From 36968f92246aedcb1a19160127278db320dcdf31 Mon Sep 17 00:00:00 2001 From: glebius Date: Mon, 26 Oct 2015 11:37:31 +0000 Subject: [PATCH] Upgrade NTP to 4.2.8p4. Security: FreeBSD-SA-15:25.ntp Security: CVE-2015-7871 Security: CVE-2015-7855 Security: CVE-2015-7854 Security: CVE-2015-7853 Security: CVE-2015-7852 Security: CVE-2015-7851 Security: CVE-2015-7850 Security: CVE-2015-7849 Security: CVE-2015-7848 Security: CVE-2015-7701 Security: CVE-2015-7703 Security: CVE-2015-7704, CVE-2015-7705 Security: CVE-2015-7691, CVE-2015-7692, CVE-2015-7702 Approved by: so git-svn-id: svn://svn.freebsd.org/base/releng/10.1@290000 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f --- UPDATING | 9 + contrib/ntp/COPYRIGHT | 271 +- contrib/ntp/ChangeLog | 3899 +- contrib/ntp/CommitLog | 201252 ++++++++++++++- contrib/ntp/Makefile.am | 202 +- contrib/ntp/Makefile.in | 801 +- contrib/ntp/NEWS | 1297 + contrib/ntp/README.hackers | 13 - contrib/ntp/README.leapsmear | 272 + contrib/ntp/WHERE-TO-START | 5 +- contrib/ntp/aclocal.m4 | 7148 +- contrib/ntp/adjtimed/Makefile.am | 27 +- contrib/ntp/adjtimed/Makefile.in | 723 +- contrib/ntp/adjtimed/adjtimed.c | 2 +- contrib/ntp/arlib/COPYING | 46 - contrib/ntp/arlib/INSTALL | 182 - contrib/ntp/arlib/Makefile.am | 15 - contrib/ntp/arlib/Makefile.in | 580 - contrib/ntp/arlib/README | 49 - contrib/ntp/arlib/UNSHAR.HDR | 32 - contrib/ntp/arlib/arlib.3 | 230 - contrib/ntp/arlib/arlib.c | 1056 - contrib/ntp/arlib/arlib.h | 29 - contrib/ntp/arlib/arplib.h | 45 - contrib/ntp/arlib/configure | 5008 - contrib/ntp/arlib/configure.in | 57 - contrib/ntp/arlib/install-sh | 323 - contrib/ntp/arlib/sample.c | 143 - contrib/ntp/bincheck.mf | 16 +- contrib/ntp/bootstrap | 148 +- contrib/ntp/build | 160 +- contrib/ntp/check-libopts.mf | 14 + contrib/ntp/clockstuff/Makefile.am | 27 +- contrib/ntp/clockstuff/Makefile.in | 605 +- contrib/ntp/clockstuff/README | 18 +- contrib/ntp/clockstuff/chutest.c | 89 +- contrib/ntp/clockstuff/clktest.c | 412 - contrib/ntp/clockstuff/propdelay.c | 8 +- contrib/ntp/conf/beauregard.conf | 2 +- contrib/ntp/config.guess | 502 +- contrib/ntp/config.h.in | 803 +- contrib/ntp/config.sub | 337 +- contrib/ntp/configure | 48025 ++-- contrib/ntp/configure.ac | 6321 +- contrib/ntp/deps-ver | 1 + contrib/ntp/depsver.mf | 60 + contrib/ntp/dot.emacs | 7 +- contrib/ntp/excludes | 1 - contrib/ntp/flock-build | 137 +- contrib/ntp/html/access.html | 50 + contrib/ntp/html/accopt.html | 160 +- contrib/ntp/html/assoc.html | 136 +- contrib/ntp/html/audio.html | 324 +- contrib/ntp/html/authentic.html | 65 + contrib/ntp/html/authopt.html | 246 +- contrib/ntp/html/autokey.html | 215 + contrib/ntp/html/bugs.html | 27 + contrib/ntp/html/build.html | 57 + contrib/ntp/html/build/build.html | 83 - contrib/ntp/html/build/config.html | 168 - contrib/ntp/html/build/hints.html | 23 - contrib/ntp/html/build/hints/netbsd | 37 - contrib/ntp/html/build/hints/solaris.html | 144 - contrib/ntp/html/build/hints/vxworks.html | 82 - contrib/ntp/html/build/hints/winnt.html | 281 - contrib/ntp/html/build/patches.html | 36 - contrib/ntp/html/build/porting.html | 40 - contrib/ntp/html/build/quick.html | 30 - contrib/ntp/html/build/scripts/footer.txt | 7 - contrib/ntp/html/build/scripts/links10.txt | 5 - contrib/ntp/html/build/scripts/links11.txt | 5 - contrib/ntp/html/build/scripts/links12.txt | 5 - contrib/ntp/html/build/scripts/links7.txt | 5 - contrib/ntp/html/build/scripts/links8.txt | 6 - contrib/ntp/html/build/scripts/links9.txt | 7 - contrib/ntp/html/build/scripts/style.css | 64 - contrib/ntp/html/clock.html | 65 + contrib/ntp/html/clockopt.html | 121 +- contrib/ntp/html/cluster.html | 32 + contrib/ntp/html/comdex.html | 29 + contrib/ntp/html/config.html | 40 + contrib/ntp/html/confopt.html | 179 +- contrib/ntp/html/copyright.html | 190 +- contrib/ntp/html/debug.html | 261 +- contrib/ntp/html/decode.html | 692 + contrib/ntp/html/discipline.html | 49 + contrib/ntp/html/discover.html | 75 + contrib/ntp/html/drivers/driver1.html | 111 +- contrib/ntp/html/drivers/driver10.html | 102 +- contrib/ntp/html/drivers/driver11.html | 122 +- contrib/ntp/html/drivers/driver12.html | 94 +- contrib/ntp/html/drivers/driver16.html | 53 +- contrib/ntp/html/drivers/driver18.html | 160 +- contrib/ntp/html/drivers/driver19.html | 106 +- contrib/ntp/html/drivers/driver2.html | 67 - contrib/ntp/html/drivers/driver20.html | 519 +- contrib/ntp/html/drivers/driver22.html | 154 +- contrib/ntp/html/drivers/driver26.html | 3 + contrib/ntp/html/drivers/driver27.html | 7 +- contrib/ntp/html/drivers/driver28.html | 245 +- contrib/ntp/html/drivers/driver29.html | 329 +- contrib/ntp/html/drivers/driver3.html | 104 +- contrib/ntp/html/drivers/driver30.html | 5 +- contrib/ntp/html/drivers/driver31.html | 5 +- contrib/ntp/html/drivers/driver32.html | 6 +- contrib/ntp/html/drivers/driver33.html | 7 +- contrib/ntp/html/drivers/driver34.html | 175 +- contrib/ntp/html/drivers/driver35.html | 5 +- contrib/ntp/html/drivers/driver36.html | 292 +- contrib/ntp/html/drivers/driver37.html | 5 +- contrib/ntp/html/drivers/driver38.html | 8 +- contrib/ntp/html/drivers/driver39.html | 6 +- contrib/ntp/html/drivers/driver4.html | 138 +- contrib/ntp/html/drivers/driver40-ja.html | 534 + contrib/ntp/html/drivers/driver40.html | 443 +- contrib/ntp/html/drivers/driver42.html | 5 +- contrib/ntp/html/drivers/driver43.html | 5 +- contrib/ntp/html/drivers/driver44.html | 5 +- contrib/ntp/html/drivers/driver45.html | 32 + contrib/ntp/html/drivers/driver46.html | 363 + contrib/ntp/html/drivers/driver5.html | 143 +- contrib/ntp/html/drivers/driver6.html | 168 +- contrib/ntp/html/drivers/driver7.html | 348 +- contrib/ntp/html/drivers/driver8.html | 545 +- contrib/ntp/html/drivers/driver9.html | 106 +- .../ntp/html/{ => drivers}/mx4200data.html | 9 +- contrib/ntp/html/drivers/oncore-shmem.html | 5 +- contrib/ntp/html/drivers/scripts/footer.txt | 10 +- contrib/ntp/html/drivers/scripts/style.css | 2 +- contrib/ntp/html/drivers/tf582_4.html | 5 +- contrib/ntp/html/extern.html | 77 +- contrib/ntp/html/filter.html | 34 + contrib/ntp/html/gadget.html | 33 - contrib/ntp/html/groups.html | 47 - contrib/ntp/html/hints.html | 22 + contrib/ntp/html/{build => }/hints/a-ux | 0 contrib/ntp/html/{build => }/hints/aix | 0 contrib/ntp/html/{build => }/hints/bsdi | 0 contrib/ntp/html/{build => }/hints/changes | 0 contrib/ntp/html/{build => }/hints/decosf1 | 0 contrib/ntp/html/{build => }/hints/decosf2 | 0 contrib/ntp/html/{build => }/hints/freebsd | 0 contrib/ntp/html/{build => }/hints/hpux | 0 contrib/ntp/html/{build => }/hints/linux | 0 contrib/ntp/html/{build => }/hints/mpeix | 0 .../ntp/html/{build => }/hints/notes-xntp-v3 | 0 contrib/ntp/html/{build => }/hints/parse | 2 +- contrib/ntp/html/{build => }/hints/refclocks | 0 contrib/ntp/html/{build => }/hints/rs6000 | 0 contrib/ntp/html/{build => }/hints/sco.html | 23 +- contrib/ntp/html/{build => }/hints/sgi | 0 .../{build => }/hints/solaris-dosynctodr.html | 22 +- contrib/ntp/html/hints/solaris.html | 236 + .../{build => }/hints/solaris.xtra.4023118 | 0 .../{build => }/hints/solaris.xtra.4095849 | 0 .../{build => }/hints/solaris.xtra.S99ntpd | 0 .../{build => }/hints/solaris.xtra.patchfreq | 0 contrib/ntp/html/{build => }/hints/sun4 | 0 contrib/ntp/html/{build => }/hints/svr4-dell | 0 .../ntp/html/{build => }/hints/svr4_package | 0 contrib/ntp/html/{build => }/hints/todo | 0 contrib/ntp/html/hints/vxworks.html | 88 + contrib/ntp/html/hints/winnt.html | 90 + contrib/ntp/html/history.html | 74 + contrib/ntp/html/howto.html | 214 +- contrib/ntp/html/huffpuff.html | 31 + contrib/ntp/html/icons/sitemap.png | Bin 0 -> 2825 bytes contrib/ntp/html/index.html | 170 +- contrib/ntp/html/kern.html | 62 +- contrib/ntp/html/kernpps.html | 49 + contrib/ntp/html/keygen.html | 228 +- contrib/ntp/html/ldisc.html | 47 - contrib/ntp/html/leap.html | 24 + contrib/ntp/html/manyopt.html | 83 - contrib/ntp/html/measure.html | 23 - contrib/ntp/html/miscopt.html | 299 +- contrib/ntp/html/monopt.html | 692 +- contrib/ntp/html/msyslog.html | 247 +- contrib/ntp/html/notes.html | 280 - contrib/ntp/html/ntp-wait.html | 33 + contrib/ntp/html/ntp_conf.html | 341 +- contrib/ntp/html/ntpd.html | 355 +- contrib/ntp/html/ntpdate.html | 147 +- contrib/ntp/html/ntpdc.html | 387 +- contrib/ntp/html/ntpdsim.html | 124 +- contrib/ntp/html/ntpdsim_new.html | 152 +- contrib/ntp/html/ntpq.html | 914 +- contrib/ntp/html/ntptime.html | 90 +- contrib/ntp/html/ntptrace.html | 77 +- contrib/ntp/html/orphan.html | 42 + contrib/ntp/html/parsedata.html | 5 +- contrib/ntp/html/parsenew.html | 9 +- contrib/ntp/html/pic/9400n.jpg | Bin 0 -> 5736 bytes contrib/ntp/html/pic/alice11.gif | Bin 0 -> 18003 bytes contrib/ntp/html/pic/alice13.gif | Bin 0 -> 11516 bytes contrib/ntp/html/pic/alice15.gif | Bin 0 -> 26328 bytes contrib/ntp/html/pic/alice23.gif | Bin 0 -> 7753 bytes contrib/ntp/html/pic/alice31.gif | Bin 0 -> 13824 bytes contrib/ntp/html/pic/alice32.gif | Bin 0 -> 17168 bytes contrib/ntp/html/pic/alice35.gif | Bin 0 -> 8968 bytes contrib/ntp/html/pic/alice38.gif | Bin 0 -> 10296 bytes contrib/ntp/html/pic/alice44.gif | Bin 0 -> 19897 bytes contrib/ntp/html/pic/alice47.gif | Bin 0 -> 10771 bytes contrib/ntp/html/pic/alice51.gif | Bin 0 -> 12403 bytes contrib/ntp/html/pic/alice61.gif | Bin 0 -> 11269 bytes contrib/ntp/html/pic/barnstable.gif | Bin 0 -> 2946 bytes contrib/ntp/html/pic/beaver.gif | Bin 0 -> 2831 bytes contrib/ntp/html/pic/boom3.gif | Bin 0 -> 11042 bytes contrib/ntp/html/pic/boom3a.gif | Bin 0 -> 18300 bytes contrib/ntp/html/pic/boom4.gif | Bin 0 -> 16157 bytes contrib/ntp/html/pic/broad.gif | Bin 0 -> 5728 bytes contrib/ntp/html/pic/bustardfly.gif | Bin 0 -> 8476 bytes contrib/ntp/html/pic/c51.jpg | Bin 0 -> 16429 bytes contrib/ntp/html/pic/description.jpg | Bin 0 -> 34170 bytes contrib/ntp/html/pic/discipline.gif | Bin 0 -> 6836 bytes contrib/ntp/html/pic/dogsnake.gif | Bin 0 -> 5445 bytes contrib/ntp/html/pic/driver29.gif | Bin 0 -> 11723 bytes contrib/ntp/html/pic/driver43_1.gif | Bin 0 -> 38818 bytes contrib/ntp/html/pic/driver43_2.jpg | Bin 0 -> 6576 bytes contrib/ntp/html/pic/fg6021.gif | Bin 0 -> 21593 bytes contrib/ntp/html/pic/fg6039.jpg | Bin 0 -> 7383 bytes contrib/ntp/html/pic/fig_3_1.gif | Bin 0 -> 10428 bytes contrib/ntp/html/pic/flatheads.gif | Bin 0 -> 13085 bytes contrib/ntp/html/pic/flt1.gif | Bin 0 -> 9045 bytes contrib/ntp/html/pic/flt2.gif | Bin 0 -> 3148 bytes contrib/ntp/html/pic/flt3.gif | Bin 0 -> 1847 bytes contrib/ntp/html/pic/flt4.gif | Bin 0 -> 3876 bytes contrib/ntp/html/pic/flt5.gif | Bin 0 -> 10609 bytes contrib/ntp/html/pic/flt6.gif | Bin 0 -> 15563 bytes contrib/ntp/html/pic/flt7.gif | Bin 0 -> 7848 bytes contrib/ntp/html/pic/flt8.gif | Bin 0 -> 5969 bytes contrib/ntp/html/pic/flt9.gif | Bin 0 -> 8948 bytes contrib/ntp/html/pic/freq1211.gif | Bin 0 -> 11428 bytes contrib/ntp/html/pic/gadget.jpg | Bin 0 -> 26341 bytes contrib/ntp/html/pic/gps167.jpg | Bin 0 -> 15589 bytes contrib/ntp/html/pic/group.gif | Bin 0 -> 2756 bytes contrib/ntp/html/pic/hornraba.gif | Bin 0 -> 8790 bytes contrib/ntp/html/pic/igclock.gif | Bin 0 -> 8985 bytes contrib/ntp/html/pic/neoclock4x.gif | Bin 0 -> 14977 bytes contrib/ntp/html/pic/offset1211.gif | Bin 0 -> 25493 bytes contrib/ntp/html/pic/oncore_evalbig.gif | Bin 0 -> 7904 bytes contrib/ntp/html/pic/oncore_remoteant.jpg | Bin 0 -> 4828 bytes contrib/ntp/html/pic/oncore_utplusbig.gif | Bin 0 -> 10117 bytes contrib/ntp/html/pic/oz2.gif | Bin 0 -> 8225 bytes contrib/ntp/html/pic/panda.gif | Bin 0 -> 1660 bytes contrib/ntp/html/pic/pd_om006.gif | Bin 0 -> 16704 bytes contrib/ntp/html/pic/pd_om011.gif | Bin 0 -> 12848 bytes contrib/ntp/html/pic/peer.gif | Bin 0 -> 4936 bytes contrib/ntp/html/pic/pogo.gif | Bin 0 -> 1918 bytes contrib/ntp/html/pic/pogo1a.gif | Bin 0 -> 18769 bytes contrib/ntp/html/pic/pogo3a.gif | Bin 0 -> 3657 bytes contrib/ntp/html/pic/pogo4.gif | Bin 0 -> 3213 bytes contrib/ntp/html/pic/pogo5.gif | Bin 0 -> 5819 bytes contrib/ntp/html/pic/pogo6.gif | Bin 0 -> 5902 bytes contrib/ntp/html/pic/pogo7.gif | Bin 0 -> 13817 bytes contrib/ntp/html/pic/pogo8.gif | Bin 0 -> 7820 bytes contrib/ntp/html/pic/pzf509.jpg | Bin 0 -> 13011 bytes contrib/ntp/html/pic/pzf511.jpg | Bin 0 -> 20370 bytes contrib/ntp/html/pic/rabbit.gif | Bin 0 -> 3342 bytes contrib/ntp/html/pic/radio2.jpg | Bin 0 -> 17006 bytes contrib/ntp/html/pic/sheepb.jpg | Bin 0 -> 20295 bytes contrib/ntp/html/pic/stack1a.jpg | Bin 0 -> 29655 bytes contrib/ntp/html/pic/stats.gif | Bin 0 -> 12168 bytes contrib/ntp/html/pic/sx5.gif | Bin 0 -> 20470 bytes contrib/ntp/html/pic/thunderbolt.jpg | Bin 0 -> 38718 bytes contrib/ntp/html/pic/time1.gif | Bin 0 -> 4507 bytes contrib/ntp/html/pic/tonea.gif | Bin 0 -> 12002 bytes contrib/ntp/html/pic/tribeb.gif | Bin 0 -> 30287 bytes contrib/ntp/html/pic/wingdorothy.gif | Bin 0 -> 10849 bytes contrib/ntp/html/poll.html | 26 + contrib/ntp/html/pps.html | 84 +- contrib/ntp/html/prefer.html | 161 +- contrib/ntp/html/quick.html | 45 + contrib/ntp/html/rate.html | 67 + contrib/ntp/html/rdebug.html | 57 +- contrib/ntp/html/refclock.html | 192 +- contrib/ntp/html/release.html | 138 +- contrib/ntp/html/scripts/accopt.txt | 5 + contrib/ntp/html/scripts/audio.txt | 7 + contrib/ntp/html/scripts/authopt.txt | 12 + contrib/ntp/html/scripts/clockopt.txt | 5 + contrib/ntp/html/scripts/command.txt | 7 + contrib/ntp/html/scripts/config.txt | 5 + contrib/ntp/html/scripts/confopt.txt | 12 + contrib/ntp/html/scripts/external.txt | 19 + contrib/ntp/html/scripts/footer.txt | 10 +- contrib/ntp/html/scripts/hand.txt | 11 + contrib/ntp/html/scripts/install.txt | 10 + contrib/ntp/html/scripts/links10.txt | 5 - contrib/ntp/html/scripts/links11.txt | 7 - contrib/ntp/html/scripts/links12.txt | 5 - contrib/ntp/html/scripts/links7.txt | 6 - contrib/ntp/html/scripts/links8.txt | 6 - contrib/ntp/html/scripts/links9.txt | 8 - contrib/ntp/html/scripts/manual.txt | 13 + contrib/ntp/html/scripts/misc.txt | 9 + contrib/ntp/html/scripts/miscopt.txt | 21 + contrib/ntp/html/scripts/monopt.txt | 6 + contrib/ntp/html/scripts/refclock.txt | 7 + contrib/ntp/html/scripts/special.txt | 17 + contrib/ntp/html/scripts/style.css | 2 +- contrib/ntp/html/select.html | 41 + contrib/ntp/html/sitemap.html | 33 + contrib/ntp/html/sntp.html | 132 +- contrib/ntp/html/stats.html | 70 + contrib/ntp/html/tickadj.html | 90 +- contrib/ntp/html/warp.html | 60 + contrib/ntp/html/xleave.html | 30 + contrib/ntp/include/Makefile.am | 128 +- contrib/ntp/include/Makefile.in | 630 +- contrib/ntp/include/audio.h | 6 +- contrib/ntp/include/autogen-version.def | 2 - contrib/ntp/include/binio.h | 26 +- contrib/ntp/include/copyright.def | 18 - contrib/ntp/include/debug-opt.def | 34 - contrib/ntp/include/declcond.h | 21 + contrib/ntp/include/global.h | 54 - contrib/ntp/include/icom.h | 4 +- contrib/ntp/include/ieee754io.h | 4 +- contrib/ntp/include/intreswork.h | 29 + contrib/ntp/include/iosignal.h | 63 +- contrib/ntp/include/isc/Makefile.am | 40 +- contrib/ntp/include/isc/Makefile.in | 431 +- contrib/ntp/include/isc/app.h | 212 - contrib/ntp/include/isc/boolean.h | 29 - contrib/ntp/include/isc/formatcheck.h | 34 - contrib/ntp/include/isc/interfaceiter.h | 139 - contrib/ntp/include/isc/lang.h | 31 - contrib/ntp/include/isc/lib.h | 39 - contrib/ntp/include/isc/mem.h | 65 +- contrib/ntp/include/isc/msgs.h | 183 - contrib/ntp/include/isc/once.h | 32 - contrib/ntp/include/isc/result.h | 106 - contrib/ntp/include/isc/strerror.h | 42 - contrib/ntp/include/isc/string.h | 56 - contrib/ntp/include/isc/types.h | 102 - contrib/ntp/include/l_stdlib.h | 422 +- contrib/ntp/include/lib_strbuf.h | 32 + contrib/ntp/include/libntp.h | 16 + contrib/ntp/include/mbg_gps166.h | 1239 +- contrib/ntp/include/ntp.h | 645 +- contrib/ntp/include/ntp_assert.h | 104 + contrib/ntp/include/ntp_calendar.h | 399 +- contrib/ntp/include/ntp_cmdargs.h | 5 +- contrib/ntp/include/ntp_config.h | 450 +- contrib/ntp/include/ntp_control.h | 193 +- contrib/ntp/include/ntp_crypto.h | 90 +- contrib/ntp/include/ntp_debug.h | 25 +- contrib/ntp/include/ntp_filegen.h | 41 +- contrib/ntp/include/ntp_fp.h | 452 +- contrib/ntp/include/ntp_intres.h | 45 + contrib/ntp/include/ntp_io.h | 66 +- contrib/ntp/include/ntp_libopts.h | 14 + contrib/ntp/include/ntp_lineedit.h | 13 + contrib/ntp/include/ntp_lists.h | 443 + contrib/ntp/include/ntp_machine.h | 337 +- contrib/ntp/include/ntp_malloc.h | 60 +- contrib/ntp/include/ntp_md5.h | 41 +- contrib/ntp/include/ntp_net.h | 238 + contrib/ntp/include/ntp_prio_q.h | 83 + contrib/ntp/include/ntp_proto.h | 10 +- contrib/ntp/include/ntp_random.h | 15 +- contrib/ntp/include/ntp_refclock.h | 138 +- contrib/ntp/include/ntp_request.h | 126 +- contrib/ntp/include/ntp_rfc2553.h | 183 +- contrib/ntp/include/ntp_select.h | 38 +- contrib/ntp/include/ntp_sprintf.h | 13 - contrib/ntp/include/ntp_stdlib.h | 329 +- contrib/ntp/include/ntp_string.h | 43 +- contrib/ntp/include/ntp_syscall.h | 55 +- contrib/ntp/include/ntp_syslog.h | 46 +- contrib/ntp/include/ntp_tty.h | 70 +- contrib/ntp/include/ntp_types.h | 280 +- contrib/ntp/include/ntp_unixtime.h | 116 +- contrib/ntp/include/ntp_worker.h | 162 + contrib/ntp/include/ntp_workimpl.h | 30 + contrib/ntp/include/ntpd.h | 600 +- contrib/ntp/include/ntpsim.h | 181 +- contrib/ntp/include/parse.h | 101 +- contrib/ntp/include/parse_conf.h | 14 +- contrib/ntp/include/rc_cmdlength.h | 2 + contrib/ntp/include/recvbuff.h | 96 +- contrib/ntp/include/refclock_atom.h | 15 + contrib/ntp/include/refidsmear.h | 3 + contrib/ntp/include/rsa_md5.h | 51 - contrib/ntp/include/ssl_applink.c | 74 + contrib/ntp/include/timepps-SCO.h | 2 +- contrib/ntp/include/timepps-Solaris.h | 156 +- contrib/ntp/include/timepps-SunOS.h | 2 +- contrib/ntp/include/timespecops.h | 393 + contrib/ntp/include/timetoa.h | 83 + contrib/ntp/include/timevalops.h | 446 + contrib/ntp/include/trimble.h | 2 +- contrib/ntp/include/version.def | 1 - contrib/ntp/include/vint64ops.h | 28 + contrib/ntp/includes.mf | 6 + contrib/ntp/kernel/Makefile.am | 4 - contrib/ntp/kernel/Makefile.in | 506 +- contrib/ntp/kernel/README | 200 - contrib/ntp/kernel/chuinit.c | 74 - contrib/ntp/kernel/clkinit.c | 74 - contrib/ntp/kernel/sys/Makefile.am | 8 +- contrib/ntp/kernel/sys/Makefile.in | 401 +- contrib/ntp/kernel/sys/chudefs.h | 22 - contrib/ntp/kernel/sys/clkdefs.h | 38 - contrib/ntp/kernel/sys/parsestreams.h | 2 +- contrib/ntp/kernel/tty_chu.c | 276 - contrib/ntp/kernel/tty_chu_STREAMS.c | 603 - contrib/ntp/kernel/tty_clk.c | 317 - contrib/ntp/kernel/tty_clk_STREAMS.c | 266 - contrib/ntp/lib/isc/Atffile | 5 + .../ntp/lib/isc/alpha/include/isc/atomic.h | 184 + contrib/ntp/lib/isc/api | 8 + contrib/ntp/lib/isc/app_api.c | 136 + contrib/ntp/lib/isc/assertions.c | 139 + contrib/ntp/lib/isc/backtrace-emptytbl.c | 34 + contrib/ntp/lib/isc/backtrace.c | 285 + contrib/ntp/lib/isc/base32.c | 373 + contrib/ntp/lib/isc/base64.c | 252 + contrib/ntp/lib/isc/bitstring.c | 127 + contrib/ntp/lib/isc/buffer.c | 489 + contrib/ntp/lib/isc/bufferlist.c | 64 + contrib/ntp/lib/isc/commandline.c | 225 + contrib/ntp/lib/isc/entropy.c | 1277 + contrib/ntp/{libisc => lib/isc}/error.c | 25 +- contrib/ntp/lib/isc/event.c | 86 + contrib/ntp/lib/isc/fsaccess.c | 102 + contrib/ntp/lib/isc/hash.c | 404 + contrib/ntp/lib/isc/heap.c | 265 + contrib/ntp/lib/isc/hex.c | 201 + contrib/ntp/lib/isc/hmacmd5.c | 149 + contrib/ntp/lib/isc/hmacsha.c | 594 + contrib/ntp/lib/isc/httpd.c | 1028 + contrib/ntp/lib/isc/ia64/include/isc/atomic.h | 100 + contrib/ntp/lib/isc/include/isc/app.h | 375 + .../{ => lib/isc}/include/isc/assertions.h | 32 +- contrib/ntp/lib/isc/include/isc/backtrace.h | 131 + contrib/ntp/lib/isc/include/isc/base32.h | 128 + contrib/ntp/lib/isc/include/isc/base64.h | 99 + contrib/ntp/lib/isc/include/isc/bind9.h | 30 + contrib/ntp/lib/isc/include/isc/bitstring.h | 157 + contrib/ntp/lib/isc/include/isc/boolean.h | 31 + .../ntp/{ => lib/isc}/include/isc/buffer.h | 398 +- contrib/ntp/lib/isc/include/isc/bufferlist.h | 86 + contrib/ntp/lib/isc/include/isc/commandline.h | 50 + contrib/ntp/lib/isc/include/isc/entropy.h | 314 + contrib/ntp/{ => lib/isc}/include/isc/error.h | 32 +- contrib/ntp/lib/isc/include/isc/event.h | 121 + contrib/ntp/lib/isc/include/isc/eventclass.h | 53 + contrib/ntp/lib/isc/include/isc/file.h | 304 + contrib/ntp/lib/isc/include/isc/formatcheck.h | 40 + contrib/ntp/lib/isc/include/isc/fsaccess.h | 178 + contrib/ntp/lib/isc/include/isc/hash.h | 185 + contrib/ntp/lib/isc/include/isc/heap.h | 170 + contrib/ntp/lib/isc/include/isc/hex.h | 98 + contrib/ntp/lib/isc/include/isc/hmacmd5.h | 72 + contrib/ntp/lib/isc/include/isc/hmacsha.h | 169 + contrib/ntp/lib/isc/include/isc/httpd.h | 64 + .../ntp/lib/isc/include/isc/interfaceiter.h | 138 + contrib/ntp/{ => lib/isc}/include/isc/ipv6.h | 51 +- .../ntp/lib/isc/include/isc/iterated_hash.h | 47 + contrib/ntp/lib/isc/include/isc/lang.h | 33 + contrib/ntp/lib/isc/include/isc/lex.h | 431 + contrib/ntp/lib/isc/include/isc/lfsr.h | 130 + contrib/ntp/lib/isc/include/isc/lib.h | 50 + contrib/ntp/{ => lib/isc}/include/isc/list.h | 43 +- contrib/ntp/lib/isc/include/isc/log.h | 914 + contrib/ntp/{ => lib/isc}/include/isc/magic.h | 25 +- contrib/ntp/lib/isc/include/isc/md5.h | 83 + contrib/ntp/lib/isc/include/isc/mem.h | 750 + .../ntp/{ => lib/isc}/include/isc/msgcat.h | 67 +- contrib/ntp/lib/isc/include/isc/msgs.h | 195 + contrib/ntp/lib/isc/include/isc/mutexblock.h | 71 + contrib/ntp/lib/isc/include/isc/namespace.h | 171 + .../ntp/{ => lib/isc}/include/isc/netaddr.h | 85 +- .../ntp/{ => lib/isc}/include/isc/netscope.h | 17 +- contrib/ntp/lib/isc/include/isc/ondestroy.h | 116 + contrib/ntp/lib/isc/include/isc/os.h | 38 + contrib/ntp/lib/isc/include/isc/parseint.h | 64 + .../ntp/{ => lib/isc}/include/isc/platform.h | 0 contrib/ntp/lib/isc/include/isc/platform.h.in | 367 + contrib/ntp/lib/isc/include/isc/portset.h | 141 + contrib/ntp/{ => lib/isc}/include/isc/print.h | 44 +- contrib/ntp/lib/isc/include/isc/queue.h | 100 + contrib/ntp/lib/isc/include/isc/quota.h | 119 + contrib/ntp/lib/isc/include/isc/radix.h | 240 + contrib/ntp/lib/isc/include/isc/random.h | 62 + contrib/ntp/lib/isc/include/isc/ratelimiter.h | 134 + contrib/ntp/lib/isc/include/isc/refcount.h | 233 + .../ntp/{ => lib/isc}/include/isc/region.h | 24 +- contrib/ntp/lib/isc/include/isc/resource.h | 97 + contrib/ntp/lib/isc/include/isc/result.h | 109 + contrib/ntp/lib/isc/include/isc/resultclass.h | 51 + contrib/ntp/lib/isc/include/isc/rwlock.h | 135 + contrib/ntp/lib/isc/include/isc/serial.h | 75 + contrib/ntp/lib/isc/include/isc/sha1.h | 68 + contrib/ntp/lib/isc/include/isc/sha2.h | 145 + .../ntp/{ => lib/isc}/include/isc/sockaddr.h | 127 +- contrib/ntp/lib/isc/include/isc/socket.h | 1168 + contrib/ntp/lib/isc/include/isc/stats.h | 121 + contrib/ntp/lib/isc/include/isc/stdio.h | 77 + contrib/ntp/lib/isc/include/isc/stdlib.h | 40 + contrib/ntp/lib/isc/include/isc/string.h | 231 + contrib/ntp/lib/isc/include/isc/symtab.h | 139 + contrib/ntp/lib/isc/include/isc/task.h | 796 + contrib/ntp/lib/isc/include/isc/taskpool.h | 157 + contrib/ntp/lib/isc/include/isc/timer.h | 431 + contrib/ntp/lib/isc/include/isc/types.h | 129 + contrib/ntp/{ => lib/isc}/include/isc/util.h | 51 +- contrib/ntp/lib/isc/include/isc/version.h | 28 + contrib/ntp/lib/isc/include/isc/xml.h | 41 + contrib/ntp/{libisc => lib/isc}/inet_aton.c | 17 +- contrib/ntp/{libisc => lib/isc}/inet_ntop.c | 63 +- contrib/ntp/{libisc => lib/isc}/inet_pton.c | 70 +- contrib/ntp/lib/isc/iterated_hash.c | 48 + contrib/ntp/lib/isc/lex.c | 959 + contrib/ntp/lib/isc/lfsr.c | 161 + contrib/ntp/{libisc => lib/isc}/lib.c | 54 +- contrib/ntp/lib/isc/log.c | 1767 + contrib/ntp/lib/isc/md5.c | 277 + contrib/ntp/lib/isc/mem.c | 2477 + contrib/ntp/lib/isc/mem_api.c | 303 + contrib/ntp/lib/isc/mips/include/isc/atomic.h | 98 + contrib/ntp/lib/isc/mutexblock.c | 58 + contrib/ntp/{libisc => lib/isc}/netaddr.c | 113 +- contrib/ntp/{libisc => lib/isc}/netscope.c | 8 +- contrib/ntp/{libisc => lib/isc/nls}/msgcat.c | 27 +- .../ntp/lib/isc/noatomic/include/isc/atomic.h | 24 + contrib/ntp/lib/isc/nothreads/condition.c | 24 + .../lib/isc/nothreads/include/isc/condition.h | 59 + .../isc/nothreads}/include/isc/mutex.h | 20 +- .../ntp/lib/isc/nothreads/include/isc/once.h | 32 + .../lib/isc/nothreads/include/isc/thread.h | 35 + contrib/ntp/lib/isc/nothreads/mutex.c | 25 + contrib/ntp/lib/isc/nothreads/thread.c | 28 + contrib/ntp/lib/isc/ondestroy.c | 85 + contrib/ntp/lib/isc/parseint.c | 72 + contrib/ntp/lib/isc/portset.c | 143 + .../ntp/lib/isc/powerpc/include/isc/atomic.h | 197 + contrib/ntp/lib/isc/print.c | 624 + contrib/ntp/lib/isc/pthreads/condition.c | 74 + .../lib/isc/pthreads/include/isc/condition.h | 65 + .../ntp/lib/isc/pthreads/include/isc/mutex.h | 145 + .../ntp/lib/isc/pthreads/include/isc/once.h | 50 + .../ntp/lib/isc/pthreads/include/isc/thread.h | 60 + contrib/ntp/lib/isc/pthreads/mutex.c | 284 + contrib/ntp/lib/isc/pthreads/thread.c | 76 + contrib/ntp/lib/isc/quota.c | 101 + contrib/ntp/lib/isc/radix.c | 706 + contrib/ntp/lib/isc/random.c | 113 + contrib/ntp/lib/isc/ratelimiter.c | 328 + contrib/ntp/lib/isc/refcount.c | 37 + contrib/ntp/lib/isc/region.c | 45 + contrib/ntp/lib/isc/result.c | 214 + contrib/ntp/lib/isc/rwlock.c | 809 + contrib/ntp/lib/isc/serial.c | 59 + contrib/ntp/lib/isc/sha1.c | 354 + contrib/ntp/lib/isc/sha2.c | 1449 + contrib/ntp/{libisc => lib/isc}/sockaddr.c | 172 +- contrib/ntp/lib/isc/socket_api.c | 231 + .../ntp/lib/isc/sparc64/include/isc/atomic.h | 127 + contrib/ntp/lib/isc/stats.c | 326 + contrib/ntp/lib/isc/string.c | 271 + contrib/ntp/lib/isc/strtoul.c | 129 + contrib/ntp/lib/isc/symtab.c | 301 + contrib/ntp/lib/isc/task.c | 1813 + contrib/ntp/lib/isc/task_api.c | 244 + contrib/ntp/lib/isc/task_p.h | 39 + contrib/ntp/lib/isc/taskpool.c | 185 + contrib/ntp/lib/isc/tests/Atffile | 5 + contrib/ntp/lib/isc/tests/hash_test.c | 1805 + contrib/ntp/lib/isc/tests/isctest.c | 178 + contrib/ntp/lib/isc/tests/isctest.h | 57 + contrib/ntp/lib/isc/tests/queue_test.c | 144 + contrib/ntp/lib/isc/tests/socket_test.c | 255 + contrib/ntp/lib/isc/tests/symtab_test.c | 147 + contrib/ntp/lib/isc/tests/task_test.c | 416 + contrib/ntp/lib/isc/tests/taskpool_test.c | 211 + contrib/ntp/lib/isc/timer.c | 1072 + contrib/ntp/lib/isc/timer_api.c | 144 + contrib/ntp/lib/isc/timer_p.h | 31 + contrib/ntp/lib/isc/unix/app.c | 946 + contrib/ntp/lib/isc/unix/dir.c | 256 + contrib/ntp/lib/isc/unix/entropy.c | 605 + contrib/ntp/lib/isc/unix/errno2result.c | 122 + contrib/ntp/lib/isc/unix/errno2result.h | 41 + contrib/ntp/lib/isc/unix/file.c | 544 + contrib/ntp/lib/isc/unix/fsaccess.c | 93 + .../isc/unix}/ifiter_getifaddrs.c | 134 +- .../{libisc => lib/isc/unix}/ifiter_ioctl.c | 290 +- .../{libisc => lib/isc/unix}/ifiter_sysctl.c | 32 +- contrib/ntp/lib/isc/unix/include/isc/dir.h | 94 + .../ntp/{ => lib/isc/unix}/include/isc/int.h | 24 +- .../ntp/lib/isc/unix/include/isc/keyboard.h | 52 + .../ntp/{ => lib/isc/unix}/include/isc/net.h | 147 +- contrib/ntp/lib/isc/unix/include/isc/netdb.h | 57 + contrib/ntp/lib/isc/unix/include/isc/offset.h | 46 + contrib/ntp/lib/isc/unix/include/isc/stat.h | 52 + .../ntp/lib/isc/unix/include/isc/stdtime.h | 64 + .../ntp/lib/isc/unix/include/isc/strerror.h | 45 + contrib/ntp/lib/isc/unix/include/isc/syslog.h | 47 + contrib/ntp/lib/isc/unix/include/isc/time.h | 334 + .../{libisc => lib/isc/unix}/interfaceiter.c | 125 +- contrib/ntp/lib/isc/unix/ipv6.c | 27 + contrib/ntp/lib/isc/unix/keyboard.c | 126 + contrib/ntp/lib/isc/unix/net.c | 523 + contrib/ntp/lib/isc/unix/os.c | 94 + contrib/ntp/lib/isc/unix/resource.c | 231 + contrib/ntp/lib/isc/unix/socket.c | 6011 + contrib/ntp/lib/isc/unix/socket_p.h | 33 + contrib/ntp/lib/isc/unix/stdio.c | 129 + contrib/ntp/lib/isc/unix/stdtime.c | 86 + .../isc/unix/strerror.c} | 30 +- contrib/ntp/lib/isc/unix/syslog.c | 84 + contrib/ntp/lib/isc/unix/time.c | 420 + contrib/ntp/lib/isc/version.c | 28 + contrib/ntp/lib/isc/win32/DLLMain.c | 58 + contrib/ntp/lib/isc/win32/app.c | 260 + contrib/ntp/lib/isc/win32/condition.c | 258 + contrib/ntp/lib/isc/win32/dir.c | 312 + contrib/ntp/lib/isc/win32/entropy.c | 307 + contrib/ntp/lib/isc/win32/errno2result.c | 113 + contrib/ntp/lib/isc/win32/errno2result.h | 40 + contrib/ntp/lib/isc/win32/file.c | 619 + contrib/ntp/lib/isc/win32/fsaccess.c | 375 + .../lib/isc/win32/include/isc/bind_registry.h | 50 + .../ntp/lib/isc/win32/include/isc/bindevt.h | 91 + .../ntp/lib/isc/win32/include/isc/condition.h | 67 + contrib/ntp/lib/isc/win32/include/isc/dir.h | 83 + contrib/ntp/lib/isc/win32/include/isc/int.h | 56 + contrib/ntp/lib/isc/win32/include/isc/ipv6.h | 124 + .../ntp/lib/isc/win32/include/isc/keyboard.h | 47 + contrib/ntp/lib/isc/win32/include/isc/mutex.h | 55 + contrib/ntp/lib/isc/win32/include/isc/net.h | 374 + contrib/ntp/lib/isc/win32/include/isc/netdb.h | 54 + .../ntp/lib/isc/win32/include/isc/ntgroups.h | 35 + .../ntp/lib/isc/win32/include/isc/ntpaths.h | 72 + .../{ => lib/isc/win32}/include/isc/offset.h | 22 +- contrib/ntp/lib/isc/win32/include/isc/once.h | 43 + .../ntp/lib/isc/win32/include/isc/platform.h | 117 + contrib/ntp/lib/isc/win32/include/isc/stat.h | 68 + .../ntp/lib/isc/win32/include/isc/stdtime.h | 62 + .../ntp/lib/isc/win32/include/isc/strerror.h | 42 + .../ntp/lib/isc/win32/include/isc/syslog.h | 45 + .../ntp/lib/isc/win32/include/isc/thread.h | 100 + contrib/ntp/lib/isc/win32/include/isc/time.h | 291 + .../ntp/lib/isc/win32/include/isc/win32os.h | 71 + contrib/ntp/lib/isc/win32/interfaceiter.c | 807 + contrib/ntp/lib/isc/win32/ipv6.c | 27 + contrib/ntp/lib/isc/win32/keyboard.c | 89 + contrib/ntp/lib/isc/win32/libgen.h | 25 + contrib/ntp/lib/isc/win32/libisc.def | 583 + contrib/ntp/lib/isc/win32/libisc.dsp | 802 + contrib/ntp/lib/isc/win32/libisc.dsw | 29 + contrib/ntp/lib/isc/win32/libisc.mak | 2055 + contrib/ntp/{libisc => lib/isc/win32}/net.c | 169 +- contrib/ntp/lib/isc/win32/netdb.h | 187 + contrib/ntp/lib/isc/win32/ntgroups.c | 186 + contrib/ntp/lib/isc/win32/ntpaths.c | 147 + contrib/ntp/lib/isc/win32/once.c | 54 + contrib/ntp/lib/isc/win32/os.c | 45 + contrib/ntp/lib/isc/win32/resource.c | 72 + contrib/ntp/lib/isc/win32/socket.c | 3967 + contrib/ntp/lib/isc/win32/stdio.c | 117 + contrib/ntp/lib/isc/win32/stdtime.c | 37 + contrib/ntp/lib/isc/win32/strerror.c | 459 + contrib/ntp/lib/isc/win32/syslog.c | 181 + contrib/ntp/lib/isc/win32/syslog.h | 76 + contrib/ntp/lib/isc/win32/thread.c | 94 + contrib/ntp/lib/isc/win32/time.c | 320 + contrib/ntp/lib/isc/win32/unistd.h | 60 + contrib/ntp/lib/isc/win32/version.c | 28 + contrib/ntp/lib/isc/win32/win32os.c | 101 + .../ntp/lib/isc/x86_32/include/isc/atomic.h | 176 + .../ntp/lib/isc/x86_64/include/isc/atomic.h | 123 + contrib/ntp/libisc/assertions.c | 93 - contrib/ntp/libisc/mem.c | 42 - contrib/ntp/libisc/strerror.c | 72 - contrib/ntp/libjsmn/LICENSE | 20 + contrib/ntp/libjsmn/Makefile | 35 + contrib/ntp/libjsmn/README.md | 167 + contrib/ntp/libjsmn/example/jsondump.c | 112 + contrib/ntp/libjsmn/example/simple.c | 75 + contrib/ntp/libjsmn/jsmn.c | 312 + contrib/ntp/libjsmn/jsmn.h | 75 + contrib/ntp/libjsmn/jsmn_test.c | 608 + contrib/ntp/libntp/Makefile.am | 145 +- contrib/ntp/libntp/Makefile.in | 1881 +- contrib/ntp/libntp/a_md5encrypt.c | 139 +- contrib/ntp/libntp/atoint.c | 3 +- contrib/ntp/libntp/atolfp.c | 14 +- contrib/ntp/libntp/atouint.c | 31 +- contrib/ntp/libntp/audio.c | 119 +- contrib/ntp/libntp/authkeys.c | 716 +- contrib/ntp/libntp/authreadkeys.c | 210 +- contrib/ntp/libntp/authusekey.c | 21 +- .../ntp/libntp/{strerror.c => bsd_strerror.c} | 7 +- contrib/ntp/libntp/buftvtots.c | 15 +- contrib/ntp/libntp/caljulian.c | 153 +- contrib/ntp/libntp/caltontp.c | 78 +- contrib/ntp/libntp/calyearstart.c | 86 +- contrib/ntp/libntp/clocktime.c | 211 +- contrib/ntp/libntp/clocktypes.c | 13 +- contrib/ntp/libntp/decodenetnum.c | 75 +- contrib/ntp/libntp/dofptoa.c | 43 +- contrib/ntp/libntp/dolfptoa.c | 207 +- contrib/ntp/libntp/emalloc.c | 139 +- contrib/ntp/libntp/findconfig.c | 12 +- contrib/ntp/libntp/fptoa.c | 25 - contrib/ntp/libntp/fptoms.c | 24 - contrib/ntp/libntp/getopt.c | 1 + contrib/ntp/libntp/hextoint.c | 27 +- contrib/ntp/libntp/hextolfp.c | 5 +- contrib/ntp/libntp/humandate.c | 66 +- contrib/ntp/libntp/icom.c | 321 +- contrib/ntp/libntp/inttoa.c | 20 - contrib/ntp/libntp/iosignal.c | 75 +- contrib/ntp/libntp/lib_strbuf.c | 26 +- contrib/ntp/libntp/lib_strbuf.h | 28 - contrib/ntp/libntp/machines.c | 112 +- contrib/ntp/libntp/md5c.c | 354 - contrib/ntp/libntp/memmove.c | 140 - contrib/ntp/libntp/mfptoa.c | 23 - contrib/ntp/libntp/mfptoms.c | 23 - contrib/ntp/libntp/mktime.c | 13 +- contrib/ntp/libntp/modetoa.c | 9 +- contrib/ntp/libntp/mstolfp.c | 11 +- contrib/ntp/libntp/msutotsf.c | 35 - contrib/ntp/libntp/msyslog.c | 628 +- contrib/ntp/libntp/netof.c | 57 +- contrib/ntp/libntp/ntp_calendar.c | 1801 + contrib/ntp/libntp/ntp_crypto_rnd.c | 113 + contrib/ntp/libntp/ntp_intres.c | 1128 + contrib/ntp/libntp/ntp_libopts.c | 58 + contrib/ntp/libntp/ntp_lineedit.c | 245 + contrib/ntp/libntp/ntp_random.c | 64 +- contrib/ntp/libntp/ntp_rfc2553.c | 177 +- contrib/ntp/libntp/ntp_worker.c | 340 + contrib/ntp/libntp/numtoa.c | 41 +- contrib/ntp/libntp/numtohost.c | 11 +- contrib/ntp/libntp/octtoint.c | 3 +- contrib/ntp/libntp/prettydate.c | 273 +- contrib/ntp/libntp/recvbuff.c | 204 +- contrib/ntp/libntp/refidsmear.c | 58 + contrib/ntp/libntp/refnumtoa.c | 38 +- contrib/ntp/libntp/snprintf.c | 2158 +- contrib/ntp/libntp/socket.c | 218 + contrib/ntp/libntp/socktoa.c | 166 +- contrib/ntp/libntp/socktohost.c | 95 +- contrib/ntp/libntp/ssl_init.c | 187 + contrib/ntp/libntp/statestr.c | 500 +- contrib/ntp/libntp/strdup.c | 29 +- contrib/ntp/libntp/strl_obsd.c | 123 + contrib/ntp/libntp/strstr.c | 52 - contrib/ntp/libntp/syssignal.c | 159 +- contrib/ntp/libntp/systime.c | 660 +- contrib/ntp/libntp/timetoa.c | 106 + contrib/ntp/libntp/timevalops.c | 297 + contrib/ntp/libntp/tsftomsu.c | 38 - contrib/ntp/libntp/tstotv.c | 135 - contrib/ntp/libntp/tvtoa.c | 39 - contrib/ntp/libntp/tvtots.c | 159 - contrib/ntp/libntp/uglydate.c | 9 +- contrib/ntp/libntp/uinttoa.c | 20 - contrib/ntp/libntp/utvtoa.c | 26 - contrib/ntp/libntp/vint64ops.c | 284 + contrib/ntp/libntp/work_fork.c | 545 + contrib/ntp/libntp/work_thread.c | 726 + contrib/ntp/libntp/ymd2yd.c | 39 +- contrib/ntp/libopts/COPYING.lgpl | 502 - contrib/ntp/libopts/COPYING.mbsd | 26 - contrib/ntp/libopts/Makefile.am | 24 - contrib/ntp/libopts/Makefile.in | 579 - contrib/ntp/libopts/README | 93 - contrib/ntp/libopts/autoopts.c | 1120 - contrib/ntp/libopts/autoopts.h | 387 - contrib/ntp/libopts/autoopts/options.h | 977 - contrib/ntp/libopts/autoopts/usage-txt.h | 355 - contrib/ntp/libopts/boolean.c | 106 - contrib/ntp/libopts/compat/compat.h | 319 - contrib/ntp/libopts/compat/pathfind.c | 339 - contrib/ntp/libopts/compat/snprintf.c | 60 - contrib/ntp/libopts/compat/strchr.c | 60 - contrib/ntp/libopts/compat/strdup.c | 19 - contrib/ntp/libopts/compat/windows-config.h | 130 - contrib/ntp/libopts/configfile.c | 1290 - contrib/ntp/libopts/cook.c | 354 - contrib/ntp/libopts/enumeration.c | 498 - contrib/ntp/libopts/environment.c | 279 - contrib/ntp/libopts/genshell.c | 354 - contrib/ntp/libopts/genshell.h | 149 - contrib/ntp/libopts/libopts.c | 30 - contrib/ntp/libopts/load.c | 563 - contrib/ntp/libopts/m4/libopts.m4 | 509 - contrib/ntp/libopts/m4/liboptschk.m4 | 42 - contrib/ntp/libopts/makeshell.c | 1122 - contrib/ntp/libopts/nested.c | 733 - contrib/ntp/libopts/numeric.c | 93 - contrib/ntp/libopts/pgusage.c | 157 - contrib/ntp/libopts/proto.h | 91 - contrib/ntp/libopts/putshell.c | 335 - contrib/ntp/libopts/restore.c | 250 - contrib/ntp/libopts/save.c | 521 - contrib/ntp/libopts/sort.c | 359 - contrib/ntp/libopts/stack.c | 269 - contrib/ntp/libopts/streqvcmp.c | 289 - contrib/ntp/libopts/text_mmap.c | 363 - contrib/ntp/libopts/tokenize.c | 321 - contrib/ntp/libopts/usage.c | 740 - contrib/ntp/libopts/version.c | 178 - contrib/ntp/libparse/Makefile.am | 205 +- contrib/ntp/libparse/Makefile.in | 907 +- contrib/ntp/libparse/binio.c | 5 +- contrib/ntp/libparse/clk_computime.c | 64 +- contrib/ntp/libparse/clk_dcf7000.c | 29 +- contrib/ntp/libparse/clk_hopf6021.c | 41 +- contrib/ntp/libparse/clk_meinberg.c | 183 +- contrib/ntp/libparse/clk_rawdcf.c | 182 +- contrib/ntp/libparse/clk_rcc8000.c | 33 +- contrib/ntp/libparse/clk_schmid.c | 42 +- contrib/ntp/libparse/clk_sel240x.c | 172 + contrib/ntp/libparse/clk_trimtaip.c | 25 +- contrib/ntp/libparse/clk_trimtsip.c | 79 +- contrib/ntp/libparse/clk_varitext.c | 89 +- contrib/ntp/libparse/clk_wharton.c | 17 +- contrib/ntp/libparse/data_mbg.c | 160 +- contrib/ntp/libparse/gpstolfp.c | 11 +- contrib/ntp/libparse/ieee754io.c | 48 +- contrib/ntp/libparse/info_trimble.c | 6 +- contrib/ntp/libparse/mfp_mul.c | 1 + contrib/ntp/libparse/mkinfo_rcmd.sed | 8 +- contrib/ntp/libparse/mkinfo_scmd.sed | 11 +- contrib/ntp/libparse/parse.c | 136 +- contrib/ntp/libparse/parse_conf.c | 11 +- contrib/ntp/libparse/parsesolaris.c | 172 +- contrib/ntp/libparse/parsestreams.c | 172 +- contrib/ntp/libparse/trim_info.c | 3 +- contrib/ntp/ltmain.sh | 14483 +- contrib/ntp/m4/define_dir.m4 | 26 - contrib/ntp/m4/hs_ulong_const.m4 | 11 - contrib/ntp/m4/os_cflags.m4 | 87 - contrib/ntp/ntpd/Makefile.am | 496 +- contrib/ntp/ntpd/Makefile.in | 1943 +- contrib/ntp/ntpd/check_y2k.c | 1 - contrib/ntp/ntpd/cmd_args.c | 165 +- contrib/ntp/ntpd/complete.conf.in | 69 + contrib/ntp/ntpd/declcond.h | 21 + contrib/ntp/ntpd/invoke-ntp.conf.menu | 1 + contrib/ntp/ntpd/invoke-ntp.conf.texi | 2680 + contrib/ntp/ntpd/invoke-ntp.keys.menu | 1 + contrib/ntp/ntpd/invoke-ntp.keys.texi | 125 + .../ntpd/{ntpd-opts.menu => invoke-ntpd.menu} | 0 contrib/ntp/ntpd/invoke-ntpd.texi | 719 + contrib/ntp/ntpd/keyword-gen-utd | 1 + contrib/ntp/ntpd/keyword-gen.c | 755 + contrib/ntp/ntpd/ntp.conf.5man | 3055 + contrib/ntp/ntpd/ntp.conf.5mdoc | 2856 + contrib/ntp/ntpd/ntp.conf.def | 2843 + contrib/ntp/ntpd/ntp.conf.html | 2666 + contrib/ntp/ntpd/ntp.conf.man.in | 3055 + contrib/ntp/ntpd/ntp.conf.mdoc.in | 2856 + contrib/ntp/ntpd/ntp.conf.texi | 49 + contrib/ntp/ntpd/ntp.keys.5man | 173 + contrib/ntp/ntpd/ntp.keys.5mdoc | 158 + contrib/ntp/ntpd/ntp.keys.def | 152 + contrib/ntp/ntpd/ntp.keys.html | 200 + contrib/ntp/ntpd/ntp.keys.man.in | 173 + contrib/ntp/ntpd/ntp.keys.mdoc.in | 158 + contrib/ntp/ntpd/ntp.keys.texi | 49 + contrib/ntp/ntpd/ntp_config.c | 6694 +- contrib/ntp/ntpd/ntp_control.c | 4584 +- contrib/ntp/ntpd/ntp_crypto.c | 3474 +- contrib/ntp/ntpd/ntp_filegen.c | 611 +- contrib/ntp/ntpd/ntp_intres.c | 1185 - contrib/ntp/ntpd/ntp_io.c | 5431 +- contrib/ntp/ntpd/ntp_keyword.h | 1068 + contrib/ntp/ntpd/ntp_leapsec.c | 1186 + contrib/ntp/ntpd/ntp_leapsec.h | 276 + contrib/ntp/ntpd/ntp_loopfilter.c | 1271 +- contrib/ntp/ntpd/ntp_monitor.c | 576 +- contrib/ntp/ntpd/ntp_parser.c | 3657 + contrib/ntp/ntpd/ntp_parser.h | 469 + contrib/ntp/ntpd/ntp_peer.c | 1290 +- contrib/ntp/ntpd/ntp_prio_q.c | 238 + contrib/ntp/ntpd/ntp_proto.c | 4463 +- contrib/ntp/ntpd/ntp_refclock.c | 801 +- contrib/ntp/ntpd/ntp_request.c | 2022 +- contrib/ntp/ntpd/ntp_restrict.c | 996 +- contrib/ntp/ntpd/ntp_scanner.c | 935 + contrib/ntp/ntpd/ntp_scanner.h | 142 + contrib/ntp/ntpd/ntp_signd.c | 239 + contrib/ntp/ntpd/ntp_timer.c | 707 +- contrib/ntp/ntpd/ntp_util.c | 878 +- contrib/ntp/ntpd/ntpd-opts.c | 2113 +- contrib/ntp/ntpd/ntpd-opts.def | 610 +- contrib/ntp/ntpd/ntpd-opts.h | 320 +- contrib/ntp/ntpd/ntpd-opts.texi | 496 - contrib/ntp/ntpd/ntpd.1 | 296 - contrib/ntp/ntpd/ntpd.1ntpdman | 1005 + contrib/ntp/ntpd/ntpd.1ntpdmdoc | 908 + contrib/ntp/ntpd/ntpd.c | 1553 +- contrib/ntp/ntpd/ntpd.html | 1019 + contrib/ntp/ntpd/ntpd.man.in | 1005 + contrib/ntp/ntpd/ntpd.mdoc.in | 908 + contrib/ntp/ntpd/ntpd.texi | 113 + contrib/ntp/ntpd/ntpdbase-opts.def | 296 +- contrib/ntp/ntpd/ntpdsim-opts.c | 1262 - contrib/ntp/ntpd/ntpdsim-opts.def | 15 - contrib/ntp/ntpd/ntpdsim-opts.h | 422 - contrib/ntp/ntpd/ntpdsim-opts.menu | 1 - contrib/ntp/ntpd/ntpdsim-opts.texi | 568 - contrib/ntp/ntpd/ntpdsim.1 | 357 - contrib/ntp/ntpd/ntpsim.c | 856 +- contrib/ntp/ntpd/rc_cmdlength.c | 36 + contrib/ntp/ntpd/refclock_acts.c | 906 +- contrib/ntp/ntpd/refclock_arbiter.c | 106 +- contrib/ntp/ntpd/refclock_arc.c | 380 +- contrib/ntp/ntpd/refclock_as2201.c | 58 +- contrib/ntp/ntpd/refclock_atom.c | 408 +- contrib/ntp/ntpd/refclock_bancomm.c | 185 +- contrib/ntp/ntpd/refclock_chronolog.c | 46 +- contrib/ntp/ntpd/refclock_chu.c | 760 +- contrib/ntp/ntpd/refclock_conf.c | 29 +- contrib/ntp/ntpd/refclock_datum.c | 213 +- contrib/ntp/ntpd/refclock_dumbclock.c | 85 +- contrib/ntp/ntpd/refclock_fg.c | 234 +- contrib/ntp/ntpd/refclock_gpsdjson.c | 2210 + contrib/ntp/ntpd/refclock_gpsvme.c | 27 +- contrib/ntp/ntpd/refclock_heath.c | 33 +- contrib/ntp/ntpd/refclock_hopfpci.c | 51 +- contrib/ntp/ntpd/refclock_hopfser.c | 79 +- contrib/ntp/ntpd/refclock_hpgps.c | 75 +- contrib/ntp/ntpd/refclock_irig.c | 819 +- contrib/ntp/ntpd/refclock_jjy.c | 4864 +- contrib/ntp/ntpd/refclock_jupiter.c | 235 +- contrib/ntp/ntpd/refclock_leitch.c | 100 +- contrib/ntp/ntpd/refclock_local.c | 82 +- contrib/ntp/ntpd/refclock_msfees.c | 80 +- contrib/ntp/ntpd/refclock_mx4200.c | 137 +- contrib/ntp/ntpd/refclock_neoclock4x.c | 107 +- contrib/ntp/ntpd/refclock_nmea.c | 2269 +- contrib/ntp/ntpd/refclock_oncore.c | 1689 +- contrib/ntp/ntpd/refclock_palisade.c | 1078 +- contrib/ntp/ntpd/refclock_palisade.h | 72 +- contrib/ntp/ntpd/refclock_parse.c | 1720 +- contrib/ntp/ntpd/refclock_pcf.c | 19 +- contrib/ntp/ntpd/refclock_pst.c | 44 +- contrib/ntp/ntpd/refclock_ripencc.c | 3569 +- contrib/ntp/ntpd/refclock_shm.c | 696 +- contrib/ntp/ntpd/refclock_tpro.c | 46 +- contrib/ntp/ntpd/refclock_trak.c | 359 - contrib/ntp/ntpd/refclock_true.c | 424 +- contrib/ntp/ntpd/refclock_tsyncpci.c | 912 + contrib/ntp/ntpd/refclock_tt560.c | 22 +- contrib/ntp/ntpd/refclock_ulink.c | 75 +- contrib/ntp/ntpd/refclock_wwv.c | 462 +- contrib/ntp/ntpd/refclock_wwvb.c | 236 +- contrib/ntp/ntpd/refclock_zyfer.c | 67 +- contrib/ntp/ntpdate/Makefile.am | 48 +- contrib/ntp/ntpdate/Makefile.in | 744 +- contrib/ntp/ntpdate/ntpdate.c | 512 +- contrib/ntp/ntpdate/ntpdate.h | 14 +- contrib/ntp/ntpdate/ntptime_config.c | 552 - contrib/ntp/ntpdate/ntptimeset.c | 2164 - contrib/ntp/ntpdc/Makefile.am | 155 +- contrib/ntp/ntpdc/Makefile.in | 991 +- .../{ntpdc-opts.menu => invoke-ntpdc.menu} | 0 contrib/ntp/ntpdc/invoke-ntpdc.texi | 349 + contrib/ntp/ntpdc/layout.std | 28 +- contrib/ntp/ntpdc/nl.pl | 10 +- contrib/ntp/ntpdc/nl.pl.in | 10 +- contrib/ntp/ntpdc/ntpdc-layout.c | 1 + contrib/ntp/ntpdc/ntpdc-opts.c | 1378 +- contrib/ntp/ntpdc/ntpdc-opts.def | 775 +- contrib/ntp/ntpdc/ntpdc-opts.h | 274 +- contrib/ntp/ntpdc/ntpdc-opts.texi | 278 - contrib/ntp/ntpdc/ntpdc.1 | 158 - contrib/ntp/ntpdc/ntpdc.1ntpdcman | 874 + contrib/ntp/ntpdc/ntpdc.1ntpdcmdoc | 809 + contrib/ntp/ntpdc/ntpdc.c | 811 +- contrib/ntp/ntpdc/ntpdc.h | 10 +- contrib/ntp/ntpdc/ntpdc.html | 515 + contrib/ntp/ntpdc/ntpdc.man.in | 874 + contrib/ntp/ntpdc/ntpdc.mdoc.in | 809 + contrib/ntp/ntpdc/ntpdc.texi | 88 + contrib/ntp/ntpdc/ntpdc_ops.c | 1366 +- contrib/ntp/ntpq/Makefile.am | 141 +- contrib/ntp/ntpq/Makefile.in | 1027 +- .../ntpq/{ntpq-opts.menu => invoke-ntpq.menu} | 0 contrib/ntp/ntpq/invoke-ntpq.texi | 1098 + contrib/ntp/ntpq/libntpq.c | 771 + contrib/ntp/ntpq/libntpq.h | 109 + contrib/ntp/ntpq/libntpq_subs.c | 52 + contrib/ntp/ntpq/ntpq-opts.c | 1311 +- contrib/ntp/ntpq/ntpq-opts.def | 1147 +- contrib/ntp/ntpq/ntpq-opts.h | 250 +- contrib/ntp/ntpq/ntpq-opts.texi | 219 - contrib/ntp/ntpq/ntpq-subs.c | 3442 +- contrib/ntp/ntpq/ntpq.1 | 385 - contrib/ntp/ntpq/ntpq.1ntpqman | 1421 + contrib/ntp/ntpq/ntpq.1ntpqmdoc | 964 + contrib/ntp/ntpq/ntpq.c | 3077 +- contrib/ntp/ntpq/ntpq.h | 113 +- contrib/ntp/ntpq/ntpq.html | 1824 + contrib/ntp/ntpq/ntpq.man.in | 1421 + contrib/ntp/ntpq/ntpq.mdoc.in | 964 + contrib/ntp/ntpq/ntpq.texi | 834 + contrib/ntp/ntpsnmpd/Makefile.am | 117 + contrib/ntp/ntpsnmpd/Makefile.in | 1271 + contrib/ntp/ntpsnmpd/README | 40 + contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.menu | 1 + contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.texi | 188 + contrib/ntp/ntpsnmpd/netsnmp_daemonize.c | 271 + contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c | 549 + contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h | 81 + contrib/ntp/ntpsnmpd/ntp_snmp.h | 37 + contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c | 912 + contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def | 146 + contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h | 243 + contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdman | 203 + contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc | 144 + contrib/ntp/ntpsnmpd/ntpsnmpd.c | 118 + contrib/ntp/ntpsnmpd/ntpsnmpd.html | 79 + contrib/ntp/ntpsnmpd/ntpsnmpd.man.in | 203 + contrib/ntp/ntpsnmpd/ntpsnmpd.mdoc.in | 144 + contrib/ntp/ntpsnmpd/ntpsnmpd.texi | 53 + contrib/ntp/ntpsnmpd/ntpv4-mib.mib | 892 + contrib/ntp/packageinfo.sh | 116 +- contrib/ntp/parseutil/Makefile.am | 19 +- contrib/ntp/parseutil/Makefile.in | 556 +- contrib/ntp/parseutil/dcfd.c | 127 +- contrib/ntp/parseutil/testdcf.c | 28 +- contrib/ntp/readme.y2kfixes | Bin 8192 -> 4874 bytes contrib/ntp/scripts/Makefile.am | 180 +- contrib/ntp/scripts/Makefile.in | 905 +- contrib/ntp/scripts/README | 26 +- contrib/ntp/scripts/VersionName | 41 - contrib/ntp/scripts/build/Makefile.am | 17 + contrib/ntp/scripts/build/Makefile.in | 640 + contrib/ntp/scripts/build/UpdatePoint | 337 + contrib/ntp/scripts/build/VersionName | 70 + contrib/ntp/scripts/build/check--help | 22 + contrib/ntp/scripts/build/checkChangeLog | 29 + contrib/ntp/scripts/build/checkHtmlFileDates | 16 + .../scripts/{ => build}/fixautomakedepsmagic | 0 contrib/ntp/scripts/build/genCommitLog | 16 + contrib/ntp/scripts/build/genver | 96 + contrib/ntp/scripts/{ => build}/mkver.in | 10 +- contrib/ntp/scripts/build/updateBEDate | 53 + contrib/ntp/scripts/calc_tickadj.in | 38 - contrib/ntp/scripts/calc_tickadj/Makefile.am | 104 + contrib/ntp/scripts/calc_tickadj/Makefile.in | 961 + .../scripts/calc_tickadj/calc_tickadj-opts | 60 + .../calc_tickadj/calc_tickadj-opts.def | 60 + .../calc_tickadj.1calc_tickadjman | 108 + .../calc_tickadj.1calc_tickadjmdoc | 84 + .../scripts/calc_tickadj/calc_tickadj.html | 166 + .../ntp/scripts/calc_tickadj/calc_tickadj.in | 59 + .../scripts/calc_tickadj/calc_tickadj.man.in | 108 + .../scripts/calc_tickadj/calc_tickadj.mdoc.in | 84 + .../scripts/calc_tickadj/calc_tickadj.texi | 37 + .../calc_tickadj/invoke-calc_tickadj.menu | 1 + .../calc_tickadj/invoke-calc_tickadj.texi | 102 + contrib/ntp/scripts/checktime.in | 79 - .../ntp/scripts/{ => deprecated}/freq_adj.in | 0 .../ntp/scripts/{ => deprecated}/hpadjtime.sh | 0 .../ntp/scripts/{ => deprecated}/html2man.in | 148 +- .../ntp/scripts/{ => deprecated}/ntp-close | 0 .../ntp/scripts/{ => deprecated}/ntp-groper | 0 .../ntp/scripts/{ => deprecated}/ntp-restart | 0 .../ntp/scripts/{ => deprecated}/ntp-status | 0 contrib/ntp/scripts/genCommitLog | 7 - contrib/ntp/scripts/genver | 67 - contrib/ntp/scripts/invoke-plot_summary.menu | 1 + contrib/ntp/scripts/invoke-plot_summary.texi | 121 + contrib/ntp/scripts/invoke-summary.menu | 1 + contrib/ntp/scripts/invoke-summary.texi | 103 + contrib/ntp/scripts/lib/Makefile.am | 5 + contrib/ntp/scripts/lib/Makefile.in | 680 + contrib/ntp/scripts/lib/NTP/Util.pm | 155 + contrib/ntp/scripts/monitoring/ntp.pl | 81 +- contrib/ntp/scripts/monitoring/ntptrap | 10 +- contrib/ntp/scripts/ntp-wait.in | 42 - contrib/ntp/scripts/ntp-wait/Makefile.am | 96 + contrib/ntp/scripts/ntp-wait/Makefile.in | 976 + .../ntp/scripts/ntp-wait/invoke-ntp-wait.menu | 1 + .../ntp/scripts/ntp-wait/invoke-ntp-wait.texi | 114 + contrib/ntp/scripts/ntp-wait/ntp-wait-opts | 62 + .../ntp/scripts/ntp-wait/ntp-wait-opts.def | 109 + .../scripts/ntp-wait/ntp-wait.1ntp-waitman | 122 + .../scripts/ntp-wait/ntp-wait.1ntp-waitmdoc | 95 + contrib/ntp/scripts/ntp-wait/ntp-wait.html | 208 + contrib/ntp/scripts/ntp-wait/ntp-wait.in | 66 + contrib/ntp/scripts/ntp-wait/ntp-wait.man.in | 122 + contrib/ntp/scripts/ntp-wait/ntp-wait.mdoc.in | 95 + contrib/ntp/scripts/ntp-wait/ntp-wait.texi | 52 + contrib/ntp/scripts/ntpsweep.in | 300 - contrib/ntp/scripts/ntpsweep/Makefile.am | 102 + contrib/ntp/scripts/ntpsweep/Makefile.in | 982 + .../ntp/scripts/ntpsweep/invoke-ntpsweep.menu | 1 + .../ntp/scripts/ntpsweep/invoke-ntpsweep.texi | 118 + contrib/ntp/scripts/ntpsweep/ntpsweep-opts | 67 + .../ntp/scripts/ntpsweep/ntpsweep-opts.def | 66 + .../scripts/ntpsweep/ntpsweep.1ntpsweepman | 97 + .../scripts/ntpsweep/ntpsweep.1ntpsweepmdoc | 75 + contrib/ntp/scripts/ntpsweep/ntpsweep.html | 201 + contrib/ntp/scripts/ntpsweep/ntpsweep.in | 205 + contrib/ntp/scripts/ntpsweep/ntpsweep.man.in | 97 + contrib/ntp/scripts/ntpsweep/ntpsweep.mdoc.in | 75 + contrib/ntp/scripts/ntpsweep/ntpsweep.texi | 43 + contrib/ntp/scripts/ntptrace.in | 70 - contrib/ntp/scripts/ntptrace/Makefile.am | 95 + contrib/ntp/scripts/ntptrace/Makefile.in | 975 + .../ntp/scripts/ntptrace/invoke-ntptrace.menu | 1 + .../ntp/scripts/ntptrace/invoke-ntptrace.texi | 109 + contrib/ntp/scripts/ntptrace/ntptrace-opts | 62 + .../ntp/scripts/ntptrace/ntptrace-opts.def | 69 + .../scripts/ntptrace/ntptrace.1ntptraceman | 114 + .../scripts/ntptrace/ntptrace.1ntptracemdoc | 91 + contrib/ntp/scripts/ntptrace/ntptrace.html | 180 + contrib/ntp/scripts/ntptrace/ntptrace.in | 80 + contrib/ntp/scripts/ntptrace/ntptrace.man.in | 114 + contrib/ntp/scripts/ntptrace/ntptrace.mdoc.in | 91 + contrib/ntp/scripts/ntptrace/ntptrace.texi | 40 + contrib/ntp/scripts/ntpver.in | 4 +- contrib/ntp/scripts/plot_summary-opts | 73 + contrib/ntp/scripts/plot_summary-opts.def | 83 + .../ntp/scripts/plot_summary.1plot_summaryman | 114 + .../scripts/plot_summary.1plot_summarymdoc | 88 + contrib/ntp/scripts/plot_summary.html | 207 + contrib/ntp/scripts/plot_summary.in | 90 +- contrib/ntp/scripts/plot_summary.man.in | 114 + contrib/ntp/scripts/plot_summary.mdoc.in | 88 + contrib/ntp/scripts/plot_summary.texi | 40 + contrib/ntp/scripts/rc/README | 13 + contrib/ntp/scripts/rc/ntpd | 88 + contrib/ntp/scripts/rc/ntpwait | 15 + contrib/ntp/scripts/rc/rc.d/TIMESYNC | 8 + contrib/ntp/scripts/rc/rc.d/ntpd | 32 + contrib/ntp/scripts/rc/rc.d/ntpwait | 21 + contrib/ntp/scripts/rc1/postinstall | 2 - contrib/ntp/scripts/rc1/preinstall | 6 - contrib/ntp/scripts/rc1/preremove | 4 - contrib/ntp/scripts/rc1/prototype | 19 - contrib/ntp/scripts/rc1/xntp | 29 - contrib/ntp/scripts/rc2/local.ntpd | 64 - contrib/ntp/scripts/summary-opts | 69 + contrib/ntp/scripts/summary-opts.def | 82 + contrib/ntp/scripts/summary.1summaryman | 123 + contrib/ntp/scripts/summary.1summarymdoc | 98 + contrib/ntp/scripts/summary.html | 182 + contrib/ntp/scripts/summary.in | 162 +- contrib/ntp/scripts/summary.man.in | 123 + contrib/ntp/scripts/summary.mdoc.in | 98 + contrib/ntp/scripts/summary.texi | 40 + contrib/ntp/scripts/update-leap/Makefile.am | 98 + contrib/ntp/scripts/update-leap/Makefile.in | 978 + .../update-leap/invoke-update-leap.menu | 1 + .../update-leap/invoke-update-leap.texi | 219 + .../ntp/scripts/update-leap/update-leap-opts | 72 + .../scripts/update-leap/update-leap-opts.def | 163 + .../update-leap/update-leap.1update-leapman | 169 + .../update-leap/update-leap.1update-leapmdoc | 134 + .../ntp/scripts/update-leap/update-leap.html | 323 + .../ntp/scripts/update-leap/update-leap.in | 424 + .../scripts/update-leap/update-leap.man.in | 169 + .../scripts/update-leap/update-leap.mdoc.in | 134 + .../ntp/scripts/update-leap/update-leap.sh | 434 + .../ntp/scripts/update-leap/update-leap.texi | 43 + contrib/ntp/sntp/COPYRIGHT | 309 +- contrib/ntp/sntp/Makefile.am | 310 +- contrib/ntp/sntp/Makefile.in | 1318 +- contrib/ntp/sntp/README | 536 - contrib/ntp/sntp/aclocal.m4 | 7093 +- contrib/ntp/sntp/ag-tpl/0-old/Mdoc.pm | 515 + contrib/ntp/sntp/ag-tpl/0-old/agman-cmd.tpl | 58 + contrib/ntp/sntp/ag-tpl/0-old/agmdoc-cmd.tpl | 46 + contrib/ntp/sntp/ag-tpl/0-old/cmd-doc.tlib | 1079 + .../ntp/sntp/ag-tpl/0-old/mdoc-synopsis.tlib | 92 + contrib/ntp/sntp/ag-tpl/0-old/mdoc2man | 193 + contrib/ntp/sntp/ag-tpl/0-old/mdoc2texi | 162 + contrib/ntp/sntp/ag-tpl/0-old/perlopt.tpl | 188 + contrib/ntp/sntp/ag-tpl/Mdoc.pm | 542 + contrib/ntp/sntp/ag-tpl/mdoc2man | 219 + contrib/ntp/sntp/autogen-version.def | 2 - contrib/ntp/sntp/bincheck.mf | 16 +- contrib/ntp/sntp/check-libntp.mf | 15 + contrib/ntp/sntp/check-libopts.mf | 14 + contrib/ntp/sntp/config.guess | 502 +- contrib/ntp/sntp/config.h.in | 766 +- contrib/ntp/sntp/config.sub | 337 +- contrib/ntp/sntp/configure | 38314 ++- contrib/ntp/sntp/configure.ac | 239 +- contrib/ntp/sntp/crypto.c | 192 + contrib/ntp/sntp/crypto.h | 32 + contrib/ntp/sntp/data_formats.h | 8 + contrib/ntp/sntp/deps-ver | 1 + contrib/ntp/sntp/depsver.mf | 60 + contrib/ntp/sntp/header.h | 87 - contrib/ntp/sntp/include/Makefile.am | 19 + contrib/ntp/sntp/include/Makefile.in | 597 + contrib/ntp/sntp/include/autogen-version.def | 4 + contrib/ntp/sntp/include/copyright.def | 30 + contrib/ntp/sntp/include/debug-opt.def | 29 + contrib/ntp/{ => sntp}/include/homerc.def | 0 contrib/ntp/sntp/include/ntp.lic | 18 + contrib/ntp/sntp/include/version.def | 1 + contrib/ntp/sntp/include/version.texi | 3 + contrib/ntp/sntp/includes.mf | 6 + contrib/ntp/sntp/internet.c | 207 - contrib/ntp/sntp/internet.h | 47 - .../sntp/{sntp-opts.menu => invoke-sntp.menu} | 0 contrib/ntp/sntp/invoke-sntp.texi | 430 + contrib/ntp/sntp/kludges.h | 62 - contrib/ntp/sntp/kod_management.c | 301 + contrib/ntp/sntp/kod_management.h | 20 + contrib/ntp/sntp/libevent/ChangeLog | 1402 + contrib/ntp/sntp/libevent/ChangeLog-1.4 | 231 + contrib/ntp/sntp/libevent/ChangeLog-2.0 | 1280 + contrib/ntp/sntp/libevent/Doxyfile | 257 + contrib/ntp/sntp/libevent/LICENSE | 99 + contrib/ntp/sntp/libevent/Makefile.am | 303 + contrib/ntp/sntp/libevent/Makefile.in | 2473 + contrib/ntp/sntp/libevent/Makefile.nmake | 82 + .../WIN32-Code/nmake/evconfig-private.h | 6 + .../WIN32-Code/nmake/event2/event-config.h | 360 + contrib/ntp/sntp/libevent/WIN32-Code/tree.h | 677 + .../ntp/{arlib => sntp/libevent}/aclocal.m4 | 833 +- contrib/ntp/sntp/libevent/arc4random.c | 556 + contrib/ntp/sntp/libevent/autogen.sh | 15 + contrib/ntp/sntp/libevent/buffer.c | 3439 + contrib/ntp/sntp/libevent/buffer_iocp.c | 326 + .../ntp/sntp/libevent/bufferevent-internal.h | 450 + contrib/ntp/sntp/libevent/bufferevent.c | 989 + contrib/ntp/sntp/libevent/bufferevent_async.c | 686 + .../ntp/sntp/libevent/bufferevent_filter.c | 545 + .../ntp/sntp/libevent/bufferevent_openssl.c | 1504 + contrib/ntp/sntp/libevent/bufferevent_pair.c | 358 + .../ntp/sntp/libevent/bufferevent_ratelim.c | 1092 + contrib/ntp/sntp/libevent/bufferevent_sock.c | 709 + contrib/ntp/sntp/libevent/build-aux/ar-lib | 270 + contrib/ntp/sntp/libevent/build-aux/compile | 143 + .../ntp/sntp/libevent/build-aux/config.guess | 1517 + .../ntp/sntp/libevent/build-aux/config.sub | 1756 + .../libevent/build-aux}/depcomp | 172 +- .../ntp/sntp/libevent/build-aux/install-sh | 520 + contrib/ntp/sntp/libevent/build-aux/ltmain.sh | 9655 + .../libevent/build-aux}/missing | 104 +- .../ntp/sntp/libevent/build-aux/test-driver | 148 + contrib/ntp/sntp/libevent/build-aux/ylwrap | 222 + .../ntp/sntp/libevent/changelist-internal.h | 102 + contrib/ntp/sntp/libevent/compat/sys/queue.h | 488 + contrib/ntp/sntp/libevent/config.h.in | 524 + contrib/ntp/sntp/libevent/configure | 18025 ++ contrib/ntp/sntp/libevent/configure.ac | 916 + contrib/ntp/sntp/libevent/defer-internal.h | 70 + contrib/ntp/sntp/libevent/devpoll.c | 311 + contrib/ntp/sntp/libevent/epoll.c | 541 + contrib/ntp/sntp/libevent/epoll_sub.c | 66 + .../ntp/sntp/libevent/epolltable-internal.h | 1166 + contrib/ntp/sntp/libevent/evbuffer-internal.h | 351 + contrib/ntp/sntp/libevent/evconfig-private.h | 49 + .../ntp/sntp/libevent/evconfig-private.h.in | 48 + contrib/ntp/sntp/libevent/evdns.c | 4756 + contrib/ntp/sntp/libevent/event-internal.h | 474 + contrib/ntp/sntp/libevent/event.c | 3890 + contrib/ntp/sntp/libevent/event_iocp.c | 294 + contrib/ntp/sntp/libevent/event_rpcgen.py | 1728 + contrib/ntp/sntp/libevent/event_tagging.c | 604 + contrib/ntp/sntp/libevent/evmap-internal.h | 117 + contrib/ntp/sntp/libevent/evmap.c | 1055 + contrib/ntp/sntp/libevent/evport.c | 451 + contrib/ntp/sntp/libevent/evrpc-internal.h | 205 + contrib/ntp/sntp/libevent/evrpc.c | 1171 + contrib/ntp/sntp/libevent/evsignal-internal.h | 65 + contrib/ntp/sntp/libevent/evthread-internal.h | 392 + contrib/ntp/sntp/libevent/evthread.c | 475 + contrib/ntp/sntp/libevent/evthread_pthread.c | 191 + contrib/ntp/sntp/libevent/evthread_win32.c | 341 + contrib/ntp/sntp/libevent/evutil.c | 2663 + contrib/ntp/sntp/libevent/evutil_rand.c | 206 + contrib/ntp/sntp/libevent/evutil_time.c | 538 + contrib/ntp/sntp/libevent/ht-internal.h | 487 + contrib/ntp/sntp/libevent/http-internal.h | 206 + contrib/ntp/sntp/libevent/http.c | 4857 + contrib/ntp/sntp/libevent/include/evdns.h | 45 + contrib/ntp/sntp/libevent/include/event.h | 85 + .../ntp/sntp/libevent/include/event2/buffer.h | 1076 + .../libevent/include/event2/buffer_compat.h | 115 + .../libevent/include/event2/bufferevent.h | 995 + .../include/event2/bufferevent_compat.h | 100 + .../libevent/include/event2/bufferevent_ssl.h | 134 + .../include/event2/bufferevent_struct.h | 116 + .../ntp/sntp/libevent/include/event2/dns.h | 717 + .../sntp/libevent/include/event2/dns_compat.h | 336 + .../sntp/libevent/include/event2/dns_struct.h | 80 + .../ntp/sntp/libevent/include/event2/event.h | 1679 + .../libevent/include/event2/event_compat.h | 230 + .../libevent/include/event2/event_struct.h | 180 + .../ntp/sntp/libevent/include/event2/http.h | 1154 + .../libevent/include/event2/http_compat.h | 90 + .../libevent/include/event2/http_struct.h | 152 + .../libevent/include/event2/keyvalq_struct.h | 80 + .../sntp/libevent/include/event2/listener.h | 180 + .../ntp/sntp/libevent/include/event2/rpc.h | 596 + .../sntp/libevent/include/event2/rpc_compat.h | 61 + .../sntp/libevent/include/event2/rpc_struct.h | 100 + .../ntp/sntp/libevent/include/event2/tag.h | 146 + .../sntp/libevent/include/event2/tag_compat.h | 49 + .../ntp/sntp/libevent/include/event2/thread.h | 253 + .../ntp/sntp/libevent/include/event2/util.h | 837 + .../sntp/libevent/include/event2/visibility.h | 55 + contrib/ntp/sntp/libevent/include/evhttp.h | 45 + contrib/ntp/sntp/libevent/include/evrpc.h | 45 + contrib/ntp/sntp/libevent/include/evutil.h | 39 + contrib/ntp/sntp/libevent/include/include.am | 46 + contrib/ntp/sntp/libevent/iocp-internal.h | 201 + contrib/ntp/sntp/libevent/ipv6-internal.h | 83 + contrib/ntp/sntp/libevent/kqueue-internal.h | 39 + contrib/ntp/sntp/libevent/kqueue.c | 566 + contrib/ntp/sntp/libevent/libevent.pc.in | 16 + .../ntp/sntp/libevent/libevent_openssl.pc.in | 16 + .../ntp/sntp/libevent/libevent_pthreads.pc.in | 16 + contrib/ntp/sntp/libevent/listener.c | 889 + contrib/ntp/sntp/libevent/log-internal.h | 83 + contrib/ntp/sntp/libevent/log.c | 253 + .../libevent/m4/ac_backport_259_ssizet.m4 | 3 + contrib/ntp/sntp/libevent/m4/acx_pthread.m4 | 279 + .../ntp/sntp/libevent/m4/libevent_openssl.m4 | 47 + contrib/ntp/sntp/libevent/m4/libtool.m4 | 7831 + contrib/ntp/sntp/libevent/m4/ltoptions.m4 | 369 + contrib/ntp/sntp/libevent/m4/ltsugar.m4 | 123 + contrib/ntp/sntp/libevent/m4/ltversion.m4 | 23 + contrib/ntp/sntp/libevent/m4/lt~obsolete.m4 | 98 + .../ntp/sntp/libevent/m4/ntp_pkg_config.m4 | 27 + .../ntp/sntp/libevent/make-event-config.sed | 23 + contrib/ntp/sntp/libevent/minheap-internal.h | 188 + contrib/ntp/sntp/libevent/mm-internal.h | 87 + contrib/ntp/sntp/libevent/poll.c | 341 + contrib/ntp/sntp/libevent/ratelim-internal.h | 105 + contrib/ntp/sntp/libevent/select.c | 346 + contrib/ntp/sntp/libevent/signal.c | 479 + contrib/ntp/sntp/libevent/strlcpy-internal.h | 22 + contrib/ntp/sntp/libevent/strlcpy.c | 75 + contrib/ntp/sntp/libevent/test/Makefile.nmake | 79 + contrib/ntp/sntp/libevent/test/bench.c | 207 + .../ntp/sntp/libevent/test/bench_cascade.c | 188 + contrib/ntp/sntp/libevent/test/bench_http.c | 195 + .../ntp/sntp/libevent/test/bench_httpclient.c | 234 + .../sntp/libevent/test/check-dumpevents.py | 54 + contrib/ntp/sntp/libevent/test/include.am | 146 + contrib/ntp/sntp/libevent/test/regress.c | 3334 + contrib/ntp/sntp/libevent/test/regress.gen.c | 1 + contrib/ntp/sntp/libevent/test/regress.gen.h | 1 + contrib/ntp/sntp/libevent/test/regress.h | 136 + contrib/ntp/sntp/libevent/test/regress.rpc | 25 + .../ntp/sntp/libevent/test/regress_buffer.c | 2281 + .../sntp/libevent/test/regress_bufferevent.c | 1162 + contrib/ntp/sntp/libevent/test/regress_dns.c | 2050 + contrib/ntp/sntp/libevent/test/regress_et.c | 208 + .../ntp/sntp/libevent/test/regress_finalize.c | 347 + contrib/ntp/sntp/libevent/test/regress_http.c | 3995 + contrib/ntp/sntp/libevent/test/regress_iocp.c | 352 + .../ntp/sntp/libevent/test/regress_listener.c | 214 + contrib/ntp/sntp/libevent/test/regress_main.c | 466 + .../ntp/sntp/libevent/test/regress_minheap.c | 100 + contrib/ntp/sntp/libevent/test/regress_rpc.c | 905 + contrib/ntp/sntp/libevent/test/regress_ssl.c | 478 + .../sntp/libevent/test/regress_testutils.c | 219 + .../sntp/libevent/test/regress_testutils.h | 66 + .../ntp/sntp/libevent/test/regress_thread.c | 585 + .../ntp/sntp/libevent/test/regress_thread.h | 48 + contrib/ntp/sntp/libevent/test/regress_util.c | 1413 + contrib/ntp/sntp/libevent/test/regress_zlib.c | 348 + .../ntp/sntp/libevent/test/rpcgen_wrapper.sh | 52 + .../ntp/sntp/libevent/test/test-changelist.c | 224 + contrib/ntp/sntp/libevent/test/test-closed.c | 117 + .../ntp/sntp/libevent/test/test-dumpevents.c | 179 + contrib/ntp/sntp/libevent/test/test-eof.c | 124 + contrib/ntp/sntp/libevent/test/test-fdleak.c | 249 + contrib/ntp/sntp/libevent/test/test-init.c | 65 + contrib/ntp/sntp/libevent/test/test-ratelim.c | 605 + contrib/ntp/sntp/libevent/test/test-time.c | 117 + contrib/ntp/sntp/libevent/test/test-weof.c | 117 + contrib/ntp/sntp/libevent/test/test.sh | 144 + contrib/ntp/sntp/libevent/test/tinytest.c | 493 + contrib/ntp/sntp/libevent/test/tinytest.h | 100 + .../ntp/sntp/libevent/test/tinytest_local.h | 12 + .../ntp/sntp/libevent/test/tinytest_macros.h | 199 + contrib/ntp/sntp/libevent/time-internal.h | 98 + contrib/ntp/sntp/libevent/util-internal.h | 479 + contrib/ntp/sntp/libevent/whatsnew-2.0.txt | 609 + contrib/ntp/sntp/libevent/whatsnew-2.1.txt | 690 + contrib/ntp/sntp/libevent/win32select.c | 388 + contrib/ntp/sntp/libopts/COPYING.gplv3 | 674 + contrib/ntp/sntp/libopts/COPYING.lgpl | 502 - contrib/ntp/sntp/libopts/COPYING.lgplv3 | 165 + contrib/ntp/sntp/libopts/COPYING.mbsd | 1 + contrib/ntp/sntp/libopts/Makefile.am | 64 +- contrib/ntp/sntp/libopts/Makefile.in | 527 +- contrib/ntp/sntp/libopts/README | 99 +- contrib/ntp/sntp/libopts/ag-char-map.h | 526 + contrib/ntp/sntp/libopts/alias.c | 116 + contrib/ntp/sntp/libopts/ao-strs.c | 374 + contrib/ntp/sntp/libopts/ao-strs.h | 330 + contrib/ntp/sntp/libopts/autoopts.c | 1035 +- contrib/ntp/sntp/libopts/autoopts.h | 379 +- contrib/ntp/sntp/libopts/autoopts/options.h | 1406 +- contrib/ntp/sntp/libopts/autoopts/project.h | 77 + contrib/ntp/sntp/libopts/autoopts/usage-txt.h | 954 +- contrib/ntp/sntp/libopts/boolean.c | 101 +- contrib/ntp/sntp/libopts/check.c | 177 + contrib/ntp/sntp/libopts/compat/_Noreturn.h | 10 + contrib/ntp/sntp/libopts/compat/compat.h | 132 +- contrib/ntp/sntp/libopts/compat/pathfind.c | 171 +- contrib/ntp/sntp/libopts/compat/snprintf.c | 2 + contrib/ntp/sntp/libopts/compat/strchr.c | 18 +- contrib/ntp/sntp/libopts/compat/strdup.c | 3 + .../ntp/sntp/libopts/compat/windows-config.h | 112 +- contrib/ntp/sntp/libopts/configfile.c | 1475 +- contrib/ntp/sntp/libopts/cook.c | 339 +- contrib/ntp/sntp/libopts/enum.c | 652 + contrib/ntp/sntp/libopts/enumeration.c | 498 - contrib/ntp/sntp/libopts/env.c | 267 + contrib/ntp/sntp/libopts/environment.c | 279 - contrib/ntp/sntp/libopts/file.c | 201 + contrib/ntp/sntp/libopts/find.c | 780 + contrib/ntp/sntp/libopts/genshell.c | 909 +- contrib/ntp/sntp/libopts/genshell.h | 250 +- contrib/ntp/sntp/libopts/gettext.h | 288 + contrib/ntp/sntp/libopts/init.c | 294 + contrib/ntp/sntp/libopts/intprops.h | 320 + contrib/ntp/sntp/libopts/libopts.c | 28 +- contrib/ntp/sntp/libopts/load.c | 563 +- contrib/ntp/sntp/libopts/m4/libopts.m4 | 371 +- contrib/ntp/sntp/libopts/m4/liboptschk.m4 | 55 +- contrib/ntp/sntp/libopts/m4/stdnoreturn.m4 | 41 + contrib/ntp/sntp/libopts/makeshell.c | 1314 +- contrib/ntp/sntp/libopts/nested.c | 1009 +- contrib/ntp/sntp/libopts/numeric.c | 198 +- contrib/ntp/sntp/libopts/option-value-type.c | 156 + contrib/ntp/sntp/libopts/option-value-type.h | 60 + .../ntp/sntp/libopts/option-xat-attribute.c | 148 + .../ntp/sntp/libopts/option-xat-attribute.h | 57 + contrib/ntp/sntp/libopts/parse-duration.c | 604 + contrib/ntp/sntp/libopts/parse-duration.h | 90 + contrib/ntp/sntp/libopts/pgusage.c | 208 +- contrib/ntp/sntp/libopts/proto.h | 223 +- contrib/ntp/sntp/libopts/putshell.c | 526 +- contrib/ntp/sntp/libopts/reset.c | 141 + contrib/ntp/sntp/libopts/restore.c | 141 +- contrib/ntp/sntp/libopts/save.c | 818 +- contrib/ntp/sntp/libopts/sort.c | 207 +- contrib/ntp/sntp/libopts/stack.c | 174 +- contrib/ntp/sntp/libopts/stdnoreturn.in.h | 50 + contrib/ntp/sntp/libopts/streqvcmp.c | 153 +- contrib/ntp/sntp/libopts/text_mmap.c | 526 +- contrib/ntp/sntp/libopts/time.c | 143 + contrib/ntp/sntp/libopts/tokenize.c | 280 +- contrib/ntp/sntp/libopts/usage.c | 1270 +- contrib/ntp/sntp/libopts/version.c | 289 +- contrib/ntp/sntp/libpkgver/colcomp.c | 135 + contrib/ntp/sntp/libpkgver/pkgver.h | 19 + contrib/ntp/sntp/loc/README | 17 + contrib/ntp/sntp/loc/darwin | 15 + contrib/ntp/sntp/loc/debian | 18 + contrib/ntp/sntp/loc/freebsd | 15 + contrib/ntp/sntp/loc/legacy | 18 + contrib/ntp/sntp/loc/netbsd | 15 + contrib/ntp/sntp/loc/redhat | 17 + contrib/ntp/sntp/loc/solaris | 17 + contrib/ntp/sntp/log.c | 47 + contrib/ntp/sntp/log.h | 27 + contrib/ntp/sntp/ltmain.sh | 14483 +- contrib/ntp/sntp/m4/ax_c99_struct_init.m4 | 59 + contrib/ntp/sntp/m4/define_dir.m4 | 35 + contrib/ntp/sntp/m4/hms_search_lib.m4 | 30 + contrib/ntp/sntp/m4/libtool.m4 | 7831 + contrib/ntp/sntp/m4/ltoptions.m4 | 369 + contrib/ntp/sntp/m4/ltsugar.m4 | 123 + contrib/ntp/sntp/m4/ltversion.m4 | 23 + contrib/ntp/sntp/m4/lt~obsolete.m4 | 98 + contrib/ntp/sntp/m4/ntp_cacheversion.m4 | 129 + contrib/ntp/sntp/m4/ntp_compiler.m4 | 196 + contrib/ntp/sntp/m4/ntp_crosscompile.m4 | 8 + contrib/ntp/sntp/m4/ntp_crypto_rand.m4 | 53 + contrib/ntp/sntp/m4/ntp_debug.m4 | 22 + contrib/ntp/sntp/m4/ntp_dir_sep.m4 | 24 + contrib/ntp/sntp/m4/ntp_facilitynames.m4 | 24 + contrib/ntp/sntp/m4/ntp_googletest.m4 | 53 + contrib/ntp/sntp/m4/ntp_ipv6.m4 | 528 + contrib/ntp/sntp/m4/ntp_lib_m.m4 | 17 + contrib/ntp/sntp/m4/ntp_libevent.m4 | 192 + contrib/ntp/sntp/m4/ntp_libntp.m4 | 1141 + contrib/ntp/sntp/m4/ntp_lineeditlibs.m4 | 136 + contrib/ntp/sntp/m4/ntp_locinfo.m4 | 135 + contrib/ntp/sntp/m4/ntp_openssl.m4 | 381 + contrib/ntp/sntp/m4/ntp_pkg_config.m4 | 27 + contrib/ntp/sntp/m4/ntp_problemtests.m4 | 56 + contrib/ntp/sntp/m4/ntp_prog_cc.m4 | 21 + contrib/ntp/sntp/m4/ntp_rlimit.m4 | 125 + contrib/ntp/sntp/m4/ntp_sntp.m4 | 29 + contrib/ntp/sntp/m4/ntp_sysexits.m4 | 11 + contrib/ntp/sntp/m4/ntp_unitytest.m4 | 19 + contrib/ntp/sntp/m4/ntp_ver_suffix.m4 | 13 + contrib/ntp/sntp/m4/ntp_vpathhack.m4 | 43 + contrib/ntp/sntp/m4/openldap-thread-check.m4 | 692 + contrib/ntp/sntp/m4/openldap.m4 | 1131 + contrib/ntp/sntp/m4/os_cflags.m4 | 134 + contrib/ntp/sntp/m4/snprintf.m4 | 288 + contrib/ntp/sntp/m4/version.m4 | 1 + contrib/ntp/sntp/main.c | 3193 +- contrib/ntp/sntp/main.h | 31 + contrib/ntp/sntp/networking.c | 287 + contrib/ntp/sntp/networking.h | 110 + contrib/ntp/sntp/scm-rev | 1 + contrib/ntp/sntp/scripts/Makefile.am | 7 + contrib/ntp/sntp/scripts/Makefile.in | 583 + contrib/ntp/sntp/scripts/cvo.sh | 156 + contrib/ntp/sntp/scripts/genLocInfo | 264 + contrib/ntp/sntp/scripts/mansec2subst.sed | 28 + contrib/ntp/sntp/sntp-opts.c | 1838 +- contrib/ntp/sntp/sntp-opts.def | 555 +- contrib/ntp/sntp/sntp-opts.h | 445 +- contrib/ntp/sntp/sntp-opts.texi | 225 - contrib/ntp/sntp/sntp.1 | 400 - contrib/ntp/sntp/sntp.1sntpman | 357 + contrib/ntp/sntp/sntp.1sntpmdoc | 312 + contrib/ntp/sntp/sntp.c | 12 + contrib/ntp/sntp/sntp.html | 624 + contrib/ntp/sntp/sntp.man.in | 357 + contrib/ntp/sntp/sntp.mdoc.in | 312 + contrib/ntp/sntp/sntp.texi | 88 + contrib/ntp/sntp/socket.c | 385 - contrib/ntp/sntp/tests/Makefile.am | 250 + contrib/ntp/sntp/tests/Makefile.in | 1606 + contrib/ntp/sntp/tests/crypto.c | 149 + .../ntp/sntp/tests/data/debug-input-lfp-bin | 3 + .../ntp/sntp/tests/data/debug-input-lfp-dec | 3 + contrib/ntp/sntp/tests/data/debug-input-pkt | 8 + contrib/ntp/sntp/tests/data/key-test-ascii | 2 + contrib/ntp/sntp/tests/data/key-test-comments | 3 + .../tests/data/key-test-empty} | 0 contrib/ntp/sntp/tests/data/key-test-hex | 3 + .../ntp/sntp/tests/data/key-test-invalid-hex | 2 + .../ntp/sntp/tests/data/kod-expected-multiple | 3 + .../ntp/sntp/tests/data/kod-expected-single | 1 + contrib/ntp/sntp/tests/data/kod-test-blanks | 6 + contrib/ntp/sntp/tests/data/kod-test-correct | 2 + contrib/ntp/sntp/tests/data/kod-test-empty | 0 contrib/ntp/sntp/tests/fileHandlingTest.c | 74 + contrib/ntp/sntp/tests/fileHandlingTest.h.in | 35 + contrib/ntp/sntp/tests/keyFile.c | 157 + contrib/ntp/sntp/tests/kodDatabase.c | 139 + contrib/ntp/sntp/tests/kodFile.c | 155 + contrib/ntp/sntp/tests/networking.c | 7 + contrib/ntp/sntp/tests/packetHandling.c | 302 + contrib/ntp/sntp/tests/packetProcessing.c | 405 + contrib/ntp/sntp/tests/run-crypto.c | 65 + contrib/ntp/sntp/tests/run-keyFile.c | 64 + contrib/ntp/sntp/tests/run-kodDatabase.c | 66 + contrib/ntp/sntp/tests/run-kodFile.c | 66 + contrib/ntp/sntp/tests/run-networking.c | 52 + contrib/ntp/sntp/tests/run-packetHandling.c | 78 + contrib/ntp/sntp/tests/run-packetProcessing.c | 89 + contrib/ntp/sntp/tests/run-t-log.c | 57 + contrib/ntp/sntp/tests/run-utilities.c | 69 + contrib/ntp/sntp/tests/sntptest.c | 33 + contrib/ntp/sntp/tests/sntptest.h | 11 + contrib/ntp/sntp/tests/t-log.c | 68 + contrib/ntp/sntp/tests/tests-runner | 13 + contrib/ntp/sntp/tests/utilities.c | 205 + contrib/ntp/sntp/timing.c | 112 - contrib/ntp/sntp/unity/Makefile.am | 26 + contrib/ntp/sntp/unity/Makefile.in | 861 + contrib/ntp/sntp/unity/auto/colour_prompt.rb | 94 + .../ntp/sntp/unity/auto/colour_reporter.rb | 39 + .../ntp/sntp/unity/auto/generate_config.yml | 36 + .../ntp/sntp/unity/auto/generate_module.rb | 202 + .../sntp/unity/auto/generate_test_runner.rb | 408 + contrib/ntp/sntp/unity/auto/parseOutput.rb | 191 + contrib/ntp/sntp/unity/auto/runner_maybe.c | 52 + .../ntp/sntp/unity/auto/test_file_filter.rb | 23 + contrib/ntp/sntp/unity/auto/type_sanitizer.rb | 8 + .../ntp/sntp/unity/auto/unity_test_summary.py | 135 + .../ntp/sntp/unity/auto/unity_test_summary.rb | 149 + contrib/ntp/sntp/unity/unity.c | 1280 + contrib/ntp/sntp/unity/unity.h | 272 + contrib/ntp/sntp/unity/unity_config.h | 12 + contrib/ntp/sntp/unity/unity_fixture.c | 398 + contrib/ntp/sntp/unity/unity_fixture.h | 86 + .../ntp/sntp/unity/unity_fixture_internals.h | 44 + .../unity/unity_fixture_malloc_overrides.h | 21 + contrib/ntp/sntp/unity/unity_internals.h | 703 + contrib/ntp/sntp/unix.c | 92 - contrib/ntp/sntp/utilities.c | 209 + contrib/ntp/sntp/utilities.h | 27 + contrib/ntp/sntp/version.c | 5 + contrib/ntp/sntp/version.def | 1 - contrib/ntp/tests/Makefile.am | 12 + contrib/ntp/tests/Makefile.in | 801 + contrib/ntp/tests/bug-2803/Makefile.am | 72 + contrib/ntp/tests/bug-2803/Makefile.in | 1267 + contrib/ntp/tests/bug-2803/bug-2803.c | 123 + contrib/ntp/tests/bug-2803/run-bug-2803.c | 56 + contrib/ntp/tests/libntp/Makefile.am | 556 + contrib/ntp/tests/libntp/Makefile.in | 2701 + contrib/ntp/tests/libntp/a_md5encrypt.c | 109 + contrib/ntp/tests/libntp/atoint.c | 60 + contrib/ntp/tests/libntp/atouint.c | 51 + contrib/ntp/tests/libntp/authkeys.c | 134 + contrib/ntp/tests/libntp/buftvtots.c | 85 + contrib/ntp/tests/libntp/calendar.c | 541 + contrib/ntp/tests/libntp/caljulian.c | 128 + contrib/ntp/tests/libntp/caltontp.c | 53 + contrib/ntp/tests/libntp/calyearstart.c | 49 + contrib/ntp/tests/libntp/clocktime.c | 222 + contrib/ntp/tests/libntp/decodenetnum.c | 130 + contrib/ntp/tests/libntp/hextoint.c | 53 + contrib/ntp/tests/libntp/hextolfp.c | 75 + contrib/ntp/tests/libntp/humandate.c | 42 + contrib/ntp/tests/libntp/lfpfunc.c | 504 + contrib/ntp/tests/libntp/lfptest.c | 11 + contrib/ntp/tests/libntp/lfptest.h | 16 + contrib/ntp/tests/libntp/lfptostr.c | 125 + contrib/ntp/tests/libntp/modetoa.c | 23 + contrib/ntp/tests/libntp/msyslog.c | 154 + contrib/ntp/tests/libntp/netof.c | 82 + contrib/ntp/tests/libntp/numtoa.c | 25 + contrib/ntp/tests/libntp/numtohost.c | 20 + contrib/ntp/tests/libntp/octtoint.c | 74 + contrib/ntp/tests/libntp/prettydate.c | 20 + contrib/ntp/tests/libntp/recvbuff.c | 46 + contrib/ntp/tests/libntp/refidsmear.c | 144 + contrib/ntp/tests/libntp/refnumtoa.c | 66 + contrib/ntp/tests/libntp/run-a_md5encrypt.c | 62 + contrib/ntp/tests/libntp/run-atoint.c | 64 + contrib/ntp/tests/libntp/run-atouint.c | 63 + contrib/ntp/tests/libntp/run-authkeys.c | 65 + contrib/ntp/tests/libntp/run-buftvtots.c | 63 + contrib/ntp/tests/libntp/run-calendar.c | 83 + contrib/ntp/tests/libntp/run-caljulian.c | 62 + contrib/ntp/tests/libntp/run-caltontp.c | 59 + contrib/ntp/tests/libntp/run-calyearstart.c | 59 + contrib/ntp/tests/libntp/run-clocktime.c | 69 + contrib/ntp/tests/libntp/run-decodenetnum.c | 64 + contrib/ntp/tests/libntp/run-hextoint.c | 63 + contrib/ntp/tests/libntp/run-hextolfp.c | 65 + contrib/ntp/tests/libntp/run-humandate.c | 56 + contrib/ntp/tests/libntp/run-lfpfunc.c | 72 + contrib/ntp/tests/libntp/run-lfptostr.c | 74 + contrib/ntp/tests/libntp/run-modetoa.c | 55 + contrib/ntp/tests/libntp/run-msyslog.c | 67 + contrib/ntp/tests/libntp/run-netof.c | 61 + contrib/ntp/tests/libntp/run-numtoa.c | 56 + contrib/ntp/tests/libntp/run-numtohost.c | 54 + contrib/ntp/tests/libntp/run-octtoint.c | 65 + contrib/ntp/tests/libntp/run-prettydate.c | 55 + contrib/ntp/tests/libntp/run-recvbuff.c | 57 + contrib/ntp/tests/libntp/run-refidsmear.c | 56 + contrib/ntp/tests/libntp/run-refnumtoa.c | 56 + contrib/ntp/tests/libntp/run-sfptostr.c | 67 + contrib/ntp/tests/libntp/run-socktoa.c | 65 + contrib/ntp/tests/libntp/run-ssl_init.c | 61 + contrib/ntp/tests/libntp/run-statestr.c | 61 + contrib/ntp/tests/libntp/run-strtolfp.c | 67 + contrib/ntp/tests/libntp/run-timespecops.c | 111 + contrib/ntp/tests/libntp/run-timevalops.c | 110 + contrib/ntp/tests/libntp/run-tstotv.c | 58 + contrib/ntp/tests/libntp/run-tvtots.c | 59 + contrib/ntp/tests/libntp/run-uglydate.c | 54 + contrib/ntp/tests/libntp/run-vi64ops.c | 58 + contrib/ntp/tests/libntp/run-ymd2yd.c | 59 + contrib/ntp/tests/libntp/sfptostr.c | 83 + contrib/ntp/tests/libntp/sockaddrtest.c | 51 + contrib/ntp/tests/libntp/sockaddrtest.h | 13 + contrib/ntp/tests/libntp/socktoa.c | 141 + contrib/ntp/tests/libntp/ssl_init.c | 69 + contrib/ntp/tests/libntp/statestr.c | 37 + contrib/ntp/tests/libntp/strtolfp.c | 123 + contrib/ntp/tests/libntp/test-libntp.c | 27 + contrib/ntp/tests/libntp/test-libntp.h | 8 + contrib/ntp/tests/libntp/timespecops.c | 664 + contrib/ntp/tests/libntp/timevalops.c | 680 + contrib/ntp/tests/libntp/tstotv.c | 49 + contrib/ntp/tests/libntp/tvtots.c | 64 + contrib/ntp/tests/libntp/uglydate.c | 18 + contrib/ntp/tests/libntp/vi64ops.c | 80 + contrib/ntp/tests/libntp/ymd2yd.c | 37 + contrib/ntp/tests/ntpd/Makefile.am | 222 + contrib/ntp/tests/ntpd/Makefile.in | 1770 + contrib/ntp/tests/ntpd/leapsec.c | 1229 + contrib/ntp/tests/ntpd/ntp_prio_q.c | 262 + contrib/ntp/tests/ntpd/ntp_restrict.c | 198 + contrib/ntp/tests/ntpd/rc_cmdlength.c | 38 + contrib/ntp/tests/ntpd/run-leapsec.c | 122 + contrib/ntp/tests/ntpd/run-ntp_prio_q.c | 69 + contrib/ntp/tests/ntpd/run-ntp_restrict.c | 68 + contrib/ntp/tests/ntpd/run-rc_cmdlength.c | 57 + contrib/ntp/tests/ntpd/run-t-ntp_scanner.c | 72 + contrib/ntp/tests/ntpd/run-t-ntp_signd.c | 66 + contrib/ntp/tests/ntpd/t-ntp_scanner.c | 136 + contrib/ntp/tests/ntpd/t-ntp_signd.c | 116 + contrib/ntp/tests/ntpq/Makefile.am | 96 + contrib/ntp/tests/ntpq/Makefile.in | 1286 + contrib/ntp/tests/ntpq/run-t-ntpq.c | 54 + contrib/ntp/tests/ntpq/t-ntpq.c | 37 + contrib/ntp/tests/sandbox/Makefile.am | 98 + contrib/ntp/tests/sandbox/Makefile.in | 1335 + contrib/ntp/tests/sandbox/bug-2803.c | 99 + contrib/ntp/tests/sandbox/modetoa.c | 20 + contrib/ntp/tests/sandbox/run-modetoa.c | 53 + contrib/ntp/tests/sandbox/run-uglydate.c | 53 + contrib/ntp/tests/sandbox/run-ut-2803.c | 61 + contrib/ntp/tests/sandbox/smeartest.c | 180 + contrib/ntp/tests/sandbox/uglydate.c | 16 + contrib/ntp/tests/sandbox/ut-2803.c | 80 + contrib/ntp/tests/sec-2853/Makefile.am | 80 + contrib/ntp/tests/sec-2853/Makefile.in | 1274 + contrib/ntp/tests/sec-2853/run-sec-2853.c | 53 + contrib/ntp/tests/sec-2853/sec-2853.c | 120 + contrib/ntp/util/Makefile.am | 150 +- contrib/ntp/util/Makefile.in | 1208 +- contrib/ntp/util/README | 7 + contrib/ntp/util/ansi2knr.1 | 36 - contrib/ntp/util/ansi2knr.c | 739 - contrib/ntp/util/audio-pcm.c | 4 +- contrib/ntp/util/hist.c | 35 +- ...eygen-opts.menu => invoke-ntp-keygen.menu} | 0 contrib/ntp/util/invoke-ntp-keygen.texi | 1354 + contrib/ntp/util/jitter.c | 6 +- contrib/ntp/util/jitter.h | 412 - contrib/ntp/util/ntp-keygen-opts.c | 2049 +- contrib/ntp/util/ntp-keygen-opts.def | 1079 +- contrib/ntp/util/ntp-keygen-opts.h | 342 +- contrib/ntp/util/ntp-keygen-opts.texi | 364 - contrib/ntp/util/ntp-keygen.1 | 176 - contrib/ntp/util/ntp-keygen.1ntp-keygenman | 1221 + contrib/ntp/util/ntp-keygen.1ntp-keygenmdoc | 1071 + contrib/ntp/util/ntp-keygen.c | 1920 +- contrib/ntp/util/ntp-keygen.html | 1811 + contrib/ntp/util/ntp-keygen.man.in | 1221 + contrib/ntp/util/ntp-keygen.mdoc.in | 1071 + contrib/ntp/util/ntp-keygen.texi | 307 + contrib/ntp/util/ntptime.c | 231 +- contrib/ntp/util/sht.c | 221 +- contrib/ntp/util/tg.c | 19 +- contrib/ntp/util/tg2.c | 2506 + contrib/ntp/util/tickadj.c | 38 +- contrib/ntp/version | 1 - contrib/ntp/version.m4 | 1 - contrib/ntp/ylwrap | 222 + etc/mtree/BSD.usr.dist | 8 + etc/ntp.conf | 4 +- sys/conf/newvers.sh | 2 +- usr.sbin/ntp/Makefile | 2 +- usr.sbin/ntp/Makefile.inc | 5 +- usr.sbin/ntp/config.h | 974 +- usr.sbin/ntp/doc/Makefile | 39 +- usr.sbin/ntp/doc/drivers/Makefile | 21 + usr.sbin/ntp/doc/drivers/scripts/Makefile | 13 + usr.sbin/ntp/doc/hints/Makefile | 17 + usr.sbin/ntp/doc/ntp-keygen.8 | 558 +- usr.sbin/ntp/doc/ntp.conf.5 | 418 +- usr.sbin/ntp/doc/ntp.keys.5 | 168 +- usr.sbin/ntp/doc/ntpd.8 | 624 +- usr.sbin/ntp/doc/ntpdc.8 | 242 +- usr.sbin/ntp/doc/ntpq.8 | 1409 +- usr.sbin/ntp/doc/ntptime.8 | 4 +- usr.sbin/ntp/doc/ntptrace.8 | 149 +- usr.sbin/ntp/doc/scripts/Makefile | 15 + usr.sbin/ntp/doc/sntp.8 | 314 + usr.sbin/ntp/libntp/Makefile | 100 +- usr.sbin/ntp/libntpevent/Makefile | 34 + .../ntp/libntpevent/event2/event-config.h | 648 + usr.sbin/ntp/libopts/Makefile | 9 +- usr.sbin/ntp/libparse/Makefile | 17 +- usr.sbin/ntp/ntp-keygen/Makefile | 34 +- usr.sbin/ntp/ntpd/Makefile | 69 +- usr.sbin/ntp/ntpdate/Makefile | 22 +- usr.sbin/ntp/ntpdc/Makefile | 25 +- usr.sbin/ntp/ntpdc/nl.c | 895 + usr.sbin/ntp/ntpq/Makefile | 28 +- usr.sbin/ntp/ntptime/Makefile | 12 +- usr.sbin/ntp/scripts/mkver | 2 +- usr.sbin/ntp/sntp/Makefile | 34 +- 1786 files changed, 736514 insertions(+), 170806 deletions(-) create mode 100644 contrib/ntp/README.leapsmear delete mode 100644 contrib/ntp/arlib/COPYING delete mode 100644 contrib/ntp/arlib/INSTALL delete mode 100644 contrib/ntp/arlib/Makefile.am delete mode 100644 contrib/ntp/arlib/Makefile.in delete mode 100644 contrib/ntp/arlib/README delete mode 100644 contrib/ntp/arlib/UNSHAR.HDR delete mode 100644 contrib/ntp/arlib/arlib.3 delete mode 100644 contrib/ntp/arlib/arlib.c delete mode 100644 contrib/ntp/arlib/arlib.h delete mode 100644 contrib/ntp/arlib/arplib.h delete mode 100755 contrib/ntp/arlib/configure delete mode 100644 contrib/ntp/arlib/configure.in delete mode 100755 contrib/ntp/arlib/install-sh delete mode 100644 contrib/ntp/arlib/sample.c create mode 100644 contrib/ntp/check-libopts.mf delete mode 100644 contrib/ntp/clockstuff/clktest.c create mode 100644 contrib/ntp/deps-ver create mode 100644 contrib/ntp/depsver.mf delete mode 100644 contrib/ntp/excludes create mode 100644 contrib/ntp/html/access.html create mode 100644 contrib/ntp/html/authentic.html create mode 100644 contrib/ntp/html/autokey.html create mode 100644 contrib/ntp/html/bugs.html create mode 100644 contrib/ntp/html/build.html delete mode 100644 contrib/ntp/html/build/build.html delete mode 100644 contrib/ntp/html/build/config.html delete mode 100644 contrib/ntp/html/build/hints.html delete mode 100644 contrib/ntp/html/build/hints/netbsd delete mode 100644 contrib/ntp/html/build/hints/solaris.html delete mode 100644 contrib/ntp/html/build/hints/vxworks.html delete mode 100644 contrib/ntp/html/build/hints/winnt.html delete mode 100644 contrib/ntp/html/build/patches.html delete mode 100644 contrib/ntp/html/build/porting.html delete mode 100644 contrib/ntp/html/build/quick.html delete mode 100644 contrib/ntp/html/build/scripts/footer.txt delete mode 100644 contrib/ntp/html/build/scripts/links10.txt delete mode 100644 contrib/ntp/html/build/scripts/links11.txt delete mode 100644 contrib/ntp/html/build/scripts/links12.txt delete mode 100644 contrib/ntp/html/build/scripts/links7.txt delete mode 100644 contrib/ntp/html/build/scripts/links8.txt delete mode 100644 contrib/ntp/html/build/scripts/links9.txt delete mode 100644 contrib/ntp/html/build/scripts/style.css create mode 100644 contrib/ntp/html/clock.html create mode 100644 contrib/ntp/html/cluster.html create mode 100644 contrib/ntp/html/comdex.html create mode 100644 contrib/ntp/html/config.html create mode 100644 contrib/ntp/html/decode.html create mode 100644 contrib/ntp/html/discipline.html create mode 100644 contrib/ntp/html/discover.html delete mode 100644 contrib/ntp/html/drivers/driver2.html create mode 100644 contrib/ntp/html/drivers/driver40-ja.html create mode 100644 contrib/ntp/html/drivers/driver45.html create mode 100644 contrib/ntp/html/drivers/driver46.html rename contrib/ntp/html/{ => drivers}/mx4200data.html (98%) create mode 100644 contrib/ntp/html/filter.html delete mode 100644 contrib/ntp/html/gadget.html delete mode 100644 contrib/ntp/html/groups.html create mode 100644 contrib/ntp/html/hints.html rename contrib/ntp/html/{build => }/hints/a-ux (100%) rename contrib/ntp/html/{build => }/hints/aix (100%) rename contrib/ntp/html/{build => }/hints/bsdi (100%) rename contrib/ntp/html/{build => }/hints/changes (100%) rename contrib/ntp/html/{build => }/hints/decosf1 (100%) rename contrib/ntp/html/{build => }/hints/decosf2 (100%) rename contrib/ntp/html/{build => }/hints/freebsd (100%) rename contrib/ntp/html/{build => }/hints/hpux (100%) rename contrib/ntp/html/{build => }/hints/linux (100%) rename contrib/ntp/html/{build => }/hints/mpeix (100%) rename contrib/ntp/html/{build => }/hints/notes-xntp-v3 (100%) rename contrib/ntp/html/{build => }/hints/parse (97%) rename contrib/ntp/html/{build => }/hints/refclocks (100%) rename contrib/ntp/html/{build => }/hints/rs6000 (100%) rename contrib/ntp/html/{build => }/hints/sco.html (66%) rename contrib/ntp/html/{build => }/hints/sgi (100%) rename contrib/ntp/html/{build => }/hints/solaris-dosynctodr.html (94%) create mode 100644 contrib/ntp/html/hints/solaris.html rename contrib/ntp/html/{build => }/hints/solaris.xtra.4023118 (100%) rename contrib/ntp/html/{build => }/hints/solaris.xtra.4095849 (100%) rename contrib/ntp/html/{build => }/hints/solaris.xtra.S99ntpd (100%) rename contrib/ntp/html/{build => }/hints/solaris.xtra.patchfreq (100%) rename contrib/ntp/html/{build => }/hints/sun4 (100%) rename contrib/ntp/html/{build => }/hints/svr4-dell (100%) rename contrib/ntp/html/{build => }/hints/svr4_package (100%) rename contrib/ntp/html/{build => }/hints/todo (100%) create mode 100644 contrib/ntp/html/hints/vxworks.html create mode 100644 contrib/ntp/html/hints/winnt.html create mode 100644 contrib/ntp/html/history.html create mode 100644 contrib/ntp/html/huffpuff.html create mode 100644 contrib/ntp/html/icons/sitemap.png create mode 100644 contrib/ntp/html/kernpps.html delete mode 100644 contrib/ntp/html/ldisc.html create mode 100644 contrib/ntp/html/leap.html delete mode 100644 contrib/ntp/html/manyopt.html delete mode 100644 contrib/ntp/html/measure.html delete mode 100644 contrib/ntp/html/notes.html create mode 100644 contrib/ntp/html/ntp-wait.html create mode 100644 contrib/ntp/html/orphan.html create mode 100644 contrib/ntp/html/pic/9400n.jpg create mode 100644 contrib/ntp/html/pic/alice11.gif create mode 100644 contrib/ntp/html/pic/alice13.gif create mode 100644 contrib/ntp/html/pic/alice15.gif create mode 100644 contrib/ntp/html/pic/alice23.gif create mode 100644 contrib/ntp/html/pic/alice31.gif create mode 100644 contrib/ntp/html/pic/alice32.gif create mode 100644 contrib/ntp/html/pic/alice35.gif create mode 100644 contrib/ntp/html/pic/alice38.gif create mode 100644 contrib/ntp/html/pic/alice44.gif create mode 100644 contrib/ntp/html/pic/alice47.gif create mode 100644 contrib/ntp/html/pic/alice51.gif create mode 100644 contrib/ntp/html/pic/alice61.gif create mode 100644 contrib/ntp/html/pic/barnstable.gif create mode 100644 contrib/ntp/html/pic/beaver.gif create mode 100644 contrib/ntp/html/pic/boom3.gif create mode 100644 contrib/ntp/html/pic/boom3a.gif create mode 100644 contrib/ntp/html/pic/boom4.gif create mode 100644 contrib/ntp/html/pic/broad.gif create mode 100644 contrib/ntp/html/pic/bustardfly.gif create mode 100644 contrib/ntp/html/pic/c51.jpg create mode 100644 contrib/ntp/html/pic/description.jpg create mode 100644 contrib/ntp/html/pic/discipline.gif create mode 100644 contrib/ntp/html/pic/dogsnake.gif create mode 100644 contrib/ntp/html/pic/driver29.gif create mode 100644 contrib/ntp/html/pic/driver43_1.gif create mode 100644 contrib/ntp/html/pic/driver43_2.jpg create mode 100644 contrib/ntp/html/pic/fg6021.gif create mode 100644 contrib/ntp/html/pic/fg6039.jpg create mode 100644 contrib/ntp/html/pic/fig_3_1.gif create mode 100644 contrib/ntp/html/pic/flatheads.gif create mode 100644 contrib/ntp/html/pic/flt1.gif create mode 100644 contrib/ntp/html/pic/flt2.gif create mode 100644 contrib/ntp/html/pic/flt3.gif create mode 100644 contrib/ntp/html/pic/flt4.gif create mode 100644 contrib/ntp/html/pic/flt5.gif create mode 100644 contrib/ntp/html/pic/flt6.gif create mode 100644 contrib/ntp/html/pic/flt7.gif create mode 100644 contrib/ntp/html/pic/flt8.gif create mode 100644 contrib/ntp/html/pic/flt9.gif create mode 100644 contrib/ntp/html/pic/freq1211.gif create mode 100644 contrib/ntp/html/pic/gadget.jpg create mode 100644 contrib/ntp/html/pic/gps167.jpg create mode 100644 contrib/ntp/html/pic/group.gif create mode 100644 contrib/ntp/html/pic/hornraba.gif create mode 100644 contrib/ntp/html/pic/igclock.gif create mode 100755 contrib/ntp/html/pic/neoclock4x.gif create mode 100644 contrib/ntp/html/pic/offset1211.gif create mode 100644 contrib/ntp/html/pic/oncore_evalbig.gif create mode 100644 contrib/ntp/html/pic/oncore_remoteant.jpg create mode 100644 contrib/ntp/html/pic/oncore_utplusbig.gif create mode 100644 contrib/ntp/html/pic/oz2.gif create mode 100644 contrib/ntp/html/pic/panda.gif create mode 100644 contrib/ntp/html/pic/pd_om006.gif create mode 100644 contrib/ntp/html/pic/pd_om011.gif create mode 100644 contrib/ntp/html/pic/peer.gif create mode 100644 contrib/ntp/html/pic/pogo.gif create mode 100644 contrib/ntp/html/pic/pogo1a.gif create mode 100644 contrib/ntp/html/pic/pogo3a.gif create mode 100644 contrib/ntp/html/pic/pogo4.gif create mode 100644 contrib/ntp/html/pic/pogo5.gif create mode 100644 contrib/ntp/html/pic/pogo6.gif create mode 100644 contrib/ntp/html/pic/pogo7.gif create mode 100644 contrib/ntp/html/pic/pogo8.gif create mode 100644 contrib/ntp/html/pic/pzf509.jpg create mode 100644 contrib/ntp/html/pic/pzf511.jpg create mode 100644 contrib/ntp/html/pic/rabbit.gif create mode 100644 contrib/ntp/html/pic/radio2.jpg create mode 100644 contrib/ntp/html/pic/sheepb.jpg create mode 100644 contrib/ntp/html/pic/stack1a.jpg create mode 100644 contrib/ntp/html/pic/stats.gif create mode 100644 contrib/ntp/html/pic/sx5.gif create mode 100644 contrib/ntp/html/pic/thunderbolt.jpg create mode 100644 contrib/ntp/html/pic/time1.gif create mode 100644 contrib/ntp/html/pic/tonea.gif create mode 100644 contrib/ntp/html/pic/tribeb.gif create mode 100644 contrib/ntp/html/pic/wingdorothy.gif create mode 100644 contrib/ntp/html/poll.html create mode 100644 contrib/ntp/html/quick.html create mode 100644 contrib/ntp/html/rate.html create mode 100644 contrib/ntp/html/scripts/accopt.txt create mode 100644 contrib/ntp/html/scripts/audio.txt create mode 100644 contrib/ntp/html/scripts/authopt.txt create mode 100644 contrib/ntp/html/scripts/clockopt.txt create mode 100644 contrib/ntp/html/scripts/command.txt create mode 100644 contrib/ntp/html/scripts/config.txt create mode 100644 contrib/ntp/html/scripts/confopt.txt create mode 100644 contrib/ntp/html/scripts/external.txt create mode 100644 contrib/ntp/html/scripts/hand.txt create mode 100644 contrib/ntp/html/scripts/install.txt delete mode 100644 contrib/ntp/html/scripts/links10.txt delete mode 100644 contrib/ntp/html/scripts/links11.txt delete mode 100644 contrib/ntp/html/scripts/links12.txt delete mode 100644 contrib/ntp/html/scripts/links7.txt delete mode 100644 contrib/ntp/html/scripts/links8.txt delete mode 100644 contrib/ntp/html/scripts/links9.txt create mode 100644 contrib/ntp/html/scripts/manual.txt create mode 100644 contrib/ntp/html/scripts/misc.txt create mode 100644 contrib/ntp/html/scripts/miscopt.txt create mode 100644 contrib/ntp/html/scripts/monopt.txt create mode 100644 contrib/ntp/html/scripts/refclock.txt create mode 100644 contrib/ntp/html/scripts/special.txt create mode 100644 contrib/ntp/html/select.html create mode 100644 contrib/ntp/html/sitemap.html create mode 100644 contrib/ntp/html/stats.html create mode 100644 contrib/ntp/html/warp.html create mode 100644 contrib/ntp/html/xleave.html delete mode 100644 contrib/ntp/include/autogen-version.def delete mode 100644 contrib/ntp/include/copyright.def delete mode 100644 contrib/ntp/include/debug-opt.def create mode 100644 contrib/ntp/include/declcond.h delete mode 100644 contrib/ntp/include/global.h create mode 100644 contrib/ntp/include/intreswork.h delete mode 100644 contrib/ntp/include/isc/app.h delete mode 100644 contrib/ntp/include/isc/boolean.h delete mode 100644 contrib/ntp/include/isc/formatcheck.h delete mode 100644 contrib/ntp/include/isc/interfaceiter.h delete mode 100644 contrib/ntp/include/isc/lang.h delete mode 100644 contrib/ntp/include/isc/lib.h delete mode 100644 contrib/ntp/include/isc/msgs.h delete mode 100644 contrib/ntp/include/isc/once.h delete mode 100644 contrib/ntp/include/isc/result.h delete mode 100644 contrib/ntp/include/isc/strerror.h delete mode 100644 contrib/ntp/include/isc/string.h delete mode 100644 contrib/ntp/include/isc/types.h create mode 100644 contrib/ntp/include/lib_strbuf.h create mode 100644 contrib/ntp/include/libntp.h create mode 100644 contrib/ntp/include/ntp_assert.h create mode 100644 contrib/ntp/include/ntp_intres.h create mode 100644 contrib/ntp/include/ntp_libopts.h create mode 100644 contrib/ntp/include/ntp_lineedit.h create mode 100644 contrib/ntp/include/ntp_lists.h create mode 100644 contrib/ntp/include/ntp_net.h create mode 100644 contrib/ntp/include/ntp_prio_q.h delete mode 100644 contrib/ntp/include/ntp_sprintf.h create mode 100644 contrib/ntp/include/ntp_worker.h create mode 100644 contrib/ntp/include/ntp_workimpl.h create mode 100644 contrib/ntp/include/rc_cmdlength.h create mode 100644 contrib/ntp/include/refclock_atom.h create mode 100644 contrib/ntp/include/refidsmear.h delete mode 100644 contrib/ntp/include/rsa_md5.h create mode 100644 contrib/ntp/include/ssl_applink.c create mode 100644 contrib/ntp/include/timespecops.h create mode 100644 contrib/ntp/include/timetoa.h create mode 100644 contrib/ntp/include/timevalops.h delete mode 100644 contrib/ntp/include/version.def create mode 100644 contrib/ntp/include/vint64ops.h create mode 100644 contrib/ntp/includes.mf delete mode 100644 contrib/ntp/kernel/README delete mode 100644 contrib/ntp/kernel/chuinit.c delete mode 100644 contrib/ntp/kernel/clkinit.c delete mode 100644 contrib/ntp/kernel/sys/chudefs.h delete mode 100644 contrib/ntp/kernel/sys/clkdefs.h delete mode 100644 contrib/ntp/kernel/tty_chu.c delete mode 100644 contrib/ntp/kernel/tty_chu_STREAMS.c delete mode 100644 contrib/ntp/kernel/tty_clk.c delete mode 100644 contrib/ntp/kernel/tty_clk_STREAMS.c create mode 100644 contrib/ntp/lib/isc/Atffile create mode 100644 contrib/ntp/lib/isc/alpha/include/isc/atomic.h create mode 100644 contrib/ntp/lib/isc/api create mode 100644 contrib/ntp/lib/isc/app_api.c create mode 100644 contrib/ntp/lib/isc/assertions.c create mode 100644 contrib/ntp/lib/isc/backtrace-emptytbl.c create mode 100644 contrib/ntp/lib/isc/backtrace.c create mode 100644 contrib/ntp/lib/isc/base32.c create mode 100644 contrib/ntp/lib/isc/base64.c create mode 100644 contrib/ntp/lib/isc/bitstring.c create mode 100644 contrib/ntp/lib/isc/buffer.c create mode 100644 contrib/ntp/lib/isc/bufferlist.c create mode 100644 contrib/ntp/lib/isc/commandline.c create mode 100644 contrib/ntp/lib/isc/entropy.c rename contrib/ntp/{libisc => lib/isc}/error.c (74%) create mode 100644 contrib/ntp/lib/isc/event.c create mode 100644 contrib/ntp/lib/isc/fsaccess.c create mode 100644 contrib/ntp/lib/isc/hash.c create mode 100644 contrib/ntp/lib/isc/heap.c create mode 100644 contrib/ntp/lib/isc/hex.c create mode 100644 contrib/ntp/lib/isc/hmacmd5.c create mode 100644 contrib/ntp/lib/isc/hmacsha.c create mode 100644 contrib/ntp/lib/isc/httpd.c create mode 100644 contrib/ntp/lib/isc/ia64/include/isc/atomic.h create mode 100644 contrib/ntp/lib/isc/include/isc/app.h rename contrib/ntp/{ => lib/isc}/include/isc/assertions.h (71%) create mode 100644 contrib/ntp/lib/isc/include/isc/backtrace.h create mode 100644 contrib/ntp/lib/isc/include/isc/base32.h create mode 100644 contrib/ntp/lib/isc/include/isc/base64.h create mode 100644 contrib/ntp/lib/isc/include/isc/bind9.h create mode 100644 contrib/ntp/lib/isc/include/isc/bitstring.h create mode 100644 contrib/ntp/lib/isc/include/isc/boolean.h rename contrib/ntp/{ => lib/isc}/include/isc/buffer.h (67%) create mode 100644 contrib/ntp/lib/isc/include/isc/bufferlist.h create mode 100644 contrib/ntp/lib/isc/include/isc/commandline.h create mode 100644 contrib/ntp/lib/isc/include/isc/entropy.h rename contrib/ntp/{ => lib/isc}/include/isc/error.h (52%) create mode 100644 contrib/ntp/lib/isc/include/isc/event.h create mode 100644 contrib/ntp/lib/isc/include/isc/eventclass.h create mode 100644 contrib/ntp/lib/isc/include/isc/file.h create mode 100644 contrib/ntp/lib/isc/include/isc/formatcheck.h create mode 100644 contrib/ntp/lib/isc/include/isc/fsaccess.h create mode 100644 contrib/ntp/lib/isc/include/isc/hash.h create mode 100644 contrib/ntp/lib/isc/include/isc/heap.h create mode 100644 contrib/ntp/lib/isc/include/isc/hex.h create mode 100644 contrib/ntp/lib/isc/include/isc/hmacmd5.h create mode 100644 contrib/ntp/lib/isc/include/isc/hmacsha.h create mode 100644 contrib/ntp/lib/isc/include/isc/httpd.h create mode 100644 contrib/ntp/lib/isc/include/isc/interfaceiter.h rename contrib/ntp/{ => lib/isc}/include/isc/ipv6.h (82%) create mode 100644 contrib/ntp/lib/isc/include/isc/iterated_hash.h create mode 100644 contrib/ntp/lib/isc/include/isc/lang.h create mode 100644 contrib/ntp/lib/isc/include/isc/lex.h create mode 100644 contrib/ntp/lib/isc/include/isc/lfsr.h create mode 100644 contrib/ntp/lib/isc/include/isc/lib.h rename contrib/ntp/{ => lib/isc}/include/isc/list.h (81%) create mode 100644 contrib/ntp/lib/isc/include/isc/log.h rename contrib/ntp/{ => lib/isc}/include/isc/magic.h (54%) create mode 100644 contrib/ntp/lib/isc/include/isc/md5.h create mode 100644 contrib/ntp/lib/isc/include/isc/mem.h rename contrib/ntp/{ => lib/isc}/include/isc/msgcat.h (54%) create mode 100644 contrib/ntp/lib/isc/include/isc/msgs.h create mode 100644 contrib/ntp/lib/isc/include/isc/mutexblock.h create mode 100644 contrib/ntp/lib/isc/include/isc/namespace.h rename contrib/ntp/{ => lib/isc}/include/isc/netaddr.h (66%) rename contrib/ntp/{ => lib/isc}/include/isc/netscope.h (75%) create mode 100644 contrib/ntp/lib/isc/include/isc/ondestroy.h create mode 100644 contrib/ntp/lib/isc/include/isc/os.h create mode 100644 contrib/ntp/lib/isc/include/isc/parseint.h rename contrib/ntp/{ => lib/isc}/include/isc/platform.h (100%) create mode 100644 contrib/ntp/lib/isc/include/isc/platform.h.in create mode 100644 contrib/ntp/lib/isc/include/isc/portset.h rename contrib/ntp/{ => lib/isc}/include/isc/print.h (55%) create mode 100644 contrib/ntp/lib/isc/include/isc/queue.h create mode 100644 contrib/ntp/lib/isc/include/isc/quota.h create mode 100644 contrib/ntp/lib/isc/include/isc/radix.h create mode 100644 contrib/ntp/lib/isc/include/isc/random.h create mode 100644 contrib/ntp/lib/isc/include/isc/ratelimiter.h create mode 100644 contrib/ntp/lib/isc/include/isc/refcount.h rename contrib/ntp/{ => lib/isc}/include/isc/region.h (81%) create mode 100644 contrib/ntp/lib/isc/include/isc/resource.h create mode 100644 contrib/ntp/lib/isc/include/isc/result.h create mode 100644 contrib/ntp/lib/isc/include/isc/resultclass.h create mode 100644 contrib/ntp/lib/isc/include/isc/rwlock.h create mode 100644 contrib/ntp/lib/isc/include/isc/serial.h create mode 100644 contrib/ntp/lib/isc/include/isc/sha1.h create mode 100644 contrib/ntp/lib/isc/include/isc/sha2.h rename contrib/ntp/{ => lib/isc}/include/isc/sockaddr.h (59%) create mode 100644 contrib/ntp/lib/isc/include/isc/socket.h create mode 100644 contrib/ntp/lib/isc/include/isc/stats.h create mode 100644 contrib/ntp/lib/isc/include/isc/stdio.h create mode 100644 contrib/ntp/lib/isc/include/isc/stdlib.h create mode 100644 contrib/ntp/lib/isc/include/isc/string.h create mode 100644 contrib/ntp/lib/isc/include/isc/symtab.h create mode 100644 contrib/ntp/lib/isc/include/isc/task.h create mode 100644 contrib/ntp/lib/isc/include/isc/taskpool.h create mode 100644 contrib/ntp/lib/isc/include/isc/timer.h create mode 100644 contrib/ntp/lib/isc/include/isc/types.h rename contrib/ntp/{ => lib/isc}/include/isc/util.h (87%) create mode 100644 contrib/ntp/lib/isc/include/isc/version.h create mode 100644 contrib/ntp/lib/isc/include/isc/xml.h rename contrib/ntp/{libisc => lib/isc}/inet_aton.c (94%) rename contrib/ntp/{libisc => lib/isc}/inet_ntop.c (76%) rename contrib/ntp/{libisc => lib/isc}/inet_pton.c (82%) create mode 100644 contrib/ntp/lib/isc/iterated_hash.c create mode 100644 contrib/ntp/lib/isc/lex.c create mode 100644 contrib/ntp/lib/isc/lfsr.c rename contrib/ntp/{libisc => lib/isc}/lib.c (52%) create mode 100644 contrib/ntp/lib/isc/log.c create mode 100644 contrib/ntp/lib/isc/md5.c create mode 100644 contrib/ntp/lib/isc/mem.c create mode 100644 contrib/ntp/lib/isc/mem_api.c create mode 100644 contrib/ntp/lib/isc/mips/include/isc/atomic.h create mode 100644 contrib/ntp/lib/isc/mutexblock.c rename contrib/ntp/{libisc => lib/isc}/netaddr.c (75%) rename contrib/ntp/{libisc => lib/isc}/netscope.c (90%) rename contrib/ntp/{libisc => lib/isc/nls}/msgcat.c (76%) create mode 100644 contrib/ntp/lib/isc/noatomic/include/isc/atomic.h create mode 100644 contrib/ntp/lib/isc/nothreads/condition.c create mode 100644 contrib/ntp/lib/isc/nothreads/include/isc/condition.h rename contrib/ntp/{ => lib/isc/nothreads}/include/isc/mutex.h (57%) create mode 100644 contrib/ntp/lib/isc/nothreads/include/isc/once.h create mode 100644 contrib/ntp/lib/isc/nothreads/include/isc/thread.h create mode 100644 contrib/ntp/lib/isc/nothreads/mutex.c create mode 100644 contrib/ntp/lib/isc/nothreads/thread.c create mode 100644 contrib/ntp/lib/isc/ondestroy.c create mode 100644 contrib/ntp/lib/isc/parseint.c create mode 100644 contrib/ntp/lib/isc/portset.c create mode 100644 contrib/ntp/lib/isc/powerpc/include/isc/atomic.h create mode 100644 contrib/ntp/lib/isc/print.c create mode 100644 contrib/ntp/lib/isc/pthreads/condition.c create mode 100644 contrib/ntp/lib/isc/pthreads/include/isc/condition.h create mode 100644 contrib/ntp/lib/isc/pthreads/include/isc/mutex.h create mode 100644 contrib/ntp/lib/isc/pthreads/include/isc/once.h create mode 100644 contrib/ntp/lib/isc/pthreads/include/isc/thread.h create mode 100644 contrib/ntp/lib/isc/pthreads/mutex.c create mode 100644 contrib/ntp/lib/isc/pthreads/thread.c create mode 100644 contrib/ntp/lib/isc/quota.c create mode 100644 contrib/ntp/lib/isc/radix.c create mode 100644 contrib/ntp/lib/isc/random.c create mode 100644 contrib/ntp/lib/isc/ratelimiter.c create mode 100644 contrib/ntp/lib/isc/refcount.c create mode 100644 contrib/ntp/lib/isc/region.c create mode 100644 contrib/ntp/lib/isc/result.c create mode 100644 contrib/ntp/lib/isc/rwlock.c create mode 100644 contrib/ntp/lib/isc/serial.c create mode 100644 contrib/ntp/lib/isc/sha1.c create mode 100644 contrib/ntp/lib/isc/sha2.c rename contrib/ntp/{libisc => lib/isc}/sockaddr.c (77%) create mode 100644 contrib/ntp/lib/isc/socket_api.c create mode 100644 contrib/ntp/lib/isc/sparc64/include/isc/atomic.h create mode 100644 contrib/ntp/lib/isc/stats.c create mode 100644 contrib/ntp/lib/isc/string.c create mode 100644 contrib/ntp/lib/isc/strtoul.c create mode 100644 contrib/ntp/lib/isc/symtab.c create mode 100644 contrib/ntp/lib/isc/task.c create mode 100644 contrib/ntp/lib/isc/task_api.c create mode 100644 contrib/ntp/lib/isc/task_p.h create mode 100644 contrib/ntp/lib/isc/taskpool.c create mode 100644 contrib/ntp/lib/isc/tests/Atffile create mode 100644 contrib/ntp/lib/isc/tests/hash_test.c create mode 100644 contrib/ntp/lib/isc/tests/isctest.c create mode 100644 contrib/ntp/lib/isc/tests/isctest.h create mode 100644 contrib/ntp/lib/isc/tests/queue_test.c create mode 100644 contrib/ntp/lib/isc/tests/socket_test.c create mode 100644 contrib/ntp/lib/isc/tests/symtab_test.c create mode 100644 contrib/ntp/lib/isc/tests/task_test.c create mode 100644 contrib/ntp/lib/isc/tests/taskpool_test.c create mode 100644 contrib/ntp/lib/isc/timer.c create mode 100644 contrib/ntp/lib/isc/timer_api.c create mode 100644 contrib/ntp/lib/isc/timer_p.h create mode 100644 contrib/ntp/lib/isc/unix/app.c create mode 100644 contrib/ntp/lib/isc/unix/dir.c create mode 100644 contrib/ntp/lib/isc/unix/entropy.c create mode 100644 contrib/ntp/lib/isc/unix/errno2result.c create mode 100644 contrib/ntp/lib/isc/unix/errno2result.h create mode 100644 contrib/ntp/lib/isc/unix/file.c create mode 100644 contrib/ntp/lib/isc/unix/fsaccess.c rename contrib/ntp/{libisc => lib/isc/unix}/ifiter_getifaddrs.c (60%) rename contrib/ntp/{libisc => lib/isc/unix}/ifiter_ioctl.c (81%) rename contrib/ntp/{libisc => lib/isc/unix}/ifiter_sysctl.c (91%) create mode 100644 contrib/ntp/lib/isc/unix/include/isc/dir.h rename contrib/ntp/{ => lib/isc/unix}/include/isc/int.h (64%) create mode 100644 contrib/ntp/lib/isc/unix/include/isc/keyboard.h rename contrib/ntp/{ => lib/isc/unix}/include/isc/net.h (74%) create mode 100644 contrib/ntp/lib/isc/unix/include/isc/netdb.h create mode 100644 contrib/ntp/lib/isc/unix/include/isc/offset.h create mode 100644 contrib/ntp/lib/isc/unix/include/isc/stat.h create mode 100644 contrib/ntp/lib/isc/unix/include/isc/stdtime.h create mode 100644 contrib/ntp/lib/isc/unix/include/isc/strerror.h create mode 100644 contrib/ntp/lib/isc/unix/include/isc/syslog.h create mode 100644 contrib/ntp/lib/isc/unix/include/isc/time.h rename contrib/ntp/{libisc => lib/isc/unix}/interfaceiter.c (60%) create mode 100644 contrib/ntp/lib/isc/unix/ipv6.c create mode 100644 contrib/ntp/lib/isc/unix/keyboard.c create mode 100644 contrib/ntp/lib/isc/unix/net.c create mode 100644 contrib/ntp/lib/isc/unix/os.c create mode 100644 contrib/ntp/lib/isc/unix/resource.c create mode 100644 contrib/ntp/lib/isc/unix/socket.c create mode 100644 contrib/ntp/lib/isc/unix/socket_p.h create mode 100644 contrib/ntp/lib/isc/unix/stdio.c create mode 100644 contrib/ntp/lib/isc/unix/stdtime.c rename contrib/ntp/{libisc/isc_strerror.c => lib/isc/unix/strerror.c} (62%) create mode 100644 contrib/ntp/lib/isc/unix/syslog.c create mode 100644 contrib/ntp/lib/isc/unix/time.c create mode 100644 contrib/ntp/lib/isc/version.c create mode 100644 contrib/ntp/lib/isc/win32/DLLMain.c create mode 100644 contrib/ntp/lib/isc/win32/app.c create mode 100644 contrib/ntp/lib/isc/win32/condition.c create mode 100644 contrib/ntp/lib/isc/win32/dir.c create mode 100644 contrib/ntp/lib/isc/win32/entropy.c create mode 100644 contrib/ntp/lib/isc/win32/errno2result.c create mode 100644 contrib/ntp/lib/isc/win32/errno2result.h create mode 100644 contrib/ntp/lib/isc/win32/file.c create mode 100644 contrib/ntp/lib/isc/win32/fsaccess.c create mode 100644 contrib/ntp/lib/isc/win32/include/isc/bind_registry.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/bindevt.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/condition.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/dir.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/int.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/ipv6.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/keyboard.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/mutex.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/net.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/netdb.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/ntgroups.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/ntpaths.h rename contrib/ntp/{ => lib/isc/win32}/include/isc/offset.h (63%) create mode 100644 contrib/ntp/lib/isc/win32/include/isc/once.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/platform.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/stat.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/stdtime.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/strerror.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/syslog.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/thread.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/time.h create mode 100644 contrib/ntp/lib/isc/win32/include/isc/win32os.h create mode 100644 contrib/ntp/lib/isc/win32/interfaceiter.c create mode 100644 contrib/ntp/lib/isc/win32/ipv6.c create mode 100644 contrib/ntp/lib/isc/win32/keyboard.c create mode 100644 contrib/ntp/lib/isc/win32/libgen.h create mode 100644 contrib/ntp/lib/isc/win32/libisc.def create mode 100644 contrib/ntp/lib/isc/win32/libisc.dsp create mode 100644 contrib/ntp/lib/isc/win32/libisc.dsw create mode 100644 contrib/ntp/lib/isc/win32/libisc.mak rename contrib/ntp/{libisc => lib/isc/win32}/net.c (64%) create mode 100644 contrib/ntp/lib/isc/win32/netdb.h create mode 100644 contrib/ntp/lib/isc/win32/ntgroups.c create mode 100644 contrib/ntp/lib/isc/win32/ntpaths.c create mode 100644 contrib/ntp/lib/isc/win32/once.c create mode 100644 contrib/ntp/lib/isc/win32/os.c create mode 100644 contrib/ntp/lib/isc/win32/resource.c create mode 100644 contrib/ntp/lib/isc/win32/socket.c create mode 100644 contrib/ntp/lib/isc/win32/stdio.c create mode 100644 contrib/ntp/lib/isc/win32/stdtime.c create mode 100644 contrib/ntp/lib/isc/win32/strerror.c create mode 100644 contrib/ntp/lib/isc/win32/syslog.c create mode 100644 contrib/ntp/lib/isc/win32/syslog.h create mode 100644 contrib/ntp/lib/isc/win32/thread.c create mode 100644 contrib/ntp/lib/isc/win32/time.c create mode 100644 contrib/ntp/lib/isc/win32/unistd.h create mode 100644 contrib/ntp/lib/isc/win32/version.c create mode 100644 contrib/ntp/lib/isc/win32/win32os.c create mode 100644 contrib/ntp/lib/isc/x86_32/include/isc/atomic.h create mode 100644 contrib/ntp/lib/isc/x86_64/include/isc/atomic.h delete mode 100644 contrib/ntp/libisc/assertions.c delete mode 100644 contrib/ntp/libisc/mem.c delete mode 100644 contrib/ntp/libisc/strerror.c create mode 100644 contrib/ntp/libjsmn/LICENSE create mode 100644 contrib/ntp/libjsmn/Makefile create mode 100644 contrib/ntp/libjsmn/README.md create mode 100644 contrib/ntp/libjsmn/example/jsondump.c create mode 100644 contrib/ntp/libjsmn/example/simple.c create mode 100644 contrib/ntp/libjsmn/jsmn.c create mode 100644 contrib/ntp/libjsmn/jsmn.h create mode 100644 contrib/ntp/libjsmn/jsmn_test.c rename contrib/ntp/libntp/{strerror.c => bsd_strerror.c} (92%) delete mode 100644 contrib/ntp/libntp/fptoa.c delete mode 100644 contrib/ntp/libntp/fptoms.c delete mode 100644 contrib/ntp/libntp/inttoa.c delete mode 100644 contrib/ntp/libntp/lib_strbuf.h delete mode 100644 contrib/ntp/libntp/md5c.c delete mode 100644 contrib/ntp/libntp/memmove.c delete mode 100644 contrib/ntp/libntp/mfptoa.c delete mode 100644 contrib/ntp/libntp/mfptoms.c delete mode 100644 contrib/ntp/libntp/msutotsf.c create mode 100644 contrib/ntp/libntp/ntp_calendar.c create mode 100644 contrib/ntp/libntp/ntp_crypto_rnd.c create mode 100644 contrib/ntp/libntp/ntp_intres.c create mode 100644 contrib/ntp/libntp/ntp_libopts.c create mode 100644 contrib/ntp/libntp/ntp_lineedit.c create mode 100644 contrib/ntp/libntp/ntp_worker.c create mode 100644 contrib/ntp/libntp/refidsmear.c create mode 100644 contrib/ntp/libntp/socket.c create mode 100644 contrib/ntp/libntp/ssl_init.c create mode 100644 contrib/ntp/libntp/strl_obsd.c delete mode 100644 contrib/ntp/libntp/strstr.c create mode 100644 contrib/ntp/libntp/timetoa.c create mode 100644 contrib/ntp/libntp/timevalops.c delete mode 100644 contrib/ntp/libntp/tsftomsu.c delete mode 100644 contrib/ntp/libntp/tstotv.c delete mode 100644 contrib/ntp/libntp/tvtoa.c delete mode 100644 contrib/ntp/libntp/tvtots.c delete mode 100644 contrib/ntp/libntp/uinttoa.c delete mode 100644 contrib/ntp/libntp/utvtoa.c create mode 100644 contrib/ntp/libntp/vint64ops.c create mode 100644 contrib/ntp/libntp/work_fork.c create mode 100644 contrib/ntp/libntp/work_thread.c delete mode 100644 contrib/ntp/libopts/COPYING.lgpl delete mode 100644 contrib/ntp/libopts/COPYING.mbsd delete mode 100644 contrib/ntp/libopts/Makefile.am delete mode 100644 contrib/ntp/libopts/Makefile.in delete mode 100644 contrib/ntp/libopts/README delete mode 100644 contrib/ntp/libopts/autoopts.c delete mode 100644 contrib/ntp/libopts/autoopts.h delete mode 100644 contrib/ntp/libopts/autoopts/options.h delete mode 100644 contrib/ntp/libopts/autoopts/usage-txt.h delete mode 100644 contrib/ntp/libopts/boolean.c delete mode 100644 contrib/ntp/libopts/compat/compat.h delete mode 100644 contrib/ntp/libopts/compat/pathfind.c delete mode 100644 contrib/ntp/libopts/compat/snprintf.c delete mode 100644 contrib/ntp/libopts/compat/strchr.c delete mode 100644 contrib/ntp/libopts/compat/strdup.c delete mode 100644 contrib/ntp/libopts/compat/windows-config.h delete mode 100644 contrib/ntp/libopts/configfile.c delete mode 100644 contrib/ntp/libopts/cook.c delete mode 100644 contrib/ntp/libopts/enumeration.c delete mode 100644 contrib/ntp/libopts/environment.c delete mode 100644 contrib/ntp/libopts/genshell.c delete mode 100644 contrib/ntp/libopts/genshell.h delete mode 100644 contrib/ntp/libopts/libopts.c delete mode 100644 contrib/ntp/libopts/load.c delete mode 100644 contrib/ntp/libopts/m4/libopts.m4 delete mode 100644 contrib/ntp/libopts/m4/liboptschk.m4 delete mode 100644 contrib/ntp/libopts/makeshell.c delete mode 100644 contrib/ntp/libopts/nested.c delete mode 100644 contrib/ntp/libopts/numeric.c delete mode 100644 contrib/ntp/libopts/pgusage.c delete mode 100644 contrib/ntp/libopts/proto.h delete mode 100644 contrib/ntp/libopts/putshell.c delete mode 100644 contrib/ntp/libopts/restore.c delete mode 100644 contrib/ntp/libopts/save.c delete mode 100644 contrib/ntp/libopts/sort.c delete mode 100644 contrib/ntp/libopts/stack.c delete mode 100644 contrib/ntp/libopts/streqvcmp.c delete mode 100644 contrib/ntp/libopts/text_mmap.c delete mode 100644 contrib/ntp/libopts/tokenize.c delete mode 100644 contrib/ntp/libopts/usage.c delete mode 100644 contrib/ntp/libopts/version.c create mode 100644 contrib/ntp/libparse/clk_sel240x.c delete mode 100644 contrib/ntp/m4/define_dir.m4 delete mode 100644 contrib/ntp/m4/hs_ulong_const.m4 delete mode 100644 contrib/ntp/m4/os_cflags.m4 create mode 100644 contrib/ntp/ntpd/complete.conf.in create mode 100644 contrib/ntp/ntpd/declcond.h create mode 100644 contrib/ntp/ntpd/invoke-ntp.conf.menu create mode 100644 contrib/ntp/ntpd/invoke-ntp.conf.texi create mode 100644 contrib/ntp/ntpd/invoke-ntp.keys.menu create mode 100644 contrib/ntp/ntpd/invoke-ntp.keys.texi rename contrib/ntp/ntpd/{ntpd-opts.menu => invoke-ntpd.menu} (100%) create mode 100644 contrib/ntp/ntpd/invoke-ntpd.texi create mode 100644 contrib/ntp/ntpd/keyword-gen-utd create mode 100644 contrib/ntp/ntpd/keyword-gen.c create mode 100644 contrib/ntp/ntpd/ntp.conf.5man create mode 100644 contrib/ntp/ntpd/ntp.conf.5mdoc create mode 100644 contrib/ntp/ntpd/ntp.conf.def create mode 100644 contrib/ntp/ntpd/ntp.conf.html create mode 100644 contrib/ntp/ntpd/ntp.conf.man.in create mode 100644 contrib/ntp/ntpd/ntp.conf.mdoc.in create mode 100644 contrib/ntp/ntpd/ntp.conf.texi create mode 100644 contrib/ntp/ntpd/ntp.keys.5man create mode 100644 contrib/ntp/ntpd/ntp.keys.5mdoc create mode 100644 contrib/ntp/ntpd/ntp.keys.def create mode 100644 contrib/ntp/ntpd/ntp.keys.html create mode 100644 contrib/ntp/ntpd/ntp.keys.man.in create mode 100644 contrib/ntp/ntpd/ntp.keys.mdoc.in create mode 100644 contrib/ntp/ntpd/ntp.keys.texi delete mode 100644 contrib/ntp/ntpd/ntp_intres.c create mode 100644 contrib/ntp/ntpd/ntp_keyword.h create mode 100644 contrib/ntp/ntpd/ntp_leapsec.c create mode 100644 contrib/ntp/ntpd/ntp_leapsec.h create mode 100644 contrib/ntp/ntpd/ntp_parser.c create mode 100644 contrib/ntp/ntpd/ntp_parser.h create mode 100644 contrib/ntp/ntpd/ntp_prio_q.c create mode 100644 contrib/ntp/ntpd/ntp_scanner.c create mode 100644 contrib/ntp/ntpd/ntp_scanner.h create mode 100644 contrib/ntp/ntpd/ntp_signd.c delete mode 100644 contrib/ntp/ntpd/ntpd-opts.texi delete mode 100644 contrib/ntp/ntpd/ntpd.1 create mode 100644 contrib/ntp/ntpd/ntpd.1ntpdman create mode 100644 contrib/ntp/ntpd/ntpd.1ntpdmdoc create mode 100644 contrib/ntp/ntpd/ntpd.html create mode 100644 contrib/ntp/ntpd/ntpd.man.in create mode 100644 contrib/ntp/ntpd/ntpd.mdoc.in create mode 100644 contrib/ntp/ntpd/ntpd.texi delete mode 100644 contrib/ntp/ntpd/ntpdsim-opts.c delete mode 100644 contrib/ntp/ntpd/ntpdsim-opts.def delete mode 100644 contrib/ntp/ntpd/ntpdsim-opts.h delete mode 100644 contrib/ntp/ntpd/ntpdsim-opts.menu delete mode 100644 contrib/ntp/ntpd/ntpdsim-opts.texi delete mode 100644 contrib/ntp/ntpd/ntpdsim.1 create mode 100644 contrib/ntp/ntpd/rc_cmdlength.c create mode 100644 contrib/ntp/ntpd/refclock_gpsdjson.c delete mode 100644 contrib/ntp/ntpd/refclock_trak.c create mode 100644 contrib/ntp/ntpd/refclock_tsyncpci.c delete mode 100644 contrib/ntp/ntpdate/ntptime_config.c delete mode 100644 contrib/ntp/ntpdate/ntptimeset.c rename contrib/ntp/ntpdc/{ntpdc-opts.menu => invoke-ntpdc.menu} (100%) create mode 100644 contrib/ntp/ntpdc/invoke-ntpdc.texi delete mode 100644 contrib/ntp/ntpdc/ntpdc-opts.texi delete mode 100644 contrib/ntp/ntpdc/ntpdc.1 create mode 100644 contrib/ntp/ntpdc/ntpdc.1ntpdcman create mode 100644 contrib/ntp/ntpdc/ntpdc.1ntpdcmdoc create mode 100644 contrib/ntp/ntpdc/ntpdc.html create mode 100644 contrib/ntp/ntpdc/ntpdc.man.in create mode 100644 contrib/ntp/ntpdc/ntpdc.mdoc.in create mode 100644 contrib/ntp/ntpdc/ntpdc.texi rename contrib/ntp/ntpq/{ntpq-opts.menu => invoke-ntpq.menu} (100%) create mode 100644 contrib/ntp/ntpq/invoke-ntpq.texi create mode 100644 contrib/ntp/ntpq/libntpq.c create mode 100644 contrib/ntp/ntpq/libntpq.h create mode 100644 contrib/ntp/ntpq/libntpq_subs.c delete mode 100644 contrib/ntp/ntpq/ntpq-opts.texi delete mode 100644 contrib/ntp/ntpq/ntpq.1 create mode 100644 contrib/ntp/ntpq/ntpq.1ntpqman create mode 100644 contrib/ntp/ntpq/ntpq.1ntpqmdoc create mode 100644 contrib/ntp/ntpq/ntpq.html create mode 100644 contrib/ntp/ntpq/ntpq.man.in create mode 100644 contrib/ntp/ntpq/ntpq.mdoc.in create mode 100644 contrib/ntp/ntpq/ntpq.texi create mode 100644 contrib/ntp/ntpsnmpd/Makefile.am create mode 100644 contrib/ntp/ntpsnmpd/Makefile.in create mode 100644 contrib/ntp/ntpsnmpd/README create mode 100644 contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.menu create mode 100644 contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.texi create mode 100644 contrib/ntp/ntpsnmpd/netsnmp_daemonize.c create mode 100644 contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c create mode 100644 contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h create mode 100644 contrib/ntp/ntpsnmpd/ntp_snmp.h create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdman create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd.c create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd.html create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd.man.in create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd.mdoc.in create mode 100644 contrib/ntp/ntpsnmpd/ntpsnmpd.texi create mode 100644 contrib/ntp/ntpsnmpd/ntpv4-mib.mib delete mode 100755 contrib/ntp/scripts/VersionName create mode 100644 contrib/ntp/scripts/build/Makefile.am create mode 100644 contrib/ntp/scripts/build/Makefile.in create mode 100755 contrib/ntp/scripts/build/UpdatePoint create mode 100755 contrib/ntp/scripts/build/VersionName create mode 100755 contrib/ntp/scripts/build/check--help create mode 100755 contrib/ntp/scripts/build/checkChangeLog create mode 100755 contrib/ntp/scripts/build/checkHtmlFileDates rename contrib/ntp/scripts/{ => build}/fixautomakedepsmagic (100%) mode change 100644 => 100755 create mode 100755 contrib/ntp/scripts/build/genCommitLog create mode 100755 contrib/ntp/scripts/build/genver rename contrib/ntp/scripts/{ => build}/mkver.in (78%) create mode 100755 contrib/ntp/scripts/build/updateBEDate delete mode 100644 contrib/ntp/scripts/calc_tickadj.in create mode 100644 contrib/ntp/scripts/calc_tickadj/Makefile.am create mode 100644 contrib/ntp/scripts/calc_tickadj/Makefile.in create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts.def create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjman create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj.html create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj.in create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj.man.in create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj.mdoc.in create mode 100644 contrib/ntp/scripts/calc_tickadj/calc_tickadj.texi create mode 100644 contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.menu create mode 100644 contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.texi delete mode 100644 contrib/ntp/scripts/checktime.in rename contrib/ntp/scripts/{ => deprecated}/freq_adj.in (100%) rename contrib/ntp/scripts/{ => deprecated}/hpadjtime.sh (100%) rename contrib/ntp/scripts/{ => deprecated}/html2man.in (51%) rename contrib/ntp/scripts/{ => deprecated}/ntp-close (100%) rename contrib/ntp/scripts/{ => deprecated}/ntp-groper (100%) rename contrib/ntp/scripts/{ => deprecated}/ntp-restart (100%) rename contrib/ntp/scripts/{ => deprecated}/ntp-status (100%) delete mode 100755 contrib/ntp/scripts/genCommitLog delete mode 100755 contrib/ntp/scripts/genver create mode 100644 contrib/ntp/scripts/invoke-plot_summary.menu create mode 100644 contrib/ntp/scripts/invoke-plot_summary.texi create mode 100644 contrib/ntp/scripts/invoke-summary.menu create mode 100644 contrib/ntp/scripts/invoke-summary.texi create mode 100644 contrib/ntp/scripts/lib/Makefile.am create mode 100644 contrib/ntp/scripts/lib/Makefile.in create mode 100644 contrib/ntp/scripts/lib/NTP/Util.pm delete mode 100644 contrib/ntp/scripts/ntp-wait.in create mode 100644 contrib/ntp/scripts/ntp-wait/Makefile.am create mode 100644 contrib/ntp/scripts/ntp-wait/Makefile.in create mode 100644 contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.menu create mode 100644 contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.texi create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait-opts create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait-opts.def create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitman create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitmdoc create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait.html create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait.in create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait.man.in create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait.mdoc.in create mode 100644 contrib/ntp/scripts/ntp-wait/ntp-wait.texi delete mode 100644 contrib/ntp/scripts/ntpsweep.in create mode 100644 contrib/ntp/scripts/ntpsweep/Makefile.am create mode 100644 contrib/ntp/scripts/ntpsweep/Makefile.in create mode 100644 contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.menu create mode 100644 contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.texi create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep-opts create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep-opts.def create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepman create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepmdoc create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep.html create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep.in create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep.man.in create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep.mdoc.in create mode 100644 contrib/ntp/scripts/ntpsweep/ntpsweep.texi delete mode 100755 contrib/ntp/scripts/ntptrace.in create mode 100644 contrib/ntp/scripts/ntptrace/Makefile.am create mode 100644 contrib/ntp/scripts/ntptrace/Makefile.in create mode 100644 contrib/ntp/scripts/ntptrace/invoke-ntptrace.menu create mode 100644 contrib/ntp/scripts/ntptrace/invoke-ntptrace.texi create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace-opts create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace-opts.def create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace.1ntptraceman create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace.1ntptracemdoc create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace.html create mode 100755 contrib/ntp/scripts/ntptrace/ntptrace.in create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace.man.in create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace.mdoc.in create mode 100644 contrib/ntp/scripts/ntptrace/ntptrace.texi create mode 100644 contrib/ntp/scripts/plot_summary-opts create mode 100644 contrib/ntp/scripts/plot_summary-opts.def create mode 100644 contrib/ntp/scripts/plot_summary.1plot_summaryman create mode 100644 contrib/ntp/scripts/plot_summary.1plot_summarymdoc create mode 100644 contrib/ntp/scripts/plot_summary.html create mode 100644 contrib/ntp/scripts/plot_summary.man.in create mode 100644 contrib/ntp/scripts/plot_summary.mdoc.in create mode 100644 contrib/ntp/scripts/plot_summary.texi create mode 100644 contrib/ntp/scripts/rc/README create mode 100644 contrib/ntp/scripts/rc/ntpd create mode 100644 contrib/ntp/scripts/rc/ntpwait create mode 100644 contrib/ntp/scripts/rc/rc.d/TIMESYNC create mode 100644 contrib/ntp/scripts/rc/rc.d/ntpd create mode 100644 contrib/ntp/scripts/rc/rc.d/ntpwait delete mode 100644 contrib/ntp/scripts/rc1/postinstall delete mode 100644 contrib/ntp/scripts/rc1/preinstall delete mode 100644 contrib/ntp/scripts/rc1/preremove delete mode 100644 contrib/ntp/scripts/rc1/prototype delete mode 100644 contrib/ntp/scripts/rc1/xntp delete mode 100644 contrib/ntp/scripts/rc2/local.ntpd create mode 100644 contrib/ntp/scripts/summary-opts create mode 100644 contrib/ntp/scripts/summary-opts.def create mode 100644 contrib/ntp/scripts/summary.1summaryman create mode 100644 contrib/ntp/scripts/summary.1summarymdoc create mode 100644 contrib/ntp/scripts/summary.html create mode 100644 contrib/ntp/scripts/summary.man.in create mode 100644 contrib/ntp/scripts/summary.mdoc.in create mode 100644 contrib/ntp/scripts/summary.texi create mode 100644 contrib/ntp/scripts/update-leap/Makefile.am create mode 100644 contrib/ntp/scripts/update-leap/Makefile.in create mode 100644 contrib/ntp/scripts/update-leap/invoke-update-leap.menu create mode 100644 contrib/ntp/scripts/update-leap/invoke-update-leap.texi create mode 100644 contrib/ntp/scripts/update-leap/update-leap-opts create mode 100644 contrib/ntp/scripts/update-leap/update-leap-opts.def create mode 100644 contrib/ntp/scripts/update-leap/update-leap.1update-leapman create mode 100644 contrib/ntp/scripts/update-leap/update-leap.1update-leapmdoc create mode 100644 contrib/ntp/scripts/update-leap/update-leap.html create mode 100755 contrib/ntp/scripts/update-leap/update-leap.in create mode 100644 contrib/ntp/scripts/update-leap/update-leap.man.in create mode 100644 contrib/ntp/scripts/update-leap/update-leap.mdoc.in create mode 100755 contrib/ntp/scripts/update-leap/update-leap.sh create mode 100644 contrib/ntp/scripts/update-leap/update-leap.texi delete mode 100644 contrib/ntp/sntp/README create mode 100644 contrib/ntp/sntp/ag-tpl/0-old/Mdoc.pm create mode 100644 contrib/ntp/sntp/ag-tpl/0-old/agman-cmd.tpl create mode 100644 contrib/ntp/sntp/ag-tpl/0-old/agmdoc-cmd.tpl create mode 100644 contrib/ntp/sntp/ag-tpl/0-old/cmd-doc.tlib create mode 100644 contrib/ntp/sntp/ag-tpl/0-old/mdoc-synopsis.tlib create mode 100755 contrib/ntp/sntp/ag-tpl/0-old/mdoc2man create mode 100755 contrib/ntp/sntp/ag-tpl/0-old/mdoc2texi create mode 100644 contrib/ntp/sntp/ag-tpl/0-old/perlopt.tpl create mode 100644 contrib/ntp/sntp/ag-tpl/Mdoc.pm create mode 100755 contrib/ntp/sntp/ag-tpl/mdoc2man delete mode 100644 contrib/ntp/sntp/autogen-version.def create mode 100644 contrib/ntp/sntp/check-libntp.mf create mode 100644 contrib/ntp/sntp/check-libopts.mf create mode 100644 contrib/ntp/sntp/crypto.c create mode 100644 contrib/ntp/sntp/crypto.h create mode 100644 contrib/ntp/sntp/data_formats.h create mode 100644 contrib/ntp/sntp/deps-ver create mode 100644 contrib/ntp/sntp/depsver.mf delete mode 100644 contrib/ntp/sntp/header.h create mode 100644 contrib/ntp/sntp/include/Makefile.am create mode 100644 contrib/ntp/sntp/include/Makefile.in create mode 100644 contrib/ntp/sntp/include/autogen-version.def create mode 100644 contrib/ntp/sntp/include/copyright.def create mode 100644 contrib/ntp/sntp/include/debug-opt.def rename contrib/ntp/{ => sntp}/include/homerc.def (100%) create mode 100644 contrib/ntp/sntp/include/ntp.lic create mode 100644 contrib/ntp/sntp/include/version.def create mode 100644 contrib/ntp/sntp/include/version.texi create mode 100644 contrib/ntp/sntp/includes.mf delete mode 100644 contrib/ntp/sntp/internet.c delete mode 100644 contrib/ntp/sntp/internet.h rename contrib/ntp/sntp/{sntp-opts.menu => invoke-sntp.menu} (100%) create mode 100644 contrib/ntp/sntp/invoke-sntp.texi delete mode 100644 contrib/ntp/sntp/kludges.h create mode 100644 contrib/ntp/sntp/kod_management.c create mode 100644 contrib/ntp/sntp/kod_management.h create mode 100644 contrib/ntp/sntp/libevent/ChangeLog create mode 100644 contrib/ntp/sntp/libevent/ChangeLog-1.4 create mode 100644 contrib/ntp/sntp/libevent/ChangeLog-2.0 create mode 100644 contrib/ntp/sntp/libevent/Doxyfile create mode 100644 contrib/ntp/sntp/libevent/LICENSE create mode 100644 contrib/ntp/sntp/libevent/Makefile.am create mode 100644 contrib/ntp/sntp/libevent/Makefile.in create mode 100644 contrib/ntp/sntp/libevent/Makefile.nmake create mode 100644 contrib/ntp/sntp/libevent/WIN32-Code/nmake/evconfig-private.h create mode 100644 contrib/ntp/sntp/libevent/WIN32-Code/nmake/event2/event-config.h create mode 100644 contrib/ntp/sntp/libevent/WIN32-Code/tree.h rename contrib/ntp/{arlib => sntp/libevent}/aclocal.m4 (52%) create mode 100644 contrib/ntp/sntp/libevent/arc4random.c create mode 100755 contrib/ntp/sntp/libevent/autogen.sh create mode 100644 contrib/ntp/sntp/libevent/buffer.c create mode 100644 contrib/ntp/sntp/libevent/buffer_iocp.c create mode 100644 contrib/ntp/sntp/libevent/bufferevent-internal.h create mode 100644 contrib/ntp/sntp/libevent/bufferevent.c create mode 100644 contrib/ntp/sntp/libevent/bufferevent_async.c create mode 100644 contrib/ntp/sntp/libevent/bufferevent_filter.c create mode 100644 contrib/ntp/sntp/libevent/bufferevent_openssl.c create mode 100644 contrib/ntp/sntp/libevent/bufferevent_pair.c create mode 100644 contrib/ntp/sntp/libevent/bufferevent_ratelim.c create mode 100644 contrib/ntp/sntp/libevent/bufferevent_sock.c create mode 100755 contrib/ntp/sntp/libevent/build-aux/ar-lib create mode 100755 contrib/ntp/sntp/libevent/build-aux/compile create mode 100755 contrib/ntp/sntp/libevent/build-aux/config.guess create mode 100755 contrib/ntp/sntp/libevent/build-aux/config.sub rename contrib/ntp/{arlib => sntp/libevent/build-aux}/depcomp (77%) create mode 100755 contrib/ntp/sntp/libevent/build-aux/install-sh create mode 100755 contrib/ntp/sntp/libevent/build-aux/ltmain.sh rename contrib/ntp/{arlib => sntp/libevent/build-aux}/missing (85%) create mode 100755 contrib/ntp/sntp/libevent/build-aux/test-driver create mode 100755 contrib/ntp/sntp/libevent/build-aux/ylwrap create mode 100644 contrib/ntp/sntp/libevent/changelist-internal.h create mode 100644 contrib/ntp/sntp/libevent/compat/sys/queue.h create mode 100644 contrib/ntp/sntp/libevent/config.h.in create mode 100755 contrib/ntp/sntp/libevent/configure create mode 100644 contrib/ntp/sntp/libevent/configure.ac create mode 100644 contrib/ntp/sntp/libevent/defer-internal.h create mode 100644 contrib/ntp/sntp/libevent/devpoll.c create mode 100644 contrib/ntp/sntp/libevent/epoll.c create mode 100644 contrib/ntp/sntp/libevent/epoll_sub.c create mode 100644 contrib/ntp/sntp/libevent/epolltable-internal.h create mode 100644 contrib/ntp/sntp/libevent/evbuffer-internal.h create mode 100644 contrib/ntp/sntp/libevent/evconfig-private.h create mode 100644 contrib/ntp/sntp/libevent/evconfig-private.h.in create mode 100644 contrib/ntp/sntp/libevent/evdns.c create mode 100644 contrib/ntp/sntp/libevent/event-internal.h create mode 100644 contrib/ntp/sntp/libevent/event.c create mode 100644 contrib/ntp/sntp/libevent/event_iocp.c create mode 100755 contrib/ntp/sntp/libevent/event_rpcgen.py create mode 100644 contrib/ntp/sntp/libevent/event_tagging.c create mode 100644 contrib/ntp/sntp/libevent/evmap-internal.h create mode 100644 contrib/ntp/sntp/libevent/evmap.c create mode 100644 contrib/ntp/sntp/libevent/evport.c create mode 100644 contrib/ntp/sntp/libevent/evrpc-internal.h create mode 100644 contrib/ntp/sntp/libevent/evrpc.c create mode 100644 contrib/ntp/sntp/libevent/evsignal-internal.h create mode 100644 contrib/ntp/sntp/libevent/evthread-internal.h create mode 100644 contrib/ntp/sntp/libevent/evthread.c create mode 100644 contrib/ntp/sntp/libevent/evthread_pthread.c create mode 100644 contrib/ntp/sntp/libevent/evthread_win32.c create mode 100644 contrib/ntp/sntp/libevent/evutil.c create mode 100644 contrib/ntp/sntp/libevent/evutil_rand.c create mode 100644 contrib/ntp/sntp/libevent/evutil_time.c create mode 100644 contrib/ntp/sntp/libevent/ht-internal.h create mode 100644 contrib/ntp/sntp/libevent/http-internal.h create mode 100644 contrib/ntp/sntp/libevent/http.c create mode 100644 contrib/ntp/sntp/libevent/include/evdns.h create mode 100644 contrib/ntp/sntp/libevent/include/event.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/buffer.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/buffer_compat.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/bufferevent.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/bufferevent_compat.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/bufferevent_ssl.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/bufferevent_struct.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/dns.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/dns_compat.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/dns_struct.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/event.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/event_compat.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/event_struct.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/http.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/http_compat.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/http_struct.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/keyvalq_struct.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/listener.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/rpc.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/rpc_compat.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/rpc_struct.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/tag.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/tag_compat.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/thread.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/util.h create mode 100644 contrib/ntp/sntp/libevent/include/event2/visibility.h create mode 100644 contrib/ntp/sntp/libevent/include/evhttp.h create mode 100644 contrib/ntp/sntp/libevent/include/evrpc.h create mode 100644 contrib/ntp/sntp/libevent/include/evutil.h create mode 100644 contrib/ntp/sntp/libevent/include/include.am create mode 100644 contrib/ntp/sntp/libevent/iocp-internal.h create mode 100644 contrib/ntp/sntp/libevent/ipv6-internal.h create mode 100644 contrib/ntp/sntp/libevent/kqueue-internal.h create mode 100644 contrib/ntp/sntp/libevent/kqueue.c create mode 100644 contrib/ntp/sntp/libevent/libevent.pc.in create mode 100644 contrib/ntp/sntp/libevent/libevent_openssl.pc.in create mode 100644 contrib/ntp/sntp/libevent/libevent_pthreads.pc.in create mode 100644 contrib/ntp/sntp/libevent/listener.c create mode 100644 contrib/ntp/sntp/libevent/log-internal.h create mode 100644 contrib/ntp/sntp/libevent/log.c create mode 100644 contrib/ntp/sntp/libevent/m4/ac_backport_259_ssizet.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/acx_pthread.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/libevent_openssl.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/libtool.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/ltoptions.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/ltsugar.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/ltversion.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/lt~obsolete.m4 create mode 100644 contrib/ntp/sntp/libevent/m4/ntp_pkg_config.m4 create mode 100644 contrib/ntp/sntp/libevent/make-event-config.sed create mode 100644 contrib/ntp/sntp/libevent/minheap-internal.h create mode 100644 contrib/ntp/sntp/libevent/mm-internal.h create mode 100644 contrib/ntp/sntp/libevent/poll.c create mode 100644 contrib/ntp/sntp/libevent/ratelim-internal.h create mode 100644 contrib/ntp/sntp/libevent/select.c create mode 100644 contrib/ntp/sntp/libevent/signal.c create mode 100644 contrib/ntp/sntp/libevent/strlcpy-internal.h create mode 100644 contrib/ntp/sntp/libevent/strlcpy.c create mode 100644 contrib/ntp/sntp/libevent/test/Makefile.nmake create mode 100644 contrib/ntp/sntp/libevent/test/bench.c create mode 100644 contrib/ntp/sntp/libevent/test/bench_cascade.c create mode 100644 contrib/ntp/sntp/libevent/test/bench_http.c create mode 100644 contrib/ntp/sntp/libevent/test/bench_httpclient.c create mode 100755 contrib/ntp/sntp/libevent/test/check-dumpevents.py create mode 100644 contrib/ntp/sntp/libevent/test/include.am create mode 100644 contrib/ntp/sntp/libevent/test/regress.c create mode 100644 contrib/ntp/sntp/libevent/test/regress.gen.c create mode 100644 contrib/ntp/sntp/libevent/test/regress.gen.h create mode 100644 contrib/ntp/sntp/libevent/test/regress.h create mode 100644 contrib/ntp/sntp/libevent/test/regress.rpc create mode 100644 contrib/ntp/sntp/libevent/test/regress_buffer.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_bufferevent.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_dns.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_et.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_finalize.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_http.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_iocp.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_listener.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_main.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_minheap.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_rpc.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_ssl.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_testutils.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_testutils.h create mode 100644 contrib/ntp/sntp/libevent/test/regress_thread.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_thread.h create mode 100644 contrib/ntp/sntp/libevent/test/regress_util.c create mode 100644 contrib/ntp/sntp/libevent/test/regress_zlib.c create mode 100755 contrib/ntp/sntp/libevent/test/rpcgen_wrapper.sh create mode 100644 contrib/ntp/sntp/libevent/test/test-changelist.c create mode 100644 contrib/ntp/sntp/libevent/test/test-closed.c create mode 100644 contrib/ntp/sntp/libevent/test/test-dumpevents.c create mode 100644 contrib/ntp/sntp/libevent/test/test-eof.c create mode 100644 contrib/ntp/sntp/libevent/test/test-fdleak.c create mode 100644 contrib/ntp/sntp/libevent/test/test-init.c create mode 100644 contrib/ntp/sntp/libevent/test/test-ratelim.c create mode 100644 contrib/ntp/sntp/libevent/test/test-time.c create mode 100644 contrib/ntp/sntp/libevent/test/test-weof.c create mode 100755 contrib/ntp/sntp/libevent/test/test.sh create mode 100644 contrib/ntp/sntp/libevent/test/tinytest.c create mode 100644 contrib/ntp/sntp/libevent/test/tinytest.h create mode 100644 contrib/ntp/sntp/libevent/test/tinytest_local.h create mode 100644 contrib/ntp/sntp/libevent/test/tinytest_macros.h create mode 100644 contrib/ntp/sntp/libevent/time-internal.h create mode 100644 contrib/ntp/sntp/libevent/util-internal.h create mode 100644 contrib/ntp/sntp/libevent/whatsnew-2.0.txt create mode 100644 contrib/ntp/sntp/libevent/whatsnew-2.1.txt create mode 100644 contrib/ntp/sntp/libevent/win32select.c create mode 100644 contrib/ntp/sntp/libopts/COPYING.gplv3 delete mode 100644 contrib/ntp/sntp/libopts/COPYING.lgpl create mode 100644 contrib/ntp/sntp/libopts/COPYING.lgplv3 create mode 100644 contrib/ntp/sntp/libopts/ag-char-map.h create mode 100644 contrib/ntp/sntp/libopts/alias.c create mode 100644 contrib/ntp/sntp/libopts/ao-strs.c create mode 100644 contrib/ntp/sntp/libopts/ao-strs.h create mode 100644 contrib/ntp/sntp/libopts/autoopts/project.h create mode 100644 contrib/ntp/sntp/libopts/check.c create mode 100644 contrib/ntp/sntp/libopts/compat/_Noreturn.h create mode 100644 contrib/ntp/sntp/libopts/enum.c delete mode 100644 contrib/ntp/sntp/libopts/enumeration.c create mode 100644 contrib/ntp/sntp/libopts/env.c delete mode 100644 contrib/ntp/sntp/libopts/environment.c create mode 100644 contrib/ntp/sntp/libopts/file.c create mode 100644 contrib/ntp/sntp/libopts/find.c create mode 100644 contrib/ntp/sntp/libopts/gettext.h create mode 100644 contrib/ntp/sntp/libopts/init.c create mode 100644 contrib/ntp/sntp/libopts/intprops.h create mode 100644 contrib/ntp/sntp/libopts/m4/stdnoreturn.m4 create mode 100644 contrib/ntp/sntp/libopts/option-value-type.c create mode 100644 contrib/ntp/sntp/libopts/option-value-type.h create mode 100644 contrib/ntp/sntp/libopts/option-xat-attribute.c create mode 100644 contrib/ntp/sntp/libopts/option-xat-attribute.h create mode 100644 contrib/ntp/sntp/libopts/parse-duration.c create mode 100644 contrib/ntp/sntp/libopts/parse-duration.h create mode 100644 contrib/ntp/sntp/libopts/reset.c create mode 100644 contrib/ntp/sntp/libopts/stdnoreturn.in.h create mode 100644 contrib/ntp/sntp/libopts/time.c create mode 100644 contrib/ntp/sntp/libpkgver/colcomp.c create mode 100644 contrib/ntp/sntp/libpkgver/pkgver.h create mode 100644 contrib/ntp/sntp/loc/README create mode 100644 contrib/ntp/sntp/loc/darwin create mode 100644 contrib/ntp/sntp/loc/debian create mode 100644 contrib/ntp/sntp/loc/freebsd create mode 100644 contrib/ntp/sntp/loc/legacy create mode 100644 contrib/ntp/sntp/loc/netbsd create mode 100644 contrib/ntp/sntp/loc/redhat create mode 100644 contrib/ntp/sntp/loc/solaris create mode 100644 contrib/ntp/sntp/log.c create mode 100644 contrib/ntp/sntp/log.h create mode 100644 contrib/ntp/sntp/m4/ax_c99_struct_init.m4 create mode 100644 contrib/ntp/sntp/m4/define_dir.m4 create mode 100644 contrib/ntp/sntp/m4/hms_search_lib.m4 create mode 100644 contrib/ntp/sntp/m4/libtool.m4 create mode 100644 contrib/ntp/sntp/m4/ltoptions.m4 create mode 100644 contrib/ntp/sntp/m4/ltsugar.m4 create mode 100644 contrib/ntp/sntp/m4/ltversion.m4 create mode 100644 contrib/ntp/sntp/m4/lt~obsolete.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_cacheversion.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_compiler.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_crosscompile.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_crypto_rand.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_debug.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_dir_sep.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_facilitynames.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_googletest.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_ipv6.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_lib_m.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_libevent.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_libntp.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_lineeditlibs.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_locinfo.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_openssl.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_pkg_config.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_problemtests.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_prog_cc.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_rlimit.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_sntp.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_sysexits.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_unitytest.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_ver_suffix.m4 create mode 100644 contrib/ntp/sntp/m4/ntp_vpathhack.m4 create mode 100644 contrib/ntp/sntp/m4/openldap-thread-check.m4 create mode 100644 contrib/ntp/sntp/m4/openldap.m4 create mode 100644 contrib/ntp/sntp/m4/os_cflags.m4 create mode 100644 contrib/ntp/sntp/m4/snprintf.m4 create mode 100644 contrib/ntp/sntp/m4/version.m4 create mode 100644 contrib/ntp/sntp/main.h create mode 100644 contrib/ntp/sntp/networking.c create mode 100644 contrib/ntp/sntp/networking.h create mode 100644 contrib/ntp/sntp/scm-rev create mode 100644 contrib/ntp/sntp/scripts/Makefile.am create mode 100644 contrib/ntp/sntp/scripts/Makefile.in create mode 100755 contrib/ntp/sntp/scripts/cvo.sh create mode 100755 contrib/ntp/sntp/scripts/genLocInfo create mode 100644 contrib/ntp/sntp/scripts/mansec2subst.sed delete mode 100644 contrib/ntp/sntp/sntp-opts.texi delete mode 100644 contrib/ntp/sntp/sntp.1 create mode 100644 contrib/ntp/sntp/sntp.1sntpman create mode 100644 contrib/ntp/sntp/sntp.1sntpmdoc create mode 100644 contrib/ntp/sntp/sntp.c create mode 100644 contrib/ntp/sntp/sntp.html create mode 100644 contrib/ntp/sntp/sntp.man.in create mode 100644 contrib/ntp/sntp/sntp.mdoc.in create mode 100644 contrib/ntp/sntp/sntp.texi delete mode 100644 contrib/ntp/sntp/socket.c create mode 100644 contrib/ntp/sntp/tests/Makefile.am create mode 100644 contrib/ntp/sntp/tests/Makefile.in create mode 100644 contrib/ntp/sntp/tests/crypto.c create mode 100644 contrib/ntp/sntp/tests/data/debug-input-lfp-bin create mode 100644 contrib/ntp/sntp/tests/data/debug-input-lfp-dec create mode 100644 contrib/ntp/sntp/tests/data/debug-input-pkt create mode 100644 contrib/ntp/sntp/tests/data/key-test-ascii create mode 100644 contrib/ntp/sntp/tests/data/key-test-comments rename contrib/ntp/{libopts/MakeDefs.inc => sntp/tests/data/key-test-empty} (100%) create mode 100644 contrib/ntp/sntp/tests/data/key-test-hex create mode 100644 contrib/ntp/sntp/tests/data/key-test-invalid-hex create mode 100644 contrib/ntp/sntp/tests/data/kod-expected-multiple create mode 100644 contrib/ntp/sntp/tests/data/kod-expected-single create mode 100644 contrib/ntp/sntp/tests/data/kod-test-blanks create mode 100644 contrib/ntp/sntp/tests/data/kod-test-correct create mode 100644 contrib/ntp/sntp/tests/data/kod-test-empty create mode 100644 contrib/ntp/sntp/tests/fileHandlingTest.c create mode 100644 contrib/ntp/sntp/tests/fileHandlingTest.h.in create mode 100644 contrib/ntp/sntp/tests/keyFile.c create mode 100644 contrib/ntp/sntp/tests/kodDatabase.c create mode 100644 contrib/ntp/sntp/tests/kodFile.c create mode 100644 contrib/ntp/sntp/tests/networking.c create mode 100644 contrib/ntp/sntp/tests/packetHandling.c create mode 100644 contrib/ntp/sntp/tests/packetProcessing.c create mode 100644 contrib/ntp/sntp/tests/run-crypto.c create mode 100644 contrib/ntp/sntp/tests/run-keyFile.c create mode 100644 contrib/ntp/sntp/tests/run-kodDatabase.c create mode 100644 contrib/ntp/sntp/tests/run-kodFile.c create mode 100644 contrib/ntp/sntp/tests/run-networking.c create mode 100644 contrib/ntp/sntp/tests/run-packetHandling.c create mode 100644 contrib/ntp/sntp/tests/run-packetProcessing.c create mode 100644 contrib/ntp/sntp/tests/run-t-log.c create mode 100644 contrib/ntp/sntp/tests/run-utilities.c create mode 100644 contrib/ntp/sntp/tests/sntptest.c create mode 100644 contrib/ntp/sntp/tests/sntptest.h create mode 100644 contrib/ntp/sntp/tests/t-log.c create mode 100755 contrib/ntp/sntp/tests/tests-runner create mode 100644 contrib/ntp/sntp/tests/utilities.c delete mode 100644 contrib/ntp/sntp/timing.c create mode 100644 contrib/ntp/sntp/unity/Makefile.am create mode 100644 contrib/ntp/sntp/unity/Makefile.in create mode 100644 contrib/ntp/sntp/unity/auto/colour_prompt.rb create mode 100644 contrib/ntp/sntp/unity/auto/colour_reporter.rb create mode 100644 contrib/ntp/sntp/unity/auto/generate_config.yml create mode 100644 contrib/ntp/sntp/unity/auto/generate_module.rb create mode 100644 contrib/ntp/sntp/unity/auto/generate_test_runner.rb create mode 100755 contrib/ntp/sntp/unity/auto/parseOutput.rb create mode 100644 contrib/ntp/sntp/unity/auto/runner_maybe.c create mode 100644 contrib/ntp/sntp/unity/auto/test_file_filter.rb create mode 100755 contrib/ntp/sntp/unity/auto/type_sanitizer.rb create mode 100755 contrib/ntp/sntp/unity/auto/unity_test_summary.py create mode 100644 contrib/ntp/sntp/unity/auto/unity_test_summary.rb create mode 100644 contrib/ntp/sntp/unity/unity.c create mode 100644 contrib/ntp/sntp/unity/unity.h create mode 100644 contrib/ntp/sntp/unity/unity_config.h create mode 100644 contrib/ntp/sntp/unity/unity_fixture.c create mode 100644 contrib/ntp/sntp/unity/unity_fixture.h create mode 100644 contrib/ntp/sntp/unity/unity_fixture_internals.h create mode 100644 contrib/ntp/sntp/unity/unity_fixture_malloc_overrides.h create mode 100644 contrib/ntp/sntp/unity/unity_internals.h delete mode 100644 contrib/ntp/sntp/unix.c create mode 100644 contrib/ntp/sntp/utilities.c create mode 100644 contrib/ntp/sntp/utilities.h create mode 100644 contrib/ntp/sntp/version.c delete mode 100644 contrib/ntp/sntp/version.def create mode 100644 contrib/ntp/tests/Makefile.am create mode 100644 contrib/ntp/tests/Makefile.in create mode 100644 contrib/ntp/tests/bug-2803/Makefile.am create mode 100644 contrib/ntp/tests/bug-2803/Makefile.in create mode 100644 contrib/ntp/tests/bug-2803/bug-2803.c create mode 100644 contrib/ntp/tests/bug-2803/run-bug-2803.c create mode 100644 contrib/ntp/tests/libntp/Makefile.am create mode 100644 contrib/ntp/tests/libntp/Makefile.in create mode 100644 contrib/ntp/tests/libntp/a_md5encrypt.c create mode 100644 contrib/ntp/tests/libntp/atoint.c create mode 100644 contrib/ntp/tests/libntp/atouint.c create mode 100644 contrib/ntp/tests/libntp/authkeys.c create mode 100644 contrib/ntp/tests/libntp/buftvtots.c create mode 100644 contrib/ntp/tests/libntp/calendar.c create mode 100644 contrib/ntp/tests/libntp/caljulian.c create mode 100644 contrib/ntp/tests/libntp/caltontp.c create mode 100644 contrib/ntp/tests/libntp/calyearstart.c create mode 100644 contrib/ntp/tests/libntp/clocktime.c create mode 100644 contrib/ntp/tests/libntp/decodenetnum.c create mode 100644 contrib/ntp/tests/libntp/hextoint.c create mode 100644 contrib/ntp/tests/libntp/hextolfp.c create mode 100644 contrib/ntp/tests/libntp/humandate.c create mode 100644 contrib/ntp/tests/libntp/lfpfunc.c create mode 100644 contrib/ntp/tests/libntp/lfptest.c create mode 100644 contrib/ntp/tests/libntp/lfptest.h create mode 100644 contrib/ntp/tests/libntp/lfptostr.c create mode 100644 contrib/ntp/tests/libntp/modetoa.c create mode 100644 contrib/ntp/tests/libntp/msyslog.c create mode 100644 contrib/ntp/tests/libntp/netof.c create mode 100644 contrib/ntp/tests/libntp/numtoa.c create mode 100644 contrib/ntp/tests/libntp/numtohost.c create mode 100644 contrib/ntp/tests/libntp/octtoint.c create mode 100644 contrib/ntp/tests/libntp/prettydate.c create mode 100644 contrib/ntp/tests/libntp/recvbuff.c create mode 100644 contrib/ntp/tests/libntp/refidsmear.c create mode 100644 contrib/ntp/tests/libntp/refnumtoa.c create mode 100644 contrib/ntp/tests/libntp/run-a_md5encrypt.c create mode 100644 contrib/ntp/tests/libntp/run-atoint.c create mode 100644 contrib/ntp/tests/libntp/run-atouint.c create mode 100644 contrib/ntp/tests/libntp/run-authkeys.c create mode 100644 contrib/ntp/tests/libntp/run-buftvtots.c create mode 100644 contrib/ntp/tests/libntp/run-calendar.c create mode 100644 contrib/ntp/tests/libntp/run-caljulian.c create mode 100644 contrib/ntp/tests/libntp/run-caltontp.c create mode 100644 contrib/ntp/tests/libntp/run-calyearstart.c create mode 100644 contrib/ntp/tests/libntp/run-clocktime.c create mode 100644 contrib/ntp/tests/libntp/run-decodenetnum.c create mode 100644 contrib/ntp/tests/libntp/run-hextoint.c create mode 100644 contrib/ntp/tests/libntp/run-hextolfp.c create mode 100644 contrib/ntp/tests/libntp/run-humandate.c create mode 100644 contrib/ntp/tests/libntp/run-lfpfunc.c create mode 100644 contrib/ntp/tests/libntp/run-lfptostr.c create mode 100644 contrib/ntp/tests/libntp/run-modetoa.c create mode 100644 contrib/ntp/tests/libntp/run-msyslog.c create mode 100644 contrib/ntp/tests/libntp/run-netof.c create mode 100644 contrib/ntp/tests/libntp/run-numtoa.c create mode 100644 contrib/ntp/tests/libntp/run-numtohost.c create mode 100644 contrib/ntp/tests/libntp/run-octtoint.c create mode 100644 contrib/ntp/tests/libntp/run-prettydate.c create mode 100644 contrib/ntp/tests/libntp/run-recvbuff.c create mode 100644 contrib/ntp/tests/libntp/run-refidsmear.c create mode 100644 contrib/ntp/tests/libntp/run-refnumtoa.c create mode 100644 contrib/ntp/tests/libntp/run-sfptostr.c create mode 100644 contrib/ntp/tests/libntp/run-socktoa.c create mode 100644 contrib/ntp/tests/libntp/run-ssl_init.c create mode 100644 contrib/ntp/tests/libntp/run-statestr.c create mode 100644 contrib/ntp/tests/libntp/run-strtolfp.c create mode 100644 contrib/ntp/tests/libntp/run-timespecops.c create mode 100644 contrib/ntp/tests/libntp/run-timevalops.c create mode 100644 contrib/ntp/tests/libntp/run-tstotv.c create mode 100644 contrib/ntp/tests/libntp/run-tvtots.c create mode 100644 contrib/ntp/tests/libntp/run-uglydate.c create mode 100644 contrib/ntp/tests/libntp/run-vi64ops.c create mode 100644 contrib/ntp/tests/libntp/run-ymd2yd.c create mode 100644 contrib/ntp/tests/libntp/sfptostr.c create mode 100644 contrib/ntp/tests/libntp/sockaddrtest.c create mode 100644 contrib/ntp/tests/libntp/sockaddrtest.h create mode 100644 contrib/ntp/tests/libntp/socktoa.c create mode 100644 contrib/ntp/tests/libntp/ssl_init.c create mode 100644 contrib/ntp/tests/libntp/statestr.c create mode 100644 contrib/ntp/tests/libntp/strtolfp.c create mode 100644 contrib/ntp/tests/libntp/test-libntp.c create mode 100644 contrib/ntp/tests/libntp/test-libntp.h create mode 100644 contrib/ntp/tests/libntp/timespecops.c create mode 100644 contrib/ntp/tests/libntp/timevalops.c create mode 100644 contrib/ntp/tests/libntp/tstotv.c create mode 100644 contrib/ntp/tests/libntp/tvtots.c create mode 100644 contrib/ntp/tests/libntp/uglydate.c create mode 100644 contrib/ntp/tests/libntp/vi64ops.c create mode 100644 contrib/ntp/tests/libntp/ymd2yd.c create mode 100644 contrib/ntp/tests/ntpd/Makefile.am create mode 100644 contrib/ntp/tests/ntpd/Makefile.in create mode 100644 contrib/ntp/tests/ntpd/leapsec.c create mode 100644 contrib/ntp/tests/ntpd/ntp_prio_q.c create mode 100644 contrib/ntp/tests/ntpd/ntp_restrict.c create mode 100644 contrib/ntp/tests/ntpd/rc_cmdlength.c create mode 100644 contrib/ntp/tests/ntpd/run-leapsec.c create mode 100644 contrib/ntp/tests/ntpd/run-ntp_prio_q.c create mode 100644 contrib/ntp/tests/ntpd/run-ntp_restrict.c create mode 100644 contrib/ntp/tests/ntpd/run-rc_cmdlength.c create mode 100644 contrib/ntp/tests/ntpd/run-t-ntp_scanner.c create mode 100644 contrib/ntp/tests/ntpd/run-t-ntp_signd.c create mode 100644 contrib/ntp/tests/ntpd/t-ntp_scanner.c create mode 100644 contrib/ntp/tests/ntpd/t-ntp_signd.c create mode 100644 contrib/ntp/tests/ntpq/Makefile.am create mode 100644 contrib/ntp/tests/ntpq/Makefile.in create mode 100644 contrib/ntp/tests/ntpq/run-t-ntpq.c create mode 100644 contrib/ntp/tests/ntpq/t-ntpq.c create mode 100644 contrib/ntp/tests/sandbox/Makefile.am create mode 100644 contrib/ntp/tests/sandbox/Makefile.in create mode 100644 contrib/ntp/tests/sandbox/bug-2803.c create mode 100644 contrib/ntp/tests/sandbox/modetoa.c create mode 100644 contrib/ntp/tests/sandbox/run-modetoa.c create mode 100644 contrib/ntp/tests/sandbox/run-uglydate.c create mode 100644 contrib/ntp/tests/sandbox/run-ut-2803.c create mode 100644 contrib/ntp/tests/sandbox/smeartest.c create mode 100644 contrib/ntp/tests/sandbox/uglydate.c create mode 100644 contrib/ntp/tests/sandbox/ut-2803.c create mode 100644 contrib/ntp/tests/sec-2853/Makefile.am create mode 100644 contrib/ntp/tests/sec-2853/Makefile.in create mode 100644 contrib/ntp/tests/sec-2853/run-sec-2853.c create mode 100644 contrib/ntp/tests/sec-2853/sec-2853.c delete mode 100644 contrib/ntp/util/ansi2knr.1 delete mode 100644 contrib/ntp/util/ansi2knr.c rename contrib/ntp/util/{ntp-keygen-opts.menu => invoke-ntp-keygen.menu} (100%) create mode 100644 contrib/ntp/util/invoke-ntp-keygen.texi delete mode 100644 contrib/ntp/util/jitter.h delete mode 100644 contrib/ntp/util/ntp-keygen-opts.texi delete mode 100644 contrib/ntp/util/ntp-keygen.1 create mode 100644 contrib/ntp/util/ntp-keygen.1ntp-keygenman create mode 100644 contrib/ntp/util/ntp-keygen.1ntp-keygenmdoc create mode 100644 contrib/ntp/util/ntp-keygen.html create mode 100644 contrib/ntp/util/ntp-keygen.man.in create mode 100644 contrib/ntp/util/ntp-keygen.mdoc.in create mode 100644 contrib/ntp/util/ntp-keygen.texi create mode 100644 contrib/ntp/util/tg2.c delete mode 100644 contrib/ntp/version delete mode 100644 contrib/ntp/version.m4 create mode 100755 contrib/ntp/ylwrap create mode 100644 usr.sbin/ntp/doc/drivers/Makefile create mode 100644 usr.sbin/ntp/doc/drivers/scripts/Makefile create mode 100644 usr.sbin/ntp/doc/hints/Makefile create mode 100644 usr.sbin/ntp/doc/scripts/Makefile create mode 100644 usr.sbin/ntp/doc/sntp.8 create mode 100644 usr.sbin/ntp/libntpevent/Makefile create mode 100644 usr.sbin/ntp/libntpevent/event2/event-config.h create mode 100644 usr.sbin/ntp/ntpdc/nl.c diff --git a/UPDATING b/UPDATING index 899867d52..66f4c1617 100644 --- a/UPDATING +++ b/UPDATING @@ -16,6 +16,15 @@ from older versions of FreeBSD, try WITHOUT_CLANG to bootstrap to the tip of stable/10, and then rebuild without this option. The bootstrap process from older version of current is a bit fragile. +20151026: p23 FreeBSD-SA-15:25.ntp + + Fix multiple NTP vulnerabilities. New NTP version is 4.2.8p4. + + The configuration file syntax has been changed, thus mergemaster + run is recommended. Now the "kod" parameter requires "limited" + parameter. If the ntp.conf is not updated, the ntpd will run + successfully, but with KoD disabled. + 20151002: p22 FreeBSD-SA-15:24.rpcbind [revised] Revised patch to address a regression that prevents NIS from working. diff --git a/contrib/ntp/COPYRIGHT b/contrib/ntp/COPYRIGHT index 549704047..9c1a0f839 100644 --- a/contrib/ntp/COPYRIGHT +++ b/contrib/ntp/COPYRIGHT @@ -2,18 +2,18 @@ This file is automatically generated from html/copyright.html Copyright Notice - jpg "Clone me," says Dolly sheepishly + jpg "Clone me," says Dolly sheepishly. - Last update: 20:31 UTC Saturday, January 06, 2007 + Last update: 17-Jan-2015 00:16 UTC _________________________________________________________________ The following copyright notice applies to all files collectively called the Network Time Protocol Version 4 Distribution. Unless - specifically declared otherwise in an individual file, this notice - applies as if the text was explicitly included in the file. + specifically declared otherwise in an individual file, this entire + notice applies as if the text was explicitly included in the file. *********************************************************************** * * -* Copyright (c) David L. Mills 1992-2009 * +* Copyright (c) University of Delaware 1992-2015 * * * * Permission to use, copy, modify, and distribute this software and * * its documentation for any purpose with or without fee is hereby * @@ -27,150 +27,203 @@ This file is automatically generated from html/copyright.html * purpose. It is provided "as is" without express or implied * * warranty. * * * +*********************************************************************** + + Content starting in 2011 from Harlan Stenn, Danny Mayer, and Martin + Burnicki is: +*********************************************************************** +* * +* Copyright (c) Network Time Foundation 2011-2015 * +* * +* All Rights Reserved * +* * +* Redistribution and use in source and binary forms, with or without * +* modification, are permitted provided that the following conditions * +* are met: * +* 1. Redistributions of source code must retain the above copyright * +* notice, this list of conditions and the following disclaimer. * +* 2. Redistributions in binary form must reproduce the above * +* copyright notice, this list of conditions and the following * +* disclaimer in the documentation and/or other materials provided * +* with the distribution. * +* * +* THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS * +* OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * +* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * +* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE * +* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT * +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR * +* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * +* DAMAGE. * *********************************************************************** The following individuals contributed in part to the Network Time Protocol Distribution Version 4 and are acknowledged as authors of this work. - 1. [1]Mark Andrews Leitch atomic clock + 1. [1]Takao Abe Clock driver for JJY receivers + 2. [2]Mark Andrews Leitch atomic clock controller - 2. [2]Bernd Altmeier hopf Elektronik serial + 3. [3]Bernd Altmeier hopf Elektronik serial line and PCI-bus devices - 3. [3]Viraj Bais and [4]Clayton Kirkwood + 4. [4]Viraj Bais and [5]Clayton Kirkwood port to WindowsNT 3.5 - 4. [5]Michael Barone GPSVME fixes - 5. [6]Jean-Francois Boudreault - IPv6 support + 5. [6]Michael Barone GPSVME fixes 6. [7]Karl Berry syslog to file option 7. [8]Greg Brackley Major rework of WINNT port. Clean up recvbuf and iosignal code into separate modules. 8. [9]Marc Brett Magnavox GPS clock driver 9. [10]Piete Brooks MSF clock driver, Trimble PARSE support - 10. [11]Reg Clemens Oncore driver (Current maintainer) - 11. [12]Steve Clift OMEGA clock driver - 12. [13]Casey Crellin vxWorks (Tornado) port and + 10. [11]Nelson B Bolyard update and complete + broadcast and crypto features in sntp + 11. [12]Jean-Francois Boudreault + IPv6 support + 12. [13]Reg Clemens Oncore driver (Current maintainer) + 13. [14]Steve Clift OMEGA clock driver + 14. [15]Casey Crellin vxWorks (Tornado) port and help with target configuration - 13. [14]Sven Dietrich Palisade reference + 15. [16]Sven Dietrich Palisade reference clock driver, NT adj. residuals, integrated Greg's Winnt port. - 14. [15]John A. Dundas III Apple A/UX port - 15. [16]Torsten Duwe Linux + 16. [17]John A. Dundas III Apple A/UX port + 17. [18]Torsten Duwe Linux port - 16. [17]Dennis Ferguson foundation code for + 18. [19]Dennis Ferguson foundation code for NTP Version 2 as specified in RFC-1119 - 17. [18]John Hay IPv6 support and testing - 18. [19]Glenn Hollinger GOES clock driver - 19. [20]Mike Iglesias DEC Alpha port - 20. [21]Jim Jagielski A/UX port - 21. [22]Jeff Johnson massive prototyping + 19. [20]John Hay IPv6 support and testing + 20. [21]Dave Hart General maintenance, Windows + port interpolation rewrite + 21. [22]Claas Hilbrecht NeoClock4X clock driver + 22. [23]Glenn Hollinger GOES clock driver + 23. [24]Mike Iglesias DEC Alpha port + 24. [25]Jim Jagielski A/UX port + 25. [26]Jeff Johnson massive prototyping overhaul - 22. [23]Hans Lambermont or - [24] ntpsweep - 23. [25]Poul-Henning Kamp Oncore driver (Original + 26. [27]Hans Lambermont or + [28] ntpsweep + 27. [29]Poul-Henning Kamp Oncore driver (Original author) - 24. [26]Frank Kardel [27] PARSE - driver (>14 reference clocks), STREAMS modules for PARSE, support + 28. [30]Frank Kardel [31] PARSE + (driver 14 reference clocks), STREAMS modules for PARSE, support scripts, syslog cleanup, dynamic interface handling - 25. [28]William L. Jones RS/6000 AIX + 29. [32]Johannes Maximilian Kuehn Rewrote sntp to + comply with NTPv4 specification, ntpq saveconfig + 30. [33]William L. Jones RS/6000 AIX modifications, HPUX modifications - 26. [29]Dave Katz RS/6000 AIX port - 27. [30]Craig Leres 4.4BSD port, ppsclock, Magnavox + 31. [34]Dave Katz RS/6000 AIX port + 32. [35]Craig Leres 4.4BSD port, ppsclock, Magnavox GPS clock driver - 28. [31]George Lindholm SunOS 5.1 port - 29. [32]Louis A. Mamakos MD5-based authentication - 30. [33]Lars H. Mathiesen adaptation of foundation + 33. [36]George Lindholm SunOS 5.1 port + 34. [37]Louis A. Mamakos MD5-based authentication + 35. [38]Lars H. Mathiesen adaptation of foundation code for Version 3 as specified in RFC-1305 - 31. [34]Danny Mayer Network I/O, Windows Port, Code + 36. [39]Danny Mayer Network I/O, Windows Port, Code Maintenance - 32. [35]David L. Mills Version 4 foundation: clock - discipline, authentication, precision kernel; clock drivers: - Spectracom, Austron, Arbiter, Heath, ATOM, ACTS, KSI/Odetics; - audio clock drivers: CHU, WWV/H, IRIG - 33. [36]Wolfgang Moeller VMS port - 34. [37]Jeffrey Mogul ntptrace utility - 35. [38]Tom Moore i386 svr4 port - 36. [39]Kamal A Mostafa SCO OpenServer port - 37. [40]Derek Mulcahy and [41]Damon + 37. [40]David L. Mills Version 4 foundation, + precision kernel; clock drivers: 1, 3, 4, 6, 7, 11, 13, 18, 19, + 22, 36 + 38. [41]Wolfgang Moeller VMS port + 39. [42]Jeffrey Mogul ntptrace utility + 40. [43]Tom Moore i386 svr4 port + 41. [44]Kamal A Mostafa SCO OpenServer port + 42. [45]Derek Mulcahy and [46]Damon Hart-Davis ARCRON MSF clock driver - 38. [42]Rainer Pruy + 43. [47]Rob Neal Bancomm refclock and config/parse code + maintenance + 44. [48]Rainer Pruy monitoring/trap scripts, statistics file handling - 39. [43]Dirce Richards Digital UNIX V4.0 port - 40. [44]Wilfredo Sánchez added support for + 45. [49]Dirce Richards Digital UNIX V4.0 port + 46. [50]Wilfredo Sánchez added support for NetInfo - 41. [45]Nick Sayer SunOS streams modules - 42. [46]Jack Sasportas Saved a Lot of + 47. [51]Nick Sayer SunOS streams modules + 48. [52]Jack Sasportas Saved a Lot of space on the stuff in the html/pic/ subdirectory - 43. [47]Ray Schnitzler Unixware1 port - 44. [48]Michael Shields USNO clock driver - 45. [49]Jeff Steinman Datum PTS clock + 49. [53]Ray Schnitzler Unixware1 port + 50. [54]Michael Shields USNO clock driver + 51. [55]Jeff Steinman Datum PTS clock driver - 46. [50]Harlan Stenn GNU automake/autoconfigure + 52. [56]Harlan Stenn GNU automake/autoconfigure makeover, various other bits (see the ChangeLog) - 47. [51]Kenneth Stone HP-UX port - 48. [52]Ajit Thyagarajan IP multicast/anycast + 53. [57]Kenneth Stone HP-UX port + 54. [58]Ajit Thyagarajan IP multicast/anycast support - 49. [53]Tomoaki TSURUOKA TRAK clock + 55. [59]Tomoaki TSURUOKA TRAK clock driver - 50. [54]Paul A Vixie TrueTime GPS driver, generic + 56. [60]Brian Utterback General codebase, + Solaris issues + 57. [61]Loganaden Velvindron Sandboxing + (libseccomp) support + 58. [62]Paul A Vixie TrueTime GPS driver, generic TrueTime clock driver - 51. [55]Ulrich Windl corrected and + 59. [63]Ulrich Windl corrected and validated HTML documents according to the HTML DTD _________________________________________________________________ References - 1. mailto:%20mark_andrews@isc.org - 2. mailto:%20altmeier@atlsoft.de - 3. mailto:%20vbais@mailman1.intel.co - 4. mailto:%20kirkwood@striderfm.intel.com - 5. mailto:%20michael.barone@lmco.com - 6. mailto:%20Jean-Francois.Boudreault@viagenie.qc.ca + 1. mailto:%20takao_abe@xurb.jp + 2. mailto:%20mark_andrews@isc.org + 3. mailto:%20altmeier@atlsoft.de + 4. mailto:%20vbais@mailman1.intel.co + 5. mailto:%20kirkwood@striderfm.intel.com + 6. mailto:%20michael.barone@lmco.com 7. mailto:%20karl@owl.HQ.ileaf.com 8. mailto:%20greg.brackley@bigfoot.com 9. mailto:%20Marc.Brett@westgeo.com 10. mailto:%20Piete.Brooks@cl.cam.ac.uk - 11. mailto:%20reg@dwf.com - 12. mailto:%20clift@ml.csiro.au - 13. mailto:casey@csc.co.za - 14. mailto:%20Sven_Dietrich@trimble.COM - 15. mailto:%20dundas@salt.jpl.nasa.gov - 16. mailto:%20duwe@immd4.informatik.uni-erlangen.de - 17. mailto:%20dennis@mrbill.canet.ca - 18. mailto:%20jhay@icomtek.csir.co.za - 19. mailto:%20glenn@herald.usask.ca - 20. mailto:%20iglesias@uci.edu - 21. mailto:%20jagubox.gsfc.nasa.gov - 22. mailto:%20jbj@chatham.usdesign.com - 23. mailto:Hans.Lambermont@nl.origin-it.com - 24. mailto:H.Lambermont@chello.nl - 25. mailto:%20phk@FreeBSD.ORG - 26. http://www4.informatik.uni-erlangen.de/%7ekardel - 27. mailto:%20kardel(at)ntp(dot)org - 28. mailto:%20jones@hermes.chpc.utexas.edu - 29. mailto:%20dkatz@cisco.com - 30. mailto:%20leres@ee.lbl.gov - 31. mailto:%20lindholm@ucs.ubc.ca - 32. mailto:%20louie@ni.umd.edu - 33. mailto:%20thorinn@diku.dk - 34. mailto:%20mayer@ntp.org - 35. mailto:%20mills@udel.edu - 36. mailto:%20moeller@gwdgv1.dnet.gwdg.de - 37. mailto:%20mogul@pa.dec.com - 38. mailto:%20tmoore@fievel.daytonoh.ncr.com - 39. mailto:%20kamal@whence.com - 40. mailto:%20derek@toybox.demon.co.uk - 41. mailto:%20d@hd.org - 42. mailto:%20Rainer.Pruy@informatik.uni-erlangen.de - 43. mailto:%20dirce@zk3.dec.com - 44. mailto:%20wsanchez@apple.com - 45. mailto:%20mrapple@quack.kfu.com - 46. mailto:%20jack@innovativeinternet.com - 47. mailto:%20schnitz@unipress.com - 48. mailto:%20shields@tembel.org - 49. mailto:%20pebbles.jpl.nasa.gov - 50. mailto:%20harlan@pfcs.com - 51. mailto:%20ken@sdd.hp.com - 52. mailto:%20ajit@ee.udel.edu - 53. mailto:%20tsuruoka@nc.fukuoka-u.ac.jp - 54. mailto:%20vixie@vix.com - 55. mailto:%20Ulrich.Windl@rz.uni-regensburg.de + 11. mailto:%20nelson@bolyard.me + 12. mailto:%20Jean-Francois.Boudreault@viagenie.qc.ca + 13. mailto:%20reg@dwf.com + 14. mailto:%20clift@ml.csiro.au + 15. mailto:%20casey@csc.co.za + 16. mailto:%20Sven_Dietrich@trimble.COM + 17. mailto:%20dundas@salt.jpl.nasa.gov + 18. mailto:%20duwe@immd4.informatik.uni-erlangen.de + 19. mailto:%20dennis@mrbill.canet.ca + 20. mailto:%20jhay@icomtek.csir.co.za + 21. mailto:%20davehart@davehart.com + 22. mailto:%20neoclock4x@linum.com + 23. mailto:%20glenn@herald.usask.ca + 24. mailto:%20iglesias@uci.edu + 25. mailto:%20jagubox.gsfc.nasa.gov + 26. mailto:%20jbj@chatham.usdesign.com + 27. mailto:%20Hans.Lambermont@nl.origin-it.com + 28. mailto:H.Lambermont@chello.nl + 29. mailto:%20phk@FreeBSD.ORG + 30. http://www4.informatik.uni-erlangen.de/%7ekardel + 31. mailto:%20kardel%20%28at%29%20ntp%20%28dot%29%20org + 32. mailto:kuehn@ntp.org + 33. mailto:%20jones@hermes.chpc.utexas.edu + 34. mailto:%20dkatz@cisco.com + 35. mailto:%20leres@ee.lbl.gov + 36. mailto:%20lindholm@ucs.ubc.ca + 37. mailto:%20louie@ni.umd.edu + 38. mailto:%20thorinn@diku.dk + 39. mailto:%20mayer@ntp.org + 40. mailto:%20mills@udel.edu + 41. mailto:%20moeller@gwdgv1.dnet.gwdg.de + 42. mailto:%20mogul@pa.dec.com + 43. mailto:%20tmoore@fievel.daytonoh.ncr.com + 44. mailto:%20kamal@whence.com + 45. mailto:%20derek@toybox.demon.co.uk + 46. mailto:%20d@hd.org + 47. mailto:%20neal@ntp.org + 48. mailto:%20Rainer.Pruy@informatik.uni-erlangen.de + 49. mailto:%20dirce@zk3.dec.com + 50. mailto:%20wsanchez@apple.com + 51. mailto:%20mrapple@quack.kfu.com + 52. mailto:%20jack@innovativeinternet.com + 53. mailto:%20schnitz@unipress.com + 54. mailto:%20shields@tembel.org + 55. mailto:%20pebbles.jpl.nasa.gov + 56. mailto:%20harlan@pfcs.com + 57. mailto:%20ken@sdd.hp.com + 58. mailto:%20ajit@ee.udel.edu + 59. mailto:%20tsuruoka@nc.fukuoka-u.ac.jp + 60. mailto:%20brian.utterback@oracle.com + 61. mailto:%20loganaden@gmail.com + 62. mailto:%20vixie@vix.com + 63. mailto:%20Ulrich.Windl@rz.uni-regensburg.de diff --git a/contrib/ntp/ChangeLog b/contrib/ntp/ChangeLog index 60b7f0508..5d8346b31 100644 --- a/contrib/ntp/ChangeLog +++ b/contrib/ntp/ChangeLog @@ -1,4 +1,3595 @@ --- +(4.2.8p4) 2015/10/21 Released by Harlan Stenn +(4.2.8p4-RC1) 2015/10/06 Released by Harlan Stenn + +* [Sec 2899] CVE-2014-9297 perlinger@ntp.org +* [Sec 2901] Drop invalid packet before checking KoD. Check for all KoD's. + Danny Mayer. Log incoming packets that fail TEST2. Harlan Stenn. +* [Sec 2902] configuration directives "pidfile" and "driftfile" + should be local-only. perlinger@ntp.org (patch by Miroslav Lichvar) +* [Sec 2909] added missing call to 'free()' in ntp_crypto.c. perlinger@ntp.org +* [Sec 2913] TALOS-CAN-0052: crash by loop counter underrun. perlinger@ntp.org +* [Sec 2916] TALOS-CAN-0054: memory corruption in password store. JPerlinger +* [Sec 2917] TALOS-CAN-0055: Infinite loop if extended logging enabled and + the logfile and keyfile are the same. perlinger@ntp.org +* [Sec 1918] TALOS-CAN-0062: prevent directory traversal for VMS, too, when + using 'saveconfig' command. perlinger@ntp.org +* [Bug 2919] TALOS-CAN-0063: avoid buffer overrun in ntpq. perlinger@ntp.org +* [Sec 2020] TALOS-CAN-0064: signed/unsiged clash could lead to buffer overun + and memory corruption. perlinger@ntp.org +* [Sec 2921] TALOS-CAN-0065: password length memory corruption. JPerlinger. +* [Sec 2922] decodenetnum() will ASSERT botch instead of returning FAIL + on some bogus values. Harlan Stenn. +* [Sec 2941] NAK to the Future: Symmetric association authentication + bypass via crypto-NAK. Patch applied. perlinger@ntp.org +* [Bug 2332] (reopened) Exercise thread cancellation once before dropping + privileges and limiting resources in NTPD removes the need to link + forcefully against 'libgcc_s' which does not always work. J.Perlinger +* [Bug 2595] ntpdate man page quirks. Hal Murray, Harlan Stenn. +* [Bug 2625] Deprecate flag1 in local refclock. Hal Murray, Harlan Stenn. +* [Bug 2817] Stop locking ntpd into memory by default under Linux. H.Stenn. +* [Bug 2821] minor build issues: fixed refclock_gpsdjson.c. perlinger@ntp.org +* [Bug 2823] ntpsweep with recursive peers option doesn't work. H.Stenn. +* [Bug 2849] Systems with more than one default route may never + synchronize. Brian Utterback. Note that this patch might need to + be reverted once Bug 2043 has been fixed. +* [Bug 2864] 4.2.8p3 fails to compile on Windows. Juergen Perlinger +* [Bug 2866] segmentation fault at initgroups(). Harlan Stenn. +* [Bug 2867] ntpd with autokey active crashed by 'ntpq -crv'. J.Perlinger +* [Bug 2873] libevent should not include .deps/ in the tarball. H.Stenn +* [Bug 2874] Don't distribute generated sntp/tests/fileHandlingTest.h. H.Stenn +* [Bug 2875] sntp/Makefile.am: Get rid of DIST_SUBDIRS. libevent must + be configured for the distribution targets. Harlan Stenn. +* [Bug 2883] ntpd crashes on exit with empty driftfile. Miroslav Lichvar. +* [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org +* [Bug 2888] streamline calendar functions. perlinger@ntp.org +* [Bug 2889] ntp-dev-4.3.67 does not build on Windows. perlinger@ntp.org +* [Bug 2890] Ignore ENOBUFS on routing netlink socket. Konstantin Khlebnikov. +* [Bug 2906] make check needs better support for pthreads. Harlan Stenn. +* [Bug 2907] dist* build targets require our libevent/ to be enabled. HStenn. +* [Bug 2912] no munlockall() under Windows. David Taylor, Harlan Stenn. +* libntp/emalloc.c: Remove explicit include of stdint.h. Harlan Stenn. +* Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. +* tests/ntpd/g_leapsec.cpp typo fix. Harlan Stenn. +* Phase 1 deprecation of google test in sntp/tests/. Harlan Stenn. +* On some versions of HP-UX, inttypes.h does not include stdint.h. H.Stenn. +* top_srcdir can change based on ntp v. sntp. Harlan Stenn. +* sntp/tests/ function parameter list cleanup. Damir Tomić. +* tests/libntp/ function parameter list cleanup. Damir Tomić. +* tests/ntpd/ function parameter list cleanup. Damir Tomić. +* sntp/unity/unity_config.h: handle stdint.h. Harlan Stenn. +* sntp/unity/unity_internals.h: handle *INTPTR_MAX on old Solaris. H.Stenn. +* tests/libntp/timevalops.c and timespecops.c fixed error printing. D.Tomić. +* tests/libntp/ improvements in code and fixed error printing. Damir Tomić. +* tests/libntp: a_md5encrypt.c, authkeys.c, buftvtots.c, calendar.c, caljulian.c, + caltontp.c, clocktime.c, humandate.c, hextolfp.c, decodenetnum.c - fixed + formatting; first declaration, then code (C90); deleted unnecessary comments; + changed from sprintf to snprintf; fixed order of includes. Tomasz Flendrich +* tests/libntp/lfpfunc.c remove unnecessary include, remove old comments, + fix formatting, cleanup. Tomasz Flendrich +* tests/libntp/lfptostr.c remove unnecessary include, add consts, fix formatting. + Tomasz Flendrich +* tests/libntp/statestr.c remove empty functions, remove unnecessary include, + fix formatting. Tomasz Flendrich +* tests/libntp/modetoa.c fixed formatting. Tomasz Flendrich +* tests/libntp/msyslog.c fixed formatting. Tomasz Flendrich +* tests/libntp/numtoa.c deleted unnecessary empty functions, fixed formatting. + Tomasz Flendrich +* tests/libntp/numtohost.c added const, fixed formatting. Tomasz Flendrich +* tests/libntp/refnumtoa.c fixed formatting. Tomasz Flendrich +* tests/libntp/ssl_init.c fixed formatting. Tomasz Flendrich +* tests/libntp/tvtots.c fixed a bug, fixed formatting. Tomasz Flendrich +* tests/libntp/uglydate.c removed an unnecessary include. Tomasz Flendrich +* tests/libntp/vi64ops.c removed an unnecessary comment, fixed formatting. +* tests/libntp/ymd3yd.c removed an empty function and an unnecessary include, +fixed formatting. Tomasz Flendrich +* tests/libntp/timespecops.c fixed formatting, fixed the order of includes, + removed unnecessary comments, cleanup. Tomasz Flendrich +* tests/libntp/timevalops.c fixed the order of includes, deleted unnecessary + comments, cleanup. Tomasz Flendrich +* tests/libntp/sockaddrtest.h making it agree to NTP's conventions of formatting. + Tomasz Flendrich +* tests/libntp/lfptest.h cleanup. Tomasz Flendrich +* tests/libntp/test-libntp.c fix formatting. Tomasz Flendrich +* sntp/tests/crypto.c is now using proper Unity's assertions, fixed formatting. + Tomasz Flendrich +* sntp/tests/kodDatabase.c added consts, deleted empty function, + fixed formatting. Tomasz Flendrich +* sntp/tests/kodFile.c cleanup, fixed formatting. Tomasz Flendrich +* sntp/tests/packetHandling.c is now using proper Unity's assertions, + fixed formatting, deleted unused variable. Tomasz Flendrich +* sntp/tests/keyFile.c is now using proper Unity's assertions, fixed formatting. + Tomasz Flendrich +* sntp/tests/packetProcessing.c changed from sprintf to snprintf, + fixed formatting. Tomasz Flendrich +* sntp/tests/utilities.c is now using proper Unity's assertions, changed + the order of includes, fixed formatting, removed unnecessary comments. + Tomasz Flendrich +* sntp/tests/sntptest.h fixed formatting. Tomasz Flendrich +* sntp/tests/fileHandlingTest.h.in fixed a possible buffer overflow problem, + made one function do its job, deleted unnecessary prints, fixed formatting. + Tomasz Flendrich +* sntp/unity/Makefile.am added a missing header. Tomasz Flendrich +* sntp/unity/unity_config.h: Distribute it. Harlan Stenn. +* sntp/libevent/evconfig-private.h: remove generated filefrom SCM. H.Stenn. +* sntp/unity/Makefile.am: fix some broken paths. Harlan Stenn. +* sntp/unity/unity.c: Clean up a printf(). Harlan Stenn. +* Phase 1 deprecation of google test in tests/libntp/. Harlan Stenn. +* Don't build sntp/libevent/sample/. Harlan Stenn. +* tests/libntp/test_caltontp needs -lpthread. Harlan Stenn. +* br-flock: --enable-local-libevent. Harlan Stenn. +* Wrote tests for ntpd/ntp_prio_q.c. Tomasz Flendrich +* scripts/lib/NTP/Util.pm: stratum output is version-dependent. Harlan Stenn. +* Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. +* Code cleanup. Harlan Stenn. +* libntp/icom.c: Typo fix. Harlan Stenn. +* util/ntptime.c: initialization nit. Harlan Stenn. +* ntpd/ntp_peer.c:newpeer(): added a DEBUG_REQUIRE(srcadr). Harlan Stenn. +* Add std_unity_tests to various Makefile.am files. Harlan Stenn. +* ntpd/ntp_restrict.c: added a few assertions, created tests for this file. + Tomasz Flendrich +* Changed progname to be const in many files - now it's consistent. Tomasz + Flendrich +* Typo fix for GCC warning suppression. Harlan Stenn. +* Added tests/ntpd/ntp_scanner.c test. Damir Tomić. +* Added declarations to all Unity tests, and did minor fixes to them. + Reduced the number of warnings by half. Damir Tomić. +* Updated generate_test_runner.rb and updated the sntp/unity/auto directory + with the latest Unity updates from Mark. Damir Tomić. +* Retire google test - phase I. Harlan Stenn. +* Unity test cleanup: move declaration of 'initializing'. Harlan Stenn. +* Update the NEWS file. Harlan Stenn. +* Autoconf cleanup. Harlan Stenn. +* Unit test dist cleanup. Harlan Stenn. +* Cleanup various test Makefile.am files. Harlan Stenn. +* Pthread autoconf macro cleanup. Harlan Stenn. +* Fix progname definition in unity runner scripts. Harlan Stenn. +* Clean trailing whitespace in tests/ntpd/Makefile.am. Harlan Stenn. +* Update the patch for bug 2817. Harlan Stenn. +* More updates for bug 2817. Harlan Stenn. +* Fix bugs in tests/ntpd/ntp_prio_q.c. Harlan Stenn. +* gcc on older HPUX may need +allowdups. Harlan Stenn. +* Adding missing MCAST protection. Harlan Stenn. +* Disable certain test programs on certain platforms. Harlan Stenn. +* Implement --enable-problem-tests (on by default). Harlan Stenn. +* build system tweaks. Harlan Stenn. +--- +(4.2.8p3) 2015/06/29 Released by Harlan Stenn + +* [Sec 2853] Crafted remote config packet can crash some versions of + ntpd. Aleksis Kauppinen, Juergen Perlinger, Harlan Stenn. +* [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. +* [Bug 1060] Buffer overruns in libparse/clk_rawdcf.c. Helge Oldach. +* [Bug 2846] Report 'unsynchronized' status during the leap second. + Fixed in Martin's changes to Bug 2855. Martin Burnicki. +* [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. +* [Bug 2860] ntpq ifstats sanity check is too stringent. Frank Kardel. +* README.leapsmear added. Martin Burnicki. +* README.leapsmear edited. Harlan Stenn. +* tests/libntp/msyslog.c: fixed a gcc warning. Tomasz Flendrich. +* ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. +* html/miscopt.html: Document leapsmearinterval, other cleanup. Harlan Stenn. +--- +(4.2.8p3-RC3) 2015/06/27 Released by Harlan Stenn + +* [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. +* [Bug 2855] Report leap smear in the REFID. Harlan Stenn. +* [Bug 2856] ntpd should wait() on terminated child processes. Paul Green. +* [Bug 2857] Stratus VOS does not support SIGIO. Paul Green. +* html/drivers/driver22.html: typo fix. Harlan Stenn. +* refidsmear test cleanup. Tomasz Flendrich. +* refidsmear function support and tests. Harlan Stenn. +* sntp/tests/Makefile.am: remove g_nameresolution.cpp as it tested + something that was only in the 4.2.6 sntp. Harlan Stenn. +* Modified tests/bug-2803/Makefile.am so it builds Unity framework tests. + Damir Tomić +* Modified tests/libtnp/Makefile.am so it builds Unity framework tests. + Damir Tomić +* Modified sntp/tests/Makefile.am so it builds Unity framework tests. + Damir Tomić +* tests/sandbox/smeartest.c: Harlan Stenn, Damir Tomic, Juergen Perlinger. +* Converted from gtest to Unity: tests/bug-2803/. Damir Tomić +* Converted from gtest to Unity: tests/libntp/ a_md5encrypt, atoint.c, + atouint.c, authkeys.c, buftvtots.c, calendar.c, caljulian.c, + calyearstart.c, clocktime.c, hextoint.c, lfpfunc.c, modetoa.c, + numtoa.c, numtohost.c, refnumtoa.c, ssl_init.c, statestr.c, + timespecops.c, timevalops.c, uglydate.c, vi64ops.c, ymd2yd.c. + Damir Tomić +* Converted from gtest to Unity: sntp/tests/ kodDatabase.c, kodFile.c, + networking.c, keyFile.c, utilities.cpp, sntptest.h, + fileHandlingTest.h. Damir Tomić +* Converted from gtest to Unity: sntp/tests/ caltontp.c, humandate.c, + msyslog.c, prettydate.c, recvbuff.c, sfptostr.c, tstotv.c, tvtots.c, + sntp/tests/packetProcessing.c. Tomasz Flendrich +--- +(4.2.8p3-RC2) 2015/06/24 Released by Harlan Stenn + +* [Bug 2778] Implement "apeers" ntpq command to include associd. +* [Bug 2805] ntpd fails to join multicast group. +* [Bug 2824] Convert update-leap to perl. (also see 2769) +* [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTPD transfers the current TAI (instead of an announcement) now. + This might still needed improvement. + Update autokey data ASAP when 'sys_tai' changes. + Fix unit test that was broken by changes for autokey update. + Avoid potential signature length issue and use DPRINTF where possible + in ntp_crypto.c. +* [Bug 2832] refclock_jjy.c supports the TDC-300. +* [Bug 2834] Correct a broken html tag in html/refclock.html +* [Bug 2836] DFC77 patches from Frank Kardel to make decoding more + robust, and require 2 consecutive timestamps to be consistent. +* [Bug 2837] Allow a configurable DSCP value. +* [Bug 2837] add test for DSCP to ntpd/complete.conf.in +* [Bug 2842] Glitch in ntp.conf.def documentation stanza. +* [Bug 2842] Bug in mdoc2man. +* [Bug 2843] make check fails on 4.3.36 + Fixed compiler warnings about numeric range overflow + (The original topic was fixed in a byplay to bug#2830) +* [Bug 2845] Harden memory allocation in ntpd. +* [Bug 2852] 'make check' can't find unity.h. Hal Murray. +* [Bug 2854] Missing brace in libntp/strdup.c. Masanari Iida. +* [Bug 2855] Implement conditional leap smear code. Martin Burnicki. +* [Bug 2855] leap smear cleanup. Harlan Stenn. +* Initial support for experimental leap smear code. Harlan Stenn. +* Fixes to sntp/tests/fileHandlingTest.h.in. Harlan Stenn. +* Report select() debug messages at debug level 3 now. +* sntp/scripts/genLocInfo: treat raspbian as debian. +* Unity test framework fixes. + ** Requires ruby for changes to tests. +* Initial support for PACKAGE_VERSION tests. +* sntp/libpkgver belongs in EXTRA_DIST, not DIST_SUBDIRS. +* tests/bug-2803/Makefile.am must distribute bug-2803.h. +* automake-1.15 cleanup for sntp/tests/fileHandlingTest.h.in . Harlan Stenn. +--- +(4.2.8p3-RC1) 2015/05/12 Released by Harlan Stenn + +* CID 739725: Fix a rare resource leak in libevent/listener.c. +* CID 1295478: Quiet a pedantic potential error from the fix for Bug 2776. +* CID 1296235: Fix refclock_jjy.c and correcting type of the driver40-ja.html +* CID 1269537: Clean up a line of dead code in getShmTime(). +* [Bug 2590] autogen-5.18.5. +* [Bug 2612] restrict: Warn when 'monitor' can't be disabled because + of 'limited'. +* [Bug 2650] fix includefile processing. +* [Bug 2745] ntpd -x steps clock on leap second + Fixed an initial-value problem that caused misbehaviour in absence of + any leapsecond information. + Do leap second stepping only of the step adjustment is beyond the + proper jump distance limit and step correction is allowed at all. +* [Bug 2750] build for Win64 + Building for 32bit of loopback ppsapi needs def file +* [Bug 2776] Improve ntpq's 'help keytype'. +* [Bug 2782] Refactor refclock_shm.c, add memory barrier protection. +* [Bug 2792] If the IFF_RUNNING interface flag is supported then an + interface is ignored as long as this flag is not set since the + interface is not usable (e.g., no link). +* [Bug 2794] Clean up kernel clock status reports. +* [Bug 2800] refclock_true.c true_debug() can't open debug log because + of incompatible open/fdopen parameters. +* [Bug 2804] install-local-data assumes GNU 'find' semantics. +* [Bug 2806] refclock_jjy.c supports the Telephone JJY. +* [Bug 2808] GPSD_JSON driver enhancements, step 1. + Fix crash during cleanup if GPS device not present and char device. + Increase internal token buffer to parse all JSON data, even SKY. + Defer logging of errors during driver init until the first unit is + started, so the syslog is not cluttered when the driver is not used. + Various improvements, see http://bugs.ntp.org/2808 for details. + Changed libjsmn to a more recent version. +* [Bug 2810] refclock_shm.c memory barrier code needs tweaks for QNX. +* [Bug 2813] HP-UX needs -D__STDC_VERSION__=199901L and limits.h. +* [Bug 2815] net-snmp before v5.4 has circular library dependencies. +* [Bug 2821] Add a missing NTP_PRINTF and a missing const. +* [Bug 2822] New leap column in sntp broke NTP::Util.pm. +* [Bug 2825] Quiet file installation in html/ . +* [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTPD transfers the current TAI (instead of an announcement) now. + This might still needed improvement. +* Add an assert to the ntpq ifstats code. +* Clean up the RLIMIT_STACK code. +* Improve the ntpq documentation around the controlkey keyid. +* ntpq.c cleanup. +* Windows port build cleanup. +--- +(4.2.8p2) 2015/04/07 Released by Harlan Stenn +(4.2.8p2-RC3) 2015/04/03 Released by Harlan Stenn + +* [Bug 2763] Fix for different thresholds for forward and backward steps. +* Initial import of the Unity test framework. +--- +(4.2.8p2-RC2) 2015/04/03 Released by Harlan Stenn + +* [Bug 2592] FLAG_TSTAMP_PPS cleanup for refclock_parse.c. +* [Bug 2769] New script: update-leap +* [Bug 2769] cleannup for update-leap +* [Bug 2788] New flag -G (force_step_once). +* [Bug 2794] Clean up kernel clock status reports. +* [Bug 2795] Cannot build without OpenSLL (on Win32). + Provided a Win32 specific wrapper around libevent/arc4random.c. + fixed some minor warnings. +* [Bug 2796] ntp-keygen crashes in 'getclock()' on Win32. +* [Bug 2797] ntp-keygen trapped in endless loop for MD5 keys + on big-endian machines. +* [Bug 2798] sntp should decode and display the leap indicator. +* Simple cleanup to html/build.html +--- +(4.2.8p2-RC1) 2015/03/30 Released by Harlan Stenn + +* [Bug 2794] Don't let reports on normal kernel status changes + look like errors. +* [Bug 2788] New flag -G (force_step_once). +* [Bug 2592] Account for PPS sources which can provide an accurate + absolute time stamp, and status information. + Fixed indention and removed trailing whitespace. +* [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. +* [Bug 1960] setsockopt IPV6_MULTICAST_IF: Invalid argument. +* [Bug 2346] "graceful termination" signals do not do peer cleanup. +* [Bug 2728] See if C99-style structure initialization works. +* [Bug 2747] Upgrade libevent to 2.1.5-beta. +* [Bug 2749] ntp/lib/NTP/Util.pm needs update for ntpq -w, IPv6, .POOL. . +* [Bug 2751] jitter.h has stale copies of l_fp macros. +* [Bug 2756] ntpd hangs in startup with gcc 3.3.5 on ARM. +* [Bug 2757] Quiet compiler warnings. +* [Bug 2759] Expose nonvolatile/clk_wander_threshold to ntpq. +* [Bug 2763] Allow different thresholds for forward and backward steps. +* [Bug 2766] ntp-keygen output files should not be world-readable. +* [Bug 2767] ntp-keygen -M should symlink to ntp.keys. +* [Bug 2771] nonvolatile value is documented in wrong units. +* [Bug 2773] Early leap announcement from Palisade/Thunderbolt +* [Bug 2774] Unreasonably verbose printout - leap pending/warning +* [Bug 2775] ntp-keygen.c fails to compile under Windows. +* [Bug 2777] Fixed loops and decoding of Meinberg GPS satellite info. + Removed non-ASCII characters from some copyright comments. + Removed trailing whitespace. + Updated definitions for Meinberg clocks from current Meinberg header files. + Now use C99 fixed-width types and avoid non-ASCII characters in comments. + Account for updated definitions pulled from Meinberg header files. + Updated comments on Meinberg GPS receivers which are not only called GPS16x. + Replaced some constant numbers by defines from ntp_calendar.h + Modified creation of parse-specific variables for Meinberg devices + in gps16x_message(). + Reworked mk_utcinfo() to avoid printing of ambiguous leap second dates. + Modified mbg_tm_str() which now expexts an additional parameter controlling + if the time status shall be printed. +* [Sec 2779] ntpd accepts unauthenticated packets with symmetric key crypto. +* [Sec 2781] Authentication doesn't protect symmetric associations against + DoS attacks. +* [Bug 2783] Quiet autoconf warnings about missing AC_LANG_SOURCE. +* [Bug 2784] Fix for 2782 uses clock_gettime() instead of get_ostime(). +* [Bug 2789] Quiet compiler warnings from libevent. +* [Bug 2790] If ntpd sets the Windows MM timer highest resolution + pause briefly before measuring system clock precision to yield + correct results. +* Comment from Juergen Perlinger in ntp_calendar.c to make the code clearer. +* Use predefined function types for parse driver functions + used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast parse conversion results to appropriate types to avoid + compiler warnings. + Let ioctl() for Windows accept a (void *) to avoid compiler warnings + when called with pointers to different types. +--- +(4.2.8p1) 2015/02/04 Released by Harlan Stenn + +* Update the NEWS file. +* [Sec 2671] vallen in extension fields are not validated. +--- +(4.2.8p1-RC2) 2015/01/29 Released by Harlan Stenn + +* [Bug 2627] shm refclock allows only two units with owner-only access + rework: reverted sense of mode bit (so default reflects previous + behaviour) and updated ducumentation. +* [Bug 2732] - Leap second not handled correctly on Windows 8 + use 'GetTickCount()' to get the true elapsed time of slew + (This should work for all versions of Windows >= W2K) +* [Bug 2738] Missing buffer initialization in refclocK_parse.c::parsestate(). +* [Bug 2739] Parse driver with PPS enabled occasionally evaluates + PPS timestamp with wrong sign. + Removed some German umlauts. +* [Bug 2740] Removed some obsolete code from the parse driver. +* [Bug 2741] Incorrect buffer check in refclocK_parse.c::parsestatus(). +--- +(4.2.8p1-RC1) 2015/01/24 Released by Harlan Stenn + +* Start the RC for 4.2.8p1. +* [Bug 2187] Update version number generation scripts. +* [Bug 2617] Fix sntp Usage documentation section. +* [Sec 2672] Code cleanup: On some OSes ::1 can be spoofed... +* [Bug 2736] Show error message if we cannot open the config file. +* Copyright update. +* Fix the package name. +--- +(4.2.8p1-beta5) 2015/01/07 Released by Harlan Stenn + +* [Bug 2695] Windows build: __func__ not supported under Windows. +* [Bug 2728] Work around C99-style structure initialization code + for older compilers, specifically Visual Studio prior to VS2013. +--- +(4.2.8p1-beta4) 2015/01/04 Released by Harlan Stenn + +* [Bug 1084] PPSAPI for ntpd on Windows with DLL backends +* [Bug 2695] Build problem on Windows (sys/socket.h). +* [Bug 2715] mdnstries option for ntp.conf from NetBSD. +* Fix a regression introduced to timepps-Solaris.h as part of: + [Bug 1206] Required compiler changes for Windows + (4.2.5p181) 2009/06/06 +--- +(4.2.8p1-beta3) 2015/01/02 Released by Harlan Stenn + +* [Bug 2627] shm refclock allows only two units with owner-only access + Use mode bit 0 to select public access for units >= 2 (units 0 & 1 are + always private. +* [Bug 2681] Fix display of certificate EOValidity dates on 32-bit systems. +* [Bug 2695] 4.2.8 does not build on Windows. +* [bug 2700] mrulist stopped working in 4.2.8. +* [Bug 2706] libparse/info_trimble.c build dependencies are broken. +* [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD. +* [Bug 2714] libevent may need to be built independently of any build of sntp. +* [Bug 2715] mdnstries option for ntp.conf from NetBSD. +--- +(4.2.8p1-beta2) 2014/12/27 Released by Harlan Stenn + +* [Bug 2674] Install sntp in sbin on NetBSD. +* [Bug 2693] ntp-keygen doesn't build without OpenSSL and sntp. +* [Bug 2707] Avoid a C90 extension in libjsmn/jsmn.c. +* [Bug 2709] see if we have a C99 compiler (not yet required). +--- +(4.2.8p1-beta1) 2014/12/23 Released by Harlan Stenn + +* [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs. +* [Bug 2693] ntp-keygen doesn't build without OpenSSL. +* [Bug 2697] IN6_IS_ADDR_LOOPBACK build problems on some OSes. +* [Bug 2699] HAVE_SYS_SELECT_H is misspelled in refclock_gpsdjson.c. +--- +(4.2.8) 2014/12/19 Released by Harlan Stenn + +* [Sec 730] Increase RSA_generate_key modulus. +* [Sec 2666] Use cryptographic random numbers for md5 key generation. +* [Sec 2667] buffer overflow in crypto_recv(). +* [Sec 2668] buffer overflow in ctl_putdata(). +* [Sec 2669] buffer overflow in configure(). +* [Sec 2670] Missing return; from error clause. +* [Sec 2671] vallen in extension fields are not validated. +* [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs. +* [Bug 2691] Wrong variable name in refclock_ripencc.c. +(4.2.7p486-RC) 2014/12/18 Released by Harlan Stenn +* [Bug 2687] RefClock 26/hpgps doesn't work at default line speed +(4.2.7p485-RC) 2014/12/12 Released by Harlan Stenn +* [Bug 2686] refclock_gpsdjson needs strtoll(), which is not always present. +(4.2.7p484-RC) 2014/12/11 Released by Harlan Stenn +(4.2.7p483) 2014/12/08 Released by Harlan Stenn +* [Bug 2685] Better document the KOD file for sntp. +(4.2.7p482) 2014/12/02 Released by Harlan Stenn +* [Bug 2641] sntp is installed in the wrong location in Solaris. +* [Bug 2678] nmea_control() now checks 'refclock_params()' result. +(4.2.7p481) 2014/11/22 Released by Harlan Stenn +* [Bug 2314] Only enable PPS if kernel consumer binding succeeds. +* [Bug 2314] Kernel PPS binding EOPNOTSUPP is a failure condition. +* Rename pps_enable to hardpps_enable. +(4.2.7p480) 2014/11/21 Released by Harlan Stenn +* [Bug 2677] PATH_MAX isn't #define'd under Windows. + Regression from the patch fixing Bug 2639. +(4.2.7p479) 2014/11/15 Released by Harlan Stenn +* [Bug 2651] Certificates with ASN timestamps w/ 4-digit years mis-parsed. +(4.2.7p478) 2014/11/14 Released by Harlan Stenn +* [Sec 2630] buffer overrun in ntpq tokenize(). +* [Bug 2639] Check return value of ntp_adjtime(). +* [Bug 2650] includefile processing broken. +* [Bug 2661] ntpq crashes with mreadvar. +(4.2.7p477) 2014/11/13 Released by Harlan Stenn +* [Bug 2657] Document that "restrict nopeer" intereferes with "pool". +(4.2.7p476) 2014/10/08 Released by Harlan Stenn +* [Bug 2503] SHT utility outdated +(4.2.7p475) 2014/09/11 Released by Harlan Stenn +* [Bug 2654] refclock_true.c doesn't identify the Mk III. +(4.2.7p474) 2014/09/10 Released by Harlan Stenn +* [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup. +* [Bug 2649] Clean up html/ page installation. +(4.2.7p473) 2014/09/06 Released by Harlan Stenn +* [Bug 2649] Clean up html/ page installation. +(4.2.7p472) 2014/09/06 Released by Harlan Stenn +* [Bug 2556] mrulist is missing from the generated ntpq man page. +(4.2.7p471) 2014/09/05 Released by Harlan Stenn +* [Bug 2649] "make install" leaves wrong owner for files in html/. +* [Bug 2652] Windows hates directory names that contain a :. +(4.2.7p470) 2014/09/02 Released by Harlan Stenn +* [Bug 2502] Autogen text replacement errors. +* autogen-5.18.5pre1 +* html/ cleanups from Hal Murray. +(4.2.7p469) 2014/09/01 Released by Harlan Stenn +* [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup. +(4.2.7p468) 2014/08/31 Released by Harlan Stenn +* [Bug 2556] ntpq man page cleanup. +* autogen-5.18.4 +(4.2.7p467) 2014/08/28 Released by Harlan Stenn +* [Bug 2639] Check return value of ntp_adjtime(). +* [Bug 2640] STA_NANO can result in invalid ntv.constant. +(4.2.7p466) 2014/08/27 Released by Harlan Stenn +* [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup. +(4.2.7p465) 2014/08/23 Released by Harlan Stenn +* [Bug 2538] NTP programs print exit code in help/usage text. +* [Bug 2595] Man page quirks: ntpdate references in ntpd. +* [Bug 2613] www.ntp.org/bugs.html tells folks to email doc bugs to DLM. +* [Bug 2636] Clutter in syslog if gpsd not running + - found (hopefully) last cause for clutter in protocol version + - log GPSD revision and release numbers with protocol version +(4.2.7p464) 2014/08/22 Released by Harlan Stenn +* [Bug 2636] Fix coverity warning from previous patch. +(4.2.7p463) 2014/08/21 Released by Harlan Stenn +* [Bug 2636] Clutter in syslog if gpsd not running + - make driver work with GPSD protocol version 3.9 + - use exponential back-off for connection problems + - implement rate-limit for syslog entries +(4.2.7p462) 2014/08/16 Released by Harlan Stenn +* [Bug 2622] Synchronisation problem using SHM [...] + Add 'control' function -- fudge values not available during start. +(4.2.7p461) 2014/08/14 Released by Harlan Stenn +* [Bug 1128] ntpq truncates "remote" host information. +* More autogen-5.18.4pre14 cleanup. +(4.2.7p460) 2014/08/13 Released by Harlan Stenn +* More autogen-5.18.4pre14 cleanup. +(4.2.7p459) 2014/08/12 Released by Harlan Stenn +* [Bug 2630] Limit the ntpq command buffer to 512 bytes. +* FlexeLint cleanups. +* Try bison-3.0.2 instead of bison-2.5. +(4.2.7p458) 2014/08/11 Released by Harlan Stenn +* [Bug 2633] Provide stdnoreturn.h for windows port. +(4.2.7p457) 2014/08/09 Released by Harlan Stenn +* [Bug 2622] Synchronisation problem using SHM when time difference is + more than four hours: Change SHM driver so TOY restricted API is not + used any more. (Plus some minor cleanup in logic and flow control) +* Pass the configration source into the parser as argument rather + than through a global variable. +* Fix nits in the ntpq man page. +* autogen-5.18.4pre14 +(4.2.7p456) 2014/08/07 Released by Harlan Stenn +* CID 739722: Change the way the extention and MAC fields are processed. +(4.2.7p455) 2014/08/03 Released by Harlan Stenn +* [Bug 2565] ntpd sometimes logs unexpected getifaddrs() errors. +* CID 739722: Clean up the definition of the exten field of struct pkt. +(4.2.7p454) 2014/07/30 Released by Harlan Stenn +* [Bug 2628] 'mon_getmoremem()' relies on undefined behaviour +(4.2.7p453) 2014/07/19 Released by Harlan Stenn +* [Bug 2597] leap file loose ends (follow-up) + - uniform expiration check messages for config and timer triggered + leap file loads + - timer triggered loads log messages only once per day +(4.2.7p452) 2014/07/18 Released by Harlan Stenn +* Make all of the html/ .html files use the same format for "Last update". +(4.2.7p451) 2014/07/17 Released by Harlan Stenn +* Fix the "Last update" entries in the html/ subtree. +(4.2.7p450) 2014/07/16 Released by Harlan Stenn +* Distribute the scripts needed for the fix for Bug 2547. +(4.2.7p449) 2014/07/16 Released by Harlan Stenn +* [Bug 2547] Automate update of "Last Update" datestamps in .html files. +* [Bug 2623] Missing {} in refclock_oncore.c. +* Quiet warnings from ntp_calendar.h: avoid using argument names. +* Fix typos in decode.html and debug.html . +(4.2.7p448) 2014/07/15 Released by Harlan Stenn +* [Bug 2621] Avoid use of indeterminate address after 'free()' + (minor C standard conformance issue) +* Quiet warnings from ntp_calendar.h: avoid using argument names. +(4.2.7p447) 2014/07/05 Released by Harlan Stenn +* [Bug 2620] Use version.pm for checking version numbers in NTP::Util. +* [Bug 2624] Fix signed compare on 'l_fp'. +(4.2.7p446) 2014/06/28 Released by Harlan Stenn +* [Bug 2597] leap file processing -- loose ends. +* [Bug 2614] use 'unsigned long' consistently in ntp_random.c + to avoid possibly undefined behaviour in signed int overflow +* [Bug 2619] Save a signed int copy of the return value of i2d_DSA_SIG(). + Provide missing msyslog() message in crypto_alice(). +* Fix a variable lifetime issue. +* Allow for version suffix in libevent in ntp_libevent.m4. +(4.2.7p445) 2014/06/12 Released by Harlan Stenn +* [Bug 2556] mrulist isn't mentioned in the ntpq man page. +(4.2.7p444) 2014/05/19 Released by Harlan Stenn +* [Bug 2597] leap file processing -- loose ends + fixed coverity issues +(4.2.7p443) 2014/05/10 Released by Harlan Stenn +* [Bug 2594] Update the year in sntp/include/copyright.def. +(4.2.7p442) 2014/05/09 Released by Harlan Stenn +* [Bug 2589] Update VS2013 project files for libntp. +* [Bug 2600] Fix "Undisicplined Local Clock" driver1.html page. +(4.2.7p441) 2014/05/04 Released by Harlan Stenn +* [Bug 2597] leap file processing -- loose ends + log daily warning when leap info less than 28 days to expiration or + already expired; nag hourly on last day before expiration; log when + leapfile name is invalid +(4.2.7p440) 2014/04/09 Released by Harlan Stenn +* [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup. +* [Bug 2570] cleanup: fix log format for successful leapfile load +(4.2.7p439) 2014/04/03 Released by Harlan Stenn +* [Bug 2589] fix VS2009 compile problem. +(4.2.7p438) 2014/04/01 Released by Harlan Stenn +* [Bug 2546] Windows build documentation updates. +(4.2.7p437) 2014/03/31 Released by Harlan Stenn +* [Bug 2537] ntpd truncates symmetric keys to 20 bytes. +* [Bug 2546] Documentation updates. +(4.2.7p436) 2014/03/31 Released by Harlan Stenn +* Update to libopts-40.2.15, and autogen-5.18.3pre18. +* [Bug 2311] Add more tags to mdoc2xxx. +* [Bug 2502] Assorted text replacement errors in 4.2.7p345 +* [Bug 2538] ntp programs print exit code as part of the "usage" text. +(4.2.7p435) 2014/03/29 Released by Harlan Stenn +* [Bug 2570] cleanup: reduced logging noise, moved some functions + into libntp. +(4.2.7p434) 2014/03/21 Released by Harlan Stenn +* [Bug 2577] Update VS2013 solution and project files. +(4.2.7p433) 2014/03/10 Released by Harlan Stenn +* Clean up last-update timestamps of html/*.html files. +* [Bug 2546] Documentation updates. +(4.2.7p432) 2014/03/09 Released by Harlan Stenn +* CID 711660: Do a non-NULL pointer assertion check a bit earlier. +(4.2.7p431) 2014/03/05 Released by Harlan Stenn +* [Bug 2572] cross-compiling fails for --with-yielding-select. +(4.2.7p430) 2014/03/04 Released by Harlan Stenn +* Upgrade to libevent-2.1.3-alpha-dev. +* [Bug 2572] cross-compiling fails for --with-yielding-select. +(4.2.7p429) 2014/03/03 Released by Harlan Stenn +* CID 1165098: Remove logically dead code from refclock_true.c. +* CID 1189401: Use INSIST() instead of a belt-and-suspenders pointer check. +* In ntp_dir_sep.m4, we care about $host_os, not $target_os. +* [Bug 2170] Use AC_PREPROC_IFELSE instead of AC_EGREP_CPP. +* [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups. +* [Bug 2570] refuse to load leapsec file with bad/missing SHA1 hash + -- change reading the hash line code: NIST omits leading zeros. +* [Bug 2576] refclock_gpsdjson.c doesn't compile if CLOCK_GPSDJSON is + not enabled at configure time. +(4.2.7p428) 2014/03/03 Released by Harlan Stenn +* [Bug 2570] refuse to load leapsec file with bad/missing SHA1 hash +* [Bug 2562] Distribute the code in libjsmn/ . +(4.2.7p427) 2014/03/02 Released by Harlan Stenn +* [Bug 2562] GPSD_JSON: fix solaris issues (asprintf(), isfinite()) +* [Bug 2562] first release of the GPSD client clock (type 46) +(4.2.7p426) 2014/02/28 Released by Harlan Stenn +* [Bug 2113] Warn about ignored extra args in ntpq. +* [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups. +* [Bug 2561] Allow wildcards in the target of the "interface" command. +* [Bug 2572] cross-compiling fails for --with-yielding_select. +(4.2.7p425) 2014/02/26 Released by Harlan Stenn +* Copyright file update. +(4.2.7p424) 2014/02/24 Released by Harlan Stenn +* [Bug 2541] ntpd terminates itself with SIGHUP unexpectedly. +(4.2.7p423) 2014/02/23 Released by Harlan Stenn +* [Bug 2565] Handle EINTR on getifaddrs(). +(4.2.7p422) 2014/02/17 Released by Harlan Stenn +* [Bug 2536] ntpd sandboxing support (libseccomp2). +(4.2.7p421) 2014/02/10 Released by Harlan Stenn +* [Bug 898] More documentation fixes. +* [Bug 2555] Autogen mdoc man pages all stamped with SunOS 5.10. +* calc_tickadj/Makefile.am man/mdoc page build cleanup. +(4.2.7p420) 2014/02/09 Released by Harlan Stenn +* [Bug 492] Clearly document ntpdate's pending deprecation. +* [Bug 1186] ntpd fails with link local IPv6 addresses. +* [Sec 2542] Strengthen the mrulist nonce. +(4.2.7p419) 2014/02/08 Released by Harlan Stenn +* [Bug 2466] Wrap NMEA timestamps in 1024 week cycles. +(4.2.7p418) 2014/02/05 Released by Harlan Stenn +* [Bug 2551] --disable-local-libevent breaks the build. +(4.2.7p417) 2014/02/02 Released by Harlan Stenn +* [Bug 2539] doc and code tweaks for NMEA driver. +* Add check for enable stats to ntpd/complete.conf.in +* Fix typo in html/confopt.html +(4.2.7p416) 2014/01/31 Released by Harlan Stenn +* Tweak the 'Modified' line on appropriate html pages. +* Note in the deprecation of ntpdc in its documentation. +* [Bug 2332] Be more careful about when we use 'libgcc_s'. +(4.2.7p415) 2014/01/28 Released by Harlan Stenn +* Fix the man page installation for the scripts/ files. +(4.2.7p414) 2014/01/28 Released by Harlan Stenn +* [Bug 792] TrueTime TL-3 WWV refclock support. +* [Bug 898] Documentation fixes. +* [Bug 930] ntpdc docs refer to 'clockinfo', but mean 'clockstat'. +* [Bug 1002] ntp-keygen option and documentation updates: -p/--pvt-passwd + is now -p/--password, and -q/--get-pvt-passwd is now -q/--export-passwd. +* [Bug 1349] statistics command not documented in HTML documentation. + In html/monopt.html, add statistics id, definition, description, and + correct typo. + In html/scripts/monopt.txt, add statistics item, href, and comment. + In ntpd/ntp.conf.def, under statistics correct four to eight kinds. + In ntpd/complete.conf.in, add all eight kinds to statistics. + In html/comdex.html, remove duplicate footer. +* [Bug 1734] Include man page for ntp.conf (fixed in 4.2.7p297). +* [Bug 2049] Clarify ntpdate's -d option behavior. +* [Bug 2366] ntpdc.html: burst/iburst only work on servers. +* [Bug 2493] ntptrace needs a man page (fixed in 4.2.7p402). +* [Bug 2545] Cleanup of scripts/monitoring/ntptrap. +(4.2.7p413) 2014/01/27 Released by Harlan Stenn +* Require a version string for perl scripts that use autogen. +* html/ cleanup. +(4.2.7p412) 2014/01/20 Released by Harlan Stenn +* [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups. +(4.2.7p411) 2014/01/12 Released by Harlan Stenn +* [Bug 2532] Note in ntpdc docs that "enable pps" only works on older ntpd. +(4.2.7p410) 2014/01/08 Released by Harlan Stenn +* [Bug 2332] Force reference to 'libgcc_s' when using GCC, because + threading+restricted user+locked memory otherwise fails on Linux. +* [Bug 2530] Fix documentation for enable/disable mode7 and pps. +* Cleanup to the new scripts/*/Makefile.am files. +(4.2.7p409) 2014/01/04 Released by Harlan Stenn +* [Bug 2060] Warn about restrictions with "kod" but not "limited". +(4.2.7p408) 2013/12/29 Released by Harlan Stenn +* [Bug 2187] Update version number generation scripts. +(4.2.7p407) 2013/12/29 Released by Harlan Stenn +* [Bug 2519] mktime.c does not compile on 64-bit Solaris but we do not + need timegm() and the Solaris provides mktime(). +* [Bug 2522] Revert Bug 2513 fix - it breaks backward compatibility. +(4.2.7p406) 2013/12/28 Released by Harlan Stenn +* [Bug 2521] VPATH tweaks for perl -opts files. +(4.2.7p405) 2013/12/27 Released by Harlan Stenn +* [Bug 2521] bootstrap script needs a tweak for perl -opts files. +* [Bug 2524] Add ntpsweep to sntp/loc/* files. +* [Bug 2526] Add "noinst" support to the sntp/loc/ framework. +(4.2.7p404) 2013/12/24 Released by Harlan Stenn +* [Bug 135] AIX5: "Address already in use" for IPv6 wildcard. +(4.2.7p403) 2013/12/23 Released by Harlan Stenn +* [Bug 2513] Remove any PIDFILE in finish(). +* [Bug 2516] Enable clock_gettime() support for AIX 5+. +* [Bug 2517] Fix peer status errors in decode.html. +(4.2.7p402) 2013/12/23 Released by Harlan Stenn +* Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup. +(4.2.7p401) 2013/11/30 Released by Harlan Stenn +* [Bug 2491] VS20xx compile fixes. +(4.2.7p400) 2013/11/29 Released by Harlan Stenn +* [Bug 2491] VS2013 project files. +(4.2.7p399) 2013/11/28 Released by Harlan Stenn +* [Bug 2326] More leapsecond file notification cleanup. +* [Bug 2506] make sure routing updates are always tracked +* [Bug 2514] secs/* #define usage cleanup. +(4.2.7p398) 2013/11/25 Released by Harlan Stenn +* [Bug 2326] More leapsecond file notification cleanup. +* Improve sntp KoD data file fopen() error message. +(4.2.7p397) 2013/11/20 Released by Harlan Stenn +* [Bug 2326] More leapsecond file notification cleanup. +(4.2.7p396) 2013/11/19 Released by Harlan Stenn +* [Bug 2326] Improve stale leapsecond notifications. +(4.2.7p395) 2013/11/12 Released by Harlan Stenn +* Upgrade to autogen-5.18.3pre5 and libopts-40.1.15. +(4.2.7p394) 2013/11/05 Released by Harlan Stenn +* [Bug 1050] Change ONCORE log message for leap second announcement + to avoid misunderstandings. +* [Bug 2499] Win32 user-space/loopback ppsapi provider drops samples. +* [Bug 2256] Improve configure's function searches in libraries. +(4.2.7p393) 2013/10/16 Released by Harlan Stenn +* [Bug 2272] Use C99 integer types. ntp_calendar.h and ntp_types.h . +(4.2.7p392) 2013/10/15 Released by Harlan Stenn +* [Bug 2375] Improve AIX compatibility. +* [Bug 2490] Fixed non-const initializer coming from [Bug 2250] fix. +(4.2.7p391) 2013/10/12 Released by Harlan Stenn +* [Bug 2250] Rework of leap second handling machine. +* [Bug 2419] [rc-nmea] Improve clockstats reporting when receiver sends + data without valid GPS fix. +(4.2.7p390) 2013/09/26 Released by Harlan Stenn +* [Bug 2482] Cleanup of droproot and jail support for Solaris. +(4.2.7p389) 2013/09/24 Released by Harlan Stenn +* [Bug 2473] revisited: NTPD exits after clock is stepped backwards + Avoid possible unsigned underrun for startup condition when testing + for clock backstep. +* [Bug 2481] ntpd aborts when both user and group are specified with -u. +* [Bug 2482] Add droproot and jail support for Solaris. +(4.2.7p388) 2013/09/19 Released by Harlan Stenn +* [Bug 2473] NTPD exits after clock is stepped backwards externally +(4.2.7p387) 2013/09/16 Released by Harlan Stenn +* [Bug 1642] ntpdsim can't find simnulate block in config file. +(4.2.7p386) 2013/09/01 Released by Harlan Stenn +* [Bug 2472] (WinXP) Avoid self-termination of IO thread during exit(). +(4.2.7p385) 2013/08/19 Released by Harlan Stenn +* CID 975596: Copy/paste error: vallen should be siglen. +* CID 1009579: Check return status of X509_add_ext(). +* [2085] Fix root distance and root dispersion calculations. +* [Bug 2426] Possibly uninitialized data in crypto_send() - CID 975596. +(4.2.7p384) 2013/08/18 Released by Harlan Stenn +* [Bug 2450] --version has bogus short option. +(4.2.7p383) 2013/08/10 Released by Harlan Stenn +* (no changes - force a rebuild for a new Coverity scan) +(4.2.7p382) 2013/08/08 Released by Harlan Stenn +* [Bug 2454] Need way to set file descriptor limit - cleanup. +(4.2.7p381) 2013/08/07 Released by Harlan Stenn +* [Bug 2451] rlimit command is missing from the table of contents in + miscopt.html . +* [Bug 2452] provide io_handler/input_handler only on + non HAVE_IO_COMPLETION_PORT platforms +* [Bug 2453] Need a way to avoid calling mlockall. +* [Bug 2454] Need way to set file descriptor limit. +* [Bug 2458] AM_CONFIG_HEADER is obsolete. +(4.2.7p380) 2013/08/03 Released by Harlan Stenn +* CID 984511: Some systems have different printf needs for sizeof. +(4.2.7p379) 2013/08/02 Released by Harlan Stenn +* CID 739724: Fix printf arg mismatch in a debug line. +* [Bug 2425] compile io_handler() in ntp_io.c unconditionally +* [Bug 2448] Fix checks for configure --with-stack-limit and --with-memlock + values. +(4.2.7p378) 2013/08/01 Released by Harlan Stenn +* [Bug 2425] move part of input handler code from ntpd.c to ntp_io.c + and fix select()-only platforms calling input_handler directly. +* [Bug 2446] Quiet warnings from Oracle's Studio compiler. +* Upgrade to AutoGen-5.18.1pre3 +* Upgrade to libopts-40.1.15. +(4.2.7p377) 2013/07/28 Released by Harlan Stenn +* [Bug 2397] License/copyright cleanup. +* [Bug 2439] Fix check of EscapeCommFunction() in ports/winnt/libntp/termios.c. +(4.2.7p376) 2013/07/24 Released by Harlan Stenn +* [Bug 2322] Oncore driver should send 0 PPS offset to GPS. +(4.2.7p375) 2013/07/22 Released by Harlan Stenn +* [Bug 883] log warning arguments swapped in refclock_gpsvme.c. +* [Bug 2368] Correct bug in previous attempt. +* [Bug 2413] Fix "make check" with automake >= 1.13. +* [Bug 2434] Line-buffer (v. block-buffer) stdout. +(4.2.7p374) 2013/07/21 Released by Harlan Stenn +* [Bug 2368] make check troubles in libevent. +* [Bug 2425] setup SIGIO/SIGPOLL for asyncio on the read side + of a socketpair for the worker thread. +(4.2.7p373) 2013/07/20 Released by Harlan Stenn +* [Bug 2427] configure fails to detect recvmsg() on Solaris. +(4.2.7p372) 2013/07/17 Released by Harlan Stenn +* [Bug 1466] Oncore should set FLAG_PPS. +* [Bug 2375] AIX 7 doesn't like a libevent validation check. +* [Bug 2423] Log command-line args at LOG_INFO. +* [Bug 2428] do_unconf() should reset 'items' before the 2nd loop. +(4.2.7p371) 2013/07/07 Released by Harlan Stenn +* CID 1042586: Check the return value of clock_gettime() in worker_sleep(). +* Upgrade to libopts-39.0.14 from 5.17.5pre10. +(4.2.7p370) 2013/07/06 Released by Harlan Stenn +* Remove \n's from syslog output strings. +(4.2.7p369) 2013/07/05 Released by Harlan Stenn +* [Bug 2415] RES_LIMITED flags check should use &, not &&. +* Have NTP_LIBNTP check for time.h and clock_getres(). +* Fix ntpsweep to use sntp instead of ntpdate, from Oliver Kindernay. +(4.2.7p368) 2013/05/01 Released by Harlan Stenn +* [Bug 2145] ntpq dumps core when displaying sys_var_list and more. +(4.2.7p367) 2013/04/25 Released by Harlan Stenn +* [Bug 1485] Sometimes ntpd crashes +* [Bug 2382] Implement LOGTOD using ldexp() instead of shifting. +(4.2.7p366) 2013/04/17 Released by Harlan Stenn +* [Bug 1866] Disable some debugging output in refclock_oncore. +(4.2.7p365) 2013/04/16 Released by Harlan Stenn +* [Bug 2149] Log an error message if /proc/net/if_inet6 cannot be opened. +(4.2.7p364) 2013/03/26 Released by Harlan Stenn +* Bump sntp/include/autogen-version.def . +(4.2.7p363) 2013/03/26 Released by Harlan Stenn +* [Bug 2357] sntp/libopts/usage.c sometimes needs -lintl. +* Upgrade to libopts from 5.17.3pre10. +(4.2.7p362) 2013/03/19 Released by Harlan Stenn +* [Bug 2364] "sed -i" is not portable. +(4.2.7p361) 2013/03/17 Released by Harlan Stenn +* [Bug 2357] sntp/libopts/usage.c sometimes needs -lintl. +* [Bug 2365] "make check" fails in libevent. +(4.2.7p360) 2013/03/15 Released by Harlan Stenn +* Upgrade libevent (coverity fixes, etc.). +* EEXIST is OK for mkdir() in sntp/kod_management.c. +(4.2.7p359) 2013/03/03 Released by Harlan Stenn +* [Bug 2359] Fix send_via_ntp_signd() prototype. +(4.2.7p358) 2013/02/27 Released by Harlan Stenn +* Upgrade to autogen-5.17.3pre4 and libopts-38.0.13. +* [Bug 2357] sntp/libopts/usage.c on NetBSD needs -lintl. +(4.2.7p357) 2013/02/22 Released by Harlan Stenn +* Upgrade to autogen-5.17.2pre and libopts-38.0.13. +(4.2.7p356) 2013/02/19 Released by Harlan Stenn +* Added loc/debian. +(4.2.7p355) 2013/02/18 Released by Harlan Stenn +* CID 739708: Check return status of fcntl() in refclock_arc.c. +* CID 739709: Check return status of fcntl() in refclock_datum.c. +* CID 739710: Check return status of mkdir() in sntp/kod_management.c. +* CID 739711: Ignore return status of remove() in ntp-keygen.c. +* CID 739723: Print sizeof as unsigned. +* CID 971094: Clean up time of check/time of use in check_leap_file(). +(4.2.7p354) 2013/02/10 Released by Harlan Stenn +* CID 97194: Check return from setsockopt(). +* CID 739473,739532: Out-of-bounds access/illegal address computation. +* CID 739558: Double close. +* CID 739559: Double close. +* CID 739713: devmask/recmask copy/paste error. +* CID 739714: Fix code indentation level. +* CID 739715: Clean up sockaddr_dump(). +(4.2.7p353) 2013/02/09 Released by Harlan Stenn +* [Bug 2326] Check hourly for a new leapfile if the old one expired. +(4.2.7p352) 2013/01/28 Released by Harlan Stenn +* [Bug 2326] Notice when a new leapfile has been installed. +(4.2.7p351) 2013/01/24 Released by Harlan Stenn +* [Bug 2328] Don't apply small time adjustments on Windows versions + which don't support this. +(4.2.7p350) 2013/01/21 Released by Harlan Stenn +* Added sntp/loc/netbsd based on info from Christos Zoulas. +(4.2.7p349) 2013/01/20 Released by Harlan Stenn +* [Bug 2321] Fixed Windows build, but autogen update still required. +(4.2.7p348) 2013/01/17 Released by Harlan Stenn +* [Bug 2327] Rename sntp/ag-tpl/:Old to sntp/ag-tpl/Old. +* Cleanup to ntpsnmpd-opts.def. +* Cleanup to ntpq.texi. +* Documentation cleanup to the ntpd, ntpdc, ntpq and ntp-wait + .def files. +* In ntp.conf.def, cleanup SEE ALSO, document 'rlimit' options. +* Add a reference to RFC5907 in the ntpsnmpd documentation. +(4.2.7p347) 2013/01/07 Released by Harlan Stenn +* [Bug 2325] Re-enable mlockall() check under Linux post-1223 fix. +(4.2.7p346) 2013/01/06 Released by Harlan Stenn +* [Bug 1223] reorganize inclusion of sys/resource.h. +(4.2.7p345) 2013/01/04 Released by Harlan Stenn +* Update several .def files to use autogen-5.17 feature set. +(4.2.7p344) 2013/01/03 Released by Harlan Stenn +* Refactor and enhance mdoc2texi. +* Make sure agtexi-file.tpl defines label-str. +* Cleanup to ntp.conf.def. +* Upgrade to autogen-5.17 and libopts-37.0.12. +(4.2.7p343) 2013/01/02 Released by Harlan Stenn +* Update the copyright year. +(4.2.7p342) 2012/12/31 Released by Harlan Stenn +* [Bug 2081 - Backward Incompatible] rawstats now logs everything. +(4.2.7p341) 2012/12/30 Released by Harlan Stenn +(4.2.7p340) 2012/12/29 Released by Harlan Stenn +* mdoc2texi fixes: trailing punctuation. +(4.2.7p339) 2012/12/26 Released by Harlan Stenn +* mdoc2texi fixes: parseQuote, closing of list item tables. +* ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates. +(4.2.7p338) 2012/12/25 Released by Harlan Stenn +* mdoc2texi fixes: Handle_ArCmFlIc, Handle_Fn, HandleQ. +* ntp-keygen autogen documentation updates. +* ntpq autogen docs. +(4.2.7p337) 2012/12/22 Released by Harlan Stenn +* [Bug 1223] More final cleanup for rlimit changes. +(4.2.7p336) 2012/12/21 Released by Harlan Stenn +* [Bug 1223] Final cleanup for rlimit changes. +(4.2.7p335) 2012/12/18 Released by Harlan Stenn +* Update documentation templates and definitions. +* Create agtexi-file.tpl . +(4.2.7p334) 2012/12/10 Released by Harlan Stenn +* [Bug 2114] Update tests for sntp's synch distance. +* Create ntp-keygen.{html,texi}. +(4.2.7p333) 2012/12/07 Released by Harlan Stenn +* Autogen documentation cleanup. +(4.2.7p332) 2012/12/06 Released by Harlan Stenn +* sntp documentation cleanup. +(4.2.7p331) 2012/12/03 Released by Harlan Stenn +* [Bug 2114] Correctly calculate sntp's synch distance. +(4.2.7p330) 2012/12/03 Released by Harlan Stenn +* autogen doc cleanup +(4.2.7p329) 2012/12/01 Released by Harlan Stenn +* [Bug 2278] ACTS flag3 mismatch between code and driver18.html. +* Use an enum for the ACTS state table. +* html doc reconciliation with DLM's copy. +(4.2.7p328) 2012/11/30 Released by Harlan Stenn +* html doc reconciliation with DLM's copy. +(4.2.7p327) 2012/11/29 Released by Harlan Stenn +* [Bug 2024] Identify Events in the system status word in decode.html.' +* [Bug 2040] Provide a command-line option for the identity key bits. +* Create loc/darwin for Mac OSX +(4.2.7p326) 2012/11/21 Released by Harlan Stenn +* [Bug 1214] 'proto: precision = ...' should be at INFO, not NOTICE. +* [Bug 2246] Clear sys_leap when voting says to disarm the leap. +(4.2.7p325) 2012/11/20 Released by Harlan Stenn +* [Bug 2202] ntpq.html: there is no "acv" billboard. +* [Bug 2306] keep pps hack for Win32 even if user-mode/loopback + PPS API is activated on a serial line. +(4.2.7p324) 2012/11/19 Released by Harlan Stenn +* Reinstate doc fix to authentic.html from Mike T. +* [Bug 1223] cleanup for rlimit changes. +* [Bug 2098] Install DLM's HTML documentation. +* [Bug 2306] Added user-mode/loop-back PPS API provider for Win32 +(4.2.7p323) 2012/11/18 Released by Harlan Stenn +* html/ updates from Dave Mills. +(4.2.7p322) 2012/11/15 Released by Harlan Stenn +* [Bug 1223] Allow configurable values for RLIMIT_STACK and + RLIMIT_MEMLOCK. +* [Bug 1320] Log ntpd's initial command-line parameters. (updated fix) +* [Bug 2120] no sysexits.h under QNX. +* [Bug 2123] cleanup to html/leap.html. +(4.2.7p321) 2012/11/13 Released by Harlan Stenn +* [Bug 1320] Log ntpd's initial command-line parameters. +(4.2.7p320) 2012/11/12 Released by Harlan Stenn +* [Bug 969] Clarify ntpdate.html documentation about -u and ntpd. +* [Bug 1217] libisc/ifiter_sysctl.c:internal_current(): Ignore RTM + messages with wrong version +(4.2.7p319) 2012/11/11 Released by Harlan Stenn +* [Bug 2296] Fix compile problem with building with old OpenSSL. +(4.2.7p318) 2012/11/05 Released by Harlan Stenn +* [Bug 2301] Remove spurious debug output from ntpq. +(4.2.7p317) 2012/11/05 Released by Harlan Stenn +* [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line. +(4.2.7p316) 2012/10/27 Released by Harlan Stenn +* [Bug 2296] Update fix for Bug 2294 to handle --without-crypto. +(4.2.7p315) 2012/10/26 Released by Harlan Stenn +* [Bug 2294] ntpd crashes in FIPS mode. +(4.2.7p314) 2012/10/23 Released by Harlan Stenn +* Document a tricky malloc() of dns_ctx in sntp. +(4.2.7p313) 2012/10/23 Released by Harlan Stenn +* [Bug 2291] sntp should report why it cannot open file.kod. +* [Bug 2293] add support for SO_BINTIME, refine support for + SO_TIMESTAMPNS (bug 1374) +(4.2.7p312) 2012/10/11 Released by Harlan Stenn +* Clean up testing/debugging of fix for [Bug 938] from sntp/main.c . +(4.2.7p311) 2012/10/10 Released by Harlan Stenn +* [Bug 938] The argument to the -D flag takes a number, not a string. +* [Bug 1013] ntpdate's HTML page claims wrong default version. +* [Bug 1374] Support SO_TIMESTAMPNS. +(4.2.7p310) 2012/10/09 Released by Harlan Stenn +* [Bug 1374] Support SO_TIMESTAMPNS. +* [Bug 2266] Remove deprecated refclock_trak.c from Windows Makefile + equivalents. +* [Bug 2274] Bring libopts/enum.c back to (old) ANSI C compliance. +(4.2.7p309) 2012/10/04 Released by Harlan Stenn +* [Bug 2287] ntpdate returns 0 even if adjtime() call fails. +(4.2.7p308) 2012/09/29 Released by Harlan Stenn +* CID 97198: Check return from ioctl() calls in refclock_acts.c. +(4.2.7p307) 2012/09/29 Released by Harlan Stenn +* [Bug 1997] Fix sntp broadcast timeouts. +* [Bug 2234] Fix incorrect ntptrace html documentation. +* [Bug 2262] Install html docs in $htmldir. +* Fix typo in html/select.html. +(4.2.7p306) 2012/09/15 Released by Harlan Stenn +* [Bug 752] ToS cleanup from Mike Tatarinov. +(4.2.7p305) 2012/09/15 Released by Harlan Stenn +* [Bug 752] Use proper ToS network packet markings for IPv4 and IPv6. +* [Bug 1232] Convert SHM refclock to use struct timespec. +* [Bug 2258] Add syslog message about leap insertion. +* [Bug 2263] broadcast server doesn't work for host with + OS_MISSES_SPECIFIC_ROUTE_UPDATES. +* [Bug 2271] Decode refclock types when built with --disable-all-clocks. +* [Bug 2276] clk_sel240x.c #define's _XOPEN_SOURCE, breaking QNX6. +* Updates to driver28.html. +(4.2.7p304) 2012/09/06 Released by Harlan Stenn +* [Bug 2264] Cleanup SEL240X Refclock. +* In refclock_wwv.c rename SECOND to WWV_SEC and MINUTE to WWV_MIN. +(4.2.7p303) 2012/09/05 Released by Harlan Stenn +* [Bug 1232] Add nanosecond support to SHM driver. +(4.2.7p302) 2012/09/05 Released by Harlan Stenn +* [Bug 2160] Log warning about expired leapseconds file. +(4.2.7p301) 2012/09/03 Released by Harlan Stenn +* [Bug 2164] Greater precision needed for ntpq offset report. +* Clean the man5_MANS in ntpd/ . +(4.2.7p300) 2012/09/03 Released by Harlan Stenn +* [Bug 2262] Install sntp.html into htmldir. +* [Bug 2270] Install fails due to repeated man5 page names. +(4.2.7p299) 2012/09/01 Released by Harlan Stenn +* More cleanup to the bootstrap script. +(4.2.7p298) 2012/09/01 Released by Harlan Stenn +* Handle additional man page sections in the bootstrap script. +* Remove extraneous parens. +* Add a missing "%s" syslog format string. +(4.2.7p297) 2012/09/01 Released by Harlan Stenn +* Fix mdoc2man. +* Distribute ntp.conf.def and ntp.keys.def. +(4.2.7p296) 2012/08/31 Released by Harlan Stenn +* Begin support for autogen maintaining ntp.conf and ntp.keys docs. +* Upgrade to autogen-5.16.2 and libopts-36.5.11. +* Potential bugfix for agtexi-cmd.tpl. +(4.2.7p295) 2012/08/11 Released by Harlan Stenn +* Look for syslog's facilitynames[]. +(4.2.7p294) 2012/08/08 Released by Harlan Stenn +* [Bug 2242] configure fails to detect getifaddrs function on Solaris. +* [Bug 2249] Bad operator for 'test' in 'make check' of libevent. +* [Bug 2252] palisade: formats nanosecs to a 6-char field. +* Attempt to resolve strict-aliasing violation in refclock_tsyncpci.c. +* Fix && -> & typo in refclock_palisade.c debug statements. +(4.2.7p293) 2012/08/04 Released by Harlan Stenn +* [Bug 2247] (more) Get rid of the TRAK refclock - deprecated since 2006. +* Documentation cleanup from Mike T. +* Cleanup kclk_sel240x.o rules in libparse/Makefile.am. +(4.2.7p292) 2012/08/02 Released by Harlan Stenn +* [Bug 1545] Note why we are logging the Version string. +* [Bug 1872] Remove legacy ppsclock fdpps, #ifdef PPS. +* [Bug 2075] Fix spelling of 'incompatible'. +* [Bug 2247] Get rid of the TRAK refclock - deprecated since 2006. +* Clean up an exit status in ntpq.c. +(4.2.7p291) 2012/07/31 Released by Harlan Stenn +* [Bug 2241] MDNS registration should only happen if requested. +(4.2.7p290) 2012/07/20 Released by Harlan Stenn +* [Bug 1454] Add parse clock support for the SEL-240x GPS products. +* CID 709185: refclock_chu.c will leak fd==0 (better fix) +(4.2.7p289) 2012/07/16 Released by Harlan Stenn +* CID 97123: Future-proof possible change to refclock_nmea.c. +* CID 97377: ntp-keygen.c's followlink() might not NUL-terminate. +* CID 709185: refclock_chu.c will leak fd==0 (which should be impossible). +(4.2.7p288) 2012/07/03 Released by Harlan Stenn +* CID 709173: Make sure a libisc function we do not use is called properly. +(4.2.7p287) 2012/07/03 Released by Harlan Stenn +* Remove 1024 associations-per-server limit from ntpq. +* Remove blank line between ntpq mreadvar associations. +(4.2.7p286) 2012/06/28 Released by Harlan Stenn +* CID 97193: check return from sscanf() in ntp_config.c. +* CID 709169: check return from open("/dev/null", 0) and friends. +* CID 709207: Initialize "quality" for ulink_receive. +(4.2.7p285) 2012/06/18 Released by Harlan Stenn +* [Bug 2227] Enable mrulist access control via "restrict ... nomrulist". +* Automake-1.12 wants us to use AM_PROG_AR. +* Conditionalize msyslog messages about rejected mode 6 requests due to + nomodify and nomrulist restrictions under "logconfig +sysinfo". +* Increment sys_restricted in a few rejection paths due to nomodify + restrictions where previosuly overlooked. +(4.2.7p284) 2012/06/16 Released by Harlan Stenn +* [Bug 2225] libevent configure hangs. +* Update bundled libevent to git master, post libevent 2.1.1-alpha. +(4.2.7p283) 2012/06/16 Released by Harlan Stenn +* In sntp/m4/ntp_openssl.m4, Support multiple package names for the + crypto library. Add legacy support for -Wl,-rpath. +(4.2.7p282) 2012/06/15 Released by Harlan Stenn +* tickadj may need to be linked with PTHREAD_LIBS. +(4.2.7p281) 2012/06/14 Released by Harlan Stenn +* U_INT32_MAX cleanup in include/ntp_types.h . +* When linking, ntp_keygen and tickadj need $(LIBM). +(4.2.7p280) 2012/06/13 Released by Harlan Stenn +* [Bug 2224] Use-after-free in routing socket code after dropping root. +(4.2.7p279) 2012/06/10 Released by Harlan Stenn +* [Bug 2211] findbcastinter(): possibly undefined variable iface used. +* [Bug 2220] Incorrect check for maximum association id in ntpq. +(4.2.7p278) 2012/06/03 Released by Harlan Stenn +* [Bug 2204] Build with --enable-getifaddrs=glibc fails. +* [Bug 2178] refclock_tsyncpci.c reach register fails to shift. +* [Bug 2191] dcfd -Y y2kcheck on CentOS 6.2 x86_64 breaks make check. +(4.2.7p277) 2012/05/25 Released by Harlan Stenn +* [Bug 2193] Building timestruct tests with Clang 3.1 fails. +(4.2.7p276) 2012/05/15 Released by Harlan Stenn +* [Bug 2179] Remove sntp/header.h. +(4.2.7p275) 2012/04/28 Released by Harlan Stenn +* [Bug 1744] Remove obsolete ntpdate/ntptime* items. +(4.2.7p274) 2012/04/25 Released by Harlan Stenn +* [Bug 2174] ntpd rejects source UDP ports less than 123 as bogus. +(4.2.7p273) 2012/04/19 Released by Harlan Stenn +* [Bug 2141] handle_sigio() calls get_systime(), which must be + reentrant when SIGIO is used. Sanity checks relative to the prior + get_systime() are disabled in ntpd on systems with signaled I/O, but + active in sntp and ntpdate. +* Correct authnumfreekeys accounting broken in 4.2.7p262. +(4.2.7p272) 2012/04/14 Released by Harlan Stenn +* LCRYPTO is gone - replace with VER_SUFFIX. +* Change the link order for ntpsntpd. +* Remove extra 'nlist' check from configure.ac. +(4.2.7p271) 2012/04/11 Released by Harlan Stenn +* [Bug 1122] openssl detection via pkg-config fails when no additional + -Idir flags are needed. +* Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. +(4.2.7p270) 2012/03/26 Released by Harlan Stenn +* Update driver45.html page. +(4.2.7p269) 2012/03/25 Released by Harlan Stenn +* Clean up configure.ac. +* Cleanup configure.ac's TSYNC PCI section. +(4.2.7p268) 2012/03/24 Released by Harlan Stenn +* Update driver45.html page. +(4.2.7p267) 2012/03/23 Released by Harlan Stenn +* Initial cut at a basic driver45.html page. +(4.2.7p266) 2012/03/21 Released by Harlan Stenn +* Add refclock_tsyncpci.c (driver 45) supporting Spectracom TSYNC timing + boards. +(4.2.7p265) 2012/03/20 Released by Harlan Stenn +* Treat zero counter as indication of precise system time in Windows + PPSAPI helper function pps_ntp_timestamp_from_counter(), enabling + PPSAPI providers to use the Windows 8 precise clock directly. +(4.2.7p264) 2012/03/14 Released by Harlan Stenn +* [Bug 2160] Note if leapseconds file is past its prime. +* Use GetSystemTimePreciseAsFileTime() on Windows 8. +(4.2.7p263) 2012/03/13 Released by Harlan Stenn +* [Bug 2156] clock instability with LOCAL driver, from Miroslav Lichvar. +* [Bug 2159] Windows ntpd using leapfile erroneous leap second 20120401. +(4.2.7p262) 2012/02/29 Released by Harlan Stenn +* Improve ntpd scalability for servers with many trusted keys. +(4.2.7p261) 2012/02/27 Released by Harlan Stenn +* [Bug 2048] add the clock variable timecode to SHM refclock. +(4.2.7p260) 2012/02/24 Released by Harlan Stenn +* Fix the check-scm-rev invocation in several Makefile.am's. +(4.2.7p259) 2012/02/22 Released by Harlan Stenn +* [Bug 2148] ntpd 4.2.7p258 segfault with 0x0100000 bit in NMEA mode. +* refclock_nmea.c merge cleanup thanks to Juergen Perlinger. +(4.2.7p258) 2012/02/21 Released by Harlan Stenn +* [Bug 2140] Rework of Windows I/O completion port handling to avoid + garbling serial input in UNIX line discipline emulation. +* [Bug 2143] NMEA driver: discard data if quality indication not good, + add statistic counters (mode bit enabled) to clockstats file. +(4.2.7p257) 2012/02/17 Released by Harlan Stenn +* [Bug 2135] defer calls to 'io_input' to main thread under Windows. +(4.2.7p256) 2012/02/08 Released by Harlan Stenn +* [Bug 2131] Set the system variable settimeofday only after clock step. +* [Bug 2134] --enable-C99-snprintf does not force rpl_snprintf use. +(4.2.7p255) 2012/01/29 Released by Harlan Stenn +* [Bug 603] Only link with nlist()-related libraries when needed: + More cleanup. +(4.2.7p254) 2012/01/29 Released by Harlan Stenn +* [Bug 603] Only link with nlist()-related libraries when needed. +(4.2.7p253) 2012/01/26 Released by Harlan Stenn +* [Bug 2126] Compile error on Windows with libopts from Autogen 5.14. +* Update one of the license URLs. +(4.2.7p252) 2012/01/25 Released by Harlan Stenn +* Upgrade to autogen-5.14 (and libopts-36.1.11). +(4.2.7p251) 2012/01/17 Released by Harlan Stenn +* [Bug 2115] ntptrace should accept both rootdispersion and rootdisp. +(4.2.7p250) 2012/01/15 Released by Harlan Stenn +* [Bug 2113] Warn about ignored extra args in ntpq. +* Update the copyright year. +(4.2.7p249) 2012/01/10 Released by Harlan Stenn +* [Bug 2111] Remove minpoll delay before iburst for pool and + manycastclient. +* Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. +(4.2.7p248) 2012/01/08 Released by Harlan Stenn +* [Bug 2109] "make clean check" is broken with gtest available. +* [Bug 2110] systime.c typo breaks build on microsecond clocks. +(4.2.7p247) 2012/01/07 Released by Harlan Stenn +* Fix build break triggered by updating deps-ver and libntp/systime.c at + the same time by explicitly depending systime_s.c on systime.c. +(4.2.7p246) 2012/01/06 Released by Harlan Stenn +* [Bug 2104] ntpdc fault with oversize -c command. +* [Bug 2106] Fix warnings when using -Wformat-security. +* Refactor timespecops.h and timevalops.h into inline functions. +(4.2.7p245) 2011/12/31 Released by Harlan Stenn +* [Bug 2100] conversion problem with timespec/timeval <--> l_fp fixed; + added tests to expose the bug. +(4.2.7p244) 2011/12/25 Released by Harlan Stenn +* Updates from 4.2.6p5. +(4.2.7p243) 2011/12/23 Released by Harlan Stenn +* [Bug 2095] ntptrace now needs 'rv' instead of 'pstat', reported + by Michael Tatarinov. +(4.2.7p242) 2011/12/21 Released by Harlan Stenn +* Include missing html/icons/sitemap.png, reported by Michael Tatarinov. +* Documentation updates from Dave Mills. +(4.2.7p241) 2011/12/18 Released by Harlan Stenn +* [Bug 2015] Overriding sys_tick should recalculate sys_precision. +* [Bug 2037] Fuzzed non-interpolated clock may decrease. +* [Bug 2068] "tos ceiling" default and cap changed to 15. +* Floor peer delay using system precision, as with jitter, reflecting + inability to measure shorter intervals. +(4.2.7p240) 2011/12/15 Released by Harlan Stenn +* [Bug 2092] clock_select() selection jitter miscalculated. +* [Bug 2093] Reintroduce smaller stratum factor to system peer metric. +(4.2.7p239) 2011/12/11 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p238) 2011/12/09 Released by Harlan Stenn +* [Bug 2082] from 4.2.6p5-RC3: 3-char refid sent by ntpd 4.2.6p5-RC2 + ends with extra dot. +* [Bug 2085] from 4.2.6p5-RC3: clock_update() sys_rootdisp calculation + omits root delay. +* [Bug 2086] from 4.2.6p5-RC3: get_systime() should not offset by + sys_residual. +* [Bug 2087] from 4.2.6p5-RC3: sys_jitter calculation overweights + sys.peer jitter. +* from 4.2.6p5-RC3: Ensure NULL peer->dstadr is not accessed in orphan + parent selection. +(4.2.7p237) 2011/12/01 Released by Harlan Stenn +* [Bug 2050] from 4.2.6p5-RC2: Orphan mode stratum counting to infinity. +* [Bug 2059] from 4.2.6p5-RC2: optional billboard column "server" does + not honor -n. +* [Bug 2066] from 4.2.6p5-RC2: ntpq lopeers ipv6 "local" column overrun. +* [Bug 2068] from 4.2.6p5-RC2: ntpd sends nonprintable stratum 16 refid + to ntpq. +* [Bug 2069] from 4.2.6p5-RC2: broadcastclient, multicastclient spin up + duplicate ephemeral associations without broadcastdelay. +* [Bug 2072] from 4.2.6p5-RC2: Orphan parent selection metric needs + ntohl(). +* [Bug 2073] Correct ntpq billboard's MODE_PASSIVE t from 'u' to 'S'. +* from 4.2.6p5-RC2: Exclude not-yet-determined sys_refid from use in + loopback TEST12 (from Dave Mills). +* from 4.2.6p5-RC2: Never send KoD rate limiting response to MODE_SERVER. +* Floor calculation of sys_rootdisp at sys_mindisp in clock_update (from + Dave Mills). +* Restore 4.2.6 clock_combine() weighting to ntp-dev, reverting to pre- + 4.2.7p70 method while also avoiding divide-by-zero (from Dave Mills). +* Round l_fp traffic interval when converting to integer in rate limit + and KoD calculation. +(4.2.7p236) 2011/11/16 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p235) 2011/11/16 Released by Harlan Stenn +* [Bug 2052] Autokey CRYPTO_ASSOC host@group vallen needs checking. +(4.2.7p234) 2011/11/07 Released by Harlan Stenn +* Clean up -libm entries regarding libntp.a +(4.2.7p233) 2011/11/06 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p232) 2011/11/05 Released by Harlan Stenn +* Update the NEWS file so we note the default disable of mode 7 requests. +* Clean up some bitrotted code in libntp/socket.c. +(4.2.7p231) 2011/11/03 Released by Harlan Stenn +* [Bug 1940] ignore auth key if hex decoding fails. +* Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. +(4.2.7p230) 2011/11/01 Released by Harlan Stenn +* Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. +* Directly limit the number of datagrams in a mrulist response, rather + than limiting the number of entries returned to indirectly limit the + datagram count. +* Documentation updates from Dave Mills. +(4.2.7p229) 2011/10/26 Released by Harlan Stenn +* [Bug 1995] fix wrong use of ZERO() macro in 'ntp_calendar.c' +(4.2.7p228) 2011/10/23 Released by Harlan Stenn +* [Bug 1995] add compile time stamp based era unfolding for + 'step_systime()' and necessary support to 'ntp-calendar.c'. +(4.2.7p227) 2011/10/22 Released by Harlan Stenn +* [Bug 2036] gcc 2.95.3 preprocessor can't nest #ifdef in macro args. +* A number of compiler warnings eliminated. +(4.2.7p226) 2011/10/21 Released by Harlan Stenn +* [Bug 2035] ntpq -c mrulist sleeps 1 sec between queries, not 5 msec. +* Documentation updates from Dave Mills. +(4.2.7p225) 2011/10/15 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p224) 2011/10/14 Released by Harlan Stenn +* ntpq mrulist shows intermediate counts every five seconds while + retrieving list, and allows Ctrl-C interruption of the retrieval, + showing the incomplete list as retrieved. Reduce delay between + successive mrulist retrieval queries from 30 to 5 msec. Do not + give up mrulist retrieval when a single query times out. +(4.2.7p223) 2011/10/12 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p222) 2011/10/11 Released by Harlan Stenn +* [Bug 2029] "make check" clutters syslog. +* Log signal description along with number on ntpd exit. +(4.2.7p221) 2011/10/10 Released by Harlan Stenn +* [Bug 2025] Switching between daemon and kernel loops can doubly- + correct drift +* [Bug 2028] ntpd -n (nofork) redirects logging to stderr. +* Documentation updates from Dave Mills. +(4.2.7p220) 2011/10/05 Released by Harlan Stenn +* [Bug 1945] mbg_gps166.h use of _TM_DEFINED conflicts with MS VC. +* [Bug 1946] parse_start uses open; does not work on Windows. +* [Bug 1947] Porting parse-based Wharton refclock driver to Windows. +* [Bug 2024] Remove unused system event code EVNT_CLKHOP. +(4.2.7p219) 2011/10/04 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p218) 2011/10/03 Released by Harlan Stenn +* [Bug 2019] Allow selection of cipher for private key files. +* Documentation updates from Dave Mills. +* ntp-keygen private key cipher default now triple-key triple DES CBC. +* ntp-keygen -M is intended to ignore all other defaults and + options, so do not attempt to open existing Autokey host certificate + before generating symmetric keys and terminating. +* Restore IFF, MV, and GQ identity parameter filename convention to + ntpkey_par_ in ntpd, matching ntp-keygen. +* Change some error logging to syslog to ignore logconfig mask, such + as reporting PPSAPI failure in NMEA and WWVB refclocks. +* ntp-keygen on Windows XP and later systems will now create links + expected by ntpd. They are hardlinks on Windows, soft on POSIX. +* Conditionalize NMEA serial open message under clockevent. +* Send all peer variables to trappers in report_event(). +(4.2.7p217) 2011/09/29 Released by Harlan Stenn +* [Bug 2020] ntp-keygen -s no longer sets host in cert file name. +* [Backward Incompatible] ntp-keygen -i option long name changed from + misleading --issuer-name to --ident. +(4.2.7p216) 2011/09/27 Released by Harlan Stenn +* sntp documentation tag cleanup. +* mdoc2man improvements. +(4.2.7p215) 2011/09/24 Released by Harlan Stenn +* Use patched mdoc2man script, from Eric Feng. +* Sync with ntp-4.2.6p4 (a no-op). +(4.2.7p214) 2011/09/20 Released by Harlan Stenn +* [Bug 1981] Initial offset convergence applies frequency correction 2x + with kernel discipline. +* [Bug 2008] Initial offset convergence degraded with 500 PPM adjtime(). +* [Bug 2009] EVNT_NSET adj_systime() mishandled by Windows ntpd. +(4.2.7p213) 2011/09/08 Released by Harlan Stenn +* [Bug 1999] NMEA does not send PMOTG messages any more. +(4.2.7p212) 2011/09/07 Released by Harlan Stenn +* [Bug 2003] from 4.2.6p4-RC3: ntpq_read_assoc_peervars() broken. +(4.2.7p211) 2011/09/01 Released by Harlan Stenn +* Update libevent to git head (2.1 branch) as of 2.0.14-stable. +(4.2.7p210) 2011/08/31 Released by Harlan Stenn +* Require -D4 or higher for ntpd SIGALRM debug trace from [Bug 2000]. +(4.2.7p209) 2011/08/27 Released by Harlan Stenn +* [Bug 2000] ntpd worker threads must block signals expected in main + thread. +* [Bug 2001] add ntpq -c timerstats like ntpdc -c timerstats. +* [Bug 2001] from 4.2.6p4-RC3: ntpdc timerstats reports overruns as + handled. +* Update sntp tests to track the change of root dispersion to + synchronization distance. +(4.2.7p208) 2011/08/24 Released by Harlan Stenn +* Fix the CLOCK_MONOTONIC TRACE() message. +(4.2.7p207) 2011/08/22 Released by Harlan Stenn +* Restore the original CLOCK_MONOTONIC output format in sntp. +* Cleanups for ntp-wait-opts.def and ntp.keys.def . +(4.2.7p206) 2011/08/20 Released by Harlan Stenn +* [Bug 1993] ntpd Windows port adj_systime() broken in 4.2.7p203. +* sntp documentation and behavior improvements suggested by + Steven Sommars. +* Have sntp report synchronization distance instead of root dispersion. +* Clean up ntp-wait-opts.def . +(4.2.7p205) 2011/08/19 Released by Harlan Stenn +* [Bug 1992] util/tg2 doesn't compile, needs libntp. +(4.2.7p204) 2011/08/16 Released by Harlan Stenn +* Added support for Garmin's $PGRMF sentence to NMEA driver +* [Bug 1988] Better sntp send failed error message needed. +* [Bug 1989] sntp manual page sometimes refers to SNTP as a program. +* [Bug 1990] sntp output should include stratum. +(4.2.7p203) 2011/08/13 Released by Harlan Stenn +* [Bug 1986] Require Visual C++ 2005 or later compilers in Windows port. +* Actually use long long for (u_)int64 by correcting spelling of + SIZEOF_LONG_LONG in ntp_types.h. +* Force .exe minimum Windows version to 0x0400 to allow NT4 in + vs2005/*.vcproj files. +* Fix make distcheck with --enable-libevent-regress problem with + unwritable $srcdir. +* Correct init_logging()'s def_syslogmask type to u_int32 following + change of ntp_syslogmask from u_long to u_int32 in p202. +(4.2.7p202) 2011/08/09 Released by Harlan Stenn +* [Bug 1983] --without-sntp build breaks in sntp subdir. +* [Bug 1984] from 4.2.6p4-RC3: ntp/libisc fails to compile on OS X 10.7. +* [Bug 1985] from 4.2.6p4-RC3: "logconfig =allall" rejected. +(4.2.7p201) 2011/08/05 Released by Harlan Stenn +* sntp: change -h/--headspace to -g/--gap, and change the default gap + from 10 to 50ms +* [Backward Incompatible] from 4.2.6p4: sntp: -l/--filelog -> + -l/--logfile, to be consistent with ntpd. +* Documentation updates from Dave Mills. +* From 4.2.6p4: libopts/file.c fix from Bruce Korb (arg-type=file). +(4.2.7p200) 2011/08/04 Released by Harlan Stenn +* Sync with 4.2.6p4-RC2. +(4.2.7p199) 2011/07/29 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p198) 2011/07/28 Released by Harlan Stenn +* remove old binsubdir stuff from SNTP, as NTP_LOCINFO does that now. +(4.2.7p197) 2011/07/28 Released by Harlan Stenn +* [Bug 1975] from 4.2.6p4-RC2: libntp/mktime.c won't work with 64-bit + time_t +* [Bug 1976] genLocInfo writes to srcdir break 'make distcheck'. +* [Bug 1977] Fix flag/description mismatches in ntp-keygen-opts.def. +* Do not force "legacy" when --with-locfile is not given, genLocInfo + will find the correct default for the system. +* Fix warnings in ntp_request.c ([Bug 1973] oversight) and sntp/main.c + (CID 159, apparent overrun due to union, actually correct). +* Update sntp/loc/solaris to conform to stock locations. +(4.2.7p196) 2011/07/27 Released by Harlan Stenn +* DEFAULT INSTALLATION DIRECTORY CHANGES ON SOME OSes: to get the old + behavior, pass --with-locfile=legacy to 'configure' +* [Bug 1972] from 4.2.6p4-RC2: checking for struct rtattr fails. +* [Bug 1973] Widen reference clock mode from 8 to 32 bits. +* Removed sntp/m4/ntp_bindir.m4 - no longer needed. +* Move loc/ to sntp/loc/ . +* Move scripts/cvo.sh to sntp/scripts/cvo.sh . +* Move scripts/genLocInfo to sntp/scripts/genLocInfo . +* Give NTP_LOCINFO an optional path-to argument. +* Remove hacks to get NTP_LOCINFO-related data to sntp/ . +* Move sntp/include/mansec2subst.sed to sntp/scripts/mansec2subst.sed . +* If no "more specific" loc file is found for redhat* or fedora*, + look for a loc/redhat file. +* If no "more specific" loc file is found and uname says this is Linux, + look for a loc/linux file. +* Improve the help text: --with-locfile=XXX . +* work around solaris /bin/sh issues for genLocInfo. +(4.2.7p195) 2011/07/25 Released by Harlan Stenn +* Added loc/redhat. +(4.2.7p194) 2011/07/25 Released by Harlan Stenn +* [Bug 1608] from 4.2.6p4-RC2: Parse Refclock driver should honor + trusttime. +* Add support for installing programs and scripts to libexec. +* Added loc/solaris. +(4.2.7p193) 2011/07/24 Released by Harlan Stenn +* [Bug 1970] from 4.2.6p4-RC2: UNLINK_EXPR_SLIST() causes crash if list + is empty. +* Update libevent to 2.1 HEAD as of merge of 2.0.13-stable-dev. +* Match addr_eqprefix() sizeof and memcpy destination to make it clear + to static analysis that there is no buffer overrun (CID 402). +(4.2.7p192) 2011/07/18 Released by Harlan Stenn +* [Bug 1966] Broken FILES section for ntp.keys.def. +(4.2.7p191) 2011/07/17 Released by Harlan Stenn +* [Bug 1948] Update man page section layout. +* [Bug 1963] add reset command for ntpq :config, similar to ntpdc's. +* [Bug 1964] --without-sntp should not build sntp. +(4.2.7p190) 2011/07/13 Released by Harlan Stenn +* [Bug 1961] from 4.2.6p4: html2man update: distribute ntp-wait.html. +* Require autogen-5.12. +(4.2.7p189) 2011/07/11 Released by Harlan Stenn +* [Bug 1134] from 4.2.6p4-RC1: ntpd fails binding to tentative IPv6 + addresses. +* [Bug 1790] from 4.2.6p4-RC1: Update config.guess and config.sub to + detect AIX6. +(4.2.7p188) 2011/06/28 Released by Harlan Stenn +* [Bug 1958] genLocInfo must export PATH. +* ntp-wait: some versions of ntpd spell "associd" differently. +(4.2.7p187) 2011/06/24 Released by Harlan Stenn +* [Bug 1954] Fix typos in [s]bin_PROGRAMS in ntpd/Makefile.am. +* Implement --with-locfile=filename configure argument. If filename is + empty we'll look under loc/ for a good fit. If the filename contains + a / character, it will be treated as a "normal" pathname. Otherwise, + that explicit file will be searched for under loc/ . +(4.2.7p186) 2011/06/23 Released by Harlan Stenn +* [Bug 1950] Control installation of event_rpcgen.py. +* Update .point-changed-filelist for the new man pages. +* Update the building of OS-specific programs. +* Finish conversion to genLocInfo. +* validate MANTAGFMT in genLocInfo. +* Documentation update from Dave Mills. +(4.2.7p185) 2011/06/21 Released by Harlan Stenn +* ntp_locs.m4: handle the case where . is not in the PATH. +* More genLocInfo cleanup. +(4.2.7p184) 2011/06/20 Released by Harlan Stenn +* Added ntp_locs.m4. +* genLocInfo improvements. +* Add the man page tag "flavor" to the loc.* files. +* Add/distribute genLocInfo. +(4.2.7p183) 2011/06/19 Released by Harlan Stenn +* Update the autogen include list for scripts/Makefile.am. +* Added loc.freebsd (and distribute it). +* Added loc.legacy (and distribute it). +(4.2.7p182) 2011/06/15 Released by Harlan Stenn +* [Bug 1304] Update sntp.html to reflect new implementation. +* Update .point-changed-filelist . +* ntpdc documentation fixes. +* Update ntp-wait autogen docs. +* Update the ntpd autogen docs. +* Update the ntpsnmpd autogen docs. +* Use autogen to produce ntp-keygen docs. +* Add "license name" to ntp.lic for autogen-5.11.10. +* Prepare for ntp.keys.5. +(4.2.7p181) 2011/06/07 Released by Harlan Stenn +* [Bug 1938] addr_eqprefix() doesn't clear enough storage. +(4.2.7p180) 2011/06/06 Released by Harlan Stenn +* Upgrade to libevent-2.0.12. +* More sntp.1 cleanups. +* Produce ntpq.1 with the new autogen macros. +* Remove the deprecated "detail" stanza from ntpdc-opts.def. +(4.2.7p179) 2011/06/03 Released by Harlan Stenn +* Update cmd-doc.tlib to autogen-5.11.10pre5. +* Upgrade local autoopts templates to 5.11.10pre5. +(4.2.7p178) 2011/06/02 Released by Harlan Stenn +* Update the std_def_list to include the ntp.lic file. +* Distribute the ntp.lic file. +* Add http://ntp.org/license to the ntp.lic file. +(4.2.7p177) 2011/06/01 Released by Harlan Stenn +* Use the latest autogen's new copyright template code. +* Clean up the ntp.lic file. +(4.2.7p176) 2011/05/31 Released by Harlan Stenn +* sntp documentation cleanup. +* autogen documentation template cleanup. +(4.2.7p175) 2011/05/30 Released by Harlan Stenn +* [Bug 1936] Correctly set IPV6_MULTICAST_LOOP. +* cmd-doc.tlib cleanup from Bruce Korb. +* sntp documentation cleanup. +(4.2.7p174) 2011/05/28 Released by Harlan Stenn +* ntpdc documentation cleanup. +* sntp documentation cleanup. +* Don't build libevent with openssl support. Right now, libevent + doesn't use pkg-config to find openssl's installation location. +(4.2.7p173) 2011/05/25 Released by Harlan Stenn +* Typo in emalloc.c hides file and line number from emalloc() error msg. +* parsesolaris.c compile fails on SPARC Solaris with conflicting printf. +* ntp_util.c compile fails on AIX and OSF with conflicting statsdir. +(4.2.7p172) 2011/05/24 Released by Harlan Stenn +* Remove hardcoded 1/960 s. fudge for transmission time at 9600 8n1 + from WWVB/Spectracom driver introduced in 4.2.7p169. +(4.2.7p171) 2011/05/23 Released by Harlan Stenn +* Eliminate warnings about shadowing global "basename" on Linux. +* Use filegen_config() consistently when changing filegen options. +* mprintf() should go to stdout, not stderr. DPRINTF() uses mprintf(). +* Repair a few simulator problems (more remain). +* Documentation updates from Dave Mills. +(4.2.7p170) 2011/05/19 Released by Harlan Stenn +* [Bug 1932] libevent/util_internal.h builtin_expect compile error with + gcc 2.95. +* Use 64-bit scalars in LFPTOD() and DTOLFP() on more platforms by + conditionalizing on HAVE_U_INT64 rather than UINT64_MAX. +(4.2.7p169) 2011/05/18 Released by Harlan Stenn +* [Bug 1933] WWVB/Spectracom driver timestamps LFs, not CRs. +(4.2.7p168) 2011/05/16 Released by Harlan Stenn +* Convert receive buffer queue from doubly-linked list to FIFO. +(4.2.7p167) 2011/05/14 Released by Harlan Stenn +* [Bug 1927] io_closeclock() should purge pending recvbufs. +* [Bug 1931] cv always includes fudgetime1, never fudgetime2. +* Use acts_close() in acts_shutdown() to avoid leaving a stale lockfile + if unpeered via runtime configuration while the modem is open. +* Correct acts_close() test of pp->io.fd to see if it is open. +* 4.2.7p164 documentation updates re: 'tos orphanwait' expanded scope. +(4.2.7p166) 2011/05/13 Released by Harlan Stenn +* If we have local overrides for autogen template files, use them. +* Convert more of the sntp-opt.def documentation from man to mdoc. +(4.2.7p165) 2011/05/11 Released by Harlan Stenn +* Convert snmp docs to mdoc format, which requires autogen 5.11.9. +* from 4.2.6p4-RC1: Require autogen 5.11.9. +(4.2.7p164) 2011/05/11 Released by Harlan Stenn +* [Bug 988] Local clock eats up -g option, so ntpd stops with large + initial time offset. +* [Bug 1921] LOCAL, ACTS drivers with "prefer" excluded from initial + candidate list. +* [Bug 1922] "tos orphanwait" applied incorrectly at startup. +* [Bug 1923] orphan parent favored over LOCAL, ACTS drivers. +* [Bug 1924] Billboard tally codes sometimes do not match operation, + variables. +* Change "pool DNS" messages from msyslog to debug trace output. +* Remove unused FLAG_SYSPEER from peer->status. +* Respect "tos orphanwait" at startup. Previously there was an + unconditional 300 s. startup orphanwait, though other values were + respected for subsequent orphan wait periods after no_sys_peer events. +* Apply "tos orphanwait" (def. 300 seconds) to LOCAL and ACTS reference + clock drivers, in addition to orphan parent operation. LOCAL and ACTS + are not selectable during the orphanwait delay at startup and after + each no_sys_peer event. This prevents a particular form of clock- + hopping, such as using LOCAL briefly at startup before remote peers + are selectable. This fixes the issue reported in [Bug 988]. +* Documentation updates from Dave Mills. +(4.2.7p163) 2011/05/08 Released by Harlan Stenn +* [Bug 1911] missing curly brace in libntp/ntp_rfc2553.c +(4.2.7p162) 2011/05/03 Released by Harlan Stenn +* [Bug 1910] Support the Tristate Ltd. TS-GPSclock-01. +(4.2.7p161) 2011/05/02 Released by Harlan Stenn +* [Bug 1904] 4.2.7p160 Windows build broken (POSIX_SHELL). +* [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent +* Share a single sntp/libevent/build-aux directory between all three + configure scripts. +* Add missing --enable-local-libevent help to top-level configure. +(4.2.7p160) 2011/05/01 Released by Harlan Stenn +* from 4.2.6p4-RC1: Upgrade to libopts 35.0.10 from AutoGen 5.11.9pre8. +* [Bug 1901] Simulator does not set progname. +(4.2.7p159) 2011/04/28 Released by Harlan Stenn +* Fix a couple of unused variable warnings. +* cleanup in timespecops.c / timevalops.c +(4.2.7p158) 2011/04/24 Released by Harlan Stenn +* Update libevent --disable-libevent-regress handling to work when + building libevent using mingw. +(4.2.7p157) 2011/04/21 Released by Harlan Stenn +* [Bug 1890] 4.2.7p156 segfault in duplicate freeaddrinfo(). +(4.2.7p156) 2011/04/19 Released by Harlan Stenn +* [Bug 1851] freeaddrinfo() called after getaddrinfo() fails. +(4.2.7p155) 2011/04/18 Released by Harlan Stenn +* Fix leak in refclock_datum.c start failure path. +(4.2.7p154) 2011/04/17 Released by Harlan Stenn +* [Bug 1887] DNS fails on 4.2.7p153 using threads. +(4.2.7p153) 2011/04/16 Released by Harlan Stenn +* A few more Coverity Scan cleanups. +(4.2.7p152) 2011/04/15 Released by Harlan Stenn +* Update embedded libevent to current 2.1 git HEAD. +(4.2.7p151) 2011/04/14 Released by Harlan Stenn +* Detect vsnprintf() support for "%m" and disable our "%m" expansion. +* Add --enable-c99-sprintf to configure args for -noopenssl variety of + flock-build to avoid regressions in (v)snprintf() replacement. +* More msnprintf() unit tests. +* Coverity Scan error checking fixes. +* Log failure to fetch time from HOPF_P hardware. +* Check HOPF_S sscanf() conversion count before converted values. +(4.2.7p150) 2011/04/13 Released by Harlan Stenn +* Remove never-used, incomplete ports/winnt/ntpd/refclock_trimbledc.[ch] +* On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements (http://www.jhweiss.de/software/snprintf.html) +* Remove remaining sprintf() calls except refclock_ripencc.c (which is + kept out of --enable-all-clocks as a result), upstream libs which use + sprintf() only after careful buffer sizing. +(4.2.7p149) 2011/04/11 Released by Harlan Stenn +* [Bug 1881] describe the {+,-,s} characters in configure --help output. +(4.2.7p148) 2011/04/09 Released by Harlan Stenn +* Use _mkgmtime() as timegm() in the Windows port, rather than + libntp/mktime.c's timegm(). Fixed [Bug 1875] on Windows using the old + asn2ntp() code from before 4.2.7p147. +* ntp_crypto.c string buffer safety. +* Remove use of MAXFILENAME in mode 7 (ntpdc) on-wire structs. +* Change ntpd MAXFILENAME from 128 to 256 to match ntp-keygen. +* Buffer safety and sign extension fixes (thanks Coverity Scan). +(4.2.7p147) 2011/04/07 Released by Harlan Stenn +* [Bug 1875] 'asn2ntp()' rewritten with 'caltontp()'; 'timegm()' + substitute likely to crash with 64bit time_t. +(4.2.7p146) 2011/04/05 Released by Harlan Stenn +* String buffer safety cleanup, converting to strlcpy() and strlcat(). +* Use utmpname() before pututline() so repeated steps do not + accidentally record into wtmp where utmp was intended. +* Use setutent() before each pututline() including first. +(4.2.7p145) 2011/04/04 Released by Harlan Stenn +* [Bug 1840] ntp_lists.h FIFO macros buggy. +(4.2.7p144) 2011/04/03 Released by Harlan Stenn +* [Bug 1874] ntpq -c "rv 0 sys_var_list" empty. +(4.2.7p143) 2011/03/31 Released by Harlan Stenn +* [Bug 1732] ntpd ties up CPU on disconnected USB refclock. +* [Bug 1861] tickadj build failure using uClibc. +* [Bug 1862] in6addr_any test in configure fooled by arm gcc 4.1.3 -O2. +* Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. +* Remove "signal_no_reset: signal 17 had flags 4000000" logging, as it + indicates no problem and is interpreted as an error. Previously some + bits had been ignored one-by-one, but Linux SA_RESTORER definition is + unavailable to user headers. +(4.2.7p142) 2011/03/21 Released by Harlan Stenn +* [Bug 1844] ntpd 4.2.7p131 NetBSD, --gc-sections links bad executable. +* Fix "make distcheck" break in libevent/sample caused by typo. +(4.2.7p141) 2011/03/20 Released by Harlan Stenn +* Add "ntpq -c iostats" similar to "ntpdc -c iostats". +* Compare entire timestamp to reject duplicates in refclock_pps(). +(4.2.7p140) 2011/03/17 Released by Harlan Stenn +* [Bug 1848] ntpd 4.2.7p139 --disable-thread-support does not compile. +* Add --disable-thread-support to one flock-build variation. +* One more lock-while-init in lib/isc/task.c to quiet lock analysis. +(4.2.7p139) 2011/03/16 Released by Harlan Stenn +* [Bug 1848] make check ntpd --saveconfigquit clutters syslog. +(4.2.7p138) 2011/03/08 Released by Harlan Stenn +* [Bug 1846] MacOSX: debug symbol not found by propdelay or tickadj. +(4.2.7p137) 2011/03/07 Released by Harlan Stenn +* Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. +* Declare debug in libntp instead of each program. Expose extern + declaration to utilities, libntp, and DEBUG ntpd. +* Lock under-construction task, taskmgr objects to satisfy Coverity's + mostly-correct assumptions about which variables are protected by + which locks. +(4.2.7p136) 2011/03/02 Released by Harlan Stenn +* [Bug 1839] 4.2.7p135 still installs libevent ev*.h headers. +(4.2.7p135) 2011/03/02 Released by Harlan Stenn +* libevent: When building on systems with CLOCK_MONOTONIC available, + separate the internal timeline (possibly counting since system boot) + from the gettimeofday() timeline in event_base cached timevals. Adds + new event_base_tv_cached() to retrieve cached callback round start + time on the internal timeline, and changes + event_based_gettimeofday_cached() to always return times using the + namesake timeline. This preserves the benefit of using the never- + stepped monotonic clock for event timeouts while providing clients + with times consistently using gettimeofday(). +* Correct event_base_gettimeofday_cached() workaround code in + sntp to work with corrected libevent. +* Remove sntp l_fp_output() test now that it uses prettydate(). +* [Bug 1839] 4.2.7p131 installs libevent ev*.h headers. +* Ensure CONFIG_SHELL is not empty before relying on it for #! scripts. +(4.2.7p134) 2011/02/24 Released by Harlan Stenn +* [Bug 1837] Build fails on Win7 due to regedit requiring privilege. +* Provide fallback definitions for GetAdaptersAddresses() for Windows + build environments lacking iphlpapi.h. +* Rename file containing 1.xxxx ChangeSet revision from version to + scm-rev to avoid invoking GNU make implicit rules attempting to + compile version.c into version. Problem was with sntp/version.o + during make distcheck after fix for spurious sntp rebuilds. +* Add INC_ALIGNED_PTR() macro to align pointers like malloc(). +(4.2.7p133) 2011/02/23 Released by Harlan Stenn +* [Bug 1834] ntpdate 4.2.7p131 aborts with assertion failure. +* Move sntp last in top-level Makefile.am SUBDIRS so that the libevent + tearoff (if required) and sntp are compiled after the rest. +* Use a single set of Automake options for each package in configure.ac + AM_INIT, remove Makefile.am AUTOMAKE_OPTIONS= lines. +* Correct spurious sntp rebuilds triggered by a make misperception + sntp/version was out-of-date relative to phony target FRC.version. +* Do not cache paths to perl, test, or pkg-config, searching the PATH + at configure time is worth it to pick up tool updates. +(4.2.7p132) 2011/02/22 Released by Harlan Stenn +* [Bug 1832] ntpdate doesn't allow timeout > 2s. +* [Bug 1833] The checking sem_timedwait() fails without -pthread. +* ElectricFence was suffering bitrot - remove it. valgrind works well. +* Enable all relevant automake warnings. +* Correct Solaris 2.1x PTHREAD_ONCE_INIT extra braces test to avoid + triggering warnings due to excess braces. +* Remove libevent-cfg from sntp/Makefile.am. +* Provide bug report and URL options to Autoconf. +* Avoid relying on remake rules for routine build/flock-build for + libevent as for the top-level and sntp subproject. +(4.2.7p131) 2011/02/21 Released by Harlan Stenn +* [Bug 1087] -v/--normalverbose conflicts with -v/--version in sntp. +* [Bug 1088] sntp should (only) report the time difference without -s/-a. +* older autoconf sometimes dislikes []. +* Move "can't write KoD file" warning from sntp shutdown to startup. +* refclock_acts.c cleanup from Dave Mills. +* Convert sntp to libevent event-driven socket programming. Instead of + blocking name resolution and querying one NTP server at a time, + resolve server names and send NTP queries without blocking. Add + sntp command-line options to adjust timing and optionally wait for all + servers to respond instead of exiting after the first. +* Import libevent 2.0.10-stable plus local patches as a tearoff, used + only if the target system lacks an installed libevent 2.0.9 or later. +* Move blocking worker and resolver to libntp from ntpd. +* Use threads rather than forked child processes for blocking worker + when possible. Override with configure --disable-thread-support. +* Move init_logging(), change_logfile(), and setup_logfile() from ntpd + to libntp, use them in sntp. +* Test --without-sntp in flock-build script's -no-refclocks variety. +* Avoid invoking config.status twice in a row in build script. +* Move more m4sh tests needed by libntp to shared .m4 files. +* Split up ntp_libntp.m4 into smaller, more specific subsets. +* Enable gcc -Wcast-align, fix many instances of warnings when casting + a pointer to a more-strictly-aligned underlying type. +(4.2.7p130) 2011/02/12 Released by Harlan Stenn +* [Bug 1811] Update the download location in WHERE-TO-START. +(4.2.7p129) 2011/02/09 Released by Harlan Stenn +* Add missing "break;" to ntp_control.c ctl_putsys() for caliberrs, used + by ntpq -c kerninfo introduced in 4.2.7p104. +* Fix leak in ntp_control.c read_mru_list(). +(4.2.7p128) 2011/01/30 Released by Harlan Stenn +* [Bug 1799] ntpq mrv crash. +* [Bug 1801] ntpq mreadvar requires prior association caching. +(4.2.7p127) 2011/01/28 Released by Harlan Stenn +* [Bug 1797] Restore stale timestamp check from the RANGEGATE cleanup. +(4.2.7p126) 2011/01/27 Released by Harlan Stenn +* Fix unexposed fencepost error in format_time_fraction(). +* Add more unit tests for timeval_tostr() and timespec_tostr(). +(4.2.7p125) 2011/01/26 Released by Harlan Stenn +* [Bug 1794] ntpq -c rv missing clk_wander information. +* [Bug 1795] ntpq readvar does not display last variable. +(4.2.7p124) 2011/01/25 Released by Harlan Stenn +* sntp/Makefile.am needs any passed-in CFLAGS. +(4.2.7p123) 2011/01/24 Released by Harlan Stenn +* [Bug 1788] tvtots.c tables inaccurate +(4.2.7p122) 2011/01/22 Released by Harlan Stenn +* ACTS refclock cleanup from Dave Mills. +* Avoid shadowing the "group" global variable. +(4.2.7p121) 2011/01/21 Released by Harlan Stenn +* [Bug 1786] Remove extra semicolon from ntp_proto.c . +(4.2.7p120) 2011/01/20 Released by Harlan Stenn +* Change new timeval and timespec to string routines to use snprintf() + rather than hand-crafted conversion, avoid signed int overflow there. +* Add configure support for SIZEOF_LONG_LONG to enable portable use of + snprintf() with time_t. +* Grow ntpd/work_thread.c arrays as needed. +* Add DEBUG_* variants of ntp_assert.h macros which compile away using + ./configure --disable-debugging. +* Fix tvalops.cpp unit test failures for 32-bit builds. +* Return to a single autoreconf invocation in ./bootstrap script. +* Fix warnings seen on FreeBSD 9. +* crypto group changes from Dave Mills. +* Lose the RANGEGATE check in PPS, from Dave Mills. +* ACTS refclock cleanup from Dave Mills. +* Documentation updates from Dave Mills. +* NMEA driver documentation update from Juergen Perlinger. +(4.2.7p119) 2011/01/18 Released by Harlan Stenn +* added timespecops.{c,h} and tievalops.{c.h} to libntp and include + added tspecops.cpp to tests/libntp +* Correct msyslog.c build break on Solaris 2.9 from #ifdef/#if mixup. +(4.2.7p118) 2011/01/15 Released by Harlan Stenn +* Simplify the built-sources stuff in sntp/ . +* Fix check for -lipv6 on HP-UX 11. +(4.2.7p117) 2011/01/13 Released by Harlan Stenn +* Add configure --without-sntp option to disable building sntp and + sntp/tests. withsntp=no in the environment changes the default. +* Build infrastructure cleanup: + Move m4 directory to sntp/m4. + Share a single set of genver output between sntp and the top level. + Share a single set of autogen included .defs in sntp/include. + Share a single set of build-aux scripts (e.g. config.guess, missing). + Add ntp_libntp.m4 and ntp_ipv6.m4 to reduce configure.ac duplication. + Warn and exit build/flock-build if bootstrap needs to be run. +(4.2.7p116) 2011/01/10 Released by Harlan Stenn +* refclock_nmea.c refactoring by Juergen Perlinger. +(4.2.7p115) 2011/01/09 Released by Harlan Stenn +* [Bug 1780] Windows ntpd 4.2.7p114 crashes in ioctl(). +* [Bug 1781] longlong undefined in sntp handle_pkt() on Debian amd64. +(4.2.7p114) 2011/01/08 Released by Harlan Stenn +* Fix for openssl pkg-config detection eval failure. +* Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. +(4.2.7p113) 2011/01/07 Released by Harlan Stenn +* [Bug 1776] sntp mishandles -t/--timeout and -a/--authentication. +* Default to silent make rules, override with make V=1 or ./configure + --disable-silent-rules. +* Correct --with-openssl-incdir defaulting with pkg-config. +* Correct ./build on systems without gtest available. +* Begin moving some of the low-level socket stuff to libntp. +(4.2.7p112) 2011/01/06 Released by Harlan Stenn +* [Bug 1773] openssl not detected during ./configure. +* [Bug 1774] Segfaults if cryptostats enabled and built without OpenSSL. +* Use make V=0 in build script to increase signal/noise ratio. +(4.2.7p111) 2011/01/05 Released by Harlan Stenn +* [Bug 1772] refclock_open() return value check wrong for ACTS. +* Default --with-openssl-libdir and --with-openssl-incdir to the values + from pkg-config, falling back on our usual search paths if pkg-config + is not available or does not have openssl.pc on PKG_CONFIG_PATH. +* Change refclock_open() to return -1 on failure like open(). +* Update all refclock_open() callers to check for fd <= 0 indicating + failure, so they work with older and newer refclock_open() and can + easily backport. +* Initialize refclockproc.rio.fd to -1, harmonize refclock shutdown + entrypoints to avoid crashing, particularly if refclock_open() fails. +* Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. +(4.2.7p110) 2011/01/04 Released by Harlan Stenn +* [Bug 1771] algorithmic error in 'clocktime()' fixed. +* Unit tests extended for hard-coded system time. +* make V=0 and configure --enable-silent-rules supported. +* setvar modemsetup = ATE0... overrides ACTS driver default. +* Preserve last timecode in ACTS driver (ntpq -ccv). +* Tolerate previous ATE1 state when sending ACTS setup. +* Enable raw tty line discipline in Windows port. +* Allow tty open/close/open to succeed on Windows port. +* Enable ACTS and CHU reference clock drivers on Windows. +(4.2.7p109) 2011/01/02 Released by Harlan Stenn +* Remove nearly all strcpy() and most strcat() from NTP distribution. + One major pocket remains in ntp_crypto.c. libopts & libisc also have + (safe) uses of strcpy() and strcat() remaining. +* Documentation updates from Dave Mills. +(4.2.7p108) 2011/01/01 Released by Harlan Stenn +* [Bug 1764] Move Palisade modem control logic to configure.ac. +* [Bug 1768] TIOCFLUSH undefined in linux for refclock_acts. +* Autokey multiple identity group improvements from Dave Mills. +* from 4.2.6p3: Update the copyright year. +(4.2.7p107) 2010/12/31 Released by Harlan Stenn +* [Bug 1764] Palisade driver doesn't build on Linux. +* [Bug 1766] Oncore clock has offset/high jitter at startup. +* Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. +* refclock_acts.c updates from Dave Mills. +(4.2.7p106) 2010/12/30 Released by Harlan Stenn +* from 4.2.6p3: Update genCommitLog for the bk-5 release. +(4.2.7p105) 2010/12/29 Released by Harlan Stenn +(4.2.7p104) 2010/12/28 Released by Harlan Stenn +* from 4.2.6p3: Create and use scripts/check--help when generating + .texi files. +* from 4.2.6p3: Update bk triggers for the bk-5 release. +* Support for multiple Autokey identity groups from Dave Mills. +* Documentation updates from Dave Mills. +* Add ntpq kerninfo, authinfo, and sysinfo commands similar to ntpdc's. +(4.2.7p103) 2010/12/24 Released by Harlan Stenn +* Add ntpq pstats command similar to ntpdc's. +* Remove ntpq pstatus command, rv/readvar does the same and more. +* Documentation updates from Dave Mills. +(4.2.7p102) 2010/12/23 Released by Harlan Stenn +* Allow ntpq &1 associd use without preceding association-fetching. +* Documentation updates from Dave Mills. +(4.2.7p101) 2010/12/22 Released by Harlan Stenn +* from 4.2.6p3-RC12: Upgrade to libopts 34.0.9 from AutoGen 5.11.6pre7. +* from 4.2.6p3-RC12: Relax minimum Automake version to 1.10 with updated + libopts.m4. +(4.2.7p100) 2010/12/21 Released by Harlan Stenn +* [Bug 1743] from 4.2.6p3-RC12: Display timezone offset when showing + time for sntp in the local timezone (documentation updates). +(4.2.7p99) 2010/12/21 Released by Harlan Stenn +* Add unit tests for msnprintf(). +(4.2.7p98) 2010/12/20 Released by Harlan Stenn +* [Bug 1761] clockstuff/clktest-opts.h omitted from tarball. +* [Bug 1762] from 4.2.6p3-RC12: manycastclient responses interfere. +* Documentation updates from Dave Mills. +(4.2.7p97) 2010/12/19 Released by Harlan Stenn +* [Bug 1458] from 4.2.6p3-RC12: Can not compile NTP on FreeBSD 4.7. +* [Bug 1760] from 4.2.6p3-RC12: ntpd Windows interpolation cannot be + disabled. +* from 4.2.6p3-RC12: Upgrade to libopts 34.0.9 from AutoGen 5.11.6pre5. +* Documentation updates from Dave Mills. +(4.2.7p96) 2010/12/18 Released by Harlan Stenn +* [Bug 1758] from 4.2.6p3-RC12: setsockopt IPV6_MULTICAST_IF with wrong + ifindex. +* Documentation updates from Dave Mills. +(4.2.7p95) 2010/12/17 Released by Harlan Stenn +* [Bug 1753] 4.2.7p94 faults on startup in newpeer(), strdup(NULL). +* [Bug 1754] from 4.2.6p3-RC12: --version output should be more verbose. +* [Bug 1757] from 4.2.6p3-RC12: oncore snprintf("%m") doesn't expand %m. +* from 4.2.6p3-RC12: Suppress ntp-keygen OpenSSL version display for + --help, --version, display both build and runtime OpenSSL versions + when they differ. +* from 4.2.6p3-RC12: Upgrade to libopts 33.5.8 from AutoGen 5.11.6pre3. +* Documentation updates from Dave Mills. +(4.2.7p94) 2010/12/15 Released by Harlan Stenn +* [Bug 1751] from 4.2.6p3-RC12: Support for Atari FreeMiNT OS. +* Documentation updates from Dave Mills. +(4.2.7p93) 2010/12/13 Released by Harlan Stenn +* [Bug 1510] from 4.2.6p3-RC12: Add modes 20/21 for driver 8 to support + RAWDCF @ 75 baud. +* [Bug 1741] from 4.2.6p3-RC12: Enable multicast reception on each + address (Windows). +* from 4.2.6p3-RC12: Other manycastclient repairs: + Separate handling of scope ID embedded in many in6_addr from ifindex + used for IPv6 multicasting ioctls. + Add INT_PRIVACY endpt bit flag for IPv6 RFC 4941 privacy addresses. + Enable outbound multicast from only one address per interface in the + same subnet, and in that case prefer embedded MAC address modified + EUI-64 IPv6 addresses first, then static, and last RFC 4941 privacy + addresses. + Use setsockopt(IP[V6]_MULTICAST_IF) before each send to multicast to + select the local source address, using the correct socket is not + enough. +* "server ... ident " changes from Dave Mills. +* Documentation updates from Dave Mills. +(4.2.7p92) 2010/12/08 Released by Harlan Stenn +* [Bug 1743] from 4.2.6p3-RC12: Display timezone offset when showing + time for sntp in the local timezone. +(4.2.7p91) 2010/12/07 Released by Harlan Stenn +* [Bug 1732] ntpd ties up CPU on disconnected USB device. +* [Bug 1742] form 4.2.6p3-RC12: Fix a typo in an error message in the + "build" script. +(4.2.7p90) 2010/12/06 Released by Harlan Stenn +* [Bug 1738] Windows ntpd has wrong net adapter name. +* [Bug 1740] ntpdc -c reslist packet count wrongly treated as signed. +(4.2.7p89) 2010/12/04 Released by Harlan Stenn +* [Bug 1736] tos int, bool options broken in 4.2.7p66. +* from 4.2.6p3-RC12: Clean up the SNTP documentation. +(4.2.7p88) 2010/12/02 Released by Harlan Stenn +* [Bug 1735] 'clocktime()' aborts ntpd on bogus input +(4.2.7p87) 2010/12/01 Released by Harlan Stenn +* from 4.2.6p3-RC12: Clean up m4 quoting in configure.ac, *.m4 files, + resolving intermittent AC_LANG_PROGRAM possibly undefined errors. +(4.2.7p86) 2010/11/29 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p85) 2010/11/24 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p84) 2010/11/22 Released by Harlan Stenn +* [Bug 1618] Unreachable code in jjy_start(). +* [Bug 1725] from 4.2.6p3-RC11: ntpd sends multicast from only one + address. +* from 4.2.6p3-RC11: Upgrade libopts to 33.3.8. +* from 4.2.6p3-RC11: Bump minimum Automake version to 1.11, required for + AM_COND_IF use in LIBOPTS_CHECK. +* An almost complete rebuild of the initial loopfilter configuration + process, including the code that determines the interval between + frequency file updates, from Dave Mills. +* Documentation updates from Dave Mills. +* Add ntp-keygen -l/--lifetime to control certificate expiry. +* JJY driver improvements for Tristate JJY01/02, including changes + to its clockstats format. +* Add "nonvolatile" ntp.conf directive to control how often the + driftfile is written. +(4.2.7p83) 2010/11/17 Released by Harlan Stenn +* [Bug 1727] ntp-keygen PLEN, ILEN undeclared --without-crypto. +* Remove top-level libopts, use sntp/libopts. +* from 4.2.6p3-RC11: Remove log_msg() and debug_msg() from sntp in favor + of msyslog(). +* Documentation updates from Dave Mills. +(4.2.7p82) 2010/11/16 Released by Harlan Stenn +* [Bug 1728] from 4.2.6p3-RC11: In ntp_openssl.m4, don't add + -I/usr/include or -L/usr/lib to CPPFLAGS or LDFLAGS. +(4.2.7p81) 2010/11/14 Released by Harlan Stenn +* [Bug 1681] from 4.2.6p3-RC10: More sntp logging cleanup. +* [Bug 1683] from 4.2.6p3-RC10: Non-localhost on loopback exempted from + nic rules. +* [Bug 1719] Cleanup for ntp-keygen and fix -V crash, from Dave Mills. +(4.2.7p80) 2010/11/10 Released by Harlan Stenn +* [Bug 1574] from 4.2.6p3-RC9: sntp doesn't set tv_usec correctly. +* [Bug 1681] from 4.2.6p3-RC9: sntp logging cleanup. +* [Bug 1683] from 4.2.6p3-RC9: Interface binding does not seem to work + as intended. +* [Bug 1708] make check fails with googletest 1.4.0. +* [Bug 1709] from 4.2.6p3-RC9: ntpdate ignores replies with equal + receive and transmit timestamps. +* [Bug 1715] sntp utilitiesTest.IPv6Address failed. +* [Bug 1718] Improve gtest checks in configure.ac. +(4.2.7p79) 2010/11/07 Released by Harlan Stenn +* Correct frequency estimate with no drift file, from David Mills. +(4.2.7p78) 2010/11/04 Released by Harlan Stenn +* [Bug 1697] filegen implementation should be improved. +* Refactor calendar functions in terms of new common code. +* Documentation updates from Dave Mills. +(4.2.7p77) 2010/11/03 Released by Harlan Stenn +* [Bug 1692] packageinfo.sh needs to be "sourced" using ./ . +* [Bug 1695] ntpdate takes longer than necessary. +(4.2.7p76) 2010/11/02 Released by Harlan Stenn +* [Bug 1690] Unit tests fails to build on some systems. +* [Bug 1691] Use first NMEA sentence each second. +* Put the sntp tests under sntp/ . +* ... and only build/run them if we have gtest. +* Documentation updates from Dave Mills. +(4.2.7p75) 2010/10/30 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Include Linus Karlsson's GSoC 2010 testing code. +(4.2.7p74) 2010/10/29 Released by Harlan Stenn +* [Bug 1685] from 4.2.6p3-RC8: NMEA driver mode byte confusion. +* from 4.2.6p3-RC8: First cut at using scripts/checkChangeLog. +* Documentation updates from Dave Mills. +(4.2.7p73) 2010/10/27 Released by Harlan Stenn +* [Bug 1680] Fix alignment of clock_select() arrays. +* refinements to new startup behavior from David Mills. +* For the bootstrap script, touch .html files last. +* Add 'make check' test case that would have caught [Bug 1678]. +(4.2.7p72) 2010/10/26 Released by Harlan Stenn +* [Bug 1679] Fix test for -lsocket. +* Clean up missing ;; entries in configure.ac. +(4.2.7p71) 2010/10/25 Released by Harlan Stenn +* [Bug 1676] from 4.2.6p3-RC7: NMEA: $GPGLL did not work after fix + for Bug 1571. +* [Bug 1678] "restrict source" treated as "restrict default". +* from 4.2.6p3-RC7: Added scripts/checkChangeLog. +(4.2.7p70) 2010/10/24 Released by Harlan Stenn +* [Bug 1571] from 4.2.6p3-RC6: NMEA does not relate data to PPS edge. +* [Bug 1572] from 4.2.p63-RC6: NMEA time adjustment for GPZDG buggy. +* [Bug 1675] from 4.2.6p3-RC6: Prohibit includefile remote config. +* Enable generating ntpd/ntp_keyword.h after keyword-gen.c changes on + Windows as well as POSIX platforms. +* Fix from Dave Mills for a rare singularity in clock_combine(). +(4.2.7p69) 2010/10/23 Released by Harlan Stenn +* [Bug 1671] Automatic delay calibration is sometimes inaccurate. +(4.2.7p68) 2010/10/22 Released by Harlan Stenn +* [Bug 1669] from 4.2.6p3-RC5: NTP fails to compile on IBM AIX 5.3. +* [Bug 1670] Fix peer->bias and broadcastdelay. +* Documentation updates from Dave Mills. +* Documentation EOL cleanup. +(4.2.7p67) 2010/10/21 Released by Harlan Stenn +* [Bug 1649] from 4.2.6p3-RC5: Require NMEA checksum if $GPRMC or + previously seen. +(4.2.7p66) 2010/10/19 Released by Harlan Stenn +* [Bug 1277] Provide and use O(1) FIFOs, esp. in the config tree code. +* Remove unused 'bias' configuration keyword. +(4.2.7p65) 2010/10/16 Released by Harlan Stenn +* [Bug 1584] from 4.2.6p3-RC4: wrong SNMP type for precision, + resolution. +* Remove 'calldelay' and 'sign' remnants from parser, ntp_config.c. +(4.2.7p64) 2010/10/15 Released by Harlan Stenn +* [Bug 1584] from 4.2.6p3-RC3: ntpsnmpd OID must be mib-2.197. +* [Bug 1659] from 4.2.6p3-RC4: Need CLOCK_TRUETIME not CLOCK_TRUE. +* [Bug 1663] ntpdsim should not open net sockets. +* [Bug 1665] from 4.2.6p3-RC4: is_anycast() u_int32_t should be u_int32. +* from 4.2.6p3: ntpsnmpd, libntpq warning cleanup. +* Remove 'calldelay' and 'sign' keywords (Dave Mills). +* Documentation updates from Dave Mills. +(4.2.7p63) 2010/10/13 Released by Harlan Stenn +* [Bug 1080] from 4.2.6p3-RC3: ntpd on ipv6 routers very chatty. +* Documentation nit cleanup. +* Documentation updates from Dave Mills. +(4.2.7p62) 2010/10/12 Released by Harlan Stenn +* [Bug 750] from 4.2.6p3-RC3: Non-existing device causes coredump with + RIPE-NCC driver. +* [Bug 1567] from 4.2.6p3-RC3: Support Arbiter 1093C Satellite Clock on + Windows. +* [Bug 1581] from 4.2.6p3-RC3: printf format string mismatch leftover. +* [Bug 1659] from 4.2.6p3-RC3: Support Truetime Satellite Clocks on + Windows. +* [Bug 1660] from 4.2.6p3-RC3: On some systems, test is in /usr/bin, not + /bin. +* [Bug 1661] from 4.2.6p3-RC3: Re-indent refclock_ripencc.c. +* Lose peer_count from ntp_peer.c and ntp_proto.c (Dave Mills). +* Documentation updates from Dave Mills. +(4.2.7p61) 2010/10/06 Released by Harlan Stenn +* Documentation and code cleanup from Dave Mills. No more NTP_MAXASSOC. +(4.2.7p60) 2010/10/04 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p59) 2010/10/02 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Variable name cleanup from Dave Mills. +* [Bug 1657] darwin needs res_9_init, not res_init. +(4.2.7p58) 2010/09/30 Released by Harlan Stenn +* Clock select bugfix from Dave Mills. +* [Bug 1554] peer may stay selected as system peer after becoming + unreachable. +* [Bug 1644] from 4.2.6p3-RC3: cvo.sh should use lsb_release to identify + linux distros. +* [Bug 1646] ntpd crashes with relative path to logfile. +(4.2.7p57) 2010/09/27 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p56) 2010/09/25 Released by Harlan Stenn +* Clock combining algorithm improvements from Dave Mills. +* Documentation updates from Dave Mills. +* [Bug 1642] ntpdsim can't find simulate block in config file. +* [Bug 1643] from 4.2.6p3-RC3: Range-check the decoding of the RIPE-NCC + status codes. +(4.2.7p55) 2010/09/22 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* [Bug 1636] from 4.2.6p3-RC2: segfault after denied remote config. +(4.2.7p54) 2010/09/21 Released by Harlan Stenn +* More Initial convergence improvements from Dave Mills. +* Documentation updates from Dave Mills. +* [Bug 1635] from 4.2.6p3-RC2: "filegen ... enable" is not default. +(4.2.7p53) 2010/09/20 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* More Initial convergence improvements from Dave Mills. +(4.2.7p52) 2010/09/19 Released by Harlan Stenn +* Initial convergence improvements from Dave Mills. +(4.2.7p51) 2010/09/18 Released by Harlan Stenn +* [Bug 1344] from 4.2.6p3-RC1: ntpd on Windows exits without logging + cause. +* [Bug 1629] 4.2.7p50 configure.ac changes invalidate config.cache. +* [Bug 1630] 4.2.7p50 cannot bootstrap on Autoconf 2.61. +(4.2.7p50) 2010/09/16 Released by Harlan Stenn +* Cleanup NTP_LIB_M. +* [Bug 1628] Clean up -lxnet/-lsocket usage for (open)solaris. +(4.2.7p49) 2010/09/13 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p48) 2010/09/12 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.7p47) 2010/09/11 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* [Bug 1588] finish configure --disable-autokey implementation. +* [Bug 1616] refclock_acts.c: if (pp->leap == 2) is always false. +* [Bug 1620] [Backward Incompatible] "discard minimum" value should be in + seconds, not log2 seconds. +(4.2.7p46) 2010/09/10 Released by Harlan Stenn +* Use AC_SEARCH_LIBS instead of AC_CHECK_LIB for NTP_LIB_M. +(4.2.7p45) 2010/09/05 Released by Harlan Stenn +* [Bug 1578] Consistently use -lm when needed. +(4.2.7p44) 2010/08/27 Released by Harlan Stenn +* [Bug 1573] from 4.2.6p3-beta1: Miscalculation of offset in sntp. +(4.2.7p43) 2010/08/26 Released by Harlan Stenn +* [Bug 1602] Refactor some of the sntp/ directory to facililtate testing. +(4.2.7p42) 2010/08/18 Released by Harlan Stenn +* [Bug 1593] ntpd abort in free() with logconfig syntax error. +* [Bug 1595] from 4.2.6p3-beta1: empty last line in key file causes + duplicate key to be added +* [Bug 1597] from 4.2.6p3-beta1: packet processing ignores RATE KoD packets, + Because of a bug in string comparison. +(4.2.7p41) 2010/07/28 Released by Harlan Stenn +* [Bug 1581] from 4.2.6p3-beta1: ntp_intres.c size_t printf format + string mismatch. +* [Bug 1586] ntpd 4.2.7p40 doesn't write to syslog after fork on QNX. +* Avoid race with parallel builds using same source directory in + scripts/genver by using build directory for temporary files. +* orphanwait documentation updates. +(4.2.7p40) 2010/07/12 Released by Harlan Stenn +* [Bug 1395] ease ntpdate elimination with ntpd -w/--wait-sync +* [Bug 1396] allow servers on ntpd command line like ntpdate +(4.2.7p39) 2010/07/09 Released by Harlan Stenn +* Fix typo in driver28.html. +* [Bug 1581] from 4.2.6p2: size_t printf format string mismatches, IRIG + string buffers undersized. Mostly backported from earlier ntp-dev + fixes by Juergen Perlinger. +(4.2.7p38) 2010/06/20 Released by Harlan Stenn +* [Bug 1570] backported to 4.2.6p2-RC7. +* [Bug 1575] from 4.2.6p2-RC7: use 'snprintf' with LIB_BUFLENGTH in + inttoa.c, tvtoa.c and utvtoa.c +* [Bug 1576] backported to 4.2.6p2-RC7. +* Typo fix in a comment in ntp_proto.c. +(4.2.7p37) 2010/06/19 Released by Harlan Stenn +* [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD. +(4.2.7p36) 2010/06/15 Released by Harlan Stenn +* [Bug 1560] Initial support for orphanwait, from Dave Mills. +* clock_filter()/reachability fixes from Dave Mills. +(4.2.7p35) 2010/06/12 Released by Harlan Stenn +* Rewrite of multiprecision macros in 'ntp_fp.h' from J. Perlinger + +* [Bug 715] from 4.2.6p2-RC6: libisc Linux IPv6 interface iteration + drops multicast flags. +(4.2.7p34) 2010/06/05 Released by Harlan Stenn +* [Bug 1570] serial clock drivers get outdated input from kernel tty + line buffer after startup +(4.2.7p33) 2010/06/04 Released by Harlan Stenn +* [Bug 1561] from 4.2.6p2-RC5: ntpq, ntpdc "passwd" prompts for MD5 + password w/SHA1. +* [Bug 1565] from 4.2.6p2-RC5: sntp/crypto.c compile fails on MacOS over + vsnprintf(). +* from 4.2.6p2-RC5: Windows port: do not exit in + ntp_timestamp_from_counter() without first logging the reason. +(4.2.7p32) 2010/05/19 Released by Harlan Stenn +* Copyright file cleanup from Dave Mills. +* [Bug 1555] from 4.2.6p2-RC4: sntp illegal C (mixed code and + declarations). +* [Bug 1558] pool prototype associations have 0.0.0.0 for remote addr. +* configure.ac: add --disable-autokey, #define AUTOKEY to enable future + support for building without Autokey, but with OpenSSL for its digest + algorithms (hash functions). Code must be modified to use #ifdef + AUTOKEY instead of #ifdef OPENSSL where appropriate to complete this. +* include/ntp_crypto.h: make assumption AUTOKEY implies OPENSSL explicit. +(4.2.7p31) 2010/05/11 Released by Harlan Stenn +* [Bug 1325] from 4.2.6p2-RC3: unreachable code sntp recv_bcst_data(). +* [Bug 1459] from 4.2.6p2-RC3: sntp MD5 authentication does not work + with ntpd. +* [Bug 1552] from 4.2.6p2-RC3: update and complete broadcast and crypto + features in sntp. +* [Bug 1553] from 4.2.6p2-RC3: sntp/configure.ac OpenSSL support. +* from 4.2.6p2-RC3: Escape unprintable characters in a refid in ntpq -p + billboard. +* from 4.2.6p2-RC3: Simplify hash client code by providing OpenSSL + EVP_*() API when built without OpenSSL. (already in 4.2.7) +* from 4.2.6p2-RC3: Do not depend on ASCII in sntp. +(4.2.7p30) 2010/05/06 Released by Harlan Stenn +* [Bug 1526] ntpd DNS pipe read EINTR with no network at startup. +* Update the ChangeLog entries when merging items from -stable. +(4.2.7p29) 2010/05/04 Released by Harlan Stenn +* [Bug 1542] ntpd mrulist response may have incorrect last.older. +* [Bug 1543] ntpq mrulist must refresh nonce when retrying. +* [Bug 1544] ntpq mrulist sscanf timestamp format mismatch on 64-bit. +* Windows compiling hints/winnt.html update from G. Sunil Tej. +(4.2.7p28) 2010/05/03 Released by Harlan Stenn +* [Bug 1512] from 4.2.6p2-RC3: ntpsnmpd should connect to net-snmpd + via a unix-domain socket by default. + Provide a command-line 'socket name' option. +* [Bug 1538] from 4.2.6p2-RC3: update refclock_nmea.c's call to + getprotobyname(). +* [Bug 1541] from 4.2.6p2-RC3: Fix wrong keyword for "maxclock". +(4.2.7p27) 2010/04/27 Released by Harlan Stenn +(4.2.7p26) 2010/04/24 Released by Harlan Stenn +* [Bug 1465] from 4.2.6p2-RC2: Make sure time from TS2100 is not + invalid (backport from -dev). +* [Bug 1528] from 4.2.6p2-RC2: Fix EDITLINE_LIBS link order for ntpq + and ntpdc. +* [Bug 1531] Require nonce with mrulist requests. +* [Bug 1532] Remove ntpd support for ntpdc's monlist in favor of ntpq's + mrulist. +* [Bug 1534] from 4.2.6p2-RC2: conflicts with VC++ 2010 errno.h. +* [Bug 1535] from 4.2.6p2-RC2: "restrict -4 default" and "restrict + -6 default" ignored. +(4.2.7p25) 2010/04/20 Released by Harlan Stenn +* [Bug 1528] from 4.2.6p2-RC2: Remove --with-arlib from br-flock. +* [Bug 1503] [Bug 1504] [Bug 1518] [Bug 1522] from 4.2.6p2-RC2: + all of which were fixed in 4.2.7 previously. +(4.2.7p24) 2010/04/13 Released by Harlan Stenn +* [Bug 1390] Control PPS on the Oncore M12. +* [Bug 1518] Windows ntpd should lock to one processor more + conservatively. +* [Bug 1520] '%u' formats for size_t gives warnings with 64-bit builds. +* [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". +* Documentation updates for 4.2.7p22 changes and additions, updating + ntpdc.html, ntpq.html, accopt.html, confopt.html, manyopt.html, + miscopt.html, and miscopt.txt. +* accopt.html: non-ntpport doc changes from Dave Mills. +* Modify full MRU list preemption when full to match "discard monitor" + documentation, by removing exception for count == 1. +(4.2.7p23) 2010/04/04 Released by Harlan Stenn +* [Bug 1516] unpeer by IP address fails, DNS name works. +* [Bug 1517] ntpq and ntpdc should verify reverse DNS before use. + ntpq and ntpdc now use the following format for showing purported + DNS names from IP address "reverse" DNS lookups when the DNS name + does not exist or does not include the original IP address among + the results: "192.168.1.2 (fake.dns.local)". +(4.2.7p22) 2010/04/02 Released by Harlan Stenn +* [Bug 1432] Don't set inheritable flag for linux capabilities. +* [Bug 1465] Make sure time from TS2100 is not invalid. +* [Bug 1483] AI_NUMERICSERV undefined in 4.2.7p20. +* [Bug 1497] fudge is broken by getnetnum() change. +* [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. +* [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. +* ntpdate: stop querying source after KoD packet response, log it. +* ntpdate: rate limit each server to 2s between packets. +* From J. N. Perlinger: avoid pointer wraparound warnings in dolfptoa(), + printf format mismatches with 64-bit size_t. +* Broadcast client (ephemeral) associations should be demobilized only + if they are not heard from for 10 consecutive polls, regardless of + surviving the clock selection. Fix from David Mills. +* Add "ntpq -c ifstats" similar to "ntpdc -c ifstats". +* Add "ntpq -c sysstats" similar to "ntpdc -c sysstats". +* Add "ntpq -c monstats" to show monlist knobs and stats. +* Add "ntpq -c mrulist" similar to "ntpdc -c monlist" but not + limited to 600 rows, and with filtering and sorting options: + ntpq -c "mrulist mincount=2 laddr=192.168.1.2 sort=-avgint" + ntpq -c "mrulist sort=addr" + ntpq -c "mrulist mincount=2 sort=count" + ntpq -c "mrulist sort=-lstint" +* Modify internal representation of MRU list to use l_fp fixed-point + NTP timestamps instead of seconds since startup. This increases the + resolution and substantially improves accuracy of sorts involving + timestamps, at the cost of flushing all MRU entries when the clock is + stepped, to ensure the timestamps can be compared with the current + get_systime() results. +* Add ntp.conf "mru" directive to configure MRU parameters, such as + "mru mindepth 600 maxage 64 maxdepth 5000 maxmem 1024" or + "mru initalloc 0 initmem 16 incalloc 99 incmem 4". Several pairs are + equivalent with one in units of MRU entries and its twin in units of + kilobytes of memory, so the last one used in ntp.conf controls: + maxdepth/maxmem, initalloc/initmem, incalloc/incmem. With the above + values, ntpd will preallocate 16kB worth of MRU entries, allocating + 4kB worth each time more are needed, with a hard limit of 1MB of MRU + entries. Until there are more than 600 entries none would be reused. + Then only entries for addresses last seen 64 seconds or longer ago are + reused. +* Limit "ntpdc -c monlist" response in ntpd to 600 entries, the previous + overall limit on the MRU list depth which was driven by the monlist + implementation limit of one request with a single multipacket + response. +* New "pool" directive implementation modeled on manycastclient. +* Do not abort on non-ASCII characters in ntp.conf, ignore them. +* ntpq: increase response reassembly limit from 24 to 32 packets, add + discussion in comment regarding results with even larger MAXFRAGS. +* ntpq: handle "passwd MYPASSWORD" (without prompting) as with ntpdc. +* ntpdc: do not examine argument to "passwd" if not supplied. +* configure: remove check for pointer type used with qsort(), we + require ANSI C which mandates void *. +* Reset sys_kodsent to 0 in proto_clr_stats(). +* Add sptoa()/sockporttoa() similar to stoa()/socktoa() adding :port. +* Use memcpy() instead of memmove() when buffers can not overlap. +* Remove sockaddr_storage from our sockaddr_u union of sockaddr, + sockaddr_in, and sockaddr_in6, shaving about 100 bytes from its size + and substantially decreasing MRU entry memory consumption. +* Extend ntpq readvar (alias rv) to allow fetching up to three named + variables in one operation: ntpq -c "rv 0 version offset frequency". +* ntpq: use srchost variable to show .POOL. prototype associations' + hostname instead of address 0.0.0.0. +* "restrict source ..." configures override restrictions for time + sources, allows tight default restrictions to be used with the pool + directive (where server addresses are not known in advance). +* Ignore "preempt" modifier on manycastclient and pool prototype + associations. The resulting associations are preemptible, but the + prototype must not be. +* Maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. +* Remove more workarounds unneeded since we require ISO C90 AKA ANSI C: + - remove fallback implementations for memmove(), memset, strstr(). + - do not test for atexit() or memcpy(). +* Collapse a bunch of code duplication in ntpd/ntp_restrict.c added with + support for IPv6. +* Correct some corner case failures in automatically enabling the MRU + list if any "restrict ... limited" is in effect, and in disabling MRU + maintenance. (ntp_monitor.c, ntp_restrict.c) +* Reverse the internal sort order of the address restriction lists, but + preserve the same behavior. This allows removal of special-case code + related to the default restrictions and more straightforward lookups + of restrictions for a given address (now, stop on first match). +* Move ntp_restrict.c MRU doubly-linked list maintenance code into + ntp_lists.h macros, allowing more duplicated source excision. +* Repair ntpdate.c to no longer test HAVE_TIMER_SETTIME. +* Do not reference peer_node/unpeer_node after freeing when built with + --disable-saveconfig and using DNS. +(4.2.7p21) 2010/03/31 Released by Harlan Stenn +* [Bug 2399] Reset sys_kodsent in proto_clr_stats(). +* [Bug 1514] from 4.2.6p1-RC6: Typo in ntp_proto.c: fabs(foo < .4) + should be fabs(foo) < .4. +* [Bug 1464] from 4.2.6p1-RC6: synchronization source wrong for + refclocks ARCRON_MSF (27) and SHM (28). +* From 4.2.6p1-RC6: Correct Windows port's refclock_open() to + return 0 on failure not -1. +* From 4.2.6p1-RC6: Correct CHU, dumbclock, and WWVB drivers to + check for 0 returned from refclock_open() on failure. +* From 4.2.6p1-RC6: Correct "SIMUL=4 ./flock-build -1" to + prioritize -1/--one. +* [Bug 1306] constant conditionals in audio_gain(). +(4.2.7p20) 2010/02/13 Released by Harlan Stenn +* [Bug 1483] hostname in ntp.conf "restrict" parameter rejected. +* Use all addresses for each restrict by hostname. +* Use async DNS to resolve trap directive hostnames. +(4.2.7p19) 2010/02/09 Released by Harlan Stenn +* [Bug 1338] Update the association type codes in ntpq.html. +* [Bug 1478] from 4.2.6p1-RC5: linking fails: EVP_MD_pkey_type. +* [Bug 1479] from 4.2.6p1-RC5: not finding readline headers. +* [Bug 1484] from 4.2.6p1-RC5: ushort is not defined in QNX6. +(4.2.7p18) 2010/02/07 Released by Harlan Stenn +* [Bug 1480] from 4.2.6p1-RC5: snprintf() cleanup caused + unterminated refclock IDs. +* Stop using getaddrinfo() to convert numeric address strings to on-wire + addresses in favor of is_ip_address() alone. +(4.2.7p17) 2010/02/05 Released by Harlan Stenn +* [Bug 1477] from 4.2.6p1-RC5: First non-gmake make in clone + w/VPATH can't make COPYRIGHT. +* Attempts to cure CID 108 CID 118 CID 119 TAINTED_SCALAR warnings. +* Broaden ylwrap workaround VPATH_HACK to all non-GNU make. +(4.2.7p16) 2010/02/04 Released by Harlan Stenn +* [Bug 1474] from 4.2.6p1-RC4: ntp_keygen LCRYPTO after libntp.a. +* Include 4.2.6p1-RC4: Remove arlib. +(4.2.7p15) 2010/02/03 Released by Harlan Stenn +* [Bug 1455] from 4.2.6p1: ntpd does not try /etc/ntp.audio. +* Include 4.2.6p1: Convert many sprintf() calls to snprintf(), also + strcpy(), strcat(). +* Include 4.2.6p1: Fix widely cut-n-pasted bug in refclock shutdown + after failed start. +* Include 4.2.6p1: Remove some dead code checking for emalloc() + returning NULL. +(4.2.7p14) 2010/02/02 Released by Harlan Stenn +* [Bug 1338] ntpq displays incorrect association type codes. +* [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. +* [Bug 1470] from 4.2.6p1: "make distdir" compiles keyword-gen. +* [Bug 1471] CID 120 CID 121 CID 122 is_ip_address() uninit family. +* [Bug 1472] CID 116 CID 117 minor warnings in new DNS code. +* [Bug 1473] from 4.2.6p1: "make distcheck" version.m4 error. +(4.2.7p13) 2010/01/31 Released by Harlan Stenn +* [Bug 1467] from 4.2.6p1: Fix bogus rebuild of sntp/sntp.html. +(4.2.7p12) 2010/01/30 Released by Harlan Stenn +* [Bug 1468] 'make install' broken for root on default NFS mount. +(4.2.7p11) 2010/01/28 Released by Harlan Stenn +* [Bug 47] Debugging and logging do not work after a fork. +* [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. +* New async DNS resolver in ntpd allows nonblocking queries anytime, + instead of only once at startup. +(4.2.7p10) 2010/01/24 Released by Harlan Stenn +* [Bug 1140] from 4.2.6p1-RC5: Clean up debug.html, decode.html, + and ntpq.html. +* Include 4.2.6p1-RC3: Use TZ=UTC instead of TZ= when calling date in + scripts/mkver.in . +* [Bug 1448] from 4.2.6p1-RC3: Some macros not correctly conditionally + or absolutely defined on Windows. +* [Bug 1449] from 4.2.6p1-RC3: ntpsim.h in ntp_config.c should be used + conditionally. +* [Bug 1450] from 4.2.6p1-RC3: Option to exclude warnings not + unconditionally defined on Windows. +(4.2.7p9) 2010/01/13 Released by Harlan Stenn +(4.2.7p8) 2010/01/12 Released by Harlan Stenn +* [Bug 702] ntpd service logic should use libopts to examine cmdline. +* [Bug 1451] from 4.2.6p1-RC3: sntp leaks KoD entry updating. +* [Bug 1453] from 4.2.6p1-RC3: Use $CC in config.cache filename. +(4.2.7p7) 2009/12/30 Released by Harlan Stenn +* [Bug 620] ntpdc getresponse() esize != *rsize s/b size != *rsize. +* [Bug 1446] 4.2.7p6 requires autogen, missing ntpd.1, *.texi, *.menu. +(4.2.7p6) 2009/12/28 Released by Harlan Stenn +* [Bug 1443] Remove unnecessary dependencies on ntp_io.h +* [Bug 1442] Move Windows functions into libntp files +* [Bug 1127] from 4.2.6p1-RC3: Check the return of X590_verify(). +* [Bug 1439] from 4.2.6p1-RC3: .texi gen after binary is linked. +* [Bug 1440] from 4.2.6p1-RC3: Update configure.ac to support kfreebsd. +* [Bug 1445] from 4.2.6p1-RC3: IRIX does not have -lcap or support + linux capabilities. +(4.2.7p5) 2009/12/25 Released by Harlan Stenn +* Include 4.2.6p1-RC2 +(4.2.7p4) 2009/12/24 Released by Harlan Stenn +* [Bug 1429] ntpd -4 option does not reliably force IPv4 resolution. +* [Bug 1431] System headers must come before ntp headers in ntp_intres.c . +(4.2.7p3) 2009/12/22 Released by Harlan Stenn +* [Bug 1426] scripts/VersionName needs . on the search path. +* [Bug 1427] quote missing in ./build - shows up on NetBSD. +* [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h +(4.2.7p2) 2009/12/20 Released by Harlan Stenn +* [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. +* [Bug 1421] add util/tg2, a clone of tg that works on Linux, NetBSD, and + FreeBSD +(4.2.7p1) 2009/12/15 Released by Harlan Stenn +* [Bug 1348] ntpd Windows port should wait for sendto() completion. +* [Bug 1413] test OpenSSL headers regarding -Wno-strict-prototypes. +* [Bug 1418] building ntpd/ntpdc/ntpq statically with ssl fails. +(4.2.7p0) 2009/12/13 Released by Harlan Stenn +* [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. +* [Bug 1414] Enable "make distcheck" success with BSD make. +(4.2.7) 2009/12/09 Released by Harlan Stenn +* [Bug 1407] configure.ac: recent GNU Make -v does not include "version". +--- +(4.2.6p5) 2011/12/24 Released by Harlan Stenn + +No changes from 4.2.6p5-RC3. + +--- +(4.2.6p5-RC3) 2011/12/08 Released by Harlan Stenn + +* [Bug 2082] 3-char refid sent by ntpd 4.2.6p5-RC2 ends with extra dot. +* [Bug 2085] clock_update() sys_rootdisp calculation omits root delay. +* [Bug 2086] get_systime() should not offset by sys_residual. +* [Bug 2087] sys_jitter calculation overweights sys.peer jitter. +* Ensure NULL peer->dstadr is not accessed in orphan parent selection. + +--- +(4.2.6p5-RC2) 2011/11/30 Released by Harlan Stenn + +* [Bug 2050] Orphan mode stratum counting to infinity. +* [Bug 2059] optional billboard column "server" does not honor -n. +* [Bug 2066] ntpq lopeers ipv6 "local" column overrun. +* [Bug 2068] ntpd sends nonprintable stratum 16 refid to ntpq. +* [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. +* [Bug 2072] Orphan parent selection metric needs ntohl(). +* Exclude not-yet-determined sys_refid from use in loopback TEST12 + (from David Mills). +* Never send KoD rate limiting response to MODE_SERVER response. + +--- +(4.2.6p5-RC1) 2011/10/18 Released by Harlan Stenn + +* [Bug 2034] Listening address configuration with prefix misapplied. + +--- +(4.2.6p4) 2011/09/22 Released by Harlan Stenn + +* [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). +* [Bug 1985] "logconfig =allall" rejected. +* [Bug 2001] ntpdc timerstats reports overruns as handled. +* [Bug 2003] libntpq ntpq_read_assoc_peervars() broken. +* [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be + consistent with ntpd. +* libopts/file.c fix from Bruce Korb (arg-type=file). + +--- +(4.2.6p4-RC2) 2011/08/04 Released by Harlan Stenn + +* [Bug 1608] Parse Refclock driver should honor trusttime. +* [Bug 1961] html2man update: distribute ntp-wait.html. +* [Bug 1970] UNLINK_EXPR_SLIST() causes crash if list is empty. +* [Bug 1972] checking for struct rtattr fails. +* [Bug 1975] libntp/mktime.c won't work with 64-bit time_t +* [Bug 1978] [Bug 1134] fix in 4.2.6p4-RC1 doesn't build on older Linux. +* Backport several fixes for Coverity warnings from ntp-dev. +* Backport if_nametoindex() check for hpux. + +--- +(4.2.6p4-RC1) 2011/07/10 Released by Harlan Stenn + +* [Bug 1134] ntpd fails binding to tentative IPv6 addresses. +* [Bug 1790] Update config.guess and config.sub to detect AIX6. +* [Bug 1961] html2man needs an update. +* Update the NEWS file. + +--- +(4.2.6p4-beta2) 2011/05/25 Released by Harlan Stenn + +* [Bug 1695] ntpdate takes longer than necessary. +* [Bug 1832] ntpdate doesn't allow timeout > 2s. +* [Bug 1933] WWVB/Spectracom driver timestamps LFs, not CRs. +* Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + +--- +(4.2.6p4-beta1) 2011/05/16 Released by Harlan Stenn + +* [Bug 1554] peer may stay selected as system peer after becoming + unreachable. +* [Bug 1921] LOCAL, ACTS drivers with "prefer" excluded from initial + candidate list. +* [Bug 1923] orphan parent favored over LOCAL, ACTS drivers. +* [Bug 1924] Billboard tally codes sometimes do not match operation, + variables. +* Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. +* Upgrade to AutoGen 5.11.9 (and require it). +* Upgrade to libopts 35.0.10 from AutoGen 5.11.9pre8. + +--- +(4.2.6p3) 2011/01/03 Released by Harlan Stenn + +* [Bug 1764] Palisade driver doesn't build on Linux +* Create and use scripts/check--help when generating .texi files. +* Update bk triggers for the bk-5 release. +* Update genCommitLog for the bk-5 release. +* Update the copyright year. + +--- +(4.2.6p3-RC12) 2010/12/25 Released by Harlan Stenn + +* [Bug 1458] Can not compile NTP on FreeBSD 4.7. +* [Bug 1510] Add modes 20/21 for driver 8 to support RAWDCF @ 75 baud. +* [Bug 1618] Unreachable code in jjy_start(). (backport from ntp-dev) +* [Bug 1719] ntp-keygen -V crash. (backport) +* [Bug 1740] ntpdc treats many counters as signed. (backport) +* [Bug 1741] Enable multicast reception on each address (Windows). +* [Bug 1742] Fix a typo in an error message in the "build" script. +* [Bug 1743] Display timezone offset when showing time for sntp in the +local timezone. +* [Bug 1751] Support for Atari FreeMiNT OS. +* [Bug 1754] --version output should be more verbose. +* [Bug 1757] oncore snprintf("%m") doesn't expand %m. +* [Bug 1758] setsockopt IPV6_MULTICAST_IF with wrong ifindex. +* [Bug 1760] ntpd Windows interpolation cannot be disabled. +* [Bug 1762] manycastclient solicitation responses interfere. +* Upgrade to libopts 34.0.9 from AutoGen 5.11.6pre7. +* Relax minimum Automake version to 1.10 with updated libopts.m4. +* Suppress ntp-keygen OpenSSL version display for --help, --version, +display both build and runtime OpenSSL versions when they differ. +* Clean up m4 quoting in configure.ac, *.m4 files, resolving + intermittent AC_LANG_PROGRAM possibly undefined errors. +* Clean up the SNTP documentation. +* Other manycastclient repairs: + Separate handling of scope ID embedded in many in6_addr from ifindex + used for IPv6 multicasting ioctls. + Add INT_PRIVACY endpt bit flag for IPv6 RFC 4941 privacy addresses. + Enable outbound multicast from only one address per interface in the + same subnet, and in that case prefer embedded MAC address modified + EUI-64 IPv6 addresses first, then static, and last RFC 4941 privacy + addresses. + Use setsockopt(IP[V6]_MULTICAST_IF) before each send to multicast to + select the local source address, using the correct socket is not + enough. + +--- +(4.2.6p3-RC11) 2010/11/28 Released by Harlan Stenn + +* [Bug 1725] ntpd sends multicast from only one address. +* [Bug 1728] In ntp_openssl.m4, don't add -I/usr/include or -L/usr/lib + to CPPFLAGS or LDFLAGS. +* [Bug 1733] IRIX doesn't have 'head' (affects scripts/checkChangeLog). +* Remove log_msg() and debug_msg() from sntp in favor of msyslog(). +* Use a single copy of libopts/, in sntp/. +* Upgrade libopts to 33.3.8. +* Bump minimum Automake version to 1.11, required for AM_COND_IF + use in LIBOPTS_CHECK. +* Improvements to the 'build' script. + +--- +(4.2.6p3-RC10) 2010/11/14 Released by Harlan Stenn + +* [Bug 1681] More sntp logging cleanup. +* [Bug 1683] Non-localhost on loopback exempted from nic rules. + +--- +(4.2.6p3-RC9) 2010/11/10 Released by Harlan Stenn + +* [Bug 1574] sntp:set_time doesn't set tv_usec correctly. +* [Bug 1681] sntp logging cleanup. +* [Bug 1683] Interface binding does not seem to work as intended. +* [Bug 1691] Use first NMEA sentence each second. +* [Bug 1692] packageinfo.sh needs to be "sourced" using ./ . +* [Bug 1709] ntpdate ignores replies with equal receive and transmit + timestamps. +* Backport sntp from -dev + +--- +(4.2.6p3-RC8) 2010/10/29 Released by Harlan Stenn + +* [Bug 1685] NMEA driver mode byte confusion. +* First cut at using scripts/checkChangeLog. + +--- +(4.2.6p3-RC7) 2010/10/25 Released by Harlan Stenn + +* [Bug 1676] NMEA: $GPGLL did not work after fix for Bug 1571. +* Added scripts/checkChangeLog. + +--- +(4.2.6p3-RC6) 2010/10/24 Released by Harlan Stenn + +* [Bug 1571] NMEA does not relate data to PPS edge. +* [Bug 1572] NMEA time adjustment for GPZDG buggy. +* [Bug 1675] Prohibit includefile remote config. + +--- +(4.2.6p3-RC5) 2010/10/22 Released by Harlan Stenn + +* [Bug 1649] Require NMEA checksum if $GPRMC or previously seen. +* [Bug 1669] NTP 4.2.6p2 fails to compile on IBM AIX 5.3. + +--- +(4.2.6p3-RC4) 2010/10/16 Released by Harlan Stenn + +* [Bug 1584] wrong SNMP type for precision, resolution. +* [Bug 1659] Need CLOCK_TRUETIME not CLOCK_TRUE. +* [Bug 1665] is_anycast() u_int32_t should be u_int32. +* ntpsnmpd, libntpq warning cleanup. + +--- +(4.2.6p3-RC3) 2010/10/14 Released by Harlan Stenn + +* [Bug 750] Non-existing device causes coredump with RIPE-NCC driver. +* [Bug 1080] ntpd on ipv6 routers very chatty. +* [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. +* [Bug 1581] printf format string mismatch leftover. +* [Bug 1584] ntpsnmpd OID must be mib-2.197. +* [Bug 1643] Range-check the decoding of the RIPE-NCC status codes. +* [Bug 1644] cvo.sh should use lsb_release to identify linux distros. +* [Bug 1659] Support Truetime Satellite Clocks on Windows. +* [Bug 1660] On some systems, test is in /usr/bin, not /bin. +* [Bug 1661] Re-indent refclock_ripencc.c. + +--- +(4.2.6p3-RC2) 2010/09/25 Released by Harlan Stenn + +* [Bug 1635] "filegen ... enable" is not default. +* [Bug 1636] yyparse() segfault after denied filegen remote config. + +--- +(4.2.6p3-RC1) 2010/09/18 Released by Harlan Stenn + +* [Bug 1344] ntpd on Windows exits without logging cause. + +--- +(4.2.6p3-beta1) 2010/09/11 Released by Harlan Stenn + +* [Bug 1573] Miscalculation of offset in sntp. +* [Bug 1595] empty last line in key file causes duplicate key to be added +* [Bug 1597] packet processing ignores RATE KoD packets, because of + a bug in string comparison. +* [Bug 1581] ntp_intres.c size_t printf format string mismatch. + +--- +(4.2.6p2) 2010/07/09 Released by Harlan Stenn + +* [Bug 1581] size_t printf format string mismatches, IRIG string buffers + undersized. Mostly backported from earlier ntp-dev fixes by Juergen + Perlinger. + +--- +(4.2.6p2-RC7) 2010/06/19 Released by Harlan Stenn + +* [Bug 1570] serial clock drivers get outdated input from kernel tty + line buffer after startup +* [Bug 1575] use 'snprintf' with LIB_BUFLENGTH in inttoa.c, tvtoa.c and + utvtoa.c +* [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD. + +--- +(4.2.6p2-RC6) 2010/06/12 Released by Harlan Stenn + +* [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. + +--- +(4.2.6p2-RC5) 2010/06/03 Released by Harlan Stenn + +* [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. +* [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). +* Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. +* Support "passwd blah" syntax in ntpq. + +--- +(4.2.6p2-RC4) 2010/05/19 Released by Harlan Stenn + +* [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + +--- +(4.2.6p2-RC3) 2010/05/11 Released by Harlan Stenn + +* [Bug 1325] unreachable code in sntp recv_bcst_data(). +* [Bug 1459] sntp MD5 authentication does not work with ntpd. +* [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain + socket by default. Provide a command-line 'socket name' option. +* [Bug 1538] update refclock_nmea.c's call to getprotobyname(). +* [Bug 1541] Fix wrong keyword for "maxclock". +* [Bug 1552] update and complete broadcast and crypto features in sntp. +* [Bug 1553] sntp/configure.ac OpenSSL support. +* Escape unprintable characters in a refid in ntpq -p billboard. +* Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) +* Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. +* Windows compiling hints/winnt.html update from G. Sunil Tej. + +--- +(4.2.6p2-RC2) 2010/04/27 Released by Harlan Stenn + +* [Bug 1465] Make sure time from TS2100 is not invalid (backport from + ntp-dev). +* [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc. +* [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. +* [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. +* Remove --with-arlib from br-flock. + +--- +(4.2.6p2-RC1) 2010/04/18 Released by Harlan Stenn + +* [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. +* [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. +* [Bug 1518] Windows ntpd should lock to one processor more + conservatively. +* [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". +* Update html/authopt.html controlkey, requestkey, and trustedkey docs. + +--- +(4.2.6p1) 2010/04/09 Released by Harlan Stenn +(4.2.6p1-RC6) 2010/03/31 Released by Harlan Stenn + +* [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4. +* [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). +* Correct Windows port's refclock_open() to return 0 on failure not -1. +* Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. +* Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. + +--- +(4.2.6p1-RC5) 2010/02/09 Released by Harlan Stenn + +* [Bug 1140] Clean up debug.html, decode.html, and ntpq.html. +* [Bug 1438] Remove dead code from sntp/networking.c. +* [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. +* [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. +* [Bug 1479] Compilation fails because of not finding readline headers. +* [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. +* [Bug 1484] ushort is not defined in QNX6. + +--- +(4.2.6p1-RC4) 2010/02/04 Released by Harlan Stenn + +* [Bug 1455] ntpd does not try /etc/ntp.audio as documented. +* [Bug 1467] Fix bogus rebuild of sntp/sntp.html +* [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. +* [Bug 1473] "make distcheck" before build can't make sntp/version.m4. +* [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a. +* Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). +* Fix widely cut-n-pasted bug in refclock shutdown after failed start. +* Remove some dead code checking for emalloc() returning NULL. +* Remove arlib. + +--- +(4.2.6p1-RC3) 2010/01/24 Released by Harlan Stenn + +* Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in . +* [Bug 1448] Some macros not correctly conditionally or absolutely defined + on Windows. +* [Bug 1449] ntpsim.h in ntp_config.c should be used conditionally. +* [Bug 1450] Option to exclude warnings not unconditionally defined on Windows. +* [Bug 1127] Properly check the return of X590_verify() - missed one. +* [Bug 1439] .texi generation must wait until after binary is linked. +* [Bug 1440] Update configure.ac to support kfreebsd. +* [Bug 1445] IRIX does not have -lcap or support linux capabilities. +* [Bug 1451] CID 115: sntp leaks KoD entry when updating existing. +* [Bug 1453] Use $CC in config.cache filename in ./build script. + +--- +(4.2.6p1-RC2) 2009/12/25 Released by Harlan Stenn + +* [Bug 1411] Fix status messages in refclock_oncore.c. +* [Bug 1416] MAXDNAME undefined on Solaris 2.6. +* [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. +* [Bug 1424] Fix check for rtattr (rtnetlink.h). +* [Bug 1425] unpeer by association ID sets up for duplicate free(). +* [Bug 1426] scripts/VersionName needs . on the search path. +* [Bug 1427] quote missing in ./build - shows up on NetBSD. +* [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h +* [Bug 1429] ntpd -4 option does not reliably force IPv4 resolution. +* [Bug 1431] System headers must come before ntp headers in ntp_intres.c . +* [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. +* [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp. + +--- +(4.2.6p1-RC1) 2009/12/20 Released by Harlan Stenn + +* [Bug 1409] Put refclock_neoclock4x.c under the NTP COPYRIGHT notice. + This should allow debian and other distros to add this refclock driver + in further distro releases. + Detect R2 hardware releases. +* [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. +* [Bug 1413] test OpenSSL headers regarding -Wno-strict-prototypes. +* [Bug 1414] Enable "make distcheck" success with BSD make. +* [Bug 1415] Fix Mac OS X link problem. +* [Bug 1418] building ntpd/ntpdc/ntpq statically with ssl fails. +* Build infrastructure updates to enable beta releases of ntp-stable. + +--- +(4.2.6) 2009/12/09 Released by Harlan Stenn +* [Sec 1331] from4.2.4p8: DoS with mode 7 packets - CVE-2009-3563. +* [Bug 508] Fixed leap second handling for Windows. +(4.2.5p250-RC) 2009/11/30 Released by Harlan Stenn +* sntp documentation updates. +* [Bug 761] internal resolver does not seem to honor -4/-6 qualifiers +* [Bug 1386] Deferred DNS doesn't work on NetBSD +* [Bug 1391] avoid invoking autogen twice for .c and .h files. +* [Bug 1397] shmget() refclock_shm failing because of file mode. +* Pass no_needed to ntp_intres as first part of fixing [Bug 975]. +* Add ./configure --enable-force-defer-DNS to help debugging. +(4.2.5p249-RC) 2009/11/28 Released by Harlan Stenn +* [Bug 1400] An empty KOD DB file causes sntp to coredump. +* sntp: documentation cleanup. +* sntp: clean up some error messages. +* sntp: Use the precision to control how many offset digits are shown. +* sntp: Show root dispersion. +* Cleanup from the automake/autoconf upgrades. +(4.2.5p248-RC) 2009/11/26 Released by Harlan Stenn +* Prepare for the generation of sntp.html. +* Documentation changes from Dave Mills. +* [Bug 1387] Storage leak in ntp_intres (minor). +* [Bug 1389] buffer overflow in refclock_oncore.c +* [Bug 1391] .texi usage text from installed, not built binaries. +* [Bug 1392] intres retries duplicate assocations endlessly. +* Correct *-opts.h dependency so default 'get' action isn't used. +(4.2.5p247-RC) 2009/11/20 Released by Harlan Stenn +* [Bug 1142] nodebug builds shed no light on -d, -D option failure. +* [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. +* [Bug 1308] support systems that lack fork(). +* [Bug 1343] sntp doesn't link on Solaris 7, needs -lresolv. +(4.2.5p246-RC) 2009/11/17 Released by Harlan Stenn +* Upgrade to autogen-5.10 +* [Bug 1378] Unnecessary resetting of peers during interface update. +* [Bug 1382] p245 configure --disable-dependency-tracking won't build. +* [Bug 1384] ntpq :config core dumped with a blank password. +(4.2.5p245-RC) 2009/11/14 Released by Harlan Stenn +* Cleanup from Dave Mills. +* [Bug 1343] sntp illegal C does not compile on Solaris 7. +* [Bug 1381] Version .deps generated include file dependencies to allow + known dependency-breaking changes to force .deps to be cleaned, + triggered by changing the contents of deps-ver and/or sntp/deps-ver. +(4.2.5p244-RC) 2009/11/12 Released by Harlan Stenn +* keygen.html updates from Dave Mills. +* [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. +* [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. +* ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. +(4.2.5p243-RC) 2009/11/11 Released by Harlan Stenn +* [Bug 1226] Fix deferred DNS lookups. +* new crypto signature cleanup. +(4.2.5p242-RC) 2009/11/10 Released by Harlan Stenn +* [Bug 1363] CID 92 clarify fallthrough case in clk_trimtsip.c +* [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. +* [Bug 1368] typos in libntp --without-crypto case +* [Bug 1371] deferred DNS lookup failing with INFO_ERR_AUTH. +* CID 87 dead code in ntpq.c atoascii(). +* Fix authenticated ntpdc, broken in p240. +* Stub out isc/mem.h, shaving 47k from a MIPS ntpd binary. +* Shrink keyword scanner FSM entries from 64 to 32 bits apiece. +* Documention updates from Dave Mills. +* authkeys.c cleanup from Dave Mills. +(4.2.5p241-RC) 2009/11/07 Released by Harlan Stenn +* html/authopt.html update from Dave Mills. +* Remove unused file from sntp/Makefile.am's distribution list. +* new crypto signature cleanup. +(4.2.5p240-RC) 2009/11/05 Released by Harlan Stenn +* [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. +* Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2). +(4.2.5p239-RC) 2009/10/30 Released by Harlan Stenn +* [Bug 1357] bogus assert from refclock_shm. +* [Bug 1359] Debug message cleanup. +* CID 101: more pointer/array cleanup. +* [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. +* [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. +* CID 101: pointer/array cleanup. +(4.2.5p238-RC) 2009/10/27 Released by Harlan Stenn +* Changes from Dave Mills. +* driver4.html updates from Dave Mills. +* [Bug 1252] PPSAPI cleanup on ntpd/refclock_wwvb.c. +* [Bug 1354] libtool error building after bootstrap with Autoconf 2.64. +* Allow NTP_VPATH_HACK configure test to handle newer gmake versions. +* CIDs 94-99 make it more clearly impossible for sock_hash() to return + a negative number. +* CID 105, 106 ensure ntpdc arrays are not overrun even if callers + misbehave. +* CID 113 use va_end() in refclock_true.c true_debug(). +* Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. +(4.2.5p237-RC) 2009/10/26 Released by Harlan Stenn +* [Bug 610] NMEA support for using PPSAPI on a different device. +* [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. +* [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. +(4.2.5p236-RC) 2009/10/22 Released by Harlan Stenn +* Cleanup from Dave Mills. +* [Bug 1343] ntpd/ntp_io.c close_fd() does not compile on Solaris 7. +* [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. +* Do not attempt to execute built binaries from ntpd/Makefile when + cross-compiling (keyword-gen and ntpd --saveconfigquit). +* sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. +* Correct in6addr_any test in configure.ac to attempt link too. +(4.2.5p235-RC) 2009/10/18 Released by Harlan Stenn +* [Bug 1343] lib/isc build breaks on systems without IPv6 headers. +(4.2.5p234-RC) 2009/10/16 Released by Harlan Stenn +* [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. +* [Bug 1345] illegal 'grep' option prevents compilation. +* [Bug 1346] keyword scanner broken where char defaults to unsigned. +* [Bug 1347] ntpd/complete.conf missing multicastclient test case. +(4.2.5p233-RC) 2009/10/15 Released by Harlan Stenn +* [Bug 1337] cast setsockopt() v4 address pointer to void *. +* [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. +* Documentation cleanup and updates. +(4.2.5p232-RC) 2009/10/14 Released by Harlan Stenn +* [Bug 1302] OpenSSL under Windows needs applink support. +* [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...). +* [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. +* [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. +* Construct ntpd keyword scanner finite state machine at compile time + rather than at runtime, shrink entries from 40+ to 8 bytes. +* Update documentation for ntpq --old-rv, saveconfig, saveconfigdir, + ntpd -I -L and -M, and interface/nic rules. (From Dave Hart) +* [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) +(4.2.5p231-RC) 2009/10/10 Released by Harlan Stenn +* [Bug 1335] Broadcast client degraded by wildcard default change. +(4.2.5p230-RC) 2009/10/09 Released by Harlan Stenn +* Start the 4.2.6 Release Candidate cycle. +* Broadcast and transit phase cleanup from Dave Mills. +(4.2.5p229) 2009/10/07 Released by Harlan Stenn +* [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. +* Change ntpsnmpd/Makefile.am include file order to fix FreeBSD build. +(4.2.5p228) 2009/10/06 Released by Harlan Stenn +* Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. +* [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. +* [Bug 1333] ntpd --interface precedence over --novirtualips lost. +(4.2.5p227) 2009/10/05 Released by Harlan Stenn +* [Bug 1135] :config fails with "Server disallowed request" +* [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. +* [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. +* Add test of ntpd --saveconfigquit fidelity using new complete.conf. +* Documentation updates from Dave Hart/Dave Mills. +(4.2.5p226) 2009/10/04 Released by Harlan Stenn +* [Bug 1318] Allow multiple -g options on ntpd command line. +* [Bug 1327] ntpq, ntpdc, ntp-keygen -d & -D should work with configure + --disable-debugging. +* Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. +* Clockhop and autokey cleanup from Dave Mills. +* Documentation updates from Dave Mills. +(4.2.5p225) 2009/09/30 Released by Harlan Stenn +* authopt documentation changes from Dave Mills/Dave Hart. +* [Bug 1324] support bracketed IPv6 numeric addresses for restrict. +(4.2.5p224) 2009/09/29 Released by Harlan Stenn +* Clockhop and documentation fixes from Dave Mills. +* Remove "tos maxhop" ntp.conf knob. +(4.2.5p223) 2009/09/28 Released by Harlan Stenn +* [Bug 1321] build doesn't work if . isn't on $PATH. +* [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". +(4.2.5p222) 2009/09/27 Released by Harlan Stenn +* Update libisc code using bind-9.6.1-P1.tar.gz, rearrange our copy to + mirror the upstream layout (lib/isc/...), and merge in NTP-local + modifications to libisc. There is a new procedure to ease future + libisc merges using a separate "upstream" bk repo. That will enable + normal bk pull automerge to handle carrying forward any local changes + and should enable us to take updated libisc snapshots more often. +* Updated build and flock-build scripts. flock-build --one is a way + to perform a flock-build compatible solitary build, handy for a repo + clone's first build on a machine with autoconf, automake, etc. +* Compiling ntp_parser.y using BSD make correctly places ntp_parser.h + in the top-level ntpd directory instead of A.*/ntpd. +* bootstrap script updated to remove potentially stale .deps dirs. +* Remove unneeded Makefile.am files from the lib/isc/include tree. +(4.2.5p221) 2009/09/26 Released by Harlan Stenn +* [Bug 1316] segfault if refclock_nmea can't open file. +* [Bug 1317] Distribute cvo.sh. +(4.2.5p220) 2009/09/25 Released by Harlan Stenn +* Rearrange libisc code to match the upstream layout in BIND. This is + step one of two, changing the layout but keeping our existing libisc. +(4.2.5p219) 2009/09/24 Released by Harlan Stenn +* [Bug 1315] "interface ignore 0.0.0.0" is ignored. +* add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". +* add wildcard match class for interface/nic rules. +* fix mistaken carryover of prefixlen from one rule to the next. +* Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. +(4.2.5p218) 2009/09/21 Released by Harlan Stenn +* [Bug 1314] saveconfig emits -4 and -6 on when not given. +* correct parsing and processing of setvar directive. +* highlight location of ntpq :config syntax errors with ^. +* clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. +* parser, saveconfig cleanup to store T_ identifiers in syntax tree. +(4.2.5p217) 2009/09/20 Released by Harlan Stenn +* [Bug 1300] reject remote configuration of dangerous items. +(4.2.5p216) 2009/09/19 Released by Harlan Stenn +* [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. +* CID 10 missing free(up); in refclock_palisade.c error return, again. +* CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). +(4.2.5p215) 2009/09/18 Released by Harlan Stenn +* [Bug 1292] Workaround last VC6 unsigned __int64 kink. +(4.2.5p214) 2009/09/17 Released by Harlan Stenn +* [Bug 1303] remove top-level "autokey" directive. +* use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". +(4.2.5p213) 2009/09/16 Released by Harlan Stenn +* [Bug 1310] fix Thunderbolt mode in refclock_palisade.c +(4.2.5p212) 2009/09/15 Released by Harlan Stenn +* [Bug 983] add interface [listen | ignore | drop] ... directive. +* [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. +* [Bug 1295] leftover fix, do not crash on exit in free_config_trap() + when "trap 1.2.3.4" is used without any further options. +* [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. +* document interface (alias nic) and unpeer. +* Correct syntax error line & column numbers. +* CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths. +* CID 80: attempt to quiet Coverity false positive re: leaking "reason" + in main(). +* Documentation updates from Dave Mills. +* CID 81: savedconfig leaked in save_config(). +* Make the code agree with the spec and the book (Dave Mills). +(4.2.5p211) 2009/09/14 Released by Harlan Stenn +* [Bug 663] respect ntpq -c and -p order on command line. +* [Bug 1292] more VC6 unsigned __int64 workarounds. +* [Bug 1296] Added Support for Trimble Acutime Gold. +(4.2.5p210) 2009/09/06 Released by Harlan Stenn +* [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros for Windows + and remove unnecessary reference to applink.c for Windows +* [Bug 1295] trap directive options are not optional. +* [Bug 1297] yylex() must always set yylval before returning. +(4.2.5p209) 2009/09/01 Released by Harlan Stenn +* [Bug 1290] Fix to use GETTIMEOFDAY macro +* [Bug 1289] Update project files for VC6, VS2003, VS2005, VS 2008 +(4.2.5p208) 2009/08/30 Released by Harlan Stenn +* [Bug 1293] make configuration dumper ready for release, specifically: +* rename ntpq dumpcfg command to "saveconfig". +* require authentication for saveconfig. +* "restrict ... nomodify" prevents saveconfig and :config. +* "saveconfig ." shorthand to save to startup configuration file. +* support strftime() substitution in saveconfig arg to timestamp + the output filename, for example "saveconfig %Y%m%d-%H%M%S.conf". +* display saveconfig response message from ntpd in ntpq. +* save output filename in "savedconfig" variable, fetched with ntpq -c + "rv 0 savedconfig". +* document saveconfig in html/ntpq.html. +* add ./configure --disable-saveconfig to build a smaller ntpd. +* log saveconfig failures and successes to syslog. +(4.2.5p207) 2009/08/29 Released by Harlan Stenn +* [Bug 1292] Minor Windows source tweaks for VC6-era SDK headers. +(4.2.5p206) 2009/08/26 Released by Harlan Stenn +* accopt.html typo fixes from Dave Mills. +* [Bug 1283] default to remembering KoD in sntp. +* clean up numerous sntp/kod_management.c bugs. +* use all addresses resolved from each DNS name in sntp. +(4.2.5p205) 2009/08/18 Released by Harlan Stenn +* accopt.html typo fixes from Dave Mills. +* [Bug 1285] Log ntpq :config/config-from-file events. +* [Bug 1286] dumpcfg omits statsdir, mangles filegen. +(4.2.5p204) 2009/08/17 Released by Harlan Stenn +* [Bug 1284] infinite loop in ntpd dumping more than one trustedkey +(4.2.5p203) 2009/08/16 Released by Harlan Stenn +* Add ntpq -c dumpcfg, Google Summer of Code project of Max Kuehn +(4.2.5p202) 2009/08/14 Released by Harlan Stenn +* install the binary and man page for sntp. +(4.2.5p201) 2009/08/13 Released by Harlan Stenn +* sntp: out with the old, in with the new. +(4.2.5p200) 2009/08/12 Released by Harlan Stenn +* [Bug 1281] Build ntpd on Windows without big SDK download, burn, + and install by checking in essentially unchanging messages.mc build + products to avoid requiring mc.exe, which is not included with VC++ + 2008 EE. +(4.2.5p199) 2009/08/09 Released by Harlan Stenn +* [Bug 1279] Cleanup for warnings from Veracode static analysis. +(4.2.5p198) 2009/08/03 Released by Harlan Stenn +* Upgrade to autogen-5.9.9-pre5. +(4.2.5p197) 2009/07/30 Released by Harlan Stenn +* The build script now has . at the end of PATH for config.guess. +(4.2.5p196) 2009/07/29 Released by Harlan Stenn +* [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. +* [Bug 1273] CID 10: Palisade leaks unit struct in error path. +* [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. +* [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. +* [Bug 1276] CID 52: crypto_xmit() may call crypto_alice[23]() + with NULL peer. +(4.2.5p195) 2009/07/27 Released by Harlan Stenn +* cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE, and QNX. +(4.2.5p194) 2009/07/26 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Use scripts/cvo.sh in the build script to get better subdir names. +(4.2.5p193) 2009/07/25 Released by Harlan Stenn +* [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. +* [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). +* [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). +* [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. +* [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. +* [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. +* [Bug 1267] CID 44: old sntp handle_saving() writes stack garbage to + file when clearing. +* [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. +* [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. +* [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. +(4.2.5p192) 2009/07/24 Released by Harlan Stenn +* [Bug 965] CID 42: ss_family uninitialized. +* [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. +* [Bug 1251] CID 68: search_entry() mishandles dst argument. +* [Bug 1252] CID 32: Quiet Coverity warning with assertion. +* [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. +* [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. +* [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. +* [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. +* [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). +* [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. +* [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. +* [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). +* Updated to AutoGen-5.9.9pre2. +(4.2.5p191) 2009/07/21 Released by Harlan Stenn +* Updated to AutoGen-5.9.9pre1. +(4.2.5p190) 2009/07/20 Released by Harlan Stenn +* Updated to AutoGen-5.9.8. +* [Bug 1248] RES_MSSNTP typo in ntp_proto.c. +* [Bug 1246] use a common template for singly-linked lists, convert most + doubly-linked lists to singly-linked. +* Log warning about signd blocking when restrict mssntp used. +(4.2.5p189) 2009/07/16 Released by Harlan Stenn +* Documentation cleanup from Dave Mills. +(4.2.5p188) 2009/07/15 Released by Harlan Stenn +* [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187. +(4.2.5p187) 2009/07/11 Released by Harlan Stenn +* [Bug 1042] multicast listeners IPv4+6 ignore new interfaces. +* [Bug 1237] Windows serial code treat CR and LF both as line + terminators. +* [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. +* [Bug 1242] Remove --enable-wintime, symmetric workaround is now + always enabled. +* [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child +* Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills. +(4.2.5p186) 2009/07/08 Released by Harlan Stenn +* ntp_proto.c cleanup from Dave Mills. +(4.2.5p185) 2009/07/01 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* [Bug 1234] convert NMEA driver to use common PPSAPI code. +* timepps-Solaris.h pps_handle_t changed from pointer to scalar +* Spectracom refclock added to Windows port of ntpd +* [Bug 1236] Declaration order fixed. +* Bracket private ONCORE debug statements with #if 0 rather than #ifdef + DEBUG +* Delete ONCORE debug statement that is now handled elsewhere. +(4.2.5p184) 2009/06/24 Released by Harlan Stenn +* [Bug 1233] atom refclock fudge time1 sign flipped in 4.2.5p164. +(4.2.5p183) 2009/06/23 Released by Harlan Stenn +* [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. +* [Bug 1210] ONCORE driver terminates ntpd without logging a reason. +* [Bug 1218] Correct comment in refclock_oncore on /etc/ntp.oncore* + configuration file search order. +* Change ONCORE driver to log using msyslog as well as to any + clockstats file. +* [Bug 1231] ntpsnmpd build fails after sockaddr union changes. +(4.2.5p182) 2009/06/18 Released by Harlan Stenn +* Add missing header dependencies to the ntpdc layout verification. +* prefer.html updates from Dave Mills. +* [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows +* [Bug 1215] unpeer by association ID +* [Bug 1225] Broadcast address miscalculated on Windows 4.2.5p180 +* [Bug 1229] autokey segfaults in cert_install(). +* Use a union for structs sockaddr, sockaddr_storage, sockaddr_in, and + sockaddr_in6 to remove casts and enable type checking. Collapse + some previously separate IPv4/IPv6 paths into a single codepath. +(4.2.5p181) 2009/06/06 Released by Harlan Stenn +* [Bug 1206] Required compiler changes for Windows +* [Bug 1084] PPSAPI for ntpd on Windows with DLL backends +* [Bug 1204] Unix-style refclock device paths on Windows +* [Bug 1205] partial fix, disable RDTSC use by default on Windows +* [Bug 1208] decodenetnum() buffer overrun on [ with no ] +* [Bug 1211] keysdir free()d twice #ifdef DEBUG +* Enable ONCORE, ARCRON refclocks on Windows (untested) +(4.2.5p180) 2009/05/29 Released by Harlan Stenn +* [Bug 1200] Enable IPv6 in Windows port +* Lose FLAG_FIXPOLL, from Dave Mills. +(4.2.5p179) 2009/05/23 Released by Harlan Stenn +* [Bug 1041] xmt -> aorg timestamp cleanup from Dave Mills, + reported by Dave Hart. +* [Bug 1193] Compile error: conflicting types for emalloc. +* [Bug 1196] VC6 winsock2.h does not define SO_EXCLUSIVEADDRUSE. +* Leap/expire cleanup from Dave Mills. +(4.2.5p178) 2009/05/21 Released by Harlan Stenn +* Provide erealloc() and estrdup(), a la emalloc(). +* Improve ntp.conf's parser error messages. +* [Bug 320] "restrict default ignore" does not affect IPv6. +* [Bug 1192] "restrict -6 ..." reports a syntax error. +(4.2.5p177) 2009/05/18 Released by Harlan Stenn +* Include 4.2.4p7 +* [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned +* [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode +* Update NMEA refclock documentation in html/drivers/driver20.html +(4.2.5p176) 2009/05/13 Released by Harlan Stenn +* [Bug 1154] mDNS registration should be done later, repeatedly and only + if asked for. (second try for fix) +(4.2.5p175) 2009/05/12 Released by Harlan Stenn +* Include 4.2.4p7-RC7 +* [Bug 1180] ntpd won't start with more than ~1000 interfaces +* [Bug 1182] Documentation typos and missing bits. +* [Bug 1183] COM port support should extend past COM3 +* [Bug 1184] ntpd is deaf when restricted to second IP on the same net +* Clean up configure.ac NTP_CACHEVERSION interface, display cache + version when clearing. Fixes a regression. +(4.2.5p174) 2009/05/09 Released by Harlan Stenn +* Stale leapsecond file fixes from Dave Mills. +(4.2.5p173) 2009/05/08 Released by Harlan Stenn +* Include 4.2.4p7-RC6 +(4.2.5p172) 2009/05/06 Released by Harlan Stenn +* [Bug 1175] Instability in PLL daemon mode. +* [Bug 1176] refclock_parse.c does not compile without PPSAPI. +(4.2.5p171) 2009/05/04 Released by Harlan Stenn +* Autokey documentation cleanup from Dave Mills. +* [Bug 1171] line editing libs found without headers (Solaris 11) +* [Bug 1173] NMEA refclock fails with Solaris PPSAPI +* Fix problem linking msntp on Solaris when sntp subdir is configured + before parent caused by different gethostent library search order. +* Do not clear config.cache when it is empty. +(4.2.5p170) 2009/05/02 Released by Harlan Stenn +* [Bug 1152] adjust PARSE to new refclock_pps logic +* Include 4.2.4p7-RC5 +* loopfilter FLL/PLL crossover cleanup from Dave Mills. +* Documentation updates from Dave Mills. +* ntp-keygen cleanup from Dave Mills. +* crypto API cleanup from Dave Mills. +* Add NTP_CACHEVERSION mechanism to ignore incompatible config.cache +* Enable gcc -Wstrict-overflow for gsoc_sntp as well +(4.2.5p169) 2009/04/30 Released by Harlan Stenn +* [Bug 1171] Note that we never look for -lreadline by default. +* [Bug 1090] Fix bogus leap seconds in refclock_hpgps. +(4.2.5p168) 2009/04/29 Released by Harlan Stenn +* Include 4.2.4p7-RC4 +* [Bug 1169] quiet compiler warnings +* Re-enable gcc -Wstrict-prototypes when not building with OpenSSL +* Enable gcc -Wstrict-overflow +* ntpq/ntpdc emit newline after accepting password on Windows +* Updates from Dave Mills: +* ntp-keygen.c: Updates. +* Fix the error return and syslog function ID in refclock_{param,ppsapi}. +* Make sure syspoll is within the peer's minpoll/maxpoll bounds. +* ntp_crypto.c: Use sign_siglen, not len. sign key filename cleanup. +* Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths. +* m4/ntp_lineeditlibs.m4: fix warnings from newer Autoconf +* [Bug 1166] Remove truncation of position (blanking) code in refclock_nmea.c +(4.2.5p167) 2009/04/26 Released by Harlan Stenn +* Crypto cleanup from Dave Mills. +(4.2.5p166) 2009/04/25 Released by Harlan Stenn +* [Bug 1165] Clean up small memory leaks in the config file parser +* Correct logconfig keyword declaration to MULTIPLE_ARG +* Enable filename and line number leak reporting on Windows when built + DEBUG for all the typical C runtime allocators such as calloc, + malloc, and strdup. Previously only emalloc calls were covered. +* Add DEBUG-only code to free dynamically allocated memory that would + otherwise remain allocated at ntpd exit, to allow less forgivable + leaks to stand out in leaks reported after exit. +* Ensure termination of strings in ports/winnt/libisc/isc_strerror.c + and quiet compiler warnings. +* [Bug 1057] ntpdc unconfig failure +* [Bug 1161] unpeer AKA unconfig command for ntpq :config +* PPS and crypto cleanup in ntp_proto.c from Dave Mills. +(4.2.5p165) 2009/04/23 Released by Harlan Stenn +* WWVB refclock cleanup from Dave Mills. +* Code cleanup: requested_key -> request_key. +* [Bug 833] ignore whitespace at end of remote configuration lines +* [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows +* [Bug 1028] Support for W32Time authentication via Samba. +* quiet ntp_parser.c malloc redeclaration warning +* Mitigation and PPS/PPSAPI cleanup from Dave Mills. +* Documentation updates from Dave Mills. +* timepps-Solaris.h patches from Dave Hart. +(4.2.5p164) 2009/04/22 Released by Harlan Stenn +* Include 4.2.4p7-RC3 +* PPS/PPSAPI cleanup from Dave Mills. +* Documentation updates from Dave Mills. +* [Bug 1125] C runtime per-thread initialization on Windows +* [Bug 1152] temporarily disable refclock_parse, refclock_true until + maintainers can repair build break from pps_sample() +* [Bug 1153] refclock_nmea should not mix UTC with GPS time +* [Bug 1159] ntpq overlap diagnostic message test buggy +(4.2.5p163) 2009/04/10 Released by Harlan Stenn +(4.2.5p162) 2009/04/09 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Mitigation and PPS cleanup from Dave Mills. +* Include 4.2.4p7-RC2 +* [Bug 216] New interpolation scheme for Windows eliminates 1ms jitter +* remove a bunch of #ifdef SYS_WINNT from portable code +* 64-bit time_t cleanup for building on newer Windows compilers +* Only set CMOS clock during ntpd exit on Windows if the computer is + shutting down or restarting. +* [Bug 1148] NMEA reference clock improvements +* remove deleted gsoc_sntp/utilities.o from repository so that .o build + products can be cleaned up without corrupting the repository. +(4.2.5p161) 2009/03/31 Released by Harlan Stenn +* Documentation updates from Dave Mills. +(4.2.5p160) 2009/03/30 Released by Harlan Stenn +* [Bug 1141] refclock_report missing braces cause spurious "peer event: + clock clk_unspec" log entries +* Include 4.2.4p7-RC1 +(4.2.5p159) 2009/03/28 Released by Harlan Stenn +* "bias" changes from Dave Mills. +(4.2.5p158) 2009/01/30 Released by Harlan Stenn +* Fix [CID 72], a typo introduced at the latest fix to prettydate.c. +(4.2.5p157) 2009/01/26 Released by Harlan Stenn +* Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills. +(4.2.5p156) 2009/01/19 Released by Harlan Stenn +* [Bug 1118] Fixed sign extension for 32 bit time_t in caljulian() and prettydate(). + Fixed some compiler warnings about missing prototypes. + Fixed some other simple compiler warnings. +* [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c. +* [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it. +* [Bug 1121] [CID 47] double fclose() in ntp-keygen.c. +(4.2.5p155) 2009/01/18 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* CHU frequency updates. +* Design assertion fixes for ntp_crypto.c from Dave Mills. +(4.2.5p154) 2009/01/13 Released by Harlan Stenn +* [Bug 992] support interface event change on Linux from + Miroslav Lichvar. +(4.2.5p153) 2009/01/09 Released by Harlan Stenn +* Renamed gsoc_sntp/:fetch-stubs to gsoc_sntp/fetch-stubs to avoid + file name problems under Windows. + Removed German umlaut from log msg for 4.2.5p142. +(4.2.5p152) 2009/01/08 Released by Harlan Stenn +* Include 4.2.4p6: 2009/01/08 Released by Harlan Stenn +(4.2.5p151) 2008/12/23 Released by Harlan Stenn +* Stats file logging cleanup from Dave Mills. +(4.2.5p150) 2008/12/15 Released by Harlan Stenn +* [Bug 1099] Fixed wrong behaviour in sntp's crypto.c. +* [Bug 1103] Fix 64-bit issues in the new calendar code. +(4.2.5p149) 2008/12/05 Released by Harlan Stenn +* Fixed mismatches in data types and OID definitions in ntpSnmpSubAgent.c +* added a premliminary MIB file to ntpsnmpd (ntpv4-mib.mib) +(4.2.5p148) 2008/12/04 Released by Harlan Stenn +* [Bug 1070] Fix use of ntpq_parsestring() in ntpsnmpd. +(4.2.5p147) 2008/11/27 Released by Harlan Stenn +* Update gsoc_sntp's GCC warning code. +(4.2.5p146) 2008/11/26 Released by Harlan Stenn +* Update Solaris CFLAGS for gsoc_sntp. +(4.2.5p145) 2008/11/20 Released by Harlan Stenn +* Deal with time.h for sntp under linux. +* Provide rpl_malloc() for sntp for systems that need it. +* Handle ss_len and socklen type for sntp. +* Fixes to the sntp configure.ac script. +* Provide INET6_ADDRSTRLEN if it is missing. +* [Bug 1095] overflow in caljulian.c. +(4.2.5p144) 2008/11/19 Released by Harlan Stenn +* Use int32, not int32_t. +* Avoid the sched*() functions under OSF - link problems. +(4.2.5p143) 2008/11/17 Released by Harlan Stenn +* sntp cleanup and fixes. +(4.2.5p142) 2008/11/16 Released by Harlan Stenn +* Imported GSoC SNTP code from Johannes Maximilian Kuehn. +(4.2.5p141) 2008/11/13 Released by Harlan Stenn +* New caltontp.c and calyearstart.c from Juergen Perlinger. +(4.2.5p140) 2008/11/12 Released by Harlan Stenn +* Cleanup lint from the ntp_scanner files. +* [Bug 1011] gmtime() returns NULL on windows where it would not under Unix. +* Updated caljulian.c and prettydate.c from Juergen Perlinger. +(4.2.5p139) 2008/11/11 Released by Harlan Stenn +* Typo fix to driver20.html. +(4.2.5p138) 2008/11/10 Released by Harlan Stenn +* [Bug 474] --disable-ipv6 is broken. +* IPv6 interfaces were being looked for twice. +* SHM driver grabs more samples, add clockstats +* decode.html and driver20.html updates from Dave Mills. +(4.2.5p137) 2008/11/01 Released by Harlan Stenn +* [Bug 1069] #undef netsnmp's PACKAGE_* macros. +* [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize(). +(4.2.5p136) 2008/10/27 Released by Harlan Stenn +* [Bug 1078] statsdir configuration parsing is broken. +(4.2.5p135) 2008/09/23 Released by Harlan Stenn +* [Bug 1072] clock_update should not allow updates older than sys_epoch. +(4.2.5p134) 2008/09/17 Released by Harlan Stenn +* Clean up build process for ntpsnmpd. +(4.2.5p133) 2008/09/16 Released by Harlan Stenn +* Add options processing to ntpsnmpd. +* [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. +* Clean up the libntpq.a build. +* Regenerate ntp_parser.[ch] from ntp_parser.y +(4.2.5p132) 2008/09/15 Released by Harlan Stenn +* [Bug 1067] Multicast DNS service registration must come after the fork + on Solaris. +* [Bug 1066] Error messages should log as errors. +(4.2.5p131) 2008/09/14 Released by Harlan Stenn +* [Bug 1065] Re-enable support for the timingstats file. +(4.2.5p130) 2008/09/13 Released by Harlan Stenn +* [Bug 1064] Implement --with-net-snmp-config=progname +* [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution. +(4.2.5p129) 2008/09/11 Released by Harlan Stenn +* Quiet some libntpq-related warnings. +(4.2.5p128) 2008/09/08 Released by Harlan Stenn +* Import Heiko Gerstung's GSoC2008 NTP MIB daemon. +(4.2.5p127) 2008/09/01 Released by Harlan Stenn +* Regenerate ntpd/ntp_parser.c +(4.2.5p126) 2008/08/31 Released by Harlan Stenn +* Stop libtool-1.5 from looking for C++ or Fortran. +* [BUG 610] Documentation update for NMEA reference clock driver. +* [Bug 828] Fix IPv4/IPv6 address parsing. +* Changes from Dave Mills: + Documentation updates. + Fix a corner case where a frequency update was reported but not set. + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have + crypto_flags. +(4.2.5p125) 2008/08/18 Released by Harlan Stenn +* [Bug 1052] Add linuxPPS support to ONCORE driver. +(4.2.5p124) 2008/08/17 Released by Harlan Stenn +* Documentation updates from Dave Mills. +* Include 4.2.4p5: 2008/08/17 Released by Harlan Stenn +* [Bug 861] leap info was not being transmitted. +* [Bug 1046] refnumtoa.c is using the wrong header file. +* [Bug 1047] enable/disable options processing fix. +* header file cleanup. +* [Bug 1037] buffer in subroutine was 1 byte short. +* configure.ac: cleanup, add option for wintime, and lay the groundwork + for the changes needed for bug 1028. +* Fixes from Dave Mills: 'bias' and 'interleave' work. Separate + phase and frequency discipline (for long poll intervals). Update + TAI function to match current leapsecond processing. +* Documentation updates from Dave Mills. +* [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen. +* Fixed the incorrect edge parameter being passed to time_pps_kcbind in + NMEA refclock driver. +* [Bug 399] NMEA refclock driver does not honor time1 offset if flag3 set. +* [Bug 985] Modifications to NMEA reference clock driver to support Accord + GPS Clock. +* poll time updates from Dave Mills. +* local refclock documentation updates from Dave Mills. +* [Bug 1022] Fix compilation problems with yesterday's commit. +* Updates and cleanup from Dave Mills: + I've now spent eleven months of a sabbatical year - 7 days a week, 6-10 + hours most days - working on NTP. I have carefully reviewed every major + algorithm, examined its original design and evolution from that design. + I've trimmed off dead code and briar patches and did zillions of tests + contrived to expose evil vulnerabilities. The development article is in + rather good shape and should be ready for prime time. + + 1. The protostats statistics files have been very useful in exposing + little twitches and turns when something hiccups, like a broken PPS + signal. Most of what used to be syslog messages are now repackaged as + protostats messages with optional syslog as well. These can also be sent + as traps which might be handy to tiggle a beeper or celltext. These, the + sysstats files and cryptostats files reveal the ambient health of a busy + server, monitor traffic and error counts and spot crypto attacks. + + 2. Close inspection of the clock discipline behavior at long poll + intervals (36 h) showed it not doing as well as it should. I redesigned + the FLL loop to improve nominal accuracy from several tens of + milliseconds to something less than ten milliseconds. + + 3. Autokey (again). The enhanced error checking was becoming a major + pain. I found a way to toss out gobs of ugly fat code and replace the + function with a much simpler and more comprehensive scheme. It resists + bait-and-switch attacks and quickly detect cases when the protocol is + not correctly synchronized. + + 4. The interface code for the kernel PPS signal was not in sync with the + kernel code itself. Some error checks were duplicated and some + ineffective. I found none of the PPS-capable drivers, including the atom + driver, do anything when the prefer peer fails; the kernel PPS signal + remains in control. The atom driver now disables the kernel PPS when the + prefer peer comes bum. This is important when the prefer peer is not a + reference clock but a remote NTP server. + + 5. The flake restrict bit turned out to be really interesting, + especially with symmtric modes and of those especially those using + Autokey. Small changes in the recovery procedures when packets are lost + now avoid almost all scenarios which previously required protocol resets. + + 6. I've always been a little uncomfortable when using the clock filter + with long poll intervals because the samples become less and less + correlated as the sample age exceeds the Allan intercept. Various + schemes have been used over the years to cope with this fact. The latest + one and the one that works the best is to use a modified sort metric + where the delay is used when the age of the sample is less than the + intercept and the sum of delay and dispersion above that. The net result + is that, at small poll intervals the algorithm operates as a minimum + filter, while at larger poll intervals it morphs to FIFO. Left + unmodified, a sample could be used when twelve days old. This along with + the FLL modifications has made a dramatic improvement at large poll + intervals. + +- [Backward Incompatible] The 'state' variable is no longer reported or + available via ntpq output. The following system status bit names + have been changed: + - sync_alarm -> leap_alarm + - sync_atomic -> sync_pps + - sync_lf_clock -> sync_lf_radio + - sync_hf_clock -> sync_hf_radio + - sync_uhf_clock -> sync_uhf_radio + - sync_local_proto -> sync_local + - sync_udp/time -> sync_other + Other names have been changed as well. See the change history for + libntp/statestr.c for more details. + Other backward-incompatible changes in ntpq include: + - assID -> associd + - rootdispersion -> rootdisp + - pkt_head -> pkt_neader + See the change history for other details. + +* Updates and cleanup from Dave Mills. +* [Bug 995] Remove spurious ; from ntp-keygen.c. +* More cleanup and changes from Dave Mills. +* [Bug 980] Direct help to stdout. +--- (4.2.4p8) 2009/12/08 Released by Harlan Stenn * [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. @@ -75,7 +3666,7 @@ --- (4.2.4p6) 2009/01/08 Released by Harlan Stenn -* [Bug 1113] Fixed build errors with recent versions of openSSL. +* [Bug 1113] Fixed build errors with recent versions of openSSL. * [Sec 1111] Fix incorrect check of EVP_VerifyFinal()'s return value. * Update the copyright year. @@ -84,6 +3675,217 @@ * [BUG 1051] Month off by one in leap second message written to clockstats file fixed. +* [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). +* [Bug 1038] Built-in getpass() function also prompts for password if + not built with DEBUG. +* [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. +* [Bug 959] Refclock on Windows not properly releasing recvbuffs. +* [Bug 993] Fix memory leak when fetching system messages. +* much cleanup, fixes, and changes from Dave Mills. +* ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. +* ntp_config.c: ntp_minpoll fixes from Dave Mills. +* ntp-keygen updates from Dave Mills. +* refresh epoch, throttle, and leap cleanup from Dave Mills. +* Documentation cleanup from Dave Mills. +* [Bug 918] Only use a native md5.h if MD5Init() is available. +* [Bug 979] Provide ntptimeval if it is not otherwise present. +* [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork. +* [Bug 952] Use md5 code with a friendlier license. +* [Bug 977] Fix mismatching #ifdefs for builds without IPv6. +* [Bug 830] Fix the checking order of the interface options. +* Clean up the logfile/syslog setup. +* [Bug 970] Lose obsolete -g flag to ntp-keygen. +* The -e flag to ntp-keygen can write GQ keys now, too. +* ntp_proto.c: sys_survivors and hpoll cleanup from Dave Mills. +* ntp_loopfilter.c: sys_poll cleanup from Dave Mills. +* refclock_wwv.c: maximum-likelihood digit and DSYNC fixes from Dave Mills. +* [Bug 967] preemptable associations are lost forever on a step. +* ntp_config.c: [CID 48] missing "else" clause. +* [Bug 833] ntpq config keyword is quote-mark unfriendly. +* Rename the ntpq "config" keyword to ":config". +* Dave Mills shifted some orphan processing. +* Fix typos in the [Bug 963] patch. +* bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown. +* Remove obsolete simulator command-line options. +* ntp_request.c: [CID 36] zero sin_zero. +* [Bug 963] get_systime() is too noisy. +* [Bug 960] spurious syslog:crypto_setup:spurious crypto command +* [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux. +* Changes from Dave Mills: + - ntp_util.c: cleanup. + - ntp_timer.c: watch the non-burst packet rate. + - ntp_request.c: cleanup. + - ntp_restrict.c: RES_LIMITED cleanup. + - ntp_proto.c: RES_LIMITED, rate bucktes, counters, overall cleanup. + - ntp_peer.c: disallow peer_unconfig(). + - ntp_monitor.c: RES_LIMITED cleanup. + - ntp_loopfilter.c: poll interval cleanup. + - ntp_crypto.c: volley -> retry. Cleanup TAI leap message. + - ntp_config: average and minimum are ^2 values. + - ntpdc: unknownversion is really "declined", not "bad version". + - Packet retry cleanup. +* [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice. +* [Bug 957] Windows only: Let command line parameters from the Windows SCM GUI + override the standard parameters from the ImagePath registry key. +* Added HAVE_INT32_T to the Windows config.h to avoid duplicate definitions. +* Work around a VPATH difference in FreeBSD's 'make' command. +* Update bugreport URL. +* Update -I documentation. +* [Bug 713] Fix bug reporting information. +* A bug in the application of the negative-sawtooth for 12 channel receivers. +* The removal of unneeded startup code used for the original LinuxPPS, it now + conforms to the PPSAPI and does not need special code. +* ntp-keygen.c: Coverity fixes [CID 33,47]. +* Volley cleanup from Dave Mills. +* Fuzz cleanup from Dave Mills. +* [Bug 861] Leap second cleanups from Dave Mills. +* ntpsim.c: add missing protypes and fix [CID 34], a nit. +* Upgraded bison at UDel. +* Update br-flock and flock-build machine lists. +* [Bug 752] QoS: add parse/config handling code. +* Fix the #include order in tickadj.c for picky machines. +* [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h. +* [Bug 752] Update the QoS tagging (code only - configuration to follow). +* Orphan mode and other protocol cleanup from Dave Mills. +* Documentation cleanup from Dave Mills. +* [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version. +* more cleanup to ntp_lineeditlibs.m4. +* Documentation updates from Dave Mills. +* -ledit cleanup for ntpdc and ntpq. +* Association and other cleanup from Dave Mills. +* NTP_UNREACH changes from Dave Mills. +* Fix the readline history test. +* [Bug 931] Require -lreadline to be asked for explicitly. +* [Bug 764] When looking for -lreadline support, also try using -lncurses. +* [Bug 909] Fix int32_t errors for ntohl(). +* [Bug 376/214] Enhancements to support multiple if names and IP addresses. +* [Bug 929] int32_t is undefined on Windows. Casting wrong. +* [Bug 928] readlink missing braces. +* [Bug 788] Update macros to support VS 2005. +* ntpd/ntp_timer.c: add missing sys_tai parameter for debug printf +* [Bug 917] config parse leaves files open +* [Bug 912] detect conflicting enable/disable configuration on interfaces + sharing an IP address +* [Bug 771] compare scopeid if available for IPv6 addresses +* Lose obsolete crypto subcommands (Dave Mills). +* WWV is an HF source, not an LF source (Dave Mills). +* [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT. +* [Bug 916] 'cryptosw' is undefined if built without OpenSSL. +* [Bug 891] 'restrict' config file keyword does not work (partial fix). +* [Bug 890] the crypto command seems to be required now. +* [Bug 915] ntpd cores during processing of x509 certificates. +* Crypto lint cleanup from Dave Mills. +* [Bug 897] Check RAND_status() - we may not need a .rnd file. +* Crypto cleanup from Dave Mills. +* [Bug 911] Fix error message in cmd_args.c. +* [Bug 895] Log assertion failures via syslog(), not stderr. +* Documentation updates from Dave Mills. +* Crypto cleanup from Dave Mills. +* [Bug 905] ntp_crypto.c fails to compile without -DDEBUG. +* Avoid double peer stats logging. +* ntp-keygen cleanup from Dave Mills. +* libopts needs to be built after ElectricFence. +* [Bug 894] Initialize keysdir before calling crypto_setup(). +* Calysto cleanup for ntpq. +* ntp-keygen -i takes an arg. +* Cleanup and fixes from Dave Mills. +* [Bug 887] Fix error in ntp_types.h (for sizeof int != 4). +* Bug 880 bug fixes for Windows build +* Improve Calysto support. +* The "revoke" parameter is a crypto command. +* The driftfile wander threshold is a real number. +* [Bug 850] Fix the wander threshold parameter on the driftfile command. +* ntp_io.c: Dead code cleanup - Coverity View 19. +* Leap file related cleanup from Dave Mills. +* ntp_peer.c: Set peer->srcadr before (not after) calling set_peerdstadr(). +* Initialize offset in leap_file() - Coverity View 17. +* Use the correct stratum on KISS codes. +* Fuzz bits cleanup. +* Show more digits in some debug printf's. +* Use drift_file_sw internally to control writing the drift file. +* Implement the wander_threshold option for the driftfile config keyword. +* reformat ntp_control.c; do not use c++ // comments. +* [Bug 629] Undo bug #629 fixes as they cause more problems than were being + solved +* Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, + driftfile write cleanup, packet buffer length checks, documentation updates. +* More assertion checks and malloc()->emalloc(), courtesy of Calysto. +* [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris +* [Bug 862] includefile nesting; preserve phonelist on reconfig. +* [Bug 604] ntpd regularly dies on linux/alpha. +* more leap second infrastructure fixes from Dave Mills. +* [Bug 858] recent leapfile changes broke non-OpenSSL builds. +* Use emalloc() instead of malloc() in refclock_datum.c (Calysto). +* Start using 'design by contract' assertions. +* [Bug 767] Fast sync to refclocks wanted. +* Allow null driftfile. +* Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES. +* [Bug 629] changes to ensure broadcast works including on wildcard addresses +* [Bug 853] get_node() must return a pointer to maximally-aligned memory. +* Initial leap file fixes from Dave Mills. +* [Bug 858] Recent leapfile changes broke without OPENSSL. +* Use a char for DIR_SEP, not a string. +* [Bug 850] driftfile parsing changes. +* driftfile maintenance changes from Dave Mills. Use clock_phi instead of + stats_write_tolerance. +* [Bug 828] refid string not being parsed correctly. +* [Bug 846] Correct includefile parsing. +* [Bug 827] New parsing code does not handle "fudge" correctly. +* Enable debugging capability in the config parser. +* [Bug 839] Crypto password not read from ntp.conf. +* Have autogen produce writable output files. +* [Bug 825] Correct logconfig -/+ keyword processing. +* [Bug 828] Correct parsing of " delimited strings. +* Cleanup FILE * usage after fclose() in ntp_filegen.c. +* [Bug 843] Windows Completion port code was incorrectly merged from -stable. +* [Bug 840] do fudge configuration AFTER peers (thus refclocks) have been + configured. +* [Bug 824] Added new parser modules to the Windows project file. +* [Bug 832] Add libisc/log.c headers to the distribution. +* [Bug 808] Only write the drift file if we are in state 4. +* Initial import of libisc/log.c and friends. +* [Bug 826] Fix redefinition of PI. +* [Bug 825] ntp_scanner.c needs to #include . +* [Bug 824] New parser code has some build problems with the SIM code. +* [Bug 817] Use longnames for setting ntp variables on the command-line; + Allowing '-v' with and without an arg to disambiguate usage is error-prone. +* [Bug 822] set progname once, early. +* [Bug 819] remove erroneous #if 0 in Windows completion port code. +* The new config code missed an #ifdef for building without refclocks. +* Distribute some files needed by the new config parsing code. +* [Bug 819] Timeout for WaitForMultipleObjects was 500ms instead of INFINITE +* Use autogen 5.9.1. +* Fix clktest command-line arg processing.' +* Audio documentation updates from Dave Mills. +* New config file parsing code, from Sachin Kamboj. +* fuzz bit cleanup from Dave Mills. +* replay cleanup from Dave Mills. +* [Bug 542] Tolerate missing directory separator at EO statsdir. +* [Bug 812] ntpd should drop supplementary groups. +* [Bug 815] Fix warning compiling 4.2.5p22 under Windows with VC6. +* [Bug 740] Fix kernel/daemon startup drift anomaly. +* refclock_wwv.c fixes from Dave Mills. +* [Bug 810] Fix ntp-keygen documentation. +* [Bug 787] Bug fixes for 64-bit time_t on Windows. +* [Bug 796] Clean up duplicate #defines in ntp_control.c. +* [Bug 569] Use the correct precision for the Leitch CSD-5300. +* [Bug 795] Moved declaration of variable to top of function. +* [Bug 798] ntpq [p typo crashes ntpq/ntpdc. +* [Bug 786] Fix refclock_bancomm.c on Solaris. +* [Bug 774] parsesolaris.c does not compile under the new Solaris. +* [Bug 782] Remove P() macros from Windows files. +* [Bug 778] ntpd fails to lock with drift=+500 when started with drift=-500. +* [Bug 592] Trimble Thunderbolt GPS support. +* IRIG, CHU, WWV, WWVB refclock improvements from Dave Mills. +* [Bug 757] Lose ULONG_CONST(). +* [Bug 756] Require ANSI C (function prototypes). +* codec (audio) and ICOM changes from Dave Mills. + +--- + * [Bug 450] Windows only: Under original Windows NT we must not discard the wildcard socket to workaround a bug in NT's getsockname(). * [Bug 1038] Built-in getpass() function also prompts for password if @@ -120,7 +3922,6 @@ as under other OSs. * ntpdate.c: Fixed some typos and indents (tabs/spaces). ---- (4.2.4p4) Released by Harlan Stenn * [Bug 902] Fix problems with the -6 flag. @@ -129,33 +3930,43 @@ * [Bug 881] Corrected display of pll offset on 64bit systems. * [Bug 886] Corrected sign handling on 64bit in ntpdc loopinfo command. * [Bug 889] avoid malloc() interrupted by SIGIO risk -* ntpd/refclock_parse.c: cleanup shutdown while the file descriptor is still open. +* ntpd/refclock_parse.c: cleanup shutdown while the file descriptor is still + open. * [Bug 885] use emalloc() to get a message at the end of the memory - unsigned types cannot be less than 0 - default_ai_family is a short - lose trailing , from enum list - clarify ntp_restrict.c for easier automated analysis -* [Bug 884] don't access recv buffers after having them passed to the free list. -* [Bug 882] allow loopback interfaces to share addresses with other interfaces. + unsigned types cannot be less than 0 + default_ai_family is a short + lose trailing , from enum list + clarify ntp_restrict.c for easier automated analysis +* [Bug 884] don't access recv buffers after having them passed to the free + list. +* [Bug 882] allow loopback interfaces to share addresses with other + interfaces. --- (4.2.4p3) Released by Harlan Stenn * [Bug 863] unable to stop ntpd on Windows as the handle reference for events - changed + changed --- (4.2.4p2) Released by Harlan Stenn * [Bug 854] Broadcast address was not correctly set for interface addresses * [Bug 829] reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration. + to reflect the actual configuration. * [Bug 795] Moved declaration of variable to top of function. * [Bug 789] Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. + multicast packets do not disturb the autokey dance. * [Bug 785] improve handling of multicast interfaces - (multicast routers still need to run a multicast routing - software/daemon) + (multicast routers still need to run a multicast routing software/daemon) +* ntpd/refclock_parse.c: cleanup shutdown while the file descriptor is still + open. +* [Bug 885] use emalloc() to get a message at the end of the memory + unsigned types cannot be less than 0 + default_ai_family is a short + lose trailing , from enum list +* [Bug 884] don't access recv buffers after having them passed to the free list. +* [Bug 882] allow loopback interfaces to share addresses with other interfaces. * [Bug 527] Don't write from source address length to wrong location * Upgraded autogen and libopts. * [Bug 811] ntpd should not read a .ntprc file. @@ -249,52 +4060,52 @@ --- (4.2.2p4) Released by Harlan Stenn - * [Bug 710] compat getnameinfo() has off-by-one error - * [Bug 690] Buffer overflow in Windows when doing DNS Lookups +* [Bug 710] compat getnameinfo() has off-by-one error +* [Bug 690] Buffer overflow in Windows when doing DNS Lookups --- (4.2.2p3) Released by Harlan Stenn - * Make the ChangeLog file cleaner and easier to read - * [Bug 601] ntpq's decodeint uses an extra level of indirection - * [Bug 657] Different OSes need different sized args for IP_MULTICAST_LOOP - * release engineering/build changes - * Documentation fixes - * Get sntp working under AIX-5 +* Make the ChangeLog file cleaner and easier to read +* [Bug 601] ntpq's decodeint uses an extra level of indirection +* [Bug 657] Different OSes need different sized args for IP_MULTICAST_LOOP +* release engineering/build changes +* Documentation fixes +* Get sntp working under AIX-5 --- (4.2.2p2) (broken) - * Get sntp working under AIX-5 +* Get sntp working under AIX-5 --- (4.2.2p1) - * [Bug 661] Use environment variable to specify the base path to openssl. - * Resolve an ambiguity in the copyright notice - * Added some new documentation files - * URL cleanup in the documentation - * [Bug 657]: IP_MULTICAST_LOOP uses a u_char value/size - * quiet gcc4 complaints - * more Coverity fixes - * [Bug 614] manage file descriptors better - * [Bug 632] update kernel PPS offsets when PPS offset is re-configured - * [Bug 637] Ignore UP in*addr_any interfaces - * [Bug 633] Avoid writing files in srcdir - * release engineering/build changes +* [Bug 661] Use environment variable to specify the base path to openssl. +* Resolve an ambiguity in the copyright notice +* Added some new documentation files +* URL cleanup in the documentation +* [Bug 657]: IP_MULTICAST_LOOP uses a u_char value/size +* quiet gcc4 complaints +* more Coverity fixes +* [Bug 614] manage file descriptors better +* [Bug 632] update kernel PPS offsets when PPS offset is re-configured +* [Bug 637] Ignore UP in*addr_any interfaces +* [Bug 633] Avoid writing files in srcdir +* release engineering/build changes --- (4.2.2) - * SNTP - * Many bugfixes - * Implements the current "goal state" of NTPv4 - * Autokey improvements - * Much better IPv6 support - * [Bug 360] ntpd loses handles with LAN connection disabled. - * [Bug 239] Fix intermittent autokey failure with multicast clients. - * Rewrite of the multicast code - * New version numbering scheme +* SNTP +* Many bugfixes +* Implements the current "goal state" of NTPv4 +* Autokey improvements +* Much better IPv6 support +* [Bug 360] ntpd loses handles with LAN connection disabled. +* [Bug 239] Fix intermittent autokey failure with multicast clients. +* Rewrite of the multicast code +* New version numbering scheme --- (4.2.0) diff --git a/contrib/ntp/CommitLog b/contrib/ntp/CommitLog index ade3be704..3366f2ff1 100644 --- a/contrib/ntp/CommitLog +++ b/contrib/ntp/CommitLog @@ -1,7407 +1,188174 @@ -ChangeSet@1.1612, 2009-12-08 08:30:54-05:00, stenn@whimsy.udel.edu +1 -0 - ChangeLog: - typo +ChangeSet@1.3577, 2015-10-21 12:42:02-04:00, stenn@deacon.udel.edu + NTP_4_2_8P4 + TAG: NTP_4_2_8P4 - ChangeLog@1.95, 2009-12-08 08:30:44-05:00, stenn@whimsy.udel.edu +0 -1 - typo + ChangeLog@1.1757 +1 -0 + NTP_4_2_8P4 -ChangeSet@1.1611, 2009-12-08 08:23:12-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P8 - TAG: NTP_4_2_4P8 + ntpd/invoke-ntp.conf.texi@1.193 +1 -1 + NTP_4_2_8P4 - ChangeLog@1.94, 2009-12-08 08:23:01-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P8 + ntpd/invoke-ntp.keys.texi@1.185 +1 -1 + NTP_4_2_8P4 - ntpd/ntpd-opts.c@1.86, 2009-12-08 08:23:02-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/invoke-ntpd.texi@1.502 +2 -2 + NTP_4_2_8P4 - ntpd/ntpd-opts.h@1.86, 2009-12-08 08:23:02-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpd/ntp.conf.5man@1.227 +3 -3 + NTP_4_2_8P4 - ntpd/ntpd-opts.texi@1.85, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpd/ntp.conf.5mdoc@1.227 +2 -2 + NTP_4_2_8P4 - ntpd/ntpd.1@1.84, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntp.conf.html@1.181 +94 -107 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.c@1.86, 2009-12-08 08:23:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntp.conf.man.in@1.227 +3 -3 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.h@1.86, 2009-12-08 08:23:04-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpd/ntp.conf.mdoc.in@1.227 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.texi@1.84, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpd/ntp.keys.5man@1.219 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim.1@1.84, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntp.keys.5mdoc@1.219 +3 -3 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.c@1.86, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntp.keys.html@1.181 +21 -33 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.h@1.86, 2009-12-08 08:23:05-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpd/ntp.keys.man.in@1.219 +2 -2 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.texi@1.84, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpd/ntp.keys.mdoc.in@1.219 +3 -3 + NTP_4_2_8P4 - ntpdc/ntpdc.1@1.84, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntpd-opts.c@1.524 +245 -245 + NTP_4_2_8P4 - ntpq/ntpq-opts.c@1.88, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntpd-opts.h@1.523 +3 -3 + NTP_4_2_8P4 - ntpq/ntpq-opts.h@1.88, 2009-12-08 08:23:06-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpd/ntpd.1ntpdman@1.331 +3 -3 + NTP_4_2_8P4 - ntpq/ntpq-opts.texi@1.85, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpd/ntpd.1ntpdmdoc@1.331 +2 -2 + NTP_4_2_8P4 - ntpq/ntpq.1@1.84, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntpd.html@1.175 +142 -186 + NTP_4_2_8P4 - packageinfo.sh@1.118, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P8 + ntpd/ntpd.man.in@1.331 +3 -3 + NTP_4_2_8P4 - sntp/sntp-opts.c@1.84, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpd/ntpd.mdoc.in@1.331 +2 -2 + NTP_4_2_8P4 - sntp/sntp-opts.h@1.84, 2009-12-08 08:23:07-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpdc/invoke-ntpdc.texi@1.499 +2 -2 + NTP_4_2_8P4 - sntp/sntp-opts.texi@1.81, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpdc/ntpdc-opts.c@1.517 +107 -107 + NTP_4_2_8P4 - sntp/sntp.1@1.84, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpdc/ntpdc-opts.h@1.516 +3 -3 + NTP_4_2_8P4 - util/ntp-keygen-opts.c@1.85, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpdc/ntpdc.1ntpdcman@1.330 +3 -3 + NTP_4_2_8P4 - util/ntp-keygen-opts.h@1.85, 2009-12-08 08:23:08-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P8 + ntpdc/ntpdc.1ntpdcmdoc@1.330 +2 -2 + NTP_4_2_8P4 - util/ntp-keygen-opts.texi@1.83, 2009-12-08 08:23:09-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P8 + ntpdc/ntpdc.html@1.343 +75 -95 + NTP_4_2_8P4 - util/ntp-keygen.1@1.83, 2009-12-08 08:23:09-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P8 + ntpdc/ntpdc.man.in@1.330 +3 -3 + NTP_4_2_8P4 -ChangeSet@1.1610, 2009-12-08 07:45:28-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P9_RC1 - TAG: NTP_4_2_4P9_RC1 + ntpdc/ntpdc.mdoc.in@1.330 +2 -2 + NTP_4_2_8P4 - ChangeLog@1.93, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P9_RC1 + ntpq/invoke-ntpq.texi@1.506 +2 -2 + NTP_4_2_8P4 - ntpd/ntpd-opts.c@1.85, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpq/ntpq-opts.c@1.523 +106 -106 + NTP_4_2_8P4 - ntpd/ntpd-opts.h@1.85, 2009-12-08 07:45:19-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpq/ntpq-opts.h@1.521 +3 -3 + NTP_4_2_8P4 - ntpd/ntpd-opts.texi@1.84, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +13 -6 - NTP_4_2_4P9_RC1 + ntpq/ntpq.1ntpqman@1.334 +3 -3 + NTP_4_2_8P4 - ntpd/ntpd.1@1.83, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpq/ntpq.1ntpqmdoc@1.334 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.c@1.85, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpq/ntpq.html@1.172 +132 -155 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.h@1.85, 2009-12-08 07:45:20-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpq/ntpq.man.in@1.334 +3 -3 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.texi@1.83, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +61 -2 - NTP_4_2_4P9_RC1 + ntpq/ntpq.mdoc.in@1.334 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim.1@1.83, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpsnmpd/invoke-ntpsnmpd.texi@1.501 +2 -2 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.c@1.85, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpsnmpd/ntpsnmpd-opts.c@1.519 +68 -68 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.h@1.85, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpsnmpd/ntpsnmpd-opts.h@1.518 +3 -3 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.texi@1.83, 2009-12-08 07:45:21-05:00, stenn@whimsy.udel.edu +7 -4 - NTP_4_2_4P9_RC1 + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.330 +3 -3 + NTP_4_2_8P4 - ntpdc/ntpdc.1@1.83, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.330 +2 -2 + NTP_4_2_8P4 - ntpq/ntpq-opts.c@1.87, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + ntpsnmpd/ntpsnmpd.html@1.170 +10 -14 + NTP_4_2_8P4 - ntpq/ntpq-opts.h@1.87, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + ntpsnmpd/ntpsnmpd.man.in@1.330 +3 -3 + NTP_4_2_8P4 - ntpq/ntpq-opts.texi@1.84, 2009-12-08 07:45:22-05:00, stenn@whimsy.udel.edu +8 -4 - NTP_4_2_4P9_RC1 + ntpsnmpd/ntpsnmpd.mdoc.in@1.330 +2 -2 + NTP_4_2_8P4 - ntpq/ntpq.1@1.83, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + packageinfo.sh@1.520 +3 -3 + NTP_4_2_8P4 - packageinfo.sh@1.117, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P9_RC1 + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.91 +3 -3 + NTP_4_2_8P4 - sntp/sntp-opts.c@1.83, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.92 +2 -2 + NTP_4_2_8P4 - sntp/sntp-opts.h@1.83, 2009-12-08 07:45:23-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + scripts/calc_tickadj/calc_tickadj.html@1.93 +30 -42 + NTP_4_2_8P4 - sntp/sntp-opts.texi@1.80, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +54 -2 - NTP_4_2_4P9_RC1 + scripts/calc_tickadj/calc_tickadj.man.in@1.90 +3 -3 + NTP_4_2_8P4 - sntp/sntp.1@1.83, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.92 +2 -2 + NTP_4_2_8P4 - util/ntp-keygen-opts.c@1.84, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +5 -5 - NTP_4_2_4P9_RC1 + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.95 +1 -1 + NTP_4_2_8P4 - util/ntp-keygen-opts.h@1.84, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + scripts/invoke-plot_summary.texi@1.112 +2 -2 + NTP_4_2_8P4 - util/ntp-keygen-opts.texi@1.82, 2009-12-08 07:45:24-05:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P9_RC1 + scripts/invoke-summary.texi@1.112 +2 -2 + NTP_4_2_8P4 - util/ntp-keygen.1@1.82, 2009-12-08 07:45:25-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P9_RC1 + scripts/ntp-wait/invoke-ntp-wait.texi@1.322 +2 -2 + NTP_4_2_8P4 -ChangeSet@1.1609, 2009-12-08 05:36:47-05:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + scripts/ntp-wait/ntp-wait-opts@1.58 +2 -2 + NTP_4_2_8P4 - NEWS@1.102, 2009-12-08 05:36:36-05:00, stenn@whimsy.udel.edu +34 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.319 +3 -3 + NTP_4_2_8P4 - packageinfo.sh@1.116, 2009-12-08 05:36:36-05:00, stenn@whimsy.udel.edu +2 -2 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.320 +2 -2 + NTP_4_2_8P4 -ChangeSet@1.1608, 2009-10-07 01:33:22+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + scripts/ntp-wait/ntp-wait.html@1.339 +41 -59 + NTP_4_2_8P4 - ChangeLog@1.92, 2009-10-07 01:33:21+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + scripts/ntp-wait/ntp-wait.man.in@1.319 +3 -3 + NTP_4_2_8P4 - ntpd/ntp_request.c@1.68, 2009-10-07 01:33:21+00:00, davehart@shiny.ad.hartbrothers.com +9 -2 - [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + scripts/ntp-wait/ntp-wait.mdoc.in@1.320 +2 -2 + NTP_4_2_8P4 -ChangeSet@1.1607, 2009-05-18 05:04:41-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7 - TAG: NTP_4_2_4P7 + scripts/ntpsweep/invoke-ntpsweep.texi@1.110 +2 -2 + NTP_4_2_8P4 - ChangeLog@1.91, 2009-05-18 05:04:18-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7 + scripts/ntpsweep/ntpsweep-opts@1.60 +2 -2 + NTP_4_2_8P4 - ntpd/ntpd-opts.c@1.84, 2009-05-18 05:04:19-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.98 +3 -3 + NTP_4_2_8P4 - ntpd/ntpd-opts.h@1.84, 2009-05-18 05:04:20-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.98 +2 -2 + NTP_4_2_8P4 - ntpd/ntpd-opts.texi@1.83, 2009-05-18 05:04:21-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + scripts/ntpsweep/ntpsweep.html@1.111 +46 -57 + NTP_4_2_8P4 - ntpd/ntpd.1@1.82, 2009-05-18 05:04:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/ntpsweep/ntpsweep.man.in@1.98 +3 -3 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.c@1.84, 2009-05-18 05:04:22-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/ntpsweep/ntpsweep.mdoc.in@1.99 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.h@1.84, 2009-05-18 05:04:23-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/ntptrace/invoke-ntptrace.texi@1.111 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.texi@1.82, 2009-05-18 05:04:24-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + scripts/ntptrace/ntptrace-opts@1.60 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim.1@1.82, 2009-05-18 05:04:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/ntptrace/ntptrace.1ntptraceman@1.98 +3 -3 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.c@1.84, 2009-05-18 05:04:26-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/ntptrace/ntptrace.1ntptracemdoc@1.99 +2 -2 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.h@1.84, 2009-05-18 05:04:26-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/ntptrace/ntptrace.html@1.112 +38 -47 + NTP_4_2_8P4 - ntpdc/ntpdc-opts.texi@1.82, 2009-05-18 05:04:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + scripts/ntptrace/ntptrace.man.in@1.98 +3 -3 + NTP_4_2_8P4 - ntpdc/ntpdc.1@1.82, 2009-05-18 05:04:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/ntptrace/ntptrace.mdoc.in@1.100 +2 -2 + NTP_4_2_8P4 - ntpq/ntpq-opts.c@1.86, 2009-05-18 05:04:29-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/plot_summary-opts@1.60 +2 -2 + NTP_4_2_8P4 - ntpq/ntpq-opts.h@1.86, 2009-05-18 05:04:29-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/plot_summary.1plot_summaryman@1.110 +3 -3 + NTP_4_2_8P4 - ntpq/ntpq-opts.texi@1.83, 2009-05-18 05:04:30-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + scripts/plot_summary.1plot_summarymdoc@1.110 +2 -2 + NTP_4_2_8P4 - ntpq/ntpq.1@1.82, 2009-05-18 05:04:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/plot_summary.html@1.113 +40 -58 + NTP_4_2_8P4 - packageinfo.sh@1.115, 2009-05-18 05:04:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/plot_summary.man.in@1.110 +3 -3 + NTP_4_2_8P4 - sntp/sntp-opts.c@1.82, 2009-05-18 05:04:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/plot_summary.mdoc.in@1.110 +2 -2 + NTP_4_2_8P4 - sntp/sntp-opts.h@1.82, 2009-05-18 05:04:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7 + scripts/summary-opts@1.60 +2 -2 + NTP_4_2_8P4 - sntp/sntp-opts.texi@1.79, 2009-05-18 05:04:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + scripts/summary.1summaryman@1.110 +3 -3 + NTP_4_2_8P4 - sntp/sntp.1@1.82, 2009-05-18 05:04:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/summary.1summarymdoc@1.110 +2 -2 + NTP_4_2_8P4 - util/ntp-keygen-opts.c@1.83, 2009-05-18 05:04:35-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/summary.html@1.113 +37 -49 + NTP_4_2_8P4 - util/ntp-keygen-opts.h@1.83, 2009-05-18 05:04:36-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P7 + scripts/summary.man.in@1.110 +3 -3 + NTP_4_2_8P4 - util/ntp-keygen-opts.texi@1.81, 2009-05-18 05:04:37-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7 + scripts/summary.mdoc.in@1.110 +2 -2 + NTP_4_2_8P4 - util/ntp-keygen.1@1.81, 2009-05-18 05:04:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7 + scripts/update-leap/invoke-update-leap.texi@1.11 +1 -1 + NTP_4_2_8P4 -ChangeSet@1.1606, 2009-05-18 03:14:59-04:00, stenn@whimsy.udel.edu +2 -0 - 4.2.4p7 + scripts/update-leap/update-leap-opts@1.11 +2 -2 + NTP_4_2_8P4 - NEWS@1.101, 2009-05-18 03:14:49-04:00, stenn@whimsy.udel.edu +38 -0 - 4.2.4p7 + scripts/update-leap/update-leap.1update-leapman@1.11 +3 -3 + NTP_4_2_8P4 - packageinfo.sh@1.114, 2009-05-18 03:14:50-04:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p7 + scripts/update-leap/update-leap.1update-leapmdoc@1.11 +2 -2 + NTP_4_2_8P4 -ChangeSet@1.1605, 2009-05-18 02:56:36-04:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + scripts/update-leap/update-leap.html@1.11 +48 -72 + NTP_4_2_8P4 - ChangeLog@1.90, 2009-05-18 02:56:22-04:00, stenn@whimsy.udel.edu +1 -0 - [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + scripts/update-leap/update-leap.man.in@1.11 +3 -3 + NTP_4_2_8P4 - ntpd/ntp_crypto.c@1.110, 2009-05-18 02:56:22-04:00, stenn@whimsy.udel.edu +22 -17 - [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + scripts/update-leap/update-leap.mdoc.in@1.11 +2 -2 + NTP_4_2_8P4 -ChangeSet@1.1604, 2009-05-18 02:24:31-04:00, stenn@whimsy.udel.edu +2 -0 - [Bug 1187] Update the copyright date. + sntp/invoke-sntp.texi@1.499 +2 -2 + NTP_4_2_8P4 - ChangeLog@1.89, 2009-05-18 02:24:21-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 1187] Update the copyright date. + sntp/sntp-opts.c@1.518 +159 -159 + NTP_4_2_8P4 - include/copyright.def@1.8, 2009-05-18 02:24:22-04:00, stenn@whimsy.udel.edu +1 -1 - [Bug 1187] Update the copyright date. + sntp/sntp-opts.h@1.516 +3 -3 + NTP_4_2_8P4 -ChangeSet@1.1603, 2009-05-17 08:59:06+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix - for [Sec 1149]. + sntp/sntp.1sntpman@1.334 +3 -3 + NTP_4_2_8P4 - ChangeLog@1.88, 2009-05-17 08:59:05+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 - [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix - for [Sec 1149]. + sntp/sntp.1sntpmdoc@1.334 +2 -2 + NTP_4_2_8P4 - ntpd/ntp_io.c@1.261, 2009-05-17 08:59:05+00:00, davehart@shiny.ad.hartbrothers.com +45 -34 - [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix - for [Sec 1149]. + sntp/sntp.html@1.514 +111 -135 + NTP_4_2_8P4 -ChangeSet@1.1602, 2009-05-14 04:42:10+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - fix error from BitKeeper/triggers/pre-resolve.licfix triggered (ahem) - by recent BitKeeper/etc/config delta updating repologs email address + sntp/sntp.man.in@1.334 +3 -3 + NTP_4_2_8P4 - BitKeeper/triggers/pre-resolve.licfix@1.5, 2009-05-14 04:42:09+00:00, davehart@shiny.ad.hartbrothers.com +4 -1 - bk sccscat has been removed, replaced by bk annotate -R - -q grep -> grep -q (untested until recent BitKeeper/etc/config commit - changing repologs@ntp.isc.org to repologs@ntp.org + sntp/sntp.mdoc.in@1.334 +2 -2 + NTP_4_2_8P4 -ChangeSet@1.1601, 2009-05-12 02:41:56-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC7 - TAG: NTP_4_2_4P7_RC7 + util/invoke-ntp-keygen.texi@1.502 +2 -2 + NTP_4_2_8P4 - ChangeLog@1.87, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC7 + util/ntp-keygen-opts.c@1.520 +173 -173 + NTP_4_2_8P4 - ntpd/ntpd-opts.c@1.83, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen-opts.h@1.518 +3 -3 + NTP_4_2_8P4 - ntpd/ntpd-opts.h@1.83, 2009-05-12 02:41:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen.1ntp-keygenman@1.330 +3 -3 + NTP_4_2_8P4 - ntpd/ntpd-opts.texi@1.82, 2009-05-12 02:41:35-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + util/ntp-keygen.1ntp-keygenmdoc@1.330 +2 -2 + NTP_4_2_8P4 - ntpd/ntpd.1@1.81, 2009-05-12 02:41:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen.html@1.176 +157 -216 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.c@1.83, 2009-05-12 02:41:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen.man.in@1.330 +3 -3 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.h@1.83, 2009-05-12 02:41:37-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + util/ntp-keygen.mdoc.in@1.330 +2 -2 + NTP_4_2_8P4 - ntpd/ntpdsim-opts.texi@1.81, 2009-05-12 02:41:37-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 +ChangeSet@1.3576, 2015-10-21 11:58:26-04:00, stenn@deacon.udel.edu + 4.2.8p4 - ntpd/ntpdsim.1@1.81, 2009-05-12 02:41:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + packageinfo.sh@1.519 +1 -1 + 4.2.8p4 - ntpdc/ntpdc-opts.c@1.83, 2009-05-12 02:41:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 +ChangeSet@1.3575, 2015-10-21 15:35:31+00:00, stenn@psp-deb1.ntp.org + Update severity information - ntpdc/ntpdc-opts.h@1.83, 2009-05-12 02:41:40-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + NEWS@1.150 +2 -2 + Update severity information - ntpdc/ntpdc-opts.texi@1.81, 2009-05-12 02:41:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 +ChangeSet@1.3574, 2015-10-20 08:00:43+00:00, stenn@psp-deb1.ntp.org + Update CVEs - ntpdc/ntpdc.1@1.81, 2009-05-12 02:41:42-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + NEWS@1.149 +16 -16 + Update CVEs - ntpq/ntpq-opts.c@1.85, 2009-05-12 02:41:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 +ChangeSet@1.3573, 2015-10-17 06:28:49+00:00, stenn@psp-deb1.ntp.org + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.h@1.85, 2009-05-12 02:41:44-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + NEWS@1.148 +336 -4 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.texi@1.82, 2009-05-12 02:41:45-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpd/invoke-ntp.conf.texi@1.192 +1 -1 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq.1@1.81, 2009-05-12 02:41:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/invoke-ntp.keys.texi@1.184 +1 -1 + ntp-4.2.8p4-sec-RC2 - packageinfo.sh@1.113, 2009-05-12 02:41:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpd/invoke-ntpd.texi@1.501 +2 -2 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.c@1.81, 2009-05-12 02:41:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntp.conf.5man@1.226 +3 -3 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.h@1.81, 2009-05-12 02:41:48-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntp.conf.5mdoc@1.226 +2 -2 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.texi@1.78, 2009-05-12 02:41:49-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpd/ntp.conf.html@1.180 +107 -94 + ntp-4.2.8p4-sec-RC2 - sntp/sntp.1@1.81, 2009-05-12 02:41:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntp.conf.man.in@1.226 +3 -3 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.c@1.82, 2009-05-12 02:41:51-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntp.conf.mdoc.in@1.226 +2 -2 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.h@1.82, 2009-05-12 02:41:51-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntp.keys.5man@1.218 +2 -2 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.texi@1.80, 2009-05-12 02:41:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC7 + ntpd/ntp.keys.5mdoc@1.218 +3 -3 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen.1@1.80, 2009-05-12 02:41:53-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC7 + ntpd/ntp.keys.html@1.180 +33 -21 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1600, 2009-05-12 01:07:37-04:00, stenn@whimsy.udel.edu +9 -0 - ntp.isc.org -> ntp.org cleanup + ntpd/ntp.keys.man.in@1.218 +2 -2 + ntp-4.2.8p4-sec-RC2 - BitKeeper/etc/config@1.10, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpd/ntp.keys.mdoc.in@1.218 +3 -3 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.86, 2009-05-12 01:06:01-04:00, stenn@whimsy.udel.edu +1 -0 - ntp.isc.org -> ntp.org cleanup + ntpd/ntpd-opts.c@1.523 +245 -245 + ntp-4.2.8p4-sec-RC2 - README@1.23, 2009-05-12 01:06:02-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpd/ntpd-opts.h@1.522 +3 -3 + ntp-4.2.8p4-sec-RC2 - README.bk@1.19, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpd/ntpd.1ntpdman@1.330 +3 -3 + ntp-4.2.8p4-sec-RC2 - README.patches@1.4, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpd/ntpd.1ntpdmdoc@1.330 +2 -2 + ntp-4.2.8p4-sec-RC2 - WHERE-TO-START@1.7, 2009-05-12 01:06:03-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpd/ntpd.html@1.174 +186 -142 + ntp-4.2.8p4-sec-RC2 - configure.ac@1.418, 2009-05-12 01:06:04-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpd/ntpd.man.in@1.330 +3 -3 + ntp-4.2.8p4-sec-RC2 - include/copyright.def@1.7, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpd/ntpd.mdoc.in@1.330 +2 -2 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.def@1.11, 2009-05-12 01:06:49-04:00, stenn@whimsy.udel.edu +1 -1 - ntp.isc.org -> ntp.org cleanup + ntpdc/invoke-ntpdc.texi@1.498 +2 -2 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1597.1.1, 2009-05-08 18:11:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - correct help text + ntpdc/ntpdc-opts.c@1.516 +107 -107 + ntp-4.2.8p4-sec-RC2 - configure.ac@1.415.1.1, 2009-05-08 18:11:24+00:00, davehart@shiny.ad.hartbrothers.com +11 -5 - correct help text + ntpdc/ntpdc-opts.h@1.515 +3 -3 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1598, 2009-05-08 17:50:37+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - add configure --enable-ignore-dns-errors to retry on any failure + ntpdc/ntpdc.1ntpdcman@1.329 +3 -3 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.85, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -1 - add configure --enable-ignore-dns-errors to retry on any failure + ntpdc/ntpdc.1ntpdcmdoc@1.329 +2 -2 + ntp-4.2.8p4-sec-RC2 - configure.ac@1.416, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +26 -4 - add configure --enable-ignore-dns-errors to retry on any failure + ntpdc/ntpdc.html@1.342 +95 -75 + ntp-4.2.8p4-sec-RC2 - ntpd/ntp_intres.c@1.55, 2009-05-08 17:50:35+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - add configure --enable-ignore-dns-errors to retry on any failure + ntpdc/ntpdc.man.in@1.329 +3 -3 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1597, 2009-05-08 15:34:46+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - Do not exceed FD_SETSIZE in ntp_intres.c - --- - ntp_intres.c: - typo - --- - ntp_intres.c: - missing comma typo - --- - ntp_intres.c: - typo + ntpdc/ntpdc.mdoc.in@1.329 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntp_intres.c@1.54, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +64 -33 - fix typos, refine "host name not found" log message, stay under FD_SETSIZE + ntpq/invoke-ntpq.texi@1.505 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntp_request.c@1.67, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +21 -3 - after ntp_intres adds a server entry, rescan interfaces, to notice the - return of connectivity sooner. + ntpq/ntpq-opts.c@1.522 +106 -106 + ntp-4.2.8p4-sec-RC2 - ntpd/ntp_timer.c@1.34, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 - indent cleanup + ntpq/ntpq-opts.h@1.520 +3 -3 + ntp-4.2.8p4-sec-RC2 - ports/winnt/include/config.h@1.52, 2009-05-08 15:34:45+00:00, davehart@shiny.ad.hartbrothers.com +4 -10 - remove FORCE_DNSRETRY, no longer used - indent cleanup + ntpq/ntpq.1ntpqman@1.333 +3 -3 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1587.1.1, 2009-05-08 11:24:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + ntpq/ntpq.1ntpqmdoc@1.333 +2 -2 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.76.1.1, 2009-05-08 11:24:42+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + ntpq/ntpq.html@1.171 +155 -132 + ntp-4.2.8p4-sec-RC2 - ntpd/ntp_intres.c@1.53, 2009-05-08 11:24:42+00:00, davehart@shiny.ad.hartbrothers.com +53 -55 - [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + ntpq/ntpq.man.in@1.333 +3 -3 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1595, 2009-05-08 04:42:52-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC6 - TAG: NTP_4_2_4P7_RC6 + ntpq/ntpq.mdoc.in@1.333 +2 -2 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.83, 2009-05-08 04:42:28-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC6 + ntpsnmpd/invoke-ntpsnmpd.texi@1.500 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd-opts.c@1.82, 2009-05-08 04:42:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd-opts.c@1.518 +68 -68 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd-opts.h@1.82, 2009-05-08 04:42:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd-opts.h@1.517 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd-opts.texi@1.81, 2009-05-08 04:42:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.329 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd.1@1.80, 2009-05-08 04:42:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.329 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim-opts.c@1.82, 2009-05-08 04:42:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd.html@1.169 +14 -10 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim-opts.h@1.82, 2009-05-08 04:42:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd.man.in@1.329 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim-opts.texi@1.80, 2009-05-08 04:42:33-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC6 + ntpsnmpd/ntpsnmpd.mdoc.in@1.329 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim.1@1.80, 2009-05-08 04:42:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + packageinfo.sh@1.518 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc-opts.c@1.82, 2009-05-08 04:42:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.90 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc-opts.h@1.82, 2009-05-08 04:42:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.91 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc-opts.texi@1.80, 2009-05-08 04:42:36-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/calc_tickadj/calc_tickadj.html@1.92 +42 -30 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc.1@1.80, 2009-05-08 04:42:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/calc_tickadj/calc_tickadj.man.in@1.89 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.c@1.84, 2009-05-08 04:42:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.91 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.h@1.84, 2009-05-08 04:42:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.94 +1 -1 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.texi@1.81, 2009-05-08 04:42:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/invoke-plot_summary.texi@1.111 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq.1@1.80, 2009-05-08 04:42:41-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/invoke-summary.texi@1.111 +2 -2 + ntp-4.2.8p4-sec-RC2 - packageinfo.sh@1.112, 2009-05-08 04:42:42-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC6 + scripts/ntp-wait/invoke-ntp-wait.texi@1.321 +2 -2 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.c@1.80, 2009-05-08 04:42:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/ntp-wait/ntp-wait-opts@1.57 +2 -2 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.h@1.80, 2009-05-08 04:42:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.318 +3 -3 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.texi@1.77, 2009-05-08 04:42:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC6 + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.319 +2 -2 + ntp-4.2.8p4-sec-RC2 - sntp/sntp.1@1.80, 2009-05-08 04:42:44-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/ntp-wait/ntp-wait.html@1.338 +59 -41 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.c@1.81, 2009-05-08 04:42:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/ntp-wait/ntp-wait.man.in@1.318 +3 -3 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.h@1.81, 2009-05-08 04:42:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC6 + scripts/ntp-wait/ntp-wait.mdoc.in@1.319 +2 -2 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.texi@1.79, 2009-05-08 04:42:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/ntpsweep/invoke-ntpsweep.texi@1.109 +2 -2 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen.1@1.79, 2009-05-08 04:42:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC6 + scripts/ntpsweep/ntpsweep-opts@1.59 +2 -2 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1594, 2009-05-08 03:29:16-04:00, stenn@pogo.udel.edu +1 -0 - typo + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.97 +3 -3 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.82, 2009-05-08 03:28:46-04:00, stenn@pogo.udel.edu +1 -1 - typo + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.97 +2 -2 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1593, 2009-05-08 02:13:17+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - Add [Bug 1071] reference to ChangeLog entry + scripts/ntpsweep/ntpsweep.html@1.110 +57 -46 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.81, 2009-05-08 02:13:16+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 - [Bug 1071] Log a message and exit before trying to use FD_SET with a - descriptor larger than FD_SETSIZE, which will corrupt memory - (adds reference to 1071 to existing description) + scripts/ntpsweep/ntpsweep.man.in@1.97 +3 -3 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1592, 2009-05-08 01:23:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1179] error messages for -u/--user and -i when built w/o droproot + scripts/ntpsweep/ntpsweep.mdoc.in@1.98 +2 -2 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.80, 2009-05-08 01:23:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1179] error messages for -u/--user and -i when built w/o droproot + scripts/ntptrace/invoke-ntptrace.texi@1.110 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/cmd_args.c@1.49, 2009-05-08 01:23:41+00:00, davehart@shiny.ad.hartbrothers.com +39 -19 - descriptive error messages for -u/--user and -i without droproot + scripts/ntptrace/ntptrace-opts@1.59 +2 -2 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1591, 2009-05-07 22:15:41+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - ntp_io.c: do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + scripts/ntptrace/ntptrace.1ntptraceman@1.97 +3 -3 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.79, 2009-05-07 22:15:39+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + scripts/ntptrace/ntptrace.1ntptracemdoc@1.98 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntp_io.c@1.260, 2009-05-07 22:15:39+00:00, davehart@shiny.ad.hartbrothers.com +23 -0 - do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + scripts/ntptrace/ntptrace.html@1.111 +47 -38 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1590, 2009-05-07 07:39:41+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - refclock_jjy.c: - add missing newline before EOF + scripts/ntptrace/ntptrace.man.in@1.97 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpd/refclock_jjy.c@1.15, 2009-05-07 07:39:32+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - add missing newline before EOF + scripts/ntptrace/ntptrace.mdoc.in@1.99 +2 -2 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1589, 2009-05-07 05:19:36+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - [Bug 784] Make --enable-linuxcaps the default when available - add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj + scripts/plot_summary-opts@1.59 +2 -2 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.78, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 784] Make --enable-linuxcaps the default when available + scripts/plot_summary.1plot_summaryman@1.109 +3 -3 + ntp-4.2.8p4-sec-RC2 - configure.ac@1.415, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +34 -33 - [Bug 784] Make --enable-linuxcaps the default when available + scripts/plot_summary.1plot_summarymdoc@1.109 +2 -2 + ntp-4.2.8p4-sec-RC2 - ports/winnt/ntpd/ntpd.vcproj@1.2, 2009-05-07 05:19:34+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj + scripts/plot_summary.html@1.112 +58 -40 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1588, 2009-05-07 05:10:54+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - Updated JJY reference clock driver from Takao abe - Make ntpd the default project in Visual C++/Visual Studio + scripts/plot_summary.man.in@1.109 +3 -3 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.77, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - Updated JJY reference clock driver from Takao abe + scripts/plot_summary.mdoc.in@1.109 +2 -2 + ntp-4.2.8p4-sec-RC2 - html/drivers/driver40.html@1.14, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +103 -48 - Updated JJY reference clock driver from Takao abe + scripts/summary-opts@1.59 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/refclock_jjy.c@1.14, 2009-05-07 05:10:52+00:00, davehart@shiny.ad.hartbrothers.com +153 -5 - Updated JJY reference clock driver from Takao abe + scripts/summary.1summaryman@1.109 +3 -3 + ntp-4.2.8p4-sec-RC2 - ports/winnt/ntp.sln@1.2, 2009-05-07 05:10:53+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 - Make ntpd the default project in Visual C++/Visual Studio + scripts/summary.1summarymdoc@1.109 +2 -2 + ntp-4.2.8p4-sec-RC2 -ChangeSet@1.1587, 2009-05-02 02:38:49-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC5 - TAG: NTP_4_2_4P7_RC5 + scripts/summary.html@1.112 +49 -37 + ntp-4.2.8p4-sec-RC2 - ChangeLog@1.76, 2009-05-02 02:38:22-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC5 + scripts/summary.man.in@1.109 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd-opts.c@1.81, 2009-05-02 02:38:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + scripts/summary.mdoc.in@1.109 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd-opts.h@1.81, 2009-05-02 02:38:25-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + scripts/update-leap/invoke-update-leap.texi@1.10 +1 -1 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd-opts.texi@1.80, 2009-05-02 02:38:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + scripts/update-leap/update-leap-opts@1.10 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpd.1@1.79, 2009-05-02 02:38:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + scripts/update-leap/update-leap.1update-leapman@1.10 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim-opts.c@1.81, 2009-05-02 02:38:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + scripts/update-leap/update-leap.1update-leapmdoc@1.10 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim-opts.h@1.81, 2009-05-02 02:38:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + scripts/update-leap/update-leap.html@1.10 +72 -48 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim-opts.texi@1.79, 2009-05-02 02:38:30-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + scripts/update-leap/update-leap.man.in@1.10 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpd/ntpdsim.1@1.79, 2009-05-02 02:38:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + scripts/update-leap/update-leap.mdoc.in@1.10 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc-opts.c@1.81, 2009-05-02 02:38:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + sntp/invoke-sntp.texi@1.498 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc-opts.h@1.81, 2009-05-02 02:38:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + sntp/sntp-opts.c@1.517 +159 -159 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc-opts.texi@1.79, 2009-05-02 02:38:33-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + sntp/sntp-opts.h@1.515 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpdc/ntpdc.1@1.79, 2009-05-02 02:38:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + sntp/sntp.1sntpman@1.333 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.c@1.83, 2009-05-02 02:38:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + sntp/sntp.1sntpmdoc@1.333 +2 -2 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.h@1.83, 2009-05-02 02:38:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + sntp/sntp.html@1.513 +135 -111 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq-opts.texi@1.80, 2009-05-02 02:38:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + sntp/sntp.man.in@1.333 +3 -3 + ntp-4.2.8p4-sec-RC2 - ntpq/ntpq.1@1.79, 2009-05-02 02:38:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + sntp/sntp.mdoc.in@1.333 +2 -2 + ntp-4.2.8p4-sec-RC2 - packageinfo.sh@1.111, 2009-05-02 02:38:38-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + util/invoke-ntp-keygen.texi@1.501 +2 -2 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.c@1.79, 2009-05-02 02:38:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + util/ntp-keygen-opts.c@1.519 +173 -173 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.h@1.79, 2009-05-02 02:38:40-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + util/ntp-keygen-opts.h@1.517 +3 -3 + ntp-4.2.8p4-sec-RC2 - sntp/sntp-opts.texi@1.76, 2009-05-02 02:38:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + util/ntp-keygen.1ntp-keygenman@1.329 +3 -3 + ntp-4.2.8p4-sec-RC2 - sntp/sntp.1@1.79, 2009-05-02 02:38:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + util/ntp-keygen.1ntp-keygenmdoc@1.329 +2 -2 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.c@1.80, 2009-05-02 02:38:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 + util/ntp-keygen.html@1.175 +216 -157 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.h@1.80, 2009-05-02 02:38:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC5 + util/ntp-keygen.man.in@1.329 +3 -3 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen-opts.texi@1.78, 2009-05-02 02:38:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC5 + util/ntp-keygen.mdoc.in@1.329 +2 -2 + ntp-4.2.8p4-sec-RC2 - util/ntp-keygen.1@1.78, 2009-05-02 02:38:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC5 +ChangeSet@1.3572, 2015-10-17 03:10:01+00:00, stenn@psp-deb1.ntp.org + cleanup -ChangeSet@1.1586, 2009-05-02 01:49:02+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - flock-build: - set -m wasn't needed with ssh -tt and caused problems, remove - ChangeLog: - [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. - remove unportable 'set -m' from flock-build script - configure.ac: - reverse accidental backport from -dev of struct rtattr test in - configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + ChangeLog@1.1756 +1 -5 + cleanup - ChangeLog@1.75, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 - [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. - remove unportable 'set -m' from flock-build script +ChangeSet@1.3571, 2015-10-17 01:39:22+00:00, stenn@psp-deb1.ntp.org + [Sec 2941] NAK to the Future: Symmetric association authentication bypass via crypto-NAK - configure.ac@1.414, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +1 -12 - reverse accidental backport from -dev of struct rtattr test in - configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + ChangeLog@1.1755 +4 -1 + [Sec 2941] NAK to the Future: Symmetric association authentication bypass via crypto-NAK - flock-build@1.41, 2009-05-02 01:48:30+00:00, davehart@shiny.ad.hartbrothers.com +3 -5 - set -m wasn't needed with ssh -tt and caused problems, remove +ChangeSet@1.3558.3.3, 2015-10-11 08:10:20+02:00, jnperlin@hydra.localnet + [Bug 2941] NAK to the Future: Symmetric association authentication bypass via crypto-NAK -ChangeSet@1.1585, 2009-04-29 04:03:41-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC4 - TAG: NTP_4_2_4P7_RC4 + ChangeLog@1.1743.3.3 +3 -0 + [Bug 2941] NAK to the Future: Symmetric association authentication bypass via crypto-NAK - ChangeLog@1.74, 2009-04-29 04:03:17-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC4 + ntpd/ntp_proto.c@1.364.1.1 +18 -0 + [Bug 2941] NAK to the Future: Symmetric association authentication bypass via crypto-NAK - ntpd/ntpd-opts.c@1.80, 2009-04-29 04:03:18-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 +ChangeSet@1.3558.3.2, 2015-10-06 06:25:48-04:00, stenn@deacon.udel.edu + NTP_4_2_8P4_RC1 + TAG: NTP_4_2_8P4_RC1 - ntpd/ntpd-opts.h@1.80, 2009-04-29 04:03:19-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ChangeLog@1.1743.3.2 +1 -0 + NTP_4_2_8P4_RC1 - ntpd/ntpd-opts.texi@1.79, 2009-04-29 04:03:21-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/invoke-ntp.conf.texi@1.191 +1 -1 + NTP_4_2_8P4_RC1 - ntpd/ntpd.1@1.78, 2009-04-29 04:03:21-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/invoke-ntp.keys.texi@1.183 +1 -1 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim-opts.c@1.80, 2009-04-29 04:03:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/invoke-ntpd.texi@1.500 +2 -2 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim-opts.h@1.80, 2009-04-29 04:03:22-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpd/ntp.conf.5man@1.225 +3 -3 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim-opts.texi@1.78, 2009-04-29 04:03:24-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/ntp.conf.5mdoc@1.225 +2 -2 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim.1@1.78, 2009-04-29 04:03:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntp.conf.html@1.179 +1196 -1524 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc-opts.c@1.80, 2009-04-29 04:03:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntp.conf.man.in@1.225 +3 -3 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc-opts.h@1.80, 2009-04-29 04:03:26-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpd/ntp.conf.mdoc.in@1.225 +2 -2 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc-opts.texi@1.78, 2009-04-29 04:03:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/ntp.keys.5man@1.217 +2 -2 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc.1@1.78, 2009-04-29 04:03:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntp.keys.5mdoc@1.217 +2 -2 + NTP_4_2_8P4_RC1 - ntpq/ntpq-opts.c@1.82, 2009-04-29 04:03:29-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntp.keys.html@1.179 +1 -1 + NTP_4_2_8P4_RC1 - ntpq/ntpq-opts.h@1.82, 2009-04-29 04:03:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpd/ntp.keys.man.in@1.217 +2 -2 + NTP_4_2_8P4_RC1 - ntpq/ntpq-opts.texi@1.79, 2009-04-29 04:03:30-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/ntp.keys.mdoc.in@1.217 +2 -2 + NTP_4_2_8P4_RC1 - ntpq/ntpq.1@1.78, 2009-04-29 04:03:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntpd-opts.c@1.522 +245 -245 + NTP_4_2_8P4_RC1 - packageinfo.sh@1.110, 2009-04-29 04:03:31-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/ntpd-opts.h@1.521 +3 -3 + NTP_4_2_8P4_RC1 - sntp/sntp-opts.c@1.78, 2009-04-29 04:03:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntpd.1ntpdman@1.329 +8 -4 + NTP_4_2_8P4_RC1 - sntp/sntp-opts.h@1.78, 2009-04-29 04:03:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpd/ntpd.1ntpdmdoc@1.329 +7 -3 + NTP_4_2_8P4_RC1 - sntp/sntp-opts.texi@1.75, 2009-04-29 04:03:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpd/ntpd.html@1.173 +2 -2 + NTP_4_2_8P4_RC1 - sntp/sntp.1@1.78, 2009-04-29 04:03:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntpd.man.in@1.329 +8 -4 + NTP_4_2_8P4_RC1 - util/ntp-keygen-opts.c@1.79, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpd/ntpd.mdoc.in@1.329 +7 -3 + NTP_4_2_8P4_RC1 - util/ntp-keygen-opts.h@1.79, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC4 + ntpdc/invoke-ntpdc.texi@1.497 +2 -2 + NTP_4_2_8P4_RC1 - util/ntp-keygen-opts.texi@1.77, 2009-04-29 04:03:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC4 + ntpdc/ntpdc-opts.c@1.515 +107 -107 + NTP_4_2_8P4_RC1 - util/ntp-keygen.1@1.77, 2009-04-29 04:03:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC4 + ntpdc/ntpdc-opts.h@1.514 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1584, 2009-04-29 01:50:44-04:00, stenn@pogo.udel.edu +1 -0 - No need to know the GCC -W items in config.h + ntpdc/ntpdc.1ntpdcman@1.328 +3 -3 + NTP_4_2_8P4_RC1 - configure.ac@1.413, 2009-04-29 01:50:36-04:00, stenn@pogo.udel.edu +2 -12 - No need to know the GCC -W items in config.h + ntpdc/ntpdc.1ntpdcmdoc@1.328 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1583, 2009-04-27 11:47:49+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - add [Bug 1167] to ChangeLog entry + ntpdc/ntpdc.html@1.341 +2 -2 + NTP_4_2_8P4_RC1 - ChangeLog@1.73, 2009-04-27 11:47:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - add [Bug 1167] to ChangeLog entry + ntpdc/ntpdc.man.in@1.328 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1582, 2009-04-26 06:10:27+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - gcc -Winit-self is used only if it is understood + ntpdc/ntpdc.mdoc.in@1.328 +2 -2 + NTP_4_2_8P4_RC1 - ChangeLog@1.72, 2009-04-26 06:10:25+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - gcc -Winit-self is used only if it is understood + ntpq/invoke-ntpq.texi@1.504 +2 -2 + NTP_4_2_8P4_RC1 - configure.ac@1.412, 2009-04-26 06:10:26+00:00, davehart@shiny.ad.hartbrothers.com +34 -2 - gcc -Winit-self is used only if it is understood + ntpq/ntpq-opts.c@1.521 +106 -106 + NTP_4_2_8P4_RC1 -ChangeSet@1.1581, 2009-04-22 08:18:29-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC3 - TAG: NTP_4_2_4P7_RC3 + ntpq/ntpq-opts.h@1.519 +3 -3 + NTP_4_2_8P4_RC1 - ChangeLog@1.71, 2009-04-22 08:18:04-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC3 + ntpq/ntpq.1ntpqman@1.332 +3 -3 + NTP_4_2_8P4_RC1 - ntpd/ntpd-opts.c@1.79, 2009-04-22 08:18:04-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpq/ntpq.1ntpqmdoc@1.332 +2 -2 + NTP_4_2_8P4_RC1 - ntpd/ntpd-opts.h@1.79, 2009-04-22 08:18:05-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + ntpq/ntpq.html@1.170 +2 -2 + NTP_4_2_8P4_RC1 - ntpd/ntpd-opts.texi@1.78, 2009-04-22 08:18:05-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpq/ntpq.man.in@1.332 +3 -3 + NTP_4_2_8P4_RC1 - ntpd/ntpd.1@1.77, 2009-04-22 08:18:07-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpq/ntpq.mdoc.in@1.332 +2 -2 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim-opts.c@1.79, 2009-04-22 08:18:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpsnmpd/invoke-ntpsnmpd.texi@1.499 +2 -2 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim-opts.h@1.79, 2009-04-22 08:18:08-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + ntpsnmpd/ntpsnmpd-opts.c@1.517 +68 -68 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim-opts.texi@1.77, 2009-04-22 08:18:09-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC3 + ntpsnmpd/ntpsnmpd-opts.h@1.516 +3 -3 + NTP_4_2_8P4_RC1 - ntpd/ntpdsim.1@1.77, 2009-04-22 08:18:10-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.328 +3 -3 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc-opts.c@1.79, 2009-04-22 08:18:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.328 +2 -2 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc-opts.h@1.79, 2009-04-22 08:18:11-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + ntpsnmpd/ntpsnmpd.html@1.168 +1 -1 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc-opts.texi@1.77, 2009-04-22 08:18:12-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpsnmpd/ntpsnmpd.man.in@1.328 +3 -3 + NTP_4_2_8P4_RC1 - ntpdc/ntpdc.1@1.77, 2009-04-22 08:18:13-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + ntpsnmpd/ntpsnmpd.mdoc.in@1.328 +2 -2 + NTP_4_2_8P4_RC1 - ntpq/ntpq-opts.c@1.81, 2009-04-22 08:18:13-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + packageinfo.sh@1.517 +2 -2 + NTP_4_2_8P4_RC1 - ntpq/ntpq-opts.h@1.81, 2009-04-22 08:18:14-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.89 +3 -3 + NTP_4_2_8P4_RC1 - ntpq/ntpq-opts.texi@1.78, 2009-04-22 08:18:15-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.90 +2 -2 + NTP_4_2_8P4_RC1 - ntpq/ntpq.1@1.77, 2009-04-22 08:18:16-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + scripts/calc_tickadj/calc_tickadj.html@1.91 +1 -1 + NTP_4_2_8P4_RC1 - packageinfo.sh@1.109, 2009-04-22 08:18:17-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC3 + scripts/calc_tickadj/calc_tickadj.man.in@1.88 +3 -3 + NTP_4_2_8P4_RC1 - sntp/sntp-opts.c@1.77, 2009-04-22 08:18:19-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.90 +2 -2 + NTP_4_2_8P4_RC1 - sntp/sntp-opts.h@1.77, 2009-04-22 08:18:20-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.93 +1 -1 + NTP_4_2_8P4_RC1 - sntp/sntp-opts.texi@1.74, 2009-04-22 08:18:20-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC3 + scripts/invoke-plot_summary.texi@1.110 +2 -2 + NTP_4_2_8P4_RC1 - sntp/sntp.1@1.77, 2009-04-22 08:18:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + scripts/invoke-summary.texi@1.110 +2 -2 + NTP_4_2_8P4_RC1 - util/ntp-keygen-opts.c@1.78, 2009-04-22 08:18:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + scripts/ntp-wait/invoke-ntp-wait.texi@1.320 +2 -2 + NTP_4_2_8P4_RC1 - util/ntp-keygen-opts.h@1.78, 2009-04-22 08:18:23-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC3 + scripts/ntp-wait/ntp-wait-opts@1.56 +2 -2 + NTP_4_2_8P4_RC1 - util/ntp-keygen-opts.texi@1.76, 2009-04-22 08:18:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.317 +3 -3 + NTP_4_2_8P4_RC1 - util/ntp-keygen.1@1.76, 2009-04-22 08:18:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC3 + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.318 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1580, 2009-04-22 07:00:20-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 1155] Fix compile problem on Windows with VS2005 + scripts/ntp-wait/ntp-wait.html@1.337 +2 -2 + NTP_4_2_8P4_RC1 - ChangeLog@1.70, 2009-04-22 07:00:11-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 1155] Fix compile problem on Windows with VS2005 + scripts/ntp-wait/ntp-wait.man.in@1.317 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1579, 2009-04-22 06:06:53-04:00, stenn@whimsy.udel.edu +1 -0 - Cleanup + scripts/ntp-wait/ntp-wait.mdoc.in@1.318 +2 -2 + NTP_4_2_8P4_RC1 - ChangeLog@1.69, 2009-04-22 06:06:44-04:00, stenn@whimsy.udel.edu +4 -2 - Cleanup + scripts/ntpsweep/invoke-ntpsweep.texi@1.108 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1578, 2009-04-20 22:55:13+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - auto merge not quite right + scripts/ntpsweep/ntpsweep-opts@1.58 +2 -2 + NTP_4_2_8P4_RC1 - ChangeLog@1.68, 2009-04-20 22:55:10+00:00, davehart@shiny.ad.hartbrothers.com +3 -7 - auto merge not quite right + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.96 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1577, 2009-04-20 22:42:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ntp_iocompletionport.c: - revert overlooked CreateEvent naming/sharing change not conditionalized away already + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.96 +2 -2 + NTP_4_2_8P4_RC1 - ports/winnt/ntpd/ntp_iocompletionport.c@1.32, 2009-04-20 22:42:50+00:00, davehart@shiny.ad.hartbrothers.com +2 -2 - revert overlooked CreateEvent naming/sharing change not conditionalized away already + scripts/ntpsweep/ntpsweep.html@1.109 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.11, 2009-04-20 06:17:21+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + scripts/ntpsweep/ntpsweep.man.in@1.96 +3 -3 + NTP_4_2_8P4_RC1 - ChangeLog@1.64.1.3, 2009-04-20 06:17:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + scripts/ntpsweep/ntpsweep.mdoc.in@1.97 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.10, 2009-04-20 06:02:20+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - [Bug 1160] MacOS X is like BSD regarding F_SETOWN + scripts/ntptrace/invoke-ntptrace.texi@1.109 +2 -2 + NTP_4_2_8P4_RC1 - configure.ac@1.411, 2009-04-20 06:02:08+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - [Bug 1160] MacOS X is like BSD regarding F_SETOWN + scripts/ntptrace/ntptrace-opts@1.58 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.9, 2009-04-16 02:39:01+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - fix for --enable-ntp-signd=/my/path + scripts/ntptrace/ntptrace.1ntptraceman@1.96 +3 -3 + NTP_4_2_8P4_RC1 - configure.ac@1.410, 2009-04-16 02:38:53+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - fix for --enable-ntp-signd=/my/path + scripts/ntptrace/ntptrace.1ntptracemdoc@1.97 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.8, 2009-04-15 12:36:24+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - do not cache options fix + scripts/ntptrace/ntptrace.html@1.110 +2 -2 + NTP_4_2_8P4_RC1 - configure.ac@1.409, 2009-04-15 12:36:12+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - do not cache options fix + scripts/ntptrace/ntptrace.man.in@1.96 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.7, 2009-04-15 10:43:51+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - Do not cache configure --options, only current values matter - Default --enable-wintime when --enable-ntp-signd + scripts/ntptrace/ntptrace.mdoc.in@1.98 +2 -2 + NTP_4_2_8P4_RC1 - configure.ac@1.408, 2009-04-15 10:43:32+00:00, davehart@shiny.ad.hartbrothers.com +575 -403 - Do not cache configure --options, only current values matter - Default --enable-wintime when --enable-ntp-signd + scripts/plot_summary-opts@1.58 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.6, 2009-04-15 01:32:33+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - use AC_SEARCH_LIBS to avoid problems with sntp + scripts/plot_summary.1plot_summaryman@1.108 +3 -3 + NTP_4_2_8P4_RC1 - configure.ac@1.407, 2009-04-15 01:30:56+00:00, davehart@shiny.ad.hartbrothers.com +12 -20 - use AC_SEARCH_LIBS in preference to AC_CHECK_LIB particulary for sockets, use AM_PROG_CC_C_O which supersets prior AC_PROG_CC_C_O + scripts/plot_summary.1plot_summarymdoc@1.108 +2 -2 + NTP_4_2_8P4_RC1 - sntp/configure.ac@1.17, 2009-04-15 01:28:22+00:00, davehart@shiny.ad.hartbrothers.com +4 -4 - use AC_SEARCH_LIBS which is recommended particularly for sockets over the older AC_CHECK_LIB + scripts/plot_summary.html@1.111 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.5, 2009-04-14 13:47:29+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - tear off sntp/configure.ac from configure.ac + scripts/plot_summary.man.in@1.108 +3 -3 + NTP_4_2_8P4_RC1 - configure.ac@1.406, 2009-04-14 13:46:17+00:00, davehart@shiny.ad.hartbrothers.com +6 -1 - tear off sntp/configure.ac from configure.ac + scripts/plot_summary.mdoc.in@1.108 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1575, 2009-04-14 07:55:41-04:00, mayer@pogo.udel.edu +1 -0 - Added fix for Bug 813 + scripts/summary-opts@1.58 +2 -2 + NTP_4_2_8P4_RC1 - ChangeLog@1.66, 2009-04-14 07:55:31-04:00, mayer@pogo.udel.edu +1 -0 - Added fix for Bug 813 + scripts/summary.1summaryman@1.108 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1574, 2009-04-14 07:51:41-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 813] Conditional naming of Event + scripts/summary.1summarymdoc@1.108 +2 -2 + NTP_4_2_8P4_RC1 - ports/winnt/ntpd/ntp_iocompletionport.c@1.31, 2009-04-14 07:51:14-04:00, mayer@pogo.udel.edu +7 -1 - [Bug 813] Conditional naming of Event + scripts/summary.html@1.111 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.4, 2009-04-14 05:21:17+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - configure.ac: - use unset for tickadj utility test fix + scripts/summary.man.in@1.108 +3 -3 + NTP_4_2_8P4_RC1 - configure.ac@1.405, 2009-04-14 05:21:15+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - use unset for tickadj utility test fix + scripts/summary.mdoc.in@1.108 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.3, 2009-04-14 02:59:39+00:00, hart@pogo.udel.edu +1 -0 - build: - do not require nice + scripts/update-leap/invoke-update-leap.texi@1.9 +1 -1 + NTP_4_2_8P4_RC1 - build@1.26, 2009-04-14 02:59:20+00:00, hart@pogo.udel.edu +21 -4 - do not require nice + scripts/update-leap/update-leap-opts@1.9 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.2, 2009-04-14 01:33:01+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - configure.ac, ChangeLog: - [Bug 1158] support for aix6.1 + scripts/update-leap/update-leap.1update-leapman@1.9 +3 -3 + NTP_4_2_8P4_RC1 - ChangeLog@1.64.1.2, 2009-04-14 01:33:00+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1158] support for aix6.1 + scripts/update-leap/update-leap.1update-leapmdoc@1.9 +2 -2 + NTP_4_2_8P4_RC1 - configure.ac@1.404, 2009-04-14 01:33:00+00:00, davehart@shiny.ad.hartbrothers.com +8 -8 - [Bug 1158] support for aix6.1 + scripts/update-leap/update-leap.html@1.9 +1 -1 + NTP_4_2_8P4_RC1 -ChangeSet@1.1567.1.1, 2009-04-14 01:28:08+00:00, davehart@shiny.ad.hartbrothers.com +5 -0 - [Bug 1157] quiet OpenSSL warnings, clean up configure.ac - make flock-build quit before causing harm if another has not completed - + scripts/update-leap/update-leap.man.in@1.9 +3 -3 + NTP_4_2_8P4_RC1 - ChangeLog@1.64.1.1, 2009-04-14 01:28:06+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Bug 1157] quiet OpenSSL warnings, clean up configure.ac + scripts/update-leap/update-leap.mdoc.in@1.9 +2 -2 + NTP_4_2_8P4_RC1 - build@1.25, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +6 -7 - prevent multiple flock-builds from stepping on each others work + sntp/invoke-sntp.texi@1.497 +2 -2 + NTP_4_2_8P4_RC1 - configure.ac@1.403, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +613 -361 - [Bug 1157] quiet OpenSSL warnings, configure.ac cleanup + sntp/sntp-opts.c@1.516 +159 -159 + NTP_4_2_8P4_RC1 - flock-build@1.40, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +76 -20 - prevent multiple flock-builds from stepping on each others work + sntp/sntp-opts.h@1.514 +3 -3 + NTP_4_2_8P4_RC1 - sntp/configure.ac@1.16, 2009-04-14 01:28:07+00:00, davehart@shiny.ad.hartbrothers.com +14 -0 - bring in line with -dev to ease merges, no functional change + sntp/sntp.1sntpman@1.332 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1573, 2009-04-13 00:00:55-04:00, mayer@pogo.udel.edu +1 -0 - Forgot the _WIN32_WINNT update + sntp/sntp.1sntpmdoc@1.332 +2 -2 + NTP_4_2_8P4_RC1 - ports/winnt/include/config.h@1.51, 2009-04-13 00:00:24-04:00, mayer@pogo.udel.edu +10 -23 - Forgot the _WIN32_WINNT update + sntp/sntp.html@1.512 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1572, 2009-04-12 00:55:24-04:00, mayer@pogo.udel.edu +1 -0 - Windows bug fixes + sntp/sntp.man.in@1.332 +3 -3 + NTP_4_2_8P4_RC1 - ChangeLog@1.65, 2009-04-12 00:54:43-04:00, mayer@pogo.udel.edu +7 -2 - Windows bug fixes + sntp/sntp.mdoc.in@1.332 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1571, 2009-04-12 00:45:48-04:00, mayer@pogo.udel.edu +2 -0 - [Bug 1156] lock_thread_to_processor() should be declared in header + util/invoke-ntp-keygen.texi@1.500 +2 -2 + NTP_4_2_8P4_RC1 - ports/winnt/include/clockstuff.h@1.8, 2009-04-12 00:45:09-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 1156] lock_thread_to_processor() should be declared in header + util/ntp-keygen-opts.c@1.518 +173 -173 + NTP_4_2_8P4_RC1 - ports/winnt/ntpd/nt_clockstuff.c@1.25, 2009-04-12 00:45:09-04:00, mayer@pogo.udel.edu +0 -1 - [Bug 1156] lock_thread_to_processor() should be declared in header + util/ntp-keygen-opts.h@1.516 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1570, 2009-04-12 00:38:47-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 1147] System errors should be logged to msyslog() + util/ntp-keygen.1ntp-keygenman@1.328 +3 -3 + NTP_4_2_8P4_RC1 - ports/winnt/ntpd/ntp_iocompletionport.c@1.30, 2009-04-12 00:38:08-04:00, mayer@pogo.udel.edu +17 -14 - [Bug 1147] System errors should be logged to msyslog() + util/ntp-keygen.1ntp-keygenmdoc@1.328 +2 -2 + NTP_4_2_8P4_RC1 -ChangeSet@1.1569, 2009-04-12 00:34:41-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 1155] Wrong header included in config.h. Should have been winsock2.h + util/ntp-keygen.html@1.174 +2 -2 + NTP_4_2_8P4_RC1 - ports/winnt/include/config.h@1.50, 2009-04-12 00:34:10-04:00, mayer@pogo.udel.edu +1 -2 - [Bug 1155] Wrong header included in config.h. Should have been winsock2.h + util/ntp-keygen.man.in@1.328 +3 -3 + NTP_4_2_8P4_RC1 -ChangeSet@1.1568, 2009-04-12 00:32:25-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 787] Bug fixes for 64-bit time_t on Windows + util/ntp-keygen.mdoc.in@1.328 +2 -2 + NTP_4_2_8P4_RC1 - ports/winnt/libntp/SetSystemTime.c@1.4, 2009-04-12 00:30:42-04:00, mayer@pogo.udel.edu +2 -2 - [Bug 787] Bug fixes for 64-bit time_t on Windows +ChangeSet@1.3558.3.1, 2015-10-06 05:40:23-04:00, stenn@deacon.udel.edu + Prepare for 4.2.8p4-RC1 -ChangeSet@1.1567, 2009-04-09 07:44:06-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC2 - TAG: NTP_4_2_4P7_RC2 + ChangeLog@1.1743.3.1 +1 -0 + Prepare for 4.2.8p4-RC1 - ChangeLog@1.64, 2009-04-09 07:43:41-04:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC2 + NEWS@1.147 +143 -4 + Prepare for 4.2.8p4-RC1 - ntpd/ntpd-opts.c@1.78, 2009-04-09 07:43:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + packageinfo.sh@1.516 +1 -1 + Prepare for 4.2.8p4-RC1 - ntpd/ntpd-opts.h@1.78, 2009-04-09 07:43:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 +ChangeSet@1.3568, 2015-10-06 08:51:27+00:00, stenn@psp-deb1.ntp.org + [Sec 2922] decodenetnum() will ASSERT botch instead of returning FAIL on some bogus values. Harlan Stenn. - ntpd/ntpd-opts.texi@1.77, 2009-04-09 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ChangeLog@1.1752 +2 -0 + [Sec 2922] decodenetnum() will ASSERT botch instead of returning FAIL on some [Sec 2922] decodenetnum() will ASSERT botch instead of returning FAIL on some bogus values. Harlan Stenn. - ntpd/ntpd.1@1.76, 2009-04-09 07:43:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + libntp/decodenetnum.c@1.18 +4 -1 + [Sec 2922] decodenetnum() will ASSERT botch instead of returning FAIL on some [Sec 2922] decodenetnum() will ASSERT botch instead of returning FAIL on some bogus values. Harlan Stenn. - ntpd/ntpdsim-opts.c@1.78, 2009-04-09 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 +ChangeSet@1.3567, 2015-10-06 08:02:23+00:00, stenn@psp-deb1.ntp.org + Log incoming packets that fail TEST2. Harlan Stenn. - ntpd/ntpdsim-opts.h@1.78, 2009-04-09 07:43:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + ChangeLog@1.1751 +1 -1 + Log incoming packets that fail TEST2. Harlan Stenn. - ntpd/ntpdsim-opts.texi@1.76, 2009-04-09 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC2 + ntpd/ntp_proto.c@1.367 +7 -1 + Log incoming packets that fail TEST2. Harlan Stenn. - ntpd/ntpdsim.1@1.76, 2009-04-09 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 +ChangeSet@1.3566, 2015-10-06 07:47:24+00:00, stenn@psp-deb1.ntp.org + cleanup - ntpdc/ntpdc-opts.c@1.78, 2009-04-09 07:43:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ChangeLog@1.1750 +2 -1 + cleanup - ntpdc/ntpdc-opts.h@1.78, 2009-04-09 07:43:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + ntpd/ntp_proto.c@1.366 +113 -95 + cleanup - ntpdc/ntpdc-opts.texi@1.76, 2009-04-09 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 +ChangeSet@1.3564, 2015-10-06 03:56:29+00:00, stenn@psp-deb1.ntp.org + [Sec 2921] TALOS-CAN-0065: password length memory corruption. JPerlinger. - ntpdc/ntpdc.1@1.76, 2009-04-09 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ChangeLog@1.1748 +1 -0 + [Sec 2921] TALOS-CAN-0065: password length memory corruption. JPerlinger. + Fixed as part of [Sec 2916] TALOS-CAN-0054: memory corruption in password store. JPerlinger. - ntpq/ntpq-opts.c@1.80, 2009-04-09 07:43:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 +ChangeSet@1.3562, 2015-10-05 21:11:21+00:00, stenn@psp-deb1.ntp.org + typo - ntpq/ntpq-opts.h@1.80, 2009-04-09 07:43:53-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 + libntp/authreadkeys.c@1.22 +1 -1 + typo - ntpq/ntpq-opts.texi@1.77, 2009-04-09 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 +ChangeSet@1.3552.9.2, 2015-10-05 11:11:54+00:00, stenn@psp-deb1.ntp.org + 2909 is a security bug - ntpq/ntpq.1@1.76, 2009-04-09 07:43:55-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ChangeLog@1.1739.5.2 +1 -1 + 2909 is a security bug - packageinfo.sh@1.108, 2009-04-09 07:43:55-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC2 +ChangeSet@1.3558.2.2, 2015-10-05 11:03:39+00:00, stenn@psp-deb1.ntp.org + 2902 is a security bug - sntp/sntp-opts.c@1.76, 2009-04-09 07:43:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ChangeLog@1.1743.2.2 +2 -2 + 2902 is a security bug - sntp/sntp-opts.h@1.76, 2009-04-09 07:43:58-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 +ChangeSet@1.3558.1.4, 2015-10-05 10:49:30+00:00, stenn@psp-deb1.ntp.org + Update the ChangeLog for 2899 - sntp/sntp-opts.texi@1.73, 2009-04-09 07:43:58-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC2 + ChangeLog@1.1743.1.4 +1 -1 + Update the ChangeLog for 2899 - sntp/sntp.1@1.76, 2009-04-09 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 +ChangeSet@1.3552.4.2, 2015-10-05 10:32:02+00:00, stenn@psp-deb1.ntp.org + typos - util/ntp-keygen-opts.c@1.77, 2009-04-09 07:44:00-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpd/ntp_crypto.c@1.183 +4 -4 + typos - util/ntp-keygen-opts.h@1.77, 2009-04-09 07:44:00-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC2 +ChangeSet@1.3558.1.2, 2015-10-05 06:26:46+00:00, stenn@psp-deb1.ntp.org + [Bug 2912] no munlockall() under Windows. David Taylor, Harlan Stenn. - util/ntp-keygen-opts.texi@1.75, 2009-04-09 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ChangeLog@1.1743.1.2 +1 -0 + [Bug 2912] no munlockall() under Windows. David Taylor, Harlan Stenn. - util/ntp-keygen.1@1.75, 2009-04-09 07:44:02-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC2 + ntpd/ntp_config.c@1.335 +4 -0 + [Bug 2912] no munlockall() under Windows. David Taylor, Harlan Stenn. -ChangeSet@1.1566, 2009-04-09 04:16:50-04:00, stenn@whimsy.udel.edu +1 -0 - ChangLog cleanup +ChangeSet@1.3561, 2015-10-03 09:08:20+02:00, jnperlin@hydra.localnet + [TALOS-CAN-0055] Infinite loop if extended logging enabled and the logfile and keyfile are the same - ChangeLog@1.63, 2009-04-09 04:16:43-04:00, stenn@whimsy.udel.edu +1 -0 - ChangLog cleanup + ChangeLog@1.1746 +2 -0 + [TALOS-CAN-0055] Infinite loop if extended logging enabled and the logfile and keyfile are the same -ChangeSet@1.1565, 2009-04-09 04:13:41-04:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + include/ntp_stdlib.h@1.79 +1 -0 + [TALOS-CAN-0055] Infinite loop if extended logging enabled and the logfile and keyfile are the same + - add 'mvsyslog()' function to make wrapping calls to syslog easier - ChangeLog@1.62, 2009-04-09 04:13:30-04:00, stenn@whimsy.udel.edu +2 -0 - [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + include/ntp_syslog.h@1.9 +1 -0 + [TALOS-CAN-0055] Infinite loop if extended logging enabled and the logfile and keyfile are the same + - add 'mvsyslog()' function to make wrapping calls to syslog easier - ntpq/ntpq.c@1.66, 2009-04-09 04:13:30-04:00, stenn@whimsy.udel.edu +2 -2 - [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + libntp/authreadkeys.c@1.21 +71 -18 + [TALOS-CAN-0055] Infinite loop if extended logging enabled and the logfile and keyfile are the same + - Avoid endless loop by logging only the first 5 errors explicitely, counting the next 10 silently, and aborting + the parsing of the file with proper diagnostic when more than 15 errors where encountered. -ChangeSet@1.1564, 2009-04-07 09:14:58+00:00, davehart@shiny.ad.hartbrothers.com +3 -0 - [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + libntp/msyslog.c@1.53 +12 -0 + [TALOS-CAN-0055] Infinite loop if extended logging enabled and the logfile and keyfile are the same + - add 'mvsyslog()' function to make wrapping calls to syslog easier - ChangeLog@1.61, 2009-04-07 09:14:56+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows +ChangeSet@1.3558.1.1, 2015-10-01 03:27:35-04:00, stenn@deacon.udel.edu + build system tweaks. Harlan Stenn. - ntpd/ntp_io.c@1.259, 2009-04-07 09:14:56+00:00, davehart@shiny.ad.hartbrothers.com +64 -31 - [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + ChangeLog@1.1743.1.1 +2 -1 + build system tweaks. Harlan Stenn. - ports/winnt/libntp/libntp.vcproj@1.2, 2009-04-07 09:14:57+00:00, davehart@shiny.ad.hartbrothers.com +4 -0 - add ntp_debug.h + Makefile.am@1.134 +1 -1 + build system tweaks. Harlan Stenn. -ChangeSet@1.1563, 2009-03-30 06:47:41-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P7_RC1 - TAG: NTP_4_2_4P7_RC1 + sntp/m4/ntp_problemtests.m4@1.3 +14 -14 + build system tweaks. Harlan Stenn. - ChangeLog@1.60, 2009-03-30 06:47:19-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P7_RC1 +ChangeSet@1.3560, 2015-09-30 22:47:45+02:00, jnperlin@hydra.localnet + [TALOS-CAN-0062] prevent directory traversal for VMS, too, when using 'saveconfig' command. - ntpd/ntpd-opts.c@1.77, 2009-03-30 06:47:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ChangeLog@1.1745 +2 -0 + [TALOS-CAN-0062] prevent directory traversal for VMS, too, when using 'saveconfig' command. - ntpd/ntpd-opts.h@1.77, 2009-03-30 06:47:21-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpd/ntp_control.c@1.204 +25 -9 + [TALOS-CAN-0062] prevent directory traversal for VMS, too, when using 'saveconfig' command. - ntpd/ntpd-opts.texi@1.76, 2009-03-30 06:47:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 +ChangeSet@1.3559, 2015-09-30 21:55:09+02:00, jnperlin@hydra.localnet + [TALOS-CAN-0064] signed/unsiged clash could lead to buffer overun - ntpd/ntpd.1@1.75, 2009-03-30 06:47:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + BitKeeper/etc/ignore@1.89 +4 -0 + keep cscope files away from repo - ntpd/ntpdsim-opts.c@1.77, 2009-03-30 06:47:23-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ChangeLog@1.1744 +2 -0 + [TALOS-CAN-0064] signed/unsiged clash could lead to buffer overun - ntpd/ntpdsim-opts.h@1.77, 2009-03-30 06:47:24-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ntpd/ntp_io.c@1.408 +9 -6 + [TALOS-CAN-0064] signed/unsiged clash could lead to buffer overun - ntpd/ntpdsim-opts.texi@1.75, 2009-03-30 06:47:25-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.11.4, 2015-09-30 20:15:13+02:00, jnperlin@hydra.localnet + [TALOS-CAN-0063] avoid buffer overrun in ntpq - ntpd/ntpdsim.1@1.75, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ChangeLog@1.1739.7.3 +1 -0 + [TALOS-CAN-0063] avoid buffer overrun in ntpq - ntpdc/ntpdc-opts.c@1.77, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpq/ntpq.c@1.162 +6 -1 + [TALOS-CAN-0063] avoid buffer overrun in ntpq - ntpdc/ntpdc-opts.h@1.77, 2009-03-30 06:47:26-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.11.3, 2015-09-30 18:44:18+02:00, jnperlin@hydra.localnet + [TALOS-CAN-0054] memory corruption + - make sure there's *always* a new buffer for storing the key again - ntpdc/ntpdc-opts.texi@1.75, 2009-03-30 06:47:27-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + libntp/authkeys.c@1.27 +9 -5 + [TALOS-CAN-0054] memory corruption + - make sure there's *always* a new buffer for storing the key again - ntpdc/ntpdc.1@1.75, 2009-03-30 06:47:28-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.1.32, 2015-09-30 07:40:52+00:00, stenn@psp-deb1.ntp.org + formatting cleanup - ntpq/ntpq-opts.c@1.79, 2009-03-30 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ChangeLog@1.1739.1.18 +1 -1 + formatting cleanup - ntpq/ntpq-opts.h@1.79, 2009-03-30 06:47:30-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.12.2, 2015-09-30 06:45:59+00:00, stenn@psp-deb1.ntp.org + Implement --disable-problem-tests (off by default). Harlan Stenn. - ntpq/ntpq-opts.texi@1.76, 2009-03-30 06:47:31-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ChangeLog@1.1739.8.1 +1 -0 + Implement --disable-problem-tests (off by default). Harlan Stenn. - ntpq/ntpq.1@1.75, 2009-03-30 06:47:32-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + sntp/m4/ntp_problemtests.m4@1.2 +20 -6 + Implement --disable-problem-tests (off by default). Harlan Stenn. - packageinfo.sh@1.107, 2009-03-30 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.12.1, 2015-09-30 06:11:05+00:00, stenn@psp-deb1.ntp.org + whitespace cleanup - sntp/sntp-opts.c@1.75, 2009-03-30 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/ntp_io.c@1.407 +13 -13 + whitespace cleanup - sntp/sntp-opts.h@1.75, 2009-03-30 06:47:34-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.11.2, 2015-09-29 23:13:13+02:00, jnperlin@hydra.localnet + [TALOS-CAN-0054] memory corruption in password store - sntp/sntp-opts.texi@1.72, 2009-03-30 06:47:35-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P7_RC1 + ChangeLog@1.1739.7.2 +1 -0 + [TALOS-CAN-0054] memory corruption in password store - sntp/sntp.1@1.75, 2009-03-30 06:47:35-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + libntp/authkeys.c@1.26 +4 -0 + [TALOS-CAN-0054] memory corruption in password store + - make sure deallocated pointers are NULLed and new storage is allocated on demand - util/ntp-keygen-opts.c@1.76, 2009-03-30 06:47:36-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.11.1, 2015-09-29 22:00:10+02:00, jnperlin@hydra.localnet + [TALOS-CAN-0052] crash by loop counter underrun. - util/ntp-keygen-opts.h@1.76, 2009-03-30 06:47:36-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P7_RC1 + ChangeLog@1.1739.7.1 +1 -0 + [TALOS-CAN-0052] crash by loop counter underrun. - util/ntp-keygen-opts.texi@1.74, 2009-03-30 06:47:37-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 + ntpd/ntp_request.c@1.114 +7 -3 + [TALOS-CAN-0052] crash by loop counter underrun. + - add missing reload of loop counter - util/ntp-keygen.1@1.74, 2009-03-30 06:47:38-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P7_RC1 +ChangeSet@1.3552.10.2, 2015-09-29 20:34:05+02:00, jnperlin@hydra.localnet + [Bug 2902] configuration directives "pidfile" and "driftfile" should be local-only. -ChangeSet@1.1562, 2009-03-30 02:31:49-05:00, stenn@whimsy.udel.edu +1 -0 - Release Candidate + ChangeLog@1.1739.6.2 +2 -0 + [Bug 2902] configuration directives "pidfile" and "driftfile" should be local-only. - packageinfo.sh@1.106, 2009-03-30 02:31:39-05:00, stenn@whimsy.udel.edu +1 -1 - Release Candidate + ntpd/ntp_parser.c@1.99 +235 -226 + [Bug 2902] configuration directives "pidfile" and "driftfile" should be local-only. + - update bison-generated files -ChangeSet@1.1560, 2009-03-28 02:46:45-05:00, stenn@whimsy.udel.edu +9 -0 - build system email address cleanup + ntpd/ntp_parser.h@1.64 +3 -5 + [Bug 2902] configuration directives "pidfile" and "driftfile" should be local-only. + - update bison-generated files - BitKeeper/triggers/changelog@1.4, 2009-03-28 02:45:21-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + ntpd/ntp_parser.y@1.89 +26 -15 + [Bug 2902] configuration directives "pidfile" and "driftfile" should be local-only. + - applied patch from Miroslav Lichvar, plus minor cosmetic changes - BitKeeper/triggers/commitlogs@1.6, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup +ChangeSet@1.3552.10.1, 2015-09-29 06:10:38-04:00, stenn@pogo.udel.edu + Disable certain test programs on certain platforms. Harlan Stenn. - BitKeeper/triggers/delta-changelog@1.8, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +2 -2 - trigger email address cleanup + ChangeLog@1.1739.6.1 +1 -0 + Disable certain test programs on certain platforms. Harlan Stenn. - BitKeeper/triggers/notify@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + configure.ac@1.602 +2 -0 + Disable certain test programs on certain platforms. Harlan Stenn. - BitKeeper/triggers/paranoid@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + sntp/m4/ntp_problemtests.m4@1.1 +42 -0 + BitKeeper file /pogo/users/stenn/ntp-stable/sntp/m4/ntp_problemtests.m4 - BitKeeper/triggers/post-incoming.license-warn@1.7, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + sntp/m4/ntp_problemtests.m4@1.0 +0 -0 - BitKeeper/triggers/pre-resolve.licfix@1.4, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +1 -1 - trigger email address cleanup + tests/ntpd/Makefile.am@1.28 +14 -3 + Disable certain test programs on certain platforms. Harlan Stenn. - BitKeeper/triggers/send@1.14, 2009-03-28 02:45:22-05:00, stenn@whimsy.udel.edu +2 -2 - trigger email address cleanup +ChangeSet@1.3552.9.1, 2015-09-28 18:22:06+02:00, jnperlin@hydra.localnet + [Bug 2909] - Slow memory leak in CRYPTO_ASSOC + - added missing call to 'free()' in ntp_crypto.c. - ChangeLog@1.58, 2009-03-28 02:46:36-05:00, stenn@whimsy.udel.edu +3 -1 - build system email address cleanup + ChangeLog@1.1739.5.1 +1 -0 + [Bug 2909] - Slow memory leak in CRYPTO_ASSOC + - added missing call to 'free()' in ntp_crypto.c. -ChangeSet@1.1559, 2009-03-24 15:22:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - config.h: - include winsock.h before ws2tcpip.h to fix VS 2005 build + ntpd/ntp_crypto.c@1.181.1.1 +1 -0 + [Bug 2909] - Slow memory leak in CRYPTO_ASSOC + - added missing call to 'free()' in ntp_crypto.c. - ports/winnt/include/config.h@1.49, 2009-03-24 15:22:23+00:00, davehart@shiny.ad.hartbrothers.com +8 -5 - include winsock.h before ws2tcpip.h to fix VS 2005 build +ChangeSet@1.3556, 2015-09-27 12:52:27+02:00, jnperlin@hydra.localnet + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments -ChangeSet@1.1549.4.2, 2009-03-24 15:14:36+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ntp_iocompletionport.c: - use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + tests/libntp/buftvtots.c@1.5 +7 -7 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments - ports/winnt/ntpd/ntp_iocompletionport.c@1.26.1.2, 2009-03-24 15:14:23+00:00, davehart@shiny.ad.hartbrothers.com +10 -1 - use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + tests/libntp/calendar.c@1.9 +45 -35 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments -ChangeSet@1.1557, 2009-03-22 21:09:43+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - Makefile.am, ChangeLog: - [Bug 774] parsesolaris.c does not compile under the new Solaris + tests/libntp/clocktime.c@1.8 +16 -16 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments - ChangeLog@1.57, 2009-03-22 21:09:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 774] parsesolaris.c does not compile under the new Solaris + tests/libntp/hextolfp.c@1.9 +9 -9 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments - libparse/Makefile.am@1.9, 2009-03-22 21:09:42+00:00, davehart@shiny.ad.hartbrothers.com +1 -1 - [Bug 774] parsesolaris.c does not compile under the new Solaris + tests/libntp/lfptostr.c@1.7 +14 -14 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments -ChangeSet@1.1556, 2009-03-20 03:39:26+00:00, hart@pogo.udel.edu +1 -0 - ChangeLog: - bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + tests/libntp/prettydate.c@1.4 +1 -1 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments - ChangeLog@1.56, 2009-03-20 03:39:16+00:00, hart@pogo.udel.edu +0 -2 - bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + tests/libntp/strtolfp.c@1.6 +3 -3 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments -ChangeSet@1.1553, 2009-03-20 03:10:22+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - ChangeLog: - remove blank first line + tests/libntp/tstotv.c@1.4 +3 -3 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments - ChangeLog@1.53, 2009-03-20 03:09:55+00:00, davehart@shiny.ad.hartbrothers.com +0 -1 - remove blank first line + tests/libntp/tvtots.c@1.6 +10 -10 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments -ChangeSet@1.1549.4.1, 2009-03-20 01:46:15+00:00, davehart@shiny.ad.hartbrothers.com +10 -0 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + tests/libntp/uglydate.c@1.8 +1 -1 + [Bug2888] Fixed compiler warnings, converted C++ comments to C comments - ChangeLog@1.50.4.1, 2009-03-20 01:46:11+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 873] Windows serial refclock proper TTY line discipline emulation +ChangeSet@1.3552.8.1, 2015-09-27 02:30:13+00:00, mayer@psp-deb1.ntp.org + Drop invalid packet before checking KoD. Check for all KoD's - ntpd/ntp_io.c@1.256.1.1, 2009-03-20 01:46:11+00:00, davehart@shiny.ad.hartbrothers.com +26 -23 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ChangeLog@1.1739.4.1 +1 -0 + Drop invalid packet before checking KoD. Check for all KoD's - ntpd/ntpd.c@1.86, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +14 -25 - slightly reduce #ifdef SYS_WINNT forest + ntpd/ntp_proto.c@1.365 +66 -9 + Drop invalid packet before checking KoD. Check for all KoD's - ntpd/refclock_dumbclock.c@1.9, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation +ChangeSet@1.3552.1.29, 2015-09-26 13:17:13+00:00, perlinger@psp-deb1.ntp.org + [bug2332] Create & cancel a dummy thread to warm-up the pthread runtime + instead of linking against libgcc_s on Linux targets - ntpd/refclock_hopfser.c@1.10, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ChangeLog@1.1739.1.15 +3 -0 + [Bug2332](reopened) fixed - ntpd/refclock_nmea.c@1.26, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + ntpd/ntpd.c@1.165 +74 -0 + [bug2332] Create & cancel a dummy thread to warm-up the pthread runtime - ntpd/refclock_palisade.c@1.19, 2009-03-20 01:46:12+00:00, davehart@shiny.ad.hartbrothers.com +6 -5 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + sntp/m4/ntp_libntp.m4@1.32 +0 -14 + [bug2332] Remove the forced link against 'libgcc_s' since it breaks other targets - ports/winnt/include/ntp_iocompletionport.h@1.14, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +8 -9 +ChangeSet@1.3552.7.6, 2015-09-25 06:51:35+00:00, stenn@psp-deb1.ntp.org + gcc on older HPUX may need +allowdups. Harlan Stenn. + + sntp/m4/os_cflags.m4@1.12 +1 -1 + gcc on older HPUX may need +allowdups. Harlan Stenn. + +ChangeSet@1.3552.7.5, 2015-09-25 04:21:37+00:00, stenn@psp-deb1.ntp.org + Adding missing MCAST protection. Harlan Stenn. + + ChangeLog@1.1739.1.14 +1 -0 + Adding missing MCAST protection. Harlan Stenn. + + ntpd/ntp_io.c@1.406 +2 -0 + Adding missing MCAST protection. Harlan Stenn. + +ChangeSet@1.3552.7.4, 2015-09-25 04:13:23+00:00, stenn@psp-deb1.ntp.org + gcc on older HPUX may need +allowdups. Harlan Stenn. + + ChangeLog@1.1739.1.13 +1 -0 + gcc on older HPUX may need +allowdups. Harlan Stenn. + + sntp/m4/os_cflags.m4@1.11 +32 -2 + gcc on older HPUX may need +allowdups. Harlan Stenn. + +ChangeSet@1.3552.7.3, 2015-09-24 11:27:07+00:00, stenn@psp-deb1.ntp.org + More updates for bug 2817. Harlan Stenn. + + ntpd/ntpd.c@1.164 +1 -1 + More updates for bug 2817. Harlan Stenn. + +ChangeSet@1.3552.7.2, 2015-09-24 10:27:51+00:00, stenn@psp-deb1.ntp.org + More updates for bug 2817. Harlan Stenn. + + ntpd/ntpd.c@1.163 +6 -3 + More updates for bug 2817. Harlan Stenn. + +ChangeSet@1.3552.7.1, 2015-09-24 05:44:53+00:00, stenn@psp-deb1.ntp.org + Fix bugs in tests/ntpd/ntp_prio_q.c. Harlan Stenn. + + ChangeLog@1.1739.1.12 +1 -0 + Fix bugs in tests/ntpd/ntp_prio_q.c. Harlan Stenn. + + tests/ntpd/ntp_prio_q.c@1.2 +8 -7 + Fix bugs in tests/ntpd/ntp_prio_q.c. Harlan Stenn. + +ChangeSet@1.3552.1.23, 2015-09-23 07:49:24-04:00, stenn@deacon.udel.edu + More updates for bug 2817. Harlan Stenn. + + sntp/m4/ntp_rlimit.m4@1.5 +5 -5 + More updates for bug 2817. Harlan Stenn. + +ChangeSet@1.3552.1.22, 2015-09-23 10:29:51+00:00, stenn@psp-deb1.ntp.org + More updates for bug 2817. Harlan Stenn. + + ChangeLog@1.1739.1.11 +1 -0 + More updates for bug 2817. Harlan Stenn. + + html/miscopt.html@1.83 +2 -2 + More updates for bug 2817. Harlan Stenn. + + include/ntp_config.h@1.83 +2 -2 + More updates for bug 2817. Harlan Stenn. + + ntpd/invoke-ntp.conf.texi@1.190 +8 -5 + More updates for bug 2817. Harlan Stenn. + + ntpd/ntp.conf.5man@1.224 +9 -6 + More updates for bug 2817. Harlan Stenn. + + ntpd/ntp.conf.5mdoc@1.224 +9 -6 + More updates for bug 2817. Harlan Stenn. + + ntpd/ntp.conf.def@1.20 +6 -3 + More updates for bug 2817. Harlan Stenn. + + ntpd/ntp.conf.man.in@1.224 +9 -6 + More updates for bug 2817. Harlan Stenn. + + ntpd/ntp.conf.mdoc.in@1.224 +9 -6 + More updates for bug 2817. Harlan Stenn. + + ntpd/ntp_config.c@1.334 +26 -4 + More updates for bug 2817. Harlan Stenn. + + ntpd/ntpd.c@1.162 +1 -1 + More updates for bug 2817. Harlan Stenn. + + sntp/m4/ntp_rlimit.m4@1.4 +2 -2 + More updates for bug 2817. Harlan Stenn. + +ChangeSet@1.3552.1.21, 2015-09-21 10:53:44+00:00, stenn@psp-deb1.ntp.org + Update the patch for bug 2817. Harlan Stenn. + + ChangeLog@1.1739.1.10 +1 -0 + Update the patch for bug 2817. Harlan Stenn. + + configure.ac@1.601 +0 -54 + Update the patch for bug 2817. Harlan Stenn. + + sntp/m4/ntp_rlimit.m4@1.3 +57 -2 + Update the patch for bug 2817. Harlan Stenn. + +ChangeSet@1.3552.1.20, 2015-09-21 10:30:35+00:00, stenn@psp-deb1.ntp.org + Clean trailing whitespace in tests/ntpd/Makefile.am. Harlan Stenn. + + ChangeLog@1.1739.1.9 +1 -0 + Clean trailing whitespace in tests/ntpd/Makefile.am. Harlan Stenn. + + tests/ntpd/Makefile.am@1.27 +5 -5 + Clean trailing whitespace in tests/ntpd/Makefile.am. Harlan Stenn. + +ChangeSet@1.3552.1.19, 2015-09-21 08:09:33+00:00, stenn@psp-deb1.ntp.org + Fix progname definition in unity runner scripts. Harlan Stenn. + + ChangeLog@1.1739.1.8 +1 -0 + Fix progname definition in unity runner scripts. Harlan Stenn. + + sntp/tests/run-packetProcessing.c@1.9 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + sntp/tests/run-t-log.c@1.3 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + sntp/unity/auto/generate_test_runner.rb@1.10 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-a_md5encrypt.c@1.14 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-atoint.c@1.8 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-atouint.c@1.9 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-authkeys.c@1.11 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-buftvtots.c@1.6 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-calendar.c@1.8.1.1 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-caljulian.c@1.13 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-caltontp.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-calyearstart.c@1.7 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-clocktime.c@1.10 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-decodenetnum.c@1.9 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-hextoint.c@1.9 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-hextolfp.c@1.8 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-humandate.c@1.6 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-lfpfunc.c@1.17 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-lfptostr.c@1.7 +12 -12 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-modetoa.c@1.11 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-msyslog.c@1.8 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-netof.c@1.7 +2 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-numtoa.c@1.10 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-numtohost.c@1.10 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-octtoint.c@1.7 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-prettydate.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-recvbuff.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-refidsmear.c@1.6 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-refnumtoa.c@1.8 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-sfptostr.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-socktoa.c@1.12 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-ssl_init.c@1.9 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-statestr.c@1.10 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-strtolfp.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-timespecops.c@1.10 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-timevalops.c@1.12 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-tstotv.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-tvtots.c@1.6 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-uglydate.c@1.10 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-vi64ops.c@1.8 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/libntp/run-ymd2yd.c@1.11 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/ntpd/run-leapsec.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/ntpd/run-ntp_prio_q.c@1.4 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/ntpd/run-rc_cmdlength.c@1.3 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/ntpd/run-t-ntp_scanner.c@1.5 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/ntpd/run-t-ntp_signd.c@1.8 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + + tests/ntpq/run-t-ntpq.c@1.3 +1 -1 + Fix progname definition in unity runner scripts. Harlan Stenn. + +ChangeSet@1.3552.1.18, 2015-09-21 08:06:14+00:00, stenn@psp-deb1.ntp.org + Pthread autoconf macro cleanup. Harlan Stenn. + + ChangeLog@1.1739.1.7 +1 -0 + Pthread autoconf macro cleanup. Harlan Stenn. + + sntp/m4/ntp_libevent.m4@1.15 +15 -19 + Pthread autoconf macro cleanup. Harlan Stenn. + + sntp/m4/ntp_libntp.m4@1.31 +5 -2 + Pthread autoconf macro cleanup. Harlan Stenn. + + sntp/m4/openldap-thread-check.m4@1.7 +6 -0 + Pthread autoconf macro cleanup. Harlan Stenn. + +ChangeSet@1.3552.1.16, 2015-09-17 11:09:07+00:00, stenn@psp-deb1.ntp.org + Avoid spurious SCCS get + + ntpd/Makefile.am@1.134 +3 -0 + Avoid spurious SCCS get + +ChangeSet@1.3552.6.3, 2015-09-16 11:10:41+00:00, stenn@psp-deb1.ntp.org + Cleanup various test Makefile.am files. Harlan Stenn. + + ChangeLog@1.1739.1.6 +1 -0 + Cleanup various test Makefile.am files. Harlan Stenn. + + sntp/tests/Makefile.am@1.64.1.3 +5 -5 + Cleanup various test Makefile.am files. Harlan Stenn. + + tests/libntp/Makefile.am@1.93 +23 -23 + Cleanup various test Makefile.am files. Harlan Stenn. + + tests/ntpd/Makefile.am@1.22.1.3 +7 -12 + Cleanup various test Makefile.am files. Harlan Stenn. + + tests/ntpq/Makefile.am@1.5.1.1 +3 -10 + Cleanup various test Makefile.am files. Harlan Stenn. + +ChangeSet@1.3552.6.2, 2015-09-15 10:44:48+00:00, stenn@psp-deb1.ntp.org + Unit test dist cleanup. Harlan Stenn + + ChangeLog@1.1739.1.5 +1 -0 + Unit test dist cleanup. Harlan Stenn + + sntp/configure.ac@1.82 +1 -0 + Unit test dist cleanup. Harlan Stenn + + sntp/tests/Makefile.am@1.64.1.2 +2 -0 + Unit test dist cleanup. Harlan Stenn + + tests/Makefile.am@1.17.1.1 +1 -0 + Unit test dist cleanup. Harlan Stenn + + tests/ntpd/Makefile.am@1.22.1.2 +0 -9 + Unit test dist cleanup. Harlan Stenn + +ChangeSet@1.3552.5.6, 2015-09-15 07:45:39+00:00, stenn@psp-deb1.ntp.org + [Bug 2906] make check needs better support for pthreads. Harlan Stenn. + + sntp/m4/ntp_libevent.m4@1.14 +23 -0 + [Bug 2906] make check needs better support for pthreads. Harlan Stenn. + +ChangeSet@1.3552.5.5, 2015-09-15 07:12:08+00:00, stenn@psp-deb1.ntp.org + documentation notes + + sntp/m4/openldap-thread-check.m4@1.6 +3 -0 + documentation notes + +ChangeSet@1.3552.5.4, 2015-09-14 06:36:37+00:00, stenn@psp-deb1.ntp.org + [Bug 2906] "make check" needs better support for pthreads + + ChangeLog@1.1739.3.4 +1 -0 + [Bug 2906] "make check" needs better support for pthreads + + sntp/m4/ntp_libevent.m4@1.13 +2 -0 + [Bug 2906] "make check" needs better support for pthreads + + sntp/tests/Makefile.am@1.62.2.1 +5 -0 + [Bug 2906] "make check" needs better support for pthreads + + tests/libntp/Makefile.am@1.90.1.1 +12 -12 + [Bug 2906] "make check" needs better support for pthreads + + tests/ntpd/Makefile.am@1.12.3.1 +4 -2 + [Bug 2906] "make check" needs better support for pthreads + +ChangeSet@1.3552.5.3, 2015-09-14 05:50:02+00:00, stenn@psp-deb1.ntp.org + [Bug 2907] dist* build targets require our libevent/ to be enabled. HStenn. + + ChangeLog@1.1739.3.3 +1 -0 + [Bug 2907] dist* build targets require our libevent/ to be enabled. HStenn. + + sntp/Makefile.am@1.86.1.1 +7 -4 + [Bug 2907] dist* build targets require our libevent/ to be enabled. HStenn. + +ChangeSet@1.3552.5.2, 2015-09-13 22:11:31+00:00, stenn@psp-deb1.ntp.org + Autoconf cleanup + + ChangeLog@1.1739.3.2 +1 -0 + Autoconf cleanup + + configure.ac@1.598.1.1 +1 -0 + Autoconf cleanup + +ChangeSet@1.3552.5.1, 2015-09-13 22:10:03+00:00, stenn@psp-deb1.ntp.org + Update the NEWS file + + ChangeLog@1.1739.3.1 +1 -0 + Update the NEWS file + + NEWS@1.146 +14 -0 + Update the NEWS file + +ChangeSet@1.3552.1.15, 2015-08-20 17:13:37+02:00, viperus@ubuntu.(none) + t-ntp_scanner.c: + Rename: tests/ntpd/ntp_scanner.c -> tests/ntpd/t-ntp_scanner.c + new static functions tested + run-t-ntp_scanner.c: + Rename: tests/ntpd/run-ntp_scanner.c -> tests/ntpd/run-t-ntp_scanner.c + Makefile.am: + updates required for include *.c to work + run-t-ntp_scanner.c: + update + + tests/ntpd/Makefile.am@1.25 +6 -5 + updates required for include *.c to work + + tests/ntpd/run-t-ntp_scanner.c@1.4 +18 -7 + update + + tests/ntpd/run-t-ntp_scanner.c@1.3 +0 -0 + Rename: tests/ntpd/run-ntp_scanner.c -> tests/ntpd/run-t-ntp_scanner.c + + tests/ntpd/t-ntp_scanner.c@1.5 +73 -2 + new static functions tested + + tests/ntpd/t-ntp_scanner.c@1.4 +0 -0 + Rename: tests/ntpd/ntp_scanner.c -> tests/ntpd/t-ntp_scanner.c + +ChangeSet@1.3552.1.14, 2015-08-20 16:35:29+02:00, viperus@ubuntu.(none) + t-ntpq.c: + disabled for now, very trick to test static functions. + run-t-ntpq.c: + update + ntp_scanner.c: + added new test + Makefile.am: + added more include dirs + + tests/ntpd/ntp_scanner.c@1.3 +11 -3 + added new test + + tests/ntpq/Makefile.am@1.7 +2 -3 + added more include dirs + + tests/ntpq/run-t-ntpq.c@1.2 +1 -2 + update + + tests/ntpq/t-ntpq.c@1.3 +25 -2 + disabled for now, very trick to test static functions. + +ChangeSet@1.3552.1.13, 2015-08-20 10:15:12+02:00, viperus@ubuntu.(none) + http-server.c: + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + Many files: + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + + sntp/libevent/sample/http-server.c@1.12 +6 -2 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + sntp/libevent/test/bench_httpclient.c@1.8 +5 -1 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + + sntp/libevent/test/regress.c@1.8 +6 -2 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + + sntp/libevent/test/regress_dns.c@1.10 +6 -5 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + + sntp/libevent/test/regress_http.c@1.10 +8 -4 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + + sntp/libevent/test/regress_minheap.c@1.5 +2 -1 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + + sntp/libevent/test/test-ratelim.c@1.11 +6 -2 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + + sntp/libevent/test/test-time.c@1.7 +2 -1 + reverted emalloc (and similar) to malloc + added checks if malloc is NULL, because emalloc is not linked here. + + +ChangeSet@1.3552.1.12, 2015-08-20 01:10:57+02:00, viperus@ubuntu.(none) + Makefile.am: + added 2 more temp files to CLEANFILES and DISTCLEAN, because it prevented make distcheck from finishing properly + pathfind.c: + reverted emalloc to malloc with if(result == NULL)... because sntp/ doesn't link libntp...probably for a reason unknown to me. + + sntp/libopts/compat/pathfind.c@1.13 +17 -6 + reverted emalloc to malloc with if(result == NULL)... because sntp/ doesn't link libntp...probably for a reason unknown to me. + + sntp/tests/Makefile.am@1.65 +4 -0 + added 2 more temp files to CLEANFILES and DISTCLEAN, because it prevented make distcheck from finishing properly + +ChangeSet@1.3552.1.11, 2015-08-20 01:04:40+02:00, viperus@ubuntu.(none) + run-packetProcessing.c: + manually updated due to char / const char progname issues when autogenerating + Makefile.am: + re-enabled ntpq dir + + sntp/tests/run-packetProcessing.c@1.8 +1 -1 + manually updated due to char / const char progname issues when autogenerating + + tests/Makefile.am@1.18 +1 -0 + re-enabled ntpq dir + +ChangeSet@1.3552.1.10, 2015-08-20 00:23:42+02:00, viperus@ubuntu.(none) + machines.c: + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + Many files: + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + libntp/machines.c@1.26 +3 -3 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + ntpd/refclock_palisade.c@1.43 +2 -2 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + ntpq/ntpq.c@1.161 +7 -7 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/sample/http-server.c@1.11 +2 -2 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/test/bench_httpclient.c@1.7 +1 -1 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/test/regress.c@1.7 +2 -2 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/test/regress_dns.c@1.9 +4 -4 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/test/regress_http.c@1.9 +3 -3 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/test/regress_minheap.c@1.4 +1 -1 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/test/test-ratelim.c@1.10 +2 -2 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libevent/test/test-time.c@1.6 +1 -1 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/libopts/compat/pathfind.c@1.12 +5 -5 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/tests/fileHandlingTest.c@1.3 +1 -1 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + sntp/tests/packetProcessing.c@1.8 +1 -1 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + tests/libntp/a_md5encrypt.c@1.12 +1 -1 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + tests/libntp/calendar.c@1.6.1.1 +4 -4 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + + tests/libntp/caljulian.c@1.10 +1 -1 + Fixing bug 2898, replacing malloc with emalloc, calloc with emalloc_zero, strdup with estrup etc. + + +ChangeSet@1.3552.1.9, 2015-08-17 13:56:23+02:00, viperus@ubuntu.(none) + Makefile.am: + fixed minor typo which caused me a lot of headache + t-ntp_signd.c: + added a new test + run-t-ntp_signd.c: + autogen update + Makefile.am: + removed unnecessary CFLAG + t-ntp_signd.c: + minor update + + tests/ntpd/Makefile.am@1.24 +2 -1 + fixed minor typo which caused me a lot of headache + + tests/ntpd/Makefile.am@1.23 +0 -3 + removed unnecessary CFLAG + + tests/ntpd/run-t-ntp_signd.c@1.7 +10 -5 + autogen update + + tests/ntpd/t-ntp_signd.c@1.10 +23 -14 + added a new test + + tests/ntpd/t-ntp_signd.c@1.9 +10 -3 + minor update + +ChangeSet@1.3552.1.8, 2015-08-17 12:21:45+02:00, viperus@ubuntu.(none) + run-t-ntp_signd.c: + added more tests manually + + tests/ntpd/run-t-ntp_signd.c@1.6 +2 -1 + added more tests manually + + tests/ntpd/t-ntp_signd.c@1.8 +0 -1 + +ChangeSet@1.3552.1.7, 2015-08-17 12:15:56+02:00, viperus@ubuntu.(none) + t-ntp_signd.c: + adding more tests , added mocked functinos section + + tests/ntpd/t-ntp_signd.c@1.7 +34 -0 + adding more tests , added mocked functinos section + +ChangeSet@1.3552.1.6, 2015-08-17 11:28:21+02:00, viperus@ubuntu.(none) + t-ntp_signd.c: + new tests added + run-t-ntp_signd.c: + I had some issues with bk and this file + t-ntp_signd.c: + basic mocking concept added. connect() is mocked, and always returns 1 + + tests/ntpd/run-t-ntp_signd.c@1.5 +4 -2 + I had some issues with bk and this file + + tests/ntpd/t-ntp_signd.c@1.6 +13 -9 + basic mocking concept added. connect() is mocked, and always returns 1 + + tests/ntpd/t-ntp_signd.c@1.5 +22 -2 + new tests added + +ChangeSet@1.3552.4.1, 2015-08-17 07:54:01+02:00, jnperlin@hydra.(none) + CVE-2014-9297 + + ChangeLog@1.1739.2.1 +1 -0 + CVE-2014-9297 + + ntpd/ntp_crypto.c@1.182 +78 -27 + CVE-2014-9297: buffer overrun checks + +ChangeSet@1.3552.3.1, 2015-08-14 12:05:44+02:00, viperus@ubuntu.(none) + Makefile.am: + removed unnecessary CFLAGS + + tests/ntpq/Makefile.am@1.6 +0 -5 + removed unnecessary CFLAGS + +ChangeSet@1.3552.1.4, 2015-08-14 08:24:21+00:00, stenn@psp-at1.ntp.org + Unity test cleanup: move declaration of 'initializing'. Harlan Stenn. + + ChangeLog@1.1739.1.3 +1 -0 + Unity test cleanup: move declaration of 'initializing'. Harlan Stenn. + + ntpd/ntp_timer.c@1.92 +6 -0 + Unity test cleanup: move declaration of 'initializing'. Harlan Stenn. + + ntpd/ntpd.c@1.161 +0 -6 + Unity test cleanup: move declaration of 'initializing'. Harlan Stenn. + +ChangeSet@1.3552.1.3, 2015-08-10 13:15:13+02:00, viperus@ubuntu.(none) + run-ntp_util.c: + new file, I guess? + Makefile.am: + changes to harlan's makefile after merge + run-ntp_prio_q.c: + hopefully, fixes stuff. Why is this here? Did harlan pull something from tfendrich? + + tests/ntpd/Makefile.am@1.22 +13 -13 + changes to harlan's makefile after merge + + tests/ntpd/run-ntp_prio_q.c@1.3 +1 -1 + hopefully, fixes stuff. Why is this here? Did harlan pull something from tfendrich? + + tests/ntpd/run-ntp_util.c@1.1 +60 -0 + new file, I guess? + + tests/ntpd/run-ntp_util.c@1.0 +0 -0 + +ChangeSet@1.3552.2.1, 2015-08-10 09:50:16+00:00, stenn@psp-at1.ntp.org + Retire google test - phase I. Harlan Stenn. + + BitKeeper/deleted/07/g_packetHandling.cpp~2e07085e82bde6c@1.2 +0 -0 + Delete: sntp/tests/g_packetHandling.cpp + + BitKeeper/deleted/09/tvtots.cpp~c58754a7b62dde1c@1.9 +0 -0 + Delete: tests/libntp/g_tvtots.cpp + + BitKeeper/deleted/0a/sntptest.h~c408c7764b75cd4f@1.7 +0 -0 + Delete: sntp/tests/g_sntptest.h + + BitKeeper/deleted/0a/utilities.cpp~2657edd0f94e49eb@1.12 +0 -0 + Delete: sntp/tests/g_utilities.cpp + + BitKeeper/deleted/0c/buftvtots.cpp~eababa3e59583108@1.6 +0 -0 + Delete: tests/libntp/g_buftvtots.cpp + + BitKeeper/deleted/0f/uglydate.cpp~a0fdfbbfdc636411@1.5 +0 -0 + Delete: tests/libntp/g_uglydate.cpp + + BitKeeper/deleted/10/sfptostr.cpp~cef5595e4f89eac8@1.4 +0 -0 + Delete: tests/libntp/g_sfptostr.cpp + + BitKeeper/deleted/13/g_lfptostr.cpp~386d730e91bb76de@1.3 +0 -0 + Delete: tests/libntp/g_lfptostr.cpp + + BitKeeper/deleted/14/humandate.cpp~c3b455ca717b631a@1.5 +0 -0 + Delete: tests/libntp/g_humandate.cpp + + BitKeeper/deleted/15/g_nameresolution.cpp~23956912aa26e0b9@1.2 +0 -0 + Delete: sntp/tests/g_nameresolution.cpp + + BitKeeper/deleted/17/a_md5encrypt.cpp~1013ff09a55a7336@1.8 +0 -0 + Delete: tests/libntp/g_a_md5encrypt.cpp + + BitKeeper/deleted/1c/crypto.cpp~77bbd0102246a5@1.7 +0 -0 + Delete: sntp/tests/g_crypto.cpp + + BitKeeper/deleted/24/atoint.cpp~533534d530ae4081@1.5 +0 -0 + Delete: tests/libntp/g_atoint.cpp + + BitKeeper/deleted/29/networking.cpp~a6f1b3f0b76192c9@1.11 +0 -0 + Delete: sntp/tests/g_networking.cpp + + BitKeeper/deleted/29/refnumtoa.cpp~ed3c5e075503bdf4@1.5 +0 -0 + Delete: tests/libntp/g_refnumtoa.cpp + + BitKeeper/deleted/2d/libntptest.h~1990ef7fb70295d6@1.6 +0 -0 + Delete: tests/libntp/g_libntptest.h + + BitKeeper/deleted/30/g_recvbuff.cpp~7b0d3114520a0616@1.3 +0 -0 + Delete: tests/libntp/g_recvbuff.cpp + + BitKeeper/deleted/30/main.cpp~62ec7f38f7d49413@1.10 +0 -0 + Delete: sntp/tests_main.cpp + + BitKeeper/deleted/37/statestr.cpp~65497a98bac68a52@1.5 +0 -0 + Delete: tests/libntp/g_statestr.cpp + + BitKeeper/deleted/3b/tvalops.cpp~fa0bb1554d1d08d4@1.11 +0 -0 + Delete: tests/libntp/g_timevalops.cpp + + BitKeeper/deleted/3c/g_octtoint.cpp~8124d76dd2b395e5@1.3 +0 -0 + Delete: tests/libntp/g_octtoint.cpp + + BitKeeper/deleted/3f/calendar.cpp~72447c9b8c0deced@1.4 +0 -0 + Delete: tests/libntp/g_calendar.cpp + + BitKeeper/deleted/4e/g_hextolfp.cpp~ba8561698c15b354@1.3 +0 -0 + Delete: tests/libntp/g_hextolfp.cpp + + BitKeeper/deleted/57/ntpdtest.h~25bdfa3eeda7b121@1.3 +0 -0 + Delete: tests/ntpd/g_ntpdtest.h + + BitKeeper/deleted/5b/sockaddrtest.h~4bf7e82961607bf0@1.6 +0 -0 + Delete: tests/libntp/g_sockaddrtest.h + + BitKeeper/deleted/5f/authkeys.cpp~24496a9d93173937@1.10 +0 -0 + Delete: tests/libntp/g_authkeys.cpp + + BitKeeper/deleted/62/g_strtolfp.cpp~5a50a9b282094e7f@1.3 +0 -0 + Delete: tests/libntp/g_strtolfp.cpp + + BitKeeper/deleted/77/lfpfunc.cpp~9ed51f8dc31368eb@1.5 +0 -0 + Delete: tests/libntp/g_lfpfunc.cpp + + BitKeeper/deleted/82/clocktime.cpp~7dd85c09c049ffd4@1.7 +0 -0 + Delete: tests/libntp/g_clocktime.cpp + + BitKeeper/deleted/8b/atouint.cpp~43abc72d64a1857a@1.4 +0 -0 + Delete: tests/libntp/g_atouint.cpp + + BitKeeper/deleted/8b/leapsec.cpp~11be64d438063292@1.17 +0 -0 + Delete: tests/ntpd/g_leapsec.cpp + + BitKeeper/deleted/93/g_vi64ops.cpp~e023cb72bff45261@1.3 +0 -0 + Delete: tests/libntp/g_vi64ops.cpp + + BitKeeper/deleted/96/numtoa.cpp~b3b85b1ebc36fc2b@1.5 +0 -0 + Delete: tests/libntp/g_numtoa.cpp + + BitKeeper/deleted/98/g_tstotv.cpp~37896736f73c48b0@1.3 +0 -0 + Delete: tests/libntp/g_tstotv.cpp + + BitKeeper/deleted/9a/packetProcessing.cpp~4822a1d49ca16be5@1.8 +0 -0 + Delete: sntp/tests/g_packetProcessing.cpp + + BitKeeper/deleted/9c/kodDatabase.cpp~f9244577ca9f0aa9@1.6 +0 -0 + Delete: sntp/tests/g_kodDatabase.cpp + + BitKeeper/deleted/a4/g_msyslog.cpp~ec51c9e8395b3e4b@1.3 +0 -0 + Delete: tests/libntp/g_msyslog.cpp + + BitKeeper/deleted/ae/lfptest.h~a452179b90fdedaa@1.8 +0 -0 + Delete: tests/libntp/g_lfptest.h + + BitKeeper/deleted/af/calyearstart.cpp~586f44f58a75b25e@1.6 +0 -0 + Delete: tests/libntp/g_calyearstart.cpp + + BitKeeper/deleted/b2/ntpdtest.cpp~d4e605db974f754d@1.4 +0 -0 + Delete: tests/ntpd/g_ntpdtest.cpp + + BitKeeper/deleted/b3/timestructs.cpp~2bc53cc52f6599d5@1.7 +0 -0 + Delete: tests/libntp/g_timestructs.cpp + + BitKeeper/deleted/c1/ssl_init.cpp~81ce47bbb0e4fbbc@1.6 +0 -0 + Delete: tests/libntp/g_ssl_init.cpp + + BitKeeper/deleted/c3/modetoa.cpp~50f2955120b0ed6f@1.4 +0 -0 + Delete: tests/libntp/g_modetoa.cpp + + BitKeeper/deleted/c6/kodFile.cpp~c593859a65c8e9e3@1.11 +0 -0 + Delete: sntp/tests/g_kodFile.cpp + + BitKeeper/deleted/c9/main.h~44cc5c4040b89c30@1.9 +0 -0 + Delete: sntp/tests_main.h + + BitKeeper/deleted/ce/timestructs.h~a7213e57006326f@1.6 +0 -0 + Delete: tests/libntp/g_timestructs.h + + BitKeeper/deleted/cf/libntptest.cpp~fb911e064fe18517@1.6 +0 -0 + Delete: tests/libntp/g_libntptest.cpp + + BitKeeper/deleted/d0/g_caltontp.cpp~ea2471ca2734873a@1.3 +0 -0 + Delete: tests/libntp/g_caltontp.cpp + + BitKeeper/deleted/d8/hextoint.cpp~78aeb35b2f896bed@1.6 +0 -0 + Delete: tests/libntp/g_hextoint.cpp + + BitKeeper/deleted/dd/keyFile.cpp~7ca67d971ffc97ae@1.9 +0 -0 + Delete: sntp/tests/g_keyFile.cpp + + BitKeeper/deleted/e0/g_socktoa.cpp~9f28a4451c7f0c1a@1.3 +0 -0 + Delete: tests/libntp/g_socktoa.cpp + + BitKeeper/deleted/eb/g_prettydate.cpp~7800800c1dbf9688@1.3 +0 -0 + Delete: tests/libntp/g_prettydate.cpp + + BitKeeper/deleted/ee/caljulian.cpp~4c368703107f888@1.8 +0 -0 + Delete: tests/libntp/g_caljulian.cpp + + BitKeeper/deleted/ef/fileHandlingTest.h~212fb01783c1dfd7@1.7 +0 -0 + Delete: sntp/tests/g_fileHandlingTest.h + + BitKeeper/deleted/f6/g_decodenetnum.cpp~5b151a58bf8417a2@1.3 +0 -0 + Delete: tests/libntp/g_decodenetnum.cpp + + BitKeeper/deleted/f8/g_netof.cpp~a772fe4f2f1b84e8@1.3 +0 -0 + Delete: tests/libntp/g_netof.cpp + + BitKeeper/deleted/fa/tspecops.cpp~fabae81f65cd8134@1.11 +0 -0 + Delete: tests/libntp/g_timespecops.cpp + + BitKeeper/deleted/fd/ymd2yd.cpp~eeb76d1d2a534b6@1.4 +0 -0 + Delete: tests/libntp/g_ymd2yd.cpp + + BitKeeper/deleted/ff/numtohost.cpp~c346ee31ae5ffefe@1.4 +0 -0 + Delete: tests/libntp/g_numtohost.cpp + + ChangeLog@1.1739.1.2 +1 -1 + Retire google test - phase I. Harlan Stenn. + + ChangeLog@1.1739.1.1 +1 -0 + Retire google test - phase I + + sntp/Makefile.am@1.87 +0 -1 + Retire google test - phase I. Harlan Stenn. + + sntp/tests/Makefile.am@1.62.1.1 +15 -28 + Retire google test - phase I. Harlan Stenn. + + tests/Makefile.am@1.12.1.1 +0 -13 + Retire google test - phase I. Harlan Stenn. + + tests/libntp/Makefile.am@1.91 +0 -63 + Retire google test - phase I. Harlan Stenn. + + tests/ntpd/Makefile.am@1.12.2.1 +32 -50 + Retire google test - phase I. Harlan Stenn. + + tests/sandbox/Makefile.am@1.7 +14 -5 + Retire google test - phase I. Harlan Stenn. + +ChangeSet@1.3548.1.16, 2015-08-07 08:07:50+02:00, viperus@ubuntu.(none) + Makefile.am: + re-added ntpq, works now + run-t-ntpq.c: + added + Makefile.am: + minor cleanup + configure.ac: + added ntpq dir + + configure.ac@1.599 +1 -0 + added ntpq dir + + tests/Makefile.am@1.16 +2 -0 + re-added ntpq, works now + + tests/ntpq/Makefile.am@1.5 +0 -1 + minor cleanup + + tests/ntpq/run-t-ntpq.c@1.1 +55 -0 + added + + tests/ntpq/run-t-ntpq.c@1.0 +0 -0 + +ChangeSet@1.3548.1.15, 2015-08-06 21:42:18+02:00, viperus@ubuntu.(none) + Makefile.am: + removed ntpq becuase it doesnt work?! + + tests/Makefile.am@1.15 +0 -2 + removed ntpq becuase it doesnt work?! + +ChangeSet@1.3548.1.14, 2015-08-06 21:03:10+02:00, viperus@ubuntu.(none) + Makefile.am: + adding new Makefile + minor change + Makefile.am, t-ntpq.c: + update + + tests/Makefile.am@1.14 +1 -0 + update + + tests/ntpq/Makefile.am@1.4 +3 -1 + minor change + + tests/ntpq/Makefile.am@1.3 +6 -15 + adding new Makefile + + tests/ntpq/t-ntpq.c@1.2 +1 -1 + update + +ChangeSet@1.3548.1.13, 2015-08-06 20:41:02+02:00, viperus@ubuntu.(none) + socktoa.c: + fixed. Tests are skipped when you do ./build --disable-ipv6 + + t-ntpq.c: + new test file + decodenetnum.c: + fixed. Tests are skipped when you do ./build --disable-ipv6 + Makefile.am: + changes + run-t-log.c: + updated + + sntp/tests/run-t-log.c@1.2 +4 -3 + updated + + tests/libntp/decodenetnum.c@1.9 +3 -3 + fixed. Tests are skipped when you do ./build --disable-ipv6 + + tests/libntp/socktoa.c@1.9 +2 -2 + fixed. Tests are skipped when you do ./build --disable-ipv6 + + + tests/ntpq/Makefile.am@1.2 +8 -37 + changes + + tests/ntpq/t-ntpq.c@1.1 +14 -0 + new test file + + tests/ntpq/t-ntpq.c@1.0 +0 -0 + +ChangeSet@1.3548.1.12, 2015-08-06 20:24:05+02:00, viperus@ubuntu.(none) + log.c: + modified to allow calling of multiple atexit(cleanup_log) without causing a segfault. + t-log.c: + minor cleanup, fixes, stuff works (in combination with updated log.c) + + sntp/log.c@1.24 +15 -6 + modified to allow calling of multiple atexit(cleanup_log) without causing a segfault. + + sntp/tests/t-log.c@1.2 +13 -11 + minor cleanup, fixes, stuff works (in combination with updated log.c) + +ChangeSet@1.3548.1.11, 2015-08-06 10:27:35+02:00, viperus@ubuntu.(none) + Makefile.am: + small fix + socktoa.c, run-decodenetnum.c: + update + decodenetnum.c: + Minor changes due to the autogenerated ruby script + run-socktoa.c: + Minor changes due to the autogenerated ruby script + + + tests/libntp/decodenetnum.c@1.8 +22 -6 + Minor changes due to the autogenerated ruby script + + tests/libntp/run-decodenetnum.c@1.8 +4 -5 + update + + tests/libntp/run-socktoa.c@1.11 +7 -7 + Minor changes due to the autogenerated ruby script + + + tests/libntp/socktoa.c@1.8 +22 -6 + update + + tests/ntpd/Makefile.am@1.20 +0 -1 + small fix + +ChangeSet@1.3548.1.10, 2015-08-05 16:53:22+02:00, viperus@ubuntu.(none) + Makefile.am: + new file + added ntpq dir + added a new test, test-log + t-log.c: + removed the 2nd test because only one open_logfile per program can be used (segfault otherwise) + run-t-log.c: + new file, HAS ISSUES WITH CONST CHAR *progname. + + sntp/tests/Makefile.am@1.63 +11 -0 + added a new test, test-log + + sntp/tests/run-t-log.c@1.1 +56 -0 + new file, HAS ISSUES WITH CONST CHAR *progname. + + sntp/tests/run-t-log.c@1.0 +0 -0 + + sntp/tests/t-log.c@1.1 +66 -0 + removed the 2nd test because only one open_logfile per program can be used (segfault otherwise) + + sntp/tests/t-log.c@1.0 +0 -0 + + tests/Makefile.am@1.13 +2 -0 + added ntpq dir + + tests/ntpq/Makefile.am@1.1 +146 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/ntpq/Makefile.am + + tests/ntpq/Makefile.am@1.0 +0 -0 + +ChangeSet@1.3554, 2015-08-03 20:59:21+02:00, jnperlin@nemesis.localnet + [Bug 2888] streamline calendar functions + - MSVC compilation issue + + libntp/ntp_calendar.c@1.17 +3 -1 + [Bug 2888] streamline calendar functions + - 'uint' not known with MSVC; use u_int instead + +ChangeSet@1.3529.4.1, 2015-08-03 20:34:01+02:00, jnperlin@hydra.(none) + [Bug 2888] streamline calendar functions. + + ChangeLog@1.1725.2.1 +1 -1 + [Bug 2888] streamline calendar functions. + + include/ntp_calendar.h@1.18 +13 -0 + [Bug 2888] streamline calendar functions. + + libntp/ntp_calendar.c@1.16 +495 -321 + [Bug 2888] streamline calendar functions. + - reduce number of divisions for gregorian calendar + - rewrite divisions to use explicit 2's complement calculation via unsigned types + - avoid branches in calculations where possible + + tests/libntp/calendar.c@1.7 +211 -132 + [Bug 2888] streamline calendar functions. + - added tests for ISO8601 week calendar + - streamlined string formatting + - converted struct-by-value to struct-by-pointer in several cases + - fixed prototypes + + tests/libntp/run-calendar.c@1.9 +19 -11 + [Bug 2888] streamline calendar functions. + - update of test runner + +ChangeSet@1.3548.1.9, 2015-08-03 11:43:07+02:00, viperus@ubuntu.(none) + Makefile.am: + changed signdT -> t-ntp_signd. All tests files will from now on be named t-name.c , where name.c is the name of the tested file. + run-ntp_signdT.c~8aba306cc0dcbfc: + Delete: tests/ntpd/run-ntp_signdT.c + run-t-ntp_signd.c: + Rename: tests/ntpd/run-ntp_signd.c -> tests/ntpd/run-t-ntp_signd.c + t-ntp_signd.c: + Rename: tests/ntpd/ntp_signdT.c -> tests/ntpd/t-ntp_signd.c + + BitKeeper/deleted/3a/run-ntp_signdT.c~8aba306cc0dcbfc@1.3 +0 -0 + Delete: tests/ntpd/run-ntp_signdT.c + + tests/ntpd/Makefile.am@1.19 +17 -17 + changed signdT -> t-ntp_signd. All tests files will from now on be named t-name.c , where name.c is the name of the tested file. + + tests/ntpd/run-t-ntp_signd.c@1.4 +0 -0 + Rename: tests/ntpd/run-ntp_signd.c -> tests/ntpd/run-t-ntp_signd.c + + tests/ntpd/t-ntp_signd.c@1.4 +0 -0 + Rename: tests/ntpd/ntp_signdT.c -> tests/ntpd/t-ntp_signd.c + +ChangeSet@1.3548.1.8, 2015-08-03 08:48:00+00:00, viperus@psp-deb1.ntp.org + Makefile.am: + minor fixes, trying to link on psp-deb1 + + tests/ntpd/Makefile.am@1.18 +3 -4 + minor fixes, trying to link on psp-deb1 + +ChangeSet@1.3548.1.7, 2015-08-03 10:36:05+02:00, viperus@ubuntu.(none) + ntp_signdT.c: + added extern, hopefully, it will work + + tests/ntpd/ntp_signdT.c@1.3 +1 -1 + added extern, hopefully, it will work + +ChangeSet@1.3548.1.6, 2015-08-03 10:18:52+02:00, viperus@ubuntu.(none) + Makefile.am: + added rc_cmdlength.o + + tests/ntpd/Makefile.am@1.17 +1 -0 + added rc_cmdlength.o + +ChangeSet@1.3548.1.5, 2015-08-03 10:14:12+02:00, viperus@ubuntu.(none) + Makefile.am: + minor fix + + tests/ntpd/Makefile.am@1.16 +1 -1 + minor fix + +ChangeSet@1.3547.1.1, 2015-08-03 12:30:29+05:30, loki@dadasgift.(none) + ntp_util.c: + new file + + tests/libntp/decodenetnum.c@1.7 +7 -1 + + tests/libntp/socktoa.c@1.7 +8 -1 + + tests/ntpd/Makefile.am@1.12.1.1 +23 -0 + + tests/ntpd/ntp_util.c@1.1 +74 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/ntpd/ntp_util.c + + tests/ntpd/ntp_util.c@1.0 +0 -0 + +ChangeSet@1.3548.1.3, 2015-08-03 08:51:53+02:00, viperus@ubuntu.(none) + ntp_signd.c~736d4c4a37ef4b86: + Delete: tests/ntpd/ntp_signd.c + + BitKeeper/deleted/7f/ntp_signd.c~736d4c4a37ef4b86@1.3 +0 -0 + Delete: tests/ntpd/ntp_signd.c + +ChangeSet@1.3552, 2015-08-03 08:16:57+02:00, jnperlin@nemesis.localnet + [Bug 2889] ntp-dev-4.3.67 does not build on Windows + + ChangeLog@1.1739 +1 -0 + [Bug 2889] ntp-dev-4.3.67 does not build on Windows + + libntp/msyslog.c@1.52 +2 -2 + [Bug 2889] ntp-dev-4.3.67 does not build on Windows + - fixed a Windows-specific const clash in string processing + +ChangeSet@1.3548.1.2, 2015-08-01 22:40:51+02:00, viperus@ubuntu.(none) + ntp_signdT.c: + MUST ADD #define HAVE_NTP_NAME above the #include "ntp_NAME.c" + Makefile.am: + + + Added test ntp_singd again, renamed it to ntp_signdT (including the original ntp_signd.c doesn't work if you have 2 files with the same name). + I included the original ntp_signd.c, so static functions can be tested. + Additional .o objects had to be added for everyhting to work. + + + run-ntp_signdT.c: + autogenerated + + tests/ntpd/Makefile.am@1.14 +7 -2 + + + Added test ntp_singd again, renamed it to ntp_signdT (including the original ntp_signd.c doesn't work if you have 2 files with the same name). + I included the original ntp_signd.c, so static functions can be tested. + Additional .o objects had to be added for everyhting to work. + + + + tests/ntpd/ntp_signdT.c@1.2 +17 -2 + MUST ADD #define HAVE_NTP_NAME above the #include "ntp_NAME.c" + + tests/ntpd/run-ntp_signdT.c@1.2 +2 -2 + autogenerated + +ChangeSet@1.3548.1.1, 2015-08-01 20:49:22+02:00, viperus@ubuntu.(none) + Makefile.am: + added ntp_signdT + ntp_signdT.c, run-ntp_signdT.c: + new file + + tests/ntpd/Makefile.am@1.13 +11 -9 + added ntp_signdT + + tests/ntpd/ntp_signdT.c@1.1 +28 -0 + new file + + tests/ntpd/ntp_signdT.c@1.0 +0 -0 + + tests/ntpd/run-ntp_signdT.c@1.1 +58 -0 + new file + + tests/ntpd/run-ntp_signdT.c@1.0 +0 -0 + +ChangeSet@1.3549.1.1, 2015-07-31 07:58:11+00:00, stenn@psp-at1.ntp.org + [Bug 2890] Ignore ENOBUFS on routing netlink socket. Konstantin Khlebnikov. + + ChangeLog@1.1736.1.1 +1 -0 + [Bug 2890] Ignore ENOBUFS on routing netlink socket. Konstantin Khlebnikov. + + ntpd/ntp_io.c@1.405 +9 -4 + [Bug 2890] Ignore ENOBUFS on routing netlink socket. Konstantin Khlebnikov. + +ChangeSet@1.3550, 2015-07-29 22:50:29+02:00, jnperlin@hydra.(none) + Bug 2821: minor build issues: fixed refclock_gpsdjson.c + + ChangeLog@1.1737 +1 -0 + Bug 2821: minor build issues: fixed refclock_gpsdjson.c + + ntpd/refclock_gpsdjson.c@1.23 +9 -9 + Bug 2821: minor build issues: fixed refclock_gpsdjson.c + - 'isprint()' is called with u_char argument + - unified 'unsigned char' and 'u_char' to 'u_char' + +ChangeSet@1.3549, 2015-07-29 10:04:53+00:00, stenn@psp-at1.ntp.org + ChangeLog cleanup + + ChangeLog@1.1736 +5 -3 + ChangeLog cleanup + +ChangeSet@1.3548, 2015-07-29 12:01:10+02:00, viperus@ubuntu.(none) + ChangeLog: + updated ChangeLog + + ChangeLog@1.1735 +3 -1 + updated ChangeLog + +ChangeSet@1.3529.3.1, 2015-07-29 13:18:47+05:30, loki@dadasgift.(none) + ntp_util + + tests/ntpd/Makefile.am@1.6.2.1 +13 -10 + +ChangeSet@1.3545, 2015-07-28 09:37:25+00:00, stenn@psp-at1.ntp.org + update tests/libntp/run-socktoa.c + + tests/libntp/run-socktoa.c@1.8.1.1 +6 -6 + update tests/libntp/run-socktoa.c + +ChangeSet@1.3544, 2015-07-28 09:36:24+00:00, stenn@psp-at1.ntp.org + Typo fix for GCC warning suppression. Harlan Stenn. + + ChangeLog@1.1734 +1 -0 + Typo fix for GCC warning suppression. Harlan Stenn. + + ntpd/ntp_config.c@1.333 +5 -5 + Typo fix for GCC warning suppression. Harlan Stenn. + + ntpd/ntp_proto.c@1.364 +1 -1 + Typo fix for GCC warning suppression. Harlan Stenn. + +ChangeSet@1.3529.1.18, 2015-07-27 19:46:25+02:00, viperus@ubuntu.(none) + Many files: + update + + run-leapsec.c: + minor change + run-ntp_scanner.c, run-decodenetnum.c: + update + ntp_scanner.c: + Added more tests + lfptest.h: + minor move after merge with lokesh + Makefile.am: + Merge + + tests/libntp/lfptest.h@1.5.1.2 +0 -16 + minor move after merge with lokesh + + tests/libntp/run-decodenetnum.c@1.7 +1 -0 + update + + tests/libntp/run-lfptostr.c@1.6 +11 -11 + update + + + tests/libntp/run-netof.c@1.6 +0 -1 + update + + + tests/libntp/run-socktoa.c@1.9 +6 -6 + update + + + tests/ntpd/Makefile.am@1.6.1.4 +8 -3 + Merge + + tests/ntpd/ntp_scanner.c@1.2 +30 -2 + Added more tests + + tests/ntpd/run-leapsec.c@1.4 +9 -3 + minor change + + tests/ntpd/run-ntp_scanner.c@1.2 +7 -1 + update + + tests/ntpd/run-ntp_signd.c@1.3 +2 -2 + update + + + tests/ntpd/run-rc_cmdlength.c@1.2 +8 -3 + update + + +ChangeSet@1.3543, 2015-07-27 04:11:08+00:00, stenn@psp-at1.ntp.org + [Bug 2595] ntpdate man page quirks. Hal Murray, Harlan Stenn + + ChangeLog@1.1733 +1 -0 + [Bug 2595] ntpdate man page quirks. Hal Murray, Harlan Stenn + + ntpd/ntp.conf.def@1.19 +1 -1 + [Bug 2595] ntpdate man page quirks. Hal Murray, Harlan Stenn + + ntpd/ntpd-opts.def@1.13 +5 -1 + [Bug 2595] ntpdate man page quirks. Hal Murray, Harlan Stenn + +ChangeSet@1.3542, 2015-07-27 03:16:04+00:00, stenn@psp-at1.ntp.org + [Bug 2625] Deprecate flag1 in local refclock. Hal Murray, Harlan Stenn. + + ChangeLog@1.1732 +1 -0 + [Bug 2625] Deprecate flag1 in local refclock. Hal Murray, Harlan Stenn. + + ntpd/refclock_local.c@1.21 +2 -16 + [Bug 2625] Deprecate flag1 in local refclock. Hal Murray, Harlan Stenn. + +ChangeSet@1.3540, 2015-07-27 00:07:00+00:00, tflendrich@psp-at1.ntp.org + ChangeLog: + updated with info about progname and ntp_restrict.c + + ChangeLog@1.1730 +4 -0 + updated with info about progname and ntp_restrict.c + +ChangeSet@1.3529.2.1, 2015-07-26 22:04:07+00:00, stenn@psp-at1.ntp.org + [Bug 2817] Stop locking ntpd into memory by default under Linux. H.Stenn. + + ChangeLog@1.1725.1.8 +1 -0 + [Bug 2817] Stop locking ntpd into memory by default under Linux. H.Stenn. + + sntp/m4/ntp_rlimit.m4@1.2 +5 -1 + [Bug 2817] Stop locking ntpd into memory by default under Linux. H.Stenn. + +ChangeSet@1.3529.1.17, 2015-07-26 21:48:29+02:00, viperus@ubuntu.(none) + run-ntp_scanner.c, ntp_scanner.c: + new file + + tests/ntpd/ntp_scanner.c@1.1 +29 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/ntpd/ntp_scanner.c + + tests/ntpd/ntp_scanner.c@1.0 +0 -0 + + tests/ntpd/run-ntp_scanner.c@1.1 +55 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/ntpd/run-ntp_scanner.c + + tests/ntpd/run-ntp_scanner.c@1.0 +0 -0 + +ChangeSet@1.3529.1.16, 2015-07-26 21:34:45+02:00, viperus@ubuntu.(none) + + tests/ntpd/Makefile.am@1.6.1.3 +20 -1 + + tests/ntpd/ntp_signd.c@1.2 +3 -1 + + tests/ntpd/run-ntp_signd.c@1.2 +9 -3 + +ChangeSet@1.3529.1.14, 2015-07-26 07:23:22+00:00, stenn@psp-at1.ntp.org + update tests/sec-2853/run-sec-2853. + + tests/sec-2853/run-sec-2853.c@1.3.1.1 +4 -5 + update + +ChangeSet@1.3529.1.13, 2015-07-26 07:14:53+00:00, stenn@psp-at1.ntp.org + Add std_unity_tests to various Makefile.am files. Harlan Stenn. + + ChangeLog@1.1725.1.7 +1 -0 + Add std_unity_tests to various Makefile.am files. Harlan Stenn. + + sntp/tests/Makefile.am@1.62 +4 -0 + Add std_unity_tests to various Makefile.am files. Harlan Stenn. + + tests/libntp/Makefile.am@1.85.1.4 +4 -0 + Add std_unity_tests to various Makefile.am files. Harlan Stenn. + + tests/ntpd/Makefile.am@1.4.1.1 +4 -0 + Add std_unity_tests to various Makefile.am files. Harlan Stenn. + + tests/sandbox/Makefile.am@1.6 +4 -0 + Add std_unity_tests to various Makefile.am files. Harlan Stenn. + +ChangeSet@1.3529.1.12, 2015-07-26 06:43:54+00:00, stenn@psp-at1.ntp.org + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + NEWS@1.145 +10 -0 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + +ChangeSet@1.3529.1.11, 2015-07-26 06:37:30+00:00, stenn@psp-at1.ntp.org + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ChangeLog@1.1725.1.6 +1 -0 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + html/decode.html@1.26 +2 -2 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + html/stats.html@1.4 +24 -24 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + include/ntp_control.h@1.59 +1 -1 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + libntp/statestr.c@1.28 +1 -1 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/invoke-ntp.conf.texi@1.189 +2 -2 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp.conf.5man@1.223 +4 -4 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp.conf.5mdoc@1.223 +3 -3 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp.conf.def@1.18 +1 -1 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp.conf.html@1.178 +1522 -1191 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp.conf.man.in@1.223 +4 -4 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp.conf.mdoc.in@1.223 +3 -3 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp_loopfilter.c@1.185 +4 -4 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpd/ntp_proto.c@1.363 +1 -1 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpq/libntpq.h@1.10 +1 -1 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + + ntpq/ntpq-subs.c@1.111 +1 -1 + [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org + +ChangeSet@1.3537, 2015-07-25 18:08:16+02:00, tomek@tomek-n56vz.(none) + Changed "char * progname;" variable to be "char const * progname;", so now it is consistent + Many files: + changed a variable to be const + autogenerated + + adjtimed/adjtimed.c@1.5 +1 -1 + changed a variable to be const + + clockstuff/chutest.c@1.7 +1 -1 + changed a variable to be const + + clockstuff/propdelay.c@1.8 +1 -1 + changed a variable to be const + + libntp/msyslog.c@1.51 +3 -3 + changed a variable to be const + + libntp/ntp_lineedit.c@1.13 +1 -1 + changed a variable to be const + + ntpdate/ntpdate.c@1.94 +1 -1 + changed a variable to be const + + ntpdc/ntpdc.c@1.104 +1 -1 + changed a variable to be const + + ntpq/ntpq.c@1.160 +1 -1 + changed a variable to be const + + sntp/log.c@1.23 +1 -1 + changed a variable to be const + + sntp/log.h@1.12 +1 -1 + changed a variable to be const + + sntp/tests/run-crypto.c@1.6 +1 -1 + autogenerated + + sntp/tests/run-keyFile.c@1.9 +1 -1 + autogenerated + + sntp/tests/run-kodDatabase.c@1.7 +1 -1 + autogenerated + + sntp/tests/run-kodFile.c@1.7 +1 -1 + autogenerated + + sntp/tests/run-networking.c@1.3 +1 -1 + autogenerated + + sntp/tests/run-packetHandling.c@1.6 +1 -1 + autogenerated + + sntp/tests/run-packetProcessing.c@1.7 +1 -1 + autogenerated + + sntp/tests/run-utilities.c@1.6 +1 -1 + autogenerated + + tests/ntpd/run-ntp_restrict.c@1.4 +1 -1 + autogenerated + + tests/sandbox/run-modetoa.c@1.3 +7 -4 + autogenerated + + tests/sandbox/run-uglydate.c@1.3 +9 -4 + autogenerated + + tests/sandbox/run-ut-2803.c@1.2 +7 -4 + autogenerated + + util/ntp-keygen.c@1.106 +1 -1 + changed a variable to be const + + util/ntptime.c@1.27 +1 -1 + changed a variable to be const + +ChangeSet@1.3529.1.10, 2015-07-25 16:54:29+02:00, viperus@ubuntu.(none) + Many files: + added declarations + + lfpfunc.c: + adding declarations, reorganizing + Many files: + adding declarations + + update + + run-clocktime.c: + update + clocktime.c: + adding declarations + socktoa.c: + added declarations + + tests/libntp/clocktime.c@1.7 +1 -0 + adding declarations + + tests/libntp/lfpfunc.c@1.13 +28 -7 + adding declarations, reorganizing + + tests/libntp/netof.c@1.3.1.1 +8 -0 + adding declarations + + + tests/libntp/numtoa.c@1.6 +2 -0 + adding declarations + + + tests/libntp/numtohost.c@1.5 +2 -0 + adding declarations + + + tests/libntp/octtoint.c@1.3.1.1 +10 -0 + adding declarations + + + tests/libntp/prettydate.c@1.3 +3 -0 + adding declarations + + + tests/libntp/recvbuff.c@1.5 +4 -0 + adding declarations + + + tests/libntp/refidsmear.c@1.5 +6 -3 + adding declarations + + + tests/libntp/refnumtoa.c@1.5 +4 -0 + adding declarations + + + tests/libntp/run-clocktime.c@1.9 +1 -1 + update + + tests/libntp/run-lfpfunc.c@1.16 +9 -9 + update + + + tests/libntp/run-netof.c@1.5 +4 -4 + update + + + tests/libntp/run-numtoa.c@1.9 +2 -2 + update + + + tests/libntp/run-numtohost.c@1.9 +1 -1 + update + + + tests/libntp/run-octtoint.c@1.6 +7 -7 + update + + + tests/libntp/run-prettydate.c@1.4 +1 -1 + update + + + tests/libntp/run-recvbuff.c@1.4 +3 -3 + update + + + tests/libntp/run-refidsmear.c@1.5 +1 -1 + update + + + tests/libntp/run-refnumtoa.c@1.7 +2 -2 + update + + + tests/libntp/run-sfptostr.c@1.4 +7 -7 + update + + + tests/libntp/run-socktoa.c@1.8 +6 -6 + update + + + tests/libntp/run-ssl_init.c@1.8 +5 -5 + update + + + tests/libntp/run-statestr.c@1.9 +4 -4 + update + + + tests/libntp/run-strtolfp.c@1.4 +6 -6 + update + + + tests/libntp/run-timespecops.c@1.9 +28 -28 + update + + + tests/libntp/run-timevalops.c@1.11 +28 -28 + update + + + tests/libntp/run-tstotv.c@1.4 +3 -3 + update + + + tests/libntp/run-tvtots.c@1.5 +3 -3 + update + + + tests/libntp/run-vi64ops.c@1.7 +3 -3 + update + + + tests/libntp/run-ymd2yd.c@1.10 +4 -4 + update + + + tests/libntp/sfptostr.c@1.3 +10 -0 + update + + + tests/libntp/sockaddrtest.c@1.2 +1 -0 + update + + + tests/libntp/socktoa.c@1.3.1.1 +6 -0 + added declarations + + tests/libntp/ssl_init.c@1.8 +6 -0 + added declarations + + + tests/libntp/statestr.c@1.5 +4 -0 + added declarations + + + tests/libntp/strtolfp.c@1.2.1.1 +9 -0 + added declarations + + + tests/libntp/timespecops.c@1.8 +40 -1 + added declarations + + + tests/libntp/timevalops.c@1.11 +37 -1 + added declarations + + + tests/libntp/tstotv.c@1.3 +5 -0 + added declarations + + + tests/libntp/tvtots.c@1.5 +3 -0 + added declarations + + + tests/libntp/vi64ops.c@1.6 +6 -0 + added declarations + + + tests/libntp/ymd2yd.c@1.6 +5 -0 + added declarations + + +ChangeSet@1.3536, 2015-07-25 02:08:32+02:00, tomek@tomek-n56vz.(none) + run-ntp_restrict.c: + autogenerated, but modified manually... + Makefile.am: + removed something not longer in use + ntp_restrict.c: + added another test + run-ntp_restrict.c, run-ntp_prio_q.c, run-sec-2853.c, run-bug-2803.c: + autogenerated + + tests/bug-2803/run-bug-2803.c@1.8 +8 -4 + autogenerated + + tests/ntpd/Makefile.am@1.9 +0 -3 + removed something not longer in use + + tests/ntpd/ntp_restrict.c@1.2 +17 -4 + added another test + + tests/ntpd/run-ntp_prio_q.c@1.2 +9 -4 + autogenerated + + tests/ntpd/run-ntp_restrict.c@1.3 +1 -1 + autogenerated, but modified manually... + + tests/ntpd/run-ntp_restrict.c@1.2 +8 -4 + autogenerated + + tests/sec-2853/run-sec-2853.c@1.4 +5 -6 + autogenerated + +ChangeSet@1.3529.1.9, 2015-07-24 18:38:05+02:00, viperus@ubuntu.(none) + calendar.c: + added function declarations + minor comment fixes + + Many files: + added declarations + + updated + + run-buftvtots.c, run-calendar.c: + update + lfptest.c: + added #include + buftvtots.c: + added function declarations + caljulian.c: + added declarations + run-caljulian.c: + updated + + tests/libntp/buftvtots.c@1.4 +4 -0 + added function declarations + + tests/libntp/calendar.c@1.6 +42 -18 + added function declarations + minor comment fixes + + + tests/libntp/caljulian.c@1.9 +10 -0 + added declarations + + tests/libntp/caltontp.c@1.3 +5 -0 + added declarations + + + tests/libntp/calyearstart.c@1.4 +5 -0 + added declarations + + + tests/libntp/clocktime.c@1.6 +11 -0 + added declarations + + + tests/libntp/decodenetnum.c@1.3.1.1 +7 -0 + added declarations + + + tests/libntp/hextoint.c@1.4 +6 -0 + added declarations + + + tests/libntp/hextolfp.c@1.5.1.1 +7 -0 + added declarations + + + tests/libntp/humandate.c@1.5 +4 -0 + added declarations + + + tests/libntp/lfpfunc.c@1.12 +13 -0 + added declarations + + + tests/libntp/lfptest.c@1.2 +1 -0 + added #include + + tests/libntp/lfptostr.c@1.3.1.1 +15 -0 + added declarations + + + tests/libntp/modetoa.c@1.7 +3 -0 + added declarations + + + tests/libntp/msyslog.c@1.6 +10 -0 + added declarations + + + tests/libntp/run-buftvtots.c@1.5 +10 -10 + update + + tests/libntp/run-calendar.c@1.8 +11 -11 + update + + tests/libntp/run-caljulian.c@1.12 +4 -4 + updated + + tests/libntp/run-caltontp.c@1.4 +4 -4 + updated + + + tests/libntp/run-calyearstart.c@1.6 +3 -3 + updated + + + tests/libntp/run-clocktime.c@1.8 +8 -8 + updated + + + tests/libntp/run-decodenetnum.c@1.6 +6 -6 + updated + + + tests/libntp/run-hextoint.c@1.8 +5 -5 + updated + + + tests/libntp/run-hextolfp.c@1.7 +6 -6 + updated + + + tests/libntp/run-humandate.c@1.5 +2 -2 + updated + + + tests/libntp/run-lfpfunc.c@1.15 +9 -9 + updated + + + tests/libntp/run-lfptostr.c@1.5 +10 -10 + updated + + + tests/libntp/run-modetoa.c@1.10 +2 -2 + updated + + + tests/libntp/run-msyslog.c@1.7 +8 -8 + updated + + +ChangeSet@1.3523.2.7, 2015-07-24 12:01:24+05:30, loki@dadasgift.(none) + ntp signd testing + + tests/ntpd/ntp_signd.c@1.1 +24 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/ntpd/ntp_signd.c + + tests/ntpd/ntp_signd.c@1.0 +0 -0 + +ChangeSet@1.3523.2.6, 2015-07-24 11:55:00+05:30, loki@dadasgift.(none) + ntp_signd test changes + + tests/ntpd/Makefile.am@1.6.1.1 +21 -0 + + tests/ntpd/run-ntp_signd.c@1.1 +52 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/ntpd/run-ntp_signd.c + + tests/ntpd/run-ntp_signd.c@1.0 +0 -0 + +ChangeSet@1.3535, 2015-07-23 19:19:08+02:00, tomek@tomek-n56vz.(none) + Wrote tests for ntpd/ntp_restrict.c + ntp_restrict.c, run-ntp_restrict.c: + new file + Makefile.am: + added ntp_restrict.c test + ntp_restrict.c: + added assertions (I prefer them to a segfault) + + ntpd/ntp_restrict.c@1.39 +6 -0 + added assertions (I prefer them to a segfault) + + tests/ntpd/Makefile.am@1.8 +25 -0 + added ntp_restrict.c test + + tests/ntpd/ntp_restrict.c@1.1 +185 -0 + BitKeeper file /home/tomek/ntp/ntpd_tests/ntp-stable-unity/tests/ntpd/ntp_restrict.c + + tests/ntpd/ntp_restrict.c@1.0 +0 -0 + + tests/ntpd/run-ntp_restrict.c@1.1 +64 -0 + BitKeeper file /home/tomek/ntp/ntpd_tests/ntp-stable-unity/tests/ntpd/run-ntp_restrict.c + + tests/ntpd/run-ntp_restrict.c@1.0 +0 -0 + +ChangeSet@1.3529.1.8, 2015-07-23 18:37:16+02:00, viperus@ubuntu.(none) + reduced number of warnings in sntp/tests/ + + sntp/tests/crypto.c@1.9 +6 -0 + added declarations for tests + + sntp/tests/fileHandlingTest.c@1.2 +1 -1 + commented out unnecessary array + + sntp/tests/keyFile.c@1.7 +4 -0 + added declarations for tests + + + sntp/tests/kodDatabase.c@1.7 +6 -0 + added declarations for tests + + + sntp/tests/kodFile.c@1.8 +8 -0 + added declarations for tests + + + sntp/tests/nameresolution.c@1.2 +3 -0 + added declarations for tests + + + sntp/tests/packetHandling.c@1.5 +13 -0 + added declarations for tests + + + sntp/tests/packetProcessing.c@1.7 +24 -0 + added declarations for tests + + + sntp/tests/run-crypto.c@1.5 +5 -5 + added declarations for tests + + + sntp/tests/run-keyFile.c@1.8 +4 -4 + updated + + sntp/tests/run-kodDatabase.c@1.6 +5 -5 + updated + + sntp/tests/run-kodFile.c@1.6 +6 -6 + updated + + sntp/tests/run-packetHandling.c@1.5 +10 -10 + updated + + sntp/tests/run-packetProcessing.c@1.6 +18 -18 + updated + + sntp/tests/run-utilities.c@1.5 +7 -7 + updated + + sntp/tests/utilities.c@1.4 +12 -0 + added declarations for tests + + +ChangeSet@1.3529.1.7, 2015-07-22 20:09:39+02:00, viperus@ubuntu.(none) + Updated unity ruby testRunner generator with mark's latest fixes. Modified tests/libntp/Makefile.am and sntp/tests/Makefile.am accordingly. Also, split some .h files into .h and .c because they contained declarations and definitions which caused error in the newly generated test runners. Started fixing some warnings. We can add both declarations and defitions in a single test.c file without any issues now. Autogenerated tests will be run in order of the declarations in the test file. + + sntp/tests/Makefile.am@1.61 +4 -0 + New ruby generator script required some changes. Removed some definitions form header files and created their own .c files. + + sntp/tests/crypto.c@1.8 +2 -0 + started adding declarations at the top of the file + + sntp/tests/fileHandlingTest.c@1.1 +74 -0 + new file. Contains definitions from fileHandlingTest.h.in + + sntp/tests/fileHandlingTest.c@1.0 +0 -0 + + sntp/tests/fileHandlingTest.h.in@1.14 +7 -46 + changes stuff a bit, to work with the updated ruby generator + + sntp/tests/keyFile.c@1.6 +4 -0 + added declarations to avoid warnings + + sntp/tests/run-crypto.c@1.4 +12 -9 + updated autogenerated code + + sntp/tests/run-keyFile.c@1.7 +12 -8 + updated autogenerated code + + + sntp/tests/run-kodDatabase.c@1.5 +9 -3 + updated autogenerated code + + + sntp/tests/run-kodFile.c@1.5 +7 -3 + updated autogenerated code + + + sntp/tests/run-networking.c@1.2 +5 -2 + updated autogenerated code + + + sntp/tests/run-packetHandling.c@1.4 +11 -3 + updated autogenerated code + + + sntp/tests/run-packetProcessing.c@1.5 +6 -3 + updated autogenerated code + + + sntp/tests/run-utilities.c@1.4 +8 -3 + updated autogenerated code + + + sntp/tests/sntptest.c@1.1 +33 -0 + definitions placed from .h to .c + + sntp/tests/sntptest.c@1.0 +0 -0 + + sntp/tests/sntptest.h@1.6 +0 -29 + added sntptest.c and put definitions in it. + + sntp/unity/auto/generate_test_runner.rb@1.9 +3 -3 + some changes were needed after mark's update to work better with NTP + + sntp/unity/auto/generate_test_runner.rb@1.8 +209 -110 + updated the ruby script with new stuff from Mark + + sntp/unity/auto/parseOutput.rb@1.1 +191 -0 + mark's new file from the update + + sntp/unity/auto/parseOutput.rb@1.0 +0 -0 + + sntp/unity/auto/type_sanitizer.rb@1.1 +8 -0 + mark's new file from the update + + + sntp/unity/auto/type_sanitizer.rb@1.0 +0 -0 + + sntp/unity/auto/unity_test_summary.py@1.1 +135 -0 + mark's new file from the update + + + sntp/unity/auto/unity_test_summary.py@1.0 +0 -0 + + sntp/unity/auto/unity_test_summary.rb@1.3 +48 -25 + added Marks new changes + + tests/libntp/Makefile.am@1.85.1.3 +7 -0 + New ruby generator script required some changes. Removed some definitions form header files and created their own .c files. + + + tests/libntp/a_md5encrypt.c@1.11 +8 -0 + added declarations + + tests/libntp/atoint.c@1.4 +9 -0 + added declarations + + + tests/libntp/atouint.c@1.5 +8 -0 + added declarations + + + tests/libntp/authkeys.c@1.10 +17 -6 + added declarations + + + tests/libntp/lfptest.c@1.1 +10 -0 + new file, contains definitions from lfptest.h + + tests/libntp/lfptest.c@1.0 +0 -0 + + tests/libntp/lfptest.h@1.4.1.3 +2 -8 + split to .h and .c which now contains definitions + + tests/libntp/run-a_md5encrypt.c@1.13 +9 -7 + autogenerated file update + + tests/libntp/run-atoint.c@1.7 +10 -7 + autogenerated file update + + + tests/libntp/run-atouint.c@1.8 +10 -7 + autogenerated file update + + + tests/libntp/run-authkeys.c@1.10 +12 -9 + autogenerated file update + + + tests/libntp/run-buftvtots.c@1.4 +8 -3 + autogenerated file update + + + tests/libntp/run-calendar.c@1.7 +6 -3 + autogenerated file update + + + tests/libntp/run-caljulian.c@1.11 +7 -3 + autogenerated file update + + + tests/libntp/run-caltontp.c@1.3 +4 -3 + autogenerated file update + + + tests/libntp/run-calyearstart.c@1.5 +6 -3 + autogenerated file update + + + tests/libntp/run-clocktime.c@1.7 +6 -3 + autogenerated file update + + + tests/libntp/run-decodenetnum.c@1.5 +5 -3 + autogenerated file update + + + tests/libntp/run-hextoint.c@1.7 +6 -2 + autogenerated file update + + + tests/libntp/run-hextolfp.c@1.6 +6 -3 + autogenerated file update + + + tests/libntp/run-humandate.c@1.4 +5 -3 + autogenerated file update + + + tests/libntp/run-lfpfunc.c@1.14 +7 -3 + autogenerated file update + + + tests/libntp/run-lfptostr.c@1.4 +5 -3 + autogenerated file update + + + tests/libntp/run-modetoa.c@1.9 +4 -3 + autogenerated file update + + + tests/libntp/run-msyslog.c@1.6 +4 -3 + autogenerated file update + + + tests/libntp/run-netof.c@1.4 +6 -3 + autogenerated file update + + + tests/libntp/run-numtoa.c@1.8 +5 -3 + autogenerated file update + + + tests/libntp/run-numtohost.c@1.8 +5 -3 + autogenerated file update + + + tests/libntp/run-octtoint.c@1.5 +4 -2 + autogenerated file update + + + tests/libntp/run-prettydate.c@1.3 +6 -2 + autogenerated file update + + + tests/libntp/run-recvbuff.c@1.3 +4 -2 + autogenerated file update + + + tests/libntp/run-refidsmear.c@1.4 +7 -3 + autogenerated file update + + + tests/libntp/run-refnumtoa.c@1.6 +5 -3 + autogenerated file update + + + tests/libntp/run-sfptostr.c@1.3 +4 -3 + autogenerated file update + + + tests/libntp/run-socktoa.c@1.7 +6 -2 + autogenerated file update + + + tests/libntp/run-ssl_init.c@1.7 +4 -3 + autogenerated file update + + + tests/libntp/run-statestr.c@1.8 +6 -3 + autogenerated file update + + + tests/libntp/run-strtolfp.c@1.3 +6 -2 + autogenerated file update + + + tests/libntp/run-timespecops.c@1.8 +8 -3 + autogenerated file update + + + tests/libntp/run-timevalops.c@1.10 +7 -3 + autogenerated file update + + + tests/libntp/run-tstotv.c@1.3 +5 -2 + autogenerated file update + + + tests/libntp/run-tvtots.c@1.4 +6 -3 + autogenerated file update + + + tests/libntp/run-uglydate.c@1.9 +6 -4 + autogenerated file update + + + tests/libntp/run-vi64ops.c@1.6 +5 -3 + autogenerated file update + + + tests/libntp/run-ymd2yd.c@1.9 +4 -3 + autogenerated file update + + + tests/libntp/sockaddrtest.c@1.1 +50 -0 + New file created by splitting sockaddrtest.h. + + tests/libntp/sockaddrtest.c@1.0 +0 -0 + + tests/libntp/sockaddrtest.h@1.6 +4 -45 + removed definitions and placed them in sockaddrtest.c + + tests/libntp/uglydate.c@1.7 +1 -0 + added some declarations to test the new generator. Unfinished + +ChangeSet@1.3523.3.18, 2015-07-21 06:47:23+00:00, stenn@psp-deb1.ntp.org + [Bug 2883] ntpd crashes on exit with empty driftfile. Miroslav Lichvar. + + ChangeLog@1.1708.1.19 +1 -0 + [Bug 2883] ntpd crashes on exit with empty driftfile. Miroslav Lichvar. + + ntpd/ntp_parser.c@1.98 +1141 -1381 + [Bug 2883] ntpd crashes on exit with empty driftfile. Miroslav Lichvar. + + ntpd/ntp_parser.h@1.63 +216 -230 + [Bug 2883] ntpd crashes on exit with empty driftfile. Miroslav Lichvar. + + ntpd/ntp_parser.y@1.88 +1 -1 + [Bug 2883] ntpd crashes on exit with empty driftfile. Miroslav Lichvar. + +ChangeSet@1.3523.3.17, 2015-07-20 07:32:09+00:00, stenn@psp-at1.ntp.org + ntpd/ntp_peer.c:newpeer(): added a DEBUG_REQUIRE(srcadr). Harlan Stenn. + + ChangeLog@1.1708.1.18 +1 -0 + ntpd/ntp_peer.c:newpeer(): added a DEBUG_REQUIRE(srcadr). Harlan Stenn. + + ntpd/ntp_peer.c@1.158 +2 -0 + ntpd/ntp_peer.c:newpeer(): added a DEBUG_REQUIRE(srcadr). Harlan Stenn. + +ChangeSet@1.3523.3.16, 2015-07-20 07:20:04+00:00, stenn@psp-at1.ntp.org + [Bug 2849] Systems with more than one default route may never synchronize. Brian Utterback. + + ChangeLog@1.1708.1.17 +3 -0 + [Bug 2849] Systems with more than one default route may never synchronize. Brian Utterback. + + ntpd/ntp_peer.c@1.157 +7 -3 + [Bug 2849] Systems with more than one default route may never synchronize. Brian Utterback. + +ChangeSet@1.3523.3.15, 2015-07-20 06:38:37+00:00, stenn@psp-at1.ntp.org + util/ntptime.c: initialization nit. Harlan Stenn. + + ChangeLog@1.1708.1.16 +1 -0 + util/ntptime.c: initialization nit. Harlan Stenn. + + util/ntptime.c@1.26 +1 -1 + util/ntptime.c: initialization nit. Harlan Stenn. + +ChangeSet@1.3523.3.14, 2015-07-19 21:49:06-04:00, stenn@deacon.udel.edu + Typo + + ChangeLog@1.1708.1.15 +1 -1 + Typo + +ChangeSet@1.3523.3.13, 2015-07-19 21:46:59-04:00, stenn@deacon.udel.edu + libntp/icom.c: Typos fix. Harlan Stenn. + + ChangeLog@1.1708.1.14 +1 -0 + libntp/icom.c: Typos fix. Harlan Stenn. + + libntp/icom.c@1.20 +1 -1 + libntp/icom.c: Typos fix. Harlan Stenn. + +ChangeSet@1.3523.3.12, 2015-07-19 05:37:40+00:00, stenn@psp-at1.ntp.org + Code cleanup. Harlan Stenn. + + ChangeLog@1.1708.1.13 +1 -0 + Code cleanup. Harlan Stenn. + + include/Makefile.am@1.52 +1 -0 + Code cleanup. Harlan Stenn. + + include/rc_cmdlength.h@1.1 +2 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable/include/rc_cmdlength.h + + include/rc_cmdlength.h@1.0 +0 -0 + + libntp/audio.c@1.36 +8 -5 + Code cleanup. Harlan Stenn. + + libntp/icom.c@1.19 +23 -7 + Code cleanup. Harlan Stenn. + + libntp/ntp_worker.c@1.5 +1 -1 + Code cleanup. Harlan Stenn. + + ntpd/ntp_config.c@1.332 +10 -0 + Code cleanup. Harlan Stenn. + + ntpd/ntp_control.c@1.203 +1 -2 + Code cleanup. Harlan Stenn. + + ntpd/ntp_crypto.c@1.181 +1 -1 + Code cleanup. Harlan Stenn. + + ntpd/ntp_monitor.c@1.44 +4 -0 + Code cleanup. Harlan Stenn. + + ntpd/ntp_peer.c@1.156 +1 -0 + Code cleanup. Harlan Stenn. + + ntpd/ntp_proto.c@1.362 +3 -1 + Code cleanup. Harlan Stenn. + + ntpd/ntp_restrict.c@1.38 +4 -0 + Code cleanup. Harlan Stenn. + + ntpd/rc_cmdlength.c@1.2 +1 -0 + Code cleanup. Harlan Stenn. + + ntpd/refclock_arc.c@1.33 +1 -1 + Code cleanup. Harlan Stenn. + + ntpd/refclock_chu.c@1.57 +1 -1 + Code cleanup. Harlan Stenn. + + ntpd/refclock_nmea.c@1.78 +4 -3 + Code cleanup. Harlan Stenn. + + ntpd/refclock_parse.c@1.81 +3 -0 + Code cleanup. Harlan Stenn. + + ntpd/refclock_wwv.c@1.80 +4 -2 + Code cleanup. Harlan Stenn. + + ntpq/ntpq.c@1.159 +0 -1 + Code cleanup. Harlan Stenn. + + sntp/networking.c@1.66 +1 -1 + Code cleanup. Harlan Stenn. + + tests/sec-2853/run-sec-2853.c@1.3 +2 -2 + Code cleanup. Harlan Stenn. + + tests/sec-2853/sec-2853.c@1.5 +2 -2 + Code cleanup. Harlan Stenn. + + util/ntp-keygen.c@1.105 +2 -2 + Code cleanup. Harlan Stenn. + +ChangeSet@1.3523.3.11, 2015-07-16 07:37:32+00:00, stenn@psp-at1.ntp.org + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ChangeLog@1.1708.1.12 +1 -0 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + include/ntp_assert.h@1.9 +0 -4 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + include/ntp_lists.h@1.15 +3 -3 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/atolfp.c@1.6 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/caljulian.c@1.16 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/caltontp.c@1.7 +8 -8 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/decodenetnum.c@1.17 +3 -3 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/msyslog.c@1.50 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/ntp_intres.c@1.99 +12 -12 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/ntp_rfc2553.c@1.48 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/prettydate.c@1.20 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/recvbuff.c@1.40 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/socket.c@1.10 +2 -2 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + libntp/socktohost.c@1.15 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_config.c@1.331 +7 -8 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_control.c@1.202 +18 -18 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_crypto.c@1.180 +14 -14 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_io.c@1.404 +15 -15 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_monitor.c@1.43 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_peer.c@1.155 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_refclock.c@1.120 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpd/ntp_restrict.c@1.37 +9 -9 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpdc/ntpdc.c@1.103 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ntpq/ntpq-subs.c@1.110 +7 -7 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ports/winnt/libntp/termios.c@1.31 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ports/winnt/ntpd/nt_clockstuff.c@1.66 +1 -1 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.71 +7 -8 + Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. + +ChangeSet@1.3523.3.10, 2015-07-13 04:28:29+00:00, stenn@psp-at1.ntp.org + [Bug 2823] ntpsweep with recursive peers option doesn't work. H.Stenn. + + ChangeLog@1.1708.1.11 +1 -0 + [Bug 2823] ntpsweep with recursive peers option doesn't work. H.Stenn. + + scripts/ntpsweep/ntpsweep.in@1.9 +2 -1 + [Bug 2823] ntpsweep with recursive peers option doesn't work. H.Stenn. + +ChangeSet@1.3523.3.9, 2015-07-13 04:18:36+00:00, stenn@psp-at1.ntp.org + scripts/lib/NTP/Util.pm: stratum output is version-dependent. Harlan Stenn. + + ChangeLog@1.1708.1.10 +1 -0 + scripts/lib/NTP/Util.pm: stratum output is version-dependent. Harlan Stenn. + + scripts/lib/NTP/Util.pm@1.5 +8 -1 + scripts/lib/NTP/Util.pm: stratum output is version-dependent. Harlan Stenn. + +ChangeSet@1.3531, 2015-07-13 04:21:50+02:00, tomek@tomek-n56vz.(none) + wrote tests for ntpd/ntp_prio_q.c + + Makefile.am: + added ntp_prio_q.c + ntp_prio_q.c, run-ntp_prio_q.c: + new file + ChangeLog: + added info about the test of ntpd/ntp_prio_q.c + + ChangeLog@1.1726 +1 -0 + added info about the test of ntpd/ntp_prio_q.c + + tests/ntpd/Makefile.am@1.7 +28 -0 + added ntp_prio_q.c + + tests/ntpd/ntp_prio_q.c@1.1 +261 -0 + BitKeeper file /home/tomek/ntp/ntpd_tests/ntp-stable-unity/tests/ntpd/ntp_prio_q.c + + tests/ntpd/ntp_prio_q.c@1.0 +0 -0 + + tests/ntpd/run-ntp_prio_q.c@1.1 +64 -0 + BitKeeper file /home/tomek/ntp/ntpd_tests/ntp-stable-unity/tests/ntpd/run-ntp_prio_q.c + + tests/ntpd/run-ntp_prio_q.c@1.0 +0 -0 + +ChangeSet@1.3523.2.5, 2015-07-12 22:59:46+05:30, loki@dadasgift.(none) + rc_cmdlength test + + tests/ntpd/rc_cmdlength.c@1.2 +20 -4 + + tests/ntpd/run-rc_cmdlength.c@1.1 +52 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/ntpd/run-rc_cmdlength.c + + tests/ntpd/run-rc_cmdlength.c@1.0 +0 -0 + +ChangeSet@1.3523.3.8, 2015-07-11 19:20:33-04:00, stenn@deacon.udel.edu + br-flock: --enable-local-libevent. Harlan Stenn. + + ChangeLog@1.1708.1.9 +1 -0 + br-flock: --enable-local-libevent. Harlan Stenn. + + br-flock@1.17 +1 -1 + br-flock: --enable-local-libevent. Harlan Stenn. + +ChangeSet@1.3523.3.7, 2015-07-11 18:46:20-04:00, stenn@deacon.udel.edu + [Bug 2875] libevent is improperly bundled in the tarball + + Makefile.am@1.133 +1 -1 + [Bug 2875] libevent is improperly bundled in the tarball + +ChangeSet@1.3523.4.1, 2015-07-11 20:28:26+00:00, stenn@psp-at1.ntp.org + [Bug 2875] sntp/Makefile.am: Get rid of DIST_SUBDIRS. libevent must be configured for the distribution targets. Harlan Stenn. + + ChangeLog@1.1708.2.1 +2 -0 + [Bug 2875] sntp/Makefile.am: Get rid of DIST_SUBDIRS. libevent must be configured for the distribution targets. Harlan Stenn. + + sntp/Makefile.am@1.86 +13 -24 + [Bug 2875] sntp/Makefile.am: Get rid of DIST_SUBDIRS. libevent must be configured for the distribution targets. Harlan Stenn. + +ChangeSet@1.3523.2.4, 2015-07-11 00:19:36+05:30, loki@dadasgift.(none) + rc_cmdlength testing + + tests/ntpd/Makefile.am@1.6 +20 -0 + + tests/ntpd/rc_cmdlength.c@1.1 +22 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/ntpd/rc_cmdlength.c + + tests/ntpd/rc_cmdlength.c@1.0 +0 -0 + +ChangeSet@1.3523.3.5, 2015-07-09 09:03:46+00:00, stenn@psp-at1.ntp.org + tests/libntp/test_caltontp needs -lpthread. Harlan Stenn. + + ChangeLog@1.1708.1.7 +1 -0 + tests/libntp/test_caltontp needs -lpthread. Harlan Stenn. + + tests/libntp/Makefile.am@1.85.1.2 +5 -0 + tests/libntp/test_caltontp needs -lpthread. Harlan Stenn. + +ChangeSet@1.3523.3.4, 2015-07-09 03:42:45-04:00, stenn@deacon.udel.edu + Don't build sntp/libevent/sample/. Harlan Stenn. + + ChangeLog@1.1708.1.6 +1 -0 + Don't build sntp/libevent/sample/. Harlan Stenn. + + sntp/libevent/Makefile.am@1.14 +1 -1 + Don't build sntp/libevent/sample/. Harlan Stenn. + +ChangeSet@1.3523.3.3, 2015-07-09 06:06:50+00:00, stenn@psp-at1.ntp.org + Phase 1 deprecation of google test in tests/libntp/. Harlan Stenn. + + ChangeLog@1.1708.1.5 +1 -0 + Phase 1 deprecation of google test in tests/libntp/. Harlan Stenn. + + tests/libntp/Makefile.am@1.85.1.1 +113 -408 + Phase 1 deprecation of google test in tests/libntp/. Harlan Stenn. + +ChangeSet@1.3527, 2015-07-09 04:25:01+02:00, tomek@tomek-n56vz.(none) + lfptest.h: + now it uses NTP's conventions + ChangeLog: + add info about lfptest.h + test-libntp.c: + fixed formatting + sockaddrtest.h: + formatting fix + kodDatabase.c: + formatting, adding const, adding a missing library + ChangeLog: + added info about timespecops.c + kodFile.c: + formatting, changes to usage of unity macros to get better print messages, cleanup + crypto.c, lfptest.h: + cleanup + ChangeLog: + add info about test-libntp.c + timespecops.c: + further formatting changes + ChangeLog: + added info about timevalops.c + fileHandlingTest.h.in: + fixed buffer overflow problem and fixed one function that previously did nothing + timevalops.c: + fixed the order of includes, deleted unnecessary + packetProcessing.c: + formatting, sprintf->snprintf + packetHandling.c: + formatting, using better unity functions, using proper unity functions, deleting unused variable + keyFile.c: + formatting, using proper unity's macros + ChangeLog: + fileHandlingTest.h info + updating with info about sockaddrtest.h + timespecops.c: + forgot to delete one comment + ChangeLog: + added info about my code review changes in sntp/tests/ + kodDatabase.c: + missed something in formatting + sntptest.h: + formatting + Many files: + autogenerated + kodDatabase.c: + added a header. now it's windows compliant too! + fileHandlingTest.h.in: + formatting, deleted unnecessary prints + timespecops.c: + fixed formatting, fixed the order of includes, + removed unnecessary comments, cleanup + utilities.c: + the order of includes, formatting, removing unnecessary comments, using proper unity assertions + + ChangeLog@1.1723 +2 -1 + fileHandlingTest.h info + + ChangeLog@1.1722 +17 -0 + added info about my code review changes in sntp/tests/ + + ChangeLog@1.1721 +1 -0 + add info about test-libntp.c + + ChangeLog@1.1720 +2 -0 + updating with info about sockaddrtest.h + + ChangeLog@1.1719 +1 -0 + add info about lfptest.h + + ChangeLog@1.1718 +2 -0 + added info about timevalops.c + + ChangeLog@1.1717 +3 -1 + added info about timespecops.c + + sntp/tests/crypto.c@1.7 +14 -8 + cleanup + + sntp/tests/fileHandlingTest.h.in@1.13 +6 -6 + fixed buffer overflow problem and fixed one function that previously did nothing + + sntp/tests/fileHandlingTest.h.in@1.12 +13 -39 + formatting, deleted unnecessary prints + + sntp/tests/keyFile.c@1.5 +33 -24 + formatting, using proper unity's macros + + sntp/tests/kodDatabase.c@1.6 +1 -1 + added a header. now it's windows compliant too! + + sntp/tests/kodDatabase.c@1.5 +1 -2 + missed something in formatting + + sntp/tests/kodDatabase.c@1.4 +39 -31 + formatting, adding const, adding a missing library + + sntp/tests/kodFile.c@1.7 +34 -32 + formatting, changes to usage of unity macros to get better print messages, cleanup + + sntp/tests/packetHandling.c@1.4 +46 -31 + formatting, using better unity functions, using proper unity functions, deleting unused variable + + sntp/tests/packetProcessing.c@1.6 +67 -25 + formatting, sprintf->snprintf + + sntp/tests/run-crypto.c@1.3 +6 -6 + autogenerated + + sntp/tests/run-keyFile.c@1.6 +5 -5 + autogenerated + + sntp/tests/run-kodDatabase.c@1.4 +5 -5 + autogenerated + + sntp/tests/run-kodDatabase.c@1.3 +4 -4 + autogenerated + + sntp/tests/run-kodFile.c@1.4 +5 -5 + autogenerated + + sntp/tests/run-packetHandling.c@1.3 +10 -10 + autogenerated + + sntp/tests/run-packetProcessing.c@1.4 +18 -18 + autogenerated + + sntp/tests/run-utilities.c@1.3 +7 -7 + autogenerated + + sntp/tests/sntptest.h@1.5 +9 -3 + formatting + + sntp/tests/utilities.c@1.3 +38 -20 + the order of includes, formatting, removing unnecessary comments, using proper unity assertions + + tests/libntp/lfptest.h@1.4.1.2 +2 -3 + now it uses NTP's conventions + + tests/libntp/lfptest.h@1.4.1.1 +7 -16 + cleanup + + tests/libntp/run-timespecops.c@1.5.1.3 +28 -28 + autogenerated + + tests/libntp/run-timespecops.c@1.5.1.2 +28 -28 + autogenerated + + tests/libntp/run-timespecops.c@1.5.1.1 +28 -28 + autogenerated + + tests/libntp/run-timevalops.c@1.7.1.1 +28 -28 + autogenerated + + tests/libntp/sockaddrtest.h@1.5 +6 -5 + formatting fix + + tests/libntp/test-libntp.c@1.10 +6 -11 + fixed formatting + + tests/libntp/timespecops.c@1.5.1.3 +7 -6 + further formatting changes + + tests/libntp/timespecops.c@1.5.1.2 +0 -1 + forgot to delete one comment + + tests/libntp/timespecops.c@1.5.1.1 +129 -85 + fixed formatting, fixed the order of includes, + removed unnecessary comments, cleanup + + tests/libntp/timevalops.c@1.8.1.1 +137 -87 + fixed the order of includes, deleted unnecessary + +ChangeSet@1.3523.3.2, 2015-07-07 01:27:49+00:00, stenn@psp-at1.ntp.org + sntp/unity/unity.c: Clean up a printf(). Harlan Stenn + + ChangeLog@1.1708.1.4 +1 -0 + sntp/unity/unity.c: Clean up a printf(). Harlan Stenn + + sntp/unity/unity.c@1.3 +1 -3 + sntp/unity/unity.c: Clean up a printf(). Harlan Stenn + +ChangeSet@1.3523.3.1, 2015-07-07 01:21:36+00:00, stenn@psp-at1.ntp.org + [Bug 2873] libevent should not include .deps/ in the tarball. H.Stenn + + ChangeLog@1.1708.1.3 +1 -0 + [Bug 2873] libevent should not include .deps/ in the tarball. H.Stenn + + sntp/Makefile.am@1.85 +1 -1 + [Bug 2873] libevent should not include .deps/ in the tarball. H.Stenn + +ChangeSet@1.3523.2.2, 2015-07-06 20:30:39+05:30, loki@dadasgift.(none) + code review changes + + tests/libntp/lfptest.h@1.5 +7 -6 + + tests/libntp/strtolfp.c@1.3 +20 -19 + +ChangeSet@1.3514.1.2, 2015-07-06 19:55:50+05:30, loki@dadasgift.(none) + Code review changes + + tests/libntp/decodenetnum.c@1.2.1.1 +13 -9 + + tests/libntp/hextolfp.c@1.4.1.1 +0 -1 + + tests/libntp/lfptostr.c@1.2.1.1 +23 -12 + + tests/libntp/netof.c@1.4 +9 -6 + + tests/libntp/octtoint.c@1.4 +14 -7 + + tests/libntp/socktoa.c@1.4 +16 -13 + +ChangeSet@1.3523.1.3, 2015-07-06 08:37:13+00:00, stenn@psp-at1.ntp.org + [Bug 2874] Don't distribute generated sntp/tests/fileHandlingTest.h. H.Stenn + + ChangeLog@1.1708.1.2 +1 -0 + [Bug 2874] Don't distribute generated sntp/tests/fileHandlingTest.h. H.Stenn + + sntp/tests/Makefile.am@1.60 +0 -1 + [Bug 2874] Don't distribute generated sntp/tests/fileHandlingTest.h. H.Stenn + +ChangeSet@1.3523.1.2, 2015-07-06 08:31:19+00:00, stenn@psp-at1.ntp.org + update tests/libntp/run-lfpfunc.c + + tests/libntp/run-lfpfunc.c@1.13 +9 -9 + update + +ChangeSet@1.3523.1.1, 2015-07-06 05:48:25+00:00, stenn@psp-at1.ntp.org + sntp/unity/Makefile.am: fix some broken paths. Harlan Stenn. + + ChangeLog@1.1708.1.1 +1 -0 + sntp/unity/Makefile.am: fix some broken paths. Harlan Stenn. + + sntp/tests/Makefile.am@1.59 +4 -4 + sntp/unity/Makefile.am: fix some broken paths. Harlan Stenn. + +ChangeSet@1.3524, 2015-07-05 23:58:57+02:00, tomek@tomek-n56vz.(none) + vi64ops.c: + deleted a comment + ymd2yd.c: + fixed formatting, deleted empty setUp() and tearDown() + ssl_init.c: + fixed formatting + ChangeLog: + updated the changes to vi64ops.c + vi64ops.c: + fixed formatting (trailing spaces, the order of includes, return type of a function in a new line) + ChangeLog: + info about tvtots.c + ymd2yd.c: + removed an include + ChangeLog: + info about ymd2yd.c + uglydate.c: + removed an unnecessary include + ChangeLog: + info about uglydate.c + statestr.c: + deleted unnecessary empty functions, fixed formatting, removed an unnecessary include + ChangeLog: + info about vi64ops.c + tvtots.c: + fixed a bug, fixed formatting + Many files: + autogenerated + + ChangeLog@1.1714 +2 -3 + info about ymd2yd.c + + ChangeLog@1.1713 +2 -0 + info about ymd2yd.c + + ChangeLog@1.1712 +2 -1 + updated the changes to vi64ops.c + + ChangeLog@1.1711 +1 -0 + info about vi64ops.c + + ChangeLog@1.1710 +1 -0 + info about uglydate.c + + ChangeLog@1.1709 +4 -0 + info about tvtots.c + + tests/libntp/run-ssl_init.c@1.6 +5 -5 + autogenerated + + tests/libntp/run-statestr.c@1.7 +5 -4 + autogenerated + + tests/libntp/run-tvtots.c@1.3 +4 -3 + autogenerated + + tests/libntp/run-uglydate.c@1.8 +2 -1 + autogenerated + + tests/libntp/run-vi64ops.c@1.5 +3 -3 + autogenerated + + tests/libntp/run-ymd2yd.c@1.8 +4 -4 + autogenerated + + tests/libntp/run-ymd2yd.c@1.7 +5 -4 + autogenerated + + tests/libntp/ssl_init.c@1.7 +11 -6 + fixed formatting + + tests/libntp/statestr.c@1.4 +12 -15 + deleted unnecessary empty functions, fixed formatting, removed an unnecessary include + + tests/libntp/tvtots.c@1.4 +12 -5 + fixed a bug, fixed formatting + + tests/libntp/uglydate.c@1.6 +0 -1 + removed an unnecessary include + + tests/libntp/vi64ops.c@1.5 +1 -1 + deleted a comment + + tests/libntp/vi64ops.c@1.4 +17 -14 + fixed formatting (trailing spaces, the order of includes, return type of a function in a new line) + + tests/libntp/ymd2yd.c@1.5 +0 -1 + removed an include + + tests/libntp/ymd2yd.c@1.4 +14 -16 + fixed formatting, deleted empty setUp() and tearDown() + +ChangeSet@1.3523, 2015-07-05 18:41:36+02:00, tomek@tomek-n56vz.(none) + refnumtoa.c: + fixed formatting + numtoa.c: + remove unnecessary empty functions, fix formatting + lfpfunc.c: + remove unnecessary include, remove old comments, fix formatting, cleanup + numtohost.c: + added const, fixed formatting + lfptostr.c: + fix formatting, delete an include + lfpfunc.c: + removed an endline + ChangeLog: + update with new changes to numtoa.c + numtoa.c: + added "const" + ChangeLog: + changes with numtohost.c + added changes to lfpfunc.c + add info about numtoa.c + updated with modetoa.c changes + add info about lfptostr.c + msyslog.c, modetoa.c: + fix formatting + Many files: + autogenerated + ChangeLog: + add info about msyslog.c + lfpfunc.c: + added spaces after the commas + ChangeLog: + updated info about refnumtoa.c + + ChangeLog@1.1708 +1 -0 + updated info about refnumtoa.c + + ChangeLog@1.1707 +1 -0 + changes with numtohost.c + + ChangeLog@1.1706 +2 -2 + update with new changes to numtoa.c + + ChangeLog@1.1705 +2 -0 + add info about numtoa.c + + ChangeLog@1.1704 +1 -0 + add info about msyslog.c + + ChangeLog@1.1703 +1 -0 + updated with modetoa.c changes + + ChangeLog@1.1702 +3 -1 + add info about lfptostr.c + + ChangeLog@1.1701 +2 -0 + added changes to lfpfunc.c + + tests/libntp/lfpfunc.c@1.11 +0 -2 + removed an endline + + tests/libntp/lfpfunc.c@1.10 +55 -55 + added spaces after the commas + + tests/libntp/lfpfunc.c@1.9 +100 -188 + remove unnecessary include, remove old comments, fix formatting, cleanup + + tests/libntp/lfptostr.c@1.3 +20 -13 + fix formatting, delete an include + + tests/libntp/modetoa.c@1.6 +5 -5 + fix formatting + + tests/libntp/msyslog.c@1.5 +11 -2 + fix formatting + + tests/libntp/numtoa.c@1.5 +3 -3 + added "const" + + tests/libntp/numtoa.c@1.4 +12 -20 + remove unnecessary empty functions, fix formatting + + tests/libntp/numtohost.c@1.4 +3 -4 + added const, fixed formatting + + tests/libntp/refnumtoa.c@1.4 +10 -12 + fixed formatting + + tests/libntp/run-lfpfunc.c@1.12 +9 -9 + autogenerated + + tests/libntp/run-lfptostr.c@1.3 +11 -10 + autogenerated + + tests/libntp/run-modetoa.c@1.8 +2 -1 + autogenerated + + tests/libntp/run-msyslog.c@1.5 +8 -8 + autogenerated + + tests/libntp/run-numtoa.c@1.7 +3 -2 + autogenerated + + tests/libntp/run-numtohost.c@1.7 +1 -0 + autogenerated + + tests/libntp/run-refnumtoa.c@1.5 +1 -1 + autogenerated + +ChangeSet@1.3514.2.2, 2015-07-04 21:58:49+00:00, stenn@psp-at1.ntp.org + sntp/libevent/evconfig-private.h: remove generated filefrom SCM. H.Stenn. + + BitKeeper/deleted/42/evconfig-private.h~c311ed41afa56d3b@1.2 +0 -0 + Delete: sntp/libevent/evconfig-private.h + + ChangeLog@1.1695.1.2 +1 -0 + sntp/libevent/evconfig-private.h: remove generated filefrom SCM. H.Stenn. + +ChangeSet@1.3514.2.1, 2015-07-04 21:44:33+00:00, stenn@psp-at1.ntp.org + sntp/unity/unity_config.h: Distribute it. Harlan Stenn. + + ChangeLog@1.1695.1.1 +1 -0 + sntp/unity/unity_config.h: Distribute it. Harlan Stenn. + + sntp/unity/Makefile.am@1.6.1.1 +1 -0 + sntp/unity/unity_config.h: Distribute it. Harlan Stenn. + +ChangeSet@1.3513.1.1, 2015-07-04 23:32:08+02:00, viperus@ubuntu.(none) + timevalops.c: + added timevaltoa() and fixed the printfs + timespecops.c: + added timespectoa() and fixed the printfs + + tests/libntp/run-timespecops.c@1.6 +28 -28 + + tests/libntp/run-timevalops.c@1.8 +28 -28 + + tests/libntp/timespecops.c@1.6 +58 -1 + added timespectoa() and fixed the printfs + + tests/libntp/timevalops.c@1.9 +53 -1 + added timevaltoa() and fixed the printfs + +ChangeSet@1.3520, 2015-07-04 14:10:34+00:00, tflendrich@psp-deb1.ntp.org + ChangeLog: + updated my changes + + ChangeLog@1.1698 +1 -0 + updated my changs + +ChangeSet@1.3519, 2015-07-04 15:41:50+02:00, tomek@tomek-n56vz.(none) + ChangeLog: + updated to match my changes + + ChangeLog@1.1697 +3 -3 + updated to match my changes + +ChangeSet@1.3518, 2015-07-04 15:39:51+02:00, tomek@tomek-n56vz.(none) + humandate.c: + reordered code so that it is C90-compilant, renamed variables so that they are different that function names, fixed formatting to match NTP's convention + hextolfp.c: + removed a trailing endline, changed formatting to match NTP's convention, + decodenetnum.c: + changed the order of imports, removed an unnecessary import, removed a trailing space, changed the return type from a function to be in a new line + run-humandate.c, run-hextolfp.c, run-decodenetnum.c: + autogenerated + + tests/libntp/decodenetnum.c@1.3 +16 -11 + changed the order of imports, removed an unnecessary import, removed a trailing space, changed the return type from a function to be in a new line + + tests/libntp/hextolfp.c@1.5 +12 -7 + removed a trailing endline, changed formatting to match NTP's convention, + + tests/libntp/humandate.c@1.4 +11 -9 + reordered code so that it is C90-compilant, renamed variables so that they are different that function names, fixed formatting to match NTP's convention + + tests/libntp/run-decodenetnum.c@1.4 +5 -5 + autogenerated + + tests/libntp/run-hextolfp.c@1.5 +6 -6 + autogenerated + + tests/libntp/run-humandate.c@1.3 +3 -2 + autogenerated + +ChangeSet@1.3517, 2015-07-04 12:38:08+00:00, tflendrich@psp-deb1.ntp.org + Makefile.am: + adding a forgotten header, so that "make distcheck" works + + sntp/unity/Makefile.am@1.7 +1 -0 + adding a forgotten header, so that "make distcheck" works + +ChangeSet@1.3516, 2015-07-04 11:55:26+00:00, tflendrich@psp-deb1.ntp.org + ChangeLog: + updated with my changes + + ChangeLog@1.1696 +4 -0 + updated with my changes + +ChangeSet@1.3499.1.1, 2015-07-04 13:39:28+02:00, tomek@tomek-n56vz.(none) + buftvtots.c: + fix formatting, declarations before code (C90) + authkeys.c: + fixed formatting, removed unnecessary comment + calendar.c: + further cleanup: deleted unnecessary comments, made first declaration, then code + clocktime.c: + removed comments, fixed formatting + a_md5encrypt.c: + fix formatting, add (void) as argument to a function etc + caltontp.c: + fixed the order of #includes + run-buftvtots.c, run-a_md5encrypt.c: + adding autogenerated file + calendar.c: + deleted comments, fixed formatting, used snprintf instead of sprintf, change variable names to be meaningful, + caljulian.c: + changed sprintf to snprintf, fixed formatting etc + a_md5encrypt.c: + changed to first declaration, then code (C90 compatibility) + Many files: + autogenerated + authkeys.c: + further changes of formatting + + tests/libntp/a_md5encrypt.c@1.9 +8 -3 + changed to first declaration, then code (C90 compatibility) + + tests/libntp/a_md5encrypt.c@1.8 +17 -21 + fix formatting, add (void) as argument to a function etc + + tests/libntp/authkeys.c@1.8 +20 -10 + further changes of formatting + + tests/libntp/authkeys.c@1.7 +5 -11 + fixed formatting, removed unnecessary comment + + tests/libntp/buftvtots.c@1.2 +10 -7 + fix formatting, declarations before code (C90) + + tests/libntp/calendar.c@1.4 +12 -7 + further cleanup: deleted unnecessary comments, made first declaration, then code + + tests/libntp/calendar.c@1.3 +121 -114 + deleted comments, fixed formatting, used snprintf instead of sprintf, change variable names to be meaningful, + + tests/libntp/caljulian.c@1.7 +41 -39 + changed sprintf to snprintf, fixed formatting etc + + tests/libntp/caltontp.c@1.2 +1 -1 + fixed the order of #includes + + tests/libntp/clocktime.c@1.4 +24 -15 + removed comments, fixed formatting + + tests/libntp/run-a_md5encrypt.c@1.11 +4 -4 + adding autogenerated file + + tests/libntp/run-a_md5encrypt.c@1.10 +10 -10 + adding autogenerated file + + tests/libntp/run-authkeys.c@1.8 +6 -5 + autogenerated + + tests/libntp/run-buftvtots.c@1.2 +9 -8 + adding autogenerated file + + tests/libntp/run-calendar.c@1.5 +10 -10 + autogenerated + + tests/libntp/run-calendar.c@1.4 +22 -21 + autogenerated + + tests/libntp/run-caljulian.c@1.9 +7 -7 + autogenerated + + tests/libntp/run-caltontp.c@1.2 +1 -0 + autogenerated + + tests/libntp/run-clocktime.c@1.5 +17 -16 + autogenerated + +ChangeSet@1.3514, 2015-07-04 10:24:57+00:00, viperus@psp-at1.ntp.org + cleanup + + ChangeLog@1.1695 +2 -3 + cleanup + +ChangeSet@1.3512, 2015-07-04 12:19:42+02:00, viperus@ubuntu.(none) + fixes to unsigned printing in timespecops.c and timevalops.c + + tests/libntp/timespecops.c@1.5 +1 -1 + + tests/libntp/timevalops.c@1.8 +1 -1 + +ChangeSet@1.3511, 2015-07-04 12:15:31+02:00, viperus@ubuntu.(none) + ChangeLog: + added my changes + timespecops.c: + many fixes, better printfs etc. + minor fixes to printf, formatting, etc. + timevalops.c: + minor fixes to printf, formatting, etc. + + ChangeLog@1.1692.1.1 +3 -0 + added my changes + + tests/libntp/run-timespecops.c@1.5 +28 -28 + + tests/libntp/run-timevalops.c@1.7 +28 -28 + + tests/libntp/timespecops.c@1.4 +7 -13 + many fixes, better printfs etc. + minor fixes to printf, formatting, etc. + + tests/libntp/timevalops.c@1.7 +5 -9 + minor fixes to printf, formatting, etc. + +ChangeSet@1.3509.1.1, 2015-07-04 09:34:18+00:00, stenn@psp-at1.ntp.org + [Bug 2866] segmentation fault at initgroups(). Harlan Stenn. + + ChangeLog@1.1693 +1 -0 + [Bug 2866] segmentation fault at initgroups(). Harlan Stenn. + + ntpd/ntpd.c@1.160 +11 -4 + [Bug 2866] segmentation fault at initgroups(). Harlan Stenn. + +ChangeSet@1.3510, 2015-07-04 11:27:04+02:00, viperus@ubuntu.(none) + sockaddrtest.h: + fully converted some tricky cout to printf (af_inet, sockaddr etc.) + + tests/libntp/sockaddrtest.h@1.4 +3 -7 + fully converted some tricky cout to printf (af_inet, sockaddr etc.) + +ChangeSet@1.3505.1.3, 2015-07-04 09:19:48+00:00, stenn@psp-at1.ntp.org + sntp/unity/unity_internals.h: handle *INTPTR_MAX on old Solaris. Harlan Stenn. + + ChangeLog@1.1690.1.2 +1 -0 + sntp/unity/unity_internals.h: handle *INTPTR_MAX on old Solaris. Harlan Stenn. + + sntp/unity/unity_internals.h@1.4 +6 -6 + sntp/unity/unity_internals.h: handle *INTPTR_MAX on old Solaris. Harlan Stenn. + +ChangeSet@1.3505.1.2, 2015-07-04 09:16:51+00:00, stenn@psp-at1.ntp.org + sntp/unity/unity_config.h: handle stdint.h. Harlan Stenn. + + ChangeLog@1.1690.1.1 +1 -0 + sntp/unity/unity_config.h: handle stdint.h. Harlan Stenn. + + sntp/unity/unity_config.h@1.2 +4 -0 + sntp/unity/unity_config.h: handle stdint.h. Harlan Stenn. + +ChangeSet@1.3508, 2015-07-04 09:11:47+00:00, stenn@psp-at1.ntp.org + tests/{libntp,ntpd} function parameter cleanup from Damir + + ChangeLog@1.1691 +2 -0 + tests/{libntp,ntpd} function parameter cleanup from Damir + +ChangeSet@1.3505.1.1, 2015-07-04 08:56:15+00:00, stenn@psp-at1.ntp.org + Update sntp/tests/run-crypto.c + + sntp/tests/run-crypto.c@1.2 +6 -6 + Update sntp/tests/run-crypto.c + +ChangeSet@1.3504.1.2, 2015-07-04 10:38:08+02:00, viperus@ubuntu.(none) + minor fixes, adding void, cleanup... + + tests/libntp/a_md5encrypt.c@1.7.1.1 +5 -5 + + tests/libntp/atouint.c@1.4 +5 -5 + + tests/libntp/authkeys.c@1.6.1.1 +6 -6 + + tests/libntp/buftvtots.c@1.1.1.1 +4 -4 + + tests/libntp/calendar.c@1.2.1.1 +27 -32 + + tests/libntp/caljulian.c@1.6.1.1 +6 -8 + + tests/libntp/calyearstart.c@1.3 +6 -6 + + tests/libntp/clocktime.c@1.3.1.1 +10 -10 + + tests/libntp/lfpfunc.c@1.8 +9 -10 + + tests/libntp/lfptest.h@1.4 +2 -0 + + tests/libntp/msyslog.c@1.4 +0 -1 + + tests/libntp/refnumtoa.c@1.3 +2 -2 + + tests/libntp/run-a_md5encrypt.c@1.9.1.1 +5 -5 + + tests/libntp/run-atouint.c@1.7 +6 -5 + + tests/libntp/run-authkeys.c@1.7.1.1 +7 -6 + + tests/libntp/run-buftvtots.c@1.1.1.1 +5 -4 + + tests/libntp/run-calendar.c@1.3.1.1 +23 -22 + + tests/libntp/run-caljulian.c@1.8.1.1 +8 -8 + + tests/libntp/run-calyearstart.c@1.4 +4 -3 + + tests/libntp/run-clocktime.c@1.4.1.1 +9 -8 + + tests/libntp/run-lfpfunc.c@1.11 +17 -17 + + tests/libntp/run-msyslog.c@1.4 +8 -8 + + tests/libntp/run-refidsmear.c@1.3 +1 -1 + + tests/libntp/run-refnumtoa.c@1.4 +3 -2 + + tests/libntp/run-ssl_init.c@1.5 +6 -5 + + tests/libntp/run-timespecops.c@1.4 +29 -28 + + tests/libntp/run-timevalops.c@1.6 +29 -28 + + tests/libntp/run-vi64ops.c@1.4 +6 -6 + + tests/libntp/ssl_init.c@1.6 +5 -5 + + tests/libntp/timespecops.c@1.3 +28 -28 + + tests/libntp/timevalops.c@1.6 +37 -37 + + tests/libntp/vi64ops.c@1.3 +10 -11 + +ChangeSet@1.3504.1.1, 2015-07-04 10:08:41+02:00, viperus@ubuntu.(none) + minor warning fixes, adding voids etc. + + tests/ntpd/leapsec.c@1.3 +40 -45 + + tests/ntpd/run-leapsec.c@1.3 +66 -66 + +ChangeSet@1.3505, 2015-07-04 08:08:23+00:00, stenn@psp-at1.ntp.org + sntp/tests/ function parameter list cleanup. Damir Tomi\xc4\x87. + + ChangeLog@1.1690 +1 -0 + sntp/tests/ function parameter list cleanup. Damir Tomi\xc4\x87. + +ChangeSet@1.3504, 2015-07-04 09:49:26+02:00, viperus@ubuntu.(none) + minor warning fixes like adding void etc. + + sntp/tests/crypto.c@1.6 +1 -0 + + sntp/tests/keyFile.c@1.4 +5 -5 + + sntp/tests/kodDatabase.c@1.3 +5 -5 + + sntp/tests/kodFile.c@1.6 +8 -8 + + sntp/tests/packetProcessing.c@1.5 +2 -2 + + sntp/tests/run-keyFile.c@1.5 +6 -5 + + sntp/tests/run-kodDatabase.c@1.2 +6 -5 + + sntp/tests/run-kodFile.c@1.3 +7 -6 + + sntp/tests/run-utilities.c@1.2 +14 -14 + + sntp/tests/sntptest.h@1.4 +6 -3 + + sntp/tests/utilities.c@1.2 +7 -9 + +ChangeSet@1.3503, 2015-07-04 07:25:15+00:00, stenn@psp-at1.ntp.org + top_srcdir can change based on ntp v. sntp. Harlan Stenn. + + ChangeLog@1.1689 +1 -0 + top_srcdir can change based on ntp v. sntp. Harlan Stenn. + + sntp/tests/Makefile.am@1.58 +1 -1 + top_srcdir can change based on ntp v. sntp. Harlan Stenn. + +ChangeSet@1.3502, 2015-07-04 00:44:41-04:00, stenn@deacon.udel.edu + On some versions of HP-UX, inttypes.h does not include stdint.h. H.Stenn. + + ChangeLog@1.1688 +1 -0 + On some versions of HP-UX, inttypes.h does not include stdint.h. H.Stenn. + + include/ntp_types.h@1.35 +2 -1 + On some versions of HP-UX, inttypes.h does not include stdint.h. H.Stenn. + +ChangeSet@1.3501, 2015-07-04 03:49:10+00:00, stenn@psp-at1.ntp.org + Phase 1 deprecation of google test in sntp/tests/. Harlan Stenn. + + ChangeLog@1.1687 +1 -0 + Phase 1 deprecation of google test in sntp/tests/. Harlan Stenn. + + sntp/tests/Makefile.am@1.57 +20 -97 + Phase 1 deprecation of google test in sntp/tests/. Harlan Stenn. + +ChangeSet@1.3500, 2015-07-03 20:30:06+00:00, stenn@psp-fb1.ntp.org + tests/ntpd/g_leapsec.cpp typo fix. Harlan Stenn. + + ChangeLog@1.1686 +1 -0 + tests/ntpd/g_leapsec.cpp typo fix. Harlan Stenn. + + tests/ntpd/g_leapsec.cpp@1.16 +1 -1 + tests/ntpd/g_leapsec.cpp typo fix. Harlan Stenn. + +ChangeSet@1.3498, 2015-07-03 19:27:53+00:00, stenn@psp-at1.ntp.org + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + ChangeLog@1.1685 +1 -0 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + sntp/tests/Makefile.am@1.56 +4 -2 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + sntp/unity/Makefile.am@1.6 +1 -1 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + sntp/unity/unity_config.h@1.1 +8 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity_config.h + + sntp/unity/unity_config.h@1.0 +0 -0 + + tests/bug-2803/Makefile.am@1.13 +2 -0 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + tests/libntp/Makefile.am@1.83.1.1 +2 -4 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + tests/ntpd/Makefile.am@1.1.1.1 +2 -0 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + tests/sandbox/Makefile.am@1.5 +2 -0 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + tests/sandbox/smeartest.c@1.3.1.3 +12 -0 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + + tests/sec-2853/Makefile.am@1.3 +2 -0 + Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. + +ChangeSet@1.3497, 2015-07-03 09:30:02+00:00, stenn@psp-at1.ntp.org + libntp/emalloc.c: Remove explicit include of stdint.h. Harlan Stenn. + + ChangeLog@1.1684 +1 -0 + libntp/emalloc.c: Remove explicit include of stdint.h. Harlan Stenn. + + libntp/emalloc.c@1.19 +0 -2 + libntp/emalloc.c: Remove explicit include of stdint.h. Harlan Stenn. + +ChangeSet@1.3492.1.3, 2015-07-02 09:34:06+00:00, stenn@psp-at1.ntp.org + Fix ChangeLog + + ChangeLog@1.1680.1.2 +3 -1 + Fix ChangeLog + +ChangeSet@1.3495, 2015-07-02 09:32:14+00:00, stenn@psp-at1.ntp.org + Fix ChangeLog + + ChangeLog@1.1682 +3 -1 + Fix ChangeLog + +ChangeSet@1.3473.1.23, 2015-07-01 10:06:49+02:00, viperus@ubuntu.(none) + leapsec.c: + added include to fix everything, yey! + Makefile.am: + changed the order of libntp.a and libntpd.a, stuff builds now + + tests/ntpd/Makefile.am@1.3 +11 -9 + changed the order of libntp.a and libntpd.a, stuff builds now + + tests/ntpd/leapsec.c@1.2 +8 -4 + added include to fix everything, yey! + + tests/ntpd/run-leapsec.c@1.2 +33 -33 + +ChangeSet@1.3473.1.22, 2015-07-01 09:31:35+02:00, viperus@ubuntu.(none) + g_leapsec.cpp: + Rename: tests/ntpd/leapsec.cpp -> tests/ntpd/g_leapsec.cpp + run-leapsec.c, leapsec.c: + new file + Makefile.am: + added /tests/ntpd/ dir + unity tests + removed a comment line + g_ntpdtest.h: + Rename: tests/ntpd/ntpdtest.h -> tests/ntpd/g_ntpdtest.h + Makefile.am: + added support for unity tests + test-libntp.h: + added new headers + g_ntpdtest.cpp: + minor change in the header name + Rename: tests/ntpd/ntpdtest.cpp -> tests/ntpd/g_ntpdtest.cpp + + tests/Makefile.am@1.9.1.1 +6 -5 + added /tests/ntpd/ dir + unity tests + + tests/libntp/Makefile.am@1.84 +0 -1 + removed a comment line + + tests/libntp/test-libntp.h@1.7 +5 -0 + added new headers + + tests/ntpd/Makefile.am@1.2 +62 -6 + added support for unity tests + + tests/ntpd/g_leapsec.cpp@1.15 +0 -0 + Rename: tests/ntpd/leapsec.cpp -> tests/ntpd/g_leapsec.cpp + + tests/ntpd/g_ntpdtest.cpp@1.3 +1 -1 + minor change in the header name + + tests/ntpd/g_ntpdtest.cpp@1.2 +0 -0 + Rename: tests/ntpd/ntpdtest.cpp -> tests/ntpd/g_ntpdtest.cpp + + tests/ntpd/g_ntpdtest.h@1.2 +0 -0 + Rename: tests/ntpd/ntpdtest.h -> tests/ntpd/g_ntpdtest.h + + tests/ntpd/leapsec.c@1.1 +1230 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/ntpd/leapsec.c + + tests/ntpd/leapsec.c@1.0 +0 -0 + + tests/ntpd/run-leapsec.c@1.1 +116 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/ntpd/run-leapsec.c + + tests/ntpd/run-leapsec.c@1.0 +0 -0 + +ChangeSet@1.3492.2.1, 2015-07-01 03:11:28-04:00, stenn@deacon.udel.edu + Update the repo's description and contact email + + BitKeeper/etc/config@1.11 +2 -2 + Update the repo's description and contact email + +ChangeSet@1.3492.1.1, 2015-07-01 08:53:24+02:00, jnperlin@hydra.(none) + [Bug 2867] ntpd with autokey active crashed by 'ntpq -crv' + + ChangeLog@1.1680.1.1 +1 -0 + [Bug 2867] ntpd with autokey active crashed by 'ntpq -crv' + + + ntpd/ntp_control.c@1.201 +5 -2 + [Bug 2867] ntpd with autokey active crashed by 'ntpq -crv' + make sure 'ctl_var' table matches indices (CS_LEAPSMEAR* is unconditionally defined and affects AUTOKEY vars) + +ChangeSet@1.3493, 2015-07-01 08:40:44+02:00, jnperlin@nemesis.localnet + [Bug 2864] 4.2.8p3 fails to compile on Windows. + fixed project files. (tested with VS2008 and VS2013) + + ChangeLog@1.1681 +1 -0 + [Bug 2864] 4.2.8p3 fails to compile on Windows. + fix project files. (tested with VS2008 and VS2013) + + ports/winnt/vs2005/ntpd.vcproj@1.20 +22 -0 + [Bug 2864] 4.2.8p3 fails to compile on Windows. + fixed project files. (UNTESTED!) + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.49 +4 -0 + [Bug 2864] 4.2.8p3 fails to compile on Windows. + fixed project files. (tested) + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.7 +1 -0 + [Bug 2864] 4.2.8p3 fails to compile on Windows. + fixed project files. (tested) + + ports/winnt/vs2013/ntpd/ntpd.vcxproj.filters@1.5 +3 -0 + [Bug 2864] 4.2.8p3 fails to compile on Windows. + fixed project files. (tested) + +ChangeSet@1.3492, 2015-06-29 16:52:34-04:00, stenn@deacon.udel.edu + Makefile.in should not be checked in + + BitKeeper/deleted/bd/Makefile.in~a06c74c485656b20@1.3 +0 -0 + Delete: tests/sec-2853/Makefile.in + +ChangeSet@1.3491, 2015-06-29 16:34:44-04:00, stenn@deacon.udel.edu + NTP_4_2_8P3 + TAG: NTP_4_2_8P3 + + ChangeLog@1.1680 +1 -0 + NTP_4_2_8P3 + + ntpd/invoke-ntp.conf.texi@1.188 +1 -1 + NTP_4_2_8P3 + + ntpd/invoke-ntp.keys.texi@1.182 +1 -1 + NTP_4_2_8P3 + + ntpd/invoke-ntpd.texi@1.499 +2 -2 + NTP_4_2_8P3 + + ntpd/ntp.conf.5man@1.222 +3 -3 + NTP_4_2_8P3 + + ntpd/ntp.conf.5mdoc@1.222 +1 -1 + NTP_4_2_8P3 + + ntpd/ntp.conf.html@1.177 +15 -1 + NTP_4_2_8P3 + + ntpd/ntp.conf.man.in@1.222 +3 -3 + NTP_4_2_8P3 + + ntpd/ntp.conf.mdoc.in@1.222 +1 -1 + NTP_4_2_8P3 + + ntpd/ntp.keys.5man@1.216 +2 -2 + NTP_4_2_8P3 + + ntpd/ntp.keys.5mdoc@1.216 +2 -2 + NTP_4_2_8P3 + + ntpd/ntp.keys.html@1.178 +1 -1 + NTP_4_2_8P3 + + ntpd/ntp.keys.man.in@1.216 +2 -2 + NTP_4_2_8P3 + + ntpd/ntp.keys.mdoc.in@1.216 +2 -2 + NTP_4_2_8P3 + + ntpd/ntpd-opts.c@1.521 +245 -245 + NTP_4_2_8P3 + + ntpd/ntpd-opts.h@1.520 +3 -3 + NTP_4_2_8P3 + + ntpd/ntpd.1ntpdman@1.328 +3 -3 + NTP_4_2_8P3 + + ntpd/ntpd.1ntpdmdoc@1.328 +2 -2 + NTP_4_2_8P3 + + ntpd/ntpd.html@1.172 +2 -2 + NTP_4_2_8P3 + + ntpd/ntpd.man.in@1.328 +3 -3 + NTP_4_2_8P3 + + ntpd/ntpd.mdoc.in@1.328 +2 -2 + NTP_4_2_8P3 + + ntpdc/invoke-ntpdc.texi@1.496 +2 -2 + NTP_4_2_8P3 + + ntpdc/ntpdc-opts.c@1.514 +107 -107 + NTP_4_2_8P3 + + ntpdc/ntpdc-opts.h@1.513 +3 -3 + NTP_4_2_8P3 + + ntpdc/ntpdc.1ntpdcman@1.327 +3 -3 + NTP_4_2_8P3 + + ntpdc/ntpdc.1ntpdcmdoc@1.327 +2 -2 + NTP_4_2_8P3 + + ntpdc/ntpdc.html@1.340 +2 -2 + NTP_4_2_8P3 + + ntpdc/ntpdc.man.in@1.327 +3 -3 + NTP_4_2_8P3 + + ntpdc/ntpdc.mdoc.in@1.327 +2 -2 + NTP_4_2_8P3 + + ntpq/invoke-ntpq.texi@1.503 +2 -2 + NTP_4_2_8P3 + + ntpq/ntpq-opts.c@1.520 +106 -106 + NTP_4_2_8P3 + + ntpq/ntpq-opts.h@1.518 +3 -3 + NTP_4_2_8P3 + + ntpq/ntpq.1ntpqman@1.331 +3 -3 + NTP_4_2_8P3 + + ntpq/ntpq.1ntpqmdoc@1.331 +2 -2 + NTP_4_2_8P3 + + ntpq/ntpq.html@1.169 +2 -2 + NTP_4_2_8P3 + + ntpq/ntpq.man.in@1.331 +3 -3 + NTP_4_2_8P3 + + ntpq/ntpq.mdoc.in@1.331 +2 -2 + NTP_4_2_8P3 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.498 +2 -2 + NTP_4_2_8P3 + + ntpsnmpd/ntpsnmpd-opts.c@1.516 +68 -68 + NTP_4_2_8P3 + + ntpsnmpd/ntpsnmpd-opts.h@1.515 +3 -3 + NTP_4_2_8P3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.327 +3 -3 + NTP_4_2_8P3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.327 +2 -2 + NTP_4_2_8P3 + + ntpsnmpd/ntpsnmpd.html@1.167 +1 -1 + NTP_4_2_8P3 + + ntpsnmpd/ntpsnmpd.man.in@1.327 +3 -3 + NTP_4_2_8P3 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.327 +2 -2 + NTP_4_2_8P3 + + packageinfo.sh@1.515 +2 -2 + NTP_4_2_8P3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.88 +3 -3 + NTP_4_2_8P3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.89 +2 -2 + NTP_4_2_8P3 + + scripts/calc_tickadj/calc_tickadj.html@1.90 +1 -1 + NTP_4_2_8P3 + + scripts/calc_tickadj/calc_tickadj.man.in@1.87 +3 -3 + NTP_4_2_8P3 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.89 +2 -2 + NTP_4_2_8P3 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.92 +1 -1 + NTP_4_2_8P3 + + scripts/invoke-plot_summary.texi@1.109 +2 -2 + NTP_4_2_8P3 + + scripts/invoke-summary.texi@1.109 +2 -2 + NTP_4_2_8P3 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.319 +2 -2 + NTP_4_2_8P3 + + scripts/ntp-wait/ntp-wait-opts@1.55 +2 -2 + NTP_4_2_8P3 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.316 +3 -3 + NTP_4_2_8P3 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.317 +2 -2 + NTP_4_2_8P3 + + scripts/ntp-wait/ntp-wait.html@1.336 +2 -2 + NTP_4_2_8P3 + + scripts/ntp-wait/ntp-wait.man.in@1.316 +3 -3 + NTP_4_2_8P3 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.317 +2 -2 + NTP_4_2_8P3 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.107 +2 -2 + NTP_4_2_8P3 + + scripts/ntpsweep/ntpsweep-opts@1.57 +2 -2 + NTP_4_2_8P3 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.95 +3 -3 + NTP_4_2_8P3 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.95 +2 -2 + NTP_4_2_8P3 + + scripts/ntpsweep/ntpsweep.html@1.108 +2 -2 + NTP_4_2_8P3 + + scripts/ntpsweep/ntpsweep.man.in@1.95 +3 -3 + NTP_4_2_8P3 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.96 +2 -2 + NTP_4_2_8P3 + + scripts/ntptrace/invoke-ntptrace.texi@1.108 +2 -2 + NTP_4_2_8P3 + + scripts/ntptrace/ntptrace-opts@1.57 +2 -2 + NTP_4_2_8P3 + + scripts/ntptrace/ntptrace.1ntptraceman@1.95 +3 -3 + NTP_4_2_8P3 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.96 +2 -2 + NTP_4_2_8P3 + + scripts/ntptrace/ntptrace.html@1.109 +2 -2 + NTP_4_2_8P3 + + scripts/ntptrace/ntptrace.man.in@1.95 +3 -3 + NTP_4_2_8P3 + + scripts/ntptrace/ntptrace.mdoc.in@1.97 +2 -2 + NTP_4_2_8P3 + + scripts/plot_summary-opts@1.57 +2 -2 + NTP_4_2_8P3 + + scripts/plot_summary.1plot_summaryman@1.107 +3 -3 + NTP_4_2_8P3 + + scripts/plot_summary.1plot_summarymdoc@1.107 +2 -2 + NTP_4_2_8P3 + + scripts/plot_summary.html@1.110 +2 -2 + NTP_4_2_8P3 + + scripts/plot_summary.man.in@1.107 +3 -3 + NTP_4_2_8P3 + + scripts/plot_summary.mdoc.in@1.107 +2 -2 + NTP_4_2_8P3 + + scripts/summary-opts@1.57 +2 -2 + NTP_4_2_8P3 + + scripts/summary.1summaryman@1.107 +3 -3 + NTP_4_2_8P3 + + scripts/summary.1summarymdoc@1.107 +2 -2 + NTP_4_2_8P3 + + scripts/summary.html@1.110 +2 -2 + NTP_4_2_8P3 + + scripts/summary.man.in@1.107 +3 -3 + NTP_4_2_8P3 + + scripts/summary.mdoc.in@1.107 +2 -2 + NTP_4_2_8P3 + + scripts/update-leap/invoke-update-leap.texi@1.8 +1 -1 + NTP_4_2_8P3 + + scripts/update-leap/update-leap-opts@1.8 +2 -2 + NTP_4_2_8P3 + + scripts/update-leap/update-leap.1update-leapman@1.8 +3 -3 + NTP_4_2_8P3 + + scripts/update-leap/update-leap.1update-leapmdoc@1.8 +2 -2 + NTP_4_2_8P3 + + scripts/update-leap/update-leap.html@1.8 +1 -1 + NTP_4_2_8P3 + + scripts/update-leap/update-leap.man.in@1.8 +3 -3 + NTP_4_2_8P3 + + scripts/update-leap/update-leap.mdoc.in@1.8 +2 -2 + NTP_4_2_8P3 + + sntp/invoke-sntp.texi@1.496 +2 -2 + NTP_4_2_8P3 + + sntp/sntp-opts.c@1.515 +159 -159 + NTP_4_2_8P3 + + sntp/sntp-opts.h@1.513 +3 -3 + NTP_4_2_8P3 + + sntp/sntp.1sntpman@1.331 +3 -3 + NTP_4_2_8P3 + + sntp/sntp.1sntpmdoc@1.331 +2 -2 + NTP_4_2_8P3 + + sntp/sntp.html@1.511 +2 -2 + NTP_4_2_8P3 + + sntp/sntp.man.in@1.331 +3 -3 + NTP_4_2_8P3 + + sntp/sntp.mdoc.in@1.331 +2 -2 + NTP_4_2_8P3 + + util/invoke-ntp-keygen.texi@1.499 +2 -2 + NTP_4_2_8P3 + + util/ntp-keygen-opts.c@1.517 +173 -173 + NTP_4_2_8P3 + + util/ntp-keygen-opts.h@1.515 +3 -3 + NTP_4_2_8P3 + + util/ntp-keygen.1ntp-keygenman@1.327 +3 -3 + NTP_4_2_8P3 + + util/ntp-keygen.1ntp-keygenmdoc@1.327 +2 -2 + NTP_4_2_8P3 + + util/ntp-keygen.html@1.173 +2 -2 + NTP_4_2_8P3 + + util/ntp-keygen.man.in@1.327 +3 -3 + NTP_4_2_8P3 + + util/ntp-keygen.mdoc.in@1.327 +2 -2 + NTP_4_2_8P3 + +ChangeSet@1.3490, 2015-06-29 16:11:13-04:00, stenn@deacon.udel.edu + Release ntp-4.2.8p3 + + packageinfo.sh@1.514 +1 -1 + Release ntp-4.2.8p3 + +ChangeSet@1.3489, 2015-06-29 19:33:22+00:00, stenn@psp-at1.ntp.org + NEWS file update for bug 2853 + + NEWS@1.144 +18 -3 + NEWS file update for bug 2853 + +ChangeSet@1.3473.1.21, 2015-06-29 20:33:15+02:00, viperus@ubuntu.(none) + a_md5encrypt.c: + minor change to memory compare, suggested by Tomasz + + tests/libntp/a_md5encrypt.c@1.7 +2 -1 + minor change to memory compare, suggested by Tomasz + + tests/libntp/run-a_md5encrypt.c@1.9 +5 -4 + +ChangeSet@1.3473.3.23, 2015-06-29 06:00:52+00:00, stenn@psp-at1.ntp.org + html/miscopt.html: Document leapsmearinterval, other cleanup. Harlan Stenn. + + ChangeLog@1.1666.1.19 +1 -0 + html/miscopt.html: Document leapsmearinterval, other cleanup. Harlan Stenn. + + html/miscopt.html@1.82 +18 -15 + html/miscopt.html: Document leapsmearinterval, other cleanup. Harlan Stenn. + +ChangeSet@1.3473.3.22, 2015-06-29 05:28:47+00:00, stenn@psp-at1.ntp.org + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + + ChangeLog@1.1666.1.18 +1 -0 + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + + ntpd/invoke-ntp.conf.texi@1.187 +17 -1 + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + + ntpd/ntp.conf.5man@1.221 +21 -3 + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + + ntpd/ntp.conf.5mdoc@1.221 +18 -2 + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + + ntpd/ntp.conf.def@1.17 +16 -0 + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + + ntpd/ntp.conf.man.in@1.221 +21 -3 + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + + ntpd/ntp.conf.mdoc.in@1.221 +18 -2 + ntpd/ntp.conf.def: Document DSCP and leapsmearinterval. Harlan Stenn. + +ChangeSet@1.3486, 2015-06-29 03:39:39+00:00, stenn@psp-at1.ntp.org + Updated entry for Sec 2853 + + ChangeLog@1.1677 +2 -1 + Updated entry for Sec 2853 + +ChangeSet@1.3473.4.2, 2015-06-29 04:57:16+02:00, tomek@tomek-n56vz.(none) + ChangeLog: + moved a change to the proper place + + ChangeLog@1.1666.2.2 +1 -1 + moved a change to the proper place + +ChangeSet@1.3473.4.1, 2015-06-29 04:50:55+02:00, tomek@tomek-n56vz.(none) + ChangeLog: + updated my changes + msyslog.c: + fixed a gcc warning + run-msyslog.c: + checking in the autogenerated file + + ChangeLog@1.1666.2.1 +4 -0 + updated my changes + + tests/libntp/msyslog.c@1.3 +2 -2 + fixed a gcc warning + + tests/libntp/run-msyslog.c@1.3 +1 -0 + checking in the autogenerated file + +ChangeSet@1.3473.3.20, 2015-06-29 01:16:44+00:00, stenn@psp-at1.ntp.org + [Bug 2860] ntpq ifstats sanity check is too stringent. Frank Kardel. + + ChangeLog@1.1666.1.16 +1 -0 + [Bug 2860] ntpq ifstats sanity check is too stringent. Frank Kardel. + + NEWS@1.143 +1 -0 + [Bug 2860] ntpq ifstats sanity check is too stringent. Frank Kardel. + + ntpq/ntpq-subs.c@1.109 +1 -1 + [Bug 2860] ntpq ifstats sanity check is too stringent. Frank Kardel. + +ChangeSet@1.3473.3.19, 2015-06-29 01:13:38+00:00, stenn@psp-at1.ntp.org + Update the NEWS file with info about README.leapsmear + + NEWS@1.142 +2 -1 + Update the NEWS file with info about README.leapsmear + +ChangeSet@1.3473.3.18, 2015-06-29 00:10:53+00:00, stenn@psp-at1.ntp.org + README.leapsmear edited. Harlan Stenn. + + ChangeLog@1.1666.1.15 +1 -0 + README.leapsmear edited. Harlan Stenn. + + README.leapsmear@1.2 +240 -75 + README.leapsmear edited. Harlan Stenn. + +ChangeSet@1.3473.3.17, 2015-06-28 21:20:27+00:00, stenn@psp-at1.ntp.org + README.leapsmear added. Martin Burnicki. + + ChangeLog@1.1666.1.14 +1 -0 + README.leapsmear added. Martin Burnicki. + + Makefile.am@1.132 +1 -0 + README.leapsmear added. Martin Burnicki. + + README.leapsmear@1.1 +107 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable/README.leapsmear + + README.leapsmear@1.0 +0 -0 + +ChangeSet@1.3473.3.16, 2015-06-27 23:05:51-04:00, stenn@deacon.udel.edu + [Bug 2846] Report 'unsynchronized' status during the leap second. Fixed in Martin's changes to Bug 2855. Martin Burnicki. + + ChangeLog@1.1666.1.13 +2 -0 + [Bug 2846] Report 'unsynchronized' status during the leap second. Fixed in Martin's changes to Bug 2855. Martin Burnicki. + +ChangeSet@1.3473.3.15, 2015-06-27 21:34:55+00:00, stenn@psp-at1.ntp.org + NEWS file update + + NEWS@1.141 +12 -0 + NEWS file update + +ChangeSet@1.3473.3.14, 2015-06-27 19:25:39+00:00, stenn@psp-at1.ntp.org + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + + ChangeLog@1.1666.1.12 +4 -0 + [Bug 1060] Buffer overruns in libparse/clk_rawdcf.c. Helge Oldach. + + include/parse.h@1.13 +3 -3 + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + + libparse/clk_meinberg.c@1.15 +2 -2 + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + + libparse/clk_rawdcf.c@1.22 +100 -12 + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + + libparse/clk_schmid.c@1.14 +2 -2 + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + + ntpd/refclock_parse.c@1.80 +4 -4 + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + + parseutil/dcfd.c@1.29 +1 -1 + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + + parseutil/testdcf.c@1.11 +1 -1 + [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. + +ChangeSet@1.3473.3.13, 2015-06-27 05:21:56-04:00, stenn@deacon.udel.edu + NTP_4_2_8P3_RC3 + TAG: NTP_4_2_8P3_RC3 + + ChangeLog@1.1666.1.11 +1 -0 + NTP_4_2_8P3_RC3 + + ntpd/invoke-ntp.conf.texi@1.186 +1 -1 + NTP_4_2_8P3_RC3 + + ntpd/invoke-ntp.keys.texi@1.181 +1 -1 + NTP_4_2_8P3_RC3 + + ntpd/invoke-ntpd.texi@1.498 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntp.conf.5man@1.220 +3 -3 + NTP_4_2_8P3_RC3 + + ntpd/ntp.conf.5mdoc@1.220 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntp.conf.html@1.176 +1 -1 + NTP_4_2_8P3_RC3 + + ntpd/ntp.conf.man.in@1.220 +3 -3 + NTP_4_2_8P3_RC3 + + ntpd/ntp.conf.mdoc.in@1.220 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntp.keys.5man@1.215 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntp.keys.5mdoc@1.215 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntp.keys.html@1.177 +1 -1 + NTP_4_2_8P3_RC3 + + ntpd/ntp.keys.man.in@1.215 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntp.keys.mdoc.in@1.215 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntpd-opts.c@1.520 +7 -7 + NTP_4_2_8P3_RC3 + + ntpd/ntpd-opts.h@1.519 +3 -3 + NTP_4_2_8P3_RC3 + + ntpd/ntpd.1ntpdman@1.327 +3 -3 + NTP_4_2_8P3_RC3 + + ntpd/ntpd.1ntpdmdoc@1.327 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntpd.html@1.171 +2 -2 + NTP_4_2_8P3_RC3 + + ntpd/ntpd.man.in@1.327 +3 -3 + NTP_4_2_8P3_RC3 + + ntpd/ntpd.mdoc.in@1.327 +2 -2 + NTP_4_2_8P3_RC3 + + ntpdc/invoke-ntpdc.texi@1.495 +2 -2 + NTP_4_2_8P3_RC3 + + ntpdc/ntpdc-opts.c@1.513 +7 -7 + NTP_4_2_8P3_RC3 + + ntpdc/ntpdc-opts.h@1.512 +3 -3 + NTP_4_2_8P3_RC3 + + ntpdc/ntpdc.1ntpdcman@1.326 +3 -3 + NTP_4_2_8P3_RC3 + + ntpdc/ntpdc.1ntpdcmdoc@1.326 +2 -2 + NTP_4_2_8P3_RC3 + + ntpdc/ntpdc.html@1.339 +2 -2 + NTP_4_2_8P3_RC3 + + ntpdc/ntpdc.man.in@1.326 +3 -3 + NTP_4_2_8P3_RC3 + + ntpdc/ntpdc.mdoc.in@1.326 +2 -2 + NTP_4_2_8P3_RC3 + + ntpq/invoke-ntpq.texi@1.502 +2 -2 + NTP_4_2_8P3_RC3 + + ntpq/ntpq-opts.c@1.519 +7 -7 + NTP_4_2_8P3_RC3 + + ntpq/ntpq-opts.h@1.517 +3 -3 + NTP_4_2_8P3_RC3 + + ntpq/ntpq.1ntpqman@1.330 +3 -3 + NTP_4_2_8P3_RC3 + + ntpq/ntpq.1ntpqmdoc@1.330 +2 -2 + NTP_4_2_8P3_RC3 + + ntpq/ntpq.html@1.168 +2 -2 + NTP_4_2_8P3_RC3 + + ntpq/ntpq.man.in@1.330 +3 -3 + NTP_4_2_8P3_RC3 + + ntpq/ntpq.mdoc.in@1.330 +2 -2 + NTP_4_2_8P3_RC3 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.497 +2 -2 + NTP_4_2_8P3_RC3 + + ntpsnmpd/ntpsnmpd-opts.c@1.515 +7 -7 + NTP_4_2_8P3_RC3 + + ntpsnmpd/ntpsnmpd-opts.h@1.514 +3 -3 + NTP_4_2_8P3_RC3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.326 +3 -3 + NTP_4_2_8P3_RC3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.326 +2 -2 + NTP_4_2_8P3_RC3 + + ntpsnmpd/ntpsnmpd.html@1.166 +1 -1 + NTP_4_2_8P3_RC3 + + ntpsnmpd/ntpsnmpd.man.in@1.326 +3 -3 + NTP_4_2_8P3_RC3 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.326 +2 -2 + NTP_4_2_8P3_RC3 + + packageinfo.sh@1.513 +1 -1 + NTP_4_2_8P3_RC3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.87 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.88 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/calc_tickadj/calc_tickadj.html@1.89 +1 -1 + NTP_4_2_8P3_RC3 + + scripts/calc_tickadj/calc_tickadj.man.in@1.86 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.88 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.91 +1 -1 + NTP_4_2_8P3_RC3 + + scripts/invoke-plot_summary.texi@1.108 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/invoke-summary.texi@1.108 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.318 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntp-wait/ntp-wait-opts@1.54 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.315 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.316 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntp-wait/ntp-wait.html@1.335 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntp-wait/ntp-wait.man.in@1.315 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.316 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.106 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntpsweep/ntpsweep-opts@1.56 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.94 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.94 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntpsweep/ntpsweep.html@1.107 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntpsweep/ntpsweep.man.in@1.94 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.95 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntptrace/invoke-ntptrace.texi@1.107 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntptrace/ntptrace-opts@1.56 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntptrace/ntptrace.1ntptraceman@1.94 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.95 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntptrace/ntptrace.html@1.108 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/ntptrace/ntptrace.man.in@1.94 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/ntptrace/ntptrace.mdoc.in@1.96 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/plot_summary-opts@1.56 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/plot_summary.1plot_summaryman@1.106 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/plot_summary.1plot_summarymdoc@1.106 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/plot_summary.html@1.109 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/plot_summary.man.in@1.106 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/plot_summary.mdoc.in@1.106 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/summary-opts@1.56 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/summary.1summaryman@1.106 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/summary.1summarymdoc@1.106 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/summary.html@1.109 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/summary.man.in@1.106 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/summary.mdoc.in@1.106 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/update-leap/invoke-update-leap.texi@1.7 +1 -1 + NTP_4_2_8P3_RC3 + + scripts/update-leap/update-leap-opts@1.7 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/update-leap/update-leap.1update-leapman@1.7 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/update-leap/update-leap.1update-leapmdoc@1.7 +2 -2 + NTP_4_2_8P3_RC3 + + scripts/update-leap/update-leap.html@1.7 +51 -2 + NTP_4_2_8P3_RC3 + + scripts/update-leap/update-leap.man.in@1.7 +3 -3 + NTP_4_2_8P3_RC3 + + scripts/update-leap/update-leap.mdoc.in@1.7 +2 -2 + NTP_4_2_8P3_RC3 + + sntp/invoke-sntp.texi@1.495 +2 -2 + NTP_4_2_8P3_RC3 + + sntp/sntp-opts.c@1.514 +7 -7 + NTP_4_2_8P3_RC3 + + sntp/sntp-opts.h@1.512 +3 -3 + NTP_4_2_8P3_RC3 + + sntp/sntp.1sntpman@1.330 +3 -3 + NTP_4_2_8P3_RC3 + + sntp/sntp.1sntpmdoc@1.330 +2 -2 + NTP_4_2_8P3_RC3 + + sntp/sntp.html@1.510 +2 -2 + NTP_4_2_8P3_RC3 + + sntp/sntp.man.in@1.330 +3 -3 + NTP_4_2_8P3_RC3 + + sntp/sntp.mdoc.in@1.330 +2 -2 + NTP_4_2_8P3_RC3 + + util/invoke-ntp-keygen.texi@1.498 +2 -2 + NTP_4_2_8P3_RC3 + + util/ntp-keygen-opts.c@1.516 +7 -7 + NTP_4_2_8P3_RC3 + + util/ntp-keygen-opts.h@1.514 +3 -3 + NTP_4_2_8P3_RC3 + + util/ntp-keygen.1ntp-keygenman@1.326 +3 -3 + NTP_4_2_8P3_RC3 + + util/ntp-keygen.1ntp-keygenmdoc@1.326 +2 -2 + NTP_4_2_8P3_RC3 + + util/ntp-keygen.html@1.172 +2 -2 + NTP_4_2_8P3_RC3 + + util/ntp-keygen.man.in@1.326 +3 -3 + NTP_4_2_8P3_RC3 + + util/ntp-keygen.mdoc.in@1.326 +2 -2 + NTP_4_2_8P3_RC3 + +ChangeSet@1.3473.3.12, 2015-06-27 04:45:02-04:00, stenn@deacon.udel.edu + Update the NEWS file for 4.2.8p3-RC3 + + NEWS@1.140 +26 -0 + Update the NEWS file for 4.2.8p3-RC3 + +ChangeSet@1.3473.3.11, 2015-06-27 04:20:07-04:00, stenn@deacon.udel.edu + html/drivers/driver22.html: typo fix. Harlan Stenn. + + ChangeLog@1.1666.1.10 +1 -0 + html/drivers/driver22.html: typo fix. Harlan Stenn. + + html/drivers/driver22.html@1.23 +1 -1 + html/drivers/driver22.html: typo fix. Harlan Stenn. + +ChangeSet@1.3473.3.10, 2015-06-27 02:22:09-04:00, stenn@deacon.udel.edu + [Bug 2857] Stratus VOS does not support SIGIO. Paul Green. + + ChangeLog@1.1666.1.9 +1 -0 + [Bug 2857] Stratus VOS does not support SIGIO. Paul Green. + + configure.ac@1.596.1.1 +9 -0 + [Bug 2857] Stratus VOS does not support SIGIO. Paul Green. + + sntp/m4/ntp_libntp.m4@1.30 +9 -0 + [Bug 2857] Stratus VOS does not support SIGIO. Paul Green. + +ChangeSet@1.3473.3.9, 2015-06-27 01:58:07-04:00, stenn@deacon.udel.edu + [Bug 2856] ntpd should wait() on terminated child processes. Paul Green. + + ChangeLog@1.1666.1.8 +1 -0 + [Bug 2856] ntpd should wait() on terminated child processes. Paul Green. + + libntp/work_fork.c@1.14 +23 -4 + [Bug 2856] ntpd should wait() on terminated child processes. Paul Green. + +ChangeSet@1.3473.3.8, 2015-06-27 05:12:21+00:00, stenn@psp-at1.ntp.org + [Bug 2855] Report leap smear in the REFID. Harlan Stenn. + + ChangeLog@1.1666.1.7 +1 -0 + [Bug 2855] Report leap smear in the REFID. Harlan Stenn. + + ntpd/ntp_proto.c@1.361 +8 -2 + [Bug 2855] Report leap smear in the REFID. Harlan Stenn. + +ChangeSet@1.3473.3.7, 2015-06-27 04:53:42+00:00, stenn@psp-at1.ntp.org + refidsmear test cleanup. Tomasz Flendrich. + + ChangeLog@1.1666.1.6 +1 -0 + refidsmear test cleanup. Tomasz Flendrich. + + tests/libntp/refidsmear.c@1.4 +4 -5 + refidsmear test cleanup. Tomasz Flendrich. + +ChangeSet@1.3473.3.6, 2015-06-27 06:44:17+02:00, tomek@tomek-n56vz.(none) + refidsmear.c: + moved assertions to proper places + + tests/libntp/refidsmear.c@1.3 +4 -2 + moved assertions to proper places + +ChangeSet@1.3473.3.5, 2015-06-27 04:46:21+02:00, tomek@tomek-n56vz.(none) + run-refidsmear.c: + updated autogenerated file + refidsmear.c: + added the assertions and a nice message if a test fails + + tests/libntp/refidsmear.c@1.2 +22 -9 + added the assertions and a nice message if a test fails + + tests/libntp/run-refidsmear.c@1.2 +1 -1 + updated autogenerated file + +ChangeSet@1.3473.3.4, 2015-06-27 01:16:47+00:00, stenn@psp-at1.ntp.org + refidsmear function support and tests. Harlan Stenn. + + ChangeLog@1.1666.1.5 +1 -0 + refidsmear function support and tests. Harlan Stenn. + + include/Makefile.am@1.51 +1 -0 + refidsmear function support and tests. Harlan Stenn. + + include/refidsmear.h@1.1 +3 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/include/refidsmear.h + + include/refidsmear.h@1.0 +0 -0 + + libntp/Makefile.am@1.76 +1 -0 + refidsmear function support and tests. Harlan Stenn. + + libntp/refidsmear.c@1.1 +58 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/libntp/refidsmear.c + + libntp/refidsmear.c@1.0 +0 -0 + + tests/libntp/Makefile.am@1.83 +439 -378 + refidsmear function support and tests. Harlan Stenn. + + tests/libntp/refidsmear.c@1.1 +127 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/libntp/refidsmear.c + + tests/libntp/refidsmear.c@1.0 +0 -0 + + tests/libntp/run-refidsmear.c@1.1 +52 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/libntp/run-refidsmear.c + + tests/libntp/run-refidsmear.c@1.0 +0 -0 + +ChangeSet@1.3473.3.3, 2015-06-26 22:45:16+00:00, stenn@psp-at1.ntp.org + tests/sandbox/smeartest.c: Harlan Stenn, Damir Tomic, Juergen Perlinger. + + ChangeLog@1.1666.1.4 +1 -0 + tests/sandbox/smeartest.c: Harlan Stenn, Damir Tomic, Juergen Perlinger. + +ChangeSet@1.3473.3.2, 2015-06-26 20:10:51+00:00, stenn@psp-at1.ntp.org + smeartest.c fixes from Harlan + + tests/sandbox/smeartest.c@1.3.1.2 +52 -1 + smeartest.c fixes from Harlan + +ChangeSet@1.3473.3.1, 2015-06-26 18:43:39+00:00, stenn@psp-at1.ntp.org + smeartest.c fixes from Juergen, Damir, and Harlan + + tests/sandbox/smeartest.c@1.3.1.1 +26 -17 + smeartest.c fixes from Juergen, Damir, and Harlan + +ChangeSet@1.3473.1.18, 2015-06-26 15:17:10+02:00, viperus@ubuntu.(none) + smeartest.c: + maybed fixed both funtions, needs checking!!! + + tests/sandbox/smeartest.c@1.4 +69 -26 + maybed fixed both funtions, needs checking!!! + +ChangeSet@1.3473.1.17, 2015-06-26 11:24:43+00:00, stenn@psp-at1.ntp.org + smeartest.c - Harlan Stenn + + tests/sandbox/smeartest.c@1.3 +2 -2 + smeartest.c - Harlan Stenn + +ChangeSet@1.3473.1.16, 2015-06-26 11:20:59+00:00, stenn@psp-at1.ntp.org + smeartest.c - Harlan Stenn + + tests/sandbox/smeartest.c@1.2 +4 -0 + smeartest.c - Harlan Stenn + +ChangeSet@1.3473.1.15, 2015-06-26 10:58:41+00:00, stenn@psp-at1.ntp.org + smeartest.c - Harlan Stenn + + tests/sandbox/Makefile.am@1.4 +1 -1 + smeartest.c - Harlan Stenn + + tests/sandbox/smeartest.c@1.1 +104 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/smeartest.c + + tests/sandbox/smeartest.c@1.0 +0 -0 + +ChangeSet@1.3473.1.14, 2015-06-25 18:22:10+00:00, stenn@psp-at1.ntp.org + sntp/tests/Makefile.am: remove g_nameresolution.cpp as it tested something that was only in the 4.2.6 sntp. Harlan Stenn. + + ChangeLog@1.1666.1.3 +18 -8 + sntp/tests/Makefile.am: remove g_nameresolution.cpp as it tested something that was only in the 4.2.6 sntp. Harlan Stenn. + + sntp/tests/Makefile.am@1.55 +4 -2 + sntp/tests/Makefile.am: remove g_nameresolution.cpp as it tested something that was only in the 4.2.6 sntp. Harlan Stenn. + +ChangeSet@1.3473.1.13, 2015-06-25 16:34:19+02:00, viperus@ubuntu.(none) + packetProcessing.c: + fixed SetUp() -> setUp() and TearDown() -> tearDown() which seemed to work because of extern functions + + sntp/tests/packetProcessing.c@1.4 +11 -11 + fixed SetUp() -> setUp() and TearDown() -> tearDown() which seemed to work because of extern functions + + sntp/tests/run-packetProcessing.c@1.3 +6 -6 + +ChangeSet@1.3473.1.12, 2015-06-25 16:08:41+02:00, viperus@ubuntu.(none) + packetHandling.c: + put init_lib() every time. Unlike init_auth(), works every time in setUp() without causing segfault + added init_lib() in setUp(), so now stuff works! + + sntp/tests/packetHandling.c@1.3 +2 -2 + put init_lib() every time. Unlike init_auth(), works every time in setUp() without causing segfault + + sntp/tests/packetHandling.c@1.2 +19 -5 + added init_lib() in setUp(), so now stuff works! + + sntp/tests/run-packetHandling.c@1.2 +10 -10 + +ChangeSet@1.3473.1.11, 2015-06-25 14:21:11+02:00, viperus@ubuntu.(none) + sntptest.h: + added sntptest_destroy() + packetProcessing.c: + added a bunch of snptest_destroy() + + sntp/tests/packetProcessing.c@1.3 +14 -6 + added a bunch of snptest_destroy() + + sntp/tests/run-packetProcessing.c@1.2 +18 -18 + + sntp/tests/sntptest.h@1.3 +4 -5 + added sntptest_destroy() + +ChangeSet@1.3473.1.10, 2015-06-25 12:16:34+02:00, viperus@ubuntu.(none) + nameresolution.cpp~a54f29b6c06a0baf: + Delete: sntp/tests/nameresolution.cpp + + BitKeeper/deleted/a0/nameresolution.cpp~a54f29b6c06a0baf@1.3 +0 -0 + Delete: sntp/tests/nameresolution.cpp + +ChangeSet@1.3473.1.9, 2015-06-25 12:15:27+02:00, viperus@ubuntu.(none) + run-packetProcessing.c: + new file + packetHandling.cpp~39b5af94c298eb8c: + Delete: sntp/tests/packetHandling.cpp + Makefile.am: + merged lokesh and tomasz work + + BitKeeper/deleted/f3/packetHandling.cpp~39b5af94c298eb8c@1.12 +0 -0 + Delete: sntp/tests/packetHandling.cpp + + sntp/tests/Makefile.am@1.54 +6 -6 + merged lokesh and tomasz work + + sntp/tests/run-packetProcessing.c@1.1 +86 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-packetProcessing.c + + sntp/tests/run-packetProcessing.c@1.0 +0 -0 + +ChangeSet@1.3473.1.7, 2015-06-25 11:39:39+02:00, tomek@tomek-n56vz.(none) + Makefile.am: + added pocketProcessing.c + + sntp/tests/Makefile.am@1.52 +33 -15 + added pocketProcessing.c + +ChangeSet@1.3473.2.1, 2015-06-25 11:32:47+02:00, tomek@tomek-n56vz.(none) + packetProcessing.c: + new file + g_packetProcessing.cpp: + Rename: sntp/tests/packetProcessing.cpp -> sntp/tests/g_packetProcessing.cpp + packetProcessing.c: + fixed array size, so that it doesn't crash on 64bit integer + + sntp/tests/g_packetProcessing.cpp@1.7 +0 -0 + Rename: sntp/tests/packetProcessing.cpp -> sntp/tests/g_packetProcessing.cpp + + sntp/tests/packetProcessing.c@1.2 +1 -1 + fixed array size, so that it doesn't crash on 64bit integer + + sntp/tests/packetProcessing.c@1.1 +331 -0 + BitKeeper file /home/tomek/ntp/packetProcessing/ntp-stable-unity/sntp/tests/packetProcessing.c + + sntp/tests/packetProcessing.c@1.0 +0 -0 + +ChangeSet@1.3473.1.5, 2015-06-25 10:10:48+02:00, viperus@ubuntu.(none) + lfpfunc.c: + replaced TEST_ASSERT_EQUAL_MEMORY(&a,&b,sizeof(a)) with TEST_ASSERT_EQUAL_l_fp(a,b). It's safer this way, because structs can be compared even if they aren't initiated with memset (due to padding bytes) + + tests/libntp/lfpfunc.c@1.7 +25 -8 + replaced TEST_ASSERT_EQUAL_MEMORY(&a,&b,sizeof(a)) with TEST_ASSERT_EQUAL_l_fp(a,b). It's safer this way, because structs can be compared even if they aren't initiated with memset (due to padding bytes) + + tests/libntp/run-lfpfunc.c@1.10 +10 -9 + +ChangeSet@1.3473.1.4, 2015-06-25 09:38:11+02:00, viperus@ubuntu.(none) + ChangeLog: + added my changes + + ChangeLog@1.1666.1.2 +8 -0 + added my changes + +ChangeSet@1.3458.2.1, 2015-06-25 07:21:48+00:00, viperus@psp-fb1.ntp.org + g_crypto.cpp: + Rename: sntp/tests/crypto.cpp -> sntp/tests/g_crypto.cpp + g_crypto.cpp~cb769256579f1186: + Delete: sntp/tests/g_crypto.cpp + + BitKeeper/deleted/aa/g_crypto.cpp~cb769256579f1186@1.2, stenn@psp-at1.ntp.org +0 -0 + Delete: sntp/tests/g_crypto.cpp + + sntp/tests/g_crypto.cpp@1.6, stenn@psp-at1.ntp.org +0 -0 + Rename: sntp/tests/crypto.cpp -> sntp/tests/g_crypto.cpp + +ChangeSet@1.3473.1.2, 2015-06-25 09:19:32+02:00, viperus@ubuntu.(none) + Makefile.am: + minor fix for buildin libunity.a + minor fix for building libunity.a + crypto.c~1ed7d1829a6a73e5: + Delete: sntp/tests/crypto.c + crypto.c: + Rename: BitKeeper/deleted/23/crypto.c~1ed7d1829a6a73e5 -> sntp/tests/crypto.c + bug-2803.c: + function now returns x instead of 0 + + sntp/tests/crypto.c@1.5 +0 -0 + Rename: BitKeeper/deleted/23/crypto.c~1ed7d1829a6a73e5 -> sntp/tests/crypto.c + + BitKeeper/deleted/23/crypto.c~1ed7d1829a6a73e5@1.4 +0 -0 + Delete: sntp/tests/crypto.c + + tests/bug-2803/Makefile.am@1.12 +1 -1 + minor fix for building libunity.a + + tests/bug-2803/bug-2803.c@1.9 +7 -7 + function now returns x instead of 0 + + tests/libntp/Makefile.am@1.82 +1 -1 + minor fix for buildin libunity.a + + tests/libntp/run-sfptostr.c@1.2 +1 -0 + +ChangeSet@1.3479, 2015-06-25 04:26:18+00:00, stenn@psp-at1.ntp.org + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + tests/sec-2853/sec-2853.c@1.4 +4 -6 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + +ChangeSet@1.3473.1.1, 2015-06-25 04:10:56+00:00, stenn@psp-at1.ntp.org + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + + ChangeLog@1.1666.1.1 +3 -0 + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + + ntpd/keyword-gen-utd@1.26 +1 -1 + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + + ntpd/keyword-gen.c@1.32 +0 -2 + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + + ntpd/ntp_keyword.h@1.28 +446 -433 + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + + ntpd/ntp_parser.c@1.97 +1397 -1147 + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + + ntpd/ntp_parser.h@1.62 +230 -216 + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + + ntpd/ntp_parser.y@1.87 +5 -0 + [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. + +ChangeSet@1.3478, 2015-06-25 02:48:14+00:00, stenn@psp-at1.ntp.org + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + tests/sec-2853/run-sec-2853.c@1.2 +2 -2 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + tests/sec-2853/sec-2853.c@1.3 +0 -2 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + +ChangeSet@1.3477, 2015-06-25 02:43:46+00:00, stenn@psp-at1.ntp.org + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + tests/sec-2853/sec-2853.c@1.2 +58 -2 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + +ChangeSet@1.3476, 2015-06-25 02:29:11+00:00, stenn@psp-at1.ntp.org + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + ChangeLog@1.1670 +1 -0 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + ntpd/Makefile.am@1.133 +1 -0 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + ntpd/ntp_control.c@1.200 +2 -29 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + ntpd/rc_cmdlength.c@1.1 +35 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2853/ntpd/rc_cmdlength.c + + ntpd/rc_cmdlength.c@1.0 +0 -0 + + tests/sec-2853/Makefile.am@1.2 +9 -3 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + + tests/sec-2853/Makefile.in@1.2 +513 -161 + [Sec 2853] Initial work on tests/sec-2853/. Harlan Stenn. + +ChangeSet@1.3475, 2015-06-24 10:59:01-07:00, harlan@hms-mbp11.pfcs.com + [Sec 2853] FICORA #829967. Juergen Perlinger, Harlan Stenn. + + ChangeLog@1.1669 +1 -1 + [Sec 2853] FICORA #829967. Juergen Perlinger, Harlan Stenn. + + ChangeLog@1.1668 +3 -1 + merge cleanup + + configure.ac@1.597 +1 -0 + [Sec 2853] FICORA #829967. Juergen Perlinger, Harlan Stenn. + + tests/Makefile.am@1.10 +2 -0 + [Sec 2853] FICORA #829967. Juergen Perlinger, Harlan Stenn. + + tests/sec-2853/Makefile.am@1.1 +72 -0 + BitKeeper file /Users/harlan/src/ntp-stable-2853/tests/sec-2853/Makefile.am + + tests/sec-2853/Makefile.am@1.0 +0 -0 + + tests/sec-2853/Makefile.in@1.1 +918 -0 + BitKeeper file /Users/harlan/src/ntp-stable-2853/tests/sec-2853/Makefile.in + + tests/sec-2853/Makefile.in@1.0 +0 -0 + + tests/sec-2853/run-sec-2853.c@1.1 +54 -0 + BitKeeper file /Users/harlan/src/ntp-stable-2853/tests/sec-2853/run-sec-2853.c + + tests/sec-2853/run-sec-2853.c@1.0 +0 -0 + + tests/sec-2853/sec-2853.c@1.1 +68 -0 + BitKeeper file /Users/harlan/src/ntp-stable-2853/tests/sec-2853/sec-2853.c + + tests/sec-2853/sec-2853.c@1.0 +0 -0 + +ChangeSet@1.3473, 2015-06-24 11:06:56-04:00, stenn@deacon.udel.edu + NTP_4_2_8P3_RC2 + TAG: NTP_4_2_8P3_RC2 + + ChangeLog@1.1666 +1 -0 + NTP_4_2_8P3_RC2 + + ntpd/invoke-ntp.conf.texi@1.185 +1 -1 + NTP_4_2_8P3_RC2 + + ntpd/invoke-ntp.keys.texi@1.180 +1 -1 + NTP_4_2_8P3_RC2 + + ntpd/invoke-ntpd.texi@1.497 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntp.conf.5man@1.219 +76 -76 + NTP_4_2_8P3_RC2 + + ntpd/ntp.conf.5mdoc@1.219 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntp.conf.html@1.175 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntp.conf.man.in@1.219 +76 -76 + NTP_4_2_8P3_RC2 + + ntpd/ntp.conf.mdoc.in@1.219 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntp.keys.5man@1.214 +11 -11 + NTP_4_2_8P3_RC2 + + ntpd/ntp.keys.5mdoc@1.214 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntp.keys.html@1.176 +1 -1 + NTP_4_2_8P3_RC2 + + ntpd/ntp.keys.man.in@1.214 +11 -11 + NTP_4_2_8P3_RC2 + + ntpd/ntp.keys.mdoc.in@1.214 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntpd-opts.c@1.519 +7 -7 + NTP_4_2_8P3_RC2 + + ntpd/ntpd-opts.h@1.518 +3 -3 + NTP_4_2_8P3_RC2 + + ntpd/ntpd.1ntpdman@1.326 +30 -30 + NTP_4_2_8P3_RC2 + + ntpd/ntpd.1ntpdmdoc@1.326 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntpd.html@1.170 +2 -2 + NTP_4_2_8P3_RC2 + + ntpd/ntpd.man.in@1.326 +30 -30 + NTP_4_2_8P3_RC2 + + ntpd/ntpd.mdoc.in@1.326 +2 -2 + NTP_4_2_8P3_RC2 + + ntpdc/invoke-ntpdc.texi@1.494 +2 -2 + NTP_4_2_8P3_RC2 + + ntpdc/ntpdc-opts.c@1.512 +7 -7 + NTP_4_2_8P3_RC2 + + ntpdc/ntpdc-opts.h@1.511 +3 -3 + NTP_4_2_8P3_RC2 + + ntpdc/ntpdc.1ntpdcman@1.325 +16 -16 + NTP_4_2_8P3_RC2 + + ntpdc/ntpdc.1ntpdcmdoc@1.325 +2 -2 + NTP_4_2_8P3_RC2 + + ntpdc/ntpdc.html@1.338 +2 -2 + NTP_4_2_8P3_RC2 + + ntpdc/ntpdc.man.in@1.325 +16 -16 + NTP_4_2_8P3_RC2 + + ntpdc/ntpdc.mdoc.in@1.325 +2 -2 + NTP_4_2_8P3_RC2 + + ntpq/invoke-ntpq.texi@1.501 +2 -2 + NTP_4_2_8P3_RC2 + + ntpq/ntpq-opts.c@1.518 +7 -7 + NTP_4_2_8P3_RC2 + + ntpq/ntpq-opts.h@1.516 +3 -3 + NTP_4_2_8P3_RC2 + + ntpq/ntpq.1ntpqman@1.329 +3 -3 + NTP_4_2_8P3_RC2 + + ntpq/ntpq.1ntpqmdoc@1.329 +2 -2 + NTP_4_2_8P3_RC2 + + ntpq/ntpq.html@1.167 +14 -4 + NTP_4_2_8P3_RC2 + + ntpq/ntpq.man.in@1.329 +3 -3 + NTP_4_2_8P3_RC2 + + ntpq/ntpq.mdoc.in@1.329 +2 -2 + NTP_4_2_8P3_RC2 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.496 +2 -2 + NTP_4_2_8P3_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.514 +7 -7 + NTP_4_2_8P3_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.513 +3 -3 + NTP_4_2_8P3_RC2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.325 +5 -5 + NTP_4_2_8P3_RC2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.325 +2 -2 + NTP_4_2_8P3_RC2 + + ntpsnmpd/ntpsnmpd.html@1.165 +1 -1 + NTP_4_2_8P3_RC2 + + ntpsnmpd/ntpsnmpd.man.in@1.325 +5 -5 + NTP_4_2_8P3_RC2 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.325 +2 -2 + NTP_4_2_8P3_RC2 + + packageinfo.sh@1.512 +1 -1 + NTP_4_2_8P3_RC2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.86 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.87 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/calc_tickadj/calc_tickadj.html@1.88 +1 -1 + NTP_4_2_8P3_RC2 + + scripts/calc_tickadj/calc_tickadj.man.in@1.85 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.87 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.90 +1 -1 + NTP_4_2_8P3_RC2 + + scripts/invoke-plot_summary.texi@1.107 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/invoke-summary.texi@1.107 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.317 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntp-wait/ntp-wait-opts@1.53 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.314 +5 -5 + NTP_4_2_8P3_RC2 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.315 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntp-wait/ntp-wait.html@1.334 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntp-wait/ntp-wait.man.in@1.314 +5 -5 + NTP_4_2_8P3_RC2 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.315 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.105 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntpsweep/ntpsweep-opts@1.55 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.93 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.93 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntpsweep/ntpsweep.html@1.106 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntpsweep/ntpsweep.man.in@1.93 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.94 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntptrace/invoke-ntptrace.texi@1.106 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntptrace/ntptrace-opts@1.55 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntptrace/ntptrace.1ntptraceman@1.93 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.94 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntptrace/ntptrace.html@1.107 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/ntptrace/ntptrace.man.in@1.93 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/ntptrace/ntptrace.mdoc.in@1.95 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/plot_summary-opts@1.55 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/plot_summary.1plot_summaryman@1.105 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/plot_summary.1plot_summarymdoc@1.105 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/plot_summary.html@1.108 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/plot_summary.man.in@1.105 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/plot_summary.mdoc.in@1.105 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/summary-opts@1.55 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/summary.1summaryman@1.105 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/summary.1summarymdoc@1.105 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/summary.html@1.108 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/summary.man.in@1.105 +3 -3 + NTP_4_2_8P3_RC2 + + scripts/summary.mdoc.in@1.105 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/update-leap/invoke-update-leap.texi@1.6 +51 -2 + NTP_4_2_8P3_RC2 + + scripts/update-leap/update-leap-opts@1.6 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/update-leap/update-leap.1update-leapman@1.6 +4 -4 + NTP_4_2_8P3_RC2 + + scripts/update-leap/update-leap.1update-leapmdoc@1.6 +2 -2 + NTP_4_2_8P3_RC2 + + scripts/update-leap/update-leap.html@1.6 +1 -1 + NTP_4_2_8P3_RC2 + + scripts/update-leap/update-leap.man.in@1.6 +4 -4 + NTP_4_2_8P3_RC2 + + scripts/update-leap/update-leap.mdoc.in@1.6 +2 -2 + NTP_4_2_8P3_RC2 + + sntp/invoke-sntp.texi@1.494 +2 -2 + NTP_4_2_8P3_RC2 + + sntp/sntp-opts.c@1.513 +7 -7 + NTP_4_2_8P3_RC2 + + sntp/sntp-opts.h@1.511 +3 -3 + NTP_4_2_8P3_RC2 + + sntp/sntp.1sntpman@1.329 +7 -7 + NTP_4_2_8P3_RC2 + + sntp/sntp.1sntpmdoc@1.329 +2 -2 + NTP_4_2_8P3_RC2 + + sntp/sntp.html@1.509 +2 -2 + NTP_4_2_8P3_RC2 + + sntp/sntp.man.in@1.329 +7 -7 + NTP_4_2_8P3_RC2 + + sntp/sntp.mdoc.in@1.329 +2 -2 + NTP_4_2_8P3_RC2 + + util/invoke-ntp-keygen.texi@1.497 +2 -2 + NTP_4_2_8P3_RC2 + + util/ntp-keygen-opts.c@1.515 +7 -7 + NTP_4_2_8P3_RC2 + + util/ntp-keygen-opts.h@1.513 +3 -3 + NTP_4_2_8P3_RC2 + + util/ntp-keygen.1ntp-keygenman@1.325 +18 -18 + NTP_4_2_8P3_RC2 + + util/ntp-keygen.1ntp-keygenmdoc@1.325 +2 -2 + NTP_4_2_8P3_RC2 + + util/ntp-keygen.html@1.171 +2 -2 + NTP_4_2_8P3_RC2 + + util/ntp-keygen.man.in@1.325 +18 -18 + NTP_4_2_8P3_RC2 + + util/ntp-keygen.mdoc.in@1.325 +2 -2 + NTP_4_2_8P3_RC2 + +ChangeSet@1.3472, 2015-06-24 10:25:48-04:00, stenn@deacon.udel.edu + automake-1.15 cleanup for sntp/tests/fileHandlingTest.h.in . Harlan Stenn. + + ChangeLog@1.1665 +1 -0 + automake-1.15 cleanup for sntp/tests/fileHandlingTest.h.in . Harlan Stenn. + + sntp/tests/fileHandlingTest.h.in@1.11 +3 -3 + automake-1.15 cleanup for sntp/tests/fileHandlingTest.h.in . Harlan Stenn. + +ChangeSet@1.3471, 2015-06-24 10:22:13-04:00, stenn@deacon.udel.edu + [Bug 2855] leap smear cleanup. Harlan Stenn. + + ChangeLog@1.1664 +1 -0 + [Bug 2855] leap smear cleanup. Harlan Stenn. + + ntpd/complete.conf.in@1.30 +1 -1 + [Bug 2855] leap smear cleanup. Harlan Stenn. + + ntpd/keyword-gen-utd@1.25 +1 -1 + [Bug 2855] leap smear cleanup. Harlan Stenn. + + ntpd/ntp_keyword.h@1.27 +433 -446 + [Bug 2855] leap smear cleanup. Harlan Stenn. + + ntpd/ntp_parser.c@1.96 +147 -147 + [Bug 2855] leap smear cleanup. Harlan Stenn. + + ntpd/ntp_parser.h@1.61 +4 -4 + [Bug 2855] leap smear cleanup. Harlan Stenn. + + ntpd/ntp_proto.c@1.360 +1 -1 + [Bug 2855] leap smear cleanup. Harlan Stenn. + +ChangeSet@1.3470, 2015-06-24 10:17:03-04:00, stenn@deacon.udel.edu + Cleanup for ntp-4.2.3p8-RC2 + + ChangeLog@1.1663 +1 -1 + Cleanup for ntp-4.2.3p8-RC2 + + NEWS@1.139 +35 -1 + Cleanup for ntp-4.2.3p8-RC2 + + configure.ac@1.596 +3 -1 + Cleanup for ntp-4.2.3p8-RC2 + +ChangeSet@1.3469, 2015-06-24 11:25:11+00:00, stenn@psp-at1.ntp.org + [Bug 2855] Implement conditional leap smear code. Martin Burnicki. + + ChangeLog@1.1662 +1 -1 + [Bug 2855] Implement conditional leap smear code. Martin Burnicki. + +ChangeSet@1.3466.1.1, 2015-06-24 09:18:52+02:00, jnperlin@hydra.(none) + Bug 2853 - FICORA #829967 + + ChangeLog@1.1660.1.1 +1 -0 + Bug 2853 - FICORA #829967 + + ntpd/ntp_control.c@1.196.1.1 +56 -21 + Bug 2853 - FICORA #829967 + +ChangeSet@1.3458.1.3, 2015-06-23 12:56:23+05:30, loki@dadasgift.(none) + PacketHandling test changes + + sntp/tests/Makefile.am@1.50.1.3 +11 -11 + + sntp/tests/g_packetHandling.cpp@1.1 +264 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/g_packetHandling.cpp + + sntp/tests/g_packetHandling.cpp@1.0 +0 -0 + + sntp/tests/packetHandling.c@1.1 +260 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/packetHandling.c + + sntp/tests/packetHandling.c@1.0 +0 -0 + + sntp/tests/run-packetHandling.c@1.1 +70 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/run-packetHandling.c + + sntp/tests/run-packetHandling.c@1.0 +0 -0 + +ChangeSet@1.3468, 2015-06-22 17:31:28+02:00, martin@pc-martin.(none) + [Bug 2855] Implement conditional leap smear feature. + + ChangeLog@1.1661 +1 -0 + [Bug 2855] Implement conditional leap smear feature. + + include/ntpd.h@1.191 +3 -0 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + + ntpd/keyword-gen.c@1.31 +2 -0 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + + ntpd/ntp_config.c@1.330 +2 -0 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + + ntpd/ntp_control.c@1.198 +4 -0 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + + ntpd/ntp_io.c@1.403 +8 -1 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + + ntpd/ntp_leapsec.h@1.14 +5 -0 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + + ntpd/ntp_proto.c@1.359 +30 -2 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + + ntpd/ntp_timer.c@1.91 +21 -12 + Protected leap smearing code by preprocessor symbol LEAP_SMEAR. + +ChangeSet@1.3466, 2015-06-22 07:45:39+00:00, stenn@psp-at1.ntp.org + Initial support for experimental leap smear code. Harlan Stenn. + + ChangeLog@1.1660 +1 -0 + Initial support for experimental leap smear code. Harlan Stenn. + + configure.ac@1.595 +21 -0 + Initial support for experimental leap smear code. Harlan Stenn. + +ChangeSet@1.3458.1.2, 2015-06-22 13:06:53+05:30, loki@dadasgift.(none) + Nameresolution test + + sntp/tests/Makefile.am@1.50.1.2 +20 -0 + + sntp/tests/g_nameresolution.cpp@1.1 +171 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/g_nameresolution.cpp + + sntp/tests/g_nameresolution.cpp@1.0 +0 -0 + + sntp/tests/nameresolution.c@1.1 +162 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/nameresolution.c + + sntp/tests/nameresolution.c@1.0 +0 -0 + + sntp/tests/run-nameresolution.c@1.1 +51 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/run-nameresolution.c + + sntp/tests/run-nameresolution.c@1.0 +0 -0 + +ChangeSet@1.3453.1.3, 2015-06-22 12:56:31+05:30, loki@dadasgift.(none) + Makefile changes + + sntp/tests/Makefile.am@1.48.1.1 +20 -0 + +ChangeSet@1.3465, 2015-06-22 06:50:39+00:00, stenn@psp-at1.ntp.org + Regenerate some unity test runners to declare resetTest() + + tests/libntp/run-caljulian.c@1.8 +1 -0 + Regenerate some unity test runners to declare resetTest() + + tests/libntp/run-decodenetnum.c@1.3 +1 -0 + Regenerate some unity test runners to declare resetTest() + + tests/libntp/run-hextolfp.c@1.4 +1 -0 + Regenerate some unity test runners to declare resetTest() + + tests/libntp/run-netof.c@1.3 +1 -0 + Regenerate some unity test runners to declare resetTest() + + tests/libntp/run-vi64ops.c@1.3 +1 -0 + Regenerate some unity test runners to declare resetTest() + +ChangeSet@1.3464, 2015-06-21 05:15:32+00:00, stenn@psp-at1.ntp.org + Fixes to sntp/tests/fileHandlingTest.h.in. Harlan Stenn. + + ChangeLog@1.1659 +1 -0 + Fixes to sntp/tests/fileHandlingTest.h.in. Harlan Stenn. + + sntp/configure.ac@1.81 +1 -0 + Fixes to sntp/tests/fileHandlingTest.h.in. Harlan Stenn. + + sntp/tests/fileHandlingTest.h.in@1.10 +3 -11 + Fixes to sntp/tests/fileHandlingTest.h.in. Harlan Stenn. + + sntp/tests/fileHandlingTest.h.in@1.9, stenn@psp-fb1.ntp.org +0 -0 + Rename: sntp/tests/fileHandlingTest.h -> sntp/tests/fileHandlingTest.h.in + +ChangeSet@1.3463, 2015-06-20 23:18:33+00:00, stenn@psp-at1.ntp.org + [Bug 2852] 'make check' can't find unity.h. Hal Murray. + + ChangeLog@1.1658 +1 -0 + [Bug 2852] 'make check' can't find unity.h. Hal Murray. + +ChangeSet@1.3462, 2015-06-20 23:12:10+00:00, stenn@psp-at1.ntp.org + [Bug 2854] Missing brace in libntp/strdup.c. Masanari Iida. + + ChangeLog@1.1657 +1 -0 + [Bug 2854] Missing brace in libntp/strdup.c. Masanari Iida. + + libntp/strdup.c@1.9 +9 -10 + [Bug 2854] Missing brace in libntp/strdup.c. Masanari Iida. + +ChangeSet@1.3461, 2015-06-20 22:41:34+00:00, stenn@psp-at1.ntp.org + gtest->Unity cleanup + + sntp/tests/Makefile.am@1.51 +10 -6 + gtest->Unity cleanup + + sntp/tests_main.cpp@1.9 +4 -0 + gtest->Unity cleanup + + tests/libntp/g_buftvtots.cpp@1.5 +1 -1 + gtest->Unity cleanup + + tests/libntp/g_decodenetnum.cpp@1.2 +1 -1 + gtest->Unity cleanup + + tests/libntp/g_hextolfp.cpp@1.2 +1 -1 + gtest->Unity cleanup + + tests/libntp/g_netof.cpp@1.2 +1 -1 + gtest->Unity cleanup + + tests/libntp/g_socktoa.cpp@1.2 +1 -1 + gtest->Unity cleanup + + tests/libntp/g_strtolfp.cpp@1.2 +1 -1 + gtest->Unity cleanup + + tests/libntp/g_tvtots.cpp@1.8 +1 -1 + gtest->Unity cleanup + +ChangeSet@1.3460, 2015-06-20 21:41:29+00:00, stenn@psp-at1.ntp.org + re-apply lost typo fix + + sntp/tests/g_crypto.cpp@1.1.1.1 +1 -1 + re-apply lost typo fix + +ChangeSet@1.3458, 2015-06-20 14:32:03+02:00, viperus@ubuntu.(none) + run-crypto.c: + new file + Makefile.am: + minor rearrange + crypto.c: + minor fix with #define, now works even without openSSL + + sntp/tests/Makefile.am@1.50 +16 -18 + minor rearrange + + sntp/tests/crypto.c@1.3 +11 -4 + minor fix with #define, now works even without openSSL + + sntp/tests/run-crypto.c@1.1 +62 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-crypto.c + + sntp/tests/run-crypto.c@1.0 +0 -0 + +ChangeSet@1.3456, 2015-06-20 14:14:57+02:00, viperus@ubuntu.(none) + Makefile.am: + added a few more test files to cleanfiles + g_utilities.cpp: + Rename: sntp/tests/utilities.cpp -> sntp/tests/g_utilities.cpp + bug-2803.h~e9cdd024b7db50f6: + Delete: tests/bug-2803/bug-2803.h + Many files: + new file + Makefile.am: + added utilities test, fixed a minor bug with CLEANFILES var + generate_test_runner.rb: + for now, I'm giving up on removing functions that are written twice (because of declaraion and defintion). That regex is difficult because ruby script splits with newline, ; and { and }. I just added declaration for resetTest, to avoid warnings + + BitKeeper/deleted/4b/bug-2803.h~e9cdd024b7db50f6@1.2 +0 -0 + Delete: tests/bug-2803/bug-2803.h + + sntp/tests/Makefile.am@1.46.1.2 +1 -1 + added a few more test files to cleanfiles + + sntp/tests/Makefile.am@1.46.1.1 +50 -32 + added utilities test, fixed a minor bug with CLEANFILES var + + sntp/tests/data/debug-output-lfp-bin@1.1 +3 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/data/debug-output-lfp-bin + + sntp/tests/data/debug-output-lfp-bin@1.0 +0 -0 + + sntp/tests/data/debug-output-lfp-dec@1.1 +3 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/data/debug-output-lfp-dec + + sntp/tests/data/debug-output-lfp-dec@1.0 +0 -0 + + sntp/tests/data/debug-output-pkt@1.1 +8 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/data/debug-output-pkt + + sntp/tests/data/debug-output-pkt@1.0 +0 -0 + + sntp/tests/g_utilities.cpp@1.11 +0 -0 + Rename: sntp/tests/utilities.cpp -> sntp/tests/g_utilities.cpp + + sntp/tests/run-utilities.c@1.1 +64 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-utilities.c + + sntp/tests/run-utilities.c@1.0 +0 -0 + + sntp/tests/utilities.c@1.1 +177 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/utilities.c + + sntp/tests/utilities.c@1.0 +0 -0 + + sntp/unity/auto/generate_test_runner.rb@1.5.1.1 +1 -0 + for now, I'm giving up on removing functions that are written twice (because of declaraion and defintion). That regex is difficult because ruby script splits with newline, ; and { and }. I just added declaration for resetTest, to avoid warnings + + tests/bug-2803/bug-2803.c@1.8 +1 -1 + + tests/bug-2803/bug-2803.c@1.7 +4 -1 + + tests/bug-2803/run-bug-2803.c@1.7 +3 -2 + +ChangeSet@1.3453.1.2, 2015-06-20 16:11:49+05:30, loki@dadasgift.(none) + Crypto test file + + sntp/tests/Makefile.am@1.48 +19 -1 + + sntp/tests/crypto.c@1.2 +1 -1 + +ChangeSet@1.3452.1.1, 2015-06-20 09:07:37+00:00, stenn@psp-at1.ntp.org + typo + + sntp/unity/auto/colour_prompt.rb@1.2 +0 -0 + Change mode to -rw-rw-r-- + + sntp/unity/auto/colour_reporter.rb@1.2 +0 -0 + Change mode to -rw-rw-r-- + + sntp/unity/auto/generate_config.yml@1.2 +0 -0 + Change mode to -rw-rw-r-- + + sntp/unity/auto/generate_module.rb@1.2 +0 -0 + Change mode to -rw-rw-r-- + + sntp/unity/auto/generate_test_runner.rb@1.6 +0 -0 + Change mode to -rw-rw-r-- + + sntp/unity/auto/test_file_filter.rb@1.2 +0 -0 + Change mode to -rw-rw-r-- + + sntp/unity/auto/unity_test_summary.rb@1.2 +0 -0 + Change mode to -rw-rw-r-- + + tests/libntp/sfptostr.c@1.2 +1 -1 + typo + +ChangeSet@1.3455, 2015-06-20 10:10:34+02:00, viperus@ubuntu.(none) + bug-2803.h: + new file + bug-2803.c: + removed declarations, and put them into bug-2803.h + + tests/bug-2803/bug-2803.c@1.6 +1 -4 + removed declarations, and put them into bug-2803.h + + tests/bug-2803/bug-2803.h@1.1 +14 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/bug-2803/bug-2803.h + + tests/bug-2803/bug-2803.h@1.0 +0 -0 + + tests/bug-2803/run-bug-2803.c@1.6 +1 -3 + +ChangeSet@1.3454, 2015-06-20 09:57:06+02:00, viperus@ubuntu.(none) + testcalshims.c~f84485d2b13cef55: + Delete: tests/libntp/testcalshims.c + testcalshims.h~5612fd527e4d6de9: + Delete: tests/libntp/testcalshims.h + + BitKeeper/deleted/3e/testcalshims.c~f84485d2b13cef55@1.5 +0 -0 + Delete: tests/libntp/testcalshims.c + + BitKeeper/deleted/ac/testcalshims.h~5612fd527e4d6de9@1.5 +0 -0 + Delete: tests/libntp/testcalshims.h + +ChangeSet@1.3453, 2015-06-20 09:19:13+02:00, viperus@ubuntu.(none) + run-buftvtots.c, buftvtots.c: + new file + Makefile.am: + minor fix to the alphabetic list + added buftvtots + + tests/libntp/Makefile.am@1.80 +2 -2 + minor fix to the alphabetic list + + tests/libntp/Makefile.am@1.79 +26 -6 + added buftvtots + + tests/libntp/buftvtots.c@1.1 +78 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/buftvtots.c + + tests/libntp/buftvtots.c@1.0 +0 -0 + + tests/libntp/run-buftvtots.c@1.1 +57 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-buftvtots.c + + tests/libntp/run-buftvtots.c@1.0 +0 -0 + +ChangeSet@1.3452, 2015-06-20 04:02:48+00:00, stenn@psp-at1.ntp.org + unity cleanup + + sntp/tests/utilities.cpp@1.10 +5 -5 + unity cleanup + +ChangeSet@1.3451, 2015-06-20 04:00:43+00:00, stenn@psp-at1.ntp.org + tests/libntp cleanup for Unity + + tests/libntp/Makefile.am@1.78 +7 -7 + tests/libntp cleanup for Unity + + tests/libntp/clocktime.c@1.3 +1 -5 + tests/libntp cleanup for Unity + + tests/libntp/decodenetnum.c@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_a_md5encrypt.cpp@1.7 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_atoint.cpp@1.4 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_atouint.cpp@1.3 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_authkeys.cpp@1.9 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_buftvtots.cpp@1.4, stenn@psp-fb1.ntp.org +0 -0 + Rename: tests/libntp/buftvtots.cpp -> tests/libntp/g_buftvtots.cpp + + tests/libntp/g_calendar.cpp@1.3 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_caljulian.cpp@1.7 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_caltontp.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_calyearstart.cpp@1.5 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_clocktime.cpp@1.6 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_hextoint.cpp@1.5 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_humandate.cpp@1.4 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_lfpfunc.cpp@1.4 +2 -2 + tests/libntp cleanup for Unity + + tests/libntp/g_lfptest.h@1.7 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_lfptest.h@1.6, stenn@psp-fb1.ntp.org +0 -0 + Rename: tests/libntp/lfptest.h -> tests/libntp/g_lfptest.h + + tests/libntp/g_lfptostr.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_libntptest.cpp@1.5 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_libntptest.cpp@1.4, stenn@psp-fb1.ntp.org +0 -0 + Rename: tests/libntp/libntptest.cpp -> tests/libntp/g_libntptest.cpp + + tests/libntp/g_libntptest.h@1.5, stenn@psp-fb1.ntp.org +0 -0 + Rename: tests/libntp/libntptest.h -> tests/libntp/g_libntptest.h + + tests/libntp/g_modetoa.cpp@1.3 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_msyslog.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_numtoa.cpp@1.4 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_numtohost.cpp@1.3 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_octtoint.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_prettydate.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_recvbuff.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_refnumtoa.cpp@1.4 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_sfptostr.cpp@1.3 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_sockaddrtest.h@1.5 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_sockaddrtest.h@1.4, stenn@psp-fb1.ntp.org +0 -0 + Rename: tests/libntp/sockaddrtest.h -> tests/libntp/g_sockaddrtest.h + + tests/libntp/g_ssl_init.cpp@1.5 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_statestr.cpp@1.4 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_timespecops.cpp@1.10 +2 -2 + tests/libntp cleanup for Unity + + tests/libntp/g_timestructs.cpp@1.6 +2 -2 + tests/libntp cleanup for Unity + + tests/libntp/g_timestructs.cpp@1.5, stenn@psp-fb1.ntp.org +0 -0 + Rename: tests/libntp/timestructs.cpp -> tests/libntp/g_timestructs.cpp + + tests/libntp/g_timestructs.h@1.5, stenn@psp-fb1.ntp.org +0 -0 + Rename: tests/libntp/timestructs.h -> tests/libntp/g_timestructs.h + + tests/libntp/g_timevalops.cpp@1.10 +2 -2 + tests/libntp cleanup for Unity + + tests/libntp/g_tstotv.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_uglydate.cpp@1.4 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_vi64ops.cpp@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/g_ymd2yd.cpp@1.3 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/hextolfp.c@1.4 +3 -1 + tests/libntp cleanup for Unity + + tests/libntp/humandate.c@1.3 +3 -2 + tests/libntp cleanup for Unity + + tests/libntp/lfpfunc.c@1.6 +0 -2 + tests/libntp cleanup for Unity + + tests/libntp/lfptest.h@1.3 +0 -0 + Rename: tests/libntp/c_lfptest.h -> tests/libntp/lfptest.h + + tests/libntp/lfptostr.c@1.2 +2 -1 + tests/libntp cleanup for Unity + + tests/libntp/msyslog.c@1.2 +2 -3 + tests/libntp cleanup for Unity + + tests/libntp/netof.c@1.3 +4 -4 + tests/libntp cleanup for Unity + + tests/libntp/octtoint.c@1.3 +1 -3 + tests/libntp cleanup for Unity + + tests/libntp/prettydate.c@1.2 +2 -1 + tests/libntp cleanup for Unity + + tests/libntp/recvbuff.c@1.4 +3 -4 + tests/libntp cleanup for Unity + + tests/libntp/refnumtoa.c@1.2 +1 -0 + tests/libntp cleanup for Unity + + tests/libntp/run-clocktime.c@1.4 +8 -8 + tests/libntp cleanup for Unity + + tests/libntp/run-hextolfp.c@1.3 +6 -6 + tests/libntp cleanup for Unity + + tests/libntp/run-humandate.c@1.2 +2 -2 + tests/libntp cleanup for Unity + + tests/libntp/run-lfpfunc.c@1.9 +9 -9 + tests/libntp cleanup for Unity + + tests/libntp/run-lfptostr.c@1.2 +11 -11 + tests/libntp cleanup for Unity + + tests/libntp/run-msyslog.c@1.2 +8 -8 + tests/libntp cleanup for Unity + + tests/libntp/run-octtoint.c@1.4 +7 -7 + tests/libntp cleanup for Unity + + tests/libntp/run-prettydate.c@1.2 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/run-recvbuff.c@1.2 +3 -3 + tests/libntp cleanup for Unity + + tests/libntp/run-refnumtoa.c@1.3 +2 -2 + tests/libntp cleanup for Unity + + tests/libntp/run-socktoa.c@1.6 +6 -6 + tests/libntp cleanup for Unity + + tests/libntp/run-ssl_init.c@1.4 +5 -5 + tests/libntp cleanup for Unity + + tests/libntp/run-strtolfp.c@1.2 +7 -7 + tests/libntp cleanup for Unity + + tests/libntp/run-timespecops.c@1.3 +28 -28 + tests/libntp cleanup for Unity + + tests/libntp/run-timevalops.c@1.5 +28 -28 + tests/libntp cleanup for Unity + + tests/libntp/run-tstotv.c@1.2 +3 -3 + tests/libntp cleanup for Unity + + tests/libntp/run-tvtots.c@1.2 +3 -3 + tests/libntp cleanup for Unity + + tests/libntp/run-uglydate.c@1.7 +1 -1 + tests/libntp cleanup for Unity + + tests/libntp/sockaddrtest.h@1.3 +0 -0 + Rename: tests/libntp/c_sockaddrtest.h -> tests/libntp/sockaddrtest.h + + tests/libntp/socktoa.c@1.3 +3 -1 + tests/libntp cleanup for Unity + + tests/libntp/ssl_init.c@1.5 +2 -1 + tests/libntp cleanup for Unity + + tests/libntp/strtolfp.c@1.2 +3 -1 + tests/libntp cleanup for Unity + + tests/libntp/test-libntp.c@1.9 +1 -0 + tests/libntp cleanup for Unity + + tests/libntp/testcalshims.h@1.4 +0 -3 + tests/libntp cleanup for Unity + + tests/libntp/timespecops.c@1.2 +0 -1 + tests/libntp cleanup for Unity + + tests/libntp/timestructs.c@1.2 +0 -0 + Rename: tests/libntp/c_timestructs.c -> tests/libntp/timestructs.c + + tests/libntp/timestructs.h@1.2 +0 -0 + Rename: tests/libntp/c_timestructs.h -> tests/libntp/timestructs.h + + tests/libntp/timevalops.c@1.5 +2 -4 + tests/libntp cleanup for Unity + + tests/libntp/tstotv.c@1.2 +3 -1 + tests/libntp cleanup for Unity + + tests/libntp/tvtots.c@1.3 +3 -2 + tests/libntp cleanup for Unity + + tests/libntp/uglydate.c@1.5 +1 -0 + tests/libntp cleanup for Unity + + tests/libntp/vi64ops.c@1.2 +2 -2 + tests/libntp cleanup for Unity + +ChangeSet@1.3450, 2015-06-20 02:39:45+00:00, stenn@psp-fb1.ntp.org + Unity cleanup of sntp/tests/ + + sntp/tests/Makefile.am@1.46 +4 -3 + Unity cleanup of sntp/tests/ + + sntp/tests/crypto.cpp@1.5 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/fileHandlingTest.h@1.8 +8 -7 + Unity cleanup of sntp/tests/ + + sntp/tests/fileHandlingTest.h@1.7 +0 -0 + Rename: sntp/tests/c_fileHandlingTest.h -> sntp/tests/fileHandlingTest.h + + sntp/tests/g_fileHandlingTest.h@1.6 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/g_fileHandlingTest.h@1.5 +0 -0 + Rename: sntp/tests/fileHandlingTest.h -> sntp/tests/g_fileHandlingTest.h + + sntp/tests/g_keyFile.cpp@1.8 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/g_kodDatabase.cpp@1.5 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/g_kodFile.cpp@1.10 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/g_networking.cpp@1.10 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/g_sntptest.h@1.6 +0 -0 + Rename: sntp/tests/sntptest.h -> sntp/tests/g_sntptest.h + + sntp/tests/keyFile.c@1.3 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/kodDatabase.c@1.2 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/kodFile.c@1.5 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/nameresolution.cpp@1.2 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/networking.c@1.3 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/packetHandling.cpp@1.11 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/packetProcessing.cpp@1.6 +1 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/run-keyFile.c@1.4 +0 -1 + Unity cleanup of sntp/tests/ + + sntp/tests/sntptest.h@1.2 +0 -0 + Rename: sntp/tests/c_sntptest.h -> sntp/tests/sntptest.h + + sntp/tests/utilities.cpp@1.9 +2 -2 + Unity cleanup of sntp/tests/ + +ChangeSet@1.3449, 2015-06-20 01:25:54+00:00, stenn@psp-fb1.ntp.org + Remove obsolete gtest files + + BitKeeper/deleted/03/atolfp.cpp~4b2bfa141cb6e704@1.10, stenn@psp-at1.ntp.org +0 -0 + Delete: tests/libntp/strtolfp.cpp + + BitKeeper/deleted/11/octtoint.cpp~50548df6cb56ca39@1.3, stenn@psp-at1.ntp.org +0 -0 + Delete: tests/libntp/octtoint.cpp + + BitKeeper/deleted/1e/lfptostr.cpp~fc33022cca22f4a0@1.4, stenn@psp-at1.ntp.org +0 -0 + Delete: tests/libntp/lfptostr.cpp + + BitKeeper/deleted/29/netof.cpp~ce09accf46a3055c@1.2, stenn@psp-at1.ntp.org +0 -0 + Delete: tests/libntp/netof.cpp + + BitKeeper/deleted/36/hextolfp.cpp~bdb41862b8a92a90@1.6, stenn@psp-at1.ntp.org +0 -0 + Delete: tests/libntp/hextolfp.cpp + + BitKeeper/deleted/c0/decodenetnum.cpp~eb55b950b046942f@1.3, stenn@psp-at1.ntp.org +0 -0 + Delete: tests/libntp/decodenetnum.cpp + +ChangeSet@1.3447, 2015-06-20 00:57:57+00:00, tflendrich@psp-deb1.ntp.org + Makefile.am: + dashes are now lined up + + tests/libntp/Makefile.am@1.77 +9 -9 + dashes are now lined up + +ChangeSet@1.3445.1.1, 2015-06-20 00:57:43+00:00, stenn@psp-at1.ntp.org + sntp/tests/Makefile.am cleanup + + sntp/tests/Makefile.am@1.45 +41 -37 + sntp/tests/Makefile.am cleanup + +ChangeSet@1.3446, 2015-06-20 00:55:15+00:00, tflendrich@psp-deb1.ntp.org + Makefile.am: + changed the indent from spaces to tabs + + tests/libntp/Makefile.am@1.76 +5 -5 + changed the indent from spaces to tabs + +ChangeSet@1.3445, 2015-06-19 23:49:56+00:00, tflendrich@psp-deb1.ntp.org + Makefile.am: + added a missing "-lpthread" + + tests/libntp/Makefile.am@1.75 +1 -0 + added a missing "-lpthread" + +ChangeSet@1.3444, 2015-06-19 23:34:57+00:00, tflendrich@psp-deb1.ntp.org + Makefile.am: + fixed the merge + + tests/libntp/Makefile.am@1.74 +1 -0 + fixed the merge + +ChangeSet@1.3429.3.3, 2015-06-20 00:33:19+02:00, tomek@tomek-n56vz.(none) + converted humandate from gtest to unity + + tests/libntp/Makefile.am@1.68.3.3 +20 -1 + added humandate.c + + tests/libntp/g_humandate.cpp@1.3 +0 -0 + Rename: tests/libntp/humandate.cpp -> tests/libntp/g_humandate.cpp + + tests/libntp/humandate.c@1.2 +25 -31 + + tests/libntp/humandate.c@1.1 +41 -0 + BitKeeper file /home/tomek/ntp/kod/head/ntp-stable-unity/tests/libntp/humandate.c + + tests/libntp/humandate.c@1.0 +0 -0 + + tests/libntp/run-humandate.c@1.1 +53 -0 + BitKeeper file /home/tomek/ntp/kod/head/ntp-stable-unity/tests/libntp/run-humandate.c + + tests/libntp/run-humandate.c@1.0 +0 -0 + + tests/libntp/run-sfptostr.c@1.1 +65 -0 + BitKeeper file /home/tomek/ntp/kod/head/ntp-stable-unity/tests/libntp/run-sfptostr.c + + tests/libntp/run-sfptostr.c@1.0 +0 -0 + +ChangeSet@1.3442, 2015-06-19 23:52:11+02:00, viperus@ubuntu.(none) + kodFile.c: + removed debug printfs + + sntp/tests/kodFile.c@1.4 +7 -7 + removed debug printfs + +ChangeSet@1.3441, 2015-06-19 23:15:36+02:00, viperus@ubuntu.(none) + Makefile.am: + added some clean and distclean stuff + c_fileHandlingTest.h: + added more debug printfs + kodFile.c: + changed CreatePath so new files are written in a writeable directory + + sntp/tests/Makefile.am@1.43 +2 -1 + added some clean and distclean stuff + + sntp/tests/c_fileHandlingTest.h@1.6 +1 -1 + added more debug printfs + + sntp/tests/kodFile.c@1.3 +7 -4 + changed CreatePath so new files are written in a writeable directory + + sntp/tests/run-kodFile.c@1.2 +2 -2 + +ChangeSet@1.3429.3.2, 2015-06-19 23:07:51+02:00, tomek@tomek-n56vz.(none) + converted sfptostr from GTest to Unity + + sntp/tests/Makefile.am@1.40.3.1 +1 -1 + makefile now works if someone has gtest + + sntp/tests/g_keyFile.cpp@1.4.2.1 +0 -0 + Rename: sntp/tests/keyFile.cpp -> sntp/tests/g_keyFile.cpp + + tests/libntp/Makefile.am@1.68.3.2 +21 -1 + added sfptostr.c + + tests/libntp/g_sfptostr.cpp@1.2 +0 -0 + Rename: tests/libntp/sfptostr.cpp -> tests/libntp/g_sfptostr.cpp + + tests/libntp/sfptostr.c@1.1 +73 -0 + BitKeeper file /home/tomek/ntp/kod/head/ntp-stable-unity/tests/libntp/sfptostr.c + + tests/libntp/sfptostr.c@1.0 +0 -0 + +ChangeSet@1.3429.3.1, 2015-06-19 22:31:16+02:00, tomek@tomek-n56vz.(none) + converted tvtots from gtest to unity + + tests/libntp/Makefile.am@1.68.3.1 +21 -1 + added tvtots.c + + tests/libntp/g_tvtots.cpp@1.7 +0 -0 + Rename: tests/libntp/tvtots.cpp -> tests/libntp/g_tvtots.cpp + + tests/libntp/run-tvtots.c@1.1 +55 -0 + BitKeeper file /home/tomek/ntp/kod/head/ntp-stable-unity/tests/libntp/run-tvtots.c + + tests/libntp/run-tvtots.c@1.0 +0 -0 + + tests/libntp/tvtots.c@1.2 +53 -0 + converted to unity + + tests/libntp/tvtots.c@1.1 +0 -0 + BitKeeper file /home/tomek/ntp/kod/head/ntp-stable-unity/tests/libntp/tvtots.c + + tests/libntp/tvtots.c@1.0 +0 -0 + +ChangeSet@1.3429.1.9, 2015-06-19 18:00:35+00:00, tflendrich@psp-deb1.ntp.org + bring back two files that were wrongfully removed + + tests/libntp/test-libntp.c@1.8 +0 -0 + Rename: BitKeeper/deleted/a4/test-libntp.c~4efce7533d11e808 -> tests/libntp/test-libntp.c + + tests/libntp/test-libntp.h@1.6 +0 -0 + Rename: BitKeeper/deleted/01/test-libntp.h~c19218ad555ac21 -> tests/libntp/test-libntp.h + +ChangeSet@1.3439, 2015-06-19 17:51:30+02:00, viperus@ubuntu.(none) + c_fileHandlingTest.h: + added new cases with strcpy(path,....) + run-strtolfp.c, run-lfptostr.c: + new file + + sntp/tests/c_fileHandlingTest.h@1.5 +4 -1 + added new cases with strcpy(path,....) + + tests/libntp/run-lfptostr.c@1.1 +71 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-lfptostr.c + + tests/libntp/run-lfptostr.c@1.0 +0 -0 + + tests/libntp/run-strtolfp.c@1.1 +63 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-strtolfp.c + + tests/libntp/run-strtolfp.c@1.0 +0 -0 + +ChangeSet@1.3429.2.2, 2015-06-19 20:24:45+05:30, loki@dadasgift.(none) + Test - crypto.c from sntp + + sntp/tests/Makefile.am@1.40.2.1 +20 -1 + + sntp/tests/crypto.c@1.1 +127 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/crypto.c + + sntp/tests/crypto.c@1.0 +0 -0 + + sntp/tests/g_crypto.cpp@1.1 +129 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/sntp/tests/g_crypto.cpp + + sntp/tests/g_crypto.cpp@1.0 +0 -0 + +ChangeSet@1.3413.3.4, 2015-06-19 16:06:35+02:00, martin@pc-martin.(none) + More support for smeared leap seconds. + + include/ntpd.h@1.190 +2 -0 + More support for smeared leap seconds. + + ntpd/ntp_config.c@1.329 +1 -0 + More support for smeared leap seconds. + + ntpd/ntp_control.c@1.197 +18 -1 + More support for smeared leap seconds. + + ntpd/ntp_leapsec.h@1.13 +1 -0 + More support for smeared leap seconds. + + ntpd/ntp_proto.c@1.358 +33 -14 + More support for smeared leap seconds. + + ntpd/ntp_timer.c@1.90 +40 -10 + More support for smeared leap seconds. + +ChangeSet@1.3435.1.1, 2015-06-19 13:51:57+00:00, viperus@psp-at1.ntp.org + c_fileHandlingTest.h: + added debug printfs, changed path value + kodFile.c: + added debug printfs + + sntp/tests/c_fileHandlingTest.h@1.4 +1 -1 + added debug printfs, changed path value + + sntp/tests/kodFile.c@1.2 +3 -3 + added debug printfs + +ChangeSet@1.3436, 2015-06-19 15:42:41+02:00, viperus@ubuntu.(none) + kod-output-single, kod-output-blank, kod-output-multiple: + new file + + sntp/tests/data/kod-output-blank@1.1 +0 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/data/kod-output-blank + + sntp/tests/data/kod-output-blank@1.0 +0 -0 + + sntp/tests/data/kod-output-multiple@1.1 +3 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/data/kod-output-multiple + + sntp/tests/data/kod-output-multiple@1.0 +0 -0 + + sntp/tests/data/kod-output-single@1.1 +1 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/data/kod-output-single + + sntp/tests/data/kod-output-single@1.0 +0 -0 + +ChangeSet@1.3435, 2015-06-19 13:58:37+02:00, viperus@ubuntu.(none) + c_fileHandlingTest.h: + added different paths depening on the build dir, maybe this will work on freebsd + run-keyFile.c: + slight change + + sntp/tests/c_fileHandlingTest.h@1.3 +16 -2 + added different paths depening on the build dir, maybe this will work on freebsd + + sntp/tests/run-keyFile.c@1.3 +1 -0 + slight change + +ChangeSet@1.3413.3.3, 2015-06-19 08:20:49+00:00, burnicki@psp-deb1.ntp.org + Updates by Harlan. + + ntpd/complete.conf.in@1.29 +1 -0 + Updates by Harlan. + + ntpd/ntp_parser.c@1.95 +1511 -1563 + Updates by Harlan. + + ntpd/ntp_parser.h@1.60 +230 -220 + Updates by Harlan. + +ChangeSet@1.3429.1.8, 2015-06-19 07:03:32+00:00, tflendrich@psp-at1.ntp.org + removed generated files that are not longer used + + BitKeeper/deleted/01/test-libntp.h~c19218ad555ac21@1.5 +0 -0 + Delete: tests/libntp/test-libntp.h + + BitKeeper/deleted/17/test-msyslog.c~36cfb2ff59dd5e9@1.2 +0 -0 + Delete: tests/libntp/test-msyslog.c + + BitKeeper/deleted/2a/test-recvbuff.c~1bf5e94672c41f5@1.2 +0 -0 + Delete: tests/libntp/test-recvbuff.c + + BitKeeper/deleted/67/test-tstotv.c~3117fe865385504e@1.2 +0 -0 + Delete: tests/libntp/test-tstotv.c + + BitKeeper/deleted/6f/test-ssl_init.c~2c5bc2112c1aaf15@1.2 +0 -0 + Delete: tests/libntp/test-ssl_init.c + + BitKeeper/deleted/91/test-vi64ops.c~3812d64e36653bf4@1.2 +0 -0 + Delete: tests/libntp/test-vi64ops.c + + BitKeeper/deleted/a4/test-libntp.c~4efce7533d11e808@1.7 +0 -0 + Delete: tests/libntp/test-libntp.c + + BitKeeper/deleted/b9/test-prettydate.c~ce9792d7bb10506b@1.2 +0 -0 + Delete: tests/libntp/test-prettydate.c + + BitKeeper/deleted/bb/test-caltontp.c~8cc124d6c538f1cb@1.2 +0 -0 + Delete: tests/libntp/test-caltontp.c + +ChangeSet@1.3429.1.7, 2015-06-19 06:43:05+00:00, tflendrich@psp-at1.ntp.org + deleted old, unused generated files + + BitKeeper/deleted/27/run-test-prettydate.c~93d1bdc762261643@1.2 +0 -0 + Delete: tests/libntp/run-test-prettydate.c + + BitKeeper/deleted/31/run-test-vi64ops.c~ddc8f15be90f476c@1.2 +0 -0 + Delete: tests/libntp/run-test-vi64ops.c + + BitKeeper/deleted/40/run-test-ssl_init.c~7ed3e3db79be5452@1.2 +0 -0 + Delete: tests/libntp/run-test-ssl_init.c + + BitKeeper/deleted/55/run-test-caltontp.c~989b072c54cd2ccd@1.2 +0 -0 + Delete: tests/libntp/run-test-caltontp.c + + BitKeeper/deleted/67/run-test-tstotv.c~48cf1897ca453301@1.2 +0 -0 + Delete: tests/libntp/run-test-tstotv.c + + BitKeeper/deleted/9f/run-test-msyslog.c~fb1907a46fb63895@1.2 +0 -0 + Delete: tests/libntp/run-test-msyslog.c + + BitKeeper/deleted/bc/run-test-recvbuff.c~cf87735b269fb6c2@1.2 +0 -0 + Delete: tests/libntp/run-test-recvbuff.c + +ChangeSet@1.3413.1.3, 2015-06-19 12:04:49+05:30, loki@dadasgift.(none) + lfptostr & strtolfp tests + + tests/libntp/Makefile.am@1.64.1.3 +38 -2 + +ChangeSet@1.3429.1.6, 2015-06-19 06:20:32+00:00, tflendrich@psp-deb1.ntp.org + added autogenerated files + + tests/libntp/run-caltontp.c@1.1 +57 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/run-caltontp.c + + tests/libntp/run-caltontp.c@1.0 +0 -0 + + tests/libntp/run-msyslog.c@1.1 +65 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/run-msyslog.c + + tests/libntp/run-msyslog.c@1.0 +0 -0 + + tests/libntp/run-prettydate.c@1.1 +51 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/run-prettydate.c + + tests/libntp/run-prettydate.c@1.0 +0 -0 + + tests/libntp/run-recvbuff.c@1.1 +55 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/run-recvbuff.c + + tests/libntp/run-recvbuff.c@1.0 +0 -0 + + tests/libntp/run-tstotv.c@1.1 +55 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/run-tstotv.c + + tests/libntp/run-tstotv.c@1.0 +0 -0 + + tests/libntp/test-caltontp.c@1.1 +0 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/test-caltontp.c + + tests/libntp/test-caltontp.c@1.0 +0 -0 + + tests/libntp/test-msyslog.c@1.1 +0 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/test-msyslog.c + + tests/libntp/test-msyslog.c@1.0 +0 -0 + + tests/libntp/test-prettydate.c@1.1 +0 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/test-prettydate.c + + tests/libntp/test-prettydate.c@1.0 +0 -0 + + tests/libntp/test-recvbuff.c@1.1 +0 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/test-recvbuff.c + + tests/libntp/test-recvbuff.c@1.0 +0 -0 + + tests/libntp/test-ssl_init.c@1.1 +0 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/test-ssl_init.c + + tests/libntp/test-ssl_init.c@1.0 +0 -0 + + tests/libntp/test-tstotv.c@1.1 +0 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/test-tstotv.c + + tests/libntp/test-tstotv.c@1.0 +0 -0 + + tests/libntp/test-vi64ops.c@1.1 +0 -0 + BitKeeper file /home/tflendrich/develpment/harlans/ntp-stable-unity/tests/libntp/test-vi64ops.c + + tests/libntp/test-vi64ops.c@1.0 +0 -0 + +ChangeSet@1.3429.1.5, 2015-06-19 07:09:46+02:00, tomek@tomek-n56vz.(none) + recvbuff.c: + removed testcalshims.h + + tests/libntp/recvbuff.c@1.3 +2 -2 + removed testcalshims.h + +ChangeSet@1.3429.1.4, 2015-06-19 04:16:11+00:00, tflendrich@psp-deb1.ntp.org + Makefile.am: + added -lpthread + + tests/libntp/Makefile.am@1.71 +1 -0 + added -lpthread + +ChangeSet@1.3429.1.3, 2015-06-19 05:59:58+02:00, tomek@tomek-n56vz.(none) + fixed a makefile: it didn't work if we had gtest enabled + + sntp/tests/Makefile.am@1.40.1.1 +2 -2 + + sntp/tests/g_keyFile.cpp@1.4.1.1 +0 -0 + Rename: sntp/tests/keyFile.cpp -> sntp/tests/g_keyFile.cpp + + tests/libntp/Makefile.am@1.70 +106 -11 + +ChangeSet@1.3434, 2015-06-19 03:25:54+02:00, viperus@ubuntu.(none) + + tests/libntp/run-caljulian.c@1.7 +4 -4 + +ChangeSet@1.3433, 2015-06-19 03:13:24+02:00, viperus@ubuntu.(none) + g_kodFile.cpp: + Rename: sntp/tests/kodFile.cpp -> sntp/tests/g_kodFile.cpp + g_keyFile.cpp: + Rename: sntp/tests/keyFile.cpp -> sntp/tests/g_keyFile.cpp + run-kodFile.c, kodFile.c: + new file + Makefile.am: + replaced ../version.c with $(top_builddir)/version.c. Converted new test. + c_fileHandlingTest.h: + converted all functions from C++ to C + keyFile.c: + uncommented all functions, 90% converted + + sntp/tests/Makefile.am@1.41 +26 -4 + replaced ../version.c with $(top_builddir)/version.c. Converted new test. + + sntp/tests/c_fileHandlingTest.h@1.2 +53 -26 + converted all functions from C++ to C + + sntp/tests/g_keyFile.cpp@1.5 +0 -0 + Rename: sntp/tests/keyFile.cpp -> sntp/tests/g_keyFile.cpp + + sntp/tests/g_kodFile.cpp@1.9 +0 -0 + Rename: sntp/tests/kodFile.cpp -> sntp/tests/g_kodFile.cpp + + sntp/tests/keyFile.c@1.2 +51 -47 + uncommented all functions, 90% converted + + sntp/tests/kodFile.c@1.1 +142 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/kodFile.c + + sntp/tests/kodFile.c@1.0 +0 -0 + + sntp/tests/run-keyFile.c@1.2 +10 -0 + + sntp/tests/run-kodFile.c@1.1 +61 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-kodFile.c + + sntp/tests/run-kodFile.c@1.0 +0 -0 + +ChangeSet@1.3432, 2015-06-18 23:33:19+02:00, viperus@ubuntu.(none) + caljulian.c: + replacing malloc.h with "ntp_stdlib.h" + + tests/libntp/caljulian.c@1.6 +3 -1 + replacing malloc.h with "ntp_stdlib.h" + +ChangeSet@1.3413.3.2, 2015-06-18 18:05:44+02:00, martin@pc-martin.(none) + Started to support leap smear. + + include/ntpd.h@1.189 +1 -0 + Started to support leap smear. + + ntpd/keyword-gen-utd@1.24 +1 -1 + Started to support leap smear. + + ntpd/keyword-gen.c@1.30 +17 -16 + Started to support leap smear. + + ntpd/ntp_config.c@1.328 +5 -1 + Started to support leap smear. + + ntpd/ntp_io.c@1.402 +2 -1 + Started to support leap smear. + + ntpd/ntp_keyword.h@1.26 +670 -656 + Started to support leap smear. + + ntpd/ntp_leapsec.h@1.12 +12 -0 + Started to support leap smear. + + ntpd/ntp_parser.c@1.94 +2031 -1971 + Started to support leap smear. + + ntpd/ntp_parser.h@1.59 +339 -345 + Started to support leap smear. + + ntpd/ntp_parser.y@1.86 +51 -46 + Started to support leap smear. + + ntpd/ntp_proto.c@1.357 +35 -2 + Started to support leap smear. + + ntpd/ntp_timer.c@1.89 +55 -9 + Started to support leap smear. + +ChangeSet@1.3413.3.1, 2015-06-18 16:45:21+02:00, martin@pc-martin.(none) + Removed trailing whitespace. + + ntpd/ntp_leapsec.c@1.22 +17 -17 + Removed trailing whitespace. + + ntpd/ntp_leapsec.h@1.11 +2 -2 + Removed trailing whitespace. + + ntpd/ntp_timer.c@1.88 +6 -6 + Removed trailing whitespace. + +ChangeSet@1.3429.1.1, 2015-06-18 08:48:31+00:00, stenn@psp-at1.ntp.org + typo + + sntp/tests/Makefile.am@1.40 +1 -1 + typo + +ChangeSet@1.3429, 2015-06-18 08:34:39+00:00, stenn@psp-at1.ntp.org + sntp/tests/networking.c build fixes + + sntp/tests/Makefile.am@1.39 +2 -1 + sntp/tests/networking.c build fixes + +ChangeSet@1.3427.1.2, 2015-06-18 10:21:18+02:00, viperus@ubuntu.(none) + caljulian.c: + included malloc.h to avoid implicit declaration + + tests/libntp/caljulian.c@1.5 +1 -0 + included malloc.h to avoid implicit declaration + + tests/libntp/run-caljulian.c@1.6 +4 -4 + +ChangeSet@1.3427.1.1, 2015-06-18 10:09:02+02:00, viperus@ubuntu.(none) + ssl_init.c: + fixing a test bug with #ifdef OPENSSL + + tests/libntp/run-ssl_init.c@1.1.1.1 +2 -0 + + tests/libntp/ssl_init.c@1.2.1.1 +5 -2 + fixing a test bug with #ifdef OPENSSL + +ChangeSet@1.3428, 2015-06-18 08:05:23+00:00, stenn@psp-at1.ntp.org + Unity ssl_init typo fix + + tests/libntp/run-ssl_init.c@1.2 +2 -0 + Unity ssl_init typo fix + + tests/libntp/ssl_init.c@1.3 +1 -1 + Unity ssl_init typo fix + +ChangeSet@1.3427, 2015-06-18 07:55:11+00:00, stenn@psp-at1.ntp.org + Unity update to sntp/Makefile.am + + sntp/Makefile.am@1.84 +0 -2 + Unity update to sntp/Makefile.am + +ChangeSet@1.3426, 2015-06-18 07:49:21+00:00, stenn@psp-at1.ntp.org + Unity cleanup + + BitKeeper/deleted/46/run-test-keyFile.c~4bf68803bc8e2c40@1.2 +0 -0 + Delete: sntp/tests/run-test-keyFile.c + + BitKeeper/deleted/56/run-test-kodDatabase.c~d8bb8b62b1e08d30@1.2 +0 -0 + Delete: sntp/tests/run-test-kodDatabase.c + + BitKeeper/deleted/fc/run-test-networking.c~b2cd2d50f3d83a90@1.2 +0 -0 + Delete: sntp/tests/run-test-networking.c + + sntp/tests/Makefile.am@1.38 +19 -17 + Unity cleanup + +ChangeSet@1.3425, 2015-06-18 09:06:24+02:00, viperus@ubuntu.(none) + removing duplicate file + + BitKeeper/deleted/61/socktoa.cpp~151e8671c6e040ac@1.3 +0 -0 + Delete: tests/libntp/socktoa.cpp + +ChangeSet@1.3424, 2015-06-18 09:04:46+02:00, viperus@ubuntu.(none) + run-keyFile.c, run-networking.c, run-kodDatabase.c: + new file + Makefile.am: + hopefully fixing bug-2852 + + sntp/tests/run-keyFile.c@1.1 +49 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-keyFile.c + + sntp/tests/run-keyFile.c@1.0 +0 -0 + + sntp/tests/run-kodDatabase.c@1.1 +59 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-kodDatabase.c + + sntp/tests/run-kodDatabase.c@1.0 +0 -0 + + sntp/tests/run-networking.c@1.1 +49 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-networking.c + + sntp/tests/run-networking.c@1.0 +0 -0 + + tests/libntp/Makefile.am@1.68 +1 -1 + hopefully fixing bug-2852 + +ChangeSet@1.3423, 2015-06-17 19:45:59+02:00, viperus@ubuntu.(none) + clocktime.c: + fixed the warning about implicit declaration, because mike_t said so, and mike_t is a wizard XD + bug-2803.c: + added declarations at the top of the file to fix warnings + + tests/bug-2803/bug-2803.c@1.5 +4 -1 + added declarations at the top of the file to fix warnings + + tests/bug-2803/run-bug-2803.c@1.5 +4 -2 + + tests/libntp/clocktime.c@1.2 +6 -0 + fixed the warning about implicit declaration, because mike_t said so, and mike_t is a wizard XD + + tests/libntp/run-clocktime.c@1.3 +8 -8 + +ChangeSet@1.3422, 2015-06-17 13:26:20+02:00, viperus@ubuntu.(none) + Makefile.am: + minor cleanup + + sntp/tests/Makefile.am@1.37 +2 -2 + minor cleanup + +ChangeSet@1.3421, 2015-06-17 13:17:39+02:00, viperus@ubuntu.(none) + run-ssl_init.c: + new file + ssl_init.c: + fix for minor #else warning + Makefile.am: + modified /sntp/tests/Makefile.am so it is consistent to harlans /tests/libntp/Makefile.am changes, including the run-test-* -> run-* + fixed the stuff I broke with automerge XD + + sntp/tests/Makefile.am@1.36 +18 -17 + modified /sntp/tests/Makefile.am so it is consistent to harlans /tests/libntp/Makefile.am changes, including the run-test-* -> run-* + + tests/libntp/Makefile.am@1.67 +15 -9 + fixed the stuff I broke with automerge XD + + tests/libntp/run-ssl_init.c@1.1 +57 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-ssl_init.c + + tests/libntp/run-ssl_init.c@1.0 +0 -0 + + tests/libntp/ssl_init.c@1.2 +2 -1 + fix for minor #else warning + +ChangeSet@1.3413.2.1, 2015-06-17 15:12:46+05:30, loki@dadasgift.(none) + Changes for & tests + + tests/libntp/Makefile.am@1.64.2.1 +41 -3 + + tests/libntp/g_lfptostr.cpp@1.1 +103 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/g_lfptostr.cpp + + tests/libntp/g_lfptostr.cpp@1.0 +0 -0 + + tests/libntp/g_strtolfp.cpp@1.1 +107 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/g_strtolfp.cpp + + tests/libntp/g_strtolfp.cpp@1.0 +0 -0 + + tests/libntp/lfptostr.c@1.1 +102 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/lfptostr.c + + tests/libntp/lfptostr.c@1.0 +0 -0 + + tests/libntp/strtolfp.c@1.1 +112 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/strtolfp.c + + tests/libntp/strtolfp.c@1.0 +0 -0 + +ChangeSet@1.3419, 2015-06-17 11:30:50+02:00, viperus@ubuntu.(none) + Many files: + new file + Makefile.am: + removed keyFile test from check_Programs for now + + sntp/tests/Makefile.am@1.35 +19 -2 + removed keyFile test from check_Programs for now + + sntp/tests/c_fileHandlingTest.h@1.1 +63 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/c_fileHandlingTest.h + + sntp/tests/c_fileHandlingTest.h@1.0 +0 -0 + + sntp/tests/keyFile.c@1.1 +136 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/keyFile.c + + sntp/tests/keyFile.c@1.0 +0 -0 + + sntp/tests/kodDatabase.c@1.1 +126 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/kodDatabase.c + + sntp/tests/kodDatabase.c@1.0 +0 -0 + + sntp/tests/run-test-keyFile.c@1.1 +49 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-test-keyFile.c + + sntp/tests/run-test-keyFile.c@1.0 +0 -0 + + sntp/tests/run-test-kodDatabase.c@1.1 +59 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-test-kodDatabase.c + + sntp/tests/run-test-kodDatabase.c@1.0 +0 -0 + +ChangeSet@1.3418, 2015-06-17 11:03:42+02:00, viperus@ubuntu.(none) + g_kodDatabase.cpp: + Rename: sntp/tests/kodDatabase.cpp -> sntp/tests/g_kodDatabase.cpp + g_networking.cpp: + Rename: sntp/tests/networking.cpp -> sntp/tests/g_networking.cpp + Makefile.am: + renamed *.cpp files to g_*.cpp + + sntp/tests/Makefile.am@1.34 +2 -2 + renamed *.cpp files to g_*.cpp + + sntp/tests/g_kodDatabase.cpp@1.4 +0 -0 + Rename: sntp/tests/kodDatabase.cpp -> sntp/tests/g_kodDatabase.cpp + + sntp/tests/g_networking.cpp@1.9 +0 -0 + Rename: sntp/tests/networking.cpp -> sntp/tests/g_networking.cpp + +ChangeSet@1.3417, 2015-06-17 10:59:42+02:00, viperus@ubuntu.(none) + Makefile.am: + builds another test + added ../version.c so kodDatabase builds. Should be done via a rule, needs fixing! + added c_fileHandlingTest.h to noinst_HEADERS + GTEST_AVAILABLE check moved into /sntp/tests/Makefile.am so unity tests can be run + + sntp/Makefile.am@1.83 +2 -2 + GTEST_AVAILABLE check moved into /sntp/tests/Makefile.am so unity tests can be run + + sntp/tests/Makefile.am@1.33 +7 -5 + added ../version.c so kodDatabase builds. Should be done via a rule, needs fixing! + + sntp/tests/Makefile.am@1.32 +21 -1 + builds another test + + sntp/tests/Makefile.am@1.31 +1 -0 + added c_fileHandlingTest.h to noinst_HEADERS + +ChangeSet@1.3413.1.1, 2015-06-17 04:05:10-04:00, stenn@deacon.udel.edu + clean up unity test names + + BitKeeper/deleted/b6/Makefile-~7d9ad3536b5db654@1.2 +0 -0 + Delete: tests/bug-2803/Makefile- + + BitKeeper/deleted/b8/test-2803.c~ba74ad843e357700@1.2 +0 -0 + Delete: tests/bug-2803/test-2803.c + + bootstrap@1.49 +2 -2 + clean up unity test names + + tests/bug-2803/Makefile.am@1.11 +3 -3 + clean up unity test names + + tests/bug-2803/bug-2803.c@1.4 +0 -0 + Rename: tests/bug-2803/ut-2803.c -> tests/bug-2803/bug-2803.c + + tests/libntp/Makefile.am@1.64.1.1 +194 -194 + clean up unity test names + + tests/libntp/run-a_md5encrypt.c@1.8 +0 -0 + Rename: tests/libntp/run-test-a_md5encrypt.c -> tests/libntp/run-a_md5encrypt.c + + tests/libntp/run-atoint.c@1.6 +0 -0 + Rename: tests/libntp/run-test-atoint.c -> tests/libntp/run-atoint.c + + tests/libntp/run-atouint.c@1.6 +0 -0 + Rename: tests/libntp/run-test-atouint.c -> tests/libntp/run-atouint.c + + tests/libntp/run-authkeys.c@1.7 +0 -0 + Rename: tests/libntp/run-test-authkeys.c -> tests/libntp/run-authkeys.c + + tests/libntp/run-calendar.c@1.3 +0 -0 + Rename: tests/libntp/run-test-calendar.c -> tests/libntp/run-calendar.c + + tests/libntp/run-caljulian.c@1.5 +0 -0 + Rename: tests/libntp/run-test-caljulian.c -> tests/libntp/run-caljulian.c + + tests/libntp/run-calyearstart.c@1.3 +0 -0 + Rename: tests/libntp/run-test-calyearstart.c -> tests/libntp/run-calyearstart.c + + tests/libntp/run-clocktime.c@1.2 +0 -0 + Rename: tests/libntp/run-test-clocktime.c -> tests/libntp/run-clocktime.c + + tests/libntp/run-decodenetnum.c@1.2 +0 -0 + Rename: tests/libntp/run-test-decodenetnum.c -> tests/libntp/run-decodenetnum.c + + tests/libntp/run-hextoint.c@1.6 +0 -0 + Rename: tests/libntp/run-test-hextoint.c -> tests/libntp/run-hextoint.c + + tests/libntp/run-hextolfp.c@1.2 +0 -0 + Rename: tests/libntp/run-test-hextolfp.c -> tests/libntp/run-hextolfp.c + + tests/libntp/run-lfpfunc.c@1.8 +0 -0 + Rename: tests/libntp/run-test-lfpfunc.c -> tests/libntp/run-lfpfunc.c + + tests/libntp/run-modetoa.c@1.7 +0 -0 + Rename: tests/libntp/run-test-modetoa.c -> tests/libntp/run-modetoa.c + + tests/libntp/run-netof.c@1.2 +0 -0 + Rename: tests/libntp/run-test-netof.c -> tests/libntp/run-netof.c + + tests/libntp/run-numtoa.c@1.6 +0 -0 + Rename: tests/libntp/run-test-numtoa.c -> tests/libntp/run-numtoa.c + + tests/libntp/run-numtohost.c@1.6 +0 -0 + Rename: tests/libntp/run-test-numtohost.c -> tests/libntp/run-numtohost.c + + tests/libntp/run-octtoint.c@1.3 +0 -0 + Rename: tests/libntp/run-test-octtoint.c -> tests/libntp/run-octtoint.c + + tests/libntp/run-refnumtoa.c@1.2 +0 -0 + Rename: tests/libntp/run-test-refnumtoa.c -> tests/libntp/run-refnumtoa.c + + tests/libntp/run-socktoa.c@1.2.1.1 +0 -0 + Rename: tests/libntp/run-test-socktoa.c -> tests/libntp/run-socktoa.c + + tests/libntp/run-statestr.c@1.6 +0 -0 + Rename: tests/libntp/run-test-statestr.c -> tests/libntp/run-statestr.c + + tests/libntp/run-timespecops.c@1.2 +0 -0 + Rename: tests/libntp/run-test-timespecops.c -> tests/libntp/run-timespecops.c + + tests/libntp/run-timevalops.c@1.4 +0 -0 + Rename: tests/libntp/run-test-timevalops.c -> tests/libntp/run-timevalops.c + + tests/libntp/run-uglydate.c@1.6 +0 -0 + Rename: tests/libntp/run-test-uglydate.c -> tests/libntp/run-uglydate.c + + tests/libntp/run-vi64ops.c@1.2 +0 -0 + Rename: tests/libntp/run-test-vi64ops.c -> tests/libntp/run-vi64ops.c + + tests/libntp/run-ymd2yd.c@1.6 +0 -0 + Rename: tests/libntp/run-test-ymd2yd.c -> tests/libntp/run-ymd2yd.c + + tests/sandbox/Makefile.am@1.3 +19 -20 + clean up unity test names + + tests/sandbox/run-modetoa.c@1.2 +0 -0 + Rename: tests/sandbox/run-second-test.c -> tests/sandbox/run-modetoa.c + + tests/sandbox/run-uglydate.c@1.2 +0 -0 + Rename: tests/sandbox/run-first-test.c -> tests/sandbox/run-uglydate.c + +ChangeSet@1.3416, 2015-06-17 09:35:55+02:00, viperus@ubuntu.(none) + run-test-networking.c, c_sntptest.h: + new file + networking.c: + added c_sntptest.h include + Makefile.am: + modified so Makefile.am runs unity tests and gtests + + sntp/tests/Makefile.am@1.30 +24 -9 + modified so Makefile.am runs unity tests and gtests + + sntp/tests/c_sntptest.h@1.1 +32 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/c_sntptest.h + + sntp/tests/c_sntptest.h@1.0 +0 -0 + + sntp/tests/networking.c@1.2 +4 -1 + added c_sntptest.h include + + sntp/tests/run-test-networking.c@1.1 +49 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/run-test-networking.c + + sntp/tests/run-test-networking.c@1.0 +0 -0 + +ChangeSet@1.3415, 2015-06-17 08:47:17+02:00, viperus@ubuntu.(none) + networking.c: + new file + Makefile.am: + started adding unity test framework support + + sntp/tests/Makefile.am@1.29 +36 -1 + started adding unity test framework support + + sntp/tests/networking.c@1.1 +4 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/sntp/tests/networking.c + + sntp/tests/networking.c@1.0 +0 -0 + +ChangeSet@1.3414, 2015-06-17 07:45:38+02:00, viperus@ubuntu.(none) + ssl_init.c, run-test-ssl_init.c: + new file + Makefile.am: + added ssl-init.c building + g_ssl_init.cpp: + Rename: tests/libntp/ssl_init.cpp -> tests/libntp/g_ssl_init.cpp + + tests/libntp/Makefile.am@1.65 +21 -2 + added ssl-init.c building + + tests/libntp/g_ssl_init.cpp@1.4 +0 -0 + Rename: tests/libntp/ssl_init.cpp -> tests/libntp/g_ssl_init.cpp + + tests/libntp/run-test-socktoa.c@1.3 +1 -1 + + tests/libntp/run-test-ssl_init.c@1.1 +57 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-ssl_init.c + + tests/libntp/run-test-ssl_init.c@1.0 +0 -0 + + tests/libntp/ssl_init.c@1.1 +53 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/ssl_init.c + + tests/libntp/ssl_init.c@1.0 +0 -0 + +ChangeSet@1.3413, 2015-06-16 18:48:26+02:00, viperus@ubuntu.(none) + socktoa.c: + added new function which replaces EXPECT_NE from gtest + + tests/libntp/run-test-socktoa.c@1.2 +1 -1 + + tests/libntp/socktoa.c@1.2 +4 -0 + added new function which replaces EXPECT_NE from gtest + +ChangeSet@1.3412, 2015-06-16 18:29:22+02:00, viperus@ubuntu.(none) + forgot to rename old .cpp file + + tests/libntp/g_timespecops.cpp@1.9 +0 -0 + Rename: tests/libntp/timespecops.cpp -> tests/libntp/g_timespecops.cpp + +ChangeSet@1.3411, 2015-06-16 18:26:31+02:00, viperus@ubuntu.(none) + timespecops.c : 95% done, lacks printf error messages. Contains 2 unity_helper functions which should be moved ot unity_helper.h + + tests/libntp/Makefile.am@1.64 +19 -1 + + tests/libntp/run-test-timespecops.c@1.1 +105 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-timespecops.c + + tests/libntp/run-test-timespecops.c@1.0 +0 -0 + + tests/libntp/run-test-timevalops.c@1.3 +5 -1 + + tests/libntp/timespecops.c@1.1 +588 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/timespecops.c + + tests/libntp/timespecops.c@1.0 +0 -0 + + tests/libntp/timevalops.c@1.4 +9 -9 + forgot to uncomment a few converted functions + +ChangeSet@1.3410, 2015-06-16 16:45:06+02:00, viperus@ubuntu.(none) + timevalops.c: + 95% done, a few printfs in case of an error have to be converted + + tests/libntp/run-test-timevalops.c@1.2 +32 -20 + + tests/libntp/timevalops.c@1.3 +81 -45 + 95% done, a few printfs in case of an error have to be converted + +ChangeSet@1.3409, 2015-06-16 15:33:51+02:00, viperus@ubuntu.(none) + timevalops.c: + replaced TEST_ASSERT_EQUAL_INT64 with TEST_ASSERT_EQUAL() (TEST_ASSER_EQUAL_INT() also autodetects 32 bit or 64 bit long int, which time_t uses) + + tests/libntp/timevalops.c@1.2 +1 -1 + replaced TEST_ASSERT_EQUAL_INT64 with TEST_ASSERT_EQUAL() (TEST_ASSER_EQUAL_INT() also autodetects 32 bit or 64 bit long int, which time_t uses) + +ChangeSet@1.3408, 2015-06-16 12:46:58+02:00, viperus@ubuntu.(none) + Makefile.am: + added building timevalops.c + run-test-timevalops.c, timevalops.c: + new file + lfpfunc.c: + removed sstream + g_timevalops.cpp: + Rename: tests/libntp/timevalops.cpp -> tests/libntp/g_timevalops.cpp + + tests/libntp/Makefile.am@1.63 +20 -1 + added building timevalops.c + + tests/libntp/g_timevalops.cpp@1.9 +0 -0 + Rename: tests/libntp/timevalops.cpp -> tests/libntp/g_timevalops.cpp + + tests/libntp/lfpfunc.c@1.5 +1 -2 + removed sstream + + tests/libntp/run-test-lfpfunc.c@1.7 +9 -9 + + tests/libntp/run-test-timevalops.c@1.1 +89 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-timevalops.c + + tests/libntp/run-test-timevalops.c@1.0 +0 -0 + + tests/libntp/timevalops.c@1.1 +564 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/timevalops.c + + tests/libntp/timevalops.c@1.0 +0 -0 + +ChangeSet@1.3407, 2015-06-16 01:29:44+02:00, viperus@ubuntu.(none) + Makefile.am: + added -lpthread to decodenetnum_LDADD. Temporary solution, until I get an answer from jnperlin + + tests/libntp/Makefile.am@1.62 +1 -0 + added -lpthread to decodenetnum_LDADD. Temporary solution, until I get an answer from jnperlin + +ChangeSet@1.3406, 2015-06-16 00:54:42+02:00, viperus@ubuntu.(none) + c_sockaddrtest.h: + removed stuff like 1==1 with TRUE. Also added cin cout stuff, should be replaced b + Many files: + new file + Makefile.am: + fixes to Lokesh-Damir merge, added new .h to noinst_SOURCES + c_lfptest.h: + put the static vars back in here, removed them from hextolfp.c, because more files will need them. + hextolfp.c: + removed static consts, placed them in c_lpftest.h + octtoint.c: + removed outdates testcalshims.h, replaced with required includes + + tests/libntp/Makefile.am@1.61 +62 -45 + fixes to Lokesh-Damir merge, added new .h to noinst_SOURCES + + tests/libntp/c_lfptest.h@1.2 +15 -2 + put the static vars back in here, removed them from hextolfp.c, because more files will need them. + + tests/libntp/c_sockaddrtest.h@1.2 +14 -6 + removed stuff like 1==1 with TRUE. Also added cin cout stuff, should be replaced b + + tests/libntp/hextolfp.c@1.3 +0 -7 + removed static consts, placed them in c_lpftest.h + + tests/libntp/octtoint.c@1.2 +4 -1 + removed outdates testcalshims.h, replaced with required includes + + tests/libntp/run-test-decodenetnum.c@1.1 +61 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-decodenetnum.c + + tests/libntp/run-test-decodenetnum.c@1.0 +0 -0 + + tests/libntp/run-test-hextolfp.c@1.1 +61 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-hextolfp.c + + tests/libntp/run-test-hextolfp.c@1.0 +0 -0 + + tests/libntp/run-test-netof.c@1.1 +57 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-netof.c + + tests/libntp/run-test-netof.c@1.0 +0 -0 + + tests/libntp/run-test-octtoint.c@1.2 +11 -8 + + tests/libntp/run-test-socktoa.c@1.1 +61 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-socktoa.c + + tests/libntp/run-test-socktoa.c@1.0 +0 -0 + +ChangeSet@1.3383.1.7, 2015-06-15 23:53:38+05:30, loki@dadasgift.(none) + Changes wrt to test + + tests/libntp/Makefile.am@1.59 +27 -8 + + tests/libntp/g_socktoa.cpp@1.1 +100 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/g_socktoa.cpp + + tests/libntp/g_socktoa.cpp@1.0 +0 -0 + + tests/libntp/socktoa.c@1.1 +103 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/socktoa.c + + tests/libntp/socktoa.c@1.0 +0 -0 + +ChangeSet@1.3383.1.6, 2015-06-15 11:59:18+05:30, loki@dadasgift.(none) + Changes for test + + tests/libntp/Makefile.am@1.58 +16 -3 + + tests/libntp/decodenetnum.c@1.1 +96 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/decodenetnum.c + + tests/libntp/decodenetnum.c@1.0 +0 -0 + + tests/libntp/g_decodenetnum.cpp@1.1 +93 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/g_decodenetnum.cpp + + tests/libntp/g_decodenetnum.cpp@1.0 +0 -0 + +ChangeSet@1.3383.1.5, 2015-06-15 11:21:38+05:30, loki@dadasgift.(none) + Changes wrt to test + + tests/libntp/c_lfptest.h@1.1 +17 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/c_lfptest.h + + tests/libntp/c_lfptest.h@1.0 +0 -0 + + tests/libntp/hextolfp.c@1.2 +24 -17 + + tests/libntp/lfptest.h@1.5 +0 -23 + +ChangeSet@1.3383.1.4, 2015-06-15 11:05:04+05:30, loki@dadasgift.(none) + Changes for tests + + tests/libntp/c_sockaddrtest.h@1.1 +49 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/c_sockaddrtest.h + + tests/libntp/c_sockaddrtest.h@1.0 +0 -0 + + tests/libntp/netof.c@1.2 +1 -1 + + tests/libntp/sockaddrtest.h@1.3 +0 -52 + +ChangeSet@1.3391.1.6, 2015-06-15 01:34:31+02:00, tomek@tomek-n56vz.(none) + Makefile.am: + fixed double definition of something + + tests/libntp/Makefile.am@1.54.3.3 +0 -6 + fixed double definition of something + +ChangeSet@1.3391.1.5, 2015-06-15 01:12:49+02:00, tomek@tomek-n56vz.(none) + Makefile.am: + missing backslashes added + + tests/libntp/Makefile.am@1.54.3.2 +10 -10 + missing backslashes added + +ChangeSet@1.3391.1.4, 2015-06-15 00:51:33+02:00, tomek@tomek-n56vz.(none) + vi64ops.c: + used a simpler assertion + + tests/libntp/vi64ops.c@1.2 +6 -6 + used a simpler assertion + +ChangeSet@1.3391.1.3, 2015-06-15 00:49:59+02:00, tomek@tomek-n56vz.(none) + used TEST_ASSERT_NULL instead of ASSERT_TRUE(ptr == NULL) in test/libntp/recvbuff.c + + tests/libntp/recvbuff.c@1.2 +1 -1 + +ChangeSet@1.3391.1.2, 2015-06-15 00:45:57+02:00, tomek@tomek-n56vz.(none) + edited a makefile in test/libntp to build those tests + + tests/libntp/Makefile.am@1.54.3.1 +108 -7 + +ChangeSet@1.3391.1.1, 2015-06-15 00:42:12+02:00, tomek@tomek-n56vz.(none) + converted a bunch of test from GTest to Unity in test/libntp/ + + BitKeeper/deleted/5b/msyslog.c~2253255e7e9701a2@1.2 +0 -0 + Delete: tests/libntp/msyslog.c + + tests/libntp/msyslog.c@1.1 +137 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/msyslog.c + + tests/libntp/msyslog.c@1.0 +0 -0 + + BitKeeper/deleted/5e/prettydate.cpp~f50578082d92e04@1.4 +0 -0 + Delete: tests/libntp/prettydate.cpp + + BitKeeper/deleted/8d/tstotv.cpp~44f3d9a5f5de991@1.3 +0 -0 + Delete: tests/libntp/tstotv.cpp + + BitKeeper/deleted/a9/recvbuff.cpp~64ef3a6926361d4@1.2 +0 -0 + Delete: tests/libntp/recvbuff.cpp + + BitKeeper/deleted/bb/caltontp.cpp~625109d015181aab@1.2 +0 -0 + Delete: tests/libntp/caltontp.cpp + + BitKeeper/deleted/d2/vi64ops.cpp~8587c242374ab4ce@1.1.1.1 +0 -0 + Delete: tests/libntp/vi64ops.cpp + + BitKeeper/deleted/e2/msyslog.cpp~439edfb748fb30dd@1.4 +0 -0 + Delete: tests/libntp/msyslog.cpp + + tests/libntp/caltontp.c@1.1 +48 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/caltontp.c + + tests/libntp/caltontp.c@1.0 +0 -0 + + tests/libntp/g_caltontp.cpp@1.1 +49 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/g_caltontp.cpp + + tests/libntp/g_caltontp.cpp@1.0 +0 -0 + + tests/libntp/g_msyslog.cpp@1.1 +137 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/g_msyslog.cpp + + tests/libntp/g_msyslog.cpp@1.0 +0 -0 + + tests/libntp/g_prettydate.cpp@1.1 +16 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/g_prettydate.cpp + + tests/libntp/g_prettydate.cpp@1.0 +0 -0 + + tests/libntp/g_recvbuff.cpp@1.1 +38 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/g_recvbuff.cpp + + tests/libntp/g_recvbuff.cpp@1.0 +0 -0 + + tests/libntp/g_tstotv.cpp@1.1 +57 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/g_tstotv.cpp + + tests/libntp/g_tstotv.cpp@1.0 +0 -0 + + tests/libntp/g_vi64ops.cpp@1.1 +64 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/g_vi64ops.cpp + + tests/libntp/g_vi64ops.cpp@1.0 +0 -0 + + tests/libntp/msyslog.c@1.1 +137 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/msyslog.c + + tests/libntp/msyslog.c@1.0 +0 -0 + + tests/libntp/prettydate.c@1.1 +16 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/prettydate.c + + tests/libntp/prettydate.c@1.0 +0 -0 + + tests/libntp/recvbuff.c@1.1 +43 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/recvbuff.c + + tests/libntp/recvbuff.c@1.0 +0 -0 + + tests/libntp/run-test-caltontp.c@1.1 +57 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/run-test-caltontp.c + + tests/libntp/run-test-caltontp.c@1.0 +0 -0 + + tests/libntp/run-test-msyslog.c@1.1 +65 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/run-test-msyslog.c + + tests/libntp/run-test-msyslog.c@1.0 +0 -0 + + tests/libntp/run-test-prettydate.c@1.1 +51 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/run-test-prettydate.c + + tests/libntp/run-test-prettydate.c@1.0 +0 -0 + + tests/libntp/run-test-recvbuff.c@1.1 +55 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/run-test-recvbuff.c + + tests/libntp/run-test-recvbuff.c@1.0 +0 -0 + + tests/libntp/run-test-tstotv.c@1.1 +55 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/run-test-tstotv.c + + tests/libntp/run-test-tstotv.c@1.0 +0 -0 + + tests/libntp/run-test-vi64ops.c@1.1 +55 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/run-test-vi64ops.c + + tests/libntp/run-test-vi64ops.c@1.0 +0 -0 + + tests/libntp/tstotv.c@1.1 +42 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/tstotv.c + + tests/libntp/tstotv.c@1.0 +0 -0 + + tests/libntp/vi64ops.c@1.1 +52 -0 + BitKeeper file /home/tomek/ntp/kod/harlans/ntp-stable-unity/tests/libntp/vi64ops.c + + tests/libntp/vi64ops.c@1.0 +0 -0 + +ChangeSet@1.3404, 2015-06-14 19:01:51+02:00, viperus@ubuntu.(none) + Makefile.am: + added -lpthread to test_caljuliaj_LDADD, because it's not in $(PTHREAD_LIBS) + + tests/libntp/Makefile.am@1.54.1.9 +1 -0 + added -lpthread to test_caljuliaj_LDADD, because it's not in $(PTHREAD_LIBS) + +ChangeSet@1.3403, 2015-06-14 18:42:02+02:00, viperus@ubuntu.(none) + Makefile.am: + added test-libntp.h in noinst_HEADERS, otherwise you can't build make distcheck on my ubuntu + + tests/libntp/Makefile.am@1.54.1.8 +1 -0 + added test-libntp.h in noinst_HEADERS, otherwise you can't build make distcheck on my ubuntu + +ChangeSet@1.3402, 2015-06-14 18:34:38+02:00, viperus@ubuntu.(none) + testlibntp.c: + Rename: tests/libntp/test-libntp.c -> tests/libntp/testlibntp.c + testlibntp.h: + Rename: tests/libntp/test-libntp.h -> tests/libntp/testlibntp.h + test-libntp.h: + Rename: tests/libntp/testlibntp.h -> tests/libntp/test-libntp.h + test-libntp.c: + Rename: tests/libntp/testlibntp.c -> tests/libntp/test-libntp.c + + tests/libntp/test-libntp.c@1.6 +0 -0 + Rename: tests/libntp/testlibntp.c -> tests/libntp/test-libntp.c + + tests/libntp/testlibntp.c@1.5 +0 -0 + Rename: tests/libntp/test-libntp.c -> tests/libntp/testlibntp.c + + tests/libntp/test-libntp.h@1.4 +0 -0 + Rename: tests/libntp/testlibntp.h -> tests/libntp/test-libntp.h + + tests/libntp/testlibntp.h@1.3 +0 -0 + Rename: tests/libntp/test-libntp.h -> tests/libntp/testlibntp.h + +ChangeSet@1.3401, 2015-06-14 16:17:06+00:00, viperus@psp-deb1.ntp.org + Makefile.am: + removed the folder /unity-framework/ + + Makefile.am@1.131 +0 -1 + removed the folder /unity-framework/ + +ChangeSet@1.3400, 2015-06-14 16:14:29+00:00, viperus@psp-deb1.ntp.org + ProductionCode.h~fac233823798db21: + Delete: tests/unity-framework/ProductionCode.h + TestProductionCode.c~4b9dea2fdb531435: + Delete: tests/unity-framework/TestProductionCode.c + TestProductionCode_Runner.c~41a4ba4b8da8c72e: + Delete: tests/unity-framework/TestProductionCode_Runner.c + ProductionCode.c~2c2bc4c32341b018: + Delete: tests/unity-framework/ProductionCode.c + + BitKeeper/deleted/87/TestProductionCode.c~4b9dea2fdb531435@1.2 +0 -0 + Delete: tests/unity-framework/TestProductionCode.c + + BitKeeper/deleted/88/ProductionCode.h~fac233823798db21@1.2 +0 -0 + Delete: tests/unity-framework/ProductionCode.h + + BitKeeper/deleted/ae/ProductionCode.c~2c2bc4c32341b018@1.2 +0 -0 + Delete: tests/unity-framework/ProductionCode.c + + BitKeeper/deleted/af/TestProductionCode_Runner.c~41a4ba4b8da8c72e@1.2 +0 -0 + Delete: tests/unity-framework/TestProductionCode_Runner.c + +ChangeSet@1.3383.1.3, 2015-06-14 20:28:01+05:30, loki@dadasgift.(none) + Files related to test + + tests/libntp/Makefile.am@1.57 +19 -2 + + tests/libntp/sockaddrtest.h@1.2 +53 -0 + +ChangeSet@1.3383.1.2, 2015-06-14 20:26:51+05:30, loki@dadasgift.(none) + Files related to test + + tests/libntp/g_netof.cpp@1.1 +69 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/g_netof.cpp + + tests/libntp/g_netof.cpp@1.0 +0 -0 + + tests/libntp/netof.c@1.1 +74 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/netof.c + + tests/libntp/netof.c@1.0 +0 -0 + +ChangeSet@1.3399, 2015-06-14 12:22:39+00:00, viperus@psp-at1.ntp.org + g_calendar.cpp: + Rename: tests/libntp/calendar.cpp -> tests/libntp/g_calendar.cpp + Makefile.am: + renamed calendar.cpp to g_calendar.cpp, reflecting changes in Makefile.am + + tests/libntp/Makefile.am@1.54.1.7 +2 -1 + renamed calendar.cpp to g_calendar.cpp, reflecting changes in Makefile.am + + tests/libntp/g_calendar.cpp@1.2 +0 -0 + Rename: tests/libntp/calendar.cpp -> tests/libntp/g_calendar.cpp + +ChangeSet@1.3398, 2015-06-14 11:56:02+02:00, viperus@ubuntu.(none) + bug-2803.h~388af97e65bf386e: + Delete: tests/bug-2803/bug-2803.h + TestProductionCode_Runner.c~1dd6cbb7f125c42a: + Delete: tests/bug-2803/TestProductionCode_Runner.c + bug-2803.c~75ddf194e9fda1b8: + Delete: tests/bug-2803/bug-2803.c + Makefile.am: + removed outdated files + ut-2803.c: + merged with bug-2803.c|h, they are obsolete now + + BitKeeper/deleted/52/bug-2803.h~388af97e65bf386e@1.2 +0 -0 + Delete: tests/bug-2803/bug-2803.h + + BitKeeper/deleted/e9/TestProductionCode_Runner.c~1dd6cbb7f125c42a@1.3 +0 -0 + Delete: tests/bug-2803/TestProductionCode_Runner.c + + tests/bug-2803/TestProductionCode_Runner.c@1.2 +9 -25 + + BitKeeper/deleted/f4/bug-2803.c~75ddf194e9fda1b8@1.4 +0 -0 + Delete: tests/bug-2803/bug-2803.c + + tests/bug-2803/Makefile.am@1.10 +0 -2 + removed outdated files + + tests/bug-2803/run-bug-2803.c@1.4 +1 -1 + + tests/bug-2803/ut-2803.c@1.3 +100 -10 + merged with bug-2803.c|h, they are obsolete now + +ChangeSet@1.3397, 2015-06-14 11:34:05+02:00, viperus@ubuntu.(none) + calendar.c: + forgot to return 2 functions + + tests/libntp/calendar.c@1.2 +3 -18 + forgot to return 2 functions + + tests/libntp/run-test-calendar.c@1.2 +11 -11 + +ChangeSet@1.3396, 2015-06-14 11:26:43+02:00, viperus@ubuntu.(none) + caljulian.c: + removed an unnecessary printf + run-test-calendar.c, calendar.c: + new file + Makefile.am: + now builds calendar.c as well + + tests/libntp/Makefile.am@1.54.1.6 +23 -0 + now builds calendar.c as well + + tests/libntp/calendar.c@1.1 +431 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/calendar.c + + tests/libntp/calendar.c@1.0 +0 -0 + + tests/libntp/caljulian.c@1.4 +0 -1 + removed an unnecessary printf + + tests/libntp/run-test-calendar.c@1.1 +71 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-calendar.c + + tests/libntp/run-test-calendar.c@1.0 +0 -0 + + tests/libntp/run-test-caljulian.c@1.4 +4 -4 + +ChangeSet@1.3395, 2015-06-14 10:24:54+02:00, viperus@ubuntu.(none) + Makefile.am: + removed run-test-libntp.c, unncecessary + run-test-libntp.c~b495db21713a6587: + Delete: tests/libntp/run-test-libntp.c + + BitKeeper/deleted/78/run-test-libntp.c~b495db21713a6587@1.3 +0 -0 + Delete: tests/libntp/run-test-libntp.c + + tests/libntp/Makefile.am@1.54.1.5 +0 -1 + removed run-test-libntp.c, unncecessary + + tests/libntp/run-test-caljulian.c@1.3 +4 -4 + +ChangeSet@1.3394, 2015-06-14 10:05:45+02:00, viperus@ubuntu.(none) + caljulian.c: + minor cleanup + Makefile.am: + mereged with Harlan's Makefile.am@1.55 version. + + tests/libntp/Makefile.am@1.54.1.4 +162 -134 + mereged with Harlan's Makefile.am@1.55 version. + + tests/libntp/caljulian.c@1.3 +2 -9 + minor cleanup + +ChangeSet@1.3393, 2015-06-14 08:29:55+02:00, viperus@ubuntu.(none) + caljulian.c: + fixed printf in case of an error + + tests/libntp/caljulian.c@1.2 +24 -4 + fixed printf in case of an error + + tests/libntp/run-test-caljulian.c@1.2 +4 -4 + +ChangeSet@1.3391, 2015-06-14 05:15:48+00:00, stenn@psp-at1.ntp.org + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq-subs.c@1.108 +5 -4 + [Bug 2778] Implement "apeers" ntpq command to include associd + +ChangeSet@1.3390, 2015-06-14 03:18:13+00:00, stenn@psp-at1.ntp.org + merge cleanup + + ChangeLog@1.1656 +1 -1 + merge cleanup + +ChangeSet@1.3388, 2015-06-14 00:10:48+00:00, stenn@psp-at1.ntp.org + Unity updates + + bootstrap@1.48 +30 -13 + Unity updates + + tests/libntp/Makefile.am@1.54.1.2 +133 -148 + Unity updates + + tests/libntp/a_md5encrypt.c@1.6 +17 -15 + Unity updates + + tests/libntp/run-test-a_md5encrypt.c@1.7 +5 -5 + Unity updates + +ChangeSet@1.3386.1.4, 2015-06-14 01:42:05+02:00, viperus@ubuntu.(none) + forgot to rename the .cpp file + + tests/libntp/g_caljulian.cpp@1.6 +0 -0 + Rename: tests/libntp/caljulian.cpp -> tests/libntp/g_caljulian.cpp + +ChangeSet@1.3386.1.3, 2015-06-14 01:40:35+02:00, viperus@ubuntu.(none) + Many files: + new file + calyearstart.c: + removed the functions from here, put them in test-libntp.c + Makefile.am: + adding support for new tests + g_calyearstart.cpp: + Rename: tests/libntp/calyearstart.cpp -> tests/libntp/g_calyearstart.cpp + g_clocktime.cpp: + Rename: tests/libntp/clocktime.cpp -> tests/libntp/g_clocktime.cpp + test-libntp.h: + added headers for new functions + test-libntp.c: + moved the functions which 3 tests use into this file + run-test-calyearstart.c: + minor update + + tests/libntp/Makefile.am@1.54.2.3 +57 -12 + adding support for new tests + + tests/libntp/caljulian.c@1.1 +101 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/caljulian.c + + tests/libntp/caljulian.c@1.0 +0 -0 + + tests/libntp/calyearstart.c@1.2 +2 -19 + removed the functions from here, put them in test-libntp.c + + tests/libntp/calyearstart.c@1.1 +61 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/calyearstart.c + + tests/libntp/calyearstart.c@1.0 +0 -0 + + tests/libntp/clocktime.c@1.1 +199 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/clocktime.c + + tests/libntp/clocktime.c@1.0 +0 -0 + + tests/libntp/g_calyearstart.cpp@1.4 +0 -0 + Rename: tests/libntp/calyearstart.cpp -> tests/libntp/g_calyearstart.cpp + + tests/libntp/g_clocktime.cpp@1.5 +0 -0 + Rename: tests/libntp/clocktime.cpp -> tests/libntp/g_clocktime.cpp + + tests/libntp/run-test-caljulian.c@1.1 +57 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-caljulian.c + + tests/libntp/run-test-caljulian.c@1.0 +0 -0 + + tests/libntp/run-test-calyearstart.c@1.2 +3 -3 + minor update + + tests/libntp/run-test-calyearstart.c@1.1 +55 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-calyearstart.c + + tests/libntp/run-test-calyearstart.c@1.0 +0 -0 + + tests/libntp/run-test-clocktime.c@1.1 +65 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-clocktime.c + + tests/libntp/run-test-clocktime.c@1.0 +0 -0 + + tests/libntp/test-libntp.c@1.4 +14 -22 + moved the functions which 3 tests use into this file + + tests/libntp/test-libntp.h@1.2 +3 -6 + added headers for new functions + +ChangeSet@1.3386.1.2, 2015-06-14 00:20:14+02:00, viperus@ubuntu.(none) + Makefile.am: + added refnumtoa.c + run-test-vi64ops.c, refnumtoa.c, run-test-refnumtoa.c: + new file + g_refnumtoa.cpp: + Rename: tests/libntp/refnumtoa.cpp -> tests/libntp/g_refnumtoa.cpp + + tests/libntp/Makefile.am@1.54.2.2 +19 -2 + added refnumtoa.c + + tests/libntp/g_refnumtoa.cpp@1.3 +0 -0 + Rename: tests/libntp/refnumtoa.cpp -> tests/libntp/g_refnumtoa.cpp + + tests/libntp/refnumtoa.c@1.1 +63 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/refnumtoa.c + + tests/libntp/refnumtoa.c@1.0 +0 -0 + + tests/libntp/run-test-refnumtoa.c@1.1 +53 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-refnumtoa.c + + tests/libntp/run-test-refnumtoa.c@1.0 +0 -0 + + tests/libntp/run-test-vi64ops.c@1.1 +55 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-vi64ops.c + + tests/libntp/run-test-vi64ops.c@1.0 +0 -0 + +ChangeSet@1.3386.1.1, 2015-06-13 23:35:39+02:00, viperus@ubuntu.(none) + vi64ops.c: + new file + Makefile.am: + added stuff related to vi64ops.c + g_vi64ops.cpp: + Rename: tests/libntp/vi64ops.cpp -> tests/libntp/g_vi64ops.cpp + + tests/libntp/Makefile.am@1.54.2.1 +23 -2 + added stuff related to vi64ops.c + + tests/libntp/g_vi64ops.cpp@1.2 +0 -0 + Rename: tests/libntp/vi64ops.cpp -> tests/libntp/g_vi64ops.cpp + + tests/libntp/vi64ops.c@1.1 +72 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/vi64ops.c + + tests/libntp/vi64ops.c@1.0 +0 -0 + +ChangeSet@1.3387, 2015-06-13 18:35:19+00:00, stenn@psp-at1.ntp.org + Makefile.am unity-related cleanup + + tests/bug-2803/run-bug-2803.c@1.3 +5 -2 + template update + + tests/libntp/Makefile.am@1.54.1.1 +148 -133 + Makefile.am unity-related cleanup + +ChangeSet@1.3385, 2015-06-13 05:28:57-04:00, stenn@deacon.udel.edu + unity notes + + NEWS@1.138 +8 -1 + unity notes + +ChangeSet@1.3384, 2015-06-13 05:16:11-04:00, stenn@deacon.udel.edu + Note that Unity requires ruby, if tests change + + ChangeLog@1.1653 +1 -0 + Note that Unity requires ruby, if tests change + +ChangeSet@1.3370.1.3, 2015-06-13 14:42:51+05:30, loki@dadasgift.(none) + hextolfp test converted to unity + + tests/libntp/Makefile.am@1.56 +19 -2 + + tests/libntp/g_hextolfp.cpp@1.1 +58 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/g_hextolfp.cpp + + tests/libntp/g_hextolfp.cpp@1.0 +0 -0 + + tests/libntp/hextolfp.c@1.1 +61 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/hextolfp.c + + tests/libntp/hextolfp.c@1.0 +0 -0 + + tests/libntp/lfptest.h@1.4 +25 -1 + +ChangeSet@1.3383, 2015-06-13 02:47:12+00:00, stenn@psp-fb1.ntp.org + testcalshims.h cleanup + + tests/libntp/a_md5encrypt.c@1.5 +1 -5 + testcalshims.h cleanup + + tests/libntp/atoint.c@1.3 +4 -1 + testcalshims.h cleanup + + tests/libntp/atouint.c@1.3 +4 -2 + testcalshims.h cleanup + + tests/libntp/authkeys.c@1.6 +5 -3 + testcalshims.h cleanup + + tests/libntp/hextoint.c@1.3 +5 -3 + testcalshims.h cleanup + + tests/libntp/lfpfunc.c@1.4 +4 -13 + testcalshims.h cleanup + + tests/libntp/modetoa.c@1.5 +5 -5 + testcalshims.h cleanup + + tests/libntp/numtoa.c@1.3 +5 -2 + testcalshims.h cleanup + + tests/libntp/numtohost.c@1.3 +4 -2 + testcalshims.h cleanup + + tests/libntp/run-test-a_md5encrypt.c@1.6 +5 -5 + testcalshims.h cleanup + + tests/libntp/run-test-atoint.c@1.5 +6 -6 + testcalshims.h cleanup + + tests/libntp/run-test-atouint.c@1.5 +5 -5 + testcalshims.h cleanup + + tests/libntp/run-test-authkeys.c@1.6 +6 -6 + testcalshims.h cleanup + + tests/libntp/run-test-hextoint.c@1.5 +5 -5 + testcalshims.h cleanup + + tests/libntp/run-test-lfpfunc.c@1.6 +9 -9 + testcalshims.h cleanup + + tests/libntp/run-test-numtoa.c@1.5 +2 -2 + testcalshims.h cleanup + + tests/libntp/run-test-numtohost.c@1.5 +1 -1 + testcalshims.h cleanup + + tests/libntp/run-test-statestr.c@1.5 +4 -4 + testcalshims.h cleanup + + tests/libntp/run-test-ymd2yd.c@1.5 +4 -4 + testcalshims.h cleanup + + tests/libntp/statestr.c@1.3 +6 -5 + testcalshims.h cleanup + + tests/libntp/testcalshims.c@1.4 +4 -1 + testcalshims.h cleanup + + tests/libntp/uglydate.c@1.4 +4 -4 + testcalshims.h cleanup + + tests/libntp/ymd2yd.c@1.3 +5 -1 + testcalshims.h cleanup + +ChangeSet@1.3370.1.2, 2015-06-12 16:39:36+05:30, loki@dadasgift.(none) + Makefile.am modified for octotint.c file + + tests/libntp/Makefile.am@1.55 +20 -2 + +ChangeSet@1.3382, 2015-06-12 10:53:55+00:00, stenn@psp-fb1.ntp.org + md5encrypt tests need current_time + + tests/libntp/a_md5encrypt.c@1.4 +2 -0 + md5encrypt tests need current_time + + tests/libntp/run-test-a_md5encrypt.c@1.5 +5 -5 + md5encrypt tests need current_time + +ChangeSet@1.3370.1.1, 2015-06-12 15:50:51+05:30, loki@dadasgift.(none) + octtoint.cpp converted to unity framework + + tests/libntp/g_octtoint.cpp@1.1 +57 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/g_octtoint.cpp + + tests/libntp/g_octtoint.cpp@1.0 +0 -0 + + tests/libntp/octtoint.c@1.1 +63 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/octtoint.c + + tests/libntp/octtoint.c@1.0 +0 -0 + + tests/libntp/run-test-octtoint.c@1.1 +60 -0 + BitKeeper file /home/loki/ntp_gsoc/2_damir_code/ntp-stable-unity/tests/libntp/run-test-octtoint.c + + tests/libntp/run-test-octtoint.c@1.0 +0 -0 + +ChangeSet@1.3345.1.11, 2015-06-12 10:14:37+00:00, stenn@psp-at1.ntp.org + sntp/unity/Makefile.am: Use default AUTOMAKE_OPTIONS + + sntp/unity/Makefile.am@1.3.1.1 +1 -1 + sntp/unity/Makefile.am: Use default AUTOMAKE_OPTIONS + +ChangeSet@1.3379, 2015-06-12 09:58:12+00:00, stenn@psp-at1.ntp.org + EOL cleanup + + sntp/unity/unity_internals.h@1.3 +4 -4 + EOL cleanup + +ChangeSet@1.3378, 2015-06-12 09:29:49+00:00, stenn@psp-at1.ntp.org + Distribute unity/auto/ + + sntp/Makefile.am@1.82 +1 -0 + Distribute unity/auto/ + +ChangeSet@1.3377, 2015-06-12 11:27:01+02:00, viperus@ubuntu.(none) + authkeys.c: + added code which runs init_auth() only in the 1st setUp, prevents segfault + generate_test_runner.rb: + removed init_lib() and init_auth() from here. Put it into setUp() in the test, but it should be run only once + + sntp/unity/auto/generate_test_runner.rb@1.5 +3 -2 + removed init_lib() and init_auth() from here. Put it into setUp() in the test, but it should be run only once + + tests/libntp/authkeys.c@1.5 +6 -2 + added code which runs init_auth() only in the 1st setUp, prevents segfault + + tests/libntp/run-test-a_md5encrypt.c@1.4 +0 -2 + + tests/libntp/run-test-atoint.c@1.4 +0 -2 + + tests/libntp/run-test-atouint.c@1.4 +0 -2 + + tests/libntp/run-test-authkeys.c@1.5 +6 -8 + + tests/libntp/run-test-hextoint.c@1.4 +0 -2 + + tests/libntp/run-test-lfpfunc.c@1.5 +0 -2 + + tests/libntp/run-test-modetoa.c@1.6 +0 -2 + + tests/libntp/run-test-numtoa.c@1.4 +0 -2 + + tests/libntp/run-test-numtohost.c@1.4 +0 -2 + + tests/libntp/run-test-statestr.c@1.4 +0 -2 + + tests/libntp/run-test-uglydate.c@1.5 +0 -2 + + tests/libntp/run-test-ymd2yd.c@1.4 +0 -2 + +ChangeSet@1.3376, 2015-06-12 11:14:36+02:00, viperus@ubuntu.(none) + test-libntp.c: + removed stuff that was placed elsewhere + + tests/libntp/run-test-a_md5encrypt.c@1.3 +2 -0 + + tests/libntp/run-test-atoint.c@1.3 +2 -0 + + tests/libntp/run-test-atouint.c@1.3 +2 -0 + + tests/libntp/run-test-authkeys.c@1.4 +8 -8 + + tests/libntp/run-test-hextoint.c@1.3 +2 -0 + + tests/libntp/run-test-lfpfunc.c@1.4 +2 -0 + + tests/libntp/run-test-modetoa.c@1.5 +2 -0 + + tests/libntp/run-test-numtoa.c@1.3 +2 -0 + + tests/libntp/run-test-numtohost.c@1.3 +2 -0 + + tests/libntp/run-test-statestr.c@1.3 +2 -0 + + tests/libntp/run-test-uglydate.c@1.4 +2 -0 + + tests/libntp/run-test-ymd2yd.c@1.3 +2 -0 + + tests/libntp/test-libntp.c@1.3 +5 -3 + removed stuff that was placed elsewhere + +ChangeSet@1.3375, 2015-06-12 10:50:27+02:00, viperus@ubuntu.(none) + generate_test_runner.rb: + test runners main() will always call init_lib() and init_auth() + + sntp/unity/auto/generate_test_runner.rb@1.4 +2 -1 + test runners main() will always call init_lib() and init_auth() + + tests/libntp/authkeys.c@1.4 +3 -1 + +ChangeSet@1.3374, 2015-06-12 10:37:47+02:00, viperus@ubuntu.(none) + updating autogenerated testrunners with progname = argv[0] + + tests/libntp/run-test-a_md5encrypt.c@1.2 +9 -6 + + tests/libntp/run-test-atoint.c@1.2 +10 -7 + + tests/libntp/run-test-atouint.c@1.2 +9 -6 + + tests/libntp/run-test-authkeys.c@1.3 +6 -3 + + tests/libntp/run-test-hextoint.c@1.2 +9 -6 + + tests/libntp/run-test-lfpfunc.c@1.3 +15 -8 + + tests/libntp/run-test-modetoa.c@1.4 +6 -3 + + tests/libntp/run-test-numtoa.c@1.2 +6 -3 + + tests/libntp/run-test-numtohost.c@1.2 +5 -2 + + tests/libntp/run-test-statestr.c@1.2 +8 -5 + + tests/libntp/run-test-uglydate.c@1.3 +5 -2 + + tests/libntp/run-test-ymd2yd.c@1.2 +8 -5 + +ChangeSet@1.3373, 2015-06-12 10:33:08+02:00, viperus@ubuntu.(none) + testcalshims.h: + also removed progname and current_time var + testcalshims.c: + removed progname and current_time var + + tests/libntp/authkeys.c@1.3 +3 -1 + + tests/libntp/testcalshims.c@1.3 +2 -2 + removed progname and current_time var + + tests/libntp/testcalshims.h@1.3 +2 -2 + also removed progname and current_time var + +ChangeSet@1.3372, 2015-06-12 10:14:36+02:00, viperus@ubuntu.(none) + generate_test_runner.rb: + Added progname = argv[0] in main() function of each runner. + + sntp/unity/auto/generate_test_runner.rb@1.3 +8 -1 + Added progname = argv[0] in main() function of each runner. + +ChangeSet@1.3371, 2015-06-12 06:25:21+00:00, viperus@psp-at1.ntp.org + removed the outdated functions made purely for testing unity + + tests/bug-2803/Makefile.am@1.9 +3 -3 + + tests/bug-2803/run-bug-2803.c@1.2 +4 -2 + + tests/bug-2803/ut-2803.c@1.2 +1 -12 + +ChangeSet@1.3369, 2015-06-11 23:00:26+02:00, viperus@ubuntu.(none) + manually merged a few lines in tests/bug-2803/Makefile.am + + tests/bug-2803/Makefile.am@1.8 +6 -2 + +ChangeSet@1.3345.1.9, 2015-06-11 20:01:57+00:00, stenn@psp-at1.ntp.org + test/Makefile.am DIST_SUBDIRS cleanup + + tests/Makefile.am@1.9 +7 -0 + test/Makefile.am DIST_SUBDIRS cleanup + +ChangeSet@1.3345.1.8, 2015-06-11 19:00:08+00:00, stenn@psp-at1.ntp.org + Fix a typo in tests/libntp/modetoa.c + + tests/libntp/modetoa.c@1.1.1.1 +1 -1 + Fix a typo in tests/libntp/modetoa.c + +ChangeSet@1.3367, 2015-06-11 20:50:24+02:00, viperus@ubuntu.(none) + finished this test, changed TEST_ASSERT_DOUBLE_WITHIN(...) as jnperlin suggested + + tests/libntp/lfpfunc.c@1.3 +158 -237 + +ChangeSet@1.3345.1.7, 2015-06-11 18:48:46+00:00, stenn@psp-at1.ntp.org + Updates to tests/libntp/ + + tests/libntp/run-test-libntp.c@1.2 +2 -2 + Updates to tests/libntp/ + + tests/libntp/test-libntp.c@1.2 +9 -1 + Updates to tests/libntp/ + +ChangeSet@1.3326.12.3, 2015-06-11 20:08:33+02:00, jnperlin@hydra.(none) + [Bug 2843] make check fails on 4.3.36 + Fixed compiler warnings about numeric range overflow (The original topic was fixed in a byplay to bug#2830) + + ChangeLog@1.1641.10.3 +3 -0 + [Bug 2843] make check fails on 4.3.36 + Fixed compiler warnings about numeric range overflow (The original topic was fixed in a byplay to bug#2830) + + tests/ntpd/leapsec.cpp@1.14 +21 -21 + [Bug 2843] make check fails on 4.3.36 + Fixed compiler warnings about numeric range overflow (The original topic was fixed in a byplay to bug#2830) + +ChangeSet@1.3345.1.6, 2015-06-11 17:55:32+00:00, stenn@psp-at1.ntp.org + tests/bug-2803/Makefile.am must distribute bug-2803.h + + ChangeLog@1.1648.1.5 +1 -0 + tests/bug-2803/Makefile.am must distribute bug-2803.h + + tests/bug-2803/Makefile.am@1.7 +1 -0 + tests/bug-2803/Makefile.am must distribute bug-2803.h + +ChangeSet@1.3345.1.5, 2015-06-11 17:54:00+00:00, stenn@psp-at1.ntp.org + sntp/libpkgver belongs in EXTRA_DIST, not DIST_SUBDIRS + + ChangeLog@1.1648.1.4 +1 -0 + sntp/libpkgver belongs in EXTRA_DIST, not DIST_SUBDIRS + + sntp/Makefile.am@1.81 +2 -1 + sntp/libpkgver belongs in EXTRA_DIST, not DIST_SUBDIRS + +ChangeSet@1.3326.12.2, 2015-06-10 22:23:44-04:00, stenn@deacon.udel.edu + Typo: Bug 2887 -> Bug 2778 + + ChangeLog@1.1641.10.2 +1 -1 + Typo: Bug 2887 -> Bug 2778 + +ChangeSet@1.3366, 2015-06-10 13:09:48+02:00, viperus@ubuntu.(none) + minor change in testrunner + + tests/libntp/run-test-lfpfunc.c@1.2 +9 -5 + +ChangeSet@1.3365, 2015-06-10 13:08:39+02:00, viperus@ubuntu.(none) + + Makefile.am: + added -DUNITY_DOUBLE_INCLUDE to CFLAGS, so I don't get linker errors anymore (because asserting double is disabled by default in unity) + + Makefile.am: (/tests/libntp/Makefile.am) + added -DUNITY.... to makefile when building lfpfunc.c. Maybe I should add -DUNITY... to CFLAGS_unity or something like that' + lfpfunc.c: + converted more tests + + + sntp/unity/Makefile.am@1.2.1.1 +4 -0 + added -DUNITY_DOUBLE_INCLUDE to CFLAGS, so I don't get linker errors anymore (because asserting double is disabled by default in unity) + + tests/libntp/Makefile.am@1.54 +2 -1 + 'added -DUNITY.... to makefile when building lfpfunc.c. Maybe I should add -DUNITY... to CFLAGS_unity or something like that' + + tests/libntp/lfpfunc.c@1.2 +72 -80 + 'added -DUNITY.... to makefile when building lfpfunc.c. Maybe I should add -DUNITY... to CFLAGS_unity or somethign like that' + +ChangeSet@1.3326.12.1, 2015-06-10 10:52:55+00:00, stenn@psp-at1.ntp.org + [Bug 2778] Implement "apeers" ntpq command to include associd + + ChangeLog@1.1641.10.1 +1 -0 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/invoke-ntpq.texi@1.500 +11 -1 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq-opts.c@1.517 +1 -1 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq-opts.def@1.26 +8 -0 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq-opts.h@1.515 +1 -1 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq-subs.c@1.105.1.1 +140 -2 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq.1ntpqman@1.328 +15 -4 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq.1ntpqmdoc@1.328 +10 -2 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq.man.in@1.328 +15 -4 + [Bug 2778] Implement "apeers" ntpq command to include associd + + ntpq/ntpq.mdoc.in@1.328 +10 -2 + [Bug 2778] Implement "apeers" ntpq command to include associd + +ChangeSet@1.3364, 2015-06-10 10:21:01+02:00, viperus@ubuntu.(none) + Makefile.am: + Added LIBM in LDADD. + + tests/libntp/Makefile.am@1.53 +30 -10 + Added LIBM in LDADD. + +ChangeSet@1.3326.7.16, 2015-06-09 23:58:56+02:00, jnperlin@nemesis.localnet + [Bug 2845] Harden memory allocation in ntpd + implement and use 'eallocarray(...)' where appropriate + + ChangeLog@1.1641.7.12 +1 -0 + [Bug 2845] Harden memory allocation in ntpd + implement and use 'eallocarray(...)' where appropriate + + include/ntp_stdlib.h@1.78 +19 -10 + [Bug 2845] Harden memory allocation in ntpd + add 'oreallocarray()' prototypes and the macros 'eallocarray' and 'ereallocarray' + use proper parentheses in allocation macro expansions + + libntp/emalloc.c@1.18 +53 -0 + [Bug 2845] Harden memory allocation in ntpd + add 'oreallocarry()' implementation + + ntpd/ntp_config.c@1.327 +4 -3 + [Bug 2845] Harden memory allocation in ntpd + use 'eallocarray(...)' where appropriate + + ntpd/ntp_crypto.c@1.179 +2 -2 + [Bug 2845] Harden memory allocation in ntpd + use 'eallocarray(...)' where appropriate + + ntpd/ntp_monitor.c@1.42 +1 -1 + [Bug 2845] Harden memory allocation in ntpd + use 'eallocarray(...)' where appropriate + + ntpq/ntpq-subs.c@1.106 +1 -1 + [Bug 2845] Harden memory allocation in ntpd + use 'eallocarray(...)' where appropriate + + sntp/kod_management.c@1.33 +2 -2 + [Bug 2845] Harden memory allocation in ntpd + use 'eallocarray(...)' where appropriate + +ChangeSet@1.3363, 2015-06-08 10:29:19+02:00, viperus@ubuntu.(none) + added incomplete test for lfpfunc.c. Changes to makefile and created c_timestructs.c and .h, because timestructs.cpp is a big c++ wrapper. Slowly converting it all to C code + + tests/libntp/c_timestructs.c@1.1 +155 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/c_timestructs.c + + tests/libntp/c_timestructs.c@1.0 +0 -0 + + tests/libntp/c_timestructs.h@1.1 +213 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/c_timestructs.h + + tests/libntp/c_timestructs.h@1.0 +0 -0 + + tests/libntp/g_lfpfunc.cpp@1.3 +0 -0 + Rename: tests/libntp/lfpfunc.cpp -> tests/libntp/g_lfpfunc.cpp + + tests/libntp/lfpfunc.c@1.1 +643 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/lfpfunc.c + + tests/libntp/lfpfunc.c@1.0 +0 -0 + + tests/libntp/run-test-lfpfunc.c@1.1 +56 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-lfpfunc.c + + tests/libntp/run-test-lfpfunc.c@1.0 +0 -0 + +ChangeSet@1.3326.7.15, 2015-06-07 21:20:28-04:00, stenn@deacon.udel.edu + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + + ntpd/ntp_timer.c@1.87 +10 -0 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + +ChangeSet@1.3326.7.14, 2015-06-07 23:11:26+02:00, jnperlin@hydra.(none) + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + - add changelog entry + - add ASSERTS to ntp_crypto.c for length of signature + + ChangeLog@1.1641.7.11 +4 -0 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + - add missing entries + + ntpd/ntp_crypto.c@1.178 +34 -11 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + - add asserts to signature length code + +ChangeSet@1.3362, 2015-06-07 17:14:49+02:00, viperus@ubuntu.(none) + removed some spaces from Makefile.am, removed init_auth from setUp, because every test was calling it. Added init_auth inside run-test-authkeys.c. This is aproblem because I had to modify an autogenerated file! + + tests/libntp/Makefile.am@1.52 +1 -4 + + tests/libntp/authkeys.c@1.2 +2 -0 + + tests/libntp/run-test-authkeys.c@1.2 +8 -6 + +ChangeSet@1.3361, 2015-06-07 13:22:51+00:00, viperus@psp-at1.ntp.org + loaded math lib for some tests so building works on psp-at1 and psp-fb1 + + tests/libntp/Makefile.am@1.51 +7 -1 + +ChangeSet@1.3360, 2015-06-07 15:09:23+02:00, viperus@ubuntu.(none) + re-enabled a_md5encrypt test + + tests/libntp/Makefile.am@1.50 +1 -2 + +ChangeSet@1.3359, 2015-06-07 15:04:05+02:00, viperus@ubuntu.(none) + temporarily removed #test-a_md5encrypt due to log10, linking with math lib + + tests/libntp/Makefile.am@1.49 +2 -1 + +ChangeSet@1.3358, 2015-06-07 14:39:28+02:00, viperus@ubuntu.(none) + added new includes in all files + + tests/libntp/a_md5encrypt.c@1.3 +3 -3 + + tests/libntp/atoint.c@1.2 +1 -0 + + tests/libntp/atouint.c@1.2 +2 -1 + + tests/libntp/hextoint.c@1.2 +2 -1 + + tests/libntp/modetoa.c@1.3 +1 -0 + + tests/libntp/numtoa.c@1.2 +2 -1 + + tests/libntp/numtohost.c@1.2 +2 -1 + + tests/libntp/statestr.c@1.2 +2 -1 + + tests/libntp/uglydate.c@1.3 +1 -1 + + tests/libntp/ymd2yd.c@1.2 +1 -0 + +ChangeSet@1.3357, 2015-06-07 14:31:53+02:00, viperus@ubuntu.(none) + removed a minor makefile bug, put added new include in uglydate.c + + tests/libntp/Makefile.am@1.48 +0 -1 + + tests/libntp/uglydate.c@1.2 +1 -0 + +ChangeSet@1.3356, 2015-06-07 11:37:45+02:00, viperus@ubuntu.(none) + for some reason this file isnt available on psp-deb1 + + tests/libntp/a_md5encrypt.c@1.2 +1 -0 + +ChangeSet@1.3326.11.2, 2015-06-07 11:25:17+02:00, jnperlin@hydra.(none) + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + - fix test case that got damaged by changes to TAI table limit logic + + tests/ntpd/leapsec.cpp@1.13 +6 -2 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + - fix test case that got damaged by changes to TAI table limit logic + +ChangeSet@1.3355, 2015-06-07 11:02:10+02:00, viperus@ubuntu.(none) + adding new test files and their runners + + tests/libntp/a_md5encrypt.c@1.1 +98 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/a_md5encrypt.c + + tests/libntp/a_md5encrypt.c@1.0 +0 -0 + + tests/libntp/atouint.c@1.1 +40 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/atouint.c + + tests/libntp/atouint.c@1.0 +0 -0 + + tests/libntp/authkeys.c@1.1 +107 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/authkeys.c + + tests/libntp/authkeys.c@1.0 +0 -0 + + tests/libntp/run-test-a_md5encrypt.c@1.1 +56 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-a_md5encrypt.c + + tests/libntp/run-test-a_md5encrypt.c@1.0 +0 -0 + + tests/libntp/run-test-atouint.c@1.1 +56 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-atouint.c + + tests/libntp/run-test-atouint.c@1.0 +0 -0 + + tests/libntp/run-test-authkeys.c@1.1 +58 -0 + BitKeeper file /home/viperus/Desktop/ntp-stable-unity/tests/libntp/run-test-authkeys.c + + tests/libntp/run-test-authkeys.c@1.0 +0 -0 + +ChangeSet@1.3353, 2015-06-07 10:51:34+02:00, viperus@ubuntu.(none) + forgot to ci a few files + + tests/libntp/Makefile.am@1.47 +51 -4 + + tests/libntp/testcalshims.c@1.2 +7 -3 + + tests/libntp/testcalshims.h@1.2 +7 -3 + +ChangeSet@1.3352, 2015-06-07 10:30:09+02:00, viperus@ubuntu.(none) + modified testcalshims.h to suppoer md5encrypt.c and authkeys.c , added new tests, and modified Makefile.am + + tests/libntp/g_a_md5encrypt.cpp@1.6 +0 -0 + Rename: tests/libntp/a_md5encrypt.cpp -> tests/libntp/g_a_md5encrypt.cpp + + tests/libntp/g_atouint.cpp@1.2 +0 -0 + Rename: tests/libntp/atouint.cpp -> tests/libntp/g_atouint.cpp + + tests/libntp/g_authkeys.cpp@1.8 +0 -0 + Rename: tests/libntp/authkeys.cpp -> tests/libntp/g_authkeys.cpp + +ChangeSet@1.3326.7.12, 2015-06-07 04:00:46-04:00, stenn@deacon.udel.edu + sntp/scripts/genLocInfo: treat raspbian as debian + + ChangeLog@1.1641.7.10 +1 -0 + sntp/scripts/genLocInfo: treat raspbian as debian + + sntp/scripts/genLocInfo@1.18 +8 -0 + sntp/scripts/genLocInfo: treat raspbian as debian + +ChangeSet@1.3326.7.11, 2015-06-07 06:16:41+00:00, stenn@psp-at1.ntp.org + [Bug 2842] Bug in mdoc2man + + ChangeLog@1.1641.7.9 +1 -0 + [Bug 2842] Bug in mdoc2man + + sntp/ag-tpl/Mdoc.pm@1.1 +542 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable/sntp/ag-tpl/Mdoc.pm + + sntp/ag-tpl/Mdoc.pm@1.0 +0 -0 + + sntp/ag-tpl/mdoc2man@1.1 +219 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable/sntp/ag-tpl/mdoc2man + + sntp/ag-tpl/mdoc2man@1.0 +0 -0 + +ChangeSet@1.3326.7.10, 2015-06-07 03:16:04+00:00, stenn@psp-fb1.ntp.org + [Bug 2836] DFC77 patches from Frank Kardel to make decoding more robust, and require 2 consecutive timestamps to be consistent + + ChangeLog@1.1641.7.8 +2 -0 + [Bug 2836] DFC77 patches from Frank Kardel to make decoding more robust, and require 2 consecutive timestamps to be consistent + + libparse/clk_rawdcf.c@1.21 +6 -4 + [Bug 2836] DFC77 patches from Frank Kardel to make decoding more robust, and require 2 consecutive timestamps to be consistent + + libparse/parse.c@1.20 +2 -2 + [Bug 2836] DFC77 patches from Frank Kardel to make decoding more robust, and require 2 consecutive timestamps to be consistent + + ntpd/refclock_parse.c@1.79 +2 -0 + [Bug 2836] DFC77 patches from Frank Kardel to make decoding more robust, and require 2 consecutive timestamps to be consistent + +ChangeSet@1.3351, 2015-06-06 08:38:18+00:00, viperus@psp-deb1.ntp.org + adding new unity test files, changes to Makefile.am + + tests/libntp/Makefile.am@1.46 +119 -15 + + tests/libntp/atoint.c@1.1 +47 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/atoint.c + + tests/libntp/atoint.c@1.0 +0 -0 + + tests/libntp/g_atoint.cpp@1.3 +0 -0 + Rename: tests/libntp/atoint.cpp -> tests/libntp/g_atoint.cpp + + tests/libntp/g_hextoint.cpp@1.4 +0 -0 + Rename: tests/libntp/hextoint.cpp -> tests/libntp/g_hextoint.cpp + + tests/libntp/g_numtoa.cpp@1.3 +0 -0 + Rename: tests/libntp/numtoa.cpp -> tests/libntp/g_numtoa.cpp + + tests/libntp/g_numtohost.cpp@1.2 +0 -0 + Rename: tests/libntp/numtohost.cpp -> tests/libntp/g_numtohost.cpp + + tests/libntp/g_statestr.cpp@1.3 +1 -0 + + tests/libntp/g_statestr.cpp@1.2 +0 -0 + Rename: tests/libntp/statestr.cpp -> tests/libntp/g_statestr.cpp + + tests/libntp/g_ymd2yd.cpp@1.2 +0 -0 + Rename: tests/libntp/ymd2yd.cpp -> tests/libntp/g_ymd2yd.cpp + + tests/libntp/hextoint.c@1.1 +44 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/hextoint.c + + tests/libntp/hextoint.c@1.0 +0 -0 + + tests/libntp/modetoa.c@1.2 +2 -3 + + tests/libntp/numtoa.c@1.1 +27 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/numtoa.c + + tests/libntp/numtoa.c@1.0 +0 -0 + + tests/libntp/numtohost.c@1.1 +16 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/numtohost.c + + tests/libntp/numtohost.c@1.0 +0 -0 + + tests/libntp/run-test-atoint.c@1.1 +58 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-atoint.c + + tests/libntp/run-test-atoint.c@1.0 +0 -0 + + tests/libntp/run-test-hextoint.c@1.1 +56 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-hextoint.c + + tests/libntp/run-test-hextoint.c@1.0 +0 -0 + + tests/libntp/run-test-modetoa.c@1.3 +1 -1 + + tests/libntp/run-test-numtoa.c@1.1 +50 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-numtoa.c + + tests/libntp/run-test-numtoa.c@1.0 +0 -0 + + tests/libntp/run-test-numtohost.c@1.1 +48 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-numtohost.c + + tests/libntp/run-test-numtohost.c@1.0 +0 -0 + + tests/libntp/run-test-statestr.c@1.1 +54 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-statestr.c + + tests/libntp/run-test-statestr.c@1.0 +0 -0 + + tests/libntp/run-test-ymd2yd.c@1.1 +54 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-ymd2yd.c + + tests/libntp/run-test-ymd2yd.c@1.0 +0 -0 + + tests/libntp/statestr.c@1.1 +34 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/statestr.c + + tests/libntp/statestr.c@1.0 +0 -0 + + tests/libntp/ymd2yd.c@1.1 +30 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/ymd2yd.c + + tests/libntp/ymd2yd.c@1.0 +0 -0 + +ChangeSet@1.3326.7.9, 2015-06-05 08:24:51+00:00, stenn@psp-at1.ntp.org + [Bug 2837] add test for DSCP to ntpd/complete.conf.in - from Hal Murray + + ChangeLog@1.1641.7.7 +1 -0 + [Bug 2837] add test for DSCP to ntpd/complete.conf.in - from Hal Murray + + ntpd/complete.conf.in@1.28 +1 -0 + [Bug 2837] add test for DSCP to ntpd/complete.conf.in - from Hal Murray + +ChangeSet@1.3326.11.1, 2015-06-05 06:31:07+02:00, jnperlin@hydra.(none) + Bug 2830 - ntpd doesn't always transfer the correct TAI offset via autokey + - trigger a possible autokey update on change of 'sys_tai' + + include/ntpd.h@1.188 +1 -0 + Bug 2830 - ntpd doesn't always transfer the correct TAI offset via autokey + add 'crypto_update_taichange()': update autokey data after TAI change if possible + + ntpd/ntp_crypto.c@1.177 +75 -113 + Bug 2830 - ntpd doesn't always transfer the correct TAI offset via autokey + - add 'crypto_update_taichange()': update autokey data after TAI change if possible + - fix potential problem with signature size + - use DPRINTF where possible + + ntpd/ntp_timer.c@1.86 +7 -1 + Bug 2830 - ntpd doesn't always transfer the correct TAI offset via autokey + possibly update autokey data after 'sys_tai' changes + +ChangeSet@1.3326.7.8, 2015-06-05 02:42:26+00:00, stenn@psp-at1.ntp.org + 2830 fixes from Pearly + + ChangeLog@1.1641.7.6 +3 -0 + 2830 fixes from Pearly + +ChangeSet@1.3326.8.10, 2015-06-04 19:39:40+00:00, stenn@psp-at1.ntp.org + [Bug 2842] Glitch in ntp.conf.def documentation stanza + + ChangeLog@1.1641.8.9 +1 -0 + [Bug 2842] Glitch in ntp.conf.def documentation stanza + + ntpd/invoke-ntp.conf.texi@1.184 +3 -3 + [Bug 2842] Glitch in ntp.conf.def documentation stanza + + ntpd/ntp.conf.5man@1.218 +6 -6 + [Bug 2842] Glitch in ntp.conf.def documentation stanza + + ntpd/ntp.conf.5mdoc@1.218 +4 -4 + [Bug 2842] Glitch in ntp.conf.def documentation stanza + + ntpd/ntp.conf.def@1.16 +2 -2 + [Bug 2842] Glitch in ntp.conf.def documentation stanza + + ntpd/ntp.conf.man.in@1.218 +6 -6 + [Bug 2842] Glitch in ntp.conf.def documentation stanza + + ntpd/ntp.conf.mdoc.in@1.218 +4 -4 + [Bug 2842] Glitch in ntp.conf.def documentation stanza + +ChangeSet@1.3326.10.2, 2015-06-04 03:24:16-04:00, stenn@deacon.udel.edu + [Bug 2824] Convert update-leap to perl. (also see 2769) + + configure.ac@1.588.1.1 +1 -0 + [Bug 2824] Convert update-leap to perl. (also see 2769) + + scripts/update-leap/update-leap.in@1.2 +2 -3 + [Bug 2824] Convert update-leap to perl. (also see 2769) + +ChangeSet@1.3326.10.1, 2015-06-04 03:21:27-04:00, stenn@deacon.udel.edu + [Bug 2837] Allow a configurable DSCP value + + ntpd/keyword-gen-utd@1.23 +1 -1 + [Bug 2837] Allow a configurable DSCP value + + ntpd/ntp_keyword.h@1.25 +842 -838 + [Bug 2837] Allow a configurable DSCP value + + ntpd/ntp_parser.c@1.93 +1074 -1060 + [Bug 2837] Allow a configurable DSCP value + + ntpd/ntp_parser.h@1.58 +320 -318 + [Bug 2837] Allow a configurable DSCP value + +ChangeSet@1.3326.8.8, 2015-06-04 03:14:37+00:00, stenn@psp-fb1.ntp.org + Report select() debug messages at debug level 3 now + + ChangeLog@1.1641.8.8 +1 -1 + Report select() debug messages at debug level 3 now + +ChangeSet@1.3326.8.7, 2015-06-03 17:04:21+02:00, martin@pc-martin.(none) + Increased the debug level at which a tiny debug message is printed. + + ChangeLog@1.1641.8.7 +1 -0 + Increased the debug level at which a tiny debug message is printed. + + ntpd/ntp_io.c@1.399.1.2 +1 -1 + Increased the debug level at which a tiny debug message is printed. + +ChangeSet@1.3326.8.6, 2015-06-03 09:30:35+00:00, stenn@psp-at1.ntp.org + [Bug 2837] Allow a configurable DSCP value + + ChangeLog@1.1641.8.6 +2 -1 + [Bug 2837] Allow a configurable DSCP value + + html/miscopt.html@1.81 +2 -0 + [Bug 2837] Allow a configurable DSCP value + + include/ntp_io.h@1.22 +1 -0 + [Bug 2837] Allow a configurable DSCP value + + ntpd/keyword-gen.c@1.29 +1 -0 + [Bug 2837] Allow a configurable DSCP value + + ntpd/ntp_config.c@1.326 +8 -1 + [Bug 2837] Allow a configurable DSCP value + + ntpd/ntp_io.c@1.399.1.1 +5 -5 + [Bug 2837] Allow a configurable DSCP value + + ntpd/ntp_parser.y@1.85 +13 -0 + [Bug 2837] Allow a configurable DSCP value + +ChangeSet@1.3326.8.5, 2015-06-03 03:46:57-04:00, stenn@deacon.udel.edu + ChangeLog cleanup + + ChangeLog@1.1641.8.5 +2 -2 + ChangeLog cleanup + +ChangeSet@1.3326.8.3, 2015-06-03 05:39:07+00:00, stenn@psp-at1.ntp.org + ChangeLog order cleanup + + ChangeLog@1.1641.8.3 +2 -2 + ChangeLog order cleanup + +ChangeSet@1.3326.9.2, 2015-06-03 01:07:20-04:00, stenn@deacon.udel.edu + update-leap conversion is bug 2824, not 2769 + + ChangeLog@1.1641.9.2 +1 -1 + update-leap conversion is bug 2824, not 2769 + +ChangeSet@1.3326.7.6, 2015-06-02 09:11:10+02:00, jnperlin@hydra.(none) + Bug 2830 - ntpd doesn't always transfer the correct TAI offset via autokey + fix a few bad ideas and missing links + + ntpd/ntp_crypto.c@1.176 +34 -39 + Bug 2830 - ntpd doesn't always transfer the correct TAI offset via autokey + - fix the autokey TAI data block (initial value, never omit data) + + ntpd/ntp_leapsec.c@1.21 +25 -16 + Bug 2830 - ntpd doesn't always transfer the correct TAI offset via autokey + - loading the leap frame should always copy the data (not just after the close monitoring time) + - loading the table data via build time limit keeps the last 10 years before build data + - lstostr() should return 'const char*' + +ChangeSet@1.3345.1.1, 2015-06-01 10:42:57+00:00, stenn@psp-fb1.ntp.org + add unity_fixture to the unity library + + sntp/unity/Makefile.am@1.3 +9 -5 + add unity_fixture to the unity library + + sntp/unity/unity_fixture.c@1.1 +398 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity_fixture.c + + sntp/unity/unity_fixture.c@1.0 +0 -0 + + sntp/unity/unity_fixture.h@1.1 +86 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity_fixture.h + + sntp/unity/unity_fixture.h@1.0 +0 -0 + + sntp/unity/unity_fixture_internals.h@1.1 +44 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity_fixture_internals.h + + sntp/unity/unity_fixture_internals.h@1.0 +0 -0 + + sntp/unity/unity_fixture_malloc_overrides.h@1.1 +21 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity_fixture_malloc_overrides.h + + sntp/unity/unity_fixture_malloc_overrides.h@1.0 +0 -0 + +ChangeSet@1.3326.7.5, 2015-06-01 07:24:52+02:00, jnperlin@hydra.(none) + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTPD transfers the current TAI (instead of an announcement) now. This might still needed improvement. + + ChangeLog@1.1641.7.4 +2 -3 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTPD transfers the current TAI (instead of an announcement) now. This might still needed improvement. + + ntpd/ntp_crypto.c@1.175 +55 -34 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + transmit/receive the current leap era instead of of the latest announcement in autokey packets + + ntpd/ntp_leapsec.c@1.20 +116 -1 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + Support adjustment of transmitting the current TAI offset via autokey. + Needs support to shift the table values in absence of fixed entries. + + ntpd/ntp_leapsec.h@1.10 +42 -5 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + Support adjustment of transmitting the current TAI offset via autokey. + Needs support to shift the table values in absence of fixed entries. + + tests/ntpd/leapsec.cpp@1.12 +82 -5 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + Test processing of TAI offset shifts as used by autokey + +ChangeSet@1.3326.9.1, 2015-05-30 07:19:56+00:00, stenn@psp-fb1.ntp.org + [Bug 2769] Convert update-leap to perl + + ChangeLog@1.1641.9.1 +3 -0 + [Bug 2769] Convert update-leap to perl + + scripts/update-leap/Makefile.am@1.4 +2 -1 + [Bug 2769] Convert update-leap to perl + + scripts/update-leap/update-leap.in@1.1 +425 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable/scripts/update-leap/update-leap.in + + scripts/update-leap/update-leap.in@1.0 +0 -0 + + scripts/update-leap/update-leap.sh@1.2 +0 -0 + Rename: scripts/update-leap/update-leap -> scripts/update-leap/update-leap.sh + +ChangeSet@1.3350, 2015-05-27 09:51:28+00:00, viperus@psp-deb1.ntp.org + modified the ruby testRunner generator, so the test prints filesnames properly. ALSO, run-test-name.c files dont rebuild after I modify the ruby code + + sntp/unity/auto/generate_test_runner.rb@1.2 +2 -1 + + tests/libntp/run-test-modetoa.c@1.2 +1 -1 + + tests/libntp/run-test-uglydate.c@1.2 +1 -1 + +ChangeSet@1.3349, 2015-05-27 08:40:02+00:00, viperus@psp-deb1.ntp.org + added run-testmodeto.c and run-test.uglydate.c + + tests/libntp/run-test-modetoa.c@1.1 +50 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-modetoa.c + + tests/libntp/run-test-modetoa.c@1.0 +0 -0 + + tests/libntp/run-test-uglydate.c@1.1 +48 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-uglydate.c + + tests/libntp/run-test-uglydate.c@1.0 +0 -0 + +ChangeSet@1.3348, 2015-05-27 08:38:25+00:00, viperus@psp-deb1.ntp.org + modified makefile to work with multiple tests + + tests/libntp/Makefile.am@1.45 +45 -6 + +ChangeSet@1.3347, 2015-05-26 10:15:06+00:00, viperus@psp-deb1.ntp.org + ut-2803.c: + Removed unncessary include. + + tests/sandbox/ut-2803.c@1.3 +1 -1 + Removed unncessary include. + +ChangeSet@1.3346, 2015-05-26 10:11:49+00:00, viperus@psp-deb1.ntp.org + making better sandbox examples + + tests/sandbox/Makefile.am@1.2 +22 -5 + makefile now builds 3 seperate tests + + tests/sandbox/ut-2803.c@1.2 +44 -5 + added more test examples + +ChangeSet@1.3345, 2015-05-26 09:36:31+00:00, viperus@psp-deb1.ntp.org + we want to build tests/libntp even if no GTEST + + tests/Makefile.am@1.8 +8 -6 + we want to build tests/libntp even if no GTEST + + tests/libntp/Makefile.am@1.44 +6 -1 + we want to build tests/libntp even if no GTEST + +ChangeSet@1.3344, 2015-05-26 09:31:22+00:00, viperus@psp-deb1.ntp.org + added run-test-libntp.c + + tests/libntp/run-test-libntp.c@1.1 +50 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/run-test-libntp.c + + tests/libntp/run-test-libntp.c@1.0 +0 -0 + +ChangeSet@1.3343, 2015-05-26 09:23:18+00:00, viperus@psp-deb1.ntp.org + probably commited changes to tests/libntp/Makefile.am + + tests/libntp/Makefile.am@1.43 +44 -11 + modified makefile. + +ChangeSet@1.3342, 2015-05-26 09:13:23+00:00, viperus@psp-deb1.ntp.org + added more files to libntp/ and added some autogenerated tests to sandbox so other people can see how do they lok like. + + tests/libntp/g_modetoa.cpp@1.2 +0 -0 + Rename: tests/libntp/modetoa.cpp -> tests/libntp/g_modetoa.cpp + + tests/libntp/g_uglydate.cpp@1.3 +0 -0 + Rename: tests/libntp/uglydate.cpp -> tests/libntp/g_uglydate.cpp + + tests/libntp/modetoa.c@1.1 +20 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/modetoa.c + + tests/libntp/modetoa.c@1.0 +0 -0 + + tests/libntp/test-libntp.c@1.1 +29 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/test-libntp.c + + tests/libntp/test-libntp.c@1.0 +0 -0 + + tests/libntp/test-libntp.h@1.1 +6 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/test-libntp.h + + tests/libntp/test-libntp.h@1.0 +0 -0 + + tests/libntp/testcalshims.c@1.1 +27 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/testcalshims.c + + tests/libntp/testcalshims.c@1.0 +0 -0 + + tests/libntp/testcalshims.h@1.1 +9 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/testcalshims.h + + tests/libntp/testcalshims.h@1.0 +0 -0 + + tests/libntp/uglydate.c@1.1 +16 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/libntp/uglydate.c + + tests/libntp/uglydate.c@1.0 +0 -0 + + tests/sandbox/run-first-test.c@1.1 +48 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/sandbox/run-first-test.c + + tests/sandbox/run-first-test.c@1.0 +0 -0 + + tests/sandbox/run-second-test.c@1.1 +50 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/sandbox/run-second-test.c + + tests/sandbox/run-second-test.c@1.0 +0 -0 + + tests/sandbox/run-ut-2803.c@1.1 +58 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/sandbox/run-ut-2803.c + + tests/sandbox/run-ut-2803.c@1.0 +0 -0 + +ChangeSet@1.3341, 2015-05-26 08:45:31+00:00, viperus@psp-deb1.ntp.org + added a few more files to sandbox/ , updated unity to print FAIL instead of Failure + + tests/sandbox/modetoa.c@1.1 +20 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/sandbox/modetoa.c + + tests/sandbox/modetoa.c@1.0 +0 -0 + + tests/sandbox/uglydate.c@1.1 +16 -0 + BitKeeper file /home/viperus/ntp-stable-unity/tests/sandbox/uglydate.c + + tests/sandbox/uglydate.c@1.0 +0 -0 + +ChangeSet@1.3340, 2015-05-19 10:24:10+00:00, stenn@psp-at1.ntp.org + Unity test framework fixes + + configure.ac@1.592 +1 -1 + Unity test framework fixes + + sntp/configure.ac@1.80 +1 -1 + Unity test framework fixes + + sntp/m4/ntp_unitytest.m4@1.2 +1 -1 + Unity test framework fixes + +ChangeSet@1.3339, 2015-05-19 09:33:10+00:00, stenn@psp-deb1.ntp.org + Unity test framework fixes + + ChangeLog@1.1648 +1 -0 + Unity test framework fixes + + configure.ac@1.591 +3 -0 + Unity test framework fixes + + sntp/configure.ac@1.79 +1 -0 + Unity test framework fixes + + sntp/m4/ntp_unitytest.m4@1.1, stenn@psp-at1.ntp.org +19 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/m4/ntp_unitytest.m4 + + sntp/m4/ntp_unitytest.m4@1.0, stenn@psp-at1.ntp.org +0 -0 + +ChangeSet@1.3338, 2015-05-19 07:22:21+00:00, stenn@psp-at1.ntp.org + Unity framework cleanup + + tests/bug-2803/run-bug-2803.c@1.1 +46 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/run-bug-2803.c + + tests/bug-2803/run-bug-2803.c@1.0 +0 -0 + +ChangeSet@1.3337, 2015-05-18 06:30:54+00:00, viperus@psp-deb1.ntp.org + tests/sandbox cleanup + + BitKeeper/etc/ignore@1.88 +1 -0 + added tests/sandbox/Makefile.in + +ChangeSet@1.3336, 2015-05-18 06:29:35+00:00, viperus@psp-deb1.ntp.org + tests/sandbox cleanup + + BitKeeper/deleted/8f/Makefile.in~199a99ee888869a7@1.2 +0 -0 + Delete: tests/sandbox/Makefile.in + + configure.ac@1.590 +1 -0 + tests/sandbox cleanup + +ChangeSet@1.3335, 2015-05-17 22:30:55+00:00, stenn@psp-at1.ntp.org + Created tests/sandbox/ + + tests/Makefile.am@1.7 +1 -0 + Created tests/sandbox/ + + tests/sandbox/Makefile.am@1.1 +67 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/Makefile.am + + tests/sandbox/Makefile.am@1.0 +0 -0 + + tests/sandbox/Makefile.in@1.1 +1258 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/Makefile.in + + tests/sandbox/Makefile.in@1.0 +0 -0 + + tests/sandbox/bug-2803.c@1.1 +99 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/bug-2803.c + + tests/sandbox/bug-2803.c@1.0 +0 -0 + + tests/sandbox/bug-2803.h@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/bug-2803.h + + tests/sandbox/bug-2803.h@1.0 +0 -0 + + tests/sandbox/run-bug-2803.c@1.1 +46 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/run-bug-2803.c + + tests/sandbox/run-bug-2803.c@1.0 +0 -0 + + tests/sandbox/test-2803.c@1.1 +229 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/test-2803.c + + tests/sandbox/test-2803.c@1.0 +0 -0 + + tests/sandbox/ut-2803.c@1.1 +41 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/sandbox/ut-2803.c + + tests/sandbox/ut-2803.c@1.0 +0 -0 + +ChangeSet@1.3334, 2015-05-17 22:16:38+00:00, stenn@psp-at1.ntp.org + Unity framework improvements + + sntp/unity/auto/colour_prompt.rb@1.1 +94 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/colour_prompt.rb + + sntp/unity/auto/colour_prompt.rb@1.0 +0 -0 + + sntp/unity/auto/colour_reporter.rb@1.1 +39 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/colour_reporter.rb + + sntp/unity/auto/colour_reporter.rb@1.0 +0 -0 + + sntp/unity/auto/generate_config.yml@1.1 +36 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/generate_config.yml + + sntp/unity/auto/generate_config.yml@1.0 +0 -0 + + sntp/unity/auto/generate_module.rb@1.1 +202 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/generate_module.rb + + sntp/unity/auto/generate_module.rb@1.0 +0 -0 + + sntp/unity/auto/generate_test_runner.rb@1.1 +298 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/generate_test_runner.rb + + sntp/unity/auto/generate_test_runner.rb@1.0 +0 -0 + + sntp/unity/auto/runner_maybe.c@1.1 +52 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/runner_maybe.c + + sntp/unity/auto/runner_maybe.c@1.0 +0 -0 + + sntp/unity/auto/test_file_filter.rb@1.1 +23 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/test_file_filter.rb + + sntp/unity/auto/test_file_filter.rb@1.0 +0 -0 + + sntp/unity/auto/unity_test_summary.rb@1.1 +126 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/auto/unity_test_summary.rb + + sntp/unity/auto/unity_test_summary.rb@1.0 +0 -0 + + sntp/unity/unity.c@1.2 +110 -5 + Unity XFAIL patches from Damir Tomic + + sntp/unity/unity_internals.h@1.2 +11 -0 + Unity XFAIL patches from Damir Tomic + + tests/bug-2803/Makefile.am@1.6 +1 -1 + Unity cleanup + + tests/bug-2803/Makefile.am@1.5 +6 -1 + Unity cleanup + +ChangeSet@1.3333, 2015-05-17 06:47:45+00:00, stenn@psp-at1.ntp.org + Initial support for PACKAGE_VERSION tests + + ChangeLog@1.1647 +3 -0 + Initial support for PACKAGE_VERSION tests + + sntp/Makefile.am@1.80 +1 -1 + Added libpkgver + + sntp/libpkgver/colcomp.c@1.2 +2 -2 + import typo fix + + sntp/libpkgver/colcomp.c@1.1, stenn@psp-deb1.ntp.org +135 -0 + BitKeeper file /home/stenn/ntp-stable-unity/sntp/libpkgver/colcomp.c + + sntp/libpkgver/colcomp.c@1.0, stenn@psp-deb1.ntp.org +0 -0 + + sntp/libpkgver/pkgver.h@1.1, stenn@psp-deb1.ntp.org +19 -0 + BitKeeper file /home/stenn/ntp-stable-unity/sntp/libpkgver/pkgver.h + + sntp/libpkgver/pkgver.h@1.0, stenn@psp-deb1.ntp.org +0 -0 + + sntp/unity/Makefile.am@1.2 +1 -0 + Added colcomp.c from libpkgver + +ChangeSet@1.3332, 2015-05-16 08:58:44+00:00, stenn@psp-at1.ntp.org + Updates to bug-2803 tests + + tests/bug-2803/Makefile.am@1.4 +4 -2 + Updates to bug-2803 tests + + tests/bug-2803/TestProductionCode_Runner.c@1.1 +55 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/TestProductionCode_Runner.c + + tests/bug-2803/TestProductionCode_Runner.c@1.0 +0 -0 + + tests/bug-2803/bug-2803.c@1.3 +1 -1 + Updates to bug-2803 tests + + tests/bug-2803/bug-2803.h@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/bug-2803.h + + tests/bug-2803/bug-2803.h@1.0 +0 -0 + + tests/bug-2803/ut-2803.c@1.1 +41 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/ut-2803.c + + tests/bug-2803/ut-2803.c@1.0 +0 -0 + +ChangeSet@1.3326.8.2, 2015-05-16 04:28:40+00:00, abe@psp-deb1.ntp.org + refclock.html, ChangeLog: + [Bug 2834] Correct a broken html tag in html/refclock.html + + ChangeLog@1.1641.8.2 +1 -0 + [Bug 2834] Correct a broken html tag in html/refclock.html + + html/refclock.html@1.45 +1 -1 + [Bug 2834] Correct a broken html tag in html/refclock.html + +ChangeSet@1.3326.8.1, 2015-05-15 11:43:04+00:00, abe@psp-deb1.ntp.org + driver40.html, refclock_jjy.c, driver40-ja.html, ChangeLog: + refclock_jjy.c supports the TDC-300 + + ChangeLog@1.1641.8.1 +1 -0 + refclock_jjy.c supports the TDC-300 + + html/drivers/driver40-ja.html@1.4 +62 -9 + refclock_jjy.c supports the TDC-300 + + html/drivers/driver40.html@1.19 +62 -9 + refclock_jjy.c supports the TDC-300 + + ntpd/refclock_jjy.c@1.29 +253 -1 + refclock_jjy.c supports the TDC-300 + +ChangeSet@1.3326.7.4, 2015-05-14 17:08:20+02:00, jnperlin@hydra.(none) + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTP does *not* transfer the TAI offset, but a leap second announcement. + Handling of these announcements and stepping over leap seconds needed improvement. + + ChangeLog@1.1641.7.3 +4 -0 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTP does *not* transfer the TAI offset, but a leap second announcement. + Handling of these announcements and stepping over leap seconds needed improvement. + + ntpd/ntp_leapsec.c@1.19 +60 -26 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTP does *not* transfer the TAI offset, but a leap second announcement. This needed some more work: + - Extending the expiration date via autokey without a new transition did not work. + - Assuming a positive leap transition at the first leap second helps when starting without leap file. + - Stepping over a leapsecond should not trigger the leap second transition detection. + + tests/ntpd/leapsec.cpp@1.11 +162 -4 + [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + Add/fix test cases to validate the changes to ntp_leapsec.c + +ChangeSet@1.3326.7.3, 2015-05-12 04:35:09-04:00, stenn@deacon.udel.edu + NTP_4_2_8P3_RC1 + TAG: NTP_4_2_8P3_RC1 + + ChangeLog@1.1641.7.2 +1 -0 + NTP_4_2_8P3_RC1 + + ntpd/invoke-ntp.conf.texi@1.183 +1 -1 + NTP_4_2_8P3_RC1 + + ntpd/invoke-ntp.keys.texi@1.179 +1 -1 + NTP_4_2_8P3_RC1 + + ntpd/invoke-ntpd.texi@1.496 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntp.conf.5man@1.217 +3 -3 + NTP_4_2_8P3_RC1 + + ntpd/ntp.conf.5mdoc@1.217 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntp.conf.html@1.174 +1 -1 + NTP_4_2_8P3_RC1 + + ntpd/ntp.conf.man.in@1.217 +3 -3 + NTP_4_2_8P3_RC1 + + ntpd/ntp.conf.mdoc.in@1.217 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntp.keys.5man@1.213 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntp.keys.5mdoc@1.213 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntp.keys.html@1.175 +1 -1 + NTP_4_2_8P3_RC1 + + ntpd/ntp.keys.man.in@1.213 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntp.keys.mdoc.in@1.213 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntpd-opts.c@1.518 +268 -268 + NTP_4_2_8P3_RC1 + + ntpd/ntpd-opts.h@1.517 +3 -3 + NTP_4_2_8P3_RC1 + + ntpd/ntpd.1ntpdman@1.325 +3 -3 + NTP_4_2_8P3_RC1 + + ntpd/ntpd.1ntpdmdoc@1.325 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntpd.html@1.169 +2 -2 + NTP_4_2_8P3_RC1 + + ntpd/ntpd.man.in@1.325 +3 -3 + NTP_4_2_8P3_RC1 + + ntpd/ntpd.mdoc.in@1.325 +2 -2 + NTP_4_2_8P3_RC1 + + ntpdc/invoke-ntpdc.texi@1.493 +2 -2 + NTP_4_2_8P3_RC1 + + ntpdc/ntpdc-opts.c@1.511 +130 -130 + NTP_4_2_8P3_RC1 + + ntpdc/ntpdc-opts.h@1.510 +3 -3 + NTP_4_2_8P3_RC1 + + ntpdc/ntpdc.1ntpdcman@1.324 +3 -3 + NTP_4_2_8P3_RC1 + + ntpdc/ntpdc.1ntpdcmdoc@1.324 +2 -2 + NTP_4_2_8P3_RC1 + + ntpdc/ntpdc.html@1.337 +2 -2 + NTP_4_2_8P3_RC1 + + ntpdc/ntpdc.man.in@1.324 +3 -3 + NTP_4_2_8P3_RC1 + + ntpdc/ntpdc.mdoc.in@1.324 +2 -2 + NTP_4_2_8P3_RC1 + + ntpq/invoke-ntpq.texi@1.499 +5 -3 + NTP_4_2_8P3_RC1 + + ntpq/ntpq-opts.c@1.516 +129 -129 + NTP_4_2_8P3_RC1 + + ntpq/ntpq-opts.h@1.514 +3 -3 + NTP_4_2_8P3_RC1 + + ntpq/ntpq.1ntpqman@1.327 +6 -4 + NTP_4_2_8P3_RC1 + + ntpq/ntpq.1ntpqmdoc@1.327 +5 -3 + NTP_4_2_8P3_RC1 + + ntpq/ntpq.html@1.166 +2 -2 + NTP_4_2_8P3_RC1 + + ntpq/ntpq.man.in@1.327 +6 -4 + NTP_4_2_8P3_RC1 + + ntpq/ntpq.mdoc.in@1.327 +5 -3 + NTP_4_2_8P3_RC1 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.495 +2 -2 + NTP_4_2_8P3_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.513 +91 -91 + NTP_4_2_8P3_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.512 +3 -3 + NTP_4_2_8P3_RC1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.324 +3 -3 + NTP_4_2_8P3_RC1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.324 +2 -2 + NTP_4_2_8P3_RC1 + + ntpsnmpd/ntpsnmpd.html@1.164 +1 -1 + NTP_4_2_8P3_RC1 + + ntpsnmpd/ntpsnmpd.man.in@1.324 +3 -3 + NTP_4_2_8P3_RC1 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.324 +2 -2 + NTP_4_2_8P3_RC1 + + packageinfo.sh@1.511 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.85 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.86 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/calc_tickadj/calc_tickadj.html@1.87 +1 -1 + NTP_4_2_8P3_RC1 + + scripts/calc_tickadj/calc_tickadj.man.in@1.84 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.86 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.89 +1 -1 + NTP_4_2_8P3_RC1 + + scripts/invoke-plot_summary.texi@1.106 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/invoke-summary.texi@1.106 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.316 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntp-wait/ntp-wait-opts@1.52 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.313 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.314 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntp-wait/ntp-wait.html@1.333 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntp-wait/ntp-wait.man.in@1.313 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.314 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.104 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntpsweep/ntpsweep-opts@1.54 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.92 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.92 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntpsweep/ntpsweep.html@1.105 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntpsweep/ntpsweep.man.in@1.92 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.93 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntptrace/invoke-ntptrace.texi@1.105 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntptrace/ntptrace-opts@1.54 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntptrace/ntptrace.1ntptraceman@1.92 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.93 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntptrace/ntptrace.html@1.106 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/ntptrace/ntptrace.man.in@1.92 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/ntptrace/ntptrace.mdoc.in@1.94 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/plot_summary-opts@1.54 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/plot_summary.1plot_summaryman@1.104 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/plot_summary.1plot_summarymdoc@1.104 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/plot_summary.html@1.107 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/plot_summary.man.in@1.104 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/plot_summary.mdoc.in@1.104 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/summary-opts@1.54 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/summary.1summaryman@1.104 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/summary.1summarymdoc@1.104 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/summary.html@1.107 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/summary.man.in@1.104 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/summary.mdoc.in@1.104 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/update-leap/invoke-update-leap.texi@1.5 +1 -1 + NTP_4_2_8P3_RC1 + + scripts/update-leap/update-leap-opts@1.5 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/update-leap/update-leap.1update-leapman@1.5 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/update-leap/update-leap.1update-leapmdoc@1.5 +2 -2 + NTP_4_2_8P3_RC1 + + scripts/update-leap/update-leap.html@1.5 +1 -1 + NTP_4_2_8P3_RC1 + + scripts/update-leap/update-leap.man.in@1.5 +3 -3 + NTP_4_2_8P3_RC1 + + scripts/update-leap/update-leap.mdoc.in@1.5 +2 -2 + NTP_4_2_8P3_RC1 + + sntp/invoke-sntp.texi@1.493 +2 -2 + NTP_4_2_8P3_RC1 + + sntp/sntp-opts.c@1.512 +185 -185 + NTP_4_2_8P3_RC1 + + sntp/sntp-opts.h@1.510 +3 -3 + NTP_4_2_8P3_RC1 + + sntp/sntp.1sntpman@1.328 +3 -3 + NTP_4_2_8P3_RC1 + + sntp/sntp.1sntpmdoc@1.328 +2 -2 + NTP_4_2_8P3_RC1 + + sntp/sntp.html@1.508 +2 -2 + NTP_4_2_8P3_RC1 + + sntp/sntp.man.in@1.328 +3 -3 + NTP_4_2_8P3_RC1 + + sntp/sntp.mdoc.in@1.328 +2 -2 + NTP_4_2_8P3_RC1 + + util/invoke-ntp-keygen.texi@1.496 +2 -2 + NTP_4_2_8P3_RC1 + + util/ntp-keygen-opts.c@1.514 +198 -198 + NTP_4_2_8P3_RC1 + + util/ntp-keygen-opts.h@1.512 +3 -3 + NTP_4_2_8P3_RC1 + + util/ntp-keygen.1ntp-keygenman@1.324 +3 -3 + NTP_4_2_8P3_RC1 + + util/ntp-keygen.1ntp-keygenmdoc@1.324 +2 -2 + NTP_4_2_8P3_RC1 + + util/ntp-keygen.html@1.170 +2 -2 + NTP_4_2_8P3_RC1 + + util/ntp-keygen.man.in@1.324 +3 -3 + NTP_4_2_8P3_RC1 + + util/ntp-keygen.mdoc.in@1.324 +2 -2 + NTP_4_2_8P3_RC1 + +ChangeSet@1.3326.7.2, 2015-05-12 04:02:33-04:00, stenn@deacon.udel.edu + 4.2.8p3-RC1 + + NEWS@1.137 +51 -1 + 4.2.8p3-RC1 + + packageinfo.sh@1.510 +1 -1 + 4.2.8p3-RC1 + +ChangeSet@1.3326.1.11, 2015-05-08 23:35:28-04:00, stenn@deacon.udel.edu + cleanup + + ChangeLog@1.1641.1.11 +3 -3 + cleanup + +ChangeSet@1.3326.1.9, 2015-05-09 03:28:48+00:00, stenn@psp-at1.ntp.org + minor cleanup + + ChangeLog@1.1641.1.9 +3 -3 + minor cleanup + + lib/isc/unix/ifiter_getifaddrs.c@1.16 +2 -0 + minor cleanup + +ChangeSet@1.3326.4.6, 2015-05-08 23:57:16+02:00, jnperlin@hydra.(none) + * [Bug 2745] ntpd -x steps clock on leap second + removed dead test code block in ntpd/ntp_leapsec.c + + ntpd/ntp_leapsec.c@1.18 +0 -8 + * [Bug 2745] ntpd -x steps clock on leap second + removed dead test code block + + +ChangeSet@1.3326.4.5, 2015-05-08 23:35:42+02:00, jnperlin@hydra.(none) + * [Bug 2745] ntpd -x steps clock on leap second + Fixed an initial-value problem that caused misbehaviour in absence of any leapsecond information. + + ChangeLog@1.1641.4.4 +2 -0 + * [Bug 2745] ntpd -x steps clock on leap second + Fixed an initial-value problem that caused misbehaviour in absence of any leapsecond information. + + ntpd/ntp_leapsec.c@1.17 +29 -3 + * [Bug 2745] ntpd -x steps clock on leap second + Fixed an initial-value problem that caused misbehaviour in absence of any leapsecond information. + Added support function to reset to pristine state for unit tests. + + ntpd/ntp_leapsec.h@1.9 +3 -0 + * [Bug 2745] ntpd -x steps clock on leap second + Added support function to reset to pristine state for unit tests. + + tests/ntpd/leapsec.cpp@1.10 +20 -10 + * [Bug 2745] ntpd -x steps clock on leap second + Added test case to validate the behaviour of queries in pristine state. + +ChangeSet@1.3326.6.1, 2015-05-08 21:25:22+02:00, jnperlin@hydra.(none) + * [Bug 2808] GPSD_JSON driver enhancements, step 1. + Fix crash during cleanup if GPS device not present and char device. + + ChangeLog@1.1641.6.1 +1 -0 + * [Bug 2808] GPSD_JSON driver enhancements, step 1. + Fix crash during cleanup if GPS device not present and char device. + + ntpd/refclock_gpsdjson.c@1.22 +12 -3 + * [Bug 2808] GPSD_JSON driver enhancements, step 1. + Fix crash during cleanup if GPS device not present and char device. + +ChangeSet@1.3326.1.8, 2015-05-08 12:25:43+02:00, martin@pc-martin.(none) + [Bug 2792] If the IFF_RUNNING interface flag is supported then an interface is ignored + as long as this flag is not set since the interface is not usable (e.g., no link). + + ChangeLog@1.1641.1.8 +3 -0 + [Bug 2792] If the IFF_RUNNING interface flag is supported then an interface is ignored + as long as this flag is not set since the interface is not usable (e.g., no link). + + lib/isc/unix/ifiter_getifaddrs.c@1.15 +17 -0 + [Bug 2792] If the IFF_RUNNING interface flag is supported then an interface is ignored + as long as this flag is not set since the interface is not usable (e.g., no link). + +ChangeSet@1.3326.1.7, 2015-05-08 08:29:08+00:00, stenn@psp-at1.ntp.org + CID 739725: Fix a rare resource leak in libevent/listener.c + + ChangeLog@1.1641.1.7 +1 -0 + CID 739725: Fix a rare resource leak in libevent/listener.c + + sntp/libevent/listener.c@1.8 +2 -0 + CID 739725: Fix a rare resource leak in libevent/listener.c + +ChangeSet@1.3326.1.6, 2015-05-08 08:19:06+00:00, stenn@psp-at1.ntp.org + [Bug 2821] Add a missing NTP_PRINTF and a missing const + + ChangeLog@1.1641.1.6 +1 -0 + [Bug 2821] Add a missing NTP_PRINTF and a missing const + + ntpd/refclock_gpsdjson.c@1.21 +1 -1 + [Bug 2821] Add a missing NTP_PRINTF and a missing const + + sntp/main.c@1.96 +1 -1 + [Bug 2821] Add a missing NTP_PRINTF and a missing const + +ChangeSet@1.3326.1.5, 2015-05-08 07:48:27+00:00, stenn@psp-at1.ntp.org + cleanup + + ChangeLog@1.1641.1.5 +3 -2 + cleanup + +ChangeSet@1.3326.3.3, 2015-05-08 07:37:35+00:00, stenn@psp-at1.ntp.org + merge cleanup + + ChangeLog@1.1641.3.3 +3 -4 + merge cleanup + +ChangeSet@1.3326.5.2, 2015-05-08 05:35:12+00:00, stenn@psp-at1.ntp.org + Add an assert to the ntpq ifstats code + + ChangeLog@1.1641.5.2 +1 -0 + Add an assert to the ntpq ifstats code + + ntpq/ntpq-subs.c@1.105 +1 -0 + Add an assert to the ntpq ifstats code + +ChangeSet@1.3326.5.1, 2015-05-08 04:59:19+00:00, stenn@psp-at1.ntp.org + Clean up the RLIMIT_STACK code + + ChangeLog@1.1641.5.1 +1 -0 + Clean up the RLIMIT_STACK code + + ntpd/ntp_config.c@1.325 +3 -2 + Clean up the RLIMIT_STACK code + +ChangeSet@1.3326.4.4, 2015-05-07 23:55:59+02:00, jnperlin@hydra.(none) + [Bug 2745] ntpd -x steps clock on leap second + provide test case for empty table lookup with real leap second + don't step with '-x' or if step min. step > 1sec + + ChangeLog@1.1641.4.3 +3 -3 + [Bug 2745] ntpd -x steps clock on leap second + provide test case for empty table lookup with real leap second + don't step with '-x' or if step min. step > 1sec + + tests/ntpd/leapsec.cpp@1.9 +43 -0 + [Bug 2745] ntpd -x steps clock on leap second + provide test case for empty table lookup with real leap second + +ChangeSet@1.3326.4.2, 2015-05-07 04:55:15+00:00, stenn@psp-at1.ntp.org + [Bug 2825] Quiet file installation in html/ + + ChangeLog@1.1641.4.1 +1 -0 + [Bug 2825] Quiet file installation in html/ + + Makefile.am@1.128.1.1 +3 -2 + [Bug 2825] Quiet file installation in html/ + +ChangeSet@1.3326.4.1, 2015-05-07 00:03:30+00:00, stenn@psp-at1.ntp.org + bk gone file cleanup + + BitKeeper/etc/gone@1.13 +0 -8 + bk gone file cleanup + +ChangeSet@1.3326.3.1, 2015-05-06 22:38:12+02:00, jnperlin@hydra.(none) + [Bug 2808] GPSD_JSON driver enhancements, step 1. + Increase internal token buffer to parse all JSON data, even SKY. + Avoid syslog clutter when driver has init problems but is nout used later on. + + ChangeLog@1.1641.3.1 +4 -0 + [Bug 2808] GPSD_JSON driver enhancements, step 1. + Increase internal token buffer to parse all JSON data, even SKY. + Avoid syslog clutter when driver has init problems but is nout used later on. + + ntpd/refclock_gpsdjson.c@1.20 +87 -11 + [Bug 2808] GPSD_JSON driver enhancements, step 1. + Increase internal token buffer to parse all JSON data, even SKY. + Avoid syslog clutter when driver has init problems but is nout used later on. + +ChangeSet@1.3326.1.3, 2015-05-05 23:32:59+02:00, jnperlin@nemesis.localnet + [Bug 2750] build for Win64 + loopback ppsapi dll needs def-file for entry point renaming in x86 target builds + + BitKeeper/etc/ignore@1.87 +6 -1 + [Bug 2750] build for Win64 + add all '.suo' files + add {Win32,x64}-{tmp,out} dirs + + ChangeLog@1.1641.1.3 +2 -1 + [Bug 2750] build for Win64 + use def-file for entry point renaming in x86 target builds of loopback ppsapi provider + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.def@1.4 +3 -1 + [Bug 2750] build for Win64 + add comment to explain why this is needed + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.def@1.3 +0 -0 + Rename: BitKeeper/deleted/74/loopback-ppsapi.def~c04da70eaf86d30 -> ports/winnt/ppsapi/loopback/src/loopback-ppsapi.def + + ports/winnt/vs2008/loopback-pps/loopback-ppsapi-provider.vcproj@1.3 +2 -0 + [Bug 2750] build for Win64 + use def-file for entry point renaming in x86 target builds + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj@1.5 +4 -0 + [Bug 2750] build for Win64 + use def-file for entry point renaming in x86 target builds + +ChangeSet@1.3326.1.2, 2015-05-04 22:51:42+00:00, stenn@psp-at1.ntp.org + Remove vs2013/ntp.v12.suo and vs2013/ntp.sdf + + BitKeeper/etc/gone@1.12 +1 -0 + Add items with bk gone + + BitKeeper/etc/gone@1.11 +0 -0 + Turn on MONOTONIC flag + + BitKeeper/etc/gone@1.10 +1 -0 + Add items with bk gone + +ChangeSet@1.3326.1.1, 2015-05-04 06:46:05+00:00, stenn@psp-at1.ntp.org + [Bug 2822] New leap column in sntp broke NTP::Util.pm + + ChangeLog@1.1641.1.2 +1 -0 + [Bug 2822] New leap column in sntp broke NTP::Util.pm + + scripts/lib/NTP/Util.pm@1.4 +1 -1 + [Bug 2822] New leap column in sntp broke NTP::Util.pm + +ChangeSet@1.3326, 2015-05-03 08:00:35+00:00, stenn@psp-deb1.ntp.org + Windows port build cleanup + + ChangeLog@1.1641.1.1 +1 -0 + Windows port build cleanup + +ChangeSet@1.3320.1.13, 2015-05-03 07:11:22+00:00, stenn@psp-at1.ntp.org + unity framework + + Makefile.am@1.129 +1 -0 + unity framework + + sntp/Makefile.am@1.79 +2 -2 + unity framework + + tests/unity-framework/ProductionCode.c@1.1 +24 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/unity-framework/ProductionCode.c + + tests/unity-framework/ProductionCode.c@1.0 +0 -0 + + tests/unity-framework/ProductionCode.h@1.1 +3 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/unity-framework/ProductionCode.h + + tests/unity-framework/ProductionCode.h@1.0 +0 -0 + + tests/unity-framework/TestProductionCode.c@1.1 +62 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/unity-framework/TestProductionCode.c + + tests/unity-framework/TestProductionCode.c@1.0 +0 -0 + + tests/unity-framework/TestProductionCode_Runner.c@1.1 +37 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/unity-framework/TestProductionCode_Runner.c + + tests/unity-framework/TestProductionCode_Runner.c@1.0 +0 -0 + +ChangeSet@1.3320.1.12, 2015-05-03 03:50:55+00:00, stenn@psp-at1.ntp.org + typo + + tests/bug-2803/Makefile.am@1.3 +1 -1 + typo + +ChangeSet@1.3320.1.11, 2015-05-03 03:41:35+00:00, stenn@psp-at1.ntp.org + bug-2803 framework + + sntp/configure.ac@1.78 +1 -0 + bug-2803 framework + + sntp/unity/Makefile.am@1.1 +15 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/Makefile.am + + sntp/unity/Makefile.am@1.0 +0 -0 + + tests/bug-2803/Makefile.am@1.2 +14 -8 + bug-2803 framework + + tests/bug-2803/bug-2803.c@1.2 +4 -134 + bug-2803 framework + +ChangeSet@1.3320.1.10, 2015-05-03 02:43:24+00:00, stenn@psp-at1.ntp.org + Updates for bug-2803/ tests + + configure.ac@1.589 +1 -0 + Updates for bug-2803/ tests + + tests/Makefile.am@1.6 +3 -0 + Updates for bug-2803/ tests + + tests/bug-2803/Makefile.am@1.1 +54 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/Makefile.am + + tests/bug-2803/Makefile.am@1.0 +0 -0 + +ChangeSet@1.3320.1.8, 2015-05-02 04:05:14+00:00, stenn@psp-at1.ntp.org + cleanup + + ChangeLog@1.1641 +1 -1 + cleanup + +ChangeSet@1.3320.1.7, 2015-05-01 13:27:32+00:00, abe@psp-deb1.ntp.org + driver40-ja.html: + [BUG 2806] Correcting typo of the driver40-ja.html + ChangeLog: + [BUG 2806] CID 1296235: refclock_jjy.c and correcting typo of driver40-ja.html + refclock_jjy.c: + [BUG 2806] CID 1296235: Fix refclock_jjy.c and some changes to avoid claims by the check tool + + ChangeLog@1.1640 +1 -0 + [BUG 2806] CID 1296235: refclock_jjy.c and correcting typo of driver40-ja.html + + html/drivers/driver40-ja.html@1.3 +2 -2 + [BUG 2806] Correcting typo of the driver40-ja.html + + ntpd/refclock_jjy.c@1.28 +12 -2 + [BUG 2806] CID 1296235: Fix refclock_jjy.c and some changes to avoid claims by the check tool + +ChangeSet@1.3320.4.13, 2015-05-01 05:59:34-04:00, stenn@deacon.udel.edu + [Bug 2590] autogen-5.18.5 + + ChangeLog@1.1635.3.8 +1 -1 + [Bug 2590] autogen-5.18.5 + + sntp/include/autogen-version.def@1.22 +1 -1 + [Bug 2590] autogen-5.18.5 + +ChangeSet@1.3320.4.12, 2015-05-01 09:25:56+00:00, stenn@psp-at1.ntp.org + [Bug 2650] fix includefile processing + + ChangeLog@1.1635.3.7 +1 -0 + [Bug 2650] fix includefile processing + +ChangeSet@1.3320.10.2, 2015-05-01 01:08:05+02:00, jnperlin@hydra.(none) + [Bug 2650] includefile processing broken. + rework and cleanup of config processing after merge from 4.2.8p2 + + ntpd/keyword-gen.c@1.28 +0 -2 + [Bug 2650] includefile processing broken. + rework and cleanup of config processing after merge from 4.2.8p2 + + ntpd/ntp_parser.c@1.92 +405 -412 + [Bug 2650] includefile processing broken. + rework and cleanup of config processing after merge from 4.2.8p2 + + ntpd/ntp_scanner.c@1.48 +56 -45 + [Bug 2650] includefile processing broken. + rework and cleanup of config processing after merge from 4.2.8p2 + + ntpd/ntp_scanner.h@1.20 +8 -1 + [Bug 2650] includefile processing broken. + rework and cleanup of config processing after merge from 4.2.8p2 + +ChangeSet@1.3320.4.10, 2015-04-30 05:55:00+00:00, stenn@psp-at1.ntp.org + update dates + + html/drivers/driver40-ja.html@1.2 +1 -1 + update dates + + html/drivers/driver40.html@1.18 +1 -1 + update dates + + html/drivers/driver46.html@1.7 +1 -1 + update dates + +ChangeSet@1.3320.4.9, 2015-04-30 05:01:21+00:00, stenn@psp-at1.ntp.org + cleanup + + ChangeLog@1.1635.3.6 +0 -3 + cleanup + + ntpd/refclock_shm.c@1.31.1.3 +4 -0 + cleanup + +ChangeSet@1.3320.3.5, 2015-04-30 04:02:23+00:00, stenn@psp-at1.ntp.org + cleanup + + ChangeLog@1.1635.2.4 +3 -3 + cleanup + + ntpd/ntp_timer.c@1.85 +1 -1 + cleanup + + ntpd/refclock_shm.c@1.31.3.1 +4 -1 + cleanup + +ChangeSet@1.3320.7.3, 2015-04-29 22:58:45+00:00, stenn@psp-at1.ntp.org + cleanup + + ChangeLog@1.1635.5.2 +1 -1 + cleanup + +ChangeSet@1.3292.1.21, 2015-04-29 20:07:39+02:00, jnperlin@hydra.(none) + [bug 2650] includefile processing broken + forward from lost/orphaned repo + + ntpd/ntp_config.c@1.322.1.1 +20 -38 + [bug 2650] includefile processing broken + forward from lost/orphaned repo + + ntpd/ntp_parser.c@1.89.1.1 +404 -411 + [bug 2650] includefile processing broken + forward from lost/orphaned repo + + ntpd/ntp_parser.h@1.55.1.1 +2 -2 + [bug 2650] includefile processing broken + forward from lost/orphaned repo + + ntpd/ntp_parser.y@1.82.1.1 +43 -51 + [bug 2650] includefile processing broken + forward from lost/orphaned repo + + ntpd/ntp_scanner.c@1.47 +297 -128 + [bug 2650] includefile processing broken + forward from lost/orphaned repo + + ntpd/ntp_scanner.h@1.19 +27 -22 + [bug 2650] includefile processing broken + forward from lost/orphaned repo + +ChangeSet@1.3320.3.2, 2015-04-29 19:29:16+02:00, jnperlin@hydra.(none) + [Bug 2745] ntpd -x steps clock on leap second + Better syslog messages when not stepping + + ntpd/ntp_timer.c@1.84 +19 -4 + [Bug 2745] ntpd -x steps clock on leap second + Better syslog messages when not stepping + +ChangeSet@1.3320.4.6, 2015-04-29 18:58:30+02:00, jnperlin@hydra.(none) + [Bug 2808] - GPSD_JSON driver enhancements, step 1 + fix coverity issues in refclock_shm and refclock_gpsdjson + + ChangeLog@1.1635.3.3 +2 -0 + [Bug 2808] - GPSD_JSON driver enhancements, step 1 + fix coverity issues in refclock_shm and refclock_gpsdjson + + libjsmn/jsmn.c@1.5 +6 -5 + [Bug 2808] - GPSD_JSON driver enhancements, step 1 + fix coverity issue with potential NULL pointer access + + ntpd/refclock_gpsdjson.c@1.19 +3 -2 + [Bug 2808] - GPSD_JSON driver enhancements, step 1 + fix coverity issue with negative array index + + ntpd/refclock_shm.c@1.31.2.1 +0 -1 + [Bug 2808] - GPSD_JSON driver enhancements, step 1 + fix coverity issue with unreachable code + +ChangeSet@1.3320.8.1, 2015-04-29 07:03:32+00:00, stenn@psp-at1.ntp.org + [Bug 2805] ntpd fails to join multicast group + + ChangeLog@1.1635.6.1 +1 -0 + [Bug 2805] ntpd fails to join multicast group + + ntpd/ntp_io.c@1.400 +30 -9 + [Bug 2805] ntpd fails to join multicast group + +ChangeSet@1.3320.7.2, 2015-04-28 12:08:31+00:00, abe@psp-deb1.ntp.org + ChangeLog: + [BUG 2806] refclock_jjy.c supports the Tel-JJY + + ChangeLog@1.1635.5.1 +1 -0 + [BUG 2806] refclock_jjy.c supports the Tel-JJY + +ChangeSet@1.3320.7.1, 2015-04-28 11:47:00+00:00, abe@psp-deb1.ntp.org + driver40-ja.html: + new file + driver40.html, refclock_jjy.c: + [BUG 2806] refclock_jjy.c supports the Tel-JJY + + html/drivers/driver40-ja.html@1.1 +481 -0 + BitKeeper file /home/abe/ntp-stable-2806/html/drivers/driver40-ja.html + + html/drivers/driver40-ja.html@1.0 +0 -0 + + html/drivers/driver40.html@1.17 +265 -48 + [BUG 2806] refclock_jjy.c supports the Tel-JJY + + ntpd/refclock_jjy.c@1.27 +3570 -1117 + [BUG 2806] refclock_jjy.c supports the Tel-JJY + +ChangeSet@1.3320.5.10, 2015-04-28 09:13:57+00:00, stenn@psp-at1.ntp.org + bug-2803 tests + + tests/bug-2803/Makefile-@1.1 +10 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/Makefile- + + tests/bug-2803/Makefile-@1.0 +0 -0 + + tests/bug-2803/bug-2803.c@1.1 +229 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/bug-2803.c + + tests/bug-2803/bug-2803.c@1.0 +0 -0 + + tests/bug-2803/test-2803.c@1.1 +229 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/tests/bug-2803/test-2803.c + + tests/bug-2803/test-2803.c@1.0 +0 -0 + +ChangeSet@1.3320.5.8, 2015-04-27 20:49:41+00:00, stenn@psp-at1.ntp.org + [Bug 2612] restrict: Warn when 'monitor' can't be disabled because of 'limited' + + ChangeLog@1.1635.4.6 +2 -0 + [Bug 2612] restrict: Warn when 'monitor' can't be disabled because of 'limited' + + ntpd/ntp_proto.c@1.356 +5 -1 + [Bug 2612] restrict: Warn when 'monitor' can't be disabled because of 'limited' + +ChangeSet@1.3320.5.7, 2015-04-27 10:48:48+00:00, stenn@psp-at1.ntp.org + [Bug 2815] net-snmp before v5.4 has circular library dependencies + + ChangeLog@1.1635.4.5 +1 -0 + [Bug 2815] net-snmp before v5.4 has circular library dependencies + + configure.ac@1.584.1.2 +14 -0 + [Bug 2815] net-snmp before v5.4 has circular library dependencies + +ChangeSet@1.3320.2.11, 2015-04-27 08:41:41+00:00, stenn@psp-deb1.ntp.org + [Bug 2776] Clean up EVP_MD_do_all_sorted() test + + sntp/m4/ntp_openssl.m4@1.24 +3 -1 + [Bug 2776] Clean up EVP_MD_do_all_sorted() test + +ChangeSet@1.3320.5.6, 2015-04-26 19:53:46+00:00, stenn@psp-at1.ntp.org + [Bug 2813] HP-UX needs -D__STDC_VERSION__=199901L and limits.h + + ChangeLog@1.1635.4.4 +1 -0 + [Bug 2813] HP-UX needs -D__STDC_VERSION__=199901L and limits.h + + include/ntp_types.h@1.34 +5 -0 + [Bug 2813] HP-UX needs -D__STDC_VERSION__=199901L and limits.h + + sntp/m4/os_cflags.m4@1.10 +2 -2 + [Bug 2813] HP-UX needs -D__STDC_VERSION__=199901L and limits.h + +ChangeSet@1.3320.5.5, 2015-04-26 18:44:23+00:00, stenn@psp-at1.ntp.org + autogen-5.18.5 + + ChangeLog@1.1635.4.3 +1 -0 + autogen-5.18.5 + + sntp/libopts/COPYING.gplv3@1.8 +1 -1 + autogen-5.18.5 + + sntp/libopts/COPYING.lgplv3@1.8 +1 -1 + autogen-5.18.5 + + sntp/libopts/COPYING.mbsd@1.3 +1 -0 + autogen-5.18.5 + + sntp/libopts/README@1.10 +1 -1 + autogen-5.18.5 + + sntp/libopts/ag-char-map.h@1.31 +2 -2 + autogen-5.18.5 + + sntp/libopts/alias.c@1.8 +1 -1 + autogen-5.18.5 + + sntp/libopts/ao-strs.c@1.17 +2 -2 + autogen-5.18.5 + + sntp/libopts/ao-strs.h@1.16 +2 -2 + autogen-5.18.5 + + sntp/libopts/autoopts.c@1.20 +4 -4 + autogen-5.18.5 + + sntp/libopts/autoopts.h@1.21 +12 -12 + autogen-5.18.5 + + sntp/libopts/autoopts/options.h@1.30 +96 -96 + autogen-5.18.5 + + sntp/libopts/autoopts/project.h@1.8 +1 -1 + autogen-5.18.5 + + sntp/libopts/autoopts/usage-txt.h@1.29 +15 -15 + autogen-5.18.5 + + sntp/libopts/boolean.c@1.15 +5 -5 + autogen-5.18.5 + + sntp/libopts/check.c@1.8 +1 -1 + autogen-5.18.5 + + sntp/libopts/compat/compat.h@1.16 +1 -1 + autogen-5.18.5 + + sntp/libopts/compat/pathfind.c@1.11 +13 -13 + autogen-5.18.5 + + sntp/libopts/compat/windows-config.h@1.14 +1 -1 + autogen-5.18.5 + + sntp/libopts/configfile.c@1.23 +54 -55 + autogen-5.18.5 + + sntp/libopts/cook.c@1.15 +10 -10 + autogen-5.18.5 + + sntp/libopts/enum.c@1.13 +14 -14 + autogen-5.18.5 + + sntp/libopts/env.c@1.9 +4 -4 + autogen-5.18.5 + + sntp/libopts/file.c@1.16 +6 -6 + autogen-5.18.5 + + sntp/libopts/find.c@1.12 +10 -10 + autogen-5.18.5 + + sntp/libopts/genshell.c@1.31 +25 -25 + autogen-5.18.5 + + sntp/libopts/gettext.h@1.4 +1 -1 + autogen-5.18.5 + + sntp/libopts/init.c@1.8 +12 -13 + autogen-5.18.5 + + sntp/libopts/intprops.h@1.2 +1 -1 + autogen-5.18.5 + + sntp/libopts/libopts.c@1.9 +2 -0 + autogen-5.18.5 + + sntp/libopts/load.c@1.21 +8 -8 + autogen-5.18.5 + + sntp/libopts/m4/libopts.m4@1.34 +28 -28 + autogen-5.18.5 + + sntp/libopts/m4/liboptschk.m4@1.13 +1 -1 + autogen-5.18.5 + + sntp/libopts/m4/stdnoreturn.m4@1.2 +1 -1 + autogen-5.18.5 + + sntp/libopts/makeshell.c@1.20 +22 -17 + autogen-5.18.5 + + sntp/libopts/nested.c@1.16 +36 -36 + autogen-5.18.5 + + sntp/libopts/numeric.c@1.15 +10 -10 + autogen-5.18.5 + + sntp/libopts/option-value-type.c@1.18 +2 -2 + autogen-5.18.5 + + sntp/libopts/option-value-type.h@1.32 +1 -1 + autogen-5.18.5 + + sntp/libopts/option-xat-attribute.c@1.18 +2 -2 + autogen-5.18.5 + + sntp/libopts/option-xat-attribute.h@1.32 +1 -1 + autogen-5.18.5 + + sntp/libopts/parse-duration.c@1.14 +3 -3 + autogen-5.18.5 + + sntp/libopts/parse-duration.h@1.10 +1 -1 + autogen-5.18.5 + + sntp/libopts/pgusage.c@1.18 +5 -5 + autogen-5.18.5 + + sntp/libopts/proto.h@1.31 +2 -2 + autogen-5.18.5 + + sntp/libopts/putshell.c@1.15 +7 -7 + autogen-5.18.5 + + sntp/libopts/reset.c@1.17 +5 -5 + autogen-5.18.5 + + sntp/libopts/restore.c@1.14 +19 -19 + autogen-5.18.5 + + sntp/libopts/save.c@1.18 +11 -11 + autogen-5.18.5 + + sntp/libopts/sort.c@1.14 +5 -5 + autogen-5.18.5 + + sntp/libopts/stack.c@1.16 +15 -15 + autogen-5.18.5 + + sntp/libopts/stdnoreturn.in.h@1.2 +1 -1 + autogen-5.18.5 + + sntp/libopts/streqvcmp.c@1.16 +11 -11 + autogen-5.18.5 + + sntp/libopts/text_mmap.c@1.17 +11 -11 + autogen-5.18.5 + + sntp/libopts/time.c@1.15 +5 -5 + autogen-5.18.5 + + sntp/libopts/tokenize.c@1.13 +28 -28 + autogen-5.18.5 + + sntp/libopts/usage.c@1.21 +4 -4 + autogen-5.18.5 + + sntp/libopts/version.c@1.19 +9 -9 + autogen-5.18.5 + +ChangeSet@1.3320.5.4, 2015-04-26 05:26:11-04:00, stenn@deacon.udel.edu + CID 1269537: Clean up a line of dead code in getShmTime(). + + ChangeLog@1.1635.4.2 +1 -0 + CID 1269537: Clean up a line of dead code in getShmTime(). + + ntpd/refclock_shm.c@1.31.1.1 +4 -1 + CID 1269537: Clean up a line of dead code in getShmTime(). + +ChangeSet@1.3320.2.9, 2015-04-26 08:14:52+00:00, stenn@psp-at1.ntp.org + CID 1295478: Quiet a pedantic potential error from the fix for Bug 2776 + + ChangeLog@1.1635.1.6 +2 -0 + CID 1295478: Quiet a pedantic potential error from the fix for Bug 2776 + + ntpq/ntpq.c@1.158 +9 -0 + CID 1295478: Quiet a pedantic potential error from the fix for Bug 2776 + +ChangeSet@1.3320.6.1, 2015-04-25 23:56:16+00:00, stenn@psp-fb1.ntp.org + Improve the ntpq documentation around the controlkey keyid + + ChangeLog@1.1635.4.1 +1 -0 + Improve the ntpq documentation around the controlkey keyid + + ntpq/ntpq-opts.def@1.25 +3 -1 + Improve the ntpq documentation around the controlkey keyid + +ChangeSet@1.3320.5.2, 2015-04-24 22:46:50-04:00, stenn@deacon.udel.edu + [Bug 2804] more cleanup to install-local-data + + Makefile.am@1.128 +1 -1 + [Bug 2804] more cleanup to install-local-data + +ChangeSet@1.3320.5.1, 2015-04-24 18:59:14-04:00, stenn@deacon.udel.edu + Fix regression in previous [Bug 2804] fix + + Makefile.am@1.127 +4 -4 + Fix regression in previous [Bug 2804] fix + +ChangeSet@1.3320.4.4, 2015-04-24 21:20:38+02:00, jnperlin@hydra.(none) + [Bug 2808] GPSD_JSON driver enhancements, step 1. + Add a few more tallies as per Hal Murray's suggestions + + ChangeLog@1.1635.3.2 +2 -0 + [Bug 2808] GPSD_JSON driver enhancements, step 1. + Add a few more tallies as per Hal Murray's suggestions + + + html/drivers/driver46.html@1.6 +54 -16 + [Bug 2808] GPSD_JSON driver enhancements, step 1. + Add a few more tallies as per Hal Murray's suggestions + + + ntpd/refclock_gpsdjson.c@1.18 +39 -18 + [Bug 2808] GPSD_JSON driver enhancements, step 1. + Add a few more tallies as per Hal Murray's suggestions + + +ChangeSet@1.3320.2.7, 2015-04-24 09:25:09+00:00, stenn@psp-at1.ntp.org + [Bug 2776] Improve ntpq's 'help keytype' + + sntp/m4/ntp_openssl.m4@1.23 +7 -1 + [Bug 2776] Improve ntpq's 'help keytype' + +ChangeSet@1.3320.4.3, 2015-04-24 01:25:50-04:00, stenn@deacon.udel.edu + refclock_true.c true_debug() can't open debug log because of incompatible open/fdopen parameters + + ChangeLog@1.1635.3.1 +2 -0 + refclock_true.c true_debug() can't open debug log because of incompatible open/fdopen parameters + + ntpd/refclock_true.c@1.24 +1 -1 + refclock_true.c true_debug() can't open debug log because of incompatible open/fdopen parameters + +ChangeSet@1.3320.4.2, 2015-04-22 13:49:17-04:00, stenn@deacon.udel.edu + Update NEWS file + + NEWS@1.136 +4 -1 + Update NEWS file + +ChangeSet@1.3320.2.5, 2015-04-22 17:33:08+00:00, stenn@psp-fb1.ntp.org + Fix typo in patch for bug 2776 + + ntpq/ntpq.c@1.157 +1 -1 + Fix typo in patch for bug 2776 + +ChangeSet@1.3320.2.4, 2015-04-22 11:25:54+00:00, stenn@psp-fb1.ntp.org + [Bug 2776] Improve ntpq's 'help keytype' + + ntpq/ntpq.c@1.156 +6 -1 + [Bug 2776] Improve ntpq's 'help keytype' + + sntp/m4/ntp_openssl.m4@1.22 +1 -0 + [Bug 2776] Improve ntpq's 'help keytype' + +ChangeSet@1.3320.4.1, 2015-04-22 08:36:46+00:00, stenn@psp-at1.ntp.org + [Bug 2804] install-local-data assumes GNU find semantics + + Makefile.am@1.126 +4 -4 + [Bug 2804] install-local-data assumes GNU find semantics + +ChangeSet@1.3320.3.1, 2015-04-21 21:08:11+02:00, jnperlin@hydra.(none) + [Bug 2745] ntpd -x steps clock on leap second + Do leap second stepping only of the step adjustment is beyond the proper jump distance limit and step correction is allowed at all. + + ChangeLog@1.1635.2.1 +3 -0 + [Bug 2745] ntpd -x steps clock on leap second + Do leap second stepping only of the step adjustment is beyond the proper jump distance limit and step correction is allowed at all. + + + ntpd/ntp_timer.c@1.83 +15 -5 + [Bug 2745] ntpd -x steps clock on leap second + Do leap second stepping only of the step adjustment is beyond the proper jump distance limit and step correction is allowed at all. + + +ChangeSet@1.3320.2.3, 2015-04-21 09:48:05+00:00, stenn@psp-deb1.ntp.org + [Bug 2776] Improve ntpq's 'help keytype' + + ChangeLog@1.1635.1.3 +1 -0 + [Bug 2776] Improve ntpq's 'help keytype' + + ntpq/ntpq.c@1.155 +132 -8 + [Bug 2776] Improve ntpq's 'help keytype' + +ChangeSet@1.3320.2.2, 2015-04-21 06:49:56+00:00, stenn@psp-fb1.ntp.org + [Bug 2794] Clean up kernel clock status reports + + ChangeLog@1.1635.1.2 +1 -0 + [Bug 2794] Clean up kernel clock status reports + + ntpd/ntp_loopfilter.c@1.184 +83 -8 + [Bug 2794] Clean up kernel clock status reports + +ChangeSet@1.3320.2.1, 2015-04-20 11:26:22+00:00, stenn@psp-fb1.ntp.org + [Bug 2804] install-local-data assumes GNU 'find' semantics' + + ChangeLog@1.1635.1.1 +1 -0 + [Bug 2804] install-local-data assumes GNU 'find' semantics' + + Makefile.am@1.125 +6 -4 + [Bug 2804] install-local-data assumes GNU 'find' semantics' + +ChangeSet@1.3320.1.4, 2015-04-20 10:00:46+00:00, stenn@psp-deb1.ntp.org + [Bug 2810] refclock_shm.c memory barrier code needs tweaks for QNX + + ChangeLog@1.1637 +1 -0 + [Bug 2810] refclock_shm.c memory barrier code needs tweaks for QNX + + configure.ac@1.587 +21 -5 + [Bug 2810] refclock_shm.c memory barrier code needs tweaks for QNX + + ntpd/refclock_shm.c@1.35 +2 -2 + [Bug 2810] refclock_shm.c memory barrier code needs tweaks for QNX + +ChangeSet@1.3320.1.2, 2015-04-19 23:50:36+00:00, stenn@psp-fb1.ntp.org + cleanup + + ChangeLog@1.1635 +4 -3 + cleanup + +ChangeSet@1.3323, 2015-04-19 12:38:34+02:00, jnperlin@nemesis.localnet + Fixed include file lists; improved generation of 'ntp_keyword.h' + + ports/winnt/vs2008/libntp/libntp.vcproj@1.54 +7 -15 + Fixed include file lists + + ports/winnt/vs2008/ntpd/gen-ntp_keyword.bat@1.4 +19 -7 + 'Touch' both output files to avoid needless cycles + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.48 +8 -16 + Fixed include file lists + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.16 +1 -1 + Fixed include file lists + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.8 +5 -7 + Fixed include file lists + + ports/winnt/vs2013/libntp/libntp.vcxproj.filters@1.6 +15 -21 + Fixed include file lists + + ports/winnt/vs2013/ntpd/gen-ntp_keyword.bat@1.3 +18 -6 + 'Touch' both output files to avoid needless cycles + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.6 +8 -9 + Fixed include file lists + + ports/winnt/vs2013/ntpd/ntpd.vcxproj.filters@1.4 +22 -25 + Fixed include file lists + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj@1.6 +1 -1 + Fixed include file lists + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj.filters@1.3 +3 -3 + Fixed include file lists + +ChangeSet@1.3322, 2015-04-13 23:24:19+02:00, jnperlin@nemesis.localnet + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj@1.4 +6 -6 + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj@1.5 +6 -6 + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.5 +43 -41 + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + + ports/winnt/vs2013/ntpd/ntpd.vcxproj.filters@1.3 +3 -6 + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj@1.5 +6 -6 + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj@1.5 +6 -6 + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + + ports/winnt/vs2013/ntpq/ntpq.vcxproj@1.5 +6 -6 + make sure batch files are executed via 'call' -- multiple custom build steps fail otherwise. + +ChangeSet@1.3320.1.1, 2015-04-13 20:39:08+02:00, jnperlin@hydra.(none) + [Bug 2808] GPSD_JSON driver enhancements, step 1 + + ChangeLog@1.1634 +4 -0 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + + html/drivers/driver46.html@1.5 +210 -69 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + extended docs to reflect new modes, describe clockstat lines + + libjsmn/Makefile@1.2 +10 -2 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + update of libjsmn + + libjsmn/README.md@1.2 +16 -10 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + update of libjsmn + + libjsmn/example/jsondump.c@1.1 +112 -0 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + update of libjsmn + + libjsmn/example/jsondump.c@1.0 +0 -0 + + libjsmn/example/simple.c@1.1 +75 -0 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + update of libjsmn + + libjsmn/example/simple.c@1.0 +0 -0 + + libjsmn/jsmn.c@1.4 +68 -26 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + update of libjsmn + + libjsmn/jsmn.h@1.2 +13 -5 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + update of libjsmn + + libjsmn/jsmn_test.c@1.2 +269 -70 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + update of libjsmn + + ntpd/refclock_gpsdjson.c@1.17 +1242 -480 + [Bug 2808] GPSD_JSON driver enhancements, step 1 + +ChangeSet@1.3321, 2015-04-12 19:49:34+02:00, jnperlin@nemesis.localnet + WinBuild: cleanup of VS2008/VS2013 build, add 64bit build to VS2008 + + BitKeeper/deleted/1f/libntp.vcproj~633f10802d3dd886@1.2 +0 -0 + Delete: ports/winnt/vs2013/libntp/libntp.vcproj + + BitKeeper/deleted/2c/loopback-ppsapi-provider.vcproj~cc591e5b57f29333@1.2 +0 -0 + Delete: ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcproj + + BitKeeper/deleted/4a/ntpdate.vcproj~25a4bb1b2b25d122@1.2 +0 -0 + Delete: ports/winnt/vs2013/ntpdate/ntpdate.vcproj + + BitKeeper/deleted/59/ntp-keygen.vcproj~113746c5269b75c1@1.2 +0 -0 + Delete: ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcproj + + BitKeeper/deleted/74/loopback-ppsapi.def~c04da70eaf86d30@1.2 +0 -0 + Delete: ports/winnt/ppsapi/loopback/src/loopback-ppsapi.def + + BitKeeper/deleted/7d/instsrv.vcproj~d954b04479d96296@1.2 +0 -0 + Delete: ports/winnt/vs2013/instsrv/instsrv.vcproj + + BitKeeper/deleted/85/ntpq.vcproj~7315506e38872e71@1.2 +0 -0 + Delete: ports/winnt/vs2013/ntpq/ntpq.vcproj + + BitKeeper/deleted/be/ntpd-keyword-gen.vcproj~9da2e11a69865360@1.2 +0 -0 + Delete: ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcproj + + BitKeeper/deleted/c6/ntpd.vcproj~b19ad49465a3e751@1.2 +0 -0 + Delete: ports/winnt/vs2013/ntpd/ntpd.vcproj + + BitKeeper/deleted/fc/ntpdc.vcproj~d5808b9e94b3c99@1.2 +0 -0 + Delete: ports/winnt/vs2013/ntpdc/ntpdc.vcproj + + ports/winnt/include/config.h@1.112 +6 -4 + OPENSSL set from property sheet + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.h@1.2 +4 -1 + avoid double definition of _CRT_SECURE_NO_WARNINGS + + ports/winnt/ppsapi/loopback/src/timepps.h@1.3 +21 -15 + reduce number of warnings + + ports/winnt/vs2008/common.vsprops@1.1 +53 -0 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/common.vsprops@1.0 +0 -0 + + ports/winnt/vs2008/debug-x64.vsprops@1.1 +20 -0 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/debug-x64.vsprops@1.0 +0 -0 + + ports/winnt/vs2008/debug.vsprops@1.1 +20 -0 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/debug.vsprops@1.0 +0 -0 + + ports/winnt/vs2008/instsrv/instsrv.vcproj@1.7 +200 -87 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/libntp/libntp.vcproj@1.53 +156 -49 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/loopback-pps/loopback-ppsapi-provider.vcproj@1.2 +190 -62 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.15 +173 -137 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/ntp.sln@1.11 +39 -1 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/ntpd-keyword-gen/ntpd-keyword-gen.vcproj@1.3 +144 -53 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/ntpd/gen-ntp_keyword.bat@1.3 +6 -4 + minor cleanup & touch emulation + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.47 +253 -235 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.15 +178 -116 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.17 +178 -157 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.16 +176 -149 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/release-x64.vsprops@1.1 +21 -0 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/release-x64.vsprops@1.0 +0 -0 + + ports/winnt/vs2008/release.vsprops@1.1 +21 -0 + add 64bit build, refactor into property sheets + + ports/winnt/vs2008/release.vsprops@1.0 +0 -0 + + ports/winnt/vs2013/common.props@1.1 +59 -0 + refactor into property sheets + + ports/winnt/vs2013/common.props@1.0 +0 -0 + + ports/winnt/vs2013/debug-x64.props@1.1 +23 -0 + refactor into property sheets + + ports/winnt/vs2013/debug-x64.props@1.0 +0 -0 + + ports/winnt/vs2013/debug.props@1.1 +24 -0 + refactor into property sheets + + ports/winnt/vs2013/debug.props@1.0 +0 -0 + + ports/winnt/vs2013/instsrv/instsrv.vcxproj@1.3 +88 -499 + refactor into property sheets + + ports/winnt/vs2013/instsrv/instsrv.vcxproj.filters@1.2 +9 -3 + refactor into property sheets + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.7 +150 -462 + refactor into property sheets + + ports/winnt/vs2013/libntp/libntp.vcxproj.filters@1.5 +21 -24 + refactor into property sheets + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj@1.3 +95 -430 + refactor into property sheets + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj.filters@1.2 +4 -1 + refactor into property sheets + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj@1.4 +83 -565 + refactor into property sheets + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj.filters@1.2 +3 -3 + refactor into property sheets + + ports/winnt/vs2013/ntp.sln@1.3 +61 -61 + refactor into property sheets + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj@1.4 +85 -389 + refactor into property sheets + + ports/winnt/vs2013/ntpd/gen-ntp_keyword.bat@1.2 +6 -4 + minor cleanup & touch emulation + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.4 +195 -728 + refactor into property sheets + + ports/winnt/vs2013/ntpd/ntpd.vcxproj.filters@1.2 +19 -31 + refactor into property sheets + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj@1.4 +84 -547 + refactor into property sheets + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj.filters@1.2 +3 -3 + refactor into property sheets + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj@1.4 +85 -575 + refactor into property sheets + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj.filters@1.2 +3 -3 + refactor into property sheets + + ports/winnt/vs2013/ntpq/ntpq.vcxproj@1.4 +74 -537 + refactor into property sheets + + ports/winnt/vs2013/ntpq/ntpq.vcxproj.filters@1.2 +3 -3 + refactor into property sheets + + ports/winnt/vs2013/release-x64.props@1.1 +24 -0 + refactor into property sheets + + ports/winnt/vs2013/release-x64.props@1.0 +0 -0 + + ports/winnt/vs2013/release.props@1.1 +25 -0 + refactor into property sheets + + ports/winnt/vs2013/release.props@1.0 +0 -0 + +ChangeSet@1.3320, 2015-04-07 04:28:16-04:00, stenn@deacon.udel.edu + NTP_4_2_8P2 + TAG: NTP_4_2_8P2 + + ChangeLog@1.1633 +1 -0 + NTP_4_2_8P2 + + ntpd/invoke-ntp.conf.texi@1.182 +1 -1 + NTP_4_2_8P2 + + ntpd/invoke-ntp.keys.texi@1.178 +1 -1 + NTP_4_2_8P2 + + ntpd/invoke-ntpd.texi@1.495 +2 -2 + NTP_4_2_8P2 + + ntpd/ntp.conf.5man@1.216 +3 -3 + NTP_4_2_8P2 + + ntpd/ntp.conf.5mdoc@1.216 +2 -2 + NTP_4_2_8P2 + + ntpd/ntp.conf.html@1.173 +1 -1 + NTP_4_2_8P2 + + ntpd/ntp.conf.man.in@1.216 +3 -3 + NTP_4_2_8P2 + + ntpd/ntp.conf.mdoc.in@1.216 +2 -2 + NTP_4_2_8P2 + + ntpd/ntp.keys.5man@1.212 +2 -2 + NTP_4_2_8P2 + + ntpd/ntp.keys.5mdoc@1.212 +2 -2 + NTP_4_2_8P2 + + ntpd/ntp.keys.html@1.174 +1 -1 + NTP_4_2_8P2 + + ntpd/ntp.keys.man.in@1.212 +2 -2 + NTP_4_2_8P2 + + ntpd/ntp.keys.mdoc.in@1.212 +2 -2 + NTP_4_2_8P2 + + ntpd/ntpd-opts.c@1.517 +245 -245 + NTP_4_2_8P2 + + ntpd/ntpd-opts.h@1.516 +3 -3 + NTP_4_2_8P2 + + ntpd/ntpd.1ntpdman@1.324 +3 -3 + NTP_4_2_8P2 + + ntpd/ntpd.1ntpdmdoc@1.324 +2 -2 + NTP_4_2_8P2 + + ntpd/ntpd.html@1.168 +2 -2 + NTP_4_2_8P2 + + ntpd/ntpd.man.in@1.324 +3 -3 + NTP_4_2_8P2 + + ntpd/ntpd.mdoc.in@1.324 +2 -2 + NTP_4_2_8P2 + + ntpdc/invoke-ntpdc.texi@1.492 +2 -2 + NTP_4_2_8P2 + + ntpdc/ntpdc-opts.c@1.510 +107 -107 + NTP_4_2_8P2 + + ntpdc/ntpdc-opts.h@1.509 +3 -3 + NTP_4_2_8P2 + + ntpdc/ntpdc.1ntpdcman@1.323 +3 -3 + NTP_4_2_8P2 + + ntpdc/ntpdc.1ntpdcmdoc@1.323 +2 -2 + NTP_4_2_8P2 + + ntpdc/ntpdc.html@1.336 +2 -2 + NTP_4_2_8P2 + + ntpdc/ntpdc.man.in@1.323 +3 -3 + NTP_4_2_8P2 + + ntpdc/ntpdc.mdoc.in@1.323 +2 -2 + NTP_4_2_8P2 + + ntpq/invoke-ntpq.texi@1.498 +2 -2 + NTP_4_2_8P2 + + ntpq/ntpq-opts.c@1.515 +106 -106 + NTP_4_2_8P2 + + ntpq/ntpq-opts.h@1.513 +3 -3 + NTP_4_2_8P2 + + ntpq/ntpq.1ntpqman@1.326 +3 -3 + NTP_4_2_8P2 + + ntpq/ntpq.1ntpqmdoc@1.326 +2 -2 + NTP_4_2_8P2 + + ntpq/ntpq.html@1.165 +2 -2 + NTP_4_2_8P2 + + ntpq/ntpq.man.in@1.326 +3 -3 + NTP_4_2_8P2 + + ntpq/ntpq.mdoc.in@1.326 +2 -2 + NTP_4_2_8P2 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.494 +2 -2 + NTP_4_2_8P2 + + ntpsnmpd/ntpsnmpd-opts.c@1.512 +68 -68 + NTP_4_2_8P2 + + ntpsnmpd/ntpsnmpd-opts.h@1.511 +3 -3 + NTP_4_2_8P2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.323 +3 -3 + NTP_4_2_8P2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.323 +2 -2 + NTP_4_2_8P2 + + ntpsnmpd/ntpsnmpd.html@1.163 +1 -1 + NTP_4_2_8P2 + + ntpsnmpd/ntpsnmpd.man.in@1.323 +3 -3 + NTP_4_2_8P2 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.323 +2 -2 + NTP_4_2_8P2 + + packageinfo.sh@1.509 +2 -2 + NTP_4_2_8P2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.84 +3 -3 + NTP_4_2_8P2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.85 +2 -2 + NTP_4_2_8P2 + + scripts/calc_tickadj/calc_tickadj.html@1.86 +1 -1 + NTP_4_2_8P2 + + scripts/calc_tickadj/calc_tickadj.man.in@1.83 +3 -3 + NTP_4_2_8P2 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.85 +2 -2 + NTP_4_2_8P2 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.88 +1 -1 + NTP_4_2_8P2 + + scripts/invoke-plot_summary.texi@1.105 +2 -2 + NTP_4_2_8P2 + + scripts/invoke-summary.texi@1.105 +2 -2 + NTP_4_2_8P2 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.315 +2 -2 + NTP_4_2_8P2 + + scripts/ntp-wait/ntp-wait-opts@1.51 +2 -2 + NTP_4_2_8P2 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.312 +3 -3 + NTP_4_2_8P2 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.313 +2 -2 + NTP_4_2_8P2 + + scripts/ntp-wait/ntp-wait.html@1.332 +2 -2 + NTP_4_2_8P2 + + scripts/ntp-wait/ntp-wait.man.in@1.312 +3 -3 + NTP_4_2_8P2 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.313 +2 -2 + NTP_4_2_8P2 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.103 +2 -2 + NTP_4_2_8P2 + + scripts/ntpsweep/ntpsweep-opts@1.53 +2 -2 + NTP_4_2_8P2 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.91 +3 -3 + NTP_4_2_8P2 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.91 +2 -2 + NTP_4_2_8P2 + + scripts/ntpsweep/ntpsweep.html@1.104 +2 -2 + NTP_4_2_8P2 + + scripts/ntpsweep/ntpsweep.man.in@1.91 +3 -3 + NTP_4_2_8P2 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.92 +2 -2 + NTP_4_2_8P2 + + scripts/ntptrace/invoke-ntptrace.texi@1.104 +2 -2 + NTP_4_2_8P2 + + scripts/ntptrace/ntptrace-opts@1.53 +2 -2 + NTP_4_2_8P2 + + scripts/ntptrace/ntptrace.1ntptraceman@1.91 +3 -3 + NTP_4_2_8P2 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.92 +2 -2 + NTP_4_2_8P2 + + scripts/ntptrace/ntptrace.html@1.105 +2 -2 + NTP_4_2_8P2 + + scripts/ntptrace/ntptrace.man.in@1.91 +3 -3 + NTP_4_2_8P2 + + scripts/ntptrace/ntptrace.mdoc.in@1.93 +2 -2 + NTP_4_2_8P2 + + scripts/plot_summary-opts@1.53 +2 -2 + NTP_4_2_8P2 + + scripts/plot_summary.1plot_summaryman@1.103 +3 -3 + NTP_4_2_8P2 + + scripts/plot_summary.1plot_summarymdoc@1.103 +2 -2 + NTP_4_2_8P2 + + scripts/plot_summary.html@1.106 +2 -2 + NTP_4_2_8P2 + + scripts/plot_summary.man.in@1.103 +3 -3 + NTP_4_2_8P2 + + scripts/plot_summary.mdoc.in@1.103 +2 -2 + NTP_4_2_8P2 + + scripts/summary-opts@1.53 +2 -2 + NTP_4_2_8P2 + + scripts/summary.1summaryman@1.103 +3 -3 + NTP_4_2_8P2 + + scripts/summary.1summarymdoc@1.103 +2 -2 + NTP_4_2_8P2 + + scripts/summary.html@1.106 +2 -2 + NTP_4_2_8P2 + + scripts/summary.man.in@1.103 +3 -3 + NTP_4_2_8P2 + + scripts/summary.mdoc.in@1.103 +2 -2 + NTP_4_2_8P2 + + scripts/update-leap/invoke-update-leap.texi@1.4 +1 -1 + NTP_4_2_8P2 + + scripts/update-leap/update-leap-opts@1.4 +2 -2 + NTP_4_2_8P2 + + scripts/update-leap/update-leap.1update-leapman@1.4 +3 -3 + NTP_4_2_8P2 + + scripts/update-leap/update-leap.1update-leapmdoc@1.4 +2 -2 + NTP_4_2_8P2 + + scripts/update-leap/update-leap.html@1.4 +1 -1 + NTP_4_2_8P2 + + scripts/update-leap/update-leap.man.in@1.4 +3 -3 + NTP_4_2_8P2 + + scripts/update-leap/update-leap.mdoc.in@1.4 +2 -2 + NTP_4_2_8P2 + + sntp/invoke-sntp.texi@1.492 +2 -2 + NTP_4_2_8P2 + + sntp/sntp-opts.c@1.511 +159 -159 + NTP_4_2_8P2 + + sntp/sntp-opts.h@1.509 +3 -3 + NTP_4_2_8P2 + + sntp/sntp.1sntpman@1.327 +3 -3 + NTP_4_2_8P2 + + sntp/sntp.1sntpmdoc@1.327 +2 -2 + NTP_4_2_8P2 + + sntp/sntp.html@1.507 +2 -2 + NTP_4_2_8P2 + + sntp/sntp.man.in@1.327 +3 -3 + NTP_4_2_8P2 + + sntp/sntp.mdoc.in@1.327 +2 -2 + NTP_4_2_8P2 + + util/invoke-ntp-keygen.texi@1.495 +2 -2 + NTP_4_2_8P2 + + util/ntp-keygen-opts.c@1.513 +173 -173 + NTP_4_2_8P2 + + util/ntp-keygen-opts.h@1.511 +3 -3 + NTP_4_2_8P2 + + util/ntp-keygen.1ntp-keygenman@1.323 +3 -3 + NTP_4_2_8P2 + + util/ntp-keygen.1ntp-keygenmdoc@1.323 +2 -2 + NTP_4_2_8P2 + + util/ntp-keygen.html@1.169 +2 -2 + NTP_4_2_8P2 + + util/ntp-keygen.man.in@1.323 +3 -3 + NTP_4_2_8P2 + + util/ntp-keygen.mdoc.in@1.323 +2 -2 + NTP_4_2_8P2 + +ChangeSet@1.3319, 2015-04-07 04:05:46-04:00, stenn@deacon.udel.edu + ntp-4.2.8p2 + + packageinfo.sh@1.508 +2 -2 + ntp-4.2.8p2 + +ChangeSet@1.3318, 2015-04-07 07:57:32+00:00, stenn@psp-fb1.ntp.org + NEWS update + + NEWS@1.135 +4 -2 + NEWS update + +ChangeSet@1.3314.1.4, 2015-04-07 07:43:04+00:00, stenn@psp-fb1.ntp.org + Initial import of the Unity test framework + + ChangeLog@1.1629.1.4 +1 -0 + Initial import of the Unity test framework + + sntp/unity/license.txt@1.1 +21 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/license.txt + + sntp/unity/license.txt@1.0 +0 -0 + + sntp/unity/unity.c@1.1 +1177 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity.c + + sntp/unity/unity.c@1.0 +0 -0 + + sntp/unity/unity.h@1.1 +272 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity.h + + sntp/unity/unity.h@1.0 +0 -0 + + sntp/unity/unity_internals.h@1.1 +692 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-unity/sntp/unity/unity_internals.h + + sntp/unity/unity_internals.h@1.0 +0 -0 + +ChangeSet@1.3314.1.3, 2015-04-03 03:56:38-04:00, stenn@deacon.udel.edu + NTP_4_2_8P2_RC3 + TAG: NTP_4_2_8P2_RC3 + + ChangeLog@1.1629.1.3 +1 -0 + NTP_4_2_8P2_RC3 + + ntpd/invoke-ntp.conf.texi@1.181 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/invoke-ntp.keys.texi@1.177 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/invoke-ntpd.texi@1.494 +2 -2 + NTP_4_2_8P2_RC3 + + ntpd/ntp.conf.5man@1.215 +3 -3 + NTP_4_2_8P2_RC3 + + ntpd/ntp.conf.5mdoc@1.215 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/ntp.conf.html@1.172 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/ntp.conf.man.in@1.215 +3 -3 + NTP_4_2_8P2_RC3 + + ntpd/ntp.conf.mdoc.in@1.215 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/ntp.keys.5man@1.211 +2 -2 + NTP_4_2_8P2_RC3 + + ntpd/ntp.keys.5mdoc@1.211 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/ntp.keys.html@1.173 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/ntp.keys.man.in@1.211 +2 -2 + NTP_4_2_8P2_RC3 + + ntpd/ntp.keys.mdoc.in@1.211 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/ntpd-opts.c@1.516 +7 -7 + NTP_4_2_8P2_RC3 + + ntpd/ntpd-opts.h@1.515 +3 -3 + NTP_4_2_8P2_RC3 + + ntpd/ntpd.1ntpdman@1.323 +3 -3 + NTP_4_2_8P2_RC3 + + ntpd/ntpd.1ntpdmdoc@1.323 +1 -1 + NTP_4_2_8P2_RC3 + + ntpd/ntpd.html@1.167 +2 -2 + NTP_4_2_8P2_RC3 + + ntpd/ntpd.man.in@1.323 +3 -3 + NTP_4_2_8P2_RC3 + + ntpd/ntpd.mdoc.in@1.323 +1 -1 + NTP_4_2_8P2_RC3 + + ntpdc/invoke-ntpdc.texi@1.491 +2 -2 + NTP_4_2_8P2_RC3 + + ntpdc/ntpdc-opts.c@1.509 +7 -7 + NTP_4_2_8P2_RC3 + + ntpdc/ntpdc-opts.h@1.508 +3 -3 + NTP_4_2_8P2_RC3 + + ntpdc/ntpdc.1ntpdcman@1.322 +3 -3 + NTP_4_2_8P2_RC3 + + ntpdc/ntpdc.1ntpdcmdoc@1.322 +1 -1 + NTP_4_2_8P2_RC3 + + ntpdc/ntpdc.html@1.335 +2 -2 + NTP_4_2_8P2_RC3 + + ntpdc/ntpdc.man.in@1.322 +3 -3 + NTP_4_2_8P2_RC3 + + ntpdc/ntpdc.mdoc.in@1.322 +1 -1 + NTP_4_2_8P2_RC3 + + ntpq/invoke-ntpq.texi@1.497 +2 -2 + NTP_4_2_8P2_RC3 + + ntpq/ntpq-opts.c@1.514 +7 -7 + NTP_4_2_8P2_RC3 + + ntpq/ntpq-opts.h@1.512 +3 -3 + NTP_4_2_8P2_RC3 + + ntpq/ntpq.1ntpqman@1.325 +3 -3 + NTP_4_2_8P2_RC3 + + ntpq/ntpq.1ntpqmdoc@1.325 +1 -1 + NTP_4_2_8P2_RC3 + + ntpq/ntpq.html@1.164 +2 -2 + NTP_4_2_8P2_RC3 + + ntpq/ntpq.man.in@1.325 +3 -3 + NTP_4_2_8P2_RC3 + + ntpq/ntpq.mdoc.in@1.325 +1 -1 + NTP_4_2_8P2_RC3 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.493 +2 -2 + NTP_4_2_8P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.c@1.511 +7 -7 + NTP_4_2_8P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.h@1.510 +3 -3 + NTP_4_2_8P2_RC3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.322 +3 -3 + NTP_4_2_8P2_RC3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.322 +1 -1 + NTP_4_2_8P2_RC3 + + ntpsnmpd/ntpsnmpd.html@1.162 +1 -1 + NTP_4_2_8P2_RC3 + + ntpsnmpd/ntpsnmpd.man.in@1.322 +3 -3 + NTP_4_2_8P2_RC3 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.322 +1 -1 + NTP_4_2_8P2_RC3 + + packageinfo.sh@1.507 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.83 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.84 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/calc_tickadj/calc_tickadj.html@1.85 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/calc_tickadj/calc_tickadj.man.in@1.82 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.84 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.87 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/invoke-plot_summary.texi@1.104 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/invoke-summary.texi@1.104 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.314 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntp-wait/ntp-wait-opts@1.50 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.311 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.312 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/ntp-wait/ntp-wait.html@1.331 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntp-wait/ntp-wait.man.in@1.311 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.312 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.102 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntpsweep/ntpsweep-opts@1.52 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.90 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.90 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/ntpsweep/ntpsweep.html@1.103 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntpsweep/ntpsweep.man.in@1.90 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.91 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/ntptrace/invoke-ntptrace.texi@1.103 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntptrace/ntptrace-opts@1.52 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntptrace/ntptrace.1ntptraceman@1.90 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.91 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/ntptrace/ntptrace.html@1.104 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/ntptrace/ntptrace.man.in@1.90 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/ntptrace/ntptrace.mdoc.in@1.92 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/plot_summary-opts@1.52 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/plot_summary.1plot_summaryman@1.102 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/plot_summary.1plot_summarymdoc@1.102 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/plot_summary.html@1.105 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/plot_summary.man.in@1.102 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/plot_summary.mdoc.in@1.102 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/summary-opts@1.52 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/summary.1summaryman@1.102 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/summary.1summarymdoc@1.102 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/summary.html@1.105 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/summary.man.in@1.102 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/summary.mdoc.in@1.102 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/update-leap/invoke-update-leap.texi@1.3 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/update-leap/update-leap-opts@1.3 +2 -2 + NTP_4_2_8P2_RC3 + + scripts/update-leap/update-leap.1update-leapman@1.3 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/update-leap/update-leap.1update-leapmdoc@1.3 +1 -1 + NTP_4_2_8P2_RC3 + + scripts/update-leap/update-leap.html@1.3 +6 -5 + NTP_4_2_8P2_RC3 + + scripts/update-leap/update-leap.man.in@1.3 +3 -3 + NTP_4_2_8P2_RC3 + + scripts/update-leap/update-leap.mdoc.in@1.3 +1 -1 + NTP_4_2_8P2_RC3 + + sntp/invoke-sntp.texi@1.491 +2 -2 + NTP_4_2_8P2_RC3 + + sntp/sntp-opts.c@1.510 +7 -7 + NTP_4_2_8P2_RC3 + + sntp/sntp-opts.h@1.508 +3 -3 + NTP_4_2_8P2_RC3 + + sntp/sntp.1sntpman@1.326 +3 -3 + NTP_4_2_8P2_RC3 + + sntp/sntp.1sntpmdoc@1.326 +1 -1 + NTP_4_2_8P2_RC3 + + sntp/sntp.html@1.506 +2 -2 + NTP_4_2_8P2_RC3 + + sntp/sntp.man.in@1.326 +3 -3 + NTP_4_2_8P2_RC3 + + sntp/sntp.mdoc.in@1.326 +1 -1 + NTP_4_2_8P2_RC3 + + util/invoke-ntp-keygen.texi@1.494 +2 -2 + NTP_4_2_8P2_RC3 + + util/ntp-keygen-opts.c@1.512 +7 -7 + NTP_4_2_8P2_RC3 + + util/ntp-keygen-opts.h@1.510 +3 -3 + NTP_4_2_8P2_RC3 + + util/ntp-keygen.1ntp-keygenman@1.322 +3 -3 + NTP_4_2_8P2_RC3 + + util/ntp-keygen.1ntp-keygenmdoc@1.322 +1 -1 + NTP_4_2_8P2_RC3 + + util/ntp-keygen.html@1.168 +2 -2 + NTP_4_2_8P2_RC3 + + util/ntp-keygen.man.in@1.322 +3 -3 + NTP_4_2_8P2_RC3 + + util/ntp-keygen.mdoc.in@1.322 +1 -1 + NTP_4_2_8P2_RC3 + +ChangeSet@1.3314.1.2, 2015-04-03 03:35:54-04:00, stenn@deacon.udel.edu + [Bug 2763] Fix for different thresholds for forward and backward steps + + ChangeLog@1.1629.1.2 +3 -0 + [Bug 2763] Fix for different thresholds for forward and backward steps + + ntpd/ntp_loopfilter.c@1.183 +2 -2 + [Bug 2763] Fix for different thresholds for forward and backward steps + +ChangeSet@1.3314.1.1, 2015-04-03 01:16:34-04:00, stenn@deacon.udel.edu + NTP_4_2_8P2_RC2 + TAG: NTP_4_2_8P2_RC2 + + ChangeLog@1.1629.1.1 +1 -0 + NTP_4_2_8P2_RC2 + + ntpd/invoke-ntp.conf.texi@1.180 +1 -1 + NTP_4_2_8P2_RC2 + + ntpd/invoke-ntp.keys.texi@1.176 +1 -1 + NTP_4_2_8P2_RC2 + + ntpd/invoke-ntpd.texi@1.493 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntp.conf.5man@1.214 +3 -3 + NTP_4_2_8P2_RC2 + + ntpd/ntp.conf.5mdoc@1.214 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntp.conf.html@1.171 +1 -1 + NTP_4_2_8P2_RC2 + + ntpd/ntp.conf.man.in@1.214 +3 -3 + NTP_4_2_8P2_RC2 + + ntpd/ntp.conf.mdoc.in@1.214 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntp.keys.5man@1.210 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntp.keys.5mdoc@1.210 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntp.keys.html@1.172 +1 -1 + NTP_4_2_8P2_RC2 + + ntpd/ntp.keys.man.in@1.210 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntp.keys.mdoc.in@1.210 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntpd-opts.c@1.515 +7 -7 + NTP_4_2_8P2_RC2 + + ntpd/ntpd-opts.h@1.514 +3 -3 + NTP_4_2_8P2_RC2 + + ntpd/ntpd.1ntpdman@1.322 +3 -3 + NTP_4_2_8P2_RC2 + + ntpd/ntpd.1ntpdmdoc@1.322 +2 -2 + NTP_4_2_8P2_RC2 + + ntpd/ntpd.html@1.166 +50 -26 + NTP_4_2_8P2_RC2 + + ntpd/ntpd.man.in@1.322 +3 -3 + NTP_4_2_8P2_RC2 + + ntpd/ntpd.mdoc.in@1.322 +2 -2 + NTP_4_2_8P2_RC2 + + ntpdc/invoke-ntpdc.texi@1.490 +2 -2 + NTP_4_2_8P2_RC2 + + ntpdc/ntpdc-opts.c@1.508 +7 -7 + NTP_4_2_8P2_RC2 + + ntpdc/ntpdc-opts.h@1.507 +3 -3 + NTP_4_2_8P2_RC2 + + ntpdc/ntpdc.1ntpdcman@1.321 +3 -3 + NTP_4_2_8P2_RC2 + + ntpdc/ntpdc.1ntpdcmdoc@1.321 +2 -2 + NTP_4_2_8P2_RC2 + + ntpdc/ntpdc.html@1.334 +2 -2 + NTP_4_2_8P2_RC2 + + ntpdc/ntpdc.man.in@1.321 +3 -3 + NTP_4_2_8P2_RC2 + + ntpdc/ntpdc.mdoc.in@1.321 +2 -2 + NTP_4_2_8P2_RC2 + + ntpq/invoke-ntpq.texi@1.496 +2 -2 + NTP_4_2_8P2_RC2 + + ntpq/ntpq-opts.c@1.513 +7 -7 + NTP_4_2_8P2_RC2 + + ntpq/ntpq-opts.h@1.511 +3 -3 + NTP_4_2_8P2_RC2 + + ntpq/ntpq.1ntpqman@1.324 +3 -3 + NTP_4_2_8P2_RC2 + + ntpq/ntpq.1ntpqmdoc@1.324 +2 -2 + NTP_4_2_8P2_RC2 + + ntpq/ntpq.html@1.163 +2 -2 + NTP_4_2_8P2_RC2 + + ntpq/ntpq.man.in@1.324 +3 -3 + NTP_4_2_8P2_RC2 + + ntpq/ntpq.mdoc.in@1.324 +2 -2 + NTP_4_2_8P2_RC2 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.492 +2 -2 + NTP_4_2_8P2_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.510 +7 -7 + NTP_4_2_8P2_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.509 +3 -3 + NTP_4_2_8P2_RC2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.321 +3 -3 + NTP_4_2_8P2_RC2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.321 +2 -2 + NTP_4_2_8P2_RC2 + + ntpsnmpd/ntpsnmpd.html@1.161 +1 -1 + NTP_4_2_8P2_RC2 + + ntpsnmpd/ntpsnmpd.man.in@1.321 +3 -3 + NTP_4_2_8P2_RC2 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.321 +2 -2 + NTP_4_2_8P2_RC2 + + packageinfo.sh@1.506 +1 -1 + NTP_4_2_8P2_RC2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.82 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.83 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/calc_tickadj/calc_tickadj.html@1.84 +1 -1 + NTP_4_2_8P2_RC2 + + scripts/calc_tickadj/calc_tickadj.man.in@1.81 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.83 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.86 +1 -1 + NTP_4_2_8P2_RC2 + + scripts/invoke-plot_summary.texi@1.103 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/invoke-summary.texi@1.103 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.313 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntp-wait/ntp-wait-opts@1.49 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.310 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.311 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntp-wait/ntp-wait.html@1.330 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntp-wait/ntp-wait.man.in@1.310 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.311 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.101 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntpsweep/ntpsweep-opts@1.51 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.89 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.89 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntpsweep/ntpsweep.html@1.102 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntpsweep/ntpsweep.man.in@1.89 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.90 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntptrace/invoke-ntptrace.texi@1.102 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntptrace/ntptrace-opts@1.51 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntptrace/ntptrace.1ntptraceman@1.89 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.90 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntptrace/ntptrace.html@1.103 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/ntptrace/ntptrace.man.in@1.89 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/ntptrace/ntptrace.mdoc.in@1.91 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/plot_summary-opts@1.51 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/plot_summary.1plot_summaryman@1.101 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/plot_summary.1plot_summarymdoc@1.101 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/plot_summary.html@1.104 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/plot_summary.man.in@1.101 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/plot_summary.mdoc.in@1.101 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/summary-opts@1.51 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/summary.1summaryman@1.101 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/summary.1summarymdoc@1.101 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/summary.html@1.104 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/summary.man.in@1.101 +3 -3 + NTP_4_2_8P2_RC2 + + scripts/summary.mdoc.in@1.101 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/update-leap/invoke-update-leap.texi@1.2 +6 -5 + NTP_4_2_8P2_RC2 + + scripts/update-leap/update-leap-opts@1.2 +2 -2 + NTP_4_2_8P2_RC2 + + scripts/update-leap/update-leap.1update-leapman@1.2 +7 -6 + NTP_4_2_8P2_RC2 + + scripts/update-leap/update-leap.1update-leapmdoc@1.2 +6 -5 + NTP_4_2_8P2_RC2 + + scripts/update-leap/update-leap.html@1.2 +48 -72 + NTP_4_2_8P2_RC2 + + scripts/update-leap/update-leap.man.in@1.2 +7 -6 + NTP_4_2_8P2_RC2 + + scripts/update-leap/update-leap.mdoc.in@1.2 +6 -5 + NTP_4_2_8P2_RC2 + + sntp/invoke-sntp.texi@1.490 +2 -2 + NTP_4_2_8P2_RC2 + + sntp/sntp-opts.c@1.509 +7 -7 + NTP_4_2_8P2_RC2 + + sntp/sntp-opts.h@1.507 +3 -3 + NTP_4_2_8P2_RC2 + + sntp/sntp.1sntpman@1.325 +3 -3 + NTP_4_2_8P2_RC2 + + sntp/sntp.1sntpmdoc@1.325 +2 -2 + NTP_4_2_8P2_RC2 + + sntp/sntp.html@1.505 +111 -135 + NTP_4_2_8P2_RC2 + + sntp/sntp.man.in@1.325 +3 -3 + NTP_4_2_8P2_RC2 + + sntp/sntp.mdoc.in@1.325 +2 -2 + NTP_4_2_8P2_RC2 + + util/invoke-ntp-keygen.texi@1.493 +2 -2 + NTP_4_2_8P2_RC2 + + util/ntp-keygen-opts.c@1.511 +7 -7 + NTP_4_2_8P2_RC2 + + util/ntp-keygen-opts.h@1.509 +3 -3 + NTP_4_2_8P2_RC2 + + util/ntp-keygen.1ntp-keygenman@1.321 +3 -3 + NTP_4_2_8P2_RC2 + + util/ntp-keygen.1ntp-keygenmdoc@1.321 +2 -2 + NTP_4_2_8P2_RC2 + + util/ntp-keygen.html@1.167 +2 -2 + NTP_4_2_8P2_RC2 + + util/ntp-keygen.man.in@1.321 +3 -3 + NTP_4_2_8P2_RC2 + + util/ntp-keygen.mdoc.in@1.321 +2 -2 + NTP_4_2_8P2_RC2 + +ChangeSet@1.3314, 2015-04-03 02:36:18+00:00, stenn@psp-fb1.ntp.org + merge cleanup + + NEWS@1.133 +6 -5 + merge cleanup + +ChangeSet@1.3313, 2015-04-03 02:31:18+00:00, stenn@psp-fb1.ntp.org + merge cleanup + + ChangeLog@1.1629 +3 -3 + merge cleanup + +ChangeSet@1.3308.2.11, 2015-04-02 21:42:37+00:00, stenn@psp-deb1.ntp.org + [Bug 2592] FLAG_TSTAMP_PPS cleanup for refclock_parse.c + + ChangeLog@1.1625.2.9 +1 -0 + [Bug 2592] FLAG_TSTAMP_PPS cleanup for refclock_parse.c + +ChangeSet@1.3308.2.10, 2015-04-02 20:17:55+00:00, stenn@psp-deb1.ntp.org + merge cleanup + + ChangeLog@1.1625.2.8 +1 -3 + merge cleanup + +ChangeSet@1.3308.2.9, 2015-04-02 21:41:22+02:00, jnperlin@nemesis.localnet + [Bug 2795] Cannot build without OpenSLL (on Win32). + fixed minor warning + + ChangeLog@1.1625.2.7 +3 -0 + [Bug 2795] Cannot build without OpenSLL (on Win32). + fixed minor warning + + include/ntp_md5.h@1.10 +1 -1 + [Bug 2795] Cannot build without OpenSLL (on Win32). + OpenSSL declares EVP_md5() as function without arguments; surrogate should do the same. + +ChangeSet@1.3308.6.2, 2015-04-02 07:45:04+00:00, stenn@psp-deb1.ntp.org + cleanup + + ChangeLog@1.1625.6.3 +0 -2 + cleanup + + ChangeLog@1.1625.6.2 +6 -0 + + ntpd/invoke-ntpd.texi@1.492 +20 -3 + [Bug 2788] New -G flag (force step once) cleanup. + + ntpd/ntp_loopfilter.c@1.182 +17 -6 + [Bug 2794] Clean up kernel clock status reports. + Trailing whitespace cleanup. + + ntpd/ntpd-opts.c@1.514 +249 -249 + Autogenerated file. + + ntpd/ntpd-opts.h@1.513 +3 -3 + Autogenerated file. + + ntpd/ntpd.1ntpdman@1.321 +19 -5 + Autogenerated file. + + ntpd/ntpd.1ntpdmdoc@1.321 +17 -4 + Autogenerated file. + + ntpd/ntpd.man.in@1.321 +19 -5 + Autogenerated file. + + ntpd/ntpd.mdoc.in@1.321 +17 -4 + Autogenerated file. + + ntpd/ntpdbase-opts.def@1.29 +9 -6 + [Bug 2788] New flag -G (force_step_once) - documentation cleanup. + +ChangeSet@1.3308.2.7, 2015-04-02 07:34:40+00:00, stenn@psp-deb1.ntp.org + Simple cleanup to html/build.html + + ChangeLog@1.1625.2.5 +1 -0 + Simple cleanup to html/build.html + + html/build.html@1.28 +2 -2 + Simple cleanup to html/build.html + +ChangeSet@1.3308.2.6, 2015-04-02 03:15:42+00:00, stenn@psp-fb1.ntp.org + typos + + ChangeLog@1.1625.2.4 +4 -4 + typos + +ChangeSet@1.3308.5.2, 2015-04-01 11:08:14+00:00, stenn@psp-deb1.ntp.org + [Bug 2798] sntp should decode and display the leap indicator + + html/sntp.html@1.12 +3 -3 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/invoke-sntp.texi@1.489 +4 -3 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp-opts.c@1.508 +1 -1 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp-opts.def@1.47 +2 -1 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp-opts.h@1.506 +1 -1 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp.1sntpman@1.324 +5 -4 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp.1sntpmdoc@1.324 +4 -3 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp.html@1.504 +136 -111 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp.man.in@1.324 +5 -4 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/sntp.mdoc.in@1.324 +4 -3 + [Bug 2798] sntp should decode and display the leap indicator + +ChangeSet@1.3308.5.1, 2015-04-01 10:44:24+00:00, stenn@psp-fb1.ntp.org + [Bug 2798] sntp should decode and display the leap indicator + + ChangeLog@1.1625.5.1 +3 -0 + [Bug 2798] sntp should decode and display the leap indicator + + sntp/main.c@1.95 +21 -1 + [Bug 2798] sntp should decode and display the leap indicator + +ChangeSet@1.3308.4.1, 2015-03-30 20:14:46+02:00, jnperlin@hydra.(none) + [Bug 2797] ntp-keygen trapped in endless loop for MD5 keys on big-endian machines + + ChangeLog@1.1625.4.1 +3 -0 + [Bug 2797] ntp-keygen trapped in endless loop for MD5 keys on big-endian machines + + util/ntp-keygen.c@1.104 +4 -4 + [Bug 2797] ntp-keygen trapped in endless loop for MD5 keys on big-endian machines + +ChangeSet@1.3308.3.1, 2015-03-30 19:39:17+02:00, jnperlin@nemesis.localnet + [Bug 2796] ntp-keygen crashes in 'getclock()' on Win32 + + ChangeLog@1.1625.3.1 +2 -0 + [Bug 2796] ntp-keygen crashes in 'getclock()' on Win32 + + ports/winnt/libntp/getclock.c@1.5 +2 -0 + [Bug 2796] ntp-keygen crashes in 'getclock()' on Win32 + make sure 'init_win_precise_time()' gets called + +ChangeSet@1.3308.2.4, 2015-03-30 19:10:12+02:00, jnperlin@nemesis.localnet + [Bug 2795] Cannot build without OpenSLL (on Win32) + Provided a Win32 specific wrapper around libevent/arc4random.c + + ChangeLog@1.1625.2.2 +3 -0 + [Bug 2795] Cannot build without OpenSLL (on Win32) + Provided a Win32 specific wrapper around libevent/arc4random.c + + ports/winnt/libntp/arc4wrap.c@1.1 +84 -0 + [Bug 2795] Cannot build without OpenSLL (on Win32) + Provided a Win32 specific wrapper around libevent/arc4random.c + + ports/winnt/libntp/arc4wrap.c@1.0 +0 -0 + + ports/winnt/vs2005/libntp.vcproj@1.24 +4 -0 + [Bug 2795] Cannot build without OpenSLL (on Win32) + Provided a Win32 specific wrapper around libevent/arc4random.c + + ports/winnt/vs2008/libntp/libntp.vcproj@1.52 +6 -2 + [Bug 2795] Cannot build without OpenSLL (on Win32) + Provided a Win32 specific wrapper around libevent/arc4random.c + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.6 +1 -0 + [Bug 2795] Cannot build without OpenSLL (on Win32) + Provided a Win32 specific wrapper around libevent/arc4random.c + + ports/winnt/vs2013/libntp/libntp.vcxproj.filters@1.4 +6 -0 + [Bug 2795] Cannot build without OpenSLL (on Win32) + Provided a Win32 specific wrapper around libevent/arc4random.c + +ChangeSet@1.3305.4.8, 2015-03-30 15:55:43+02:00, martin@pc-martin.(none) + [Bug 2794] Don't let reports on normal kernel status changes look like errors. + + ChangeLog@1.1622.4.8 +2 -0 + [Bug 2794] Don't let reports on normal kernel status changes look like errors. + + ntpd/ntp_loopfilter.c@1.181 +30 -19 + [Bug 2794] Don't let reports on normal kernel status changes look like errors. + +ChangeSet@1.3305.4.7, 2015-03-30 11:23:48+02:00, martin@pc-martin.(none) + [Bug 2788] New flag -G (force_step_once) + + ChangeLog@1.1622.4.7 +1 -0 + [Bug 2788] New flag -G (force_step_once) + + include/ntpd.h@1.185.1.1 +4 -3 + [Bug 2788] Support new flag -G (force_step_once) + Removed trailing whitespace. + + ntpd/cmd_args.c@1.62 +6 -3 + [Bug 2788] New flag -G (force_step_once) + Removed trailing whitespace. + + ntpd/ntp_loopfilter.c@1.180 +21 -15 + [Bug 2788] New flag -G (force_step_once) + Removed trailing whitespace. + + ntpd/ntpd-opts.c@1.511.1.1 +255 -225 + [Bug 2788] New flag -G (force_step_once) + + ntpd/ntpd-opts.h@1.510.1.1 +36 -29 + [Bug 2788] New flag -G (force_step_once) + + ntpd/ntpdbase-opts.def@1.28 +17 -2 + [Bug 2788] New flag -G (force_step_once) + Removed trailing whitespace. + +ChangeSet@1.3308.1.3, 2015-03-30 09:11:33+00:00, stenn@psp-fb1.ntp.org + Start the RC cycle for ntp-4.2.8p2 + + NEWS@1.130.1.2 +82 -1 + Start the RC cycle for ntp-4.2.8p2 + +ChangeSet@1.3308.2.3, 2015-03-30 04:48:27-04:00, stenn@deacon.udel.edu + NTP_4_2_8P2_RC1 + TAG: NTP_4_2_8P2_RC1 + + ChangeLog@1.1625.2.1 +1 -0 + NTP_4_2_8P2_RC1 + + ntpd/invoke-ntp.conf.texi@1.179 +1 -1 + NTP_4_2_8P2_RC1 + + ntpd/invoke-ntp.keys.texi@1.175 +1 -1 + NTP_4_2_8P2_RC1 + + ntpd/invoke-ntpd.texi@1.491 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntp.conf.5man@1.213 +3 -3 + NTP_4_2_8P2_RC1 + + ntpd/ntp.conf.5mdoc@1.213 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntp.conf.html@1.170 +13 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntp.conf.man.in@1.213 +3 -3 + NTP_4_2_8P2_RC1 + + ntpd/ntp.conf.mdoc.in@1.213 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntp.keys.5man@1.209 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntp.keys.5mdoc@1.209 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntp.keys.html@1.171 +1 -1 + NTP_4_2_8P2_RC1 + + ntpd/ntp.keys.man.in@1.209 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntp.keys.mdoc.in@1.209 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntpd-opts.c@1.512 +239 -239 + NTP_4_2_8P2_RC1 + + ntpd/ntpd-opts.h@1.511 +3 -3 + NTP_4_2_8P2_RC1 + + ntpd/ntpd.1ntpdman@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + ntpd/ntpd.1ntpdmdoc@1.320 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntpd.html@1.165 +2 -2 + NTP_4_2_8P2_RC1 + + ntpd/ntpd.man.in@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + ntpd/ntpd.mdoc.in@1.320 +2 -2 + NTP_4_2_8P2_RC1 + + ntpdc/invoke-ntpdc.texi@1.489 +2 -2 + NTP_4_2_8P2_RC1 + + ntpdc/ntpdc-opts.c@1.507 +107 -107 + NTP_4_2_8P2_RC1 + + ntpdc/ntpdc-opts.h@1.506 +3 -3 + NTP_4_2_8P2_RC1 + + ntpdc/ntpdc.1ntpdcman@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + ntpdc/ntpdc.1ntpdcmdoc@1.320 +2 -2 + NTP_4_2_8P2_RC1 + + ntpdc/ntpdc.html@1.333 +2 -2 + NTP_4_2_8P2_RC1 + + ntpdc/ntpdc.man.in@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + ntpdc/ntpdc.mdoc.in@1.320 +2 -2 + NTP_4_2_8P2_RC1 + + ntpq/invoke-ntpq.texi@1.495 +2 -2 + NTP_4_2_8P2_RC1 + + ntpq/ntpq-opts.c@1.512 +106 -106 + NTP_4_2_8P2_RC1 + + ntpq/ntpq-opts.h@1.510 +3 -3 + NTP_4_2_8P2_RC1 + + ntpq/ntpq.1ntpqman@1.323 +3 -3 + NTP_4_2_8P2_RC1 + + ntpq/ntpq.1ntpqmdoc@1.323 +2 -2 + NTP_4_2_8P2_RC1 + + ntpq/ntpq.html@1.162 +2 -2 + NTP_4_2_8P2_RC1 + + ntpq/ntpq.man.in@1.323 +3 -3 + NTP_4_2_8P2_RC1 + + ntpq/ntpq.mdoc.in@1.323 +2 -2 + NTP_4_2_8P2_RC1 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.491 +2 -2 + NTP_4_2_8P2_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.509 +68 -68 + NTP_4_2_8P2_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.508 +3 -3 + NTP_4_2_8P2_RC1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.320 +2 -2 + NTP_4_2_8P2_RC1 + + ntpsnmpd/ntpsnmpd.html@1.160 +1 -1 + NTP_4_2_8P2_RC1 + + ntpsnmpd/ntpsnmpd.man.in@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.320 +2 -2 + NTP_4_2_8P2_RC1 + + packageinfo.sh@1.505 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.81 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.82 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/calc_tickadj/calc_tickadj.html@1.83 +1 -1 + NTP_4_2_8P2_RC1 + + scripts/calc_tickadj/calc_tickadj.man.in@1.80 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.82 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.85 +1 -1 + NTP_4_2_8P2_RC1 + + scripts/invoke-plot_summary.texi@1.102 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/invoke-summary.texi@1.102 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.312 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntp-wait/ntp-wait-opts@1.48 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.309 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.310 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntp-wait/ntp-wait.html@1.329 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntp-wait/ntp-wait.man.in@1.309 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.310 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.100 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntpsweep/ntpsweep-opts@1.50 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.88 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.88 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntpsweep/ntpsweep.html@1.101 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntpsweep/ntpsweep.man.in@1.88 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.89 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntptrace/invoke-ntptrace.texi@1.101 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntptrace/ntptrace-opts@1.50 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntptrace/ntptrace.1ntptraceman@1.88 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.89 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntptrace/ntptrace.html@1.102 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/ntptrace/ntptrace.man.in@1.88 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/ntptrace/ntptrace.mdoc.in@1.90 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/plot_summary-opts@1.50 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/plot_summary.1plot_summaryman@1.100 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/plot_summary.1plot_summarymdoc@1.100 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/plot_summary.html@1.103 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/plot_summary.man.in@1.100 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/plot_summary.mdoc.in@1.100 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/summary-opts@1.50 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/summary.1summaryman@1.100 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/summary.1summarymdoc@1.100 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/summary.html@1.103 +2 -2 + NTP_4_2_8P2_RC1 + + scripts/summary.man.in@1.100 +3 -3 + NTP_4_2_8P2_RC1 + + scripts/summary.mdoc.in@1.100 +2 -2 + NTP_4_2_8P2_RC1 + + sntp/invoke-sntp.texi@1.488 +2 -2 + NTP_4_2_8P2_RC1 + + sntp/sntp-opts.c@1.507 +159 -159 + NTP_4_2_8P2_RC1 + + sntp/sntp-opts.h@1.505 +3 -3 + NTP_4_2_8P2_RC1 + + sntp/sntp.1sntpman@1.323 +3 -3 + NTP_4_2_8P2_RC1 + + sntp/sntp.1sntpmdoc@1.323 +2 -2 + NTP_4_2_8P2_RC1 + + sntp/sntp.html@1.503 +2 -2 + NTP_4_2_8P2_RC1 + + sntp/sntp.man.in@1.323 +3 -3 + NTP_4_2_8P2_RC1 + + sntp/sntp.mdoc.in@1.323 +2 -2 + NTP_4_2_8P2_RC1 + + util/invoke-ntp-keygen.texi@1.492 +2 -2 + NTP_4_2_8P2_RC1 + + util/ntp-keygen-opts.c@1.510 +173 -173 + NTP_4_2_8P2_RC1 + + util/ntp-keygen-opts.h@1.508 +3 -3 + NTP_4_2_8P2_RC1 + + util/ntp-keygen.1ntp-keygenman@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + util/ntp-keygen.1ntp-keygenmdoc@1.320 +2 -2 + NTP_4_2_8P2_RC1 + + util/ntp-keygen.html@1.166 +2 -2 + NTP_4_2_8P2_RC1 + + util/ntp-keygen.man.in@1.320 +3 -3 + NTP_4_2_8P2_RC1 + + util/ntp-keygen.mdoc.in@1.320 +2 -2 + NTP_4_2_8P2_RC1 + +ChangeSet@1.3308.2.2, 2015-03-30 04:25:58-04:00, stenn@deacon.udel.edu + Begin 4.2.8p2-RC1 + + packageinfo.sh@1.504 +1 -1 + Begin 4.2.8p2-RC1 + +ChangeSet@1.3308.2.1, 2015-03-30 08:18:35+00:00, stenn@psp-fb1.ntp.org + Start the RC cycle for ntp-4.2.8p2 + + NEWS@1.130.1.1 +49 -0 + Start the RC cycle for ntp-4.2.8p2 + +ChangeSet@1.3311, 2015-03-29 05:05:41+00:00, stenn@psp-fb1.ntp.org + [Bug 2769] cleannup for update-leap + + ChangeLog@1.1627 +1 -0 + [Bug 2769] cleannup for update-leap + +ChangeSet@1.3310, 2015-03-29 04:10:31+00:00, stenn@psp-fb1.ntp.org + [Bug 2769] cleannup for update-leap + + NEWS@1.131 +8 -0 + [Bug 2769] cleannup for update-leap + + scripts/update-leap/Makefile.am@1.3 +1 -0 + [Bug 2769] cleannup for update-leap + + scripts/update-leap/update-leap-opts.def@1.2 +4 -3 + [Bug 2769] cleannup for update-leap + +ChangeSet@1.3308, 2015-03-29 01:49:10+00:00, stenn@psp-deb1.ntp.org + [Bug 2346] "graceful termination" signals do not do peer cleanup + + ChangeLog@1.1625 +1 -0 + [Bug 2346] "graceful termination" signals do not do peer cleanup + + include/ntpd.h@1.186 +1 -0 + [Bug 2346] "graceful termination" signals do not do peer cleanup + + ntpd/ntp_peer.c@1.154 +20 -0 + [Bug 2346] "graceful termination" signals do not do peer cleanup + + ntpd/ntpd.c@1.159 +1 -0 + [Bug 2346] "graceful termination" signals do not do peer cleanup + +ChangeSet@1.3305.4.6, 2015-03-25 17:32:25+01:00, martin@pc-martin.(none) + [Bug 2592] Account for PPS sources which can provide an accurate absolute time stamp, and status information. + + ChangeLog@1.1622.4.6 +2 -0 + [Bug 2592] Account for PPS sources which can provide an accurate absolute time stamp, and status information. + + include/ntp.h@1.213 +2 -1 + New flag FLAG_TSTAMP_PPS. + + ntpd/ntp_proto.c@1.353.1.2 +2 -1 + [Bug 2592] Account for PPS sources which can provide an accurate absolute time stamp, and status information. + + ntpd/refclock_parse.c@1.78 +2 -2 + [Bug 2592] Parse driver can return absolute timestamp with PPS, and status information. + +ChangeSet@1.3305.4.5, 2015-03-25 17:24:59+01:00, martin@pc-martin.(none) + Fixed indention and removed trailing whitespace. + + ChangeLog@1.1622.4.5 +1 -0 + Fixed indention and removed trailing whitespace. + + include/ntp.h@1.212 +4 -4 + Fixed indention. + + include/parse_conf.h@1.7 +6 -6 + Fixed indention. + + ntpd/ntp_proto.c@1.353.1.1 +27 -27 + Removed trailing whitespace. + + ntpd/refclock_parse.c@1.77 +16 -16 + Fixed indention. + +ChangeSet@1.3305.4.4, 2015-03-22 07:59:12+00:00, stenn@psp-fb1.ntp.org + merge cleanup + + ChangeLog@1.1622.4.4 +0 -1 + merge cleanup + +ChangeSet@1.3305.6.3, 2015-03-22 07:24:07+00:00, stenn@psp-fb1.ntp.org + Bug 2791 -> Bug 2789 + + ChangeLog@1.1622.6.3 +1 -1 + Bug 2791 -> Bug 2789 + +ChangeSet@1.3305.6.2, 2015-03-22 06:59:06+00:00, stenn@psp-fb1.ntp.org + Merge cleanup + + ChangeLog@1.1622.6.2 +22 -22 + Merge cleanup + +ChangeSet@1.3305.5.2, 2015-03-22 03:48:52+00:00, stenn@psp-fb1.ntp.org + [Bug 2769] New script: update-leap + + .point-changed-filelist@1.26 +7 -0 + [Bug 2769] New script: update-leap + + scripts/update-leap/Makefile.am@1.2 +2 -1 + [Bug 2769] New script: update-leap + +ChangeSet@1.3305.5.1, 2015-03-22 03:01:33+00:00, stenn@psp-fb1.ntp.org + [Bug 2769] New script: update-leap + + BitKeeper/etc/ignore@1.86 +1 -0 + added Makefile.in + + ChangeLog@1.1622.5.1 +1 -0 + [Bug 2769] New script: update-leap + + configure.ac@1.584.1.1 +8 -7 + [Bug 2769] New script: update-leap + + scripts/Makefile.am@1.40 +1 -0 + [Bug 2769] New script: update-leap + + scripts/update-leap/Makefile.am@1.1 +95 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/Makefile.am + + scripts/update-leap/Makefile.am@1.0 +0 -0 + + scripts/update-leap/invoke-update-leap.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/invoke-update-leap.menu + + scripts/update-leap/invoke-update-leap.menu@1.0 +0 -0 + + scripts/update-leap/invoke-update-leap.texi@1.1 +169 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/invoke-update-leap.texi + + scripts/update-leap/invoke-update-leap.texi@1.0 +0 -0 + + scripts/update-leap/update-leap@1.1 +434 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap + + scripts/update-leap/update-leap@1.0 +0 -0 + + scripts/update-leap/update-leap-opts@1.1 +72 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap-opts + + scripts/update-leap/update-leap-opts@1.0 +0 -0 + + scripts/update-leap/update-leap-opts.def@1.1 +162 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap-opts.def + + scripts/update-leap/update-leap-opts.def@1.0 +0 -0 + + scripts/update-leap/update-leap.1update-leapman@1.1 +168 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap.1update-leapman + + scripts/update-leap/update-leap.1update-leapman@1.0 +0 -0 + + scripts/update-leap/update-leap.1update-leapmdoc@1.1 +133 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap.1update-leapmdoc + + scripts/update-leap/update-leap.1update-leapmdoc@1.0 +0 -0 + + scripts/update-leap/update-leap.html@1.1 +297 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap.html + + scripts/update-leap/update-leap.html@1.0 +0 -0 + + scripts/update-leap/update-leap.man.in@1.1 +168 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap.man.in + + scripts/update-leap/update-leap.man.in@1.0 +0 -0 + + scripts/update-leap/update-leap.mdoc.in@1.1 +133 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap.mdoc.in + + scripts/update-leap/update-leap.mdoc.in@1.0 +0 -0 + + scripts/update-leap/update-leap.texi@1.1 +43 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2769/scripts/update-leap/update-leap.texi + + scripts/update-leap/update-leap.texi@1.0 +0 -0 + + sntp/loc/darwin@1.3 +1 -0 + [Bug 2769] New script: update-leap + + sntp/loc/debian@1.4 +1 -0 + [Bug 2769] New script: update-leap + + sntp/loc/freebsd@1.6 +1 -0 + [Bug 2769] New script: update-leap + + sntp/loc/legacy@1.7 +1 -0 + [Bug 2769] New script: update-leap + + sntp/loc/netbsd@1.4 +1 -0 + [Bug 2769] New script: update-leap + + sntp/loc/solaris@1.7 +1 -0 + [Bug 2769] New script: update-leap + + sntp/m4/ntp_locinfo.m4@1.18 +6 -0 + [Bug 2769] New script: update-leap + +ChangeSet@1.3305.4.1, 2015-03-20 13:03:38+01:00, burnicki@pc-martin4. + [Bug 2790] If ntpd sets the Windows MM timer highest resolution then pause + briefly before measuring system clock precision to yield correct results. + + ChangeLog@1.1622.4.1 +3 -1 + [Bug 2790] If ntpd sets the Windows MM timer highest resolution then pause + briefly before measuring system clock precision to yield correct results. + + ports/winnt/ntpd/nt_clockstuff.c@1.65 +4 -0 + [Bug 2790] If ntpd sets the Windows MM timer highest resolution then pause + briefly before measuring system clock precision to yield correct results. + +ChangeSet@1.3305.3.6, 2015-03-20 11:47:15+01:00, martin@pc-martin.(none) + [Bug 2791] Quiet compiler warnings from libevent. + + ChangeLog@1.1622.3.6 +1 -0 + [Bug 2791] Quiet compiler warnings from libevent. + + sntp/libevent/evthread-internal.h@1.8 +2 -2 + [Bug 2791] Fixed function prototypes to quiet compiler warnings. + +ChangeSet@1.3305.3.5, 2015-03-20 11:36:15+01:00, martin@pc-martin.(none) + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + + ChangeLog@1.1622.3.5 +4 -3 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + + include/parse.h@1.12 +3 -3 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + + libparse/clk_meinberg.c@1.14 +7 -4 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + + libparse/clk_rawdcf.c@1.20 +3 -2 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + + libparse/clk_schmid.c@1.13 +3 -3 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + + libparse/parse.c@1.19 +1 -1 + Quiet compiler warning. + + ntpd/refclock_parse.c@1.76 +1 -1 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + + parseutil/dcfd.c@1.28 +26 -25 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + Removed trailing whitespace. + + parseutil/testdcf.c@1.10 +11 -10 + [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. + Removed trailing whitespace and fixed indention. + +ChangeSet@1.3305.3.4, 2015-03-19 17:00:30+01:00, martin@pc-martin.(none) + Added a comment from Juergen Perlinger in ntp_date.c to make the code clearer. + + ChangeLog@1.1622.3.4 +1 -0 + Added a comment from Juergen Perlinger in ntp_date.c to make the code clearer. + + libntp/ntp_calendar.c@1.15 +40 -34 + Added a comment from Juergen Perlinger to make the code clearer. + Removed trailing whitespace. + +ChangeSet@1.3305.3.3, 2015-03-19 16:52:05+01:00, martin@pc-martin.(none) + Use predefined function types for parse driver functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast parse conversion results to appropriate types to avoid compiler warnings. + Let ioctl() for Windows accept a (void *) to avoid compiler warnings when called with pointers to different types. + + ChangeLog@1.1622.3.3 +7 -0 + Use predefined function types for parse driver functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast parse conversion results to appropriate types to avoid compiler warnings. + Let ioctl() for Windows accept a (void *) to avoid compiler warnings when called with pointers to different types. + + include/binio.h@1.6 +10 -0 + Added macros casting the result of the conversion function to a dedicated with to avoid compiler warnings. + + include/mbg_gps166.h@1.13 +1 -1 + Use specific data type with mbg_csum() to avoid compiler warnings. + + include/parse.h@1.11 +15 -11 + Introduced some dedicated function types simplifying use with function pointers. + Let parse input functions expect a char instead of an unsigned int since chars are used anyway. + This helps to avoid compiler warnings. + + libparse/clk_computime.c@1.12 +10 -10 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/clk_dcf7000.c@1.12 +8 -7 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/clk_hopf6021.c@1.11 +21 -20 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/clk_meinberg.c@1.13 +20 -19 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast conversion results to appropriate types to avoid compiler warnings. + + libparse/clk_rawdcf.c@1.19 +8 -7 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast to appropriate types to avoid compiler warnings. + + libparse/clk_rcc8000.c@1.11 +17 -16 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/clk_schmid.c@1.12 +9 -9 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/clk_sel240x.c@1.4 +5 -11 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast to appropriate types to avoid compiler warnings. + + libparse/clk_trimtaip.c@1.12 +8 -7 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/clk_trimtsip.c@1.13 +18 -18 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast conversion results to appropriate types to avoid compiler warnings. + Use commonly defined constants to handle GPS week number wraparounds. + + libparse/clk_varitext.c@1.11 +6 -5 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/clk_wharton.c@1.10 +7 -4 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + + libparse/data_mbg.c@1.15 +36 -36 + Cast conversion results to appropriate types to avoid compiler warnings. + + libparse/gpstolfp.c@1.12 +1 -1 + Type cast to avoid compiler warning. + + libparse/parse.c@1.18 +14 -14 + Use predefined function types for functions used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast conversion results to appropriate types to avoid compiler warnings. + + ntpd/refclock_parse.c@1.75 +49 -48 + Cast conversion results to appropriate types to avoid compiler warnings. + + ports/winnt/include/termios.h@1.17 +1 -1 + Changed the prototype for ioctl() to accept a (void *) to avoid compiler warnings when called with pointers to different types. + + ports/winnt/libntp/termios.c@1.30 +2 -1 + Let ioctl() accept a (void *) to avoid compiler warnings when called with pointers to different types. + +ChangeSet@1.3305.2.4, 2015-03-19 07:54:24+00:00, stenn@psp-deb1.ntp.org + ntp_proto.c, ChangeLog: + [Sec 2779] ntpd accepts unauthenticated packets with symmetric key crypto. + [Sec 2781] Authentication doesn't protect symmetric associations against DoS attacks. + + ChangeLog@1.1622.2.4 +3 -0 + [Sec 2779] ntpd accepts unauthenticated packets with symmetric key crypto. + [Sec 2781] Authentication doesn't protect symmetric associations against DoS attacks. + + ntpd/ntp_proto.c@1.354 +16 -14 + [Sec 2779] ntpd accepts unauthenticated packets with symmetric key crypto. + [Sec 2781] Authentication doesn't protect symmetric associations against DoS attacks. + +ChangeSet@1.3305.2.3, 2015-03-16 09:17:42+00:00, stenn@psp-fb1.ntp.org + [Bug 2763] Allow different thresholds for forward and backward steps + + ChangeLog@1.1622.2.3 +1 -0 + [Bug 2763] Allow different thresholds for forward and backward steps + + include/ntp.h@1.211 +13 -11 + [Bug 2763] Allow different thresholds for forward and backward steps + + include/ntpd.h@1.185 +2 -1 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/invoke-ntp.conf.texi@1.178 +15 -2 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/keyword-gen-utd@1.22 +1 -1 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/keyword-gen.c@1.27 +2 -0 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp.conf.5man@1.212 +19 -4 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp.conf.5mdoc@1.212 +18 -3 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp.conf.def@1.15 +16 -1 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp.conf.man.in@1.212 +19 -4 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp.conf.mdoc.in@1.212 +18 -3 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp_config.c@1.323 +8 -0 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp_keyword.h@1.24 +492 -483 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp_loopfilter.c@1.179 +27 -5 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp_parser.c@1.90 +803 -797 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp_parser.h@1.56 +81 -77 + [Bug 2763] Allow different thresholds for forward and backward steps + + ntpd/ntp_parser.y@1.83 +4 -0 + [Bug 2763] Allow different thresholds for forward and backward steps + +ChangeSet@1.3305.3.2, 2015-03-13 10:28:32+01:00, martin@pc-martin.(none) + Removed non-ASCII characters from some copyright comments. + Removed trailing whitespace. + Updated definitions for Meinberg clocks from current Meinberg header files. Now use C99 fixed-width types and avoid non-ASCII characters in comments. + Account for updated definitions pulled from Meinberg header files. + Updated comments on Meinberg GPS receivers which are not only called GPS16x. + Replaced some constant numbers by defines from ntp_calendar.h + Modified creation of parse-specific variables for Meinberg devices in gps16x_message(). + Reworked mk_utcinfo() to avoid printing of ambiguous leap second dates. + Modified mbg_tm_str() which now expexts an additional parameter controlling if the time status shall be printed. + + ChangeLog@1.1622.3.2 +12 -0 + Removed non-ASCII characters from some copyright comments. + Removed trailing whitespace. + Updated definitions for Meinberg clocks from current Meinberg header files. Now use C99 fixed-width types and avoid non-ASCII characters in comments. + Account for updated definitions pulled from Meinberg header files. + Updated comments on Meinberg GPS receivers which are not only called GPS16x. + Replaced some constant numbers by defines from ntp_calendar.h + Modified creation of parse-specific variables for Meinberg devices in gps16x_message(). + Reworked mk_utcinfo() to avoid printing of ambiguous leap second dates. + Modified mbg_tm_str() which now expexts an additional parameter controlling if the time status shall be printed. + + include/mbg_gps166.h@1.12 +841 -408 + Updated definitions for Meinberg clocks from current Meinberg header files. Now use C99 fixed-width types and avoid non-ASCII characters in comments. + Updated prototype for mbg_tm_str() which now takes one more parameter. + + include/ntp_calendar.h@1.17 +4 -2 + Added definitions for DAYSPERWEEK and SECSPERWEEK. + + include/parse.h@1.10 +14 -7 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + Moved a few definitions from gpstolfp.c here so they can also be used in other c modules. + + include/parse_conf.h@1.6 +1 -1 + Removed non-ASCII characters from copyright comment. + + kernel/sys/parsestreams.h@1.8 +1 -1 + Removed non-ASCII characters from copyright comment. + + libparse/clk_computime.c@1.11 +23 -23 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_dcf7000.c@1.11 +7 -7 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_meinberg.c@1.12 +71 -70 + Updated comments on Meinberg GPS receivers which are not only called GPS16x. + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_rawdcf.c@1.18 +12 -12 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_schmid.c@1.11 +7 -7 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_trimtaip.c@1.11 +5 -5 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_trimtsip.c@1.12 +13 -13 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_varitext.c@1.10 +38 -38 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/clk_wharton.c@1.9 +1 -1 + Fixed a typo. + + libparse/data_mbg.c@1.14 +39 -36 + Account for updated definitions pulled from Meinberg header files. + Updated definitions for Meinberg clocks from current Meinberg header files. Now use C99 fixed-width types and avoid non-ASCII characters in comments. + Replaced some constant numbers by defines from ntp_calendar.h. + Modified mbg_tm_str() which now expexts an additional parameter controlling if the time status shall be printed. + + libparse/gpstolfp.c@1.11 +4 -6 + Moved some commonly used constants to parse.h. + Removed duplicate defines and use those in ntp_calendar.h. + Also replaced some constant numbers by defines from ntp_calendar.h. + + libparse/parse.c@1.17 +46 -46 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/parse_conf.c@1.11 +2 -2 + Removed non-ASCII characters from copyright comment. + + libparse/parsesolaris.c@1.12 +55 -55 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/parsestreams.c@1.8 +63 -63 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + + libparse/trim_info.c@1.6 +1 -1 + Removed non-ASCII characters from copyright comment. + + ntpd/refclock_parse.c@1.74 +326 -295 + Removed non-ASCII characters from copyright comment. + Removed trailing whitespace. + Reworked mk_utcinfo() to avoid printing of ambiguous leap second dates. + Modified creation of parse-specific variables for Meinberg devices in gps16x_message(). + + parseutil/dcfd.c@1.27 +2 -2 + Removed non-ASCII characters from copyright comment. + + parseutil/testdcf.c@1.9 +2 -2 + Removed non-ASCII characters from copyright comment. + +ChangeSet@1.3305.2.2, 2015-03-10 11:21:46+00:00, stenn@psp-fb1.ntp.org + merge cleanup + + ChangeLog@1.1622.2.2 +1 -3 + merge cleanup + + ntpd/ntp_loopfilter.c@1.178 +5 -2 + merge cleanup + +ChangeSet@1.3305.3.1, 2015-03-10 10:48:25+01:00, martin@pc-martin.(none) + Fixed loops and decoding of Meinberg GPS satellite info. + + ChangeLog@1.1622.3.1 +1 -0 + Fixed loops and decoding of Meinberg GPS satellite info. + + libparse/data_mbg.c@1.13 +3 -3 + Fixed loops handling Meinberg GPS satellite info. + + ntpd/refclock_parse.c@1.73 +44 -68 + Fixed loops and decoding of Meinberg GPS satellite info. + +ChangeSet@1.3305.2.1, 2015-03-09 06:36:19-04:00, murray@pogo.udel.edu + ChangeLog, ntp_loopfilter.c: + Fix for bug 2774 + + ChangeLog@1.1622.2.1 +3 -0 + Fix for bug 2774 + + ntpd/ntp_loopfilter.c@1.177 +4 -1 + Fix for bug 2774 + +ChangeSet@1.3305.1.18, 2015-03-07 23:04:03+00:00, stenn@psp-fb1.ntp.org + [Bug 2782] Refactor refclock_shm.c, add memory barrier protection + + ntpd/refclock_shm.c@1.34 +6 -1 + [Bug 2782] Refactor refclock_shm.c, add memory barrier protection + +ChangeSet@1.3305.1.17, 2015-03-07 01:51:49+00:00, stenn@stenn.ntp.org + [Bug 2784] Fix for 2782 uses clock_gettime() instead of get_ostime() + + ChangeLog@1.1622.1.14 +1 -0 + [Bug 2784] Fix for 2782 uses clock_gettime() instead of get_ostime() + + ntpd/refclock_shm.c@1.33 +1 -1 + [Bug 2784] Fix for 2782 uses clock_gettime() instead of get_ostime() + +ChangeSet@1.3305.1.16, 2015-03-05 20:08:21+00:00, stenn@stenn.ntp.org + [Bug 2782] Refactor refclock_shm.c, add memory barrier protection + + ChangeLog@1.1622.1.13 +1 -0 + [Bug 2782] Refactor refclock_shm.c, add memory barrier protection + + configure.ac@1.585 +7 -1 + [Bug 2782] Refactor refclock_shm.c, add memory barrier protection + + ntpd/refclock_shm.c@1.32 +196 -108 + [Bug 2782] Refactor refclock_shm.c, add memory barrier protection + +ChangeSet@1.3305.1.15, 2015-03-05 10:17:02+00:00, stenn@psp-fb1.ntp.org + [Bug 2783] Quiet autoconf warnings about missing AC_LANG_SOURCE + + ChangeLog@1.1622.1.12 +1 -0 + [Bug 2783] Quiet autoconf warnings about missing AC_LANG_SOURCE + + configure.ac@1.584 +24 -22 + [Bug 2783] Quiet autoconf warnings about missing AC_LANG_SOURCE + + sntp/libopts/m4/libopts.m4@1.33 +12 -12 + [Bug 2783] Quiet autoconf warnings about missing AC_LANG_SOURCE + + sntp/m4/ntp_libntp.m4@1.29 +4 -4 + [Bug 2783] Quiet autoconf warnings about missing AC_LANG_SOURCE + +ChangeSet@1.3305.1.14, 2015-03-04 11:16:31+00:00, stenn@psp-fb1.ntp.org + [Bug 2775] ntp-keygen.c fails to compile under Windows + + ChangeLog@1.1622.1.11 +1 -0 + [Bug 2775] ntp-keygen.c fails to compile under Windows. + + util/ntp-keygen.c@1.103 +7 -1 + [Bug 2775] ntp-keygen.c fails to compile under Windows + +ChangeSet@1.3305.1.13, 2015-03-01 21:46:56-05:00, stenn@pogo.udel.edu + cleanup + + ChangeLog@1.1622.1.10 +1 -2 + cleanup + +ChangeSet@1.3305.1.12, 2015-03-01 02:50:18-05:00, murray@pogo.udel.edu + refclock_palisade.h, ChangeLog, refclock_palisade.c: + Fix bug 2773 - early leap from Palisade/Thunderbolt + + ChangeLog@1.1622.1.9 +2 -0 + Fix bug 2773 - early leap from Palisade/Thunderbolt + + ntpd/refclock_palisade.c@1.42 +8 -2 + Fix bug 2773 - early leap from Palisade/Thunderbolt + + ntpd/refclock_palisade.h@1.15 +1 -0 + Fix bug 2773 - early leap from Palisade/Thunderbolt + +ChangeSet@1.3305.1.11, 2015-02-28 12:12:13+00:00, stenn@psp-fb1.ntp.org + [Bug 2751] jitter.h has stale copies of l_fp macros + + util/Makefile.am@1.78 +1 -1 + [Bug 2751] jitter.h has stale copies of l_fp macros + +ChangeSet@1.3305.1.10, 2015-02-28 12:04:02+00:00, stenn@psp-fb1.ntp.org + [Bug 2771] nonvolatile value is documented in wrong units + + ChangeLog@1.1622.1.8 +1 -0 + [Bug 2771] nonvolatile value is documented in wrong units + + html/miscopt.html@1.80 +2 -2 + [Bug 2771] nonvolatile value is documented in wrong units + +ChangeSet@1.3305.1.9, 2015-02-28 11:34:24+00:00, stenn@psp-fb1.ntp.org + [Bug 2767] ntp-keygen -M should symlink to ntp.keys + + ChangeLog@1.1622.1.7 +1 -0 + [Bug 2767] ntp-keygen -M should symlink to ntp.keys + + util/ntp-keygen.c@1.102 +6 -2 + [Bug 2767] ntp-keygen -M should symlink to ntp.keys + +ChangeSet@1.3305.1.8, 2015-02-28 11:28:04+00:00, stenn@psp-fb1.ntp.org + [Bug 2766] ntp-keygen output files should not be world-readable + + ChangeLog@1.1622.1.6 +1 -0 + [Bug 2766] ntp-keygen output files should not be world-readable + + util/ntp-keygen.c@1.101 +5 -1 + [Bug 2766] ntp-keygen output files should not be world-readable + +ChangeSet@1.3305.1.7, 2015-02-28 11:18:57+00:00, stenn@psp-fb1.ntp.org + [Bug 2759] Expose nonvolatile/clk_wander_threshold to ntpq + + ChangeLog@1.1622.1.5 +1 -0 + [Bug 2759] Expose nonvolatile/clk_wander_threshold to ntpq + + ntpd/ntp_control.c@1.196 +56 -51 + [Bug 2759] Expose nonvolatile/clk_wander_threshold to ntpq + +ChangeSet@1.3305.1.6, 2015-02-28 09:47:20+00:00, stenn@psp-fb1.ntp.org + [Bug 2757] Quiet compiler warnings. + + lib/isc/inet_ntop.c@1.14 +1 -0 + [Bug 2757] Quiet compiler warnings. + + lib/isc/log.c@1.8 +12 -12 + [Bug 2757] Quiet compiler warnings. + + ntpd/ntp_leapsec.c@1.16 +6 -6 + [Bug 2757] Quiet compiler warnings. + + parseutil/dcfd.c@1.26 +7 -0 + [Bug 2757] Quiet compiler warnings. + + sntp/libevent/include/event2/event.h@1.11 +4 -0 + [Bug 2757] Quiet compiler warnings. + +ChangeSet@1.3305.1.5, 2015-02-28 09:11:24+00:00, stenn@psp-fb1.ntp.org + [Bug 2756] ntpd hangs in startup with gcc 3.3.5 on ARM + + ChangeLog@1.1622.1.4 +1 -0 + [Bug 2756] ntpd hangs in startup with gcc 3.3.5 on ARM + + configure.ac@1.583 +0 -2 + [Bug 2756] ntpd hangs in startup with gcc 3.3.5 on ARM + + include/ntp_fp.h@1.32 +4 -1 + [Bug 2756] ntpd hangs in startup with gcc 3.3.5 on ARM + +ChangeSet@1.3305.1.4, 2015-02-25 07:58:47+00:00, stenn@psp-fb1.ntp.org + [Bug 2751] jitter.h has stale copies of l_fp macros + + BitKeeper/deleted/fd/jitter.h~11d7c056cb18e28@1.5 +0 -0 + Delete: util/jitter.h + + ChangeLog@1.1622.1.3 +1 -0 + [Bug 2751] jitter.h has stale copies of l_fp macros + + util/jitter.c@1.11 +1 -2 + [Bug 2751] jitter.h has stale copies of l_fp macros + +ChangeSet@1.3305.1.3, 2015-02-21 05:56:16-05:00, stenn@deacon.udel.edu + Update triggers for bk-6 + + BitKeeper/triggers/post-incoming.license-warn@1.9 +3 -0 + Update triggers for bk-6 + + BitKeeper/triggers/pre-resolve.license-chk@1.10 +3 -0 + Update triggers for bk-6 + + BitKeeper/triggers/send@1.16 +2 -2 + Update triggers for bk-6 + +ChangeSet@1.3305.1.2, 2015-02-21 10:35:38+00:00, stenn@psp-fb1.ntp.org + [Bug 2757] Quiet compiler warnings + + ChangeLog@1.1622.1.2 +1 -0 + [Bug 2757] Quiet compiler warnings + + lib/isc/result.c@1.4 +6 -6 + [Bug 2757] Quiet compiler warnings + + lib/isc/unix/file.c@1.7 +3 -3 + [Bug 2757] Quiet compiler warnings + + lib/isc/unix/ifiter_ioctl.c@1.32.1.1 +4 -0 + [Bug 2757] Quiet compiler warnings + + lib/isc/unix/net.c@1.19 +2 -1 + [Bug 2757] Quiet compiler warnings + + libntp/work_fork.c@1.13 +1 -1 + [Bug 2757] Quiet compiler warnings + + ntpd/ntp_crypto.c@1.174 +1 -1 + [Bug 2757] Quiet compiler warnings + +ChangeSet@1.3305.1.1, 2015-02-21 09:51:32+00:00, stenn@psp-deb1.ntp.org + [Bug 2749] ntp/lib/NTP/Util.pm needs update for ntpq -w, IPv6, .POOL. + + ChangeLog@1.1622.1.1 +1 -0 + [Bug 2749] ntp/lib/NTP/Util.pm needs update for ntpq -w, IPv6, .POOL. + + scripts/lib/NTP/Util.pm@1.3 +15 -4 + [Bug 2749] ntp/lib/NTP/Util.pm needs update for ntpq -w, IPv6, .POOL. + +ChangeSet@1.3306, 2015-02-21 09:28:08+00:00, stenn@psp-fb1.ntp.org + [Bug 1960] setsockopt IPV6_MULTICAST_IF: Invalid argument + + ChangeLog@1.1623 +1 -0 + [Bug 1960] setsockopt IPV6_MULTICAST_IF: Invalid argument + + lib/isc/unix/ifiter_getifaddrs.c@1.14 +3 -0 + [Bug 1960] setsockopt IPV6_MULTICAST_IF: Invalid argument + + lib/isc/unix/ifiter_ioctl.c@1.33 +12 -2 + [Bug 1960] setsockopt IPV6_MULTICAST_IF: Invalid argument + +ChangeSet@1.3302.1.1, 2015-02-21 07:15:54+00:00, stenn@psp-deb1.ntp.org + [Bug 2728] See if C99-style structure initialization works + + ChangeLog@1.1620.1.1 +3 -0 + [Bug 2728] See if C99-style structure initialization works + + configure.ac@1.582 +1 -0 + [Bug 2728] See if C99-style structure initialization works + + ntpq/ntpq-subs.c@1.104 +1 -1 + [Bug 2728] See if C99-style structure initialization works + + ports/winnt/include/config.h@1.111 +1 -1 + [Bug 2728] See if C99-style structure initialization works + + sntp/m4/ax_c99_struct_init.m4@1.1 +59 -0 + BitKeeper file /home/stenn/ntp-stable-2728/sntp/m4/ax_c99_struct_init.m4 + + sntp/m4/ax_c99_struct_init.m4@1.0 +0 -0 + +ChangeSet@1.3304, 2015-02-11 09:08:51+00:00, stenn@psp-fb1.ntp.org + [Bug 2747] Upgrade libevent to 2.1.5-beta + + ChangeLog@1.1621 +3 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + +ChangeSet@1.3303, 2015-02-11 09:05:59+00:00, stenn@psp-fb1.ntp.org + [Bug 2747] Upgrade libevent to 2.1.5-beta + + BitKeeper/deleted/5b/README~3a69bb76c676898e@1.7 +0 -0 + Delete: sntp/libevent/README + + sntp/libevent/ChangeLog@1.9 +726 -60 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/Makefile.am@1.13 +3 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/README.md@1.1 +318 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2747/sntp/libevent/README.md + + sntp/libevent/README.md@1.0 +0 -0 + + sntp/libevent/WIN32-Code/getopt.c@1.1 +149 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2747/sntp/libevent/WIN32-Code/getopt.c + + sntp/libevent/WIN32-Code/getopt.c@1.0 +0 -0 + + sntp/libevent/WIN32-Code/getopt.h@1.1 +33 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2747/sntp/libevent/WIN32-Code/getopt.h + + sntp/libevent/WIN32-Code/getopt.h@1.0 +0 -0 + + sntp/libevent/WIN32-Code/getopt_long.c@1.1 +233 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2747/sntp/libevent/WIN32-Code/getopt_long.c + + sntp/libevent/WIN32-Code/getopt_long.c@1.0 +0 -0 + + sntp/libevent/WIN32-Code/nmake/event2/event-config.h@1.2 +2 -2 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/WIN32-Code/tree.h@1.2 +0 -677 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/buffer.c@1.10 +74 -10 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/bufferevent.c@1.8 +9 -4 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/bufferevent_async.c@1.7 +6 -4 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/bufferevent_filter.c@1.7 +50 -23 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/bufferevent_openssl.c@1.9 +2 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/bufferevent_pair.c@1.8 +32 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/configure.ac@1.17 +15 -18 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/evbuffer-internal.h@1.8 +13 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/evdns.c@1.10 +80 -33 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/event.c@1.13 +38 -10 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/event_tagging.c@1.5 +14 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/evrpc-internal.h@1.3 +1 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/evthread-internal.h@1.7 +7 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/evthread.c@1.8 +17 -6 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/evutil.c@1.10 +28 -14 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/evutil_time.c@1.5 +50 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/ht-internal.h@1.4 +0 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/http-internal.h@1.6 +2 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/http.c@1.10 +45 -2 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/include/event2/buffer.h@1.7 +3 -8 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/include/event2/bufferevent.h@1.6 +5 -4 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/include/event2/dns.h@1.7 +17 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/include/event2/event.h@1.10 +6 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/include/event2/http.h@1.7 +14 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/include/event2/listener.h@1.4 +9 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/include/event2/util.h@1.7 +69 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/kqueue.c@1.7 +17 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/listener.c@1.7 +5 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/sample/http-server.c@1.10 +5 -2 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/sample/https-client.c@1.2 +15 -2 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/sample/include.am@1.3 +2 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/include.am@1.4 +2 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/print-winsock-errors.c@1.1 +84 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2747/sntp/libevent/test/print-winsock-errors.c + + sntp/libevent/test/print-winsock-errors.c@1.0 +0 -0 + + sntp/libevent/test/regress.c@1.6 +29 -8 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress.h@1.5 +5 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_buffer.c@1.8 +47 -6 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_bufferevent.c@1.6 +150 -2 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_dns.c@1.8 +141 -14 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_finalize.c@1.2 +1 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_http.c@1.8 +107 -9 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_main.c@1.7 +4 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_minheap.c@1.3 +3 -2 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_ssl.c@1.7 +1 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_thread.c@1.6 +3 -2 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_util.c@1.7 +19 -17 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/regress_zlib.c@1.5 +10 -7 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/test-fdleak.c@1.2 +10 -10 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/test-ratelim.c@1.9 +5 -6 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/test-ratelim.sh@1.1 +88 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2747/sntp/libevent/test/test-ratelim.sh + + sntp/libevent/test/test-ratelim.sh@1.0 +0 -0 + + sntp/libevent/test/test-time.c@1.5 +9 -6 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/tinytest.c@1.6 +33 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/tinytest.h@1.4 +2 -0 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/test/tinytest_demo.c@1.1 +260 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-stable-2747/sntp/libevent/test/tinytest_demo.c + + sntp/libevent/test/tinytest_demo.c@1.0 +0 -0 + + sntp/libevent/test/tinytest_macros.h@1.3 +21 -6 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/time-internal.h@1.2 +0 -3 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/util-internal.h@1.10 +1 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/libevent/whatsnew-2.1.txt@1.4 +52 -1 + [Bug 2747] Upgrade libevent to 2.1.5-beta + + sntp/m4/LICENSE-OPENLDAP@1.2 +0 -0 + Rename: sntp/libevent/m4/LICENSE-OPENLDAP -> sntp/m4/LICENSE-OPENLDAP + + sntp/m4/openldap-thread-check.m4@1.5 +0 -0 + Rename: sntp/libevent/m4/openldap-thread-check.m4 -> sntp/m4/openldap-thread-check.m4 + + sntp/m4/openldap.m4@1.2 +0 -0 + Rename: sntp/libevent/m4/openldap.m4 -> sntp/m4/openldap.m4 + +ChangeSet@1.3302, 2015-02-04 02:44:25-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1 + TAG: NTP_4_2_8P1 + + ChangeLog@1.1620 +1 -0 + NTP_4_2_8P1 + + ntpd/invoke-ntp.conf.texi@1.177 +1 -1 + NTP_4_2_8P1 + + ntpd/invoke-ntp.keys.texi@1.174 +1 -1 + NTP_4_2_8P1 + + ntpd/invoke-ntpd.texi@1.490 +2 -2 + NTP_4_2_8P1 + + ntpd/ntp.conf.5man@1.211 +3 -3 + NTP_4_2_8P1 + + ntpd/ntp.conf.5mdoc@1.211 +2 -2 + NTP_4_2_8P1 + + ntpd/ntp.conf.html@1.169 +1 -1 + NTP_4_2_8P1 + + ntpd/ntp.conf.man.in@1.211 +3 -3 + NTP_4_2_8P1 + + ntpd/ntp.conf.mdoc.in@1.211 +2 -2 + NTP_4_2_8P1 + + ntpd/ntp.keys.5man@1.208 +2 -2 + NTP_4_2_8P1 + + ntpd/ntp.keys.5mdoc@1.208 +2 -2 + NTP_4_2_8P1 + + ntpd/ntp.keys.html@1.170 +1 -1 + NTP_4_2_8P1 + + ntpd/ntp.keys.man.in@1.208 +2 -2 + NTP_4_2_8P1 + + ntpd/ntp.keys.mdoc.in@1.208 +2 -2 + NTP_4_2_8P1 + + ntpd/ntpd-opts.c@1.511 +239 -239 + NTP_4_2_8P1 + + ntpd/ntpd-opts.h@1.510 +3 -3 + NTP_4_2_8P1 + + ntpd/ntpd.1ntpdman@1.319 +3 -3 + NTP_4_2_8P1 + + ntpd/ntpd.1ntpdmdoc@1.319 +2 -2 + NTP_4_2_8P1 + + ntpd/ntpd.html@1.164 +2 -2 + NTP_4_2_8P1 + + ntpd/ntpd.man.in@1.319 +3 -3 + NTP_4_2_8P1 + + ntpd/ntpd.mdoc.in@1.319 +2 -2 + NTP_4_2_8P1 + + ntpdc/invoke-ntpdc.texi@1.488 +2 -2 + NTP_4_2_8P1 + + ntpdc/ntpdc-opts.c@1.506 +107 -107 + NTP_4_2_8P1 + + ntpdc/ntpdc-opts.h@1.505 +3 -3 + NTP_4_2_8P1 + + ntpdc/ntpdc.1ntpdcman@1.319 +3 -3 + NTP_4_2_8P1 + + ntpdc/ntpdc.1ntpdcmdoc@1.319 +2 -2 + NTP_4_2_8P1 + + ntpdc/ntpdc.html@1.332 +2 -2 + NTP_4_2_8P1 + + ntpdc/ntpdc.man.in@1.319 +3 -3 + NTP_4_2_8P1 + + ntpdc/ntpdc.mdoc.in@1.319 +2 -2 + NTP_4_2_8P1 + + ntpq/invoke-ntpq.texi@1.494 +2 -2 + NTP_4_2_8P1 + + ntpq/ntpq-opts.c@1.511 +106 -106 + NTP_4_2_8P1 + + ntpq/ntpq-opts.h@1.509 +3 -3 + NTP_4_2_8P1 + + ntpq/ntpq.1ntpqman@1.322 +3 -3 + NTP_4_2_8P1 + + ntpq/ntpq.1ntpqmdoc@1.322 +2 -2 + NTP_4_2_8P1 + + ntpq/ntpq.html@1.161 +2 -2 + NTP_4_2_8P1 + + ntpq/ntpq.man.in@1.322 +3 -3 + NTP_4_2_8P1 + + ntpq/ntpq.mdoc.in@1.322 +2 -2 + NTP_4_2_8P1 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.490 +2 -2 + NTP_4_2_8P1 + + ntpsnmpd/ntpsnmpd-opts.c@1.508 +68 -68 + NTP_4_2_8P1 + + ntpsnmpd/ntpsnmpd-opts.h@1.507 +3 -3 + NTP_4_2_8P1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.319 +3 -3 + NTP_4_2_8P1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.319 +2 -2 + NTP_4_2_8P1 + + ntpsnmpd/ntpsnmpd.html@1.159 +1 -1 + NTP_4_2_8P1 + + ntpsnmpd/ntpsnmpd.man.in@1.319 +3 -3 + NTP_4_2_8P1 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.319 +2 -2 + NTP_4_2_8P1 + + packageinfo.sh@1.503 +3 -3 + NTP_4_2_8P1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.80 +3 -3 + NTP_4_2_8P1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.81 +2 -2 + NTP_4_2_8P1 + + scripts/calc_tickadj/calc_tickadj.html@1.82 +1 -1 + NTP_4_2_8P1 + + scripts/calc_tickadj/calc_tickadj.man.in@1.79 +3 -3 + NTP_4_2_8P1 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.81 +2 -2 + NTP_4_2_8P1 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.84 +1 -1 + NTP_4_2_8P1 + + scripts/invoke-plot_summary.texi@1.101 +2 -2 + NTP_4_2_8P1 + + scripts/invoke-summary.texi@1.101 +2 -2 + NTP_4_2_8P1 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.311 +2 -2 + NTP_4_2_8P1 + + scripts/ntp-wait/ntp-wait-opts@1.47 +2 -2 + NTP_4_2_8P1 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.308 +3 -3 + NTP_4_2_8P1 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.309 +2 -2 + NTP_4_2_8P1 + + scripts/ntp-wait/ntp-wait.html@1.328 +2 -2 + NTP_4_2_8P1 + + scripts/ntp-wait/ntp-wait.man.in@1.308 +3 -3 + NTP_4_2_8P1 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.309 +2 -2 + NTP_4_2_8P1 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.99 +2 -2 + NTP_4_2_8P1 + + scripts/ntpsweep/ntpsweep-opts@1.49 +2 -2 + NTP_4_2_8P1 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.87 +3 -3 + NTP_4_2_8P1 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.87 +2 -2 + NTP_4_2_8P1 + + scripts/ntpsweep/ntpsweep.html@1.100 +2 -2 + NTP_4_2_8P1 + + scripts/ntpsweep/ntpsweep.man.in@1.87 +3 -3 + NTP_4_2_8P1 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.88 +2 -2 + NTP_4_2_8P1 + + scripts/ntptrace/invoke-ntptrace.texi@1.100 +2 -2 + NTP_4_2_8P1 + + scripts/ntptrace/ntptrace-opts@1.49 +2 -2 + NTP_4_2_8P1 + + scripts/ntptrace/ntptrace.1ntptraceman@1.87 +3 -3 + NTP_4_2_8P1 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.88 +2 -2 + NTP_4_2_8P1 + + scripts/ntptrace/ntptrace.html@1.101 +2 -2 + NTP_4_2_8P1 + + scripts/ntptrace/ntptrace.man.in@1.87 +3 -3 + NTP_4_2_8P1 + + scripts/ntptrace/ntptrace.mdoc.in@1.89 +2 -2 + NTP_4_2_8P1 + + scripts/plot_summary-opts@1.49 +2 -2 + NTP_4_2_8P1 + + scripts/plot_summary.1plot_summaryman@1.99 +3 -3 + NTP_4_2_8P1 + + scripts/plot_summary.1plot_summarymdoc@1.99 +2 -2 + NTP_4_2_8P1 + + scripts/plot_summary.html@1.102 +2 -2 + NTP_4_2_8P1 + + scripts/plot_summary.man.in@1.99 +3 -3 + NTP_4_2_8P1 + + scripts/plot_summary.mdoc.in@1.99 +2 -2 + NTP_4_2_8P1 + + scripts/summary-opts@1.49 +2 -2 + NTP_4_2_8P1 + + scripts/summary.1summaryman@1.99 +3 -3 + NTP_4_2_8P1 + + scripts/summary.1summarymdoc@1.99 +2 -2 + NTP_4_2_8P1 + + scripts/summary.html@1.102 +2 -2 + NTP_4_2_8P1 + + scripts/summary.man.in@1.99 +3 -3 + NTP_4_2_8P1 + + scripts/summary.mdoc.in@1.99 +2 -2 + NTP_4_2_8P1 + + sntp/invoke-sntp.texi@1.487 +2 -2 + NTP_4_2_8P1 + + sntp/sntp-opts.c@1.506 +159 -159 + NTP_4_2_8P1 + + sntp/sntp-opts.h@1.504 +3 -3 + NTP_4_2_8P1 + + sntp/sntp.1sntpman@1.322 +3 -3 + NTP_4_2_8P1 + + sntp/sntp.1sntpmdoc@1.322 +2 -2 + NTP_4_2_8P1 + + sntp/sntp.html@1.502 +2 -2 + NTP_4_2_8P1 + + sntp/sntp.man.in@1.322 +3 -3 + NTP_4_2_8P1 + + sntp/sntp.mdoc.in@1.322 +2 -2 + NTP_4_2_8P1 + + util/invoke-ntp-keygen.texi@1.491 +2 -2 + NTP_4_2_8P1 + + util/ntp-keygen-opts.c@1.509 +173 -173 + NTP_4_2_8P1 + + util/ntp-keygen-opts.h@1.507 +3 -3 + NTP_4_2_8P1 + + util/ntp-keygen.1ntp-keygenman@1.319 +3 -3 + NTP_4_2_8P1 + + util/ntp-keygen.1ntp-keygenmdoc@1.319 +2 -2 + NTP_4_2_8P1 + + util/ntp-keygen.html@1.165 +2 -2 + NTP_4_2_8P1 + + util/ntp-keygen.man.in@1.319 +3 -3 + NTP_4_2_8P1 + + util/ntp-keygen.mdoc.in@1.319 +2 -2 + NTP_4_2_8P1 + +ChangeSet@1.3301, 2015-02-04 02:22:55-05:00, stenn@deacon.udel.edu + ntp-4.2.8p1 + + packageinfo.sh@1.502 +1 -1 + ntp-4.2.8p1 + +ChangeSet@1.3300, 2015-02-04 07:16:30+00:00, stenn@psp-deb1.ntp.org + Update the ChangeLog and NEWS files + + ChangeLog@1.1619 +4 -1 + Update the ChangeLog and NEWS files + + NEWS@1.130 +60 -0 + Update the ChangeLog and NEWS files + +ChangeSet@1.3292.1.20, 2015-01-29 19:14:37-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1_RC2 + TAG: NTP_4_2_8P1_RC2 + + ChangeLog@1.1613.1.18 +1 -0 + NTP_4_2_8P1_RC2 + + ntpd/invoke-ntp.conf.texi@1.176 +1 -1 + NTP_4_2_8P1_RC2 + + ntpd/invoke-ntp.keys.texi@1.173 +1 -1 + NTP_4_2_8P1_RC2 + + ntpd/invoke-ntpd.texi@1.489 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntp.conf.5man@1.210 +3 -3 + NTP_4_2_8P1_RC2 + + ntpd/ntp.conf.5mdoc@1.210 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntp.conf.html@1.168 +1 -1 + NTP_4_2_8P1_RC2 + + ntpd/ntp.conf.man.in@1.210 +3 -3 + NTP_4_2_8P1_RC2 + + ntpd/ntp.conf.mdoc.in@1.210 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntp.keys.5man@1.207 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntp.keys.5mdoc@1.207 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntp.keys.html@1.169 +1 -1 + NTP_4_2_8P1_RC2 + + ntpd/ntp.keys.man.in@1.207 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntp.keys.mdoc.in@1.207 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntpd-opts.c@1.510 +7 -7 + NTP_4_2_8P1_RC2 + + ntpd/ntpd-opts.h@1.509 +3 -3 + NTP_4_2_8P1_RC2 + + ntpd/ntpd.1ntpdman@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + ntpd/ntpd.1ntpdmdoc@1.318 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntpd.html@1.163 +2 -2 + NTP_4_2_8P1_RC2 + + ntpd/ntpd.man.in@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + ntpd/ntpd.mdoc.in@1.318 +2 -2 + NTP_4_2_8P1_RC2 + + ntpdc/invoke-ntpdc.texi@1.487 +2 -2 + NTP_4_2_8P1_RC2 + + ntpdc/ntpdc-opts.c@1.505 +7 -7 + NTP_4_2_8P1_RC2 + + ntpdc/ntpdc-opts.h@1.504 +3 -3 + NTP_4_2_8P1_RC2 + + ntpdc/ntpdc.1ntpdcman@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + ntpdc/ntpdc.1ntpdcmdoc@1.318 +2 -2 + NTP_4_2_8P1_RC2 + + ntpdc/ntpdc.html@1.331 +2 -2 + NTP_4_2_8P1_RC2 + + ntpdc/ntpdc.man.in@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + ntpdc/ntpdc.mdoc.in@1.318 +2 -2 + NTP_4_2_8P1_RC2 + + ntpq/invoke-ntpq.texi@1.493 +2 -2 + NTP_4_2_8P1_RC2 + + ntpq/ntpq-opts.c@1.510 +7 -7 + NTP_4_2_8P1_RC2 + + ntpq/ntpq-opts.h@1.508 +3 -3 + NTP_4_2_8P1_RC2 + + ntpq/ntpq.1ntpqman@1.321 +3 -3 + NTP_4_2_8P1_RC2 + + ntpq/ntpq.1ntpqmdoc@1.321 +2 -2 + NTP_4_2_8P1_RC2 + + ntpq/ntpq.html@1.160 +2 -2 + NTP_4_2_8P1_RC2 + + ntpq/ntpq.man.in@1.321 +3 -3 + NTP_4_2_8P1_RC2 + + ntpq/ntpq.mdoc.in@1.321 +2 -2 + NTP_4_2_8P1_RC2 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.489 +2 -2 + NTP_4_2_8P1_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.507 +7 -7 + NTP_4_2_8P1_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.506 +3 -3 + NTP_4_2_8P1_RC2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.318 +2 -2 + NTP_4_2_8P1_RC2 + + ntpsnmpd/ntpsnmpd.html@1.158 +1 -1 + NTP_4_2_8P1_RC2 + + ntpsnmpd/ntpsnmpd.man.in@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.318 +2 -2 + NTP_4_2_8P1_RC2 + + packageinfo.sh@1.501 +1 -1 + NTP_4_2_8P1_RC2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.79 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.80 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/calc_tickadj/calc_tickadj.html@1.81 +1 -1 + NTP_4_2_8P1_RC2 + + scripts/calc_tickadj/calc_tickadj.man.in@1.78 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.80 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.83 +1 -1 + NTP_4_2_8P1_RC2 + + scripts/invoke-plot_summary.texi@1.100 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/invoke-summary.texi@1.100 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.310 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntp-wait/ntp-wait-opts@1.46 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.307 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.308 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntp-wait/ntp-wait.html@1.327 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntp-wait/ntp-wait.man.in@1.307 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.308 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.98 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntpsweep/ntpsweep-opts@1.48 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.86 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.86 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntpsweep/ntpsweep.html@1.99 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntpsweep/ntpsweep.man.in@1.86 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.87 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntptrace/invoke-ntptrace.texi@1.99 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntptrace/ntptrace-opts@1.48 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntptrace/ntptrace.1ntptraceman@1.86 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.87 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntptrace/ntptrace.html@1.100 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/ntptrace/ntptrace.man.in@1.86 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/ntptrace/ntptrace.mdoc.in@1.88 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/plot_summary-opts@1.48 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/plot_summary.1plot_summaryman@1.98 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/plot_summary.1plot_summarymdoc@1.98 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/plot_summary.html@1.101 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/plot_summary.man.in@1.98 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/plot_summary.mdoc.in@1.98 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/summary-opts@1.48 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/summary.1summaryman@1.98 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/summary.1summarymdoc@1.98 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/summary.html@1.101 +2 -2 + NTP_4_2_8P1_RC2 + + scripts/summary.man.in@1.98 +3 -3 + NTP_4_2_8P1_RC2 + + scripts/summary.mdoc.in@1.98 +2 -2 + NTP_4_2_8P1_RC2 + + sntp/invoke-sntp.texi@1.486 +2 -2 + NTP_4_2_8P1_RC2 + + sntp/sntp-opts.c@1.505 +7 -7 + NTP_4_2_8P1_RC2 + + sntp/sntp-opts.h@1.503 +3 -3 + NTP_4_2_8P1_RC2 + + sntp/sntp.1sntpman@1.321 +3 -3 + NTP_4_2_8P1_RC2 + + sntp/sntp.1sntpmdoc@1.321 +2 -2 + NTP_4_2_8P1_RC2 + + sntp/sntp.html@1.501 +2 -2 + NTP_4_2_8P1_RC2 + + sntp/sntp.man.in@1.321 +3 -3 + NTP_4_2_8P1_RC2 + + sntp/sntp.mdoc.in@1.321 +2 -2 + NTP_4_2_8P1_RC2 + + util/invoke-ntp-keygen.texi@1.490 +2 -2 + NTP_4_2_8P1_RC2 + + util/ntp-keygen-opts.c@1.508 +7 -7 + NTP_4_2_8P1_RC2 + + util/ntp-keygen-opts.h@1.506 +3 -3 + NTP_4_2_8P1_RC2 + + util/ntp-keygen.1ntp-keygenman@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + util/ntp-keygen.1ntp-keygenmdoc@1.318 +2 -2 + NTP_4_2_8P1_RC2 + + util/ntp-keygen.html@1.164 +2 -2 + NTP_4_2_8P1_RC2 + + util/ntp-keygen.man.in@1.318 +3 -3 + NTP_4_2_8P1_RC2 + + util/ntp-keygen.mdoc.in@1.318 +2 -2 + NTP_4_2_8P1_RC2 + +ChangeSet@1.3292.5.2, 2015-01-29 00:34:07+00:00, stenn@psp-deb1.ntp.org + typo + + ChangeLog@1.1613.5.2 +2 -0 + typo + +ChangeSet@1.3292.4.3, 2015-01-29 00:23:57+00:00, stenn@psp-deb1.ntp.org + typos + + ChangeLog@1.1613.4.3 +5 -3 + typos + +ChangeSet@1.3292.4.2, 2015-01-28 23:39:54+01:00, martin@pc-martin.fritz.box + Bug 2741 - Incorrect buffer check in parsestatus() + + ChangeLog@1.1613.4.2 +2 -1 + Bug 2741 - Incorrect buffer check in parsestatus() + + ntpd/refclock_parse.c@1.71 +1 -1 + Bug 2741 - Incorrect buffer check in parsestatus() + +ChangeSet@1.3292.2.3, 2015-01-28 22:06:47+01:00, jnperlin@nemesis.localnet + [bug 2732] Bug 2732 - Leap second not handled correctly on Windows 8 + Guard against slewing twice. Something weird is happening under Win8/8.1. + + ports/winnt/ntpd/nt_clockstuff.c@1.64 +2 -2 + [bug 2732] Bug 2732 - Leap second not handled correctly on Windows 8 + Guard against slewing twice. Something weird is happening under Win8/8.1. + +ChangeSet@1.3292.5.1, 2015-01-28 17:04:07+01:00, martin@pc-martin.(none) + [Bug 2740] Removed some obsolete code from the parse driver. + + ChangeLog@1.1613.5.1 +1 -0 + [Bug 2740] Removed some obsolete code from the parse driver. + + ntpd/refclock_parse.c@1.69.1.1 +1 -14 + [Bug 2740] Removed some obsolete code from the parse driver, as discussed with Frank Kardel. + +ChangeSet@1.3292.4.1, 2015-01-27 16:33:33+01:00, martin@pc-martin.(none) + [Bug 2738] Missing buffer initialisation in parsestate(). + [Bug 2739] Parse driver with PPS enabled occasionaly evaluates PPS timestamp with wrong sign. + Removed some German umlauts. + + ChangeLog@1.1613.4.1 +4 -0 + [Bug 2738] Missing buffer initialisation in parsestate(). + [Bug 2739] Parse driver with PPS enabled occasionaly evaluates PPS timestamp with wrong sign. + Removed some German umlauts. + + + ntpd/refclock_parse.c@1.70 +3 -2 + [Bug 2738] Missing buffer initialisation in parsestate(). + [Bug 2739] Parse driver with PPS enabled occasionaly evaluates PPS timestamp with wrong sign. + Removed some German umlauts. + +ChangeSet@1.3292.1.16, 2015-01-27 00:26:25+01:00, jnperlin@hydra.(none) + * [Bug 2627] rework: reverted sense of mode bit (so default reflects previous behaviour) and updated ducumentation. + + ChangeLog@1.1613.1.14 +4 -0 + * [Bug 2627] rework: reverted sense of mode bit (so default reflects previous behaviour) and updated ducumentation. + + html/drivers/driver28.html@1.18 +3 -2 + * [Bug 2627] rework: updated documentation + + ntpd/refclock_shm.c@1.31 +2 -7 + * [Bug 2627] rework: reverted sense of mode bit (so default reflects previous behaviour). + +ChangeSet@1.3292.2.2, 2015-01-26 23:42:37+01:00, jnperlin@nemesis.localnet + [Bug 2732] - Leap second not handled correctly on Windows 8 + use 'GetTickCount()' to get the true elapsed time of slew + (This should work for all versions of Windows >= W2K) + + ChangeLog@1.1613.3.1 +4 -0 + [Bug 2732] - Leap second not handled correctly on Windows 8 + use 'GetTickCount()' to get the true elapsed time of slew + (This should work for all versions of Windows >= W2K) + + ports/winnt/ntpd/nt_clockstuff.c@1.63 +1 -1 + [Bug 2732] - Leap second not handled correctly on Windows 8 + use 'GetTickCount()' to get the true elapsed time of slew + (This should work for all versions of Windows >= W2K) + Start 1.5 secs before schedule to minimise phase shift errors + +ChangeSet@1.3292.1.15, 2015-01-24 20:47:20-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1_RC1 + TAG: NTP_4_2_8P1_RC1 + + ChangeLog@1.1613.1.13 +1 -0 + NTP_4_2_8P1_RC1 + + ntpd/invoke-ntp.conf.texi@1.175 +1 -1 + NTP_4_2_8P1_RC1 + + ntpd/invoke-ntp.keys.texi@1.172 +1 -1 + NTP_4_2_8P1_RC1 + + ntpd/invoke-ntpd.texi@1.488 +2 -2 + NTP_4_2_8P1_RC1 + + ntpd/ntp.conf.5man@1.209 +5 -5 + NTP_4_2_8P1_RC1 + + ntpd/ntp.conf.5mdoc@1.209 +4 -4 + NTP_4_2_8P1_RC1 + + ntpd/ntp.conf.html@1.167 +1 -1 + NTP_4_2_8P1_RC1 + + ntpd/ntp.conf.man.in@1.209 +5 -5 + NTP_4_2_8P1_RC1 + + ntpd/ntp.conf.mdoc.in@1.209 +4 -4 + NTP_4_2_8P1_RC1 + + ntpd/ntp.keys.5man@1.206 +4 -4 + NTP_4_2_8P1_RC1 + + ntpd/ntp.keys.5mdoc@1.206 +4 -4 + NTP_4_2_8P1_RC1 + + ntpd/ntp.keys.html@1.168 +1 -1 + NTP_4_2_8P1_RC1 + + ntpd/ntp.keys.man.in@1.206 +4 -4 + NTP_4_2_8P1_RC1 + + ntpd/ntp.keys.mdoc.in@1.206 +4 -4 + NTP_4_2_8P1_RC1 + + ntpd/ntpd-opts.c@1.509 +251 -249 + NTP_4_2_8P1_RC1 + + ntpd/ntpd-opts.h@1.508 +5 -5 + NTP_4_2_8P1_RC1 + + ntpd/ntpd.1ntpdman@1.317 +5 -5 + NTP_4_2_8P1_RC1 + + ntpd/ntpd.1ntpdmdoc@1.317 +4 -4 + NTP_4_2_8P1_RC1 + + ntpd/ntpd.html@1.162 +2 -2 + NTP_4_2_8P1_RC1 + + ntpd/ntpd.man.in@1.317 +5 -5 + NTP_4_2_8P1_RC1 + + ntpd/ntpd.mdoc.in@1.317 +4 -4 + NTP_4_2_8P1_RC1 + + ntpdc/invoke-ntpdc.texi@1.486 +2 -2 + NTP_4_2_8P1_RC1 + + ntpdc/ntpdc-opts.c@1.504 +119 -117 + NTP_4_2_8P1_RC1 + + ntpdc/ntpdc-opts.h@1.503 +5 -5 + NTP_4_2_8P1_RC1 + + ntpdc/ntpdc.1ntpdcman@1.317 +4 -4 + NTP_4_2_8P1_RC1 + + ntpdc/ntpdc.1ntpdcmdoc@1.317 +3 -3 + NTP_4_2_8P1_RC1 + + ntpdc/ntpdc.html@1.330 +58 -88 + NTP_4_2_8P1_RC1 + + ntpdc/ntpdc.man.in@1.317 +4 -4 + NTP_4_2_8P1_RC1 + + ntpdc/ntpdc.mdoc.in@1.317 +3 -3 + NTP_4_2_8P1_RC1 + + ntpq/invoke-ntpq.texi@1.492 +2 -2 + NTP_4_2_8P1_RC1 + + ntpq/ntpq-opts.c@1.509 +118 -116 + NTP_4_2_8P1_RC1 + + ntpq/ntpq-opts.h@1.507 +5 -5 + NTP_4_2_8P1_RC1 + + ntpq/ntpq.1ntpqman@1.320 +5 -5 + NTP_4_2_8P1_RC1 + + ntpq/ntpq.1ntpqmdoc@1.320 +4 -4 + NTP_4_2_8P1_RC1 + + ntpq/ntpq.html@1.159 +2 -2 + NTP_4_2_8P1_RC1 + + ntpq/ntpq.man.in@1.320 +5 -5 + NTP_4_2_8P1_RC1 + + ntpq/ntpq.mdoc.in@1.320 +4 -4 + NTP_4_2_8P1_RC1 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.488 +2 -2 + NTP_4_2_8P1_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.506 +80 -78 + NTP_4_2_8P1_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.505 +5 -5 + NTP_4_2_8P1_RC1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.317 +4 -4 + NTP_4_2_8P1_RC1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.317 +3 -3 + NTP_4_2_8P1_RC1 + + ntpsnmpd/ntpsnmpd.html@1.157 +1 -1 + NTP_4_2_8P1_RC1 + + ntpsnmpd/ntpsnmpd.man.in@1.317 +4 -4 + NTP_4_2_8P1_RC1 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.317 +3 -3 + NTP_4_2_8P1_RC1 + + packageinfo.sh@1.500 +1 -1 + NTP_4_2_8P1_RC1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.78 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.79 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/calc_tickadj/calc_tickadj.html@1.80 +1 -1 + NTP_4_2_8P1_RC1 + + scripts/calc_tickadj/calc_tickadj.man.in@1.77 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.79 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.82 +1 -1 + NTP_4_2_8P1_RC1 + + scripts/invoke-plot_summary.texi@1.99 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/invoke-summary.texi@1.99 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.309 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntp-wait/ntp-wait-opts@1.45 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.306 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.307 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntp-wait/ntp-wait.html@1.326 +31 -49 + NTP_4_2_8P1_RC1 + + scripts/ntp-wait/ntp-wait.man.in@1.306 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.307 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.97 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntpsweep/ntpsweep-opts@1.47 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.85 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.85 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntpsweep/ntpsweep.html@1.98 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntpsweep/ntpsweep.man.in@1.85 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.86 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntptrace/invoke-ntptrace.texi@1.98 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntptrace/ntptrace-opts@1.47 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntptrace/ntptrace.1ntptraceman@1.85 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.86 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/ntptrace/ntptrace.html@1.99 +27 -36 + NTP_4_2_8P1_RC1 + + scripts/ntptrace/ntptrace.man.in@1.85 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/ntptrace/ntptrace.mdoc.in@1.87 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/plot_summary-opts@1.47 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/plot_summary.1plot_summaryman@1.97 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/plot_summary.1plot_summarymdoc@1.97 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/plot_summary.html@1.100 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/plot_summary.man.in@1.97 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/plot_summary.mdoc.in@1.97 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/summary-opts@1.47 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/summary.1summaryman@1.97 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/summary.1summarymdoc@1.97 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/summary.html@1.100 +2 -2 + NTP_4_2_8P1_RC1 + + scripts/summary.man.in@1.97 +3 -3 + NTP_4_2_8P1_RC1 + + scripts/summary.mdoc.in@1.97 +2 -2 + NTP_4_2_8P1_RC1 + + sntp/invoke-sntp.texi@1.485 +5 -3 + NTP_4_2_8P1_RC1 + + sntp/sntp-opts.c@1.504 +174 -170 + NTP_4_2_8P1_RC1 + + sntp/sntp-opts.h@1.502 +5 -5 + NTP_4_2_8P1_RC1 + + sntp/sntp.1sntpman@1.320 +24 -8 + NTP_4_2_8P1_RC1 + + sntp/sntp.1sntpmdoc@1.320 +22 -7 + NTP_4_2_8P1_RC1 + + sntp/sntp.html@1.500 +88 -120 + NTP_4_2_8P1_RC1 + + sntp/sntp.man.in@1.320 +24 -8 + NTP_4_2_8P1_RC1 + + sntp/sntp.mdoc.in@1.320 +22 -7 + NTP_4_2_8P1_RC1 + + util/invoke-ntp-keygen.texi@1.489 +2 -2 + NTP_4_2_8P1_RC1 + + util/ntp-keygen-opts.c@1.507 +185 -183 + NTP_4_2_8P1_RC1 + + util/ntp-keygen-opts.h@1.505 +5 -5 + NTP_4_2_8P1_RC1 + + util/ntp-keygen.1ntp-keygenman@1.317 +5 -5 + NTP_4_2_8P1_RC1 + + util/ntp-keygen.1ntp-keygenmdoc@1.317 +4 -4 + NTP_4_2_8P1_RC1 + + util/ntp-keygen.html@1.163 +2 -2 + NTP_4_2_8P1_RC1 + + util/ntp-keygen.man.in@1.317 +5 -5 + NTP_4_2_8P1_RC1 + + util/ntp-keygen.mdoc.in@1.317 +4 -4 + NTP_4_2_8P1_RC1 + +ChangeSet@1.3292.1.14, 2015-01-24 10:44:12+00:00, stenn@psp-fb1.ntp.org + [Bug 2736] Show error message if we cannot open the config file + + ChangeLog@1.1613.1.12 +1 -0 + [Bug 2736] Show error message if we cannot open the config file + + ntpd/ntp_config.c@1.322 +2 -2 + [Bug 2736] Show error message if we cannot open the config file + +ChangeSet@1.3292.1.12, 2015-01-24 04:02:10+00:00, stenn@psp-deb1.ntp.org + Copyright update + + html/copyright.html@1.67 +2 -2 + Copyright update + +ChangeSet@1.3292.1.11, 2015-01-24 03:09:26+00:00, stenn@psp-fb1.ntp.org + typo fix + + sntp/include/ntp.lic@1.8 +1 -3 + typo fix + +ChangeSet@1.3292.3.5, 2015-01-24 02:27:46+00:00, stenn@psp-fb1.ntp.org + Start the RC for 4.2.8p1 + + ChangeLog@1.1613.2.5 +1 -0 + + packageinfo.sh@1.499 +1 -1 + +ChangeSet@1.3292.3.4, 2015-01-24 01:54:36+00:00, stenn@psp-fb1.ntp.org + [Bug 2187] Update version number generation scripts + + ChangeLog@1.1613.2.4 +1 -0 + [Bug 2187] Update version number generation scripts + + scripts/build/UpdatePoint@1.7 +12 -6 + [Bug 2187] Update version number generation scripts + + scripts/build/VersionName@1.9 +12 -3 + [Bug 2187] Update version number generation scripts + +ChangeSet@1.3292.3.3, 2015-01-24 01:52:52+00:00, stenn@psp-fb1.ntp.org + Fix the package name + + ChangeLog@1.1613.2.3 +1 -0 + Fix the package name + + configure.ac@1.579.1.1 +1 -1 + Fix the package name + +ChangeSet@1.3292.3.2, 2015-01-23 10:29:31+00:00, stenn@psp-fb1.ntp.org + [Sec 2672] Code cleanup: On some OSes ::1 can be spoofed... + + ChangeLog@1.1613.2.2 +1 -0 + [Sec 2672] Code cleanup: On some OSes ::1 can be spoofed... + + ntpd/ntp_io.c@1.399 +10 -12 + [Sec 2672] Code cleanup: On some OSes ::1 can be spoofed... + +ChangeSet@1.3292.3.1, 2015-01-23 10:16:23+00:00, stenn@psp-fb1.ntp.org + [Bug 2617] Fix sntp Usage documentation section + + ChangeLog@1.1613.2.1 +3 -0 + [Bug 2617] Fix sntp Usage documentation section + + sntp/sntp-opts.def@1.46 +19 -4 + [Bug 2617] Fix sntp Usage documentation section + +ChangeSet@1.3292.2.1, 2015-01-21 19:16:29+01:00, jnperlin@nemesis.localnet + [bug 2732] leapsecond processing buggy with win8 + + ports/winnt/ntpd/nt_clockstuff.c@1.62 +19 -14 + [bug 2732] leapsecond processing buggy with win8 + +ChangeSet@1.3281.1.3, 2015-01-14 10:52:55+00:00, stenn@psp-fb1.ntp.org + Copyright update + + ChangeLog@1.1604.1.3 +1 -0 + Copyright update + + html/copyright.html@1.66 +35 -3 + Copyright update + + ntpd/invoke-ntp.conf.texi@1.170.1.1 +12 -2 + update + + ntpd/invoke-ntp.keys.texi@1.167.1.1 +12 -2 + update + + ntpd/invoke-ntpd.texi@1.483.1.1 +14 -4 + update + + ntpd/ntp.conf.5man@1.204.1.1 +15 -6 + update + + ntpd/ntp.conf.5mdoc@1.204.1.1 +14 -5 + update + + ntpd/ntp.conf.man.in@1.204.1.1 +15 -6 + update + + ntpd/ntp.conf.mdoc.in@1.204.1.1 +14 -5 + update + + ntpd/ntp.keys.5man@1.201.1.1 +14 -5 + update + + ntpd/ntp.keys.5mdoc@1.201.1.1 +15 -6 + update + + ntpd/ntp.keys.man.in@1.201.1.1 +14 -5 + update + + ntpd/ntp.keys.mdoc.in@1.201.1.1 +15 -6 + update + + ntpd/ntpd-opts.c@1.504.1.1 +240 -264 + update + + ntpd/ntpd-opts.h@1.503.1.1 +3 -11 + update + + ntpd/ntpd.1ntpdman@1.312.1.1 +15 -6 + update + + ntpd/ntpd.1ntpdmdoc@1.312.1.1 +14 -5 + update + + ntpd/ntpd.man.in@1.312.1.1 +15 -6 + update + + ntpd/ntpd.mdoc.in@1.312.1.1 +14 -5 + update + + ntpdc/invoke-ntpdc.texi@1.481.1.1 +12 -2 + update + + ntpdc/ntpdc-opts.c@1.499.1.1 +108 -132 + update + + ntpdc/ntpdc-opts.h@1.498.1.1 +3 -11 + update + + ntpdc/ntpdc.1ntpdcman@1.312.1.1 +14 -5 + update + + ntpdc/ntpdc.1ntpdcmdoc@1.312.1.1 +13 -4 + update + + ntpdc/ntpdc.html@1.325.1.1 +86 -56 + update + + ntpdc/ntpdc.man.in@1.312.1.1 +14 -5 + update + + ntpdc/ntpdc.mdoc.in@1.312.1.1 +13 -4 + update + + ntpq/invoke-ntpq.texi@1.487.1.1 +12 -2 + update + + ntpq/ntpq-opts.c@1.504.1.1 +107 -131 + update + + ntpq/ntpq-opts.h@1.502.1.1 +3 -11 + update + + ntpq/ntpq.1ntpqman@1.315.1.1 +15 -6 + update + + ntpq/ntpq.1ntpqmdoc@1.315.1.1 +14 -5 + update + + ntpq/ntpq.man.in@1.315.1.1 +15 -6 + update + + ntpq/ntpq.mdoc.in@1.315.1.1 +14 -5 + update + + ntpsnmpd/invoke-ntpsnmpd.texi@1.483.1.1 +12 -2 + update + + ntpsnmpd/ntpsnmpd-opts.c@1.501.1.1 +69 -93 + update + + ntpsnmpd/ntpsnmpd-opts.h@1.500.1.1 +3 -11 + update + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.312.1.1 +14 -5 + update + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.312.1.1 +13 -4 + update + + ntpsnmpd/ntpsnmpd.man.in@1.312.1.1 +14 -5 + update + + ntpsnmpd/ntpsnmpd.mdoc.in@1.312.1.1 +13 -4 + update + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.74.1.1 +2 -2 + update + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.74.1.1 +2 -2 + update + + scripts/ntp-wait/invoke-ntp-wait.texi@1.304.1.1 +1 -1 + update + + scripts/ntp-wait/ntp-wait-opts@1.40.1.1 +1 -1 + update + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.302.1.1 +2 -2 + update + + scripts/ntp-wait/ntp-wait.html@1.321.1.1 +47 -29 + update + + scripts/ntp-wait/ntp-wait.mdoc.in@1.302.1.1 +2 -2 + update + + scripts/ntpsweep/ntpsweep-opts@1.42.1.1 +1 -1 + update + + scripts/ntptrace/invoke-ntptrace.texi@1.93.1.1 +1 -1 + update + + scripts/ntptrace/ntptrace-opts@1.42.1.1 +1 -1 + update + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.81.1.1 +2 -2 + update + + scripts/ntptrace/ntptrace.html@1.94.1.1 +34 -25 + update + + scripts/ntptrace/ntptrace.mdoc.in@1.82.1.1 +2 -2 + update + + scripts/plot_summary-opts@1.42.1.1 +1 -1 + update + + scripts/summary-opts@1.42.1.1 +1 -1 + update + + sntp/include/copyright.def@1.25 +2 -2 + Copyright update + + sntp/include/ntp.lic@1.7 +3 -1 + Copyright update + + sntp/invoke-sntp.texi@1.480.1.1 +12 -2 + update + + sntp/sntp-opts.c@1.498.1.1 +160 -184 + update + + sntp/sntp-opts.h@1.497.1.1 +3 -11 + update + + sntp/sntp.1sntpman@1.315.1.1 +14 -5 + update + + sntp/sntp.1sntpmdoc@1.315.1.1 +13 -4 + update + + sntp/sntp.html@1.495.1.1 +118 -84 + update + + sntp/sntp.man.in@1.315.1.1 +14 -5 + update + + sntp/sntp.mdoc.in@1.315.1.1 +13 -4 + update + + util/invoke-ntp-keygen.texi@1.484.1.1 +12 -2 + update + + util/ntp-keygen-opts.c@1.501.1.1 +174 -198 + update + + util/ntp-keygen-opts.h@1.500.1.1 +3 -11 + update + + util/ntp-keygen.1ntp-keygenman@1.312.1.1 +15 -6 + update + + util/ntp-keygen.1ntp-keygenmdoc@1.312.1.1 +14 -5 + update + + util/ntp-keygen.man.in@1.312.1.1 +15 -6 + update + + util/ntp-keygen.mdoc.in@1.312.1.1 +14 -5 + update + +ChangeSet@1.3292.1.8, 2015-01-07 03:05:51-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1_BETA5 + TAG: NTP_4_2_8P1_BETA5 + + ChangeLog@1.1613.1.8 +1 -0 + NTP_4_2_8P1_BETA5 + + ntpd/invoke-ntp.conf.texi@1.173 +1 -1 + NTP_4_2_8P1_BETA5 + + ntpd/invoke-ntp.keys.texi@1.170 +1 -1 + NTP_4_2_8P1_BETA5 + + ntpd/invoke-ntpd.texi@1.486 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.conf.5man@1.207 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.conf.5mdoc@1.207 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.conf.html@1.166 +1 -1 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.conf.man.in@1.207 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.conf.mdoc.in@1.207 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.keys.5man@1.204 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.keys.5mdoc@1.204 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.keys.html@1.167 +1 -1 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.keys.man.in@1.204 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntp.keys.mdoc.in@1.204 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntpd-opts.c@1.507 +7 -7 + NTP_4_2_8P1_BETA5 + + ntpd/ntpd-opts.h@1.506 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpd/ntpd.1ntpdman@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpd/ntpd.1ntpdmdoc@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntpd.html@1.161 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpd/ntpd.man.in@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpd/ntpd.mdoc.in@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpdc/invoke-ntpdc.texi@1.484 +26 -2 + NTP_4_2_8P1_BETA5 + + ntpdc/ntpdc-opts.c@1.502 +7 -7 + NTP_4_2_8P1_BETA5 + + ntpdc/ntpdc-opts.h@1.501 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpdc/ntpdc.1ntpdcman@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpdc/ntpdc.1ntpdcmdoc@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpdc/ntpdc.html@1.328 +27 -2 + NTP_4_2_8P1_BETA5 + + ntpdc/ntpdc.man.in@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpdc/ntpdc.mdoc.in@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpq/invoke-ntpq.texi@1.490 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpq/ntpq-opts.c@1.507 +7 -7 + NTP_4_2_8P1_BETA5 + + ntpq/ntpq-opts.h@1.505 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpq/ntpq.1ntpqman@1.318 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpq/ntpq.1ntpqmdoc@1.318 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpq/ntpq.html@1.158 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpq/ntpq.man.in@1.318 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpq/ntpq.mdoc.in@1.318 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.486 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/ntpsnmpd-opts.c@1.504 +7 -7 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/ntpsnmpd-opts.h@1.503 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/ntpsnmpd.html@1.156 +1 -1 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/ntpsnmpd.man.in@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + + packageinfo.sh@1.498 +1 -1 + NTP_4_2_8P1_BETA5 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.77 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.77 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/calc_tickadj/calc_tickadj.html@1.79 +1 -1 + NTP_4_2_8P1_BETA5 + + scripts/calc_tickadj/calc_tickadj.man.in@1.76 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.77 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.81 +1 -1 + NTP_4_2_8P1_BETA5 + + scripts/invoke-plot_summary.texi@1.98 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/invoke-summary.texi@1.98 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.307 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntp-wait/ntp-wait-opts@1.43 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.305 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.305 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntp-wait/ntp-wait.html@1.324 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntp-wait/ntp-wait.man.in@1.305 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.305 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.96 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntpsweep/ntpsweep-opts@1.45 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.84 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.84 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntpsweep/ntpsweep.html@1.97 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntpsweep/ntpsweep.man.in@1.84 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.85 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntptrace/invoke-ntptrace.texi@1.96 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntptrace/ntptrace-opts@1.45 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntptrace/ntptrace.1ntptraceman@1.84 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.84 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntptrace/ntptrace.html@1.97 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/ntptrace/ntptrace.man.in@1.84 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/ntptrace/ntptrace.mdoc.in@1.85 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/plot_summary-opts@1.45 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/plot_summary.1plot_summaryman@1.96 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/plot_summary.1plot_summarymdoc@1.96 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/plot_summary.html@1.99 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/plot_summary.man.in@1.96 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/plot_summary.mdoc.in@1.96 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/summary-opts@1.45 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/summary.1summaryman@1.96 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/summary.1summarymdoc@1.96 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/summary.html@1.99 +2 -2 + NTP_4_2_8P1_BETA5 + + scripts/summary.man.in@1.96 +3 -3 + NTP_4_2_8P1_BETA5 + + scripts/summary.mdoc.in@1.96 +2 -2 + NTP_4_2_8P1_BETA5 + + sntp/invoke-sntp.texi@1.483 +2 -2 + NTP_4_2_8P1_BETA5 + + sntp/sntp-opts.c@1.502 +7 -7 + NTP_4_2_8P1_BETA5 + + sntp/sntp-opts.h@1.500 +3 -3 + NTP_4_2_8P1_BETA5 + + sntp/sntp.1sntpman@1.318 +3 -3 + NTP_4_2_8P1_BETA5 + + sntp/sntp.1sntpmdoc@1.318 +2 -2 + NTP_4_2_8P1_BETA5 + + sntp/sntp.html@1.498 +2 -2 + NTP_4_2_8P1_BETA5 + + sntp/sntp.man.in@1.318 +3 -3 + NTP_4_2_8P1_BETA5 + + sntp/sntp.mdoc.in@1.318 +2 -2 + NTP_4_2_8P1_BETA5 + + util/invoke-ntp-keygen.texi@1.487 +2 -2 + NTP_4_2_8P1_BETA5 + + util/ntp-keygen-opts.c@1.505 +7 -7 + NTP_4_2_8P1_BETA5 + + util/ntp-keygen-opts.h@1.503 +3 -3 + NTP_4_2_8P1_BETA5 + + util/ntp-keygen.1ntp-keygenman@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + util/ntp-keygen.1ntp-keygenmdoc@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + + util/ntp-keygen.html@1.162 +2 -2 + NTP_4_2_8P1_BETA5 + + util/ntp-keygen.man.in@1.315 +3 -3 + NTP_4_2_8P1_BETA5 + + util/ntp-keygen.mdoc.in@1.315 +2 -2 + NTP_4_2_8P1_BETA5 + +ChangeSet@1.3292.1.7, 2015-01-07 07:35:11+00:00, burnicki@psp-deb1.ntp.org + cleanup + + ChangeLog@1.1613.1.7 +2 -0 + cleanup + +ChangeSet@1.3292.1.6, 2015-01-06 15:14:03+01:00, burnicki@pc-martin4. + [Bug 2728] Work around C99-style structure initialization code for older compilers, specifically Visual Studio prior to VS2013. + + ChangeLog@1.1613.1.6 +2 -0 + [Bug 2728] Work around C99-style structure initialization code for older compilers, specifically Visual Studio prior to VS2013. + + ntpq/ntpq-subs.c@1.103 +5 -2 + [Bug 2728] Fix for build environments where C99 style structure initialization is not supported. + + ports/winnt/include/config.h@1.110 +1 -0 + [Bug 2728] Define MISSING_C99_STYLE_INIT for VS versions prior to VS2013 to indicate C99-style structure initialization is not supported. + + sntp/libopts/autoopts.h@1.20 +1 -1 + [Bug 2728] Zero out whole structure, avoiding C99-style code zeroing out only specific fields. + + sntp/libopts/enum.c@1.12 +1 -1 + [Bug 2728] Zero out whole structure, avoiding C99-style code zeroing out only specific fields. + +ChangeSet@1.3292.1.5, 2015-01-06 14:29:51+01:00, burnicki@pc-martin4. + [Bug 2695] Windows build: __func__ not supported under Windows. + + ChangeLog@1.1613.1.5 +1 -0 + [Bug 2695] Windows build: __func__ not supported under Windows. + + ports/winnt/include/config.h@1.109 +5 -1 + [Bug 2695] Windows build: __func__ not supported under Windows. + +ChangeSet@1.3295, 2015-01-06 10:52:26+00:00, stenn@psp-deb1.ntp.org + Fix the package name + + configure.ac@1.580 +1 -1 + Fix the package name + +ChangeSet@1.3294, 2015-01-06 10:01:10+00:00, stenn@psp-deb1.ntp.org + [Sec 2671] vallen in extension fields are not validated + + ntpd/ntp_crypto.c@1.173 +65 -35 + [Sec 2671] vallen in extension fields are not validated + +ChangeSet@1.3292.1.4, 2015-01-04 06:17:14-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1_BETA4 + TAG: NTP_4_2_8P1_BETA4 + + ChangeLog@1.1613.1.4 +1 -0 + NTP_4_2_8P1_BETA4 + + ntpd/invoke-ntp.conf.texi@1.172 +1 -1 + NTP_4_2_8P1_BETA4 + + ntpd/invoke-ntp.keys.texi@1.169 +1 -1 + NTP_4_2_8P1_BETA4 + + ntpd/invoke-ntpd.texi@1.485 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.conf.5man@1.206 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.conf.5mdoc@1.206 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.conf.html@1.165 +14 -1 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.conf.man.in@1.206 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.conf.mdoc.in@1.206 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.keys.5man@1.203 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.keys.5mdoc@1.203 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.keys.html@1.166 +1 -1 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.keys.man.in@1.203 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntp.keys.mdoc.in@1.203 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntpd-opts.c@1.506 +7 -7 + NTP_4_2_8P1_BETA4 + + ntpd/ntpd-opts.h@1.505 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpd/ntpd.1ntpdman@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpd/ntpd.1ntpdmdoc@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntpd.html@1.160 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpd/ntpd.man.in@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpd/ntpd.mdoc.in@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpdc/invoke-ntpdc.texi@1.483 +2 -26 + NTP_4_2_8P1_BETA4 + + ntpdc/ntpdc-opts.c@1.501 +7 -7 + NTP_4_2_8P1_BETA4 + + ntpdc/ntpdc-opts.h@1.500 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpdc/ntpdc.1ntpdcman@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpdc/ntpdc.1ntpdcmdoc@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpdc/ntpdc.html@1.327 +2 -27 + NTP_4_2_8P1_BETA4 + + ntpdc/ntpdc.man.in@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpdc/ntpdc.mdoc.in@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpq/invoke-ntpq.texi@1.489 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpq/ntpq-opts.c@1.506 +7 -7 + NTP_4_2_8P1_BETA4 + + ntpq/ntpq-opts.h@1.504 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpq/ntpq.1ntpqman@1.317 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpq/ntpq.1ntpqmdoc@1.317 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpq/ntpq.html@1.157 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpq/ntpq.man.in@1.317 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpq/ntpq.mdoc.in@1.317 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.485 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/ntpsnmpd-opts.c@1.503 +7 -7 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/ntpsnmpd-opts.h@1.502 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/ntpsnmpd.html@1.155 +1 -1 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/ntpsnmpd.man.in@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + + packageinfo.sh@1.497 +1 -1 + NTP_4_2_8P1_BETA4 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.76 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.76 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/calc_tickadj/calc_tickadj.html@1.78 +1 -1 + NTP_4_2_8P1_BETA4 + + scripts/calc_tickadj/calc_tickadj.man.in@1.75 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.76 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.80 +1 -1 + NTP_4_2_8P1_BETA4 + + scripts/invoke-plot_summary.texi@1.97 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/invoke-summary.texi@1.97 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.306 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntp-wait/ntp-wait-opts@1.42 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.304 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.304 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntp-wait/ntp-wait.html@1.323 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntp-wait/ntp-wait.man.in@1.304 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.304 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.95 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntpsweep/ntpsweep-opts@1.44 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.83 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.83 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntpsweep/ntpsweep.html@1.96 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntpsweep/ntpsweep.man.in@1.83 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.84 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntptrace/invoke-ntptrace.texi@1.95 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntptrace/ntptrace-opts@1.44 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntptrace/ntptrace.1ntptraceman@1.83 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.83 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntptrace/ntptrace.html@1.96 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/ntptrace/ntptrace.man.in@1.83 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/ntptrace/ntptrace.mdoc.in@1.84 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/plot_summary-opts@1.44 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/plot_summary.1plot_summaryman@1.95 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/plot_summary.1plot_summarymdoc@1.95 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/plot_summary.html@1.98 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/plot_summary.man.in@1.95 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/plot_summary.mdoc.in@1.95 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/summary-opts@1.44 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/summary.1summaryman@1.95 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/summary.1summarymdoc@1.95 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/summary.html@1.98 +2 -2 + NTP_4_2_8P1_BETA4 + + scripts/summary.man.in@1.95 +3 -3 + NTP_4_2_8P1_BETA4 + + scripts/summary.mdoc.in@1.95 +2 -2 + NTP_4_2_8P1_BETA4 + + sntp/invoke-sntp.texi@1.482 +2 -2 + NTP_4_2_8P1_BETA4 + + sntp/sntp-opts.c@1.501 +7 -7 + NTP_4_2_8P1_BETA4 + + sntp/sntp-opts.h@1.499 +3 -3 + NTP_4_2_8P1_BETA4 + + sntp/sntp.1sntpman@1.317 +3 -3 + NTP_4_2_8P1_BETA4 + + sntp/sntp.1sntpmdoc@1.317 +2 -2 + NTP_4_2_8P1_BETA4 + + sntp/sntp.html@1.497 +2 -2 + NTP_4_2_8P1_BETA4 + + sntp/sntp.man.in@1.317 +3 -3 + NTP_4_2_8P1_BETA4 + + sntp/sntp.mdoc.in@1.317 +2 -2 + NTP_4_2_8P1_BETA4 + + util/invoke-ntp-keygen.texi@1.486 +2 -2 + NTP_4_2_8P1_BETA4 + + util/ntp-keygen-opts.c@1.504 +7 -7 + NTP_4_2_8P1_BETA4 + + util/ntp-keygen-opts.h@1.502 +3 -3 + NTP_4_2_8P1_BETA4 + + util/ntp-keygen.1ntp-keygenman@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + util/ntp-keygen.1ntp-keygenmdoc@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + + util/ntp-keygen.html@1.161 +2 -2 + NTP_4_2_8P1_BETA4 + + util/ntp-keygen.man.in@1.314 +3 -3 + NTP_4_2_8P1_BETA4 + + util/ntp-keygen.mdoc.in@1.314 +2 -2 + NTP_4_2_8P1_BETA4 + +ChangeSet@1.3292.1.3, 2015-01-04 04:48:35-05:00, stenn@deacon.udel.edu + Fix a regression introduced to timepps-Solaris.h + + ChangeLog@1.1613.1.3 +4 -0 + Fix a regression introduced to timepps-Solaris.h + + include/timepps-Solaris.h@1.8 +1 -1 + Fix a regression introduced to timepps-Solaris.h + +ChangeSet@1.3292.1.2, 2015-01-04 09:08:36+00:00, stenn@psp-fb1.ntp.org + [Bug 2695] Build problem on Windows (sys/socket.h) + + ChangeLog@1.1613.1.2 +4 -3 + [Bug 2695] Build problem on Windows (sys/socket.h) + + ntpd/refclock_nmea.c@1.77 +2 -0 + [Bug 2695] Build problem on Windows (sys/socket.h) + +ChangeSet@1.3292.1.1, 2015-01-04 00:20:52+00:00, stenn@psp-fb1.ntp.org + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ChangeLog@1.1613.1.1 +3 -0 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/keyword-gen-utd@1.21 +1 -1 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/ntp_keyword.h@1.23 +596 -587 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/ntp_parser.c@1.89 +1006 -1001 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/ntp_parser.h@1.55 +202 -200 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + +ChangeSet@1.3293, 2015-01-03 10:33:57+00:00, stenn@psp-deb1.ntp.org + [Sec 2671] vallen in extension fields are not validated + + ChangeLog@1.1614 +3 -0 + [Sec 2671] vallen in extension fields are not validated + + ntpd/ntp_crypto.c@1.172 +19 -12 + [Sec 2671] vallen in extension fields are not validated + +ChangeSet@1.3292, 2015-01-02 23:07:47-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1_BETA3 + TAG: NTP_4_2_8P1_BETA3 + + ChangeLog@1.1613 +1 -0 + NTP_4_2_8P1_BETA3 + + ntpd/invoke-ntp.conf.texi@1.171 +15 -1 + NTP_4_2_8P1_BETA3 + + ntpd/invoke-ntp.keys.texi@1.168 +1 -1 + NTP_4_2_8P1_BETA3 + + ntpd/invoke-ntpd.texi@1.484 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.conf.5man@1.205 +18 -3 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.conf.5mdoc@1.205 +16 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.conf.html@1.164 +1 -1 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.conf.man.in@1.205 +18 -3 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.conf.mdoc.in@1.205 +16 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.keys.5man@1.202 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.keys.5mdoc@1.202 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.keys.html@1.165 +1 -1 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.keys.man.in@1.202 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntp.keys.mdoc.in@1.202 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntpd-opts.c@1.505 +7 -7 + NTP_4_2_8P1_BETA3 + + ntpd/ntpd-opts.h@1.504 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpd/ntpd.1ntpdman@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpd/ntpd.1ntpdmdoc@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntpd.html@1.159 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpd/ntpd.man.in@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpd/ntpd.mdoc.in@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpdc/invoke-ntpdc.texi@1.482 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpdc/ntpdc-opts.c@1.500 +7 -7 + NTP_4_2_8P1_BETA3 + + ntpdc/ntpdc-opts.h@1.499 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpdc/ntpdc.1ntpdcman@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpdc/ntpdc.1ntpdcmdoc@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpdc/ntpdc.html@1.326 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpdc/ntpdc.man.in@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpdc/ntpdc.mdoc.in@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpq/invoke-ntpq.texi@1.488 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpq/ntpq-opts.c@1.505 +7 -7 + NTP_4_2_8P1_BETA3 + + ntpq/ntpq-opts.h@1.503 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpq/ntpq.1ntpqman@1.316 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpq/ntpq.1ntpqmdoc@1.316 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpq/ntpq.html@1.156 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpq/ntpq.man.in@1.316 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpq/ntpq.mdoc.in@1.316 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.484 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/ntpsnmpd-opts.c@1.502 +7 -7 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/ntpsnmpd-opts.h@1.501 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/ntpsnmpd.html@1.154 +1 -1 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/ntpsnmpd.man.in@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + + packageinfo.sh@1.496 +1 -1 + NTP_4_2_8P1_BETA3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.75 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.75 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/calc_tickadj/calc_tickadj.html@1.77 +1 -1 + NTP_4_2_8P1_BETA3 + + scripts/calc_tickadj/calc_tickadj.man.in@1.74 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.75 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.79 +1 -1 + NTP_4_2_8P1_BETA3 + + scripts/invoke-plot_summary.texi@1.96 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/invoke-summary.texi@1.96 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.305 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntp-wait/ntp-wait-opts@1.41 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.303 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.303 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntp-wait/ntp-wait.html@1.322 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntp-wait/ntp-wait.man.in@1.303 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.303 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.94 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntpsweep/ntpsweep-opts@1.43 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.82 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.82 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntpsweep/ntpsweep.html@1.95 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntpsweep/ntpsweep.man.in@1.82 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.83 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntptrace/invoke-ntptrace.texi@1.94 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntptrace/ntptrace-opts@1.43 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntptrace/ntptrace.1ntptraceman@1.82 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.82 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntptrace/ntptrace.html@1.95 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/ntptrace/ntptrace.man.in@1.82 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/ntptrace/ntptrace.mdoc.in@1.83 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/plot_summary-opts@1.43 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/plot_summary.1plot_summaryman@1.94 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/plot_summary.1plot_summarymdoc@1.94 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/plot_summary.html@1.97 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/plot_summary.man.in@1.94 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/plot_summary.mdoc.in@1.94 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/summary-opts@1.43 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/summary.1summaryman@1.94 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/summary.1summarymdoc@1.94 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/summary.html@1.97 +2 -2 + NTP_4_2_8P1_BETA3 + + scripts/summary.man.in@1.94 +3 -3 + NTP_4_2_8P1_BETA3 + + scripts/summary.mdoc.in@1.94 +2 -2 + NTP_4_2_8P1_BETA3 + + sntp/invoke-sntp.texi@1.481 +2 -2 + NTP_4_2_8P1_BETA3 + + sntp/sntp-opts.c@1.500 +9 -9 + NTP_4_2_8P1_BETA3 + + sntp/sntp-opts.h@1.498 +3 -3 + NTP_4_2_8P1_BETA3 + + sntp/sntp.1sntpman@1.316 +3 -3 + NTP_4_2_8P1_BETA3 + + sntp/sntp.1sntpmdoc@1.316 +2 -2 + NTP_4_2_8P1_BETA3 + + sntp/sntp.html@1.496 +2 -2 + NTP_4_2_8P1_BETA3 + + sntp/sntp.man.in@1.316 +3 -3 + NTP_4_2_8P1_BETA3 + + sntp/sntp.mdoc.in@1.316 +2 -2 + NTP_4_2_8P1_BETA3 + + util/invoke-ntp-keygen.texi@1.485 +2 -2 + NTP_4_2_8P1_BETA3 + + util/ntp-keygen-opts.c@1.503 +9 -9 + NTP_4_2_8P1_BETA3 + + util/ntp-keygen-opts.h@1.501 +3 -3 + NTP_4_2_8P1_BETA3 + + util/ntp-keygen.1ntp-keygenman@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + util/ntp-keygen.1ntp-keygenmdoc@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + + util/ntp-keygen.html@1.160 +2 -2 + NTP_4_2_8P1_BETA3 + + util/ntp-keygen.man.in@1.313 +3 -3 + NTP_4_2_8P1_BETA3 + + util/ntp-keygen.mdoc.in@1.313 +2 -2 + NTP_4_2_8P1_BETA3 + +ChangeSet@1.3281.3.3, 2015-01-02 17:37:39+01:00, jnperlin@hydra.(none) + [Bug 2627] changelog file syntax + + ChangeLog@1.1604.3.2 +1 -0 + [Bug 2627] changelog file syntax + +ChangeSet@1.3281.3.2, 2015-01-02 17:23:21+01:00, jnperlin@nemesis.localnet + [Bug 2627] sidekick: avoid runtime conversion trap on MSVC builds + + ntpd/ntp_leapsec.c@1.13.1.1 +2 -1 + [Bug 2627] sidekick: avoid runtime conversion trap on MSVC builds + +ChangeSet@1.3273.1.1, 2015-01-02 13:45:05+01:00, jnperlin@hydra.(none) + [Bug 2627] shm refclock allows only two units with owner-only access + + ChangeLog@1.1597.1.1 +3 -0 + [Bug 2627] shm refclock allows only two units with owner-only access + + html/drivers/driver28.html@1.17 +122 -17 + [Bug 2627] shm refclock allows only two units with owner-only access + update docu + + ntpd/refclock_shm.c@1.30 +111 -114 + [Bug 2627] shm refclock allows only two units with owner-only access + use mode bit 0 to select public access for units >= 2 (default is private for all now) + +ChangeSet@1.3288, 2015-01-02 07:59:13+00:00, stenn@psp-fb1.ntp.org + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/Makefile.am@1.132 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_loopfilter.c@1.176 +44 -8 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/m4/hms_search_lib.m4@1.2 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/m4/ntp_libntp.m4@1.28 +6 -0 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + +ChangeSet@1.3281.1.2, 2015-01-01 07:31:57+00:00, stenn@psp-deb1.ntp.org + [Bug 2681] Fix display of certificate EOValidity dates on 32-bit systems + + ChangeLog@1.1604.1.2 +1 -0 + [Bug 2681] Fix display of certificate EOValidity dates on 32-bit systems + + ntpd/ntp_control.c@1.192.2.1 +28 -4 + [Bug 2681] Fix display of certificate EOValidity dates on 32-bit systems + +ChangeSet@1.3281.2.2, 2014-12-30 05:48:04-05:00, murray@pogo.udel.edu + ChangeLog: + add --- to top of ChangeLog + + ChangeLog@1.1604.2.2 +1 -1 + add --- to top of ChangeLog + +ChangeSet@1.3281.2.1, 2014-12-30 04:55:11-05:00, murray@pogo.udel.edu + ChangeLog, ntp_control.c: + Fix for bug 2700 + + ChangeLog@1.1604.2.1 +2 -0 + Fix for bug 2700 + + ntpd/ntp_control.c@1.192.1.1 +4 -1 + Fix for bug 2700 + +ChangeSet@1.3287, 2014-12-30 01:28:39+00:00, stenn@psp-fb1.ntp.org + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + html/confopt.html@1.63 +3 -1 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/ntp.conf.def@1.14 +14 -0 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + +ChangeSet@1.3286, 2014-12-30 00:29:47+00:00, stenn@psp-fb1.ntp.org + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_wwvb.c@1.35 +1 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + +ChangeSet@1.3285, 2014-12-30 00:28:06+00:00, stenn@psp-fb1.ntp.org + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ChangeLog@1.1609 +1 -0 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/keyword-gen.c@1.26 +2 -1 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/ntp_config.c@1.321 +29 -13 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + + ntpd/ntp_parser.y@1.82 +3 -0 + [Bug 2715] mdnstries option for ntp.conf from NetBSD + +ChangeSet@1.3278.1.1, 2014-12-29 08:47:40+00:00, stenn@psp-fb1.ntp.org + [Bug 2695] 4.2.8 does not build on Windows + + ChangeLog@1.1601.1.1 +1 -0 + [Bug 2695] 4.2.8 does not build on Windows + + ports/winnt/include/config.h@1.108 +1 -0 + [Bug 2695] 4.2.8 does not build on Windows + + ports/winnt/vs2008/libntp/libntp.vcproj@1.51 +6 -2 + [Bug 2695] 4.2.8 does not build on Windows + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.5 +1 -0 + [Bug 2695] 4.2.8 does not build on Windows + +ChangeSet@1.3284, 2014-12-29 06:57:50+00:00, stenn@psp-fb1.ntp.org + [Bug 2714] libevent may need to be built independently of any build of sntp + + ChangeLog@1.1608 +1 -0 + [Bug 2714] libevent may need to be built independently of any build of sntp + + sntp/Makefile.am@1.78 +7 -7 + [Bug 2714] libevent may need to be built independently of any build of sntp + +ChangeSet@1.3283, 2014-12-29 06:42:07+00:00, stenn@psp-fb1.ntp.org + [Bug 2706] libparse/info_trimble.c build dependencies are broken + + ChangeLog@1.1607 +1 -0 + [Bug 2706] libparse/info_trimble.c build dependencies are broken + + libparse/Makefile.am@1.31 +30 -2 + [Bug 2706] libparse/info_trimble.c build dependencies are broken + + libparse/info_trimble.c@1.6 +2 -2 + [Bug 2706] libparse/info_trimble.c build dependencies are broken + + libparse/mkinfo_rcmd.sed@1.4 +1 -1 + [Bug 2706] libparse/info_trimble.c build dependencies are broken + + libparse/mkinfo_scmd.sed@1.4 +1 -1 + [Bug 2706] libparse/info_trimble.c build dependencies are broken + +ChangeSet@1.3282, 2014-12-29 06:39:40+00:00, stenn@psp-fb1.ntp.org + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ChangeLog@1.1606 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ChangeLog@1.1605 +3 -0 + [Bug 2713] variable type/cast cleanup from NetBSD + + include/audio.h@1.8 +1 -1 + [Bug 2713] variable type/cast cleanup from NetBSD + + include/icom.h@1.6 +1 -1 + [Bug 2713] variable type/cast cleanup from NetBSD + + include/ntp_config.h@1.82 +3 -2 + [Bug 2713] variable type/cast cleanup from NetBSD + + include/ntp_filegen.h@1.11 +1 -1 + [Bug 2713] variable type/cast cleanup from NetBSD + + include/ntp_stdlib.h@1.77 +5 -5 + [Bug 2713] variable type/cast cleanup from NetBSD + + include/ntpd.h@1.184 +3 -3 + [Bug 2713] variable type/cast cleanup from NetBSD + + lib/isc/backtrace.c@1.2 +4 -4 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + lib/isc/event.c@1.2 +1 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + lib/isc/include/isc/backtrace.h@1.2 +2 -2 + [Bug 2713] variable type/cast, parameter name cleanup from NetBSD + + lib/isc/include/isc/socket.h@1.3 +7 -7 + [Bug 2713] variable type/cast, parameter name cleanup from NetBSD + + lib/isc/log.c@1.7 +2 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + lib/isc/netaddr.c@1.13 +2 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + lib/isc/sockaddr.c@1.12 +8 -4 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + lib/isc/unix/ifiter_getifaddrs.c@1.13 +7 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libjsmn/jsmn.c@1.3 +3 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/atoint.c@1.4 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/atolfp.c@1.5 +5 -5 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/atouint.c@1.5 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/audio.c@1.35 +12 -12 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/authkeys.c@1.25 +1 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/authreadkeys.c@1.20 +4 -4 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/emalloc.c@1.17 +2 -0 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/hextoint.c@1.5 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/hextolfp.c@1.4 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/humandate.c@1.12 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/icom.c@1.18 +1 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/modetoa.c@1.6 +3 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/mstolfp.c@1.4 +5 -5 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/ntp_calendar.c@1.14 +5 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/ntp_crypto_rnd.c@1.3 +4 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/ntp_intres.c@1.98 +2 -17 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/ntp_lineedit.c@1.12 +6 -7 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/octtoint.c@1.4 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/prettydate.c@1.19 +7 -7 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/ssl_init.c@1.17 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libntp/timetoa.c@1.5 +3 -6 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libparse/clk_meinberg.c@1.11 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libparse/clk_rawdcf.c@1.17 +10 -10 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + libparse/data_mbg.c@1.12 +3 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_control.c@1.193 +60 -62 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_crypto.c@1.171 +8 -10 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_filegen.c@1.25 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_io.c@1.398 +63 -30 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_leapsec.c@1.14 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_proto.c@1.353 +13 -14 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_request.c@1.113 +8 -9 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_restrict.c@1.36 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_scanner.c@1.46 +14 -14 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntp_util.c@1.116 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/ntpd.c@1.158 +6 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_acts.c@1.54 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_arc.c@1.32 +3 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_chu.c@1.56 +0 -4 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_gpsdjson.c@1.16 +6 -6 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_heath.c@1.19 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_irig.c@1.37 +1 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_jjy.c@1.26 +22 -23 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_jupiter.c@1.29 +54 -55 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_neoclock4x.c@1.23 +7 -7 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_nmea.c@1.76 +7 -6 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_oncore.c@1.102 +80 -80 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_parse.c@1.69 +228 -214 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_pcf.c@1.13 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_true.c@1.23 +1 -0 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_wwv.c@1.79 +3 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpd/refclock_wwvb.c@1.34 +2 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpdate/ntpdate.c@1.93 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpdc/ntpdc.c@1.102 +42 -30 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpdc/ntpdc.h@1.11 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpdc/ntpdc_ops.c@1.80 +6 -6 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpq/ntpq-subs.c@1.102 +103 -107 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpq/ntpq.c@1.154 +43 -32 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpq/ntpq.h@1.29 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpsnmpd/netsnmp_daemonize.c@1.5 +1 -0 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + ntpsnmpd/ntp_snmp.h@1.2 +3 -0 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/crypto.c@1.18 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/autoopts.h@1.19 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/autoopts/options.h@1.29 +9 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/configfile.c@1.22 +6 -6 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/enum.c@1.11 +5 -5 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/file.c@1.15 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/find.c@1.11 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/init.c@1.7 +5 -8 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/load.c@1.20 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/makeshell.c@1.19 +8 -8 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/nested.c@1.15 +7 -7 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/numeric.c@1.14 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/parse-duration.c@1.13 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/pgusage.c@1.17 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/reset.c@1.16 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/save.c@1.17 +10 -10 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/tokenize.c@1.12 +1 -1 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/libopts/usage.c@1.20 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/main.c@1.94 +7 -6 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/networking.c@1.65 +16 -7 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + sntp/sntp-opts.c@1.499 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + util/jitter.h@1.4 +3 -3 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + util/ntp-keygen-opts.c@1.502 +2 -2 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + util/ntp-keygen.c@1.100 +26 -25 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + + util/ntptime.c@1.25 +5 -4 + [Bug 2713] variable type/cast, parameter name, general cleanup from NetBSD + +ChangeSet@1.3281, 2014-12-27 06:33:35-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1_BETA2 + TAG: NTP_4_2_8P1_BETA2 + + ChangeLog@1.1604 +1 -0 + NTP_4_2_8P1_BETA2 + + ntpd/invoke-ntp.conf.texi@1.170 +1 -1 + NTP_4_2_8P1_BETA2 + + ntpd/invoke-ntp.keys.texi@1.167 +1 -1 + NTP_4_2_8P1_BETA2 + + ntpd/invoke-ntpd.texi@1.483 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.conf.5man@1.204 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.conf.5mdoc@1.204 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.conf.html@1.163 +1 -1 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.conf.man.in@1.204 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.conf.mdoc.in@1.204 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.keys.5man@1.201 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.keys.5mdoc@1.201 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.keys.html@1.164 +1 -1 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.keys.man.in@1.201 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntp.keys.mdoc.in@1.201 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntpd-opts.c@1.504 +7 -7 + NTP_4_2_8P1_BETA2 + + ntpd/ntpd-opts.h@1.503 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpd/ntpd.1ntpdman@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpd/ntpd.1ntpdmdoc@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntpd.html@1.158 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpd/ntpd.man.in@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpd/ntpd.mdoc.in@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpdc/invoke-ntpdc.texi@1.481 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpdc/ntpdc-opts.c@1.499 +7 -7 + NTP_4_2_8P1_BETA2 + + ntpdc/ntpdc-opts.h@1.498 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpdc/ntpdc.1ntpdcman@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpdc/ntpdc.1ntpdcmdoc@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpdc/ntpdc.html@1.325 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpdc/ntpdc.man.in@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpdc/ntpdc.mdoc.in@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpq/invoke-ntpq.texi@1.487 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpq/ntpq-opts.c@1.504 +7 -7 + NTP_4_2_8P1_BETA2 + + ntpq/ntpq-opts.h@1.502 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpq/ntpq.1ntpqman@1.315 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpq/ntpq.1ntpqmdoc@1.315 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpq/ntpq.html@1.155 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpq/ntpq.man.in@1.315 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpq/ntpq.mdoc.in@1.315 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.483 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/ntpsnmpd-opts.c@1.501 +7 -7 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/ntpsnmpd-opts.h@1.500 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/ntpsnmpd.html@1.153 +1 -1 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/ntpsnmpd.man.in@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + + packageinfo.sh@1.495 +1 -1 + NTP_4_2_8P1_BETA2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.74 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.74 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/calc_tickadj/calc_tickadj.html@1.76 +1 -1 + NTP_4_2_8P1_BETA2 + + scripts/calc_tickadj/calc_tickadj.man.in@1.73 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.74 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.78 +1 -1 + NTP_4_2_8P1_BETA2 + + scripts/invoke-plot_summary.texi@1.95 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/invoke-summary.texi@1.95 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.304 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntp-wait/ntp-wait-opts@1.40 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.302 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.302 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntp-wait/ntp-wait.html@1.321 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntp-wait/ntp-wait.man.in@1.302 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.302 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.93 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntpsweep/ntpsweep-opts@1.42 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.81 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.81 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntpsweep/ntpsweep.html@1.94 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntpsweep/ntpsweep.man.in@1.81 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.82 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntptrace/invoke-ntptrace.texi@1.93 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntptrace/ntptrace-opts@1.42 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntptrace/ntptrace.1ntptraceman@1.81 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.81 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntptrace/ntptrace.html@1.94 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/ntptrace/ntptrace.man.in@1.81 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/ntptrace/ntptrace.mdoc.in@1.82 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/plot_summary-opts@1.42 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/plot_summary.1plot_summaryman@1.93 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/plot_summary.1plot_summarymdoc@1.93 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/plot_summary.html@1.96 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/plot_summary.man.in@1.93 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/plot_summary.mdoc.in@1.93 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/summary-opts@1.42 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/summary.1summaryman@1.93 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/summary.1summarymdoc@1.93 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/summary.html@1.96 +2 -2 + NTP_4_2_8P1_BETA2 + + scripts/summary.man.in@1.93 +3 -3 + NTP_4_2_8P1_BETA2 + + scripts/summary.mdoc.in@1.93 +2 -2 + NTP_4_2_8P1_BETA2 + + sntp/invoke-sntp.texi@1.480 +2 -2 + NTP_4_2_8P1_BETA2 + + sntp/sntp-opts.c@1.498 +7 -7 + NTP_4_2_8P1_BETA2 + + sntp/sntp-opts.h@1.497 +3 -3 + NTP_4_2_8P1_BETA2 + + sntp/sntp.1sntpman@1.315 +3 -3 + NTP_4_2_8P1_BETA2 + + sntp/sntp.1sntpmdoc@1.315 +2 -2 + NTP_4_2_8P1_BETA2 + + sntp/sntp.html@1.495 +2 -2 + NTP_4_2_8P1_BETA2 + + sntp/sntp.man.in@1.315 +3 -3 + NTP_4_2_8P1_BETA2 + + sntp/sntp.mdoc.in@1.315 +2 -2 + NTP_4_2_8P1_BETA2 + + util/invoke-ntp-keygen.texi@1.484 +2 -2 + NTP_4_2_8P1_BETA2 + + util/ntp-keygen-opts.c@1.501 +7 -7 + NTP_4_2_8P1_BETA2 + + util/ntp-keygen-opts.h@1.500 +3 -3 + NTP_4_2_8P1_BETA2 + + util/ntp-keygen.1ntp-keygenman@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + util/ntp-keygen.1ntp-keygenmdoc@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + + util/ntp-keygen.html@1.159 +2 -2 + NTP_4_2_8P1_BETA2 + + util/ntp-keygen.man.in@1.312 +3 -3 + NTP_4_2_8P1_BETA2 + + util/ntp-keygen.mdoc.in@1.312 +2 -2 + NTP_4_2_8P1_BETA2 + +ChangeSet@1.3280, 2014-12-26 22:21:06-05:00, stenn@deacon.udel.edu + [Bug 2674] Install sntp in sbin on NetBSD + + ChangeLog@1.1603 +1 -0 + [Bug 2674] Install sntp in sbin on NetBSD + + sntp/loc/netbsd@1.3 +1 -1 + [Bug 2674] Install sntp in sbin on NetBSD + +ChangeSet@1.3279, 2014-12-26 22:11:56-05:00, stenn@deacon.udel.edu + [Bug 2707] Avoid a C90 extension in libjsmn/jsmn.c + + ChangeLog@1.1602 +1 -0 + [Bug 2707] Avoid a C90 extension in libjsmn/jsmn.c + + libjsmn/jsmn.c@1.2 +2 -1 + [Bug 2707] Avoid a C90 extension in libjsmn/jsmn.c + +ChangeSet@1.3278, 2014-12-26 23:56:33+00:00, stenn@psp-deb1.ntp.org + [Bug 2693] ntp-keygen doesn't build without OpenSSL and sntp + + ChangeLog@1.1601 +1 -0 + [Bug 2693] ntp-keygen doesn't build without OpenSSL and sntp + + sntp/Makefile.am@1.77 +5 -4 + [Bug 2693] ntp-keygen doesn't build without OpenSSL and sntp + +ChangeSet@1.3277, 2014-12-26 23:50:15+00:00, stenn@psp-deb1.ntp.org + [Bug 2709] see if we have a C99 compiler (not yet required) + + ChangeLog@1.1600 +1 -1 + [Bug 2709] see if we have a C99 compiler (not yet required) + +ChangeSet@1.3276, 2014-12-26 23:48:57+00:00, stenn@psp-deb1.ntp.org + build: see if we have a C99 compiler (not yet required) + + ChangeLog@1.1599 +3 -0 + build: see if we have a C99 compiler (not yet required) + + sntp/m4/ntp_compiler.m4@1.5 +1 -0 + build: see if we have a C99 compiler (not yet required) + +ChangeSet@1.3275, 2014-12-23 16:59:55-05:00, stenn@deacon.udel.edu + NTP_4_2_8P1_BETA1 + TAG: NTP_4_2_8P1_BETA1 + + ChangeLog@1.1598 +1 -0 + NTP_4_2_8P1_BETA1 + + ntpd/invoke-ntp.conf.texi@1.169 +1 -1 + NTP_4_2_8P1_BETA1 + + ntpd/invoke-ntp.keys.texi@1.166 +1 -1 + NTP_4_2_8P1_BETA1 + + ntpd/invoke-ntpd.texi@1.482 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.conf.5man@1.203 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.conf.5mdoc@1.203 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.conf.html@1.162 +1 -1 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.conf.man.in@1.203 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.conf.mdoc.in@1.203 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.keys.5man@1.200 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.keys.5mdoc@1.200 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.keys.html@1.163 +1 -1 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.keys.man.in@1.200 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntp.keys.mdoc.in@1.200 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntpd-opts.c@1.503 +239 -239 + NTP_4_2_8P1_BETA1 + + ntpd/ntpd-opts.h@1.502 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpd/ntpd.1ntpdman@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpd/ntpd.1ntpdmdoc@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntpd.html@1.157 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpd/ntpd.man.in@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpd/ntpd.mdoc.in@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpdc/invoke-ntpdc.texi@1.480 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpdc/ntpdc-opts.c@1.498 +107 -107 + NTP_4_2_8P1_BETA1 + + ntpdc/ntpdc-opts.h@1.497 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpdc/ntpdc.1ntpdcman@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpdc/ntpdc.1ntpdcmdoc@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpdc/ntpdc.html@1.324 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpdc/ntpdc.man.in@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpdc/ntpdc.mdoc.in@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpq/invoke-ntpq.texi@1.486 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpq/ntpq-opts.c@1.503 +106 -106 + NTP_4_2_8P1_BETA1 + + ntpq/ntpq-opts.h@1.501 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpq/ntpq.1ntpqman@1.314 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpq/ntpq.1ntpqmdoc@1.314 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpq/ntpq.html@1.154 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpq/ntpq.man.in@1.314 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpq/ntpq.mdoc.in@1.314 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.482 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/ntpsnmpd-opts.c@1.500 +68 -68 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/ntpsnmpd-opts.h@1.499 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/ntpsnmpd.html@1.152 +1 -1 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/ntpsnmpd.man.in@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + + packageinfo.sh@1.494 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.73 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.73 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/calc_tickadj/calc_tickadj.html@1.75 +1 -1 + NTP_4_2_8P1_BETA1 + + scripts/calc_tickadj/calc_tickadj.man.in@1.72 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.73 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.77 +1 -1 + NTP_4_2_8P1_BETA1 + + scripts/invoke-plot_summary.texi@1.94 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/invoke-summary.texi@1.94 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.303 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntp-wait/ntp-wait-opts@1.39 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.301 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.301 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntp-wait/ntp-wait.html@1.320 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntp-wait/ntp-wait.man.in@1.301 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.301 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.92 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntpsweep/ntpsweep-opts@1.41 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.80 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.80 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntpsweep/ntpsweep.html@1.93 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntpsweep/ntpsweep.man.in@1.80 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.81 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntptrace/invoke-ntptrace.texi@1.92 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntptrace/ntptrace-opts@1.41 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntptrace/ntptrace.1ntptraceman@1.80 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.80 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntptrace/ntptrace.html@1.93 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/ntptrace/ntptrace.man.in@1.80 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/ntptrace/ntptrace.mdoc.in@1.81 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/plot_summary-opts@1.41 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/plot_summary.1plot_summaryman@1.92 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/plot_summary.1plot_summarymdoc@1.92 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/plot_summary.html@1.95 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/plot_summary.man.in@1.92 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/plot_summary.mdoc.in@1.92 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/summary-opts@1.41 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/summary.1summaryman@1.92 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/summary.1summarymdoc@1.92 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/summary.html@1.95 +2 -2 + NTP_4_2_8P1_BETA1 + + scripts/summary.man.in@1.92 +3 -3 + NTP_4_2_8P1_BETA1 + + scripts/summary.mdoc.in@1.92 +2 -2 + NTP_4_2_8P1_BETA1 + + sntp/invoke-sntp.texi@1.479 +2 -2 + NTP_4_2_8P1_BETA1 + + sntp/sntp-opts.c@1.497 +159 -159 + NTP_4_2_8P1_BETA1 + + sntp/sntp-opts.h@1.496 +3 -3 + NTP_4_2_8P1_BETA1 + + sntp/sntp.1sntpman@1.314 +3 -3 + NTP_4_2_8P1_BETA1 + + sntp/sntp.1sntpmdoc@1.314 +2 -2 + NTP_4_2_8P1_BETA1 + + sntp/sntp.html@1.494 +2 -2 + NTP_4_2_8P1_BETA1 + + sntp/sntp.man.in@1.314 +3 -3 + NTP_4_2_8P1_BETA1 + + sntp/sntp.mdoc.in@1.314 +2 -2 + NTP_4_2_8P1_BETA1 + + util/invoke-ntp-keygen.texi@1.483 +2 -2 + NTP_4_2_8P1_BETA1 + + util/ntp-keygen-opts.c@1.500 +173 -173 + NTP_4_2_8P1_BETA1 + + util/ntp-keygen-opts.h@1.499 +3 -3 + NTP_4_2_8P1_BETA1 + + util/ntp-keygen.1ntp-keygenman@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + util/ntp-keygen.1ntp-keygenmdoc@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + + util/ntp-keygen.html@1.158 +2 -2 + NTP_4_2_8P1_BETA1 + + util/ntp-keygen.man.in@1.311 +3 -3 + NTP_4_2_8P1_BETA1 + + util/ntp-keygen.mdoc.in@1.311 +2 -2 + NTP_4_2_8P1_BETA1 + +ChangeSet@1.3274, 2014-12-23 21:36:47+00:00, stenn@psp-deb1.ntp.org + Disable config.cache-* files for now + + build@1.49 +5 -1 + Disable config.cache-* files for now + +ChangeSet@1.3273, 2014-12-23 04:34:37+00:00, stenn@psp-deb1.ntp.org + Update cvo.sh for new CentOS version format + + sntp/scripts/cvo.sh@1.8 +7 -1 + Update cvo.sh for new CentOS version format + +ChangeSet@1.3272, 2014-12-22 05:59:33+00:00, stenn@psp-fb1.ntp.org + [Bug 2693] ntp-keygen doesn't build without OpenSSL + + ChangeLog@1.1597 +2 -1 + [Bug 2693] ntp-keygen doesn't build without OpenSSL + + Makefile.am@1.124 +3 -2 + [Bug 2693] ntp-keygen doesn't build without OpenSSL + + configure.ac@1.579 +5 -1 + [Bug 2693] ntp-keygen doesn't build without OpenSSL + + libntp/ntp_crypto_rnd.c@1.2 +15 -0 + [Bug 2693] ntp-keygen doesn't build without OpenSSL + + sntp/configure.ac@1.77 +8 -5 + [Bug 2693] ntp-keygen doesn't build without OpenSSL + + sntp/m4/ntp_libevent.m4@1.12 +23 -2 + [Bug 2693] ntp-keygen doesn't build without OpenSSL + + util/Makefile.am@1.77 +1 -0 + [Bug 2693] ntp-keygen doesn't build without OpenSSL + +ChangeSet@1.3271, 2014-12-22 05:51:47+00:00, stenn@psp-fb1.ntp.org + [Bug 2699] IN6_IS_ADDR_LOOPBACK build problems on some OSes + + ChangeLog@1.1596 +1 -0 + [Bug 2699] IN6_IS_ADDR_LOOPBACK build problems on some OSes + +ChangeSet@1.3270, 2014-12-22 02:55:14+00:00, stenn@psp-deb1.ntp.org + [Bug 2699] HAVE_SYS_SELECT_H is misspelled in refclock_gpsdjson.c + + ChangeLog@1.1595 +3 -0 + [Bug 2699] HAVE_SYS_SELECT_H is misspelled in refclock_gpsdjson.c + + ntpd/refclock_gpsdjson.c@1.15 +1 -1 + [Bug 2699] HAVE_SYS_SELECT_H is misspelled in refclock_gpsdjson.c + +ChangeSet@1.3269, 2014-12-22 02:52:42+00:00, stenn@psp-deb1.ntp.org + NEWS file update + + NEWS@1.129 +39 -12 + +ChangeSet@1.3268, 2014-12-21 01:24:15+00:00, stenn@psp-deb1.ntp.org + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs + + ChangeLog@1.1594 +1 -0 + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs + + ntpd/ntp_io.c@1.397 +4 -6 + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs + +ChangeSet@1.3267, 2014-12-21 00:35:39+00:00, stenn@psp-deb1.ntp.org + typo + + build@1.48 +1 -1 + typo + +ChangeSet@1.3266, 2014-12-19 07:53:07-05:00, stenn@deacon.udel.edu + NTP_4_2_8 + TAG: NTP_4_2_8 + + ChangeLog@1.1593 +1 -0 + NTP_4_2_8 + + ntpd/invoke-ntp.conf.texi@1.168 +1 -1 + NTP_4_2_8 + + ntpd/invoke-ntp.keys.texi@1.165 +1 -1 + NTP_4_2_8 + + ntpd/invoke-ntpd.texi@1.481 +2 -2 + NTP_4_2_8 + + ntpd/ntp.conf.5man@1.202 +3 -3 + NTP_4_2_8 + + ntpd/ntp.conf.5mdoc@1.202 +2 -2 + NTP_4_2_8 + + ntpd/ntp.conf.html@1.161 +1 -1 + NTP_4_2_8 + + ntpd/ntp.conf.man.in@1.202 +3 -3 + NTP_4_2_8 + + ntpd/ntp.conf.mdoc.in@1.202 +2 -2 + NTP_4_2_8 + + ntpd/ntp.keys.5man@1.199 +2 -2 + NTP_4_2_8 + + ntpd/ntp.keys.5mdoc@1.199 +2 -2 + NTP_4_2_8 + + ntpd/ntp.keys.html@1.162 +1 -1 + NTP_4_2_8 + + ntpd/ntp.keys.man.in@1.199 +2 -2 + NTP_4_2_8 + + ntpd/ntp.keys.mdoc.in@1.199 +2 -2 + NTP_4_2_8 + + ntpd/ntpd-opts.c@1.502 +239 -239 + NTP_4_2_8 + + ntpd/ntpd-opts.h@1.501 +3 -3 + NTP_4_2_8 + + ntpd/ntpd.1ntpdman@1.310 +3 -3 + NTP_4_2_8 + + ntpd/ntpd.1ntpdmdoc@1.310 +2 -2 + NTP_4_2_8 + + ntpd/ntpd.html@1.156 +2 -2 + NTP_4_2_8 + + ntpd/ntpd.man.in@1.310 +3 -3 + NTP_4_2_8 + + ntpd/ntpd.mdoc.in@1.310 +2 -2 + NTP_4_2_8 + + ntpdc/invoke-ntpdc.texi@1.479 +2 -2 + NTP_4_2_8 + + ntpdc/ntpdc-opts.c@1.497 +107 -107 + NTP_4_2_8 + + ntpdc/ntpdc-opts.h@1.496 +3 -3 + NTP_4_2_8 + + ntpdc/ntpdc.1ntpdcman@1.310 +3 -3 + NTP_4_2_8 + + ntpdc/ntpdc.1ntpdcmdoc@1.310 +2 -2 + NTP_4_2_8 + + ntpdc/ntpdc.html@1.323 +2 -2 + NTP_4_2_8 + + ntpdc/ntpdc.man.in@1.310 +3 -3 + NTP_4_2_8 + + ntpdc/ntpdc.mdoc.in@1.310 +2 -2 + NTP_4_2_8 + + ntpq/invoke-ntpq.texi@1.485 +2 -2 + NTP_4_2_8 + + ntpq/ntpq-opts.c@1.502 +106 -106 + NTP_4_2_8 + + ntpq/ntpq-opts.h@1.500 +3 -3 + NTP_4_2_8 + + ntpq/ntpq.1ntpqman@1.313 +3 -3 + NTP_4_2_8 + + ntpq/ntpq.1ntpqmdoc@1.313 +2 -2 + NTP_4_2_8 + + ntpq/ntpq.html@1.153 +2 -2 + NTP_4_2_8 + + ntpq/ntpq.man.in@1.313 +3 -3 + NTP_4_2_8 + + ntpq/ntpq.mdoc.in@1.313 +2 -2 + NTP_4_2_8 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.481 +2 -2 + NTP_4_2_8 + + ntpsnmpd/ntpsnmpd-opts.c@1.499 +68 -68 + NTP_4_2_8 + + ntpsnmpd/ntpsnmpd-opts.h@1.498 +3 -3 + NTP_4_2_8 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.310 +3 -3 + NTP_4_2_8 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.310 +2 -2 + NTP_4_2_8 + + ntpsnmpd/ntpsnmpd.html@1.151 +1 -1 + NTP_4_2_8 + + ntpsnmpd/ntpsnmpd.man.in@1.310 +3 -3 + NTP_4_2_8 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.310 +2 -2 + NTP_4_2_8 + + packageinfo.sh@1.493 +1 -1 + NTP_4_2_8 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.72 +3 -3 + NTP_4_2_8 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.72 +2 -2 + NTP_4_2_8 + + scripts/calc_tickadj/calc_tickadj.html@1.74 +1 -1 + NTP_4_2_8 + + scripts/calc_tickadj/calc_tickadj.man.in@1.71 +3 -3 + NTP_4_2_8 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.72 +2 -2 + NTP_4_2_8 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.76 +1 -1 + NTP_4_2_8 + + scripts/invoke-plot_summary.texi@1.93 +2 -2 + NTP_4_2_8 + + scripts/invoke-summary.texi@1.93 +2 -2 + NTP_4_2_8 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.302 +2 -2 + NTP_4_2_8 + + scripts/ntp-wait/ntp-wait-opts@1.38 +2 -2 + NTP_4_2_8 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.300 +3 -3 + NTP_4_2_8 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.300 +2 -2 + NTP_4_2_8 + + scripts/ntp-wait/ntp-wait.html@1.319 +2 -2 + NTP_4_2_8 + + scripts/ntp-wait/ntp-wait.man.in@1.300 +3 -3 + NTP_4_2_8 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.300 +2 -2 + NTP_4_2_8 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.91 +2 -2 + NTP_4_2_8 + + scripts/ntpsweep/ntpsweep-opts@1.40 +2 -2 + NTP_4_2_8 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.79 +3 -3 + NTP_4_2_8 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.79 +2 -2 + NTP_4_2_8 + + scripts/ntpsweep/ntpsweep.html@1.92 +2 -2 + NTP_4_2_8 + + scripts/ntpsweep/ntpsweep.man.in@1.79 +3 -3 + NTP_4_2_8 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.80 +2 -2 + NTP_4_2_8 + + scripts/ntptrace/invoke-ntptrace.texi@1.91 +2 -2 + NTP_4_2_8 + + scripts/ntptrace/ntptrace-opts@1.40 +2 -2 + NTP_4_2_8 + + scripts/ntptrace/ntptrace.1ntptraceman@1.79 +3 -3 + NTP_4_2_8 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.79 +2 -2 + NTP_4_2_8 + + scripts/ntptrace/ntptrace.html@1.92 +2 -2 + NTP_4_2_8 + + scripts/ntptrace/ntptrace.man.in@1.79 +3 -3 + NTP_4_2_8 + + scripts/ntptrace/ntptrace.mdoc.in@1.80 +2 -2 + NTP_4_2_8 + + scripts/plot_summary-opts@1.40 +2 -2 + NTP_4_2_8 + + scripts/plot_summary.1plot_summaryman@1.91 +3 -3 + NTP_4_2_8 + + scripts/plot_summary.1plot_summarymdoc@1.91 +2 -2 + NTP_4_2_8 + + scripts/plot_summary.html@1.94 +2 -2 + NTP_4_2_8 + + scripts/plot_summary.man.in@1.91 +3 -3 + NTP_4_2_8 + + scripts/plot_summary.mdoc.in@1.91 +2 -2 + NTP_4_2_8 + + scripts/summary-opts@1.40 +2 -2 + NTP_4_2_8 + + scripts/summary.1summaryman@1.91 +3 -3 + NTP_4_2_8 + + scripts/summary.1summarymdoc@1.91 +2 -2 + NTP_4_2_8 + + scripts/summary.html@1.94 +2 -2 + NTP_4_2_8 + + scripts/summary.man.in@1.91 +3 -3 + NTP_4_2_8 + + scripts/summary.mdoc.in@1.91 +2 -2 + NTP_4_2_8 + + sntp/invoke-sntp.texi@1.478 +2 -2 + NTP_4_2_8 + + sntp/sntp-opts.c@1.496 +159 -159 + NTP_4_2_8 + + sntp/sntp-opts.h@1.495 +3 -3 + NTP_4_2_8 + + sntp/sntp.1sntpman@1.313 +3 -3 + NTP_4_2_8 + + sntp/sntp.1sntpmdoc@1.313 +2 -2 + NTP_4_2_8 + + sntp/sntp.html@1.493 +2 -2 + NTP_4_2_8 + + sntp/sntp.man.in@1.313 +3 -3 + NTP_4_2_8 + + sntp/sntp.mdoc.in@1.313 +2 -2 + NTP_4_2_8 + + util/invoke-ntp-keygen.texi@1.482 +2 -2 + NTP_4_2_8 + + util/ntp-keygen-opts.c@1.499 +173 -173 + NTP_4_2_8 + + util/ntp-keygen-opts.h@1.498 +3 -3 + NTP_4_2_8 + + util/ntp-keygen.1ntp-keygenman@1.310 +3 -3 + NTP_4_2_8 + + util/ntp-keygen.1ntp-keygenmdoc@1.310 +2 -2 + NTP_4_2_8 + + util/ntp-keygen.html@1.157 +2 -2 + NTP_4_2_8 + + util/ntp-keygen.man.in@1.310 +3 -3 + NTP_4_2_8 + + util/ntp-keygen.mdoc.in@1.310 +2 -2 + NTP_4_2_8 + +ChangeSet@1.3265, 2014-12-19 05:55:30-05:00, stenn@deacon.udel.edu + ntp-4.2.8 + + ChangeLog@1.1592 +2 -0 + ntp-4.2.8 + + packageinfo.sh@1.492 +4 -4 + ntp-4.2.8 + +ChangeSet@1.3264, 2014-12-19 04:43:15-05:00, stenn@deacon.udel.edu + Disable Sec 2672 interim fix for now + + ntpd/ntp_io.c@1.396 +3 -0 + Disable Sec 2672 interim fix for now + +ChangeSet@1.3263, 2014-12-19 04:41:40-05:00, stenn@deacon.udel.edu + cleanup + + ChangeLog@1.1591 +0 -2 + cleanup + +ChangeSet@1.3245.1.7, 2014-12-19 08:05:17+00:00, stenn@psp-deb1.ntp.org + NEWS file for 4.2.8 + + NEWS@1.128 +136 -5 + NEWS file for 4.2.8 + +ChangeSet@1.3245.1.6, 2014-12-18 23:01:06-05:00, stenn@deacon.udel.edu + [Sec 730] Increase RSA_generate_key modulus + + ChangeLog@1.1579.1.5 +1 -0 + [Sec 730] Increase RSA_generate_key modulus + + util/ntp-keygen.c@1.97.1.1 +2 -2 + [Sec 730] Increase RSA_generate_key modulus + +ChangeSet@1.3245.1.5, 2014-12-18 21:42:38-05:00, stenn@deacon.udel.edu + [Bug 2691] Wrong variable name in refclock_ripencc.c + + ChangeLog@1.1579.1.4 +1 -0 + [Bug 2691] Wrong variable name in refclock_ripencc.c + + ntpd/refclock_ripencc.c@1.18 +1 -1 + [Bug 2691] Wrong variable name in refclock_ripencc.c + +ChangeSet@1.3260, 2014-12-18 13:14:59+00:00, stenn@psp-deb1.ntp.org + [Sec 2671] vallen in extension fields are not validated + + ChangeLog@1.1589 +1 -0 + [Sec 2671] vallen in extension fields are not validated + + ntpd/ntp_proto.c@1.352 +9 -1 + [Sec 2671] vallen in extension fields are not validated + +ChangeSet@1.3259, 2014-12-18 13:11:35+00:00, stenn@psp-deb1.ntp.org + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs: debug output tweaking + + ntpd/ntp_io.c@1.395 +6 -2 + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs: debug output tweaking + +ChangeSet@1.3256.1.1, 2014-12-18 10:08:38+00:00, stenn@psp-deb1.ntp.org + Comment cleanup + + ntpd/ntp_crypto.c@1.170 +1 -0 + Comment cleanup + +ChangeSet@1.3245.1.4, 2014-12-18 09:42:02+00:00, stenn@deacon.udel.edu + NTP_4_2_7P486_RC + TAG: NTP_4_2_7P486_RC + + ChangeLog@1.1579.1.3 +1 -0 + NTP_4_2_7P486_RC + + ntpd/invoke-ntp.conf.texi@1.167 +1 -1 + NTP_4_2_7P486_RC + + ntpd/invoke-ntp.keys.texi@1.164 +1 -1 + NTP_4_2_7P486_RC + + ntpd/invoke-ntpd.texi@1.480 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntp.conf.5man@1.201 +3 -3 + NTP_4_2_7P486_RC + + ntpd/ntp.conf.5mdoc@1.201 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntp.conf.html@1.160 +1 -1 + NTP_4_2_7P486_RC + + ntpd/ntp.conf.man.in@1.201 +3 -3 + NTP_4_2_7P486_RC + + ntpd/ntp.conf.mdoc.in@1.201 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntp.keys.5man@1.198 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntp.keys.5mdoc@1.198 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntp.keys.html@1.161 +1 -1 + NTP_4_2_7P486_RC + + ntpd/ntp.keys.man.in@1.198 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntp.keys.mdoc.in@1.198 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntpd-opts.c@1.501 +7 -7 + NTP_4_2_7P486_RC + + ntpd/ntpd-opts.h@1.500 +3 -3 + NTP_4_2_7P486_RC + + ntpd/ntpd.1ntpdman@1.309 +3 -3 + NTP_4_2_7P486_RC + + ntpd/ntpd.1ntpdmdoc@1.309 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntpd.html@1.155 +2 -2 + NTP_4_2_7P486_RC + + ntpd/ntpd.man.in@1.309 +3 -3 + NTP_4_2_7P486_RC + + ntpd/ntpd.mdoc.in@1.309 +2 -2 + NTP_4_2_7P486_RC + + ntpdc/invoke-ntpdc.texi@1.478 +2 -2 + NTP_4_2_7P486_RC + + ntpdc/ntpdc-opts.c@1.496 +7 -7 + NTP_4_2_7P486_RC + + ntpdc/ntpdc-opts.h@1.495 +3 -3 + NTP_4_2_7P486_RC + + ntpdc/ntpdc.1ntpdcman@1.309 +3 -3 + NTP_4_2_7P486_RC + + ntpdc/ntpdc.1ntpdcmdoc@1.309 +2 -2 + NTP_4_2_7P486_RC + + ntpdc/ntpdc.html@1.322 +2 -2 + NTP_4_2_7P486_RC + + ntpdc/ntpdc.man.in@1.309 +3 -3 + NTP_4_2_7P486_RC + + ntpdc/ntpdc.mdoc.in@1.309 +2 -2 + NTP_4_2_7P486_RC + + ntpq/invoke-ntpq.texi@1.484 +2 -2 + NTP_4_2_7P486_RC + + ntpq/ntpq-opts.c@1.501 +7 -7 + NTP_4_2_7P486_RC + + ntpq/ntpq-opts.h@1.499 +3 -3 + NTP_4_2_7P486_RC + + ntpq/ntpq.1ntpqman@1.312 +3 -3 + NTP_4_2_7P486_RC + + ntpq/ntpq.1ntpqmdoc@1.312 +2 -2 + NTP_4_2_7P486_RC + + ntpq/ntpq.html@1.152 +2 -2 + NTP_4_2_7P486_RC + + ntpq/ntpq.man.in@1.312 +3 -3 + NTP_4_2_7P486_RC + + ntpq/ntpq.mdoc.in@1.312 +2 -2 + NTP_4_2_7P486_RC + + ntpsnmpd/invoke-ntpsnmpd.texi@1.480 +2 -2 + NTP_4_2_7P486_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.498 +7 -7 + NTP_4_2_7P486_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.497 +3 -3 + NTP_4_2_7P486_RC + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.309 +3 -3 + NTP_4_2_7P486_RC + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.309 +2 -2 + NTP_4_2_7P486_RC + + ntpsnmpd/ntpsnmpd.html@1.150 +1 -1 + NTP_4_2_7P486_RC + + ntpsnmpd/ntpsnmpd.man.in@1.309 +3 -3 + NTP_4_2_7P486_RC + + ntpsnmpd/ntpsnmpd.mdoc.in@1.309 +2 -2 + NTP_4_2_7P486_RC + + packageinfo.sh@1.491 +1 -1 + NTP_4_2_7P486_RC + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.71 +3 -3 + NTP_4_2_7P486_RC + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.71 +2 -2 + NTP_4_2_7P486_RC + + scripts/calc_tickadj/calc_tickadj.html@1.73 +1 -1 + NTP_4_2_7P486_RC + + scripts/calc_tickadj/calc_tickadj.man.in@1.70 +3 -3 + NTP_4_2_7P486_RC + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.71 +2 -2 + NTP_4_2_7P486_RC + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.75 +1 -1 + NTP_4_2_7P486_RC + + scripts/invoke-plot_summary.texi@1.92 +2 -2 + NTP_4_2_7P486_RC + + scripts/invoke-summary.texi@1.92 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntp-wait/invoke-ntp-wait.texi@1.301 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntp-wait/ntp-wait-opts@1.37 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.299 +3 -3 + NTP_4_2_7P486_RC + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.299 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntp-wait/ntp-wait.html@1.318 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntp-wait/ntp-wait.man.in@1.299 +3 -3 + NTP_4_2_7P486_RC + + scripts/ntp-wait/ntp-wait.mdoc.in@1.299 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntpsweep/invoke-ntpsweep.texi@1.90 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntpsweep/ntpsweep-opts@1.39 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.78 +3 -3 + NTP_4_2_7P486_RC + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.78 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntpsweep/ntpsweep.html@1.91 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntpsweep/ntpsweep.man.in@1.78 +3 -3 + NTP_4_2_7P486_RC + + scripts/ntpsweep/ntpsweep.mdoc.in@1.79 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntptrace/invoke-ntptrace.texi@1.90 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntptrace/ntptrace-opts@1.39 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntptrace/ntptrace.1ntptraceman@1.78 +3 -3 + NTP_4_2_7P486_RC + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.78 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntptrace/ntptrace.html@1.91 +2 -2 + NTP_4_2_7P486_RC + + scripts/ntptrace/ntptrace.man.in@1.78 +3 -3 + NTP_4_2_7P486_RC + + scripts/ntptrace/ntptrace.mdoc.in@1.79 +2 -2 + NTP_4_2_7P486_RC + + scripts/plot_summary-opts@1.39 +2 -2 + NTP_4_2_7P486_RC + + scripts/plot_summary.1plot_summaryman@1.90 +3 -3 + NTP_4_2_7P486_RC + + scripts/plot_summary.1plot_summarymdoc@1.90 +2 -2 + NTP_4_2_7P486_RC + + scripts/plot_summary.html@1.93 +2 -2 + NTP_4_2_7P486_RC + + scripts/plot_summary.man.in@1.90 +3 -3 + NTP_4_2_7P486_RC + + scripts/plot_summary.mdoc.in@1.90 +2 -2 + NTP_4_2_7P486_RC + + scripts/summary-opts@1.39 +2 -2 + NTP_4_2_7P486_RC + + scripts/summary.1summaryman@1.90 +3 -3 + NTP_4_2_7P486_RC + + scripts/summary.1summarymdoc@1.90 +2 -2 + NTP_4_2_7P486_RC + + scripts/summary.html@1.93 +2 -2 + NTP_4_2_7P486_RC + + scripts/summary.man.in@1.90 +3 -3 + NTP_4_2_7P486_RC + + scripts/summary.mdoc.in@1.90 +2 -2 + NTP_4_2_7P486_RC + + sntp/invoke-sntp.texi@1.477 +2 -2 + NTP_4_2_7P486_RC + + sntp/sntp-opts.c@1.495 +7 -7 + NTP_4_2_7P486_RC + + sntp/sntp-opts.h@1.494 +3 -3 + NTP_4_2_7P486_RC + + sntp/sntp.1sntpman@1.312 +3 -3 + NTP_4_2_7P486_RC + + sntp/sntp.1sntpmdoc@1.312 +2 -2 + NTP_4_2_7P486_RC + + sntp/sntp.html@1.492 +2 -2 + NTP_4_2_7P486_RC + + sntp/sntp.man.in@1.312 +3 -3 + NTP_4_2_7P486_RC + + sntp/sntp.mdoc.in@1.312 +2 -2 + NTP_4_2_7P486_RC + + util/invoke-ntp-keygen.texi@1.481 +2 -2 + NTP_4_2_7P486_RC + + util/ntp-keygen-opts.c@1.498 +7 -7 + NTP_4_2_7P486_RC + + util/ntp-keygen-opts.h@1.497 +3 -3 + NTP_4_2_7P486_RC + + util/ntp-keygen.1ntp-keygenman@1.309 +3 -3 + NTP_4_2_7P486_RC + + util/ntp-keygen.1ntp-keygenmdoc@1.309 +2 -2 + NTP_4_2_7P486_RC + + util/ntp-keygen.html@1.156 +2 -2 + NTP_4_2_7P486_RC + + util/ntp-keygen.man.in@1.309 +3 -3 + NTP_4_2_7P486_RC + + util/ntp-keygen.mdoc.in@1.309 +2 -2 + NTP_4_2_7P486_RC + +ChangeSet@1.3255, 2014-12-18 01:18:29+00:00, stenn@psp-deb1.ntp.org + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs + + ChangeLog@1.1586 +1 -0 + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs + + ntpd/ntp_io.c@1.394 +20 -0 + [Sec 2672] On some OSes ::1 can be spoofed, bypassing source IP ACLs + +ChangeSet@1.3254, 2014-12-18 01:17:02+00:00, stenn@psp-deb1.ntp.org + ntp_io.c lint removal + + ntpd/ntp_io.c@1.393 +4 -1 + lint removal + +ChangeSet@1.3245.1.3, 2014-12-16 04:59:54-05:00, murray@pogo.udel.edu + refclock_hpgps.c: + Fix typo. + + ntpd/refclock_hpgps.c@1.16 +1 -1 + Fix typo. + +ChangeSet@1.3245.1.2, 2014-12-16 03:36:46-05:00, murray@pogo.udel.edu + refclock_hpgps.c, ChangeLog: + Fix for bug 2687: RefClock 26/hpgps doesn't work at default line speed + + ChangeLog@1.1579.1.2 +1 -0 + Fix for bug 2687: RefClock 26/hpgps doesn't work at default line speed + + ntpd/refclock_hpgps.c@1.15 +6 -3 + Fix for bug 2687: RefClock 26/hpgps doesn't work at default line speed + +ChangeSet@1.3253, 2014-12-15 13:12:45+00:00, stenn@psp-deb1.ntp.org + Use finer-grained config.cache files for our configure runs + + build@1.47 +2 -2 + Use finer-grained config.cache files for our configure runs + +ChangeSet@1.3252, 2014-12-15 05:40:20+00:00, stenn@psp-deb1.ntp.org + Quiet some debug output + + sntp/m4/ntp_crypto_rand.m4@1.2 +1 -1 + Quiet some debug output + +ChangeSet@1.3251, 2014-12-14 16:12:13+00:00, stenn@psp-deb1.ntp.org + [Sec 2666] Use cryptographic random numbers for md5 key generation + + ChangeLog@1.1585 +1 -0 + [Sec 2666] Use cryptographic random numbers for md5 key generation + + configure.ac@1.578 +2 -0 + [Sec 2666] Use cryptographic random numbers for md5 key generation + + include/ntp_random.h@1.3 +3 -0 + [Sec 2666] Use cryptographic random numbers for md5 key generation + + libntp/Makefile.am@1.75 +2 -1 + [Sec 2666] Use cryptographic random numbers for md5 key generation + + libntp/ntp_crypto_rnd.c@1.1 +96 -0 + BitKeeper file /home/stenn/ntp-dev-sec-2666/libntp/ntp_crypto_rnd.c + + libntp/ntp_crypto_rnd.c@1.0 +0 -0 + + sntp/m4/ntp_crypto_rand.m4@1.1 +53 -0 + BitKeeper file /home/stenn/ntp-dev-sec-2666/sntp/m4/ntp_crypto_rand.m4 + + sntp/m4/ntp_crypto_rand.m4@1.0 +0 -0 + + util/ntp-keygen.c@1.98 +10 -2 + [Sec 2666] Use cryptographic random numbers for md5 key generation + +ChangeSet@1.3245.1.1, 2014-12-12 11:58:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P485_RC + TAG: NTP_4_2_7P485_RC + + ChangeLog@1.1579.1.1 +1 -0 + NTP_4_2_7P485_RC + + ntpd/invoke-ntp.conf.texi@1.166 +1 -1 + NTP_4_2_7P485_RC + + ntpd/invoke-ntp.keys.texi@1.163 +1 -1 + NTP_4_2_7P485_RC + + ntpd/invoke-ntpd.texi@1.479 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntp.conf.5man@1.200 +3 -3 + NTP_4_2_7P485_RC + + ntpd/ntp.conf.5mdoc@1.200 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntp.conf.html@1.159 +1 -1 + NTP_4_2_7P485_RC + + ntpd/ntp.conf.man.in@1.200 +3 -3 + NTP_4_2_7P485_RC + + ntpd/ntp.conf.mdoc.in@1.200 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntp.keys.5man@1.197 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntp.keys.5mdoc@1.197 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntp.keys.html@1.160 +1 -1 + NTP_4_2_7P485_RC + + ntpd/ntp.keys.man.in@1.197 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntp.keys.mdoc.in@1.197 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntpd-opts.c@1.500 +7 -7 + NTP_4_2_7P485_RC + + ntpd/ntpd-opts.h@1.499 +3 -3 + NTP_4_2_7P485_RC + + ntpd/ntpd.1ntpdman@1.308 +3 -3 + NTP_4_2_7P485_RC + + ntpd/ntpd.1ntpdmdoc@1.308 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntpd.html@1.154 +2 -2 + NTP_4_2_7P485_RC + + ntpd/ntpd.man.in@1.308 +3 -3 + NTP_4_2_7P485_RC + + ntpd/ntpd.mdoc.in@1.308 +2 -2 + NTP_4_2_7P485_RC + + ntpdc/invoke-ntpdc.texi@1.477 +2 -2 + NTP_4_2_7P485_RC + + ntpdc/ntpdc-opts.c@1.495 +7 -7 + NTP_4_2_7P485_RC + + ntpdc/ntpdc-opts.h@1.494 +3 -3 + NTP_4_2_7P485_RC + + ntpdc/ntpdc.1ntpdcman@1.308 +3 -3 + NTP_4_2_7P485_RC + + ntpdc/ntpdc.1ntpdcmdoc@1.308 +2 -2 + NTP_4_2_7P485_RC + + ntpdc/ntpdc.html@1.321 +2 -2 + NTP_4_2_7P485_RC + + ntpdc/ntpdc.man.in@1.308 +3 -3 + NTP_4_2_7P485_RC + + ntpdc/ntpdc.mdoc.in@1.308 +2 -2 + NTP_4_2_7P485_RC + + ntpq/invoke-ntpq.texi@1.483 +2 -2 + NTP_4_2_7P485_RC + + ntpq/ntpq-opts.c@1.500 +7 -7 + NTP_4_2_7P485_RC + + ntpq/ntpq-opts.h@1.498 +3 -3 + NTP_4_2_7P485_RC + + ntpq/ntpq.1ntpqman@1.311 +3 -3 + NTP_4_2_7P485_RC + + ntpq/ntpq.1ntpqmdoc@1.311 +2 -2 + NTP_4_2_7P485_RC + + ntpq/ntpq.html@1.151 +2 -2 + NTP_4_2_7P485_RC + + ntpq/ntpq.man.in@1.311 +3 -3 + NTP_4_2_7P485_RC + + ntpq/ntpq.mdoc.in@1.311 +2 -2 + NTP_4_2_7P485_RC + + ntpsnmpd/invoke-ntpsnmpd.texi@1.479 +2 -2 + NTP_4_2_7P485_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.497 +7 -7 + NTP_4_2_7P485_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.496 +3 -3 + NTP_4_2_7P485_RC + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.308 +3 -3 + NTP_4_2_7P485_RC + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.308 +2 -2 + NTP_4_2_7P485_RC + + ntpsnmpd/ntpsnmpd.html@1.149 +1 -1 + NTP_4_2_7P485_RC + + ntpsnmpd/ntpsnmpd.man.in@1.308 +3 -3 + NTP_4_2_7P485_RC + + ntpsnmpd/ntpsnmpd.mdoc.in@1.308 +2 -2 + NTP_4_2_7P485_RC + + packageinfo.sh@1.490 +1 -1 + NTP_4_2_7P485_RC + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.70 +3 -3 + NTP_4_2_7P485_RC + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.70 +2 -2 + NTP_4_2_7P485_RC + + scripts/calc_tickadj/calc_tickadj.html@1.72 +1 -1 + NTP_4_2_7P485_RC + + scripts/calc_tickadj/calc_tickadj.man.in@1.69 +3 -3 + NTP_4_2_7P485_RC + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.70 +2 -2 + NTP_4_2_7P485_RC + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.74 +1 -1 + NTP_4_2_7P485_RC + + scripts/invoke-plot_summary.texi@1.91 +2 -2 + NTP_4_2_7P485_RC + + scripts/invoke-summary.texi@1.91 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntp-wait/invoke-ntp-wait.texi@1.300 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntp-wait/ntp-wait-opts@1.36 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.298 +3 -3 + NTP_4_2_7P485_RC + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.298 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntp-wait/ntp-wait.html@1.317 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntp-wait/ntp-wait.man.in@1.298 +3 -3 + NTP_4_2_7P485_RC + + scripts/ntp-wait/ntp-wait.mdoc.in@1.298 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntpsweep/invoke-ntpsweep.texi@1.89 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntpsweep/ntpsweep-opts@1.38 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.77 +3 -3 + NTP_4_2_7P485_RC + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.77 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntpsweep/ntpsweep.html@1.90 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntpsweep/ntpsweep.man.in@1.77 +3 -3 + NTP_4_2_7P485_RC + + scripts/ntpsweep/ntpsweep.mdoc.in@1.78 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntptrace/invoke-ntptrace.texi@1.89 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntptrace/ntptrace-opts@1.38 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntptrace/ntptrace.1ntptraceman@1.77 +3 -3 + NTP_4_2_7P485_RC + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.77 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntptrace/ntptrace.html@1.90 +2 -2 + NTP_4_2_7P485_RC + + scripts/ntptrace/ntptrace.man.in@1.77 +3 -3 + NTP_4_2_7P485_RC + + scripts/ntptrace/ntptrace.mdoc.in@1.78 +2 -2 + NTP_4_2_7P485_RC + + scripts/plot_summary-opts@1.38 +2 -2 + NTP_4_2_7P485_RC + + scripts/plot_summary.1plot_summaryman@1.89 +3 -3 + NTP_4_2_7P485_RC + + scripts/plot_summary.1plot_summarymdoc@1.89 +2 -2 + NTP_4_2_7P485_RC + + scripts/plot_summary.html@1.92 +2 -2 + NTP_4_2_7P485_RC + + scripts/plot_summary.man.in@1.89 +3 -3 + NTP_4_2_7P485_RC + + scripts/plot_summary.mdoc.in@1.89 +2 -2 + NTP_4_2_7P485_RC + + scripts/summary-opts@1.38 +2 -2 + NTP_4_2_7P485_RC + + scripts/summary.1summaryman@1.89 +3 -3 + NTP_4_2_7P485_RC + + scripts/summary.1summarymdoc@1.89 +2 -2 + NTP_4_2_7P485_RC + + scripts/summary.html@1.92 +2 -2 + NTP_4_2_7P485_RC + + scripts/summary.man.in@1.89 +3 -3 + NTP_4_2_7P485_RC + + scripts/summary.mdoc.in@1.89 +2 -2 + NTP_4_2_7P485_RC + + sntp/invoke-sntp.texi@1.476 +2 -2 + NTP_4_2_7P485_RC + + sntp/sntp-opts.c@1.494 +7 -7 + NTP_4_2_7P485_RC + + sntp/sntp-opts.h@1.493 +3 -3 + NTP_4_2_7P485_RC + + sntp/sntp.1sntpman@1.311 +3 -3 + NTP_4_2_7P485_RC + + sntp/sntp.1sntpmdoc@1.311 +2 -2 + NTP_4_2_7P485_RC + + sntp/sntp.html@1.491 +2 -2 + NTP_4_2_7P485_RC + + sntp/sntp.man.in@1.311 +3 -3 + NTP_4_2_7P485_RC + + sntp/sntp.mdoc.in@1.311 +2 -2 + NTP_4_2_7P485_RC + + util/invoke-ntp-keygen.texi@1.480 +2 -2 + NTP_4_2_7P485_RC + + util/ntp-keygen-opts.c@1.497 +7 -7 + NTP_4_2_7P485_RC + + util/ntp-keygen-opts.h@1.496 +3 -3 + NTP_4_2_7P485_RC + + util/ntp-keygen.1ntp-keygenman@1.308 +3 -3 + NTP_4_2_7P485_RC + + util/ntp-keygen.1ntp-keygenmdoc@1.308 +2 -2 + NTP_4_2_7P485_RC + + util/ntp-keygen.html@1.155 +2 -2 + NTP_4_2_7P485_RC + + util/ntp-keygen.man.in@1.308 +3 -3 + NTP_4_2_7P485_RC + + util/ntp-keygen.mdoc.in@1.308 +2 -2 + NTP_4_2_7P485_RC + +ChangeSet@1.3249, 2014-12-12 11:24:31+00:00, stenn@psp-fb1.ntp.org + [Sec 2670] Missing return; from error clause + + ChangeLog@1.1583 +1 -0 + [Sec 2670] Missing return; from error clause + + ntpd/ntp_proto.c@1.351 +1 -0 + [Sec 2670] Missing return; from error clause + +ChangeSet@1.3248, 2014-12-12 11:19:49+00:00, stenn@psp-fb1.ntp.org + [Sec 2669] buffer overflow in configure() + + ChangeLog@1.1582 +1 -0 + [Sec 2669] buffer overflow in configure() + + ntpd/ntp_control.c@1.192 +14 -0 + [Sec 2669] buffer overflow in configure() + +ChangeSet@1.3247, 2014-12-12 11:13:55+00:00, stenn@psp-fb1.ntp.org + [Sec 2668] buffer overflow in ctl_putdata() + + ChangeLog@1.1581 +1 -0 + [Sec 2668] buffer overflow in ctl_putdata() + + ntpd/ntp_control.c@1.191 +16 -1 + [Sec 2668] buffer overflow in ctl_putdata() + +ChangeSet@1.3246, 2014-12-12 11:06:53+00:00, stenn@psp-fb1.ntp.org + [Sec 2667] buffer overflow in crypto_recv() + + ChangeLog@1.1580 +1 -0 + [Sec 2667] buffer overflow in crypto_recv() + + ntpd/ntp_crypto.c@1.169 +12 -3 + [Sec 2667] buffer overflow in crypto_recv() + +ChangeSet@1.3245, 2014-12-12 08:49:58+00:00, stenn@psp-fb1.ntp.org + [Bug 2686] refclock_gpsdjson needs strtoll(), which is not always present + + ChangeLog@1.1579 +1 -0 + [Bug 2686] refclock_gpsdjson needs strtoll(), which is not always present + + configure.ac@1.577 +5 -1 + [Bug 2686] refclock_gpsdjson needs strtoll(), which is not always present + +ChangeSet@1.3244, 2014-12-11 12:13:16+00:00, stenn@deacon.udel.edu + NTP_4_2_7P484_RC + TAG: NTP_4_2_7P484_RC + + ChangeLog@1.1578 +1 -0 + NTP_4_2_7P484_RC + + ntpd/invoke-ntp.conf.texi@1.165 +1 -1 + NTP_4_2_7P484_RC + + ntpd/invoke-ntp.keys.texi@1.162 +1 -1 + NTP_4_2_7P484_RC + + ntpd/invoke-ntpd.texi@1.478 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntp.conf.5man@1.199 +3 -3 + NTP_4_2_7P484_RC + + ntpd/ntp.conf.5mdoc@1.199 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntp.conf.html@1.158 +1 -1 + NTP_4_2_7P484_RC + + ntpd/ntp.conf.man.in@1.199 +3 -3 + NTP_4_2_7P484_RC + + ntpd/ntp.conf.mdoc.in@1.199 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntp.keys.5man@1.196 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntp.keys.5mdoc@1.196 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntp.keys.html@1.159 +1 -1 + NTP_4_2_7P484_RC + + ntpd/ntp.keys.man.in@1.196 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntp.keys.mdoc.in@1.196 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntpd-opts.c@1.499 +239 -239 + NTP_4_2_7P484_RC + + ntpd/ntpd-opts.h@1.498 +3 -3 + NTP_4_2_7P484_RC + + ntpd/ntpd.1ntpdman@1.307 +3 -3 + NTP_4_2_7P484_RC + + ntpd/ntpd.1ntpdmdoc@1.307 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntpd.html@1.153 +2 -2 + NTP_4_2_7P484_RC + + ntpd/ntpd.man.in@1.307 +3 -3 + NTP_4_2_7P484_RC + + ntpd/ntpd.mdoc.in@1.307 +2 -2 + NTP_4_2_7P484_RC + + ntpdc/invoke-ntpdc.texi@1.476 +2 -2 + NTP_4_2_7P484_RC + + ntpdc/ntpdc-opts.c@1.494 +106 -106 + NTP_4_2_7P484_RC + + ntpdc/ntpdc-opts.h@1.493 +3 -3 + NTP_4_2_7P484_RC + + ntpdc/ntpdc.1ntpdcman@1.307 +3 -3 + NTP_4_2_7P484_RC + + ntpdc/ntpdc.1ntpdcmdoc@1.307 +2 -2 + NTP_4_2_7P484_RC + + ntpdc/ntpdc.html@1.320 +2 -2 + NTP_4_2_7P484_RC + + ntpdc/ntpdc.man.in@1.307 +3 -3 + NTP_4_2_7P484_RC + + ntpdc/ntpdc.mdoc.in@1.307 +2 -2 + NTP_4_2_7P484_RC + + ntpq/invoke-ntpq.texi@1.482 +2 -2 + NTP_4_2_7P484_RC + + ntpq/ntpq-opts.c@1.499 +105 -105 + NTP_4_2_7P484_RC + + ntpq/ntpq-opts.h@1.497 +3 -3 + NTP_4_2_7P484_RC + + ntpq/ntpq.1ntpqman@1.310 +3 -3 + NTP_4_2_7P484_RC + + ntpq/ntpq.1ntpqmdoc@1.310 +2 -2 + NTP_4_2_7P484_RC + + ntpq/ntpq.html@1.150 +2 -2 + NTP_4_2_7P484_RC + + ntpq/ntpq.man.in@1.310 +3 -3 + NTP_4_2_7P484_RC + + ntpq/ntpq.mdoc.in@1.310 +2 -2 + NTP_4_2_7P484_RC + + ntpsnmpd/invoke-ntpsnmpd.texi@1.478 +2 -2 + NTP_4_2_7P484_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.496 +67 -67 + NTP_4_2_7P484_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.495 +3 -3 + NTP_4_2_7P484_RC + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.307 +3 -3 + NTP_4_2_7P484_RC + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.307 +2 -2 + NTP_4_2_7P484_RC + + ntpsnmpd/ntpsnmpd.html@1.148 +1 -1 + NTP_4_2_7P484_RC + + ntpsnmpd/ntpsnmpd.man.in@1.307 +3 -3 + NTP_4_2_7P484_RC + + ntpsnmpd/ntpsnmpd.mdoc.in@1.307 +2 -2 + NTP_4_2_7P484_RC + + packageinfo.sh@1.489 +1 -1 + NTP_4_2_7P484_RC + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.69 +3 -3 + NTP_4_2_7P484_RC + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.69 +2 -2 + NTP_4_2_7P484_RC + + scripts/calc_tickadj/calc_tickadj.html@1.71 +1 -1 + NTP_4_2_7P484_RC + + scripts/calc_tickadj/calc_tickadj.man.in@1.68 +3 -3 + NTP_4_2_7P484_RC + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.69 +2 -2 + NTP_4_2_7P484_RC + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.73 +1 -1 + NTP_4_2_7P484_RC + + scripts/invoke-plot_summary.texi@1.90 +2 -2 + NTP_4_2_7P484_RC + + scripts/invoke-summary.texi@1.90 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntp-wait/invoke-ntp-wait.texi@1.299 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntp-wait/ntp-wait-opts@1.35 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.297 +3 -3 + NTP_4_2_7P484_RC + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.297 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntp-wait/ntp-wait.html@1.316 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntp-wait/ntp-wait.man.in@1.297 +3 -3 + NTP_4_2_7P484_RC + + scripts/ntp-wait/ntp-wait.mdoc.in@1.297 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntpsweep/invoke-ntpsweep.texi@1.88 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntpsweep/ntpsweep-opts@1.37 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.76 +3 -3 + NTP_4_2_7P484_RC + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.76 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntpsweep/ntpsweep.html@1.89 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntpsweep/ntpsweep.man.in@1.76 +3 -3 + NTP_4_2_7P484_RC + + scripts/ntpsweep/ntpsweep.mdoc.in@1.77 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntptrace/invoke-ntptrace.texi@1.88 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntptrace/ntptrace-opts@1.37 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntptrace/ntptrace.1ntptraceman@1.76 +3 -3 + NTP_4_2_7P484_RC + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.76 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntptrace/ntptrace.html@1.89 +2 -2 + NTP_4_2_7P484_RC + + scripts/ntptrace/ntptrace.man.in@1.76 +3 -3 + NTP_4_2_7P484_RC + + scripts/ntptrace/ntptrace.mdoc.in@1.77 +2 -2 + NTP_4_2_7P484_RC + + scripts/plot_summary-opts@1.37 +2 -2 + NTP_4_2_7P484_RC + + scripts/plot_summary.1plot_summaryman@1.88 +3 -3 + NTP_4_2_7P484_RC + + scripts/plot_summary.1plot_summarymdoc@1.88 +2 -2 + NTP_4_2_7P484_RC + + scripts/plot_summary.html@1.91 +2 -2 + NTP_4_2_7P484_RC + + scripts/plot_summary.man.in@1.88 +3 -3 + NTP_4_2_7P484_RC + + scripts/plot_summary.mdoc.in@1.88 +2 -2 + NTP_4_2_7P484_RC + + scripts/summary-opts@1.37 +2 -2 + NTP_4_2_7P484_RC + + scripts/summary.1summaryman@1.88 +3 -3 + NTP_4_2_7P484_RC + + scripts/summary.1summarymdoc@1.88 +2 -2 + NTP_4_2_7P484_RC + + scripts/summary.html@1.91 +2 -2 + NTP_4_2_7P484_RC + + scripts/summary.man.in@1.88 +3 -3 + NTP_4_2_7P484_RC + + scripts/summary.mdoc.in@1.88 +2 -2 + NTP_4_2_7P484_RC + + sntp/invoke-sntp.texi@1.475 +2 -2 + NTP_4_2_7P484_RC + + sntp/sntp-opts.c@1.493 +158 -158 + NTP_4_2_7P484_RC + + sntp/sntp-opts.h@1.492 +3 -3 + NTP_4_2_7P484_RC + + sntp/sntp.1sntpman@1.310 +3 -3 + NTP_4_2_7P484_RC + + sntp/sntp.1sntpmdoc@1.310 +2 -2 + NTP_4_2_7P484_RC + + sntp/sntp.html@1.490 +2 -2 + NTP_4_2_7P484_RC + + sntp/sntp.man.in@1.310 +3 -3 + NTP_4_2_7P484_RC + + sntp/sntp.mdoc.in@1.310 +2 -2 + NTP_4_2_7P484_RC + + util/invoke-ntp-keygen.texi@1.479 +2 -2 + NTP_4_2_7P484_RC + + util/ntp-keygen-opts.c@1.496 +172 -172 + NTP_4_2_7P484_RC + + util/ntp-keygen-opts.h@1.495 +3 -3 + NTP_4_2_7P484_RC + + util/ntp-keygen.1ntp-keygenman@1.307 +3 -3 + NTP_4_2_7P484_RC + + util/ntp-keygen.1ntp-keygenmdoc@1.307 +2 -2 + NTP_4_2_7P484_RC + + util/ntp-keygen.html@1.154 +2 -2 + NTP_4_2_7P484_RC + + util/ntp-keygen.man.in@1.307 +3 -3 + NTP_4_2_7P484_RC + + util/ntp-keygen.mdoc.in@1.307 +2 -2 + NTP_4_2_7P484_RC + +ChangeSet@1.3243, 2014-12-11 06:51:38-05:00, stenn@deacon.udel.edu + Start the RC cycle for 4.2.8 + + packageinfo.sh@1.488 +1 -1 + Start the RC cycle for 4.2.8 + +ChangeSet@1.3242, 2014-12-08 08:59:52+00:00, stenn@deacon.udel.edu + NTP_4_2_7P483 + TAG: NTP_4_2_7P483 + + ChangeLog@1.1577 +1 -0 + NTP_4_2_7P483 + + ntpd/invoke-ntp.conf.texi@1.164 +1 -1 + NTP_4_2_7P483 + + ntpd/invoke-ntp.keys.texi@1.161 +1 -1 + NTP_4_2_7P483 + + ntpd/invoke-ntpd.texi@1.477 +2 -2 + NTP_4_2_7P483 + + ntpd/ntp.conf.5man@1.198 +3 -3 + NTP_4_2_7P483 + + ntpd/ntp.conf.5mdoc@1.198 +2 -2 + NTP_4_2_7P483 + + ntpd/ntp.conf.html@1.157 +1 -1 + NTP_4_2_7P483 + + ntpd/ntp.conf.man.in@1.198 +3 -3 + NTP_4_2_7P483 + + ntpd/ntp.conf.mdoc.in@1.198 +2 -2 + NTP_4_2_7P483 + + ntpd/ntp.keys.5man@1.195 +2 -2 + NTP_4_2_7P483 + + ntpd/ntp.keys.5mdoc@1.195 +2 -2 + NTP_4_2_7P483 + + ntpd/ntp.keys.html@1.158 +1 -1 + NTP_4_2_7P483 + + ntpd/ntp.keys.man.in@1.195 +2 -2 + NTP_4_2_7P483 + + ntpd/ntp.keys.mdoc.in@1.195 +2 -2 + NTP_4_2_7P483 + + ntpd/ntpd-opts.c@1.498 +7 -7 + NTP_4_2_7P483 + + ntpd/ntpd-opts.h@1.497 +3 -3 + NTP_4_2_7P483 + + ntpd/ntpd.1ntpdman@1.306 +3 -3 + NTP_4_2_7P483 + + ntpd/ntpd.1ntpdmdoc@1.306 +2 -2 + NTP_4_2_7P483 + + ntpd/ntpd.html@1.152 +2 -2 + NTP_4_2_7P483 + + ntpd/ntpd.man.in@1.306 +3 -3 + NTP_4_2_7P483 + + ntpd/ntpd.mdoc.in@1.306 +2 -2 + NTP_4_2_7P483 + + ntpdc/invoke-ntpdc.texi@1.475 +2 -2 + NTP_4_2_7P483 + + ntpdc/ntpdc-opts.c@1.493 +7 -7 + NTP_4_2_7P483 + + ntpdc/ntpdc-opts.h@1.492 +3 -3 + NTP_4_2_7P483 + + ntpdc/ntpdc.1ntpdcman@1.306 +3 -3 + NTP_4_2_7P483 + + ntpdc/ntpdc.1ntpdcmdoc@1.306 +2 -2 + NTP_4_2_7P483 + + ntpdc/ntpdc.html@1.319 +2 -2 + NTP_4_2_7P483 + + ntpdc/ntpdc.man.in@1.306 +3 -3 + NTP_4_2_7P483 + + ntpdc/ntpdc.mdoc.in@1.306 +2 -2 + NTP_4_2_7P483 + + ntpq/invoke-ntpq.texi@1.481 +2 -2 + NTP_4_2_7P483 + + ntpq/ntpq-opts.c@1.498 +7 -7 + NTP_4_2_7P483 + + ntpq/ntpq-opts.h@1.496 +3 -3 + NTP_4_2_7P483 + + ntpq/ntpq.1ntpqman@1.309 +3 -3 + NTP_4_2_7P483 + + ntpq/ntpq.1ntpqmdoc@1.309 +2 -2 + NTP_4_2_7P483 + + ntpq/ntpq.html@1.149 +2 -2 + NTP_4_2_7P483 + + ntpq/ntpq.man.in@1.309 +3 -3 + NTP_4_2_7P483 + + ntpq/ntpq.mdoc.in@1.309 +2 -2 + NTP_4_2_7P483 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.477 +2 -2 + NTP_4_2_7P483 + + ntpsnmpd/ntpsnmpd-opts.c@1.495 +7 -7 + NTP_4_2_7P483 + + ntpsnmpd/ntpsnmpd-opts.h@1.494 +3 -3 + NTP_4_2_7P483 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.306 +3 -3 + NTP_4_2_7P483 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.306 +2 -2 + NTP_4_2_7P483 + + ntpsnmpd/ntpsnmpd.html@1.147 +1 -1 + NTP_4_2_7P483 + + ntpsnmpd/ntpsnmpd.man.in@1.306 +3 -3 + NTP_4_2_7P483 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.306 +2 -2 + NTP_4_2_7P483 + + packageinfo.sh@1.487 +1 -1 + NTP_4_2_7P483 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.68 +3 -3 + NTP_4_2_7P483 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.68 +2 -2 + NTP_4_2_7P483 + + scripts/calc_tickadj/calc_tickadj.html@1.70 +1 -1 + NTP_4_2_7P483 + + scripts/calc_tickadj/calc_tickadj.man.in@1.67 +3 -3 + NTP_4_2_7P483 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.68 +2 -2 + NTP_4_2_7P483 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.72 +1 -1 + NTP_4_2_7P483 + + scripts/invoke-plot_summary.texi@1.89 +2 -2 + NTP_4_2_7P483 + + scripts/invoke-summary.texi@1.89 +2 -2 + NTP_4_2_7P483 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.298 +2 -2 + NTP_4_2_7P483 + + scripts/ntp-wait/ntp-wait-opts@1.34 +2 -2 + NTP_4_2_7P483 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.296 +3 -3 + NTP_4_2_7P483 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.296 +2 -2 + NTP_4_2_7P483 + + scripts/ntp-wait/ntp-wait.html@1.315 +2 -2 + NTP_4_2_7P483 + + scripts/ntp-wait/ntp-wait.man.in@1.296 +3 -3 + NTP_4_2_7P483 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.296 +2 -2 + NTP_4_2_7P483 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.87 +2 -2 + NTP_4_2_7P483 + + scripts/ntpsweep/ntpsweep-opts@1.36 +2 -2 + NTP_4_2_7P483 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.75 +3 -3 + NTP_4_2_7P483 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.75 +2 -2 + NTP_4_2_7P483 + + scripts/ntpsweep/ntpsweep.html@1.88 +2 -2 + NTP_4_2_7P483 + + scripts/ntpsweep/ntpsweep.man.in@1.75 +3 -3 + NTP_4_2_7P483 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.76 +2 -2 + NTP_4_2_7P483 + + scripts/ntptrace/invoke-ntptrace.texi@1.87 +2 -2 + NTP_4_2_7P483 + + scripts/ntptrace/ntptrace-opts@1.36 +2 -2 + NTP_4_2_7P483 + + scripts/ntptrace/ntptrace.1ntptraceman@1.75 +3 -3 + NTP_4_2_7P483 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.75 +2 -2 + NTP_4_2_7P483 + + scripts/ntptrace/ntptrace.html@1.88 +2 -2 + NTP_4_2_7P483 + + scripts/ntptrace/ntptrace.man.in@1.75 +3 -3 + NTP_4_2_7P483 + + scripts/ntptrace/ntptrace.mdoc.in@1.76 +2 -2 + NTP_4_2_7P483 + + scripts/plot_summary-opts@1.36 +2 -2 + NTP_4_2_7P483 + + scripts/plot_summary.1plot_summaryman@1.87 +3 -3 + NTP_4_2_7P483 + + scripts/plot_summary.1plot_summarymdoc@1.87 +2 -2 + NTP_4_2_7P483 + + scripts/plot_summary.html@1.90 +2 -2 + NTP_4_2_7P483 + + scripts/plot_summary.man.in@1.87 +3 -3 + NTP_4_2_7P483 + + scripts/plot_summary.mdoc.in@1.87 +2 -2 + NTP_4_2_7P483 + + scripts/summary-opts@1.36 +2 -2 + NTP_4_2_7P483 + + scripts/summary.1summaryman@1.87 +3 -3 + NTP_4_2_7P483 + + scripts/summary.1summarymdoc@1.87 +2 -2 + NTP_4_2_7P483 + + scripts/summary.html@1.90 +2 -2 + NTP_4_2_7P483 + + scripts/summary.man.in@1.87 +3 -3 + NTP_4_2_7P483 + + scripts/summary.mdoc.in@1.87 +2 -2 + NTP_4_2_7P483 + + sntp/invoke-sntp.texi@1.474 +4 -3 + NTP_4_2_7P483 + + sntp/sntp-opts.c@1.492 +9 -8 + NTP_4_2_7P483 + + sntp/sntp-opts.h@1.491 +3 -3 + NTP_4_2_7P483 + + sntp/sntp.1sntpman@1.309 +5 -4 + NTP_4_2_7P483 + + sntp/sntp.1sntpmdoc@1.309 +4 -3 + NTP_4_2_7P483 + + sntp/sntp.html@1.489 +4 -3 + NTP_4_2_7P483 + + sntp/sntp.man.in@1.309 +5 -4 + NTP_4_2_7P483 + + sntp/sntp.mdoc.in@1.309 +4 -3 + NTP_4_2_7P483 + + util/invoke-ntp-keygen.texi@1.478 +2 -2 + NTP_4_2_7P483 + + util/ntp-keygen-opts.c@1.495 +7 -7 + NTP_4_2_7P483 + + util/ntp-keygen-opts.h@1.494 +3 -3 + NTP_4_2_7P483 + + util/ntp-keygen.1ntp-keygenman@1.306 +3 -3 + NTP_4_2_7P483 + + util/ntp-keygen.1ntp-keygenmdoc@1.306 +2 -2 + NTP_4_2_7P483 + + util/ntp-keygen.html@1.153 +2 -2 + NTP_4_2_7P483 + + util/ntp-keygen.man.in@1.306 +3 -3 + NTP_4_2_7P483 + + util/ntp-keygen.mdoc.in@1.306 +2 -2 + NTP_4_2_7P483 + +ChangeSet@1.3241, 2014-12-07 11:30:07+00:00, stenn@psp-fb1.ntp.org + [Bug 2685] Better document the KOD file for sntp + + ChangeLog@1.1576 +1 -0 + [Bug 2685] Better document the KOD file for sntp + + html/sntp.html@1.11 +3 -2 + [Bug 2685] Better document the KOD file for sntp + + sntp/sntp-opts.def@1.45 +2 -1 + [Bug 2685] Better document the KOD file for sntp + +ChangeSet@1.3240, 2014-12-02 08:59:55+00:00, stenn@deacon.udel.edu + NTP_4_2_7P482 + TAG: NTP_4_2_7P482 + + ChangeLog@1.1575 +1 -0 + NTP_4_2_7P482 + + ntpd/invoke-ntp.conf.texi@1.163 +1 -1 + NTP_4_2_7P482 + + ntpd/invoke-ntp.keys.texi@1.160 +1 -1 + NTP_4_2_7P482 + + ntpd/invoke-ntpd.texi@1.476 +2 -2 + NTP_4_2_7P482 + + ntpd/ntp.conf.5man@1.197 +3 -3 + NTP_4_2_7P482 + + ntpd/ntp.conf.5mdoc@1.197 +2 -2 + NTP_4_2_7P482 + + ntpd/ntp.conf.html@1.156 +1 -1 + NTP_4_2_7P482 + + ntpd/ntp.conf.man.in@1.197 +3 -3 + NTP_4_2_7P482 + + ntpd/ntp.conf.mdoc.in@1.197 +2 -2 + NTP_4_2_7P482 + + ntpd/ntp.keys.5man@1.194 +2 -2 + NTP_4_2_7P482 + + ntpd/ntp.keys.5mdoc@1.194 +2 -2 + NTP_4_2_7P482 + + ntpd/ntp.keys.html@1.157 +1 -1 + NTP_4_2_7P482 + + ntpd/ntp.keys.man.in@1.194 +2 -2 + NTP_4_2_7P482 + + ntpd/ntp.keys.mdoc.in@1.194 +2 -2 + NTP_4_2_7P482 + + ntpd/ntpd-opts.c@1.497 +7 -7 + NTP_4_2_7P482 + + ntpd/ntpd-opts.h@1.496 +3 -3 + NTP_4_2_7P482 + + ntpd/ntpd.1ntpdman@1.305 +3 -3 + NTP_4_2_7P482 + + ntpd/ntpd.1ntpdmdoc@1.305 +2 -2 + NTP_4_2_7P482 + + ntpd/ntpd.html@1.151 +2 -2 + NTP_4_2_7P482 + + ntpd/ntpd.man.in@1.305 +3 -3 + NTP_4_2_7P482 + + ntpd/ntpd.mdoc.in@1.305 +2 -2 + NTP_4_2_7P482 + + ntpdc/invoke-ntpdc.texi@1.474 +2 -2 + NTP_4_2_7P482 + + ntpdc/ntpdc-opts.c@1.492 +7 -7 + NTP_4_2_7P482 + + ntpdc/ntpdc-opts.h@1.491 +3 -3 + NTP_4_2_7P482 + + ntpdc/ntpdc.1ntpdcman@1.305 +3 -3 + NTP_4_2_7P482 + + ntpdc/ntpdc.1ntpdcmdoc@1.305 +2 -2 + NTP_4_2_7P482 + + ntpdc/ntpdc.html@1.318 +2 -2 + NTP_4_2_7P482 + + ntpdc/ntpdc.man.in@1.305 +3 -3 + NTP_4_2_7P482 + + ntpdc/ntpdc.mdoc.in@1.305 +2 -2 + NTP_4_2_7P482 + + ntpq/invoke-ntpq.texi@1.480 +2 -2 + NTP_4_2_7P482 + + ntpq/ntpq-opts.c@1.497 +7 -7 + NTP_4_2_7P482 + + ntpq/ntpq-opts.h@1.495 +3 -3 + NTP_4_2_7P482 + + ntpq/ntpq.1ntpqman@1.308 +3 -3 + NTP_4_2_7P482 + + ntpq/ntpq.1ntpqmdoc@1.308 +2 -2 + NTP_4_2_7P482 + + ntpq/ntpq.html@1.148 +2 -2 + NTP_4_2_7P482 + + ntpq/ntpq.man.in@1.308 +3 -3 + NTP_4_2_7P482 + + ntpq/ntpq.mdoc.in@1.308 +2 -2 + NTP_4_2_7P482 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.476 +2 -2 + NTP_4_2_7P482 + + ntpsnmpd/ntpsnmpd-opts.c@1.494 +7 -7 + NTP_4_2_7P482 + + ntpsnmpd/ntpsnmpd-opts.h@1.493 +3 -3 + NTP_4_2_7P482 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.305 +3 -3 + NTP_4_2_7P482 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.305 +2 -2 + NTP_4_2_7P482 + + ntpsnmpd/ntpsnmpd.html@1.146 +1 -1 + NTP_4_2_7P482 + + ntpsnmpd/ntpsnmpd.man.in@1.305 +3 -3 + NTP_4_2_7P482 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.305 +2 -2 + NTP_4_2_7P482 + + packageinfo.sh@1.486 +1 -1 + NTP_4_2_7P482 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.67 +3 -3 + NTP_4_2_7P482 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.67 +2 -2 + NTP_4_2_7P482 + + scripts/calc_tickadj/calc_tickadj.html@1.69 +1 -1 + NTP_4_2_7P482 + + scripts/calc_tickadj/calc_tickadj.man.in@1.66 +3 -3 + NTP_4_2_7P482 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.67 +2 -2 + NTP_4_2_7P482 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.71 +1 -1 + NTP_4_2_7P482 + + scripts/invoke-plot_summary.texi@1.88 +2 -2 + NTP_4_2_7P482 + + scripts/invoke-summary.texi@1.88 +2 -2 + NTP_4_2_7P482 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.297 +2 -2 + NTP_4_2_7P482 + + scripts/ntp-wait/ntp-wait-opts@1.33 +2 -2 + NTP_4_2_7P482 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.295 +3 -3 + NTP_4_2_7P482 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.295 +2 -2 + NTP_4_2_7P482 + + scripts/ntp-wait/ntp-wait.html@1.314 +2 -2 + NTP_4_2_7P482 + + scripts/ntp-wait/ntp-wait.man.in@1.295 +3 -3 + NTP_4_2_7P482 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.295 +2 -2 + NTP_4_2_7P482 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.86 +2 -2 + NTP_4_2_7P482 + + scripts/ntpsweep/ntpsweep-opts@1.35 +2 -2 + NTP_4_2_7P482 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.74 +3 -3 + NTP_4_2_7P482 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.74 +2 -2 + NTP_4_2_7P482 + + scripts/ntpsweep/ntpsweep.html@1.87 +2 -2 + NTP_4_2_7P482 + + scripts/ntpsweep/ntpsweep.man.in@1.74 +3 -3 + NTP_4_2_7P482 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.75 +2 -2 + NTP_4_2_7P482 + + scripts/ntptrace/invoke-ntptrace.texi@1.86 +2 -2 + NTP_4_2_7P482 + + scripts/ntptrace/ntptrace-opts@1.35 +2 -2 + NTP_4_2_7P482 + + scripts/ntptrace/ntptrace.1ntptraceman@1.74 +3 -3 + NTP_4_2_7P482 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.74 +2 -2 + NTP_4_2_7P482 + + scripts/ntptrace/ntptrace.html@1.87 +2 -2 + NTP_4_2_7P482 + + scripts/ntptrace/ntptrace.man.in@1.74 +3 -3 + NTP_4_2_7P482 + + scripts/ntptrace/ntptrace.mdoc.in@1.75 +2 -2 + NTP_4_2_7P482 + + scripts/plot_summary-opts@1.35 +2 -2 + NTP_4_2_7P482 + + scripts/plot_summary.1plot_summaryman@1.86 +3 -3 + NTP_4_2_7P482 + + scripts/plot_summary.1plot_summarymdoc@1.86 +2 -2 + NTP_4_2_7P482 + + scripts/plot_summary.html@1.89 +2 -2 + NTP_4_2_7P482 + + scripts/plot_summary.man.in@1.86 +3 -3 + NTP_4_2_7P482 + + scripts/plot_summary.mdoc.in@1.86 +2 -2 + NTP_4_2_7P482 + + scripts/summary-opts@1.35 +2 -2 + NTP_4_2_7P482 + + scripts/summary.1summaryman@1.86 +3 -3 + NTP_4_2_7P482 + + scripts/summary.1summarymdoc@1.86 +2 -2 + NTP_4_2_7P482 + + scripts/summary.html@1.89 +2 -2 + NTP_4_2_7P482 + + scripts/summary.man.in@1.86 +3 -3 + NTP_4_2_7P482 + + scripts/summary.mdoc.in@1.86 +2 -2 + NTP_4_2_7P482 + + sntp/invoke-sntp.texi@1.473 +2 -2 + NTP_4_2_7P482 + + sntp/sntp-opts.c@1.491 +7 -7 + NTP_4_2_7P482 + + sntp/sntp-opts.h@1.490 +3 -3 + NTP_4_2_7P482 + + sntp/sntp.1sntpman@1.308 +3 -3 + NTP_4_2_7P482 + + sntp/sntp.1sntpmdoc@1.308 +2 -2 + NTP_4_2_7P482 + + sntp/sntp.html@1.488 +2 -2 + NTP_4_2_7P482 + + sntp/sntp.man.in@1.308 +3 -3 + NTP_4_2_7P482 + + sntp/sntp.mdoc.in@1.308 +2 -2 + NTP_4_2_7P482 + + util/invoke-ntp-keygen.texi@1.477 +2 -2 + NTP_4_2_7P482 + + util/ntp-keygen-opts.c@1.494 +7 -7 + NTP_4_2_7P482 + + util/ntp-keygen-opts.h@1.493 +3 -3 + NTP_4_2_7P482 + + util/ntp-keygen.1ntp-keygenman@1.305 +3 -3 + NTP_4_2_7P482 + + util/ntp-keygen.1ntp-keygenmdoc@1.305 +2 -2 + NTP_4_2_7P482 + + util/ntp-keygen.html@1.152 +2 -2 + NTP_4_2_7P482 + + util/ntp-keygen.man.in@1.305 +3 -3 + NTP_4_2_7P482 + + util/ntp-keygen.mdoc.in@1.305 +2 -2 + NTP_4_2_7P482 + +ChangeSet@1.3237.1.1, 2014-12-02 02:55:23+00:00, stenn@psp-fb1.ntp.org + [Bug 2641] sntp is installed in the wrong location in Solaris + + ChangeLog@1.1572.1.1 +1 -0 + [Bug 2641] sntp is installed in the wrong location in Solaris + + sntp/loc/solaris@1.6 +1 -1 + [Bug 2641] sntp is installed in the wrong location in Solaris + +ChangeSet@1.3238, 2014-12-02 00:37:46+01:00, jnperlin@hydra.(none) + [Bug 2678] nmea_control() now checks 'refclock_params()' result. + + ChangeLog@1.1573 +1 -0 + [Bug 2678] nmea_control() now checks 'refclock_params()' result. + + ntpd/refclock_nmea.c@1.75 +12 -2 + [Bug 2678] nmea_control() now checks 'refclock_params()' result. + +ChangeSet@1.3237, 2014-11-22 08:59:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P481 + TAG: NTP_4_2_7P481 + + ChangeLog@1.1572 +1 -0 + NTP_4_2_7P481 + + ntpd/invoke-ntp.conf.texi@1.162 +1 -1 + NTP_4_2_7P481 + + ntpd/invoke-ntp.keys.texi@1.159 +1 -1 + NTP_4_2_7P481 + + ntpd/invoke-ntpd.texi@1.475 +2 -2 + NTP_4_2_7P481 + + ntpd/ntp.conf.5man@1.196 +3 -3 + NTP_4_2_7P481 + + ntpd/ntp.conf.5mdoc@1.196 +2 -2 + NTP_4_2_7P481 + + ntpd/ntp.conf.html@1.155 +1 -1 + NTP_4_2_7P481 + + ntpd/ntp.conf.man.in@1.196 +3 -3 + NTP_4_2_7P481 + + ntpd/ntp.conf.mdoc.in@1.196 +2 -2 + NTP_4_2_7P481 + + ntpd/ntp.keys.5man@1.193 +2 -2 + NTP_4_2_7P481 + + ntpd/ntp.keys.5mdoc@1.193 +2 -2 + NTP_4_2_7P481 + + ntpd/ntp.keys.html@1.156 +1 -1 + NTP_4_2_7P481 + + ntpd/ntp.keys.man.in@1.193 +2 -2 + NTP_4_2_7P481 + + ntpd/ntp.keys.mdoc.in@1.193 +2 -2 + NTP_4_2_7P481 + + ntpd/ntpd-opts.c@1.496 +7 -7 + NTP_4_2_7P481 + + ntpd/ntpd-opts.h@1.495 +3 -3 + NTP_4_2_7P481 + + ntpd/ntpd.1ntpdman@1.304 +3 -3 + NTP_4_2_7P481 + + ntpd/ntpd.1ntpdmdoc@1.304 +2 -2 + NTP_4_2_7P481 + + ntpd/ntpd.html@1.150 +2 -2 + NTP_4_2_7P481 + + ntpd/ntpd.man.in@1.304 +3 -3 + NTP_4_2_7P481 + + ntpd/ntpd.mdoc.in@1.304 +2 -2 + NTP_4_2_7P481 + + ntpdc/invoke-ntpdc.texi@1.473 +2 -2 + NTP_4_2_7P481 + + ntpdc/ntpdc-opts.c@1.491 +7 -7 + NTP_4_2_7P481 + + ntpdc/ntpdc-opts.h@1.490 +3 -3 + NTP_4_2_7P481 + + ntpdc/ntpdc.1ntpdcman@1.304 +3 -3 + NTP_4_2_7P481 + + ntpdc/ntpdc.1ntpdcmdoc@1.304 +2 -2 + NTP_4_2_7P481 + + ntpdc/ntpdc.html@1.317 +2 -2 + NTP_4_2_7P481 + + ntpdc/ntpdc.man.in@1.304 +3 -3 + NTP_4_2_7P481 + + ntpdc/ntpdc.mdoc.in@1.304 +2 -2 + NTP_4_2_7P481 + + ntpq/invoke-ntpq.texi@1.479 +2 -2 + NTP_4_2_7P481 + + ntpq/ntpq-opts.c@1.496 +7 -7 + NTP_4_2_7P481 + + ntpq/ntpq-opts.h@1.494 +3 -3 + NTP_4_2_7P481 + + ntpq/ntpq.1ntpqman@1.307 +3 -3 + NTP_4_2_7P481 + + ntpq/ntpq.1ntpqmdoc@1.307 +2 -2 + NTP_4_2_7P481 + + ntpq/ntpq.html@1.147 +2 -2 + NTP_4_2_7P481 + + ntpq/ntpq.man.in@1.307 +3 -3 + NTP_4_2_7P481 + + ntpq/ntpq.mdoc.in@1.307 +2 -2 + NTP_4_2_7P481 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.475 +2 -2 + NTP_4_2_7P481 + + ntpsnmpd/ntpsnmpd-opts.c@1.493 +7 -7 + NTP_4_2_7P481 + + ntpsnmpd/ntpsnmpd-opts.h@1.492 +3 -3 + NTP_4_2_7P481 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.304 +3 -3 + NTP_4_2_7P481 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.304 +2 -2 + NTP_4_2_7P481 + + ntpsnmpd/ntpsnmpd.html@1.145 +1 -1 + NTP_4_2_7P481 + + ntpsnmpd/ntpsnmpd.man.in@1.304 +3 -3 + NTP_4_2_7P481 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.304 +2 -2 + NTP_4_2_7P481 + + packageinfo.sh@1.485 +1 -1 + NTP_4_2_7P481 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.66 +3 -3 + NTP_4_2_7P481 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.66 +2 -2 + NTP_4_2_7P481 + + scripts/calc_tickadj/calc_tickadj.html@1.68 +1 -1 + NTP_4_2_7P481 + + scripts/calc_tickadj/calc_tickadj.man.in@1.65 +3 -3 + NTP_4_2_7P481 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.66 +2 -2 + NTP_4_2_7P481 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.70 +1 -1 + NTP_4_2_7P481 + + scripts/invoke-plot_summary.texi@1.87 +2 -2 + NTP_4_2_7P481 + + scripts/invoke-summary.texi@1.87 +2 -2 + NTP_4_2_7P481 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.296 +2 -2 + NTP_4_2_7P481 + + scripts/ntp-wait/ntp-wait-opts@1.32 +2 -2 + NTP_4_2_7P481 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.294 +3 -3 + NTP_4_2_7P481 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.294 +2 -2 + NTP_4_2_7P481 + + scripts/ntp-wait/ntp-wait.html@1.313 +2 -2 + NTP_4_2_7P481 + + scripts/ntp-wait/ntp-wait.man.in@1.294 +3 -3 + NTP_4_2_7P481 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.294 +2 -2 + NTP_4_2_7P481 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.85 +2 -2 + NTP_4_2_7P481 + + scripts/ntpsweep/ntpsweep-opts@1.34 +2 -2 + NTP_4_2_7P481 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.73 +3 -3 + NTP_4_2_7P481 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.73 +2 -2 + NTP_4_2_7P481 + + scripts/ntpsweep/ntpsweep.html@1.86 +2 -2 + NTP_4_2_7P481 + + scripts/ntpsweep/ntpsweep.man.in@1.73 +3 -3 + NTP_4_2_7P481 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.74 +2 -2 + NTP_4_2_7P481 + + scripts/ntptrace/invoke-ntptrace.texi@1.85 +2 -2 + NTP_4_2_7P481 + + scripts/ntptrace/ntptrace-opts@1.34 +2 -2 + NTP_4_2_7P481 + + scripts/ntptrace/ntptrace.1ntptraceman@1.73 +3 -3 + NTP_4_2_7P481 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.73 +2 -2 + NTP_4_2_7P481 + + scripts/ntptrace/ntptrace.html@1.86 +2 -2 + NTP_4_2_7P481 + + scripts/ntptrace/ntptrace.man.in@1.73 +3 -3 + NTP_4_2_7P481 + + scripts/ntptrace/ntptrace.mdoc.in@1.74 +2 -2 + NTP_4_2_7P481 + + scripts/plot_summary-opts@1.34 +2 -2 + NTP_4_2_7P481 + + scripts/plot_summary.1plot_summaryman@1.85 +3 -3 + NTP_4_2_7P481 + + scripts/plot_summary.1plot_summarymdoc@1.85 +2 -2 + NTP_4_2_7P481 + + scripts/plot_summary.html@1.88 +2 -2 + NTP_4_2_7P481 + + scripts/plot_summary.man.in@1.85 +3 -3 + NTP_4_2_7P481 + + scripts/plot_summary.mdoc.in@1.85 +2 -2 + NTP_4_2_7P481 + + scripts/summary-opts@1.34 +2 -2 + NTP_4_2_7P481 + + scripts/summary.1summaryman@1.85 +3 -3 + NTP_4_2_7P481 + + scripts/summary.1summarymdoc@1.85 +2 -2 + NTP_4_2_7P481 + + scripts/summary.html@1.88 +2 -2 + NTP_4_2_7P481 + + scripts/summary.man.in@1.85 +3 -3 + NTP_4_2_7P481 + + scripts/summary.mdoc.in@1.85 +2 -2 + NTP_4_2_7P481 + + sntp/invoke-sntp.texi@1.472 +2 -2 + NTP_4_2_7P481 + + sntp/sntp-opts.c@1.490 +7 -7 + NTP_4_2_7P481 + + sntp/sntp-opts.h@1.489 +3 -3 + NTP_4_2_7P481 + + sntp/sntp.1sntpman@1.307 +3 -3 + NTP_4_2_7P481 + + sntp/sntp.1sntpmdoc@1.307 +2 -2 + NTP_4_2_7P481 + + sntp/sntp.html@1.487 +2 -2 + NTP_4_2_7P481 + + sntp/sntp.man.in@1.307 +3 -3 + NTP_4_2_7P481 + + sntp/sntp.mdoc.in@1.307 +2 -2 + NTP_4_2_7P481 + + util/invoke-ntp-keygen.texi@1.476 +2 -2 + NTP_4_2_7P481 + + util/ntp-keygen-opts.c@1.493 +7 -7 + NTP_4_2_7P481 + + util/ntp-keygen-opts.h@1.492 +3 -3 + NTP_4_2_7P481 + + util/ntp-keygen.1ntp-keygenman@1.304 +3 -3 + NTP_4_2_7P481 + + util/ntp-keygen.1ntp-keygenmdoc@1.304 +2 -2 + NTP_4_2_7P481 + + util/ntp-keygen.html@1.151 +2 -2 + NTP_4_2_7P481 + + util/ntp-keygen.man.in@1.304 +3 -3 + NTP_4_2_7P481 + + util/ntp-keygen.mdoc.in@1.304 +2 -2 + NTP_4_2_7P481 + +ChangeSet@1.3236, 2014-11-21 21:13:03+00:00, stenn@psp-fb1.ntp.org + [Bug 2314] Kernel PPS binding EOPNOTSUPP is a failure condition + + ChangeLog@1.1571 +1 -0 + [Bug 2314] Kernel PPS binding EOPNOTSUPP is a failure condition + + ntpd/ntp_refclock.c@1.119 +5 -8 + [Bug 2314] Kernel PPS binding EOPNOTSUPP is a failure condition + +ChangeSet@1.3235, 2014-11-21 11:08:32+00:00, stenn@psp-fb1.ntp.org + Rename pps_enable to hardpps_enable. + + ChangeLog@1.1570 +1 -0 + Rename pps_enable to hardpps_enable. + + include/ntpd.h@1.183 +1 -1 + Rename pps_enable to hardpps_enable. + + ntpd/ntp_loopfilter.c@1.175 +3 -3 + Rename pps_enable to hardpps_enable. + + ntpd/ntp_proto.c@1.350 +2 -2 + Rename pps_enable to hardpps_enable. + + ntpd/ntp_refclock.c@1.118 +1 -1 + Rename pps_enable to hardpps_enable. + + ntpd/ntp_request.c@1.112 +1 -1 + Rename pps_enable to hardpps_enable. + + ntpd/refclock_jupiter.c@1.28 +1 -1 + Rename pps_enable to hardpps_enable. + + ntpd/refclock_oncore.c@1.101 +1 -1 + Rename pps_enable to hardpps_enable. + + ntpd/refclock_parse.c@1.68 +2 -2 + Rename pps_enable to hardpps_enable. + +ChangeSet@1.3234, 2014-11-21 09:44:10+00:00, stenn@psp-fb1.ntp.org + [Bug 2314] Only enable PPS if kernel consumer binding succeeds + + ChangeLog@1.1569 +1 -0 + [Bug 2314] Only enable PPS if kernel consumer binding succeeds + + ntpd/ntp_refclock.c@1.117 +4 -3 + [Bug 2314] Only enable PPS if kernel consumer binding succeeds + +ChangeSet@1.3233, 2014-11-21 09:00:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P480 + TAG: NTP_4_2_7P480 + + ChangeLog@1.1568 +1 -0 + NTP_4_2_7P480 + + ntpd/invoke-ntp.conf.texi@1.161 +1 -1 + NTP_4_2_7P480 + + ntpd/invoke-ntp.keys.texi@1.158 +1 -1 + NTP_4_2_7P480 + + ntpd/invoke-ntpd.texi@1.474 +2 -2 + NTP_4_2_7P480 + + ntpd/ntp.conf.5man@1.195 +3 -3 + NTP_4_2_7P480 + + ntpd/ntp.conf.5mdoc@1.195 +2 -2 + NTP_4_2_7P480 + + ntpd/ntp.conf.html@1.154 +1 -1 + NTP_4_2_7P480 + + ntpd/ntp.conf.man.in@1.195 +3 -3 + NTP_4_2_7P480 + + ntpd/ntp.conf.mdoc.in@1.195 +2 -2 + NTP_4_2_7P480 + + ntpd/ntp.keys.5man@1.192 +2 -2 + NTP_4_2_7P480 + + ntpd/ntp.keys.5mdoc@1.192 +2 -2 + NTP_4_2_7P480 + + ntpd/ntp.keys.html@1.155 +1 -1 + NTP_4_2_7P480 + + ntpd/ntp.keys.man.in@1.192 +2 -2 + NTP_4_2_7P480 + + ntpd/ntp.keys.mdoc.in@1.192 +2 -2 + NTP_4_2_7P480 + + ntpd/ntpd-opts.c@1.495 +7 -7 + NTP_4_2_7P480 + + ntpd/ntpd-opts.h@1.494 +3 -3 + NTP_4_2_7P480 + + ntpd/ntpd.1ntpdman@1.303 +3 -3 + NTP_4_2_7P480 + + ntpd/ntpd.1ntpdmdoc@1.303 +2 -2 + NTP_4_2_7P480 + + ntpd/ntpd.html@1.149 +2 -2 + NTP_4_2_7P480 + + ntpd/ntpd.man.in@1.303 +3 -3 + NTP_4_2_7P480 + + ntpd/ntpd.mdoc.in@1.303 +2 -2 + NTP_4_2_7P480 + + ntpdc/invoke-ntpdc.texi@1.472 +2 -2 + NTP_4_2_7P480 + + ntpdc/ntpdc-opts.c@1.490 +7 -7 + NTP_4_2_7P480 + + ntpdc/ntpdc-opts.h@1.489 +3 -3 + NTP_4_2_7P480 + + ntpdc/ntpdc.1ntpdcman@1.303 +3 -3 + NTP_4_2_7P480 + + ntpdc/ntpdc.1ntpdcmdoc@1.303 +2 -2 + NTP_4_2_7P480 + + ntpdc/ntpdc.html@1.316 +2 -2 + NTP_4_2_7P480 + + ntpdc/ntpdc.man.in@1.303 +3 -3 + NTP_4_2_7P480 + + ntpdc/ntpdc.mdoc.in@1.303 +2 -2 + NTP_4_2_7P480 + + ntpq/invoke-ntpq.texi@1.478 +2 -2 + NTP_4_2_7P480 + + ntpq/ntpq-opts.c@1.495 +7 -7 + NTP_4_2_7P480 + + ntpq/ntpq-opts.h@1.493 +3 -3 + NTP_4_2_7P480 + + ntpq/ntpq.1ntpqman@1.306 +3 -3 + NTP_4_2_7P480 + + ntpq/ntpq.1ntpqmdoc@1.306 +2 -2 + NTP_4_2_7P480 + + ntpq/ntpq.html@1.146 +2 -2 + NTP_4_2_7P480 + + ntpq/ntpq.man.in@1.306 +3 -3 + NTP_4_2_7P480 + + ntpq/ntpq.mdoc.in@1.306 +2 -2 + NTP_4_2_7P480 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.474 +2 -2 + NTP_4_2_7P480 + + ntpsnmpd/ntpsnmpd-opts.c@1.492 +7 -7 + NTP_4_2_7P480 + + ntpsnmpd/ntpsnmpd-opts.h@1.491 +3 -3 + NTP_4_2_7P480 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.303 +3 -3 + NTP_4_2_7P480 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.303 +2 -2 + NTP_4_2_7P480 + + ntpsnmpd/ntpsnmpd.html@1.144 +1 -1 + NTP_4_2_7P480 + + ntpsnmpd/ntpsnmpd.man.in@1.303 +3 -3 + NTP_4_2_7P480 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.303 +2 -2 + NTP_4_2_7P480 + + packageinfo.sh@1.484 +1 -1 + NTP_4_2_7P480 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.65 +3 -3 + NTP_4_2_7P480 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.65 +2 -2 + NTP_4_2_7P480 + + scripts/calc_tickadj/calc_tickadj.html@1.67 +1 -1 + NTP_4_2_7P480 + + scripts/calc_tickadj/calc_tickadj.man.in@1.64 +3 -3 + NTP_4_2_7P480 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.65 +2 -2 + NTP_4_2_7P480 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.69 +1 -1 + NTP_4_2_7P480 + + scripts/invoke-plot_summary.texi@1.86 +2 -2 + NTP_4_2_7P480 + + scripts/invoke-summary.texi@1.86 +2 -2 + NTP_4_2_7P480 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.295 +2 -2 + NTP_4_2_7P480 + + scripts/ntp-wait/ntp-wait-opts@1.31 +2 -2 + NTP_4_2_7P480 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.293 +3 -3 + NTP_4_2_7P480 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.293 +2 -2 + NTP_4_2_7P480 + + scripts/ntp-wait/ntp-wait.html@1.312 +2 -2 + NTP_4_2_7P480 + + scripts/ntp-wait/ntp-wait.man.in@1.293 +3 -3 + NTP_4_2_7P480 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.293 +2 -2 + NTP_4_2_7P480 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.84 +2 -2 + NTP_4_2_7P480 + + scripts/ntpsweep/ntpsweep-opts@1.33 +2 -2 + NTP_4_2_7P480 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.72 +3 -3 + NTP_4_2_7P480 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.72 +2 -2 + NTP_4_2_7P480 + + scripts/ntpsweep/ntpsweep.html@1.85 +2 -2 + NTP_4_2_7P480 + + scripts/ntpsweep/ntpsweep.man.in@1.72 +3 -3 + NTP_4_2_7P480 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.73 +2 -2 + NTP_4_2_7P480 + + scripts/ntptrace/invoke-ntptrace.texi@1.84 +2 -2 + NTP_4_2_7P480 + + scripts/ntptrace/ntptrace-opts@1.33 +2 -2 + NTP_4_2_7P480 + + scripts/ntptrace/ntptrace.1ntptraceman@1.72 +3 -3 + NTP_4_2_7P480 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.72 +2 -2 + NTP_4_2_7P480 + + scripts/ntptrace/ntptrace.html@1.85 +2 -2 + NTP_4_2_7P480 + + scripts/ntptrace/ntptrace.man.in@1.72 +3 -3 + NTP_4_2_7P480 + + scripts/ntptrace/ntptrace.mdoc.in@1.73 +2 -2 + NTP_4_2_7P480 + + scripts/plot_summary-opts@1.33 +2 -2 + NTP_4_2_7P480 + + scripts/plot_summary.1plot_summaryman@1.84 +3 -3 + NTP_4_2_7P480 + + scripts/plot_summary.1plot_summarymdoc@1.84 +2 -2 + NTP_4_2_7P480 + + scripts/plot_summary.html@1.87 +2 -2 + NTP_4_2_7P480 + + scripts/plot_summary.man.in@1.84 +3 -3 + NTP_4_2_7P480 + + scripts/plot_summary.mdoc.in@1.84 +2 -2 + NTP_4_2_7P480 + + scripts/summary-opts@1.33 +2 -2 + NTP_4_2_7P480 + + scripts/summary.1summaryman@1.84 +3 -3 + NTP_4_2_7P480 + + scripts/summary.1summarymdoc@1.84 +2 -2 + NTP_4_2_7P480 + + scripts/summary.html@1.87 +2 -2 + NTP_4_2_7P480 + + scripts/summary.man.in@1.84 +3 -3 + NTP_4_2_7P480 + + scripts/summary.mdoc.in@1.84 +2 -2 + NTP_4_2_7P480 + + sntp/invoke-sntp.texi@1.471 +2 -2 + NTP_4_2_7P480 + + sntp/sntp-opts.c@1.489 +7 -7 + NTP_4_2_7P480 + + sntp/sntp-opts.h@1.488 +3 -3 + NTP_4_2_7P480 + + sntp/sntp.1sntpman@1.306 +3 -3 + NTP_4_2_7P480 + + sntp/sntp.1sntpmdoc@1.306 +2 -2 + NTP_4_2_7P480 + + sntp/sntp.html@1.486 +2 -2 + NTP_4_2_7P480 + + sntp/sntp.man.in@1.306 +3 -3 + NTP_4_2_7P480 + + sntp/sntp.mdoc.in@1.306 +2 -2 + NTP_4_2_7P480 + + util/invoke-ntp-keygen.texi@1.475 +2 -2 + NTP_4_2_7P480 + + util/ntp-keygen-opts.c@1.492 +7 -7 + NTP_4_2_7P480 + + util/ntp-keygen-opts.h@1.491 +3 -3 + NTP_4_2_7P480 + + util/ntp-keygen.1ntp-keygenman@1.303 +3 -3 + NTP_4_2_7P480 + + util/ntp-keygen.1ntp-keygenmdoc@1.303 +2 -2 + NTP_4_2_7P480 + + util/ntp-keygen.html@1.150 +2 -2 + NTP_4_2_7P480 + + util/ntp-keygen.man.in@1.303 +3 -3 + NTP_4_2_7P480 + + util/ntp-keygen.mdoc.in@1.303 +2 -2 + NTP_4_2_7P480 + +ChangeSet@1.3232, 2014-11-20 10:21:46+00:00, stenn@psp-fb1.ntp.org + [Bug 2677] PATH_MAX isn't #define'd under Windows + + ChangeLog@1.1567 +2 -0 + [Bug 2677] PATH_MAX isn't #define'd under Windows + + ntpd/ntp_loopfilter.c@1.174 +3 -0 + [Bug 2677] PATH_MAX isn't #define'd under Windows + +ChangeSet@1.3231, 2014-11-15 08:58:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P479 + TAG: NTP_4_2_7P479 + + ChangeLog@1.1566 +1 -0 + NTP_4_2_7P479 + + ntpd/invoke-ntp.conf.texi@1.160 +1 -1 + NTP_4_2_7P479 + + ntpd/invoke-ntp.keys.texi@1.157 +1 -1 + NTP_4_2_7P479 + + ntpd/invoke-ntpd.texi@1.473 +2 -2 + NTP_4_2_7P479 + + ntpd/ntp.conf.5man@1.194 +3 -3 + NTP_4_2_7P479 + + ntpd/ntp.conf.5mdoc@1.194 +2 -2 + NTP_4_2_7P479 + + ntpd/ntp.conf.html@1.153 +1 -1 + NTP_4_2_7P479 + + ntpd/ntp.conf.man.in@1.194 +3 -3 + NTP_4_2_7P479 + + ntpd/ntp.conf.mdoc.in@1.194 +2 -2 + NTP_4_2_7P479 + + ntpd/ntp.keys.5man@1.191 +2 -2 + NTP_4_2_7P479 + + ntpd/ntp.keys.5mdoc@1.191 +2 -2 + NTP_4_2_7P479 + + ntpd/ntp.keys.html@1.154 +1 -1 + NTP_4_2_7P479 + + ntpd/ntp.keys.man.in@1.191 +2 -2 + NTP_4_2_7P479 + + ntpd/ntp.keys.mdoc.in@1.191 +2 -2 + NTP_4_2_7P479 + + ntpd/ntpd-opts.c@1.494 +7 -7 + NTP_4_2_7P479 + + ntpd/ntpd-opts.h@1.493 +3 -3 + NTP_4_2_7P479 + + ntpd/ntpd.1ntpdman@1.302 +3 -3 + NTP_4_2_7P479 + + ntpd/ntpd.1ntpdmdoc@1.302 +2 -2 + NTP_4_2_7P479 + + ntpd/ntpd.html@1.148 +2 -2 + NTP_4_2_7P479 + + ntpd/ntpd.man.in@1.302 +3 -3 + NTP_4_2_7P479 + + ntpd/ntpd.mdoc.in@1.302 +2 -2 + NTP_4_2_7P479 + + ntpdc/invoke-ntpdc.texi@1.471 +2 -2 + NTP_4_2_7P479 + + ntpdc/ntpdc-opts.c@1.489 +7 -7 + NTP_4_2_7P479 + + ntpdc/ntpdc-opts.h@1.488 +3 -3 + NTP_4_2_7P479 + + ntpdc/ntpdc.1ntpdcman@1.302 +3 -3 + NTP_4_2_7P479 + + ntpdc/ntpdc.1ntpdcmdoc@1.302 +2 -2 + NTP_4_2_7P479 + + ntpdc/ntpdc.html@1.315 +2 -2 + NTP_4_2_7P479 + + ntpdc/ntpdc.man.in@1.302 +3 -3 + NTP_4_2_7P479 + + ntpdc/ntpdc.mdoc.in@1.302 +2 -2 + NTP_4_2_7P479 + + ntpq/invoke-ntpq.texi@1.477 +2 -2 + NTP_4_2_7P479 + + ntpq/ntpq-opts.c@1.494 +7 -7 + NTP_4_2_7P479 + + ntpq/ntpq-opts.h@1.492 +3 -3 + NTP_4_2_7P479 + + ntpq/ntpq.1ntpqman@1.305 +3 -3 + NTP_4_2_7P479 + + ntpq/ntpq.1ntpqmdoc@1.305 +2 -2 + NTP_4_2_7P479 + + ntpq/ntpq.html@1.145 +2 -2 + NTP_4_2_7P479 + + ntpq/ntpq.man.in@1.305 +3 -3 + NTP_4_2_7P479 + + ntpq/ntpq.mdoc.in@1.305 +2 -2 + NTP_4_2_7P479 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.473 +2 -2 + NTP_4_2_7P479 + + ntpsnmpd/ntpsnmpd-opts.c@1.491 +7 -7 + NTP_4_2_7P479 + + ntpsnmpd/ntpsnmpd-opts.h@1.490 +3 -3 + NTP_4_2_7P479 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.302 +3 -3 + NTP_4_2_7P479 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.302 +2 -2 + NTP_4_2_7P479 + + ntpsnmpd/ntpsnmpd.html@1.143 +1 -1 + NTP_4_2_7P479 + + ntpsnmpd/ntpsnmpd.man.in@1.302 +3 -3 + NTP_4_2_7P479 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.302 +2 -2 + NTP_4_2_7P479 + + packageinfo.sh@1.483 +1 -1 + NTP_4_2_7P479 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.64 +3 -3 + NTP_4_2_7P479 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.64 +2 -2 + NTP_4_2_7P479 + + scripts/calc_tickadj/calc_tickadj.html@1.66 +1 -1 + NTP_4_2_7P479 + + scripts/calc_tickadj/calc_tickadj.man.in@1.63 +3 -3 + NTP_4_2_7P479 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.64 +2 -2 + NTP_4_2_7P479 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.68 +1 -1 + NTP_4_2_7P479 + + scripts/invoke-plot_summary.texi@1.85 +2 -2 + NTP_4_2_7P479 + + scripts/invoke-summary.texi@1.85 +2 -2 + NTP_4_2_7P479 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.294 +2 -2 + NTP_4_2_7P479 + + scripts/ntp-wait/ntp-wait-opts@1.30 +2 -2 + NTP_4_2_7P479 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.292 +3 -3 + NTP_4_2_7P479 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.292 +2 -2 + NTP_4_2_7P479 + + scripts/ntp-wait/ntp-wait.html@1.311 +2 -2 + NTP_4_2_7P479 + + scripts/ntp-wait/ntp-wait.man.in@1.292 +3 -3 + NTP_4_2_7P479 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.292 +2 -2 + NTP_4_2_7P479 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.83 +2 -2 + NTP_4_2_7P479 + + scripts/ntpsweep/ntpsweep-opts@1.32 +2 -2 + NTP_4_2_7P479 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.71 +3 -3 + NTP_4_2_7P479 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.71 +2 -2 + NTP_4_2_7P479 + + scripts/ntpsweep/ntpsweep.html@1.84 +2 -2 + NTP_4_2_7P479 + + scripts/ntpsweep/ntpsweep.man.in@1.71 +3 -3 + NTP_4_2_7P479 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.72 +2 -2 + NTP_4_2_7P479 + + scripts/ntptrace/invoke-ntptrace.texi@1.83 +2 -2 + NTP_4_2_7P479 + + scripts/ntptrace/ntptrace-opts@1.32 +2 -2 + NTP_4_2_7P479 + + scripts/ntptrace/ntptrace.1ntptraceman@1.71 +3 -3 + NTP_4_2_7P479 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.71 +2 -2 + NTP_4_2_7P479 + + scripts/ntptrace/ntptrace.html@1.84 +2 -2 + NTP_4_2_7P479 + + scripts/ntptrace/ntptrace.man.in@1.71 +3 -3 + NTP_4_2_7P479 + + scripts/ntptrace/ntptrace.mdoc.in@1.72 +2 -2 + NTP_4_2_7P479 + + scripts/plot_summary-opts@1.32 +2 -2 + NTP_4_2_7P479 + + scripts/plot_summary.1plot_summaryman@1.83 +3 -3 + NTP_4_2_7P479 + + scripts/plot_summary.1plot_summarymdoc@1.83 +2 -2 + NTP_4_2_7P479 + + scripts/plot_summary.html@1.86 +2 -2 + NTP_4_2_7P479 + + scripts/plot_summary.man.in@1.83 +3 -3 + NTP_4_2_7P479 + + scripts/plot_summary.mdoc.in@1.83 +2 -2 + NTP_4_2_7P479 + + scripts/summary-opts@1.32 +2 -2 + NTP_4_2_7P479 + + scripts/summary.1summaryman@1.83 +3 -3 + NTP_4_2_7P479 + + scripts/summary.1summarymdoc@1.83 +2 -2 + NTP_4_2_7P479 + + scripts/summary.html@1.86 +2 -2 + NTP_4_2_7P479 + + scripts/summary.man.in@1.83 +3 -3 + NTP_4_2_7P479 + + scripts/summary.mdoc.in@1.83 +2 -2 + NTP_4_2_7P479 + + sntp/invoke-sntp.texi@1.470 +2 -2 + NTP_4_2_7P479 + + sntp/sntp-opts.c@1.488 +7 -7 + NTP_4_2_7P479 + + sntp/sntp-opts.h@1.487 +3 -3 + NTP_4_2_7P479 + + sntp/sntp.1sntpman@1.305 +3 -3 + NTP_4_2_7P479 + + sntp/sntp.1sntpmdoc@1.305 +2 -2 + NTP_4_2_7P479 + + sntp/sntp.html@1.485 +2 -2 + NTP_4_2_7P479 + + sntp/sntp.man.in@1.305 +3 -3 + NTP_4_2_7P479 + + sntp/sntp.mdoc.in@1.305 +2 -2 + NTP_4_2_7P479 + + util/invoke-ntp-keygen.texi@1.474 +2 -2 + NTP_4_2_7P479 + + util/ntp-keygen-opts.c@1.491 +7 -7 + NTP_4_2_7P479 + + util/ntp-keygen-opts.h@1.490 +3 -3 + NTP_4_2_7P479 + + util/ntp-keygen.1ntp-keygenman@1.302 +3 -3 + NTP_4_2_7P479 + + util/ntp-keygen.1ntp-keygenmdoc@1.302 +2 -2 + NTP_4_2_7P479 + + util/ntp-keygen.html@1.149 +2 -2 + NTP_4_2_7P479 + + util/ntp-keygen.man.in@1.302 +3 -3 + NTP_4_2_7P479 + + util/ntp-keygen.mdoc.in@1.302 +2 -2 + NTP_4_2_7P479 + +ChangeSet@1.3230, 2014-11-15 04:42:01+00:00, stenn@psp-fb1.ntp.org + [Bug 2651] Certificates with ASN timestamps w/ 4-digit years mis-parsed + + ChangeLog@1.1565 +1 -0 + [Bug 2651] Certificates with ASN timestamps w/ 4-digit years mis-parsed + + include/ntp_crypto.h@1.51 +4 -2 + [Bug 2651] Certificates with ASN timestamps w/ 4-digit years mis-parsed + + ntpd/ntp_control.c@1.190 +4 -1 + [Bug 2651] Certificates with ASN timestamps w/ 4-digit years mis-parsed + + ntpd/ntp_crypto.c@1.168 +98 -32 + [Bug 2651] Certificates with ASN timestamps w/ 4-digit years mis-parsed + +ChangeSet@1.3229, 2014-11-14 10:55:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P478 + TAG: NTP_4_2_7P478 + + ChangeLog@1.1564 +1 -0 + NTP_4_2_7P478 + + ntpd/invoke-ntp.conf.texi@1.159 +1 -1 + NTP_4_2_7P478 + + ntpd/invoke-ntp.keys.texi@1.156 +1 -1 + NTP_4_2_7P478 + + ntpd/invoke-ntpd.texi@1.472 +2 -2 + NTP_4_2_7P478 + + ntpd/ntp.conf.5man@1.193 +3 -3 + NTP_4_2_7P478 + + ntpd/ntp.conf.5mdoc@1.193 +2 -2 + NTP_4_2_7P478 + + ntpd/ntp.conf.html@1.152 +1 -1 + NTP_4_2_7P478 + + ntpd/ntp.conf.man.in@1.193 +3 -3 + NTP_4_2_7P478 + + ntpd/ntp.conf.mdoc.in@1.193 +2 -2 + NTP_4_2_7P478 + + ntpd/ntp.keys.5man@1.190 +2 -2 + NTP_4_2_7P478 + + ntpd/ntp.keys.5mdoc@1.190 +2 -2 + NTP_4_2_7P478 + + ntpd/ntp.keys.html@1.153 +1 -1 + NTP_4_2_7P478 + + ntpd/ntp.keys.man.in@1.190 +2 -2 + NTP_4_2_7P478 + + ntpd/ntp.keys.mdoc.in@1.190 +2 -2 + NTP_4_2_7P478 + + ntpd/ntpd-opts.c@1.493 +7 -7 + NTP_4_2_7P478 + + ntpd/ntpd-opts.h@1.492 +3 -3 + NTP_4_2_7P478 + + ntpd/ntpd.1ntpdman@1.301 +3 -3 + NTP_4_2_7P478 + + ntpd/ntpd.1ntpdmdoc@1.301 +2 -2 + NTP_4_2_7P478 + + ntpd/ntpd.html@1.147 +2 -2 + NTP_4_2_7P478 + + ntpd/ntpd.man.in@1.301 +3 -3 + NTP_4_2_7P478 + + ntpd/ntpd.mdoc.in@1.301 +2 -2 + NTP_4_2_7P478 + + ntpdc/invoke-ntpdc.texi@1.470 +2 -2 + NTP_4_2_7P478 + + ntpdc/ntpdc-opts.c@1.488 +7 -7 + NTP_4_2_7P478 + + ntpdc/ntpdc-opts.h@1.487 +3 -3 + NTP_4_2_7P478 + + ntpdc/ntpdc.1ntpdcman@1.301 +3 -3 + NTP_4_2_7P478 + + ntpdc/ntpdc.1ntpdcmdoc@1.301 +2 -2 + NTP_4_2_7P478 + + ntpdc/ntpdc.html@1.314 +2 -2 + NTP_4_2_7P478 + + ntpdc/ntpdc.man.in@1.301 +3 -3 + NTP_4_2_7P478 + + ntpdc/ntpdc.mdoc.in@1.301 +2 -2 + NTP_4_2_7P478 + + ntpq/invoke-ntpq.texi@1.476 +2 -2 + NTP_4_2_7P478 + + ntpq/ntpq-opts.c@1.493 +7 -7 + NTP_4_2_7P478 + + ntpq/ntpq-opts.h@1.491 +3 -3 + NTP_4_2_7P478 + + ntpq/ntpq.1ntpqman@1.304 +3 -3 + NTP_4_2_7P478 + + ntpq/ntpq.1ntpqmdoc@1.304 +2 -2 + NTP_4_2_7P478 + + ntpq/ntpq.html@1.144 +2 -2 + NTP_4_2_7P478 + + ntpq/ntpq.man.in@1.304 +3 -3 + NTP_4_2_7P478 + + ntpq/ntpq.mdoc.in@1.304 +2 -2 + NTP_4_2_7P478 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.472 +2 -2 + NTP_4_2_7P478 + + ntpsnmpd/ntpsnmpd-opts.c@1.490 +7 -7 + NTP_4_2_7P478 + + ntpsnmpd/ntpsnmpd-opts.h@1.489 +3 -3 + NTP_4_2_7P478 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.301 +3 -3 + NTP_4_2_7P478 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.301 +2 -2 + NTP_4_2_7P478 + + ntpsnmpd/ntpsnmpd.html@1.142 +1 -1 + NTP_4_2_7P478 + + ntpsnmpd/ntpsnmpd.man.in@1.301 +3 -3 + NTP_4_2_7P478 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.301 +2 -2 + NTP_4_2_7P478 + + packageinfo.sh@1.482 +1 -1 + NTP_4_2_7P478 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.63 +3 -3 + NTP_4_2_7P478 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.63 +2 -2 + NTP_4_2_7P478 + + scripts/calc_tickadj/calc_tickadj.html@1.65 +1 -1 + NTP_4_2_7P478 + + scripts/calc_tickadj/calc_tickadj.man.in@1.62 +3 -3 + NTP_4_2_7P478 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.63 +2 -2 + NTP_4_2_7P478 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.67 +1 -1 + NTP_4_2_7P478 + + scripts/invoke-plot_summary.texi@1.84 +2 -2 + NTP_4_2_7P478 + + scripts/invoke-summary.texi@1.84 +2 -2 + NTP_4_2_7P478 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.293 +2 -2 + NTP_4_2_7P478 + + scripts/ntp-wait/ntp-wait-opts@1.29 +2 -2 + NTP_4_2_7P478 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.291 +3 -3 + NTP_4_2_7P478 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.291 +2 -2 + NTP_4_2_7P478 + + scripts/ntp-wait/ntp-wait.html@1.310 +2 -2 + NTP_4_2_7P478 + + scripts/ntp-wait/ntp-wait.man.in@1.291 +3 -3 + NTP_4_2_7P478 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.291 +2 -2 + NTP_4_2_7P478 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.82 +2 -2 + NTP_4_2_7P478 + + scripts/ntpsweep/ntpsweep-opts@1.31 +2 -2 + NTP_4_2_7P478 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.70 +3 -3 + NTP_4_2_7P478 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.70 +2 -2 + NTP_4_2_7P478 + + scripts/ntpsweep/ntpsweep.html@1.83 +2 -2 + NTP_4_2_7P478 + + scripts/ntpsweep/ntpsweep.man.in@1.70 +3 -3 + NTP_4_2_7P478 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.71 +2 -2 + NTP_4_2_7P478 + + scripts/ntptrace/invoke-ntptrace.texi@1.82 +2 -2 + NTP_4_2_7P478 + + scripts/ntptrace/ntptrace-opts@1.31 +2 -2 + NTP_4_2_7P478 + + scripts/ntptrace/ntptrace.1ntptraceman@1.70 +3 -3 + NTP_4_2_7P478 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.70 +2 -2 + NTP_4_2_7P478 + + scripts/ntptrace/ntptrace.html@1.83 +2 -2 + NTP_4_2_7P478 + + scripts/ntptrace/ntptrace.man.in@1.70 +3 -3 + NTP_4_2_7P478 + + scripts/ntptrace/ntptrace.mdoc.in@1.71 +2 -2 + NTP_4_2_7P478 + + scripts/plot_summary-opts@1.31 +2 -2 + NTP_4_2_7P478 + + scripts/plot_summary.1plot_summaryman@1.82 +3 -3 + NTP_4_2_7P478 + + scripts/plot_summary.1plot_summarymdoc@1.82 +2 -2 + NTP_4_2_7P478 + + scripts/plot_summary.html@1.85 +2 -2 + NTP_4_2_7P478 + + scripts/plot_summary.man.in@1.82 +3 -3 + NTP_4_2_7P478 + + scripts/plot_summary.mdoc.in@1.82 +2 -2 + NTP_4_2_7P478 + + scripts/summary-opts@1.31 +2 -2 + NTP_4_2_7P478 + + scripts/summary.1summaryman@1.82 +3 -3 + NTP_4_2_7P478 + + scripts/summary.1summarymdoc@1.82 +2 -2 + NTP_4_2_7P478 + + scripts/summary.html@1.85 +2 -2 + NTP_4_2_7P478 + + scripts/summary.man.in@1.82 +3 -3 + NTP_4_2_7P478 + + scripts/summary.mdoc.in@1.82 +2 -2 + NTP_4_2_7P478 + + sntp/invoke-sntp.texi@1.469 +2 -2 + NTP_4_2_7P478 + + sntp/sntp-opts.c@1.487 +7 -7 + NTP_4_2_7P478 + + sntp/sntp-opts.h@1.486 +3 -3 + NTP_4_2_7P478 + + sntp/sntp.1sntpman@1.304 +3 -3 + NTP_4_2_7P478 + + sntp/sntp.1sntpmdoc@1.304 +2 -2 + NTP_4_2_7P478 + + sntp/sntp.html@1.484 +2 -2 + NTP_4_2_7P478 + + sntp/sntp.man.in@1.304 +3 -3 + NTP_4_2_7P478 + + sntp/sntp.mdoc.in@1.304 +2 -2 + NTP_4_2_7P478 + + util/invoke-ntp-keygen.texi@1.473 +2 -2 + NTP_4_2_7P478 + + util/ntp-keygen-opts.c@1.490 +7 -7 + NTP_4_2_7P478 + + util/ntp-keygen-opts.h@1.489 +3 -3 + NTP_4_2_7P478 + + util/ntp-keygen.1ntp-keygenman@1.301 +3 -3 + NTP_4_2_7P478 + + util/ntp-keygen.1ntp-keygenmdoc@1.301 +2 -2 + NTP_4_2_7P478 + + util/ntp-keygen.html@1.148 +2 -2 + NTP_4_2_7P478 + + util/ntp-keygen.man.in@1.301 +3 -3 + NTP_4_2_7P478 + + util/ntp-keygen.mdoc.in@1.301 +2 -2 + NTP_4_2_7P478 + +ChangeSet@1.3228, 2014-11-14 09:53:23+00:00, stenn@psp-fb1.ntp.org + [Bug 2650] includefile processing broken + + ChangeLog@1.1563 +1 -0 + [Bug 2650] includefile processing broken + + ntpd/ntp_scanner.c@1.45 +2 -0 + [Bug 2650] includefile processing broken + +ChangeSet@1.3227, 2014-11-14 09:40:06+00:00, stenn@psp-fb1.ntp.org + [Bug 2639] Check return value of ntp_adjtime() + + ChangeLog@1.1562 +1 -0 + [Bug 2639] Check return value of ntp_adjtime() + + ntpd/ntp_loopfilter.c@1.173 +136 -26 + [Bug 2639] Check return value of ntp_adjtime() + +ChangeSet@1.3226, 2014-11-14 09:19:09+00:00, stenn@psp-fb1.ntp.org + [Sec 2630] buffer overrun in ntpq tokenize() + + ChangeLog@1.1561 +1 -0 + [Sec 2630] buffer overrun in ntpq tokenize() + + ntpq/ntpq.c@1.153 +16 -0 + [Sec 2630] buffer overrun in ntpq tokenize() + +ChangeSet@1.3225, 2014-11-14 08:54:11+00:00, stenn@psp-fb1.ntp.org + [Bug 2661] ntpq crashes with mreadvar + + ChangeLog@1.1560 +1 -0 + [Bug 2661] ntpq crashes with mreadvar + + ntpq/ntpq-subs.c@1.101 +1 -1 + [Bug 2661] ntpq crashes with mreadvar + +ChangeSet@1.3224, 2014-11-13 09:01:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P477 + TAG: NTP_4_2_7P477 + + ChangeLog@1.1559 +1 -0 + NTP_4_2_7P477 + + ntpd/invoke-ntp.conf.texi@1.158 +1 -1 + NTP_4_2_7P477 + + ntpd/invoke-ntp.keys.texi@1.155 +1 -1 + NTP_4_2_7P477 + + ntpd/invoke-ntpd.texi@1.471 +2 -2 + NTP_4_2_7P477 + + ntpd/ntp.conf.5man@1.192 +3 -3 + NTP_4_2_7P477 + + ntpd/ntp.conf.5mdoc@1.192 +2 -2 + NTP_4_2_7P477 + + ntpd/ntp.conf.html@1.151 +12 -1 + NTP_4_2_7P477 + + ntpd/ntp.conf.man.in@1.192 +3 -3 + NTP_4_2_7P477 + + ntpd/ntp.conf.mdoc.in@1.192 +2 -2 + NTP_4_2_7P477 + + ntpd/ntp.keys.5man@1.189 +2 -2 + NTP_4_2_7P477 + + ntpd/ntp.keys.5mdoc@1.189 +2 -2 + NTP_4_2_7P477 + + ntpd/ntp.keys.html@1.152 +1 -1 + NTP_4_2_7P477 + + ntpd/ntp.keys.man.in@1.189 +2 -2 + NTP_4_2_7P477 + + ntpd/ntp.keys.mdoc.in@1.189 +2 -2 + NTP_4_2_7P477 + + ntpd/ntpd-opts.c@1.492 +7 -7 + NTP_4_2_7P477 + + ntpd/ntpd-opts.h@1.491 +3 -3 + NTP_4_2_7P477 + + ntpd/ntpd.1ntpdman@1.300 +3 -3 + NTP_4_2_7P477 + + ntpd/ntpd.1ntpdmdoc@1.300 +2 -2 + NTP_4_2_7P477 + + ntpd/ntpd.html@1.146 +2 -2 + NTP_4_2_7P477 + + ntpd/ntpd.man.in@1.300 +3 -3 + NTP_4_2_7P477 + + ntpd/ntpd.mdoc.in@1.300 +2 -2 + NTP_4_2_7P477 + + ntpdc/invoke-ntpdc.texi@1.469 +2 -2 + NTP_4_2_7P477 + + ntpdc/ntpdc-opts.c@1.487 +7 -7 + NTP_4_2_7P477 + + ntpdc/ntpdc-opts.h@1.486 +3 -3 + NTP_4_2_7P477 + + ntpdc/ntpdc.1ntpdcman@1.300 +3 -3 + NTP_4_2_7P477 + + ntpdc/ntpdc.1ntpdcmdoc@1.300 +2 -2 + NTP_4_2_7P477 + + ntpdc/ntpdc.html@1.313 +2 -2 + NTP_4_2_7P477 + + ntpdc/ntpdc.man.in@1.300 +3 -3 + NTP_4_2_7P477 + + ntpdc/ntpdc.mdoc.in@1.300 +2 -2 + NTP_4_2_7P477 + + ntpq/invoke-ntpq.texi@1.475 +2 -2 + NTP_4_2_7P477 + + ntpq/ntpq-opts.c@1.492 +7 -7 + NTP_4_2_7P477 + + ntpq/ntpq-opts.h@1.490 +3 -3 + NTP_4_2_7P477 + + ntpq/ntpq.1ntpqman@1.303 +3 -3 + NTP_4_2_7P477 + + ntpq/ntpq.1ntpqmdoc@1.303 +2 -2 + NTP_4_2_7P477 + + ntpq/ntpq.html@1.143 +2 -2 + NTP_4_2_7P477 + + ntpq/ntpq.man.in@1.303 +3 -3 + NTP_4_2_7P477 + + ntpq/ntpq.mdoc.in@1.303 +2 -2 + NTP_4_2_7P477 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.471 +2 -2 + NTP_4_2_7P477 + + ntpsnmpd/ntpsnmpd-opts.c@1.489 +7 -7 + NTP_4_2_7P477 + + ntpsnmpd/ntpsnmpd-opts.h@1.488 +3 -3 + NTP_4_2_7P477 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.300 +3 -3 + NTP_4_2_7P477 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.300 +2 -2 + NTP_4_2_7P477 + + ntpsnmpd/ntpsnmpd.html@1.141 +1 -1 + NTP_4_2_7P477 + + ntpsnmpd/ntpsnmpd.man.in@1.300 +3 -3 + NTP_4_2_7P477 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.300 +2 -2 + NTP_4_2_7P477 + + packageinfo.sh@1.481 +1 -1 + NTP_4_2_7P477 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.62 +3 -3 + NTP_4_2_7P477 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.62 +2 -2 + NTP_4_2_7P477 + + scripts/calc_tickadj/calc_tickadj.html@1.64 +1 -1 + NTP_4_2_7P477 + + scripts/calc_tickadj/calc_tickadj.man.in@1.61 +3 -3 + NTP_4_2_7P477 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.62 +2 -2 + NTP_4_2_7P477 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.66 +1 -1 + NTP_4_2_7P477 + + scripts/invoke-plot_summary.texi@1.83 +2 -2 + NTP_4_2_7P477 + + scripts/invoke-summary.texi@1.83 +2 -2 + NTP_4_2_7P477 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.292 +2 -2 + NTP_4_2_7P477 + + scripts/ntp-wait/ntp-wait-opts@1.28 +2 -2 + NTP_4_2_7P477 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.290 +3 -3 + NTP_4_2_7P477 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.290 +2 -2 + NTP_4_2_7P477 + + scripts/ntp-wait/ntp-wait.html@1.309 +2 -2 + NTP_4_2_7P477 + + scripts/ntp-wait/ntp-wait.man.in@1.290 +3 -3 + NTP_4_2_7P477 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.290 +2 -2 + NTP_4_2_7P477 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.81 +2 -2 + NTP_4_2_7P477 + + scripts/ntpsweep/ntpsweep-opts@1.30 +2 -2 + NTP_4_2_7P477 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.69 +3 -3 + NTP_4_2_7P477 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.69 +2 -2 + NTP_4_2_7P477 + + scripts/ntpsweep/ntpsweep.html@1.82 +2 -2 + NTP_4_2_7P477 + + scripts/ntpsweep/ntpsweep.man.in@1.69 +3 -3 + NTP_4_2_7P477 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.70 +2 -2 + NTP_4_2_7P477 + + scripts/ntptrace/invoke-ntptrace.texi@1.81 +2 -2 + NTP_4_2_7P477 + + scripts/ntptrace/ntptrace-opts@1.30 +2 -2 + NTP_4_2_7P477 + + scripts/ntptrace/ntptrace.1ntptraceman@1.69 +3 -3 + NTP_4_2_7P477 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.69 +2 -2 + NTP_4_2_7P477 + + scripts/ntptrace/ntptrace.html@1.82 +2 -2 + NTP_4_2_7P477 + + scripts/ntptrace/ntptrace.man.in@1.69 +3 -3 + NTP_4_2_7P477 + + scripts/ntptrace/ntptrace.mdoc.in@1.70 +2 -2 + NTP_4_2_7P477 + + scripts/plot_summary-opts@1.30 +2 -2 + NTP_4_2_7P477 + + scripts/plot_summary.1plot_summaryman@1.81 +3 -3 + NTP_4_2_7P477 + + scripts/plot_summary.1plot_summarymdoc@1.81 +2 -2 + NTP_4_2_7P477 + + scripts/plot_summary.html@1.84 +2 -2 + NTP_4_2_7P477 + + scripts/plot_summary.man.in@1.81 +3 -3 + NTP_4_2_7P477 + + scripts/plot_summary.mdoc.in@1.81 +2 -2 + NTP_4_2_7P477 + + scripts/summary-opts@1.30 +2 -2 + NTP_4_2_7P477 + + scripts/summary.1summaryman@1.81 +3 -3 + NTP_4_2_7P477 + + scripts/summary.1summarymdoc@1.81 +2 -2 + NTP_4_2_7P477 + + scripts/summary.html@1.84 +2 -2 + NTP_4_2_7P477 + + scripts/summary.man.in@1.81 +3 -3 + NTP_4_2_7P477 + + scripts/summary.mdoc.in@1.81 +2 -2 + NTP_4_2_7P477 + + sntp/invoke-sntp.texi@1.468 +2 -2 + NTP_4_2_7P477 + + sntp/sntp-opts.c@1.486 +7 -7 + NTP_4_2_7P477 + + sntp/sntp-opts.h@1.485 +3 -3 + NTP_4_2_7P477 + + sntp/sntp.1sntpman@1.303 +3 -3 + NTP_4_2_7P477 + + sntp/sntp.1sntpmdoc@1.303 +2 -2 + NTP_4_2_7P477 + + sntp/sntp.html@1.483 +2 -2 + NTP_4_2_7P477 + + sntp/sntp.man.in@1.303 +3 -3 + NTP_4_2_7P477 + + sntp/sntp.mdoc.in@1.303 +2 -2 + NTP_4_2_7P477 + + util/invoke-ntp-keygen.texi@1.472 +2 -2 + NTP_4_2_7P477 + + util/ntp-keygen-opts.c@1.489 +7 -7 + NTP_4_2_7P477 + + util/ntp-keygen-opts.h@1.488 +3 -3 + NTP_4_2_7P477 + + util/ntp-keygen.1ntp-keygenman@1.300 +3 -3 + NTP_4_2_7P477 + + util/ntp-keygen.1ntp-keygenmdoc@1.300 +2 -2 + NTP_4_2_7P477 + + util/ntp-keygen.html@1.147 +2 -2 + NTP_4_2_7P477 + + util/ntp-keygen.man.in@1.300 +3 -3 + NTP_4_2_7P477 + + util/ntp-keygen.mdoc.in@1.300 +2 -2 + NTP_4_2_7P477 + +ChangeSet@1.3223, 2014-11-13 03:05:35+00:00, stenn@psp-fb1.ntp.org + [Bug 2657] Document that "restrict nopeer" interferes with "pool" + + ChangeLog@1.1558 +1 -0 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + + html/accopt.html@1.43 +4 -3 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + + ntpd/invoke-ntp.conf.texi@1.157 +13 -1 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + + ntpd/ntp.conf.5man@1.191 +16 -3 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + + ntpd/ntp.conf.5mdoc@1.191 +14 -2 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + + ntpd/ntp.conf.def@1.13 +12 -0 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + + ntpd/ntp.conf.man.in@1.191 +16 -3 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + + ntpd/ntp.conf.mdoc.in@1.191 +14 -2 + [Bug 2657] Document that "restrict nopeer" intereferes with "pool" + +ChangeSet@1.3222, 2014-10-08 09:36:42+00:00, stenn@deacon.udel.edu + NTP_4_2_7P476 + TAG: NTP_4_2_7P476 + + ChangeLog@1.1557 +1 -0 + NTP_4_2_7P476 + + ntpd/invoke-ntp.conf.texi@1.156 +1 -1 + NTP_4_2_7P476 + + ntpd/invoke-ntp.keys.texi@1.154 +1 -1 + NTP_4_2_7P476 + + ntpd/invoke-ntpd.texi@1.470 +2 -2 + NTP_4_2_7P476 + + ntpd/ntp.conf.5man@1.190 +3 -3 + NTP_4_2_7P476 + + ntpd/ntp.conf.5mdoc@1.190 +2 -2 + NTP_4_2_7P476 + + ntpd/ntp.conf.html@1.150 +1 -1 + NTP_4_2_7P476 + + ntpd/ntp.conf.man.in@1.190 +3 -3 + NTP_4_2_7P476 + + ntpd/ntp.conf.mdoc.in@1.190 +2 -2 + NTP_4_2_7P476 + + ntpd/ntp.keys.5man@1.188 +2 -2 + NTP_4_2_7P476 + + ntpd/ntp.keys.5mdoc@1.188 +2 -2 + NTP_4_2_7P476 + + ntpd/ntp.keys.html@1.151 +1 -1 + NTP_4_2_7P476 + + ntpd/ntp.keys.man.in@1.188 +2 -2 + NTP_4_2_7P476 + + ntpd/ntp.keys.mdoc.in@1.188 +2 -2 + NTP_4_2_7P476 + + ntpd/ntpd-opts.c@1.491 +10 -10 + NTP_4_2_7P476 + + ntpd/ntpd-opts.h@1.490 +3 -3 + NTP_4_2_7P476 + + ntpd/ntpd.1ntpdman@1.299 +3 -3 + NTP_4_2_7P476 + + ntpd/ntpd.1ntpdmdoc@1.299 +2 -2 + NTP_4_2_7P476 + + ntpd/ntpd.html@1.145 +2 -2 + NTP_4_2_7P476 + + ntpd/ntpd.man.in@1.299 +3 -3 + NTP_4_2_7P476 + + ntpd/ntpd.mdoc.in@1.299 +2 -2 + NTP_4_2_7P476 + + ntpdc/invoke-ntpdc.texi@1.468 +2 -2 + NTP_4_2_7P476 + + ntpdc/ntpdc-opts.c@1.486 +10 -10 + NTP_4_2_7P476 + + ntpdc/ntpdc-opts.h@1.485 +3 -3 + NTP_4_2_7P476 + + ntpdc/ntpdc.1ntpdcman@1.299 +3 -3 + NTP_4_2_7P476 + + ntpdc/ntpdc.1ntpdcmdoc@1.299 +2 -2 + NTP_4_2_7P476 + + ntpdc/ntpdc.html@1.312 +2 -2 + NTP_4_2_7P476 + + ntpdc/ntpdc.man.in@1.299 +3 -3 + NTP_4_2_7P476 + + ntpdc/ntpdc.mdoc.in@1.299 +2 -2 + NTP_4_2_7P476 + + ntpq/invoke-ntpq.texi@1.474 +2 -2 + NTP_4_2_7P476 + + ntpq/ntpq-opts.c@1.491 +10 -10 + NTP_4_2_7P476 + + ntpq/ntpq-opts.h@1.489 +3 -3 + NTP_4_2_7P476 + + ntpq/ntpq.1ntpqman@1.302 +3 -3 + NTP_4_2_7P476 + + ntpq/ntpq.1ntpqmdoc@1.302 +2 -2 + NTP_4_2_7P476 + + ntpq/ntpq.html@1.142 +2 -2 + NTP_4_2_7P476 + + ntpq/ntpq.man.in@1.302 +3 -3 + NTP_4_2_7P476 + + ntpq/ntpq.mdoc.in@1.302 +2 -2 + NTP_4_2_7P476 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.470 +2 -2 + NTP_4_2_7P476 + + ntpsnmpd/ntpsnmpd-opts.c@1.488 +10 -10 + NTP_4_2_7P476 + + ntpsnmpd/ntpsnmpd-opts.h@1.487 +3 -3 + NTP_4_2_7P476 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.299 +3 -3 + NTP_4_2_7P476 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.299 +2 -2 + NTP_4_2_7P476 + + ntpsnmpd/ntpsnmpd.html@1.140 +1 -1 + NTP_4_2_7P476 + + ntpsnmpd/ntpsnmpd.man.in@1.299 +3 -3 + NTP_4_2_7P476 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.299 +2 -2 + NTP_4_2_7P476 + + packageinfo.sh@1.480 +1 -1 + NTP_4_2_7P476 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.61 +3 -3 + NTP_4_2_7P476 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.61 +2 -2 + NTP_4_2_7P476 + + scripts/calc_tickadj/calc_tickadj.html@1.63 +1 -1 + NTP_4_2_7P476 + + scripts/calc_tickadj/calc_tickadj.man.in@1.60 +3 -3 + NTP_4_2_7P476 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.61 +2 -2 + NTP_4_2_7P476 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.65 +1 -1 + NTP_4_2_7P476 + + scripts/invoke-plot_summary.texi@1.82 +2 -2 + NTP_4_2_7P476 + + scripts/invoke-summary.texi@1.82 +2 -2 + NTP_4_2_7P476 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.291 +2 -2 + NTP_4_2_7P476 + + scripts/ntp-wait/ntp-wait-opts@1.27 +2 -2 + NTP_4_2_7P476 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.289 +3 -3 + NTP_4_2_7P476 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.289 +2 -2 + NTP_4_2_7P476 + + scripts/ntp-wait/ntp-wait.html@1.308 +2 -2 + NTP_4_2_7P476 + + scripts/ntp-wait/ntp-wait.man.in@1.289 +3 -3 + NTP_4_2_7P476 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.289 +2 -2 + NTP_4_2_7P476 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.80 +2 -2 + NTP_4_2_7P476 + + scripts/ntpsweep/ntpsweep-opts@1.29 +2 -2 + NTP_4_2_7P476 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.68 +3 -3 + NTP_4_2_7P476 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.68 +2 -2 + NTP_4_2_7P476 + + scripts/ntpsweep/ntpsweep.html@1.81 +2 -2 + NTP_4_2_7P476 + + scripts/ntpsweep/ntpsweep.man.in@1.68 +3 -3 + NTP_4_2_7P476 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.69 +2 -2 + NTP_4_2_7P476 + + scripts/ntptrace/invoke-ntptrace.texi@1.80 +2 -2 + NTP_4_2_7P476 + + scripts/ntptrace/ntptrace-opts@1.29 +2 -2 + NTP_4_2_7P476 + + scripts/ntptrace/ntptrace.1ntptraceman@1.68 +3 -3 + NTP_4_2_7P476 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.68 +2 -2 + NTP_4_2_7P476 + + scripts/ntptrace/ntptrace.html@1.81 +2 -2 + NTP_4_2_7P476 + + scripts/ntptrace/ntptrace.man.in@1.68 +3 -3 + NTP_4_2_7P476 + + scripts/ntptrace/ntptrace.mdoc.in@1.69 +2 -2 + NTP_4_2_7P476 + + scripts/plot_summary-opts@1.29 +2 -2 + NTP_4_2_7P476 + + scripts/plot_summary.1plot_summaryman@1.80 +3 -3 + NTP_4_2_7P476 + + scripts/plot_summary.1plot_summarymdoc@1.80 +2 -2 + NTP_4_2_7P476 + + scripts/plot_summary.html@1.83 +2 -2 + NTP_4_2_7P476 + + scripts/plot_summary.man.in@1.80 +3 -3 + NTP_4_2_7P476 + + scripts/plot_summary.mdoc.in@1.80 +2 -2 + NTP_4_2_7P476 + + scripts/summary-opts@1.29 +2 -2 + NTP_4_2_7P476 + + scripts/summary.1summaryman@1.80 +3 -3 + NTP_4_2_7P476 + + scripts/summary.1summarymdoc@1.80 +2 -2 + NTP_4_2_7P476 + + scripts/summary.html@1.83 +2 -2 + NTP_4_2_7P476 + + scripts/summary.man.in@1.80 +3 -3 + NTP_4_2_7P476 + + scripts/summary.mdoc.in@1.80 +2 -2 + NTP_4_2_7P476 + + sntp/invoke-sntp.texi@1.467 +2 -2 + NTP_4_2_7P476 + + sntp/sntp-opts.c@1.485 +10 -10 + NTP_4_2_7P476 + + sntp/sntp-opts.h@1.484 +3 -3 + NTP_4_2_7P476 + + sntp/sntp.1sntpman@1.302 +3 -3 + NTP_4_2_7P476 + + sntp/sntp.1sntpmdoc@1.302 +2 -2 + NTP_4_2_7P476 + + sntp/sntp.html@1.482 +2 -2 + NTP_4_2_7P476 + + sntp/sntp.man.in@1.302 +3 -3 + NTP_4_2_7P476 + + sntp/sntp.mdoc.in@1.302 +2 -2 + NTP_4_2_7P476 + + util/invoke-ntp-keygen.texi@1.471 +2 -2 + NTP_4_2_7P476 + + util/ntp-keygen-opts.c@1.488 +10 -10 + NTP_4_2_7P476 + + util/ntp-keygen-opts.h@1.487 +3 -3 + NTP_4_2_7P476 + + util/ntp-keygen.1ntp-keygenman@1.299 +3 -3 + NTP_4_2_7P476 + + util/ntp-keygen.1ntp-keygenmdoc@1.299 +2 -2 + NTP_4_2_7P476 + + util/ntp-keygen.html@1.146 +2 -2 + NTP_4_2_7P476 + + util/ntp-keygen.man.in@1.299 +3 -3 + NTP_4_2_7P476 + + util/ntp-keygen.mdoc.in@1.299 +2 -2 + NTP_4_2_7P476 + +ChangeSet@1.3221, 2014-10-04 11:53:31+02:00, jnperlin@hydra.(none) + [Bug 2503] sht utility outdated + + ChangeLog@1.1556 +1 -0 + [Bug 2503] sht utility outdated + + util/sht.c@1.5 +147 -72 + [Bug 2503] sht utility outdated + +ChangeSet@1.3220, 2014-09-11 08:58:05+00:00, stenn@deacon.udel.edu + NTP_4_2_7P475 + TAG: NTP_4_2_7P475 + + ChangeLog@1.1555 +1 -0 + NTP_4_2_7P475 + + ntpd/invoke-ntp.conf.texi@1.155 +1 -1 + NTP_4_2_7P475 + + ntpd/invoke-ntp.keys.texi@1.153 +1 -1 + NTP_4_2_7P475 + + ntpd/invoke-ntpd.texi@1.469 +2 -2 + NTP_4_2_7P475 + + ntpd/ntp.conf.5man@1.189 +3 -3 + NTP_4_2_7P475 + + ntpd/ntp.conf.5mdoc@1.189 +2 -2 + NTP_4_2_7P475 + + ntpd/ntp.conf.html@1.149 +1 -1 + NTP_4_2_7P475 + + ntpd/ntp.conf.man.in@1.189 +3 -3 + NTP_4_2_7P475 + + ntpd/ntp.conf.mdoc.in@1.189 +2 -2 + NTP_4_2_7P475 + + ntpd/ntp.keys.5man@1.187 +2 -2 + NTP_4_2_7P475 + + ntpd/ntp.keys.5mdoc@1.187 +2 -2 + NTP_4_2_7P475 + + ntpd/ntp.keys.html@1.150 +1 -1 + NTP_4_2_7P475 + + ntpd/ntp.keys.man.in@1.187 +2 -2 + NTP_4_2_7P475 + + ntpd/ntp.keys.mdoc.in@1.187 +2 -2 + NTP_4_2_7P475 + + ntpd/ntpd-opts.c@1.490 +7 -7 + NTP_4_2_7P475 + + ntpd/ntpd-opts.h@1.489 +3 -3 + NTP_4_2_7P475 + + ntpd/ntpd.1ntpdman@1.298 +3 -3 + NTP_4_2_7P475 + + ntpd/ntpd.1ntpdmdoc@1.298 +2 -2 + NTP_4_2_7P475 + + ntpd/ntpd.html@1.144 +2 -2 + NTP_4_2_7P475 + + ntpd/ntpd.man.in@1.298 +3 -3 + NTP_4_2_7P475 + + ntpd/ntpd.mdoc.in@1.298 +2 -2 + NTP_4_2_7P475 + + ntpdc/invoke-ntpdc.texi@1.467 +2 -2 + NTP_4_2_7P475 + + ntpdc/ntpdc-opts.c@1.485 +7 -7 + NTP_4_2_7P475 + + ntpdc/ntpdc-opts.h@1.484 +3 -3 + NTP_4_2_7P475 + + ntpdc/ntpdc.1ntpdcman@1.298 +3 -3 + NTP_4_2_7P475 + + ntpdc/ntpdc.1ntpdcmdoc@1.298 +2 -2 + NTP_4_2_7P475 + + ntpdc/ntpdc.html@1.311 +2 -2 + NTP_4_2_7P475 + + ntpdc/ntpdc.man.in@1.298 +3 -3 + NTP_4_2_7P475 + + ntpdc/ntpdc.mdoc.in@1.298 +2 -2 + NTP_4_2_7P475 + + ntpq/invoke-ntpq.texi@1.473 +2 -2 + NTP_4_2_7P475 + + ntpq/ntpq-opts.c@1.490 +7 -7 + NTP_4_2_7P475 + + ntpq/ntpq-opts.h@1.488 +3 -3 + NTP_4_2_7P475 + + ntpq/ntpq.1ntpqman@1.301 +3 -3 + NTP_4_2_7P475 + + ntpq/ntpq.1ntpqmdoc@1.301 +2 -2 + NTP_4_2_7P475 + + ntpq/ntpq.html@1.141 +2 -2 + NTP_4_2_7P475 + + ntpq/ntpq.man.in@1.301 +3 -3 + NTP_4_2_7P475 + + ntpq/ntpq.mdoc.in@1.301 +2 -2 + NTP_4_2_7P475 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.469 +2 -2 + NTP_4_2_7P475 + + ntpsnmpd/ntpsnmpd-opts.c@1.487 +7 -7 + NTP_4_2_7P475 + + ntpsnmpd/ntpsnmpd-opts.h@1.486 +3 -3 + NTP_4_2_7P475 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.298 +3 -3 + NTP_4_2_7P475 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.298 +2 -2 + NTP_4_2_7P475 + + ntpsnmpd/ntpsnmpd.html@1.139 +1 -1 + NTP_4_2_7P475 + + ntpsnmpd/ntpsnmpd.man.in@1.298 +3 -3 + NTP_4_2_7P475 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.298 +2 -2 + NTP_4_2_7P475 + + packageinfo.sh@1.479 +1 -1 + NTP_4_2_7P475 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.60 +3 -3 + NTP_4_2_7P475 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.60 +2 -2 + NTP_4_2_7P475 + + scripts/calc_tickadj/calc_tickadj.html@1.62 +1 -1 + NTP_4_2_7P475 + + scripts/calc_tickadj/calc_tickadj.man.in@1.59 +3 -3 + NTP_4_2_7P475 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.60 +2 -2 + NTP_4_2_7P475 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.64 +1 -1 + NTP_4_2_7P475 + + scripts/invoke-plot_summary.texi@1.81 +2 -2 + NTP_4_2_7P475 + + scripts/invoke-summary.texi@1.81 +2 -2 + NTP_4_2_7P475 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.290 +2 -2 + NTP_4_2_7P475 + + scripts/ntp-wait/ntp-wait-opts@1.26 +2 -2 + NTP_4_2_7P475 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.288 +3 -3 + NTP_4_2_7P475 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.288 +2 -2 + NTP_4_2_7P475 + + scripts/ntp-wait/ntp-wait.html@1.307 +2 -2 + NTP_4_2_7P475 + + scripts/ntp-wait/ntp-wait.man.in@1.288 +3 -3 + NTP_4_2_7P475 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.288 +2 -2 + NTP_4_2_7P475 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.79 +2 -2 + NTP_4_2_7P475 + + scripts/ntpsweep/ntpsweep-opts@1.28 +2 -2 + NTP_4_2_7P475 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.67 +3 -3 + NTP_4_2_7P475 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.67 +2 -2 + NTP_4_2_7P475 + + scripts/ntpsweep/ntpsweep.html@1.80 +2 -2 + NTP_4_2_7P475 + + scripts/ntpsweep/ntpsweep.man.in@1.67 +3 -3 + NTP_4_2_7P475 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.68 +2 -2 + NTP_4_2_7P475 + + scripts/ntptrace/invoke-ntptrace.texi@1.79 +2 -2 + NTP_4_2_7P475 + + scripts/ntptrace/ntptrace-opts@1.28 +2 -2 + NTP_4_2_7P475 + + scripts/ntptrace/ntptrace.1ntptraceman@1.67 +3 -3 + NTP_4_2_7P475 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.67 +2 -2 + NTP_4_2_7P475 + + scripts/ntptrace/ntptrace.html@1.80 +2 -2 + NTP_4_2_7P475 + + scripts/ntptrace/ntptrace.man.in@1.67 +3 -3 + NTP_4_2_7P475 + + scripts/ntptrace/ntptrace.mdoc.in@1.68 +2 -2 + NTP_4_2_7P475 + + scripts/plot_summary-opts@1.28 +2 -2 + NTP_4_2_7P475 + + scripts/plot_summary.1plot_summaryman@1.79 +3 -3 + NTP_4_2_7P475 + + scripts/plot_summary.1plot_summarymdoc@1.79 +2 -2 + NTP_4_2_7P475 + + scripts/plot_summary.html@1.82 +2 -2 + NTP_4_2_7P475 + + scripts/plot_summary.man.in@1.79 +3 -3 + NTP_4_2_7P475 + + scripts/plot_summary.mdoc.in@1.79 +2 -2 + NTP_4_2_7P475 + + scripts/summary-opts@1.28 +2 -2 + NTP_4_2_7P475 + + scripts/summary.1summaryman@1.79 +3 -3 + NTP_4_2_7P475 + + scripts/summary.1summarymdoc@1.79 +2 -2 + NTP_4_2_7P475 + + scripts/summary.html@1.82 +2 -2 + NTP_4_2_7P475 + + scripts/summary.man.in@1.79 +3 -3 + NTP_4_2_7P475 + + scripts/summary.mdoc.in@1.79 +2 -2 + NTP_4_2_7P475 + + sntp/invoke-sntp.texi@1.466 +2 -2 + NTP_4_2_7P475 + + sntp/sntp-opts.c@1.484 +7 -7 + NTP_4_2_7P475 + + sntp/sntp-opts.h@1.483 +3 -3 + NTP_4_2_7P475 + + sntp/sntp.1sntpman@1.301 +3 -3 + NTP_4_2_7P475 + + sntp/sntp.1sntpmdoc@1.301 +2 -2 + NTP_4_2_7P475 + + sntp/sntp.html@1.481 +2 -2 + NTP_4_2_7P475 + + sntp/sntp.man.in@1.301 +3 -3 + NTP_4_2_7P475 + + sntp/sntp.mdoc.in@1.301 +2 -2 + NTP_4_2_7P475 + + util/invoke-ntp-keygen.texi@1.470 +2 -2 + NTP_4_2_7P475 + + util/ntp-keygen-opts.c@1.487 +7 -7 + NTP_4_2_7P475 + + util/ntp-keygen-opts.h@1.486 +3 -3 + NTP_4_2_7P475 + + util/ntp-keygen.1ntp-keygenman@1.298 +3 -3 + NTP_4_2_7P475 + + util/ntp-keygen.1ntp-keygenmdoc@1.298 +2 -2 + NTP_4_2_7P475 + + util/ntp-keygen.html@1.145 +2 -2 + NTP_4_2_7P475 + + util/ntp-keygen.man.in@1.298 +3 -3 + NTP_4_2_7P475 + + util/ntp-keygen.mdoc.in@1.298 +2 -2 + NTP_4_2_7P475 + +ChangeSet@1.3219, 2014-09-10 09:48:50+00:00, stenn@psp-fb1.ntp.org + [Bug 2654] refclock_true.c doesn't identify the Mk III + + ChangeLog@1.1554 +1 -0 + [Bug 2654] refclock_true.c doesn't identify the Mk III + + ntpd/refclock_true.c@1.22 +1 -1 + [Bug 2654] refclock_true.c doesn't identify the Mk III + +ChangeSet@1.3218, 2014-09-10 09:21:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P474 + TAG: NTP_4_2_7P474 + + ChangeLog@1.1553 +1 -0 + NTP_4_2_7P474 + + ntpd/invoke-ntp.conf.texi@1.154 +1 -1 + NTP_4_2_7P474 + + ntpd/invoke-ntp.keys.texi@1.152 +1 -1 + NTP_4_2_7P474 + + ntpd/invoke-ntpd.texi@1.468 +2 -2 + NTP_4_2_7P474 + + ntpd/ntp.conf.5man@1.188 +2990 -0 + NTP_4_2_7P474 + + ntpd/ntp.conf.5mdoc@1.188 +2 -2 + NTP_4_2_7P474 + + ntpd/ntp.conf.html@1.148 +1 -1 + NTP_4_2_7P474 + + ntpd/ntp.conf.man.in@1.188 +2990 -0 + NTP_4_2_7P474 + + ntpd/ntp.conf.mdoc.in@1.188 +2 -2 + NTP_4_2_7P474 + + ntpd/ntp.keys.5man@1.186 +2 -2 + NTP_4_2_7P474 + + ntpd/ntp.keys.5mdoc@1.186 +2 -2 + NTP_4_2_7P474 + + ntpd/ntp.keys.html@1.149 +1 -1 + NTP_4_2_7P474 + + ntpd/ntp.keys.man.in@1.186 +2 -2 + NTP_4_2_7P474 + + ntpd/ntp.keys.mdoc.in@1.186 +2 -2 + NTP_4_2_7P474 + + ntpd/ntpd-opts.c@1.489 +7 -7 + NTP_4_2_7P474 + + ntpd/ntpd-opts.h@1.488 +3 -3 + NTP_4_2_7P474 + + ntpd/ntpd.1ntpdman@1.297 +3 -3 + NTP_4_2_7P474 + + ntpd/ntpd.1ntpdmdoc@1.297 +2 -2 + NTP_4_2_7P474 + + ntpd/ntpd.html@1.143 +2 -2 + NTP_4_2_7P474 + + ntpd/ntpd.man.in@1.297 +3 -3 + NTP_4_2_7P474 + + ntpd/ntpd.mdoc.in@1.297 +2 -2 + NTP_4_2_7P474 + + ntpdc/invoke-ntpdc.texi@1.466 +2 -2 + NTP_4_2_7P474 + + ntpdc/ntpdc-opts.c@1.484 +7 -7 + NTP_4_2_7P474 + + ntpdc/ntpdc-opts.h@1.483 +3 -3 + NTP_4_2_7P474 + + ntpdc/ntpdc.1ntpdcman@1.297 +3 -3 + NTP_4_2_7P474 + + ntpdc/ntpdc.1ntpdcmdoc@1.297 +2 -2 + NTP_4_2_7P474 + + ntpdc/ntpdc.html@1.310 +2 -2 + NTP_4_2_7P474 + + ntpdc/ntpdc.man.in@1.297 +3 -3 + NTP_4_2_7P474 + + ntpdc/ntpdc.mdoc.in@1.297 +2 -2 + NTP_4_2_7P474 + + ntpq/invoke-ntpq.texi@1.472 +2 -2 + NTP_4_2_7P474 + + ntpq/ntpq-opts.c@1.489 +7 -7 + NTP_4_2_7P474 + + ntpq/ntpq-opts.h@1.487 +3 -3 + NTP_4_2_7P474 + + ntpq/ntpq.1ntpqman@1.300 +3 -3 + NTP_4_2_7P474 + + ntpq/ntpq.1ntpqmdoc@1.300 +2 -2 + NTP_4_2_7P474 + + ntpq/ntpq.html@1.140 +2 -2 + NTP_4_2_7P474 + + ntpq/ntpq.man.in@1.300 +3 -3 + NTP_4_2_7P474 + + ntpq/ntpq.mdoc.in@1.300 +2 -2 + NTP_4_2_7P474 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.468 +2 -2 + NTP_4_2_7P474 + + ntpsnmpd/ntpsnmpd-opts.c@1.486 +7 -7 + NTP_4_2_7P474 + + ntpsnmpd/ntpsnmpd-opts.h@1.485 +3 -3 + NTP_4_2_7P474 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.297 +3 -3 + NTP_4_2_7P474 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.297 +2 -2 + NTP_4_2_7P474 + + ntpsnmpd/ntpsnmpd.html@1.138 +1 -1 + NTP_4_2_7P474 + + ntpsnmpd/ntpsnmpd.man.in@1.297 +3 -3 + NTP_4_2_7P474 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.297 +2 -2 + NTP_4_2_7P474 + + packageinfo.sh@1.478 +1 -1 + NTP_4_2_7P474 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.59 +3 -3 + NTP_4_2_7P474 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.59 +2 -2 + NTP_4_2_7P474 + + scripts/calc_tickadj/calc_tickadj.html@1.61 +1 -1 + NTP_4_2_7P474 + + scripts/calc_tickadj/calc_tickadj.man.in@1.58 +3 -3 + NTP_4_2_7P474 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.59 +2 -2 + NTP_4_2_7P474 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.63 +1 -1 + NTP_4_2_7P474 + + scripts/invoke-plot_summary.texi@1.80 +2 -2 + NTP_4_2_7P474 + + scripts/invoke-summary.texi@1.80 +2 -2 + NTP_4_2_7P474 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.289 +2 -2 + NTP_4_2_7P474 + + scripts/ntp-wait/ntp-wait-opts@1.25 +2 -2 + NTP_4_2_7P474 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.287 +3 -3 + NTP_4_2_7P474 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.287 +2 -2 + NTP_4_2_7P474 + + scripts/ntp-wait/ntp-wait.html@1.306 +2 -2 + NTP_4_2_7P474 + + scripts/ntp-wait/ntp-wait.man.in@1.287 +3 -3 + NTP_4_2_7P474 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.287 +2 -2 + NTP_4_2_7P474 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.78 +2 -2 + NTP_4_2_7P474 + + scripts/ntpsweep/ntpsweep-opts@1.27 +2 -2 + NTP_4_2_7P474 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.66 +3 -3 + NTP_4_2_7P474 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.66 +2 -2 + NTP_4_2_7P474 + + scripts/ntpsweep/ntpsweep.html@1.79 +2 -2 + NTP_4_2_7P474 + + scripts/ntpsweep/ntpsweep.man.in@1.66 +3 -3 + NTP_4_2_7P474 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.67 +2 -2 + NTP_4_2_7P474 + + scripts/ntptrace/invoke-ntptrace.texi@1.78 +2 -2 + NTP_4_2_7P474 + + scripts/ntptrace/ntptrace-opts@1.27 +2 -2 + NTP_4_2_7P474 + + scripts/ntptrace/ntptrace.1ntptraceman@1.66 +3 -3 + NTP_4_2_7P474 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.66 +2 -2 + NTP_4_2_7P474 + + scripts/ntptrace/ntptrace.html@1.79 +2 -2 + NTP_4_2_7P474 + + scripts/ntptrace/ntptrace.man.in@1.66 +3 -3 + NTP_4_2_7P474 + + scripts/ntptrace/ntptrace.mdoc.in@1.67 +2 -2 + NTP_4_2_7P474 + + scripts/plot_summary-opts@1.27 +2 -2 + NTP_4_2_7P474 + + scripts/plot_summary.1plot_summaryman@1.78 +3 -3 + NTP_4_2_7P474 + + scripts/plot_summary.1plot_summarymdoc@1.78 +2 -2 + NTP_4_2_7P474 + + scripts/plot_summary.html@1.81 +2 -2 + NTP_4_2_7P474 + + scripts/plot_summary.man.in@1.78 +3 -3 + NTP_4_2_7P474 + + scripts/plot_summary.mdoc.in@1.78 +2 -2 + NTP_4_2_7P474 + + scripts/summary-opts@1.27 +2 -2 + NTP_4_2_7P474 + + scripts/summary.1summaryman@1.78 +3 -3 + NTP_4_2_7P474 + + scripts/summary.1summarymdoc@1.78 +2 -2 + NTP_4_2_7P474 + + scripts/summary.html@1.81 +2 -2 + NTP_4_2_7P474 + + scripts/summary.man.in@1.78 +3 -3 + NTP_4_2_7P474 + + scripts/summary.mdoc.in@1.78 +2 -2 + NTP_4_2_7P474 + + sntp/invoke-sntp.texi@1.465 +2 -2 + NTP_4_2_7P474 + + sntp/sntp-opts.c@1.483 +7 -7 + NTP_4_2_7P474 + + sntp/sntp-opts.h@1.482 +3 -3 + NTP_4_2_7P474 + + sntp/sntp.1sntpman@1.300 +3 -3 + NTP_4_2_7P474 + + sntp/sntp.1sntpmdoc@1.300 +2 -2 + NTP_4_2_7P474 + + sntp/sntp.html@1.480 +2 -2 + NTP_4_2_7P474 + + sntp/sntp.man.in@1.300 +3 -3 + NTP_4_2_7P474 + + sntp/sntp.mdoc.in@1.300 +2 -2 + NTP_4_2_7P474 + + util/invoke-ntp-keygen.texi@1.469 +2 -2 + NTP_4_2_7P474 + + util/ntp-keygen-opts.c@1.486 +7 -7 + NTP_4_2_7P474 + + util/ntp-keygen-opts.h@1.485 +3 -3 + NTP_4_2_7P474 + + util/ntp-keygen.1ntp-keygenman@1.297 +3 -3 + NTP_4_2_7P474 + + util/ntp-keygen.1ntp-keygenmdoc@1.297 +2 -2 + NTP_4_2_7P474 + + util/ntp-keygen.html@1.144 +2 -2 + NTP_4_2_7P474 + + util/ntp-keygen.man.in@1.297 +3 -3 + NTP_4_2_7P474 + + util/ntp-keygen.mdoc.in@1.297 +2 -2 + NTP_4_2_7P474 + +ChangeSet@1.3217, 2014-09-10 08:56:05+00:00, stenn@psp-fb1.ntp.org + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + ChangeLog@1.1552 +1 -0 + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + configure.ac@1.576 +40 -0 + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + ntpd/ntpd.c@1.157 +4 -4 + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + +ChangeSet@1.3216, 2014-09-10 08:25:33+00:00, stenn@psp-fb1.ntp.org + [Bug 2649] Clean up html/ page installation + + ChangeLog@1.1551 +1 -0 + [Bug 2649] Clean up html/ page installation + + Makefile.am@1.123 +1 -1 + [Bug 2649] Clean up html/ page installation + +ChangeSet@1.3215, 2014-09-07 02:04:00+00:00, stenn@deacon.udel.edu + NTP_4_2_7P473 + TAG: NTP_4_2_7P473 + + ChangeLog@1.1550 +1 -0 + NTP_4_2_7P473 + + ntpd/invoke-ntp.conf.texi@1.153 +1 -1 + NTP_4_2_7P473 + + ntpd/invoke-ntp.keys.texi@1.151 +1 -1 + NTP_4_2_7P473 + + ntpd/invoke-ntpd.texi@1.467 +2 -2 + NTP_4_2_7P473 + + ntpd/ntp.conf.5man@1.187 +0 -2990 + NTP_4_2_7P473 + + ntpd/ntp.conf.5mdoc@1.187 +1 -1 + NTP_4_2_7P473 + + ntpd/ntp.conf.html@1.147 +1 -1 + NTP_4_2_7P473 + + ntpd/ntp.conf.man.in@1.187 +0 -2990 + NTP_4_2_7P473 + + ntpd/ntp.conf.mdoc.in@1.187 +1 -1 + NTP_4_2_7P473 + + ntpd/ntp.keys.5man@1.185 +2 -2 + NTP_4_2_7P473 + + ntpd/ntp.keys.5mdoc@1.185 +1 -1 + NTP_4_2_7P473 + + ntpd/ntp.keys.html@1.148 +1 -1 + NTP_4_2_7P473 + + ntpd/ntp.keys.man.in@1.185 +2 -2 + NTP_4_2_7P473 + + ntpd/ntp.keys.mdoc.in@1.185 +1 -1 + NTP_4_2_7P473 + + ntpd/ntpd-opts.c@1.488 +7 -7 + NTP_4_2_7P473 + + ntpd/ntpd-opts.h@1.487 +3 -3 + NTP_4_2_7P473 + + ntpd/ntpd.1ntpdman@1.296 +3 -3 + NTP_4_2_7P473 + + ntpd/ntpd.1ntpdmdoc@1.296 +1 -1 + NTP_4_2_7P473 + + ntpd/ntpd.html@1.142 +2 -2 + NTP_4_2_7P473 + + ntpd/ntpd.man.in@1.296 +3 -3 + NTP_4_2_7P473 + + ntpd/ntpd.mdoc.in@1.296 +1 -1 + NTP_4_2_7P473 + + ntpdc/invoke-ntpdc.texi@1.465 +2 -2 + NTP_4_2_7P473 + + ntpdc/ntpdc-opts.c@1.483 +7 -7 + NTP_4_2_7P473 + + ntpdc/ntpdc-opts.h@1.482 +3 -3 + NTP_4_2_7P473 + + ntpdc/ntpdc.1ntpdcman@1.296 +3 -3 + NTP_4_2_7P473 + + ntpdc/ntpdc.1ntpdcmdoc@1.296 +1 -1 + NTP_4_2_7P473 + + ntpdc/ntpdc.html@1.309 +2 -2 + NTP_4_2_7P473 + + ntpdc/ntpdc.man.in@1.296 +3 -3 + NTP_4_2_7P473 + + ntpdc/ntpdc.mdoc.in@1.296 +1 -1 + NTP_4_2_7P473 + + ntpq/invoke-ntpq.texi@1.471 +2 -2 + NTP_4_2_7P473 + + ntpq/ntpq-opts.c@1.488 +7 -7 + NTP_4_2_7P473 + + ntpq/ntpq-opts.h@1.486 +3 -3 + NTP_4_2_7P473 + + ntpq/ntpq.1ntpqman@1.299 +3 -3 + NTP_4_2_7P473 + + ntpq/ntpq.1ntpqmdoc@1.299 +1 -1 + NTP_4_2_7P473 + + ntpq/ntpq.html@1.139 +56 -11 + NTP_4_2_7P473 + + ntpq/ntpq.man.in@1.299 +3 -3 + NTP_4_2_7P473 + + ntpq/ntpq.mdoc.in@1.299 +1 -1 + NTP_4_2_7P473 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.467 +2 -2 + NTP_4_2_7P473 + + ntpsnmpd/ntpsnmpd-opts.c@1.485 +7 -7 + NTP_4_2_7P473 + + ntpsnmpd/ntpsnmpd-opts.h@1.484 +3 -3 + NTP_4_2_7P473 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.296 +3 -3 + NTP_4_2_7P473 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.296 +1 -1 + NTP_4_2_7P473 + + ntpsnmpd/ntpsnmpd.html@1.137 +1 -1 + NTP_4_2_7P473 + + ntpsnmpd/ntpsnmpd.man.in@1.296 +3 -3 + NTP_4_2_7P473 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.296 +1 -1 + NTP_4_2_7P473 + + packageinfo.sh@1.477 +1 -1 + NTP_4_2_7P473 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.58 +3 -3 + NTP_4_2_7P473 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.58 +1 -1 + NTP_4_2_7P473 + + scripts/calc_tickadj/calc_tickadj.html@1.60 +1 -1 + NTP_4_2_7P473 + + scripts/calc_tickadj/calc_tickadj.man.in@1.57 +3 -3 + NTP_4_2_7P473 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.58 +1 -1 + NTP_4_2_7P473 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.62 +1 -1 + NTP_4_2_7P473 + + scripts/invoke-plot_summary.texi@1.79 +1 -1 + NTP_4_2_7P473 + + scripts/invoke-summary.texi@1.79 +1 -1 + NTP_4_2_7P473 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.288 +2 -2 + NTP_4_2_7P473 + + scripts/ntp-wait/ntp-wait-opts@1.24 +2 -2 + NTP_4_2_7P473 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.286 +3 -3 + NTP_4_2_7P473 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.286 +1 -1 + NTP_4_2_7P473 + + scripts/ntp-wait/ntp-wait.html@1.305 +2 -2 + NTP_4_2_7P473 + + scripts/ntp-wait/ntp-wait.man.in@1.286 +3 -3 + NTP_4_2_7P473 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.286 +1 -1 + NTP_4_2_7P473 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.77 +2 -2 + NTP_4_2_7P473 + + scripts/ntpsweep/ntpsweep-opts@1.26 +2 -2 + NTP_4_2_7P473 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.65 +3 -3 + NTP_4_2_7P473 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.65 +1 -1 + NTP_4_2_7P473 + + scripts/ntpsweep/ntpsweep.html@1.78 +2 -2 + NTP_4_2_7P473 + + scripts/ntpsweep/ntpsweep.man.in@1.65 +3 -3 + NTP_4_2_7P473 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.66 +1 -1 + NTP_4_2_7P473 + + scripts/ntptrace/invoke-ntptrace.texi@1.77 +2 -2 + NTP_4_2_7P473 + + scripts/ntptrace/ntptrace-opts@1.26 +2 -2 + NTP_4_2_7P473 + + scripts/ntptrace/ntptrace.1ntptraceman@1.65 +3 -3 + NTP_4_2_7P473 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.65 +1 -1 + NTP_4_2_7P473 + + scripts/ntptrace/ntptrace.html@1.78 +2 -2 + NTP_4_2_7P473 + + scripts/ntptrace/ntptrace.man.in@1.65 +3 -3 + NTP_4_2_7P473 + + scripts/ntptrace/ntptrace.mdoc.in@1.66 +1 -1 + NTP_4_2_7P473 + + scripts/plot_summary-opts@1.26 +1 -1 + NTP_4_2_7P473 + + scripts/plot_summary.1plot_summaryman@1.77 +2 -2 + NTP_4_2_7P473 + + scripts/plot_summary.1plot_summarymdoc@1.77 +1 -1 + NTP_4_2_7P473 + + scripts/plot_summary.html@1.80 +2 -2 + NTP_4_2_7P473 + + scripts/plot_summary.man.in@1.77 +2 -2 + NTP_4_2_7P473 + + scripts/plot_summary.mdoc.in@1.77 +1 -1 + NTP_4_2_7P473 + + scripts/summary-opts@1.26 +1 -1 + NTP_4_2_7P473 + + scripts/summary.1summaryman@1.77 +2 -2 + NTP_4_2_7P473 + + scripts/summary.1summarymdoc@1.77 +1 -1 + NTP_4_2_7P473 + + scripts/summary.html@1.80 +2 -2 + NTP_4_2_7P473 + + scripts/summary.man.in@1.77 +2 -2 + NTP_4_2_7P473 + + scripts/summary.mdoc.in@1.77 +1 -1 + NTP_4_2_7P473 + + sntp/invoke-sntp.texi@1.464 +2 -2 + NTP_4_2_7P473 + + sntp/sntp-opts.c@1.482 +7 -7 + NTP_4_2_7P473 + + sntp/sntp-opts.h@1.481 +3 -3 + NTP_4_2_7P473 + + sntp/sntp.1sntpman@1.299 +3 -3 + NTP_4_2_7P473 + + sntp/sntp.1sntpmdoc@1.299 +1 -1 + NTP_4_2_7P473 + + sntp/sntp.html@1.479 +2 -2 + NTP_4_2_7P473 + + sntp/sntp.man.in@1.299 +3 -3 + NTP_4_2_7P473 + + sntp/sntp.mdoc.in@1.299 +1 -1 + NTP_4_2_7P473 + + util/invoke-ntp-keygen.texi@1.468 +2 -2 + NTP_4_2_7P473 + + util/ntp-keygen-opts.c@1.485 +7 -7 + NTP_4_2_7P473 + + util/ntp-keygen-opts.h@1.484 +3 -3 + NTP_4_2_7P473 + + util/ntp-keygen.1ntp-keygenman@1.296 +3 -3 + NTP_4_2_7P473 + + util/ntp-keygen.1ntp-keygenmdoc@1.296 +1 -1 + NTP_4_2_7P473 + + util/ntp-keygen.html@1.143 +2 -2 + NTP_4_2_7P473 + + util/ntp-keygen.man.in@1.296 +3 -3 + NTP_4_2_7P473 + + util/ntp-keygen.mdoc.in@1.296 +1 -1 + NTP_4_2_7P473 + +ChangeSet@1.3214, 2014-09-06 22:03:18-04:00, stenn@deacon.udel.edu + Autogen DNE fix + + scripts/Makefile.am@1.39 +1 -1 + Autogen DNE fix + +ChangeSet@1.3213, 2014-09-06 05:38:30-04:00, stenn@deacon.udel.edu + [Bug 2649] Clean up html/ page installation + + Makefile.am@1.122 +2 -0 + [Bug 2649] Clean up html/ page installation + +ChangeSet@1.3212, 2014-09-06 09:27:29+00:00, stenn@psp-fb1.ntp.org + [Bug 2649] Clean up html/ page installation + + ChangeLog@1.1549 +1 -0 + [Bug 2649] Clean up html/ page installation + + Makefile.am@1.121 +1 -1 + [Bug 2649] Clean up html/ page installation + +ChangeSet@1.3211, 2014-09-06 08:58:30+00:00, stenn@deacon.udel.edu + NTP_4_2_7P472 + TAG: NTP_4_2_7P472 + + ChangeLog@1.1548 +1 -0 + NTP_4_2_7P472 + + ntpd/invoke-ntp.conf.texi@1.152 +1 -1 + NTP_4_2_7P472 + + ntpd/invoke-ntp.keys.texi@1.150 +1 -1 + NTP_4_2_7P472 + + ntpd/invoke-ntpd.texi@1.466 +2 -2 + NTP_4_2_7P472 + + ntpd/ntp.conf.5man@1.186 +3 -3 + NTP_4_2_7P472 + + ntpd/ntp.conf.5mdoc@1.186 +2 -2 + NTP_4_2_7P472 + + ntpd/ntp.conf.html@1.146 +1 -1 + NTP_4_2_7P472 + + ntpd/ntp.conf.man.in@1.186 +3 -3 + NTP_4_2_7P472 + + ntpd/ntp.conf.mdoc.in@1.186 +2 -2 + NTP_4_2_7P472 + + ntpd/ntp.keys.5man@1.184 +2 -2 + NTP_4_2_7P472 + + ntpd/ntp.keys.5mdoc@1.184 +2 -2 + NTP_4_2_7P472 + + ntpd/ntp.keys.html@1.147 +1 -1 + NTP_4_2_7P472 + + ntpd/ntp.keys.man.in@1.184 +2 -2 + NTP_4_2_7P472 + + ntpd/ntp.keys.mdoc.in@1.184 +2 -2 + NTP_4_2_7P472 + + ntpd/ntpd-opts.c@1.487 +7 -7 + NTP_4_2_7P472 + + ntpd/ntpd-opts.h@1.486 +3 -3 + NTP_4_2_7P472 + + ntpd/ntpd.1ntpdman@1.295 +3 -3 + NTP_4_2_7P472 + + ntpd/ntpd.1ntpdmdoc@1.295 +2 -2 + NTP_4_2_7P472 + + ntpd/ntpd.html@1.141 +2 -2 + NTP_4_2_7P472 + + ntpd/ntpd.man.in@1.295 +3 -3 + NTP_4_2_7P472 + + ntpd/ntpd.mdoc.in@1.295 +2 -2 + NTP_4_2_7P472 + + ntpdc/invoke-ntpdc.texi@1.464 +2 -2 + NTP_4_2_7P472 + + ntpdc/ntpdc-opts.c@1.482 +7 -7 + NTP_4_2_7P472 + + ntpdc/ntpdc-opts.h@1.481 +3 -3 + NTP_4_2_7P472 + + ntpdc/ntpdc.1ntpdcman@1.295 +3 -3 + NTP_4_2_7P472 + + ntpdc/ntpdc.1ntpdcmdoc@1.295 +2 -2 + NTP_4_2_7P472 + + ntpdc/ntpdc.html@1.308 +2 -2 + NTP_4_2_7P472 + + ntpdc/ntpdc.man.in@1.295 +3 -3 + NTP_4_2_7P472 + + ntpdc/ntpdc.mdoc.in@1.295 +2 -2 + NTP_4_2_7P472 + + ntpq/invoke-ntpq.texi@1.470 +72 -13 + NTP_4_2_7P472 + + ntpq/ntpq-opts.c@1.487 +7 -7 + NTP_4_2_7P472 + + ntpq/ntpq-opts.h@1.485 +3 -3 + NTP_4_2_7P472 + + ntpq/ntpq.1ntpqman@1.298 +119 -15 + NTP_4_2_7P472 + + ntpq/ntpq.1ntpqmdoc@1.298 +92 -14 + NTP_4_2_7P472 + + ntpq/ntpq.html@1.138 +2 -2 + NTP_4_2_7P472 + + ntpq/ntpq.man.in@1.298 +119 -15 + NTP_4_2_7P472 + + ntpq/ntpq.mdoc.in@1.298 +92 -14 + NTP_4_2_7P472 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.466 +2 -2 + NTP_4_2_7P472 + + ntpsnmpd/ntpsnmpd-opts.c@1.484 +7 -7 + NTP_4_2_7P472 + + ntpsnmpd/ntpsnmpd-opts.h@1.483 +3 -3 + NTP_4_2_7P472 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.295 +3 -3 + NTP_4_2_7P472 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.295 +2 -2 + NTP_4_2_7P472 + + ntpsnmpd/ntpsnmpd.html@1.136 +1 -1 + NTP_4_2_7P472 + + ntpsnmpd/ntpsnmpd.man.in@1.295 +3 -3 + NTP_4_2_7P472 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.295 +2 -2 + NTP_4_2_7P472 + + packageinfo.sh@1.476 +1 -1 + NTP_4_2_7P472 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.57 +3 -3 + NTP_4_2_7P472 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.57 +2 -2 + NTP_4_2_7P472 + + scripts/calc_tickadj/calc_tickadj.html@1.59 +1 -1 + NTP_4_2_7P472 + + scripts/calc_tickadj/calc_tickadj.man.in@1.56 +3 -3 + NTP_4_2_7P472 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.57 +2 -2 + NTP_4_2_7P472 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.61 +1 -1 + NTP_4_2_7P472 + + scripts/invoke-plot_summary.texi@1.78 +1 -1 + NTP_4_2_7P472 + + scripts/invoke-summary.texi@1.78 +1 -1 + NTP_4_2_7P472 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.287 +2 -2 + NTP_4_2_7P472 + + scripts/ntp-wait/ntp-wait-opts@1.23 +2 -2 + NTP_4_2_7P472 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.285 +3 -3 + NTP_4_2_7P472 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.285 +2 -2 + NTP_4_2_7P472 + + scripts/ntp-wait/ntp-wait.html@1.304 +2 -2 + NTP_4_2_7P472 + + scripts/ntp-wait/ntp-wait.man.in@1.285 +3 -3 + NTP_4_2_7P472 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.285 +2 -2 + NTP_4_2_7P472 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.76 +2 -2 + NTP_4_2_7P472 + + scripts/ntpsweep/ntpsweep-opts@1.25 +2 -2 + NTP_4_2_7P472 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.64 +3 -3 + NTP_4_2_7P472 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.64 +2 -2 + NTP_4_2_7P472 + + scripts/ntpsweep/ntpsweep.html@1.77 +2 -2 + NTP_4_2_7P472 + + scripts/ntpsweep/ntpsweep.man.in@1.64 +3 -3 + NTP_4_2_7P472 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.65 +2 -2 + NTP_4_2_7P472 + + scripts/ntptrace/invoke-ntptrace.texi@1.76 +2 -2 + NTP_4_2_7P472 + + scripts/ntptrace/ntptrace-opts@1.25 +2 -2 + NTP_4_2_7P472 + + scripts/ntptrace/ntptrace.1ntptraceman@1.64 +3 -3 + NTP_4_2_7P472 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.64 +2 -2 + NTP_4_2_7P472 + + scripts/ntptrace/ntptrace.html@1.77 +2 -2 + NTP_4_2_7P472 + + scripts/ntptrace/ntptrace.man.in@1.64 +3 -3 + NTP_4_2_7P472 + + scripts/ntptrace/ntptrace.mdoc.in@1.65 +2 -2 + NTP_4_2_7P472 + + scripts/plot_summary-opts@1.25 +1 -1 + NTP_4_2_7P472 + + scripts/plot_summary.1plot_summaryman@1.76 +2 -2 + NTP_4_2_7P472 + + scripts/plot_summary.1plot_summarymdoc@1.76 +1 -1 + NTP_4_2_7P472 + + scripts/plot_summary.html@1.79 +2 -2 + NTP_4_2_7P472 + + scripts/plot_summary.man.in@1.76 +2 -2 + NTP_4_2_7P472 + + scripts/plot_summary.mdoc.in@1.76 +1 -1 + NTP_4_2_7P472 + + scripts/summary-opts@1.25 +1 -1 + NTP_4_2_7P472 + + scripts/summary.1summaryman@1.76 +2 -2 + NTP_4_2_7P472 + + scripts/summary.1summarymdoc@1.76 +1 -1 + NTP_4_2_7P472 + + scripts/summary.html@1.79 +2 -2 + NTP_4_2_7P472 + + scripts/summary.man.in@1.76 +2 -2 + NTP_4_2_7P472 + + scripts/summary.mdoc.in@1.76 +1 -1 + NTP_4_2_7P472 + + sntp/invoke-sntp.texi@1.463 +2 -2 + NTP_4_2_7P472 + + sntp/sntp-opts.c@1.481 +7 -7 + NTP_4_2_7P472 + + sntp/sntp-opts.h@1.480 +3 -3 + NTP_4_2_7P472 + + sntp/sntp.1sntpman@1.298 +3 -3 + NTP_4_2_7P472 + + sntp/sntp.1sntpmdoc@1.298 +2 -2 + NTP_4_2_7P472 + + sntp/sntp.html@1.478 +2 -2 + NTP_4_2_7P472 + + sntp/sntp.man.in@1.298 +3 -3 + NTP_4_2_7P472 + + sntp/sntp.mdoc.in@1.298 +2 -2 + NTP_4_2_7P472 + + util/invoke-ntp-keygen.texi@1.467 +2 -2 + NTP_4_2_7P472 + + util/ntp-keygen-opts.c@1.484 +7 -7 + NTP_4_2_7P472 + + util/ntp-keygen-opts.h@1.483 +3 -3 + NTP_4_2_7P472 + + util/ntp-keygen.1ntp-keygenman@1.295 +3 -3 + NTP_4_2_7P472 + + util/ntp-keygen.1ntp-keygenmdoc@1.295 +2 -2 + NTP_4_2_7P472 + + util/ntp-keygen.html@1.142 +2 -2 + NTP_4_2_7P472 + + util/ntp-keygen.man.in@1.295 +3 -3 + NTP_4_2_7P472 + + util/ntp-keygen.mdoc.in@1.295 +2 -2 + NTP_4_2_7P472 + +ChangeSet@1.3210, 2014-09-05 10:34:18+00:00, stenn@psp-deb1.ntp.org + [Bug 2556] mrulist is missing from the generated ntpq man page + + ChangeLog@1.1547 +1 -0 + [Bug 2556] mrulist is missing from the generated ntpq man page + + ntpq/ntpq-opts.def@1.24 +91 -12 + [Bug 2556] mrulist is missing from the generated ntpq man page + +ChangeSet@1.3209, 2014-09-05 08:58:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P471 + TAG: NTP_4_2_7P471 + + ChangeLog@1.1546 +1 -0 + NTP_4_2_7P471 + + ntpd/invoke-ntp.conf.texi@1.151 +1 -1 + NTP_4_2_7P471 + + ntpd/invoke-ntp.keys.texi@1.149 +1 -1 + NTP_4_2_7P471 + + ntpd/invoke-ntpd.texi@1.465 +2 -2 + NTP_4_2_7P471 + + ntpd/ntp.conf.5man@1.185 +3 -3 + NTP_4_2_7P471 + + ntpd/ntp.conf.5mdoc@1.185 +2 -2 + NTP_4_2_7P471 + + ntpd/ntp.conf.html@1.145 +1 -1 + NTP_4_2_7P471 + + ntpd/ntp.conf.man.in@1.185 +3 -3 + NTP_4_2_7P471 + + ntpd/ntp.conf.mdoc.in@1.185 +2 -2 + NTP_4_2_7P471 + + ntpd/ntp.keys.5man@1.183 +2 -2 + NTP_4_2_7P471 + + ntpd/ntp.keys.5mdoc@1.183 +2 -2 + NTP_4_2_7P471 + + ntpd/ntp.keys.html@1.146 +1 -1 + NTP_4_2_7P471 + + ntpd/ntp.keys.man.in@1.183 +2 -2 + NTP_4_2_7P471 + + ntpd/ntp.keys.mdoc.in@1.183 +2 -2 + NTP_4_2_7P471 + + ntpd/ntpd-opts.c@1.486 +7 -7 + NTP_4_2_7P471 + + ntpd/ntpd-opts.h@1.485 +3 -3 + NTP_4_2_7P471 + + ntpd/ntpd.1ntpdman@1.294 +3 -3 + NTP_4_2_7P471 + + ntpd/ntpd.1ntpdmdoc@1.294 +2 -2 + NTP_4_2_7P471 + + ntpd/ntpd.html@1.140 +2 -2 + NTP_4_2_7P471 + + ntpd/ntpd.man.in@1.294 +3 -3 + NTP_4_2_7P471 + + ntpd/ntpd.mdoc.in@1.294 +2 -2 + NTP_4_2_7P471 + + ntpdc/invoke-ntpdc.texi@1.463 +2 -2 + NTP_4_2_7P471 + + ntpdc/ntpdc-opts.c@1.481 +7 -7 + NTP_4_2_7P471 + + ntpdc/ntpdc-opts.h@1.480 +3 -3 + NTP_4_2_7P471 + + ntpdc/ntpdc.1ntpdcman@1.294 +3 -3 + NTP_4_2_7P471 + + ntpdc/ntpdc.1ntpdcmdoc@1.294 +2 -2 + NTP_4_2_7P471 + + ntpdc/ntpdc.html@1.307 +2 -2 + NTP_4_2_7P471 + + ntpdc/ntpdc.man.in@1.294 +3 -3 + NTP_4_2_7P471 + + ntpdc/ntpdc.mdoc.in@1.294 +2 -2 + NTP_4_2_7P471 + + ntpq/invoke-ntpq.texi@1.469 +2 -2 + NTP_4_2_7P471 + + ntpq/ntpq-opts.c@1.486 +7 -7 + NTP_4_2_7P471 + + ntpq/ntpq-opts.h@1.484 +3 -3 + NTP_4_2_7P471 + + ntpq/ntpq.1ntpqman@1.297 +3 -3 + NTP_4_2_7P471 + + ntpq/ntpq.1ntpqmdoc@1.297 +2 -2 + NTP_4_2_7P471 + + ntpq/ntpq.html@1.137 +2 -2 + NTP_4_2_7P471 + + ntpq/ntpq.man.in@1.297 +3 -3 + NTP_4_2_7P471 + + ntpq/ntpq.mdoc.in@1.297 +2 -2 + NTP_4_2_7P471 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.465 +2 -2 + NTP_4_2_7P471 + + ntpsnmpd/ntpsnmpd-opts.c@1.483 +7 -7 + NTP_4_2_7P471 + + ntpsnmpd/ntpsnmpd-opts.h@1.482 +3 -3 + NTP_4_2_7P471 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.294 +3 -3 + NTP_4_2_7P471 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.294 +2 -2 + NTP_4_2_7P471 + + ntpsnmpd/ntpsnmpd.html@1.135 +1 -1 + NTP_4_2_7P471 + + ntpsnmpd/ntpsnmpd.man.in@1.294 +3 -3 + NTP_4_2_7P471 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.294 +2 -2 + NTP_4_2_7P471 + + packageinfo.sh@1.475 +1 -1 + NTP_4_2_7P471 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.56 +3 -3 + NTP_4_2_7P471 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.56 +2 -2 + NTP_4_2_7P471 + + scripts/calc_tickadj/calc_tickadj.html@1.58 +1 -1 + NTP_4_2_7P471 + + scripts/calc_tickadj/calc_tickadj.man.in@1.55 +3 -3 + NTP_4_2_7P471 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.56 +2 -2 + NTP_4_2_7P471 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.60 +1 -1 + NTP_4_2_7P471 + + scripts/invoke-plot_summary.texi@1.77 +1 -1 + NTP_4_2_7P471 + + scripts/invoke-summary.texi@1.77 +1 -1 + NTP_4_2_7P471 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.286 +2 -2 + NTP_4_2_7P471 + + scripts/ntp-wait/ntp-wait-opts@1.22 +2 -2 + NTP_4_2_7P471 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.284 +3 -3 + NTP_4_2_7P471 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.284 +2 -2 + NTP_4_2_7P471 + + scripts/ntp-wait/ntp-wait.html@1.303 +2 -2 + NTP_4_2_7P471 + + scripts/ntp-wait/ntp-wait.man.in@1.284 +3 -3 + NTP_4_2_7P471 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.284 +2 -2 + NTP_4_2_7P471 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.75 +2 -2 + NTP_4_2_7P471 + + scripts/ntpsweep/ntpsweep-opts@1.24 +2 -2 + NTP_4_2_7P471 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.63 +3 -3 + NTP_4_2_7P471 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.63 +2 -2 + NTP_4_2_7P471 + + scripts/ntpsweep/ntpsweep.html@1.76 +2 -2 + NTP_4_2_7P471 + + scripts/ntpsweep/ntpsweep.man.in@1.63 +3 -3 + NTP_4_2_7P471 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.64 +2 -2 + NTP_4_2_7P471 + + scripts/ntptrace/invoke-ntptrace.texi@1.75 +2 -2 + NTP_4_2_7P471 + + scripts/ntptrace/ntptrace-opts@1.24 +2 -2 + NTP_4_2_7P471 + + scripts/ntptrace/ntptrace.1ntptraceman@1.63 +3 -3 + NTP_4_2_7P471 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.63 +2 -2 + NTP_4_2_7P471 + + scripts/ntptrace/ntptrace.html@1.76 +2 -2 + NTP_4_2_7P471 + + scripts/ntptrace/ntptrace.man.in@1.63 +3 -3 + NTP_4_2_7P471 + + scripts/ntptrace/ntptrace.mdoc.in@1.64 +2 -2 + NTP_4_2_7P471 + + scripts/plot_summary-opts@1.24 +1 -1 + NTP_4_2_7P471 + + scripts/plot_summary.1plot_summaryman@1.75 +2 -2 + NTP_4_2_7P471 + + scripts/plot_summary.1plot_summarymdoc@1.75 +1 -1 + NTP_4_2_7P471 + + scripts/plot_summary.html@1.78 +2 -2 + NTP_4_2_7P471 + + scripts/plot_summary.man.in@1.75 +2 -2 + NTP_4_2_7P471 + + scripts/plot_summary.mdoc.in@1.75 +1 -1 + NTP_4_2_7P471 + + scripts/summary-opts@1.24 +1 -1 + NTP_4_2_7P471 + + scripts/summary.1summaryman@1.75 +2 -2 + NTP_4_2_7P471 + + scripts/summary.1summarymdoc@1.75 +1 -1 + NTP_4_2_7P471 + + scripts/summary.html@1.78 +2 -2 + NTP_4_2_7P471 + + scripts/summary.man.in@1.75 +2 -2 + NTP_4_2_7P471 + + scripts/summary.mdoc.in@1.75 +1 -1 + NTP_4_2_7P471 + + sntp/invoke-sntp.texi@1.462 +2 -2 + NTP_4_2_7P471 + + sntp/sntp-opts.c@1.480 +7 -7 + NTP_4_2_7P471 + + sntp/sntp-opts.h@1.479 +3 -3 + NTP_4_2_7P471 + + sntp/sntp.1sntpman@1.297 +3 -3 + NTP_4_2_7P471 + + sntp/sntp.1sntpmdoc@1.297 +2 -2 + NTP_4_2_7P471 + + sntp/sntp.html@1.477 +2 -2 + NTP_4_2_7P471 + + sntp/sntp.man.in@1.297 +3 -3 + NTP_4_2_7P471 + + sntp/sntp.mdoc.in@1.297 +2 -2 + NTP_4_2_7P471 + + util/invoke-ntp-keygen.texi@1.466 +2 -2 + NTP_4_2_7P471 + + util/ntp-keygen-opts.c@1.483 +7 -7 + NTP_4_2_7P471 + + util/ntp-keygen-opts.h@1.482 +3 -3 + NTP_4_2_7P471 + + util/ntp-keygen.1ntp-keygenman@1.294 +3 -3 + NTP_4_2_7P471 + + util/ntp-keygen.1ntp-keygenmdoc@1.294 +2 -2 + NTP_4_2_7P471 + + util/ntp-keygen.html@1.141 +2 -2 + NTP_4_2_7P471 + + util/ntp-keygen.man.in@1.294 +3 -3 + NTP_4_2_7P471 + + util/ntp-keygen.mdoc.in@1.294 +2 -2 + NTP_4_2_7P471 + +ChangeSet@1.3208, 2014-09-05 02:34:19+00:00, stenn@psp-fb1.ntp.org + [Bug 2649] "make install" leaves wrong owner for files in html/ + + ChangeLog@1.1545 +1 -0 + [Bug 2649] "make install" leaves wrong owner for files in html/ + + Makefile.am@1.120 +2 -2 + [Bug 2649] "make install" leaves wrong owner for files in html/ + +ChangeSet@1.3207, 2014-09-05 02:29:49+00:00, stenn@psp-fb1.ntp.org + [Bug 2652] Windows hates directory names that contain a : + + ChangeLog@1.1544 +1 -0 + [Bug 2652] Windows hates directory names that contain a : + + sntp/ag-tpl/0-old/Mdoc.pm@1.4 +0 -0 + Rename: sntp/ag-tpl/:Old/Mdoc.pm -> sntp/ag-tpl/0-old/Mdoc.pm + + sntp/ag-tpl/0-old/agman-cmd.tpl@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/agman-cmd.tpl -> sntp/ag-tpl/0-old/agman-cmd.tpl + + sntp/ag-tpl/0-old/agmdoc-cmd.tpl@1.4 +0 -0 + Rename: sntp/ag-tpl/:Old/agmdoc-cmd.tpl -> sntp/ag-tpl/0-old/agmdoc-cmd.tpl + + sntp/ag-tpl/0-old/cmd-doc.tlib@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/cmd-doc.tlib -> sntp/ag-tpl/0-old/cmd-doc.tlib + + sntp/ag-tpl/0-old/mdoc-synopsis.tlib@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/mdoc-synopsis.tlib -> sntp/ag-tpl/0-old/mdoc-synopsis.tlib + + sntp/ag-tpl/0-old/mdoc2man@1.4 +0 -0 + Rename: sntp/ag-tpl/:Old/mdoc2man -> sntp/ag-tpl/0-old/mdoc2man + + sntp/ag-tpl/0-old/mdoc2texi@1.11 +0 -0 + Rename: sntp/ag-tpl/:Old/mdoc2texi -> sntp/ag-tpl/0-old/mdoc2texi + + sntp/ag-tpl/0-old/perlopt.tpl@1.5 +0 -0 + Rename: sntp/ag-tpl/:Old/perlopt.tpl -> sntp/ag-tpl/0-old/perlopt.tpl + +ChangeSet@1.3206, 2014-09-02 08:58:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P470 + TAG: NTP_4_2_7P470 + + ChangeLog@1.1543 +1 -0 + NTP_4_2_7P470 + + ntpd/invoke-ntp.conf.texi@1.150 +1 -1 + NTP_4_2_7P470 + + ntpd/invoke-ntp.keys.texi@1.148 +1 -1 + NTP_4_2_7P470 + + ntpd/invoke-ntpd.texi@1.464 +2 -2 + NTP_4_2_7P470 + + ntpd/ntp.conf.5man@1.184 +3 -54 + NTP_4_2_7P470 + + ntpd/ntp.conf.5mdoc@1.184 +2 -44 + NTP_4_2_7P470 + + ntpd/ntp.conf.html@1.144 +1 -1 + NTP_4_2_7P470 + + ntpd/ntp.conf.man.in@1.184 +3 -54 + NTP_4_2_7P470 + + ntpd/ntp.conf.mdoc.in@1.184 +2 -44 + NTP_4_2_7P470 + + ntpd/ntp.keys.5man@1.182 +2 -43 + NTP_4_2_7P470 + + ntpd/ntp.keys.5mdoc@1.182 +2 -44 + NTP_4_2_7P470 + + ntpd/ntp.keys.html@1.145 +1 -1 + NTP_4_2_7P470 + + ntpd/ntp.keys.man.in@1.182 +2 -43 + NTP_4_2_7P470 + + ntpd/ntp.keys.mdoc.in@1.182 +2 -44 + NTP_4_2_7P470 + + ntpd/ntpd-opts.c@1.485 +7 -7 + NTP_4_2_7P470 + + ntpd/ntpd-opts.h@1.484 +3 -3 + NTP_4_2_7P470 + + ntpd/ntpd.1ntpdman@1.293 +3 -54 + NTP_4_2_7P470 + + ntpd/ntpd.1ntpdmdoc@1.293 +2 -44 + NTP_4_2_7P470 + + ntpd/ntpd.html@1.139 +2 -2 + NTP_4_2_7P470 + + ntpd/ntpd.man.in@1.293 +3 -54 + NTP_4_2_7P470 + + ntpd/ntpd.mdoc.in@1.293 +2 -44 + NTP_4_2_7P470 + + ntpdc/invoke-ntpdc.texi@1.462 +2 -2 + NTP_4_2_7P470 + + ntpdc/ntpdc-opts.c@1.480 +7 -7 + NTP_4_2_7P470 + + ntpdc/ntpdc-opts.h@1.479 +3 -3 + NTP_4_2_7P470 + + ntpdc/ntpdc.1ntpdcman@1.293 +3 -54 + NTP_4_2_7P470 + + ntpdc/ntpdc.1ntpdcmdoc@1.293 +2 -44 + NTP_4_2_7P470 + + ntpdc/ntpdc.html@1.306 +2 -2 + NTP_4_2_7P470 + + ntpdc/ntpdc.man.in@1.293 +3 -54 + NTP_4_2_7P470 + + ntpdc/ntpdc.mdoc.in@1.293 +2 -44 + NTP_4_2_7P470 + + ntpq/invoke-ntpq.texi@1.468 +2 -2 + NTP_4_2_7P470 + + ntpq/ntpq-opts.c@1.485 +7 -7 + NTP_4_2_7P470 + + ntpq/ntpq-opts.h@1.483 +3 -3 + NTP_4_2_7P470 + + ntpq/ntpq.1ntpqman@1.296 +3 -54 + NTP_4_2_7P470 + + ntpq/ntpq.1ntpqmdoc@1.296 +2 -44 + NTP_4_2_7P470 + + ntpq/ntpq.html@1.136 +2 -2 + NTP_4_2_7P470 + + ntpq/ntpq.man.in@1.296 +3 -54 + NTP_4_2_7P470 + + ntpq/ntpq.mdoc.in@1.296 +2 -44 + NTP_4_2_7P470 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.464 +2 -2 + NTP_4_2_7P470 + + ntpsnmpd/ntpsnmpd-opts.c@1.482 +7 -7 + NTP_4_2_7P470 + + ntpsnmpd/ntpsnmpd-opts.h@1.481 +3 -3 + NTP_4_2_7P470 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.293 +3 -54 + NTP_4_2_7P470 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.293 +2 -44 + NTP_4_2_7P470 + + ntpsnmpd/ntpsnmpd.html@1.134 +1 -1 + NTP_4_2_7P470 + + ntpsnmpd/ntpsnmpd.man.in@1.293 +3 -54 + NTP_4_2_7P470 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.293 +2 -44 + NTP_4_2_7P470 + + packageinfo.sh@1.474 +1 -1 + NTP_4_2_7P470 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.55 +3 -54 + NTP_4_2_7P470 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.55 +2 -44 + NTP_4_2_7P470 + + scripts/calc_tickadj/calc_tickadj.html@1.57 +1 -1 + NTP_4_2_7P470 + + scripts/calc_tickadj/calc_tickadj.man.in@1.54 +3 -54 + NTP_4_2_7P470 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.55 +2 -44 + NTP_4_2_7P470 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.59 +1 -1 + NTP_4_2_7P470 + + scripts/invoke-plot_summary.texi@1.76 +1 -1 + NTP_4_2_7P470 + + scripts/invoke-summary.texi@1.76 +1 -1 + NTP_4_2_7P470 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.285 +2 -2 + NTP_4_2_7P470 + + scripts/ntp-wait/ntp-wait-opts@1.21 +2 -2 + NTP_4_2_7P470 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.283 +3 -54 + NTP_4_2_7P470 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.283 +2 -44 + NTP_4_2_7P470 + + scripts/ntp-wait/ntp-wait.html@1.302 +2 -2 + NTP_4_2_7P470 + + scripts/ntp-wait/ntp-wait.man.in@1.283 +3 -54 + NTP_4_2_7P470 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.283 +2 -44 + NTP_4_2_7P470 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.74 +2 -2 + NTP_4_2_7P470 + + scripts/ntpsweep/ntpsweep-opts@1.23 +2 -2 + NTP_4_2_7P470 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.62 +3 -54 + NTP_4_2_7P470 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.62 +2 -44 + NTP_4_2_7P470 + + scripts/ntpsweep/ntpsweep.html@1.75 +2 -2 + NTP_4_2_7P470 + + scripts/ntpsweep/ntpsweep.man.in@1.62 +3 -54 + NTP_4_2_7P470 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.63 +2 -44 + NTP_4_2_7P470 + + scripts/ntptrace/invoke-ntptrace.texi@1.74 +2 -2 + NTP_4_2_7P470 + + scripts/ntptrace/ntptrace-opts@1.23 +2 -2 + NTP_4_2_7P470 + + scripts/ntptrace/ntptrace.1ntptraceman@1.62 +3 -54 + NTP_4_2_7P470 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.62 +2 -44 + NTP_4_2_7P470 + + scripts/ntptrace/ntptrace.html@1.75 +2 -2 + NTP_4_2_7P470 + + scripts/ntptrace/ntptrace.man.in@1.62 +3 -54 + NTP_4_2_7P470 + + scripts/ntptrace/ntptrace.mdoc.in@1.63 +2 -44 + NTP_4_2_7P470 + + scripts/plot_summary-opts@1.23 +1 -1 + NTP_4_2_7P470 + + scripts/plot_summary.1plot_summaryman@1.74 +2 -54 + NTP_4_2_7P470 + + scripts/plot_summary.1plot_summarymdoc@1.74 +1 -44 + NTP_4_2_7P470 + + scripts/plot_summary.html@1.77 +2 -2 + NTP_4_2_7P470 + + scripts/plot_summary.man.in@1.74 +2 -54 + NTP_4_2_7P470 + + scripts/plot_summary.mdoc.in@1.74 +1 -44 + NTP_4_2_7P470 + + scripts/summary-opts@1.23 +1 -1 + NTP_4_2_7P470 + + scripts/summary.1summaryman@1.74 +2 -53 + NTP_4_2_7P470 + + scripts/summary.1summarymdoc@1.74 +1 -43 + NTP_4_2_7P470 + + scripts/summary.html@1.77 +2 -2 + NTP_4_2_7P470 + + scripts/summary.man.in@1.74 +2 -53 + NTP_4_2_7P470 + + scripts/summary.mdoc.in@1.74 +1 -43 + NTP_4_2_7P470 + + sntp/invoke-sntp.texi@1.461 +2 -2 + NTP_4_2_7P470 + + sntp/sntp-opts.c@1.479 +7 -7 + NTP_4_2_7P470 + + sntp/sntp-opts.h@1.478 +3 -3 + NTP_4_2_7P470 + + sntp/sntp.1sntpman@1.296 +3 -54 + NTP_4_2_7P470 + + sntp/sntp.1sntpmdoc@1.296 +2 -44 + NTP_4_2_7P470 + + sntp/sntp.html@1.476 +2 -2 + NTP_4_2_7P470 + + sntp/sntp.man.in@1.296 +3 -54 + NTP_4_2_7P470 + + sntp/sntp.mdoc.in@1.296 +2 -44 + NTP_4_2_7P470 + + util/invoke-ntp-keygen.texi@1.465 +2 -2 + NTP_4_2_7P470 + + util/ntp-keygen-opts.c@1.482 +7 -7 + NTP_4_2_7P470 + + util/ntp-keygen-opts.h@1.481 +3 -3 + NTP_4_2_7P470 + + util/ntp-keygen.1ntp-keygenman@1.293 +3 -54 + NTP_4_2_7P470 + + util/ntp-keygen.1ntp-keygenmdoc@1.293 +2 -44 + NTP_4_2_7P470 + + util/ntp-keygen.html@1.140 +2 -2 + NTP_4_2_7P470 + + util/ntp-keygen.man.in@1.293 +3 -54 + NTP_4_2_7P470 + + util/ntp-keygen.mdoc.in@1.293 +2 -44 + NTP_4_2_7P470 + +ChangeSet@1.3205, 2014-09-01 23:43:55-04:00, stenn@pogo.udel.edu + html/ cleanups from Hal Murray + + ChangeLog@1.1542 +1 -0 + html/ cleanups from Hal Murray + + html/clockopt.html@1.25 +1 -1 + html/ cleanups from Hal Murray + + html/miscopt.html@1.79 +2 -2 + html/ cleanups from Hal Murray + + html/refclock.html@1.44 +1 -1 + html/ cleanups from Hal Murray + +ChangeSet@1.3204, 2014-09-01 19:13:08-04:00, stenn@deacon.udel.edu + autogen-5.18.5pre1 fixes [Bug 2502] Autogen text replacement errors + + ChangeLog@1.1541 +2 -0 + autogen-5.18.5pre1 fixes [Bug 2502] Autogen text replacement errors + +ChangeSet@1.3203, 2014-09-01 08:58:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P469 + TAG: NTP_4_2_7P469 + + ChangeLog@1.1540 +1 -0 + NTP_4_2_7P469 + + ntpd/invoke-ntp.conf.texi@1.149 +1 -1 + NTP_4_2_7P469 + + ntpd/invoke-ntp.keys.texi@1.147 +1 -1 + NTP_4_2_7P469 + + ntpd/invoke-ntpd.texi@1.463 +2 -2 + NTP_4_2_7P469 + + ntpd/ntp.conf.5man@1.183 +16 -6 + NTP_4_2_7P469 + + ntpd/ntp.conf.5mdoc@1.183 +12 -2 + NTP_4_2_7P469 + + ntpd/ntp.conf.html@1.143 +1 -1 + NTP_4_2_7P469 + + ntpd/ntp.conf.man.in@1.183 +16 -6 + NTP_4_2_7P469 + + ntpd/ntp.conf.mdoc.in@1.183 +12 -2 + NTP_4_2_7P469 + + ntpd/ntp.keys.5man@1.181 +12 -2 + NTP_4_2_7P469 + + ntpd/ntp.keys.5mdoc@1.181 +12 -2 + NTP_4_2_7P469 + + ntpd/ntp.keys.html@1.144 +1 -1 + NTP_4_2_7P469 + + ntpd/ntp.keys.man.in@1.181 +12 -2 + NTP_4_2_7P469 + + ntpd/ntp.keys.mdoc.in@1.181 +12 -2 + NTP_4_2_7P469 + + ntpd/ntpd-opts.c@1.484 +7 -7 + NTP_4_2_7P469 + + ntpd/ntpd-opts.h@1.483 +3 -3 + NTP_4_2_7P469 + + ntpd/ntpd.1ntpdman@1.292 +16 -6 + NTP_4_2_7P469 + + ntpd/ntpd.1ntpdmdoc@1.292 +12 -2 + NTP_4_2_7P469 + + ntpd/ntpd.html@1.138 +4 -4 + NTP_4_2_7P469 + + ntpd/ntpd.man.in@1.292 +16 -6 + NTP_4_2_7P469 + + ntpd/ntpd.mdoc.in@1.292 +12 -2 + NTP_4_2_7P469 + + ntpdc/invoke-ntpdc.texi@1.461 +2 -2 + NTP_4_2_7P469 + + ntpdc/ntpdc-opts.c@1.479 +7 -7 + NTP_4_2_7P469 + + ntpdc/ntpdc-opts.h@1.478 +3 -3 + NTP_4_2_7P469 + + ntpdc/ntpdc.1ntpdcman@1.292 +16 -6 + NTP_4_2_7P469 + + ntpdc/ntpdc.1ntpdcmdoc@1.292 +12 -2 + NTP_4_2_7P469 + + ntpdc/ntpdc.html@1.305 +2 -2 + NTP_4_2_7P469 + + ntpdc/ntpdc.man.in@1.292 +16 -6 + NTP_4_2_7P469 + + ntpdc/ntpdc.mdoc.in@1.292 +12 -2 + NTP_4_2_7P469 + + ntpq/invoke-ntpq.texi@1.467 +2 -2 + NTP_4_2_7P469 + + ntpq/ntpq-opts.c@1.484 +7 -7 + NTP_4_2_7P469 + + ntpq/ntpq-opts.h@1.482 +3 -3 + NTP_4_2_7P469 + + ntpq/ntpq.1ntpqman@1.295 +16 -6 + NTP_4_2_7P469 + + ntpq/ntpq.1ntpqmdoc@1.295 +12 -2 + NTP_4_2_7P469 + + ntpq/ntpq.html@1.135 +2 -2 + NTP_4_2_7P469 + + ntpq/ntpq.man.in@1.295 +16 -6 + NTP_4_2_7P469 + + ntpq/ntpq.mdoc.in@1.295 +12 -2 + NTP_4_2_7P469 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.463 +2 -2 + NTP_4_2_7P469 + + ntpsnmpd/ntpsnmpd-opts.c@1.481 +7 -7 + NTP_4_2_7P469 + + ntpsnmpd/ntpsnmpd-opts.h@1.480 +3 -3 + NTP_4_2_7P469 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.292 +23 -13 + NTP_4_2_7P469 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.292 +12 -2 + NTP_4_2_7P469 + + ntpsnmpd/ntpsnmpd.html@1.133 +1 -1 + NTP_4_2_7P469 + + ntpsnmpd/ntpsnmpd.man.in@1.292 +23 -13 + NTP_4_2_7P469 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.292 +12 -2 + NTP_4_2_7P469 + + packageinfo.sh@1.473 +1 -1 + NTP_4_2_7P469 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.54 +16 -6 + NTP_4_2_7P469 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.54 +12 -2 + NTP_4_2_7P469 + + scripts/calc_tickadj/calc_tickadj.html@1.56 +1 -1 + NTP_4_2_7P469 + + scripts/calc_tickadj/calc_tickadj.man.in@1.53 +16 -6 + NTP_4_2_7P469 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.54 +12 -2 + NTP_4_2_7P469 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.58 +1 -1 + NTP_4_2_7P469 + + scripts/invoke-plot_summary.texi@1.75 +1 -1 + NTP_4_2_7P469 + + scripts/invoke-summary.texi@1.75 +1 -1 + NTP_4_2_7P469 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.284 +2 -2 + NTP_4_2_7P469 + + scripts/ntp-wait/ntp-wait-opts@1.20 +2 -2 + NTP_4_2_7P469 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.282 +16 -6 + NTP_4_2_7P469 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.282 +12 -2 + NTP_4_2_7P469 + + scripts/ntp-wait/ntp-wait.html@1.301 +2 -2 + NTP_4_2_7P469 + + scripts/ntp-wait/ntp-wait.man.in@1.282 +16 -6 + NTP_4_2_7P469 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.282 +12 -2 + NTP_4_2_7P469 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.73 +2 -2 + NTP_4_2_7P469 + + scripts/ntpsweep/ntpsweep-opts@1.22 +2 -2 + NTP_4_2_7P469 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.61 +16 -6 + NTP_4_2_7P469 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.61 +12 -2 + NTP_4_2_7P469 + + scripts/ntpsweep/ntpsweep.html@1.74 +2 -2 + NTP_4_2_7P469 + + scripts/ntpsweep/ntpsweep.man.in@1.61 +16 -6 + NTP_4_2_7P469 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.62 +12 -2 + NTP_4_2_7P469 + + scripts/ntptrace/invoke-ntptrace.texi@1.73 +2 -2 + NTP_4_2_7P469 + + scripts/ntptrace/ntptrace-opts@1.22 +2 -2 + NTP_4_2_7P469 + + scripts/ntptrace/ntptrace.1ntptraceman@1.61 +23 -13 + NTP_4_2_7P469 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.61 +12 -2 + NTP_4_2_7P469 + + scripts/ntptrace/ntptrace.html@1.74 +2 -2 + NTP_4_2_7P469 + + scripts/ntptrace/ntptrace.man.in@1.61 +23 -13 + NTP_4_2_7P469 + + scripts/ntptrace/ntptrace.mdoc.in@1.62 +12 -2 + NTP_4_2_7P469 + + scripts/plot_summary-opts@1.22 +1 -1 + NTP_4_2_7P469 + + scripts/plot_summary.1plot_summaryman@1.73 +14 -4 + NTP_4_2_7P469 + + scripts/plot_summary.1plot_summarymdoc@1.73 +11 -1 + NTP_4_2_7P469 + + scripts/plot_summary.html@1.76 +2 -2 + NTP_4_2_7P469 + + scripts/plot_summary.man.in@1.73 +14 -4 + NTP_4_2_7P469 + + scripts/plot_summary.mdoc.in@1.73 +11 -1 + NTP_4_2_7P469 + + scripts/summary-opts@1.22 +1 -1 + NTP_4_2_7P469 + + scripts/summary.1summaryman@1.73 +14 -4 + NTP_4_2_7P469 + + scripts/summary.1summarymdoc@1.73 +11 -1 + NTP_4_2_7P469 + + scripts/summary.html@1.76 +2 -2 + NTP_4_2_7P469 + + scripts/summary.man.in@1.73 +14 -4 + NTP_4_2_7P469 + + scripts/summary.mdoc.in@1.73 +11 -1 + NTP_4_2_7P469 + + sntp/invoke-sntp.texi@1.460 +2 -2 + NTP_4_2_7P469 + + sntp/sntp-opts.c@1.478 +7 -7 + NTP_4_2_7P469 + + sntp/sntp-opts.h@1.477 +3 -3 + NTP_4_2_7P469 + + sntp/sntp.1sntpman@1.295 +16 -6 + NTP_4_2_7P469 + + sntp/sntp.1sntpmdoc@1.295 +12 -2 + NTP_4_2_7P469 + + sntp/sntp.html@1.475 +2 -2 + NTP_4_2_7P469 + + sntp/sntp.man.in@1.295 +16 -6 + NTP_4_2_7P469 + + sntp/sntp.mdoc.in@1.295 +12 -2 + NTP_4_2_7P469 + + util/invoke-ntp-keygen.texi@1.464 +2 -2 + NTP_4_2_7P469 + + util/ntp-keygen-opts.c@1.481 +7 -7 + NTP_4_2_7P469 + + util/ntp-keygen-opts.h@1.480 +3 -3 + NTP_4_2_7P469 + + util/ntp-keygen.1ntp-keygenman@1.292 +16 -6 + NTP_4_2_7P469 + + util/ntp-keygen.1ntp-keygenmdoc@1.292 +12 -2 + NTP_4_2_7P469 + + util/ntp-keygen.html@1.139 +2 -2 + NTP_4_2_7P469 + + util/ntp-keygen.man.in@1.292 +16 -6 + NTP_4_2_7P469 + + util/ntp-keygen.mdoc.in@1.292 +12 -2 + NTP_4_2_7P469 + +ChangeSet@1.3202, 2014-09-01 03:12:34+00:00, stenn@psp-deb1.ntp.org + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + ChangeLog@1.1539 +1 -0 + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + ntpd/ntpd.c@1.156 +2 -2 + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + +ChangeSet@1.3201, 2014-08-31 09:00:12+00:00, stenn@deacon.udel.edu + NTP_4_2_7P468 + TAG: NTP_4_2_7P468 + + ChangeLog@1.1538 +1 -0 + NTP_4_2_7P468 + + ntpd/invoke-ntp.conf.texi@1.148 +1 -1 + NTP_4_2_7P468 + + ntpd/invoke-ntp.keys.texi@1.146 +1 -1 + NTP_4_2_7P468 + + ntpd/invoke-ntpd.texi@1.462 +4 -4 + NTP_4_2_7P468 + + ntpd/ntp.conf.5man@1.182 +44 -3 + NTP_4_2_7P468 + + ntpd/ntp.conf.5mdoc@1.182 +32 -1 + NTP_4_2_7P468 + + ntpd/ntp.conf.html@1.142 +1 -1 + NTP_4_2_7P468 + + ntpd/ntp.conf.man.in@1.182 +44 -3 + NTP_4_2_7P468 + + ntpd/ntp.conf.mdoc.in@1.182 +32 -1 + NTP_4_2_7P468 + + ntpd/ntp.keys.5man@1.180 +33 -2 + NTP_4_2_7P468 + + ntpd/ntp.keys.5mdoc@1.180 +33 -2 + NTP_4_2_7P468 + + ntpd/ntp.keys.html@1.143 +1 -1 + NTP_4_2_7P468 + + ntpd/ntp.keys.man.in@1.180 +33 -2 + NTP_4_2_7P468 + + ntpd/ntp.keys.mdoc.in@1.180 +33 -2 + NTP_4_2_7P468 + + ntpd/ntpd-opts.c@1.483 +7 -7 + NTP_4_2_7P468 + + ntpd/ntpd-opts.h@1.482 +3 -3 + NTP_4_2_7P468 + + ntpd/ntpd.1ntpdman@1.291 +44 -3 + NTP_4_2_7P468 + + ntpd/ntpd.1ntpdmdoc@1.291 +32 -1 + NTP_4_2_7P468 + + ntpd/ntpd.html@1.137 +4 -4 + NTP_4_2_7P468 + + ntpd/ntpd.man.in@1.291 +44 -3 + NTP_4_2_7P468 + + ntpd/ntpd.mdoc.in@1.291 +32 -1 + NTP_4_2_7P468 + + ntpdc/invoke-ntpdc.texi@1.460 +2 -2 + NTP_4_2_7P468 + + ntpdc/ntpdc-opts.c@1.478 +7 -7 + NTP_4_2_7P468 + + ntpdc/ntpdc-opts.h@1.477 +3 -3 + NTP_4_2_7P468 + + ntpdc/ntpdc.1ntpdcman@1.291 +44 -3 + NTP_4_2_7P468 + + ntpdc/ntpdc.1ntpdcmdoc@1.291 +32 -1 + NTP_4_2_7P468 + + ntpdc/ntpdc.html@1.304 +57 -77 + NTP_4_2_7P468 + + ntpdc/ntpdc.man.in@1.291 +44 -3 + NTP_4_2_7P468 + + ntpdc/ntpdc.mdoc.in@1.291 +32 -1 + NTP_4_2_7P468 + + ntpq/invoke-ntpq.texi@1.466 +2 -2 + NTP_4_2_7P468 + + ntpq/ntpq-opts.c@1.483 +7 -7 + NTP_4_2_7P468 + + ntpq/ntpq-opts.h@1.481 +3 -3 + NTP_4_2_7P468 + + ntpq/ntpq.1ntpqman@1.294 +44 -3 + NTP_4_2_7P468 + + ntpq/ntpq.1ntpqmdoc@1.294 +32 -1 + NTP_4_2_7P468 + + ntpq/ntpq.html@1.134 +3 -3 + NTP_4_2_7P468 + + ntpq/ntpq.man.in@1.294 +44 -3 + NTP_4_2_7P468 + + ntpq/ntpq.mdoc.in@1.294 +32 -1 + NTP_4_2_7P468 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.462 +2 -2 + NTP_4_2_7P468 + + ntpsnmpd/ntpsnmpd-opts.c@1.480 +7 -7 + NTP_4_2_7P468 + + ntpsnmpd/ntpsnmpd-opts.h@1.479 +3 -3 + NTP_4_2_7P468 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.291 +44 -3 + NTP_4_2_7P468 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.291 +32 -1 + NTP_4_2_7P468 + + ntpsnmpd/ntpsnmpd.html@1.132 +1 -1 + NTP_4_2_7P468 + + ntpsnmpd/ntpsnmpd.man.in@1.291 +44 -3 + NTP_4_2_7P468 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.291 +32 -1 + NTP_4_2_7P468 + + packageinfo.sh@1.472 +1 -1 + NTP_4_2_7P468 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.53 +44 -3 + NTP_4_2_7P468 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.53 +32 -1 + NTP_4_2_7P468 + + scripts/calc_tickadj/calc_tickadj.html@1.55 +23 -35 + NTP_4_2_7P468 + + scripts/calc_tickadj/calc_tickadj.man.in@1.52 +44 -3 + NTP_4_2_7P468 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.53 +32 -1 + NTP_4_2_7P468 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.57 +2 -2 + NTP_4_2_7P468 + + scripts/invoke-plot_summary.texi@1.74 +1 -1 + NTP_4_2_7P468 + + scripts/invoke-summary.texi@1.74 +1 -1 + NTP_4_2_7P468 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.283 +2 -2 + NTP_4_2_7P468 + + scripts/ntp-wait/ntp-wait-opts@1.19 +2 -2 + NTP_4_2_7P468 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.281 +44 -3 + NTP_4_2_7P468 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.281 +32 -1 + NTP_4_2_7P468 + + scripts/ntp-wait/ntp-wait.html@1.300 +31 -49 + NTP_4_2_7P468 + + scripts/ntp-wait/ntp-wait.man.in@1.281 +44 -3 + NTP_4_2_7P468 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.281 +32 -1 + NTP_4_2_7P468 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.72 +2 -2 + NTP_4_2_7P468 + + scripts/ntpsweep/ntpsweep-opts@1.21 +2 -2 + NTP_4_2_7P468 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.60 +44 -3 + NTP_4_2_7P468 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.60 +32 -1 + NTP_4_2_7P468 + + scripts/ntpsweep/ntpsweep.html@1.73 +33 -44 + NTP_4_2_7P468 + + scripts/ntpsweep/ntpsweep.man.in@1.60 +44 -3 + NTP_4_2_7P468 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.61 +32 -1 + NTP_4_2_7P468 + + scripts/ntptrace/invoke-ntptrace.texi@1.72 +2 -2 + NTP_4_2_7P468 + + scripts/ntptrace/ntptrace-opts@1.21 +2 -2 + NTP_4_2_7P468 + + scripts/ntptrace/ntptrace.1ntptraceman@1.60 +44 -3 + NTP_4_2_7P468 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.60 +32 -1 + NTP_4_2_7P468 + + scripts/ntptrace/ntptrace.html@1.73 +27 -36 + NTP_4_2_7P468 + + scripts/ntptrace/ntptrace.man.in@1.60 +44 -3 + NTP_4_2_7P468 + + scripts/ntptrace/ntptrace.mdoc.in@1.61 +32 -1 + NTP_4_2_7P468 + + scripts/plot_summary-opts@1.21 +1 -1 + NTP_4_2_7P468 + + scripts/plot_summary.1plot_summaryman@1.72 +44 -2 + NTP_4_2_7P468 + + scripts/plot_summary.1plot_summarymdoc@1.72 +32 -0 + NTP_4_2_7P468 + + scripts/plot_summary.html@1.75 +29 -47 + NTP_4_2_7P468 + + scripts/plot_summary.man.in@1.72 +44 -2 + NTP_4_2_7P468 + + scripts/plot_summary.mdoc.in@1.72 +32 -0 + NTP_4_2_7P468 + + scripts/summary-opts@1.21 +1 -1 + NTP_4_2_7P468 + + scripts/summary.1summaryman@1.72 +43 -2 + NTP_4_2_7P468 + + scripts/summary.1summarymdoc@1.72 +31 -0 + NTP_4_2_7P468 + + scripts/summary.html@1.75 +27 -39 + NTP_4_2_7P468 + + scripts/summary.man.in@1.72 +43 -2 + NTP_4_2_7P468 + + scripts/summary.mdoc.in@1.72 +31 -0 + NTP_4_2_7P468 + + sntp/invoke-sntp.texi@1.459 +2 -2 + NTP_4_2_7P468 + + sntp/sntp-opts.c@1.477 +7 -7 + NTP_4_2_7P468 + + sntp/sntp-opts.h@1.476 +3 -3 + NTP_4_2_7P468 + + sntp/sntp.1sntpman@1.294 +44 -3 + NTP_4_2_7P468 + + sntp/sntp.1sntpmdoc@1.294 +32 -1 + NTP_4_2_7P468 + + sntp/sntp.html@1.474 +85 -109 + NTP_4_2_7P468 + + sntp/sntp.man.in@1.294 +44 -3 + NTP_4_2_7P468 + + sntp/sntp.mdoc.in@1.294 +32 -1 + NTP_4_2_7P468 + + util/invoke-ntp-keygen.texi@1.463 +2 -2 + NTP_4_2_7P468 + + util/ntp-keygen-opts.c@1.480 +7 -7 + NTP_4_2_7P468 + + util/ntp-keygen-opts.h@1.479 +3 -3 + NTP_4_2_7P468 + + util/ntp-keygen.1ntp-keygenman@1.291 +44 -3 + NTP_4_2_7P468 + + util/ntp-keygen.1ntp-keygenmdoc@1.291 +32 -1 + NTP_4_2_7P468 + + util/ntp-keygen.html@1.138 +2 -2 + NTP_4_2_7P468 + + util/ntp-keygen.man.in@1.291 +44 -3 + NTP_4_2_7P468 + + util/ntp-keygen.mdoc.in@1.291 +32 -1 + NTP_4_2_7P468 + +ChangeSet@1.3200, 2014-08-31 05:07:43+00:00, stenn@psp-fb1.ntp.org + autogen-5.18.4 + + ChangeLog@1.1537 +1 -0 + autogen-5.18.4 + + ntpd/invoke-ntp.conf.texi@1.147 +1 -1 + autogen-5.18.4 + + ntpd/invoke-ntp.keys.texi@1.145 +1 -1 + autogen-5.18.4 + + ntpd/invoke-ntpd.texi@1.461 +3 -3 + autogen-5.18.4 + + ntpd/ntp.conf.5man@1.181 +3 -32 + autogen-5.18.4 + + ntpd/ntp.conf.5mdoc@1.181 +3 -21 + autogen-5.18.4 + + ntpd/ntp.conf.man.in@1.181 +3 -32 + autogen-5.18.4 + + ntpd/ntp.conf.mdoc.in@1.181 +3 -21 + autogen-5.18.4 + + ntpd/ntp.keys.5man@1.179 +2 -21 + autogen-5.18.4 + + ntpd/ntp.keys.5mdoc@1.179 +4 -22 + autogen-5.18.4 + + ntpd/ntp.keys.man.in@1.179 +2 -21 + autogen-5.18.4 + + ntpd/ntp.keys.mdoc.in@1.179 +4 -22 + autogen-5.18.4 + + ntpd/ntpd-opts.c@1.482 +1 -1 + autogen-5.18.4 + + ntpd/ntpd-opts.h@1.481 +1 -1 + autogen-5.18.4 + + ntpd/ntpd.1ntpdman@1.290 +3 -32 + autogen-5.18.4 + + ntpd/ntpd.1ntpdmdoc@1.290 +3 -21 + autogen-5.18.4 + + ntpd/ntpd.man.in@1.290 +3 -32 + autogen-5.18.4 + + ntpd/ntpd.mdoc.in@1.290 +3 -21 + autogen-5.18.4 + + ntpdc/invoke-ntpdc.texi@1.459 +1 -1 + autogen-5.18.4 + + ntpdc/ntpdc-opts.c@1.477 +1 -1 + autogen-5.18.4 + + ntpdc/ntpdc-opts.h@1.476 +1 -1 + autogen-5.18.4 + + ntpdc/ntpdc.1ntpdcman@1.290 +3 -32 + autogen-5.18.4 + + ntpdc/ntpdc.1ntpdcmdoc@1.290 +3 -21 + autogen-5.18.4 + + ntpdc/ntpdc.html@1.303 +75 -55 + autogen-5.18.4 + + ntpdc/ntpdc.man.in@1.290 +3 -32 + autogen-5.18.4 + + ntpdc/ntpdc.mdoc.in@1.290 +3 -21 + autogen-5.18.4 + + ntpq/invoke-ntpq.texi@1.465 +2 -2 + autogen-5.18.4 + + ntpq/ntpq-opts.c@1.482 +1 -1 + autogen-5.18.4 + + ntpq/ntpq-opts.h@1.480 +1 -1 + autogen-5.18.4 + + ntpq/ntpq.1ntpqman@1.293 +4 -33 + autogen-5.18.4 + + ntpq/ntpq.1ntpqmdoc@1.293 +4 -22 + autogen-5.18.4 + + ntpq/ntpq.man.in@1.293 +4 -33 + autogen-5.18.4 + + ntpq/ntpq.mdoc.in@1.293 +4 -22 + autogen-5.18.4 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.461 +1 -1 + autogen-5.18.4 + + ntpsnmpd/ntpsnmpd-opts.c@1.479 +1 -1 + autogen-5.18.4 + + ntpsnmpd/ntpsnmpd-opts.h@1.478 +1 -1 + autogen-5.18.4 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.290 +3 -32 + autogen-5.18.4 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.290 +3 -21 + autogen-5.18.4 + + ntpsnmpd/ntpsnmpd.man.in@1.290 +3 -32 + autogen-5.18.4 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.290 +3 -21 + autogen-5.18.4 + + scripts/calc_tickadj/calc_tickadj-opts@1.9 +2 -2 + autogen-5.18.4 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.52 +3 -32 + autogen-5.18.4 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.52 +3 -21 + autogen-5.18.4 + + scripts/calc_tickadj/calc_tickadj.html@1.54 +33 -21 + autogen-5.18.4 + + scripts/calc_tickadj/calc_tickadj.man.in@1.51 +3 -32 + autogen-5.18.4 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.52 +3 -21 + autogen-5.18.4 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.56 +1 -1 + autogen-5.18.4 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.282 +1 -1 + autogen-5.18.4 + + scripts/ntp-wait/ntp-wait-opts@1.18 +1 -1 + autogen-5.18.4 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.280 +3 -32 + autogen-5.18.4 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.280 +3 -21 + autogen-5.18.4 + + scripts/ntp-wait/ntp-wait.html@1.299 +47 -29 + autogen-5.18.4 + + scripts/ntp-wait/ntp-wait.man.in@1.280 +3 -32 + autogen-5.18.4 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.280 +3 -21 + autogen-5.18.4 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.71 +1 -1 + autogen-5.18.4 + + scripts/ntpsweep/ntpsweep-opts@1.20 +1 -1 + autogen-5.18.4 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.59 +3 -32 + autogen-5.18.4 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.59 +3 -21 + autogen-5.18.4 + + scripts/ntpsweep/ntpsweep.html@1.72 +42 -31 + autogen-5.18.4 + + scripts/ntpsweep/ntpsweep.man.in@1.59 +3 -32 + autogen-5.18.4 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.60 +3 -21 + autogen-5.18.4 + + scripts/ntptrace/invoke-ntptrace.texi@1.71 +1 -1 + autogen-5.18.4 + + scripts/ntptrace/ntptrace-opts@1.20 +1 -1 + autogen-5.18.4 + + scripts/ntptrace/ntptrace.1ntptraceman@1.59 +3 -32 + autogen-5.18.4 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.59 +3 -21 + autogen-5.18.4 + + scripts/ntptrace/ntptrace.html@1.72 +34 -25 + autogen-5.18.4 + + scripts/ntptrace/ntptrace.man.in@1.59 +3 -32 + autogen-5.18.4 + + scripts/ntptrace/ntptrace.mdoc.in@1.60 +3 -21 + autogen-5.18.4 + + scripts/plot_summary.1plot_summaryman@1.71 +2 -32 + autogen-5.18.4 + + scripts/plot_summary.1plot_summarymdoc@1.71 +2 -21 + autogen-5.18.4 + + scripts/plot_summary.html@1.74 +45 -27 + autogen-5.18.4 + + scripts/plot_summary.man.in@1.71 +2 -32 + autogen-5.18.4 + + scripts/plot_summary.mdoc.in@1.71 +2 -21 + autogen-5.18.4 + + scripts/summary.1summaryman@1.71 +2 -31 + autogen-5.18.4 + + scripts/summary.1summarymdoc@1.71 +2 -20 + autogen-5.18.4 + + scripts/summary.html@1.74 +37 -25 + autogen-5.18.4 + + scripts/summary.man.in@1.71 +2 -31 + autogen-5.18.4 + + scripts/summary.mdoc.in@1.71 +2 -20 + autogen-5.18.4 + + sntp/include/autogen-version.def@1.21 +2 -2 + autogen-5.18.4 + + sntp/invoke-sntp.texi@1.458 +1 -1 + autogen-5.18.4 + + sntp/sntp-opts.c@1.476 +1 -1 + autogen-5.18.4 + + sntp/sntp-opts.h@1.475 +1 -1 + autogen-5.18.4 + + sntp/sntp.1sntpman@1.293 +3 -32 + autogen-5.18.4 + + sntp/sntp.1sntpmdoc@1.293 +3 -21 + autogen-5.18.4 + + sntp/sntp.html@1.473 +107 -83 + autogen-5.18.4 + + sntp/sntp.man.in@1.293 +3 -32 + autogen-5.18.4 + + sntp/sntp.mdoc.in@1.293 +3 -21 + autogen-5.18.4 + + util/invoke-ntp-keygen.texi@1.462 +1 -1 + autogen-5.18.4 + + util/ntp-keygen-opts.c@1.479 +1 -1 + autogen-5.18.4 + + util/ntp-keygen-opts.h@1.478 +1 -1 + autogen-5.18.4 + + util/ntp-keygen.1ntp-keygenman@1.290 +3 -32 + autogen-5.18.4 + + util/ntp-keygen.1ntp-keygenmdoc@1.290 +3 -21 + autogen-5.18.4 + + util/ntp-keygen.man.in@1.290 +3 -32 + autogen-5.18.4 + + util/ntp-keygen.mdoc.in@1.290 +3 -21 + autogen-5.18.4 + +ChangeSet@1.3199, 2014-08-31 04:47:39+00:00, stenn@psp-fb1.ntp.org + [Bug 2556] ntpq man page cleanup + + ChangeLog@1.1536 +1 -0 + [Bug 2556] ntpq man page cleanup + + ntpq/ntpq-opts.def@1.23 +1 -1 + [Bug 2556] ntpq man page cleanup + +ChangeSet@1.3198, 2014-08-28 08:58:35+00:00, stenn@deacon.udel.edu + NTP_4_2_7P467 + TAG: NTP_4_2_7P467 + + ChangeLog@1.1535 +1 -0 + NTP_4_2_7P467 + + ntpd/invoke-ntp.conf.texi@1.146 +1 -1 + NTP_4_2_7P467 + + ntpd/invoke-ntp.keys.texi@1.144 +1 -1 + NTP_4_2_7P467 + + ntpd/invoke-ntpd.texi@1.460 +2 -2 + NTP_4_2_7P467 + + ntpd/ntp.conf.5man@1.180 +6 -6 + NTP_4_2_7P467 + + ntpd/ntp.conf.5mdoc@1.180 +2 -2 + NTP_4_2_7P467 + + ntpd/ntp.conf.html@1.141 +1 -1 + NTP_4_2_7P467 + + ntpd/ntp.conf.man.in@1.180 +6 -6 + NTP_4_2_7P467 + + ntpd/ntp.conf.mdoc.in@1.180 +2 -2 + NTP_4_2_7P467 + + ntpd/ntp.keys.5man@1.178 +2 -2 + NTP_4_2_7P467 + + ntpd/ntp.keys.5mdoc@1.178 +2 -2 + NTP_4_2_7P467 + + ntpd/ntp.keys.html@1.142 +1 -1 + NTP_4_2_7P467 + + ntpd/ntp.keys.man.in@1.178 +2 -2 + NTP_4_2_7P467 + + ntpd/ntp.keys.mdoc.in@1.178 +2 -2 + NTP_4_2_7P467 + + ntpd/ntpd-opts.c@1.481 +7 -7 + NTP_4_2_7P467 + + ntpd/ntpd-opts.h@1.480 +3 -3 + NTP_4_2_7P467 + + ntpd/ntpd.1ntpdman@1.289 +6 -6 + NTP_4_2_7P467 + + ntpd/ntpd.1ntpdmdoc@1.289 +2 -2 + NTP_4_2_7P467 + + ntpd/ntpd.html@1.136 +2 -2 + NTP_4_2_7P467 + + ntpd/ntpd.man.in@1.289 +6 -6 + NTP_4_2_7P467 + + ntpd/ntpd.mdoc.in@1.289 +2 -2 + NTP_4_2_7P467 + + ntpdc/invoke-ntpdc.texi@1.458 +2 -2 + NTP_4_2_7P467 + + ntpdc/ntpdc-opts.c@1.476 +7 -7 + NTP_4_2_7P467 + + ntpdc/ntpdc-opts.h@1.475 +3 -3 + NTP_4_2_7P467 + + ntpdc/ntpdc.1ntpdcman@1.289 +6 -6 + NTP_4_2_7P467 + + ntpdc/ntpdc.1ntpdcmdoc@1.289 +2 -2 + NTP_4_2_7P467 + + ntpdc/ntpdc.html@1.302 +2 -2 + NTP_4_2_7P467 + + ntpdc/ntpdc.man.in@1.289 +6 -6 + NTP_4_2_7P467 + + ntpdc/ntpdc.mdoc.in@1.289 +2 -2 + NTP_4_2_7P467 + + ntpq/invoke-ntpq.texi@1.464 +2 -2 + NTP_4_2_7P467 + + ntpq/ntpq-opts.c@1.481 +7 -7 + NTP_4_2_7P467 + + ntpq/ntpq-opts.h@1.479 +3 -3 + NTP_4_2_7P467 + + ntpq/ntpq.1ntpqman@1.292 +6 -6 + NTP_4_2_7P467 + + ntpq/ntpq.1ntpqmdoc@1.292 +2 -2 + NTP_4_2_7P467 + + ntpq/ntpq.html@1.133 +2 -2 + NTP_4_2_7P467 + + ntpq/ntpq.man.in@1.292 +6 -6 + NTP_4_2_7P467 + + ntpq/ntpq.mdoc.in@1.292 +2 -2 + NTP_4_2_7P467 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.460 +2 -2 + NTP_4_2_7P467 + + ntpsnmpd/ntpsnmpd-opts.c@1.478 +7 -7 + NTP_4_2_7P467 + + ntpsnmpd/ntpsnmpd-opts.h@1.477 +3 -3 + NTP_4_2_7P467 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.289 +6 -6 + NTP_4_2_7P467 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.289 +2 -2 + NTP_4_2_7P467 + + ntpsnmpd/ntpsnmpd.html@1.131 +1 -1 + NTP_4_2_7P467 + + ntpsnmpd/ntpsnmpd.man.in@1.289 +6 -6 + NTP_4_2_7P467 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.289 +2 -2 + NTP_4_2_7P467 + + packageinfo.sh@1.471 +1 -1 + NTP_4_2_7P467 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.51 +6 -6 + NTP_4_2_7P467 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.51 +2 -2 + NTP_4_2_7P467 + + scripts/calc_tickadj/calc_tickadj.html@1.53 +1 -1 + NTP_4_2_7P467 + + scripts/calc_tickadj/calc_tickadj.man.in@1.50 +6 -6 + NTP_4_2_7P467 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.51 +2 -2 + NTP_4_2_7P467 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.55 +1 -1 + NTP_4_2_7P467 + + scripts/invoke-plot_summary.texi@1.73 +1 -1 + NTP_4_2_7P467 + + scripts/invoke-summary.texi@1.73 +1 -1 + NTP_4_2_7P467 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.281 +2 -2 + NTP_4_2_7P467 + + scripts/ntp-wait/ntp-wait-opts@1.17 +2 -2 + NTP_4_2_7P467 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.279 +6 -6 + NTP_4_2_7P467 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.279 +2 -2 + NTP_4_2_7P467 + + scripts/ntp-wait/ntp-wait.html@1.298 +2 -2 + NTP_4_2_7P467 + + scripts/ntp-wait/ntp-wait.man.in@1.279 +6 -6 + NTP_4_2_7P467 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.279 +2 -2 + NTP_4_2_7P467 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.70 +2 -2 + NTP_4_2_7P467 + + scripts/ntpsweep/ntpsweep-opts@1.19 +2 -2 + NTP_4_2_7P467 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.58 +6 -6 + NTP_4_2_7P467 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.58 +2 -2 + NTP_4_2_7P467 + + scripts/ntpsweep/ntpsweep.html@1.71 +2 -2 + NTP_4_2_7P467 + + scripts/ntpsweep/ntpsweep.man.in@1.58 +6 -6 + NTP_4_2_7P467 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.59 +2 -2 + NTP_4_2_7P467 + + scripts/ntptrace/invoke-ntptrace.texi@1.70 +2 -2 + NTP_4_2_7P467 + + scripts/ntptrace/ntptrace-opts@1.19 +2 -2 + NTP_4_2_7P467 + + scripts/ntptrace/ntptrace.1ntptraceman@1.58 +6 -6 + NTP_4_2_7P467 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.58 +2 -2 + NTP_4_2_7P467 + + scripts/ntptrace/ntptrace.html@1.71 +2 -2 + NTP_4_2_7P467 + + scripts/ntptrace/ntptrace.man.in@1.58 +6 -6 + NTP_4_2_7P467 + + scripts/ntptrace/ntptrace.mdoc.in@1.59 +2 -2 + NTP_4_2_7P467 + + scripts/plot_summary-opts@1.20 +1 -1 + NTP_4_2_7P467 + + scripts/plot_summary.1plot_summaryman@1.70 +4 -4 + NTP_4_2_7P467 + + scripts/plot_summary.1plot_summarymdoc@1.70 +1 -1 + NTP_4_2_7P467 + + scripts/plot_summary.html@1.73 +2 -2 + NTP_4_2_7P467 + + scripts/plot_summary.man.in@1.70 +4 -4 + NTP_4_2_7P467 + + scripts/plot_summary.mdoc.in@1.70 +1 -1 + NTP_4_2_7P467 + + scripts/summary-opts@1.20 +1 -1 + NTP_4_2_7P467 + + scripts/summary.1summaryman@1.70 +4 -4 + NTP_4_2_7P467 + + scripts/summary.1summarymdoc@1.70 +1 -1 + NTP_4_2_7P467 + + scripts/summary.html@1.73 +2 -2 + NTP_4_2_7P467 + + scripts/summary.man.in@1.70 +4 -4 + NTP_4_2_7P467 + + scripts/summary.mdoc.in@1.70 +1 -1 + NTP_4_2_7P467 + + sntp/invoke-sntp.texi@1.457 +2 -2 + NTP_4_2_7P467 + + sntp/sntp-opts.c@1.475 +7 -7 + NTP_4_2_7P467 + + sntp/sntp-opts.h@1.474 +3 -3 + NTP_4_2_7P467 + + sntp/sntp.1sntpman@1.292 +6 -6 + NTP_4_2_7P467 + + sntp/sntp.1sntpmdoc@1.292 +2 -2 + NTP_4_2_7P467 + + sntp/sntp.html@1.472 +2 -2 + NTP_4_2_7P467 + + sntp/sntp.man.in@1.292 +6 -6 + NTP_4_2_7P467 + + sntp/sntp.mdoc.in@1.292 +2 -2 + NTP_4_2_7P467 + + util/invoke-ntp-keygen.texi@1.461 +2 -2 + NTP_4_2_7P467 + + util/ntp-keygen-opts.c@1.478 +7 -7 + NTP_4_2_7P467 + + util/ntp-keygen-opts.h@1.477 +3 -3 + NTP_4_2_7P467 + + util/ntp-keygen.1ntp-keygenman@1.289 +6 -6 + NTP_4_2_7P467 + + util/ntp-keygen.1ntp-keygenmdoc@1.289 +2 -2 + NTP_4_2_7P467 + + util/ntp-keygen.html@1.137 +2 -2 + NTP_4_2_7P467 + + util/ntp-keygen.man.in@1.289 +6 -6 + NTP_4_2_7P467 + + util/ntp-keygen.mdoc.in@1.289 +2 -2 + NTP_4_2_7P467 + +ChangeSet@1.3197, 2014-08-28 03:33:02-04:00, stenn@deacon.udel.edu + [Bug 2640] STA_NANO can result in invalid ntv.constant + + ChangeLog@1.1534 +1 -0 + [Bug 2640] STA_NANO can result in invalid ntv.constant + + ntpd/ntp_loopfilter.c@1.172 +3 -0 + [Bug 2640] STA_NANO can result in invalid ntv.constant + +ChangeSet@1.3196, 2014-08-28 07:13:56+00:00, stenn@psp-fb1.ntp.org + [Bug 2639] Check return value of ntp_adjtime() + + ChangeLog@1.1533 +1 -0 + [Bug 2639] Check return value of ntp_adjtime() + + ntpd/ntp_loopfilter.c@1.171 +24 -6 + [Bug 2639] Check return value of ntp_adjtime() + +ChangeSet@1.3195, 2014-08-27 08:59:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P466 + TAG: NTP_4_2_7P466 + + ChangeLog@1.1532 +1 -0 + NTP_4_2_7P466 + + ntpd/invoke-ntp.conf.texi@1.145 +1 -1 + NTP_4_2_7P466 + + ntpd/invoke-ntp.keys.texi@1.143 +1 -1 + NTP_4_2_7P466 + + ntpd/invoke-ntpd.texi@1.459 +2 -2 + NTP_4_2_7P466 + + ntpd/ntp.conf.5man@1.179 +6 -6 + NTP_4_2_7P466 + + ntpd/ntp.conf.5mdoc@1.179 +2 -2 + NTP_4_2_7P466 + + ntpd/ntp.conf.html@1.140 +1 -1 + NTP_4_2_7P466 + + ntpd/ntp.conf.man.in@1.179 +6 -6 + NTP_4_2_7P466 + + ntpd/ntp.conf.mdoc.in@1.179 +2 -2 + NTP_4_2_7P466 + + ntpd/ntp.keys.5man@1.177 +2 -2 + NTP_4_2_7P466 + + ntpd/ntp.keys.5mdoc@1.177 +2 -2 + NTP_4_2_7P466 + + ntpd/ntp.keys.html@1.141 +1 -1 + NTP_4_2_7P466 + + ntpd/ntp.keys.man.in@1.177 +2 -2 + NTP_4_2_7P466 + + ntpd/ntp.keys.mdoc.in@1.177 +2 -2 + NTP_4_2_7P466 + + ntpd/ntpd-opts.c@1.480 +7 -7 + NTP_4_2_7P466 + + ntpd/ntpd-opts.h@1.479 +3 -3 + NTP_4_2_7P466 + + ntpd/ntpd.1ntpdman@1.288 +6 -6 + NTP_4_2_7P466 + + ntpd/ntpd.1ntpdmdoc@1.288 +2 -2 + NTP_4_2_7P466 + + ntpd/ntpd.html@1.135 +2 -4 + NTP_4_2_7P466 + + ntpd/ntpd.man.in@1.288 +6 -6 + NTP_4_2_7P466 + + ntpd/ntpd.mdoc.in@1.288 +2 -2 + NTP_4_2_7P466 + + ntpdc/invoke-ntpdc.texi@1.457 +2 -2 + NTP_4_2_7P466 + + ntpdc/ntpdc-opts.c@1.475 +7 -7 + NTP_4_2_7P466 + + ntpdc/ntpdc-opts.h@1.474 +3 -3 + NTP_4_2_7P466 + + ntpdc/ntpdc.1ntpdcman@1.288 +6 -6 + NTP_4_2_7P466 + + ntpdc/ntpdc.1ntpdcmdoc@1.288 +2 -2 + NTP_4_2_7P466 + + ntpdc/ntpdc.html@1.301 +2 -2 + NTP_4_2_7P466 + + ntpdc/ntpdc.man.in@1.288 +6 -6 + NTP_4_2_7P466 + + ntpdc/ntpdc.mdoc.in@1.288 +2 -2 + NTP_4_2_7P466 + + ntpq/invoke-ntpq.texi@1.463 +2 -2 + NTP_4_2_7P466 + + ntpq/ntpq-opts.c@1.480 +7 -7 + NTP_4_2_7P466 + + ntpq/ntpq-opts.h@1.478 +3 -3 + NTP_4_2_7P466 + + ntpq/ntpq.1ntpqman@1.291 +6 -6 + NTP_4_2_7P466 + + ntpq/ntpq.1ntpqmdoc@1.291 +2 -2 + NTP_4_2_7P466 + + ntpq/ntpq.html@1.132 +2 -4 + NTP_4_2_7P466 + + ntpq/ntpq.man.in@1.291 +6 -6 + NTP_4_2_7P466 + + ntpq/ntpq.mdoc.in@1.291 +2 -2 + NTP_4_2_7P466 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.459 +2 -2 + NTP_4_2_7P466 + + ntpsnmpd/ntpsnmpd-opts.c@1.477 +7 -7 + NTP_4_2_7P466 + + ntpsnmpd/ntpsnmpd-opts.h@1.476 +3 -3 + NTP_4_2_7P466 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.288 +6 -6 + NTP_4_2_7P466 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.288 +2 -2 + NTP_4_2_7P466 + + ntpsnmpd/ntpsnmpd.html@1.130 +1 -1 + NTP_4_2_7P466 + + ntpsnmpd/ntpsnmpd.man.in@1.288 +6 -6 + NTP_4_2_7P466 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.288 +2 -2 + NTP_4_2_7P466 + + packageinfo.sh@1.470 +1 -1 + NTP_4_2_7P466 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.50 +6 -6 + NTP_4_2_7P466 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.50 +2 -2 + NTP_4_2_7P466 + + scripts/calc_tickadj/calc_tickadj.html@1.52 +1 -1 + NTP_4_2_7P466 + + scripts/calc_tickadj/calc_tickadj.man.in@1.49 +6 -6 + NTP_4_2_7P466 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.50 +2 -2 + NTP_4_2_7P466 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.54 +1 -1 + NTP_4_2_7P466 + + scripts/invoke-plot_summary.texi@1.72 +1 -1 + NTP_4_2_7P466 + + scripts/invoke-summary.texi@1.72 +1 -1 + NTP_4_2_7P466 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.280 +2 -2 + NTP_4_2_7P466 + + scripts/ntp-wait/ntp-wait-opts@1.16 +2 -2 + NTP_4_2_7P466 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.278 +6 -6 + NTP_4_2_7P466 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.278 +2 -2 + NTP_4_2_7P466 + + scripts/ntp-wait/ntp-wait.html@1.297 +2 -2 + NTP_4_2_7P466 + + scripts/ntp-wait/ntp-wait.man.in@1.278 +6 -6 + NTP_4_2_7P466 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.278 +2 -2 + NTP_4_2_7P466 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.69 +2 -2 + NTP_4_2_7P466 + + scripts/ntpsweep/ntpsweep-opts@1.18 +2 -2 + NTP_4_2_7P466 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.57 +6 -6 + NTP_4_2_7P466 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.57 +2 -2 + NTP_4_2_7P466 + + scripts/ntpsweep/ntpsweep.html@1.70 +2 -2 + NTP_4_2_7P466 + + scripts/ntpsweep/ntpsweep.man.in@1.57 +6 -6 + NTP_4_2_7P466 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.58 +2 -2 + NTP_4_2_7P466 + + scripts/ntptrace/invoke-ntptrace.texi@1.69 +2 -2 + NTP_4_2_7P466 + + scripts/ntptrace/ntptrace-opts@1.18 +2 -2 + NTP_4_2_7P466 + + scripts/ntptrace/ntptrace.1ntptraceman@1.57 +6 -6 + NTP_4_2_7P466 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.57 +2 -2 + NTP_4_2_7P466 + + scripts/ntptrace/ntptrace.html@1.70 +2 -2 + NTP_4_2_7P466 + + scripts/ntptrace/ntptrace.man.in@1.57 +6 -6 + NTP_4_2_7P466 + + scripts/ntptrace/ntptrace.mdoc.in@1.58 +2 -2 + NTP_4_2_7P466 + + scripts/plot_summary-opts@1.19 +1 -1 + NTP_4_2_7P466 + + scripts/plot_summary.1plot_summaryman@1.69 +4 -4 + NTP_4_2_7P466 + + scripts/plot_summary.1plot_summarymdoc@1.69 +1 -1 + NTP_4_2_7P466 + + scripts/plot_summary.html@1.72 +2 -2 + NTP_4_2_7P466 + + scripts/plot_summary.man.in@1.69 +4 -4 + NTP_4_2_7P466 + + scripts/plot_summary.mdoc.in@1.69 +1 -1 + NTP_4_2_7P466 + + scripts/summary-opts@1.19 +1 -1 + NTP_4_2_7P466 + + scripts/summary.1summaryman@1.69 +4 -4 + NTP_4_2_7P466 + + scripts/summary.1summarymdoc@1.69 +1 -1 + NTP_4_2_7P466 + + scripts/summary.html@1.72 +2 -2 + NTP_4_2_7P466 + + scripts/summary.man.in@1.69 +4 -4 + NTP_4_2_7P466 + + scripts/summary.mdoc.in@1.69 +1 -1 + NTP_4_2_7P466 + + sntp/invoke-sntp.texi@1.456 +2 -2 + NTP_4_2_7P466 + + sntp/sntp-opts.c@1.474 +7 -7 + NTP_4_2_7P466 + + sntp/sntp-opts.h@1.473 +3 -3 + NTP_4_2_7P466 + + sntp/sntp.1sntpman@1.291 +6 -6 + NTP_4_2_7P466 + + sntp/sntp.1sntpmdoc@1.291 +2 -2 + NTP_4_2_7P466 + + sntp/sntp.html@1.471 +2 -2 + NTP_4_2_7P466 + + sntp/sntp.man.in@1.291 +6 -6 + NTP_4_2_7P466 + + sntp/sntp.mdoc.in@1.291 +2 -2 + NTP_4_2_7P466 + + util/invoke-ntp-keygen.texi@1.460 +2 -2 + NTP_4_2_7P466 + + util/ntp-keygen-opts.c@1.477 +7 -7 + NTP_4_2_7P466 + + util/ntp-keygen-opts.h@1.476 +3 -3 + NTP_4_2_7P466 + + util/ntp-keygen.1ntp-keygenman@1.288 +6 -6 + NTP_4_2_7P466 + + util/ntp-keygen.1ntp-keygenmdoc@1.288 +2 -2 + NTP_4_2_7P466 + + util/ntp-keygen.html@1.136 +2 -4 + NTP_4_2_7P466 + + util/ntp-keygen.man.in@1.288 +6 -6 + NTP_4_2_7P466 + + util/ntp-keygen.mdoc.in@1.288 +2 -2 + NTP_4_2_7P466 + +ChangeSet@1.3194, 2014-08-27 04:53:42+00:00, stenn@psp-fb1.ntp.org + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + ChangeLog@1.1531 +1 -0 + + ntpd/ntpd.c@1.155 +10 -3 + +ChangeSet@1.3193, 2014-08-23 08:59:05+00:00, stenn@deacon.udel.edu + NTP_4_2_7P465 + TAG: NTP_4_2_7P465 + + ChangeLog@1.1530 +1 -0 + NTP_4_2_7P465 + + ntpd/invoke-ntp.conf.texi@1.144 +1 -1 + NTP_4_2_7P465 + + ntpd/invoke-ntp.keys.texi@1.142 +1 -1 + NTP_4_2_7P465 + + ntpd/invoke-ntpd.texi@1.458 +2 -4 + NTP_4_2_7P465 + + ntpd/ntp.conf.5man@1.178 +6 -6 + NTP_4_2_7P465 + + ntpd/ntp.conf.5mdoc@1.178 +2 -2 + NTP_4_2_7P465 + + ntpd/ntp.conf.html@1.139 +1 -1 + NTP_4_2_7P465 + + ntpd/ntp.conf.man.in@1.178 +6 -6 + NTP_4_2_7P465 + + ntpd/ntp.conf.mdoc.in@1.178 +2 -2 + NTP_4_2_7P465 + + ntpd/ntp.keys.5man@1.176 +2 -2 + NTP_4_2_7P465 + + ntpd/ntp.keys.5mdoc@1.176 +2 -2 + NTP_4_2_7P465 + + ntpd/ntp.keys.html@1.140 +1 -1 + NTP_4_2_7P465 + + ntpd/ntp.keys.man.in@1.176 +2 -2 + NTP_4_2_7P465 + + ntpd/ntp.keys.mdoc.in@1.176 +2 -2 + NTP_4_2_7P465 + + ntpd/ntpd-opts.c@1.479 +7 -7 + NTP_4_2_7P465 + + ntpd/ntpd-opts.h@1.478 +3 -3 + NTP_4_2_7P465 + + ntpd/ntpd.1ntpdman@1.287 +22 -13 + NTP_4_2_7P465 + + ntpd/ntpd.1ntpdmdoc@1.287 +18 -9 + NTP_4_2_7P465 + + ntpd/ntpd.html@1.134 +2 -2 + NTP_4_2_7P465 + + ntpd/ntpd.man.in@1.287 +22 -13 + NTP_4_2_7P465 + + ntpd/ntpd.mdoc.in@1.287 +18 -9 + NTP_4_2_7P465 + + ntpdc/invoke-ntpdc.texi@1.456 +2 -4 + NTP_4_2_7P465 + + ntpdc/ntpdc-opts.c@1.474 +7 -7 + NTP_4_2_7P465 + + ntpdc/ntpdc-opts.h@1.473 +3 -3 + NTP_4_2_7P465 + + ntpdc/ntpdc.1ntpdcman@1.287 +6 -6 + NTP_4_2_7P465 + + ntpdc/ntpdc.1ntpdcmdoc@1.287 +2 -2 + NTP_4_2_7P465 + + ntpdc/ntpdc.html@1.300 +2 -4 + NTP_4_2_7P465 + + ntpdc/ntpdc.man.in@1.287 +6 -6 + NTP_4_2_7P465 + + ntpdc/ntpdc.mdoc.in@1.287 +2 -2 + NTP_4_2_7P465 + + ntpq/invoke-ntpq.texi@1.462 +2 -4 + NTP_4_2_7P465 + + ntpq/ntpq-opts.c@1.479 +7 -7 + NTP_4_2_7P465 + + ntpq/ntpq-opts.h@1.477 +3 -3 + NTP_4_2_7P465 + + ntpq/ntpq.1ntpqman@1.290 +6 -6 + NTP_4_2_7P465 + + ntpq/ntpq.1ntpqmdoc@1.290 +2 -2 + NTP_4_2_7P465 + + ntpq/ntpq.html@1.131 +2 -2 + NTP_4_2_7P465 + + ntpq/ntpq.man.in@1.290 +6 -6 + NTP_4_2_7P465 + + ntpq/ntpq.mdoc.in@1.290 +2 -2 + NTP_4_2_7P465 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.458 +2 -4 + NTP_4_2_7P465 + + ntpsnmpd/ntpsnmpd-opts.c@1.476 +7 -7 + NTP_4_2_7P465 + + ntpsnmpd/ntpsnmpd-opts.h@1.475 +3 -3 + NTP_4_2_7P465 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.287 +6 -6 + NTP_4_2_7P465 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.287 +2 -2 + NTP_4_2_7P465 + + ntpsnmpd/ntpsnmpd.html@1.129 +1 -1 + NTP_4_2_7P465 + + ntpsnmpd/ntpsnmpd.man.in@1.287 +6 -6 + NTP_4_2_7P465 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.287 +2 -2 + NTP_4_2_7P465 + + packageinfo.sh@1.469 +1 -1 + NTP_4_2_7P465 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.49 +6 -6 + NTP_4_2_7P465 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.49 +2 -2 + NTP_4_2_7P465 + + scripts/calc_tickadj/calc_tickadj.html@1.51 +22 -34 + NTP_4_2_7P465 + + scripts/calc_tickadj/calc_tickadj.man.in@1.48 +6 -6 + NTP_4_2_7P465 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.49 +2 -2 + NTP_4_2_7P465 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.53 +1 -1 + NTP_4_2_7P465 + + scripts/invoke-plot_summary.texi@1.71 +1 -1 + NTP_4_2_7P465 + + scripts/invoke-summary.texi@1.71 +1 -1 + NTP_4_2_7P465 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.279 +2 -2 + NTP_4_2_7P465 + + scripts/ntp-wait/ntp-wait-opts@1.15 +2 -2 + NTP_4_2_7P465 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.277 +6 -6 + NTP_4_2_7P465 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.277 +2 -2 + NTP_4_2_7P465 + + scripts/ntp-wait/ntp-wait.html@1.296 +31 -49 + NTP_4_2_7P465 + + scripts/ntp-wait/ntp-wait.man.in@1.277 +6 -6 + NTP_4_2_7P465 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.277 +2 -2 + NTP_4_2_7P465 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.68 +2 -2 + NTP_4_2_7P465 + + scripts/ntpsweep/ntpsweep-opts@1.17 +2 -2 + NTP_4_2_7P465 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.56 +6 -6 + NTP_4_2_7P465 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.56 +2 -2 + NTP_4_2_7P465 + + scripts/ntpsweep/ntpsweep.html@1.69 +33 -44 + NTP_4_2_7P465 + + scripts/ntpsweep/ntpsweep.man.in@1.56 +6 -6 + NTP_4_2_7P465 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.57 +2 -2 + NTP_4_2_7P465 + + scripts/ntptrace/invoke-ntptrace.texi@1.68 +2 -2 + NTP_4_2_7P465 + + scripts/ntptrace/ntptrace-opts@1.17 +2 -2 + NTP_4_2_7P465 + + scripts/ntptrace/ntptrace.1ntptraceman@1.56 +13 -13 + NTP_4_2_7P465 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.56 +2 -2 + NTP_4_2_7P465 + + scripts/ntptrace/ntptrace.html@1.69 +27 -36 + NTP_4_2_7P465 + + scripts/ntptrace/ntptrace.man.in@1.56 +13 -13 + NTP_4_2_7P465 + + scripts/ntptrace/ntptrace.mdoc.in@1.57 +2 -2 + NTP_4_2_7P465 + + scripts/plot_summary-opts@1.18 +1 -1 + NTP_4_2_7P465 + + scripts/plot_summary.1plot_summaryman@1.68 +6 -6 + NTP_4_2_7P465 + + scripts/plot_summary.1plot_summarymdoc@1.68 +3 -3 + NTP_4_2_7P465 + + scripts/plot_summary.html@1.71 +29 -47 + NTP_4_2_7P465 + + scripts/plot_summary.man.in@1.68 +6 -6 + NTP_4_2_7P465 + + scripts/plot_summary.mdoc.in@1.68 +3 -3 + NTP_4_2_7P465 + + scripts/summary-opts@1.18 +1 -1 + NTP_4_2_7P465 + + scripts/summary.1summaryman@1.68 +6 -6 + NTP_4_2_7P465 + + scripts/summary.1summarymdoc@1.68 +2 -2 + NTP_4_2_7P465 + + scripts/summary.html@1.71 +27 -39 + NTP_4_2_7P465 + + scripts/summary.man.in@1.68 +6 -6 + NTP_4_2_7P465 + + scripts/summary.mdoc.in@1.68 +2 -2 + NTP_4_2_7P465 + + sntp/invoke-sntp.texi@1.455 +2 -4 + NTP_4_2_7P465 + + sntp/sntp-opts.c@1.473 +7 -7 + NTP_4_2_7P465 + + sntp/sntp-opts.h@1.472 +3 -3 + NTP_4_2_7P465 + + sntp/sntp.1sntpman@1.290 +6 -6 + NTP_4_2_7P465 + + sntp/sntp.1sntpmdoc@1.290 +2 -2 + NTP_4_2_7P465 + + sntp/sntp.html@1.470 +2 -4 + NTP_4_2_7P465 + + sntp/sntp.man.in@1.290 +6 -6 + NTP_4_2_7P465 + + sntp/sntp.mdoc.in@1.290 +2 -2 + NTP_4_2_7P465 + + util/invoke-ntp-keygen.texi@1.459 +2 -4 + NTP_4_2_7P465 + + util/ntp-keygen-opts.c@1.476 +7 -7 + NTP_4_2_7P465 + + util/ntp-keygen-opts.h@1.475 +3 -3 + NTP_4_2_7P465 + + util/ntp-keygen.1ntp-keygenman@1.287 +6 -6 + NTP_4_2_7P465 + + util/ntp-keygen.1ntp-keygenmdoc@1.287 +2 -2 + NTP_4_2_7P465 + + util/ntp-keygen.html@1.135 +2 -2 + NTP_4_2_7P465 + + util/ntp-keygen.man.in@1.287 +6 -6 + NTP_4_2_7P465 + + util/ntp-keygen.mdoc.in@1.287 +2 -2 + NTP_4_2_7P465 + +ChangeSet@1.3192, 2014-08-23 08:37:07+00:00, stenn@psp-fb1.ntp.org + [Bug 2595] Man page quirks: ntpdate references in ntpd + + ChangeLog@1.1529 +1 -0 + [Bug 2595] Man page quirks: ntpdate references in ntpd + + ntpd/ntpd-opts.def@1.12 +16 -7 + [Bug 2595] Man page quirks: ntpdate references in ntpd + +ChangeSet@1.3191, 2014-08-23 05:39:03+00:00, stenn@psp-fb1.ntp.org + [Bug 2613] www.ntp.org/bugs.html tells folks to email doc bugs to DLM + + ChangeLog@1.1528 +1 -0 + [Bug 2613] www.ntp.org/bugs.html tells folks to email doc bugs to DLM + + html/bugs.html@1.8 +4 -7 + [Bug 2613] www.ntp.org/bugs.html tells folks to email doc bugs to DLM + +ChangeSet@1.3190, 2014-08-23 00:23:55+00:00, stenn@psp-fb1.ntp.org + [Bug 2538] NTP programs print exit code in help/usage text + + ChangeLog@1.1527 +1 -0 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpd/Makefile.am@1.131 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpd/ntpd-opts.c@1.478 +3 -60 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpd/ntpdbase-opts.def@1.27 +0 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpd/ntpdsim-opts.c@1.28 +9 -66 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpd/ntpdsim-opts.h@1.28 +2 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpdc/Makefile.am@1.75 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpdc/ntpdc-opts.c@1.473 +3 -60 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpdc/ntpdc-opts.def@1.23 +0 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpq/Makefile.am@1.71 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpq/ntpq-opts.c@1.478 +5 -69 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpq/ntpq-opts.def@1.22 +0 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpsnmpd/Makefile.am@1.40 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpsnmpd/ntpsnmpd-opts.c@1.475 +2 -44 + [Bug 2538] NTP programs print exit code in help/usage text + + ntpsnmpd/ntpsnmpd-opts.def@1.11 +0 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/build/Makefile.am@1.4 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/calc_tickadj/Makefile.am@1.10 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/calc_tickadj/calc_tickadj-opts@1.8 +2 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/calc_tickadj/calc_tickadj.html@1.50 +34 -22 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.52 +2 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/invoke-plot_summary.texi@1.70 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/invoke-summary.texi@1.70 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntp-wait/Makefile.am@1.9 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntp-wait/invoke-ntp-wait.texi@1.278 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntp-wait/ntp-wait-opts@1.14 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntp-wait/ntp-wait-opts.def@1.11 +0 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntp-wait/ntp-wait.html@1.295 +47 -29 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntpsweep/Makefile.am@1.10 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntpsweep/invoke-ntpsweep.texi@1.67 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntpsweep/ntpsweep-opts@1.16 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntpsweep/ntpsweep.html@1.68 +42 -31 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntptrace/Makefile.am@1.10 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntptrace/invoke-ntptrace.texi@1.67 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntptrace/ntptrace-opts@1.16 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/ntptrace/ntptrace.html@1.68 +34 -25 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/plot_summary-opts@1.17 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/plot_summary.html@1.70 +45 -27 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/summary-opts@1.17 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + scripts/summary.html@1.70 +37 -25 + [Bug 2538] NTP programs print exit code in help/usage text + + sntp/Makefile.am@1.76 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + sntp/sntp-opts.c@1.472 +3 -61 + [Bug 2538] NTP programs print exit code in help/usage text + + sntp/sntp-opts.def@1.44 +0 -2 + [Bug 2538] NTP programs print exit code in help/usage text + + util/Makefile.am@1.76 +1 -1 + [Bug 2538] NTP programs print exit code in help/usage text + + util/ntp-keygen-opts.c@1.475 +3 -60 + [Bug 2538] NTP programs print exit code in help/usage text + + util/ntp-keygen-opts.def@1.27 +0 -2 + [Bug 2538] NTP programs print exit code in help/usage text + +ChangeSet@1.3189, 2014-08-22 22:14:11+02:00, jnperlin@hydra.(none) + [Bug 2636] Clutter in syslog if gpsd not running + - log GPSD revision and release numbers with protocol version + + ChangeLog@1.1526 +1 -0 + [Bug 2636] Clutter in syslog if gpsd not running + - log GPSD revision and release numbers with protocol version + + ntpd/refclock_gpsdjson.c@1.14 +8 -1 + [Bug 2636] Clutter in syslog if gpsd not running + - log GPSD revision and release numbers with protocol version + +ChangeSet@1.3188, 2014-08-22 18:36:17+02:00, jnperlin@hydra.(none) + [Bug 2636] Clutter in syslog if gpsd not running + - found (hopefully) last cause for clutter in protocol version + + ChangeLog@1.1525 +2 -0 + [Bug 2636] Clutter in syslog if gpsd not running + - found (hopefully) last cause for clutter in protocol version + + + ntpd/refclock_gpsdjson.c@1.13 +12 -13 + [Bug 2636] Clutter in syslog if gpsd not running + - found (hopefully) last cause for clutter in protocol version + + +ChangeSet@1.3187, 2014-08-22 08:58:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P464 + TAG: NTP_4_2_7P464 + + ChangeLog@1.1524 +1 -0 + NTP_4_2_7P464 + + ntpd/invoke-ntp.conf.texi@1.143 +1 -1 + NTP_4_2_7P464 + + ntpd/invoke-ntp.keys.texi@1.141 +1 -1 + NTP_4_2_7P464 + + ntpd/invoke-ntpd.texi@1.457 +2 -2 + NTP_4_2_7P464 + + ntpd/ntp.conf.5man@1.177 +6 -6 + NTP_4_2_7P464 + + ntpd/ntp.conf.5mdoc@1.177 +2 -2 + NTP_4_2_7P464 + + ntpd/ntp.conf.html@1.138 +1 -1 + NTP_4_2_7P464 + + ntpd/ntp.conf.man.in@1.177 +6 -6 + NTP_4_2_7P464 + + ntpd/ntp.conf.mdoc.in@1.177 +2 -2 + NTP_4_2_7P464 + + ntpd/ntp.keys.5man@1.175 +2 -2 + NTP_4_2_7P464 + + ntpd/ntp.keys.5mdoc@1.175 +2 -2 + NTP_4_2_7P464 + + ntpd/ntp.keys.html@1.139 +1 -1 + NTP_4_2_7P464 + + ntpd/ntp.keys.man.in@1.175 +2 -2 + NTP_4_2_7P464 + + ntpd/ntp.keys.mdoc.in@1.175 +2 -2 + NTP_4_2_7P464 + + ntpd/ntpd-opts.c@1.477 +6 -6 + NTP_4_2_7P464 + + ntpd/ntpd-opts.h@1.477 +2 -2 + NTP_4_2_7P464 + + ntpd/ntpd.1ntpdman@1.286 +6 -6 + NTP_4_2_7P464 + + ntpd/ntpd.1ntpdmdoc@1.286 +2 -2 + NTP_4_2_7P464 + + ntpd/ntpd.html@1.133 +2 -2 + NTP_4_2_7P464 + + ntpd/ntpd.man.in@1.286 +6 -6 + NTP_4_2_7P464 + + ntpd/ntpd.mdoc.in@1.286 +2 -2 + NTP_4_2_7P464 + + ntpdc/invoke-ntpdc.texi@1.455 +2 -2 + NTP_4_2_7P464 + + ntpdc/ntpdc-opts.c@1.472 +6 -6 + NTP_4_2_7P464 + + ntpdc/ntpdc-opts.h@1.472 +2 -2 + NTP_4_2_7P464 + + ntpdc/ntpdc.1ntpdcman@1.286 +6 -6 + NTP_4_2_7P464 + + ntpdc/ntpdc.1ntpdcmdoc@1.286 +2 -2 + NTP_4_2_7P464 + + ntpdc/ntpdc.html@1.299 +2 -2 + NTP_4_2_7P464 + + ntpdc/ntpdc.man.in@1.286 +6 -6 + NTP_4_2_7P464 + + ntpdc/ntpdc.mdoc.in@1.286 +2 -2 + NTP_4_2_7P464 + + ntpq/invoke-ntpq.texi@1.461 +2 -2 + NTP_4_2_7P464 + + ntpq/ntpq-opts.c@1.477 +6 -6 + NTP_4_2_7P464 + + ntpq/ntpq-opts.h@1.476 +2 -2 + NTP_4_2_7P464 + + ntpq/ntpq.1ntpqman@1.289 +6 -6 + NTP_4_2_7P464 + + ntpq/ntpq.1ntpqmdoc@1.289 +2 -2 + NTP_4_2_7P464 + + ntpq/ntpq.html@1.130 +2 -2 + NTP_4_2_7P464 + + ntpq/ntpq.man.in@1.289 +6 -6 + NTP_4_2_7P464 + + ntpq/ntpq.mdoc.in@1.289 +2 -2 + NTP_4_2_7P464 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.457 +2 -2 + NTP_4_2_7P464 + + ntpsnmpd/ntpsnmpd-opts.c@1.474 +6 -6 + NTP_4_2_7P464 + + ntpsnmpd/ntpsnmpd-opts.h@1.474 +2 -2 + NTP_4_2_7P464 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.286 +6 -6 + NTP_4_2_7P464 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.286 +2 -2 + NTP_4_2_7P464 + + ntpsnmpd/ntpsnmpd.html@1.128 +1 -1 + NTP_4_2_7P464 + + ntpsnmpd/ntpsnmpd.man.in@1.286 +6 -6 + NTP_4_2_7P464 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.286 +2 -2 + NTP_4_2_7P464 + + packageinfo.sh@1.468 +1 -1 + NTP_4_2_7P464 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.48 +6 -6 + NTP_4_2_7P464 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.48 +2 -2 + NTP_4_2_7P464 + + scripts/calc_tickadj/calc_tickadj.html@1.49 +1 -1 + NTP_4_2_7P464 + + scripts/calc_tickadj/calc_tickadj.man.in@1.47 +6 -6 + NTP_4_2_7P464 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.48 +2 -2 + NTP_4_2_7P464 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.51 +1 -1 + NTP_4_2_7P464 + + scripts/invoke-plot_summary.texi@1.69 +2 -2 + NTP_4_2_7P464 + + scripts/invoke-summary.texi@1.69 +2 -2 + NTP_4_2_7P464 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.277 +2 -2 + NTP_4_2_7P464 + + scripts/ntp-wait/ntp-wait-opts@1.13 +2 -2 + NTP_4_2_7P464 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.276 +6 -6 + NTP_4_2_7P464 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.276 +2 -2 + NTP_4_2_7P464 + + scripts/ntp-wait/ntp-wait.html@1.294 +2 -2 + NTP_4_2_7P464 + + scripts/ntp-wait/ntp-wait.man.in@1.276 +6 -6 + NTP_4_2_7P464 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.276 +2 -2 + NTP_4_2_7P464 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.66 +2 -2 + NTP_4_2_7P464 + + scripts/ntpsweep/ntpsweep-opts@1.15 +2 -2 + NTP_4_2_7P464 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.55 +6 -6 + NTP_4_2_7P464 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.55 +2 -2 + NTP_4_2_7P464 + + scripts/ntpsweep/ntpsweep.html@1.67 +2 -2 + NTP_4_2_7P464 + + scripts/ntpsweep/ntpsweep.man.in@1.55 +6 -6 + NTP_4_2_7P464 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.56 +2 -2 + NTP_4_2_7P464 + + scripts/ntptrace/invoke-ntptrace.texi@1.66 +2 -2 + NTP_4_2_7P464 + + scripts/ntptrace/ntptrace-opts@1.15 +2 -2 + NTP_4_2_7P464 + + scripts/ntptrace/ntptrace.1ntptraceman@1.55 +13 -13 + NTP_4_2_7P464 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.55 +2 -2 + NTP_4_2_7P464 + + scripts/ntptrace/ntptrace.html@1.67 +2 -2 + NTP_4_2_7P464 + + scripts/ntptrace/ntptrace.man.in@1.55 +13 -13 + NTP_4_2_7P464 + + scripts/ntptrace/ntptrace.mdoc.in@1.56 +2 -2 + NTP_4_2_7P464 + + scripts/plot_summary-opts@1.16 +2 -2 + NTP_4_2_7P464 + + scripts/plot_summary.1plot_summaryman@1.67 +14 -14 + NTP_4_2_7P464 + + scripts/plot_summary.1plot_summarymdoc@1.67 +3 -3 + NTP_4_2_7P464 + + scripts/plot_summary.html@1.69 +2 -2 + NTP_4_2_7P464 + + scripts/plot_summary.man.in@1.67 +14 -14 + NTP_4_2_7P464 + + scripts/plot_summary.mdoc.in@1.67 +3 -3 + NTP_4_2_7P464 + + scripts/summary-opts@1.16 +2 -2 + NTP_4_2_7P464 + + scripts/summary.1summaryman@1.67 +6 -6 + NTP_4_2_7P464 + + scripts/summary.1summarymdoc@1.67 +2 -2 + NTP_4_2_7P464 + + scripts/summary.html@1.69 +2 -2 + NTP_4_2_7P464 + + scripts/summary.man.in@1.67 +6 -6 + NTP_4_2_7P464 + + scripts/summary.mdoc.in@1.67 +2 -2 + NTP_4_2_7P464 + + sntp/invoke-sntp.texi@1.454 +2 -2 + NTP_4_2_7P464 + + sntp/sntp-opts.c@1.471 +6 -6 + NTP_4_2_7P464 + + sntp/sntp-opts.h@1.471 +2 -2 + NTP_4_2_7P464 + + sntp/sntp.1sntpman@1.289 +6 -6 + NTP_4_2_7P464 + + sntp/sntp.1sntpmdoc@1.289 +2 -2 + NTP_4_2_7P464 + + sntp/sntp.html@1.469 +2 -2 + NTP_4_2_7P464 + + sntp/sntp.man.in@1.289 +6 -6 + NTP_4_2_7P464 + + sntp/sntp.mdoc.in@1.289 +2 -2 + NTP_4_2_7P464 + + util/invoke-ntp-keygen.texi@1.458 +2 -2 + NTP_4_2_7P464 + + util/ntp-keygen-opts.c@1.474 +6 -6 + NTP_4_2_7P464 + + util/ntp-keygen-opts.h@1.474 +2 -2 + NTP_4_2_7P464 + + util/ntp-keygen.1ntp-keygenman@1.286 +6 -6 + NTP_4_2_7P464 + + util/ntp-keygen.1ntp-keygenmdoc@1.286 +2 -2 + NTP_4_2_7P464 + + util/ntp-keygen.html@1.134 +2 -2 + NTP_4_2_7P464 + + util/ntp-keygen.man.in@1.286 +6 -6 + NTP_4_2_7P464 + + util/ntp-keygen.mdoc.in@1.286 +2 -2 + NTP_4_2_7P464 + +ChangeSet@1.3186, 2014-08-22 02:15:10-04:00, stenn@deacon.udel.edu + typos + + ChangeLog@1.1523 +1 -1 + typos + +ChangeSet@1.3185, 2014-08-21 21:40:54+00:00, stenn@psp-fb1.ntp.org + [Bug 2636] Fix coverity warning from previous patch + + ChangeLog@1.1522 +1 -0 + [Bug 2636] Fix coverity warning from previous patch + +ChangeSet@1.3184, 2014-08-21 18:17:07+02:00, jnperlin@hydra.(none) + refclock_gpsdjson: Fix coverity warning. Did not cause a bug, but the code was not excatly as intented. + + ntpd/refclock_gpsdjson.c@1.12 +11 -5 + Fix coverity warning. Did not cause a bug, but the code was not excatly as intented. + +ChangeSet@1.3183, 2014-08-21 08:59:13+00:00, stenn@deacon.udel.edu + NTP_4_2_7P463 + TAG: NTP_4_2_7P463 + + ChangeLog@1.1521 +1 -0 + NTP_4_2_7P463 + + ntpd/invoke-ntp.conf.texi@1.142 +1 -1 + NTP_4_2_7P463 + + ntpd/invoke-ntp.keys.texi@1.140 +1 -1 + NTP_4_2_7P463 + + ntpd/invoke-ntpd.texi@1.456 +2 -2 + NTP_4_2_7P463 + + ntpd/ntp.conf.5man@1.176 +6 -6 + NTP_4_2_7P463 + + ntpd/ntp.conf.5mdoc@1.176 +2 -2 + NTP_4_2_7P463 + + ntpd/ntp.conf.html@1.137 +1 -1 + NTP_4_2_7P463 + + ntpd/ntp.conf.man.in@1.176 +6 -6 + NTP_4_2_7P463 + + ntpd/ntp.conf.mdoc.in@1.176 +2 -2 + NTP_4_2_7P463 + + ntpd/ntp.keys.5man@1.174 +2 -2 + NTP_4_2_7P463 + + ntpd/ntp.keys.5mdoc@1.174 +2 -2 + NTP_4_2_7P463 + + ntpd/ntp.keys.html@1.138 +1 -1 + NTP_4_2_7P463 + + ntpd/ntp.keys.man.in@1.174 +2 -2 + NTP_4_2_7P463 + + ntpd/ntp.keys.mdoc.in@1.174 +2 -2 + NTP_4_2_7P463 + + ntpd/ntpd-opts.c@1.476 +6 -6 + NTP_4_2_7P463 + + ntpd/ntpd-opts.h@1.476 +2 -2 + NTP_4_2_7P463 + + ntpd/ntpd.1ntpdman@1.285 +6 -6 + NTP_4_2_7P463 + + ntpd/ntpd.1ntpdmdoc@1.285 +2 -2 + NTP_4_2_7P463 + + ntpd/ntpd.html@1.132 +2 -2 + NTP_4_2_7P463 + + ntpd/ntpd.man.in@1.285 +6 -6 + NTP_4_2_7P463 + + ntpd/ntpd.mdoc.in@1.285 +2 -2 + NTP_4_2_7P463 + + ntpdc/invoke-ntpdc.texi@1.454 +2 -2 + NTP_4_2_7P463 + + ntpdc/ntpdc-opts.c@1.471 +6 -6 + NTP_4_2_7P463 + + ntpdc/ntpdc-opts.h@1.471 +2 -2 + NTP_4_2_7P463 + + ntpdc/ntpdc.1ntpdcman@1.285 +13 -13 + NTP_4_2_7P463 + + ntpdc/ntpdc.1ntpdcmdoc@1.285 +2 -2 + NTP_4_2_7P463 + + ntpdc/ntpdc.html@1.298 +2 -2 + NTP_4_2_7P463 + + ntpdc/ntpdc.man.in@1.285 +13 -13 + NTP_4_2_7P463 + + ntpdc/ntpdc.mdoc.in@1.285 +2 -2 + NTP_4_2_7P463 + + ntpq/invoke-ntpq.texi@1.460 +2 -2 + NTP_4_2_7P463 + + ntpq/ntpq-opts.c@1.476 +6 -6 + NTP_4_2_7P463 + + ntpq/ntpq-opts.h@1.475 +2 -2 + NTP_4_2_7P463 + + ntpq/ntpq.1ntpqman@1.288 +6 -6 + NTP_4_2_7P463 + + ntpq/ntpq.1ntpqmdoc@1.288 +2 -2 + NTP_4_2_7P463 + + ntpq/ntpq.html@1.129 +2 -2 + NTP_4_2_7P463 + + ntpq/ntpq.man.in@1.288 +6 -6 + NTP_4_2_7P463 + + ntpq/ntpq.mdoc.in@1.288 +2 -2 + NTP_4_2_7P463 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.456 +2 -2 + NTP_4_2_7P463 + + ntpsnmpd/ntpsnmpd-opts.c@1.473 +6 -6 + NTP_4_2_7P463 + + ntpsnmpd/ntpsnmpd-opts.h@1.473 +2 -2 + NTP_4_2_7P463 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.285 +6 -6 + NTP_4_2_7P463 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.285 +2 -2 + NTP_4_2_7P463 + + ntpsnmpd/ntpsnmpd.html@1.127 +1 -1 + NTP_4_2_7P463 + + ntpsnmpd/ntpsnmpd.man.in@1.285 +6 -6 + NTP_4_2_7P463 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.285 +2 -2 + NTP_4_2_7P463 + + packageinfo.sh@1.467 +1 -1 + NTP_4_2_7P463 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.47 +6 -6 + NTP_4_2_7P463 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.47 +2 -2 + NTP_4_2_7P463 + + scripts/calc_tickadj/calc_tickadj.html@1.48 +1 -1 + NTP_4_2_7P463 + + scripts/calc_tickadj/calc_tickadj.man.in@1.46 +6 -6 + NTP_4_2_7P463 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.47 +2 -2 + NTP_4_2_7P463 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.50 +1 -1 + NTP_4_2_7P463 + + scripts/invoke-plot_summary.texi@1.68 +2 -2 + NTP_4_2_7P463 + + scripts/invoke-summary.texi@1.68 +2 -2 + NTP_4_2_7P463 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.276 +2 -2 + NTP_4_2_7P463 + + scripts/ntp-wait/ntp-wait-opts@1.12 +2 -2 + NTP_4_2_7P463 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.275 +6 -6 + NTP_4_2_7P463 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.275 +2 -2 + NTP_4_2_7P463 + + scripts/ntp-wait/ntp-wait.html@1.293 +2 -2 + NTP_4_2_7P463 + + scripts/ntp-wait/ntp-wait.man.in@1.275 +6 -6 + NTP_4_2_7P463 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.275 +2 -2 + NTP_4_2_7P463 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.65 +2 -2 + NTP_4_2_7P463 + + scripts/ntpsweep/ntpsweep-opts@1.14 +2 -2 + NTP_4_2_7P463 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.54 +6 -6 + NTP_4_2_7P463 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.54 +2 -2 + NTP_4_2_7P463 + + scripts/ntpsweep/ntpsweep.html@1.66 +2 -2 + NTP_4_2_7P463 + + scripts/ntpsweep/ntpsweep.man.in@1.54 +6 -6 + NTP_4_2_7P463 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.55 +2 -2 + NTP_4_2_7P463 + + scripts/ntptrace/invoke-ntptrace.texi@1.65 +2 -2 + NTP_4_2_7P463 + + scripts/ntptrace/ntptrace-opts@1.14 +2 -2 + NTP_4_2_7P463 + + scripts/ntptrace/ntptrace.1ntptraceman@1.54 +6 -6 + NTP_4_2_7P463 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.54 +2 -2 + NTP_4_2_7P463 + + scripts/ntptrace/ntptrace.html@1.66 +2 -2 + NTP_4_2_7P463 + + scripts/ntptrace/ntptrace.man.in@1.54 +6 -6 + NTP_4_2_7P463 + + scripts/ntptrace/ntptrace.mdoc.in@1.55 +2 -2 + NTP_4_2_7P463 + + scripts/plot_summary-opts@1.15 +2 -2 + NTP_4_2_7P463 + + scripts/plot_summary.1plot_summaryman@1.66 +14 -14 + NTP_4_2_7P463 + + scripts/plot_summary.1plot_summarymdoc@1.66 +2 -2 + NTP_4_2_7P463 + + scripts/plot_summary.html@1.68 +2 -2 + NTP_4_2_7P463 + + scripts/plot_summary.man.in@1.66 +14 -14 + NTP_4_2_7P463 + + scripts/plot_summary.mdoc.in@1.66 +2 -2 + NTP_4_2_7P463 + + scripts/summary-opts@1.15 +2 -2 + NTP_4_2_7P463 + + scripts/summary.1summaryman@1.66 +6 -6 + NTP_4_2_7P463 + + scripts/summary.1summarymdoc@1.66 +2 -2 + NTP_4_2_7P463 + + scripts/summary.html@1.68 +2 -2 + NTP_4_2_7P463 + + scripts/summary.man.in@1.66 +6 -6 + NTP_4_2_7P463 + + scripts/summary.mdoc.in@1.66 +2 -2 + NTP_4_2_7P463 + + sntp/invoke-sntp.texi@1.453 +2 -2 + NTP_4_2_7P463 + + sntp/sntp-opts.c@1.470 +6 -6 + NTP_4_2_7P463 + + sntp/sntp-opts.h@1.470 +2 -2 + NTP_4_2_7P463 + + sntp/sntp.1sntpman@1.288 +6 -6 + NTP_4_2_7P463 + + sntp/sntp.1sntpmdoc@1.288 +2 -2 + NTP_4_2_7P463 + + sntp/sntp.html@1.468 +2 -2 + NTP_4_2_7P463 + + sntp/sntp.man.in@1.288 +6 -6 + NTP_4_2_7P463 + + sntp/sntp.mdoc.in@1.288 +2 -2 + NTP_4_2_7P463 + + util/invoke-ntp-keygen.texi@1.457 +2 -2 + NTP_4_2_7P463 + + util/ntp-keygen-opts.c@1.473 +6 -6 + NTP_4_2_7P463 + + util/ntp-keygen-opts.h@1.473 +2 -2 + NTP_4_2_7P463 + + util/ntp-keygen.1ntp-keygenman@1.285 +6 -6 + NTP_4_2_7P463 + + util/ntp-keygen.1ntp-keygenmdoc@1.285 +2 -2 + NTP_4_2_7P463 + + util/ntp-keygen.html@1.133 +2 -2 + NTP_4_2_7P463 + + util/ntp-keygen.man.in@1.285 +6 -6 + NTP_4_2_7P463 + + util/ntp-keygen.mdoc.in@1.285 +2 -2 + NTP_4_2_7P463 + +ChangeSet@1.3182, 2014-08-20 22:14:09+02:00, jnperlin@hydra.(none) + [Bug 2636] Clutter in syslog if gpsd not running + - make driver work with PSD protocol versio 3.9 + - use exponential back-off for connection problems + - implement rate-limit for syslog entries + + ChangeLog@1.1520 +4 -0 + [Bug 2636] Clutter in syslog if gpsd not running + - make driver work with PSD protocol versio 3.9 + - use exponential back-off for connection problems + - implement rate-limit for syslog entries + + html/drivers/driver46.html@1.4 +102 -43 + [Bug 2636] Clutter in syslog if gpsd not running + - documentation update and extension + + ntpd/refclock_gpsdjson.c@1.11 +125 -74 + [Bug 2636] Clutter in syslog if gpsd not running + - make driver work with PSD protocol versio 3.9 + - use exponential back-off for connection problems + - implement rate-limit for syslog entries + +ChangeSet@1.3181, 2014-08-19 22:39:42+02:00, jnperlin@hydra.(none) + [Bug 2636] reduce logging of recurrent/persistent errors to avoid syslog flooding; + adapt to protocol version 3.9 and nanosecond PPS precision. + + html/drivers/driver46.html@1.3 +10 -3 + [Bug 2636] describe fudge flags used for clock stats and log throttle + + ntpd/refclock_gpsdjson.c@1.10 +271 -121 + [Bug 2636] imlement log throttling, adapt to GPSD protoco verdion 3.9 + +ChangeSet@1.3180, 2014-08-16 06:28:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P462 + TAG: NTP_4_2_7P462 + + ChangeLog@1.1519 +1 -0 + NTP_4_2_7P462 + + ntpd/invoke-ntp.conf.texi@1.141 +1 -1 + NTP_4_2_7P462 + + ntpd/invoke-ntp.keys.texi@1.139 +1 -1 + NTP_4_2_7P462 + + ntpd/invoke-ntpd.texi@1.455 +2 -2 + NTP_4_2_7P462 + + ntpd/ntp.conf.5man@1.175 +6 -6 + NTP_4_2_7P462 + + ntpd/ntp.conf.5mdoc@1.175 +2 -2 + NTP_4_2_7P462 + + ntpd/ntp.conf.html@1.136 +1 -1 + NTP_4_2_7P462 + + ntpd/ntp.conf.man.in@1.175 +6 -6 + NTP_4_2_7P462 + + ntpd/ntp.conf.mdoc.in@1.175 +2 -2 + NTP_4_2_7P462 + + ntpd/ntp.keys.5man@1.173 +2 -2 + NTP_4_2_7P462 + + ntpd/ntp.keys.5mdoc@1.173 +2 -2 + NTP_4_2_7P462 + + ntpd/ntp.keys.html@1.137 +1 -1 + NTP_4_2_7P462 + + ntpd/ntp.keys.man.in@1.173 +2 -2 + NTP_4_2_7P462 + + ntpd/ntp.keys.mdoc.in@1.173 +2 -2 + NTP_4_2_7P462 + + ntpd/ntpd-opts.c@1.475 +6 -6 + NTP_4_2_7P462 + + ntpd/ntpd-opts.h@1.475 +2 -2 + NTP_4_2_7P462 + + ntpd/ntpd.1ntpdman@1.284 +6 -6 + NTP_4_2_7P462 + + ntpd/ntpd.1ntpdmdoc@1.284 +2 -2 + NTP_4_2_7P462 + + ntpd/ntpd.html@1.131 +2 -2 + NTP_4_2_7P462 + + ntpd/ntpd.man.in@1.284 +6 -6 + NTP_4_2_7P462 + + ntpd/ntpd.mdoc.in@1.284 +2 -2 + NTP_4_2_7P462 + + ntpdc/invoke-ntpdc.texi@1.453 +2 -2 + NTP_4_2_7P462 + + ntpdc/ntpdc-opts.c@1.470 +6 -6 + NTP_4_2_7P462 + + ntpdc/ntpdc-opts.h@1.470 +2 -2 + NTP_4_2_7P462 + + ntpdc/ntpdc.1ntpdcman@1.284 +13 -13 + NTP_4_2_7P462 + + ntpdc/ntpdc.1ntpdcmdoc@1.284 +2 -2 + NTP_4_2_7P462 + + ntpdc/ntpdc.html@1.297 +2 -2 + NTP_4_2_7P462 + + ntpdc/ntpdc.man.in@1.284 +13 -13 + NTP_4_2_7P462 + + ntpdc/ntpdc.mdoc.in@1.284 +2 -2 + NTP_4_2_7P462 + + ntpq/invoke-ntpq.texi@1.459 +2 -2 + NTP_4_2_7P462 + + ntpq/ntpq-opts.c@1.475 +6 -6 + NTP_4_2_7P462 + + ntpq/ntpq-opts.h@1.474 +2 -2 + NTP_4_2_7P462 + + ntpq/ntpq.1ntpqman@1.287 +6 -6 + NTP_4_2_7P462 + + ntpq/ntpq.1ntpqmdoc@1.287 +2 -2 + NTP_4_2_7P462 + + ntpq/ntpq.html@1.128 +2 -2 + NTP_4_2_7P462 + + ntpq/ntpq.man.in@1.287 +6 -6 + NTP_4_2_7P462 + + ntpq/ntpq.mdoc.in@1.287 +2 -2 + NTP_4_2_7P462 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.455 +2 -2 + NTP_4_2_7P462 + + ntpsnmpd/ntpsnmpd-opts.c@1.472 +6 -6 + NTP_4_2_7P462 + + ntpsnmpd/ntpsnmpd-opts.h@1.472 +2 -2 + NTP_4_2_7P462 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.284 +6 -6 + NTP_4_2_7P462 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.284 +2 -2 + NTP_4_2_7P462 + + ntpsnmpd/ntpsnmpd.html@1.126 +1 -1 + NTP_4_2_7P462 + + ntpsnmpd/ntpsnmpd.man.in@1.284 +6 -6 + NTP_4_2_7P462 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.284 +2 -2 + NTP_4_2_7P462 + + packageinfo.sh@1.466 +1 -1 + NTP_4_2_7P462 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.46 +6 -6 + NTP_4_2_7P462 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.46 +2 -2 + NTP_4_2_7P462 + + scripts/calc_tickadj/calc_tickadj.html@1.47 +1 -1 + NTP_4_2_7P462 + + scripts/calc_tickadj/calc_tickadj.man.in@1.45 +6 -6 + NTP_4_2_7P462 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.46 +2 -2 + NTP_4_2_7P462 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.49 +1 -1 + NTP_4_2_7P462 + + scripts/invoke-plot_summary.texi@1.67 +3 -3 + NTP_4_2_7P462 + + scripts/invoke-summary.texi@1.67 +3 -3 + NTP_4_2_7P462 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.275 +2 -2 + NTP_4_2_7P462 + + scripts/ntp-wait/ntp-wait-opts@1.11 +2 -2 + NTP_4_2_7P462 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.274 +6 -6 + NTP_4_2_7P462 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.274 +2 -2 + NTP_4_2_7P462 + + scripts/ntp-wait/ntp-wait.html@1.292 +2 -2 + NTP_4_2_7P462 + + scripts/ntp-wait/ntp-wait.man.in@1.274 +6 -6 + NTP_4_2_7P462 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.274 +2 -2 + NTP_4_2_7P462 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.64 +2 -2 + NTP_4_2_7P462 + + scripts/ntpsweep/ntpsweep-opts@1.13 +2 -2 + NTP_4_2_7P462 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.53 +6 -6 + NTP_4_2_7P462 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.53 +2 -2 + NTP_4_2_7P462 + + scripts/ntpsweep/ntpsweep.html@1.65 +2 -2 + NTP_4_2_7P462 + + scripts/ntpsweep/ntpsweep.man.in@1.53 +6 -6 + NTP_4_2_7P462 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.54 +2 -2 + NTP_4_2_7P462 + + scripts/ntptrace/invoke-ntptrace.texi@1.64 +2 -2 + NTP_4_2_7P462 + + scripts/ntptrace/ntptrace-opts@1.13 +2 -2 + NTP_4_2_7P462 + + scripts/ntptrace/ntptrace.1ntptraceman@1.53 +6 -6 + NTP_4_2_7P462 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.53 +2 -2 + NTP_4_2_7P462 + + scripts/ntptrace/ntptrace.html@1.65 +2 -2 + NTP_4_2_7P462 + + scripts/ntptrace/ntptrace.man.in@1.53 +6 -6 + NTP_4_2_7P462 + + scripts/ntptrace/ntptrace.mdoc.in@1.54 +2 -2 + NTP_4_2_7P462 + + scripts/plot_summary-opts@1.14 +3 -3 + NTP_4_2_7P462 + + scripts/plot_summary.1plot_summaryman@1.65 +6 -6 + NTP_4_2_7P462 + + scripts/plot_summary.1plot_summarymdoc@1.65 +3 -3 + NTP_4_2_7P462 + + scripts/plot_summary.html@1.67 +3 -3 + NTP_4_2_7P462 + + scripts/plot_summary.man.in@1.65 +6 -6 + NTP_4_2_7P462 + + scripts/plot_summary.mdoc.in@1.65 +3 -3 + NTP_4_2_7P462 + + scripts/summary-opts@1.14 +2 -2 + NTP_4_2_7P462 + + scripts/summary.1summaryman@1.65 +6 -6 + NTP_4_2_7P462 + + scripts/summary.1summarymdoc@1.65 +3 -3 + NTP_4_2_7P462 + + scripts/summary.html@1.67 +3 -3 + NTP_4_2_7P462 + + scripts/summary.man.in@1.65 +6 -6 + NTP_4_2_7P462 + + scripts/summary.mdoc.in@1.65 +2 -2 + NTP_4_2_7P462 + + sntp/invoke-sntp.texi@1.452 +2 -2 + NTP_4_2_7P462 + + sntp/sntp-opts.c@1.469 +6 -6 + NTP_4_2_7P462 + + sntp/sntp-opts.h@1.469 +2 -2 + NTP_4_2_7P462 + + sntp/sntp.1sntpman@1.287 +6 -6 + NTP_4_2_7P462 + + sntp/sntp.1sntpmdoc@1.287 +2 -2 + NTP_4_2_7P462 + + sntp/sntp.html@1.467 +2 -2 + NTP_4_2_7P462 + + sntp/sntp.man.in@1.287 +6 -6 + NTP_4_2_7P462 + + sntp/sntp.mdoc.in@1.287 +2 -2 + NTP_4_2_7P462 + + util/invoke-ntp-keygen.texi@1.456 +2 -2 + NTP_4_2_7P462 + + util/ntp-keygen-opts.c@1.472 +6 -6 + NTP_4_2_7P462 + + util/ntp-keygen-opts.h@1.472 +2 -2 + NTP_4_2_7P462 + + util/ntp-keygen.1ntp-keygenman@1.284 +6 -6 + NTP_4_2_7P462 + + util/ntp-keygen.1ntp-keygenmdoc@1.284 +2 -2 + NTP_4_2_7P462 + + util/ntp-keygen.html@1.132 +2 -2 + NTP_4_2_7P462 + + util/ntp-keygen.man.in@1.284 +6 -6 + NTP_4_2_7P462 + + util/ntp-keygen.mdoc.in@1.284 +2 -2 + NTP_4_2_7P462 + +ChangeSet@1.3177.1.5, 2014-08-14 09:32:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P461 + TAG: NTP_4_2_7P461 + + ChangeLog@1.1516.1.5 +2 -0 + NTP_4_2_7P461 + + ntpd/invoke-ntp.conf.texi@1.140 +1 -1 + NTP_4_2_7P461 + + ntpd/invoke-ntp.keys.texi@1.138 +1 -1 + NTP_4_2_7P461 + + ntpd/invoke-ntpd.texi@1.454 +2 -2 + NTP_4_2_7P461 + + ntpd/ntp.conf.5man@1.174 +6 -6 + NTP_4_2_7P461 + + ntpd/ntp.conf.5mdoc@1.174 +2 -2 + NTP_4_2_7P461 + + ntpd/ntp.conf.html@1.135 +1 -1 + NTP_4_2_7P461 + + ntpd/ntp.conf.man.in@1.174 +6 -6 + NTP_4_2_7P461 + + ntpd/ntp.conf.mdoc.in@1.174 +2 -2 + NTP_4_2_7P461 + + ntpd/ntp.keys.5man@1.172 +2 -2 + NTP_4_2_7P461 + + ntpd/ntp.keys.5mdoc@1.172 +2 -2 + NTP_4_2_7P461 + + ntpd/ntp.keys.html@1.136 +1 -1 + NTP_4_2_7P461 + + ntpd/ntp.keys.man.in@1.172 +2 -2 + NTP_4_2_7P461 + + ntpd/ntp.keys.mdoc.in@1.172 +2 -2 + NTP_4_2_7P461 + + ntpd/ntpd-opts.c@1.474 +6 -6 + NTP_4_2_7P461 + + ntpd/ntpd-opts.h@1.474 +2 -2 + NTP_4_2_7P461 + + ntpd/ntpd.1ntpdman@1.283 +6 -6 + NTP_4_2_7P461 + + ntpd/ntpd.1ntpdmdoc@1.283 +2 -2 + NTP_4_2_7P461 + + ntpd/ntpd.html@1.130 +2 -2 + NTP_4_2_7P461 + + ntpd/ntpd.man.in@1.283 +6 -6 + NTP_4_2_7P461 + + ntpd/ntpd.mdoc.in@1.283 +2 -2 + NTP_4_2_7P461 + + ntpdc/invoke-ntpdc.texi@1.452 +2 -2 + NTP_4_2_7P461 + + ntpdc/ntpdc-opts.c@1.469 +6 -6 + NTP_4_2_7P461 + + ntpdc/ntpdc-opts.h@1.469 +2 -2 + NTP_4_2_7P461 + + ntpdc/ntpdc.1ntpdcman@1.283 +6 -6 + NTP_4_2_7P461 + + ntpdc/ntpdc.1ntpdcmdoc@1.283 +2 -2 + NTP_4_2_7P461 + + ntpdc/ntpdc.html@1.296 +2 -2 + NTP_4_2_7P461 + + ntpdc/ntpdc.man.in@1.283 +6 -6 + NTP_4_2_7P461 + + ntpdc/ntpdc.mdoc.in@1.283 +2 -2 + NTP_4_2_7P461 + + ntpq/invoke-ntpq.texi@1.458 +2 -2 + NTP_4_2_7P461 + + ntpq/ntpq-opts.c@1.474 +6 -6 + NTP_4_2_7P461 + + ntpq/ntpq-opts.h@1.473 +2 -2 + NTP_4_2_7P461 + + ntpq/ntpq.1ntpqman@1.286 +32 -3 + NTP_4_2_7P461 + + ntpq/ntpq.1ntpqmdoc@1.286 +20 -1 + NTP_4_2_7P461 + + ntpq/ntpq.html@1.127 +63 -41 + NTP_4_2_7P461 + + ntpq/ntpq.man.in@1.286 +32 -3 + NTP_4_2_7P461 + + ntpq/ntpq.mdoc.in@1.286 +20 -1 + NTP_4_2_7P461 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.454 +2 -2 + NTP_4_2_7P461 + + ntpsnmpd/ntpsnmpd-opts.c@1.471 +6 -6 + NTP_4_2_7P461 + + ntpsnmpd/ntpsnmpd-opts.h@1.471 +2 -2 + NTP_4_2_7P461 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.283 +6 -6 + NTP_4_2_7P461 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.283 +2 -2 + NTP_4_2_7P461 + + ntpsnmpd/ntpsnmpd.html@1.125 +1 -1 + NTP_4_2_7P461 + + ntpsnmpd/ntpsnmpd.man.in@1.283 +6 -6 + NTP_4_2_7P461 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.283 +2 -2 + NTP_4_2_7P461 + + packageinfo.sh@1.465 +1 -1 + NTP_4_2_7P461 + + scripts/Makefile.am@1.38 +1 -0 + More autogen-5.18.4pre14 cleanup + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.45 +6 -6 + NTP_4_2_7P461 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.45 +2 -2 + NTP_4_2_7P461 + + scripts/calc_tickadj/calc_tickadj.html@1.46 +1 -1 + NTP_4_2_7P461 + + scripts/calc_tickadj/calc_tickadj.man.in@1.44 +6 -6 + NTP_4_2_7P461 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.45 +2 -2 + NTP_4_2_7P461 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.48 +1 -1 + NTP_4_2_7P461 + + scripts/invoke-plot_summary.texi@1.66 +1 -1 + NTP_4_2_7P461 + + scripts/invoke-plot_summary.texi@1.65 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/invoke-summary.texi@1.66 +1 -1 + NTP_4_2_7P461 + + scripts/invoke-summary.texi@1.65 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntp-wait/Makefile.am@1.8 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/ntp-wait/invoke-ntp-wait.texi@1.274 +2 -2 + NTP_4_2_7P461 + + scripts/ntp-wait/ntp-wait-opts@1.10 +2 -2 + NTP_4_2_7P461 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.273 +6 -6 + NTP_4_2_7P461 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.273 +2 -2 + NTP_4_2_7P461 + + scripts/ntp-wait/ntp-wait.html@1.291 +2 -2 + NTP_4_2_7P461 + + scripts/ntp-wait/ntp-wait.man.in@1.273 +6 -6 + NTP_4_2_7P461 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.273 +2 -2 + NTP_4_2_7P461 + + scripts/ntpsweep/Makefile.am@1.9 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/ntpsweep/invoke-ntpsweep.texi@1.63 +2 -2 + NTP_4_2_7P461 + + scripts/ntpsweep/ntpsweep-opts@1.12 +2 -2 + NTP_4_2_7P461 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.52 +13 -13 + NTP_4_2_7P461 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.52 +2 -2 + NTP_4_2_7P461 + + scripts/ntpsweep/ntpsweep.html@1.64 +2 -2 + NTP_4_2_7P461 + + scripts/ntpsweep/ntpsweep.man.in@1.52 +13 -13 + NTP_4_2_7P461 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.53 +2 -2 + NTP_4_2_7P461 + + scripts/ntptrace/Makefile.am@1.9 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/ntptrace/invoke-ntptrace.texi@1.63 +2 -2 + NTP_4_2_7P461 + + scripts/ntptrace/ntptrace-opts@1.12 +2 -2 + NTP_4_2_7P461 + + scripts/ntptrace/ntptrace.1ntptraceman@1.52 +6 -6 + NTP_4_2_7P461 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.52 +2 -2 + NTP_4_2_7P461 + + scripts/ntptrace/ntptrace.html@1.64 +2 -2 + NTP_4_2_7P461 + + scripts/ntptrace/ntptrace.man.in@1.52 +6 -6 + NTP_4_2_7P461 + + scripts/ntptrace/ntptrace.mdoc.in@1.53 +2 -2 + NTP_4_2_7P461 + + scripts/plot_summary-opts@1.13 +1 -1 + NTP_4_2_7P461 + + scripts/plot_summary-opts@1.12 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/plot_summary.1plot_summaryman@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/plot_summary.1plot_summaryman@1.63 +6 -6 + More autogen-5.18.4pre14 cleanup + + scripts/plot_summary.1plot_summarymdoc@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/plot_summary.1plot_summarymdoc@1.63 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/plot_summary.html@1.66 +1 -1 + NTP_4_2_7P461 + + scripts/plot_summary.html@1.65 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/plot_summary.man.in@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/plot_summary.man.in@1.63 +6 -6 + More autogen-5.18.4pre14 cleanup + + scripts/plot_summary.mdoc.in@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/plot_summary.mdoc.in@1.63 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/summary-opts@1.13 +1 -1 + NTP_4_2_7P461 + + scripts/summary-opts@1.12 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/summary.1summaryman@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/summary.1summaryman@1.63 +6 -6 + More autogen-5.18.4pre14 cleanup + + scripts/summary.1summarymdoc@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/summary.1summarymdoc@1.63 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/summary.html@1.66 +1 -1 + NTP_4_2_7P461 + + scripts/summary.html@1.65 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/summary.man.in@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/summary.man.in@1.63 +6 -6 + More autogen-5.18.4pre14 cleanup + + scripts/summary.mdoc.in@1.64 +1 -1 + NTP_4_2_7P461 + + scripts/summary.mdoc.in@1.63 +2 -2 + More autogen-5.18.4pre14 cleanup + + sntp/invoke-sntp.texi@1.451 +2 -2 + NTP_4_2_7P461 + + sntp/sntp-opts.c@1.468 +6 -6 + NTP_4_2_7P461 + + sntp/sntp-opts.h@1.468 +2 -2 + NTP_4_2_7P461 + + sntp/sntp.1sntpman@1.286 +6 -6 + NTP_4_2_7P461 + + sntp/sntp.1sntpmdoc@1.286 +2 -2 + NTP_4_2_7P461 + + sntp/sntp.html@1.466 +2 -2 + NTP_4_2_7P461 + + sntp/sntp.man.in@1.286 +6 -6 + NTP_4_2_7P461 + + sntp/sntp.mdoc.in@1.286 +2 -2 + NTP_4_2_7P461 + + util/invoke-ntp-keygen.texi@1.455 +2 -2 + NTP_4_2_7P461 + + util/ntp-keygen-opts.c@1.471 +6 -6 + NTP_4_2_7P461 + + util/ntp-keygen-opts.h@1.471 +2 -2 + NTP_4_2_7P461 + + util/ntp-keygen.1ntp-keygenman@1.283 +6 -6 + NTP_4_2_7P461 + + util/ntp-keygen.1ntp-keygenmdoc@1.283 +2 -2 + NTP_4_2_7P461 + + util/ntp-keygen.html@1.131 +2 -2 + NTP_4_2_7P461 + + util/ntp-keygen.man.in@1.283 +6 -6 + NTP_4_2_7P461 + + util/ntp-keygen.mdoc.in@1.283 +2 -2 + NTP_4_2_7P461 + +ChangeSet@1.3177.1.4, 2014-08-14 08:27:49+00:00, stenn@psp-fb1.ntp.org + [Bug 1128] ntpq truncates "remote" host information + + ChangeLog@1.1516.1.4 +1 -0 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/invoke-ntpq.texi@1.457 +38 -23 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq-opts.c@1.473 +129 -99 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq-opts.def@1.21 +30 -14 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq-opts.h@1.472 +23 -16 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq-subs.c@1.100 +5 -1 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq.1ntpqman@1.285 +24 -41 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq.1ntpqmdoc@1.285 +22 -30 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq.c@1.152 +4 -0 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq.man.in@1.285 +24 -41 + [Bug 1128] ntpq truncates "remote" host information + + ntpq/ntpq.mdoc.in@1.285 +22 -30 + [Bug 1128] ntpq truncates "remote" host information + +ChangeSet@1.3177.1.3, 2014-08-13 11:49:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P460 + TAG: NTP_4_2_7P460 + + ChangeLog@1.1516.1.3 +1 -0 + NTP_4_2_7P460 + + ntpd/invoke-ntp.conf.texi@1.139 +1 -1 + NTP_4_2_7P460 + + ntpd/invoke-ntp.keys.texi@1.137 +1 -1 + NTP_4_2_7P460 + + ntpd/invoke-ntpd.texi@1.453 +2 -2 + NTP_4_2_7P460 + + ntpd/ntp.conf.5man@1.173 +4 -4 + NTP_4_2_7P460 + + ntpd/ntp.conf.5mdoc@1.173 +1 -1 + NTP_4_2_7P460 + + ntpd/ntp.conf.html@1.134 +1 -1 + NTP_4_2_7P460 + + ntpd/ntp.conf.man.in@1.173 +4 -4 + NTP_4_2_7P460 + + ntpd/ntp.conf.mdoc.in@1.173 +1 -1 + NTP_4_2_7P460 + + ntpd/ntp.keys.5man@1.171 +11 -4 + NTP_4_2_7P460 + + ntpd/ntp.keys.5mdoc@1.171 +7 -3 + NTP_4_2_7P460 + + ntpd/ntp.keys.html@1.135 +1 -1 + NTP_4_2_7P460 + + ntpd/ntp.keys.man.in@1.171 +11 -4 + NTP_4_2_7P460 + + ntpd/ntp.keys.mdoc.in@1.171 +7 -3 + NTP_4_2_7P460 + + ntpd/ntpd-opts.c@1.473 +6 -6 + NTP_4_2_7P460 + + ntpd/ntpd-opts.h@1.473 +2 -2 + NTP_4_2_7P460 + + ntpd/ntpd.1ntpdman@1.282 +4 -4 + NTP_4_2_7P460 + + ntpd/ntpd.1ntpdmdoc@1.282 +1 -1 + NTP_4_2_7P460 + + ntpd/ntpd.html@1.129 +2 -2 + NTP_4_2_7P460 + + ntpd/ntpd.man.in@1.282 +4 -4 + NTP_4_2_7P460 + + ntpd/ntpd.mdoc.in@1.282 +1 -1 + NTP_4_2_7P460 + + ntpdc/invoke-ntpdc.texi@1.451 +2 -2 + NTP_4_2_7P460 + + ntpdc/ntpdc-opts.c@1.468 +6 -6 + NTP_4_2_7P460 + + ntpdc/ntpdc-opts.h@1.468 +2 -2 + NTP_4_2_7P460 + + ntpdc/ntpdc.1ntpdcman@1.282 +4 -4 + NTP_4_2_7P460 + + ntpdc/ntpdc.1ntpdcmdoc@1.282 +1 -1 + NTP_4_2_7P460 + + ntpdc/ntpdc.html@1.295 +2 -2 + NTP_4_2_7P460 + + ntpdc/ntpdc.man.in@1.282 +4 -4 + NTP_4_2_7P460 + + ntpdc/ntpdc.mdoc.in@1.282 +1 -1 + NTP_4_2_7P460 + + ntpq/invoke-ntpq.texi@1.456 +2 -2 + NTP_4_2_7P460 + + ntpq/ntpq-opts.c@1.472 +6 -6 + NTP_4_2_7P460 + + ntpq/ntpq-opts.h@1.471 +2 -2 + NTP_4_2_7P460 + + ntpq/ntpq.1ntpqman@1.284 +4 -4 + NTP_4_2_7P460 + + ntpq/ntpq.1ntpqmdoc@1.284 +1 -1 + NTP_4_2_7P460 + + ntpq/ntpq.html@1.126 +2 -2 + NTP_4_2_7P460 + + ntpq/ntpq.man.in@1.284 +4 -4 + NTP_4_2_7P460 + + ntpq/ntpq.mdoc.in@1.284 +1 -1 + NTP_4_2_7P460 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.453 +2 -2 + NTP_4_2_7P460 + + ntpsnmpd/ntpsnmpd-opts.c@1.470 +6 -6 + NTP_4_2_7P460 + + ntpsnmpd/ntpsnmpd-opts.h@1.470 +2 -2 + NTP_4_2_7P460 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.282 +4 -4 + NTP_4_2_7P460 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.282 +1 -1 + NTP_4_2_7P460 + + ntpsnmpd/ntpsnmpd.html@1.124 +1 -1 + NTP_4_2_7P460 + + ntpsnmpd/ntpsnmpd.man.in@1.282 +4 -4 + NTP_4_2_7P460 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.282 +1 -1 + NTP_4_2_7P460 + + packageinfo.sh@1.464 +1 -1 + NTP_4_2_7P460 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.44 +4 -4 + NTP_4_2_7P460 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.44 +1 -1 + NTP_4_2_7P460 + + scripts/calc_tickadj/calc_tickadj.html@1.45 +22 -34 + NTP_4_2_7P460 + + scripts/calc_tickadj/calc_tickadj.man.in@1.43 +4 -4 + NTP_4_2_7P460 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.44 +1 -1 + NTP_4_2_7P460 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.47 +1 -1 + NTP_4_2_7P460 + + scripts/invoke-plot_summary.texi@1.64 +2 -2 + NTP_4_2_7P460 + + scripts/invoke-summary.texi@1.64 +2 -2 + NTP_4_2_7P460 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.273 +2 -2 + NTP_4_2_7P460 + + scripts/ntp-wait/ntp-wait-opts@1.9 +2 -2 + NTP_4_2_7P460 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.272 +4 -4 + NTP_4_2_7P460 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.272 +1 -1 + NTP_4_2_7P460 + + scripts/ntp-wait/ntp-wait.html@1.290 +31 -49 + NTP_4_2_7P460 + + scripts/ntp-wait/ntp-wait.man.in@1.272 +4 -4 + NTP_4_2_7P460 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.272 +1 -1 + NTP_4_2_7P460 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.62 +2 -2 + NTP_4_2_7P460 + + scripts/ntpsweep/ntpsweep-opts@1.11 +2 -2 + NTP_4_2_7P460 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.51 +12 -12 + NTP_4_2_7P460 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.51 +1 -1 + NTP_4_2_7P460 + + scripts/ntpsweep/ntpsweep.html@1.63 +33 -44 + NTP_4_2_7P460 + + scripts/ntpsweep/ntpsweep.man.in@1.51 +12 -12 + NTP_4_2_7P460 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.52 +1 -1 + NTP_4_2_7P460 + + scripts/ntptrace/invoke-ntptrace.texi@1.62 +2 -2 + NTP_4_2_7P460 + + scripts/ntptrace/ntptrace-opts@1.11 +2 -2 + NTP_4_2_7P460 + + scripts/ntptrace/ntptrace.1ntptraceman@1.51 +4 -4 + NTP_4_2_7P460 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.51 +1 -1 + NTP_4_2_7P460 + + scripts/ntptrace/ntptrace.html@1.63 +27 -36 + NTP_4_2_7P460 + + scripts/ntptrace/ntptrace.man.in@1.51 +4 -4 + NTP_4_2_7P460 + + scripts/ntptrace/ntptrace.mdoc.in@1.52 +1 -1 + NTP_4_2_7P460 + + scripts/plot_summary-opts@1.11 +2 -2 + NTP_4_2_7P460 + + scripts/plot_summary.1plot_summaryman@1.62 +4 -4 + NTP_4_2_7P460 + + scripts/plot_summary.1plot_summarymdoc@1.62 +1 -1 + NTP_4_2_7P460 + + scripts/plot_summary.html@1.64 +29 -47 + NTP_4_2_7P460 + + scripts/plot_summary.man.in@1.62 +4 -4 + NTP_4_2_7P460 + + scripts/plot_summary.mdoc.in@1.62 +1 -1 + NTP_4_2_7P460 + + scripts/summary-opts@1.11 +2 -2 + NTP_4_2_7P460 + + scripts/summary.1summaryman@1.62 +4 -4 + NTP_4_2_7P460 + + scripts/summary.1summarymdoc@1.62 +1 -1 + NTP_4_2_7P460 + + scripts/summary.html@1.64 +27 -39 + NTP_4_2_7P460 + + scripts/summary.man.in@1.62 +4 -4 + NTP_4_2_7P460 + + scripts/summary.mdoc.in@1.62 +1 -1 + NTP_4_2_7P460 + + sntp/invoke-sntp.texi@1.450 +2 -2 + NTP_4_2_7P460 + + sntp/sntp-opts.c@1.467 +6 -6 + NTP_4_2_7P460 + + sntp/sntp-opts.h@1.467 +2 -2 + NTP_4_2_7P460 + + sntp/sntp.1sntpman@1.285 +4 -4 + NTP_4_2_7P460 + + sntp/sntp.1sntpmdoc@1.285 +1 -1 + NTP_4_2_7P460 + + sntp/sntp.html@1.465 +2 -2 + NTP_4_2_7P460 + + sntp/sntp.man.in@1.285 +4 -4 + NTP_4_2_7P460 + + sntp/sntp.mdoc.in@1.285 +1 -1 + NTP_4_2_7P460 + + util/invoke-ntp-keygen.texi@1.454 +2 -2 + NTP_4_2_7P460 + + util/ntp-keygen-opts.c@1.470 +6 -6 + NTP_4_2_7P460 + + util/ntp-keygen-opts.h@1.470 +2 -2 + NTP_4_2_7P460 + + util/ntp-keygen.1ntp-keygenman@1.282 +4 -4 + NTP_4_2_7P460 + + util/ntp-keygen.1ntp-keygenmdoc@1.282 +1 -1 + NTP_4_2_7P460 + + util/ntp-keygen.html@1.130 +2 -2 + NTP_4_2_7P460 + + util/ntp-keygen.man.in@1.282 +4 -4 + NTP_4_2_7P460 + + util/ntp-keygen.mdoc.in@1.282 +1 -1 + NTP_4_2_7P460 + +ChangeSet@1.3177.1.2, 2014-08-13 10:36:39+00:00, stenn@psp-fb1.ntp.org + More autogen-5.18.4pre14 cleanup + + BitKeeper/deleted/00/mdoc2man~8fe2ef1ce14f0f8e@1.4 +0 -0 + Delete: sntp/ag-tpl/Old/mdoc2man + + BitKeeper/deleted/0f/agman-file.tpl~e66d0c3c8f6fdd@1.4 +0 -0 + Delete: sntp/ag-tpl/Old/agman-file.tpl + + BitKeeper/deleted/63/agtexi-cmd.tpl~2f8da79991e6b4d4@1.4 +0 -0 + Delete: sntp/ag-tpl/Old/agtexi-cmd.tpl + + BitKeeper/deleted/80/agmdoc-file.tpl~4fa7cc72899a18a3@1.4 +0 -0 + Delete: sntp/ag-tpl/Old/agmdoc-file.tpl + + BitKeeper/deleted/a6/cmd-doc.tlib~e55de6df878a7dcc@1.4 +0 -0 + Delete: sntp/ag-tpl/Old/cmd-doc.tlib + + ChangeLog@1.1516.1.2 +1 -0 + More autogen-5.18.4pre14 cleanup + + ntpd/ntpdsim-opts.c@1.27 +6 -6 + More autogen-5.18.4pre14 cleanup + + ntpd/ntpdsim-opts.h@1.27 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/Makefile.am@1.37 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/calc_tickadj/Makefile.am@1.9 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/calc_tickadj/calc_tickadj-opts@1.7 +3 -3 + More autogen-5.18.4pre14 cleanup + + scripts/calc_tickadj/calc_tickadj.html@1.44 +35 -23 + More autogen-5.18.4pre14 cleanup + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.46 +3 -3 + More autogen-5.18.4pre14 cleanup + + scripts/invoke-plot_summary.texi@1.63 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/invoke-summary.texi@1.63 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntp-wait/Makefile.am@1.7 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/ntp-wait/invoke-ntp-wait.texi@1.272 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntp-wait/ntp-wait-opts@1.8 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntp-wait/ntp-wait.html@1.289 +48 -30 + More autogen-5.18.4pre14 cleanup + + scripts/ntpsweep/Makefile.am@1.8 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/ntpsweep/invoke-ntpsweep.texi@1.61 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntpsweep/ntpsweep-opts@1.10 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntpsweep/ntpsweep.html@1.62 +43 -32 + More autogen-5.18.4pre14 cleanup + + scripts/ntptrace/Makefile.am@1.8 +1 -1 + More autogen-5.18.4pre14 cleanup + + scripts/ntptrace/invoke-ntptrace.texi@1.61 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntptrace/ntptrace-opts@1.10 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/ntptrace/ntptrace.html@1.62 +35 -26 + More autogen-5.18.4pre14 cleanup + + scripts/plot_summary-opts@1.10 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/plot_summary.html@1.63 +46 -28 + More autogen-5.18.4pre14 cleanup + + scripts/summary-opts@1.10 +2 -2 + More autogen-5.18.4pre14 cleanup + + scripts/summary.html@1.63 +38 -26 + More autogen-5.18.4pre14 cleanup + + sntp/ag-tpl/:Old/Mdoc.pm@1.3 +0 -0 + Rename: sntp/ag-tpl/Mdoc.pm -> sntp/ag-tpl/:Old/Mdoc.pm + + sntp/ag-tpl/:Old/agman-cmd.tpl@1.2 +0 -0 + Rename: sntp/ag-tpl/agman-cmd.tpl -> sntp/ag-tpl/:Old/agman-cmd.tpl + + sntp/ag-tpl/:Old/agmdoc-cmd.tpl@1.3 +0 -0 + Rename: sntp/ag-tpl/agmdoc-cmd.tpl -> sntp/ag-tpl/:Old/agmdoc-cmd.tpl + + sntp/ag-tpl/:Old/cmd-doc.tlib@1.2 +0 -0 + Rename: sntp/ag-tpl/cmd-doc.tlib -> sntp/ag-tpl/:Old/cmd-doc.tlib + + sntp/ag-tpl/:Old/mdoc-synopsis.tlib@1.2 +0 -0 + Rename: sntp/ag-tpl/mdoc-synopsis.tlib -> sntp/ag-tpl/:Old/mdoc-synopsis.tlib + + sntp/ag-tpl/:Old/mdoc2man@1.3 +0 -0 + Rename: sntp/ag-tpl/mdoc2man -> sntp/ag-tpl/:Old/mdoc2man + + sntp/ag-tpl/:Old/mdoc2texi@1.10 +0 -0 + Rename: sntp/ag-tpl/mdoc2texi -> sntp/ag-tpl/:Old/mdoc2texi + + sntp/ag-tpl/:Old/perlopt.tpl@1.4 +0 -0 + Rename: sntp/ag-tpl/perlopt.tpl -> sntp/ag-tpl/:Old/perlopt.tpl + +ChangeSet@1.3177.1.1, 2014-08-13 08:38:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P459 + TAG: NTP_4_2_7P459 + + ChangeLog@1.1516.1.1 +1 -0 + NTP_4_2_7P459 + + ntpd/invoke-ntp.conf.texi@1.138 +1 -1 + NTP_4_2_7P459 + + ntpd/invoke-ntp.keys.texi@1.136 +1 -1 + NTP_4_2_7P459 + + ntpd/invoke-ntpd.texi@1.452 +2 -2 + NTP_4_2_7P459 + + ntpd/ntp.conf.5man@1.172 +4 -4 + NTP_4_2_7P459 + + ntpd/ntp.conf.5mdoc@1.172 +1 -1 + NTP_4_2_7P459 + + ntpd/ntp.conf.html@1.133 +1 -1 + NTP_4_2_7P459 + + ntpd/ntp.conf.man.in@1.172 +4 -4 + NTP_4_2_7P459 + + ntpd/ntp.conf.mdoc.in@1.172 +1 -1 + NTP_4_2_7P459 + + ntpd/ntp.keys.5man@1.170 +1 -1 + NTP_4_2_7P459 + + ntpd/ntp.keys.5mdoc@1.170 +1 -1 + NTP_4_2_7P459 + + ntpd/ntp.keys.html@1.134 +1 -1 + NTP_4_2_7P459 + + ntpd/ntp.keys.man.in@1.170 +1 -1 + NTP_4_2_7P459 + + ntpd/ntp.keys.mdoc.in@1.170 +1 -1 + NTP_4_2_7P459 + + ntpd/ntpd-opts.c@1.472 +6 -6 + NTP_4_2_7P459 + + ntpd/ntpd-opts.h@1.472 +2 -2 + NTP_4_2_7P459 + + ntpd/ntpd.1ntpdman@1.281 +4 -4 + NTP_4_2_7P459 + + ntpd/ntpd.1ntpdmdoc@1.281 +1 -1 + NTP_4_2_7P459 + + ntpd/ntpd.html@1.128 +2 -2 + NTP_4_2_7P459 + + ntpd/ntpd.man.in@1.281 +4 -4 + NTP_4_2_7P459 + + ntpd/ntpd.mdoc.in@1.281 +1 -1 + NTP_4_2_7P459 + + ntpdc/invoke-ntpdc.texi@1.450 +2 -2 + NTP_4_2_7P459 + + ntpdc/ntpdc-opts.c@1.467 +6 -6 + NTP_4_2_7P459 + + ntpdc/ntpdc-opts.h@1.467 +2 -2 + NTP_4_2_7P459 + + ntpdc/ntpdc.1ntpdcman@1.281 +12 -12 + NTP_4_2_7P459 + + ntpdc/ntpdc.1ntpdcmdoc@1.281 +1 -1 + NTP_4_2_7P459 + + ntpdc/ntpdc.html@1.294 +2 -2 + NTP_4_2_7P459 + + ntpdc/ntpdc.man.in@1.281 +12 -12 + NTP_4_2_7P459 + + ntpdc/ntpdc.mdoc.in@1.281 +1 -1 + NTP_4_2_7P459 + + ntpq/invoke-ntpq.texi@1.455 +2 -2 + NTP_4_2_7P459 + + ntpq/ntpq-opts.c@1.471 +6 -6 + NTP_4_2_7P459 + + ntpq/ntpq-opts.h@1.470 +2 -2 + NTP_4_2_7P459 + + ntpq/ntpq.1ntpqman@1.283 +4 -4 + NTP_4_2_7P459 + + ntpq/ntpq.1ntpqmdoc@1.283 +1 -1 + NTP_4_2_7P459 + + ntpq/ntpq.html@1.125 +4 -4 + NTP_4_2_7P459 + + ntpq/ntpq.man.in@1.283 +4 -4 + NTP_4_2_7P459 + + ntpq/ntpq.mdoc.in@1.283 +1 -1 + NTP_4_2_7P459 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.452 +2 -2 + NTP_4_2_7P459 + + ntpsnmpd/ntpsnmpd-opts.c@1.469 +6 -6 + NTP_4_2_7P459 + + ntpsnmpd/ntpsnmpd-opts.h@1.469 +2 -2 + NTP_4_2_7P459 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.281 +4 -4 + NTP_4_2_7P459 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.281 +1 -1 + NTP_4_2_7P459 + + ntpsnmpd/ntpsnmpd.html@1.123 +1 -1 + NTP_4_2_7P459 + + ntpsnmpd/ntpsnmpd.man.in@1.281 +4 -4 + NTP_4_2_7P459 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.281 +1 -1 + NTP_4_2_7P459 + + packageinfo.sh@1.463 +1 -1 + NTP_4_2_7P459 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.43 +4 -4 + NTP_4_2_7P459 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.43 +1 -1 + NTP_4_2_7P459 + + scripts/calc_tickadj/calc_tickadj.html@1.43 +1 -1 + NTP_4_2_7P459 + + scripts/calc_tickadj/calc_tickadj.man.in@1.42 +4 -4 + NTP_4_2_7P459 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.43 +1 -1 + NTP_4_2_7P459 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.45 +1 -1 + NTP_4_2_7P459 + + scripts/invoke-plot_summary.texi@1.62 +2 -2 + NTP_4_2_7P459 + + scripts/invoke-summary.texi@1.62 +2 -2 + NTP_4_2_7P459 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.271 +2 -2 + NTP_4_2_7P459 + + scripts/ntp-wait/ntp-wait-opts@1.7 +1 -1 + NTP_4_2_7P459 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.271 +4 -4 + NTP_4_2_7P459 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.271 +1 -1 + NTP_4_2_7P459 + + scripts/ntp-wait/ntp-wait.html@1.288 +2 -2 + NTP_4_2_7P459 + + scripts/ntp-wait/ntp-wait.man.in@1.271 +4 -4 + NTP_4_2_7P459 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.271 +1 -1 + NTP_4_2_7P459 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.60 +2 -2 + NTP_4_2_7P459 + + scripts/ntpsweep/ntpsweep-opts@1.9 +1 -1 + NTP_4_2_7P459 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.50 +4 -4 + NTP_4_2_7P459 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.50 +1 -1 + NTP_4_2_7P459 + + scripts/ntpsweep/ntpsweep.html@1.61 +2 -2 + NTP_4_2_7P459 + + scripts/ntpsweep/ntpsweep.man.in@1.50 +4 -4 + NTP_4_2_7P459 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.51 +1 -1 + NTP_4_2_7P459 + + scripts/ntptrace/invoke-ntptrace.texi@1.60 +2 -2 + NTP_4_2_7P459 + + scripts/ntptrace/ntptrace-opts@1.9 +1 -1 + NTP_4_2_7P459 + + scripts/ntptrace/ntptrace.1ntptraceman@1.50 +4 -4 + NTP_4_2_7P459 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.50 +1 -1 + NTP_4_2_7P459 + + scripts/ntptrace/ntptrace.html@1.61 +2 -2 + NTP_4_2_7P459 + + scripts/ntptrace/ntptrace.man.in@1.50 +4 -4 + NTP_4_2_7P459 + + scripts/ntptrace/ntptrace.mdoc.in@1.51 +1 -1 + NTP_4_2_7P459 + + scripts/plot_summary-opts@1.9 +1 -1 + NTP_4_2_7P459 + + scripts/plot_summary.1plot_summaryman@1.61 +4 -4 + NTP_4_2_7P459 + + scripts/plot_summary.1plot_summarymdoc@1.61 +1 -1 + NTP_4_2_7P459 + + scripts/plot_summary.html@1.62 +2 -2 + NTP_4_2_7P459 + + scripts/plot_summary.man.in@1.61 +4 -4 + NTP_4_2_7P459 + + scripts/plot_summary.mdoc.in@1.61 +1 -1 + NTP_4_2_7P459 + + scripts/summary-opts@1.9 +1 -1 + NTP_4_2_7P459 + + scripts/summary.1summaryman@1.61 +4 -4 + NTP_4_2_7P459 + + scripts/summary.1summarymdoc@1.61 +1 -1 + NTP_4_2_7P459 + + scripts/summary.html@1.62 +2 -2 + NTP_4_2_7P459 + + scripts/summary.man.in@1.61 +4 -4 + NTP_4_2_7P459 + + scripts/summary.mdoc.in@1.61 +1 -1 + NTP_4_2_7P459 + + sntp/invoke-sntp.texi@1.449 +2 -2 + NTP_4_2_7P459 + + sntp/sntp-opts.c@1.466 +6 -6 + NTP_4_2_7P459 + + sntp/sntp-opts.h@1.466 +2 -2 + NTP_4_2_7P459 + + sntp/sntp.1sntpman@1.284 +4 -4 + NTP_4_2_7P459 + + sntp/sntp.1sntpmdoc@1.284 +1 -1 + NTP_4_2_7P459 + + sntp/sntp.html@1.464 +2 -2 + NTP_4_2_7P459 + + sntp/sntp.man.in@1.284 +4 -4 + NTP_4_2_7P459 + + sntp/sntp.mdoc.in@1.284 +1 -1 + NTP_4_2_7P459 + + util/invoke-ntp-keygen.texi@1.453 +2 -2 + NTP_4_2_7P459 + + util/ntp-keygen-opts.c@1.469 +6 -6 + NTP_4_2_7P459 + + util/ntp-keygen-opts.h@1.469 +2 -2 + NTP_4_2_7P459 + + util/ntp-keygen.1ntp-keygenman@1.281 +4 -4 + NTP_4_2_7P459 + + util/ntp-keygen.1ntp-keygenmdoc@1.281 +1 -1 + NTP_4_2_7P459 + + util/ntp-keygen.html@1.129 +2 -2 + NTP_4_2_7P459 + + util/ntp-keygen.man.in@1.281 +4 -4 + NTP_4_2_7P459 + + util/ntp-keygen.mdoc.in@1.281 +1 -1 + NTP_4_2_7P459 + +ChangeSet@1.3178, 2014-08-12 20:29:54+02:00, jnperlin@hydra.(none) + [Bug 2622] Synchronisation problem using SHM [...] + Add 'control' function to SHM driver-- fudge values not available during start. + + ChangeLog@1.1517 +2 -0 + [Bug 2622] Synchronisation problem using SHM [...] + Add 'control' function -- fudge values not available during start. + + ntpd/refclock_shm.c@1.29 +38 -9 + [Bug 2622] Synchronisation problem using SHM [...] + Add 'control' function -- fudge values not available during start. + +ChangeSet@1.3177, 2014-08-12 02:08:55-04:00, stenn@deacon.udel.edu + Try bison-3.0.2 instead of bison-2.5 + + ChangeLog@1.1516 +1 -0 + Try bison-3.0.2 instead of bison-2.5 + + ntpd/ntp_parser.c@1.88 +1109 -1510 + Try bison-3.0.2 instead of bison-2.5 + + ntpd/ntp_parser.h@1.54 +215 -211 + Try bison-3.0.2 instead of bison-2.5 + +ChangeSet@1.3176, 2014-08-12 02:01:01-04:00, stenn@deacon.udel.edu + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ChangeLog@1.1515 +1 -0 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ntpq/invoke-ntpq.texi@1.454 +3 -3 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ntpq/ntpq-opts.c@1.470 +1 -1 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ntpq/ntpq-opts.def@1.20 +1 -1 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ntpq/ntpq.1ntpqman@1.282 +5 -5 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ntpq/ntpq.1ntpqmdoc@1.282 +2 -2 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ntpq/ntpq.man.in@1.282 +5 -5 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + + ntpq/ntpq.mdoc.in@1.282 +2 -2 + [Bug 2630] Limit the ntpq command buffer to 512 bytes + +ChangeSet@1.3175, 2014-08-12 02:08:30+00:00, stenn@psp-fb1.ntp.org + FlexeLint cleanups + + ChangeLog@1.1514 +1 -0 + FlexeLint cleanups + +ChangeSet@1.3172.1.2, 2014-08-12 01:27:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P458 + TAG: NTP_4_2_7P458 + + ChangeLog@1.1513 +1 -0 + NTP_4_2_7P458 + + ntpd/invoke-ntp.conf.texi@1.137 +1 -1 + NTP_4_2_7P458 + + ntpd/invoke-ntp.keys.texi@1.135 +1 -1 + NTP_4_2_7P458 + + ntpd/invoke-ntpd.texi@1.451 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.conf.5man@1.171 +4 -4 + NTP_4_2_7P458 + + ntpd/ntp.conf.5mdoc@1.171 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.conf.html@1.132 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.conf.man.in@1.171 +4 -4 + NTP_4_2_7P458 + + ntpd/ntp.conf.mdoc.in@1.171 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.keys.5man@1.169 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.keys.5mdoc@1.169 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.keys.html@1.133 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.keys.man.in@1.169 +1 -1 + NTP_4_2_7P458 + + ntpd/ntp.keys.mdoc.in@1.169 +1 -1 + NTP_4_2_7P458 + + ntpd/ntpd-opts.c@1.471 +6 -6 + NTP_4_2_7P458 + + ntpd/ntpd-opts.h@1.471 +2 -2 + NTP_4_2_7P458 + + ntpd/ntpd.1ntpdman@1.280 +4 -4 + NTP_4_2_7P458 + + ntpd/ntpd.1ntpdmdoc@1.280 +1 -1 + NTP_4_2_7P458 + + ntpd/ntpd.html@1.127 +2 -2 + NTP_4_2_7P458 + + ntpd/ntpd.man.in@1.280 +4 -4 + NTP_4_2_7P458 + + ntpd/ntpd.mdoc.in@1.280 +1 -1 + NTP_4_2_7P458 + + ntpdc/invoke-ntpdc.texi@1.449 +1 -1 + NTP_4_2_7P458 + + ntpdc/ntpdc-opts.c@1.466 +6 -6 + NTP_4_2_7P458 + + ntpdc/ntpdc-opts.h@1.466 +2 -2 + NTP_4_2_7P458 + + ntpdc/ntpdc.1ntpdcman@1.280 +4 -4 + NTP_4_2_7P458 + + ntpdc/ntpdc.1ntpdcmdoc@1.280 +1 -1 + NTP_4_2_7P458 + + ntpdc/ntpdc.html@1.293 +2 -2 + NTP_4_2_7P458 + + ntpdc/ntpdc.man.in@1.280 +4 -4 + NTP_4_2_7P458 + + ntpdc/ntpdc.mdoc.in@1.280 +1 -1 + NTP_4_2_7P458 + + ntpq/invoke-ntpq.texi@1.453 +1 -1 + NTP_4_2_7P458 + + ntpq/ntpq-opts.c@1.469 +6 -6 + NTP_4_2_7P458 + + ntpq/ntpq-opts.h@1.469 +2 -2 + NTP_4_2_7P458 + + ntpq/ntpq.1ntpqman@1.281 +4 -4 + NTP_4_2_7P458 + + ntpq/ntpq.1ntpqmdoc@1.281 +1 -1 + NTP_4_2_7P458 + + ntpq/ntpq.html@1.124 +27 -26 + NTP_4_2_7P458 + + ntpq/ntpq.man.in@1.281 +4 -4 + NTP_4_2_7P458 + + ntpq/ntpq.mdoc.in@1.281 +1 -1 + NTP_4_2_7P458 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.451 +1 -1 + NTP_4_2_7P458 + + ntpsnmpd/ntpsnmpd-opts.c@1.468 +6 -6 + NTP_4_2_7P458 + + ntpsnmpd/ntpsnmpd-opts.h@1.468 +2 -2 + NTP_4_2_7P458 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.280 +4 -4 + NTP_4_2_7P458 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.280 +1 -1 + NTP_4_2_7P458 + + ntpsnmpd/ntpsnmpd.html@1.122 +1 -1 + NTP_4_2_7P458 + + ntpsnmpd/ntpsnmpd.man.in@1.280 +4 -4 + NTP_4_2_7P458 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.280 +1 -1 + NTP_4_2_7P458 + + packageinfo.sh@1.462 +1 -1 + NTP_4_2_7P458 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.42 +4 -4 + NTP_4_2_7P458 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.42 +1 -1 + NTP_4_2_7P458 + + scripts/calc_tickadj/calc_tickadj.html@1.42 +1 -1 + NTP_4_2_7P458 + + scripts/calc_tickadj/calc_tickadj.man.in@1.41 +4 -4 + NTP_4_2_7P458 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.42 +1 -1 + NTP_4_2_7P458 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.44 +1 -1 + NTP_4_2_7P458 + + scripts/invoke-plot_summary.texi@1.61 +1 -1 + NTP_4_2_7P458 + + scripts/invoke-summary.texi@1.61 +1 -1 + NTP_4_2_7P458 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.270 +1 -1 + NTP_4_2_7P458 + + scripts/ntp-wait/ntp-wait-opts@1.6 +1 -1 + NTP_4_2_7P458 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.270 +4 -4 + NTP_4_2_7P458 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.270 +1 -1 + NTP_4_2_7P458 + + scripts/ntp-wait/ntp-wait.html@1.287 +2 -2 + NTP_4_2_7P458 + + scripts/ntp-wait/ntp-wait.man.in@1.270 +4 -4 + NTP_4_2_7P458 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.270 +1 -1 + NTP_4_2_7P458 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.59 +1 -1 + NTP_4_2_7P458 + + scripts/ntpsweep/ntpsweep-opts@1.8 +1 -1 + NTP_4_2_7P458 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.49 +4 -4 + NTP_4_2_7P458 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.49 +1 -1 + NTP_4_2_7P458 + + scripts/ntpsweep/ntpsweep.html@1.60 +2 -2 + NTP_4_2_7P458 + + scripts/ntpsweep/ntpsweep.man.in@1.49 +4 -4 + NTP_4_2_7P458 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.50 +1 -1 + NTP_4_2_7P458 + + scripts/ntptrace/invoke-ntptrace.texi@1.59 +1 -1 + NTP_4_2_7P458 + + scripts/ntptrace/ntptrace-opts@1.8 +1 -1 + NTP_4_2_7P458 + + scripts/ntptrace/ntptrace.1ntptraceman@1.49 +4 -4 + NTP_4_2_7P458 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.49 +1 -1 + NTP_4_2_7P458 + + scripts/ntptrace/ntptrace.html@1.60 +2 -2 + NTP_4_2_7P458 + + scripts/ntptrace/ntptrace.man.in@1.49 +4 -4 + NTP_4_2_7P458 + + scripts/ntptrace/ntptrace.mdoc.in@1.50 +1 -1 + NTP_4_2_7P458 + + scripts/plot_summary-opts@1.8 +1 -1 + NTP_4_2_7P458 + + scripts/plot_summary.1plot_summaryman@1.60 +4 -4 + NTP_4_2_7P458 + + scripts/plot_summary.1plot_summarymdoc@1.60 +1 -1 + NTP_4_2_7P458 + + scripts/plot_summary.html@1.61 +2 -2 + NTP_4_2_7P458 + + scripts/plot_summary.man.in@1.60 +4 -4 + NTP_4_2_7P458 + + scripts/plot_summary.mdoc.in@1.60 +1 -1 + NTP_4_2_7P458 + + scripts/summary-opts@1.8 +1 -1 + NTP_4_2_7P458 + + scripts/summary.1summaryman@1.60 +4 -4 + NTP_4_2_7P458 + + scripts/summary.1summarymdoc@1.60 +1 -1 + NTP_4_2_7P458 + + scripts/summary.html@1.61 +2 -2 + NTP_4_2_7P458 + + scripts/summary.man.in@1.60 +4 -4 + NTP_4_2_7P458 + + scripts/summary.mdoc.in@1.60 +1 -1 + NTP_4_2_7P458 + + sntp/invoke-sntp.texi@1.448 +1 -1 + NTP_4_2_7P458 + + sntp/sntp-opts.c@1.465 +6 -6 + NTP_4_2_7P458 + + sntp/sntp-opts.h@1.465 +2 -2 + NTP_4_2_7P458 + + sntp/sntp.1sntpman@1.283 +4 -4 + NTP_4_2_7P458 + + sntp/sntp.1sntpmdoc@1.283 +1 -1 + NTP_4_2_7P458 + + sntp/sntp.html@1.463 +2 -2 + NTP_4_2_7P458 + + sntp/sntp.man.in@1.283 +4 -4 + NTP_4_2_7P458 + + sntp/sntp.mdoc.in@1.283 +1 -1 + NTP_4_2_7P458 + + util/invoke-ntp-keygen.texi@1.452 +1 -1 + NTP_4_2_7P458 + + util/ntp-keygen-opts.c@1.468 +6 -6 + NTP_4_2_7P458 + + util/ntp-keygen-opts.h@1.468 +2 -2 + NTP_4_2_7P458 + + util/ntp-keygen.1ntp-keygenman@1.280 +4 -4 + NTP_4_2_7P458 + + util/ntp-keygen.1ntp-keygenmdoc@1.280 +1 -1 + NTP_4_2_7P458 + + util/ntp-keygen.html@1.128 +2 -2 + NTP_4_2_7P458 + + util/ntp-keygen.man.in@1.280 +4 -4 + NTP_4_2_7P458 + + util/ntp-keygen.mdoc.in@1.280 +1 -1 + NTP_4_2_7P458 + +ChangeSet@1.3172.1.1, 2014-08-10 22:26:19+00:00, stenn@psp-fb1.ntp.org + [Bug 2633] Provide stdnoreturn.h for windows port + + ChangeLog@1.1512 +1 -0 + [Bug 2633] Provide stdnoreturn.h for windows port + + ports/winnt/include/hopf_PCI_io.h@1.3 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/include/stdnoreturn.h@1.1 +61 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/ports/winnt/include/stdnoreturn.h + + ports/winnt/include/stdnoreturn.h@1.0 +0 -0 + +ChangeSet@1.3173, 2014-08-09 20:32:45+00:00, phk@psp-fb1.ntp.org + ntp.h, ntp_proto.c: + Don't do arithmetic on NULL pointer when we have a real pointer to use + ntp_parser.y, ntp_config.c: + A set of no-op pedantic changes inspired by FlexeLints complaints, + while looking for ways to make the simulator work again: + + Add prototype for yyparser() until bison joins the century of the fruit-bat. + Make some functions static. + Spell NTP_INSIST() INSIST() + Deal with "SIM-only" stuff in ntp_parser.y rather than later. + Mark knowingly unused arguments + Signed/Unsigned/Long fixes to constants. + Const char* argument to fprintf(3). + ntp_assert.h: + Use systems assert(3) for FlexeLint analysis + + include/ntp.h@1.210 +1 -2 + Don't do arithmetic on NULL pointer when we have a real pointer to use + + include/ntp_assert.h@1.8 +12 -1 + Use systems assert(3) for FlexeLint analysis + + ntpd/ntp_config.c@1.320 +59 -50 + A set of no-op pedantic changes inspired by FlexeLints complaints, + while looking for ways to make the simulator work again: + + Add prototype for yyparser() until bison joins the century of the fruit-bat. + Make some functions static. + Spell NTP_INSIST() INSIST() + Deal with "SIM-only" stuff in ntp_parser.y rather than later. + Mark knowingly unused arguments + Signed/Unsigned/Long fixes to constants. + Const char* argument to fprintf(3). + + ntpd/ntp_parser.c@1.87 +187 -181 + A set of no-op pedantic changes inspired by FlexeLints complaints, + while looking for ways to make the simulator work again: + + Add prototype for yyparser() until bison joins the century of the fruit-bat. + Make some functions static. + Spell NTP_INSIST() INSIST() + Deal with "SIM-only" stuff in ntp_parser.y rather than later. + Mark knowingly unused arguments + Signed/Unsigned/Long fixes to constants. + Const char* argument to fprintf(3). + + ntpd/ntp_parser.h@1.53 +1 -1 + + ntpd/ntp_parser.y@1.81 +8 -2 + + ntpd/ntp_proto.c@1.349 +1 -1 + Don't do arithmetic on NULL pointer when we have a real pointer to use + +ChangeSet@1.3172, 2014-08-09 11:04:13+00:00, stenn@deacon.udel.edu + NTP_4_2_7P457 + TAG: NTP_4_2_7P457 + + ChangeLog@1.1511 +1 -0 + NTP_4_2_7P457 + + ntpd/invoke-ntp.conf.texi@1.136 +1 -1 + NTP_4_2_7P457 + + ntpd/invoke-ntp.keys.texi@1.134 +1 -1 + NTP_4_2_7P457 + + ntpd/invoke-ntpd.texi@1.450 +2 -2 + NTP_4_2_7P457 + + ntpd/ntp.conf.5man@1.170 +6 -6 + NTP_4_2_7P457 + + ntpd/ntp.conf.5mdoc@1.170 +2 -2 + NTP_4_2_7P457 + + ntpd/ntp.conf.html@1.131 +1 -1 + NTP_4_2_7P457 + + ntpd/ntp.conf.man.in@1.170 +6 -6 + NTP_4_2_7P457 + + ntpd/ntp.conf.mdoc.in@1.170 +2 -2 + NTP_4_2_7P457 + + ntpd/ntp.keys.5man@1.168 +2 -2 + NTP_4_2_7P457 + + ntpd/ntp.keys.5mdoc@1.168 +2 -2 + NTP_4_2_7P457 + + ntpd/ntp.keys.html@1.132 +1 -1 + NTP_4_2_7P457 + + ntpd/ntp.keys.man.in@1.168 +2 -2 + NTP_4_2_7P457 + + ntpd/ntp.keys.mdoc.in@1.168 +2 -2 + NTP_4_2_7P457 + + ntpd/ntpd-opts.c@1.470 +6 -6 + NTP_4_2_7P457 + + ntpd/ntpd-opts.h@1.470 +2 -2 + NTP_4_2_7P457 + + ntpd/ntpd.1ntpdman@1.279 +6 -6 + NTP_4_2_7P457 + + ntpd/ntpd.1ntpdmdoc@1.279 +2 -2 + NTP_4_2_7P457 + + ntpd/ntpd.html@1.126 +2 -2 + NTP_4_2_7P457 + + ntpd/ntpd.man.in@1.279 +6 -6 + NTP_4_2_7P457 + + ntpd/ntpd.mdoc.in@1.279 +2 -2 + NTP_4_2_7P457 + + ntpdc/invoke-ntpdc.texi@1.448 +2 -2 + NTP_4_2_7P457 + + ntpdc/ntpdc-opts.c@1.465 +6 -6 + NTP_4_2_7P457 + + ntpdc/ntpdc-opts.h@1.465 +2 -2 + NTP_4_2_7P457 + + ntpdc/ntpdc.1ntpdcman@1.279 +13 -13 + NTP_4_2_7P457 + + ntpdc/ntpdc.1ntpdcmdoc@1.279 +2 -2 + NTP_4_2_7P457 + + ntpdc/ntpdc.html@1.292 +2 -2 + NTP_4_2_7P457 + + ntpdc/ntpdc.man.in@1.279 +13 -13 + NTP_4_2_7P457 + + ntpdc/ntpdc.mdoc.in@1.279 +2 -2 + NTP_4_2_7P457 + + ntpq/invoke-ntpq.texi@1.452 +28 -26 + NTP_4_2_7P457 + + ntpq/ntpq-opts.c@1.468 +6 -6 + NTP_4_2_7P457 + + ntpq/ntpq-opts.h@1.468 +2 -2 + NTP_4_2_7P457 + + ntpq/ntpq.1ntpqman@1.280 +43 -34 + NTP_4_2_7P457 + + ntpq/ntpq.1ntpqmdoc@1.280 +31 -28 + NTP_4_2_7P457 + + ntpq/ntpq.html@1.123 +2 -2 + NTP_4_2_7P457 + + ntpq/ntpq.man.in@1.280 +43 -34 + NTP_4_2_7P457 + + ntpq/ntpq.mdoc.in@1.280 +31 -28 + NTP_4_2_7P457 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.450 +2 -2 + NTP_4_2_7P457 + + ntpsnmpd/ntpsnmpd-opts.c@1.467 +6 -6 + NTP_4_2_7P457 + + ntpsnmpd/ntpsnmpd-opts.h@1.467 +2 -2 + NTP_4_2_7P457 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.279 +6 -6 + NTP_4_2_7P457 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.279 +2 -2 + NTP_4_2_7P457 + + ntpsnmpd/ntpsnmpd.html@1.121 +1 -1 + NTP_4_2_7P457 + + ntpsnmpd/ntpsnmpd.man.in@1.279 +6 -6 + NTP_4_2_7P457 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.279 +2 -2 + NTP_4_2_7P457 + + packageinfo.sh@1.461 +1 -1 + NTP_4_2_7P457 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.41 +6 -6 + NTP_4_2_7P457 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.41 +2 -2 + NTP_4_2_7P457 + + scripts/calc_tickadj/calc_tickadj.html@1.41 +23 -35 + NTP_4_2_7P457 + + scripts/calc_tickadj/calc_tickadj.man.in@1.40 +6 -6 + NTP_4_2_7P457 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.41 +2 -2 + NTP_4_2_7P457 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.43 +1 -1 + NTP_4_2_7P457 + + scripts/invoke-plot_summary.texi@1.60 +1 -1 + NTP_4_2_7P457 + + scripts/invoke-summary.texi@1.60 +1 -1 + NTP_4_2_7P457 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.269 +1 -1 + NTP_4_2_7P457 + + scripts/ntp-wait/ntp-wait-opts@1.5 +1 -1 + NTP_4_2_7P457 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.269 +6 -6 + NTP_4_2_7P457 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.269 +2 -2 + NTP_4_2_7P457 + + scripts/ntp-wait/ntp-wait.html@1.286 +31 -49 + NTP_4_2_7P457 + + scripts/ntp-wait/ntp-wait.man.in@1.269 +6 -6 + NTP_4_2_7P457 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.269 +2 -2 + NTP_4_2_7P457 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.58 +1 -1 + NTP_4_2_7P457 + + scripts/ntpsweep/ntpsweep-opts@1.7 +1 -1 + NTP_4_2_7P457 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.48 +6 -6 + NTP_4_2_7P457 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.48 +2 -2 + NTP_4_2_7P457 + + scripts/ntpsweep/ntpsweep.html@1.59 +33 -44 + NTP_4_2_7P457 + + scripts/ntpsweep/ntpsweep.man.in@1.48 +6 -6 + NTP_4_2_7P457 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.49 +2 -2 + NTP_4_2_7P457 + + scripts/ntptrace/invoke-ntptrace.texi@1.58 +1 -1 + NTP_4_2_7P457 + + scripts/ntptrace/ntptrace-opts@1.7 +1 -1 + NTP_4_2_7P457 + + scripts/ntptrace/ntptrace.1ntptraceman@1.48 +6 -6 + NTP_4_2_7P457 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.48 +2 -2 + NTP_4_2_7P457 + + scripts/ntptrace/ntptrace.html@1.59 +27 -36 + NTP_4_2_7P457 + + scripts/ntptrace/ntptrace.man.in@1.48 +6 -6 + NTP_4_2_7P457 + + scripts/ntptrace/ntptrace.mdoc.in@1.49 +2 -2 + NTP_4_2_7P457 + + scripts/plot_summary-opts@1.7 +1 -1 + NTP_4_2_7P457 + + scripts/plot_summary.1plot_summaryman@1.59 +6 -6 + NTP_4_2_7P457 + + scripts/plot_summary.1plot_summarymdoc@1.59 +2 -2 + NTP_4_2_7P457 + + scripts/plot_summary.html@1.60 +29 -47 + NTP_4_2_7P457 + + scripts/plot_summary.man.in@1.59 +6 -6 + NTP_4_2_7P457 + + scripts/plot_summary.mdoc.in@1.59 +2 -2 + NTP_4_2_7P457 + + scripts/summary-opts@1.7 +1 -1 + NTP_4_2_7P457 + + scripts/summary.1summaryman@1.59 +6 -6 + NTP_4_2_7P457 + + scripts/summary.1summarymdoc@1.59 +2 -2 + NTP_4_2_7P457 + + scripts/summary.html@1.60 +27 -39 + NTP_4_2_7P457 + + scripts/summary.man.in@1.59 +6 -6 + NTP_4_2_7P457 + + scripts/summary.mdoc.in@1.59 +2 -2 + NTP_4_2_7P457 + + sntp/invoke-sntp.texi@1.447 +2 -2 + NTP_4_2_7P457 + + sntp/sntp-opts.c@1.464 +6 -6 + NTP_4_2_7P457 + + sntp/sntp-opts.h@1.464 +2 -2 + NTP_4_2_7P457 + + sntp/sntp.1sntpman@1.282 +6 -6 + NTP_4_2_7P457 + + sntp/sntp.1sntpmdoc@1.282 +2 -2 + NTP_4_2_7P457 + + sntp/sntp.html@1.462 +2 -2 + NTP_4_2_7P457 + + sntp/sntp.man.in@1.282 +6 -6 + NTP_4_2_7P457 + + sntp/sntp.mdoc.in@1.282 +2 -2 + NTP_4_2_7P457 + + util/invoke-ntp-keygen.texi@1.451 +2 -2 + NTP_4_2_7P457 + + util/ntp-keygen-opts.c@1.467 +6 -6 + NTP_4_2_7P457 + + util/ntp-keygen-opts.h@1.467 +2 -2 + NTP_4_2_7P457 + + util/ntp-keygen.1ntp-keygenman@1.279 +6 -6 + NTP_4_2_7P457 + + util/ntp-keygen.1ntp-keygenmdoc@1.279 +2 -2 + NTP_4_2_7P457 + + util/ntp-keygen.html@1.127 +2 -2 + NTP_4_2_7P457 + + util/ntp-keygen.man.in@1.279 +6 -6 + NTP_4_2_7P457 + + util/ntp-keygen.mdoc.in@1.279 +2 -2 + NTP_4_2_7P457 + +ChangeSet@1.3171, 2014-08-09 07:02:16-04:00, stenn@deacon.udel.edu + Update .point-changed-filelist + + .point-changed-filelist@1.25 +5 -0 + Update .point-changed-filelist + +ChangeSet@1.3156.2.2, 2014-08-09 08:17:47+00:00, phk@psp-fb1.ntp.org + Typo fix + + ChangeLog@1.1502.2.2 +1 -1 + Typo fix + +ChangeSet@1.3168, 2014-08-09 08:00:44+00:00, stenn@psp-fb1.ntp.org + Added Brian Utterback to the copyright file + + html/copyright.html@1.65 +2 -1 + Added Brian Utterback to the copyright file + +ChangeSet@1.3167, 2014-08-09 07:51:01+00:00, stenn@psp-fb1.ntp.org + autogen-5.18.4pre14 + + scripts/calc_tickadj/calc_tickadj.html@1.40 +1 -1 + autogen-5.18.4pre14 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.42 +3 -3 + autogen-5.18.4pre14 + + scripts/invoke-plot_summary.texi@1.59 +10 -10 + autogen-5.18.4pre14 + + scripts/invoke-summary.texi@1.59 +9 -9 + autogen-5.18.4pre14 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.268 +3 -3 + autogen-5.18.4pre14 + + scripts/ntp-wait/ntp-wait.html@1.285 +49 -31 + autogen-5.18.4pre14 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.57 +3 -3 + autogen-5.18.4pre14 + + scripts/ntpsweep/ntpsweep.html@1.58 +1 -1 + autogen-5.18.4pre14 + + scripts/ntptrace/invoke-ntptrace.texi@1.57 +3 -3 + autogen-5.18.4pre14 + + scripts/ntptrace/ntptrace.html@1.58 +1 -1 + autogen-5.18.4pre14 + + scripts/plot_summary.html@1.59 +1 -1 + autogen-5.18.4pre14 + + scripts/summary.html@1.59 +1 -1 + autogen-5.18.4pre14 + +ChangeSet@1.3166, 2014-08-09 07:27:03+00:00, stenn@psp-fb1.ntp.org + autogen-5.18.4pre14 + + ntpd/ntpd-opts.c@1.469 +7 -7 + autogen-5.18.4pre14 + + ntpd/ntpd-opts.h@1.469 +3 -3 + autogen-5.18.4pre14 + + ntpd/ntpdsim-opts.c@1.26 +7 -7 + autogen-5.18.4pre14 + + ntpd/ntpdsim-opts.h@1.26 +3 -3 + autogen-5.18.4pre14 + + ntpdc/ntpdc-opts.c@1.464 +7 -7 + autogen-5.18.4pre14 + + ntpdc/ntpdc-opts.h@1.464 +3 -3 + autogen-5.18.4pre14 + + ntpq/ntpq-opts.c@1.467 +7 -7 + autogen-5.18.4pre14 + + ntpq/ntpq-opts.h@1.467 +3 -3 + autogen-5.18.4pre14 + + ntpsnmpd/ntpsnmpd-opts.c@1.466 +7 -7 + autogen-5.18.4pre14 + + ntpsnmpd/ntpsnmpd-opts.h@1.466 +3 -3 + autogen-5.18.4pre14 + + scripts/calc_tickadj/calc_tickadj-opts@1.6 +2 -2 + autogen-5.18.4pre14 + + scripts/ntp-wait/ntp-wait-opts@1.4 +2 -2 + autogen-5.18.4pre14 + + scripts/ntpsweep/ntpsweep-opts@1.6 +2 -2 + autogen-5.18.4pre14 + + scripts/ntptrace/ntptrace-opts@1.6 +2 -2 + autogen-5.18.4pre14 + + scripts/plot_summary-opts@1.6 +2 -2 + autogen-5.18.4pre14 + + scripts/summary-opts@1.6 +2 -2 + autogen-5.18.4pre14 + + sntp/sntp-opts.c@1.463 +7 -7 + autogen-5.18.4pre14 + + sntp/sntp-opts.h@1.463 +3 -3 + autogen-5.18.4pre14 + + util/ntp-keygen-opts.c@1.466 +7 -7 + autogen-5.18.4pre14 + + util/ntp-keygen-opts.h@1.466 +3 -3 + autogen-5.18.4pre14 + +ChangeSet@1.3165, 2014-08-09 07:16:25+00:00, stenn@psp-fb1.ntp.org + autogen-5.18.4pre14 + + ChangeLog@1.1508 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/Makefile.am@1.27 +3 -3 + autogen-5.18.4pre14 + + sntp/libopts/ag-char-map.h@1.30 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/ao-strs.c@1.16 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/ao-strs.h@1.15 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/genshell.c@1.30 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/genshell.h@1.30 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/option-value-type.c@1.17 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/option-value-type.h@1.31 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/option-xat-attribute.c@1.17 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/option-xat-attribute.h@1.31 +1 -1 + autogen-5.18.4pre14 + + sntp/libopts/proto.h@1.30 +1 -1 + autogen-5.18.4pre14 + +ChangeSet@1.3156.1.12, 2014-08-08 22:47:50+02:00, jnperlin@hydra.(none) + implement new logic to define difference limit and limit check with SHM clock (driver28) + + html/drivers/driver28.html@1.16 +25 -5 + updated docs to describe flag1 and time2 + + ntpd/refclock_shm.c@1.28 +125 -55 + use time2 for difference limit and flag1 to disable distance limit check + +ChangeSet@1.3156.2.1, 2014-08-08 09:54:12+00:00, phk@psp-fb1.ntp.org + Pass the configration source into the parser as argument rather than through a global variable + + ChangeLog@1.1502.2.1 +2 -0 + Changelog entry + + ntpd/ntp_config.c@1.319 +2 -5 + Pass config file source to yyparse() as argument, not through global variable + + ntpd/ntp_parser.c@1.86 +610 -558 + Pass config file source to yyparse() as argument, not through global variable + + ntpd/ntp_parser.h@1.52 +7 -9 + Pass config file source to yyparse() as argument, not through global variable + + ntpd/ntp_parser.y@1.80 +13 -13 + Pass config file source to yyparse() as argument, not through global variable + + ntpd/ntp_scanner.c@1.44 +13 -15 + Pass config file source to yyparse() as argument, not through global variable + + ntpd/ntp_scanner.h@1.18 +1 -5 + Pass config file source to yyparse() as argument, not through global variable + +ChangeSet@1.3164, 2014-08-08 09:31:03+00:00, stenn@psp-fb1.ntp.org + autogen-5.18.4pre12 + + ntpd/ntpd-opts.c@1.468 +8 -8 + autogen-5.18.4pre12 + + ntpd/ntpd-opts.h@1.468 +11 -11 + autogen-5.18.4pre12 + + ntpd/ntpdsim-opts.c@1.25 +7 -7 + autogen-5.18.4pre12 + + ntpd/ntpdsim-opts.h@1.25 +3 -3 + autogen-5.18.4pre12 + + ntpdc/ntpdc-opts.c@1.463 +8 -8 + autogen-5.18.4pre12 + + ntpdc/ntpdc-opts.h@1.463 +13 -13 + autogen-5.18.4pre12 + + ntpq/ntpq-opts.c@1.466 +8 -8 + autogen-5.18.4pre12 + + ntpq/ntpq-opts.h@1.466 +13 -13 + autogen-5.18.4pre12 + + ntpsnmpd/ntpsnmpd-opts.c@1.465 +8 -8 + autogen-5.18.4pre12 + + ntpsnmpd/ntpsnmpd-opts.h@1.465 +13 -13 + autogen-5.18.4pre12 + + scripts/calc_tickadj/calc_tickadj-opts@1.5 +2 -2 + autogen-5.18.4pre12 + + scripts/ntpsweep/ntpsweep-opts@1.5 +2 -2 + autogen-5.18.4pre12 + + scripts/ntptrace/ntptrace-opts@1.5 +2 -2 + autogen-5.18.4pre12 + + scripts/plot_summary-opts@1.5 +2 -2 + autogen-5.18.4pre12 + + scripts/summary-opts@1.5 +2 -2 + autogen-5.18.4pre12 + + util/ntp-keygen-opts.c@1.465 +8 -8 + autogen-5.18.4pre12 + + util/ntp-keygen-opts.h@1.465 +13 -13 + autogen-5.18.4pre12 + +ChangeSet@1.3163, 2014-08-08 09:24:12+00:00, stenn@psp-fb1.ntp.org + autogen-5.18.4pre12 + + sntp/libopts/Makefile.am@1.26 +19 -26 + autogen-5.18.4pre12 + + sntp/libopts/ag-char-map.h@1.29 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/ao-strs.c@1.15 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/ao-strs.h@1.14 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/autoopts/options.h@1.28 +26 -5 + autogen-5.18.4pre12 + + sntp/libopts/autoopts/usage-txt.h@1.28 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/genshell.c@1.29 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/genshell.h@1.29 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/m4/libopts.m4@1.32 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/option-value-type.c@1.16 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/option-value-type.h@1.30 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/option-xat-attribute.c@1.16 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/option-xat-attribute.h@1.30 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/proto.h@1.29 +1 -1 + autogen-5.18.4pre12 + + sntp/libopts/version.c@1.18 +0 -2 + autogen-5.18.4pre12 + + sntp/sntp-opts.c@1.462 +8 -8 + autogen-5.18.4pre12 + + sntp/sntp-opts.h@1.462 +13 -13 + autogen-5.18.4pre12 + +ChangeSet@1.3156.1.11, 2014-08-07 21:24:29+02:00, jnperlin@hydra.(none) + [Bug 2622] Change SHM driver so TOY restricted API is not used any more. (Plus some minor cleanup in logic and flow control) + + ChangeLog@1.1502.1.9 +3 -0 + [Bug 2622] change SHM driver so TOY restricted API is not used any more. (Plus some minor cleanup in logic and flow control) + + ntpd/refclock_shm.c@1.27 +106 -103 + [Bug 2622] Change SHM driver so TOY restricted API is not used any more. (Plus some minor cleanup in logic and flow control) + +ChangeSet@1.3156.1.10, 2014-08-07 09:34:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P456 + TAG: NTP_4_2_7P456 + + ChangeLog@1.1502.1.8 +1 -0 + NTP_4_2_7P456 + + ntpd/invoke-ntp.conf.texi@1.135 +1 -1 + NTP_4_2_7P456 + + ntpd/invoke-ntp.keys.texi@1.133 +1 -1 + NTP_4_2_7P456 + + ntpd/invoke-ntpd.texi@1.449 +2 -2 + NTP_4_2_7P456 + + ntpd/ntp.conf.5man@1.169 +6 -6 + NTP_4_2_7P456 + + ntpd/ntp.conf.5mdoc@1.169 +2 -2 + NTP_4_2_7P456 + + ntpd/ntp.conf.html@1.130 +1 -1 + NTP_4_2_7P456 + + ntpd/ntp.conf.man.in@1.169 +6 -6 + NTP_4_2_7P456 + + ntpd/ntp.conf.mdoc.in@1.169 +2 -2 + NTP_4_2_7P456 + + ntpd/ntp.keys.5man@1.167 +2 -2 + NTP_4_2_7P456 + + ntpd/ntp.keys.5mdoc@1.167 +2 -2 + NTP_4_2_7P456 + + ntpd/ntp.keys.html@1.131 +1 -1 + NTP_4_2_7P456 + + ntpd/ntp.keys.man.in@1.167 +2 -2 + NTP_4_2_7P456 + + ntpd/ntp.keys.mdoc.in@1.167 +2 -2 + NTP_4_2_7P456 + + ntpd/ntpd-opts.c@1.464.1.3 +7 -7 + NTP_4_2_7P456 + + ntpd/ntpd-opts.h@1.464.1.3 +3 -3 + NTP_4_2_7P456 + + ntpd/ntpd.1ntpdman@1.278 +6 -6 + NTP_4_2_7P456 + + ntpd/ntpd.1ntpdmdoc@1.278 +2 -2 + NTP_4_2_7P456 + + ntpd/ntpd.html@1.125 +2 -2 + NTP_4_2_7P456 + + ntpd/ntpd.man.in@1.278 +6 -6 + NTP_4_2_7P456 + + ntpd/ntpd.mdoc.in@1.278 +2 -2 + NTP_4_2_7P456 + + ntpdc/invoke-ntpdc.texi@1.447 +2 -2 + NTP_4_2_7P456 + + ntpdc/ntpdc-opts.c@1.459.1.3 +7 -7 + NTP_4_2_7P456 + + ntpdc/ntpdc-opts.h@1.459.1.3 +3 -3 + NTP_4_2_7P456 + + ntpdc/ntpdc.1ntpdcman@1.278 +6 -6 + NTP_4_2_7P456 + + ntpdc/ntpdc.1ntpdcmdoc@1.278 +2 -2 + NTP_4_2_7P456 + + ntpdc/ntpdc.html@1.291 +2 -2 + NTP_4_2_7P456 + + ntpdc/ntpdc.man.in@1.278 +6 -6 + NTP_4_2_7P456 + + ntpdc/ntpdc.mdoc.in@1.278 +2 -2 + NTP_4_2_7P456 + + ntpq/invoke-ntpq.texi@1.448.1.3 +2 -2 + NTP_4_2_7P456 + + ntpq/ntpq-opts.c@1.462.1.3 +7 -7 + NTP_4_2_7P456 + + ntpq/ntpq-opts.h@1.462.1.3 +3 -3 + NTP_4_2_7P456 + + ntpq/ntpq.1ntpqman@1.276.1.3 +6 -6 + NTP_4_2_7P456 + + ntpq/ntpq.1ntpqmdoc@1.276.1.3 +2 -2 + NTP_4_2_7P456 + + ntpq/ntpq.html@1.122 +2 -2 + NTP_4_2_7P456 + + ntpq/ntpq.man.in@1.276.1.3 +6 -6 + NTP_4_2_7P456 + + ntpq/ntpq.mdoc.in@1.276.1.3 +2 -2 + NTP_4_2_7P456 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.449 +2 -2 + NTP_4_2_7P456 + + ntpsnmpd/ntpsnmpd-opts.c@1.461.1.3 +7 -7 + NTP_4_2_7P456 + + ntpsnmpd/ntpsnmpd-opts.h@1.461.1.3 +3 -3 + NTP_4_2_7P456 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.278 +6 -6 + NTP_4_2_7P456 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.278 +2 -2 + NTP_4_2_7P456 + + ntpsnmpd/ntpsnmpd.html@1.120 +1 -1 + NTP_4_2_7P456 + + ntpsnmpd/ntpsnmpd.man.in@1.278 +6 -6 + NTP_4_2_7P456 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.278 +2 -2 + NTP_4_2_7P456 + + packageinfo.sh@1.460 +1 -1 + NTP_4_2_7P456 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.40 +6 -6 + NTP_4_2_7P456 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.40 +2 -2 + NTP_4_2_7P456 + + scripts/calc_tickadj/calc_tickadj.html@1.36.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/calc_tickadj/calc_tickadj.man.in@1.39 +6 -6 + NTP_4_2_7P456 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.40 +2 -2 + NTP_4_2_7P456 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.38.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/invoke-plot_summary.texi@1.55.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/invoke-summary.texi@1.55.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.267 +1 -1 + NTP_4_2_7P456 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.268 +6 -6 + NTP_4_2_7P456 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.268 +2 -2 + NTP_4_2_7P456 + + scripts/ntp-wait/ntp-wait.html@1.284 +1 -1 + NTP_4_2_7P456 + + scripts/ntp-wait/ntp-wait.man.in@1.268 +6 -6 + NTP_4_2_7P456 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.268 +2 -2 + NTP_4_2_7P456 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.53.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.47 +6 -6 + NTP_4_2_7P456 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.47 +2 -2 + NTP_4_2_7P456 + + scripts/ntpsweep/ntpsweep.html@1.54.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/ntpsweep/ntpsweep.man.in@1.47 +6 -6 + NTP_4_2_7P456 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.48 +2 -2 + NTP_4_2_7P456 + + scripts/ntptrace/invoke-ntptrace.texi@1.53.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/ntptrace/ntptrace.1ntptraceman@1.47 +6 -6 + NTP_4_2_7P456 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.47 +2 -2 + NTP_4_2_7P456 + + scripts/ntptrace/ntptrace.html@1.54.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/ntptrace/ntptrace.man.in@1.47 +6 -6 + NTP_4_2_7P456 + + scripts/ntptrace/ntptrace.mdoc.in@1.48 +2 -2 + NTP_4_2_7P456 + + scripts/plot_summary.1plot_summaryman@1.58 +6 -6 + NTP_4_2_7P456 + + scripts/plot_summary.1plot_summarymdoc@1.58 +2 -2 + NTP_4_2_7P456 + + scripts/plot_summary.html@1.55.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/plot_summary.man.in@1.58 +6 -6 + NTP_4_2_7P456 + + scripts/plot_summary.mdoc.in@1.58 +2 -2 + NTP_4_2_7P456 + + scripts/summary.1summaryman@1.58 +6 -6 + NTP_4_2_7P456 + + scripts/summary.1summarymdoc@1.58 +2 -2 + NTP_4_2_7P456 + + scripts/summary.html@1.55.1.3 +1 -1 + NTP_4_2_7P456 + + scripts/summary.man.in@1.58 +6 -6 + NTP_4_2_7P456 + + scripts/summary.mdoc.in@1.58 +2 -2 + NTP_4_2_7P456 + + sntp/invoke-sntp.texi@1.446 +2 -2 + NTP_4_2_7P456 + + sntp/sntp-opts.c@1.458.1.3 +7 -7 + NTP_4_2_7P456 + + sntp/sntp-opts.h@1.458.1.3 +3 -3 + NTP_4_2_7P456 + + sntp/sntp.1sntpman@1.281 +6 -6 + NTP_4_2_7P456 + + sntp/sntp.1sntpmdoc@1.281 +2 -2 + NTP_4_2_7P456 + + sntp/sntp.html@1.461 +2 -2 + NTP_4_2_7P456 + + sntp/sntp.man.in@1.281 +6 -6 + NTP_4_2_7P456 + + sntp/sntp.mdoc.in@1.281 +2 -2 + NTP_4_2_7P456 + + util/invoke-ntp-keygen.texi@1.450 +2 -2 + NTP_4_2_7P456 + + util/ntp-keygen-opts.c@1.461.1.3 +7 -7 + NTP_4_2_7P456 + + util/ntp-keygen-opts.h@1.461.1.3 +3 -3 + NTP_4_2_7P456 + + util/ntp-keygen.1ntp-keygenman@1.278 +13 -13 + NTP_4_2_7P456 + + util/ntp-keygen.1ntp-keygenmdoc@1.278 +2 -2 + NTP_4_2_7P456 + + util/ntp-keygen.html@1.126 +2 -2 + NTP_4_2_7P456 + + util/ntp-keygen.man.in@1.278 +13 -13 + NTP_4_2_7P456 + + util/ntp-keygen.mdoc.in@1.278 +2 -2 + NTP_4_2_7P456 + +ChangeSet@1.3156.1.9, 2014-08-07 07:07:31+00:00, stenn@psp-fb1.ntp.org + CID 739722: Change the way the extention and MAC fields are processed + + ChangeLog@1.1502.1.7 +1 -0 + CID 739722: Change the way the extention and MAC fields are processed + + sntp/networking.c@1.64 +6 -6 + CID 739722: Change the way the extention and MAC fields are processed + +ChangeSet@1.3156.1.8, 2014-08-06 22:22:18+02:00, jnperlin@hydra.(none) + Work around Coverity issue over mismatch of formal and paket layout. + + sntp/networking.c@1.63 +47 -24 + Move skipping over extension fields into a pointer-based separate function. + Should deal with coverity issue with formal/actual structure layout. + Also easier to read. + +ChangeSet@1.3156.1.7, 2014-08-03 09:34:31+00:00, stenn@deacon.udel.edu + NTP_4_2_7P455 + TAG: NTP_4_2_7P455 + + ChangeLog@1.1502.1.6 +1 -0 + NTP_4_2_7P455 + + ntpd/invoke-ntp.conf.texi@1.134 +1 -1 + NTP_4_2_7P455 + + ntpd/invoke-ntp.keys.texi@1.132 +1 -1 + NTP_4_2_7P455 + + ntpd/invoke-ntpd.texi@1.448 +2 -2 + NTP_4_2_7P455 + + ntpd/ntp.conf.5man@1.168 +6 -6 + NTP_4_2_7P455 + + ntpd/ntp.conf.5mdoc@1.168 +2 -2 + NTP_4_2_7P455 + + ntpd/ntp.conf.html@1.129 +1 -1 + NTP_4_2_7P455 + + ntpd/ntp.conf.man.in@1.168 +6 -6 + NTP_4_2_7P455 + + ntpd/ntp.conf.mdoc.in@1.168 +2 -2 + NTP_4_2_7P455 + + ntpd/ntp.keys.5man@1.166 +2 -2 + NTP_4_2_7P455 + + ntpd/ntp.keys.5mdoc@1.166 +2 -2 + NTP_4_2_7P455 + + ntpd/ntp.keys.html@1.130 +1 -1 + NTP_4_2_7P455 + + ntpd/ntp.keys.man.in@1.166 +2 -2 + NTP_4_2_7P455 + + ntpd/ntp.keys.mdoc.in@1.166 +2 -2 + NTP_4_2_7P455 + + ntpd/ntpd-opts.c@1.464.1.2 +7 -7 + NTP_4_2_7P455 + + ntpd/ntpd-opts.h@1.464.1.2 +3 -3 + NTP_4_2_7P455 + + ntpd/ntpd.1ntpdman@1.277 +6 -6 + NTP_4_2_7P455 + + ntpd/ntpd.1ntpdmdoc@1.277 +2 -2 + NTP_4_2_7P455 + + ntpd/ntpd.html@1.124 +2 -2 + NTP_4_2_7P455 + + ntpd/ntpd.man.in@1.277 +6 -6 + NTP_4_2_7P455 + + ntpd/ntpd.mdoc.in@1.277 +2 -2 + NTP_4_2_7P455 + + ntpdc/invoke-ntpdc.texi@1.446 +2 -2 + NTP_4_2_7P455 + + ntpdc/ntpdc-opts.c@1.459.1.2 +7 -7 + NTP_4_2_7P455 + + ntpdc/ntpdc-opts.h@1.459.1.2 +3 -3 + NTP_4_2_7P455 + + ntpdc/ntpdc.1ntpdcman@1.277 +6 -6 + NTP_4_2_7P455 + + ntpdc/ntpdc.1ntpdcmdoc@1.277 +2 -2 + NTP_4_2_7P455 + + ntpdc/ntpdc.html@1.290 +2 -2 + NTP_4_2_7P455 + + ntpdc/ntpdc.man.in@1.277 +6 -6 + NTP_4_2_7P455 + + ntpdc/ntpdc.mdoc.in@1.277 +2 -2 + NTP_4_2_7P455 + + ntpq/invoke-ntpq.texi@1.448.1.2 +2 -2 + NTP_4_2_7P455 + + ntpq/ntpq-opts.c@1.462.1.2 +7 -7 + NTP_4_2_7P455 + + ntpq/ntpq-opts.h@1.462.1.2 +3 -3 + NTP_4_2_7P455 + + ntpq/ntpq.1ntpqman@1.276.1.2 +6 -6 + NTP_4_2_7P455 + + ntpq/ntpq.1ntpqmdoc@1.276.1.2 +2 -2 + NTP_4_2_7P455 + + ntpq/ntpq.html@1.121 +2 -2 + NTP_4_2_7P455 + + ntpq/ntpq.man.in@1.276.1.2 +6 -6 + NTP_4_2_7P455 + + ntpq/ntpq.mdoc.in@1.276.1.2 +2 -2 + NTP_4_2_7P455 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.448 +2 -2 + NTP_4_2_7P455 + + ntpsnmpd/ntpsnmpd-opts.c@1.461.1.2 +7 -7 + NTP_4_2_7P455 + + ntpsnmpd/ntpsnmpd-opts.h@1.461.1.2 +3 -3 + NTP_4_2_7P455 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.277 +6 -6 + NTP_4_2_7P455 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.277 +2 -2 + NTP_4_2_7P455 + + ntpsnmpd/ntpsnmpd.html@1.119 +1 -1 + NTP_4_2_7P455 + + ntpsnmpd/ntpsnmpd.man.in@1.277 +6 -6 + NTP_4_2_7P455 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.277 +2 -2 + NTP_4_2_7P455 + + packageinfo.sh@1.459 +1 -1 + NTP_4_2_7P455 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.39 +6 -6 + NTP_4_2_7P455 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.39 +2 -2 + NTP_4_2_7P455 + + scripts/calc_tickadj/calc_tickadj.html@1.36.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/calc_tickadj/calc_tickadj.man.in@1.38 +6 -6 + NTP_4_2_7P455 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.39 +2 -2 + NTP_4_2_7P455 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.38.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/invoke-plot_summary.texi@1.55.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/invoke-summary.texi@1.55.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.266 +1 -1 + NTP_4_2_7P455 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.267 +6 -6 + NTP_4_2_7P455 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.267 +2 -2 + NTP_4_2_7P455 + + scripts/ntp-wait/ntp-wait.html@1.283 +1 -1 + NTP_4_2_7P455 + + scripts/ntp-wait/ntp-wait.man.in@1.267 +6 -6 + NTP_4_2_7P455 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.267 +2 -2 + NTP_4_2_7P455 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.53.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.46 +6 -6 + NTP_4_2_7P455 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.46 +2 -2 + NTP_4_2_7P455 + + scripts/ntpsweep/ntpsweep.html@1.54.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/ntpsweep/ntpsweep.man.in@1.46 +6 -6 + NTP_4_2_7P455 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.47 +2 -2 + NTP_4_2_7P455 + + scripts/ntptrace/invoke-ntptrace.texi@1.53.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/ntptrace/ntptrace.1ntptraceman@1.46 +6 -6 + NTP_4_2_7P455 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.46 +2 -2 + NTP_4_2_7P455 + + scripts/ntptrace/ntptrace.html@1.54.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/ntptrace/ntptrace.man.in@1.46 +6 -6 + NTP_4_2_7P455 + + scripts/ntptrace/ntptrace.mdoc.in@1.47 +2 -2 + NTP_4_2_7P455 + + scripts/plot_summary.1plot_summaryman@1.57 +6 -6 + NTP_4_2_7P455 + + scripts/plot_summary.1plot_summarymdoc@1.57 +2 -2 + NTP_4_2_7P455 + + scripts/plot_summary.html@1.55.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/plot_summary.man.in@1.57 +6 -6 + NTP_4_2_7P455 + + scripts/plot_summary.mdoc.in@1.57 +2 -2 + NTP_4_2_7P455 + + scripts/summary.1summaryman@1.57 +13 -13 + NTP_4_2_7P455 + + scripts/summary.1summarymdoc@1.57 +2 -2 + NTP_4_2_7P455 + + scripts/summary.html@1.55.1.2 +1 -1 + NTP_4_2_7P455 + + scripts/summary.man.in@1.57 +13 -13 + NTP_4_2_7P455 + + scripts/summary.mdoc.in@1.57 +2 -2 + NTP_4_2_7P455 + + sntp/invoke-sntp.texi@1.445 +2 -2 + NTP_4_2_7P455 + + sntp/sntp-opts.c@1.458.1.2 +7 -7 + NTP_4_2_7P455 + + sntp/sntp-opts.h@1.458.1.2 +3 -3 + NTP_4_2_7P455 + + sntp/sntp.1sntpman@1.280 +6 -6 + NTP_4_2_7P455 + + sntp/sntp.1sntpmdoc@1.280 +2 -2 + NTP_4_2_7P455 + + sntp/sntp.html@1.460 +2 -2 + NTP_4_2_7P455 + + sntp/sntp.man.in@1.280 +6 -6 + NTP_4_2_7P455 + + sntp/sntp.mdoc.in@1.280 +2 -2 + NTP_4_2_7P455 + + util/invoke-ntp-keygen.texi@1.449 +2 -2 + NTP_4_2_7P455 + + util/ntp-keygen-opts.c@1.461.1.2 +7 -7 + NTP_4_2_7P455 + + util/ntp-keygen-opts.h@1.461.1.2 +3 -3 + NTP_4_2_7P455 + + util/ntp-keygen.1ntp-keygenman@1.277 +13 -13 + NTP_4_2_7P455 + + util/ntp-keygen.1ntp-keygenmdoc@1.277 +2 -2 + NTP_4_2_7P455 + + util/ntp-keygen.html@1.125 +2 -2 + NTP_4_2_7P455 + + util/ntp-keygen.man.in@1.277 +13 -13 + NTP_4_2_7P455 + + util/ntp-keygen.mdoc.in@1.277 +2 -2 + NTP_4_2_7P455 + +ChangeSet@1.3156.1.6, 2014-08-03 05:03:03+00:00, stenn@psp-fb1.ntp.org + [Bug 2565] ntpd sometimes logs unexpected getifaddrs() errors + + ChangeLog@1.1502.1.5 +1 -0 + [Bug 2565] ntpd sometimes logs unexpected getifaddrs() errors + + lib/isc/unix/ifiter_getifaddrs.c@1.12 +14 -17 + [Bug 2565] ntpd sometimes logs unexpected getifaddrs() errors + +ChangeSet@1.3156.1.5, 2014-08-02 19:56:24-04:00, stenn@deacon.udel.edu + CID 739722: Clean up the definition of the exten field of struct pkt + + ChangeLog@1.1502.1.4 +1 -1 + CID 739722: Clean up the definition of the exten field of struct pkt + +ChangeSet@1.3156.1.4, 2014-08-02 23:44:12+00:00, stenn@psp-fb1.ntp.org + Clean up the definition of the exten field of struct pkt + + ChangeLog@1.1502.1.3 +1 -0 + Clean up the definition of the exten field of struct pkt + +ChangeSet@1.3156.1.3, 2014-08-02 13:15:10+02:00, jnperlin@hydra.(none) + make consistent layout for 'struct pkt' + + include/ntp.h@1.209 +9 -3 + make consistent layout for 'struct pkt' + + libntp/work_thread.c@1.17 +1 -1 + fix minor 64-bit casting issue for 'thread_exit()' macro + + sntp/main.c@1.93 +2 -6 + make consistent layout for 'struct pkt' + +ChangeSet@1.3156.1.2, 2014-07-30 09:34:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P454 + TAG: NTP_4_2_7P454 + + ChangeLog@1.1502.1.2 +1 -0 + NTP_4_2_7P454 + + ntpd/invoke-ntp.conf.texi@1.133 +1 -1 + NTP_4_2_7P454 + + ntpd/invoke-ntp.keys.texi@1.131 +1 -1 + NTP_4_2_7P454 + + ntpd/invoke-ntpd.texi@1.447 +2 -2 + NTP_4_2_7P454 + + ntpd/ntp.conf.5man@1.167 +6 -6 + NTP_4_2_7P454 + + ntpd/ntp.conf.5mdoc@1.167 +2 -2 + NTP_4_2_7P454 + + ntpd/ntp.conf.html@1.128 +1 -1 + NTP_4_2_7P454 + + ntpd/ntp.conf.man.in@1.167 +6 -6 + NTP_4_2_7P454 + + ntpd/ntp.conf.mdoc.in@1.167 +2 -2 + NTP_4_2_7P454 + + ntpd/ntp.keys.5man@1.165 +2 -2 + NTP_4_2_7P454 + + ntpd/ntp.keys.5mdoc@1.165 +2 -2 + NTP_4_2_7P454 + + ntpd/ntp.keys.html@1.129 +1 -1 + NTP_4_2_7P454 + + ntpd/ntp.keys.man.in@1.165 +2 -2 + NTP_4_2_7P454 + + ntpd/ntp.keys.mdoc.in@1.165 +2 -2 + NTP_4_2_7P454 + + ntpd/ntpd-opts.c@1.464.1.1 +7 -7 + NTP_4_2_7P454 + + ntpd/ntpd-opts.h@1.464.1.1 +3 -3 + NTP_4_2_7P454 + + ntpd/ntpd.1ntpdman@1.276 +6 -6 + NTP_4_2_7P454 + + ntpd/ntpd.1ntpdmdoc@1.276 +2 -2 + NTP_4_2_7P454 + + ntpd/ntpd.html@1.123 +2 -2 + NTP_4_2_7P454 + + ntpd/ntpd.man.in@1.276 +6 -6 + NTP_4_2_7P454 + + ntpd/ntpd.mdoc.in@1.276 +2 -2 + NTP_4_2_7P454 + + ntpdc/invoke-ntpdc.texi@1.445 +2 -2 + NTP_4_2_7P454 + + ntpdc/ntpdc-opts.c@1.459.1.1 +7 -7 + NTP_4_2_7P454 + + ntpdc/ntpdc-opts.h@1.459.1.1 +3 -3 + NTP_4_2_7P454 + + ntpdc/ntpdc.1ntpdcman@1.276 +6 -6 + NTP_4_2_7P454 + + ntpdc/ntpdc.1ntpdcmdoc@1.276 +2 -2 + NTP_4_2_7P454 + + ntpdc/ntpdc.html@1.289 +2 -2 + NTP_4_2_7P454 + + ntpdc/ntpdc.man.in@1.276 +6 -6 + NTP_4_2_7P454 + + ntpdc/ntpdc.mdoc.in@1.276 +2 -2 + NTP_4_2_7P454 + + ntpq/invoke-ntpq.texi@1.448.1.1 +2 -2 + NTP_4_2_7P454 + + ntpq/ntpq-opts.c@1.462.1.1 +7 -7 + NTP_4_2_7P454 + + ntpq/ntpq-opts.h@1.462.1.1 +3 -3 + NTP_4_2_7P454 + + ntpq/ntpq.1ntpqman@1.276.1.1 +6 -6 + NTP_4_2_7P454 + + ntpq/ntpq.1ntpqmdoc@1.276.1.1 +2 -2 + NTP_4_2_7P454 + + ntpq/ntpq.html@1.120 +2 -2 + NTP_4_2_7P454 + + ntpq/ntpq.man.in@1.276.1.1 +6 -6 + NTP_4_2_7P454 + + ntpq/ntpq.mdoc.in@1.276.1.1 +2 -2 + NTP_4_2_7P454 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.447 +2 -2 + NTP_4_2_7P454 + + ntpsnmpd/ntpsnmpd-opts.c@1.461.1.1 +7 -7 + NTP_4_2_7P454 + + ntpsnmpd/ntpsnmpd-opts.h@1.461.1.1 +3 -3 + NTP_4_2_7P454 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.276 +6 -6 + NTP_4_2_7P454 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.276 +2 -2 + NTP_4_2_7P454 + + ntpsnmpd/ntpsnmpd.html@1.118 +1 -1 + NTP_4_2_7P454 + + ntpsnmpd/ntpsnmpd.man.in@1.276 +6 -6 + NTP_4_2_7P454 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.276 +2 -2 + NTP_4_2_7P454 + + packageinfo.sh@1.458 +1 -1 + NTP_4_2_7P454 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.38 +6 -6 + NTP_4_2_7P454 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.38 +2 -2 + NTP_4_2_7P454 + + scripts/calc_tickadj/calc_tickadj.html@1.36.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/calc_tickadj/calc_tickadj.man.in@1.37 +6 -6 + NTP_4_2_7P454 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.38 +2 -2 + NTP_4_2_7P454 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.38.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/invoke-plot_summary.texi@1.55.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/invoke-summary.texi@1.55.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.265 +1 -1 + NTP_4_2_7P454 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.266 +13 -13 + NTP_4_2_7P454 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.266 +2 -2 + NTP_4_2_7P454 + + scripts/ntp-wait/ntp-wait.html@1.282 +1 -1 + NTP_4_2_7P454 + + scripts/ntp-wait/ntp-wait.man.in@1.266 +13 -13 + NTP_4_2_7P454 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.266 +2 -2 + NTP_4_2_7P454 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.53.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.45 +6 -6 + NTP_4_2_7P454 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.45 +2 -2 + NTP_4_2_7P454 + + scripts/ntpsweep/ntpsweep.html@1.54.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/ntpsweep/ntpsweep.man.in@1.45 +6 -6 + NTP_4_2_7P454 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.46 +2 -2 + NTP_4_2_7P454 + + scripts/ntptrace/invoke-ntptrace.texi@1.53.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/ntptrace/ntptrace.1ntptraceman@1.45 +6 -6 + NTP_4_2_7P454 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.45 +2 -2 + NTP_4_2_7P454 + + scripts/ntptrace/ntptrace.html@1.54.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/ntptrace/ntptrace.man.in@1.45 +6 -6 + NTP_4_2_7P454 + + scripts/ntptrace/ntptrace.mdoc.in@1.46 +2 -2 + NTP_4_2_7P454 + + scripts/plot_summary.1plot_summaryman@1.56 +6 -6 + NTP_4_2_7P454 + + scripts/plot_summary.1plot_summarymdoc@1.56 +2 -2 + NTP_4_2_7P454 + + scripts/plot_summary.html@1.55.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/plot_summary.man.in@1.56 +6 -6 + NTP_4_2_7P454 + + scripts/plot_summary.mdoc.in@1.56 +2 -2 + NTP_4_2_7P454 + + scripts/summary.1summaryman@1.56 +13 -13 + NTP_4_2_7P454 + + scripts/summary.1summarymdoc@1.56 +2 -2 + NTP_4_2_7P454 + + scripts/summary.html@1.55.1.1 +1 -1 + NTP_4_2_7P454 + + scripts/summary.man.in@1.56 +13 -13 + NTP_4_2_7P454 + + scripts/summary.mdoc.in@1.56 +2 -2 + NTP_4_2_7P454 + + sntp/invoke-sntp.texi@1.444 +2 -2 + NTP_4_2_7P454 + + sntp/sntp-opts.c@1.458.1.1 +7 -7 + NTP_4_2_7P454 + + sntp/sntp-opts.h@1.458.1.1 +3 -3 + NTP_4_2_7P454 + + sntp/sntp.1sntpman@1.279 +6 -6 + NTP_4_2_7P454 + + sntp/sntp.1sntpmdoc@1.279 +2 -2 + NTP_4_2_7P454 + + sntp/sntp.html@1.459 +2 -2 + NTP_4_2_7P454 + + sntp/sntp.man.in@1.279 +6 -6 + NTP_4_2_7P454 + + sntp/sntp.mdoc.in@1.279 +2 -2 + NTP_4_2_7P454 + + util/invoke-ntp-keygen.texi@1.448 +2 -2 + NTP_4_2_7P454 + + util/ntp-keygen-opts.c@1.461.1.1 +7 -7 + NTP_4_2_7P454 + + util/ntp-keygen-opts.h@1.461.1.1 +3 -3 + NTP_4_2_7P454 + + util/ntp-keygen.1ntp-keygenman@1.276 +6 -6 + NTP_4_2_7P454 + + util/ntp-keygen.1ntp-keygenmdoc@1.276 +2 -2 + NTP_4_2_7P454 + + util/ntp-keygen.html@1.124 +2 -2 + NTP_4_2_7P454 + + util/ntp-keygen.man.in@1.276 +6 -6 + NTP_4_2_7P454 + + util/ntp-keygen.mdoc.in@1.276 +2 -2 + NTP_4_2_7P454 + +ChangeSet@1.3156.1.1, 2014-07-29 20:35:32+02:00, jnperlin@hydra.(none) + [Bug 2628] 'mon_getmoremem()' relies on undefined behaviour + + ChangeLog@1.1502.1.1 +1 -0 + [Bug 2628] 'mon_getmoremem()' relies on undefined behaviour + + ntpd/ntp_monitor.c@1.41 +8 -7 + [Bug 2628] 'mon_getmoremem()' relies on undefined behaviour + +ChangeSet@1.3160, 2014-07-20 09:44:32+00:00, stenn@psp-fb1.ntp.org + autogen-5.18.4pre9 + + ntpd/ntpd-opts.c@1.465 +2 -2 + autogen-5.18.4pre9 + + ntpd/ntpd-opts.h@1.465 +9 -9 + autogen-5.18.4pre9 + + ntpd/ntpdsim-opts.c@1.24 +11 -11 + autogen-5.18.4pre9 + + ntpd/ntpdsim-opts.h@1.24 +14 -14 + autogen-5.18.4pre9 + + ntpdc/ntpdc-opts.c@1.460 +2 -2 + autogen-5.18.4pre9 + + ntpdc/ntpdc-opts.h@1.460 +11 -11 + autogen-5.18.4pre9 + + ntpq/invoke-ntpq.texi@1.449 +27 -25 + autogen-5.18.4pre9 + + ntpq/ntpq-opts.c@1.463 +2 -2 + autogen-5.18.4pre9 + + ntpq/ntpq-opts.h@1.463 +11 -11 + autogen-5.18.4pre9 + + ntpq/ntpq.1ntpqman@1.277 +40 -60 + autogen-5.18.4pre9 + + ntpq/ntpq.1ntpqmdoc@1.277 +31 -47 + autogen-5.18.4pre9 + + ntpq/ntpq.man.in@1.277 +40 -60 + autogen-5.18.4pre9 + + ntpq/ntpq.mdoc.in@1.277 +31 -47 + autogen-5.18.4pre9 + + ntpsnmpd/ntpsnmpd-opts.c@1.462 +2 -2 + autogen-5.18.4pre9 + + ntpsnmpd/ntpsnmpd-opts.h@1.462 +11 -11 + autogen-5.18.4pre9 + + scripts/calc_tickadj/calc_tickadj-opts@1.4 +6 -6 + autogen-5.18.4pre9 + + scripts/calc_tickadj/calc_tickadj.html@1.37 +35 -23 + autogen-5.18.4pre9 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.39 +3 -3 + autogen-5.18.4pre9 + + scripts/invoke-plot_summary.texi@1.56 +10 -10 + autogen-5.18.4pre9 + + scripts/invoke-summary.texi@1.56 +9 -9 + autogen-5.18.4pre9 + + scripts/ntp-wait/ntp-wait-opts@1.3 +6 -6 + autogen-5.18.4pre9 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.54 +3 -3 + autogen-5.18.4pre9 + + scripts/ntpsweep/ntpsweep-opts@1.4 +6 -11 + autogen-5.18.4pre9 + + scripts/ntpsweep/ntpsweep.html@1.55 +44 -33 + autogen-5.18.4pre9 + + scripts/ntptrace/invoke-ntptrace.texi@1.54 +3 -3 + autogen-5.18.4pre9 + + scripts/ntptrace/ntptrace-opts@1.4 +6 -11 + autogen-5.18.4pre9 + + scripts/ntptrace/ntptrace.html@1.55 +36 -27 + autogen-5.18.4pre9 + + scripts/plot_summary-opts@1.4 +13 -13 + autogen-5.18.4pre9 + + scripts/plot_summary.html@1.56 +54 -36 + autogen-5.18.4pre9 + + scripts/summary-opts@1.4 +12 -12 + autogen-5.18.4pre9 + + scripts/summary.html@1.56 +45 -33 + autogen-5.18.4pre9 + + sntp/sntp-opts.c@1.459 +2 -2 + autogen-5.18.4pre9 + + sntp/sntp-opts.h@1.459 +11 -11 + autogen-5.18.4pre9 + + util/ntp-keygen-opts.c@1.462 +2 -2 + autogen-5.18.4pre9 + + util/ntp-keygen-opts.h@1.462 +11 -11 + autogen-5.18.4pre9 + +ChangeSet@1.3159, 2014-07-20 09:34:20+00:00, stenn@psp-fb1.ntp.org + Fix nits in the ntpq man page + + ChangeLog@1.1505 +1 -1 + Fix nits in the ntpq man page + + ntpq/ntpq-opts.def@1.19 +28 -28 + Fix nits in the ntpq man page + +ChangeSet@1.3158, 2014-07-20 07:31:46+00:00, stenn@psp-deb1.ntp.org + Fix a nit in the ntpq man page + + ChangeLog@1.1504 +1 -0 + Fix a nit in the ntpq man page + + ntpq/ntpq-opts.def@1.18 +1 -1 + Fix a nit in the ntpq man page + +ChangeSet@1.3157, 2014-07-20 07:30:06+00:00, stenn@psp-deb1.ntp.org + autogen-5.18.4pre9 + + ChangeLog@1.1503 +1 -0 + autogen-5.18.4pre9 + + sntp/libopts/Makefile.am@1.25 +52 -16 + autogen-5.18.4pre9 + + sntp/libopts/ag-char-map.h@1.28 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/ao-strs.c@1.14 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/ao-strs.h@1.13 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/autoopts.h@1.18 +1 -0 + autogen-5.18.4pre9 + + sntp/libopts/autoopts/options.h@1.27 +6 -4 + autogen-5.18.4pre9 + + sntp/libopts/autoopts/usage-txt.h@1.27 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/compat/_Noreturn.h@1.1 +10 -0 + BitKeeper file /home/stenn/ntp-dev-autogen-5.18.4/sntp/libopts/compat/_Noreturn.h + + sntp/libopts/compat/_Noreturn.h@1.0 +0 -0 + + sntp/libopts/genshell.c@1.28 +2 -2 + autogen-5.18.4pre9 + + sntp/libopts/genshell.h@1.28 +9 -9 + autogen-5.18.4pre9 + + sntp/libopts/intprops.h@1.1 +320 -0 + BitKeeper file /home/stenn/ntp-dev-autogen-5.18.4/sntp/libopts/intprops.h + + sntp/libopts/intprops.h@1.0 +0 -0 + + sntp/libopts/m4/libopts.m4@1.31 +2 -1 + autogen-5.18.4pre9 + + sntp/libopts/m4/stdnoreturn.m4@1.1 +41 -0 + BitKeeper file /home/stenn/ntp-dev-autogen-5.18.4/sntp/libopts/m4/stdnoreturn.m4 + + sntp/libopts/m4/stdnoreturn.m4@1.0 +0 -0 + + sntp/libopts/makeshell.c@1.18 +3 -3 + autogen-5.18.4pre9 + + sntp/libopts/option-value-type.c@1.15 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/option-value-type.h@1.29 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/option-xat-attribute.c@1.15 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/option-xat-attribute.h@1.29 +1 -1 + autogen-5.18.4pre9 + + sntp/libopts/parse-duration.c@1.12 +6 -3 + autogen-5.18.4pre9 + + sntp/libopts/proto.h@1.28 +4 -4 + autogen-5.18.4pre9 + + sntp/libopts/stdnoreturn.in.h@1.1 +50 -0 + BitKeeper file /home/stenn/ntp-dev-autogen-5.18.4/sntp/libopts/stdnoreturn.in.h + + sntp/libopts/stdnoreturn.in.h@1.0 +0 -0 + + sntp/libopts/version.c@1.17 +24 -4 + autogen-5.18.4pre9 + +ChangeSet@1.3156, 2014-07-19 09:33:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P453 + TAG: NTP_4_2_7P453 + + ChangeLog@1.1502 +1 -0 + NTP_4_2_7P453 + + ntpd/invoke-ntp.conf.texi@1.132 +1 -1 + NTP_4_2_7P453 + + ntpd/invoke-ntp.keys.texi@1.130 +1 -1 + NTP_4_2_7P453 + + ntpd/invoke-ntpd.texi@1.446 +2 -2 + NTP_4_2_7P453 + + ntpd/ntp.conf.5man@1.166 +6 -6 + NTP_4_2_7P453 + + ntpd/ntp.conf.5mdoc@1.166 +2 -2 + NTP_4_2_7P453 + + ntpd/ntp.conf.html@1.127 +1 -1 + NTP_4_2_7P453 + + ntpd/ntp.conf.man.in@1.166 +6 -6 + NTP_4_2_7P453 + + ntpd/ntp.conf.mdoc.in@1.166 +2 -2 + NTP_4_2_7P453 + + ntpd/ntp.keys.5man@1.164 +2 -2 + NTP_4_2_7P453 + + ntpd/ntp.keys.5mdoc@1.164 +2 -2 + NTP_4_2_7P453 + + ntpd/ntp.keys.html@1.128 +1 -1 + NTP_4_2_7P453 + + ntpd/ntp.keys.man.in@1.164 +2 -2 + NTP_4_2_7P453 + + ntpd/ntp.keys.mdoc.in@1.164 +2 -2 + NTP_4_2_7P453 + + ntpd/ntpd-opts.c@1.464 +7 -7 + NTP_4_2_7P453 + + ntpd/ntpd-opts.h@1.464 +3 -3 + NTP_4_2_7P453 + + ntpd/ntpd.1ntpdman@1.275 +13 -13 + NTP_4_2_7P453 + + ntpd/ntpd.1ntpdmdoc@1.275 +2 -2 + NTP_4_2_7P453 + + ntpd/ntpd.html@1.122 +2 -2 + NTP_4_2_7P453 + + ntpd/ntpd.man.in@1.275 +13 -13 + NTP_4_2_7P453 + + ntpd/ntpd.mdoc.in@1.275 +2 -2 + NTP_4_2_7P453 + + ntpdc/invoke-ntpdc.texi@1.444 +2 -2 + NTP_4_2_7P453 + + ntpdc/ntpdc-opts.c@1.459 +7 -7 + NTP_4_2_7P453 + + ntpdc/ntpdc-opts.h@1.459 +3 -3 + NTP_4_2_7P453 + + ntpdc/ntpdc.1ntpdcman@1.275 +6 -6 + NTP_4_2_7P453 + + ntpdc/ntpdc.1ntpdcmdoc@1.275 +2 -2 + NTP_4_2_7P453 + + ntpdc/ntpdc.html@1.288 +2 -2 + NTP_4_2_7P453 + + ntpdc/ntpdc.man.in@1.275 +6 -6 + NTP_4_2_7P453 + + ntpdc/ntpdc.mdoc.in@1.275 +2 -2 + NTP_4_2_7P453 + + ntpq/invoke-ntpq.texi@1.448 +2 -2 + NTP_4_2_7P453 + + ntpq/ntpq-opts.c@1.462 +7 -7 + NTP_4_2_7P453 + + ntpq/ntpq-opts.h@1.462 +3 -3 + NTP_4_2_7P453 + + ntpq/ntpq.1ntpqman@1.276 +6 -6 + NTP_4_2_7P453 + + ntpq/ntpq.1ntpqmdoc@1.276 +2 -2 + NTP_4_2_7P453 + + ntpq/ntpq.html@1.119 +2 -2 + NTP_4_2_7P453 + + ntpq/ntpq.man.in@1.276 +6 -6 + NTP_4_2_7P453 + + ntpq/ntpq.mdoc.in@1.276 +2 -2 + NTP_4_2_7P453 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.446 +2 -2 + NTP_4_2_7P453 + + ntpsnmpd/ntpsnmpd-opts.c@1.461 +7 -7 + NTP_4_2_7P453 + + ntpsnmpd/ntpsnmpd-opts.h@1.461 +3 -3 + NTP_4_2_7P453 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.275 +6 -6 + NTP_4_2_7P453 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.275 +2 -2 + NTP_4_2_7P453 + + ntpsnmpd/ntpsnmpd.html@1.117 +1 -1 + NTP_4_2_7P453 + + ntpsnmpd/ntpsnmpd.man.in@1.275 +6 -6 + NTP_4_2_7P453 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.275 +2 -2 + NTP_4_2_7P453 + + packageinfo.sh@1.457 +1 -1 + NTP_4_2_7P453 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.37 +6 -6 + NTP_4_2_7P453 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.37 +2 -2 + NTP_4_2_7P453 + + scripts/calc_tickadj/calc_tickadj.html@1.36 +1 -1 + NTP_4_2_7P453 + + scripts/calc_tickadj/calc_tickadj.man.in@1.36 +6 -6 + NTP_4_2_7P453 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.37 +2 -2 + NTP_4_2_7P453 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.38 +1 -1 + NTP_4_2_7P453 + + scripts/invoke-plot_summary.texi@1.55 +1 -1 + NTP_4_2_7P453 + + scripts/invoke-summary.texi@1.55 +1 -1 + NTP_4_2_7P453 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.264 +1 -1 + NTP_4_2_7P453 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.265 +13 -13 + NTP_4_2_7P453 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.265 +2 -2 + NTP_4_2_7P453 + + scripts/ntp-wait/ntp-wait.html@1.281 +1 -1 + NTP_4_2_7P453 + + scripts/ntp-wait/ntp-wait.man.in@1.265 +13 -13 + NTP_4_2_7P453 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.265 +2 -2 + NTP_4_2_7P453 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.53 +1 -1 + NTP_4_2_7P453 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.44 +6 -6 + NTP_4_2_7P453 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.44 +2 -2 + NTP_4_2_7P453 + + scripts/ntpsweep/ntpsweep.html@1.54 +1 -1 + NTP_4_2_7P453 + + scripts/ntpsweep/ntpsweep.man.in@1.44 +6 -6 + NTP_4_2_7P453 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.45 +2 -2 + NTP_4_2_7P453 + + scripts/ntptrace/invoke-ntptrace.texi@1.53 +1 -1 + NTP_4_2_7P453 + + scripts/ntptrace/ntptrace.1ntptraceman@1.44 +6 -6 + NTP_4_2_7P453 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.44 +2 -2 + NTP_4_2_7P453 + + scripts/ntptrace/ntptrace.html@1.54 +1 -1 + NTP_4_2_7P453 + + scripts/ntptrace/ntptrace.man.in@1.44 +6 -6 + NTP_4_2_7P453 + + scripts/ntptrace/ntptrace.mdoc.in@1.45 +2 -2 + NTP_4_2_7P453 + + scripts/plot_summary.1plot_summaryman@1.55 +6 -6 + NTP_4_2_7P453 + + scripts/plot_summary.1plot_summarymdoc@1.55 +2 -2 + NTP_4_2_7P453 + + scripts/plot_summary.html@1.55 +1 -1 + NTP_4_2_7P453 + + scripts/plot_summary.man.in@1.55 +6 -6 + NTP_4_2_7P453 + + scripts/plot_summary.mdoc.in@1.55 +2 -2 + NTP_4_2_7P453 + + scripts/summary.1summaryman@1.55 +6 -6 + NTP_4_2_7P453 + + scripts/summary.1summarymdoc@1.55 +2 -2 + NTP_4_2_7P453 + + scripts/summary.html@1.55 +1 -1 + NTP_4_2_7P453 + + scripts/summary.man.in@1.55 +6 -6 + NTP_4_2_7P453 + + scripts/summary.mdoc.in@1.55 +2 -2 + NTP_4_2_7P453 + + sntp/invoke-sntp.texi@1.443 +2 -2 + NTP_4_2_7P453 + + sntp/sntp-opts.c@1.458 +7 -7 + NTP_4_2_7P453 + + sntp/sntp-opts.h@1.458 +3 -3 + NTP_4_2_7P453 + + sntp/sntp.1sntpman@1.278 +6 -6 + NTP_4_2_7P453 + + sntp/sntp.1sntpmdoc@1.278 +2 -2 + NTP_4_2_7P453 + + sntp/sntp.html@1.458 +2 -2 + NTP_4_2_7P453 + + sntp/sntp.man.in@1.278 +6 -6 + NTP_4_2_7P453 + + sntp/sntp.mdoc.in@1.278 +2 -2 + NTP_4_2_7P453 + + util/invoke-ntp-keygen.texi@1.447 +2 -2 + NTP_4_2_7P453 + + util/ntp-keygen-opts.c@1.461 +7 -7 + NTP_4_2_7P453 + + util/ntp-keygen-opts.h@1.461 +3 -3 + NTP_4_2_7P453 + + util/ntp-keygen.1ntp-keygenman@1.275 +6 -6 + NTP_4_2_7P453 + + util/ntp-keygen.1ntp-keygenmdoc@1.275 +2 -2 + NTP_4_2_7P453 + + util/ntp-keygen.html@1.123 +2 -2 + NTP_4_2_7P453 + + util/ntp-keygen.man.in@1.275 +6 -6 + NTP_4_2_7P453 + + util/ntp-keygen.mdoc.in@1.275 +2 -2 + NTP_4_2_7P453 + +ChangeSet@1.3154, 2014-07-18 09:33:45+00:00, stenn@deacon.udel.edu + NTP_4_2_7P452 + TAG: NTP_4_2_7P452 + + ChangeLog@1.1500 +1 -0 + NTP_4_2_7P452 + + ntpd/invoke-ntp.conf.texi@1.131 +1 -1 + NTP_4_2_7P452 + + ntpd/invoke-ntp.keys.texi@1.129 +1 -1 + NTP_4_2_7P452 + + ntpd/invoke-ntpd.texi@1.445 +2 -2 + NTP_4_2_7P452 + + ntpd/ntp.conf.5man@1.165 +6 -6 + NTP_4_2_7P452 + + ntpd/ntp.conf.5mdoc@1.165 +2 -2 + NTP_4_2_7P452 + + ntpd/ntp.conf.html@1.126 +1 -1 + NTP_4_2_7P452 + + ntpd/ntp.conf.man.in@1.165 +6 -6 + NTP_4_2_7P452 + + ntpd/ntp.conf.mdoc.in@1.165 +2 -2 + NTP_4_2_7P452 + + ntpd/ntp.keys.5man@1.163 +2 -2 + NTP_4_2_7P452 + + ntpd/ntp.keys.5mdoc@1.163 +2 -2 + NTP_4_2_7P452 + + ntpd/ntp.keys.html@1.127 +1 -1 + NTP_4_2_7P452 + + ntpd/ntp.keys.man.in@1.163 +2 -2 + NTP_4_2_7P452 + + ntpd/ntp.keys.mdoc.in@1.163 +2 -2 + NTP_4_2_7P452 + + ntpd/ntpd-opts.c@1.463 +7 -7 + NTP_4_2_7P452 + + ntpd/ntpd-opts.h@1.463 +3 -3 + NTP_4_2_7P452 + + ntpd/ntpd.1ntpdman@1.274 +13 -13 + NTP_4_2_7P452 + + ntpd/ntpd.1ntpdmdoc@1.274 +2 -2 + NTP_4_2_7P452 + + ntpd/ntpd.html@1.121 +2 -2 + NTP_4_2_7P452 + + ntpd/ntpd.man.in@1.274 +13 -13 + NTP_4_2_7P452 + + ntpd/ntpd.mdoc.in@1.274 +2 -2 + NTP_4_2_7P452 + + ntpdc/invoke-ntpdc.texi@1.443 +2 -2 + NTP_4_2_7P452 + + ntpdc/ntpdc-opts.c@1.458 +7 -7 + NTP_4_2_7P452 + + ntpdc/ntpdc-opts.h@1.458 +3 -3 + NTP_4_2_7P452 + + ntpdc/ntpdc.1ntpdcman@1.274 +6 -6 + NTP_4_2_7P452 + + ntpdc/ntpdc.1ntpdcmdoc@1.274 +2 -2 + NTP_4_2_7P452 + + ntpdc/ntpdc.html@1.287 +2 -2 + NTP_4_2_7P452 + + ntpdc/ntpdc.man.in@1.274 +6 -6 + NTP_4_2_7P452 + + ntpdc/ntpdc.mdoc.in@1.274 +2 -2 + NTP_4_2_7P452 + + ntpq/invoke-ntpq.texi@1.447 +2 -2 + NTP_4_2_7P452 + + ntpq/ntpq-opts.c@1.461 +7 -7 + NTP_4_2_7P452 + + ntpq/ntpq-opts.h@1.461 +3 -3 + NTP_4_2_7P452 + + ntpq/ntpq.1ntpqman@1.275 +6 -6 + NTP_4_2_7P452 + + ntpq/ntpq.1ntpqmdoc@1.275 +2 -2 + NTP_4_2_7P452 + + ntpq/ntpq.html@1.118 +2 -2 + NTP_4_2_7P452 + + ntpq/ntpq.man.in@1.275 +6 -6 + NTP_4_2_7P452 + + ntpq/ntpq.mdoc.in@1.275 +2 -2 + NTP_4_2_7P452 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.445 +2 -2 + NTP_4_2_7P452 + + ntpsnmpd/ntpsnmpd-opts.c@1.460 +7 -7 + NTP_4_2_7P452 + + ntpsnmpd/ntpsnmpd-opts.h@1.460 +3 -3 + NTP_4_2_7P452 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.274 +6 -6 + NTP_4_2_7P452 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.274 +2 -2 + NTP_4_2_7P452 + + ntpsnmpd/ntpsnmpd.html@1.116 +1 -1 + NTP_4_2_7P452 + + ntpsnmpd/ntpsnmpd.man.in@1.274 +6 -6 + NTP_4_2_7P452 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.274 +2 -2 + NTP_4_2_7P452 + + packageinfo.sh@1.456 +1 -1 + NTP_4_2_7P452 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.36 +6 -6 + NTP_4_2_7P452 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.36 +2 -2 + NTP_4_2_7P452 + + scripts/calc_tickadj/calc_tickadj.html@1.35 +1 -1 + NTP_4_2_7P452 + + scripts/calc_tickadj/calc_tickadj.man.in@1.35 +6 -6 + NTP_4_2_7P452 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.36 +2 -2 + NTP_4_2_7P452 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.37 +1 -1 + NTP_4_2_7P452 + + scripts/invoke-plot_summary.texi@1.54 +1 -1 + NTP_4_2_7P452 + + scripts/invoke-summary.texi@1.54 +1 -1 + NTP_4_2_7P452 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.263 +1 -1 + NTP_4_2_7P452 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.264 +6 -6 + NTP_4_2_7P452 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.264 +2 -2 + NTP_4_2_7P452 + + scripts/ntp-wait/ntp-wait.html@1.280 +1 -1 + NTP_4_2_7P452 + + scripts/ntp-wait/ntp-wait.man.in@1.264 +6 -6 + NTP_4_2_7P452 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.264 +2 -2 + NTP_4_2_7P452 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.52 +1 -1 + NTP_4_2_7P452 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.43 +6 -6 + NTP_4_2_7P452 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.43 +2 -2 + NTP_4_2_7P452 + + scripts/ntpsweep/ntpsweep.html@1.53 +1 -1 + NTP_4_2_7P452 + + scripts/ntpsweep/ntpsweep.man.in@1.43 +6 -6 + NTP_4_2_7P452 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.44 +2 -2 + NTP_4_2_7P452 + + scripts/ntptrace/invoke-ntptrace.texi@1.52 +1 -1 + NTP_4_2_7P452 + + scripts/ntptrace/ntptrace.1ntptraceman@1.43 +6 -6 + NTP_4_2_7P452 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.43 +2 -2 + NTP_4_2_7P452 + + scripts/ntptrace/ntptrace.html@1.53 +1 -1 + NTP_4_2_7P452 + + scripts/ntptrace/ntptrace.man.in@1.43 +6 -6 + NTP_4_2_7P452 + + scripts/ntptrace/ntptrace.mdoc.in@1.44 +2 -2 + NTP_4_2_7P452 + + scripts/plot_summary.1plot_summaryman@1.54 +6 -6 + NTP_4_2_7P452 + + scripts/plot_summary.1plot_summarymdoc@1.54 +2 -2 + NTP_4_2_7P452 + + scripts/plot_summary.html@1.54 +1 -1 + NTP_4_2_7P452 + + scripts/plot_summary.man.in@1.54 +6 -6 + NTP_4_2_7P452 + + scripts/plot_summary.mdoc.in@1.54 +2 -2 + NTP_4_2_7P452 + + scripts/summary.1summaryman@1.54 +6 -6 + NTP_4_2_7P452 + + scripts/summary.1summarymdoc@1.54 +2 -2 + NTP_4_2_7P452 + + scripts/summary.html@1.54 +1 -1 + NTP_4_2_7P452 + + scripts/summary.man.in@1.54 +6 -6 + NTP_4_2_7P452 + + scripts/summary.mdoc.in@1.54 +2 -2 + NTP_4_2_7P452 + + sntp/invoke-sntp.texi@1.442 +2 -2 + NTP_4_2_7P452 + + sntp/sntp-opts.c@1.457 +7 -7 + NTP_4_2_7P452 + + sntp/sntp-opts.h@1.457 +3 -3 + NTP_4_2_7P452 + + sntp/sntp.1sntpman@1.277 +6 -6 + NTP_4_2_7P452 + + sntp/sntp.1sntpmdoc@1.277 +2 -2 + NTP_4_2_7P452 + + sntp/sntp.html@1.457 +2 -2 + NTP_4_2_7P452 + + sntp/sntp.man.in@1.277 +6 -6 + NTP_4_2_7P452 + + sntp/sntp.mdoc.in@1.277 +2 -2 + NTP_4_2_7P452 + + util/invoke-ntp-keygen.texi@1.446 +2 -2 + NTP_4_2_7P452 + + util/ntp-keygen-opts.c@1.460 +7 -7 + NTP_4_2_7P452 + + util/ntp-keygen-opts.h@1.460 +3 -3 + NTP_4_2_7P452 + + util/ntp-keygen.1ntp-keygenman@1.274 +6 -6 + NTP_4_2_7P452 + + util/ntp-keygen.1ntp-keygenmdoc@1.274 +2 -2 + NTP_4_2_7P452 + + util/ntp-keygen.html@1.122 +2 -2 + NTP_4_2_7P452 + + util/ntp-keygen.man.in@1.274 +6 -6 + NTP_4_2_7P452 + + util/ntp-keygen.mdoc.in@1.274 +2 -2 + NTP_4_2_7P452 + +ChangeSet@1.3153, 2014-07-18 04:36:57-04:00, stenn@deacon.udel.edu + Make all of the html/ .html files use the same format for "Last update" + + ChangeLog@1.1499 +1 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/assoc.html@1.41 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/comdex.html@1.7 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/config.html@1.25 +3 -2 + Make all of the html/ .html files use the same format for "Last update" + + html/confopt.html@1.62 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/copyright.html@1.64 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/decode.html@1.25 +3 -2 + Make all of the html/ .html files use the same format for "Last update" + + html/discipline.html@1.10 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/discover.html@1.6 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver16.html@1.13 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver20.html@1.29 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver26.html@1.11 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver27.html@1.17 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver28.html@1.15 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver29.html@1.17 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver30.html@1.21 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver31.html@1.4 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver32.html@1.14 +3 -1 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver33.html@1.14 +3 -2 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver34.html@1.13 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver35.html@1.16 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver37.html@1.14 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver38.html@1.16 +3 -1 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver39.html@1.15 +3 -1 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver40.html@1.16 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver42.html@1.14 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver43.html@1.12 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver44.html@1.15 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver45.html@1.4 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver46.html@1.2 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver6.html@1.30 +2 -2 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver7.html@1.31 +2 -1 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver8.html@1.31 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/driver9.html@1.16 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/mx4200data.html@1.3 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/oncore-shmem.html@1.14 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/drivers/tf582_4.html@1.4 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/extern.html@1.21 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/filter.html@1.8 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/hints.html@1.20 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/hints/sco.html@1.12 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/hints/solaris.html@1.12 +4 -1 + Make all of the html/ .html files use the same format for "Last update" + + html/hints/vxworks.html@1.11 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/history.html@1.4 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/howto.html@1.25 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/huffpuff.html@1.6 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/kern.html@1.22 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/kernpps.html@1.5 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/keygen.html@1.34 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/leap.html@1.7 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/miscopt.html@1.78 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/monopt.html@1.38 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/msyslog.html@1.12 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/ntp-wait.html@1.2 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/ntpd.html@1.62 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/ntpdate.html@1.28 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/ntpdc.html@1.39 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/ntpdsim_new.html@1.9 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/ntpq.html@1.50 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/ntptrace.html@1.21 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/parsedata.html@1.14 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/parsenew.html@1.13 +3 -0 + Make all of the html/ .html files use the same format for "Last update" + + html/poll.html@1.5 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/pps.html@1.26 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/prefer.html@1.33 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/rate.html@1.13 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/rdebug.html@1.19 +4 -4 + Make all of the html/ .html files use the same format for "Last update" + + html/refclock.html@1.43 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/select.html@1.10 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/stats.html@1.3 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/tickadj.html@1.19 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/warp.html@1.24 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + + html/xleave.html@1.10 +3 -3 + Make all of the html/ .html files use the same format for "Last update" + +ChangeSet@1.3152, 2014-07-17 09:33:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P451 + TAG: NTP_4_2_7P451 + + ChangeLog@1.1498 +1 -0 + NTP_4_2_7P451 + + ntpd/invoke-ntp.conf.texi@1.130 +1 -1 + NTP_4_2_7P451 + + ntpd/invoke-ntp.keys.texi@1.128 +1 -1 + NTP_4_2_7P451 + + ntpd/invoke-ntpd.texi@1.444 +2 -2 + NTP_4_2_7P451 + + ntpd/ntp.conf.5man@1.164 +6 -6 + NTP_4_2_7P451 + + ntpd/ntp.conf.5mdoc@1.164 +2 -2 + NTP_4_2_7P451 + + ntpd/ntp.conf.html@1.125 +1 -1 + NTP_4_2_7P451 + + ntpd/ntp.conf.man.in@1.164 +6 -6 + NTP_4_2_7P451 + + ntpd/ntp.conf.mdoc.in@1.164 +2 -2 + NTP_4_2_7P451 + + ntpd/ntp.keys.5man@1.162 +2 -2 + NTP_4_2_7P451 + + ntpd/ntp.keys.5mdoc@1.162 +2 -2 + NTP_4_2_7P451 + + ntpd/ntp.keys.html@1.126 +1 -1 + NTP_4_2_7P451 + + ntpd/ntp.keys.man.in@1.162 +2 -2 + NTP_4_2_7P451 + + ntpd/ntp.keys.mdoc.in@1.162 +2 -2 + NTP_4_2_7P451 + + ntpd/ntpd-opts.c@1.462 +7 -7 + NTP_4_2_7P451 + + ntpd/ntpd-opts.h@1.462 +3 -3 + NTP_4_2_7P451 + + ntpd/ntpd.1ntpdman@1.273 +6 -6 + NTP_4_2_7P451 + + ntpd/ntpd.1ntpdmdoc@1.273 +2 -2 + NTP_4_2_7P451 + + ntpd/ntpd.html@1.120 +2 -2 + NTP_4_2_7P451 + + ntpd/ntpd.man.in@1.273 +6 -6 + NTP_4_2_7P451 + + ntpd/ntpd.mdoc.in@1.273 +2 -2 + NTP_4_2_7P451 + + ntpdc/invoke-ntpdc.texi@1.442 +2 -2 + NTP_4_2_7P451 + + ntpdc/ntpdc-opts.c@1.457 +7 -7 + NTP_4_2_7P451 + + ntpdc/ntpdc-opts.h@1.457 +3 -3 + NTP_4_2_7P451 + + ntpdc/ntpdc.1ntpdcman@1.273 +6 -6 + NTP_4_2_7P451 + + ntpdc/ntpdc.1ntpdcmdoc@1.273 +2 -2 + NTP_4_2_7P451 + + ntpdc/ntpdc.html@1.286 +2 -2 + NTP_4_2_7P451 + + ntpdc/ntpdc.man.in@1.273 +6 -6 + NTP_4_2_7P451 + + ntpdc/ntpdc.mdoc.in@1.273 +2 -2 + NTP_4_2_7P451 + + ntpq/invoke-ntpq.texi@1.446 +2 -2 + NTP_4_2_7P451 + + ntpq/ntpq-opts.c@1.460 +7 -7 + NTP_4_2_7P451 + + ntpq/ntpq-opts.h@1.460 +3 -3 + NTP_4_2_7P451 + + ntpq/ntpq.1ntpqman@1.274 +6 -6 + NTP_4_2_7P451 + + ntpq/ntpq.1ntpqmdoc@1.274 +2 -2 + NTP_4_2_7P451 + + ntpq/ntpq.html@1.117 +2 -2 + NTP_4_2_7P451 + + ntpq/ntpq.man.in@1.274 +6 -6 + NTP_4_2_7P451 + + ntpq/ntpq.mdoc.in@1.274 +2 -2 + NTP_4_2_7P451 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.444 +2 -2 + NTP_4_2_7P451 + + ntpsnmpd/ntpsnmpd-opts.c@1.459 +7 -7 + NTP_4_2_7P451 + + ntpsnmpd/ntpsnmpd-opts.h@1.459 +3 -3 + NTP_4_2_7P451 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.273 +6 -6 + NTP_4_2_7P451 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.273 +2 -2 + NTP_4_2_7P451 + + ntpsnmpd/ntpsnmpd.html@1.115 +1 -1 + NTP_4_2_7P451 + + ntpsnmpd/ntpsnmpd.man.in@1.273 +6 -6 + NTP_4_2_7P451 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.273 +2 -2 + NTP_4_2_7P451 + + packageinfo.sh@1.455 +1 -1 + NTP_4_2_7P451 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.35 +6 -6 + NTP_4_2_7P451 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.35 +2 -2 + NTP_4_2_7P451 + + scripts/calc_tickadj/calc_tickadj.html@1.34 +1 -1 + NTP_4_2_7P451 + + scripts/calc_tickadj/calc_tickadj.man.in@1.34 +6 -6 + NTP_4_2_7P451 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.35 +2 -2 + NTP_4_2_7P451 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.36 +1 -1 + NTP_4_2_7P451 + + scripts/invoke-plot_summary.texi@1.53 +1 -1 + NTP_4_2_7P451 + + scripts/invoke-summary.texi@1.53 +1 -1 + NTP_4_2_7P451 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.262 +1 -1 + NTP_4_2_7P451 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.263 +6 -6 + NTP_4_2_7P451 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.263 +2 -2 + NTP_4_2_7P451 + + scripts/ntp-wait/ntp-wait.html@1.279 +1 -1 + NTP_4_2_7P451 + + scripts/ntp-wait/ntp-wait.man.in@1.263 +6 -6 + NTP_4_2_7P451 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.263 +2 -2 + NTP_4_2_7P451 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.51 +1 -1 + NTP_4_2_7P451 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.42 +6 -6 + NTP_4_2_7P451 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.42 +2 -2 + NTP_4_2_7P451 + + scripts/ntpsweep/ntpsweep.html@1.52 +1 -1 + NTP_4_2_7P451 + + scripts/ntpsweep/ntpsweep.man.in@1.42 +6 -6 + NTP_4_2_7P451 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.43 +2 -2 + NTP_4_2_7P451 + + scripts/ntptrace/invoke-ntptrace.texi@1.51 +1 -1 + NTP_4_2_7P451 + + scripts/ntptrace/ntptrace.1ntptraceman@1.42 +6 -6 + NTP_4_2_7P451 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.42 +2 -2 + NTP_4_2_7P451 + + scripts/ntptrace/ntptrace.html@1.52 +1 -1 + NTP_4_2_7P451 + + scripts/ntptrace/ntptrace.man.in@1.42 +6 -6 + NTP_4_2_7P451 + + scripts/ntptrace/ntptrace.mdoc.in@1.43 +2 -2 + NTP_4_2_7P451 + + scripts/plot_summary.1plot_summaryman@1.53 +6 -6 + NTP_4_2_7P451 + + scripts/plot_summary.1plot_summarymdoc@1.53 +2 -2 + NTP_4_2_7P451 + + scripts/plot_summary.html@1.53 +1 -1 + NTP_4_2_7P451 + + scripts/plot_summary.man.in@1.53 +6 -6 + NTP_4_2_7P451 + + scripts/plot_summary.mdoc.in@1.53 +2 -2 + NTP_4_2_7P451 + + scripts/summary.1summaryman@1.53 +6 -6 + NTP_4_2_7P451 + + scripts/summary.1summarymdoc@1.53 +2 -2 + NTP_4_2_7P451 + + scripts/summary.html@1.53 +1 -1 + NTP_4_2_7P451 + + scripts/summary.man.in@1.53 +6 -6 + NTP_4_2_7P451 + + scripts/summary.mdoc.in@1.53 +2 -2 + NTP_4_2_7P451 + + sntp/invoke-sntp.texi@1.441 +2 -2 + NTP_4_2_7P451 + + sntp/sntp-opts.c@1.456 +7 -7 + NTP_4_2_7P451 + + sntp/sntp-opts.h@1.456 +3 -3 + NTP_4_2_7P451 + + sntp/sntp.1sntpman@1.276 +6 -6 + NTP_4_2_7P451 + + sntp/sntp.1sntpmdoc@1.276 +2 -2 + NTP_4_2_7P451 + + sntp/sntp.html@1.456 +2 -2 + NTP_4_2_7P451 + + sntp/sntp.man.in@1.276 +6 -6 + NTP_4_2_7P451 + + sntp/sntp.mdoc.in@1.276 +2 -2 + NTP_4_2_7P451 + + util/invoke-ntp-keygen.texi@1.445 +2 -2 + NTP_4_2_7P451 + + util/ntp-keygen-opts.c@1.459 +7 -7 + NTP_4_2_7P451 + + util/ntp-keygen-opts.h@1.459 +3 -3 + NTP_4_2_7P451 + + util/ntp-keygen.1ntp-keygenman@1.273 +6 -6 + NTP_4_2_7P451 + + util/ntp-keygen.1ntp-keygenmdoc@1.273 +2 -2 + NTP_4_2_7P451 + + util/ntp-keygen.html@1.121 +2 -2 + NTP_4_2_7P451 + + util/ntp-keygen.man.in@1.273 +6 -6 + NTP_4_2_7P451 + + util/ntp-keygen.mdoc.in@1.273 +2 -2 + NTP_4_2_7P451 + +ChangeSet@1.3151, 2014-07-17 06:13:14+00:00, stenn@psp-deb1.ntp.org + Fix the "Last update" entries in the html/ subtree + + ChangeLog@1.1497 +1 -0 + Fix the "Last update" entries in the html/ subtree + + html/access.html@1.2 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/accopt.html@1.42 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/audio.html@1.23 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/authentic.html@1.14 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/authopt.html@1.74 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/autokey.html@1.22 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/bugs.html@1.7 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/build.html@1.27 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/clock.html@1.4 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/clockopt.html@1.24 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/cluster.html@1.9 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/debug.html@1.33 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver1.html@1.22 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver10.html@1.14 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver11.html@1.14 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver12.html@1.13 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver18.html@1.20 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver19.html@1.13 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver22.html@1.22 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver3.html@1.13 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver36.html@1.35 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver4.html@1.17 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver6.html@1.29 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/drivers/driver7.html@1.30 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/hints/winnt.html@1.24 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/index.html@1.47 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/ntp_conf.html@1.7 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/ntpdsim.html@1.9 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/ntptime.html@1.18 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/orphan.html@1.4 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/quick.html@1.25 +2 -2 + Fix the "Last update" entries in the html/ subtree + + html/release.html@1.43 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/sitemap.html@1.5 +1 -1 + Fix the "Last update" entries in the html/ subtree + + html/sntp.html@1.10 +1 -1 + Fix the "Last update" entries in the html/ subtree + +ChangeSet@1.3148.1.1, 2014-07-17 00:02:39+02:00, jnperlin@hydra.(none) + [Bug 2597] leap file loose ends + - uniform log messages for timer and config triggered leap file loads + - timer triggered load errors only once per day + + ChangeLog@1.1494.1.1 +4 -0 + [Bug 2597] leap file loose ends + - uniform log messages for timer and config triggered leap file loads + - timer triggered load errors only once per day + + ntpd/ntp_leapsec.c@1.13 +37 -32 + [Bug 2597] file/stream load supports 'logall' flag to enable silent operation + + ntpd/ntp_leapsec.h@1.8 +3 -2 + [Bug 2597] file/stream load supports 'logall' flag to enable silent operation + + ntpd/ntp_timer.c@1.82 +4 -4 + [Bug 2597] proper setup for leap file check timer + + ntpd/ntp_util.c@1.115 +32 -11 + [Bug 2597] unified expiration check messages for timer and config triggered leap file load + +ChangeSet@1.3150, 2014-07-16 21:57:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P450 + TAG: NTP_4_2_7P450 + + ChangeLog@1.1496 +1 -0 + NTP_4_2_7P450 + + ntpd/invoke-ntp.conf.texi@1.129 +1 -1 + NTP_4_2_7P450 + + ntpd/invoke-ntp.keys.texi@1.127 +1 -1 + NTP_4_2_7P450 + + ntpd/invoke-ntpd.texi@1.443 +2 -2 + NTP_4_2_7P450 + + ntpd/ntp.conf.5man@1.163 +6 -6 + NTP_4_2_7P450 + + ntpd/ntp.conf.5mdoc@1.163 +1 -1 + NTP_4_2_7P450 + + ntpd/ntp.conf.html@1.124 +1 -1 + NTP_4_2_7P450 + + ntpd/ntp.conf.man.in@1.163 +6 -6 + NTP_4_2_7P450 + + ntpd/ntp.conf.mdoc.in@1.163 +1 -1 + NTP_4_2_7P450 + + ntpd/ntp.keys.5man@1.161 +2 -2 + NTP_4_2_7P450 + + ntpd/ntp.keys.5mdoc@1.161 +1 -1 + NTP_4_2_7P450 + + ntpd/ntp.keys.html@1.125 +1 -1 + NTP_4_2_7P450 + + ntpd/ntp.keys.man.in@1.161 +2 -2 + NTP_4_2_7P450 + + ntpd/ntp.keys.mdoc.in@1.161 +1 -1 + NTP_4_2_7P450 + + ntpd/ntpd-opts.c@1.461 +7 -7 + NTP_4_2_7P450 + + ntpd/ntpd-opts.h@1.461 +3 -3 + NTP_4_2_7P450 + + ntpd/ntpd.1ntpdman@1.272 +6 -6 + NTP_4_2_7P450 + + ntpd/ntpd.1ntpdmdoc@1.272 +1 -1 + NTP_4_2_7P450 + + ntpd/ntpd.html@1.119 +2 -2 + NTP_4_2_7P450 + + ntpd/ntpd.man.in@1.272 +6 -6 + NTP_4_2_7P450 + + ntpd/ntpd.mdoc.in@1.272 +1 -1 + NTP_4_2_7P450 + + ntpdc/invoke-ntpdc.texi@1.441 +2 -2 + NTP_4_2_7P450 + + ntpdc/ntpdc-opts.c@1.456 +7 -7 + NTP_4_2_7P450 + + ntpdc/ntpdc-opts.h@1.456 +3 -3 + NTP_4_2_7P450 + + ntpdc/ntpdc.1ntpdcman@1.272 +6 -6 + NTP_4_2_7P450 + + ntpdc/ntpdc.1ntpdcmdoc@1.272 +1 -1 + NTP_4_2_7P450 + + ntpdc/ntpdc.html@1.285 +2 -2 + NTP_4_2_7P450 + + ntpdc/ntpdc.man.in@1.272 +6 -6 + NTP_4_2_7P450 + + ntpdc/ntpdc.mdoc.in@1.272 +1 -1 + NTP_4_2_7P450 + + ntpq/invoke-ntpq.texi@1.445 +2 -2 + NTP_4_2_7P450 + + ntpq/ntpq-opts.c@1.459 +7 -7 + NTP_4_2_7P450 + + ntpq/ntpq-opts.h@1.459 +3 -3 + NTP_4_2_7P450 + + ntpq/ntpq.1ntpqman@1.273 +6 -6 + NTP_4_2_7P450 + + ntpq/ntpq.1ntpqmdoc@1.273 +1 -1 + NTP_4_2_7P450 + + ntpq/ntpq.html@1.116 +2 -2 + NTP_4_2_7P450 + + ntpq/ntpq.man.in@1.273 +6 -6 + NTP_4_2_7P450 + + ntpq/ntpq.mdoc.in@1.273 +1 -1 + NTP_4_2_7P450 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.443 +2 -2 + NTP_4_2_7P450 + + ntpsnmpd/ntpsnmpd-opts.c@1.458 +7 -7 + NTP_4_2_7P450 + + ntpsnmpd/ntpsnmpd-opts.h@1.458 +3 -3 + NTP_4_2_7P450 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.272 +6 -6 + NTP_4_2_7P450 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.272 +1 -1 + NTP_4_2_7P450 + + ntpsnmpd/ntpsnmpd.html@1.114 +1 -1 + NTP_4_2_7P450 + + ntpsnmpd/ntpsnmpd.man.in@1.272 +6 -6 + NTP_4_2_7P450 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.272 +1 -1 + NTP_4_2_7P450 + + packageinfo.sh@1.454 +1 -1 + NTP_4_2_7P450 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.34 +6 -6 + NTP_4_2_7P450 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.34 +1 -1 + NTP_4_2_7P450 + + scripts/calc_tickadj/calc_tickadj.html@1.33 +1 -1 + NTP_4_2_7P450 + + scripts/calc_tickadj/calc_tickadj.man.in@1.33 +6 -6 + NTP_4_2_7P450 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.34 +1 -1 + NTP_4_2_7P450 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.35 +1 -1 + NTP_4_2_7P450 + + scripts/invoke-plot_summary.texi@1.52 +1 -1 + NTP_4_2_7P450 + + scripts/invoke-summary.texi@1.52 +1 -1 + NTP_4_2_7P450 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.261 +1 -1 + NTP_4_2_7P450 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.262 +6 -6 + NTP_4_2_7P450 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.262 +1 -1 + NTP_4_2_7P450 + + scripts/ntp-wait/ntp-wait.html@1.278 +1 -1 + NTP_4_2_7P450 + + scripts/ntp-wait/ntp-wait.man.in@1.262 +6 -6 + NTP_4_2_7P450 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.262 +1 -1 + NTP_4_2_7P450 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.50 +1 -1 + NTP_4_2_7P450 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.41 +6 -6 + NTP_4_2_7P450 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.41 +1 -1 + NTP_4_2_7P450 + + scripts/ntpsweep/ntpsweep.html@1.51 +1 -1 + NTP_4_2_7P450 + + scripts/ntpsweep/ntpsweep.man.in@1.41 +6 -6 + NTP_4_2_7P450 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.42 +1 -1 + NTP_4_2_7P450 + + scripts/ntptrace/invoke-ntptrace.texi@1.50 +1 -1 + NTP_4_2_7P450 + + scripts/ntptrace/ntptrace.1ntptraceman@1.41 +6 -6 + NTP_4_2_7P450 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.41 +1 -1 + NTP_4_2_7P450 + + scripts/ntptrace/ntptrace.html@1.51 +1 -1 + NTP_4_2_7P450 + + scripts/ntptrace/ntptrace.man.in@1.41 +6 -6 + NTP_4_2_7P450 + + scripts/ntptrace/ntptrace.mdoc.in@1.42 +1 -1 + NTP_4_2_7P450 + + scripts/plot_summary.1plot_summaryman@1.52 +6 -6 + NTP_4_2_7P450 + + scripts/plot_summary.1plot_summarymdoc@1.52 +2 -2 + NTP_4_2_7P450 + + scripts/plot_summary.html@1.52 +1 -1 + NTP_4_2_7P450 + + scripts/plot_summary.man.in@1.52 +6 -6 + NTP_4_2_7P450 + + scripts/plot_summary.mdoc.in@1.52 +2 -2 + NTP_4_2_7P450 + + scripts/summary.1summaryman@1.52 +6 -6 + NTP_4_2_7P450 + + scripts/summary.1summarymdoc@1.52 +1 -1 + NTP_4_2_7P450 + + scripts/summary.html@1.52 +1 -1 + NTP_4_2_7P450 + + scripts/summary.man.in@1.52 +6 -6 + NTP_4_2_7P450 + + scripts/summary.mdoc.in@1.52 +1 -1 + NTP_4_2_7P450 + + sntp/invoke-sntp.texi@1.440 +2 -2 + NTP_4_2_7P450 + + sntp/sntp-opts.c@1.455 +7 -7 + NTP_4_2_7P450 + + sntp/sntp-opts.h@1.455 +3 -3 + NTP_4_2_7P450 + + sntp/sntp.1sntpman@1.275 +6 -6 + NTP_4_2_7P450 + + sntp/sntp.1sntpmdoc@1.275 +1 -1 + NTP_4_2_7P450 + + sntp/sntp.html@1.455 +2 -2 + NTP_4_2_7P450 + + sntp/sntp.man.in@1.275 +6 -6 + NTP_4_2_7P450 + + sntp/sntp.mdoc.in@1.275 +1 -1 + NTP_4_2_7P450 + + util/invoke-ntp-keygen.texi@1.444 +2 -2 + NTP_4_2_7P450 + + util/ntp-keygen-opts.c@1.458 +7 -7 + NTP_4_2_7P450 + + util/ntp-keygen-opts.h@1.458 +3 -3 + NTP_4_2_7P450 + + util/ntp-keygen.1ntp-keygenman@1.272 +6 -6 + NTP_4_2_7P450 + + util/ntp-keygen.1ntp-keygenmdoc@1.272 +1 -1 + NTP_4_2_7P450 + + util/ntp-keygen.html@1.120 +2 -2 + NTP_4_2_7P450 + + util/ntp-keygen.man.in@1.272 +6 -6 + NTP_4_2_7P450 + + util/ntp-keygen.mdoc.in@1.272 +1 -1 + NTP_4_2_7P450 + +ChangeSet@1.3149, 2014-07-16 17:20:01-04:00, stenn@deacon.udel.edu + Distribute the scripts needed for the fix for Bug 2547 + + ChangeLog@1.1495 +1 -0 + Distribute the scripts needed for the fix for Bug 2547 + + scripts/build/Makefile.am@1.3 +5 -1 + Distribute the scripts needed for the fix for Bug 2547 + + scripts/build/Makefile.am@1.2 +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.3148, 2014-07-16 09:33:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P449 + TAG: NTP_4_2_7P449 + + ChangeLog@1.1494 +1 -0 + NTP_4_2_7P449 + + ntpd/invoke-ntp.conf.texi@1.128 +1 -1 + NTP_4_2_7P449 + + ntpd/invoke-ntp.keys.texi@1.126 +1 -1 + NTP_4_2_7P449 + + ntpd/invoke-ntpd.texi@1.442 +2 -2 + NTP_4_2_7P449 + + ntpd/ntp.conf.5man@1.162 +6 -6 + NTP_4_2_7P449 + + ntpd/ntp.conf.5mdoc@1.162 +2 -2 + NTP_4_2_7P449 + + ntpd/ntp.conf.html@1.123 +1 -1 + NTP_4_2_7P449 + + ntpd/ntp.conf.man.in@1.162 +6 -6 + NTP_4_2_7P449 + + ntpd/ntp.conf.mdoc.in@1.162 +2 -2 + NTP_4_2_7P449 + + ntpd/ntp.keys.5man@1.160 +2 -2 + NTP_4_2_7P449 + + ntpd/ntp.keys.5mdoc@1.160 +2 -2 + NTP_4_2_7P449 + + ntpd/ntp.keys.html@1.124 +1 -1 + NTP_4_2_7P449 + + ntpd/ntp.keys.man.in@1.160 +2 -2 + NTP_4_2_7P449 + + ntpd/ntp.keys.mdoc.in@1.160 +2 -2 + NTP_4_2_7P449 + + ntpd/ntpd-opts.c@1.460 +7 -7 + NTP_4_2_7P449 + + ntpd/ntpd-opts.h@1.460 +3 -3 + NTP_4_2_7P449 + + ntpd/ntpd.1ntpdman@1.271 +6 -6 + NTP_4_2_7P449 + + ntpd/ntpd.1ntpdmdoc@1.271 +2 -2 + NTP_4_2_7P449 + + ntpd/ntpd.html@1.118 +2 -2 + NTP_4_2_7P449 + + ntpd/ntpd.man.in@1.271 +6 -6 + NTP_4_2_7P449 + + ntpd/ntpd.mdoc.in@1.271 +2 -2 + NTP_4_2_7P449 + + ntpdc/invoke-ntpdc.texi@1.440 +2 -2 + NTP_4_2_7P449 + + ntpdc/ntpdc-opts.c@1.455 +7 -7 + NTP_4_2_7P449 + + ntpdc/ntpdc-opts.h@1.455 +3 -3 + NTP_4_2_7P449 + + ntpdc/ntpdc.1ntpdcman@1.271 +6 -6 + NTP_4_2_7P449 + + ntpdc/ntpdc.1ntpdcmdoc@1.271 +2 -2 + NTP_4_2_7P449 + + ntpdc/ntpdc.html@1.284 +2 -2 + NTP_4_2_7P449 + + ntpdc/ntpdc.man.in@1.271 +6 -6 + NTP_4_2_7P449 + + ntpdc/ntpdc.mdoc.in@1.271 +2 -2 + NTP_4_2_7P449 + + ntpq/invoke-ntpq.texi@1.444 +2 -2 + NTP_4_2_7P449 + + ntpq/ntpq-opts.c@1.458 +7 -7 + NTP_4_2_7P449 + + ntpq/ntpq-opts.h@1.458 +3 -3 + NTP_4_2_7P449 + + ntpq/ntpq.1ntpqman@1.272 +6 -6 + NTP_4_2_7P449 + + ntpq/ntpq.1ntpqmdoc@1.272 +2 -2 + NTP_4_2_7P449 + + ntpq/ntpq.html@1.115 +2 -2 + NTP_4_2_7P449 + + ntpq/ntpq.man.in@1.272 +6 -6 + NTP_4_2_7P449 + + ntpq/ntpq.mdoc.in@1.272 +2 -2 + NTP_4_2_7P449 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.442 +2 -2 + NTP_4_2_7P449 + + ntpsnmpd/ntpsnmpd-opts.c@1.457 +7 -7 + NTP_4_2_7P449 + + ntpsnmpd/ntpsnmpd-opts.h@1.457 +3 -3 + NTP_4_2_7P449 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.271 +6 -6 + NTP_4_2_7P449 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.271 +2 -2 + NTP_4_2_7P449 + + ntpsnmpd/ntpsnmpd.html@1.113 +1 -1 + NTP_4_2_7P449 + + ntpsnmpd/ntpsnmpd.man.in@1.271 +6 -6 + NTP_4_2_7P449 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.271 +2 -2 + NTP_4_2_7P449 + + packageinfo.sh@1.453 +1 -1 + NTP_4_2_7P449 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.33 +6 -6 + NTP_4_2_7P449 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.33 +2 -2 + NTP_4_2_7P449 + + scripts/calc_tickadj/calc_tickadj.html@1.32 +1 -1 + NTP_4_2_7P449 + + scripts/calc_tickadj/calc_tickadj.man.in@1.32 +6 -6 + NTP_4_2_7P449 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.33 +2 -2 + NTP_4_2_7P449 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.34 +1 -1 + NTP_4_2_7P449 + + scripts/invoke-plot_summary.texi@1.51 +1 -1 + NTP_4_2_7P449 + + scripts/invoke-summary.texi@1.51 +1 -1 + NTP_4_2_7P449 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.260 +1 -1 + NTP_4_2_7P449 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.261 +6 -6 + NTP_4_2_7P449 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.261 +2 -2 + NTP_4_2_7P449 + + scripts/ntp-wait/ntp-wait.html@1.277 +1 -1 + NTP_4_2_7P449 + + scripts/ntp-wait/ntp-wait.man.in@1.261 +6 -6 + NTP_4_2_7P449 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.261 +2 -2 + NTP_4_2_7P449 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.49 +1 -1 + NTP_4_2_7P449 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.40 +6 -6 + NTP_4_2_7P449 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.40 +2 -2 + NTP_4_2_7P449 + + scripts/ntpsweep/ntpsweep.html@1.50 +1 -1 + NTP_4_2_7P449 + + scripts/ntpsweep/ntpsweep.man.in@1.40 +6 -6 + NTP_4_2_7P449 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.41 +2 -2 + NTP_4_2_7P449 + + scripts/ntptrace/invoke-ntptrace.texi@1.49 +1 -1 + NTP_4_2_7P449 + + scripts/ntptrace/ntptrace.1ntptraceman@1.40 +6 -6 + NTP_4_2_7P449 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.40 +2 -2 + NTP_4_2_7P449 + + scripts/ntptrace/ntptrace.html@1.50 +1 -1 + NTP_4_2_7P449 + + scripts/ntptrace/ntptrace.man.in@1.40 +6 -6 + NTP_4_2_7P449 + + scripts/ntptrace/ntptrace.mdoc.in@1.41 +2 -2 + NTP_4_2_7P449 + + scripts/plot_summary.1plot_summaryman@1.51 +6 -6 + NTP_4_2_7P449 + + scripts/plot_summary.1plot_summarymdoc@1.51 +3 -3 + NTP_4_2_7P449 + + scripts/plot_summary.html@1.51 +1 -1 + NTP_4_2_7P449 + + scripts/plot_summary.man.in@1.51 +6 -6 + NTP_4_2_7P449 + + scripts/plot_summary.mdoc.in@1.51 +3 -3 + NTP_4_2_7P449 + + scripts/summary.1summaryman@1.51 +6 -6 + NTP_4_2_7P449 + + scripts/summary.1summarymdoc@1.51 +2 -2 + NTP_4_2_7P449 + + scripts/summary.html@1.51 +1 -1 + NTP_4_2_7P449 + + scripts/summary.man.in@1.51 +6 -6 + NTP_4_2_7P449 + + scripts/summary.mdoc.in@1.51 +2 -2 + NTP_4_2_7P449 + + sntp/invoke-sntp.texi@1.439 +2 -2 + NTP_4_2_7P449 + + sntp/sntp-opts.c@1.454 +7 -7 + NTP_4_2_7P449 + + sntp/sntp-opts.h@1.454 +3 -3 + NTP_4_2_7P449 + + sntp/sntp.1sntpman@1.274 +6 -6 + NTP_4_2_7P449 + + sntp/sntp.1sntpmdoc@1.274 +2 -2 + NTP_4_2_7P449 + + sntp/sntp.html@1.454 +2 -2 + NTP_4_2_7P449 + + sntp/sntp.man.in@1.274 +6 -6 + NTP_4_2_7P449 + + sntp/sntp.mdoc.in@1.274 +2 -2 + NTP_4_2_7P449 + + util/invoke-ntp-keygen.texi@1.443 +2 -2 + NTP_4_2_7P449 + + util/ntp-keygen-opts.c@1.457 +7 -7 + NTP_4_2_7P449 + + util/ntp-keygen-opts.h@1.457 +3 -3 + NTP_4_2_7P449 + + util/ntp-keygen.1ntp-keygenman@1.271 +6 -6 + NTP_4_2_7P449 + + util/ntp-keygen.1ntp-keygenmdoc@1.271 +2 -2 + NTP_4_2_7P449 + + util/ntp-keygen.html@1.119 +2 -2 + NTP_4_2_7P449 + + util/ntp-keygen.man.in@1.271 +6 -6 + NTP_4_2_7P449 + + util/ntp-keygen.mdoc.in@1.271 +2 -2 + NTP_4_2_7P449 + +ChangeSet@1.3147, 2014-07-16 01:37:41-07:00, harlan@hms-mbp11.pfcs.com + Fix typos in decode.html and debug.html + + ChangeLog@1.1493 +1 -0 + Fix typos in decode.html and debug.html + + html/debug.html@1.32 +3 -3 + Fix typos in decode.html and debug.html + + html/decode.html@1.24 +1 -1 + Fix typos in decode.html and debug.html + +ChangeSet@1.3146, 2014-07-16 01:33:06-07:00, harlan@hms-mbp11.pfcs.com + [Bug 2547] Automate update of "Last Update" datestamps in .html files + + ChangeLog@1.1492 +1 -0 + [Bug 2547] Automate update of "Last Update" datestamps in .html files + + Makefile.am@1.119 +24 -19 + [Bug 2547] Automate update of "Last Update" datestamps in .html files + + scripts/build/checkHtmlFileDates@1.1 +16 -0 + BitKeeper file /Users/harlan/src/ntp-dev/scripts/build/checkHtmlFileDates + + scripts/build/checkHtmlFileDates@1.0 +0 -0 + + scripts/build/updateBEDate@1.1 +53 -0 + BitKeeper file /Users/harlan/src/ntp-dev/scripts/build/updateBEDate + + scripts/build/updateBEDate@1.0 +0 -0 + +ChangeSet@1.3145, 2014-07-16 02:45:17-04:00, stenn@deacon.udel.edu + Quiet warnings from ntp_calendar.h: avoid using argument names + + ChangeLog@1.1491 +1 -0 + Quiet warnings from ntp_calendar.h: avoid using argument names + + include/ntp_calendar.h@1.16 +41 -38 + Quiet warnings from ntp_calendar.h: avoid using argument names + +ChangeSet@1.3144, 2014-07-16 04:17:40+00:00, stenn@psp-fb1.ntp.org + [Bug 2623] Missing {} in refclock_oncore.c + + ChangeLog@1.1490 +1 -0 + [Bug 2623] Missing {} in refclock_oncore.c + + ntpd/refclock_oncore.c@1.100 +2 -1 + [Bug 2623] Missing {} in refclock_oncore.c + +ChangeSet@1.3143, 2014-07-15 09:34:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P448 + TAG: NTP_4_2_7P448 + + ChangeLog@1.1489 +1 -0 + NTP_4_2_7P448 + + ntpd/invoke-ntp.conf.texi@1.127 +1 -1 + NTP_4_2_7P448 + + ntpd/invoke-ntp.keys.texi@1.125 +1 -1 + NTP_4_2_7P448 + + ntpd/invoke-ntpd.texi@1.441 +2 -2 + NTP_4_2_7P448 + + ntpd/ntp.conf.5man@1.161 +6 -6 + NTP_4_2_7P448 + + ntpd/ntp.conf.5mdoc@1.161 +2 -2 + NTP_4_2_7P448 + + ntpd/ntp.conf.html@1.122 +1 -1 + NTP_4_2_7P448 + + ntpd/ntp.conf.man.in@1.161 +6 -6 + NTP_4_2_7P448 + + ntpd/ntp.conf.mdoc.in@1.161 +2 -2 + NTP_4_2_7P448 + + ntpd/ntp.keys.5man@1.159 +2 -2 + NTP_4_2_7P448 + + ntpd/ntp.keys.5mdoc@1.159 +2 -2 + NTP_4_2_7P448 + + ntpd/ntp.keys.html@1.123 +1 -1 + NTP_4_2_7P448 + + ntpd/ntp.keys.man.in@1.159 +2 -2 + NTP_4_2_7P448 + + ntpd/ntp.keys.mdoc.in@1.159 +2 -2 + NTP_4_2_7P448 + + ntpd/ntpd-opts.c@1.459 +7 -7 + NTP_4_2_7P448 + + ntpd/ntpd-opts.h@1.459 +3 -3 + NTP_4_2_7P448 + + ntpd/ntpd.1ntpdman@1.270 +6 -6 + NTP_4_2_7P448 + + ntpd/ntpd.1ntpdmdoc@1.270 +2 -2 + NTP_4_2_7P448 + + ntpd/ntpd.html@1.117 +2 -2 + NTP_4_2_7P448 + + ntpd/ntpd.man.in@1.270 +6 -6 + NTP_4_2_7P448 + + ntpd/ntpd.mdoc.in@1.270 +2 -2 + NTP_4_2_7P448 + + ntpdc/invoke-ntpdc.texi@1.439 +2 -2 + NTP_4_2_7P448 + + ntpdc/ntpdc-opts.c@1.454 +7 -7 + NTP_4_2_7P448 + + ntpdc/ntpdc-opts.h@1.454 +3 -3 + NTP_4_2_7P448 + + ntpdc/ntpdc.1ntpdcman@1.270 +6 -6 + NTP_4_2_7P448 + + ntpdc/ntpdc.1ntpdcmdoc@1.270 +2 -2 + NTP_4_2_7P448 + + ntpdc/ntpdc.html@1.283 +2 -2 + NTP_4_2_7P448 + + ntpdc/ntpdc.man.in@1.270 +6 -6 + NTP_4_2_7P448 + + ntpdc/ntpdc.mdoc.in@1.270 +2 -2 + NTP_4_2_7P448 + + ntpq/invoke-ntpq.texi@1.443 +2 -2 + NTP_4_2_7P448 + + ntpq/ntpq-opts.c@1.457 +7 -7 + NTP_4_2_7P448 + + ntpq/ntpq-opts.h@1.457 +3 -3 + NTP_4_2_7P448 + + ntpq/ntpq.1ntpqman@1.271 +6 -6 + NTP_4_2_7P448 + + ntpq/ntpq.1ntpqmdoc@1.271 +2 -2 + NTP_4_2_7P448 + + ntpq/ntpq.html@1.114 +2 -2 + NTP_4_2_7P448 + + ntpq/ntpq.man.in@1.271 +6 -6 + NTP_4_2_7P448 + + ntpq/ntpq.mdoc.in@1.271 +2 -2 + NTP_4_2_7P448 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.441 +2 -2 + NTP_4_2_7P448 + + ntpsnmpd/ntpsnmpd-opts.c@1.456 +7 -7 + NTP_4_2_7P448 + + ntpsnmpd/ntpsnmpd-opts.h@1.456 +3 -3 + NTP_4_2_7P448 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.270 +6 -6 + NTP_4_2_7P448 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.270 +2 -2 + NTP_4_2_7P448 + + ntpsnmpd/ntpsnmpd.html@1.112 +1 -1 + NTP_4_2_7P448 + + ntpsnmpd/ntpsnmpd.man.in@1.270 +6 -6 + NTP_4_2_7P448 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.270 +2 -2 + NTP_4_2_7P448 + + packageinfo.sh@1.452 +1 -1 + NTP_4_2_7P448 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.32 +6 -6 + NTP_4_2_7P448 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.32 +2 -2 + NTP_4_2_7P448 + + scripts/calc_tickadj/calc_tickadj.html@1.31 +1 -1 + NTP_4_2_7P448 + + scripts/calc_tickadj/calc_tickadj.man.in@1.31 +6 -6 + NTP_4_2_7P448 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.32 +2 -2 + NTP_4_2_7P448 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.33 +1 -1 + NTP_4_2_7P448 + + scripts/invoke-plot_summary.texi@1.50 +1 -1 + NTP_4_2_7P448 + + scripts/invoke-summary.texi@1.50 +1 -1 + NTP_4_2_7P448 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.259 +1 -1 + NTP_4_2_7P448 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.260 +6 -6 + NTP_4_2_7P448 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.260 +2 -2 + NTP_4_2_7P448 + + scripts/ntp-wait/ntp-wait.html@1.276 +1 -1 + NTP_4_2_7P448 + + scripts/ntp-wait/ntp-wait.man.in@1.260 +6 -6 + NTP_4_2_7P448 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.260 +2 -2 + NTP_4_2_7P448 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.48 +1 -1 + NTP_4_2_7P448 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.39 +6 -6 + NTP_4_2_7P448 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.39 +2 -2 + NTP_4_2_7P448 + + scripts/ntpsweep/ntpsweep.html@1.49 +1 -1 + NTP_4_2_7P448 + + scripts/ntpsweep/ntpsweep.man.in@1.39 +6 -6 + NTP_4_2_7P448 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.40 +2 -2 + NTP_4_2_7P448 + + scripts/ntptrace/invoke-ntptrace.texi@1.48 +1 -1 + NTP_4_2_7P448 + + scripts/ntptrace/ntptrace.1ntptraceman@1.39 +6 -6 + NTP_4_2_7P448 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.39 +2 -2 + NTP_4_2_7P448 + + scripts/ntptrace/ntptrace.html@1.49 +1 -1 + NTP_4_2_7P448 + + scripts/ntptrace/ntptrace.man.in@1.39 +6 -6 + NTP_4_2_7P448 + + scripts/ntptrace/ntptrace.mdoc.in@1.40 +2 -2 + NTP_4_2_7P448 + + scripts/plot_summary.1plot_summaryman@1.50 +6 -6 + NTP_4_2_7P448 + + scripts/plot_summary.1plot_summarymdoc@1.50 +3 -3 + NTP_4_2_7P448 + + scripts/plot_summary.html@1.50 +1 -1 + NTP_4_2_7P448 + + scripts/plot_summary.man.in@1.50 +6 -6 + NTP_4_2_7P448 + + scripts/plot_summary.mdoc.in@1.50 +3 -3 + NTP_4_2_7P448 + + scripts/summary.1summaryman@1.50 +6 -6 + NTP_4_2_7P448 + + scripts/summary.1summarymdoc@1.50 +2 -2 + NTP_4_2_7P448 + + scripts/summary.html@1.50 +1 -1 + NTP_4_2_7P448 + + scripts/summary.man.in@1.50 +6 -6 + NTP_4_2_7P448 + + scripts/summary.mdoc.in@1.50 +2 -2 + NTP_4_2_7P448 + + sntp/invoke-sntp.texi@1.438 +2 -2 + NTP_4_2_7P448 + + sntp/sntp-opts.c@1.453 +7 -7 + NTP_4_2_7P448 + + sntp/sntp-opts.h@1.453 +3 -3 + NTP_4_2_7P448 + + sntp/sntp.1sntpman@1.273 +6 -6 + NTP_4_2_7P448 + + sntp/sntp.1sntpmdoc@1.273 +2 -2 + NTP_4_2_7P448 + + sntp/sntp.html@1.453 +2 -2 + NTP_4_2_7P448 + + sntp/sntp.man.in@1.273 +6 -6 + NTP_4_2_7P448 + + sntp/sntp.mdoc.in@1.273 +2 -2 + NTP_4_2_7P448 + + util/invoke-ntp-keygen.texi@1.442 +2 -2 + NTP_4_2_7P448 + + util/ntp-keygen-opts.c@1.456 +7 -7 + NTP_4_2_7P448 + + util/ntp-keygen-opts.h@1.456 +3 -3 + NTP_4_2_7P448 + + util/ntp-keygen.1ntp-keygenman@1.270 +6 -6 + NTP_4_2_7P448 + + util/ntp-keygen.1ntp-keygenmdoc@1.270 +2 -2 + NTP_4_2_7P448 + + util/ntp-keygen.html@1.118 +2 -2 + NTP_4_2_7P448 + + util/ntp-keygen.man.in@1.270 +6 -6 + NTP_4_2_7P448 + + util/ntp-keygen.mdoc.in@1.270 +2 -2 + NTP_4_2_7P448 + +ChangeSet@1.3142, 2014-07-15 08:41:34+00:00, stenn@psp-deb1.ntp.org + Quiet warnings from ntp_calendar.h: avoid using argument names + + ChangeLog@1.1488 +1 -0 + Quiet warnings from ntp_calendar.h: avoid using argument names + + include/ntp_calendar.h@1.15 +8 -8 + Quiet warnings from ntp_calendar.h: avoid using argument names + +ChangeSet@1.3141, 2014-07-12 12:26:38+02:00, jnperlin@hydra.(none) + [Bug 2621] Avoid use of indeterminate address after 'free()' + + ChangeLog@1.1487 +2 -0 + [Bug 2621] Avoid use of indeterminate address after 'free()' + + libntp/recvbuff.c@1.39 +11 -9 + [Bug 2621] Avoid use of indeterminate address after 'free()' + + ntpd/ntp_config.c@1.318 +62 -61 + [Bug 2621] Avoid use of indeterminate address after 'free()', unification of cleanup pattern + + ntpd/ntp_io.c@1.392 +8 -8 + [Bug 2621] Avoid use of indeterminate address after 'free()' + +ChangeSet@1.3140, 2014-07-05 11:09:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P447 + TAG: NTP_4_2_7P447 + + ChangeLog@1.1486 +1 -0 + NTP_4_2_7P447 + + ntpd/invoke-ntp.conf.texi@1.126 +1 -1 + NTP_4_2_7P447 + + ntpd/invoke-ntp.keys.texi@1.124 +1 -1 + NTP_4_2_7P447 + + ntpd/invoke-ntpd.texi@1.440 +2 -2 + NTP_4_2_7P447 + + ntpd/ntp.conf.5man@1.160 +6 -6 + NTP_4_2_7P447 + + ntpd/ntp.conf.5mdoc@1.160 +2 -2 + NTP_4_2_7P447 + + ntpd/ntp.conf.html@1.121 +1 -1 + NTP_4_2_7P447 + + ntpd/ntp.conf.man.in@1.160 +6 -6 + NTP_4_2_7P447 + + ntpd/ntp.conf.mdoc.in@1.160 +2 -2 + NTP_4_2_7P447 + + ntpd/ntp.keys.5man@1.158 +2 -2 + NTP_4_2_7P447 + + ntpd/ntp.keys.5mdoc@1.158 +2 -2 + NTP_4_2_7P447 + + ntpd/ntp.keys.html@1.122 +1 -1 + NTP_4_2_7P447 + + ntpd/ntp.keys.man.in@1.158 +2 -2 + NTP_4_2_7P447 + + ntpd/ntp.keys.mdoc.in@1.158 +2 -2 + NTP_4_2_7P447 + + ntpd/ntpd-opts.c@1.458 +7 -7 + NTP_4_2_7P447 + + ntpd/ntpd-opts.h@1.458 +3 -3 + NTP_4_2_7P447 + + ntpd/ntpd.1ntpdman@1.269 +6 -6 + NTP_4_2_7P447 + + ntpd/ntpd.1ntpdmdoc@1.269 +2 -2 + NTP_4_2_7P447 + + ntpd/ntpd.html@1.116 +2 -2 + NTP_4_2_7P447 + + ntpd/ntpd.man.in@1.269 +6 -6 + NTP_4_2_7P447 + + ntpd/ntpd.mdoc.in@1.269 +2 -2 + NTP_4_2_7P447 + + ntpdc/invoke-ntpdc.texi@1.438 +2 -2 + NTP_4_2_7P447 + + ntpdc/ntpdc-opts.c@1.453 +7 -7 + NTP_4_2_7P447 + + ntpdc/ntpdc-opts.h@1.453 +3 -3 + NTP_4_2_7P447 + + ntpdc/ntpdc.1ntpdcman@1.269 +6 -6 + NTP_4_2_7P447 + + ntpdc/ntpdc.1ntpdcmdoc@1.269 +2 -2 + NTP_4_2_7P447 + + ntpdc/ntpdc.html@1.282 +2 -2 + NTP_4_2_7P447 + + ntpdc/ntpdc.man.in@1.269 +6 -6 + NTP_4_2_7P447 + + ntpdc/ntpdc.mdoc.in@1.269 +2 -2 + NTP_4_2_7P447 + + ntpq/invoke-ntpq.texi@1.442 +2 -2 + NTP_4_2_7P447 + + ntpq/ntpq-opts.c@1.456 +7 -7 + NTP_4_2_7P447 + + ntpq/ntpq-opts.h@1.456 +3 -3 + NTP_4_2_7P447 + + ntpq/ntpq.1ntpqman@1.270 +6 -6 + NTP_4_2_7P447 + + ntpq/ntpq.1ntpqmdoc@1.270 +2 -2 + NTP_4_2_7P447 + + ntpq/ntpq.html@1.113 +2 -2 + NTP_4_2_7P447 + + ntpq/ntpq.man.in@1.270 +6 -6 + NTP_4_2_7P447 + + ntpq/ntpq.mdoc.in@1.270 +2 -2 + NTP_4_2_7P447 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.440 +2 -2 + NTP_4_2_7P447 + + ntpsnmpd/ntpsnmpd-opts.c@1.455 +7 -7 + NTP_4_2_7P447 + + ntpsnmpd/ntpsnmpd-opts.h@1.455 +3 -3 + NTP_4_2_7P447 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.269 +6 -6 + NTP_4_2_7P447 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.269 +2 -2 + NTP_4_2_7P447 + + ntpsnmpd/ntpsnmpd.html@1.111 +1 -1 + NTP_4_2_7P447 + + ntpsnmpd/ntpsnmpd.man.in@1.269 +6 -6 + NTP_4_2_7P447 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.269 +2 -2 + NTP_4_2_7P447 + + packageinfo.sh@1.451 +1 -1 + NTP_4_2_7P447 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.31 +6 -6 + NTP_4_2_7P447 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.31 +2 -2 + NTP_4_2_7P447 + + scripts/calc_tickadj/calc_tickadj.html@1.30 +1 -1 + NTP_4_2_7P447 + + scripts/calc_tickadj/calc_tickadj.man.in@1.30 +6 -6 + NTP_4_2_7P447 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.31 +2 -2 + NTP_4_2_7P447 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.32 +1 -1 + NTP_4_2_7P447 + + scripts/invoke-plot_summary.texi@1.49 +1 -1 + NTP_4_2_7P447 + + scripts/invoke-summary.texi@1.49 +1 -1 + NTP_4_2_7P447 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.258 +1 -1 + NTP_4_2_7P447 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.259 +6 -6 + NTP_4_2_7P447 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.259 +2 -2 + NTP_4_2_7P447 + + scripts/ntp-wait/ntp-wait.html@1.275 +1 -1 + NTP_4_2_7P447 + + scripts/ntp-wait/ntp-wait.man.in@1.259 +6 -6 + NTP_4_2_7P447 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.259 +2 -2 + NTP_4_2_7P447 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.47 +1 -1 + NTP_4_2_7P447 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.38 +6 -6 + NTP_4_2_7P447 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.38 +2 -2 + NTP_4_2_7P447 + + scripts/ntpsweep/ntpsweep.html@1.48 +1 -1 + NTP_4_2_7P447 + + scripts/ntpsweep/ntpsweep.man.in@1.38 +6 -6 + NTP_4_2_7P447 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.39 +2 -2 + NTP_4_2_7P447 + + scripts/ntptrace/invoke-ntptrace.texi@1.47 +1 -1 + NTP_4_2_7P447 + + scripts/ntptrace/ntptrace.1ntptraceman@1.38 +6 -6 + NTP_4_2_7P447 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.38 +2 -2 + NTP_4_2_7P447 + + scripts/ntptrace/ntptrace.html@1.48 +1 -1 + NTP_4_2_7P447 + + scripts/ntptrace/ntptrace.man.in@1.38 +6 -6 + NTP_4_2_7P447 + + scripts/ntptrace/ntptrace.mdoc.in@1.39 +2 -2 + NTP_4_2_7P447 + + scripts/plot_summary.1plot_summaryman@1.49 +6 -6 + NTP_4_2_7P447 + + scripts/plot_summary.1plot_summarymdoc@1.49 +3 -3 + NTP_4_2_7P447 + + scripts/plot_summary.html@1.49 +1 -1 + NTP_4_2_7P447 + + scripts/plot_summary.man.in@1.49 +6 -6 + NTP_4_2_7P447 + + scripts/plot_summary.mdoc.in@1.49 +3 -3 + NTP_4_2_7P447 + + scripts/summary.1summaryman@1.49 +6 -6 + NTP_4_2_7P447 + + scripts/summary.1summarymdoc@1.49 +2 -2 + NTP_4_2_7P447 + + scripts/summary.html@1.49 +1 -1 + NTP_4_2_7P447 + + scripts/summary.man.in@1.49 +6 -6 + NTP_4_2_7P447 + + scripts/summary.mdoc.in@1.49 +2 -2 + NTP_4_2_7P447 + + sntp/invoke-sntp.texi@1.437 +2 -2 + NTP_4_2_7P447 + + sntp/sntp-opts.c@1.452 +7 -7 + NTP_4_2_7P447 + + sntp/sntp-opts.h@1.452 +3 -3 + NTP_4_2_7P447 + + sntp/sntp.1sntpman@1.272 +6 -6 + NTP_4_2_7P447 + + sntp/sntp.1sntpmdoc@1.272 +2 -2 + NTP_4_2_7P447 + + sntp/sntp.html@1.452 +2 -2 + NTP_4_2_7P447 + + sntp/sntp.man.in@1.272 +6 -6 + NTP_4_2_7P447 + + sntp/sntp.mdoc.in@1.272 +2 -2 + NTP_4_2_7P447 + + util/invoke-ntp-keygen.texi@1.441 +2 -2 + NTP_4_2_7P447 + + util/ntp-keygen-opts.c@1.455 +7 -7 + NTP_4_2_7P447 + + util/ntp-keygen-opts.h@1.455 +3 -3 + NTP_4_2_7P447 + + util/ntp-keygen.1ntp-keygenman@1.269 +6 -6 + NTP_4_2_7P447 + + util/ntp-keygen.1ntp-keygenmdoc@1.269 +2 -2 + NTP_4_2_7P447 + + util/ntp-keygen.html@1.117 +2 -2 + NTP_4_2_7P447 + + util/ntp-keygen.man.in@1.269 +6 -6 + NTP_4_2_7P447 + + util/ntp-keygen.mdoc.in@1.269 +2 -2 + NTP_4_2_7P447 + +ChangeSet@1.3139, 2014-07-05 08:22:01+00:00, stenn@psp-deb1.ntp.org + [Bug 2624] Fix signed compare on 'l_fp' + + ChangeLog@1.1485 +1 -1 + [Bug 2624] Fix signed compare on 'l_fp' + +ChangeSet@1.3131.3.2, 2014-07-05 09:34:14+02:00, jnperlin@hydra.(none) + [Bug 2618) (side work) added unit test for 'l_fp' operations + + ChangeLog@1.1478.3.1 +1 -0 + [Bug 2618) (side work) added unit test for 'l_fp' operations + + include/ntp_fp.h@1.31 +3 -3 + fixed a sign/unsigned compare problem inside signed compare macros + + tests/libntp/lfpfunc.cpp@1.2 +224 -28 + added relational operation tests + cleanup and more independent reference implementations + +ChangeSet@1.3137, 2014-07-04 16:57:21-04:00, stenn@deacon.udel.edu + Remove extraneous NULs + + readme.y2kfixes@1.6 +1 -75 + Remove extraneous NULs + +ChangeSet@1.3136, 2014-07-04 03:12:30+00:00, stenn@psp-deb1.ntp.org + [Bug 2620] Use version.pm for checking version numbers in NTP::Util + + ChangeLog@1.1483 +1 -0 + [Bug 2620] Use version.pm for checking version numbers in NTP::Util + + scripts/lib/NTP/Util.pm@1.2 +2 -1 + [Bug 2620] Use version.pm for checking version numbers in NTP::Util + +ChangeSet@1.3131.3.1, 2014-07-01 00:59:29+02:00, jnperlin@hydra.(none) + added first tests for 'l_fp' + + tests/libntp/Makefile.am@1.42 +1 -0 + added first tests for 'l_fp' + + tests/libntp/lfpfunc.cpp@1.1 +351 -0 + added first tests for 'l_fp' + + tests/libntp/lfpfunc.cpp@1.0 +0 -0 + +ChangeSet@1.3135, 2014-06-28 09:33:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P446 + TAG: NTP_4_2_7P446 + + ChangeLog@1.1482 +1 -0 + NTP_4_2_7P446 + + ntpd/invoke-ntp.conf.texi@1.125 +1 -1 + NTP_4_2_7P446 + + ntpd/invoke-ntp.keys.texi@1.123 +1 -1 + NTP_4_2_7P446 + + ntpd/invoke-ntpd.texi@1.439 +2 -2 + NTP_4_2_7P446 + + ntpd/ntp.conf.5man@1.159 +6 -6 + NTP_4_2_7P446 + + ntpd/ntp.conf.5mdoc@1.159 +2 -2 + NTP_4_2_7P446 + + ntpd/ntp.conf.html@1.120 +1 -1 + NTP_4_2_7P446 + + ntpd/ntp.conf.man.in@1.159 +6 -6 + NTP_4_2_7P446 + + ntpd/ntp.conf.mdoc.in@1.159 +2 -2 + NTP_4_2_7P446 + + ntpd/ntp.keys.5man@1.157 +2 -2 + NTP_4_2_7P446 + + ntpd/ntp.keys.5mdoc@1.157 +2 -2 + NTP_4_2_7P446 + + ntpd/ntp.keys.html@1.121 +1 -1 + NTP_4_2_7P446 + + ntpd/ntp.keys.man.in@1.157 +2 -2 + NTP_4_2_7P446 + + ntpd/ntp.keys.mdoc.in@1.157 +2 -2 + NTP_4_2_7P446 + + ntpd/ntpd-opts.c@1.457 +7 -7 + NTP_4_2_7P446 + + ntpd/ntpd-opts.h@1.457 +3 -3 + NTP_4_2_7P446 + + ntpd/ntpd.1ntpdman@1.268 +6 -6 + NTP_4_2_7P446 + + ntpd/ntpd.1ntpdmdoc@1.268 +2 -2 + NTP_4_2_7P446 + + ntpd/ntpd.html@1.115 +2 -2 + NTP_4_2_7P446 + + ntpd/ntpd.man.in@1.268 +6 -6 + NTP_4_2_7P446 + + ntpd/ntpd.mdoc.in@1.268 +2 -2 + NTP_4_2_7P446 + + ntpdc/invoke-ntpdc.texi@1.437 +2 -2 + NTP_4_2_7P446 + + ntpdc/ntpdc-opts.c@1.452 +7 -7 + NTP_4_2_7P446 + + ntpdc/ntpdc-opts.h@1.452 +3 -3 + NTP_4_2_7P446 + + ntpdc/ntpdc.1ntpdcman@1.268 +6 -6 + NTP_4_2_7P446 + + ntpdc/ntpdc.1ntpdcmdoc@1.268 +2 -2 + NTP_4_2_7P446 + + ntpdc/ntpdc.html@1.281 +2 -2 + NTP_4_2_7P446 + + ntpdc/ntpdc.man.in@1.268 +6 -6 + NTP_4_2_7P446 + + ntpdc/ntpdc.mdoc.in@1.268 +2 -2 + NTP_4_2_7P446 + + ntpq/invoke-ntpq.texi@1.441 +2 -2 + NTP_4_2_7P446 + + ntpq/ntpq-opts.c@1.455 +7 -7 + NTP_4_2_7P446 + + ntpq/ntpq-opts.h@1.455 +3 -3 + NTP_4_2_7P446 + + ntpq/ntpq.1ntpqman@1.269 +6 -6 + NTP_4_2_7P446 + + ntpq/ntpq.1ntpqmdoc@1.269 +2 -2 + NTP_4_2_7P446 + + ntpq/ntpq.html@1.112 +3 -3 + NTP_4_2_7P446 + + ntpq/ntpq.man.in@1.269 +6 -6 + NTP_4_2_7P446 + + ntpq/ntpq.mdoc.in@1.269 +2 -2 + NTP_4_2_7P446 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.439 +2 -2 + NTP_4_2_7P446 + + ntpsnmpd/ntpsnmpd-opts.c@1.454 +7 -7 + NTP_4_2_7P446 + + ntpsnmpd/ntpsnmpd-opts.h@1.454 +3 -3 + NTP_4_2_7P446 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.268 +6 -6 + NTP_4_2_7P446 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.268 +2 -2 + NTP_4_2_7P446 + + ntpsnmpd/ntpsnmpd.html@1.110 +1 -1 + NTP_4_2_7P446 + + ntpsnmpd/ntpsnmpd.man.in@1.268 +6 -6 + NTP_4_2_7P446 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.268 +2 -2 + NTP_4_2_7P446 + + packageinfo.sh@1.450 +1 -1 + NTP_4_2_7P446 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.30 +6 -6 + NTP_4_2_7P446 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.30 +2 -2 + NTP_4_2_7P446 + + scripts/calc_tickadj/calc_tickadj.html@1.29 +1 -1 + NTP_4_2_7P446 + + scripts/calc_tickadj/calc_tickadj.man.in@1.29 +6 -6 + NTP_4_2_7P446 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.30 +2 -2 + NTP_4_2_7P446 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.31 +1 -1 + NTP_4_2_7P446 + + scripts/invoke-plot_summary.texi@1.48 +1 -1 + NTP_4_2_7P446 + + scripts/invoke-summary.texi@1.48 +1 -1 + NTP_4_2_7P446 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.257 +1 -1 + NTP_4_2_7P446 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.258 +13 -13 + NTP_4_2_7P446 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.258 +2 -2 + NTP_4_2_7P446 + + scripts/ntp-wait/ntp-wait.html@1.274 +1 -1 + NTP_4_2_7P446 + + scripts/ntp-wait/ntp-wait.man.in@1.258 +13 -13 + NTP_4_2_7P446 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.258 +2 -2 + NTP_4_2_7P446 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.46 +1 -1 + NTP_4_2_7P446 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.37 +6 -6 + NTP_4_2_7P446 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.37 +2 -2 + NTP_4_2_7P446 + + scripts/ntpsweep/ntpsweep.html@1.47 +1 -1 + NTP_4_2_7P446 + + scripts/ntpsweep/ntpsweep.man.in@1.37 +6 -6 + NTP_4_2_7P446 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.38 +2 -2 + NTP_4_2_7P446 + + scripts/ntptrace/invoke-ntptrace.texi@1.46 +1 -1 + NTP_4_2_7P446 + + scripts/ntptrace/ntptrace.1ntptraceman@1.37 +6 -6 + NTP_4_2_7P446 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.37 +2 -2 + NTP_4_2_7P446 + + scripts/ntptrace/ntptrace.html@1.47 +1 -1 + NTP_4_2_7P446 + + scripts/ntptrace/ntptrace.man.in@1.37 +6 -6 + NTP_4_2_7P446 + + scripts/ntptrace/ntptrace.mdoc.in@1.38 +2 -2 + NTP_4_2_7P446 + + scripts/plot_summary.1plot_summaryman@1.48 +6 -6 + NTP_4_2_7P446 + + scripts/plot_summary.1plot_summarymdoc@1.48 +2 -2 + NTP_4_2_7P446 + + scripts/plot_summary.html@1.48 +1 -1 + NTP_4_2_7P446 + + scripts/plot_summary.man.in@1.48 +6 -6 + NTP_4_2_7P446 + + scripts/plot_summary.mdoc.in@1.48 +2 -2 + NTP_4_2_7P446 + + scripts/summary.1summaryman@1.48 +6 -6 + NTP_4_2_7P446 + + scripts/summary.1summarymdoc@1.48 +2 -2 + NTP_4_2_7P446 + + scripts/summary.html@1.48 +1 -1 + NTP_4_2_7P446 + + scripts/summary.man.in@1.48 +6 -6 + NTP_4_2_7P446 + + scripts/summary.mdoc.in@1.48 +2 -2 + NTP_4_2_7P446 + + sntp/invoke-sntp.texi@1.436 +2 -2 + NTP_4_2_7P446 + + sntp/sntp-opts.c@1.451 +7 -7 + NTP_4_2_7P446 + + sntp/sntp-opts.h@1.451 +3 -3 + NTP_4_2_7P446 + + sntp/sntp.1sntpman@1.271 +6 -6 + NTP_4_2_7P446 + + sntp/sntp.1sntpmdoc@1.271 +2 -2 + NTP_4_2_7P446 + + sntp/sntp.html@1.451 +2 -2 + NTP_4_2_7P446 + + sntp/sntp.man.in@1.271 +6 -6 + NTP_4_2_7P446 + + sntp/sntp.mdoc.in@1.271 +2 -2 + NTP_4_2_7P446 + + util/invoke-ntp-keygen.texi@1.440 +2 -2 + NTP_4_2_7P446 + + util/ntp-keygen-opts.c@1.454 +7 -7 + NTP_4_2_7P446 + + util/ntp-keygen-opts.h@1.454 +3 -3 + NTP_4_2_7P446 + + util/ntp-keygen.1ntp-keygenman@1.268 +6 -6 + NTP_4_2_7P446 + + util/ntp-keygen.1ntp-keygenmdoc@1.268 +2 -2 + NTP_4_2_7P446 + + util/ntp-keygen.html@1.116 +2 -2 + NTP_4_2_7P446 + + util/ntp-keygen.man.in@1.268 +6 -6 + NTP_4_2_7P446 + + util/ntp-keygen.mdoc.in@1.268 +2 -2 + NTP_4_2_7P446 + +ChangeSet@1.3134, 2014-06-28 05:00:22-04:00, stenn@deacon.udel.edu + Allow for version suffix in libevent in ntp_libevent.m4 + + ChangeLog@1.1481 +1 -0 + Allow for version suffix in libevent in ntp_libevent.m4 + + sntp/m4/ntp_libevent.m4@1.11 +19 -1 + Allow for version suffix in libevent in ntp_libevent.m4 + +ChangeSet@1.3131.1.4, 2014-06-28 07:48:23+00:00, stenn@psp-fb1.ntp.org + ntp_crypto.c, ChangeLog: + [Bug 2619] Save a signed int copy of the return value of i2d_DSA_SIG(). + Provide missing msyslog() message in crypto_alice(). + + ChangeLog@1.1478.1.3 +2 -0 + [Bug 2619] Save a signed int copy of the return value of i2d_DSA_SIG(). + Provide missing msyslog() message in crypto_alice(). + + ntpd/ntp_crypto.c@1.167 +6 -3 + [Bug 2619] Save a signed int copy of the return value of i2d_DSA_SIG(). + Provide missing msyslog() message in crypto_alice(). + +ChangeSet@1.3131.2.1, 2014-06-28 07:25:32+00:00, stenn@psp-fb1.ntp.org + [Bug 2597] leap file processing -- loose ends + + ChangeLog@1.1478.2.1 +1 -0 + [Bug 2597] leap file processing -- loose ends + + ntpd/ntp_util.c@1.114 +1 -1 + [Bug 2597] leap file processing -- loose ends + +ChangeSet@1.3131.1.2, 2014-06-28 06:27:42+00:00, phk@psp-fb1.ntp.org + ChangeLog: + fix a variable lifetime issue + + ChangeLog@1.1478.1.1 +1 -0 + fix a variable lifetime issue + +ChangeSet@1.3131.1.1, 2014-06-28 06:19:58+00:00, phk@psp-fb1.ntp.org + ntp_crypto.c: + Don't assign stack variables to globals. + + ntpd/ntp_crypto.c@1.166 +1 -1 + Don't assign stack variables to globals. + +ChangeSet@1.3132, 2014-06-20 10:59:35+02:00, jnperlin@hydra.(none) + [Bug 2614] use 'unsigned long' consistently in 'ntp_random.c' to avoid undefined signed int overflow + + ChangeLog@1.1479 +2 -0 + [Bug 2614] use 'unsigned long' consistently in 'ntp_random.c' to avoid undefined signed int overflow + + libntp/ntp_random.c@1.11 +8 -8 + [Bug 2614] use 'unsigned long' consistently in 'ntp_random.c' to avoid undefined signed int overflow + +ChangeSet@1.3131, 2014-06-12 09:34:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P445 + TAG: NTP_4_2_7P445 + + ChangeLog@1.1478 +1 -0 + NTP_4_2_7P445 + + ntpd/invoke-ntp.conf.texi@1.124 +1 -1 + NTP_4_2_7P445 + + ntpd/invoke-ntp.keys.texi@1.122 +1 -1 + NTP_4_2_7P445 + + ntpd/invoke-ntpd.texi@1.438 +2 -2 + NTP_4_2_7P445 + + ntpd/ntp.conf.5man@1.158 +6 -6 + NTP_4_2_7P445 + + ntpd/ntp.conf.5mdoc@1.158 +2 -2 + NTP_4_2_7P445 + + ntpd/ntp.conf.html@1.119 +1 -1 + NTP_4_2_7P445 + + ntpd/ntp.conf.man.in@1.158 +6 -6 + NTP_4_2_7P445 + + ntpd/ntp.conf.mdoc.in@1.158 +2 -2 + NTP_4_2_7P445 + + ntpd/ntp.keys.5man@1.156 +2 -2 + NTP_4_2_7P445 + + ntpd/ntp.keys.5mdoc@1.156 +2 -2 + NTP_4_2_7P445 + + ntpd/ntp.keys.html@1.120 +1 -1 + NTP_4_2_7P445 + + ntpd/ntp.keys.man.in@1.156 +2 -2 + NTP_4_2_7P445 + + ntpd/ntp.keys.mdoc.in@1.156 +2 -2 + NTP_4_2_7P445 + + ntpd/ntpd-opts.c@1.456 +7 -7 + NTP_4_2_7P445 + + ntpd/ntpd-opts.h@1.456 +3 -3 + NTP_4_2_7P445 + + ntpd/ntpd.1ntpdman@1.267 +6 -6 + NTP_4_2_7P445 + + ntpd/ntpd.1ntpdmdoc@1.267 +2 -2 + NTP_4_2_7P445 + + ntpd/ntpd.html@1.114 +2 -2 + NTP_4_2_7P445 + + ntpd/ntpd.man.in@1.267 +6 -6 + NTP_4_2_7P445 + + ntpd/ntpd.mdoc.in@1.267 +2 -2 + NTP_4_2_7P445 + + ntpdc/invoke-ntpdc.texi@1.436 +2 -2 + NTP_4_2_7P445 + + ntpdc/ntpdc-opts.c@1.451 +7 -7 + NTP_4_2_7P445 + + ntpdc/ntpdc-opts.h@1.451 +3 -3 + NTP_4_2_7P445 + + ntpdc/ntpdc.1ntpdcman@1.267 +6 -6 + NTP_4_2_7P445 + + ntpdc/ntpdc.1ntpdcmdoc@1.267 +2 -2 + NTP_4_2_7P445 + + ntpdc/ntpdc.html@1.280 +2 -2 + NTP_4_2_7P445 + + ntpdc/ntpdc.man.in@1.267 +6 -6 + NTP_4_2_7P445 + + ntpdc/ntpdc.mdoc.in@1.267 +2 -2 + NTP_4_2_7P445 + + ntpq/invoke-ntpq.texi@1.440 +3 -3 + NTP_4_2_7P445 + + ntpq/ntpq-opts.c@1.454 +7 -7 + NTP_4_2_7P445 + + ntpq/ntpq-opts.h@1.454 +3 -3 + NTP_4_2_7P445 + + ntpq/ntpq.1ntpqman@1.268 +33 -4 + NTP_4_2_7P445 + + ntpq/ntpq.1ntpqmdoc@1.268 +21 -2 + NTP_4_2_7P445 + + ntpq/ntpq.html@1.111 +359 -2 + NTP_4_2_7P445 + + ntpq/ntpq.man.in@1.268 +33 -4 + NTP_4_2_7P445 + + ntpq/ntpq.mdoc.in@1.268 +21 -2 + NTP_4_2_7P445 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.438 +2 -2 + NTP_4_2_7P445 + + ntpsnmpd/ntpsnmpd-opts.c@1.453 +7 -7 + NTP_4_2_7P445 + + ntpsnmpd/ntpsnmpd-opts.h@1.453 +3 -3 + NTP_4_2_7P445 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.267 +6 -6 + NTP_4_2_7P445 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.267 +2 -2 + NTP_4_2_7P445 + + ntpsnmpd/ntpsnmpd.html@1.109 +1 -1 + NTP_4_2_7P445 + + ntpsnmpd/ntpsnmpd.man.in@1.267 +6 -6 + NTP_4_2_7P445 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.267 +2 -2 + NTP_4_2_7P445 + + packageinfo.sh@1.449 +1 -1 + NTP_4_2_7P445 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.29 +6 -6 + NTP_4_2_7P445 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.29 +2 -2 + NTP_4_2_7P445 + + scripts/calc_tickadj/calc_tickadj.html@1.28 +1 -1 + NTP_4_2_7P445 + + scripts/calc_tickadj/calc_tickadj.man.in@1.28 +6 -6 + NTP_4_2_7P445 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.29 +2 -2 + NTP_4_2_7P445 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.30 +1 -1 + NTP_4_2_7P445 + + scripts/invoke-plot_summary.texi@1.47 +1 -1 + NTP_4_2_7P445 + + scripts/invoke-summary.texi@1.47 +1 -1 + NTP_4_2_7P445 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.256 +1 -1 + NTP_4_2_7P445 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.257 +13 -13 + NTP_4_2_7P445 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.257 +2 -2 + NTP_4_2_7P445 + + scripts/ntp-wait/ntp-wait.html@1.273 +1 -1 + NTP_4_2_7P445 + + scripts/ntp-wait/ntp-wait.man.in@1.257 +13 -13 + NTP_4_2_7P445 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.257 +2 -2 + NTP_4_2_7P445 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.45 +1 -1 + NTP_4_2_7P445 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.36 +6 -6 + NTP_4_2_7P445 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.36 +2 -2 + NTP_4_2_7P445 + + scripts/ntpsweep/ntpsweep.html@1.46 +1 -1 + NTP_4_2_7P445 + + scripts/ntpsweep/ntpsweep.man.in@1.36 +6 -6 + NTP_4_2_7P445 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.37 +2 -2 + NTP_4_2_7P445 + + scripts/ntptrace/invoke-ntptrace.texi@1.45 +1 -1 + NTP_4_2_7P445 + + scripts/ntptrace/ntptrace.1ntptraceman@1.36 +6 -6 + NTP_4_2_7P445 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.36 +2 -2 + NTP_4_2_7P445 + + scripts/ntptrace/ntptrace.html@1.46 +1 -1 + NTP_4_2_7P445 + + scripts/ntptrace/ntptrace.man.in@1.36 +6 -6 + NTP_4_2_7P445 + + scripts/ntptrace/ntptrace.mdoc.in@1.37 +2 -2 + NTP_4_2_7P445 + + scripts/plot_summary.1plot_summaryman@1.47 +6 -6 + NTP_4_2_7P445 + + scripts/plot_summary.1plot_summarymdoc@1.47 +2 -2 + NTP_4_2_7P445 + + scripts/plot_summary.html@1.47 +1 -1 + NTP_4_2_7P445 + + scripts/plot_summary.man.in@1.47 +6 -6 + NTP_4_2_7P445 + + scripts/plot_summary.mdoc.in@1.47 +2 -2 + NTP_4_2_7P445 + + scripts/summary.1summaryman@1.47 +6 -6 + NTP_4_2_7P445 + + scripts/summary.1summarymdoc@1.47 +2 -2 + NTP_4_2_7P445 + + scripts/summary.html@1.47 +1 -1 + NTP_4_2_7P445 + + scripts/summary.man.in@1.47 +6 -6 + NTP_4_2_7P445 + + scripts/summary.mdoc.in@1.47 +2 -2 + NTP_4_2_7P445 + + sntp/invoke-sntp.texi@1.435 +2 -2 + NTP_4_2_7P445 + + sntp/sntp-opts.c@1.450 +7 -7 + NTP_4_2_7P445 + + sntp/sntp-opts.h@1.450 +3 -3 + NTP_4_2_7P445 + + sntp/sntp.1sntpman@1.270 +6 -6 + NTP_4_2_7P445 + + sntp/sntp.1sntpmdoc@1.270 +2 -2 + NTP_4_2_7P445 + + sntp/sntp.html@1.450 +2 -2 + NTP_4_2_7P445 + + sntp/sntp.man.in@1.270 +6 -6 + NTP_4_2_7P445 + + sntp/sntp.mdoc.in@1.270 +2 -2 + NTP_4_2_7P445 + + util/invoke-ntp-keygen.texi@1.439 +2 -2 + NTP_4_2_7P445 + + util/ntp-keygen-opts.c@1.453 +7 -7 + NTP_4_2_7P445 + + util/ntp-keygen-opts.h@1.453 +3 -3 + NTP_4_2_7P445 + + util/ntp-keygen.1ntp-keygenman@1.267 +6 -6 + NTP_4_2_7P445 + + util/ntp-keygen.1ntp-keygenmdoc@1.267 +2 -2 + NTP_4_2_7P445 + + util/ntp-keygen.html@1.115 +2 -2 + NTP_4_2_7P445 + + util/ntp-keygen.man.in@1.267 +6 -6 + NTP_4_2_7P445 + + util/ntp-keygen.mdoc.in@1.267 +2 -2 + NTP_4_2_7P445 + +ChangeSet@1.3130, 2014-06-12 08:47:33+00:00, stenn@psp-fb1.ntp.org + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ChangeLog@1.1477 +1 -0 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/invoke-ntpq.texi@1.439 +491 -1 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/ntpq-opts.c@1.453 +1 -1 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/ntpq-opts.def@1.17 +487 -0 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/ntpq-opts.h@1.453 +1 -1 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/ntpq.1ntpqman@1.267 +839 -32 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/ntpq.1ntpqmdoc@1.267 +479 -21 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/ntpq.man.in@1.267 +839 -32 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + ntpq/ntpq.mdoc.in@1.267 +479 -21 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + sntp/ag-tpl/Mdoc.pm@1.2 +1 -1 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + sntp/ag-tpl/mdoc2man@1.2 +13 -1 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + + sntp/ag-tpl/mdoc2texi@1.9 +12 -0 + [Bug 2556] mrulist isn't mentioned in the ntpq man page + +ChangeSet@1.3129, 2014-05-19 09:34:39+00:00, stenn@deacon.udel.edu + NTP_4_2_7P444 + TAG: NTP_4_2_7P444 + + ChangeLog@1.1476 +1 -0 + NTP_4_2_7P444 + + ntpd/invoke-ntp.conf.texi@1.123 +1 -1 + NTP_4_2_7P444 + + ntpd/invoke-ntp.keys.texi@1.121 +1 -1 + NTP_4_2_7P444 + + ntpd/invoke-ntpd.texi@1.437 +2 -2 + NTP_4_2_7P444 + + ntpd/ntp.conf.5man@1.157 +6 -6 + NTP_4_2_7P444 + + ntpd/ntp.conf.5mdoc@1.157 +2 -2 + NTP_4_2_7P444 + + ntpd/ntp.conf.html@1.118 +1 -1 + NTP_4_2_7P444 + + ntpd/ntp.conf.man.in@1.157 +6 -6 + NTP_4_2_7P444 + + ntpd/ntp.conf.mdoc.in@1.157 +2 -2 + NTP_4_2_7P444 + + ntpd/ntp.keys.5man@1.155 +2 -2 + NTP_4_2_7P444 + + ntpd/ntp.keys.5mdoc@1.155 +2 -2 + NTP_4_2_7P444 + + ntpd/ntp.keys.html@1.119 +1 -1 + NTP_4_2_7P444 + + ntpd/ntp.keys.man.in@1.155 +2 -2 + NTP_4_2_7P444 + + ntpd/ntp.keys.mdoc.in@1.155 +2 -2 + NTP_4_2_7P444 + + ntpd/ntpd-opts.c@1.455 +7 -7 + NTP_4_2_7P444 + + ntpd/ntpd-opts.h@1.455 +3 -3 + NTP_4_2_7P444 + + ntpd/ntpd.1ntpdman@1.266 +6 -6 + NTP_4_2_7P444 + + ntpd/ntpd.1ntpdmdoc@1.266 +2 -2 + NTP_4_2_7P444 + + ntpd/ntpd.html@1.113 +2 -2 + NTP_4_2_7P444 + + ntpd/ntpd.man.in@1.266 +6 -6 + NTP_4_2_7P444 + + ntpd/ntpd.mdoc.in@1.266 +2 -2 + NTP_4_2_7P444 + + ntpdc/invoke-ntpdc.texi@1.435 +2 -2 + NTP_4_2_7P444 + + ntpdc/ntpdc-opts.c@1.450 +7 -7 + NTP_4_2_7P444 + + ntpdc/ntpdc-opts.h@1.450 +3 -3 + NTP_4_2_7P444 + + ntpdc/ntpdc.1ntpdcman@1.266 +6 -6 + NTP_4_2_7P444 + + ntpdc/ntpdc.1ntpdcmdoc@1.266 +2 -2 + NTP_4_2_7P444 + + ntpdc/ntpdc.html@1.279 +2 -2 + NTP_4_2_7P444 + + ntpdc/ntpdc.man.in@1.266 +6 -6 + NTP_4_2_7P444 + + ntpdc/ntpdc.mdoc.in@1.266 +2 -2 + NTP_4_2_7P444 + + ntpq/invoke-ntpq.texi@1.438 +2 -2 + NTP_4_2_7P444 + + ntpq/ntpq-opts.c@1.452 +7 -7 + NTP_4_2_7P444 + + ntpq/ntpq-opts.h@1.452 +3 -3 + NTP_4_2_7P444 + + ntpq/ntpq.1ntpqman@1.266 +13 -13 + NTP_4_2_7P444 + + ntpq/ntpq.1ntpqmdoc@1.266 +2 -2 + NTP_4_2_7P444 + + ntpq/ntpq.html@1.110 +2 -2 + NTP_4_2_7P444 + + ntpq/ntpq.man.in@1.266 +13 -13 + NTP_4_2_7P444 + + ntpq/ntpq.mdoc.in@1.266 +2 -2 + NTP_4_2_7P444 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.437 +2 -2 + NTP_4_2_7P444 + + ntpsnmpd/ntpsnmpd-opts.c@1.452 +7 -7 + NTP_4_2_7P444 + + ntpsnmpd/ntpsnmpd-opts.h@1.452 +3 -3 + NTP_4_2_7P444 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.266 +6 -6 + NTP_4_2_7P444 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.266 +2 -2 + NTP_4_2_7P444 + + ntpsnmpd/ntpsnmpd.html@1.108 +1 -1 + NTP_4_2_7P444 + + ntpsnmpd/ntpsnmpd.man.in@1.266 +6 -6 + NTP_4_2_7P444 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.266 +2 -2 + NTP_4_2_7P444 + + packageinfo.sh@1.448 +1 -1 + NTP_4_2_7P444 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.28 +6 -6 + NTP_4_2_7P444 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.28 +2 -2 + NTP_4_2_7P444 + + scripts/calc_tickadj/calc_tickadj.html@1.27 +1 -1 + NTP_4_2_7P444 + + scripts/calc_tickadj/calc_tickadj.man.in@1.27 +6 -6 + NTP_4_2_7P444 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.28 +2 -2 + NTP_4_2_7P444 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.29 +1 -1 + NTP_4_2_7P444 + + scripts/invoke-plot_summary.texi@1.46 +1 -1 + NTP_4_2_7P444 + + scripts/invoke-summary.texi@1.46 +1 -1 + NTP_4_2_7P444 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.255 +1 -1 + NTP_4_2_7P444 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.256 +6 -6 + NTP_4_2_7P444 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.256 +2 -2 + NTP_4_2_7P444 + + scripts/ntp-wait/ntp-wait.html@1.272 +1 -1 + NTP_4_2_7P444 + + scripts/ntp-wait/ntp-wait.man.in@1.256 +6 -6 + NTP_4_2_7P444 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.256 +2 -2 + NTP_4_2_7P444 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.44 +1 -1 + NTP_4_2_7P444 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.35 +6 -6 + NTP_4_2_7P444 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.35 +2 -2 + NTP_4_2_7P444 + + scripts/ntpsweep/ntpsweep.html@1.45 +1 -1 + NTP_4_2_7P444 + + scripts/ntpsweep/ntpsweep.man.in@1.35 +6 -6 + NTP_4_2_7P444 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.36 +2 -2 + NTP_4_2_7P444 + + scripts/ntptrace/invoke-ntptrace.texi@1.44 +1 -1 + NTP_4_2_7P444 + + scripts/ntptrace/ntptrace.1ntptraceman@1.35 +6 -6 + NTP_4_2_7P444 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.35 +2 -2 + NTP_4_2_7P444 + + scripts/ntptrace/ntptrace.html@1.45 +1 -1 + NTP_4_2_7P444 + + scripts/ntptrace/ntptrace.man.in@1.35 +6 -6 + NTP_4_2_7P444 + + scripts/ntptrace/ntptrace.mdoc.in@1.36 +2 -2 + NTP_4_2_7P444 + + scripts/plot_summary.1plot_summaryman@1.46 +6 -6 + NTP_4_2_7P444 + + scripts/plot_summary.1plot_summarymdoc@1.46 +2 -2 + NTP_4_2_7P444 + + scripts/plot_summary.html@1.46 +1 -1 + NTP_4_2_7P444 + + scripts/plot_summary.man.in@1.46 +6 -6 + NTP_4_2_7P444 + + scripts/plot_summary.mdoc.in@1.46 +2 -2 + NTP_4_2_7P444 + + scripts/summary.1summaryman@1.46 +6 -6 + NTP_4_2_7P444 + + scripts/summary.1summarymdoc@1.46 +2 -2 + NTP_4_2_7P444 + + scripts/summary.html@1.46 +1 -1 + NTP_4_2_7P444 + + scripts/summary.man.in@1.46 +6 -6 + NTP_4_2_7P444 + + scripts/summary.mdoc.in@1.46 +2 -2 + NTP_4_2_7P444 + + sntp/invoke-sntp.texi@1.434 +2 -2 + NTP_4_2_7P444 + + sntp/sntp-opts.c@1.449 +7 -7 + NTP_4_2_7P444 + + sntp/sntp-opts.h@1.449 +3 -3 + NTP_4_2_7P444 + + sntp/sntp.1sntpman@1.269 +6 -6 + NTP_4_2_7P444 + + sntp/sntp.1sntpmdoc@1.269 +2 -2 + NTP_4_2_7P444 + + sntp/sntp.html@1.449 +2 -2 + NTP_4_2_7P444 + + sntp/sntp.man.in@1.269 +6 -6 + NTP_4_2_7P444 + + sntp/sntp.mdoc.in@1.269 +2 -2 + NTP_4_2_7P444 + + util/invoke-ntp-keygen.texi@1.438 +2 -2 + NTP_4_2_7P444 + + util/ntp-keygen-opts.c@1.452 +7 -7 + NTP_4_2_7P444 + + util/ntp-keygen-opts.h@1.452 +3 -3 + NTP_4_2_7P444 + + util/ntp-keygen.1ntp-keygenman@1.266 +6 -6 + NTP_4_2_7P444 + + util/ntp-keygen.1ntp-keygenmdoc@1.266 +2 -2 + NTP_4_2_7P444 + + util/ntp-keygen.html@1.114 +2 -2 + NTP_4_2_7P444 + + util/ntp-keygen.man.in@1.266 +6 -6 + NTP_4_2_7P444 + + util/ntp-keygen.mdoc.in@1.266 +2 -2 + NTP_4_2_7P444 + +ChangeSet@1.3127, 2014-05-10 09:33:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P443 + TAG: NTP_4_2_7P443 + + ChangeLog@1.1473.1.6 +1 -0 + NTP_4_2_7P443 + + ntpd/invoke-ntp.conf.texi@1.122 +1 -1 + NTP_4_2_7P443 + + ntpd/invoke-ntp.keys.texi@1.120 +1 -1 + NTP_4_2_7P443 + + ntpd/invoke-ntpd.texi@1.436 +2 -2 + NTP_4_2_7P443 + + ntpd/ntp.conf.5man@1.156 +7 -7 + NTP_4_2_7P443 + + ntpd/ntp.conf.5mdoc@1.156 +3 -3 + NTP_4_2_7P443 + + ntpd/ntp.conf.html@1.117 +1 -1 + NTP_4_2_7P443 + + ntpd/ntp.conf.man.in@1.156 +7 -7 + NTP_4_2_7P443 + + ntpd/ntp.conf.mdoc.in@1.156 +3 -3 + NTP_4_2_7P443 + + ntpd/ntp.keys.5man@1.154 +3 -3 + NTP_4_2_7P443 + + ntpd/ntp.keys.5mdoc@1.154 +3 -3 + NTP_4_2_7P443 + + ntpd/ntp.keys.html@1.118 +1 -1 + NTP_4_2_7P443 + + ntpd/ntp.keys.man.in@1.154 +3 -3 + NTP_4_2_7P443 + + ntpd/ntp.keys.mdoc.in@1.154 +3 -3 + NTP_4_2_7P443 + + ntpd/ntpd-opts.c@1.454 +10 -10 + NTP_4_2_7P443 + + ntpd/ntpd-opts.h@1.454 +4 -4 + NTP_4_2_7P443 + + ntpd/ntpd.1ntpdman@1.265 +7 -7 + NTP_4_2_7P443 + + ntpd/ntpd.1ntpdmdoc@1.265 +3 -3 + NTP_4_2_7P443 + + ntpd/ntpd.html@1.112 +2 -2 + NTP_4_2_7P443 + + ntpd/ntpd.man.in@1.265 +7 -7 + NTP_4_2_7P443 + + ntpd/ntpd.mdoc.in@1.265 +3 -3 + NTP_4_2_7P443 + + ntpdc/invoke-ntpdc.texi@1.434 +2 -2 + NTP_4_2_7P443 + + ntpdc/ntpdc-opts.c@1.449 +10 -10 + NTP_4_2_7P443 + + ntpdc/ntpdc-opts.h@1.449 +4 -4 + NTP_4_2_7P443 + + ntpdc/ntpdc.1ntpdcman@1.265 +14 -14 + NTP_4_2_7P443 + + ntpdc/ntpdc.1ntpdcmdoc@1.265 +3 -3 + NTP_4_2_7P443 + + ntpdc/ntpdc.html@1.278 +2 -2 + NTP_4_2_7P443 + + ntpdc/ntpdc.man.in@1.265 +14 -14 + NTP_4_2_7P443 + + ntpdc/ntpdc.mdoc.in@1.265 +3 -3 + NTP_4_2_7P443 + + ntpq/invoke-ntpq.texi@1.437 +2 -2 + NTP_4_2_7P443 + + ntpq/ntpq-opts.c@1.451 +10 -10 + NTP_4_2_7P443 + + ntpq/ntpq-opts.h@1.451 +4 -4 + NTP_4_2_7P443 + + ntpq/ntpq.1ntpqman@1.265 +7 -7 + NTP_4_2_7P443 + + ntpq/ntpq.1ntpqmdoc@1.265 +3 -3 + NTP_4_2_7P443 + + ntpq/ntpq.html@1.109 +2 -2 + NTP_4_2_7P443 + + ntpq/ntpq.man.in@1.265 +7 -7 + NTP_4_2_7P443 + + ntpq/ntpq.mdoc.in@1.265 +3 -3 + NTP_4_2_7P443 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.436 +2 -2 + NTP_4_2_7P443 + + ntpsnmpd/ntpsnmpd-opts.c@1.451 +10 -10 + NTP_4_2_7P443 + + ntpsnmpd/ntpsnmpd-opts.h@1.451 +4 -4 + NTP_4_2_7P443 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.265 +7 -7 + NTP_4_2_7P443 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.265 +3 -3 + NTP_4_2_7P443 + + ntpsnmpd/ntpsnmpd.html@1.107 +1 -1 + NTP_4_2_7P443 + + ntpsnmpd/ntpsnmpd.man.in@1.265 +7 -7 + NTP_4_2_7P443 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.265 +3 -3 + NTP_4_2_7P443 + + packageinfo.sh@1.447 +1 -1 + NTP_4_2_7P443 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.27 +6 -6 + NTP_4_2_7P443 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.27 +2 -2 + NTP_4_2_7P443 + + scripts/calc_tickadj/calc_tickadj.html@1.26 +1 -1 + NTP_4_2_7P443 + + scripts/calc_tickadj/calc_tickadj.man.in@1.26 +6 -6 + NTP_4_2_7P443 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.27 +2 -2 + NTP_4_2_7P443 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.28 +1 -1 + NTP_4_2_7P443 + + scripts/invoke-plot_summary.texi@1.45 +1 -1 + NTP_4_2_7P443 + + scripts/invoke-summary.texi@1.45 +1 -1 + NTP_4_2_7P443 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.254 +1 -1 + NTP_4_2_7P443 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.255 +6 -6 + NTP_4_2_7P443 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.255 +2 -2 + NTP_4_2_7P443 + + scripts/ntp-wait/ntp-wait.html@1.271 +1 -1 + NTP_4_2_7P443 + + scripts/ntp-wait/ntp-wait.man.in@1.255 +6 -6 + NTP_4_2_7P443 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.255 +2 -2 + NTP_4_2_7P443 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.43 +1 -1 + NTP_4_2_7P443 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.34 +6 -6 + NTP_4_2_7P443 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.34 +2 -2 + NTP_4_2_7P443 + + scripts/ntpsweep/ntpsweep.html@1.44 +1 -1 + NTP_4_2_7P443 + + scripts/ntpsweep/ntpsweep.man.in@1.34 +6 -6 + NTP_4_2_7P443 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.35 +2 -2 + NTP_4_2_7P443 + + scripts/ntptrace/invoke-ntptrace.texi@1.43 +1 -1 + NTP_4_2_7P443 + + scripts/ntptrace/ntptrace.1ntptraceman@1.34 +6 -6 + NTP_4_2_7P443 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.34 +2 -2 + NTP_4_2_7P443 + + scripts/ntptrace/ntptrace.html@1.44 +1 -1 + NTP_4_2_7P443 + + scripts/ntptrace/ntptrace.man.in@1.34 +6 -6 + NTP_4_2_7P443 + + scripts/ntptrace/ntptrace.mdoc.in@1.35 +2 -2 + NTP_4_2_7P443 + + scripts/plot_summary.1plot_summaryman@1.45 +6 -6 + NTP_4_2_7P443 + + scripts/plot_summary.1plot_summarymdoc@1.45 +2 -2 + NTP_4_2_7P443 + + scripts/plot_summary.html@1.45 +1 -1 + NTP_4_2_7P443 + + scripts/plot_summary.man.in@1.45 +6 -6 + NTP_4_2_7P443 + + scripts/plot_summary.mdoc.in@1.45 +2 -2 + NTP_4_2_7P443 + + scripts/summary.1summaryman@1.45 +6 -6 + NTP_4_2_7P443 + + scripts/summary.1summarymdoc@1.45 +2 -2 + NTP_4_2_7P443 + + scripts/summary.html@1.45 +1 -1 + NTP_4_2_7P443 + + scripts/summary.man.in@1.45 +6 -6 + NTP_4_2_7P443 + + scripts/summary.mdoc.in@1.45 +2 -2 + NTP_4_2_7P443 + + sntp/invoke-sntp.texi@1.433 +2 -2 + NTP_4_2_7P443 + + sntp/sntp-opts.c@1.448 +10 -10 + NTP_4_2_7P443 + + sntp/sntp-opts.h@1.448 +4 -4 + NTP_4_2_7P443 + + sntp/sntp.1sntpman@1.268 +7 -7 + NTP_4_2_7P443 + + sntp/sntp.1sntpmdoc@1.268 +3 -3 + NTP_4_2_7P443 + + sntp/sntp.html@1.448 +2 -2 + NTP_4_2_7P443 + + sntp/sntp.man.in@1.268 +7 -7 + NTP_4_2_7P443 + + sntp/sntp.mdoc.in@1.268 +3 -3 + NTP_4_2_7P443 + + util/invoke-ntp-keygen.texi@1.437 +2 -2 + NTP_4_2_7P443 + + util/ntp-keygen-opts.c@1.451 +10 -10 + NTP_4_2_7P443 + + util/ntp-keygen-opts.h@1.451 +4 -4 + NTP_4_2_7P443 + + util/ntp-keygen.1ntp-keygenman@1.265 +7 -7 + NTP_4_2_7P443 + + util/ntp-keygen.1ntp-keygenmdoc@1.265 +3 -3 + NTP_4_2_7P443 + + util/ntp-keygen.html@1.113 +2 -2 + NTP_4_2_7P443 + + util/ntp-keygen.man.in@1.265 +7 -7 + NTP_4_2_7P443 + + util/ntp-keygen.mdoc.in@1.265 +3 -3 + NTP_4_2_7P443 + +ChangeSet@1.3126, 2014-05-09 21:52:34+00:00, stenn@psp-fb1.ntp.org + [Bug 2594] Update the year in sntp/include/copyright.def + + ChangeLog@1.1473.1.5 +1 -1 + [Bug 2594] Update the year in sntp/include/copyright.def + +ChangeSet@1.3123.1.1, 2014-05-09 09:34:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P442 + TAG: NTP_4_2_7P442 + + ChangeLog@1.1473.2.1 +1 -0 + NTP_4_2_7P442 + + ntpd/invoke-ntp.conf.texi@1.121 +1 -1 + NTP_4_2_7P442 + + ntpd/invoke-ntp.keys.texi@1.119 +1 -1 + NTP_4_2_7P442 + + ntpd/invoke-ntpd.texi@1.435 +2 -2 + NTP_4_2_7P442 + + ntpd/ntp.conf.5man@1.155 +6 -6 + NTP_4_2_7P442 + + ntpd/ntp.conf.5mdoc@1.155 +2 -2 + NTP_4_2_7P442 + + ntpd/ntp.conf.html@1.116 +1 -1 + NTP_4_2_7P442 + + ntpd/ntp.conf.man.in@1.155 +6 -6 + NTP_4_2_7P442 + + ntpd/ntp.conf.mdoc.in@1.155 +2 -2 + NTP_4_2_7P442 + + ntpd/ntp.keys.5man@1.153 +2 -2 + NTP_4_2_7P442 + + ntpd/ntp.keys.5mdoc@1.153 +2 -2 + NTP_4_2_7P442 + + ntpd/ntp.keys.html@1.117 +1 -1 + NTP_4_2_7P442 + + ntpd/ntp.keys.man.in@1.153 +2 -2 + NTP_4_2_7P442 + + ntpd/ntp.keys.mdoc.in@1.153 +2 -2 + NTP_4_2_7P442 + + ntpd/ntpd-opts.c@1.453 +7 -7 + NTP_4_2_7P442 + + ntpd/ntpd-opts.h@1.453 +3 -3 + NTP_4_2_7P442 + + ntpd/ntpd.1ntpdman@1.264 +13 -13 + NTP_4_2_7P442 + + ntpd/ntpd.1ntpdmdoc@1.264 +2 -2 + NTP_4_2_7P442 + + ntpd/ntpd.html@1.111 +2 -2 + NTP_4_2_7P442 + + ntpd/ntpd.man.in@1.264 +13 -13 + NTP_4_2_7P442 + + ntpd/ntpd.mdoc.in@1.264 +2 -2 + NTP_4_2_7P442 + + ntpdc/invoke-ntpdc.texi@1.433 +2 -2 + NTP_4_2_7P442 + + ntpdc/ntpdc-opts.c@1.448 +7 -7 + NTP_4_2_7P442 + + ntpdc/ntpdc-opts.h@1.448 +3 -3 + NTP_4_2_7P442 + + ntpdc/ntpdc.1ntpdcman@1.264 +13 -13 + NTP_4_2_7P442 + + ntpdc/ntpdc.1ntpdcmdoc@1.264 +2 -2 + NTP_4_2_7P442 + + ntpdc/ntpdc.html@1.277 +2 -2 + NTP_4_2_7P442 + + ntpdc/ntpdc.man.in@1.264 +13 -13 + NTP_4_2_7P442 + + ntpdc/ntpdc.mdoc.in@1.264 +2 -2 + NTP_4_2_7P442 + + ntpq/invoke-ntpq.texi@1.436 +2 -2 + NTP_4_2_7P442 + + ntpq/ntpq-opts.c@1.450 +7 -7 + NTP_4_2_7P442 + + ntpq/ntpq-opts.h@1.450 +3 -3 + NTP_4_2_7P442 + + ntpq/ntpq.1ntpqman@1.264 +6 -6 + NTP_4_2_7P442 + + ntpq/ntpq.1ntpqmdoc@1.264 +2 -2 + NTP_4_2_7P442 + + ntpq/ntpq.html@1.108 +2 -2 + NTP_4_2_7P442 + + ntpq/ntpq.man.in@1.264 +6 -6 + NTP_4_2_7P442 + + ntpq/ntpq.mdoc.in@1.264 +2 -2 + NTP_4_2_7P442 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.435 +2 -2 + NTP_4_2_7P442 + + ntpsnmpd/ntpsnmpd-opts.c@1.450 +7 -7 + NTP_4_2_7P442 + + ntpsnmpd/ntpsnmpd-opts.h@1.450 +3 -3 + NTP_4_2_7P442 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.264 +6 -6 + NTP_4_2_7P442 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.264 +2 -2 + NTP_4_2_7P442 + + ntpsnmpd/ntpsnmpd.html@1.106 +1 -1 + NTP_4_2_7P442 + + ntpsnmpd/ntpsnmpd.man.in@1.264 +6 -6 + NTP_4_2_7P442 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.264 +2 -2 + NTP_4_2_7P442 + + packageinfo.sh@1.446 +1 -1 + NTP_4_2_7P442 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.26 +6 -6 + NTP_4_2_7P442 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.26 +2 -2 + NTP_4_2_7P442 + + scripts/calc_tickadj/calc_tickadj.html@1.25 +1 -1 + NTP_4_2_7P442 + + scripts/calc_tickadj/calc_tickadj.man.in@1.25 +6 -6 + NTP_4_2_7P442 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.26 +2 -2 + NTP_4_2_7P442 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.27 +1 -1 + NTP_4_2_7P442 + + scripts/invoke-plot_summary.texi@1.44 +1 -1 + NTP_4_2_7P442 + + scripts/invoke-summary.texi@1.44 +1 -1 + NTP_4_2_7P442 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.253 +1 -1 + NTP_4_2_7P442 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.254 +6 -6 + NTP_4_2_7P442 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.254 +2 -2 + NTP_4_2_7P442 + + scripts/ntp-wait/ntp-wait.html@1.270 +1 -1 + NTP_4_2_7P442 + + scripts/ntp-wait/ntp-wait.man.in@1.254 +6 -6 + NTP_4_2_7P442 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.254 +2 -2 + NTP_4_2_7P442 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.42 +1 -1 + NTP_4_2_7P442 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.33 +6 -6 + NTP_4_2_7P442 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.33 +2 -2 + NTP_4_2_7P442 + + scripts/ntpsweep/ntpsweep.html@1.43 +1 -1 + NTP_4_2_7P442 + + scripts/ntpsweep/ntpsweep.man.in@1.33 +6 -6 + NTP_4_2_7P442 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.34 +2 -2 + NTP_4_2_7P442 + + scripts/ntptrace/invoke-ntptrace.texi@1.42 +1 -1 + NTP_4_2_7P442 + + scripts/ntptrace/ntptrace.1ntptraceman@1.33 +6 -6 + NTP_4_2_7P442 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.33 +2 -2 + NTP_4_2_7P442 + + scripts/ntptrace/ntptrace.html@1.43 +1 -1 + NTP_4_2_7P442 + + scripts/ntptrace/ntptrace.man.in@1.33 +6 -6 + NTP_4_2_7P442 + + scripts/ntptrace/ntptrace.mdoc.in@1.34 +2 -2 + NTP_4_2_7P442 + + scripts/plot_summary.1plot_summaryman@1.44 +6 -6 + NTP_4_2_7P442 + + scripts/plot_summary.1plot_summarymdoc@1.44 +2 -2 + NTP_4_2_7P442 + + scripts/plot_summary.html@1.44 +1 -1 + NTP_4_2_7P442 + + scripts/plot_summary.man.in@1.44 +6 -6 + NTP_4_2_7P442 + + scripts/plot_summary.mdoc.in@1.44 +2 -2 + NTP_4_2_7P442 + + scripts/summary.1summaryman@1.44 +6 -6 + NTP_4_2_7P442 + + scripts/summary.1summarymdoc@1.44 +2 -2 + NTP_4_2_7P442 + + scripts/summary.html@1.44 +1 -1 + NTP_4_2_7P442 + + scripts/summary.man.in@1.44 +6 -6 + NTP_4_2_7P442 + + scripts/summary.mdoc.in@1.44 +2 -2 + NTP_4_2_7P442 + + sntp/invoke-sntp.texi@1.432 +2 -2 + NTP_4_2_7P442 + + sntp/sntp-opts.c@1.447 +7 -7 + NTP_4_2_7P442 + + sntp/sntp-opts.h@1.447 +3 -3 + NTP_4_2_7P442 + + sntp/sntp.1sntpman@1.267 +6 -6 + NTP_4_2_7P442 + + sntp/sntp.1sntpmdoc@1.267 +2 -2 + NTP_4_2_7P442 + + sntp/sntp.html@1.447 +2 -2 + NTP_4_2_7P442 + + sntp/sntp.man.in@1.267 +6 -6 + NTP_4_2_7P442 + + sntp/sntp.mdoc.in@1.267 +2 -2 + NTP_4_2_7P442 + + util/invoke-ntp-keygen.texi@1.436 +2 -2 + NTP_4_2_7P442 + + util/ntp-keygen-opts.c@1.450 +7 -7 + NTP_4_2_7P442 + + util/ntp-keygen-opts.h@1.450 +3 -3 + NTP_4_2_7P442 + + util/ntp-keygen.1ntp-keygenman@1.264 +6 -6 + NTP_4_2_7P442 + + util/ntp-keygen.1ntp-keygenmdoc@1.264 +2 -2 + NTP_4_2_7P442 + + util/ntp-keygen.html@1.112 +2 -2 + NTP_4_2_7P442 + + util/ntp-keygen.man.in@1.264 +6 -6 + NTP_4_2_7P442 + + util/ntp-keygen.mdoc.in@1.264 +2 -2 + NTP_4_2_7P442 + +ChangeSet@1.3124, 2014-05-09 01:54:22-07:00, harlan@hms-mbp11.local + [Bug 2594] Update the year in sntp/include/copyright.def + + ChangeLog@1.1473.1.3 +1 -0 + [Bug 2594] Update the year in sntp/include/copyright.def + + sntp/include/copyright.def@1.24 +1 -1 + [Bug 2594] Update the year in sntp/include/copyright.def + +ChangeSet@1.3123, 2014-05-09 01:32:31-07:00, harlan@hms-mbp11.local + turn off the SCCS flag in extern.html + + html/extern.html@1.20 +0 -0 + Turn off SCCS flag + +ChangeSet@1.3122, 2014-05-08 23:29:15-07:00, harlan@hms-mbp11.local + [Bug 2600] Fix "Undisicplined Local Clock" driver1.html page + + ChangeLog@1.1473.1.2 +1 -0 + [Bug 2600] Fix "Undisicplined Local Clock" driver1.html page + + html/drivers/driver1.html@1.21 +3 -3 + [Bug 2600] Fix "Undisicplined Local Clock" driver1.html page + +ChangeSet@1.3121, 2014-05-08 23:07:27-07:00, harlan@hms-mbp11.local + [Bug 2589] Update VS2013 project files for libntp + + ChangeLog@1.1473.1.1 +1 -0 + [Bug 2589] Update VS2013 project files for libntp + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.4 +2 -0 + [Bug 2589] Update VS2013 project files for libntp + + ports/winnt/vs2013/libntp/libntp.vcxproj.filters@1.3 +6 -0 + [Bug 2589] Update VS2013 project files for libntp + +ChangeSet@1.3107.1.41, 2014-05-06 00:48:08+02:00, jnperlin@hydra.(none) + [bug 2597] leap second loose ends -- coverity issues + + ChangeLog@1.1474 +2 -0 + [bug 2597] leap second loose ends -- coverity issues + + ntpd/ntp_leapsec.c@1.12 +17 -1 + [bug 2597] leap second loose ends -- coverity issues + + ntpd/ntp_util.c@1.113 +4 -4 + [bug 2597] leap second loose ends -- coverity issues + +ChangeSet@1.3107.1.40, 2014-05-04 06:10:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P441 + TAG: NTP_4_2_7P441 + + ChangeLog@1.1473 +1 -0 + NTP_4_2_7P441 + + ntpd/invoke-ntp.conf.texi@1.120 +1 -1 + NTP_4_2_7P441 + + ntpd/invoke-ntp.keys.texi@1.118 +1 -1 + NTP_4_2_7P441 + + ntpd/invoke-ntpd.texi@1.434 +2 -2 + NTP_4_2_7P441 + + ntpd/ntp.conf.5man@1.154 +3019 -0 + NTP_4_2_7P441 + + ntpd/ntp.conf.5mdoc@1.154 +2 -2 + NTP_4_2_7P441 + + ntpd/ntp.conf.html@1.115 +1 -1 + NTP_4_2_7P441 + + ntpd/ntp.conf.man.in@1.154 +3019 -0 + NTP_4_2_7P441 + + ntpd/ntp.conf.mdoc.in@1.154 +2 -2 + NTP_4_2_7P441 + + ntpd/ntp.keys.5man@1.152 +2 -2 + NTP_4_2_7P441 + + ntpd/ntp.keys.5mdoc@1.152 +2 -2 + NTP_4_2_7P441 + + ntpd/ntp.keys.html@1.116 +1 -1 + NTP_4_2_7P441 + + ntpd/ntp.keys.man.in@1.152 +2 -2 + NTP_4_2_7P441 + + ntpd/ntp.keys.mdoc.in@1.152 +2 -2 + NTP_4_2_7P441 + + ntpd/ntpd-opts.c@1.452 +7 -7 + NTP_4_2_7P441 + + ntpd/ntpd-opts.h@1.452 +3 -3 + NTP_4_2_7P441 + + ntpd/ntpd.1ntpdman@1.263 +13 -13 + NTP_4_2_7P441 + + ntpd/ntpd.1ntpdmdoc@1.263 +2 -2 + NTP_4_2_7P441 + + ntpd/ntpd.html@1.110 +2 -2 + NTP_4_2_7P441 + + ntpd/ntpd.man.in@1.263 +13 -13 + NTP_4_2_7P441 + + ntpd/ntpd.mdoc.in@1.263 +2 -2 + NTP_4_2_7P441 + + ntpdc/invoke-ntpdc.texi@1.432 +2 -2 + NTP_4_2_7P441 + + ntpdc/ntpdc-opts.c@1.447 +7 -7 + NTP_4_2_7P441 + + ntpdc/ntpdc-opts.h@1.447 +3 -3 + NTP_4_2_7P441 + + ntpdc/ntpdc.1ntpdcman@1.263 +6 -6 + NTP_4_2_7P441 + + ntpdc/ntpdc.1ntpdcmdoc@1.263 +2 -2 + NTP_4_2_7P441 + + ntpdc/ntpdc.html@1.276 +2 -2 + NTP_4_2_7P441 + + ntpdc/ntpdc.man.in@1.263 +6 -6 + NTP_4_2_7P441 + + ntpdc/ntpdc.mdoc.in@1.263 +2 -2 + NTP_4_2_7P441 + + ntpq/invoke-ntpq.texi@1.435 +2 -2 + NTP_4_2_7P441 + + ntpq/ntpq-opts.c@1.449 +7 -7 + NTP_4_2_7P441 + + ntpq/ntpq-opts.h@1.449 +3 -3 + NTP_4_2_7P441 + + ntpq/ntpq.1ntpqman@1.263 +13 -13 + NTP_4_2_7P441 + + ntpq/ntpq.1ntpqmdoc@1.263 +2 -2 + NTP_4_2_7P441 + + ntpq/ntpq.html@1.107 +2 -2 + NTP_4_2_7P441 + + ntpq/ntpq.man.in@1.263 +13 -13 + NTP_4_2_7P441 + + ntpq/ntpq.mdoc.in@1.263 +2 -2 + NTP_4_2_7P441 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.434 +2 -2 + NTP_4_2_7P441 + + ntpsnmpd/ntpsnmpd-opts.c@1.449 +7 -7 + NTP_4_2_7P441 + + ntpsnmpd/ntpsnmpd-opts.h@1.449 +3 -3 + NTP_4_2_7P441 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.263 +6 -6 + NTP_4_2_7P441 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.263 +2 -2 + NTP_4_2_7P441 + + ntpsnmpd/ntpsnmpd.html@1.105 +1 -1 + NTP_4_2_7P441 + + ntpsnmpd/ntpsnmpd.man.in@1.263 +6 -6 + NTP_4_2_7P441 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.263 +2 -2 + NTP_4_2_7P441 + + packageinfo.sh@1.445 +1 -1 + NTP_4_2_7P441 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.25 +6 -6 + NTP_4_2_7P441 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.25 +2 -2 + NTP_4_2_7P441 + + scripts/calc_tickadj/calc_tickadj.html@1.24 +1 -1 + NTP_4_2_7P441 + + scripts/calc_tickadj/calc_tickadj.man.in@1.24 +6 -6 + NTP_4_2_7P441 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.25 +2 -2 + NTP_4_2_7P441 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.26 +1 -1 + NTP_4_2_7P441 + + scripts/invoke-plot_summary.texi@1.43 +1 -1 + NTP_4_2_7P441 + + scripts/invoke-summary.texi@1.43 +1 -1 + NTP_4_2_7P441 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.252 +1 -1 + NTP_4_2_7P441 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.253 +6 -6 + NTP_4_2_7P441 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.253 +2 -2 + NTP_4_2_7P441 + + scripts/ntp-wait/ntp-wait.html@1.269 +1 -1 + NTP_4_2_7P441 + + scripts/ntp-wait/ntp-wait.man.in@1.253 +6 -6 + NTP_4_2_7P441 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.253 +2 -2 + NTP_4_2_7P441 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.41 +1 -1 + NTP_4_2_7P441 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.32 +6 -6 + NTP_4_2_7P441 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.32 +2 -2 + NTP_4_2_7P441 + + scripts/ntpsweep/ntpsweep.html@1.42 +1 -1 + NTP_4_2_7P441 + + scripts/ntpsweep/ntpsweep.man.in@1.32 +6 -6 + NTP_4_2_7P441 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.33 +2 -2 + NTP_4_2_7P441 + + scripts/ntptrace/invoke-ntptrace.texi@1.41 +1 -1 + NTP_4_2_7P441 + + scripts/ntptrace/ntptrace.1ntptraceman@1.32 +6 -6 + NTP_4_2_7P441 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.32 +2 -2 + NTP_4_2_7P441 + + scripts/ntptrace/ntptrace.html@1.42 +1 -1 + NTP_4_2_7P441 + + scripts/ntptrace/ntptrace.man.in@1.32 +6 -6 + NTP_4_2_7P441 + + scripts/ntptrace/ntptrace.mdoc.in@1.33 +2 -2 + NTP_4_2_7P441 + + scripts/plot_summary.1plot_summaryman@1.43 +6 -6 + NTP_4_2_7P441 + + scripts/plot_summary.1plot_summarymdoc@1.43 +2 -2 + NTP_4_2_7P441 + + scripts/plot_summary.html@1.43 +1 -1 + NTP_4_2_7P441 + + scripts/plot_summary.man.in@1.43 +6 -6 + NTP_4_2_7P441 + + scripts/plot_summary.mdoc.in@1.43 +2 -2 + NTP_4_2_7P441 + + scripts/summary.1summaryman@1.43 +6 -6 + NTP_4_2_7P441 + + scripts/summary.1summarymdoc@1.43 +2 -2 + NTP_4_2_7P441 + + scripts/summary.html@1.43 +1 -1 + NTP_4_2_7P441 + + scripts/summary.man.in@1.43 +6 -6 + NTP_4_2_7P441 + + scripts/summary.mdoc.in@1.43 +2 -2 + NTP_4_2_7P441 + + sntp/invoke-sntp.texi@1.431 +2 -2 + NTP_4_2_7P441 + + sntp/sntp-opts.c@1.446 +7 -7 + NTP_4_2_7P441 + + sntp/sntp-opts.h@1.446 +3 -3 + NTP_4_2_7P441 + + sntp/sntp.1sntpman@1.266 +6 -6 + NTP_4_2_7P441 + + sntp/sntp.1sntpmdoc@1.266 +2 -2 + NTP_4_2_7P441 + + sntp/sntp.html@1.446 +2 -2 + NTP_4_2_7P441 + + sntp/sntp.man.in@1.266 +6 -6 + NTP_4_2_7P441 + + sntp/sntp.mdoc.in@1.266 +2 -2 + NTP_4_2_7P441 + + util/invoke-ntp-keygen.texi@1.435 +2 -2 + NTP_4_2_7P441 + + util/ntp-keygen-opts.c@1.449 +7 -7 + NTP_4_2_7P441 + + util/ntp-keygen-opts.h@1.449 +3 -3 + NTP_4_2_7P441 + + util/ntp-keygen.1ntp-keygenman@1.263 +6 -6 + NTP_4_2_7P441 + + util/ntp-keygen.1ntp-keygenmdoc@1.263 +2 -2 + NTP_4_2_7P441 + + util/ntp-keygen.html@1.111 +2 -2 + NTP_4_2_7P441 + + util/ntp-keygen.man.in@1.263 +6 -6 + NTP_4_2_7P441 + + util/ntp-keygen.mdoc.in@1.263 +2 -2 + NTP_4_2_7P441 + +ChangeSet@1.3107.1.39, 2014-05-04 04:51:37+00:00, stenn@psp-deb1.ntp.org + nits + + ntpd/ntp_leapsec.c@1.11 +9 -7 + nits + + ntpd/ntp_util.c@1.112 +2 -2 + nits + +ChangeSet@1.3107.1.38, 2014-04-22 21:40:54+02:00, jnperlin@hydra.(none) + [Bug 2597] fixed loose ends: changed/unified logging for leapfile related actions + + ChangeLog@1.1472 +4 -0 + [Bug 2597] changed/unified logging for leapfile related actions + + include/ntpd.h@1.182 +1 -1 + [Bug 2597] changed/unified logging for leapfile related actions + changed signature for 'check_leap_file()' + + ntpd/ntp_leapsec.c@1.10 +83 -7 + [Bug 2597] changed/unified logging for leapfile related actions + split functionality between 'leapsec_load_file()' and 'leapsec_load_stream()' + improve logging for non-existing and successfully loaded files + + ntpd/ntp_leapsec.h@1.7 +17 -4 + [Bug 2597] changed/unified logging for leapfile related actions + split functionality between 'leapsec_load_file()' and 'leapsec_load_stream()' + + ntpd/ntp_timer.c@1.81 +5 -26 + [Bug 2597] changed/unified logging for leapfile related actions + let 'check_leap_file()' do the expiration test and logging + + ntpd/ntp_util.c@1.111 +44 -54 + [Bug 2597] changed/unified logging for leapfile related actions + 'check_leap_file()' checks for leapfile load/reload and expiration, + let 'leapsec_load_file()' do the handling & logging for the disk file + +ChangeSet@1.3107.1.37, 2014-04-09 10:24:43+00:00, stenn@deacon.udel.edu + NTP_4_2_7P440 + TAG: NTP_4_2_7P440 + + ChangeLog@1.1471 +1 -0 + NTP_4_2_7P440 + + ntpd/invoke-ntp.conf.texi@1.119 +1 -1 + NTP_4_2_7P440 + + ntpd/invoke-ntp.keys.texi@1.117 +1 -1 + NTP_4_2_7P440 + + ntpd/invoke-ntpd.texi@1.433 +2 -2 + NTP_4_2_7P440 + + ntpd/ntp.conf.5man@1.153 +0 -3019 + NTP_4_2_7P440 + + ntpd/ntp.conf.5mdoc@1.153 +2 -2 + NTP_4_2_7P440 + + ntpd/ntp.conf.html@1.114 +1 -1 + NTP_4_2_7P440 + + ntpd/ntp.conf.man.in@1.153 +0 -3019 + NTP_4_2_7P440 + + ntpd/ntp.conf.mdoc.in@1.153 +2 -2 + NTP_4_2_7P440 + + ntpd/ntp.keys.5man@1.151 +2 -2 + NTP_4_2_7P440 + + ntpd/ntp.keys.5mdoc@1.151 +2 -2 + NTP_4_2_7P440 + + ntpd/ntp.keys.html@1.115 +1 -1 + NTP_4_2_7P440 + + ntpd/ntp.keys.man.in@1.151 +2 -2 + NTP_4_2_7P440 + + ntpd/ntp.keys.mdoc.in@1.151 +2 -2 + NTP_4_2_7P440 + + ntpd/ntpd-opts.c@1.451 +7 -7 + NTP_4_2_7P440 + + ntpd/ntpd-opts.h@1.451 +3 -3 + NTP_4_2_7P440 + + ntpd/ntpd.1ntpdman@1.262 +6 -6 + NTP_4_2_7P440 + + ntpd/ntpd.1ntpdmdoc@1.262 +2 -2 + NTP_4_2_7P440 + + ntpd/ntpd.html@1.109 +2 -2 + NTP_4_2_7P440 + + ntpd/ntpd.man.in@1.262 +6 -6 + NTP_4_2_7P440 + + ntpd/ntpd.mdoc.in@1.262 +2 -2 + NTP_4_2_7P440 + + ntpdc/invoke-ntpdc.texi@1.431 +2 -2 + NTP_4_2_7P440 + + ntpdc/ntpdc-opts.c@1.446 +7 -7 + NTP_4_2_7P440 + + ntpdc/ntpdc-opts.h@1.446 +3 -3 + NTP_4_2_7P440 + + ntpdc/ntpdc.1ntpdcman@1.262 +6 -6 + NTP_4_2_7P440 + + ntpdc/ntpdc.1ntpdcmdoc@1.262 +2 -2 + NTP_4_2_7P440 + + ntpdc/ntpdc.html@1.275 +2 -2 + NTP_4_2_7P440 + + ntpdc/ntpdc.man.in@1.262 +6 -6 + NTP_4_2_7P440 + + ntpdc/ntpdc.mdoc.in@1.262 +2 -2 + NTP_4_2_7P440 + + ntpq/invoke-ntpq.texi@1.434 +2 -2 + NTP_4_2_7P440 + + ntpq/ntpq-opts.c@1.448 +7 -7 + NTP_4_2_7P440 + + ntpq/ntpq-opts.h@1.448 +3 -3 + NTP_4_2_7P440 + + ntpq/ntpq.1ntpqman@1.262 +475 -0 + NTP_4_2_7P440 + + ntpq/ntpq.1ntpqmdoc@1.262 +2 -2 + NTP_4_2_7P440 + + ntpq/ntpq.html@1.106 +2 -2 + NTP_4_2_7P440 + + ntpq/ntpq.man.in@1.262 +475 -0 + NTP_4_2_7P440 + + ntpq/ntpq.mdoc.in@1.262 +2 -2 + NTP_4_2_7P440 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.433 +2 -2 + NTP_4_2_7P440 + + ntpsnmpd/ntpsnmpd-opts.c@1.448 +7 -7 + NTP_4_2_7P440 + + ntpsnmpd/ntpsnmpd-opts.h@1.448 +3 -3 + NTP_4_2_7P440 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.262 +13 -13 + NTP_4_2_7P440 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.262 +2 -2 + NTP_4_2_7P440 + + ntpsnmpd/ntpsnmpd.html@1.104 +1 -1 + NTP_4_2_7P440 + + ntpsnmpd/ntpsnmpd.man.in@1.262 +13 -13 + NTP_4_2_7P440 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.262 +2 -2 + NTP_4_2_7P440 + + packageinfo.sh@1.444 +1 -1 + NTP_4_2_7P440 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.24 +6 -6 + NTP_4_2_7P440 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.24 +2 -2 + NTP_4_2_7P440 + + scripts/calc_tickadj/calc_tickadj.html@1.23 +1 -1 + NTP_4_2_7P440 + + scripts/calc_tickadj/calc_tickadj.man.in@1.23 +6 -6 + NTP_4_2_7P440 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.24 +2 -2 + NTP_4_2_7P440 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.25 +1 -1 + NTP_4_2_7P440 + + scripts/invoke-plot_summary.texi@1.42 +1 -1 + NTP_4_2_7P440 + + scripts/invoke-summary.texi@1.42 +1 -1 + NTP_4_2_7P440 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.251 +1 -1 + NTP_4_2_7P440 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.252 +6 -6 + NTP_4_2_7P440 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.252 +2 -2 + NTP_4_2_7P440 + + scripts/ntp-wait/ntp-wait.html@1.268 +1 -1 + NTP_4_2_7P440 + + scripts/ntp-wait/ntp-wait.man.in@1.252 +6 -6 + NTP_4_2_7P440 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.252 +2 -2 + NTP_4_2_7P440 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.40 +1 -1 + NTP_4_2_7P440 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.31 +6 -6 + NTP_4_2_7P440 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.31 +2 -2 + NTP_4_2_7P440 + + scripts/ntpsweep/ntpsweep.html@1.41 +1 -1 + NTP_4_2_7P440 + + scripts/ntpsweep/ntpsweep.man.in@1.31 +6 -6 + NTP_4_2_7P440 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.32 +2 -2 + NTP_4_2_7P440 + + scripts/ntptrace/invoke-ntptrace.texi@1.40 +1 -1 + NTP_4_2_7P440 + + scripts/ntptrace/ntptrace.1ntptraceman@1.31 +6 -6 + NTP_4_2_7P440 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.31 +2 -2 + NTP_4_2_7P440 + + scripts/ntptrace/ntptrace.html@1.41 +1 -1 + NTP_4_2_7P440 + + scripts/ntptrace/ntptrace.man.in@1.31 +6 -6 + NTP_4_2_7P440 + + scripts/ntptrace/ntptrace.mdoc.in@1.32 +2 -2 + NTP_4_2_7P440 + + scripts/plot_summary.1plot_summaryman@1.42 +6 -6 + NTP_4_2_7P440 + + scripts/plot_summary.1plot_summarymdoc@1.42 +2 -2 + NTP_4_2_7P440 + + scripts/plot_summary.html@1.42 +1 -1 + NTP_4_2_7P440 + + scripts/plot_summary.man.in@1.42 +6 -6 + NTP_4_2_7P440 + + scripts/plot_summary.mdoc.in@1.42 +2 -2 + NTP_4_2_7P440 + + scripts/summary.1summaryman@1.42 +6 -6 + NTP_4_2_7P440 + + scripts/summary.1summarymdoc@1.42 +2 -2 + NTP_4_2_7P440 + + scripts/summary.html@1.42 +1 -1 + NTP_4_2_7P440 + + scripts/summary.man.in@1.42 +6 -6 + NTP_4_2_7P440 + + scripts/summary.mdoc.in@1.42 +2 -2 + NTP_4_2_7P440 + + sntp/invoke-sntp.texi@1.430 +2 -2 + NTP_4_2_7P440 + + sntp/sntp-opts.c@1.445 +7 -7 + NTP_4_2_7P440 + + sntp/sntp-opts.h@1.445 +3 -3 + NTP_4_2_7P440 + + sntp/sntp.1sntpman@1.265 +6 -6 + NTP_4_2_7P440 + + sntp/sntp.1sntpmdoc@1.265 +2 -2 + NTP_4_2_7P440 + + sntp/sntp.html@1.445 +2 -2 + NTP_4_2_7P440 + + sntp/sntp.man.in@1.265 +6 -6 + NTP_4_2_7P440 + + sntp/sntp.mdoc.in@1.265 +2 -2 + NTP_4_2_7P440 + + util/invoke-ntp-keygen.texi@1.434 +2 -2 + NTP_4_2_7P440 + + util/ntp-keygen-opts.c@1.448 +7 -7 + NTP_4_2_7P440 + + util/ntp-keygen-opts.h@1.448 +3 -3 + NTP_4_2_7P440 + + util/ntp-keygen.1ntp-keygenman@1.262 +6 -6 + NTP_4_2_7P440 + + util/ntp-keygen.1ntp-keygenmdoc@1.262 +2 -2 + NTP_4_2_7P440 + + util/ntp-keygen.html@1.110 +2 -2 + NTP_4_2_7P440 + + util/ntp-keygen.man.in@1.262 +6 -6 + NTP_4_2_7P440 + + util/ntp-keygen.mdoc.in@1.262 +2 -2 + NTP_4_2_7P440 + +ChangeSet@1.3107.4.2, 2014-04-08 07:40:51+00:00, stenn@psp-fb1.ntp.org + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + ChangeLog@1.1468.1.2 +1 -0 + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + + ntpd/ntpd.c@1.154 +46 -45 + [Bug 2536] ntpd sandboxing support (libseccomp2) cleanup + +ChangeSet@1.3107.4.1, 2014-04-03 10:22:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P439 + TAG: NTP_4_2_7P439 + + ChangeLog@1.1468.1.1 +1 -0 + NTP_4_2_7P439 + + ntpd/invoke-ntp.conf.texi@1.118 +1 -1 + NTP_4_2_7P439 + + ntpd/invoke-ntp.keys.texi@1.116 +1 -1 + NTP_4_2_7P439 + + ntpd/invoke-ntpd.texi@1.432 +2 -2 + NTP_4_2_7P439 + + ntpd/ntp.conf.5man@1.152 +6 -6 + NTP_4_2_7P439 + + ntpd/ntp.conf.5mdoc@1.152 +2 -2 + NTP_4_2_7P439 + + ntpd/ntp.conf.html@1.113 +1 -1 + NTP_4_2_7P439 + + ntpd/ntp.conf.man.in@1.152 +6 -6 + NTP_4_2_7P439 + + ntpd/ntp.conf.mdoc.in@1.152 +2 -2 + NTP_4_2_7P439 + + ntpd/ntp.keys.5man@1.150 +2 -2 + NTP_4_2_7P439 + + ntpd/ntp.keys.5mdoc@1.150 +2 -2 + NTP_4_2_7P439 + + ntpd/ntp.keys.html@1.114 +1 -1 + NTP_4_2_7P439 + + ntpd/ntp.keys.man.in@1.150 +2 -2 + NTP_4_2_7P439 + + ntpd/ntp.keys.mdoc.in@1.150 +2 -2 + NTP_4_2_7P439 + + ntpd/ntpd-opts.c@1.450 +7 -7 + NTP_4_2_7P439 + + ntpd/ntpd-opts.h@1.450 +3 -3 + NTP_4_2_7P439 + + ntpd/ntpd.1ntpdman@1.261 +6 -6 + NTP_4_2_7P439 + + ntpd/ntpd.1ntpdmdoc@1.261 +2 -2 + NTP_4_2_7P439 + + ntpd/ntpd.html@1.108 +2 -2 + NTP_4_2_7P439 + + ntpd/ntpd.man.in@1.261 +6 -6 + NTP_4_2_7P439 + + ntpd/ntpd.mdoc.in@1.261 +2 -2 + NTP_4_2_7P439 + + ntpdc/invoke-ntpdc.texi@1.430 +2 -2 + NTP_4_2_7P439 + + ntpdc/ntpdc-opts.c@1.445 +7 -7 + NTP_4_2_7P439 + + ntpdc/ntpdc-opts.h@1.445 +3 -3 + NTP_4_2_7P439 + + ntpdc/ntpdc.1ntpdcman@1.261 +6 -6 + NTP_4_2_7P439 + + ntpdc/ntpdc.1ntpdcmdoc@1.261 +2 -2 + NTP_4_2_7P439 + + ntpdc/ntpdc.html@1.274 +2 -2 + NTP_4_2_7P439 + + ntpdc/ntpdc.man.in@1.261 +6 -6 + NTP_4_2_7P439 + + ntpdc/ntpdc.mdoc.in@1.261 +2 -2 + NTP_4_2_7P439 + + ntpq/invoke-ntpq.texi@1.433 +2 -2 + NTP_4_2_7P439 + + ntpq/ntpq-opts.c@1.447 +7 -7 + NTP_4_2_7P439 + + ntpq/ntpq-opts.h@1.447 +3 -3 + NTP_4_2_7P439 + + ntpq/ntpq.1ntpqman@1.261 +0 -475 + NTP_4_2_7P439 + + ntpq/ntpq.1ntpqmdoc@1.261 +2 -2 + NTP_4_2_7P439 + + ntpq/ntpq.html@1.105 +2 -2 + NTP_4_2_7P439 + + ntpq/ntpq.man.in@1.261 +0 -475 + NTP_4_2_7P439 + + ntpq/ntpq.mdoc.in@1.261 +2 -2 + NTP_4_2_7P439 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.432 +2 -2 + NTP_4_2_7P439 + + ntpsnmpd/ntpsnmpd-opts.c@1.447 +7 -7 + NTP_4_2_7P439 + + ntpsnmpd/ntpsnmpd-opts.h@1.447 +3 -3 + NTP_4_2_7P439 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.261 +13 -13 + NTP_4_2_7P439 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.261 +2 -2 + NTP_4_2_7P439 + + ntpsnmpd/ntpsnmpd.html@1.103 +1 -1 + NTP_4_2_7P439 + + ntpsnmpd/ntpsnmpd.man.in@1.261 +13 -13 + NTP_4_2_7P439 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.261 +2 -2 + NTP_4_2_7P439 + + packageinfo.sh@1.443 +1 -1 + NTP_4_2_7P439 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.23 +6 -6 + NTP_4_2_7P439 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.23 +2 -2 + NTP_4_2_7P439 + + scripts/calc_tickadj/calc_tickadj.html@1.22 +1 -1 + NTP_4_2_7P439 + + scripts/calc_tickadj/calc_tickadj.man.in@1.22 +6 -6 + NTP_4_2_7P439 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.23 +2 -2 + NTP_4_2_7P439 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.24 +1 -1 + NTP_4_2_7P439 + + scripts/invoke-plot_summary.texi@1.41 +1 -1 + NTP_4_2_7P439 + + scripts/invoke-summary.texi@1.41 +1 -1 + NTP_4_2_7P439 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.250 +1 -1 + NTP_4_2_7P439 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.251 +6 -6 + NTP_4_2_7P439 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.251 +2 -2 + NTP_4_2_7P439 + + scripts/ntp-wait/ntp-wait.html@1.267 +1 -1 + NTP_4_2_7P439 + + scripts/ntp-wait/ntp-wait.man.in@1.251 +6 -6 + NTP_4_2_7P439 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.251 +2 -2 + NTP_4_2_7P439 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.39 +1 -1 + NTP_4_2_7P439 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.30 +6 -6 + NTP_4_2_7P439 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.30 +2 -2 + NTP_4_2_7P439 + + scripts/ntpsweep/ntpsweep.html@1.40 +1 -1 + NTP_4_2_7P439 + + scripts/ntpsweep/ntpsweep.man.in@1.30 +6 -6 + NTP_4_2_7P439 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.31 +2 -2 + NTP_4_2_7P439 + + scripts/ntptrace/invoke-ntptrace.texi@1.39 +1 -1 + NTP_4_2_7P439 + + scripts/ntptrace/ntptrace.1ntptraceman@1.30 +6 -6 + NTP_4_2_7P439 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.30 +2 -2 + NTP_4_2_7P439 + + scripts/ntptrace/ntptrace.html@1.40 +1 -1 + NTP_4_2_7P439 + + scripts/ntptrace/ntptrace.man.in@1.30 +6 -6 + NTP_4_2_7P439 + + scripts/ntptrace/ntptrace.mdoc.in@1.31 +2 -2 + NTP_4_2_7P439 + + scripts/plot_summary.1plot_summaryman@1.41 +6 -6 + NTP_4_2_7P439 + + scripts/plot_summary.1plot_summarymdoc@1.41 +2 -2 + NTP_4_2_7P439 + + scripts/plot_summary.html@1.41 +1 -1 + NTP_4_2_7P439 + + scripts/plot_summary.man.in@1.41 +6 -6 + NTP_4_2_7P439 + + scripts/plot_summary.mdoc.in@1.41 +2 -2 + NTP_4_2_7P439 + + scripts/summary.1summaryman@1.41 +6 -6 + NTP_4_2_7P439 + + scripts/summary.1summarymdoc@1.41 +2 -2 + NTP_4_2_7P439 + + scripts/summary.html@1.41 +1 -1 + NTP_4_2_7P439 + + scripts/summary.man.in@1.41 +6 -6 + NTP_4_2_7P439 + + scripts/summary.mdoc.in@1.41 +2 -2 + NTP_4_2_7P439 + + sntp/invoke-sntp.texi@1.429 +2 -2 + NTP_4_2_7P439 + + sntp/sntp-opts.c@1.444 +7 -7 + NTP_4_2_7P439 + + sntp/sntp-opts.h@1.444 +3 -3 + NTP_4_2_7P439 + + sntp/sntp.1sntpman@1.264 +6 -6 + NTP_4_2_7P439 + + sntp/sntp.1sntpmdoc@1.264 +2 -2 + NTP_4_2_7P439 + + sntp/sntp.html@1.444 +2 -2 + NTP_4_2_7P439 + + sntp/sntp.man.in@1.264 +6 -6 + NTP_4_2_7P439 + + sntp/sntp.mdoc.in@1.264 +2 -2 + NTP_4_2_7P439 + + util/invoke-ntp-keygen.texi@1.433 +2 -2 + NTP_4_2_7P439 + + util/ntp-keygen-opts.c@1.447 +7 -7 + NTP_4_2_7P439 + + util/ntp-keygen-opts.h@1.447 +3 -3 + NTP_4_2_7P439 + + util/ntp-keygen.1ntp-keygenman@1.261 +6 -6 + NTP_4_2_7P439 + + util/ntp-keygen.1ntp-keygenmdoc@1.261 +2 -2 + NTP_4_2_7P439 + + util/ntp-keygen.html@1.109 +2 -2 + NTP_4_2_7P439 + + util/ntp-keygen.man.in@1.261 +6 -6 + NTP_4_2_7P439 + + util/ntp-keygen.mdoc.in@1.261 +2 -2 + NTP_4_2_7P439 + +ChangeSet@1.3107.1.35, 2014-04-02 20:26:10+02:00, jnperlin@hydra.(none) + [Bug 2570] cleanup: log format for successful leapfile load + + ChangeLog@1.1469 +1 -0 + [Bug 2570] cleanup: log format for successful leapfile load + + ntpd/ntp_leapsec.c@1.9 +1 -1 + [Bug 2570] cleanup: log format for successful leapfile load + +ChangeSet@1.3107.1.34, 2014-04-02 03:00:46-04:00, stenn@deacon.udel.edu + [Bug 2589] fix VS2009 compile problem + + ChangeLog@1.1468 +1 -0 + [Bug 2589] fix VS2009 compile problem + + ports/winnt/vs2008/libntp/libntp.vcproj@1.50 +10 -2 + [Bug 2589] fix VS2009 compile problem + +ChangeSet@1.3107.1.33, 2014-04-01 10:50:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P438 + TAG: NTP_4_2_7P438 + + ChangeLog@1.1467 +1 -0 + NTP_4_2_7P438 + + ntpd/invoke-ntp.conf.texi@1.117 +1 -1 + NTP_4_2_7P438 + + ntpd/invoke-ntp.keys.texi@1.115 +1 -1 + NTP_4_2_7P438 + + ntpd/invoke-ntpd.texi@1.431 +2 -2 + NTP_4_2_7P438 + + ntpd/ntp.conf.5man@1.151 +6 -6 + NTP_4_2_7P438 + + ntpd/ntp.conf.5mdoc@1.151 +2 -2 + NTP_4_2_7P438 + + ntpd/ntp.conf.html@1.112 +1 -1 + NTP_4_2_7P438 + + ntpd/ntp.conf.man.in@1.151 +6 -6 + NTP_4_2_7P438 + + ntpd/ntp.conf.mdoc.in@1.151 +2 -2 + NTP_4_2_7P438 + + ntpd/ntp.keys.5man@1.149 +2 -2 + NTP_4_2_7P438 + + ntpd/ntp.keys.5mdoc@1.149 +2 -2 + NTP_4_2_7P438 + + ntpd/ntp.keys.html@1.113 +1 -1 + NTP_4_2_7P438 + + ntpd/ntp.keys.man.in@1.149 +2 -2 + NTP_4_2_7P438 + + ntpd/ntp.keys.mdoc.in@1.149 +2 -2 + NTP_4_2_7P438 + + ntpd/ntpd-opts.c@1.449 +7 -7 + NTP_4_2_7P438 + + ntpd/ntpd-opts.h@1.449 +3 -3 + NTP_4_2_7P438 + + ntpd/ntpd.1ntpdman@1.260 +6 -6 + NTP_4_2_7P438 + + ntpd/ntpd.1ntpdmdoc@1.260 +2 -2 + NTP_4_2_7P438 + + ntpd/ntpd.html@1.107 +2 -2 + NTP_4_2_7P438 + + ntpd/ntpd.man.in@1.260 +6 -6 + NTP_4_2_7P438 + + ntpd/ntpd.mdoc.in@1.260 +2 -2 + NTP_4_2_7P438 + + ntpdc/invoke-ntpdc.texi@1.429 +2 -2 + NTP_4_2_7P438 + + ntpdc/ntpdc-opts.c@1.444 +7 -7 + NTP_4_2_7P438 + + ntpdc/ntpdc-opts.h@1.444 +3 -3 + NTP_4_2_7P438 + + ntpdc/ntpdc.1ntpdcman@1.260 +6 -6 + NTP_4_2_7P438 + + ntpdc/ntpdc.1ntpdcmdoc@1.260 +2 -2 + NTP_4_2_7P438 + + ntpdc/ntpdc.html@1.273 +2 -2 + NTP_4_2_7P438 + + ntpdc/ntpdc.man.in@1.260 +6 -6 + NTP_4_2_7P438 + + ntpdc/ntpdc.mdoc.in@1.260 +2 -2 + NTP_4_2_7P438 + + ntpq/invoke-ntpq.texi@1.432 +2 -2 + NTP_4_2_7P438 + + ntpq/ntpq-opts.c@1.446 +7 -7 + NTP_4_2_7P438 + + ntpq/ntpq-opts.h@1.446 +3 -3 + NTP_4_2_7P438 + + ntpq/ntpq.1ntpqman@1.260 +6 -6 + NTP_4_2_7P438 + + ntpq/ntpq.1ntpqmdoc@1.260 +2 -2 + NTP_4_2_7P438 + + ntpq/ntpq.html@1.104 +2 -2 + NTP_4_2_7P438 + + ntpq/ntpq.man.in@1.260 +6 -6 + NTP_4_2_7P438 + + ntpq/ntpq.mdoc.in@1.260 +2 -2 + NTP_4_2_7P438 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.431 +2 -2 + NTP_4_2_7P438 + + ntpsnmpd/ntpsnmpd-opts.c@1.446 +7 -7 + NTP_4_2_7P438 + + ntpsnmpd/ntpsnmpd-opts.h@1.446 +3 -3 + NTP_4_2_7P438 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.260 +6 -6 + NTP_4_2_7P438 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.260 +2 -2 + NTP_4_2_7P438 + + ntpsnmpd/ntpsnmpd.html@1.102 +1 -1 + NTP_4_2_7P438 + + ntpsnmpd/ntpsnmpd.man.in@1.260 +6 -6 + NTP_4_2_7P438 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.260 +2 -2 + NTP_4_2_7P438 + + packageinfo.sh@1.442 +1 -1 + NTP_4_2_7P438 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.22 +6 -6 + NTP_4_2_7P438 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.22 +2 -2 + NTP_4_2_7P438 + + scripts/calc_tickadj/calc_tickadj.html@1.21 +1 -1 + NTP_4_2_7P438 + + scripts/calc_tickadj/calc_tickadj.man.in@1.21 +6 -6 + NTP_4_2_7P438 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.22 +2 -2 + NTP_4_2_7P438 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.23 +1 -1 + NTP_4_2_7P438 + + scripts/invoke-plot_summary.texi@1.40 +1 -1 + NTP_4_2_7P438 + + scripts/invoke-summary.texi@1.40 +1 -1 + NTP_4_2_7P438 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.249 +1 -1 + NTP_4_2_7P438 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.250 +6 -6 + NTP_4_2_7P438 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.250 +2 -2 + NTP_4_2_7P438 + + scripts/ntp-wait/ntp-wait.html@1.266 +1 -1 + NTP_4_2_7P438 + + scripts/ntp-wait/ntp-wait.man.in@1.250 +6 -6 + NTP_4_2_7P438 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.250 +2 -2 + NTP_4_2_7P438 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.38 +1 -1 + NTP_4_2_7P438 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.29 +6 -6 + NTP_4_2_7P438 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.29 +2 -2 + NTP_4_2_7P438 + + scripts/ntpsweep/ntpsweep.html@1.39 +1 -1 + NTP_4_2_7P438 + + scripts/ntpsweep/ntpsweep.man.in@1.29 +6 -6 + NTP_4_2_7P438 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.30 +2 -2 + NTP_4_2_7P438 + + scripts/ntptrace/invoke-ntptrace.texi@1.38 +1 -1 + NTP_4_2_7P438 + + scripts/ntptrace/ntptrace.1ntptraceman@1.29 +6 -6 + NTP_4_2_7P438 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.29 +2 -2 + NTP_4_2_7P438 + + scripts/ntptrace/ntptrace.html@1.39 +1 -1 + NTP_4_2_7P438 + + scripts/ntptrace/ntptrace.man.in@1.29 +6 -6 + NTP_4_2_7P438 + + scripts/ntptrace/ntptrace.mdoc.in@1.30 +2 -2 + NTP_4_2_7P438 + + scripts/plot_summary.1plot_summaryman@1.40 +6 -6 + NTP_4_2_7P438 + + scripts/plot_summary.1plot_summarymdoc@1.40 +2 -2 + NTP_4_2_7P438 + + scripts/plot_summary.html@1.40 +1 -1 + NTP_4_2_7P438 + + scripts/plot_summary.man.in@1.40 +6 -6 + NTP_4_2_7P438 + + scripts/plot_summary.mdoc.in@1.40 +2 -2 + NTP_4_2_7P438 + + scripts/summary.1summaryman@1.40 +6 -6 + NTP_4_2_7P438 + + scripts/summary.1summarymdoc@1.40 +2 -2 + NTP_4_2_7P438 + + scripts/summary.html@1.40 +1 -1 + NTP_4_2_7P438 + + scripts/summary.man.in@1.40 +6 -6 + NTP_4_2_7P438 + + scripts/summary.mdoc.in@1.40 +2 -2 + NTP_4_2_7P438 + + sntp/invoke-sntp.texi@1.428 +2 -2 + NTP_4_2_7P438 + + sntp/sntp-opts.c@1.443 +7 -7 + NTP_4_2_7P438 + + sntp/sntp-opts.h@1.443 +3 -3 + NTP_4_2_7P438 + + sntp/sntp.1sntpman@1.263 +6 -6 + NTP_4_2_7P438 + + sntp/sntp.1sntpmdoc@1.263 +2 -2 + NTP_4_2_7P438 + + sntp/sntp.html@1.443 +2 -2 + NTP_4_2_7P438 + + sntp/sntp.man.in@1.263 +6 -6 + NTP_4_2_7P438 + + sntp/sntp.mdoc.in@1.263 +2 -2 + NTP_4_2_7P438 + + util/invoke-ntp-keygen.texi@1.432 +2 -2 + NTP_4_2_7P438 + + util/ntp-keygen-opts.c@1.446 +7 -7 + NTP_4_2_7P438 + + util/ntp-keygen-opts.h@1.446 +3 -3 + NTP_4_2_7P438 + + util/ntp-keygen.1ntp-keygenman@1.260 +6 -6 + NTP_4_2_7P438 + + util/ntp-keygen.1ntp-keygenmdoc@1.260 +2 -2 + NTP_4_2_7P438 + + util/ntp-keygen.html@1.108 +2 -2 + NTP_4_2_7P438 + + util/ntp-keygen.man.in@1.260 +6 -6 + NTP_4_2_7P438 + + util/ntp-keygen.mdoc.in@1.260 +2 -2 + NTP_4_2_7P438 + +ChangeSet@1.3107.1.32, 2014-04-01 02:26:13-04:00, stenn@deacon.udel.edu + Windows build documentation updates + + ChangeLog@1.1466 +1 -0 + Windows build documentation updates + + html/hints/winnt.html@1.23 +6 -5 + Windows build documentation updates + +ChangeSet@1.3107.1.31, 2014-03-31 10:52:43+00:00, stenn@deacon.udel.edu + NTP_4_2_7P437 + TAG: NTP_4_2_7P437 + + ChangeLog@1.1465 +1 -0 + NTP_4_2_7P437 + + ntpd/invoke-ntp.conf.texi@1.116 +1 -1 + NTP_4_2_7P437 + + ntpd/invoke-ntp.keys.texi@1.114 +1 -1 + NTP_4_2_7P437 + + ntpd/invoke-ntpd.texi@1.430 +2 -2 + NTP_4_2_7P437 + + ntpd/ntp.conf.5man@1.150 +6 -6 + NTP_4_2_7P437 + + ntpd/ntp.conf.5mdoc@1.150 +1 -1 + NTP_4_2_7P437 + + ntpd/ntp.conf.html@1.111 +1 -1 + NTP_4_2_7P437 + + ntpd/ntp.conf.man.in@1.150 +6 -6 + NTP_4_2_7P437 + + ntpd/ntp.conf.mdoc.in@1.150 +1 -1 + NTP_4_2_7P437 + + ntpd/ntp.keys.5man@1.148 +2 -2 + NTP_4_2_7P437 + + ntpd/ntp.keys.5mdoc@1.148 +1 -1 + NTP_4_2_7P437 + + ntpd/ntp.keys.html@1.112 +1 -1 + NTP_4_2_7P437 + + ntpd/ntp.keys.man.in@1.148 +2 -2 + NTP_4_2_7P437 + + ntpd/ntp.keys.mdoc.in@1.148 +1 -1 + NTP_4_2_7P437 + + ntpd/ntpd-opts.c@1.448 +7 -7 + NTP_4_2_7P437 + + ntpd/ntpd-opts.h@1.448 +3 -3 + NTP_4_2_7P437 + + ntpd/ntpd.1ntpdman@1.259 +6 -6 + NTP_4_2_7P437 + + ntpd/ntpd.1ntpdmdoc@1.259 +1 -1 + NTP_4_2_7P437 + + ntpd/ntpd.html@1.106 +4 -4 + NTP_4_2_7P437 + + ntpd/ntpd.man.in@1.259 +6 -6 + NTP_4_2_7P437 + + ntpd/ntpd.mdoc.in@1.259 +1 -1 + NTP_4_2_7P437 + + ntpdc/invoke-ntpdc.texi@1.428 +2 -2 + NTP_4_2_7P437 + + ntpdc/ntpdc-opts.c@1.443 +7 -7 + NTP_4_2_7P437 + + ntpdc/ntpdc-opts.h@1.443 +3 -3 + NTP_4_2_7P437 + + ntpdc/ntpdc.1ntpdcman@1.259 +6 -6 + NTP_4_2_7P437 + + ntpdc/ntpdc.1ntpdcmdoc@1.259 +1 -1 + NTP_4_2_7P437 + + ntpdc/ntpdc.html@1.272 +2 -2 + NTP_4_2_7P437 + + ntpdc/ntpdc.man.in@1.259 +6 -6 + NTP_4_2_7P437 + + ntpdc/ntpdc.mdoc.in@1.259 +1 -1 + NTP_4_2_7P437 + + ntpq/invoke-ntpq.texi@1.431 +2 -2 + NTP_4_2_7P437 + + ntpq/ntpq-opts.c@1.445 +7 -7 + NTP_4_2_7P437 + + ntpq/ntpq-opts.h@1.445 +3 -3 + NTP_4_2_7P437 + + ntpq/ntpq.1ntpqman@1.259 +6 -6 + NTP_4_2_7P437 + + ntpq/ntpq.1ntpqmdoc@1.259 +1 -1 + NTP_4_2_7P437 + + ntpq/ntpq.html@1.103 +2 -2 + NTP_4_2_7P437 + + ntpq/ntpq.man.in@1.259 +6 -6 + NTP_4_2_7P437 + + ntpq/ntpq.mdoc.in@1.259 +1 -1 + NTP_4_2_7P437 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.430 +2 -2 + NTP_4_2_7P437 + + ntpsnmpd/ntpsnmpd-opts.c@1.445 +7 -7 + NTP_4_2_7P437 + + ntpsnmpd/ntpsnmpd-opts.h@1.445 +3 -3 + NTP_4_2_7P437 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.259 +6 -6 + NTP_4_2_7P437 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.259 +1 -1 + NTP_4_2_7P437 + + ntpsnmpd/ntpsnmpd.html@1.101 +1 -1 + NTP_4_2_7P437 + + ntpsnmpd/ntpsnmpd.man.in@1.259 +6 -6 + NTP_4_2_7P437 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.259 +1 -1 + NTP_4_2_7P437 + + packageinfo.sh@1.441 +1 -1 + NTP_4_2_7P437 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.21 +6 -6 + NTP_4_2_7P437 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.21 +1 -1 + NTP_4_2_7P437 + + scripts/calc_tickadj/calc_tickadj.html@1.20 +1 -1 + NTP_4_2_7P437 + + scripts/calc_tickadj/calc_tickadj.man.in@1.20 +6 -6 + NTP_4_2_7P437 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.21 +1 -1 + NTP_4_2_7P437 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.22 +1 -1 + NTP_4_2_7P437 + + scripts/invoke-plot_summary.texi@1.39 +1 -1 + NTP_4_2_7P437 + + scripts/invoke-summary.texi@1.39 +1 -1 + NTP_4_2_7P437 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.248 +1 -1 + NTP_4_2_7P437 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.249 +6 -6 + NTP_4_2_7P437 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.249 +1 -1 + NTP_4_2_7P437 + + scripts/ntp-wait/ntp-wait.html@1.265 +1 -1 + NTP_4_2_7P437 + + scripts/ntp-wait/ntp-wait.man.in@1.249 +6 -6 + NTP_4_2_7P437 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.249 +1 -1 + NTP_4_2_7P437 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.37 +1 -1 + NTP_4_2_7P437 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.28 +6 -6 + NTP_4_2_7P437 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.28 +1 -1 + NTP_4_2_7P437 + + scripts/ntpsweep/ntpsweep.html@1.38 +1 -1 + NTP_4_2_7P437 + + scripts/ntpsweep/ntpsweep.man.in@1.28 +6 -6 + NTP_4_2_7P437 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.29 +1 -1 + NTP_4_2_7P437 + + scripts/ntptrace/invoke-ntptrace.texi@1.37 +1 -1 + NTP_4_2_7P437 + + scripts/ntptrace/ntptrace.1ntptraceman@1.28 +6 -6 + NTP_4_2_7P437 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.28 +1 -1 + NTP_4_2_7P437 + + scripts/ntptrace/ntptrace.html@1.38 +1 -1 + NTP_4_2_7P437 + + scripts/ntptrace/ntptrace.man.in@1.28 +6 -6 + NTP_4_2_7P437 + + scripts/ntptrace/ntptrace.mdoc.in@1.29 +1 -1 + NTP_4_2_7P437 + + scripts/plot_summary.1plot_summaryman@1.39 +6 -6 + NTP_4_2_7P437 + + scripts/plot_summary.1plot_summarymdoc@1.39 +1 -1 + NTP_4_2_7P437 + + scripts/plot_summary.html@1.39 +1 -1 + NTP_4_2_7P437 + + scripts/plot_summary.man.in@1.39 +6 -6 + NTP_4_2_7P437 + + scripts/plot_summary.mdoc.in@1.39 +1 -1 + NTP_4_2_7P437 + + scripts/summary.1summaryman@1.39 +6 -6 + NTP_4_2_7P437 + + scripts/summary.1summarymdoc@1.39 +1 -1 + NTP_4_2_7P437 + + scripts/summary.html@1.39 +1 -1 + NTP_4_2_7P437 + + scripts/summary.man.in@1.39 +6 -6 + NTP_4_2_7P437 + + scripts/summary.mdoc.in@1.39 +1 -1 + NTP_4_2_7P437 + + sntp/invoke-sntp.texi@1.427 +2 -2 + NTP_4_2_7P437 + + sntp/sntp-opts.c@1.442 +7 -7 + NTP_4_2_7P437 + + sntp/sntp-opts.h@1.442 +3 -3 + NTP_4_2_7P437 + + sntp/sntp.1sntpman@1.262 +6 -6 + NTP_4_2_7P437 + + sntp/sntp.1sntpmdoc@1.262 +1 -1 + NTP_4_2_7P437 + + sntp/sntp.html@1.442 +2 -2 + NTP_4_2_7P437 + + sntp/sntp.man.in@1.262 +6 -6 + NTP_4_2_7P437 + + sntp/sntp.mdoc.in@1.262 +1 -1 + NTP_4_2_7P437 + + util/invoke-ntp-keygen.texi@1.431 +2 -2 + NTP_4_2_7P437 + + util/ntp-keygen-opts.c@1.445 +7 -7 + NTP_4_2_7P437 + + util/ntp-keygen-opts.h@1.445 +3 -3 + NTP_4_2_7P437 + + util/ntp-keygen.1ntp-keygenman@1.259 +6 -6 + NTP_4_2_7P437 + + util/ntp-keygen.1ntp-keygenmdoc@1.259 +1 -1 + NTP_4_2_7P437 + + util/ntp-keygen.html@1.107 +2 -2 + NTP_4_2_7P437 + + util/ntp-keygen.man.in@1.259 +6 -6 + NTP_4_2_7P437 + + util/ntp-keygen.mdoc.in@1.259 +1 -1 + NTP_4_2_7P437 + +ChangeSet@1.3107.1.30, 2014-03-31 04:06:33-04:00, stenn@deacon.udel.edu + [Bug 2537] ntpd truncates symmetric keys to 20 bytes + + ChangeLog@1.1464 +1 -0 + [Bug 2537] ntpd truncates symmetric keys to 20 bytes + + libntp/authreadkeys.c@1.19 +2 -2 + [Bug 2537] ntpd truncates symmetric keys to 20 bytes + +ChangeSet@1.3107.1.29, 2014-03-31 07:53:05+00:00, stenn@psp-fb1.ntp.org + [Bug 2546] Documentation updates + + ChangeLog@1.1463 +1 -0 + [Bug 2546] Documentation updates + +ChangeSet@1.3107.3.1, 2014-03-31 07:50:34+00:00, stenn@psp-fb1.ntp.org + [Bug 2546] Documentation updates + + ChangeLog@1.1453.1.1 +1 -0 + [Bug 2546] Documentation updates + + html/build.html@1.26 +3 -3 + [Bug 2546] Documentation updates + + html/drivers/driver20.html@1.28 +5 -1 + [Bug 2546] Documentation updates + + html/drivers/driver22.html@1.21 +4 -3 + [Bug 2546] Documentation updates + + html/hints/winnt.html@1.22 +11 -109 + [Bug 2546] Documentation updates + + html/index.html@1.46 +3 -3 + [Bug 2546] Documentation updates + +ChangeSet@1.3107.1.27, 2014-03-31 06:48:04+00:00, stenn@deacon.udel.edu + NTP_4_2_7P436 + TAG: NTP_4_2_7P436 + + ChangeLog@1.1461 +1 -0 + NTP_4_2_7P436 + + ntpd/invoke-ntp.conf.texi@1.115 +1 -1 + NTP_4_2_7P436 + + ntpd/invoke-ntp.keys.texi@1.113 +1 -1 + NTP_4_2_7P436 + + ntpd/invoke-ntpd.texi@1.429 +4 -4 + NTP_4_2_7P436 + + ntpd/ntp.conf.5man@1.149 +32 -3 + NTP_4_2_7P436 + + ntpd/ntp.conf.5mdoc@1.149 +20 -1 + NTP_4_2_7P436 + + ntpd/ntp.conf.html@1.110 +91 -104 + NTP_4_2_7P436 + + ntpd/ntp.conf.man.in@1.149 +32 -3 + NTP_4_2_7P436 + + ntpd/ntp.conf.mdoc.in@1.149 +20 -1 + NTP_4_2_7P436 + + ntpd/ntp.keys.5man@1.147 +21 -2 + NTP_4_2_7P436 + + ntpd/ntp.keys.5mdoc@1.147 +21 -2 + NTP_4_2_7P436 + + ntpd/ntp.keys.html@1.111 +17 -29 + NTP_4_2_7P436 + + ntpd/ntp.keys.man.in@1.147 +21 -2 + NTP_4_2_7P436 + + ntpd/ntp.keys.mdoc.in@1.147 +21 -2 + NTP_4_2_7P436 + + ntpd/ntpd-opts.c@1.447 +7 -7 + NTP_4_2_7P436 + + ntpd/ntpd-opts.h@1.447 +3 -3 + NTP_4_2_7P436 + + ntpd/ntpd.1ntpdman@1.258 +32 -3 + NTP_4_2_7P436 + + ntpd/ntpd.1ntpdmdoc@1.258 +20 -1 + NTP_4_2_7P436 + + ntpd/ntpd.html@1.105 +100 -142 + NTP_4_2_7P436 + + ntpd/ntpd.man.in@1.258 +32 -3 + NTP_4_2_7P436 + + ntpd/ntpd.mdoc.in@1.258 +20 -1 + NTP_4_2_7P436 + + ntpdc/invoke-ntpdc.texi@1.427 +2 -2 + NTP_4_2_7P436 + + ntpdc/ntpdc-opts.c@1.442 +7 -7 + NTP_4_2_7P436 + + ntpdc/ntpdc-opts.h@1.442 +3 -3 + NTP_4_2_7P436 + + ntpdc/ntpdc.1ntpdcman@1.258 +32 -3 + NTP_4_2_7P436 + + ntpdc/ntpdc.1ntpdcmdoc@1.258 +20 -1 + NTP_4_2_7P436 + + ntpdc/ntpdc.html@1.271 +57 -77 + NTP_4_2_7P436 + + ntpdc/ntpdc.man.in@1.258 +32 -3 + NTP_4_2_7P436 + + ntpdc/ntpdc.mdoc.in@1.258 +20 -1 + NTP_4_2_7P436 + + ntpq/invoke-ntpq.texi@1.430 +2 -2 + NTP_4_2_7P436 + + ntpq/ntpq-opts.c@1.444 +7 -7 + NTP_4_2_7P436 + + ntpq/ntpq-opts.h@1.444 +3 -3 + NTP_4_2_7P436 + + ntpq/ntpq.1ntpqman@1.258 +32 -3 + NTP_4_2_7P436 + + ntpq/ntpq.1ntpqmdoc@1.258 +20 -1 + NTP_4_2_7P436 + + ntpq/ntpq.html@1.102 +97 -119 + NTP_4_2_7P436 + + ntpq/ntpq.man.in@1.258 +32 -3 + NTP_4_2_7P436 + + ntpq/ntpq.mdoc.in@1.258 +20 -1 + NTP_4_2_7P436 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.429 +2 -2 + NTP_4_2_7P436 + + ntpsnmpd/ntpsnmpd-opts.c@1.444 +7 -7 + NTP_4_2_7P436 + + ntpsnmpd/ntpsnmpd-opts.h@1.444 +3 -3 + NTP_4_2_7P436 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.258 +32 -3 + NTP_4_2_7P436 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.258 +20 -1 + NTP_4_2_7P436 + + ntpsnmpd/ntpsnmpd.html@1.100 +10 -14 + NTP_4_2_7P436 + + ntpsnmpd/ntpsnmpd.man.in@1.258 +32 -3 + NTP_4_2_7P436 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.258 +20 -1 + NTP_4_2_7P436 + + packageinfo.sh@1.440 +1 -1 + NTP_4_2_7P436 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.20 +32 -3 + NTP_4_2_7P436 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.20 +20 -1 + NTP_4_2_7P436 + + scripts/calc_tickadj/calc_tickadj.html@1.19 +22 -34 + NTP_4_2_7P436 + + scripts/calc_tickadj/calc_tickadj.man.in@1.19 +32 -3 + NTP_4_2_7P436 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.20 +20 -1 + NTP_4_2_7P436 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.21 +1 -1 + NTP_4_2_7P436 + + scripts/invoke-plot_summary.texi@1.38 +1 -1 + NTP_4_2_7P436 + + scripts/invoke-summary.texi@1.38 +1 -1 + NTP_4_2_7P436 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.247 +1 -1 + NTP_4_2_7P436 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.248 +32 -3 + NTP_4_2_7P436 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.248 +20 -1 + NTP_4_2_7P436 + + scripts/ntp-wait/ntp-wait.html@1.264 +30 -48 + NTP_4_2_7P436 + + scripts/ntp-wait/ntp-wait.man.in@1.248 +32 -3 + NTP_4_2_7P436 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.248 +20 -1 + NTP_4_2_7P436 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.36 +1 -1 + NTP_4_2_7P436 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.27 +32 -3 + NTP_4_2_7P436 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.27 +20 -1 + NTP_4_2_7P436 + + scripts/ntpsweep/ntpsweep.html@1.37 +32 -43 + NTP_4_2_7P436 + + scripts/ntpsweep/ntpsweep.man.in@1.27 +32 -3 + NTP_4_2_7P436 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.28 +20 -1 + NTP_4_2_7P436 + + scripts/ntptrace/invoke-ntptrace.texi@1.36 +1 -1 + NTP_4_2_7P436 + + scripts/ntptrace/ntptrace.1ntptraceman@1.27 +32 -3 + NTP_4_2_7P436 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.27 +20 -1 + NTP_4_2_7P436 + + scripts/ntptrace/ntptrace.html@1.37 +26 -35 + NTP_4_2_7P436 + + scripts/ntptrace/ntptrace.man.in@1.27 +32 -3 + NTP_4_2_7P436 + + scripts/ntptrace/ntptrace.mdoc.in@1.28 +20 -1 + NTP_4_2_7P436 + + scripts/plot_summary.1plot_summaryman@1.38 +33 -3 + NTP_4_2_7P436 + + scripts/plot_summary.1plot_summarymdoc@1.38 +21 -1 + NTP_4_2_7P436 + + scripts/plot_summary.html@1.38 +28 -46 + NTP_4_2_7P436 + + scripts/plot_summary.man.in@1.38 +33 -3 + NTP_4_2_7P436 + + scripts/plot_summary.mdoc.in@1.38 +21 -1 + NTP_4_2_7P436 + + scripts/summary.1summaryman@1.38 +32 -3 + NTP_4_2_7P436 + + scripts/summary.1summarymdoc@1.38 +20 -1 + NTP_4_2_7P436 + + scripts/summary.html@1.38 +26 -38 + NTP_4_2_7P436 + + scripts/summary.man.in@1.38 +32 -3 + NTP_4_2_7P436 + + scripts/summary.mdoc.in@1.38 +20 -1 + NTP_4_2_7P436 + + sntp/invoke-sntp.texi@1.426 +2 -2 + NTP_4_2_7P436 + + sntp/sntp-opts.c@1.441 +7 -7 + NTP_4_2_7P436 + + sntp/sntp-opts.h@1.441 +3 -3 + NTP_4_2_7P436 + + sntp/sntp.1sntpman@1.261 +32 -3 + NTP_4_2_7P436 + + sntp/sntp.1sntpmdoc@1.261 +20 -1 + NTP_4_2_7P436 + + sntp/sntp.html@1.441 +85 -109 + NTP_4_2_7P436 + + sntp/sntp.man.in@1.261 +32 -3 + NTP_4_2_7P436 + + sntp/sntp.mdoc.in@1.261 +20 -1 + NTP_4_2_7P436 + + util/invoke-ntp-keygen.texi@1.430 +2 -2 + NTP_4_2_7P436 + + util/ntp-keygen-opts.c@1.444 +7 -7 + NTP_4_2_7P436 + + util/ntp-keygen-opts.h@1.444 +3 -3 + NTP_4_2_7P436 + + util/ntp-keygen.1ntp-keygenman@1.258 +32 -3 + NTP_4_2_7P436 + + util/ntp-keygen.1ntp-keygenmdoc@1.258 +20 -1 + NTP_4_2_7P436 + + util/ntp-keygen.html@1.106 +124 -183 + NTP_4_2_7P436 + + util/ntp-keygen.man.in@1.258 +32 -3 + NTP_4_2_7P436 + + util/ntp-keygen.mdoc.in@1.258 +20 -1 + NTP_4_2_7P436 + +ChangeSet@1.3107.1.26, 2014-03-31 04:52:47+00:00, stenn@psp-fb1.ntp.org + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ChangeLog@1.1460 +4 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/invoke-ntp.conf.texi@1.114 +1 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/invoke-ntp.keys.texi@1.112 +1 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/invoke-ntpd.texi@1.428 +3 -3 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.conf.5man@1.148 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.conf.5mdoc@1.148 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.conf.def@1.12 +0 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.conf.html@1.109 +104 -92 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.conf.man.in@1.148 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.conf.mdoc.in@1.148 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.keys.5man@1.146 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.keys.5mdoc@1.146 +3 -23 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.keys.def@1.10 +0 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.keys.html@1.110 +29 -18 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.keys.man.in@1.146 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntp.keys.mdoc.in@1.146 +3 -23 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd-opts.c@1.446 +6 -6 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd-opts.def@1.11 +0 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd-opts.h@1.446 +8 -3 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd.1ntpdman@1.257 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd.1ntpdmdoc@1.257 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd.html@1.104 +143 -101 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd.man.in@1.257 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpd.mdoc.in@1.257 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpdsim-opts.c@1.23 +196 -195 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpd/ntpdsim-opts.h@1.23 +16 -11 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/invoke-ntpdc.texi@1.426 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/ntpdc-opts.c@1.441 +6 -6 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/ntpdc-opts.h@1.441 +8 -3 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/ntpdc.1ntpdcman@1.257 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/ntpdc.1ntpdcmdoc@1.257 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/ntpdc.html@1.270 +75 -55 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/ntpdc.man.in@1.257 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpdc/ntpdc.mdoc.in@1.257 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/invoke-ntpq.texi@1.429 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/ntpq-opts.c@1.443 +6 -6 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/ntpq-opts.h@1.443 +8 -3 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/ntpq.1ntpqman@1.257 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/ntpq.1ntpqmdoc@1.257 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/ntpq.html@1.101 +118 -96 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/ntpq.man.in@1.257 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpq/ntpq.mdoc.in@1.257 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/invoke-ntpsnmpd.texi@1.428 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd-opts.c@1.443 +6 -6 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd-opts.def@1.10 +0 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd-opts.h@1.443 +8 -3 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.257 +3 -36 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.257 +2 -23 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd.html@1.99 +13 -9 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd.man.in@1.257 +3 -36 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + ntpsnmpd/ntpsnmpd.mdoc.in@1.257 +2 -23 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/calc_tickadj/calc_tickadj-opts@1.3 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.19 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.19 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/calc_tickadj/calc_tickadj.html@1.18 +34 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/calc_tickadj/calc_tickadj.man.in@1.18 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.19 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.20 +2 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/invoke-plot_summary.texi@1.37 +2 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/invoke-summary.texi@1.37 +2 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntp-wait/invoke-ntp-wait.texi@1.246 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.247 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.247 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntp-wait/ntp-wait.html@1.263 +47 -29 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntp-wait/ntp-wait.man.in@1.247 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntp-wait/ntp-wait.mdoc.in@1.247 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntpsweep/invoke-ntpsweep.texi@1.35 +2 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntpsweep/ntpsweep-opts@1.3 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.26 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.26 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntpsweep/ntpsweep.html@1.36 +43 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntpsweep/ntpsweep.man.in@1.26 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntpsweep/ntpsweep.mdoc.in@1.27 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntptrace/invoke-ntptrace.texi@1.35 +2 -2 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntptrace/ntptrace-opts@1.3 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntptrace/ntptrace.1ntptraceman@1.26 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.26 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntptrace/ntptrace.html@1.36 +35 -26 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntptrace/ntptrace.man.in@1.26 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/ntptrace/ntptrace.mdoc.in@1.27 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/plot_summary-opts@1.3 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/plot_summary.1plot_summaryman@1.37 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/plot_summary.1plot_summarymdoc@1.37 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/plot_summary.html@1.37 +46 -28 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/plot_summary.man.in@1.37 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/plot_summary.mdoc.in@1.37 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/summary-opts@1.3 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/summary.1summaryman@1.37 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/summary.1summarymdoc@1.37 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/summary.html@1.37 +38 -26 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/summary.man.in@1.37 +3 -32 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + scripts/summary.mdoc.in@1.37 +2 -21 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/ag-tpl/perlopt.tpl@1.3 +66 -55 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/include/autogen-version.def@1.20 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/include/copyright.def@1.23 +8 -4 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/invoke-sntp.texi@1.425 +1 -4 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp-opts.c@1.440 +6 -6 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp-opts.def@1.43 +0 -9 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp-opts.h@1.440 +8 -3 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp.1sntpman@1.260 +4 -38 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp.1sntpmdoc@1.260 +3 -25 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp.html@1.440 +104 -91 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp.man.in@1.260 +4 -38 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + sntp/sntp.mdoc.in@1.260 +3 -25 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/invoke-ntp-keygen.texi@1.429 +1 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen-opts.c@1.443 +6 -6 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen-opts.def@1.26 +0 -1 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen-opts.h@1.443 +8 -3 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen.1ntp-keygenman@1.257 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen.1ntp-keygenmdoc@1.257 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen.html@1.105 +182 -123 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen.man.in@1.257 +3 -33 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + + util/ntp-keygen.mdoc.in@1.257 +2 -22 + * Update to libopts-40.2.15, and autogen-5.18.3pre18. + * [Bug 2311] Add more tags to mdoc2xxx. + * [Bug 2502] Assorted text replacement errors in 4.2.7p345 + * [Bug 2538] ntp programs print exit code as part of the "usage" text. + +ChangeSet@1.3107.1.25, 2014-03-29 23:11:12+00:00, stenn@psp-fb1.ntp.org + Update to libopts-40.2.15 + + ChangeLog@1.1459 +1 -0 + Update to libopts-40.2.15 + + sntp/libopts/COPYING.gplv3@1.7 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/COPYING.lgplv3@1.7 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/Makefile.am@1.24 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/README@1.9 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/ag-char-map.h@1.27 +2 -2 + Update to libopts-40.2.15 + + sntp/libopts/alias.c@1.7 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/ao-strs.c@1.13 +2 -2 + Update to libopts-40.2.15 + + sntp/libopts/ao-strs.h@1.12 +2 -2 + Update to libopts-40.2.15 + + sntp/libopts/autoopts.c@1.19 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/autoopts.h@1.17 +11 -1 + Update to libopts-40.2.15 + + sntp/libopts/autoopts/options.h@1.26 +6 -6 + Update to libopts-40.2.15 + + sntp/libopts/autoopts/project.h@1.7 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/autoopts/usage-txt.h@1.26 +7 -7 + Update to libopts-40.2.15 + + sntp/libopts/boolean.c@1.14 +14 -19 + Update to libopts-40.2.15 + + sntp/libopts/check.c@1.7 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/compat/compat.h@1.15 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/compat/windows-config.h@1.13 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/configfile.c@1.21 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/cook.c@1.14 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/enum.c@1.10 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/env.c@1.8 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/file.c@1.14 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/find.c@1.10 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/genshell.c@1.27 +9 -9 + Update to libopts-40.2.15 + + sntp/libopts/genshell.h@1.27 +9 -4 + Update to libopts-40.2.15 + + sntp/libopts/gettext.h@1.3 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/init.c@1.6 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/load.c@1.19 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/m4/libopts.m4@1.30 +5 -5 + Update to libopts-40.2.15 + + sntp/libopts/m4/liboptschk.m4@1.12 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/makeshell.c@1.17 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/nested.c@1.14 +75 -52 + Update to libopts-40.2.15 + + sntp/libopts/numeric.c@1.13 +8 -1 + Update to libopts-40.2.15 + + sntp/libopts/option-value-type.c@1.14 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/option-value-type.h@1.28 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/option-xat-attribute.c@1.14 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/option-xat-attribute.h@1.28 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/parse-duration.c@1.11 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/parse-duration.h@1.9 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/pgusage.c@1.16 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/proto.h@1.27 +2 -2 + Update to libopts-40.2.15 + + sntp/libopts/putshell.c@1.14 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/reset.c@1.15 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/restore.c@1.13 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/save.c@1.16 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/sort.c@1.13 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/stack.c@1.15 +41 -46 + Update to libopts-40.2.15 + + sntp/libopts/streqvcmp.c@1.15 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/text_mmap.c@1.16 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/time.c@1.14 +32 -35 + Update to libopts-40.2.15 + + sntp/libopts/tokenize.c@1.11 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/usage.c@1.19 +1 -1 + Update to libopts-40.2.15 + + sntp/libopts/version.c@1.16 +1 -1 + Update to libopts-40.2.15 + +ChangeSet@1.3107.1.24, 2014-03-29 11:41:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P435 + TAG: NTP_4_2_7P435 + + ChangeLog@1.1458 +1 -0 + NTP_4_2_7P435 + + ntpd/invoke-ntp.conf.texi@1.113 +1 -1 + NTP_4_2_7P435 + + ntpd/invoke-ntp.keys.texi@1.111 +1 -1 + NTP_4_2_7P435 + + ntpd/invoke-ntpd.texi@1.427 +2 -2 + NTP_4_2_7P435 + + ntpd/ntp.conf.5man@1.147 +7 -7 + NTP_4_2_7P435 + + ntpd/ntp.conf.5mdoc@1.147 +3 -3 + NTP_4_2_7P435 + + ntpd/ntp.conf.html@1.108 +1 -1 + NTP_4_2_7P435 + + ntpd/ntp.conf.man.in@1.147 +7 -7 + NTP_4_2_7P435 + + ntpd/ntp.conf.mdoc.in@1.147 +3 -3 + NTP_4_2_7P435 + + ntpd/ntp.keys.5man@1.145 +3 -3 + NTP_4_2_7P435 + + ntpd/ntp.keys.5mdoc@1.145 +3 -3 + NTP_4_2_7P435 + + ntpd/ntp.keys.html@1.109 +1 -1 + NTP_4_2_7P435 + + ntpd/ntp.keys.man.in@1.145 +3 -3 + NTP_4_2_7P435 + + ntpd/ntp.keys.mdoc.in@1.145 +3 -3 + NTP_4_2_7P435 + + ntpd/ntpd-opts.c@1.445 +7 -7 + NTP_4_2_7P435 + + ntpd/ntpd-opts.h@1.445 +3 -3 + NTP_4_2_7P435 + + ntpd/ntpd.1ntpdman@1.256 +7 -7 + NTP_4_2_7P435 + + ntpd/ntpd.1ntpdmdoc@1.256 +3 -3 + NTP_4_2_7P435 + + ntpd/ntpd.html@1.103 +2 -2 + NTP_4_2_7P435 + + ntpd/ntpd.man.in@1.256 +7 -7 + NTP_4_2_7P435 + + ntpd/ntpd.mdoc.in@1.256 +3 -3 + NTP_4_2_7P435 + + ntpdc/invoke-ntpdc.texi@1.425 +2 -2 + NTP_4_2_7P435 + + ntpdc/ntpdc-opts.c@1.440 +7 -7 + NTP_4_2_7P435 + + ntpdc/ntpdc-opts.h@1.440 +3 -3 + NTP_4_2_7P435 + + ntpdc/ntpdc.1ntpdcman@1.256 +6 -6 + NTP_4_2_7P435 + + ntpdc/ntpdc.1ntpdcmdoc@1.256 +2 -2 + NTP_4_2_7P435 + + ntpdc/ntpdc.html@1.269 +2 -2 + NTP_4_2_7P435 + + ntpdc/ntpdc.man.in@1.256 +6 -6 + NTP_4_2_7P435 + + ntpdc/ntpdc.mdoc.in@1.256 +2 -2 + NTP_4_2_7P435 + + ntpq/invoke-ntpq.texi@1.428 +2 -2 + NTP_4_2_7P435 + + ntpq/ntpq-opts.c@1.442 +7 -7 + NTP_4_2_7P435 + + ntpq/ntpq-opts.h@1.442 +3 -3 + NTP_4_2_7P435 + + ntpq/ntpq.1ntpqman@1.256 +6 -6 + NTP_4_2_7P435 + + ntpq/ntpq.1ntpqmdoc@1.256 +2 -2 + NTP_4_2_7P435 + + ntpq/ntpq.html@1.100 +2 -2 + NTP_4_2_7P435 + + ntpq/ntpq.man.in@1.256 +6 -6 + NTP_4_2_7P435 + + ntpq/ntpq.mdoc.in@1.256 +2 -2 + NTP_4_2_7P435 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.427 +2 -2 + NTP_4_2_7P435 + + ntpsnmpd/ntpsnmpd-opts.c@1.442 +7 -7 + NTP_4_2_7P435 + + ntpsnmpd/ntpsnmpd-opts.h@1.442 +3 -3 + NTP_4_2_7P435 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.256 +14 -14 + NTP_4_2_7P435 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.256 +3 -3 + NTP_4_2_7P435 + + ntpsnmpd/ntpsnmpd.html@1.98 +1 -1 + NTP_4_2_7P435 + + ntpsnmpd/ntpsnmpd.man.in@1.256 +14 -14 + NTP_4_2_7P435 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.256 +3 -3 + NTP_4_2_7P435 + + packageinfo.sh@1.439 +1 -1 + NTP_4_2_7P435 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.18 +6 -6 + NTP_4_2_7P435 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.18 +2 -2 + NTP_4_2_7P435 + + scripts/calc_tickadj/calc_tickadj.html@1.17 +82 -1 + NTP_4_2_7P435 + + scripts/calc_tickadj/calc_tickadj.man.in@1.17 +6 -6 + NTP_4_2_7P435 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.18 +2 -2 + NTP_4_2_7P435 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.19 +60 -1 + NTP_4_2_7P435 + + scripts/invoke-plot_summary.texi@1.36 +1 -1 + NTP_4_2_7P435 + + scripts/invoke-summary.texi@1.36 +1 -1 + NTP_4_2_7P435 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.245 +1 -1 + NTP_4_2_7P435 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.246 +6 -6 + NTP_4_2_7P435 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.246 +2 -2 + NTP_4_2_7P435 + + scripts/ntp-wait/ntp-wait.html@1.262 +1 -1 + NTP_4_2_7P435 + + scripts/ntp-wait/ntp-wait.man.in@1.246 +6 -6 + NTP_4_2_7P435 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.246 +2 -2 + NTP_4_2_7P435 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.34 +1 -1 + NTP_4_2_7P435 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.25 +6 -6 + NTP_4_2_7P435 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.25 +2 -2 + NTP_4_2_7P435 + + scripts/ntpsweep/ntpsweep.html@1.35 +1 -1 + NTP_4_2_7P435 + + scripts/ntpsweep/ntpsweep.man.in@1.25 +6 -6 + NTP_4_2_7P435 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.26 +2 -2 + NTP_4_2_7P435 + + scripts/ntptrace/invoke-ntptrace.texi@1.34 +1 -1 + NTP_4_2_7P435 + + scripts/ntptrace/ntptrace.1ntptraceman@1.25 +6 -6 + NTP_4_2_7P435 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.25 +2 -2 + NTP_4_2_7P435 + + scripts/ntptrace/ntptrace.html@1.35 +1 -1 + NTP_4_2_7P435 + + scripts/ntptrace/ntptrace.man.in@1.25 +6 -6 + NTP_4_2_7P435 + + scripts/ntptrace/ntptrace.mdoc.in@1.26 +2 -2 + NTP_4_2_7P435 + + scripts/plot_summary.1plot_summaryman@1.36 +6 -6 + NTP_4_2_7P435 + + scripts/plot_summary.1plot_summarymdoc@1.36 +2 -2 + NTP_4_2_7P435 + + scripts/plot_summary.html@1.36 +1 -1 + NTP_4_2_7P435 + + scripts/plot_summary.man.in@1.36 +6 -6 + NTP_4_2_7P435 + + scripts/plot_summary.mdoc.in@1.36 +2 -2 + NTP_4_2_7P435 + + scripts/summary.1summaryman@1.36 +13 -13 + NTP_4_2_7P435 + + scripts/summary.1summarymdoc@1.36 +2 -2 + NTP_4_2_7P435 + + scripts/summary.html@1.36 +1 -1 + NTP_4_2_7P435 + + scripts/summary.man.in@1.36 +13 -13 + NTP_4_2_7P435 + + scripts/summary.mdoc.in@1.36 +2 -2 + NTP_4_2_7P435 + + sntp/invoke-sntp.texi@1.424 +2 -2 + NTP_4_2_7P435 + + sntp/sntp-opts.c@1.439 +7 -7 + NTP_4_2_7P435 + + sntp/sntp-opts.h@1.439 +3 -3 + NTP_4_2_7P435 + + sntp/sntp.1sntpman@1.259 +7 -7 + NTP_4_2_7P435 + + sntp/sntp.1sntpmdoc@1.259 +3 -3 + NTP_4_2_7P435 + + sntp/sntp.html@1.439 +2 -2 + NTP_4_2_7P435 + + sntp/sntp.man.in@1.259 +7 -7 + NTP_4_2_7P435 + + sntp/sntp.mdoc.in@1.259 +3 -3 + NTP_4_2_7P435 + + util/invoke-ntp-keygen.texi@1.428 +2 -2 + NTP_4_2_7P435 + + util/ntp-keygen-opts.c@1.442 +7 -7 + NTP_4_2_7P435 + + util/ntp-keygen-opts.h@1.442 +3 -3 + NTP_4_2_7P435 + + util/ntp-keygen.1ntp-keygenman@1.256 +7 -7 + NTP_4_2_7P435 + + util/ntp-keygen.1ntp-keygenmdoc@1.256 +3 -3 + NTP_4_2_7P435 + + util/ntp-keygen.html@1.104 +2 -2 + NTP_4_2_7P435 + + util/ntp-keygen.man.in@1.256 +7 -7 + NTP_4_2_7P435 + + util/ntp-keygen.mdoc.in@1.256 +3 -3 + NTP_4_2_7P435 + +ChangeSet@1.3107.1.23, 2014-03-26 11:01:31+01:00, jnperlin@hydra.(none) + [Bug 2570] cleanup: reduced logging noise, moved some functions into libntp + + ChangeLog@1.1457 +2 -0 + [Bug 2570] cleanup: reduced logging noise, moved some functions into libntp + + include/Makefile.am@1.50 +1 -0 + [Bug 2570] cleanup: added 'vint64ops.h' + + include/ntp_calendar.h@1.14 +12 -0 + [Bug 2570] cleanup: moved functions for 64bit times to to calendar + + include/vint64ops.h@1.1 +28 -0 + [Bug 2570] cleanup: moved vint64 operations to libntp + + include/vint64ops.h@1.0 +0 -0 + + libntp/Makefile.am@1.74 +1 -0 + [Bug 2570] cleanup: added 'vint64ops.c' + + libntp/ntp_calendar.c@1.13 +71 -23 + [Bug 2570] cleanup: moved functions for 64bit times to to calendar + + libntp/vint64ops.c@1.1 +284 -0 + [Bug 2570] cleanup: moved vint64 operations to libntp + + libntp/vint64ops.c@1.0 +0 -0 + + ntpd/ntp_leapsec.c@1.8 +44 -277 + [Bug 2570] cleanup: reduced logging noise, moved some functions into libntp + + ntpd/ntp_leapsec.h@1.6 +1 -6 + [Bug 2570] cleanup: reduced logging noise, moved some functions into libntp + + ntpd/ntp_util.c@1.110 +2 -10 + [Bug 2570] cleanup: reduced logging noise + + tests/libntp/Makefile.am@1.41 +1 -0 + [Bug 2570] cleanup: added test cases for vint64 ops + + tests/libntp/vi64ops.cpp@1.1 +64 -0 + [Bug 2570] cleanup: added test cases for vint64 ops + + tests/libntp/vi64ops.cpp@1.0 +0 -0 + + tests/ntpd/leapsec.cpp@1.8 +0 -42 + [Bug 2570] cleanup: moved vint64 tests to libntp + +ChangeSet@1.3107.1.22, 2014-03-21 06:02:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P434 + TAG: NTP_4_2_7P434 + + ChangeLog@1.1456 +1 -0 + NTP_4_2_7P434 + + ntpd/invoke-ntp.conf.texi@1.112 +1 -1 + NTP_4_2_7P434 + + ntpd/invoke-ntp.keys.texi@1.110 +1 -1 + NTP_4_2_7P434 + + ntpd/invoke-ntpd.texi@1.426 +2 -2 + NTP_4_2_7P434 + + ntpd/ntp.conf.5man@1.146 +7 -7 + NTP_4_2_7P434 + + ntpd/ntp.conf.5mdoc@1.146 +3 -3 + NTP_4_2_7P434 + + ntpd/ntp.conf.html@1.107 +1 -1 + NTP_4_2_7P434 + + ntpd/ntp.conf.man.in@1.146 +7 -7 + NTP_4_2_7P434 + + ntpd/ntp.conf.mdoc.in@1.146 +3 -3 + NTP_4_2_7P434 + + ntpd/ntp.keys.5man@1.144 +3 -3 + NTP_4_2_7P434 + + ntpd/ntp.keys.5mdoc@1.144 +3 -3 + NTP_4_2_7P434 + + ntpd/ntp.keys.html@1.108 +1 -1 + NTP_4_2_7P434 + + ntpd/ntp.keys.man.in@1.144 +3 -3 + NTP_4_2_7P434 + + ntpd/ntp.keys.mdoc.in@1.144 +3 -3 + NTP_4_2_7P434 + + ntpd/ntpd-opts.c@1.444 +7 -7 + NTP_4_2_7P434 + + ntpd/ntpd-opts.h@1.444 +3 -3 + NTP_4_2_7P434 + + ntpd/ntpd.1ntpdman@1.255 +7 -7 + NTP_4_2_7P434 + + ntpd/ntpd.1ntpdmdoc@1.255 +3 -3 + NTP_4_2_7P434 + + ntpd/ntpd.html@1.102 +2 -2 + NTP_4_2_7P434 + + ntpd/ntpd.man.in@1.255 +7 -7 + NTP_4_2_7P434 + + ntpd/ntpd.mdoc.in@1.255 +3 -3 + NTP_4_2_7P434 + + ntpdc/invoke-ntpdc.texi@1.424 +2 -2 + NTP_4_2_7P434 + + ntpdc/ntpdc-opts.c@1.439 +7 -7 + NTP_4_2_7P434 + + ntpdc/ntpdc-opts.h@1.439 +3 -3 + NTP_4_2_7P434 + + ntpdc/ntpdc.1ntpdcman@1.255 +6 -6 + NTP_4_2_7P434 + + ntpdc/ntpdc.1ntpdcmdoc@1.255 +2 -2 + NTP_4_2_7P434 + + ntpdc/ntpdc.html@1.268 +2 -2 + NTP_4_2_7P434 + + ntpdc/ntpdc.man.in@1.255 +6 -6 + NTP_4_2_7P434 + + ntpdc/ntpdc.mdoc.in@1.255 +2 -2 + NTP_4_2_7P434 + + ntpq/invoke-ntpq.texi@1.427 +2 -2 + NTP_4_2_7P434 + + ntpq/ntpq-opts.c@1.441 +7 -7 + NTP_4_2_7P434 + + ntpq/ntpq-opts.h@1.441 +3 -3 + NTP_4_2_7P434 + + ntpq/ntpq.1ntpqman@1.255 +6 -6 + NTP_4_2_7P434 + + ntpq/ntpq.1ntpqmdoc@1.255 +2 -2 + NTP_4_2_7P434 + + ntpq/ntpq.html@1.99 +2 -2 + NTP_4_2_7P434 + + ntpq/ntpq.man.in@1.255 +6 -6 + NTP_4_2_7P434 + + ntpq/ntpq.mdoc.in@1.255 +2 -2 + NTP_4_2_7P434 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.426 +2 -2 + NTP_4_2_7P434 + + ntpsnmpd/ntpsnmpd-opts.c@1.441 +7 -7 + NTP_4_2_7P434 + + ntpsnmpd/ntpsnmpd-opts.h@1.441 +3 -3 + NTP_4_2_7P434 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.255 +7 -7 + NTP_4_2_7P434 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.255 +3 -3 + NTP_4_2_7P434 + + ntpsnmpd/ntpsnmpd.html@1.97 +1 -1 + NTP_4_2_7P434 + + ntpsnmpd/ntpsnmpd.man.in@1.255 +7 -7 + NTP_4_2_7P434 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.255 +3 -3 + NTP_4_2_7P434 + + packageinfo.sh@1.438 +1 -1 + NTP_4_2_7P434 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.17 +6 -6 + NTP_4_2_7P434 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.17 +2 -2 + NTP_4_2_7P434 + + scripts/calc_tickadj/calc_tickadj.html@1.16 +1 -82 + NTP_4_2_7P434 + + scripts/calc_tickadj/calc_tickadj.man.in@1.16 +6 -6 + NTP_4_2_7P434 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.17 +2 -2 + NTP_4_2_7P434 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.18 +1 -60 + NTP_4_2_7P434 + + scripts/invoke-plot_summary.texi@1.35 +1 -1 + NTP_4_2_7P434 + + scripts/invoke-summary.texi@1.35 +1 -1 + NTP_4_2_7P434 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.244 +1 -1 + NTP_4_2_7P434 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.245 +6 -6 + NTP_4_2_7P434 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.245 +2 -2 + NTP_4_2_7P434 + + scripts/ntp-wait/ntp-wait.html@1.261 +1 -1 + NTP_4_2_7P434 + + scripts/ntp-wait/ntp-wait.man.in@1.245 +6 -6 + NTP_4_2_7P434 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.245 +2 -2 + NTP_4_2_7P434 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.33 +1 -1 + NTP_4_2_7P434 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.24 +6 -6 + NTP_4_2_7P434 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.24 +2 -2 + NTP_4_2_7P434 + + scripts/ntpsweep/ntpsweep.html@1.34 +1 -1 + NTP_4_2_7P434 + + scripts/ntpsweep/ntpsweep.man.in@1.24 +6 -6 + NTP_4_2_7P434 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.25 +2 -2 + NTP_4_2_7P434 + + scripts/ntptrace/invoke-ntptrace.texi@1.33 +1 -1 + NTP_4_2_7P434 + + scripts/ntptrace/ntptrace.1ntptraceman@1.24 +6 -6 + NTP_4_2_7P434 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.24 +2 -2 + NTP_4_2_7P434 + + scripts/ntptrace/ntptrace.html@1.34 +1 -1 + NTP_4_2_7P434 + + scripts/ntptrace/ntptrace.man.in@1.24 +6 -6 + NTP_4_2_7P434 + + scripts/ntptrace/ntptrace.mdoc.in@1.25 +2 -2 + NTP_4_2_7P434 + + scripts/plot_summary.1plot_summaryman@1.35 +13 -13 + NTP_4_2_7P434 + + scripts/plot_summary.1plot_summarymdoc@1.35 +2 -2 + NTP_4_2_7P434 + + scripts/plot_summary.html@1.35 +1 -1 + NTP_4_2_7P434 + + scripts/plot_summary.man.in@1.35 +13 -13 + NTP_4_2_7P434 + + scripts/plot_summary.mdoc.in@1.35 +2 -2 + NTP_4_2_7P434 + + scripts/summary.1summaryman@1.35 +13 -13 + NTP_4_2_7P434 + + scripts/summary.1summarymdoc@1.35 +2 -2 + NTP_4_2_7P434 + + scripts/summary.html@1.35 +1 -1 + NTP_4_2_7P434 + + scripts/summary.man.in@1.35 +13 -13 + NTP_4_2_7P434 + + scripts/summary.mdoc.in@1.35 +2 -2 + NTP_4_2_7P434 + + sntp/invoke-sntp.texi@1.423 +2 -2 + NTP_4_2_7P434 + + sntp/sntp-opts.c@1.438 +7 -7 + NTP_4_2_7P434 + + sntp/sntp-opts.h@1.438 +3 -3 + NTP_4_2_7P434 + + sntp/sntp.1sntpman@1.258 +7 -7 + NTP_4_2_7P434 + + sntp/sntp.1sntpmdoc@1.258 +3 -3 + NTP_4_2_7P434 + + sntp/sntp.html@1.438 +2 -2 + NTP_4_2_7P434 + + sntp/sntp.man.in@1.258 +7 -7 + NTP_4_2_7P434 + + sntp/sntp.mdoc.in@1.258 +3 -3 + NTP_4_2_7P434 + + util/invoke-ntp-keygen.texi@1.427 +2 -2 + NTP_4_2_7P434 + + util/ntp-keygen-opts.c@1.441 +7 -7 + NTP_4_2_7P434 + + util/ntp-keygen-opts.h@1.441 +3 -3 + NTP_4_2_7P434 + + util/ntp-keygen.1ntp-keygenman@1.255 +7 -7 + NTP_4_2_7P434 + + util/ntp-keygen.1ntp-keygenmdoc@1.255 +3 -3 + NTP_4_2_7P434 + + util/ntp-keygen.html@1.103 +2 -2 + NTP_4_2_7P434 + + util/ntp-keygen.man.in@1.255 +7 -7 + NTP_4_2_7P434 + + util/ntp-keygen.mdoc.in@1.255 +3 -3 + NTP_4_2_7P434 + +ChangeSet@1.3107.1.21, 2014-03-20 05:43:19-04:00, stenn@deacon.udel.edu + [Bug 2577] Update VS2013 solution and project files + + ChangeLog@1.1455 +1 -0 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/instsrv/instsrv.vcxproj@1.2 +375 -6 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.3 +295 -0 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/libntp/libntp.vcxproj.filters@1.2 +6 -0 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj@1.2 +313 -6 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj@1.3 +401 -4 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/ntp.sln@1.2 +59 -1 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj@1.3 +281 -0 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.3 +451 -9 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj@1.3 +393 -3 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj@1.3 +407 -4 + [Bug 2577] Update VS2013 solution and project files + + ports/winnt/vs2013/ntpq/ntpq.vcxproj@1.3 +395 -4 + [Bug 2577] Update VS2013 solution and project files + +ChangeSet@1.3107.1.20, 2014-03-10 11:23:57+00:00, stenn@deacon.udel.edu + NTP_4_2_7P433 + TAG: NTP_4_2_7P433 + + ChangeLog@1.1454 +1 -0 + NTP_4_2_7P433 + + ntpd/invoke-ntp.conf.texi@1.111 +1 -1 + NTP_4_2_7P433 + + ntpd/invoke-ntp.keys.texi@1.109 +1 -1 + NTP_4_2_7P433 + + ntpd/invoke-ntpd.texi@1.425 +2 -2 + NTP_4_2_7P433 + + ntpd/ntp.conf.5man@1.145 +7 -7 + NTP_4_2_7P433 + + ntpd/ntp.conf.5mdoc@1.145 +3 -3 + NTP_4_2_7P433 + + ntpd/ntp.conf.html@1.106 +1 -1 + NTP_4_2_7P433 + + ntpd/ntp.conf.man.in@1.145 +7 -7 + NTP_4_2_7P433 + + ntpd/ntp.conf.mdoc.in@1.145 +3 -3 + NTP_4_2_7P433 + + ntpd/ntp.keys.5man@1.143 +3 -3 + NTP_4_2_7P433 + + ntpd/ntp.keys.5mdoc@1.143 +3 -3 + NTP_4_2_7P433 + + ntpd/ntp.keys.html@1.107 +1 -1 + NTP_4_2_7P433 + + ntpd/ntp.keys.man.in@1.143 +3 -3 + NTP_4_2_7P433 + + ntpd/ntp.keys.mdoc.in@1.143 +3 -3 + NTP_4_2_7P433 + + ntpd/ntpd-opts.c@1.443 +7 -7 + NTP_4_2_7P433 + + ntpd/ntpd-opts.h@1.443 +3 -3 + NTP_4_2_7P433 + + ntpd/ntpd.1ntpdman@1.254 +7 -7 + NTP_4_2_7P433 + + ntpd/ntpd.1ntpdmdoc@1.254 +3 -3 + NTP_4_2_7P433 + + ntpd/ntpd.html@1.101 +2 -2 + NTP_4_2_7P433 + + ntpd/ntpd.man.in@1.254 +7 -7 + NTP_4_2_7P433 + + ntpd/ntpd.mdoc.in@1.254 +3 -3 + NTP_4_2_7P433 + + ntpdc/invoke-ntpdc.texi@1.423 +2 -2 + NTP_4_2_7P433 + + ntpdc/ntpdc-opts.c@1.438 +7 -7 + NTP_4_2_7P433 + + ntpdc/ntpdc-opts.h@1.438 +3 -3 + NTP_4_2_7P433 + + ntpdc/ntpdc.1ntpdcman@1.254 +6 -6 + NTP_4_2_7P433 + + ntpdc/ntpdc.1ntpdcmdoc@1.254 +2 -2 + NTP_4_2_7P433 + + ntpdc/ntpdc.html@1.267 +2 -2 + NTP_4_2_7P433 + + ntpdc/ntpdc.man.in@1.254 +6 -6 + NTP_4_2_7P433 + + ntpdc/ntpdc.mdoc.in@1.254 +2 -2 + NTP_4_2_7P433 + + ntpq/invoke-ntpq.texi@1.426 +2 -2 + NTP_4_2_7P433 + + ntpq/ntpq-opts.c@1.440 +7 -7 + NTP_4_2_7P433 + + ntpq/ntpq-opts.h@1.440 +3 -3 + NTP_4_2_7P433 + + ntpq/ntpq.1ntpqman@1.254 +6 -6 + NTP_4_2_7P433 + + ntpq/ntpq.1ntpqmdoc@1.254 +2 -2 + NTP_4_2_7P433 + + ntpq/ntpq.html@1.98 +2 -2 + NTP_4_2_7P433 + + ntpq/ntpq.man.in@1.254 +6 -6 + NTP_4_2_7P433 + + ntpq/ntpq.mdoc.in@1.254 +2 -2 + NTP_4_2_7P433 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.425 +2 -2 + NTP_4_2_7P433 + + ntpsnmpd/ntpsnmpd-opts.c@1.440 +7 -7 + NTP_4_2_7P433 + + ntpsnmpd/ntpsnmpd-opts.h@1.440 +3 -3 + NTP_4_2_7P433 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.254 +7 -7 + NTP_4_2_7P433 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.254 +3 -3 + NTP_4_2_7P433 + + ntpsnmpd/ntpsnmpd.html@1.96 +1 -1 + NTP_4_2_7P433 + + ntpsnmpd/ntpsnmpd.man.in@1.254 +7 -7 + NTP_4_2_7P433 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.254 +3 -3 + NTP_4_2_7P433 + + packageinfo.sh@1.437 +1 -1 + NTP_4_2_7P433 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.16 +6 -6 + NTP_4_2_7P433 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.16 +2 -2 + NTP_4_2_7P433 + + scripts/calc_tickadj/calc_tickadj.html@1.15 +1 -1 + NTP_4_2_7P433 + + scripts/calc_tickadj/calc_tickadj.man.in@1.15 +6 -6 + NTP_4_2_7P433 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.16 +2 -2 + NTP_4_2_7P433 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.17 +1 -1 + NTP_4_2_7P433 + + scripts/invoke-plot_summary.texi@1.34 +1 -1 + NTP_4_2_7P433 + + scripts/invoke-summary.texi@1.34 +1 -1 + NTP_4_2_7P433 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.243 +1 -1 + NTP_4_2_7P433 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.244 +13 -13 + NTP_4_2_7P433 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.244 +2 -2 + NTP_4_2_7P433 + + scripts/ntp-wait/ntp-wait.html@1.260 +1 -1 + NTP_4_2_7P433 + + scripts/ntp-wait/ntp-wait.man.in@1.244 +13 -13 + NTP_4_2_7P433 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.244 +2 -2 + NTP_4_2_7P433 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.32 +1 -1 + NTP_4_2_7P433 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.23 +6 -6 + NTP_4_2_7P433 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.23 +2 -2 + NTP_4_2_7P433 + + scripts/ntpsweep/ntpsweep.html@1.33 +1 -1 + NTP_4_2_7P433 + + scripts/ntpsweep/ntpsweep.man.in@1.23 +6 -6 + NTP_4_2_7P433 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.24 +2 -2 + NTP_4_2_7P433 + + scripts/ntptrace/invoke-ntptrace.texi@1.32 +1 -1 + NTP_4_2_7P433 + + scripts/ntptrace/ntptrace.1ntptraceman@1.23 +6 -6 + NTP_4_2_7P433 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.23 +2 -2 + NTP_4_2_7P433 + + scripts/ntptrace/ntptrace.html@1.33 +1 -1 + NTP_4_2_7P433 + + scripts/ntptrace/ntptrace.man.in@1.23 +6 -6 + NTP_4_2_7P433 + + scripts/ntptrace/ntptrace.mdoc.in@1.24 +2 -2 + NTP_4_2_7P433 + + scripts/plot_summary.1plot_summaryman@1.34 +13 -13 + NTP_4_2_7P433 + + scripts/plot_summary.1plot_summarymdoc@1.34 +2 -2 + NTP_4_2_7P433 + + scripts/plot_summary.html@1.34 +1 -1 + NTP_4_2_7P433 + + scripts/plot_summary.man.in@1.34 +13 -13 + NTP_4_2_7P433 + + scripts/plot_summary.mdoc.in@1.34 +2 -2 + NTP_4_2_7P433 + + scripts/summary.1summaryman@1.34 +6 -6 + NTP_4_2_7P433 + + scripts/summary.1summarymdoc@1.34 +2 -2 + NTP_4_2_7P433 + + scripts/summary.html@1.34 +1 -1 + NTP_4_2_7P433 + + scripts/summary.man.in@1.34 +6 -6 + NTP_4_2_7P433 + + scripts/summary.mdoc.in@1.34 +2 -2 + NTP_4_2_7P433 + + sntp/invoke-sntp.texi@1.422 +2 -2 + NTP_4_2_7P433 + + sntp/sntp-opts.c@1.437 +7 -7 + NTP_4_2_7P433 + + sntp/sntp-opts.h@1.437 +3 -3 + NTP_4_2_7P433 + + sntp/sntp.1sntpman@1.257 +7 -7 + NTP_4_2_7P433 + + sntp/sntp.1sntpmdoc@1.257 +3 -3 + NTP_4_2_7P433 + + sntp/sntp.html@1.437 +2 -2 + NTP_4_2_7P433 + + sntp/sntp.man.in@1.257 +7 -7 + NTP_4_2_7P433 + + sntp/sntp.mdoc.in@1.257 +3 -3 + NTP_4_2_7P433 + + util/invoke-ntp-keygen.texi@1.426 +2 -2 + NTP_4_2_7P433 + + util/ntp-keygen-opts.c@1.440 +7 -7 + NTP_4_2_7P433 + + util/ntp-keygen-opts.h@1.440 +3 -3 + NTP_4_2_7P433 + + util/ntp-keygen.1ntp-keygenman@1.254 +7 -7 + NTP_4_2_7P433 + + util/ntp-keygen.1ntp-keygenmdoc@1.254 +3 -3 + NTP_4_2_7P433 + + util/ntp-keygen.html@1.102 +2 -2 + NTP_4_2_7P433 + + util/ntp-keygen.man.in@1.254 +7 -7 + NTP_4_2_7P433 + + util/ntp-keygen.mdoc.in@1.254 +3 -3 + NTP_4_2_7P433 + +ChangeSet@1.3107.1.19, 2014-03-10 05:31:40-04:00, stenn@deacon.udel.edu + Clean up last-update timestamps of html/*.html files + + ChangeLog@1.1453 +1 -0 + Clean up last-update timestamps of html/*.html files + + html/confopt.html@1.61 +1 -1 + Clean up last-update timestamps of html/*.html files + + html/copyright.html@1.63 +5 -4 + Clean up last-update timestamps of html/*.html files + + html/discipline.html@1.9 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/discover.html@1.5 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/extern.html@1.16.1.1 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/filter.html@1.7 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/hints.html@1.19 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/history.html@1.3 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/howto.html@1.24 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/huffpuff.html@1.5 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/index.html@1.45 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/kern.html@1.21 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/kernpps.html@1.4 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/keygen.html@1.33 +2 -2 + Clean up last-update timestamps of html/*.html files + + html/leap.html@1.6 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/msyslog.html@1.11 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/ntpd.html@1.61 +1 -1 + Clean up last-update timestamps of html/*.html files + + html/poll.html@1.4 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/pps.html@1.25 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/prefer.html@1.32 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/rate.html@1.12 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/rdebug.html@1.18 +3 -5 + Clean up last-update timestamps of html/*.html files + + html/refclock.html@1.42 +1 -1 + Clean up last-update timestamps of html/*.html files + + html/select.html@1.9 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/stats.html@1.2 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/tickadj.html@1.18 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/warp.html@1.23 +3 -3 + Clean up last-update timestamps of html/*.html files + + html/xleave.html@1.9 +3 -3 + Clean up last-update timestamps of html/*.html files + +ChangeSet@1.3107.1.18, 2014-03-09 11:46:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P432 + TAG: NTP_4_2_7P432 + + ChangeLog@1.1452 +1 -0 + NTP_4_2_7P432 + + ntpd/invoke-ntp.conf.texi@1.110 +1 -1 + NTP_4_2_7P432 + + ntpd/invoke-ntp.keys.texi@1.108 +1 -1 + NTP_4_2_7P432 + + ntpd/invoke-ntpd.texi@1.424 +2 -2 + NTP_4_2_7P432 + + ntpd/ntp.conf.5man@1.144 +7 -7 + NTP_4_2_7P432 + + ntpd/ntp.conf.5mdoc@1.144 +3 -3 + NTP_4_2_7P432 + + ntpd/ntp.conf.html@1.105 +1 -1 + NTP_4_2_7P432 + + ntpd/ntp.conf.man.in@1.144 +7 -7 + NTP_4_2_7P432 + + ntpd/ntp.conf.mdoc.in@1.144 +3 -3 + NTP_4_2_7P432 + + ntpd/ntp.keys.5man@1.142 +3 -3 + NTP_4_2_7P432 + + ntpd/ntp.keys.5mdoc@1.142 +3 -3 + NTP_4_2_7P432 + + ntpd/ntp.keys.html@1.106 +1 -1 + NTP_4_2_7P432 + + ntpd/ntp.keys.man.in@1.142 +3 -3 + NTP_4_2_7P432 + + ntpd/ntp.keys.mdoc.in@1.142 +3 -3 + NTP_4_2_7P432 + + ntpd/ntpd-opts.c@1.442 +7 -7 + NTP_4_2_7P432 + + ntpd/ntpd-opts.h@1.442 +3 -3 + NTP_4_2_7P432 + + ntpd/ntpd.1ntpdman@1.253 +7 -7 + NTP_4_2_7P432 + + ntpd/ntpd.1ntpdmdoc@1.253 +3 -3 + NTP_4_2_7P432 + + ntpd/ntpd.html@1.100 +2 -2 + NTP_4_2_7P432 + + ntpd/ntpd.man.in@1.253 +7 -7 + NTP_4_2_7P432 + + ntpd/ntpd.mdoc.in@1.253 +3 -3 + NTP_4_2_7P432 + + ntpdc/invoke-ntpdc.texi@1.422 +2 -2 + NTP_4_2_7P432 + + ntpdc/ntpdc-opts.c@1.437 +7 -7 + NTP_4_2_7P432 + + ntpdc/ntpdc-opts.h@1.437 +3 -3 + NTP_4_2_7P432 + + ntpdc/ntpdc.1ntpdcman@1.253 +6 -6 + NTP_4_2_7P432 + + ntpdc/ntpdc.1ntpdcmdoc@1.253 +2 -2 + NTP_4_2_7P432 + + ntpdc/ntpdc.html@1.266 +2 -2 + NTP_4_2_7P432 + + ntpdc/ntpdc.man.in@1.253 +6 -6 + NTP_4_2_7P432 + + ntpdc/ntpdc.mdoc.in@1.253 +2 -2 + NTP_4_2_7P432 + + ntpq/invoke-ntpq.texi@1.425 +2 -2 + NTP_4_2_7P432 + + ntpq/ntpq-opts.c@1.439 +7 -7 + NTP_4_2_7P432 + + ntpq/ntpq-opts.h@1.439 +3 -3 + NTP_4_2_7P432 + + ntpq/ntpq.1ntpqman@1.253 +6 -6 + NTP_4_2_7P432 + + ntpq/ntpq.1ntpqmdoc@1.253 +2 -2 + NTP_4_2_7P432 + + ntpq/ntpq.html@1.97 +2 -2 + NTP_4_2_7P432 + + ntpq/ntpq.man.in@1.253 +6 -6 + NTP_4_2_7P432 + + ntpq/ntpq.mdoc.in@1.253 +2 -2 + NTP_4_2_7P432 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.424 +2 -2 + NTP_4_2_7P432 + + ntpsnmpd/ntpsnmpd-opts.c@1.439 +7 -7 + NTP_4_2_7P432 + + ntpsnmpd/ntpsnmpd-opts.h@1.439 +3 -3 + NTP_4_2_7P432 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.253 +7 -7 + NTP_4_2_7P432 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.253 +3 -3 + NTP_4_2_7P432 + + ntpsnmpd/ntpsnmpd.html@1.95 +1 -1 + NTP_4_2_7P432 + + ntpsnmpd/ntpsnmpd.man.in@1.253 +7 -7 + NTP_4_2_7P432 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.253 +3 -3 + NTP_4_2_7P432 + + packageinfo.sh@1.436 +1 -1 + NTP_4_2_7P432 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.15 +13 -13 + NTP_4_2_7P432 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.15 +2 -2 + NTP_4_2_7P432 + + scripts/calc_tickadj/calc_tickadj.html@1.14 +1 -1 + NTP_4_2_7P432 + + scripts/calc_tickadj/calc_tickadj.man.in@1.14 +13 -13 + NTP_4_2_7P432 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.15 +2 -2 + NTP_4_2_7P432 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.16 +1 -1 + NTP_4_2_7P432 + + scripts/invoke-plot_summary.texi@1.33 +1 -1 + NTP_4_2_7P432 + + scripts/invoke-summary.texi@1.33 +1 -1 + NTP_4_2_7P432 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.242 +1 -1 + NTP_4_2_7P432 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.243 +13 -13 + NTP_4_2_7P432 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.243 +2 -2 + NTP_4_2_7P432 + + scripts/ntp-wait/ntp-wait.html@1.259 +1 -1 + NTP_4_2_7P432 + + scripts/ntp-wait/ntp-wait.man.in@1.243 +13 -13 + NTP_4_2_7P432 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.243 +2 -2 + NTP_4_2_7P432 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.31 +1 -1 + NTP_4_2_7P432 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.22 +6 -6 + NTP_4_2_7P432 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.22 +2 -2 + NTP_4_2_7P432 + + scripts/ntpsweep/ntpsweep.html@1.32 +1 -1 + NTP_4_2_7P432 + + scripts/ntpsweep/ntpsweep.man.in@1.22 +6 -6 + NTP_4_2_7P432 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.23 +2 -2 + NTP_4_2_7P432 + + scripts/ntptrace/invoke-ntptrace.texi@1.31 +1 -1 + NTP_4_2_7P432 + + scripts/ntptrace/ntptrace.1ntptraceman@1.22 +6 -6 + NTP_4_2_7P432 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.22 +2 -2 + NTP_4_2_7P432 + + scripts/ntptrace/ntptrace.html@1.32 +1 -1 + NTP_4_2_7P432 + + scripts/ntptrace/ntptrace.man.in@1.22 +6 -6 + NTP_4_2_7P432 + + scripts/ntptrace/ntptrace.mdoc.in@1.23 +2 -2 + NTP_4_2_7P432 + + scripts/plot_summary.1plot_summaryman@1.33 +6 -6 + NTP_4_2_7P432 + + scripts/plot_summary.1plot_summarymdoc@1.33 +2 -2 + NTP_4_2_7P432 + + scripts/plot_summary.html@1.33 +1 -1 + NTP_4_2_7P432 + + scripts/plot_summary.man.in@1.33 +6 -6 + NTP_4_2_7P432 + + scripts/plot_summary.mdoc.in@1.33 +2 -2 + NTP_4_2_7P432 + + scripts/summary.1summaryman@1.33 +6 -6 + NTP_4_2_7P432 + + scripts/summary.1summarymdoc@1.33 +2 -2 + NTP_4_2_7P432 + + scripts/summary.html@1.33 +1 -1 + NTP_4_2_7P432 + + scripts/summary.man.in@1.33 +6 -6 + NTP_4_2_7P432 + + scripts/summary.mdoc.in@1.33 +2 -2 + NTP_4_2_7P432 + + sntp/invoke-sntp.texi@1.421 +2 -2 + NTP_4_2_7P432 + + sntp/sntp-opts.c@1.436 +7 -7 + NTP_4_2_7P432 + + sntp/sntp-opts.h@1.436 +3 -3 + NTP_4_2_7P432 + + sntp/sntp.1sntpman@1.256 +7 -7 + NTP_4_2_7P432 + + sntp/sntp.1sntpmdoc@1.256 +3 -3 + NTP_4_2_7P432 + + sntp/sntp.html@1.436 +2 -2 + NTP_4_2_7P432 + + sntp/sntp.man.in@1.256 +7 -7 + NTP_4_2_7P432 + + sntp/sntp.mdoc.in@1.256 +3 -3 + NTP_4_2_7P432 + + util/invoke-ntp-keygen.texi@1.425 +2 -2 + NTP_4_2_7P432 + + util/ntp-keygen-opts.c@1.439 +7 -7 + NTP_4_2_7P432 + + util/ntp-keygen-opts.h@1.439 +3 -3 + NTP_4_2_7P432 + + util/ntp-keygen.1ntp-keygenman@1.253 +7 -7 + NTP_4_2_7P432 + + util/ntp-keygen.1ntp-keygenmdoc@1.253 +3 -3 + NTP_4_2_7P432 + + util/ntp-keygen.html@1.101 +2 -2 + NTP_4_2_7P432 + + util/ntp-keygen.man.in@1.253 +7 -7 + NTP_4_2_7P432 + + util/ntp-keygen.mdoc.in@1.253 +3 -3 + NTP_4_2_7P432 + +ChangeSet@1.3107.1.17, 2014-03-08 23:11:31-05:00, stenn@deacon.udel.edu + CID 711660: Do a non-NULL pointer assertion check a bit earlier + + ChangeLog@1.1451 +1 -1 + CID 711660: Do a non-NULL pointer assertion check a bit earlier + + sntp/libevent/event.c@1.12 +1 -1 + CID 711660: Do a non-NULL pointer assertion check a bit earlier + +ChangeSet@1.3107.1.16, 2014-03-05 11:18:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P431 + TAG: NTP_4_2_7P431 + + ChangeLog@1.1450 +1 -0 + NTP_4_2_7P431 + + ntpd/invoke-ntp.conf.texi@1.109 +1 -1 + NTP_4_2_7P431 + + ntpd/invoke-ntp.keys.texi@1.107 +1 -1 + NTP_4_2_7P431 + + ntpd/invoke-ntpd.texi@1.423 +2 -2 + NTP_4_2_7P431 + + ntpd/ntp.conf.5man@1.143 +7 -7 + NTP_4_2_7P431 + + ntpd/ntp.conf.5mdoc@1.143 +3 -3 + NTP_4_2_7P431 + + ntpd/ntp.conf.html@1.104 +1 -1 + NTP_4_2_7P431 + + ntpd/ntp.conf.man.in@1.143 +7 -7 + NTP_4_2_7P431 + + ntpd/ntp.conf.mdoc.in@1.143 +3 -3 + NTP_4_2_7P431 + + ntpd/ntp.keys.5man@1.141 +3 -3 + NTP_4_2_7P431 + + ntpd/ntp.keys.5mdoc@1.141 +3 -3 + NTP_4_2_7P431 + + ntpd/ntp.keys.html@1.105 +1 -1 + NTP_4_2_7P431 + + ntpd/ntp.keys.man.in@1.141 +3 -3 + NTP_4_2_7P431 + + ntpd/ntp.keys.mdoc.in@1.141 +3 -3 + NTP_4_2_7P431 + + ntpd/ntpd-opts.c@1.441 +7 -7 + NTP_4_2_7P431 + + ntpd/ntpd-opts.h@1.441 +3 -3 + NTP_4_2_7P431 + + ntpd/ntpd.1ntpdman@1.252 +7 -7 + NTP_4_2_7P431 + + ntpd/ntpd.1ntpdmdoc@1.252 +3 -3 + NTP_4_2_7P431 + + ntpd/ntpd.html@1.99 +2 -2 + NTP_4_2_7P431 + + ntpd/ntpd.man.in@1.252 +7 -7 + NTP_4_2_7P431 + + ntpd/ntpd.mdoc.in@1.252 +3 -3 + NTP_4_2_7P431 + + ntpdc/invoke-ntpdc.texi@1.421 +2 -2 + NTP_4_2_7P431 + + ntpdc/ntpdc-opts.c@1.436 +7 -7 + NTP_4_2_7P431 + + ntpdc/ntpdc-opts.h@1.436 +3 -3 + NTP_4_2_7P431 + + ntpdc/ntpdc.1ntpdcman@1.252 +6 -6 + NTP_4_2_7P431 + + ntpdc/ntpdc.1ntpdcmdoc@1.252 +2 -2 + NTP_4_2_7P431 + + ntpdc/ntpdc.html@1.265 +2 -2 + NTP_4_2_7P431 + + ntpdc/ntpdc.man.in@1.252 +6 -6 + NTP_4_2_7P431 + + ntpdc/ntpdc.mdoc.in@1.252 +2 -2 + NTP_4_2_7P431 + + ntpq/invoke-ntpq.texi@1.424 +2 -2 + NTP_4_2_7P431 + + ntpq/ntpq-opts.c@1.438 +7 -7 + NTP_4_2_7P431 + + ntpq/ntpq-opts.h@1.438 +3 -3 + NTP_4_2_7P431 + + ntpq/ntpq.1ntpqman@1.252 +6 -6 + NTP_4_2_7P431 + + ntpq/ntpq.1ntpqmdoc@1.252 +2 -2 + NTP_4_2_7P431 + + ntpq/ntpq.html@1.96 +2 -2 + NTP_4_2_7P431 + + ntpq/ntpq.man.in@1.252 +6 -6 + NTP_4_2_7P431 + + ntpq/ntpq.mdoc.in@1.252 +2 -2 + NTP_4_2_7P431 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.423 +2 -2 + NTP_4_2_7P431 + + ntpsnmpd/ntpsnmpd-opts.c@1.438 +7 -7 + NTP_4_2_7P431 + + ntpsnmpd/ntpsnmpd-opts.h@1.438 +3 -3 + NTP_4_2_7P431 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.252 +7 -7 + NTP_4_2_7P431 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.252 +3 -3 + NTP_4_2_7P431 + + ntpsnmpd/ntpsnmpd.html@1.94 +1 -1 + NTP_4_2_7P431 + + ntpsnmpd/ntpsnmpd.man.in@1.252 +7 -7 + NTP_4_2_7P431 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.252 +3 -3 + NTP_4_2_7P431 + + packageinfo.sh@1.435 +1 -1 + NTP_4_2_7P431 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.14 +6 -6 + NTP_4_2_7P431 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.14 +2 -2 + NTP_4_2_7P431 + + scripts/calc_tickadj/calc_tickadj.html@1.13 +1 -1 + NTP_4_2_7P431 + + scripts/calc_tickadj/calc_tickadj.man.in@1.13 +6 -6 + NTP_4_2_7P431 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.14 +2 -2 + NTP_4_2_7P431 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.15 +1 -1 + NTP_4_2_7P431 + + scripts/invoke-plot_summary.texi@1.32 +1 -1 + NTP_4_2_7P431 + + scripts/invoke-summary.texi@1.32 +1 -1 + NTP_4_2_7P431 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.241 +1 -1 + NTP_4_2_7P431 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.242 +6 -6 + NTP_4_2_7P431 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.242 +2 -2 + NTP_4_2_7P431 + + scripts/ntp-wait/ntp-wait.html@1.258 +1 -1 + NTP_4_2_7P431 + + scripts/ntp-wait/ntp-wait.man.in@1.242 +6 -6 + NTP_4_2_7P431 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.242 +2 -2 + NTP_4_2_7P431 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.30 +1 -1 + NTP_4_2_7P431 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.21 +6 -6 + NTP_4_2_7P431 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.21 +2 -2 + NTP_4_2_7P431 + + scripts/ntpsweep/ntpsweep.html@1.31 +1 -1 + NTP_4_2_7P431 + + scripts/ntpsweep/ntpsweep.man.in@1.21 +6 -6 + NTP_4_2_7P431 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.22 +2 -2 + NTP_4_2_7P431 + + scripts/ntptrace/invoke-ntptrace.texi@1.30 +1 -1 + NTP_4_2_7P431 + + scripts/ntptrace/ntptrace.1ntptraceman@1.21 +13 -13 + NTP_4_2_7P431 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.21 +2 -2 + NTP_4_2_7P431 + + scripts/ntptrace/ntptrace.html@1.31 +1 -1 + NTP_4_2_7P431 + + scripts/ntptrace/ntptrace.man.in@1.21 +13 -13 + NTP_4_2_7P431 + + scripts/ntptrace/ntptrace.mdoc.in@1.22 +2 -2 + NTP_4_2_7P431 + + scripts/plot_summary.1plot_summaryman@1.32 +6 -6 + NTP_4_2_7P431 + + scripts/plot_summary.1plot_summarymdoc@1.32 +3 -3 + NTP_4_2_7P431 + + scripts/plot_summary.html@1.32 +1 -1 + NTP_4_2_7P431 + + scripts/plot_summary.man.in@1.32 +6 -6 + NTP_4_2_7P431 + + scripts/plot_summary.mdoc.in@1.32 +3 -3 + NTP_4_2_7P431 + + scripts/summary.1summaryman@1.32 +6 -6 + NTP_4_2_7P431 + + scripts/summary.1summarymdoc@1.32 +2 -2 + NTP_4_2_7P431 + + scripts/summary.html@1.32 +1 -1 + NTP_4_2_7P431 + + scripts/summary.man.in@1.32 +6 -6 + NTP_4_2_7P431 + + scripts/summary.mdoc.in@1.32 +2 -2 + NTP_4_2_7P431 + + sntp/invoke-sntp.texi@1.420 +2 -2 + NTP_4_2_7P431 + + sntp/sntp-opts.c@1.435 +7 -7 + NTP_4_2_7P431 + + sntp/sntp-opts.h@1.435 +3 -3 + NTP_4_2_7P431 + + sntp/sntp.1sntpman@1.255 +7 -7 + NTP_4_2_7P431 + + sntp/sntp.1sntpmdoc@1.255 +3 -3 + NTP_4_2_7P431 + + sntp/sntp.html@1.435 +2 -2 + NTP_4_2_7P431 + + sntp/sntp.man.in@1.255 +7 -7 + NTP_4_2_7P431 + + sntp/sntp.mdoc.in@1.255 +3 -3 + NTP_4_2_7P431 + + util/invoke-ntp-keygen.texi@1.424 +2 -2 + NTP_4_2_7P431 + + util/ntp-keygen-opts.c@1.438 +7 -7 + NTP_4_2_7P431 + + util/ntp-keygen-opts.h@1.438 +3 -3 + NTP_4_2_7P431 + + util/ntp-keygen.1ntp-keygenman@1.252 +7 -7 + NTP_4_2_7P431 + + util/ntp-keygen.1ntp-keygenmdoc@1.252 +3 -3 + NTP_4_2_7P431 + + util/ntp-keygen.html@1.100 +2 -2 + NTP_4_2_7P431 + + util/ntp-keygen.man.in@1.252 +7 -7 + NTP_4_2_7P431 + + util/ntp-keygen.mdoc.in@1.252 +3 -3 + NTP_4_2_7P431 + +ChangeSet@1.3107.1.15, 2014-03-05 01:44:37-05:00, stenn@deacon.udel.edu + [Bug 2572] cross-compiling fails for --with-yielding-select + + ChangeLog@1.1449 +1 -0 + [Bug 2572] cross-compiling fails for --with-yielding-select + + sntp/libevent/m4/openldap-thread-check.m4@1.4 +1 -1 + [Bug 2572] cross-compiling fails for --with-yielding-select + +ChangeSet@1.3107.1.14, 2014-03-05 00:53:47-05:00, stenn@deacon.udel.edu + CID 711669: Do a non-NULL pointer assertion check a bit earlier + + ChangeLog@1.1448 +1 -0 + CID 711669: Do a non-NULL pointer assertion check a bit earlier + + sntp/libevent/event.c@1.11 +1 -1 + CID 711669: Do a non-NULL pointer assertion check a bit earlier + +ChangeSet@1.3107.1.13, 2014-03-04 11:54:12+00:00, stenn@deacon.udel.edu + NTP_4_2_7P430 + TAG: NTP_4_2_7P430 + + ChangeLog@1.1447 +1 -0 + NTP_4_2_7P430 + + ntpd/invoke-ntp.conf.texi@1.108 +1 -1 + NTP_4_2_7P430 + + ntpd/invoke-ntp.keys.texi@1.106 +1 -1 + NTP_4_2_7P430 + + ntpd/invoke-ntpd.texi@1.422 +2 -2 + NTP_4_2_7P430 + + ntpd/ntp.conf.5man@1.142 +7 -7 + NTP_4_2_7P430 + + ntpd/ntp.conf.5mdoc@1.142 +3 -3 + NTP_4_2_7P430 + + ntpd/ntp.conf.html@1.103 +1 -1 + NTP_4_2_7P430 + + ntpd/ntp.conf.man.in@1.142 +7 -7 + NTP_4_2_7P430 + + ntpd/ntp.conf.mdoc.in@1.142 +3 -3 + NTP_4_2_7P430 + + ntpd/ntp.keys.5man@1.140 +3 -3 + NTP_4_2_7P430 + + ntpd/ntp.keys.5mdoc@1.140 +3 -3 + NTP_4_2_7P430 + + ntpd/ntp.keys.html@1.104 +1 -1 + NTP_4_2_7P430 + + ntpd/ntp.keys.man.in@1.140 +3 -3 + NTP_4_2_7P430 + + ntpd/ntp.keys.mdoc.in@1.140 +3 -3 + NTP_4_2_7P430 + + ntpd/ntpd-opts.c@1.440 +7 -7 + NTP_4_2_7P430 + + ntpd/ntpd-opts.h@1.440 +3 -3 + NTP_4_2_7P430 + + ntpd/ntpd.1ntpdman@1.251 +1007 -0 + NTP_4_2_7P430 + + ntpd/ntpd.1ntpdmdoc@1.251 +3 -3 + NTP_4_2_7P430 + + ntpd/ntpd.html@1.98 +2 -2 + NTP_4_2_7P430 + + ntpd/ntpd.man.in@1.251 +1007 -0 + NTP_4_2_7P430 + + ntpd/ntpd.mdoc.in@1.251 +3 -3 + NTP_4_2_7P430 + + ntpdc/invoke-ntpdc.texi@1.420 +2 -2 + NTP_4_2_7P430 + + ntpdc/ntpdc-opts.c@1.435 +7 -7 + NTP_4_2_7P430 + + ntpdc/ntpdc-opts.h@1.435 +3 -3 + NTP_4_2_7P430 + + ntpdc/ntpdc.1ntpdcman@1.251 +6 -6 + NTP_4_2_7P430 + + ntpdc/ntpdc.1ntpdcmdoc@1.251 +2 -2 + NTP_4_2_7P430 + + ntpdc/ntpdc.html@1.264 +2 -2 + NTP_4_2_7P430 + + ntpdc/ntpdc.man.in@1.251 +6 -6 + NTP_4_2_7P430 + + ntpdc/ntpdc.mdoc.in@1.251 +2 -2 + NTP_4_2_7P430 + + ntpq/invoke-ntpq.texi@1.423 +2 -2 + NTP_4_2_7P430 + + ntpq/ntpq-opts.c@1.437 +7 -7 + NTP_4_2_7P430 + + ntpq/ntpq-opts.h@1.437 +3 -3 + NTP_4_2_7P430 + + ntpq/ntpq.1ntpqman@1.251 +6 -6 + NTP_4_2_7P430 + + ntpq/ntpq.1ntpqmdoc@1.251 +2 -2 + NTP_4_2_7P430 + + ntpq/ntpq.html@1.95 +2 -2 + NTP_4_2_7P430 + + ntpq/ntpq.man.in@1.251 +6 -6 + NTP_4_2_7P430 + + ntpq/ntpq.mdoc.in@1.251 +2 -2 + NTP_4_2_7P430 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.422 +2 -2 + NTP_4_2_7P430 + + ntpsnmpd/ntpsnmpd-opts.c@1.437 +7 -7 + NTP_4_2_7P430 + + ntpsnmpd/ntpsnmpd-opts.h@1.437 +3 -3 + NTP_4_2_7P430 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.251 +7 -7 + NTP_4_2_7P430 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.251 +3 -3 + NTP_4_2_7P430 + + ntpsnmpd/ntpsnmpd.html@1.93 +1 -1 + NTP_4_2_7P430 + + ntpsnmpd/ntpsnmpd.man.in@1.251 +7 -7 + NTP_4_2_7P430 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.251 +3 -3 + NTP_4_2_7P430 + + packageinfo.sh@1.434 +1 -1 + NTP_4_2_7P430 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.13 +13 -13 + NTP_4_2_7P430 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.13 +2 -2 + NTP_4_2_7P430 + + scripts/calc_tickadj/calc_tickadj.html@1.12 +1 -1 + NTP_4_2_7P430 + + scripts/calc_tickadj/calc_tickadj.man.in@1.12 +13 -13 + NTP_4_2_7P430 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.13 +2 -2 + NTP_4_2_7P430 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.14 +1 -1 + NTP_4_2_7P430 + + scripts/invoke-plot_summary.texi@1.31 +1 -1 + NTP_4_2_7P430 + + scripts/invoke-summary.texi@1.31 +1 -1 + NTP_4_2_7P430 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.240 +1 -1 + NTP_4_2_7P430 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.241 +6 -6 + NTP_4_2_7P430 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.241 +2 -2 + NTP_4_2_7P430 + + scripts/ntp-wait/ntp-wait.html@1.257 +1 -1 + NTP_4_2_7P430 + + scripts/ntp-wait/ntp-wait.man.in@1.241 +6 -6 + NTP_4_2_7P430 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.241 +2 -2 + NTP_4_2_7P430 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.29 +1 -1 + NTP_4_2_7P430 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.20 +6 -6 + NTP_4_2_7P430 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.20 +2 -2 + NTP_4_2_7P430 + + scripts/ntpsweep/ntpsweep.html@1.30 +1 -1 + NTP_4_2_7P430 + + scripts/ntpsweep/ntpsweep.man.in@1.20 +6 -6 + NTP_4_2_7P430 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.21 +2 -2 + NTP_4_2_7P430 + + scripts/ntptrace/invoke-ntptrace.texi@1.29 +1 -1 + NTP_4_2_7P430 + + scripts/ntptrace/ntptrace.1ntptraceman@1.20 +13 -13 + NTP_4_2_7P430 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.20 +2 -2 + NTP_4_2_7P430 + + scripts/ntptrace/ntptrace.html@1.30 +1 -1 + NTP_4_2_7P430 + + scripts/ntptrace/ntptrace.man.in@1.20 +13 -13 + NTP_4_2_7P430 + + scripts/ntptrace/ntptrace.mdoc.in@1.21 +2 -2 + NTP_4_2_7P430 + + scripts/plot_summary.1plot_summaryman@1.31 +6 -6 + NTP_4_2_7P430 + + scripts/plot_summary.1plot_summarymdoc@1.31 +3 -3 + NTP_4_2_7P430 + + scripts/plot_summary.html@1.31 +1 -1 + NTP_4_2_7P430 + + scripts/plot_summary.man.in@1.31 +6 -6 + NTP_4_2_7P430 + + scripts/plot_summary.mdoc.in@1.31 +3 -3 + NTP_4_2_7P430 + + scripts/summary.1summaryman@1.31 +6 -6 + NTP_4_2_7P430 + + scripts/summary.1summarymdoc@1.31 +2 -2 + NTP_4_2_7P430 + + scripts/summary.html@1.31 +1 -1 + NTP_4_2_7P430 + + scripts/summary.man.in@1.31 +6 -6 + NTP_4_2_7P430 + + scripts/summary.mdoc.in@1.31 +2 -2 + NTP_4_2_7P430 + + sntp/invoke-sntp.texi@1.419 +2 -2 + NTP_4_2_7P430 + + sntp/sntp-opts.c@1.434 +7 -7 + NTP_4_2_7P430 + + sntp/sntp-opts.h@1.434 +3 -3 + NTP_4_2_7P430 + + sntp/sntp.1sntpman@1.254 +7 -7 + NTP_4_2_7P430 + + sntp/sntp.1sntpmdoc@1.254 +3 -3 + NTP_4_2_7P430 + + sntp/sntp.html@1.434 +2 -2 + NTP_4_2_7P430 + + sntp/sntp.man.in@1.254 +7 -7 + NTP_4_2_7P430 + + sntp/sntp.mdoc.in@1.254 +3 -3 + NTP_4_2_7P430 + + util/invoke-ntp-keygen.texi@1.423 +2 -2 + NTP_4_2_7P430 + + util/ntp-keygen-opts.c@1.437 +7 -7 + NTP_4_2_7P430 + + util/ntp-keygen-opts.h@1.437 +3 -3 + NTP_4_2_7P430 + + util/ntp-keygen.1ntp-keygenman@1.251 +7 -7 + NTP_4_2_7P430 + + util/ntp-keygen.1ntp-keygenmdoc@1.251 +3 -3 + NTP_4_2_7P430 + + util/ntp-keygen.html@1.99 +2 -2 + NTP_4_2_7P430 + + util/ntp-keygen.man.in@1.251 +7 -7 + NTP_4_2_7P430 + + util/ntp-keygen.mdoc.in@1.251 +3 -3 + NTP_4_2_7P430 + +ChangeSet@1.3107.1.12, 2014-03-04 01:43:16-08:00, harlan@hms-mbp11.local + [Bug 2572] cross-compiling fails for --with-yielding-select + + sntp/libevent/configure.ac@1.16 +2 -0 + [Bug 2572] cross-compiling fails for --with-yielding-select + +ChangeSet@1.3107.1.11, 2014-03-04 01:36:37-08:00, harlan@hms-mbp11.local + [Bug 2572] cross-compiling fails for --with-yielding-select + + ChangeLog@1.1446 +1 -0 + [Bug 2572] cross-compiling fails for --with-yielding-select + + sntp/libevent/configure.ac@1.15 +16 -10 + [Bug 2572] cross-compiling fails for --with-yielding-select + + sntp/libevent/m4/openldap-thread-check.m4@1.3 +4 -2 + [Bug 2572] cross-compiling fails for --with-yielding-select + +ChangeSet@1.3107.1.10, 2014-03-04 00:36:34-08:00, harlan@hms-mbp11.local + Upgrade to libevent-2.1.3-alpha-dev + + BitKeeper/deleted/17/evconfig-private.h~e326850fdeaa98a0@1.3 +0 -0 + Delete: sntp/libevent/WIN32-Code/evconfig-private.h + + BitKeeper/deleted/1d/test-ratelim.sh~dddafffaaeb54e28@1.4 +0 -0 + Delete: sntp/libevent/test/test-ratelim.sh + + BitKeeper/deleted/27/event.3~f0ceb5963a3e2eb2@1.2 +0 -0 + Delete: sntp/libevent/event.3 + + BitKeeper/deleted/5d/make_epoll_table.py~9cb592404263d3ec@1.3 +0 -0 + Delete: sntp/libevent/make_epoll_table.py + + BitKeeper/deleted/5e/CommitLog~8348099c640278eb@1.3 +0 -0 + Delete: sntp/libevent/CommitLog + + BitKeeper/deleted/a5/event-config.h~b5f19946803cd6c3@1.7 +0 -0 + Delete: sntp/libevent/WIN32-Code/event2/event-config.h + + BitKeeper/deleted/ae/print-winsock-errors.c~9a8c717f5ec35467@1.2 +0 -0 + Delete: sntp/libevent/test/print-winsock-errors.c + + BitKeeper/deleted/c5/tinytest_demo.c~ce8c6418b673bdfe@1.4 +0 -0 + Delete: sntp/libevent/test/tinytest_demo.c + + BitKeeper/deleted/d8/evdns.3~b3752932bb1e0709@1.2 +0 -0 + Delete: sntp/libevent/evdns.3 + + BitKeeper/etc/ignore@1.85 +1 -0 + added sntp/libevent/build-aux/ar-lib + + ChangeLog@1.1445 +1 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/ChangeLog@1.8 +257 -1 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/Makefile.am@1.12 +10 -7 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/Makefile.nmake@1.5 +1 -1 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/WIN32-Code/nmake/evconfig-private.h@1.1 +6 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/WIN32-Code/nmake/evconfig-private.h + + sntp/libevent/WIN32-Code/nmake/evconfig-private.h@1.0 +0 -0 + + sntp/libevent/WIN32-Code/nmake/event2/event-config.h@1.1 +360 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/WIN32-Code/nmake/event2/event-config.h + + sntp/libevent/WIN32-Code/nmake/event2/event-config.h@1.0 +0 -0 + + sntp/libevent/arc4random.c@1.6 +36 -20 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/buffer.c@1.9 +36 -8 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent-internal.h@1.7 +34 -10 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent.c@1.7 +119 -44 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent_async.c@1.6 +10 -17 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent_filter.c@1.6 +16 -11 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent_openssl.c@1.8 +46 -37 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent_pair.c@1.7 +10 -17 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent_ratelim.c@1.5 +22 -5 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/bufferevent_sock.c@1.7 +16 -20 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/changelist-internal.h@1.3 +1 -0 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/configure.ac@1.14 +28 -22 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/epoll.c@1.6 +33 -176 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/epoll_sub.c@1.4 +13 -0 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/epolltable-internal.h@1.1 +1166 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/epolltable-internal.h + + sntp/libevent/epolltable-internal.h@1.0 +0 -0 + + sntp/libevent/evbuffer-internal.h@1.7 +5 -0 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/evconfig-private.h@1.1 +49 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/evconfig-private.h + + sntp/libevent/evconfig-private.h@1.0 +0 -0 + + sntp/libevent/evdns.c@1.9 +87 -37 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/event-internal.h@1.9 +45 -3 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/event.c@1.10 +381 -69 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/event_iocp.c@1.6 +4 -1 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/evmap.c@1.7 +54 -13 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/evrpc.c@1.6 +5 -9 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/evutil.c@1.9 +25 -9 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/evutil_rand.c@1.7 +26 -3 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/evutil_time.c@1.4 +14 -3 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/http-internal.h@1.5 +10 -9 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/http.c@1.9 +116 -28 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/include/event2/buffer.h@1.6 +59 -5 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/buffer_compat.h@1.4 +5 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/bufferevent.h@1.5 +123 -3 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/bufferevent_ssl.h@1.4 +8 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/dns.h@1.6 +59 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/event.h@1.9 +266 -15 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/event_compat.h@1.5 +10 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/event_struct.h@1.5 +8 -3 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/http.h@1.6 +209 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/http_struct.h@1.4 +22 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/listener.h@1.3 +11 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/tag.h@1.4 +22 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/thread.h@1.6 +10 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/util.h@1.6 +47 -3 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/include/event2/visibility.h@1.1 +55 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/include/event2/visibility.h + + sntp/libevent/include/event2/visibility.h@1.0 +0 -0 + + sntp/libevent/include/include.am@1.2 +2 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/log-internal.h@1.3 +3 -0 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/log.c@1.6 +13 -12 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/m4/acx_pthread.m4@1.1 +279 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/m4/acx_pthread.m4 + + sntp/libevent/m4/acx_pthread.m4@1.0 +0 -0 + + sntp/libevent/minheap-internal.h@1.6 +1 -1 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/sample/dns-example.c@1.7 +2 -2 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/sample/hostcheck.c@1.1 +217 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/sample/hostcheck.c + + sntp/libevent/sample/hostcheck.c@1.0 +0 -0 + + sntp/libevent/sample/hostcheck.h@1.1 +30 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/sample/hostcheck.h + + sntp/libevent/sample/hostcheck.h@1.0 +0 -0 + + sntp/libevent/sample/http-server.c@1.9 +2 -2 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/sample/https-client.c@1.1 +426 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/sample/https-client.c + + sntp/libevent/sample/https-client.c@1.0 +0 -0 + + sntp/libevent/sample/include.am@1.2 +12 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/sample/le-proxy.c@1.3 +10 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/sample/openssl_hostname_validation.c@1.1 +172 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/sample/openssl_hostname_validation.c + + sntp/libevent/sample/openssl_hostname_validation.c@1.0 +0 -0 + + sntp/libevent/sample/openssl_hostname_validation.h@1.1 +56 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/sample/openssl_hostname_validation.h + + sntp/libevent/sample/openssl_hostname_validation.h@1.0 +0 -0 + + sntp/libevent/test/Makefile.nmake@1.5 +7 -5 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/bench.c@1.5 +15 -4 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/bench_cascade.c@1.5 +15 -6 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/bench_http.c@1.5 +6 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/include.am@1.3 +11 -10 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress.c@1.5 +604 -7 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress.h@1.4 +3 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_buffer.c@1.7 +15 -14 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_bufferevent.c@1.5 +159 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_dns.c@1.7 +68 -8 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_et.c@1.5 +2 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_finalize.c@1.1 +346 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/test/regress_finalize.c + + sntp/libevent/test/regress_finalize.c@1.0 +0 -0 + + sntp/libevent/test/regress_http.c@1.7 +215 -18 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_main.c@1.6 +12 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_rpc.c@1.6 +8 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_ssl.c@1.6 +5 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_thread.c@1.5 +1 -18 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/regress_thread.h@1.1 +48 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/test/regress_thread.h + + sntp/libevent/test/regress_thread.h@1.0 +0 -0 + + sntp/libevent/test/regress_util.c@1.6 +1 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/rpcgen_wrapper.sh@1.4 +2 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/test-changelist.c@1.5 +2 -1 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/test-closed.c@1.1 +117 -0 + BitKeeper file /Users/harlan/src/ntp-dev-libevent/sntp/libevent/test/test-closed.c + + sntp/libevent/test/test-closed.c@1.0 +0 -0 + + sntp/libevent/test/test-ratelim.c@1.8 +2 -0 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/test/test.sh@1.10 +3 -10 + Upgrade to libevent-2.1.3-alpha-dev + + sntp/libevent/util-internal.h@1.9 +4 -0 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/whatsnew-2.1.txt@1.3 +125 -7 + upgrade to libevent 2.1.3-alpha-dev + + sntp/libevent/win32select.c@1.5 +1 -1 + upgrade to libevent 2.1.3-alpha-dev + +ChangeSet@1.3107.1.9, 2014-03-03 11:15:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P429 + TAG: NTP_4_2_7P429 + + ChangeLog@1.1444 +1 -0 + NTP_4_2_7P429 + + ntpd/invoke-ntp.conf.texi@1.107 +1 -1 + NTP_4_2_7P429 + + ntpd/invoke-ntp.keys.texi@1.105 +1 -1 + NTP_4_2_7P429 + + ntpd/invoke-ntpd.texi@1.421 +2 -2 + NTP_4_2_7P429 + + ntpd/ntp.conf.5man@1.141 +7 -7 + NTP_4_2_7P429 + + ntpd/ntp.conf.5mdoc@1.141 +3 -3 + NTP_4_2_7P429 + + ntpd/ntp.conf.html@1.102 +1 -1 + NTP_4_2_7P429 + + ntpd/ntp.conf.man.in@1.141 +7 -7 + NTP_4_2_7P429 + + ntpd/ntp.conf.mdoc.in@1.141 +3 -3 + NTP_4_2_7P429 + + ntpd/ntp.keys.5man@1.139 +3 -3 + NTP_4_2_7P429 + + ntpd/ntp.keys.5mdoc@1.139 +3 -3 + NTP_4_2_7P429 + + ntpd/ntp.keys.html@1.103 +1 -1 + NTP_4_2_7P429 + + ntpd/ntp.keys.man.in@1.139 +3 -3 + NTP_4_2_7P429 + + ntpd/ntp.keys.mdoc.in@1.139 +3 -3 + NTP_4_2_7P429 + + ntpd/ntpd-opts.c@1.439 +7 -7 + NTP_4_2_7P429 + + ntpd/ntpd-opts.h@1.439 +3 -3 + NTP_4_2_7P429 + + ntpd/ntpd.1ntpdman@1.250 +0 -1007 + NTP_4_2_7P429 + + ntpd/ntpd.1ntpdmdoc@1.250 +3 -3 + NTP_4_2_7P429 + + ntpd/ntpd.html@1.97 +2 -2 + NTP_4_2_7P429 + + ntpd/ntpd.man.in@1.250 +0 -1007 + NTP_4_2_7P429 + + ntpd/ntpd.mdoc.in@1.250 +3 -3 + NTP_4_2_7P429 + + ntpdc/invoke-ntpdc.texi@1.419 +2 -2 + NTP_4_2_7P429 + + ntpdc/ntpdc-opts.c@1.434 +7 -7 + NTP_4_2_7P429 + + ntpdc/ntpdc-opts.h@1.434 +3 -3 + NTP_4_2_7P429 + + ntpdc/ntpdc.1ntpdcman@1.250 +6 -6 + NTP_4_2_7P429 + + ntpdc/ntpdc.1ntpdcmdoc@1.250 +2 -2 + NTP_4_2_7P429 + + ntpdc/ntpdc.html@1.263 +2 -2 + NTP_4_2_7P429 + + ntpdc/ntpdc.man.in@1.250 +6 -6 + NTP_4_2_7P429 + + ntpdc/ntpdc.mdoc.in@1.250 +2 -2 + NTP_4_2_7P429 + + ntpq/invoke-ntpq.texi@1.422 +2 -2 + NTP_4_2_7P429 + + ntpq/ntpq-opts.c@1.436 +7 -7 + NTP_4_2_7P429 + + ntpq/ntpq-opts.h@1.436 +3 -3 + NTP_4_2_7P429 + + ntpq/ntpq.1ntpqman@1.250 +6 -6 + NTP_4_2_7P429 + + ntpq/ntpq.1ntpqmdoc@1.250 +2 -2 + NTP_4_2_7P429 + + ntpq/ntpq.html@1.94 +2 -2 + NTP_4_2_7P429 + + ntpq/ntpq.man.in@1.250 +6 -6 + NTP_4_2_7P429 + + ntpq/ntpq.mdoc.in@1.250 +2 -2 + NTP_4_2_7P429 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.421 +2 -2 + NTP_4_2_7P429 + + ntpsnmpd/ntpsnmpd-opts.c@1.436 +7 -7 + NTP_4_2_7P429 + + ntpsnmpd/ntpsnmpd-opts.h@1.436 +3 -3 + NTP_4_2_7P429 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.250 +7 -7 + NTP_4_2_7P429 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.250 +3 -3 + NTP_4_2_7P429 + + ntpsnmpd/ntpsnmpd.html@1.92 +1 -1 + NTP_4_2_7P429 + + ntpsnmpd/ntpsnmpd.man.in@1.250 +7 -7 + NTP_4_2_7P429 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.250 +3 -3 + NTP_4_2_7P429 + + packageinfo.sh@1.433 +1 -1 + NTP_4_2_7P429 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.12 +6 -6 + NTP_4_2_7P429 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.12 +2 -2 + NTP_4_2_7P429 + + scripts/calc_tickadj/calc_tickadj.html@1.11 +1 -1 + NTP_4_2_7P429 + + scripts/calc_tickadj/calc_tickadj.man.in@1.11 +6 -6 + NTP_4_2_7P429 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.12 +2 -2 + NTP_4_2_7P429 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.13 +1 -1 + NTP_4_2_7P429 + + scripts/invoke-plot_summary.texi@1.30 +1 -1 + NTP_4_2_7P429 + + scripts/invoke-summary.texi@1.30 +1 -1 + NTP_4_2_7P429 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.239 +1 -1 + NTP_4_2_7P429 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.240 +6 -6 + NTP_4_2_7P429 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.240 +2 -2 + NTP_4_2_7P429 + + scripts/ntp-wait/ntp-wait.html@1.256 +1 -1 + NTP_4_2_7P429 + + scripts/ntp-wait/ntp-wait.man.in@1.240 +6 -6 + NTP_4_2_7P429 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.240 +2 -2 + NTP_4_2_7P429 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.28 +1 -1 + NTP_4_2_7P429 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.19 +6 -6 + NTP_4_2_7P429 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.19 +2 -2 + NTP_4_2_7P429 + + scripts/ntpsweep/ntpsweep.html@1.29 +1 -1 + NTP_4_2_7P429 + + scripts/ntpsweep/ntpsweep.man.in@1.19 +6 -6 + NTP_4_2_7P429 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.20 +2 -2 + NTP_4_2_7P429 + + scripts/ntptrace/invoke-ntptrace.texi@1.28 +1 -1 + NTP_4_2_7P429 + + scripts/ntptrace/ntptrace.1ntptraceman@1.19 +6 -6 + NTP_4_2_7P429 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.19 +2 -2 + NTP_4_2_7P429 + + scripts/ntptrace/ntptrace.html@1.29 +1 -1 + NTP_4_2_7P429 + + scripts/ntptrace/ntptrace.man.in@1.19 +6 -6 + NTP_4_2_7P429 + + scripts/ntptrace/ntptrace.mdoc.in@1.20 +2 -2 + NTP_4_2_7P429 + + scripts/plot_summary.1plot_summaryman@1.30 +6 -6 + NTP_4_2_7P429 + + scripts/plot_summary.1plot_summarymdoc@1.30 +3 -3 + NTP_4_2_7P429 + + scripts/plot_summary.html@1.30 +1 -1 + NTP_4_2_7P429 + + scripts/plot_summary.man.in@1.30 +6 -6 + NTP_4_2_7P429 + + scripts/plot_summary.mdoc.in@1.30 +3 -3 + NTP_4_2_7P429 + + scripts/summary.1summaryman@1.30 +6 -6 + NTP_4_2_7P429 + + scripts/summary.1summarymdoc@1.30 +2 -2 + NTP_4_2_7P429 + + scripts/summary.html@1.30 +1 -1 + NTP_4_2_7P429 + + scripts/summary.man.in@1.30 +6 -6 + NTP_4_2_7P429 + + scripts/summary.mdoc.in@1.30 +2 -2 + NTP_4_2_7P429 + + sntp/invoke-sntp.texi@1.418 +2 -2 + NTP_4_2_7P429 + + sntp/sntp-opts.c@1.433 +7 -7 + NTP_4_2_7P429 + + sntp/sntp-opts.h@1.433 +3 -3 + NTP_4_2_7P429 + + sntp/sntp.1sntpman@1.253 +7 -7 + NTP_4_2_7P429 + + sntp/sntp.1sntpmdoc@1.253 +3 -3 + NTP_4_2_7P429 + + sntp/sntp.html@1.433 +2 -2 + NTP_4_2_7P429 + + sntp/sntp.man.in@1.253 +7 -7 + NTP_4_2_7P429 + + sntp/sntp.mdoc.in@1.253 +3 -3 + NTP_4_2_7P429 + + util/invoke-ntp-keygen.texi@1.422 +2 -2 + NTP_4_2_7P429 + + util/ntp-keygen-opts.c@1.436 +7 -7 + NTP_4_2_7P429 + + util/ntp-keygen-opts.h@1.436 +3 -3 + NTP_4_2_7P429 + + util/ntp-keygen.1ntp-keygenman@1.250 +7 -7 + NTP_4_2_7P429 + + util/ntp-keygen.1ntp-keygenmdoc@1.250 +3 -3 + NTP_4_2_7P429 + + util/ntp-keygen.html@1.98 +2 -2 + NTP_4_2_7P429 + + util/ntp-keygen.man.in@1.250 +7 -7 + NTP_4_2_7P429 + + util/ntp-keygen.mdoc.in@1.250 +3 -3 + NTP_4_2_7P429 + +ChangeSet@1.3107.1.8, 2014-03-03 09:53:09+00:00, stenn@psp-fb1.ntp.org + [Bug 2170] Use AC_PREPROC_IFELSE instead of AC_EGREP_CPP + + ChangeLog@1.1443 +1 -0 + [Bug 2170] Use AC_PREPROC_IFELSE instead of AC_EGREP_CPP + + configure.ac@1.575 +51 -59 + [Bug 2170] Use AC_PREPROC_IFELSE instead of AC_EGREP_CPP + + sntp/m4/ntp_libntp.m4@1.27 +6 -8 + [Bug 2170] Use AC_PREPROC_IFELSE instead of AC_EGREP_CPP + +ChangeSet@1.3107.2.2, 2014-03-03 09:33:00+00:00, stenn@psp-deb1.ntp.org + Reorder ChangeLog entry + + ChangeLog@1.1440.1.2 +2 -2 + Reorder ChangeLog entry + +ChangeSet@1.3107.2.1, 2014-03-03 10:06:43+01:00, jnperlin@hydra.(none) + * [Bug 2570] refuse to load leapsec file with bad/missing SHA1 hash + -- change reading the hash line code: NIST omits leading zeros. + + ChangeLog@1.1440.1.1 +2 -0 + * [Bug 2570] refuse to load leapsec file with bad/missing SHA1 hash + -- change reading the hash line code: NIST omits leading zeros. + + ntpd/ntp_leapsec.c@1.7 +24 -22 + * [Bug 2570] refuse to load leapsec file with bad/missing SHA1 hash + -- change reading the hash line code: NIST omits leading zeros. + + tests/ntpd/leapsec.cpp@1.7 +74 -0 + * [Bug 2570] refuse to load leapsec file with bad/missing SHA1 hash + -- added test cases for modified hash line read. + +ChangeSet@1.3107.1.6, 2014-03-03 03:37:29-05:00, stenn@deacon.udel.edu + CID 1189401: Use INSIST() instead of a belt-and-suspenders pointer check + + ChangeLog@1.1441 +1 -0 + CID 1189401: Use INSIST() instead of a belt-and-suspenders pointer check + + ntpd/refclock_gpsdjson.c@1.9 +5 -4 + CID 1189401: Use INSIST() instead of a belt-and-suspenders pointer check + +ChangeSet@1.3107.1.5, 2014-03-03 02:34:17-05:00, stenn@deacon.udel.edu + [Bug 2576] refclock_gpsdjson.c doesn't compile if CLOCK_GPSDJSON is not enabled at configure time + + ChangeLog@1.1440 +2 -0 + [Bug 2576] refclock_gpsdjson.c doesn't compile if CLOCK_GPSDJSON is not enabled at configure time + + ntpd/refclock_gpsdjson.c@1.8 +2 -1 + [Bug 2576] refclock_gpsdjson.c doesn't compile if CLOCK_GPSDJSON is not enabled at configure time + +ChangeSet@1.3107.1.4, 2014-03-03 02:04:30-05:00, stenn@deacon.udel.edu + CID 1165098: Remove logically dead code from refclock_true.c + + ChangeLog@1.1439 +1 -0 + CID 1165098: Remove logically dead code from refclock_true.c + + ntpd/refclock_true.c@1.21 +2 -4 + CID 1165098: Remove logically dead code from refclock_true.c + +ChangeSet@1.3107.1.3, 2014-03-02 22:47:14-05:00, stenn@deacon.udel.edu + In ntp_dir_sep.m4, we care about $host_os, not $target_os + + ChangeLog@1.1438 +1 -0 + In ntp_dir_sep.m4, we care about $host_os, not $target_os + + sntp/m4/ntp_dir_sep.m4@1.5 +1 -1 + In ntp_dir_sep.m4, we care about $host_os, not $target_os + +ChangeSet@1.3107.1.2, 2014-03-02 21:45:57-05:00, stenn@deacon.udel.edu + bootstrap script needs to 'touch' files in finer-grained groups + + ChangeLog@1.1437 +1 -0 + bootstrap script needs to 'touch' files in finer-grained groups + + bootstrap@1.47 +3 -0 + bootstrap script needs to 'touch' files in finer-grained groups + +ChangeSet@1.3107.1.1, 2014-03-03 01:58:08+00:00, stenn@deacon.udel.edu + NTP_4_2_7P428 + TAG: NTP_4_2_7P428 + + ChangeLog@1.1436 +1 -0 + NTP_4_2_7P428 + + ntpd/invoke-ntp.conf.texi@1.106 +1 -1 + NTP_4_2_7P428 + + ntpd/invoke-ntp.keys.texi@1.104 +1 -1 + NTP_4_2_7P428 + + ntpd/invoke-ntpd.texi@1.420 +2 -2 + NTP_4_2_7P428 + + ntpd/ntp.conf.5man@1.140 +7 -7 + NTP_4_2_7P428 + + ntpd/ntp.conf.5mdoc@1.140 +2 -2 + NTP_4_2_7P428 + + ntpd/ntp.conf.html@1.101 +1 -1 + NTP_4_2_7P428 + + ntpd/ntp.conf.man.in@1.140 +7 -7 + NTP_4_2_7P428 + + ntpd/ntp.conf.mdoc.in@1.140 +2 -2 + NTP_4_2_7P428 + + ntpd/ntp.keys.5man@1.138 +3 -3 + NTP_4_2_7P428 + + ntpd/ntp.keys.5mdoc@1.138 +2 -2 + NTP_4_2_7P428 + + ntpd/ntp.keys.html@1.102 +1 -1 + NTP_4_2_7P428 + + ntpd/ntp.keys.man.in@1.138 +3 -3 + NTP_4_2_7P428 + + ntpd/ntp.keys.mdoc.in@1.138 +2 -2 + NTP_4_2_7P428 + + ntpd/ntpd-opts.c@1.438 +7 -7 + NTP_4_2_7P428 + + ntpd/ntpd-opts.h@1.438 +3 -3 + NTP_4_2_7P428 + + ntpd/ntpd.1ntpdman@1.249 +7 -7 + NTP_4_2_7P428 + + ntpd/ntpd.1ntpdmdoc@1.249 +2 -2 + NTP_4_2_7P428 + + ntpd/ntpd.html@1.96 +2 -2 + NTP_4_2_7P428 + + ntpd/ntpd.man.in@1.249 +7 -7 + NTP_4_2_7P428 + + ntpd/ntpd.mdoc.in@1.249 +2 -2 + NTP_4_2_7P428 + + ntpdc/invoke-ntpdc.texi@1.418 +2 -2 + NTP_4_2_7P428 + + ntpdc/ntpdc-opts.c@1.433 +7 -7 + NTP_4_2_7P428 + + ntpdc/ntpdc-opts.h@1.433 +3 -3 + NTP_4_2_7P428 + + ntpdc/ntpdc.1ntpdcman@1.249 +6 -6 + NTP_4_2_7P428 + + ntpdc/ntpdc.1ntpdcmdoc@1.249 +1 -1 + NTP_4_2_7P428 + + ntpdc/ntpdc.html@1.262 +2 -2 + NTP_4_2_7P428 + + ntpdc/ntpdc.man.in@1.249 +6 -6 + NTP_4_2_7P428 + + ntpdc/ntpdc.mdoc.in@1.249 +1 -1 + NTP_4_2_7P428 + + ntpq/invoke-ntpq.texi@1.421 +2 -2 + NTP_4_2_7P428 + + ntpq/ntpq-opts.c@1.435 +7 -7 + NTP_4_2_7P428 + + ntpq/ntpq-opts.h@1.435 +3 -3 + NTP_4_2_7P428 + + ntpq/ntpq.1ntpqman@1.249 +6 -6 + NTP_4_2_7P428 + + ntpq/ntpq.1ntpqmdoc@1.249 +1 -1 + NTP_4_2_7P428 + + ntpq/ntpq.html@1.93 +2 -2 + NTP_4_2_7P428 + + ntpq/ntpq.man.in@1.249 +6 -6 + NTP_4_2_7P428 + + ntpq/ntpq.mdoc.in@1.249 +1 -1 + NTP_4_2_7P428 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.420 +2 -2 + NTP_4_2_7P428 + + ntpsnmpd/ntpsnmpd-opts.c@1.435 +7 -7 + NTP_4_2_7P428 + + ntpsnmpd/ntpsnmpd-opts.h@1.435 +3 -3 + NTP_4_2_7P428 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.249 +7 -7 + NTP_4_2_7P428 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.249 +2 -2 + NTP_4_2_7P428 + + ntpsnmpd/ntpsnmpd.html@1.91 +1 -1 + NTP_4_2_7P428 + + ntpsnmpd/ntpsnmpd.man.in@1.249 +7 -7 + NTP_4_2_7P428 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.249 +2 -2 + NTP_4_2_7P428 + + packageinfo.sh@1.432 +1 -1 + NTP_4_2_7P428 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.11 +6 -6 + NTP_4_2_7P428 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.11 +2 -2 + NTP_4_2_7P428 + + scripts/calc_tickadj/calc_tickadj.html@1.10 +1 -1 + NTP_4_2_7P428 + + scripts/calc_tickadj/calc_tickadj.man.in@1.10 +6 -6 + NTP_4_2_7P428 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.11 +2 -2 + NTP_4_2_7P428 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.12 +1 -1 + NTP_4_2_7P428 + + scripts/invoke-plot_summary.texi@1.29 +1 -1 + NTP_4_2_7P428 + + scripts/invoke-summary.texi@1.29 +1 -1 + NTP_4_2_7P428 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.238 +1 -1 + NTP_4_2_7P428 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.239 +6 -6 + NTP_4_2_7P428 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.239 +2 -2 + NTP_4_2_7P428 + + scripts/ntp-wait/ntp-wait.html@1.255 +1 -1 + NTP_4_2_7P428 + + scripts/ntp-wait/ntp-wait.man.in@1.239 +6 -6 + NTP_4_2_7P428 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.239 +2 -2 + NTP_4_2_7P428 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.27 +1 -1 + NTP_4_2_7P428 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.18 +6 -6 + NTP_4_2_7P428 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.18 +2 -2 + NTP_4_2_7P428 + + scripts/ntpsweep/ntpsweep.html@1.28 +1 -1 + NTP_4_2_7P428 + + scripts/ntpsweep/ntpsweep.man.in@1.18 +6 -6 + NTP_4_2_7P428 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.19 +2 -2 + NTP_4_2_7P428 + + scripts/ntptrace/invoke-ntptrace.texi@1.27 +1 -1 + NTP_4_2_7P428 + + scripts/ntptrace/ntptrace.1ntptraceman@1.18 +6 -6 + NTP_4_2_7P428 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.18 +2 -2 + NTP_4_2_7P428 + + scripts/ntptrace/ntptrace.html@1.28 +1 -1 + NTP_4_2_7P428 + + scripts/ntptrace/ntptrace.man.in@1.18 +6 -6 + NTP_4_2_7P428 + + scripts/ntptrace/ntptrace.mdoc.in@1.19 +2 -2 + NTP_4_2_7P428 + + scripts/plot_summary.1plot_summaryman@1.29 +6 -6 + NTP_4_2_7P428 + + scripts/plot_summary.1plot_summarymdoc@1.29 +3 -3 + NTP_4_2_7P428 + + scripts/plot_summary.html@1.29 +1 -1 + NTP_4_2_7P428 + + scripts/plot_summary.man.in@1.29 +6 -6 + NTP_4_2_7P428 + + scripts/plot_summary.mdoc.in@1.29 +3 -3 + NTP_4_2_7P428 + + scripts/summary.1summaryman@1.29 +6 -6 + NTP_4_2_7P428 + + scripts/summary.1summarymdoc@1.29 +2 -2 + NTP_4_2_7P428 + + scripts/summary.html@1.29 +1 -1 + NTP_4_2_7P428 + + scripts/summary.man.in@1.29 +6 -6 + NTP_4_2_7P428 + + scripts/summary.mdoc.in@1.29 +2 -2 + NTP_4_2_7P428 + + sntp/invoke-sntp.texi@1.417 +2 -2 + NTP_4_2_7P428 + + sntp/sntp-opts.c@1.432 +7 -7 + NTP_4_2_7P428 + + sntp/sntp-opts.h@1.432 +3 -3 + NTP_4_2_7P428 + + sntp/sntp.1sntpman@1.252 +14 -14 + NTP_4_2_7P428 + + sntp/sntp.1sntpmdoc@1.252 +2 -2 + NTP_4_2_7P428 + + sntp/sntp.html@1.432 +2 -2 + NTP_4_2_7P428 + + sntp/sntp.man.in@1.252 +14 -14 + NTP_4_2_7P428 + + sntp/sntp.mdoc.in@1.252 +2 -2 + NTP_4_2_7P428 + + util/invoke-ntp-keygen.texi@1.421 +2 -2 + NTP_4_2_7P428 + + util/ntp-keygen-opts.c@1.435 +7 -7 + NTP_4_2_7P428 + + util/ntp-keygen-opts.h@1.435 +3 -3 + NTP_4_2_7P428 + + util/ntp-keygen.1ntp-keygenman@1.249 +7 -7 + NTP_4_2_7P428 + + util/ntp-keygen.1ntp-keygenmdoc@1.249 +2 -2 + NTP_4_2_7P428 + + util/ntp-keygen.html@1.97 +2 -2 + NTP_4_2_7P428 + + util/ntp-keygen.man.in@1.249 +7 -7 + NTP_4_2_7P428 + + util/ntp-keygen.mdoc.in@1.249 +2 -2 + NTP_4_2_7P428 + +ChangeSet@1.3103.2.3, 2014-03-02 04:45:25-05:00, stenn@deacon.udel.edu + [Bug 2562] Distribute the code in libjsmn/ + + ChangeLog@1.1432.2.3 +1 -0 + [Bug 2562] Distribute the code in libjsmn/ + + Makefile.am@1.118 +1 -0 + [Bug 2562] Distribute the code in libjsmn/ + +ChangeSet@1.3103.2.2, 2014-03-02 09:11:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P427 + TAG: NTP_4_2_7P427 + + ChangeLog@1.1432.2.2 +1 -0 + NTP_4_2_7P427 + + ntpd/invoke-ntp.conf.texi@1.105 +1 -1 + NTP_4_2_7P427 + + ntpd/invoke-ntp.keys.texi@1.103 +1 -1 + NTP_4_2_7P427 + + ntpd/invoke-ntpd.texi@1.419 +2 -2 + NTP_4_2_7P427 + + ntpd/ntp.conf.5man@1.139 +14 -14 + NTP_4_2_7P427 + + ntpd/ntp.conf.5mdoc@1.139 +3 -3 + NTP_4_2_7P427 + + ntpd/ntp.conf.html@1.100 +1 -1 + NTP_4_2_7P427 + + ntpd/ntp.conf.man.in@1.139 +14 -14 + NTP_4_2_7P427 + + ntpd/ntp.conf.mdoc.in@1.139 +3 -3 + NTP_4_2_7P427 + + ntpd/ntp.keys.5man@1.137 +3 -3 + NTP_4_2_7P427 + + ntpd/ntp.keys.5mdoc@1.137 +3 -3 + NTP_4_2_7P427 + + ntpd/ntp.keys.html@1.101 +1 -1 + NTP_4_2_7P427 + + ntpd/ntp.keys.man.in@1.137 +3 -3 + NTP_4_2_7P427 + + ntpd/ntp.keys.mdoc.in@1.137 +3 -3 + NTP_4_2_7P427 + + ntpd/ntpd-opts.c@1.437 +7 -7 + NTP_4_2_7P427 + + ntpd/ntpd-opts.h@1.437 +3 -3 + NTP_4_2_7P427 + + ntpd/ntpd.1ntpdman@1.248 +7 -7 + NTP_4_2_7P427 + + ntpd/ntpd.1ntpdmdoc@1.248 +3 -3 + NTP_4_2_7P427 + + ntpd/ntpd.html@1.95 +2 -2 + NTP_4_2_7P427 + + ntpd/ntpd.man.in@1.248 +7 -7 + NTP_4_2_7P427 + + ntpd/ntpd.mdoc.in@1.248 +3 -3 + NTP_4_2_7P427 + + ntpdc/invoke-ntpdc.texi@1.417 +2 -2 + NTP_4_2_7P427 + + ntpdc/ntpdc-opts.c@1.432 +7 -7 + NTP_4_2_7P427 + + ntpdc/ntpdc-opts.h@1.432 +3 -3 + NTP_4_2_7P427 + + ntpdc/ntpdc.1ntpdcman@1.248 +13 -13 + NTP_4_2_7P427 + + ntpdc/ntpdc.1ntpdcmdoc@1.248 +2 -2 + NTP_4_2_7P427 + + ntpdc/ntpdc.html@1.261 +2 -2 + NTP_4_2_7P427 + + ntpdc/ntpdc.man.in@1.248 +13 -13 + NTP_4_2_7P427 + + ntpdc/ntpdc.mdoc.in@1.248 +2 -2 + NTP_4_2_7P427 + + ntpq/invoke-ntpq.texi@1.420 +2 -2 + NTP_4_2_7P427 + + ntpq/ntpq-opts.c@1.434 +7 -7 + NTP_4_2_7P427 + + ntpq/ntpq-opts.h@1.434 +3 -3 + NTP_4_2_7P427 + + ntpq/ntpq.1ntpqman@1.248 +13 -13 + NTP_4_2_7P427 + + ntpq/ntpq.1ntpqmdoc@1.248 +2 -2 + NTP_4_2_7P427 + + ntpq/ntpq.html@1.92 +2 -2 + NTP_4_2_7P427 + + ntpq/ntpq.man.in@1.248 +13 -13 + NTP_4_2_7P427 + + ntpq/ntpq.mdoc.in@1.248 +2 -2 + NTP_4_2_7P427 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.419 +2 -2 + NTP_4_2_7P427 + + ntpsnmpd/ntpsnmpd-opts.c@1.434 +7 -7 + NTP_4_2_7P427 + + ntpsnmpd/ntpsnmpd-opts.h@1.434 +3 -3 + NTP_4_2_7P427 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.248 +7 -7 + NTP_4_2_7P427 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.248 +3 -3 + NTP_4_2_7P427 + + ntpsnmpd/ntpsnmpd.html@1.90 +1 -1 + NTP_4_2_7P427 + + ntpsnmpd/ntpsnmpd.man.in@1.248 +7 -7 + NTP_4_2_7P427 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.248 +3 -3 + NTP_4_2_7P427 + + packageinfo.sh@1.431 +1 -1 + NTP_4_2_7P427 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.10 +6 -6 + NTP_4_2_7P427 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.10 +2 -2 + NTP_4_2_7P427 + + scripts/calc_tickadj/calc_tickadj.html@1.9 +1 -1 + NTP_4_2_7P427 + + scripts/calc_tickadj/calc_tickadj.man.in@1.9 +6 -6 + NTP_4_2_7P427 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.10 +2 -2 + NTP_4_2_7P427 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.11 +1 -1 + NTP_4_2_7P427 + + scripts/invoke-plot_summary.texi@1.28 +1 -1 + NTP_4_2_7P427 + + scripts/invoke-summary.texi@1.28 +1 -1 + NTP_4_2_7P427 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.237 +1 -1 + NTP_4_2_7P427 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.238 +6 -6 + NTP_4_2_7P427 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.238 +2 -2 + NTP_4_2_7P427 + + scripts/ntp-wait/ntp-wait.html@1.254 +1 -1 + NTP_4_2_7P427 + + scripts/ntp-wait/ntp-wait.man.in@1.238 +6 -6 + NTP_4_2_7P427 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.238 +2 -2 + NTP_4_2_7P427 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.26 +1 -1 + NTP_4_2_7P427 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.17 +6 -6 + NTP_4_2_7P427 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.17 +2 -2 + NTP_4_2_7P427 + + scripts/ntpsweep/ntpsweep.html@1.27 +1 -1 + NTP_4_2_7P427 + + scripts/ntpsweep/ntpsweep.man.in@1.17 +6 -6 + NTP_4_2_7P427 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.18 +2 -2 + NTP_4_2_7P427 + + scripts/ntptrace/invoke-ntptrace.texi@1.26 +1 -1 + NTP_4_2_7P427 + + scripts/ntptrace/ntptrace.1ntptraceman@1.17 +13 -13 + NTP_4_2_7P427 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.17 +2 -2 + NTP_4_2_7P427 + + scripts/ntptrace/ntptrace.html@1.27 +1 -1 + NTP_4_2_7P427 + + scripts/ntptrace/ntptrace.man.in@1.17 +13 -13 + NTP_4_2_7P427 + + scripts/ntptrace/ntptrace.mdoc.in@1.18 +2 -2 + NTP_4_2_7P427 + + scripts/plot_summary.1plot_summaryman@1.28 +6 -6 + NTP_4_2_7P427 + + scripts/plot_summary.1plot_summarymdoc@1.28 +2 -2 + NTP_4_2_7P427 + + scripts/plot_summary.html@1.28 +1 -1 + NTP_4_2_7P427 + + scripts/plot_summary.man.in@1.28 +6 -6 + NTP_4_2_7P427 + + scripts/plot_summary.mdoc.in@1.28 +2 -2 + NTP_4_2_7P427 + + scripts/summary.1summaryman@1.28 +6 -6 + NTP_4_2_7P427 + + scripts/summary.1summarymdoc@1.28 +2 -2 + NTP_4_2_7P427 + + scripts/summary.html@1.28 +1 -1 + NTP_4_2_7P427 + + scripts/summary.man.in@1.28 +6 -6 + NTP_4_2_7P427 + + scripts/summary.mdoc.in@1.28 +2 -2 + NTP_4_2_7P427 + + sntp/invoke-sntp.texi@1.416 +2 -2 + NTP_4_2_7P427 + + sntp/sntp-opts.c@1.431 +7 -7 + NTP_4_2_7P427 + + sntp/sntp-opts.h@1.431 +3 -3 + NTP_4_2_7P427 + + sntp/sntp.1sntpman@1.251 +14 -14 + NTP_4_2_7P427 + + sntp/sntp.1sntpmdoc@1.251 +3 -3 + NTP_4_2_7P427 + + sntp/sntp.html@1.431 +2 -2 + NTP_4_2_7P427 + + sntp/sntp.man.in@1.251 +14 -14 + NTP_4_2_7P427 + + sntp/sntp.mdoc.in@1.251 +3 -3 + NTP_4_2_7P427 + + util/invoke-ntp-keygen.texi@1.420 +2 -2 + NTP_4_2_7P427 + + util/ntp-keygen-opts.c@1.434 +7 -7 + NTP_4_2_7P427 + + util/ntp-keygen-opts.h@1.434 +3 -3 + NTP_4_2_7P427 + + util/ntp-keygen.1ntp-keygenman@1.248 +7 -7 + NTP_4_2_7P427 + + util/ntp-keygen.1ntp-keygenmdoc@1.248 +3 -3 + NTP_4_2_7P427 + + util/ntp-keygen.html@1.96 +2 -2 + NTP_4_2_7P427 + + util/ntp-keygen.man.in@1.248 +7 -7 + NTP_4_2_7P427 + + util/ntp-keygen.mdoc.in@1.248 +3 -3 + NTP_4_2_7P427 + +ChangeSet@1.3102.1.1, 2014-03-02 09:25:15+01:00, jnperlin@hydra.(none) + [Bug 2562] GPSD_JSON clock: fix build issues with solaris (asprintf(),isfinite()) + + ChangeLog@1.1431.1.1 +1 -0 + [Bug 2562] GPSD_JSON clock: fix build issues with solaris (asprintf(),isfinite()) + + ntpd/refclock_gpsdjson.c@1.7 +40 -14 + [Bug 2562] GPSD_JSON clock: fix build issues with solaris (asprintf(),isfinite()) + +ChangeSet@1.3103.1.1, 2014-03-01 11:52:12+00:00, perlinger@psp-deb1.ntp.org + [Bug 2570] add signature check when reading leapseconds file + + ChangeLog@1.1432.1.1 +1 -0 + [Bug 2570] add signature check when reading leapseconds file + + libntp/Makefile.am@1.71.1.1 +1 -0 + [Bug 2570] add signature check when reading leapseconds file + - include isc/sha1.c in build + + ntpd/ntp_leapsec.c@1.4.1.1 +141 -1 + [Bug 2570] add signature check when reading leapseconds file + - add support functions and plumbing + + ntpd/ntp_leapsec.h@1.3.1.1 +14 -1 + [Bug 2570] add signature check when reading leapseconds file + - define hash validation result definitions + - provide argument how to handle validation results + + + ntpd/ntp_util.c@1.106.1.1 +10 -2 + [Bug 2570] add signature check when reading leapseconds file + - hardwired refusal of files with bad signature (no signature is OK!) + + ports/winnt/vs2008/libntp/libntp.vcproj@1.47.1.1 +7 -3 + [Bug 2570] add signature check when reading leapseconds file + - include isc/sha1.c in build + + tests/ntpd/leapsec.cpp@1.4.1.1 +114 -1 + [Bug 2570] add signature check when reading leapseconds file + - Add test cases for good/missing/bad/malformed SHA1 lines + +ChangeSet@1.3105, 2014-03-01 12:46:15+01:00, jnperlin@hydra.(none) + default + + ntpd/ntp_util.c@1.108 +10 -2 + default + +ChangeSet@1.3104, 2014-03-01 11:13:10+00:00, perlinger@psp-deb1.ntp.org + [Bug 2570] add signature check when reading leapseconds file + - include isc/sha1.c in build + + ChangeLog@1.1433 +1 -0 + [Bug 2570] add signature check when reading leapseconds file + + libntp/Makefile.am@1.72 +1 -0 + [Bug 2570] add signature check when reading leapseconds file + - include isc/sha1.c in build + + ntpd/ntp_leapsec.c@1.5 +141 -1 + [Bug 2570] add signature check when reading leapseconds file + - add support functions and plumbing + + ntpd/ntp_leapsec.h@1.4 +14 -1 + [Bug 2570] add signature check when reading leapseconds file + - define hash validation result definitions + - provide argument how to handle validation results + + + ntpd/ntp_util.c@1.107 +2 -2 + [Bug 2570] add signature check when reading leapseconds file + - hardwired refusal of files without good signature + + ports/winnt/vs2008/libntp/libntp.vcproj@1.48 +7 -3 + [Bug 2570] add signature check when reading leapseconds file + - include isc/sha1.c in build + + tests/ntpd/leapsec.cpp@1.5 +114 -1 + [Bug 2570] add signature check when reading leapseconds file + - Add test cases for good/missing/bad/malformed SHA1 lines + +ChangeSet@1.3093.4.4, 2014-02-28 11:46:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P426 + TAG: NTP_4_2_7P426 + + ChangeLog@1.1430.1.6 +1 -0 + NTP_4_2_7P426 + + ntpd/invoke-ntp.conf.texi@1.104 +1 -1 + NTP_4_2_7P426 + + ntpd/invoke-ntp.keys.texi@1.102 +1 -1 + NTP_4_2_7P426 + + ntpd/invoke-ntpd.texi@1.418 +2 -2 + NTP_4_2_7P426 + + ntpd/ntp.conf.5man@1.138 +14 -14 + NTP_4_2_7P426 + + ntpd/ntp.conf.5mdoc@1.138 +3 -3 + NTP_4_2_7P426 + + ntpd/ntp.conf.html@1.99 +1 -1 + NTP_4_2_7P426 + + ntpd/ntp.conf.man.in@1.138 +14 -14 + NTP_4_2_7P426 + + ntpd/ntp.conf.mdoc.in@1.138 +3 -3 + NTP_4_2_7P426 + + ntpd/ntp.keys.5man@1.136 +3 -3 + NTP_4_2_7P426 + + ntpd/ntp.keys.5mdoc@1.136 +3 -3 + NTP_4_2_7P426 + + ntpd/ntp.keys.html@1.100 +1 -1 + NTP_4_2_7P426 + + ntpd/ntp.keys.man.in@1.136 +3 -3 + NTP_4_2_7P426 + + ntpd/ntp.keys.mdoc.in@1.136 +3 -3 + NTP_4_2_7P426 + + ntpd/ntpd-opts.c@1.436 +7 -7 + NTP_4_2_7P426 + + ntpd/ntpd-opts.h@1.436 +3 -3 + NTP_4_2_7P426 + + ntpd/ntpd.1ntpdman@1.247 +7 -7 + NTP_4_2_7P426 + + ntpd/ntpd.1ntpdmdoc@1.247 +3 -3 + NTP_4_2_7P426 + + ntpd/ntpd.html@1.94 +2 -2 + NTP_4_2_7P426 + + ntpd/ntpd.man.in@1.247 +7 -7 + NTP_4_2_7P426 + + ntpd/ntpd.mdoc.in@1.247 +3 -3 + NTP_4_2_7P426 + + ntpdc/invoke-ntpdc.texi@1.416 +2 -2 + NTP_4_2_7P426 + + ntpdc/ntpdc-opts.c@1.431 +7 -7 + NTP_4_2_7P426 + + ntpdc/ntpdc-opts.h@1.431 +3 -3 + NTP_4_2_7P426 + + ntpdc/ntpdc.1ntpdcman@1.247 +13 -13 + NTP_4_2_7P426 + + ntpdc/ntpdc.1ntpdcmdoc@1.247 +2 -2 + NTP_4_2_7P426 + + ntpdc/ntpdc.html@1.260 +2 -2 + NTP_4_2_7P426 + + ntpdc/ntpdc.man.in@1.247 +13 -13 + NTP_4_2_7P426 + + ntpdc/ntpdc.mdoc.in@1.247 +2 -2 + NTP_4_2_7P426 + + ntpq/invoke-ntpq.texi@1.419 +2 -2 + NTP_4_2_7P426 + + ntpq/ntpq-opts.c@1.433 +7 -7 + NTP_4_2_7P426 + + ntpq/ntpq-opts.h@1.433 +3 -3 + NTP_4_2_7P426 + + ntpq/ntpq.1ntpqman@1.247 +13 -13 + NTP_4_2_7P426 + + ntpq/ntpq.1ntpqmdoc@1.247 +2 -2 + NTP_4_2_7P426 + + ntpq/ntpq.html@1.91 +2 -2 + NTP_4_2_7P426 + + ntpq/ntpq.man.in@1.247 +13 -13 + NTP_4_2_7P426 + + ntpq/ntpq.mdoc.in@1.247 +2 -2 + NTP_4_2_7P426 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.418 +2 -2 + NTP_4_2_7P426 + + ntpsnmpd/ntpsnmpd-opts.c@1.433 +7 -7 + NTP_4_2_7P426 + + ntpsnmpd/ntpsnmpd-opts.h@1.433 +3 -3 + NTP_4_2_7P426 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.247 +7 -7 + NTP_4_2_7P426 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.247 +3 -3 + NTP_4_2_7P426 + + ntpsnmpd/ntpsnmpd.html@1.89 +1 -1 + NTP_4_2_7P426 + + ntpsnmpd/ntpsnmpd.man.in@1.247 +7 -7 + NTP_4_2_7P426 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.247 +3 -3 + NTP_4_2_7P426 + + packageinfo.sh@1.430 +1 -1 + NTP_4_2_7P426 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.9 +13 -13 + NTP_4_2_7P426 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.9 +2 -2 + NTP_4_2_7P426 + + scripts/calc_tickadj/calc_tickadj.html@1.8 +1 -1 + NTP_4_2_7P426 + + scripts/calc_tickadj/calc_tickadj.man.in@1.8 +13 -13 + NTP_4_2_7P426 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.9 +2 -2 + NTP_4_2_7P426 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.10 +1 -1 + NTP_4_2_7P426 + + scripts/invoke-plot_summary.texi@1.27 +1 -1 + NTP_4_2_7P426 + + scripts/invoke-summary.texi@1.27 +1 -1 + NTP_4_2_7P426 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.236 +1 -1 + NTP_4_2_7P426 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.237 +6 -6 + NTP_4_2_7P426 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.237 +2 -2 + NTP_4_2_7P426 + + scripts/ntp-wait/ntp-wait.html@1.253 +1 -1 + NTP_4_2_7P426 + + scripts/ntp-wait/ntp-wait.man.in@1.237 +6 -6 + NTP_4_2_7P426 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.237 +2 -2 + NTP_4_2_7P426 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.25 +1 -1 + NTP_4_2_7P426 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.16 +6 -6 + NTP_4_2_7P426 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.16 +2 -2 + NTP_4_2_7P426 + + scripts/ntpsweep/ntpsweep.html@1.26 +1 -1 + NTP_4_2_7P426 + + scripts/ntpsweep/ntpsweep.man.in@1.16 +6 -6 + NTP_4_2_7P426 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.17 +2 -2 + NTP_4_2_7P426 + + scripts/ntptrace/invoke-ntptrace.texi@1.25 +1 -1 + NTP_4_2_7P426 + + scripts/ntptrace/ntptrace.1ntptraceman@1.16 +13 -13 + NTP_4_2_7P426 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.16 +2 -2 + NTP_4_2_7P426 + + scripts/ntptrace/ntptrace.html@1.26 +1 -1 + NTP_4_2_7P426 + + scripts/ntptrace/ntptrace.man.in@1.16 +13 -13 + NTP_4_2_7P426 + + scripts/ntptrace/ntptrace.mdoc.in@1.17 +2 -2 + NTP_4_2_7P426 + + scripts/plot_summary.1plot_summaryman@1.27 +6 -6 + NTP_4_2_7P426 + + scripts/plot_summary.1plot_summarymdoc@1.27 +2 -2 + NTP_4_2_7P426 + + scripts/plot_summary.html@1.27 +1 -1 + NTP_4_2_7P426 + + scripts/plot_summary.man.in@1.27 +6 -6 + NTP_4_2_7P426 + + scripts/plot_summary.mdoc.in@1.27 +2 -2 + NTP_4_2_7P426 + + scripts/summary.1summaryman@1.27 +6 -6 + NTP_4_2_7P426 + + scripts/summary.1summarymdoc@1.27 +2 -2 + NTP_4_2_7P426 + + scripts/summary.html@1.27 +1 -1 + NTP_4_2_7P426 + + scripts/summary.man.in@1.27 +6 -6 + NTP_4_2_7P426 + + scripts/summary.mdoc.in@1.27 +2 -2 + NTP_4_2_7P426 + + sntp/invoke-sntp.texi@1.415 +2 -2 + NTP_4_2_7P426 + + sntp/sntp-opts.c@1.430 +7 -7 + NTP_4_2_7P426 + + sntp/sntp-opts.h@1.430 +3 -3 + NTP_4_2_7P426 + + sntp/sntp.1sntpman@1.250 +7 -7 + NTP_4_2_7P426 + + sntp/sntp.1sntpmdoc@1.250 +3 -3 + NTP_4_2_7P426 + + sntp/sntp.html@1.430 +2 -2 + NTP_4_2_7P426 + + sntp/sntp.man.in@1.250 +7 -7 + NTP_4_2_7P426 + + sntp/sntp.mdoc.in@1.250 +3 -3 + NTP_4_2_7P426 + + util/invoke-ntp-keygen.texi@1.419 +2 -2 + NTP_4_2_7P426 + + util/ntp-keygen-opts.c@1.433 +7 -7 + NTP_4_2_7P426 + + util/ntp-keygen-opts.h@1.433 +3 -3 + NTP_4_2_7P426 + + util/ntp-keygen.1ntp-keygenman@1.247 +1250 -0 + NTP_4_2_7P426 + + util/ntp-keygen.1ntp-keygenmdoc@1.247 +3 -3 + NTP_4_2_7P426 + + util/ntp-keygen.html@1.95 +2 -2 + NTP_4_2_7P426 + + util/ntp-keygen.man.in@1.247 +1250 -0 + NTP_4_2_7P426 + + util/ntp-keygen.mdoc.in@1.247 +3 -3 + NTP_4_2_7P426 + +ChangeSet@1.3093.4.3, 2014-02-28 06:24:16-05:00, stenn@deacon.udel.edu + test -nt is not portable + + bootstrap@1.46 +7 -2 + test -nt is not portable + +ChangeSet@1.3093.4.2, 2014-02-28 04:20:55-05:00, stenn@deacon.udel.edu + [Bug 2561] Allow wildcards in the target of the "interface" command + + ntpd/ntp_io.c@1.391 +4 -1 + [Bug 2561] Allow wildcards in the target of the "interface" command + +ChangeSet@1.3093.4.1, 2014-02-28 08:14:13+00:00, stenn@psp-fb1.ntp.org + [Bug 2572] cross-compiling fails for --with-yielding_select + + ChangeLog@1.1430.1.5 +1 -0 + [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups + + ChangeLog@1.1430.1.4 +1 -0 + [Bug 2572] cross-compiling fails for --with-yielding_select + + bootstrap@1.45 +3 -0 + [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups. + + sntp/libevent/m4/openldap-thread-check.m4@1.2 +1 -1 + [Bug 2572] cross-compiling fails for --with-yielding_select + +ChangeSet@1.3093.3.2, 2014-02-27 23:55:28-08:00, harlan@hms-mbp11.local + test SCCS date/time keyword expansion for html files + + html/extern.html@1.18 +0 -0 + Turn on SCCS flag + +ChangeSet@1.3093.1.10, 2014-02-28 02:29:49-05:00, stenn@deacon.udel.edu + [Bug 2113] Warn about ignored extra args in ntpq + + ChangeLog@1.1430.1.3 +1 -0 + [Bug 2113] Warn about ignored extra args in ntpq + + ntpq/ntpq-subs.c@1.99 +7 -3 + [Bug 2113] Warn about ignored extra args in ntpq + +ChangeSet@1.3093.3.1, 2014-02-27 22:53:21-08:00, harlan@hms-mbp11.local + test bk keyword expansion + + html/extern.html@1.17 +1 -1 + test bk keyword expansion + +ChangeSet@1.3093.2.1, 2014-02-28 06:37:01+00:00, stenn@psp-fb1.ntp.org + [Bug 2561] Allow wildcards in the target of the "interface" command + + ChangeLog@1.1425.1.1 +1 -0 + [Bug 2561] Allow wildcards in the target of the "interface" command + + configure.ac@1.571.1.2 +2 -2 + [Bug 2561] Allow wildcards in the target of the "interface" command + + ntpd/ntp_io.c@1.390 +9 -1 + [Bug 2561] Allow wildcards in the target of the "interface" command + +ChangeSet@1.3093.1.8, 2014-02-26 10:06:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P425 + TAG: NTP_4_2_7P425 + + ChangeLog@1.1430.1.1 +1 -0 + NTP_4_2_7P425 + + ntpd/invoke-ntp.conf.texi@1.103 +1 -1 + NTP_4_2_7P425 + + ntpd/invoke-ntp.keys.texi@1.101 +1 -1 + NTP_4_2_7P425 + + ntpd/invoke-ntpd.texi@1.417 +2 -2 + NTP_4_2_7P425 + + ntpd/ntp.conf.5man@1.137 +7 -7 + NTP_4_2_7P425 + + ntpd/ntp.conf.5mdoc@1.137 +3 -3 + NTP_4_2_7P425 + + ntpd/ntp.conf.html@1.98 +1 -1 + NTP_4_2_7P425 + + ntpd/ntp.conf.man.in@1.137 +7 -7 + NTP_4_2_7P425 + + ntpd/ntp.conf.mdoc.in@1.137 +3 -3 + NTP_4_2_7P425 + + ntpd/ntp.keys.5man@1.135 +3 -3 + NTP_4_2_7P425 + + ntpd/ntp.keys.5mdoc@1.135 +3 -3 + NTP_4_2_7P425 + + ntpd/ntp.keys.html@1.99 +1 -1 + NTP_4_2_7P425 + + ntpd/ntp.keys.man.in@1.135 +3 -3 + NTP_4_2_7P425 + + ntpd/ntp.keys.mdoc.in@1.135 +3 -3 + NTP_4_2_7P425 + + ntpd/ntpd-opts.c@1.435 +7 -7 + NTP_4_2_7P425 + + ntpd/ntpd-opts.h@1.435 +3 -3 + NTP_4_2_7P425 + + ntpd/ntpd.1ntpdman@1.246 +7 -7 + NTP_4_2_7P425 + + ntpd/ntpd.1ntpdmdoc@1.246 +3 -3 + NTP_4_2_7P425 + + ntpd/ntpd.html@1.93 +2 -2 + NTP_4_2_7P425 + + ntpd/ntpd.man.in@1.246 +7 -7 + NTP_4_2_7P425 + + ntpd/ntpd.mdoc.in@1.246 +3 -3 + NTP_4_2_7P425 + + ntpdc/invoke-ntpdc.texi@1.415 +2 -2 + NTP_4_2_7P425 + + ntpdc/ntpdc-opts.c@1.430 +7 -7 + NTP_4_2_7P425 + + ntpdc/ntpdc-opts.h@1.430 +3 -3 + NTP_4_2_7P425 + + ntpdc/ntpdc.1ntpdcman@1.246 +6 -6 + NTP_4_2_7P425 + + ntpdc/ntpdc.1ntpdcmdoc@1.246 +2 -2 + NTP_4_2_7P425 + + ntpdc/ntpdc.html@1.259 +2 -2 + NTP_4_2_7P425 + + ntpdc/ntpdc.man.in@1.246 +6 -6 + NTP_4_2_7P425 + + ntpdc/ntpdc.mdoc.in@1.246 +2 -2 + NTP_4_2_7P425 + + ntpq/invoke-ntpq.texi@1.418 +2 -2 + NTP_4_2_7P425 + + ntpq/ntpq-opts.c@1.432 +7 -7 + NTP_4_2_7P425 + + ntpq/ntpq-opts.h@1.432 +3 -3 + NTP_4_2_7P425 + + ntpq/ntpq.1ntpqman@1.246 +6 -6 + NTP_4_2_7P425 + + ntpq/ntpq.1ntpqmdoc@1.246 +2 -2 + NTP_4_2_7P425 + + ntpq/ntpq.html@1.90 +2 -2 + NTP_4_2_7P425 + + ntpq/ntpq.man.in@1.246 +6 -6 + NTP_4_2_7P425 + + ntpq/ntpq.mdoc.in@1.246 +2 -2 + NTP_4_2_7P425 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.417 +2 -2 + NTP_4_2_7P425 + + ntpsnmpd/ntpsnmpd-opts.c@1.432 +7 -7 + NTP_4_2_7P425 + + ntpsnmpd/ntpsnmpd-opts.h@1.432 +3 -3 + NTP_4_2_7P425 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.246 +7 -7 + NTP_4_2_7P425 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.246 +3 -3 + NTP_4_2_7P425 + + ntpsnmpd/ntpsnmpd.html@1.88 +1 -1 + NTP_4_2_7P425 + + ntpsnmpd/ntpsnmpd.man.in@1.246 +7 -7 + NTP_4_2_7P425 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.246 +3 -3 + NTP_4_2_7P425 + + packageinfo.sh@1.429 +1 -1 + NTP_4_2_7P425 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.8 +13 -13 + NTP_4_2_7P425 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.8 +2 -2 + NTP_4_2_7P425 + + scripts/calc_tickadj/calc_tickadj.html@1.7 +1 -1 + NTP_4_2_7P425 + + scripts/calc_tickadj/calc_tickadj.man.in@1.7 +13 -13 + NTP_4_2_7P425 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.8 +2 -2 + NTP_4_2_7P425 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.9 +1 -1 + NTP_4_2_7P425 + + scripts/invoke-plot_summary.texi@1.26 +1 -1 + NTP_4_2_7P425 + + scripts/invoke-summary.texi@1.26 +1 -1 + NTP_4_2_7P425 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.235 +1 -1 + NTP_4_2_7P425 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.236 +6 -6 + NTP_4_2_7P425 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.236 +2 -2 + NTP_4_2_7P425 + + scripts/ntp-wait/ntp-wait.html@1.252 +1 -1 + NTP_4_2_7P425 + + scripts/ntp-wait/ntp-wait.man.in@1.236 +6 -6 + NTP_4_2_7P425 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.236 +2 -2 + NTP_4_2_7P425 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.24 +1 -1 + NTP_4_2_7P425 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.15 +6 -6 + NTP_4_2_7P425 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.15 +2 -2 + NTP_4_2_7P425 + + scripts/ntpsweep/ntpsweep.html@1.25 +1 -1 + NTP_4_2_7P425 + + scripts/ntpsweep/ntpsweep.man.in@1.15 +6 -6 + NTP_4_2_7P425 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.16 +2 -2 + NTP_4_2_7P425 + + scripts/ntptrace/invoke-ntptrace.texi@1.24 +1 -1 + NTP_4_2_7P425 + + scripts/ntptrace/ntptrace.1ntptraceman@1.15 +6 -6 + NTP_4_2_7P425 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.15 +2 -2 + NTP_4_2_7P425 + + scripts/ntptrace/ntptrace.html@1.25 +1 -1 + NTP_4_2_7P425 + + scripts/ntptrace/ntptrace.man.in@1.15 +6 -6 + NTP_4_2_7P425 + + scripts/ntptrace/ntptrace.mdoc.in@1.16 +2 -2 + NTP_4_2_7P425 + + scripts/plot_summary.1plot_summaryman@1.26 +6 -6 + NTP_4_2_7P425 + + scripts/plot_summary.1plot_summarymdoc@1.26 +2 -2 + NTP_4_2_7P425 + + scripts/plot_summary.html@1.26 +1 -1 + NTP_4_2_7P425 + + scripts/plot_summary.man.in@1.26 +6 -6 + NTP_4_2_7P425 + + scripts/plot_summary.mdoc.in@1.26 +2 -2 + NTP_4_2_7P425 + + scripts/summary.1summaryman@1.26 +6 -6 + NTP_4_2_7P425 + + scripts/summary.1summarymdoc@1.26 +2 -2 + NTP_4_2_7P425 + + scripts/summary.html@1.26 +1 -1 + NTP_4_2_7P425 + + scripts/summary.man.in@1.26 +6 -6 + NTP_4_2_7P425 + + scripts/summary.mdoc.in@1.26 +2 -2 + NTP_4_2_7P425 + + sntp/invoke-sntp.texi@1.414 +2 -2 + NTP_4_2_7P425 + + sntp/sntp-opts.c@1.429 +7 -7 + NTP_4_2_7P425 + + sntp/sntp-opts.h@1.429 +3 -3 + NTP_4_2_7P425 + + sntp/sntp.1sntpman@1.249 +7 -7 + NTP_4_2_7P425 + + sntp/sntp.1sntpmdoc@1.249 +3 -3 + NTP_4_2_7P425 + + sntp/sntp.html@1.429 +2 -2 + NTP_4_2_7P425 + + sntp/sntp.man.in@1.249 +7 -7 + NTP_4_2_7P425 + + sntp/sntp.mdoc.in@1.249 +3 -3 + NTP_4_2_7P425 + + util/invoke-ntp-keygen.texi@1.418 +2 -2 + NTP_4_2_7P425 + + util/ntp-keygen-opts.c@1.432 +7 -7 + NTP_4_2_7P425 + + util/ntp-keygen-opts.h@1.432 +3 -3 + NTP_4_2_7P425 + + util/ntp-keygen.1ntp-keygenman@1.246 +0 -1250 + NTP_4_2_7P425 + + util/ntp-keygen.1ntp-keygenmdoc@1.246 +3 -3 + NTP_4_2_7P425 + + util/ntp-keygen.html@1.94 +2 -2 + NTP_4_2_7P425 + + util/ntp-keygen.man.in@1.246 +0 -1250 + NTP_4_2_7P425 + + util/ntp-keygen.mdoc.in@1.246 +3 -3 + NTP_4_2_7P425 + +ChangeSet@1.3102, 2014-02-25 21:26:28+01:00, jnperlin@hydra.(none) + [Bug 2562] first release of the GPSD client clock (type 46) + + ChangeLog@1.1431 +1 -0 + [Bug 2562] first release of the GPSD client clock (type 46) + +ChangeSet@1.3093.1.7, 2014-02-25 01:36:30-05:00, stenn@deacon.udel.edu + Copyright file update + + ChangeLog@1.1430 +1 -0 + Copyright file update + + html/copyright.html@1.62 +1 -0 + Copyright file update + +ChangeSet@1.3093.1.6, 2014-02-24 05:59:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P424 + TAG: NTP_4_2_7P424 + + ChangeLog@1.1429 +1 -0 + NTP_4_2_7P424 + + ntpd/invoke-ntp.conf.texi@1.102 +1 -1 + NTP_4_2_7P424 + + ntpd/invoke-ntp.keys.texi@1.100 +1 -1 + NTP_4_2_7P424 + + ntpd/invoke-ntpd.texi@1.416 +2 -2 + NTP_4_2_7P424 + + ntpd/ntp.conf.5man@1.136 +7 -7 + NTP_4_2_7P424 + + ntpd/ntp.conf.5mdoc@1.136 +3 -3 + NTP_4_2_7P424 + + ntpd/ntp.conf.html@1.97 +1 -1 + NTP_4_2_7P424 + + ntpd/ntp.conf.man.in@1.136 +7 -7 + NTP_4_2_7P424 + + ntpd/ntp.conf.mdoc.in@1.136 +3 -3 + NTP_4_2_7P424 + + ntpd/ntp.keys.5man@1.134 +3 -3 + NTP_4_2_7P424 + + ntpd/ntp.keys.5mdoc@1.134 +3 -3 + NTP_4_2_7P424 + + ntpd/ntp.keys.html@1.98 +1 -1 + NTP_4_2_7P424 + + ntpd/ntp.keys.man.in@1.134 +3 -3 + NTP_4_2_7P424 + + ntpd/ntp.keys.mdoc.in@1.134 +3 -3 + NTP_4_2_7P424 + + ntpd/ntpd-opts.c@1.434 +7 -7 + NTP_4_2_7P424 + + ntpd/ntpd-opts.h@1.434 +3 -3 + NTP_4_2_7P424 + + ntpd/ntpd.1ntpdman@1.245 +7 -7 + NTP_4_2_7P424 + + ntpd/ntpd.1ntpdmdoc@1.245 +3 -3 + NTP_4_2_7P424 + + ntpd/ntpd.html@1.92 +2 -2 + NTP_4_2_7P424 + + ntpd/ntpd.man.in@1.245 +7 -7 + NTP_4_2_7P424 + + ntpd/ntpd.mdoc.in@1.245 +3 -3 + NTP_4_2_7P424 + + ntpdc/invoke-ntpdc.texi@1.414 +2 -2 + NTP_4_2_7P424 + + ntpdc/ntpdc-opts.c@1.429 +7 -7 + NTP_4_2_7P424 + + ntpdc/ntpdc-opts.h@1.429 +3 -3 + NTP_4_2_7P424 + + ntpdc/ntpdc.1ntpdcman@1.245 +6 -6 + NTP_4_2_7P424 + + ntpdc/ntpdc.1ntpdcmdoc@1.245 +2 -2 + NTP_4_2_7P424 + + ntpdc/ntpdc.html@1.258 +2 -2 + NTP_4_2_7P424 + + ntpdc/ntpdc.man.in@1.245 +6 -6 + NTP_4_2_7P424 + + ntpdc/ntpdc.mdoc.in@1.245 +2 -2 + NTP_4_2_7P424 + + ntpq/invoke-ntpq.texi@1.417 +2 -2 + NTP_4_2_7P424 + + ntpq/ntpq-opts.c@1.431 +7 -7 + NTP_4_2_7P424 + + ntpq/ntpq-opts.h@1.431 +3 -3 + NTP_4_2_7P424 + + ntpq/ntpq.1ntpqman@1.245 +6 -6 + NTP_4_2_7P424 + + ntpq/ntpq.1ntpqmdoc@1.245 +2 -2 + NTP_4_2_7P424 + + ntpq/ntpq.html@1.89 +2 -2 + NTP_4_2_7P424 + + ntpq/ntpq.man.in@1.245 +6 -6 + NTP_4_2_7P424 + + ntpq/ntpq.mdoc.in@1.245 +2 -2 + NTP_4_2_7P424 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.416 +2 -2 + NTP_4_2_7P424 + + ntpsnmpd/ntpsnmpd-opts.c@1.431 +7 -7 + NTP_4_2_7P424 + + ntpsnmpd/ntpsnmpd-opts.h@1.431 +3 -3 + NTP_4_2_7P424 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.245 +235 -0 + NTP_4_2_7P424 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.245 +3 -3 + NTP_4_2_7P424 + + ntpsnmpd/ntpsnmpd.html@1.87 +1 -1 + NTP_4_2_7P424 + + ntpsnmpd/ntpsnmpd.man.in@1.245 +235 -0 + NTP_4_2_7P424 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.245 +3 -3 + NTP_4_2_7P424 + + packageinfo.sh@1.428 +1 -1 + NTP_4_2_7P424 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.7 +6 -6 + NTP_4_2_7P424 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.7 +2 -2 + NTP_4_2_7P424 + + scripts/calc_tickadj/calc_tickadj.html@1.6 +1 -1 + NTP_4_2_7P424 + + scripts/calc_tickadj/calc_tickadj.man.in@1.6 +6 -6 + NTP_4_2_7P424 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.7 +2 -2 + NTP_4_2_7P424 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.8 +1 -1 + NTP_4_2_7P424 + + scripts/invoke-plot_summary.texi@1.25 +1 -1 + NTP_4_2_7P424 + + scripts/invoke-summary.texi@1.25 +1 -1 + NTP_4_2_7P424 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.234 +1 -1 + NTP_4_2_7P424 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.235 +6 -6 + NTP_4_2_7P424 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.235 +2 -2 + NTP_4_2_7P424 + + scripts/ntp-wait/ntp-wait.html@1.251 +1 -1 + NTP_4_2_7P424 + + scripts/ntp-wait/ntp-wait.man.in@1.235 +6 -6 + NTP_4_2_7P424 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.235 +2 -2 + NTP_4_2_7P424 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.23 +1 -1 + NTP_4_2_7P424 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.14 +6 -6 + NTP_4_2_7P424 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.14 +2 -2 + NTP_4_2_7P424 + + scripts/ntpsweep/ntpsweep.html@1.24 +1 -1 + NTP_4_2_7P424 + + scripts/ntpsweep/ntpsweep.man.in@1.14 +6 -6 + NTP_4_2_7P424 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.15 +2 -2 + NTP_4_2_7P424 + + scripts/ntptrace/invoke-ntptrace.texi@1.23 +1 -1 + NTP_4_2_7P424 + + scripts/ntptrace/ntptrace.1ntptraceman@1.14 +6 -6 + NTP_4_2_7P424 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.14 +2 -2 + NTP_4_2_7P424 + + scripts/ntptrace/ntptrace.html@1.24 +1 -1 + NTP_4_2_7P424 + + scripts/ntptrace/ntptrace.man.in@1.14 +6 -6 + NTP_4_2_7P424 + + scripts/ntptrace/ntptrace.mdoc.in@1.15 +2 -2 + NTP_4_2_7P424 + + scripts/plot_summary.1plot_summaryman@1.25 +6 -6 + NTP_4_2_7P424 + + scripts/plot_summary.1plot_summarymdoc@1.25 +2 -2 + NTP_4_2_7P424 + + scripts/plot_summary.html@1.25 +1 -1 + NTP_4_2_7P424 + + scripts/plot_summary.man.in@1.25 +6 -6 + NTP_4_2_7P424 + + scripts/plot_summary.mdoc.in@1.25 +2 -2 + NTP_4_2_7P424 + + scripts/summary.1summaryman@1.25 +6 -6 + NTP_4_2_7P424 + + scripts/summary.1summarymdoc@1.25 +2 -2 + NTP_4_2_7P424 + + scripts/summary.html@1.25 +1 -1 + NTP_4_2_7P424 + + scripts/summary.man.in@1.25 +6 -6 + NTP_4_2_7P424 + + scripts/summary.mdoc.in@1.25 +2 -2 + NTP_4_2_7P424 + + sntp/invoke-sntp.texi@1.413 +2 -2 + NTP_4_2_7P424 + + sntp/sntp-opts.c@1.428 +7 -7 + NTP_4_2_7P424 + + sntp/sntp-opts.h@1.428 +3 -3 + NTP_4_2_7P424 + + sntp/sntp.1sntpman@1.248 +7 -7 + NTP_4_2_7P424 + + sntp/sntp.1sntpmdoc@1.248 +3 -3 + NTP_4_2_7P424 + + sntp/sntp.html@1.428 +2 -2 + NTP_4_2_7P424 + + sntp/sntp.man.in@1.248 +7 -7 + NTP_4_2_7P424 + + sntp/sntp.mdoc.in@1.248 +3 -3 + NTP_4_2_7P424 + + util/invoke-ntp-keygen.texi@1.417 +2 -2 + NTP_4_2_7P424 + + util/ntp-keygen-opts.c@1.431 +7 -7 + NTP_4_2_7P424 + + util/ntp-keygen-opts.h@1.431 +3 -3 + NTP_4_2_7P424 + + util/ntp-keygen.1ntp-keygenman@1.245 +7 -7 + NTP_4_2_7P424 + + util/ntp-keygen.1ntp-keygenmdoc@1.245 +3 -3 + NTP_4_2_7P424 + + util/ntp-keygen.html@1.93 +2 -2 + NTP_4_2_7P424 + + util/ntp-keygen.man.in@1.245 +7 -7 + NTP_4_2_7P424 + + util/ntp-keygen.mdoc.in@1.245 +3 -3 + NTP_4_2_7P424 + +ChangeSet@1.3093.1.5, 2014-02-23 18:25:43-05:00, stenn@deacon.udel.edu + [Bug 2541] ntpd terminates itself with SIGHUP unexpectedly + + ChangeLog@1.1428 +1 -0 + [Bug 2541] ntpd terminates itself with SIGHUP unexpectedly + + libntp/work_fork.c@1.12 +3 -1 + [Bug 2541] ntpd terminates itself with SIGHUP unexpectedly + +ChangeSet@1.3093.1.4, 2014-02-23 22:59:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P423 + TAG: NTP_4_2_7P423 + + ChangeLog@1.1427 +1 -0 + NTP_4_2_7P423 + + ntpd/invoke-ntp.conf.texi@1.101 +1 -1 + NTP_4_2_7P423 + + ntpd/invoke-ntp.keys.texi@1.99 +1 -1 + NTP_4_2_7P423 + + ntpd/invoke-ntpd.texi@1.415 +2 -2 + NTP_4_2_7P423 + + ntpd/ntp.conf.5man@1.135 +7 -7 + NTP_4_2_7P423 + + ntpd/ntp.conf.5mdoc@1.135 +3 -3 + NTP_4_2_7P423 + + ntpd/ntp.conf.html@1.96 +1 -1 + NTP_4_2_7P423 + + ntpd/ntp.conf.man.in@1.135 +7 -7 + NTP_4_2_7P423 + + ntpd/ntp.conf.mdoc.in@1.135 +3 -3 + NTP_4_2_7P423 + + ntpd/ntp.keys.5man@1.133 +3 -3 + NTP_4_2_7P423 + + ntpd/ntp.keys.5mdoc@1.133 +3 -3 + NTP_4_2_7P423 + + ntpd/ntp.keys.html@1.97 +1 -1 + NTP_4_2_7P423 + + ntpd/ntp.keys.man.in@1.133 +3 -3 + NTP_4_2_7P423 + + ntpd/ntp.keys.mdoc.in@1.133 +3 -3 + NTP_4_2_7P423 + + ntpd/ntpd-opts.c@1.433 +7 -7 + NTP_4_2_7P423 + + ntpd/ntpd-opts.h@1.433 +3 -3 + NTP_4_2_7P423 + + ntpd/ntpd.1ntpdman@1.244 +7 -7 + NTP_4_2_7P423 + + ntpd/ntpd.1ntpdmdoc@1.244 +3 -3 + NTP_4_2_7P423 + + ntpd/ntpd.html@1.91 +2 -2 + NTP_4_2_7P423 + + ntpd/ntpd.man.in@1.244 +7 -7 + NTP_4_2_7P423 + + ntpd/ntpd.mdoc.in@1.244 +3 -3 + NTP_4_2_7P423 + + ntpdc/invoke-ntpdc.texi@1.413 +2 -2 + NTP_4_2_7P423 + + ntpdc/ntpdc-opts.c@1.428 +7 -7 + NTP_4_2_7P423 + + ntpdc/ntpdc-opts.h@1.428 +3 -3 + NTP_4_2_7P423 + + ntpdc/ntpdc.1ntpdcman@1.244 +6 -6 + NTP_4_2_7P423 + + ntpdc/ntpdc.1ntpdcmdoc@1.244 +2 -2 + NTP_4_2_7P423 + + ntpdc/ntpdc.html@1.257 +2 -2 + NTP_4_2_7P423 + + ntpdc/ntpdc.man.in@1.244 +6 -6 + NTP_4_2_7P423 + + ntpdc/ntpdc.mdoc.in@1.244 +2 -2 + NTP_4_2_7P423 + + ntpq/invoke-ntpq.texi@1.416 +2 -2 + NTP_4_2_7P423 + + ntpq/ntpq-opts.c@1.430 +7 -7 + NTP_4_2_7P423 + + ntpq/ntpq-opts.h@1.430 +3 -3 + NTP_4_2_7P423 + + ntpq/ntpq.1ntpqman@1.244 +6 -6 + NTP_4_2_7P423 + + ntpq/ntpq.1ntpqmdoc@1.244 +2 -2 + NTP_4_2_7P423 + + ntpq/ntpq.html@1.88 +2 -2 + NTP_4_2_7P423 + + ntpq/ntpq.man.in@1.244 +6 -6 + NTP_4_2_7P423 + + ntpq/ntpq.mdoc.in@1.244 +2 -2 + NTP_4_2_7P423 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.415 +2 -2 + NTP_4_2_7P423 + + ntpsnmpd/ntpsnmpd-opts.c@1.430 +7 -7 + NTP_4_2_7P423 + + ntpsnmpd/ntpsnmpd-opts.h@1.430 +3 -3 + NTP_4_2_7P423 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.244 +0 -235 + NTP_4_2_7P423 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.244 +3 -3 + NTP_4_2_7P423 + + ntpsnmpd/ntpsnmpd.html@1.86 +1 -1 + NTP_4_2_7P423 + + ntpsnmpd/ntpsnmpd.man.in@1.244 +0 -235 + NTP_4_2_7P423 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.244 +3 -3 + NTP_4_2_7P423 + + packageinfo.sh@1.427 +1 -1 + NTP_4_2_7P423 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.6 +6 -6 + NTP_4_2_7P423 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.6 +2 -2 + NTP_4_2_7P423 + + scripts/calc_tickadj/calc_tickadj.html@1.5 +1 -1 + NTP_4_2_7P423 + + scripts/calc_tickadj/calc_tickadj.man.in@1.5 +6 -6 + NTP_4_2_7P423 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.6 +2 -2 + NTP_4_2_7P423 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.7 +1 -1 + NTP_4_2_7P423 + + scripts/invoke-plot_summary.texi@1.24 +1 -1 + NTP_4_2_7P423 + + scripts/invoke-summary.texi@1.24 +1 -1 + NTP_4_2_7P423 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.233 +1 -1 + NTP_4_2_7P423 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.234 +6 -6 + NTP_4_2_7P423 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.234 +2 -2 + NTP_4_2_7P423 + + scripts/ntp-wait/ntp-wait.html@1.250 +1 -1 + NTP_4_2_7P423 + + scripts/ntp-wait/ntp-wait.man.in@1.234 +6 -6 + NTP_4_2_7P423 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.234 +2 -2 + NTP_4_2_7P423 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.22 +1 -1 + NTP_4_2_7P423 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.13 +6 -6 + NTP_4_2_7P423 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.13 +2 -2 + NTP_4_2_7P423 + + scripts/ntpsweep/ntpsweep.html@1.23 +1 -1 + NTP_4_2_7P423 + + scripts/ntpsweep/ntpsweep.man.in@1.13 +6 -6 + NTP_4_2_7P423 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.14 +2 -2 + NTP_4_2_7P423 + + scripts/ntptrace/invoke-ntptrace.texi@1.22 +1 -1 + NTP_4_2_7P423 + + scripts/ntptrace/ntptrace.1ntptraceman@1.13 +6 -6 + NTP_4_2_7P423 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.13 +2 -2 + NTP_4_2_7P423 + + scripts/ntptrace/ntptrace.html@1.23 +1 -1 + NTP_4_2_7P423 + + scripts/ntptrace/ntptrace.man.in@1.13 +6 -6 + NTP_4_2_7P423 + + scripts/ntptrace/ntptrace.mdoc.in@1.14 +2 -2 + NTP_4_2_7P423 + + scripts/plot_summary.1plot_summaryman@1.24 +6 -6 + NTP_4_2_7P423 + + scripts/plot_summary.1plot_summarymdoc@1.24 +2 -2 + NTP_4_2_7P423 + + scripts/plot_summary.html@1.24 +1 -1 + NTP_4_2_7P423 + + scripts/plot_summary.man.in@1.24 +6 -6 + NTP_4_2_7P423 + + scripts/plot_summary.mdoc.in@1.24 +2 -2 + NTP_4_2_7P423 + + scripts/summary.1summaryman@1.24 +6 -6 + NTP_4_2_7P423 + + scripts/summary.1summarymdoc@1.24 +2 -2 + NTP_4_2_7P423 + + scripts/summary.html@1.24 +1 -1 + NTP_4_2_7P423 + + scripts/summary.man.in@1.24 +6 -6 + NTP_4_2_7P423 + + scripts/summary.mdoc.in@1.24 +2 -2 + NTP_4_2_7P423 + + sntp/invoke-sntp.texi@1.412 +2 -2 + NTP_4_2_7P423 + + sntp/sntp-opts.c@1.427 +7 -7 + NTP_4_2_7P423 + + sntp/sntp-opts.h@1.427 +3 -3 + NTP_4_2_7P423 + + sntp/sntp.1sntpman@1.247 +7 -7 + NTP_4_2_7P423 + + sntp/sntp.1sntpmdoc@1.247 +3 -3 + NTP_4_2_7P423 + + sntp/sntp.html@1.427 +2 -2 + NTP_4_2_7P423 + + sntp/sntp.man.in@1.247 +7 -7 + NTP_4_2_7P423 + + sntp/sntp.mdoc.in@1.247 +3 -3 + NTP_4_2_7P423 + + util/invoke-ntp-keygen.texi@1.416 +2 -2 + NTP_4_2_7P423 + + util/ntp-keygen-opts.c@1.430 +7 -7 + NTP_4_2_7P423 + + util/ntp-keygen-opts.h@1.430 +3 -3 + NTP_4_2_7P423 + + util/ntp-keygen.1ntp-keygenman@1.244 +7 -7 + NTP_4_2_7P423 + + util/ntp-keygen.1ntp-keygenmdoc@1.244 +3 -3 + NTP_4_2_7P423 + + util/ntp-keygen.html@1.92 +2 -2 + NTP_4_2_7P423 + + util/ntp-keygen.man.in@1.244 +7 -7 + NTP_4_2_7P423 + + util/ntp-keygen.mdoc.in@1.244 +3 -3 + NTP_4_2_7P423 + +ChangeSet@1.3093.1.3, 2014-02-22 05:25:52+00:00, stenn@psp-fb1.ntp.org + [Bug 2565] Handle EINTR on getifaddrs() + + ChangeLog@1.1426 +1 -0 + [Bug 2565] Handle EINTR on getifaddrs() + + lib/isc/unix/ifiter_getifaddrs.c@1.11 +18 -11 + [Bug 2565] Handle EINTR on getifaddrs() + +ChangeSet@1.3100, 2014-02-20 21:22:08+01:00, jnperlin@hydra.(none) + refclock_gpsdjson: operation reordering (grouping) during startup + + ntpd/refclock_gpsdjson.c@1.6 +5 -3 + operation reordering (grouping) during startup + +ChangeSet@1.3099, 2014-02-18 21:36:24+01:00, jnperlin@hydra.(none) + refclock_gpsdjson: fix clock status report logic (did not work after reconnect) + + ntpd/refclock_gpsdjson.c@1.5 +43 -16 + fix clock status report logic (did not work after reconnect) + +ChangeSet@1.3098, 2014-02-17 19:42:56+01:00, jnperlin@hydra.(none) + GPSD_JSON: do not build on Win32 + + ntpd/refclock_conf.c@1.35 +1 -1 + GPSD_JSON: do not build on Win32 + + ntpd/refclock_gpsdjson.c@1.4 +40 -30 + GPSD_JSON: do not build on Win32 (and some typo fixing) + +ChangeSet@1.3093.1.2, 2014-02-17 11:39:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P422 + TAG: NTP_4_2_7P422 + + ChangeLog@1.1425 +1 -0 + NTP_4_2_7P422 + + ntpd/invoke-ntp.conf.texi@1.100 +1 -1 + NTP_4_2_7P422 + + ntpd/invoke-ntp.keys.texi@1.98 +1 -1 + NTP_4_2_7P422 + + ntpd/invoke-ntpd.texi@1.414 +2 -2 + NTP_4_2_7P422 + + ntpd/ntp.conf.5man@1.134 +7 -7 + NTP_4_2_7P422 + + ntpd/ntp.conf.5mdoc@1.134 +3 -3 + NTP_4_2_7P422 + + ntpd/ntp.conf.html@1.95 +1 -1 + NTP_4_2_7P422 + + ntpd/ntp.conf.man.in@1.134 +7 -7 + NTP_4_2_7P422 + + ntpd/ntp.conf.mdoc.in@1.134 +3 -3 + NTP_4_2_7P422 + + ntpd/ntp.keys.5man@1.132 +3 -3 + NTP_4_2_7P422 + + ntpd/ntp.keys.5mdoc@1.132 +3 -3 + NTP_4_2_7P422 + + ntpd/ntp.keys.html@1.96 +1 -1 + NTP_4_2_7P422 + + ntpd/ntp.keys.man.in@1.132 +3 -3 + NTP_4_2_7P422 + + ntpd/ntp.keys.mdoc.in@1.132 +3 -3 + NTP_4_2_7P422 + + ntpd/ntpd-opts.c@1.432 +7 -7 + NTP_4_2_7P422 + + ntpd/ntpd-opts.h@1.432 +3 -3 + NTP_4_2_7P422 + + ntpd/ntpd.1ntpdman@1.243 +7 -7 + NTP_4_2_7P422 + + ntpd/ntpd.1ntpdmdoc@1.243 +3 -3 + NTP_4_2_7P422 + + ntpd/ntpd.html@1.90 +2 -2 + NTP_4_2_7P422 + + ntpd/ntpd.man.in@1.243 +7 -7 + NTP_4_2_7P422 + + ntpd/ntpd.mdoc.in@1.243 +3 -3 + NTP_4_2_7P422 + + ntpdc/invoke-ntpdc.texi@1.412 +2 -2 + NTP_4_2_7P422 + + ntpdc/ntpdc-opts.c@1.427 +7 -7 + NTP_4_2_7P422 + + ntpdc/ntpdc-opts.h@1.427 +3 -3 + NTP_4_2_7P422 + + ntpdc/ntpdc.1ntpdcman@1.243 +6 -6 + NTP_4_2_7P422 + + ntpdc/ntpdc.1ntpdcmdoc@1.243 +2 -2 + NTP_4_2_7P422 + + ntpdc/ntpdc.html@1.256 +2 -2 + NTP_4_2_7P422 + + ntpdc/ntpdc.man.in@1.243 +6 -6 + NTP_4_2_7P422 + + ntpdc/ntpdc.mdoc.in@1.243 +2 -2 + NTP_4_2_7P422 + + ntpq/invoke-ntpq.texi@1.415 +2 -2 + NTP_4_2_7P422 + + ntpq/ntpq-opts.c@1.429 +7 -7 + NTP_4_2_7P422 + + ntpq/ntpq-opts.h@1.429 +3 -3 + NTP_4_2_7P422 + + ntpq/ntpq.1ntpqman@1.243 +6 -6 + NTP_4_2_7P422 + + ntpq/ntpq.1ntpqmdoc@1.243 +2 -2 + NTP_4_2_7P422 + + ntpq/ntpq.html@1.87 +2 -2 + NTP_4_2_7P422 + + ntpq/ntpq.man.in@1.243 +6 -6 + NTP_4_2_7P422 + + ntpq/ntpq.mdoc.in@1.243 +2 -2 + NTP_4_2_7P422 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.414 +2 -2 + NTP_4_2_7P422 + + ntpsnmpd/ntpsnmpd-opts.c@1.429 +7 -7 + NTP_4_2_7P422 + + ntpsnmpd/ntpsnmpd-opts.h@1.429 +3 -3 + NTP_4_2_7P422 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.243 +7 -7 + NTP_4_2_7P422 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.243 +3 -3 + NTP_4_2_7P422 + + ntpsnmpd/ntpsnmpd.html@1.85 +1 -1 + NTP_4_2_7P422 + + ntpsnmpd/ntpsnmpd.man.in@1.243 +7 -7 + NTP_4_2_7P422 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.243 +3 -3 + NTP_4_2_7P422 + + packageinfo.sh@1.426 +1 -1 + NTP_4_2_7P422 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.5 +6 -6 + NTP_4_2_7P422 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.5 +2 -2 + NTP_4_2_7P422 + + scripts/calc_tickadj/calc_tickadj.html@1.4 +1 -1 + NTP_4_2_7P422 + + scripts/calc_tickadj/calc_tickadj.man.in@1.4 +6 -6 + NTP_4_2_7P422 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.5 +2 -2 + NTP_4_2_7P422 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.6 +1 -1 + NTP_4_2_7P422 + + scripts/invoke-plot_summary.texi@1.23 +1 -1 + NTP_4_2_7P422 + + scripts/invoke-summary.texi@1.23 +1 -1 + NTP_4_2_7P422 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.232 +1 -1 + NTP_4_2_7P422 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.233 +6 -6 + NTP_4_2_7P422 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.233 +2 -2 + NTP_4_2_7P422 + + scripts/ntp-wait/ntp-wait.html@1.249 +1 -1 + NTP_4_2_7P422 + + scripts/ntp-wait/ntp-wait.man.in@1.233 +6 -6 + NTP_4_2_7P422 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.233 +2 -2 + NTP_4_2_7P422 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.21 +1 -1 + NTP_4_2_7P422 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.12 +6 -6 + NTP_4_2_7P422 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.12 +2 -2 + NTP_4_2_7P422 + + scripts/ntpsweep/ntpsweep.html@1.22 +1 -1 + NTP_4_2_7P422 + + scripts/ntpsweep/ntpsweep.man.in@1.12 +6 -6 + NTP_4_2_7P422 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.13 +2 -2 + NTP_4_2_7P422 + + scripts/ntptrace/invoke-ntptrace.texi@1.21 +1 -1 + NTP_4_2_7P422 + + scripts/ntptrace/ntptrace.1ntptraceman@1.12 +6 -6 + NTP_4_2_7P422 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.12 +2 -2 + NTP_4_2_7P422 + + scripts/ntptrace/ntptrace.html@1.22 +1 -1 + NTP_4_2_7P422 + + scripts/ntptrace/ntptrace.man.in@1.12 +6 -6 + NTP_4_2_7P422 + + scripts/ntptrace/ntptrace.mdoc.in@1.13 +2 -2 + NTP_4_2_7P422 + + scripts/plot_summary.1plot_summaryman@1.23 +6 -6 + NTP_4_2_7P422 + + scripts/plot_summary.1plot_summarymdoc@1.23 +2 -2 + NTP_4_2_7P422 + + scripts/plot_summary.html@1.23 +1 -1 + NTP_4_2_7P422 + + scripts/plot_summary.man.in@1.23 +6 -6 + NTP_4_2_7P422 + + scripts/plot_summary.mdoc.in@1.23 +2 -2 + NTP_4_2_7P422 + + scripts/summary.1summaryman@1.23 +6 -6 + NTP_4_2_7P422 + + scripts/summary.1summarymdoc@1.23 +2 -2 + NTP_4_2_7P422 + + scripts/summary.html@1.23 +1 -1 + NTP_4_2_7P422 + + scripts/summary.man.in@1.23 +6 -6 + NTP_4_2_7P422 + + scripts/summary.mdoc.in@1.23 +2 -2 + NTP_4_2_7P422 + + sntp/invoke-sntp.texi@1.411 +2 -2 + NTP_4_2_7P422 + + sntp/sntp-opts.c@1.426 +7 -7 + NTP_4_2_7P422 + + sntp/sntp-opts.h@1.426 +3 -3 + NTP_4_2_7P422 + + sntp/sntp.1sntpman@1.246 +14 -14 + NTP_4_2_7P422 + + sntp/sntp.1sntpmdoc@1.246 +3 -3 + NTP_4_2_7P422 + + sntp/sntp.html@1.426 +2 -2 + NTP_4_2_7P422 + + sntp/sntp.man.in@1.246 +14 -14 + NTP_4_2_7P422 + + sntp/sntp.mdoc.in@1.246 +3 -3 + NTP_4_2_7P422 + + util/invoke-ntp-keygen.texi@1.415 +2 -2 + NTP_4_2_7P422 + + util/ntp-keygen-opts.c@1.429 +7 -7 + NTP_4_2_7P422 + + util/ntp-keygen-opts.h@1.429 +3 -3 + NTP_4_2_7P422 + + util/ntp-keygen.1ntp-keygenman@1.243 +7 -7 + NTP_4_2_7P422 + + util/ntp-keygen.1ntp-keygenmdoc@1.243 +3 -3 + NTP_4_2_7P422 + + util/ntp-keygen.html@1.91 +2 -2 + NTP_4_2_7P422 + + util/ntp-keygen.man.in@1.243 +7 -7 + NTP_4_2_7P422 + + util/ntp-keygen.mdoc.in@1.243 +3 -3 + NTP_4_2_7P422 + +ChangeSet@1.3093.1.1, 2014-02-17 07:51:58+00:00, stenn@psp-fb1.ntp.org + [Bug 2536] ntpd sandboxing support (libseccomp2) + + ChangeLog@1.1424 +1 -0 + [Bug 2536] ntpd sandboxing support (libseccomp2) + + configure.ac@1.571.1.1 +24 -0 + [Bug 2536] ntpd sandboxing support (libseccomp2) + + ntpd/ntpd.c@1.153 +106 -4 + [Bug 2536] ntpd sandboxing support (libseccomp2) + +ChangeSet@1.3097, 2014-02-16 22:43:49+01:00, jnperlin@hydra.(none) + GPSD/JSON driver: added type aliases, some more cleanup + + ntpd/refclock_gpsdjson.c@1.3 +137 -152 + added type aliases, some more cleanup + +ChangeSet@1.3096, 2014-02-16 15:07:57+01:00, jnperlin@hydra.(none) + started documentation on driver 46 (GPSD_JSON) + + html/drivers/driver46.html@1.1 +115 -0 + started documentation + + html/drivers/driver46.html@1.0 +0 -0 + + html/refclock.html@1.41 +1 -0 + added link to driver 46 /GPSD_JSON) + + ntpd/ntp_control.c@1.189 +1 -0 + added GPSD_JSON + +ChangeSet@1.3095, 2014-02-16 14:10:37+01:00, jnperlin@hydra.(none) + logging, cleanup, refactoring: still a work in progress + + ntpd/refclock_gpsdjson.c@1.2 +463 -308 + logging, cleanup, refactoring: still a work in progress + +ChangeSet@1.3094, 2014-02-15 02:56:41+01:00, jnperlin@hydra.(none) + added the GPSD-JSON client driver + + configure.ac@1.572 +18 -0 + added the GPSD-JSON client driver + + include/ntp.h@1.208 +3 -2 + added the GPSD-JSON client driver + + libjsmn/LICENSE@1.1 +20 -0 + added the GPSD-JSON client driver + + libjsmn/LICENSE@1.0 +0 -0 + + libjsmn/Makefile@1.1 +27 -0 + added the GPSD-JSON client driver + + libjsmn/Makefile@1.0 +0 -0 + + libjsmn/README.md@1.1 +161 -0 + added the GPSD-JSON client driver + + libjsmn/README.md@1.0 +0 -0 + + libjsmn/jsmn.c@1.1 +268 -0 + added the GPSD-JSON client driver + + libjsmn/jsmn.c@1.0 +0 -0 + + libjsmn/jsmn.h@1.1 +67 -0 + added the GPSD-JSON client driver + + libjsmn/jsmn.h@1.0 +0 -0 + + libjsmn/jsmn_test.c@1.1 +409 -0 + added the GPSD-JSON client driver + + libjsmn/jsmn_test.c@1.0 +0 -0 + + libntp/clocktypes.c@1.21 +2 -0 + added the GPSD-JSON client driver + + ntpd/Makefile.am@1.130 +1 -0 + added the GPSD-JSON client driver + + ntpd/refclock_conf.c@1.34 +8 -1 + added the GPSD-JSON client driver + + ntpd/refclock_gpsdjson.c@1.1 +921 -0 + added the GPSD-JSON client driver + + ntpd/refclock_gpsdjson.c@1.0 +0 -0 + +ChangeSet@1.3093, 2014-02-10 20:34:39+00:00, stenn@deacon.udel.edu + NTP_4_2_7P421 + TAG: NTP_4_2_7P421 + + ChangeLog@1.1423 +1 -0 + NTP_4_2_7P421 + + ntpd/invoke-ntp.conf.texi@1.99 +1 -1 + NTP_4_2_7P421 + + ntpd/invoke-ntp.keys.texi@1.97 +1 -1 + NTP_4_2_7P421 + + ntpd/invoke-ntpd.texi@1.413 +2 -2 + NTP_4_2_7P421 + + ntpd/ntp.conf.5man@1.133 +7 -7 + NTP_4_2_7P421 + + ntpd/ntp.conf.5mdoc@1.133 +4 -4 + NTP_4_2_7P421 + + ntpd/ntp.conf.html@1.94 +1 -1 + NTP_4_2_7P421 + + ntpd/ntp.conf.man.in@1.133 +7 -7 + NTP_4_2_7P421 + + ntpd/ntp.conf.mdoc.in@1.133 +4 -4 + NTP_4_2_7P421 + + ntpd/ntp.keys.5man@1.131 +3 -3 + NTP_4_2_7P421 + + ntpd/ntp.keys.5mdoc@1.131 +3 -3 + NTP_4_2_7P421 + + ntpd/ntp.keys.html@1.95 +1 -1 + NTP_4_2_7P421 + + ntpd/ntp.keys.man.in@1.131 +3 -3 + NTP_4_2_7P421 + + ntpd/ntp.keys.mdoc.in@1.131 +3 -3 + NTP_4_2_7P421 + + ntpd/ntpd-opts.c@1.431 +7 -7 + NTP_4_2_7P421 + + ntpd/ntpd-opts.h@1.431 +3 -3 + NTP_4_2_7P421 + + ntpd/ntpd.1ntpdman@1.242 +7 -7 + NTP_4_2_7P421 + + ntpd/ntpd.1ntpdmdoc@1.242 +4 -4 + NTP_4_2_7P421 + + ntpd/ntpd.html@1.89 +2 -2 + NTP_4_2_7P421 + + ntpd/ntpd.man.in@1.242 +7 -7 + NTP_4_2_7P421 + + ntpd/ntpd.mdoc.in@1.242 +4 -4 + NTP_4_2_7P421 + + ntpdc/invoke-ntpdc.texi@1.411 +2 -2 + NTP_4_2_7P421 + + ntpdc/ntpdc-opts.c@1.426 +7 -7 + NTP_4_2_7P421 + + ntpdc/ntpdc-opts.h@1.426 +3 -3 + NTP_4_2_7P421 + + ntpdc/ntpdc.1ntpdcman@1.242 +6 -6 + NTP_4_2_7P421 + + ntpdc/ntpdc.1ntpdcmdoc@1.242 +3 -3 + NTP_4_2_7P421 + + ntpdc/ntpdc.html@1.255 +2 -2 + NTP_4_2_7P421 + + ntpdc/ntpdc.man.in@1.242 +6 -6 + NTP_4_2_7P421 + + ntpdc/ntpdc.mdoc.in@1.242 +3 -3 + NTP_4_2_7P421 + + ntpq/invoke-ntpq.texi@1.414 +2 -2 + NTP_4_2_7P421 + + ntpq/ntpq-opts.c@1.428 +7 -7 + NTP_4_2_7P421 + + ntpq/ntpq-opts.h@1.428 +3 -3 + NTP_4_2_7P421 + + ntpq/ntpq.1ntpqman@1.242 +6 -6 + NTP_4_2_7P421 + + ntpq/ntpq.1ntpqmdoc@1.242 +3 -3 + NTP_4_2_7P421 + + ntpq/ntpq.html@1.86 +2 -2 + NTP_4_2_7P421 + + ntpq/ntpq.man.in@1.242 +6 -6 + NTP_4_2_7P421 + + ntpq/ntpq.mdoc.in@1.242 +3 -3 + NTP_4_2_7P421 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.413 +2 -2 + NTP_4_2_7P421 + + ntpsnmpd/ntpsnmpd-opts.c@1.428 +7 -7 + NTP_4_2_7P421 + + ntpsnmpd/ntpsnmpd-opts.h@1.428 +3 -3 + NTP_4_2_7P421 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.242 +7 -7 + NTP_4_2_7P421 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.242 +4 -4 + NTP_4_2_7P421 + + ntpsnmpd/ntpsnmpd.html@1.84 +1 -1 + NTP_4_2_7P421 + + ntpsnmpd/ntpsnmpd.man.in@1.242 +7 -7 + NTP_4_2_7P421 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.242 +4 -4 + NTP_4_2_7P421 + + packageinfo.sh@1.425 +1 -1 + NTP_4_2_7P421 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.4 +6 -6 + NTP_4_2_7P421 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.4 +1 -1 + NTP_4_2_7P421 + + scripts/calc_tickadj/calc_tickadj.html@1.3 +23 -35 + NTP_4_2_7P421 + + scripts/calc_tickadj/calc_tickadj.man.in@1.3 +6 -6 + NTP_4_2_7P421 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.4 +1 -1 + NTP_4_2_7P421 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.5 +2 -2 + NTP_4_2_7P421 + + scripts/invoke-plot_summary.texi@1.22 +1 -1 + NTP_4_2_7P421 + + scripts/invoke-summary.texi@1.22 +1 -1 + NTP_4_2_7P421 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.231 +1 -1 + NTP_4_2_7P421 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.232 +6 -6 + NTP_4_2_7P421 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.232 +3 -3 + NTP_4_2_7P421 + + scripts/ntp-wait/ntp-wait.html@1.248 +1 -1 + NTP_4_2_7P421 + + scripts/ntp-wait/ntp-wait.man.in@1.232 +6 -6 + NTP_4_2_7P421 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.232 +3 -3 + NTP_4_2_7P421 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.20 +1 -1 + NTP_4_2_7P421 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.11 +6 -6 + NTP_4_2_7P421 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.11 +3 -3 + NTP_4_2_7P421 + + scripts/ntpsweep/ntpsweep.html@1.21 +1 -1 + NTP_4_2_7P421 + + scripts/ntpsweep/ntpsweep.man.in@1.11 +6 -6 + NTP_4_2_7P421 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.12 +3 -3 + NTP_4_2_7P421 + + scripts/ntptrace/invoke-ntptrace.texi@1.20 +1 -1 + NTP_4_2_7P421 + + scripts/ntptrace/ntptrace.1ntptraceman@1.11 +6 -6 + NTP_4_2_7P421 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.11 +3 -3 + NTP_4_2_7P421 + + scripts/ntptrace/ntptrace.html@1.21 +1 -1 + NTP_4_2_7P421 + + scripts/ntptrace/ntptrace.man.in@1.11 +6 -6 + NTP_4_2_7P421 + + scripts/ntptrace/ntptrace.mdoc.in@1.12 +3 -3 + NTP_4_2_7P421 + + scripts/plot_summary.1plot_summaryman@1.22 +6 -6 + NTP_4_2_7P421 + + scripts/plot_summary.1plot_summarymdoc@1.22 +3 -3 + NTP_4_2_7P421 + + scripts/plot_summary.html@1.22 +1 -1 + NTP_4_2_7P421 + + scripts/plot_summary.man.in@1.22 +6 -6 + NTP_4_2_7P421 + + scripts/plot_summary.mdoc.in@1.22 +3 -3 + NTP_4_2_7P421 + + scripts/summary.1summaryman@1.22 +6 -6 + NTP_4_2_7P421 + + scripts/summary.1summarymdoc@1.22 +3 -3 + NTP_4_2_7P421 + + scripts/summary.html@1.22 +1 -1 + NTP_4_2_7P421 + + scripts/summary.man.in@1.22 +6 -6 + NTP_4_2_7P421 + + scripts/summary.mdoc.in@1.22 +3 -3 + NTP_4_2_7P421 + + sntp/invoke-sntp.texi@1.410 +2 -2 + NTP_4_2_7P421 + + sntp/sntp-opts.c@1.425 +7 -7 + NTP_4_2_7P421 + + sntp/sntp-opts.h@1.425 +3 -3 + NTP_4_2_7P421 + + sntp/sntp.1sntpman@1.245 +14 -14 + NTP_4_2_7P421 + + sntp/sntp.1sntpmdoc@1.245 +4 -4 + NTP_4_2_7P421 + + sntp/sntp.html@1.425 +2 -2 + NTP_4_2_7P421 + + sntp/sntp.man.in@1.245 +14 -14 + NTP_4_2_7P421 + + sntp/sntp.mdoc.in@1.245 +4 -4 + NTP_4_2_7P421 + + util/invoke-ntp-keygen.texi@1.414 +2 -2 + NTP_4_2_7P421 + + util/ntp-keygen-opts.c@1.428 +7 -7 + NTP_4_2_7P421 + + util/ntp-keygen-opts.h@1.428 +3 -3 + NTP_4_2_7P421 + + util/ntp-keygen.1ntp-keygenman@1.242 +7 -7 + NTP_4_2_7P421 + + util/ntp-keygen.1ntp-keygenmdoc@1.242 +4 -4 + NTP_4_2_7P421 + + util/ntp-keygen.html@1.90 +2 -2 + NTP_4_2_7P421 + + util/ntp-keygen.man.in@1.242 +7 -7 + NTP_4_2_7P421 + + util/ntp-keygen.mdoc.in@1.242 +4 -4 + NTP_4_2_7P421 + +ChangeSet@1.3092, 2014-02-10 15:34:22-05:00, stenn@deacon.udel.edu + calc_tickadj/Makefile.am man/mdoc page build cleanup + + .point-changed-filelist@1.24 +6 -0 + +ChangeSet@1.3091, 2014-02-10 02:35:55-05:00, stenn@deacon.udel.edu + calc_tickadj/Makefile.am man/mdoc page build cleanup + + ChangeLog@1.1422 +1 -0 + calc_tickadj/Makefile.am man/mdoc page build cleanup + + scripts/calc_tickadj/Makefile.am@1.8 +11 -0 + calc_tickadj/Makefile.am man/mdoc page build cleanup + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.3 +32 -3 + calc_tickadj/Makefile.am man/mdoc page build cleanup + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.3 +22 -3 + calc_tickadj/Makefile.am man/mdoc page build cleanup + + scripts/calc_tickadj/calc_tickadj.man.in@1.2 +37 -3 + calc_tickadj/Makefile.am man/mdoc page build cleanup + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.3 +22 -3 + calc_tickadj/Makefile.am man/mdoc page build cleanup + +ChangeSet@1.3090, 2014-02-10 01:17:38-05:00, stenn@deacon.udel.edu + [Bug 2555] Autogen mdoc man pages all stamped with SunOS 5.10 + + ChangeLog@1.1421 +1 -0 + [Bug 2555] Autogen mdoc man pages all stamped with SunOS 5.10 + + sntp/ag-tpl/agmdoc-cmd.tpl@1.2 +1 -1 + [Bug 2555] Autogen mdoc man pages all stamped with SunOS 5.10 + +ChangeSet@1.3089, 2014-02-10 05:55:42+00:00, stenn@psp-fb1.ntp.org + [Bug 898] More documentation fixes + + ChangeLog@1.1420 +1 -0 + [Bug 898] More documentation fixes + + html/ntpd.html@1.60 +4 -3 + [Bug 898] More documentation fixes + +ChangeSet@1.3088, 2014-02-09 11:19:15+00:00, stenn@deacon.udel.edu + NTP_4_2_7P420 + TAG: NTP_4_2_7P420 + + ChangeLog@1.1419 +1 -0 + NTP_4_2_7P420 + + ntpd/invoke-ntp.conf.texi@1.98 +1 -1 + NTP_4_2_7P420 + + ntpd/invoke-ntp.keys.texi@1.96 +1 -1 + NTP_4_2_7P420 + + ntpd/invoke-ntpd.texi@1.412 +2 -2 + NTP_4_2_7P420 + + ntpd/ntp.conf.5man@1.132 +7 -7 + NTP_4_2_7P420 + + ntpd/ntp.conf.5mdoc@1.132 +3 -3 + NTP_4_2_7P420 + + ntpd/ntp.conf.html@1.93 +1 -1 + NTP_4_2_7P420 + + ntpd/ntp.conf.man.in@1.132 +7 -7 + NTP_4_2_7P420 + + ntpd/ntp.conf.mdoc.in@1.132 +3 -3 + NTP_4_2_7P420 + + ntpd/ntp.keys.5man@1.130 +3 -3 + NTP_4_2_7P420 + + ntpd/ntp.keys.5mdoc@1.130 +3 -3 + NTP_4_2_7P420 + + ntpd/ntp.keys.html@1.94 +1 -1 + NTP_4_2_7P420 + + ntpd/ntp.keys.man.in@1.130 +3 -3 + NTP_4_2_7P420 + + ntpd/ntp.keys.mdoc.in@1.130 +3 -3 + NTP_4_2_7P420 + + ntpd/ntpd-opts.c@1.430 +7 -7 + NTP_4_2_7P420 + + ntpd/ntpd-opts.h@1.430 +3 -3 + NTP_4_2_7P420 + + ntpd/ntpd.1ntpdman@1.241 +7 -7 + NTP_4_2_7P420 + + ntpd/ntpd.1ntpdmdoc@1.241 +3 -3 + NTP_4_2_7P420 + + ntpd/ntpd.html@1.88 +2 -2 + NTP_4_2_7P420 + + ntpd/ntpd.man.in@1.241 +7 -7 + NTP_4_2_7P420 + + ntpd/ntpd.mdoc.in@1.241 +3 -3 + NTP_4_2_7P420 + + ntpdc/invoke-ntpdc.texi@1.410 +2 -2 + NTP_4_2_7P420 + + ntpdc/ntpdc-opts.c@1.425 +7 -7 + NTP_4_2_7P420 + + ntpdc/ntpdc-opts.h@1.425 +3 -3 + NTP_4_2_7P420 + + ntpdc/ntpdc.1ntpdcman@1.241 +6 -6 + NTP_4_2_7P420 + + ntpdc/ntpdc.1ntpdcmdoc@1.241 +2 -2 + NTP_4_2_7P420 + + ntpdc/ntpdc.html@1.254 +2 -2 + NTP_4_2_7P420 + + ntpdc/ntpdc.man.in@1.241 +6 -6 + NTP_4_2_7P420 + + ntpdc/ntpdc.mdoc.in@1.241 +2 -2 + NTP_4_2_7P420 + + ntpq/invoke-ntpq.texi@1.413 +2 -2 + NTP_4_2_7P420 + + ntpq/ntpq-opts.c@1.427 +7 -7 + NTP_4_2_7P420 + + ntpq/ntpq-opts.h@1.427 +3 -3 + NTP_4_2_7P420 + + ntpq/ntpq.1ntpqman@1.241 +6 -6 + NTP_4_2_7P420 + + ntpq/ntpq.1ntpqmdoc@1.241 +2 -2 + NTP_4_2_7P420 + + ntpq/ntpq.html@1.85 +2 -2 + NTP_4_2_7P420 + + ntpq/ntpq.man.in@1.241 +6 -6 + NTP_4_2_7P420 + + ntpq/ntpq.mdoc.in@1.241 +2 -2 + NTP_4_2_7P420 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.412 +2 -2 + NTP_4_2_7P420 + + ntpsnmpd/ntpsnmpd-opts.c@1.427 +7 -7 + NTP_4_2_7P420 + + ntpsnmpd/ntpsnmpd-opts.h@1.427 +3 -3 + NTP_4_2_7P420 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.241 +7 -7 + NTP_4_2_7P420 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.241 +3 -3 + NTP_4_2_7P420 + + ntpsnmpd/ntpsnmpd.html@1.83 +1 -1 + NTP_4_2_7P420 + + ntpsnmpd/ntpsnmpd.man.in@1.241 +7 -7 + NTP_4_2_7P420 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.241 +3 -3 + NTP_4_2_7P420 + + packageinfo.sh@1.424 +1 -1 + NTP_4_2_7P420 + + scripts/invoke-plot_summary.texi@1.21 +1 -1 + NTP_4_2_7P420 + + scripts/invoke-summary.texi@1.21 +1 -1 + NTP_4_2_7P420 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.230 +1 -1 + NTP_4_2_7P420 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.231 +6 -6 + NTP_4_2_7P420 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.231 +2 -2 + NTP_4_2_7P420 + + scripts/ntp-wait/ntp-wait.html@1.247 +1 -1 + NTP_4_2_7P420 + + scripts/ntp-wait/ntp-wait.man.in@1.231 +6 -6 + NTP_4_2_7P420 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.231 +2 -2 + NTP_4_2_7P420 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.19 +1 -1 + NTP_4_2_7P420 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.10 +6 -6 + NTP_4_2_7P420 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.10 +2 -2 + NTP_4_2_7P420 + + scripts/ntpsweep/ntpsweep.html@1.20 +1 -1 + NTP_4_2_7P420 + + scripts/ntpsweep/ntpsweep.man.in@1.10 +6 -6 + NTP_4_2_7P420 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.11 +2 -2 + NTP_4_2_7P420 + + scripts/ntptrace/invoke-ntptrace.texi@1.19 +1 -1 + NTP_4_2_7P420 + + scripts/ntptrace/ntptrace.1ntptraceman@1.10 +6 -6 + NTP_4_2_7P420 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.10 +2 -2 + NTP_4_2_7P420 + + scripts/ntptrace/ntptrace.html@1.20 +1 -1 + NTP_4_2_7P420 + + scripts/ntptrace/ntptrace.man.in@1.10 +6 -6 + NTP_4_2_7P420 + + scripts/ntptrace/ntptrace.mdoc.in@1.11 +2 -2 + NTP_4_2_7P420 + + scripts/plot_summary.1plot_summaryman@1.21 +6 -6 + NTP_4_2_7P420 + + scripts/plot_summary.1plot_summarymdoc@1.21 +2 -2 + NTP_4_2_7P420 + + scripts/plot_summary.html@1.21 +1 -1 + NTP_4_2_7P420 + + scripts/plot_summary.man.in@1.21 +6 -6 + NTP_4_2_7P420 + + scripts/plot_summary.mdoc.in@1.21 +2 -2 + NTP_4_2_7P420 + + scripts/summary.1summaryman@1.21 +6 -6 + NTP_4_2_7P420 + + scripts/summary.1summarymdoc@1.21 +2 -2 + NTP_4_2_7P420 + + scripts/summary.html@1.21 +1 -1 + NTP_4_2_7P420 + + scripts/summary.man.in@1.21 +6 -6 + NTP_4_2_7P420 + + scripts/summary.mdoc.in@1.21 +2 -2 + NTP_4_2_7P420 + + sntp/invoke-sntp.texi@1.409 +2 -2 + NTP_4_2_7P420 + + sntp/sntp-opts.c@1.424 +7 -7 + NTP_4_2_7P420 + + sntp/sntp-opts.h@1.424 +3 -3 + NTP_4_2_7P420 + + sntp/sntp.1sntpman@1.244 +7 -7 + NTP_4_2_7P420 + + sntp/sntp.1sntpmdoc@1.244 +3 -3 + NTP_4_2_7P420 + + sntp/sntp.html@1.424 +2 -2 + NTP_4_2_7P420 + + sntp/sntp.man.in@1.244 +7 -7 + NTP_4_2_7P420 + + sntp/sntp.mdoc.in@1.244 +3 -3 + NTP_4_2_7P420 + + util/invoke-ntp-keygen.texi@1.413 +2 -2 + NTP_4_2_7P420 + + util/ntp-keygen-opts.c@1.427 +7 -7 + NTP_4_2_7P420 + + util/ntp-keygen-opts.h@1.427 +3 -3 + NTP_4_2_7P420 + + util/ntp-keygen.1ntp-keygenman@1.241 +7 -7 + NTP_4_2_7P420 + + util/ntp-keygen.1ntp-keygenmdoc@1.241 +3 -3 + NTP_4_2_7P420 + + util/ntp-keygen.html@1.89 +2 -2 + NTP_4_2_7P420 + + util/ntp-keygen.man.in@1.241 +7 -7 + NTP_4_2_7P420 + + util/ntp-keygen.mdoc.in@1.241 +3 -3 + NTP_4_2_7P420 + +ChangeSet@1.3087, 2014-02-09 09:00:04+00:00, stenn@psp-fb1.ntp.org + [Sec 2542] Strengthen the mrulist nonce + + ChangeLog@1.1418 +1 -0 + [Sec 2542] Strengthen the mrulist nonce + + ntpd/ntp_control.c@1.188 +8 -3 + [Sec 2542] Strengthen the mrulist nonce + +ChangeSet@1.3086, 2014-02-09 03:37:08-05:00, stenn@deacon.udel.edu + [Bug 492] Clearly document ntpdate's pending deprecation + + ChangeLog@1.1417 +1 -0 + [Bug 492] Clearly document ntpdate's pending deprecation + + html/ntpdate.html@1.27 +11 -1 + [Bug 492] Clearly document ntpdate's pending deprecation + +ChangeSet@1.3085, 2014-02-09 08:09:56+00:00, stenn@psp-fb1.ntp.org + [Bug 1186] ntpd fails with link local IPv6 addresses + + ChangeLog@1.1416 +3 -2 + [Bug 1186] ntpd fails with link local IPv6 addresses + + ntpd/ntp_io.c@1.389 +11 -6 + [Bug 1186] ntpd fails with link local IPv6 addresses + +ChangeSet@1.3084, 2014-02-08 11:29:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P419 + TAG: NTP_4_2_7P419 + + ChangeLog@1.1415 +1 -0 + NTP_4_2_7P419 + + ntpd/invoke-ntp.conf.texi@1.97 +1 -1 + NTP_4_2_7P419 + + ntpd/invoke-ntp.keys.texi@1.95 +1 -1 + NTP_4_2_7P419 + + ntpd/invoke-ntpd.texi@1.411 +2 -2 + NTP_4_2_7P419 + + ntpd/ntp.conf.5man@1.131 +7 -7 + NTP_4_2_7P419 + + ntpd/ntp.conf.5mdoc@1.131 +3 -3 + NTP_4_2_7P419 + + ntpd/ntp.conf.html@1.92 +1 -1 + NTP_4_2_7P419 + + ntpd/ntp.conf.man.in@1.131 +7 -7 + NTP_4_2_7P419 + + ntpd/ntp.conf.mdoc.in@1.131 +3 -3 + NTP_4_2_7P419 + + ntpd/ntp.keys.5man@1.129 +3 -3 + NTP_4_2_7P419 + + ntpd/ntp.keys.5mdoc@1.129 +3 -3 + NTP_4_2_7P419 + + ntpd/ntp.keys.html@1.93 +1 -1 + NTP_4_2_7P419 + + ntpd/ntp.keys.man.in@1.129 +3 -3 + NTP_4_2_7P419 + + ntpd/ntp.keys.mdoc.in@1.129 +3 -3 + NTP_4_2_7P419 + + ntpd/ntpd-opts.c@1.429 +7 -7 + NTP_4_2_7P419 + + ntpd/ntpd-opts.h@1.429 +3 -3 + NTP_4_2_7P419 + + ntpd/ntpd.1ntpdman@1.240 +14 -14 + NTP_4_2_7P419 + + ntpd/ntpd.1ntpdmdoc@1.240 +3 -3 + NTP_4_2_7P419 + + ntpd/ntpd.html@1.87 +2 -2 + NTP_4_2_7P419 + + ntpd/ntpd.man.in@1.240 +14 -14 + NTP_4_2_7P419 + + ntpd/ntpd.mdoc.in@1.240 +3 -3 + NTP_4_2_7P419 + + ntpdc/invoke-ntpdc.texi@1.409 +2 -2 + NTP_4_2_7P419 + + ntpdc/ntpdc-opts.c@1.424 +7 -7 + NTP_4_2_7P419 + + ntpdc/ntpdc-opts.h@1.424 +3 -3 + NTP_4_2_7P419 + + ntpdc/ntpdc.1ntpdcman@1.240 +6 -6 + NTP_4_2_7P419 + + ntpdc/ntpdc.1ntpdcmdoc@1.240 +2 -2 + NTP_4_2_7P419 + + ntpdc/ntpdc.html@1.253 +2 -2 + NTP_4_2_7P419 + + ntpdc/ntpdc.man.in@1.240 +6 -6 + NTP_4_2_7P419 + + ntpdc/ntpdc.mdoc.in@1.240 +2 -2 + NTP_4_2_7P419 + + ntpq/invoke-ntpq.texi@1.412 +2 -2 + NTP_4_2_7P419 + + ntpq/ntpq-opts.c@1.426 +7 -7 + NTP_4_2_7P419 + + ntpq/ntpq-opts.h@1.426 +3 -3 + NTP_4_2_7P419 + + ntpq/ntpq.1ntpqman@1.240 +6 -6 + NTP_4_2_7P419 + + ntpq/ntpq.1ntpqmdoc@1.240 +2 -2 + NTP_4_2_7P419 + + ntpq/ntpq.html@1.84 +2 -2 + NTP_4_2_7P419 + + ntpq/ntpq.man.in@1.240 +6 -6 + NTP_4_2_7P419 + + ntpq/ntpq.mdoc.in@1.240 +2 -2 + NTP_4_2_7P419 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.411 +2 -2 + NTP_4_2_7P419 + + ntpsnmpd/ntpsnmpd-opts.c@1.426 +7 -7 + NTP_4_2_7P419 + + ntpsnmpd/ntpsnmpd-opts.h@1.426 +3 -3 + NTP_4_2_7P419 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.240 +7 -7 + NTP_4_2_7P419 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.240 +3 -3 + NTP_4_2_7P419 + + ntpsnmpd/ntpsnmpd.html@1.82 +1 -1 + NTP_4_2_7P419 + + ntpsnmpd/ntpsnmpd.man.in@1.240 +7 -7 + NTP_4_2_7P419 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.240 +3 -3 + NTP_4_2_7P419 + + packageinfo.sh@1.423 +1 -1 + NTP_4_2_7P419 + + scripts/invoke-plot_summary.texi@1.20 +1 -1 + NTP_4_2_7P419 + + scripts/invoke-summary.texi@1.20 +1 -1 + NTP_4_2_7P419 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.229 +1 -1 + NTP_4_2_7P419 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.230 +6 -6 + NTP_4_2_7P419 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.230 +2 -2 + NTP_4_2_7P419 + + scripts/ntp-wait/ntp-wait.html@1.246 +1 -1 + NTP_4_2_7P419 + + scripts/ntp-wait/ntp-wait.man.in@1.230 +6 -6 + NTP_4_2_7P419 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.230 +2 -2 + NTP_4_2_7P419 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.18 +1 -1 + NTP_4_2_7P419 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.9 +6 -6 + NTP_4_2_7P419 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.9 +2 -2 + NTP_4_2_7P419 + + scripts/ntpsweep/ntpsweep.html@1.19 +1 -1 + NTP_4_2_7P419 + + scripts/ntpsweep/ntpsweep.man.in@1.9 +6 -6 + NTP_4_2_7P419 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.10 +2 -2 + NTP_4_2_7P419 + + scripts/ntptrace/invoke-ntptrace.texi@1.18 +1 -1 + NTP_4_2_7P419 + + scripts/ntptrace/ntptrace.1ntptraceman@1.9 +6 -6 + NTP_4_2_7P419 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.9 +2 -2 + NTP_4_2_7P419 + + scripts/ntptrace/ntptrace.html@1.19 +1 -1 + NTP_4_2_7P419 + + scripts/ntptrace/ntptrace.man.in@1.9 +6 -6 + NTP_4_2_7P419 + + scripts/ntptrace/ntptrace.mdoc.in@1.10 +2 -2 + NTP_4_2_7P419 + + scripts/plot_summary.1plot_summaryman@1.20 +6 -6 + NTP_4_2_7P419 + + scripts/plot_summary.1plot_summarymdoc@1.20 +2 -2 + NTP_4_2_7P419 + + scripts/plot_summary.html@1.20 +1 -1 + NTP_4_2_7P419 + + scripts/plot_summary.man.in@1.20 +6 -6 + NTP_4_2_7P419 + + scripts/plot_summary.mdoc.in@1.20 +2 -2 + NTP_4_2_7P419 + + scripts/summary.1summaryman@1.20 +6 -6 + NTP_4_2_7P419 + + scripts/summary.1summarymdoc@1.20 +2 -2 + NTP_4_2_7P419 + + scripts/summary.html@1.20 +1 -1 + NTP_4_2_7P419 + + scripts/summary.man.in@1.20 +6 -6 + NTP_4_2_7P419 + + scripts/summary.mdoc.in@1.20 +2 -2 + NTP_4_2_7P419 + + sntp/invoke-sntp.texi@1.408 +2 -2 + NTP_4_2_7P419 + + sntp/sntp-opts.c@1.423 +7 -7 + NTP_4_2_7P419 + + sntp/sntp-opts.h@1.423 +3 -3 + NTP_4_2_7P419 + + sntp/sntp.1sntpman@1.243 +7 -7 + NTP_4_2_7P419 + + sntp/sntp.1sntpmdoc@1.243 +3 -3 + NTP_4_2_7P419 + + sntp/sntp.html@1.423 +2 -2 + NTP_4_2_7P419 + + sntp/sntp.man.in@1.243 +7 -7 + NTP_4_2_7P419 + + sntp/sntp.mdoc.in@1.243 +3 -3 + NTP_4_2_7P419 + + util/invoke-ntp-keygen.texi@1.412 +2 -2 + NTP_4_2_7P419 + + util/ntp-keygen-opts.c@1.426 +7 -7 + NTP_4_2_7P419 + + util/ntp-keygen-opts.h@1.426 +3 -3 + NTP_4_2_7P419 + + util/ntp-keygen.1ntp-keygenman@1.240 +7 -7 + NTP_4_2_7P419 + + util/ntp-keygen.1ntp-keygenmdoc@1.240 +3 -3 + NTP_4_2_7P419 + + util/ntp-keygen.html@1.88 +2 -2 + NTP_4_2_7P419 + + util/ntp-keygen.man.in@1.240 +7 -7 + NTP_4_2_7P419 + + util/ntp-keygen.mdoc.in@1.240 +3 -3 + NTP_4_2_7P419 + +ChangeSet@1.3052.1.1, 2014-02-08 08:52:51+01:00, jnperlin@hydra.(none) + [Bug 2466] Fold NMEA date into 1024 week cycles - GPS has no absolute date. + + ChangeLog@1.1387.1.1 +1 -0 + [Bug 2466] Fold NMEA date into 1024 week cycles - GPS has no absolute date. + + libntp/ntp_calendar.c@1.12 +17 -1 + [Bug 2466] Fold NMEA date into 1024 week cycles - GPS has no absolute date. + Evaluation of build date can be blocked for DEBUG builds by environment. + + ntpd/refclock_nmea.c@1.72.1.1 +156 -4 + [Bug 2466] Fold NMEA date into 1024 week cycles - GPS has no absolute date. + Refactored date evaluation into separate function. + +ChangeSet@1.3082, 2014-02-05 12:02:45+00:00, stenn@deacon.udel.edu + NTP_4_2_7P418 + TAG: NTP_4_2_7P418 + + ChangeLog@1.1413 +1 -0 + NTP_4_2_7P418 + + ntpd/invoke-ntp.conf.texi@1.96 +1 -1 + NTP_4_2_7P418 + + ntpd/invoke-ntp.keys.texi@1.94 +1 -1 + NTP_4_2_7P418 + + ntpd/invoke-ntpd.texi@1.410 +2 -2 + NTP_4_2_7P418 + + ntpd/ntp.conf.5man@1.130 +7 -7 + NTP_4_2_7P418 + + ntpd/ntp.conf.5mdoc@1.130 +3 -3 + NTP_4_2_7P418 + + ntpd/ntp.conf.html@1.91 +1 -1 + NTP_4_2_7P418 + + ntpd/ntp.conf.man.in@1.130 +7 -7 + NTP_4_2_7P418 + + ntpd/ntp.conf.mdoc.in@1.130 +3 -3 + NTP_4_2_7P418 + + ntpd/ntp.keys.5man@1.128 +3 -3 + NTP_4_2_7P418 + + ntpd/ntp.keys.5mdoc@1.128 +3 -3 + NTP_4_2_7P418 + + ntpd/ntp.keys.html@1.92 +1 -1 + NTP_4_2_7P418 + + ntpd/ntp.keys.man.in@1.128 +3 -3 + NTP_4_2_7P418 + + ntpd/ntp.keys.mdoc.in@1.128 +3 -3 + NTP_4_2_7P418 + + ntpd/ntpd-opts.c@1.428 +7 -7 + NTP_4_2_7P418 + + ntpd/ntpd-opts.h@1.428 +3 -3 + NTP_4_2_7P418 + + ntpd/ntpd.1ntpdman@1.239 +14 -14 + NTP_4_2_7P418 + + ntpd/ntpd.1ntpdmdoc@1.239 +3 -3 + NTP_4_2_7P418 + + ntpd/ntpd.html@1.86 +2 -2 + NTP_4_2_7P418 + + ntpd/ntpd.man.in@1.239 +14 -14 + NTP_4_2_7P418 + + ntpd/ntpd.mdoc.in@1.239 +3 -3 + NTP_4_2_7P418 + + ntpdc/invoke-ntpdc.texi@1.408 +2 -2 + NTP_4_2_7P418 + + ntpdc/ntpdc-opts.c@1.423 +7 -7 + NTP_4_2_7P418 + + ntpdc/ntpdc-opts.h@1.423 +3 -3 + NTP_4_2_7P418 + + ntpdc/ntpdc.1ntpdcman@1.239 +6 -6 + NTP_4_2_7P418 + + ntpdc/ntpdc.1ntpdcmdoc@1.239 +2 -2 + NTP_4_2_7P418 + + ntpdc/ntpdc.html@1.252 +2 -2 + NTP_4_2_7P418 + + ntpdc/ntpdc.man.in@1.239 +6 -6 + NTP_4_2_7P418 + + ntpdc/ntpdc.mdoc.in@1.239 +2 -2 + NTP_4_2_7P418 + + ntpq/invoke-ntpq.texi@1.411 +2 -2 + NTP_4_2_7P418 + + ntpq/ntpq-opts.c@1.425 +7 -7 + NTP_4_2_7P418 + + ntpq/ntpq-opts.h@1.425 +3 -3 + NTP_4_2_7P418 + + ntpq/ntpq.1ntpqman@1.239 +6 -6 + NTP_4_2_7P418 + + ntpq/ntpq.1ntpqmdoc@1.239 +2 -2 + NTP_4_2_7P418 + + ntpq/ntpq.html@1.83 +2 -2 + NTP_4_2_7P418 + + ntpq/ntpq.man.in@1.239 +6 -6 + NTP_4_2_7P418 + + ntpq/ntpq.mdoc.in@1.239 +2 -2 + NTP_4_2_7P418 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.410 +2 -2 + NTP_4_2_7P418 + + ntpsnmpd/ntpsnmpd-opts.c@1.425 +7 -7 + NTP_4_2_7P418 + + ntpsnmpd/ntpsnmpd-opts.h@1.425 +3 -3 + NTP_4_2_7P418 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.239 +7 -7 + NTP_4_2_7P418 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.239 +3 -3 + NTP_4_2_7P418 + + ntpsnmpd/ntpsnmpd.html@1.81 +1 -1 + NTP_4_2_7P418 + + ntpsnmpd/ntpsnmpd.man.in@1.239 +7 -7 + NTP_4_2_7P418 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.239 +3 -3 + NTP_4_2_7P418 + + packageinfo.sh@1.422 +1 -1 + NTP_4_2_7P418 + + scripts/invoke-plot_summary.texi@1.19 +1 -1 + NTP_4_2_7P418 + + scripts/invoke-summary.texi@1.19 +1 -1 + NTP_4_2_7P418 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.228 +1 -1 + NTP_4_2_7P418 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.229 +6 -6 + NTP_4_2_7P418 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.229 +2 -2 + NTP_4_2_7P418 + + scripts/ntp-wait/ntp-wait.html@1.245 +1 -1 + NTP_4_2_7P418 + + scripts/ntp-wait/ntp-wait.man.in@1.229 +6 -6 + NTP_4_2_7P418 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.229 +2 -2 + NTP_4_2_7P418 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.17 +1 -1 + NTP_4_2_7P418 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.8 +6 -6 + NTP_4_2_7P418 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.8 +2 -2 + NTP_4_2_7P418 + + scripts/ntpsweep/ntpsweep.html@1.18 +1 -1 + NTP_4_2_7P418 + + scripts/ntpsweep/ntpsweep.man.in@1.8 +6 -6 + NTP_4_2_7P418 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.9 +2 -2 + NTP_4_2_7P418 + + scripts/ntptrace/invoke-ntptrace.texi@1.17 +1 -1 + NTP_4_2_7P418 + + scripts/ntptrace/ntptrace.1ntptraceman@1.8 +6 -6 + NTP_4_2_7P418 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.8 +2 -2 + NTP_4_2_7P418 + + scripts/ntptrace/ntptrace.html@1.18 +1 -1 + NTP_4_2_7P418 + + scripts/ntptrace/ntptrace.man.in@1.8 +6 -6 + NTP_4_2_7P418 + + scripts/ntptrace/ntptrace.mdoc.in@1.9 +2 -2 + NTP_4_2_7P418 + + scripts/plot_summary.1plot_summaryman@1.19 +6 -6 + NTP_4_2_7P418 + + scripts/plot_summary.1plot_summarymdoc@1.19 +2 -2 + NTP_4_2_7P418 + + scripts/plot_summary.html@1.19 +1 -1 + NTP_4_2_7P418 + + scripts/plot_summary.man.in@1.19 +6 -6 + NTP_4_2_7P418 + + scripts/plot_summary.mdoc.in@1.19 +2 -2 + NTP_4_2_7P418 + + scripts/summary.1summaryman@1.19 +6 -6 + NTP_4_2_7P418 + + scripts/summary.1summarymdoc@1.19 +2 -2 + NTP_4_2_7P418 + + scripts/summary.html@1.19 +1 -1 + NTP_4_2_7P418 + + scripts/summary.man.in@1.19 +6 -6 + NTP_4_2_7P418 + + scripts/summary.mdoc.in@1.19 +2 -2 + NTP_4_2_7P418 + + sntp/invoke-sntp.texi@1.407 +2 -2 + NTP_4_2_7P418 + + sntp/sntp-opts.c@1.422 +7 -7 + NTP_4_2_7P418 + + sntp/sntp-opts.h@1.422 +3 -3 + NTP_4_2_7P418 + + sntp/sntp.1sntpman@1.242 +7 -7 + NTP_4_2_7P418 + + sntp/sntp.1sntpmdoc@1.242 +3 -3 + NTP_4_2_7P418 + + sntp/sntp.html@1.422 +2 -2 + NTP_4_2_7P418 + + sntp/sntp.man.in@1.242 +7 -7 + NTP_4_2_7P418 + + sntp/sntp.mdoc.in@1.242 +3 -3 + NTP_4_2_7P418 + + util/invoke-ntp-keygen.texi@1.411 +2 -2 + NTP_4_2_7P418 + + util/ntp-keygen-opts.c@1.425 +7 -7 + NTP_4_2_7P418 + + util/ntp-keygen-opts.h@1.425 +3 -3 + NTP_4_2_7P418 + + util/ntp-keygen.1ntp-keygenman@1.239 +7 -7 + NTP_4_2_7P418 + + util/ntp-keygen.1ntp-keygenmdoc@1.239 +3 -3 + NTP_4_2_7P418 + + util/ntp-keygen.html@1.87 +2 -2 + NTP_4_2_7P418 + + util/ntp-keygen.man.in@1.239 +7 -7 + NTP_4_2_7P418 + + util/ntp-keygen.mdoc.in@1.239 +3 -3 + NTP_4_2_7P418 + +ChangeSet@1.3081, 2014-02-05 07:02:58+00:00, stenn@psp-deb1.ntp.org + [Bug 2551] --disable-local-libevent breaks the build + + ChangeLog@1.1412 +1 -0 + [Bug 2551] --disable-local-libevent breaks the build + + sntp/m4/ntp_libevent.m4@1.10 +1 -3 + [Bug 2551] --disable-local-libevent breaks the build + +ChangeSet@1.3080, 2014-02-02 11:35:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P417 + TAG: NTP_4_2_7P417 + + ChangeLog@1.1411 +1 -0 + NTP_4_2_7P417 + + ntpd/invoke-ntp.conf.texi@1.95 +1 -1 + NTP_4_2_7P417 + + ntpd/invoke-ntp.keys.texi@1.93 +1 -1 + NTP_4_2_7P417 + + ntpd/invoke-ntpd.texi@1.409 +2 -2 + NTP_4_2_7P417 + + ntpd/ntp.conf.5man@1.129 +7 -7 + NTP_4_2_7P417 + + ntpd/ntp.conf.5mdoc@1.129 +3 -3 + NTP_4_2_7P417 + + ntpd/ntp.conf.html@1.90 +1 -1 + NTP_4_2_7P417 + + ntpd/ntp.conf.man.in@1.129 +7 -7 + NTP_4_2_7P417 + + ntpd/ntp.conf.mdoc.in@1.129 +3 -3 + NTP_4_2_7P417 + + ntpd/ntp.keys.5man@1.127 +3 -3 + NTP_4_2_7P417 + + ntpd/ntp.keys.5mdoc@1.127 +3 -3 + NTP_4_2_7P417 + + ntpd/ntp.keys.html@1.91 +1 -1 + NTP_4_2_7P417 + + ntpd/ntp.keys.man.in@1.127 +3 -3 + NTP_4_2_7P417 + + ntpd/ntp.keys.mdoc.in@1.127 +3 -3 + NTP_4_2_7P417 + + ntpd/ntpd-opts.c@1.427 +7 -7 + NTP_4_2_7P417 + + ntpd/ntpd-opts.h@1.427 +3 -3 + NTP_4_2_7P417 + + ntpd/ntpd.1ntpdman@1.238 +7 -7 + NTP_4_2_7P417 + + ntpd/ntpd.1ntpdmdoc@1.238 +3 -3 + NTP_4_2_7P417 + + ntpd/ntpd.html@1.85 +2 -2 + NTP_4_2_7P417 + + ntpd/ntpd.man.in@1.238 +7 -7 + NTP_4_2_7P417 + + ntpd/ntpd.mdoc.in@1.238 +3 -3 + NTP_4_2_7P417 + + ntpdc/invoke-ntpdc.texi@1.407 +2 -2 + NTP_4_2_7P417 + + ntpdc/ntpdc-opts.c@1.422 +7 -7 + NTP_4_2_7P417 + + ntpdc/ntpdc-opts.h@1.422 +3 -3 + NTP_4_2_7P417 + + ntpdc/ntpdc.1ntpdcman@1.238 +6 -6 + NTP_4_2_7P417 + + ntpdc/ntpdc.1ntpdcmdoc@1.238 +2 -2 + NTP_4_2_7P417 + + ntpdc/ntpdc.html@1.251 +2 -2 + NTP_4_2_7P417 + + ntpdc/ntpdc.man.in@1.238 +6 -6 + NTP_4_2_7P417 + + ntpdc/ntpdc.mdoc.in@1.238 +2 -2 + NTP_4_2_7P417 + + ntpq/invoke-ntpq.texi@1.410 +2 -2 + NTP_4_2_7P417 + + ntpq/ntpq-opts.c@1.424 +7 -7 + NTP_4_2_7P417 + + ntpq/ntpq-opts.h@1.424 +3 -3 + NTP_4_2_7P417 + + ntpq/ntpq.1ntpqman@1.238 +6 -6 + NTP_4_2_7P417 + + ntpq/ntpq.1ntpqmdoc@1.238 +2 -2 + NTP_4_2_7P417 + + ntpq/ntpq.html@1.82 +2 -2 + NTP_4_2_7P417 + + ntpq/ntpq.man.in@1.238 +6 -6 + NTP_4_2_7P417 + + ntpq/ntpq.mdoc.in@1.238 +2 -2 + NTP_4_2_7P417 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.409 +2 -2 + NTP_4_2_7P417 + + ntpsnmpd/ntpsnmpd-opts.c@1.424 +7 -7 + NTP_4_2_7P417 + + ntpsnmpd/ntpsnmpd-opts.h@1.424 +3 -3 + NTP_4_2_7P417 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.238 +7 -7 + NTP_4_2_7P417 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.238 +3 -3 + NTP_4_2_7P417 + + ntpsnmpd/ntpsnmpd.html@1.80 +1 -1 + NTP_4_2_7P417 + + ntpsnmpd/ntpsnmpd.man.in@1.238 +7 -7 + NTP_4_2_7P417 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.238 +3 -3 + NTP_4_2_7P417 + + packageinfo.sh@1.421 +1 -1 + NTP_4_2_7P417 + + scripts/invoke-plot_summary.texi@1.18 +1 -1 + NTP_4_2_7P417 + + scripts/invoke-summary.texi@1.18 +1 -1 + NTP_4_2_7P417 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.227 +1 -1 + NTP_4_2_7P417 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.228 +6 -6 + NTP_4_2_7P417 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.228 +2 -2 + NTP_4_2_7P417 + + scripts/ntp-wait/ntp-wait.html@1.244 +1 -1 + NTP_4_2_7P417 + + scripts/ntp-wait/ntp-wait.man.in@1.228 +6 -6 + NTP_4_2_7P417 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.228 +2 -2 + NTP_4_2_7P417 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.16 +1 -1 + NTP_4_2_7P417 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.7 +6 -6 + NTP_4_2_7P417 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.7 +2 -2 + NTP_4_2_7P417 + + scripts/ntpsweep/ntpsweep.html@1.17 +1 -1 + NTP_4_2_7P417 + + scripts/ntpsweep/ntpsweep.man.in@1.7 +6 -6 + NTP_4_2_7P417 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.8 +2 -2 + NTP_4_2_7P417 + + scripts/ntptrace/invoke-ntptrace.texi@1.16 +1 -1 + NTP_4_2_7P417 + + scripts/ntptrace/ntptrace.1ntptraceman@1.7 +6 -6 + NTP_4_2_7P417 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.7 +2 -2 + NTP_4_2_7P417 + + scripts/ntptrace/ntptrace.html@1.17 +1 -1 + NTP_4_2_7P417 + + scripts/ntptrace/ntptrace.man.in@1.7 +6 -6 + NTP_4_2_7P417 + + scripts/ntptrace/ntptrace.mdoc.in@1.8 +2 -2 + NTP_4_2_7P417 + + scripts/plot_summary.1plot_summaryman@1.18 +6 -6 + NTP_4_2_7P417 + + scripts/plot_summary.1plot_summarymdoc@1.18 +2 -2 + NTP_4_2_7P417 + + scripts/plot_summary.html@1.18 +1 -1 + NTP_4_2_7P417 + + scripts/plot_summary.man.in@1.18 +6 -6 + NTP_4_2_7P417 + + scripts/plot_summary.mdoc.in@1.18 +2 -2 + NTP_4_2_7P417 + + scripts/summary.1summaryman@1.18 +6 -6 + NTP_4_2_7P417 + + scripts/summary.1summarymdoc@1.18 +2 -2 + NTP_4_2_7P417 + + scripts/summary.html@1.18 +1 -1 + NTP_4_2_7P417 + + scripts/summary.man.in@1.18 +6 -6 + NTP_4_2_7P417 + + scripts/summary.mdoc.in@1.18 +2 -2 + NTP_4_2_7P417 + + sntp/invoke-sntp.texi@1.406 +2 -2 + NTP_4_2_7P417 + + sntp/sntp-opts.c@1.421 +7 -7 + NTP_4_2_7P417 + + sntp/sntp-opts.h@1.421 +3 -3 + NTP_4_2_7P417 + + sntp/sntp.1sntpman@1.241 +7 -7 + NTP_4_2_7P417 + + sntp/sntp.1sntpmdoc@1.241 +3 -3 + NTP_4_2_7P417 + + sntp/sntp.html@1.421 +2 -2 + NTP_4_2_7P417 + + sntp/sntp.man.in@1.241 +7 -7 + NTP_4_2_7P417 + + sntp/sntp.mdoc.in@1.241 +3 -3 + NTP_4_2_7P417 + + util/invoke-ntp-keygen.texi@1.410 +2 -2 + NTP_4_2_7P417 + + util/ntp-keygen-opts.c@1.424 +7 -7 + NTP_4_2_7P417 + + util/ntp-keygen-opts.h@1.424 +3 -3 + NTP_4_2_7P417 + + util/ntp-keygen.1ntp-keygenman@1.238 +7 -7 + NTP_4_2_7P417 + + util/ntp-keygen.1ntp-keygenmdoc@1.238 +3 -3 + NTP_4_2_7P417 + + util/ntp-keygen.html@1.86 +2 -2 + NTP_4_2_7P417 + + util/ntp-keygen.man.in@1.238 +7 -7 + NTP_4_2_7P417 + + util/ntp-keygen.mdoc.in@1.238 +3 -3 + NTP_4_2_7P417 + +ChangeSet@1.3075.1.4, 2014-01-31 12:14:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P416 + TAG: NTP_4_2_7P416 + + ChangeLog@1.1406.1.4 +1 -0 + NTP_4_2_7P416 + + ntpd/invoke-ntp.conf.texi@1.94 +1 -1 + NTP_4_2_7P416 + + ntpd/invoke-ntp.keys.texi@1.92 +1 -1 + NTP_4_2_7P416 + + ntpd/invoke-ntpd.texi@1.408 +2 -2 + NTP_4_2_7P416 + + ntpd/ntp.conf.5man@1.128 +7 -7 + NTP_4_2_7P416 + + ntpd/ntp.conf.5mdoc@1.128 +3 -3 + NTP_4_2_7P416 + + ntpd/ntp.conf.html@1.89 +1 -1 + NTP_4_2_7P416 + + ntpd/ntp.conf.man.in@1.128 +7 -7 + NTP_4_2_7P416 + + ntpd/ntp.conf.mdoc.in@1.128 +3 -3 + NTP_4_2_7P416 + + ntpd/ntp.keys.5man@1.126 +3 -3 + NTP_4_2_7P416 + + ntpd/ntp.keys.5mdoc@1.126 +3 -3 + NTP_4_2_7P416 + + ntpd/ntp.keys.html@1.90 +1 -1 + NTP_4_2_7P416 + + ntpd/ntp.keys.man.in@1.126 +3 -3 + NTP_4_2_7P416 + + ntpd/ntp.keys.mdoc.in@1.126 +3 -3 + NTP_4_2_7P416 + + ntpd/ntpd-opts.c@1.426 +7 -7 + NTP_4_2_7P416 + + ntpd/ntpd-opts.h@1.426 +3 -3 + NTP_4_2_7P416 + + ntpd/ntpd.1ntpdman@1.237 +7 -7 + NTP_4_2_7P416 + + ntpd/ntpd.1ntpdmdoc@1.237 +3 -3 + NTP_4_2_7P416 + + ntpd/ntpd.html@1.84 +2 -2 + NTP_4_2_7P416 + + ntpd/ntpd.man.in@1.237 +7 -7 + NTP_4_2_7P416 + + ntpd/ntpd.mdoc.in@1.237 +3 -3 + NTP_4_2_7P416 + + ntpdc/invoke-ntpdc.texi@1.406 +2 -2 + NTP_4_2_7P416 + + ntpdc/ntpdc-opts.c@1.421 +7 -7 + NTP_4_2_7P416 + + ntpdc/ntpdc-opts.h@1.421 +3 -3 + NTP_4_2_7P416 + + ntpdc/ntpdc.1ntpdcman@1.237 +32 -3 + NTP_4_2_7P416 + + ntpdc/ntpdc.1ntpdcmdoc@1.237 +21 -2 + NTP_4_2_7P416 + + ntpdc/ntpdc.html@1.250 +57 -77 + NTP_4_2_7P416 + + ntpdc/ntpdc.man.in@1.237 +32 -3 + NTP_4_2_7P416 + + ntpdc/ntpdc.mdoc.in@1.237 +21 -2 + NTP_4_2_7P416 + + ntpq/invoke-ntpq.texi@1.409 +2 -2 + NTP_4_2_7P416 + + ntpq/ntpq-opts.c@1.423 +7 -7 + NTP_4_2_7P416 + + ntpq/ntpq-opts.h@1.423 +3 -3 + NTP_4_2_7P416 + + ntpq/ntpq.1ntpqman@1.237 +6 -6 + NTP_4_2_7P416 + + ntpq/ntpq.1ntpqmdoc@1.237 +2 -2 + NTP_4_2_7P416 + + ntpq/ntpq.html@1.81 +2 -2 + NTP_4_2_7P416 + + ntpq/ntpq.man.in@1.237 +6 -6 + NTP_4_2_7P416 + + ntpq/ntpq.mdoc.in@1.237 +2 -2 + NTP_4_2_7P416 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.408 +2 -2 + NTP_4_2_7P416 + + ntpsnmpd/ntpsnmpd-opts.c@1.423 +7 -7 + NTP_4_2_7P416 + + ntpsnmpd/ntpsnmpd-opts.h@1.423 +3 -3 + NTP_4_2_7P416 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.237 +7 -7 + NTP_4_2_7P416 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.237 +3 -3 + NTP_4_2_7P416 + + ntpsnmpd/ntpsnmpd.html@1.79 +1 -1 + NTP_4_2_7P416 + + ntpsnmpd/ntpsnmpd.man.in@1.237 +7 -7 + NTP_4_2_7P416 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.237 +3 -3 + NTP_4_2_7P416 + + packageinfo.sh@1.420 +1 -1 + NTP_4_2_7P416 + + scripts/invoke-plot_summary.texi@1.17 +1 -1 + NTP_4_2_7P416 + + scripts/invoke-summary.texi@1.17 +1 -1 + NTP_4_2_7P416 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.226 +1 -1 + NTP_4_2_7P416 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.227 +6 -6 + NTP_4_2_7P416 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.227 +2 -2 + NTP_4_2_7P416 + + scripts/ntp-wait/ntp-wait.html@1.243 +1 -1 + NTP_4_2_7P416 + + scripts/ntp-wait/ntp-wait.man.in@1.227 +6 -6 + NTP_4_2_7P416 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.227 +2 -2 + NTP_4_2_7P416 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.15 +1 -1 + NTP_4_2_7P416 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.6 +6 -6 + NTP_4_2_7P416 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.6 +2 -2 + NTP_4_2_7P416 + + scripts/ntpsweep/ntpsweep.html@1.16 +1 -1 + NTP_4_2_7P416 + + scripts/ntpsweep/ntpsweep.man.in@1.6 +6 -6 + NTP_4_2_7P416 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.7 +2 -2 + NTP_4_2_7P416 + + scripts/ntptrace/invoke-ntptrace.texi@1.15 +1 -1 + NTP_4_2_7P416 + + scripts/ntptrace/ntptrace.1ntptraceman@1.6 +6 -6 + NTP_4_2_7P416 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.6 +2 -2 + NTP_4_2_7P416 + + scripts/ntptrace/ntptrace.html@1.16 +1 -1 + NTP_4_2_7P416 + + scripts/ntptrace/ntptrace.man.in@1.6 +6 -6 + NTP_4_2_7P416 + + scripts/ntptrace/ntptrace.mdoc.in@1.7 +2 -2 + NTP_4_2_7P416 + + scripts/plot_summary.1plot_summaryman@1.17 +6 -6 + NTP_4_2_7P416 + + scripts/plot_summary.1plot_summarymdoc@1.17 +2 -2 + NTP_4_2_7P416 + + scripts/plot_summary.html@1.17 +1 -1 + NTP_4_2_7P416 + + scripts/plot_summary.man.in@1.17 +6 -6 + NTP_4_2_7P416 + + scripts/plot_summary.mdoc.in@1.17 +2 -2 + NTP_4_2_7P416 + + scripts/summary.1summaryman@1.17 +6 -6 + NTP_4_2_7P416 + + scripts/summary.1summarymdoc@1.17 +2 -2 + NTP_4_2_7P416 + + scripts/summary.html@1.17 +1 -1 + NTP_4_2_7P416 + + scripts/summary.man.in@1.17 +6 -6 + NTP_4_2_7P416 + + scripts/summary.mdoc.in@1.17 +2 -2 + NTP_4_2_7P416 + + sntp/invoke-sntp.texi@1.405 +2 -2 + NTP_4_2_7P416 + + sntp/sntp-opts.c@1.420 +7 -7 + NTP_4_2_7P416 + + sntp/sntp-opts.h@1.420 +3 -3 + NTP_4_2_7P416 + + sntp/sntp.1sntpman@1.240 +7 -7 + NTP_4_2_7P416 + + sntp/sntp.1sntpmdoc@1.240 +3 -3 + NTP_4_2_7P416 + + sntp/sntp.html@1.420 +2 -2 + NTP_4_2_7P416 + + sntp/sntp.man.in@1.240 +7 -7 + NTP_4_2_7P416 + + sntp/sntp.mdoc.in@1.240 +3 -3 + NTP_4_2_7P416 + + util/invoke-ntp-keygen.texi@1.409 +2 -2 + NTP_4_2_7P416 + + util/ntp-keygen-opts.c@1.423 +7 -7 + NTP_4_2_7P416 + + util/ntp-keygen-opts.h@1.423 +3 -3 + NTP_4_2_7P416 + + util/ntp-keygen.1ntp-keygenman@1.237 +7 -7 + NTP_4_2_7P416 + + util/ntp-keygen.1ntp-keygenmdoc@1.237 +3 -3 + NTP_4_2_7P416 + + util/ntp-keygen.html@1.85 +2 -2 + NTP_4_2_7P416 + + util/ntp-keygen.man.in@1.237 +7 -7 + NTP_4_2_7P416 + + util/ntp-keygen.mdoc.in@1.237 +3 -3 + NTP_4_2_7P416 + +ChangeSet@1.3075.1.3, 2014-01-31 11:53:07+00:00, stenn@psp-fb1.ntp.org + Tweak the 'Modified' line on appropriate html pages + + ChangeLog@1.1406.1.3 +1 -0 + Tweak the 'Modified' line on appropriate html pages + + html/assoc.html@1.40 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/comdex.html@1.6 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/confopt.html@1.58.1.1 +3 -2 + Tweak the 'Modified' line on appropriate html pages + + html/decode.html@1.23 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/miscopt.html@1.77 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/monopt.html@1.37 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/ntpd.html@1.59 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/ntpdate.html@1.26 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/ntpdsim_new.html@1.8 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/ntpq.html@1.49 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/ntptrace.html@1.20 +3 -3 + Tweak the 'Modified' line on appropriate html pages + + html/refclock.html@1.40 +3 -3 + Tweak the 'Modified' line on appropriate html pages + +ChangeSet@1.3075.1.2, 2014-01-31 11:50:29+00:00, stenn@psp-fb1.ntp.org + Note in the deprecation of ntpdc in its documentation + + ChangeLog@1.1406.1.2 +1 -0 + Note in the deprecation of ntpdc in its documentation + + html/ntpdc.html@1.38 +6 -4 + Note in the deprecation of ntpdc in its documentation + + ntpdc/invoke-ntpdc.texi@1.405 +8 -1 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc-opts.c@1.420 +1 -1 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc-opts.def@1.22 +7 -0 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc-opts.h@1.420 +1 -1 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc.1ntpdcman@1.236 +12 -32 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc.1ntpdcmdoc@1.236 +10 -22 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc.html@1.249 +82 -55 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc.man.in@1.236 +12 -32 + Note in the deprecation of ntpdc in its documentation + + ntpdc/ntpdc.mdoc.in@1.236 +10 -22 + Note in the deprecation of ntpdc in its documentation + +ChangeSet@1.3075.1.1, 2014-01-31 11:48:11+00:00, stenn@psp-fb1.ntp.org + [Bug 2332] Be more careful about when we use 'libgcc_s' + + ChangeLog@1.1406.1.1 +1 -0 + [Bug 2332] Be more careful about when we use 'libgcc_s' + + sntp/m4/ntp_libntp.m4@1.26 +6 -4 + [Bug 2332] Be more careful about when we use 'libgcc_s' + +ChangeSet@1.3078, 2014-01-29 04:21:29-05:00, murray@pogo.udel.edu + ChangeLog: + Bug 2539, doc extra statistics and code fixe for NMEA driver + refclock_nmea.c: + expand extra counters + fix for missing NMEA sentence in clockstats + driver20.html: + document extra statistics + several minor fixes + + ChangeLog@1.1409 +1 -0 + Bug 2539, doc extra statistics and code fixe for NMEA driver + + html/drivers/driver20.html@1.27 +100 -6 + document extra statistics + several minor fixes + + ntpd/refclock_nmea.c@1.73 +22 -13 + expand extra counters + fix for missing NMEA sentence in clockstats + +ChangeSet@1.3077, 2014-01-29 04:16:00-05:00, murray@pogo.udel.edu + ChangeLog: + Add check for enable stats to ntpd/complete.conf.in + complete.conf.in: + Add check for enable stats + + ChangeLog@1.1408 +1 -0 + Add check for enable stats to ntpd/complete.conf.in + + ntpd/complete.conf.in@1.27 +2 -1 + Add check for enable stats + +ChangeSet@1.3076, 2014-01-29 04:12:05-05:00, murray@pogo.udel.edu + confopt.html, ChangeLog: + Fix typo + + ChangeLog@1.1407 +1 -0 + Fix typo + + html/confopt.html@1.59 +2 -2 + Fix typo + +ChangeSet@1.3075, 2014-01-28 12:18:50+00:00, stenn@deacon.udel.edu + NTP_4_2_7P415 + TAG: NTP_4_2_7P415 + + ChangeLog@1.1406 +1 -0 + NTP_4_2_7P415 + + ntpd/invoke-ntp.conf.texi@1.93 +1 -1 + NTP_4_2_7P415 + + ntpd/invoke-ntp.keys.texi@1.91 +1 -1 + NTP_4_2_7P415 + + ntpd/invoke-ntpd.texi@1.407 +2 -2 + NTP_4_2_7P415 + + ntpd/ntp.conf.5man@1.127 +7 -7 + NTP_4_2_7P415 + + ntpd/ntp.conf.5mdoc@1.127 +2 -2 + NTP_4_2_7P415 + + ntpd/ntp.conf.html@1.88 +2 -2 + NTP_4_2_7P415 + + ntpd/ntp.conf.man.in@1.127 +7 -7 + NTP_4_2_7P415 + + ntpd/ntp.conf.mdoc.in@1.127 +2 -2 + NTP_4_2_7P415 + + ntpd/ntp.keys.5man@1.125 +3 -3 + NTP_4_2_7P415 + + ntpd/ntp.keys.5mdoc@1.125 +2 -2 + NTP_4_2_7P415 + + ntpd/ntp.keys.html@1.89 +1 -1 + NTP_4_2_7P415 + + ntpd/ntp.keys.man.in@1.125 +3 -3 + NTP_4_2_7P415 + + ntpd/ntp.keys.mdoc.in@1.125 +2 -2 + NTP_4_2_7P415 + + ntpd/ntpd-opts.c@1.425 +7 -7 + NTP_4_2_7P415 + + ntpd/ntpd-opts.h@1.425 +3 -3 + NTP_4_2_7P415 + + ntpd/ntpd.1ntpdman@1.236 +7 -7 + NTP_4_2_7P415 + + ntpd/ntpd.1ntpdmdoc@1.236 +2 -2 + NTP_4_2_7P415 + + ntpd/ntpd.html@1.83 +2 -2 + NTP_4_2_7P415 + + ntpd/ntpd.man.in@1.236 +7 -7 + NTP_4_2_7P415 + + ntpd/ntpd.mdoc.in@1.236 +2 -2 + NTP_4_2_7P415 + + ntpdc/invoke-ntpdc.texi@1.404 +2 -2 + NTP_4_2_7P415 + + ntpdc/ntpdc-opts.c@1.419 +7 -7 + NTP_4_2_7P415 + + ntpdc/ntpdc-opts.h@1.419 +3 -3 + NTP_4_2_7P415 + + ntpdc/ntpdc.1ntpdcman@1.235 +6 -6 + NTP_4_2_7P415 + + ntpdc/ntpdc.1ntpdcmdoc@1.235 +1 -1 + NTP_4_2_7P415 + + ntpdc/ntpdc.html@1.248 +2 -2 + NTP_4_2_7P415 + + ntpdc/ntpdc.man.in@1.235 +6 -6 + NTP_4_2_7P415 + + ntpdc/ntpdc.mdoc.in@1.235 +1 -1 + NTP_4_2_7P415 + + ntpq/invoke-ntpq.texi@1.408 +2 -2 + NTP_4_2_7P415 + + ntpq/ntpq-opts.c@1.422 +7 -7 + NTP_4_2_7P415 + + ntpq/ntpq-opts.h@1.422 +3 -3 + NTP_4_2_7P415 + + ntpq/ntpq.1ntpqman@1.236 +6 -6 + NTP_4_2_7P415 + + ntpq/ntpq.1ntpqmdoc@1.236 +1 -1 + NTP_4_2_7P415 + + ntpq/ntpq.html@1.80 +2 -2 + NTP_4_2_7P415 + + ntpq/ntpq.man.in@1.236 +6 -6 + NTP_4_2_7P415 + + ntpq/ntpq.mdoc.in@1.236 +1 -1 + NTP_4_2_7P415 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.407 +2 -2 + NTP_4_2_7P415 + + ntpsnmpd/ntpsnmpd-opts.c@1.422 +7 -7 + NTP_4_2_7P415 + + ntpsnmpd/ntpsnmpd-opts.h@1.422 +3 -3 + NTP_4_2_7P415 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.236 +7 -7 + NTP_4_2_7P415 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.236 +2 -2 + NTP_4_2_7P415 + + ntpsnmpd/ntpsnmpd.html@1.78 +1 -1 + NTP_4_2_7P415 + + ntpsnmpd/ntpsnmpd.man.in@1.236 +7 -7 + NTP_4_2_7P415 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.236 +2 -2 + NTP_4_2_7P415 + + packageinfo.sh@1.419 +1 -1 + NTP_4_2_7P415 + + scripts/invoke-plot_summary.texi@1.16 +1 -1 + NTP_4_2_7P415 + + scripts/invoke-summary.texi@1.16 +1 -1 + NTP_4_2_7P415 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.225 +1 -1 + NTP_4_2_7P415 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.226 +6 -6 + NTP_4_2_7P415 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.226 +1 -1 + NTP_4_2_7P415 + + scripts/ntp-wait/ntp-wait.html@1.242 +1 -1 + NTP_4_2_7P415 + + scripts/ntp-wait/ntp-wait.man.in@1.226 +6 -6 + NTP_4_2_7P415 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.226 +1 -1 + NTP_4_2_7P415 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.14 +1 -1 + NTP_4_2_7P415 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.5 +6 -6 + NTP_4_2_7P415 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.5 +1 -1 + NTP_4_2_7P415 + + scripts/ntpsweep/ntpsweep.html@1.15 +1 -1 + NTP_4_2_7P415 + + scripts/ntpsweep/ntpsweep.man.in@1.5 +6 -6 + NTP_4_2_7P415 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.6 +1 -1 + NTP_4_2_7P415 + + scripts/ntptrace/invoke-ntptrace.texi@1.14 +1 -1 + NTP_4_2_7P415 + + scripts/ntptrace/ntptrace.1ntptraceman@1.5 +6 -6 + NTP_4_2_7P415 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.5 +1 -1 + NTP_4_2_7P415 + + scripts/ntptrace/ntptrace.html@1.15 +1 -1 + NTP_4_2_7P415 + + scripts/ntptrace/ntptrace.man.in@1.5 +6 -6 + NTP_4_2_7P415 + + scripts/ntptrace/ntptrace.mdoc.in@1.6 +1 -1 + NTP_4_2_7P415 + + scripts/plot_summary.1plot_summaryman@1.16 +6 -6 + NTP_4_2_7P415 + + scripts/plot_summary.1plot_summarymdoc@1.16 +1 -1 + NTP_4_2_7P415 + + scripts/plot_summary.html@1.16 +1 -1 + NTP_4_2_7P415 + + scripts/plot_summary.man.in@1.16 +6 -6 + NTP_4_2_7P415 + + scripts/plot_summary.mdoc.in@1.16 +1 -1 + NTP_4_2_7P415 + + scripts/summary.1summaryman@1.16 +6 -6 + NTP_4_2_7P415 + + scripts/summary.1summarymdoc@1.16 +1 -1 + NTP_4_2_7P415 + + scripts/summary.html@1.16 +1 -1 + NTP_4_2_7P415 + + scripts/summary.man.in@1.16 +6 -6 + NTP_4_2_7P415 + + scripts/summary.mdoc.in@1.16 +1 -1 + NTP_4_2_7P415 + + sntp/invoke-sntp.texi@1.404 +2 -2 + NTP_4_2_7P415 + + sntp/sntp-opts.c@1.419 +7 -7 + NTP_4_2_7P415 + + sntp/sntp-opts.h@1.419 +3 -3 + NTP_4_2_7P415 + + sntp/sntp.1sntpman@1.239 +7 -7 + NTP_4_2_7P415 + + sntp/sntp.1sntpmdoc@1.239 +2 -2 + NTP_4_2_7P415 + + sntp/sntp.html@1.419 +2 -2 + NTP_4_2_7P415 + + sntp/sntp.man.in@1.239 +7 -7 + NTP_4_2_7P415 + + sntp/sntp.mdoc.in@1.239 +2 -2 + NTP_4_2_7P415 + + util/invoke-ntp-keygen.texi@1.408 +2 -2 + NTP_4_2_7P415 + + util/ntp-keygen-opts.c@1.422 +7 -7 + NTP_4_2_7P415 + + util/ntp-keygen-opts.h@1.422 +3 -3 + NTP_4_2_7P415 + + util/ntp-keygen.1ntp-keygenman@1.236 +7 -7 + NTP_4_2_7P415 + + util/ntp-keygen.1ntp-keygenmdoc@1.236 +2 -2 + NTP_4_2_7P415 + + util/ntp-keygen.html@1.84 +27 -20 + NTP_4_2_7P415 + + util/ntp-keygen.man.in@1.236 +7 -7 + NTP_4_2_7P415 + + util/ntp-keygen.mdoc.in@1.236 +2 -2 + NTP_4_2_7P415 + +ChangeSet@1.3074, 2014-01-28 03:51:39-08:00, harlan@hms-mbp11.local + Fix the man page installation for the scripts/ files + + ChangeLog@1.1405 +1 -0 + Fix the man page installation for the scripts/ files + + scripts/calc_tickadj/Makefile.am@1.7 +2 -0 + Fix the man page installation for the scripts/ files + + scripts/ntp-wait/Makefile.am@1.6 +2 -0 + Fix the man page installation for the scripts/ files + + scripts/ntpsweep/Makefile.am@1.7 +2 -0 + Fix the man page installation for the scripts/ files + + scripts/ntptrace/Makefile.am@1.7 +2 -0 + Fix the man page installation for the scripts/ files + + sntp/loc/README@1.3 +7 -0 + Fix the man page installation for the scripts/ files + +ChangeSet@1.3073, 2014-01-28 11:26:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P414 + TAG: NTP_4_2_7P414 + + ChangeLog@1.1404 +1 -0 + NTP_4_2_7P414 + + ntpd/invoke-ntp.conf.texi@1.92 +2 -2 + NTP_4_2_7P414 + + ntpd/invoke-ntp.keys.texi@1.90 +1 -1 + NTP_4_2_7P414 + + ntpd/invoke-ntpd.texi@1.406 +2 -2 + NTP_4_2_7P414 + + ntpd/ntp.conf.5man@1.126 +8 -8 + NTP_4_2_7P414 + + ntpd/ntp.conf.5mdoc@1.126 +4 -4 + NTP_4_2_7P414 + + ntpd/ntp.conf.html@1.87 +1 -1 + NTP_4_2_7P414 + + ntpd/ntp.conf.man.in@1.126 +8 -8 + NTP_4_2_7P414 + + ntpd/ntp.conf.mdoc.in@1.126 +4 -4 + NTP_4_2_7P414 + + ntpd/ntp.keys.5man@1.124 +3 -3 + NTP_4_2_7P414 + + ntpd/ntp.keys.5mdoc@1.124 +3 -3 + NTP_4_2_7P414 + + ntpd/ntp.keys.html@1.88 +1 -1 + NTP_4_2_7P414 + + ntpd/ntp.keys.man.in@1.124 +3 -3 + NTP_4_2_7P414 + + ntpd/ntp.keys.mdoc.in@1.124 +3 -3 + NTP_4_2_7P414 + + ntpd/ntpd-opts.c@1.424 +7 -7 + NTP_4_2_7P414 + + ntpd/ntpd-opts.h@1.424 +3 -3 + NTP_4_2_7P414 + + ntpd/ntpd.1ntpdman@1.235 +7 -7 + NTP_4_2_7P414 + + ntpd/ntpd.1ntpdmdoc@1.235 +3 -3 + NTP_4_2_7P414 + + ntpd/ntpd.html@1.82 +2 -2 + NTP_4_2_7P414 + + ntpd/ntpd.man.in@1.235 +7 -7 + NTP_4_2_7P414 + + ntpd/ntpd.mdoc.in@1.235 +3 -3 + NTP_4_2_7P414 + + ntpdc/invoke-ntpdc.texi@1.403 +2 -2 + NTP_4_2_7P414 + + ntpdc/ntpdc-opts.c@1.418 +7 -7 + NTP_4_2_7P414 + + ntpdc/ntpdc-opts.h@1.418 +3 -3 + NTP_4_2_7P414 + + ntpdc/ntpdc.1ntpdcman@1.234 +7 -7 + NTP_4_2_7P414 + + ntpdc/ntpdc.1ntpdcmdoc@1.234 +3 -3 + NTP_4_2_7P414 + + ntpdc/ntpdc.html@1.247 +2 -2 + NTP_4_2_7P414 + + ntpdc/ntpdc.man.in@1.234 +7 -7 + NTP_4_2_7P414 + + ntpdc/ntpdc.mdoc.in@1.234 +3 -3 + NTP_4_2_7P414 + + ntpq/invoke-ntpq.texi@1.407 +2 -2 + NTP_4_2_7P414 + + ntpq/ntpq-opts.c@1.421 +7 -7 + NTP_4_2_7P414 + + ntpq/ntpq-opts.h@1.421 +3 -3 + NTP_4_2_7P414 + + ntpq/ntpq.1ntpqman@1.235 +6 -6 + NTP_4_2_7P414 + + ntpq/ntpq.1ntpqmdoc@1.235 +2 -2 + NTP_4_2_7P414 + + ntpq/ntpq.html@1.79 +2 -2 + NTP_4_2_7P414 + + ntpq/ntpq.man.in@1.235 +6 -6 + NTP_4_2_7P414 + + ntpq/ntpq.mdoc.in@1.235 +2 -2 + NTP_4_2_7P414 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.406 +2 -2 + NTP_4_2_7P414 + + ntpsnmpd/ntpsnmpd-opts.c@1.421 +7 -7 + NTP_4_2_7P414 + + ntpsnmpd/ntpsnmpd-opts.h@1.421 +3 -3 + NTP_4_2_7P414 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.235 +14 -14 + NTP_4_2_7P414 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.235 +3 -3 + NTP_4_2_7P414 + + ntpsnmpd/ntpsnmpd.html@1.77 +1 -1 + NTP_4_2_7P414 + + ntpsnmpd/ntpsnmpd.man.in@1.235 +14 -14 + NTP_4_2_7P414 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.235 +3 -3 + NTP_4_2_7P414 + + packageinfo.sh@1.418 +1 -1 + NTP_4_2_7P414 + + scripts/invoke-plot_summary.texi@1.15 +1 -1 + NTP_4_2_7P414 + + scripts/invoke-summary.texi@1.15 +1 -1 + NTP_4_2_7P414 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.224 +1 -1 + NTP_4_2_7P414 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.225 +6 -6 + NTP_4_2_7P414 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.225 +2 -2 + NTP_4_2_7P414 + + scripts/ntp-wait/ntp-wait.html@1.241 +1 -1 + NTP_4_2_7P414 + + scripts/ntp-wait/ntp-wait.man.in@1.225 +6 -6 + NTP_4_2_7P414 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.225 +2 -2 + NTP_4_2_7P414 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.13 +1 -1 + NTP_4_2_7P414 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.4 +6 -6 + NTP_4_2_7P414 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.4 +2 -2 + NTP_4_2_7P414 + + scripts/ntpsweep/ntpsweep.html@1.14 +1 -1 + NTP_4_2_7P414 + + scripts/ntpsweep/ntpsweep.man.in@1.4 +6 -6 + NTP_4_2_7P414 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.5 +2 -2 + NTP_4_2_7P414 + + scripts/ntptrace/invoke-ntptrace.texi@1.13 +1 -1 + NTP_4_2_7P414 + + scripts/ntptrace/ntptrace.1ntptraceman@1.4 +6 -6 + NTP_4_2_7P414 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.4 +2 -2 + NTP_4_2_7P414 + + scripts/ntptrace/ntptrace.html@1.14 +1 -1 + NTP_4_2_7P414 + + scripts/ntptrace/ntptrace.man.in@1.4 +6 -6 + NTP_4_2_7P414 + + scripts/ntptrace/ntptrace.mdoc.in@1.5 +2 -2 + NTP_4_2_7P414 + + scripts/plot_summary.1plot_summaryman@1.15 +6 -6 + NTP_4_2_7P414 + + scripts/plot_summary.1plot_summarymdoc@1.15 +2 -2 + NTP_4_2_7P414 + + scripts/plot_summary.html@1.15 +1 -1 + NTP_4_2_7P414 + + scripts/plot_summary.man.in@1.15 +6 -6 + NTP_4_2_7P414 + + scripts/plot_summary.mdoc.in@1.15 +2 -2 + NTP_4_2_7P414 + + scripts/summary.1summaryman@1.15 +6 -6 + NTP_4_2_7P414 + + scripts/summary.1summarymdoc@1.15 +2 -2 + NTP_4_2_7P414 + + scripts/summary.html@1.15 +1 -1 + NTP_4_2_7P414 + + scripts/summary.man.in@1.15 +6 -6 + NTP_4_2_7P414 + + scripts/summary.mdoc.in@1.15 +2 -2 + NTP_4_2_7P414 + + sntp/invoke-sntp.texi@1.403 +2 -2 + NTP_4_2_7P414 + + sntp/sntp-opts.c@1.418 +7 -7 + NTP_4_2_7P414 + + sntp/sntp-opts.h@1.418 +3 -3 + NTP_4_2_7P414 + + sntp/sntp.1sntpman@1.238 +7 -7 + NTP_4_2_7P414 + + sntp/sntp.1sntpmdoc@1.238 +3 -3 + NTP_4_2_7P414 + + sntp/sntp.html@1.418 +2 -2 + NTP_4_2_7P414 + + sntp/sntp.man.in@1.238 +7 -7 + NTP_4_2_7P414 + + sntp/sntp.mdoc.in@1.238 +3 -3 + NTP_4_2_7P414 + + util/invoke-ntp-keygen.texi@1.407 +24 -17 + NTP_4_2_7P414 + + util/ntp-keygen-opts.c@1.421 +122 -122 + NTP_4_2_7P414 + + util/ntp-keygen-opts.h@1.421 +16 -16 + NTP_4_2_7P414 + + util/ntp-keygen.1ntp-keygenman@1.235 +23 -16 + NTP_4_2_7P414 + + util/ntp-keygen.1ntp-keygenmdoc@1.235 +18 -11 + NTP_4_2_7P414 + + util/ntp-keygen.html@1.83 +2 -2 + NTP_4_2_7P414 + + util/ntp-keygen.man.in@1.235 +23 -16 + NTP_4_2_7P414 + + util/ntp-keygen.mdoc.in@1.235 +18 -11 + NTP_4_2_7P414 + +ChangeSet@1.3072, 2014-01-28 06:21:33-05:00, stenn@deacon.udel.edu + [Bug 1002] ntp-keygen option and documentation updates + + util/ntp-keygen.c@1.97 +4 -4 + [Bug 1002] ntp-keygen option and documentation updates + +ChangeSet@1.3071, 2014-01-28 04:40:20-05:00, stenn@deacon.udel.edu + [Bug 2493] ntptrace needs a man page (fixed in 4.2.7p402) + + ChangeLog@1.1403 +1 -0 + [Bug 2493] ntptrace needs a man page (fixed in 4.2.7p402) + +ChangeSet@1.3070, 2014-01-28 09:33:40+00:00, stenn@psp-fb1.ntp.org + [Bug 2366] ntpdc.html: burst/iburst only work on servers + + ChangeLog@1.1402 +1 -0 + [Bug 2366] ntpdc.html: burst/iburst only work on servers + + html/confopt.html@1.58 +1 -1 + fix a typo + + html/ntpdc.html@1.37 +3 -3 + [Bug 2366] ntpdc.html: burst/iburst only work on servers + +ChangeSet@1.3069, 2014-01-28 08:45:42+00:00, stenn@psp-fb1.ntp.org + [Bug 2049] Clarify ntpdate's -d option behavior + + ChangeLog@1.1401 +1 -0 + [Bug 2049] Clarify ntpdate's -d option behavior + + html/ntpdate.html@1.25 +1 -1 + [Bug 2049] Clarify ntpdate's -d option behavior + +ChangeSet@1.3068, 2014-01-28 03:35:19-05:00, stenn@deacon.udel.edu + [Bug 1734] Include man page for ntp.conf (fixed in 4.2.7p297) + + ChangeLog@1.1400 +1 -0 + [Bug 1734] Include man page for ntp.conf (fixed in 4.2.7p297) + +ChangeSet@1.3067, 2014-01-28 08:28:29+00:00, stenn@psp-fb1.ntp.org + [Bug 1349] statistics command not documented in HTML documentation + + ChangeLog@1.1399 +7 -0 + [Bug 1349] statistics command not documented in HTML documentation + + html/comdex.html@1.5 +2 -2 + [Bug 1349] statistics command not documented in HTML documentation + + html/monopt.html@1.36 +5 -1 + [Bug 1349] statistics command not documented in HTML documentation + + html/scripts/monopt.txt@1.4 +1 -0 + [Bug 1349] statistics command not documented in HTML documentation + + ntpd/complete.conf.in@1.26 +1 -1 + [Bug 1349] statistics command not documented in HTML documentation + + ntpd/ntp.conf.def@1.11 +1 -1 + [Bug 1349] statistics command not documented in HTML documentation + +ChangeSet@1.3066, 2014-01-28 08:14:17+00:00, stenn@psp-fb1.ntp.org + [Bug 1002] ntp-keygen option and documentation updates + + ChangeLog@1.1398 +2 -0 + [Bug 1002] ntp-keygen option and documentation updates + + util/ntp-keygen-opts.def@1.25 +14 -7 + [Bug 1002] ntp-keygen option and documentation updates + +ChangeSet@1.3065, 2014-01-28 07:35:00+00:00, stenn@psp-fb1.ntp.org + [Bug 930] ntpdc docs refer to 'clockinfo', but mean 'clockstat' + + ChangeLog@1.1397 +1 -0 + [Bug 930] ntpdc docs refer to 'clockinfo', but mean 'clockstat' + + html/ntpdc.html@1.36 +1 -1 + [Bug 930] ntpdc docs refer to 'clockinfo', but mean 'clockstat' + + ntpdc/ntpdc-opts.def@1.21 +1 -1 + [Bug 930] ntpdc docs refer to 'clockinfo', but mean 'clockstat' + +ChangeSet@1.3064, 2014-01-28 07:07:13+00:00, stenn@psp-fb1.ntp.org + [Bug 898] Documentation fixes + + ChangeLog@1.1396 +1 -0 + [Bug 898] Documentation fixes + + html/ntpd.html@1.58 +5 -1 + [Bug 898] Documentation fixes + + html/ntpdate.html@1.24 +5 -5 + [Bug 898] Documentation fixes + + html/ntpdc.html@1.35 +4 -2 + [Bug 898] Documentation fixes + + html/ntpq.html@1.48 +1 -1 + [Bug 898] Documentation fixes + + html/ntptrace.html@1.19 +1 -1 + [Bug 898] Documentation fixes + +ChangeSet@1.3063, 2014-01-28 00:00:50-05:00, stenn@deacon.udel.edu + [Bug 2545] Cleanup of scripts/monitoring/ntptrap + + ChangeLog@1.1395 +1 -0 + [Bug 2545] Cleanup of scripts/monitoring/ntptrap + + scripts/monitoring/ntp.pl@1.4 +54 -27 + [Bug 2545] Cleanup of scripts/monitoring/ntptrap + + scripts/monitoring/ntptrap@1.3 +6 -4 + [Bug 2545] Cleanup of scripts/monitoring/ntptrap + +ChangeSet@1.3062, 2014-01-27 21:32:42-05:00, stenn@deacon.udel.edu + [Bug 792] TrueTime TL-3 WWV refclock support + + ChangeLog@1.1394 +1 -0 + [Bug 792] TrueTime TL-3 WWV refclock support + + html/drivers/driver5.html@1.15 +17 -6 + [Bug 792] TrueTime TL-3 WWV refclock support + + ntpd/refclock_true.c@1.20 +121 -30 + [Bug 792] TrueTime TL-3 WWV refclock support + +ChangeSet@1.3061, 2014-01-28 00:35:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P413 + TAG: NTP_4_2_7P413 + + ChangeLog@1.1393 +1 -0 + NTP_4_2_7P413 + + ntpd/invoke-ntp.conf.texi@1.91 +1 -1 + NTP_4_2_7P413 + + ntpd/invoke-ntp.keys.texi@1.89 +1 -1 + NTP_4_2_7P413 + + ntpd/invoke-ntpd.texi@1.405 +2 -2 + NTP_4_2_7P413 + + ntpd/ntp.conf.5man@1.125 +7 -7 + NTP_4_2_7P413 + + ntpd/ntp.conf.5mdoc@1.125 +3 -3 + NTP_4_2_7P413 + + ntpd/ntp.conf.html@1.86 +1 -1 + NTP_4_2_7P413 + + ntpd/ntp.conf.man.in@1.125 +7 -7 + NTP_4_2_7P413 + + ntpd/ntp.conf.mdoc.in@1.125 +3 -3 + NTP_4_2_7P413 + + ntpd/ntp.keys.5man@1.123 +3 -3 + NTP_4_2_7P413 + + ntpd/ntp.keys.5mdoc@1.123 +3 -3 + NTP_4_2_7P413 + + ntpd/ntp.keys.html@1.87 +1 -1 + NTP_4_2_7P413 + + ntpd/ntp.keys.man.in@1.123 +3 -3 + NTP_4_2_7P413 + + ntpd/ntp.keys.mdoc.in@1.123 +3 -3 + NTP_4_2_7P413 + + ntpd/ntpd-opts.c@1.423 +7 -7 + NTP_4_2_7P413 + + ntpd/ntpd-opts.h@1.423 +3 -3 + NTP_4_2_7P413 + + ntpd/ntpd.1ntpdman@1.234 +7 -7 + NTP_4_2_7P413 + + ntpd/ntpd.1ntpdmdoc@1.234 +3 -3 + NTP_4_2_7P413 + + ntpd/ntpd.html@1.81 +2 -2 + NTP_4_2_7P413 + + ntpd/ntpd.man.in@1.234 +7 -7 + NTP_4_2_7P413 + + ntpd/ntpd.mdoc.in@1.234 +3 -3 + NTP_4_2_7P413 + + ntpdc/invoke-ntpdc.texi@1.402 +2 -2 + NTP_4_2_7P413 + + ntpdc/ntpdc-opts.c@1.417 +7 -7 + NTP_4_2_7P413 + + ntpdc/ntpdc-opts.h@1.417 +3 -3 + NTP_4_2_7P413 + + ntpdc/ntpdc.1ntpdcman@1.233 +6 -6 + NTP_4_2_7P413 + + ntpdc/ntpdc.1ntpdcmdoc@1.233 +2 -2 + NTP_4_2_7P413 + + ntpdc/ntpdc.html@1.246 +2 -2 + NTP_4_2_7P413 + + ntpdc/ntpdc.man.in@1.233 +6 -6 + NTP_4_2_7P413 + + ntpdc/ntpdc.mdoc.in@1.233 +2 -2 + NTP_4_2_7P413 + + ntpq/invoke-ntpq.texi@1.406 +2 -2 + NTP_4_2_7P413 + + ntpq/ntpq-opts.c@1.420 +7 -7 + NTP_4_2_7P413 + + ntpq/ntpq-opts.h@1.420 +3 -3 + NTP_4_2_7P413 + + ntpq/ntpq.1ntpqman@1.234 +6 -6 + NTP_4_2_7P413 + + ntpq/ntpq.1ntpqmdoc@1.234 +2 -2 + NTP_4_2_7P413 + + ntpq/ntpq.html@1.78 +2 -2 + NTP_4_2_7P413 + + ntpq/ntpq.man.in@1.234 +6 -6 + NTP_4_2_7P413 + + ntpq/ntpq.mdoc.in@1.234 +2 -2 + NTP_4_2_7P413 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.405 +2 -2 + NTP_4_2_7P413 + + ntpsnmpd/ntpsnmpd-opts.c@1.420 +7 -7 + NTP_4_2_7P413 + + ntpsnmpd/ntpsnmpd-opts.h@1.420 +3 -3 + NTP_4_2_7P413 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.234 +7 -7 + NTP_4_2_7P413 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.234 +3 -3 + NTP_4_2_7P413 + + ntpsnmpd/ntpsnmpd.html@1.76 +1 -1 + NTP_4_2_7P413 + + ntpsnmpd/ntpsnmpd.man.in@1.234 +7 -7 + NTP_4_2_7P413 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.234 +3 -3 + NTP_4_2_7P413 + + packageinfo.sh@1.417 +1 -1 + NTP_4_2_7P413 + + scripts/invoke-plot_summary.texi@1.14 +1 -1 + NTP_4_2_7P413 + + scripts/invoke-summary.texi@1.14 +1 -1 + NTP_4_2_7P413 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.223 +2 -2 + NTP_4_2_7P413 + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.224 +32 -3 + NTP_4_2_7P413 + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.224 +21 -2 + NTP_4_2_7P413 + + scripts/ntp-wait/ntp-wait.html@1.240 +2 -2 + NTP_4_2_7P413 + + scripts/ntp-wait/ntp-wait.man.in@1.224 +32 -3 + NTP_4_2_7P413 + + scripts/ntp-wait/ntp-wait.mdoc.in@1.224 +21 -2 + NTP_4_2_7P413 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.12 +2 -2 + NTP_4_2_7P413 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.3 +32 -3 + NTP_4_2_7P413 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.3 +21 -2 + NTP_4_2_7P413 + + scripts/ntpsweep/ntpsweep.html@1.13 +2 -2 + NTP_4_2_7P413 + + scripts/ntpsweep/ntpsweep.man.in@1.3 +32 -3 + NTP_4_2_7P413 + + scripts/ntpsweep/ntpsweep.mdoc.in@1.4 +21 -2 + NTP_4_2_7P413 + + scripts/ntptrace/invoke-ntptrace.texi@1.12 +2 -2 + NTP_4_2_7P413 + + scripts/ntptrace/ntptrace.1ntptraceman@1.3 +32 -3 + NTP_4_2_7P413 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.3 +21 -2 + NTP_4_2_7P413 + + scripts/ntptrace/ntptrace.html@1.13 +2 -2 + NTP_4_2_7P413 + + scripts/ntptrace/ntptrace.man.in@1.3 +32 -3 + NTP_4_2_7P413 + + scripts/ntptrace/ntptrace.mdoc.in@1.4 +21 -2 + NTP_4_2_7P413 + + scripts/plot_summary.1plot_summaryman@1.14 +33 -3 + NTP_4_2_7P413 + + scripts/plot_summary.1plot_summarymdoc@1.14 +22 -2 + NTP_4_2_7P413 + + scripts/plot_summary.html@1.14 +28 -46 + NTP_4_2_7P413 + + scripts/plot_summary.man.in@1.14 +33 -3 + NTP_4_2_7P413 + + scripts/plot_summary.mdoc.in@1.14 +22 -2 + NTP_4_2_7P413 + + scripts/summary.1summaryman@1.14 +32 -3 + NTP_4_2_7P413 + + scripts/summary.1summarymdoc@1.14 +21 -2 + NTP_4_2_7P413 + + scripts/summary.html@1.14 +26 -38 + NTP_4_2_7P413 + + scripts/summary.man.in@1.14 +32 -3 + NTP_4_2_7P413 + + scripts/summary.mdoc.in@1.14 +21 -2 + NTP_4_2_7P413 + + sntp/invoke-sntp.texi@1.402 +2 -2 + NTP_4_2_7P413 + + sntp/sntp-opts.c@1.417 +7 -7 + NTP_4_2_7P413 + + sntp/sntp-opts.h@1.417 +3 -3 + NTP_4_2_7P413 + + sntp/sntp.1sntpman@1.237 +7 -7 + NTP_4_2_7P413 + + sntp/sntp.1sntpmdoc@1.237 +3 -3 + NTP_4_2_7P413 + + sntp/sntp.html@1.417 +2 -2 + NTP_4_2_7P413 + + sntp/sntp.man.in@1.237 +7 -7 + NTP_4_2_7P413 + + sntp/sntp.mdoc.in@1.237 +3 -3 + NTP_4_2_7P413 + + util/invoke-ntp-keygen.texi@1.406 +2 -2 + NTP_4_2_7P413 + + util/ntp-keygen-opts.c@1.420 +7 -7 + NTP_4_2_7P413 + + util/ntp-keygen-opts.h@1.420 +3 -3 + NTP_4_2_7P413 + + util/ntp-keygen.1ntp-keygenman@1.234 +7 -7 + NTP_4_2_7P413 + + util/ntp-keygen.1ntp-keygenmdoc@1.234 +3 -3 + NTP_4_2_7P413 + + util/ntp-keygen.html@1.82 +2 -2 + NTP_4_2_7P413 + + util/ntp-keygen.man.in@1.234 +7 -7 + NTP_4_2_7P413 + + util/ntp-keygen.mdoc.in@1.234 +3 -3 + NTP_4_2_7P413 + +ChangeSet@1.3060, 2014-01-27 19:35:20-05:00, stenn@deacon.udel.edu + update .point-changed-filelist + + .point-changed-filelist@1.23 +12 -0 + update .point-changed-filelist + +ChangeSet@1.3059, 2014-01-27 19:31:58-05:00, stenn@deacon.udel.edu + Add missing std_def_list + + scripts/ntp-wait/Makefile.am@1.5 +8 -0 + Add missing std_def_list + + scripts/ntpsweep/Makefile.am@1.6 +8 -0 + Add missing std_def_list + + scripts/ntptrace/Makefile.am@1.6 +8 -0 + Add missing std_def_list + +ChangeSet@1.3058, 2014-01-27 09:55:09+00:00, stenn@psp-fb1.ntp.org + Require a version string for perl scripts that use autogen + + scripts/calc_tickadj/calc_tickadj-opts@1.2 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/calc_tickadj/calc_tickadj-opts.def@1.2 +7 -2 + Require a version string for perl scripts that use autogen + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.2 +7 -2 + Require a version string for perl scripts that use autogen + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.2 +6 -2 + Require a version string for perl scripts that use autogen + + scripts/calc_tickadj/calc_tickadj.html@1.2 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.2 +6 -2 + Require a version string for perl scripts that use autogen + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.4 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/invoke-plot_summary.texi@1.13 +2 -2 + Require a version string for perl scripts that use autogen + + scripts/invoke-summary.texi@1.13 +2 -2 + Require a version string for perl scripts that use autogen + + scripts/ntp-wait/ntp-wait-opts@1.2 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/ntp-wait/ntp-wait-opts.def@1.10 +6 -4 + Require a version string for perl scripts that use autogen + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.223 +71 -72 + Require a version string for perl scripts that use autogen + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.223 +27 -53 + Require a version string for perl scripts that use autogen + + scripts/ntp-wait/ntp-wait.man.in@1.223 +71 -72 + Require a version string for perl scripts that use autogen + + scripts/ntp-wait/ntp-wait.mdoc.in@1.223 +27 -53 + Require a version string for perl scripts that use autogen + + scripts/ntpsweep/ntpsweep-opts@1.2 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/ntpsweep/ntpsweep-opts.def@1.2 +3 -0 + Require a version string for perl scripts that use autogen + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.2 +7 -2 + Require a version string for perl scripts that use autogen + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.2 +6 -2 + Require a version string for perl scripts that use autogen + + scripts/ntpsweep/ntpsweep.man.in@1.2 +7 -2 + Require a version string for perl scripts that use autogen + + scripts/ntpsweep/ntpsweep.mdoc.in@1.3 +6 -2 + Require a version string for perl scripts that use autogen + + scripts/ntptrace/ntptrace-opts@1.2 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/ntptrace/ntptrace-opts.def@1.2 +7 -4 + Require a version string for perl scripts that use autogen + + scripts/ntptrace/ntptrace.1ntptraceman@1.2 +7 -2 + Require a version string for perl scripts that use autogen + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.2 +6 -2 + Require a version string for perl scripts that use autogen + + scripts/ntptrace/ntptrace.man.in@1.2 +7 -2 + Require a version string for perl scripts that use autogen + + scripts/ntptrace/ntptrace.mdoc.in@1.3 +6 -2 + Require a version string for perl scripts that use autogen + + scripts/plot_summary-opts@1.2 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/plot_summary-opts.def@1.2 +6 -1 + Require a version string for perl scripts that use autogen + + scripts/plot_summary.1plot_summaryman@1.13 +8 -33 + Require a version string for perl scripts that use autogen + + scripts/plot_summary.1plot_summarymdoc@1.13 +7 -23 + Require a version string for perl scripts that use autogen + + scripts/plot_summary.html@1.13 +46 -28 + Require a version string for perl scripts that use autogen + + scripts/plot_summary.man.in@1.13 +8 -33 + Require a version string for perl scripts that use autogen + + scripts/plot_summary.mdoc.in@1.13 +7 -23 + Require a version string for perl scripts that use autogen + + scripts/summary-opts@1.2 +1 -1 + Require a version string for perl scripts that use autogen + + scripts/summary-opts.def@1.2 +6 -1 + Require a version string for perl scripts that use autogen + + scripts/summary.1summaryman@1.13 +8 -32 + Require a version string for perl scripts that use autogen + + scripts/summary.1summarymdoc@1.13 +7 -22 + Require a version string for perl scripts that use autogen + + scripts/summary.html@1.13 +38 -26 + Require a version string for perl scripts that use autogen + + scripts/summary.man.in@1.13 +8 -32 + Require a version string for perl scripts that use autogen + + scripts/summary.mdoc.in@1.13 +7 -22 + Require a version string for perl scripts that use autogen + +ChangeSet@1.3057, 2014-01-27 09:46:42+00:00, stenn@psp-fb1.ntp.org + Require a version string for perl scripts that use autogen + + ChangeLog@1.1392 +2 -1 + Require a version string for perl scripts that use autogen + + sntp/ag-tpl/perlopt.tpl@1.2 +3 -2 + Require a version string for perl scripts that use autogen + +ChangeSet@1.3056, 2014-01-27 09:42:49+00:00, stenn@psp-fb1.ntp.org + html/ cleanup + + ChangeLog@1.1391 +1 -0 + html/ cleanup + + html/assoc.html@1.39 +1 -1 + html/ cleanup + + html/drivers/driver8.html@1.30 +1 -1 + html/ cleanup + + html/hints/solaris.html@1.11 +90 -1 + html/ cleanup + + html/pic/stats.gif@1.1, stenn@stenn.ntp.org +272 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/html/pic/stats.gif + + html/pic/stats.gif@1.0, stenn@stenn.ntp.org +0 -0 + + html/pic/time1.gif@1.1, stenn@stenn.ntp.org +102 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/html/pic/time1.gif + + html/pic/time1.gif@1.0, stenn@stenn.ntp.org +0 -0 + + html/refclock.html@1.39 +1 -1 + html/ cleanup + +ChangeSet@1.3055, 2014-01-27 09:13:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P412 + TAG: NTP_4_2_7P412 + + ChangeLog@1.1390 +1 -0 + NTP_4_2_7P412 + + ntpd/invoke-ntp.conf.texi@1.90 +1 -1 + NTP_4_2_7P412 + + ntpd/invoke-ntp.keys.texi@1.88 +1 -1 + NTP_4_2_7P412 + + ntpd/invoke-ntpd.texi@1.404 +2 -2 + NTP_4_2_7P412 + + ntpd/ntp.conf.5man@1.124 +7 -7 + NTP_4_2_7P412 + + ntpd/ntp.conf.5mdoc@1.124 +3 -3 + NTP_4_2_7P412 + + ntpd/ntp.conf.html@1.85 +1 -1 + NTP_4_2_7P412 + + ntpd/ntp.conf.man.in@1.124 +7 -7 + NTP_4_2_7P412 + + ntpd/ntp.conf.mdoc.in@1.124 +3 -3 + NTP_4_2_7P412 + + ntpd/ntp.keys.5man@1.122 +3 -3 + NTP_4_2_7P412 + + ntpd/ntp.keys.5mdoc@1.122 +3 -3 + NTP_4_2_7P412 + + ntpd/ntp.keys.html@1.86 +1 -1 + NTP_4_2_7P412 + + ntpd/ntp.keys.man.in@1.122 +3 -3 + NTP_4_2_7P412 + + ntpd/ntp.keys.mdoc.in@1.122 +3 -3 + NTP_4_2_7P412 + + ntpd/ntpd-opts.c@1.422 +7 -7 + NTP_4_2_7P412 + + ntpd/ntpd-opts.h@1.422 +3 -3 + NTP_4_2_7P412 + + ntpd/ntpd.1ntpdman@1.233 +7 -7 + NTP_4_2_7P412 + + ntpd/ntpd.1ntpdmdoc@1.233 +3 -3 + NTP_4_2_7P412 + + ntpd/ntpd.html@1.80 +2 -2 + NTP_4_2_7P412 + + ntpd/ntpd.man.in@1.233 +7 -7 + NTP_4_2_7P412 + + ntpd/ntpd.mdoc.in@1.233 +3 -3 + NTP_4_2_7P412 + + ntpdc/invoke-ntpdc.texi@1.401 +2 -2 + NTP_4_2_7P412 + + ntpdc/ntpdc-opts.c@1.416 +7 -7 + NTP_4_2_7P412 + + ntpdc/ntpdc-opts.h@1.416 +3 -3 + NTP_4_2_7P412 + + ntpdc/ntpdc.1ntpdcman@1.232 +893 -0 + NTP_4_2_7P412 + + ntpdc/ntpdc.1ntpdcmdoc@1.232 +2 -2 + NTP_4_2_7P412 + + ntpdc/ntpdc.html@1.245 +2 -2 + NTP_4_2_7P412 + + ntpdc/ntpdc.man.in@1.232 +893 -0 + NTP_4_2_7P412 + + ntpdc/ntpdc.mdoc.in@1.232 +2 -2 + NTP_4_2_7P412 + + ntpq/invoke-ntpq.texi@1.405 +2 -2 + NTP_4_2_7P412 + + ntpq/ntpq-opts.c@1.419 +7 -7 + NTP_4_2_7P412 + + ntpq/ntpq-opts.h@1.419 +3 -3 + NTP_4_2_7P412 + + ntpq/ntpq.1ntpqman@1.233 +6 -6 + NTP_4_2_7P412 + + ntpq/ntpq.1ntpqmdoc@1.233 +2 -2 + NTP_4_2_7P412 + + ntpq/ntpq.html@1.77 +2 -2 + NTP_4_2_7P412 + + ntpq/ntpq.man.in@1.233 +6 -6 + NTP_4_2_7P412 + + ntpq/ntpq.mdoc.in@1.233 +2 -2 + NTP_4_2_7P412 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.404 +2 -2 + NTP_4_2_7P412 + + ntpsnmpd/ntpsnmpd-opts.c@1.419 +7 -7 + NTP_4_2_7P412 + + ntpsnmpd/ntpsnmpd-opts.h@1.419 +3 -3 + NTP_4_2_7P412 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.233 +7 -7 + NTP_4_2_7P412 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.233 +3 -3 + NTP_4_2_7P412 + + ntpsnmpd/ntpsnmpd.html@1.75 +1 -1 + NTP_4_2_7P412 + + ntpsnmpd/ntpsnmpd.man.in@1.233 +7 -7 + NTP_4_2_7P412 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.233 +3 -3 + NTP_4_2_7P412 + + packageinfo.sh@1.416 +1 -1 + NTP_4_2_7P412 + + scripts/invoke-plot_summary.texi@1.12 +1 -1 + NTP_4_2_7P412 + + scripts/invoke-summary.texi@1.12 +1 -1 + NTP_4_2_7P412 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.222 +1 -1 + NTP_4_2_7P412 + + scripts/ntp-wait/ntp-wait.html@1.239 +1 -1 + NTP_4_2_7P412 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.11 +1 -1 + NTP_4_2_7P412 + + scripts/ntpsweep/ntpsweep.html@1.12 +1 -1 + NTP_4_2_7P412 + + scripts/ntptrace/invoke-ntptrace.texi@1.11 +1 -1 + NTP_4_2_7P412 + + scripts/ntptrace/ntptrace.html@1.12 +1 -1 + NTP_4_2_7P412 + + scripts/plot_summary.1plot_summaryman@1.12 +6 -6 + NTP_4_2_7P412 + + scripts/plot_summary.1plot_summarymdoc@1.12 +2 -2 + NTP_4_2_7P412 + + scripts/plot_summary.html@1.12 +1 -1 + NTP_4_2_7P412 + + scripts/plot_summary.man.in@1.12 +6 -6 + NTP_4_2_7P412 + + scripts/plot_summary.mdoc.in@1.12 +2 -2 + NTP_4_2_7P412 + + scripts/summary.1summaryman@1.12 +6 -6 + NTP_4_2_7P412 + + scripts/summary.1summarymdoc@1.12 +2 -2 + NTP_4_2_7P412 + + scripts/summary.html@1.12 +1 -1 + NTP_4_2_7P412 + + scripts/summary.man.in@1.12 +6 -6 + NTP_4_2_7P412 + + scripts/summary.mdoc.in@1.12 +2 -2 + NTP_4_2_7P412 + + sntp/invoke-sntp.texi@1.401 +2 -2 + NTP_4_2_7P412 + + sntp/sntp-opts.c@1.416 +7 -7 + NTP_4_2_7P412 + + sntp/sntp-opts.h@1.416 +3 -3 + NTP_4_2_7P412 + + sntp/sntp.1sntpman@1.236 +372 -0 + NTP_4_2_7P412 + + sntp/sntp.1sntpmdoc@1.236 +3 -3 + NTP_4_2_7P412 + + sntp/sntp.html@1.416 +2 -2 + NTP_4_2_7P412 + + sntp/sntp.man.in@1.236 +372 -0 + NTP_4_2_7P412 + + sntp/sntp.mdoc.in@1.236 +3 -3 + NTP_4_2_7P412 + + util/invoke-ntp-keygen.texi@1.405 +2 -2 + NTP_4_2_7P412 + + util/ntp-keygen-opts.c@1.419 +7 -7 + NTP_4_2_7P412 + + util/ntp-keygen-opts.h@1.419 +3 -3 + NTP_4_2_7P412 + + util/ntp-keygen.1ntp-keygenman@1.233 +7 -7 + NTP_4_2_7P412 + + util/ntp-keygen.1ntp-keygenmdoc@1.233 +3 -3 + NTP_4_2_7P412 + + util/ntp-keygen.html@1.81 +2 -2 + NTP_4_2_7P412 + + util/ntp-keygen.man.in@1.233 +7 -7 + NTP_4_2_7P412 + + util/ntp-keygen.mdoc.in@1.233 +3 -3 + NTP_4_2_7P412 + +ChangeSet@1.3054, 2014-01-20 02:39:11+00:00, stenn@psp-deb1.ntp.org + [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups + + ChangeLog@1.1389 +1 -0 + [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups + + bootstrap@1.44 +26 -7 + [Bug 2540] bootstrap script needs to 'touch' files in finer-grained groups + +ChangeSet@1.3053, 2014-01-12 10:07:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P411 + TAG: NTP_4_2_7P411 + + ChangeLog@1.1388 +1 -0 + NTP_4_2_7P411 + + ntpd/invoke-ntp.conf.texi@1.89 +1 -1 + NTP_4_2_7P411 + + ntpd/invoke-ntp.keys.texi@1.87 +1 -1 + NTP_4_2_7P411 + + ntpd/invoke-ntpd.texi@1.403 +2 -2 + NTP_4_2_7P411 + + ntpd/ntp.conf.5man@1.123 +7 -7 + NTP_4_2_7P411 + + ntpd/ntp.conf.5mdoc@1.123 +3 -3 + NTP_4_2_7P411 + + ntpd/ntp.conf.html@1.84 +14 -12 + NTP_4_2_7P411 + + ntpd/ntp.conf.man.in@1.123 +7 -7 + NTP_4_2_7P411 + + ntpd/ntp.conf.mdoc.in@1.123 +3 -3 + NTP_4_2_7P411 + + ntpd/ntp.keys.5man@1.121 +3 -3 + NTP_4_2_7P411 + + ntpd/ntp.keys.5mdoc@1.121 +3 -3 + NTP_4_2_7P411 + + ntpd/ntp.keys.html@1.85 +1 -1 + NTP_4_2_7P411 + + ntpd/ntp.keys.man.in@1.121 +3 -3 + NTP_4_2_7P411 + + ntpd/ntp.keys.mdoc.in@1.121 +3 -3 + NTP_4_2_7P411 + + ntpd/ntpd-opts.c@1.421 +7 -7 + NTP_4_2_7P411 + + ntpd/ntpd-opts.h@1.421 +3 -3 + NTP_4_2_7P411 + + ntpd/ntpd.1ntpdman@1.232 +7 -7 + NTP_4_2_7P411 + + ntpd/ntpd.1ntpdmdoc@1.232 +3 -3 + NTP_4_2_7P411 + + ntpd/ntpd.html@1.79 +2 -2 + NTP_4_2_7P411 + + ntpd/ntpd.man.in@1.232 +7 -7 + NTP_4_2_7P411 + + ntpd/ntpd.mdoc.in@1.232 +3 -3 + NTP_4_2_7P411 + + ntpdc/invoke-ntpdc.texi@1.400 +2 -2 + NTP_4_2_7P411 + + ntpdc/ntpdc-opts.c@1.415 +7 -7 + NTP_4_2_7P411 + + ntpdc/ntpdc-opts.h@1.415 +3 -3 + NTP_4_2_7P411 + + ntpdc/ntpdc.1ntpdcman@1.231 +0 -893 + NTP_4_2_7P411 + + ntpdc/ntpdc.1ntpdcmdoc@1.231 +2 -2 + NTP_4_2_7P411 + + ntpdc/ntpdc.html@1.244 +2 -2 + NTP_4_2_7P411 + + ntpdc/ntpdc.man.in@1.231 +0 -893 + NTP_4_2_7P411 + + ntpdc/ntpdc.mdoc.in@1.231 +2 -2 + NTP_4_2_7P411 + + ntpq/invoke-ntpq.texi@1.404 +2 -2 + NTP_4_2_7P411 + + ntpq/ntpq-opts.c@1.418 +7 -7 + NTP_4_2_7P411 + + ntpq/ntpq-opts.h@1.418 +3 -3 + NTP_4_2_7P411 + + ntpq/ntpq.1ntpqman@1.232 +6 -6 + NTP_4_2_7P411 + + ntpq/ntpq.1ntpqmdoc@1.232 +2 -2 + NTP_4_2_7P411 + + ntpq/ntpq.html@1.76 +2 -2 + NTP_4_2_7P411 + + ntpq/ntpq.man.in@1.232 +6 -6 + NTP_4_2_7P411 + + ntpq/ntpq.mdoc.in@1.232 +2 -2 + NTP_4_2_7P411 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.403 +2 -2 + NTP_4_2_7P411 + + ntpsnmpd/ntpsnmpd-opts.c@1.418 +7 -7 + NTP_4_2_7P411 + + ntpsnmpd/ntpsnmpd-opts.h@1.418 +3 -3 + NTP_4_2_7P411 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.232 +14 -14 + NTP_4_2_7P411 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.232 +3 -3 + NTP_4_2_7P411 + + ntpsnmpd/ntpsnmpd.html@1.74 +1 -1 + NTP_4_2_7P411 + + ntpsnmpd/ntpsnmpd.man.in@1.232 +14 -14 + NTP_4_2_7P411 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.232 +3 -3 + NTP_4_2_7P411 + + packageinfo.sh@1.415 +1 -1 + NTP_4_2_7P411 + + scripts/invoke-plot_summary.texi@1.11 +1 -1 + NTP_4_2_7P411 + + scripts/invoke-summary.texi@1.11 +1 -1 + NTP_4_2_7P411 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.221 +1 -1 + NTP_4_2_7P411 + + scripts/ntp-wait/ntp-wait.html@1.238 +1 -1 + NTP_4_2_7P411 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.10 +1 -1 + NTP_4_2_7P411 + + scripts/ntpsweep/ntpsweep.html@1.11 +1 -1 + NTP_4_2_7P411 + + scripts/ntptrace/invoke-ntptrace.texi@1.10 +1 -1 + NTP_4_2_7P411 + + scripts/ntptrace/ntptrace.html@1.11 +1 -1 + NTP_4_2_7P411 + + scripts/plot_summary.1plot_summaryman@1.11 +6 -6 + NTP_4_2_7P411 + + scripts/plot_summary.1plot_summarymdoc@1.11 +2 -2 + NTP_4_2_7P411 + + scripts/plot_summary.html@1.11 +1 -1 + NTP_4_2_7P411 + + scripts/plot_summary.man.in@1.11 +6 -6 + NTP_4_2_7P411 + + scripts/plot_summary.mdoc.in@1.11 +2 -2 + NTP_4_2_7P411 + + scripts/summary.1summaryman@1.11 +6 -6 + NTP_4_2_7P411 + + scripts/summary.1summarymdoc@1.11 +2 -2 + NTP_4_2_7P411 + + scripts/summary.html@1.11 +1 -1 + NTP_4_2_7P411 + + scripts/summary.man.in@1.11 +6 -6 + NTP_4_2_7P411 + + scripts/summary.mdoc.in@1.11 +2 -2 + NTP_4_2_7P411 + + sntp/invoke-sntp.texi@1.400 +2 -2 + NTP_4_2_7P411 + + sntp/sntp-opts.c@1.415 +7 -7 + NTP_4_2_7P411 + + sntp/sntp-opts.h@1.415 +3 -3 + NTP_4_2_7P411 + + sntp/sntp.1sntpman@1.235 +0 -372 + NTP_4_2_7P411 + + sntp/sntp.1sntpmdoc@1.235 +3 -3 + NTP_4_2_7P411 + + sntp/sntp.html@1.415 +2 -2 + NTP_4_2_7P411 + + sntp/sntp.man.in@1.235 +0 -372 + NTP_4_2_7P411 + + sntp/sntp.mdoc.in@1.235 +3 -3 + NTP_4_2_7P411 + + util/invoke-ntp-keygen.texi@1.404 +2 -2 + NTP_4_2_7P411 + + util/ntp-keygen-opts.c@1.418 +7 -7 + NTP_4_2_7P411 + + util/ntp-keygen-opts.h@1.418 +3 -3 + NTP_4_2_7P411 + + util/ntp-keygen.1ntp-keygenman@1.232 +7 -7 + NTP_4_2_7P411 + + util/ntp-keygen.1ntp-keygenmdoc@1.232 +3 -3 + NTP_4_2_7P411 + + util/ntp-keygen.html@1.80 +2 -2 + NTP_4_2_7P411 + + util/ntp-keygen.man.in@1.232 +7 -7 + NTP_4_2_7P411 + + util/ntp-keygen.mdoc.in@1.232 +3 -3 + NTP_4_2_7P411 + +ChangeSet@1.3052, 2014-01-09 05:21:23-05:00, stenn@deacon.udel.edu + [Bug 2532] Note in ntpdc docs that "enable pps" only works on older ntpd + + ChangeLog@1.1387 +1 -0 + [Bug 2532] Note in ntpdc docs that "enable pps" only works on older ntpd + + html/ntpdc.html@1.34 +1 -0 + [Bug 2532] Note in ntpdc docs that "enable pps" only works on older ntpd + +ChangeSet@1.3051, 2014-01-08 11:47:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P410 + TAG: NTP_4_2_7P410 + + ChangeLog@1.1386 +1 -0 + NTP_4_2_7P410 + + ntpd/invoke-ntp.conf.texi@1.88 +16 -14 + NTP_4_2_7P410 + + ntpd/invoke-ntp.keys.texi@1.86 +1 -1 + NTP_4_2_7P410 + + ntpd/invoke-ntpd.texi@1.402 +2 -2 + NTP_4_2_7P410 + + ntpd/ntp.conf.5man@1.122 +24 -22 + NTP_4_2_7P410 + + ntpd/ntp.conf.5mdoc@1.122 +21 -19 + NTP_4_2_7P410 + + ntpd/ntp.conf.html@1.83 +1 -1 + NTP_4_2_7P410 + + ntpd/ntp.conf.man.in@1.122 +24 -22 + NTP_4_2_7P410 + + ntpd/ntp.conf.mdoc.in@1.122 +21 -19 + NTP_4_2_7P410 + + ntpd/ntp.keys.5man@1.120 +4 -4 + NTP_4_2_7P410 + + ntpd/ntp.keys.5mdoc@1.120 +4 -4 + NTP_4_2_7P410 + + ntpd/ntp.keys.html@1.84 +1 -1 + NTP_4_2_7P410 + + ntpd/ntp.keys.man.in@1.120 +4 -4 + NTP_4_2_7P410 + + ntpd/ntp.keys.mdoc.in@1.120 +4 -4 + NTP_4_2_7P410 + + ntpd/ntpd-opts.c@1.420 +7 -7 + NTP_4_2_7P410 + + ntpd/ntpd-opts.h@1.420 +3 -3 + NTP_4_2_7P410 + + ntpd/ntpd.1ntpdman@1.231 +8 -8 + NTP_4_2_7P410 + + ntpd/ntpd.1ntpdmdoc@1.231 +4 -4 + NTP_4_2_7P410 + + ntpd/ntpd.html@1.78 +2 -2 + NTP_4_2_7P410 + + ntpd/ntpd.man.in@1.231 +8 -8 + NTP_4_2_7P410 + + ntpd/ntpd.mdoc.in@1.231 +4 -4 + NTP_4_2_7P410 + + ntpdc/invoke-ntpdc.texi@1.399 +2 -2 + NTP_4_2_7P410 + + ntpdc/ntpdc-opts.c@1.414 +7 -7 + NTP_4_2_7P410 + + ntpdc/ntpdc-opts.h@1.414 +3 -3 + NTP_4_2_7P410 + + ntpdc/ntpdc.1ntpdcman@1.230 +7 -7 + NTP_4_2_7P410 + + ntpdc/ntpdc.1ntpdcmdoc@1.230 +3 -3 + NTP_4_2_7P410 + + ntpdc/ntpdc.html@1.243 +2 -2 + NTP_4_2_7P410 + + ntpdc/ntpdc.man.in@1.230 +7 -7 + NTP_4_2_7P410 + + ntpdc/ntpdc.mdoc.in@1.230 +3 -3 + NTP_4_2_7P410 + + ntpq/invoke-ntpq.texi@1.403 +2 -2 + NTP_4_2_7P410 + + ntpq/ntpq-opts.c@1.417 +7 -7 + NTP_4_2_7P410 + + ntpq/ntpq-opts.h@1.417 +3 -3 + NTP_4_2_7P410 + + ntpq/ntpq.1ntpqman@1.231 +7 -7 + NTP_4_2_7P410 + + ntpq/ntpq.1ntpqmdoc@1.231 +3 -3 + NTP_4_2_7P410 + + ntpq/ntpq.html@1.75 +2 -2 + NTP_4_2_7P410 + + ntpq/ntpq.man.in@1.231 +7 -7 + NTP_4_2_7P410 + + ntpq/ntpq.mdoc.in@1.231 +3 -3 + NTP_4_2_7P410 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.402 +2 -2 + NTP_4_2_7P410 + + ntpsnmpd/ntpsnmpd-opts.c@1.417 +7 -7 + NTP_4_2_7P410 + + ntpsnmpd/ntpsnmpd-opts.h@1.417 +3 -3 + NTP_4_2_7P410 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.231 +15 -15 + NTP_4_2_7P410 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.231 +4 -4 + NTP_4_2_7P410 + + ntpsnmpd/ntpsnmpd.html@1.73 +1 -1 + NTP_4_2_7P410 + + ntpsnmpd/ntpsnmpd.man.in@1.231 +15 -15 + NTP_4_2_7P410 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.231 +4 -4 + NTP_4_2_7P410 + + packageinfo.sh@1.414 +1 -1 + NTP_4_2_7P410 + + scripts/invoke-plot_summary.texi@1.10 +1 -1 + NTP_4_2_7P410 + + scripts/invoke-summary.texi@1.10 +14 -1 + NTP_4_2_7P410 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.220 +29 -1 + NTP_4_2_7P410 + + scripts/ntp-wait/ntp-wait.html@1.237 +31 -2 + NTP_4_2_7P410 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.9 +1 -1 + NTP_4_2_7P410 + + scripts/ntpsweep/ntpsweep.html@1.10 +1 -1 + NTP_4_2_7P410 + + scripts/ntptrace/invoke-ntptrace.texi@1.9 +1 -1 + NTP_4_2_7P410 + + scripts/ntptrace/ntptrace.html@1.10 +1 -1 + NTP_4_2_7P410 + + scripts/plot_summary.1plot_summaryman@1.10 +138 -0 + NTP_4_2_7P410 + + scripts/plot_summary.1plot_summarymdoc@1.10 +3 -3 + NTP_4_2_7P410 + + scripts/plot_summary.html@1.10 +1 -1 + NTP_4_2_7P410 + + scripts/plot_summary.man.in@1.10 +138 -0 + NTP_4_2_7P410 + + scripts/plot_summary.mdoc.in@1.10 +3 -3 + NTP_4_2_7P410 + + scripts/summary.1summaryman@1.10 +7 -7 + NTP_4_2_7P410 + + scripts/summary.1summarymdoc@1.10 +3 -3 + NTP_4_2_7P410 + + scripts/summary.html@1.10 +15 -2 + NTP_4_2_7P410 + + scripts/summary.man.in@1.10 +7 -7 + NTP_4_2_7P410 + + scripts/summary.mdoc.in@1.10 +3 -3 + NTP_4_2_7P410 + + sntp/invoke-sntp.texi@1.399 +2 -2 + NTP_4_2_7P410 + + sntp/sntp-opts.c@1.414 +7 -7 + NTP_4_2_7P410 + + sntp/sntp-opts.h@1.414 +3 -3 + NTP_4_2_7P410 + + sntp/sntp.1sntpman@1.234 +8 -8 + NTP_4_2_7P410 + + sntp/sntp.1sntpmdoc@1.234 +4 -4 + NTP_4_2_7P410 + + sntp/sntp.html@1.414 +2 -2 + NTP_4_2_7P410 + + sntp/sntp.man.in@1.234 +8 -8 + NTP_4_2_7P410 + + sntp/sntp.mdoc.in@1.234 +4 -4 + NTP_4_2_7P410 + + util/invoke-ntp-keygen.texi@1.403 +2 -2 + NTP_4_2_7P410 + + util/ntp-keygen-opts.c@1.417 +7 -7 + NTP_4_2_7P410 + + util/ntp-keygen-opts.h@1.417 +3 -3 + NTP_4_2_7P410 + + util/ntp-keygen.1ntp-keygenman@1.231 +8 -8 + NTP_4_2_7P410 + + util/ntp-keygen.1ntp-keygenmdoc@1.231 +4 -4 + NTP_4_2_7P410 + + util/ntp-keygen.html@1.79 +2 -2 + NTP_4_2_7P410 + + util/ntp-keygen.man.in@1.231 +8 -8 + NTP_4_2_7P410 + + util/ntp-keygen.mdoc.in@1.231 +4 -4 + NTP_4_2_7P410 + +ChangeSet@1.3050, 2014-01-08 10:25:17+00:00, stenn@psp-fb1.ntp.org + [Bug 2530] Fix documentation for enable/disable mode7 and pps + + ChangeLog@1.1385 +1 -0 + [Bug 2530] Fix documentation for enable/disable mode7 and pps + + html/miscopt.html@1.76 +4 -4 + [Bug 2530] Fix documentation for enable/disable mode7 and pps + + ntpd/ntp.conf.def@1.10 +17 -15 + [Bug 2530] Fix documentation for enable/disable mode7 and pps + +ChangeSet@1.3049, 2014-01-08 02:46:45-05:00, stenn@deacon.udel.edu + [Bug 2332] Force reference to 'libgcc_s' when using GCC and GNU ld + + sntp/m4/ntp_libntp.m4@1.25 +5 -3 + [Bug 2332] Force reference to 'libgcc_s' when using GCC and GNU ld + +ChangeSet@1.3046.2.2, 2014-01-07 20:33:45-05:00, stenn@deacon.udel.edu + Cleanup to the new scripts/*/Makefile.am files + + ChangeLog@1.1382.1.2 +1 -0 + + scripts/calc_tickadj/Makefile.am@1.6 +2 -0 + + scripts/ntp-wait/Makefile.am@1.4 +1 -0 + + scripts/ntptrace/Makefile.am@1.5 +2 -0 + +ChangeSet@1.3046.2.1, 2014-01-04 11:22:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P409 + TAG: NTP_4_2_7P409 + + ChangeLog@1.1382.1.1 +1 -0 + NTP_4_2_7P409 + + ntpd/invoke-ntp.conf.texi@1.87 +1 -1 + NTP_4_2_7P409 + + ntpd/invoke-ntp.keys.texi@1.85 +1 -1 + NTP_4_2_7P409 + + ntpd/invoke-ntpd.texi@1.401 +2 -2 + NTP_4_2_7P409 + + ntpd/ntp.conf.5man@1.121 +7 -7 + NTP_4_2_7P409 + + ntpd/ntp.conf.5mdoc@1.121 +3 -3 + NTP_4_2_7P409 + + ntpd/ntp.conf.html@1.82 +1 -1 + NTP_4_2_7P409 + + ntpd/ntp.conf.man.in@1.121 +7 -7 + NTP_4_2_7P409 + + ntpd/ntp.conf.mdoc.in@1.121 +3 -3 + NTP_4_2_7P409 + + ntpd/ntp.keys.5man@1.119 +3 -3 + NTP_4_2_7P409 + + ntpd/ntp.keys.5mdoc@1.119 +3 -3 + NTP_4_2_7P409 + + ntpd/ntp.keys.html@1.83 +1 -1 + NTP_4_2_7P409 + + ntpd/ntp.keys.man.in@1.119 +3 -3 + NTP_4_2_7P409 + + ntpd/ntp.keys.mdoc.in@1.119 +3 -3 + NTP_4_2_7P409 + + ntpd/ntpd-opts.c@1.419 +7 -7 + NTP_4_2_7P409 + + ntpd/ntpd-opts.h@1.419 +3 -3 + NTP_4_2_7P409 + + ntpd/ntpd.1ntpdman@1.230 +7 -7 + NTP_4_2_7P409 + + ntpd/ntpd.1ntpdmdoc@1.230 +3 -3 + NTP_4_2_7P409 + + ntpd/ntpd.html@1.77 +2 -2 + NTP_4_2_7P409 + + ntpd/ntpd.man.in@1.230 +7 -7 + NTP_4_2_7P409 + + ntpd/ntpd.mdoc.in@1.230 +3 -3 + NTP_4_2_7P409 + + ntpdc/invoke-ntpdc.texi@1.398 +2 -2 + NTP_4_2_7P409 + + ntpdc/ntpdc-opts.c@1.413 +7 -7 + NTP_4_2_7P409 + + ntpdc/ntpdc-opts.h@1.413 +3 -3 + NTP_4_2_7P409 + + ntpdc/ntpdc.1ntpdcman@1.229 +6 -6 + NTP_4_2_7P409 + + ntpdc/ntpdc.1ntpdcmdoc@1.229 +2 -2 + NTP_4_2_7P409 + + ntpdc/ntpdc.html@1.242 +2 -2 + NTP_4_2_7P409 + + ntpdc/ntpdc.man.in@1.229 +6 -6 + NTP_4_2_7P409 + + ntpdc/ntpdc.mdoc.in@1.229 +2 -2 + NTP_4_2_7P409 + + ntpq/invoke-ntpq.texi@1.402 +2 -2 + NTP_4_2_7P409 + + ntpq/ntpq-opts.c@1.416 +7 -7 + NTP_4_2_7P409 + + ntpq/ntpq-opts.h@1.416 +3 -3 + NTP_4_2_7P409 + + ntpq/ntpq.1ntpqman@1.230 +6 -6 + NTP_4_2_7P409 + + ntpq/ntpq.1ntpqmdoc@1.230 +2 -2 + NTP_4_2_7P409 + + ntpq/ntpq.html@1.74 +2 -2 + NTP_4_2_7P409 + + ntpq/ntpq.man.in@1.230 +6 -6 + NTP_4_2_7P409 + + ntpq/ntpq.mdoc.in@1.230 +2 -2 + NTP_4_2_7P409 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.401 +2 -2 + NTP_4_2_7P409 + + ntpsnmpd/ntpsnmpd-opts.c@1.416 +7 -7 + NTP_4_2_7P409 + + ntpsnmpd/ntpsnmpd-opts.h@1.416 +3 -3 + NTP_4_2_7P409 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.230 +14 -14 + NTP_4_2_7P409 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.230 +3 -3 + NTP_4_2_7P409 + + ntpsnmpd/ntpsnmpd.html@1.72 +1 -1 + NTP_4_2_7P409 + + ntpsnmpd/ntpsnmpd.man.in@1.230 +14 -14 + NTP_4_2_7P409 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.230 +3 -3 + NTP_4_2_7P409 + + packageinfo.sh@1.413 +1 -1 + NTP_4_2_7P409 + + scripts/invoke-plot_summary.texi@1.9 +1 -1 + NTP_4_2_7P409 + + scripts/invoke-summary.texi@1.9 +1 -14 + NTP_4_2_7P409 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.219 +1 -29 + NTP_4_2_7P409 + + scripts/ntp-wait/ntp-wait.html@1.236 +2 -31 + NTP_4_2_7P409 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.8 +1 -1 + NTP_4_2_7P409 + + scripts/ntpsweep/ntpsweep.html@1.9 +1 -1 + NTP_4_2_7P409 + + scripts/ntptrace/invoke-ntptrace.texi@1.8 +1 -1 + NTP_4_2_7P409 + + scripts/ntptrace/ntptrace.html@1.9 +1 -1 + NTP_4_2_7P409 + + scripts/plot_summary.1plot_summaryman@1.9 +0 -138 + NTP_4_2_7P409 + + scripts/plot_summary.1plot_summarymdoc@1.9 +2 -2 + NTP_4_2_7P409 + + scripts/plot_summary.html@1.9 +1 -1 + NTP_4_2_7P409 + + scripts/plot_summary.man.in@1.9 +0 -138 + NTP_4_2_7P409 + + scripts/plot_summary.mdoc.in@1.9 +2 -2 + NTP_4_2_7P409 + + scripts/summary.1summaryman@1.9 +6 -6 + NTP_4_2_7P409 + + scripts/summary.1summarymdoc@1.9 +2 -2 + NTP_4_2_7P409 + + scripts/summary.html@1.9 +2 -15 + NTP_4_2_7P409 + + scripts/summary.man.in@1.9 +6 -6 + NTP_4_2_7P409 + + scripts/summary.mdoc.in@1.9 +2 -2 + NTP_4_2_7P409 + + sntp/invoke-sntp.texi@1.398 +2 -2 + NTP_4_2_7P409 + + sntp/sntp-opts.c@1.413 +7 -7 + NTP_4_2_7P409 + + sntp/sntp-opts.h@1.413 +3 -3 + NTP_4_2_7P409 + + sntp/sntp.1sntpman@1.233 +7 -7 + NTP_4_2_7P409 + + sntp/sntp.1sntpmdoc@1.233 +3 -3 + NTP_4_2_7P409 + + sntp/sntp.html@1.413 +2 -2 + NTP_4_2_7P409 + + sntp/sntp.man.in@1.233 +7 -7 + NTP_4_2_7P409 + + sntp/sntp.mdoc.in@1.233 +3 -3 + NTP_4_2_7P409 + + util/invoke-ntp-keygen.texi@1.402 +2 -2 + NTP_4_2_7P409 + + util/ntp-keygen-opts.c@1.416 +7 -7 + NTP_4_2_7P409 + + util/ntp-keygen-opts.h@1.416 +3 -3 + NTP_4_2_7P409 + + util/ntp-keygen.1ntp-keygenman@1.230 +7 -7 + NTP_4_2_7P409 + + util/ntp-keygen.1ntp-keygenmdoc@1.230 +3 -3 + NTP_4_2_7P409 + + util/ntp-keygen.html@1.78 +2 -2 + NTP_4_2_7P409 + + util/ntp-keygen.man.in@1.230 +7 -7 + NTP_4_2_7P409 + + util/ntp-keygen.mdoc.in@1.230 +3 -3 + NTP_4_2_7P409 + +ChangeSet@1.3046.1.1, 2014-01-04 00:11:38+01:00, jnperlin@hydra.(none) + [Bug 2332] Force reference to 'libgcc_s' when using GCC, because threading+restricted user+locked memory otherwise fails on Linux. + + ChangeLog@1.1383 +2 -0 + [Bug 2332] Force reference to 'libgcc_s' when using GCC, because threading+restricted user+locked memory otherwise fails on Linux. + + sntp/m4/ntp_libntp.m4@1.24 +10 -0 + [Bug 2332] Force reference to 'libgcc_s' when using GCC, because threading+restricted user+locked memory otherwise fails on Linux. + +ChangeSet@1.3047, 2014-01-01 08:25:27+00:00, stenn@psp-fb1.ntp.org + [Bug 2060] Warn about restrictions with "kod" but not "limited" + + ntpd/ntp_config.c@1.317 +7 -2 + [Bug 2060] Warn about restrictions with "kod" but not "limited" + +ChangeSet@1.3046, 2014-01-01 05:51:07+00:00, stenn@psp-fb1.ntp.org + [Bug 2060] Warn about restrictions with "kod" but not "limited" + + ChangeLog@1.1382 +1 -0 + [Bug 2060] Warn about restrictions with "kod" but not "limited" + + ntpd/ntp_config.c@1.316 +9 -1 + [Bug 2060] Warn about restrictions with "kod" but not "limited" + +ChangeSet@1.3045, 2013-12-29 13:02:05+00:00, stenn@deacon.udel.edu + NTP_4_2_7P408 + TAG: NTP_4_2_7P408 + + ChangeLog@1.1381 +1 -0 + NTP_4_2_7P408 + + ntpd/invoke-ntp.conf.texi@1.86 +1 -1 + NTP_4_2_7P408 + + ntpd/invoke-ntp.keys.texi@1.84 +1 -1 + NTP_4_2_7P408 + + ntpd/invoke-ntpd.texi@1.400 +2 -2 + NTP_4_2_7P408 + + ntpd/ntp.conf.5man@1.120 +7 -7 + NTP_4_2_7P408 + + ntpd/ntp.conf.5mdoc@1.120 +2 -2 + NTP_4_2_7P408 + + ntpd/ntp.conf.html@1.81 +1 -1 + NTP_4_2_7P408 + + ntpd/ntp.conf.man.in@1.120 +7 -7 + NTP_4_2_7P408 + + ntpd/ntp.conf.mdoc.in@1.120 +2 -2 + NTP_4_2_7P408 + + ntpd/ntp.keys.5man@1.118 +3 -3 + NTP_4_2_7P408 + + ntpd/ntp.keys.5mdoc@1.118 +2 -2 + NTP_4_2_7P408 + + ntpd/ntp.keys.html@1.82 +1 -1 + NTP_4_2_7P408 + + ntpd/ntp.keys.man.in@1.118 +3 -3 + NTP_4_2_7P408 + + ntpd/ntp.keys.mdoc.in@1.118 +2 -2 + NTP_4_2_7P408 + + ntpd/ntpd-opts.c@1.418 +7 -7 + NTP_4_2_7P408 + + ntpd/ntpd-opts.h@1.418 +3 -3 + NTP_4_2_7P408 + + ntpd/ntpd.1ntpdman@1.229 +7 -7 + NTP_4_2_7P408 + + ntpd/ntpd.1ntpdmdoc@1.229 +2 -2 + NTP_4_2_7P408 + + ntpd/ntpd.html@1.76 +2 -2 + NTP_4_2_7P408 + + ntpd/ntpd.man.in@1.229 +7 -7 + NTP_4_2_7P408 + + ntpd/ntpd.mdoc.in@1.229 +2 -2 + NTP_4_2_7P408 + + ntpdc/invoke-ntpdc.texi@1.397 +2 -2 + NTP_4_2_7P408 + + ntpdc/ntpdc-opts.c@1.412 +7 -7 + NTP_4_2_7P408 + + ntpdc/ntpdc-opts.h@1.412 +3 -3 + NTP_4_2_7P408 + + ntpdc/ntpdc.1ntpdcman@1.228 +6 -6 + NTP_4_2_7P408 + + ntpdc/ntpdc.1ntpdcmdoc@1.228 +1 -1 + NTP_4_2_7P408 + + ntpdc/ntpdc.html@1.241 +2 -2 + NTP_4_2_7P408 + + ntpdc/ntpdc.man.in@1.228 +6 -6 + NTP_4_2_7P408 + + ntpdc/ntpdc.mdoc.in@1.228 +1 -1 + NTP_4_2_7P408 + + ntpq/invoke-ntpq.texi@1.401 +2 -2 + NTP_4_2_7P408 + + ntpq/ntpq-opts.c@1.415 +7 -7 + NTP_4_2_7P408 + + ntpq/ntpq-opts.h@1.415 +3 -3 + NTP_4_2_7P408 + + ntpq/ntpq.1ntpqman@1.229 +6 -6 + NTP_4_2_7P408 + + ntpq/ntpq.1ntpqmdoc@1.229 +1 -1 + NTP_4_2_7P408 + + ntpq/ntpq.html@1.73 +2 -2 + NTP_4_2_7P408 + + ntpq/ntpq.man.in@1.229 +6 -6 + NTP_4_2_7P408 + + ntpq/ntpq.mdoc.in@1.229 +1 -1 + NTP_4_2_7P408 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.400 +2 -2 + NTP_4_2_7P408 + + ntpsnmpd/ntpsnmpd-opts.c@1.415 +7 -7 + NTP_4_2_7P408 + + ntpsnmpd/ntpsnmpd-opts.h@1.415 +3 -3 + NTP_4_2_7P408 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.229 +7 -7 + NTP_4_2_7P408 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.229 +2 -2 + NTP_4_2_7P408 + + ntpsnmpd/ntpsnmpd.html@1.71 +1 -1 + NTP_4_2_7P408 + + ntpsnmpd/ntpsnmpd.man.in@1.229 +7 -7 + NTP_4_2_7P408 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.229 +2 -2 + NTP_4_2_7P408 + + packageinfo.sh@1.412 +1 -1 + NTP_4_2_7P408 + + scripts/invoke-plot_summary.texi@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/invoke-summary.texi@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.218 +1 -1 + NTP_4_2_7P408 + + scripts/ntp-wait/ntp-wait.html@1.235 +1 -1 + NTP_4_2_7P408 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.7 +1 -1 + NTP_4_2_7P408 + + scripts/ntpsweep/ntpsweep.html@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/ntptrace/invoke-ntptrace.texi@1.7 +1 -1 + NTP_4_2_7P408 + + scripts/ntptrace/ntptrace.html@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/plot_summary.1plot_summaryman@1.8 +4 -4 + NTP_4_2_7P408 + + scripts/plot_summary.1plot_summarymdoc@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/plot_summary.html@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/plot_summary.man.in@1.8 +4 -4 + NTP_4_2_7P408 + + scripts/plot_summary.mdoc.in@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/summary.1summaryman@1.8 +4 -4 + NTP_4_2_7P408 + + scripts/summary.1summarymdoc@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/summary.html@1.8 +1 -1 + NTP_4_2_7P408 + + scripts/summary.man.in@1.8 +4 -4 + NTP_4_2_7P408 + + scripts/summary.mdoc.in@1.8 +1 -1 + NTP_4_2_7P408 + + sntp/invoke-sntp.texi@1.397 +2 -2 + NTP_4_2_7P408 + + sntp/sntp-opts.c@1.412 +7 -7 + NTP_4_2_7P408 + + sntp/sntp-opts.h@1.412 +3 -3 + NTP_4_2_7P408 + + sntp/sntp.1sntpman@1.232 +7 -7 + NTP_4_2_7P408 + + sntp/sntp.1sntpmdoc@1.232 +2 -2 + NTP_4_2_7P408 + + sntp/sntp.html@1.412 +2 -2 + NTP_4_2_7P408 + + sntp/sntp.man.in@1.232 +7 -7 + NTP_4_2_7P408 + + sntp/sntp.mdoc.in@1.232 +2 -2 + NTP_4_2_7P408 + + util/invoke-ntp-keygen.texi@1.401 +2 -2 + NTP_4_2_7P408 + + util/ntp-keygen-opts.c@1.415 +7 -7 + NTP_4_2_7P408 + + util/ntp-keygen-opts.h@1.415 +3 -3 + NTP_4_2_7P408 + + util/ntp-keygen.1ntp-keygenman@1.229 +7 -7 + NTP_4_2_7P408 + + util/ntp-keygen.1ntp-keygenmdoc@1.229 +2 -2 + NTP_4_2_7P408 + + util/ntp-keygen.html@1.77 +2 -2 + NTP_4_2_7P408 + + util/ntp-keygen.man.in@1.229 +7 -7 + NTP_4_2_7P408 + + util/ntp-keygen.mdoc.in@1.229 +2 -2 + NTP_4_2_7P408 + +ChangeSet@1.3042.1.1, 2013-12-29 11:41:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P407 + TAG: NTP_4_2_7P407 + + ChangeLog@1.1378.1.1 +1 -0 + NTP_4_2_7P407 + + ntpd/invoke-ntp.conf.texi@1.85 +1 -1 + NTP_4_2_7P407 + + ntpd/invoke-ntp.keys.texi@1.83 +1 -1 + NTP_4_2_7P407 + + ntpd/invoke-ntpd.texi@1.399 +2 -2 + NTP_4_2_7P407 + + ntpd/ntp.conf.5man@1.119 +7 -7 + NTP_4_2_7P407 + + ntpd/ntp.conf.5mdoc@1.119 +3 -3 + NTP_4_2_7P407 + + ntpd/ntp.conf.html@1.80 +1 -1 + NTP_4_2_7P407 + + ntpd/ntp.conf.man.in@1.119 +7 -7 + NTP_4_2_7P407 + + ntpd/ntp.conf.mdoc.in@1.119 +3 -3 + NTP_4_2_7P407 + + ntpd/ntp.keys.5man@1.117 +3 -3 + NTP_4_2_7P407 + + ntpd/ntp.keys.5mdoc@1.117 +3 -3 + NTP_4_2_7P407 + + ntpd/ntp.keys.html@1.81 +1 -1 + NTP_4_2_7P407 + + ntpd/ntp.keys.man.in@1.117 +3 -3 + NTP_4_2_7P407 + + ntpd/ntp.keys.mdoc.in@1.117 +3 -3 + NTP_4_2_7P407 + + ntpd/ntpd-opts.c@1.417 +7 -7 + NTP_4_2_7P407 + + ntpd/ntpd-opts.h@1.417 +3 -3 + NTP_4_2_7P407 + + ntpd/ntpd.1ntpdman@1.228 +7 -7 + NTP_4_2_7P407 + + ntpd/ntpd.1ntpdmdoc@1.228 +3 -3 + NTP_4_2_7P407 + + ntpd/ntpd.html@1.75 +2 -2 + NTP_4_2_7P407 + + ntpd/ntpd.man.in@1.228 +7 -7 + NTP_4_2_7P407 + + ntpd/ntpd.mdoc.in@1.228 +3 -3 + NTP_4_2_7P407 + + ntpdc/invoke-ntpdc.texi@1.396 +2 -2 + NTP_4_2_7P407 + + ntpdc/ntpdc-opts.c@1.411 +7 -7 + NTP_4_2_7P407 + + ntpdc/ntpdc-opts.h@1.411 +3 -3 + NTP_4_2_7P407 + + ntpdc/ntpdc.1ntpdcman@1.227 +6 -6 + NTP_4_2_7P407 + + ntpdc/ntpdc.1ntpdcmdoc@1.227 +2 -2 + NTP_4_2_7P407 + + ntpdc/ntpdc.html@1.240 +2 -2 + NTP_4_2_7P407 + + ntpdc/ntpdc.man.in@1.227 +6 -6 + NTP_4_2_7P407 + + ntpdc/ntpdc.mdoc.in@1.227 +2 -2 + NTP_4_2_7P407 + + ntpq/invoke-ntpq.texi@1.400 +2 -2 + NTP_4_2_7P407 + + ntpq/ntpq-opts.c@1.414 +7 -7 + NTP_4_2_7P407 + + ntpq/ntpq-opts.h@1.414 +3 -3 + NTP_4_2_7P407 + + ntpq/ntpq.1ntpqman@1.228 +6 -6 + NTP_4_2_7P407 + + ntpq/ntpq.1ntpqmdoc@1.228 +2 -2 + NTP_4_2_7P407 + + ntpq/ntpq.html@1.72 +2 -2 + NTP_4_2_7P407 + + ntpq/ntpq.man.in@1.228 +6 -6 + NTP_4_2_7P407 + + ntpq/ntpq.mdoc.in@1.228 +2 -2 + NTP_4_2_7P407 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.399 +2 -2 + NTP_4_2_7P407 + + ntpsnmpd/ntpsnmpd-opts.c@1.414 +7 -7 + NTP_4_2_7P407 + + ntpsnmpd/ntpsnmpd-opts.h@1.414 +3 -3 + NTP_4_2_7P407 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.228 +7 -7 + NTP_4_2_7P407 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.228 +3 -3 + NTP_4_2_7P407 + + ntpsnmpd/ntpsnmpd.html@1.70 +1 -1 + NTP_4_2_7P407 + + ntpsnmpd/ntpsnmpd.man.in@1.228 +7 -7 + NTP_4_2_7P407 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.228 +3 -3 + NTP_4_2_7P407 + + packageinfo.sh@1.409.1.1 +1 -1 + NTP_4_2_7P407 + + scripts/invoke-plot_summary.texi@1.7 +1 -1 + NTP_4_2_7P407 + + scripts/invoke-summary.texi@1.7 +1 -1 + NTP_4_2_7P407 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.217 +1 -1 + NTP_4_2_7P407 + + scripts/ntp-wait/ntp-wait.html@1.234 +1 -1 + NTP_4_2_7P407 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.6 +1 -1 + NTP_4_2_7P407 + + scripts/ntpsweep/ntpsweep.html@1.7 +1 -1 + NTP_4_2_7P407 + + scripts/ntptrace/invoke-ntptrace.texi@1.6 +1 -1 + NTP_4_2_7P407 + + scripts/ntptrace/ntptrace.html@1.7 +1 -1 + NTP_4_2_7P407 + + scripts/plot_summary.1plot_summaryman@1.7 +6 -6 + NTP_4_2_7P407 + + scripts/plot_summary.1plot_summarymdoc@1.7 +2 -2 + NTP_4_2_7P407 + + scripts/plot_summary.html@1.7 +1 -1 + NTP_4_2_7P407 + + scripts/plot_summary.man.in@1.7 +6 -6 + NTP_4_2_7P407 + + scripts/plot_summary.mdoc.in@1.7 +2 -2 + NTP_4_2_7P407 + + scripts/summary.1summaryman@1.7 +6 -6 + NTP_4_2_7P407 + + scripts/summary.1summarymdoc@1.7 +2 -2 + NTP_4_2_7P407 + + scripts/summary.html@1.7 +1 -1 + NTP_4_2_7P407 + + scripts/summary.man.in@1.7 +6 -6 + NTP_4_2_7P407 + + scripts/summary.mdoc.in@1.7 +2 -2 + NTP_4_2_7P407 + + sntp/invoke-sntp.texi@1.396 +2 -2 + NTP_4_2_7P407 + + sntp/sntp-opts.c@1.411 +7 -7 + NTP_4_2_7P407 + + sntp/sntp-opts.h@1.411 +3 -3 + NTP_4_2_7P407 + + sntp/sntp.1sntpman@1.231 +14 -14 + NTP_4_2_7P407 + + sntp/sntp.1sntpmdoc@1.231 +3 -3 + NTP_4_2_7P407 + + sntp/sntp.html@1.411 +2 -2 + NTP_4_2_7P407 + + sntp/sntp.man.in@1.231 +14 -14 + NTP_4_2_7P407 + + sntp/sntp.mdoc.in@1.231 +3 -3 + NTP_4_2_7P407 + + util/invoke-ntp-keygen.texi@1.400 +2 -2 + NTP_4_2_7P407 + + util/ntp-keygen-opts.c@1.414 +7 -7 + NTP_4_2_7P407 + + util/ntp-keygen-opts.h@1.414 +3 -3 + NTP_4_2_7P407 + + util/ntp-keygen.1ntp-keygenman@1.228 +7 -7 + NTP_4_2_7P407 + + util/ntp-keygen.1ntp-keygenmdoc@1.228 +3 -3 + NTP_4_2_7P407 + + util/ntp-keygen.html@1.76 +2 -2 + NTP_4_2_7P407 + + util/ntp-keygen.man.in@1.228 +7 -7 + NTP_4_2_7P407 + + util/ntp-keygen.mdoc.in@1.228 +3 -3 + NTP_4_2_7P407 + +ChangeSet@1.3043, 2013-12-29 10:20:38+00:00, stenn@psp-fb1.ntp.org + [Bug 2187] Update version number generation scripts + + ChangeLog@1.1379 +1 -0 + [Bug 2187] Update version number generation scripts + + configure.ac@1.571 +1 -1 + [Bug 2187] Update version number generation scripts + + packageinfo.sh@1.410 +14 -1 + [Bug 2187] Update version number generation scripts + + scripts/build/VersionName@1.8 +7 -1 + [Bug 2187] Update version number generation scripts + +ChangeSet@1.3042, 2013-12-29 07:55:28+00:00, stenn@psp-fb1.ntp.org + [Bug 2519] mktime.c does not compile on 64-bit Solaris but we do not need timegm() and the Solaris provides mktime() + + ChangeLog@1.1378 +2 -0 + [Bug 2519] mktime.c does not compile on 64-bit Solaris but we do not need timegm() and the Solaris provides mktime() + + libntp/mktime.c@1.13 +3 -1 + [Bug 2519] mktime.c does not compile on 64-bit Solaris but we do not need timegm() and the Solaris provides mktime() + +ChangeSet@1.3041, 2013-12-29 07:06:37+00:00, stenn@psp-fb1.ntp.org + [Bug 2522] Revert Bug 2513 fix - it breaks backward compatibility + + ChangeLog@1.1377 +1 -0 + [Bug 2522] Revert Bug 2513 fix - it breaks backward compatibility + + ntpd/ntpd.c@1.152 +1 -4 + [Bug 2522] Revert Bug 2513 fix - it breaks backward compatibility + +ChangeSet@1.3040, 2013-12-28 12:09:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P406 + TAG: NTP_4_2_7P406 + + ChangeLog@1.1376 +1 -0 + NTP_4_2_7P406 + + ntpd/invoke-ntp.conf.texi@1.84 +1 -1 + NTP_4_2_7P406 + + ntpd/invoke-ntp.keys.texi@1.82 +1 -1 + NTP_4_2_7P406 + + ntpd/invoke-ntpd.texi@1.398 +2 -2 + NTP_4_2_7P406 + + ntpd/ntp.conf.5man@1.118 +7 -7 + NTP_4_2_7P406 + + ntpd/ntp.conf.5mdoc@1.118 +3 -3 + NTP_4_2_7P406 + + ntpd/ntp.conf.html@1.79 +1 -1 + NTP_4_2_7P406 + + ntpd/ntp.conf.man.in@1.118 +7 -7 + NTP_4_2_7P406 + + ntpd/ntp.conf.mdoc.in@1.118 +3 -3 + NTP_4_2_7P406 + + ntpd/ntp.keys.5man@1.116 +3 -3 + NTP_4_2_7P406 + + ntpd/ntp.keys.5mdoc@1.116 +3 -3 + NTP_4_2_7P406 + + ntpd/ntp.keys.html@1.80 +1 -1 + NTP_4_2_7P406 + + ntpd/ntp.keys.man.in@1.116 +3 -3 + NTP_4_2_7P406 + + ntpd/ntp.keys.mdoc.in@1.116 +3 -3 + NTP_4_2_7P406 + + ntpd/ntpd-opts.c@1.416 +7 -7 + NTP_4_2_7P406 + + ntpd/ntpd-opts.h@1.416 +3 -3 + NTP_4_2_7P406 + + ntpd/ntpd.1ntpdman@1.227 +7 -7 + NTP_4_2_7P406 + + ntpd/ntpd.1ntpdmdoc@1.227 +3 -3 + NTP_4_2_7P406 + + ntpd/ntpd.html@1.74 +2 -2 + NTP_4_2_7P406 + + ntpd/ntpd.man.in@1.227 +7 -7 + NTP_4_2_7P406 + + ntpd/ntpd.mdoc.in@1.227 +3 -3 + NTP_4_2_7P406 + + ntpdc/invoke-ntpdc.texi@1.395 +2 -2 + NTP_4_2_7P406 + + ntpdc/ntpdc-opts.c@1.410 +7 -7 + NTP_4_2_7P406 + + ntpdc/ntpdc-opts.h@1.410 +3 -3 + NTP_4_2_7P406 + + ntpdc/ntpdc.1ntpdcman@1.226 +6 -6 + NTP_4_2_7P406 + + ntpdc/ntpdc.1ntpdcmdoc@1.226 +2 -2 + NTP_4_2_7P406 + + ntpdc/ntpdc.html@1.239 +2 -2 + NTP_4_2_7P406 + + ntpdc/ntpdc.man.in@1.226 +6 -6 + NTP_4_2_7P406 + + ntpdc/ntpdc.mdoc.in@1.226 +2 -2 + NTP_4_2_7P406 + + ntpq/invoke-ntpq.texi@1.399 +2 -2 + NTP_4_2_7P406 + + ntpq/ntpq-opts.c@1.413 +7 -7 + NTP_4_2_7P406 + + ntpq/ntpq-opts.h@1.413 +3 -3 + NTP_4_2_7P406 + + ntpq/ntpq.1ntpqman@1.227 +6 -6 + NTP_4_2_7P406 + + ntpq/ntpq.1ntpqmdoc@1.227 +2 -2 + NTP_4_2_7P406 + + ntpq/ntpq.html@1.71 +2 -2 + NTP_4_2_7P406 + + ntpq/ntpq.man.in@1.227 +6 -6 + NTP_4_2_7P406 + + ntpq/ntpq.mdoc.in@1.227 +2 -2 + NTP_4_2_7P406 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.398 +2 -2 + NTP_4_2_7P406 + + ntpsnmpd/ntpsnmpd-opts.c@1.413 +7 -7 + NTP_4_2_7P406 + + ntpsnmpd/ntpsnmpd-opts.h@1.413 +3 -3 + NTP_4_2_7P406 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.227 +7 -7 + NTP_4_2_7P406 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.227 +3 -3 + NTP_4_2_7P406 + + ntpsnmpd/ntpsnmpd.html@1.69 +1 -1 + NTP_4_2_7P406 + + ntpsnmpd/ntpsnmpd.man.in@1.227 +7 -7 + NTP_4_2_7P406 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.227 +3 -3 + NTP_4_2_7P406 + + packageinfo.sh@1.409 +1 -1 + NTP_4_2_7P406 + + scripts/invoke-plot_summary.texi@1.6 +1 -1 + NTP_4_2_7P406 + + scripts/invoke-summary.texi@1.6 +1 -1 + NTP_4_2_7P406 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.216 +1 -1 + NTP_4_2_7P406 + + scripts/ntp-wait/ntp-wait.html@1.233 +1 -1 + NTP_4_2_7P406 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.5 +1 -1 + NTP_4_2_7P406 + + scripts/ntpsweep/ntpsweep.html@1.6 +1 -1 + NTP_4_2_7P406 + + scripts/ntptrace/invoke-ntptrace.texi@1.5 +1 -1 + NTP_4_2_7P406 + + scripts/ntptrace/ntptrace.html@1.6 +1 -1 + NTP_4_2_7P406 + + scripts/plot_summary.1plot_summaryman@1.6 +6 -6 + NTP_4_2_7P406 + + scripts/plot_summary.1plot_summarymdoc@1.6 +2 -2 + NTP_4_2_7P406 + + scripts/plot_summary.html@1.6 +1 -1 + NTP_4_2_7P406 + + scripts/plot_summary.man.in@1.6 +6 -6 + NTP_4_2_7P406 + + scripts/plot_summary.mdoc.in@1.6 +2 -2 + NTP_4_2_7P406 + + scripts/summary.1summaryman@1.6 +6 -6 + NTP_4_2_7P406 + + scripts/summary.1summarymdoc@1.6 +2 -2 + NTP_4_2_7P406 + + scripts/summary.html@1.6 +1 -1 + NTP_4_2_7P406 + + scripts/summary.man.in@1.6 +6 -6 + NTP_4_2_7P406 + + scripts/summary.mdoc.in@1.6 +2 -2 + NTP_4_2_7P406 + + sntp/invoke-sntp.texi@1.395 +2 -2 + NTP_4_2_7P406 + + sntp/sntp-opts.c@1.410 +7 -7 + NTP_4_2_7P406 + + sntp/sntp-opts.h@1.410 +3 -3 + NTP_4_2_7P406 + + sntp/sntp.1sntpman@1.230 +14 -14 + NTP_4_2_7P406 + + sntp/sntp.1sntpmdoc@1.230 +3 -3 + NTP_4_2_7P406 + + sntp/sntp.html@1.410 +2 -2 + NTP_4_2_7P406 + + sntp/sntp.man.in@1.230 +14 -14 + NTP_4_2_7P406 + + sntp/sntp.mdoc.in@1.230 +3 -3 + NTP_4_2_7P406 + + util/invoke-ntp-keygen.texi@1.399 +2 -2 + NTP_4_2_7P406 + + util/ntp-keygen-opts.c@1.413 +7 -7 + NTP_4_2_7P406 + + util/ntp-keygen-opts.h@1.413 +3 -3 + NTP_4_2_7P406 + + util/ntp-keygen.1ntp-keygenman@1.227 +7 -7 + NTP_4_2_7P406 + + util/ntp-keygen.1ntp-keygenmdoc@1.227 +3 -3 + NTP_4_2_7P406 + + util/ntp-keygen.html@1.75 +2 -2 + NTP_4_2_7P406 + + util/ntp-keygen.man.in@1.227 +7 -7 + NTP_4_2_7P406 + + util/ntp-keygen.mdoc.in@1.227 +3 -3 + NTP_4_2_7P406 + +ChangeSet@1.3039, 2013-12-28 11:47:47+00:00, harlan@chessie.everett.org + [Bug 2521] VPATH tweaks for perl -opts files + + ChangeLog@1.1375 +1 -0 + [Bug 2521] VPATH tweaks for perl -opts files + + scripts/Makefile.am@1.36 +4 -4 + [Bug 2521] VPATH tweaks for perl -opts files + +ChangeSet@1.3038, 2013-12-28 10:34:12+00:00, stenn@deacon.udel.edu + NTP_4_2_7P405 + TAG: NTP_4_2_7P405 + + .point-changed-filelist@1.22 +3 -0 + Updates for some of the new script invoke-* files + + ChangeLog@1.1374 +1 -0 + NTP_4_2_7P405 + + ntpd/invoke-ntp.conf.texi@1.83 +1 -1 + NTP_4_2_7P405 + + ntpd/invoke-ntp.keys.texi@1.81 +1 -1 + NTP_4_2_7P405 + + ntpd/invoke-ntpd.texi@1.397 +2 -2 + NTP_4_2_7P405 + + ntpd/ntp.conf.5man@1.117 +7 -7 + NTP_4_2_7P405 + + ntpd/ntp.conf.5mdoc@1.117 +3 -3 + NTP_4_2_7P405 + + ntpd/ntp.conf.html@1.78 +1 -1 + NTP_4_2_7P405 + + ntpd/ntp.conf.man.in@1.117 +7 -7 + NTP_4_2_7P405 + + ntpd/ntp.conf.mdoc.in@1.117 +3 -3 + NTP_4_2_7P405 + + ntpd/ntp.keys.5man@1.115 +3 -3 + NTP_4_2_7P405 + + ntpd/ntp.keys.5mdoc@1.115 +3 -3 + NTP_4_2_7P405 + + ntpd/ntp.keys.html@1.79 +1 -1 + NTP_4_2_7P405 + + ntpd/ntp.keys.man.in@1.115 +3 -3 + NTP_4_2_7P405 + + ntpd/ntp.keys.mdoc.in@1.115 +3 -3 + NTP_4_2_7P405 + + ntpd/ntpd-opts.c@1.415 +7 -7 + NTP_4_2_7P405 + + ntpd/ntpd-opts.h@1.415 +3 -3 + NTP_4_2_7P405 + + ntpd/ntpd.1ntpdman@1.226 +7 -7 + NTP_4_2_7P405 + + ntpd/ntpd.1ntpdmdoc@1.226 +3 -3 + NTP_4_2_7P405 + + ntpd/ntpd.html@1.73 +2 -2 + NTP_4_2_7P405 + + ntpd/ntpd.man.in@1.226 +7 -7 + NTP_4_2_7P405 + + ntpd/ntpd.mdoc.in@1.226 +3 -3 + NTP_4_2_7P405 + + ntpdc/invoke-ntpdc.texi@1.394 +2 -2 + NTP_4_2_7P405 + + ntpdc/ntpdc-opts.c@1.409 +7 -7 + NTP_4_2_7P405 + + ntpdc/ntpdc-opts.h@1.409 +3 -3 + NTP_4_2_7P405 + + ntpdc/ntpdc.1ntpdcman@1.225 +13 -13 + NTP_4_2_7P405 + + ntpdc/ntpdc.1ntpdcmdoc@1.225 +2 -2 + NTP_4_2_7P405 + + ntpdc/ntpdc.html@1.238 +2 -2 + NTP_4_2_7P405 + + ntpdc/ntpdc.man.in@1.225 +13 -13 + NTP_4_2_7P405 + + ntpdc/ntpdc.mdoc.in@1.225 +2 -2 + NTP_4_2_7P405 + + ntpq/invoke-ntpq.texi@1.398 +2 -2 + NTP_4_2_7P405 + + ntpq/ntpq-opts.c@1.412 +7 -7 + NTP_4_2_7P405 + + ntpq/ntpq-opts.h@1.412 +3 -3 + NTP_4_2_7P405 + + ntpq/ntpq.1ntpqman@1.226 +6 -6 + NTP_4_2_7P405 + + ntpq/ntpq.1ntpqmdoc@1.226 +2 -2 + NTP_4_2_7P405 + + ntpq/ntpq.html@1.70 +2 -2 + NTP_4_2_7P405 + + ntpq/ntpq.man.in@1.226 +6 -6 + NTP_4_2_7P405 + + ntpq/ntpq.mdoc.in@1.226 +2 -2 + NTP_4_2_7P405 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.397 +2 -2 + NTP_4_2_7P405 + + ntpsnmpd/ntpsnmpd-opts.c@1.412 +7 -7 + NTP_4_2_7P405 + + ntpsnmpd/ntpsnmpd-opts.h@1.412 +3 -3 + NTP_4_2_7P405 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.226 +7 -7 + NTP_4_2_7P405 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.226 +3 -3 + NTP_4_2_7P405 + + ntpsnmpd/ntpsnmpd.html@1.68 +1 -1 + NTP_4_2_7P405 + + ntpsnmpd/ntpsnmpd.man.in@1.226 +7 -7 + NTP_4_2_7P405 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.226 +3 -3 + NTP_4_2_7P405 + + packageinfo.sh@1.408 +1 -1 + NTP_4_2_7P405 + + scripts/invoke-plot_summary.texi@1.5 +1 -1 + NTP_4_2_7P405 + + scripts/invoke-summary.texi@1.5 +1 -1 + NTP_4_2_7P405 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.215 +1 -1 + NTP_4_2_7P405 + + scripts/ntp-wait/ntp-wait.html@1.232 +1 -1 + NTP_4_2_7P405 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.4 +1 -1 + NTP_4_2_7P405 + + scripts/ntpsweep/ntpsweep.html@1.5 +1 -1 + NTP_4_2_7P405 + + scripts/ntptrace/invoke-ntptrace.texi@1.4 +1 -1 + NTP_4_2_7P405 + + scripts/ntptrace/ntptrace.html@1.5 +1 -1 + NTP_4_2_7P405 + + scripts/plot_summary.1plot_summaryman@1.5 +6 -6 + NTP_4_2_7P405 + + scripts/plot_summary.1plot_summarymdoc@1.5 +2 -2 + NTP_4_2_7P405 + + scripts/plot_summary.html@1.5 +1 -1 + NTP_4_2_7P405 + + scripts/plot_summary.man.in@1.5 +6 -6 + NTP_4_2_7P405 + + scripts/plot_summary.mdoc.in@1.5 +2 -2 + NTP_4_2_7P405 + + scripts/summary.1summaryman@1.5 +6 -6 + NTP_4_2_7P405 + + scripts/summary.1summarymdoc@1.5 +2 -2 + NTP_4_2_7P405 + + scripts/summary.html@1.5 +1 -1 + NTP_4_2_7P405 + + scripts/summary.man.in@1.5 +6 -6 + NTP_4_2_7P405 + + scripts/summary.mdoc.in@1.5 +2 -2 + NTP_4_2_7P405 + + sntp/invoke-sntp.texi@1.394 +2 -2 + NTP_4_2_7P405 + + sntp/sntp-opts.c@1.409 +7 -7 + NTP_4_2_7P405 + + sntp/sntp-opts.h@1.409 +3 -3 + NTP_4_2_7P405 + + sntp/sntp.1sntpman@1.229 +7 -7 + NTP_4_2_7P405 + + sntp/sntp.1sntpmdoc@1.229 +3 -3 + NTP_4_2_7P405 + + sntp/sntp.html@1.409 +2 -2 + NTP_4_2_7P405 + + sntp/sntp.man.in@1.229 +7 -7 + NTP_4_2_7P405 + + sntp/sntp.mdoc.in@1.229 +3 -3 + NTP_4_2_7P405 + + util/invoke-ntp-keygen.texi@1.398 +2 -2 + NTP_4_2_7P405 + + util/ntp-keygen-opts.c@1.412 +7 -7 + NTP_4_2_7P405 + + util/ntp-keygen-opts.h@1.412 +3 -3 + NTP_4_2_7P405 + + util/ntp-keygen.1ntp-keygenman@1.226 +7 -7 + NTP_4_2_7P405 + + util/ntp-keygen.1ntp-keygenmdoc@1.226 +3 -3 + NTP_4_2_7P405 + + util/ntp-keygen.html@1.74 +2 -2 + NTP_4_2_7P405 + + util/ntp-keygen.man.in@1.226 +7 -7 + NTP_4_2_7P405 + + util/ntp-keygen.mdoc.in@1.226 +3 -3 + NTP_4_2_7P405 + +ChangeSet@1.3037, 2013-12-27 03:50:46-05:00, stenn@deacon.udel.edu + [Bug 2521] bootstrap script needs a tweak for perl *-opts files + + ChangeLog@1.1373 +1 -0 + [Bug 2521] bootstrap script needs a tweak for perl *-opts files + + bootstrap@1.43 +1 -1 + [Bug 2521] bootstrap script needs a tweak for perl *-opts files + +ChangeSet@1.3036, 2013-12-27 05:51:12+00:00, stenn@psp-fb1.ntp.org + [Bug 2524] Add ntpsweep to sntp/loc/* files + + ChangeLog@1.1372 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + ChangeLog@1.1371 +1 -0 + [Bug 2526] Add "noinst" support to the sntp/loc/ framework + + scripts/ntpsweep/Makefile.am@1.5 +12 -2 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/README@1.2 +2 -1 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/darwin@1.2 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/debian@1.3 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/freebsd@1.5 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/legacy@1.6 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/netbsd@1.2 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/redhat@1.4 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/loc/solaris@1.5 +1 -0 + [Bug 2524] Add ntpsweep to sntp/loc/* files + + sntp/m4/ntp_locinfo.m4@1.17 +21 -0 + [Bug 2526] Add "noinst" support to the sntp/loc/ framework + + sntp/scripts/genLocInfo@1.17 +16 -4 + [Bug 2526] Add "noinst" support to the sntp/loc/ framework + +ChangeSet@1.3035, 2013-12-24 11:40:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P404 + TAG: NTP_4_2_7P404 + + ChangeLog@1.1370 +1 -0 + NTP_4_2_7P404 + + ntpd/invoke-ntp.conf.texi@1.82 +1 -1 + NTP_4_2_7P404 + + ntpd/invoke-ntp.keys.texi@1.80 +1 -1 + NTP_4_2_7P404 + + ntpd/invoke-ntpd.texi@1.396 +2 -2 + NTP_4_2_7P404 + + ntpd/ntp.conf.5man@1.116 +7 -7 + NTP_4_2_7P404 + + ntpd/ntp.conf.5mdoc@1.116 +3 -3 + NTP_4_2_7P404 + + ntpd/ntp.conf.html@1.77 +1 -1 + NTP_4_2_7P404 + + ntpd/ntp.conf.man.in@1.116 +7 -7 + NTP_4_2_7P404 + + ntpd/ntp.conf.mdoc.in@1.116 +3 -3 + NTP_4_2_7P404 + + ntpd/ntp.keys.5man@1.114 +3 -3 + NTP_4_2_7P404 + + ntpd/ntp.keys.5mdoc@1.114 +3 -3 + NTP_4_2_7P404 + + ntpd/ntp.keys.html@1.78 +1 -1 + NTP_4_2_7P404 + + ntpd/ntp.keys.man.in@1.114 +3 -3 + NTP_4_2_7P404 + + ntpd/ntp.keys.mdoc.in@1.114 +3 -3 + NTP_4_2_7P404 + + ntpd/ntpd-opts.c@1.414 +7 -7 + NTP_4_2_7P404 + + ntpd/ntpd-opts.h@1.414 +3 -3 + NTP_4_2_7P404 + + ntpd/ntpd.1ntpdman@1.225 +7 -7 + NTP_4_2_7P404 + + ntpd/ntpd.1ntpdmdoc@1.225 +3 -3 + NTP_4_2_7P404 + + ntpd/ntpd.html@1.72 +2 -2 + NTP_4_2_7P404 + + ntpd/ntpd.man.in@1.225 +7 -7 + NTP_4_2_7P404 + + ntpd/ntpd.mdoc.in@1.225 +3 -3 + NTP_4_2_7P404 + + ntpdc/invoke-ntpdc.texi@1.393 +2 -2 + NTP_4_2_7P404 + + ntpdc/ntpdc-opts.c@1.408 +7 -7 + NTP_4_2_7P404 + + ntpdc/ntpdc-opts.h@1.408 +3 -3 + NTP_4_2_7P404 + + ntpdc/ntpdc.1ntpdcman@1.224 +13 -13 + NTP_4_2_7P404 + + ntpdc/ntpdc.1ntpdcmdoc@1.224 +2 -2 + NTP_4_2_7P404 + + ntpdc/ntpdc.html@1.237 +2 -2 + NTP_4_2_7P404 + + ntpdc/ntpdc.man.in@1.224 +13 -13 + NTP_4_2_7P404 + + ntpdc/ntpdc.mdoc.in@1.224 +2 -2 + NTP_4_2_7P404 + + ntpq/invoke-ntpq.texi@1.397 +2 -2 + NTP_4_2_7P404 + + ntpq/ntpq-opts.c@1.411 +7 -7 + NTP_4_2_7P404 + + ntpq/ntpq-opts.h@1.411 +3 -3 + NTP_4_2_7P404 + + ntpq/ntpq.1ntpqman@1.225 +13 -13 + NTP_4_2_7P404 + + ntpq/ntpq.1ntpqmdoc@1.225 +2 -2 + NTP_4_2_7P404 + + ntpq/ntpq.html@1.69 +2 -2 + NTP_4_2_7P404 + + ntpq/ntpq.man.in@1.225 +13 -13 + NTP_4_2_7P404 + + ntpq/ntpq.mdoc.in@1.225 +2 -2 + NTP_4_2_7P404 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.396 +2 -2 + NTP_4_2_7P404 + + ntpsnmpd/ntpsnmpd-opts.c@1.411 +7 -7 + NTP_4_2_7P404 + + ntpsnmpd/ntpsnmpd-opts.h@1.411 +3 -3 + NTP_4_2_7P404 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.225 +7 -7 + NTP_4_2_7P404 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.225 +3 -3 + NTP_4_2_7P404 + + ntpsnmpd/ntpsnmpd.html@1.67 +1 -1 + NTP_4_2_7P404 + + ntpsnmpd/ntpsnmpd.man.in@1.225 +7 -7 + NTP_4_2_7P404 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.225 +3 -3 + NTP_4_2_7P404 + + packageinfo.sh@1.407 +1 -1 + NTP_4_2_7P404 + + scripts/invoke-plot_summary.texi@1.4 +1 -1 + NTP_4_2_7P404 + + scripts/invoke-summary.texi@1.4 +1 -1 + NTP_4_2_7P404 + + scripts/ntp-wait/ntp-wait.html@1.231 +1 -1 + NTP_4_2_7P404 + + scripts/ntpsweep/ntpsweep.html@1.4 +1 -1 + NTP_4_2_7P404 + + scripts/ntptrace/ntptrace.html@1.4 +1 -1 + NTP_4_2_7P404 + + scripts/plot_summary.1plot_summaryman@1.4 +6 -6 + NTP_4_2_7P404 + + scripts/plot_summary.1plot_summarymdoc@1.4 +2 -2 + NTP_4_2_7P404 + + scripts/plot_summary.html@1.4 +1 -1 + NTP_4_2_7P404 + + scripts/plot_summary.man.in@1.4 +6 -6 + NTP_4_2_7P404 + + scripts/plot_summary.mdoc.in@1.4 +2 -2 + NTP_4_2_7P404 + + scripts/summary.1summaryman@1.4 +6 -6 + NTP_4_2_7P404 + + scripts/summary.1summarymdoc@1.4 +2 -2 + NTP_4_2_7P404 + + scripts/summary.html@1.4 +1 -1 + NTP_4_2_7P404 + + scripts/summary.man.in@1.4 +6 -6 + NTP_4_2_7P404 + + scripts/summary.mdoc.in@1.4 +2 -2 + NTP_4_2_7P404 + + sntp/invoke-sntp.texi@1.393 +2 -2 + NTP_4_2_7P404 + + sntp/sntp-opts.c@1.408 +7 -7 + NTP_4_2_7P404 + + sntp/sntp-opts.h@1.408 +3 -3 + NTP_4_2_7P404 + + sntp/sntp.1sntpman@1.228 +7 -7 + NTP_4_2_7P404 + + sntp/sntp.1sntpmdoc@1.228 +3 -3 + NTP_4_2_7P404 + + sntp/sntp.html@1.408 +2 -2 + NTP_4_2_7P404 + + sntp/sntp.man.in@1.228 +7 -7 + NTP_4_2_7P404 + + sntp/sntp.mdoc.in@1.228 +3 -3 + NTP_4_2_7P404 + + util/invoke-ntp-keygen.texi@1.397 +2 -2 + NTP_4_2_7P404 + + util/ntp-keygen-opts.c@1.411 +7 -7 + NTP_4_2_7P404 + + util/ntp-keygen-opts.h@1.411 +3 -3 + NTP_4_2_7P404 + + util/ntp-keygen.1ntp-keygenman@1.225 +7 -7 + NTP_4_2_7P404 + + util/ntp-keygen.1ntp-keygenmdoc@1.225 +3 -3 + NTP_4_2_7P404 + + util/ntp-keygen.html@1.73 +2 -2 + NTP_4_2_7P404 + + util/ntp-keygen.man.in@1.225 +7 -7 + NTP_4_2_7P404 + + util/ntp-keygen.mdoc.in@1.225 +3 -3 + NTP_4_2_7P404 + +ChangeSet@1.3034, 2013-12-24 09:49:09+00:00, stenn@psp-deb1.ntp.org + [Bug 135] AIX5: "Address already in use" for IPv6 wildcard + + ChangeLog@1.1369 +1 -0 + [Bug 135] AIX5: "Address already in use" for IPv6 wildcard + + ntpd/ntp_io.c@1.388 +159 -159 + [Bug 135] AIX5: "Address already in use" for IPv6 wildcard + +ChangeSet@1.3033, 2013-12-23 11:39:23+00:00, stenn@deacon.udel.edu + NTP_4_2_7P403 + TAG: NTP_4_2_7P403 + + ChangeLog@1.1368 +1 -0 + NTP_4_2_7P403 + + ntpd/invoke-ntp.conf.texi@1.81 +1 -1 + NTP_4_2_7P403 + + ntpd/invoke-ntp.keys.texi@1.79 +1 -1 + NTP_4_2_7P403 + + ntpd/invoke-ntpd.texi@1.395 +2 -2 + NTP_4_2_7P403 + + ntpd/ntp.conf.5man@1.115 +7 -7 + NTP_4_2_7P403 + + ntpd/ntp.conf.5mdoc@1.115 +3 -3 + NTP_4_2_7P403 + + ntpd/ntp.conf.html@1.76 +1211 -139 + NTP_4_2_7P403 + + ntpd/ntp.conf.man.in@1.115 +7 -7 + NTP_4_2_7P403 + + ntpd/ntp.conf.mdoc.in@1.115 +3 -3 + NTP_4_2_7P403 + + ntpd/ntp.keys.5man@1.113 +3 -3 + NTP_4_2_7P403 + + ntpd/ntp.keys.5mdoc@1.113 +3 -3 + NTP_4_2_7P403 + + ntpd/ntp.keys.html@1.77 +2 -2 + NTP_4_2_7P403 + + ntpd/ntp.keys.man.in@1.113 +3 -3 + NTP_4_2_7P403 + + ntpd/ntp.keys.mdoc.in@1.113 +3 -3 + NTP_4_2_7P403 + + ntpd/ntpd-opts.c@1.413 +7 -7 + NTP_4_2_7P403 + + ntpd/ntpd-opts.h@1.413 +3 -3 + NTP_4_2_7P403 + + ntpd/ntpd.1ntpdman@1.224 +7 -7 + NTP_4_2_7P403 + + ntpd/ntpd.1ntpdmdoc@1.224 +3 -3 + NTP_4_2_7P403 + + ntpd/ntpd.html@1.71 +3 -3 + NTP_4_2_7P403 + + ntpd/ntpd.man.in@1.224 +7 -7 + NTP_4_2_7P403 + + ntpd/ntpd.mdoc.in@1.224 +3 -3 + NTP_4_2_7P403 + + ntpdc/invoke-ntpdc.texi@1.392 +2 -2 + NTP_4_2_7P403 + + ntpdc/ntpdc-opts.c@1.407 +7 -7 + NTP_4_2_7P403 + + ntpdc/ntpdc-opts.h@1.407 +3 -3 + NTP_4_2_7P403 + + ntpdc/ntpdc.1ntpdcman@1.223 +6 -6 + NTP_4_2_7P403 + + ntpdc/ntpdc.1ntpdcmdoc@1.223 +2 -2 + NTP_4_2_7P403 + + ntpdc/ntpdc.html@1.236 +2 -2 + NTP_4_2_7P403 + + ntpdc/ntpdc.man.in@1.223 +6 -6 + NTP_4_2_7P403 + + ntpdc/ntpdc.mdoc.in@1.223 +2 -2 + NTP_4_2_7P403 + + ntpq/invoke-ntpq.texi@1.396 +2 -2 + NTP_4_2_7P403 + + ntpq/ntpq-opts.c@1.410 +7 -7 + NTP_4_2_7P403 + + ntpq/ntpq-opts.h@1.410 +3 -3 + NTP_4_2_7P403 + + ntpq/ntpq.1ntpqman@1.224 +13 -13 + NTP_4_2_7P403 + + ntpq/ntpq.1ntpqmdoc@1.224 +2 -2 + NTP_4_2_7P403 + + ntpq/ntpq.html@1.68 +30 -57 + NTP_4_2_7P403 + + ntpq/ntpq.man.in@1.224 +13 -13 + NTP_4_2_7P403 + + ntpq/ntpq.mdoc.in@1.224 +2 -2 + NTP_4_2_7P403 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.395 +2 -2 + NTP_4_2_7P403 + + ntpsnmpd/ntpsnmpd-opts.c@1.410 +7 -7 + NTP_4_2_7P403 + + ntpsnmpd/ntpsnmpd-opts.h@1.410 +3 -3 + NTP_4_2_7P403 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.224 +14 -14 + NTP_4_2_7P403 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.224 +3 -3 + NTP_4_2_7P403 + + ntpsnmpd/ntpsnmpd.html@1.66 +1 -1 + NTP_4_2_7P403 + + ntpsnmpd/ntpsnmpd.man.in@1.224 +14 -14 + NTP_4_2_7P403 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.224 +3 -3 + NTP_4_2_7P403 + + packageinfo.sh@1.406 +1 -1 + NTP_4_2_7P403 + + scripts/invoke-plot_summary.texi@1.3 +1 -1 + NTP_4_2_7P403 + + scripts/invoke-summary.texi@1.3 +1 -1 + NTP_4_2_7P403 + + scripts/ntp-wait/ntp-wait.html@1.230 +1 -1 + NTP_4_2_7P403 + + scripts/ntpsweep/ntpsweep.html@1.3 +1 -1 + NTP_4_2_7P403 + + scripts/ntptrace/ntptrace.html@1.3 +1 -1 + NTP_4_2_7P403 + + scripts/plot_summary.1plot_summaryman@1.3 +6 -6 + NTP_4_2_7P403 + + scripts/plot_summary.1plot_summarymdoc@1.3 +3 -3 + NTP_4_2_7P403 + + scripts/plot_summary.html@1.3 +1 -1 + NTP_4_2_7P403 + + scripts/plot_summary.man.in@1.3 +6 -6 + NTP_4_2_7P403 + + scripts/plot_summary.mdoc.in@1.3 +3 -3 + NTP_4_2_7P403 + + scripts/summary.1summaryman@1.3 +6 -6 + NTP_4_2_7P403 + + scripts/summary.1summarymdoc@1.3 +2 -2 + NTP_4_2_7P403 + + scripts/summary.html@1.3 +1 -1 + NTP_4_2_7P403 + + scripts/summary.man.in@1.3 +6 -6 + NTP_4_2_7P403 + + scripts/summary.mdoc.in@1.3 +2 -2 + NTP_4_2_7P403 + + sntp/invoke-sntp.texi@1.392 +2 -2 + NTP_4_2_7P403 + + sntp/sntp-opts.c@1.407 +7 -7 + NTP_4_2_7P403 + + sntp/sntp-opts.h@1.407 +3 -3 + NTP_4_2_7P403 + + sntp/sntp.1sntpman@1.227 +14 -14 + NTP_4_2_7P403 + + sntp/sntp.1sntpmdoc@1.227 +3 -3 + NTP_4_2_7P403 + + sntp/sntp.html@1.407 +2 -2 + NTP_4_2_7P403 + + sntp/sntp.man.in@1.227 +14 -14 + NTP_4_2_7P403 + + sntp/sntp.mdoc.in@1.227 +3 -3 + NTP_4_2_7P403 + + util/invoke-ntp-keygen.texi@1.396 +2 -2 + NTP_4_2_7P403 + + util/ntp-keygen-opts.c@1.410 +7 -7 + NTP_4_2_7P403 + + util/ntp-keygen-opts.h@1.410 +3 -3 + NTP_4_2_7P403 + + util/ntp-keygen.1ntp-keygenman@1.224 +7 -7 + NTP_4_2_7P403 + + util/ntp-keygen.1ntp-keygenmdoc@1.224 +3 -3 + NTP_4_2_7P403 + + util/ntp-keygen.html@1.72 +60 -95 + NTP_4_2_7P403 + + util/ntp-keygen.man.in@1.224 +7 -7 + NTP_4_2_7P403 + + util/ntp-keygen.mdoc.in@1.224 +3 -3 + NTP_4_2_7P403 + +ChangeSet@1.3032, 2013-12-23 03:03:25-05:00, stenn@deacon.udel.edu + [Bug 2513] Remove any PIDFILE in finish() + + ChangeLog@1.1367 +1 -0 + [Bug 2513] Remove any PIDFILE in finish() + + ntpd/ntpd.c@1.151 +4 -0 + [Bug 2513] Remove any PIDFILE in finish() + +ChangeSet@1.3031, 2013-12-23 07:22:20+00:00, stenn@psp-fb1.ntp.org + [Bug 2517] Fix peer status errors in decode.html + + ChangeLog@1.1366 +1 -0 + [Bug 2517] Fix peer status errors in decode.html + + html/decode.html@1.22 +4 -4 + [Bug 2517] Fix peer status errors in decode.html + +ChangeSet@1.3030, 2013-12-23 07:03:41+00:00, stenn@psp-fb1.ntp.org + [Bug 2516] Enable clock_gettime() support for AIX 5+ + + ChangeLog@1.1365 +1 -0 + [Bug 2516] Enable clock_gettime() support for AIX 5+ + + sntp/m4/ntp_libntp.m4@1.23 +7 -2 + [Bug 2516] Enable clock_gettime() support for AIX 5+ + +ChangeSet@1.3029, 2013-12-23 02:44:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P402 + TAG: NTP_4_2_7P402 + + .point-changed-filelist@1.21 +15 -6 + updated point changed list + + ChangeLog@1.1364 +1 -0 + NTP_4_2_7P402 + + ntpd/invoke-ntp.conf.texi@1.80 +117 -230 + NTP_4_2_7P402 + + ntpd/invoke-ntp.keys.texi@1.78 +2 -4 + NTP_4_2_7P402 + + ntpd/invoke-ntpd.texi@1.394 +3 -3 + NTP_4_2_7P402 + + ntpd/ntp.conf.5man@1.114 +985 -953 + NTP_4_2_7P402 + + ntpd/ntp.conf.5mdoc@1.114 +6 -6 + NTP_4_2_7P402 + + ntpd/ntp.conf.html@1.75 +1 -1 + NTP_4_2_7P402 + + ntpd/ntp.conf.man.in@1.114 +985 -953 + NTP_4_2_7P402 + + ntpd/ntp.conf.mdoc.in@1.114 +6 -6 + NTP_4_2_7P402 + + ntpd/ntp.keys.5man@1.112 +93 -47 + NTP_4_2_7P402 + + ntpd/ntp.keys.5mdoc@1.112 +10 -6 + NTP_4_2_7P402 + + ntpd/ntp.keys.html@1.76 +1 -1 + NTP_4_2_7P402 + + ntpd/ntp.keys.man.in@1.112 +93 -47 + NTP_4_2_7P402 + + ntpd/ntp.keys.mdoc.in@1.112 +10 -6 + NTP_4_2_7P402 + + ntpd/ntpd-opts.c@1.412 +7 -7 + NTP_4_2_7P402 + + ntpd/ntpd-opts.h@1.412 +3 -3 + NTP_4_2_7P402 + + ntpd/ntpd.1ntpdman@1.223 +282 -209 + NTP_4_2_7P402 + + ntpd/ntpd.1ntpdmdoc@1.223 +42 -42 + NTP_4_2_7P402 + + ntpd/ntpd.html@1.70 +2 -2 + NTP_4_2_7P402 + + ntpd/ntpd.man.in@1.223 +282 -209 + NTP_4_2_7P402 + + ntpd/ntpd.mdoc.in@1.223 +42 -42 + NTP_4_2_7P402 + + ntpdc/invoke-ntpdc.texi@1.391 +3 -3 + NTP_4_2_7P402 + + ntpdc/ntpdc-opts.c@1.406 +7 -7 + NTP_4_2_7P402 + + ntpdc/ntpdc-opts.h@1.406 +3 -3 + NTP_4_2_7P402 + + ntpdc/ntpdc.1ntpdcman@1.222 +306 -289 + NTP_4_2_7P402 + + ntpdc/ntpdc.1ntpdcmdoc@1.222 +19 -19 + NTP_4_2_7P402 + + ntpdc/ntpdc.html@1.235 +3 -3 + NTP_4_2_7P402 + + ntpdc/ntpdc.man.in@1.222 +306 -289 + NTP_4_2_7P402 + + ntpdc/ntpdc.mdoc.in@1.222 +19 -19 + NTP_4_2_7P402 + + ntpq/invoke-ntpq.texi@1.395 +24 -36 + NTP_4_2_7P402 + + ntpq/ntpq-opts.c@1.409 +7 -7 + NTP_4_2_7P402 + + ntpq/ntpq-opts.h@1.409 +3 -3 + NTP_4_2_7P402 + + ntpq/ntpq.1ntpqman@1.223 +165 -117 + NTP_4_2_7P402 + + ntpq/ntpq.1ntpqmdoc@1.223 +18 -18 + NTP_4_2_7P402 + + ntpq/ntpq.html@1.67 +2 -2 + NTP_4_2_7P402 + + ntpq/ntpq.man.in@1.223 +165 -117 + NTP_4_2_7P402 + + ntpq/ntpq.mdoc.in@1.223 +18 -18 + NTP_4_2_7P402 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.394 +2 -2 + NTP_4_2_7P402 + + ntpsnmpd/ntpsnmpd-opts.c@1.409 +7 -7 + NTP_4_2_7P402 + + ntpsnmpd/ntpsnmpd-opts.h@1.409 +3 -3 + NTP_4_2_7P402 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.223 +126 -66 + NTP_4_2_7P402 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.223 +16 -14 + NTP_4_2_7P402 + + ntpsnmpd/ntpsnmpd.html@1.65 +1 -1 + NTP_4_2_7P402 + + ntpsnmpd/ntpsnmpd.man.in@1.223 +126 -66 + NTP_4_2_7P402 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.223 +16 -14 + NTP_4_2_7P402 + + packageinfo.sh@1.405 +1 -1 + NTP_4_2_7P402 + + scripts/invoke-plot_summary.texi@1.2 +1 -1 + NTP_4_2_7P402 + + scripts/invoke-summary.texi@1.2 +1 -1 + NTP_4_2_7P402 + + scripts/ntp-wait/ntp-wait.html@1.229 +30 -48 + NTP_4_2_7P402 + + scripts/ntpsweep/Makefile.am@1.4 +3 -0 + cleanup + + scripts/ntpsweep/ntpsweep.html@1.2 +32 -43 + NTP_4_2_7P402 + + scripts/ntptrace/ntptrace.html@1.2 +26 -35 + NTP_4_2_7P402 + + scripts/plot_summary.1plot_summaryman@1.2 +32 -2 + NTP_4_2_7P402 + + scripts/plot_summary.1plot_summarymdoc@1.2 +22 -2 + NTP_4_2_7P402 + + scripts/plot_summary.html@1.2 +28 -46 + NTP_4_2_7P402 + + scripts/plot_summary.man.in@1.2 +32 -2 + NTP_4_2_7P402 + + scripts/plot_summary.mdoc.in@1.2 +22 -2 + NTP_4_2_7P402 + + scripts/summary.1summaryman@1.2 +31 -2 + NTP_4_2_7P402 + + scripts/summary.1summarymdoc@1.2 +21 -2 + NTP_4_2_7P402 + + scripts/summary.html@1.2 +26 -38 + NTP_4_2_7P402 + + scripts/summary.man.in@1.2 +31 -2 + NTP_4_2_7P402 + + scripts/summary.mdoc.in@1.2 +21 -2 + NTP_4_2_7P402 + + sntp/invoke-sntp.texi@1.391 +7 -7 + NTP_4_2_7P402 + + sntp/sntp-opts.c@1.406 +7 -7 + NTP_4_2_7P402 + + sntp/sntp-opts.h@1.406 +3 -3 + NTP_4_2_7P402 + + sntp/sntp.1sntpman@1.226 +119 -70 + NTP_4_2_7P402 + + sntp/sntp.1sntpmdoc@1.226 +46 -34 + NTP_4_2_7P402 + + sntp/sntp.html@1.406 +7 -7 + NTP_4_2_7P402 + + sntp/sntp.man.in@1.226 +119 -70 + NTP_4_2_7P402 + + sntp/sntp.mdoc.in@1.226 +46 -34 + NTP_4_2_7P402 + + util/invoke-ntp-keygen.texi@1.395 +28 -50 + NTP_4_2_7P402 + + util/ntp-keygen-opts.c@1.409 +7 -7 + NTP_4_2_7P402 + + util/ntp-keygen-opts.h@1.409 +3 -3 + NTP_4_2_7P402 + + util/ntp-keygen.1ntp-keygenman@1.223 +397 -270 + NTP_4_2_7P402 + + util/ntp-keygen.1ntp-keygenmdoc@1.223 +37 -33 + NTP_4_2_7P402 + + util/ntp-keygen.html@1.71 +2 -2 + NTP_4_2_7P402 + + util/ntp-keygen.man.in@1.223 +397 -270 + NTP_4_2_7P402 + + util/ntp-keygen.mdoc.in@1.223 +37 -33 + NTP_4_2_7P402 + +ChangeSet@1.3028, 2013-12-22 10:28:11+00:00, stenn@psp-fb1.ntp.org + Create doc framework for summary and plot_summary + + scripts/Makefile.am@1.35 +120 -9 + Create doc framework for summary and plot_summary + + scripts/invoke-plot_summary.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/invoke-plot_summary.menu + + scripts/invoke-plot_summary.menu@1.0 +0 -0 + + scripts/invoke-plot_summary.texi@1.1 +121 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/invoke-plot_summary.texi + + scripts/invoke-plot_summary.texi@1.0 +0 -0 + + scripts/invoke-summary.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/invoke-summary.menu + + scripts/invoke-summary.menu@1.0 +0 -0 + + scripts/invoke-summary.texi@1.1 +103 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/invoke-summary.texi + + scripts/invoke-summary.texi@1.0 +0 -0 + + scripts/ntptrace/Makefile.am@1.4 +2 -2 + fix typos in ntptrace/Makefile.am + + scripts/plot_summary.1plot_summaryman@1.1 +109 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary.1plot_summaryman + + scripts/plot_summary.1plot_summaryman@1.0 +0 -0 + + scripts/plot_summary.1plot_summarymdoc@1.1 +84 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary.1plot_summarymdoc + + scripts/plot_summary.1plot_summarymdoc@1.0 +0 -0 + + scripts/plot_summary.html@1.1 +225 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary.html + + scripts/plot_summary.html@1.0 +0 -0 + + scripts/plot_summary.man.in@1.1 +109 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary.man.in + + scripts/plot_summary.man.in@1.0 +0 -0 + + scripts/plot_summary.mdoc.in@1.1 +84 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary.mdoc.in + + scripts/plot_summary.mdoc.in@1.0 +0 -0 + + scripts/plot_summary.texi@1.1 +40 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary.texi + + scripts/plot_summary.texi@1.0 +0 -0 + + scripts/summary.1summaryman@1.1 +118 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary.1summaryman + + scripts/summary.1summaryman@1.0 +0 -0 + + scripts/summary.1summarymdoc@1.1 +94 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary.1summarymdoc + + scripts/summary.1summarymdoc@1.0 +0 -0 + + scripts/summary.html@1.1 +194 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary.html + + scripts/summary.html@1.0 +0 -0 + + scripts/summary.man.in@1.1 +118 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary.man.in + + scripts/summary.man.in@1.0 +0 -0 + + scripts/summary.mdoc.in@1.1 +94 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary.mdoc.in + + scripts/summary.mdoc.in@1.0 +0 -0 + + scripts/summary.texi@1.1 +40 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary.texi + + scripts/summary.texi@1.0 +0 -0 + +ChangeSet@1.3027, 2013-12-21 10:12:36+00:00, stenn@psp-fb1.ntp.org + More build cleanup around Oliver's GSoC project + + scripts/Makefile.am@1.34 +4 -0 + More build cleanup around Oliver's GSoC project + + scripts/calc_tickadj/Makefile.am@1.5 +11 -8 + More build cleanup around Oliver's GSoC project + + scripts/calc_tickadj/calc_tickadj.man.in@1.1 +103 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj.man.in + + scripts/calc_tickadj/calc_tickadj.man.in@1.0 +0 -0 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.3 +1 -1 + More build cleanup around Oliver's GSoC project + + scripts/lib/Makefile.am@1.2 +1 -1 + More build cleanup around Oliver's GSoC project + + scripts/ntp-wait/Makefile.am@1.3 +24 -27 + More build cleanup around Oliver's GSoC project + + scripts/ntp-wait/invoke-ntp-wait.texi@1.214 +1 -1 + More build cleanup around Oliver's GSoC project + + scripts/ntpsweep/Makefile.am@1.3 +34 -36 + More build cleanup around Oliver's GSoC project + + scripts/ntpsweep/invoke-ntpsweep.texi@1.3 +1 -1 + More build cleanup around Oliver's GSoC project + + scripts/ntpsweep/ntpsweep.man.in@1.1 +92 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep.man.in + + scripts/ntpsweep/ntpsweep.man.in@1.0 +0 -0 + + scripts/ntptrace/Makefile.am@1.3 +26 -27 + More build cleanup around Oliver's GSoC project + + scripts/ntptrace/invoke-ntptrace.texi@1.3 +1 -1 + More build cleanup around Oliver's GSoC project + + scripts/ntptrace/ntptrace.man.in@1.1 +109 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace.man.in + + scripts/ntptrace/ntptrace.man.in@1.0 +0 -0 + +ChangeSet@1.3026, 2013-12-19 11:47:46+00:00, stenn@psp-fb1.ntp.org + calc_tickadj man page generation fixes + + scripts/calc_tickadj/Makefile.am@1.4 +2 -1 + calc_tickadj man page generation fixes + + sntp/m4/ntp_locinfo.m4@1.16 +2 -0 + calc_tickadj man page generation fixes + +ChangeSet@1.3025, 2013-12-19 09:27:41+00:00, stenn@psp-fb1.ntp.org + cleanup + + scripts/calc_tickadj/Makefile.am@1.3 +26 -21 + cleanup + +ChangeSet@1.3024, 2013-12-19 07:56:15+00:00, stenn@psp-fb1.ntp.org + automake cleanup for Oliver's work + + configure.ac@1.570 +4 -0 + automake cleanup for Oliver's work + + scripts/Makefile.am@1.33 +8 -2 + automake cleanup for Oliver's work + + scripts/calc_tickadj/Makefile.am@1.2 +8 -7 + automake cleanup for Oliver's work + + scripts/calc_tickadj/calc_tickadj.texi@1.2 +1 -1 + automake cleanup for Oliver's work + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.2 +1 -1 + automake cleanup for Oliver's work + + scripts/ntp-wait/Makefile.am@1.2 +27 -26 + automake cleanup for Oliver's work + + scripts/ntp-wait/invoke-ntp-wait.texi@1.213 +1 -1 + automake cleanup for Oliver's work + + scripts/ntp-wait/ntp-wait.in@1.11 +0 -1 + automake cleanup for Oliver's work + + scripts/ntpsweep/Makefile.am@1.2 +23 -22 + automake cleanup for Oliver's work + + scripts/ntpsweep/invoke-ntpsweep.texi@1.2 +1 -1 + automake cleanup for Oliver's work + + scripts/ntpsweep/ntpsweep.in@1.8 +0 -1 + automake cleanup for Oliver's work + + scripts/ntptrace/Makefile.am@1.2 +5 -7 + automake cleanup for Oliver's work + + scripts/ntptrace/invoke-ntptrace.texi@1.2 +1 -1 + automake cleanup for Oliver's work + + scripts/ntptrace/ntptrace.in@1.12 +0 -1 + automake cleanup for Oliver's work + + sntp/loc/debian@1.2 +1 -0 + automake cleanup for Oliver's work + + sntp/loc/legacy@1.5 +1 -0 + automake cleanup for Oliver's work + + sntp/loc/redhat@1.3 +1 -0 + automake cleanup for Oliver's work + + sntp/loc/solaris@1.4 +1 -0 + automake cleanup for Oliver's work + + sntp/m4/ntp_locinfo.m4@1.15 +4 -0 + automake cleanup for Oliver's work + +ChangeSet@1.3023, 2013-12-18 11:09:54+00:00, stenn@psp-fb1.ntp.org + updates + + configure.ac@1.569 +6 -6 + fix *_opts variables + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.1 +103 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj.1calc_tickadjman + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjman@1.0 +0 -0 + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.1 +80 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc + + scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc@1.0 +0 -0 + + scripts/calc_tickadj/calc_tickadj.html@1.1 +178 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj.html + + scripts/calc_tickadj/calc_tickadj.html@1.0 +0 -0 + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.1 +80 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj.mdoc.in + + scripts/calc_tickadj/calc_tickadj.mdoc.in@1.0 +0 -0 + + scripts/calc_tickadj/invoke-calc_tickadj.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/invoke-calc_tickadj.menu + + scripts/calc_tickadj/invoke-calc_tickadj.menu@1.0 +0 -0 + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.1 +102 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/invoke-calc_tickadj.texi + + scripts/calc_tickadj/invoke-calc_tickadj.texi@1.0 +0 -0 + + scripts/ntp-wait/invoke-ntp-wait.texi@1.212 +32 -64 + updates + + scripts/ntp-wait/ntp-wait.html@1.228 +85 -117 + updates + + scripts/ntp-wait/ntp-wait.in@1.10 +2 -0 + updates + + scripts/ntpsweep/invoke-ntpsweep.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/invoke-ntpsweep.menu + + scripts/ntpsweep/invoke-ntpsweep.menu@1.0 +0 -0 + + scripts/ntpsweep/invoke-ntpsweep.texi@1.1 +118 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/invoke-ntpsweep.texi + + scripts/ntpsweep/invoke-ntpsweep.texi@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.1 +92 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep.1ntpsweepman + + scripts/ntpsweep/ntpsweep.1ntpsweepman@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.1 +71 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep.1ntpsweepmdoc + + scripts/ntpsweep/ntpsweep.1ntpsweepmdoc@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep.html@1.1 +212 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep.html + + scripts/ntpsweep/ntpsweep.html@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep.in@1.7 +2 -0 + updates + + scripts/ntpsweep/ntpsweep.mdoc.in@1.2 +2 -2 + updates + + scripts/ntptrace/invoke-ntptrace.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/invoke-ntptrace.menu + + scripts/ntptrace/invoke-ntptrace.menu@1.0 +0 -0 + + scripts/ntptrace/invoke-ntptrace.texi@1.1 +109 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/invoke-ntptrace.texi + + scripts/ntptrace/invoke-ntptrace.texi@1.0 +0 -0 + + scripts/ntptrace/ntptrace.1ntptraceman@1.1 +109 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace.1ntptraceman + + scripts/ntptrace/ntptrace.1ntptraceman@1.0 +0 -0 + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.1 +87 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace.1ntptracemdoc + + scripts/ntptrace/ntptrace.1ntptracemdoc@1.0 +0 -0 + + scripts/ntptrace/ntptrace.html@1.1 +189 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace.html + + scripts/ntptrace/ntptrace.html@1.0 +0 -0 + + scripts/ntptrace/ntptrace.in@1.11 +2 -0 + updates + + scripts/ntptrace/ntptrace.mdoc.in@1.2 +2 -2 + updates + +ChangeSet@1.3020.1.5, 2013-11-30 11:34:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P401 + TAG: NTP_4_2_7P401 + + ChangeLog@1.1361.1.4 +1 -0 + NTP_4_2_7P401 + + ntpd/invoke-ntp.conf.texi@1.79 +1 -1 + NTP_4_2_7P401 + + ntpd/invoke-ntp.keys.texi@1.77 +1 -1 + NTP_4_2_7P401 + + ntpd/invoke-ntpd.texi@1.393 +2 -2 + NTP_4_2_7P401 + + ntpd/ntp.conf.5man@1.113 +3 -3 + NTP_4_2_7P401 + + ntpd/ntp.conf.5mdoc@1.113 +3 -3 + NTP_4_2_7P401 + + ntpd/ntp.conf.html@1.74 +1 -1 + NTP_4_2_7P401 + + ntpd/ntp.conf.man.in@1.113 +3 -3 + NTP_4_2_7P401 + + ntpd/ntp.conf.mdoc.in@1.113 +3 -3 + NTP_4_2_7P401 + + ntpd/ntp.keys.5man@1.111 +3 -3 + NTP_4_2_7P401 + + ntpd/ntp.keys.5mdoc@1.111 +3 -3 + NTP_4_2_7P401 + + ntpd/ntp.keys.html@1.75 +1 -1 + NTP_4_2_7P401 + + ntpd/ntp.keys.man.in@1.111 +3 -3 + NTP_4_2_7P401 + + ntpd/ntp.keys.mdoc.in@1.111 +3 -3 + NTP_4_2_7P401 + + ntpd/ntpd-opts.c@1.411 +7 -7 + NTP_4_2_7P401 + + ntpd/ntpd-opts.h@1.411 +3 -3 + NTP_4_2_7P401 + + ntpd/ntpd.1ntpdman@1.222 +3 -3 + NTP_4_2_7P401 + + ntpd/ntpd.1ntpdmdoc@1.222 +3 -3 + NTP_4_2_7P401 + + ntpd/ntpd.html@1.69 +2 -2 + NTP_4_2_7P401 + + ntpd/ntpd.man.in@1.222 +3 -3 + NTP_4_2_7P401 + + ntpd/ntpd.mdoc.in@1.222 +3 -3 + NTP_4_2_7P401 + + ntpdc/invoke-ntpdc.texi@1.390 +2 -2 + NTP_4_2_7P401 + + ntpdc/ntpdc-opts.c@1.405 +7 -7 + NTP_4_2_7P401 + + ntpdc/ntpdc-opts.h@1.405 +3 -3 + NTP_4_2_7P401 + + ntpdc/ntpdc.1ntpdcman@1.221 +2 -2 + NTP_4_2_7P401 + + ntpdc/ntpdc.1ntpdcmdoc@1.221 +2 -2 + NTP_4_2_7P401 + + ntpdc/ntpdc.html@1.234 +2 -2 + NTP_4_2_7P401 + + ntpdc/ntpdc.man.in@1.221 +2 -2 + NTP_4_2_7P401 + + ntpdc/ntpdc.mdoc.in@1.221 +2 -2 + NTP_4_2_7P401 + + ntpq/invoke-ntpq.texi@1.394 +2 -2 + NTP_4_2_7P401 + + ntpq/ntpq-opts.c@1.408 +7 -7 + NTP_4_2_7P401 + + ntpq/ntpq-opts.h@1.408 +3 -3 + NTP_4_2_7P401 + + ntpq/ntpq.1ntpqman@1.222 +2 -2 + NTP_4_2_7P401 + + ntpq/ntpq.1ntpqmdoc@1.222 +2 -2 + NTP_4_2_7P401 + + ntpq/ntpq.html@1.66 +2 -2 + NTP_4_2_7P401 + + ntpq/ntpq.man.in@1.222 +2 -2 + NTP_4_2_7P401 + + ntpq/ntpq.mdoc.in@1.222 +2 -2 + NTP_4_2_7P401 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.393 +2 -2 + NTP_4_2_7P401 + + ntpsnmpd/ntpsnmpd-opts.c@1.408 +7 -7 + NTP_4_2_7P401 + + ntpsnmpd/ntpsnmpd-opts.h@1.408 +3 -3 + NTP_4_2_7P401 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.222 +3 -3 + NTP_4_2_7P401 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.222 +3 -3 + NTP_4_2_7P401 + + ntpsnmpd/ntpsnmpd.html@1.64 +1 -1 + NTP_4_2_7P401 + + ntpsnmpd/ntpsnmpd.man.in@1.222 +3 -3 + NTP_4_2_7P401 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.222 +3 -3 + NTP_4_2_7P401 + + packageinfo.sh@1.404 +1 -1 + NTP_4_2_7P401 + + scripts/invoke-ntp-wait.texi@1.208.1.2 +1 -1 + NTP_4_2_7P401 + + scripts/ntp-wait.1ntp-waitman@1.219.1.2 +3 -3 + NTP_4_2_7P401 + + scripts/ntp-wait.1ntp-waitmdoc@1.219.1.2 +3 -3 + NTP_4_2_7P401 + + scripts/ntp-wait.html@1.224.1.2 +1 -1 + NTP_4_2_7P401 + + scripts/ntp-wait.man.in@1.219.1.2 +3 -3 + NTP_4_2_7P401 + + scripts/ntp-wait.mdoc.in@1.219.1.2 +3 -3 + NTP_4_2_7P401 + + sntp/invoke-sntp.texi@1.390 +2 -2 + NTP_4_2_7P401 + + sntp/sntp-opts.c@1.405 +7 -7 + NTP_4_2_7P401 + + sntp/sntp-opts.h@1.405 +3 -3 + NTP_4_2_7P401 + + sntp/sntp.1sntpman@1.225 +3 -3 + NTP_4_2_7P401 + + sntp/sntp.1sntpmdoc@1.225 +3 -3 + NTP_4_2_7P401 + + sntp/sntp.html@1.405 +2 -2 + NTP_4_2_7P401 + + sntp/sntp.man.in@1.225 +3 -3 + NTP_4_2_7P401 + + sntp/sntp.mdoc.in@1.225 +3 -3 + NTP_4_2_7P401 + + util/invoke-ntp-keygen.texi@1.394 +2 -2 + NTP_4_2_7P401 + + util/ntp-keygen-opts.c@1.408 +7 -7 + NTP_4_2_7P401 + + util/ntp-keygen-opts.h@1.408 +3 -3 + NTP_4_2_7P401 + + util/ntp-keygen.1ntp-keygenman@1.222 +3 -3 + NTP_4_2_7P401 + + util/ntp-keygen.1ntp-keygenmdoc@1.222 +3 -3 + NTP_4_2_7P401 + + util/ntp-keygen.html@1.70 +2 -2 + NTP_4_2_7P401 + + util/ntp-keygen.man.in@1.222 +3 -3 + NTP_4_2_7P401 + + util/ntp-keygen.mdoc.in@1.222 +3 -3 + NTP_4_2_7P401 + +ChangeSet@1.3020.1.4, 2013-11-30 03:56:11-05:00, stenn@deacon.udel.edu + [Bug 2491] VS20xx compile fixes + + ChangeLog@1.1361.1.3 +1 -0 + [Bug 2491] VS20xx compile fixes + + ports/winnt/include/config.h@1.107 +12 -3 + [Bug 2491] VS20xx compile fixes + + ports/winnt/include/stdint.h@1.2 +2 -2 + [Bug 2491] VS20xx compile fixes + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.2 +4 -4 + [Bug 2491] VS20xx compile fixes + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj@1.2 +4 -4 + [Bug 2491] VS20xx compile fixes + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj@1.2 +4 -4 + [Bug 2491] VS20xx compile fixes + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.2 +4 -4 + [Bug 2491] VS20xx compile fixes + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj@1.2 +4 -4 + [Bug 2491] VS20xx compile fixes + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj@1.2 +4 -4 + [Bug 2491] VS20xx compile fixes + + ports/winnt/vs2013/ntpq/ntpq.vcxproj@1.2 +4 -4 + [Bug 2491] VS20xx compile fixes + +ChangeSet@1.3020.1.3, 2013-11-29 11:36:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P400 + TAG: NTP_4_2_7P400 + + ChangeLog@1.1361.1.2 +1 -0 + NTP_4_2_7P400 + + ntpd/invoke-ntp.conf.texi@1.78 +1 -1 + NTP_4_2_7P400 + + ntpd/invoke-ntp.keys.texi@1.76 +1 -1 + NTP_4_2_7P400 + + ntpd/invoke-ntpd.texi@1.392 +2 -2 + NTP_4_2_7P400 + + ntpd/ntp.conf.5man@1.112 +3 -3 + NTP_4_2_7P400 + + ntpd/ntp.conf.5mdoc@1.112 +3 -3 + NTP_4_2_7P400 + + ntpd/ntp.conf.html@1.73 +1 -1 + NTP_4_2_7P400 + + ntpd/ntp.conf.man.in@1.112 +3 -3 + NTP_4_2_7P400 + + ntpd/ntp.conf.mdoc.in@1.112 +3 -3 + NTP_4_2_7P400 + + ntpd/ntp.keys.5man@1.110 +3 -3 + NTP_4_2_7P400 + + ntpd/ntp.keys.5mdoc@1.110 +3 -3 + NTP_4_2_7P400 + + ntpd/ntp.keys.html@1.74 +1 -1 + NTP_4_2_7P400 + + ntpd/ntp.keys.man.in@1.110 +3 -3 + NTP_4_2_7P400 + + ntpd/ntp.keys.mdoc.in@1.110 +3 -3 + NTP_4_2_7P400 + + ntpd/ntpd-opts.c@1.410 +7 -7 + NTP_4_2_7P400 + + ntpd/ntpd-opts.h@1.410 +3 -3 + NTP_4_2_7P400 + + ntpd/ntpd.1ntpdman@1.221 +3 -3 + NTP_4_2_7P400 + + ntpd/ntpd.1ntpdmdoc@1.221 +3 -3 + NTP_4_2_7P400 + + ntpd/ntpd.html@1.68 +2 -2 + NTP_4_2_7P400 + + ntpd/ntpd.man.in@1.221 +3 -3 + NTP_4_2_7P400 + + ntpd/ntpd.mdoc.in@1.221 +3 -3 + NTP_4_2_7P400 + + ntpdc/invoke-ntpdc.texi@1.389 +2 -2 + NTP_4_2_7P400 + + ntpdc/ntpdc-opts.c@1.404 +7 -7 + NTP_4_2_7P400 + + ntpdc/ntpdc-opts.h@1.404 +3 -3 + NTP_4_2_7P400 + + ntpdc/ntpdc.1ntpdcman@1.220 +2 -2 + NTP_4_2_7P400 + + ntpdc/ntpdc.1ntpdcmdoc@1.220 +2 -2 + NTP_4_2_7P400 + + ntpdc/ntpdc.html@1.233 +2 -2 + NTP_4_2_7P400 + + ntpdc/ntpdc.man.in@1.220 +2 -2 + NTP_4_2_7P400 + + ntpdc/ntpdc.mdoc.in@1.220 +2 -2 + NTP_4_2_7P400 + + ntpq/invoke-ntpq.texi@1.393 +2 -2 + NTP_4_2_7P400 + + ntpq/ntpq-opts.c@1.407 +7 -7 + NTP_4_2_7P400 + + ntpq/ntpq-opts.h@1.407 +3 -3 + NTP_4_2_7P400 + + ntpq/ntpq.1ntpqman@1.221 +2 -2 + NTP_4_2_7P400 + + ntpq/ntpq.1ntpqmdoc@1.221 +2 -2 + NTP_4_2_7P400 + + ntpq/ntpq.html@1.65 +2 -2 + NTP_4_2_7P400 + + ntpq/ntpq.man.in@1.221 +2 -2 + NTP_4_2_7P400 + + ntpq/ntpq.mdoc.in@1.221 +2 -2 + NTP_4_2_7P400 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.392 +2 -2 + NTP_4_2_7P400 + + ntpsnmpd/ntpsnmpd-opts.c@1.407 +7 -7 + NTP_4_2_7P400 + + ntpsnmpd/ntpsnmpd-opts.h@1.407 +3 -3 + NTP_4_2_7P400 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.221 +3 -3 + NTP_4_2_7P400 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.221 +3 -3 + NTP_4_2_7P400 + + ntpsnmpd/ntpsnmpd.html@1.63 +1 -1 + NTP_4_2_7P400 + + ntpsnmpd/ntpsnmpd.man.in@1.221 +3 -3 + NTP_4_2_7P400 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.221 +3 -3 + NTP_4_2_7P400 + + packageinfo.sh@1.403 +1 -1 + NTP_4_2_7P400 + + scripts/invoke-ntp-wait.texi@1.208.1.1 +1 -1 + NTP_4_2_7P400 + + scripts/ntp-wait.1ntp-waitman@1.219.1.1 +3 -3 + NTP_4_2_7P400 + + scripts/ntp-wait.1ntp-waitmdoc@1.219.1.1 +3 -3 + NTP_4_2_7P400 + + scripts/ntp-wait.html@1.224.1.1 +1 -1 + NTP_4_2_7P400 + + scripts/ntp-wait.man.in@1.219.1.1 +3 -3 + NTP_4_2_7P400 + + scripts/ntp-wait.mdoc.in@1.219.1.1 +3 -3 + NTP_4_2_7P400 + + sntp/invoke-sntp.texi@1.389 +2 -2 + NTP_4_2_7P400 + + sntp/sntp-opts.c@1.404 +7 -7 + NTP_4_2_7P400 + + sntp/sntp-opts.h@1.404 +3 -3 + NTP_4_2_7P400 + + sntp/sntp.1sntpman@1.224 +3 -3 + NTP_4_2_7P400 + + sntp/sntp.1sntpmdoc@1.224 +3 -3 + NTP_4_2_7P400 + + sntp/sntp.html@1.404 +2 -2 + NTP_4_2_7P400 + + sntp/sntp.man.in@1.224 +3 -3 + NTP_4_2_7P400 + + sntp/sntp.mdoc.in@1.224 +3 -3 + NTP_4_2_7P400 + + util/invoke-ntp-keygen.texi@1.393 +2 -2 + NTP_4_2_7P400 + + util/ntp-keygen-opts.c@1.407 +7 -7 + NTP_4_2_7P400 + + util/ntp-keygen-opts.h@1.407 +3 -3 + NTP_4_2_7P400 + + util/ntp-keygen.1ntp-keygenman@1.221 +3 -3 + NTP_4_2_7P400 + + util/ntp-keygen.1ntp-keygenmdoc@1.221 +3 -3 + NTP_4_2_7P400 + + util/ntp-keygen.html@1.69 +2 -2 + NTP_4_2_7P400 + + util/ntp-keygen.man.in@1.221 +3 -3 + NTP_4_2_7P400 + + util/ntp-keygen.mdoc.in@1.221 +3 -3 + NTP_4_2_7P400 + +ChangeSet@1.3020.1.2, 2013-11-29 05:40:01-05:00, stenn@deacon.udel.edu + [Bug 2491] VS2013 project files + + ports/winnt/include/config.h@1.106 +5 -1 + [Bug 2491] VS2013 project files + +ChangeSet@1.3020.1.1, 2013-11-29 05:34:11-05:00, stenn@deacon.udel.edu + [Bug 2491] VS2013 project files + + ChangeLog@1.1361.1.1 +1 -0 + [Bug 2491] VS2013 project files + + ports/winnt/vs2013/instsrv/instsrv.vcproj@1.1 +258 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/instsrv/instsrv.vcproj + + ports/winnt/vs2013/instsrv/instsrv.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/instsrv/instsrv.vcxproj@1.1 +311 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/instsrv/instsrv.vcxproj + + ports/winnt/vs2013/instsrv/instsrv.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/instsrv/instsrv.vcxproj.filters@1.1 +22 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/instsrv/instsrv.vcxproj.filters + + ports/winnt/vs2013/instsrv/instsrv.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/libntp/libntp.vcproj@1.1 +936 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/libntp/libntp.vcproj + + ports/winnt/vs2013/libntp/libntp.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.1 +443 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/libntp/libntp.vcxproj + + ports/winnt/vs2013/libntp/libntp.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/libntp/libntp.vcxproj.filters@1.1 +556 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/libntp/libntp.vcxproj.filters + + ports/winnt/vs2013/libntp/libntp.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcproj@1.1 +256 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcproj + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj@1.1 +276 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj.filters@1.1 +36 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj.filters + + ports/winnt/vs2013/loopback-pps/loopback-ppsapi-provider.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcproj@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcproj + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj.filters@1.1 +36 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj.filters + + ports/winnt/vs2013/ntp-keygen/ntp-keygen.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/ntp.sln@1.1 +108 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntp.sln + + ports/winnt/vs2013/ntp.sln@1.0 +0 -0 + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcproj@1.1 +273 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcproj + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj.filters@1.1 +69 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj.filters + + ports/winnt/vs2013/ntpd-keyword-gen/ntpd-keyword-gen.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/ntpd/gen-ntp_keyword.bat@1.1 +39 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpd/gen-ntp_keyword.bat + + ports/winnt/vs2013/ntpd/gen-ntp_keyword.bat@1.0 +0 -0 + + ports/winnt/vs2013/ntpd/ntpd.vcproj@1.1 +1126 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpd/ntpd.vcproj + + ports/winnt/vs2013/ntpd/ntpd.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.1 +594 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpd/ntpd.vcxproj + + ports/winnt/vs2013/ntpd/ntpd.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpd/ntpd.vcxproj.filters@1.1 +559 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpd/ntpd.vcxproj.filters + + ports/winnt/vs2013/ntpd/ntpd.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/ntpdate/ntpdate.vcproj@1.1 +362 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpdate/ntpdate.vcproj + + ports/winnt/vs2013/ntpdate/ntpdate.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj@1.1 +360 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpdate/ntpdate.vcxproj + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj.filters@1.1 +72 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpdate/ntpdate.vcxproj.filters + + ports/winnt/vs2013/ntpdate/ntpdate.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/ntpdc/ntpdc.vcproj@1.1 +367 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpdc/ntpdc.vcproj + + ports/winnt/vs2013/ntpdc/ntpdc.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj@1.1 +365 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpdc/ntpdc.vcxproj + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj.filters@1.1 +45 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpdc/ntpdc.vcxproj.filters + + ports/winnt/vs2013/ntpdc/ntpdc.vcxproj.filters@1.0 +0 -0 + + ports/winnt/vs2013/ntpq/ntpq.vcproj@1.1 +357 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpq/ntpq.vcproj + + ports/winnt/vs2013/ntpq/ntpq.vcproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpq/ntpq.vcxproj@1.1 +349 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpq/ntpq.vcxproj + + ports/winnt/vs2013/ntpq/ntpq.vcxproj@1.0 +0 -0 + + ports/winnt/vs2013/ntpq/ntpq.vcxproj.filters@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/ports/winnt/vs2013/ntpq/ntpq.vcxproj.filters + + ports/winnt/vs2013/ntpq/ntpq.vcxproj.filters@1.0 +0 -0 + +ChangeSet@1.2991.2.1, 2013-11-29 06:12:37+00:00, stenn@psp-fb1.ntp.org + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + BitKeeper/deleted/21/checktime.in~d65a0b68@1.3 +0 -0 + Delete: scripts/checktime.in + + ChangeLog@1.1338.2.1 +1 -0 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + Makefile.am@1.117 +3 -3 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + bootstrap@1.42 +2 -1 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + configure.ac@1.562.2.1 +27 -8 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + ntpd/Makefile.am@1.127.1.1 +2 -2 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + ntpdate/Makefile.am@1.37 +1 -1 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + ntpdc/Makefile.am@1.74 +2 -2 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + ntpq/Makefile.am@1.70 +2 -2 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + ntpsnmpd/Makefile.am@1.39 +1 -1 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/Makefile.am@1.32 +13 -74 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/README@1.9 +7 -19 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/build/Makefile.am@1.1 +13 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/build/Makefile.am + + scripts/build/Makefile.am@1.0 +0 -0 + + scripts/build/UpdatePoint@1.6 +3 -3 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/build/UpdatePoint@1.5 +0 -0 + Rename: scripts/UpdatePoint -> scripts/build/UpdatePoint + + scripts/build/VersionName@1.7 +0 -0 + Rename: scripts/VersionName -> scripts/build/VersionName + + scripts/build/addChangeLogTag@1.5 +1 -1 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/build/addChangeLogTag@1.4 +0 -0 + Rename: scripts/addChangeLogTag -> scripts/build/addChangeLogTag + + scripts/build/check--help@1.3 +0 -0 + Rename: scripts/check--help -> scripts/build/check--help + + scripts/build/checkChangeLog@1.6 +0 -0 + Rename: scripts/checkChangeLog -> scripts/build/checkChangeLog + + scripts/build/fixautomakedepsmagic@1.4 +0 -0 + Change mode to -rwxrwxr-x + + scripts/build/fixautomakedepsmagic@1.3 +0 -0 + Rename: scripts/fixautomakedepsmagic -> scripts/build/fixautomakedepsmagic + + scripts/build/genChangeLogTag@1.3 +1 -1 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/build/genChangeLogTag@1.2 +0 -0 + Rename: scripts/genChangeLogTag -> scripts/build/genChangeLogTag + + scripts/build/genCommitLog@1.9 +0 -0 + Rename: scripts/genCommitLog -> scripts/build/genCommitLog + + scripts/build/genver@1.9 +1 -1 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/build/genver@1.8 +0 -0 + Rename: scripts/genver -> scripts/build/genver + + scripts/build/mkver.in@1.15 +0 -0 + Rename: scripts/mkver.in -> scripts/build/mkver.in + + scripts/calc_tickadj/Makefile.am@1.1 +79 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/Makefile.am + + scripts/calc_tickadj/Makefile.am@1.0 +0 -0 + + scripts/calc_tickadj/calc_tickadj-opts@1.1 +60 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj-opts + + scripts/calc_tickadj/calc_tickadj-opts@1.0 +0 -0 + + scripts/calc_tickadj/calc_tickadj-opts.def@1.1 +55 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj-opts.def + + scripts/calc_tickadj/calc_tickadj-opts.def@1.0 +0 -0 + + scripts/calc_tickadj/calc_tickadj.in@1.4 +51 -30 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/calc_tickadj/calc_tickadj.in@1.3 +0 -0 + Rename: scripts/calc_tickadj.in -> scripts/calc_tickadj/calc_tickadj.in + + scripts/calc_tickadj/calc_tickadj.texi@1.1 +37 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/calc_tickadj/calc_tickadj.texi + + scripts/calc_tickadj/calc_tickadj.texi@1.0 +0 -0 + + scripts/deprecated/freq_adj.in@1.3 +0 -0 + Rename: scripts/freq_adj.in -> scripts/deprecated/freq_adj.in + + scripts/deprecated/hpadjtime.sh@1.3 +0 -0 + Rename: scripts/hpadjtime.sh -> scripts/deprecated/hpadjtime.sh + + scripts/deprecated/html2man.in@1.8 +0 -0 + Rename: scripts/html2man.in -> scripts/deprecated/html2man.in + + scripts/deprecated/ntp-close@1.3 +0 -0 + Rename: scripts/ntp-close -> scripts/deprecated/ntp-close + + scripts/deprecated/ntp-groper@1.3 +0 -0 + Rename: scripts/ntp-groper -> scripts/deprecated/ntp-groper + + scripts/deprecated/ntp-restart@1.4 +0 -0 + Rename: scripts/ntp-restart -> scripts/deprecated/ntp-restart + + scripts/deprecated/ntp-status@1.3 +0 -0 + Rename: scripts/ntp-status -> scripts/deprecated/ntp-status + + scripts/lib/Makefile.am@1.1 +5 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/lib/Makefile.am + + scripts/lib/Makefile.am@1.0 +0 -0 + + scripts/lib/NTP/Mode6/Packet.pm@1.1 +222 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/lib/NTP/Mode6/Packet.pm + + scripts/lib/NTP/Mode6/Packet.pm@1.0 +0 -0 + + scripts/lib/NTP/Util.pm@1.1 +136 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/lib/NTP/Util.pm + + scripts/lib/NTP/Util.pm@1.0 +0 -0 + + scripts/ntp-wait/Makefile.am@1.1 +87 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntp-wait/Makefile.am + + scripts/ntp-wait/Makefile.am@1.0 +0 -0 + + scripts/ntp-wait/invoke-ntp-wait.menu@1.3 +0 -0 + Rename: scripts/invoke-ntp-wait.menu -> scripts/ntp-wait/invoke-ntp-wait.menu + + scripts/ntp-wait/invoke-ntp-wait.texi@1.199.1.1 +0 -0 + Rename: scripts/invoke-ntp-wait.texi -> scripts/ntp-wait/invoke-ntp-wait.texi + + scripts/ntp-wait/ntp-wait-opts@1.1 +62 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntp-wait/ntp-wait-opts + + scripts/ntp-wait/ntp-wait-opts@1.0 +0 -0 + + scripts/ntp-wait/ntp-wait-opts.def@1.9 +30 -29 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/ntp-wait/ntp-wait-opts.def@1.8 +0 -0 + Rename: scripts/ntp-wait-opts.def -> scripts/ntp-wait/ntp-wait-opts.def + + scripts/ntp-wait/ntp-wait.1ntp-waitman@1.210.1.1 +0 -0 + Rename: scripts/ntp-wait.1ntp-waitman -> scripts/ntp-wait/ntp-wait.1ntp-waitman + + scripts/ntp-wait/ntp-wait.1ntp-waitmdoc@1.210.1.1 +0 -0 + Rename: scripts/ntp-wait.1ntp-waitmdoc -> scripts/ntp-wait/ntp-wait.1ntp-waitmdoc + + scripts/ntp-wait/ntp-wait.html@1.215.1.1 +0 -0 + Rename: scripts/ntp-wait.html -> scripts/ntp-wait/ntp-wait.html + + scripts/ntp-wait/ntp-wait.in@1.9 +62 -51 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/ntp-wait/ntp-wait.in@1.8 +0 -0 + Rename: scripts/ntp-wait.in -> scripts/ntp-wait/ntp-wait.in + + scripts/ntp-wait/ntp-wait.man.in@1.210.1.1 +0 -0 + Rename: scripts/ntp-wait.man.in -> scripts/ntp-wait/ntp-wait.man.in + + scripts/ntp-wait/ntp-wait.mdoc.in@1.210.1.2 +26 -56 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/ntp-wait/ntp-wait.mdoc.in@1.210.1.1 +0 -0 + Rename: scripts/ntp-wait.mdoc.in -> scripts/ntp-wait/ntp-wait.mdoc.in + + scripts/ntp-wait/ntp-wait.texi@1.6 +1 -10 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/ntp-wait/ntp-wait.texi@1.5 +0 -0 + Rename: scripts/ntp-wait.texi -> scripts/ntp-wait/ntp-wait.texi + + scripts/ntpsweep/Makefile.am@1.1 +80 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/Makefile.am + + scripts/ntpsweep/Makefile.am@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep-opts@1.1 +72 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep-opts + + scripts/ntpsweep/ntpsweep-opts@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep-opts.def@1.1 +63 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep-opts.def + + scripts/ntpsweep/ntpsweep-opts.def@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep.in@1.6 +150 -247 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/ntpsweep/ntpsweep.in@1.5 +0 -0 + Rename: scripts/ntpsweep.in -> scripts/ntpsweep/ntpsweep.in + + scripts/ntpsweep/ntpsweep.mdoc.in@1.1 +71 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep.mdoc.in + + scripts/ntpsweep/ntpsweep.mdoc.in@1.0 +0 -0 + + scripts/ntpsweep/ntpsweep.texi@1.1 +43 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntpsweep/ntpsweep.texi + + scripts/ntpsweep/ntpsweep.texi@1.0 +0 -0 + + scripts/ntptrace/Makefile.am@1.1 +86 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/Makefile.am + + scripts/ntptrace/Makefile.am@1.0 +0 -0 + + scripts/ntptrace/ntptrace-opts@1.1 +67 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace-opts + + scripts/ntptrace/ntptrace-opts@1.0 +0 -0 + + scripts/ntptrace/ntptrace-opts.def@1.1 +66 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace-opts.def + + scripts/ntptrace/ntptrace-opts.def@1.0 +0 -0 + + scripts/ntptrace/ntptrace.in@1.10 +74 -67 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/ntptrace/ntptrace.in@1.9 +0 -0 + Rename: scripts/ntptrace.in -> scripts/ntptrace/ntptrace.in + + scripts/ntptrace/ntptrace.mdoc.in@1.1 +87 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace.mdoc.in + + scripts/ntptrace/ntptrace.mdoc.in@1.0 +0 -0 + + scripts/ntptrace/ntptrace.texi@1.1 +40 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/ntptrace/ntptrace.texi + + scripts/ntptrace/ntptrace.texi@1.0 +0 -0 + + scripts/plot_summary-opts@1.1 +73 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary-opts + + scripts/plot_summary-opts@1.0 +0 -0 + + scripts/plot_summary-opts.def@1.1 +78 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/plot_summary-opts.def + + scripts/plot_summary-opts.def@1.0 +0 -0 + + scripts/plot_summary.in@1.3 +42 -50 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/rc/README@1.1 +13 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/rc/README + + scripts/rc/README@1.0 +0 -0 + + scripts/rc/ntpd@1.1 +88 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/rc/ntpd + + scripts/rc/ntpd@1.0 +0 -0 + + scripts/rc/ntpwait@1.1 +15 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/rc/ntpwait + + scripts/rc/ntpwait@1.0 +0 -0 + + scripts/rc/rc.d/TIMESYNC@1.1 +8 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/rc/rc.d/TIMESYNC + + scripts/rc/rc.d/TIMESYNC@1.0 +0 -0 + + scripts/rc/rc.d/ntpd@1.1 +32 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/rc/rc.d/ntpd + + scripts/rc/rc.d/ntpd@1.0 +0 -0 + + scripts/rc/rc.d/ntpwait@1.1 +21 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/rc/rc.d/ntpwait + + scripts/rc/rc.d/ntpwait@1.0 +0 -0 + + scripts/rc1/postinstall@1.3 +0 -2 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/rc1/preinstall@1.3 +0 -6 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/rc1/preremove@1.3 +0 -4 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/rc1/prototype@1.3 +0 -19 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/rc1/xntp@1.3 +0 -29 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/rc2/local.ntpd@1.3 +0 -64 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/summary-opts@1.1 +69 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary-opts + + scripts/summary-opts@1.0 +0 -0 + + scripts/summary-opts.def@1.1 +77 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/summary-opts.def + + scripts/summary-opts.def@1.0 +0 -0 + + scripts/summary.in@1.3 +81 -85 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + scripts/t/1_common.t@1.1 +28 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/1_common.t + + scripts/t/1_common.t@1.0 +0 -0 + + scripts/t/calc_tickadj.t@1.1 +90 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/calc_tickadj.t + + scripts/t/calc_tickadj.t@1.0 +0 -0 + + scripts/t/lib/Test/Command.pm@1.1 +261 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/lib/Test/Command.pm + + scripts/t/lib/Test/Command.pm@1.0 +0 -0 + + scripts/t/lib/Test/Mode6/Server.pm@1.1 +66 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/lib/Test/Mode6/Server.pm + + scripts/t/lib/Test/Mode6/Server.pm@1.0 +0 -0 + + scripts/t/lib/Test/Util.pm@1.1 +167 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/lib/Test/Util.pm + + scripts/t/lib/Test/Util.pm@1.0 +0 -0 + + scripts/t/ntp-wait.t@1.1 +142 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/ntp-wait.t + + scripts/t/ntp-wait.t@1.0 +0 -0 + + scripts/t/ntpsweep.t@1.1 +117 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/ntpsweep.t + + scripts/t/ntpsweep.t@1.0 +0 -0 + + scripts/t/ntptrace.t@1.1 +154 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/ntptrace.t + + scripts/t/ntptrace.t@1.0 +0 -0 + + scripts/t/plot_summary.t@1.1 +17 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/plot_summary.t + + scripts/t/plot_summary.t@1.0 +0 -0 + + scripts/t/summary.t@1.1 +17 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/summary.t + + scripts/t/summary.t@1.0 +0 -0 + + scripts/t/util.t@1.1 +179 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/scripts/t/util.t + + scripts/t/util.t@1.0 +0 -0 + + sntp/Makefile.am@1.75 +5 -5 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + sntp/ag-tpl/Mdoc.pm@1.1 +515 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/sntp/ag-tpl/Mdoc.pm + + sntp/ag-tpl/Mdoc.pm@1.0 +0 -0 + + sntp/ag-tpl/agman-cmd.tpl@1.1 +58 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/sntp/ag-tpl/agman-cmd.tpl + + sntp/ag-tpl/agman-cmd.tpl@1.0 +0 -0 + + sntp/ag-tpl/agmdoc-cmd.tpl@1.1 +46 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/sntp/ag-tpl/agmdoc-cmd.tpl + + sntp/ag-tpl/agmdoc-cmd.tpl@1.0 +0 -0 + + sntp/ag-tpl/cmd-doc.tlib@1.1 +1079 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/sntp/ag-tpl/cmd-doc.tlib + + sntp/ag-tpl/cmd-doc.tlib@1.0 +0 -0 + + sntp/ag-tpl/mdoc-synopsis.tlib@1.1 +92 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/sntp/ag-tpl/mdoc-synopsis.tlib + + sntp/ag-tpl/mdoc-synopsis.tlib@1.0 +0 -0 + + sntp/ag-tpl/mdoc2man@1.1 +181 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/sntp/ag-tpl/mdoc2man + + sntp/ag-tpl/mdoc2man@1.0 +0 -0 + + sntp/ag-tpl/mdoc2texi@1.8 +144 -1016 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + sntp/ag-tpl/perlopt.tpl@1.1 +176 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/kindernay/ntp-dev-final/sntp/ag-tpl/perlopt.tpl + + sntp/ag-tpl/perlopt.tpl@1.0 +0 -0 + + sntp/m4/define_dir.m4@1.4 +26 -17 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + + util/Makefile.am@1.75 +2 -2 + Incorporate Oliver Kindernay's GSoC 2013 scripts/ cleanup + +ChangeSet@1.3020, 2013-11-28 11:37:11+00:00, stenn@deacon.udel.edu + NTP_4_2_7P399 + TAG: NTP_4_2_7P399 + + ChangeLog@1.1361 +1 -0 + NTP_4_2_7P399 + + ntpd/invoke-ntp.conf.texi@1.77 +1 -1 + NTP_4_2_7P399 + + ntpd/invoke-ntp.keys.texi@1.75 +1 -1 + NTP_4_2_7P399 + + ntpd/invoke-ntpd.texi@1.391 +2 -2 + NTP_4_2_7P399 + + ntpd/ntp.conf.5man@1.111 +3 -3 + NTP_4_2_7P399 + + ntpd/ntp.conf.5mdoc@1.111 +3 -3 + NTP_4_2_7P399 + + ntpd/ntp.conf.html@1.72 +1 -1 + NTP_4_2_7P399 + + ntpd/ntp.conf.man.in@1.111 +3 -3 + NTP_4_2_7P399 + + ntpd/ntp.conf.mdoc.in@1.111 +3 -3 + NTP_4_2_7P399 + + ntpd/ntp.keys.5man@1.109 +3 -3 + NTP_4_2_7P399 + + ntpd/ntp.keys.5mdoc@1.109 +3 -3 + NTP_4_2_7P399 + + ntpd/ntp.keys.html@1.73 +1 -1 + NTP_4_2_7P399 + + ntpd/ntp.keys.man.in@1.109 +3 -3 + NTP_4_2_7P399 + + ntpd/ntp.keys.mdoc.in@1.109 +3 -3 + NTP_4_2_7P399 + + ntpd/ntpd-opts.c@1.409 +7 -7 + NTP_4_2_7P399 + + ntpd/ntpd-opts.h@1.409 +3 -3 + NTP_4_2_7P399 + + ntpd/ntpd.1ntpdman@1.220 +3 -3 + NTP_4_2_7P399 + + ntpd/ntpd.1ntpdmdoc@1.220 +3 -3 + NTP_4_2_7P399 + + ntpd/ntpd.html@1.67 +2 -2 + NTP_4_2_7P399 + + ntpd/ntpd.man.in@1.220 +3 -3 + NTP_4_2_7P399 + + ntpd/ntpd.mdoc.in@1.220 +3 -3 + NTP_4_2_7P399 + + ntpdc/invoke-ntpdc.texi@1.388 +2 -2 + NTP_4_2_7P399 + + ntpdc/ntpdc-opts.c@1.403 +7 -7 + NTP_4_2_7P399 + + ntpdc/ntpdc-opts.h@1.403 +3 -3 + NTP_4_2_7P399 + + ntpdc/ntpdc.1ntpdcman@1.219 +2 -2 + NTP_4_2_7P399 + + ntpdc/ntpdc.1ntpdcmdoc@1.219 +2 -2 + NTP_4_2_7P399 + + ntpdc/ntpdc.html@1.232 +2 -2 + NTP_4_2_7P399 + + ntpdc/ntpdc.man.in@1.219 +2 -2 + NTP_4_2_7P399 + + ntpdc/ntpdc.mdoc.in@1.219 +2 -2 + NTP_4_2_7P399 + + ntpq/invoke-ntpq.texi@1.392 +2 -2 + NTP_4_2_7P399 + + ntpq/ntpq-opts.c@1.406 +7 -7 + NTP_4_2_7P399 + + ntpq/ntpq-opts.h@1.406 +3 -3 + NTP_4_2_7P399 + + ntpq/ntpq.1ntpqman@1.220 +2 -2 + NTP_4_2_7P399 + + ntpq/ntpq.1ntpqmdoc@1.220 +2 -2 + NTP_4_2_7P399 + + ntpq/ntpq.html@1.64 +2 -2 + NTP_4_2_7P399 + + ntpq/ntpq.man.in@1.220 +2 -2 + NTP_4_2_7P399 + + ntpq/ntpq.mdoc.in@1.220 +2 -2 + NTP_4_2_7P399 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.391 +2 -2 + NTP_4_2_7P399 + + ntpsnmpd/ntpsnmpd-opts.c@1.406 +7 -7 + NTP_4_2_7P399 + + ntpsnmpd/ntpsnmpd-opts.h@1.406 +3 -3 + NTP_4_2_7P399 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.220 +3 -3 + NTP_4_2_7P399 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.220 +3 -3 + NTP_4_2_7P399 + + ntpsnmpd/ntpsnmpd.html@1.62 +1 -1 + NTP_4_2_7P399 + + ntpsnmpd/ntpsnmpd.man.in@1.220 +3 -3 + NTP_4_2_7P399 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.220 +3 -3 + NTP_4_2_7P399 + + packageinfo.sh@1.402 +1 -1 + NTP_4_2_7P399 + + scripts/invoke-ntp-wait.texi@1.208 +1 -1 + NTP_4_2_7P399 + + scripts/ntp-wait.1ntp-waitman@1.219 +3 -3 + NTP_4_2_7P399 + + scripts/ntp-wait.1ntp-waitmdoc@1.219 +3 -3 + NTP_4_2_7P399 + + scripts/ntp-wait.html@1.224 +1 -1 + NTP_4_2_7P399 + + scripts/ntp-wait.man.in@1.219 +3 -3 + NTP_4_2_7P399 + + scripts/ntp-wait.mdoc.in@1.219 +3 -3 + NTP_4_2_7P399 + + sntp/invoke-sntp.texi@1.388 +2 -2 + NTP_4_2_7P399 + + sntp/sntp-opts.c@1.403 +7 -7 + NTP_4_2_7P399 + + sntp/sntp-opts.h@1.403 +3 -3 + NTP_4_2_7P399 + + sntp/sntp.1sntpman@1.223 +3 -3 + NTP_4_2_7P399 + + sntp/sntp.1sntpmdoc@1.223 +3 -3 + NTP_4_2_7P399 + + sntp/sntp.html@1.403 +2 -2 + NTP_4_2_7P399 + + sntp/sntp.man.in@1.223 +3 -3 + NTP_4_2_7P399 + + sntp/sntp.mdoc.in@1.223 +3 -3 + NTP_4_2_7P399 + + util/invoke-ntp-keygen.texi@1.392 +2 -2 + NTP_4_2_7P399 + + util/ntp-keygen-opts.c@1.406 +7 -7 + NTP_4_2_7P399 + + util/ntp-keygen-opts.h@1.406 +3 -3 + NTP_4_2_7P399 + + util/ntp-keygen.1ntp-keygenman@1.220 +3 -3 + NTP_4_2_7P399 + + util/ntp-keygen.1ntp-keygenmdoc@1.220 +3 -3 + NTP_4_2_7P399 + + util/ntp-keygen.html@1.68 +2 -2 + NTP_4_2_7P399 + + util/ntp-keygen.man.in@1.220 +3 -3 + NTP_4_2_7P399 + + util/ntp-keygen.mdoc.in@1.220 +3 -3 + NTP_4_2_7P399 + +ChangeSet@1.3017, 2013-11-28 00:20:43-05:00, stenn@deacon.udel.edu + [Bug 2514] secs/* #define usage cleanup + + ChangeLog@1.1359 +1 -0 + [Bug 2514] secs/* #define usage cleanup + + include/ntp_stdlib.h@1.76 +0 -4 + [Bug 2514] secs/* #define usage cleanup + + ntpd/ntp_loopfilter.c@1.170 +0 -2 + [Bug 2514] secs/* #define usage cleanup + + ntpd/ntp_timer.c@1.80 +4 -3 + [Bug 2514] secs/* #define usage cleanup + + ntpd/refclock_tsyncpci.c@1.9 +19 -29 + [Bug 2514] secs/* #define usage cleanup + + util/ntp-keygen.c@1.96 +2 -3 + [Bug 2514] secs/* #define usage cleanup + +ChangeSet@1.3016, 2013-11-27 22:07:41+00:00, stenn@psp-deb1.ntp.org + [Bug 2326] More leapsecond file notification cleanup + + ChangeLog@1.1358 +1 -0 + [Bug 2326] More leapsecond file notification cleanup + + ntpd/ntp_timer.c@1.79 +4 -4 + [Bug 2326] More leapsecond file notification cleanup + +ChangeSet@1.3015, 2013-11-25 13:00:04+00:00, stenn@deacon.udel.edu + NTP_4_2_7P398 + TAG: NTP_4_2_7P398 + + ChangeLog@1.1357 +1 -0 + NTP_4_2_7P398 + + ntpd/invoke-ntp.conf.texi@1.76 +1 -1 + NTP_4_2_7P398 + + ntpd/invoke-ntp.keys.texi@1.74 +1 -1 + NTP_4_2_7P398 + + ntpd/invoke-ntpd.texi@1.390 +2 -2 + NTP_4_2_7P398 + + ntpd/ntp.conf.5man@1.110 +3 -3 + NTP_4_2_7P398 + + ntpd/ntp.conf.5mdoc@1.110 +3 -3 + NTP_4_2_7P398 + + ntpd/ntp.conf.html@1.71 +1 -1 + NTP_4_2_7P398 + + ntpd/ntp.conf.man.in@1.110 +3 -3 + NTP_4_2_7P398 + + ntpd/ntp.conf.mdoc.in@1.110 +3 -3 + NTP_4_2_7P398 + + ntpd/ntp.keys.5man@1.108 +3 -3 + NTP_4_2_7P398 + + ntpd/ntp.keys.5mdoc@1.108 +3 -3 + NTP_4_2_7P398 + + ntpd/ntp.keys.html@1.72 +1 -1 + NTP_4_2_7P398 + + ntpd/ntp.keys.man.in@1.108 +3 -3 + NTP_4_2_7P398 + + ntpd/ntp.keys.mdoc.in@1.108 +3 -3 + NTP_4_2_7P398 + + ntpd/ntpd-opts.c@1.408 +7 -7 + NTP_4_2_7P398 + + ntpd/ntpd-opts.h@1.408 +3 -3 + NTP_4_2_7P398 + + ntpd/ntpd.1ntpdman@1.219 +3 -3 + NTP_4_2_7P398 + + ntpd/ntpd.1ntpdmdoc@1.219 +3 -3 + NTP_4_2_7P398 + + ntpd/ntpd.html@1.66 +2 -2 + NTP_4_2_7P398 + + ntpd/ntpd.man.in@1.219 +3 -3 + NTP_4_2_7P398 + + ntpd/ntpd.mdoc.in@1.219 +3 -3 + NTP_4_2_7P398 + + ntpdc/invoke-ntpdc.texi@1.387 +2 -2 + NTP_4_2_7P398 + + ntpdc/ntpdc-opts.c@1.402 +7 -7 + NTP_4_2_7P398 + + ntpdc/ntpdc-opts.h@1.402 +3 -3 + NTP_4_2_7P398 + + ntpdc/ntpdc.1ntpdcman@1.218 +2 -2 + NTP_4_2_7P398 + + ntpdc/ntpdc.1ntpdcmdoc@1.218 +2 -2 + NTP_4_2_7P398 + + ntpdc/ntpdc.html@1.231 +2 -2 + NTP_4_2_7P398 + + ntpdc/ntpdc.man.in@1.218 +2 -2 + NTP_4_2_7P398 + + ntpdc/ntpdc.mdoc.in@1.218 +2 -2 + NTP_4_2_7P398 + + ntpq/invoke-ntpq.texi@1.391 +2 -2 + NTP_4_2_7P398 + + ntpq/ntpq-opts.c@1.405 +7 -7 + NTP_4_2_7P398 + + ntpq/ntpq-opts.h@1.405 +3 -3 + NTP_4_2_7P398 + + ntpq/ntpq.1ntpqman@1.219 +2 -2 + NTP_4_2_7P398 + + ntpq/ntpq.1ntpqmdoc@1.219 +2 -2 + NTP_4_2_7P398 + + ntpq/ntpq.html@1.63 +2 -2 + NTP_4_2_7P398 + + ntpq/ntpq.man.in@1.219 +2 -2 + NTP_4_2_7P398 + + ntpq/ntpq.mdoc.in@1.219 +2 -2 + NTP_4_2_7P398 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.390 +2 -2 + NTP_4_2_7P398 + + ntpsnmpd/ntpsnmpd-opts.c@1.405 +7 -7 + NTP_4_2_7P398 + + ntpsnmpd/ntpsnmpd-opts.h@1.405 +3 -3 + NTP_4_2_7P398 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.219 +3 -3 + NTP_4_2_7P398 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.219 +3 -3 + NTP_4_2_7P398 + + ntpsnmpd/ntpsnmpd.html@1.61 +1 -1 + NTP_4_2_7P398 + + ntpsnmpd/ntpsnmpd.man.in@1.219 +3 -3 + NTP_4_2_7P398 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.219 +3 -3 + NTP_4_2_7P398 + + packageinfo.sh@1.401 +1 -1 + NTP_4_2_7P398 + + scripts/invoke-ntp-wait.texi@1.207 +1 -1 + NTP_4_2_7P398 + + scripts/ntp-wait.1ntp-waitman@1.218 +3 -3 + NTP_4_2_7P398 + + scripts/ntp-wait.1ntp-waitmdoc@1.218 +3 -3 + NTP_4_2_7P398 + + scripts/ntp-wait.html@1.223 +1 -1 + NTP_4_2_7P398 + + scripts/ntp-wait.man.in@1.218 +3 -3 + NTP_4_2_7P398 + + scripts/ntp-wait.mdoc.in@1.218 +3 -3 + NTP_4_2_7P398 + + sntp/invoke-sntp.texi@1.387 +2 -2 + NTP_4_2_7P398 + + sntp/sntp-opts.c@1.402 +7 -7 + NTP_4_2_7P398 + + sntp/sntp-opts.h@1.402 +3 -3 + NTP_4_2_7P398 + + sntp/sntp.1sntpman@1.222 +3 -3 + NTP_4_2_7P398 + + sntp/sntp.1sntpmdoc@1.222 +3 -3 + NTP_4_2_7P398 + + sntp/sntp.html@1.402 +2 -2 + NTP_4_2_7P398 + + sntp/sntp.man.in@1.222 +3 -3 + NTP_4_2_7P398 + + sntp/sntp.mdoc.in@1.222 +3 -3 + NTP_4_2_7P398 + + util/invoke-ntp-keygen.texi@1.391 +2 -2 + NTP_4_2_7P398 + + util/ntp-keygen-opts.c@1.405 +7 -7 + NTP_4_2_7P398 + + util/ntp-keygen-opts.h@1.405 +3 -3 + NTP_4_2_7P398 + + util/ntp-keygen.1ntp-keygenman@1.219 +3 -3 + NTP_4_2_7P398 + + util/ntp-keygen.1ntp-keygenmdoc@1.219 +3 -3 + NTP_4_2_7P398 + + util/ntp-keygen.html@1.67 +2 -2 + NTP_4_2_7P398 + + util/ntp-keygen.man.in@1.219 +3 -3 + NTP_4_2_7P398 + + util/ntp-keygen.mdoc.in@1.219 +3 -3 + NTP_4_2_7P398 + +ChangeSet@1.3014, 2013-11-25 04:01:41-08:00, harlan@hms-mbp11.local + [Bug 2326] More leapsecond file notification cleanup + + ntpd/ntp_config.c@1.315 +0 -1 + [Bug 2326] More leapsecond file notification cleanup + + ntpd/ntp_io.c@1.386 +0 -32 + [Bug 2326] More leapsecond file notification cleanup + + ntpd/ntp_timer.c@1.78 +18 -13 + [Bug 2326] More leapsecond file notification cleanup + +ChangeSet@1.3013, 2013-11-23 14:08:57-08:00, harlan@hms-mbp11.local + [Bug 2326] More leapsecond file notification cleanup + + ChangeLog@1.1356 +2 -0 + [Bug 2326] More leapsecond file notification cleanup + + ntpd/ntp_io.c@1.385 +25 -8 + [Bug 2326] More leapsecond file notification cleanup + + ntpd/ntp_timer.c@1.77 +3 -2 + [Bug 2326] More leapsecond file notification cleanup + +ChangeSet@1.3012, 2013-11-23 13:59:42-08:00, harlan@hms-mbp11.local + Emit %m value on KoD file open failure. + + sntp/kod_management.c@1.32 +1 -1 + Emit %m value on KoD file open failure. + +ChangeSet@1.3011, 2013-11-20 11:34:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P397 + TAG: NTP_4_2_7P397 + + ChangeLog@1.1355 +1 -0 + NTP_4_2_7P397 + + ntpd/invoke-ntp.conf.texi@1.75 +1 -1 + NTP_4_2_7P397 + + ntpd/invoke-ntp.keys.texi@1.73 +1 -1 + NTP_4_2_7P397 + + ntpd/invoke-ntpd.texi@1.389 +2 -2 + NTP_4_2_7P397 + + ntpd/ntp.conf.5man@1.109 +3 -3 + NTP_4_2_7P397 + + ntpd/ntp.conf.5mdoc@1.109 +3 -3 + NTP_4_2_7P397 + + ntpd/ntp.conf.html@1.70 +1 -1 + NTP_4_2_7P397 + + ntpd/ntp.conf.man.in@1.109 +3 -3 + NTP_4_2_7P397 + + ntpd/ntp.conf.mdoc.in@1.109 +3 -3 + NTP_4_2_7P397 + + ntpd/ntp.keys.5man@1.107 +3 -3 + NTP_4_2_7P397 + + ntpd/ntp.keys.5mdoc@1.107 +3 -3 + NTP_4_2_7P397 + + ntpd/ntp.keys.html@1.71 +1 -1 + NTP_4_2_7P397 + + ntpd/ntp.keys.man.in@1.107 +3 -3 + NTP_4_2_7P397 + + ntpd/ntp.keys.mdoc.in@1.107 +3 -3 + NTP_4_2_7P397 + + ntpd/ntpd-opts.c@1.407 +7 -7 + NTP_4_2_7P397 + + ntpd/ntpd-opts.h@1.407 +3 -3 + NTP_4_2_7P397 + + ntpd/ntpd.1ntpdman@1.218 +3 -3 + NTP_4_2_7P397 + + ntpd/ntpd.1ntpdmdoc@1.218 +3 -3 + NTP_4_2_7P397 + + ntpd/ntpd.html@1.65 +2 -2 + NTP_4_2_7P397 + + ntpd/ntpd.man.in@1.218 +3 -3 + NTP_4_2_7P397 + + ntpd/ntpd.mdoc.in@1.218 +3 -3 + NTP_4_2_7P397 + + ntpdc/invoke-ntpdc.texi@1.386 +2 -2 + NTP_4_2_7P397 + + ntpdc/ntpdc-opts.c@1.401 +7 -7 + NTP_4_2_7P397 + + ntpdc/ntpdc-opts.h@1.401 +3 -3 + NTP_4_2_7P397 + + ntpdc/ntpdc.1ntpdcman@1.217 +2 -2 + NTP_4_2_7P397 + + ntpdc/ntpdc.1ntpdcmdoc@1.217 +2 -2 + NTP_4_2_7P397 + + ntpdc/ntpdc.html@1.230 +2 -2 + NTP_4_2_7P397 + + ntpdc/ntpdc.man.in@1.217 +2 -2 + NTP_4_2_7P397 + + ntpdc/ntpdc.mdoc.in@1.217 +2 -2 + NTP_4_2_7P397 + + ntpq/invoke-ntpq.texi@1.390 +2 -2 + NTP_4_2_7P397 + + ntpq/ntpq-opts.c@1.404 +7 -7 + NTP_4_2_7P397 + + ntpq/ntpq-opts.h@1.404 +3 -3 + NTP_4_2_7P397 + + ntpq/ntpq.1ntpqman@1.218 +2 -2 + NTP_4_2_7P397 + + ntpq/ntpq.1ntpqmdoc@1.218 +2 -2 + NTP_4_2_7P397 + + ntpq/ntpq.html@1.62 +2 -2 + NTP_4_2_7P397 + + ntpq/ntpq.man.in@1.218 +2 -2 + NTP_4_2_7P397 + + ntpq/ntpq.mdoc.in@1.218 +2 -2 + NTP_4_2_7P397 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.389 +2 -2 + NTP_4_2_7P397 + + ntpsnmpd/ntpsnmpd-opts.c@1.404 +7 -7 + NTP_4_2_7P397 + + ntpsnmpd/ntpsnmpd-opts.h@1.404 +3 -3 + NTP_4_2_7P397 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.218 +3 -3 + NTP_4_2_7P397 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.218 +3 -3 + NTP_4_2_7P397 + + ntpsnmpd/ntpsnmpd.html@1.60 +1 -1 + NTP_4_2_7P397 + + ntpsnmpd/ntpsnmpd.man.in@1.218 +3 -3 + NTP_4_2_7P397 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.218 +3 -3 + NTP_4_2_7P397 + + packageinfo.sh@1.400 +1 -1 + NTP_4_2_7P397 + + scripts/invoke-ntp-wait.texi@1.206 +1 -1 + NTP_4_2_7P397 + + scripts/ntp-wait.1ntp-waitman@1.217 +3 -3 + NTP_4_2_7P397 + + scripts/ntp-wait.1ntp-waitmdoc@1.217 +3 -3 + NTP_4_2_7P397 + + scripts/ntp-wait.html@1.222 +1 -1 + NTP_4_2_7P397 + + scripts/ntp-wait.man.in@1.217 +3 -3 + NTP_4_2_7P397 + + scripts/ntp-wait.mdoc.in@1.217 +3 -3 + NTP_4_2_7P397 + + sntp/invoke-sntp.texi@1.386 +2 -2 + NTP_4_2_7P397 + + sntp/sntp-opts.c@1.401 +7 -7 + NTP_4_2_7P397 + + sntp/sntp-opts.h@1.401 +3 -3 + NTP_4_2_7P397 + + sntp/sntp.1sntpman@1.221 +3 -3 + NTP_4_2_7P397 + + sntp/sntp.1sntpmdoc@1.221 +3 -3 + NTP_4_2_7P397 + + sntp/sntp.html@1.401 +2 -2 + NTP_4_2_7P397 + + sntp/sntp.man.in@1.221 +3 -3 + NTP_4_2_7P397 + + sntp/sntp.mdoc.in@1.221 +3 -3 + NTP_4_2_7P397 + + util/invoke-ntp-keygen.texi@1.390 +2 -2 + NTP_4_2_7P397 + + util/ntp-keygen-opts.c@1.404 +7 -7 + NTP_4_2_7P397 + + util/ntp-keygen-opts.h@1.404 +3 -3 + NTP_4_2_7P397 + + util/ntp-keygen.1ntp-keygenman@1.218 +3 -3 + NTP_4_2_7P397 + + util/ntp-keygen.1ntp-keygenmdoc@1.218 +3 -3 + NTP_4_2_7P397 + + util/ntp-keygen.html@1.66 +2 -2 + NTP_4_2_7P397 + + util/ntp-keygen.man.in@1.218 +3 -3 + NTP_4_2_7P397 + + util/ntp-keygen.mdoc.in@1.218 +3 -3 + NTP_4_2_7P397 + +ChangeSet@1.3010, 2013-11-20 03:56:38-05:00, stenn@deacon.udel.edu + [Bug 2326] Improve stale leapsecond notifications + + ChangeLog@1.1354 +1 -0 + [Bug 2326] Improve stale leapsecond notifications + + ntpd/ntp_io.c@1.384 +7 -1 + [Bug 2326] Improve stale leapsecond notifications + + ntpd/ntp_timer.c@1.76 +2 -3 + [Bug 2326] Improve stale leapsecond notifications + +ChangeSet@1.3009, 2013-11-19 11:37:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P396 + TAG: NTP_4_2_7P396 + + ChangeLog@1.1353 +1 -0 + NTP_4_2_7P396 + + ntpd/invoke-ntp.conf.texi@1.74 +1 -1 + NTP_4_2_7P396 + + ntpd/invoke-ntp.keys.texi@1.72 +1 -1 + NTP_4_2_7P396 + + ntpd/invoke-ntpd.texi@1.388 +2 -2 + NTP_4_2_7P396 + + ntpd/ntp.conf.5man@1.108 +3 -3 + NTP_4_2_7P396 + + ntpd/ntp.conf.5mdoc@1.108 +3 -3 + NTP_4_2_7P396 + + ntpd/ntp.conf.html@1.69 +1 -1 + NTP_4_2_7P396 + + ntpd/ntp.conf.man.in@1.108 +3 -3 + NTP_4_2_7P396 + + ntpd/ntp.conf.mdoc.in@1.108 +3 -3 + NTP_4_2_7P396 + + ntpd/ntp.keys.5man@1.106 +3 -3 + NTP_4_2_7P396 + + ntpd/ntp.keys.5mdoc@1.106 +3 -3 + NTP_4_2_7P396 + + ntpd/ntp.keys.html@1.70 +1 -1 + NTP_4_2_7P396 + + ntpd/ntp.keys.man.in@1.106 +3 -3 + NTP_4_2_7P396 + + ntpd/ntp.keys.mdoc.in@1.106 +3 -3 + NTP_4_2_7P396 + + ntpd/ntpd-opts.c@1.406 +7 -7 + NTP_4_2_7P396 + + ntpd/ntpd-opts.h@1.406 +3 -3 + NTP_4_2_7P396 + + ntpd/ntpd.1ntpdman@1.217 +3 -3 + NTP_4_2_7P396 + + ntpd/ntpd.1ntpdmdoc@1.217 +3 -3 + NTP_4_2_7P396 + + ntpd/ntpd.html@1.64 +18 -18 + NTP_4_2_7P396 + + ntpd/ntpd.man.in@1.217 +3 -3 + NTP_4_2_7P396 + + ntpd/ntpd.mdoc.in@1.217 +3 -3 + NTP_4_2_7P396 + + ntpdc/invoke-ntpdc.texi@1.385 +2 -2 + NTP_4_2_7P396 + + ntpdc/ntpdc-opts.c@1.400 +7 -7 + NTP_4_2_7P396 + + ntpdc/ntpdc-opts.h@1.400 +3 -3 + NTP_4_2_7P396 + + ntpdc/ntpdc.1ntpdcman@1.216 +2 -2 + NTP_4_2_7P396 + + ntpdc/ntpdc.1ntpdcmdoc@1.216 +2 -2 + NTP_4_2_7P396 + + ntpdc/ntpdc.html@1.229 +2 -2 + NTP_4_2_7P396 + + ntpdc/ntpdc.man.in@1.216 +2 -2 + NTP_4_2_7P396 + + ntpdc/ntpdc.mdoc.in@1.216 +2 -2 + NTP_4_2_7P396 + + ntpq/invoke-ntpq.texi@1.389 +2 -2 + NTP_4_2_7P396 + + ntpq/ntpq-opts.c@1.403 +7 -7 + NTP_4_2_7P396 + + ntpq/ntpq-opts.h@1.403 +3 -3 + NTP_4_2_7P396 + + ntpq/ntpq.1ntpqman@1.217 +2 -2 + NTP_4_2_7P396 + + ntpq/ntpq.1ntpqmdoc@1.217 +2 -2 + NTP_4_2_7P396 + + ntpq/ntpq.html@1.61 +3 -3 + NTP_4_2_7P396 + + ntpq/ntpq.man.in@1.217 +2 -2 + NTP_4_2_7P396 + + ntpq/ntpq.mdoc.in@1.217 +2 -2 + NTP_4_2_7P396 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.388 +2 -2 + NTP_4_2_7P396 + + ntpsnmpd/ntpsnmpd-opts.c@1.403 +7 -7 + NTP_4_2_7P396 + + ntpsnmpd/ntpsnmpd-opts.h@1.403 +3 -3 + NTP_4_2_7P396 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.217 +3 -3 + NTP_4_2_7P396 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.217 +3 -3 + NTP_4_2_7P396 + + ntpsnmpd/ntpsnmpd.html@1.59 +1 -1 + NTP_4_2_7P396 + + ntpsnmpd/ntpsnmpd.man.in@1.217 +3 -3 + NTP_4_2_7P396 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.217 +3 -3 + NTP_4_2_7P396 + + packageinfo.sh@1.399 +1 -1 + NTP_4_2_7P396 + + scripts/invoke-ntp-wait.texi@1.205 +1 -1 + NTP_4_2_7P396 + + scripts/ntp-wait.1ntp-waitman@1.216 +3 -3 + NTP_4_2_7P396 + + scripts/ntp-wait.1ntp-waitmdoc@1.216 +3 -3 + NTP_4_2_7P396 + + scripts/ntp-wait.html@1.221 +1 -1 + NTP_4_2_7P396 + + scripts/ntp-wait.man.in@1.216 +3 -3 + NTP_4_2_7P396 + + scripts/ntp-wait.mdoc.in@1.216 +3 -3 + NTP_4_2_7P396 + + sntp/invoke-sntp.texi@1.385 +2 -2 + NTP_4_2_7P396 + + sntp/sntp-opts.c@1.400 +7 -7 + NTP_4_2_7P396 + + sntp/sntp-opts.h@1.400 +3 -3 + NTP_4_2_7P396 + + sntp/sntp.1sntpman@1.220 +3 -3 + NTP_4_2_7P396 + + sntp/sntp.1sntpmdoc@1.220 +3 -3 + NTP_4_2_7P396 + + sntp/sntp.html@1.400 +2 -2 + NTP_4_2_7P396 + + sntp/sntp.man.in@1.220 +3 -3 + NTP_4_2_7P396 + + sntp/sntp.mdoc.in@1.220 +3 -3 + NTP_4_2_7P396 + + util/invoke-ntp-keygen.texi@1.389 +2 -2 + NTP_4_2_7P396 + + util/ntp-keygen-opts.c@1.403 +7 -7 + NTP_4_2_7P396 + + util/ntp-keygen-opts.h@1.403 +3 -3 + NTP_4_2_7P396 + + util/ntp-keygen.1ntp-keygenman@1.217 +3 -3 + NTP_4_2_7P396 + + util/ntp-keygen.1ntp-keygenmdoc@1.217 +3 -3 + NTP_4_2_7P396 + + util/ntp-keygen.html@1.65 +14 -14 + NTP_4_2_7P396 + + util/ntp-keygen.man.in@1.217 +3 -3 + NTP_4_2_7P396 + + util/ntp-keygen.mdoc.in@1.217 +3 -3 + NTP_4_2_7P396 + +ChangeSet@1.3005.1.1, 2013-11-18 20:55:37+00:00, kardel@pogo.udel.edu + ChangeLog: + ntp_io.c: + [Bug 2506] make sure routing updates are always tracked + the 'flapping fix' from 2010-12-12 was and is incorrect + as routes can change without change of interface + configuration. + + ChangeLog@1.1351.1.1 +1 -0 + [Bug 2506] make sure routing updates are always tracked + the 'flapping fix' from 2010-12-12 was and is incorrect + as routes can change without change of interface + configuration. + + ntpd/ntp_io.c@1.382.1.1 +14 -24 + +ChangeSet@1.3008, 2013-11-17 14:38:45+01:00, jnperlin@hydra.(none) + [Bug 2326] sidekick: C99 type cleanup + + tests/ntpd/leapsec.cpp@1.4 +4 -4 + [Bug 2326] sidekick: C99 type cleanup + +ChangeSet@1.3007, 2013-11-17 14:36:40+01:00, jnperlin@hydra.(none) + [bug 2326] use time-to-live of leap second table for better diagnostics + + ntpd/ntp_leapsec.c@1.4 +101 -56 + [bug 2326] add support for calculation of remaining time-to-live of table data + + ntpd/ntp_leapsec.h@1.3 +22 -22 + [bug 2326] add support for calculation of remaining time-to-live of table data + + ntpd/ntp_util.c@1.106 +24 -22 + [Bug 2326] plumbing to TTL calculation for leap second data + + tests/ntpd/leapsec.cpp@1.3 +28 -1 + [Bug 2326] add tests for TTL calculation of table data + +ChangeSet@1.3006, 2013-11-17 09:03:39+00:00, stenn@psp-fb1.ntp.org + [Bug 2326] Improve stale leapsecond notifications + + ChangeLog@1.1352 +1 -0 + [Bug 2326] Improve stale leapsecond notifications + + include/ntpd.h@1.181 +1 -1 + [Bug 2326] Improve stale leapsecond notifications + + ntpd/ntp_io.c@1.383 +1 -1 + [Bug 2326] Improve stale leapsecond notifications + + ntpd/ntp_timer.c@1.75 +19 -11 + [Bug 2326] Improve stale leapsecond notifications + + ntpd/ntp_util.c@1.105 +15 -4 + [Bug 2326] Improve stale leapsecond notifications + +ChangeSet@1.3005, 2013-11-12 11:30:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P395 + TAG: NTP_4_2_7P395 + + ChangeLog@1.1351 +1 -0 + NTP_4_2_7P395 + + ntpd/invoke-ntp.conf.texi@1.73 +1 -1 + NTP_4_2_7P395 + + ntpd/invoke-ntp.keys.texi@1.71 +1 -1 + NTP_4_2_7P395 + + ntpd/invoke-ntpd.texi@1.387 +18 -18 + NTP_4_2_7P395 + + ntpd/ntp.conf.5man@1.107 +3 -3 + NTP_4_2_7P395 + + ntpd/ntp.conf.5mdoc@1.107 +3 -3 + NTP_4_2_7P395 + + ntpd/ntp.conf.html@1.68 +1 -1 + NTP_4_2_7P395 + + ntpd/ntp.conf.man.in@1.107 +3 -3 + NTP_4_2_7P395 + + ntpd/ntp.conf.mdoc.in@1.107 +3 -3 + NTP_4_2_7P395 + + ntpd/ntp.keys.5man@1.105 +3 -3 + NTP_4_2_7P395 + + ntpd/ntp.keys.5mdoc@1.105 +3 -3 + NTP_4_2_7P395 + + ntpd/ntp.keys.html@1.69 +1 -1 + NTP_4_2_7P395 + + ntpd/ntp.keys.man.in@1.105 +3 -3 + NTP_4_2_7P395 + + ntpd/ntp.keys.mdoc.in@1.105 +3 -3 + NTP_4_2_7P395 + + ntpd/ntpd-opts.c@1.405 +10 -9 + NTP_4_2_7P395 + + ntpd/ntpd-opts.h@1.405 +3 -3 + NTP_4_2_7P395 + + ntpd/ntpd.1ntpdman@1.216 +3 -3 + NTP_4_2_7P395 + + ntpd/ntpd.1ntpdmdoc@1.216 +3 -3 + NTP_4_2_7P395 + + ntpd/ntpd.html@1.63 +2 -2 + NTP_4_2_7P395 + + ntpd/ntpd.man.in@1.216 +3 -3 + NTP_4_2_7P395 + + ntpd/ntpd.mdoc.in@1.216 +3 -3 + NTP_4_2_7P395 + + ntpdc/invoke-ntpdc.texi@1.384 +3 -3 + NTP_4_2_7P395 + + ntpdc/ntpdc-opts.c@1.399 +10 -9 + NTP_4_2_7P395 + + ntpdc/ntpdc-opts.h@1.399 +3 -3 + NTP_4_2_7P395 + + ntpdc/ntpdc.1ntpdcman@1.215 +2 -2 + NTP_4_2_7P395 + + ntpdc/ntpdc.1ntpdcmdoc@1.215 +2 -2 + NTP_4_2_7P395 + + ntpdc/ntpdc.html@1.228 +3 -3 + NTP_4_2_7P395 + + ntpdc/ntpdc.man.in@1.215 +2 -2 + NTP_4_2_7P395 + + ntpdc/ntpdc.mdoc.in@1.215 +2 -2 + NTP_4_2_7P395 + + ntpq/invoke-ntpq.texi@1.388 +3 -3 + NTP_4_2_7P395 + + ntpq/ntpq-opts.c@1.402 +10 -9 + NTP_4_2_7P395 + + ntpq/ntpq-opts.h@1.402 +3 -3 + NTP_4_2_7P395 + + ntpq/ntpq.1ntpqman@1.216 +2 -2 + NTP_4_2_7P395 + + ntpq/ntpq.1ntpqmdoc@1.216 +2 -2 + NTP_4_2_7P395 + + ntpq/ntpq.html@1.60 +2 -2 + NTP_4_2_7P395 + + ntpq/ntpq.man.in@1.216 +2 -2 + NTP_4_2_7P395 + + ntpq/ntpq.mdoc.in@1.216 +2 -2 + NTP_4_2_7P395 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.387 +3 -3 + NTP_4_2_7P395 + + ntpsnmpd/ntpsnmpd-opts.c@1.402 +10 -9 + NTP_4_2_7P395 + + ntpsnmpd/ntpsnmpd-opts.h@1.402 +3 -3 + NTP_4_2_7P395 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.216 +3 -3 + NTP_4_2_7P395 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.216 +3 -3 + NTP_4_2_7P395 + + ntpsnmpd/ntpsnmpd.html@1.58 +1 -1 + NTP_4_2_7P395 + + ntpsnmpd/ntpsnmpd.man.in@1.216 +3 -3 + NTP_4_2_7P395 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.216 +3 -3 + NTP_4_2_7P395 + + packageinfo.sh@1.398 +1 -1 + NTP_4_2_7P395 + + scripts/invoke-ntp-wait.texi@1.204 +3 -3 + NTP_4_2_7P395 + + scripts/ntp-wait.1ntp-waitman@1.215 +3 -3 + NTP_4_2_7P395 + + scripts/ntp-wait.1ntp-waitmdoc@1.215 +3 -3 + NTP_4_2_7P395 + + scripts/ntp-wait.html@1.220 +3 -3 + NTP_4_2_7P395 + + scripts/ntp-wait.man.in@1.215 +3 -3 + NTP_4_2_7P395 + + scripts/ntp-wait.mdoc.in@1.215 +3 -3 + NTP_4_2_7P395 + + sntp/invoke-sntp.texi@1.384 +15 -13 + NTP_4_2_7P395 + + sntp/sntp-opts.c@1.399 +10 -9 + NTP_4_2_7P395 + + sntp/sntp-opts.h@1.399 +3 -3 + NTP_4_2_7P395 + + sntp/sntp.1sntpman@1.219 +3 -3 + NTP_4_2_7P395 + + sntp/sntp.1sntpmdoc@1.219 +3 -3 + NTP_4_2_7P395 + + sntp/sntp.html@1.399 +14 -13 + NTP_4_2_7P395 + + sntp/sntp.man.in@1.219 +3 -3 + NTP_4_2_7P395 + + sntp/sntp.mdoc.in@1.219 +3 -3 + NTP_4_2_7P395 + + util/invoke-ntp-keygen.texi@1.388 +14 -14 + NTP_4_2_7P395 + + util/ntp-keygen-opts.c@1.402 +10 -9 + NTP_4_2_7P395 + + util/ntp-keygen-opts.h@1.402 +3 -3 + NTP_4_2_7P395 + + util/ntp-keygen.1ntp-keygenman@1.216 +3 -3 + NTP_4_2_7P395 + + util/ntp-keygen.1ntp-keygenmdoc@1.216 +3 -3 + NTP_4_2_7P395 + + util/ntp-keygen.html@1.64 +2 -2 + NTP_4_2_7P395 + + util/ntp-keygen.man.in@1.216 +3 -3 + NTP_4_2_7P395 + + util/ntp-keygen.mdoc.in@1.216 +3 -3 + NTP_4_2_7P395 + +ChangeSet@1.3004, 2013-11-12 08:16:16+00:00, stenn@psp-fb1.ntp.org + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + ChangeLog@1.1350 +1 -0 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/include/autogen-version.def@1.19 +2 -2 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/Makefile.am@1.23 +4 -4 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/ag-char-map.h@1.26 +2 -3 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/ao-strs.c@1.12 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/ao-strs.h@1.11 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/autoopts/options.h@1.25 +51 -51 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/autoopts/usage-txt.h@1.25 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/compat/compat.h@1.14 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/genshell.c@1.26 +49 -48 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/genshell.h@1.26 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/m4/libopts.m4@1.29 +1 -2 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/option-value-type.c@1.13 +2 -2 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/option-value-type.h@1.27 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/option-xat-attribute.c@1.13 +2 -2 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/option-xat-attribute.h@1.27 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + + sntp/libopts/proto.h@1.26 +1 -1 + Upgrade to autogen-5.18.3pre5 and libopts-40.1.15 + +ChangeSet@1.3003, 2013-11-05 11:37:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P394 + TAG: NTP_4_2_7P394 + + ChangeLog@1.1349 +1 -0 + NTP_4_2_7P394 + + ntpd/invoke-ntp.conf.texi@1.72 +1 -1 + NTP_4_2_7P394 + + ntpd/invoke-ntp.keys.texi@1.70 +1 -1 + NTP_4_2_7P394 + + ntpd/invoke-ntpd.texi@1.386 +2 -2 + NTP_4_2_7P394 + + ntpd/ntp.conf.5man@1.106 +3 -3 + NTP_4_2_7P394 + + ntpd/ntp.conf.5mdoc@1.106 +3 -3 + NTP_4_2_7P394 + + ntpd/ntp.conf.html@1.67 +1 -1 + NTP_4_2_7P394 + + ntpd/ntp.conf.man.in@1.106 +3 -3 + NTP_4_2_7P394 + + ntpd/ntp.conf.mdoc.in@1.106 +3 -3 + NTP_4_2_7P394 + + ntpd/ntp.keys.5man@1.104 +3 -3 + NTP_4_2_7P394 + + ntpd/ntp.keys.5mdoc@1.104 +3 -3 + NTP_4_2_7P394 + + ntpd/ntp.keys.html@1.68 +1 -1 + NTP_4_2_7P394 + + ntpd/ntp.keys.man.in@1.104 +3 -3 + NTP_4_2_7P394 + + ntpd/ntp.keys.mdoc.in@1.104 +3 -3 + NTP_4_2_7P394 + + ntpd/ntpd-opts.c@1.404 +7 -7 + NTP_4_2_7P394 + + ntpd/ntpd-opts.h@1.404 +3 -3 + NTP_4_2_7P394 + + ntpd/ntpd.1ntpdman@1.215 +3 -3 + NTP_4_2_7P394 + + ntpd/ntpd.1ntpdmdoc@1.215 +3 -3 + NTP_4_2_7P394 + + ntpd/ntpd.html@1.62 +2 -2 + NTP_4_2_7P394 + + ntpd/ntpd.man.in@1.215 +3 -3 + NTP_4_2_7P394 + + ntpd/ntpd.mdoc.in@1.215 +3 -3 + NTP_4_2_7P394 + + ntpdc/invoke-ntpdc.texi@1.383 +2 -2 + NTP_4_2_7P394 + + ntpdc/ntpdc-opts.c@1.398 +7 -7 + NTP_4_2_7P394 + + ntpdc/ntpdc-opts.h@1.398 +3 -3 + NTP_4_2_7P394 + + ntpdc/ntpdc.1ntpdcman@1.214 +2 -2 + NTP_4_2_7P394 + + ntpdc/ntpdc.1ntpdcmdoc@1.214 +2 -2 + NTP_4_2_7P394 + + ntpdc/ntpdc.html@1.227 +2 -2 + NTP_4_2_7P394 + + ntpdc/ntpdc.man.in@1.214 +2 -2 + NTP_4_2_7P394 + + ntpdc/ntpdc.mdoc.in@1.214 +2 -2 + NTP_4_2_7P394 + + ntpq/invoke-ntpq.texi@1.387 +2 -2 + NTP_4_2_7P394 + + ntpq/ntpq-opts.c@1.401 +7 -7 + NTP_4_2_7P394 + + ntpq/ntpq-opts.h@1.401 +3 -3 + NTP_4_2_7P394 + + ntpq/ntpq.1ntpqman@1.215 +2 -2 + NTP_4_2_7P394 + + ntpq/ntpq.1ntpqmdoc@1.215 +2 -2 + NTP_4_2_7P394 + + ntpq/ntpq.html@1.59 +2 -2 + NTP_4_2_7P394 + + ntpq/ntpq.man.in@1.215 +2 -2 + NTP_4_2_7P394 + + ntpq/ntpq.mdoc.in@1.215 +2 -2 + NTP_4_2_7P394 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.386 +2 -2 + NTP_4_2_7P394 + + ntpsnmpd/ntpsnmpd-opts.c@1.401 +7 -7 + NTP_4_2_7P394 + + ntpsnmpd/ntpsnmpd-opts.h@1.401 +3 -3 + NTP_4_2_7P394 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.215 +3 -3 + NTP_4_2_7P394 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.215 +3 -3 + NTP_4_2_7P394 + + ntpsnmpd/ntpsnmpd.html@1.57 +1 -1 + NTP_4_2_7P394 + + ntpsnmpd/ntpsnmpd.man.in@1.215 +3 -3 + NTP_4_2_7P394 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.215 +3 -3 + NTP_4_2_7P394 + + packageinfo.sh@1.397 +1 -1 + NTP_4_2_7P394 + + scripts/invoke-ntp-wait.texi@1.203 +14 -2 + NTP_4_2_7P394 + + scripts/ntp-wait.1ntp-waitman@1.214 +3 -3 + NTP_4_2_7P394 + + scripts/ntp-wait.1ntp-waitmdoc@1.214 +3 -3 + NTP_4_2_7P394 + + scripts/ntp-wait.html@1.219 +14 -2 + NTP_4_2_7P394 + + scripts/ntp-wait.man.in@1.214 +3 -3 + NTP_4_2_7P394 + + scripts/ntp-wait.mdoc.in@1.214 +3 -3 + NTP_4_2_7P394 + + sntp/invoke-sntp.texi@1.383 +2 -2 + NTP_4_2_7P394 + + sntp/sntp-opts.c@1.398 +7 -7 + NTP_4_2_7P394 + + sntp/sntp-opts.h@1.398 +3 -3 + NTP_4_2_7P394 + + sntp/sntp.1sntpman@1.218 +3 -3 + NTP_4_2_7P394 + + sntp/sntp.1sntpmdoc@1.218 +3 -3 + NTP_4_2_7P394 + + sntp/sntp.html@1.398 +2 -2 + NTP_4_2_7P394 + + sntp/sntp.man.in@1.218 +3 -3 + NTP_4_2_7P394 + + sntp/sntp.mdoc.in@1.218 +3 -3 + NTP_4_2_7P394 + + util/invoke-ntp-keygen.texi@1.387 +2 -2 + NTP_4_2_7P394 + + util/ntp-keygen-opts.c@1.401 +7 -7 + NTP_4_2_7P394 + + util/ntp-keygen-opts.h@1.401 +3 -3 + NTP_4_2_7P394 + + util/ntp-keygen.1ntp-keygenman@1.215 +3 -3 + NTP_4_2_7P394 + + util/ntp-keygen.1ntp-keygenmdoc@1.215 +3 -3 + NTP_4_2_7P394 + + util/ntp-keygen.html@1.63 +2 -2 + NTP_4_2_7P394 + + util/ntp-keygen.man.in@1.215 +3 -3 + NTP_4_2_7P394 + + util/ntp-keygen.mdoc.in@1.215 +3 -3 + NTP_4_2_7P394 + +ChangeSet@1.2996.4.1, 2013-11-02 16:14:35+01:00, jnperlin@nemesis.localnet + [Bug 2499] Win32 user-space/loopback ppsapi provider drops samples. + + ChangeLog@1.1346.2.1 +1 -0 + [Bug 2499] Win32 user-space/loopback ppsapi provider drops samples. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.70 +29 -29 + [Bug 2499] Win32 user-space/loopback ppsapi provider drops samples. + Caused by FIFO buffer access logic. + +ChangeSet@1.2996.3.1, 2013-11-01 10:37:27+01:00, jnperlin@nemesis.localnet + [Bug 2272] (update) Use C99 integer types. + + include/ntp_calendar.h@1.13 +76 -76 + [Bug 2272] (update) Use C99 integer types. Consequently, not for just u_char. + + libntp/caljulian.c@1.15 +1 -1 + [Bug 2272] (update) Use C99 integer types. + + libntp/caltontp.c@1.6 +3 -3 + [Bug 2272] (update) Use C99 integer types. + + libntp/ntp_calendar.c@1.11 +157 -155 + [Bug 2272] (update) Use C99 integer types. Consequently, not for just u_char. + + ports/winnt/include/config.h@1.105 +0 -5 + [Bug 2272] (update) Use C99 integer types. + Avoid including stdint/stdtypes from inside the config header. + + ports/winnt/include/stdint.h@1.1 +244 -0 + [Bug 2272] (update) Use C99 integer types. + Provide a C99 compatible for local use if the compiler comes without one. + + ports/winnt/include/stdint.h@1.0 +0 -0 + +ChangeSet@1.3001, 2013-10-28 08:17:56+00:00, stenn@psp-deb1.ntp.org + [Bug 2256] Improve configure's function searches in libraries + + configure.ac@1.567 +1 -1 + [Bug 2256] Improve configure's function searches in libraries + + sntp/configure.ac@1.76 +3 -1 + [Bug 2256] Improve configure's function searches in libraries + + sntp/m4/ntp_ipv6.m4@1.8 +4 -0 + [Bug 2256] Improve configure's function searches in libraries + +ChangeSet@1.3000, 2013-10-26 09:04:23+00:00, stenn@psp-deb1.ntp.org + [Bug 2256] Improve configure's function searches in libraries + + configure.ac@1.566 +6 -12 + [Bug 2256] Improve configure's function searches in libraries + +ChangeSet@1.2996.1.7, 2013-10-25 18:32:28+02:00, jnperlin@hydra.(none) + [Bug 1050] Change ONCORE log message for leap second announcement to avoid misunderstandings. + + ChangeLog@1.1346.1.1 +2 -0 + [Bug 1050] Change ONCORE log message for leap second announcement to avoid misunderstandings. + + ntpd/refclock_oncore.c@1.99 +21 -4 + [Bug 1050] Change ONCORE log message for leap second announcement to avoid misunderstandings. + +ChangeSet@1.2998, 2013-10-17 07:15:02+00:00, stenn@psp-deb1.ntp.org + [Bug 2256] Improve configure's function searches in libraries + + ChangeLog@1.1341.1.1 +1 -0 + [Bug 2256] Improve configure's function searches in libraries + + sntp/configure.ac@1.75 +2 -0 + [Bug 2256] Improve configure's function searches in libraries + + sntp/m4/hms_search_lib.m4@1.1 +30 -0 + BitKeeper file /home/stenn/ntp-dev-2256/sntp/m4/hms_search_lib.m4 + + sntp/m4/hms_search_lib.m4@1.0 +0 -0 + + sntp/m4/ntp_libntp.m4@1.20.1.1 +9 -5 + [Bug 2256] Improve configure's function searches in libraries + +ChangeSet@1.2996.1.6, 2013-10-16 11:37:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P393 + TAG: NTP_4_2_7P393 + + ChangeLog@1.1346 +1 -0 + NTP_4_2_7P393 + + ntpd/invoke-ntp.conf.texi@1.71 +1 -1 + NTP_4_2_7P393 + + ntpd/invoke-ntp.keys.texi@1.69 +1 -1 + NTP_4_2_7P393 + + ntpd/invoke-ntpd.texi@1.385 +2 -2 + NTP_4_2_7P393 + + ntpd/ntp.conf.5man@1.105 +3 -3 + NTP_4_2_7P393 + + ntpd/ntp.conf.5mdoc@1.105 +3 -3 + NTP_4_2_7P393 + + ntpd/ntp.conf.html@1.66 +1 -1 + NTP_4_2_7P393 + + ntpd/ntp.conf.man.in@1.105 +3 -3 + NTP_4_2_7P393 + + ntpd/ntp.conf.mdoc.in@1.105 +3 -3 + NTP_4_2_7P393 + + ntpd/ntp.keys.5man@1.103 +3 -3 + NTP_4_2_7P393 + + ntpd/ntp.keys.5mdoc@1.103 +3 -3 + NTP_4_2_7P393 + + ntpd/ntp.keys.html@1.67 +1 -1 + NTP_4_2_7P393 + + ntpd/ntp.keys.man.in@1.103 +3 -3 + NTP_4_2_7P393 + + ntpd/ntp.keys.mdoc.in@1.103 +3 -3 + NTP_4_2_7P393 + + ntpd/ntpd-opts.c@1.403 +7 -7 + NTP_4_2_7P393 + + ntpd/ntpd-opts.h@1.403 +3 -3 + NTP_4_2_7P393 + + ntpd/ntpd.1ntpdman@1.214 +3 -3 + NTP_4_2_7P393 + + ntpd/ntpd.1ntpdmdoc@1.214 +3 -3 + NTP_4_2_7P393 + + ntpd/ntpd.html@1.61 +2 -2 + NTP_4_2_7P393 + + ntpd/ntpd.man.in@1.214 +3 -3 + NTP_4_2_7P393 + + ntpd/ntpd.mdoc.in@1.214 +3 -3 + NTP_4_2_7P393 + + ntpdc/invoke-ntpdc.texi@1.382 +2 -2 + NTP_4_2_7P393 + + ntpdc/ntpdc-opts.c@1.397 +7 -7 + NTP_4_2_7P393 + + ntpdc/ntpdc-opts.h@1.397 +3 -3 + NTP_4_2_7P393 + + ntpdc/ntpdc.1ntpdcman@1.213 +2 -2 + NTP_4_2_7P393 + + ntpdc/ntpdc.1ntpdcmdoc@1.213 +2 -2 + NTP_4_2_7P393 + + ntpdc/ntpdc.html@1.226 +2 -2 + NTP_4_2_7P393 + + ntpdc/ntpdc.man.in@1.213 +2 -2 + NTP_4_2_7P393 + + ntpdc/ntpdc.mdoc.in@1.213 +2 -2 + NTP_4_2_7P393 + + ntpq/invoke-ntpq.texi@1.386 +2 -2 + NTP_4_2_7P393 + + ntpq/ntpq-opts.c@1.400 +7 -7 + NTP_4_2_7P393 + + ntpq/ntpq-opts.h@1.400 +3 -3 + NTP_4_2_7P393 + + ntpq/ntpq.1ntpqman@1.214 +2 -2 + NTP_4_2_7P393 + + ntpq/ntpq.1ntpqmdoc@1.214 +2 -2 + NTP_4_2_7P393 + + ntpq/ntpq.html@1.58 +2 -2 + NTP_4_2_7P393 + + ntpq/ntpq.man.in@1.214 +2 -2 + NTP_4_2_7P393 + + ntpq/ntpq.mdoc.in@1.214 +2 -2 + NTP_4_2_7P393 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.385 +2 -2 + NTP_4_2_7P393 + + ntpsnmpd/ntpsnmpd-opts.c@1.400 +7 -7 + NTP_4_2_7P393 + + ntpsnmpd/ntpsnmpd-opts.h@1.400 +3 -3 + NTP_4_2_7P393 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.214 +3 -3 + NTP_4_2_7P393 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.214 +3 -3 + NTP_4_2_7P393 + + ntpsnmpd/ntpsnmpd.html@1.56 +1 -1 + NTP_4_2_7P393 + + ntpsnmpd/ntpsnmpd.man.in@1.214 +3 -3 + NTP_4_2_7P393 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.214 +3 -3 + NTP_4_2_7P393 + + packageinfo.sh@1.396 +1 -1 + NTP_4_2_7P393 + + scripts/invoke-ntp-wait.texi@1.202 +1 -1 + NTP_4_2_7P393 + + scripts/ntp-wait.1ntp-waitman@1.213 +3 -3 + NTP_4_2_7P393 + + scripts/ntp-wait.1ntp-waitmdoc@1.213 +3 -3 + NTP_4_2_7P393 + + scripts/ntp-wait.html@1.218 +1 -1 + NTP_4_2_7P393 + + scripts/ntp-wait.man.in@1.213 +3 -3 + NTP_4_2_7P393 + + scripts/ntp-wait.mdoc.in@1.213 +3 -3 + NTP_4_2_7P393 + + sntp/invoke-sntp.texi@1.382 +2 -2 + NTP_4_2_7P393 + + sntp/sntp-opts.c@1.397 +7 -7 + NTP_4_2_7P393 + + sntp/sntp-opts.h@1.397 +3 -3 + NTP_4_2_7P393 + + sntp/sntp.1sntpman@1.217 +3 -3 + NTP_4_2_7P393 + + sntp/sntp.1sntpmdoc@1.217 +3 -3 + NTP_4_2_7P393 + + sntp/sntp.html@1.397 +2 -2 + NTP_4_2_7P393 + + sntp/sntp.man.in@1.217 +3 -3 + NTP_4_2_7P393 + + sntp/sntp.mdoc.in@1.217 +3 -3 + NTP_4_2_7P393 + + util/invoke-ntp-keygen.texi@1.386 +2 -2 + NTP_4_2_7P393 + + util/ntp-keygen-opts.c@1.400 +7 -7 + NTP_4_2_7P393 + + util/ntp-keygen-opts.h@1.400 +3 -3 + NTP_4_2_7P393 + + util/ntp-keygen.1ntp-keygenman@1.214 +3 -3 + NTP_4_2_7P393 + + util/ntp-keygen.1ntp-keygenmdoc@1.214 +3 -3 + NTP_4_2_7P393 + + util/ntp-keygen.html@1.62 +2 -2 + NTP_4_2_7P393 + + util/ntp-keygen.man.in@1.214 +3 -3 + NTP_4_2_7P393 + + util/ntp-keygen.mdoc.in@1.214 +3 -3 + NTP_4_2_7P393 + +ChangeSet@1.2996.1.5, 2013-10-16 08:45:10+00:00, stenn@hikaru.il.thewrittenword.com + [Bug 2272] Use c99 integer types: ntp_calendar.h, ntp_types.h + + ChangeLog@1.1345 +1 -0 + [Bug 2272] Use c99 integer types: ntp_calendar.h, ntp_types.h + + include/ntp_calendar.h@1.12 +14 -14 + [Bug 2272] Use c99 integer types: ntp_calendar.h, ntp_types.h + + include/ntp_types.h@1.33 +13 -8 + [Bug 2272] Use c99 integer types: ntp_calendar.h, ntp_types.h + +ChangeSet@1.2996.1.4, 2013-10-15 11:35:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P392 + TAG: NTP_4_2_7P392 + + ChangeLog@1.1344 +1 -0 + NTP_4_2_7P392 + + ntpd/invoke-ntp.conf.texi@1.70 +1 -1 + NTP_4_2_7P392 + + ntpd/invoke-ntp.keys.texi@1.68 +1 -1 + NTP_4_2_7P392 + + ntpd/invoke-ntpd.texi@1.384 +2 -2 + NTP_4_2_7P392 + + ntpd/ntp.conf.5man@1.104 +3 -3 + NTP_4_2_7P392 + + ntpd/ntp.conf.5mdoc@1.104 +3 -3 + NTP_4_2_7P392 + + ntpd/ntp.conf.html@1.65 +1 -1 + NTP_4_2_7P392 + + ntpd/ntp.conf.man.in@1.104 +3 -3 + NTP_4_2_7P392 + + ntpd/ntp.conf.mdoc.in@1.104 +3 -3 + NTP_4_2_7P392 + + ntpd/ntp.keys.5man@1.102 +3 -3 + NTP_4_2_7P392 + + ntpd/ntp.keys.5mdoc@1.102 +3 -3 + NTP_4_2_7P392 + + ntpd/ntp.keys.html@1.66 +1 -1 + NTP_4_2_7P392 + + ntpd/ntp.keys.man.in@1.102 +3 -3 + NTP_4_2_7P392 + + ntpd/ntp.keys.mdoc.in@1.102 +3 -3 + NTP_4_2_7P392 + + ntpd/ntpd-opts.c@1.402 +7 -7 + NTP_4_2_7P392 + + ntpd/ntpd-opts.h@1.402 +3 -3 + NTP_4_2_7P392 + + ntpd/ntpd.1ntpdman@1.213 +3 -3 + NTP_4_2_7P392 + + ntpd/ntpd.1ntpdmdoc@1.213 +3 -3 + NTP_4_2_7P392 + + ntpd/ntpd.html@1.60 +2 -2 + NTP_4_2_7P392 + + ntpd/ntpd.man.in@1.213 +3 -3 + NTP_4_2_7P392 + + ntpd/ntpd.mdoc.in@1.213 +3 -3 + NTP_4_2_7P392 + + ntpdc/invoke-ntpdc.texi@1.381 +2 -2 + NTP_4_2_7P392 + + ntpdc/ntpdc-opts.c@1.396 +7 -7 + NTP_4_2_7P392 + + ntpdc/ntpdc-opts.h@1.396 +3 -3 + NTP_4_2_7P392 + + ntpdc/ntpdc.1ntpdcman@1.212 +2 -2 + NTP_4_2_7P392 + + ntpdc/ntpdc.1ntpdcmdoc@1.212 +2 -2 + NTP_4_2_7P392 + + ntpdc/ntpdc.html@1.225 +2 -2 + NTP_4_2_7P392 + + ntpdc/ntpdc.man.in@1.212 +2 -2 + NTP_4_2_7P392 + + ntpdc/ntpdc.mdoc.in@1.212 +2 -2 + NTP_4_2_7P392 + + ntpq/invoke-ntpq.texi@1.385 +2 -2 + NTP_4_2_7P392 + + ntpq/ntpq-opts.c@1.399 +7 -7 + NTP_4_2_7P392 + + ntpq/ntpq-opts.h@1.399 +3 -3 + NTP_4_2_7P392 + + ntpq/ntpq.1ntpqman@1.213 +2 -2 + NTP_4_2_7P392 + + ntpq/ntpq.1ntpqmdoc@1.213 +2 -2 + NTP_4_2_7P392 + + ntpq/ntpq.html@1.57 +2 -2 + NTP_4_2_7P392 + + ntpq/ntpq.man.in@1.213 +2 -2 + NTP_4_2_7P392 + + ntpq/ntpq.mdoc.in@1.213 +2 -2 + NTP_4_2_7P392 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.384 +2 -2 + NTP_4_2_7P392 + + ntpsnmpd/ntpsnmpd-opts.c@1.399 +7 -7 + NTP_4_2_7P392 + + ntpsnmpd/ntpsnmpd-opts.h@1.399 +3 -3 + NTP_4_2_7P392 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.213 +3 -3 + NTP_4_2_7P392 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.213 +3 -3 + NTP_4_2_7P392 + + ntpsnmpd/ntpsnmpd.html@1.55 +1 -1 + NTP_4_2_7P392 + + ntpsnmpd/ntpsnmpd.man.in@1.213 +3 -3 + NTP_4_2_7P392 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.213 +3 -3 + NTP_4_2_7P392 + + packageinfo.sh@1.395 +1 -1 + NTP_4_2_7P392 + + scripts/invoke-ntp-wait.texi@1.201 +1 -1 + NTP_4_2_7P392 + + scripts/ntp-wait.1ntp-waitman@1.212 +3 -3 + NTP_4_2_7P392 + + scripts/ntp-wait.1ntp-waitmdoc@1.212 +3 -3 + NTP_4_2_7P392 + + scripts/ntp-wait.html@1.217 +1 -1 + NTP_4_2_7P392 + + scripts/ntp-wait.man.in@1.212 +3 -3 + NTP_4_2_7P392 + + scripts/ntp-wait.mdoc.in@1.212 +3 -3 + NTP_4_2_7P392 + + sntp/invoke-sntp.texi@1.381 +2 -2 + NTP_4_2_7P392 + + sntp/sntp-opts.c@1.396 +7 -7 + NTP_4_2_7P392 + + sntp/sntp-opts.h@1.396 +3 -3 + NTP_4_2_7P392 + + sntp/sntp.1sntpman@1.216 +3 -3 + NTP_4_2_7P392 + + sntp/sntp.1sntpmdoc@1.216 +3 -3 + NTP_4_2_7P392 + + sntp/sntp.html@1.396 +2 -2 + NTP_4_2_7P392 + + sntp/sntp.man.in@1.216 +3 -3 + NTP_4_2_7P392 + + sntp/sntp.mdoc.in@1.216 +3 -3 + NTP_4_2_7P392 + + util/invoke-ntp-keygen.texi@1.385 +2 -2 + NTP_4_2_7P392 + + util/ntp-keygen-opts.c@1.399 +7 -7 + NTP_4_2_7P392 + + util/ntp-keygen-opts.h@1.399 +3 -3 + NTP_4_2_7P392 + + util/ntp-keygen.1ntp-keygenman@1.213 +3 -3 + NTP_4_2_7P392 + + util/ntp-keygen.1ntp-keygenmdoc@1.213 +3 -3 + NTP_4_2_7P392 + + util/ntp-keygen.html@1.61 +2 -2 + NTP_4_2_7P392 + + util/ntp-keygen.man.in@1.213 +3 -3 + NTP_4_2_7P392 + + util/ntp-keygen.mdoc.in@1.213 +3 -3 + NTP_4_2_7P392 + +ChangeSet@1.2996.1.3, 2013-10-15 03:16:55-07:00, harlan@hms-mbp11.local + [Bug 2375] Improve AIX compatibility + + ChangeLog@1.1343 +1 -0 + [Bug 2375] Improve AIX compatibility + + configure.ac@1.563.1.2 +10 -5 + [Bug 2375] Improve AIX compatibility + + sntp/m4/ntp_libntp.m4@1.21 +6 -3 + [Bug 2375] Improve AIX compatibility + + sntp/m4/os_cflags.m4@1.9 +6 -1 + [Bug 2375] Improve AIX compatibility + +ChangeSet@1.2996.2.1, 2013-10-14 21:11:05+02:00, jnperlin@hydra.localnet + [Bug 2490] Fixed non-const initializer introduced with [Bug 2250] fix. + + ChangeLog@1.1342 +1 -0 + [Bug 2490] Fixed non-const initializer introduced with [Bug 2250] fix. + + ntpd/ntp_control.c@1.187 +4 -4 + [Bug 2490] Fixed non-const initializer introduced with [Bug 2250] fix. + +ChangeSet@1.2996.1.1, 2013-10-13 17:43:29-07:00, harlan@hms-mbp11.local + Fix comments and netbsd patterns in configure.ac + + configure.ac@1.563.1.1 +14 -14 + Fix comments and netbsd patterns in configure.ac + +ChangeSet@1.2990.1.1, 2013-10-13 09:26:49+00:00, stenn@psp-fb1.ntp.org + Prep for fixing bug 2256 + + configure.ac@1.562.1.1 +9 -0 + Prep for fixing bug 2256 + + sntp/configure.ac@1.74 +6 -1 + Prep for fixing bug 2256 + +ChangeSet@1.2996, 2013-10-12 11:26:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P391 + TAG: NTP_4_2_7P391 + + ChangeLog@1.1341 +1 -0 + NTP_4_2_7P391 + + ntpd/invoke-ntp.conf.texi@1.69 +1 -1 + NTP_4_2_7P391 + + ntpd/invoke-ntp.keys.texi@1.67 +1 -1 + NTP_4_2_7P391 + + ntpd/invoke-ntpd.texi@1.383 +2 -2 + NTP_4_2_7P391 + + ntpd/ntp.conf.5man@1.103 +3 -3 + NTP_4_2_7P391 + + ntpd/ntp.conf.5mdoc@1.103 +3 -3 + NTP_4_2_7P391 + + ntpd/ntp.conf.html@1.64 +1 -1 + NTP_4_2_7P391 + + ntpd/ntp.conf.man.in@1.103 +3 -3 + NTP_4_2_7P391 + + ntpd/ntp.conf.mdoc.in@1.103 +3 -3 + NTP_4_2_7P391 + + ntpd/ntp.keys.5man@1.101 +3 -3 + NTP_4_2_7P391 + + ntpd/ntp.keys.5mdoc@1.101 +3 -3 + NTP_4_2_7P391 + + ntpd/ntp.keys.html@1.65 +1 -1 + NTP_4_2_7P391 + + ntpd/ntp.keys.man.in@1.101 +3 -3 + NTP_4_2_7P391 + + ntpd/ntp.keys.mdoc.in@1.101 +3 -3 + NTP_4_2_7P391 + + ntpd/ntpd-opts.c@1.401 +7 -7 + NTP_4_2_7P391 + + ntpd/ntpd-opts.h@1.401 +3 -3 + NTP_4_2_7P391 + + ntpd/ntpd.1ntpdman@1.212 +3 -3 + NTP_4_2_7P391 + + ntpd/ntpd.1ntpdmdoc@1.212 +3 -3 + NTP_4_2_7P391 + + ntpd/ntpd.html@1.59 +2 -2 + NTP_4_2_7P391 + + ntpd/ntpd.man.in@1.212 +3 -3 + NTP_4_2_7P391 + + ntpd/ntpd.mdoc.in@1.212 +3 -3 + NTP_4_2_7P391 + + ntpdc/invoke-ntpdc.texi@1.380 +2 -2 + NTP_4_2_7P391 + + ntpdc/ntpdc-opts.c@1.395 +7 -7 + NTP_4_2_7P391 + + ntpdc/ntpdc-opts.h@1.395 +3 -3 + NTP_4_2_7P391 + + ntpdc/ntpdc.1ntpdcman@1.211 +2 -2 + NTP_4_2_7P391 + + ntpdc/ntpdc.1ntpdcmdoc@1.211 +2 -2 + NTP_4_2_7P391 + + ntpdc/ntpdc.html@1.224 +2 -2 + NTP_4_2_7P391 + + ntpdc/ntpdc.man.in@1.211 +2 -2 + NTP_4_2_7P391 + + ntpdc/ntpdc.mdoc.in@1.211 +2 -2 + NTP_4_2_7P391 + + ntpq/invoke-ntpq.texi@1.384 +2 -2 + NTP_4_2_7P391 + + ntpq/ntpq-opts.c@1.398 +7 -7 + NTP_4_2_7P391 + + ntpq/ntpq-opts.h@1.398 +3 -3 + NTP_4_2_7P391 + + ntpq/ntpq.1ntpqman@1.212 +2 -2 + NTP_4_2_7P391 + + ntpq/ntpq.1ntpqmdoc@1.212 +2 -2 + NTP_4_2_7P391 + + ntpq/ntpq.html@1.56 +2 -2 + NTP_4_2_7P391 + + ntpq/ntpq.man.in@1.212 +2 -2 + NTP_4_2_7P391 + + ntpq/ntpq.mdoc.in@1.212 +2 -2 + NTP_4_2_7P391 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.383 +2 -2 + NTP_4_2_7P391 + + ntpsnmpd/ntpsnmpd-opts.c@1.398 +7 -7 + NTP_4_2_7P391 + + ntpsnmpd/ntpsnmpd-opts.h@1.398 +3 -3 + NTP_4_2_7P391 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.212 +3 -3 + NTP_4_2_7P391 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.212 +3 -3 + NTP_4_2_7P391 + + ntpsnmpd/ntpsnmpd.html@1.54 +1 -1 + NTP_4_2_7P391 + + ntpsnmpd/ntpsnmpd.man.in@1.212 +3 -3 + NTP_4_2_7P391 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.212 +3 -3 + NTP_4_2_7P391 + + packageinfo.sh@1.394 +1 -1 + NTP_4_2_7P391 + + scripts/invoke-ntp-wait.texi@1.200 +2 -14 + NTP_4_2_7P391 + + scripts/ntp-wait.1ntp-waitman@1.211 +3 -3 + NTP_4_2_7P391 + + scripts/ntp-wait.1ntp-waitmdoc@1.211 +3 -3 + NTP_4_2_7P391 + + scripts/ntp-wait.html@1.216 +2 -14 + NTP_4_2_7P391 + + scripts/ntp-wait.man.in@1.211 +3 -3 + NTP_4_2_7P391 + + scripts/ntp-wait.mdoc.in@1.211 +3 -3 + NTP_4_2_7P391 + + sntp/invoke-sntp.texi@1.380 +2 -2 + NTP_4_2_7P391 + + sntp/sntp-opts.c@1.395 +7 -7 + NTP_4_2_7P391 + + sntp/sntp-opts.h@1.395 +3 -3 + NTP_4_2_7P391 + + sntp/sntp.1sntpman@1.215 +3 -3 + NTP_4_2_7P391 + + sntp/sntp.1sntpmdoc@1.215 +3 -3 + NTP_4_2_7P391 + + sntp/sntp.html@1.395 +2 -2 + NTP_4_2_7P391 + + sntp/sntp.man.in@1.215 +3 -3 + NTP_4_2_7P391 + + sntp/sntp.mdoc.in@1.215 +3 -3 + NTP_4_2_7P391 + + util/invoke-ntp-keygen.texi@1.384 +2 -2 + NTP_4_2_7P391 + + util/ntp-keygen-opts.c@1.398 +7 -7 + NTP_4_2_7P391 + + util/ntp-keygen-opts.h@1.398 +3 -3 + NTP_4_2_7P391 + + util/ntp-keygen.1ntp-keygenman@1.212 +3 -3 + NTP_4_2_7P391 + + util/ntp-keygen.1ntp-keygenmdoc@1.212 +3 -3 + NTP_4_2_7P391 + + util/ntp-keygen.html@1.60 +2 -2 + NTP_4_2_7P391 + + util/ntp-keygen.man.in@1.212 +3 -3 + NTP_4_2_7P391 + + util/ntp-keygen.mdoc.in@1.212 +3 -3 + NTP_4_2_7P391 + +ChangeSet@1.2991.1.1, 2013-10-06 15:06:40+02:00, jnperlin@hydra.localnet + [Bug 2419] [rc-nmea] Improve clockstats reporting when receiver sends data without valid GPS fix. + + ChangeLog@1.1338.1.1 +2 -0 + [Bug 2419] [rc-nmea] Improve clockstats reporting when receiver sends data without valid GPS fix. + + ntpd/refclock_nmea.c@1.72 +38 -22 + [Bug 2419] [rc-nmea] Improve clockstats reporting when receiver sends data without valid GPS fix. + +ChangeSet@1.2994, 2013-10-03 14:55:29+02:00, jnperlin@hydra.localnet + [Bug 2250] Cleanup & Win32 integration of the NTPD leapsec module + fixed handling of leap second removal + trigger logic and windows port for leap seconds + + include/ntpd.h@1.180 +1 -0 + [Bug 2250] make difference in TAI offset at next leap second globally visible + + ntpd/ntp_crypto.c@1.165 +2 -2 + [Bug 2250] some argument reordering in leapsec module for clearer code + + ntpd/ntp_leapsec.c@1.3 +137 -87 + [Bug 2250] further cleanup & MSVC warning issues + better support for Win32 clock handling; + some argument reordering and more consistent naming + handling of leap second removal was buggy + some further refinements in parsing + + ntpd/ntp_leapsec.h@1.2 +55 -24 + [Bug 2250] further cleanup & MSVC warning issues; + some argument reordering + + ntpd/ntp_proto.c@1.348 +3 -3 + [Bug 2250] reset leap frame by API function + some argument reordering in leapsec module for clearer code + + ntpd/ntp_timer.c@1.74 +35 -27 + [Bug 2250] let windows clock stuff decide how to handle a leap second + separation of concerns + fix trigger logic for leap events + + ntpd/ntp_util.c@1.104 +1 -5 + [Bug 2250] use proper leapsec function to read file + + ports/winnt/ntpd/nt_clockstuff.c@1.61 +43 -48 + [Bug 2250] use NTPD's leapsec module to decide when leap seconds occur + fix offset NTP vs FILETIME (don't trust constants you haven't calculated yourself...) + + ports/winnt/vs2005/ntpd.vcproj@1.19 +8 -0 + [Bug 2250] add ntp_leapsec.* to build + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.46 +8 -0 + [Bug 2250] add ntp_leapsec.* to build + + tests/ntpd/leapsec.cpp@1.2 +246 -85 + [Bug 2250] some argument reordering in leapsec module for clearer code + removed some irrelevant checks + added a (faked) leap second deleteion table and test cases + +ChangeSet@1.2993, 2013-09-28 08:43:01+02:00, jnperlin@hydra.localnet + [Bug 2250] minor cleanup + + ntpd/ntp_leapsec.c@1.2 +25 -18 + [Bug 2250] minor cleanup + +ChangeSet@1.2985.2.1, 2013-09-27 20:37:04+02:00, jnperlin@hydra.localnet + [Bug 2250] Rework of leap second handling machine + + ChangeLog@1.1333.2.1 +1 -0 + [Bug 2250] Rework of leap second handling machine + + configure.ac@1.561.1.1 +1 -0 + [Bug 2250] add unit test dir for NTPD modules + + include/ntpd.h@1.179 +1 -6 + [Bug 2250] removed global values that went into leap second handling module + + ntpd/Makefile.am@1.128 +5 -1 + [Bug 2250] add references to 'ntp_leapsec.[ch]' + + ntpd/ntp_control.c@1.186 +17 -10 + [Bug 2250] rewired to 'ntp_leapsec' + + ntpd/ntp_crypto.c@1.164 +18 -12 + [Bug 2250] rewired to 'ntp_leapsec' + + ntpd/ntp_leapsec.c@1.1 +899 -0 + [Bug 2250] new module for leap second processing + + ntpd/ntp_leapsec.c@1.0 +0 -0 + + ntpd/ntp_leapsec.h@1.1 +165 -0 + [Bug 2250] new module for leap second processing + + ntpd/ntp_leapsec.h@1.0 +0 -0 + + ntpd/ntp_proto.c@1.347 +31 -40 + [Bug 2250] rewired to 'ntp_leapsec' + + ntpd/ntp_timer.c@1.73 +103 -47 + [Bug 2250] rewired to 'ntp_leapsec' + + ntpd/ntp_util.c@1.103 +24 -124 + [Bug 2250] rewired to 'ntp_leapsec' + + tests/Makefile.am@1.5 +4 -1 + [Bug 2250] subdir references to unit test for NTPD modules + + tests/ntpd/Makefile.am@1.1 +55 -0 + [Bug 2250] unit test support + + tests/ntpd/Makefile.am@1.0 +0 -0 + + tests/ntpd/leapsec.cpp@1.1 +568 -0 + [Bug 2250] unit test for leap second machine + + tests/ntpd/leapsec.cpp@1.0 +0 -0 + + tests/ntpd/ntpdtest.cpp@1.1 +27 -0 + [Bug 2250] unit test support + + tests/ntpd/ntpdtest.cpp@1.0 +0 -0 + + tests/ntpd/ntpdtest.h@1.1 +15 -0 + [Bug 2250] unit test support + + tests/ntpd/ntpdtest.h@1.0 +0 -0 + +ChangeSet@1.2991, 2013-09-26 11:37:35+00:00, stenn@deacon.udel.edu + NTP_4_2_7P390 + TAG: NTP_4_2_7P390 + + ChangeLog@1.1338 +1 -0 + NTP_4_2_7P390 + + ntpd/invoke-ntp.conf.texi@1.68 +1 -1 + NTP_4_2_7P390 + + ntpd/invoke-ntp.keys.texi@1.66 +1 -1 + NTP_4_2_7P390 + + ntpd/invoke-ntpd.texi@1.382 +2 -2 + NTP_4_2_7P390 + + ntpd/ntp.conf.5man@1.102 +3 -3 + NTP_4_2_7P390 + + ntpd/ntp.conf.5mdoc@1.102 +3 -3 + NTP_4_2_7P390 + + ntpd/ntp.conf.html@1.63 +1 -1 + NTP_4_2_7P390 + + ntpd/ntp.conf.man.in@1.102 +3 -3 + NTP_4_2_7P390 + + ntpd/ntp.conf.mdoc.in@1.102 +3 -3 + NTP_4_2_7P390 + + ntpd/ntp.keys.5man@1.100 +3 -3 + NTP_4_2_7P390 + + ntpd/ntp.keys.5mdoc@1.100 +3 -3 + NTP_4_2_7P390 + + ntpd/ntp.keys.html@1.64 +1 -1 + NTP_4_2_7P390 + + ntpd/ntp.keys.man.in@1.100 +3 -3 + NTP_4_2_7P390 + + ntpd/ntp.keys.mdoc.in@1.100 +3 -3 + NTP_4_2_7P390 + + ntpd/ntpd-opts.c@1.400 +7 -7 + NTP_4_2_7P390 + + ntpd/ntpd-opts.h@1.400 +3 -3 + NTP_4_2_7P390 + + ntpd/ntpd.1ntpdman@1.211 +3 -3 + NTP_4_2_7P390 + + ntpd/ntpd.1ntpdmdoc@1.211 +3 -3 + NTP_4_2_7P390 + + ntpd/ntpd.html@1.58 +8 -8 + NTP_4_2_7P390 + + ntpd/ntpd.man.in@1.211 +3 -3 + NTP_4_2_7P390 + + ntpd/ntpd.mdoc.in@1.211 +3 -3 + NTP_4_2_7P390 + + ntpdc/invoke-ntpdc.texi@1.379 +2 -2 + NTP_4_2_7P390 + + ntpdc/ntpdc-opts.c@1.394 +7 -7 + NTP_4_2_7P390 + + ntpdc/ntpdc-opts.h@1.394 +3 -3 + NTP_4_2_7P390 + + ntpdc/ntpdc.1ntpdcman@1.210 +2 -2 + NTP_4_2_7P390 + + ntpdc/ntpdc.1ntpdcmdoc@1.210 +2 -2 + NTP_4_2_7P390 + + ntpdc/ntpdc.html@1.223 +2 -2 + NTP_4_2_7P390 + + ntpdc/ntpdc.man.in@1.210 +2 -2 + NTP_4_2_7P390 + + ntpdc/ntpdc.mdoc.in@1.210 +2 -2 + NTP_4_2_7P390 + + ntpq/invoke-ntpq.texi@1.383 +2 -2 + NTP_4_2_7P390 + + ntpq/ntpq-opts.c@1.397 +7 -7 + NTP_4_2_7P390 + + ntpq/ntpq-opts.h@1.397 +3 -3 + NTP_4_2_7P390 + + ntpq/ntpq.1ntpqman@1.211 +2 -2 + NTP_4_2_7P390 + + ntpq/ntpq.1ntpqmdoc@1.211 +2 -2 + NTP_4_2_7P390 + + ntpq/ntpq.html@1.55 +2 -2 + NTP_4_2_7P390 + + ntpq/ntpq.man.in@1.211 +2 -2 + NTP_4_2_7P390 + + ntpq/ntpq.mdoc.in@1.211 +2 -2 + NTP_4_2_7P390 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.382 +2 -2 + NTP_4_2_7P390 + + ntpsnmpd/ntpsnmpd-opts.c@1.397 +7 -7 + NTP_4_2_7P390 + + ntpsnmpd/ntpsnmpd-opts.h@1.397 +3 -3 + NTP_4_2_7P390 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.211 +3 -3 + NTP_4_2_7P390 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.211 +3 -3 + NTP_4_2_7P390 + + ntpsnmpd/ntpsnmpd.html@1.53 +1 -1 + NTP_4_2_7P390 + + ntpsnmpd/ntpsnmpd.man.in@1.211 +3 -3 + NTP_4_2_7P390 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.211 +3 -3 + NTP_4_2_7P390 + + packageinfo.sh@1.393 +1 -1 + NTP_4_2_7P390 + + scripts/invoke-ntp-wait.texi@1.199 +1 -1 + NTP_4_2_7P390 + + scripts/ntp-wait.1ntp-waitman@1.210 +3 -3 + NTP_4_2_7P390 + + scripts/ntp-wait.1ntp-waitmdoc@1.210 +3 -3 + NTP_4_2_7P390 + + scripts/ntp-wait.html@1.215 +1 -1 + NTP_4_2_7P390 + + scripts/ntp-wait.man.in@1.210 +3 -3 + NTP_4_2_7P390 + + scripts/ntp-wait.mdoc.in@1.210 +3 -3 + NTP_4_2_7P390 + + sntp/invoke-sntp.texi@1.379 +2 -2 + NTP_4_2_7P390 + + sntp/sntp-opts.c@1.394 +7 -7 + NTP_4_2_7P390 + + sntp/sntp-opts.h@1.394 +3 -3 + NTP_4_2_7P390 + + sntp/sntp.1sntpman@1.214 +3 -3 + NTP_4_2_7P390 + + sntp/sntp.1sntpmdoc@1.214 +3 -3 + NTP_4_2_7P390 + + sntp/sntp.html@1.394 +2 -2 + NTP_4_2_7P390 + + sntp/sntp.man.in@1.214 +3 -3 + NTP_4_2_7P390 + + sntp/sntp.mdoc.in@1.214 +3 -3 + NTP_4_2_7P390 + + util/invoke-ntp-keygen.texi@1.383 +2 -2 + NTP_4_2_7P390 + + util/ntp-keygen-opts.c@1.397 +7 -7 + NTP_4_2_7P390 + + util/ntp-keygen-opts.h@1.397 +3 -3 + NTP_4_2_7P390 + + util/ntp-keygen.1ntp-keygenman@1.211 +3 -3 + NTP_4_2_7P390 + + util/ntp-keygen.1ntp-keygenmdoc@1.211 +3 -3 + NTP_4_2_7P390 + + util/ntp-keygen.html@1.59 +2 -2 + NTP_4_2_7P390 + + util/ntp-keygen.man.in@1.211 +3 -3 + NTP_4_2_7P390 + + util/ntp-keygen.mdoc.in@1.211 +3 -3 + NTP_4_2_7P390 + +ChangeSet@1.2990, 2013-09-25 08:24:34-04:00, stenn@deacon.udel.edu + [Bug 2482] Cleanup of droproot and jail support for Solaris + + ChangeLog@1.1337 +2 -1 + [Bug 2482] Cleanup of droproot and jail support for Solaris + + ntpd/ntpd.c@1.150 +1 -3 + [Bug 2482] Cleanup of droproot and jail support for Solaris + +ChangeSet@1.2989, 2013-09-24 08:54:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P389 + TAG: NTP_4_2_7P389 + + ChangeLog@1.1336 +1 -0 + NTP_4_2_7P389 + + ntpd/invoke-ntp.conf.texi@1.67 +1 -1 + NTP_4_2_7P389 + + ntpd/invoke-ntp.keys.texi@1.65 +1 -1 + NTP_4_2_7P389 + + ntpd/invoke-ntpd.texi@1.381 +8 -8 + NTP_4_2_7P389 + + ntpd/ntp.conf.5man@1.101 +3 -3 + NTP_4_2_7P389 + + ntpd/ntp.conf.5mdoc@1.101 +3 -3 + NTP_4_2_7P389 + + ntpd/ntp.conf.html@1.62 +1 -1 + NTP_4_2_7P389 + + ntpd/ntp.conf.man.in@1.101 +3 -3 + NTP_4_2_7P389 + + ntpd/ntp.conf.mdoc.in@1.101 +3 -3 + NTP_4_2_7P389 + + ntpd/ntp.keys.5man@1.99 +3 -3 + NTP_4_2_7P389 + + ntpd/ntp.keys.5mdoc@1.99 +3 -3 + NTP_4_2_7P389 + + ntpd/ntp.keys.html@1.63 +1 -1 + NTP_4_2_7P389 + + ntpd/ntp.keys.man.in@1.99 +3 -3 + NTP_4_2_7P389 + + ntpd/ntp.keys.mdoc.in@1.99 +3 -3 + NTP_4_2_7P389 + + ntpd/ntpd-opts.c@1.399 +170 -170 + NTP_4_2_7P389 + + ntpd/ntpd-opts.h@1.399 +3 -3 + NTP_4_2_7P389 + + ntpd/ntpd.1ntpdman@1.210 +7 -7 + NTP_4_2_7P389 + + ntpd/ntpd.1ntpdmdoc@1.210 +7 -7 + NTP_4_2_7P389 + + ntpd/ntpd.html@1.57 +2 -2 + NTP_4_2_7P389 + + ntpd/ntpd.man.in@1.210 +7 -7 + NTP_4_2_7P389 + + ntpd/ntpd.mdoc.in@1.210 +7 -7 + NTP_4_2_7P389 + + ntpdc/invoke-ntpdc.texi@1.378 +2 -2 + NTP_4_2_7P389 + + ntpdc/ntpdc-opts.c@1.393 +7 -7 + NTP_4_2_7P389 + + ntpdc/ntpdc-opts.h@1.393 +3 -3 + NTP_4_2_7P389 + + ntpdc/ntpdc.1ntpdcman@1.209 +2 -2 + NTP_4_2_7P389 + + ntpdc/ntpdc.1ntpdcmdoc@1.209 +2 -2 + NTP_4_2_7P389 + + ntpdc/ntpdc.html@1.222 +2 -2 + NTP_4_2_7P389 + + ntpdc/ntpdc.man.in@1.209 +2 -2 + NTP_4_2_7P389 + + ntpdc/ntpdc.mdoc.in@1.209 +2 -2 + NTP_4_2_7P389 + + ntpq/invoke-ntpq.texi@1.382 +2 -2 + NTP_4_2_7P389 + + ntpq/ntpq-opts.c@1.396 +7 -7 + NTP_4_2_7P389 + + ntpq/ntpq-opts.h@1.396 +3 -3 + NTP_4_2_7P389 + + ntpq/ntpq.1ntpqman@1.210 +2 -2 + NTP_4_2_7P389 + + ntpq/ntpq.1ntpqmdoc@1.210 +2 -2 + NTP_4_2_7P389 + + ntpq/ntpq.html@1.54 +2 -2 + NTP_4_2_7P389 + + ntpq/ntpq.man.in@1.210 +2 -2 + NTP_4_2_7P389 + + ntpq/ntpq.mdoc.in@1.210 +2 -2 + NTP_4_2_7P389 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.381 +2 -2 + NTP_4_2_7P389 + + ntpsnmpd/ntpsnmpd-opts.c@1.396 +7 -7 + NTP_4_2_7P389 + + ntpsnmpd/ntpsnmpd-opts.h@1.396 +3 -3 + NTP_4_2_7P389 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.210 +3 -3 + NTP_4_2_7P389 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.210 +3 -3 + NTP_4_2_7P389 + + ntpsnmpd/ntpsnmpd.html@1.52 +1 -1 + NTP_4_2_7P389 + + ntpsnmpd/ntpsnmpd.man.in@1.210 +3 -3 + NTP_4_2_7P389 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.210 +3 -3 + NTP_4_2_7P389 + + packageinfo.sh@1.392 +1 -1 + NTP_4_2_7P389 + + scripts/invoke-ntp-wait.texi@1.198 +1 -1 + NTP_4_2_7P389 + + scripts/ntp-wait.1ntp-waitman@1.209 +3 -3 + NTP_4_2_7P389 + + scripts/ntp-wait.1ntp-waitmdoc@1.209 +3 -3 + NTP_4_2_7P389 + + scripts/ntp-wait.html@1.214 +1 -1 + NTP_4_2_7P389 + + scripts/ntp-wait.man.in@1.209 +3 -3 + NTP_4_2_7P389 + + scripts/ntp-wait.mdoc.in@1.209 +3 -3 + NTP_4_2_7P389 + + sntp/invoke-sntp.texi@1.378 +2 -2 + NTP_4_2_7P389 + + sntp/sntp-opts.c@1.393 +7 -7 + NTP_4_2_7P389 + + sntp/sntp-opts.h@1.393 +3 -3 + NTP_4_2_7P389 + + sntp/sntp.1sntpman@1.213 +3 -3 + NTP_4_2_7P389 + + sntp/sntp.1sntpmdoc@1.213 +3 -3 + NTP_4_2_7P389 + + sntp/sntp.html@1.393 +2 -2 + NTP_4_2_7P389 + + sntp/sntp.man.in@1.213 +3 -3 + NTP_4_2_7P389 + + sntp/sntp.mdoc.in@1.213 +3 -3 + NTP_4_2_7P389 + + util/invoke-ntp-keygen.texi@1.382 +2 -2 + NTP_4_2_7P389 + + util/ntp-keygen-opts.c@1.396 +7 -7 + NTP_4_2_7P389 + + util/ntp-keygen-opts.h@1.396 +3 -3 + NTP_4_2_7P389 + + util/ntp-keygen.1ntp-keygenman@1.210 +3 -3 + NTP_4_2_7P389 + + util/ntp-keygen.1ntp-keygenmdoc@1.210 +3 -3 + NTP_4_2_7P389 + + util/ntp-keygen.html@1.58 +2 -2 + NTP_4_2_7P389 + + util/ntp-keygen.man.in@1.210 +3 -3 + NTP_4_2_7P389 + + util/ntp-keygen.mdoc.in@1.210 +3 -3 + NTP_4_2_7P389 + +ChangeSet@1.2988, 2013-09-24 04:30:55-04:00, stenn@deacon.udel.edu + #ifdef PRIV_AWARE_RESET for older Solaris for now... + + ntpd/ntpd.c@1.149 +2 -0 + #ifdef PRIV_AWARE_RESET for older Solaris for now... + +ChangeSet@1.2985.1.1, 2013-09-24 04:05:09-04:00, stenn@pogo.udel.edu + [Bug 2482] Add droproot ahd jail support for Solaris + + ChangeLog@1.1333.1.2 +1 -0 + [Bug 2482] Add droproot ahd jail support for Solaris + + ChangeLog@1.1333.1.1 +1 -0 + [Bug 2481] ntpd aborts when both user and group are specified with -u + + configure.ac@1.562 +0 -11 + [Bug 2482] Add droproot ahd jail support for Solaris + + ntpd/cmd_args.c@1.61 +4 -1 + [Bug 2481] ntpd aborts when both user and group are specified with -u + + ntpd/ntpd.c@1.148 +44 -5 + [Bug 2482] Add droproot ahd jail support for Solaris + + ntpd/ntpdbase-opts.def@1.26 +6 -6 + [Bug 2482] Add droproot ahd jail support for Solaris + + sntp/m4/ntp_libntp.m4@1.20 +37 -1 + [Bug 2482] Add droproot ahd jail support for Solaris + +ChangeSet@1.2986, 2013-09-20 13:40:43+02:00, jnperlin@hydra.localnet + [Bug 2473] revisited: Avoid possible unsigned underrun for startup condition when testing for clock backstep. + + ChangeLog@1.1334 +3 -0 + [Bug 2473] revisited: Avoid possible unsigned underrun for startup condition when testing for clock backstep. + + libntp/systime.c@1.68 +10 -2 + [Bug 2473] revisited: Avoid possible unsigned underrun for startup condition when testing for clock backstep. + +ChangeSet@1.2985, 2013-09-19 11:35:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P388 + TAG: NTP_4_2_7P388 + + ChangeLog@1.1333 +1 -0 + NTP_4_2_7P388 + + ntpd/invoke-ntp.conf.texi@1.66 +1 -1 + NTP_4_2_7P388 + + ntpd/invoke-ntp.keys.texi@1.64 +1 -1 + NTP_4_2_7P388 + + ntpd/invoke-ntpd.texi@1.380 +2 -2 + NTP_4_2_7P388 + + ntpd/ntp.conf.5man@1.100 +3 -3 + NTP_4_2_7P388 + + ntpd/ntp.conf.5mdoc@1.100 +3 -3 + NTP_4_2_7P388 + + ntpd/ntp.conf.html@1.61 +1 -1 + NTP_4_2_7P388 + + ntpd/ntp.conf.man.in@1.100 +3 -3 + NTP_4_2_7P388 + + ntpd/ntp.conf.mdoc.in@1.100 +3 -3 + NTP_4_2_7P388 + + ntpd/ntp.keys.5man@1.98 +3 -3 + NTP_4_2_7P388 + + ntpd/ntp.keys.5mdoc@1.98 +3 -3 + NTP_4_2_7P388 + + ntpd/ntp.keys.html@1.62 +1 -1 + NTP_4_2_7P388 + + ntpd/ntp.keys.man.in@1.98 +3 -3 + NTP_4_2_7P388 + + ntpd/ntp.keys.mdoc.in@1.98 +3 -3 + NTP_4_2_7P388 + + ntpd/ntpd-opts.c@1.398 +7 -7 + NTP_4_2_7P388 + + ntpd/ntpd-opts.h@1.398 +3 -3 + NTP_4_2_7P388 + + ntpd/ntpd.1ntpdman@1.209 +3 -3 + NTP_4_2_7P388 + + ntpd/ntpd.1ntpdmdoc@1.209 +3 -3 + NTP_4_2_7P388 + + ntpd/ntpd.html@1.56 +2 -2 + NTP_4_2_7P388 + + ntpd/ntpd.man.in@1.209 +3 -3 + NTP_4_2_7P388 + + ntpd/ntpd.mdoc.in@1.209 +3 -3 + NTP_4_2_7P388 + + ntpdc/invoke-ntpdc.texi@1.377 +2 -2 + NTP_4_2_7P388 + + ntpdc/ntpdc-opts.c@1.392 +7 -7 + NTP_4_2_7P388 + + ntpdc/ntpdc-opts.h@1.392 +3 -3 + NTP_4_2_7P388 + + ntpdc/ntpdc.1ntpdcman@1.208 +2 -2 + NTP_4_2_7P388 + + ntpdc/ntpdc.1ntpdcmdoc@1.208 +2 -2 + NTP_4_2_7P388 + + ntpdc/ntpdc.html@1.221 +2 -2 + NTP_4_2_7P388 + + ntpdc/ntpdc.man.in@1.208 +2 -2 + NTP_4_2_7P388 + + ntpdc/ntpdc.mdoc.in@1.208 +2 -2 + NTP_4_2_7P388 + + ntpq/invoke-ntpq.texi@1.381 +2 -2 + NTP_4_2_7P388 + + ntpq/ntpq-opts.c@1.395 +7 -7 + NTP_4_2_7P388 + + ntpq/ntpq-opts.h@1.395 +3 -3 + NTP_4_2_7P388 + + ntpq/ntpq.1ntpqman@1.209 +2 -2 + NTP_4_2_7P388 + + ntpq/ntpq.1ntpqmdoc@1.209 +2 -2 + NTP_4_2_7P388 + + ntpq/ntpq.html@1.53 +2 -2 + NTP_4_2_7P388 + + ntpq/ntpq.man.in@1.209 +2 -2 + NTP_4_2_7P388 + + ntpq/ntpq.mdoc.in@1.209 +2 -2 + NTP_4_2_7P388 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.380 +2 -2 + NTP_4_2_7P388 + + ntpsnmpd/ntpsnmpd-opts.c@1.395 +7 -7 + NTP_4_2_7P388 + + ntpsnmpd/ntpsnmpd-opts.h@1.395 +3 -3 + NTP_4_2_7P388 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.209 +3 -3 + NTP_4_2_7P388 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.209 +3 -3 + NTP_4_2_7P388 + + ntpsnmpd/ntpsnmpd.html@1.51 +1 -1 + NTP_4_2_7P388 + + ntpsnmpd/ntpsnmpd.man.in@1.209 +3 -3 + NTP_4_2_7P388 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.209 +3 -3 + NTP_4_2_7P388 + + packageinfo.sh@1.391 +1 -1 + NTP_4_2_7P388 + + scripts/invoke-ntp-wait.texi@1.197 +1 -1 + NTP_4_2_7P388 + + scripts/ntp-wait.1ntp-waitman@1.208 +3 -3 + NTP_4_2_7P388 + + scripts/ntp-wait.1ntp-waitmdoc@1.208 +3 -3 + NTP_4_2_7P388 + + scripts/ntp-wait.html@1.213 +1 -1 + NTP_4_2_7P388 + + scripts/ntp-wait.man.in@1.208 +3 -3 + NTP_4_2_7P388 + + scripts/ntp-wait.mdoc.in@1.208 +3 -3 + NTP_4_2_7P388 + + sntp/invoke-sntp.texi@1.377 +2 -2 + NTP_4_2_7P388 + + sntp/sntp-opts.c@1.392 +7 -7 + NTP_4_2_7P388 + + sntp/sntp-opts.h@1.392 +3 -3 + NTP_4_2_7P388 + + sntp/sntp.1sntpman@1.212 +3 -3 + NTP_4_2_7P388 + + sntp/sntp.1sntpmdoc@1.212 +3 -3 + NTP_4_2_7P388 + + sntp/sntp.html@1.392 +2 -2 + NTP_4_2_7P388 + + sntp/sntp.man.in@1.212 +3 -3 + NTP_4_2_7P388 + + sntp/sntp.mdoc.in@1.212 +3 -3 + NTP_4_2_7P388 + + util/invoke-ntp-keygen.texi@1.381 +2 -2 + NTP_4_2_7P388 + + util/ntp-keygen-opts.c@1.395 +7 -7 + NTP_4_2_7P388 + + util/ntp-keygen-opts.h@1.395 +3 -3 + NTP_4_2_7P388 + + util/ntp-keygen.1ntp-keygenman@1.209 +3 -3 + NTP_4_2_7P388 + + util/ntp-keygen.1ntp-keygenmdoc@1.209 +3 -3 + NTP_4_2_7P388 + + util/ntp-keygen.html@1.57 +2 -2 + NTP_4_2_7P388 + + util/ntp-keygen.man.in@1.209 +3 -3 + NTP_4_2_7P388 + + util/ntp-keygen.mdoc.in@1.209 +3 -3 + NTP_4_2_7P388 + +ChangeSet@1.2983, 2013-09-16 11:34:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P387 + TAG: NTP_4_2_7P387 + + ChangeLog@1.1331 +1 -0 + NTP_4_2_7P387 + + ntpd/invoke-ntp.conf.texi@1.65 +1 -1 + NTP_4_2_7P387 + + ntpd/invoke-ntp.keys.texi@1.63 +1 -1 + NTP_4_2_7P387 + + ntpd/invoke-ntpd.texi@1.379 +2 -2 + NTP_4_2_7P387 + + ntpd/ntp.conf.5man@1.99 +3 -3 + NTP_4_2_7P387 + + ntpd/ntp.conf.5mdoc@1.99 +3 -3 + NTP_4_2_7P387 + + ntpd/ntp.conf.html@1.60 +1 -1 + NTP_4_2_7P387 + + ntpd/ntp.conf.man.in@1.99 +3 -3 + NTP_4_2_7P387 + + ntpd/ntp.conf.mdoc.in@1.99 +3 -3 + NTP_4_2_7P387 + + ntpd/ntp.keys.5man@1.97 +3 -3 + NTP_4_2_7P387 + + ntpd/ntp.keys.5mdoc@1.97 +3 -3 + NTP_4_2_7P387 + + ntpd/ntp.keys.html@1.61 +1 -1 + NTP_4_2_7P387 + + ntpd/ntp.keys.man.in@1.97 +3 -3 + NTP_4_2_7P387 + + ntpd/ntp.keys.mdoc.in@1.97 +3 -3 + NTP_4_2_7P387 + + ntpd/ntpd-opts.c@1.397 +7 -7 + NTP_4_2_7P387 + + ntpd/ntpd-opts.h@1.397 +3 -3 + NTP_4_2_7P387 + + ntpd/ntpd.1ntpdman@1.208 +3 -3 + NTP_4_2_7P387 + + ntpd/ntpd.1ntpdmdoc@1.208 +3 -3 + NTP_4_2_7P387 + + ntpd/ntpd.html@1.55 +2 -2 + NTP_4_2_7P387 + + ntpd/ntpd.man.in@1.208 +3 -3 + NTP_4_2_7P387 + + ntpd/ntpd.mdoc.in@1.208 +3 -3 + NTP_4_2_7P387 + + ntpdc/invoke-ntpdc.texi@1.376 +2 -2 + NTP_4_2_7P387 + + ntpdc/ntpdc-opts.c@1.391 +7 -7 + NTP_4_2_7P387 + + ntpdc/ntpdc-opts.h@1.391 +3 -3 + NTP_4_2_7P387 + + ntpdc/ntpdc.1ntpdcman@1.207 +2 -2 + NTP_4_2_7P387 + + ntpdc/ntpdc.1ntpdcmdoc@1.207 +2 -2 + NTP_4_2_7P387 + + ntpdc/ntpdc.html@1.220 +2 -2 + NTP_4_2_7P387 + + ntpdc/ntpdc.man.in@1.207 +2 -2 + NTP_4_2_7P387 + + ntpdc/ntpdc.mdoc.in@1.207 +2 -2 + NTP_4_2_7P387 + + ntpq/invoke-ntpq.texi@1.380 +2 -2 + NTP_4_2_7P387 + + ntpq/ntpq-opts.c@1.394 +7 -7 + NTP_4_2_7P387 + + ntpq/ntpq-opts.h@1.394 +3 -3 + NTP_4_2_7P387 + + ntpq/ntpq.1ntpqman@1.208 +2 -2 + NTP_4_2_7P387 + + ntpq/ntpq.1ntpqmdoc@1.208 +2 -2 + NTP_4_2_7P387 + + ntpq/ntpq.html@1.52 +2 -2 + NTP_4_2_7P387 + + ntpq/ntpq.man.in@1.208 +2 -2 + NTP_4_2_7P387 + + ntpq/ntpq.mdoc.in@1.208 +2 -2 + NTP_4_2_7P387 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.379 +2 -2 + NTP_4_2_7P387 + + ntpsnmpd/ntpsnmpd-opts.c@1.394 +7 -7 + NTP_4_2_7P387 + + ntpsnmpd/ntpsnmpd-opts.h@1.394 +3 -3 + NTP_4_2_7P387 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.208 +3 -3 + NTP_4_2_7P387 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.208 +3 -3 + NTP_4_2_7P387 + + ntpsnmpd/ntpsnmpd.html@1.50 +1 -1 + NTP_4_2_7P387 + + ntpsnmpd/ntpsnmpd.man.in@1.208 +3 -3 + NTP_4_2_7P387 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.208 +3 -3 + NTP_4_2_7P387 + + packageinfo.sh@1.390 +1 -1 + NTP_4_2_7P387 + + scripts/invoke-ntp-wait.texi@1.196 +1 -1 + NTP_4_2_7P387 + + scripts/ntp-wait.1ntp-waitman@1.207 +3 -3 + NTP_4_2_7P387 + + scripts/ntp-wait.1ntp-waitmdoc@1.207 +3 -3 + NTP_4_2_7P387 + + scripts/ntp-wait.html@1.212 +1 -1 + NTP_4_2_7P387 + + scripts/ntp-wait.man.in@1.207 +3 -3 + NTP_4_2_7P387 + + scripts/ntp-wait.mdoc.in@1.207 +3 -3 + NTP_4_2_7P387 + + sntp/invoke-sntp.texi@1.376 +2 -2 + NTP_4_2_7P387 + + sntp/sntp-opts.c@1.391 +7 -7 + NTP_4_2_7P387 + + sntp/sntp-opts.h@1.391 +3 -3 + NTP_4_2_7P387 + + sntp/sntp.1sntpman@1.211 +3 -3 + NTP_4_2_7P387 + + sntp/sntp.1sntpmdoc@1.211 +3 -3 + NTP_4_2_7P387 + + sntp/sntp.html@1.391 +2 -2 + NTP_4_2_7P387 + + sntp/sntp.man.in@1.211 +3 -3 + NTP_4_2_7P387 + + sntp/sntp.mdoc.in@1.211 +3 -3 + NTP_4_2_7P387 + + util/invoke-ntp-keygen.texi@1.380 +2 -2 + NTP_4_2_7P387 + + util/ntp-keygen-opts.c@1.394 +7 -7 + NTP_4_2_7P387 + + util/ntp-keygen-opts.h@1.394 +3 -3 + NTP_4_2_7P387 + + util/ntp-keygen.1ntp-keygenman@1.208 +3 -3 + NTP_4_2_7P387 + + util/ntp-keygen.1ntp-keygenmdoc@1.208 +3 -3 + NTP_4_2_7P387 + + util/ntp-keygen.html@1.56 +2 -2 + NTP_4_2_7P387 + + util/ntp-keygen.man.in@1.208 +3 -3 + NTP_4_2_7P387 + + util/ntp-keygen.mdoc.in@1.208 +3 -3 + NTP_4_2_7P387 + +ChangeSet@1.2977.1.10, 2013-09-16 01:24:16-07:00, harlan@hms-mbp11.local + [Bug 1642] ntpdsim can't find simnulate block in config file + + ChangeLog@1.1326.1.10 +1 -0 + [Bug 1642] ntpdsim can't find simnulate block in config file + + html/ntpdsim_new.html@1.7 +28 -28 + [Bug 1642] ntpdsim can't find simnulate block in config file + +ChangeSet@1.2981, 2013-09-16 03:56:14-04:00, stenn@psp-deb1.ntp.org + Remove obsolete agtexi-file.tpl patch + + BitKeeper/deleted/86/agtexi-file.tpl~53aac9b4490bfb69@1.5, stenn@psp-fb1.ntp.org +0 -0 + Delete: sntp/ag-tpl/agtexi-file.tpl + +ChangeSet@1.2977.1.9, 2013-09-01 11:39:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P386 + TAG: NTP_4_2_7P386 + + ChangeLog@1.1326.1.9 +1 -0 + NTP_4_2_7P386 + + ntpd/invoke-ntp.conf.texi@1.64 +1 -1 + NTP_4_2_7P386 + + ntpd/invoke-ntp.keys.texi@1.62 +1 -1 + NTP_4_2_7P386 + + ntpd/invoke-ntpd.texi@1.378 +2 -2 + NTP_4_2_7P386 + + ntpd/ntp.conf.5man@1.98 +3 -3 + NTP_4_2_7P386 + + ntpd/ntp.conf.5mdoc@1.98 +3 -3 + NTP_4_2_7P386 + + ntpd/ntp.conf.html@1.59 +1 -1 + NTP_4_2_7P386 + + ntpd/ntp.conf.man.in@1.98 +3 -3 + NTP_4_2_7P386 + + ntpd/ntp.conf.mdoc.in@1.98 +3 -3 + NTP_4_2_7P386 + + ntpd/ntp.keys.5man@1.96 +3 -3 + NTP_4_2_7P386 + + ntpd/ntp.keys.5mdoc@1.96 +3 -3 + NTP_4_2_7P386 + + ntpd/ntp.keys.html@1.60 +1 -1 + NTP_4_2_7P386 + + ntpd/ntp.keys.man.in@1.96 +3 -3 + NTP_4_2_7P386 + + ntpd/ntp.keys.mdoc.in@1.96 +3 -3 + NTP_4_2_7P386 + + ntpd/ntpd-opts.c@1.396 +7 -7 + NTP_4_2_7P386 + + ntpd/ntpd-opts.h@1.396 +3 -3 + NTP_4_2_7P386 + + ntpd/ntpd.1ntpdman@1.207 +3 -3 + NTP_4_2_7P386 + + ntpd/ntpd.1ntpdmdoc@1.207 +3 -3 + NTP_4_2_7P386 + + ntpd/ntpd.html@1.54 +2 -2 + NTP_4_2_7P386 + + ntpd/ntpd.man.in@1.207 +3 -3 + NTP_4_2_7P386 + + ntpd/ntpd.mdoc.in@1.207 +3 -3 + NTP_4_2_7P386 + + ntpdc/invoke-ntpdc.texi@1.375 +2 -2 + NTP_4_2_7P386 + + ntpdc/ntpdc-opts.c@1.390 +7 -7 + NTP_4_2_7P386 + + ntpdc/ntpdc-opts.h@1.390 +3 -3 + NTP_4_2_7P386 + + ntpdc/ntpdc.1ntpdcman@1.206 +2 -2 + NTP_4_2_7P386 + + ntpdc/ntpdc.1ntpdcmdoc@1.206 +2 -2 + NTP_4_2_7P386 + + ntpdc/ntpdc.html@1.219 +2 -2 + NTP_4_2_7P386 + + ntpdc/ntpdc.man.in@1.206 +2 -2 + NTP_4_2_7P386 + + ntpdc/ntpdc.mdoc.in@1.206 +2 -2 + NTP_4_2_7P386 + + ntpq/invoke-ntpq.texi@1.379 +2 -2 + NTP_4_2_7P386 + + ntpq/ntpq-opts.c@1.393 +7 -7 + NTP_4_2_7P386 + + ntpq/ntpq-opts.h@1.393 +3 -3 + NTP_4_2_7P386 + + ntpq/ntpq.1ntpqman@1.207 +2 -2 + NTP_4_2_7P386 + + ntpq/ntpq.1ntpqmdoc@1.207 +2 -2 + NTP_4_2_7P386 + + ntpq/ntpq.html@1.51 +2 -2 + NTP_4_2_7P386 + + ntpq/ntpq.man.in@1.207 +2 -2 + NTP_4_2_7P386 + + ntpq/ntpq.mdoc.in@1.207 +2 -2 + NTP_4_2_7P386 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.378 +2 -2 + NTP_4_2_7P386 + + ntpsnmpd/ntpsnmpd-opts.c@1.393 +7 -7 + NTP_4_2_7P386 + + ntpsnmpd/ntpsnmpd-opts.h@1.393 +3 -3 + NTP_4_2_7P386 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.207 +3 -3 + NTP_4_2_7P386 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.207 +3 -3 + NTP_4_2_7P386 + + ntpsnmpd/ntpsnmpd.html@1.49 +1 -1 + NTP_4_2_7P386 + + ntpsnmpd/ntpsnmpd.man.in@1.207 +3 -3 + NTP_4_2_7P386 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.207 +3 -3 + NTP_4_2_7P386 + + packageinfo.sh@1.389 +1 -1 + NTP_4_2_7P386 + + scripts/invoke-ntp-wait.texi@1.195 +1 -1 + NTP_4_2_7P386 + + scripts/ntp-wait.1ntp-waitman@1.206 +3 -3 + NTP_4_2_7P386 + + scripts/ntp-wait.1ntp-waitmdoc@1.206 +3 -3 + NTP_4_2_7P386 + + scripts/ntp-wait.html@1.211 +1 -1 + NTP_4_2_7P386 + + scripts/ntp-wait.man.in@1.206 +3 -3 + NTP_4_2_7P386 + + scripts/ntp-wait.mdoc.in@1.206 +3 -3 + NTP_4_2_7P386 + + sntp/invoke-sntp.texi@1.375 +2 -2 + NTP_4_2_7P386 + + sntp/sntp-opts.c@1.390 +7 -7 + NTP_4_2_7P386 + + sntp/sntp-opts.h@1.390 +3 -3 + NTP_4_2_7P386 + + sntp/sntp.1sntpman@1.210 +3 -3 + NTP_4_2_7P386 + + sntp/sntp.1sntpmdoc@1.210 +3 -3 + NTP_4_2_7P386 + + sntp/sntp.html@1.390 +2 -2 + NTP_4_2_7P386 + + sntp/sntp.man.in@1.210 +3 -3 + NTP_4_2_7P386 + + sntp/sntp.mdoc.in@1.210 +3 -3 + NTP_4_2_7P386 + + util/invoke-ntp-keygen.texi@1.379 +2 -2 + NTP_4_2_7P386 + + util/ntp-keygen-opts.c@1.393 +7 -7 + NTP_4_2_7P386 + + util/ntp-keygen-opts.h@1.393 +3 -3 + NTP_4_2_7P386 + + util/ntp-keygen.1ntp-keygenman@1.207 +3 -3 + NTP_4_2_7P386 + + util/ntp-keygen.1ntp-keygenmdoc@1.207 +3 -3 + NTP_4_2_7P386 + + util/ntp-keygen.html@1.55 +2 -2 + NTP_4_2_7P386 + + util/ntp-keygen.man.in@1.207 +3 -3 + NTP_4_2_7P386 + + util/ntp-keygen.mdoc.in@1.207 +3 -3 + NTP_4_2_7P386 + +ChangeSet@1.2977.2.1, 2013-09-01 10:34:32+02:00, jnperlin@armageddon. + [Bug 2473] NTPD exits after clock is stepped backwards externally + + ChangeLog@1.1326.2.1 +1 -0 + [Bug 2473] NTPD exits after clock is stepped backwards externally + + libntp/systime.c@1.67 +10 -0 + [Bug 2473] NTPD exits after clock is stepped backwards externally + Check for back-steps of the system clock to avoid sporious Lamport advance violations + +ChangeSet@1.2977.1.8, 2013-08-30 21:23:39+02:00, jnperlin@armageddon. + * [Bug 2472] (WinXP) Avoid self-termination of IO thread during exit(). + + ChangeLog@1.1326.1.8 +1 -0 + * [Bug 2472] (WinXP) Avoid self-termination of IO thread during exit(). + + ports/winnt/ntpd/ntp_iocompletionport.c@1.69 +16 -10 + * [Bug 2472] (WinXP) Avoid self-termination of IO thread during exit(). + +ChangeSet@1.2977.1.7, 2013-08-19 03:48:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P385 + TAG: NTP_4_2_7P385 + + ChangeLog@1.1326.1.7 +1 -0 + NTP_4_2_7P385 + + ntpd/invoke-ntp.conf.texi@1.63 +1 -1 + NTP_4_2_7P385 + + ntpd/invoke-ntp.keys.texi@1.61 +1 -1 + NTP_4_2_7P385 + + ntpd/invoke-ntpd.texi@1.377 +2 -2 + NTP_4_2_7P385 + + ntpd/ntp.conf.5man@1.97 +3 -3 + NTP_4_2_7P385 + + ntpd/ntp.conf.5mdoc@1.97 +3 -3 + NTP_4_2_7P385 + + ntpd/ntp.conf.html@1.58 +1 -1 + NTP_4_2_7P385 + + ntpd/ntp.conf.man.in@1.97 +3 -3 + NTP_4_2_7P385 + + ntpd/ntp.conf.mdoc.in@1.97 +3 -3 + NTP_4_2_7P385 + + ntpd/ntp.keys.5man@1.95 +3 -3 + NTP_4_2_7P385 + + ntpd/ntp.keys.5mdoc@1.95 +3 -3 + NTP_4_2_7P385 + + ntpd/ntp.keys.html@1.59 +1 -1 + NTP_4_2_7P385 + + ntpd/ntp.keys.man.in@1.95 +3 -3 + NTP_4_2_7P385 + + ntpd/ntp.keys.mdoc.in@1.95 +3 -3 + NTP_4_2_7P385 + + ntpd/ntpd-opts.c@1.395 +7 -7 + NTP_4_2_7P385 + + ntpd/ntpd-opts.h@1.395 +3 -3 + NTP_4_2_7P385 + + ntpd/ntpd.1ntpdman@1.206 +3 -3 + NTP_4_2_7P385 + + ntpd/ntpd.1ntpdmdoc@1.206 +3 -3 + NTP_4_2_7P385 + + ntpd/ntpd.html@1.53 +3 -3 + NTP_4_2_7P385 + + ntpd/ntpd.man.in@1.206 +3 -3 + NTP_4_2_7P385 + + ntpd/ntpd.mdoc.in@1.206 +3 -3 + NTP_4_2_7P385 + + ntpdc/invoke-ntpdc.texi@1.374 +2 -2 + NTP_4_2_7P385 + + ntpdc/ntpdc-opts.c@1.389 +7 -7 + NTP_4_2_7P385 + + ntpdc/ntpdc-opts.h@1.389 +3 -3 + NTP_4_2_7P385 + + ntpdc/ntpdc.1ntpdcman@1.205 +2 -2 + NTP_4_2_7P385 + + ntpdc/ntpdc.1ntpdcmdoc@1.205 +2 -2 + NTP_4_2_7P385 + + ntpdc/ntpdc.html@1.218 +2 -2 + NTP_4_2_7P385 + + ntpdc/ntpdc.man.in@1.205 +2 -2 + NTP_4_2_7P385 + + ntpdc/ntpdc.mdoc.in@1.205 +2 -2 + NTP_4_2_7P385 + + ntpq/invoke-ntpq.texi@1.378 +2 -2 + NTP_4_2_7P385 + + ntpq/ntpq-opts.c@1.392 +7 -7 + NTP_4_2_7P385 + + ntpq/ntpq-opts.h@1.392 +3 -3 + NTP_4_2_7P385 + + ntpq/ntpq.1ntpqman@1.206 +2 -2 + NTP_4_2_7P385 + + ntpq/ntpq.1ntpqmdoc@1.206 +2 -2 + NTP_4_2_7P385 + + ntpq/ntpq.html@1.50 +2 -2 + NTP_4_2_7P385 + + ntpq/ntpq.man.in@1.206 +2 -2 + NTP_4_2_7P385 + + ntpq/ntpq.mdoc.in@1.206 +2 -2 + NTP_4_2_7P385 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.377 +2 -2 + NTP_4_2_7P385 + + ntpsnmpd/ntpsnmpd-opts.c@1.392 +7 -7 + NTP_4_2_7P385 + + ntpsnmpd/ntpsnmpd-opts.h@1.392 +3 -3 + NTP_4_2_7P385 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.206 +3 -3 + NTP_4_2_7P385 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.206 +3 -3 + NTP_4_2_7P385 + + ntpsnmpd/ntpsnmpd.html@1.48 +1 -1 + NTP_4_2_7P385 + + ntpsnmpd/ntpsnmpd.man.in@1.206 +3 -3 + NTP_4_2_7P385 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.206 +3 -3 + NTP_4_2_7P385 + + packageinfo.sh@1.388 +1 -1 + NTP_4_2_7P385 + + scripts/invoke-ntp-wait.texi@1.194 +1 -1 + NTP_4_2_7P385 + + scripts/ntp-wait.1ntp-waitman@1.205 +3 -3 + NTP_4_2_7P385 + + scripts/ntp-wait.1ntp-waitmdoc@1.205 +3 -3 + NTP_4_2_7P385 + + scripts/ntp-wait.html@1.210 +1 -1 + NTP_4_2_7P385 + + scripts/ntp-wait.man.in@1.205 +3 -3 + NTP_4_2_7P385 + + scripts/ntp-wait.mdoc.in@1.205 +3 -3 + NTP_4_2_7P385 + + sntp/invoke-sntp.texi@1.374 +2 -2 + NTP_4_2_7P385 + + sntp/sntp-opts.c@1.389 +7 -7 + NTP_4_2_7P385 + + sntp/sntp-opts.h@1.389 +3 -3 + NTP_4_2_7P385 + + sntp/sntp.1sntpman@1.209 +3 -3 + NTP_4_2_7P385 + + sntp/sntp.1sntpmdoc@1.209 +3 -3 + NTP_4_2_7P385 + + sntp/sntp.html@1.389 +2 -2 + NTP_4_2_7P385 + + sntp/sntp.man.in@1.209 +3 -3 + NTP_4_2_7P385 + + sntp/sntp.mdoc.in@1.209 +3 -3 + NTP_4_2_7P385 + + util/invoke-ntp-keygen.texi@1.378 +2 -2 + NTP_4_2_7P385 + + util/ntp-keygen-opts.c@1.392 +7 -7 + NTP_4_2_7P385 + + util/ntp-keygen-opts.h@1.392 +3 -3 + NTP_4_2_7P385 + + util/ntp-keygen.1ntp-keygenman@1.206 +3 -3 + NTP_4_2_7P385 + + util/ntp-keygen.1ntp-keygenmdoc@1.206 +3 -3 + NTP_4_2_7P385 + + util/ntp-keygen.html@1.54 +2 -2 + NTP_4_2_7P385 + + util/ntp-keygen.man.in@1.206 +3 -3 + NTP_4_2_7P385 + + util/ntp-keygen.mdoc.in@1.206 +3 -3 + NTP_4_2_7P385 + +ChangeSet@1.2977.1.6, 2013-08-18 23:30:39-04:00, stenn@deacon.udel.edu + [Bug 2426] Possibly uninitialized data in crypto_send() - CID 975596 + + ChangeLog@1.1326.1.6 +1 -0 + [Bug 2426] Possibly uninitialized data in crypto_send() - CID 975596 + +ChangeSet@1.2977.1.5, 2013-08-18 23:05:39-04:00, stenn@pogo.udel.edu + CID 975596: Copy/paste error: vallen should be siglen + + ChangeLog@1.1326.1.5 +1 -0 + CID 975596: Copy/paste error: vallen should be siglen + + ntpd/ntp_crypto.c@1.163 +1 -1 + CID 975596: Copy/paste error: vallen should be siglen + +ChangeSet@1.2977.1.4, 2013-08-18 23:00:37-04:00, stenn@pogo.udel.edu + CID 1009579: Check return status of X509_add_ext() + + ChangeLog@1.1326.1.4 +1 -0 + CID 1009579: Check return status of X509_add_ext() + + ntpd/ntp_crypto.c@1.162 +1 -1 + CID 1009579: Check return status of X509_add_ext() + +ChangeSet@1.2977.1.3, 2013-08-18 22:20:55-04:00, stenn@pogo.udel.edu + [2085] Fix root distance and root dispersion calculations + + ChangeLog@1.1326.1.3 +1 -0 + [2085] Fix root distance and root dispersion calculations + + ntpd/ntp_proto.c@1.346 +48 -6 + [2085] Fix root distance and root dispersion calculations + +ChangeSet@1.2977.1.2, 2013-08-18 11:41:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P384 + TAG: NTP_4_2_7P384 + + ChangeLog@1.1326.1.2 +1 -0 + NTP_4_2_7P384 + + ntpd/invoke-ntp.conf.texi@1.62 +1 -1 + NTP_4_2_7P384 + + ntpd/invoke-ntp.keys.texi@1.60 +1 -1 + NTP_4_2_7P384 + + ntpd/invoke-ntpd.texi@1.376 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.conf.5man@1.96 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.conf.5mdoc@1.96 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.conf.html@1.57 +1 -1 + NTP_4_2_7P384 + + ntpd/ntp.conf.man.in@1.96 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.conf.mdoc.in@1.96 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.keys.5man@1.94 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.keys.5mdoc@1.94 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.keys.html@1.58 +1 -1 + NTP_4_2_7P384 + + ntpd/ntp.keys.man.in@1.94 +3 -3 + NTP_4_2_7P384 + + ntpd/ntp.keys.mdoc.in@1.94 +3 -3 + NTP_4_2_7P384 + + ntpd/ntpd-opts.c@1.394 +7 -7 + NTP_4_2_7P384 + + ntpd/ntpd-opts.h@1.394 +9 -9 + NTP_4_2_7P384 + + ntpd/ntpd.1ntpdman@1.205 +3 -3 + NTP_4_2_7P384 + + ntpd/ntpd.1ntpdmdoc@1.205 +3 -3 + NTP_4_2_7P384 + + ntpd/ntpd.html@1.52 +2 -2 + NTP_4_2_7P384 + + ntpd/ntpd.man.in@1.205 +3 -3 + NTP_4_2_7P384 + + ntpd/ntpd.mdoc.in@1.205 +3 -3 + NTP_4_2_7P384 + + ntpdc/invoke-ntpdc.texi@1.373 +2 -2 + NTP_4_2_7P384 + + ntpdc/ntpdc-opts.c@1.388 +7 -7 + NTP_4_2_7P384 + + ntpdc/ntpdc-opts.h@1.388 +4 -4 + NTP_4_2_7P384 + + ntpdc/ntpdc.1ntpdcman@1.204 +2 -2 + NTP_4_2_7P384 + + ntpdc/ntpdc.1ntpdcmdoc@1.204 +2 -2 + NTP_4_2_7P384 + + ntpdc/ntpdc.html@1.217 +2 -2 + NTP_4_2_7P384 + + ntpdc/ntpdc.man.in@1.204 +2 -2 + NTP_4_2_7P384 + + ntpdc/ntpdc.mdoc.in@1.204 +2 -2 + NTP_4_2_7P384 + + ntpq/invoke-ntpq.texi@1.377 +2 -2 + NTP_4_2_7P384 + + ntpq/ntpq-opts.c@1.391 +7 -7 + NTP_4_2_7P384 + + ntpq/ntpq-opts.h@1.391 +5 -5 + NTP_4_2_7P384 + + ntpq/ntpq.1ntpqman@1.205 +2 -2 + NTP_4_2_7P384 + + ntpq/ntpq.1ntpqmdoc@1.205 +2 -2 + NTP_4_2_7P384 + + ntpq/ntpq.html@1.49 +2 -2 + NTP_4_2_7P384 + + ntpq/ntpq.man.in@1.205 +2 -2 + NTP_4_2_7P384 + + ntpq/ntpq.mdoc.in@1.205 +2 -2 + NTP_4_2_7P384 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.376 +2 -2 + NTP_4_2_7P384 + + ntpsnmpd/ntpsnmpd-opts.c@1.391 +7 -7 + NTP_4_2_7P384 + + ntpsnmpd/ntpsnmpd-opts.h@1.391 +5 -5 + NTP_4_2_7P384 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.205 +3 -3 + NTP_4_2_7P384 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.205 +3 -3 + NTP_4_2_7P384 + + ntpsnmpd/ntpsnmpd.html@1.47 +1 -1 + NTP_4_2_7P384 + + ntpsnmpd/ntpsnmpd.man.in@1.205 +3 -3 + NTP_4_2_7P384 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.205 +3 -3 + NTP_4_2_7P384 + + packageinfo.sh@1.387 +1 -1 + NTP_4_2_7P384 + + scripts/invoke-ntp-wait.texi@1.193 +1 -1 + NTP_4_2_7P384 + + scripts/ntp-wait.1ntp-waitman@1.204 +3 -3 + NTP_4_2_7P384 + + scripts/ntp-wait.1ntp-waitmdoc@1.204 +3 -3 + NTP_4_2_7P384 + + scripts/ntp-wait.html@1.209 +1 -1 + NTP_4_2_7P384 + + scripts/ntp-wait.man.in@1.204 +3 -3 + NTP_4_2_7P384 + + scripts/ntp-wait.mdoc.in@1.204 +3 -3 + NTP_4_2_7P384 + + sntp/invoke-sntp.texi@1.373 +2 -2 + NTP_4_2_7P384 + + sntp/sntp-opts.c@1.388 +7 -7 + NTP_4_2_7P384 + + sntp/sntp-opts.h@1.388 +5 -5 + NTP_4_2_7P384 + + sntp/sntp.1sntpman@1.208 +3 -3 + NTP_4_2_7P384 + + sntp/sntp.1sntpmdoc@1.208 +3 -3 + NTP_4_2_7P384 + + sntp/sntp.html@1.388 +2 -2 + NTP_4_2_7P384 + + sntp/sntp.man.in@1.208 +3 -3 + NTP_4_2_7P384 + + sntp/sntp.mdoc.in@1.208 +3 -3 + NTP_4_2_7P384 + + util/invoke-ntp-keygen.texi@1.377 +2 -2 + NTP_4_2_7P384 + + util/ntp-keygen-opts.c@1.391 +7 -7 + NTP_4_2_7P384 + + util/ntp-keygen-opts.h@1.391 +4 -4 + NTP_4_2_7P384 + + util/ntp-keygen.1ntp-keygenman@1.205 +3 -3 + NTP_4_2_7P384 + + util/ntp-keygen.1ntp-keygenmdoc@1.205 +3 -3 + NTP_4_2_7P384 + + util/ntp-keygen.html@1.53 +2 -2 + NTP_4_2_7P384 + + util/ntp-keygen.man.in@1.205 +3 -3 + NTP_4_2_7P384 + + util/ntp-keygen.mdoc.in@1.205 +3 -3 + NTP_4_2_7P384 + +ChangeSet@1.2977.1.1, 2013-08-18 01:42:12-04:00, stenn@deacon.udel.edu + [Bug 2450] --version has bogus short option + + ChangeLog@1.1326.1.1 +1 -0 + [Bug 2450] --version has bogus short option + +ChangeSet@1.2978, 2013-08-13 07:22:26+00:00, stenn@psp-fb1.ntp.org + Note [Bug 2399] Reset sys_kodsent in proto_clr_stats() was fixed in 4.2.7p21 + + ChangeLog@1.1327 +1 -0 + Note [Bug 2399] Reset sys_kodsent in proto_clr_stats() was fixed in 4.2.7p21 + +ChangeSet@1.2977, 2013-08-10 11:34:05+00:00, stenn@deacon.udel.edu + NTP_4_2_7P383 + TAG: NTP_4_2_7P383 + + ChangeLog@1.1326 +1 -0 + NTP_4_2_7P383 + + ntpd/invoke-ntp.conf.texi@1.61 +1 -1 + NTP_4_2_7P383 + + ntpd/invoke-ntp.keys.texi@1.59 +1 -1 + NTP_4_2_7P383 + + ntpd/invoke-ntpd.texi@1.375 +2 -2 + NTP_4_2_7P383 + + ntpd/ntp.conf.5man@1.95 +3 -3 + NTP_4_2_7P383 + + ntpd/ntp.conf.5mdoc@1.95 +3 -3 + NTP_4_2_7P383 + + ntpd/ntp.conf.html@1.56 +1 -1 + NTP_4_2_7P383 + + ntpd/ntp.conf.man.in@1.95 +3 -3 + NTP_4_2_7P383 + + ntpd/ntp.conf.mdoc.in@1.95 +3 -3 + NTP_4_2_7P383 + + ntpd/ntp.keys.5man@1.93 +3 -3 + NTP_4_2_7P383 + + ntpd/ntp.keys.5mdoc@1.93 +3 -3 + NTP_4_2_7P383 + + ntpd/ntp.keys.html@1.57 +1 -1 + NTP_4_2_7P383 + + ntpd/ntp.keys.man.in@1.93 +3 -3 + NTP_4_2_7P383 + + ntpd/ntp.keys.mdoc.in@1.93 +3 -3 + NTP_4_2_7P383 + + ntpd/ntpd-opts.c@1.393 +7 -7 + NTP_4_2_7P383 + + ntpd/ntpd-opts.h@1.393 +3 -3 + NTP_4_2_7P383 + + ntpd/ntpd.1ntpdman@1.204 +3 -3 + NTP_4_2_7P383 + + ntpd/ntpd.1ntpdmdoc@1.204 +3 -3 + NTP_4_2_7P383 + + ntpd/ntpd.html@1.51 +2 -2 + NTP_4_2_7P383 + + ntpd/ntpd.man.in@1.204 +3 -3 + NTP_4_2_7P383 + + ntpd/ntpd.mdoc.in@1.204 +3 -3 + NTP_4_2_7P383 + + ntpdc/invoke-ntpdc.texi@1.372 +2 -2 + NTP_4_2_7P383 + + ntpdc/ntpdc-opts.c@1.387 +7 -7 + NTP_4_2_7P383 + + ntpdc/ntpdc-opts.h@1.387 +3 -3 + NTP_4_2_7P383 + + ntpdc/ntpdc.1ntpdcman@1.203 +2 -2 + NTP_4_2_7P383 + + ntpdc/ntpdc.1ntpdcmdoc@1.203 +2 -2 + NTP_4_2_7P383 + + ntpdc/ntpdc.html@1.216 +2 -2 + NTP_4_2_7P383 + + ntpdc/ntpdc.man.in@1.203 +2 -2 + NTP_4_2_7P383 + + ntpdc/ntpdc.mdoc.in@1.203 +2 -2 + NTP_4_2_7P383 + + ntpq/invoke-ntpq.texi@1.376 +2 -2 + NTP_4_2_7P383 + + ntpq/ntpq-opts.c@1.390 +7 -7 + NTP_4_2_7P383 + + ntpq/ntpq-opts.h@1.390 +3 -3 + NTP_4_2_7P383 + + ntpq/ntpq.1ntpqman@1.204 +2 -2 + NTP_4_2_7P383 + + ntpq/ntpq.1ntpqmdoc@1.204 +2 -2 + NTP_4_2_7P383 + + ntpq/ntpq.html@1.48 +2 -2 + NTP_4_2_7P383 + + ntpq/ntpq.man.in@1.204 +2 -2 + NTP_4_2_7P383 + + ntpq/ntpq.mdoc.in@1.204 +2 -2 + NTP_4_2_7P383 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.375 +2 -2 + NTP_4_2_7P383 + + ntpsnmpd/ntpsnmpd-opts.c@1.390 +7 -7 + NTP_4_2_7P383 + + ntpsnmpd/ntpsnmpd-opts.h@1.390 +3 -3 + NTP_4_2_7P383 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.204 +3 -3 + NTP_4_2_7P383 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.204 +3 -3 + NTP_4_2_7P383 + + ntpsnmpd/ntpsnmpd.html@1.46 +1 -1 + NTP_4_2_7P383 + + ntpsnmpd/ntpsnmpd.man.in@1.204 +3 -3 + NTP_4_2_7P383 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.204 +3 -3 + NTP_4_2_7P383 + + packageinfo.sh@1.386 +1 -1 + NTP_4_2_7P383 + + scripts/invoke-ntp-wait.texi@1.192 +1 -1 + NTP_4_2_7P383 + + scripts/ntp-wait.1ntp-waitman@1.203 +3 -3 + NTP_4_2_7P383 + + scripts/ntp-wait.1ntp-waitmdoc@1.203 +3 -3 + NTP_4_2_7P383 + + scripts/ntp-wait.html@1.208 +1 -1 + NTP_4_2_7P383 + + scripts/ntp-wait.man.in@1.203 +3 -3 + NTP_4_2_7P383 + + scripts/ntp-wait.mdoc.in@1.203 +3 -3 + NTP_4_2_7P383 + + sntp/invoke-sntp.texi@1.372 +2 -2 + NTP_4_2_7P383 + + sntp/sntp-opts.c@1.387 +7 -7 + NTP_4_2_7P383 + + sntp/sntp-opts.h@1.387 +3 -3 + NTP_4_2_7P383 + + sntp/sntp.1sntpman@1.207 +3 -3 + NTP_4_2_7P383 + + sntp/sntp.1sntpmdoc@1.207 +3 -3 + NTP_4_2_7P383 + + sntp/sntp.html@1.387 +2 -2 + NTP_4_2_7P383 + + sntp/sntp.man.in@1.207 +3 -3 + NTP_4_2_7P383 + + sntp/sntp.mdoc.in@1.207 +3 -3 + NTP_4_2_7P383 + + util/invoke-ntp-keygen.texi@1.376 +2 -2 + NTP_4_2_7P383 + + util/ntp-keygen-opts.c@1.390 +7 -7 + NTP_4_2_7P383 + + util/ntp-keygen-opts.h@1.390 +3 -3 + NTP_4_2_7P383 + + util/ntp-keygen.1ntp-keygenman@1.204 +3 -3 + NTP_4_2_7P383 + + util/ntp-keygen.1ntp-keygenmdoc@1.204 +3 -3 + NTP_4_2_7P383 + + util/ntp-keygen.html@1.52 +2 -2 + NTP_4_2_7P383 + + util/ntp-keygen.man.in@1.204 +3 -3 + NTP_4_2_7P383 + + util/ntp-keygen.mdoc.in@1.204 +3 -3 + NTP_4_2_7P383 + +ChangeSet@1.2976, 2013-08-10 06:47:51-04:00, stenn@deacon.udel.edu + (no changes - force a rebuild for a new Coverity scan) + + ChangeLog@1.1325 +1 -0 + (no changes - force a rebuild for a new Coverity scan) + +ChangeSet@1.2975, 2013-08-08 11:38:23+00:00, stenn@deacon.udel.edu + NTP_4_2_7P382 + TAG: NTP_4_2_7P382 + + ChangeLog@1.1324 +1 -0 + NTP_4_2_7P382 + + ntpd/invoke-ntp.conf.texi@1.60 +1 -1 + NTP_4_2_7P382 + + ntpd/invoke-ntp.keys.texi@1.58 +1 -1 + NTP_4_2_7P382 + + ntpd/invoke-ntpd.texi@1.374 +2 -2 + NTP_4_2_7P382 + + ntpd/ntp.conf.5man@1.94 +3 -3 + NTP_4_2_7P382 + + ntpd/ntp.conf.5mdoc@1.94 +2 -2 + NTP_4_2_7P382 + + ntpd/ntp.conf.html@1.55 +1 -1 + NTP_4_2_7P382 + + ntpd/ntp.conf.man.in@1.94 +3 -3 + NTP_4_2_7P382 + + ntpd/ntp.conf.mdoc.in@1.94 +2 -2 + NTP_4_2_7P382 + + ntpd/ntp.keys.5man@1.92 +3 -3 + NTP_4_2_7P382 + + ntpd/ntp.keys.5mdoc@1.92 +3 -3 + NTP_4_2_7P382 + + ntpd/ntp.keys.html@1.56 +1 -1 + NTP_4_2_7P382 + + ntpd/ntp.keys.man.in@1.92 +3 -3 + NTP_4_2_7P382 + + ntpd/ntp.keys.mdoc.in@1.92 +3 -3 + NTP_4_2_7P382 + + ntpd/ntpd-opts.c@1.392 +7 -7 + NTP_4_2_7P382 + + ntpd/ntpd-opts.h@1.392 +3 -3 + NTP_4_2_7P382 + + ntpd/ntpd.1ntpdman@1.203 +3 -3 + NTP_4_2_7P382 + + ntpd/ntpd.1ntpdmdoc@1.203 +3 -3 + NTP_4_2_7P382 + + ntpd/ntpd.html@1.50 +2 -2 + NTP_4_2_7P382 + + ntpd/ntpd.man.in@1.203 +3 -3 + NTP_4_2_7P382 + + ntpd/ntpd.mdoc.in@1.203 +3 -3 + NTP_4_2_7P382 + + ntpdc/invoke-ntpdc.texi@1.371 +2 -2 + NTP_4_2_7P382 + + ntpdc/ntpdc-opts.c@1.386 +7 -7 + NTP_4_2_7P382 + + ntpdc/ntpdc-opts.h@1.386 +3 -3 + NTP_4_2_7P382 + + ntpdc/ntpdc.1ntpdcman@1.202 +2 -2 + NTP_4_2_7P382 + + ntpdc/ntpdc.1ntpdcmdoc@1.202 +2 -2 + NTP_4_2_7P382 + + ntpdc/ntpdc.html@1.215 +2 -2 + NTP_4_2_7P382 + + ntpdc/ntpdc.man.in@1.202 +2 -2 + NTP_4_2_7P382 + + ntpdc/ntpdc.mdoc.in@1.202 +2 -2 + NTP_4_2_7P382 + + ntpq/invoke-ntpq.texi@1.375 +2 -2 + NTP_4_2_7P382 + + ntpq/ntpq-opts.c@1.389 +7 -7 + NTP_4_2_7P382 + + ntpq/ntpq-opts.h@1.389 +3 -3 + NTP_4_2_7P382 + + ntpq/ntpq.1ntpqman@1.203 +2 -2 + NTP_4_2_7P382 + + ntpq/ntpq.1ntpqmdoc@1.203 +2 -2 + NTP_4_2_7P382 + + ntpq/ntpq.html@1.47 +2 -2 + NTP_4_2_7P382 + + ntpq/ntpq.man.in@1.203 +2 -2 + NTP_4_2_7P382 + + ntpq/ntpq.mdoc.in@1.203 +2 -2 + NTP_4_2_7P382 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.374 +2 -2 + NTP_4_2_7P382 + + ntpsnmpd/ntpsnmpd-opts.c@1.389 +7 -7 + NTP_4_2_7P382 + + ntpsnmpd/ntpsnmpd-opts.h@1.389 +3 -3 + NTP_4_2_7P382 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.203 +3 -3 + NTP_4_2_7P382 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.203 +3 -3 + NTP_4_2_7P382 + + ntpsnmpd/ntpsnmpd.html@1.45 +1 -1 + NTP_4_2_7P382 + + ntpsnmpd/ntpsnmpd.man.in@1.203 +3 -3 + NTP_4_2_7P382 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.203 +3 -3 + NTP_4_2_7P382 + + packageinfo.sh@1.385 +1 -1 + NTP_4_2_7P382 + + scripts/invoke-ntp-wait.texi@1.191 +1 -1 + NTP_4_2_7P382 + + scripts/ntp-wait.1ntp-waitman@1.202 +3 -3 + NTP_4_2_7P382 + + scripts/ntp-wait.1ntp-waitmdoc@1.202 +3 -3 + NTP_4_2_7P382 + + scripts/ntp-wait.html@1.207 +1 -1 + NTP_4_2_7P382 + + scripts/ntp-wait.man.in@1.202 +3 -3 + NTP_4_2_7P382 + + scripts/ntp-wait.mdoc.in@1.202 +3 -3 + NTP_4_2_7P382 + + sntp/invoke-sntp.texi@1.371 +2 -2 + NTP_4_2_7P382 + + sntp/sntp-opts.c@1.386 +7 -7 + NTP_4_2_7P382 + + sntp/sntp-opts.h@1.386 +3 -3 + NTP_4_2_7P382 + + sntp/sntp.1sntpman@1.206 +3 -3 + NTP_4_2_7P382 + + sntp/sntp.1sntpmdoc@1.206 +3 -3 + NTP_4_2_7P382 + + sntp/sntp.html@1.386 +2 -2 + NTP_4_2_7P382 + + sntp/sntp.man.in@1.206 +3 -3 + NTP_4_2_7P382 + + sntp/sntp.mdoc.in@1.206 +3 -3 + NTP_4_2_7P382 + + util/invoke-ntp-keygen.texi@1.375 +2 -2 + NTP_4_2_7P382 + + util/ntp-keygen-opts.c@1.389 +7 -7 + NTP_4_2_7P382 + + util/ntp-keygen-opts.h@1.389 +3 -3 + NTP_4_2_7P382 + + util/ntp-keygen.1ntp-keygenman@1.203 +3 -3 + NTP_4_2_7P382 + + util/ntp-keygen.1ntp-keygenmdoc@1.203 +3 -3 + NTP_4_2_7P382 + + util/ntp-keygen.html@1.51 +2 -2 + NTP_4_2_7P382 + + util/ntp-keygen.man.in@1.203 +3 -3 + NTP_4_2_7P382 + + util/ntp-keygen.mdoc.in@1.203 +3 -3 + NTP_4_2_7P382 + +ChangeSet@1.2974, 2013-08-08 04:18:46-04:00, stenn@deacon.udel.edu + [Bug 2454] Need way to set file descriptor limit - cleanup + + ChangeLog@1.1323 +15 -14 + [Bug 2454] Need way to set file descriptor limit - cleanup + + html/miscopt.html@1.75 +3 -3 + [Bug 2454] Need way to set file descriptor limit - cleanup + + include/ntp_config.h@1.81 +1 -1 + [Bug 2454] Need way to set file descriptor limit - cleanup + + ntpd/invoke-ntp.conf.texi@1.59 +3 -3 + [Bug 2454] Need way to set file descriptor limit - cleanup + + ntpd/ntp.conf.5man@1.93 +4 -4 + [Bug 2454] Need way to set file descriptor limit - cleanup + + ntpd/ntp.conf.5mdoc@1.93 +4 -4 + [Bug 2454] Need way to set file descriptor limit - cleanup + + ntpd/ntp.conf.def@1.9 +2 -2 + [Bug 2454] Need way to set file descriptor limit - cleanup + + ntpd/ntp.conf.man.in@1.93 +4 -4 + [Bug 2454] Need way to set file descriptor limit - cleanup + + ntpd/ntp.conf.mdoc.in@1.93 +4 -4 + [Bug 2454] Need way to set file descriptor limit - cleanup + + ntpd/ntp_config.c@1.314 +13 -11 + [Bug 2454] Need way to set file descriptor limit - cleanup + +ChangeSet@1.2973, 2013-08-07 11:44:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P381 + TAG: NTP_4_2_7P381 + + ChangeLog@1.1322 +1 -0 + NTP_4_2_7P381 + + ntpd/invoke-ntp.conf.texi@1.58 +1 -1 + NTP_4_2_7P381 + + ntpd/invoke-ntp.keys.texi@1.57 +1 -1 + NTP_4_2_7P381 + + ntpd/invoke-ntpd.texi@1.373 +2 -2 + NTP_4_2_7P381 + + ntpd/ntp.conf.5man@1.92 +3 -3 + NTP_4_2_7P381 + + ntpd/ntp.conf.5mdoc@1.92 +3 -3 + NTP_4_2_7P381 + + ntpd/ntp.conf.html@1.54 +1 -1 + NTP_4_2_7P381 + + ntpd/ntp.conf.man.in@1.92 +3 -3 + NTP_4_2_7P381 + + ntpd/ntp.conf.mdoc.in@1.92 +3 -3 + NTP_4_2_7P381 + + ntpd/ntp.keys.5man@1.91 +3 -3 + NTP_4_2_7P381 + + ntpd/ntp.keys.5mdoc@1.91 +3 -3 + NTP_4_2_7P381 + + ntpd/ntp.keys.html@1.55 +1 -1 + NTP_4_2_7P381 + + ntpd/ntp.keys.man.in@1.91 +3 -3 + NTP_4_2_7P381 + + ntpd/ntp.keys.mdoc.in@1.91 +3 -3 + NTP_4_2_7P381 + + ntpd/ntpd-opts.c@1.391 +7 -7 + NTP_4_2_7P381 + + ntpd/ntpd-opts.h@1.391 +3 -3 + NTP_4_2_7P381 + + ntpd/ntpd.1ntpdman@1.202 +3 -3 + NTP_4_2_7P381 + + ntpd/ntpd.1ntpdmdoc@1.202 +3 -3 + NTP_4_2_7P381 + + ntpd/ntpd.html@1.49 +2 -2 + NTP_4_2_7P381 + + ntpd/ntpd.man.in@1.202 +3 -3 + NTP_4_2_7P381 + + ntpd/ntpd.mdoc.in@1.202 +3 -3 + NTP_4_2_7P381 + + ntpdc/invoke-ntpdc.texi@1.370 +2 -2 + NTP_4_2_7P381 + + ntpdc/ntpdc-opts.c@1.385 +7 -7 + NTP_4_2_7P381 + + ntpdc/ntpdc-opts.h@1.385 +3 -3 + NTP_4_2_7P381 + + ntpdc/ntpdc.1ntpdcman@1.201 +2 -2 + NTP_4_2_7P381 + + ntpdc/ntpdc.1ntpdcmdoc@1.201 +2 -2 + NTP_4_2_7P381 + + ntpdc/ntpdc.html@1.214 +2 -2 + NTP_4_2_7P381 + + ntpdc/ntpdc.man.in@1.201 +2 -2 + NTP_4_2_7P381 + + ntpdc/ntpdc.mdoc.in@1.201 +2 -2 + NTP_4_2_7P381 + + ntpq/invoke-ntpq.texi@1.374 +2 -2 + NTP_4_2_7P381 + + ntpq/ntpq-opts.c@1.388 +7 -7 + NTP_4_2_7P381 + + ntpq/ntpq-opts.h@1.388 +3 -3 + NTP_4_2_7P381 + + ntpq/ntpq.1ntpqman@1.202 +2 -2 + NTP_4_2_7P381 + + ntpq/ntpq.1ntpqmdoc@1.202 +2 -2 + NTP_4_2_7P381 + + ntpq/ntpq.html@1.46 +2 -2 + NTP_4_2_7P381 + + ntpq/ntpq.man.in@1.202 +2 -2 + NTP_4_2_7P381 + + ntpq/ntpq.mdoc.in@1.202 +2 -2 + NTP_4_2_7P381 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.373 +2 -2 + NTP_4_2_7P381 + + ntpsnmpd/ntpsnmpd-opts.c@1.388 +7 -7 + NTP_4_2_7P381 + + ntpsnmpd/ntpsnmpd-opts.h@1.388 +3 -3 + NTP_4_2_7P381 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.202 +3 -3 + NTP_4_2_7P381 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.202 +3 -3 + NTP_4_2_7P381 + + ntpsnmpd/ntpsnmpd.html@1.44 +1 -1 + NTP_4_2_7P381 + + ntpsnmpd/ntpsnmpd.man.in@1.202 +3 -3 + NTP_4_2_7P381 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.202 +3 -3 + NTP_4_2_7P381 + + packageinfo.sh@1.384 +1 -1 + NTP_4_2_7P381 + + scripts/invoke-ntp-wait.texi@1.190 +1 -1 + NTP_4_2_7P381 + + scripts/ntp-wait.1ntp-waitman@1.201 +3 -3 + NTP_4_2_7P381 + + scripts/ntp-wait.1ntp-waitmdoc@1.201 +3 -3 + NTP_4_2_7P381 + + scripts/ntp-wait.html@1.206 +1 -1 + NTP_4_2_7P381 + + scripts/ntp-wait.man.in@1.201 +3 -3 + NTP_4_2_7P381 + + scripts/ntp-wait.mdoc.in@1.201 +3 -3 + NTP_4_2_7P381 + + sntp/invoke-sntp.texi@1.370 +2 -2 + NTP_4_2_7P381 + + sntp/sntp-opts.c@1.385 +7 -7 + NTP_4_2_7P381 + + sntp/sntp-opts.h@1.385 +3 -3 + NTP_4_2_7P381 + + sntp/sntp.1sntpman@1.205 +3 -3 + NTP_4_2_7P381 + + sntp/sntp.1sntpmdoc@1.205 +3 -3 + NTP_4_2_7P381 + + sntp/sntp.html@1.385 +2 -2 + NTP_4_2_7P381 + + sntp/sntp.man.in@1.205 +3 -3 + NTP_4_2_7P381 + + sntp/sntp.mdoc.in@1.205 +3 -3 + NTP_4_2_7P381 + + util/invoke-ntp-keygen.texi@1.374 +2 -2 + NTP_4_2_7P381 + + util/ntp-keygen-opts.c@1.388 +7 -7 + NTP_4_2_7P381 + + util/ntp-keygen-opts.h@1.388 +3 -3 + NTP_4_2_7P381 + + util/ntp-keygen.1ntp-keygenman@1.202 +3 -3 + NTP_4_2_7P381 + + util/ntp-keygen.1ntp-keygenmdoc@1.202 +3 -3 + NTP_4_2_7P381 + + util/ntp-keygen.html@1.50 +2 -2 + NTP_4_2_7P381 + + util/ntp-keygen.man.in@1.202 +3 -3 + NTP_4_2_7P381 + + util/ntp-keygen.mdoc.in@1.202 +3 -3 + NTP_4_2_7P381 + +ChangeSet@1.2972, 2013-08-07 06:31:17-04:00, stenn@deacon.udel.edu + [Bug 2458] AM_CONFIG_HEADER is obsolete + + sntp/m4/ntp_cacheversion.m4@1.14 +1 -1 + [Bug 2458] AM_CONFIG_HEADER is obsolete + +ChangeSet@1.2971, 2013-08-07 05:59:16-04:00, stenn@deacon.udel.edu + [Bug 2458] AM_CONFIG_HEADER is obsolete + + ChangeLog@1.1321 +1 -0 + [Bug 2458] AM_CONFIG_HEADER is obsolete + + configure.ac@1.561 +1 -1 + [Bug 2458] AM_CONFIG_HEADER is obsolete + +ChangeSet@1.2970, 2013-08-07 05:54:22-04:00, stenn@deacon.udel.edu + fix type in miscopt.html - thanks Michael Tatarinov! + + html/miscopt.html@1.74 +1 -1 + fix type in miscopt.html - thanks Michael Tatarinov! + +ChangeSet@1.2966.1.5, 2013-08-07 05:31:26-04:00, stenn@pogo.udel.edu + Reorder bug numbers in ChangeLog + + ChangeLog@1.1317.1.4 +3 -2 + Reorder bug numbers in ChangeLog + +ChangeSet@1.2966.1.4, 2013-08-04 01:02:28-04:00, stenn@pogo.udel.edu + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/invoke-ntp.conf.texi@1.57 +5 -3 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/keyword-gen-utd@1.20 +1 -1 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/ntp.conf.5man@1.91 +7 -3 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/ntp.conf.5mdoc@1.91 +6 -3 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/ntp.conf.man.in@1.91 +7 -3 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/ntp.conf.mdoc.in@1.91 +6 -3 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/ntp_keyword.h@1.22 +793 -789 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/ntp_parser.c@1.85 +1448 -1130 + Check in of updated files from Brian's updates for 2451,53,54 + + ntpd/ntp_parser.h@1.51 +321 -313 + Check in of updated files from Brian's updates for 2451,53,54 + +ChangeSet@1.2966.1.3, 2013-08-03 15:13:34-04:00, utterback@pogo.udel.edu + [Bug 2454] Need way to set file descriptor limit. + [Bug 2453] Need a way to avoid calling mlockall. + [Bug 2451] rlimit command is missing from the table of contents in miscopt.html + + ChangeLog@1.1317.1.3 +3 -0 + [Bug 2454] Need way to set file descriptor limit. + [Bug 2453] Need a way to avoid calling mlockall. + [Bug 2451] rlimit command is missing from the table of contents in miscopt.html + + + html/miscopt.html@1.73 +3 -1 + [Bug 2454] Need way to set file descriptor limit. + [Bug 2453] Need a way to avoid calling mlockall. + + html/scripts/miscopt.txt@1.9 +1 -0 + [Bug 2451] rlimit command is missing from the table of contents in miscopt.html + + include/ntp_config.h@1.80 +3 -0 + [Bug 2453] Need a way to avoid calling mlockall. + + ntpd/keyword-gen.c@1.25 +1 -0 + [Bug 2454] Need way to set file descriptor limit. + + ntpd/ntp.conf.def@1.8 +4 -1 + [Bug 2454] Need way to set file descriptor limit. + [Bug 2453] Need a way to avoid calling mlockall. + + ntpd/ntp_config.c@1.313 +40 -6 + [Bug 2454] Need way to set file descriptor limit. + [Bug 2453] Need a way to avoid calling mlockall. + + ntpd/ntp_parser.y@1.79 +2 -0 + [Bug 2454] Need way to set file descriptor limit. + + ntpd/ntpd.c@1.147 +34 -22 + [Bug 2454] Need way to set file descriptor limit. + [Bug 2453] Need a way to avoid calling mlockall. + +ChangeSet@1.2966.1.2, 2013-08-03 11:35:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P380 + TAG: NTP_4_2_7P380 + + ChangeLog@1.1317.1.2 +1 -0 + NTP_4_2_7P380 + + ntpd/invoke-ntp.conf.texi@1.56 +1 -1 + NTP_4_2_7P380 + + ntpd/invoke-ntp.keys.texi@1.56 +1 -1 + NTP_4_2_7P380 + + ntpd/invoke-ntpd.texi@1.372 +2 -2 + NTP_4_2_7P380 + + ntpd/ntp.conf.5man@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntp.conf.5mdoc@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntp.conf.html@1.53 +1 -1 + NTP_4_2_7P380 + + ntpd/ntp.conf.man.in@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntp.conf.mdoc.in@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntp.keys.5man@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntp.keys.5mdoc@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntp.keys.html@1.54 +1 -1 + NTP_4_2_7P380 + + ntpd/ntp.keys.man.in@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntp.keys.mdoc.in@1.90 +3 -3 + NTP_4_2_7P380 + + ntpd/ntpd-opts.c@1.390 +7 -7 + NTP_4_2_7P380 + + ntpd/ntpd-opts.h@1.390 +3 -3 + NTP_4_2_7P380 + + ntpd/ntpd.1ntpdman@1.201 +3 -3 + NTP_4_2_7P380 + + ntpd/ntpd.1ntpdmdoc@1.201 +3 -3 + NTP_4_2_7P380 + + ntpd/ntpd.html@1.48 +2 -2 + NTP_4_2_7P380 + + ntpd/ntpd.man.in@1.201 +3 -3 + NTP_4_2_7P380 + + ntpd/ntpd.mdoc.in@1.201 +3 -3 + NTP_4_2_7P380 + + ntpdc/invoke-ntpdc.texi@1.369 +2 -2 + NTP_4_2_7P380 + + ntpdc/ntpdc-opts.c@1.384 +7 -7 + NTP_4_2_7P380 + + ntpdc/ntpdc-opts.h@1.384 +3 -3 + NTP_4_2_7P380 + + ntpdc/ntpdc.1ntpdcman@1.200 +2 -2 + NTP_4_2_7P380 + + ntpdc/ntpdc.1ntpdcmdoc@1.200 +2 -2 + NTP_4_2_7P380 + + ntpdc/ntpdc.html@1.213 +2 -2 + NTP_4_2_7P380 + + ntpdc/ntpdc.man.in@1.200 +2 -2 + NTP_4_2_7P380 + + ntpdc/ntpdc.mdoc.in@1.200 +2 -2 + NTP_4_2_7P380 + + ntpq/invoke-ntpq.texi@1.373 +2 -2 + NTP_4_2_7P380 + + ntpq/ntpq-opts.c@1.387 +7 -7 + NTP_4_2_7P380 + + ntpq/ntpq-opts.h@1.387 +3 -3 + NTP_4_2_7P380 + + ntpq/ntpq.1ntpqman@1.201 +2 -2 + NTP_4_2_7P380 + + ntpq/ntpq.1ntpqmdoc@1.201 +2 -2 + NTP_4_2_7P380 + + ntpq/ntpq.html@1.45 +2 -2 + NTP_4_2_7P380 + + ntpq/ntpq.man.in@1.201 +2 -2 + NTP_4_2_7P380 + + ntpq/ntpq.mdoc.in@1.201 +2 -2 + NTP_4_2_7P380 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.372 +2 -2 + NTP_4_2_7P380 + + ntpsnmpd/ntpsnmpd-opts.c@1.387 +7 -7 + NTP_4_2_7P380 + + ntpsnmpd/ntpsnmpd-opts.h@1.387 +3 -3 + NTP_4_2_7P380 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.201 +3 -3 + NTP_4_2_7P380 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.201 +3 -3 + NTP_4_2_7P380 + + ntpsnmpd/ntpsnmpd.html@1.43 +1 -1 + NTP_4_2_7P380 + + ntpsnmpd/ntpsnmpd.man.in@1.201 +3 -3 + NTP_4_2_7P380 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.201 +3 -3 + NTP_4_2_7P380 + + packageinfo.sh@1.383 +1 -1 + NTP_4_2_7P380 + + scripts/invoke-ntp-wait.texi@1.189 +16 -1 + NTP_4_2_7P380 + + scripts/ntp-wait.1ntp-waitman@1.200 +3 -3 + NTP_4_2_7P380 + + scripts/ntp-wait.1ntp-waitmdoc@1.200 +3 -3 + NTP_4_2_7P380 + + scripts/ntp-wait.html@1.205 +17 -1 + NTP_4_2_7P380 + + scripts/ntp-wait.man.in@1.200 +3 -3 + NTP_4_2_7P380 + + scripts/ntp-wait.mdoc.in@1.200 +3 -3 + NTP_4_2_7P380 + + sntp/invoke-sntp.texi@1.369 +2 -2 + NTP_4_2_7P380 + + sntp/sntp-opts.c@1.384 +7 -7 + NTP_4_2_7P380 + + sntp/sntp-opts.h@1.384 +3 -3 + NTP_4_2_7P380 + + sntp/sntp.1sntpman@1.204 +3 -3 + NTP_4_2_7P380 + + sntp/sntp.1sntpmdoc@1.204 +3 -3 + NTP_4_2_7P380 + + sntp/sntp.html@1.384 +2 -2 + NTP_4_2_7P380 + + sntp/sntp.man.in@1.204 +3 -3 + NTP_4_2_7P380 + + sntp/sntp.mdoc.in@1.204 +3 -3 + NTP_4_2_7P380 + + util/invoke-ntp-keygen.texi@1.373 +2 -2 + NTP_4_2_7P380 + + util/ntp-keygen-opts.c@1.387 +7 -7 + NTP_4_2_7P380 + + util/ntp-keygen-opts.h@1.387 +3 -3 + NTP_4_2_7P380 + + util/ntp-keygen.1ntp-keygenman@1.201 +3 -3 + NTP_4_2_7P380 + + util/ntp-keygen.1ntp-keygenmdoc@1.201 +3 -3 + NTP_4_2_7P380 + + util/ntp-keygen.html@1.49 +2 -2 + NTP_4_2_7P380 + + util/ntp-keygen.man.in@1.201 +3 -3 + NTP_4_2_7P380 + + util/ntp-keygen.mdoc.in@1.201 +3 -3 + NTP_4_2_7P380 + +ChangeSet@1.2966.1.1, 2013-08-03 05:35:28-04:00, stenn@deacon.udel.edu + CID 984511: Some systems have different printf needs for sizeof + + ChangeLog@1.1317.1.1 +1 -0 + CID 984511: Some systems have different printf needs for sizeof + + sntp/main.c@1.92 +1 -1 + CID 984511: Some systems have different printf needs for sizeof + +ChangeSet@1.2967, 2013-08-03 08:15:49+00:00, kardel@pogo.udel.edu + ChangeLog ntpd.h, ntp_io.c: + [Bug 2452] provide io_handler/input_handler only on non HAVE_IO_COMPLETION_PORT platforms + + ChangeLog@1.1318 +2 -0 + [Bug 2452] provide io_handler/input_handler only on non HAVE_IO_COMPLETION_PORT platforms + + include/ntpd.h@1.178 +2 -0 + [Bug 2452] provide io_handler/input_handler only on HAVE_IO_COMPLETION platforms + + ntpd/ntp_io.c@1.382 +64 -64 + [Bug 2452] provide io_handler/input_handler only on HAVE_IO_COMPLETION platforms + +ChangeSet@1.2966, 2013-08-02 11:37:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P379 + TAG: NTP_4_2_7P379 + + ChangeLog@1.1317 +1 -0 + NTP_4_2_7P379 + + ntpd/invoke-ntp.conf.texi@1.55 +1 -1 + NTP_4_2_7P379 + + ntpd/invoke-ntp.keys.texi@1.55 +1 -1 + NTP_4_2_7P379 + + ntpd/invoke-ntpd.texi@1.371 +2 -2 + NTP_4_2_7P379 + + ntpd/ntp.conf.5man@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntp.conf.5mdoc@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntp.conf.html@1.52 +1 -1 + NTP_4_2_7P379 + + ntpd/ntp.conf.man.in@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntp.conf.mdoc.in@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntp.keys.5man@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntp.keys.5mdoc@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntp.keys.html@1.53 +1 -1 + NTP_4_2_7P379 + + ntpd/ntp.keys.man.in@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntp.keys.mdoc.in@1.89 +3 -3 + NTP_4_2_7P379 + + ntpd/ntpd-opts.c@1.389 +7 -7 + NTP_4_2_7P379 + + ntpd/ntpd-opts.h@1.389 +3 -3 + NTP_4_2_7P379 + + ntpd/ntpd.1ntpdman@1.200 +3 -3 + NTP_4_2_7P379 + + ntpd/ntpd.1ntpdmdoc@1.200 +3 -3 + NTP_4_2_7P379 + + ntpd/ntpd.html@1.47 +2 -2 + NTP_4_2_7P379 + + ntpd/ntpd.man.in@1.200 +3 -3 + NTP_4_2_7P379 + + ntpd/ntpd.mdoc.in@1.200 +3 -3 + NTP_4_2_7P379 + + ntpdc/invoke-ntpdc.texi@1.368 +2 -2 + NTP_4_2_7P379 + + ntpdc/ntpdc-opts.c@1.383 +7 -7 + NTP_4_2_7P379 + + ntpdc/ntpdc-opts.h@1.383 +3 -3 + NTP_4_2_7P379 + + ntpdc/ntpdc.1ntpdcman@1.199 +2 -2 + NTP_4_2_7P379 + + ntpdc/ntpdc.1ntpdcmdoc@1.199 +2 -2 + NTP_4_2_7P379 + + ntpdc/ntpdc.html@1.212 +2 -2 + NTP_4_2_7P379 + + ntpdc/ntpdc.man.in@1.199 +2 -2 + NTP_4_2_7P379 + + ntpdc/ntpdc.mdoc.in@1.199 +2 -2 + NTP_4_2_7P379 + + ntpq/invoke-ntpq.texi@1.372 +2 -2 + NTP_4_2_7P379 + + ntpq/ntpq-opts.c@1.386 +7 -7 + NTP_4_2_7P379 + + ntpq/ntpq-opts.h@1.386 +3 -3 + NTP_4_2_7P379 + + ntpq/ntpq.1ntpqman@1.200 +2 -2 + NTP_4_2_7P379 + + ntpq/ntpq.1ntpqmdoc@1.200 +2 -2 + NTP_4_2_7P379 + + ntpq/ntpq.html@1.44 +2 -2 + NTP_4_2_7P379 + + ntpq/ntpq.man.in@1.200 +2 -2 + NTP_4_2_7P379 + + ntpq/ntpq.mdoc.in@1.200 +2 -2 + NTP_4_2_7P379 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.371 +2 -2 + NTP_4_2_7P379 + + ntpsnmpd/ntpsnmpd-opts.c@1.386 +7 -7 + NTP_4_2_7P379 + + ntpsnmpd/ntpsnmpd-opts.h@1.386 +3 -3 + NTP_4_2_7P379 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.200 +3 -3 + NTP_4_2_7P379 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.200 +3 -3 + NTP_4_2_7P379 + + ntpsnmpd/ntpsnmpd.html@1.42 +1 -1 + NTP_4_2_7P379 + + ntpsnmpd/ntpsnmpd.man.in@1.200 +3 -3 + NTP_4_2_7P379 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.200 +3 -3 + NTP_4_2_7P379 + + packageinfo.sh@1.382 +1 -1 + NTP_4_2_7P379 + + scripts/invoke-ntp-wait.texi@1.188 +1 -16 + NTP_4_2_7P379 + + scripts/ntp-wait.1ntp-waitman@1.199 +3 -3 + NTP_4_2_7P379 + + scripts/ntp-wait.1ntp-waitmdoc@1.199 +3 -3 + NTP_4_2_7P379 + + scripts/ntp-wait.html@1.204 +1 -17 + NTP_4_2_7P379 + + scripts/ntp-wait.man.in@1.199 +3 -3 + NTP_4_2_7P379 + + scripts/ntp-wait.mdoc.in@1.199 +3 -3 + NTP_4_2_7P379 + + sntp/invoke-sntp.texi@1.368 +2 -2 + NTP_4_2_7P379 + + sntp/sntp-opts.c@1.383 +7 -7 + NTP_4_2_7P379 + + sntp/sntp-opts.h@1.383 +3 -3 + NTP_4_2_7P379 + + sntp/sntp.1sntpman@1.203 +3 -3 + NTP_4_2_7P379 + + sntp/sntp.1sntpmdoc@1.203 +3 -3 + NTP_4_2_7P379 + + sntp/sntp.html@1.383 +2 -2 + NTP_4_2_7P379 + + sntp/sntp.man.in@1.203 +3 -3 + NTP_4_2_7P379 + + sntp/sntp.mdoc.in@1.203 +3 -3 + NTP_4_2_7P379 + + util/invoke-ntp-keygen.texi@1.372 +2 -2 + NTP_4_2_7P379 + + util/ntp-keygen-opts.c@1.386 +7 -7 + NTP_4_2_7P379 + + util/ntp-keygen-opts.h@1.386 +3 -3 + NTP_4_2_7P379 + + util/ntp-keygen.1ntp-keygenman@1.200 +3 -3 + NTP_4_2_7P379 + + util/ntp-keygen.1ntp-keygenmdoc@1.200 +3 -3 + NTP_4_2_7P379 + + util/ntp-keygen.html@1.48 +2 -2 + NTP_4_2_7P379 + + util/ntp-keygen.man.in@1.200 +3 -3 + NTP_4_2_7P379 + + util/ntp-keygen.mdoc.in@1.200 +3 -3 + NTP_4_2_7P379 + +ChangeSet@1.2965, 2013-08-02 06:30:59-04:00, stenn@deacon.udel.edu + CID 739724: Fix printf arg mismatch in a debug line + + sntp/main.c@1.91 +1 -1 + CID 739724: Fix printf arg mismatch in a debug line + +ChangeSet@1.2964, 2013-08-02 06:28:46-04:00, stenn@deacon.udel.edu + CID 739724: Fix printf arg mismatch in a debug line + + ChangeLog@1.1316 +1 -0 + CID 739724: Fix printf arg mismatch in a debug line + + sntp/main.c@1.90 +1 -1 + CID 739724: Fix printf arg mismatch in a debug line + +ChangeSet@1.2963, 2013-08-02 06:08:47+00:00, kardel@pogo.udel.edu + ChangeLog ntp_io.c: + [Bug 2425] compile io_handler() in ntp_io.c unconditionally + + ChangeLog@1.1315 +1 -0 + [Bug 2425] compile io_handler() in ntp_io.c unconditionally + + ntpd/ntp_io.c@1.381 +7 -8 + place io_handler outside of HAVE_ROUTING_SOCKET conditional + +ChangeSet@1.2962, 2013-08-01 17:58:31-04:00, stenn@deacon.udel.edu + [Bug 2448] Fix checks for configure --with-stack-limit and --with-memlock values + + ChangeLog@1.1314 +2 -0 + [Bug 2448] Fix checks for configure --with-stack-limit and --with-memlock values + + configure.ac@1.560 +2 -2 + [Bug 2448] Fix checks for configure --with-stack-limit and --with-memlock values + +ChangeSet@1.2961, 2013-08-01 06:45:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P378 + TAG: NTP_4_2_7P378 + + ChangeLog@1.1313 +1 -0 + NTP_4_2_7P378 + + ntpd/invoke-ntp.conf.texi@1.54 +1 -1 + NTP_4_2_7P378 + + ntpd/invoke-ntp.keys.texi@1.54 +1 -1 + NTP_4_2_7P378 + + ntpd/invoke-ntpd.texi@1.370 +2 -2 + NTP_4_2_7P378 + + ntpd/ntp.conf.5man@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntp.conf.5mdoc@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntp.conf.html@1.51 +1 -1 + NTP_4_2_7P378 + + ntpd/ntp.conf.man.in@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntp.conf.mdoc.in@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntp.keys.5man@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntp.keys.5mdoc@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntp.keys.html@1.52 +1 -1 + NTP_4_2_7P378 + + ntpd/ntp.keys.man.in@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntp.keys.mdoc.in@1.88 +22 -3 + NTP_4_2_7P378 + + ntpd/ntpd-opts.c@1.388 +7 -7 + NTP_4_2_7P378 + + ntpd/ntpd-opts.h@1.388 +3 -3 + NTP_4_2_7P378 + + ntpd/ntpd.1ntpdman@1.199 +22 -3 + NTP_4_2_7P378 + + ntpd/ntpd.1ntpdmdoc@1.199 +22 -3 + NTP_4_2_7P378 + + ntpd/ntpd.html@1.46 +2 -2 + NTP_4_2_7P378 + + ntpd/ntpd.man.in@1.199 +22 -3 + NTP_4_2_7P378 + + ntpd/ntpd.mdoc.in@1.199 +22 -3 + NTP_4_2_7P378 + + ntpdc/invoke-ntpdc.texi@1.367 +2 -2 + NTP_4_2_7P378 + + ntpdc/ntpdc-opts.c@1.382 +7 -7 + NTP_4_2_7P378 + + ntpdc/ntpdc-opts.h@1.382 +3 -3 + NTP_4_2_7P378 + + ntpdc/ntpdc.1ntpdcman@1.198 +21 -2 + NTP_4_2_7P378 + + ntpdc/ntpdc.1ntpdcmdoc@1.198 +21 -2 + NTP_4_2_7P378 + + ntpdc/ntpdc.html@1.211 +57 -77 + NTP_4_2_7P378 + + ntpdc/ntpdc.man.in@1.198 +21 -2 + NTP_4_2_7P378 + + ntpdc/ntpdc.mdoc.in@1.198 +21 -2 + NTP_4_2_7P378 + + ntpq/invoke-ntpq.texi@1.371 +2 -2 + NTP_4_2_7P378 + + ntpq/ntpq-opts.c@1.385 +7 -7 + NTP_4_2_7P378 + + ntpq/ntpq-opts.h@1.385 +3 -3 + NTP_4_2_7P378 + + ntpq/ntpq.1ntpqman@1.199 +21 -2 + NTP_4_2_7P378 + + ntpq/ntpq.1ntpqmdoc@1.199 +21 -2 + NTP_4_2_7P378 + + ntpq/ntpq.html@1.43 +2 -2 + NTP_4_2_7P378 + + ntpq/ntpq.man.in@1.199 +21 -2 + NTP_4_2_7P378 + + ntpq/ntpq.mdoc.in@1.199 +21 -2 + NTP_4_2_7P378 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.370 +2 -2 + NTP_4_2_7P378 + + ntpsnmpd/ntpsnmpd-opts.c@1.385 +7 -7 + NTP_4_2_7P378 + + ntpsnmpd/ntpsnmpd-opts.h@1.385 +3 -3 + NTP_4_2_7P378 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.199 +22 -3 + NTP_4_2_7P378 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.199 +22 -3 + NTP_4_2_7P378 + + ntpsnmpd/ntpsnmpd.html@1.41 +1 -1 + NTP_4_2_7P378 + + ntpsnmpd/ntpsnmpd.man.in@1.199 +22 -3 + NTP_4_2_7P378 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.199 +22 -3 + NTP_4_2_7P378 + + packageinfo.sh@1.381 +1 -1 + NTP_4_2_7P378 + + scripts/invoke-ntp-wait.texi@1.187 +3 -3 + NTP_4_2_7P378 + + scripts/ntp-wait.1ntp-waitman@1.198 +22 -3 + NTP_4_2_7P378 + + scripts/ntp-wait.1ntp-waitmdoc@1.198 +22 -3 + NTP_4_2_7P378 + + scripts/ntp-wait.html@1.203 +40 -62 + NTP_4_2_7P378 + + scripts/ntp-wait.man.in@1.198 +22 -3 + NTP_4_2_7P378 + + scripts/ntp-wait.mdoc.in@1.198 +22 -3 + NTP_4_2_7P378 + + sntp/invoke-sntp.texi@1.367 +2 -2 + NTP_4_2_7P378 + + sntp/sntp-opts.c@1.382 +7 -7 + NTP_4_2_7P378 + + sntp/sntp-opts.h@1.382 +3 -3 + NTP_4_2_7P378 + + sntp/sntp.1sntpman@1.202 +22 -3 + NTP_4_2_7P378 + + sntp/sntp.1sntpmdoc@1.202 +22 -3 + NTP_4_2_7P378 + + sntp/sntp.html@1.382 +87 -112 + NTP_4_2_7P378 + + sntp/sntp.man.in@1.202 +22 -3 + NTP_4_2_7P378 + + sntp/sntp.mdoc.in@1.202 +22 -3 + NTP_4_2_7P378 + + util/invoke-ntp-keygen.texi@1.371 +2 -2 + NTP_4_2_7P378 + + util/ntp-keygen-opts.c@1.385 +7 -7 + NTP_4_2_7P378 + + util/ntp-keygen-opts.h@1.385 +3 -3 + NTP_4_2_7P378 + + util/ntp-keygen.1ntp-keygenman@1.199 +22 -3 + NTP_4_2_7P378 + + util/ntp-keygen.1ntp-keygenmdoc@1.199 +22 -3 + NTP_4_2_7P378 + + util/ntp-keygen.html@1.47 +2 -2 + NTP_4_2_7P378 + + util/ntp-keygen.man.in@1.199 +22 -3 + NTP_4_2_7P378 + + util/ntp-keygen.mdoc.in@1.199 +22 -3 + NTP_4_2_7P378 + +ChangeSet@1.2960, 2013-08-01 01:34:34-04:00, stenn@deacon.udel.edu + [Bug 2446] Quiet warnings from Oracle's Studio compiler + + ChangeLog@1.1312 +1 -0 + [Bug 2446] Quiet warnings from Oracle's Studio compiler + + include/ntp_stdlib.h@1.75 +11 -10 + [Bug 2446] Quiet warnings from Oracle's Studio compiler + + include/ntp_worker.h@1.3 +2 -2 + [Bug 2446] Quiet warnings from Oracle's Studio compiler + + include/ntpd.h@1.177 +2 -2 + [Bug 2446] Quiet warnings from Oracle's Studio compiler + + libntp/ntp_random.c@1.10 +5 -5 + [Bug 2446] Quiet warnings from Oracle's Studio compiler + + ntpd/refclock_oncore.c@1.98 +1 -1 + [Bug 2446] Quiet warnings from Oracle's Studio compiler + + sntp/libevent/minheap-internal.h@1.5 +1 -2 + [Bug 2446] Quiet warnings from Oracle's Studio compiler + +ChangeSet@1.2957.1.3, 2013-08-01 02:39:32+00:00, stenn@psp-fb1.ntp.org + Upgrade to AutoGen-5.18.1pre3 + + ChangeLog@1.1307.1.2 +1 -0 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/invoke-ntp.conf.texi@1.53 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/invoke-ntp.keys.texi@1.53 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/invoke-ntpd.texi@1.369 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.conf.5man@1.87 +11 -30 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.conf.5mdoc@1.87 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.conf.man.in@1.87 +11 -30 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.conf.mdoc.in@1.87 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.keys.5man@1.87 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.keys.5mdoc@1.87 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.keys.man.in@1.87 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntp.keys.mdoc.in@1.87 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpd-opts.c@1.387 +66 -66 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpd-opts.h@1.387 +3 -3 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpd.1ntpdman@1.198 +44 -63 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpd.1ntpdmdoc@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpd.man.in@1.198 +44 -63 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpd.mdoc.in@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpdsim-opts.c@1.22 +324 -167 + Upgrade to AutoGen-5.18.1pre3 + + ntpd/ntpdsim-opts.h@1.22 +47 -25 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/invoke-ntpdc.texi@1.366 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/ntpdc-opts.c@1.381 +67 -67 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/ntpdc-opts.h@1.381 +3 -3 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/ntpdc.1ntpdcman@1.197 +17 -36 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/ntpdc.1ntpdcmdoc@1.197 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/ntpdc.html@1.210 +75 -55 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/ntpdc.man.in@1.197 +17 -36 + Upgrade to AutoGen-5.18.1pre3 + + ntpdc/ntpdc.mdoc.in@1.197 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpq/invoke-ntpq.texi@1.370 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + ntpq/ntpq-opts.c@1.384 +67 -67 + Upgrade to AutoGen-5.18.1pre3 + + ntpq/ntpq-opts.h@1.384 +3 -3 + Upgrade to AutoGen-5.18.1pre3 + + ntpq/ntpq.1ntpqman@1.198 +15 -34 + Upgrade to AutoGen-5.18.1pre3 + + ntpq/ntpq.1ntpqmdoc@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpq/ntpq.man.in@1.198 +15 -34 + Upgrade to AutoGen-5.18.1pre3 + + ntpq/ntpq.mdoc.in@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.369 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + ntpsnmpd/ntpsnmpd-opts.c@1.384 +67 -67 + Upgrade to AutoGen-5.18.1pre3 + + ntpsnmpd/ntpsnmpd-opts.h@1.384 +3 -3 + Upgrade to AutoGen-5.18.1pre3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.198 +5 -24 + Upgrade to AutoGen-5.18.1pre3 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + ntpsnmpd/ntpsnmpd.man.in@1.198 +5 -24 + Upgrade to AutoGen-5.18.1pre3 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + scripts/invoke-ntp-wait.texi@1.186 +3 -3 + Upgrade to AutoGen-5.18.1pre3 + + scripts/ntp-wait.1ntp-waitman@1.197 +6 -25 + Upgrade to AutoGen-5.18.1pre3 + + scripts/ntp-wait.1ntp-waitmdoc@1.197 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + scripts/ntp-wait.html@1.202 +61 -39 + Upgrade to AutoGen-5.18.1pre3 + + scripts/ntp-wait.man.in@1.197 +6 -25 + Upgrade to AutoGen-5.18.1pre3 + + scripts/ntp-wait.mdoc.in@1.197 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + sntp/include/autogen-version.def@1.18 +2 -2 + Upgrade to AutoGen-5.18.1pre3 + + sntp/invoke-sntp.texi@1.366 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + sntp/sntp-opts.c@1.381 +67 -67 + Upgrade to AutoGen-5.18.1pre3 + + sntp/sntp-opts.h@1.381 +3 -3 + Upgrade to AutoGen-5.18.1pre3 + + sntp/sntp.1sntpman@1.201 +20 -39 + Upgrade to AutoGen-5.18.1pre3 + + sntp/sntp.1sntpmdoc@1.201 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + sntp/sntp.html@1.381 +110 -85 + Upgrade to AutoGen-5.18.1pre3 + + sntp/sntp.man.in@1.201 +20 -39 + Upgrade to AutoGen-5.18.1pre3 + + sntp/sntp.mdoc.in@1.201 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + util/invoke-ntp-keygen.texi@1.370 +1 -1 + Upgrade to AutoGen-5.18.1pre3 + + util/ntp-keygen-opts.c@1.384 +67 -67 + Upgrade to AutoGen-5.18.1pre3 + + util/ntp-keygen-opts.h@1.384 +3 -3 + Upgrade to AutoGen-5.18.1pre3 + + util/ntp-keygen.1ntp-keygenman@1.198 +45 -64 + Upgrade to AutoGen-5.18.1pre3 + + util/ntp-keygen.1ntp-keygenmdoc@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + + util/ntp-keygen.man.in@1.198 +45 -64 + Upgrade to AutoGen-5.18.1pre3 + + util/ntp-keygen.mdoc.in@1.198 +3 -22 + Upgrade to AutoGen-5.18.1pre3 + +ChangeSet@1.2957.1.2, 2013-08-01 02:05:18+00:00, stenn@psp-fb1.ntp.org + Upgrade to libopts-40.1.15 + + ChangeLog@1.1307.1.1 +1 -0 + Upgrade to libopts-40.1.15 + +ChangeSet@1.2957.1.1, 2013-08-01 02:03:52+00:00, stenn@psp-fb1.ntp.org + Upgrade to libopts-40.1.15 + + sntp/libopts/Makefile.am@1.22 +6 -6 + Upgrade to libopts-40.1.15 + + sntp/libopts/ag-char-map.h@1.25 +5 -5 + Upgrade to libopts-40.1.15 + + sntp/libopts/ao-strs.c@1.11 +1 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/ao-strs.h@1.10 +1 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/autoopts.c@1.18 +22 -22 + Upgrade to libopts-40.1.15 + + sntp/libopts/autoopts.h@1.16 +11 -0 + Upgrade to libopts-40.1.15 + + sntp/libopts/autoopts/options.h@1.24 +4 -4 + Upgrade to libopts-40.1.15 + + sntp/libopts/autoopts/usage-txt.h@1.24 +61 -61 + Upgrade to libopts-40.1.15 + + sntp/libopts/compat/pathfind.c@1.10 +22 -76 + Upgrade to libopts-40.1.15 + + sntp/libopts/compat/strchr.c@1.4 +2 -2 + Upgrade to libopts-40.1.15 + + sntp/libopts/configfile.c@1.20 +12 -5 + Upgrade to libopts-40.1.15 + + sntp/libopts/find.c@1.9 +10 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/genshell.c@1.25 +20 -20 + Upgrade to libopts-40.1.15 + + sntp/libopts/genshell.h@1.25 +3 -3 + Upgrade to libopts-40.1.15 + + sntp/libopts/init.c@1.5 +6 -6 + Upgrade to libopts-40.1.15 + + sntp/libopts/load.c@1.18 +164 -117 + Upgrade to libopts-40.1.15 + + sntp/libopts/m4/libopts.m4@1.28 +1 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/option-value-type.c@1.12 +1 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/option-value-type.h@1.26 +1 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/option-xat-attribute.c@1.12 +1 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/option-xat-attribute.h@1.26 +1 -1 + Upgrade to libopts-40.1.15 + + sntp/libopts/pgusage.c@1.15 +4 -0 + Upgrade to libopts-40.1.15 + + sntp/libopts/proto.h@1.25 +3 -3 + Upgrade to libopts-40.1.15 + + sntp/libopts/streqvcmp.c@1.14 +2 -2 + Upgrade to libopts-40.1.15 + + sntp/libopts/text_mmap.c@1.15 +25 -18 + Upgrade to libopts-40.1.15 + + sntp/libopts/usage.c@1.18 +1 -0 + Upgrade to libopts-40.1.15 + +ChangeSet@1.2958, 2013-07-31 08:45:06+00:00, kardel@pogo.udel.edu + ntpd.c, ntp_io.c, ChangeLog, ntpd.h, iosignal.h: + [Bug 2425] move part of input handler code from ntpd.c to ntp_io.c + and fix select() only platforms calling input_handler directly. + + ChangeLog@1.1310 +1 -1 + fix wording + + ChangeLog@1.1309 +1 -1 + fix spelling + + ChangeLog@1.1308 +2 -0 + [Bug 2425] move part of inputhandle code from ntpd.c to ntp_io.c + and fix select() only platforms callint input_handler. + + include/iosignal.h@1.8 +3 -3 + [Bug 2425] move part of inputhandle code from ntpd.c to ntp_io.c + and fix select() only platforms callint input_handler. + + include/ntpd.h@1.176 +1 -3 + [Bug 2425] move part of inputhandle code from ntpd.c to ntp_io.c + and fix select() only platforms callint input_handler.. + + ntpd/ntp_io.c@1.380 +69 -4 + [Bug 2425] move part of inputhandle code from ntpd.c to ntp_io.c + and fix select() only platforms callint input_handler. + + ntpd/ntpd.c@1.146 +6 -61 + [Bug 2425] move part of inputhandle code from ntpd.c to ntp_io.c + and fix select() only platforms callint input_handler.. + +ChangeSet@1.2957, 2013-07-28 11:41:08+00:00, stenn@deacon.udel.edu + NTP_4_2_7P377 + TAG: NTP_4_2_7P377 + + ChangeLog@1.1307 +1 -0 + NTP_4_2_7P377 + + ntpd/invoke-ntp.conf.texi@1.52 +1 -1 + NTP_4_2_7P377 + + ntpd/invoke-ntp.keys.texi@1.52 +1 -1 + NTP_4_2_7P377 + + ntpd/invoke-ntpd.texi@1.368 +2 -2 + NTP_4_2_7P377 + + ntpd/ntp.conf.5man@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntp.conf.5mdoc@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntp.conf.html@1.50 +1 -1 + NTP_4_2_7P377 + + ntpd/ntp.conf.man.in@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntp.conf.mdoc.in@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntp.keys.5man@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntp.keys.5mdoc@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntp.keys.html@1.51 +1 -1 + NTP_4_2_7P377 + + ntpd/ntp.keys.man.in@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntp.keys.mdoc.in@1.86 +3 -3 + NTP_4_2_7P377 + + ntpd/ntpd-opts.c@1.386 +7 -7 + NTP_4_2_7P377 + + ntpd/ntpd-opts.h@1.386 +3 -3 + NTP_4_2_7P377 + + ntpd/ntpd.1ntpdman@1.197 +3 -3 + NTP_4_2_7P377 + + ntpd/ntpd.1ntpdmdoc@1.197 +3 -3 + NTP_4_2_7P377 + + ntpd/ntpd.html@1.45 +2 -2 + NTP_4_2_7P377 + + ntpd/ntpd.man.in@1.197 +3 -3 + NTP_4_2_7P377 + + ntpd/ntpd.mdoc.in@1.197 +3 -3 + NTP_4_2_7P377 + + ntpdc/invoke-ntpdc.texi@1.365 +2 -2 + NTP_4_2_7P377 + + ntpdc/ntpdc-opts.c@1.380 +7 -7 + NTP_4_2_7P377 + + ntpdc/ntpdc-opts.h@1.380 +3 -3 + NTP_4_2_7P377 + + ntpdc/ntpdc.1ntpdcman@1.196 +2 -2 + NTP_4_2_7P377 + + ntpdc/ntpdc.1ntpdcmdoc@1.196 +2 -2 + NTP_4_2_7P377 + + ntpdc/ntpdc.html@1.209 +2 -2 + NTP_4_2_7P377 + + ntpdc/ntpdc.man.in@1.196 +2 -2 + NTP_4_2_7P377 + + ntpdc/ntpdc.mdoc.in@1.196 +2 -2 + NTP_4_2_7P377 + + ntpq/invoke-ntpq.texi@1.369 +2 -2 + NTP_4_2_7P377 + + ntpq/ntpq-opts.c@1.383 +7 -7 + NTP_4_2_7P377 + + ntpq/ntpq-opts.h@1.383 +3 -3 + NTP_4_2_7P377 + + ntpq/ntpq.1ntpqman@1.197 +2 -2 + NTP_4_2_7P377 + + ntpq/ntpq.1ntpqmdoc@1.197 +2 -2 + NTP_4_2_7P377 + + ntpq/ntpq.html@1.42 +2 -2 + NTP_4_2_7P377 + + ntpq/ntpq.man.in@1.197 +2 -2 + NTP_4_2_7P377 + + ntpq/ntpq.mdoc.in@1.197 +2 -2 + NTP_4_2_7P377 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.368 +2 -2 + NTP_4_2_7P377 + + ntpsnmpd/ntpsnmpd-opts.c@1.383 +7 -7 + NTP_4_2_7P377 + + ntpsnmpd/ntpsnmpd-opts.h@1.383 +3 -3 + NTP_4_2_7P377 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.197 +3 -3 + NTP_4_2_7P377 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.197 +3 -3 + NTP_4_2_7P377 + + ntpsnmpd/ntpsnmpd.html@1.40 +1 -1 + NTP_4_2_7P377 + + ntpsnmpd/ntpsnmpd.man.in@1.197 +3 -3 + NTP_4_2_7P377 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.197 +3 -3 + NTP_4_2_7P377 + + packageinfo.sh@1.380 +1 -1 + NTP_4_2_7P377 + + scripts/invoke-ntp-wait.texi@1.185 +1 -1 + NTP_4_2_7P377 + + scripts/ntp-wait.1ntp-waitman@1.196 +3 -3 + NTP_4_2_7P377 + + scripts/ntp-wait.1ntp-waitmdoc@1.196 +3 -3 + NTP_4_2_7P377 + + scripts/ntp-wait.html@1.201 +1 -1 + NTP_4_2_7P377 + + scripts/ntp-wait.man.in@1.196 +3 -3 + NTP_4_2_7P377 + + scripts/ntp-wait.mdoc.in@1.196 +3 -3 + NTP_4_2_7P377 + + sntp/invoke-sntp.texi@1.365 +2 -2 + NTP_4_2_7P377 + + sntp/sntp-opts.c@1.380 +7 -7 + NTP_4_2_7P377 + + sntp/sntp-opts.h@1.380 +3 -3 + NTP_4_2_7P377 + + sntp/sntp.1sntpman@1.200 +3 -3 + NTP_4_2_7P377 + + sntp/sntp.1sntpmdoc@1.200 +3 -3 + NTP_4_2_7P377 + + sntp/sntp.html@1.380 +2 -2 + NTP_4_2_7P377 + + sntp/sntp.man.in@1.200 +3 -3 + NTP_4_2_7P377 + + sntp/sntp.mdoc.in@1.200 +3 -3 + NTP_4_2_7P377 + + util/invoke-ntp-keygen.texi@1.369 +2 -2 + NTP_4_2_7P377 + + util/ntp-keygen-opts.c@1.383 +7 -7 + NTP_4_2_7P377 + + util/ntp-keygen-opts.h@1.383 +3 -3 + NTP_4_2_7P377 + + util/ntp-keygen.1ntp-keygenman@1.197 +3 -3 + NTP_4_2_7P377 + + util/ntp-keygen.1ntp-keygenmdoc@1.197 +3 -3 + NTP_4_2_7P377 + + util/ntp-keygen.html@1.46 +2 -2 + NTP_4_2_7P377 + + util/ntp-keygen.man.in@1.197 +3 -3 + NTP_4_2_7P377 + + util/ntp-keygen.mdoc.in@1.197 +3 -3 + NTP_4_2_7P377 + +ChangeSet@1.2956, 2013-07-28 04:16:23-04:00, stenn@deacon.udel.edu + [Bug 2397] License/copyright cleanup + + ChangeLog@1.1306 +1 -0 + [Bug 2397] License/copyright cleanup + + include/timepps-SCO.h@1.3 +1 -1 + [Bug 2397] License/copyright cleanup + + include/timepps-Solaris.h@1.7 +1 -1 + [Bug 2397] License/copyright cleanup + + include/timepps-SunOS.h@1.4 +1 -1 + [Bug 2397] License/copyright cleanup + + ports/winnt/include/timepps.h@1.3 +1 -1 + [Bug 2397] License/copyright cleanup + + ports/winnt/ppsapi/loopback/monolithic-serialpps-timepps.h@1.2 +1 -1 + [Bug 2397] License/copyright cleanup + + ports/winnt/ppsapi/loopback/monolithic-serialpps-timepps.txt@1.2 +1 -1 + [Bug 2397] License/copyright cleanup + + ports/winnt/ppsapi/loopback/src/timepps.h@1.2 +1 -1 + [Bug 2397] License/copyright cleanup + +ChangeSet@1.2955, 2013-07-28 02:28:23-04:00, stenn@deacon.udel.edu + [Bug 2439] Fix check of EscapeCommFunction() in ports/winnt/libntp/termios.c + + ChangeLog@1.1305 +1 -0 + [Bug 2439] Fix check of EscapeCommFunction() in ports/winnt/libntp/termios.c + + ports/winnt/libntp/termios.c@1.29 +2 -2 + [Bug 2439] Fix check of EscapeCommFunction() in ports/winnt/libntp/termios.c + +ChangeSet@1.2954, 2013-07-24 11:38:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P376 + TAG: NTP_4_2_7P376 + + ChangeLog@1.1304 +1 -0 + NTP_4_2_7P376 + + ntpd/invoke-ntp.conf.texi@1.51 +1 -1 + NTP_4_2_7P376 + + ntpd/invoke-ntp.keys.texi@1.51 +1 -1 + NTP_4_2_7P376 + + ntpd/invoke-ntpd.texi@1.367 +2 -2 + NTP_4_2_7P376 + + ntpd/ntp.conf.5man@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntp.conf.5mdoc@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntp.conf.html@1.49 +1 -1 + NTP_4_2_7P376 + + ntpd/ntp.conf.man.in@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntp.conf.mdoc.in@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntp.keys.5man@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntp.keys.5mdoc@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntp.keys.html@1.50 +1 -1 + NTP_4_2_7P376 + + ntpd/ntp.keys.man.in@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntp.keys.mdoc.in@1.85 +3 -3 + NTP_4_2_7P376 + + ntpd/ntpd-opts.c@1.385 +7 -7 + NTP_4_2_7P376 + + ntpd/ntpd-opts.h@1.385 +3 -3 + NTP_4_2_7P376 + + ntpd/ntpd.1ntpdman@1.196 +3 -3 + NTP_4_2_7P376 + + ntpd/ntpd.1ntpdmdoc@1.196 +3 -3 + NTP_4_2_7P376 + + ntpd/ntpd.html@1.44 +2 -2 + NTP_4_2_7P376 + + ntpd/ntpd.man.in@1.196 +3 -3 + NTP_4_2_7P376 + + ntpd/ntpd.mdoc.in@1.196 +3 -3 + NTP_4_2_7P376 + + ntpdc/invoke-ntpdc.texi@1.364 +2 -2 + NTP_4_2_7P376 + + ntpdc/ntpdc-opts.c@1.379 +7 -7 + NTP_4_2_7P376 + + ntpdc/ntpdc-opts.h@1.379 +3 -3 + NTP_4_2_7P376 + + ntpdc/ntpdc.1ntpdcman@1.195 +2 -2 + NTP_4_2_7P376 + + ntpdc/ntpdc.1ntpdcmdoc@1.195 +2 -2 + NTP_4_2_7P376 + + ntpdc/ntpdc.html@1.208 +2 -2 + NTP_4_2_7P376 + + ntpdc/ntpdc.man.in@1.195 +2 -2 + NTP_4_2_7P376 + + ntpdc/ntpdc.mdoc.in@1.195 +2 -2 + NTP_4_2_7P376 + + ntpq/invoke-ntpq.texi@1.368 +2 -2 + NTP_4_2_7P376 + + ntpq/ntpq-opts.c@1.382 +7 -7 + NTP_4_2_7P376 + + ntpq/ntpq-opts.h@1.382 +3 -3 + NTP_4_2_7P376 + + ntpq/ntpq.1ntpqman@1.196 +2 -2 + NTP_4_2_7P376 + + ntpq/ntpq.1ntpqmdoc@1.196 +2 -2 + NTP_4_2_7P376 + + ntpq/ntpq.html@1.41 +2 -2 + NTP_4_2_7P376 + + ntpq/ntpq.man.in@1.196 +2 -2 + NTP_4_2_7P376 + + ntpq/ntpq.mdoc.in@1.196 +2 -2 + NTP_4_2_7P376 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.367 +2 -2 + NTP_4_2_7P376 + + ntpsnmpd/ntpsnmpd-opts.c@1.382 +7 -7 + NTP_4_2_7P376 + + ntpsnmpd/ntpsnmpd-opts.h@1.382 +3 -3 + NTP_4_2_7P376 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.196 +3 -3 + NTP_4_2_7P376 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.196 +3 -3 + NTP_4_2_7P376 + + ntpsnmpd/ntpsnmpd.html@1.39 +1 -1 + NTP_4_2_7P376 + + ntpsnmpd/ntpsnmpd.man.in@1.196 +3 -3 + NTP_4_2_7P376 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.196 +3 -3 + NTP_4_2_7P376 + + packageinfo.sh@1.379 +1 -1 + NTP_4_2_7P376 + + scripts/invoke-ntp-wait.texi@1.184 +1 -1 + NTP_4_2_7P376 + + scripts/ntp-wait.1ntp-waitman@1.195 +3 -3 + NTP_4_2_7P376 + + scripts/ntp-wait.1ntp-waitmdoc@1.195 +3 -3 + NTP_4_2_7P376 + + scripts/ntp-wait.html@1.200 +1 -1 + NTP_4_2_7P376 + + scripts/ntp-wait.man.in@1.195 +3 -3 + NTP_4_2_7P376 + + scripts/ntp-wait.mdoc.in@1.195 +3 -3 + NTP_4_2_7P376 + + sntp/invoke-sntp.texi@1.364 +2 -2 + NTP_4_2_7P376 + + sntp/sntp-opts.c@1.379 +7 -7 + NTP_4_2_7P376 + + sntp/sntp-opts.h@1.379 +3 -3 + NTP_4_2_7P376 + + sntp/sntp.1sntpman@1.199 +3 -3 + NTP_4_2_7P376 + + sntp/sntp.1sntpmdoc@1.199 +3 -3 + NTP_4_2_7P376 + + sntp/sntp.html@1.379 +2 -2 + NTP_4_2_7P376 + + sntp/sntp.man.in@1.199 +3 -3 + NTP_4_2_7P376 + + sntp/sntp.mdoc.in@1.199 +3 -3 + NTP_4_2_7P376 + + util/invoke-ntp-keygen.texi@1.368 +2 -2 + NTP_4_2_7P376 + + util/ntp-keygen-opts.c@1.382 +7 -7 + NTP_4_2_7P376 + + util/ntp-keygen-opts.h@1.382 +3 -3 + NTP_4_2_7P376 + + util/ntp-keygen.1ntp-keygenman@1.196 +3 -3 + NTP_4_2_7P376 + + util/ntp-keygen.1ntp-keygenmdoc@1.196 +3 -3 + NTP_4_2_7P376 + + util/ntp-keygen.html@1.45 +2 -2 + NTP_4_2_7P376 + + util/ntp-keygen.man.in@1.196 +3 -3 + NTP_4_2_7P376 + + util/ntp-keygen.mdoc.in@1.196 +3 -3 + NTP_4_2_7P376 + +ChangeSet@1.2953, 2013-07-24 05:46:25-04:00, stenn@deacon.udel.edu + [Bug 2322] Oncore driver should send 0 PPS offset to GPS + + ChangeLog@1.1303 +1 -0 + [Bug 2322] Oncore driver should send 0 PPS offset to GPS + + ntpd/refclock_oncore.c@1.97 +3 -5 + [Bug 2322] Oncore driver should send 0 PPS offset to GPS + +ChangeSet@1.2952, 2013-07-22 11:40:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P375 + TAG: NTP_4_2_7P375 + + ChangeLog@1.1302 +1 -0 + NTP_4_2_7P375 + + ntpd/invoke-ntp.conf.texi@1.50 +1 -1 + NTP_4_2_7P375 + + ntpd/invoke-ntp.keys.texi@1.50 +1 -1 + NTP_4_2_7P375 + + ntpd/invoke-ntpd.texi@1.366 +2 -2 + NTP_4_2_7P375 + + ntpd/ntp.conf.5man@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntp.conf.5mdoc@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntp.conf.html@1.48 +1 -1 + NTP_4_2_7P375 + + ntpd/ntp.conf.man.in@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntp.conf.mdoc.in@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntp.keys.5man@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntp.keys.5mdoc@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntp.keys.html@1.49 +1 -1 + NTP_4_2_7P375 + + ntpd/ntp.keys.man.in@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntp.keys.mdoc.in@1.84 +3 -3 + NTP_4_2_7P375 + + ntpd/ntpd-opts.c@1.384 +7 -7 + NTP_4_2_7P375 + + ntpd/ntpd-opts.h@1.384 +3 -3 + NTP_4_2_7P375 + + ntpd/ntpd.1ntpdman@1.195 +3 -3 + NTP_4_2_7P375 + + ntpd/ntpd.1ntpdmdoc@1.195 +3 -3 + NTP_4_2_7P375 + + ntpd/ntpd.html@1.43 +2 -2 + NTP_4_2_7P375 + + ntpd/ntpd.man.in@1.195 +3 -3 + NTP_4_2_7P375 + + ntpd/ntpd.mdoc.in@1.195 +3 -3 + NTP_4_2_7P375 + + ntpdc/invoke-ntpdc.texi@1.363 +2 -2 + NTP_4_2_7P375 + + ntpdc/ntpdc-opts.c@1.378 +7 -7 + NTP_4_2_7P375 + + ntpdc/ntpdc-opts.h@1.378 +3 -3 + NTP_4_2_7P375 + + ntpdc/ntpdc.1ntpdcman@1.194 +2 -2 + NTP_4_2_7P375 + + ntpdc/ntpdc.1ntpdcmdoc@1.194 +2 -2 + NTP_4_2_7P375 + + ntpdc/ntpdc.html@1.207 +2 -2 + NTP_4_2_7P375 + + ntpdc/ntpdc.man.in@1.194 +2 -2 + NTP_4_2_7P375 + + ntpdc/ntpdc.mdoc.in@1.194 +2 -2 + NTP_4_2_7P375 + + ntpq/invoke-ntpq.texi@1.367 +2 -2 + NTP_4_2_7P375 + + ntpq/ntpq-opts.c@1.381 +7 -7 + NTP_4_2_7P375 + + ntpq/ntpq-opts.h@1.381 +3 -3 + NTP_4_2_7P375 + + ntpq/ntpq.1ntpqman@1.195 +2 -2 + NTP_4_2_7P375 + + ntpq/ntpq.1ntpqmdoc@1.195 +2 -2 + NTP_4_2_7P375 + + ntpq/ntpq.html@1.40 +2 -2 + NTP_4_2_7P375 + + ntpq/ntpq.man.in@1.195 +2 -2 + NTP_4_2_7P375 + + ntpq/ntpq.mdoc.in@1.195 +2 -2 + NTP_4_2_7P375 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.366 +2 -2 + NTP_4_2_7P375 + + ntpsnmpd/ntpsnmpd-opts.c@1.381 +7 -7 + NTP_4_2_7P375 + + ntpsnmpd/ntpsnmpd-opts.h@1.381 +3 -3 + NTP_4_2_7P375 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.195 +3 -3 + NTP_4_2_7P375 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.195 +3 -3 + NTP_4_2_7P375 + + ntpsnmpd/ntpsnmpd.html@1.38 +1 -1 + NTP_4_2_7P375 + + ntpsnmpd/ntpsnmpd.man.in@1.195 +3 -3 + NTP_4_2_7P375 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.195 +3 -3 + NTP_4_2_7P375 + + packageinfo.sh@1.378 +1 -1 + NTP_4_2_7P375 + + scripts/invoke-ntp-wait.texi@1.183 +1 -1 + NTP_4_2_7P375 + + scripts/ntp-wait.1ntp-waitman@1.194 +3 -3 + NTP_4_2_7P375 + + scripts/ntp-wait.1ntp-waitmdoc@1.194 +3 -3 + NTP_4_2_7P375 + + scripts/ntp-wait.html@1.199 +1 -1 + NTP_4_2_7P375 + + scripts/ntp-wait.man.in@1.194 +3 -3 + NTP_4_2_7P375 + + scripts/ntp-wait.mdoc.in@1.194 +3 -3 + NTP_4_2_7P375 + + sntp/invoke-sntp.texi@1.363 +2 -2 + NTP_4_2_7P375 + + sntp/sntp-opts.c@1.378 +7 -7 + NTP_4_2_7P375 + + sntp/sntp-opts.h@1.378 +3 -3 + NTP_4_2_7P375 + + sntp/sntp.1sntpman@1.198 +3 -3 + NTP_4_2_7P375 + + sntp/sntp.1sntpmdoc@1.198 +3 -3 + NTP_4_2_7P375 + + sntp/sntp.html@1.378 +2 -2 + NTP_4_2_7P375 + + sntp/sntp.man.in@1.198 +3 -3 + NTP_4_2_7P375 + + sntp/sntp.mdoc.in@1.198 +3 -3 + NTP_4_2_7P375 + + util/invoke-ntp-keygen.texi@1.367 +2 -2 + NTP_4_2_7P375 + + util/ntp-keygen-opts.c@1.381 +7 -7 + NTP_4_2_7P375 + + util/ntp-keygen-opts.h@1.381 +3 -3 + NTP_4_2_7P375 + + util/ntp-keygen.1ntp-keygenman@1.195 +3 -3 + NTP_4_2_7P375 + + util/ntp-keygen.1ntp-keygenmdoc@1.195 +3 -3 + NTP_4_2_7P375 + + util/ntp-keygen.html@1.44 +2 -2 + NTP_4_2_7P375 + + util/ntp-keygen.man.in@1.195 +3 -3 + NTP_4_2_7P375 + + util/ntp-keygen.mdoc.in@1.195 +3 -3 + NTP_4_2_7P375 + +ChangeSet@1.2951, 2013-07-22 06:50:54-04:00, stenn@deacon.udel.edu + [Bug 883] log warning arguments swapped in refclock_gpsvme.c + + ChangeLog@1.1301 +1 -0 + [Bug 883] log warning arguments swapped in refclock_gpsvme.c + + ntpd/refclock_gpsvme.c@1.10 +1 -1 + [Bug 883] log warning arguments swapped in refclock_gpsvme.c + +ChangeSet@1.2950, 2013-07-22 06:39:38-04:00, stenn@deacon.udel.edu + [Bug 2434] Line-buffer (v. block-buffer) stdout + + ChangeLog@1.1300 +1 -0 + [Bug 2434] Line-buffer (v. block-buffer) stdout + + ntpd/ntpd.c@1.145 +3 -0 + [Bug 2434] Line-buffer (v. block-buffer) stdout + +ChangeSet@1.2946.1.22, 2013-07-21 17:50:57-04:00, murray@pogo.udel.edu + test.sh, ChangeLog: + Correct bug in previous attempt to fix bug-2368. + + ChangeLog@1.1296.1.19 +1 -0 + Correct bug in previous attempt to fix bug-2368. + + sntp/libevent/test/test.sh@1.9 +1 -1 + Correct bug in previous attempt to fix bug-2368. + +ChangeSet@1.2946.1.21, 2013-07-21 11:39:42+00:00, stenn@deacon.udel.edu + NTP_4_2_7P374 + TAG: NTP_4_2_7P374 + + ChangeLog@1.1296.1.18 +1 -0 + NTP_4_2_7P374 + + ntpd/invoke-ntp.conf.texi@1.49 +1 -1 + NTP_4_2_7P374 + + ntpd/invoke-ntp.keys.texi@1.49 +1 -1 + NTP_4_2_7P374 + + ntpd/invoke-ntpd.texi@1.365 +2 -2 + NTP_4_2_7P374 + + ntpd/ntp.conf.5man@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntp.conf.5mdoc@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntp.conf.html@1.47 +1 -1 + NTP_4_2_7P374 + + ntpd/ntp.conf.man.in@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntp.conf.mdoc.in@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntp.keys.5man@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntp.keys.5mdoc@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntp.keys.html@1.48 +1 -1 + NTP_4_2_7P374 + + ntpd/ntp.keys.man.in@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntp.keys.mdoc.in@1.83 +3 -3 + NTP_4_2_7P374 + + ntpd/ntpd-opts.c@1.383 +7 -7 + NTP_4_2_7P374 + + ntpd/ntpd-opts.h@1.383 +3 -3 + NTP_4_2_7P374 + + ntpd/ntpd.1ntpdman@1.194 +3 -3 + NTP_4_2_7P374 + + ntpd/ntpd.1ntpdmdoc@1.194 +3 -3 + NTP_4_2_7P374 + + ntpd/ntpd.html@1.42 +2 -2 + NTP_4_2_7P374 + + ntpd/ntpd.man.in@1.194 +3 -3 + NTP_4_2_7P374 + + ntpd/ntpd.mdoc.in@1.194 +3 -3 + NTP_4_2_7P374 + + ntpdc/invoke-ntpdc.texi@1.362 +2 -2 + NTP_4_2_7P374 + + ntpdc/ntpdc-opts.c@1.377 +7 -7 + NTP_4_2_7P374 + + ntpdc/ntpdc-opts.h@1.377 +3 -3 + NTP_4_2_7P374 + + ntpdc/ntpdc.1ntpdcman@1.193 +2 -2 + NTP_4_2_7P374 + + ntpdc/ntpdc.1ntpdcmdoc@1.193 +2 -2 + NTP_4_2_7P374 + + ntpdc/ntpdc.html@1.206 +2 -2 + NTP_4_2_7P374 + + ntpdc/ntpdc.man.in@1.193 +2 -2 + NTP_4_2_7P374 + + ntpdc/ntpdc.mdoc.in@1.193 +2 -2 + NTP_4_2_7P374 + + ntpq/invoke-ntpq.texi@1.366 +2 -2 + NTP_4_2_7P374 + + ntpq/ntpq-opts.c@1.380 +7 -7 + NTP_4_2_7P374 + + ntpq/ntpq-opts.h@1.380 +3 -3 + NTP_4_2_7P374 + + ntpq/ntpq.1ntpqman@1.194 +2 -2 + NTP_4_2_7P374 + + ntpq/ntpq.1ntpqmdoc@1.194 +2 -2 + NTP_4_2_7P374 + + ntpq/ntpq.html@1.39 +2 -2 + NTP_4_2_7P374 + + ntpq/ntpq.man.in@1.194 +2 -2 + NTP_4_2_7P374 + + ntpq/ntpq.mdoc.in@1.194 +2 -2 + NTP_4_2_7P374 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.365 +2 -2 + NTP_4_2_7P374 + + ntpsnmpd/ntpsnmpd-opts.c@1.380 +7 -7 + NTP_4_2_7P374 + + ntpsnmpd/ntpsnmpd-opts.h@1.380 +3 -3 + NTP_4_2_7P374 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.194 +3 -3 + NTP_4_2_7P374 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.194 +3 -3 + NTP_4_2_7P374 + + ntpsnmpd/ntpsnmpd.html@1.37 +1 -1 + NTP_4_2_7P374 + + ntpsnmpd/ntpsnmpd.man.in@1.194 +3 -3 + NTP_4_2_7P374 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.194 +3 -3 + NTP_4_2_7P374 + + packageinfo.sh@1.377 +1 -1 + NTP_4_2_7P374 + + scripts/invoke-ntp-wait.texi@1.182 +1 -1 + NTP_4_2_7P374 + + scripts/ntp-wait.1ntp-waitman@1.193 +3 -3 + NTP_4_2_7P374 + + scripts/ntp-wait.1ntp-waitmdoc@1.193 +3 -3 + NTP_4_2_7P374 + + scripts/ntp-wait.html@1.198 +1 -1 + NTP_4_2_7P374 + + scripts/ntp-wait.man.in@1.193 +3 -3 + NTP_4_2_7P374 + + scripts/ntp-wait.mdoc.in@1.193 +3 -3 + NTP_4_2_7P374 + + sntp/invoke-sntp.texi@1.362 +2 -2 + NTP_4_2_7P374 + + sntp/sntp-opts.c@1.377 +7 -7 + NTP_4_2_7P374 + + sntp/sntp-opts.h@1.377 +3 -3 + NTP_4_2_7P374 + + sntp/sntp.1sntpman@1.197 +3 -3 + NTP_4_2_7P374 + + sntp/sntp.1sntpmdoc@1.197 +3 -3 + NTP_4_2_7P374 + + sntp/sntp.html@1.377 +2 -2 + NTP_4_2_7P374 + + sntp/sntp.man.in@1.197 +3 -3 + NTP_4_2_7P374 + + sntp/sntp.mdoc.in@1.197 +3 -3 + NTP_4_2_7P374 + + util/invoke-ntp-keygen.texi@1.366 +2 -2 + NTP_4_2_7P374 + + util/ntp-keygen-opts.c@1.380 +7 -7 + NTP_4_2_7P374 + + util/ntp-keygen-opts.h@1.380 +3 -3 + NTP_4_2_7P374 + + util/ntp-keygen.1ntp-keygenman@1.194 +3 -3 + NTP_4_2_7P374 + + util/ntp-keygen.1ntp-keygenmdoc@1.194 +3 -3 + NTP_4_2_7P374 + + util/ntp-keygen.html@1.43 +2 -2 + NTP_4_2_7P374 + + util/ntp-keygen.man.in@1.194 +3 -3 + NTP_4_2_7P374 + + util/ntp-keygen.mdoc.in@1.194 +3 -3 + NTP_4_2_7P374 + +ChangeSet@1.2946.4.4, 2013-07-21 01:37:05-04:00, karlsson@psp-deb1.ntp.org + [Bug 2413] Fix "make check" with automake >= 1.13 + + ChangeLog@1.1296.3.4 +1 -1 + [Bug 2413] Fix "make check" with automake >= 1.13 + +ChangeSet@1.2946.4.3, 2013-07-21 01:36:42-04:00, karlsson@psp-deb1.ntp.org + [Bug 2413] Fix "make check" with automake >= 1.13 + + ChangeLog@1.1296.3.3 +2 -1 + [Bug 2413] Fix "make check" with automamke >= 1.13 + +ChangeSet@1.2946.5.1, 2013-07-20 19:56:47-04:00, murray@pogo.udel.edu + test.sh, ChangeLog: + Fix bug 2368 + + ChangeLog@1.1296.4.1 +1 -0 + Fix bug 2368 + + sntp/libevent/test/test.sh@1.8 +7 -0 + Fix bug 2368 + +ChangeSet@1.2946.4.1, 2013-07-20 11:32:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P373 + TAG: NTP_4_2_7P373 + + ChangeLog@1.1296.3.1 +1 -0 + NTP_4_2_7P373 + + ntpd/invoke-ntp.conf.texi@1.48 +1 -1 + NTP_4_2_7P373 + + ntpd/invoke-ntp.keys.texi@1.48 +1 -1 + NTP_4_2_7P373 + + ntpd/invoke-ntpd.texi@1.364 +2 -2 + NTP_4_2_7P373 + + ntpd/ntp.conf.5man@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntp.conf.5mdoc@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntp.conf.html@1.46 +1 -1 + NTP_4_2_7P373 + + ntpd/ntp.conf.man.in@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntp.conf.mdoc.in@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntp.keys.5man@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntp.keys.5mdoc@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntp.keys.html@1.47 +1 -1 + NTP_4_2_7P373 + + ntpd/ntp.keys.man.in@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntp.keys.mdoc.in@1.82 +3 -3 + NTP_4_2_7P373 + + ntpd/ntpd-opts.c@1.382 +7 -7 + NTP_4_2_7P373 + + ntpd/ntpd-opts.h@1.382 +3 -3 + NTP_4_2_7P373 + + ntpd/ntpd.1ntpdman@1.193 +3 -3 + NTP_4_2_7P373 + + ntpd/ntpd.1ntpdmdoc@1.193 +3 -3 + NTP_4_2_7P373 + + ntpd/ntpd.html@1.41 +2 -2 + NTP_4_2_7P373 + + ntpd/ntpd.man.in@1.193 +3 -3 + NTP_4_2_7P373 + + ntpd/ntpd.mdoc.in@1.193 +3 -3 + NTP_4_2_7P373 + + ntpdc/invoke-ntpdc.texi@1.361 +2 -2 + NTP_4_2_7P373 + + ntpdc/ntpdc-opts.c@1.376 +7 -7 + NTP_4_2_7P373 + + ntpdc/ntpdc-opts.h@1.376 +3 -3 + NTP_4_2_7P373 + + ntpdc/ntpdc.1ntpdcman@1.192 +2 -2 + NTP_4_2_7P373 + + ntpdc/ntpdc.1ntpdcmdoc@1.192 +2 -2 + NTP_4_2_7P373 + + ntpdc/ntpdc.html@1.205 +2 -2 + NTP_4_2_7P373 + + ntpdc/ntpdc.man.in@1.192 +2 -2 + NTP_4_2_7P373 + + ntpdc/ntpdc.mdoc.in@1.192 +2 -2 + NTP_4_2_7P373 + + ntpq/invoke-ntpq.texi@1.365 +2 -2 + NTP_4_2_7P373 + + ntpq/ntpq-opts.c@1.379 +7 -7 + NTP_4_2_7P373 + + ntpq/ntpq-opts.h@1.379 +3 -3 + NTP_4_2_7P373 + + ntpq/ntpq.1ntpqman@1.193 +2 -2 + NTP_4_2_7P373 + + ntpq/ntpq.1ntpqmdoc@1.193 +2 -2 + NTP_4_2_7P373 + + ntpq/ntpq.html@1.38 +2 -2 + NTP_4_2_7P373 + + ntpq/ntpq.man.in@1.193 +2 -2 + NTP_4_2_7P373 + + ntpq/ntpq.mdoc.in@1.193 +2 -2 + NTP_4_2_7P373 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.364 +2 -2 + NTP_4_2_7P373 + + ntpsnmpd/ntpsnmpd-opts.c@1.379 +7 -7 + NTP_4_2_7P373 + + ntpsnmpd/ntpsnmpd-opts.h@1.379 +3 -3 + NTP_4_2_7P373 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.193 +3 -3 + NTP_4_2_7P373 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.193 +3 -3 + NTP_4_2_7P373 + + ntpsnmpd/ntpsnmpd.html@1.36 +1 -1 + NTP_4_2_7P373 + + ntpsnmpd/ntpsnmpd.man.in@1.193 +3 -3 + NTP_4_2_7P373 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.193 +3 -3 + NTP_4_2_7P373 + + packageinfo.sh@1.376 +1 -1 + NTP_4_2_7P373 + + scripts/invoke-ntp-wait.texi@1.181 +1 -1 + NTP_4_2_7P373 + + scripts/ntp-wait.1ntp-waitman@1.192 +3 -3 + NTP_4_2_7P373 + + scripts/ntp-wait.1ntp-waitmdoc@1.192 +3 -3 + NTP_4_2_7P373 + + scripts/ntp-wait.html@1.197 +1 -1 + NTP_4_2_7P373 + + scripts/ntp-wait.man.in@1.192 +3 -3 + NTP_4_2_7P373 + + scripts/ntp-wait.mdoc.in@1.192 +3 -3 + NTP_4_2_7P373 + + sntp/invoke-sntp.texi@1.361 +2 -2 + NTP_4_2_7P373 + + sntp/sntp-opts.c@1.376 +7 -7 + NTP_4_2_7P373 + + sntp/sntp-opts.h@1.376 +3 -3 + NTP_4_2_7P373 + + sntp/sntp.1sntpman@1.196 +3 -3 + NTP_4_2_7P373 + + sntp/sntp.1sntpmdoc@1.196 +3 -3 + NTP_4_2_7P373 + + sntp/sntp.html@1.376 +2 -2 + NTP_4_2_7P373 + + sntp/sntp.man.in@1.196 +3 -3 + NTP_4_2_7P373 + + sntp/sntp.mdoc.in@1.196 +3 -3 + NTP_4_2_7P373 + + util/invoke-ntp-keygen.texi@1.365 +2 -2 + NTP_4_2_7P373 + + util/ntp-keygen-opts.c@1.379 +7 -7 + NTP_4_2_7P373 + + util/ntp-keygen-opts.h@1.379 +3 -3 + NTP_4_2_7P373 + + util/ntp-keygen.1ntp-keygenman@1.193 +3 -3 + NTP_4_2_7P373 + + util/ntp-keygen.1ntp-keygenmdoc@1.193 +3 -3 + NTP_4_2_7P373 + + util/ntp-keygen.html@1.42 +2 -2 + NTP_4_2_7P373 + + util/ntp-keygen.man.in@1.193 +3 -3 + NTP_4_2_7P373 + + util/ntp-keygen.mdoc.in@1.193 +3 -3 + NTP_4_2_7P373 + +ChangeSet@1.2946.1.19, 2013-07-20 10:59:15+00:00, kardel@pogo.udel.edu + ntp_io.c: + add missing static + + ntpd/ntp_io.c@1.379 +1 -1 + add missing static + +ChangeSet@1.2946.1.18, 2013-07-20 10:48:50+00:00, kardel@pogo.udel.edu + ntp_io.c, work_thread.c: + [Bug 2425] keep init_socket_sig() within ntp_io.c to avoid interference with sntp's way of doing i/o + + libntp/work_thread.c@1.16 +0 -4 + [Bug 2425] keep init_socket_sig() within ntp_io.c to avoid interference with sntp's way of doing things + + ntpd/ntp_io.c@1.378 +6 -1 + [Bug 2425] keep init_socket_sig() within ntp_io.c to avoid interference with sntp's way of doing things + +ChangeSet@1.2946.1.17, 2013-07-20 08:25:40+00:00, kardel@pogo.udel.edu + work_thread.c, ntpd.h, ntpd.c, ntp_io.c, ChangeLog, iosignal.h, iosignal.c: + [Bug 2425] fix async io setup for worker thread + + ChangeLog@1.1296.1.16 +2 -0 + [Bug 2425] fix async io setup for worker thread + + include/iosignal.h@1.7 +4 -2 + [Bug 2425] fix async io setup for worker thread + + include/ntpd.h@1.175 +0 -1 + [Bug 2425] fix async io setup for worker thread + + libntp/iosignal.c@1.17 +30 -15 + [Bug 2425] fix async io setup for worker thread + + libntp/work_thread.c@1.15 +4 -0 + [Bug 2425] fix async io setup for worker thread. + + ntpd/ntp_io.c@1.377 +1 -1 + [Bug 2425] fix async io setup for worker thread + + ntpd/ntpd.c@1.144 +1 -0 + [Bug 2425] fix async io setup for worker thread + +ChangeSet@1.2946.1.16, 2013-07-20 00:33:31-04:00, stenn@pogo.udel.edu + Bug 2427] configure fails to detect recvmsg() on Solaris + + ChangeLog@1.1296.1.15 +1 -0 + Bug 2427] configure fails to detect recvmsg() on Solaris + + configure.ac@1.559 +1 -1 + Bug 2427] configure fails to detect recvmsg() on Solaris + + sntp/m4/ntp_libntp.m4@1.19 +3 -0 + Bug 2427] configure fails to detect recvmsg() on Solaris + +ChangeSet@1.2946.1.15, 2013-07-17 11:39:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P372 + TAG: NTP_4_2_7P372 + + ChangeLog@1.1296.1.14 +1 -0 + NTP_4_2_7P372 + + ntpd/invoke-ntp.conf.texi@1.47 +1 -1 + NTP_4_2_7P372 + + ntpd/invoke-ntp.keys.texi@1.47 +1 -1 + NTP_4_2_7P372 + + ntpd/invoke-ntpd.texi@1.363 +2 -2 + NTP_4_2_7P372 + + ntpd/ntp.conf.5man@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntp.conf.5mdoc@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntp.conf.html@1.45 +1 -1 + NTP_4_2_7P372 + + ntpd/ntp.conf.man.in@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntp.conf.mdoc.in@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntp.keys.5man@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntp.keys.5mdoc@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntp.keys.html@1.46 +1 -1 + NTP_4_2_7P372 + + ntpd/ntp.keys.man.in@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntp.keys.mdoc.in@1.81 +3 -3 + NTP_4_2_7P372 + + ntpd/ntpd-opts.c@1.381 +7 -7 + NTP_4_2_7P372 + + ntpd/ntpd-opts.h@1.381 +3 -3 + NTP_4_2_7P372 + + ntpd/ntpd.1ntpdman@1.192 +3 -3 + NTP_4_2_7P372 + + ntpd/ntpd.1ntpdmdoc@1.192 +3 -3 + NTP_4_2_7P372 + + ntpd/ntpd.html@1.40 +4 -2 + NTP_4_2_7P372 + + ntpd/ntpd.man.in@1.192 +3 -3 + NTP_4_2_7P372 + + ntpd/ntpd.mdoc.in@1.192 +3 -3 + NTP_4_2_7P372 + + ntpdc/invoke-ntpdc.texi@1.360 +2 -2 + NTP_4_2_7P372 + + ntpdc/ntpdc-opts.c@1.375 +7 -7 + NTP_4_2_7P372 + + ntpdc/ntpdc-opts.h@1.375 +3 -3 + NTP_4_2_7P372 + + ntpdc/ntpdc.1ntpdcman@1.191 +2 -2 + NTP_4_2_7P372 + + ntpdc/ntpdc.1ntpdcmdoc@1.191 +2 -2 + NTP_4_2_7P372 + + ntpdc/ntpdc.html@1.204 +2 -2 + NTP_4_2_7P372 + + ntpdc/ntpdc.man.in@1.191 +2 -2 + NTP_4_2_7P372 + + ntpdc/ntpdc.mdoc.in@1.191 +2 -2 + NTP_4_2_7P372 + + ntpq/invoke-ntpq.texi@1.364 +2 -2 + NTP_4_2_7P372 + + ntpq/ntpq-opts.c@1.378 +7 -7 + NTP_4_2_7P372 + + ntpq/ntpq-opts.h@1.378 +3 -3 + NTP_4_2_7P372 + + ntpq/ntpq.1ntpqman@1.192 +2 -2 + NTP_4_2_7P372 + + ntpq/ntpq.1ntpqmdoc@1.192 +2 -2 + NTP_4_2_7P372 + + ntpq/ntpq.html@1.37 +4 -2 + NTP_4_2_7P372 + + ntpq/ntpq.man.in@1.192 +2 -2 + NTP_4_2_7P372 + + ntpq/ntpq.mdoc.in@1.192 +2 -2 + NTP_4_2_7P372 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.363 +2 -2 + NTP_4_2_7P372 + + ntpsnmpd/ntpsnmpd-opts.c@1.378 +7 -7 + NTP_4_2_7P372 + + ntpsnmpd/ntpsnmpd-opts.h@1.378 +3 -3 + NTP_4_2_7P372 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.192 +3 -3 + NTP_4_2_7P372 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.192 +3 -3 + NTP_4_2_7P372 + + ntpsnmpd/ntpsnmpd.html@1.35 +1 -1 + NTP_4_2_7P372 + + ntpsnmpd/ntpsnmpd.man.in@1.192 +3 -3 + NTP_4_2_7P372 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.192 +3 -3 + NTP_4_2_7P372 + + packageinfo.sh@1.375 +1 -1 + NTP_4_2_7P372 + + scripts/invoke-ntp-wait.texi@1.180 +1 -1 + NTP_4_2_7P372 + + scripts/ntp-wait.1ntp-waitman@1.191 +3 -3 + NTP_4_2_7P372 + + scripts/ntp-wait.1ntp-waitmdoc@1.191 +3 -3 + NTP_4_2_7P372 + + scripts/ntp-wait.html@1.196 +1 -1 + NTP_4_2_7P372 + + scripts/ntp-wait.man.in@1.191 +3 -3 + NTP_4_2_7P372 + + scripts/ntp-wait.mdoc.in@1.191 +3 -3 + NTP_4_2_7P372 + + sntp/invoke-sntp.texi@1.360 +2 -2 + NTP_4_2_7P372 + + sntp/sntp-opts.c@1.375 +7 -7 + NTP_4_2_7P372 + + sntp/sntp-opts.h@1.375 +3 -3 + NTP_4_2_7P372 + + sntp/sntp.1sntpman@1.195 +3 -3 + NTP_4_2_7P372 + + sntp/sntp.1sntpmdoc@1.195 +3 -3 + NTP_4_2_7P372 + + sntp/sntp.html@1.375 +2 -2 + NTP_4_2_7P372 + + sntp/sntp.man.in@1.195 +3 -3 + NTP_4_2_7P372 + + sntp/sntp.mdoc.in@1.195 +3 -3 + NTP_4_2_7P372 + + util/invoke-ntp-keygen.texi@1.364 +2 -2 + NTP_4_2_7P372 + + util/ntp-keygen-opts.c@1.378 +7 -7 + NTP_4_2_7P372 + + util/ntp-keygen-opts.h@1.378 +3 -3 + NTP_4_2_7P372 + + util/ntp-keygen.1ntp-keygenman@1.192 +3 -3 + NTP_4_2_7P372 + + util/ntp-keygen.1ntp-keygenmdoc@1.192 +3 -3 + NTP_4_2_7P372 + + util/ntp-keygen.html@1.41 +4 -2 + NTP_4_2_7P372 + + util/ntp-keygen.man.in@1.192 +3 -3 + NTP_4_2_7P372 + + util/ntp-keygen.mdoc.in@1.192 +3 -3 + NTP_4_2_7P372 + +ChangeSet@1.2946.1.14, 2013-07-17 05:23:29-04:00, stenn@deacon.udel.edu + [Bug 2428] do_unconf() should reset 'items' before the 2nd loop + + ChangeLog@1.1296.1.13 +1 -0 + [Bug 2428] do_unconf() should reset 'items' before the 2nd loop + + ntpd/ntp_request.c@1.111 +1 -0 + [Bug 2428] do_unconf() should reset 'items' before the 2nd loop + +ChangeSet@1.2946.1.13, 2013-07-17 05:18:42-04:00, stenn@deacon.udel.edu + [Bug 2423] Log command-line args at LOG_INFO + + ChangeLog@1.1296.1.12 +1 -0 + [Bug 2423] Log command-line args at LOG_INFO + + ntpd/ntpd.c@1.143 +1 -1 + [Bug 2423] Log command-line args at LOG_INFO + +ChangeSet@1.2946.1.12, 2013-07-17 05:11:31-04:00, stenn@pogo.udel.edu + [Bug 2375] AIX 7 doesn't like a libevent validation check + + ChangeLog@1.1296.1.11 +1 -0 + [Bug 2375] AIX 7 doesn't like a libevent validation check + + sntp/libevent/evutil_time.c@1.3 +0 -10 + [Bug 2375] AIX 7 doesn't like a libevent validation check + +ChangeSet@1.2946.1.11, 2013-07-17 03:34:42-04:00, stenn@deacon.udel.edu + [Bug 1466] Oncore should set FLAG_PPS + + ChangeLog@1.1296.1.10 +1 -0 + [Bug 1466] Oncore should set FLAG_PPS + + ntpd/refclock_oncore.c@1.96 +12 -3 + [Bug 1466] Oncore should set FLAG_PPS + +ChangeSet@1.2946.1.10, 2013-07-07 06:34:52+00:00, stenn@deacon.udel.edu + NTP_4_2_7P371 + TAG: NTP_4_2_7P371 + + ChangeLog@1.1296.1.9 +1 -0 + NTP_4_2_7P371 + + ntpd/invoke-ntp.conf.texi@1.46 +1 -1 + NTP_4_2_7P371 + + ntpd/invoke-ntp.keys.texi@1.46 +1 -1 + NTP_4_2_7P371 + + ntpd/invoke-ntpd.texi@1.362 +4 -2 + NTP_4_2_7P371 + + ntpd/ntp.conf.5man@1.80 +36 -36 + NTP_4_2_7P371 + + ntpd/ntp.conf.5mdoc@1.80 +4 -4 + NTP_4_2_7P371 + + ntpd/ntp.conf.html@1.44 +1 -1 + NTP_4_2_7P371 + + ntpd/ntp.conf.man.in@1.80 +36 -36 + NTP_4_2_7P371 + + ntpd/ntp.conf.mdoc.in@1.80 +4 -4 + NTP_4_2_7P371 + + ntpd/ntp.keys.5man@1.80 +10 -10 + NTP_4_2_7P371 + + ntpd/ntp.keys.5mdoc@1.80 +4 -4 + NTP_4_2_7P371 + + ntpd/ntp.keys.html@1.45 +1 -1 + NTP_4_2_7P371 + + ntpd/ntp.keys.man.in@1.80 +10 -10 + NTP_4_2_7P371 + + ntpd/ntp.keys.mdoc.in@1.80 +4 -4 + NTP_4_2_7P371 + + ntpd/ntpd-opts.c@1.380 +104 -99 + NTP_4_2_7P371 + + ntpd/ntpd-opts.h@1.380 +13 -15 + NTP_4_2_7P371 + + ntpd/ntpd.1ntpdman@1.191 +4 -4 + NTP_4_2_7P371 + + ntpd/ntpd.1ntpdmdoc@1.191 +4 -4 + NTP_4_2_7P371 + + ntpd/ntpd.html@1.39 +2 -2 + NTP_4_2_7P371 + + ntpd/ntpd.man.in@1.191 +4 -4 + NTP_4_2_7P371 + + ntpd/ntpd.mdoc.in@1.191 +4 -4 + NTP_4_2_7P371 + + ntpdc/invoke-ntpdc.texi@1.359 +4 -3 + NTP_4_2_7P371 + + ntpdc/ntpdc-opts.c@1.374 +104 -99 + NTP_4_2_7P371 + + ntpdc/ntpdc-opts.h@1.374 +14 -16 + NTP_4_2_7P371 + + ntpdc/ntpdc.1ntpdcman@1.190 +14 -13 + NTP_4_2_7P371 + + ntpdc/ntpdc.1ntpdcmdoc@1.190 +9 -8 + NTP_4_2_7P371 + + ntpdc/ntpdc.html@1.203 +4 -2 + NTP_4_2_7P371 + + ntpdc/ntpdc.man.in@1.190 +14 -13 + NTP_4_2_7P371 + + ntpdc/ntpdc.mdoc.in@1.190 +9 -8 + NTP_4_2_7P371 + + ntpq/invoke-ntpq.texi@1.363 +4 -3 + NTP_4_2_7P371 + + ntpq/ntpq-opts.c@1.377 +104 -99 + NTP_4_2_7P371 + + ntpq/ntpq-opts.h@1.377 +14 -16 + NTP_4_2_7P371 + + ntpq/ntpq.1ntpqman@1.191 +10 -9 + NTP_4_2_7P371 + + ntpq/ntpq.1ntpqmdoc@1.191 +9 -8 + NTP_4_2_7P371 + + ntpq/ntpq.html@1.36 +2 -2 + NTP_4_2_7P371 + + ntpq/ntpq.man.in@1.191 +10 -9 + NTP_4_2_7P371 + + ntpq/ntpq.mdoc.in@1.191 +9 -8 + NTP_4_2_7P371 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.362 +4 -3 + NTP_4_2_7P371 + + ntpsnmpd/ntpsnmpd-opts.c@1.377 +104 -99 + NTP_4_2_7P371 + + ntpsnmpd/ntpsnmpd-opts.h@1.377 +14 -16 + NTP_4_2_7P371 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.191 +10 -9 + NTP_4_2_7P371 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.191 +10 -9 + NTP_4_2_7P371 + + ntpsnmpd/ntpsnmpd.html@1.34 +1 -1 + NTP_4_2_7P371 + + ntpsnmpd/ntpsnmpd.man.in@1.191 +10 -9 + NTP_4_2_7P371 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.191 +10 -9 + NTP_4_2_7P371 + + packageinfo.sh@1.374 +1 -1 + NTP_4_2_7P371 + + scripts/invoke-ntp-wait.texi@1.179 +1 -1 + NTP_4_2_7P371 + + scripts/ntp-wait.1ntp-waitman@1.190 +6 -6 + NTP_4_2_7P371 + + scripts/ntp-wait.1ntp-waitmdoc@1.190 +4 -4 + NTP_4_2_7P371 + + scripts/ntp-wait.html@1.195 +1 -1 + NTP_4_2_7P371 + + scripts/ntp-wait.man.in@1.190 +6 -6 + NTP_4_2_7P371 + + scripts/ntp-wait.mdoc.in@1.190 +4 -4 + NTP_4_2_7P371 + + sntp/invoke-sntp.texi@1.359 +4 -3 + NTP_4_2_7P371 + + sntp/sntp-opts.c@1.374 +104 -99 + NTP_4_2_7P371 + + sntp/sntp-opts.h@1.374 +14 -16 + NTP_4_2_7P371 + + sntp/sntp.1sntpman@1.194 +10 -9 + NTP_4_2_7P371 + + sntp/sntp.1sntpmdoc@1.194 +10 -9 + NTP_4_2_7P371 + + sntp/sntp.html@1.374 +4 -2 + NTP_4_2_7P371 + + sntp/sntp.man.in@1.194 +10 -9 + NTP_4_2_7P371 + + sntp/sntp.mdoc.in@1.194 +10 -9 + NTP_4_2_7P371 + + util/invoke-ntp-keygen.texi@1.363 +4 -3 + NTP_4_2_7P371 + + util/ntp-keygen-opts.c@1.377 +104 -99 + NTP_4_2_7P371 + + util/ntp-keygen-opts.h@1.377 +9 -11 + NTP_4_2_7P371 + + util/ntp-keygen.1ntp-keygenman@1.191 +36 -35 + NTP_4_2_7P371 + + util/ntp-keygen.1ntp-keygenmdoc@1.191 +10 -9 + NTP_4_2_7P371 + + util/ntp-keygen.html@1.40 +2 -2 + NTP_4_2_7P371 + + util/ntp-keygen.man.in@1.191 +36 -35 + NTP_4_2_7P371 + + util/ntp-keygen.mdoc.in@1.191 +10 -9 + NTP_4_2_7P371 + +ChangeSet@1.2946.1.8, 2013-07-07 01:42:37-04:00, stenn@deacon.udel.edu + CID 1042586: Check the return value of clock_gettime() in worker_sleep() + + ChangeLog@1.1296.1.7 +1 -0 + CID 1042586: Check the return value of clock_gettime() in worker_sleep() + + libntp/work_thread.c@1.14 +9 -3 + CID 1042586: Check the return value of clock_gettime() in worker_sleep() + +ChangeSet@1.2946.3.1, 2013-07-07 05:39:47+00:00, stenn@psp-fb1.ntp.org + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + ChangeLog@1.1296.2.1 +1 -0 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/Makefile.am@1.21 +5 -5 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/ag-char-map.h@1.24 +2 -2 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/alias.c@1.6 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/ao-strs.c@1.10 +58 -56 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/ao-strs.h@1.9 +64 -60 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/autoopts.c@1.17 +4 -19 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/autoopts.h@1.15 +59 -0 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/autoopts/options.h@1.23 +22 -6 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/autoopts/project.h@1.6 +2 -0 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/autoopts/usage-txt.h@1.23 +78 -78 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/enum.c@1.9 +211 -95 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/find.c@1.8 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/genshell.c@1.24 +91 -89 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/genshell.h@1.24 +9 -11 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/init.c@1.4 +1 -0 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/load.c@1.17 +28 -18 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/m4/libopts.m4@1.27 +11 -9 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/makeshell.c@1.16 +19 -11 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/option-value-type.c@1.11 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/option-value-type.h@1.25 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/option-xat-attribute.c@1.11 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/option-xat-attribute.h@1.25 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/pgusage.c@1.14 +81 -34 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/proto.h@1.24 +9 -10 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/putshell.c@1.13 +4 -9 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/restore.c@1.12 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/save.c@1.15 +39 -41 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/stack.c@1.14 +2 -2 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/text_mmap.c@1.14 +1 -1 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/usage.c@1.17 +35 -63 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + + sntp/libopts/version.c@1.15 +3 -3 + Upgrade to libopts-39.0.14 from 5.17.5pre10 + +ChangeSet@1.2946.1.7, 2013-07-06 11:30:50+00:00, stenn@deacon.udel.edu + NTP_4_2_7P370 + TAG: NTP_4_2_7P370 + + ChangeLog@1.1296.1.6 +1 -0 + NTP_4_2_7P370 + + ntpd/invoke-ntp.conf.texi@1.45 +1 -1 + NTP_4_2_7P370 + + ntpd/invoke-ntp.keys.texi@1.45 +1 -1 + NTP_4_2_7P370 + + ntpd/invoke-ntpd.texi@1.361 +2 -2 + NTP_4_2_7P370 + + ntpd/ntp.conf.5man@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntp.conf.5mdoc@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntp.conf.html@1.43 +1 -1 + NTP_4_2_7P370 + + ntpd/ntp.conf.man.in@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntp.conf.mdoc.in@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntp.keys.5man@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntp.keys.5mdoc@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntp.keys.html@1.44 +1 -1 + NTP_4_2_7P370 + + ntpd/ntp.keys.man.in@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntp.keys.mdoc.in@1.79 +3 -3 + NTP_4_2_7P370 + + ntpd/ntpd-opts.c@1.379 +7 -7 + NTP_4_2_7P370 + + ntpd/ntpd-opts.h@1.379 +3 -3 + NTP_4_2_7P370 + + ntpd/ntpd.1ntpdman@1.190 +3 -3 + NTP_4_2_7P370 + + ntpd/ntpd.1ntpdmdoc@1.190 +3 -3 + NTP_4_2_7P370 + + ntpd/ntpd.html@1.38 +2 -2 + NTP_4_2_7P370 + + ntpd/ntpd.man.in@1.190 +3 -3 + NTP_4_2_7P370 + + ntpd/ntpd.mdoc.in@1.190 +3 -3 + NTP_4_2_7P370 + + ntpdc/invoke-ntpdc.texi@1.358 +2 -2 + NTP_4_2_7P370 + + ntpdc/ntpdc-opts.c@1.373 +7 -7 + NTP_4_2_7P370 + + ntpdc/ntpdc-opts.h@1.373 +3 -3 + NTP_4_2_7P370 + + ntpdc/ntpdc.1ntpdcman@1.189 +2 -2 + NTP_4_2_7P370 + + ntpdc/ntpdc.1ntpdcmdoc@1.189 +2 -2 + NTP_4_2_7P370 + + ntpdc/ntpdc.html@1.202 +2 -2 + NTP_4_2_7P370 + + ntpdc/ntpdc.man.in@1.189 +2 -2 + NTP_4_2_7P370 + + ntpdc/ntpdc.mdoc.in@1.189 +2 -2 + NTP_4_2_7P370 + + ntpq/invoke-ntpq.texi@1.362 +2 -2 + NTP_4_2_7P370 + + ntpq/ntpq-opts.c@1.376 +7 -7 + NTP_4_2_7P370 + + ntpq/ntpq-opts.h@1.376 +3 -3 + NTP_4_2_7P370 + + ntpq/ntpq.1ntpqman@1.190 +2 -2 + NTP_4_2_7P370 + + ntpq/ntpq.1ntpqmdoc@1.190 +2 -2 + NTP_4_2_7P370 + + ntpq/ntpq.html@1.35 +2 -2 + NTP_4_2_7P370 + + ntpq/ntpq.man.in@1.190 +2 -2 + NTP_4_2_7P370 + + ntpq/ntpq.mdoc.in@1.190 +2 -2 + NTP_4_2_7P370 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.361 +2 -2 + NTP_4_2_7P370 + + ntpsnmpd/ntpsnmpd-opts.c@1.376 +7 -7 + NTP_4_2_7P370 + + ntpsnmpd/ntpsnmpd-opts.h@1.376 +3 -3 + NTP_4_2_7P370 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.190 +3 -3 + NTP_4_2_7P370 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.190 +3 -3 + NTP_4_2_7P370 + + ntpsnmpd/ntpsnmpd.html@1.33 +1 -1 + NTP_4_2_7P370 + + ntpsnmpd/ntpsnmpd.man.in@1.190 +3 -3 + NTP_4_2_7P370 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.190 +3 -3 + NTP_4_2_7P370 + + packageinfo.sh@1.373 +1 -1 + NTP_4_2_7P370 + + scripts/invoke-ntp-wait.texi@1.178 +1 -1 + NTP_4_2_7P370 + + scripts/ntp-wait.1ntp-waitman@1.189 +3 -3 + NTP_4_2_7P370 + + scripts/ntp-wait.1ntp-waitmdoc@1.189 +3 -3 + NTP_4_2_7P370 + + scripts/ntp-wait.html@1.194 +1 -1 + NTP_4_2_7P370 + + scripts/ntp-wait.man.in@1.189 +3 -3 + NTP_4_2_7P370 + + scripts/ntp-wait.mdoc.in@1.189 +3 -3 + NTP_4_2_7P370 + + sntp/invoke-sntp.texi@1.358 +2 -2 + NTP_4_2_7P370 + + sntp/sntp-opts.c@1.373 +7 -7 + NTP_4_2_7P370 + + sntp/sntp-opts.h@1.373 +3 -3 + NTP_4_2_7P370 + + sntp/sntp.1sntpman@1.193 +3 -3 + NTP_4_2_7P370 + + sntp/sntp.1sntpmdoc@1.193 +3 -3 + NTP_4_2_7P370 + + sntp/sntp.html@1.373 +2 -2 + NTP_4_2_7P370 + + sntp/sntp.man.in@1.193 +3 -3 + NTP_4_2_7P370 + + sntp/sntp.mdoc.in@1.193 +3 -3 + NTP_4_2_7P370 + + util/invoke-ntp-keygen.texi@1.362 +2 -2 + NTP_4_2_7P370 + + util/ntp-keygen-opts.c@1.376 +7 -7 + NTP_4_2_7P370 + + util/ntp-keygen-opts.h@1.376 +3 -3 + NTP_4_2_7P370 + + util/ntp-keygen.1ntp-keygenman@1.190 +3 -3 + NTP_4_2_7P370 + + util/ntp-keygen.1ntp-keygenmdoc@1.190 +3 -3 + NTP_4_2_7P370 + + util/ntp-keygen.html@1.39 +2 -2 + NTP_4_2_7P370 + + util/ntp-keygen.man.in@1.190 +3 -3 + NTP_4_2_7P370 + + util/ntp-keygen.mdoc.in@1.190 +3 -3 + NTP_4_2_7P370 + +ChangeSet@1.2946.1.6, 2013-07-05 22:39:55-07:00, harlan@hms-mbp11.local + Remove tailing \n's from msyslog output strings + + ChangeLog@1.1296.1.5 +1 -0 + Remove tailing \n's from msyslog output strings + +ChangeSet@1.2946.2.1, 2013-07-05 22:36:33-07:00, harlan@hms-mbp11.local + Remove tailing \n's from msyslog output strings + + libntp/audio.c@1.34 +3 -3 + Remove tailing \n's from msyslog output strings + + libntp/ssl_init.c@1.16 +2 -2 + Remove tailing \n's from msyslog output strings + + libntp/work_fork.c@1.11 +5 -5 + Remove tailing \n's from msyslog output strings + + libntp/work_thread.c@1.13 +2 -2 + Remove tailing \n's from msyslog output strings + + libparse/clk_rawdcf.c@1.16 +2 -2 + Remove tailing \n's from msyslog output strings + + libparse/parse.c@1.16 +1 -1 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_config.c@1.312 +9 -9 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_control.c@1.185 +1 -1 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_crypto.c@1.161 +3 -3 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_parser.c@1.84 +167 -470 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_parser.h@1.50 +20 -25 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_parser.y@1.78 +2 -2 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_proto.c@1.345 +3 -3 + Remove tailing \n's from msyslog output strings + + ntpd/ntp_timer.c@1.72 +2 -2 + Remove tailing \n's from msyslog output strings + + ntpd/ntpd.c@1.142 +1 -1 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_arc.c@1.31 +4 -4 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_bancomm.c@1.16 +1 -1 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_datum.c@1.22 +1 -1 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_hopfpci.c@1.14 +1 -1 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_msfees.c@1.18 +1 -1 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_palisade.c@1.41 +4 -4 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_ripencc.c@1.17 +5 -5 + Remove tailing \n's from msyslog output strings + + ntpd/refclock_tsyncpci.c@1.8 +5 -5 + Remove tailing \n's from msyslog output strings + + ntpdate/ntpdate.c@1.92 +4 -4 + Remove tailing \n's from msyslog output strings + + ports/winnt/libntp/SetSystemTime.c@1.11 +1 -1 + Remove tailing \n's from msyslog output strings + + ports/winnt/libntp/win32_io.c@1.3 +1 -1 + Remove tailing \n's from msyslog output strings + + ports/winnt/ntpd/nt_clockstuff.c@1.60 +5 -5 + Remove tailing \n's from msyslog output strings + + sntp/main.c@1.89 +2 -2 + Remove tailing \n's from msyslog output strings + + sntp/networking.c@1.62 +3 -3 + Remove tailing \n's from msyslog output strings + +ChangeSet@1.2946.1.4, 2013-07-05 11:39:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P369 + TAG: NTP_4_2_7P369 + + ChangeLog@1.1296.1.4 +1 -0 + NTP_4_2_7P369 + + ntpd/invoke-ntp.conf.texi@1.44 +1 -1 + NTP_4_2_7P369 + + ntpd/invoke-ntp.keys.texi@1.44 +1 -1 + NTP_4_2_7P369 + + ntpd/invoke-ntpd.texi@1.360 +2 -2 + NTP_4_2_7P369 + + ntpd/ntp.conf.5man@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntp.conf.5mdoc@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntp.conf.html@1.42 +1 -1 + NTP_4_2_7P369 + + ntpd/ntp.conf.man.in@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntp.conf.mdoc.in@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntp.keys.5man@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntp.keys.5mdoc@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntp.keys.html@1.43 +1 -1 + NTP_4_2_7P369 + + ntpd/ntp.keys.man.in@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntp.keys.mdoc.in@1.78 +3 -3 + NTP_4_2_7P369 + + ntpd/ntpd-opts.c@1.378 +7 -7 + NTP_4_2_7P369 + + ntpd/ntpd-opts.h@1.378 +3 -3 + NTP_4_2_7P369 + + ntpd/ntpd.1ntpdman@1.189 +3 -3 + NTP_4_2_7P369 + + ntpd/ntpd.1ntpdmdoc@1.189 +3 -3 + NTP_4_2_7P369 + + ntpd/ntpd.html@1.37 +2 -2 + NTP_4_2_7P369 + + ntpd/ntpd.man.in@1.189 +3 -3 + NTP_4_2_7P369 + + ntpd/ntpd.mdoc.in@1.189 +3 -3 + NTP_4_2_7P369 + + ntpdc/invoke-ntpdc.texi@1.357 +2 -2 + NTP_4_2_7P369 + + ntpdc/ntpdc-opts.c@1.372 +7 -7 + NTP_4_2_7P369 + + ntpdc/ntpdc-opts.h@1.372 +3 -3 + NTP_4_2_7P369 + + ntpdc/ntpdc.1ntpdcman@1.188 +2 -2 + NTP_4_2_7P369 + + ntpdc/ntpdc.1ntpdcmdoc@1.188 +2 -2 + NTP_4_2_7P369 + + ntpdc/ntpdc.html@1.201 +2 -2 + NTP_4_2_7P369 + + ntpdc/ntpdc.man.in@1.188 +2 -2 + NTP_4_2_7P369 + + ntpdc/ntpdc.mdoc.in@1.188 +2 -2 + NTP_4_2_7P369 + + ntpq/invoke-ntpq.texi@1.361 +2 -2 + NTP_4_2_7P369 + + ntpq/ntpq-opts.c@1.375 +7 -7 + NTP_4_2_7P369 + + ntpq/ntpq-opts.h@1.375 +3 -3 + NTP_4_2_7P369 + + ntpq/ntpq.1ntpqman@1.189 +2 -2 + NTP_4_2_7P369 + + ntpq/ntpq.1ntpqmdoc@1.189 +2 -2 + NTP_4_2_7P369 + + ntpq/ntpq.html@1.34 +2 -2 + NTP_4_2_7P369 + + ntpq/ntpq.man.in@1.189 +2 -2 + NTP_4_2_7P369 + + ntpq/ntpq.mdoc.in@1.189 +2 -2 + NTP_4_2_7P369 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.360 +2 -2 + NTP_4_2_7P369 + + ntpsnmpd/ntpsnmpd-opts.c@1.375 +7 -7 + NTP_4_2_7P369 + + ntpsnmpd/ntpsnmpd-opts.h@1.375 +3 -3 + NTP_4_2_7P369 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.189 +3 -3 + NTP_4_2_7P369 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.189 +3 -3 + NTP_4_2_7P369 + + ntpsnmpd/ntpsnmpd.html@1.32 +1 -1 + NTP_4_2_7P369 + + ntpsnmpd/ntpsnmpd.man.in@1.189 +3 -3 + NTP_4_2_7P369 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.189 +3 -3 + NTP_4_2_7P369 + + packageinfo.sh@1.372 +1 -1 + NTP_4_2_7P369 + + scripts/invoke-ntp-wait.texi@1.177 +1 -1 + NTP_4_2_7P369 + + scripts/ntp-wait.1ntp-waitman@1.188 +3 -3 + NTP_4_2_7P369 + + scripts/ntp-wait.1ntp-waitmdoc@1.188 +3 -3 + NTP_4_2_7P369 + + scripts/ntp-wait.html@1.193 +1 -1 + NTP_4_2_7P369 + + scripts/ntp-wait.man.in@1.188 +3 -3 + NTP_4_2_7P369 + + scripts/ntp-wait.mdoc.in@1.188 +3 -3 + NTP_4_2_7P369 + + sntp/invoke-sntp.texi@1.357 +2 -2 + NTP_4_2_7P369 + + sntp/sntp-opts.c@1.372 +7 -7 + NTP_4_2_7P369 + + sntp/sntp-opts.h@1.372 +3 -3 + NTP_4_2_7P369 + + sntp/sntp.1sntpman@1.192 +3 -3 + NTP_4_2_7P369 + + sntp/sntp.1sntpmdoc@1.192 +3 -3 + NTP_4_2_7P369 + + sntp/sntp.html@1.372 +2 -2 + NTP_4_2_7P369 + + sntp/sntp.man.in@1.192 +3 -3 + NTP_4_2_7P369 + + sntp/sntp.mdoc.in@1.192 +3 -3 + NTP_4_2_7P369 + + util/invoke-ntp-keygen.texi@1.361 +2 -2 + NTP_4_2_7P369 + + util/ntp-keygen-opts.c@1.375 +7 -7 + NTP_4_2_7P369 + + util/ntp-keygen-opts.h@1.375 +3 -3 + NTP_4_2_7P369 + + util/ntp-keygen.1ntp-keygenman@1.189 +3 -3 + NTP_4_2_7P369 + + util/ntp-keygen.1ntp-keygenmdoc@1.189 +3 -3 + NTP_4_2_7P369 + + util/ntp-keygen.html@1.38 +2 -2 + NTP_4_2_7P369 + + util/ntp-keygen.man.in@1.189 +3 -3 + NTP_4_2_7P369 + + util/ntp-keygen.mdoc.in@1.189 +3 -3 + NTP_4_2_7P369 + +ChangeSet@1.2946.1.3, 2013-07-04 23:01:44-04:00, stenn@deacon.udel.edu + [Bug 2415] RES_LIMITED flags check should use &, not && + + ChangeLog@1.1296.1.3 +1 -0 + [Bug 2415] RES_LIMITED flags check should use &, not && + + ntpd/ntp_restrict.c@1.35 +1 -1 + [Bug 2415] RES_LIMITED flags check should use &, not && + +ChangeSet@1.2946.1.2, 2013-07-04 21:45:09-04:00, stenn@deacon.udel.edu + Have NTP_LIBNTP check for time.h and clock_getres() + + ChangeLog@1.1296.1.2 +1 -0 + Have NTP_LIBNTP check for time.h and clock_getres() + + sntp/m4/ntp_libntp.m4@1.18 +2 -2 + Have NTP_LIBNTP check for time.h and clock_getres() + +ChangeSet@1.2939.1.1, 2013-07-04 20:43:53-04:00, stenn@psp-deb1.ntp.org + Fix ntpsweep to use sntp instead of ntpdate, from Oliver Kindernay + + ChangeLog@1.1289.1.1 +1 -0 + Fix ntpsweep to use sntp instead of ntpdate, from Oliver Kindernay + + scripts/ntpsweep.in@1.4 +13 -13 + Fix ntpsweep to use sntp instead of ntpdate, from Oliver Kindernay + +ChangeSet@1.2947, 2013-06-28 13:18:15-04:00, karlsson@psp-deb1.ntp.org + [Bug 2413] make check fails to run tests with automake >= 1.13 + + BitKeeper/deleted/31/test-driver~38cbd0dac650aed0@1.5 +0 -0 + Delete: sntp/tests/test-driver + + ChangeLog@1.1297 +1 -0 + [Bug 2413] make check fails to run tests with automake >= 1.13 + + sntp/tests/Makefile.am@1.28 +2 -7 + [Bug 2413] make check fails to run tests with automake >= 1.13 + + sntp/tests/tests-runner@1.1 +13 -0 + BitKeeper file /home/karlsson/2413/ntp-dev-2413/sntp/tests/tests-runner + + sntp/tests/tests-runner@1.0 +0 -0 + +ChangeSet@1.2946, 2013-05-01 11:35:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P368 + TAG: NTP_4_2_7P368 + + ChangeLog@1.1296 +1 -0 + NTP_4_2_7P368 + + ntpd/invoke-ntp.conf.texi@1.43 +1 -1 + NTP_4_2_7P368 + + ntpd/invoke-ntp.keys.texi@1.43 +1 -1 + NTP_4_2_7P368 + + ntpd/invoke-ntpd.texi@1.359 +2 -2 + NTP_4_2_7P368 + + ntpd/ntp.conf.5man@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntp.conf.5mdoc@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntp.conf.html@1.41 +1 -1 + NTP_4_2_7P368 + + ntpd/ntp.conf.man.in@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntp.conf.mdoc.in@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntp.keys.5man@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntp.keys.5mdoc@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntp.keys.html@1.42 +1 -1 + NTP_4_2_7P368 + + ntpd/ntp.keys.man.in@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntp.keys.mdoc.in@1.77 +3 -3 + NTP_4_2_7P368 + + ntpd/ntpd-opts.c@1.377 +7 -7 + NTP_4_2_7P368 + + ntpd/ntpd-opts.h@1.377 +3 -3 + NTP_4_2_7P368 + + ntpd/ntpd.1ntpdman@1.188 +3 -3 + NTP_4_2_7P368 + + ntpd/ntpd.1ntpdmdoc@1.188 +3 -3 + NTP_4_2_7P368 + + ntpd/ntpd.html@1.36 +2 -2 + NTP_4_2_7P368 + + ntpd/ntpd.man.in@1.188 +3 -3 + NTP_4_2_7P368 + + ntpd/ntpd.mdoc.in@1.188 +3 -3 + NTP_4_2_7P368 + + ntpdc/invoke-ntpdc.texi@1.356 +2 -2 + NTP_4_2_7P368 + + ntpdc/ntpdc-opts.c@1.371 +7 -7 + NTP_4_2_7P368 + + ntpdc/ntpdc-opts.h@1.371 +3 -3 + NTP_4_2_7P368 + + ntpdc/ntpdc.1ntpdcman@1.187 +2 -2 + NTP_4_2_7P368 + + ntpdc/ntpdc.1ntpdcmdoc@1.187 +2 -2 + NTP_4_2_7P368 + + ntpdc/ntpdc.html@1.200 +2 -2 + NTP_4_2_7P368 + + ntpdc/ntpdc.man.in@1.187 +2 -2 + NTP_4_2_7P368 + + ntpdc/ntpdc.mdoc.in@1.187 +2 -2 + NTP_4_2_7P368 + + ntpq/invoke-ntpq.texi@1.360 +2 -2 + NTP_4_2_7P368 + + ntpq/ntpq-opts.c@1.374 +7 -7 + NTP_4_2_7P368 + + ntpq/ntpq-opts.h@1.374 +3 -3 + NTP_4_2_7P368 + + ntpq/ntpq.1ntpqman@1.188 +2 -2 + NTP_4_2_7P368 + + ntpq/ntpq.1ntpqmdoc@1.188 +2 -2 + NTP_4_2_7P368 + + ntpq/ntpq.html@1.33 +2 -2 + NTP_4_2_7P368 + + ntpq/ntpq.man.in@1.188 +2 -2 + NTP_4_2_7P368 + + ntpq/ntpq.mdoc.in@1.188 +2 -2 + NTP_4_2_7P368 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.359 +2 -2 + NTP_4_2_7P368 + + ntpsnmpd/ntpsnmpd-opts.c@1.374 +7 -7 + NTP_4_2_7P368 + + ntpsnmpd/ntpsnmpd-opts.h@1.374 +3 -3 + NTP_4_2_7P368 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.188 +3 -3 + NTP_4_2_7P368 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.188 +3 -3 + NTP_4_2_7P368 + + ntpsnmpd/ntpsnmpd.html@1.31 +1 -1 + NTP_4_2_7P368 + + ntpsnmpd/ntpsnmpd.man.in@1.188 +3 -3 + NTP_4_2_7P368 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.188 +3 -3 + NTP_4_2_7P368 + + packageinfo.sh@1.371 +1 -1 + NTP_4_2_7P368 + + scripts/invoke-ntp-wait.texi@1.176 +1 -1 + NTP_4_2_7P368 + + scripts/ntp-wait.1ntp-waitman@1.187 +3 -3 + NTP_4_2_7P368 + + scripts/ntp-wait.1ntp-waitmdoc@1.187 +3 -3 + NTP_4_2_7P368 + + scripts/ntp-wait.html@1.192 +1 -1 + NTP_4_2_7P368 + + scripts/ntp-wait.man.in@1.187 +3 -3 + NTP_4_2_7P368 + + scripts/ntp-wait.mdoc.in@1.187 +3 -3 + NTP_4_2_7P368 + + sntp/invoke-sntp.texi@1.356 +2 -2 + NTP_4_2_7P368 + + sntp/sntp-opts.c@1.371 +7 -7 + NTP_4_2_7P368 + + sntp/sntp-opts.h@1.371 +3 -3 + NTP_4_2_7P368 + + sntp/sntp.1sntpman@1.191 +3 -3 + NTP_4_2_7P368 + + sntp/sntp.1sntpmdoc@1.191 +3 -3 + NTP_4_2_7P368 + + sntp/sntp.html@1.371 +2 -2 + NTP_4_2_7P368 + + sntp/sntp.man.in@1.191 +3 -3 + NTP_4_2_7P368 + + sntp/sntp.mdoc.in@1.191 +3 -3 + NTP_4_2_7P368 + + util/invoke-ntp-keygen.texi@1.360 +2 -2 + NTP_4_2_7P368 + + util/ntp-keygen-opts.c@1.374 +7 -7 + NTP_4_2_7P368 + + util/ntp-keygen-opts.h@1.374 +3 -3 + NTP_4_2_7P368 + + util/ntp-keygen.1ntp-keygenman@1.188 +3 -3 + NTP_4_2_7P368 + + util/ntp-keygen.1ntp-keygenmdoc@1.188 +3 -3 + NTP_4_2_7P368 + + util/ntp-keygen.html@1.37 +2 -2 + NTP_4_2_7P368 + + util/ntp-keygen.man.in@1.188 +3 -3 + NTP_4_2_7P368 + + util/ntp-keygen.mdoc.in@1.188 +3 -3 + NTP_4_2_7P368 + +ChangeSet@1.2945, 2013-04-30 22:36:28-04:00, stenn@pogo.udel.edu + [Bug 2145] ntpq dumps core when displaying sys_var_list and more + + ChangeLog@1.1295 +1 -0 + [Bug 2145] ntpq dumps core when displaying sys_var_list and more + + ntpd/ntp_control.c@1.184 +43 -18 + [Bug 2145] ntpq dumps core when displaying sys_var_list and more + +ChangeSet@1.2944, 2013-04-25 11:43:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P367 + TAG: NTP_4_2_7P367 + + ChangeLog@1.1294 +1 -0 + NTP_4_2_7P367 + + ntpd/invoke-ntp.conf.texi@1.42 +1 -1 + NTP_4_2_7P367 + + ntpd/invoke-ntp.keys.texi@1.42 +1 -1 + NTP_4_2_7P367 + + ntpd/invoke-ntpd.texi@1.358 +2 -2 + NTP_4_2_7P367 + + ntpd/ntp.conf.5man@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntp.conf.5mdoc@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntp.conf.html@1.40 +1 -1 + NTP_4_2_7P367 + + ntpd/ntp.conf.man.in@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntp.conf.mdoc.in@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntp.keys.5man@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntp.keys.5mdoc@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntp.keys.html@1.41 +1 -1 + NTP_4_2_7P367 + + ntpd/ntp.keys.man.in@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntp.keys.mdoc.in@1.76 +3 -3 + NTP_4_2_7P367 + + ntpd/ntpd-opts.c@1.376 +7 -7 + NTP_4_2_7P367 + + ntpd/ntpd-opts.h@1.376 +3 -3 + NTP_4_2_7P367 + + ntpd/ntpd.1ntpdman@1.187 +3 -3 + NTP_4_2_7P367 + + ntpd/ntpd.1ntpdmdoc@1.187 +3 -3 + NTP_4_2_7P367 + + ntpd/ntpd.html@1.35 +2 -2 + NTP_4_2_7P367 + + ntpd/ntpd.man.in@1.187 +3 -3 + NTP_4_2_7P367 + + ntpd/ntpd.mdoc.in@1.187 +3 -3 + NTP_4_2_7P367 + + ntpdc/invoke-ntpdc.texi@1.355 +2 -2 + NTP_4_2_7P367 + + ntpdc/ntpdc-opts.c@1.370 +7 -7 + NTP_4_2_7P367 + + ntpdc/ntpdc-opts.h@1.370 +3 -3 + NTP_4_2_7P367 + + ntpdc/ntpdc.1ntpdcman@1.186 +2 -2 + NTP_4_2_7P367 + + ntpdc/ntpdc.1ntpdcmdoc@1.186 +2 -2 + NTP_4_2_7P367 + + ntpdc/ntpdc.html@1.199 +2 -2 + NTP_4_2_7P367 + + ntpdc/ntpdc.man.in@1.186 +2 -2 + NTP_4_2_7P367 + + ntpdc/ntpdc.mdoc.in@1.186 +2 -2 + NTP_4_2_7P367 + + ntpq/invoke-ntpq.texi@1.359 +2 -2 + NTP_4_2_7P367 + + ntpq/ntpq-opts.c@1.373 +7 -7 + NTP_4_2_7P367 + + ntpq/ntpq-opts.h@1.373 +3 -3 + NTP_4_2_7P367 + + ntpq/ntpq.1ntpqman@1.187 +2 -2 + NTP_4_2_7P367 + + ntpq/ntpq.1ntpqmdoc@1.187 +2 -2 + NTP_4_2_7P367 + + ntpq/ntpq.html@1.32 +2 -2 + NTP_4_2_7P367 + + ntpq/ntpq.man.in@1.187 +2 -2 + NTP_4_2_7P367 + + ntpq/ntpq.mdoc.in@1.187 +2 -2 + NTP_4_2_7P367 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.358 +2 -2 + NTP_4_2_7P367 + + ntpsnmpd/ntpsnmpd-opts.c@1.373 +7 -7 + NTP_4_2_7P367 + + ntpsnmpd/ntpsnmpd-opts.h@1.373 +3 -3 + NTP_4_2_7P367 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.187 +3 -3 + NTP_4_2_7P367 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.187 +3 -3 + NTP_4_2_7P367 + + ntpsnmpd/ntpsnmpd.html@1.30 +1 -1 + NTP_4_2_7P367 + + ntpsnmpd/ntpsnmpd.man.in@1.187 +3 -3 + NTP_4_2_7P367 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.187 +3 -3 + NTP_4_2_7P367 + + packageinfo.sh@1.370 +1 -1 + NTP_4_2_7P367 + + scripts/invoke-ntp-wait.texi@1.175 +1 -1 + NTP_4_2_7P367 + + scripts/ntp-wait.1ntp-waitman@1.186 +3 -3 + NTP_4_2_7P367 + + scripts/ntp-wait.1ntp-waitmdoc@1.186 +3 -3 + NTP_4_2_7P367 + + scripts/ntp-wait.html@1.191 +1 -1 + NTP_4_2_7P367 + + scripts/ntp-wait.man.in@1.186 +3 -3 + NTP_4_2_7P367 + + scripts/ntp-wait.mdoc.in@1.186 +3 -3 + NTP_4_2_7P367 + + sntp/invoke-sntp.texi@1.355 +2 -2 + NTP_4_2_7P367 + + sntp/sntp-opts.c@1.370 +7 -7 + NTP_4_2_7P367 + + sntp/sntp-opts.h@1.370 +3 -3 + NTP_4_2_7P367 + + sntp/sntp.1sntpman@1.190 +3 -3 + NTP_4_2_7P367 + + sntp/sntp.1sntpmdoc@1.190 +3 -3 + NTP_4_2_7P367 + + sntp/sntp.html@1.370 +2 -2 + NTP_4_2_7P367 + + sntp/sntp.man.in@1.190 +3 -3 + NTP_4_2_7P367 + + sntp/sntp.mdoc.in@1.190 +3 -3 + NTP_4_2_7P367 + + util/invoke-ntp-keygen.texi@1.359 +2 -2 + NTP_4_2_7P367 + + util/ntp-keygen-opts.c@1.373 +7 -7 + NTP_4_2_7P367 + + util/ntp-keygen-opts.h@1.373 +3 -3 + NTP_4_2_7P367 + + util/ntp-keygen.1ntp-keygenman@1.187 +3 -3 + NTP_4_2_7P367 + + util/ntp-keygen.1ntp-keygenmdoc@1.187 +3 -3 + NTP_4_2_7P367 + + util/ntp-keygen.html@1.36 +2 -2 + NTP_4_2_7P367 + + util/ntp-keygen.man.in@1.187 +3 -3 + NTP_4_2_7P367 + + util/ntp-keygen.mdoc.in@1.187 +3 -3 + NTP_4_2_7P367 + +ChangeSet@1.2943, 2013-04-24 19:13:53-04:00, stenn@deacon.udel.edu + [Bug 2382] Implement LOGTOD using ldexp() instead of shifting + + ChangeLog@1.1293 +1 -0 + [Bug 2382] Implement LOGTOD using ldexp() instead of shifting + + include/ntp.h@1.207 +2 -3 + [Bug 2382] Implement LOGTOD using ldexp() instead of shifting + +ChangeSet@1.2942, 2013-04-17 12:50:12-04:00, utterback@pogo.udel.edu + ChangeLog, ifiter_ioctl.c: + [Bug 1485] Sometimes ntpd crashes + + ChangeLog@1.1292 +1 -0 + [Bug 1485] Sometimes ntpd crashes + + lib/isc/unix/ifiter_ioctl.c@1.32 +26 -11 + [Bug 1485] Sometimes ntpd crashes + +ChangeSet@1.2941, 2013-04-17 11:36:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P366 + TAG: NTP_4_2_7P366 + + ChangeLog@1.1291 +1 -0 + NTP_4_2_7P366 + + ntpd/invoke-ntp.conf.texi@1.41 +1 -1 + NTP_4_2_7P366 + + ntpd/invoke-ntp.keys.texi@1.41 +1 -1 + NTP_4_2_7P366 + + ntpd/invoke-ntpd.texi@1.357 +2 -2 + NTP_4_2_7P366 + + ntpd/ntp.conf.5man@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntp.conf.5mdoc@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntp.conf.html@1.39 +1 -1 + NTP_4_2_7P366 + + ntpd/ntp.conf.man.in@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntp.conf.mdoc.in@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntp.keys.5man@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntp.keys.5mdoc@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntp.keys.html@1.40 +1 -1 + NTP_4_2_7P366 + + ntpd/ntp.keys.man.in@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntp.keys.mdoc.in@1.75 +3 -3 + NTP_4_2_7P366 + + ntpd/ntpd-opts.c@1.375 +7 -7 + NTP_4_2_7P366 + + ntpd/ntpd-opts.h@1.375 +3 -3 + NTP_4_2_7P366 + + ntpd/ntpd.1ntpdman@1.186 +3 -3 + NTP_4_2_7P366 + + ntpd/ntpd.1ntpdmdoc@1.186 +3 -3 + NTP_4_2_7P366 + + ntpd/ntpd.html@1.34 +2 -2 + NTP_4_2_7P366 + + ntpd/ntpd.man.in@1.186 +3 -3 + NTP_4_2_7P366 + + ntpd/ntpd.mdoc.in@1.186 +3 -3 + NTP_4_2_7P366 + + ntpdc/invoke-ntpdc.texi@1.354 +2 -2 + NTP_4_2_7P366 + + ntpdc/ntpdc-opts.c@1.369 +7 -7 + NTP_4_2_7P366 + + ntpdc/ntpdc-opts.h@1.369 +3 -3 + NTP_4_2_7P366 + + ntpdc/ntpdc.1ntpdcman@1.185 +2 -2 + NTP_4_2_7P366 + + ntpdc/ntpdc.1ntpdcmdoc@1.185 +2 -2 + NTP_4_2_7P366 + + ntpdc/ntpdc.html@1.198 +2 -2 + NTP_4_2_7P366 + + ntpdc/ntpdc.man.in@1.185 +2 -2 + NTP_4_2_7P366 + + ntpdc/ntpdc.mdoc.in@1.185 +2 -2 + NTP_4_2_7P366 + + ntpq/invoke-ntpq.texi@1.358 +2 -2 + NTP_4_2_7P366 + + ntpq/ntpq-opts.c@1.372 +7 -7 + NTP_4_2_7P366 + + ntpq/ntpq-opts.h@1.372 +3 -3 + NTP_4_2_7P366 + + ntpq/ntpq.1ntpqman@1.186 +2 -2 + NTP_4_2_7P366 + + ntpq/ntpq.1ntpqmdoc@1.186 +2 -2 + NTP_4_2_7P366 + + ntpq/ntpq.html@1.31 +2 -2 + NTP_4_2_7P366 + + ntpq/ntpq.man.in@1.186 +2 -2 + NTP_4_2_7P366 + + ntpq/ntpq.mdoc.in@1.186 +2 -2 + NTP_4_2_7P366 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.357 +2 -2 + NTP_4_2_7P366 + + ntpsnmpd/ntpsnmpd-opts.c@1.372 +7 -7 + NTP_4_2_7P366 + + ntpsnmpd/ntpsnmpd-opts.h@1.372 +3 -3 + NTP_4_2_7P366 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.186 +3 -3 + NTP_4_2_7P366 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.186 +3 -3 + NTP_4_2_7P366 + + ntpsnmpd/ntpsnmpd.html@1.29 +1 -1 + NTP_4_2_7P366 + + ntpsnmpd/ntpsnmpd.man.in@1.186 +3 -3 + NTP_4_2_7P366 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.186 +3 -3 + NTP_4_2_7P366 + + packageinfo.sh@1.369 +1 -1 + NTP_4_2_7P366 + + scripts/invoke-ntp-wait.texi@1.174 +1 -1 + NTP_4_2_7P366 + + scripts/ntp-wait.1ntp-waitman@1.185 +3 -3 + NTP_4_2_7P366 + + scripts/ntp-wait.1ntp-waitmdoc@1.185 +3 -3 + NTP_4_2_7P366 + + scripts/ntp-wait.html@1.190 +1 -1 + NTP_4_2_7P366 + + scripts/ntp-wait.man.in@1.185 +3 -3 + NTP_4_2_7P366 + + scripts/ntp-wait.mdoc.in@1.185 +3 -3 + NTP_4_2_7P366 + + sntp/invoke-sntp.texi@1.354 +2 -2 + NTP_4_2_7P366 + + sntp/sntp-opts.c@1.369 +7 -7 + NTP_4_2_7P366 + + sntp/sntp-opts.h@1.369 +3 -3 + NTP_4_2_7P366 + + sntp/sntp.1sntpman@1.189 +3 -3 + NTP_4_2_7P366 + + sntp/sntp.1sntpmdoc@1.189 +3 -3 + NTP_4_2_7P366 + + sntp/sntp.html@1.369 +2 -2 + NTP_4_2_7P366 + + sntp/sntp.man.in@1.189 +3 -3 + NTP_4_2_7P366 + + sntp/sntp.mdoc.in@1.189 +3 -3 + NTP_4_2_7P366 + + util/invoke-ntp-keygen.texi@1.358 +2 -2 + NTP_4_2_7P366 + + util/ntp-keygen-opts.c@1.372 +7 -7 + NTP_4_2_7P366 + + util/ntp-keygen-opts.h@1.372 +3 -3 + NTP_4_2_7P366 + + util/ntp-keygen.1ntp-keygenman@1.186 +3 -3 + NTP_4_2_7P366 + + util/ntp-keygen.1ntp-keygenmdoc@1.186 +3 -3 + NTP_4_2_7P366 + + util/ntp-keygen.html@1.35 +2 -2 + NTP_4_2_7P366 + + util/ntp-keygen.man.in@1.186 +3 -3 + NTP_4_2_7P366 + + util/ntp-keygen.mdoc.in@1.186 +3 -3 + NTP_4_2_7P366 + +ChangeSet@1.2940, 2013-04-16 19:58:03-04:00, stenn@deacon.udel.edu + [Bug 1866] Disable some debugging output in refclock_oncore + + ChangeLog@1.1290 +1 -0 + [Bug 1866] Disable some debugging output in refclock_oncore + + ntpd/refclock_oncore.c@1.95 +7 -0 + [Bug 1866] Disable some debugging output in refclock_oncore + +ChangeSet@1.2939, 2013-04-16 09:55:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P365 + TAG: NTP_4_2_7P365 + + ChangeLog@1.1289 +1 -0 + NTP_4_2_7P365 + + ntpd/invoke-ntp.conf.texi@1.40 +1 -1 + NTP_4_2_7P365 + + ntpd/invoke-ntp.keys.texi@1.40 +1 -1 + NTP_4_2_7P365 + + ntpd/invoke-ntpd.texi@1.356 +2 -2 + NTP_4_2_7P365 + + ntpd/ntp.conf.5man@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntp.conf.5mdoc@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntp.conf.html@1.38 +1 -1 + NTP_4_2_7P365 + + ntpd/ntp.conf.man.in@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntp.conf.mdoc.in@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntp.keys.5man@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntp.keys.5mdoc@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntp.keys.html@1.39 +1 -1 + NTP_4_2_7P365 + + ntpd/ntp.keys.man.in@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntp.keys.mdoc.in@1.74 +3 -3 + NTP_4_2_7P365 + + ntpd/ntpd-opts.c@1.374 +7 -7 + NTP_4_2_7P365 + + ntpd/ntpd-opts.h@1.374 +3 -3 + NTP_4_2_7P365 + + ntpd/ntpd.1ntpdman@1.185 +3 -3 + NTP_4_2_7P365 + + ntpd/ntpd.1ntpdmdoc@1.185 +3 -3 + NTP_4_2_7P365 + + ntpd/ntpd.html@1.33 +2 -2 + NTP_4_2_7P365 + + ntpd/ntpd.man.in@1.185 +3 -3 + NTP_4_2_7P365 + + ntpd/ntpd.mdoc.in@1.185 +3 -3 + NTP_4_2_7P365 + + ntpdc/invoke-ntpdc.texi@1.353 +2 -2 + NTP_4_2_7P365 + + ntpdc/ntpdc-opts.c@1.368 +7 -7 + NTP_4_2_7P365 + + ntpdc/ntpdc-opts.h@1.368 +3 -3 + NTP_4_2_7P365 + + ntpdc/ntpdc.1ntpdcman@1.184 +2 -2 + NTP_4_2_7P365 + + ntpdc/ntpdc.1ntpdcmdoc@1.184 +2 -2 + NTP_4_2_7P365 + + ntpdc/ntpdc.html@1.197 +2 -2 + NTP_4_2_7P365 + + ntpdc/ntpdc.man.in@1.184 +2 -2 + NTP_4_2_7P365 + + ntpdc/ntpdc.mdoc.in@1.184 +2 -2 + NTP_4_2_7P365 + + ntpq/invoke-ntpq.texi@1.357 +2 -2 + NTP_4_2_7P365 + + ntpq/ntpq-opts.c@1.371 +7 -7 + NTP_4_2_7P365 + + ntpq/ntpq-opts.h@1.371 +3 -3 + NTP_4_2_7P365 + + ntpq/ntpq.1ntpqman@1.185 +2 -2 + NTP_4_2_7P365 + + ntpq/ntpq.1ntpqmdoc@1.185 +2 -2 + NTP_4_2_7P365 + + ntpq/ntpq.html@1.30 +2 -2 + NTP_4_2_7P365 + + ntpq/ntpq.man.in@1.185 +2 -2 + NTP_4_2_7P365 + + ntpq/ntpq.mdoc.in@1.185 +2 -2 + NTP_4_2_7P365 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.356 +2 -2 + NTP_4_2_7P365 + + ntpsnmpd/ntpsnmpd-opts.c@1.371 +7 -7 + NTP_4_2_7P365 + + ntpsnmpd/ntpsnmpd-opts.h@1.371 +3 -3 + NTP_4_2_7P365 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.185 +3 -3 + NTP_4_2_7P365 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.185 +3 -3 + NTP_4_2_7P365 + + ntpsnmpd/ntpsnmpd.html@1.28 +1 -1 + NTP_4_2_7P365 + + ntpsnmpd/ntpsnmpd.man.in@1.185 +3 -3 + NTP_4_2_7P365 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.185 +3 -3 + NTP_4_2_7P365 + + packageinfo.sh@1.368 +1 -1 + NTP_4_2_7P365 + + scripts/invoke-ntp-wait.texi@1.173 +1 -1 + NTP_4_2_7P365 + + scripts/ntp-wait.1ntp-waitman@1.184 +3 -3 + NTP_4_2_7P365 + + scripts/ntp-wait.1ntp-waitmdoc@1.184 +3 -3 + NTP_4_2_7P365 + + scripts/ntp-wait.html@1.189 +1 -1 + NTP_4_2_7P365 + + scripts/ntp-wait.man.in@1.184 +3 -3 + NTP_4_2_7P365 + + scripts/ntp-wait.mdoc.in@1.184 +3 -3 + NTP_4_2_7P365 + + sntp/invoke-sntp.texi@1.353 +2 -2 + NTP_4_2_7P365 + + sntp/sntp-opts.c@1.368 +7 -7 + NTP_4_2_7P365 + + sntp/sntp-opts.h@1.368 +3 -3 + NTP_4_2_7P365 + + sntp/sntp.1sntpman@1.188 +3 -3 + NTP_4_2_7P365 + + sntp/sntp.1sntpmdoc@1.188 +3 -3 + NTP_4_2_7P365 + + sntp/sntp.html@1.368 +2 -2 + NTP_4_2_7P365 + + sntp/sntp.man.in@1.188 +3 -3 + NTP_4_2_7P365 + + sntp/sntp.mdoc.in@1.188 +3 -3 + NTP_4_2_7P365 + + util/invoke-ntp-keygen.texi@1.357 +2 -2 + NTP_4_2_7P365 + + util/ntp-keygen-opts.c@1.371 +7 -7 + NTP_4_2_7P365 + + util/ntp-keygen-opts.h@1.371 +3 -3 + NTP_4_2_7P365 + + util/ntp-keygen.1ntp-keygenman@1.185 +3 -3 + NTP_4_2_7P365 + + util/ntp-keygen.1ntp-keygenmdoc@1.185 +3 -3 + NTP_4_2_7P365 + + util/ntp-keygen.html@1.34 +2 -2 + NTP_4_2_7P365 + + util/ntp-keygen.man.in@1.185 +3 -3 + NTP_4_2_7P365 + + util/ntp-keygen.mdoc.in@1.185 +3 -3 + NTP_4_2_7P365 + +ChangeSet@1.2936.1.1, 2013-04-16 09:32:43+00:00, stenn@psp-fb1.ntp.org + [Bug 2149] Log an error message if /proc/net/if_inet6 cannot be opened + + ChangeLog@1.1288 +1 -0 + [Bug 2149] Log an error message if /proc/net/if_inet6 cannot be opened + + lib/isc/unix/ifiter_getifaddrs.c@1.10 +8 -2 + [Bug 2149] Log an error message if /proc/net/if_inet6 cannot be opened + +ChangeSet@1.2937, 2013-04-16 05:22:18-04:00, stenn@deacon.udel.edu + Clean up autogen-version check + + sntp/include/autogen-version.def@1.17 +1 -1 + Clean up autogen-version check + +ChangeSet@1.2936, 2013-03-26 11:35:06+00:00, stenn@deacon.udel.edu + NTP_4_2_7P364 + TAG: NTP_4_2_7P364 + + ChangeLog@1.1287 +1 -0 + NTP_4_2_7P364 + + ntpd/invoke-ntp.conf.texi@1.39 +1 -1 + NTP_4_2_7P364 + + ntpd/invoke-ntp.keys.texi@1.39 +1 -1 + NTP_4_2_7P364 + + ntpd/invoke-ntpd.texi@1.355 +2 -2 + NTP_4_2_7P364 + + ntpd/ntp.conf.5man@1.73 +3 -3 + NTP_4_2_7P364 + + ntpd/ntp.conf.5mdoc@1.73 +2 -2 + NTP_4_2_7P364 + + ntpd/ntp.conf.html@1.37 +1 -1 + NTP_4_2_7P364 + + ntpd/ntp.conf.man.in@1.73 +3 -3 + NTP_4_2_7P364 + + ntpd/ntp.conf.mdoc.in@1.73 +2 -2 + NTP_4_2_7P364 + + ntpd/ntp.keys.5man@1.73 +3 -3 + NTP_4_2_7P364 + + ntpd/ntp.keys.5mdoc@1.73 +2 -2 + NTP_4_2_7P364 + + ntpd/ntp.keys.html@1.38 +1 -1 + NTP_4_2_7P364 + + ntpd/ntp.keys.man.in@1.73 +3 -3 + NTP_4_2_7P364 + + ntpd/ntp.keys.mdoc.in@1.73 +2 -2 + NTP_4_2_7P364 + + ntpd/ntpd-opts.c@1.373 +7 -7 + NTP_4_2_7P364 + + ntpd/ntpd-opts.h@1.373 +3 -3 + NTP_4_2_7P364 + + ntpd/ntpd.1ntpdman@1.184 +3 -3 + NTP_4_2_7P364 + + ntpd/ntpd.1ntpdmdoc@1.184 +2 -2 + NTP_4_2_7P364 + + ntpd/ntpd.html@1.32 +2 -2 + NTP_4_2_7P364 + + ntpd/ntpd.man.in@1.184 +3 -3 + NTP_4_2_7P364 + + ntpd/ntpd.mdoc.in@1.184 +2 -2 + NTP_4_2_7P364 + + ntpdc/invoke-ntpdc.texi@1.352 +2 -2 + NTP_4_2_7P364 + + ntpdc/ntpdc-opts.c@1.367 +7 -7 + NTP_4_2_7P364 + + ntpdc/ntpdc-opts.h@1.367 +3 -3 + NTP_4_2_7P364 + + ntpdc/ntpdc.1ntpdcman@1.183 +2 -2 + NTP_4_2_7P364 + + ntpdc/ntpdc.1ntpdcmdoc@1.183 +1 -1 + NTP_4_2_7P364 + + ntpdc/ntpdc.html@1.196 +2 -2 + NTP_4_2_7P364 + + ntpdc/ntpdc.man.in@1.183 +2 -2 + NTP_4_2_7P364 + + ntpdc/ntpdc.mdoc.in@1.183 +1 -1 + NTP_4_2_7P364 + + ntpq/invoke-ntpq.texi@1.356 +2 -2 + NTP_4_2_7P364 + + ntpq/ntpq-opts.c@1.370 +7 -7 + NTP_4_2_7P364 + + ntpq/ntpq-opts.h@1.370 +3 -3 + NTP_4_2_7P364 + + ntpq/ntpq.1ntpqman@1.184 +2 -2 + NTP_4_2_7P364 + + ntpq/ntpq.1ntpqmdoc@1.184 +1 -1 + NTP_4_2_7P364 + + ntpq/ntpq.html@1.29 +2 -2 + NTP_4_2_7P364 + + ntpq/ntpq.man.in@1.184 +2 -2 + NTP_4_2_7P364 + + ntpq/ntpq.mdoc.in@1.184 +1 -1 + NTP_4_2_7P364 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.355 +2 -2 + NTP_4_2_7P364 + + ntpsnmpd/ntpsnmpd-opts.c@1.370 +7 -7 + NTP_4_2_7P364 + + ntpsnmpd/ntpsnmpd-opts.h@1.370 +3 -3 + NTP_4_2_7P364 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.184 +3 -3 + NTP_4_2_7P364 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.184 +2 -2 + NTP_4_2_7P364 + + ntpsnmpd/ntpsnmpd.html@1.27 +1 -1 + NTP_4_2_7P364 + + ntpsnmpd/ntpsnmpd.man.in@1.184 +3 -3 + NTP_4_2_7P364 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.184 +2 -2 + NTP_4_2_7P364 + + packageinfo.sh@1.367 +1 -1 + NTP_4_2_7P364 + + scripts/invoke-ntp-wait.texi@1.172 +1 -1 + NTP_4_2_7P364 + + scripts/ntp-wait.1ntp-waitman@1.183 +3 -3 + NTP_4_2_7P364 + + scripts/ntp-wait.1ntp-waitmdoc@1.183 +2 -2 + NTP_4_2_7P364 + + scripts/ntp-wait.html@1.188 +1 -1 + NTP_4_2_7P364 + + scripts/ntp-wait.man.in@1.183 +3 -3 + NTP_4_2_7P364 + + scripts/ntp-wait.mdoc.in@1.183 +2 -2 + NTP_4_2_7P364 + + sntp/invoke-sntp.texi@1.352 +2 -2 + NTP_4_2_7P364 + + sntp/sntp-opts.c@1.367 +7 -7 + NTP_4_2_7P364 + + sntp/sntp-opts.h@1.367 +3 -3 + NTP_4_2_7P364 + + sntp/sntp.1sntpman@1.187 +3 -3 + NTP_4_2_7P364 + + sntp/sntp.1sntpmdoc@1.187 +2 -2 + NTP_4_2_7P364 + + sntp/sntp.html@1.367 +2 -2 + NTP_4_2_7P364 + + sntp/sntp.man.in@1.187 +3 -3 + NTP_4_2_7P364 + + sntp/sntp.mdoc.in@1.187 +2 -2 + NTP_4_2_7P364 + + util/invoke-ntp-keygen.texi@1.356 +2 -2 + NTP_4_2_7P364 + + util/ntp-keygen-opts.c@1.370 +7 -7 + NTP_4_2_7P364 + + util/ntp-keygen-opts.h@1.370 +3 -3 + NTP_4_2_7P364 + + util/ntp-keygen.1ntp-keygenman@1.184 +3 -3 + NTP_4_2_7P364 + + util/ntp-keygen.1ntp-keygenmdoc@1.184 +2 -2 + NTP_4_2_7P364 + + util/ntp-keygen.html@1.33 +2 -2 + NTP_4_2_7P364 + + util/ntp-keygen.man.in@1.184 +3 -3 + NTP_4_2_7P364 + + util/ntp-keygen.mdoc.in@1.184 +2 -2 + NTP_4_2_7P364 + +ChangeSet@1.2935, 2013-03-26 06:25:16-04:00, stenn@deacon.udel.edu + sntp/include/autogen-version.def + + ChangeLog@1.1286 +1 -0 + sntp/include/autogen-version.def + + sntp/include/autogen-version.def@1.16 +2 -1 + sntp/include/autogen-version.def + +ChangeSet@1.2934, 2013-03-26 09:16:08+00:00, stenn@deacon.udel.edu + NTP_4_2_7P363 + TAG: NTP_4_2_7P363 + + ChangeLog@1.1285 +1 -0 + NTP_4_2_7P363 + + ntpd/invoke-ntp.conf.texi@1.38 +1 -1 + NTP_4_2_7P363 + + ntpd/invoke-ntp.keys.texi@1.38 +1 -1 + NTP_4_2_7P363 + + ntpd/invoke-ntpd.texi@1.354 +2 -2 + NTP_4_2_7P363 + + ntpd/ntp.conf.5man@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntp.conf.5mdoc@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntp.conf.html@1.36 +1 -1 + NTP_4_2_7P363 + + ntpd/ntp.conf.man.in@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntp.conf.mdoc.in@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntp.keys.5man@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntp.keys.5mdoc@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntp.keys.html@1.37 +1 -1 + NTP_4_2_7P363 + + ntpd/ntp.keys.man.in@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntp.keys.mdoc.in@1.72 +3 -3 + NTP_4_2_7P363 + + ntpd/ntpd-opts.c@1.372 +7 -7 + NTP_4_2_7P363 + + ntpd/ntpd-opts.h@1.372 +3 -3 + NTP_4_2_7P363 + + ntpd/ntpd.1ntpdman@1.183 +3 -3 + NTP_4_2_7P363 + + ntpd/ntpd.1ntpdmdoc@1.183 +3 -3 + NTP_4_2_7P363 + + ntpd/ntpd.html@1.31 +2 -2 + NTP_4_2_7P363 + + ntpd/ntpd.man.in@1.183 +3 -3 + NTP_4_2_7P363 + + ntpd/ntpd.mdoc.in@1.183 +3 -3 + NTP_4_2_7P363 + + ntpdc/invoke-ntpdc.texi@1.351 +2 -2 + NTP_4_2_7P363 + + ntpdc/ntpdc-opts.c@1.366 +7 -7 + NTP_4_2_7P363 + + ntpdc/ntpdc-opts.h@1.366 +3 -3 + NTP_4_2_7P363 + + ntpdc/ntpdc.1ntpdcman@1.182 +2 -2 + NTP_4_2_7P363 + + ntpdc/ntpdc.1ntpdcmdoc@1.182 +2 -2 + NTP_4_2_7P363 + + ntpdc/ntpdc.html@1.195 +2 -2 + NTP_4_2_7P363 + + ntpdc/ntpdc.man.in@1.182 +2 -2 + NTP_4_2_7P363 + + ntpdc/ntpdc.mdoc.in@1.182 +2 -2 + NTP_4_2_7P363 + + ntpq/invoke-ntpq.texi@1.355 +2 -2 + NTP_4_2_7P363 + + ntpq/ntpq-opts.c@1.369 +7 -7 + NTP_4_2_7P363 + + ntpq/ntpq-opts.h@1.369 +3 -3 + NTP_4_2_7P363 + + ntpq/ntpq.1ntpqman@1.183 +2 -2 + NTP_4_2_7P363 + + ntpq/ntpq.1ntpqmdoc@1.183 +2 -2 + NTP_4_2_7P363 + + ntpq/ntpq.html@1.28 +2 -2 + NTP_4_2_7P363 + + ntpq/ntpq.man.in@1.183 +2 -2 + NTP_4_2_7P363 + + ntpq/ntpq.mdoc.in@1.183 +2 -2 + NTP_4_2_7P363 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.354 +2 -2 + NTP_4_2_7P363 + + ntpsnmpd/ntpsnmpd-opts.c@1.369 +7 -7 + NTP_4_2_7P363 + + ntpsnmpd/ntpsnmpd-opts.h@1.369 +3 -3 + NTP_4_2_7P363 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.183 +3 -3 + NTP_4_2_7P363 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.183 +3 -3 + NTP_4_2_7P363 + + ntpsnmpd/ntpsnmpd.html@1.26 +1 -1 + NTP_4_2_7P363 + + ntpsnmpd/ntpsnmpd.man.in@1.183 +3 -3 + NTP_4_2_7P363 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.183 +3 -3 + NTP_4_2_7P363 + + packageinfo.sh@1.366 +1 -1 + NTP_4_2_7P363 + + scripts/invoke-ntp-wait.texi@1.171 +1 -1 + NTP_4_2_7P363 + + scripts/ntp-wait.1ntp-waitman@1.182 +3 -3 + NTP_4_2_7P363 + + scripts/ntp-wait.1ntp-waitmdoc@1.182 +3 -3 + NTP_4_2_7P363 + + scripts/ntp-wait.html@1.187 +1 -1 + NTP_4_2_7P363 + + scripts/ntp-wait.man.in@1.182 +3 -3 + NTP_4_2_7P363 + + scripts/ntp-wait.mdoc.in@1.182 +3 -3 + NTP_4_2_7P363 + + sntp/invoke-sntp.texi@1.351 +2 -2 + NTP_4_2_7P363 + + sntp/sntp-opts.c@1.366 +7 -7 + NTP_4_2_7P363 + + sntp/sntp-opts.h@1.366 +3 -3 + NTP_4_2_7P363 + + sntp/sntp.1sntpman@1.186 +3 -3 + NTP_4_2_7P363 + + sntp/sntp.1sntpmdoc@1.186 +3 -3 + NTP_4_2_7P363 + + sntp/sntp.html@1.366 +2 -2 + NTP_4_2_7P363 + + sntp/sntp.man.in@1.186 +3 -3 + NTP_4_2_7P363 + + sntp/sntp.mdoc.in@1.186 +3 -3 + NTP_4_2_7P363 + + util/invoke-ntp-keygen.texi@1.355 +2 -2 + NTP_4_2_7P363 + + util/ntp-keygen-opts.c@1.369 +7 -7 + NTP_4_2_7P363 + + util/ntp-keygen-opts.h@1.369 +3 -3 + NTP_4_2_7P363 + + util/ntp-keygen.1ntp-keygenman@1.183 +3 -3 + NTP_4_2_7P363 + + util/ntp-keygen.1ntp-keygenmdoc@1.183 +3 -3 + NTP_4_2_7P363 + + util/ntp-keygen.html@1.32 +2 -2 + NTP_4_2_7P363 + + util/ntp-keygen.man.in@1.183 +3 -3 + NTP_4_2_7P363 + + util/ntp-keygen.mdoc.in@1.183 +3 -3 + NTP_4_2_7P363 + +ChangeSet@1.2933, 2013-03-26 04:56:04-04:00, stenn@deacon.udel.edu + Upgrade to libopts from 5.17.3pre10 + + ChangeLog@1.1284 +2 -0 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/Makefile.am@1.20 +4 -4 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/ag-char-map.h@1.23 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/ao-strs.c@1.9 +2 -2 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/ao-strs.h@1.8 +2 -2 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/autoopts/options.h@1.22 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/autoopts/usage-txt.h@1.22 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/genshell.c@1.23 +116 -114 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/genshell.h@1.23 +13 -12 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/m4/libopts.m4@1.26 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/option-value-type.c@1.10 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/option-value-type.h@1.24 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/option-xat-attribute.c@1.10 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/option-xat-attribute.h@1.24 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/proto.h@1.23 +1 -1 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/streqvcmp.c@1.13 +16 -2 + Upgrade to libopts from 5.17.3pre10 + + sntp/libopts/usage.c@1.16 +3 -3 + Upgrade to libopts from 5.17.3pre10 + +ChangeSet@1.2932, 2013-03-19 11:40:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P362 + TAG: NTP_4_2_7P362 + + ChangeLog@1.1283 +1 -0 + NTP_4_2_7P362 + + ntpd/invoke-ntp.conf.texi@1.37 +1 -1 + NTP_4_2_7P362 + + ntpd/invoke-ntp.keys.texi@1.37 +1 -1 + NTP_4_2_7P362 + + ntpd/invoke-ntpd.texi@1.353 +2 -2 + NTP_4_2_7P362 + + ntpd/ntp.conf.5man@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntp.conf.5mdoc@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntp.conf.html@1.35 +1 -1 + NTP_4_2_7P362 + + ntpd/ntp.conf.man.in@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntp.conf.mdoc.in@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntp.keys.5man@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntp.keys.5mdoc@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntp.keys.html@1.36 +1 -1 + NTP_4_2_7P362 + + ntpd/ntp.keys.man.in@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntp.keys.mdoc.in@1.71 +3 -3 + NTP_4_2_7P362 + + ntpd/ntpd-opts.c@1.371 +7 -7 + NTP_4_2_7P362 + + ntpd/ntpd-opts.h@1.371 +3 -3 + NTP_4_2_7P362 + + ntpd/ntpd.1ntpdman@1.182 +3 -3 + NTP_4_2_7P362 + + ntpd/ntpd.1ntpdmdoc@1.182 +3 -3 + NTP_4_2_7P362 + + ntpd/ntpd.html@1.30 +2 -2 + NTP_4_2_7P362 + + ntpd/ntpd.man.in@1.182 +3 -3 + NTP_4_2_7P362 + + ntpd/ntpd.mdoc.in@1.182 +3 -3 + NTP_4_2_7P362 + + ntpdc/invoke-ntpdc.texi@1.350 +2 -2 + NTP_4_2_7P362 + + ntpdc/ntpdc-opts.c@1.365 +7 -7 + NTP_4_2_7P362 + + ntpdc/ntpdc-opts.h@1.365 +3 -3 + NTP_4_2_7P362 + + ntpdc/ntpdc.1ntpdcman@1.181 +2 -2 + NTP_4_2_7P362 + + ntpdc/ntpdc.1ntpdcmdoc@1.181 +2 -2 + NTP_4_2_7P362 + + ntpdc/ntpdc.html@1.194 +2 -2 + NTP_4_2_7P362 + + ntpdc/ntpdc.man.in@1.181 +2 -2 + NTP_4_2_7P362 + + ntpdc/ntpdc.mdoc.in@1.181 +2 -2 + NTP_4_2_7P362 + + ntpq/invoke-ntpq.texi@1.354 +2 -2 + NTP_4_2_7P362 + + ntpq/ntpq-opts.c@1.368 +7 -7 + NTP_4_2_7P362 + + ntpq/ntpq-opts.h@1.368 +3 -3 + NTP_4_2_7P362 + + ntpq/ntpq.1ntpqman@1.182 +2 -2 + NTP_4_2_7P362 + + ntpq/ntpq.1ntpqmdoc@1.182 +2 -2 + NTP_4_2_7P362 + + ntpq/ntpq.html@1.27 +2 -2 + NTP_4_2_7P362 + + ntpq/ntpq.man.in@1.182 +2 -2 + NTP_4_2_7P362 + + ntpq/ntpq.mdoc.in@1.182 +2 -2 + NTP_4_2_7P362 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.353 +2 -2 + NTP_4_2_7P362 + + ntpsnmpd/ntpsnmpd-opts.c@1.368 +7 -7 + NTP_4_2_7P362 + + ntpsnmpd/ntpsnmpd-opts.h@1.368 +3 -3 + NTP_4_2_7P362 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.182 +3 -3 + NTP_4_2_7P362 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.182 +3 -3 + NTP_4_2_7P362 + + ntpsnmpd/ntpsnmpd.html@1.25 +1 -1 + NTP_4_2_7P362 + + ntpsnmpd/ntpsnmpd.man.in@1.182 +3 -3 + NTP_4_2_7P362 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.182 +3 -3 + NTP_4_2_7P362 + + packageinfo.sh@1.365 +1 -1 + NTP_4_2_7P362 + + scripts/invoke-ntp-wait.texi@1.170 +1 -1 + NTP_4_2_7P362 + + scripts/ntp-wait.1ntp-waitman@1.181 +3 -3 + NTP_4_2_7P362 + + scripts/ntp-wait.1ntp-waitmdoc@1.181 +3 -3 + NTP_4_2_7P362 + + scripts/ntp-wait.html@1.186 +1 -1 + NTP_4_2_7P362 + + scripts/ntp-wait.man.in@1.181 +3 -3 + NTP_4_2_7P362 + + scripts/ntp-wait.mdoc.in@1.181 +3 -3 + NTP_4_2_7P362 + + sntp/invoke-sntp.texi@1.350 +2 -2 + NTP_4_2_7P362 + + sntp/sntp-opts.c@1.365 +7 -7 + NTP_4_2_7P362 + + sntp/sntp-opts.h@1.365 +3 -3 + NTP_4_2_7P362 + + sntp/sntp.1sntpman@1.185 +3 -3 + NTP_4_2_7P362 + + sntp/sntp.1sntpmdoc@1.185 +3 -3 + NTP_4_2_7P362 + + sntp/sntp.html@1.365 +2 -2 + NTP_4_2_7P362 + + sntp/sntp.man.in@1.185 +3 -3 + NTP_4_2_7P362 + + sntp/sntp.mdoc.in@1.185 +3 -3 + NTP_4_2_7P362 + + util/invoke-ntp-keygen.texi@1.354 +2 -2 + NTP_4_2_7P362 + + util/ntp-keygen-opts.c@1.368 +7 -7 + NTP_4_2_7P362 + + util/ntp-keygen-opts.h@1.368 +3 -3 + NTP_4_2_7P362 + + util/ntp-keygen.1ntp-keygenman@1.182 +3 -3 + NTP_4_2_7P362 + + util/ntp-keygen.1ntp-keygenmdoc@1.182 +3 -3 + NTP_4_2_7P362 + + util/ntp-keygen.html@1.31 +2 -2 + NTP_4_2_7P362 + + util/ntp-keygen.man.in@1.182 +3 -3 + NTP_4_2_7P362 + + util/ntp-keygen.mdoc.in@1.182 +3 -3 + NTP_4_2_7P362 + +ChangeSet@1.2931, 2013-03-19 06:26:04-04:00, stenn@deacon.udel.edu + [Bug 2364] "sed -i" is not portable + + ChangeLog@1.1282 +1 -0 + [Bug 2364] "sed -i" is not portable + + configure.ac@1.558 +1 -1 + [Bug 2364] "sed -i" is not portable + +ChangeSet@1.2930, 2013-03-17 05:08:00+00:00, stenn@deacon.udel.edu + NTP_4_2_7P361 + TAG: NTP_4_2_7P361 + + ChangeLog@1.1281 +1 -0 + NTP_4_2_7P361 + + ntpd/invoke-ntp.conf.texi@1.36 +1 -1 + NTP_4_2_7P361 + + ntpd/invoke-ntp.keys.texi@1.36 +1 -1 + NTP_4_2_7P361 + + ntpd/invoke-ntpd.texi@1.352 +2 -2 + NTP_4_2_7P361 + + ntpd/ntp.conf.5man@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntp.conf.5mdoc@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntp.conf.html@1.34 +1 -1 + NTP_4_2_7P361 + + ntpd/ntp.conf.man.in@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntp.conf.mdoc.in@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntp.keys.5man@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntp.keys.5mdoc@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntp.keys.html@1.35 +1 -1 + NTP_4_2_7P361 + + ntpd/ntp.keys.man.in@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntp.keys.mdoc.in@1.70 +3 -3 + NTP_4_2_7P361 + + ntpd/ntpd-opts.c@1.370 +10 -11 + NTP_4_2_7P361 + + ntpd/ntpd-opts.h@1.370 +3 -3 + NTP_4_2_7P361 + + ntpd/ntpd.1ntpdman@1.181 +3 -3 + NTP_4_2_7P361 + + ntpd/ntpd.1ntpdmdoc@1.181 +3 -3 + NTP_4_2_7P361 + + ntpd/ntpd.html@1.29 +2 -2 + NTP_4_2_7P361 + + ntpd/ntpd.man.in@1.181 +3 -3 + NTP_4_2_7P361 + + ntpd/ntpd.mdoc.in@1.181 +3 -3 + NTP_4_2_7P361 + + ntpdc/invoke-ntpdc.texi@1.349 +2 -2 + NTP_4_2_7P361 + + ntpdc/ntpdc-opts.c@1.364 +10 -11 + NTP_4_2_7P361 + + ntpdc/ntpdc-opts.h@1.364 +3 -3 + NTP_4_2_7P361 + + ntpdc/ntpdc.1ntpdcman@1.180 +2 -2 + NTP_4_2_7P361 + + ntpdc/ntpdc.1ntpdcmdoc@1.180 +2 -2 + NTP_4_2_7P361 + + ntpdc/ntpdc.html@1.193 +2 -2 + NTP_4_2_7P361 + + ntpdc/ntpdc.man.in@1.180 +2 -2 + NTP_4_2_7P361 + + ntpdc/ntpdc.mdoc.in@1.180 +2 -2 + NTP_4_2_7P361 + + ntpq/invoke-ntpq.texi@1.353 +2 -2 + NTP_4_2_7P361 + + ntpq/ntpq-opts.c@1.367 +10 -11 + NTP_4_2_7P361 + + ntpq/ntpq-opts.h@1.367 +3 -3 + NTP_4_2_7P361 + + ntpq/ntpq.1ntpqman@1.181 +2 -2 + NTP_4_2_7P361 + + ntpq/ntpq.1ntpqmdoc@1.181 +2 -2 + NTP_4_2_7P361 + + ntpq/ntpq.html@1.26 +2 -2 + NTP_4_2_7P361 + + ntpq/ntpq.man.in@1.181 +2 -2 + NTP_4_2_7P361 + + ntpq/ntpq.mdoc.in@1.181 +2 -2 + NTP_4_2_7P361 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.352 +2 -2 + NTP_4_2_7P361 + + ntpsnmpd/ntpsnmpd-opts.c@1.367 +10 -11 + NTP_4_2_7P361 + + ntpsnmpd/ntpsnmpd-opts.h@1.367 +3 -3 + NTP_4_2_7P361 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.181 +3 -3 + NTP_4_2_7P361 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.181 +3 -3 + NTP_4_2_7P361 + + ntpsnmpd/ntpsnmpd.html@1.24 +1 -1 + NTP_4_2_7P361 + + ntpsnmpd/ntpsnmpd.man.in@1.181 +3 -3 + NTP_4_2_7P361 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.181 +3 -3 + NTP_4_2_7P361 + + packageinfo.sh@1.364 +1 -1 + NTP_4_2_7P361 + + scripts/invoke-ntp-wait.texi@1.169 +1 -1 + NTP_4_2_7P361 + + scripts/ntp-wait.1ntp-waitman@1.180 +3 -3 + NTP_4_2_7P361 + + scripts/ntp-wait.1ntp-waitmdoc@1.180 +3 -3 + NTP_4_2_7P361 + + scripts/ntp-wait.html@1.185 +1 -1 + NTP_4_2_7P361 + + scripts/ntp-wait.man.in@1.180 +3 -3 + NTP_4_2_7P361 + + scripts/ntp-wait.mdoc.in@1.180 +3 -3 + NTP_4_2_7P361 + + sntp/invoke-sntp.texi@1.349 +2 -2 + NTP_4_2_7P361 + + sntp/sntp-opts.c@1.364 +10 -11 + NTP_4_2_7P361 + + sntp/sntp-opts.h@1.364 +3 -3 + NTP_4_2_7P361 + + sntp/sntp.1sntpman@1.184 +3 -3 + NTP_4_2_7P361 + + sntp/sntp.1sntpmdoc@1.184 +3 -3 + NTP_4_2_7P361 + + sntp/sntp.html@1.364 +2 -2 + NTP_4_2_7P361 + + sntp/sntp.man.in@1.184 +3 -3 + NTP_4_2_7P361 + + sntp/sntp.mdoc.in@1.184 +3 -3 + NTP_4_2_7P361 + + util/invoke-ntp-keygen.texi@1.353 +2 -2 + NTP_4_2_7P361 + + util/ntp-keygen-opts.c@1.367 +10 -11 + NTP_4_2_7P361 + + util/ntp-keygen-opts.h@1.367 +3 -3 + NTP_4_2_7P361 + + util/ntp-keygen.1ntp-keygenman@1.181 +3 -3 + NTP_4_2_7P361 + + util/ntp-keygen.1ntp-keygenmdoc@1.181 +3 -3 + NTP_4_2_7P361 + + util/ntp-keygen.html@1.30 +2 -2 + NTP_4_2_7P361 + + util/ntp-keygen.man.in@1.181 +3 -3 + NTP_4_2_7P361 + + util/ntp-keygen.mdoc.in@1.181 +3 -3 + NTP_4_2_7P361 + +ChangeSet@1.2929, 2013-03-17 00:09:12+00:00, stenn@psp-fb1.ntp.org + [Bug 2365] "make check" fails in libevent + + ChangeLog@1.1280 +1 -0 + [Bug 2365] "make check" fails in libevent + + sntp/libevent/test/include.am@1.2 +1 -1 + [Bug 2365] "make check" fails in libevent + +ChangeSet@1.2928, 2013-03-16 23:12:44+00:00, stenn@psp-fb1.ntp.org + [Bug 2357] sntp/libopts/usage.c sometimes needs -lintl + + ChangeLog@1.1279 +1 -0 + [Bug 2357] sntp/libopts/usage.c sometimes needs -lintl + + configure.ac@1.557 +1 -0 + [Bug 2357] sntp/libopts/usage.c sometimes needs -lintl + + sntp/configure.ac@1.73 +1 -0 + [Bug 2357] sntp/libopts/usage.c sometimes needs -lintl + +ChangeSet@1.2927, 2013-03-15 07:13:04+00:00, stenn@deacon.udel.edu + NTP_4_2_7P360 + TAG: NTP_4_2_7P360 + + ChangeLog@1.1278 +1 -0 + NTP_4_2_7P360 + + ntpd/invoke-ntp.conf.texi@1.35 +1 -1 + NTP_4_2_7P360 + + ntpd/invoke-ntp.keys.texi@1.35 +1 -1 + NTP_4_2_7P360 + + ntpd/invoke-ntpd.texi@1.351 +2 -2 + NTP_4_2_7P360 + + ntpd/ntp.conf.5man@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntp.conf.5mdoc@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntp.conf.html@1.33 +1 -1 + NTP_4_2_7P360 + + ntpd/ntp.conf.man.in@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntp.conf.mdoc.in@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntp.keys.5man@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntp.keys.5mdoc@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntp.keys.html@1.34 +1 -1 + NTP_4_2_7P360 + + ntpd/ntp.keys.man.in@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntp.keys.mdoc.in@1.69 +3 -3 + NTP_4_2_7P360 + + ntpd/ntpd-opts.c@1.369 +7 -7 + NTP_4_2_7P360 + + ntpd/ntpd-opts.h@1.369 +3 -3 + NTP_4_2_7P360 + + ntpd/ntpd.1ntpdman@1.180 +3 -3 + NTP_4_2_7P360 + + ntpd/ntpd.1ntpdmdoc@1.180 +3 -3 + NTP_4_2_7P360 + + ntpd/ntpd.html@1.28 +3 -3 + NTP_4_2_7P360 + + ntpd/ntpd.man.in@1.180 +3 -3 + NTP_4_2_7P360 + + ntpd/ntpd.mdoc.in@1.180 +3 -3 + NTP_4_2_7P360 + + ntpdc/invoke-ntpdc.texi@1.348 +2 -2 + NTP_4_2_7P360 + + ntpdc/ntpdc-opts.c@1.363 +7 -7 + NTP_4_2_7P360 + + ntpdc/ntpdc-opts.h@1.363 +3 -3 + NTP_4_2_7P360 + + ntpdc/ntpdc.1ntpdcman@1.179 +2 -2 + NTP_4_2_7P360 + + ntpdc/ntpdc.1ntpdcmdoc@1.179 +2 -2 + NTP_4_2_7P360 + + ntpdc/ntpdc.html@1.192 +2 -2 + NTP_4_2_7P360 + + ntpdc/ntpdc.man.in@1.179 +2 -2 + NTP_4_2_7P360 + + ntpdc/ntpdc.mdoc.in@1.179 +2 -2 + NTP_4_2_7P360 + + ntpq/invoke-ntpq.texi@1.352 +2 -2 + NTP_4_2_7P360 + + ntpq/ntpq-opts.c@1.366 +7 -7 + NTP_4_2_7P360 + + ntpq/ntpq-opts.h@1.366 +3 -3 + NTP_4_2_7P360 + + ntpq/ntpq.1ntpqman@1.180 +2 -2 + NTP_4_2_7P360 + + ntpq/ntpq.1ntpqmdoc@1.180 +2 -2 + NTP_4_2_7P360 + + ntpq/ntpq.html@1.25 +3 -3 + NTP_4_2_7P360 + + ntpq/ntpq.man.in@1.180 +2 -2 + NTP_4_2_7P360 + + ntpq/ntpq.mdoc.in@1.180 +2 -2 + NTP_4_2_7P360 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.351 +2 -2 + NTP_4_2_7P360 + + ntpsnmpd/ntpsnmpd-opts.c@1.366 +7 -7 + NTP_4_2_7P360 + + ntpsnmpd/ntpsnmpd-opts.h@1.366 +3 -3 + NTP_4_2_7P360 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.180 +3 -3 + NTP_4_2_7P360 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.180 +3 -3 + NTP_4_2_7P360 + + ntpsnmpd/ntpsnmpd.html@1.23 +1 -1 + NTP_4_2_7P360 + + ntpsnmpd/ntpsnmpd.man.in@1.180 +3 -3 + NTP_4_2_7P360 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.180 +3 -3 + NTP_4_2_7P360 + + packageinfo.sh@1.363 +1 -1 + NTP_4_2_7P360 + + scripts/invoke-ntp-wait.texi@1.168 +1 -1 + NTP_4_2_7P360 + + scripts/ntp-wait.1ntp-waitman@1.179 +3 -3 + NTP_4_2_7P360 + + scripts/ntp-wait.1ntp-waitmdoc@1.179 +3 -3 + NTP_4_2_7P360 + + scripts/ntp-wait.html@1.184 +1 -1 + NTP_4_2_7P360 + + scripts/ntp-wait.man.in@1.179 +3 -3 + NTP_4_2_7P360 + + scripts/ntp-wait.mdoc.in@1.179 +3 -3 + NTP_4_2_7P360 + + sntp/invoke-sntp.texi@1.348 +2 -2 + NTP_4_2_7P360 + + sntp/sntp-opts.c@1.363 +7 -7 + NTP_4_2_7P360 + + sntp/sntp-opts.h@1.363 +3 -3 + NTP_4_2_7P360 + + sntp/sntp.1sntpman@1.183 +3 -3 + NTP_4_2_7P360 + + sntp/sntp.1sntpmdoc@1.183 +3 -3 + NTP_4_2_7P360 + + sntp/sntp.html@1.363 +2 -2 + NTP_4_2_7P360 + + sntp/sntp.man.in@1.183 +3 -3 + NTP_4_2_7P360 + + sntp/sntp.mdoc.in@1.183 +3 -3 + NTP_4_2_7P360 + + util/invoke-ntp-keygen.texi@1.352 +2 -2 + NTP_4_2_7P360 + + util/ntp-keygen-opts.c@1.366 +7 -7 + NTP_4_2_7P360 + + util/ntp-keygen-opts.h@1.366 +3 -3 + NTP_4_2_7P360 + + util/ntp-keygen.1ntp-keygenman@1.180 +3 -3 + NTP_4_2_7P360 + + util/ntp-keygen.1ntp-keygenmdoc@1.180 +3 -3 + NTP_4_2_7P360 + + util/ntp-keygen.html@1.29 +3 -3 + NTP_4_2_7P360 + + util/ntp-keygen.man.in@1.180 +3 -3 + NTP_4_2_7P360 + + util/ntp-keygen.mdoc.in@1.180 +3 -3 + NTP_4_2_7P360 + +ChangeSet@1.2926, 2013-03-15 02:31:25-04:00, stenn@psp-deb1.ntp.org + UPgrade libevent (Coverity fixes, etc.). + ChangeLog, kod_management.c: + EEXIST is OK for mkdir() in sntp/kod_management.c + + BitKeeper/deleted/00/Makefile.am~474636ab6fc9e8d9@1.5 +0 -0 + Delete: sntp/libevent/include/Makefile.am + + BitKeeper/deleted/51/Makefile.am~1dee536054aa1db2@1.11 +0 -0 + Delete: sntp/libevent/test/Makefile.am + + BitKeeper/deleted/97/Makefile.am~e1e2decef1947524@1.8 +0 -0 + Delete: sntp/libevent/sample/Makefile.am + + ChangeLog@1.1277 +1 -0 + Upgrade libevent (coverity fixes, etc.) + + ChangeLog@1.1276 +1 -0 + EEXIST is OK for mkdir() in sntp/kod_management.c + + sntp/kod_management.c@1.31 +2 -1 + EEXIST is OK for mkdir() in sntp/kod_management.c + + sntp/libevent/ChangeLog@1.7 +192 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/ChangeLog-2.0@1.2 +56 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/Makefile.am@1.11 +27 -14 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/Makefile.nmake@1.4 +37 -4 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/README@1.6 +18 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/WIN32-Code/event2/event-config.h@1.6 +2 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/buffer.c@1.8 +39 -13 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/bufferevent-internal.h@1.6 +2 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/bufferevent.c@1.6 +25 -14 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/bufferevent_openssl.c@1.7 +68 -38 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/bufferevent_pair.c@1.6 +2 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/bufferevent_sock.c@1.6 +26 -6 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/configure.ac@1.13 +42 -30 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/configure.ac@1.12 +0 -0 + Rename: sntp/libevent/configure.in -> sntp/libevent/configure.ac + + sntp/libevent/defer-internal.h@1.5 +16 -52 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/epoll.c@1.5 +6 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evbuffer-internal.h@1.6 +8 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evdns.c@1.8 +29 -5 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/event-internal.h@1.8 +59 -16 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/event.c@1.9 +580 -273 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/event_rpcgen.py@1.3 +17 -6 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evmap.c@1.6 +2 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evthread-internal.h@1.6 +1 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evthread.c@1.7 +7 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evthread_pthread.c@1.6 +1 -13 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evthread_win32.c@1.6 +1 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evutil.c@1.8 +201 -78 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evutil_rand.c@1.6 +1 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/evutil_time.c@1.2 +2 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/http-internal.h@1.4 +4 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/http.c@1.8 +99 -56 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/event2/buffer.h@1.5 +22 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/event2/bufferevent.h@1.4 +6 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/event2/event.h@1.8 +81 -29 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/event2/event_struct.h@1.4 +38 -22 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/event2/http.h@1.5 +3 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/event2/thread.h@1.5 +4 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/event2/util.h@1.5 +5 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/include/include.am@1.1 +45 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/include.am + + sntp/libevent/include/include.am@1.0 +0 -0 + + sntp/libevent/libevent_openssl.pc.in@1.3 +2 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/listener.c@1.6 +27 -18 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/log.c@1.5 +8 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/make_epoll_table.py@1.2 +1 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/sample/event-read-fifo.c@1.5 +3 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/sample/http-server.c@1.8 +11 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/sample/include.am@1.1 +40 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/include.am + + sntp/libevent/sample/include.am@1.0 +0 -0 + + sntp/libevent/sample/signal-test.c@1.4 +1 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/sample/time-test.c@1.4 +1 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/signal.c@1.7 +3 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/Makefile.nmake@1.4 +22 -6 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/bench.c@1.4 +8 -8 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/bench_cascade.c@1.4 +16 -11 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/bench_httpclient.c@1.6 +12 -4 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/check-dumpevents.py@1.3 +1 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/include.am@1.1 +144 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/include.am + + sntp/libevent/test/include.am@1.0 +0 -0 + + sntp/libevent/test/print-winsock-errors.c@1.1 +84 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/print-winsock-errors.c + + sntp/libevent/test/print-winsock-errors.c@1.0 +0 -0 + + sntp/libevent/test/regress.c@1.4 +175 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_buffer.c@1.6 +81 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_bufferevent.c@1.4 +13 -5 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_dns.c@1.6 +19 -17 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_et.c@1.4 +3 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_http.c@1.6 +126 -51 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_listener.c@1.6 +1 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_main.c@1.5 +31 -4 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_rpc.c@1.5 +5 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_ssl.c@1.5 +30 -7 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_testutils.c@1.6 +8 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_thread.c@1.4 +24 -13 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_util.c@1.5 +93 -16 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/regress_zlib.c@1.4 +2 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/rpcgen_wrapper.sh@1.3 +13 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test-changelist.c@1.4 +1 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test-dumpevents.c@1.2 +1 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test-eof.c@1.6 +3 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test-init.c@1.4 +1 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test-ratelim.c@1.7 +10 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test-time.c@1.4 +1 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test-weof.c@1.4 +1 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/test.sh@1.7 +11 -4 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/tinytest.c@1.5 +83 -22 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/tinytest.h@1.3 +14 -3 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/test/tinytest_demo.c@1.3 +42 -0 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/util-internal.h@1.8 +27 -2 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/whatsnew-2.0.txt@1.4 +1 -1 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/whatsnew-2.1.txt@1.2 +135 -4 + Upgrade libevent (coverity fixes, etc.) + + sntp/libevent/win32select.c@1.4 +3 -2 + Upgrade libevent (coverity fixes, etc.) + +ChangeSet@1.2925, 2013-03-03 11:39:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P359 + TAG: NTP_4_2_7P359 + + ChangeLog@1.1275 +1 -0 + NTP_4_2_7P359 + + ntpd/invoke-ntp.conf.texi@1.34 +1 -1 + NTP_4_2_7P359 + + ntpd/invoke-ntp.keys.texi@1.34 +1 -1 + NTP_4_2_7P359 + + ntpd/invoke-ntpd.texi@1.350 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.conf.5man@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.conf.5mdoc@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.conf.html@1.32 +1 -1 + NTP_4_2_7P359 + + ntpd/ntp.conf.man.in@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.conf.mdoc.in@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.keys.5man@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.keys.5mdoc@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.keys.html@1.33 +1 -1 + NTP_4_2_7P359 + + ntpd/ntp.keys.man.in@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntp.keys.mdoc.in@1.68 +3 -3 + NTP_4_2_7P359 + + ntpd/ntpd-opts.c@1.368 +7 -7 + NTP_4_2_7P359 + + ntpd/ntpd-opts.h@1.368 +3 -3 + NTP_4_2_7P359 + + ntpd/ntpd.1ntpdman@1.179 +3 -3 + NTP_4_2_7P359 + + ntpd/ntpd.1ntpdmdoc@1.179 +3 -3 + NTP_4_2_7P359 + + ntpd/ntpd.html@1.27 +2 -2 + NTP_4_2_7P359 + + ntpd/ntpd.man.in@1.179 +3 -3 + NTP_4_2_7P359 + + ntpd/ntpd.mdoc.in@1.179 +3 -3 + NTP_4_2_7P359 + + ntpdc/invoke-ntpdc.texi@1.347 +3 -3 + NTP_4_2_7P359 + + ntpdc/ntpdc-opts.c@1.362 +7 -7 + NTP_4_2_7P359 + + ntpdc/ntpdc-opts.h@1.362 +3 -3 + NTP_4_2_7P359 + + ntpdc/ntpdc.1ntpdcman@1.178 +2 -2 + NTP_4_2_7P359 + + ntpdc/ntpdc.1ntpdcmdoc@1.178 +2 -2 + NTP_4_2_7P359 + + ntpdc/ntpdc.html@1.191 +3 -3 + NTP_4_2_7P359 + + ntpdc/ntpdc.man.in@1.178 +2 -2 + NTP_4_2_7P359 + + ntpdc/ntpdc.mdoc.in@1.178 +2 -2 + NTP_4_2_7P359 + + ntpq/invoke-ntpq.texi@1.351 +3 -3 + NTP_4_2_7P359 + + ntpq/ntpq-opts.c@1.365 +7 -7 + NTP_4_2_7P359 + + ntpq/ntpq-opts.h@1.365 +3 -3 + NTP_4_2_7P359 + + ntpq/ntpq.1ntpqman@1.179 +2 -2 + NTP_4_2_7P359 + + ntpq/ntpq.1ntpqmdoc@1.179 +2 -2 + NTP_4_2_7P359 + + ntpq/ntpq.html@1.24 +2 -2 + NTP_4_2_7P359 + + ntpq/ntpq.man.in@1.179 +2 -2 + NTP_4_2_7P359 + + ntpq/ntpq.mdoc.in@1.179 +2 -2 + NTP_4_2_7P359 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.350 +3 -3 + NTP_4_2_7P359 + + ntpsnmpd/ntpsnmpd-opts.c@1.365 +7 -7 + NTP_4_2_7P359 + + ntpsnmpd/ntpsnmpd-opts.h@1.365 +3 -3 + NTP_4_2_7P359 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.179 +3 -3 + NTP_4_2_7P359 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.179 +3 -3 + NTP_4_2_7P359 + + ntpsnmpd/ntpsnmpd.html@1.22 +1 -1 + NTP_4_2_7P359 + + ntpsnmpd/ntpsnmpd.man.in@1.179 +3 -3 + NTP_4_2_7P359 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.179 +3 -3 + NTP_4_2_7P359 + + packageinfo.sh@1.362 +1 -1 + NTP_4_2_7P359 + + scripts/invoke-ntp-wait.texi@1.167 +1 -1 + NTP_4_2_7P359 + + scripts/ntp-wait.1ntp-waitman@1.178 +3 -3 + NTP_4_2_7P359 + + scripts/ntp-wait.1ntp-waitmdoc@1.178 +3 -3 + NTP_4_2_7P359 + + scripts/ntp-wait.html@1.183 +1 -1 + NTP_4_2_7P359 + + scripts/ntp-wait.man.in@1.178 +3 -3 + NTP_4_2_7P359 + + scripts/ntp-wait.mdoc.in@1.178 +3 -3 + NTP_4_2_7P359 + + sntp/invoke-sntp.texi@1.347 +2 -2 + NTP_4_2_7P359 + + sntp/sntp-opts.c@1.362 +7 -7 + NTP_4_2_7P359 + + sntp/sntp-opts.h@1.362 +3 -3 + NTP_4_2_7P359 + + sntp/sntp.1sntpman@1.182 +3 -3 + NTP_4_2_7P359 + + sntp/sntp.1sntpmdoc@1.182 +3 -3 + NTP_4_2_7P359 + + sntp/sntp.html@1.362 +2 -2 + NTP_4_2_7P359 + + sntp/sntp.man.in@1.182 +3 -3 + NTP_4_2_7P359 + + sntp/sntp.mdoc.in@1.182 +3 -3 + NTP_4_2_7P359 + + util/invoke-ntp-keygen.texi@1.351 +3 -3 + NTP_4_2_7P359 + + util/ntp-keygen-opts.c@1.365 +7 -7 + NTP_4_2_7P359 + + util/ntp-keygen-opts.h@1.365 +3 -3 + NTP_4_2_7P359 + + util/ntp-keygen.1ntp-keygenman@1.179 +3 -3 + NTP_4_2_7P359 + + util/ntp-keygen.1ntp-keygenmdoc@1.179 +3 -3 + NTP_4_2_7P359 + + util/ntp-keygen.html@1.28 +2 -2 + NTP_4_2_7P359 + + util/ntp-keygen.man.in@1.179 +3 -3 + NTP_4_2_7P359 + + util/ntp-keygen.mdoc.in@1.179 +3 -3 + NTP_4_2_7P359 + +ChangeSet@1.2924, 2013-03-02 22:41:29-05:00, stenn@deacon.udel.edu + [Bug 2359] Fix send_via_ntp_signd() prototype + + ChangeLog@1.1274 +1 -0 + [Bug 2359] Fix send_via_ntp_signd() prototype + + include/ntpd.h@1.174 +1 -1 + [Bug 2359] Fix send_via_ntp_signd() prototype + +ChangeSet@1.2923, 2013-02-27 11:39:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P358 + TAG: NTP_4_2_7P358 + + ChangeLog@1.1273 +1 -0 + NTP_4_2_7P358 + + ntpd/invoke-ntp.conf.texi@1.33 +1 -1 + NTP_4_2_7P358 + + ntpd/invoke-ntp.keys.texi@1.33 +1 -1 + NTP_4_2_7P358 + + ntpd/invoke-ntpd.texi@1.349 +2 -2 + NTP_4_2_7P358 + + ntpd/ntp.conf.5man@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntp.conf.5mdoc@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntp.conf.html@1.31 +1 -1 + NTP_4_2_7P358 + + ntpd/ntp.conf.man.in@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntp.conf.mdoc.in@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntp.keys.5man@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntp.keys.5mdoc@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntp.keys.html@1.32 +1 -1 + NTP_4_2_7P358 + + ntpd/ntp.keys.man.in@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntp.keys.mdoc.in@1.67 +3 -3 + NTP_4_2_7P358 + + ntpd/ntpd-opts.c@1.367 +248 -95 + NTP_4_2_7P358 + + ntpd/ntpd-opts.h@1.367 +37 -15 + NTP_4_2_7P358 + + ntpd/ntpd.1ntpdman@1.178 +3 -3 + NTP_4_2_7P358 + + ntpd/ntpd.1ntpdmdoc@1.178 +3 -3 + NTP_4_2_7P358 + + ntpd/ntpd.html@1.26 +2 -2 + NTP_4_2_7P358 + + ntpd/ntpd.man.in@1.178 +3 -3 + NTP_4_2_7P358 + + ntpd/ntpd.mdoc.in@1.178 +3 -3 + NTP_4_2_7P358 + + ntpdc/invoke-ntpdc.texi@1.346 +2 -2 + NTP_4_2_7P358 + + ntpdc/ntpdc-opts.c@1.361 +124 -71 + NTP_4_2_7P358 + + ntpdc/ntpdc-opts.h@1.361 +39 -15 + NTP_4_2_7P358 + + ntpdc/ntpdc.1ntpdcman@1.177 +2 -2 + NTP_4_2_7P358 + + ntpdc/ntpdc.1ntpdcmdoc@1.177 +2 -2 + NTP_4_2_7P358 + + ntpdc/ntpdc.html@1.190 +2 -2 + NTP_4_2_7P358 + + ntpdc/ntpdc.man.in@1.177 +2 -2 + NTP_4_2_7P358 + + ntpdc/ntpdc.mdoc.in@1.177 +2 -2 + NTP_4_2_7P358 + + ntpq/invoke-ntpq.texi@1.350 +2 -2 + NTP_4_2_7P358 + + ntpq/ntpq-opts.c@1.364 +117 -70 + NTP_4_2_7P358 + + ntpq/ntpq-opts.h@1.364 +39 -15 + NTP_4_2_7P358 + + ntpq/ntpq.1ntpqman@1.178 +2 -2 + NTP_4_2_7P358 + + ntpq/ntpq.1ntpqmdoc@1.178 +2 -2 + NTP_4_2_7P358 + + ntpq/ntpq.html@1.23 +2 -2 + NTP_4_2_7P358 + + ntpq/ntpq.man.in@1.178 +2 -2 + NTP_4_2_7P358 + + ntpq/ntpq.mdoc.in@1.178 +2 -2 + NTP_4_2_7P358 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.349 +2 -2 + NTP_4_2_7P358 + + ntpsnmpd/ntpsnmpd-opts.c@1.364 +81 -61 + NTP_4_2_7P358 + + ntpsnmpd/ntpsnmpd-opts.h@1.364 +39 -15 + NTP_4_2_7P358 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.178 +3 -3 + NTP_4_2_7P358 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.178 +3 -3 + NTP_4_2_7P358 + + ntpsnmpd/ntpsnmpd.html@1.21 +1 -1 + NTP_4_2_7P358 + + ntpsnmpd/ntpsnmpd.man.in@1.178 +3 -3 + NTP_4_2_7P358 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.178 +3 -3 + NTP_4_2_7P358 + + packageinfo.sh@1.361 +1 -1 + NTP_4_2_7P358 + + scripts/invoke-ntp-wait.texi@1.166 +1 -1 + NTP_4_2_7P358 + + scripts/ntp-wait.1ntp-waitman@1.177 +3 -3 + NTP_4_2_7P358 + + scripts/ntp-wait.1ntp-waitmdoc@1.177 +3 -3 + NTP_4_2_7P358 + + scripts/ntp-wait.html@1.182 +1 -1 + NTP_4_2_7P358 + + scripts/ntp-wait.man.in@1.177 +3 -3 + NTP_4_2_7P358 + + scripts/ntp-wait.mdoc.in@1.177 +3 -3 + NTP_4_2_7P358 + + sntp/invoke-sntp.texi@1.346 +3 -3 + NTP_4_2_7P358 + + sntp/sntp-opts.c@1.361 +189 -94 + NTP_4_2_7P358 + + sntp/sntp-opts.h@1.361 +39 -15 + NTP_4_2_7P358 + + sntp/sntp.1sntpman@1.181 +3 -3 + NTP_4_2_7P358 + + sntp/sntp.1sntpmdoc@1.181 +3 -3 + NTP_4_2_7P358 + + sntp/sntp.html@1.361 +3 -3 + NTP_4_2_7P358 + + sntp/sntp.man.in@1.181 +3 -3 + NTP_4_2_7P358 + + sntp/sntp.mdoc.in@1.181 +3 -3 + NTP_4_2_7P358 + + util/invoke-ntp-keygen.texi@1.350 +2 -2 + NTP_4_2_7P358 + + util/ntp-keygen-opts.c@1.364 +179 -88 + NTP_4_2_7P358 + + util/ntp-keygen-opts.h@1.364 +39 -15 + NTP_4_2_7P358 + + util/ntp-keygen.1ntp-keygenman@1.178 +3 -3 + NTP_4_2_7P358 + + util/ntp-keygen.1ntp-keygenmdoc@1.178 +3 -3 + NTP_4_2_7P358 + + util/ntp-keygen.html@1.27 +2 -2 + NTP_4_2_7P358 + + util/ntp-keygen.man.in@1.178 +3 -3 + NTP_4_2_7P358 + + util/ntp-keygen.mdoc.in@1.178 +3 -3 + NTP_4_2_7P358 + +ChangeSet@1.2919.1.1, 2013-02-27 10:18:58+00:00, stenn@psp-fb1.ntp.org + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + ChangeLog@1.1270.1.1 +1 -0 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/Makefile.am@1.19 +3 -3 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/ag-char-map.h@1.22 +1 -1 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/ao-strs.c@1.8 +1 -1 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/ao-strs.h@1.7 +1 -1 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/autoopts/options.h@1.21 +2 -1 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/autoopts/usage-txt.h@1.21 +141 -141 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/configfile.c@1.19 +31 -18 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/genshell.c@1.22 +31 -14 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/genshell.h@1.22 +33 -12 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/m4/libopts.m4@1.25 +40 -21 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/nested.c@1.13 +2 -10 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/option-value-type.c@1.9 +3 -3 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/option-value-type.h@1.23 +3 -3 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/option-xat-attribute.c@1.9 +3 -3 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/option-xat-attribute.h@1.23 +1 -1 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/proto.h@1.22 +3 -3 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + + sntp/libopts/usage.c@1.15 +18 -5 + Upgrade to autogen-5.17.3pre4 and libopts-38.0.13 + +ChangeSet@1.2921, 2013-02-22 03:49:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P357 + TAG: NTP_4_2_7P357 + + ChangeLog@1.1271 +1 -0 + NTP_4_2_7P357 + + ntpd/invoke-ntp.conf.texi@1.32 +1 -1 + NTP_4_2_7P357 + + ntpd/invoke-ntp.keys.texi@1.32 +1 -1 + NTP_4_2_7P357 + + ntpd/invoke-ntpd.texi@1.348 +2 -2 + NTP_4_2_7P357 + + ntpd/ntp.conf.5man@1.66 +3 -3 + NTP_4_2_7P357 + + ntpd/ntp.conf.5mdoc@1.66 +2 -2 + NTP_4_2_7P357 + + ntpd/ntp.conf.html@1.30 +1 -1 + NTP_4_2_7P357 + + ntpd/ntp.conf.man.in@1.66 +3 -3 + NTP_4_2_7P357 + + ntpd/ntp.conf.mdoc.in@1.66 +2 -2 + NTP_4_2_7P357 + + ntpd/ntp.keys.5man@1.66 +3 -3 + NTP_4_2_7P357 + + ntpd/ntp.keys.5mdoc@1.66 +2 -2 + NTP_4_2_7P357 + + ntpd/ntp.keys.html@1.31 +1 -1 + NTP_4_2_7P357 + + ntpd/ntp.keys.man.in@1.66 +3 -3 + NTP_4_2_7P357 + + ntpd/ntp.keys.mdoc.in@1.66 +2 -2 + NTP_4_2_7P357 + + ntpd/ntpd-opts.c@1.366 +7 -7 + NTP_4_2_7P357 + + ntpd/ntpd-opts.h@1.366 +3 -3 + NTP_4_2_7P357 + + ntpd/ntpd.1ntpdman@1.177 +3 -3 + NTP_4_2_7P357 + + ntpd/ntpd.1ntpdmdoc@1.177 +2 -2 + NTP_4_2_7P357 + + ntpd/ntpd.html@1.25 +12 -18 + NTP_4_2_7P357 + + ntpd/ntpd.man.in@1.177 +3 -3 + NTP_4_2_7P357 + + ntpd/ntpd.mdoc.in@1.177 +2 -2 + NTP_4_2_7P357 + + ntpdc/invoke-ntpdc.texi@1.345 +2 -2 + NTP_4_2_7P357 + + ntpdc/ntpdc-opts.c@1.360 +7 -7 + NTP_4_2_7P357 + + ntpdc/ntpdc-opts.h@1.360 +3 -3 + NTP_4_2_7P357 + + ntpdc/ntpdc.1ntpdcman@1.176 +2 -2 + NTP_4_2_7P357 + + ntpdc/ntpdc.1ntpdcmdoc@1.176 +1 -1 + NTP_4_2_7P357 + + ntpdc/ntpdc.html@1.189 +2 -2 + NTP_4_2_7P357 + + ntpdc/ntpdc.man.in@1.176 +2 -2 + NTP_4_2_7P357 + + ntpdc/ntpdc.mdoc.in@1.176 +1 -1 + NTP_4_2_7P357 + + ntpq/invoke-ntpq.texi@1.349 +2 -2 + NTP_4_2_7P357 + + ntpq/ntpq-opts.c@1.363 +7 -7 + NTP_4_2_7P357 + + ntpq/ntpq-opts.h@1.363 +3 -3 + NTP_4_2_7P357 + + ntpq/ntpq.1ntpqman@1.177 +2 -2 + NTP_4_2_7P357 + + ntpq/ntpq.1ntpqmdoc@1.177 +1 -1 + NTP_4_2_7P357 + + ntpq/ntpq.html@1.22 +13 -16 + NTP_4_2_7P357 + + ntpq/ntpq.man.in@1.177 +2 -2 + NTP_4_2_7P357 + + ntpq/ntpq.mdoc.in@1.177 +1 -1 + NTP_4_2_7P357 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.348 +2 -2 + NTP_4_2_7P357 + + ntpsnmpd/ntpsnmpd-opts.c@1.363 +7 -7 + NTP_4_2_7P357 + + ntpsnmpd/ntpsnmpd-opts.h@1.363 +3 -3 + NTP_4_2_7P357 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.177 +3 -3 + NTP_4_2_7P357 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.177 +2 -2 + NTP_4_2_7P357 + + ntpsnmpd/ntpsnmpd.html@1.20 +1 -1 + NTP_4_2_7P357 + + ntpsnmpd/ntpsnmpd.man.in@1.177 +3 -3 + NTP_4_2_7P357 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.177 +2 -2 + NTP_4_2_7P357 + + packageinfo.sh@1.360 +1 -1 + NTP_4_2_7P357 + + scripts/invoke-ntp-wait.texi@1.165 +2 -2 + NTP_4_2_7P357 + + scripts/ntp-wait.1ntp-waitman@1.176 +3 -3 + NTP_4_2_7P357 + + scripts/ntp-wait.1ntp-waitmdoc@1.176 +3 -3 + NTP_4_2_7P357 + + scripts/ntp-wait.html@1.181 +2 -2 + NTP_4_2_7P357 + + scripts/ntp-wait.man.in@1.176 +3 -3 + NTP_4_2_7P357 + + scripts/ntp-wait.mdoc.in@1.176 +3 -3 + NTP_4_2_7P357 + + sntp/invoke-sntp.texi@1.345 +2 -2 + NTP_4_2_7P357 + + sntp/sntp-opts.c@1.360 +7 -7 + NTP_4_2_7P357 + + sntp/sntp-opts.h@1.360 +3 -3 + NTP_4_2_7P357 + + sntp/sntp.1sntpman@1.180 +3 -3 + NTP_4_2_7P357 + + sntp/sntp.1sntpmdoc@1.180 +2 -2 + NTP_4_2_7P357 + + sntp/sntp.html@1.360 +2 -2 + NTP_4_2_7P357 + + sntp/sntp.man.in@1.180 +3 -3 + NTP_4_2_7P357 + + sntp/sntp.mdoc.in@1.180 +2 -2 + NTP_4_2_7P357 + + util/invoke-ntp-keygen.texi@1.349 +2 -2 + NTP_4_2_7P357 + + util/ntp-keygen-opts.c@1.363 +7 -7 + NTP_4_2_7P357 + + util/ntp-keygen-opts.h@1.363 +3 -3 + NTP_4_2_7P357 + + util/ntp-keygen.1ntp-keygenman@1.177 +3 -3 + NTP_4_2_7P357 + + util/ntp-keygen.1ntp-keygenmdoc@1.177 +2 -2 + NTP_4_2_7P357 + + util/ntp-keygen.html@1.26 +12 -13 + NTP_4_2_7P357 + + util/ntp-keygen.man.in@1.177 +3 -3 + NTP_4_2_7P357 + + util/ntp-keygen.mdoc.in@1.177 +2 -2 + NTP_4_2_7P357 + +ChangeSet@1.2920, 2013-02-21 21:29:59-05:00, stenn@deacon.udel.edu + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/invoke-ntp.conf.texi@1.31 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/invoke-ntp.keys.texi@1.31 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/invoke-ntpd.texi@1.347 +13 -19 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.conf.5man@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.conf.5mdoc@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.conf.man.in@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.conf.mdoc.in@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.keys.5man@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.keys.5mdoc@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.keys.man.in@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntp.keys.mdoc.in@1.65 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpd-opts.c@1.365 +493 -41 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpd-opts.h@1.365 +6 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpd.1ntpdman@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpd.1ntpdmdoc@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpd.man.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpd.mdoc.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpdsim-opts.c@1.21 +780 -312 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpd/ntpdsim-opts.h@1.21 +17 -14 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/invoke-ntpdc.texi@1.344 +16 -22 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/ntpdc-opts.c@1.359 +424 -45 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/ntpdc-opts.h@1.359 +6 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/ntpdc.1ntpdcman@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/ntpdc.1ntpdcmdoc@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/ntpdc.html@1.188 +13 -19 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/ntpdc.man.in@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpdc/ntpdc.mdoc.in@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpq/invoke-ntpq.texi@1.348 +14 -17 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpq/ntpq-opts.c@1.362 +414 -41 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpq/ntpq-opts.h@1.362 +6 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpq/ntpq.1ntpqman@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpq/ntpq.1ntpqmdoc@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpq/ntpq.man.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpq/ntpq.mdoc.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.347 +11 -12 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpsnmpd/ntpsnmpd-opts.c@1.362 +403 -45 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpsnmpd/ntpsnmpd-opts.h@1.362 +6 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpsnmpd/ntpsnmpd.man.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + scripts/invoke-ntp-wait.texi@1.164 +4 -4 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + scripts/ntp-wait.1ntp-waitman@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + scripts/ntp-wait.1ntp-waitmdoc@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + scripts/ntp-wait.html@1.180 +1 -1 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + scripts/ntp-wait.man.in@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + scripts/ntp-wait.mdoc.in@1.175 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/include/autogen-version.def@1.15 +1 -1 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/invoke-sntp.texi@1.344 +16 -19 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/sntp-opts.c@1.359 +449 -45 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/sntp-opts.h@1.359 +6 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/sntp.1sntpman@1.179 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/sntp.1sntpmdoc@1.179 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/sntp.html@1.359 +13 -16 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/sntp.man.in@1.179 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/sntp.mdoc.in@1.179 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + util/invoke-ntp-keygen.texi@1.348 +13 -14 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + util/ntp-keygen-opts.c@1.362 +457 -45 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + util/ntp-keygen-opts.h@1.362 +6 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + util/ntp-keygen.1ntp-keygenman@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + util/ntp-keygen.1ntp-keygenmdoc@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + util/ntp-keygen.man.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + util/ntp-keygen.mdoc.in@1.176 +3 -3 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + +ChangeSet@1.2919, 2013-02-22 01:52:51+00:00, stenn@psp-fb1.ntp.org + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + ChangeLog@1.1270 +1 -0 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/Makefile.am@1.18 +4 -4 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/ag-char-map.h@1.21 +5 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/alias.c@1.5 +49 -39 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/ao-strs.c@1.7 +146 -107 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/ao-strs.h@1.6 +188 -114 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/autoopts.c@1.16 +51 -56 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/autoopts.h@1.14 +69 -32 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/autoopts/options.h@1.20 +507 -335 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/autoopts/project.h@1.5 +4 -4 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/autoopts/usage-txt.h@1.20 +541 -580 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/boolean.c@1.13 +11 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/check.c@1.6 +37 -24 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/compat/compat.h@1.13 +22 -40 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/compat/windows-config.h@1.12 +40 -50 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/configfile.c@1.18 +13 -11 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/cook.c@1.13 +11 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/enum.c@1.8 +26 -35 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/env.c@1.7 +10 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/file.c@1.13 +27 -32 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/find.c@1.7 +27 -38 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/genshell.c@1.21 +450 -99 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/genshell.h@1.21 +15 -16 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/init.c@1.3 +19 -14 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/load.c@1.16 +11 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/m4/libopts.m4@1.24 +9 -19 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/makeshell.c@1.15 +131 -104 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/nested.c@1.12 +13 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/numeric.c@1.12 +34 -25 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/option-value-type.c@1.8 +5 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/option-value-type.h@1.22 +8 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/option-xat-attribute.c@1.8 +5 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/option-xat-attribute.h@1.22 +8 -6 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/pgusage.c@1.13 +10 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/proto.h@1.21 +20 -2 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/putshell.c@1.12 +212 -55 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/reset.c@1.14 +16 -11 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/restore.c@1.11 +12 -16 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/save.c@1.14 +133 -88 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/sort.c@1.12 +10 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/stack.c@1.13 +12 -7 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/streqvcmp.c@1.12 +21 -16 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/text_mmap.c@1.13 +11 -7 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/time.c@1.13 +10 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/tokenize.c@1.10 +13 -5 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/usage.c@1.14 +496 -204 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + + sntp/libopts/version.c@1.14 +78 -69 + Upgrade to autogen-5.17.2pre and libopts-38.0.13 + +ChangeSet@1.2918, 2013-02-19 11:40:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P356 + TAG: NTP_4_2_7P356 + + ChangeLog@1.1269 +1 -0 + NTP_4_2_7P356 + + ntpd/invoke-ntp.conf.texi@1.30 +1 -1 + NTP_4_2_7P356 + + ntpd/invoke-ntp.keys.texi@1.30 +1 -1 + NTP_4_2_7P356 + + ntpd/invoke-ntpd.texi@1.346 +2 -2 + NTP_4_2_7P356 + + ntpd/ntp.conf.5man@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntp.conf.5mdoc@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntp.conf.html@1.29 +1 -1 + NTP_4_2_7P356 + + ntpd/ntp.conf.man.in@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntp.conf.mdoc.in@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntp.keys.5man@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntp.keys.5mdoc@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntp.keys.html@1.30 +1 -1 + NTP_4_2_7P356 + + ntpd/ntp.keys.man.in@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntp.keys.mdoc.in@1.64 +3 -3 + NTP_4_2_7P356 + + ntpd/ntpd-opts.c@1.364 +4 -4 + NTP_4_2_7P356 + + ntpd/ntpd-opts.h@1.364 +3 -3 + NTP_4_2_7P356 + + ntpd/ntpd.1ntpdman@1.175 +3 -3 + NTP_4_2_7P356 + + ntpd/ntpd.1ntpdmdoc@1.175 +3 -3 + NTP_4_2_7P356 + + ntpd/ntpd.html@1.24 +2 -2 + NTP_4_2_7P356 + + ntpd/ntpd.man.in@1.175 +3 -3 + NTP_4_2_7P356 + + ntpd/ntpd.mdoc.in@1.175 +3 -3 + NTP_4_2_7P356 + + ntpdc/invoke-ntpdc.texi@1.343 +2 -2 + NTP_4_2_7P356 + + ntpdc/ntpdc-opts.c@1.358 +4 -4 + NTP_4_2_7P356 + + ntpdc/ntpdc-opts.h@1.358 +3 -3 + NTP_4_2_7P356 + + ntpdc/ntpdc.1ntpdcman@1.174 +2 -2 + NTP_4_2_7P356 + + ntpdc/ntpdc.1ntpdcmdoc@1.174 +2 -2 + NTP_4_2_7P356 + + ntpdc/ntpdc.html@1.187 +2 -2 + NTP_4_2_7P356 + + ntpdc/ntpdc.man.in@1.174 +2 -2 + NTP_4_2_7P356 + + ntpdc/ntpdc.mdoc.in@1.174 +2 -2 + NTP_4_2_7P356 + + ntpq/invoke-ntpq.texi@1.347 +2 -2 + NTP_4_2_7P356 + + ntpq/ntpq-opts.c@1.361 +4 -4 + NTP_4_2_7P356 + + ntpq/ntpq-opts.h@1.361 +3 -3 + NTP_4_2_7P356 + + ntpq/ntpq.1ntpqman@1.175 +2 -2 + NTP_4_2_7P356 + + ntpq/ntpq.1ntpqmdoc@1.175 +2 -2 + NTP_4_2_7P356 + + ntpq/ntpq.html@1.21 +2 -2 + NTP_4_2_7P356 + + ntpq/ntpq.man.in@1.175 +2 -2 + NTP_4_2_7P356 + + ntpq/ntpq.mdoc.in@1.175 +2 -2 + NTP_4_2_7P356 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.346 +2 -2 + NTP_4_2_7P356 + + ntpsnmpd/ntpsnmpd-opts.c@1.361 +4 -4 + NTP_4_2_7P356 + + ntpsnmpd/ntpsnmpd-opts.h@1.361 +3 -3 + NTP_4_2_7P356 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.175 +3 -3 + NTP_4_2_7P356 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.175 +3 -3 + NTP_4_2_7P356 + + ntpsnmpd/ntpsnmpd.html@1.19 +1 -1 + NTP_4_2_7P356 + + ntpsnmpd/ntpsnmpd.man.in@1.175 +3 -3 + NTP_4_2_7P356 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.175 +3 -3 + NTP_4_2_7P356 + + packageinfo.sh@1.359 +1 -1 + NTP_4_2_7P356 + + scripts/invoke-ntp-wait.texi@1.163 +1 -1 + NTP_4_2_7P356 + + scripts/ntp-wait.1ntp-waitman@1.174 +3 -3 + NTP_4_2_7P356 + + scripts/ntp-wait.1ntp-waitmdoc@1.174 +3 -3 + NTP_4_2_7P356 + + scripts/ntp-wait.html@1.179 +1 -1 + NTP_4_2_7P356 + + scripts/ntp-wait.man.in@1.174 +3 -3 + NTP_4_2_7P356 + + scripts/ntp-wait.mdoc.in@1.174 +3 -3 + NTP_4_2_7P356 + + sntp/invoke-sntp.texi@1.343 +2 -2 + NTP_4_2_7P356 + + sntp/sntp-opts.c@1.358 +4 -4 + NTP_4_2_7P356 + + sntp/sntp-opts.h@1.358 +3 -3 + NTP_4_2_7P356 + + sntp/sntp.1sntpman@1.178 +3 -3 + NTP_4_2_7P356 + + sntp/sntp.1sntpmdoc@1.178 +3 -3 + NTP_4_2_7P356 + + sntp/sntp.html@1.358 +2 -2 + NTP_4_2_7P356 + + sntp/sntp.man.in@1.178 +3 -3 + NTP_4_2_7P356 + + sntp/sntp.mdoc.in@1.178 +3 -3 + NTP_4_2_7P356 + + util/invoke-ntp-keygen.texi@1.347 +2 -2 + NTP_4_2_7P356 + + util/ntp-keygen-opts.c@1.361 +4 -4 + NTP_4_2_7P356 + + util/ntp-keygen-opts.h@1.361 +3 -3 + NTP_4_2_7P356 + + util/ntp-keygen.1ntp-keygenman@1.175 +3 -3 + NTP_4_2_7P356 + + util/ntp-keygen.1ntp-keygenmdoc@1.175 +3 -3 + NTP_4_2_7P356 + + util/ntp-keygen.html@1.25 +2 -2 + NTP_4_2_7P356 + + util/ntp-keygen.man.in@1.175 +3 -3 + NTP_4_2_7P356 + + util/ntp-keygen.mdoc.in@1.175 +3 -3 + NTP_4_2_7P356 + +ChangeSet@1.2917, 2013-02-18 22:58:22-08:00, harlan@hms-mbp11.local + Added loc/debian + + ChangeLog@1.1268 +1 -0 + Added loc/debian + + sntp/loc/debian@1.1 +15 -0 + BitKeeper file /Users/harlan/src/ntp-dev/sntp/loc/debian + + sntp/loc/debian@1.0 +0 -0 + +ChangeSet@1.2916, 2013-02-18 09:26:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P355 + TAG: NTP_4_2_7P355 + + ChangeLog@1.1267 +1 -0 + NTP_4_2_7P355 + + ntpd/invoke-ntp.conf.texi@1.29 +1 -1 + NTP_4_2_7P355 + + ntpd/invoke-ntp.keys.texi@1.29 +1 -1 + NTP_4_2_7P355 + + ntpd/invoke-ntpd.texi@1.345 +2 -2 + NTP_4_2_7P355 + + ntpd/ntp.conf.5man@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntp.conf.5mdoc@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntp.conf.html@1.28 +1 -1 + NTP_4_2_7P355 + + ntpd/ntp.conf.man.in@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntp.conf.mdoc.in@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntp.keys.5man@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntp.keys.5mdoc@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntp.keys.html@1.29 +1 -1 + NTP_4_2_7P355 + + ntpd/ntp.keys.man.in@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntp.keys.mdoc.in@1.63 +3 -3 + NTP_4_2_7P355 + + ntpd/ntpd-opts.c@1.363 +4 -4 + NTP_4_2_7P355 + + ntpd/ntpd-opts.h@1.363 +3 -3 + NTP_4_2_7P355 + + ntpd/ntpd.1ntpdman@1.174 +3 -3 + NTP_4_2_7P355 + + ntpd/ntpd.1ntpdmdoc@1.174 +3 -3 + NTP_4_2_7P355 + + ntpd/ntpd.html@1.23 +2 -2 + NTP_4_2_7P355 + + ntpd/ntpd.man.in@1.174 +3 -3 + NTP_4_2_7P355 + + ntpd/ntpd.mdoc.in@1.174 +3 -3 + NTP_4_2_7P355 + + ntpdc/invoke-ntpdc.texi@1.342 +2 -2 + NTP_4_2_7P355 + + ntpdc/ntpdc-opts.c@1.357 +4 -4 + NTP_4_2_7P355 + + ntpdc/ntpdc-opts.h@1.357 +3 -3 + NTP_4_2_7P355 + + ntpdc/ntpdc.1ntpdcman@1.173 +2 -2 + NTP_4_2_7P355 + + ntpdc/ntpdc.1ntpdcmdoc@1.173 +2 -2 + NTP_4_2_7P355 + + ntpdc/ntpdc.html@1.186 +2 -2 + NTP_4_2_7P355 + + ntpdc/ntpdc.man.in@1.173 +2 -2 + NTP_4_2_7P355 + + ntpdc/ntpdc.mdoc.in@1.173 +2 -2 + NTP_4_2_7P355 + + ntpq/invoke-ntpq.texi@1.346 +2 -2 + NTP_4_2_7P355 + + ntpq/ntpq-opts.c@1.360 +4 -4 + NTP_4_2_7P355 + + ntpq/ntpq-opts.h@1.360 +3 -3 + NTP_4_2_7P355 + + ntpq/ntpq.1ntpqman@1.174 +2 -2 + NTP_4_2_7P355 + + ntpq/ntpq.1ntpqmdoc@1.174 +2 -2 + NTP_4_2_7P355 + + ntpq/ntpq.html@1.20 +2 -2 + NTP_4_2_7P355 + + ntpq/ntpq.man.in@1.174 +2 -2 + NTP_4_2_7P355 + + ntpq/ntpq.mdoc.in@1.174 +2 -2 + NTP_4_2_7P355 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.345 +2 -2 + NTP_4_2_7P355 + + ntpsnmpd/ntpsnmpd-opts.c@1.360 +4 -4 + NTP_4_2_7P355 + + ntpsnmpd/ntpsnmpd-opts.h@1.360 +3 -3 + NTP_4_2_7P355 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.174 +3 -3 + NTP_4_2_7P355 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.174 +3 -3 + NTP_4_2_7P355 + + ntpsnmpd/ntpsnmpd.html@1.18 +1 -1 + NTP_4_2_7P355 + + ntpsnmpd/ntpsnmpd.man.in@1.174 +3 -3 + NTP_4_2_7P355 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.174 +3 -3 + NTP_4_2_7P355 + + packageinfo.sh@1.358 +1 -1 + NTP_4_2_7P355 + + scripts/invoke-ntp-wait.texi@1.162 +1 -1 + NTP_4_2_7P355 + + scripts/ntp-wait.1ntp-waitman@1.173 +3 -3 + NTP_4_2_7P355 + + scripts/ntp-wait.1ntp-waitmdoc@1.173 +3 -3 + NTP_4_2_7P355 + + scripts/ntp-wait.html@1.178 +1 -1 + NTP_4_2_7P355 + + scripts/ntp-wait.man.in@1.173 +3 -3 + NTP_4_2_7P355 + + scripts/ntp-wait.mdoc.in@1.173 +3 -3 + NTP_4_2_7P355 + + sntp/invoke-sntp.texi@1.342 +2 -2 + NTP_4_2_7P355 + + sntp/sntp-opts.c@1.357 +4 -4 + NTP_4_2_7P355 + + sntp/sntp-opts.h@1.357 +3 -3 + NTP_4_2_7P355 + + sntp/sntp.1sntpman@1.177 +3 -3 + NTP_4_2_7P355 + + sntp/sntp.1sntpmdoc@1.177 +3 -3 + NTP_4_2_7P355 + + sntp/sntp.html@1.357 +2 -2 + NTP_4_2_7P355 + + sntp/sntp.man.in@1.177 +3 -3 + NTP_4_2_7P355 + + sntp/sntp.mdoc.in@1.177 +3 -3 + NTP_4_2_7P355 + + util/invoke-ntp-keygen.texi@1.346 +2 -2 + NTP_4_2_7P355 + + util/ntp-keygen-opts.c@1.360 +4 -4 + NTP_4_2_7P355 + + util/ntp-keygen-opts.h@1.360 +3 -3 + NTP_4_2_7P355 + + util/ntp-keygen.1ntp-keygenman@1.174 +3 -3 + NTP_4_2_7P355 + + util/ntp-keygen.1ntp-keygenmdoc@1.174 +3 -3 + NTP_4_2_7P355 + + util/ntp-keygen.html@1.24 +2 -2 + NTP_4_2_7P355 + + util/ntp-keygen.man.in@1.174 +3 -3 + NTP_4_2_7P355 + + util/ntp-keygen.mdoc.in@1.174 +3 -3 + NTP_4_2_7P355 + +ChangeSet@1.2915, 2013-02-18 04:01:05-05:00, stenn@deacon.udel.edu + CID 739711: Ignore return status of remove() in ntp-keygen.c + + ChangeLog@1.1266 +1 -0 + CID 739711: Ignore return status of remove() in ntp-keygen.c + + util/ntp-keygen.c@1.95 +1 -1 + CID 739711: Ignore return status of remove() in ntp-keygen.c + +ChangeSet@1.2914, 2013-02-18 03:28:57-05:00, stenn@deacon.udel.edu + CID 739710: Check return status of mkdir() in sntp/kod_management.c + + ChangeLog@1.1265 +1 -0 + CID 739710: Check return status of mkdir() in sntp/kod_management.c + + sntp/kod_management.c@1.30 +5 -1 + CID 739710: Check return status of mkdir() in sntp/kod_management.c + +ChangeSet@1.2913, 2013-02-18 03:18:18-05:00, stenn@deacon.udel.edu + CID 739709: Check return status of fcntl() in refclock_datum.c + + ChangeLog@1.1264 +1 -0 + CID 739709: Check return status of fcntl() in refclock_datum.c + + ntpd/refclock_datum.c@1.21 +3 -1 + CID 739709: Check return status of fcntl() in refclock_datum.c + +ChangeSet@1.2912, 2013-02-18 03:10:44-05:00, stenn@deacon.udel.edu + CID 739708: Check return status of fcntl() in refclock_arc.c + + ChangeLog@1.1263 +1 -0 + CID 739708: Check return status of fcntl() in refclock_arc.c + + ntpd/refclock_arc.c@1.30 +4 -1 + CID 739708: Check return status of fcntl() in refclock_arc.c + +ChangeSet@1.2911, 2013-02-18 03:05:01-05:00, stenn@deacon.udel.edu + CID 739723: Print sizeof as unsigned + + ChangeLog@1.1262 +1 -0 + CID 739723: Print sizeof as unsigned + + sntp/main.c@1.88 +1 -1 + CID 739723: Print sizeof as unsigned + +ChangeSet@1.2910, 2013-02-18 01:09:24-05:00, stenn@deacon.udel.edu + CID 971094: Clean up time of check/time of use in check_leap_file() + + ChangeLog@1.1261 +1 -0 + CID 971094: Clean up time of check/time of use in check_leap_file() + + ntpd/ntp_util.c@1.102 +13 -13 + CID 971094: Clean up time of check/time of use in check_leap_file() + +ChangeSet@1.2909, 2013-02-10 11:50:16+00:00, stenn@deacon.udel.edu + NTP_4_2_7P354 + TAG: NTP_4_2_7P354 + + ChangeLog@1.1260 +1 -0 + NTP_4_2_7P354 + + ntpd/invoke-ntp.conf.texi@1.28 +1 -1 + NTP_4_2_7P354 + + ntpd/invoke-ntp.keys.texi@1.28 +1 -1 + NTP_4_2_7P354 + + ntpd/invoke-ntpd.texi@1.344 +2 -2 + NTP_4_2_7P354 + + ntpd/ntp.conf.5man@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntp.conf.5mdoc@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntp.conf.html@1.27 +1 -1 + NTP_4_2_7P354 + + ntpd/ntp.conf.man.in@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntp.conf.mdoc.in@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntp.keys.5man@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntp.keys.5mdoc@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntp.keys.html@1.28 +1 -1 + NTP_4_2_7P354 + + ntpd/ntp.keys.man.in@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntp.keys.mdoc.in@1.62 +3 -3 + NTP_4_2_7P354 + + ntpd/ntpd-opts.c@1.362 +4 -4 + NTP_4_2_7P354 + + ntpd/ntpd-opts.h@1.362 +3 -3 + NTP_4_2_7P354 + + ntpd/ntpd.1ntpdman@1.173 +3 -3 + NTP_4_2_7P354 + + ntpd/ntpd.1ntpdmdoc@1.173 +3 -3 + NTP_4_2_7P354 + + ntpd/ntpd.html@1.22 +2 -2 + NTP_4_2_7P354 + + ntpd/ntpd.man.in@1.173 +3 -3 + NTP_4_2_7P354 + + ntpd/ntpd.mdoc.in@1.173 +3 -3 + NTP_4_2_7P354 + + ntpdc/invoke-ntpdc.texi@1.341 +2 -2 + NTP_4_2_7P354 + + ntpdc/ntpdc-opts.c@1.356 +4 -4 + NTP_4_2_7P354 + + ntpdc/ntpdc-opts.h@1.356 +3 -3 + NTP_4_2_7P354 + + ntpdc/ntpdc.1ntpdcman@1.172 +2 -2 + NTP_4_2_7P354 + + ntpdc/ntpdc.1ntpdcmdoc@1.172 +2 -2 + NTP_4_2_7P354 + + ntpdc/ntpdc.html@1.185 +2 -2 + NTP_4_2_7P354 + + ntpdc/ntpdc.man.in@1.172 +2 -2 + NTP_4_2_7P354 + + ntpdc/ntpdc.mdoc.in@1.172 +2 -2 + NTP_4_2_7P354 + + ntpq/invoke-ntpq.texi@1.345 +2 -2 + NTP_4_2_7P354 + + ntpq/ntpq-opts.c@1.359 +4 -4 + NTP_4_2_7P354 + + ntpq/ntpq-opts.h@1.359 +3 -3 + NTP_4_2_7P354 + + ntpq/ntpq.1ntpqman@1.173 +2 -2 + NTP_4_2_7P354 + + ntpq/ntpq.1ntpqmdoc@1.173 +2 -2 + NTP_4_2_7P354 + + ntpq/ntpq.html@1.19 +2 -2 + NTP_4_2_7P354 + + ntpq/ntpq.man.in@1.173 +2 -2 + NTP_4_2_7P354 + + ntpq/ntpq.mdoc.in@1.173 +2 -2 + NTP_4_2_7P354 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.344 +2 -2 + NTP_4_2_7P354 + + ntpsnmpd/ntpsnmpd-opts.c@1.359 +4 -4 + NTP_4_2_7P354 + + ntpsnmpd/ntpsnmpd-opts.h@1.359 +3 -3 + NTP_4_2_7P354 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.173 +3 -3 + NTP_4_2_7P354 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.173 +3 -3 + NTP_4_2_7P354 + + ntpsnmpd/ntpsnmpd.html@1.17 +1 -1 + NTP_4_2_7P354 + + ntpsnmpd/ntpsnmpd.man.in@1.173 +3 -3 + NTP_4_2_7P354 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.173 +3 -3 + NTP_4_2_7P354 + + packageinfo.sh@1.357 +1 -1 + NTP_4_2_7P354 + + scripts/invoke-ntp-wait.texi@1.161 +1 -1 + NTP_4_2_7P354 + + scripts/ntp-wait.1ntp-waitman@1.172 +3 -3 + NTP_4_2_7P354 + + scripts/ntp-wait.1ntp-waitmdoc@1.172 +3 -3 + NTP_4_2_7P354 + + scripts/ntp-wait.html@1.177 +1 -1 + NTP_4_2_7P354 + + scripts/ntp-wait.man.in@1.172 +3 -3 + NTP_4_2_7P354 + + scripts/ntp-wait.mdoc.in@1.172 +3 -3 + NTP_4_2_7P354 + + sntp/invoke-sntp.texi@1.341 +2 -2 + NTP_4_2_7P354 + + sntp/sntp-opts.c@1.356 +4 -4 + NTP_4_2_7P354 + + sntp/sntp-opts.h@1.356 +3 -3 + NTP_4_2_7P354 + + sntp/sntp.1sntpman@1.176 +3 -3 + NTP_4_2_7P354 + + sntp/sntp.1sntpmdoc@1.176 +3 -3 + NTP_4_2_7P354 + + sntp/sntp.html@1.356 +2 -2 + NTP_4_2_7P354 + + sntp/sntp.man.in@1.176 +3 -3 + NTP_4_2_7P354 + + sntp/sntp.mdoc.in@1.176 +3 -3 + NTP_4_2_7P354 + + util/invoke-ntp-keygen.texi@1.345 +2 -2 + NTP_4_2_7P354 + + util/ntp-keygen-opts.c@1.359 +4 -4 + NTP_4_2_7P354 + + util/ntp-keygen-opts.h@1.359 +3 -3 + NTP_4_2_7P354 + + util/ntp-keygen.1ntp-keygenman@1.173 +3 -3 + NTP_4_2_7P354 + + util/ntp-keygen.1ntp-keygenmdoc@1.173 +3 -3 + NTP_4_2_7P354 + + util/ntp-keygen.html@1.23 +2 -2 + NTP_4_2_7P354 + + util/ntp-keygen.man.in@1.173 +3 -3 + NTP_4_2_7P354 + + util/ntp-keygen.mdoc.in@1.173 +3 -3 + NTP_4_2_7P354 + +ChangeSet@1.2908, 2013-02-09 20:25:46-05:00, stenn@deacon.udel.edu + CID 739714: Fix code indentation level + + ChangeLog@1.1259 +1 -0 + CID 739714: Fix code indentation level + + ntpd/refclock_irig.c@1.36 +2 -2 + CID 739714: Fix code indentation level + +ChangeSet@1.2907, 2013-02-09 19:55:02-05:00, stenn@deacon.udel.edu + CID 739715: Clean up sockaddr_dump() + + ChangeLog@1.1258 +1 -0 + CID 739715: Clean up sockaddr_dump() + + ntpd/ntp_io.c@1.376 +2 -1 + CID 739715: Clean up sockaddr_dump() + +ChangeSet@1.2906, 2013-02-09 19:05:32-05:00, stenn@deacon.udel.edu + CID 97194: Check return from setsockopt() + + ChangeLog@1.1257 +1 -0 + CID 97194: Check return from setsockopt() + + ntpd/ntp_io.c@1.375 +7 -2 + CID 97194: Check return from setsockopt() + +ChangeSet@1.2905, 2013-02-09 18:28:45-05:00, stenn@deacon.udel.edu + CID 739713: devmask/recmask copy/paste error + + ChangeLog@1.1256 +1 -0 + CID 739713: devmask/recmask copy/paste error + + libntp/audio.c@1.33 +2 -1 + CID 739713: devmask/recmask copy/paste error + +ChangeSet@1.2904, 2013-02-09 18:17:48-05:00, stenn@deacon.udel.edu + CID 739559: Double close + + ChangeLog@1.1255 +2 -1 + CID 739559: Double close + + lib/isc/unix/net.c@1.18 +0 -1 + CID 739559: Double close + +ChangeSet@1.2903, 2013-02-09 18:14:26-05:00, stenn@deacon.udel.edu + CID 739558: Double close + + ChangeLog@1.1254 +1 -0 + CID 739558: Double close + + lib/isc/unix/net.c@1.17 +0 -2 + CID 739558: Double close + +ChangeSet@1.2902, 2013-02-09 18:05:03-05:00, stenn@deacon.udel.edu + CID 739473,739532: Out-of-bounds access/illegal address computation + + ChangeLog@1.1253 +1 -0 + CID 739473,739532: Out-of-bounds access/illegal address computation + + lib/isc/sockaddr.c@1.11 +1 -1 + CID 739473,739532: Out-of-bounds access/illegal address computation + +ChangeSet@1.2901, 2013-02-09 11:31:13+00:00, stenn@deacon.udel.edu + NTP_4_2_7P353 + TAG: NTP_4_2_7P353 + + ChangeLog@1.1252 +1 -0 + NTP_4_2_7P353 + + ntpd/invoke-ntp.conf.texi@1.27 +1 -1 + NTP_4_2_7P353 + + ntpd/invoke-ntp.keys.texi@1.27 +1 -1 + NTP_4_2_7P353 + + ntpd/invoke-ntpd.texi@1.343 +2 -2 + NTP_4_2_7P353 + + ntpd/ntp.conf.5man@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntp.conf.5mdoc@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntp.conf.html@1.26 +1 -1 + NTP_4_2_7P353 + + ntpd/ntp.conf.man.in@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntp.conf.mdoc.in@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntp.keys.5man@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntp.keys.5mdoc@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntp.keys.html@1.27 +1 -1 + NTP_4_2_7P353 + + ntpd/ntp.keys.man.in@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntp.keys.mdoc.in@1.61 +3 -3 + NTP_4_2_7P353 + + ntpd/ntpd-opts.c@1.361 +4 -4 + NTP_4_2_7P353 + + ntpd/ntpd-opts.h@1.361 +3 -3 + NTP_4_2_7P353 + + ntpd/ntpd.1ntpdman@1.172 +3 -3 + NTP_4_2_7P353 + + ntpd/ntpd.1ntpdmdoc@1.172 +3 -3 + NTP_4_2_7P353 + + ntpd/ntpd.html@1.21 +2 -2 + NTP_4_2_7P353 + + ntpd/ntpd.man.in@1.172 +3 -3 + NTP_4_2_7P353 + + ntpd/ntpd.mdoc.in@1.172 +3 -3 + NTP_4_2_7P353 + + ntpdc/invoke-ntpdc.texi@1.340 +2 -2 + NTP_4_2_7P353 + + ntpdc/ntpdc-opts.c@1.355 +4 -4 + NTP_4_2_7P353 + + ntpdc/ntpdc-opts.h@1.355 +3 -3 + NTP_4_2_7P353 + + ntpdc/ntpdc.1ntpdcman@1.171 +2 -2 + NTP_4_2_7P353 + + ntpdc/ntpdc.1ntpdcmdoc@1.171 +2 -2 + NTP_4_2_7P353 + + ntpdc/ntpdc.html@1.184 +2 -2 + NTP_4_2_7P353 + + ntpdc/ntpdc.man.in@1.171 +2 -2 + NTP_4_2_7P353 + + ntpdc/ntpdc.mdoc.in@1.171 +2 -2 + NTP_4_2_7P353 + + ntpq/invoke-ntpq.texi@1.344 +2 -2 + NTP_4_2_7P353 + + ntpq/ntpq-opts.c@1.358 +4 -4 + NTP_4_2_7P353 + + ntpq/ntpq-opts.h@1.358 +3 -3 + NTP_4_2_7P353 + + ntpq/ntpq.1ntpqman@1.172 +2 -2 + NTP_4_2_7P353 + + ntpq/ntpq.1ntpqmdoc@1.172 +2 -2 + NTP_4_2_7P353 + + ntpq/ntpq.html@1.18 +2 -2 + NTP_4_2_7P353 + + ntpq/ntpq.man.in@1.172 +2 -2 + NTP_4_2_7P353 + + ntpq/ntpq.mdoc.in@1.172 +2 -2 + NTP_4_2_7P353 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.343 +2 -2 + NTP_4_2_7P353 + + ntpsnmpd/ntpsnmpd-opts.c@1.358 +4 -4 + NTP_4_2_7P353 + + ntpsnmpd/ntpsnmpd-opts.h@1.358 +3 -3 + NTP_4_2_7P353 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.172 +3 -3 + NTP_4_2_7P353 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.172 +3 -3 + NTP_4_2_7P353 + + ntpsnmpd/ntpsnmpd.html@1.16 +1 -1 + NTP_4_2_7P353 + + ntpsnmpd/ntpsnmpd.man.in@1.172 +3 -3 + NTP_4_2_7P353 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.172 +3 -3 + NTP_4_2_7P353 + + packageinfo.sh@1.356 +1 -1 + NTP_4_2_7P353 + + scripts/invoke-ntp-wait.texi@1.160 +1 -1 + NTP_4_2_7P353 + + scripts/ntp-wait.1ntp-waitman@1.171 +3 -3 + NTP_4_2_7P353 + + scripts/ntp-wait.1ntp-waitmdoc@1.171 +3 -3 + NTP_4_2_7P353 + + scripts/ntp-wait.html@1.176 +1 -1 + NTP_4_2_7P353 + + scripts/ntp-wait.man.in@1.171 +3 -3 + NTP_4_2_7P353 + + scripts/ntp-wait.mdoc.in@1.171 +3 -3 + NTP_4_2_7P353 + + sntp/invoke-sntp.texi@1.340 +2 -2 + NTP_4_2_7P353 + + sntp/sntp-opts.c@1.355 +4 -4 + NTP_4_2_7P353 + + sntp/sntp-opts.h@1.355 +3 -3 + NTP_4_2_7P353 + + sntp/sntp.1sntpman@1.175 +3 -3 + NTP_4_2_7P353 + + sntp/sntp.1sntpmdoc@1.175 +3 -3 + NTP_4_2_7P353 + + sntp/sntp.html@1.355 +2 -2 + NTP_4_2_7P353 + + sntp/sntp.man.in@1.175 +3 -3 + NTP_4_2_7P353 + + sntp/sntp.mdoc.in@1.175 +3 -3 + NTP_4_2_7P353 + + util/invoke-ntp-keygen.texi@1.344 +2 -2 + NTP_4_2_7P353 + + util/ntp-keygen-opts.c@1.358 +4 -4 + NTP_4_2_7P353 + + util/ntp-keygen-opts.h@1.358 +3 -3 + NTP_4_2_7P353 + + util/ntp-keygen.1ntp-keygenman@1.172 +3 -3 + NTP_4_2_7P353 + + util/ntp-keygen.1ntp-keygenmdoc@1.172 +3 -3 + NTP_4_2_7P353 + + util/ntp-keygen.html@1.22 +2 -2 + NTP_4_2_7P353 + + util/ntp-keygen.man.in@1.172 +3 -3 + NTP_4_2_7P353 + + util/ntp-keygen.mdoc.in@1.172 +3 -3 + NTP_4_2_7P353 + +ChangeSet@1.2900, 2013-02-08 23:15:13-08:00, harlan@hms-mbp11.lan + [Bug 2326] Check hourly for a new leapfile if the old one expired + + ChangeLog@1.1251 +1 -0 + [Bug 2326] Check hourly for a new leapfile if the old one expired + + ntpd/ntp_timer.c@1.71 +7 -0 + [Bug 2326] Check hourly for a new leapfile if the old one expired + + ntpd/ntp_util.c@1.101 +1 -1 + [Bug 2326] Check hourly for a new leapfile if the old one expired + +ChangeSet@1.2899, 2013-01-28 02:57:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P352 + TAG: NTP_4_2_7P352 + + ChangeLog@1.1250 +1 -0 + NTP_4_2_7P352 + + ntpd/invoke-ntp.conf.texi@1.26 +1 -1 + NTP_4_2_7P352 + + ntpd/invoke-ntp.keys.texi@1.26 +1 -1 + NTP_4_2_7P352 + + ntpd/invoke-ntpd.texi@1.342 +2 -2 + NTP_4_2_7P352 + + ntpd/ntp.conf.5man@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntp.conf.5mdoc@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntp.conf.html@1.25 +1 -1 + NTP_4_2_7P352 + + ntpd/ntp.conf.man.in@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntp.conf.mdoc.in@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntp.keys.5man@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntp.keys.5mdoc@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntp.keys.html@1.26 +1 -1 + NTP_4_2_7P352 + + ntpd/ntp.keys.man.in@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntp.keys.mdoc.in@1.60 +3 -3 + NTP_4_2_7P352 + + ntpd/ntpd-opts.c@1.360 +4 -4 + NTP_4_2_7P352 + + ntpd/ntpd-opts.h@1.360 +3 -3 + NTP_4_2_7P352 + + ntpd/ntpd.1ntpdman@1.171 +3 -3 + NTP_4_2_7P352 + + ntpd/ntpd.1ntpdmdoc@1.171 +3 -3 + NTP_4_2_7P352 + + ntpd/ntpd.html@1.20 +2 -2 + NTP_4_2_7P352 + + ntpd/ntpd.man.in@1.171 +3 -3 + NTP_4_2_7P352 + + ntpd/ntpd.mdoc.in@1.171 +3 -3 + NTP_4_2_7P352 + + ntpdc/invoke-ntpdc.texi@1.339 +2 -2 + NTP_4_2_7P352 + + ntpdc/ntpdc-opts.c@1.354 +4 -4 + NTP_4_2_7P352 + + ntpdc/ntpdc-opts.h@1.354 +3 -3 + NTP_4_2_7P352 + + ntpdc/ntpdc.1ntpdcman@1.170 +2 -2 + NTP_4_2_7P352 + + ntpdc/ntpdc.1ntpdcmdoc@1.170 +2 -2 + NTP_4_2_7P352 + + ntpdc/ntpdc.html@1.183 +2 -2 + NTP_4_2_7P352 + + ntpdc/ntpdc.man.in@1.170 +2 -2 + NTP_4_2_7P352 + + ntpdc/ntpdc.mdoc.in@1.170 +2 -2 + NTP_4_2_7P352 + + ntpq/invoke-ntpq.texi@1.343 +2 -2 + NTP_4_2_7P352 + + ntpq/ntpq-opts.c@1.357 +4 -4 + NTP_4_2_7P352 + + ntpq/ntpq-opts.h@1.357 +3 -3 + NTP_4_2_7P352 + + ntpq/ntpq.1ntpqman@1.171 +2 -2 + NTP_4_2_7P352 + + ntpq/ntpq.1ntpqmdoc@1.171 +2 -2 + NTP_4_2_7P352 + + ntpq/ntpq.html@1.17 +2 -2 + NTP_4_2_7P352 + + ntpq/ntpq.man.in@1.171 +2 -2 + NTP_4_2_7P352 + + ntpq/ntpq.mdoc.in@1.171 +2 -2 + NTP_4_2_7P352 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.342 +2 -2 + NTP_4_2_7P352 + + ntpsnmpd/ntpsnmpd-opts.c@1.357 +4 -4 + NTP_4_2_7P352 + + ntpsnmpd/ntpsnmpd-opts.h@1.357 +3 -3 + NTP_4_2_7P352 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.171 +3 -3 + NTP_4_2_7P352 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.171 +3 -3 + NTP_4_2_7P352 + + ntpsnmpd/ntpsnmpd.html@1.15 +1 -1 + NTP_4_2_7P352 + + ntpsnmpd/ntpsnmpd.man.in@1.171 +3 -3 + NTP_4_2_7P352 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.171 +3 -3 + NTP_4_2_7P352 + + packageinfo.sh@1.355 +1 -1 + NTP_4_2_7P352 + + scripts/invoke-ntp-wait.texi@1.159 +1 -1 + NTP_4_2_7P352 + + scripts/ntp-wait.1ntp-waitman@1.170 +3 -3 + NTP_4_2_7P352 + + scripts/ntp-wait.1ntp-waitmdoc@1.170 +3 -3 + NTP_4_2_7P352 + + scripts/ntp-wait.html@1.175 +1 -1 + NTP_4_2_7P352 + + scripts/ntp-wait.man.in@1.170 +3 -3 + NTP_4_2_7P352 + + scripts/ntp-wait.mdoc.in@1.170 +3 -3 + NTP_4_2_7P352 + + sntp/invoke-sntp.texi@1.339 +2 -2 + NTP_4_2_7P352 + + sntp/sntp-opts.c@1.354 +4 -4 + NTP_4_2_7P352 + + sntp/sntp-opts.h@1.354 +3 -3 + NTP_4_2_7P352 + + sntp/sntp.1sntpman@1.174 +3 -3 + NTP_4_2_7P352 + + sntp/sntp.1sntpmdoc@1.174 +3 -3 + NTP_4_2_7P352 + + sntp/sntp.html@1.354 +2 -2 + NTP_4_2_7P352 + + sntp/sntp.man.in@1.174 +3 -3 + NTP_4_2_7P352 + + sntp/sntp.mdoc.in@1.174 +3 -3 + NTP_4_2_7P352 + + util/invoke-ntp-keygen.texi@1.343 +2 -2 + NTP_4_2_7P352 + + util/ntp-keygen-opts.c@1.357 +4 -4 + NTP_4_2_7P352 + + util/ntp-keygen-opts.h@1.357 +3 -3 + NTP_4_2_7P352 + + util/ntp-keygen.1ntp-keygenman@1.171 +3 -3 + NTP_4_2_7P352 + + util/ntp-keygen.1ntp-keygenmdoc@1.171 +3 -3 + NTP_4_2_7P352 + + util/ntp-keygen.html@1.21 +2 -2 + NTP_4_2_7P352 + + util/ntp-keygen.man.in@1.171 +3 -3 + NTP_4_2_7P352 + + util/ntp-keygen.mdoc.in@1.171 +3 -3 + NTP_4_2_7P352 + +ChangeSet@1.2898, 2013-01-28 00:44:57+00:00, stenn@psp-fb1.ntp.org + [Bug 2326] Notice when a new leapfile has been installed + + html/miscopt.html@1.72 +1 -0 + [Bug 2326] Notice when a new leapfile has been installed + +ChangeSet@1.2897, 2013-01-28 00:20:35+00:00, stenn@psp-fb1.ntp.org + [Bug 2326] Notice when a new leapfile has been installed + + ChangeLog@1.1249 +1 -0 + [Bug 2326] Notice when a new leapfile has been installed + + include/ntpd.h@1.173 +1 -0 + [Bug 2326] Notice when a new leapfile has been installed + + ntpd/ntp_config.c@1.311 +1 -1 + [Bug 2326] Notice when a new leapfile has been installed + + ntpd/ntp_io.c@1.374 +15 -5 + [Bug 2326] Notice when a new leapfile has been installed + + ntpd/ntp_util.c@1.100 +60 -5 + [Bug 2326] Notice when a new leapfile has been installed + +ChangeSet@1.2896, 2013-01-24 11:39:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P351 + TAG: NTP_4_2_7P351 + + ChangeLog@1.1248 +1 -0 + NTP_4_2_7P351 + + ntpd/invoke-ntp.conf.texi@1.25 +1 -1 + NTP_4_2_7P351 + + ntpd/invoke-ntp.keys.texi@1.25 +1 -1 + NTP_4_2_7P351 + + ntpd/invoke-ntpd.texi@1.341 +2 -2 + NTP_4_2_7P351 + + ntpd/ntp.conf.5man@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntp.conf.5mdoc@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntp.conf.html@1.24 +1 -1 + NTP_4_2_7P351 + + ntpd/ntp.conf.man.in@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntp.conf.mdoc.in@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntp.keys.5man@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntp.keys.5mdoc@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntp.keys.html@1.25 +1 -1 + NTP_4_2_7P351 + + ntpd/ntp.keys.man.in@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntp.keys.mdoc.in@1.59 +3 -3 + NTP_4_2_7P351 + + ntpd/ntpd-opts.c@1.359 +4 -4 + NTP_4_2_7P351 + + ntpd/ntpd-opts.h@1.359 +3 -3 + NTP_4_2_7P351 + + ntpd/ntpd.1ntpdman@1.170 +3 -3 + NTP_4_2_7P351 + + ntpd/ntpd.1ntpdmdoc@1.170 +3 -3 + NTP_4_2_7P351 + + ntpd/ntpd.html@1.19 +2 -2 + NTP_4_2_7P351 + + ntpd/ntpd.man.in@1.170 +3 -3 + NTP_4_2_7P351 + + ntpd/ntpd.mdoc.in@1.170 +3 -3 + NTP_4_2_7P351 + + ntpdc/invoke-ntpdc.texi@1.338 +2 -2 + NTP_4_2_7P351 + + ntpdc/ntpdc-opts.c@1.353 +4 -4 + NTP_4_2_7P351 + + ntpdc/ntpdc-opts.h@1.353 +3 -3 + NTP_4_2_7P351 + + ntpdc/ntpdc.1ntpdcman@1.169 +2 -2 + NTP_4_2_7P351 + + ntpdc/ntpdc.1ntpdcmdoc@1.169 +2 -2 + NTP_4_2_7P351 + + ntpdc/ntpdc.html@1.182 +2 -2 + NTP_4_2_7P351 + + ntpdc/ntpdc.man.in@1.169 +2 -2 + NTP_4_2_7P351 + + ntpdc/ntpdc.mdoc.in@1.169 +2 -2 + NTP_4_2_7P351 + + ntpq/invoke-ntpq.texi@1.342 +2 -2 + NTP_4_2_7P351 + + ntpq/ntpq-opts.c@1.356 +4 -4 + NTP_4_2_7P351 + + ntpq/ntpq-opts.h@1.356 +3 -3 + NTP_4_2_7P351 + + ntpq/ntpq.1ntpqman@1.170 +2 -2 + NTP_4_2_7P351 + + ntpq/ntpq.1ntpqmdoc@1.170 +2 -2 + NTP_4_2_7P351 + + ntpq/ntpq.html@1.16 +2 -2 + NTP_4_2_7P351 + + ntpq/ntpq.man.in@1.170 +2 -2 + NTP_4_2_7P351 + + ntpq/ntpq.mdoc.in@1.170 +2 -2 + NTP_4_2_7P351 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.341 +2 -2 + NTP_4_2_7P351 + + ntpsnmpd/ntpsnmpd-opts.c@1.356 +4 -4 + NTP_4_2_7P351 + + ntpsnmpd/ntpsnmpd-opts.h@1.356 +3 -3 + NTP_4_2_7P351 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.170 +3 -3 + NTP_4_2_7P351 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.170 +3 -3 + NTP_4_2_7P351 + + ntpsnmpd/ntpsnmpd.html@1.14 +1 -1 + NTP_4_2_7P351 + + ntpsnmpd/ntpsnmpd.man.in@1.170 +3 -3 + NTP_4_2_7P351 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.170 +3 -3 + NTP_4_2_7P351 + + packageinfo.sh@1.354 +1 -1 + NTP_4_2_7P351 + + scripts/invoke-ntp-wait.texi@1.158 +1 -1 + NTP_4_2_7P351 + + scripts/ntp-wait.1ntp-waitman@1.169 +3 -3 + NTP_4_2_7P351 + + scripts/ntp-wait.1ntp-waitmdoc@1.169 +3 -3 + NTP_4_2_7P351 + + scripts/ntp-wait.html@1.174 +1 -1 + NTP_4_2_7P351 + + scripts/ntp-wait.man.in@1.169 +3 -3 + NTP_4_2_7P351 + + scripts/ntp-wait.mdoc.in@1.169 +3 -3 + NTP_4_2_7P351 + + sntp/invoke-sntp.texi@1.338 +2 -2 + NTP_4_2_7P351 + + sntp/sntp-opts.c@1.353 +4 -4 + NTP_4_2_7P351 + + sntp/sntp-opts.h@1.353 +3 -3 + NTP_4_2_7P351 + + sntp/sntp.1sntpman@1.173 +3 -3 + NTP_4_2_7P351 + + sntp/sntp.1sntpmdoc@1.173 +3 -3 + NTP_4_2_7P351 + + sntp/sntp.html@1.353 +2 -2 + NTP_4_2_7P351 + + sntp/sntp.man.in@1.173 +3 -3 + NTP_4_2_7P351 + + sntp/sntp.mdoc.in@1.173 +3 -3 + NTP_4_2_7P351 + + util/invoke-ntp-keygen.texi@1.342 +2 -2 + NTP_4_2_7P351 + + util/ntp-keygen-opts.c@1.356 +4 -4 + NTP_4_2_7P351 + + util/ntp-keygen-opts.h@1.356 +3 -3 + NTP_4_2_7P351 + + util/ntp-keygen.1ntp-keygenman@1.170 +3 -3 + NTP_4_2_7P351 + + util/ntp-keygen.1ntp-keygenmdoc@1.170 +3 -3 + NTP_4_2_7P351 + + util/ntp-keygen.html@1.20 +2 -2 + NTP_4_2_7P351 + + util/ntp-keygen.man.in@1.170 +3 -3 + NTP_4_2_7P351 + + util/ntp-keygen.mdoc.in@1.170 +3 -3 + NTP_4_2_7P351 + +ChangeSet@1.2895, 2013-01-23 17:50:49+01:00, burnicki@pc-martin4. + [Bug 2328] Don't apply small time adjustments on Windows versions which don't support this. + + ChangeLog@1.1247 +2 -0 + [Bug 2328] Don't apply small time adjustments on Windows versions which don't support this. + + ports/winnt/ntpd/nt_clockstuff.c@1.59 +58 -0 + [bug 2328] Don't apply small time adjustments on Windows versions which don't support this. + +ChangeSet@1.2894, 2013-01-21 11:44:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P350 + TAG: NTP_4_2_7P350 + + ChangeLog@1.1246 +1 -0 + NTP_4_2_7P350 + + ntpd/invoke-ntp.conf.texi@1.24 +1 -1 + NTP_4_2_7P350 + + ntpd/invoke-ntp.keys.texi@1.24 +1 -1 + NTP_4_2_7P350 + + ntpd/invoke-ntpd.texi@1.340 +2 -2 + NTP_4_2_7P350 + + ntpd/ntp.conf.5man@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntp.conf.5mdoc@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntp.conf.html@1.23 +1 -1 + NTP_4_2_7P350 + + ntpd/ntp.conf.man.in@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntp.conf.mdoc.in@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntp.keys.5man@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntp.keys.5mdoc@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntp.keys.html@1.24 +1 -1 + NTP_4_2_7P350 + + ntpd/ntp.keys.man.in@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntp.keys.mdoc.in@1.58 +3 -3 + NTP_4_2_7P350 + + ntpd/ntpd-opts.c@1.358 +4 -4 + NTP_4_2_7P350 + + ntpd/ntpd-opts.h@1.358 +3 -3 + NTP_4_2_7P350 + + ntpd/ntpd.1ntpdman@1.169 +3 -3 + NTP_4_2_7P350 + + ntpd/ntpd.1ntpdmdoc@1.169 +3 -3 + NTP_4_2_7P350 + + ntpd/ntpd.html@1.18 +2 -2 + NTP_4_2_7P350 + + ntpd/ntpd.man.in@1.169 +3 -3 + NTP_4_2_7P350 + + ntpd/ntpd.mdoc.in@1.169 +3 -3 + NTP_4_2_7P350 + + ntpdc/invoke-ntpdc.texi@1.337 +2 -2 + NTP_4_2_7P350 + + ntpdc/ntpdc-opts.c@1.352 +4 -4 + NTP_4_2_7P350 + + ntpdc/ntpdc-opts.h@1.352 +3 -3 + NTP_4_2_7P350 + + ntpdc/ntpdc.1ntpdcman@1.168 +2 -2 + NTP_4_2_7P350 + + ntpdc/ntpdc.1ntpdcmdoc@1.168 +2 -2 + NTP_4_2_7P350 + + ntpdc/ntpdc.html@1.181 +2 -2 + NTP_4_2_7P350 + + ntpdc/ntpdc.man.in@1.168 +2 -2 + NTP_4_2_7P350 + + ntpdc/ntpdc.mdoc.in@1.168 +2 -2 + NTP_4_2_7P350 + + ntpq/invoke-ntpq.texi@1.341 +2 -2 + NTP_4_2_7P350 + + ntpq/ntpq-opts.c@1.355 +4 -4 + NTP_4_2_7P350 + + ntpq/ntpq-opts.h@1.355 +3 -3 + NTP_4_2_7P350 + + ntpq/ntpq.1ntpqman@1.169 +2 -2 + NTP_4_2_7P350 + + ntpq/ntpq.1ntpqmdoc@1.169 +2 -2 + NTP_4_2_7P350 + + ntpq/ntpq.html@1.15 +2 -2 + NTP_4_2_7P350 + + ntpq/ntpq.man.in@1.169 +2 -2 + NTP_4_2_7P350 + + ntpq/ntpq.mdoc.in@1.169 +2 -2 + NTP_4_2_7P350 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.340 +2 -2 + NTP_4_2_7P350 + + ntpsnmpd/ntpsnmpd-opts.c@1.355 +4 -4 + NTP_4_2_7P350 + + ntpsnmpd/ntpsnmpd-opts.h@1.355 +3 -3 + NTP_4_2_7P350 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.169 +3 -3 + NTP_4_2_7P350 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.169 +3 -3 + NTP_4_2_7P350 + + ntpsnmpd/ntpsnmpd.html@1.13 +1 -1 + NTP_4_2_7P350 + + ntpsnmpd/ntpsnmpd.man.in@1.169 +3 -3 + NTP_4_2_7P350 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.169 +3 -3 + NTP_4_2_7P350 + + packageinfo.sh@1.353 +1 -1 + NTP_4_2_7P350 + + scripts/invoke-ntp-wait.texi@1.157 +1 -1 + NTP_4_2_7P350 + + scripts/ntp-wait.1ntp-waitman@1.168 +3 -3 + NTP_4_2_7P350 + + scripts/ntp-wait.1ntp-waitmdoc@1.168 +3 -3 + NTP_4_2_7P350 + + scripts/ntp-wait.html@1.173 +1 -1 + NTP_4_2_7P350 + + scripts/ntp-wait.man.in@1.168 +3 -3 + NTP_4_2_7P350 + + scripts/ntp-wait.mdoc.in@1.168 +3 -3 + NTP_4_2_7P350 + + sntp/invoke-sntp.texi@1.337 +2 -2 + NTP_4_2_7P350 + + sntp/sntp-opts.c@1.352 +4 -4 + NTP_4_2_7P350 + + sntp/sntp-opts.h@1.352 +3 -3 + NTP_4_2_7P350 + + sntp/sntp.1sntpman@1.172 +3 -3 + NTP_4_2_7P350 + + sntp/sntp.1sntpmdoc@1.172 +3 -3 + NTP_4_2_7P350 + + sntp/sntp.html@1.352 +2 -2 + NTP_4_2_7P350 + + sntp/sntp.man.in@1.172 +3 -3 + NTP_4_2_7P350 + + sntp/sntp.mdoc.in@1.172 +3 -3 + NTP_4_2_7P350 + + util/invoke-ntp-keygen.texi@1.341 +2 -2 + NTP_4_2_7P350 + + util/ntp-keygen-opts.c@1.355 +4 -4 + NTP_4_2_7P350 + + util/ntp-keygen-opts.h@1.355 +3 -3 + NTP_4_2_7P350 + + util/ntp-keygen.1ntp-keygenman@1.169 +3 -3 + NTP_4_2_7P350 + + util/ntp-keygen.1ntp-keygenmdoc@1.169 +3 -3 + NTP_4_2_7P350 + + util/ntp-keygen.html@1.19 +2 -2 + NTP_4_2_7P350 + + util/ntp-keygen.man.in@1.169 +3 -3 + NTP_4_2_7P350 + + util/ntp-keygen.mdoc.in@1.169 +3 -3 + NTP_4_2_7P350 + +ChangeSet@1.2893, 2013-01-20 20:58:35-05:00, stenn@deacon.udel.edu + Added sntp/loc/netbsd based on info from Christos Zoulas + + ChangeLog@1.1245 +1 -0 + Added sntp/loc/netbsd based on info from Christos Zoulas + + sntp/loc/netbsd@1.1 +13 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/loc/netbsd + + sntp/loc/netbsd@1.0 +0 -0 + +ChangeSet@1.2892, 2013-01-20 11:44:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P349 + TAG: NTP_4_2_7P349 + + ChangeLog@1.1244 +1 -0 + NTP_4_2_7P349 + + ntpd/invoke-ntp.conf.texi@1.23 +1 -1 + NTP_4_2_7P349 + + ntpd/invoke-ntp.keys.texi@1.23 +1 -1 + NTP_4_2_7P349 + + ntpd/invoke-ntpd.texi@1.339 +2 -2 + NTP_4_2_7P349 + + ntpd/ntp.conf.5man@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntp.conf.5mdoc@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntp.conf.html@1.22 +1 -1 + NTP_4_2_7P349 + + ntpd/ntp.conf.man.in@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntp.conf.mdoc.in@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntp.keys.5man@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntp.keys.5mdoc@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntp.keys.html@1.23 +1 -1 + NTP_4_2_7P349 + + ntpd/ntp.keys.man.in@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntp.keys.mdoc.in@1.57 +3 -3 + NTP_4_2_7P349 + + ntpd/ntpd-opts.c@1.357 +4 -4 + NTP_4_2_7P349 + + ntpd/ntpd-opts.h@1.357 +3 -3 + NTP_4_2_7P349 + + ntpd/ntpd.1ntpdman@1.168 +3 -3 + NTP_4_2_7P349 + + ntpd/ntpd.1ntpdmdoc@1.168 +3 -3 + NTP_4_2_7P349 + + ntpd/ntpd.html@1.17 +4 -4 + NTP_4_2_7P349 + + ntpd/ntpd.man.in@1.168 +3 -3 + NTP_4_2_7P349 + + ntpd/ntpd.mdoc.in@1.168 +3 -3 + NTP_4_2_7P349 + + ntpdc/invoke-ntpdc.texi@1.336 +2 -2 + NTP_4_2_7P349 + + ntpdc/ntpdc-opts.c@1.351 +4 -4 + NTP_4_2_7P349 + + ntpdc/ntpdc-opts.h@1.351 +3 -3 + NTP_4_2_7P349 + + ntpdc/ntpdc.1ntpdcman@1.167 +2 -2 + NTP_4_2_7P349 + + ntpdc/ntpdc.1ntpdcmdoc@1.167 +2 -2 + NTP_4_2_7P349 + + ntpdc/ntpdc.html@1.180 +2 -2 + NTP_4_2_7P349 + + ntpdc/ntpdc.man.in@1.167 +2 -2 + NTP_4_2_7P349 + + ntpdc/ntpdc.mdoc.in@1.167 +2 -2 + NTP_4_2_7P349 + + ntpq/invoke-ntpq.texi@1.340 +2 -2 + NTP_4_2_7P349 + + ntpq/ntpq-opts.c@1.354 +4 -4 + NTP_4_2_7P349 + + ntpq/ntpq-opts.h@1.354 +3 -3 + NTP_4_2_7P349 + + ntpq/ntpq.1ntpqman@1.168 +2 -2 + NTP_4_2_7P349 + + ntpq/ntpq.1ntpqmdoc@1.168 +2 -2 + NTP_4_2_7P349 + + ntpq/ntpq.html@1.14 +13 -10 + NTP_4_2_7P349 + + ntpq/ntpq.man.in@1.168 +2 -2 + NTP_4_2_7P349 + + ntpq/ntpq.mdoc.in@1.168 +2 -2 + NTP_4_2_7P349 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.339 +2 -2 + NTP_4_2_7P349 + + ntpsnmpd/ntpsnmpd-opts.c@1.354 +4 -4 + NTP_4_2_7P349 + + ntpsnmpd/ntpsnmpd-opts.h@1.354 +3 -3 + NTP_4_2_7P349 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.168 +3 -3 + NTP_4_2_7P349 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.168 +3 -3 + NTP_4_2_7P349 + + ntpsnmpd/ntpsnmpd.html@1.12 +1 -1 + NTP_4_2_7P349 + + ntpsnmpd/ntpsnmpd.man.in@1.168 +3 -3 + NTP_4_2_7P349 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.168 +3 -3 + NTP_4_2_7P349 + + packageinfo.sh@1.352 +1 -1 + NTP_4_2_7P349 + + scripts/invoke-ntp-wait.texi@1.156 +1 -1 + NTP_4_2_7P349 + + scripts/ntp-wait.1ntp-waitman@1.167 +3 -3 + NTP_4_2_7P349 + + scripts/ntp-wait.1ntp-waitmdoc@1.167 +3 -3 + NTP_4_2_7P349 + + scripts/ntp-wait.html@1.172 +1 -1 + NTP_4_2_7P349 + + scripts/ntp-wait.man.in@1.167 +3 -3 + NTP_4_2_7P349 + + scripts/ntp-wait.mdoc.in@1.167 +3 -3 + NTP_4_2_7P349 + + sntp/invoke-sntp.texi@1.336 +2 -2 + NTP_4_2_7P349 + + sntp/sntp-opts.c@1.351 +4 -4 + NTP_4_2_7P349 + + sntp/sntp-opts.h@1.351 +3 -3 + NTP_4_2_7P349 + + sntp/sntp.1sntpman@1.171 +3 -3 + NTP_4_2_7P349 + + sntp/sntp.1sntpmdoc@1.171 +3 -3 + NTP_4_2_7P349 + + sntp/sntp.html@1.351 +2 -2 + NTP_4_2_7P349 + + sntp/sntp.man.in@1.171 +3 -3 + NTP_4_2_7P349 + + sntp/sntp.mdoc.in@1.171 +3 -3 + NTP_4_2_7P349 + + util/invoke-ntp-keygen.texi@1.340 +2 -2 + NTP_4_2_7P349 + + util/ntp-keygen-opts.c@1.354 +4 -4 + NTP_4_2_7P349 + + util/ntp-keygen-opts.h@1.354 +3 -3 + NTP_4_2_7P349 + + util/ntp-keygen.1ntp-keygenman@1.168 +3 -3 + NTP_4_2_7P349 + + util/ntp-keygen.1ntp-keygenmdoc@1.168 +3 -3 + NTP_4_2_7P349 + + util/ntp-keygen.html@1.18 +2 -2 + NTP_4_2_7P349 + + util/ntp-keygen.man.in@1.168 +3 -3 + NTP_4_2_7P349 + + util/ntp-keygen.mdoc.in@1.168 +3 -3 + NTP_4_2_7P349 + +ChangeSet@1.2891, 2013-01-18 09:44:02+01:00, burnicki@pc-martin4. + Support C99 exact size int types in a way which is compatible with the upcoming + version of libopts which will not #include unconditionally anymore. + Fixes the build errors under Windows reported in [Bug 2321]. + + ChangeLog@1.1243 +1 -0 + [Bug 2321] Fixed Windows build, but autogen update still required. + + ports/winnt/include/config.h@1.104 +46 -0 + Support C99 exact size int types in a way which is compatible with the upcoming + version of libopts which will not #include unconditionally anymore. + See [Bug 2321] for details. + +ChangeSet@1.2890, 2013-01-17 07:08:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P348 + TAG: NTP_4_2_7P348 + + ChangeLog@1.1242 +1 -0 + NTP_4_2_7P348 + + ntpd/invoke-ntp.conf.texi@1.22 +17 -5 + NTP_4_2_7P348 + + ntpd/invoke-ntp.keys.texi@1.22 +1 -1 + NTP_4_2_7P348 + + ntpd/invoke-ntpd.texi@1.338 +4 -4 + NTP_4_2_7P348 + + ntpd/ntp.conf.5man@1.56 +26 -4 + NTP_4_2_7P348 + + ntpd/ntp.conf.5mdoc@1.56 +23 -4 + NTP_4_2_7P348 + + ntpd/ntp.conf.html@1.21 +1 -1 + NTP_4_2_7P348 + + ntpd/ntp.conf.man.in@1.56 +26 -4 + NTP_4_2_7P348 + + ntpd/ntp.conf.mdoc.in@1.56 +23 -4 + NTP_4_2_7P348 + + ntpd/ntp.keys.5man@1.56 +3 -3 + NTP_4_2_7P348 + + ntpd/ntp.keys.5mdoc@1.56 +3 -3 + NTP_4_2_7P348 + + ntpd/ntp.keys.html@1.22 +1 -1 + NTP_4_2_7P348 + + ntpd/ntp.keys.man.in@1.56 +3 -3 + NTP_4_2_7P348 + + ntpd/ntp.keys.mdoc.in@1.56 +3 -3 + NTP_4_2_7P348 + + ntpd/ntpd-opts.c@1.356 +4 -4 + NTP_4_2_7P348 + + ntpd/ntpd-opts.h@1.356 +3 -3 + NTP_4_2_7P348 + + ntpd/ntpd.1ntpdman@1.167 +18 -18 + NTP_4_2_7P348 + + ntpd/ntpd.1ntpdmdoc@1.167 +18 -18 + NTP_4_2_7P348 + + ntpd/ntpd.html@1.16 +2 -2 + NTP_4_2_7P348 + + ntpd/ntpd.man.in@1.167 +18 -18 + NTP_4_2_7P348 + + ntpd/ntpd.mdoc.in@1.167 +18 -18 + NTP_4_2_7P348 + + ntpdc/invoke-ntpdc.texi@1.335 +3 -3 + NTP_4_2_7P348 + + ntpdc/ntpdc-opts.c@1.350 +4 -4 + NTP_4_2_7P348 + + ntpdc/ntpdc-opts.h@1.350 +3 -3 + NTP_4_2_7P348 + + ntpdc/ntpdc.1ntpdcman@1.166 +14 -14 + NTP_4_2_7P348 + + ntpdc/ntpdc.1ntpdcmdoc@1.166 +14 -14 + NTP_4_2_7P348 + + ntpdc/ntpdc.html@1.179 +3 -3 + NTP_4_2_7P348 + + ntpdc/ntpdc.man.in@1.166 +14 -14 + NTP_4_2_7P348 + + ntpdc/ntpdc.mdoc.in@1.166 +14 -14 + NTP_4_2_7P348 + + ntpq/invoke-ntpq.texi@1.339 +13 -10 + NTP_4_2_7P348 + + ntpq/ntpq-opts.c@1.353 +4 -4 + NTP_4_2_7P348 + + ntpq/ntpq-opts.h@1.353 +3 -3 + NTP_4_2_7P348 + + ntpq/ntpq.1ntpqman@1.167 +13 -10 + NTP_4_2_7P348 + + ntpq/ntpq.1ntpqmdoc@1.167 +13 -10 + NTP_4_2_7P348 + + ntpq/ntpq.html@1.13 +2 -25 + NTP_4_2_7P348 + + ntpq/ntpq.man.in@1.167 +13 -10 + NTP_4_2_7P348 + + ntpq/ntpq.mdoc.in@1.167 +13 -10 + NTP_4_2_7P348 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.338 +2 -2 + NTP_4_2_7P348 + + ntpsnmpd/ntpsnmpd-opts.c@1.353 +4 -4 + NTP_4_2_7P348 + + ntpsnmpd/ntpsnmpd-opts.h@1.353 +3 -3 + NTP_4_2_7P348 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.167 +3 -3 + NTP_4_2_7P348 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.167 +3 -3 + NTP_4_2_7P348 + + ntpsnmpd/ntpsnmpd.html@1.11 +1 -1 + NTP_4_2_7P348 + + ntpsnmpd/ntpsnmpd.man.in@1.167 +3 -3 + NTP_4_2_7P348 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.167 +3 -3 + NTP_4_2_7P348 + + packageinfo.sh@1.351 +1 -1 + NTP_4_2_7P348 + + scripts/invoke-ntp-wait.texi@1.155 +7 -7 + NTP_4_2_7P348 + + scripts/ntp-wait.1ntp-waitman@1.166 +9 -9 + NTP_4_2_7P348 + + scripts/ntp-wait.1ntp-waitmdoc@1.166 +9 -9 + NTP_4_2_7P348 + + scripts/ntp-wait.html@1.171 +7 -7 + NTP_4_2_7P348 + + scripts/ntp-wait.man.in@1.166 +9 -9 + NTP_4_2_7P348 + + scripts/ntp-wait.mdoc.in@1.166 +9 -9 + NTP_4_2_7P348 + + sntp/invoke-sntp.texi@1.335 +2 -2 + NTP_4_2_7P348 + + sntp/sntp-opts.c@1.350 +4 -4 + NTP_4_2_7P348 + + sntp/sntp-opts.h@1.350 +3 -3 + NTP_4_2_7P348 + + sntp/sntp.1sntpman@1.170 +3 -3 + NTP_4_2_7P348 + + sntp/sntp.1sntpmdoc@1.170 +3 -3 + NTP_4_2_7P348 + + sntp/sntp.html@1.350 +2 -2 + NTP_4_2_7P348 + + sntp/sntp.man.in@1.170 +3 -3 + NTP_4_2_7P348 + + sntp/sntp.mdoc.in@1.170 +3 -3 + NTP_4_2_7P348 + + util/invoke-ntp-keygen.texi@1.339 +2 -2 + NTP_4_2_7P348 + + util/ntp-keygen-opts.c@1.353 +4 -4 + NTP_4_2_7P348 + + util/ntp-keygen-opts.h@1.353 +3 -3 + NTP_4_2_7P348 + + util/ntp-keygen.1ntp-keygenman@1.167 +3 -3 + NTP_4_2_7P348 + + util/ntp-keygen.1ntp-keygenmdoc@1.167 +3 -3 + NTP_4_2_7P348 + + util/ntp-keygen.html@1.17 +2 -2 + NTP_4_2_7P348 + + util/ntp-keygen.man.in@1.167 +3 -3 + NTP_4_2_7P348 + + util/ntp-keygen.mdoc.in@1.167 +3 -3 + NTP_4_2_7P348 + +ChangeSet@1.2889, 2013-01-17 02:07:52-05:00, stenn@deacon.udel.edu + Cleanup to ntpsnmpd-opts.def + + ntpsnmpd/ntpsnmpd-opts.def@1.9 +2 -0 + Cleanup to ntpsnmpd-opts.def + +ChangeSet@1.2888, 2013-01-17 01:40:10-05:00, stenn@deacon.udel.edu + Cleanup to ntpsnmpd-opts.def + + ChangeLog@1.1241 +1 -0 + Cleanup to ntpsnmpd-opts.def + + ntpsnmpd/ntpsnmpd-opts.def@1.8 +1 -0 + Cleanup to ntpsnmpd-opts.def + +ChangeSet@1.2887, 2013-01-13 10:47:08+00:00, stenn@psp-fb1.ntp.org + Cleanup to ntpq.texi + + ChangeLog@1.1240 +1 -0 + Cleanup to ntpq.texi + + ntpq/ntpq.texi@1.4 +0 -23 + Cleanup to ntpq.texi + +ChangeSet@1.2886, 2013-01-13 09:54:06+00:00, stenn@psp-fb1.ntp.org + Documentation cleanup to various .def files + + ChangeLog@1.1239 +2 -0 + Documentation cleanup to various .def files + +ChangeSet@1.2885, 2013-01-13 09:53:41+00:00, stenn@psp-fb1.ntp.org + Documentation cleanup to various .def files + + ntpd/ntpd-opts.def@1.10 +15 -15 + Documentation cleanup to the ntpd .def files + + ntpdc/ntpdc-opts.def@1.20 +12 -12 + Documentation cleanup to the ntpdc .def files + + ntpq/ntpq-opts.def@1.16 +11 -8 + Documentation cleanup to the ntpq .def files + + scripts/ntp-wait-opts.def@1.7 +6 -6 + Documentation cleanup to the ntp-wait .def files + +ChangeSet@1.2884, 2013-01-13 07:37:17+00:00, stenn@psp-fb1.ntp.org + In ntp.conf.def, cleanup SEE ALSO, document 'rlimit' options + + ChangeLog@1.1238 +1 -0 + In ntp.conf.def, cleanup SEE ALSO, document 'rlimit' options + + ntpd/ntp.conf.def@1.7 +20 -1 + In ntp.conf.def, cleanup SEE ALSO, document 'rlimit' options + +ChangeSet@1.2883, 2013-01-09 10:07:33+00:00, stenn@psp-fb1.ntp.org + [Bug 2327] Rename sntp/ag-tpl/:Old to sntp/ag-tpl/Old. + + ChangeLog@1.1237 +1 -0 + [Bug 2327] Rename sntp/ag-tpl/:Old to sntp/ag-tpl/Old. + + sntp/ag-tpl/Old/agman-file.tpl@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/agman-file.tpl -> sntp/ag-tpl/Old/agman-file.tpl + + sntp/ag-tpl/Old/agmdoc-file.tpl@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/agmdoc-file.tpl -> sntp/ag-tpl/Old/agmdoc-file.tpl + + sntp/ag-tpl/Old/agtexi-cmd.tpl@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/agtexi-cmd.tpl -> sntp/ag-tpl/Old/agtexi-cmd.tpl + + sntp/ag-tpl/Old/cmd-doc.tlib@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/cmd-doc.tlib -> sntp/ag-tpl/Old/cmd-doc.tlib + + sntp/ag-tpl/Old/mdoc2man@1.3 +0 -0 + Rename: sntp/ag-tpl/:Old/mdoc2man -> sntp/ag-tpl/Old/mdoc2man + +ChangeSet@1.2882, 2013-01-09 09:09:37+00:00, stenn@psp-fb1.ntp.org + Add a reference to RFC5907 in the ntpsnmpd documentation + + ChangeLog@1.1236 +1 -0 + Add a reference to RFC5907 in the ntpsnmpd documentation + + ntpsnmpd/ntpsnmpd-opts.def@1.7 +13 -0 + Add a reference to RFC5907 in the ntpsnmpd documentation + +ChangeSet@1.2881, 2013-01-07 11:42:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P347 + TAG: NTP_4_2_7P347 + + ChangeLog@1.1235 +1 -0 + NTP_4_2_7P347 + + ntpd/invoke-ntp.conf.texi@1.21 +1 -1 + NTP_4_2_7P347 + + ntpd/invoke-ntp.keys.texi@1.21 +1 -1 + NTP_4_2_7P347 + + ntpd/invoke-ntpd.texi@1.337 +2 -2 + NTP_4_2_7P347 + + ntpd/ntp.conf.5man@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntp.conf.5mdoc@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntp.conf.html@1.20 +1 -1 + NTP_4_2_7P347 + + ntpd/ntp.conf.man.in@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntp.conf.mdoc.in@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntp.keys.5man@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntp.keys.5mdoc@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntp.keys.html@1.21 +1 -1 + NTP_4_2_7P347 + + ntpd/ntp.keys.man.in@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntp.keys.mdoc.in@1.55 +3 -3 + NTP_4_2_7P347 + + ntpd/ntpd-opts.c@1.355 +4 -4 + NTP_4_2_7P347 + + ntpd/ntpd-opts.h@1.355 +3 -3 + NTP_4_2_7P347 + + ntpd/ntpd.1ntpdman@1.166 +3 -3 + NTP_4_2_7P347 + + ntpd/ntpd.1ntpdmdoc@1.166 +3 -3 + NTP_4_2_7P347 + + ntpd/ntpd.html@1.15 +2 -492 + NTP_4_2_7P347 + + ntpd/ntpd.man.in@1.166 +3 -3 + NTP_4_2_7P347 + + ntpd/ntpd.mdoc.in@1.166 +3 -3 + NTP_4_2_7P347 + + ntpdc/invoke-ntpdc.texi@1.334 +2 -2 + NTP_4_2_7P347 + + ntpdc/ntpdc-opts.c@1.349 +4 -4 + NTP_4_2_7P347 + + ntpdc/ntpdc-opts.h@1.349 +3 -3 + NTP_4_2_7P347 + + ntpdc/ntpdc.1ntpdcman@1.165 +2 -2 + NTP_4_2_7P347 + + ntpdc/ntpdc.1ntpdcmdoc@1.165 +2 -2 + NTP_4_2_7P347 + + ntpdc/ntpdc.html@1.178 +2 -2 + NTP_4_2_7P347 + + ntpdc/ntpdc.man.in@1.165 +2 -2 + NTP_4_2_7P347 + + ntpdc/ntpdc.mdoc.in@1.165 +2 -2 + NTP_4_2_7P347 + + ntpq/invoke-ntpq.texi@1.338 +2 -2 + NTP_4_2_7P347 + + ntpq/ntpq-opts.c@1.352 +4 -4 + NTP_4_2_7P347 + + ntpq/ntpq-opts.h@1.352 +3 -3 + NTP_4_2_7P347 + + ntpq/ntpq.1ntpqman@1.166 +2 -2 + NTP_4_2_7P347 + + ntpq/ntpq.1ntpqmdoc@1.166 +2 -2 + NTP_4_2_7P347 + + ntpq/ntpq.html@1.12 +2 -2 + NTP_4_2_7P347 + + ntpq/ntpq.man.in@1.166 +2 -2 + NTP_4_2_7P347 + + ntpq/ntpq.mdoc.in@1.166 +2 -2 + NTP_4_2_7P347 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.337 +2 -2 + NTP_4_2_7P347 + + ntpsnmpd/ntpsnmpd-opts.c@1.352 +4 -4 + NTP_4_2_7P347 + + ntpsnmpd/ntpsnmpd-opts.h@1.352 +3 -3 + NTP_4_2_7P347 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.166 +3 -3 + NTP_4_2_7P347 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.166 +3 -3 + NTP_4_2_7P347 + + ntpsnmpd/ntpsnmpd.html@1.10 +1 -1 + NTP_4_2_7P347 + + ntpsnmpd/ntpsnmpd.man.in@1.166 +3 -3 + NTP_4_2_7P347 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.166 +3 -3 + NTP_4_2_7P347 + + packageinfo.sh@1.350 +1 -1 + NTP_4_2_7P347 + + scripts/invoke-ntp-wait.texi@1.154 +1 -1 + NTP_4_2_7P347 + + scripts/ntp-wait.1ntp-waitman@1.165 +3 -3 + NTP_4_2_7P347 + + scripts/ntp-wait.1ntp-waitmdoc@1.165 +3 -3 + NTP_4_2_7P347 + + scripts/ntp-wait.html@1.170 +1 -1 + NTP_4_2_7P347 + + scripts/ntp-wait.man.in@1.165 +3 -3 + NTP_4_2_7P347 + + scripts/ntp-wait.mdoc.in@1.165 +3 -3 + NTP_4_2_7P347 + + sntp/invoke-sntp.texi@1.334 +2 -2 + NTP_4_2_7P347 + + sntp/sntp-opts.c@1.349 +4 -4 + NTP_4_2_7P347 + + sntp/sntp-opts.h@1.349 +3 -3 + NTP_4_2_7P347 + + sntp/sntp.1sntpman@1.169 +3 -3 + NTP_4_2_7P347 + + sntp/sntp.1sntpmdoc@1.169 +3 -3 + NTP_4_2_7P347 + + sntp/sntp.html@1.349 +2 -2 + NTP_4_2_7P347 + + sntp/sntp.man.in@1.169 +3 -3 + NTP_4_2_7P347 + + sntp/sntp.mdoc.in@1.169 +3 -3 + NTP_4_2_7P347 + + util/invoke-ntp-keygen.texi@1.338 +2 -2 + NTP_4_2_7P347 + + util/ntp-keygen-opts.c@1.352 +4 -4 + NTP_4_2_7P347 + + util/ntp-keygen-opts.h@1.352 +3 -3 + NTP_4_2_7P347 + + util/ntp-keygen.1ntp-keygenman@1.166 +3 -3 + NTP_4_2_7P347 + + util/ntp-keygen.1ntp-keygenmdoc@1.166 +3 -3 + NTP_4_2_7P347 + + util/ntp-keygen.html@1.16 +2 -23 + NTP_4_2_7P347 + + util/ntp-keygen.man.in@1.166 +3 -3 + NTP_4_2_7P347 + + util/ntp-keygen.mdoc.in@1.166 +3 -3 + NTP_4_2_7P347 + +ChangeSet@1.2880, 2013-01-07 04:15:55-05:00, stenn@deacon.udel.edu + [Bug 2325] Re-enable mlockall() check under Linux post-1223 fix + + ChangeLog@1.1234 +1 -0 + [Bug 2325] Re-enable mlockall() check under Linux post-1223 fix + + configure.ac@1.556 +4 -3 + [Bug 2325] Re-enable mlockall() check under Linux post-1223 fix + +ChangeSet@1.2879, 2013-01-06 11:47:57+00:00, stenn@deacon.udel.edu + NTP_4_2_7P346 + TAG: NTP_4_2_7P346 + + ChangeLog@1.1233 +1 -0 + NTP_4_2_7P346 + + ntpd/invoke-ntp.conf.texi@1.20 +1 -1 + NTP_4_2_7P346 + + ntpd/invoke-ntp.keys.texi@1.20 +1 -1 + NTP_4_2_7P346 + + ntpd/invoke-ntpd.texi@1.336 +2 -471 + NTP_4_2_7P346 + + ntpd/ntp.conf.5man@1.54 +8 -5 + NTP_4_2_7P346 + + ntpd/ntp.conf.5mdoc@1.54 +8 -5 + NTP_4_2_7P346 + + ntpd/ntp.conf.html@1.19 +1 -1 + NTP_4_2_7P346 + + ntpd/ntp.conf.man.in@1.54 +8 -5 + NTP_4_2_7P346 + + ntpd/ntp.conf.mdoc.in@1.54 +8 -5 + NTP_4_2_7P346 + + ntpd/ntp.keys.5man@1.54 +5 -4 + NTP_4_2_7P346 + + ntpd/ntp.keys.5mdoc@1.54 +5 -4 + NTP_4_2_7P346 + + ntpd/ntp.keys.html@1.20 +2 -2 + NTP_4_2_7P346 + + ntpd/ntp.keys.man.in@1.54 +5 -4 + NTP_4_2_7P346 + + ntpd/ntp.keys.mdoc.in@1.54 +5 -4 + NTP_4_2_7P346 + + ntpd/ntpd-opts.c@1.354 +5 -5 + NTP_4_2_7P346 + + ntpd/ntpd-opts.h@1.354 +5 -5 + NTP_4_2_7P346 + + ntpd/ntpd.1ntpdman@1.165 +8 -5 + NTP_4_2_7P346 + + ntpd/ntpd.1ntpdmdoc@1.165 +8 -5 + NTP_4_2_7P346 + + ntpd/ntpd.html@1.14 +5 -5 + NTP_4_2_7P346 + + ntpd/ntpd.man.in@1.165 +8 -5 + NTP_4_2_7P346 + + ntpd/ntpd.mdoc.in@1.165 +8 -5 + NTP_4_2_7P346 + + ntpdc/invoke-ntpdc.texi@1.333 +2 -609 + NTP_4_2_7P346 + + ntpdc/ntpdc-opts.c@1.348 +5 -5 + NTP_4_2_7P346 + + ntpdc/ntpdc-opts.h@1.348 +5 -5 + NTP_4_2_7P346 + + ntpdc/ntpdc.1ntpdcman@1.164 +5 -3 + NTP_4_2_7P346 + + ntpdc/ntpdc.1ntpdcmdoc@1.164 +5 -3 + NTP_4_2_7P346 + + ntpdc/ntpdc.html@1.177 +47 -187 + NTP_4_2_7P346 + + ntpdc/ntpdc.man.in@1.164 +5 -3 + NTP_4_2_7P346 + + ntpdc/ntpdc.mdoc.in@1.164 +5 -3 + NTP_4_2_7P346 + + ntpq/invoke-ntpq.texi@1.337 +2 -2 + NTP_4_2_7P346 + + ntpq/ntpq-opts.c@1.351 +5 -5 + NTP_4_2_7P346 + + ntpq/ntpq-opts.h@1.351 +5 -5 + NTP_4_2_7P346 + + ntpq/ntpq.1ntpqman@1.165 +2 -2 + NTP_4_2_7P346 + + ntpq/ntpq.1ntpqmdoc@1.165 +2 -2 + NTP_4_2_7P346 + + ntpq/ntpq.html@1.11 +4 -4 + NTP_4_2_7P346 + + ntpq/ntpq.man.in@1.165 +2 -2 + NTP_4_2_7P346 + + ntpq/ntpq.mdoc.in@1.165 +2 -2 + NTP_4_2_7P346 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.336 +2 -48 + NTP_4_2_7P346 + + ntpsnmpd/ntpsnmpd-opts.c@1.351 +5 -5 + NTP_4_2_7P346 + + ntpsnmpd/ntpsnmpd-opts.h@1.351 +5 -5 + NTP_4_2_7P346 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.165 +4 -3 + NTP_4_2_7P346 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.165 +4 -3 + NTP_4_2_7P346 + + ntpsnmpd/ntpsnmpd.html@1.9 +1 -1 + NTP_4_2_7P346 + + ntpsnmpd/ntpsnmpd.man.in@1.165 +4 -3 + NTP_4_2_7P346 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.165 +4 -3 + NTP_4_2_7P346 + + packageinfo.sh@1.349 +1 -1 + NTP_4_2_7P346 + + scripts/invoke-ntp-wait.texi@1.153 +1 -3 + NTP_4_2_7P346 + + scripts/ntp-wait.1ntp-waitman@1.164 +4 -3 + NTP_4_2_7P346 + + scripts/ntp-wait.1ntp-waitmdoc@1.164 +4 -3 + NTP_4_2_7P346 + + scripts/ntp-wait.html@1.169 +2 -5 + NTP_4_2_7P346 + + scripts/ntp-wait.man.in@1.164 +4 -3 + NTP_4_2_7P346 + + scripts/ntp-wait.mdoc.in@1.164 +4 -3 + NTP_4_2_7P346 + + sntp/invoke-sntp.texi@1.333 +2 -27 + NTP_4_2_7P346 + + sntp/sntp-opts.c@1.348 +5 -5 + NTP_4_2_7P346 + + sntp/sntp-opts.h@1.348 +5 -5 + NTP_4_2_7P346 + + sntp/sntp.1sntpman@1.168 +6 -4 + NTP_4_2_7P346 + + sntp/sntp.1sntpmdoc@1.168 +6 -4 + NTP_4_2_7P346 + + sntp/sntp.html@1.348 +2 -25 + NTP_4_2_7P346 + + sntp/sntp.man.in@1.168 +6 -4 + NTP_4_2_7P346 + + sntp/sntp.mdoc.in@1.168 +6 -4 + NTP_4_2_7P346 + + util/invoke-ntp-keygen.texi@1.337 +2 -22 + NTP_4_2_7P346 + + util/ntp-keygen-opts.c@1.351 +5 -5 + NTP_4_2_7P346 + + util/ntp-keygen-opts.h@1.351 +5 -5 + NTP_4_2_7P346 + + util/ntp-keygen.1ntp-keygenman@1.165 +9 -5 + NTP_4_2_7P346 + + util/ntp-keygen.1ntp-keygenmdoc@1.165 +9 -5 + NTP_4_2_7P346 + + util/ntp-keygen.html@1.15 +5 -5 + NTP_4_2_7P346 + + util/ntp-keygen.man.in@1.165 +9 -5 + NTP_4_2_7P346 + + util/ntp-keygen.mdoc.in@1.165 +9 -5 + NTP_4_2_7P346 + +ChangeSet@1.2878, 2013-01-06 06:26:49-05:00, stenn@deacon.udel.edu + Libopts-5.17.1pre14 update + + sntp/libopts/autoopts/options.h@1.19 +60 -40 + Libopts-5.17.1pre14 update + + sntp/libopts/autoopts/project.h@1.4 +25 -0 + Libopts-5.17.1pre14 update + + sntp/libopts/autoopts/usage-txt.h@1.19 +9 -9 + Libopts-5.17.1pre14 update + + sntp/libopts/compat/compat.h@1.12 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/compat/windows-config.h@1.11 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/m4/libopts.m4@1.23 +2 -2 + Libopts-5.17.1pre14 update + + sntp/libopts/m4/liboptschk.m4@1.11 +1 -1 + Libopts-5.17.1pre14 update + +ChangeSet@1.2877, 2013-01-06 05:17:07-05:00, stenn@deacon.udel.edu + Libopts-5.17.1pre14 update + + sntp/libopts/COPYING.gplv3@1.6 +3 -3 + Libopts-5.17.1pre14 update + + sntp/libopts/COPYING.lgplv3@1.6 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/Makefile.am@1.17 +3 -3 + Libopts-5.17.1pre14 update + + sntp/libopts/README@1.8 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/ag-char-map.h@1.20 +2 -2 + Libopts-5.17.1pre14 update + + sntp/libopts/alias.c@1.4 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/ao-strs.c@1.6 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/ao-strs.h@1.5 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/autoopts.c@1.15 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/autoopts.h@1.13 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/boolean.c@1.12 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/check.c@1.5 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/configfile.c@1.17 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/cook.c@1.12 +24 -15 + Libopts-5.17.1pre14 update + + sntp/libopts/enum.c@1.7 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/env.c@1.6 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/file.c@1.12 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/find.c@1.6 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/genshell.c@1.20 +2 -2 + Libopts-5.17.1pre14 update + + sntp/libopts/genshell.h@1.20 +3 -3 + Libopts-5.17.1pre14 update + + sntp/libopts/gettext.h@1.2 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/init.c@1.2 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/load.c@1.15 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/makeshell.c@1.14 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/nested.c@1.11 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/numeric.c@1.11 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/option-value-type.c@1.7 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/option-value-type.h@1.21 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/option-xat-attribute.c@1.7 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/option-xat-attribute.h@1.21 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/parse-duration.c@1.10 +4 -4 + Libopts-5.17.1pre14 update + + sntp/libopts/parse-duration.h@1.8 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/pgusage.c@1.12 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/proto.h@1.20 +29 -39 + Libopts-5.17.1pre14 update + + sntp/libopts/putshell.c@1.11 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/reset.c@1.13 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/restore.c@1.10 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/save.c@1.13 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/sort.c@1.11 +70 -70 + Libopts-5.17.1pre14 update + + sntp/libopts/stack.c@1.12 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/streqvcmp.c@1.11 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/text_mmap.c@1.12 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/time.c@1.12 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/tokenize.c@1.9 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/usage.c@1.13 +1 -1 + Libopts-5.17.1pre14 update + + sntp/libopts/version.c@1.13 +3 -5 + Libopts-5.17.1pre14 update + +ChangeSet@1.2876, 2013-01-06 09:08:55+00:00, stenn@psp-at1.ntp.org + [Bug 1223] reorganize inclusion of sys/resource.h + + ChangeLog@1.1232 +1 -0 + [Bug 1223] reorganize inclusion of sys/resource.h + + include/ntp_config.h@1.79 +4 -0 + [Bug 1223] reorganize inclusion of sys/resource.h + + ntpd/ntp_config.c@1.310 +0 -3 + [Bug 1223] reorganize inclusion of sys/resource.h + + ntpd/ntp_util.c@1.99 +0 -6 + [Bug 1223] reorganize inclusion of sys/resource.h + + ntpd/ntpd.c@1.141 +0 -3 + [Bug 1223] reorganize inclusion of sys/resource.h + +ChangeSet@1.2875, 2013-01-04 09:05:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P345 + TAG: NTP_4_2_7P345 + + ChangeLog@1.1231 +1 -0 + NTP_4_2_7P345 + + ntpd/invoke-ntp.conf.texi@1.19 +2 -2 + NTP_4_2_7P345 + + ntpd/invoke-ntp.keys.texi@1.19 +2 -2 + NTP_4_2_7P345 + + ntpd/invoke-ntpd.texi@1.335 +5 -5 + NTP_4_2_7P345 + + ntpd/ntp.conf.5man@1.53 +61 -10 + NTP_4_2_7P345 + + ntpd/ntp.conf.5mdoc@1.53 +136 -87 + NTP_4_2_7P345 + + ntpd/ntp.conf.html@1.18 +405 -1603 + NTP_4_2_7P345 + + ntpd/ntp.conf.man.in@1.53 +61 -10 + NTP_4_2_7P345 + + ntpd/ntp.conf.mdoc.in@1.53 +136 -87 + NTP_4_2_7P345 + + ntpd/ntp.keys.5man@1.53 +24 -6 + NTP_4_2_7P345 + + ntpd/ntp.keys.5mdoc@1.53 +58 -9 + NTP_4_2_7P345 + + ntpd/ntp.keys.html@1.19 +71 -27 + NTP_4_2_7P345 + + ntpd/ntp.keys.man.in@1.53 +24 -6 + NTP_4_2_7P345 + + ntpd/ntp.keys.mdoc.in@1.53 +58 -9 + NTP_4_2_7P345 + + ntpd/ntpd-opts.c@1.353 +4 -4 + NTP_4_2_7P345 + + ntpd/ntpd-opts.h@1.353 +3 -3 + NTP_4_2_7P345 + + ntpd/ntpd.1ntpdman@1.164 +42 -20 + NTP_4_2_7P345 + + ntpd/ntpd.1ntpdmdoc@1.164 +68 -53 + NTP_4_2_7P345 + + ntpd/ntpd.html@1.13 +70 -178 + NTP_4_2_7P345 + + ntpd/ntpd.man.in@1.164 +42 -20 + NTP_4_2_7P345 + + ntpd/ntpd.mdoc.in@1.164 +68 -53 + NTP_4_2_7P345 + + ntpdc/invoke-ntpdc.texi@1.332 +4 -4 + NTP_4_2_7P345 + + ntpdc/ntpdc-opts.c@1.347 +4 -4 + NTP_4_2_7P345 + + ntpdc/ntpdc-opts.h@1.347 +3 -3 + NTP_4_2_7P345 + + ntpdc/ntpdc.1ntpdcman@1.163 +31 -12 + NTP_4_2_7P345 + + ntpdc/ntpdc.1ntpdcmdoc@1.163 +53 -36 + NTP_4_2_7P345 + + ntpdc/ntpdc.html@1.176 +4 -4 + NTP_4_2_7P345 + + ntpdc/ntpdc.man.in@1.163 +31 -12 + NTP_4_2_7P345 + + ntpdc/ntpdc.mdoc.in@1.163 +53 -36 + NTP_4_2_7P345 + + ntpq/invoke-ntpq.texi@1.336 +4 -4 + NTP_4_2_7P345 + + ntpq/ntpq-opts.c@1.350 +4 -4 + NTP_4_2_7P345 + + ntpq/ntpq-opts.h@1.350 +3 -3 + NTP_4_2_7P345 + + ntpq/ntpq.1ntpqman@1.164 +28 -9 + NTP_4_2_7P345 + + ntpq/ntpq.1ntpqmdoc@1.164 +40 -23 + NTP_4_2_7P345 + + ntpq/ntpq.html@1.10 +68 -37 + NTP_4_2_7P345 + + ntpq/ntpq.man.in@1.164 +28 -9 + NTP_4_2_7P345 + + ntpq/ntpq.mdoc.in@1.164 +40 -23 + NTP_4_2_7P345 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.335 +5 -5 + NTP_4_2_7P345 + + ntpsnmpd/ntpsnmpd-opts.c@1.350 +4 -4 + NTP_4_2_7P345 + + ntpsnmpd/ntpsnmpd-opts.h@1.350 +3 -3 + NTP_4_2_7P345 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.164 +25 -7 + NTP_4_2_7P345 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.164 +35 -19 + NTP_4_2_7P345 + + ntpsnmpd/ntpsnmpd.html@1.8 +1 -1 + NTP_4_2_7P345 + + ntpsnmpd/ntpsnmpd.man.in@1.164 +25 -7 + NTP_4_2_7P345 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.164 +35 -19 + NTP_4_2_7P345 + + packageinfo.sh@1.348 +1 -1 + NTP_4_2_7P345 + + scripts/invoke-ntp-wait.texi@1.152 +5 -5 + NTP_4_2_7P345 + + scripts/ntp-wait.1ntp-waitman@1.163 +27 -5 + NTP_4_2_7P345 + + scripts/ntp-wait.1ntp-waitmdoc@1.163 +33 -12 + NTP_4_2_7P345 + + scripts/ntp-wait.html@1.168 +5 -5 + NTP_4_2_7P345 + + scripts/ntp-wait.man.in@1.163 +27 -5 + NTP_4_2_7P345 + + scripts/ntp-wait.mdoc.in@1.163 +33 -12 + NTP_4_2_7P345 + + sntp/invoke-sntp.texi@1.332 +5 -5 + NTP_4_2_7P345 + + sntp/sntp-opts.c@1.347 +4 -4 + NTP_4_2_7P345 + + sntp/sntp-opts.h@1.347 +3 -3 + NTP_4_2_7P345 + + sntp/sntp.1sntpman@1.167 +32 -14 + NTP_4_2_7P345 + + sntp/sntp.1sntpmdoc@1.167 +47 -34 + NTP_4_2_7P345 + + sntp/sntp.html@1.347 +5 -5 + NTP_4_2_7P345 + + sntp/sntp.man.in@1.167 +32 -14 + NTP_4_2_7P345 + + sntp/sntp.mdoc.in@1.167 +47 -34 + NTP_4_2_7P345 + + util/invoke-ntp-keygen.texi@1.336 +5 -5 + NTP_4_2_7P345 + + util/ntp-keygen-opts.c@1.350 +4 -4 + NTP_4_2_7P345 + + util/ntp-keygen-opts.h@1.350 +3 -3 + NTP_4_2_7P345 + + util/ntp-keygen.1ntp-keygenman@1.164 +32 -14 + NTP_4_2_7P345 + + util/ntp-keygen.1ntp-keygenmdoc@1.164 +74 -59 + NTP_4_2_7P345 + + util/ntp-keygen.html@1.14 +233 -205 + NTP_4_2_7P345 + + util/ntp-keygen.man.in@1.164 +32 -14 + NTP_4_2_7P345 + + util/ntp-keygen.mdoc.in@1.164 +74 -59 + NTP_4_2_7P345 + +ChangeSet@1.2874, 2013-01-04 03:36:43-05:00, stenn@deacon.udel.edu + clarify the reasoning for local libopts + + configure.ac@1.555 +3 -2 + clarify the reasoning for local libopts + +ChangeSet@1.2873, 2013-01-04 08:12:48+00:00, stenn@psp-at1.ntp.org + Update several .def files to use autogen-5.17 feature set + + ChangeLog@1.1230 +1 -0 + Update several .def files to use autogen-5.17 feature set + + ntpd/ntp.conf.def@1.6 +1 -6 + Update several .def files to use autogen-5.17 feature set + + ntpd/ntp.keys.def@1.9 +1 -6 + Update several .def files to use autogen-5.17 feature set + + ntpd/ntpd-opts.def@1.9 +1 -1 + Update several .def files to use autogen-5.17 feature set + + ntpsnmpd/ntpsnmpd-opts.def@1.6 +1 -1 + Update several .def files to use autogen-5.17 feature set + + scripts/ntp-wait-opts.def@1.6 +1 -6 + Update several .def files to use autogen-5.17 feature set + + sntp/ag-tpl/:Old/agman-file.tpl@1.2 +0 -0 + Rename: sntp/ag-tpl/agman-file.tpl -> sntp/ag-tpl/:Old/agman-file.tpl + + sntp/ag-tpl/:Old/agmdoc-file.tpl@1.2 +0 -0 + Rename: sntp/ag-tpl/agmdoc-file.tpl -> sntp/ag-tpl/:Old/agmdoc-file.tpl + + sntp/ag-tpl/:Old/agtexi-cmd.tpl@1.2 +0 -0 + Rename: sntp/ag-tpl/agtexi-cmd.tpl -> sntp/ag-tpl/:Old/agtexi-cmd.tpl + + sntp/ag-tpl/:Old/cmd-doc.tlib@1.2 +0 -0 + Rename: sntp/ag-tpl/cmd-doc.tlib -> sntp/ag-tpl/:Old/cmd-doc.tlib + + sntp/ag-tpl/:Old/mdoc2man@1.2 +0 -0 + Rename: sntp/ag-tpl/mdoc2man -> sntp/ag-tpl/:Old/mdoc2man + + sntp/include/autogen-version.def@1.14 +2 -1 + Update several .def files to use autogen-5.17 feature set + + sntp/include/copyright.def@1.22 +5 -0 + Update several .def files to use autogen-5.17 feature set + + sntp/sntp-opts.def@1.42 +1 -47 + Update several .def files to use autogen-5.17 feature set + + util/ntp-keygen-opts.def@1.24 +1 -6 + Update several .def files to use autogen-5.17 feature set + +ChangeSet@1.2872, 2013-01-03 13:11:51+00:00, stenn@deacon.udel.edu + NTP_4_2_7P344 + TAG: NTP_4_2_7P344 + + ChangeLog@1.1229 +1 -0 + NTP_4_2_7P344 + + ntpd/invoke-ntp.conf.texi@1.18 +773 -774 + NTP_4_2_7P344 + + ntpd/invoke-ntp.keys.texi@1.18 +54 -29 + NTP_4_2_7P344 + + ntpd/invoke-ntpd.texi@1.334 +72 -173 + NTP_4_2_7P344 + + ntpd/ntp.conf.5man@1.52 +2879 -3 + NTP_4_2_7P344 + + ntpd/ntp.conf.5mdoc@1.52 +2711 -3 + NTP_4_2_7P344 + + ntpd/ntp.conf.html@1.17 +1 -1 + NTP_4_2_7P344 + + ntpd/ntp.conf.man.in@1.52 +2879 -3 + NTP_4_2_7P344 + + ntpd/ntp.conf.mdoc.in@1.52 +2711 -3 + NTP_4_2_7P344 + + ntpd/ntp.keys.5man@1.52 +95 -2 + NTP_4_2_7P344 + + ntpd/ntp.keys.5mdoc@1.52 +94 -2 + NTP_4_2_7P344 + + ntpd/ntp.keys.html@1.18 +1 -1 + NTP_4_2_7P344 + + ntpd/ntp.keys.man.in@1.52 +95 -2 + NTP_4_2_7P344 + + ntpd/ntp.keys.mdoc.in@1.52 +94 -2 + NTP_4_2_7P344 + + ntpd/ntpd-opts.c@1.352 +73 -45 + NTP_4_2_7P344 + + ntpd/ntpd-opts.h@1.352 +10 -9 + NTP_4_2_7P344 + + ntpd/ntpd.1ntpdman@1.163 +550 -4 + NTP_4_2_7P344 + + ntpd/ntpd.1ntpdmdoc@1.163 +548 -3 + NTP_4_2_7P344 + + ntpd/ntpd.html@1.12 +2 -2 + NTP_4_2_7P344 + + ntpd/ntpd.man.in@1.163 +550 -4 + NTP_4_2_7P344 + + ntpd/ntpd.mdoc.in@1.163 +548 -3 + NTP_4_2_7P344 + + ntpdc/invoke-ntpdc.texi@1.331 +154 -205 + NTP_4_2_7P344 + + ntpdc/ntpdc-opts.c@1.346 +73 -45 + NTP_4_2_7P344 + + ntpdc/ntpdc-opts.h@1.346 +12 -11 + NTP_4_2_7P344 + + ntpdc/ntpdc.1ntpdcman@1.162 +705 -4 + NTP_4_2_7P344 + + ntpdc/ntpdc.1ntpdcmdoc@1.162 +659 -3 + NTP_4_2_7P344 + + ntpdc/ntpdc.html@1.175 +40 -34 + NTP_4_2_7P344 + + ntpdc/ntpdc.man.in@1.162 +705 -4 + NTP_4_2_7P344 + + ntpdc/ntpdc.mdoc.in@1.162 +659 -3 + NTP_4_2_7P344 + + ntpq/invoke-ntpq.texi@1.335 +61 -42 + NTP_4_2_7P344 + + ntpq/ntpq-opts.c@1.349 +73 -45 + NTP_4_2_7P344 + + ntpq/ntpq-opts.h@1.349 +12 -11 + NTP_4_2_7P344 + + ntpq/ntpq.1ntpqman@1.163 +261 -3 + NTP_4_2_7P344 + + ntpq/ntpq.1ntpqmdoc@1.163 +245 -2 + NTP_4_2_7P344 + + ntpq/ntpq.html@1.9 +2 -2 + NTP_4_2_7P344 + + ntpq/ntpq.man.in@1.163 +261 -3 + NTP_4_2_7P344 + + ntpq/ntpq.mdoc.in@1.163 +245 -2 + NTP_4_2_7P344 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.334 +19 -23 + NTP_4_2_7P344 + + ntpsnmpd/ntpsnmpd-opts.c@1.349 +67 -45 + NTP_4_2_7P344 + + ntpsnmpd/ntpsnmpd-opts.h@1.349 +12 -11 + NTP_4_2_7P344 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.163 +57 -3 + NTP_4_2_7P344 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.163 +48 -2 + NTP_4_2_7P344 + + ntpsnmpd/ntpsnmpd.html@1.7 +1 -1 + NTP_4_2_7P344 + + ntpsnmpd/ntpsnmpd.man.in@1.163 +57 -3 + NTP_4_2_7P344 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.163 +48 -2 + NTP_4_2_7P344 + + packageinfo.sh@1.347 +1 -1 + NTP_4_2_7P344 + + scripts/invoke-ntp-wait.texi@1.151 +9 -6 + NTP_4_2_7P344 + + scripts/ntp-wait.1ntp-waitman@1.162 +20 -3 + NTP_4_2_7P344 + + scripts/ntp-wait.1ntp-waitmdoc@1.162 +19 -2 + NTP_4_2_7P344 + + scripts/ntp-wait.html@1.167 +9 -6 + NTP_4_2_7P344 + + scripts/ntp-wait.man.in@1.162 +20 -3 + NTP_4_2_7P344 + + scripts/ntp-wait.mdoc.in@1.162 +19 -2 + NTP_4_2_7P344 + + sntp/invoke-sntp.texi@1.331 +28 -18 + NTP_4_2_7P344 + + sntp/sntp-opts.c@1.346 +75 -47 + NTP_4_2_7P344 + + sntp/sntp-opts.h@1.346 +12 -11 + NTP_4_2_7P344 + + sntp/sntp.1sntpman@1.166 +67 -3 + NTP_4_2_7P344 + + sntp/sntp.1sntpmdoc@1.166 +66 -2 + NTP_4_2_7P344 + + sntp/sntp.html@1.346 +26 -17 + NTP_4_2_7P344 + + sntp/sntp.man.in@1.166 +67 -3 + NTP_4_2_7P344 + + sntp/sntp.mdoc.in@1.166 +66 -2 + NTP_4_2_7P344 + + util/invoke-ntp-keygen.texi@1.335 +208 -171 + NTP_4_2_7P344 + + util/ntp-keygen-opts.c@1.349 +75 -47 + NTP_4_2_7P344 + + util/ntp-keygen-opts.h@1.349 +10 -9 + NTP_4_2_7P344 + + util/ntp-keygen.1ntp-keygenman@1.163 +854 -4 + NTP_4_2_7P344 + + util/ntp-keygen.1ntp-keygenmdoc@1.163 +839 -3 + NTP_4_2_7P344 + + util/ntp-keygen.html@1.13 +2 -2 + NTP_4_2_7P344 + + util/ntp-keygen.man.in@1.163 +854 -4 + NTP_4_2_7P344 + + util/ntp-keygen.mdoc.in@1.163 +839 -3 + NTP_4_2_7P344 + +ChangeSet@1.2871, 2013-01-03 11:36:26+00:00, stenn@psp-at1.ntp.org + Refactor and enhance mdoc2texi + + ChangeLog@1.1228 +1 -0 + Refactor and enhance mdoc2texi + + ChangeLog@1.1227 +1 -0 + Make sure agtexi-file.tpl defines label-str + + sntp/ag-tpl/agtexi-file.tpl@1.4 +4 -4 + Make sure agtexi-file.tpl defines label-str + + sntp/ag-tpl/mdoc2texi@1.7 +676 -393 + Refactor and enhance mdoc2texi + +ChangeSet@1.2870, 2013-01-03 11:23:34+00:00, stenn@psp-at1.ntp.org + Cleanup to ntp.conf.def + + ChangeLog@1.1226 +1 -0 + Cleanup to ntp.conf.def + + ntpd/ntp.conf.def@1.5 +4 -2 + Cleanup to ntp.conf.def + +ChangeSet@1.2865.1.7, 2013-01-02 02:21:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P343 + TAG: NTP_4_2_7P343 + + ChangeLog@1.1222.1.6 +1 -0 + NTP_4_2_7P343 + + ntpd/invoke-ntp.conf.texi@1.17 +1 -1 + NTP_4_2_7P343 + + ntpd/invoke-ntp.keys.texi@1.17 +1 -1 + NTP_4_2_7P343 + + ntpd/invoke-ntpd.texi@1.333 +2 -2 + NTP_4_2_7P343 + + ntpd/ntp.conf.5man@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntp.conf.5mdoc@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntp.conf.html@1.16 +1 -1 + NTP_4_2_7P343 + + ntpd/ntp.conf.man.in@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntp.conf.mdoc.in@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntp.keys.5man@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntp.keys.5mdoc@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntp.keys.html@1.17 +1 -1 + NTP_4_2_7P343 + + ntpd/ntp.keys.man.in@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntp.keys.mdoc.in@1.51 +3 -3 + NTP_4_2_7P343 + + ntpd/ntpd-opts.c@1.351 +6 -6 + NTP_4_2_7P343 + + ntpd/ntpd-opts.h@1.351 +4 -4 + NTP_4_2_7P343 + + ntpd/ntpd.1ntpdman@1.162 +3 -3 + NTP_4_2_7P343 + + ntpd/ntpd.1ntpdmdoc@1.162 +3 -3 + NTP_4_2_7P343 + + ntpd/ntpd.html@1.11 +2 -2 + NTP_4_2_7P343 + + ntpd/ntpd.man.in@1.162 +3 -3 + NTP_4_2_7P343 + + ntpd/ntpd.mdoc.in@1.162 +3 -3 + NTP_4_2_7P343 + + ntpdc/invoke-ntpdc.texi@1.330 +2 -2 + NTP_4_2_7P343 + + ntpdc/ntpdc-opts.c@1.345 +6 -6 + NTP_4_2_7P343 + + ntpdc/ntpdc-opts.h@1.345 +4 -4 + NTP_4_2_7P343 + + ntpdc/ntpdc.1ntpdcman@1.161 +3 -3 + NTP_4_2_7P343 + + ntpdc/ntpdc.1ntpdcmdoc@1.161 +3 -3 + NTP_4_2_7P343 + + ntpdc/ntpdc.html@1.174 +2 -2 + NTP_4_2_7P343 + + ntpdc/ntpdc.man.in@1.161 +3 -3 + NTP_4_2_7P343 + + ntpdc/ntpdc.mdoc.in@1.161 +3 -3 + NTP_4_2_7P343 + + ntpq/invoke-ntpq.texi@1.334 +2 -2 + NTP_4_2_7P343 + + ntpq/ntpq-opts.c@1.348 +6 -6 + NTP_4_2_7P343 + + ntpq/ntpq-opts.h@1.348 +4 -4 + NTP_4_2_7P343 + + ntpq/ntpq.1ntpqman@1.162 +3 -3 + NTP_4_2_7P343 + + ntpq/ntpq.1ntpqmdoc@1.162 +3 -3 + NTP_4_2_7P343 + + ntpq/ntpq.html@1.8 +2 -2 + NTP_4_2_7P343 + + ntpq/ntpq.man.in@1.162 +3 -3 + NTP_4_2_7P343 + + ntpq/ntpq.mdoc.in@1.162 +3 -3 + NTP_4_2_7P343 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.333 +2 -2 + NTP_4_2_7P343 + + ntpsnmpd/ntpsnmpd-opts.c@1.348 +6 -6 + NTP_4_2_7P343 + + ntpsnmpd/ntpsnmpd-opts.h@1.348 +4 -4 + NTP_4_2_7P343 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.162 +3 -3 + NTP_4_2_7P343 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.162 +3 -3 + NTP_4_2_7P343 + + ntpsnmpd/ntpsnmpd.html@1.6 +1 -1 + NTP_4_2_7P343 + + ntpsnmpd/ntpsnmpd.man.in@1.162 +3 -3 + NTP_4_2_7P343 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.162 +3 -3 + NTP_4_2_7P343 + + packageinfo.sh@1.346 +1 -1 + NTP_4_2_7P343 + + scripts/invoke-ntp-wait.texi@1.150 +1 -1 + NTP_4_2_7P343 + + scripts/ntp-wait.1ntp-waitman@1.161 +3 -3 + NTP_4_2_7P343 + + scripts/ntp-wait.1ntp-waitmdoc@1.161 +3 -3 + NTP_4_2_7P343 + + scripts/ntp-wait.html@1.166 +1 -1 + NTP_4_2_7P343 + + scripts/ntp-wait.man.in@1.161 +3 -3 + NTP_4_2_7P343 + + scripts/ntp-wait.mdoc.in@1.161 +3 -3 + NTP_4_2_7P343 + + sntp/invoke-sntp.texi@1.330 +2 -2 + NTP_4_2_7P343 + + sntp/sntp-opts.c@1.345 +6 -6 + NTP_4_2_7P343 + + sntp/sntp-opts.h@1.345 +4 -4 + NTP_4_2_7P343 + + sntp/sntp.1sntpman@1.165 +3 -3 + NTP_4_2_7P343 + + sntp/sntp.1sntpmdoc@1.165 +3 -3 + NTP_4_2_7P343 + + sntp/sntp.html@1.345 +2 -2 + NTP_4_2_7P343 + + sntp/sntp.man.in@1.165 +3 -3 + NTP_4_2_7P343 + + sntp/sntp.mdoc.in@1.165 +3 -3 + NTP_4_2_7P343 + + util/invoke-ntp-keygen.texi@1.334 +2 -2 + NTP_4_2_7P343 + + util/ntp-keygen-opts.c@1.348 +6 -6 + NTP_4_2_7P343 + + util/ntp-keygen-opts.h@1.348 +4 -4 + NTP_4_2_7P343 + + util/ntp-keygen.1ntp-keygenman@1.162 +3 -3 + NTP_4_2_7P343 + + util/ntp-keygen.1ntp-keygenmdoc@1.162 +3 -3 + NTP_4_2_7P343 + + util/ntp-keygen.html@1.12 +2 -2 + NTP_4_2_7P343 + + util/ntp-keygen.man.in@1.162 +3 -3 + NTP_4_2_7P343 + + util/ntp-keygen.mdoc.in@1.162 +3 -3 + NTP_4_2_7P343 + +ChangeSet@1.2865.1.6, 2012-12-31 20:47:19-05:00, stenn@deacon.udel.edu + Update the copyright year + + ChangeLog@1.1222.1.5 +1 -0 + Update the copyright year + + html/copyright.html@1.61 +1 -1 + Update the copyright year + + sntp/include/copyright.def@1.21 +1 -1 + Update the copyright year + +ChangeSet@1.2865.1.5, 2012-12-31 09:25:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P342 + TAG: NTP_4_2_7P342 + + ChangeLog@1.1222.1.4 +1 -0 + NTP_4_2_7P342 + + ntpd/invoke-ntp.conf.texi@1.16 +1 -1 + NTP_4_2_7P342 + + ntpd/invoke-ntp.keys.texi@1.16 +1 -1 + NTP_4_2_7P342 + + ntpd/invoke-ntpd.texi@1.332 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.conf.5man@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.conf.5mdoc@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.conf.html@1.15 +1 -1 + NTP_4_2_7P342 + + ntpd/ntp.conf.man.in@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.conf.mdoc.in@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.keys.5man@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.keys.5mdoc@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.keys.html@1.16 +1 -1 + NTP_4_2_7P342 + + ntpd/ntp.keys.man.in@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntp.keys.mdoc.in@1.50 +2 -2 + NTP_4_2_7P342 + + ntpd/ntpd-opts.c@1.350 +4 -4 + NTP_4_2_7P342 + + ntpd/ntpd-opts.h@1.350 +3 -3 + NTP_4_2_7P342 + + ntpd/ntpd.1ntpdman@1.161 +2 -2 + NTP_4_2_7P342 + + ntpd/ntpd.1ntpdmdoc@1.161 +2 -2 + NTP_4_2_7P342 + + ntpd/ntpd.html@1.10 +2 -2 + NTP_4_2_7P342 + + ntpd/ntpd.man.in@1.161 +2 -2 + NTP_4_2_7P342 + + ntpd/ntpd.mdoc.in@1.161 +2 -2 + NTP_4_2_7P342 + + ntpdc/invoke-ntpdc.texi@1.329 +2 -2 + NTP_4_2_7P342 + + ntpdc/ntpdc-opts.c@1.344 +4 -4 + NTP_4_2_7P342 + + ntpdc/ntpdc-opts.h@1.344 +3 -3 + NTP_4_2_7P342 + + ntpdc/ntpdc.1ntpdcman@1.160 +2 -2 + NTP_4_2_7P342 + + ntpdc/ntpdc.1ntpdcmdoc@1.160 +2 -2 + NTP_4_2_7P342 + + ntpdc/ntpdc.html@1.173 +2 -2 + NTP_4_2_7P342 + + ntpdc/ntpdc.man.in@1.160 +2 -2 + NTP_4_2_7P342 + + ntpdc/ntpdc.mdoc.in@1.160 +2 -2 + NTP_4_2_7P342 + + ntpq/invoke-ntpq.texi@1.333 +2 -2 + NTP_4_2_7P342 + + ntpq/ntpq-opts.c@1.347 +4 -4 + NTP_4_2_7P342 + + ntpq/ntpq-opts.h@1.347 +3 -3 + NTP_4_2_7P342 + + ntpq/ntpq.1ntpqman@1.161 +2 -2 + NTP_4_2_7P342 + + ntpq/ntpq.1ntpqmdoc@1.161 +2 -2 + NTP_4_2_7P342 + + ntpq/ntpq.html@1.7 +2 -2 + NTP_4_2_7P342 + + ntpq/ntpq.man.in@1.161 +2 -2 + NTP_4_2_7P342 + + ntpq/ntpq.mdoc.in@1.161 +2 -2 + NTP_4_2_7P342 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.332 +2 -2 + NTP_4_2_7P342 + + ntpsnmpd/ntpsnmpd-opts.c@1.347 +4 -4 + NTP_4_2_7P342 + + ntpsnmpd/ntpsnmpd-opts.h@1.347 +3 -3 + NTP_4_2_7P342 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.161 +2 -2 + NTP_4_2_7P342 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.161 +2 -2 + NTP_4_2_7P342 + + ntpsnmpd/ntpsnmpd.html@1.5 +1 -1 + NTP_4_2_7P342 + + ntpsnmpd/ntpsnmpd.man.in@1.161 +2 -2 + NTP_4_2_7P342 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.161 +2 -2 + NTP_4_2_7P342 + + packageinfo.sh@1.345 +1 -1 + NTP_4_2_7P342 + + scripts/invoke-ntp-wait.texi@1.149 +1 -1 + NTP_4_2_7P342 + + scripts/ntp-wait.1ntp-waitman@1.160 +2 -2 + NTP_4_2_7P342 + + scripts/ntp-wait.1ntp-waitmdoc@1.160 +2 -2 + NTP_4_2_7P342 + + scripts/ntp-wait.html@1.165 +1 -1 + NTP_4_2_7P342 + + scripts/ntp-wait.man.in@1.160 +2 -2 + NTP_4_2_7P342 + + scripts/ntp-wait.mdoc.in@1.160 +2 -2 + NTP_4_2_7P342 + + sntp/invoke-sntp.texi@1.329 +2 -2 + NTP_4_2_7P342 + + sntp/sntp-opts.c@1.344 +4 -4 + NTP_4_2_7P342 + + sntp/sntp-opts.h@1.344 +3 -3 + NTP_4_2_7P342 + + sntp/sntp.1sntpman@1.164 +2 -2 + NTP_4_2_7P342 + + sntp/sntp.1sntpmdoc@1.164 +2 -2 + NTP_4_2_7P342 + + sntp/sntp.html@1.344 +2 -2 + NTP_4_2_7P342 + + sntp/sntp.man.in@1.164 +2 -2 + NTP_4_2_7P342 + + sntp/sntp.mdoc.in@1.164 +2 -2 + NTP_4_2_7P342 + + util/invoke-ntp-keygen.texi@1.333 +2 -2 + NTP_4_2_7P342 + + util/ntp-keygen-opts.c@1.347 +4 -4 + NTP_4_2_7P342 + + util/ntp-keygen-opts.h@1.347 +3 -3 + NTP_4_2_7P342 + + util/ntp-keygen.1ntp-keygenman@1.161 +2 -2 + NTP_4_2_7P342 + + util/ntp-keygen.1ntp-keygenmdoc@1.161 +2 -2 + NTP_4_2_7P342 + + util/ntp-keygen.html@1.11 +2 -2 + NTP_4_2_7P342 + + util/ntp-keygen.man.in@1.161 +2 -2 + NTP_4_2_7P342 + + util/ntp-keygen.mdoc.in@1.161 +2 -2 + NTP_4_2_7P342 + +ChangeSet@1.2865.1.3, 2012-12-30 16:01:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P341 + TAG: NTP_4_2_7P341 + + ChangeLog@1.1222.1.2 +1 -0 + NTP_4_2_7P341 + + ntpd/invoke-ntp.conf.texi@1.15 +1 -1 + NTP_4_2_7P341 + + ntpd/invoke-ntp.keys.texi@1.15 +1 -1 + NTP_4_2_7P341 + + ntpd/invoke-ntpd.texi@1.331 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.conf.5man@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.conf.5mdoc@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.conf.html@1.14 +1 -13 + NTP_4_2_7P341 + + ntpd/ntp.conf.man.in@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.conf.mdoc.in@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.keys.5man@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.keys.5mdoc@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.keys.html@1.15 +1 -1 + NTP_4_2_7P341 + + ntpd/ntp.keys.man.in@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntp.keys.mdoc.in@1.49 +2 -2 + NTP_4_2_7P341 + + ntpd/ntpd-opts.c@1.349 +4 -4 + NTP_4_2_7P341 + + ntpd/ntpd-opts.h@1.349 +3 -3 + NTP_4_2_7P341 + + ntpd/ntpd.1ntpdman@1.160 +2 -2 + NTP_4_2_7P341 + + ntpd/ntpd.1ntpdmdoc@1.160 +2 -2 + NTP_4_2_7P341 + + ntpd/ntpd.html@1.9 +2 -2 + NTP_4_2_7P341 + + ntpd/ntpd.man.in@1.160 +2 -2 + NTP_4_2_7P341 + + ntpd/ntpd.mdoc.in@1.160 +2 -2 + NTP_4_2_7P341 + + ntpdc/invoke-ntpdc.texi@1.328 +2 -2 + NTP_4_2_7P341 + + ntpdc/ntpdc-opts.c@1.343 +4 -4 + NTP_4_2_7P341 + + ntpdc/ntpdc-opts.h@1.343 +3 -3 + NTP_4_2_7P341 + + ntpdc/ntpdc.1ntpdcman@1.159 +2 -2 + NTP_4_2_7P341 + + ntpdc/ntpdc.1ntpdcmdoc@1.159 +2 -2 + NTP_4_2_7P341 + + ntpdc/ntpdc.html@1.172 +2 -2 + NTP_4_2_7P341 + + ntpdc/ntpdc.man.in@1.159 +2 -2 + NTP_4_2_7P341 + + ntpdc/ntpdc.mdoc.in@1.159 +2 -2 + NTP_4_2_7P341 + + ntpq/invoke-ntpq.texi@1.332 +2 -2 + NTP_4_2_7P341 + + ntpq/ntpq-opts.c@1.346 +4 -4 + NTP_4_2_7P341 + + ntpq/ntpq-opts.h@1.346 +3 -3 + NTP_4_2_7P341 + + ntpq/ntpq.1ntpqman@1.160 +2 -2 + NTP_4_2_7P341 + + ntpq/ntpq.1ntpqmdoc@1.160 +2 -2 + NTP_4_2_7P341 + + ntpq/ntpq.html@1.6 +2 -4 + NTP_4_2_7P341 + + ntpq/ntpq.man.in@1.160 +2 -2 + NTP_4_2_7P341 + + ntpq/ntpq.mdoc.in@1.160 +2 -2 + NTP_4_2_7P341 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.331 +2 -2 + NTP_4_2_7P341 + + ntpsnmpd/ntpsnmpd-opts.c@1.346 +4 -4 + NTP_4_2_7P341 + + ntpsnmpd/ntpsnmpd-opts.h@1.346 +3 -3 + NTP_4_2_7P341 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.160 +2 -2 + NTP_4_2_7P341 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.160 +2 -2 + NTP_4_2_7P341 + + ntpsnmpd/ntpsnmpd.html@1.4 +1 -1 + NTP_4_2_7P341 + + ntpsnmpd/ntpsnmpd.man.in@1.160 +2 -2 + NTP_4_2_7P341 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.160 +2 -2 + NTP_4_2_7P341 + + packageinfo.sh@1.344 +1 -1 + NTP_4_2_7P341 + + scripts/invoke-ntp-wait.texi@1.148 +1 -1 + NTP_4_2_7P341 + + scripts/ntp-wait.1ntp-waitman@1.159 +2 -2 + NTP_4_2_7P341 + + scripts/ntp-wait.1ntp-waitmdoc@1.159 +2 -2 + NTP_4_2_7P341 + + scripts/ntp-wait.html@1.164 +1 -1 + NTP_4_2_7P341 + + scripts/ntp-wait.man.in@1.159 +2 -2 + NTP_4_2_7P341 + + scripts/ntp-wait.mdoc.in@1.159 +2 -2 + NTP_4_2_7P341 + + sntp/invoke-sntp.texi@1.328 +2 -2 + NTP_4_2_7P341 + + sntp/sntp-opts.c@1.343 +4 -4 + NTP_4_2_7P341 + + sntp/sntp-opts.h@1.343 +3 -3 + NTP_4_2_7P341 + + sntp/sntp.1sntpman@1.163 +2 -2 + NTP_4_2_7P341 + + sntp/sntp.1sntpmdoc@1.163 +2 -2 + NTP_4_2_7P341 + + sntp/sntp.html@1.343 +2 -2 + NTP_4_2_7P341 + + sntp/sntp.man.in@1.163 +2 -2 + NTP_4_2_7P341 + + sntp/sntp.mdoc.in@1.163 +2 -2 + NTP_4_2_7P341 + + util/invoke-ntp-keygen.texi@1.332 +2 -2 + NTP_4_2_7P341 + + util/ntp-keygen-opts.c@1.346 +4 -4 + NTP_4_2_7P341 + + util/ntp-keygen-opts.h@1.346 +3 -3 + NTP_4_2_7P341 + + util/ntp-keygen.1ntp-keygenman@1.160 +2 -2 + NTP_4_2_7P341 + + util/ntp-keygen.1ntp-keygenmdoc@1.160 +2 -2 + NTP_4_2_7P341 + + util/ntp-keygen.html@1.10 +2 -3 + NTP_4_2_7P341 + + util/ntp-keygen.man.in@1.160 +2 -2 + NTP_4_2_7P341 + + util/ntp-keygen.mdoc.in@1.160 +2 -2 + NTP_4_2_7P341 + +ChangeSet@1.2865.1.2, 2012-12-29 19:57:16-05:00, stenn@deacon.udel.edu + Fix permissions on ntpsnmpd/netsnmp_daemonize.c + + ntpsnmpd/netsnmp_daemonize.c@1.4 +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.2865.1.1, 2012-12-29 09:30:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P340 + TAG: NTP_4_2_7P340 + + ChangeLog@1.1222.1.1 +1 -0 + NTP_4_2_7P340 + + ntpd/invoke-ntp.conf.texi@1.14 +1 -13 + NTP_4_2_7P340 + + ntpd/invoke-ntp.keys.texi@1.14 +1 -1 + NTP_4_2_7P340 + + ntpd/invoke-ntpd.texi@1.330 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.conf.5man@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.conf.5mdoc@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.conf.html@1.13 +451 -126 + NTP_4_2_7P340 + + ntpd/ntp.conf.man.in@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.conf.mdoc.in@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.keys.5man@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.keys.5mdoc@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.keys.html@1.14 +6 -5 + NTP_4_2_7P340 + + ntpd/ntp.keys.man.in@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntp.keys.mdoc.in@1.48 +2 -2 + NTP_4_2_7P340 + + ntpd/ntpd-opts.c@1.348 +4 -4 + NTP_4_2_7P340 + + ntpd/ntpd-opts.h@1.348 +3 -3 + NTP_4_2_7P340 + + ntpd/ntpd.1ntpdman@1.159 +2 -2 + NTP_4_2_7P340 + + ntpd/ntpd.1ntpdmdoc@1.159 +2 -2 + NTP_4_2_7P340 + + ntpd/ntpd.html@1.8 +8 -8 + NTP_4_2_7P340 + + ntpd/ntpd.man.in@1.159 +2 -2 + NTP_4_2_7P340 + + ntpd/ntpd.mdoc.in@1.159 +2 -2 + NTP_4_2_7P340 + + ntpdc/invoke-ntpdc.texi@1.327 +2 -3 + NTP_4_2_7P340 + + ntpdc/ntpdc-opts.c@1.342 +4 -4 + NTP_4_2_7P340 + + ntpdc/ntpdc-opts.h@1.342 +3 -3 + NTP_4_2_7P340 + + ntpdc/ntpdc.1ntpdcman@1.158 +2 -2 + NTP_4_2_7P340 + + ntpdc/ntpdc.1ntpdcmdoc@1.158 +2 -2 + NTP_4_2_7P340 + + ntpdc/ntpdc.html@1.171 +2 -3 + NTP_4_2_7P340 + + ntpdc/ntpdc.man.in@1.158 +2 -2 + NTP_4_2_7P340 + + ntpdc/ntpdc.mdoc.in@1.158 +2 -2 + NTP_4_2_7P340 + + ntpq/invoke-ntpq.texi@1.331 +2 -4 + NTP_4_2_7P340 + + ntpq/ntpq-opts.c@1.345 +4 -4 + NTP_4_2_7P340 + + ntpq/ntpq-opts.h@1.345 +3 -3 + NTP_4_2_7P340 + + ntpq/ntpq.1ntpqman@1.159 +2 -2 + NTP_4_2_7P340 + + ntpq/ntpq.1ntpqmdoc@1.159 +2 -2 + NTP_4_2_7P340 + + ntpq/ntpq.html@1.5 +6 -4 + NTP_4_2_7P340 + + ntpq/ntpq.man.in@1.159 +2 -2 + NTP_4_2_7P340 + + ntpq/ntpq.mdoc.in@1.159 +2 -2 + NTP_4_2_7P340 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.330 +2 -3 + NTP_4_2_7P340 + + ntpsnmpd/ntpsnmpd-opts.c@1.345 +4 -4 + NTP_4_2_7P340 + + ntpsnmpd/ntpsnmpd-opts.h@1.345 +3 -3 + NTP_4_2_7P340 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.159 +2 -2 + NTP_4_2_7P340 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.159 +2 -2 + NTP_4_2_7P340 + + ntpsnmpd/ntpsnmpd.html@1.3 +1 -1 + NTP_4_2_7P340 + + ntpsnmpd/ntpsnmpd.man.in@1.159 +2 -2 + NTP_4_2_7P340 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.159 +2 -2 + NTP_4_2_7P340 + + packageinfo.sh@1.343 +1 -1 + NTP_4_2_7P340 + + scripts/invoke-ntp-wait.texi@1.147 +1 -1 + NTP_4_2_7P340 + + scripts/ntp-wait.1ntp-waitman@1.158 +2 -2 + NTP_4_2_7P340 + + scripts/ntp-wait.1ntp-waitmdoc@1.158 +2 -2 + NTP_4_2_7P340 + + scripts/ntp-wait.html@1.163 +1 -1 + NTP_4_2_7P340 + + scripts/ntp-wait.man.in@1.158 +2 -2 + NTP_4_2_7P340 + + scripts/ntp-wait.mdoc.in@1.158 +2 -2 + NTP_4_2_7P340 + + sntp/invoke-sntp.texi@1.327 +3 -3 + NTP_4_2_7P340 + + sntp/sntp-opts.c@1.342 +4 -4 + NTP_4_2_7P340 + + sntp/sntp-opts.h@1.342 +3 -3 + NTP_4_2_7P340 + + sntp/sntp.1sntpman@1.162 +2 -2 + NTP_4_2_7P340 + + sntp/sntp.1sntpmdoc@1.162 +2 -2 + NTP_4_2_7P340 + + sntp/sntp.html@1.342 +3 -3 + NTP_4_2_7P340 + + sntp/sntp.man.in@1.162 +2 -2 + NTP_4_2_7P340 + + sntp/sntp.mdoc.in@1.162 +2 -2 + NTP_4_2_7P340 + + util/invoke-ntp-keygen.texi@1.331 +2 -3 + NTP_4_2_7P340 + + util/ntp-keygen-opts.c@1.345 +4 -4 + NTP_4_2_7P340 + + util/ntp-keygen-opts.h@1.345 +3 -3 + NTP_4_2_7P340 + + util/ntp-keygen.1ntp-keygenman@1.159 +2 -2 + NTP_4_2_7P340 + + util/ntp-keygen.1ntp-keygenmdoc@1.159 +2 -2 + NTP_4_2_7P340 + + util/ntp-keygen.html@1.9 +214 -213 + NTP_4_2_7P340 + + util/ntp-keygen.man.in@1.159 +2 -2 + NTP_4_2_7P340 + + util/ntp-keygen.mdoc.in@1.159 +2 -2 + NTP_4_2_7P340 + +ChangeSet@1.2863.2.1, 2012-12-29 06:47:23+00:00, stenn@psp-fb1.ntp.org + mdoc2texi: fix trailing punctuation handlers + + ChangeLog@1.1220.2.1 +2 -1 + mdoc2texi: fix trailing punctuation handlers + + sntp/ag-tpl/mdoc2texi@1.6 +16 -5 + mdoc2texi: fix trailing punctuation handlers + +ChangeSet@1.2863.1.1, 2012-12-28 11:41:12+00:00, stenn@psp-fb1.ntp.org + Upgrade to autogen-5.17 and libopts-37.0.12 + + ChangeLog@1.1220.1.1 +1 -0 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/include/autogen-version.def@1.13 +1 -1 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/Makefile.am@1.16 +9 -8 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/ag-char-map.h@1.19 +23 -6 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/alias.c@1.3 +0 -2 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/ao-strs.c@1.5 +201 -191 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/ao-strs.h@1.4 +210 -208 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/autoopts.c@1.14 +58 -370 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/autoopts.h@1.12 +38 -7 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/autoopts/options.h@1.18 +218 -307 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/autoopts/usage-txt.h@1.18 +531 -270 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/boolean.c@1.11 +0 -2 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/check.c@1.4 +0 -2 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/compat/compat.h@1.11 +0 -2 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/compat/pathfind.c@1.9 +18 -16 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/compat/snprintf.c@1.3 +2 -0 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/compat/strchr.c@1.3 +10 -4 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/compat/strdup.c@1.3 +3 -0 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/compat/windows-config.h@1.10 +0 -2 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/configfile.c@1.16 +349 -422 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/cook.c@1.11 +8 -9 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/enum.c@1.6 +11 -12 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/env.c@1.5 +12 -14 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/file.c@1.11 +1 -3 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/find.c@1.5 +248 -45 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/genshell.c@1.19 +63 -41 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/genshell.h@1.19 +7 -6 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/gettext.h@1.1 +288 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen-5.17/sntp/libopts/gettext.h + + sntp/libopts/gettext.h@1.0 +0 -0 + + sntp/libopts/init.c@1.1 +292 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen-5.17/sntp/libopts/init.c + + sntp/libopts/init.c@1.0 +0 -0 + + sntp/libopts/libopts.c@1.8 +5 -4 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/load.c@1.14 +21 -15 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/m4/libopts.m4@1.22 +1 -3 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/m4/liboptschk.m4@1.10 +0 -2 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/makeshell.c@1.13 +220 -177 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/nested.c@1.10 +334 -269 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/numeric.c@1.10 +1 -3 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/option-value-type.c@1.6 +115 -82 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/option-value-type.c@1.5 +0 -0 + Rename: sntp/libopts/value-type.c -> sntp/libopts/option-value-type.c + + sntp/libopts/option-value-type.h@1.20 +54 -21 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/option-value-type.h@1.19 +0 -0 + Rename: sntp/libopts/value-type.h -> sntp/libopts/option-value-type.h + + sntp/libopts/option-xat-attribute.c@1.6 +106 -72 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/option-xat-attribute.c@1.5 +0 -0 + Rename: sntp/libopts/xat-attribute.c -> sntp/libopts/option-xat-attribute.c + + sntp/libopts/option-xat-attribute.h@1.20 +51 -18 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/option-xat-attribute.h@1.19 +0 -0 + Rename: sntp/libopts/xat-attribute.h -> sntp/libopts/option-xat-attribute.h + + sntp/libopts/parse-duration.c@1.9 +6 -6 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/pgusage.c@1.11 +18 -19 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/proto.h@1.19 +24 -15 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/putshell.c@1.10 +0 -2 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/reset.c@1.12 +1 -3 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/restore.c@1.9 +7 -8 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/save.c@1.12 +1 -3 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/sort.c@1.10 +5 -6 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/stack.c@1.11 +1 -3 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/streqvcmp.c@1.10 +1 -3 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/text_mmap.c@1.11 +2 -4 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/time.c@1.11 +3 -5 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/tokenize.c@1.8 +2 -4 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/usage.c@1.12 +114 -109 + Upgrade to autogen-5.17 and libopts-37.0.12 + + sntp/libopts/version.c@1.12 +3 -5 + Upgrade to autogen-5.17 and libopts-37.0.12 + +ChangeSet@1.2857.1.2, 2012-12-27 20:14:04-05:00, murray@pogo.udel.edu + monopt.html: + Fix for bug-2801 + + html/monopt.html@1.35 +53 -9 + Fix for bug-2801 + +ChangeSet@1.2857.1.1, 2012-12-27 20:09:00-05:00, murray@pogo.udel.edu + ntp_util.c, ntpd.h, ChangeLog, ntp_proto.c: + Fix for bug 2081 + + ChangeLog@1.1214.1.1 +1 -0 + Fix for bug 2081 + + include/ntpd.h@1.172 +1 -1 + Fix for bug 2081 + + ntpd/ntp_proto.c@1.344 +6 -3 + Fix for bug 2081 + + ntpd/ntp_util.c@1.98 +18 -5 + Fix for bug 2081 + +ChangeSet@1.2864, 2012-12-26 04:12:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P339 + TAG: NTP_4_2_7P339 + + ChangeLog@1.1221 +1 -0 + NTP_4_2_7P339 + + ntpd/invoke-ntp.conf.texi@1.13 +36 -39 + NTP_4_2_7P339 + + ntpd/invoke-ntp.keys.texi@1.13 +2 -3 + NTP_4_2_7P339 + + ntpd/invoke-ntpd.texi@1.329 +3 -4 + NTP_4_2_7P339 + + ntpd/ntp.conf.5man@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntp.conf.5mdoc@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntp.conf.html@1.12 +114 -155 + NTP_4_2_7P339 + + ntpd/ntp.conf.man.in@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntp.conf.mdoc.in@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntp.keys.5man@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntp.keys.5mdoc@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntp.keys.html@1.13 +9 -9 + NTP_4_2_7P339 + + ntpd/ntp.keys.man.in@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntp.keys.mdoc.in@1.47 +2 -2 + NTP_4_2_7P339 + + ntpd/ntpd-opts.c@1.347 +4 -4 + NTP_4_2_7P339 + + ntpd/ntpd-opts.h@1.347 +3 -3 + NTP_4_2_7P339 + + ntpd/ntpd.1ntpdman@1.158 +2 -2 + NTP_4_2_7P339 + + ntpd/ntpd.1ntpdmdoc@1.158 +2 -2 + NTP_4_2_7P339 + + ntpd/ntpd.html@1.7 +123 -177 + NTP_4_2_7P339 + + ntpd/ntpd.man.in@1.158 +2 -2 + NTP_4_2_7P339 + + ntpd/ntpd.mdoc.in@1.158 +2 -2 + NTP_4_2_7P339 + + ntpdc/invoke-ntpdc.texi@1.326 +7 -9 + NTP_4_2_7P339 + + ntpdc/ntpdc-opts.c@1.341 +4 -4 + NTP_4_2_7P339 + + ntpdc/ntpdc-opts.h@1.341 +3 -3 + NTP_4_2_7P339 + + ntpdc/ntpdc.1ntpdcman@1.157 +2 -2 + NTP_4_2_7P339 + + ntpdc/ntpdc.1ntpdcmdoc@1.157 +2 -2 + NTP_4_2_7P339 + + ntpdc/ntpdc.html@1.170 +77 -603 + NTP_4_2_7P339 + + ntpdc/ntpdc.man.in@1.157 +2 -2 + NTP_4_2_7P339 + + ntpdc/ntpdc.mdoc.in@1.157 +2 -2 + NTP_4_2_7P339 + + ntpq/invoke-ntpq.texi@1.330 +6 -4 + NTP_4_2_7P339 + + ntpq/ntpq-opts.c@1.344 +4 -4 + NTP_4_2_7P339 + + ntpq/ntpq-opts.h@1.344 +3 -3 + NTP_4_2_7P339 + + ntpq/ntpq.1ntpqman@1.158 +2 -260 + NTP_4_2_7P339 + + ntpq/ntpq.1ntpqmdoc@1.158 +3 -246 + NTP_4_2_7P339 + + ntpq/ntpq.html@1.4 +281 -304 + NTP_4_2_7P339 + + ntpq/ntpq.man.in@1.158 +2 -260 + NTP_4_2_7P339 + + ntpq/ntpq.mdoc.in@1.158 +3 -246 + NTP_4_2_7P339 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.329 +3 -4 + NTP_4_2_7P339 + + ntpsnmpd/ntpsnmpd-opts.c@1.344 +4 -4 + NTP_4_2_7P339 + + ntpsnmpd/ntpsnmpd-opts.h@1.344 +3 -3 + NTP_4_2_7P339 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.158 +2 -56 + NTP_4_2_7P339 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.158 +3 -49 + NTP_4_2_7P339 + + ntpsnmpd/ntpsnmpd.html@1.2 +10 -15 + NTP_4_2_7P339 + + ntpsnmpd/ntpsnmpd.man.in@1.158 +2 -56 + NTP_4_2_7P339 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.158 +3 -49 + NTP_4_2_7P339 + + packageinfo.sh@1.342 +1 -1 + NTP_4_2_7P339 + + scripts/invoke-ntp-wait.texi@1.146 +2 -1 + NTP_4_2_7P339 + + scripts/ntp-wait.1ntp-waitman@1.157 +2 -2 + NTP_4_2_7P339 + + scripts/ntp-wait.1ntp-waitmdoc@1.157 +1 -1 + NTP_4_2_7P339 + + scripts/ntp-wait.html@1.162 +39 -60 + NTP_4_2_7P339 + + scripts/ntp-wait.man.in@1.157 +2 -2 + NTP_4_2_7P339 + + scripts/ntp-wait.mdoc.in@1.157 +1 -1 + NTP_4_2_7P339 + + sntp/invoke-sntp.texi@1.326 +4 -4 + NTP_4_2_7P339 + + sntp/sntp-opts.c@1.341 +4 -4 + NTP_4_2_7P339 + + sntp/sntp-opts.h@1.341 +3 -3 + NTP_4_2_7P339 + + sntp/sntp.1sntpman@1.161 +2 -2 + NTP_4_2_7P339 + + sntp/sntp.1sntpmdoc@1.161 +2 -2 + NTP_4_2_7P339 + + sntp/sntp.html@1.341 +15 -14 + NTP_4_2_7P339 + + sntp/sntp.man.in@1.161 +2 -2 + NTP_4_2_7P339 + + sntp/sntp.mdoc.in@1.161 +2 -2 + NTP_4_2_7P339 + + util/invoke-ntp-keygen.texi@1.330 +5 -5 + NTP_4_2_7P339 + + util/ntp-keygen-opts.c@1.344 +4 -4 + NTP_4_2_7P339 + + util/ntp-keygen-opts.h@1.344 +3 -3 + NTP_4_2_7P339 + + util/ntp-keygen.1ntp-keygenman@1.158 +2 -2 + NTP_4_2_7P339 + + util/ntp-keygen.1ntp-keygenmdoc@1.158 +2 -2 + NTP_4_2_7P339 + + util/ntp-keygen.html@1.8 +121 -181 + NTP_4_2_7P339 + + util/ntp-keygen.man.in@1.158 +2 -2 + NTP_4_2_7P339 + + util/ntp-keygen.mdoc.in@1.158 +2 -2 + NTP_4_2_7P339 + +ChangeSet@1.2860.1.1, 2012-12-25 11:36:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P338 + TAG: NTP_4_2_7P338 + + ChangeLog@1.1217.1.1 +1 -0 + NTP_4_2_7P338 + + ntpd/invoke-ntp.conf.texi@1.12 +118 -160 + NTP_4_2_7P338 + + ntpd/invoke-ntp.keys.texi@1.12 +9 -9 + NTP_4_2_7P338 + + ntpd/invoke-ntpd.texi@1.328 +4 -8 + NTP_4_2_7P338 + + ntpd/ntp.conf.5man@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntp.conf.5mdoc@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntp.conf.html@1.11 +1 -1 + NTP_4_2_7P338 + + ntpd/ntp.conf.man.in@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntp.conf.mdoc.in@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntp.keys.5man@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntp.keys.5mdoc@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntp.keys.html@1.12 +1 -1 + NTP_4_2_7P338 + + ntpd/ntp.keys.man.in@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntp.keys.mdoc.in@1.46 +2 -2 + NTP_4_2_7P338 + + ntpd/ntpd-opts.c@1.346 +4 -4 + NTP_4_2_7P338 + + ntpd/ntpd-opts.h@1.346 +3 -3 + NTP_4_2_7P338 + + ntpd/ntpd.1ntpdman@1.157 +2 -2 + NTP_4_2_7P338 + + ntpd/ntpd.1ntpdmdoc@1.157 +2 -2 + NTP_4_2_7P338 + + ntpd/ntpd.html@1.4.1.1 +1 -1 + NTP_4_2_7P338 + + ntpd/ntpd.man.in@1.157 +2 -2 + NTP_4_2_7P338 + + ntpd/ntpd.mdoc.in@1.157 +2 -2 + NTP_4_2_7P338 + + ntpdc/invoke-ntpdc.texi@1.325 +26 -31 + NTP_4_2_7P338 + + ntpdc/ntpdc-opts.c@1.340 +4 -4 + NTP_4_2_7P338 + + ntpdc/ntpdc-opts.h@1.340 +3 -3 + NTP_4_2_7P338 + + ntpdc/ntpdc.1ntpdcman@1.156 +2 -2 + NTP_4_2_7P338 + + ntpdc/ntpdc.1ntpdcmdoc@1.156 +2 -2 + NTP_4_2_7P338 + + ntpdc/ntpdc.html@1.167.1.1 +5 -5 + NTP_4_2_7P338 + + ntpdc/ntpdc.man.in@1.156 +2 -2 + NTP_4_2_7P338 + + ntpdc/ntpdc.mdoc.in@1.156 +2 -2 + NTP_4_2_7P338 + + ntpq/invoke-ntpq.texi@1.327.1.1 +7 -7 + NTP_4_2_7P338 + + ntpq/ntpq-opts.c@1.341.1.1 +4 -4 + NTP_4_2_7P338 + + ntpq/ntpq-opts.h@1.341.1.1 +3 -3 + NTP_4_2_7P338 + + ntpq/ntpq.1ntpqman@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + ntpq/ntpq.1ntpqmdoc@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + ntpq/ntpq.html@1.1.1.1 +717 -195 + NTP_4_2_7P338 + + ntpq/ntpq.man.in@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + ntpq/ntpq.mdoc.in@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.326.1.1 +2 -2 + NTP_4_2_7P338 + + ntpsnmpd/ntpsnmpd-opts.c@1.341.1.1 +4 -4 + NTP_4_2_7P338 + + ntpsnmpd/ntpsnmpd-opts.h@1.341.1.1 +3 -3 + NTP_4_2_7P338 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + ntpsnmpd/ntpsnmpd.man.in@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.155.1.1 +2 -2 + NTP_4_2_7P338 + + packageinfo.sh@1.341 +1 -1 + NTP_4_2_7P338 + + scripts/invoke-ntp-wait.texi@1.145 +3 -3 + NTP_4_2_7P338 + + scripts/ntp-wait.1ntp-waitman@1.156 +2 -2 + NTP_4_2_7P338 + + scripts/ntp-wait.1ntp-waitmdoc@1.156 +2 -2 + NTP_4_2_7P338 + + scripts/ntp-wait.html@1.159.1.1 +3 -3 + NTP_4_2_7P338 + + scripts/ntp-wait.man.in@1.156 +2 -2 + NTP_4_2_7P338 + + scripts/ntp-wait.mdoc.in@1.156 +2 -2 + NTP_4_2_7P338 + + sntp/invoke-sntp.texi@1.325 +2 -2 + NTP_4_2_7P338 + + sntp/sntp-opts.c@1.340 +4 -4 + NTP_4_2_7P338 + + sntp/sntp-opts.h@1.340 +3 -3 + NTP_4_2_7P338 + + sntp/sntp.1sntpman@1.160 +2 -2 + NTP_4_2_7P338 + + sntp/sntp.1sntpmdoc@1.160 +2 -2 + NTP_4_2_7P338 + + sntp/sntp.html@1.340 +2 -2 + NTP_4_2_7P338 + + sntp/sntp.man.in@1.160 +2 -2 + NTP_4_2_7P338 + + sntp/sntp.mdoc.in@1.160 +2 -2 + NTP_4_2_7P338 + + util/invoke-ntp-keygen.texi@1.329 +2 -2 + NTP_4_2_7P338 + + util/ntp-keygen-opts.c@1.343 +4 -4 + NTP_4_2_7P338 + + util/ntp-keygen-opts.h@1.343 +3 -3 + NTP_4_2_7P338 + + util/ntp-keygen.1ntp-keygenman@1.157 +3 -853 + NTP_4_2_7P338 + + util/ntp-keygen.1ntp-keygenmdoc@1.157 +4 -840 + NTP_4_2_7P338 + + util/ntp-keygen.html@1.5.1.1 +210 -230 + NTP_4_2_7P338 + + util/ntp-keygen.man.in@1.157 +3 -853 + NTP_4_2_7P338 + + util/ntp-keygen.mdoc.in@1.157 +4 -840 + NTP_4_2_7P338 + +ChangeSet@1.2862, 2012-12-25 11:21:04+00:00, stenn@psp-fb1.ntp.org + mdoc2texi fixes: parseQuote, closing of list item tables + + ChangeLog@1.1219 +1 -0 + mdoc2texi fixes: parseQuote, closing of list item tables + + sntp/ag-tpl/mdoc2texi@1.5 +17 -7 + mdoc2texi fixes: parseQuote, closing of list item tables + +ChangeSet@1.2861, 2012-12-25 11:20:12+00:00, stenn@psp-fb1.ntp.org + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + .point-changed-filelist@1.20 +1 -0 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ChangeLog@1.1218 +1 -0 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpd/ntpd.html@1.5 +171 -121 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpd/ntpd.texi@1.2 +1 -1 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpdc/ntpdc.html@1.168 +598 -71 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpdc/ntpdc.texi@1.4 +1 -1 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/invoke-ntpq.texi@1.328 +9 -8 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq-opts.c@1.342 +1 -1 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq-opts.h@1.342 +1 -1 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq.1ntpqman@1.156 +260 -2 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq.1ntpqmdoc@1.156 +246 -3 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq.html@1.2 +662 -131 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq.man.in@1.156 +260 -2 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq.mdoc.in@1.156 +246 -3 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpq/ntpq.texi@1.3 +16 -21 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/Makefile.am@1.38 +12 -0 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/invoke-ntpsnmpd.texi@1.327 +61 -2 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd-opts.c@1.342 +1 -1 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd-opts.def@1.5 +47 -3 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd-opts.h@1.342 +1 -1 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.156 +60 -3 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.156 +53 -4 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd.html@1.1 +84 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpsnmpd/ntpsnmpd.html + + ntpsnmpd/ntpsnmpd.html@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.man.in@1.156 +60 -3 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd.mdoc.in@1.156 +53 -4 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + ntpsnmpd/ntpsnmpd.texi@1.1 +53 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpsnmpd/ntpsnmpd.texi + + ntpsnmpd/ntpsnmpd.texi@1.0 +0 -0 + + scripts/ntp-wait.html@1.160 +59 -37 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + scripts/ntp-wait.texi@1.4 +1 -1 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + + util/ntp-keygen.html@1.6 +429 -383 + ntp-wait, ntpd, ntpdc, ntpq, ntpsnmpd autogen documentation updates + +ChangeSet@1.2860, 2012-12-25 05:14:20+00:00, stenn@psp-fb1.ntp.org + mdoc2texi fixes: Handle_ArCmFlIc, Handle_Fn, HandleQ + + ChangeLog@1.1217 +1 -0 + mdoc2texi fixes: Handle_ArCmFlIc, Handle_Fn, HandleQ + + sntp/ag-tpl/mdoc2texi@1.4 +71 -10 + mdoc2texi fixes: Handle_ArCmFlIc, Handle_Fn, HandleQ. + +ChangeSet@1.2859, 2012-12-25 05:09:53+00:00, stenn@psp-fb1.ntp.org + ntp-keygen autogen documentation updates + + ChangeLog@1.1216 +1 -0 + ntp-keygen autogen documentation updates + + ntpq/ntpq.html@1.1 +902 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpq/ntpq.html + + ntpq/ntpq.html@1.0 +0 -0 + + util/invoke-ntp-keygen.texi@1.328 +82 -135 + ntp-keygen autogen documentation updates + + util/ntp-keygen-opts.c@1.342 +1 -1 + ntp-keygen autogen documentation updates + + util/ntp-keygen-opts.def@1.23 +31 -26 + ntp-keygen autogen documentation updates + + util/ntp-keygen-opts.h@1.342 +1 -1 + ntp-keygen autogen documentation updates + + util/ntp-keygen.1ntp-keygenman@1.156 +867 -16 + ntp-keygen autogen documentation updates + + util/ntp-keygen.1ntp-keygenmdoc@1.156 +854 -17 + ntp-keygen autogen documentation updates + + util/ntp-keygen.man.in@1.156 +867 -16 + ntp-keygen autogen documentation updates + + util/ntp-keygen.mdoc.in@1.156 +854 -17 + ntp-keygen autogen documentation updates + + util/ntp-keygen.texi@1.2 +115 -82 + ntp-keygen autogen documentation updates + +ChangeSet@1.2858, 2012-12-24 08:51:47+00:00, stenn@psp-fb1.ntp.org + ntpq autogen docs + + .point-changed-filelist@1.19 +1 -0 + ntpq autogen docs. + + ChangeLog@1.1215 +1 -0 + ntpq autogen docs. + + ntpq/Makefile.am@1.69 +14 -0 + ntpq autogen docs + + ntpq/invoke-ntpq.texi@1.327 +1 -1 + ntpq autogen docs + + ntpq/ntpq.texi@1.2 +29 -18 + ntpq autogen docs + + ntpq/ntpq.texi@1.1 +851 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpq/ntpq.texi + + ntpq/ntpq.texi@1.0 +0 -0 + +ChangeSet@1.2857, 2012-12-22 11:54:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P337 + TAG: NTP_4_2_7P337 + + ChangeLog@1.1214 +1 -0 + NTP_4_2_7P337 + + ntpd/invoke-ntp.conf.texi@1.11 +1 -1 + NTP_4_2_7P337 + + ntpd/invoke-ntp.keys.texi@1.11 +1 -1 + NTP_4_2_7P337 + + ntpd/invoke-ntpd.texi@1.327 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.conf.5man@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.conf.5mdoc@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.conf.html@1.10 +1 -1 + NTP_4_2_7P337 + + ntpd/ntp.conf.man.in@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.conf.mdoc.in@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.keys.5man@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.keys.5mdoc@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.keys.html@1.11 +1 -1 + NTP_4_2_7P337 + + ntpd/ntp.keys.man.in@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntp.keys.mdoc.in@1.45 +2 -2 + NTP_4_2_7P337 + + ntpd/ntpd-opts.c@1.345 +4 -4 + NTP_4_2_7P337 + + ntpd/ntpd-opts.h@1.345 +3 -3 + NTP_4_2_7P337 + + ntpd/ntpd.1ntpdman@1.156 +2 -2 + NTP_4_2_7P337 + + ntpd/ntpd.1ntpdmdoc@1.156 +2 -2 + NTP_4_2_7P337 + + ntpd/ntpd.html@1.4 +1 -1 + NTP_4_2_7P337 + + ntpd/ntpd.man.in@1.156 +2 -2 + NTP_4_2_7P337 + + ntpd/ntpd.mdoc.in@1.156 +2 -2 + NTP_4_2_7P337 + + ntpdc/invoke-ntpdc.texi@1.324 +2 -2 + NTP_4_2_7P337 + + ntpdc/ntpdc-opts.c@1.339 +4 -4 + NTP_4_2_7P337 + + ntpdc/ntpdc-opts.h@1.339 +3 -3 + NTP_4_2_7P337 + + ntpdc/ntpdc.1ntpdcman@1.155 +2 -2 + NTP_4_2_7P337 + + ntpdc/ntpdc.1ntpdcmdoc@1.155 +2 -2 + NTP_4_2_7P337 + + ntpdc/ntpdc.html@1.167 +2 -2 + NTP_4_2_7P337 + + ntpdc/ntpdc.man.in@1.155 +2 -2 + NTP_4_2_7P337 + + ntpdc/ntpdc.mdoc.in@1.155 +2 -2 + NTP_4_2_7P337 + + ntpq/invoke-ntpq.texi@1.326 +2 -2 + NTP_4_2_7P337 + + ntpq/ntpq-opts.c@1.341 +4 -4 + NTP_4_2_7P337 + + ntpq/ntpq-opts.h@1.341 +3 -3 + NTP_4_2_7P337 + + ntpq/ntpq.1ntpqman@1.155 +2 -2 + NTP_4_2_7P337 + + ntpq/ntpq.1ntpqmdoc@1.155 +2 -2 + NTP_4_2_7P337 + + ntpq/ntpq.man.in@1.155 +2 -2 + NTP_4_2_7P337 + + ntpq/ntpq.mdoc.in@1.155 +2 -2 + NTP_4_2_7P337 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.326 +2 -2 + NTP_4_2_7P337 + + ntpsnmpd/ntpsnmpd-opts.c@1.341 +4 -4 + NTP_4_2_7P337 + + ntpsnmpd/ntpsnmpd-opts.h@1.341 +3 -3 + NTP_4_2_7P337 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.155 +2 -2 + NTP_4_2_7P337 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.155 +2 -2 + NTP_4_2_7P337 + + ntpsnmpd/ntpsnmpd.man.in@1.155 +2 -2 + NTP_4_2_7P337 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.155 +2 -2 + NTP_4_2_7P337 + + packageinfo.sh@1.340 +1 -1 + NTP_4_2_7P337 + + scripts/invoke-ntp-wait.texi@1.144 +1 -1 + NTP_4_2_7P337 + + scripts/ntp-wait.1ntp-waitman@1.155 +2 -2 + NTP_4_2_7P337 + + scripts/ntp-wait.1ntp-waitmdoc@1.155 +2 -2 + NTP_4_2_7P337 + + scripts/ntp-wait.html@1.159 +1 -1 + NTP_4_2_7P337 + + scripts/ntp-wait.man.in@1.155 +2 -2 + NTP_4_2_7P337 + + scripts/ntp-wait.mdoc.in@1.155 +2 -2 + NTP_4_2_7P337 + + sntp/invoke-sntp.texi@1.324 +2 -2 + NTP_4_2_7P337 + + sntp/sntp-opts.c@1.339 +4 -4 + NTP_4_2_7P337 + + sntp/sntp-opts.h@1.339 +3 -3 + NTP_4_2_7P337 + + sntp/sntp.1sntpman@1.159 +2 -2 + NTP_4_2_7P337 + + sntp/sntp.1sntpmdoc@1.159 +2 -2 + NTP_4_2_7P337 + + sntp/sntp.html@1.339 +2 -2 + NTP_4_2_7P337 + + sntp/sntp.man.in@1.159 +2 -2 + NTP_4_2_7P337 + + sntp/sntp.mdoc.in@1.159 +2 -2 + NTP_4_2_7P337 + + util/invoke-ntp-keygen.texi@1.327 +2 -2 + NTP_4_2_7P337 + + util/ntp-keygen-opts.c@1.341 +4 -4 + NTP_4_2_7P337 + + util/ntp-keygen-opts.h@1.341 +3 -3 + NTP_4_2_7P337 + + util/ntp-keygen.1ntp-keygenman@1.155 +2 -2 + NTP_4_2_7P337 + + util/ntp-keygen.1ntp-keygenmdoc@1.155 +2 -2 + NTP_4_2_7P337 + + util/ntp-keygen.html@1.5 +2 -2 + NTP_4_2_7P337 + + util/ntp-keygen.man.in@1.155 +2 -2 + NTP_4_2_7P337 + + util/ntp-keygen.mdoc.in@1.155 +2 -2 + NTP_4_2_7P337 + +ChangeSet@1.2856, 2012-12-22 06:35:37-05:00, stenn@deacon.udel.edu + [Bug 1223] More final cleanup for rlimit changes + + ChangeLog@1.1213 +1 -0 + [Bug 1223] More final cleanup for rlimit changes + + ntpd/ntp_config.c@1.309 +2 -2 + [Bug 1223] More final cleanup for rlimit changes + +ChangeSet@1.2855, 2012-12-21 23:25:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P336 + TAG: NTP_4_2_7P336 + + ChangeLog@1.1212 +1 -0 + NTP_4_2_7P336 + + ntpd/invoke-ntp.conf.texi@1.10 +1 -1 + NTP_4_2_7P336 + + ntpd/invoke-ntp.keys.texi@1.10 +1 -1 + NTP_4_2_7P336 + + ntpd/invoke-ntpd.texi@1.326 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.conf.5man@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.conf.5mdoc@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.conf.html@1.9 +552 -1862 + NTP_4_2_7P336 + + ntpd/ntp.conf.man.in@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.conf.mdoc.in@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.keys.5man@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.keys.5mdoc@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.keys.html@1.10 +13 -149 + NTP_4_2_7P336 + + ntpd/ntp.keys.man.in@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntp.keys.mdoc.in@1.44 +2 -2 + NTP_4_2_7P336 + + ntpd/ntpd-opts.c@1.344 +4 -4 + NTP_4_2_7P336 + + ntpd/ntpd-opts.h@1.344 +3 -3 + NTP_4_2_7P336 + + ntpd/ntpd.1ntpdman@1.155 +2 -2 + NTP_4_2_7P336 + + ntpd/ntpd.1ntpdmdoc@1.155 +2 -2 + NTP_4_2_7P336 + + ntpd/ntpd.html@1.3 +116 -126 + NTP_4_2_7P336 + + ntpd/ntpd.man.in@1.155 +2 -2 + NTP_4_2_7P336 + + ntpd/ntpd.mdoc.in@1.155 +2 -2 + NTP_4_2_7P336 + + ntpdc/invoke-ntpdc.texi@1.323 +2 -2 + NTP_4_2_7P336 + + ntpdc/ntpdc-opts.c@1.338 +4 -4 + NTP_4_2_7P336 + + ntpdc/ntpdc-opts.h@1.338 +3 -3 + NTP_4_2_7P336 + + ntpdc/ntpdc.1ntpdcman@1.154 +2 -2 + NTP_4_2_7P336 + + ntpdc/ntpdc.1ntpdcmdoc@1.154 +2 -2 + NTP_4_2_7P336 + + ntpdc/ntpdc.html@1.166 +2 -2 + NTP_4_2_7P336 + + ntpdc/ntpdc.man.in@1.154 +2 -2 + NTP_4_2_7P336 + + ntpdc/ntpdc.mdoc.in@1.154 +2 -2 + NTP_4_2_7P336 + + ntpq/invoke-ntpq.texi@1.325 +2 -2 + NTP_4_2_7P336 + + ntpq/ntpq-opts.c@1.340 +4 -4 + NTP_4_2_7P336 + + ntpq/ntpq-opts.h@1.340 +3 -3 + NTP_4_2_7P336 + + ntpq/ntpq.1ntpqman@1.154 +2 -2 + NTP_4_2_7P336 + + ntpq/ntpq.1ntpqmdoc@1.154 +2 -2 + NTP_4_2_7P336 + + ntpq/ntpq.man.in@1.154 +2 -2 + NTP_4_2_7P336 + + ntpq/ntpq.mdoc.in@1.154 +2 -2 + NTP_4_2_7P336 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.325 +2 -2 + NTP_4_2_7P336 + + ntpsnmpd/ntpsnmpd-opts.c@1.340 +4 -4 + NTP_4_2_7P336 + + ntpsnmpd/ntpsnmpd-opts.h@1.340 +3 -3 + NTP_4_2_7P336 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.154 +2 -2 + NTP_4_2_7P336 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.154 +2 -2 + NTP_4_2_7P336 + + ntpsnmpd/ntpsnmpd.man.in@1.154 +2 -2 + NTP_4_2_7P336 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.154 +2 -2 + NTP_4_2_7P336 + + packageinfo.sh@1.339 +1 -1 + NTP_4_2_7P336 + + scripts/invoke-ntp-wait.texi@1.143 +1 -1 + NTP_4_2_7P336 + + scripts/ntp-wait.1ntp-waitman@1.154 +2 -2 + NTP_4_2_7P336 + + scripts/ntp-wait.1ntp-waitmdoc@1.154 +2 -2 + NTP_4_2_7P336 + + scripts/ntp-wait.html@1.158 +1 -1 + NTP_4_2_7P336 + + scripts/ntp-wait.man.in@1.154 +2 -2 + NTP_4_2_7P336 + + scripts/ntp-wait.mdoc.in@1.154 +2 -2 + NTP_4_2_7P336 + + sntp/invoke-sntp.texi@1.323 +2 -2 + NTP_4_2_7P336 + + sntp/sntp-opts.c@1.338 +4 -4 + NTP_4_2_7P336 + + sntp/sntp-opts.h@1.338 +3 -3 + NTP_4_2_7P336 + + sntp/sntp.1sntpman@1.158 +2 -2 + NTP_4_2_7P336 + + sntp/sntp.1sntpmdoc@1.158 +2 -2 + NTP_4_2_7P336 + + sntp/sntp.html@1.338 +2 -2 + NTP_4_2_7P336 + + sntp/sntp.man.in@1.158 +2 -2 + NTP_4_2_7P336 + + sntp/sntp.mdoc.in@1.158 +2 -2 + NTP_4_2_7P336 + + util/invoke-ntp-keygen.texi@1.326 +2 -2 + NTP_4_2_7P336 + + util/ntp-keygen-opts.c@1.340 +4 -4 + NTP_4_2_7P336 + + util/ntp-keygen-opts.h@1.340 +3 -3 + NTP_4_2_7P336 + + util/ntp-keygen.1ntp-keygenman@1.154 +2 -2 + NTP_4_2_7P336 + + util/ntp-keygen.1ntp-keygenmdoc@1.154 +2 -2 + NTP_4_2_7P336 + + util/ntp-keygen.html@1.4 +181 -293 + NTP_4_2_7P336 + + util/ntp-keygen.man.in@1.154 +2 -2 + NTP_4_2_7P336 + + util/ntp-keygen.mdoc.in@1.154 +2 -2 + NTP_4_2_7P336 + +ChangeSet@1.2854, 2012-12-21 05:41:54-05:00, stenn@deacon.udel.edu + [Bug 1223] Final cleanup for rlimit changes + + ChangeLog@1.1211 +1 -0 + [Bug 1223] Final cleanup for rlimit changes + + ntpd/ntpd.c@1.140 +3 -2 + [Bug 1223] Final cleanup for rlimit changes + +ChangeSet@1.2853, 2012-12-18 09:00:04+00:00, stenn@deacon.udel.edu + NTP_4_2_7P335 + TAG: NTP_4_2_7P335 + + ChangeLog@1.1210 +1 -0 + NTP_4_2_7P335 + + ntpd/invoke-ntp.conf.texi@1.9 +410 -1484 + NTP_4_2_7P335 + + ntpd/invoke-ntp.keys.texi@1.9 +13 -118 + NTP_4_2_7P335 + + ntpd/invoke-ntpd.texi@1.325 +87 -127 + NTP_4_2_7P335 + + ntpd/ntp.conf.5man@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntp.conf.5mdoc@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntp.conf.html@1.8 +5 -4 + NTP_4_2_7P335 + + ntpd/ntp.conf.man.in@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntp.conf.mdoc.in@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntp.keys.5man@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntp.keys.5mdoc@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntp.keys.html@1.9 +5 -4 + NTP_4_2_7P335 + + ntpd/ntp.keys.man.in@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntp.keys.mdoc.in@1.43 +2 -2 + NTP_4_2_7P335 + + ntpd/ntpd-opts.c@1.343 +4 -4 + NTP_4_2_7P335 + + ntpd/ntpd-opts.h@1.343 +3 -3 + NTP_4_2_7P335 + + ntpd/ntpd.1ntpdman@1.154 +43 -47 + NTP_4_2_7P335 + + ntpd/ntpd.1ntpdmdoc@1.154 +43 -47 + NTP_4_2_7P335 + + ntpd/ntpd.html@1.2 +97 -139 + NTP_4_2_7P335 + + ntpd/ntpd.man.in@1.154 +43 -47 + NTP_4_2_7P335 + + ntpd/ntpd.mdoc.in@1.154 +43 -47 + NTP_4_2_7P335 + + ntpdc/invoke-ntpdc.texi@1.322 +89 -299 + NTP_4_2_7P335 + + ntpdc/ntpdc-opts.c@1.337 +4 -4 + NTP_4_2_7P335 + + ntpdc/ntpdc-opts.h@1.337 +3 -3 + NTP_4_2_7P335 + + ntpdc/ntpdc.1ntpdcman@1.153 +2 -2 + NTP_4_2_7P335 + + ntpdc/ntpdc.1ntpdcmdoc@1.153 +2 -2 + NTP_4_2_7P335 + + ntpdc/ntpdc.html@1.165 +26 -725 + NTP_4_2_7P335 + + ntpdc/ntpdc.man.in@1.153 +2 -2 + NTP_4_2_7P335 + + ntpdc/ntpdc.mdoc.in@1.153 +2 -2 + NTP_4_2_7P335 + + ntpq/invoke-ntpq.texi@1.324 +27 -83 + NTP_4_2_7P335 + + ntpq/ntpq-opts.c@1.339 +4 -4 + NTP_4_2_7P335 + + ntpq/ntpq-opts.h@1.339 +3 -3 + NTP_4_2_7P335 + + ntpq/ntpq.1ntpqman@1.153 +2 -2 + NTP_4_2_7P335 + + ntpq/ntpq.1ntpqmdoc@1.153 +2 -2 + NTP_4_2_7P335 + + ntpq/ntpq.man.in@1.153 +2 -2 + NTP_4_2_7P335 + + ntpq/ntpq.mdoc.in@1.153 +2 -2 + NTP_4_2_7P335 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.324 +2 -5 + NTP_4_2_7P335 + + ntpsnmpd/ntpsnmpd-opts.c@1.339 +4 -4 + NTP_4_2_7P335 + + ntpsnmpd/ntpsnmpd-opts.h@1.339 +3 -3 + NTP_4_2_7P335 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.153 +2 -2 + NTP_4_2_7P335 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.153 +2 -2 + NTP_4_2_7P335 + + ntpsnmpd/ntpsnmpd.man.in@1.153 +2 -2 + NTP_4_2_7P335 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.153 +2 -2 + NTP_4_2_7P335 + + packageinfo.sh@1.338 +1 -1 + NTP_4_2_7P335 + + scripts/invoke-ntp-wait.texi@1.142 +3 -10 + NTP_4_2_7P335 + + scripts/ntp-wait.1ntp-waitman@1.153 +2 -2 + NTP_4_2_7P335 + + scripts/ntp-wait.1ntp-waitmdoc@1.153 +2 -2 + NTP_4_2_7P335 + + scripts/ntp-wait.html@1.157 +16 -52 + NTP_4_2_7P335 + + scripts/ntp-wait.man.in@1.153 +2 -2 + NTP_4_2_7P335 + + scripts/ntp-wait.mdoc.in@1.153 +2 -2 + NTP_4_2_7P335 + + sntp/invoke-sntp.texi@1.322 +14 -57 + NTP_4_2_7P335 + + sntp/sntp-opts.c@1.337 +4 -4 + NTP_4_2_7P335 + + sntp/sntp-opts.h@1.337 +3 -3 + NTP_4_2_7P335 + + sntp/sntp.1sntpman@1.157 +2 -2 + NTP_4_2_7P335 + + sntp/sntp.1sntpmdoc@1.157 +2 -2 + NTP_4_2_7P335 + + sntp/sntp.html@1.337 +15 -58 + NTP_4_2_7P335 + + sntp/sntp.man.in@1.157 +2 -2 + NTP_4_2_7P335 + + sntp/sntp.mdoc.in@1.157 +2 -2 + NTP_4_2_7P335 + + util/invoke-ntp-keygen.texi@1.325 +107 -254 + NTP_4_2_7P335 + + util/ntp-keygen-opts.c@1.339 +4 -4 + NTP_4_2_7P335 + + util/ntp-keygen-opts.h@1.339 +3 -3 + NTP_4_2_7P335 + + util/ntp-keygen.1ntp-keygenman@1.153 +2 -2 + NTP_4_2_7P335 + + util/ntp-keygen.1ntp-keygenmdoc@1.153 +2 -2 + NTP_4_2_7P335 + + util/ntp-keygen.html@1.3 +152 -2 + NTP_4_2_7P335 + + util/ntp-keygen.man.in@1.153 +2 -2 + NTP_4_2_7P335 + + util/ntp-keygen.mdoc.in@1.153 +2 -2 + NTP_4_2_7P335 + +ChangeSet@1.2852, 2012-12-17 05:34:02-05:00, stenn@deacon.udel.edu + nothing + + ChangeLog@1.1209 +0 -0 + nothing + +ChangeSet@1.2851, 2012-12-17 09:43:26+00:00, stenn@psp-fb1.ntp.org + Update documentation templates and definitions + + sntp/ag-tpl/agtexi-file.tpl@1.3 +5 -2 + Update documentation templates and definitions + +ChangeSet@1.2850, 2012-12-16 10:32:46+00:00, stenn@psp-fb1.ntp.org + Update documentation templates and definitions + + sntp/ag-tpl/mdoc2texi@1.3 +22 -5 + Update documentation templates and definitions + +ChangeSet@1.2849, 2012-12-16 09:50:14+00:00, stenn@psp-fb1.ntp.org + Update documentation templates and definitions + + sntp/ag-tpl/mdoc2texi@1.2 +121 -10 + Update documentation templates and definitions + +ChangeSet@1.2848, 2012-12-16 05:08:04+00:00, stenn@psp-fb1.ntp.org + Update documentation templates and definitions + + ntpd/ntpd.html@1.1 +1655 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/ntpd.html + + ntpd/ntpd.html@1.0 +0 -0 + + ntpd/ntpdbase-opts.def@1.25 +45 -45 + Update documentation templates and definitions + + sntp/ag-tpl/mdoc2texi@1.1 +529 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/sntp/ag-tpl/mdoc2texi + + sntp/ag-tpl/mdoc2texi@1.0 +0 -0 + +ChangeSet@1.2847, 2012-12-12 09:52:10+00:00, stenn@psp-fb1.ntp.org + Update documentation templates and definitions + + .point-changed-filelist@1.18 +1 -0 + Update documentation templates and definitions + + ntpd/Makefile.am@1.127 +6 -0 + Update documentation templates and definitions + + ntpd/ntpd.texi@1.1 +113 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/ntpd.texi + + ntpd/ntpd.texi@1.0 +0 -0 + +ChangeSet@1.2846, 2012-12-12 08:13:15+00:00, stenn@psp-fb1.ntp.org + Update documentation templates and definitions + + ChangeLog@1.1208 +1 -0 + Update documentation templates and definitions + + ntpd/invoke-ntp.conf.menu@1.2 +1 -1 + Update documentation templates and definitions + + ntpd/invoke-ntp.keys.menu@1.2 +1 -1 + Update documentation templates and definitions + + ntpd/ntp.conf.texi@1.4 +3 -3 + Update documentation templates and definitions + + ntpd/ntp.keys.texi@1.4 +3 -3 + Update documentation templates and definitions + + scripts/ntp-wait.texi@1.3 +15 -45 + Update documentation templates and definitions + + sntp/ag-tpl/agtexi-file.tpl@1.2 +0 -559 + Update documentation templates and definitions + +ChangeSet@1.2845, 2012-12-11 05:37:07-05:00, stenn@psp-deb1.ntp.org + Create agtexi-file.tpl + + ChangeLog@1.1207 +1 -0 + Create agtexi-file.tpl + + ntpd/Makefile.am@1.126 +2 -2 + Create agtexi-file.tpl + + sntp/ag-tpl/agtexi-file.tpl@1.1 +884 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/sntp/ag-tpl/agtexi-file.tpl + + sntp/ag-tpl/agtexi-file.tpl@1.0 +0 -0 + +ChangeSet@1.2844, 2012-12-10 11:42:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P334 + TAG: NTP_4_2_7P334 + + ChangeLog@1.1206 +1 -0 + NTP_4_2_7P334 + + ntpd/invoke-ntp.conf.texi@1.8 +1 -1 + NTP_4_2_7P334 + + ntpd/invoke-ntp.keys.texi@1.8 +1 -1 + NTP_4_2_7P334 + + ntpd/invoke-ntpd.texi@1.324 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.conf.5man@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.conf.5mdoc@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.conf.html@1.7 +1 -1 + NTP_4_2_7P334 + + ntpd/ntp.conf.man.in@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.conf.mdoc.in@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.keys.5man@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.keys.5mdoc@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.keys.html@1.8 +1 -1 + NTP_4_2_7P334 + + ntpd/ntp.keys.man.in@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntp.keys.mdoc.in@1.42 +2 -2 + NTP_4_2_7P334 + + ntpd/ntpd-opts.c@1.342 +4 -4 + NTP_4_2_7P334 + + ntpd/ntpd-opts.h@1.342 +3 -3 + NTP_4_2_7P334 + + ntpd/ntpd.1ntpdman@1.153 +2 -2 + NTP_4_2_7P334 + + ntpd/ntpd.1ntpdmdoc@1.153 +2 -2 + NTP_4_2_7P334 + + ntpd/ntpd.man.in@1.153 +2 -2 + NTP_4_2_7P334 + + ntpd/ntpd.mdoc.in@1.153 +2 -2 + NTP_4_2_7P334 + + ntpdc/invoke-ntpdc.texi@1.321 +2 -2 + NTP_4_2_7P334 + + ntpdc/ntpdc-opts.c@1.336 +4 -4 + NTP_4_2_7P334 + + ntpdc/ntpdc-opts.h@1.336 +3 -3 + NTP_4_2_7P334 + + ntpdc/ntpdc.1ntpdcman@1.152 +2 -2 + NTP_4_2_7P334 + + ntpdc/ntpdc.1ntpdcmdoc@1.152 +2 -2 + NTP_4_2_7P334 + + ntpdc/ntpdc.html@1.164 +2 -2 + NTP_4_2_7P334 + + ntpdc/ntpdc.man.in@1.152 +2 -2 + NTP_4_2_7P334 + + ntpdc/ntpdc.mdoc.in@1.152 +2 -2 + NTP_4_2_7P334 + + ntpq/invoke-ntpq.texi@1.323 +2 -2 + NTP_4_2_7P334 + + ntpq/ntpq-opts.c@1.338 +4 -4 + NTP_4_2_7P334 + + ntpq/ntpq-opts.h@1.338 +3 -3 + NTP_4_2_7P334 + + ntpq/ntpq.1ntpqman@1.152 +2 -2 + NTP_4_2_7P334 + + ntpq/ntpq.1ntpqmdoc@1.152 +2 -2 + NTP_4_2_7P334 + + ntpq/ntpq.man.in@1.152 +2 -2 + NTP_4_2_7P334 + + ntpq/ntpq.mdoc.in@1.152 +2 -2 + NTP_4_2_7P334 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.323 +2 -2 + NTP_4_2_7P334 + + ntpsnmpd/ntpsnmpd-opts.c@1.338 +4 -4 + NTP_4_2_7P334 + + ntpsnmpd/ntpsnmpd-opts.h@1.338 +3 -3 + NTP_4_2_7P334 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.152 +2 -2 + NTP_4_2_7P334 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.152 +2 -2 + NTP_4_2_7P334 + + ntpsnmpd/ntpsnmpd.man.in@1.152 +2 -2 + NTP_4_2_7P334 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.152 +2 -2 + NTP_4_2_7P334 + + packageinfo.sh@1.337 +1 -1 + NTP_4_2_7P334 + + scripts/invoke-ntp-wait.texi@1.141 +1 -1 + NTP_4_2_7P334 + + scripts/ntp-wait.1ntp-waitman@1.152 +2 -2 + NTP_4_2_7P334 + + scripts/ntp-wait.1ntp-waitmdoc@1.152 +2 -2 + NTP_4_2_7P334 + + scripts/ntp-wait.html@1.156 +1 -1 + NTP_4_2_7P334 + + scripts/ntp-wait.man.in@1.152 +2 -2 + NTP_4_2_7P334 + + scripts/ntp-wait.mdoc.in@1.152 +2 -2 + NTP_4_2_7P334 + + sntp/invoke-sntp.texi@1.321 +2 -2 + NTP_4_2_7P334 + + sntp/sntp-opts.c@1.336 +4 -4 + NTP_4_2_7P334 + + sntp/sntp-opts.h@1.336 +3 -3 + NTP_4_2_7P334 + + sntp/sntp.1sntpman@1.156 +2 -2 + NTP_4_2_7P334 + + sntp/sntp.1sntpmdoc@1.156 +2 -2 + NTP_4_2_7P334 + + sntp/sntp.html@1.336 +2 -2 + NTP_4_2_7P334 + + sntp/sntp.man.in@1.156 +2 -2 + NTP_4_2_7P334 + + sntp/sntp.mdoc.in@1.156 +2 -2 + NTP_4_2_7P334 + + util/invoke-ntp-keygen.texi@1.324 +154 -2 + NTP_4_2_7P334 + + util/ntp-keygen-opts.c@1.338 +4 -4 + NTP_4_2_7P334 + + util/ntp-keygen-opts.h@1.338 +3 -3 + NTP_4_2_7P334 + + util/ntp-keygen.1ntp-keygenman@1.152 +2 -2 + NTP_4_2_7P334 + + util/ntp-keygen.1ntp-keygenmdoc@1.152 +2 -2 + NTP_4_2_7P334 + + util/ntp-keygen.html@1.2 +115 -174 + NTP_4_2_7P334 + + util/ntp-keygen.man.in@1.152 +2 -2 + NTP_4_2_7P334 + + util/ntp-keygen.mdoc.in@1.152 +2 -2 + NTP_4_2_7P334 + +ChangeSet@1.2843, 2012-12-10 04:25:24-05:00, stenn@psp-deb1.ntp.org + [Bug 2114] Update tests for sntp's synch distance + + ChangeLog@1.1205 +1 -0 + [Bug 2114] Update tests for sntp's synch distance + + sntp/tests/packetHandling.cpp@1.10 +3 -2 + [Bug 2114] Update tests for sntp's synch distance + +ChangeSet@1.2842, 2012-12-10 04:23:36-05:00, stenn@psp-deb1.ntp.org + Create ntp-keygen.{html,texi} + + .point-changed-filelist@1.17 +1 -0 + Create ntp-keygen.{html,texi} + + ChangeLog@1.1204 +1 -0 + Create ntp-keygen.{html,texi} + + util/Makefile.am@1.74 +11 -0 + Create ntp-keygen.{html,texi} + + util/ntp-keygen-opts.def@1.22 +130 -0 + Create ntp-keygen.{html,texi} + + util/ntp-keygen.html@1.1 +1874 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/util/ntp-keygen.html + + util/ntp-keygen.html@1.0 +0 -0 + + util/ntp-keygen.texi@1.1 +274 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/util/ntp-keygen.texi + + util/ntp-keygen.texi@1.0 +0 -0 + +ChangeSet@1.2841, 2012-12-07 11:33:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P333 + TAG: NTP_4_2_7P333 + + ChangeLog@1.1203 +1 -0 + NTP_4_2_7P333 + + ntpd/invoke-ntp.conf.texi@1.7 +1 -1 + NTP_4_2_7P333 + + ntpd/invoke-ntp.keys.texi@1.7 +1 -1 + NTP_4_2_7P333 + + ntpd/invoke-ntpd.texi@1.323 +2 -2 + NTP_4_2_7P333 + + ntpd/ntp.conf.5man@1.41 +3 -2877 + NTP_4_2_7P333 + + ntpd/ntp.conf.5mdoc@1.41 +3 -2709 + NTP_4_2_7P333 + + ntpd/ntp.conf.html@1.6 +168 -187 + NTP_4_2_7P333 + + ntpd/ntp.conf.man.in@1.41 +3 -2877 + NTP_4_2_7P333 + + ntpd/ntp.conf.mdoc.in@1.41 +3 -2709 + NTP_4_2_7P333 + + ntpd/ntp.keys.5man@1.41 +2 -95 + NTP_4_2_7P333 + + ntpd/ntp.keys.5mdoc@1.41 +2 -94 + NTP_4_2_7P333 + + ntpd/ntp.keys.html@1.7 +36 -53 + NTP_4_2_7P333 + + ntpd/ntp.keys.man.in@1.41 +2 -95 + NTP_4_2_7P333 + + ntpd/ntp.keys.mdoc.in@1.41 +2 -94 + NTP_4_2_7P333 + + ntpd/ntpd-opts.c@1.341 +4 -4 + NTP_4_2_7P333 + + ntpd/ntpd-opts.h@1.341 +3 -3 + NTP_4_2_7P333 + + ntpd/ntpd.1ntpdman@1.152 +3 -549 + NTP_4_2_7P333 + + ntpd/ntpd.1ntpdmdoc@1.152 +3 -548 + NTP_4_2_7P333 + + ntpd/ntpd.man.in@1.152 +3 -549 + NTP_4_2_7P333 + + ntpd/ntpd.mdoc.in@1.152 +3 -548 + NTP_4_2_7P333 + + ntpdc/invoke-ntpdc.texi@1.320 +2 -2 + NTP_4_2_7P333 + + ntpdc/ntpdc-opts.c@1.335 +4 -4 + NTP_4_2_7P333 + + ntpdc/ntpdc-opts.h@1.335 +3 -3 + NTP_4_2_7P333 + + ntpdc/ntpdc.1ntpdcman@1.151 +3 -704 + NTP_4_2_7P333 + + ntpdc/ntpdc.1ntpdcmdoc@1.151 +3 -659 + NTP_4_2_7P333 + + ntpdc/ntpdc.html@1.163 +98 -118 + NTP_4_2_7P333 + + ntpdc/ntpdc.man.in@1.151 +3 -704 + NTP_4_2_7P333 + + ntpdc/ntpdc.mdoc.in@1.151 +3 -659 + NTP_4_2_7P333 + + ntpq/invoke-ntpq.texi@1.322 +2 -2 + NTP_4_2_7P333 + + ntpq/ntpq-opts.c@1.337 +4 -4 + NTP_4_2_7P333 + + ntpq/ntpq-opts.h@1.337 +3 -3 + NTP_4_2_7P333 + + ntpq/ntpq.1ntpqman@1.151 +2 -260 + NTP_4_2_7P333 + + ntpq/ntpq.1ntpqmdoc@1.151 +2 -245 + NTP_4_2_7P333 + + ntpq/ntpq.man.in@1.151 +2 -260 + NTP_4_2_7P333 + + ntpq/ntpq.mdoc.in@1.151 +2 -245 + NTP_4_2_7P333 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.322 +2 -2 + NTP_4_2_7P333 + + ntpsnmpd/ntpsnmpd-opts.c@1.337 +4 -4 + NTP_4_2_7P333 + + ntpsnmpd/ntpsnmpd-opts.h@1.337 +3 -3 + NTP_4_2_7P333 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.151 +2 -4 + NTP_4_2_7P333 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.151 +2 -4 + NTP_4_2_7P333 + + ntpsnmpd/ntpsnmpd.man.in@1.151 +2 -4 + NTP_4_2_7P333 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.151 +2 -4 + NTP_4_2_7P333 + + packageinfo.sh@1.336 +1 -1 + NTP_4_2_7P333 + + scripts/invoke-ntp-wait.texi@1.140 +3 -3 + NTP_4_2_7P333 + + scripts/ntp-wait.1ntp-waitman@1.151 +2 -19 + NTP_4_2_7P333 + + scripts/ntp-wait.1ntp-waitmdoc@1.151 +2 -19 + NTP_4_2_7P333 + + scripts/ntp-wait.html@1.155 +42 -65 + NTP_4_2_7P333 + + scripts/ntp-wait.man.in@1.151 +2 -19 + NTP_4_2_7P333 + + scripts/ntp-wait.mdoc.in@1.151 +2 -19 + NTP_4_2_7P333 + + sntp/invoke-sntp.texi@1.320 +2 -2 + NTP_4_2_7P333 + + sntp/sntp-opts.c@1.335 +4 -4 + NTP_4_2_7P333 + + sntp/sntp-opts.h@1.335 +3 -3 + NTP_4_2_7P333 + + sntp/sntp.1sntpman@1.155 +2 -66 + NTP_4_2_7P333 + + sntp/sntp.1sntpmdoc@1.155 +2 -66 + NTP_4_2_7P333 + + sntp/sntp.html@1.335 +91 -116 + NTP_4_2_7P333 + + sntp/sntp.man.in@1.155 +2 -66 + NTP_4_2_7P333 + + sntp/sntp.mdoc.in@1.155 +2 -66 + NTP_4_2_7P333 + + util/invoke-ntp-keygen.texi@1.323 +2 -2 + NTP_4_2_7P333 + + util/ntp-keygen-opts.c@1.337 +4 -4 + NTP_4_2_7P333 + + util/ntp-keygen-opts.h@1.337 +3 -3 + NTP_4_2_7P333 + + util/ntp-keygen.1ntp-keygenman@1.151 +3 -721 + NTP_4_2_7P333 + + util/ntp-keygen.1ntp-keygenmdoc@1.151 +3 -707 + NTP_4_2_7P333 + + util/ntp-keygen.man.in@1.151 +3 -721 + NTP_4_2_7P333 + + util/ntp-keygen.mdoc.in@1.151 +3 -707 + NTP_4_2_7P333 + +ChangeSet@1.2840, 2012-12-07 09:56:25+00:00, stenn@psp-fb1.ntp.org + Autogen documentation cleanup + + ChangeLog@1.1202 +1 -0 + Autogen documentation cleanup + + ntpd/invoke-ntp.conf.texi@1.6 +3 -2 + Autogen documentation cleanup + + ntpd/invoke-ntp.keys.texi@1.6 +3 -2 + Autogen documentation cleanup + + ntpd/invoke-ntpd.texi@1.322 +2 -1 + Autogen documentation cleanup + + ntpd/ntp.conf.5man@1.40 +2877 -3 + Autogen documentation cleanup + + ntpd/ntp.conf.5mdoc@1.40 +2710 -4 + Autogen documentation cleanup + + ntpd/ntp.conf.def@1.4 +2 -1 + Autogen documentation cleanup + + ntpd/ntp.conf.html@1.5 +185 -165 + Autogen documentation cleanup + + ntpd/ntp.conf.man.in@1.40 +2877 -3 + Autogen documentation cleanup + + ntpd/ntp.conf.mdoc.in@1.40 +2710 -4 + Autogen documentation cleanup + + ntpd/ntp.keys.5man@1.40 +95 -2 + Autogen documentation cleanup + + ntpd/ntp.keys.5mdoc@1.40 +95 -3 + Autogen documentation cleanup + + ntpd/ntp.keys.def@1.8 +2 -1 + Autogen documentation cleanup + + ntpd/ntp.keys.html@1.6 +51 -33 + Autogen documentation cleanup + + ntpd/ntp.keys.man.in@1.40 +95 -2 + Autogen documentation cleanup + + ntpd/ntp.keys.mdoc.in@1.40 +95 -3 + Autogen documentation cleanup + + ntpd/ntpd-opts.c@1.340 +1 -1 + Autogen documentation cleanup + + ntpd/ntpd-opts.def@1.8 +1 -0 + Autogen documentation cleanup + + ntpd/ntpd-opts.h@1.340 +1 -1 + Autogen documentation cleanup + + ntpd/ntpd.1ntpdman@1.151 +549 -3 + Autogen documentation cleanup + + ntpd/ntpd.1ntpdmdoc@1.151 +549 -4 + Autogen documentation cleanup + + ntpd/ntpd.man.in@1.151 +549 -3 + Autogen documentation cleanup + + ntpd/ntpd.mdoc.in@1.151 +549 -4 + Autogen documentation cleanup + + ntpdc/invoke-ntpdc.texi@1.319 +1 -1 + Autogen documentation cleanup + + ntpdc/ntpdc-opts.c@1.334 +1 -1 + Autogen documentation cleanup + + ntpdc/ntpdc-opts.h@1.334 +1 -1 + Autogen documentation cleanup + + ntpdc/ntpdc.1ntpdcman@1.150 +704 -3 + Autogen documentation cleanup + + ntpdc/ntpdc.1ntpdcmdoc@1.150 +660 -4 + Autogen documentation cleanup + + ntpdc/ntpdc.html@1.162 +116 -96 + Autogen documentation cleanup + + ntpdc/ntpdc.man.in@1.150 +704 -3 + Autogen documentation cleanup + + ntpdc/ntpdc.mdoc.in@1.150 +660 -4 + Autogen documentation cleanup + + ntpq/invoke-ntpq.texi@1.321 +1 -1 + Autogen documentation cleanup + + ntpq/ntpq-opts.c@1.336 +1 -1 + Autogen documentation cleanup + + ntpq/ntpq-opts.h@1.336 +1 -1 + Autogen documentation cleanup + + ntpq/ntpq.1ntpqman@1.150 +260 -2 + Autogen documentation cleanup + + ntpq/ntpq.1ntpqmdoc@1.150 +246 -3 + Autogen documentation cleanup + + ntpq/ntpq.man.in@1.150 +260 -2 + Autogen documentation cleanup + + ntpq/ntpq.mdoc.in@1.150 +246 -3 + Autogen documentation cleanup + + ntpsnmpd/invoke-ntpsnmpd.texi@1.321 +5 -1 + Autogen documentation cleanup + + ntpsnmpd/ntpsnmpd-opts.c@1.336 +1 -1 + Autogen documentation cleanup + + ntpsnmpd/ntpsnmpd-opts.def@1.4 +1 -2 + Autogen documentation cleanup + + ntpsnmpd/ntpsnmpd-opts.h@1.336 +1 -1 + Autogen documentation cleanup + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.150 +6 -3 + Autogen documentation cleanup + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.150 +7 -4 + Autogen documentation cleanup + + ntpsnmpd/ntpsnmpd.man.in@1.150 +6 -3 + Autogen documentation cleanup + + ntpsnmpd/ntpsnmpd.mdoc.in@1.150 +7 -4 + Autogen documentation cleanup + + scripts/invoke-ntp-wait.texi@1.139 +7 -3 + Autogen documentation cleanup + + scripts/ntp-wait-opts.def@1.5 +9 -1 + Autogen documentation cleanup + + scripts/ntp-wait.1ntp-waitman@1.150 +21 -3 + Autogen documentation cleanup + + scripts/ntp-wait.1ntp-waitmdoc@1.150 +22 -4 + Autogen documentation cleanup + + scripts/ntp-wait.html@1.154 +74 -39 + Autogen documentation cleanup + + scripts/ntp-wait.man.in@1.150 +21 -3 + Autogen documentation cleanup + + scripts/ntp-wait.mdoc.in@1.150 +22 -4 + Autogen documentation cleanup + + sntp/invoke-sntp.texi@1.319 +1 -1 + Autogen documentation cleanup + + sntp/sntp-opts.c@1.334 +1 -1 + Autogen documentation cleanup + + sntp/sntp-opts.h@1.334 +1 -1 + Autogen documentation cleanup + + sntp/sntp.1sntpman@1.154 +66 -2 + Autogen documentation cleanup + + sntp/sntp.1sntpmdoc@1.154 +67 -3 + Autogen documentation cleanup + + sntp/sntp.html@1.334 +114 -89 + Autogen documentation cleanup + + sntp/sntp.man.in@1.154 +66 -2 + Autogen documentation cleanup + + sntp/sntp.mdoc.in@1.154 +67 -3 + Autogen documentation cleanup + + util/invoke-ntp-keygen.texi@1.322 +2 -1 + Autogen documentation cleanup + + util/ntp-keygen-opts.c@1.336 +1 -1 + Autogen documentation cleanup + + util/ntp-keygen-opts.def@1.21 +1 -0 + Autogen documentation cleanup + + util/ntp-keygen-opts.h@1.336 +1 -1 + Autogen documentation cleanup + + util/ntp-keygen.1ntp-keygenman@1.150 +721 -3 + Autogen documentation cleanup + + util/ntp-keygen.1ntp-keygenmdoc@1.150 +708 -4 + Autogen documentation cleanup + + util/ntp-keygen.man.in@1.150 +721 -3 + Autogen documentation cleanup + + util/ntp-keygen.mdoc.in@1.150 +708 -4 + Autogen documentation cleanup + +ChangeSet@1.2839, 2012-12-06 07:46:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P332 + TAG: NTP_4_2_7P332 + + ChangeLog@1.1201 +1 -0 + NTP_4_2_7P332 + + ntpd/invoke-ntp.conf.texi@1.5 +1 -1 + NTP_4_2_7P332 + + ntpd/invoke-ntp.keys.texi@1.5 +1 -1 + NTP_4_2_7P332 + + ntpd/invoke-ntpd.texi@1.321 +2 -2 + NTP_4_2_7P332 + + ntpd/ntp.conf.5man@1.39 +3 -2876 + NTP_4_2_7P332 + + ntpd/ntp.conf.5mdoc@1.39 +4 -2709 + NTP_4_2_7P332 + + ntpd/ntp.conf.html@1.4 +1 -1 + NTP_4_2_7P332 + + ntpd/ntp.conf.man.in@1.39 +3 -2876 + NTP_4_2_7P332 + + ntpd/ntp.conf.mdoc.in@1.39 +4 -2709 + NTP_4_2_7P332 + + ntpd/ntp.keys.5man@1.39 +2 -94 + NTP_4_2_7P332 + + ntpd/ntp.keys.5mdoc@1.39 +3 -94 + NTP_4_2_7P332 + + ntpd/ntp.keys.html@1.5 +1 -1 + NTP_4_2_7P332 + + ntpd/ntp.keys.man.in@1.39 +2 -94 + NTP_4_2_7P332 + + ntpd/ntp.keys.mdoc.in@1.39 +3 -94 + NTP_4_2_7P332 + + ntpd/ntpd-opts.c@1.339 +4 -4 + NTP_4_2_7P332 + + ntpd/ntpd-opts.h@1.339 +3 -3 + NTP_4_2_7P332 + + ntpd/ntpd.1ntpdman@1.150 +2 -2 + NTP_4_2_7P332 + + ntpd/ntpd.1ntpdmdoc@1.150 +2 -2 + NTP_4_2_7P332 + + ntpd/ntpd.man.in@1.150 +2 -2 + NTP_4_2_7P332 + + ntpd/ntpd.mdoc.in@1.150 +2 -2 + NTP_4_2_7P332 + + ntpdc/invoke-ntpdc.texi@1.318 +2 -2 + NTP_4_2_7P332 + + ntpdc/ntpdc-opts.c@1.333 +4 -4 + NTP_4_2_7P332 + + ntpdc/ntpdc-opts.h@1.333 +3 -3 + NTP_4_2_7P332 + + ntpdc/ntpdc.1ntpdcman@1.149 +2 -2 + NTP_4_2_7P332 + + ntpdc/ntpdc.1ntpdcmdoc@1.149 +2 -2 + NTP_4_2_7P332 + + ntpdc/ntpdc.html@1.161 +2 -2 + NTP_4_2_7P332 + + ntpdc/ntpdc.man.in@1.149 +2 -2 + NTP_4_2_7P332 + + ntpdc/ntpdc.mdoc.in@1.149 +2 -2 + NTP_4_2_7P332 + + ntpq/invoke-ntpq.texi@1.320 +2 -2 + NTP_4_2_7P332 + + ntpq/ntpq-opts.c@1.335 +4 -4 + NTP_4_2_7P332 + + ntpq/ntpq-opts.h@1.335 +3 -3 + NTP_4_2_7P332 + + ntpq/ntpq.1ntpqman@1.149 +2 -2 + NTP_4_2_7P332 + + ntpq/ntpq.1ntpqmdoc@1.149 +2 -2 + NTP_4_2_7P332 + + ntpq/ntpq.man.in@1.149 +2 -2 + NTP_4_2_7P332 + + ntpq/ntpq.mdoc.in@1.149 +2 -2 + NTP_4_2_7P332 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.320 +2 -2 + NTP_4_2_7P332 + + ntpsnmpd/ntpsnmpd-opts.c@1.335 +4 -4 + NTP_4_2_7P332 + + ntpsnmpd/ntpsnmpd-opts.h@1.335 +3 -3 + NTP_4_2_7P332 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.149 +2 -2 + NTP_4_2_7P332 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.149 +2 -2 + NTP_4_2_7P332 + + ntpsnmpd/ntpsnmpd.man.in@1.149 +2 -2 + NTP_4_2_7P332 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.149 +2 -2 + NTP_4_2_7P332 + + packageinfo.sh@1.335 +1 -1 + NTP_4_2_7P332 + + scripts/invoke-ntp-wait.texi@1.138 +1 -1 + NTP_4_2_7P332 + + scripts/ntp-wait.1ntp-waitman@1.149 +2 -2 + NTP_4_2_7P332 + + scripts/ntp-wait.1ntp-waitmdoc@1.149 +2 -2 + NTP_4_2_7P332 + + scripts/ntp-wait.html@1.153 +1 -1 + NTP_4_2_7P332 + + scripts/ntp-wait.man.in@1.149 +2 -2 + NTP_4_2_7P332 + + scripts/ntp-wait.mdoc.in@1.149 +2 -2 + NTP_4_2_7P332 + + sntp/invoke-sntp.texi@1.318 +2 -2 + NTP_4_2_7P332 + + sntp/sntp-opts.c@1.333 +4 -4 + NTP_4_2_7P332 + + sntp/sntp-opts.h@1.333 +3 -3 + NTP_4_2_7P332 + + sntp/sntp.1sntpman@1.153 +2 -66 + NTP_4_2_7P332 + + sntp/sntp.1sntpmdoc@1.153 +2 -66 + NTP_4_2_7P332 + + sntp/sntp.html@1.333 +91 -116 + NTP_4_2_7P332 + + sntp/sntp.man.in@1.153 +2 -66 + NTP_4_2_7P332 + + sntp/sntp.mdoc.in@1.153 +2 -66 + NTP_4_2_7P332 + + util/invoke-ntp-keygen.texi@1.321 +2 -2 + NTP_4_2_7P332 + + util/ntp-keygen-opts.c@1.335 +4 -4 + NTP_4_2_7P332 + + util/ntp-keygen-opts.h@1.335 +3 -3 + NTP_4_2_7P332 + + util/ntp-keygen.1ntp-keygenman@1.149 +2 -2 + NTP_4_2_7P332 + + util/ntp-keygen.1ntp-keygenmdoc@1.149 +2 -2 + NTP_4_2_7P332 + + util/ntp-keygen.man.in@1.149 +2 -2 + NTP_4_2_7P332 + + util/ntp-keygen.mdoc.in@1.149 +2 -2 + NTP_4_2_7P332 + +ChangeSet@1.2838, 2012-12-06 02:20:55+00:00, stenn@psp-fb1.ntp.org + update ntpd docs + + ntpd/invoke-ntp.conf.texi@1.4 +1 -1 + update ntpd docs + + ntpd/invoke-ntp.keys.texi@1.4 +1 -1 + update ntpd docs + + ntpd/ntp.conf.5man@1.38 +2876 -3 + update ntpd docs + + ntpd/ntp.conf.5mdoc@1.38 +2709 -4 + update ntpd docs + + ntpd/ntp.conf.man.in@1.38 +2876 -3 + update ntpd docs + + ntpd/ntp.conf.mdoc.in@1.38 +2709 -4 + update ntpd docs + + ntpd/ntp.keys.5man@1.38 +94 -2 + update ntpd docs + + ntpd/ntp.keys.5mdoc@1.38 +94 -3 + update ntpd docs + + ntpd/ntp.keys.man.in@1.38 +94 -2 + update ntpd docs + + ntpd/ntp.keys.mdoc.in@1.38 +94 -3 + update ntpd docs + +ChangeSet@1.2837, 2012-12-06 02:14:12+00:00, stenn@psp-fb1.ntp.org + sntp doc cleanup + + ChangeLog@1.1200 +1 -0 + sntp doc cleanup + + sntp/invoke-sntp.texi@1.317 +17 -26 + sntp doc cleanup + + sntp/sntp-opts.c@1.332 +78 -78 + sntp doc cleanup + + sntp/sntp-opts.def@1.41 +15 -24 + sntp doc cleanup + + sntp/sntp-opts.h@1.332 +1 -1 + sntp doc cleanup + + sntp/sntp.1sntpman@1.152 +78 -20 + sntp doc cleanup + + sntp/sntp.1sntpmdoc@1.152 +79 -24 + sntp doc cleanup + + sntp/sntp.html@1.332 +125 -110 + sntp doc cleanup + + sntp/sntp.man.in@1.152 +78 -20 + sntp doc cleanup + + sntp/sntp.mdoc.in@1.152 +79 -24 + sntp doc cleanup + +ChangeSet@1.2836, 2012-12-03 12:35:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P331 + TAG: NTP_4_2_7P331 + + ChangeLog@1.1199 +1 -0 + NTP_4_2_7P331 + + ntpd/invoke-ntp.conf.texi@1.3 +1 -1 + NTP_4_2_7P331 + + ntpd/invoke-ntp.keys.texi@1.3 +1 -1 + NTP_4_2_7P331 + + ntpd/invoke-ntpd.texi@1.320 +2 -2 + NTP_4_2_7P331 + + ntpd/ntp.conf.5man@1.37 +2 -2 + NTP_4_2_7P331 + + ntpd/ntp.conf.5mdoc@1.37 +1 -1 + NTP_4_2_7P331 + + ntpd/ntp.conf.html@1.3 +36 -3 + NTP_4_2_7P331 + + ntpd/ntp.conf.man.in@1.37 +2 -2 + NTP_4_2_7P331 + + ntpd/ntp.conf.mdoc.in@1.37 +1 -1 + NTP_4_2_7P331 + + ntpd/ntp.keys.5man@1.37 +2 -2 + NTP_4_2_7P331 + + ntpd/ntp.keys.5mdoc@1.37 +1 -1 + NTP_4_2_7P331 + + ntpd/ntp.keys.html@1.4 +1 -1 + NTP_4_2_7P331 + + ntpd/ntp.keys.man.in@1.37 +2 -2 + NTP_4_2_7P331 + + ntpd/ntp.keys.mdoc.in@1.37 +1 -1 + NTP_4_2_7P331 + + ntpd/ntpd-opts.c@1.338 +4 -4 + NTP_4_2_7P331 + + ntpd/ntpd-opts.h@1.338 +3 -3 + NTP_4_2_7P331 + + ntpd/ntpd.1ntpdman@1.149 +2 -2 + NTP_4_2_7P331 + + ntpd/ntpd.1ntpdmdoc@1.149 +1 -1 + NTP_4_2_7P331 + + ntpd/ntpd.man.in@1.149 +2 -2 + NTP_4_2_7P331 + + ntpd/ntpd.mdoc.in@1.149 +1 -1 + NTP_4_2_7P331 + + ntpdc/invoke-ntpdc.texi@1.317 +2 -2 + NTP_4_2_7P331 + + ntpdc/ntpdc-opts.c@1.332 +4 -4 + NTP_4_2_7P331 + + ntpdc/ntpdc-opts.h@1.332 +3 -3 + NTP_4_2_7P331 + + ntpdc/ntpdc.1ntpdcman@1.148 +2 -2 + NTP_4_2_7P331 + + ntpdc/ntpdc.1ntpdcmdoc@1.148 +1 -1 + NTP_4_2_7P331 + + ntpdc/ntpdc.html@1.160 +2 -2 + NTP_4_2_7P331 + + ntpdc/ntpdc.man.in@1.148 +2 -2 + NTP_4_2_7P331 + + ntpdc/ntpdc.mdoc.in@1.148 +1 -1 + NTP_4_2_7P331 + + ntpq/invoke-ntpq.texi@1.319 +2 -2 + NTP_4_2_7P331 + + ntpq/ntpq-opts.c@1.334 +4 -4 + NTP_4_2_7P331 + + ntpq/ntpq-opts.h@1.334 +3 -3 + NTP_4_2_7P331 + + ntpq/ntpq.1ntpqman@1.148 +2 -2 + NTP_4_2_7P331 + + ntpq/ntpq.1ntpqmdoc@1.148 +1 -1 + NTP_4_2_7P331 + + ntpq/ntpq.man.in@1.148 +2 -2 + NTP_4_2_7P331 + + ntpq/ntpq.mdoc.in@1.148 +1 -1 + NTP_4_2_7P331 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.319 +2 -2 + NTP_4_2_7P331 + + ntpsnmpd/ntpsnmpd-opts.c@1.334 +4 -4 + NTP_4_2_7P331 + + ntpsnmpd/ntpsnmpd-opts.h@1.334 +3 -3 + NTP_4_2_7P331 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.148 +2 -2 + NTP_4_2_7P331 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.148 +1 -1 + NTP_4_2_7P331 + + ntpsnmpd/ntpsnmpd.man.in@1.148 +2 -2 + NTP_4_2_7P331 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.148 +1 -1 + NTP_4_2_7P331 + + packageinfo.sh@1.334 +1 -1 + NTP_4_2_7P331 + + scripts/invoke-ntp-wait.texi@1.137 +1 -1 + NTP_4_2_7P331 + + scripts/ntp-wait.1ntp-waitman@1.148 +2 -2 + NTP_4_2_7P331 + + scripts/ntp-wait.1ntp-waitmdoc@1.148 +1 -1 + NTP_4_2_7P331 + + scripts/ntp-wait.html@1.152 +1 -1 + NTP_4_2_7P331 + + scripts/ntp-wait.man.in@1.148 +2 -2 + NTP_4_2_7P331 + + scripts/ntp-wait.mdoc.in@1.148 +1 -1 + NTP_4_2_7P331 + + sntp/invoke-sntp.texi@1.316 +2 -2 + NTP_4_2_7P331 + + sntp/sntp-opts.c@1.331 +4 -4 + NTP_4_2_7P331 + + sntp/sntp-opts.h@1.331 +3 -3 + NTP_4_2_7P331 + + sntp/sntp.1sntpman@1.151 +2 -2 + NTP_4_2_7P331 + + sntp/sntp.1sntpmdoc@1.151 +1 -1 + NTP_4_2_7P331 + + sntp/sntp.html@1.331 +2 -2 + NTP_4_2_7P331 + + sntp/sntp.man.in@1.151 +2 -2 + NTP_4_2_7P331 + + sntp/sntp.mdoc.in@1.151 +1 -1 + NTP_4_2_7P331 + + util/invoke-ntp-keygen.texi@1.320 +2 -2 + NTP_4_2_7P331 + + util/ntp-keygen-opts.c@1.334 +4 -4 + NTP_4_2_7P331 + + util/ntp-keygen-opts.h@1.334 +3 -3 + NTP_4_2_7P331 + + util/ntp-keygen.1ntp-keygenman@1.148 +2 -2 + NTP_4_2_7P331 + + util/ntp-keygen.1ntp-keygenmdoc@1.148 +1 -1 + NTP_4_2_7P331 + + util/ntp-keygen.man.in@1.148 +2 -2 + NTP_4_2_7P331 + + util/ntp-keygen.mdoc.in@1.148 +1 -1 + NTP_4_2_7P331 + +ChangeSet@1.2835, 2012-12-03 07:24:46-05:00, stenn@deacon.udel.edu + Include VERSION in the texi output + + ntpd/ntp.conf.texi@1.3 +2 -1 + Include VERSION in the texi output + + ntpd/ntp.keys.texi@1.3 +2 -1 + Include VERSION in the texi output + +ChangeSet@1.2834, 2012-12-03 07:14:45-05:00, stenn@deacon.udel.edu + autogen cleanup + + ntpd/ntp.keys.def@1.7 +1 -0 + autogen cleanup + + ntpd/ntp.keys.html@1.3 +1 -1 + autogen cleanup + +ChangeSet@1.2833, 2012-12-03 07:11:28-05:00, stenn@deacon.udel.edu + fix include path for texi version + + ntpd/ntp.conf.texi@1.2 +1 -1 + fix include path for texi version + + ntpd/ntp.keys.texi@1.2 +1 -1 + fix include path for texi version + +ChangeSet@1.2832, 2012-12-03 02:40:27-08:00, harlan@hms-mbp11.local + [Bug 2114] Correctly calculate sntp's synch distance + + ChangeLog@1.1198 +1 -0 + [Bug 2114] Correctly calculate sntp's synch distance + + sntp/main.c@1.87 +52 -17 + [Bug 2114] Correctly calculate sntp's synch distance + +ChangeSet@1.2831, 2012-12-03 05:37:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P330 + TAG: NTP_4_2_7P330 + + ChangeLog@1.1197 +1 -0 + NTP_4_2_7P330 + + ntpd/invoke-ntp.conf.texi@1.2 +37 -2 + NTP_4_2_7P330 + + ntpd/invoke-ntp.keys.texi@1.2 +1 -1 + NTP_4_2_7P330 + + ntpd/invoke-ntpd.texi@1.319 +2 -2 + NTP_4_2_7P330 + + ntpd/ntp.conf.5man@1.36 +2 -31 + NTP_4_2_7P330 + + ntpd/ntp.conf.5mdoc@1.36 +2 -30 + NTP_4_2_7P330 + + ntpd/ntp.conf.html@1.2 +163 -183 + NTP_4_2_7P330 + + ntpd/ntp.conf.man.in@1.36 +2 -31 + NTP_4_2_7P330 + + ntpd/ntp.conf.mdoc.in@1.36 +2 -30 + NTP_4_2_7P330 + + ntpd/ntp.keys.5man@1.36 +6 -38 + NTP_4_2_7P330 + + ntpd/ntp.keys.5mdoc@1.36 +6 -38 + NTP_4_2_7P330 + + ntpd/ntp.keys.html@1.2 +235 -12 + NTP_4_2_7P330 + + ntpd/ntp.keys.man.in@1.36 +6 -38 + NTP_4_2_7P330 + + ntpd/ntp.keys.mdoc.in@1.36 +6 -38 + NTP_4_2_7P330 + + ntpd/ntpd-opts.c@1.337 +4 -4 + NTP_4_2_7P330 + + ntpd/ntpd-opts.h@1.337 +3 -3 + NTP_4_2_7P330 + + ntpd/ntpd.1ntpdman@1.148 +2 -2 + NTP_4_2_7P330 + + ntpd/ntpd.1ntpdmdoc@1.148 +2 -2 + NTP_4_2_7P330 + + ntpd/ntpd.man.in@1.148 +2 -2 + NTP_4_2_7P330 + + ntpd/ntpd.mdoc.in@1.148 +2 -2 + NTP_4_2_7P330 + + ntpdc/invoke-ntpdc.texi@1.316 +2 -2 + NTP_4_2_7P330 + + ntpdc/ntpdc-opts.c@1.331 +4 -4 + NTP_4_2_7P330 + + ntpdc/ntpdc-opts.h@1.331 +3 -3 + NTP_4_2_7P330 + + ntpdc/ntpdc.1ntpdcman@1.147 +2 -2 + NTP_4_2_7P330 + + ntpdc/ntpdc.1ntpdcmdoc@1.147 +2 -2 + NTP_4_2_7P330 + + ntpdc/ntpdc.html@1.159 +2 -2 + NTP_4_2_7P330 + + ntpdc/ntpdc.man.in@1.147 +2 -2 + NTP_4_2_7P330 + + ntpdc/ntpdc.mdoc.in@1.147 +2 -2 + NTP_4_2_7P330 + + ntpq/invoke-ntpq.texi@1.318 +2 -2 + NTP_4_2_7P330 + + ntpq/ntpq-opts.c@1.333 +4 -4 + NTP_4_2_7P330 + + ntpq/ntpq-opts.h@1.333 +3 -3 + NTP_4_2_7P330 + + ntpq/ntpq.1ntpqman@1.147 +2 -2 + NTP_4_2_7P330 + + ntpq/ntpq.1ntpqmdoc@1.147 +2 -2 + NTP_4_2_7P330 + + ntpq/ntpq.man.in@1.147 +2 -2 + NTP_4_2_7P330 + + ntpq/ntpq.mdoc.in@1.147 +2 -2 + NTP_4_2_7P330 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.318 +2 -2 + NTP_4_2_7P330 + + ntpsnmpd/ntpsnmpd-opts.c@1.333 +4 -4 + NTP_4_2_7P330 + + ntpsnmpd/ntpsnmpd-opts.h@1.333 +3 -3 + NTP_4_2_7P330 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.147 +2 -2 + NTP_4_2_7P330 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.147 +2 -2 + NTP_4_2_7P330 + + ntpsnmpd/ntpsnmpd.man.in@1.147 +2 -2 + NTP_4_2_7P330 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.147 +2 -2 + NTP_4_2_7P330 + + packageinfo.sh@1.333 +1 -1 + NTP_4_2_7P330 + + scripts/invoke-ntp-wait.texi@1.136 +1 -1 + NTP_4_2_7P330 + + scripts/ntp-wait.1ntp-waitman@1.147 +2 -2 + NTP_4_2_7P330 + + scripts/ntp-wait.1ntp-waitmdoc@1.147 +2 -2 + NTP_4_2_7P330 + + scripts/ntp-wait.html@1.151 +1 -1 + NTP_4_2_7P330 + + scripts/ntp-wait.man.in@1.147 +2 -2 + NTP_4_2_7P330 + + scripts/ntp-wait.mdoc.in@1.147 +2 -2 + NTP_4_2_7P330 + + sntp/invoke-sntp.texi@1.315 +2 -2 + NTP_4_2_7P330 + + sntp/sntp-opts.c@1.330 +4 -4 + NTP_4_2_7P330 + + sntp/sntp-opts.h@1.330 +3 -3 + NTP_4_2_7P330 + + sntp/sntp.1sntpman@1.150 +2 -2 + NTP_4_2_7P330 + + sntp/sntp.1sntpmdoc@1.150 +2 -2 + NTP_4_2_7P330 + + sntp/sntp.html@1.330 +2 -2 + NTP_4_2_7P330 + + sntp/sntp.man.in@1.150 +2 -2 + NTP_4_2_7P330 + + sntp/sntp.mdoc.in@1.150 +2 -2 + NTP_4_2_7P330 + + util/invoke-ntp-keygen.texi@1.319 +2 -2 + NTP_4_2_7P330 + + util/ntp-keygen-opts.c@1.333 +4 -4 + NTP_4_2_7P330 + + util/ntp-keygen-opts.h@1.333 +3 -3 + NTP_4_2_7P330 + + util/ntp-keygen.1ntp-keygenman@1.147 +2 -2 + NTP_4_2_7P330 + + util/ntp-keygen.1ntp-keygenmdoc@1.147 +2 -2 + NTP_4_2_7P330 + + util/ntp-keygen.man.in@1.147 +2 -2 + NTP_4_2_7P330 + + util/ntp-keygen.mdoc.in@1.147 +2 -2 + NTP_4_2_7P330 + +ChangeSet@1.2830, 2012-12-03 00:37:12-05:00, stenn@deacon.udel.edu + autogen doc update + + .point-changed-filelist@1.16 +0 -2 + autogen doc update + +ChangeSet@1.2829, 2012-12-03 04:52:58+00:00, stenn@psp-fb1.ntp.org + autogen doc cleanup + + ntpd/ntp.conf.def@1.3 +16 -1 + autogen doc cleanup + +ChangeSet@1.2828, 2012-12-02 23:09:51-05:00, stenn@deacon.udel.edu + autogen doc cleanup + + ntpd/ntp.conf.def@1.2 +1 -0 + autogen doc cleanup + +ChangeSet@1.2827, 2012-12-03 02:51:53+00:00, stenn@psp-fb1.ntp.org + autogen doc cleanup + + .point-changed-filelist@1.15 +6 -0 + autogen doc cleanup + + ChangeLog@1.1196 +1 -0 + autogen doc cleanup + + ntpd/Makefile.am@1.125 +59 -18 + autogen doc cleanup + + ntpd/invoke-ntp.conf.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/invoke-ntp.conf.menu + + ntpd/invoke-ntp.conf.menu@1.0 +0 -0 + + ntpd/invoke-ntp.conf.texi@1.1 +3816 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/invoke-ntp.conf.texi + + ntpd/invoke-ntp.conf.texi@1.0 +0 -0 + + ntpd/invoke-ntp.keys.menu@1.1 +1 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/invoke-ntp.keys.menu + + ntpd/invoke-ntp.keys.menu@1.0 +0 -0 + + ntpd/invoke-ntp.keys.texi@1.1 +208 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/invoke-ntp.keys.texi + + ntpd/invoke-ntp.keys.texi@1.0 +0 -0 + + ntpd/ntp.conf.html@1.1 +3762 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/ntp.conf.html + + ntpd/ntp.conf.html@1.0 +0 -0 + + ntpd/ntp.conf.texi@1.1 +48 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/ntp.conf.texi + + ntpd/ntp.conf.texi@1.0 +0 -0 + + ntpd/ntp.keys.def@1.6 +40 -48 + autogen doc cleanup + + ntpd/ntp.keys.html@1.1 +67 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/ntp.keys.html + + ntpd/ntp.keys.html@1.0 +0 -0 + + ntpd/ntp.keys.texi@1.1 +48 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/ntpd/ntp.keys.texi + + ntpd/ntp.keys.texi@1.0 +0 -0 + + sntp/ag-tpl/agman-file.tpl@1.1 +86 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/sntp/ag-tpl/agman-file.tpl + + sntp/ag-tpl/agman-file.tpl@1.0 +0 -0 + + sntp/ag-tpl/agmdoc-file.tpl@1.1 +73 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/sntp/ag-tpl/agmdoc-file.tpl + + sntp/ag-tpl/agmdoc-file.tpl@1.0 +0 -0 + + sntp/ag-tpl/cmd-doc.tlib@1.1 +1003 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/sntp/ag-tpl/cmd-doc.tlib + + sntp/ag-tpl/cmd-doc.tlib@1.0 +0 -0 + +ChangeSet@1.2826, 2012-12-01 11:33:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P329 + TAG: NTP_4_2_7P329 + + ChangeLog@1.1195 +1 -0 + NTP_4_2_7P329 + + ntpd/invoke-ntpd.texi@1.318 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.conf.5man@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.conf.5mdoc@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.conf.man.in@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.conf.mdoc.in@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.keys.5man@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.keys.5mdoc@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.keys.man.in@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntp.keys.mdoc.in@1.35 +2 -2 + NTP_4_2_7P329 + + ntpd/ntpd-opts.c@1.336 +4 -4 + NTP_4_2_7P329 + + ntpd/ntpd-opts.h@1.336 +3 -3 + NTP_4_2_7P329 + + ntpd/ntpd.1ntpdman@1.147 +2 -2 + NTP_4_2_7P329 + + ntpd/ntpd.1ntpdmdoc@1.147 +2 -2 + NTP_4_2_7P329 + + ntpd/ntpd.man.in@1.147 +2 -2 + NTP_4_2_7P329 + + ntpd/ntpd.mdoc.in@1.147 +2 -2 + NTP_4_2_7P329 + + ntpdc/invoke-ntpdc.texi@1.315 +2 -2 + NTP_4_2_7P329 + + ntpdc/ntpdc-opts.c@1.330 +4 -4 + NTP_4_2_7P329 + + ntpdc/ntpdc-opts.h@1.330 +3 -3 + NTP_4_2_7P329 + + ntpdc/ntpdc.1ntpdcman@1.146 +2 -2 + NTP_4_2_7P329 + + ntpdc/ntpdc.1ntpdcmdoc@1.146 +2 -2 + NTP_4_2_7P329 + + ntpdc/ntpdc.html@1.158 +2 -2 + NTP_4_2_7P329 + + ntpdc/ntpdc.man.in@1.146 +2 -2 + NTP_4_2_7P329 + + ntpdc/ntpdc.mdoc.in@1.146 +2 -2 + NTP_4_2_7P329 + + ntpq/invoke-ntpq.texi@1.317 +2 -2 + NTP_4_2_7P329 + + ntpq/ntpq-opts.c@1.332 +4 -4 + NTP_4_2_7P329 + + ntpq/ntpq-opts.h@1.332 +3 -3 + NTP_4_2_7P329 + + ntpq/ntpq.1ntpqman@1.146 +2 -2 + NTP_4_2_7P329 + + ntpq/ntpq.1ntpqmdoc@1.146 +2 -2 + NTP_4_2_7P329 + + ntpq/ntpq.man.in@1.146 +2 -2 + NTP_4_2_7P329 + + ntpq/ntpq.mdoc.in@1.146 +2 -2 + NTP_4_2_7P329 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.317 +2 -2 + NTP_4_2_7P329 + + ntpsnmpd/ntpsnmpd-opts.c@1.332 +4 -4 + NTP_4_2_7P329 + + ntpsnmpd/ntpsnmpd-opts.h@1.332 +3 -3 + NTP_4_2_7P329 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.146 +2 -2 + NTP_4_2_7P329 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.146 +2 -2 + NTP_4_2_7P329 + + ntpsnmpd/ntpsnmpd.man.in@1.146 +2 -2 + NTP_4_2_7P329 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.146 +2 -2 + NTP_4_2_7P329 + + packageinfo.sh@1.332 +1 -1 + NTP_4_2_7P329 + + scripts/invoke-ntp-wait.texi@1.135 +1 -1 + NTP_4_2_7P329 + + scripts/ntp-wait.1ntp-waitman@1.146 +2 -2 + NTP_4_2_7P329 + + scripts/ntp-wait.1ntp-waitmdoc@1.146 +2 -2 + NTP_4_2_7P329 + + scripts/ntp-wait.html@1.150 +1 -1 + NTP_4_2_7P329 + + scripts/ntp-wait.man.in@1.146 +2 -2 + NTP_4_2_7P329 + + scripts/ntp-wait.mdoc.in@1.146 +2 -2 + NTP_4_2_7P329 + + sntp/invoke-sntp.texi@1.314 +2 -2 + NTP_4_2_7P329 + + sntp/sntp-opts.c@1.329 +4 -4 + NTP_4_2_7P329 + + sntp/sntp-opts.h@1.329 +3 -3 + NTP_4_2_7P329 + + sntp/sntp.1sntpman@1.149 +2 -2 + NTP_4_2_7P329 + + sntp/sntp.1sntpmdoc@1.149 +2 -2 + NTP_4_2_7P329 + + sntp/sntp.html@1.329 +2 -2 + NTP_4_2_7P329 + + sntp/sntp.man.in@1.149 +2 -2 + NTP_4_2_7P329 + + sntp/sntp.mdoc.in@1.149 +2 -2 + NTP_4_2_7P329 + + util/invoke-ntp-keygen.texi@1.318 +2 -2 + NTP_4_2_7P329 + + util/ntp-keygen-opts.c@1.332 +4 -4 + NTP_4_2_7P329 + + util/ntp-keygen-opts.h@1.332 +3 -3 + NTP_4_2_7P329 + + util/ntp-keygen.1ntp-keygenman@1.146 +2 -2 + NTP_4_2_7P329 + + util/ntp-keygen.1ntp-keygenmdoc@1.146 +2 -2 + NTP_4_2_7P329 + + util/ntp-keygen.man.in@1.146 +2 -2 + NTP_4_2_7P329 + + util/ntp-keygen.mdoc.in@1.146 +2 -2 + NTP_4_2_7P329 + +ChangeSet@1.2824, 2012-12-01 10:43:56+00:00, stenn@psp-fb1.ntp.org + Use an enum for the ACTS state table + + ChangeLog@1.1193 +1 -0 + Use an enum for the ACTS state table + + ntpd/refclock_acts.c@1.51.1.1 +8 -6 + Use an enum for the ACTS state table + +ChangeSet@1.2822.1.73, 2012-11-30 23:45:57-05:00, stenn@deacon.udel.edu + html doc reconciliation with DLM's copy + + ChangeLog@1.1191.1.63 +1 -0 + html doc reconciliation with DLM's copy + + html/authentic.html@1.13 +1 -1 + html doc reconciliation with DLM's copy + + html/copyright.html@1.60 +1 -1 + html doc reconciliation with DLM's copy + + html/decode.html@1.21 +1 -1 + html doc reconciliation with DLM's copy + + html/drivers/driver1.html@1.20 +1 -1 + html doc reconciliation with DLM's copy + + html/leap.html@1.5 +1 -1 + html doc reconciliation with DLM's copy + + html/miscopt.html@1.71 +1 -1 + html doc reconciliation with DLM's copy + + html/ntpd.html@1.57 +1 -1 + html doc reconciliation with DLM's copy + + html/ntpdate.html@1.23 +1 -1 + html doc reconciliation with DLM's copy + + html/ntpq.html@1.47 +1 -1 + html doc reconciliation with DLM's copy + + html/ntptrace.html@1.18 +1 -1 + html doc reconciliation with DLM's copy + + html/quick.html@1.24 +2 -2 + html doc reconciliation with DLM's copy + +ChangeSet@1.2822.1.72, 2012-11-30 11:34:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P328 + TAG: NTP_4_2_7P328 + + ChangeLog@1.1191.1.62 +1 -0 + NTP_4_2_7P328 + + ntpd/invoke-ntpd.texi@1.317 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.conf.5man@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.conf.5mdoc@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.conf.man.in@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.conf.mdoc.in@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.keys.5man@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.keys.5mdoc@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.keys.man.in@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntp.keys.mdoc.in@1.34 +2 -2 + NTP_4_2_7P328 + + ntpd/ntpd-opts.c@1.335 +4 -4 + NTP_4_2_7P328 + + ntpd/ntpd-opts.h@1.335 +3 -3 + NTP_4_2_7P328 + + ntpd/ntpd.1ntpdman@1.146 +2 -2 + NTP_4_2_7P328 + + ntpd/ntpd.1ntpdmdoc@1.146 +2 -2 + NTP_4_2_7P328 + + ntpd/ntpd.man.in@1.146 +2 -2 + NTP_4_2_7P328 + + ntpd/ntpd.mdoc.in@1.146 +2 -2 + NTP_4_2_7P328 + + ntpdc/invoke-ntpdc.texi@1.314 +2 -2 + NTP_4_2_7P328 + + ntpdc/ntpdc-opts.c@1.329 +4 -4 + NTP_4_2_7P328 + + ntpdc/ntpdc-opts.h@1.329 +3 -3 + NTP_4_2_7P328 + + ntpdc/ntpdc.1ntpdcman@1.145 +2 -2 + NTP_4_2_7P328 + + ntpdc/ntpdc.1ntpdcmdoc@1.145 +2 -2 + NTP_4_2_7P328 + + ntpdc/ntpdc.html@1.157 +2 -2 + NTP_4_2_7P328 + + ntpdc/ntpdc.man.in@1.145 +2 -2 + NTP_4_2_7P328 + + ntpdc/ntpdc.mdoc.in@1.145 +2 -2 + NTP_4_2_7P328 + + ntpq/invoke-ntpq.texi@1.316 +2 -2 + NTP_4_2_7P328 + + ntpq/ntpq-opts.c@1.331 +4 -4 + NTP_4_2_7P328 + + ntpq/ntpq-opts.h@1.331 +3 -3 + NTP_4_2_7P328 + + ntpq/ntpq.1ntpqman@1.145 +2 -2 + NTP_4_2_7P328 + + ntpq/ntpq.1ntpqmdoc@1.145 +2 -2 + NTP_4_2_7P328 + + ntpq/ntpq.man.in@1.145 +2 -2 + NTP_4_2_7P328 + + ntpq/ntpq.mdoc.in@1.145 +2 -2 + NTP_4_2_7P328 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.316 +2 -2 + NTP_4_2_7P328 + + ntpsnmpd/ntpsnmpd-opts.c@1.331 +4 -4 + NTP_4_2_7P328 + + ntpsnmpd/ntpsnmpd-opts.h@1.331 +3 -3 + NTP_4_2_7P328 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.145 +2 -2 + NTP_4_2_7P328 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.145 +2 -2 + NTP_4_2_7P328 + + ntpsnmpd/ntpsnmpd.man.in@1.145 +2 -2 + NTP_4_2_7P328 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.145 +2 -2 + NTP_4_2_7P328 + + packageinfo.sh@1.331 +1 -1 + NTP_4_2_7P328 + + scripts/invoke-ntp-wait.texi@1.134 +1 -1 + NTP_4_2_7P328 + + scripts/ntp-wait.1ntp-waitman@1.145 +2 -2 + NTP_4_2_7P328 + + scripts/ntp-wait.1ntp-waitmdoc@1.145 +2 -2 + NTP_4_2_7P328 + + scripts/ntp-wait.html@1.149 +1 -1 + NTP_4_2_7P328 + + scripts/ntp-wait.man.in@1.145 +2 -2 + NTP_4_2_7P328 + + scripts/ntp-wait.mdoc.in@1.145 +2 -2 + NTP_4_2_7P328 + + sntp/invoke-sntp.texi@1.313 +2 -2 + NTP_4_2_7P328 + + sntp/sntp-opts.c@1.328 +4 -4 + NTP_4_2_7P328 + + sntp/sntp-opts.h@1.328 +3 -3 + NTP_4_2_7P328 + + sntp/sntp.1sntpman@1.148 +2 -2 + NTP_4_2_7P328 + + sntp/sntp.1sntpmdoc@1.148 +2 -2 + NTP_4_2_7P328 + + sntp/sntp.html@1.328 +2 -2 + NTP_4_2_7P328 + + sntp/sntp.man.in@1.148 +2 -2 + NTP_4_2_7P328 + + sntp/sntp.mdoc.in@1.148 +2 -2 + NTP_4_2_7P328 + + util/invoke-ntp-keygen.texi@1.317 +2 -2 + NTP_4_2_7P328 + + util/ntp-keygen-opts.c@1.331 +4 -4 + NTP_4_2_7P328 + + util/ntp-keygen-opts.h@1.331 +3 -3 + NTP_4_2_7P328 + + util/ntp-keygen.1ntp-keygenman@1.145 +2 -2 + NTP_4_2_7P328 + + util/ntp-keygen.1ntp-keygenmdoc@1.145 +2 -2 + NTP_4_2_7P328 + + util/ntp-keygen.man.in@1.145 +2 -2 + NTP_4_2_7P328 + + util/ntp-keygen.mdoc.in@1.145 +2 -2 + NTP_4_2_7P328 + +ChangeSet@1.2822.1.71, 2012-11-30 06:00:13-05:00, stenn@deacon.udel.edu + html doc reconciliation with DLM's copy + + ChangeLog@1.1191.1.61 +1 -0 + html doc reconciliation with DLM's copy + + html/refclock.html@1.38 +1 -0 + html doc reconciliation with DLM's copy + +ChangeSet@1.2822.1.70, 2012-11-29 11:36:57+00:00, stenn@deacon.udel.edu + NTP_4_2_7P327 + TAG: NTP_4_2_7P327 + + ChangeLog@1.1191.1.60 +1 -0 + NTP_4_2_7P327 + + ntpd/invoke-ntpd.texi@1.316 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.conf.5man@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.conf.5mdoc@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.conf.man.in@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.conf.mdoc.in@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.keys.5man@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.keys.5mdoc@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.keys.man.in@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntp.keys.mdoc.in@1.33 +2 -2 + NTP_4_2_7P327 + + ntpd/ntpd-opts.c@1.334 +4 -4 + NTP_4_2_7P327 + + ntpd/ntpd-opts.h@1.334 +3 -3 + NTP_4_2_7P327 + + ntpd/ntpd.1ntpdman@1.145 +2 -2 + NTP_4_2_7P327 + + ntpd/ntpd.1ntpdmdoc@1.145 +2 -2 + NTP_4_2_7P327 + + ntpd/ntpd.man.in@1.145 +2 -2 + NTP_4_2_7P327 + + ntpd/ntpd.mdoc.in@1.145 +2 -2 + NTP_4_2_7P327 + + ntpdc/invoke-ntpdc.texi@1.313 +2 -2 + NTP_4_2_7P327 + + ntpdc/ntpdc-opts.c@1.328 +4 -4 + NTP_4_2_7P327 + + ntpdc/ntpdc-opts.h@1.328 +3 -3 + NTP_4_2_7P327 + + ntpdc/ntpdc.1ntpdcman@1.144 +2 -2 + NTP_4_2_7P327 + + ntpdc/ntpdc.1ntpdcmdoc@1.144 +2 -2 + NTP_4_2_7P327 + + ntpdc/ntpdc.html@1.156 +2 -2 + NTP_4_2_7P327 + + ntpdc/ntpdc.man.in@1.144 +2 -2 + NTP_4_2_7P327 + + ntpdc/ntpdc.mdoc.in@1.144 +2 -2 + NTP_4_2_7P327 + + ntpq/invoke-ntpq.texi@1.315 +2 -2 + NTP_4_2_7P327 + + ntpq/ntpq-opts.c@1.330 +4 -4 + NTP_4_2_7P327 + + ntpq/ntpq-opts.h@1.330 +3 -3 + NTP_4_2_7P327 + + ntpq/ntpq.1ntpqman@1.144 +2 -2 + NTP_4_2_7P327 + + ntpq/ntpq.1ntpqmdoc@1.144 +2 -2 + NTP_4_2_7P327 + + ntpq/ntpq.man.in@1.144 +2 -2 + NTP_4_2_7P327 + + ntpq/ntpq.mdoc.in@1.144 +2 -2 + NTP_4_2_7P327 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.315 +2 -2 + NTP_4_2_7P327 + + ntpsnmpd/ntpsnmpd-opts.c@1.330 +4 -4 + NTP_4_2_7P327 + + ntpsnmpd/ntpsnmpd-opts.h@1.330 +3 -3 + NTP_4_2_7P327 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.144 +2 -2 + NTP_4_2_7P327 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.144 +2 -2 + NTP_4_2_7P327 + + ntpsnmpd/ntpsnmpd.man.in@1.144 +2 -2 + NTP_4_2_7P327 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.144 +2 -2 + NTP_4_2_7P327 + + packageinfo.sh@1.330 +1 -1 + NTP_4_2_7P327 + + scripts/invoke-ntp-wait.texi@1.133 +1 -1 + NTP_4_2_7P327 + + scripts/ntp-wait.1ntp-waitman@1.144 +2 -2 + NTP_4_2_7P327 + + scripts/ntp-wait.1ntp-waitmdoc@1.144 +2 -2 + NTP_4_2_7P327 + + scripts/ntp-wait.html@1.148 +1 -1 + NTP_4_2_7P327 + + scripts/ntp-wait.man.in@1.144 +2 -2 + NTP_4_2_7P327 + + scripts/ntp-wait.mdoc.in@1.144 +2 -2 + NTP_4_2_7P327 + + sntp/invoke-sntp.texi@1.312 +2 -2 + NTP_4_2_7P327 + + sntp/sntp-opts.c@1.327 +4 -4 + NTP_4_2_7P327 + + sntp/sntp-opts.h@1.327 +3 -3 + NTP_4_2_7P327 + + sntp/sntp.1sntpman@1.147 +2 -2 + NTP_4_2_7P327 + + sntp/sntp.1sntpmdoc@1.147 +2 -2 + NTP_4_2_7P327 + + sntp/sntp.html@1.327 +2 -2 + NTP_4_2_7P327 + + sntp/sntp.man.in@1.147 +2 -2 + NTP_4_2_7P327 + + sntp/sntp.mdoc.in@1.147 +2 -2 + NTP_4_2_7P327 + + util/invoke-ntp-keygen.texi@1.316 +21 -2 + NTP_4_2_7P327 + + util/ntp-keygen-opts.c@1.330 +277 -203 + NTP_4_2_7P327 + + util/ntp-keygen-opts.h@1.330 +40 -30 + NTP_4_2_7P327 + + util/ntp-keygen.1ntp-keygenman@1.144 +15 -2 + NTP_4_2_7P327 + + util/ntp-keygen.1ntp-keygenmdoc@1.144 +14 -2 + NTP_4_2_7P327 + + util/ntp-keygen.man.in@1.144 +15 -2 + NTP_4_2_7P327 + + util/ntp-keygen.mdoc.in@1.144 +14 -2 + NTP_4_2_7P327 + +ChangeSet@1.2822.1.69, 2012-11-29 03:55:28-05:00, stenn@deacon.udel.edu + [Bug 2024] Identify Events in the system status word in decode.html + + ChangeLog@1.1191.1.59 +1 -0 + [Bug 2024] Identify Events in the system status word in decode.html + + html/decode.html@1.20 +3 -3 + [Bug 2024] Identify Events in the system status word in decode.html + +ChangeSet@1.2822.1.68, 2012-11-29 03:48:03-05:00, stenn@deacon.udel.edu + [Bug 2040] Provide a command-line option for the identity key bits + + util/ntp-keygen.c@1.94 +4 -0 + [Bug 2040] Provide a command-line option for the identity key bits + +ChangeSet@1.2822.1.67, 2012-11-29 03:45:42-05:00, stenn@deacon.udel.edu + [Bug 2040] Provide a command-line option for the identity key bits + + ChangeLog@1.1191.1.58 +1 -0 + [Bug 2040] Provide a command-line option for the identity key bits + + html/keygen.html@1.32 +4 -2 + [Bug 2040] Provide a command-line option for the identity key bits + + util/ntp-keygen-opts.def@1.20 +13 -0 + [Bug 2040] Provide a command-line option for the identity key bits + +ChangeSet@1.2822.1.66, 2012-11-29 08:21:55+00:00, stenn@psp-fb1.ntp.org + Create loc/darwin for Mac OSX + + ChangeLog@1.1191.1.57 +1 -0 + Create loc/darwin for Mac OSX + + sntp/loc/darwin@1.1 +13 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/loc/darwin + + sntp/loc/darwin@1.0 +0 -0 + +ChangeSet@1.2822.1.65, 2012-11-21 11:33:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P326 + TAG: NTP_4_2_7P326 + + ChangeLog@1.1191.1.56 +1 -0 + NTP_4_2_7P326 + + ntpd/invoke-ntpd.texi@1.315 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.conf.5man@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.conf.5mdoc@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.conf.man.in@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.conf.mdoc.in@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.keys.5man@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.keys.5mdoc@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.keys.man.in@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntp.keys.mdoc.in@1.32 +2 -2 + NTP_4_2_7P326 + + ntpd/ntpd-opts.c@1.333 +4 -4 + NTP_4_2_7P326 + + ntpd/ntpd-opts.h@1.333 +3 -3 + NTP_4_2_7P326 + + ntpd/ntpd.1ntpdman@1.144 +2 -2 + NTP_4_2_7P326 + + ntpd/ntpd.1ntpdmdoc@1.144 +2 -2 + NTP_4_2_7P326 + + ntpd/ntpd.man.in@1.144 +2 -2 + NTP_4_2_7P326 + + ntpd/ntpd.mdoc.in@1.144 +2 -2 + NTP_4_2_7P326 + + ntpdc/invoke-ntpdc.texi@1.312 +2 -2 + NTP_4_2_7P326 + + ntpdc/ntpdc-opts.c@1.327 +4 -4 + NTP_4_2_7P326 + + ntpdc/ntpdc-opts.h@1.327 +3 -3 + NTP_4_2_7P326 + + ntpdc/ntpdc.1ntpdcman@1.143 +2 -2 + NTP_4_2_7P326 + + ntpdc/ntpdc.1ntpdcmdoc@1.143 +2 -2 + NTP_4_2_7P326 + + ntpdc/ntpdc.html@1.155 +2 -2 + NTP_4_2_7P326 + + ntpdc/ntpdc.man.in@1.143 +2 -2 + NTP_4_2_7P326 + + ntpdc/ntpdc.mdoc.in@1.143 +2 -2 + NTP_4_2_7P326 + + ntpq/invoke-ntpq.texi@1.314 +2 -2 + NTP_4_2_7P326 + + ntpq/ntpq-opts.c@1.329 +4 -4 + NTP_4_2_7P326 + + ntpq/ntpq-opts.h@1.329 +3 -3 + NTP_4_2_7P326 + + ntpq/ntpq.1ntpqman@1.143 +2 -2 + NTP_4_2_7P326 + + ntpq/ntpq.1ntpqmdoc@1.143 +2 -2 + NTP_4_2_7P326 + + ntpq/ntpq.man.in@1.143 +2 -2 + NTP_4_2_7P326 + + ntpq/ntpq.mdoc.in@1.143 +2 -2 + NTP_4_2_7P326 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.314 +2 -2 + NTP_4_2_7P326 + + ntpsnmpd/ntpsnmpd-opts.c@1.329 +4 -4 + NTP_4_2_7P326 + + ntpsnmpd/ntpsnmpd-opts.h@1.329 +3 -3 + NTP_4_2_7P326 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.143 +2 -2 + NTP_4_2_7P326 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.143 +2 -2 + NTP_4_2_7P326 + + ntpsnmpd/ntpsnmpd.man.in@1.143 +2 -2 + NTP_4_2_7P326 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.143 +2 -2 + NTP_4_2_7P326 + + packageinfo.sh@1.329 +1 -1 + NTP_4_2_7P326 + + scripts/invoke-ntp-wait.texi@1.132 +1 -1 + NTP_4_2_7P326 + + scripts/ntp-wait.1ntp-waitman@1.143 +2 -2 + NTP_4_2_7P326 + + scripts/ntp-wait.1ntp-waitmdoc@1.143 +2 -2 + NTP_4_2_7P326 + + scripts/ntp-wait.html@1.147 +1 -1 + NTP_4_2_7P326 + + scripts/ntp-wait.man.in@1.143 +2 -2 + NTP_4_2_7P326 + + scripts/ntp-wait.mdoc.in@1.143 +2 -2 + NTP_4_2_7P326 + + sntp/invoke-sntp.texi@1.311 +2 -2 + NTP_4_2_7P326 + + sntp/sntp-opts.c@1.326 +4 -4 + NTP_4_2_7P326 + + sntp/sntp-opts.h@1.326 +3 -3 + NTP_4_2_7P326 + + sntp/sntp.1sntpman@1.146 +2 -2 + NTP_4_2_7P326 + + sntp/sntp.1sntpmdoc@1.146 +2 -2 + NTP_4_2_7P326 + + sntp/sntp.html@1.326 +2 -2 + NTP_4_2_7P326 + + sntp/sntp.man.in@1.146 +2 -2 + NTP_4_2_7P326 + + sntp/sntp.mdoc.in@1.146 +2 -2 + NTP_4_2_7P326 + + util/invoke-ntp-keygen.texi@1.315 +2 -2 + NTP_4_2_7P326 + + util/ntp-keygen-opts.c@1.329 +4 -4 + NTP_4_2_7P326 + + util/ntp-keygen-opts.h@1.329 +3 -3 + NTP_4_2_7P326 + + util/ntp-keygen.1ntp-keygenman@1.143 +2 -2 + NTP_4_2_7P326 + + util/ntp-keygen.1ntp-keygenmdoc@1.143 +2 -2 + NTP_4_2_7P326 + + util/ntp-keygen.man.in@1.143 +2 -2 + NTP_4_2_7P326 + + util/ntp-keygen.mdoc.in@1.143 +2 -2 + NTP_4_2_7P326 + +ChangeSet@1.2822.11.2, 2012-11-20 11:35:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P325 + TAG: NTP_4_2_7P325 + + ChangeLog@1.1191.8.1 +1 -0 + NTP_4_2_7P325 + + ntpd/invoke-ntpd.texi@1.314 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.conf.5man@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.conf.5mdoc@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.conf.man.in@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.conf.mdoc.in@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.keys.5man@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.keys.5mdoc@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.keys.man.in@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntp.keys.mdoc.in@1.31 +2 -2 + NTP_4_2_7P325 + + ntpd/ntpd-opts.c@1.332 +4 -4 + NTP_4_2_7P325 + + ntpd/ntpd-opts.h@1.332 +3 -3 + NTP_4_2_7P325 + + ntpd/ntpd.1ntpdman@1.143 +2 -2 + NTP_4_2_7P325 + + ntpd/ntpd.1ntpdmdoc@1.143 +2 -2 + NTP_4_2_7P325 + + ntpd/ntpd.man.in@1.143 +2 -2 + NTP_4_2_7P325 + + ntpd/ntpd.mdoc.in@1.143 +2 -2 + NTP_4_2_7P325 + + ntpdc/invoke-ntpdc.texi@1.311 +2 -2 + NTP_4_2_7P325 + + ntpdc/ntpdc-opts.c@1.326 +4 -4 + NTP_4_2_7P325 + + ntpdc/ntpdc-opts.h@1.326 +3 -3 + NTP_4_2_7P325 + + ntpdc/ntpdc.1ntpdcman@1.142 +2 -2 + NTP_4_2_7P325 + + ntpdc/ntpdc.1ntpdcmdoc@1.142 +2 -2 + NTP_4_2_7P325 + + ntpdc/ntpdc.html@1.154 +2 -2 + NTP_4_2_7P325 + + ntpdc/ntpdc.man.in@1.142 +2 -2 + NTP_4_2_7P325 + + ntpdc/ntpdc.mdoc.in@1.142 +2 -2 + NTP_4_2_7P325 + + ntpq/invoke-ntpq.texi@1.313 +2 -2 + NTP_4_2_7P325 + + ntpq/ntpq-opts.c@1.328 +4 -4 + NTP_4_2_7P325 + + ntpq/ntpq-opts.h@1.328 +3 -3 + NTP_4_2_7P325 + + ntpq/ntpq.1ntpqman@1.142 +2 -2 + NTP_4_2_7P325 + + ntpq/ntpq.1ntpqmdoc@1.142 +2 -2 + NTP_4_2_7P325 + + ntpq/ntpq.man.in@1.142 +2 -2 + NTP_4_2_7P325 + + ntpq/ntpq.mdoc.in@1.142 +2 -2 + NTP_4_2_7P325 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.313 +2 -2 + NTP_4_2_7P325 + + ntpsnmpd/ntpsnmpd-opts.c@1.328 +4 -4 + NTP_4_2_7P325 + + ntpsnmpd/ntpsnmpd-opts.h@1.328 +3 -3 + NTP_4_2_7P325 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.142 +2 -2 + NTP_4_2_7P325 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.142 +2 -2 + NTP_4_2_7P325 + + ntpsnmpd/ntpsnmpd.man.in@1.142 +2 -2 + NTP_4_2_7P325 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.142 +2 -2 + NTP_4_2_7P325 + + packageinfo.sh@1.328 +1 -1 + NTP_4_2_7P325 + + scripts/invoke-ntp-wait.texi@1.131 +1 -1 + NTP_4_2_7P325 + + scripts/ntp-wait.1ntp-waitman@1.142 +2 -2 + NTP_4_2_7P325 + + scripts/ntp-wait.1ntp-waitmdoc@1.142 +2 -2 + NTP_4_2_7P325 + + scripts/ntp-wait.html@1.146 +1 -1 + NTP_4_2_7P325 + + scripts/ntp-wait.man.in@1.142 +2 -2 + NTP_4_2_7P325 + + scripts/ntp-wait.mdoc.in@1.142 +2 -2 + NTP_4_2_7P325 + + sntp/invoke-sntp.texi@1.310 +2 -2 + NTP_4_2_7P325 + + sntp/sntp-opts.c@1.325 +4 -4 + NTP_4_2_7P325 + + sntp/sntp-opts.h@1.325 +3 -3 + NTP_4_2_7P325 + + sntp/sntp.1sntpman@1.145 +2 -2 + NTP_4_2_7P325 + + sntp/sntp.1sntpmdoc@1.145 +2 -2 + NTP_4_2_7P325 + + sntp/sntp.html@1.325 +2 -2 + NTP_4_2_7P325 + + sntp/sntp.man.in@1.145 +2 -2 + NTP_4_2_7P325 + + sntp/sntp.mdoc.in@1.145 +2 -2 + NTP_4_2_7P325 + + util/invoke-ntp-keygen.texi@1.314 +2 -2 + NTP_4_2_7P325 + + util/ntp-keygen-opts.c@1.328 +4 -4 + NTP_4_2_7P325 + + util/ntp-keygen-opts.h@1.328 +3 -3 + NTP_4_2_7P325 + + util/ntp-keygen.1ntp-keygenman@1.142 +2 -2 + NTP_4_2_7P325 + + util/ntp-keygen.1ntp-keygenmdoc@1.142 +2 -2 + NTP_4_2_7P325 + + util/ntp-keygen.man.in@1.142 +2 -2 + NTP_4_2_7P325 + + util/ntp-keygen.mdoc.in@1.142 +2 -2 + NTP_4_2_7P325 + +ChangeSet@1.2822.11.1, 2012-11-20 03:45:54-05:00, stenn@deacon.udel.edu + typo fix + + html/leap.html@1.4 +1 -1 + typo fix + +ChangeSet@1.2822.1.62, 2012-11-19 23:37:09-05:00, stenn@deacon.udel.edu + [Bug 2202] ntpq.html: there is no "acv" billboard + + ChangeLog@1.1191.1.53 +1 -0 + [Bug 2202] ntpq.html: there is no "acv" billboard + + html/ntpq.html@1.46 +1 -1 + [Bug 2202] ntpq.html: there is no "acv" billboard + +ChangeSet@1.2822.10.2, 2012-11-19 20:17:35-08:00, harlan@hms-mbp11.local + [Bug 2246] Clear sys_leap when voting says to disarm the leap + + ChangeLog@1.1191.7.2 +1 -0 + [Bug 2246] Clear sys_leap when voting says to disarm the leap + + ntpd/ntp_proto.c@1.343 +1 -0 + [Bug 2246] Clear sys_leap when voting says to disarm the leap + +ChangeSet@1.2822.10.1, 2012-11-19 18:44:38-08:00, harlan@hms-mbp11.local + [Bug 1214] 'proto: precision = ...' should be at INFO, not NOTICE + + ChangeLog@1.1191.7.1 +1 -0 + [Bug 1214] 'proto: precision = ...' should be at INFO, not NOTICE + + ntpd/ntp_proto.c@1.342 +1 -1 + [Bug 1214] 'proto: precision = ...' should be at INFO, not NOTICE + +ChangeSet@1.2822.1.61, 2012-11-19 19:38:43+01:00, jnperlin@armageddon. + [Bug 2306] Keep pps hack for Win32 even if user-mode/loopback PPS API is activated on a serial line. + + ChangeLog@1.1191.1.52 +2 -0 + [Bug 2306] Keep pps hack for Win32 even if user-mode/loopback PPS API is activated on a serial line. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.68 +10 -1 + [Bug 2306] Keep pps hack for Win32 even if user-mode/loopback PPS API is activated on a serial line. + +ChangeSet@1.2822.1.60, 2012-11-19 12:05:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P324 + TAG: NTP_4_2_7P324 + + ChangeLog@1.1191.1.51 +1 -0 + NTP_4_2_7P324 + + ntpd/invoke-ntpd.texi@1.313 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.conf.5man@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.conf.5mdoc@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.conf.man.in@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.conf.mdoc.in@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.keys.5man@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.keys.5mdoc@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.keys.man.in@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntp.keys.mdoc.in@1.30 +2 -2 + NTP_4_2_7P324 + + ntpd/ntpd-opts.c@1.331 +4 -4 + NTP_4_2_7P324 + + ntpd/ntpd-opts.h@1.331 +3 -3 + NTP_4_2_7P324 + + ntpd/ntpd.1ntpdman@1.142 +2 -2 + NTP_4_2_7P324 + + ntpd/ntpd.1ntpdmdoc@1.142 +2 -2 + NTP_4_2_7P324 + + ntpd/ntpd.man.in@1.142 +2 -2 + NTP_4_2_7P324 + + ntpd/ntpd.mdoc.in@1.142 +2 -2 + NTP_4_2_7P324 + + ntpdc/invoke-ntpdc.texi@1.310 +2 -2 + NTP_4_2_7P324 + + ntpdc/ntpdc-opts.c@1.325 +4 -4 + NTP_4_2_7P324 + + ntpdc/ntpdc-opts.h@1.325 +3 -3 + NTP_4_2_7P324 + + ntpdc/ntpdc.1ntpdcman@1.141 +2 -2 + NTP_4_2_7P324 + + ntpdc/ntpdc.1ntpdcmdoc@1.141 +2 -2 + NTP_4_2_7P324 + + ntpdc/ntpdc.html@1.153 +2 -2 + NTP_4_2_7P324 + + ntpdc/ntpdc.man.in@1.141 +2 -2 + NTP_4_2_7P324 + + ntpdc/ntpdc.mdoc.in@1.141 +2 -2 + NTP_4_2_7P324 + + ntpq/invoke-ntpq.texi@1.312 +2 -2 + NTP_4_2_7P324 + + ntpq/ntpq-opts.c@1.327 +4 -4 + NTP_4_2_7P324 + + ntpq/ntpq-opts.h@1.327 +3 -3 + NTP_4_2_7P324 + + ntpq/ntpq.1ntpqman@1.141 +2 -2 + NTP_4_2_7P324 + + ntpq/ntpq.1ntpqmdoc@1.141 +2 -2 + NTP_4_2_7P324 + + ntpq/ntpq.man.in@1.141 +2 -2 + NTP_4_2_7P324 + + ntpq/ntpq.mdoc.in@1.141 +2 -2 + NTP_4_2_7P324 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.312 +2 -2 + NTP_4_2_7P324 + + ntpsnmpd/ntpsnmpd-opts.c@1.327 +4 -4 + NTP_4_2_7P324 + + ntpsnmpd/ntpsnmpd-opts.h@1.327 +3 -3 + NTP_4_2_7P324 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.141 +2 -2 + NTP_4_2_7P324 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.141 +2 -2 + NTP_4_2_7P324 + + ntpsnmpd/ntpsnmpd.man.in@1.141 +2 -2 + NTP_4_2_7P324 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.141 +2 -2 + NTP_4_2_7P324 + + packageinfo.sh@1.327 +1 -1 + NTP_4_2_7P324 + + scripts/invoke-ntp-wait.texi@1.130 +1 -1 + NTP_4_2_7P324 + + scripts/ntp-wait.1ntp-waitman@1.141 +2 -2 + NTP_4_2_7P324 + + scripts/ntp-wait.1ntp-waitmdoc@1.141 +2 -2 + NTP_4_2_7P324 + + scripts/ntp-wait.html@1.145 +1 -1 + NTP_4_2_7P324 + + scripts/ntp-wait.man.in@1.141 +2 -2 + NTP_4_2_7P324 + + scripts/ntp-wait.mdoc.in@1.141 +2 -2 + NTP_4_2_7P324 + + sntp/invoke-sntp.texi@1.309 +2 -2 + NTP_4_2_7P324 + + sntp/sntp-opts.c@1.324 +4 -4 + NTP_4_2_7P324 + + sntp/sntp-opts.h@1.324 +3 -3 + NTP_4_2_7P324 + + sntp/sntp.1sntpman@1.144 +2 -2 + NTP_4_2_7P324 + + sntp/sntp.1sntpmdoc@1.144 +2 -2 + NTP_4_2_7P324 + + sntp/sntp.html@1.324 +2 -2 + NTP_4_2_7P324 + + sntp/sntp.man.in@1.144 +2 -2 + NTP_4_2_7P324 + + sntp/sntp.mdoc.in@1.144 +2 -2 + NTP_4_2_7P324 + + util/invoke-ntp-keygen.texi@1.313 +2 -2 + NTP_4_2_7P324 + + util/ntp-keygen-opts.c@1.327 +4 -4 + NTP_4_2_7P324 + + util/ntp-keygen-opts.h@1.327 +3 -3 + NTP_4_2_7P324 + + util/ntp-keygen.1ntp-keygenman@1.141 +2 -2 + NTP_4_2_7P324 + + util/ntp-keygen.1ntp-keygenmdoc@1.141 +2 -2 + NTP_4_2_7P324 + + util/ntp-keygen.man.in@1.141 +2 -2 + NTP_4_2_7P324 + + util/ntp-keygen.mdoc.in@1.141 +2 -2 + NTP_4_2_7P324 + +ChangeSet@1.2822.1.59, 2012-11-19 02:49:32-08:00, harlan@hms-mbp11.local + [Bug 2098] Install DLM's HTML documentation + + ChangeLog@1.1191.1.50 +1 -0 + [Bug 2098] Install DLM's HTML documentation + + Makefile.am@1.116 +7 -0 + [Bug 2098] Install DLM's HTML documentation + + configure.ac@1.554 +1 -1 + [Bug 2098] Install DLM's HTML documentation + +ChangeSet@1.2822.1.58, 2012-11-19 02:32:45-05:00, stenn@deacon.udel.edu + Use "diff -u" when comparing complete.conf + + ntpd/Makefile.am@1.124 +1 -1 + Use "diff -u" when comparing complete.conf + +ChangeSet@1.2822.1.56, 2012-11-19 02:01:25-05:00, stenn@deacon.udel.edu + Reinstate change from Mike T. to authentic.html + + ChangeLog@1.1191.1.48 +1 -0 + Reinstate change from Mike T. to authentic.html + + html/authentic.html@1.12 +2 -2 + Reinstate change from Mike T. to authentic.html + +ChangeSet@1.2822.1.55, 2012-11-19 01:50:59-05:00, stenn@deacon.udel.edu + [Bug 1223] cleanup for rlimit changes + + ChangeLog@1.1191.1.47 +1 -0 + [Bug 1223] cleanup for rlimit changes + +ChangeSet@1.2822.9.1, 2012-11-18 12:58:00+00:00, stenn@deacon.udel.edu + NTP_4_2_7P323 + TAG: NTP_4_2_7P323 + + ChangeLog@1.1191.1.46 +1 -0 + NTP_4_2_7P323 + + ntpd/invoke-ntpd.texi@1.312 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.conf.5man@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.conf.5mdoc@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.conf.man.in@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.conf.mdoc.in@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.keys.5man@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.keys.5mdoc@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.keys.man.in@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntp.keys.mdoc.in@1.29 +2 -2 + NTP_4_2_7P323 + + ntpd/ntpd-opts.c@1.330 +4 -4 + NTP_4_2_7P323 + + ntpd/ntpd-opts.h@1.330 +3 -3 + NTP_4_2_7P323 + + ntpd/ntpd.1ntpdman@1.141 +2 -2 + NTP_4_2_7P323 + + ntpd/ntpd.1ntpdmdoc@1.141 +2 -2 + NTP_4_2_7P323 + + ntpd/ntpd.man.in@1.141 +2 -2 + NTP_4_2_7P323 + + ntpd/ntpd.mdoc.in@1.141 +2 -2 + NTP_4_2_7P323 + + ntpdc/invoke-ntpdc.texi@1.309 +2 -2 + NTP_4_2_7P323 + + ntpdc/ntpdc-opts.c@1.324 +4 -4 + NTP_4_2_7P323 + + ntpdc/ntpdc-opts.h@1.324 +3 -3 + NTP_4_2_7P323 + + ntpdc/ntpdc.1ntpdcman@1.140 +2 -2 + NTP_4_2_7P323 + + ntpdc/ntpdc.1ntpdcmdoc@1.140 +2 -2 + NTP_4_2_7P323 + + ntpdc/ntpdc.html@1.152 +2 -2 + NTP_4_2_7P323 + + ntpdc/ntpdc.man.in@1.140 +2 -2 + NTP_4_2_7P323 + + ntpdc/ntpdc.mdoc.in@1.140 +2 -2 + NTP_4_2_7P323 + + ntpq/invoke-ntpq.texi@1.311 +2 -2 + NTP_4_2_7P323 + + ntpq/ntpq-opts.c@1.326 +4 -4 + NTP_4_2_7P323 + + ntpq/ntpq-opts.h@1.326 +3 -3 + NTP_4_2_7P323 + + ntpq/ntpq.1ntpqman@1.140 +2 -2 + NTP_4_2_7P323 + + ntpq/ntpq.1ntpqmdoc@1.140 +2 -2 + NTP_4_2_7P323 + + ntpq/ntpq.man.in@1.140 +2 -2 + NTP_4_2_7P323 + + ntpq/ntpq.mdoc.in@1.140 +2 -2 + NTP_4_2_7P323 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.311 +2 -2 + NTP_4_2_7P323 + + ntpsnmpd/ntpsnmpd-opts.c@1.326 +4 -4 + NTP_4_2_7P323 + + ntpsnmpd/ntpsnmpd-opts.h@1.326 +3 -3 + NTP_4_2_7P323 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.140 +2 -2 + NTP_4_2_7P323 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.140 +2 -2 + NTP_4_2_7P323 + + ntpsnmpd/ntpsnmpd.man.in@1.140 +2 -2 + NTP_4_2_7P323 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.140 +2 -2 + NTP_4_2_7P323 + + packageinfo.sh@1.326 +1 -1 + NTP_4_2_7P323 + + scripts/invoke-ntp-wait.texi@1.129 +111 -1 + NTP_4_2_7P323 + + scripts/ntp-wait.1ntp-waitman@1.140 +2 -2 + NTP_4_2_7P323 + + scripts/ntp-wait.1ntp-waitmdoc@1.140 +2 -2 + NTP_4_2_7P323 + + scripts/ntp-wait.html@1.144 +152 -4 + NTP_4_2_7P323 + + scripts/ntp-wait.man.in@1.140 +2 -2 + NTP_4_2_7P323 + + scripts/ntp-wait.mdoc.in@1.140 +2 -2 + NTP_4_2_7P323 + + sntp/invoke-sntp.texi@1.308 +2 -2 + NTP_4_2_7P323 + + sntp/sntp-opts.c@1.323 +4 -4 + NTP_4_2_7P323 + + sntp/sntp-opts.h@1.323 +3 -3 + NTP_4_2_7P323 + + sntp/sntp.1sntpman@1.143 +2 -2 + NTP_4_2_7P323 + + sntp/sntp.1sntpmdoc@1.143 +2 -2 + NTP_4_2_7P323 + + sntp/sntp.html@1.323 +2 -2 + NTP_4_2_7P323 + + sntp/sntp.man.in@1.143 +2 -2 + NTP_4_2_7P323 + + sntp/sntp.mdoc.in@1.143 +2 -2 + NTP_4_2_7P323 + + util/invoke-ntp-keygen.texi@1.312 +2 -2 + NTP_4_2_7P323 + + util/ntp-keygen-opts.c@1.326 +4 -4 + NTP_4_2_7P323 + + util/ntp-keygen-opts.h@1.326 +3 -3 + NTP_4_2_7P323 + + util/ntp-keygen.1ntp-keygenman@1.140 +2 -2 + NTP_4_2_7P323 + + util/ntp-keygen.1ntp-keygenmdoc@1.140 +2 -2 + NTP_4_2_7P323 + + util/ntp-keygen.man.in@1.140 +2 -2 + NTP_4_2_7P323 + + util/ntp-keygen.mdoc.in@1.140 +2 -2 + NTP_4_2_7P323 + +ChangeSet@1.2822.8.2, 2012-11-18 07:31:57-05:00, stenn@psp-deb1.ntp.org + added ntp_rlimit.m4 + + sntp/m4/ntp_rlimit.m4@1.1 +66 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/m4/ntp_rlimit.m4 + + sntp/m4/ntp_rlimit.m4@1.0 +0 -0 + +ChangeSet@1.2822.8.1, 2012-11-18 12:15:14+00:00, stenn@psp-fb1.ntp.org + rlimit cleanup + + configure.ac@1.553 +57 -54 + rlimit cleanup + + ntpd/Makefile.am@1.123 +6 -6 + rlimit cleanup + + ntpd/complete.conf.in@1.25 +1 -1 + rlimit cleanup + + ntpd/complete.conf.in@1.24, stenn@psp-deb1.ntp.org +0 -0 + Rename: ntpd/complete.conf -> ntpd/complete.conf.in + + ntpd/ntp_parser.c@1.83 +422 -418 + rlimit cleanup + + ntpd/ntp_parser.h@1.49 +6 -7 + rlimit cleanup + + ntpd/ntp_parser.y@1.77 +1 -1 + rlimit cleanup + +ChangeSet@1.2822.7.1, 2012-11-18 12:15:34+01:00, jnperlin@armageddon. + [Bug 2306] Added user-mode/loop-back PPS API provider for Win32 + + ChangeLog@1.1191.6.1 +1 -0 + [Bug 2306] Added user-mode/loop-back PPS API provider for Win32 + + include/ntp_refclock.h@1.36 +4 -0 + [Bug 2306](user-mode PPS API) add device context handle for Win32 + + ports/winnt/include/ntp_iocompletionport.h@1.20 +1 -0 + [Bug 2306](user-mode PPS API) support clean removal of clocks + + ports/winnt/include/termios.h@1.16 +1 -0 + [Bug 2306](user-mode PPS API) check for DUPs of serial line device handles + + ports/winnt/libntp/termios.c@1.28 +18 -0 + [Bug 2306](user-mode PPS API) check for DUPs of serial line device handles + + ports/winnt/ntpd/ntp_iocompletionport.c@1.67 +383 -64 + [Bug 2306](user-mode PPS API) provide wiring and lock-free buffers for data exchange with loop-back PPS API + + ports/winnt/ppsapi/loopback/monolithic-serialpps-timepps.h@1.1 +714 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/ppsapi/loopback/monolithic-serialpps-timepps.h@1.0 +0 -0 + + ports/winnt/ppsapi/loopback/monolithic-serialpps-timepps.txt@1.1 +52 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/ppsapi/loopback/monolithic-serialpps-timepps.txt@1.0 +0 -0 + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.c@1.1 +465 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.c@1.0 +0 -0 + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.def@1.1 +9 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.def@1.0 +0 -0 + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.h@1.1 +49 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/ppsapi/loopback/src/loopback-ppsapi.h@1.0 +0 -0 + + ports/winnt/ppsapi/loopback/src/sys/time.h@1.1 +18 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/ppsapi/loopback/src/sys/time.h@1.0 +0 -0 + + ports/winnt/ppsapi/loopback/src/timepps.h@1.1 +805 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/ppsapi/loopback/src/timepps.h@1.0 +0 -0 + + ports/winnt/vs2008/instsrv/instsrv.vcproj@1.6 +25 -20 + [Bug 2306](user-mode PPS API) cleanup of build process + + ports/winnt/vs2008/libntp/libntp.vcproj@1.47 +18 -17 + [Bug 2306](user-mode PPS API) cleanup of build process + + ports/winnt/vs2008/loopback-pps/loopback-ppsapi-provider.vcproj@1.1 +256 -0 + [Bug 2306](user-mode PPS API) PPS-API implementation + + ports/winnt/vs2008/loopback-pps/loopback-ppsapi-provider.vcproj@1.0 +0 -0 + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.14 +25 -21 + [Bug 2306](user-mode PPS API) cleanup of build process + + ports/winnt/vs2008/ntp.sln@1.10 +9 -0 + [Bug 2306](user-mode PPS API) add DLL project + + ports/winnt/vs2008/ntpd-keyword-gen/ntpd-keyword-gen.vcproj@1.2 +19 -9 + [Bug 2306](user-mode PPS API) cleanup of build process + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.45 +25 -24 + [Bug 2306](user-mode PPS API) cleanup of build process + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.14 +26 -21 + [Bug 2306](user-mode PPS API) cleanup of build process + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.16 +26 -21 + [Bug 2306](user-mode PPS API) cleanup of build process + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.15 +26 -21 + [Bug 2306](user-mode PPS API) cleanup of build process + +ChangeSet@1.2822.1.50, 2012-11-18 03:37:42-05:00, stenn@psp-deb1.ntp.org + RLIMIT header cleanup + + ntpd/ntp_config.c@1.308 +3 -0 + RLIMIT header cleanup + + ntpd/ntpd.c@1.139 +0 -3 + RLIMIT header cleanup + +ChangeSet@1.2822.6.1, 2012-11-15 11:21:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P322 + TAG: NTP_4_2_7P322 + + ChangeLog@1.1191.5.1 +1 -0 + NTP_4_2_7P322 + + ntpd/invoke-ntpd.texi@1.311 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.conf.5man@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.conf.5mdoc@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.conf.man.in@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.conf.mdoc.in@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.keys.5man@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.keys.5mdoc@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.keys.man.in@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntp.keys.mdoc.in@1.28 +2 -2 + NTP_4_2_7P322 + + ntpd/ntpd-opts.c@1.329 +4 -4 + NTP_4_2_7P322 + + ntpd/ntpd-opts.h@1.329 +3 -3 + NTP_4_2_7P322 + + ntpd/ntpd.1ntpdman@1.140 +2 -2 + NTP_4_2_7P322 + + ntpd/ntpd.1ntpdmdoc@1.140 +2 -2 + NTP_4_2_7P322 + + ntpd/ntpd.man.in@1.140 +2 -2 + NTP_4_2_7P322 + + ntpd/ntpd.mdoc.in@1.140 +2 -2 + NTP_4_2_7P322 + + ntpdc/invoke-ntpdc.texi@1.308 +2 -2 + NTP_4_2_7P322 + + ntpdc/ntpdc-opts.c@1.323 +4 -4 + NTP_4_2_7P322 + + ntpdc/ntpdc-opts.h@1.323 +3 -3 + NTP_4_2_7P322 + + ntpdc/ntpdc.1ntpdcman@1.139 +2 -2 + NTP_4_2_7P322 + + ntpdc/ntpdc.1ntpdcmdoc@1.139 +2 -2 + NTP_4_2_7P322 + + ntpdc/ntpdc.html@1.151 +2 -2 + NTP_4_2_7P322 + + ntpdc/ntpdc.man.in@1.139 +2 -2 + NTP_4_2_7P322 + + ntpdc/ntpdc.mdoc.in@1.139 +2 -2 + NTP_4_2_7P322 + + ntpq/invoke-ntpq.texi@1.310 +2 -2 + NTP_4_2_7P322 + + ntpq/ntpq-opts.c@1.325 +4 -4 + NTP_4_2_7P322 + + ntpq/ntpq-opts.h@1.325 +3 -3 + NTP_4_2_7P322 + + ntpq/ntpq.1ntpqman@1.139 +2 -2 + NTP_4_2_7P322 + + ntpq/ntpq.1ntpqmdoc@1.139 +2 -2 + NTP_4_2_7P322 + + ntpq/ntpq.man.in@1.139 +2 -2 + NTP_4_2_7P322 + + ntpq/ntpq.mdoc.in@1.139 +2 -2 + NTP_4_2_7P322 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.310 +2 -2 + NTP_4_2_7P322 + + ntpsnmpd/ntpsnmpd-opts.c@1.325 +4 -4 + NTP_4_2_7P322 + + ntpsnmpd/ntpsnmpd-opts.h@1.325 +3 -3 + NTP_4_2_7P322 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.139 +2 -2 + NTP_4_2_7P322 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.139 +2 -2 + NTP_4_2_7P322 + + ntpsnmpd/ntpsnmpd.man.in@1.139 +2 -2 + NTP_4_2_7P322 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.139 +2 -2 + NTP_4_2_7P322 + + packageinfo.sh@1.325 +1 -1 + NTP_4_2_7P322 + + scripts/invoke-ntp-wait.texi@1.128 +1 -111 + NTP_4_2_7P322 + + scripts/ntp-wait.1ntp-waitman@1.139 +2 -2 + NTP_4_2_7P322 + + scripts/ntp-wait.1ntp-waitmdoc@1.139 +2 -2 + NTP_4_2_7P322 + + scripts/ntp-wait.html@1.143 +4 -152 + NTP_4_2_7P322 + + scripts/ntp-wait.man.in@1.139 +2 -2 + NTP_4_2_7P322 + + scripts/ntp-wait.mdoc.in@1.139 +2 -2 + NTP_4_2_7P322 + + sntp/invoke-sntp.texi@1.307 +2 -2 + NTP_4_2_7P322 + + sntp/sntp-opts.c@1.322 +4 -4 + NTP_4_2_7P322 + + sntp/sntp-opts.h@1.322 +3 -3 + NTP_4_2_7P322 + + sntp/sntp.1sntpman@1.142 +2 -2 + NTP_4_2_7P322 + + sntp/sntp.1sntpmdoc@1.142 +2 -2 + NTP_4_2_7P322 + + sntp/sntp.html@1.322 +2 -2 + NTP_4_2_7P322 + + sntp/sntp.man.in@1.142 +2 -2 + NTP_4_2_7P322 + + sntp/sntp.mdoc.in@1.142 +2 -2 + NTP_4_2_7P322 + + util/invoke-ntp-keygen.texi@1.311 +2 -2 + NTP_4_2_7P322 + + util/ntp-keygen-opts.c@1.325 +4 -4 + NTP_4_2_7P322 + + util/ntp-keygen-opts.h@1.325 +3 -3 + NTP_4_2_7P322 + + util/ntp-keygen.1ntp-keygenman@1.139 +2 -2 + NTP_4_2_7P322 + + util/ntp-keygen.1ntp-keygenmdoc@1.139 +2 -2 + NTP_4_2_7P322 + + util/ntp-keygen.man.in@1.139 +2 -2 + NTP_4_2_7P322 + + util/ntp-keygen.mdoc.in@1.139 +2 -2 + NTP_4_2_7P322 + +ChangeSet@1.2822.1.49, 2012-11-15 04:10:48-05:00, stenn@deacon.udel.edu + html/ updates from Dave Mills + + ChangeLog@1.1191.1.44 +1 -0 + html/ updates from Dave Mills + + html/stats.html@1.1 +70 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/stats.html + + html/stats.html@1.0 +0 -0 + +ChangeSet@1.2822.5.1, 2012-11-14 22:58:44-08:00, harlan@hms-mbp11.local + Documentation updates from Dave Mills. + + html/authentic.html@1.11 +2 -2 + Updates from Dave Mills + + html/cluster.html@1.8 +7 -7 + Updates from Dave Mills + + html/discipline.html@1.8 +14 -6 + Updates from Dave Mills + + html/drivers/driver18.html@1.17.1.1 +3 -3 + Updates from Dave Mills + + html/drivers/driver20.html@1.26 +1 -1 + Updates from Dave Mills + + html/drivers/driver36.html@1.34 +6 -6 + Updates from Dave Mills + + html/drivers/driver6.html@1.28 +3 -3 + Updates from Dave Mills + + html/drivers/driver7.html@1.29 +2 -2 + Updates from Dave Mills + + html/filter.html@1.6 +7 -5 + Updates from Dave Mills + + html/huffpuff.html@1.4 +3 -3 + Updates from Dave Mills + + html/kern.html@1.20 +1 -1 + Updates from Dave Mills + + html/leap.html@1.1.1.1 +2 -2 + Updates from Dave Mills + + html/poll.html@1.3 +10 -8 + Updates from Dave Mills + + html/pps.html@1.24 +1 -1 + Updates from Dave Mills + + html/prefer.html@1.31 +30 -29 + Updates from Dave Mills + + html/quick.html@1.23 +3 -3 + Updates from Dave Mills + + html/rate.html@1.11 +8 -8 + Updates from Dave Mills + + html/refclock.html@1.37 +1 -0 + Updates from Dave Mills + + html/scripts/external.txt@1.6 +1 -0 + Updates from Dave Mills + + html/scripts/special.txt@1.7 +1 -1 + Updates from Dave Mills + + html/select.html@1.8 +8 -8 + Updates from Dave Mills + + html/warp.html@1.22 +27 -39 + Updates from Dave Mills + + html/xleave.html@1.8 +3 -4 + Updates from Dave Mills + +ChangeSet@1.2822.1.47, 2012-11-14 05:53:00-05:00, stenn@psp-deb1.ntp.org + [Bug 2123] cleanup to html/leap.html + + ChangeLog@1.1191.1.43 +1 -0 + [Bug 2123] cleanup to html/leap.html + + html/leap.html@1.2 +5 -5 + [Bug 2123] cleanup to html/leap.html + +ChangeSet@1.2822.1.46, 2012-11-14 05:07:30-05:00, stenn@deacon.udel.edu + for the setrlimit() stuff, use INSIST(), not ASSERT() + + ntpd/ntp_config.c@1.307 +1 -1 + for the setrlimit() stuff, use INSIST(), not ASSERT() + +ChangeSet@1.2822.1.45, 2012-11-14 01:35:24-08:00, harlan@hms-mbp11.local + [Bug 2120] no sysexits.h under QNX + + ChangeLog@1.1191.1.42 +1 -0 + [Bug 2120] no sysexits.h under QNX + + sntp/configure.ac@1.72 +1 -0 + [Bug 2120] no sysexits.h under QNX + + sntp/m4/ntp_sysexits.m4@1.1 +11 -0 + BitKeeper file /Users/harlan/src/ntp-dev/sntp/m4/ntp_sysexits.m4 + + sntp/m4/ntp_sysexits.m4@1.0 +0 -0 + +ChangeSet@1.2822.1.44, 2012-11-14 02:38:45-05:00, stenn@psp-deb1.ntp.org + Cleanup for bug 1223 - rlimit() updates + + include/ntp_config.h@1.78 +1 -1 + Cleanup for bug 1223 - rlimit() updates + + ntpd/ntp_config.c@1.306 +38 -18 + Cleanup for bug 1223 - rlimit() updates + +ChangeSet@1.2822.1.43, 2012-11-13 19:27:23-05:00, stenn@psp-deb1.ntp.org + Bug 1223 cleanup + + include/ntp_config.h@1.77 +1 -3 + Bug 1223 cleanup + + ntpd/complete.conf@1.23 +1 -0 + Bug 1223 cleanup + + ntpd/ntp_config.c@1.305 +68 -66 + Bug 1223 cleanup + + ntpd/ntpd.c@1.138 +3 -3 + Bug 1223 cleanup + +ChangeSet@1.2822.4.5, 2012-11-13 18:50:25-05:00, stenn@deacon.udel.edu + More cleanup of fix for Bug 1320 + + ntpd/ntpd.c@1.134.1.3 +8 -4 + More cleanup of fix for Bug 1320 + +ChangeSet@1.2822.4.4, 2012-11-13 17:49:10-05:00, stenn@deacon.udel.edu + [Bug 1320] Log ntpd's initial command-line parameters - updated fix + + ChangeLog@1.1191.4.4 +1 -0 + [Bug 1320] Log ntpd's initial command-line parameters - updated fix + + ntpd/ntpd.c@1.134.1.2 +1 -1 + [Bug 1320] Log ntpd's initial command-line parameters - updated fix + +ChangeSet@1.2822.4.3, 2012-11-13 11:33:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P321 + TAG: NTP_4_2_7P321 + + ChangeLog@1.1191.4.3 +1 -0 + NTP_4_2_7P321 + + ntpd/invoke-ntpd.texi@1.310 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.conf.5man@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.conf.5mdoc@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.conf.man.in@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.conf.mdoc.in@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.keys.5man@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.keys.5mdoc@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.keys.man.in@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntp.keys.mdoc.in@1.27 +2 -2 + NTP_4_2_7P321 + + ntpd/ntpd-opts.c@1.328 +4 -4 + NTP_4_2_7P321 + + ntpd/ntpd-opts.h@1.328 +3 -3 + NTP_4_2_7P321 + + ntpd/ntpd.1ntpdman@1.139 +2 -2 + NTP_4_2_7P321 + + ntpd/ntpd.1ntpdmdoc@1.139 +2 -2 + NTP_4_2_7P321 + + ntpd/ntpd.man.in@1.139 +2 -2 + NTP_4_2_7P321 + + ntpd/ntpd.mdoc.in@1.139 +2 -2 + NTP_4_2_7P321 + + ntpdc/invoke-ntpdc.texi@1.307 +2 -2 + NTP_4_2_7P321 + + ntpdc/ntpdc-opts.c@1.322 +4 -4 + NTP_4_2_7P321 + + ntpdc/ntpdc-opts.h@1.322 +3 -3 + NTP_4_2_7P321 + + ntpdc/ntpdc.1ntpdcman@1.138 +2 -2 + NTP_4_2_7P321 + + ntpdc/ntpdc.1ntpdcmdoc@1.138 +2 -2 + NTP_4_2_7P321 + + ntpdc/ntpdc.html@1.150 +2 -2 + NTP_4_2_7P321 + + ntpdc/ntpdc.man.in@1.138 +2 -2 + NTP_4_2_7P321 + + ntpdc/ntpdc.mdoc.in@1.138 +2 -2 + NTP_4_2_7P321 + + ntpq/invoke-ntpq.texi@1.309 +2 -2 + NTP_4_2_7P321 + + ntpq/ntpq-opts.c@1.324 +4 -4 + NTP_4_2_7P321 + + ntpq/ntpq-opts.h@1.324 +3 -3 + NTP_4_2_7P321 + + ntpq/ntpq.1ntpqman@1.138 +2 -2 + NTP_4_2_7P321 + + ntpq/ntpq.1ntpqmdoc@1.138 +2 -2 + NTP_4_2_7P321 + + ntpq/ntpq.man.in@1.138 +2 -2 + NTP_4_2_7P321 + + ntpq/ntpq.mdoc.in@1.138 +2 -2 + NTP_4_2_7P321 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.309 +2 -2 + NTP_4_2_7P321 + + ntpsnmpd/ntpsnmpd-opts.c@1.324 +4 -4 + NTP_4_2_7P321 + + ntpsnmpd/ntpsnmpd-opts.h@1.324 +3 -3 + NTP_4_2_7P321 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.138 +2 -2 + NTP_4_2_7P321 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.138 +2 -2 + NTP_4_2_7P321 + + ntpsnmpd/ntpsnmpd.man.in@1.138 +2 -2 + NTP_4_2_7P321 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.138 +2 -2 + NTP_4_2_7P321 + + packageinfo.sh@1.324 +1 -1 + NTP_4_2_7P321 + + scripts/invoke-ntp-wait.texi@1.127 +1 -1 + NTP_4_2_7P321 + + scripts/ntp-wait.1ntp-waitman@1.138 +2 -2 + NTP_4_2_7P321 + + scripts/ntp-wait.1ntp-waitmdoc@1.138 +2 -2 + NTP_4_2_7P321 + + scripts/ntp-wait.html@1.142 +1 -1 + NTP_4_2_7P321 + + scripts/ntp-wait.man.in@1.138 +2 -2 + NTP_4_2_7P321 + + scripts/ntp-wait.mdoc.in@1.138 +2 -2 + NTP_4_2_7P321 + + sntp/invoke-sntp.texi@1.306 +2 -2 + NTP_4_2_7P321 + + sntp/sntp-opts.c@1.321 +4 -4 + NTP_4_2_7P321 + + sntp/sntp-opts.h@1.321 +3 -3 + NTP_4_2_7P321 + + sntp/sntp.1sntpman@1.141 +2 -2 + NTP_4_2_7P321 + + sntp/sntp.1sntpmdoc@1.141 +2 -2 + NTP_4_2_7P321 + + sntp/sntp.html@1.321 +2 -2 + NTP_4_2_7P321 + + sntp/sntp.man.in@1.141 +2 -2 + NTP_4_2_7P321 + + sntp/sntp.mdoc.in@1.141 +2 -2 + NTP_4_2_7P321 + + util/invoke-ntp-keygen.texi@1.310 +2 -2 + NTP_4_2_7P321 + + util/ntp-keygen-opts.c@1.324 +4 -4 + NTP_4_2_7P321 + + util/ntp-keygen-opts.h@1.324 +3 -3 + NTP_4_2_7P321 + + util/ntp-keygen.1ntp-keygenman@1.138 +2 -2 + NTP_4_2_7P321 + + util/ntp-keygen.1ntp-keygenmdoc@1.138 +2 -2 + NTP_4_2_7P321 + + util/ntp-keygen.man.in@1.138 +2 -2 + NTP_4_2_7P321 + + util/ntp-keygen.mdoc.in@1.138 +2 -2 + NTP_4_2_7P321 + +ChangeSet@1.2822.4.2, 2012-11-13 03:59:29-05:00, stenn@psp-deb1.ntp.org + Fix typo: [Bug 1320] Log ntpd's initial command-line parameters + + ChangeLog@1.1191.4.2 +1 -1 + Fix typo: [Bug 1320] Log ntpd's initial command-line parameters + +ChangeSet@1.2822.4.1, 2012-11-13 03:57:34-05:00, stenn@psp-deb1.ntp.org + [Bug 1320] Log ntpd's initial command-line paprameters + + ChangeLog@1.1191.4.1 +1 -0 + [Bug 1320] Log ntpd's initial command-line paprameters + + ntpd/ntpd.c@1.134.1.1 +18 -0 + [Bug 1320] Log ntpd's initial command-line paprameters + +ChangeSet@1.2822.1.40, 2012-11-12 22:56:50-05:00, stenn@psp-deb1.ntp.org + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ChangeLog@1.1191.1.39 +2 -0 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + configure.ac@1.552 +54 -0 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + html/miscopt.html@1.70 +10 -0 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + include/ntp_config.h@1.76 +6 -0 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/keyword-gen-utd@1.19 +1 -1 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/keyword-gen.c@1.24 +4 -0 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/ntp_config.c@1.304 +124 -15 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/ntp_keyword.h@1.21 +584 -566 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/ntp_parser.c@1.82 +1181 -1138 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/ntp_parser.h@1.48 +201 -194 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/ntp_parser.y@1.76 +48 -1 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + + ntpd/ntpd.c@1.135 +2 -18 + [Bug 1223] Allow configurable values for RLIMIT_STACK and RLIMIT_MEMLOCK + +ChangeSet@1.2822.1.39, 2012-11-12 11:34:28+00:00, stenn@deacon.udel.edu + NTP_4_2_7P320 + TAG: NTP_4_2_7P320 + + ChangeLog@1.1191.1.38 +1 -0 + NTP_4_2_7P320 + + ntpd/invoke-ntpd.texi@1.309 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.conf.5man@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.conf.5mdoc@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.conf.man.in@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.conf.mdoc.in@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.keys.5man@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.keys.5mdoc@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.keys.man.in@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntp.keys.mdoc.in@1.26 +2 -2 + NTP_4_2_7P320 + + ntpd/ntpd-opts.c@1.327 +4 -4 + NTP_4_2_7P320 + + ntpd/ntpd-opts.h@1.327 +3 -3 + NTP_4_2_7P320 + + ntpd/ntpd.1ntpdman@1.138 +2 -2 + NTP_4_2_7P320 + + ntpd/ntpd.1ntpdmdoc@1.138 +2 -2 + NTP_4_2_7P320 + + ntpd/ntpd.man.in@1.138 +2 -2 + NTP_4_2_7P320 + + ntpd/ntpd.mdoc.in@1.138 +2 -2 + NTP_4_2_7P320 + + ntpdc/invoke-ntpdc.texi@1.306 +2 -2 + NTP_4_2_7P320 + + ntpdc/ntpdc-opts.c@1.321 +4 -4 + NTP_4_2_7P320 + + ntpdc/ntpdc-opts.h@1.321 +3 -3 + NTP_4_2_7P320 + + ntpdc/ntpdc.1ntpdcman@1.137 +2 -2 + NTP_4_2_7P320 + + ntpdc/ntpdc.1ntpdcmdoc@1.137 +2 -2 + NTP_4_2_7P320 + + ntpdc/ntpdc.html@1.149 +2 -2 + NTP_4_2_7P320 + + ntpdc/ntpdc.man.in@1.137 +2 -2 + NTP_4_2_7P320 + + ntpdc/ntpdc.mdoc.in@1.137 +2 -2 + NTP_4_2_7P320 + + ntpq/invoke-ntpq.texi@1.308 +2 -2 + NTP_4_2_7P320 + + ntpq/ntpq-opts.c@1.323 +4 -4 + NTP_4_2_7P320 + + ntpq/ntpq-opts.h@1.323 +3 -3 + NTP_4_2_7P320 + + ntpq/ntpq.1ntpqman@1.137 +2 -2 + NTP_4_2_7P320 + + ntpq/ntpq.1ntpqmdoc@1.137 +2 -2 + NTP_4_2_7P320 + + ntpq/ntpq.man.in@1.137 +2 -2 + NTP_4_2_7P320 + + ntpq/ntpq.mdoc.in@1.137 +2 -2 + NTP_4_2_7P320 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.308 +2 -2 + NTP_4_2_7P320 + + ntpsnmpd/ntpsnmpd-opts.c@1.323 +4 -4 + NTP_4_2_7P320 + + ntpsnmpd/ntpsnmpd-opts.h@1.323 +3 -3 + NTP_4_2_7P320 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.137 +2 -2 + NTP_4_2_7P320 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.137 +2 -2 + NTP_4_2_7P320 + + ntpsnmpd/ntpsnmpd.man.in@1.137 +2 -2 + NTP_4_2_7P320 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.137 +2 -2 + NTP_4_2_7P320 + + packageinfo.sh@1.323 +1 -1 + NTP_4_2_7P320 + + scripts/invoke-ntp-wait.texi@1.126 +1 -1 + NTP_4_2_7P320 + + scripts/ntp-wait.1ntp-waitman@1.137 +2 -2 + NTP_4_2_7P320 + + scripts/ntp-wait.1ntp-waitmdoc@1.137 +2 -2 + NTP_4_2_7P320 + + scripts/ntp-wait.html@1.141 +1 -1 + NTP_4_2_7P320 + + scripts/ntp-wait.man.in@1.137 +2 -2 + NTP_4_2_7P320 + + scripts/ntp-wait.mdoc.in@1.137 +2 -2 + NTP_4_2_7P320 + + sntp/invoke-sntp.texi@1.305 +2 -2 + NTP_4_2_7P320 + + sntp/sntp-opts.c@1.320 +4 -4 + NTP_4_2_7P320 + + sntp/sntp-opts.h@1.320 +3 -3 + NTP_4_2_7P320 + + sntp/sntp.1sntpman@1.140 +2 -2 + NTP_4_2_7P320 + + sntp/sntp.1sntpmdoc@1.140 +2 -2 + NTP_4_2_7P320 + + sntp/sntp.html@1.320 +2 -2 + NTP_4_2_7P320 + + sntp/sntp.man.in@1.140 +2 -2 + NTP_4_2_7P320 + + sntp/sntp.mdoc.in@1.140 +2 -2 + NTP_4_2_7P320 + + util/invoke-ntp-keygen.texi@1.309 +2 -2 + NTP_4_2_7P320 + + util/ntp-keygen-opts.c@1.323 +4 -4 + NTP_4_2_7P320 + + util/ntp-keygen-opts.h@1.323 +3 -3 + NTP_4_2_7P320 + + util/ntp-keygen.1ntp-keygenman@1.137 +2 -2 + NTP_4_2_7P320 + + util/ntp-keygen.1ntp-keygenmdoc@1.137 +2 -2 + NTP_4_2_7P320 + + util/ntp-keygen.man.in@1.137 +2 -2 + NTP_4_2_7P320 + + util/ntp-keygen.mdoc.in@1.137 +2 -2 + NTP_4_2_7P320 + +ChangeSet@1.2822.1.38, 2012-11-12 00:58:20-05:00, stenn@deacon.udel.edu + [Bug 1217] libisc/ifiter_sysctl.c:internal_current(): Ignore RTM messages with wrong version + + ChangeLog@1.1191.1.37 +2 -0 + [Bug 1217] libisc/ifiter_sysctl.c:internal_current(): Ignore RTM messages with wrong version + + lib/isc/unix/ifiter_sysctl.c@1.18 +4 -0 + [Bug 1217] libisc/ifiter_sysctl.c:internal_current(): Ignore RTM messages with wrong version + +ChangeSet@1.2822.1.37, 2012-11-11 20:09:21-05:00, stenn@psp-deb1.ntp.org + [Bug 969] Clarify ntpdate.html documentation about -u and ntpd + + ChangeLog@1.1191.1.36 +1 -0 + [Bug 969] Clarify ntpdate.html documentation about -u and ntpd + + html/ntpdate.html@1.22 +1 -1 + [Bug 969] Clarify ntpdate.html documentation about -u and ntpd + +ChangeSet@1.2822.1.36, 2012-11-11 11:38:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P319 + TAG: NTP_4_2_7P319 + + ChangeLog@1.1191.1.35 +1 -0 + NTP_4_2_7P319 + + ntpd/invoke-ntpd.texi@1.308 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.conf.5man@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.conf.5mdoc@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.conf.man.in@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.conf.mdoc.in@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.keys.5man@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.keys.5mdoc@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.keys.man.in@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntp.keys.mdoc.in@1.25 +2 -2 + NTP_4_2_7P319 + + ntpd/ntpd-opts.c@1.326 +4 -4 + NTP_4_2_7P319 + + ntpd/ntpd-opts.h@1.326 +3 -3 + NTP_4_2_7P319 + + ntpd/ntpd.1ntpdman@1.137 +2 -2 + NTP_4_2_7P319 + + ntpd/ntpd.1ntpdmdoc@1.137 +2 -2 + NTP_4_2_7P319 + + ntpd/ntpd.man.in@1.137 +2 -2 + NTP_4_2_7P319 + + ntpd/ntpd.mdoc.in@1.137 +2 -2 + NTP_4_2_7P319 + + ntpdc/invoke-ntpdc.texi@1.305 +2 -2 + NTP_4_2_7P319 + + ntpdc/ntpdc-opts.c@1.320 +4 -4 + NTP_4_2_7P319 + + ntpdc/ntpdc-opts.h@1.320 +3 -3 + NTP_4_2_7P319 + + ntpdc/ntpdc.1ntpdcman@1.136 +2 -2 + NTP_4_2_7P319 + + ntpdc/ntpdc.1ntpdcmdoc@1.136 +2 -2 + NTP_4_2_7P319 + + ntpdc/ntpdc.html@1.148 +2 -2 + NTP_4_2_7P319 + + ntpdc/ntpdc.man.in@1.136 +2 -2 + NTP_4_2_7P319 + + ntpdc/ntpdc.mdoc.in@1.136 +2 -2 + NTP_4_2_7P319 + + ntpq/invoke-ntpq.texi@1.307 +2 -2 + NTP_4_2_7P319 + + ntpq/ntpq-opts.c@1.322 +4 -4 + NTP_4_2_7P319 + + ntpq/ntpq-opts.h@1.322 +3 -3 + NTP_4_2_7P319 + + ntpq/ntpq.1ntpqman@1.136 +2 -2 + NTP_4_2_7P319 + + ntpq/ntpq.1ntpqmdoc@1.136 +2 -2 + NTP_4_2_7P319 + + ntpq/ntpq.man.in@1.136 +2 -2 + NTP_4_2_7P319 + + ntpq/ntpq.mdoc.in@1.136 +2 -2 + NTP_4_2_7P319 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.307 +2 -2 + NTP_4_2_7P319 + + ntpsnmpd/ntpsnmpd-opts.c@1.322 +4 -4 + NTP_4_2_7P319 + + ntpsnmpd/ntpsnmpd-opts.h@1.322 +3 -3 + NTP_4_2_7P319 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.136 +2 -2 + NTP_4_2_7P319 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.136 +2 -2 + NTP_4_2_7P319 + + ntpsnmpd/ntpsnmpd.man.in@1.136 +2 -2 + NTP_4_2_7P319 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.136 +2 -2 + NTP_4_2_7P319 + + packageinfo.sh@1.322 +1 -1 + NTP_4_2_7P319 + + scripts/invoke-ntp-wait.texi@1.125 +1 -1 + NTP_4_2_7P319 + + scripts/ntp-wait.1ntp-waitman@1.136 +2 -2 + NTP_4_2_7P319 + + scripts/ntp-wait.1ntp-waitmdoc@1.136 +2 -2 + NTP_4_2_7P319 + + scripts/ntp-wait.html@1.140 +1 -1 + NTP_4_2_7P319 + + scripts/ntp-wait.man.in@1.136 +2 -2 + NTP_4_2_7P319 + + scripts/ntp-wait.mdoc.in@1.136 +2 -2 + NTP_4_2_7P319 + + sntp/invoke-sntp.texi@1.304 +2 -2 + NTP_4_2_7P319 + + sntp/sntp-opts.c@1.319 +4 -4 + NTP_4_2_7P319 + + sntp/sntp-opts.h@1.319 +3 -3 + NTP_4_2_7P319 + + sntp/sntp.1sntpman@1.139 +2 -2 + NTP_4_2_7P319 + + sntp/sntp.1sntpmdoc@1.139 +2 -2 + NTP_4_2_7P319 + + sntp/sntp.html@1.319 +2 -2 + NTP_4_2_7P319 + + sntp/sntp.man.in@1.139 +2 -2 + NTP_4_2_7P319 + + sntp/sntp.mdoc.in@1.139 +2 -2 + NTP_4_2_7P319 + + util/invoke-ntp-keygen.texi@1.308 +2 -2 + NTP_4_2_7P319 + + util/ntp-keygen-opts.c@1.322 +4 -4 + NTP_4_2_7P319 + + util/ntp-keygen-opts.h@1.322 +3 -3 + NTP_4_2_7P319 + + util/ntp-keygen.1ntp-keygenman@1.136 +2 -2 + NTP_4_2_7P319 + + util/ntp-keygen.1ntp-keygenmdoc@1.136 +2 -2 + NTP_4_2_7P319 + + util/ntp-keygen.man.in@1.136 +2 -2 + NTP_4_2_7P319 + + util/ntp-keygen.mdoc.in@1.136 +2 -2 + NTP_4_2_7P319 + +ChangeSet@1.2822.1.35, 2012-11-11 03:49:15-05:00, stenn@deacon.udel.edu + [Bug 2296] Fix compile problem with building with old OpenSSL + + ChangeLog@1.1191.1.34 +1 -0 + [Bug 2296] Fix compile problem with building with old OpenSSL + + libntp/a_md5encrypt.c@1.34 +14 -0 + [Bug 2296] Fix compile problem with building with old OpenSSL + +ChangeSet@1.2822.1.34, 2012-11-05 11:28:16+00:00, stenn@deacon.udel.edu + NTP_4_2_7P318 + TAG: NTP_4_2_7P318 + + ChangeLog@1.1191.1.33 +1 -0 + NTP_4_2_7P318 + + ntpd/invoke-ntpd.texi@1.307 +2 -2 + NTP_4_2_7P318 + + ntpd/ntp.conf.5man@1.24 +2 -2 + NTP_4_2_7P318 + + ntpd/ntp.conf.5mdoc@1.24 +1 -1 + NTP_4_2_7P318 + + ntpd/ntp.conf.man.in@1.24 +2 -2 + NTP_4_2_7P318 + + ntpd/ntp.conf.mdoc.in@1.24 +1 -1 + NTP_4_2_7P318 + + ntpd/ntp.keys.5man@1.24 +2 -2 + NTP_4_2_7P318 + + ntpd/ntp.keys.5mdoc@1.24 +1 -1 + NTP_4_2_7P318 + + ntpd/ntp.keys.man.in@1.24 +2 -2 + NTP_4_2_7P318 + + ntpd/ntp.keys.mdoc.in@1.24 +1 -1 + NTP_4_2_7P318 + + ntpd/ntpd-opts.c@1.325 +4 -4 + NTP_4_2_7P318 + + ntpd/ntpd-opts.h@1.325 +3 -3 + NTP_4_2_7P318 + + ntpd/ntpd.1ntpdman@1.136 +2 -2 + NTP_4_2_7P318 + + ntpd/ntpd.1ntpdmdoc@1.136 +1 -1 + NTP_4_2_7P318 + + ntpd/ntpd.man.in@1.136 +2 -2 + NTP_4_2_7P318 + + ntpd/ntpd.mdoc.in@1.136 +1 -1 + NTP_4_2_7P318 + + ntpdc/invoke-ntpdc.texi@1.304 +2 -2 + NTP_4_2_7P318 + + ntpdc/ntpdc-opts.c@1.319 +4 -4 + NTP_4_2_7P318 + + ntpdc/ntpdc-opts.h@1.319 +3 -3 + NTP_4_2_7P318 + + ntpdc/ntpdc.1ntpdcman@1.135 +2 -2 + NTP_4_2_7P318 + + ntpdc/ntpdc.1ntpdcmdoc@1.135 +1 -1 + NTP_4_2_7P318 + + ntpdc/ntpdc.html@1.147 +2 -2 + NTP_4_2_7P318 + + ntpdc/ntpdc.man.in@1.135 +2 -2 + NTP_4_2_7P318 + + ntpdc/ntpdc.mdoc.in@1.135 +1 -1 + NTP_4_2_7P318 + + ntpq/invoke-ntpq.texi@1.306 +2 -2 + NTP_4_2_7P318 + + ntpq/ntpq-opts.c@1.321 +4 -4 + NTP_4_2_7P318 + + ntpq/ntpq-opts.h@1.321 +3 -3 + NTP_4_2_7P318 + + ntpq/ntpq.1ntpqman@1.135 +2 -2 + NTP_4_2_7P318 + + ntpq/ntpq.1ntpqmdoc@1.135 +1 -1 + NTP_4_2_7P318 + + ntpq/ntpq.man.in@1.135 +2 -2 + NTP_4_2_7P318 + + ntpq/ntpq.mdoc.in@1.135 +1 -1 + NTP_4_2_7P318 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.306 +2 -2 + NTP_4_2_7P318 + + ntpsnmpd/ntpsnmpd-opts.c@1.321 +4 -4 + NTP_4_2_7P318 + + ntpsnmpd/ntpsnmpd-opts.h@1.321 +3 -3 + NTP_4_2_7P318 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.135 +2 -2 + NTP_4_2_7P318 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.135 +1 -1 + NTP_4_2_7P318 + + ntpsnmpd/ntpsnmpd.man.in@1.135 +2 -2 + NTP_4_2_7P318 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.135 +1 -1 + NTP_4_2_7P318 + + packageinfo.sh@1.321 +1 -1 + NTP_4_2_7P318 + + scripts/invoke-ntp-wait.texi@1.124 +1 -1 + NTP_4_2_7P318 + + scripts/ntp-wait.1ntp-waitman@1.135 +2 -2 + NTP_4_2_7P318 + + scripts/ntp-wait.1ntp-waitmdoc@1.135 +1 -1 + NTP_4_2_7P318 + + scripts/ntp-wait.html@1.139 +1 -1 + NTP_4_2_7P318 + + scripts/ntp-wait.man.in@1.135 +2 -2 + NTP_4_2_7P318 + + scripts/ntp-wait.mdoc.in@1.135 +1 -1 + NTP_4_2_7P318 + + sntp/invoke-sntp.texi@1.303 +2 -2 + NTP_4_2_7P318 + + sntp/sntp-opts.c@1.318 +4 -4 + NTP_4_2_7P318 + + sntp/sntp-opts.h@1.318 +3 -3 + NTP_4_2_7P318 + + sntp/sntp.1sntpman@1.138 +2 -2 + NTP_4_2_7P318 + + sntp/sntp.1sntpmdoc@1.138 +1 -1 + NTP_4_2_7P318 + + sntp/sntp.html@1.318 +2 -2 + NTP_4_2_7P318 + + sntp/sntp.man.in@1.138 +2 -2 + NTP_4_2_7P318 + + sntp/sntp.mdoc.in@1.138 +1 -1 + NTP_4_2_7P318 + + util/invoke-ntp-keygen.texi@1.307 +2 -2 + NTP_4_2_7P318 + + util/ntp-keygen-opts.c@1.321 +4 -4 + NTP_4_2_7P318 + + util/ntp-keygen-opts.h@1.321 +3 -3 + NTP_4_2_7P318 + + util/ntp-keygen.1ntp-keygenman@1.135 +2 -2 + NTP_4_2_7P318 + + util/ntp-keygen.1ntp-keygenmdoc@1.135 +1 -1 + NTP_4_2_7P318 + + util/ntp-keygen.man.in@1.135 +2 -2 + NTP_4_2_7P318 + + util/ntp-keygen.mdoc.in@1.135 +1 -1 + NTP_4_2_7P318 + +ChangeSet@1.2822.1.33, 2012-11-05 02:09:35-05:00, stenn@deacon.udel.edu + [Bug 2301] Remove spurious debug output from ntpq + + ChangeLog@1.1191.1.32 +1 -0 + [Bug 2301] Remove spurious debug output from ntpq + + ntpq/ntpq.c@1.151 +0 -1 + [Bug 2301] Remove spurious debug output from ntpq + +ChangeSet@1.2822.1.32, 2012-11-05 06:02:04+00:00, stenn@deacon.udel.edu + NTP_4_2_7P317 + TAG: NTP_4_2_7P317 + + ChangeLog@1.1191.1.31 +1 -0 + NTP_4_2_7P317 + + ntpd/invoke-ntpd.texi@1.306 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.conf.5man@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.conf.5mdoc@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.conf.man.in@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.conf.mdoc.in@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.keys.5man@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.keys.5mdoc@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.keys.man.in@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntp.keys.mdoc.in@1.23 +2 -2 + NTP_4_2_7P317 + + ntpd/ntpd-opts.c@1.324 +4 -4 + NTP_4_2_7P317 + + ntpd/ntpd-opts.h@1.324 +3 -3 + NTP_4_2_7P317 + + ntpd/ntpd.1ntpdman@1.135 +2 -2 + NTP_4_2_7P317 + + ntpd/ntpd.1ntpdmdoc@1.135 +2 -2 + NTP_4_2_7P317 + + ntpd/ntpd.man.in@1.135 +2 -2 + NTP_4_2_7P317 + + ntpd/ntpd.mdoc.in@1.135 +2 -2 + NTP_4_2_7P317 + + ntpdc/invoke-ntpdc.texi@1.303 +2 -2 + NTP_4_2_7P317 + + ntpdc/ntpdc-opts.c@1.318 +4 -4 + NTP_4_2_7P317 + + ntpdc/ntpdc-opts.h@1.318 +3 -3 + NTP_4_2_7P317 + + ntpdc/ntpdc.1ntpdcman@1.134 +2 -2 + NTP_4_2_7P317 + + ntpdc/ntpdc.1ntpdcmdoc@1.134 +2 -2 + NTP_4_2_7P317 + + ntpdc/ntpdc.html@1.146 +2 -2 + NTP_4_2_7P317 + + ntpdc/ntpdc.man.in@1.134 +2 -2 + NTP_4_2_7P317 + + ntpdc/ntpdc.mdoc.in@1.134 +2 -2 + NTP_4_2_7P317 + + ntpq/invoke-ntpq.texi@1.305 +2 -2 + NTP_4_2_7P317 + + ntpq/ntpq-opts.c@1.320 +4 -4 + NTP_4_2_7P317 + + ntpq/ntpq-opts.h@1.320 +3 -3 + NTP_4_2_7P317 + + ntpq/ntpq.1ntpqman@1.134 +2 -2 + NTP_4_2_7P317 + + ntpq/ntpq.1ntpqmdoc@1.134 +2 -2 + NTP_4_2_7P317 + + ntpq/ntpq.man.in@1.134 +2 -2 + NTP_4_2_7P317 + + ntpq/ntpq.mdoc.in@1.134 +2 -2 + NTP_4_2_7P317 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.305 +2 -2 + NTP_4_2_7P317 + + ntpsnmpd/ntpsnmpd-opts.c@1.320 +4 -4 + NTP_4_2_7P317 + + ntpsnmpd/ntpsnmpd-opts.h@1.320 +3 -3 + NTP_4_2_7P317 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.134 +2 -2 + NTP_4_2_7P317 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.134 +2 -2 + NTP_4_2_7P317 + + ntpsnmpd/ntpsnmpd.man.in@1.134 +2 -2 + NTP_4_2_7P317 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.134 +2 -2 + NTP_4_2_7P317 + + packageinfo.sh@1.320 +1 -1 + NTP_4_2_7P317 + + scripts/invoke-ntp-wait.texi@1.123 +14 -2 + NTP_4_2_7P317 + + scripts/ntp-wait.1ntp-waitman@1.134 +2 -2 + NTP_4_2_7P317 + + scripts/ntp-wait.1ntp-waitmdoc@1.134 +2 -2 + NTP_4_2_7P317 + + scripts/ntp-wait.html@1.138 +14 -2 + NTP_4_2_7P317 + + scripts/ntp-wait.man.in@1.134 +2 -2 + NTP_4_2_7P317 + + scripts/ntp-wait.mdoc.in@1.134 +2 -2 + NTP_4_2_7P317 + + sntp/invoke-sntp.texi@1.302 +2 -2 + NTP_4_2_7P317 + + sntp/sntp-opts.c@1.317 +4 -4 + NTP_4_2_7P317 + + sntp/sntp-opts.h@1.317 +3 -3 + NTP_4_2_7P317 + + sntp/sntp.1sntpman@1.137 +2 -2 + NTP_4_2_7P317 + + sntp/sntp.1sntpmdoc@1.137 +2 -2 + NTP_4_2_7P317 + + sntp/sntp.html@1.317 +2 -2 + NTP_4_2_7P317 + + sntp/sntp.man.in@1.137 +2 -2 + NTP_4_2_7P317 + + sntp/sntp.mdoc.in@1.137 +2 -2 + NTP_4_2_7P317 + + util/invoke-ntp-keygen.texi@1.306 +2 -2 + NTP_4_2_7P317 + + util/ntp-keygen-opts.c@1.320 +4 -4 + NTP_4_2_7P317 + + util/ntp-keygen-opts.h@1.320 +3 -3 + NTP_4_2_7P317 + + util/ntp-keygen.1ntp-keygenman@1.134 +2 -2 + NTP_4_2_7P317 + + util/ntp-keygen.1ntp-keygenmdoc@1.134 +2 -2 + NTP_4_2_7P317 + + util/ntp-keygen.man.in@1.134 +2 -2 + NTP_4_2_7P317 + + util/ntp-keygen.mdoc.in@1.134 +2 -2 + NTP_4_2_7P317 + +ChangeSet@1.2822.1.31, 2012-11-05 02:34:01+00:00, stenn@psp-fb1.ntp.org + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + + ChangeLog@1.1191.1.30 +1 -0 + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + + ntpq/libntpq.c@1.12 +7 -2 + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + + ntpq/libntpq.h@1.9 +1 -1 + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + + ntpq/ntpq-subs.c@1.98 +2 -3 + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + + ntpq/ntpq.c@1.150 +54 -14 + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + + ntpq/ntpq.h@1.28 +8 -0 + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + + ntpsnmpd/ntpsnmpd.c@1.8 +1 -1 + [Bug 922] Allow interspersed -4 and -6 flags on the ntpq command line + +ChangeSet@1.2822.1.30, 2012-10-27 11:26:16+00:00, stenn@deacon.udel.edu + NTP_4_2_7P316 + TAG: NTP_4_2_7P316 + + ChangeLog@1.1191.1.29 +1 -0 + NTP_4_2_7P316 + + ntpd/invoke-ntpd.texi@1.305 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.conf.5man@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.conf.5mdoc@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.conf.man.in@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.conf.mdoc.in@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.keys.5man@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.keys.5mdoc@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.keys.man.in@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntp.keys.mdoc.in@1.22 +2 -2 + NTP_4_2_7P316 + + ntpd/ntpd-opts.c@1.323 +4 -4 + NTP_4_2_7P316 + + ntpd/ntpd-opts.h@1.323 +3 -3 + NTP_4_2_7P316 + + ntpd/ntpd.1ntpdman@1.134 +2 -2 + NTP_4_2_7P316 + + ntpd/ntpd.1ntpdmdoc@1.134 +2 -2 + NTP_4_2_7P316 + + ntpd/ntpd.man.in@1.134 +2 -2 + NTP_4_2_7P316 + + ntpd/ntpd.mdoc.in@1.134 +2 -2 + NTP_4_2_7P316 + + ntpdc/invoke-ntpdc.texi@1.302 +2 -2 + NTP_4_2_7P316 + + ntpdc/ntpdc-opts.c@1.317 +4 -4 + NTP_4_2_7P316 + + ntpdc/ntpdc-opts.h@1.317 +3 -3 + NTP_4_2_7P316 + + ntpdc/ntpdc.1ntpdcman@1.133 +2 -2 + NTP_4_2_7P316 + + ntpdc/ntpdc.1ntpdcmdoc@1.133 +2 -2 + NTP_4_2_7P316 + + ntpdc/ntpdc.html@1.145 +2 -2 + NTP_4_2_7P316 + + ntpdc/ntpdc.man.in@1.133 +2 -2 + NTP_4_2_7P316 + + ntpdc/ntpdc.mdoc.in@1.133 +2 -2 + NTP_4_2_7P316 + + ntpq/invoke-ntpq.texi@1.304 +2 -2 + NTP_4_2_7P316 + + ntpq/ntpq-opts.c@1.319 +4 -4 + NTP_4_2_7P316 + + ntpq/ntpq-opts.h@1.319 +3 -3 + NTP_4_2_7P316 + + ntpq/ntpq.1ntpqman@1.133 +2 -2 + NTP_4_2_7P316 + + ntpq/ntpq.1ntpqmdoc@1.133 +2 -2 + NTP_4_2_7P316 + + ntpq/ntpq.man.in@1.133 +2 -2 + NTP_4_2_7P316 + + ntpq/ntpq.mdoc.in@1.133 +2 -2 + NTP_4_2_7P316 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.304 +2 -2 + NTP_4_2_7P316 + + ntpsnmpd/ntpsnmpd-opts.c@1.319 +4 -4 + NTP_4_2_7P316 + + ntpsnmpd/ntpsnmpd-opts.h@1.319 +3 -3 + NTP_4_2_7P316 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.133 +2 -2 + NTP_4_2_7P316 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.133 +2 -2 + NTP_4_2_7P316 + + ntpsnmpd/ntpsnmpd.man.in@1.133 +2 -2 + NTP_4_2_7P316 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.133 +2 -2 + NTP_4_2_7P316 + + packageinfo.sh@1.319 +1 -1 + NTP_4_2_7P316 + + scripts/invoke-ntp-wait.texi@1.122 +1 -1 + NTP_4_2_7P316 + + scripts/ntp-wait.1ntp-waitman@1.133 +2 -2 + NTP_4_2_7P316 + + scripts/ntp-wait.1ntp-waitmdoc@1.133 +2 -2 + NTP_4_2_7P316 + + scripts/ntp-wait.html@1.137 +1 -1 + NTP_4_2_7P316 + + scripts/ntp-wait.man.in@1.133 +2 -2 + NTP_4_2_7P316 + + scripts/ntp-wait.mdoc.in@1.133 +2 -2 + NTP_4_2_7P316 + + sntp/invoke-sntp.texi@1.301 +2 -2 + NTP_4_2_7P316 + + sntp/sntp-opts.c@1.316 +4 -4 + NTP_4_2_7P316 + + sntp/sntp-opts.h@1.316 +3 -3 + NTP_4_2_7P316 + + sntp/sntp.1sntpman@1.136 +2 -2 + NTP_4_2_7P316 + + sntp/sntp.1sntpmdoc@1.136 +2 -2 + NTP_4_2_7P316 + + sntp/sntp.html@1.316 +2 -2 + NTP_4_2_7P316 + + sntp/sntp.man.in@1.136 +2 -2 + NTP_4_2_7P316 + + sntp/sntp.mdoc.in@1.136 +2 -2 + NTP_4_2_7P316 + + util/invoke-ntp-keygen.texi@1.305 +2 -2 + NTP_4_2_7P316 + + util/ntp-keygen-opts.c@1.319 +4 -4 + NTP_4_2_7P316 + + util/ntp-keygen-opts.h@1.319 +3 -3 + NTP_4_2_7P316 + + util/ntp-keygen.1ntp-keygenman@1.133 +2 -2 + NTP_4_2_7P316 + + util/ntp-keygen.1ntp-keygenmdoc@1.133 +2 -2 + NTP_4_2_7P316 + + util/ntp-keygen.man.in@1.133 +2 -2 + NTP_4_2_7P316 + + util/ntp-keygen.mdoc.in@1.133 +2 -2 + NTP_4_2_7P316 + +ChangeSet@1.2822.1.29, 2012-10-26 13:37:56-04:00, stenn@deacon.udel.edu + [Bug 2296] Update fix for Bug 2294 to handle --without-crypto + + ChangeLog@1.1191.1.28 +1 -0 + [Bug 2296] Update fix for Bug 2294 to handle --without-crypto + + include/ntp_md5.h@1.9 +5 -1 + [Bug 2296] Update fix for Bug 2294 to handle --without-crypto + +ChangeSet@1.2822.1.28, 2012-10-26 07:13:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P315 + TAG: NTP_4_2_7P315 + + ChangeLog@1.1191.1.27 +1 -0 + NTP_4_2_7P315 + + ntpd/invoke-ntpd.texi@1.304 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.conf.5man@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.conf.5mdoc@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.conf.man.in@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.conf.mdoc.in@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.keys.5man@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.keys.5mdoc@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.keys.man.in@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntp.keys.mdoc.in@1.21 +2 -2 + NTP_4_2_7P315 + + ntpd/ntpd-opts.c@1.322 +4 -4 + NTP_4_2_7P315 + + ntpd/ntpd-opts.h@1.322 +3 -3 + NTP_4_2_7P315 + + ntpd/ntpd.1ntpdman@1.133 +2 -2 + NTP_4_2_7P315 + + ntpd/ntpd.1ntpdmdoc@1.133 +2 -2 + NTP_4_2_7P315 + + ntpd/ntpd.man.in@1.133 +2 -2 + NTP_4_2_7P315 + + ntpd/ntpd.mdoc.in@1.133 +2 -2 + NTP_4_2_7P315 + + ntpdc/invoke-ntpdc.texi@1.301 +2 -2 + NTP_4_2_7P315 + + ntpdc/ntpdc-opts.c@1.316 +4 -4 + NTP_4_2_7P315 + + ntpdc/ntpdc-opts.h@1.316 +3 -3 + NTP_4_2_7P315 + + ntpdc/ntpdc.1ntpdcman@1.132 +2 -2 + NTP_4_2_7P315 + + ntpdc/ntpdc.1ntpdcmdoc@1.132 +2 -2 + NTP_4_2_7P315 + + ntpdc/ntpdc.html@1.144 +2 -2 + NTP_4_2_7P315 + + ntpdc/ntpdc.man.in@1.132 +2 -2 + NTP_4_2_7P315 + + ntpdc/ntpdc.mdoc.in@1.132 +2 -2 + NTP_4_2_7P315 + + ntpq/invoke-ntpq.texi@1.303 +2 -2 + NTP_4_2_7P315 + + ntpq/ntpq-opts.c@1.318 +4 -4 + NTP_4_2_7P315 + + ntpq/ntpq-opts.h@1.318 +3 -3 + NTP_4_2_7P315 + + ntpq/ntpq.1ntpqman@1.132 +2 -2 + NTP_4_2_7P315 + + ntpq/ntpq.1ntpqmdoc@1.132 +2 -2 + NTP_4_2_7P315 + + ntpq/ntpq.man.in@1.132 +2 -2 + NTP_4_2_7P315 + + ntpq/ntpq.mdoc.in@1.132 +2 -2 + NTP_4_2_7P315 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.303 +2 -2 + NTP_4_2_7P315 + + ntpsnmpd/ntpsnmpd-opts.c@1.318 +4 -4 + NTP_4_2_7P315 + + ntpsnmpd/ntpsnmpd-opts.h@1.318 +3 -3 + NTP_4_2_7P315 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.132 +2 -2 + NTP_4_2_7P315 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.132 +2 -2 + NTP_4_2_7P315 + + ntpsnmpd/ntpsnmpd.man.in@1.132 +2 -2 + NTP_4_2_7P315 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.132 +2 -2 + NTP_4_2_7P315 + + packageinfo.sh@1.318 +1 -1 + NTP_4_2_7P315 + + scripts/invoke-ntp-wait.texi@1.121 +1 -1 + NTP_4_2_7P315 + + scripts/ntp-wait.1ntp-waitman@1.132 +2 -2 + NTP_4_2_7P315 + + scripts/ntp-wait.1ntp-waitmdoc@1.132 +2 -2 + NTP_4_2_7P315 + + scripts/ntp-wait.html@1.136 +1 -1 + NTP_4_2_7P315 + + scripts/ntp-wait.man.in@1.132 +2 -2 + NTP_4_2_7P315 + + scripts/ntp-wait.mdoc.in@1.132 +2 -2 + NTP_4_2_7P315 + + sntp/invoke-sntp.texi@1.300 +2 -2 + NTP_4_2_7P315 + + sntp/sntp-opts.c@1.315 +4 -4 + NTP_4_2_7P315 + + sntp/sntp-opts.h@1.315 +3 -3 + NTP_4_2_7P315 + + sntp/sntp.1sntpman@1.135 +2 -2 + NTP_4_2_7P315 + + sntp/sntp.1sntpmdoc@1.135 +2 -2 + NTP_4_2_7P315 + + sntp/sntp.html@1.315 +2 -2 + NTP_4_2_7P315 + + sntp/sntp.man.in@1.135 +2 -2 + NTP_4_2_7P315 + + sntp/sntp.mdoc.in@1.135 +2 -2 + NTP_4_2_7P315 + + util/invoke-ntp-keygen.texi@1.304 +2 -2 + NTP_4_2_7P315 + + util/ntp-keygen-opts.c@1.318 +4 -4 + NTP_4_2_7P315 + + util/ntp-keygen-opts.h@1.318 +3 -3 + NTP_4_2_7P315 + + util/ntp-keygen.1ntp-keygenman@1.132 +2 -2 + NTP_4_2_7P315 + + util/ntp-keygen.1ntp-keygenmdoc@1.132 +2 -2 + NTP_4_2_7P315 + + util/ntp-keygen.man.in@1.132 +2 -2 + NTP_4_2_7P315 + + util/ntp-keygen.mdoc.in@1.132 +2 -2 + NTP_4_2_7P315 + +ChangeSet@1.2822.1.27, 2012-10-26 02:23:16-04:00, stenn@psp-deb1.ntp.org + [Bug 2294] ntpd crashes in FIPS mode + + ChangeLog@1.1191.1.26 +1 -0 + [Bug 2294] ntpd crashes in FIPS mode + + libntp/a_md5encrypt.c@1.33 +20 -3 + [Bug 2294] ntpd crashes in FIPS mode + +ChangeSet@1.2822.1.26, 2012-10-23 11:32:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P314 + TAG: NTP_4_2_7P314 + + ChangeLog@1.1191.1.25 +1 -0 + NTP_4_2_7P314 + + ntpd/invoke-ntpd.texi@1.303 +2 -2 + NTP_4_2_7P314 + + ntpd/ntp.conf.5man@1.20 +2 -2 + NTP_4_2_7P314 + + ntpd/ntp.conf.5mdoc@1.20 +1 -1 + NTP_4_2_7P314 + + ntpd/ntp.conf.man.in@1.20 +2 -2 + NTP_4_2_7P314 + + ntpd/ntp.conf.mdoc.in@1.20 +1 -1 + NTP_4_2_7P314 + + ntpd/ntp.keys.5man@1.20 +2 -2 + NTP_4_2_7P314 + + ntpd/ntp.keys.5mdoc@1.20 +1 -1 + NTP_4_2_7P314 + + ntpd/ntp.keys.man.in@1.20 +2 -2 + NTP_4_2_7P314 + + ntpd/ntp.keys.mdoc.in@1.20 +1 -1 + NTP_4_2_7P314 + + ntpd/ntpd-opts.c@1.321 +4 -4 + NTP_4_2_7P314 + + ntpd/ntpd-opts.h@1.321 +3 -3 + NTP_4_2_7P314 + + ntpd/ntpd.1ntpdman@1.132 +2 -2 + NTP_4_2_7P314 + + ntpd/ntpd.1ntpdmdoc@1.132 +1 -1 + NTP_4_2_7P314 + + ntpd/ntpd.man.in@1.132 +2 -2 + NTP_4_2_7P314 + + ntpd/ntpd.mdoc.in@1.132 +1 -1 + NTP_4_2_7P314 + + ntpdc/invoke-ntpdc.texi@1.300 +2 -2 + NTP_4_2_7P314 + + ntpdc/ntpdc-opts.c@1.315 +4 -4 + NTP_4_2_7P314 + + ntpdc/ntpdc-opts.h@1.315 +3 -3 + NTP_4_2_7P314 + + ntpdc/ntpdc.1ntpdcman@1.131 +2 -2 + NTP_4_2_7P314 + + ntpdc/ntpdc.1ntpdcmdoc@1.131 +1 -1 + NTP_4_2_7P314 + + ntpdc/ntpdc.html@1.143 +2 -2 + NTP_4_2_7P314 + + ntpdc/ntpdc.man.in@1.131 +2 -2 + NTP_4_2_7P314 + + ntpdc/ntpdc.mdoc.in@1.131 +1 -1 + NTP_4_2_7P314 + + ntpq/invoke-ntpq.texi@1.302 +2 -2 + NTP_4_2_7P314 + + ntpq/ntpq-opts.c@1.317 +4 -4 + NTP_4_2_7P314 + + ntpq/ntpq-opts.h@1.317 +3 -3 + NTP_4_2_7P314 + + ntpq/ntpq.1ntpqman@1.131 +2 -2 + NTP_4_2_7P314 + + ntpq/ntpq.1ntpqmdoc@1.131 +1 -1 + NTP_4_2_7P314 + + ntpq/ntpq.man.in@1.131 +2 -2 + NTP_4_2_7P314 + + ntpq/ntpq.mdoc.in@1.131 +1 -1 + NTP_4_2_7P314 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.302 +2 -2 + NTP_4_2_7P314 + + ntpsnmpd/ntpsnmpd-opts.c@1.317 +4 -4 + NTP_4_2_7P314 + + ntpsnmpd/ntpsnmpd-opts.h@1.317 +3 -3 + NTP_4_2_7P314 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.131 +2 -2 + NTP_4_2_7P314 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.131 +1 -1 + NTP_4_2_7P314 + + ntpsnmpd/ntpsnmpd.man.in@1.131 +2 -2 + NTP_4_2_7P314 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.131 +1 -1 + NTP_4_2_7P314 + + packageinfo.sh@1.317 +1 -1 + NTP_4_2_7P314 + + scripts/invoke-ntp-wait.texi@1.120 +1 -1 + NTP_4_2_7P314 + + scripts/ntp-wait.1ntp-waitman@1.131 +2 -2 + NTP_4_2_7P314 + + scripts/ntp-wait.1ntp-waitmdoc@1.131 +1 -1 + NTP_4_2_7P314 + + scripts/ntp-wait.html@1.135 +1 -1 + NTP_4_2_7P314 + + scripts/ntp-wait.man.in@1.131 +2 -2 + NTP_4_2_7P314 + + scripts/ntp-wait.mdoc.in@1.131 +1 -1 + NTP_4_2_7P314 + + sntp/invoke-sntp.texi@1.299 +2 -2 + NTP_4_2_7P314 + + sntp/sntp-opts.c@1.314 +4 -4 + NTP_4_2_7P314 + + sntp/sntp-opts.h@1.314 +3 -3 + NTP_4_2_7P314 + + sntp/sntp.1sntpman@1.134 +2 -2 + NTP_4_2_7P314 + + sntp/sntp.1sntpmdoc@1.134 +1 -1 + NTP_4_2_7P314 + + sntp/sntp.html@1.314 +2 -2 + NTP_4_2_7P314 + + sntp/sntp.man.in@1.134 +2 -2 + NTP_4_2_7P314 + + sntp/sntp.mdoc.in@1.134 +1 -1 + NTP_4_2_7P314 + + util/invoke-ntp-keygen.texi@1.303 +2 -2 + NTP_4_2_7P314 + + util/ntp-keygen-opts.c@1.317 +4 -4 + NTP_4_2_7P314 + + util/ntp-keygen-opts.h@1.317 +3 -3 + NTP_4_2_7P314 + + util/ntp-keygen.1ntp-keygenman@1.131 +2 -2 + NTP_4_2_7P314 + + util/ntp-keygen.1ntp-keygenmdoc@1.131 +1 -1 + NTP_4_2_7P314 + + util/ntp-keygen.man.in@1.131 +2 -2 + NTP_4_2_7P314 + + util/ntp-keygen.mdoc.in@1.131 +1 -1 + NTP_4_2_7P314 + +ChangeSet@1.2822.1.25, 2012-10-23 08:43:55+00:00, stenn@psp-fb1.ntp.org + Document a tricky malloc() of dns_ctx in sntp + + ChangeLog@1.1191.1.24 +1 -0 + Document a tricky malloc() of dns_ctx in sntp + + sntp/main.c@1.86 +5 -5 + Document a tricky malloc() of dns_ctx in sntp + +ChangeSet@1.2822.1.24, 2012-10-23 06:09:15+00:00, stenn@deacon.udel.edu + NTP_4_2_7P313 + TAG: NTP_4_2_7P313 + + ChangeLog@1.1191.1.23 +1 -0 + NTP_4_2_7P313 + + ntpd/invoke-ntpd.texi@1.302 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.conf.5man@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.conf.5mdoc@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.conf.man.in@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.conf.mdoc.in@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.keys.5man@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.keys.5mdoc@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.keys.man.in@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntp.keys.mdoc.in@1.19 +2 -2 + NTP_4_2_7P313 + + ntpd/ntpd-opts.c@1.320 +4 -4 + NTP_4_2_7P313 + + ntpd/ntpd-opts.h@1.320 +3 -3 + NTP_4_2_7P313 + + ntpd/ntpd.1ntpdman@1.131 +2 -2 + NTP_4_2_7P313 + + ntpd/ntpd.1ntpdmdoc@1.131 +2 -2 + NTP_4_2_7P313 + + ntpd/ntpd.man.in@1.131 +2 -2 + NTP_4_2_7P313 + + ntpd/ntpd.mdoc.in@1.131 +2 -2 + NTP_4_2_7P313 + + ntpdc/invoke-ntpdc.texi@1.299 +2 -2 + NTP_4_2_7P313 + + ntpdc/ntpdc-opts.c@1.314 +4 -4 + NTP_4_2_7P313 + + ntpdc/ntpdc-opts.h@1.314 +3 -3 + NTP_4_2_7P313 + + ntpdc/ntpdc.1ntpdcman@1.130 +2 -2 + NTP_4_2_7P313 + + ntpdc/ntpdc.1ntpdcmdoc@1.130 +2 -2 + NTP_4_2_7P313 + + ntpdc/ntpdc.html@1.142 +2 -2 + NTP_4_2_7P313 + + ntpdc/ntpdc.man.in@1.130 +2 -2 + NTP_4_2_7P313 + + ntpdc/ntpdc.mdoc.in@1.130 +2 -2 + NTP_4_2_7P313 + + ntpq/invoke-ntpq.texi@1.301 +2 -2 + NTP_4_2_7P313 + + ntpq/ntpq-opts.c@1.316 +4 -4 + NTP_4_2_7P313 + + ntpq/ntpq-opts.h@1.316 +3 -3 + NTP_4_2_7P313 + + ntpq/ntpq.1ntpqman@1.130 +2 -2 + NTP_4_2_7P313 + + ntpq/ntpq.1ntpqmdoc@1.130 +2 -2 + NTP_4_2_7P313 + + ntpq/ntpq.man.in@1.130 +2 -2 + NTP_4_2_7P313 + + ntpq/ntpq.mdoc.in@1.130 +2 -2 + NTP_4_2_7P313 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.301 +2 -2 + NTP_4_2_7P313 + + ntpsnmpd/ntpsnmpd-opts.c@1.316 +4 -4 + NTP_4_2_7P313 + + ntpsnmpd/ntpsnmpd-opts.h@1.316 +3 -3 + NTP_4_2_7P313 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.130 +2 -2 + NTP_4_2_7P313 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.130 +2 -2 + NTP_4_2_7P313 + + ntpsnmpd/ntpsnmpd.man.in@1.130 +2 -2 + NTP_4_2_7P313 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.130 +2 -2 + NTP_4_2_7P313 + + packageinfo.sh@1.316 +1 -1 + NTP_4_2_7P313 + + scripts/invoke-ntp-wait.texi@1.119 +2 -14 + NTP_4_2_7P313 + + scripts/ntp-wait.1ntp-waitman@1.130 +2 -2 + NTP_4_2_7P313 + + scripts/ntp-wait.1ntp-waitmdoc@1.130 +2 -2 + NTP_4_2_7P313 + + scripts/ntp-wait.html@1.134 +2 -14 + NTP_4_2_7P313 + + scripts/ntp-wait.man.in@1.130 +2 -2 + NTP_4_2_7P313 + + scripts/ntp-wait.mdoc.in@1.130 +2 -2 + NTP_4_2_7P313 + + sntp/invoke-sntp.texi@1.298 +2 -2 + NTP_4_2_7P313 + + sntp/sntp-opts.c@1.313 +4 -4 + NTP_4_2_7P313 + + sntp/sntp-opts.h@1.313 +3 -3 + NTP_4_2_7P313 + + sntp/sntp.1sntpman@1.133 +2 -2 + NTP_4_2_7P313 + + sntp/sntp.1sntpmdoc@1.133 +2 -2 + NTP_4_2_7P313 + + sntp/sntp.html@1.313 +2 -2 + NTP_4_2_7P313 + + sntp/sntp.man.in@1.133 +2 -2 + NTP_4_2_7P313 + + sntp/sntp.mdoc.in@1.133 +2 -2 + NTP_4_2_7P313 + + util/invoke-ntp-keygen.texi@1.302 +2 -2 + NTP_4_2_7P313 + + util/ntp-keygen-opts.c@1.316 +4 -4 + NTP_4_2_7P313 + + util/ntp-keygen-opts.h@1.316 +3 -3 + NTP_4_2_7P313 + + util/ntp-keygen.1ntp-keygenman@1.130 +2 -2 + NTP_4_2_7P313 + + util/ntp-keygen.1ntp-keygenmdoc@1.130 +2 -2 + NTP_4_2_7P313 + + util/ntp-keygen.man.in@1.130 +2 -2 + NTP_4_2_7P313 + + util/ntp-keygen.mdoc.in@1.130 +2 -2 + NTP_4_2_7P313 + +ChangeSet@1.2822.1.23, 2012-10-23 02:16:06+00:00, stenn@psp-fb1.ntp.org + [Bug 2293] add support for SO_BINTIME, refine support for SO_TIMESTAMPNS (bug 1374) + + ChangeLog@1.1191.1.22 +2 -0 + [Bug 2293] add support for SO_BINTIME, refine support for SO_TIMESTAMPNS (bug 1374) + + ntpd/ntp_io.c@1.373 +89 -45 + [Bug 2293] add support for SO_BINTIME, refine support for SO_TIMESTAMPNS (bug 1374) + +ChangeSet@1.2822.1.22, 2012-10-18 16:31:00-04:00, stenn@psp-deb1.ntp.org + [Bug 2291] sntp should report why it cannot open file.kod + + ChangeLog@1.1191.1.21 +1 -0 + [Bug 2291] sntp should report why it cannot open file.kod + + sntp/kod_management.c@1.29 +1 -1 + [Bug 2291] sntp should report why it cannot open file.kod + +ChangeSet@1.2822.1.21, 2012-10-11 07:12:51+00:00, stenn@deacon.udel.edu + NTP_4_2_7P312 + TAG: NTP_4_2_7P312 + + ChangeLog@1.1191.1.20 +1 -0 + NTP_4_2_7P312 + + ntpd/invoke-ntpd.texi@1.301 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.conf.5man@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.conf.5mdoc@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.conf.man.in@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.conf.mdoc.in@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.keys.5man@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.keys.5mdoc@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.keys.man.in@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntp.keys.mdoc.in@1.18 +2 -2 + NTP_4_2_7P312 + + ntpd/ntpd-opts.c@1.319 +4 -4 + NTP_4_2_7P312 + + ntpd/ntpd-opts.h@1.319 +3 -3 + NTP_4_2_7P312 + + ntpd/ntpd.1ntpdman@1.130 +2 -2 + NTP_4_2_7P312 + + ntpd/ntpd.1ntpdmdoc@1.130 +2 -2 + NTP_4_2_7P312 + + ntpd/ntpd.man.in@1.130 +2 -2 + NTP_4_2_7P312 + + ntpd/ntpd.mdoc.in@1.130 +2 -2 + NTP_4_2_7P312 + + ntpdc/invoke-ntpdc.texi@1.298 +2 -2 + NTP_4_2_7P312 + + ntpdc/ntpdc-opts.c@1.313 +4 -4 + NTP_4_2_7P312 + + ntpdc/ntpdc-opts.h@1.313 +3 -3 + NTP_4_2_7P312 + + ntpdc/ntpdc.1ntpdcman@1.129 +2 -2 + NTP_4_2_7P312 + + ntpdc/ntpdc.1ntpdcmdoc@1.129 +2 -2 + NTP_4_2_7P312 + + ntpdc/ntpdc.html@1.141 +2 -2 + NTP_4_2_7P312 + + ntpdc/ntpdc.man.in@1.129 +2 -2 + NTP_4_2_7P312 + + ntpdc/ntpdc.mdoc.in@1.129 +2 -2 + NTP_4_2_7P312 + + ntpq/invoke-ntpq.texi@1.300 +2 -2 + NTP_4_2_7P312 + + ntpq/ntpq-opts.c@1.315 +4 -4 + NTP_4_2_7P312 + + ntpq/ntpq-opts.h@1.315 +3 -3 + NTP_4_2_7P312 + + ntpq/ntpq.1ntpqman@1.129 +2 -2 + NTP_4_2_7P312 + + ntpq/ntpq.1ntpqmdoc@1.129 +2 -2 + NTP_4_2_7P312 + + ntpq/ntpq.man.in@1.129 +2 -2 + NTP_4_2_7P312 + + ntpq/ntpq.mdoc.in@1.129 +2 -2 + NTP_4_2_7P312 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.300 +2 -2 + NTP_4_2_7P312 + + ntpsnmpd/ntpsnmpd-opts.c@1.315 +4 -4 + NTP_4_2_7P312 + + ntpsnmpd/ntpsnmpd-opts.h@1.315 +3 -3 + NTP_4_2_7P312 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.129 +2 -2 + NTP_4_2_7P312 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.129 +2 -2 + NTP_4_2_7P312 + + ntpsnmpd/ntpsnmpd.man.in@1.129 +2 -2 + NTP_4_2_7P312 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.129 +2 -2 + NTP_4_2_7P312 + + packageinfo.sh@1.315 +1 -1 + NTP_4_2_7P312 + + scripts/invoke-ntp-wait.texi@1.118 +1 -1 + NTP_4_2_7P312 + + scripts/ntp-wait.1ntp-waitman@1.129 +2 -2 + NTP_4_2_7P312 + + scripts/ntp-wait.1ntp-waitmdoc@1.129 +2 -2 + NTP_4_2_7P312 + + scripts/ntp-wait.html@1.133 +1 -1 + NTP_4_2_7P312 + + scripts/ntp-wait.man.in@1.129 +2 -2 + NTP_4_2_7P312 + + scripts/ntp-wait.mdoc.in@1.129 +2 -2 + NTP_4_2_7P312 + + sntp/invoke-sntp.texi@1.297 +2 -2 + NTP_4_2_7P312 + + sntp/sntp-opts.c@1.312 +4 -4 + NTP_4_2_7P312 + + sntp/sntp-opts.h@1.312 +3 -3 + NTP_4_2_7P312 + + sntp/sntp.1sntpman@1.132 +2 -2 + NTP_4_2_7P312 + + sntp/sntp.1sntpmdoc@1.132 +2 -2 + NTP_4_2_7P312 + + sntp/sntp.html@1.312 +2 -2 + NTP_4_2_7P312 + + sntp/sntp.man.in@1.132 +2 -2 + NTP_4_2_7P312 + + sntp/sntp.mdoc.in@1.132 +2 -2 + NTP_4_2_7P312 + + util/invoke-ntp-keygen.texi@1.301 +2 -2 + NTP_4_2_7P312 + + util/ntp-keygen-opts.c@1.315 +4 -4 + NTP_4_2_7P312 + + util/ntp-keygen-opts.h@1.315 +3 -3 + NTP_4_2_7P312 + + util/ntp-keygen.1ntp-keygenman@1.129 +2 -2 + NTP_4_2_7P312 + + util/ntp-keygen.1ntp-keygenmdoc@1.129 +2 -2 + NTP_4_2_7P312 + + util/ntp-keygen.man.in@1.129 +2 -2 + NTP_4_2_7P312 + + util/ntp-keygen.mdoc.in@1.129 +2 -2 + NTP_4_2_7P312 + +ChangeSet@1.2822.1.20, 2012-10-11 01:30:28-04:00, stenn@deacon.udel.edu + Remove debugging from testing the fix for [Bug 938] + + ChangeLog@1.1191.1.19 +1 -0 + Remove debugging from testing the fix for [Bug 938] + + sntp/main.c@1.85 +0 -5 + Remove debugging from testing the fix for [Bug 938] + +ChangeSet@1.2822.1.19, 2012-10-10 06:30:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P311 + TAG: NTP_4_2_7P311 + + ChangeLog@1.1191.1.18 +1 -0 + NTP_4_2_7P311 + + ntpd/invoke-ntpd.texi@1.300 +4 -40 + NTP_4_2_7P311 + + ntpd/ntp.conf.5man@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntp.conf.5mdoc@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntp.conf.man.in@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntp.conf.mdoc.in@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntp.keys.5man@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntp.keys.5mdoc@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntp.keys.man.in@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntp.keys.mdoc.in@1.17 +2 -2 + NTP_4_2_7P311 + + ntpd/ntpd-opts.c@1.318 +214 -231 + NTP_4_2_7P311 + + ntpd/ntpd-opts.h@1.318 +5 -3 + NTP_4_2_7P311 + + ntpd/ntpd.1ntpdman@1.129 +6 -8 + NTP_4_2_7P311 + + ntpd/ntpd.1ntpdmdoc@1.129 +8 -8 + NTP_4_2_7P311 + + ntpd/ntpd.man.in@1.129 +6 -8 + NTP_4_2_7P311 + + ntpd/ntpd.mdoc.in@1.129 +8 -8 + NTP_4_2_7P311 + + ntpdc/invoke-ntpdc.texi@1.297 +3 -3 + NTP_4_2_7P311 + + ntpdc/ntpdc-opts.c@1.312 +15 -14 + NTP_4_2_7P311 + + ntpdc/ntpdc-opts.h@1.312 +5 -3 + NTP_4_2_7P311 + + ntpdc/ntpdc.1ntpdcman@1.128 +4 -3 + NTP_4_2_7P311 + + ntpdc/ntpdc.1ntpdcmdoc@1.128 +4 -3 + NTP_4_2_7P311 + + ntpdc/ntpdc.html@1.140 +3 -3 + NTP_4_2_7P311 + + ntpdc/ntpdc.man.in@1.128 +4 -3 + NTP_4_2_7P311 + + ntpdc/ntpdc.mdoc.in@1.128 +4 -3 + NTP_4_2_7P311 + + ntpq/invoke-ntpq.texi@1.299 +3 -3 + NTP_4_2_7P311 + + ntpq/ntpq-opts.c@1.314 +15 -14 + NTP_4_2_7P311 + + ntpq/ntpq-opts.h@1.314 +5 -3 + NTP_4_2_7P311 + + ntpq/ntpq.1ntpqman@1.128 +4 -3 + NTP_4_2_7P311 + + ntpq/ntpq.1ntpqmdoc@1.128 +4 -3 + NTP_4_2_7P311 + + ntpq/ntpq.man.in@1.128 +4 -3 + NTP_4_2_7P311 + + ntpq/ntpq.mdoc.in@1.128 +4 -3 + NTP_4_2_7P311 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.299 +2 -2 + NTP_4_2_7P311 + + ntpsnmpd/ntpsnmpd-opts.c@1.314 +4 -4 + NTP_4_2_7P311 + + ntpsnmpd/ntpsnmpd-opts.h@1.314 +3 -3 + NTP_4_2_7P311 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.128 +2 -2 + NTP_4_2_7P311 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.128 +2 -2 + NTP_4_2_7P311 + + ntpsnmpd/ntpsnmpd.man.in@1.128 +2 -2 + NTP_4_2_7P311 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.128 +2 -2 + NTP_4_2_7P311 + + packageinfo.sh@1.314 +1 -1 + NTP_4_2_7P311 + + scripts/invoke-ntp-wait.texi@1.117 +1 -1 + NTP_4_2_7P311 + + scripts/ntp-wait.1ntp-waitman@1.128 +2 -2 + NTP_4_2_7P311 + + scripts/ntp-wait.1ntp-waitmdoc@1.128 +2 -2 + NTP_4_2_7P311 + + scripts/ntp-wait.html@1.132 +1 -1 + NTP_4_2_7P311 + + scripts/ntp-wait.man.in@1.128 +2 -2 + NTP_4_2_7P311 + + scripts/ntp-wait.mdoc.in@1.128 +2 -2 + NTP_4_2_7P311 + + sntp/invoke-sntp.texi@1.296 +3 -3 + NTP_4_2_7P311 + + sntp/sntp-opts.c@1.311 +16 -16 + NTP_4_2_7P311 + + sntp/sntp-opts.h@1.311 +5 -3 + NTP_4_2_7P311 + + sntp/sntp.1sntpman@1.131 +4 -3 + NTP_4_2_7P311 + + sntp/sntp.1sntpmdoc@1.131 +4 -3 + NTP_4_2_7P311 + + sntp/sntp.html@1.311 +3 -3 + NTP_4_2_7P311 + + sntp/sntp.man.in@1.131 +4 -3 + NTP_4_2_7P311 + + sntp/sntp.mdoc.in@1.131 +4 -3 + NTP_4_2_7P311 + + util/invoke-ntp-keygen.texi@1.300 +3 -3 + NTP_4_2_7P311 + + util/ntp-keygen-opts.c@1.314 +15 -14 + NTP_4_2_7P311 + + util/ntp-keygen-opts.h@1.314 +5 -3 + NTP_4_2_7P311 + + util/ntp-keygen.1ntp-keygenman@1.128 +4 -3 + NTP_4_2_7P311 + + util/ntp-keygen.1ntp-keygenmdoc@1.128 +4 -3 + NTP_4_2_7P311 + + util/ntp-keygen.man.in@1.128 +4 -3 + NTP_4_2_7P311 + + util/ntp-keygen.mdoc.in@1.128 +4 -3 + NTP_4_2_7P311 + +ChangeSet@1.2822.1.17, 2012-10-10 01:49:46-04:00, stenn@psp-deb1.ntp.org + [Bug 938] The argument to the -D flag takes a number, not a string + + ChangeLog@1.1191.1.16 +1 -0 + [Bug 938] The argument to the -D flag takes a number, not a string + +ChangeSet@1.2822.1.16, 2012-10-09 23:19:59-04:00, stenn@psp-deb1.ntp.org + [Bug 1374] Support SO_TIMESTAMPNS + + ChangeLog@1.1191.1.15 +1 -0 + [Bug 1374] Support SO_TIMESTAMPNS + + ntpd/ntpd.c@1.134 +2 -2 + [Bug 1374] Support SO_TIMESTAMPNS + + ntpd/ntpdbase-opts.def@1.24 +1 -27 + [Bug 1374] Support SO_TIMESTAMPNS + + ntpdc/ntpdc.c@1.101 +1 -1 + [Bug 1374] Support SO_TIMESTAMPNS + + ntpq/ntpq.c@1.149 +1 -1 + [Bug 1374] Support SO_TIMESTAMPNS + + ports/winnt/ntpd/ntservice.c@1.29 +1 -1 + [Bug 1374] Support SO_TIMESTAMPNS + + sntp/include/debug-opt.def@1.8 +2 -2 + [Bug 1374] Support SO_TIMESTAMPNS + + sntp/main.c@1.84 +6 -1 + [Bug 1374] Support SO_TIMESTAMPNS + + util/ntp-keygen.c@1.93 +1 -1 + [Bug 1374] Support SO_TIMESTAMPNS + +ChangeSet@1.2822.1.15, 2012-10-09 22:55:48-04:00, stenn@psp-deb1.ntp.org + [Bug 1374] Support SO_TIMESTAMPNS + + ntpd/ntp_io.c@1.372 +9 -8 + [Bug 1374] Support SO_TIMESTAMPNS + +ChangeSet@1.2822.3.1, 2012-10-09 11:41:30+00:00, stenn@deacon.udel.edu + NTP_4_2_7P310 + TAG: NTP_4_2_7P310 + + ChangeLog@1.1191.3.1 +1 -0 + NTP_4_2_7P310 + + ntpd/invoke-ntpd.texi@1.299 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.conf.5man@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.conf.5mdoc@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.conf.man.in@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.conf.mdoc.in@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.keys.5man@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.keys.5mdoc@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.keys.man.in@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntp.keys.mdoc.in@1.16 +2 -2 + NTP_4_2_7P310 + + ntpd/ntpd-opts.c@1.317 +4 -4 + NTP_4_2_7P310 + + ntpd/ntpd-opts.h@1.317 +3 -3 + NTP_4_2_7P310 + + ntpd/ntpd.1ntpdman@1.128 +2 -2 + NTP_4_2_7P310 + + ntpd/ntpd.1ntpdmdoc@1.128 +2 -2 + NTP_4_2_7P310 + + ntpd/ntpd.man.in@1.128 +2 -2 + NTP_4_2_7P310 + + ntpd/ntpd.mdoc.in@1.128 +2 -2 + NTP_4_2_7P310 + + ntpdc/invoke-ntpdc.texi@1.296 +2 -2 + NTP_4_2_7P310 + + ntpdc/ntpdc-opts.c@1.311 +4 -4 + NTP_4_2_7P310 + + ntpdc/ntpdc-opts.h@1.311 +3 -3 + NTP_4_2_7P310 + + ntpdc/ntpdc.1ntpdcman@1.127 +2 -2 + NTP_4_2_7P310 + + ntpdc/ntpdc.1ntpdcmdoc@1.127 +2 -2 + NTP_4_2_7P310 + + ntpdc/ntpdc.html@1.139 +2 -2 + NTP_4_2_7P310 + + ntpdc/ntpdc.man.in@1.127 +2 -2 + NTP_4_2_7P310 + + ntpdc/ntpdc.mdoc.in@1.127 +2 -2 + NTP_4_2_7P310 + + ntpq/invoke-ntpq.texi@1.298 +2 -2 + NTP_4_2_7P310 + + ntpq/ntpq-opts.c@1.313 +4 -4 + NTP_4_2_7P310 + + ntpq/ntpq-opts.h@1.313 +3 -3 + NTP_4_2_7P310 + + ntpq/ntpq.1ntpqman@1.127 +2 -2 + NTP_4_2_7P310 + + ntpq/ntpq.1ntpqmdoc@1.127 +2 -2 + NTP_4_2_7P310 + + ntpq/ntpq.man.in@1.127 +2 -2 + NTP_4_2_7P310 + + ntpq/ntpq.mdoc.in@1.127 +2 -2 + NTP_4_2_7P310 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.298 +2 -2 + NTP_4_2_7P310 + + ntpsnmpd/ntpsnmpd-opts.c@1.313 +4 -4 + NTP_4_2_7P310 + + ntpsnmpd/ntpsnmpd-opts.h@1.313 +3 -3 + NTP_4_2_7P310 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.127 +2 -2 + NTP_4_2_7P310 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.127 +2 -2 + NTP_4_2_7P310 + + ntpsnmpd/ntpsnmpd.man.in@1.127 +2 -2 + NTP_4_2_7P310 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.127 +2 -2 + NTP_4_2_7P310 + + packageinfo.sh@1.313 +1 -1 + NTP_4_2_7P310 + + scripts/invoke-ntp-wait.texi@1.116 +1 -1 + NTP_4_2_7P310 + + scripts/ntp-wait.1ntp-waitman@1.127 +2 -2 + NTP_4_2_7P310 + + scripts/ntp-wait.1ntp-waitmdoc@1.127 +2 -2 + NTP_4_2_7P310 + + scripts/ntp-wait.html@1.131 +1 -1 + NTP_4_2_7P310 + + scripts/ntp-wait.man.in@1.127 +2 -2 + NTP_4_2_7P310 + + scripts/ntp-wait.mdoc.in@1.127 +2 -2 + NTP_4_2_7P310 + + sntp/invoke-sntp.texi@1.295 +2 -2 + NTP_4_2_7P310 + + sntp/sntp-opts.c@1.310 +4 -4 + NTP_4_2_7P310 + + sntp/sntp-opts.h@1.310 +3 -3 + NTP_4_2_7P310 + + sntp/sntp.1sntpman@1.130 +2 -2 + NTP_4_2_7P310 + + sntp/sntp.1sntpmdoc@1.130 +2 -2 + NTP_4_2_7P310 + + sntp/sntp.html@1.310 +2 -2 + NTP_4_2_7P310 + + sntp/sntp.man.in@1.130 +2 -2 + NTP_4_2_7P310 + + sntp/sntp.mdoc.in@1.130 +2 -2 + NTP_4_2_7P310 + + util/invoke-ntp-keygen.texi@1.299 +2 -2 + NTP_4_2_7P310 + + util/ntp-keygen-opts.c@1.313 +4 -4 + NTP_4_2_7P310 + + util/ntp-keygen-opts.h@1.313 +3 -3 + NTP_4_2_7P310 + + util/ntp-keygen.1ntp-keygenman@1.127 +2 -2 + NTP_4_2_7P310 + + util/ntp-keygen.1ntp-keygenmdoc@1.127 +2 -2 + NTP_4_2_7P310 + + util/ntp-keygen.man.in@1.127 +2 -2 + NTP_4_2_7P310 + + util/ntp-keygen.mdoc.in@1.127 +2 -2 + NTP_4_2_7P310 + +ChangeSet@1.2822.1.14, 2012-10-09 02:15:38-04:00, stenn@psp-deb1.ntp.org + [Bug 1013] ntpdate's HTML page claims wrong default version. + + ChangeLog@1.1191.1.14 +1 -0 + [Bug 1013] ntpdate's HTML page claims wrong default version. + + html/ntpdate.html@1.21 +2 -1 + [Bug 1013] ntpdate's HTML page claims wrong default version. + +ChangeSet@1.2822.1.13, 2012-10-08 23:50:56-04:00, stenn@deacon.udel.edu + [Bug 1374] Support SO_TIMESTAMPNS + + ChangeLog@1.1191.1.13 +1 -0 + [Bug 1374] Support SO_TIMESTAMPNS + + ntpd/ntp_io.c@1.371 +68 -16 + [Bug 1374] Support SO_TIMESTAMPNS + +ChangeSet@1.2822.1.12, 2012-10-08 22:50:36-04:00, stenn@deacon.udel.edu + [Bug 2274] Bring libopts/enum.c back to (old) ANSI C compliance + + ChangeLog@1.1191.1.12 +1 -1 + [Bug 2274] Bring libopts/enum.c back to (old) ANSI C compliance + +ChangeSet@1.2822.1.11, 2012-10-08 20:17:15-04:00, stenn@deacon.udel.edu + [Bug 2266] Remove deprecated refclock_trak.c from Windows Makefile equivalents + + ChangeLog@1.1191.1.11 +2 -1 + [Bug 2266] Remove deprecated refclock_trak.c from Windows Makefile equivalents + +ChangeSet@1.2822.2.1, 2012-10-05 01:53:46+00:00, davehart@dlh-7551.ad.hartbrothers.com + Bring libopts/enum.c back to ANSI C compliance. + Reflect removal of refclock_trak.c in Windows Makefile equivalents. + + ChangeLog@1.1191.2.1 +2 -0 + Bring libopts/enum.c back to ANSI C compliance. + Reflect removal of refclock_trak.c in Windows Makefile equivalents. + + ports/winnt/vs2005/ntpd.vcproj@1.18 +0 -24 + Reflect removal of refclock_trak.c in Windows Makefile equivalents. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.44 +0 -4 + Reflect removal of refclock_trak.c in Windows Makefile equivalents. + + sntp/libopts/enum.c@1.5 +3 -3 + Bring libopts/enum.c back to ANSI C compliance. + + +ChangeSet@1.2822.1.9, 2012-10-04 11:41:02+00:00, stenn@deacon.udel.edu + NTP_4_2_7P309 + TAG: NTP_4_2_7P309 + + ChangeLog@1.1191.1.9 +1 -0 + NTP_4_2_7P309 + + ntpd/invoke-ntpd.texi@1.298 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.conf.5man@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.conf.5mdoc@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.conf.man.in@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.conf.mdoc.in@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.keys.5man@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.keys.5mdoc@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.keys.man.in@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntp.keys.mdoc.in@1.15 +2 -2 + NTP_4_2_7P309 + + ntpd/ntpd-opts.c@1.316 +4 -4 + NTP_4_2_7P309 + + ntpd/ntpd-opts.h@1.316 +3 -3 + NTP_4_2_7P309 + + ntpd/ntpd.1ntpdman@1.127 +2 -2 + NTP_4_2_7P309 + + ntpd/ntpd.1ntpdmdoc@1.127 +2 -2 + NTP_4_2_7P309 + + ntpd/ntpd.man.in@1.127 +2 -2 + NTP_4_2_7P309 + + ntpd/ntpd.mdoc.in@1.127 +2 -2 + NTP_4_2_7P309 + + ntpdc/invoke-ntpdc.texi@1.295 +2 -2 + NTP_4_2_7P309 + + ntpdc/ntpdc-opts.c@1.310 +4 -4 + NTP_4_2_7P309 + + ntpdc/ntpdc-opts.h@1.310 +3 -3 + NTP_4_2_7P309 + + ntpdc/ntpdc.1ntpdcman@1.126 +2 -2 + NTP_4_2_7P309 + + ntpdc/ntpdc.1ntpdcmdoc@1.126 +2 -2 + NTP_4_2_7P309 + + ntpdc/ntpdc.html@1.138 +2 -2 + NTP_4_2_7P309 + + ntpdc/ntpdc.man.in@1.126 +2 -2 + NTP_4_2_7P309 + + ntpdc/ntpdc.mdoc.in@1.126 +2 -2 + NTP_4_2_7P309 + + ntpq/invoke-ntpq.texi@1.297 +2 -2 + NTP_4_2_7P309 + + ntpq/ntpq-opts.c@1.312 +4 -4 + NTP_4_2_7P309 + + ntpq/ntpq-opts.h@1.312 +3 -3 + NTP_4_2_7P309 + + ntpq/ntpq.1ntpqman@1.126 +2 -2 + NTP_4_2_7P309 + + ntpq/ntpq.1ntpqmdoc@1.126 +2 -2 + NTP_4_2_7P309 + + ntpq/ntpq.man.in@1.126 +2 -2 + NTP_4_2_7P309 + + ntpq/ntpq.mdoc.in@1.126 +2 -2 + NTP_4_2_7P309 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.297 +2 -2 + NTP_4_2_7P309 + + ntpsnmpd/ntpsnmpd-opts.c@1.312 +4 -4 + NTP_4_2_7P309 + + ntpsnmpd/ntpsnmpd-opts.h@1.312 +3 -3 + NTP_4_2_7P309 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.126 +2 -2 + NTP_4_2_7P309 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.126 +2 -2 + NTP_4_2_7P309 + + ntpsnmpd/ntpsnmpd.man.in@1.126 +2 -2 + NTP_4_2_7P309 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.126 +2 -2 + NTP_4_2_7P309 + + packageinfo.sh@1.312 +1 -1 + NTP_4_2_7P309 + + scripts/invoke-ntp-wait.texi@1.115 +1 -1 + NTP_4_2_7P309 + + scripts/ntp-wait.1ntp-waitman@1.126 +2 -2 + NTP_4_2_7P309 + + scripts/ntp-wait.1ntp-waitmdoc@1.126 +2 -2 + NTP_4_2_7P309 + + scripts/ntp-wait.html@1.130 +1 -1 + NTP_4_2_7P309 + + scripts/ntp-wait.man.in@1.126 +2 -2 + NTP_4_2_7P309 + + scripts/ntp-wait.mdoc.in@1.126 +2 -2 + NTP_4_2_7P309 + + sntp/invoke-sntp.texi@1.294 +2 -2 + NTP_4_2_7P309 + + sntp/sntp-opts.c@1.309 +4 -4 + NTP_4_2_7P309 + + sntp/sntp-opts.h@1.309 +3 -3 + NTP_4_2_7P309 + + sntp/sntp.1sntpman@1.129 +2 -2 + NTP_4_2_7P309 + + sntp/sntp.1sntpmdoc@1.129 +2 -2 + NTP_4_2_7P309 + + sntp/sntp.html@1.309 +2 -2 + NTP_4_2_7P309 + + sntp/sntp.man.in@1.129 +2 -2 + NTP_4_2_7P309 + + sntp/sntp.mdoc.in@1.129 +2 -2 + NTP_4_2_7P309 + + util/invoke-ntp-keygen.texi@1.298 +2 -2 + NTP_4_2_7P309 + + util/ntp-keygen-opts.c@1.312 +4 -4 + NTP_4_2_7P309 + + util/ntp-keygen-opts.h@1.312 +3 -3 + NTP_4_2_7P309 + + util/ntp-keygen.1ntp-keygenman@1.126 +2 -2 + NTP_4_2_7P309 + + util/ntp-keygen.1ntp-keygenmdoc@1.126 +2 -2 + NTP_4_2_7P309 + + util/ntp-keygen.man.in@1.126 +2 -2 + NTP_4_2_7P309 + + util/ntp-keygen.mdoc.in@1.126 +2 -2 + NTP_4_2_7P309 + +ChangeSet@1.2822.1.8, 2012-10-04 03:37:21-04:00, stenn@deacon.udel.edu + [Bug 2287] ntpdate returns 0 even if adjtime() call fails + + ChangeLog@1.1191.1.8 +1 -0 + [Bug 2287] ntpdate returns 0 even if adjtime() call fails + + ntpdate/ntpdate.c@1.91 +1 -1 + [Bug 2287] ntpdate returns 0 even if adjtime() call fails + +ChangeSet@1.2822.1.7, 2012-09-29 10:48:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P308 + TAG: NTP_4_2_7P308 + + ChangeLog@1.1191.1.7 +1 -0 + NTP_4_2_7P308 + + ntpd/invoke-ntpd.texi@1.297 +2 -2 + NTP_4_2_7P308 + + ntpd/ntp.conf.5man@1.14 +2 -2 + NTP_4_2_7P308 + + ntpd/ntp.conf.5mdoc@1.14 +1 -1 + NTP_4_2_7P308 + + ntpd/ntp.conf.man.in@1.14 +2 -2 + NTP_4_2_7P308 + + ntpd/ntp.conf.mdoc.in@1.14 +1 -1 + NTP_4_2_7P308 + + ntpd/ntp.keys.5man@1.14 +2 -2 + NTP_4_2_7P308 + + ntpd/ntp.keys.5mdoc@1.14 +1 -1 + NTP_4_2_7P308 + + ntpd/ntp.keys.man.in@1.14 +2 -2 + NTP_4_2_7P308 + + ntpd/ntp.keys.mdoc.in@1.14 +1 -1 + NTP_4_2_7P308 + + ntpd/ntpd-opts.c@1.315 +4 -4 + NTP_4_2_7P308 + + ntpd/ntpd-opts.h@1.315 +3 -3 + NTP_4_2_7P308 + + ntpd/ntpd.1ntpdman@1.126 +2 -2 + NTP_4_2_7P308 + + ntpd/ntpd.1ntpdmdoc@1.126 +1 -1 + NTP_4_2_7P308 + + ntpd/ntpd.man.in@1.126 +2 -2 + NTP_4_2_7P308 + + ntpd/ntpd.mdoc.in@1.126 +1 -1 + NTP_4_2_7P308 + + ntpdc/invoke-ntpdc.texi@1.294 +2 -2 + NTP_4_2_7P308 + + ntpdc/ntpdc-opts.c@1.309 +4 -4 + NTP_4_2_7P308 + + ntpdc/ntpdc-opts.h@1.309 +3 -3 + NTP_4_2_7P308 + + ntpdc/ntpdc.1ntpdcman@1.125 +2 -2 + NTP_4_2_7P308 + + ntpdc/ntpdc.1ntpdcmdoc@1.125 +1 -1 + NTP_4_2_7P308 + + ntpdc/ntpdc.html@1.137 +2 -2 + NTP_4_2_7P308 + + ntpdc/ntpdc.man.in@1.125 +2 -2 + NTP_4_2_7P308 + + ntpdc/ntpdc.mdoc.in@1.125 +1 -1 + NTP_4_2_7P308 + + ntpq/invoke-ntpq.texi@1.296 +2 -2 + NTP_4_2_7P308 + + ntpq/ntpq-opts.c@1.311 +4 -4 + NTP_4_2_7P308 + + ntpq/ntpq-opts.h@1.311 +3 -3 + NTP_4_2_7P308 + + ntpq/ntpq.1ntpqman@1.125 +2 -2 + NTP_4_2_7P308 + + ntpq/ntpq.1ntpqmdoc@1.125 +1 -1 + NTP_4_2_7P308 + + ntpq/ntpq.man.in@1.125 +2 -2 + NTP_4_2_7P308 + + ntpq/ntpq.mdoc.in@1.125 +1 -1 + NTP_4_2_7P308 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.296 +2 -2 + NTP_4_2_7P308 + + ntpsnmpd/ntpsnmpd-opts.c@1.311 +4 -4 + NTP_4_2_7P308 + + ntpsnmpd/ntpsnmpd-opts.h@1.311 +3 -3 + NTP_4_2_7P308 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.125 +2 -2 + NTP_4_2_7P308 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.125 +1 -1 + NTP_4_2_7P308 + + ntpsnmpd/ntpsnmpd.man.in@1.125 +2 -2 + NTP_4_2_7P308 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.125 +1 -1 + NTP_4_2_7P308 + + packageinfo.sh@1.311 +1 -1 + NTP_4_2_7P308 + + scripts/invoke-ntp-wait.texi@1.114 +1 -1 + NTP_4_2_7P308 + + scripts/ntp-wait.1ntp-waitman@1.125 +2 -2 + NTP_4_2_7P308 + + scripts/ntp-wait.1ntp-waitmdoc@1.125 +1 -1 + NTP_4_2_7P308 + + scripts/ntp-wait.html@1.129 +1 -1 + NTP_4_2_7P308 + + scripts/ntp-wait.man.in@1.125 +2 -2 + NTP_4_2_7P308 + + scripts/ntp-wait.mdoc.in@1.125 +1 -1 + NTP_4_2_7P308 + + sntp/invoke-sntp.texi@1.293 +2 -2 + NTP_4_2_7P308 + + sntp/sntp-opts.c@1.308 +4 -4 + NTP_4_2_7P308 + + sntp/sntp-opts.h@1.308 +3 -3 + NTP_4_2_7P308 + + sntp/sntp.1sntpman@1.128 +2 -2 + NTP_4_2_7P308 + + sntp/sntp.1sntpmdoc@1.128 +1 -1 + NTP_4_2_7P308 + + sntp/sntp.html@1.308 +2 -2 + NTP_4_2_7P308 + + sntp/sntp.man.in@1.128 +2 -2 + NTP_4_2_7P308 + + sntp/sntp.mdoc.in@1.128 +1 -1 + NTP_4_2_7P308 + + util/invoke-ntp-keygen.texi@1.297 +2 -2 + NTP_4_2_7P308 + + util/ntp-keygen-opts.c@1.311 +4 -4 + NTP_4_2_7P308 + + util/ntp-keygen-opts.h@1.311 +3 -3 + NTP_4_2_7P308 + + util/ntp-keygen.1ntp-keygenman@1.125 +2 -2 + NTP_4_2_7P308 + + util/ntp-keygen.1ntp-keygenmdoc@1.125 +1 -1 + NTP_4_2_7P308 + + util/ntp-keygen.man.in@1.125 +2 -2 + NTP_4_2_7P308 + + util/ntp-keygen.mdoc.in@1.125 +1 -1 + NTP_4_2_7P308 + +ChangeSet@1.2822.1.6, 2012-09-29 02:03:52-04:00, stenn@psp-deb1.ntp.org + CID 97198: Check return from ioctl() calls in refclock_acts.c + + ChangeLog@1.1191.1.6 +1 -0 + CID 97198: Check return from ioctl() calls in refclock_acts.c + + ntpd/refclock_acts.c@1.52 +4 -2 + CID 97198: Check return from ioctl() calls in refclock_acts.c + +ChangeSet@1.2822.1.5, 2012-09-29 00:52:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P307 + TAG: NTP_4_2_7P307 + + ChangeLog@1.1191.1.5 +1 -0 + NTP_4_2_7P307 + + ntpd/invoke-ntpd.texi@1.296 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.conf.5man@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.conf.5mdoc@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.conf.man.in@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.conf.mdoc.in@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.keys.5man@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.keys.5mdoc@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.keys.man.in@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntp.keys.mdoc.in@1.13 +2 -2 + NTP_4_2_7P307 + + ntpd/ntpd-opts.c@1.314 +4 -4 + NTP_4_2_7P307 + + ntpd/ntpd-opts.h@1.314 +3 -3 + NTP_4_2_7P307 + + ntpd/ntpd.1ntpdman@1.125 +2 -2 + NTP_4_2_7P307 + + ntpd/ntpd.1ntpdmdoc@1.125 +2 -2 + NTP_4_2_7P307 + + ntpd/ntpd.man.in@1.125 +2 -2 + NTP_4_2_7P307 + + ntpd/ntpd.mdoc.in@1.125 +2 -2 + NTP_4_2_7P307 + + ntpdc/invoke-ntpdc.texi@1.293 +2 -2 + NTP_4_2_7P307 + + ntpdc/ntpdc-opts.c@1.308 +4 -4 + NTP_4_2_7P307 + + ntpdc/ntpdc-opts.h@1.308 +3 -3 + NTP_4_2_7P307 + + ntpdc/ntpdc.1ntpdcman@1.124 +2 -2 + NTP_4_2_7P307 + + ntpdc/ntpdc.1ntpdcmdoc@1.124 +2 -2 + NTP_4_2_7P307 + + ntpdc/ntpdc.html@1.136 +2 -2 + NTP_4_2_7P307 + + ntpdc/ntpdc.man.in@1.124 +2 -2 + NTP_4_2_7P307 + + ntpdc/ntpdc.mdoc.in@1.124 +2 -2 + NTP_4_2_7P307 + + ntpq/invoke-ntpq.texi@1.295 +2 -2 + NTP_4_2_7P307 + + ntpq/ntpq-opts.c@1.310 +4 -4 + NTP_4_2_7P307 + + ntpq/ntpq-opts.h@1.310 +3 -3 + NTP_4_2_7P307 + + ntpq/ntpq.1ntpqman@1.124 +2 -2 + NTP_4_2_7P307 + + ntpq/ntpq.1ntpqmdoc@1.124 +2 -2 + NTP_4_2_7P307 + + ntpq/ntpq.man.in@1.124 +2 -2 + NTP_4_2_7P307 + + ntpq/ntpq.mdoc.in@1.124 +2 -2 + NTP_4_2_7P307 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.295 +2 -2 + NTP_4_2_7P307 + + ntpsnmpd/ntpsnmpd-opts.c@1.310 +4 -4 + NTP_4_2_7P307 + + ntpsnmpd/ntpsnmpd-opts.h@1.310 +3 -3 + NTP_4_2_7P307 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.124 +2 -2 + NTP_4_2_7P307 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.124 +2 -2 + NTP_4_2_7P307 + + ntpsnmpd/ntpsnmpd.man.in@1.124 +2 -2 + NTP_4_2_7P307 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.124 +2 -2 + NTP_4_2_7P307 + + packageinfo.sh@1.310 +1 -1 + NTP_4_2_7P307 + + scripts/invoke-ntp-wait.texi@1.113 +1 -1 + NTP_4_2_7P307 + + scripts/ntp-wait.1ntp-waitman@1.124 +2 -2 + NTP_4_2_7P307 + + scripts/ntp-wait.1ntp-waitmdoc@1.124 +2 -2 + NTP_4_2_7P307 + + scripts/ntp-wait.html@1.128 +1 -1 + NTP_4_2_7P307 + + scripts/ntp-wait.man.in@1.124 +2 -2 + NTP_4_2_7P307 + + scripts/ntp-wait.mdoc.in@1.124 +2 -2 + NTP_4_2_7P307 + + sntp/invoke-sntp.texi@1.292 +2 -2 + NTP_4_2_7P307 + + sntp/sntp-opts.c@1.307 +4 -4 + NTP_4_2_7P307 + + sntp/sntp-opts.h@1.307 +3 -3 + NTP_4_2_7P307 + + sntp/sntp.1sntpman@1.127 +3 -65 + NTP_4_2_7P307 + + sntp/sntp.1sntpmdoc@1.127 +4 -66 + NTP_4_2_7P307 + + sntp/sntp.html@1.307 +93 -118 + NTP_4_2_7P307 + + sntp/sntp.man.in@1.127 +3 -65 + NTP_4_2_7P307 + + sntp/sntp.mdoc.in@1.127 +4 -66 + NTP_4_2_7P307 + + util/invoke-ntp-keygen.texi@1.296 +2 -2 + NTP_4_2_7P307 + + util/ntp-keygen-opts.c@1.310 +4 -4 + NTP_4_2_7P307 + + util/ntp-keygen-opts.h@1.310 +3 -3 + NTP_4_2_7P307 + + util/ntp-keygen.1ntp-keygenman@1.124 +2 -2 + NTP_4_2_7P307 + + util/ntp-keygen.1ntp-keygenmdoc@1.124 +2 -2 + NTP_4_2_7P307 + + util/ntp-keygen.man.in@1.124 +2 -2 + NTP_4_2_7P307 + + util/ntp-keygen.mdoc.in@1.124 +2 -2 + NTP_4_2_7P307 + +ChangeSet@1.2822.1.4, 2012-09-28 20:12:45-04:00, stenn@psp-deb1.ntp.org + [Bug 1997] Fix sntp broadcast timeouts + + ChangeLog@1.1191.1.4 +1 -0 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/invoke-sntp.texi@1.291 +13 -20 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/main.c@1.83 +68 -18 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp-opts.c@1.306 +172 -197 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp-opts.def@1.40 +9 -19 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp-opts.h@1.306 +30 -39 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp.1sntpman@1.126 +73 -18 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp.1sntpmdoc@1.126 +74 -18 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp.html@1.306 +141 -130 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp.man.in@1.126 +73 -18 + [Bug 1997] Fix sntp broadcast timeouts + + sntp/sntp.mdoc.in@1.126 +74 -18 + [Bug 1997] Fix sntp broadcast timeouts + +ChangeSet@1.2822.1.3, 2012-09-23 01:03:01-04:00, stenn@psp-deb1.ntp.org + Fix typo in html/select.html + + ChangeLog@1.1191.1.3 +1 -0 + Fix typo in html/select.html + + html/select.html@1.7 +1 -1 + Fix typo in html/select.html + +ChangeSet@1.2822.1.2, 2012-09-22 21:07:43-04:00, stenn@psp-deb1.ntp.org + [Bug 2234] Fix incorrect ntptrace html documentation. + + ChangeLog@1.1191.1.2 +1 -0 + [Bug 2234] Fix incorrect ntptrace html documentation. + + html/ntptrace.html@1.17 +3 -9 + [Bug 2234] Fix incorrect ntptrace html documentation. + +ChangeSet@1.2822.1.1, 2012-09-17 06:11:50-04:00, stenn@psp-deb1.ntp.org + [Bug 2262] Install html docs in $htmldir + + ChangeLog@1.1191.1.1 +1 -0 + [Bug 2262] Install html docs in $htmldir + + ntpdc/Makefile.am@1.73 +6 -1 + [Bug 2262] Install html docs in $htmldir + + scripts/Makefile.am@1.31 +6 -1 + [Bug 2262] Install html docs in $htmldir + +ChangeSet@1.2823, 2012-09-17 02:46:11-04:00, stenn@psp-deb1.ntp.org + [Bug 2278] ACTS flag3 mismatch between code and driver18.html. + + ChangeLog@1.1192 +1 -0 + [Bug 2278] ACTS flag3 mismatch between code and driver18.html. + + html/drivers/driver18.html@1.18 +4 -4 + [Bug 2278] ACTS flag3 mismatch between code and driver18.html. + +ChangeSet@1.2822, 2012-09-15 11:26:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P306 + TAG: NTP_4_2_7P306 + + ChangeLog@1.1191 +1 -0 + NTP_4_2_7P306 + + ntpd/invoke-ntpd.texi@1.295 +2 -2 + NTP_4_2_7P306 + + ntpd/ntp.conf.5man@1.12 +2 -2 + NTP_4_2_7P306 + + ntpd/ntp.conf.5mdoc@1.12 +1 -1 + NTP_4_2_7P306 + + ntpd/ntp.conf.man.in@1.12 +2 -2 + NTP_4_2_7P306 + + ntpd/ntp.conf.mdoc.in@1.12 +1 -1 + NTP_4_2_7P306 + + ntpd/ntp.keys.5man@1.12 +2 -2 + NTP_4_2_7P306 + + ntpd/ntp.keys.5mdoc@1.12 +1 -1 + NTP_4_2_7P306 + + ntpd/ntp.keys.man.in@1.12 +2 -2 + NTP_4_2_7P306 + + ntpd/ntp.keys.mdoc.in@1.12 +1 -1 + NTP_4_2_7P306 + + ntpd/ntpd-opts.c@1.313 +4 -4 + NTP_4_2_7P306 + + ntpd/ntpd-opts.h@1.313 +3 -3 + NTP_4_2_7P306 + + ntpd/ntpd.1ntpdman@1.124 +2 -2 + NTP_4_2_7P306 + + ntpd/ntpd.1ntpdmdoc@1.124 +1 -1 + NTP_4_2_7P306 + + ntpd/ntpd.man.in@1.124 +2 -2 + NTP_4_2_7P306 + + ntpd/ntpd.mdoc.in@1.124 +1 -1 + NTP_4_2_7P306 + + ntpdc/invoke-ntpdc.texi@1.292 +2 -2 + NTP_4_2_7P306 + + ntpdc/ntpdc-opts.c@1.307 +4 -4 + NTP_4_2_7P306 + + ntpdc/ntpdc-opts.h@1.307 +3 -3 + NTP_4_2_7P306 + + ntpdc/ntpdc.1ntpdcman@1.123 +2 -2 + NTP_4_2_7P306 + + ntpdc/ntpdc.1ntpdcmdoc@1.123 +1 -1 + NTP_4_2_7P306 + + ntpdc/ntpdc.html@1.135 +2 -2 + NTP_4_2_7P306 + + ntpdc/ntpdc.man.in@1.123 +2 -2 + NTP_4_2_7P306 + + ntpdc/ntpdc.mdoc.in@1.123 +1 -1 + NTP_4_2_7P306 + + ntpq/invoke-ntpq.texi@1.294 +2 -2 + NTP_4_2_7P306 + + ntpq/ntpq-opts.c@1.309 +4 -4 + NTP_4_2_7P306 + + ntpq/ntpq-opts.h@1.309 +3 -3 + NTP_4_2_7P306 + + ntpq/ntpq.1ntpqman@1.123 +2 -2 + NTP_4_2_7P306 + + ntpq/ntpq.1ntpqmdoc@1.123 +1 -1 + NTP_4_2_7P306 + + ntpq/ntpq.man.in@1.123 +2 -2 + NTP_4_2_7P306 + + ntpq/ntpq.mdoc.in@1.123 +1 -1 + NTP_4_2_7P306 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.294 +2 -2 + NTP_4_2_7P306 + + ntpsnmpd/ntpsnmpd-opts.c@1.309 +4 -4 + NTP_4_2_7P306 + + ntpsnmpd/ntpsnmpd-opts.h@1.309 +3 -3 + NTP_4_2_7P306 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.123 +2 -2 + NTP_4_2_7P306 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.123 +1 -1 + NTP_4_2_7P306 + + ntpsnmpd/ntpsnmpd.man.in@1.123 +2 -2 + NTP_4_2_7P306 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.123 +1 -1 + NTP_4_2_7P306 + + packageinfo.sh@1.309 +1 -1 + NTP_4_2_7P306 + + scripts/invoke-ntp-wait.texi@1.112 +1 -1 + NTP_4_2_7P306 + + scripts/ntp-wait.1ntp-waitman@1.123 +2 -2 + NTP_4_2_7P306 + + scripts/ntp-wait.1ntp-waitmdoc@1.123 +1 -1 + NTP_4_2_7P306 + + scripts/ntp-wait.html@1.127 +1 -1 + NTP_4_2_7P306 + + scripts/ntp-wait.man.in@1.123 +2 -2 + NTP_4_2_7P306 + + scripts/ntp-wait.mdoc.in@1.123 +1 -1 + NTP_4_2_7P306 + + sntp/invoke-sntp.texi@1.290 +2 -2 + NTP_4_2_7P306 + + sntp/sntp-opts.c@1.305 +4 -4 + NTP_4_2_7P306 + + sntp/sntp-opts.h@1.305 +3 -3 + NTP_4_2_7P306 + + sntp/sntp.1sntpman@1.125 +2 -2 + NTP_4_2_7P306 + + sntp/sntp.1sntpmdoc@1.125 +1 -1 + NTP_4_2_7P306 + + sntp/sntp.html@1.305 +2 -2 + NTP_4_2_7P306 + + sntp/sntp.man.in@1.125 +2 -2 + NTP_4_2_7P306 + + sntp/sntp.mdoc.in@1.125 +1 -1 + NTP_4_2_7P306 + + util/invoke-ntp-keygen.texi@1.295 +2 -2 + NTP_4_2_7P306 + + util/ntp-keygen-opts.c@1.309 +4 -4 + NTP_4_2_7P306 + + util/ntp-keygen-opts.h@1.309 +3 -3 + NTP_4_2_7P306 + + util/ntp-keygen.1ntp-keygenman@1.123 +2 -2 + NTP_4_2_7P306 + + util/ntp-keygen.1ntp-keygenmdoc@1.123 +1 -1 + NTP_4_2_7P306 + + util/ntp-keygen.man.in@1.123 +2 -2 + NTP_4_2_7P306 + + util/ntp-keygen.mdoc.in@1.123 +1 -1 + NTP_4_2_7P306 + +ChangeSet@1.2821, 2012-09-15 03:45:57-04:00, stenn@deacon.udel.edu + [Bug 752] ToS cleanup from Mike Tatarinov + + ChangeLog@1.1190 +1 -0 + [Bug 752] ToS cleanup from Mike Tatarinov + + include/ntp_config.h@1.75 +0 -23 + [Bug 752] ToS cleanup from Mike Tatarinov + + libntp/socket.c@1.9 +0 -13 + [Bug 752] ToS cleanup from Mike Tatarinov + + ntpd/keyword-gen-utd@1.18 +1 -1 + [Bug 752] ToS cleanup from Mike Tatarinov + + ntpd/keyword-gen.c@1.23 +0 -1 + [Bug 752] ToS cleanup from Mike Tatarinov + + ntpd/ntp_keyword.h@1.20 +488 -492 + [Bug 752] ToS cleanup from Mike Tatarinov + + ntpd/ntp_parser.c@1.81 +713 -717 + [Bug 752] ToS cleanup from Mike Tatarinov + + ntpd/ntp_parser.h@1.47 +107 -109 + [Bug 752] ToS cleanup from Mike Tatarinov + + ntpd/ntp_parser.y@1.75 +0 -2 + [Bug 752] ToS cleanup from Mike Tatarinov + +ChangeSet@1.2820, 2012-09-15 07:21:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P305 + TAG: NTP_4_2_7P305 + + ChangeLog@1.1189 +1 -0 + NTP_4_2_7P305 + + ntpd/invoke-ntpd.texi@1.294 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.conf.5man@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.conf.5mdoc@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.conf.man.in@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.conf.mdoc.in@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.keys.5man@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.keys.5mdoc@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.keys.man.in@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntp.keys.mdoc.in@1.11 +2 -2 + NTP_4_2_7P305 + + ntpd/ntpd-opts.c@1.312 +4 -4 + NTP_4_2_7P305 + + ntpd/ntpd-opts.h@1.312 +3 -3 + NTP_4_2_7P305 + + ntpd/ntpd.1ntpdman@1.123 +2 -2 + NTP_4_2_7P305 + + ntpd/ntpd.1ntpdmdoc@1.123 +2 -2 + NTP_4_2_7P305 + + ntpd/ntpd.man.in@1.123 +2 -2 + NTP_4_2_7P305 + + ntpd/ntpd.mdoc.in@1.123 +2 -2 + NTP_4_2_7P305 + + ntpdc/invoke-ntpdc.texi@1.291 +2 -2 + NTP_4_2_7P305 + + ntpdc/ntpdc-opts.c@1.306 +4 -4 + NTP_4_2_7P305 + + ntpdc/ntpdc-opts.h@1.306 +3 -3 + NTP_4_2_7P305 + + ntpdc/ntpdc.1ntpdcman@1.122 +2 -2 + NTP_4_2_7P305 + + ntpdc/ntpdc.1ntpdcmdoc@1.122 +2 -2 + NTP_4_2_7P305 + + ntpdc/ntpdc.html@1.134 +2 -2 + NTP_4_2_7P305 + + ntpdc/ntpdc.man.in@1.122 +2 -2 + NTP_4_2_7P305 + + ntpdc/ntpdc.mdoc.in@1.122 +2 -2 + NTP_4_2_7P305 + + ntpq/invoke-ntpq.texi@1.293 +2 -2 + NTP_4_2_7P305 + + ntpq/ntpq-opts.c@1.308 +4 -4 + NTP_4_2_7P305 + + ntpq/ntpq-opts.h@1.308 +3 -3 + NTP_4_2_7P305 + + ntpq/ntpq.1ntpqman@1.122 +2 -2 + NTP_4_2_7P305 + + ntpq/ntpq.1ntpqmdoc@1.122 +2 -2 + NTP_4_2_7P305 + + ntpq/ntpq.man.in@1.122 +2 -2 + NTP_4_2_7P305 + + ntpq/ntpq.mdoc.in@1.122 +2 -2 + NTP_4_2_7P305 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.293 +2 -2 + NTP_4_2_7P305 + + ntpsnmpd/ntpsnmpd-opts.c@1.308 +4 -4 + NTP_4_2_7P305 + + ntpsnmpd/ntpsnmpd-opts.h@1.308 +3 -3 + NTP_4_2_7P305 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.122 +2 -2 + NTP_4_2_7P305 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.122 +2 -2 + NTP_4_2_7P305 + + ntpsnmpd/ntpsnmpd.man.in@1.122 +2 -2 + NTP_4_2_7P305 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.122 +2 -2 + NTP_4_2_7P305 + + packageinfo.sh@1.308 +1 -1 + NTP_4_2_7P305 + + scripts/invoke-ntp-wait.texi@1.111 +1 -1 + NTP_4_2_7P305 + + scripts/ntp-wait.1ntp-waitman@1.122 +2 -2 + NTP_4_2_7P305 + + scripts/ntp-wait.1ntp-waitmdoc@1.122 +2 -2 + NTP_4_2_7P305 + + scripts/ntp-wait.html@1.126 +1 -1 + NTP_4_2_7P305 + + scripts/ntp-wait.man.in@1.122 +2 -2 + NTP_4_2_7P305 + + scripts/ntp-wait.mdoc.in@1.122 +2 -2 + NTP_4_2_7P305 + + sntp/invoke-sntp.texi@1.289 +2 -2 + NTP_4_2_7P305 + + sntp/sntp-opts.c@1.304 +4 -4 + NTP_4_2_7P305 + + sntp/sntp-opts.h@1.304 +3 -3 + NTP_4_2_7P305 + + sntp/sntp.1sntpman@1.124 +2 -2 + NTP_4_2_7P305 + + sntp/sntp.1sntpmdoc@1.124 +2 -2 + NTP_4_2_7P305 + + sntp/sntp.html@1.304 +2 -2 + NTP_4_2_7P305 + + sntp/sntp.man.in@1.124 +2 -2 + NTP_4_2_7P305 + + sntp/sntp.mdoc.in@1.124 +2 -2 + NTP_4_2_7P305 + + util/invoke-ntp-keygen.texi@1.294 +2 -2 + NTP_4_2_7P305 + + util/ntp-keygen-opts.c@1.308 +4 -4 + NTP_4_2_7P305 + + util/ntp-keygen-opts.h@1.308 +3 -3 + NTP_4_2_7P305 + + util/ntp-keygen.1ntp-keygenman@1.122 +2 -2 + NTP_4_2_7P305 + + util/ntp-keygen.1ntp-keygenmdoc@1.122 +2 -2 + NTP_4_2_7P305 + + util/ntp-keygen.man.in@1.122 +2 -2 + NTP_4_2_7P305 + + util/ntp-keygen.mdoc.in@1.122 +2 -2 + NTP_4_2_7P305 + +ChangeSet@1.2819, 2012-09-15 02:20:37-04:00, stenn@deacon.udel.edu + [Bug 2276] clk_sel240x.c #define's _XOPEN_SOURCE, breaking QNX6 + + ChangeLog@1.1188 +1 -0 + [Bug 2276] clk_sel240x.c #define's _XOPEN_SOURCE, breaking QNX6 + + libparse/clk_sel240x.c@1.3 +3 -3 + [Bug 2276] clk_sel240x.c #define's _XOPEN_SOURCE, breaking QNX6 + +ChangeSet@1.2818, 2012-09-15 00:38:40-04:00, stenn@deacon.udel.edu + generated parser file cleanup + + ntpd/keyword-gen-utd@1.17 +1 -1 + generated parser file cleanup + + ntpd/ntp_keyword.h@1.19 +995 -989 + generated parser file cleanup + + ntpd/ntp_parser.c@1.80 +1015 -1002 + generated parser file cleanup + + ntpd/ntp_parser.h@1.46 +367 -365 + generated parser file cleanup + +ChangeSet@1.2817, 2012-09-15 00:35:46-04:00, stenn@deacon.udel.edu + [Bug 2258] Add syslog message about leap insertion + + ChangeLog@1.1187 +1 -0 + [Bug 2258] Add syslog message about leap insertion + + ntpd/ntp_timer.c@1.70 +6 -5 + [Bug 2258] Add syslog message about leap insertion + +ChangeSet@1.2816, 2012-09-14 23:42:10-04:00, stenn@deacon.udel.edu + [Bug 1232] Convert SHM refclock to use struct timespec + + ChangeLog@1.1186 +1 -0 + [Bug 1232] Convert SHM refclock to use struct timespec + + ntpd/refclock_shm.c@1.26 +25 -33 + [Bug 1232] Convert SHM refclock to use struct timespec + +ChangeSet@1.2815, 2012-09-14 18:45:55-04:00, stenn@psp-deb1.ntp.org + Updates to driver28.html + + ChangeLog@1.1185 +1 -0 + Updates to driver28.html + + html/drivers/driver28.html@1.14 +26 -25 + Updates to driver28.html + +ChangeSet@1.2814, 2012-09-14 18:44:39-04:00, stenn@psp-deb1.ntp.org + [Bug 2263] broadcast server doesn't work for host with OS_MISSES_SPECIFIC_ROUTE_UPDATES + + ChangeLog@1.1184 +2 -0 + [Bug 2263] broadcast server doesn't work for host with OS_MISSES_SPECIFIC_ROUTE_UPDATES + + include/ntp.h@1.206 +2 -1 + [Bug 2263] broadcast server doesn't work for host with OS_MISSES_SPECIFIC_ROUTE_UPDATES + + ntpd/keyword-gen.c@1.22 +1 -0 + [Bug 2263] broadcast server doesn't work for host with OS_MISSES_SPECIFIC_ROUTE_UPDATES + + ntpd/ntp_io.c@1.370 +49 -35 + [Bug 2263] broadcast server doesn't work for host with OS_MISSES_SPECIFIC_ROUTE_UPDATES + + ntpd/ntp_parser.y@1.74 +3 -0 + [Bug 2263] broadcast server doesn't work for host with OS_MISSES_SPECIFIC_ROUTE_UPDATES + +ChangeSet@1.2813, 2012-09-14 18:33:31-04:00, stenn@psp-deb1.ntp.org + [Bug 752] Use proper ToS network packet markings for IPv4 and IPv6 + + ChangeLog@1.1183 +1 -0 + [Bug 752] Use proper ToS network packet markings for IPv4 and IPv6 + + configure.ac@1.551 +0 -27 + [Bug 752] Use proper ToS network packet markings for IPv4 and IPv6 + + include/libntp.h@1.3 +0 -2 + [Bug 752] Use proper ToS network packet markings for IPv4 and IPv6 + + ntpd/ntp_config.c@1.303 +0 -84 + [Bug 752] Use proper ToS network packet markings for IPv4 and IPv6 + + ntpd/ntp_io.c@1.369 +15 -3 + [Bug 752] Use proper ToS network packet markings for IPv4 and IPv6 + +ChangeSet@1.2812, 2012-09-09 19:05:06-04:00, stenn@deacon.udel.edu + [Bug 2271] Decode refclock types when built with --disable-all-clocks. + + ChangeLog@1.1182 +1 -0 + [Bug 2271] Decode refclock types when built with --disable-all-clocks. + + include/ntp_net.h@1.12 +0 -4 + [Bug 2271] Decode refclock types when built with --disable-all-clocks. + + ntpd/ntp_peer.c@1.153 +8 -3 + [Bug 2271] Decode refclock types when built with --disable-all-clocks. + +ChangeSet@1.2811, 2012-09-06 08:28:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P304 + TAG: NTP_4_2_7P304 + + ChangeLog@1.1181 +1 -0 + NTP_4_2_7P304 + + ntpd/invoke-ntpd.texi@1.293 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.conf.5man@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.conf.5mdoc@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.conf.man.in@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.conf.mdoc.in@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.keys.5man@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.keys.5mdoc@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.keys.man.in@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntp.keys.mdoc.in@1.10 +2 -2 + NTP_4_2_7P304 + + ntpd/ntpd-opts.c@1.311 +4 -4 + NTP_4_2_7P304 + + ntpd/ntpd-opts.h@1.311 +3 -3 + NTP_4_2_7P304 + + ntpd/ntpd.1ntpdman@1.122 +2 -2 + NTP_4_2_7P304 + + ntpd/ntpd.1ntpdmdoc@1.122 +2 -2 + NTP_4_2_7P304 + + ntpd/ntpd.man.in@1.122 +2 -2 + NTP_4_2_7P304 + + ntpd/ntpd.mdoc.in@1.122 +2 -2 + NTP_4_2_7P304 + + ntpdc/invoke-ntpdc.texi@1.290 +2 -2 + NTP_4_2_7P304 + + ntpdc/ntpdc-opts.c@1.305 +4 -4 + NTP_4_2_7P304 + + ntpdc/ntpdc-opts.h@1.305 +3 -3 + NTP_4_2_7P304 + + ntpdc/ntpdc.1ntpdcman@1.121 +2 -2 + NTP_4_2_7P304 + + ntpdc/ntpdc.1ntpdcmdoc@1.121 +2 -2 + NTP_4_2_7P304 + + ntpdc/ntpdc.html@1.133 +2 -2 + NTP_4_2_7P304 + + ntpdc/ntpdc.man.in@1.121 +2 -2 + NTP_4_2_7P304 + + ntpdc/ntpdc.mdoc.in@1.121 +2 -2 + NTP_4_2_7P304 + + ntpq/invoke-ntpq.texi@1.292 +2 -2 + NTP_4_2_7P304 + + ntpq/ntpq-opts.c@1.307 +4 -4 + NTP_4_2_7P304 + + ntpq/ntpq-opts.h@1.307 +3 -3 + NTP_4_2_7P304 + + ntpq/ntpq.1ntpqman@1.121 +2 -2 + NTP_4_2_7P304 + + ntpq/ntpq.1ntpqmdoc@1.121 +2 -2 + NTP_4_2_7P304 + + ntpq/ntpq.man.in@1.121 +2 -2 + NTP_4_2_7P304 + + ntpq/ntpq.mdoc.in@1.121 +2 -2 + NTP_4_2_7P304 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.292 +2 -2 + NTP_4_2_7P304 + + ntpsnmpd/ntpsnmpd-opts.c@1.307 +4 -4 + NTP_4_2_7P304 + + ntpsnmpd/ntpsnmpd-opts.h@1.307 +3 -3 + NTP_4_2_7P304 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.121 +2 -2 + NTP_4_2_7P304 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.121 +2 -2 + NTP_4_2_7P304 + + ntpsnmpd/ntpsnmpd.man.in@1.121 +2 -2 + NTP_4_2_7P304 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.121 +2 -2 + NTP_4_2_7P304 + + packageinfo.sh@1.307 +1 -1 + NTP_4_2_7P304 + + scripts/invoke-ntp-wait.texi@1.110 +1 -1 + NTP_4_2_7P304 + + scripts/ntp-wait.1ntp-waitman@1.121 +2 -2 + NTP_4_2_7P304 + + scripts/ntp-wait.1ntp-waitmdoc@1.121 +2 -2 + NTP_4_2_7P304 + + scripts/ntp-wait.html@1.125 +1 -1 + NTP_4_2_7P304 + + scripts/ntp-wait.man.in@1.121 +2 -2 + NTP_4_2_7P304 + + scripts/ntp-wait.mdoc.in@1.121 +2 -2 + NTP_4_2_7P304 + + sntp/invoke-sntp.texi@1.288 +2 -2 + NTP_4_2_7P304 + + sntp/sntp-opts.c@1.303 +4 -4 + NTP_4_2_7P304 + + sntp/sntp-opts.h@1.303 +3 -3 + NTP_4_2_7P304 + + sntp/sntp.1sntpman@1.123 +2 -2 + NTP_4_2_7P304 + + sntp/sntp.1sntpmdoc@1.123 +2 -2 + NTP_4_2_7P304 + + sntp/sntp.html@1.303 +2 -2 + NTP_4_2_7P304 + + sntp/sntp.man.in@1.123 +2 -2 + NTP_4_2_7P304 + + sntp/sntp.mdoc.in@1.123 +2 -2 + NTP_4_2_7P304 + + util/invoke-ntp-keygen.texi@1.293 +2 -2 + NTP_4_2_7P304 + + util/ntp-keygen-opts.c@1.307 +4 -4 + NTP_4_2_7P304 + + util/ntp-keygen-opts.h@1.307 +3 -3 + NTP_4_2_7P304 + + util/ntp-keygen.1ntp-keygenman@1.121 +2 -2 + NTP_4_2_7P304 + + util/ntp-keygen.1ntp-keygenmdoc@1.121 +2 -2 + NTP_4_2_7P304 + + util/ntp-keygen.man.in@1.121 +2 -2 + NTP_4_2_7P304 + + util/ntp-keygen.mdoc.in@1.121 +2 -2 + NTP_4_2_7P304 + +ChangeSet@1.2810, 2012-09-06 00:56:00-04:00, stenn@deacon.udel.edu + In refclock_wwv.c rename SECOND to WWV_SEC and MINUTE to WWV_MIN + + ChangeLog@1.1180 +1 -0 + In refclock_wwv.c rename SECOND to WWV_SEC and MINUTE to WWV_MIN + + ntpd/refclock_wwv.c@1.78 +29 -29 + In refclock_wwv.c rename SECOND to WWV_SEC and MINUTE to WWV_MIN + +ChangeSet@1.2809, 2012-09-05 21:13:07-04:00, stenn@deacon.udel.edu + [Bug 2264] Cleanup SEL240X Refclock + + ChangeLog@1.1179 +1 -0 + [Bug 2264] Cleanup SEL240X Refclock + + libparse/clk_sel240x.c@1.2 +13 -29 + [Bug 2264] Cleanup SEL240X Refclock + +ChangeSet@1.2808, 2012-09-05 20:02:15+00:00, stenn@deacon.udel.edu + NTP_4_2_7P303 + TAG: NTP_4_2_7P303 + + ChangeLog@1.1178 +1 -0 + NTP_4_2_7P303 + + ntpd/invoke-ntpd.texi@1.292 +2 -2 + NTP_4_2_7P303 + + ntpd/ntp.conf.5man@1.9 +2 -2 + NTP_4_2_7P303 + + ntpd/ntp.conf.5mdoc@1.9 +1 -1 + NTP_4_2_7P303 + + ntpd/ntp.conf.man.in@1.9 +2 -2 + NTP_4_2_7P303 + + ntpd/ntp.conf.mdoc.in@1.9 +1 -1 + NTP_4_2_7P303 + + ntpd/ntp.keys.5man@1.9 +2 -2 + NTP_4_2_7P303 + + ntpd/ntp.keys.5mdoc@1.9 +1 -1 + NTP_4_2_7P303 + + ntpd/ntp.keys.man.in@1.9 +2 -2 + NTP_4_2_7P303 + + ntpd/ntp.keys.mdoc.in@1.9 +1 -1 + NTP_4_2_7P303 + + ntpd/ntpd-opts.c@1.310 +4 -4 + NTP_4_2_7P303 + + ntpd/ntpd-opts.h@1.310 +3 -3 + NTP_4_2_7P303 + + ntpd/ntpd.1ntpdman@1.121 +2 -2 + NTP_4_2_7P303 + + ntpd/ntpd.1ntpdmdoc@1.121 +1 -1 + NTP_4_2_7P303 + + ntpd/ntpd.man.in@1.121 +2 -2 + NTP_4_2_7P303 + + ntpd/ntpd.mdoc.in@1.121 +1 -1 + NTP_4_2_7P303 + + ntpdc/invoke-ntpdc.texi@1.289 +2 -2 + NTP_4_2_7P303 + + ntpdc/ntpdc-opts.c@1.304 +4 -4 + NTP_4_2_7P303 + + ntpdc/ntpdc-opts.h@1.304 +3 -3 + NTP_4_2_7P303 + + ntpdc/ntpdc.1ntpdcman@1.120 +2 -2 + NTP_4_2_7P303 + + ntpdc/ntpdc.1ntpdcmdoc@1.120 +1 -1 + NTP_4_2_7P303 + + ntpdc/ntpdc.html@1.132 +2 -2 + NTP_4_2_7P303 + + ntpdc/ntpdc.man.in@1.120 +2 -2 + NTP_4_2_7P303 + + ntpdc/ntpdc.mdoc.in@1.120 +1 -1 + NTP_4_2_7P303 + + ntpq/invoke-ntpq.texi@1.291 +2 -2 + NTP_4_2_7P303 + + ntpq/ntpq-opts.c@1.306 +4 -4 + NTP_4_2_7P303 + + ntpq/ntpq-opts.h@1.306 +3 -3 + NTP_4_2_7P303 + + ntpq/ntpq.1ntpqman@1.120 +2 -2 + NTP_4_2_7P303 + + ntpq/ntpq.1ntpqmdoc@1.120 +1 -1 + NTP_4_2_7P303 + + ntpq/ntpq.man.in@1.120 +2 -2 + NTP_4_2_7P303 + + ntpq/ntpq.mdoc.in@1.120 +1 -1 + NTP_4_2_7P303 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.291 +2 -2 + NTP_4_2_7P303 + + ntpsnmpd/ntpsnmpd-opts.c@1.306 +4 -4 + NTP_4_2_7P303 + + ntpsnmpd/ntpsnmpd-opts.h@1.306 +3 -3 + NTP_4_2_7P303 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.120 +2 -2 + NTP_4_2_7P303 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.120 +1 -1 + NTP_4_2_7P303 + + ntpsnmpd/ntpsnmpd.man.in@1.120 +2 -2 + NTP_4_2_7P303 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.120 +1 -1 + NTP_4_2_7P303 + + packageinfo.sh@1.306 +1 -1 + NTP_4_2_7P303 + + scripts/invoke-ntp-wait.texi@1.109 +1 -1 + NTP_4_2_7P303 + + scripts/ntp-wait.1ntp-waitman@1.120 +2 -2 + NTP_4_2_7P303 + + scripts/ntp-wait.1ntp-waitmdoc@1.120 +1 -1 + NTP_4_2_7P303 + + scripts/ntp-wait.html@1.124 +1 -1 + NTP_4_2_7P303 + + scripts/ntp-wait.man.in@1.120 +2 -2 + NTP_4_2_7P303 + + scripts/ntp-wait.mdoc.in@1.120 +1 -1 + NTP_4_2_7P303 + + sntp/invoke-sntp.texi@1.287 +2 -2 + NTP_4_2_7P303 + + sntp/sntp-opts.c@1.302 +4 -4 + NTP_4_2_7P303 + + sntp/sntp-opts.h@1.302 +3 -3 + NTP_4_2_7P303 + + sntp/sntp.1sntpman@1.122 +2 -2 + NTP_4_2_7P303 + + sntp/sntp.1sntpmdoc@1.122 +1 -1 + NTP_4_2_7P303 + + sntp/sntp.html@1.302 +2 -2 + NTP_4_2_7P303 + + sntp/sntp.man.in@1.122 +2 -2 + NTP_4_2_7P303 + + sntp/sntp.mdoc.in@1.122 +1 -1 + NTP_4_2_7P303 + + util/invoke-ntp-keygen.texi@1.292 +2 -2 + NTP_4_2_7P303 + + util/ntp-keygen-opts.c@1.306 +4 -4 + NTP_4_2_7P303 + + util/ntp-keygen-opts.h@1.306 +3 -3 + NTP_4_2_7P303 + + util/ntp-keygen.1ntp-keygenman@1.120 +2 -2 + NTP_4_2_7P303 + + util/ntp-keygen.1ntp-keygenmdoc@1.120 +1 -1 + NTP_4_2_7P303 + + util/ntp-keygen.man.in@1.120 +2 -2 + NTP_4_2_7P303 + + util/ntp-keygen.mdoc.in@1.120 +1 -1 + NTP_4_2_7P303 + +ChangeSet@1.2807, 2012-09-05 15:13:58-04:00, stenn@deacon.udel.edu + [Bug 1232] Add nanosecond support to SHM driver + + ChangeLog@1.1177 +1 -0 + [Bug 1232] Add nanosecond support to SHM driver + + ntpd/refclock_shm.c@1.25 +134 -86 + [Bug 1232] Add nanosecond support to SHM driver + +ChangeSet@1.2806, 2012-09-05 11:49:16+00:00, stenn@deacon.udel.edu + NTP_4_2_7P302 + TAG: NTP_4_2_7P302 + + ChangeLog@1.1176 +1 -0 + NTP_4_2_7P302 + + ntpd/invoke-ntpd.texi@1.291 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.conf.5man@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.conf.5mdoc@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.conf.man.in@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.conf.mdoc.in@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.keys.5man@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.keys.5mdoc@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.keys.man.in@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntp.keys.mdoc.in@1.8 +2 -2 + NTP_4_2_7P302 + + ntpd/ntpd-opts.c@1.309 +4 -4 + NTP_4_2_7P302 + + ntpd/ntpd-opts.h@1.309 +3 -3 + NTP_4_2_7P302 + + ntpd/ntpd.1ntpdman@1.120 +2 -2 + NTP_4_2_7P302 + + ntpd/ntpd.1ntpdmdoc@1.120 +2 -2 + NTP_4_2_7P302 + + ntpd/ntpd.man.in@1.120 +2 -2 + NTP_4_2_7P302 + + ntpd/ntpd.mdoc.in@1.120 +2 -2 + NTP_4_2_7P302 + + ntpdc/invoke-ntpdc.texi@1.288 +2 -2 + NTP_4_2_7P302 + + ntpdc/ntpdc-opts.c@1.303 +4 -4 + NTP_4_2_7P302 + + ntpdc/ntpdc-opts.h@1.303 +3 -3 + NTP_4_2_7P302 + + ntpdc/ntpdc.1ntpdcman@1.119 +2 -2 + NTP_4_2_7P302 + + ntpdc/ntpdc.1ntpdcmdoc@1.119 +2 -2 + NTP_4_2_7P302 + + ntpdc/ntpdc.html@1.131 +2 -2 + NTP_4_2_7P302 + + ntpdc/ntpdc.man.in@1.119 +2 -2 + NTP_4_2_7P302 + + ntpdc/ntpdc.mdoc.in@1.119 +2 -2 + NTP_4_2_7P302 + + ntpq/invoke-ntpq.texi@1.290 +2 -2 + NTP_4_2_7P302 + + ntpq/ntpq-opts.c@1.305 +4 -4 + NTP_4_2_7P302 + + ntpq/ntpq-opts.h@1.305 +3 -3 + NTP_4_2_7P302 + + ntpq/ntpq.1ntpqman@1.119 +2 -2 + NTP_4_2_7P302 + + ntpq/ntpq.1ntpqmdoc@1.119 +2 -2 + NTP_4_2_7P302 + + ntpq/ntpq.man.in@1.119 +2 -2 + NTP_4_2_7P302 + + ntpq/ntpq.mdoc.in@1.119 +2 -2 + NTP_4_2_7P302 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.290 +2 -2 + NTP_4_2_7P302 + + ntpsnmpd/ntpsnmpd-opts.c@1.305 +4 -4 + NTP_4_2_7P302 + + ntpsnmpd/ntpsnmpd-opts.h@1.305 +3 -3 + NTP_4_2_7P302 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.119 +2 -2 + NTP_4_2_7P302 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.119 +2 -2 + NTP_4_2_7P302 + + ntpsnmpd/ntpsnmpd.man.in@1.119 +2 -2 + NTP_4_2_7P302 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.119 +2 -2 + NTP_4_2_7P302 + + packageinfo.sh@1.305 +1 -1 + NTP_4_2_7P302 + + scripts/invoke-ntp-wait.texi@1.108 +1 -1 + NTP_4_2_7P302 + + scripts/ntp-wait.1ntp-waitman@1.119 +2 -2 + NTP_4_2_7P302 + + scripts/ntp-wait.1ntp-waitmdoc@1.119 +2 -2 + NTP_4_2_7P302 + + scripts/ntp-wait.html@1.123 +1 -1 + NTP_4_2_7P302 + + scripts/ntp-wait.man.in@1.119 +2 -2 + NTP_4_2_7P302 + + scripts/ntp-wait.mdoc.in@1.119 +2 -2 + NTP_4_2_7P302 + + sntp/invoke-sntp.texi@1.286 +2 -2 + NTP_4_2_7P302 + + sntp/sntp-opts.c@1.301 +4 -4 + NTP_4_2_7P302 + + sntp/sntp-opts.h@1.301 +3 -3 + NTP_4_2_7P302 + + sntp/sntp.1sntpman@1.121 +2 -2 + NTP_4_2_7P302 + + sntp/sntp.1sntpmdoc@1.121 +2 -2 + NTP_4_2_7P302 + + sntp/sntp.html@1.301 +2 -2 + NTP_4_2_7P302 + + sntp/sntp.man.in@1.121 +2 -2 + NTP_4_2_7P302 + + sntp/sntp.mdoc.in@1.121 +2 -2 + NTP_4_2_7P302 + + util/invoke-ntp-keygen.texi@1.291 +2 -2 + NTP_4_2_7P302 + + util/ntp-keygen-opts.c@1.305 +4 -4 + NTP_4_2_7P302 + + util/ntp-keygen-opts.h@1.305 +3 -3 + NTP_4_2_7P302 + + util/ntp-keygen.1ntp-keygenman@1.119 +2 -2 + NTP_4_2_7P302 + + util/ntp-keygen.1ntp-keygenmdoc@1.119 +2 -2 + NTP_4_2_7P302 + + util/ntp-keygen.man.in@1.119 +2 -2 + NTP_4_2_7P302 + + util/ntp-keygen.mdoc.in@1.119 +2 -2 + NTP_4_2_7P302 + +ChangeSet@1.2805, 2012-09-05 06:33:07-04:00, stenn@deacon.udel.edu + [Bug 2160] Log warning about expired leapseconds file + + ChangeLog@1.1175 +1 -0 + [Bug 2160] Log warning about expired leapseconds file + + ntpd/ntp_timer.c@1.69 +9 -1 + [Bug 2160] Log warning about expired leapseconds file + +ChangeSet@1.2804, 2012-09-03 11:47:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P301 + TAG: NTP_4_2_7P301 + + ChangeLog@1.1174 +1 -0 + NTP_4_2_7P301 + + ntpd/invoke-ntpd.texi@1.290 +2 -2 + NTP_4_2_7P301 + + ntpd/ntp.conf.5man@1.7 +2 -2 + NTP_4_2_7P301 + + ntpd/ntp.conf.5mdoc@1.7 +1 -1 + NTP_4_2_7P301 + + ntpd/ntp.conf.man.in@1.7 +2 -2 + NTP_4_2_7P301 + + ntpd/ntp.conf.mdoc.in@1.7 +1 -1 + NTP_4_2_7P301 + + ntpd/ntp.keys.5man@1.7 +2 -2 + NTP_4_2_7P301 + + ntpd/ntp.keys.5mdoc@1.7 +1 -1 + NTP_4_2_7P301 + + ntpd/ntp.keys.man.in@1.7 +2 -2 + NTP_4_2_7P301 + + ntpd/ntp.keys.mdoc.in@1.7 +1 -1 + NTP_4_2_7P301 + + ntpd/ntpd-opts.c@1.308 +4 -4 + NTP_4_2_7P301 + + ntpd/ntpd-opts.h@1.308 +3 -3 + NTP_4_2_7P301 + + ntpd/ntpd.1ntpdman@1.119 +2 -2 + NTP_4_2_7P301 + + ntpd/ntpd.1ntpdmdoc@1.119 +1 -1 + NTP_4_2_7P301 + + ntpd/ntpd.man.in@1.119 +2 -2 + NTP_4_2_7P301 + + ntpd/ntpd.mdoc.in@1.119 +1 -1 + NTP_4_2_7P301 + + ntpdc/invoke-ntpdc.texi@1.287 +2 -2 + NTP_4_2_7P301 + + ntpdc/ntpdc-opts.c@1.302 +4 -4 + NTP_4_2_7P301 + + ntpdc/ntpdc-opts.h@1.302 +3 -3 + NTP_4_2_7P301 + + ntpdc/ntpdc.1ntpdcman@1.118 +2 -2 + NTP_4_2_7P301 + + ntpdc/ntpdc.1ntpdcmdoc@1.118 +1 -1 + NTP_4_2_7P301 + + ntpdc/ntpdc.html@1.130 +2 -2 + NTP_4_2_7P301 + + ntpdc/ntpdc.man.in@1.118 +2 -2 + NTP_4_2_7P301 + + ntpdc/ntpdc.mdoc.in@1.118 +1 -1 + NTP_4_2_7P301 + + ntpq/invoke-ntpq.texi@1.289 +2 -2 + NTP_4_2_7P301 + + ntpq/ntpq-opts.c@1.304 +4 -4 + NTP_4_2_7P301 + + ntpq/ntpq-opts.h@1.304 +3 -3 + NTP_4_2_7P301 + + ntpq/ntpq.1ntpqman@1.118 +2 -2 + NTP_4_2_7P301 + + ntpq/ntpq.1ntpqmdoc@1.118 +1 -1 + NTP_4_2_7P301 + + ntpq/ntpq.man.in@1.118 +2 -2 + NTP_4_2_7P301 + + ntpq/ntpq.mdoc.in@1.118 +1 -1 + NTP_4_2_7P301 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.289 +2 -2 + NTP_4_2_7P301 + + ntpsnmpd/ntpsnmpd-opts.c@1.304 +4 -4 + NTP_4_2_7P301 + + ntpsnmpd/ntpsnmpd-opts.h@1.304 +3 -3 + NTP_4_2_7P301 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.118 +2 -2 + NTP_4_2_7P301 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.118 +1 -1 + NTP_4_2_7P301 + + ntpsnmpd/ntpsnmpd.man.in@1.118 +2 -2 + NTP_4_2_7P301 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.118 +1 -1 + NTP_4_2_7P301 + + packageinfo.sh@1.304 +1 -1 + NTP_4_2_7P301 + + scripts/invoke-ntp-wait.texi@1.107 +1 -1 + NTP_4_2_7P301 + + scripts/ntp-wait.1ntp-waitman@1.118 +2 -2 + NTP_4_2_7P301 + + scripts/ntp-wait.1ntp-waitmdoc@1.118 +1 -1 + NTP_4_2_7P301 + + scripts/ntp-wait.html@1.122 +1 -1 + NTP_4_2_7P301 + + scripts/ntp-wait.man.in@1.118 +2 -2 + NTP_4_2_7P301 + + scripts/ntp-wait.mdoc.in@1.118 +1 -1 + NTP_4_2_7P301 + + sntp/invoke-sntp.texi@1.285 +2 -2 + NTP_4_2_7P301 + + sntp/sntp-opts.c@1.300 +4 -4 + NTP_4_2_7P301 + + sntp/sntp-opts.h@1.300 +3 -3 + NTP_4_2_7P301 + + sntp/sntp.1sntpman@1.120 +2 -2 + NTP_4_2_7P301 + + sntp/sntp.1sntpmdoc@1.120 +1 -1 + NTP_4_2_7P301 + + sntp/sntp.html@1.300 +2 -2 + NTP_4_2_7P301 + + sntp/sntp.man.in@1.120 +2 -2 + NTP_4_2_7P301 + + sntp/sntp.mdoc.in@1.120 +1 -1 + NTP_4_2_7P301 + + util/invoke-ntp-keygen.texi@1.290 +2 -2 + NTP_4_2_7P301 + + util/ntp-keygen-opts.c@1.304 +4 -4 + NTP_4_2_7P301 + + util/ntp-keygen-opts.h@1.304 +3 -3 + NTP_4_2_7P301 + + util/ntp-keygen.1ntp-keygenman@1.118 +2 -2 + NTP_4_2_7P301 + + util/ntp-keygen.1ntp-keygenmdoc@1.118 +1 -1 + NTP_4_2_7P301 + + util/ntp-keygen.man.in@1.118 +2 -2 + NTP_4_2_7P301 + + util/ntp-keygen.mdoc.in@1.118 +1 -1 + NTP_4_2_7P301 + +ChangeSet@1.2803, 2012-09-03 05:13:00-04:00, stenn@deacon.udel.edu + [Bug 2164] Greater precision needed for ntpq offset report + + ChangeLog@1.1173 +1 -0 + [Bug 2164] Greater precision needed for ntpq offset report + + ntpd/ntp_control.c@1.183 +4 -2 + [Bug 2164] Greater precision needed for ntpq offset report + +ChangeSet@1.2802, 2012-09-03 03:20:41-04:00, stenn@deacon.udel.edu + Clean the man5_MANS in ntpd/ + + ChangeLog@1.1172 +1 -0 + Clean the man5_MANS in ntpd/ + + ntpd/Makefile.am@1.122 +1 -0 + Clean the man5_MANS in ntpd/ + +ChangeSet@1.2801, 2012-09-03 06:02:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P300 + TAG: NTP_4_2_7P300 + + ChangeLog@1.1171 +1 -0 + NTP_4_2_7P300 + + ntpd/invoke-ntpd.texi@1.289 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.conf.5man@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.conf.5mdoc@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.conf.man.in@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.conf.mdoc.in@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.keys.5man@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.keys.5mdoc@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.keys.man.in@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntp.keys.mdoc.in@1.6 +2 -2 + NTP_4_2_7P300 + + ntpd/ntpd-opts.c@1.307 +4 -4 + NTP_4_2_7P300 + + ntpd/ntpd-opts.h@1.307 +3 -3 + NTP_4_2_7P300 + + ntpd/ntpd.1ntpdman@1.118 +2 -2 + NTP_4_2_7P300 + + ntpd/ntpd.1ntpdmdoc@1.118 +2 -2 + NTP_4_2_7P300 + + ntpd/ntpd.man.in@1.118 +2 -2 + NTP_4_2_7P300 + + ntpd/ntpd.mdoc.in@1.118 +2 -2 + NTP_4_2_7P300 + + ntpdc/invoke-ntpdc.texi@1.286 +2 -2 + NTP_4_2_7P300 + + ntpdc/ntpdc-opts.c@1.301 +4 -4 + NTP_4_2_7P300 + + ntpdc/ntpdc-opts.h@1.301 +3 -3 + NTP_4_2_7P300 + + ntpdc/ntpdc.1ntpdcman@1.117 +2 -2 + NTP_4_2_7P300 + + ntpdc/ntpdc.1ntpdcmdoc@1.117 +2 -2 + NTP_4_2_7P300 + + ntpdc/ntpdc.html@1.129 +2 -2 + NTP_4_2_7P300 + + ntpdc/ntpdc.man.in@1.117 +2 -2 + NTP_4_2_7P300 + + ntpdc/ntpdc.mdoc.in@1.117 +2 -2 + NTP_4_2_7P300 + + ntpq/invoke-ntpq.texi@1.288 +2 -2 + NTP_4_2_7P300 + + ntpq/ntpq-opts.c@1.303 +4 -4 + NTP_4_2_7P300 + + ntpq/ntpq-opts.h@1.303 +3 -3 + NTP_4_2_7P300 + + ntpq/ntpq.1ntpqman@1.117 +2 -2 + NTP_4_2_7P300 + + ntpq/ntpq.1ntpqmdoc@1.117 +2 -2 + NTP_4_2_7P300 + + ntpq/ntpq.man.in@1.117 +2 -2 + NTP_4_2_7P300 + + ntpq/ntpq.mdoc.in@1.117 +2 -2 + NTP_4_2_7P300 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.288 +2 -2 + NTP_4_2_7P300 + + ntpsnmpd/ntpsnmpd-opts.c@1.303 +4 -4 + NTP_4_2_7P300 + + ntpsnmpd/ntpsnmpd-opts.h@1.303 +3 -3 + NTP_4_2_7P300 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.117 +2 -2 + NTP_4_2_7P300 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.117 +2 -2 + NTP_4_2_7P300 + + ntpsnmpd/ntpsnmpd.man.in@1.117 +2 -2 + NTP_4_2_7P300 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.117 +2 -2 + NTP_4_2_7P300 + + packageinfo.sh@1.303 +1 -1 + NTP_4_2_7P300 + + scripts/invoke-ntp-wait.texi@1.106 +1 -1 + NTP_4_2_7P300 + + scripts/ntp-wait.1ntp-waitman@1.117 +2 -2 + NTP_4_2_7P300 + + scripts/ntp-wait.1ntp-waitmdoc@1.117 +2 -2 + NTP_4_2_7P300 + + scripts/ntp-wait.html@1.121 +1 -1 + NTP_4_2_7P300 + + scripts/ntp-wait.man.in@1.117 +2 -2 + NTP_4_2_7P300 + + scripts/ntp-wait.mdoc.in@1.117 +2 -2 + NTP_4_2_7P300 + + sntp/invoke-sntp.texi@1.284 +2 -2 + NTP_4_2_7P300 + + sntp/sntp-opts.c@1.299 +4 -4 + NTP_4_2_7P300 + + sntp/sntp-opts.h@1.299 +3 -3 + NTP_4_2_7P300 + + sntp/sntp.1sntpman@1.119 +2 -2 + NTP_4_2_7P300 + + sntp/sntp.1sntpmdoc@1.119 +2 -2 + NTP_4_2_7P300 + + sntp/sntp.html@1.299 +2 -2 + NTP_4_2_7P300 + + sntp/sntp.man.in@1.119 +2 -2 + NTP_4_2_7P300 + + sntp/sntp.mdoc.in@1.119 +2 -2 + NTP_4_2_7P300 + + util/invoke-ntp-keygen.texi@1.289 +2 -2 + NTP_4_2_7P300 + + util/ntp-keygen-opts.c@1.303 +4 -4 + NTP_4_2_7P300 + + util/ntp-keygen-opts.h@1.303 +3 -3 + NTP_4_2_7P300 + + util/ntp-keygen.1ntp-keygenman@1.117 +2 -2 + NTP_4_2_7P300 + + util/ntp-keygen.1ntp-keygenmdoc@1.117 +2 -2 + NTP_4_2_7P300 + + util/ntp-keygen.man.in@1.117 +2 -2 + NTP_4_2_7P300 + + util/ntp-keygen.mdoc.in@1.117 +2 -2 + NTP_4_2_7P300 + +ChangeSet@1.2791.1.3, 2012-09-02 03:42:22-04:00, stenn@psp-deb1.ntp.org + Installing html docs is bug 2262 + + ChangeLog@1.1161.1.3 +1 -1 + Installing html docs is bug 2262 + +ChangeSet@1.2791.1.2, 2012-09-02 03:35:48-04:00, stenn@psp-deb1.ntp.org + Install sntp.html into htmldir + + ChangeLog@1.1161.1.2 +1 -0 + Install sntp.html into htmldir + + sntp/Makefile.am@1.74 +6 -1 + Install sntp.html into htmldir + +ChangeSet@1.2791.1.1, 2012-09-02 03:34:32-04:00, stenn@psp-deb1.ntp.org + [Bug 2270] Install fails due to repeated man5 page names + + ChangeLog@1.1161.1.1 +1 -0 + [Bug 2270] Install fails due to repeated man5 page names + + ntpd/Makefile.am@1.119.1.1 +1 -1 + [Bug 2270] Install fails due to repeated man5 page names + +ChangeSet@1.2799, 2012-09-01 18:38:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P299 + TAG: NTP_4_2_7P299 + + ChangeLog@1.1169 +1 -0 + NTP_4_2_7P299 + + ntpd/invoke-ntpd.texi@1.288 +2 -2 + NTP_4_2_7P299 + + ntpd/ntp.conf.5man@1.5 +2 -2 + NTP_4_2_7P299 + + ntpd/ntp.conf.5mdoc@1.5 +1 -1 + NTP_4_2_7P299 + + ntpd/ntp.conf.man.in@1.5 +2 -2 + NTP_4_2_7P299 + + ntpd/ntp.conf.mdoc.in@1.5 +1 -1 + NTP_4_2_7P299 + + ntpd/ntp.keys.5man@1.5 +2 -2 + NTP_4_2_7P299 + + ntpd/ntp.keys.5mdoc@1.5 +1 -1 + NTP_4_2_7P299 + + ntpd/ntp.keys.man.in@1.5 +2 -2 + NTP_4_2_7P299 + + ntpd/ntp.keys.mdoc.in@1.5 +1 -1 + NTP_4_2_7P299 + + ntpd/ntpd-opts.c@1.306 +4 -4 + NTP_4_2_7P299 + + ntpd/ntpd-opts.h@1.306 +3 -3 + NTP_4_2_7P299 + + ntpd/ntpd.1ntpdman@1.117 +2 -2 + NTP_4_2_7P299 + + ntpd/ntpd.1ntpdmdoc@1.117 +1 -1 + NTP_4_2_7P299 + + ntpd/ntpd.man.in@1.117 +2 -2 + NTP_4_2_7P299 + + ntpd/ntpd.mdoc.in@1.117 +1 -1 + NTP_4_2_7P299 + + ntpdc/invoke-ntpdc.texi@1.285 +2 -2 + NTP_4_2_7P299 + + ntpdc/ntpdc-opts.c@1.300 +4 -4 + NTP_4_2_7P299 + + ntpdc/ntpdc-opts.h@1.300 +3 -3 + NTP_4_2_7P299 + + ntpdc/ntpdc.1ntpdcman@1.116 +2 -2 + NTP_4_2_7P299 + + ntpdc/ntpdc.1ntpdcmdoc@1.116 +1 -1 + NTP_4_2_7P299 + + ntpdc/ntpdc.html@1.128 +2 -2 + NTP_4_2_7P299 + + ntpdc/ntpdc.man.in@1.116 +2 -2 + NTP_4_2_7P299 + + ntpdc/ntpdc.mdoc.in@1.116 +1 -1 + NTP_4_2_7P299 + + ntpq/invoke-ntpq.texi@1.287 +2 -2 + NTP_4_2_7P299 + + ntpq/ntpq-opts.c@1.302 +4 -4 + NTP_4_2_7P299 + + ntpq/ntpq-opts.h@1.302 +3 -3 + NTP_4_2_7P299 + + ntpq/ntpq.1ntpqman@1.116 +2 -2 + NTP_4_2_7P299 + + ntpq/ntpq.1ntpqmdoc@1.116 +1 -1 + NTP_4_2_7P299 + + ntpq/ntpq.man.in@1.116 +2 -2 + NTP_4_2_7P299 + + ntpq/ntpq.mdoc.in@1.116 +1 -1 + NTP_4_2_7P299 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.287 +2 -2 + NTP_4_2_7P299 + + ntpsnmpd/ntpsnmpd-opts.c@1.302 +4 -4 + NTP_4_2_7P299 + + ntpsnmpd/ntpsnmpd-opts.h@1.302 +3 -3 + NTP_4_2_7P299 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.116 +2 -2 + NTP_4_2_7P299 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.116 +1 -1 + NTP_4_2_7P299 + + ntpsnmpd/ntpsnmpd.man.in@1.116 +2 -2 + NTP_4_2_7P299 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.116 +1 -1 + NTP_4_2_7P299 + + packageinfo.sh@1.302 +1 -1 + NTP_4_2_7P299 + + scripts/invoke-ntp-wait.texi@1.105 +1 -1 + NTP_4_2_7P299 + + scripts/ntp-wait.1ntp-waitman@1.116 +2 -2 + NTP_4_2_7P299 + + scripts/ntp-wait.1ntp-waitmdoc@1.116 +1 -1 + NTP_4_2_7P299 + + scripts/ntp-wait.html@1.120 +1 -1 + NTP_4_2_7P299 + + scripts/ntp-wait.man.in@1.116 +2 -2 + NTP_4_2_7P299 + + scripts/ntp-wait.mdoc.in@1.116 +1 -1 + NTP_4_2_7P299 + + sntp/invoke-sntp.texi@1.283 +2 -2 + NTP_4_2_7P299 + + sntp/sntp-opts.c@1.298 +4 -4 + NTP_4_2_7P299 + + sntp/sntp-opts.h@1.298 +3 -3 + NTP_4_2_7P299 + + sntp/sntp.1sntpman@1.118 +2 -2 + NTP_4_2_7P299 + + sntp/sntp.1sntpmdoc@1.118 +1 -1 + NTP_4_2_7P299 + + sntp/sntp.html@1.298 +2 -2 + NTP_4_2_7P299 + + sntp/sntp.man.in@1.118 +2 -2 + NTP_4_2_7P299 + + sntp/sntp.mdoc.in@1.118 +1 -1 + NTP_4_2_7P299 + + util/invoke-ntp-keygen.texi@1.288 +2 -2 + NTP_4_2_7P299 + + util/ntp-keygen-opts.c@1.302 +4 -4 + NTP_4_2_7P299 + + util/ntp-keygen-opts.h@1.302 +3 -3 + NTP_4_2_7P299 + + util/ntp-keygen.1ntp-keygenman@1.116 +2 -2 + NTP_4_2_7P299 + + util/ntp-keygen.1ntp-keygenmdoc@1.116 +1 -1 + NTP_4_2_7P299 + + util/ntp-keygen.man.in@1.116 +2 -2 + NTP_4_2_7P299 + + util/ntp-keygen.mdoc.in@1.116 +1 -1 + NTP_4_2_7P299 + +ChangeSet@1.2798, 2012-09-01 14:24:07-04:00, stenn@deacon.udel.edu + More cleanup to the bootstrap script + + ChangeLog@1.1168 +1 -0 + More cleanup to the bootstrap script + + bootstrap@1.41 +4 -2 + More cleanup to the bootstrap script + +ChangeSet@1.2797, 2012-09-01 04:07:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P298 + TAG: NTP_4_2_7P298 + + ChangeLog@1.1167 +1 -0 + NTP_4_2_7P298 + + ntpd/invoke-ntpd.texi@1.287 +2 -2 + NTP_4_2_7P298 + + ntpd/ntp.conf.5man@1.4 +2 -2 + NTP_4_2_7P298 + + ntpd/ntp.conf.5mdoc@1.4 +1 -1 + NTP_4_2_7P298 + + ntpd/ntp.conf.man.in@1.4 +2 -2 + NTP_4_2_7P298 + + ntpd/ntp.conf.mdoc.in@1.4 +1 -1 + NTP_4_2_7P298 + + ntpd/ntp.keys.5man@1.4 +2 -2 + NTP_4_2_7P298 + + ntpd/ntp.keys.5mdoc@1.4 +1 -1 + NTP_4_2_7P298 + + ntpd/ntp.keys.man.in@1.4 +2 -2 + NTP_4_2_7P298 + + ntpd/ntp.keys.mdoc.in@1.4 +1 -1 + NTP_4_2_7P298 + + ntpd/ntpd-opts.c@1.305 +4 -4 + NTP_4_2_7P298 + + ntpd/ntpd-opts.h@1.305 +3 -3 + NTP_4_2_7P298 + + ntpd/ntpd.1ntpdman@1.116 +2 -2 + NTP_4_2_7P298 + + ntpd/ntpd.1ntpdmdoc@1.116 +1 -1 + NTP_4_2_7P298 + + ntpd/ntpd.man.in@1.116 +2 -2 + NTP_4_2_7P298 + + ntpd/ntpd.mdoc.in@1.116 +1 -1 + NTP_4_2_7P298 + + ntpdc/invoke-ntpdc.texi@1.284 +2 -2 + NTP_4_2_7P298 + + ntpdc/ntpdc-opts.c@1.299 +4 -4 + NTP_4_2_7P298 + + ntpdc/ntpdc-opts.h@1.299 +3 -3 + NTP_4_2_7P298 + + ntpdc/ntpdc.1ntpdcman@1.115 +2 -2 + NTP_4_2_7P298 + + ntpdc/ntpdc.1ntpdcmdoc@1.115 +1 -1 + NTP_4_2_7P298 + + ntpdc/ntpdc.html@1.127 +2 -2 + NTP_4_2_7P298 + + ntpdc/ntpdc.man.in@1.115 +2 -2 + NTP_4_2_7P298 + + ntpdc/ntpdc.mdoc.in@1.115 +1 -1 + NTP_4_2_7P298 + + ntpq/invoke-ntpq.texi@1.286 +2 -2 + NTP_4_2_7P298 + + ntpq/ntpq-opts.c@1.301 +4 -4 + NTP_4_2_7P298 + + ntpq/ntpq-opts.h@1.301 +3 -3 + NTP_4_2_7P298 + + ntpq/ntpq.1ntpqman@1.115 +2 -2 + NTP_4_2_7P298 + + ntpq/ntpq.1ntpqmdoc@1.115 +1 -1 + NTP_4_2_7P298 + + ntpq/ntpq.man.in@1.115 +2 -2 + NTP_4_2_7P298 + + ntpq/ntpq.mdoc.in@1.115 +1 -1 + NTP_4_2_7P298 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.286 +2 -2 + NTP_4_2_7P298 + + ntpsnmpd/ntpsnmpd-opts.c@1.301 +4 -4 + NTP_4_2_7P298 + + ntpsnmpd/ntpsnmpd-opts.h@1.301 +3 -3 + NTP_4_2_7P298 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.115 +2 -2 + NTP_4_2_7P298 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.115 +1 -1 + NTP_4_2_7P298 + + ntpsnmpd/ntpsnmpd.man.in@1.115 +2 -2 + NTP_4_2_7P298 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.115 +1 -1 + NTP_4_2_7P298 + + packageinfo.sh@1.301 +1 -1 + NTP_4_2_7P298 + + scripts/invoke-ntp-wait.texi@1.104 +1 -1 + NTP_4_2_7P298 + + scripts/ntp-wait.1ntp-waitman@1.115 +2 -2 + NTP_4_2_7P298 + + scripts/ntp-wait.1ntp-waitmdoc@1.115 +1 -1 + NTP_4_2_7P298 + + scripts/ntp-wait.html@1.119 +1 -1 + NTP_4_2_7P298 + + scripts/ntp-wait.man.in@1.115 +2 -2 + NTP_4_2_7P298 + + scripts/ntp-wait.mdoc.in@1.115 +1 -1 + NTP_4_2_7P298 + + sntp/invoke-sntp.texi@1.282 +2 -2 + NTP_4_2_7P298 + + sntp/sntp-opts.c@1.297 +4 -4 + NTP_4_2_7P298 + + sntp/sntp-opts.h@1.297 +3 -3 + NTP_4_2_7P298 + + sntp/sntp.1sntpman@1.117 +2 -2 + NTP_4_2_7P298 + + sntp/sntp.1sntpmdoc@1.117 +1 -1 + NTP_4_2_7P298 + + sntp/sntp.html@1.297 +2 -2 + NTP_4_2_7P298 + + sntp/sntp.man.in@1.117 +2 -2 + NTP_4_2_7P298 + + sntp/sntp.mdoc.in@1.117 +1 -1 + NTP_4_2_7P298 + + util/invoke-ntp-keygen.texi@1.287 +2 -2 + NTP_4_2_7P298 + + util/ntp-keygen-opts.c@1.301 +4 -4 + NTP_4_2_7P298 + + util/ntp-keygen-opts.h@1.301 +3 -3 + NTP_4_2_7P298 + + util/ntp-keygen.1ntp-keygenman@1.115 +2 -2 + NTP_4_2_7P298 + + util/ntp-keygen.1ntp-keygenmdoc@1.115 +1 -1 + NTP_4_2_7P298 + + util/ntp-keygen.man.in@1.115 +2 -2 + NTP_4_2_7P298 + + util/ntp-keygen.mdoc.in@1.115 +1 -1 + NTP_4_2_7P298 + +ChangeSet@1.2796, 2012-08-31 23:45:41-04:00, stenn@deacon.udel.edu + Remove extraneous parens + + ntpdc/ntpdc_ops.c@1.79 +1 -1 + Remove extraneous parens + +ChangeSet@1.2795, 2012-08-31 23:40:43-04:00, stenn@deacon.udel.edu + Remove extraneous parens + + ChangeLog@1.1166 +1 -0 + Remove extraneous parens + +ChangeSet@1.2794, 2012-08-31 23:37:42-04:00, stenn@deacon.udel.edu + Add a missing "%s" syslog format string + + ChangeLog@1.1165 +1 -0 + Handle additional man page sections in the bootstrap script + + ChangeLog@1.1164 +1 -0 + Add a missing "%s" syslog format string + + bootstrap@1.40 +1 -1 + Handle additional man page sections in the bootstrap script + + ntpd/ntp_config.c@1.302 +1 -1 + Add a missing "%s" syslog format string + +ChangeSet@1.2793, 2012-09-01 00:34:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P297 + TAG: NTP_4_2_7P297 + + ChangeLog@1.1163 +1 -0 + NTP_4_2_7P297 + + ntpd/invoke-ntpd.texi@1.286 +2 -2 + NTP_4_2_7P297 + + ntpd/ntp.conf.5man@1.3 +8 -8 + NTP_4_2_7P297 + + ntpd/ntp.conf.5mdoc@1.3 +2 -2 + NTP_4_2_7P297 + + ntpd/ntp.conf.man.in@1.3 +8 -8 + NTP_4_2_7P297 + + ntpd/ntp.conf.mdoc.in@1.3 +2 -2 + NTP_4_2_7P297 + + ntpd/ntp.keys.5man@1.3 +8 -8 + NTP_4_2_7P297 + + ntpd/ntp.keys.5mdoc@1.3 +2 -2 + NTP_4_2_7P297 + + ntpd/ntp.keys.man.in@1.3 +8 -8 + NTP_4_2_7P297 + + ntpd/ntp.keys.mdoc.in@1.3 +2 -2 + NTP_4_2_7P297 + + ntpd/ntpd-opts.c@1.304 +4 -4 + NTP_4_2_7P297 + + ntpd/ntpd-opts.h@1.304 +3 -3 + NTP_4_2_7P297 + + ntpd/ntpd.1ntpdman@1.115 +27 -27 + NTP_4_2_7P297 + + ntpd/ntpd.1ntpdmdoc@1.115 +2 -2 + NTP_4_2_7P297 + + ntpd/ntpd.man.in@1.115 +27 -27 + NTP_4_2_7P297 + + ntpd/ntpd.mdoc.in@1.115 +2 -2 + NTP_4_2_7P297 + + ntpdc/invoke-ntpdc.texi@1.283 +2 -2 + NTP_4_2_7P297 + + ntpdc/ntpdc-opts.c@1.298 +4 -4 + NTP_4_2_7P297 + + ntpdc/ntpdc-opts.h@1.298 +3 -3 + NTP_4_2_7P297 + + ntpdc/ntpdc.1ntpdcman@1.114 +21 -21 + NTP_4_2_7P297 + + ntpdc/ntpdc.1ntpdcmdoc@1.114 +2 -2 + NTP_4_2_7P297 + + ntpdc/ntpdc.html@1.126 +2 -2 + NTP_4_2_7P297 + + ntpdc/ntpdc.man.in@1.114 +21 -21 + NTP_4_2_7P297 + + ntpdc/ntpdc.mdoc.in@1.114 +2 -2 + NTP_4_2_7P297 + + ntpq/invoke-ntpq.texi@1.285 +2 -2 + NTP_4_2_7P297 + + ntpq/ntpq-opts.c@1.300 +4 -4 + NTP_4_2_7P297 + + ntpq/ntpq-opts.h@1.300 +3 -3 + NTP_4_2_7P297 + + ntpq/ntpq.1ntpqman@1.114 +21 -21 + NTP_4_2_7P297 + + ntpq/ntpq.1ntpqmdoc@1.114 +2 -2 + NTP_4_2_7P297 + + ntpq/ntpq.man.in@1.114 +21 -21 + NTP_4_2_7P297 + + ntpq/ntpq.mdoc.in@1.114 +2 -2 + NTP_4_2_7P297 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.285 +2 -2 + NTP_4_2_7P297 + + ntpsnmpd/ntpsnmpd-opts.c@1.300 +4 -4 + NTP_4_2_7P297 + + ntpsnmpd/ntpsnmpd-opts.h@1.300 +3 -3 + NTP_4_2_7P297 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.114 +21 -21 + NTP_4_2_7P297 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.114 +2 -2 + NTP_4_2_7P297 + + ntpsnmpd/ntpsnmpd.man.in@1.114 +21 -21 + NTP_4_2_7P297 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.114 +2 -2 + NTP_4_2_7P297 + + packageinfo.sh@1.300 +1 -1 + NTP_4_2_7P297 + + scripts/invoke-ntp-wait.texi@1.103 +1 -1 + NTP_4_2_7P297 + + scripts/ntp-wait.1ntp-waitman@1.114 +13 -13 + NTP_4_2_7P297 + + scripts/ntp-wait.1ntp-waitmdoc@1.114 +2 -2 + NTP_4_2_7P297 + + scripts/ntp-wait.html@1.118 +1 -1 + NTP_4_2_7P297 + + scripts/ntp-wait.man.in@1.114 +13 -13 + NTP_4_2_7P297 + + scripts/ntp-wait.mdoc.in@1.114 +2 -2 + NTP_4_2_7P297 + + sntp/invoke-sntp.texi@1.281 +2 -2 + NTP_4_2_7P297 + + sntp/sntp-opts.c@1.296 +4 -4 + NTP_4_2_7P297 + + sntp/sntp-opts.h@1.296 +3 -3 + NTP_4_2_7P297 + + sntp/sntp.1sntpman@1.116 +68 -68 + NTP_4_2_7P297 + + sntp/sntp.1sntpmdoc@1.116 +2 -2 + NTP_4_2_7P297 + + sntp/sntp.html@1.296 +2 -2 + NTP_4_2_7P297 + + sntp/sntp.man.in@1.116 +68 -68 + NTP_4_2_7P297 + + sntp/sntp.mdoc.in@1.116 +2 -2 + NTP_4_2_7P297 + + util/invoke-ntp-keygen.texi@1.286 +2 -2 + NTP_4_2_7P297 + + util/ntp-keygen-opts.c@1.300 +4 -4 + NTP_4_2_7P297 + + util/ntp-keygen-opts.h@1.300 +3 -3 + NTP_4_2_7P297 + + util/ntp-keygen.1ntp-keygenman@1.114 +32 -32 + NTP_4_2_7P297 + + util/ntp-keygen.1ntp-keygenmdoc@1.114 +2 -2 + NTP_4_2_7P297 + + util/ntp-keygen.man.in@1.114 +32 -32 + NTP_4_2_7P297 + + util/ntp-keygen.mdoc.in@1.114 +2 -2 + NTP_4_2_7P297 + +ChangeSet@1.2792, 2012-08-31 14:18:39-04:00, stenn@deacon.udel.edu + Distribute ntp.conf.def and ntp.keys.def + + ChangeLog@1.1162 +1 -1 + Distribute ntp.conf.def and ntp.keys.def + + ntpd/Makefile.am@1.120 +1 -0 + Distribute ntp.conf.def and ntp.keys.def + +ChangeSet@1.2791, 2012-08-31 06:27:38+00:00, stenn@psp-fb1.ntp.org + Fix mdoc2man + + ChangeLog@1.1161 +1 -0 + Fix mdoc2man + + sntp/ag-tpl/mdoc2man@1.1 +308 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/ag-tpl/mdoc2man + + sntp/ag-tpl/mdoc2man@1.0 +0 -0 + +ChangeSet@1.2790, 2012-08-31 00:07:37-04:00, stenn@deacon.udel.edu + Distribute ntp.conf.def + + ChangeLog@1.1160 +1 -0 + Distribute ntp.conf.def + + ntpd/Makefile.am@1.119 +1 -0 + Distribute ntp.conf.def + +ChangeSet@1.2789, 2012-08-31 03:43:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P296 + TAG: NTP_4_2_7P296 + + ChangeLog@1.1159 +1 -0 + NTP_4_2_7P296 + + ntpd/invoke-ntpd.texi@1.285 +80 -5 + NTP_4_2_7P296 + + ntpd/ntp.conf.5man@1.2 +10 -2865 + NTP_4_2_7P296 + + ntpd/ntp.conf.5mdoc@1.2 +5 -2694 + NTP_4_2_7P296 + + ntpd/ntp.conf.man.in@1.2 +10 -2865 + NTP_4_2_7P296 + + ntpd/ntp.conf.mdoc.in@1.2 +5 -2694 + NTP_4_2_7P296 + + ntpd/ntp.keys.5man@1.2 +9 -109 + NTP_4_2_7P296 + + ntpd/ntp.keys.5mdoc@1.2 +4 -103 + NTP_4_2_7P296 + + ntpd/ntp.keys.man.in@1.2 +9 -109 + NTP_4_2_7P296 + + ntpd/ntp.keys.mdoc.in@1.2 +4 -103 + NTP_4_2_7P296 + + ntpd/ntpd-opts.c@1.303 +4 -4 + NTP_4_2_7P296 + + ntpd/ntpd-opts.h@1.303 +3 -3 + NTP_4_2_7P296 + + ntpd/ntpd.1ntpdman@1.114 +29 -573 + NTP_4_2_7P296 + + ntpd/ntpd.1ntpdmdoc@1.114 +5 -548 + NTP_4_2_7P296 + + ntpd/ntpd.man.in@1.114 +29 -573 + NTP_4_2_7P296 + + ntpd/ntpd.mdoc.in@1.114 +5 -548 + NTP_4_2_7P296 + + ntpdc/invoke-ntpdc.texi@1.282 +56 -5 + NTP_4_2_7P296 + + ntpdc/ntpdc-opts.c@1.297 +4 -4 + NTP_4_2_7P296 + + ntpdc/ntpdc-opts.h@1.297 +3 -3 + NTP_4_2_7P296 + + ntpdc/ntpdc.1ntpdcman@1.113 +22 -723 + NTP_4_2_7P296 + + ntpdc/ntpdc.1ntpdcmdoc@1.113 +4 -660 + NTP_4_2_7P296 + + ntpdc/ntpdc.html@1.125 +150 -119 + NTP_4_2_7P296 + + ntpdc/ntpdc.man.in@1.113 +22 -723 + NTP_4_2_7P296 + + ntpdc/ntpdc.mdoc.in@1.113 +4 -660 + NTP_4_2_7P296 + + ntpq/invoke-ntpq.texi@1.284 +47 -5 + NTP_4_2_7P296 + + ntpq/ntpq-opts.c@1.299 +4 -4 + NTP_4_2_7P296 + + ntpq/ntpq-opts.h@1.299 +3 -3 + NTP_4_2_7P296 + + ntpq/ntpq.1ntpqman@1.113 +21 -279 + NTP_4_2_7P296 + + ntpq/ntpq.1ntpqmdoc@1.113 +3 -246 + NTP_4_2_7P296 + + ntpq/ntpq.man.in@1.113 +21 -279 + NTP_4_2_7P296 + + ntpq/ntpq.mdoc.in@1.113 +3 -246 + NTP_4_2_7P296 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.284 +31 -5 + NTP_4_2_7P296 + + ntpsnmpd/ntpsnmpd-opts.c@1.299 +4 -4 + NTP_4_2_7P296 + + ntpsnmpd/ntpsnmpd-opts.h@1.299 +3 -3 + NTP_4_2_7P296 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.113 +21 -22 + NTP_4_2_7P296 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.113 +3 -4 + NTP_4_2_7P296 + + ntpsnmpd/ntpsnmpd.man.in@1.113 +21 -22 + NTP_4_2_7P296 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.113 +3 -4 + NTP_4_2_7P296 + + packageinfo.sh@1.299 +1 -1 + NTP_4_2_7P296 + + scripts/invoke-ntp-wait.texi@1.102 +19 -5 + NTP_4_2_7P296 + + scripts/ntp-wait.1ntp-waitman@1.113 +13 -29 + NTP_4_2_7P296 + + scripts/ntp-wait.1ntp-waitmdoc@1.113 +3 -19 + NTP_4_2_7P296 + + scripts/ntp-wait.html@1.117 +54 -61 + NTP_4_2_7P296 + + scripts/ntp-wait.man.in@1.113 +13 -29 + NTP_4_2_7P296 + + scripts/ntp-wait.mdoc.in@1.113 +3 -19 + NTP_4_2_7P296 + + sntp/invoke-sntp.texi@1.280 +7 -5 + NTP_4_2_7P296 + + sntp/sntp-opts.c@1.295 +4 -4 + NTP_4_2_7P296 + + sntp/sntp-opts.h@1.295 +3 -3 + NTP_4_2_7P296 + + sntp/sntp.1sntpman@1.115 +69 -131 + NTP_4_2_7P296 + + sntp/sntp.1sntpmdoc@1.115 +4 -66 + NTP_4_2_7P296 + + sntp/sntp.html@1.295 +99 -123 + NTP_4_2_7P296 + + sntp/sntp.man.in@1.115 +69 -131 + NTP_4_2_7P296 + + sntp/sntp.mdoc.in@1.115 +4 -66 + NTP_4_2_7P296 + + util/invoke-ntp-keygen.texi@1.285 +52 -5 + NTP_4_2_7P296 + + util/ntp-keygen-opts.c@1.299 +4 -4 + NTP_4_2_7P296 + + util/ntp-keygen-opts.h@1.299 +3 -3 + NTP_4_2_7P296 + + util/ntp-keygen.1ntp-keygenman@1.113 +34 -750 + NTP_4_2_7P296 + + util/ntp-keygen.1ntp-keygenmdoc@1.113 +5 -707 + NTP_4_2_7P296 + + util/ntp-keygen.man.in@1.113 +34 -750 + NTP_4_2_7P296 + + util/ntp-keygen.mdoc.in@1.113 +5 -707 + NTP_4_2_7P296 + +ChangeSet@1.2788, 2012-08-30 22:01:12-04:00, stenn@deacon.udel.edu + Potential bugfix for agtexi-cmd.tpl + + ChangeLog@1.1158 +1 -0 + Potential bugfix for agtexi-cmd.tpl + + sntp/ag-tpl/agtexi-cmd.tpl@1.1 +884 -0 + BitKeeper file /deacon/backroom/ntp-dev-autogen/sntp/ag-tpl/agtexi-cmd.tpl + + sntp/ag-tpl/agtexi-cmd.tpl@1.0 +0 -0 + +ChangeSet@1.2787, 2012-08-30 21:48:02-04:00, stenn@deacon.udel.edu + Begin support for autogen maintaining ntp.conf and ntp.keys docs + + .point-changed-filelist@1.14 +15 -7 + Begin support for autogen maintaining ntp.conf and ntp.keys docs + +ChangeSet@1.2786, 2012-08-30 20:44:10-04:00, stenn@psp-deb1.ntp.org + Begin support for autogen maintaining ntp.conf and ntp.keys docs + + ChangeLog@1.1157 +1 -0 + Begin support for autogen maintaining ntp.conf and ntp.keys docs + + ntpd/ntp.conf.5man@1.1 +2915 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.conf.5man + + ntpd/ntp.conf.5man@1.0 +0 -0 + + ntpd/ntp.conf.5mdoc@1.1 +2749 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.conf.5mdoc + + ntpd/ntp.conf.5mdoc@1.0 +0 -0 + + ntpd/ntp.conf.def@1.1 +2746 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.conf.def + + ntpd/ntp.conf.def@1.0 +0 -0 + + ntpd/ntp.conf.man.in@1.1 +2915 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.conf.man.in + + ntpd/ntp.conf.man.in@1.0 +0 -0 + + ntpd/ntp.conf.mdoc.in@1.1 +2749 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.conf.mdoc.in + + ntpd/ntp.conf.mdoc.in@1.0 +0 -0 + + ntpd/ntp.keys.5man@1.1 +160 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.keys.5man + + ntpd/ntp.keys.5man@1.0 +0 -0 + + ntpd/ntp.keys.5mdoc@1.1 +159 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.keys.5mdoc + + ntpd/ntp.keys.5mdoc@1.0 +0 -0 + + ntpd/ntp.keys.man.in@1.1 +160 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.keys.man.in + + ntpd/ntp.keys.man.in@1.0 +0 -0 + + ntpd/ntp.keys.mdoc.in@1.1 +159 -0 + BitKeeper file /home/stenn/ntp-dev-autogen/ntpd/ntp.keys.mdoc.in + + ntpd/ntp.keys.mdoc.in@1.0 +0 -0 + +ChangeSet@1.2785, 2012-08-12 04:33:15+00:00, stenn@psp-fb1.ntp.org + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ChangeLog@1.1156 +1 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/invoke-ntpd.texi@1.284 +360 -132 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpd-opts.c@1.302 +309 -261 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpd-opts.h@1.302 +12 -5 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpd.1ntpdman@1.113 +43 -43 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpd.1ntpdmdoc@1.113 +13 -9 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpd.man.in@1.113 +43 -43 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpd.mdoc.in@1.113 +13 -9 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpdsim-opts.c@1.20 +112 -53 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpd/ntpdsim-opts.h@1.20 +24 -11 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/invoke-ntpdc.texi@1.281 +421 -72 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/ntpdc-opts.c@1.296 +172 -124 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/ntpdc-opts.h@1.296 +13 -5 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/ntpdc.1ntpdcman@1.112 +28 -21 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/ntpdc.1ntpdcmdoc@1.112 +13 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/ntpdc.html@1.124 +1108 -189 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/ntpdc.man.in@1.112 +28 -21 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpdc/ntpdc.mdoc.in@1.112 +13 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpq/invoke-ntpq.texi@1.283 +285 -237 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpq/ntpq-opts.c@1.298 +165 -119 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpq/ntpq-opts.h@1.298 +13 -5 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpq/ntpq.1ntpqman@1.112 +22 -15 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpq/ntpq.1ntpqmdoc@1.112 +15 -8 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpq/ntpq.man.in@1.112 +22 -15 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpq/ntpq.mdoc.in@1.112 +15 -8 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.283 +5 -29 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpsnmpd/ntpsnmpd-opts.c@1.298 +125 -81 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpsnmpd/ntpsnmpd-opts.h@1.298 +13 -5 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.112 +10 -3 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.112 +13 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpsnmpd/ntpsnmpd.man.in@1.112 +10 -3 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.112 +13 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + scripts/invoke-ntp-wait.texi@1.101 +21 -24 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + scripts/ntp-wait.1ntp-waitman@1.112 +6 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + scripts/ntp-wait.1ntp-waitmdoc@1.112 +6 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + scripts/ntp-wait.html@1.116 +162 -37 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + scripts/ntp-wait.man.in@1.112 +6 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + scripts/ntp-wait.mdoc.in@1.112 +6 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/include/autogen-version.def@1.12 +1 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/invoke-sntp.texi@1.279 +67 -59 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/Makefile.am@1.15 +4 -4 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/ag-char-map.h@1.18 +322 -308 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/alias.c@1.2 +2 -2 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/ao-strs.c@1.4 +52 -52 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/ao-strs.h@1.3 +206 -207 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/autoopts/options.h@1.17 +8 -7 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/autoopts/usage-txt.h@1.17 +185 -183 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/boolean.c@1.10 +4 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/compat/compat.h@1.10 +4 -2 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/compat/pathfind.c@1.8 +2 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/configfile.c@1.15 +7 -3 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/enum.c@1.4 +4 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/env.c@1.4 +3 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/find.c@1.4 +31 -18 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/genshell.c@1.18 +3 -3 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/genshell.h@1.18 +9 -3 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/load.c@1.13 +67 -63 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/m4/libopts.m4@1.21 +19 -19 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/makeshell.c@1.12 +96 -61 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/proto.h@1.18 +6 -6 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/reset.c@1.11 +4 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/stack.c@1.10 +7 -2 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/time.c@1.10 +7 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/value-type.h@1.18 +1 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/version.c@1.11 +54 -51 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/libopts/xat-attribute.h@1.18 +1 -1 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/sntp-opts.c@1.294 +265 -195 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/sntp-opts.h@1.294 +13 -5 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/sntp.1sntpman@1.114 +39 -32 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/sntp.1sntpmdoc@1.114 +48 -35 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/sntp.html@1.294 +402 -252 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/sntp.man.in@1.114 +39 -32 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + sntp/sntp.mdoc.in@1.114 +48 -35 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + util/invoke-ntp-keygen.texi@1.284 +784 -497 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + util/ntp-keygen-opts.c@1.298 +238 -188 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + util/ntp-keygen-opts.h@1.298 +13 -5 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + util/ntp-keygen.1ntp-keygenman@1.112 +43 -36 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + util/ntp-keygen.1ntp-keygenmdoc@1.112 +27 -19 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + util/ntp-keygen.man.in@1.112 +43 -36 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + + util/ntp-keygen.mdoc.in@1.112 +27 -19 + Upgrade to autogen-5.16.2 and libopts-36.5.11 + +ChangeSet@1.2773.1.76, 2012-08-11 11:33:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P295 + TAG: NTP_4_2_7P295 + + ChangeLog@1.1146.1.67 +1 -0 + NTP_4_2_7P295 + + ntpd/ntpd-opts.c@1.301 +4 -4 + NTP_4_2_7P295 + + ntpd/ntpd-opts.h@1.301 +3 -3 + NTP_4_2_7P295 + + ntpd/ntpd-opts.texi@1.275.5.6 +2 -2 + NTP_4_2_7P295 + + ntpd/ntpd.1ntpdman@1.112 +2 -2 + NTP_4_2_7P295 + + ntpd/ntpd.1ntpdmdoc@1.112 +2 -2 + NTP_4_2_7P295 + + ntpd/ntpd.man.in@1.112 +2 -2 + NTP_4_2_7P295 + + ntpd/ntpd.mdoc.in@1.112 +2 -2 + NTP_4_2_7P295 + + ntpdc/ntpdc-opts.c@1.295 +4 -4 + NTP_4_2_7P295 + + ntpdc/ntpdc-opts.h@1.295 +3 -3 + NTP_4_2_7P295 + + ntpdc/ntpdc-opts.texi@1.272.5.5 +2 -2 + NTP_4_2_7P295 + + ntpdc/ntpdc.1ntpdcman@1.111 +2 -2 + NTP_4_2_7P295 + + ntpdc/ntpdc.1ntpdcmdoc@1.111 +2 -2 + NTP_4_2_7P295 + + ntpdc/ntpdc.html@1.123 +2 -2 + NTP_4_2_7P295 + + ntpdc/ntpdc.man.in@1.111 +2 -2 + NTP_4_2_7P295 + + ntpdc/ntpdc.mdoc.in@1.111 +2 -2 + NTP_4_2_7P295 + + ntpq/ntpq-opts.c@1.297 +4 -4 + NTP_4_2_7P295 + + ntpq/ntpq-opts.h@1.297 +3 -3 + NTP_4_2_7P295 + + ntpq/ntpq-opts.texi@1.274.5.5 +2 -2 + NTP_4_2_7P295 + + ntpq/ntpq.1ntpqman@1.111 +2 -2 + NTP_4_2_7P295 + + ntpq/ntpq.1ntpqmdoc@1.111 +2 -2 + NTP_4_2_7P295 + + ntpq/ntpq.man.in@1.111 +2 -2 + NTP_4_2_7P295 + + ntpq/ntpq.mdoc.in@1.111 +2 -2 + NTP_4_2_7P295 + + ntpsnmpd/ntpsnmpd-opts.c@1.297 +4 -4 + NTP_4_2_7P295 + + ntpsnmpd/ntpsnmpd-opts.h@1.297 +3 -3 + NTP_4_2_7P295 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.5.5 +2 -2 + NTP_4_2_7P295 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.111 +2 -2 + NTP_4_2_7P295 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.111 +2 -2 + NTP_4_2_7P295 + + ntpsnmpd/ntpsnmpd.man.in@1.111 +2 -2 + NTP_4_2_7P295 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.111 +2 -2 + NTP_4_2_7P295 + + packageinfo.sh@1.298 +1 -1 + NTP_4_2_7P295 + + scripts/ntp-wait-opts.texi@1.92.5.5 +14 -2 + NTP_4_2_7P295 + + scripts/ntp-wait.1ntp-waitman@1.111 +2 -2 + NTP_4_2_7P295 + + scripts/ntp-wait.1ntp-waitmdoc@1.111 +2 -2 + NTP_4_2_7P295 + + scripts/ntp-wait.html@1.115 +14 -2 + NTP_4_2_7P295 + + scripts/ntp-wait.man.in@1.111 +2 -2 + NTP_4_2_7P295 + + scripts/ntp-wait.mdoc.in@1.111 +2 -2 + NTP_4_2_7P295 + + sntp/sntp-opts.c@1.293 +4 -4 + NTP_4_2_7P295 + + sntp/sntp-opts.h@1.293 +3 -3 + NTP_4_2_7P295 + + sntp/sntp-opts.texi@1.270.5.5 +2 -2 + NTP_4_2_7P295 + + sntp/sntp.1sntpman@1.113 +2 -2 + NTP_4_2_7P295 + + sntp/sntp.1sntpmdoc@1.113 +2 -2 + NTP_4_2_7P295 + + sntp/sntp.html@1.293 +2 -2 + NTP_4_2_7P295 + + sntp/sntp.man.in@1.113 +2 -2 + NTP_4_2_7P295 + + sntp/sntp.mdoc.in@1.113 +2 -2 + NTP_4_2_7P295 + + util/ntp-keygen-opts.c@1.297 +4 -4 + NTP_4_2_7P295 + + util/ntp-keygen-opts.h@1.297 +3 -3 + NTP_4_2_7P295 + + util/ntp-keygen-opts.texi@1.275.5.5 +2 -2 + NTP_4_2_7P295 + + util/ntp-keygen.1ntp-keygenman@1.111 +2 -2 + NTP_4_2_7P295 + + util/ntp-keygen.1ntp-keygenmdoc@1.111 +2 -2 + NTP_4_2_7P295 + + util/ntp-keygen.man.in@1.111 +2 -2 + NTP_4_2_7P295 + + util/ntp-keygen.mdoc.in@1.111 +2 -2 + NTP_4_2_7P295 + +ChangeSet@1.2773.1.75, 2012-08-11 04:28:13-04:00, stenn@psp-deb1.ntp.org + Look for syslog's facilitynames[] + + ChangeLog@1.1146.1.66 +1 -0 + Look for syslog's facilitynames[] + + configure.ac@1.550 +2 -0 + Look for syslog's facilitynames[] + + sntp/configure.ac@1.71 +1 -0 + Look for syslog's facilitynames[] + + sntp/m4/ntp_facilitynames.m4@1.1 +24 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/m4/ntp_facilitynames.m4 + + sntp/m4/ntp_facilitynames.m4@1.0 +0 -0 + +ChangeSet@1.2773.1.74, 2012-08-08 11:38:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P294 + TAG: NTP_4_2_7P294 + + ChangeLog@1.1146.1.65 +1 -0 + NTP_4_2_7P294 + + ntpd/ntpd-opts.c@1.300 +4 -4 + NTP_4_2_7P294 + + ntpd/ntpd-opts.h@1.300 +3 -3 + NTP_4_2_7P294 + + ntpd/ntpd-opts.texi@1.275.5.5 +2 -2 + NTP_4_2_7P294 + + ntpd/ntpd.1ntpdman@1.111 +2 -2 + NTP_4_2_7P294 + + ntpd/ntpd.1ntpdmdoc@1.111 +2 -2 + NTP_4_2_7P294 + + ntpd/ntpd.man.in@1.111 +2 -2 + NTP_4_2_7P294 + + ntpd/ntpd.mdoc.in@1.111 +2 -2 + NTP_4_2_7P294 + + ntpdc/ntpdc-opts.c@1.294 +4 -4 + NTP_4_2_7P294 + + ntpdc/ntpdc-opts.h@1.294 +3 -3 + NTP_4_2_7P294 + + ntpdc/ntpdc-opts.texi@1.272.5.4 +2 -2 + NTP_4_2_7P294 + + ntpdc/ntpdc.1ntpdcman@1.110 +2 -2 + NTP_4_2_7P294 + + ntpdc/ntpdc.1ntpdcmdoc@1.110 +2 -2 + NTP_4_2_7P294 + + ntpdc/ntpdc.html@1.122 +2 -2 + NTP_4_2_7P294 + + ntpdc/ntpdc.man.in@1.110 +2 -2 + NTP_4_2_7P294 + + ntpdc/ntpdc.mdoc.in@1.110 +2 -2 + NTP_4_2_7P294 + + ntpq/ntpq-opts.c@1.296 +4 -4 + NTP_4_2_7P294 + + ntpq/ntpq-opts.h@1.296 +3 -3 + NTP_4_2_7P294 + + ntpq/ntpq-opts.texi@1.274.5.4 +2 -2 + NTP_4_2_7P294 + + ntpq/ntpq.1ntpqman@1.110 +2 -2 + NTP_4_2_7P294 + + ntpq/ntpq.1ntpqmdoc@1.110 +2 -2 + NTP_4_2_7P294 + + ntpq/ntpq.man.in@1.110 +2 -2 + NTP_4_2_7P294 + + ntpq/ntpq.mdoc.in@1.110 +2 -2 + NTP_4_2_7P294 + + ntpsnmpd/ntpsnmpd-opts.c@1.296 +4 -4 + NTP_4_2_7P294 + + ntpsnmpd/ntpsnmpd-opts.h@1.296 +3 -3 + NTP_4_2_7P294 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.5.4 +2 -2 + NTP_4_2_7P294 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.110 +2 -2 + NTP_4_2_7P294 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.110 +2 -2 + NTP_4_2_7P294 + + ntpsnmpd/ntpsnmpd.man.in@1.110 +2 -2 + NTP_4_2_7P294 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.110 +2 -2 + NTP_4_2_7P294 + + packageinfo.sh@1.297 +1 -1 + NTP_4_2_7P294 + + scripts/ntp-wait-opts.texi@1.92.5.4 +1 -1 + NTP_4_2_7P294 + + scripts/ntp-wait.1ntp-waitman@1.110 +2 -2 + NTP_4_2_7P294 + + scripts/ntp-wait.1ntp-waitmdoc@1.110 +2 -2 + NTP_4_2_7P294 + + scripts/ntp-wait.html@1.114 +1 -1 + NTP_4_2_7P294 + + scripts/ntp-wait.man.in@1.110 +2 -2 + NTP_4_2_7P294 + + scripts/ntp-wait.mdoc.in@1.110 +2 -2 + NTP_4_2_7P294 + + sntp/sntp-opts.c@1.292 +4 -4 + NTP_4_2_7P294 + + sntp/sntp-opts.h@1.292 +3 -3 + NTP_4_2_7P294 + + sntp/sntp-opts.texi@1.270.5.4 +2 -2 + NTP_4_2_7P294 + + sntp/sntp.1sntpman@1.112 +2 -2 + NTP_4_2_7P294 + + sntp/sntp.1sntpmdoc@1.112 +2 -2 + NTP_4_2_7P294 + + sntp/sntp.html@1.292 +2 -2 + NTP_4_2_7P294 + + sntp/sntp.man.in@1.112 +2 -2 + NTP_4_2_7P294 + + sntp/sntp.mdoc.in@1.112 +2 -2 + NTP_4_2_7P294 + + util/ntp-keygen-opts.c@1.296 +4 -4 + NTP_4_2_7P294 + + util/ntp-keygen-opts.h@1.296 +3 -3 + NTP_4_2_7P294 + + util/ntp-keygen-opts.texi@1.275.5.4 +2 -2 + NTP_4_2_7P294 + + util/ntp-keygen.1ntp-keygenman@1.110 +2 -2 + NTP_4_2_7P294 + + util/ntp-keygen.1ntp-keygenmdoc@1.110 +2 -2 + NTP_4_2_7P294 + + util/ntp-keygen.man.in@1.110 +2 -2 + NTP_4_2_7P294 + + util/ntp-keygen.mdoc.in@1.110 +2 -2 + NTP_4_2_7P294 + +ChangeSet@1.2773.4.5, 2012-08-06 04:22:39+00:00, davehart@dlh-7551.ad.hartbrothers.com + Attempt to resolve strict-aliasing violation in refclock_tsyncpci.c. + Force prior config.cache files to be flushed due to [Bug 2242] fix + invalidating getifaddrs() cached result. + + ChangeLog@1.1146.4.4 +1 -0 + Attempt to resolve strict-aliasing violation in refclock_tsyncpci.c. + + configure.ac@1.549 +1 -1 + Force prior config.cache files to be flushed due to [Bug 2242] fix + invalidating getifaddrs() cached result. + + ntpd/refclock_tsyncpci.c@1.7 +5 -3 + Attempt to resolve strict-aliasing violation in refclock_tsyncpci.c. + + sntp/configure.ac@1.70 +1 -1 + Force prior config.cache files to be flushed due to [Bug 2242] fix + invalidating getifaddrs() cached result. + +ChangeSet@1.2773.4.4, 2012-08-05 21:15:00+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2242] configure fails to detect getifaddrs function on Solaris. + + ChangeLog@1.1146.4.3 +1 -0 + [Bug 2242] configure fails to detect getifaddrs function on Solaris. + + sntp/m4/ntp_ipv6.m4@1.7 +7 -3 + [Bug 2242] configure fails to detect getifaddrs function on Solaris. + +ChangeSet@1.2773.4.3, 2012-08-05 21:04:38+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2252] palisade: formats nanosecs to a 6-char field. + + ChangeLog@1.1146.4.2 +1 -0 + [Bug 2252] palisade: formats nanosecs to a 6-char field. + + ntpd/refclock_palisade.c@1.38.1.1 +5 -5 + [Bug 2252] palisade: formats nanosecs to a 6-char field. + +ChangeSet@1.2773.4.2, 2012-08-05 20:48:27+00:00, davehart@dlh-7551.ad.hartbrothers.com + Remove unneeded \ line continuation in ntp_config.c if condition. + Use INSIST() instead of equivalent NTP_INSIST in a few places. + + ntpd/ntp_config.c@1.301 +4 -4 + Remove unneeded \ line continuation in ntp_config.c if condition. + Use INSIST() instead of equivalent NTP_INSIST in a few places. + +ChangeSet@1.2773.4.1, 2012-08-05 19:09:38+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2249] Bad operator for 'test' in 'make check' of libevent. + + ChangeLog@1.1146.4.1 +1 -0 + [Bug 2249] Bad operator for 'test' in 'make check' of libevent. + + sntp/libevent/test/test.sh@1.6 +1 -1 + [Bug 2249] Bad operator for 'test' in 'make check' of libevent. + +ChangeSet@1.2773.1.72, 2012-08-05 05:03:59-04:00, stenn@psp-deb1.ntp.org + Fix && -> & typo in refclock_palisade.c debug statements + + ChangeLog@1.1146.1.63 +1 -0 + Fix && -> & typo in refclock_palisade.c debug statements + + ntpd/refclock_palisade.c@1.39 +5 -5 + Fix && -> & typo in refclock_palisade.c debug statements + +ChangeSet@1.2773.1.71, 2012-08-04 11:34:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P293 + TAG: NTP_4_2_7P293 + + ChangeLog@1.1146.1.62 +1 -0 + NTP_4_2_7P293 + + ntpd/ntpd-opts.c@1.299 +4 -4 + NTP_4_2_7P293 + + ntpd/ntpd-opts.h@1.299 +3 -3 + NTP_4_2_7P293 + + ntpd/ntpd-opts.texi@1.275.5.4 +2 -2 + NTP_4_2_7P293 + + ntpd/ntpd.1ntpdman@1.110 +2 -2 + NTP_4_2_7P293 + + ntpd/ntpd.1ntpdmdoc@1.110 +2 -2 + NTP_4_2_7P293 + + ntpd/ntpd.man.in@1.110 +2 -2 + NTP_4_2_7P293 + + ntpd/ntpd.mdoc.in@1.110 +2 -2 + NTP_4_2_7P293 + + ntpdc/ntpdc-opts.c@1.293 +4 -4 + NTP_4_2_7P293 + + ntpdc/ntpdc-opts.h@1.293 +3 -3 + NTP_4_2_7P293 + + ntpdc/ntpdc-opts.texi@1.272.5.3 +2 -2 + NTP_4_2_7P293 + + ntpdc/ntpdc.1ntpdcman@1.109 +2 -2 + NTP_4_2_7P293 + + ntpdc/ntpdc.1ntpdcmdoc@1.109 +2 -2 + NTP_4_2_7P293 + + ntpdc/ntpdc.html@1.121 +2 -2 + NTP_4_2_7P293 + + ntpdc/ntpdc.man.in@1.109 +2 -2 + NTP_4_2_7P293 + + ntpdc/ntpdc.mdoc.in@1.109 +2 -2 + NTP_4_2_7P293 + + ntpq/ntpq-opts.c@1.295 +4 -4 + NTP_4_2_7P293 + + ntpq/ntpq-opts.h@1.295 +3 -3 + NTP_4_2_7P293 + + ntpq/ntpq-opts.texi@1.274.5.3 +2 -2 + NTP_4_2_7P293 + + ntpq/ntpq.1ntpqman@1.109 +2 -2 + NTP_4_2_7P293 + + ntpq/ntpq.1ntpqmdoc@1.109 +2 -2 + NTP_4_2_7P293 + + ntpq/ntpq.man.in@1.109 +2 -2 + NTP_4_2_7P293 + + ntpq/ntpq.mdoc.in@1.109 +2 -2 + NTP_4_2_7P293 + + ntpsnmpd/ntpsnmpd-opts.c@1.295 +4 -4 + NTP_4_2_7P293 + + ntpsnmpd/ntpsnmpd-opts.h@1.295 +3 -3 + NTP_4_2_7P293 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.5.3 +2 -2 + NTP_4_2_7P293 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.109 +2 -2 + NTP_4_2_7P293 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.109 +2 -2 + NTP_4_2_7P293 + + ntpsnmpd/ntpsnmpd.man.in@1.109 +2 -2 + NTP_4_2_7P293 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.109 +2 -2 + NTP_4_2_7P293 + + packageinfo.sh@1.296 +1 -1 + NTP_4_2_7P293 + + scripts/ntp-wait-opts.texi@1.92.5.3 +1 -1 + NTP_4_2_7P293 + + scripts/ntp-wait.1ntp-waitman@1.109 +2 -2 + NTP_4_2_7P293 + + scripts/ntp-wait.1ntp-waitmdoc@1.109 +2 -2 + NTP_4_2_7P293 + + scripts/ntp-wait.html@1.113 +1 -1 + NTP_4_2_7P293 + + scripts/ntp-wait.man.in@1.109 +2 -2 + NTP_4_2_7P293 + + scripts/ntp-wait.mdoc.in@1.109 +2 -2 + NTP_4_2_7P293 + + sntp/sntp-opts.c@1.291 +4 -4 + NTP_4_2_7P293 + + sntp/sntp-opts.h@1.291 +3 -3 + NTP_4_2_7P293 + + sntp/sntp-opts.texi@1.270.5.3 +2 -2 + NTP_4_2_7P293 + + sntp/sntp.1sntpman@1.111 +2 -2 + NTP_4_2_7P293 + + sntp/sntp.1sntpmdoc@1.111 +2 -2 + NTP_4_2_7P293 + + sntp/sntp.html@1.291 +2 -2 + NTP_4_2_7P293 + + sntp/sntp.man.in@1.111 +2 -2 + NTP_4_2_7P293 + + sntp/sntp.mdoc.in@1.111 +2 -2 + NTP_4_2_7P293 + + util/ntp-keygen-opts.c@1.295 +4 -4 + NTP_4_2_7P293 + + util/ntp-keygen-opts.h@1.295 +3 -3 + NTP_4_2_7P293 + + util/ntp-keygen-opts.texi@1.275.5.3 +2 -2 + NTP_4_2_7P293 + + util/ntp-keygen.1ntp-keygenman@1.109 +2 -2 + NTP_4_2_7P293 + + util/ntp-keygen.1ntp-keygenmdoc@1.109 +2 -2 + NTP_4_2_7P293 + + util/ntp-keygen.man.in@1.109 +2 -2 + NTP_4_2_7P293 + + util/ntp-keygen.mdoc.in@1.109 +2 -2 + NTP_4_2_7P293 + +ChangeSet@1.2773.1.70, 2012-08-03 23:15:30-04:00, stenn@psp-deb1.ntp.org + Cleanup kclk_sel240x.o rules in libparse/Makefile.am + + ChangeLog@1.1146.1.61 +1 -0 + Cleanup kclk_sel240x.o rules in libparse/Makefile.am + + libparse/Makefile.am@1.30 +1 -4 + Cleanup kclk_sel240x.o rules in libparse/Makefile.am + +ChangeSet@1.2773.1.69, 2012-08-03 23:11:04-04:00, stenn@psp-deb1.ntp.org + Documentation cleanup from Mike T. + + ChangeLog@1.1146.1.60 +1 -0 + Documentation cleanup from Mike T. + + html/authentic.html@1.10 +2 -2 + Documentation cleanup from Mike T. + + html/decode.html@1.19 +1 -1 + Documentation cleanup from Mike T. + + html/drivers/driver1.html@1.19 +1 -1 + Documentation cleanup from Mike T. + + html/miscopt.html@1.69 +2 -2 + Documentation cleanup from Mike T. + +ChangeSet@1.2773.1.68, 2012-08-03 02:51:04-04:00, stenn@psp-deb1.ntp.org + [Bug 2247] (more) Get rid of the TRAK refclock - deprecated since 2006. + + BitKeeper/deleted/55/driver2.htm~3aed0663@1.14 +0 -0 + Delete: html/drivers/driver2.html + + ChangeLog@1.1146.1.59 +1 -0 + [Bug 2247] (more) Get rid of the TRAK refclock - deprecated since 2006. + + html/refclock.html@1.36 +0 -1 + [Bug 2247] (more) Get rid of the TRAK refclock - deprecated since 2006. + + ntpd/ntp_control.c@1.182 +1 -1 + [Bug 2247] (more) Get rid of the TRAK refclock - deprecated since 2006. + + ntpd/refclock_conf.c@1.33 +0 -6 + [Bug 2247] (more) Get rid of the TRAK refclock - deprecated since 2006. + +ChangeSet@1.2773.1.67, 2012-08-02 11:34:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P292 + TAG: NTP_4_2_7P292 + + ChangeLog@1.1146.1.58 +1 -0 + NTP_4_2_7P292 + + ntpd/ntpd-opts.c@1.298 +4 -4 + NTP_4_2_7P292 + + ntpd/ntpd-opts.h@1.298 +3 -3 + NTP_4_2_7P292 + + ntpd/ntpd-opts.texi@1.275.5.3 +2 -2 + NTP_4_2_7P292 + + ntpd/ntpd.1ntpdman@1.109 +2 -2 + NTP_4_2_7P292 + + ntpd/ntpd.1ntpdmdoc@1.109 +2 -2 + NTP_4_2_7P292 + + ntpd/ntpd.man.in@1.109 +2 -2 + NTP_4_2_7P292 + + ntpd/ntpd.mdoc.in@1.109 +2 -2 + NTP_4_2_7P292 + + ntpdc/ntpdc-opts.c@1.292 +4 -4 + NTP_4_2_7P292 + + ntpdc/ntpdc-opts.h@1.292 +3 -3 + NTP_4_2_7P292 + + ntpdc/ntpdc-opts.texi@1.272.5.2 +2 -2 + NTP_4_2_7P292 + + ntpdc/ntpdc.1ntpdcman@1.108 +2 -2 + NTP_4_2_7P292 + + ntpdc/ntpdc.1ntpdcmdoc@1.108 +2 -2 + NTP_4_2_7P292 + + ntpdc/ntpdc.html@1.120 +2 -2 + NTP_4_2_7P292 + + ntpdc/ntpdc.man.in@1.108 +2 -2 + NTP_4_2_7P292 + + ntpdc/ntpdc.mdoc.in@1.108 +2 -2 + NTP_4_2_7P292 + + ntpq/ntpq-opts.c@1.294 +4 -4 + NTP_4_2_7P292 + + ntpq/ntpq-opts.h@1.294 +3 -3 + NTP_4_2_7P292 + + ntpq/ntpq-opts.texi@1.274.5.2 +2 -2 + NTP_4_2_7P292 + + ntpq/ntpq.1ntpqman@1.108 +2 -2 + NTP_4_2_7P292 + + ntpq/ntpq.1ntpqmdoc@1.108 +2 -2 + NTP_4_2_7P292 + + ntpq/ntpq.man.in@1.108 +2 -2 + NTP_4_2_7P292 + + ntpq/ntpq.mdoc.in@1.108 +2 -2 + NTP_4_2_7P292 + + ntpsnmpd/ntpsnmpd-opts.c@1.294 +4 -4 + NTP_4_2_7P292 + + ntpsnmpd/ntpsnmpd-opts.h@1.294 +3 -3 + NTP_4_2_7P292 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.5.2 +2 -2 + NTP_4_2_7P292 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.108 +2 -2 + NTP_4_2_7P292 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.108 +2 -2 + NTP_4_2_7P292 + + ntpsnmpd/ntpsnmpd.man.in@1.108 +2 -2 + NTP_4_2_7P292 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.108 +2 -2 + NTP_4_2_7P292 + + packageinfo.sh@1.295 +1 -1 + NTP_4_2_7P292 + + scripts/ntp-wait-opts.texi@1.92.5.2 +1 -1 + NTP_4_2_7P292 + + scripts/ntp-wait.1ntp-waitman@1.108 +2 -2 + NTP_4_2_7P292 + + scripts/ntp-wait.1ntp-waitmdoc@1.108 +2 -2 + NTP_4_2_7P292 + + scripts/ntp-wait.html@1.112 +1 -1 + NTP_4_2_7P292 + + scripts/ntp-wait.man.in@1.108 +2 -2 + NTP_4_2_7P292 + + scripts/ntp-wait.mdoc.in@1.108 +2 -2 + NTP_4_2_7P292 + + sntp/sntp-opts.c@1.290 +4 -4 + NTP_4_2_7P292 + + sntp/sntp-opts.h@1.290 +3 -3 + NTP_4_2_7P292 + + sntp/sntp-opts.texi@1.270.5.2 +2 -2 + NTP_4_2_7P292 + + sntp/sntp.1sntpman@1.110 +2 -2 + NTP_4_2_7P292 + + sntp/sntp.1sntpmdoc@1.110 +2 -2 + NTP_4_2_7P292 + + sntp/sntp.html@1.290 +2 -2 + NTP_4_2_7P292 + + sntp/sntp.man.in@1.110 +2 -2 + NTP_4_2_7P292 + + sntp/sntp.mdoc.in@1.110 +2 -2 + NTP_4_2_7P292 + + util/ntp-keygen-opts.c@1.294 +4 -4 + NTP_4_2_7P292 + + util/ntp-keygen-opts.h@1.294 +3 -3 + NTP_4_2_7P292 + + util/ntp-keygen-opts.texi@1.275.5.2 +2 -2 + NTP_4_2_7P292 + + util/ntp-keygen.1ntp-keygenman@1.108 +2 -2 + NTP_4_2_7P292 + + util/ntp-keygen.1ntp-keygenmdoc@1.108 +2 -2 + NTP_4_2_7P292 + + util/ntp-keygen.man.in@1.108 +2 -2 + NTP_4_2_7P292 + + util/ntp-keygen.mdoc.in@1.108 +2 -2 + NTP_4_2_7P292 + +ChangeSet@1.2773.1.66, 2012-08-02 06:48:06-04:00, stenn@deacon.udel.edu + [Bug 1545] Note why we are logging the Version string + + ChangeLog@1.1146.1.57 +1 -0 + [Bug 1545] Note why we are logging the Version string + + ntpd/ntpd.c@1.133 +1 -1 + [Bug 1545] Note why we are logging the Version string + +ChangeSet@1.2773.1.65, 2012-08-02 04:41:05-04:00, stenn@deacon.udel.edu + [Bug 2247] Get rid of the TRAK refclock - deprecated since 2006 + + BitKeeper/deleted/50/refclock_trak.c~3aed0663@1.12 +0 -0 + Delete: ntpd/refclock_trak.c + + ChangeLog@1.1146.1.56 +1 -0 + [Bug 2247] Get rid of the TRAK refclock - deprecated since 2006 + + configure.ac@1.548 +0 -11 + [Bug 2247] Get rid of the TRAK refclock - deprecated since 2006 + + ntpd/Makefile.am@1.112.1.4 +0 -1 + [Bug 2247] Get rid of the TRAK refclock - deprecated since 2006 + +ChangeSet@1.2773.1.64, 2012-08-02 04:35:10-04:00, stenn@deacon.udel.edu + [Bug 1872] Remove legacy ppsclock fdpps, #ifdef PPS + + ChangeLog@1.1146.1.55 +1 -0 + [Bug 1872] Remove legacy ppsclock fdpps, #ifdef PPS + + ntpd/ntp_refclock.c@1.116 +1 -6 + [Bug 1872] Remove legacy ppsclock fdpps, #ifdef PPS + + ntpd/refclock_zyfer.c@1.10 +1 -18 + [Bug 1872] Remove legacy ppsclock fdpps, #ifdef PPS + +ChangeSet@1.2773.1.63, 2012-08-02 02:32:58-04:00, stenn@deacon.udel.edu + Clean up an exit status in ntpq.c + + ChangeLog@1.1146.1.54 +1 -0 + Clean up an exit status in ntpq.c + + ntpq/ntpq.c@1.148 +1 -1 + Clean up an exit status in ntpq.c + +ChangeSet@1.2773.1.62, 2012-08-01 21:26:07-04:00, stenn@psp-deb1.ntp.org + [Bug 2075] Fix spelling of 'incompatible' + + ChangeLog@1.1146.1.53 +1 -0 + [Bug 2075] Fix spelling of 'incompatible' + + include/ntp_request.h@1.47 +2 -2 + [Bug 2075] Fix spelling of 'incompatible' + + ntpdc/ntpdc.c@1.100 +1 -1 + [Bug 2075] Fix spelling of 'incompatible' + +ChangeSet@1.2773.1.61, 2012-07-31 11:34:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P291 + TAG: NTP_4_2_7P291 + + ChangeLog@1.1146.1.52 +1 -0 + NTP_4_2_7P291 + + ntpd/ntpd-opts.c@1.297 +6 -6 + NTP_4_2_7P291 + + ntpd/ntpd-opts.h@1.297 +3 -3 + NTP_4_2_7P291 + + ntpd/ntpd-opts.texi@1.275.5.2 +2 -2 + NTP_4_2_7P291 + + ntpd/ntpd.1ntpdman@1.108 +548 -8 + NTP_4_2_7P291 + + ntpd/ntpd.1ntpdmdoc@1.108 +547 -8 + NTP_4_2_7P291 + + ntpd/ntpd.man.in@1.108 +548 -8 + NTP_4_2_7P291 + + ntpd/ntpd.mdoc.in@1.108 +547 -8 + NTP_4_2_7P291 + + ntpdc/ntpdc-opts.c@1.291 +4 -4 + NTP_4_2_7P291 + + ntpdc/ntpdc-opts.h@1.291 +3 -3 + NTP_4_2_7P291 + + ntpdc/ntpdc-opts.texi@1.272.5.1 +2 -2 + NTP_4_2_7P291 + + ntpdc/ntpdc.1ntpdcman@1.107 +2 -2 + NTP_4_2_7P291 + + ntpdc/ntpdc.1ntpdcmdoc@1.107 +2 -2 + NTP_4_2_7P291 + + ntpdc/ntpdc.html@1.119 +2 -2 + NTP_4_2_7P291 + + ntpdc/ntpdc.man.in@1.107 +2 -2 + NTP_4_2_7P291 + + ntpdc/ntpdc.mdoc.in@1.107 +2 -2 + NTP_4_2_7P291 + + ntpq/ntpq-opts.c@1.293 +4 -4 + NTP_4_2_7P291 + + ntpq/ntpq-opts.h@1.293 +3 -3 + NTP_4_2_7P291 + + ntpq/ntpq-opts.texi@1.274.5.1 +2 -2 + NTP_4_2_7P291 + + ntpq/ntpq.1ntpqman@1.107 +2 -2 + NTP_4_2_7P291 + + ntpq/ntpq.1ntpqmdoc@1.107 +2 -2 + NTP_4_2_7P291 + + ntpq/ntpq.man.in@1.107 +2 -2 + NTP_4_2_7P291 + + ntpq/ntpq.mdoc.in@1.107 +2 -2 + NTP_4_2_7P291 + + ntpsnmpd/ntpsnmpd-opts.c@1.293 +4 -4 + NTP_4_2_7P291 + + ntpsnmpd/ntpsnmpd-opts.h@1.293 +3 -3 + NTP_4_2_7P291 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.5.1 +2 -2 + NTP_4_2_7P291 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.107 +2 -2 + NTP_4_2_7P291 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.107 +2 -2 + NTP_4_2_7P291 + + ntpsnmpd/ntpsnmpd.man.in@1.107 +2 -2 + NTP_4_2_7P291 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.107 +2 -2 + NTP_4_2_7P291 + + packageinfo.sh@1.294 +1 -1 + NTP_4_2_7P291 + + scripts/ntp-wait-opts.texi@1.92.5.1 +1 -1 + NTP_4_2_7P291 + + scripts/ntp-wait.1ntp-waitman@1.107 +2 -2 + NTP_4_2_7P291 + + scripts/ntp-wait.1ntp-waitmdoc@1.107 +2 -2 + NTP_4_2_7P291 + + scripts/ntp-wait.html@1.111 +1 -1 + NTP_4_2_7P291 + + scripts/ntp-wait.man.in@1.107 +2 -2 + NTP_4_2_7P291 + + scripts/ntp-wait.mdoc.in@1.107 +2 -2 + NTP_4_2_7P291 + + sntp/sntp-opts.c@1.289 +4 -4 + NTP_4_2_7P291 + + sntp/sntp-opts.h@1.289 +3 -3 + NTP_4_2_7P291 + + sntp/sntp-opts.texi@1.270.5.1 +2 -2 + NTP_4_2_7P291 + + sntp/sntp.1sntpman@1.109 +2 -2 + NTP_4_2_7P291 + + sntp/sntp.1sntpmdoc@1.109 +2 -2 + NTP_4_2_7P291 + + sntp/sntp.html@1.289 +2 -2 + NTP_4_2_7P291 + + sntp/sntp.man.in@1.109 +2 -2 + NTP_4_2_7P291 + + sntp/sntp.mdoc.in@1.109 +2 -2 + NTP_4_2_7P291 + + util/ntp-keygen-opts.c@1.293 +4 -4 + NTP_4_2_7P291 + + util/ntp-keygen-opts.h@1.293 +3 -3 + NTP_4_2_7P291 + + util/ntp-keygen-opts.texi@1.275.5.1 +2 -2 + NTP_4_2_7P291 + + util/ntp-keygen.1ntp-keygenman@1.107 +2 -2 + NTP_4_2_7P291 + + util/ntp-keygen.1ntp-keygenmdoc@1.107 +2 -2 + NTP_4_2_7P291 + + util/ntp-keygen.man.in@1.107 +2 -2 + NTP_4_2_7P291 + + util/ntp-keygen.mdoc.in@1.107 +2 -2 + NTP_4_2_7P291 + +ChangeSet@1.2773.1.60, 2012-07-27 15:12:58-04:00, utterback@pogo.udel.edu + [Bug 2241] New: MDNS registration should only happen if requested. + + ChangeLog@1.1146.1.51 +1 -0 + [Bug 2241] New: MDNS registration should only happen if requested. + + html/ntpd.html@1.56 +2 -0 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd-opts.c@1.296 +58 -27 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd-opts.h@1.296 +12 -5 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd-opts.texi@1.275.5.1 +18 -2 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd.1ntpdman@1.107 +14 -548 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd.1ntpdmdoc@1.107 +13 -547 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd.c@1.132 +11 -2 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd.man.in@1.107 +14 -548 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpd.mdoc.in@1.107 +13 -547 + [Bug 2241] New: MDNS registration should only happen if requested. + + ntpd/ntpdbase-opts.def@1.23 +11 -0 + [Bug 2241] New: MDNS registration should only happen if requested. + +ChangeSet@1.2782, 2012-07-20 06:02:41-04:00, stenn@psp-deb1.ntp.org + Upgrade to autogen-5.16.1 and libopts-36.4.11 + + sntp/include/autogen-version.def@1.11 +1 -1 + Upgrade to autogen-5.16.1 and libopts-36.4.11 + + sntp/libopts/Makefile.am@1.14, stenn@psp-fb1.ntp.org +5 -5 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/ag-char-map.h@1.17, stenn@psp-fb1.ntp.org +295 -197 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/ao-strs.c@1.3, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/ao-strs.h@1.2, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/autoopts/options.h@1.16, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/autoopts/project.h@1.3, stenn@psp-fb1.ntp.org +0 -2 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/autoopts/usage-txt.h@1.16, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/compat/windows-config.h@1.9, stenn@psp-fb1.ntp.org +25 -14 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/genshell.c@1.17, stenn@psp-fb1.ntp.org +41 -11 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/genshell.h@1.17, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/libopts.c@1.7, stenn@psp-fb1.ntp.org +0 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/m4/libopts.m4@1.20, stenn@psp-fb1.ntp.org +7 -7 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/parse-duration.c@1.8, stenn@psp-fb1.ntp.org +7 -7 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/parse-duration.h@1.7, stenn@psp-fb1.ntp.org +4 -4 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/proto.h@1.17, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/value-type.h@1.17, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/libopts/xat-attribute.h@1.17, stenn@psp-fb1.ntp.org +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + +ChangeSet@1.2773.1.59, 2012-07-20 00:03:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P290 + TAG: NTP_4_2_7P290 + + ChangeLog@1.1146.1.50 +1 -0 + NTP_4_2_7P290 + + ntpd/ntpd-opts.c@1.295 +4 -4 + NTP_4_2_7P290 + + ntpd/ntpd-opts.h@1.295 +3 -3 + NTP_4_2_7P290 + + ntpd/ntpd-opts.texi@1.275.4.6 +2 -2 + NTP_4_2_7P290 + + ntpd/ntpd.1ntpdman@1.106 +2 -2 + NTP_4_2_7P290 + + ntpd/ntpd.1ntpdmdoc@1.106 +2 -2 + NTP_4_2_7P290 + + ntpd/ntpd.man.in@1.106 +2 -2 + NTP_4_2_7P290 + + ntpd/ntpd.mdoc.in@1.106 +2 -2 + NTP_4_2_7P290 + + ntpdc/ntpdc-opts.c@1.290 +4 -4 + NTP_4_2_7P290 + + ntpdc/ntpdc-opts.h@1.290 +3 -3 + NTP_4_2_7P290 + + ntpdc/ntpdc-opts.texi@1.272.4.6 +2 -2 + NTP_4_2_7P290 + + ntpdc/ntpdc.1ntpdcman@1.106 +2 -2 + NTP_4_2_7P290 + + ntpdc/ntpdc.1ntpdcmdoc@1.106 +2 -2 + NTP_4_2_7P290 + + ntpdc/ntpdc.html@1.118 +2 -2 + NTP_4_2_7P290 + + ntpdc/ntpdc.man.in@1.106 +2 -2 + NTP_4_2_7P290 + + ntpdc/ntpdc.mdoc.in@1.106 +2 -2 + NTP_4_2_7P290 + + ntpq/ntpq-opts.c@1.292 +4 -4 + NTP_4_2_7P290 + + ntpq/ntpq-opts.h@1.292 +3 -3 + NTP_4_2_7P290 + + ntpq/ntpq-opts.texi@1.274.4.6 +2 -2 + NTP_4_2_7P290 + + ntpq/ntpq.1ntpqman@1.106 +2 -2 + NTP_4_2_7P290 + + ntpq/ntpq.1ntpqmdoc@1.106 +2 -2 + NTP_4_2_7P290 + + ntpq/ntpq.man.in@1.106 +2 -2 + NTP_4_2_7P290 + + ntpq/ntpq.mdoc.in@1.106 +2 -2 + NTP_4_2_7P290 + + ntpsnmpd/ntpsnmpd-opts.c@1.292 +4 -4 + NTP_4_2_7P290 + + ntpsnmpd/ntpsnmpd-opts.h@1.292 +3 -3 + NTP_4_2_7P290 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.4.6 +2 -2 + NTP_4_2_7P290 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.106 +2 -2 + NTP_4_2_7P290 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.106 +2 -2 + NTP_4_2_7P290 + + ntpsnmpd/ntpsnmpd.man.in@1.106 +2 -2 + NTP_4_2_7P290 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.106 +2 -2 + NTP_4_2_7P290 + + packageinfo.sh@1.293 +1 -1 + NTP_4_2_7P290 + + scripts/ntp-wait-opts.texi@1.92.4.6 +1 -1 + NTP_4_2_7P290 + + scripts/ntp-wait.1ntp-waitman@1.106 +2 -2 + NTP_4_2_7P290 + + scripts/ntp-wait.1ntp-waitmdoc@1.106 +2 -2 + NTP_4_2_7P290 + + scripts/ntp-wait.html@1.110 +1 -1 + NTP_4_2_7P290 + + scripts/ntp-wait.man.in@1.106 +2 -2 + NTP_4_2_7P290 + + scripts/ntp-wait.mdoc.in@1.106 +2 -2 + NTP_4_2_7P290 + + sntp/sntp-opts.c@1.288 +4 -4 + NTP_4_2_7P290 + + sntp/sntp-opts.h@1.288 +3 -3 + NTP_4_2_7P290 + + sntp/sntp-opts.texi@1.270.4.6 +2 -2 + NTP_4_2_7P290 + + sntp/sntp.1sntpman@1.108 +2 -2 + NTP_4_2_7P290 + + sntp/sntp.1sntpmdoc@1.108 +2 -2 + NTP_4_2_7P290 + + sntp/sntp.html@1.288 +2 -2 + NTP_4_2_7P290 + + sntp/sntp.man.in@1.108 +2 -2 + NTP_4_2_7P290 + + sntp/sntp.mdoc.in@1.108 +2 -2 + NTP_4_2_7P290 + + util/ntp-keygen-opts.c@1.292 +4 -4 + NTP_4_2_7P290 + + util/ntp-keygen-opts.h@1.292 +3 -3 + NTP_4_2_7P290 + + util/ntp-keygen-opts.texi@1.275.4.6 +2 -2 + NTP_4_2_7P290 + + util/ntp-keygen.1ntp-keygenman@1.106 +2 -2 + NTP_4_2_7P290 + + util/ntp-keygen.1ntp-keygenmdoc@1.106 +2 -2 + NTP_4_2_7P290 + + util/ntp-keygen.man.in@1.106 +2 -2 + NTP_4_2_7P290 + + util/ntp-keygen.mdoc.in@1.106 +2 -2 + NTP_4_2_7P290 + +ChangeSet@1.2773.1.58, 2012-07-19 19:26:56-04:00, stenn@psp-deb1.ntp.org + [Bug 1454] Add parse clock support for the SEL-240x GPS products + + ChangeLog@1.1146.1.49 +1 -0 + [Bug 1454] Add parse clock support for the SEL-240x GPS products + + configure.ac@1.547 +16 -0 + [Bug 1454] Add parse clock support for the SEL-240x GPS products + + html/drivers/driver8.html@1.29 +252 -242 + [Bug 1454] Add parse clock support for the SEL-240x GPS products + + libparse/Makefile.am@1.29 +8 -0 + [Bug 1454] Add parse clock support for the SEL-240x GPS products + + libparse/clk_sel240x.c@1.1 +194 -0 + BitKeeper file /home/stenn/ntp-dev/libparse/clk_sel240x.c + + libparse/clk_sel240x.c@1.0 +0 -0 + + libparse/parse_conf.c@1.10 +7 -0 + [Bug 1454] Add parse clock support for the SEL-240x GPS products + + ntpd/refclock_parse.c@1.67 +52 -0 + [Bug 1454] Add parse clock support for the SEL-240x GPS products + +ChangeSet@1.2773.1.57, 2012-07-17 01:15:11-04:00, stenn@psp-deb1.ntp.org + CID 709185: refclock_chu.c will leak fd==0 (better fix) + + ChangeLog@1.1146.1.48 +1 -0 + CID 709185: refclock_chu.c will leak fd==0 (better fix) + + ntpd/refclock_chu.c@1.55 +4 -13 + CID 709185: refclock_chu.c will leak fd==0 (better fix) + +ChangeSet@1.2773.1.56, 2012-07-16 00:21:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P289 + TAG: NTP_4_2_7P289 + + ChangeLog@1.1146.1.47 +1 -0 + NTP_4_2_7P289 + + ntpd/ntpd-opts.c@1.294 +4 -4 + NTP_4_2_7P289 + + ntpd/ntpd-opts.h@1.294 +3 -3 + NTP_4_2_7P289 + + ntpd/ntpd-opts.texi@1.275.4.5 +2 -2 + NTP_4_2_7P289 + + ntpd/ntpd.1ntpdman@1.105 +4 -10 + NTP_4_2_7P289 + + ntpd/ntpd.1ntpdmdoc@1.105 +4 -10 + NTP_4_2_7P289 + + ntpd/ntpd.man.in@1.105 +4 -10 + NTP_4_2_7P289 + + ntpd/ntpd.mdoc.in@1.105 +4 -10 + NTP_4_2_7P289 + + ntpdc/ntpdc-opts.c@1.289 +4 -4 + NTP_4_2_7P289 + + ntpdc/ntpdc-opts.h@1.289 +3 -3 + NTP_4_2_7P289 + + ntpdc/ntpdc-opts.texi@1.272.4.5 +2 -2 + NTP_4_2_7P289 + + ntpdc/ntpdc.1ntpdcman@1.105 +3 -8 + NTP_4_2_7P289 + + ntpdc/ntpdc.1ntpdcmdoc@1.105 +3 -8 + NTP_4_2_7P289 + + ntpdc/ntpdc.html@1.117 +2 -2 + NTP_4_2_7P289 + + ntpdc/ntpdc.man.in@1.105 +3 -8 + NTP_4_2_7P289 + + ntpdc/ntpdc.mdoc.in@1.105 +3 -8 + NTP_4_2_7P289 + + ntpq/ntpq-opts.c@1.291 +4 -4 + NTP_4_2_7P289 + + ntpq/ntpq-opts.h@1.291 +3 -3 + NTP_4_2_7P289 + + ntpq/ntpq-opts.texi@1.274.4.5 +2 -2 + NTP_4_2_7P289 + + ntpq/ntpq.1ntpqman@1.105 +2 -3 + NTP_4_2_7P289 + + ntpq/ntpq.1ntpqmdoc@1.105 +2 -3 + NTP_4_2_7P289 + + ntpq/ntpq.man.in@1.105 +2 -3 + NTP_4_2_7P289 + + ntpq/ntpq.mdoc.in@1.105 +2 -3 + NTP_4_2_7P289 + + ntpsnmpd/ntpsnmpd-opts.c@1.291 +4 -4 + NTP_4_2_7P289 + + ntpsnmpd/ntpsnmpd-opts.h@1.291 +3 -3 + NTP_4_2_7P289 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.4.5 +2 -2 + NTP_4_2_7P289 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.105 +2 -4 + NTP_4_2_7P289 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.105 +2 -4 + NTP_4_2_7P289 + + ntpsnmpd/ntpsnmpd.man.in@1.105 +2 -4 + NTP_4_2_7P289 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.105 +2 -4 + NTP_4_2_7P289 + + packageinfo.sh@1.292 +1 -1 + NTP_4_2_7P289 + + scripts/ntp-wait-opts.texi@1.92.4.5 +2 -14 + NTP_4_2_7P289 + + scripts/ntp-wait.1ntp-waitman@1.105 +2 -4 + NTP_4_2_7P289 + + scripts/ntp-wait.1ntp-waitmdoc@1.105 +2 -4 + NTP_4_2_7P289 + + scripts/ntp-wait.html@1.109 +2 -14 + NTP_4_2_7P289 + + scripts/ntp-wait.man.in@1.105 +2 -4 + NTP_4_2_7P289 + + scripts/ntp-wait.mdoc.in@1.105 +2 -4 + NTP_4_2_7P289 + + sntp/sntp-opts.c@1.287 +4 -4 + NTP_4_2_7P289 + + sntp/sntp-opts.h@1.287 +3 -3 + NTP_4_2_7P289 + + sntp/sntp-opts.texi@1.270.4.5 +2 -2 + NTP_4_2_7P289 + + sntp/sntp.1sntpman@1.107 +3 -7 + NTP_4_2_7P289 + + sntp/sntp.1sntpmdoc@1.107 +3 -7 + NTP_4_2_7P289 + + sntp/sntp.html@1.287 +2 -2 + NTP_4_2_7P289 + + sntp/sntp.man.in@1.107 +3 -7 + NTP_4_2_7P289 + + sntp/sntp.mdoc.in@1.107 +3 -7 + NTP_4_2_7P289 + + util/ntp-keygen-opts.c@1.291 +4 -4 + NTP_4_2_7P289 + + util/ntp-keygen-opts.h@1.291 +3 -3 + NTP_4_2_7P289 + + util/ntp-keygen-opts.texi@1.275.4.5 +2 -2 + NTP_4_2_7P289 + + util/ntp-keygen.1ntp-keygenman@1.105 +4 -8 + NTP_4_2_7P289 + + util/ntp-keygen.1ntp-keygenmdoc@1.105 +4 -8 + NTP_4_2_7P289 + + util/ntp-keygen.man.in@1.105 +4 -8 + NTP_4_2_7P289 + + util/ntp-keygen.mdoc.in@1.105 +4 -8 + NTP_4_2_7P289 + +ChangeSet@1.2773.1.55, 2012-07-15 02:28:03-07:00, stenn@stenn.ntp.org + CID 97123: Future-proof possible change to refclock_nmea.c + + ChangeLog@1.1146.1.46 +1 -0 + CID 97123: Future-proof possible change to refclock_nmea.c + + ntpd/refclock_nmea.c@1.71 +1 -0 + CID 97123: Future-proof possible change to refclock_nmea.c + +ChangeSet@1.2773.1.54, 2012-07-15 01:04:03-07:00, stenn@stenn.ntp.org + CID 97377: ntp-keygen.c's followlink() might not NUL-terminate + + ChangeLog@1.1146.1.45 +1 -0 + CID 97377: ntp-keygen.c's followlink() might not NUL-terminate + + util/ntp-keygen.c@1.92 +5 -1 + CID 97377: ntp-keygen.c's followlink() might not NUL-terminate + +ChangeSet@1.2773.1.53, 2012-07-14 23:46:24-07:00, stenn@stenn.ntp.org + CID 709185: refclock_chu.c will leak fd==0 (which should be impossible) + + ChangeLog@1.1146.1.44 +1 -0 + CID 709185: refclock_chu.c will leak fd==0 (which should be impossible) + + ntpd/refclock_chu.c@1.54 +11 -0 + CID 709185: refclock_chu.c will leak fd==0 (which should be impossible) + +ChangeSet@1.2773.1.52, 2012-07-03 09:13:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P288 + TAG: NTP_4_2_7P288 + + ChangeLog@1.1146.1.43 +1 -0 + NTP_4_2_7P288 + + ntpd/ntpd-opts.c@1.293 +4 -4 + NTP_4_2_7P288 + + ntpd/ntpd-opts.h@1.293 +3 -3 + NTP_4_2_7P288 + + ntpd/ntpd-opts.texi@1.275.4.4 +2 -2 + NTP_4_2_7P288 + + ntpd/ntpd.1ntpdman@1.104 +554 -8 + NTP_4_2_7P288 + + ntpd/ntpd.1ntpdmdoc@1.104 +552 -7 + NTP_4_2_7P288 + + ntpd/ntpd.man.in@1.104 +554 -8 + NTP_4_2_7P288 + + ntpd/ntpd.mdoc.in@1.104 +552 -7 + NTP_4_2_7P288 + + ntpdc/ntpdc-opts.c@1.288 +4 -4 + NTP_4_2_7P288 + + ntpdc/ntpdc-opts.h@1.288 +3 -3 + NTP_4_2_7P288 + + ntpdc/ntpdc-opts.texi@1.272.4.4 +2 -2 + NTP_4_2_7P288 + + ntpdc/ntpdc.1ntpdcman@1.104 +709 -7 + NTP_4_2_7P288 + + ntpdc/ntpdc.1ntpdcmdoc@1.104 +663 -6 + NTP_4_2_7P288 + + ntpdc/ntpdc.html@1.116 +2 -2 + NTP_4_2_7P288 + + ntpdc/ntpdc.man.in@1.104 +709 -7 + NTP_4_2_7P288 + + ntpdc/ntpdc.mdoc.in@1.104 +663 -6 + NTP_4_2_7P288 + + ntpq/ntpq-opts.c@1.290 +4 -4 + NTP_4_2_7P288 + + ntpq/ntpq-opts.h@1.290 +3 -3 + NTP_4_2_7P288 + + ntpq/ntpq-opts.texi@1.274.4.4 +2 -2 + NTP_4_2_7P288 + + ntpq/ntpq.1ntpqman@1.104 +261 -3 + NTP_4_2_7P288 + + ntpq/ntpq.1ntpqmdoc@1.104 +245 -2 + NTP_4_2_7P288 + + ntpq/ntpq.man.in@1.104 +261 -3 + NTP_4_2_7P288 + + ntpq/ntpq.mdoc.in@1.104 +245 -2 + NTP_4_2_7P288 + + ntpsnmpd/ntpsnmpd-opts.c@1.290 +4 -4 + NTP_4_2_7P288 + + ntpsnmpd/ntpsnmpd-opts.h@1.290 +3 -3 + NTP_4_2_7P288 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.4.4 +2 -2 + NTP_4_2_7P288 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.104 +5 -4 + NTP_4_2_7P288 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.104 +4 -3 + NTP_4_2_7P288 + + ntpsnmpd/ntpsnmpd.man.in@1.104 +5 -4 + NTP_4_2_7P288 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.104 +4 -3 + NTP_4_2_7P288 + + packageinfo.sh@1.291 +1 -1 + NTP_4_2_7P288 + + scripts/ntp-wait-opts.texi@1.92.4.4 +1 -1 + NTP_4_2_7P288 + + scripts/ntp-wait.1ntp-waitman@1.104 +20 -4 + NTP_4_2_7P288 + + scripts/ntp-wait.1ntp-waitmdoc@1.104 +19 -3 + NTP_4_2_7P288 + + scripts/ntp-wait.html@1.108 +1 -1 + NTP_4_2_7P288 + + scripts/ntp-wait.man.in@1.104 +20 -4 + NTP_4_2_7P288 + + scripts/ntp-wait.mdoc.in@1.104 +19 -3 + NTP_4_2_7P288 + + sntp/sntp-opts.c@1.286 +4 -4 + NTP_4_2_7P288 + + sntp/sntp-opts.h@1.286 +3 -3 + NTP_4_2_7P288 + + sntp/sntp-opts.texi@1.270.4.4 +2 -2 + NTP_4_2_7P288 + + sntp/sntp.1sntpman@1.106 +69 -6 + NTP_4_2_7P288 + + sntp/sntp.1sntpmdoc@1.106 +68 -5 + NTP_4_2_7P288 + + sntp/sntp.html@1.286 +2 -2 + NTP_4_2_7P288 + + sntp/sntp.man.in@1.106 +69 -6 + NTP_4_2_7P288 + + sntp/sntp.mdoc.in@1.106 +68 -5 + NTP_4_2_7P288 + + util/ntp-keygen-opts.c@1.290 +4 -4 + NTP_4_2_7P288 + + util/ntp-keygen-opts.h@1.290 +3 -3 + NTP_4_2_7P288 + + util/ntp-keygen-opts.texi@1.275.4.4 +2 -2 + NTP_4_2_7P288 + + util/ntp-keygen.1ntp-keygenman@1.104 +724 -6 + NTP_4_2_7P288 + + util/ntp-keygen.1ntp-keygenmdoc@1.104 +709 -5 + NTP_4_2_7P288 + + util/ntp-keygen.man.in@1.104 +724 -6 + NTP_4_2_7P288 + + util/ntp-keygen.mdoc.in@1.104 +709 -5 + NTP_4_2_7P288 + +ChangeSet@1.2773.1.51, 2012-07-03 04:44:18-04:00, stenn@deacon.udel.edu + CID 709173: Make sure a libisc function we do not use is called properly + + ChangeLog@1.1146.1.42 +1 -0 + CID 709173: Make sure a libisc function we do not use is called properly + + lib/isc/unix/file.c@1.6 +2 -0 + CID 709173: Make sure a libisc function we do not use is called properly + +ChangeSet@1.2773.1.50, 2012-07-03 01:29:06+00:00, stenn@deacon.udel.edu + NTP_4_2_7P287 + TAG: NTP_4_2_7P287 + + ChangeLog@1.1146.1.41 +1 -0 + NTP_4_2_7P287 + + ntpd/ntpd-opts.c@1.292 +4 -4 + NTP_4_2_7P287 + + ntpd/ntpd-opts.h@1.292 +3 -3 + NTP_4_2_7P287 + + ntpd/ntpd-opts.texi@1.275.4.3 +2 -2 + NTP_4_2_7P287 + + ntpd/ntpd.1ntpdman@1.103 +2 -2 + NTP_4_2_7P287 + + ntpd/ntpd.1ntpdmdoc@1.103 +2 -2 + NTP_4_2_7P287 + + ntpd/ntpd.man.in@1.103 +2 -2 + NTP_4_2_7P287 + + ntpd/ntpd.mdoc.in@1.103 +2 -2 + NTP_4_2_7P287 + + ntpdc/ntpdc-opts.c@1.287 +4 -4 + NTP_4_2_7P287 + + ntpdc/ntpdc-opts.h@1.287 +3 -3 + NTP_4_2_7P287 + + ntpdc/ntpdc-opts.texi@1.272.4.3 +2 -2 + NTP_4_2_7P287 + + ntpdc/ntpdc.1ntpdcman@1.103 +2 -2 + NTP_4_2_7P287 + + ntpdc/ntpdc.1ntpdcmdoc@1.103 +2 -2 + NTP_4_2_7P287 + + ntpdc/ntpdc.html@1.115 +2 -2 + NTP_4_2_7P287 + + ntpdc/ntpdc.man.in@1.103 +2 -2 + NTP_4_2_7P287 + + ntpdc/ntpdc.mdoc.in@1.103 +2 -2 + NTP_4_2_7P287 + + ntpq/ntpq-opts.c@1.289 +4 -4 + NTP_4_2_7P287 + + ntpq/ntpq-opts.h@1.289 +3 -3 + NTP_4_2_7P287 + + ntpq/ntpq-opts.texi@1.274.4.3 +2 -2 + NTP_4_2_7P287 + + ntpq/ntpq.1ntpqman@1.103 +2 -2 + NTP_4_2_7P287 + + ntpq/ntpq.1ntpqmdoc@1.103 +2 -2 + NTP_4_2_7P287 + + ntpq/ntpq.man.in@1.103 +2 -2 + NTP_4_2_7P287 + + ntpq/ntpq.mdoc.in@1.103 +2 -2 + NTP_4_2_7P287 + + ntpsnmpd/ntpsnmpd-opts.c@1.289 +4 -4 + NTP_4_2_7P287 + + ntpsnmpd/ntpsnmpd-opts.h@1.289 +3 -3 + NTP_4_2_7P287 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.4.3 +2 -2 + NTP_4_2_7P287 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.103 +2 -2 + NTP_4_2_7P287 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.103 +2 -2 + NTP_4_2_7P287 + + ntpsnmpd/ntpsnmpd.man.in@1.103 +2 -2 + NTP_4_2_7P287 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.103 +2 -2 + NTP_4_2_7P287 + + packageinfo.sh@1.290 +1 -1 + NTP_4_2_7P287 + + scripts/ntp-wait-opts.texi@1.92.4.3 +14 -2 + NTP_4_2_7P287 + + scripts/ntp-wait.1ntp-waitman@1.103 +2 -2 + NTP_4_2_7P287 + + scripts/ntp-wait.1ntp-waitmdoc@1.103 +2 -2 + NTP_4_2_7P287 + + scripts/ntp-wait.html@1.107 +14 -2 + NTP_4_2_7P287 + + scripts/ntp-wait.man.in@1.103 +2 -2 + NTP_4_2_7P287 + + scripts/ntp-wait.mdoc.in@1.103 +2 -2 + NTP_4_2_7P287 + + sntp/sntp-opts.c@1.285 +4 -4 + NTP_4_2_7P287 + + sntp/sntp-opts.h@1.285 +3 -3 + NTP_4_2_7P287 + + sntp/sntp-opts.texi@1.270.4.3 +2 -2 + NTP_4_2_7P287 + + sntp/sntp.1sntpman@1.105 +2 -2 + NTP_4_2_7P287 + + sntp/sntp.1sntpmdoc@1.105 +2 -2 + NTP_4_2_7P287 + + sntp/sntp.html@1.285 +2 -2 + NTP_4_2_7P287 + + sntp/sntp.man.in@1.105 +2 -2 + NTP_4_2_7P287 + + sntp/sntp.mdoc.in@1.105 +2 -2 + NTP_4_2_7P287 + + util/ntp-keygen-opts.c@1.289 +4 -4 + NTP_4_2_7P287 + + util/ntp-keygen-opts.h@1.289 +3 -3 + NTP_4_2_7P287 + + util/ntp-keygen-opts.texi@1.275.4.3 +2 -2 + NTP_4_2_7P287 + + util/ntp-keygen.1ntp-keygenman@1.103 +2 -2 + NTP_4_2_7P287 + + util/ntp-keygen.1ntp-keygenmdoc@1.103 +2 -2 + NTP_4_2_7P287 + + util/ntp-keygen.man.in@1.103 +2 -2 + NTP_4_2_7P287 + + util/ntp-keygen.mdoc.in@1.103 +2 -2 + NTP_4_2_7P287 + +ChangeSet@1.2773.1.49, 2012-07-02 02:17:35+00:00, davehart@dlh-7551.ad.hartbrothers.com + Remove 1024 associations-per-server limit from ntpq. + Remove blank line between ntpq mreadvar associations. + + ChangeLog@1.1146.1.40 +2 -0 + Remove 1024 associations-per-server limit from ntpq. + Remove blank line between ntpq mreadvar associations. + + ntpq/ntpq-subs.c@1.97 +13 -10 + Remove 1024 associations-per-server limit from ntpq. + Remove blank line between ntpq mreadvar associations. + + ntpq/ntpq.c@1.147 +28 -2 + Remove 1024 associations-per-server limit from ntpq. + + ntpq/ntpq.h@1.27 +3 -3 + Remove 1024 associations-per-server limit from ntpq. + +ChangeSet@1.2773.1.48, 2012-06-28 07:06:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P286 + TAG: NTP_4_2_7P286 + + ChangeLog@1.1146.1.39 +1 -0 + NTP_4_2_7P286 + + ntpd/ntpd-opts.c@1.291 +4 -4 + NTP_4_2_7P286 + + ntpd/ntpd-opts.h@1.291 +3 -3 + NTP_4_2_7P286 + + ntpd/ntpd-opts.texi@1.275.4.2 +2 -2 + NTP_4_2_7P286 + + ntpd/ntpd.1ntpdman@1.102 +2 -2 + NTP_4_2_7P286 + + ntpd/ntpd.1ntpdmdoc@1.102 +2 -2 + NTP_4_2_7P286 + + ntpd/ntpd.man.in@1.102 +2 -2 + NTP_4_2_7P286 + + ntpd/ntpd.mdoc.in@1.102 +2 -2 + NTP_4_2_7P286 + + ntpdc/ntpdc-opts.c@1.286 +4 -4 + NTP_4_2_7P286 + + ntpdc/ntpdc-opts.h@1.286 +3 -3 + NTP_4_2_7P286 + + ntpdc/ntpdc-opts.texi@1.272.4.2 +2 -2 + NTP_4_2_7P286 + + ntpdc/ntpdc.1ntpdcman@1.102 +2 -2 + NTP_4_2_7P286 + + ntpdc/ntpdc.1ntpdcmdoc@1.102 +2 -2 + NTP_4_2_7P286 + + ntpdc/ntpdc.html@1.114 +2 -2 + NTP_4_2_7P286 + + ntpdc/ntpdc.man.in@1.102 +2 -2 + NTP_4_2_7P286 + + ntpdc/ntpdc.mdoc.in@1.102 +2 -2 + NTP_4_2_7P286 + + ntpq/ntpq-opts.c@1.288 +4 -4 + NTP_4_2_7P286 + + ntpq/ntpq-opts.h@1.288 +3 -3 + NTP_4_2_7P286 + + ntpq/ntpq-opts.texi@1.274.4.2 +2 -2 + NTP_4_2_7P286 + + ntpq/ntpq.1ntpqman@1.102 +2 -2 + NTP_4_2_7P286 + + ntpq/ntpq.1ntpqmdoc@1.102 +2 -2 + NTP_4_2_7P286 + + ntpq/ntpq.man.in@1.102 +2 -2 + NTP_4_2_7P286 + + ntpq/ntpq.mdoc.in@1.102 +2 -2 + NTP_4_2_7P286 + + ntpsnmpd/ntpsnmpd-opts.c@1.288 +4 -4 + NTP_4_2_7P286 + + ntpsnmpd/ntpsnmpd-opts.h@1.288 +3 -3 + NTP_4_2_7P286 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.4.2 +2 -2 + NTP_4_2_7P286 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.102 +2 -2 + NTP_4_2_7P286 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.102 +2 -2 + NTP_4_2_7P286 + + ntpsnmpd/ntpsnmpd.man.in@1.102 +2 -2 + NTP_4_2_7P286 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.102 +2 -2 + NTP_4_2_7P286 + + packageinfo.sh@1.289 +1 -1 + NTP_4_2_7P286 + + scripts/ntp-wait-opts.texi@1.92.4.2 +2 -14 + NTP_4_2_7P286 + + scripts/ntp-wait.1ntp-waitman@1.102 +2 -2 + NTP_4_2_7P286 + + scripts/ntp-wait.1ntp-waitmdoc@1.102 +2 -2 + NTP_4_2_7P286 + + scripts/ntp-wait.html@1.106 +2 -14 + NTP_4_2_7P286 + + scripts/ntp-wait.man.in@1.102 +2 -2 + NTP_4_2_7P286 + + scripts/ntp-wait.mdoc.in@1.102 +2 -2 + NTP_4_2_7P286 + + sntp/sntp-opts.c@1.284 +4 -4 + NTP_4_2_7P286 + + sntp/sntp-opts.h@1.284 +3 -3 + NTP_4_2_7P286 + + sntp/sntp-opts.texi@1.270.4.2 +2 -2 + NTP_4_2_7P286 + + sntp/sntp.1sntpman@1.104 +2 -2 + NTP_4_2_7P286 + + sntp/sntp.1sntpmdoc@1.104 +2 -2 + NTP_4_2_7P286 + + sntp/sntp.html@1.284 +2 -2 + NTP_4_2_7P286 + + sntp/sntp.man.in@1.104 +2 -2 + NTP_4_2_7P286 + + sntp/sntp.mdoc.in@1.104 +2 -2 + NTP_4_2_7P286 + + util/ntp-keygen-opts.c@1.288 +4 -4 + NTP_4_2_7P286 + + util/ntp-keygen-opts.h@1.288 +3 -3 + NTP_4_2_7P286 + + util/ntp-keygen-opts.texi@1.275.4.2 +2 -2 + NTP_4_2_7P286 + + util/ntp-keygen.1ntp-keygenman@1.102 +2 -2 + NTP_4_2_7P286 + + util/ntp-keygen.1ntp-keygenmdoc@1.102 +2 -2 + NTP_4_2_7P286 + + util/ntp-keygen.man.in@1.102 +2 -2 + NTP_4_2_7P286 + + util/ntp-keygen.mdoc.in@1.102 +2 -2 + NTP_4_2_7P286 + +ChangeSet@1.2773.1.47, 2012-06-27 23:43:05-07:00, stenn@stenn.ntp.org + CID 97193: check return from sscanf() in ntp_config.c + + ChangeLog@1.1146.1.38 +1 -0 + CID 97193: check return from sscanf() in ntp_config.c + + ntpd/ntp_config.c@1.300 +3 -3 + CID 97193: check return from sscanf() in ntp_config.c + +ChangeSet@1.2773.1.46, 2012-06-27 23:37:22-07:00, stenn@stenn.ntp.org + CID 709207: Initialize "quality" for ulink_receive + + ChangeLog@1.1146.1.37 +1 -0 + CID 709207: Initialize "quality" for ulink_receive + + ntpd/refclock_ulink.c@1.19 +7 -7 + CID 709207: Initialize "quality" for ulink_receive + +ChangeSet@1.2773.1.45, 2012-06-27 23:28:32-07:00, stenn@stenn.ntp.org + CID 709169: check return from open("/dev/null", 0) and friends + + ChangeLog@1.1146.1.36 +1 -0 + CID 709169: check return from open("/dev/null", 0) and friends + + ntpd/ntpd.c@1.131 +2 -3 + CID 709169: check return from open("/dev/null", 0) and friends + +ChangeSet@1.2773.1.44, 2012-06-18 11:33:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P285 + TAG: NTP_4_2_7P285 + + ChangeLog@1.1146.1.35 +1 -0 + NTP_4_2_7P285 + + ntpd/ntpd-opts.c@1.290 +4 -4 + NTP_4_2_7P285 + + ntpd/ntpd-opts.h@1.290 +3 -3 + NTP_4_2_7P285 + + ntpd/ntpd-opts.texi@1.275.4.1 +2 -2 + NTP_4_2_7P285 + + ntpd/ntpd.1ntpdman@1.101 +2 -2 + NTP_4_2_7P285 + + ntpd/ntpd.1ntpdmdoc@1.101 +2 -2 + NTP_4_2_7P285 + + ntpd/ntpd.man.in@1.101 +2 -2 + NTP_4_2_7P285 + + ntpd/ntpd.mdoc.in@1.101 +2 -2 + NTP_4_2_7P285 + + ntpdc/ntpdc-opts.c@1.285 +4 -4 + NTP_4_2_7P285 + + ntpdc/ntpdc-opts.h@1.285 +3 -3 + NTP_4_2_7P285 + + ntpdc/ntpdc-opts.texi@1.272.4.1 +2 -2 + NTP_4_2_7P285 + + ntpdc/ntpdc.1ntpdcman@1.101 +2 -2 + NTP_4_2_7P285 + + ntpdc/ntpdc.1ntpdcmdoc@1.101 +2 -2 + NTP_4_2_7P285 + + ntpdc/ntpdc.html@1.113 +2 -2 + NTP_4_2_7P285 + + ntpdc/ntpdc.man.in@1.101 +2 -2 + NTP_4_2_7P285 + + ntpdc/ntpdc.mdoc.in@1.101 +2 -2 + NTP_4_2_7P285 + + ntpq/ntpq-opts.c@1.287 +4 -4 + NTP_4_2_7P285 + + ntpq/ntpq-opts.h@1.287 +3 -3 + NTP_4_2_7P285 + + ntpq/ntpq-opts.texi@1.274.4.1 +2 -2 + NTP_4_2_7P285 + + ntpq/ntpq.1ntpqman@1.101 +2 -2 + NTP_4_2_7P285 + + ntpq/ntpq.1ntpqmdoc@1.101 +2 -2 + NTP_4_2_7P285 + + ntpq/ntpq.man.in@1.101 +2 -2 + NTP_4_2_7P285 + + ntpq/ntpq.mdoc.in@1.101 +2 -2 + NTP_4_2_7P285 + + ntpsnmpd/ntpsnmpd-opts.c@1.287 +4 -4 + NTP_4_2_7P285 + + ntpsnmpd/ntpsnmpd-opts.h@1.287 +3 -3 + NTP_4_2_7P285 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.4.1 +2 -2 + NTP_4_2_7P285 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.101 +2 -2 + NTP_4_2_7P285 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.101 +2 -2 + NTP_4_2_7P285 + + ntpsnmpd/ntpsnmpd.man.in@1.101 +2 -2 + NTP_4_2_7P285 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.101 +2 -2 + NTP_4_2_7P285 + + packageinfo.sh@1.288 +1 -1 + NTP_4_2_7P285 + + scripts/ntp-wait-opts.texi@1.92.4.1 +1 -1 + NTP_4_2_7P285 + + scripts/ntp-wait.1ntp-waitman@1.101 +2 -2 + NTP_4_2_7P285 + + scripts/ntp-wait.1ntp-waitmdoc@1.101 +2 -2 + NTP_4_2_7P285 + + scripts/ntp-wait.html@1.105 +1 -1 + NTP_4_2_7P285 + + scripts/ntp-wait.man.in@1.101 +2 -2 + NTP_4_2_7P285 + + scripts/ntp-wait.mdoc.in@1.101 +2 -2 + NTP_4_2_7P285 + + sntp/sntp-opts.c@1.283 +4 -4 + NTP_4_2_7P285 + + sntp/sntp-opts.h@1.283 +3 -3 + NTP_4_2_7P285 + + sntp/sntp-opts.texi@1.270.4.1 +2 -2 + NTP_4_2_7P285 + + sntp/sntp.1sntpman@1.103 +2 -2 + NTP_4_2_7P285 + + sntp/sntp.1sntpmdoc@1.103 +2 -2 + NTP_4_2_7P285 + + sntp/sntp.html@1.283 +2 -2 + NTP_4_2_7P285 + + sntp/sntp.man.in@1.103 +2 -2 + NTP_4_2_7P285 + + sntp/sntp.mdoc.in@1.103 +2 -2 + NTP_4_2_7P285 + + util/ntp-keygen-opts.c@1.287 +4 -4 + NTP_4_2_7P285 + + util/ntp-keygen-opts.h@1.287 +3 -3 + NTP_4_2_7P285 + + util/ntp-keygen-opts.texi@1.275.4.1 +2 -2 + NTP_4_2_7P285 + + util/ntp-keygen.1ntp-keygenman@1.101 +2 -2 + NTP_4_2_7P285 + + util/ntp-keygen.1ntp-keygenmdoc@1.101 +2 -2 + NTP_4_2_7P285 + + util/ntp-keygen.man.in@1.101 +2 -2 + NTP_4_2_7P285 + + util/ntp-keygen.mdoc.in@1.101 +2 -2 + NTP_4_2_7P285 + +ChangeSet@1.2773.1.43, 2012-06-18 07:49:19+00:00, stenn@psp-fb1.ntp.org + Automake-1.12 wants us to use AM_PROG_AR + + ChangeLog@1.1146.1.34 +1 -0 + Automake-1.12 wants us to use AM_PROG_AR + + configure.ac@1.546 +6 -0 + Automake-1.12 wants us to use AM_PROG_AR + + sntp/configure.ac@1.69 +6 -0 + Automake-1.12 wants us to use AM_PROG_AR + +ChangeSet@1.2773.1.42, 2012-06-18 05:18:28+00:00, davehart@dlh-7551.ad.hartbrothers.com + generated files from last cset's ntp_parser.y and keyword-gen.c changes. + + ntpd/keyword-gen-utd@1.16 +1 -1 + generated from last cset's keyword-gen.c changes. + + ntpd/ntp_keyword.h@1.18 +535 -528 + generated from last cset's keyword-gen.c changes. + + ntpd/ntp_parser.c@1.79 +806 -796 + generated from last cset's ntp_parser.y changes. + + ntpd/ntp_parser.h@1.45 +161 -159 + generated from last cset's ntp_parser.y changes. + +ChangeSet@1.2773.1.41, 2012-06-18 05:01:49+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2227] Enable mrulist access control via "restrict ... nomrulist". + Conditionalize msyslog messages about rejected mode 6 requests due to + nomodify and nomrulist restrictions under "logconfig +sysinfo". + Increment sys_restricted in a few rejection paths due to nomodify + restrictions where previosuly overlooked. + + ChangeLog@1.1146.1.33 +5 -0 + [Bug 2227] Enable mrulist access control via "restrict ... nomrulist". + Conditionalize msyslog messages about rejected mode 6 requests due to + nomodify and nomrulist restrictions under "logconfig +sysinfo". + Increment sys_restricted in a few rejection paths due to nomodify + restrictions where previosuly overlooked. + + include/ntp.h@1.205 +5 -3 + Add RES_NOMRULIST (0x2000) for "restrict ... nomrulist" + + include/ntp_request.h@1.46 +1 -0 + Make explicit MAX_INFO_ERR macro for ntp_request.c + + ntpd/complete.conf@1.22 +1 -1 + Add "nomrulist" to round-trip parser/saveconfig test. + + ntpd/keyword-gen.c@1.21 +1 -0 + Add "nomrulist" / T_Nomrulist + + ntpd/ntp_config.c@1.299 +4 -0 + [Bug 2227] Enable mrulist access control via "restrict ... nomrulist". + + ntpd/ntp_control.c@1.181 +24 -10 + [Bug 2227] Enable mrulist access control via "restrict ... nomrulist". + Conditionalize msyslog messages about rejected mode 6 requests due to + nomodify and nomrulist restrictions under "logconfig +sysinfo". + Increment sys_restricted in a few rejection paths due to nomodify + restrictions where previosuly overlooked. + + ntpd/ntp_parser.y@1.73 +2 -0 + Add, use "nomrulist" restriction. + + ntpd/ntp_request.c@1.110 +7 -2 + Increment sys_restricted in a few rejection paths due to nomodify + restrictions where previosuly overlooked. + Use explicit MAX_INFO_ERR macro instead of implicitly assuming + INFO_ERR_AUTH is the highest-numbered. + +ChangeSet@1.2773.1.40, 2012-06-16 21:36:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P284 + TAG: NTP_4_2_7P284 + + ChangeLog@1.1146.1.32 +1 -0 + NTP_4_2_7P284 + + ntpd/ntpd-opts.c@1.289 +4 -4 + NTP_4_2_7P284 + + ntpd/ntpd-opts.h@1.289 +3 -3 + NTP_4_2_7P284 + + ntpd/ntpd-opts.texi@1.275.3.6 +2 -2 + NTP_4_2_7P284 + + ntpd/ntpd.1ntpdman@1.100 +2 -2 + NTP_4_2_7P284 + + ntpd/ntpd.1ntpdmdoc@1.100 +1 -1 + NTP_4_2_7P284 + + ntpd/ntpd.man.in@1.100 +2 -2 + NTP_4_2_7P284 + + ntpd/ntpd.mdoc.in@1.100 +1 -1 + NTP_4_2_7P284 + + ntpdc/ntpdc-opts.c@1.284 +4 -4 + NTP_4_2_7P284 + + ntpdc/ntpdc-opts.h@1.284 +3 -3 + NTP_4_2_7P284 + + ntpdc/ntpdc-opts.texi@1.272.3.6 +2 -2 + NTP_4_2_7P284 + + ntpdc/ntpdc.1ntpdcman@1.100 +2 -2 + NTP_4_2_7P284 + + ntpdc/ntpdc.1ntpdcmdoc@1.100 +1 -1 + NTP_4_2_7P284 + + ntpdc/ntpdc.html@1.112 +2 -2 + NTP_4_2_7P284 + + ntpdc/ntpdc.man.in@1.100 +2 -2 + NTP_4_2_7P284 + + ntpdc/ntpdc.mdoc.in@1.100 +1 -1 + NTP_4_2_7P284 + + ntpq/ntpq-opts.c@1.286 +4 -4 + NTP_4_2_7P284 + + ntpq/ntpq-opts.h@1.286 +3 -3 + NTP_4_2_7P284 + + ntpq/ntpq-opts.texi@1.274.3.6 +2 -2 + NTP_4_2_7P284 + + ntpq/ntpq.1ntpqman@1.100 +2 -2 + NTP_4_2_7P284 + + ntpq/ntpq.1ntpqmdoc@1.100 +1 -1 + NTP_4_2_7P284 + + ntpq/ntpq.man.in@1.100 +2 -2 + NTP_4_2_7P284 + + ntpq/ntpq.mdoc.in@1.100 +1 -1 + NTP_4_2_7P284 + + ntpsnmpd/ntpsnmpd-opts.c@1.286 +4 -4 + NTP_4_2_7P284 + + ntpsnmpd/ntpsnmpd-opts.h@1.286 +3 -3 + NTP_4_2_7P284 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.3.6 +2 -2 + NTP_4_2_7P284 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.100 +2 -2 + NTP_4_2_7P284 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.100 +1 -1 + NTP_4_2_7P284 + + ntpsnmpd/ntpsnmpd.man.in@1.100 +2 -2 + NTP_4_2_7P284 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.100 +1 -1 + NTP_4_2_7P284 + + packageinfo.sh@1.287 +1 -1 + NTP_4_2_7P284 + + scripts/ntp-wait-opts.texi@1.92.3.6 +1 -1 + NTP_4_2_7P284 + + scripts/ntp-wait.1ntp-waitman@1.100 +2 -2 + NTP_4_2_7P284 + + scripts/ntp-wait.1ntp-waitmdoc@1.100 +1 -1 + NTP_4_2_7P284 + + scripts/ntp-wait.html@1.104 +1 -1 + NTP_4_2_7P284 + + scripts/ntp-wait.man.in@1.100 +2 -2 + NTP_4_2_7P284 + + scripts/ntp-wait.mdoc.in@1.100 +1 -1 + NTP_4_2_7P284 + + sntp/sntp-opts.c@1.282 +4 -4 + NTP_4_2_7P284 + + sntp/sntp-opts.h@1.282 +3 -3 + NTP_4_2_7P284 + + sntp/sntp-opts.texi@1.270.3.6 +2 -2 + NTP_4_2_7P284 + + sntp/sntp.1sntpman@1.102 +2 -2 + NTP_4_2_7P284 + + sntp/sntp.1sntpmdoc@1.102 +1 -1 + NTP_4_2_7P284 + + sntp/sntp.html@1.282 +2 -2 + NTP_4_2_7P284 + + sntp/sntp.man.in@1.102 +2 -2 + NTP_4_2_7P284 + + sntp/sntp.mdoc.in@1.102 +1 -1 + NTP_4_2_7P284 + + util/ntp-keygen-opts.c@1.286 +4 -4 + NTP_4_2_7P284 + + util/ntp-keygen-opts.h@1.286 +3 -3 + NTP_4_2_7P284 + + util/ntp-keygen-opts.texi@1.275.3.6 +2 -2 + NTP_4_2_7P284 + + util/ntp-keygen.1ntp-keygenman@1.100 +2 -2 + NTP_4_2_7P284 + + util/ntp-keygen.1ntp-keygenmdoc@1.100 +1 -1 + NTP_4_2_7P284 + + util/ntp-keygen.man.in@1.100 +2 -2 + NTP_4_2_7P284 + + util/ntp-keygen.mdoc.in@1.100 +1 -1 + NTP_4_2_7P284 + +ChangeSet@1.2773.3.3, 2012-06-16 11:23:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P283 + TAG: NTP_4_2_7P283 + + ChangeLog@1.1146.3.1 +1 -0 + NTP_4_2_7P283 + + ntpd/ntpd-opts.c@1.288 +4 -4 + NTP_4_2_7P283 + + ntpd/ntpd-opts.h@1.288 +3 -3 + NTP_4_2_7P283 + + ntpd/ntpd-opts.texi@1.275.3.5 +2 -2 + NTP_4_2_7P283 + + ntpd/ntpd.1ntpdman@1.99 +2 -2 + NTP_4_2_7P283 + + ntpd/ntpd.1ntpdmdoc@1.99 +2 -2 + NTP_4_2_7P283 + + ntpd/ntpd.man.in@1.99 +2 -2 + NTP_4_2_7P283 + + ntpd/ntpd.mdoc.in@1.99 +2 -2 + NTP_4_2_7P283 + + ntpdc/ntpdc-opts.c@1.283 +4 -4 + NTP_4_2_7P283 + + ntpdc/ntpdc-opts.h@1.283 +3 -3 + NTP_4_2_7P283 + + ntpdc/ntpdc-opts.texi@1.272.3.5 +2 -2 + NTP_4_2_7P283 + + ntpdc/ntpdc.1ntpdcman@1.99 +2 -2 + NTP_4_2_7P283 + + ntpdc/ntpdc.1ntpdcmdoc@1.99 +2 -2 + NTP_4_2_7P283 + + ntpdc/ntpdc.html@1.111 +2 -2 + NTP_4_2_7P283 + + ntpdc/ntpdc.man.in@1.99 +2 -2 + NTP_4_2_7P283 + + ntpdc/ntpdc.mdoc.in@1.99 +2 -2 + NTP_4_2_7P283 + + ntpq/ntpq-opts.c@1.285 +4 -4 + NTP_4_2_7P283 + + ntpq/ntpq-opts.h@1.285 +3 -3 + NTP_4_2_7P283 + + ntpq/ntpq-opts.texi@1.274.3.5 +2 -2 + NTP_4_2_7P283 + + ntpq/ntpq.1ntpqman@1.99 +2 -2 + NTP_4_2_7P283 + + ntpq/ntpq.1ntpqmdoc@1.99 +2 -2 + NTP_4_2_7P283 + + ntpq/ntpq.man.in@1.99 +2 -2 + NTP_4_2_7P283 + + ntpq/ntpq.mdoc.in@1.99 +2 -2 + NTP_4_2_7P283 + + ntpsnmpd/ntpsnmpd-opts.c@1.285 +4 -4 + NTP_4_2_7P283 + + ntpsnmpd/ntpsnmpd-opts.h@1.285 +3 -3 + NTP_4_2_7P283 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.3.5 +2 -2 + NTP_4_2_7P283 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.99 +2 -2 + NTP_4_2_7P283 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.99 +2 -2 + NTP_4_2_7P283 + + ntpsnmpd/ntpsnmpd.man.in@1.99 +2 -2 + NTP_4_2_7P283 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.99 +2 -2 + NTP_4_2_7P283 + + packageinfo.sh@1.286 +1 -1 + NTP_4_2_7P283 + + scripts/ntp-wait-opts.texi@1.92.3.5 +1 -1 + NTP_4_2_7P283 + + scripts/ntp-wait.1ntp-waitman@1.99 +2 -2 + NTP_4_2_7P283 + + scripts/ntp-wait.1ntp-waitmdoc@1.99 +2 -2 + NTP_4_2_7P283 + + scripts/ntp-wait.html@1.103 +1 -1 + NTP_4_2_7P283 + + scripts/ntp-wait.man.in@1.99 +2 -2 + NTP_4_2_7P283 + + scripts/ntp-wait.mdoc.in@1.99 +2 -2 + NTP_4_2_7P283 + + sntp/sntp-opts.c@1.281 +4 -4 + NTP_4_2_7P283 + + sntp/sntp-opts.h@1.281 +3 -3 + NTP_4_2_7P283 + + sntp/sntp-opts.texi@1.270.3.5 +2 -2 + NTP_4_2_7P283 + + sntp/sntp.1sntpman@1.101 +2 -2 + NTP_4_2_7P283 + + sntp/sntp.1sntpmdoc@1.101 +2 -2 + NTP_4_2_7P283 + + sntp/sntp.html@1.281 +2 -2 + NTP_4_2_7P283 + + sntp/sntp.man.in@1.101 +2 -2 + NTP_4_2_7P283 + + sntp/sntp.mdoc.in@1.101 +2 -2 + NTP_4_2_7P283 + + util/ntp-keygen-opts.c@1.285 +4 -4 + NTP_4_2_7P283 + + util/ntp-keygen-opts.h@1.285 +3 -3 + NTP_4_2_7P283 + + util/ntp-keygen-opts.texi@1.275.3.5 +2 -2 + NTP_4_2_7P283 + + util/ntp-keygen.1ntp-keygenman@1.99 +2 -2 + NTP_4_2_7P283 + + util/ntp-keygen.1ntp-keygenmdoc@1.99 +2 -2 + NTP_4_2_7P283 + + util/ntp-keygen.man.in@1.99 +2 -2 + NTP_4_2_7P283 + + util/ntp-keygen.mdoc.in@1.99 +2 -2 + NTP_4_2_7P283 + +ChangeSet@1.2773.1.38, 2012-06-16 05:58:30+00:00, davehart@dlh-7551.ad.hartbrothers.com + Update ChangeLog for libevent update and [Bug 2225]. + + ChangeLog@1.1146.1.30 +2 -0 + [Bug 2225] libevent configure hangs. + Update bundled libevent to git master, post libevent 2.1.1-alpha. + + +ChangeSet@1.2773.1.36, 2012-06-16 04:51:53+00:00, davehart@dlh-7551.ad.hartbrothers.com + Linux 2.6.26 and earlier will fail libevent's timerfd_create() call due to + nonzero flags, yet some systems using that version have the nonworking + flags in their header files (Debian Lenny). Do not spew warnings in + regress output in that case, and set epollop->timerfd = -1. Suggested + by Nick Mathewson. + + sntp/libevent/epoll.c@1.4 +4 -1 + Linux 2.6.26 and earlier will fail libevent's timerfd_create() call due to + nonzero flags, yet some systems using that version have the nonworking + flags in their header files (Debian Lenny). Do not spew warnings in + regress output in that case, and set epollop->timerfd = -1. Suggested + by Nick Mathewson. + +ChangeSet@1.2773.3.2, 2012-06-16 03:45:09+00:00, stenn@poog.il.thewrittenword.com + Improvements to sntp/m4/ntp_openssl.m4 + + ChangeLog@1.1146.1.29 +2 -0 + Improvements to sntp/m4/ntp_openssl.m4 + + sntp/m4/ntp_openssl.m4@1.21 +35 -16 + Improvements to sntp/m4/ntp_openssl.m4 + +ChangeSet@1.2773.3.1, 2012-06-15 11:22:51+00:00, stenn@deacon.udel.edu + NTP_4_2_7P282 + TAG: NTP_4_2_7P282 + + ChangeLog@1.1146.1.28 +1 -0 + NTP_4_2_7P282 + + ntpd/ntpd-opts.c@1.287 +4 -4 + NTP_4_2_7P282 + + ntpd/ntpd-opts.h@1.287 +3 -3 + NTP_4_2_7P282 + + ntpd/ntpd-opts.texi@1.275.3.4 +2 -2 + NTP_4_2_7P282 + + ntpd/ntpd.1ntpdman@1.98 +2 -2 + NTP_4_2_7P282 + + ntpd/ntpd.1ntpdmdoc@1.98 +2 -2 + NTP_4_2_7P282 + + ntpd/ntpd.man.in@1.98 +2 -2 + NTP_4_2_7P282 + + ntpd/ntpd.mdoc.in@1.98 +2 -2 + NTP_4_2_7P282 + + ntpdc/ntpdc-opts.c@1.282 +4 -4 + NTP_4_2_7P282 + + ntpdc/ntpdc-opts.h@1.282 +3 -3 + NTP_4_2_7P282 + + ntpdc/ntpdc-opts.texi@1.272.3.4 +2 -2 + NTP_4_2_7P282 + + ntpdc/ntpdc.1ntpdcman@1.98 +2 -2 + NTP_4_2_7P282 + + ntpdc/ntpdc.1ntpdcmdoc@1.98 +2 -2 + NTP_4_2_7P282 + + ntpdc/ntpdc.html@1.110 +2 -2 + NTP_4_2_7P282 + + ntpdc/ntpdc.man.in@1.98 +2 -2 + NTP_4_2_7P282 + + ntpdc/ntpdc.mdoc.in@1.98 +2 -2 + NTP_4_2_7P282 + + ntpq/ntpq-opts.c@1.284 +4 -4 + NTP_4_2_7P282 + + ntpq/ntpq-opts.h@1.284 +3 -3 + NTP_4_2_7P282 + + ntpq/ntpq-opts.texi@1.274.3.4 +2 -2 + NTP_4_2_7P282 + + ntpq/ntpq.1ntpqman@1.98 +2 -2 + NTP_4_2_7P282 + + ntpq/ntpq.1ntpqmdoc@1.98 +2 -2 + NTP_4_2_7P282 + + ntpq/ntpq.man.in@1.98 +2 -2 + NTP_4_2_7P282 + + ntpq/ntpq.mdoc.in@1.98 +2 -2 + NTP_4_2_7P282 + + ntpsnmpd/ntpsnmpd-opts.c@1.284 +4 -4 + NTP_4_2_7P282 + + ntpsnmpd/ntpsnmpd-opts.h@1.284 +3 -3 + NTP_4_2_7P282 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.3.4 +2 -2 + NTP_4_2_7P282 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.98 +2 -2 + NTP_4_2_7P282 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.98 +2 -2 + NTP_4_2_7P282 + + ntpsnmpd/ntpsnmpd.man.in@1.98 +2 -2 + NTP_4_2_7P282 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.98 +2 -2 + NTP_4_2_7P282 + + packageinfo.sh@1.285 +1 -1 + NTP_4_2_7P282 + + scripts/ntp-wait-opts.texi@1.92.3.4 +1 -1 + NTP_4_2_7P282 + + scripts/ntp-wait.1ntp-waitman@1.98 +2 -2 + NTP_4_2_7P282 + + scripts/ntp-wait.1ntp-waitmdoc@1.98 +2 -2 + NTP_4_2_7P282 + + scripts/ntp-wait.html@1.102 +1 -1 + NTP_4_2_7P282 + + scripts/ntp-wait.man.in@1.98 +2 -2 + NTP_4_2_7P282 + + scripts/ntp-wait.mdoc.in@1.98 +2 -2 + NTP_4_2_7P282 + + sntp/sntp-opts.c@1.280 +4 -4 + NTP_4_2_7P282 + + sntp/sntp-opts.h@1.280 +3 -3 + NTP_4_2_7P282 + + sntp/sntp-opts.texi@1.270.3.4 +2 -2 + NTP_4_2_7P282 + + sntp/sntp.1sntpman@1.100 +2 -2 + NTP_4_2_7P282 + + sntp/sntp.1sntpmdoc@1.100 +2 -2 + NTP_4_2_7P282 + + sntp/sntp.html@1.280 +2 -2 + NTP_4_2_7P282 + + sntp/sntp.man.in@1.100 +2 -2 + NTP_4_2_7P282 + + sntp/sntp.mdoc.in@1.100 +2 -2 + NTP_4_2_7P282 + + util/ntp-keygen-opts.c@1.284 +4 -4 + NTP_4_2_7P282 + + util/ntp-keygen-opts.h@1.284 +3 -3 + NTP_4_2_7P282 + + util/ntp-keygen-opts.texi@1.275.3.4 +2 -2 + NTP_4_2_7P282 + + util/ntp-keygen.1ntp-keygenman@1.98 +2 -2 + NTP_4_2_7P282 + + util/ntp-keygen.1ntp-keygenmdoc@1.98 +2 -2 + NTP_4_2_7P282 + + util/ntp-keygen.man.in@1.98 +2 -2 + NTP_4_2_7P282 + + util/ntp-keygen.mdoc.in@1.98 +2 -2 + NTP_4_2_7P282 + +ChangeSet@1.2773.1.35, 2012-06-14 23:17:32+00:00, davehart@dlh-7551.ad.hartbrothers.com + repair merge flub + keep local-to-NTP patch up to date with event-config.h s/_EVENT/EVENT_/ + + sntp/libevent/configure.in@1.11 +3 -0 + repair merge flub + + sntp/libevent/evthread_pthread.c@1.5 +1 -1 + keep local-to-NTP patch up to date with event-config.h s/_EVENT/EVENT_/ + +ChangeSet@1.2461.1.10, 2012-06-14 22:20:00+00:00, davehart@dlh-7551.ad.hartbrothers.com + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/ChangeLog@1.6 +289 -1127 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/ChangeLog-1.4@1.1 +231 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/ChangeLog-1.4 + + sntp/libevent/ChangeLog-1.4@1.0 +0 -0 + + sntp/libevent/ChangeLog-2.0@1.1 +1225 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/ChangeLog-2.0 + + sntp/libevent/ChangeLog-2.0@1.0 +0 -0 + + sntp/libevent/Doxyfile@1.3 +1 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/LICENSE@1.2 +26 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/Makefile.am@1.1.1.6 +83 -44 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/Makefile.nmake@1.3 +5 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/README@1.5 +41 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/WIN32-Code/evconfig-private.h@1.2 +2 -2 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/WIN32-Code/event2/event-config.h@1.1.1.3 +115 -115 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/arc4random.c@1.1.1.3 +20 -19 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/buffer.c@1.7 +432 -175 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/buffer_iocp.c@1.5 +19 -19 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent-internal.h@1.5 +48 -34 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent.c@1.5 +77 -55 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent_async.c@1.5 +74 -74 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent_filter.c@1.5 +33 -33 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent_openssl.c@1.6 +171 -60 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent_pair.c@1.5 +13 -13 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent_ratelim.c@1.4 +170 -107 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/bufferevent_sock.c@1.5 +49 -49 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/changelist-internal.h@1.2 +8 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/compat/sys/queue.h@1.3 +3 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/configure.in@1.1.1.5 +110 -23 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/defer-internal.h@1.4 +9 -9 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/devpoll.c@1.3 +10 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/epoll.c@1.3 +116 -21 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/epoll_sub.c@1.3 +1 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evbuffer-internal.h@1.5 +39 -22 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evconfig-private.h.in@1.2 +7 -2 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evdns.c@1.1.1.5 +171 -101 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/event-internal.h@1.1.1.5 +55 -30 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/event.c@1.1.1.6 +731 -460 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/event_iocp.c@1.5 +13 -13 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/event_rpcgen.py@1.2 +17 -16 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/event_tagging.c@1.4 +5 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evmap-internal.h@1.2 +42 -15 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evmap.c@1.5 +359 -68 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evport.c@1.1.1.3 +13 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evrpc-internal.h@1.2 +11 -11 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evrpc.c@1.5 +24 -24 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evsignal-internal.h@1.2 +9 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evthread-internal.h@1.5 +112 -102 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evthread.c@1.1.1.4 +100 -85 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evthread_pthread.c@1.1.1.2 +16 -16 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evthread_win32.c@1.5 +24 -23 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evutil.c@1.1.1.5 +511 -168 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evutil_rand.c@1.5 +49 -14 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/evutil_time.c@1.1 +485 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/evutil_time.c + + sntp/libevent/evutil_time.c@1.0 +0 -0 + + sntp/libevent/ht-internal.h@1.3 +52 -48 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/http-internal.h@1.3 +17 -12 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/http.c@1.1.1.6 +197 -150 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/Makefile.am@1.1.1.2 +6 -0 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/evdns.h@1.4 +5 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/evdns.h@1.3 +0 -0 + Rename: sntp/libevent/evdns.h -> sntp/libevent/include/evdns.h + + sntp/libevent/include/event.h@1.5 +7 -7 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event.h@1.4 +0 -0 + Rename: sntp/libevent/event.h -> sntp/libevent/include/event.h + + sntp/libevent/include/event2/buffer.h@1.4 +100 -16 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/buffer_compat.h@1.3 +3 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/bufferevent.h@1.3 +55 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/bufferevent_compat.h@1.3 +3 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/bufferevent_ssl.h@1.3 +25 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/bufferevent_struct.h@1.3 +6 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/dns.h@1.5 +12 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/dns_compat.h@1.4 +6 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/dns_struct.h@1.3 +6 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/event.h@1.1.1.5 +142 -20 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/event_compat.h@1.4 +6 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/event_struct.h@1.3 +32 -14 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/http.h@1.4 +70 -10 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/http_compat.h@1.3 +6 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/http_struct.h@1.3 +6 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/keyvalq_struct.h@1.2 +7 -7 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/listener.h@1.2 +20 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/rpc.h@1.3 +8 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/rpc_compat.h@1.3 +4 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/rpc_struct.h@1.3 +4 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/tag.h@1.3 +6 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/tag_compat.h@1.3 +4 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/thread.h@1.4 +11 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/event2/util.h@1.4 +93 -64 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/evhttp.h@1.4 +5 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/evhttp.h@1.3 +0 -0 + Rename: sntp/libevent/evhttp.h -> sntp/libevent/include/evhttp.h + + sntp/libevent/include/evrpc.h@1.4 +5 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/evrpc.h@1.3 +0 -0 + Rename: sntp/libevent/evrpc.h -> sntp/libevent/include/evrpc.h + + sntp/libevent/include/evutil.h@1.4 +4 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/include/evutil.h@1.3 +0 -0 + Rename: sntp/libevent/evutil.h -> sntp/libevent/include/evutil.h + + sntp/libevent/iocp-internal.h@1.3 +28 -28 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/ipv6-internal.h@1.1.1.2 +7 -7 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/kqueue-internal.h@1.1 +39 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/kqueue-internal.h + + sntp/libevent/kqueue-internal.h@1.0 +0 -0 + + sntp/libevent/kqueue.c@1.6 +98 -16 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/listener.c@1.5 +48 -45 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/log-internal.h@1.2 +29 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/log.c@1.4 +36 -17 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/m4/libevent_openssl.m4@1.2 +3 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/make-event-config.sed@1.1 +23 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/make-event-config.sed + + sntp/libevent/make-event-config.sed@1.0 +0 -0 + + sntp/libevent/minheap-internal.h@1.4 +30 -30 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/mm-internal.h@1.2 +31 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/poll.c@1.3 +22 -15 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/ratelim-internal.h@1.2 +7 -7 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/sample/Makefile.am@1.1.1.5 +21 -9 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/sample/dns-example.c@1.1.1.4 +28 -7 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/sample/event-read-fifo.c@1.4 +45 -26 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/sample/event-read-fifo.c@1.3 +0 -0 + Rename: sntp/libevent/sample/event-test.c -> sntp/libevent/sample/event-read-fifo.c + + sntp/libevent/sample/http-server.c@1.1.1.5 +5 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/sample/signal-test.c@1.3 +7 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/sample/time-test.c@1.3 +1 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/select.c@1.1.1.4 +14 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/signal.c@1.6 +65 -32 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/strlcpy-internal.h@1.3 +5 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/strlcpy.c@1.3 +2 -2 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/Makefile.am@1.1.1.5 +60 -13 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/bench.c@1.3 +3 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/bench_cascade.c@1.3 +3 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/bench_http.c@1.4 +1 -3 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/bench_httpclient.c@1.1.1.3 +4 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/check-dumpevents.py@1.2 +0 -0 + Change mode to -rwxr-xr-x + + sntp/libevent/test/check-dumpevents.py@1.1 +54 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/test/check-dumpevents.py + + sntp/libevent/test/check-dumpevents.py@1.0 +0 -0 + + sntp/libevent/test/regress.c@1.3 +273 -86 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress.h@1.3 +10 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_buffer.c@1.5 +331 -16 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_bufferevent.c@1.3 +21 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_dns.c@1.1.1.3 +186 -33 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_et.c@1.3 +16 -8 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_http.c@1.1.1.4 +47 -40 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_iocp.c@1.2 +29 -29 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_listener.c@1.1.1.3 +5 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_main.c@1.4 +38 -10 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_minheap.c@1.2 +11 -11 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_rpc.c@1.4 +7 -7 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_ssl.c@1.4 +1 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_testutils.c@1.1.1.3 +21 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_testutils.h@1.2 +4 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_thread.c@1.3 +104 -25 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_util.c@1.4 +262 -23 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/regress_zlib.c@1.3 +1 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test-changelist.c@1.3 +31 -5 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test-dumpevents.c@1.1 +180 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/test/test-dumpevents.c + + sntp/libevent/test/test-dumpevents.c@1.0 +0 -0 + + sntp/libevent/test/test-eof.c@1.1.1.3 +28 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test-fdleak.c@1.1 +249 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/test/test-fdleak.c + + sntp/libevent/test/test-fdleak.c@1.0 +0 -0 + + sntp/libevent/test/test-init.c@1.3 +26 -4 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test-ratelim.c@1.1.1.4 +124 -9 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test-ratelim.sh@1.3 +11 -0 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test-time.c@1.3 +24 -2 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test-weof.c@1.3 +28 -6 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/test.sh@1.1.1.3 +48 -52 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/tinytest.c@1.4 +31 -20 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/tinytest.h@1.2 +9 -9 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/tinytest_demo.c@1.2 +2 -2 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/tinytest_local.h@1.3 +1 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/test/tinytest_macros.h@1.2 +39 -39 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/time-internal.h@1.1 +101 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/time-internal.h + + sntp/libevent/time-internal.h@1.0 +0 -0 + + sntp/libevent/util-internal.h@1.1.1.4 +181 -47 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/whatsnew-2.0.txt@1.3 +1 -1 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + + sntp/libevent/whatsnew-2.1.txt@1.1 +390 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/whatsnew-2.1.txt + + sntp/libevent/whatsnew-2.1.txt@1.0 +0 -0 + + sntp/libevent/win32select.c@1.3 +30 -20 + update to libevent git master, after 2.1.1-alpha, as of 14-Jun-2012 git cset + e7bf4c84afd7961eb92a2d6583c84b56a87f2555 + +ChangeSet@1.2773.1.33, 2012-06-14 07:53:00-04:00, stenn@deacon.udel.edu + tickadj may need to be linked with PTHREAD_LIBS + + ChangeLog@1.1146.1.27 +1 -0 + tickadj may need to be linked with PTHREAD_LIBS + + util/Makefile.am@1.71.1.2 +1 -1 + tickadj may need to be linked with PTHREAD_LIBS + +ChangeSet@1.2773.1.32, 2012-06-14 11:24:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P281 + TAG: NTP_4_2_7P281 + + ChangeLog@1.1146.1.26 +1 -0 + NTP_4_2_7P281 + + ntpd/ntpd-opts.c@1.286 +4 -4 + NTP_4_2_7P281 + + ntpd/ntpd-opts.h@1.286 +3 -3 + NTP_4_2_7P281 + + ntpd/ntpd-opts.texi@1.275.3.3 +2 -2 + NTP_4_2_7P281 + + ntpd/ntpd.1ntpdman@1.97 +2 -2 + NTP_4_2_7P281 + + ntpd/ntpd.1ntpdmdoc@1.97 +2 -2 + NTP_4_2_7P281 + + ntpd/ntpd.man.in@1.97 +2 -2 + NTP_4_2_7P281 + + ntpd/ntpd.mdoc.in@1.97 +2 -2 + NTP_4_2_7P281 + + ntpdc/ntpdc-opts.c@1.281 +4 -4 + NTP_4_2_7P281 + + ntpdc/ntpdc-opts.h@1.281 +3 -3 + NTP_4_2_7P281 + + ntpdc/ntpdc-opts.texi@1.272.3.3 +2 -2 + NTP_4_2_7P281 + + ntpdc/ntpdc.1ntpdcman@1.97 +2 -2 + NTP_4_2_7P281 + + ntpdc/ntpdc.1ntpdcmdoc@1.97 +2 -2 + NTP_4_2_7P281 + + ntpdc/ntpdc.html@1.109 +2 -2 + NTP_4_2_7P281 + + ntpdc/ntpdc.man.in@1.97 +2 -2 + NTP_4_2_7P281 + + ntpdc/ntpdc.mdoc.in@1.97 +2 -2 + NTP_4_2_7P281 + + ntpq/ntpq-opts.c@1.283 +4 -4 + NTP_4_2_7P281 + + ntpq/ntpq-opts.h@1.283 +3 -3 + NTP_4_2_7P281 + + ntpq/ntpq-opts.texi@1.274.3.3 +2 -2 + NTP_4_2_7P281 + + ntpq/ntpq.1ntpqman@1.97 +2 -2 + NTP_4_2_7P281 + + ntpq/ntpq.1ntpqmdoc@1.97 +2 -2 + NTP_4_2_7P281 + + ntpq/ntpq.man.in@1.97 +2 -2 + NTP_4_2_7P281 + + ntpq/ntpq.mdoc.in@1.97 +2 -2 + NTP_4_2_7P281 + + ntpsnmpd/ntpsnmpd-opts.c@1.283 +4 -4 + NTP_4_2_7P281 + + ntpsnmpd/ntpsnmpd-opts.h@1.283 +3 -3 + NTP_4_2_7P281 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.3.3 +2 -2 + NTP_4_2_7P281 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.97 +2 -2 + NTP_4_2_7P281 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.97 +2 -2 + NTP_4_2_7P281 + + ntpsnmpd/ntpsnmpd.man.in@1.97 +2 -2 + NTP_4_2_7P281 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.97 +2 -2 + NTP_4_2_7P281 + + packageinfo.sh@1.284 +1 -1 + NTP_4_2_7P281 + + scripts/ntp-wait-opts.texi@1.92.3.3 +14 -2 + NTP_4_2_7P281 + + scripts/ntp-wait.1ntp-waitman@1.97 +2 -2 + NTP_4_2_7P281 + + scripts/ntp-wait.1ntp-waitmdoc@1.97 +2 -2 + NTP_4_2_7P281 + + scripts/ntp-wait.html@1.101 +14 -2 + NTP_4_2_7P281 + + scripts/ntp-wait.man.in@1.97 +2 -2 + NTP_4_2_7P281 + + scripts/ntp-wait.mdoc.in@1.97 +2 -2 + NTP_4_2_7P281 + + sntp/sntp-opts.c@1.279 +4 -4 + NTP_4_2_7P281 + + sntp/sntp-opts.h@1.279 +3 -3 + NTP_4_2_7P281 + + sntp/sntp-opts.texi@1.270.3.3 +2 -2 + NTP_4_2_7P281 + + sntp/sntp.1sntpman@1.99 +2 -2 + NTP_4_2_7P281 + + sntp/sntp.1sntpmdoc@1.99 +2 -2 + NTP_4_2_7P281 + + sntp/sntp.html@1.279 +2 -2 + NTP_4_2_7P281 + + sntp/sntp.man.in@1.99 +2 -2 + NTP_4_2_7P281 + + sntp/sntp.mdoc.in@1.99 +2 -2 + NTP_4_2_7P281 + + util/ntp-keygen-opts.c@1.283 +4 -4 + NTP_4_2_7P281 + + util/ntp-keygen-opts.h@1.283 +3 -3 + NTP_4_2_7P281 + + util/ntp-keygen-opts.texi@1.275.3.3 +2 -2 + NTP_4_2_7P281 + + util/ntp-keygen.1ntp-keygenman@1.97 +2 -2 + NTP_4_2_7P281 + + util/ntp-keygen.1ntp-keygenmdoc@1.97 +2 -2 + NTP_4_2_7P281 + + util/ntp-keygen.man.in@1.97 +2 -2 + NTP_4_2_7P281 + + util/ntp-keygen.mdoc.in@1.97 +2 -2 + NTP_4_2_7P281 + +ChangeSet@1.2773.1.31, 2012-06-14 06:38:51-04:00, stenn@deacon.udel.edu + U_INT32_MAX cleanup in include/ntp_types.h + + ChangeLog@1.1146.1.25 +1 -0 + U_INT32_MAX cleanup in include/ntp_types.h + + include/ntp_types.h@1.32 +4 -4 + U_INT32_MAX cleanup in include/ntp_types.h + +ChangeSet@1.2773.1.30, 2012-06-14 05:41:58-04:00, stenn@deacon.udel.edu + When linking, ntp_keygen and tickadj need $(LIBM) + + ChangeLog@1.1146.1.24 +1 -0 + When linking, ntp_keygen and tickadj need $(LIBM) + + util/Makefile.am@1.71.1.1 +2 -2 + When linking, ntp_keygen and tickadj need $(LIBM) + +ChangeSet@1.2773.1.29, 2012-06-13 05:35:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P280 + TAG: NTP_4_2_7P280 + + ChangeLog@1.1146.1.23 +1 -0 + NTP_4_2_7P280 + + ntpd/ntpd-opts.c@1.285 +4 -4 + NTP_4_2_7P280 + + ntpd/ntpd-opts.h@1.285 +3 -3 + NTP_4_2_7P280 + + ntpd/ntpd-opts.texi@1.275.3.2 +2 -2 + NTP_4_2_7P280 + + ntpd/ntpd.1ntpdman@1.96 +2 -2 + NTP_4_2_7P280 + + ntpd/ntpd.1ntpdmdoc@1.96 +2 -2 + NTP_4_2_7P280 + + ntpd/ntpd.man.in@1.96 +2 -2 + NTP_4_2_7P280 + + ntpd/ntpd.mdoc.in@1.96 +2 -2 + NTP_4_2_7P280 + + ntpdc/ntpdc-opts.c@1.280 +4 -4 + NTP_4_2_7P280 + + ntpdc/ntpdc-opts.h@1.280 +3 -3 + NTP_4_2_7P280 + + ntpdc/ntpdc-opts.texi@1.272.3.2 +2 -2 + NTP_4_2_7P280 + + ntpdc/ntpdc.1ntpdcman@1.96 +2 -2 + NTP_4_2_7P280 + + ntpdc/ntpdc.1ntpdcmdoc@1.96 +2 -2 + NTP_4_2_7P280 + + ntpdc/ntpdc.html@1.108 +2 -2 + NTP_4_2_7P280 + + ntpdc/ntpdc.man.in@1.96 +2 -2 + NTP_4_2_7P280 + + ntpdc/ntpdc.mdoc.in@1.96 +2 -2 + NTP_4_2_7P280 + + ntpq/ntpq-opts.c@1.282 +4 -4 + NTP_4_2_7P280 + + ntpq/ntpq-opts.h@1.282 +3 -3 + NTP_4_2_7P280 + + ntpq/ntpq-opts.texi@1.274.3.2 +2 -2 + NTP_4_2_7P280 + + ntpq/ntpq.1ntpqman@1.96 +2 -2 + NTP_4_2_7P280 + + ntpq/ntpq.1ntpqmdoc@1.96 +2 -2 + NTP_4_2_7P280 + + ntpq/ntpq.man.in@1.96 +2 -2 + NTP_4_2_7P280 + + ntpq/ntpq.mdoc.in@1.96 +2 -2 + NTP_4_2_7P280 + + ntpsnmpd/ntpsnmpd-opts.c@1.282 +4 -4 + NTP_4_2_7P280 + + ntpsnmpd/ntpsnmpd-opts.h@1.282 +3 -3 + NTP_4_2_7P280 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.3.2 +2 -2 + NTP_4_2_7P280 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.96 +2 -2 + NTP_4_2_7P280 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.96 +2 -2 + NTP_4_2_7P280 + + ntpsnmpd/ntpsnmpd.man.in@1.96 +2 -2 + NTP_4_2_7P280 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.96 +2 -2 + NTP_4_2_7P280 + + packageinfo.sh@1.283 +1 -1 + NTP_4_2_7P280 + + scripts/ntp-wait-opts.texi@1.92.3.2 +2 -14 + NTP_4_2_7P280 + + scripts/ntp-wait.1ntp-waitman@1.96 +2 -2 + NTP_4_2_7P280 + + scripts/ntp-wait.1ntp-waitmdoc@1.96 +2 -2 + NTP_4_2_7P280 + + scripts/ntp-wait.html@1.100 +2 -14 + NTP_4_2_7P280 + + scripts/ntp-wait.man.in@1.96 +2 -2 + NTP_4_2_7P280 + + scripts/ntp-wait.mdoc.in@1.96 +2 -2 + NTP_4_2_7P280 + + sntp/sntp-opts.c@1.278 +4 -4 + NTP_4_2_7P280 + + sntp/sntp-opts.h@1.278 +3 -3 + NTP_4_2_7P280 + + sntp/sntp-opts.texi@1.270.3.2 +2 -2 + NTP_4_2_7P280 + + sntp/sntp.1sntpman@1.98 +2 -2 + NTP_4_2_7P280 + + sntp/sntp.1sntpmdoc@1.98 +2 -2 + NTP_4_2_7P280 + + sntp/sntp.html@1.278 +2 -2 + NTP_4_2_7P280 + + sntp/sntp.man.in@1.98 +2 -2 + NTP_4_2_7P280 + + sntp/sntp.mdoc.in@1.98 +2 -2 + NTP_4_2_7P280 + + util/ntp-keygen-opts.c@1.282 +4 -4 + NTP_4_2_7P280 + + util/ntp-keygen-opts.h@1.282 +3 -3 + NTP_4_2_7P280 + + util/ntp-keygen-opts.texi@1.275.3.2 +2 -2 + NTP_4_2_7P280 + + util/ntp-keygen.1ntp-keygenman@1.96 +2 -2 + NTP_4_2_7P280 + + util/ntp-keygen.1ntp-keygenmdoc@1.96 +2 -2 + NTP_4_2_7P280 + + util/ntp-keygen.man.in@1.96 +2 -2 + NTP_4_2_7P280 + + util/ntp-keygen.mdoc.in@1.96 +2 -2 + NTP_4_2_7P280 + +ChangeSet@1.2773.1.28, 2012-06-11 17:22:29+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2224] Use-after-free in routing socket code after dropping root. + + ChangeLog@1.1146.1.22 +2 -1 + [Bug 2224] Use-after-free in routing socket code after dropping root. + + ntpd/ntp_io.c@1.368 +6 -3 + [Bug 2224] Use-after-free in routing socket code after dropping root. + +ChangeSet@1.2773.1.27, 2012-06-10 06:52:04+00:00, stenn@deacon.udel.edu + NTP_4_2_7P279 + TAG: NTP_4_2_7P279 + + ChangeLog@1.1146.1.21 +1 -0 + NTP_4_2_7P279 + + ntpd/ntpd-opts.c@1.284 +4 -4 + NTP_4_2_7P279 + + ntpd/ntpd-opts.h@1.284 +3 -3 + NTP_4_2_7P279 + + ntpd/ntpd-opts.texi@1.275.3.1 +2 -2 + NTP_4_2_7P279 + + ntpd/ntpd.1ntpdman@1.95 +2 -2 + NTP_4_2_7P279 + + ntpd/ntpd.1ntpdmdoc@1.95 +2 -2 + NTP_4_2_7P279 + + ntpd/ntpd.man.in@1.95 +2 -2 + NTP_4_2_7P279 + + ntpd/ntpd.mdoc.in@1.95 +2 -2 + NTP_4_2_7P279 + + ntpdc/ntpdc-opts.c@1.279 +4 -4 + NTP_4_2_7P279 + + ntpdc/ntpdc-opts.h@1.279 +3 -3 + NTP_4_2_7P279 + + ntpdc/ntpdc-opts.texi@1.272.3.1 +2 -2 + NTP_4_2_7P279 + + ntpdc/ntpdc.1ntpdcman@1.95 +2 -2 + NTP_4_2_7P279 + + ntpdc/ntpdc.1ntpdcmdoc@1.95 +2 -2 + NTP_4_2_7P279 + + ntpdc/ntpdc.html@1.107 +2 -2 + NTP_4_2_7P279 + + ntpdc/ntpdc.man.in@1.95 +2 -2 + NTP_4_2_7P279 + + ntpdc/ntpdc.mdoc.in@1.95 +2 -2 + NTP_4_2_7P279 + + ntpq/ntpq-opts.c@1.281 +4 -4 + NTP_4_2_7P279 + + ntpq/ntpq-opts.h@1.281 +3 -3 + NTP_4_2_7P279 + + ntpq/ntpq-opts.texi@1.274.3.1 +2 -2 + NTP_4_2_7P279 + + ntpq/ntpq.1ntpqman@1.95 +2 -2 + NTP_4_2_7P279 + + ntpq/ntpq.1ntpqmdoc@1.95 +2 -2 + NTP_4_2_7P279 + + ntpq/ntpq.man.in@1.95 +2 -2 + NTP_4_2_7P279 + + ntpq/ntpq.mdoc.in@1.95 +2 -2 + NTP_4_2_7P279 + + ntpsnmpd/ntpsnmpd-opts.c@1.281 +4 -4 + NTP_4_2_7P279 + + ntpsnmpd/ntpsnmpd-opts.h@1.281 +3 -3 + NTP_4_2_7P279 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.3.1 +2 -2 + NTP_4_2_7P279 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.95 +2 -2 + NTP_4_2_7P279 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.95 +2 -2 + NTP_4_2_7P279 + + ntpsnmpd/ntpsnmpd.man.in@1.95 +2 -2 + NTP_4_2_7P279 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.95 +2 -2 + NTP_4_2_7P279 + + packageinfo.sh@1.282 +1 -1 + NTP_4_2_7P279 + + scripts/ntp-wait-opts.texi@1.92.3.1 +1 -1 + NTP_4_2_7P279 + + scripts/ntp-wait.1ntp-waitman@1.95 +2 -2 + NTP_4_2_7P279 + + scripts/ntp-wait.1ntp-waitmdoc@1.95 +2 -2 + NTP_4_2_7P279 + + scripts/ntp-wait.html@1.99 +1 -1 + NTP_4_2_7P279 + + scripts/ntp-wait.man.in@1.95 +2 -2 + NTP_4_2_7P279 + + scripts/ntp-wait.mdoc.in@1.95 +2 -2 + NTP_4_2_7P279 + + sntp/sntp-opts.c@1.277 +4 -4 + NTP_4_2_7P279 + + sntp/sntp-opts.h@1.277 +3 -3 + NTP_4_2_7P279 + + sntp/sntp-opts.texi@1.270.3.1 +2 -2 + NTP_4_2_7P279 + + sntp/sntp.1sntpman@1.97 +2 -2 + NTP_4_2_7P279 + + sntp/sntp.1sntpmdoc@1.97 +2 -2 + NTP_4_2_7P279 + + sntp/sntp.html@1.277 +2 -2 + NTP_4_2_7P279 + + sntp/sntp.man.in@1.97 +2 -2 + NTP_4_2_7P279 + + sntp/sntp.mdoc.in@1.97 +2 -2 + NTP_4_2_7P279 + + util/ntp-keygen-opts.c@1.281 +4 -4 + NTP_4_2_7P279 + + util/ntp-keygen-opts.h@1.281 +3 -3 + NTP_4_2_7P279 + + util/ntp-keygen-opts.texi@1.275.3.1 +2 -2 + NTP_4_2_7P279 + + util/ntp-keygen.1ntp-keygenman@1.95 +2 -2 + NTP_4_2_7P279 + + util/ntp-keygen.1ntp-keygenmdoc@1.95 +2 -2 + NTP_4_2_7P279 + + util/ntp-keygen.man.in@1.95 +2 -2 + NTP_4_2_7P279 + + util/ntp-keygen.mdoc.in@1.95 +2 -2 + NTP_4_2_7P279 + +ChangeSet@1.2773.1.26, 2012-06-09 14:16:49+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2211] findbcastinter(): possibly undefined variable iface used. + [Bug 2220] Incorrect check for maximum association id in ntpq. + + ChangeLog@1.1146.1.20 +3 -0 + [Bug 2211] findbcastinter(): possibly undefined variable iface used. + [Bug 2220] Incorrect check for maximum association id in ntpq. + + ntpd/ntp_io.c@1.367 +6 -4 + [Bug 2211] findbcastinter(): possibly undefined variable iface used. + + ntpq/ntpq.c@1.146 +9 -7 + [Bug 2220] Incorrect check for maximum association id in ntpq. + +ChangeSet@1.2773.1.25, 2012-06-03 08:13:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P278 + TAG: NTP_4_2_7P278 + + ChangeLog@1.1146.1.19 +1 -0 + NTP_4_2_7P278 + + ntpd/ntpd-opts.c@1.283 +4 -4 + NTP_4_2_7P278 + + ntpd/ntpd-opts.h@1.283 +3 -3 + NTP_4_2_7P278 + + ntpd/ntpd-opts.texi@1.275.2.3 +2 -2 + NTP_4_2_7P278 + + ntpd/ntpd.1ntpdman@1.94 +2 -2 + NTP_4_2_7P278 + + ntpd/ntpd.1ntpdmdoc@1.94 +2 -2 + NTP_4_2_7P278 + + ntpd/ntpd.man.in@1.94 +2 -2 + NTP_4_2_7P278 + + ntpd/ntpd.mdoc.in@1.94 +2 -2 + NTP_4_2_7P278 + + ntpdc/ntpdc-opts.c@1.278 +4 -4 + NTP_4_2_7P278 + + ntpdc/ntpdc-opts.h@1.278 +3 -3 + NTP_4_2_7P278 + + ntpdc/ntpdc-opts.texi@1.272.2.3 +2 -2 + NTP_4_2_7P278 + + ntpdc/ntpdc.1ntpdcman@1.94 +2 -2 + NTP_4_2_7P278 + + ntpdc/ntpdc.1ntpdcmdoc@1.94 +2 -2 + NTP_4_2_7P278 + + ntpdc/ntpdc.html@1.106 +2 -2 + NTP_4_2_7P278 + + ntpdc/ntpdc.man.in@1.94 +2 -2 + NTP_4_2_7P278 + + ntpdc/ntpdc.mdoc.in@1.94 +2 -2 + NTP_4_2_7P278 + + ntpq/ntpq-opts.c@1.280 +4 -4 + NTP_4_2_7P278 + + ntpq/ntpq-opts.h@1.280 +3 -3 + NTP_4_2_7P278 + + ntpq/ntpq-opts.texi@1.274.2.3 +2 -2 + NTP_4_2_7P278 + + ntpq/ntpq.1ntpqman@1.94 +2 -2 + NTP_4_2_7P278 + + ntpq/ntpq.1ntpqmdoc@1.94 +2 -2 + NTP_4_2_7P278 + + ntpq/ntpq.man.in@1.94 +2 -2 + NTP_4_2_7P278 + + ntpq/ntpq.mdoc.in@1.94 +2 -2 + NTP_4_2_7P278 + + ntpsnmpd/ntpsnmpd-opts.c@1.280 +4 -4 + NTP_4_2_7P278 + + ntpsnmpd/ntpsnmpd-opts.h@1.280 +3 -3 + NTP_4_2_7P278 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.2.3 +2 -2 + NTP_4_2_7P278 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.94 +2 -2 + NTP_4_2_7P278 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.94 +2 -2 + NTP_4_2_7P278 + + ntpsnmpd/ntpsnmpd.man.in@1.94 +2 -2 + NTP_4_2_7P278 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.94 +2 -2 + NTP_4_2_7P278 + + packageinfo.sh@1.281 +1 -1 + NTP_4_2_7P278 + + scripts/ntp-wait-opts.texi@1.92.2.3 +1 -1 + NTP_4_2_7P278 + + scripts/ntp-wait.1ntp-waitman@1.94 +2 -2 + NTP_4_2_7P278 + + scripts/ntp-wait.1ntp-waitmdoc@1.94 +2 -2 + NTP_4_2_7P278 + + scripts/ntp-wait.html@1.98 +1 -1 + NTP_4_2_7P278 + + scripts/ntp-wait.man.in@1.94 +2 -2 + NTP_4_2_7P278 + + scripts/ntp-wait.mdoc.in@1.94 +2 -2 + NTP_4_2_7P278 + + sntp/sntp-opts.c@1.276 +4 -4 + NTP_4_2_7P278 + + sntp/sntp-opts.h@1.276 +3 -3 + NTP_4_2_7P278 + + sntp/sntp-opts.texi@1.270.2.3 +2 -2 + NTP_4_2_7P278 + + sntp/sntp.1sntpman@1.96 +2 -2 + NTP_4_2_7P278 + + sntp/sntp.1sntpmdoc@1.96 +2 -2 + NTP_4_2_7P278 + + sntp/sntp.html@1.276 +2 -2 + NTP_4_2_7P278 + + sntp/sntp.man.in@1.96 +2 -2 + NTP_4_2_7P278 + + sntp/sntp.mdoc.in@1.96 +2 -2 + NTP_4_2_7P278 + + util/ntp-keygen-opts.c@1.280 +4 -4 + NTP_4_2_7P278 + + util/ntp-keygen-opts.h@1.280 +3 -3 + NTP_4_2_7P278 + + util/ntp-keygen-opts.texi@1.275.2.3 +2 -2 + NTP_4_2_7P278 + + util/ntp-keygen.1ntp-keygenman@1.94 +2 -2 + NTP_4_2_7P278 + + util/ntp-keygen.1ntp-keygenmdoc@1.94 +2 -2 + NTP_4_2_7P278 + + util/ntp-keygen.man.in@1.94 +2 -2 + NTP_4_2_7P278 + + util/ntp-keygen.mdoc.in@1.94 +2 -2 + NTP_4_2_7P278 + +ChangeSet@1.2773.1.24, 2012-06-03 07:18:47+00:00, davehart@dlh-7551.ad.hartbrothers.com + Update --enable-getifaddrs handling in ntp_ipv6.m4 to match bind 9.9.1 for + [Bug 2204] Build with --enable-getifaddrs=glibc fails + + include/isc/mem.h@1.5 +3 -3 + Clean up merge of libisc from bind-9.9.1 + some isc_mem_* are now implemented in isc__mem_* + + include/ntp_stdlib.h@1.74 +0 -19 + Clean up merge of libisc from bind-9.9.1 + __attribute__ conditionaliztion moved to config.h + + lib/isc/assertions.c@1.7 +1 -2 + Clean up merge of libisc from bind-9.9.1 + Follow libisc __attribute__((__noreturn__)) convention now there is one. + + lib/isc/include/isc/assertions.h@1.7 +1 -21 + Clean up merge of libisc from bind-9.9.1 + __attribute__ conditionaliztion moved to config.h + + lib/isc/task.c@1.7 +0 -2 + Automerge was successful where I might wish it had not been. + + lib/isc/unix/interfaceiter.c@1.25 +1 -30 + Remove NTP local addition to Linux fallback IPv6 address enumeration code + which broke --enable-getifaddrs on Linux, which is now default there with + coincident ntp_ipv6.m4 change. + + libntp/Makefile.am@1.71 +2 -0 + Clean up merge of libisc from bind-9.9.1 + task.c depends on global provided by backtrace.c + + libntp/msyslog.c@1.49 +1 -17 + Remove broken strerror_r workaround code with the real problem fixed, + which is ensuring _GNU_SOURCE is defined before the first system + header is included. + + ports/winnt/include/config.h@1.103 +2 -1 + Clean up merge of libisc from bind-9.9.1 + __attribute__ conditionaliztion moved to config.h + + ports/winnt/vs2005/libntp.vcproj@1.23 +8 -0 + Clean up merge of libisc from bind-9.9.1 + task.c depends on global provided by backtrace.c + + ports/winnt/vs2008/libntp/libntp.vcproj@1.46 +10 -2 + Clean up merge of libisc from bind-9.9.1 + task.c depends on global provided by backtrace.c + + sntp/m4/ntp_compiler.m4@1.4 +29 -0 + Clean up merge of libisc from bind-9.9.1 + __attribute__ conditionaliztion moved to config.h + + sntp/m4/ntp_ipv6.m4@1.6 +6 -39 + Update --enable-getifaddrs handling to match bind 9.9.1 configure.in + + sntp/m4/ntp_libntp.m4@1.17 +10 -4 + ensure _GNU_SOURCE is defined before any system headers are included. + +ChangeSet@1.2773.1.22, 2012-06-02 12:51:48+00:00, davehart@dlh-7551.ad.hartbrothers.com + Correct incompatible pointer type assignment warning refclock_tsyncpci.c:341 + + ntpd/refclock_tsyncpci.c@1.6 +1 -1 + Correct incompatible pointer type assignment warning refclock_tsyncpci.c:341 + +ChangeSet@1.2773.1.21, 2012-06-02 12:44:37+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2191] dcfd -Y y2kcheck on CentOS 6.2 x86_64 breaks make check. + + ChangeLog@1.1146.1.18 +1 -0 + [Bug 2191] dcfd -Y y2kcheck on CentOS 6.2 x86_64 breaks make check. + + parseutil/dcfd.c@1.25 +0 -37 + [Bug 2191] dcfd -Y y2kcheck on CentOS 6.2 x86_64 breaks make check. + Patch supplied by Frank Kardel. + +ChangeSet@1.2773.1.20, 2012-06-02 00:02:32+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ChangeLog@1.1146.1.17 +1 -0 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/ntp_io.c@1.366 +1 -1 + DPRINTF lacked \n + + ntpd/refclock_as2201.c@1.16 +0 -4 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_fg.c@1.15 +0 -3 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_heath.c@1.18 +0 -4 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_hopfser.c@1.17 +0 -1 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_jjy.c@1.25 +0 -1 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_neoclock4x.c@1.22 +0 -1 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_pst.c@1.13 +0 -4 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_tpro.c@1.14 +0 -4 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_tsyncpci.c@1.5 +0 -8 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_tt560.c@1.4 +0 -4 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + + ntpd/refclock_ulink.c@1.18 +0 -4 + [Bug 2178] refclock_tsyncpci.c reach register fails to shift. + +ChangeSet@1.2004.2.2, 2012-06-01 18:17:30+00:00, davehart@dlh-7551.ad.hartbrothers.com + unmodified bind-9.9.1 + + lib/isc/Atffile@1.1 +5 -0 + bind-9.9.1 + + lib/isc/Atffile@1.0 +0 -0 + + lib/isc/alpha/include/isc/atomic.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/api@1.2 +6 -1 + bind-9.9.1 + + lib/isc/app_api.c@1.1 +136 -0 + bind-9.9.1 + + lib/isc/app_api.c@1.0 +0 -0 + + lib/isc/assertions.c@1.4.1.1 +53 -11 + bind-9.9.1 + + lib/isc/backtrace-emptytbl.c@1.1 +34 -0 + bind-9.9.1 + + lib/isc/backtrace-emptytbl.c@1.0 +0 -0 + + lib/isc/backtrace.c@1.1 +285 -0 + bind-9.9.1 + + lib/isc/backtrace.c@1.0 +0 -0 + + lib/isc/base32.c@1.2 +3 -1 + bind-9.9.1 + + lib/isc/base64.c@1.2 +5 -3 + bind-9.9.1 + + lib/isc/entropy.c@1.2 +7 -4 + bind-9.9.1 + + lib/isc/hash.c@1.2 +17 -3 + bind-9.9.1 + + lib/isc/heap.c@1.2 +11 -8 + bind-9.9.1 + + lib/isc/hmacmd5.c@1.2 +33 -2 + bind-9.9.1 + + lib/isc/hmacsha.c@1.2 +220 -64 + bind-9.9.1 + + lib/isc/httpd.c@1.2 +58 -17 + bind-9.9.1 + + lib/isc/ia64/include/isc/atomic.h@1.2 +4 -4 + bind-9.9.1 + + lib/isc/include/isc/app.h@1.5 +168 -5 + bind-9.9.1 + + lib/isc/include/isc/assertions.h@1.4.1.1 +5 -3 + bind-9.9.1 + + lib/isc/include/isc/backtrace.h@1.1 +131 -0 + bind-9.9.1 + + lib/isc/include/isc/backtrace.h@1.0 +0 -0 + + lib/isc/include/isc/bind9.h@1.1 +30 -0 + bind-9.9.1 + + lib/isc/include/isc/bind9.h@1.0 +0 -0 + + lib/isc/include/isc/buffer.h@1.5 +2 -2 + bind-9.9.1 + + lib/isc/include/isc/entropy.h@1.2 +7 -7 + bind-9.9.1 + + lib/isc/include/isc/error.h@1.5 +5 -4 + bind-9.9.1 + + lib/isc/include/isc/file.h@1.4.1.1 +50 -2 + bind-9.9.1 + + lib/isc/include/isc/fsaccess.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/hash.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/heap.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/hmacmd5.h@1.2 +11 -2 + bind-9.9.1 + + lib/isc/include/isc/hmacsha.h@1.2 +15 -2 + bind-9.9.1 + + lib/isc/include/isc/lib.h@1.5 +11 -2 + bind-9.9.1 + + lib/isc/include/isc/list.h@1.5 +15 -2 + bind-9.9.1 + + lib/isc/include/isc/log.h@1.4 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/md5.h@1.3 +12 -2 + bind-9.9.1 + + lib/isc/include/isc/mem.h@1.6 +148 -27 + bind-9.9.1 + + lib/isc/include/isc/msgs.h@1.5.1.1 +3 -3 + bind-9.9.1 + + lib/isc/include/isc/namespace.h@1.1 +171 -0 + bind-9.9.1 + + lib/isc/include/isc/namespace.h@1.0 +0 -0 + + lib/isc/include/isc/netaddr.h@1.7 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/netscope.h@1.4 +3 -3 + bind-9.9.1 + + lib/isc/include/isc/platform.h.in@1.2 +30 -2 + bind-9.9.1 + + lib/isc/include/isc/portset.h@1.2 +2 -2 + bind-9.9.1 + + lib/isc/include/isc/queue.h@1.1 +100 -0 + bind-9.9.1 + + lib/isc/include/isc/queue.h@1.0 +0 -0 + + lib/isc/include/isc/radix.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/random.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/ratelimiter.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/refcount.h@1.2 +6 -6 + bind-9.9.1 + + lib/isc/include/isc/result.h@1.6 +5 -3 + bind-9.9.1 + + lib/isc/include/isc/resultclass.h@1.2 +3 -2 + bind-9.9.1 + + lib/isc/include/isc/serial.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/sha1.h@1.2 +11 -2 + bind-9.9.1 + + lib/isc/include/isc/sha2.h@1.2 +18 -5 + bind-9.9.1 + + lib/isc/include/isc/sockaddr.h@1.6 +1 -1 + bind-9.9.1 + + lib/isc/include/isc/socket.h@1.2 +163 -2 + bind-9.9.1 + + lib/isc/include/isc/stats.h@1.2 +2 -2 + bind-9.9.1 + + lib/isc/include/isc/symtab.h@1.2 +10 -2 + bind-9.9.1 + + lib/isc/include/isc/task.h@1.2 +176 -4 + bind-9.9.1 + + lib/isc/include/isc/taskpool.h@1.2 +58 -6 + bind-9.9.1 + + lib/isc/include/isc/timer.h@1.2 +90 -3 + bind-9.9.1 + + lib/isc/include/isc/types.h@1.5 +8 -3 + bind-9.9.1 + + lib/isc/include/isc/util.h@1.4.1.1 +7 -2 + bind-9.9.1 + + lib/isc/inet_aton.c@1.5 +2 -2 + bind-9.9.1 + + lib/isc/inet_ntop.c@1.7.1.1 +6 -5 + bind-9.9.1 + + lib/isc/iterated_hash.c@1.2 +1 -1 + bind-9.9.1 + + lib/isc/lib.c@1.5 +29 -5 + bind-9.9.1 + + lib/isc/log.c@1.3.1.1 +5 -4 + bind-9.9.1 + + lib/isc/md5.c@1.3 +28 -2 + bind-9.9.1 + + lib/isc/mem.c@1.6 +444 -172 + bind-9.9.1 + + lib/isc/mem_api.c@1.1 +303 -0 + bind-9.9.1 + + lib/isc/mem_api.c@1.0 +0 -0 + + lib/isc/mutexblock.c@1.2 +4 -5 + bind-9.9.1 + + lib/isc/netaddr.c@1.6.1.1 +20 -22 + bind-9.9.1 + + lib/isc/powerpc/include/isc/atomic.h@1.2 +54 -17 + bind-9.9.1 + + lib/isc/print.c@1.2 +3 -3 + bind-9.9.1 + + lib/isc/pthreads/mutex.c@1.1.1.1 +13 -10 + bind-9.9.1 + + lib/isc/radix.c@1.2 +3 -3 + bind-9.9.1 + + lib/isc/random.c@1.2 +19 -10 + bind-9.9.1 + + lib/isc/result.c@1.1.1.1 +3 -2 + bind-9.9.1 + + lib/isc/rwlock.c@1.2 +3 -2 + bind-9.9.1 + + lib/isc/sha1.c@1.2 +41 -2 + bind-9.9.1 + + lib/isc/sha2.c@1.2 +335 -120 + bind-9.9.1 + + lib/isc/sockaddr.c@1.8.1.1 +7 -4 + bind-9.9.1 + + lib/isc/socket_api.c@1.1 +231 -0 + bind-9.9.1 + + lib/isc/socket_api.c@1.0 +0 -0 + + lib/isc/stats.c@1.2 +2 -2 + bind-9.9.1 + + lib/isc/string.c@1.2 +6 -5 + bind-9.9.1 + + lib/isc/symtab.c@1.2 +51 -2 + bind-9.9.1 + + lib/isc/task.c@1.1.1.1 +607 -178 + bind-9.9.1 + + lib/isc/task_api.c@1.1 +244 -0 + bind-9.9.1 + + lib/isc/task_api.c@1.0 +0 -0 + + lib/isc/task_p.h@1.2 +12 -4 + bind-9.9.1 + + lib/isc/taskpool.c@1.2 +103 -14 + bind-9.9.1 + + lib/isc/tests/Atffile@1.1 +5 -0 + bind-9.9.1 + + lib/isc/tests/Atffile@1.0 +0 -0 + + lib/isc/tests/hash_test.c@1.1 +1805 -0 + bind-9.9.1 + + lib/isc/tests/hash_test.c@1.0 +0 -0 + + lib/isc/tests/isctest.c@1.1 +178 -0 + bind-9.9.1 + + lib/isc/tests/isctest.c@1.0 +0 -0 + + lib/isc/tests/isctest.h@1.1 +57 -0 + bind-9.9.1 + + lib/isc/tests/isctest.h@1.0 +0 -0 + + lib/isc/tests/queue_test.c@1.1 +144 -0 + bind-9.9.1 + + lib/isc/tests/queue_test.c@1.0 +0 -0 + + lib/isc/tests/socket_test.c@1.1 +255 -0 + bind-9.9.1 + + lib/isc/tests/socket_test.c@1.0 +0 -0 + + lib/isc/tests/symtab_test.c@1.1 +147 -0 + bind-9.9.1 + + lib/isc/tests/symtab_test.c@1.0 +0 -0 + + lib/isc/tests/task_test.c@1.1 +416 -0 + bind-9.9.1 + + lib/isc/tests/task_test.c@1.0 +0 -0 + + lib/isc/tests/taskpool_test.c@1.1 +211 -0 + bind-9.9.1 + + lib/isc/tests/taskpool_test.c@1.0 +0 -0 + + lib/isc/timer.c@1.2 +246 -107 + bind-9.9.1 + + lib/isc/timer_api.c@1.1 +144 -0 + bind-9.9.1 + + lib/isc/timer_api.c@1.0 +0 -0 + + lib/isc/timer_p.h@1.2 +4 -4 + bind-9.9.1 + + lib/isc/unix/app.c@1.2 +399 -137 + bind-9.9.1 + + lib/isc/unix/dir.c@1.1.1.1 +3 -3 + bind-9.9.1 + + lib/isc/unix/entropy.c@1.2 +2 -2 + bind-9.9.1 + + lib/isc/unix/errno2result.c@1.2 +5 -6 + bind-9.9.1 + + lib/isc/unix/errno2result.h@1.2 +5 -3 + bind-9.9.1 + + lib/isc/unix/file.c@1.1.1.1 +102 -5 + bind-9.9.1 + + lib/isc/unix/ifiter_getifaddrs.c@1.7.1.1 +3 -3 + bind-9.9.1 + + lib/isc/unix/ifiter_ioctl.c@1.27.1.1 +1 -1 + bind-9.9.1 + + lib/isc/unix/include/isc/net.h@1.10.1.1 +2 -2 + bind-9.9.1 + + lib/isc/unix/include/isc/offset.h@1.5 +2 -2 + bind-9.9.1 + + lib/isc/unix/include/isc/stdtime.h@1.2 +6 -2 + bind-9.9.1 + + lib/isc/unix/include/isc/strerror.h@1.5 +2 -2 + bind-9.9.1 + + lib/isc/unix/include/isc/time.h@1.4 +1 -1 + bind-9.9.1 + + lib/isc/unix/interfaceiter.c@1.17.1.1 +2 -2 + bind-9.9.1 + + lib/isc/unix/net.c@1.12.1.1 +2 -2 + bind-9.9.1 + + lib/isc/unix/resource.c@1.2 +1 -1 + bind-9.9.1 + + lib/isc/unix/socket.c@1.2 +851 -390 + bind-9.9.1 + + lib/isc/unix/socket_p.h@1.2 +5 -4 + bind-9.9.1 + + lib/isc/unix/stdio.c@1.2 +15 -3 + bind-9.9.1 + + lib/isc/unix/strerror.c@1.5.1.1 +1 -1 + bind-9.9.1 + + lib/isc/unix/time.c@1.2 +6 -24 + bind-9.9.1 + + lib/isc/win32/app.c@1.2 +11 -11 + bind-9.9.1 + + lib/isc/win32/dir.c@1.2 +3 -3 + bind-9.9.1 + + lib/isc/win32/entropy.c@1.2 +1 -1 + bind-9.9.1 + + lib/isc/win32/file.c@1.2 +126 -14 + bind-9.9.1 + + lib/isc/win32/include/isc/ipv6.h@1.8.1.1 +6 -6 + bind-9.9.1 + + lib/isc/win32/include/isc/mutex.h@1.5 +1 -1 + bind-9.9.1 + + lib/isc/win32/include/isc/net.h@1.8.1.1 +2 -2 + bind-9.9.1 + + lib/isc/win32/include/isc/ntpaths.h@1.2 +5 -4 + bind-9.9.1 + + lib/isc/win32/include/isc/platform.h@1.5.1.1 +7 -1 + bind-9.9.1 + + lib/isc/win32/include/isc/stat.h@1.3.1.1 +16 -3 + bind-9.9.1 + + lib/isc/win32/include/isc/stdtime.h@1.2 +6 -2 + bind-9.9.1 + + lib/isc/win32/include/isc/thread.h@1.1.1.1 +7 -7 + bind-9.9.1 + + lib/isc/win32/include/isc/time.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/win32/include/isc/win32os.h@1.5 +3 -3 + bind-9.9.1 + + lib/isc/win32/interfaceiter.c@1.10.2.1 +1 -1 + bind-9.9.1 + + lib/isc/win32/libgen.h@1.1 +25 -0 + bind-9.9.1 + + lib/isc/win32/libgen.h@1.0 +0 -0 + + lib/isc/win32/libisc.def@1.2 +149 -117 + bind-9.9.1 + + lib/isc/win32/libisc.dsp@1.2 +22 -4 + bind-9.9.1 + + lib/isc/win32/libisc.mak@1.2 +53 -4 + bind-9.9.1 + + lib/isc/win32/net.c@1.11.1.1 +7 -5 + bind-9.9.1 + + lib/isc/win32/netdb.h@1.2 +1 -1 + bind-9.9.1 + + lib/isc/win32/ntgroups.c@1.2 +23 -23 + bind-9.9.1 + + lib/isc/win32/ntpaths.c@1.2 +11 -4 + bind-9.9.1 + + lib/isc/win32/socket.c@1.2 +388 -95 + bind-9.9.1 + + lib/isc/win32/time.c@1.2 +44 -19 + bind-9.9.1 + + lib/isc/win32/unistd.h@1.2 +9 -2 + bind-9.9.1 + +ChangeSet@1.2773.1.19, 2012-05-25 05:07:31+00:00, stenn@deacon.udel.edu + NTP_4_2_7P277 + TAG: NTP_4_2_7P277 + + ChangeLog@1.1146.1.16 +1 -0 + NTP_4_2_7P277 + + ntpd/ntpd-opts.c@1.282 +4 -4 + NTP_4_2_7P277 + + ntpd/ntpd-opts.h@1.282 +3 -3 + NTP_4_2_7P277 + + ntpd/ntpd-opts.texi@1.275.2.2 +2 -2 + NTP_4_2_7P277 + + ntpd/ntpd.1ntpdman@1.93 +2 -2 + NTP_4_2_7P277 + + ntpd/ntpd.1ntpdmdoc@1.93 +2 -2 + NTP_4_2_7P277 + + ntpd/ntpd.man.in@1.93 +2 -2 + NTP_4_2_7P277 + + ntpd/ntpd.mdoc.in@1.93 +2 -2 + NTP_4_2_7P277 + + ntpdc/ntpdc-opts.c@1.277 +4 -4 + NTP_4_2_7P277 + + ntpdc/ntpdc-opts.h@1.277 +3 -3 + NTP_4_2_7P277 + + ntpdc/ntpdc-opts.texi@1.272.2.2 +2 -2 + NTP_4_2_7P277 + + ntpdc/ntpdc.1ntpdcman@1.93 +2 -2 + NTP_4_2_7P277 + + ntpdc/ntpdc.1ntpdcmdoc@1.93 +2 -2 + NTP_4_2_7P277 + + ntpdc/ntpdc.html@1.105 +2 -2 + NTP_4_2_7P277 + + ntpdc/ntpdc.man.in@1.93 +2 -2 + NTP_4_2_7P277 + + ntpdc/ntpdc.mdoc.in@1.93 +2 -2 + NTP_4_2_7P277 + + ntpq/ntpq-opts.c@1.279 +4 -4 + NTP_4_2_7P277 + + ntpq/ntpq-opts.h@1.279 +3 -3 + NTP_4_2_7P277 + + ntpq/ntpq-opts.texi@1.274.2.2 +2 -2 + NTP_4_2_7P277 + + ntpq/ntpq.1ntpqman@1.93 +2 -2 + NTP_4_2_7P277 + + ntpq/ntpq.1ntpqmdoc@1.93 +2 -2 + NTP_4_2_7P277 + + ntpq/ntpq.man.in@1.93 +2 -2 + NTP_4_2_7P277 + + ntpq/ntpq.mdoc.in@1.93 +2 -2 + NTP_4_2_7P277 + + ntpsnmpd/ntpsnmpd-opts.c@1.279 +4 -4 + NTP_4_2_7P277 + + ntpsnmpd/ntpsnmpd-opts.h@1.279 +3 -3 + NTP_4_2_7P277 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.2.2 +2 -2 + NTP_4_2_7P277 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.93 +2 -2 + NTP_4_2_7P277 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.93 +2 -2 + NTP_4_2_7P277 + + ntpsnmpd/ntpsnmpd.man.in@1.93 +2 -2 + NTP_4_2_7P277 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.93 +2 -2 + NTP_4_2_7P277 + + packageinfo.sh@1.280 +1 -1 + NTP_4_2_7P277 + + scripts/ntp-wait-opts.texi@1.92.2.2 +1 -1 + NTP_4_2_7P277 + + scripts/ntp-wait.1ntp-waitman@1.93 +2 -2 + NTP_4_2_7P277 + + scripts/ntp-wait.1ntp-waitmdoc@1.93 +2 -2 + NTP_4_2_7P277 + + scripts/ntp-wait.html@1.97 +1 -1 + NTP_4_2_7P277 + + scripts/ntp-wait.man.in@1.93 +2 -2 + NTP_4_2_7P277 + + scripts/ntp-wait.mdoc.in@1.93 +2 -2 + NTP_4_2_7P277 + + sntp/sntp-opts.c@1.275 +4 -4 + NTP_4_2_7P277 + + sntp/sntp-opts.h@1.275 +3 -3 + NTP_4_2_7P277 + + sntp/sntp-opts.texi@1.270.2.2 +2 -2 + NTP_4_2_7P277 + + sntp/sntp.1sntpman@1.95 +2 -2 + NTP_4_2_7P277 + + sntp/sntp.1sntpmdoc@1.95 +2 -2 + NTP_4_2_7P277 + + sntp/sntp.html@1.275 +2 -2 + NTP_4_2_7P277 + + sntp/sntp.man.in@1.95 +2 -2 + NTP_4_2_7P277 + + sntp/sntp.mdoc.in@1.95 +2 -2 + NTP_4_2_7P277 + + util/ntp-keygen-opts.c@1.279 +4 -4 + NTP_4_2_7P277 + + util/ntp-keygen-opts.h@1.279 +3 -3 + NTP_4_2_7P277 + + util/ntp-keygen-opts.texi@1.275.2.2 +2 -2 + NTP_4_2_7P277 + + util/ntp-keygen.1ntp-keygenman@1.93 +2 -2 + NTP_4_2_7P277 + + util/ntp-keygen.1ntp-keygenmdoc@1.93 +2 -2 + NTP_4_2_7P277 + + util/ntp-keygen.man.in@1.93 +2 -2 + NTP_4_2_7P277 + + util/ntp-keygen.mdoc.in@1.93 +2 -2 + NTP_4_2_7P277 + +ChangeSet@1.2773.1.18, 2012-05-25 00:36:37+02:00, karlsson@luft.lund.zozs.se + [Bug 2193] Building timestruct tests with Clang 3.1 fails. + + ChangeLog@1.1146.1.15 +1 -0 + [Bug 2193] Building timestruct tests with Clang 3.1 fails. + + tests/libntp/timestructs.cpp@1.4 +2 -2 + [Bug 2193] Building timestruct tests with Clang 3.1 fails. + + tests/libntp/timestructs.h@1.4 +2 -2 + [Bug 2193] Building timestruct tests with Clang 3.1 fails. + +ChangeSet@1.2773.1.17, 2012-05-15 06:32:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P276 + TAG: NTP_4_2_7P276 + + ChangeLog@1.1146.1.14 +1 -0 + NTP_4_2_7P276 + + ntpd/ntpd-opts.c@1.281 +4 -4 + NTP_4_2_7P276 + + ntpd/ntpd-opts.h@1.281 +3 -3 + NTP_4_2_7P276 + + ntpd/ntpd-opts.texi@1.275.2.1 +2 -2 + NTP_4_2_7P276 + + ntpd/ntpd.1ntpdman@1.92 +2 -2 + NTP_4_2_7P276 + + ntpd/ntpd.1ntpdmdoc@1.92 +2 -2 + NTP_4_2_7P276 + + ntpd/ntpd.man.in@1.92 +2 -2 + NTP_4_2_7P276 + + ntpd/ntpd.mdoc.in@1.92 +2 -2 + NTP_4_2_7P276 + + ntpdc/ntpdc-opts.c@1.276 +4 -4 + NTP_4_2_7P276 + + ntpdc/ntpdc-opts.h@1.276 +3 -3 + NTP_4_2_7P276 + + ntpdc/ntpdc-opts.texi@1.272.2.1 +2 -2 + NTP_4_2_7P276 + + ntpdc/ntpdc.1ntpdcman@1.92 +2 -2 + NTP_4_2_7P276 + + ntpdc/ntpdc.1ntpdcmdoc@1.92 +2 -2 + NTP_4_2_7P276 + + ntpdc/ntpdc.html@1.104 +2 -2 + NTP_4_2_7P276 + + ntpdc/ntpdc.man.in@1.92 +2 -2 + NTP_4_2_7P276 + + ntpdc/ntpdc.mdoc.in@1.92 +2 -2 + NTP_4_2_7P276 + + ntpq/ntpq-opts.c@1.278 +4 -4 + NTP_4_2_7P276 + + ntpq/ntpq-opts.h@1.278 +3 -3 + NTP_4_2_7P276 + + ntpq/ntpq-opts.texi@1.274.2.1 +2 -2 + NTP_4_2_7P276 + + ntpq/ntpq.1ntpqman@1.92 +2 -2 + NTP_4_2_7P276 + + ntpq/ntpq.1ntpqmdoc@1.92 +2 -2 + NTP_4_2_7P276 + + ntpq/ntpq.man.in@1.92 +2 -2 + NTP_4_2_7P276 + + ntpq/ntpq.mdoc.in@1.92 +2 -2 + NTP_4_2_7P276 + + ntpsnmpd/ntpsnmpd-opts.c@1.278 +4 -4 + NTP_4_2_7P276 + + ntpsnmpd/ntpsnmpd-opts.h@1.278 +3 -3 + NTP_4_2_7P276 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.2.1 +2 -2 + NTP_4_2_7P276 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.92 +2 -2 + NTP_4_2_7P276 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.92 +2 -2 + NTP_4_2_7P276 + + ntpsnmpd/ntpsnmpd.man.in@1.92 +2 -2 + NTP_4_2_7P276 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.92 +2 -2 + NTP_4_2_7P276 + + packageinfo.sh@1.279 +1 -1 + NTP_4_2_7P276 + + scripts/ntp-wait-opts.texi@1.92.2.1 +1 -1 + NTP_4_2_7P276 + + scripts/ntp-wait.1ntp-waitman@1.92 +2 -2 + NTP_4_2_7P276 + + scripts/ntp-wait.1ntp-waitmdoc@1.92 +2 -2 + NTP_4_2_7P276 + + scripts/ntp-wait.html@1.96 +1 -1 + NTP_4_2_7P276 + + scripts/ntp-wait.man.in@1.92 +2 -2 + NTP_4_2_7P276 + + scripts/ntp-wait.mdoc.in@1.92 +2 -2 + NTP_4_2_7P276 + + sntp/sntp-opts.c@1.274 +4 -4 + NTP_4_2_7P276 + + sntp/sntp-opts.h@1.274 +3 -3 + NTP_4_2_7P276 + + sntp/sntp-opts.texi@1.270.2.1 +2 -2 + NTP_4_2_7P276 + + sntp/sntp.1sntpman@1.94 +2 -2 + NTP_4_2_7P276 + + sntp/sntp.1sntpmdoc@1.94 +2 -2 + NTP_4_2_7P276 + + sntp/sntp.html@1.274 +2 -2 + NTP_4_2_7P276 + + sntp/sntp.man.in@1.94 +2 -2 + NTP_4_2_7P276 + + sntp/sntp.mdoc.in@1.94 +2 -2 + NTP_4_2_7P276 + + util/ntp-keygen-opts.c@1.278 +4 -4 + NTP_4_2_7P276 + + util/ntp-keygen-opts.h@1.278 +3 -3 + NTP_4_2_7P276 + + util/ntp-keygen-opts.texi@1.275.2.1 +2 -2 + NTP_4_2_7P276 + + util/ntp-keygen.1ntp-keygenman@1.92 +2 -2 + NTP_4_2_7P276 + + util/ntp-keygen.1ntp-keygenmdoc@1.92 +2 -2 + NTP_4_2_7P276 + + util/ntp-keygen.man.in@1.92 +2 -2 + NTP_4_2_7P276 + + util/ntp-keygen.mdoc.in@1.92 +2 -2 + NTP_4_2_7P276 + +ChangeSet@1.2773.1.16, 2012-05-15 02:16:33-04:00, stenn@deacon.udel.edu + [Bug 2179] Remove sntp/header.h + + BitKeeper/deleted/28/header.h~bd6b45785988925a@1.8 +0 -0 + Delete: sntp/header.h + + ChangeLog@1.1146.1.13 +1 -0 + [Bug 2179] Remove sntp/header.h + + sntp/Makefile.am@1.71.1.1 +0 -1 + [Bug 2179] Remove sntp/header.h + +ChangeSet@1.2778, 2012-05-08 05:47:09+00:00, stenn@psp-fb1.ntp.org + autogen upgrade + + ntpd/invoke-ntpd.texi@1.278 +2 -2 + autogen upgrade + + ntpd/ntpdsim-opts.c@1.19 +643 -472 + autogen upgrade + + ntpd/ntpdsim-opts.h@1.19 +57 -31 + autogen upgrade + + ntpdc/invoke-ntpdc.texi@1.275 +2 -2 + autogen upgrade + + ntpq/invoke-ntpq.texi@1.277 +2 -2 + autogen upgrade + + ntpsnmpd/invoke-ntpsnmpd.texi@1.277 +3 -25 + autogen upgrade + + scripts/invoke-ntp-wait.texi@1.95 +1 -1 + autogen upgrade + + sntp/invoke-sntp.texi@1.273 +8 -8 + autogen upgrade + + util/invoke-ntp-keygen.texi@1.278 +2 -2 + autogen upgrade + +ChangeSet@1.2773.1.15, 2012-04-28 06:38:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P275 + TAG: NTP_4_2_7P275 + + ChangeLog@1.1146.1.12 +1 -0 + NTP_4_2_7P275 + + ntpd/ntpd-opts.c@1.280 +4 -4 + NTP_4_2_7P275 + + ntpd/ntpd-opts.h@1.280 +3 -3 + NTP_4_2_7P275 + + ntpd/ntpd-opts.texi@1.275.1.3 +2 -2 + NTP_4_2_7P275 + + ntpd/ntpd.1ntpdman@1.91 +2 -2 + NTP_4_2_7P275 + + ntpd/ntpd.1ntpdmdoc@1.91 +2 -2 + NTP_4_2_7P275 + + ntpd/ntpd.man.in@1.91 +2 -2 + NTP_4_2_7P275 + + ntpd/ntpd.mdoc.in@1.91 +2 -2 + NTP_4_2_7P275 + + ntpdc/ntpdc-opts.c@1.275 +4 -4 + NTP_4_2_7P275 + + ntpdc/ntpdc-opts.h@1.275 +3 -3 + NTP_4_2_7P275 + + ntpdc/ntpdc-opts.texi@1.272.1.3 +2 -2 + NTP_4_2_7P275 + + ntpdc/ntpdc.1ntpdcman@1.91 +2 -2 + NTP_4_2_7P275 + + ntpdc/ntpdc.1ntpdcmdoc@1.91 +2 -2 + NTP_4_2_7P275 + + ntpdc/ntpdc.html@1.103 +2 -2 + NTP_4_2_7P275 + + ntpdc/ntpdc.man.in@1.91 +2 -2 + NTP_4_2_7P275 + + ntpdc/ntpdc.mdoc.in@1.91 +2 -2 + NTP_4_2_7P275 + + ntpq/ntpq-opts.c@1.277 +4 -4 + NTP_4_2_7P275 + + ntpq/ntpq-opts.h@1.277 +3 -3 + NTP_4_2_7P275 + + ntpq/ntpq-opts.texi@1.274.1.3 +2 -2 + NTP_4_2_7P275 + + ntpq/ntpq.1ntpqman@1.91 +2 -2 + NTP_4_2_7P275 + + ntpq/ntpq.1ntpqmdoc@1.91 +2 -2 + NTP_4_2_7P275 + + ntpq/ntpq.man.in@1.91 +2 -2 + NTP_4_2_7P275 + + ntpq/ntpq.mdoc.in@1.91 +2 -2 + NTP_4_2_7P275 + + ntpsnmpd/ntpsnmpd-opts.c@1.277 +4 -4 + NTP_4_2_7P275 + + ntpsnmpd/ntpsnmpd-opts.h@1.277 +3 -3 + NTP_4_2_7P275 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.1.3 +2 -2 + NTP_4_2_7P275 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.91 +2 -2 + NTP_4_2_7P275 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.91 +2 -2 + NTP_4_2_7P275 + + ntpsnmpd/ntpsnmpd.man.in@1.91 +2 -2 + NTP_4_2_7P275 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.91 +2 -2 + NTP_4_2_7P275 + + packageinfo.sh@1.278 +1 -1 + NTP_4_2_7P275 + + scripts/ntp-wait-opts.texi@1.92.1.3 +1 -1 + NTP_4_2_7P275 + + scripts/ntp-wait.1ntp-waitman@1.91 +2 -2 + NTP_4_2_7P275 + + scripts/ntp-wait.1ntp-waitmdoc@1.91 +2 -2 + NTP_4_2_7P275 + + scripts/ntp-wait.html@1.95 +1 -1 + NTP_4_2_7P275 + + scripts/ntp-wait.man.in@1.91 +2 -2 + NTP_4_2_7P275 + + scripts/ntp-wait.mdoc.in@1.91 +2 -2 + NTP_4_2_7P275 + + sntp/sntp-opts.c@1.273 +4 -4 + NTP_4_2_7P275 + + sntp/sntp-opts.h@1.273 +3 -3 + NTP_4_2_7P275 + + sntp/sntp-opts.texi@1.270.1.3 +2 -2 + NTP_4_2_7P275 + + sntp/sntp.1sntpman@1.93 +2 -2 + NTP_4_2_7P275 + + sntp/sntp.1sntpmdoc@1.93 +2 -2 + NTP_4_2_7P275 + + sntp/sntp.html@1.273 +2 -2 + NTP_4_2_7P275 + + sntp/sntp.man.in@1.93 +2 -2 + NTP_4_2_7P275 + + sntp/sntp.mdoc.in@1.93 +2 -2 + NTP_4_2_7P275 + + util/ntp-keygen-opts.c@1.277 +4 -4 + NTP_4_2_7P275 + + util/ntp-keygen-opts.h@1.277 +3 -3 + NTP_4_2_7P275 + + util/ntp-keygen-opts.texi@1.275.1.3 +2 -2 + NTP_4_2_7P275 + + util/ntp-keygen.1ntp-keygenman@1.91 +2 -2 + NTP_4_2_7P275 + + util/ntp-keygen.1ntp-keygenmdoc@1.91 +2 -2 + NTP_4_2_7P275 + + util/ntp-keygen.man.in@1.91 +2 -2 + NTP_4_2_7P275 + + util/ntp-keygen.mdoc.in@1.91 +2 -2 + NTP_4_2_7P275 + +ChangeSet@1.2773.1.14, 2012-04-27 15:02:14-07:00, harlan@hms-mbp.local + [Bug 1744] Remove obsolete ntpdate/ntptime* items + + BitKeeper/deleted/2e/ntptime_config.c~491a3955@1.7 +0 -0 + Delete: ntpdate/ntptime_config.c + + BitKeeper/deleted/92/ntptimeset.c~491a3955@1.16 +0 -0 + Delete: ntpdate/ntptimeset.c + + ChangeLog@1.1146.1.11 +1 -0 + [Bug 1744] Remove obsolete ntpdate/ntptime* items + + ntpdate/Makefile.am@1.36 +1 -3 + [Bug 1744] Remove obsolete ntpdate/ntptime* items + +ChangeSet@1.2773.1.13, 2012-04-25 04:41:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P274 + TAG: NTP_4_2_7P274 + + ChangeLog@1.1146.1.10 +1 -0 + NTP_4_2_7P274 + + ntpd/ntpd-opts.c@1.279 +4 -4 + NTP_4_2_7P274 + + ntpd/ntpd-opts.h@1.279 +3 -3 + NTP_4_2_7P274 + + ntpd/ntpd-opts.texi@1.275.1.2 +2 -2 + NTP_4_2_7P274 + + ntpd/ntpd.1ntpdman@1.90 +2 -2 + NTP_4_2_7P274 + + ntpd/ntpd.1ntpdmdoc@1.90 +2 -2 + NTP_4_2_7P274 + + ntpd/ntpd.man.in@1.90 +2 -2 + NTP_4_2_7P274 + + ntpd/ntpd.mdoc.in@1.90 +2 -2 + NTP_4_2_7P274 + + ntpdc/ntpdc-opts.c@1.274 +4 -4 + NTP_4_2_7P274 + + ntpdc/ntpdc-opts.h@1.274 +3 -3 + NTP_4_2_7P274 + + ntpdc/ntpdc-opts.texi@1.272.1.2 +2 -2 + NTP_4_2_7P274 + + ntpdc/ntpdc.1ntpdcman@1.90 +2 -2 + NTP_4_2_7P274 + + ntpdc/ntpdc.1ntpdcmdoc@1.90 +2 -2 + NTP_4_2_7P274 + + ntpdc/ntpdc.html@1.102 +2 -2 + NTP_4_2_7P274 + + ntpdc/ntpdc.man.in@1.90 +2 -2 + NTP_4_2_7P274 + + ntpdc/ntpdc.mdoc.in@1.90 +2 -2 + NTP_4_2_7P274 + + ntpq/ntpq-opts.c@1.276 +4 -4 + NTP_4_2_7P274 + + ntpq/ntpq-opts.h@1.276 +3 -3 + NTP_4_2_7P274 + + ntpq/ntpq-opts.texi@1.274.1.2 +2 -2 + NTP_4_2_7P274 + + ntpq/ntpq.1ntpqman@1.90 +2 -2 + NTP_4_2_7P274 + + ntpq/ntpq.1ntpqmdoc@1.90 +2 -2 + NTP_4_2_7P274 + + ntpq/ntpq.man.in@1.90 +2 -2 + NTP_4_2_7P274 + + ntpq/ntpq.mdoc.in@1.90 +2 -2 + NTP_4_2_7P274 + + ntpsnmpd/ntpsnmpd-opts.c@1.276 +4 -4 + NTP_4_2_7P274 + + ntpsnmpd/ntpsnmpd-opts.h@1.276 +3 -3 + NTP_4_2_7P274 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.1.2 +2 -2 + NTP_4_2_7P274 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.90 +2 -2 + NTP_4_2_7P274 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.90 +2 -2 + NTP_4_2_7P274 + + ntpsnmpd/ntpsnmpd.man.in@1.90 +2 -2 + NTP_4_2_7P274 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.90 +2 -2 + NTP_4_2_7P274 + + packageinfo.sh@1.277 +1 -1 + NTP_4_2_7P274 + + scripts/ntp-wait-opts.texi@1.92.1.2 +1 -1 + NTP_4_2_7P274 + + scripts/ntp-wait.1ntp-waitman@1.90 +2 -2 + NTP_4_2_7P274 + + scripts/ntp-wait.1ntp-waitmdoc@1.90 +2 -2 + NTP_4_2_7P274 + + scripts/ntp-wait.html@1.94 +1 -1 + NTP_4_2_7P274 + + scripts/ntp-wait.man.in@1.90 +2 -2 + NTP_4_2_7P274 + + scripts/ntp-wait.mdoc.in@1.90 +2 -2 + NTP_4_2_7P274 + + sntp/sntp-opts.c@1.272 +4 -4 + NTP_4_2_7P274 + + sntp/sntp-opts.h@1.272 +3 -3 + NTP_4_2_7P274 + + sntp/sntp-opts.texi@1.270.1.2 +2 -2 + NTP_4_2_7P274 + + sntp/sntp.1sntpman@1.92 +2 -2 + NTP_4_2_7P274 + + sntp/sntp.1sntpmdoc@1.92 +2 -2 + NTP_4_2_7P274 + + sntp/sntp.html@1.272 +2 -2 + NTP_4_2_7P274 + + sntp/sntp.man.in@1.92 +2 -2 + NTP_4_2_7P274 + + sntp/sntp.mdoc.in@1.92 +2 -2 + NTP_4_2_7P274 + + util/ntp-keygen-opts.c@1.276 +4 -4 + NTP_4_2_7P274 + + util/ntp-keygen-opts.h@1.276 +3 -3 + NTP_4_2_7P274 + + util/ntp-keygen-opts.texi@1.275.1.2 +2 -2 + NTP_4_2_7P274 + + util/ntp-keygen.1ntp-keygenman@1.90 +2 -2 + NTP_4_2_7P274 + + util/ntp-keygen.1ntp-keygenmdoc@1.90 +2 -2 + NTP_4_2_7P274 + + util/ntp-keygen.man.in@1.90 +2 -2 + NTP_4_2_7P274 + + util/ntp-keygen.mdoc.in@1.90 +2 -2 + NTP_4_2_7P274 + +ChangeSet@1.2773.1.12, 2012-04-25 03:53:28+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2174] ntpd rejects source UDP ports less than 123 as bogus. + + ChangeLog@1.1146.1.9 +1 -0 + [Bug 2174] ntpd rejects source UDP ports less than 123 as bogus. + + ntpd/ntp_proto.c@1.341 +3 -6 + [Bug 2174] ntpd rejects source UDP ports less than 123 as bogus. + +ChangeSet@1.2773.1.11, 2012-04-25 03:18:53+00:00, davehart@dlh-7551.ad.hartbrothers.com + Remove redundant manual systime_s.o: systime.c dependency from libntp's + Makefile.am. + + libntp/Makefile.am@1.70 +0 -7 + Remove redundant manual dependency of systime_s.o upon systime.c. The + same dependency is automatically generated in .deps/systime_s.Po which + Makefile includes. The manual dependency was an attempt to resolve a + problem caused by the release snapshot Makefile erroneously removing + all .deps directories from the build tree before running configure. + .dep/*.Po must not be removed unless *.o are removed at the same time, + or else automatic dependencies are missing. + +ChangeSet@1.2773.1.10, 2012-04-19 05:43:39+00:00, stenn@deacon.udel.edu + NTP_4_2_7P273 + TAG: NTP_4_2_7P273 + + ChangeLog@1.1146.1.8 +1 -0 + NTP_4_2_7P273 + + libntp/Makefile.am@1.69 +1 -1 + Use $(OBJEXT), not .o + + libntp/Makefile.am@1.68 +1 -2 + Fix systime_s.o dependency + + ntpd/ntpd-opts.c@1.278 +4 -4 + NTP_4_2_7P273 + + ntpd/ntpd-opts.h@1.278 +3 -3 + NTP_4_2_7P273 + + ntpd/ntpd-opts.texi@1.275.1.1 +2 -2 + NTP_4_2_7P273 + + ntpd/ntpd.1ntpdman@1.89 +2 -2 + NTP_4_2_7P273 + + ntpd/ntpd.1ntpdmdoc@1.89 +2 -2 + NTP_4_2_7P273 + + ntpd/ntpd.man.in@1.89 +2 -2 + NTP_4_2_7P273 + + ntpd/ntpd.mdoc.in@1.89 +2 -2 + NTP_4_2_7P273 + + ntpdc/ntpdc-opts.c@1.273 +4 -4 + NTP_4_2_7P273 + + ntpdc/ntpdc-opts.h@1.273 +3 -3 + NTP_4_2_7P273 + + ntpdc/ntpdc-opts.texi@1.272.1.1 +2 -2 + NTP_4_2_7P273 + + ntpdc/ntpdc.1ntpdcman@1.89 +2 -2 + NTP_4_2_7P273 + + ntpdc/ntpdc.1ntpdcmdoc@1.89 +2 -2 + NTP_4_2_7P273 + + ntpdc/ntpdc.html@1.101 +2 -2 + NTP_4_2_7P273 + + ntpdc/ntpdc.man.in@1.89 +2 -2 + NTP_4_2_7P273 + + ntpdc/ntpdc.mdoc.in@1.89 +2 -2 + NTP_4_2_7P273 + + ntpq/ntpq-opts.c@1.275 +4 -4 + NTP_4_2_7P273 + + ntpq/ntpq-opts.h@1.275 +3 -3 + NTP_4_2_7P273 + + ntpq/ntpq-opts.texi@1.274.1.1 +2 -2 + NTP_4_2_7P273 + + ntpq/ntpq.1ntpqman@1.89 +2 -2 + NTP_4_2_7P273 + + ntpq/ntpq.1ntpqmdoc@1.89 +2 -2 + NTP_4_2_7P273 + + ntpq/ntpq.man.in@1.89 +2 -2 + NTP_4_2_7P273 + + ntpq/ntpq.mdoc.in@1.89 +2 -2 + NTP_4_2_7P273 + + ntpsnmpd/ntpsnmpd-opts.c@1.275 +4 -4 + NTP_4_2_7P273 + + ntpsnmpd/ntpsnmpd-opts.h@1.275 +3 -3 + NTP_4_2_7P273 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274.1.1 +2 -2 + NTP_4_2_7P273 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.89 +2 -2 + NTP_4_2_7P273 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.89 +2 -2 + NTP_4_2_7P273 + + ntpsnmpd/ntpsnmpd.man.in@1.89 +2 -2 + NTP_4_2_7P273 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.89 +2 -2 + NTP_4_2_7P273 + + packageinfo.sh@1.276 +1 -1 + NTP_4_2_7P273 + + scripts/ntp-wait-opts.texi@1.92.1.1 +1 -1 + NTP_4_2_7P273 + + scripts/ntp-wait.1ntp-waitman@1.89 +2 -2 + NTP_4_2_7P273 + + scripts/ntp-wait.1ntp-waitmdoc@1.89 +2 -2 + NTP_4_2_7P273 + + scripts/ntp-wait.html@1.93 +1 -1 + NTP_4_2_7P273 + + scripts/ntp-wait.man.in@1.89 +2 -2 + NTP_4_2_7P273 + + scripts/ntp-wait.mdoc.in@1.89 +2 -2 + NTP_4_2_7P273 + + sntp/sntp-opts.c@1.271 +4 -4 + NTP_4_2_7P273 + + sntp/sntp-opts.h@1.271 +3 -3 + NTP_4_2_7P273 + + sntp/sntp-opts.texi@1.270.1.1 +2 -2 + NTP_4_2_7P273 + + sntp/sntp.1sntpman@1.91 +2 -2 + NTP_4_2_7P273 + + sntp/sntp.1sntpmdoc@1.91 +2 -2 + NTP_4_2_7P273 + + sntp/sntp.html@1.271 +2 -2 + NTP_4_2_7P273 + + sntp/sntp.man.in@1.91 +2 -2 + NTP_4_2_7P273 + + sntp/sntp.mdoc.in@1.91 +2 -2 + NTP_4_2_7P273 + + util/ntp-keygen-opts.c@1.275 +4 -4 + NTP_4_2_7P273 + + util/ntp-keygen-opts.h@1.275 +3 -3 + NTP_4_2_7P273 + + util/ntp-keygen-opts.texi@1.275.1.1 +2 -2 + NTP_4_2_7P273 + + util/ntp-keygen.1ntp-keygenman@1.89 +2 -2 + NTP_4_2_7P273 + + util/ntp-keygen.1ntp-keygenmdoc@1.89 +2 -2 + NTP_4_2_7P273 + + util/ntp-keygen.man.in@1.89 +2 -2 + NTP_4_2_7P273 + + util/ntp-keygen.mdoc.in@1.89 +2 -2 + NTP_4_2_7P273 + +ChangeSet@1.2773.1.9, 2012-04-18 19:30:28+00:00, davehart@dlh-7551.ad.hartbrothers.com + Correct authnumfreekeys accounting broken in 4.2.7p262. + + ChangeLog@1.1146.1.7 +1 -0 + Correct authnumfreekeys accounting broken in 4.2.7p262. + + libntp/authkeys.c@1.24 +2 -2 + Correct authnumfreekeys accounting broken in 4.2.7p262. + +ChangeSet@1.2773.1.8, 2012-04-18 11:46:26+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2141] handle_sigio() calls get_systime(), which must be + reentrant when SIGIO is used. Sanity checks relative to the prior + get_systime() are disabled in ntpd on systems with signaled I/O, but + active in sntp and ntpdate. + + ChangeLog@1.1146.1.6 +4 -0 + [Bug 2141] handle_sigio() calls get_systime(), which must be + reentrant when SIGIO is used. Sanity checks relative to the prior + get_systime() are disabled in ntpd on systems with signaled I/O, but + active in sntp and ntpdate. + + include/iosignal.h@1.6 +5 -0 + Add USING_SIGIO() and using_sigio. + + libntp/iosignal.c@1.16 +2 -0 + Set using_sigio when doing so. + + libntp/systime.c@1.66 +51 -31 + Disable non-reentrant checks in get_systime() when SIGIO is being used, + as handle_sigio() calls get_systime(). + +ChangeSet@1.2773.1.7, 2012-04-18 05:03:10+00:00, davehart@dlh-7551.ad.hartbrothers.com + Remove inttoa() and uinttoa(), convert solitary use of latter + to simpler code. + + BitKeeper/deleted/73/inttoa.cpp~827ae0ffc75432e4@1.5 +0 -0 + Delete: tests/libntp/inttoa.cpp + + BitKeeper/deleted/a5/inttoa.c~3e480692@1.5 +0 -0 + Delete: libntp/inttoa.c + + BitKeeper/deleted/ac/uinttoa.c~3e480692@1.5 +0 -0 + Delete: libntp/uinttoa.c + + BitKeeper/deleted/f0/uinttoa.cpp~d804670d7d9346f4@1.2 +0 -0 + Delete: tests/libntp/uinttoa.cpp + + include/ntp_stdlib.h@1.73 +0 -2 + Remove inttoa() and uinttoa(). + + libntp/Makefile.am@1.67 +0 -2 + Remove inttoa() and uinttoa(). + + ntpq/ntpq-subs.c@1.96 +2 -4 + Convert solitary callsite of uinttoa() to simpler equivalent. + + ports/winnt/vs2005/libntp.vcproj@1.22 +0 -8 + Remove inttoa() and uinttoa(). + + ports/winnt/vs2008/libntp/libntp.vcproj@1.45 +2 -10 + Remove inttoa() and uinttoa(). + + tests/libntp/Makefile.am@1.40 +0 -2 + Remove inttoa() and uinttoa() unit tests. + +ChangeSet@1.2776, 2012-04-17 01:54:04-07:00, stenn@stenn.ntp.org + Upgrade to autogen-5.16 and libopts-36.4.11 + + ChangeLog@1.1149 +1 -0 + Upgrade to autogen-5.16 + + ntpd/Makefile.am@1.117 +7 -7 + Upgrade to autogen-5.16 + + ntpd/invoke-ntpd.menu@1.7 +0 -0 + Rename: ntpd/ntpd-opts.menu -> ntpd/invoke-ntpd.menu + + ntpd/invoke-ntpd.texi@1.274.1.2 +681 -272 + Upgrade to autogen-5.16 and libopts-36.4.11 + + ntpd/invoke-ntpd.texi@1.274.1.1 +0 -0 + Rename: ntpd/ntpd-opts.texi -> ntpd/invoke-ntpd.texi + + ntpdc/Makefile.am@1.72 +9 -9 + Upgrade to autogen-5.16 + + ntpdc/invoke-ntpdc.menu@1.7 +0 -0 + Rename: ntpdc/ntpdc-opts.menu -> ntpdc/invoke-ntpdc.menu + + ntpdc/invoke-ntpdc.texi@1.271.1.2 +667 -84 + Upgrade to autogen-5.16 and libopts-36.4.11 + + ntpdc/invoke-ntpdc.texi@1.271.1.1 +0 -0 + Rename: ntpdc/ntpdc-opts.texi -> ntpdc/invoke-ntpdc.texi + + ntpdc/ntpdc.texi@1.3 +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + ntpq/Makefile.am@1.68 +7 -7 + Upgrade to autogen-5.16 + + ntpq/invoke-ntpq.menu@1.7 +0 -0 + Rename: ntpq/ntpq-opts.menu -> ntpq/invoke-ntpq.menu + + ntpq/invoke-ntpq.texi@1.273.1.2 +352 -83 + Upgrade to autogen-5.16 and libopts-36.4.11 + + ntpq/invoke-ntpq.texi@1.273.1.1 +0 -0 + Rename: ntpq/ntpq-opts.texi -> ntpq/invoke-ntpq.texi + + ntpsnmpd/Makefile.am@1.35.1.1 +7 -7 + Upgrade to autogen-5.16 + + ntpsnmpd/invoke-ntpsnmpd.menu@1.7 +0 -0 + Rename: ntpsnmpd/ntpsnmpd-opts.menu -> ntpsnmpd/invoke-ntpsnmpd.menu + + ntpsnmpd/invoke-ntpsnmpd.texi@1.273.1.2 +120 -47 + Upgrade to autogen-5.16 and libopts-36.4.11 + + ntpsnmpd/invoke-ntpsnmpd.texi@1.273.1.1 +0 -0 + Rename: ntpsnmpd/ntpsnmpd-opts.texi -> ntpsnmpd/invoke-ntpsnmpd.texi + + scripts/Makefile.am@1.30 +8 -8 + Upgrade to autogen-5.16 + + scripts/invoke-ntp-wait.menu@1.2 +0 -0 + Rename: scripts/ntp-wait-opts.menu -> scripts/invoke-ntp-wait.menu + + scripts/invoke-ntp-wait.texi@1.91.1.2 +92 -26 + Upgrade to autogen-5.16 and libopts-36.4.11 + + scripts/invoke-ntp-wait.texi@1.91.1.1 +0 -0 + Rename: scripts/ntp-wait-opts.texi -> scripts/invoke-ntp-wait.texi + + scripts/ntp-wait.texi@1.2 +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/Makefile.am@1.72 +9 -9 + Upgrade to autogen-5.16 + + sntp/invoke-sntp.menu@1.7 +0 -0 + Rename: sntp/sntp-opts.menu -> sntp/invoke-sntp.menu + + sntp/invoke-sntp.texi@1.269.1.2 +254 -133 + Upgrade to autogen-5.16 and libopts-36.4.11 + + sntp/invoke-sntp.texi@1.269.1.1 +0 -0 + Rename: sntp/sntp-opts.texi -> sntp/invoke-sntp.texi + + sntp/libopts/Makefile.am@1.13 +6 -6 + upgrade to libopts-36.4.11 + + sntp/libopts/ag-char-map.h@1.16 +305 -129 + upgrade to libopts-36.4.11 + + sntp/libopts/ao-strs.c@1.2 +1 -1 + upgrade to libopts-36.4.11 + + sntp/libopts/ao-strs.h@1.1 +251 -0 + upgrade to libopts-36.4.11 + + sntp/libopts/ao-strs.h@1.0 +0 -0 + + sntp/libopts/autoopts.c@1.13 +14 -5 + upgrade to libopts-36.4.11 + + sntp/libopts/autoopts.h@1.11 +8 -9 + upgrade to libopts-36.4.11 + + sntp/libopts/autoopts/options.h@1.15 +50 -29 + upgrade to libopts-36.4.11 + + sntp/libopts/autoopts/project.h@1.2 +2 -0 + upgrade to libopts-36.4.11 + + sntp/libopts/autoopts/usage-txt.h@1.15 +161 -159 + upgrade to libopts-36.4.11 + + sntp/libopts/boolean.c@1.9 +8 -6 + upgrade to libopts-36.4.11 + + sntp/libopts/check.c@1.3 +17 -15 + upgrade to libopts-36.4.11 + + sntp/libopts/compat/compat.h@1.9 +15 -4 + upgrade to libopts-36.4.11 + + sntp/libopts/compat/pathfind.c@1.7 +2 -2 + upgrade to libopts-36.4.11 + + sntp/libopts/configfile.c@1.14 +58 -50 + upgrade to libopts-36.4.11 + + sntp/libopts/cook.c@1.10 +8 -8 + upgrade to libopts-36.4.11 + + sntp/libopts/enum.c@1.3 +32 -6 + upgrade to libopts-36.4.11 + + sntp/libopts/env.c@1.3 +7 -4 + upgrade to libopts-36.4.11 + + sntp/libopts/find.c@1.3 +4 -4 + upgrade to libopts-36.4.11 + + sntp/libopts/genshell.c@1.16 +17 -16 + upgrade to libopts-36.4.11 + + sntp/libopts/genshell.h@1.16 +6 -5 + upgrade to libopts-36.4.11 + + sntp/libopts/libopts.c@1.6 +1 -2 + upgrade to libopts-36.4.11 + + sntp/libopts/load.c@1.12 +46 -47 + upgrade to libopts-36.4.11 + + sntp/libopts/m4/libopts.m4@1.19 +3 -2 + upgrade to libopts-36.4.11 + + sntp/libopts/makeshell.c@1.11 +5 -3 + upgrade to libopts-36.4.11 + + sntp/libopts/nested.c@1.9 +7 -6 + upgrade to libopts-36.4.11 + + sntp/libopts/parse-duration.c@1.7 +3 -3 + upgrade to libopts-36.4.11 + + sntp/libopts/pgusage.c@1.10 +4 -11 + upgrade to libopts-36.4.11 + + sntp/libopts/proto.h@1.16 +4 -7 + upgrade to libopts-36.4.11 + + sntp/libopts/putshell.c@1.9 +6 -4 + upgrade to libopts-36.4.11 + + sntp/libopts/reset.c@1.10 +4 -4 + upgrade to libopts-36.4.11 + + sntp/libopts/save.c@1.11 +3 -3 + upgrade to libopts-36.4.11 + + sntp/libopts/stack.c@1.9 +8 -8 + upgrade to libopts-36.4.11 + + sntp/libopts/streqvcmp.c@1.9 +3 -3 + upgrade to libopts-36.4.11 + + sntp/libopts/tokenize.c@1.7 +7 -9 + upgrade to libopts-36.4.11 + + sntp/libopts/usage.c@1.11 +30 -32 + upgrade to libopts-36.4.11 + + sntp/libopts/value-type.h@1.16 +1 -1 + upgrade to libopts-36.4.11 + + sntp/libopts/xat-attribute.h@1.16 +1 -1 + upgrade to libopts-36.4.11 + + sntp/sntp.texi@1.9 +1 -1 + Upgrade to autogen-5.16 and libopts-36.4.11 + + util/Makefile.am@1.72 +7 -7 + Upgrade to autogen-5.16 + + util/invoke-ntp-keygen.menu@1.8 +0 -0 + Rename: util/ntp-keygen-opts.menu -> util/invoke-ntp-keygen.menu + + util/invoke-ntp-keygen.texi@1.274.1.2 +761 -120 + Upgrade to autogen-5.16 and libopts-36.4.11 + + util/invoke-ntp-keygen.texi@1.274.1.1 +0 -0 + Rename: util/ntp-keygen-opts.texi -> util/invoke-ntp-keygen.texi + +ChangeSet@1.2773.1.6, 2012-04-14 04:43:39+00:00, stenn@deacon.udel.edu + NTP_4_2_7P272 + TAG: NTP_4_2_7P272 + + ChangeLog@1.1146.1.5 +1 -0 + NTP_4_2_7P272 + + ntpd/ntpd-opts.c@1.277 +4 -4 + NTP_4_2_7P272 + + ntpd/ntpd-opts.h@1.277 +3 -3 + NTP_4_2_7P272 + + ntpd/ntpd-opts.texi@1.275 +2 -2 + NTP_4_2_7P272 + + ntpd/ntpd.1ntpdman@1.88 +2 -2 + NTP_4_2_7P272 + + ntpd/ntpd.1ntpdmdoc@1.88 +2 -2 + NTP_4_2_7P272 + + ntpd/ntpd.man.in@1.88 +2 -2 + NTP_4_2_7P272 + + ntpd/ntpd.mdoc.in@1.88 +2 -2 + NTP_4_2_7P272 + + ntpdc/ntpdc-opts.c@1.272 +4 -4 + NTP_4_2_7P272 + + ntpdc/ntpdc-opts.h@1.272 +3 -3 + NTP_4_2_7P272 + + ntpdc/ntpdc-opts.texi@1.272 +2 -2 + NTP_4_2_7P272 + + ntpdc/ntpdc.1ntpdcman@1.88 +2 -2 + NTP_4_2_7P272 + + ntpdc/ntpdc.1ntpdcmdoc@1.88 +2 -2 + NTP_4_2_7P272 + + ntpdc/ntpdc.html@1.100 +2 -2 + NTP_4_2_7P272 + + ntpdc/ntpdc.man.in@1.88 +2 -2 + NTP_4_2_7P272 + + ntpdc/ntpdc.mdoc.in@1.88 +2 -2 + NTP_4_2_7P272 + + ntpq/ntpq-opts.c@1.274 +4 -4 + NTP_4_2_7P272 + + ntpq/ntpq-opts.h@1.274 +3 -3 + NTP_4_2_7P272 + + ntpq/ntpq-opts.texi@1.274 +2 -2 + NTP_4_2_7P272 + + ntpq/ntpq.1ntpqman@1.88 +2 -2 + NTP_4_2_7P272 + + ntpq/ntpq.1ntpqmdoc@1.88 +2 -2 + NTP_4_2_7P272 + + ntpq/ntpq.man.in@1.88 +2 -2 + NTP_4_2_7P272 + + ntpq/ntpq.mdoc.in@1.88 +2 -2 + NTP_4_2_7P272 + + ntpsnmpd/ntpsnmpd-opts.c@1.274 +4 -4 + NTP_4_2_7P272 + + ntpsnmpd/ntpsnmpd-opts.h@1.274 +3 -3 + NTP_4_2_7P272 + + ntpsnmpd/ntpsnmpd-opts.texi@1.274 +2 -2 + NTP_4_2_7P272 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.88 +2 -2 + NTP_4_2_7P272 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.88 +2 -2 + NTP_4_2_7P272 + + ntpsnmpd/ntpsnmpd.man.in@1.88 +2 -2 + NTP_4_2_7P272 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.88 +2 -2 + NTP_4_2_7P272 + + packageinfo.sh@1.275 +1 -1 + NTP_4_2_7P272 + + scripts/ntp-wait-opts.texi@1.92 +1 -1 + NTP_4_2_7P272 + + scripts/ntp-wait.1ntp-waitman@1.88 +2 -2 + NTP_4_2_7P272 + + scripts/ntp-wait.1ntp-waitmdoc@1.88 +2 -2 + NTP_4_2_7P272 + + scripts/ntp-wait.html@1.92 +1 -1 + NTP_4_2_7P272 + + scripts/ntp-wait.man.in@1.88 +2 -2 + NTP_4_2_7P272 + + scripts/ntp-wait.mdoc.in@1.88 +2 -2 + NTP_4_2_7P272 + + sntp/sntp-opts.c@1.270 +4 -4 + NTP_4_2_7P272 + + sntp/sntp-opts.h@1.270 +3 -3 + NTP_4_2_7P272 + + sntp/sntp-opts.texi@1.270 +2 -2 + NTP_4_2_7P272 + + sntp/sntp.1sntpman@1.90 +2 -2 + NTP_4_2_7P272 + + sntp/sntp.1sntpmdoc@1.90 +2 -2 + NTP_4_2_7P272 + + sntp/sntp.html@1.270 +2 -2 + NTP_4_2_7P272 + + sntp/sntp.man.in@1.90 +2 -2 + NTP_4_2_7P272 + + sntp/sntp.mdoc.in@1.90 +2 -2 + NTP_4_2_7P272 + + util/ntp-keygen-opts.c@1.274 +4 -4 + NTP_4_2_7P272 + + util/ntp-keygen-opts.h@1.274 +3 -3 + NTP_4_2_7P272 + + util/ntp-keygen-opts.texi@1.275 +2 -2 + NTP_4_2_7P272 + + util/ntp-keygen.1ntp-keygenman@1.88 +2 -2 + NTP_4_2_7P272 + + util/ntp-keygen.1ntp-keygenmdoc@1.88 +2 -2 + NTP_4_2_7P272 + + util/ntp-keygen.man.in@1.88 +2 -2 + NTP_4_2_7P272 + + util/ntp-keygen.mdoc.in@1.88 +2 -2 + NTP_4_2_7P272 + +ChangeSet@1.2773.2.1, 2012-04-13 23:49:28-04:00, stenn@deacon.udel.edu + Change the link order for ntpsntpd + + ChangeLog@1.1146.2.2 +1 -0 + Change the link order for ntpsntpd + + ChangeLog@1.1146.2.1 +1 -0 + Remove extra nlist test + + configure.ac@1.545 +1 -1 + Remove extra nlist test + + ntpsnmpd/Makefile.am@1.36 +3 -2 + Change the link order for ntpsntpd + +ChangeSet@1.2773.1.4, 2012-04-13 02:02:55-07:00, harlan@hms-mbp.lan + LCRYPTO is gone - replace with VER_SUFFIX + + ChangeLog@1.1146.1.3 +1 -0 + LCRYPTO is gone - replace with VER_SUFFIX + + scripts/mkver.in@1.14 +2 -4 + LCRYPTO is gone - replace with VER_SUFFIX + + sntp/m4/ntp_openssl.m4@1.20 +8 -0 + LCRYPTO is gone - replace with VER_SUFFIX + + sntp/m4/ntp_ver_suffix.m4@1.1 +13 -0 + BitKeeper file /Users/harlan/src/ntp-dev/sntp/m4/ntp_ver_suffix.m4 + + sntp/m4/ntp_ver_suffix.m4@1.0 +0 -0 + +ChangeSet@1.2773.1.3, 2012-04-11 08:44:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P271 + TAG: NTP_4_2_7P271 + + ChangeLog@1.1146.1.2 +1 -0 + NTP_4_2_7P271 + + ntpd/ntpd-opts.c@1.276 +4 -4 + NTP_4_2_7P271 + + ntpd/ntpd-opts.h@1.276 +3 -3 + NTP_4_2_7P271 + + ntpd/ntpd-opts.texi@1.274 +2 -2 + NTP_4_2_7P271 + + ntpd/ntpd.1ntpdman@1.87 +2 -2 + NTP_4_2_7P271 + + ntpd/ntpd.1ntpdmdoc@1.87 +2 -2 + NTP_4_2_7P271 + + ntpd/ntpd.man.in@1.87 +2 -2 + NTP_4_2_7P271 + + ntpd/ntpd.mdoc.in@1.87 +2 -2 + NTP_4_2_7P271 + + ntpdc/ntpdc-opts.c@1.271 +4 -4 + NTP_4_2_7P271 + + ntpdc/ntpdc-opts.h@1.271 +3 -3 + NTP_4_2_7P271 + + ntpdc/ntpdc-opts.texi@1.271 +2 -2 + NTP_4_2_7P271 + + ntpdc/ntpdc.1ntpdcman@1.87 +2 -2 + NTP_4_2_7P271 + + ntpdc/ntpdc.1ntpdcmdoc@1.87 +2 -2 + NTP_4_2_7P271 + + ntpdc/ntpdc.html@1.99 +2 -2 + NTP_4_2_7P271 + + ntpdc/ntpdc.man.in@1.87 +2 -2 + NTP_4_2_7P271 + + ntpdc/ntpdc.mdoc.in@1.87 +2 -2 + NTP_4_2_7P271 + + ntpq/ntpq-opts.c@1.273 +4 -4 + NTP_4_2_7P271 + + ntpq/ntpq-opts.h@1.273 +3 -3 + NTP_4_2_7P271 + + ntpq/ntpq-opts.texi@1.273 +2 -2 + NTP_4_2_7P271 + + ntpq/ntpq.1ntpqman@1.87 +2 -2 + NTP_4_2_7P271 + + ntpq/ntpq.1ntpqmdoc@1.87 +2 -2 + NTP_4_2_7P271 + + ntpq/ntpq.man.in@1.87 +2 -2 + NTP_4_2_7P271 + + ntpq/ntpq.mdoc.in@1.87 +2 -2 + NTP_4_2_7P271 + + ntpsnmpd/ntpsnmpd-opts.c@1.273 +4 -4 + NTP_4_2_7P271 + + ntpsnmpd/ntpsnmpd-opts.h@1.273 +3 -3 + NTP_4_2_7P271 + + ntpsnmpd/ntpsnmpd-opts.texi@1.273 +2 -2 + NTP_4_2_7P271 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.87 +2 -2 + NTP_4_2_7P271 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.87 +2 -2 + NTP_4_2_7P271 + + ntpsnmpd/ntpsnmpd.man.in@1.87 +2 -2 + NTP_4_2_7P271 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.87 +2 -2 + NTP_4_2_7P271 + + packageinfo.sh@1.274 +1 -1 + NTP_4_2_7P271 + + scripts/ntp-wait-opts.texi@1.91 +14 -2 + NTP_4_2_7P271 + + scripts/ntp-wait.1ntp-waitman@1.87 +2 -2 + NTP_4_2_7P271 + + scripts/ntp-wait.1ntp-waitmdoc@1.87 +2 -2 + NTP_4_2_7P271 + + scripts/ntp-wait.html@1.91 +14 -2 + NTP_4_2_7P271 + + scripts/ntp-wait.man.in@1.87 +2 -2 + NTP_4_2_7P271 + + scripts/ntp-wait.mdoc.in@1.87 +2 -2 + NTP_4_2_7P271 + + sntp/sntp-opts.c@1.269 +4 -4 + NTP_4_2_7P271 + + sntp/sntp-opts.h@1.269 +3 -3 + NTP_4_2_7P271 + + sntp/sntp-opts.texi@1.269 +2 -2 + NTP_4_2_7P271 + + sntp/sntp.1sntpman@1.89 +2 -2 + NTP_4_2_7P271 + + sntp/sntp.1sntpmdoc@1.89 +2 -2 + NTP_4_2_7P271 + + sntp/sntp.html@1.269 +2 -2 + NTP_4_2_7P271 + + sntp/sntp.man.in@1.89 +2 -2 + NTP_4_2_7P271 + + sntp/sntp.mdoc.in@1.89 +2 -2 + NTP_4_2_7P271 + + util/ntp-keygen-opts.c@1.273 +4 -4 + NTP_4_2_7P271 + + util/ntp-keygen-opts.h@1.273 +3 -3 + NTP_4_2_7P271 + + util/ntp-keygen-opts.texi@1.274 +2 -2 + NTP_4_2_7P271 + + util/ntp-keygen.1ntp-keygenman@1.87 +2 -2 + NTP_4_2_7P271 + + util/ntp-keygen.1ntp-keygenmdoc@1.87 +2 -2 + NTP_4_2_7P271 + + util/ntp-keygen.man.in@1.87 +2 -2 + NTP_4_2_7P271 + + util/ntp-keygen.mdoc.in@1.87 +2 -2 + NTP_4_2_7P271 + +ChangeSet@1.2773.1.2, 2012-04-09 16:19:04+00:00, davehart@dlh-7551.ad.hartbrothers.com + Put openssl -L flags from pkg-config in LDADD_NTP as comment indicates, + rather than in LDFLAGS_NTP. + + sntp/m4/ntp_openssl.m4@1.19 +4 -4 + Put openssl -L flags from pkg-config in LDADD_NTP as comment indicates, + rather than in LDFLAGS_NTP. + +ChangeSet@1.2773.1.1, 2012-04-09 05:25:13+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 1122] openssl detection via pkg-config fails when no additional + -Idir flags are needed. + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + ChangeLog@1.1146.1.1 +4 -0 + [Bug 1122] openssl detection via pkg-config fails when no additional + -Idir flags are needed. + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + + ntpd/Makefile.am@1.112.1.3 +4 -2 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + ntpdate/Makefile.am@1.35 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + ntpdc/Makefile.am@1.71 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + ntpq/Makefile.am@1.67 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + ntpsnmpd/Makefile.am@1.35 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + sntp/Makefile.am@1.71 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + sntp/m4/ntp_compiler.m4@1.3 +4 -0 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + sntp/m4/ntp_openssl.m4@1.18 +185 -197 + [Bug 1122] openssl detection via pkg-config fails when no additional + -Idir flags are needed. + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + + sntp/tests/Makefile.am@1.27 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + tests/libntp/Makefile.am@1.39 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + + util/Makefile.am@1.71 +3 -1 + Avoid overwriting user variable LDFLAGS with OpenSSL flags, instead + they are added to LDFLAGS_NTP. + +ChangeSet@1.2773, 2012-03-26 09:24:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P270 + TAG: NTP_4_2_7P270 + + ChangeLog@1.1146 +1 -0 + NTP_4_2_7P270 + + ntpd/ntpd-opts.c@1.275 +4 -4 + NTP_4_2_7P270 + + ntpd/ntpd-opts.h@1.275 +3 -3 + NTP_4_2_7P270 + + ntpd/ntpd-opts.texi@1.273 +2 -2 + NTP_4_2_7P270 + + ntpd/ntpd.1ntpdman@1.86 +2 -2 + NTP_4_2_7P270 + + ntpd/ntpd.1ntpdmdoc@1.86 +2 -2 + NTP_4_2_7P270 + + ntpd/ntpd.man.in@1.86 +2 -2 + NTP_4_2_7P270 + + ntpd/ntpd.mdoc.in@1.86 +2 -2 + NTP_4_2_7P270 + + ntpdc/ntpdc-opts.c@1.270 +4 -4 + NTP_4_2_7P270 + + ntpdc/ntpdc-opts.h@1.270 +3 -3 + NTP_4_2_7P270 + + ntpdc/ntpdc-opts.texi@1.270 +2 -2 + NTP_4_2_7P270 + + ntpdc/ntpdc.1ntpdcman@1.86 +2 -2 + NTP_4_2_7P270 + + ntpdc/ntpdc.1ntpdcmdoc@1.86 +2 -2 + NTP_4_2_7P270 + + ntpdc/ntpdc.html@1.98 +2 -2 + NTP_4_2_7P270 + + ntpdc/ntpdc.man.in@1.86 +2 -2 + NTP_4_2_7P270 + + ntpdc/ntpdc.mdoc.in@1.86 +2 -2 + NTP_4_2_7P270 + + ntpq/ntpq-opts.c@1.272 +4 -4 + NTP_4_2_7P270 + + ntpq/ntpq-opts.h@1.272 +3 -3 + NTP_4_2_7P270 + + ntpq/ntpq-opts.texi@1.272 +2 -2 + NTP_4_2_7P270 + + ntpq/ntpq.1ntpqman@1.86 +2 -2 + NTP_4_2_7P270 + + ntpq/ntpq.1ntpqmdoc@1.86 +2 -2 + NTP_4_2_7P270 + + ntpq/ntpq.man.in@1.86 +2 -2 + NTP_4_2_7P270 + + ntpq/ntpq.mdoc.in@1.86 +2 -2 + NTP_4_2_7P270 + + ntpsnmpd/ntpsnmpd-opts.c@1.272 +4 -4 + NTP_4_2_7P270 + + ntpsnmpd/ntpsnmpd-opts.h@1.272 +3 -3 + NTP_4_2_7P270 + + ntpsnmpd/ntpsnmpd-opts.texi@1.272 +2 -2 + NTP_4_2_7P270 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.86 +2 -2 + NTP_4_2_7P270 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.86 +2 -2 + NTP_4_2_7P270 + + ntpsnmpd/ntpsnmpd.man.in@1.86 +2 -2 + NTP_4_2_7P270 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.86 +2 -2 + NTP_4_2_7P270 + + packageinfo.sh@1.273 +1 -1 + NTP_4_2_7P270 + + scripts/ntp-wait-opts.texi@1.90 +1 -1 + NTP_4_2_7P270 + + scripts/ntp-wait.1ntp-waitman@1.86 +2 -2 + NTP_4_2_7P270 + + scripts/ntp-wait.1ntp-waitmdoc@1.86 +2 -2 + NTP_4_2_7P270 + + scripts/ntp-wait.html@1.90 +1 -1 + NTP_4_2_7P270 + + scripts/ntp-wait.man.in@1.86 +2 -2 + NTP_4_2_7P270 + + scripts/ntp-wait.mdoc.in@1.86 +2 -2 + NTP_4_2_7P270 + + sntp/sntp-opts.c@1.268 +4 -4 + NTP_4_2_7P270 + + sntp/sntp-opts.h@1.268 +3 -3 + NTP_4_2_7P270 + + sntp/sntp-opts.texi@1.268 +2 -2 + NTP_4_2_7P270 + + sntp/sntp.1sntpman@1.88 +2 -2 + NTP_4_2_7P270 + + sntp/sntp.1sntpmdoc@1.88 +2 -2 + NTP_4_2_7P270 + + sntp/sntp.html@1.268 +2 -2 + NTP_4_2_7P270 + + sntp/sntp.man.in@1.88 +2 -2 + NTP_4_2_7P270 + + sntp/sntp.mdoc.in@1.88 +2 -2 + NTP_4_2_7P270 + + util/ntp-keygen-opts.c@1.272 +4 -4 + NTP_4_2_7P270 + + util/ntp-keygen-opts.h@1.272 +3 -3 + NTP_4_2_7P270 + + util/ntp-keygen-opts.texi@1.273 +2 -2 + NTP_4_2_7P270 + + util/ntp-keygen.1ntp-keygenman@1.86 +2 -2 + NTP_4_2_7P270 + + util/ntp-keygen.1ntp-keygenmdoc@1.86 +2 -2 + NTP_4_2_7P270 + + util/ntp-keygen.man.in@1.86 +2 -2 + NTP_4_2_7P270 + + util/ntp-keygen.mdoc.in@1.86 +2 -2 + NTP_4_2_7P270 + +ChangeSet@1.2772, 2012-03-26 05:12:44-04:00, stenn@deacon.udel.edu + Update driver45.html page + + ChangeLog@1.1145 +1 -0 + Update driver45.html page + + html/drivers/driver45.html@1.3 +1 -1 + Update driver45.html page + +ChangeSet@1.2771, 2012-03-25 05:07:53+00:00, stenn@deacon.udel.edu + NTP_4_2_7P269 + TAG: NTP_4_2_7P269 + + ChangeLog@1.1144 +1 -0 + NTP_4_2_7P269 + + ntpd/ntpd-opts.c@1.274 +4 -4 + NTP_4_2_7P269 + + ntpd/ntpd-opts.h@1.274 +3 -3 + NTP_4_2_7P269 + + ntpd/ntpd-opts.texi@1.272 +2 -2 + NTP_4_2_7P269 + + ntpd/ntpd.1ntpdman@1.85 +8 -548 + NTP_4_2_7P269 + + ntpd/ntpd.1ntpdmdoc@1.85 +8 -547 + NTP_4_2_7P269 + + ntpd/ntpd.man.in@1.85 +8 -548 + NTP_4_2_7P269 + + ntpd/ntpd.mdoc.in@1.85 +8 -547 + NTP_4_2_7P269 + + ntpdc/ntpdc-opts.c@1.269 +4 -4 + NTP_4_2_7P269 + + ntpdc/ntpdc-opts.h@1.269 +3 -3 + NTP_4_2_7P269 + + ntpdc/ntpdc-opts.texi@1.269 +2 -2 + NTP_4_2_7P269 + + ntpdc/ntpdc.1ntpdcman@1.85 +7 -704 + NTP_4_2_7P269 + + ntpdc/ntpdc.1ntpdcmdoc@1.85 +7 -659 + NTP_4_2_7P269 + + ntpdc/ntpdc.html@1.97 +2 -2 + NTP_4_2_7P269 + + ntpdc/ntpdc.man.in@1.85 +7 -704 + NTP_4_2_7P269 + + ntpdc/ntpdc.mdoc.in@1.85 +7 -659 + NTP_4_2_7P269 + + ntpq/ntpq-opts.c@1.271 +4 -4 + NTP_4_2_7P269 + + ntpq/ntpq-opts.h@1.271 +3 -3 + NTP_4_2_7P269 + + ntpq/ntpq-opts.texi@1.271 +2 -2 + NTP_4_2_7P269 + + ntpq/ntpq.1ntpqman@1.85 +3 -260 + NTP_4_2_7P269 + + ntpq/ntpq.1ntpqmdoc@1.85 +3 -245 + NTP_4_2_7P269 + + ntpq/ntpq.man.in@1.85 +3 -260 + NTP_4_2_7P269 + + ntpq/ntpq.mdoc.in@1.85 +3 -245 + NTP_4_2_7P269 + + ntpsnmpd/ntpsnmpd-opts.c@1.271 +4 -4 + NTP_4_2_7P269 + + ntpsnmpd/ntpsnmpd-opts.h@1.271 +3 -3 + NTP_4_2_7P269 + + ntpsnmpd/ntpsnmpd-opts.texi@1.271 +2 -2 + NTP_4_2_7P269 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.85 +4 -3 + NTP_4_2_7P269 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.85 +4 -3 + NTP_4_2_7P269 + + ntpsnmpd/ntpsnmpd.man.in@1.85 +4 -3 + NTP_4_2_7P269 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.85 +4 -3 + NTP_4_2_7P269 + + packageinfo.sh@1.272 +1 -1 + NTP_4_2_7P269 + + scripts/ntp-wait-opts.texi@1.89 +1 -1 + NTP_4_2_7P269 + + scripts/ntp-wait.1ntp-waitman@1.85 +4 -18 + NTP_4_2_7P269 + + scripts/ntp-wait.1ntp-waitmdoc@1.85 +4 -18 + NTP_4_2_7P269 + + scripts/ntp-wait.html@1.89 +1 -1 + NTP_4_2_7P269 + + scripts/ntp-wait.man.in@1.85 +4 -18 + NTP_4_2_7P269 + + scripts/ntp-wait.mdoc.in@1.85 +4 -18 + NTP_4_2_7P269 + + sntp/sntp-opts.c@1.267 +4 -4 + NTP_4_2_7P269 + + sntp/sntp-opts.h@1.267 +3 -3 + NTP_4_2_7P269 + + sntp/sntp-opts.texi@1.267 +2 -2 + NTP_4_2_7P269 + + sntp/sntp.1sntpman@1.87 +6 -65 + NTP_4_2_7P269 + + sntp/sntp.1sntpmdoc@1.87 +6 -65 + NTP_4_2_7P269 + + sntp/sntp.html@1.267 +2 -2 + NTP_4_2_7P269 + + sntp/sntp.man.in@1.87 +6 -65 + NTP_4_2_7P269 + + sntp/sntp.mdoc.in@1.87 +6 -65 + NTP_4_2_7P269 + + util/ntp-keygen-opts.c@1.271 +4 -4 + NTP_4_2_7P269 + + util/ntp-keygen-opts.h@1.271 +3 -3 + NTP_4_2_7P269 + + util/ntp-keygen-opts.texi@1.272 +2 -2 + NTP_4_2_7P269 + + util/ntp-keygen.1ntp-keygenman@1.85 +6 -720 + NTP_4_2_7P269 + + util/ntp-keygen.1ntp-keygenmdoc@1.85 +6 -706 + NTP_4_2_7P269 + + util/ntp-keygen.man.in@1.85 +6 -720 + NTP_4_2_7P269 + + util/ntp-keygen.mdoc.in@1.85 +6 -706 + NTP_4_2_7P269 + +ChangeSet@1.2770, 2012-03-24 22:19:50-04:00, stenn@deacon.udel.edu + Clean up configure.ac + + ChangeLog@1.1143 +1 -0 + Clean up configure.ac + + configure.ac@1.544 +221 -117 + Clean up configure.ac + +ChangeSet@1.2769, 2012-03-24 19:30:26-04:00, stenn@psp-deb1.ntp.org + Cleanup configure.ac's TSYNC PCI section + + ChangeLog@1.1142 +2 -0 + Cleanup configure.ac's TSYNC PCI section + + configure.ac@1.543 +2 -2 + Cleanup configure.ac's TSYNC PCI section + +ChangeSet@1.2762.1.43, 2012-03-24 11:22:52+00:00, stenn@deacon.udel.edu + NTP_4_2_7P268 + TAG: NTP_4_2_7P268 + + ChangeLog@1.1141 +1 -0 + NTP_4_2_7P268 + + ntpd/ntpd-opts.c@1.273 +4 -4 + NTP_4_2_7P268 + + ntpd/ntpd-opts.h@1.273 +3 -3 + NTP_4_2_7P268 + + ntpd/ntpd-opts.texi@1.271 +2 -2 + NTP_4_2_7P268 + + ntpd/ntpd.1ntpdman@1.84 +2 -2 + NTP_4_2_7P268 + + ntpd/ntpd.1ntpdmdoc@1.84 +2 -2 + NTP_4_2_7P268 + + ntpd/ntpd.man.in@1.84 +2 -2 + NTP_4_2_7P268 + + ntpd/ntpd.mdoc.in@1.84 +2 -2 + NTP_4_2_7P268 + + ntpdc/ntpdc-opts.c@1.268 +4 -4 + NTP_4_2_7P268 + + ntpdc/ntpdc-opts.h@1.268 +3 -3 + NTP_4_2_7P268 + + ntpdc/ntpdc-opts.texi@1.268 +2 -2 + NTP_4_2_7P268 + + ntpdc/ntpdc.1ntpdcman@1.84 +2 -2 + NTP_4_2_7P268 + + ntpdc/ntpdc.1ntpdcmdoc@1.84 +2 -2 + NTP_4_2_7P268 + + ntpdc/ntpdc.html@1.96 +2 -2 + NTP_4_2_7P268 + + ntpdc/ntpdc.man.in@1.84 +2 -2 + NTP_4_2_7P268 + + ntpdc/ntpdc.mdoc.in@1.84 +2 -2 + NTP_4_2_7P268 + + ntpq/ntpq-opts.c@1.270 +4 -4 + NTP_4_2_7P268 + + ntpq/ntpq-opts.h@1.270 +3 -3 + NTP_4_2_7P268 + + ntpq/ntpq-opts.texi@1.270 +2 -2 + NTP_4_2_7P268 + + ntpq/ntpq.1ntpqman@1.84 +2 -2 + NTP_4_2_7P268 + + ntpq/ntpq.1ntpqmdoc@1.84 +2 -2 + NTP_4_2_7P268 + + ntpq/ntpq.man.in@1.84 +2 -2 + NTP_4_2_7P268 + + ntpq/ntpq.mdoc.in@1.84 +2 -2 + NTP_4_2_7P268 + + ntpsnmpd/ntpsnmpd-opts.c@1.270 +4 -4 + NTP_4_2_7P268 + + ntpsnmpd/ntpsnmpd-opts.h@1.270 +3 -3 + NTP_4_2_7P268 + + ntpsnmpd/ntpsnmpd-opts.texi@1.270 +2 -2 + NTP_4_2_7P268 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.84 +2 -2 + NTP_4_2_7P268 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.84 +2 -2 + NTP_4_2_7P268 + + ntpsnmpd/ntpsnmpd.man.in@1.84 +2 -2 + NTP_4_2_7P268 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.84 +2 -2 + NTP_4_2_7P268 + + packageinfo.sh@1.271 +1 -1 + NTP_4_2_7P268 + + scripts/ntp-wait-opts.texi@1.88 +1 -1 + NTP_4_2_7P268 + + scripts/ntp-wait.1ntp-waitman@1.84 +2 -2 + NTP_4_2_7P268 + + scripts/ntp-wait.1ntp-waitmdoc@1.84 +2 -2 + NTP_4_2_7P268 + + scripts/ntp-wait.html@1.88 +1 -1 + NTP_4_2_7P268 + + scripts/ntp-wait.man.in@1.84 +2 -2 + NTP_4_2_7P268 + + scripts/ntp-wait.mdoc.in@1.84 +2 -2 + NTP_4_2_7P268 + + sntp/sntp-opts.c@1.266 +4 -4 + NTP_4_2_7P268 + + sntp/sntp-opts.h@1.266 +3 -3 + NTP_4_2_7P268 + + sntp/sntp-opts.texi@1.266 +2 -2 + NTP_4_2_7P268 + + sntp/sntp.1sntpman@1.86 +2 -2 + NTP_4_2_7P268 + + sntp/sntp.1sntpmdoc@1.86 +2 -2 + NTP_4_2_7P268 + + sntp/sntp.html@1.266 +2 -2 + NTP_4_2_7P268 + + sntp/sntp.man.in@1.86 +2 -2 + NTP_4_2_7P268 + + sntp/sntp.mdoc.in@1.86 +2 -2 + NTP_4_2_7P268 + + util/ntp-keygen-opts.c@1.270 +4 -4 + NTP_4_2_7P268 + + util/ntp-keygen-opts.h@1.270 +3 -3 + NTP_4_2_7P268 + + util/ntp-keygen-opts.texi@1.271 +2 -2 + NTP_4_2_7P268 + + util/ntp-keygen.1ntp-keygenman@1.84 +2 -2 + NTP_4_2_7P268 + + util/ntp-keygen.1ntp-keygenmdoc@1.84 +2 -2 + NTP_4_2_7P268 + + util/ntp-keygen.man.in@1.84 +2 -2 + NTP_4_2_7P268 + + util/ntp-keygen.mdoc.in@1.84 +2 -2 + NTP_4_2_7P268 + +ChangeSet@1.2762.1.42, 2012-03-23 21:50:58-04:00, stenn@deacon.udel.edu + reindent driver45.html + + html/drivers/driver45.html@1.2 +22 -22 + reindent driver45.html + +ChangeSet@1.2762.1.41, 2012-03-23 11:23:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P267 + TAG: NTP_4_2_7P267 + + ChangeLog@1.1140 +1 -0 + NTP_4_2_7P267 + + ntpd/ntpd-opts.c@1.272 +4 -4 + NTP_4_2_7P267 + + ntpd/ntpd-opts.h@1.272 +3 -3 + NTP_4_2_7P267 + + ntpd/ntpd-opts.texi@1.270 +2 -2 + NTP_4_2_7P267 + + ntpd/ntpd.1ntpdman@1.83 +2 -2 + NTP_4_2_7P267 + + ntpd/ntpd.1ntpdmdoc@1.83 +2 -2 + NTP_4_2_7P267 + + ntpd/ntpd.man.in@1.83 +2 -2 + NTP_4_2_7P267 + + ntpd/ntpd.mdoc.in@1.83 +2 -2 + NTP_4_2_7P267 + + ntpdc/ntpdc-opts.c@1.267 +4 -4 + NTP_4_2_7P267 + + ntpdc/ntpdc-opts.h@1.267 +3 -3 + NTP_4_2_7P267 + + ntpdc/ntpdc-opts.texi@1.267 +2 -2 + NTP_4_2_7P267 + + ntpdc/ntpdc.1ntpdcman@1.83 +2 -2 + NTP_4_2_7P267 + + ntpdc/ntpdc.1ntpdcmdoc@1.83 +2 -2 + NTP_4_2_7P267 + + ntpdc/ntpdc.html@1.95 +2 -2 + NTP_4_2_7P267 + + ntpdc/ntpdc.man.in@1.83 +2 -2 + NTP_4_2_7P267 + + ntpdc/ntpdc.mdoc.in@1.83 +2 -2 + NTP_4_2_7P267 + + ntpq/ntpq-opts.c@1.269 +4 -4 + NTP_4_2_7P267 + + ntpq/ntpq-opts.h@1.269 +3 -3 + NTP_4_2_7P267 + + ntpq/ntpq-opts.texi@1.269 +2 -2 + NTP_4_2_7P267 + + ntpq/ntpq.1ntpqman@1.83 +2 -2 + NTP_4_2_7P267 + + ntpq/ntpq.1ntpqmdoc@1.83 +2 -2 + NTP_4_2_7P267 + + ntpq/ntpq.man.in@1.83 +2 -2 + NTP_4_2_7P267 + + ntpq/ntpq.mdoc.in@1.83 +2 -2 + NTP_4_2_7P267 + + ntpsnmpd/ntpsnmpd-opts.c@1.269 +4 -4 + NTP_4_2_7P267 + + ntpsnmpd/ntpsnmpd-opts.h@1.269 +3 -3 + NTP_4_2_7P267 + + ntpsnmpd/ntpsnmpd-opts.texi@1.269 +2 -2 + NTP_4_2_7P267 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.83 +2 -2 + NTP_4_2_7P267 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.83 +2 -2 + NTP_4_2_7P267 + + ntpsnmpd/ntpsnmpd.man.in@1.83 +2 -2 + NTP_4_2_7P267 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.83 +2 -2 + NTP_4_2_7P267 + + packageinfo.sh@1.270 +1 -1 + NTP_4_2_7P267 + + scripts/ntp-wait-opts.texi@1.87 +1 -1 + NTP_4_2_7P267 + + scripts/ntp-wait.1ntp-waitman@1.83 +2 -2 + NTP_4_2_7P267 + + scripts/ntp-wait.1ntp-waitmdoc@1.83 +2 -2 + NTP_4_2_7P267 + + scripts/ntp-wait.html@1.87 +1 -1 + NTP_4_2_7P267 + + scripts/ntp-wait.man.in@1.83 +2 -2 + NTP_4_2_7P267 + + scripts/ntp-wait.mdoc.in@1.83 +2 -2 + NTP_4_2_7P267 + + sntp/sntp-opts.c@1.265 +4 -4 + NTP_4_2_7P267 + + sntp/sntp-opts.h@1.265 +3 -3 + NTP_4_2_7P267 + + sntp/sntp-opts.texi@1.265 +2 -2 + NTP_4_2_7P267 + + sntp/sntp.1sntpman@1.85 +2 -2 + NTP_4_2_7P267 + + sntp/sntp.1sntpmdoc@1.85 +2 -2 + NTP_4_2_7P267 + + sntp/sntp.html@1.265 +2 -2 + NTP_4_2_7P267 + + sntp/sntp.man.in@1.85 +2 -2 + NTP_4_2_7P267 + + sntp/sntp.mdoc.in@1.85 +2 -2 + NTP_4_2_7P267 + + util/ntp-keygen-opts.c@1.269 +4 -4 + NTP_4_2_7P267 + + util/ntp-keygen-opts.h@1.269 +3 -3 + NTP_4_2_7P267 + + util/ntp-keygen-opts.texi@1.270 +2 -2 + NTP_4_2_7P267 + + util/ntp-keygen.1ntp-keygenman@1.83 +2 -2 + NTP_4_2_7P267 + + util/ntp-keygen.1ntp-keygenmdoc@1.83 +2 -2 + NTP_4_2_7P267 + + util/ntp-keygen.man.in@1.83 +2 -2 + NTP_4_2_7P267 + + util/ntp-keygen.mdoc.in@1.83 +2 -2 + NTP_4_2_7P267 + +ChangeSet@1.2762.1.40, 2012-03-22 20:20:29-04:00, stenn@deacon.udel.edu + Initial cut at a basic driver45.html page + + ChangeLog@1.1139 +1 -0 + Initial cut at a basic driver45.html page + + html/drivers/driver45.html@1.1 +29 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/drivers/driver45.html + + html/drivers/driver45.html@1.0 +0 -0 + +ChangeSet@1.2762.1.39, 2012-03-21 11:24:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P266 + TAG: NTP_4_2_7P266 + + ChangeLog@1.1138 +1 -0 + NTP_4_2_7P266 + + ntpd/ntpd-opts.c@1.271 +4 -4 + NTP_4_2_7P266 + + ntpd/ntpd-opts.h@1.271 +3 -3 + NTP_4_2_7P266 + + ntpd/ntpd-opts.texi@1.269 +2 -2 + NTP_4_2_7P266 + + ntpd/ntpd.1ntpdman@1.82 +2 -2 + NTP_4_2_7P266 + + ntpd/ntpd.1ntpdmdoc@1.82 +2 -2 + NTP_4_2_7P266 + + ntpd/ntpd.man.in@1.82 +2 -2 + NTP_4_2_7P266 + + ntpd/ntpd.mdoc.in@1.82 +2 -2 + NTP_4_2_7P266 + + ntpdc/ntpdc-opts.c@1.266 +4 -4 + NTP_4_2_7P266 + + ntpdc/ntpdc-opts.h@1.266 +3 -3 + NTP_4_2_7P266 + + ntpdc/ntpdc-opts.texi@1.266 +2 -2 + NTP_4_2_7P266 + + ntpdc/ntpdc.1ntpdcman@1.82 +2 -2 + NTP_4_2_7P266 + + ntpdc/ntpdc.1ntpdcmdoc@1.82 +2 -2 + NTP_4_2_7P266 + + ntpdc/ntpdc.html@1.94 +2 -2 + NTP_4_2_7P266 + + ntpdc/ntpdc.man.in@1.82 +2 -2 + NTP_4_2_7P266 + + ntpdc/ntpdc.mdoc.in@1.82 +2 -2 + NTP_4_2_7P266 + + ntpq/ntpq-opts.c@1.268 +4 -4 + NTP_4_2_7P266 + + ntpq/ntpq-opts.h@1.268 +3 -3 + NTP_4_2_7P266 + + ntpq/ntpq-opts.texi@1.268 +2 -2 + NTP_4_2_7P266 + + ntpq/ntpq.1ntpqman@1.82 +2 -2 + NTP_4_2_7P266 + + ntpq/ntpq.1ntpqmdoc@1.82 +2 -2 + NTP_4_2_7P266 + + ntpq/ntpq.man.in@1.82 +2 -2 + NTP_4_2_7P266 + + ntpq/ntpq.mdoc.in@1.82 +2 -2 + NTP_4_2_7P266 + + ntpsnmpd/ntpsnmpd-opts.c@1.268 +4 -4 + NTP_4_2_7P266 + + ntpsnmpd/ntpsnmpd-opts.h@1.268 +3 -3 + NTP_4_2_7P266 + + ntpsnmpd/ntpsnmpd-opts.texi@1.268 +2 -2 + NTP_4_2_7P266 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.82 +2 -2 + NTP_4_2_7P266 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.82 +2 -2 + NTP_4_2_7P266 + + ntpsnmpd/ntpsnmpd.man.in@1.82 +2 -2 + NTP_4_2_7P266 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.82 +2 -2 + NTP_4_2_7P266 + + packageinfo.sh@1.269 +1 -1 + NTP_4_2_7P266 + + scripts/ntp-wait-opts.texi@1.86 +1 -1 + NTP_4_2_7P266 + + scripts/ntp-wait.1ntp-waitman@1.82 +2 -2 + NTP_4_2_7P266 + + scripts/ntp-wait.1ntp-waitmdoc@1.82 +2 -2 + NTP_4_2_7P266 + + scripts/ntp-wait.html@1.86 +1 -1 + NTP_4_2_7P266 + + scripts/ntp-wait.man.in@1.82 +2 -2 + NTP_4_2_7P266 + + scripts/ntp-wait.mdoc.in@1.82 +2 -2 + NTP_4_2_7P266 + + sntp/sntp-opts.c@1.264 +4 -4 + NTP_4_2_7P266 + + sntp/sntp-opts.h@1.264 +3 -3 + NTP_4_2_7P266 + + sntp/sntp-opts.texi@1.264 +2 -2 + NTP_4_2_7P266 + + sntp/sntp.1sntpman@1.84 +2 -2 + NTP_4_2_7P266 + + sntp/sntp.1sntpmdoc@1.84 +2 -2 + NTP_4_2_7P266 + + sntp/sntp.html@1.264 +2 -2 + NTP_4_2_7P266 + + sntp/sntp.man.in@1.84 +2 -2 + NTP_4_2_7P266 + + sntp/sntp.mdoc.in@1.84 +2 -2 + NTP_4_2_7P266 + + util/ntp-keygen-opts.c@1.268 +4 -4 + NTP_4_2_7P266 + + util/ntp-keygen-opts.h@1.268 +3 -3 + NTP_4_2_7P266 + + util/ntp-keygen-opts.texi@1.269 +2 -2 + NTP_4_2_7P266 + + util/ntp-keygen.1ntp-keygenman@1.82 +2 -2 + NTP_4_2_7P266 + + util/ntp-keygen.1ntp-keygenmdoc@1.82 +2 -2 + NTP_4_2_7P266 + + util/ntp-keygen.man.in@1.82 +2 -2 + NTP_4_2_7P266 + + util/ntp-keygen.mdoc.in@1.82 +2 -2 + NTP_4_2_7P266 + +ChangeSet@1.2762.1.38, 2012-03-21 05:23:41+00:00, hart@psp-os1.ntp.org + refclock_tsyncpci.c: + Change mode to -rw-rw-r-- + + ntpd/refclock_tsyncpci.c@1.4 +0 -0 + Change mode to -rw-rw-r-- + + ntpd/refclock_tsyncpci.c@1.3 +0 -0 + Change mode to -rw-r--r-- + +ChangeSet@1.2762.1.36, 2012-03-21 03:04:51+00:00, davehart@dlh-7551.ad.hartbrothers.com + Include Linux-specific refclock_tsyncpci.c in --enable-all-clocks only + on Linux. + Clean up configure.ac m4 quoting, indents to match current style. + + configure.ac@1.542 +18 -5 + Include Linux-specific refclock_tsyncpci.c in --enable-all-clocks only + on Linux. + Clean up m4 quoting, indents to match current style. + + ntpd/refclock_tsyncpci.c@1.2 +3 -1 + protect sys/ioctl.h include with HAVE_SYS_IOCTL_H + +ChangeSet@1.2762.10.1, 2012-03-20 11:25:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P265 + TAG: NTP_4_2_7P265 + + ChangeLog@1.1135.1.1 +1 -0 + NTP_4_2_7P265 + + ntpd/ntpd-opts.c@1.270 +4 -4 + NTP_4_2_7P265 + + ntpd/ntpd-opts.h@1.270 +3 -3 + NTP_4_2_7P265 + + ntpd/ntpd-opts.texi@1.268 +2 -2 + NTP_4_2_7P265 + + ntpd/ntpd.1ntpdman@1.81 +2 -2 + NTP_4_2_7P265 + + ntpd/ntpd.1ntpdmdoc@1.81 +2 -2 + NTP_4_2_7P265 + + ntpd/ntpd.man.in@1.81 +2 -2 + NTP_4_2_7P265 + + ntpd/ntpd.mdoc.in@1.81 +2 -2 + NTP_4_2_7P265 + + ntpdc/ntpdc-opts.c@1.265 +4 -4 + NTP_4_2_7P265 + + ntpdc/ntpdc-opts.h@1.265 +3 -3 + NTP_4_2_7P265 + + ntpdc/ntpdc-opts.texi@1.265 +2 -2 + NTP_4_2_7P265 + + ntpdc/ntpdc.1ntpdcman@1.81 +2 -2 + NTP_4_2_7P265 + + ntpdc/ntpdc.1ntpdcmdoc@1.81 +2 -2 + NTP_4_2_7P265 + + ntpdc/ntpdc.html@1.93 +2 -2 + NTP_4_2_7P265 + + ntpdc/ntpdc.man.in@1.81 +2 -2 + NTP_4_2_7P265 + + ntpdc/ntpdc.mdoc.in@1.81 +2 -2 + NTP_4_2_7P265 + + ntpq/ntpq-opts.c@1.267 +4 -4 + NTP_4_2_7P265 + + ntpq/ntpq-opts.h@1.267 +3 -3 + NTP_4_2_7P265 + + ntpq/ntpq-opts.texi@1.267 +2 -2 + NTP_4_2_7P265 + + ntpq/ntpq.1ntpqman@1.81 +2 -2 + NTP_4_2_7P265 + + ntpq/ntpq.1ntpqmdoc@1.81 +2 -2 + NTP_4_2_7P265 + + ntpq/ntpq.man.in@1.81 +2 -2 + NTP_4_2_7P265 + + ntpq/ntpq.mdoc.in@1.81 +2 -2 + NTP_4_2_7P265 + + ntpsnmpd/ntpsnmpd-opts.c@1.267 +4 -4 + NTP_4_2_7P265 + + ntpsnmpd/ntpsnmpd-opts.h@1.267 +3 -3 + NTP_4_2_7P265 + + ntpsnmpd/ntpsnmpd-opts.texi@1.267 +2 -2 + NTP_4_2_7P265 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.81 +2 -2 + NTP_4_2_7P265 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.81 +2 -2 + NTP_4_2_7P265 + + ntpsnmpd/ntpsnmpd.man.in@1.81 +2 -2 + NTP_4_2_7P265 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.81 +2 -2 + NTP_4_2_7P265 + + packageinfo.sh@1.268 +1 -1 + NTP_4_2_7P265 + + scripts/ntp-wait-opts.texi@1.85 +1 -1 + NTP_4_2_7P265 + + scripts/ntp-wait.1ntp-waitman@1.81 +2 -2 + NTP_4_2_7P265 + + scripts/ntp-wait.1ntp-waitmdoc@1.81 +2 -2 + NTP_4_2_7P265 + + scripts/ntp-wait.html@1.85 +1 -1 + NTP_4_2_7P265 + + scripts/ntp-wait.man.in@1.81 +2 -2 + NTP_4_2_7P265 + + scripts/ntp-wait.mdoc.in@1.81 +2 -2 + NTP_4_2_7P265 + + sntp/sntp-opts.c@1.263 +4 -4 + NTP_4_2_7P265 + + sntp/sntp-opts.h@1.263 +3 -3 + NTP_4_2_7P265 + + sntp/sntp-opts.texi@1.263 +2 -2 + NTP_4_2_7P265 + + sntp/sntp.1sntpman@1.83 +2 -2 + NTP_4_2_7P265 + + sntp/sntp.1sntpmdoc@1.83 +2 -2 + NTP_4_2_7P265 + + sntp/sntp.html@1.263 +2 -2 + NTP_4_2_7P265 + + sntp/sntp.man.in@1.83 +2 -2 + NTP_4_2_7P265 + + sntp/sntp.mdoc.in@1.83 +2 -2 + NTP_4_2_7P265 + + util/ntp-keygen-opts.c@1.267 +4 -4 + NTP_4_2_7P265 + + util/ntp-keygen-opts.h@1.267 +3 -3 + NTP_4_2_7P265 + + util/ntp-keygen-opts.texi@1.268 +2 -2 + NTP_4_2_7P265 + + util/ntp-keygen.1ntp-keygenman@1.81 +2 -2 + NTP_4_2_7P265 + + util/ntp-keygen.1ntp-keygenmdoc@1.81 +2 -2 + NTP_4_2_7P265 + + util/ntp-keygen.man.in@1.81 +2 -2 + NTP_4_2_7P265 + + util/ntp-keygen.mdoc.in@1.81 +2 -2 + NTP_4_2_7P265 + +ChangeSet@1.2762.1.35, 2012-03-20 06:29:13+00:00, davehart@dlh-7551.ad.hartbrothers.com + Add reference to refclock_tsyncpci.c to ntpd.vcproj + + ports/winnt/vs2005/ntpd.vcproj@1.17 +4 -0 + Add reference to refclock_tsyncpci.c + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.43 +4 -0 + Add reference to refclock_tsyncpci.c + +ChangeSet@1.2762.1.34, 2012-03-20 06:18:59+00:00, davehart@dlh-7551.ad.hartbrothers.com + Spectracom TSYNC reference clock driver from tsync.2.5.0.tar.gz downloaded from + http://www.spectracomcorp.com/Support/HowCanWeHelpYou/Library/tabid/59/Default.aspx?EntryId=107 + (see linux/ntp/tsync.patch) + + ChangeLog@1.1136 +2 -0 + david.sohn@spectracom.orolia.com + + configure.ac@1.541 +11 -0 + Spectracom TSYNC reference clock driver from tsync.2.5.0.tar.gz + + include/ntp.h@1.204 +2 -1 + Spectracom TSYNC reference clock driver from tsync.2.5.0.tar.gz + + libntp/clocktypes.c@1.20 +2 -0 + Spectracom TSYNC reference clock driver from tsync.2.5.0.tar.gz + + ntpd/Makefile.am@1.112.1.2 +1 -0 + Spectracom TSYNC reference clock driver from tsync.2.5.0.tar.gz + + ntpd/ntp_control.c@1.180 +1 -0 + Spectracom TSYNC reference clock driver from tsync.2.5.0.tar.gz + + ntpd/refclock_conf.c@1.32 +7 -1 + Spectracom TSYNC reference clock driver from tsync.2.5.0.tar.gz + + ntpd/refclock_tsyncpci.c@1.1 +926 -0 + Via email from david.sohn@spectracom.orolia.com 19 Mar 2012 + + ntpd/refclock_tsyncpci.c@1.0 +0 -0 + +ChangeSet@1.2762.1.33, 2012-03-20 06:03:15+00:00, davehart@dlh-7551.ad.hartbrothers.com + Treat zero counter as indication of precise system time in Windows + PPSAPI helper function pps_ntp_timestamp_from_counter(), enabling + PPSAPI providers to use the Windows 8 precise clock directly. + + ChangeLog@1.1135 +3 -0 + Treat zero counter as indication of precise system time in Windows + PPSAPI helper function pps_ntp_timestamp_from_counter(), enabling + PPSAPI providers to use the Windows 8 precise clock directly. + + ports/winnt/include/clockstuff.h@1.13 +0 -9 + Treat zero counter as indication of precise system time in Windows + PPSAPI helper function pps_ntp_timestamp_from_counter(), enabling + PPSAPI providers to use the Windows 8 precise clock directly. + + ports/winnt/ntpd/nt_clockstuff.c@1.58 +6 -37 + Treat zero counter as indication of precise system time in Windows + PPSAPI helper function pps_ntp_timestamp_from_counter(), enabling + PPSAPI providers to use the Windows 8 precise clock directly. + +ChangeSet@1.2762.1.32, 2012-03-14 07:58:25+00:00, stenn@deacon.udel.edu + NTP_4_2_7P264 + TAG: NTP_4_2_7P264 + + ChangeLog@1.1134 +1 -0 + NTP_4_2_7P264 + + ntpd/ntpd-opts.c@1.269 +4 -4 + NTP_4_2_7P264 + + ntpd/ntpd-opts.h@1.269 +3 -3 + NTP_4_2_7P264 + + ntpd/ntpd-opts.texi@1.267 +2 -2 + NTP_4_2_7P264 + + ntpd/ntpd.1ntpdman@1.80 +2 -2 + NTP_4_2_7P264 + + ntpd/ntpd.1ntpdmdoc@1.80 +2 -2 + NTP_4_2_7P264 + + ntpd/ntpd.man.in@1.80 +2 -2 + NTP_4_2_7P264 + + ntpd/ntpd.mdoc.in@1.80 +2 -2 + NTP_4_2_7P264 + + ntpdc/ntpdc-opts.c@1.264 +4 -4 + NTP_4_2_7P264 + + ntpdc/ntpdc-opts.h@1.264 +3 -3 + NTP_4_2_7P264 + + ntpdc/ntpdc-opts.texi@1.264 +2 -2 + NTP_4_2_7P264 + + ntpdc/ntpdc.1ntpdcman@1.80 +2 -2 + NTP_4_2_7P264 + + ntpdc/ntpdc.1ntpdcmdoc@1.80 +2 -2 + NTP_4_2_7P264 + + ntpdc/ntpdc.html@1.92 +2 -2 + NTP_4_2_7P264 + + ntpdc/ntpdc.man.in@1.80 +2 -2 + NTP_4_2_7P264 + + ntpdc/ntpdc.mdoc.in@1.80 +2 -2 + NTP_4_2_7P264 + + ntpq/ntpq-opts.c@1.266 +4 -4 + NTP_4_2_7P264 + + ntpq/ntpq-opts.h@1.266 +3 -3 + NTP_4_2_7P264 + + ntpq/ntpq-opts.texi@1.266 +2 -2 + NTP_4_2_7P264 + + ntpq/ntpq.1ntpqman@1.80 +2 -2 + NTP_4_2_7P264 + + ntpq/ntpq.1ntpqmdoc@1.80 +2 -2 + NTP_4_2_7P264 + + ntpq/ntpq.man.in@1.80 +2 -2 + NTP_4_2_7P264 + + ntpq/ntpq.mdoc.in@1.80 +2 -2 + NTP_4_2_7P264 + + ntpsnmpd/ntpsnmpd-opts.c@1.266 +4 -4 + NTP_4_2_7P264 + + ntpsnmpd/ntpsnmpd-opts.h@1.266 +3 -3 + NTP_4_2_7P264 + + ntpsnmpd/ntpsnmpd-opts.texi@1.266 +2 -2 + NTP_4_2_7P264 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.80 +2 -2 + NTP_4_2_7P264 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.80 +2 -2 + NTP_4_2_7P264 + + ntpsnmpd/ntpsnmpd.man.in@1.80 +2 -2 + NTP_4_2_7P264 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.80 +2 -2 + NTP_4_2_7P264 + + packageinfo.sh@1.267 +1 -1 + NTP_4_2_7P264 + + scripts/ntp-wait-opts.texi@1.84 +1 -1 + NTP_4_2_7P264 + + scripts/ntp-wait.1ntp-waitman@1.80 +2 -2 + NTP_4_2_7P264 + + scripts/ntp-wait.1ntp-waitmdoc@1.80 +2 -2 + NTP_4_2_7P264 + + scripts/ntp-wait.html@1.84 +1 -1 + NTP_4_2_7P264 + + scripts/ntp-wait.man.in@1.80 +2 -2 + NTP_4_2_7P264 + + scripts/ntp-wait.mdoc.in@1.80 +2 -2 + NTP_4_2_7P264 + + sntp/sntp-opts.c@1.262 +4 -4 + NTP_4_2_7P264 + + sntp/sntp-opts.h@1.262 +3 -3 + NTP_4_2_7P264 + + sntp/sntp-opts.texi@1.262 +2 -2 + NTP_4_2_7P264 + + sntp/sntp.1sntpman@1.82 +2 -2 + NTP_4_2_7P264 + + sntp/sntp.1sntpmdoc@1.82 +2 -2 + NTP_4_2_7P264 + + sntp/sntp.html@1.262 +2 -2 + NTP_4_2_7P264 + + sntp/sntp.man.in@1.82 +2 -2 + NTP_4_2_7P264 + + sntp/sntp.mdoc.in@1.82 +2 -2 + NTP_4_2_7P264 + + util/ntp-keygen-opts.c@1.266 +4 -4 + NTP_4_2_7P264 + + util/ntp-keygen-opts.h@1.266 +3 -3 + NTP_4_2_7P264 + + util/ntp-keygen-opts.texi@1.267 +2 -2 + NTP_4_2_7P264 + + util/ntp-keygen.1ntp-keygenman@1.80 +2 -2 + NTP_4_2_7P264 + + util/ntp-keygen.1ntp-keygenmdoc@1.80 +2 -2 + NTP_4_2_7P264 + + util/ntp-keygen.man.in@1.80 +2 -2 + NTP_4_2_7P264 + + util/ntp-keygen.mdoc.in@1.80 +2 -2 + NTP_4_2_7P264 + +ChangeSet@1.2762.1.31, 2012-03-13 09:31:09+00:00, davehart@dlh-7551.ad.hartbrothers.com + Quiet "DAY" redefinition warning compiling ntp-keygen.c + + util/ntp-keygen.c@1.91 +0 -1 + Quiet "DAY" redefinition warning. + +ChangeSet@1.2762.1.30, 2012-03-13 09:22:37+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2160] Note if leapseconds file is past its prime. + + ChangeLog@1.1133 +1 -0 + [Bug 2160] Note if leapseconds file is past its prime. + + ntpd/ntp_util.c@1.97 +10 -3 + [Bug 2160] Note if leapseconds file is past its prime. + +ChangeSet@1.2762.1.29, 2012-03-13 09:02:35+00:00, davehart@dlh-7551.ad.hartbrothers.com + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + ChangeLog@1.1132 +1 -0 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + include/ntp_fp.h@1.30 +4 -0 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + libntp/systime.c@1.65 +1 -0 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + ports/winnt/include/clockstuff.h@1.12 +2 -1 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + ports/winnt/include/sys/time.h@1.8 +1 -0 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + ports/winnt/libntp/getclock.c@1.4 +20 -8 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + ports/winnt/ntpd/nt_clockstuff.c@1.57 +74 -49 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + + util/ntp-keygen.c@1.90 +1 -1 + Use GetSystemTimePreciseAsFileTime() on Windows 8. + +ChangeSet@1.2762.1.28, 2012-03-13 03:57:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P263 + TAG: NTP_4_2_7P263 + + ChangeLog@1.1131 +1 -0 + NTP_4_2_7P263 + + ntpd/ntpd-opts.c@1.268 +4 -4 + NTP_4_2_7P263 + + ntpd/ntpd-opts.h@1.268 +3 -3 + NTP_4_2_7P263 + + ntpd/ntpd-opts.texi@1.266 +2 -2 + NTP_4_2_7P263 + + ntpd/ntpd.1ntpdman@1.79 +2 -2 + NTP_4_2_7P263 + + ntpd/ntpd.1ntpdmdoc@1.79 +2 -2 + NTP_4_2_7P263 + + ntpd/ntpd.man.in@1.79 +2 -2 + NTP_4_2_7P263 + + ntpd/ntpd.mdoc.in@1.79 +2 -2 + NTP_4_2_7P263 + + ntpdc/ntpdc-opts.c@1.263 +4 -4 + NTP_4_2_7P263 + + ntpdc/ntpdc-opts.h@1.263 +3 -3 + NTP_4_2_7P263 + + ntpdc/ntpdc-opts.texi@1.263 +2 -2 + NTP_4_2_7P263 + + ntpdc/ntpdc.1ntpdcman@1.79 +2 -2 + NTP_4_2_7P263 + + ntpdc/ntpdc.1ntpdcmdoc@1.79 +2 -2 + NTP_4_2_7P263 + + ntpdc/ntpdc.html@1.91 +2 -2 + NTP_4_2_7P263 + + ntpdc/ntpdc.man.in@1.79 +2 -2 + NTP_4_2_7P263 + + ntpdc/ntpdc.mdoc.in@1.79 +2 -2 + NTP_4_2_7P263 + + ntpq/ntpq-opts.c@1.265 +4 -4 + NTP_4_2_7P263 + + ntpq/ntpq-opts.h@1.265 +3 -3 + NTP_4_2_7P263 + + ntpq/ntpq-opts.texi@1.265 +2 -2 + NTP_4_2_7P263 + + ntpq/ntpq.1ntpqman@1.79 +2 -2 + NTP_4_2_7P263 + + ntpq/ntpq.1ntpqmdoc@1.79 +2 -2 + NTP_4_2_7P263 + + ntpq/ntpq.man.in@1.79 +2 -2 + NTP_4_2_7P263 + + ntpq/ntpq.mdoc.in@1.79 +2 -2 + NTP_4_2_7P263 + + ntpsnmpd/ntpsnmpd-opts.c@1.265 +4 -4 + NTP_4_2_7P263 + + ntpsnmpd/ntpsnmpd-opts.h@1.265 +3 -3 + NTP_4_2_7P263 + + ntpsnmpd/ntpsnmpd-opts.texi@1.265 +2 -2 + NTP_4_2_7P263 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.79 +2 -2 + NTP_4_2_7P263 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.79 +2 -2 + NTP_4_2_7P263 + + ntpsnmpd/ntpsnmpd.man.in@1.79 +2 -2 + NTP_4_2_7P263 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.79 +2 -2 + NTP_4_2_7P263 + + packageinfo.sh@1.266 +1 -1 + NTP_4_2_7P263 + + scripts/ntp-wait-opts.texi@1.83 +2 -14 + NTP_4_2_7P263 + + scripts/ntp-wait.1ntp-waitman@1.79 +2 -2 + NTP_4_2_7P263 + + scripts/ntp-wait.1ntp-waitmdoc@1.79 +2 -2 + NTP_4_2_7P263 + + scripts/ntp-wait.html@1.83 +2 -14 + NTP_4_2_7P263 + + scripts/ntp-wait.man.in@1.79 +2 -2 + NTP_4_2_7P263 + + scripts/ntp-wait.mdoc.in@1.79 +2 -2 + NTP_4_2_7P263 + + sntp/sntp-opts.c@1.261 +4 -4 + NTP_4_2_7P263 + + sntp/sntp-opts.h@1.261 +3 -3 + NTP_4_2_7P263 + + sntp/sntp-opts.texi@1.261 +2 -2 + NTP_4_2_7P263 + + sntp/sntp.1sntpman@1.81 +2 -2 + NTP_4_2_7P263 + + sntp/sntp.1sntpmdoc@1.81 +2 -2 + NTP_4_2_7P263 + + sntp/sntp.html@1.261 +2 -2 + NTP_4_2_7P263 + + sntp/sntp.man.in@1.81 +2 -2 + NTP_4_2_7P263 + + sntp/sntp.mdoc.in@1.81 +2 -2 + NTP_4_2_7P263 + + util/ntp-keygen-opts.c@1.265 +4 -4 + NTP_4_2_7P263 + + util/ntp-keygen-opts.h@1.265 +3 -3 + NTP_4_2_7P263 + + util/ntp-keygen-opts.texi@1.266 +2 -2 + NTP_4_2_7P263 + + util/ntp-keygen.1ntp-keygenman@1.79 +2 -2 + NTP_4_2_7P263 + + util/ntp-keygen.1ntp-keygenmdoc@1.79 +2 -2 + NTP_4_2_7P263 + + util/ntp-keygen.man.in@1.79 +2 -2 + NTP_4_2_7P263 + + util/ntp-keygen.mdoc.in@1.79 +2 -2 + NTP_4_2_7P263 + +ChangeSet@1.2762.1.27, 2012-03-11 07:10:54+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2159] Windows ntpd using leapfile erroneous leap second 20120401. + + ChangeLog@1.1130 +1 -0 + [Bug 2159] Windows ntpd using leapfile erroneous leap second 20120401. + + include/ntp_stdlib.h@1.72 +4 -0 + [Bug 2159] Windows ntpd using leapfile erroneous leap second 20120401. + + ntpd/ntp_timer.c@1.68 +0 -4 + [Bug 2159] Windows ntpd using leapfile erroneous leap second 20120401. + + ports/winnt/ntpd/nt_clockstuff.c@1.56 +4 -3 + [Bug 2159] Windows ntpd using leapfile erroneous leap second 20120401. + +ChangeSet@1.2762.1.26, 2012-03-10 17:27:45+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2156] clock instability with LOCAL driver, from Miroslav Lichvar. + + ChangeLog@1.1129 +1 -0 + [Bug 2156] clock instability with LOCAL driver, from Miroslav Lichvar. + + ntpd/ntp_proto.c@1.340 +1 -1 + [Bug 2156] clock instability with LOCAL driver, from Miroslav Lichvar. + +ChangeSet@1.2082.4.263, 2012-03-10 04:49:48-05:00, stenn@deacon.udel.edu + Update 2mirror trigger to copy directly to bk2 + + BitKeeper/triggers/2mirrors@1.7.1.1 +5 -3 + Update 2mirror trigger to copy directly to bk2 + +ChangeSet@1.2762.1.24, 2012-02-29 01:27:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P262 + TAG: NTP_4_2_7P262 + + ChangeLog@1.1128 +1 -0 + NTP_4_2_7P262 + + ntpd/ntpd-opts.c@1.267 +4 -4 + NTP_4_2_7P262 + + ntpd/ntpd-opts.h@1.267 +3 -3 + NTP_4_2_7P262 + + ntpd/ntpd-opts.texi@1.265 +2 -2 + NTP_4_2_7P262 + + ntpd/ntpd.1ntpdman@1.78 +2 -2 + NTP_4_2_7P262 + + ntpd/ntpd.1ntpdmdoc@1.78 +2 -2 + NTP_4_2_7P262 + + ntpd/ntpd.man.in@1.78 +2 -2 + NTP_4_2_7P262 + + ntpd/ntpd.mdoc.in@1.78 +2 -2 + NTP_4_2_7P262 + + ntpdc/ntpdc-opts.c@1.262 +4 -4 + NTP_4_2_7P262 + + ntpdc/ntpdc-opts.h@1.262 +3 -3 + NTP_4_2_7P262 + + ntpdc/ntpdc-opts.texi@1.262 +2 -2 + NTP_4_2_7P262 + + ntpdc/ntpdc.1ntpdcman@1.78 +2 -2 + NTP_4_2_7P262 + + ntpdc/ntpdc.1ntpdcmdoc@1.78 +2 -2 + NTP_4_2_7P262 + + ntpdc/ntpdc.html@1.90 +2 -2 + NTP_4_2_7P262 + + ntpdc/ntpdc.man.in@1.78 +2 -2 + NTP_4_2_7P262 + + ntpdc/ntpdc.mdoc.in@1.78 +2 -2 + NTP_4_2_7P262 + + ntpq/ntpq-opts.c@1.264 +4 -4 + NTP_4_2_7P262 + + ntpq/ntpq-opts.h@1.264 +3 -3 + NTP_4_2_7P262 + + ntpq/ntpq-opts.texi@1.264 +2 -2 + NTP_4_2_7P262 + + ntpq/ntpq.1ntpqman@1.78 +2 -2 + NTP_4_2_7P262 + + ntpq/ntpq.1ntpqmdoc@1.78 +2 -2 + NTP_4_2_7P262 + + ntpq/ntpq.man.in@1.78 +2 -2 + NTP_4_2_7P262 + + ntpq/ntpq.mdoc.in@1.78 +2 -2 + NTP_4_2_7P262 + + ntpsnmpd/ntpsnmpd-opts.c@1.264 +4 -4 + NTP_4_2_7P262 + + ntpsnmpd/ntpsnmpd-opts.h@1.264 +3 -3 + NTP_4_2_7P262 + + ntpsnmpd/ntpsnmpd-opts.texi@1.264 +2 -2 + NTP_4_2_7P262 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.78 +2 -2 + NTP_4_2_7P262 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.78 +2 -2 + NTP_4_2_7P262 + + ntpsnmpd/ntpsnmpd.man.in@1.78 +2 -2 + NTP_4_2_7P262 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.78 +2 -2 + NTP_4_2_7P262 + + packageinfo.sh@1.265 +1 -1 + NTP_4_2_7P262 + + scripts/ntp-wait-opts.texi@1.82 +1 -1 + NTP_4_2_7P262 + + scripts/ntp-wait.1ntp-waitman@1.78 +2 -2 + NTP_4_2_7P262 + + scripts/ntp-wait.1ntp-waitmdoc@1.78 +2 -2 + NTP_4_2_7P262 + + scripts/ntp-wait.html@1.82 +1 -1 + NTP_4_2_7P262 + + scripts/ntp-wait.man.in@1.78 +2 -2 + NTP_4_2_7P262 + + scripts/ntp-wait.mdoc.in@1.78 +2 -2 + NTP_4_2_7P262 + + sntp/sntp-opts.c@1.260 +4 -4 + NTP_4_2_7P262 + + sntp/sntp-opts.h@1.260 +3 -3 + NTP_4_2_7P262 + + sntp/sntp-opts.texi@1.260 +2 -2 + NTP_4_2_7P262 + + sntp/sntp.1sntpman@1.80 +2 -2 + NTP_4_2_7P262 + + sntp/sntp.1sntpmdoc@1.80 +2 -2 + NTP_4_2_7P262 + + sntp/sntp.html@1.260 +2 -2 + NTP_4_2_7P262 + + sntp/sntp.man.in@1.80 +2 -2 + NTP_4_2_7P262 + + sntp/sntp.mdoc.in@1.80 +2 -2 + NTP_4_2_7P262 + + util/ntp-keygen-opts.c@1.264 +4 -4 + NTP_4_2_7P262 + + util/ntp-keygen-opts.h@1.264 +3 -3 + NTP_4_2_7P262 + + util/ntp-keygen-opts.texi@1.265 +2 -2 + NTP_4_2_7P262 + + util/ntp-keygen.1ntp-keygenman@1.78 +2 -2 + NTP_4_2_7P262 + + util/ntp-keygen.1ntp-keygenmdoc@1.78 +2 -2 + NTP_4_2_7P262 + + util/ntp-keygen.man.in@1.78 +2 -2 + NTP_4_2_7P262 + + util/ntp-keygen.mdoc.in@1.78 +2 -2 + NTP_4_2_7P262 + +ChangeSet@1.2762.1.23, 2012-02-28 20:27:35-05:00, stenn@deacon.udel.edu + Add missing library to ntpsnmpd build + + ntpsnmpd/Makefile.am@1.34 +1 -1 + Add missing library to ntpsnmpd build + +ChangeSet@1.2762.9.1, 2012-02-28 04:42:34-05:00, stenn@deacon.udel.edu + Disable bkbits as a mirror for now + + BitKeeper/triggers/2mirrors@1.8 +3 -1 + Disable bkbits as a mirror for now + +ChangeSet@1.2762.1.21, 2012-02-27 23:05:11+00:00, davehart@dlh-7551.ad.hartbrothers.com + Improve ntpd scalability for servers with many trusted keys. + + ChangeLog@1.1127 +1 -0 + Improve ntpd scalability for servers with many trusted keys. + + include/ntp_stdlib.h@1.71 +6 -4 + Improve ntpd scalability for servers with many trusted keys. + + libntp/a_md5encrypt.c@1.32 +3 -3 + Improve ntpd scalability for servers with many trusted keys. + + libntp/authkeys.c@1.23 +410 -257 + Improve ntpd scalability for servers with many trusted keys. + + ntpd/ntp_config.c@1.298 +43 -9 + Improve ntpd scalability for servers with many trusted keys. + + ntpdc/ntpdc.c@1.99 +1 -0 + Use init_auth() before other symmetric key routines. + + ntpq/ntpq.c@1.145 +1 -0 + Use init_auth() before other symmetric key routines. + + sntp/main.c@1.82 +2 -0 + Use init_auth() before other symmetric key routines. + + sntp/tests_main.cpp@1.8 +1 -0 + Use init_auth() before other symmetric key routines. + + tests/libntp/a_md5encrypt.cpp@1.5 +4 -4 + Improve ntpd scalability for servers with many trusted keys. + + tests/libntp/authkeys.cpp@1.7 +7 -11 + Improve ntpd scalability for servers with many trusted keys. + +ChangeSet@1.2762.1.20, 2012-02-27 11:45:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P261 + TAG: NTP_4_2_7P261 + + ChangeLog@1.1126 +1 -0 + NTP_4_2_7P261 + + ntpd/ntpd-opts.c@1.266 +4 -4 + NTP_4_2_7P261 + + ntpd/ntpd-opts.h@1.266 +3 -3 + NTP_4_2_7P261 + + ntpd/ntpd-opts.texi@1.264 +2 -2 + NTP_4_2_7P261 + + ntpd/ntpd.1ntpdman@1.77 +2 -2 + NTP_4_2_7P261 + + ntpd/ntpd.1ntpdmdoc@1.77 +2 -2 + NTP_4_2_7P261 + + ntpd/ntpd.man.in@1.77 +2 -2 + NTP_4_2_7P261 + + ntpd/ntpd.mdoc.in@1.77 +2 -2 + NTP_4_2_7P261 + + ntpdc/ntpdc-opts.c@1.261 +4 -4 + NTP_4_2_7P261 + + ntpdc/ntpdc-opts.h@1.261 +3 -3 + NTP_4_2_7P261 + + ntpdc/ntpdc-opts.texi@1.261 +2 -2 + NTP_4_2_7P261 + + ntpdc/ntpdc.1ntpdcman@1.77 +2 -2 + NTP_4_2_7P261 + + ntpdc/ntpdc.1ntpdcmdoc@1.77 +2 -2 + NTP_4_2_7P261 + + ntpdc/ntpdc.html@1.89 +2 -2 + NTP_4_2_7P261 + + ntpdc/ntpdc.man.in@1.77 +2 -2 + NTP_4_2_7P261 + + ntpdc/ntpdc.mdoc.in@1.77 +2 -2 + NTP_4_2_7P261 + + ntpq/ntpq-opts.c@1.263 +4 -4 + NTP_4_2_7P261 + + ntpq/ntpq-opts.h@1.263 +3 -3 + NTP_4_2_7P261 + + ntpq/ntpq-opts.texi@1.263 +2 -2 + NTP_4_2_7P261 + + ntpq/ntpq.1ntpqman@1.77 +2 -2 + NTP_4_2_7P261 + + ntpq/ntpq.1ntpqmdoc@1.77 +2 -2 + NTP_4_2_7P261 + + ntpq/ntpq.man.in@1.77 +2 -2 + NTP_4_2_7P261 + + ntpq/ntpq.mdoc.in@1.77 +2 -2 + NTP_4_2_7P261 + + ntpsnmpd/ntpsnmpd-opts.c@1.263 +4 -4 + NTP_4_2_7P261 + + ntpsnmpd/ntpsnmpd-opts.h@1.263 +3 -3 + NTP_4_2_7P261 + + ntpsnmpd/ntpsnmpd-opts.texi@1.263 +2 -2 + NTP_4_2_7P261 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.77 +2 -2 + NTP_4_2_7P261 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.77 +2 -2 + NTP_4_2_7P261 + + ntpsnmpd/ntpsnmpd.man.in@1.77 +2 -2 + NTP_4_2_7P261 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.77 +2 -2 + NTP_4_2_7P261 + + packageinfo.sh@1.264 +1 -1 + NTP_4_2_7P261 + + scripts/ntp-wait-opts.texi@1.81 +1 -1 + NTP_4_2_7P261 + + scripts/ntp-wait.1ntp-waitman@1.77 +2 -2 + NTP_4_2_7P261 + + scripts/ntp-wait.1ntp-waitmdoc@1.77 +2 -2 + NTP_4_2_7P261 + + scripts/ntp-wait.html@1.81 +1 -1 + NTP_4_2_7P261 + + scripts/ntp-wait.man.in@1.77 +2 -2 + NTP_4_2_7P261 + + scripts/ntp-wait.mdoc.in@1.77 +2 -2 + NTP_4_2_7P261 + + sntp/sntp-opts.c@1.259 +4 -4 + NTP_4_2_7P261 + + sntp/sntp-opts.h@1.259 +3 -3 + NTP_4_2_7P261 + + sntp/sntp-opts.texi@1.259 +2 -2 + NTP_4_2_7P261 + + sntp/sntp.1sntpman@1.79 +2 -2 + NTP_4_2_7P261 + + sntp/sntp.1sntpmdoc@1.79 +2 -2 + NTP_4_2_7P261 + + sntp/sntp.html@1.259 +2 -2 + NTP_4_2_7P261 + + sntp/sntp.man.in@1.79 +2 -2 + NTP_4_2_7P261 + + sntp/sntp.mdoc.in@1.79 +2 -2 + NTP_4_2_7P261 + + util/ntp-keygen-opts.c@1.263 +4 -4 + NTP_4_2_7P261 + + util/ntp-keygen-opts.h@1.263 +3 -3 + NTP_4_2_7P261 + + util/ntp-keygen-opts.texi@1.264 +2 -2 + NTP_4_2_7P261 + + util/ntp-keygen.1ntp-keygenman@1.77 +2 -2 + NTP_4_2_7P261 + + util/ntp-keygen.1ntp-keygenmdoc@1.77 +2 -2 + NTP_4_2_7P261 + + util/ntp-keygen.man.in@1.77 +2 -2 + NTP_4_2_7P261 + + util/ntp-keygen.mdoc.in@1.77 +2 -2 + NTP_4_2_7P261 + +ChangeSet@1.2762.7.3, 2012-02-27 06:45:32+00:00, stenn@psp-fb1.ntp.org + Upgrade to autogen-5.15 + + ChangeLog@1.1123.1.2 +1 -0 + Upgrade to autogen-5.15 + + sntp/include/autogen-version.def@1.10 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/COPYING.gplv3@1.5 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/COPYING.lgplv3@1.5 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/Makefile.am@1.12 +5 -4 + Upgrade to autogen-5.15 + + sntp/libopts/README@1.7 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/ag-char-map.h@1.15 +132 -102 + Upgrade to autogen-5.15 + + sntp/libopts/alias.c@1.1 +108 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/sntp/libopts/alias.c + + sntp/libopts/alias.c@1.0 +0 -0 + + sntp/libopts/ao-strs.c@1.1 +323 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-autogen/sntp/libopts/ao-strs.c + + sntp/libopts/ao-strs.c@1.0 +0 -0 + + sntp/libopts/autoopts.c@1.12 +14 -14 + Upgrade to autogen-5.15 + + sntp/libopts/autoopts.h@1.10 +5 -3 + Upgrade to autogen-5.15 + + sntp/libopts/autoopts/options.h@1.14 +31 -19 + Upgrade to autogen-5.15 + + sntp/libopts/autoopts/usage-txt.h@1.14 +168 -170 + Upgrade to autogen-5.15 + + sntp/libopts/boolean.c@1.8 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/check.c@1.2 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/compat/compat.h@1.8 +5 -3 + Upgrade to autogen-5.15 + + sntp/libopts/compat/windows-config.h@1.8 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/configfile.c@1.13 +16 -14 + Upgrade to autogen-5.15 + + sntp/libopts/cook.c@1.9 +12 -12 + Upgrade to autogen-5.15 + + sntp/libopts/enum.c@1.2 +31 -36 + Upgrade to autogen-5.15 + + sntp/libopts/env.c@1.2 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/file.c@1.10 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/find.c@1.2 +36 -38 + Upgrade to autogen-5.15 + + sntp/libopts/genshell.c@1.15 +25 -19 + Upgrade to autogen-5.15 + + sntp/libopts/genshell.h@1.15 +4 -4 + Upgrade to autogen-5.15 + + sntp/libopts/libopts.c@1.5 +7 -3 + Upgrade to autogen-5.15 + + sntp/libopts/load.c@1.11 +10 -11 + Upgrade to autogen-5.15 + + sntp/libopts/m4/libopts.m4@1.18 +30 -30 + Upgrade to autogen-5.15 + + sntp/libopts/m4/liboptschk.m4@1.9 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/makeshell.c@1.10 +124 -436 + Upgrade to autogen-5.15 + + sntp/libopts/nested.c@1.8 +65 -40 + Upgrade to autogen-5.15 + + sntp/libopts/numeric.c@1.9 +9 -13 + Upgrade to autogen-5.15 + + sntp/libopts/parse-duration.c@1.6 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/parse-duration.h@1.6 +2 -2 + Upgrade to autogen-5.15 + + sntp/libopts/pgusage.c@1.9 +8 -9 + Upgrade to autogen-5.15 + + sntp/libopts/proto.h@1.15 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/putshell.c@1.8 +21 -34 + Upgrade to autogen-5.15 + + sntp/libopts/reset.c@1.9 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/restore.c@1.8 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/save.c@1.10 +82 -98 + Upgrade to autogen-5.15 + + sntp/libopts/sort.c@1.9 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/stack.c@1.8 +6 -6 + Upgrade to autogen-5.15 + + sntp/libopts/streqvcmp.c@1.8 +6 -6 + Upgrade to autogen-5.15 + + sntp/libopts/text_mmap.c@1.10 +2 -2 + Upgrade to autogen-5.15 + + sntp/libopts/time.c@1.9 +3 -3 + Upgrade to autogen-5.15 + + sntp/libopts/tokenize.c@1.6 +5 -5 + Upgrade to autogen-5.15 + + sntp/libopts/usage.c@1.10 +9 -9 + Upgrade to autogen-5.15 + + sntp/libopts/value-type.h@1.15 +1 -1 + Upgrade to autogen-5.15 + + sntp/libopts/version.c@1.10 +25 -10 + Upgrade to autogen-5.15 + + sntp/libopts/xat-attribute.h@1.15 +1 -1 + Upgrade to autogen-5.15 + +ChangeSet@1.2762.7.1, 2012-02-24 11:36:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P260 + TAG: NTP_4_2_7P260 + + ChangeLog@1.1123.1.1 +1 -0 + NTP_4_2_7P260 + + ntpd/ntpd-opts.c@1.265 +4 -4 + NTP_4_2_7P260 + + ntpd/ntpd-opts.h@1.265 +3 -3 + NTP_4_2_7P260 + + ntpd/ntpd-opts.texi@1.263 +2 -2 + NTP_4_2_7P260 + + ntpd/ntpd.1ntpdman@1.76 +2 -2 + NTP_4_2_7P260 + + ntpd/ntpd.1ntpdmdoc@1.76 +2 -2 + NTP_4_2_7P260 + + ntpd/ntpd.man.in@1.76 +2 -2 + NTP_4_2_7P260 + + ntpd/ntpd.mdoc.in@1.76 +2 -2 + NTP_4_2_7P260 + + ntpdc/ntpdc-opts.c@1.260 +4 -4 + NTP_4_2_7P260 + + ntpdc/ntpdc-opts.h@1.260 +3 -3 + NTP_4_2_7P260 + + ntpdc/ntpdc-opts.texi@1.260 +2 -2 + NTP_4_2_7P260 + + ntpdc/ntpdc.1ntpdcman@1.76 +2 -2 + NTP_4_2_7P260 + + ntpdc/ntpdc.1ntpdcmdoc@1.76 +2 -2 + NTP_4_2_7P260 + + ntpdc/ntpdc.html@1.88 +2 -2 + NTP_4_2_7P260 + + ntpdc/ntpdc.man.in@1.76 +2 -2 + NTP_4_2_7P260 + + ntpdc/ntpdc.mdoc.in@1.76 +2 -2 + NTP_4_2_7P260 + + ntpq/ntpq-opts.c@1.262 +4 -4 + NTP_4_2_7P260 + + ntpq/ntpq-opts.h@1.262 +3 -3 + NTP_4_2_7P260 + + ntpq/ntpq-opts.texi@1.262 +2 -2 + NTP_4_2_7P260 + + ntpq/ntpq.1ntpqman@1.76 +2 -2 + NTP_4_2_7P260 + + ntpq/ntpq.1ntpqmdoc@1.76 +2 -2 + NTP_4_2_7P260 + + ntpq/ntpq.man.in@1.76 +2 -2 + NTP_4_2_7P260 + + ntpq/ntpq.mdoc.in@1.76 +2 -2 + NTP_4_2_7P260 + + ntpsnmpd/ntpsnmpd-opts.c@1.262 +4 -4 + NTP_4_2_7P260 + + ntpsnmpd/ntpsnmpd-opts.h@1.262 +3 -3 + NTP_4_2_7P260 + + ntpsnmpd/ntpsnmpd-opts.texi@1.262 +2 -2 + NTP_4_2_7P260 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.76 +2 -2 + NTP_4_2_7P260 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.76 +2 -2 + NTP_4_2_7P260 + + ntpsnmpd/ntpsnmpd.man.in@1.76 +2 -2 + NTP_4_2_7P260 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.76 +2 -2 + NTP_4_2_7P260 + + packageinfo.sh@1.263 +1 -1 + NTP_4_2_7P260 + + scripts/ntp-wait-opts.texi@1.80 +1 -1 + NTP_4_2_7P260 + + scripts/ntp-wait.1ntp-waitman@1.76 +2 -2 + NTP_4_2_7P260 + + scripts/ntp-wait.1ntp-waitmdoc@1.76 +2 -2 + NTP_4_2_7P260 + + scripts/ntp-wait.html@1.80 +1 -1 + NTP_4_2_7P260 + + scripts/ntp-wait.man.in@1.76 +2 -2 + NTP_4_2_7P260 + + scripts/ntp-wait.mdoc.in@1.76 +2 -2 + NTP_4_2_7P260 + + sntp/sntp-opts.c@1.258 +4 -4 + NTP_4_2_7P260 + + sntp/sntp-opts.h@1.258 +3 -3 + NTP_4_2_7P260 + + sntp/sntp-opts.texi@1.258 +2 -2 + NTP_4_2_7P260 + + sntp/sntp.1sntpman@1.78 +2 -2 + NTP_4_2_7P260 + + sntp/sntp.1sntpmdoc@1.78 +2 -2 + NTP_4_2_7P260 + + sntp/sntp.html@1.258 +2 -2 + NTP_4_2_7P260 + + sntp/sntp.man.in@1.78 +2 -2 + NTP_4_2_7P260 + + sntp/sntp.mdoc.in@1.78 +2 -2 + NTP_4_2_7P260 + + util/ntp-keygen-opts.c@1.262 +4 -4 + NTP_4_2_7P260 + + util/ntp-keygen-opts.h@1.262 +3 -3 + NTP_4_2_7P260 + + util/ntp-keygen-opts.texi@1.263 +2 -2 + NTP_4_2_7P260 + + util/ntp-keygen.1ntp-keygenman@1.76 +2 -2 + NTP_4_2_7P260 + + util/ntp-keygen.1ntp-keygenmdoc@1.76 +2 -2 + NTP_4_2_7P260 + + util/ntp-keygen.man.in@1.76 +2 -2 + NTP_4_2_7P260 + + util/ntp-keygen.mdoc.in@1.76 +2 -2 + NTP_4_2_7P260 + +ChangeSet@1.2762.1.18, 2012-02-24 08:07:56+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2048] add the clock variable timecode to SHM refclock. + Thanks to Michael Tatarinov. + + ChangeLog@1.1124 +1 -0 + [Bug 2048] add the clock variable timecode to SHM refclock. + + ntpd/refclock_shm.c@1.24 +16 -6 + [Bug 2048] add the clock variable timecode to SHM refclock. + +ChangeSet@1.2762.1.17, 2012-02-23 18:16:42-05:00, stenn@deacon.udel.edu + Fix the check-scm-rev invocation in several Makefile.am's. + + ChangeLog@1.1123 +1 -0 + Fix the check-scm-rev invocation in several Makefile.am's. + + ntpd/Makefile.am@1.112.1.1 +1 -1 + Fix the check-scm-rev invocation in several Makefile.am's. + + ntpdate/Makefile.am@1.34 +1 -1 + Fix the check-scm-rev invocation in several Makefile.am's. + + ntpdc/Makefile.am@1.70 +1 -1 + Fix the check-scm-rev invocation in several Makefile.am's. + + ntpq/Makefile.am@1.66 +1 -1 + Fix the check-scm-rev invocation in several Makefile.am's. + + util/Makefile.am@1.70 +1 -1 + Fix the check-scm-rev invocation in several Makefile.am's. + +ChangeSet@1.2762.1.16, 2012-02-22 05:59:53+00:00, stenn@deacon.udel.edu + NTP_4_2_7P259 + TAG: NTP_4_2_7P259 + + ChangeLog@1.1122 +1 -0 + NTP_4_2_7P259 + + ntpd/ntpd-opts.c@1.264 +4 -4 + NTP_4_2_7P259 + + ntpd/ntpd-opts.h@1.264 +3 -3 + NTP_4_2_7P259 + + ntpd/ntpd-opts.texi@1.262 +2 -2 + NTP_4_2_7P259 + + ntpd/ntpd.1ntpdman@1.75 +2 -2 + NTP_4_2_7P259 + + ntpd/ntpd.1ntpdmdoc@1.75 +2 -2 + NTP_4_2_7P259 + + ntpd/ntpd.man.in@1.75 +2 -2 + NTP_4_2_7P259 + + ntpd/ntpd.mdoc.in@1.75 +2 -2 + NTP_4_2_7P259 + + ntpdc/ntpdc-opts.c@1.259 +4 -4 + NTP_4_2_7P259 + + ntpdc/ntpdc-opts.h@1.259 +3 -3 + NTP_4_2_7P259 + + ntpdc/ntpdc-opts.texi@1.259 +2 -2 + NTP_4_2_7P259 + + ntpdc/ntpdc.1ntpdcman@1.75 +2 -2 + NTP_4_2_7P259 + + ntpdc/ntpdc.1ntpdcmdoc@1.75 +2 -2 + NTP_4_2_7P259 + + ntpdc/ntpdc.html@1.87 +2 -2 + NTP_4_2_7P259 + + ntpdc/ntpdc.man.in@1.75 +2 -2 + NTP_4_2_7P259 + + ntpdc/ntpdc.mdoc.in@1.75 +2 -2 + NTP_4_2_7P259 + + ntpq/ntpq-opts.c@1.261 +4 -4 + NTP_4_2_7P259 + + ntpq/ntpq-opts.h@1.261 +3 -3 + NTP_4_2_7P259 + + ntpq/ntpq-opts.texi@1.261 +2 -2 + NTP_4_2_7P259 + + ntpq/ntpq.1ntpqman@1.75 +2 -2 + NTP_4_2_7P259 + + ntpq/ntpq.1ntpqmdoc@1.75 +2 -2 + NTP_4_2_7P259 + + ntpq/ntpq.man.in@1.75 +2 -2 + NTP_4_2_7P259 + + ntpq/ntpq.mdoc.in@1.75 +2 -2 + NTP_4_2_7P259 + + ntpsnmpd/ntpsnmpd-opts.c@1.261 +4 -4 + NTP_4_2_7P259 + + ntpsnmpd/ntpsnmpd-opts.h@1.261 +3 -3 + NTP_4_2_7P259 + + ntpsnmpd/ntpsnmpd-opts.texi@1.261 +2 -2 + NTP_4_2_7P259 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.75 +2 -2 + NTP_4_2_7P259 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.75 +2 -2 + NTP_4_2_7P259 + + ntpsnmpd/ntpsnmpd.man.in@1.75 +2 -2 + NTP_4_2_7P259 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.75 +2 -2 + NTP_4_2_7P259 + + packageinfo.sh@1.262 +1 -1 + NTP_4_2_7P259 + + scripts/ntp-wait-opts.texi@1.79 +1 -1 + NTP_4_2_7P259 + + scripts/ntp-wait.1ntp-waitman@1.75 +2 -2 + NTP_4_2_7P259 + + scripts/ntp-wait.1ntp-waitmdoc@1.75 +2 -2 + NTP_4_2_7P259 + + scripts/ntp-wait.html@1.79 +1 -1 + NTP_4_2_7P259 + + scripts/ntp-wait.man.in@1.75 +2 -2 + NTP_4_2_7P259 + + scripts/ntp-wait.mdoc.in@1.75 +2 -2 + NTP_4_2_7P259 + + sntp/sntp-opts.c@1.257 +4 -4 + NTP_4_2_7P259 + + sntp/sntp-opts.h@1.257 +3 -3 + NTP_4_2_7P259 + + sntp/sntp-opts.texi@1.257 +2 -2 + NTP_4_2_7P259 + + sntp/sntp.1sntpman@1.77 +2 -2 + NTP_4_2_7P259 + + sntp/sntp.1sntpmdoc@1.77 +2 -2 + NTP_4_2_7P259 + + sntp/sntp.html@1.257 +2 -2 + NTP_4_2_7P259 + + sntp/sntp.man.in@1.77 +2 -2 + NTP_4_2_7P259 + + sntp/sntp.mdoc.in@1.77 +2 -2 + NTP_4_2_7P259 + + util/ntp-keygen-opts.c@1.261 +4 -4 + NTP_4_2_7P259 + + util/ntp-keygen-opts.h@1.261 +3 -3 + NTP_4_2_7P259 + + util/ntp-keygen-opts.texi@1.262 +2 -2 + NTP_4_2_7P259 + + util/ntp-keygen.1ntp-keygenman@1.75 +2 -2 + NTP_4_2_7P259 + + util/ntp-keygen.1ntp-keygenmdoc@1.75 +2 -2 + NTP_4_2_7P259 + + util/ntp-keygen.man.in@1.75 +2 -2 + NTP_4_2_7P259 + + util/ntp-keygen.mdoc.in@1.75 +2 -2 + NTP_4_2_7P259 + +ChangeSet@1.2762.1.15, 2012-02-22 05:05:04+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2148] ntpd 4.2.7p258 segfault with 0x0100000 bit in NMEA mode. + refclock_nmea.c merge cleanup thanks to Juergen Perlinger. + Use mutex with Lamport checks in get_systime() on Windows, which + unlike portable ntpd uses the routine across threads. + + ChangeLog@1.1121 +2 -0 + [Bug 2148] ntpd 4.2.7p258 segfault with 0x0100000 bit in NMEA mode. + refclock_nmea.c merge cleanup thanks to Juergen Perlinger. + + include/ntp_assert.h@1.7 +4 -4 + Do not evaluate expression for compiled-out DEBUG_INSIST() and other + DEBUG_*() assertions. + + include/ntp_fp.h@1.29 +30 -0 + Make recent fuzz Lamport checks in get_systime() safe on Windows ntpd, + which invokes get_systime() on independent threads with mutex. + + libntp/lib_strbuf.c@1.10 +5 -0 + Make recent fuzz Lamport checks in get_systime() safe on Windows ntpd, + which invokes get_systime() on independent threads with mutex. + + libntp/systime.c@1.64 +26 -2 + Make recent fuzz Lamport checks in get_systime() safe on Windows ntpd, + which invokes get_systime() on independent threads with mutex. + + ntpd/ntp_control.c@1.179 +7 -1 + [Bug 2148] ntpd 4.2.7p258 segfault with 0x0100000 bit in NMEA mode. + + ntpd/ntp_refclock.c@1.115 +3 -1 + p257 change requires reflective change to debug trace code to avoid + unprintable spew. + + ntpd/ntpd.c@1.130 +1 -1 + init_lib() calls init_systime() which needs to happen before get_systime() + + ntpd/refclock_nmea.c@1.70 +0 -13 + merge cleanup of Dave's merge, courtesy Juergen OOB + + ports/winnt/ntpd/ntp_iocompletionport.c@1.66 +1 -1 + debug trace of user PPS hack treated DCD timestamp as signed. + + sntp/tests_main.cpp@1.7 +2 -0 + Call libntp's init_lib() early in unit tests. + + sntp/tests_main.h@1.8 +3 -0 + ntp_stdlib.h for init_lib() + +ChangeSet@1.2762.1.14, 2012-02-21 04:53:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P258 + TAG: NTP_4_2_7P258 + + ChangeLog@1.1120 +1 -0 + NTP_4_2_7P258 + + ntpd/ntpd-opts.c@1.263 +4 -4 + NTP_4_2_7P258 + + ntpd/ntpd-opts.h@1.263 +3 -3 + NTP_4_2_7P258 + + ntpd/ntpd-opts.texi@1.261 +2 -2 + NTP_4_2_7P258 + + ntpd/ntpd.1ntpdman@1.74 +2 -2 + NTP_4_2_7P258 + + ntpd/ntpd.1ntpdmdoc@1.74 +2 -2 + NTP_4_2_7P258 + + ntpd/ntpd.man.in@1.74 +2 -2 + NTP_4_2_7P258 + + ntpd/ntpd.mdoc.in@1.74 +2 -2 + NTP_4_2_7P258 + + ntpdc/ntpdc-opts.c@1.258 +4 -4 + NTP_4_2_7P258 + + ntpdc/ntpdc-opts.h@1.258 +3 -3 + NTP_4_2_7P258 + + ntpdc/ntpdc-opts.texi@1.258 +2 -2 + NTP_4_2_7P258 + + ntpdc/ntpdc.1ntpdcman@1.74 +2 -2 + NTP_4_2_7P258 + + ntpdc/ntpdc.1ntpdcmdoc@1.74 +2 -2 + NTP_4_2_7P258 + + ntpdc/ntpdc.html@1.86 +2 -2 + NTP_4_2_7P258 + + ntpdc/ntpdc.man.in@1.74 +2 -2 + NTP_4_2_7P258 + + ntpdc/ntpdc.mdoc.in@1.74 +2 -2 + NTP_4_2_7P258 + + ntpq/ntpq-opts.c@1.260 +4 -4 + NTP_4_2_7P258 + + ntpq/ntpq-opts.h@1.260 +3 -3 + NTP_4_2_7P258 + + ntpq/ntpq-opts.texi@1.260 +2 -2 + NTP_4_2_7P258 + + ntpq/ntpq.1ntpqman@1.74 +2 -2 + NTP_4_2_7P258 + + ntpq/ntpq.1ntpqmdoc@1.74 +2 -2 + NTP_4_2_7P258 + + ntpq/ntpq.man.in@1.74 +2 -2 + NTP_4_2_7P258 + + ntpq/ntpq.mdoc.in@1.74 +2 -2 + NTP_4_2_7P258 + + ntpsnmpd/ntpsnmpd-opts.c@1.260 +4 -4 + NTP_4_2_7P258 + + ntpsnmpd/ntpsnmpd-opts.h@1.260 +3 -3 + NTP_4_2_7P258 + + ntpsnmpd/ntpsnmpd-opts.texi@1.260 +2 -2 + NTP_4_2_7P258 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.74 +2 -2 + NTP_4_2_7P258 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.74 +2 -2 + NTP_4_2_7P258 + + ntpsnmpd/ntpsnmpd.man.in@1.74 +2 -2 + NTP_4_2_7P258 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.74 +2 -2 + NTP_4_2_7P258 + + packageinfo.sh@1.261 +1 -1 + NTP_4_2_7P258 + + scripts/ntp-wait-opts.texi@1.78 +1 -1 + NTP_4_2_7P258 + + scripts/ntp-wait.1ntp-waitman@1.74 +2 -2 + NTP_4_2_7P258 + + scripts/ntp-wait.1ntp-waitmdoc@1.74 +2 -2 + NTP_4_2_7P258 + + scripts/ntp-wait.html@1.78 +1 -1 + NTP_4_2_7P258 + + scripts/ntp-wait.man.in@1.74 +2 -2 + NTP_4_2_7P258 + + scripts/ntp-wait.mdoc.in@1.74 +2 -2 + NTP_4_2_7P258 + + sntp/sntp-opts.c@1.256 +4 -4 + NTP_4_2_7P258 + + sntp/sntp-opts.h@1.256 +3 -3 + NTP_4_2_7P258 + + sntp/sntp-opts.texi@1.256 +2 -2 + NTP_4_2_7P258 + + sntp/sntp.1sntpman@1.76 +2 -2 + NTP_4_2_7P258 + + sntp/sntp.1sntpmdoc@1.76 +2 -2 + NTP_4_2_7P258 + + sntp/sntp.html@1.256 +2 -2 + NTP_4_2_7P258 + + sntp/sntp.man.in@1.76 +2 -2 + NTP_4_2_7P258 + + sntp/sntp.mdoc.in@1.76 +2 -2 + NTP_4_2_7P258 + + util/ntp-keygen-opts.c@1.260 +4 -4 + NTP_4_2_7P258 + + util/ntp-keygen-opts.h@1.260 +3 -3 + NTP_4_2_7P258 + + util/ntp-keygen-opts.texi@1.261 +2 -2 + NTP_4_2_7P258 + + util/ntp-keygen.1ntp-keygenman@1.74 +2 -2 + NTP_4_2_7P258 + + util/ntp-keygen.1ntp-keygenmdoc@1.74 +2 -2 + NTP_4_2_7P258 + + util/ntp-keygen.man.in@1.74 +2 -2 + NTP_4_2_7P258 + + util/ntp-keygen.mdoc.in@1.74 +2 -2 + NTP_4_2_7P258 + +ChangeSet@1.2762.1.13, 2012-02-21 02:43:49+00:00, hart@psp-os1.ntp.org + refclock_nmea.c: + add newline to EOF + + ntpd/refclock_nmea.c@1.69 +1 -1 + add newline to EOF + +ChangeSet@1.2762.6.1, 2012-02-21 01:26:03+01:00, jnperlin@hydra.localnet + [bug 2143] discard data if quality indication not good to avoid glitches + add stat counters for diagnostics (mode bit enabled) to clockstats file + + ChangeLog@1.1116.2.1 +2 -0 + [bug 2143] discard data if quality indication not good to avoid glitches + add stat counters for diagnostics (mode bit enabled) to clockstats file + + ntpd/refclock_nmea.c@1.65.1.1 +63 -12 + [bug 2143] discard data if quality indication not good to avoid glitches + add stat counters for diagnostics (mode bit enabled) to clockstats file + +ChangeSet@1.2762.4.2, 2012-02-20 22:16:37+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2143] NMEA 4.2.7p204 uses timecodes indicating lost reception. + Increase detail in clockstats for NMEA driver (from Hal Murray). + + ChangeLog@1.1116.1.1 +2 -0 + [Bug 2143] NMEA 4.2.7p204 uses timecodes indicating lost reception. + Increase detail in clockstats for NMEA driver (from Hal Murray). + + ntpd/refclock_nmea.c@1.67 +39 -6 + Increase detail in clockstats for NMEA driver (from Hal Murray). + + +ChangeSet@1.2762.1.10, 2012-02-19 16:30:28+00:00, davehart@dlh-7551.ad.hartbrothers.com + fix user-mode PPS end of line timestamp, and use wait I/O + completion timestamp not read completion. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.65 +5 -2 + fix user-mode PPS end of line timestamp, and use wait I/O + completion timestamp not read completion. + +ChangeSet@1.2762.5.1, 2012-02-19 16:06:38+00:00, davehart@dlh-7551.ad.hartbrothers.com + Minor nonfunctional refclock_nmea.c cleanup while hunting bug. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.62.1.1 +74 -54 + Minor nonfunctional cleanup while hunting bug. + +ChangeSet@1.2762.1.8, 2012-02-19 16:10:00+01:00, jnperlin@hydra.localnet + hack to get rid of leading CR/LF and keep timestamp for the whole buffer + + ports/winnt/ntpd/ntp_iocompletionport.c@1.63 +16 -6 + hack to get rid of leading CR/LF and keep timestamp for the whole buffer + +ChangeSet@1.2762.4.1, 2012-02-19 09:29:05+01:00, jnperlin@hydra.localnet + [bug 2143] do not process data if quality indication says 'not good' to avoid glitches + + ntpd/refclock_nmea.c@1.66 +6 -1 + [bug 2143] do not process data if quality indication says 'not good' to avoid glitches + +ChangeSet@1.2762.1.7, 2012-02-18 02:41:22+01:00, jnperlin@hydra.localnet + [Bug 2140] Rework of Windows I/O completion port handling to avoid garbling serial input in UNIX line discipline emulation. + + ChangeLog@1.1117 +2 -0 + [Bug 2140] Rework of Windows I/O completion port handling to avoid garbling serial input in UNIX line discipline emulation. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.62 +775 -598 + [Bug 2140] Rework of Windows I/O completion port handling to avoid garbling serial input in UNIX line discipline emulation. + +ChangeSet@1.2762.1.6, 2012-02-17 05:52:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P257 + TAG: NTP_4_2_7P257 + + ChangeLog@1.1116 +1 -0 + NTP_4_2_7P257 + + ntpd/ntpd-opts.c@1.262 +4 -4 + NTP_4_2_7P257 + + ntpd/ntpd-opts.h@1.262 +3 -3 + NTP_4_2_7P257 + + ntpd/ntpd-opts.texi@1.260 +2 -2 + NTP_4_2_7P257 + + ntpd/ntpd.1ntpdman@1.73 +2 -2 + NTP_4_2_7P257 + + ntpd/ntpd.1ntpdmdoc@1.73 +2 -2 + NTP_4_2_7P257 + + ntpd/ntpd.man.in@1.73 +2 -2 + NTP_4_2_7P257 + + ntpd/ntpd.mdoc.in@1.73 +2 -2 + NTP_4_2_7P257 + + ntpdc/ntpdc-opts.c@1.257 +4 -4 + NTP_4_2_7P257 + + ntpdc/ntpdc-opts.h@1.257 +3 -3 + NTP_4_2_7P257 + + ntpdc/ntpdc-opts.texi@1.257 +2 -2 + NTP_4_2_7P257 + + ntpdc/ntpdc.1ntpdcman@1.73 +2 -2 + NTP_4_2_7P257 + + ntpdc/ntpdc.1ntpdcmdoc@1.73 +2 -2 + NTP_4_2_7P257 + + ntpdc/ntpdc.html@1.85 +2 -2 + NTP_4_2_7P257 + + ntpdc/ntpdc.man.in@1.73 +2 -2 + NTP_4_2_7P257 + + ntpdc/ntpdc.mdoc.in@1.73 +2 -2 + NTP_4_2_7P257 + + ntpq/ntpq-opts.c@1.259 +4 -4 + NTP_4_2_7P257 + + ntpq/ntpq-opts.h@1.259 +3 -3 + NTP_4_2_7P257 + + ntpq/ntpq-opts.texi@1.259 +2 -2 + NTP_4_2_7P257 + + ntpq/ntpq.1ntpqman@1.73 +2 -2 + NTP_4_2_7P257 + + ntpq/ntpq.1ntpqmdoc@1.73 +2 -2 + NTP_4_2_7P257 + + ntpq/ntpq.man.in@1.73 +2 -2 + NTP_4_2_7P257 + + ntpq/ntpq.mdoc.in@1.73 +2 -2 + NTP_4_2_7P257 + + ntpsnmpd/ntpsnmpd-opts.c@1.259 +4 -4 + NTP_4_2_7P257 + + ntpsnmpd/ntpsnmpd-opts.h@1.259 +3 -3 + NTP_4_2_7P257 + + ntpsnmpd/ntpsnmpd-opts.texi@1.259 +2 -2 + NTP_4_2_7P257 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.73 +2 -2 + NTP_4_2_7P257 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.73 +2 -2 + NTP_4_2_7P257 + + ntpsnmpd/ntpsnmpd.man.in@1.73 +2 -2 + NTP_4_2_7P257 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.73 +2 -2 + NTP_4_2_7P257 + + packageinfo.sh@1.260 +1 -1 + NTP_4_2_7P257 + + scripts/ntp-wait-opts.texi@1.77 +1 -1 + NTP_4_2_7P257 + + scripts/ntp-wait.1ntp-waitman@1.73 +2 -2 + NTP_4_2_7P257 + + scripts/ntp-wait.1ntp-waitmdoc@1.73 +2 -2 + NTP_4_2_7P257 + + scripts/ntp-wait.html@1.77 +1 -1 + NTP_4_2_7P257 + + scripts/ntp-wait.man.in@1.73 +2 -2 + NTP_4_2_7P257 + + scripts/ntp-wait.mdoc.in@1.73 +2 -2 + NTP_4_2_7P257 + + sntp/sntp-opts.c@1.255 +4 -4 + NTP_4_2_7P257 + + sntp/sntp-opts.h@1.255 +3 -3 + NTP_4_2_7P257 + + sntp/sntp-opts.texi@1.255 +2 -2 + NTP_4_2_7P257 + + sntp/sntp.1sntpman@1.75 +2 -2 + NTP_4_2_7P257 + + sntp/sntp.1sntpmdoc@1.75 +2 -2 + NTP_4_2_7P257 + + sntp/sntp.html@1.255 +2 -2 + NTP_4_2_7P257 + + sntp/sntp.man.in@1.75 +2 -2 + NTP_4_2_7P257 + + sntp/sntp.mdoc.in@1.75 +2 -2 + NTP_4_2_7P257 + + util/ntp-keygen-opts.c@1.259 +4 -4 + NTP_4_2_7P257 + + util/ntp-keygen-opts.h@1.259 +3 -3 + NTP_4_2_7P257 + + util/ntp-keygen-opts.texi@1.260 +2 -2 + NTP_4_2_7P257 + + util/ntp-keygen.1ntp-keygenman@1.73 +2 -2 + NTP_4_2_7P257 + + util/ntp-keygen.1ntp-keygenmdoc@1.73 +2 -2 + NTP_4_2_7P257 + + util/ntp-keygen.man.in@1.73 +2 -2 + NTP_4_2_7P257 + + util/ntp-keygen.mdoc.in@1.73 +2 -2 + NTP_4_2_7P257 + +ChangeSet@1.2762.1.5, 2012-02-15 02:48:49+00:00, davehart@dlh-7551.ad.hartbrothers.com + Restore accidentally-removed "parsetime" local variable declaration + in refclock_parse.c stream_receive(). + Remove Windows-specific code from indicate_refclock_packet() as it is + now used only on non-Windows systems. + process_refclock_packet() is used only on Windows, #ifdef away elsewhere. + + ntpd/ntp_refclock.c@1.114 +3 -3 + Remove Windows-specific code from indicate_refclock_packet() as it is + now used only on non-Windows systems. + process_refclock_packet() is used only on Windows, #ifdef away elsewhere. + + + ntpd/refclock_parse.c@1.66 +1 -0 + Restore accidentally-removed "parsetime" local variable declaration + in refclock_parse.c stream_receive(). + +ChangeSet@1.2762.2.1, 2012-02-09 23:18:03+01:00, jnperlin@hydra.localnet + [Bug 2135] defer calls to 'io_input' to main thread under Windows + + ChangeLog@1.1111.1.1 +1 -0 + [Bug 2135] defer calls to 'io_input' to main thread under Windows + + include/ntp_refclock.h@1.35 +1 -0 + [Bug 2135] defer calls to 'io_input' to main thread under Windows + * add prototype for 'process_refclock_packet()' + + ntpd/ntp_refclock.c@1.111.1.1 +65 -32 + [Bug 2135] defer calls to 'io_input' to main thread under Windows + * implement 'process_refclock_packet()' + * cleanup 'refclock_gtlin()' and refclock_gtraw()' + + ntpd/refclock_msfees.c@1.17 +2 -2 + [Bug 2135] defer calls to 'io_input' to main thread under Windows + * fix 'io.srcclock' mangling -- this should be the peer. Use the unit ptr to get the unit. + + ntpd/refclock_parse.c@1.65 +8 -5 + [Bug 2135] defer calls to 'io_input' to main thread under Windows + * fix 'io.srcclock' mangling -- this should be the peer. Use the unit ptr to get the unit. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.61 +7 -14 + [Bug 2135] defer calls to 'io_input' to main thread under Windows + +ChangeSet@1.2762.1.3, 2012-02-08 08:33:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P256 + TAG: NTP_4_2_7P256 + + ChangeLog@1.1114 +1 -0 + NTP_4_2_7P256 + + ntpd/ntpd-opts.c@1.261 +4 -4 + NTP_4_2_7P256 + + ntpd/ntpd-opts.h@1.261 +3 -3 + NTP_4_2_7P256 + + ntpd/ntpd-opts.texi@1.259 +2 -2 + NTP_4_2_7P256 + + ntpd/ntpd.1ntpdman@1.72 +2 -2 + NTP_4_2_7P256 + + ntpd/ntpd.1ntpdmdoc@1.72 +2 -2 + NTP_4_2_7P256 + + ntpd/ntpd.man.in@1.72 +2 -2 + NTP_4_2_7P256 + + ntpd/ntpd.mdoc.in@1.72 +2 -2 + NTP_4_2_7P256 + + ntpdc/ntpdc-opts.c@1.256 +4 -4 + NTP_4_2_7P256 + + ntpdc/ntpdc-opts.h@1.256 +3 -3 + NTP_4_2_7P256 + + ntpdc/ntpdc-opts.texi@1.256 +2 -2 + NTP_4_2_7P256 + + ntpdc/ntpdc.1ntpdcman@1.72 +2 -2 + NTP_4_2_7P256 + + ntpdc/ntpdc.1ntpdcmdoc@1.72 +2 -2 + NTP_4_2_7P256 + + ntpdc/ntpdc.html@1.84 +2 -2 + NTP_4_2_7P256 + + ntpdc/ntpdc.man.in@1.72 +2 -2 + NTP_4_2_7P256 + + ntpdc/ntpdc.mdoc.in@1.72 +2 -2 + NTP_4_2_7P256 + + ntpq/ntpq-opts.c@1.258 +4 -4 + NTP_4_2_7P256 + + ntpq/ntpq-opts.h@1.258 +3 -3 + NTP_4_2_7P256 + + ntpq/ntpq-opts.texi@1.258 +2 -2 + NTP_4_2_7P256 + + ntpq/ntpq.1ntpqman@1.72 +2 -2 + NTP_4_2_7P256 + + ntpq/ntpq.1ntpqmdoc@1.72 +2 -2 + NTP_4_2_7P256 + + ntpq/ntpq.man.in@1.72 +2 -2 + NTP_4_2_7P256 + + ntpq/ntpq.mdoc.in@1.72 +2 -2 + NTP_4_2_7P256 + + ntpsnmpd/ntpsnmpd-opts.c@1.258 +4 -4 + NTP_4_2_7P256 + + ntpsnmpd/ntpsnmpd-opts.h@1.258 +3 -3 + NTP_4_2_7P256 + + ntpsnmpd/ntpsnmpd-opts.texi@1.258 +2 -2 + NTP_4_2_7P256 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.72 +2 -2 + NTP_4_2_7P256 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.72 +2 -2 + NTP_4_2_7P256 + + ntpsnmpd/ntpsnmpd.man.in@1.72 +2 -2 + NTP_4_2_7P256 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.72 +2 -2 + NTP_4_2_7P256 + + packageinfo.sh@1.259 +1 -1 + NTP_4_2_7P256 + + scripts/ntp-wait-opts.texi@1.76 +1 -1 + NTP_4_2_7P256 + + scripts/ntp-wait.1ntp-waitman@1.72 +2 -2 + NTP_4_2_7P256 + + scripts/ntp-wait.1ntp-waitmdoc@1.72 +2 -2 + NTP_4_2_7P256 + + scripts/ntp-wait.html@1.76 +1 -1 + NTP_4_2_7P256 + + scripts/ntp-wait.man.in@1.72 +2 -2 + NTP_4_2_7P256 + + scripts/ntp-wait.mdoc.in@1.72 +2 -2 + NTP_4_2_7P256 + + sntp/sntp-opts.c@1.254 +4 -4 + NTP_4_2_7P256 + + sntp/sntp-opts.h@1.254 +3 -3 + NTP_4_2_7P256 + + sntp/sntp-opts.texi@1.254 +2 -2 + NTP_4_2_7P256 + + sntp/sntp.1sntpman@1.74 +2 -2 + NTP_4_2_7P256 + + sntp/sntp.1sntpmdoc@1.74 +2 -2 + NTP_4_2_7P256 + + sntp/sntp.html@1.254 +2 -2 + NTP_4_2_7P256 + + sntp/sntp.man.in@1.74 +2 -2 + NTP_4_2_7P256 + + sntp/sntp.mdoc.in@1.74 +2 -2 + NTP_4_2_7P256 + + util/ntp-keygen-opts.c@1.258 +4 -4 + NTP_4_2_7P256 + + util/ntp-keygen-opts.h@1.258 +3 -3 + NTP_4_2_7P256 + + util/ntp-keygen-opts.texi@1.259 +2 -2 + NTP_4_2_7P256 + + util/ntp-keygen.1ntp-keygenman@1.72 +2 -2 + NTP_4_2_7P256 + + util/ntp-keygen.1ntp-keygenmdoc@1.72 +2 -2 + NTP_4_2_7P256 + + util/ntp-keygen.man.in@1.72 +2 -2 + NTP_4_2_7P256 + + util/ntp-keygen.mdoc.in@1.72 +2 -2 + NTP_4_2_7P256 + +ChangeSet@1.2762.1.2, 2012-02-08 07:25:26+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2131] Set the system variable settimeofday only after clock step. + + ChangeLog@1.1113 +1 -0 + [Bug 2131] Set the system variable settimeofday only after clock step. + + ntpd/ntp_config.c@1.297 +0 -8 + [Bug 2131] Set the system variable settimeofday only after clock step. + + ntpd/ntp_refclock.c@1.112 +0 -1 + Remove unused local from refclock_timer(). + +ChangeSet@1.2762.1.1, 2012-02-08 02:33:45+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2134] --enable-C99-snprintf does not force rpl_snprintf use. + + ChangeLog@1.1112 +1 -0 + [Bug 2134] --enable-C99-snprintf does not force rpl_snprintf use. + + sntp/m4/snprintf.m4@1.3 +4 -4 + [Bug 2134] --enable-C99-snprintf does not force rpl_snprintf use. + +ChangeSet@1.2764, 2012-02-06 19:40:41+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/ag-tpl/texi2txt@1.2 +2 -4 + cleanup + +ChangeSet@1.2763, 2012-02-06 06:04:15+00:00, stenn@psp-fb1.ntp.org + autogen translator updates + + BitKeeper/deleted/02/mdoc2mdoc~efc40f7d5fb243b2@1.2 +0 -0 + Delete: sntp/ag-tpl/mdoc2mdoc + + BitKeeper/deleted/55/mdoc2man~beb9c4c088d95890@1.3 +0 -0 + Delete: sntp/ag-tpl/mdoc2man + + sntp/ag-tpl/texi2man@1.1 +63 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/ag-tpl/texi2man + + sntp/ag-tpl/texi2man@1.0 +0 -0 + + sntp/ag-tpl/texi2mdoc@1.1 +182 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/ag-tpl/texi2mdoc + + sntp/ag-tpl/texi2mdoc@1.0 +0 -0 + + sntp/ag-tpl/texi2plain@1.1 +62 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/ag-tpl/texi2plain + + sntp/ag-tpl/texi2plain@1.0 +0 -0 + + sntp/ag-tpl/texi2txt@1.1 +81 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/ag-tpl/texi2txt + + sntp/ag-tpl/texi2txt@1.0 +0 -0 + +ChangeSet@1.2759.1.2, 2012-01-30 05:15:20+00:00, stenn@psp-fb1.ntp.org + Handle .5 in the mansec substitutions + + sntp/scripts/mansec2subst.sed@1.3 +2 -0 + Handle .5 in the mansec substitutions + +ChangeSet@1.2759.1.1, 2012-01-30 05:14:29+00:00, stenn@psp-fb1.ntp.org + Rules for ntp.conf.5 and ntp.keys.5 + + ntpd/Makefile.am@1.113 +62 -1 + Rules for ntp.conf.5 and ntp.keys.5 + +ChangeSet@1.2762, 2012-01-29 22:06:30+00:00, stenn@deacon.udel.edu + NTP_4_2_7P255 + TAG: NTP_4_2_7P255 + + ChangeLog@1.1111 +1 -0 + NTP_4_2_7P255 + + ntpd/ntpd-opts.c@1.260 +4 -4 + NTP_4_2_7P255 + + ntpd/ntpd-opts.h@1.260 +3 -3 + NTP_4_2_7P255 + + ntpd/ntpd-opts.texi@1.258 +2 -2 + NTP_4_2_7P255 + + ntpd/ntpd.1ntpdman@1.71 +2 -2 + NTP_4_2_7P255 + + ntpd/ntpd.1ntpdmdoc@1.71 +1 -1 + NTP_4_2_7P255 + + ntpd/ntpd.man.in@1.71 +2 -2 + NTP_4_2_7P255 + + ntpd/ntpd.mdoc.in@1.71 +1 -1 + NTP_4_2_7P255 + + ntpdc/ntpdc-opts.c@1.255 +4 -4 + NTP_4_2_7P255 + + ntpdc/ntpdc-opts.h@1.255 +3 -3 + NTP_4_2_7P255 + + ntpdc/ntpdc-opts.texi@1.255 +2 -2 + NTP_4_2_7P255 + + ntpdc/ntpdc.1ntpdcman@1.71 +2 -2 + NTP_4_2_7P255 + + ntpdc/ntpdc.1ntpdcmdoc@1.71 +1 -1 + NTP_4_2_7P255 + + ntpdc/ntpdc.html@1.83 +2 -2 + NTP_4_2_7P255 + + ntpdc/ntpdc.man.in@1.71 +2 -2 + NTP_4_2_7P255 + + ntpdc/ntpdc.mdoc.in@1.71 +1 -1 + NTP_4_2_7P255 + + ntpq/ntpq-opts.c@1.257 +4 -4 + NTP_4_2_7P255 + + ntpq/ntpq-opts.h@1.257 +3 -3 + NTP_4_2_7P255 + + ntpq/ntpq-opts.texi@1.257 +2 -2 + NTP_4_2_7P255 + + ntpq/ntpq.1ntpqman@1.71 +2 -2 + NTP_4_2_7P255 + + ntpq/ntpq.1ntpqmdoc@1.71 +1 -1 + NTP_4_2_7P255 + + ntpq/ntpq.man.in@1.71 +2 -2 + NTP_4_2_7P255 + + ntpq/ntpq.mdoc.in@1.71 +1 -1 + NTP_4_2_7P255 + + ntpsnmpd/ntpsnmpd-opts.c@1.257 +4 -4 + NTP_4_2_7P255 + + ntpsnmpd/ntpsnmpd-opts.h@1.257 +3 -3 + NTP_4_2_7P255 + + ntpsnmpd/ntpsnmpd-opts.texi@1.257 +2 -2 + NTP_4_2_7P255 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.71 +2 -2 + NTP_4_2_7P255 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.71 +1 -1 + NTP_4_2_7P255 + + ntpsnmpd/ntpsnmpd.man.in@1.71 +2 -2 + NTP_4_2_7P255 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.71 +1 -1 + NTP_4_2_7P255 + + packageinfo.sh@1.258 +1 -1 + NTP_4_2_7P255 + + scripts/ntp-wait-opts.texi@1.75 +1 -1 + NTP_4_2_7P255 + + scripts/ntp-wait.1ntp-waitman@1.71 +2 -2 + NTP_4_2_7P255 + + scripts/ntp-wait.1ntp-waitmdoc@1.71 +1 -1 + NTP_4_2_7P255 + + scripts/ntp-wait.html@1.75 +1 -1 + NTP_4_2_7P255 + + scripts/ntp-wait.man.in@1.71 +2 -2 + NTP_4_2_7P255 + + scripts/ntp-wait.mdoc.in@1.71 +1 -1 + NTP_4_2_7P255 + + sntp/sntp-opts.c@1.253 +4 -4 + NTP_4_2_7P255 + + sntp/sntp-opts.h@1.253 +3 -3 + NTP_4_2_7P255 + + sntp/sntp-opts.texi@1.253 +2 -2 + NTP_4_2_7P255 + + sntp/sntp.1sntpman@1.73 +2 -2 + NTP_4_2_7P255 + + sntp/sntp.1sntpmdoc@1.73 +1 -1 + NTP_4_2_7P255 + + sntp/sntp.html@1.253 +2 -2 + NTP_4_2_7P255 + + sntp/sntp.man.in@1.73 +2 -2 + NTP_4_2_7P255 + + sntp/sntp.mdoc.in@1.73 +1 -1 + NTP_4_2_7P255 + + util/ntp-keygen-opts.c@1.257 +4 -4 + NTP_4_2_7P255 + + util/ntp-keygen-opts.h@1.257 +3 -3 + NTP_4_2_7P255 + + util/ntp-keygen-opts.texi@1.258 +2 -2 + NTP_4_2_7P255 + + util/ntp-keygen.1ntp-keygenman@1.71 +2 -2 + NTP_4_2_7P255 + + util/ntp-keygen.1ntp-keygenmdoc@1.71 +1 -1 + NTP_4_2_7P255 + + util/ntp-keygen.man.in@1.71 +2 -2 + NTP_4_2_7P255 + + util/ntp-keygen.mdoc.in@1.71 +1 -1 + NTP_4_2_7P255 + +ChangeSet@1.2761, 2012-01-29 16:49:09-05:00, stenn@deacon.udel.edu + [Bug 603] Only link with nlist()-related libraries when needed: More cleanup + + ChangeLog@1.1110 +2 -0 + [Bug 603] Only link with nlist()-related libraries when needed: More cleanup + + configure.ac@1.540 +6 -1 + [Bug 603] Only link with nlist()-related libraries when needed: More cleanup + +ChangeSet@1.2760, 2012-01-29 07:02:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P254 + TAG: NTP_4_2_7P254 + + ChangeLog@1.1109 +1 -0 + NTP_4_2_7P254 + + ntpd/ntpd-opts.c@1.259 +4 -4 + NTP_4_2_7P254 + + ntpd/ntpd-opts.h@1.259 +3 -3 + NTP_4_2_7P254 + + ntpd/ntpd-opts.texi@1.257 +2 -2 + NTP_4_2_7P254 + + ntpd/ntpd.1ntpdman@1.70 +2 -2 + NTP_4_2_7P254 + + ntpd/ntpd.1ntpdmdoc@1.70 +2 -2 + NTP_4_2_7P254 + + ntpd/ntpd.man.in@1.70 +2 -2 + NTP_4_2_7P254 + + ntpd/ntpd.mdoc.in@1.70 +2 -2 + NTP_4_2_7P254 + + ntpdc/ntpdc-opts.c@1.254 +4 -4 + NTP_4_2_7P254 + + ntpdc/ntpdc-opts.h@1.254 +3 -3 + NTP_4_2_7P254 + + ntpdc/ntpdc-opts.texi@1.254 +2 -2 + NTP_4_2_7P254 + + ntpdc/ntpdc.1ntpdcman@1.70 +2 -2 + NTP_4_2_7P254 + + ntpdc/ntpdc.1ntpdcmdoc@1.70 +2 -2 + NTP_4_2_7P254 + + ntpdc/ntpdc.html@1.82 +2 -2 + NTP_4_2_7P254 + + ntpdc/ntpdc.man.in@1.70 +2 -2 + NTP_4_2_7P254 + + ntpdc/ntpdc.mdoc.in@1.70 +2 -2 + NTP_4_2_7P254 + + ntpq/ntpq-opts.c@1.256 +4 -4 + NTP_4_2_7P254 + + ntpq/ntpq-opts.h@1.256 +3 -3 + NTP_4_2_7P254 + + ntpq/ntpq-opts.texi@1.256 +2 -2 + NTP_4_2_7P254 + + ntpq/ntpq.1ntpqman@1.70 +2 -2 + NTP_4_2_7P254 + + ntpq/ntpq.1ntpqmdoc@1.70 +2 -2 + NTP_4_2_7P254 + + ntpq/ntpq.man.in@1.70 +2 -2 + NTP_4_2_7P254 + + ntpq/ntpq.mdoc.in@1.70 +2 -2 + NTP_4_2_7P254 + + ntpsnmpd/ntpsnmpd-opts.c@1.256 +4 -4 + NTP_4_2_7P254 + + ntpsnmpd/ntpsnmpd-opts.h@1.256 +3 -3 + NTP_4_2_7P254 + + ntpsnmpd/ntpsnmpd-opts.texi@1.256 +2 -2 + NTP_4_2_7P254 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.70 +2 -2 + NTP_4_2_7P254 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.70 +2 -2 + NTP_4_2_7P254 + + ntpsnmpd/ntpsnmpd.man.in@1.70 +2 -2 + NTP_4_2_7P254 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.70 +2 -2 + NTP_4_2_7P254 + + packageinfo.sh@1.257 +1 -1 + NTP_4_2_7P254 + + scripts/ntp-wait-opts.texi@1.74 +1 -1 + NTP_4_2_7P254 + + scripts/ntp-wait.1ntp-waitman@1.70 +2 -2 + NTP_4_2_7P254 + + scripts/ntp-wait.1ntp-waitmdoc@1.70 +2 -2 + NTP_4_2_7P254 + + scripts/ntp-wait.html@1.74 +1 -1 + NTP_4_2_7P254 + + scripts/ntp-wait.man.in@1.70 +2 -2 + NTP_4_2_7P254 + + scripts/ntp-wait.mdoc.in@1.70 +2 -2 + NTP_4_2_7P254 + + sntp/sntp-opts.c@1.252 +4 -4 + NTP_4_2_7P254 + + sntp/sntp-opts.h@1.252 +3 -3 + NTP_4_2_7P254 + + sntp/sntp-opts.texi@1.252 +2 -2 + NTP_4_2_7P254 + + sntp/sntp.1sntpman@1.72 +2 -2 + NTP_4_2_7P254 + + sntp/sntp.1sntpmdoc@1.72 +2 -2 + NTP_4_2_7P254 + + sntp/sntp.html@1.252 +2 -2 + NTP_4_2_7P254 + + sntp/sntp.man.in@1.72 +2 -2 + NTP_4_2_7P254 + + sntp/sntp.mdoc.in@1.72 +2 -2 + NTP_4_2_7P254 + + util/ntp-keygen-opts.c@1.256 +4 -4 + NTP_4_2_7P254 + + util/ntp-keygen-opts.h@1.256 +3 -3 + NTP_4_2_7P254 + + util/ntp-keygen-opts.texi@1.257 +2 -2 + NTP_4_2_7P254 + + util/ntp-keygen.1ntp-keygenman@1.70 +2 -2 + NTP_4_2_7P254 + + util/ntp-keygen.1ntp-keygenmdoc@1.70 +2 -2 + NTP_4_2_7P254 + + util/ntp-keygen.man.in@1.70 +2 -2 + NTP_4_2_7P254 + + util/ntp-keygen.mdoc.in@1.70 +2 -2 + NTP_4_2_7P254 + +ChangeSet@1.2759, 2012-01-28 23:24:08+00:00, stenn@psp-fb1.ntp.org + Only link with nlist()-related libraries when needed + + ChangeLog@1.1108 +1 -0 + Only link with nlist()-related libraries when needed + + configure.ac@1.539 +8 -5 + Only link with nlist()-related libraries when needed + + util/Makefile.am@1.69 +2 -0 + Only link with nlist()-related libraries when needed + +ChangeSet@1.2758, 2012-01-26 06:05:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P253 + TAG: NTP_4_2_7P253 + + ChangeLog@1.1107 +1 -0 + NTP_4_2_7P253 + + ntpd/ntpd-opts.c@1.258 +251 -256 + NTP_4_2_7P253 + + ntpd/ntpd-opts.h@1.258 +7 -7 + NTP_4_2_7P253 + + ntpd/ntpd-opts.texi@1.256 +2 -2 + NTP_4_2_7P253 + + ntpd/ntpd.1ntpdman@1.69 +4 -4 + NTP_4_2_7P253 + + ntpd/ntpd.1ntpdmdoc@1.69 +4 -4 + NTP_4_2_7P253 + + ntpd/ntpd.man.in@1.69 +4 -4 + NTP_4_2_7P253 + + ntpd/ntpd.mdoc.in@1.69 +4 -4 + NTP_4_2_7P253 + + ntpdc/ntpdc-opts.c@1.253 +120 -125 + NTP_4_2_7P253 + + ntpdc/ntpdc-opts.h@1.253 +7 -7 + NTP_4_2_7P253 + + ntpdc/ntpdc-opts.texi@1.253 +2 -2 + NTP_4_2_7P253 + + ntpdc/ntpdc.1ntpdcman@1.69 +3 -3 + NTP_4_2_7P253 + + ntpdc/ntpdc.1ntpdcmdoc@1.69 +3 -3 + NTP_4_2_7P253 + + ntpdc/ntpdc.html@1.81 +2 -2 + NTP_4_2_7P253 + + ntpdc/ntpdc.man.in@1.69 +3 -3 + NTP_4_2_7P253 + + ntpdc/ntpdc.mdoc.in@1.69 +3 -3 + NTP_4_2_7P253 + + ntpq/ntpq-opts.c@1.255 +111 -116 + NTP_4_2_7P253 + + ntpq/ntpq-opts.h@1.255 +7 -7 + NTP_4_2_7P253 + + ntpq/ntpq-opts.texi@1.255 +2 -2 + NTP_4_2_7P253 + + ntpq/ntpq.1ntpqman@1.69 +4 -4 + NTP_4_2_7P253 + + ntpq/ntpq.1ntpqmdoc@1.69 +4 -4 + NTP_4_2_7P253 + + ntpq/ntpq.man.in@1.69 +4 -4 + NTP_4_2_7P253 + + ntpq/ntpq.mdoc.in@1.69 +4 -4 + NTP_4_2_7P253 + + ntpsnmpd/ntpsnmpd-opts.c@1.255 +81 -86 + NTP_4_2_7P253 + + ntpsnmpd/ntpsnmpd-opts.h@1.255 +7 -7 + NTP_4_2_7P253 + + ntpsnmpd/ntpsnmpd-opts.texi@1.255 +2 -2 + NTP_4_2_7P253 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.69 +3 -3 + NTP_4_2_7P253 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.69 +3 -3 + NTP_4_2_7P253 + + ntpsnmpd/ntpsnmpd.man.in@1.69 +3 -3 + NTP_4_2_7P253 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.69 +3 -3 + NTP_4_2_7P253 + + packageinfo.sh@1.256 +1 -1 + NTP_4_2_7P253 + + scripts/ntp-wait-opts.texi@1.73 +1 -1 + NTP_4_2_7P253 + + scripts/ntp-wait.1ntp-waitman@1.69 +3 -3 + NTP_4_2_7P253 + + scripts/ntp-wait.1ntp-waitmdoc@1.69 +3 -3 + NTP_4_2_7P253 + + scripts/ntp-wait.html@1.73 +1 -1 + NTP_4_2_7P253 + + scripts/ntp-wait.man.in@1.69 +3 -3 + NTP_4_2_7P253 + + scripts/ntp-wait.mdoc.in@1.69 +3 -3 + NTP_4_2_7P253 + + sntp/sntp-opts.c@1.251 +178 -183 + NTP_4_2_7P253 + + sntp/sntp-opts.h@1.251 +7 -7 + NTP_4_2_7P253 + + sntp/sntp-opts.texi@1.251 +2 -2 + NTP_4_2_7P253 + + sntp/sntp.1sntpman@1.71 +3 -3 + NTP_4_2_7P253 + + sntp/sntp.1sntpmdoc@1.71 +3 -3 + NTP_4_2_7P253 + + sntp/sntp.html@1.251 +2 -2 + NTP_4_2_7P253 + + sntp/sntp.man.in@1.71 +3 -3 + NTP_4_2_7P253 + + sntp/sntp.mdoc.in@1.71 +3 -3 + NTP_4_2_7P253 + + util/ntp-keygen-opts.c@1.255 +180 -185 + NTP_4_2_7P253 + + util/ntp-keygen-opts.h@1.255 +7 -7 + NTP_4_2_7P253 + + util/ntp-keygen-opts.texi@1.256 +2 -2 + NTP_4_2_7P253 + + util/ntp-keygen.1ntp-keygenman@1.69 +4 -4 + NTP_4_2_7P253 + + util/ntp-keygen.1ntp-keygenmdoc@1.69 +4 -4 + NTP_4_2_7P253 + + util/ntp-keygen.man.in@1.69 +4 -4 + NTP_4_2_7P253 + + util/ntp-keygen.mdoc.in@1.69 +4 -4 + NTP_4_2_7P253 + +ChangeSet@1.2757, 2012-01-25 23:01:37-05:00, stenn@deacon.udel.edu + Update a license URL + + ChangeLog@1.1106 +1 -0 + Update a license URL + + sntp/include/ntp.lic@1.6 +1 -1 + Update a license URL + +ChangeSet@1.2756, 2012-01-26 03:33:12+00:00, davehart@dlh-7551.ad.hartbrothers.com + Override --version output without the ugly hack previously used, + as Autogen 5.13 and later provide version-proc = override in .def. + + include/ntp_libopts.h@1.2 +1 -0 + Override --version output without the ugly hack previously used, + as Autogen 5.13 and later provide version-proc = override in .def. + + libntp/ntp_libopts.c@1.5 +28 -30 + Override --version output without the ugly hack previously used, + as Autogen 5.13 and later provide version-proc = override in .def. + + sntp/include/copyright.def@1.20 +2 -1 + Override --version output without the ugly hack previously used, + as Autogen 5.13 and later provide version-proc = override in .def. + Change owner = to match copyright.html. + +ChangeSet@1.2755, 2012-01-26 01:44:08+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2126] Compile error on Windows with libopts from Autogen 5.14. + + ChangeLog@1.1105 +1 -0 + [Bug 2126] Compile error on Windows with libopts from Autogen 5.14. + + sntp/libopts/text_mmap.c@1.9 +6 -2 + [Bug 2126] Compile error on Windows with libopts from Autogen 5.14. + Patch provided by Bruce Korb based on pending Autogen changes. + +ChangeSet@1.2754, 2012-01-25 12:05:43+00:00, stenn@deacon.udel.edu + NTP_4_2_7P252 + TAG: NTP_4_2_7P252 + + ChangeLog@1.1104 +1 -0 + NTP_4_2_7P252 + + ntpd/ntpd-opts.c@1.257 +516 -442 + NTP_4_2_7P252 + + ntpd/ntpd-opts.h@1.257 +11 -10 + NTP_4_2_7P252 + + ntpd/ntpd-opts.texi@1.255 +3 -3 + NTP_4_2_7P252 + + ntpd/ntpd.1ntpdman@1.68 +2 -2 + NTP_4_2_7P252 + + ntpd/ntpd.1ntpdmdoc@1.68 +2 -2 + NTP_4_2_7P252 + + ntpd/ntpd.man.in@1.68 +2 -2 + NTP_4_2_7P252 + + ntpd/ntpd.mdoc.in@1.68 +2 -2 + NTP_4_2_7P252 + + ntpdc/ntpdc-opts.c@1.252 +255 -219 + NTP_4_2_7P252 + + ntpdc/ntpdc-opts.h@1.252 +11 -9 + NTP_4_2_7P252 + + ntpdc/ntpdc-opts.texi@1.252 +3 -3 + NTP_4_2_7P252 + + ntpdc/ntpdc.1ntpdcman@1.68 +2 -2 + NTP_4_2_7P252 + + ntpdc/ntpdc.1ntpdcmdoc@1.68 +2 -2 + NTP_4_2_7P252 + + ntpdc/ntpdc.html@1.80 +3 -3 + NTP_4_2_7P252 + + ntpdc/ntpdc.man.in@1.68 +2 -2 + NTP_4_2_7P252 + + ntpdc/ntpdc.mdoc.in@1.68 +2 -2 + NTP_4_2_7P252 + + ntpq/ntpq-opts.c@1.254 +244 -207 + NTP_4_2_7P252 + + ntpq/ntpq-opts.h@1.254 +11 -9 + NTP_4_2_7P252 + + ntpq/ntpq-opts.texi@1.254 +3 -3 + NTP_4_2_7P252 + + ntpq/ntpq.1ntpqman@1.68 +2 -2 + NTP_4_2_7P252 + + ntpq/ntpq.1ntpqmdoc@1.68 +2 -2 + NTP_4_2_7P252 + + ntpq/ntpq.man.in@1.68 +2 -2 + NTP_4_2_7P252 + + ntpq/ntpq.mdoc.in@1.68 +2 -2 + NTP_4_2_7P252 + + ntpsnmpd/ntpsnmpd-opts.c@1.254 +164 -132 + NTP_4_2_7P252 + + ntpsnmpd/ntpsnmpd-opts.h@1.254 +11 -9 + NTP_4_2_7P252 + + ntpsnmpd/ntpsnmpd-opts.texi@1.254 +3 -3 + NTP_4_2_7P252 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.68 +2 -2 + NTP_4_2_7P252 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.68 +2 -2 + NTP_4_2_7P252 + + ntpsnmpd/ntpsnmpd.man.in@1.68 +2 -2 + NTP_4_2_7P252 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.68 +2 -2 + NTP_4_2_7P252 + + packageinfo.sh@1.255 +1 -1 + NTP_4_2_7P252 + + scripts/ntp-wait-opts.texi@1.72 +2 -2 + NTP_4_2_7P252 + + scripts/ntp-wait.1ntp-waitman@1.68 +2 -2 + NTP_4_2_7P252 + + scripts/ntp-wait.1ntp-waitmdoc@1.68 +2 -2 + NTP_4_2_7P252 + + scripts/ntp-wait.html@1.72 +2 -2 + NTP_4_2_7P252 + + scripts/ntp-wait.man.in@1.68 +2 -2 + NTP_4_2_7P252 + + scripts/ntp-wait.mdoc.in@1.68 +2 -2 + NTP_4_2_7P252 + + sntp/sntp-opts.c@1.250 +366 -305 + NTP_4_2_7P252 + + sntp/sntp-opts.h@1.250 +11 -9 + NTP_4_2_7P252 + + sntp/sntp-opts.texi@1.250 +3 -3 + NTP_4_2_7P252 + + sntp/sntp.1sntpman@1.70 +2 -2 + NTP_4_2_7P252 + + sntp/sntp.1sntpmdoc@1.70 +2 -2 + NTP_4_2_7P252 + + sntp/sntp.html@1.250 +3 -3 + NTP_4_2_7P252 + + sntp/sntp.man.in@1.70 +2 -2 + NTP_4_2_7P252 + + sntp/sntp.mdoc.in@1.70 +2 -2 + NTP_4_2_7P252 + + util/ntp-keygen-opts.c@1.254 +451 -387 + NTP_4_2_7P252 + + util/ntp-keygen-opts.h@1.254 +11 -13 + NTP_4_2_7P252 + + util/ntp-keygen-opts.texi@1.255 +3 -3 + NTP_4_2_7P252 + + util/ntp-keygen.1ntp-keygenman@1.68 +2 -2 + NTP_4_2_7P252 + + util/ntp-keygen.1ntp-keygenmdoc@1.68 +2 -2 + NTP_4_2_7P252 + + util/ntp-keygen.man.in@1.68 +2 -2 + NTP_4_2_7P252 + + util/ntp-keygen.mdoc.in@1.68 +2 -2 + NTP_4_2_7P252 + +ChangeSet@1.2753, 2012-01-25 09:54:11+00:00, stenn@psp-fb1.ntp.org + Upgrade to autogen-5.14 (and libopts-36.1.11) + + BitKeeper/deleted/94/enumeration.c~263a95e02049b99c@1.9 +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/97/environment.c~444322456d6044d7@1.11 +0 -0 + Delete: sntp/libopts/environment.c + + ChangeLog@1.1103 +1 -0 + Upgrade to autogen-5.14 (and libopts-36.1.11) + + sntp/include/autogen-version.def@1.9 +1 -1 + Upgrade to autogen 5.14 + + sntp/libopts/Makefile.am@1.11 +16 -15 + Upgrade to libopts-36.1.11 + + sntp/libopts/ag-char-map.h@1.14 +3 -3 + Upgrade to libopts-36.1.11 + + sntp/libopts/autoopts.c@1.11 +48 -515 + Upgrade to libopts-36.1.11 + + sntp/libopts/autoopts/options.h@1.13 +47 -37 + Upgrade to libopts-36.1.11 + + sntp/libopts/autoopts/usage-txt.h@1.13 +324 -312 + Upgrade to libopts-36.1.11 + + sntp/libopts/check.c@1.1 +164 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/libopts/check.c + + sntp/libopts/check.c@1.0 +0 -0 + + sntp/libopts/configfile.c@1.12 +35 -25 + Upgrade to libopts-36.1.11 + + sntp/libopts/enum.c@1.1 +522 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/libopts/enum.c + + sntp/libopts/enum.c@1.0 +0 -0 + + sntp/libopts/env.c@1.1 +259 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/libopts/env.c + + sntp/libopts/env.c@1.0 +0 -0 + + sntp/libopts/file.c@1.9 +129 -94 + Upgrade to libopts-36.1.11 + + sntp/libopts/find.c@1.1 +568 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/libopts/find.c + + sntp/libopts/find.c@1.0 +0 -0 + + sntp/libopts/genshell.c@1.14 +140 -114 + Upgrade to libopts-36.1.11 + + sntp/libopts/genshell.h@1.14 +29 -24 + Upgrade to libopts-36.1.11 + + sntp/libopts/libopts.c@1.4 +4 -2 + Upgrade to libopts-36.1.11 + + sntp/libopts/load.c@1.10 +15 -16 + Upgrade to libopts-36.1.11 + + sntp/libopts/m4/libopts.m4@1.17 +4 -4 + Upgrade to libopts-36.1.11 + + sntp/libopts/proto.h@1.14 +35 -14 + Upgrade to libopts-36.1.11 + + sntp/libopts/reset.c@1.8 +3 -3 + Upgrade to libopts-36.1.11 + + sntp/libopts/sort.c@1.8 +5 -5 + Upgrade to libopts-36.1.11 + + sntp/libopts/text_mmap.c@1.8 +231 -248 + Upgrade to libopts-36.1.11 + + sntp/libopts/usage.c@1.9 +220 -62 + Upgrade to libopts-36.1.11 + + sntp/libopts/value-type.h@1.14 +1 -1 + Upgrade to libopts-36.1.11 + + sntp/libopts/version.c@1.9 +14 -7 + Upgrade to libopts-36.1.11 + + sntp/libopts/xat-attribute.h@1.14 +1 -1 + Upgrade to libopts-36.1.11 + +ChangeSet@1.2752, 2012-01-17 11:36:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P251 + TAG: NTP_4_2_7P251 + + ChangeLog@1.1102 +1 -0 + NTP_4_2_7P251 + + ntpd/ntpd-opts.c@1.256 +3 -3 + NTP_4_2_7P251 + + ntpd/ntpd-opts.h@1.256 +3 -3 + NTP_4_2_7P251 + + ntpd/ntpd-opts.texi@1.254 +2 -2 + NTP_4_2_7P251 + + ntpd/ntpd.1ntpdman@1.67 +2 -2 + NTP_4_2_7P251 + + ntpd/ntpd.1ntpdmdoc@1.67 +2 -2 + NTP_4_2_7P251 + + ntpd/ntpd.man.in@1.67 +2 -2 + NTP_4_2_7P251 + + ntpd/ntpd.mdoc.in@1.67 +2 -2 + NTP_4_2_7P251 + + ntpdc/ntpdc-opts.c@1.251 +3 -3 + NTP_4_2_7P251 + + ntpdc/ntpdc-opts.h@1.251 +3 -3 + NTP_4_2_7P251 + + ntpdc/ntpdc-opts.texi@1.251 +2 -2 + NTP_4_2_7P251 + + ntpdc/ntpdc.1ntpdcman@1.67 +2 -2 + NTP_4_2_7P251 + + ntpdc/ntpdc.1ntpdcmdoc@1.67 +2 -2 + NTP_4_2_7P251 + + ntpdc/ntpdc.html@1.79 +2 -2 + NTP_4_2_7P251 + + ntpdc/ntpdc.man.in@1.67 +2 -2 + NTP_4_2_7P251 + + ntpdc/ntpdc.mdoc.in@1.67 +2 -2 + NTP_4_2_7P251 + + ntpq/ntpq-opts.c@1.253 +3 -3 + NTP_4_2_7P251 + + ntpq/ntpq-opts.h@1.253 +3 -3 + NTP_4_2_7P251 + + ntpq/ntpq-opts.texi@1.253 +2 -2 + NTP_4_2_7P251 + + ntpq/ntpq.1ntpqman@1.67 +2 -2 + NTP_4_2_7P251 + + ntpq/ntpq.1ntpqmdoc@1.67 +2 -2 + NTP_4_2_7P251 + + ntpq/ntpq.man.in@1.67 +2 -2 + NTP_4_2_7P251 + + ntpq/ntpq.mdoc.in@1.67 +2 -2 + NTP_4_2_7P251 + + ntpsnmpd/ntpsnmpd-opts.c@1.253 +3 -3 + NTP_4_2_7P251 + + ntpsnmpd/ntpsnmpd-opts.h@1.253 +3 -3 + NTP_4_2_7P251 + + ntpsnmpd/ntpsnmpd-opts.texi@1.253 +2 -2 + NTP_4_2_7P251 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.67 +2 -2 + NTP_4_2_7P251 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.67 +2 -2 + NTP_4_2_7P251 + + ntpsnmpd/ntpsnmpd.man.in@1.67 +2 -2 + NTP_4_2_7P251 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.67 +2 -2 + NTP_4_2_7P251 + + packageinfo.sh@1.254 +1 -1 + NTP_4_2_7P251 + + scripts/ntp-wait-opts.texi@1.71 +1 -1 + NTP_4_2_7P251 + + scripts/ntp-wait.1ntp-waitman@1.67 +2 -2 + NTP_4_2_7P251 + + scripts/ntp-wait.1ntp-waitmdoc@1.67 +2 -2 + NTP_4_2_7P251 + + scripts/ntp-wait.html@1.71 +1 -1 + NTP_4_2_7P251 + + scripts/ntp-wait.man.in@1.67 +2 -2 + NTP_4_2_7P251 + + scripts/ntp-wait.mdoc.in@1.67 +2 -2 + NTP_4_2_7P251 + + sntp/sntp-opts.c@1.249 +3 -3 + NTP_4_2_7P251 + + sntp/sntp-opts.h@1.249 +3 -3 + NTP_4_2_7P251 + + sntp/sntp-opts.texi@1.249 +2 -2 + NTP_4_2_7P251 + + sntp/sntp.1sntpman@1.69 +2 -2 + NTP_4_2_7P251 + + sntp/sntp.1sntpmdoc@1.69 +2 -2 + NTP_4_2_7P251 + + sntp/sntp.html@1.249 +2 -2 + NTP_4_2_7P251 + + sntp/sntp.man.in@1.69 +2 -2 + NTP_4_2_7P251 + + sntp/sntp.mdoc.in@1.69 +2 -2 + NTP_4_2_7P251 + + util/ntp-keygen-opts.c@1.253 +3 -3 + NTP_4_2_7P251 + + util/ntp-keygen-opts.h@1.253 +3 -3 + NTP_4_2_7P251 + + util/ntp-keygen-opts.texi@1.254 +2 -2 + NTP_4_2_7P251 + + util/ntp-keygen.1ntp-keygenman@1.67 +2 -2 + NTP_4_2_7P251 + + util/ntp-keygen.1ntp-keygenmdoc@1.67 +2 -2 + NTP_4_2_7P251 + + util/ntp-keygen.man.in@1.67 +2 -2 + NTP_4_2_7P251 + + util/ntp-keygen.mdoc.in@1.67 +2 -2 + NTP_4_2_7P251 + +ChangeSet@1.2751, 2012-01-17 00:59:47+00:00, stenn@psp-fb1.ntp.org + [Bug 2115] ntptrace should accept both rootdispersion and rootdisp + + ChangeLog@1.1101 +1 -0 + [Bug 2115] ntptrace should accept both rootdispersion and rootdisp + + scripts/ntptrace.in@1.8 +2 -1 + [Bug 2115] ntptrace should accept both rootdispersion and rootdisp + +ChangeSet@1.2750, 2012-01-15 11:37:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P250 + TAG: NTP_4_2_7P250 + + ChangeLog@1.1100 +1 -0 + NTP_4_2_7P250 + + ntpd/ntpd-opts.c@1.255 +5 -5 + NTP_4_2_7P250 + + ntpd/ntpd-opts.h@1.255 +4 -4 + NTP_4_2_7P250 + + ntpd/ntpd-opts.texi@1.253 +2 -2 + NTP_4_2_7P250 + + ntpd/ntpd.1ntpdman@1.66 +3 -3 + NTP_4_2_7P250 + + ntpd/ntpd.1ntpdmdoc@1.66 +3 -3 + NTP_4_2_7P250 + + ntpd/ntpd.man.in@1.66 +3 -3 + NTP_4_2_7P250 + + ntpd/ntpd.mdoc.in@1.66 +3 -3 + NTP_4_2_7P250 + + ntpdc/ntpdc-opts.c@1.250 +5 -5 + NTP_4_2_7P250 + + ntpdc/ntpdc-opts.h@1.250 +4 -4 + NTP_4_2_7P250 + + ntpdc/ntpdc-opts.texi@1.250 +2 -2 + NTP_4_2_7P250 + + ntpdc/ntpdc.1ntpdcman@1.66 +3 -3 + NTP_4_2_7P250 + + ntpdc/ntpdc.1ntpdcmdoc@1.66 +3 -3 + NTP_4_2_7P250 + + ntpdc/ntpdc.html@1.78 +2 -2 + NTP_4_2_7P250 + + ntpdc/ntpdc.man.in@1.66 +3 -3 + NTP_4_2_7P250 + + ntpdc/ntpdc.mdoc.in@1.66 +3 -3 + NTP_4_2_7P250 + + ntpq/ntpq-opts.c@1.252 +5 -5 + NTP_4_2_7P250 + + ntpq/ntpq-opts.h@1.252 +4 -4 + NTP_4_2_7P250 + + ntpq/ntpq-opts.texi@1.252 +2 -2 + NTP_4_2_7P250 + + ntpq/ntpq.1ntpqman@1.66 +3 -3 + NTP_4_2_7P250 + + ntpq/ntpq.1ntpqmdoc@1.66 +3 -3 + NTP_4_2_7P250 + + ntpq/ntpq.man.in@1.66 +3 -3 + NTP_4_2_7P250 + + ntpq/ntpq.mdoc.in@1.66 +3 -3 + NTP_4_2_7P250 + + ntpsnmpd/ntpsnmpd-opts.c@1.252 +5 -5 + NTP_4_2_7P250 + + ntpsnmpd/ntpsnmpd-opts.h@1.252 +4 -4 + NTP_4_2_7P250 + + ntpsnmpd/ntpsnmpd-opts.texi@1.252 +2 -2 + NTP_4_2_7P250 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.66 +3 -3 + NTP_4_2_7P250 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.66 +3 -3 + NTP_4_2_7P250 + + ntpsnmpd/ntpsnmpd.man.in@1.66 +3 -3 + NTP_4_2_7P250 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.66 +3 -3 + NTP_4_2_7P250 + + packageinfo.sh@1.253 +1 -1 + NTP_4_2_7P250 + + scripts/ntp-wait-opts.texi@1.70 +1 -1 + NTP_4_2_7P250 + + scripts/ntp-wait.1ntp-waitman@1.66 +3 -3 + NTP_4_2_7P250 + + scripts/ntp-wait.1ntp-waitmdoc@1.66 +3 -3 + NTP_4_2_7P250 + + scripts/ntp-wait.html@1.70 +1 -1 + NTP_4_2_7P250 + + scripts/ntp-wait.man.in@1.66 +3 -3 + NTP_4_2_7P250 + + scripts/ntp-wait.mdoc.in@1.66 +3 -3 + NTP_4_2_7P250 + + sntp/sntp-opts.c@1.248 +5 -5 + NTP_4_2_7P250 + + sntp/sntp-opts.h@1.248 +4 -4 + NTP_4_2_7P250 + + sntp/sntp-opts.texi@1.248 +2 -2 + NTP_4_2_7P250 + + sntp/sntp.1sntpman@1.68 +3 -3 + NTP_4_2_7P250 + + sntp/sntp.1sntpmdoc@1.68 +3 -3 + NTP_4_2_7P250 + + sntp/sntp.html@1.248 +2 -2 + NTP_4_2_7P250 + + sntp/sntp.man.in@1.68 +3 -3 + NTP_4_2_7P250 + + sntp/sntp.mdoc.in@1.68 +3 -3 + NTP_4_2_7P250 + + util/ntp-keygen-opts.c@1.252 +5 -5 + NTP_4_2_7P250 + + util/ntp-keygen-opts.h@1.252 +4 -4 + NTP_4_2_7P250 + + util/ntp-keygen-opts.texi@1.253 +2 -2 + NTP_4_2_7P250 + + util/ntp-keygen.1ntp-keygenman@1.66 +3 -3 + NTP_4_2_7P250 + + util/ntp-keygen.1ntp-keygenmdoc@1.66 +3 -3 + NTP_4_2_7P250 + + util/ntp-keygen.man.in@1.66 +3 -3 + NTP_4_2_7P250 + + util/ntp-keygen.mdoc.in@1.66 +3 -3 + NTP_4_2_7P250 + +ChangeSet@1.2749, 2012-01-14 21:57:29+00:00, stenn@psp-fb1.ntp.org + Update the copyright year + + ChangeLog@1.1099 +1 -0 + Update the copyright year + + html/copyright.html@1.59 +1 -1 + Update the copyright year + + sntp/include/copyright.def@1.19 +1 -1 + Update the copyright year + +ChangeSet@1.2748, 2012-01-13 00:20:30-08:00, harlan@hms-mbp.local + [Bug 2113] Warn about ignored extra args in ntpq + + ChangeLog@1.1098 +1 -0 + [Bug 2113] Warn about ignored extra args in ntpq + + ntpq/ntpq.c@1.144 +36 -29 + [Bug 2113] Warn about ignored extra args in ntpq + +ChangeSet@1.2747, 2012-01-10 06:49:35+00:00, stenn@deacon.udel.edu + NTP_4_2_7P249 + TAG: NTP_4_2_7P249 + + ChangeLog@1.1097 +1 -0 + NTP_4_2_7P249 + + ntpd/ntpd-opts.c@1.254 +3 -3 + NTP_4_2_7P249 + + ntpd/ntpd-opts.h@1.254 +3 -3 + NTP_4_2_7P249 + + ntpd/ntpd-opts.texi@1.252 +2 -2 + NTP_4_2_7P249 + + ntpd/ntpd.1ntpdman@1.65 +2 -2 + NTP_4_2_7P249 + + ntpd/ntpd.1ntpdmdoc@1.65 +2 -2 + NTP_4_2_7P249 + + ntpd/ntpd.man.in@1.65 +2 -2 + NTP_4_2_7P249 + + ntpd/ntpd.mdoc.in@1.65 +2 -2 + NTP_4_2_7P249 + + ntpdc/ntpdc-opts.c@1.249 +3 -3 + NTP_4_2_7P249 + + ntpdc/ntpdc-opts.h@1.249 +3 -3 + NTP_4_2_7P249 + + ntpdc/ntpdc-opts.texi@1.249 +2 -2 + NTP_4_2_7P249 + + ntpdc/ntpdc.1ntpdcman@1.65 +2 -2 + NTP_4_2_7P249 + + ntpdc/ntpdc.1ntpdcmdoc@1.65 +2 -2 + NTP_4_2_7P249 + + ntpdc/ntpdc.html@1.77 +2 -2 + NTP_4_2_7P249 + + ntpdc/ntpdc.man.in@1.65 +2 -2 + NTP_4_2_7P249 + + ntpdc/ntpdc.mdoc.in@1.65 +2 -2 + NTP_4_2_7P249 + + ntpq/ntpq-opts.c@1.251 +3 -3 + NTP_4_2_7P249 + + ntpq/ntpq-opts.h@1.251 +3 -3 + NTP_4_2_7P249 + + ntpq/ntpq-opts.texi@1.251 +2 -2 + NTP_4_2_7P249 + + ntpq/ntpq.1ntpqman@1.65 +2 -2 + NTP_4_2_7P249 + + ntpq/ntpq.1ntpqmdoc@1.65 +2 -2 + NTP_4_2_7P249 + + ntpq/ntpq.man.in@1.65 +2 -2 + NTP_4_2_7P249 + + ntpq/ntpq.mdoc.in@1.65 +2 -2 + NTP_4_2_7P249 + + ntpsnmpd/ntpsnmpd-opts.c@1.251 +3 -3 + NTP_4_2_7P249 + + ntpsnmpd/ntpsnmpd-opts.h@1.251 +3 -3 + NTP_4_2_7P249 + + ntpsnmpd/ntpsnmpd-opts.texi@1.251 +2 -2 + NTP_4_2_7P249 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.65 +2 -2 + NTP_4_2_7P249 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.65 +2 -2 + NTP_4_2_7P249 + + ntpsnmpd/ntpsnmpd.man.in@1.65 +2 -2 + NTP_4_2_7P249 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.65 +2 -2 + NTP_4_2_7P249 + + packageinfo.sh@1.252 +1 -1 + NTP_4_2_7P249 + + scripts/ntp-wait-opts.texi@1.69 +1 -1 + NTP_4_2_7P249 + + scripts/ntp-wait.1ntp-waitman@1.65 +2 -2 + NTP_4_2_7P249 + + scripts/ntp-wait.1ntp-waitmdoc@1.65 +2 -2 + NTP_4_2_7P249 + + scripts/ntp-wait.html@1.69 +1 -1 + NTP_4_2_7P249 + + scripts/ntp-wait.man.in@1.65 +2 -2 + NTP_4_2_7P249 + + scripts/ntp-wait.mdoc.in@1.65 +2 -2 + NTP_4_2_7P249 + + sntp/sntp-opts.c@1.247 +3 -3 + NTP_4_2_7P249 + + sntp/sntp-opts.h@1.247 +3 -3 + NTP_4_2_7P249 + + sntp/sntp-opts.texi@1.247 +2 -2 + NTP_4_2_7P249 + + sntp/sntp.1sntpman@1.67 +2 -2 + NTP_4_2_7P249 + + sntp/sntp.1sntpmdoc@1.67 +2 -2 + NTP_4_2_7P249 + + sntp/sntp.html@1.247 +2 -2 + NTP_4_2_7P249 + + sntp/sntp.man.in@1.67 +2 -2 + NTP_4_2_7P249 + + sntp/sntp.mdoc.in@1.67 +2 -2 + NTP_4_2_7P249 + + util/ntp-keygen-opts.c@1.251 +3 -3 + NTP_4_2_7P249 + + util/ntp-keygen-opts.h@1.251 +3 -3 + NTP_4_2_7P249 + + util/ntp-keygen-opts.texi@1.252 +2 -2 + NTP_4_2_7P249 + + util/ntp-keygen.1ntp-keygenman@1.65 +2 -2 + NTP_4_2_7P249 + + util/ntp-keygen.1ntp-keygenmdoc@1.65 +2 -2 + NTP_4_2_7P249 + + util/ntp-keygen.man.in@1.65 +2 -2 + NTP_4_2_7P249 + + util/ntp-keygen.mdoc.in@1.65 +2 -2 + NTP_4_2_7P249 + +ChangeSet@1.2746, 2012-01-10 05:24:10+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2111] Remove minpoll delay before iburst for pool and + manycastclient. + + ChangeLog@1.1096 +2 -0 + [Bug 2111] Remove minpoll delay before iburst for pool and + manycastclient. + + ntpd/ntp_proto.c@1.339 +30 -46 + [Bug 2111] Remove minpoll delay before iburst for pool and + manycastclient. + +ChangeSet@1.2745, 2012-01-10 04:55:48+00:00, davehart@dlh-7551.ad.hartbrothers.com + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + + ChangeLog@1.1095 +4 -0 + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + + include/ntp.h@1.203 +1 -3 + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + + include/ntp_refclock.h@1.34 +4 -1 + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + + ntpd/ntp_peer.c@1.152 +2 -3 + use TRUE and comment typo + + ntpd/ntp_refclock.c@1.111 +12 -8 + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + + ntpd/ntp_timer.c@1.67 +0 -2 + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + + ntpd/refclock_arc.c@1.29 +3 -3 + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + + ntpd/refclock_parse.c@1.64 +10 -10 + Move refclock-specific scheduled timer code under #ifdef REFCLOCK + and move "action" and "nextaction" data for same from struct peer to + struct refclockproc. These provide a way to schedule a callback some + seconds in the future. + +ChangeSet@1.2744, 2012-01-08 23:14:53+00:00, stenn@deacon.udel.edu + NTP_4_2_7P248 + TAG: NTP_4_2_7P248 + + ChangeLog@1.1094 +1 -0 + NTP_4_2_7P248 + + ntpd/ntpd-opts.c@1.253 +3 -3 + NTP_4_2_7P248 + + ntpd/ntpd-opts.h@1.253 +3 -3 + NTP_4_2_7P248 + + ntpd/ntpd-opts.texi@1.251 +2 -2 + NTP_4_2_7P248 + + ntpd/ntpd.1ntpdman@1.64 +2 -2 + NTP_4_2_7P248 + + ntpd/ntpd.1ntpdmdoc@1.64 +2 -2 + NTP_4_2_7P248 + + ntpd/ntpd.man.in@1.64 +2 -2 + NTP_4_2_7P248 + + ntpd/ntpd.mdoc.in@1.64 +2 -2 + NTP_4_2_7P248 + + ntpdc/ntpdc-opts.c@1.248 +3 -3 + NTP_4_2_7P248 + + ntpdc/ntpdc-opts.h@1.248 +3 -3 + NTP_4_2_7P248 + + ntpdc/ntpdc-opts.texi@1.248 +2 -2 + NTP_4_2_7P248 + + ntpdc/ntpdc.1ntpdcman@1.64 +2 -2 + NTP_4_2_7P248 + + ntpdc/ntpdc.1ntpdcmdoc@1.64 +2 -2 + NTP_4_2_7P248 + + ntpdc/ntpdc.html@1.76 +2 -2 + NTP_4_2_7P248 + + ntpdc/ntpdc.man.in@1.64 +2 -2 + NTP_4_2_7P248 + + ntpdc/ntpdc.mdoc.in@1.64 +2 -2 + NTP_4_2_7P248 + + ntpq/ntpq-opts.c@1.250 +3 -3 + NTP_4_2_7P248 + + ntpq/ntpq-opts.h@1.250 +3 -3 + NTP_4_2_7P248 + + ntpq/ntpq-opts.texi@1.250 +2 -2 + NTP_4_2_7P248 + + ntpq/ntpq.1ntpqman@1.64 +2 -2 + NTP_4_2_7P248 + + ntpq/ntpq.1ntpqmdoc@1.64 +2 -2 + NTP_4_2_7P248 + + ntpq/ntpq.man.in@1.64 +2 -2 + NTP_4_2_7P248 + + ntpq/ntpq.mdoc.in@1.64 +2 -2 + NTP_4_2_7P248 + + ntpsnmpd/ntpsnmpd-opts.c@1.250 +3 -3 + NTP_4_2_7P248 + + ntpsnmpd/ntpsnmpd-opts.h@1.250 +3 -3 + NTP_4_2_7P248 + + ntpsnmpd/ntpsnmpd-opts.texi@1.250 +2 -2 + NTP_4_2_7P248 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.64 +2 -2 + NTP_4_2_7P248 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.64 +2 -2 + NTP_4_2_7P248 + + ntpsnmpd/ntpsnmpd.man.in@1.64 +2 -2 + NTP_4_2_7P248 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.64 +2 -2 + NTP_4_2_7P248 + + packageinfo.sh@1.251 +1 -1 + NTP_4_2_7P248 + + scripts/ntp-wait-opts.texi@1.68 +1 -1 + NTP_4_2_7P248 + + scripts/ntp-wait.1ntp-waitman@1.64 +2 -2 + NTP_4_2_7P248 + + scripts/ntp-wait.1ntp-waitmdoc@1.64 +2 -2 + NTP_4_2_7P248 + + scripts/ntp-wait.html@1.68 +1 -1 + NTP_4_2_7P248 + + scripts/ntp-wait.man.in@1.64 +2 -2 + NTP_4_2_7P248 + + scripts/ntp-wait.mdoc.in@1.64 +2 -2 + NTP_4_2_7P248 + + sntp/sntp-opts.c@1.246 +3 -3 + NTP_4_2_7P248 + + sntp/sntp-opts.h@1.246 +3 -3 + NTP_4_2_7P248 + + sntp/sntp-opts.texi@1.246 +2 -2 + NTP_4_2_7P248 + + sntp/sntp.1sntpman@1.66 +2 -2 + NTP_4_2_7P248 + + sntp/sntp.1sntpmdoc@1.66 +2 -2 + NTP_4_2_7P248 + + sntp/sntp.html@1.246 +2 -2 + NTP_4_2_7P248 + + sntp/sntp.man.in@1.66 +2 -2 + NTP_4_2_7P248 + + sntp/sntp.mdoc.in@1.66 +2 -2 + NTP_4_2_7P248 + + util/ntp-keygen-opts.c@1.250 +3 -3 + NTP_4_2_7P248 + + util/ntp-keygen-opts.h@1.250 +3 -3 + NTP_4_2_7P248 + + util/ntp-keygen-opts.texi@1.251 +2 -2 + NTP_4_2_7P248 + + util/ntp-keygen.1ntp-keygenman@1.64 +2 -2 + NTP_4_2_7P248 + + util/ntp-keygen.1ntp-keygenmdoc@1.64 +2 -2 + NTP_4_2_7P248 + + util/ntp-keygen.man.in@1.64 +2 -2 + NTP_4_2_7P248 + + util/ntp-keygen.mdoc.in@1.64 +2 -2 + NTP_4_2_7P248 + +ChangeSet@1.2743, 2012-01-08 12:02:32+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2109] "make clean check" is broken with gtest available. + [Bug 2110] systime.c typo breaks build on microsecond clocks. + Use $(MAKE) $(AM_MAKEFLAGS) for submakes. + + ChangeLog@1.1093 +2 -0 + [Bug 2109] "make clean check" is broken with gtest available. + [Bug 2110] systime.c typo breaks build on microsecond clocks. + + Makefile.am@1.115 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + check-libopts.mf@1.2 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + depsver.mf@1.4 +2 -2 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + libntp/systime.c@1.63 +1 -1 + [Bug 2110] systime.c typo breaks build on microsecond clocks. + + ntpd/Makefile.am@1.112 +4 -4 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + ntpdate/Makefile.am@1.33 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + ntpdc/Makefile.am@1.69 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + ntpq/Makefile.am@1.65 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + sntp/Makefile.am@1.70 +31 -24 + [Bug 2109] "make clean check" is broken with gtest available. + + sntp/check-libntp.mf@1.2 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + sntp/check-libopts.mf@1.2 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + sntp/include/Makefile.am@1.5 +2 -2 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + sntp/main.c@1.81 +3 -3 + Pass version string to sntp_main() as arg instead of global to remove main.o dependency on version.o for libsntp.a. + + sntp/main.h@1.7 +1 -1 + Pass version string to sntp_main() as arg instead of global to remove main.o dependency on version.o for libsntp.a. + + sntp/sntp.c@1.4 +1 -1 + Pass version string to sntp_main() as arg instead of global to remove main.o dependency on version.o for libsntp.a. + + sntp/tests/Makefile.am@1.26 +13 -15 + [Bug 2109] "make clean check" is broken with gtest available. + + sntp/tests/utilities.cpp@1.8 +1 -0 + Provide stub Version string for libntp.a/ntp_libopts.o + + tests/libntp/Makefile.am@1.38 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + + util/Makefile.am@1.68 +1 -1 + use $(MAKE) $(AM_MAKEFLAGS) for submakes + +ChangeSet@1.2742, 2012-01-07 01:05:31+00:00, stenn@deacon.udel.edu + NTP_4_2_7P247 + TAG: NTP_4_2_7P247 + + ChangeLog@1.1092 +1 -0 + NTP_4_2_7P247 + + ntpd/ntpd-opts.c@1.252 +3 -3 + NTP_4_2_7P247 + + ntpd/ntpd-opts.h@1.252 +3 -3 + NTP_4_2_7P247 + + ntpd/ntpd-opts.texi@1.250 +2 -2 + NTP_4_2_7P247 + + ntpd/ntpd.1ntpdman@1.63 +2 -2 + NTP_4_2_7P247 + + ntpd/ntpd.1ntpdmdoc@1.63 +1 -1 + NTP_4_2_7P247 + + ntpd/ntpd.man.in@1.63 +2 -2 + NTP_4_2_7P247 + + ntpd/ntpd.mdoc.in@1.63 +1 -1 + NTP_4_2_7P247 + + ntpdc/ntpdc-opts.c@1.247 +3 -3 + NTP_4_2_7P247 + + ntpdc/ntpdc-opts.h@1.247 +3 -3 + NTP_4_2_7P247 + + ntpdc/ntpdc-opts.texi@1.247 +2 -2 + NTP_4_2_7P247 + + ntpdc/ntpdc.1ntpdcman@1.63 +2 -2 + NTP_4_2_7P247 + + ntpdc/ntpdc.1ntpdcmdoc@1.63 +1 -1 + NTP_4_2_7P247 + + ntpdc/ntpdc.html@1.75 +2 -2 + NTP_4_2_7P247 + + ntpdc/ntpdc.man.in@1.63 +2 -2 + NTP_4_2_7P247 + + ntpdc/ntpdc.mdoc.in@1.63 +1 -1 + NTP_4_2_7P247 + + ntpq/ntpq-opts.c@1.249 +3 -3 + NTP_4_2_7P247 + + ntpq/ntpq-opts.h@1.249 +3 -3 + NTP_4_2_7P247 + + ntpq/ntpq-opts.texi@1.249 +2 -2 + NTP_4_2_7P247 + + ntpq/ntpq.1ntpqman@1.63 +2 -2 + NTP_4_2_7P247 + + ntpq/ntpq.1ntpqmdoc@1.63 +1 -1 + NTP_4_2_7P247 + + ntpq/ntpq.man.in@1.63 +2 -2 + NTP_4_2_7P247 + + ntpq/ntpq.mdoc.in@1.63 +1 -1 + NTP_4_2_7P247 + + ntpsnmpd/ntpsnmpd-opts.c@1.249 +3 -3 + NTP_4_2_7P247 + + ntpsnmpd/ntpsnmpd-opts.h@1.249 +3 -3 + NTP_4_2_7P247 + + ntpsnmpd/ntpsnmpd-opts.texi@1.249 +2 -2 + NTP_4_2_7P247 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.63 +2 -2 + NTP_4_2_7P247 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.63 +1 -1 + NTP_4_2_7P247 + + ntpsnmpd/ntpsnmpd.man.in@1.63 +2 -2 + NTP_4_2_7P247 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.63 +1 -1 + NTP_4_2_7P247 + + packageinfo.sh@1.250 +1 -1 + NTP_4_2_7P247 + + scripts/ntp-wait-opts.texi@1.67 +1 -1 + NTP_4_2_7P247 + + scripts/ntp-wait.1ntp-waitman@1.63 +2 -2 + NTP_4_2_7P247 + + scripts/ntp-wait.1ntp-waitmdoc@1.63 +1 -1 + NTP_4_2_7P247 + + scripts/ntp-wait.html@1.67 +1 -1 + NTP_4_2_7P247 + + scripts/ntp-wait.man.in@1.63 +2 -2 + NTP_4_2_7P247 + + scripts/ntp-wait.mdoc.in@1.63 +1 -1 + NTP_4_2_7P247 + + sntp/sntp-opts.c@1.245 +3 -3 + NTP_4_2_7P247 + + sntp/sntp-opts.h@1.245 +3 -3 + NTP_4_2_7P247 + + sntp/sntp-opts.texi@1.245 +2 -2 + NTP_4_2_7P247 + + sntp/sntp.1sntpman@1.65 +2 -2 + NTP_4_2_7P247 + + sntp/sntp.1sntpmdoc@1.65 +1 -1 + NTP_4_2_7P247 + + sntp/sntp.html@1.245 +2 -2 + NTP_4_2_7P247 + + sntp/sntp.man.in@1.65 +2 -2 + NTP_4_2_7P247 + + sntp/sntp.mdoc.in@1.65 +1 -1 + NTP_4_2_7P247 + + util/ntp-keygen-opts.c@1.249 +3 -3 + NTP_4_2_7P247 + + util/ntp-keygen-opts.h@1.249 +3 -3 + NTP_4_2_7P247 + + util/ntp-keygen-opts.texi@1.250 +2 -2 + NTP_4_2_7P247 + + util/ntp-keygen.1ntp-keygenman@1.63 +2 -2 + NTP_4_2_7P247 + + util/ntp-keygen.1ntp-keygenmdoc@1.63 +1 -1 + NTP_4_2_7P247 + + util/ntp-keygen.man.in@1.63 +2 -2 + NTP_4_2_7P247 + + util/ntp-keygen.mdoc.in@1.63 +1 -1 + NTP_4_2_7P247 + +ChangeSet@1.2741, 2012-01-06 20:05:11-05:00, stenn@deacon.udel.edu + cleanup + + libntp/Makefile.am@1.66 +2 -2 + cleanup + +ChangeSet@1.2740, 2012-01-06 18:38:02-05:00, stenn@deacon.udel.edu + tolerate an error touching a file in a read-only srcdir + + libntp/Makefile.am@1.65 +1 -1 + tolerate an error touching a file in a read-only srcdir + +ChangeSet@1.2739, 2012-01-06 22:31:21+00:00, davehart@dlh-7551.ad.hartbrothers.com + Fix build break triggered by updating deps-ver and libntp/systime.c at + the same time by explicitly depending systime_s.c on systime.c. + + ChangeLog@1.1091 +2 -0 + Fix build break triggered by updating deps-ver and libntp/systime.c at + the same time by explicitly depending systime_s.c on systime.c. + + libntp/Makefile.am@1.64 +8 -0 + Fix build break triggered by updating deps-ver and libntp/systime.c at + the same time by explicitly depending systime_s.c on systime.c. + +ChangeSet@1.2738, 2012-01-06 22:04:11+00:00, stenn@deacon.udel.edu + NTP_4_2_7P246 + TAG: NTP_4_2_7P246 + + ChangeLog@1.1090 +1 -0 + NTP_4_2_7P246 + + ntpd/ntpd-opts.c@1.251 +3 -3 + NTP_4_2_7P246 + + ntpd/ntpd-opts.h@1.251 +3 -3 + NTP_4_2_7P246 + + ntpd/ntpd-opts.texi@1.249 +2 -2 + NTP_4_2_7P246 + + ntpd/ntpd.1ntpdman@1.62 +2 -2 + NTP_4_2_7P246 + + ntpd/ntpd.1ntpdmdoc@1.62 +2 -2 + NTP_4_2_7P246 + + ntpd/ntpd.man.in@1.62 +2 -2 + NTP_4_2_7P246 + + ntpd/ntpd.mdoc.in@1.62 +2 -2 + NTP_4_2_7P246 + + ntpdc/ntpdc-opts.c@1.246 +3 -3 + NTP_4_2_7P246 + + ntpdc/ntpdc-opts.h@1.246 +3 -3 + NTP_4_2_7P246 + + ntpdc/ntpdc-opts.texi@1.246 +2 -2 + NTP_4_2_7P246 + + ntpdc/ntpdc.1ntpdcman@1.62 +2 -2 + NTP_4_2_7P246 + + ntpdc/ntpdc.1ntpdcmdoc@1.62 +2 -2 + NTP_4_2_7P246 + + ntpdc/ntpdc.html@1.74 +2 -2 + NTP_4_2_7P246 + + ntpdc/ntpdc.man.in@1.62 +2 -2 + NTP_4_2_7P246 + + ntpdc/ntpdc.mdoc.in@1.62 +2 -2 + NTP_4_2_7P246 + + ntpq/ntpq-opts.c@1.248 +3 -3 + NTP_4_2_7P246 + + ntpq/ntpq-opts.h@1.248 +3 -3 + NTP_4_2_7P246 + + ntpq/ntpq-opts.texi@1.248 +2 -2 + NTP_4_2_7P246 + + ntpq/ntpq.1ntpqman@1.62 +2 -2 + NTP_4_2_7P246 + + ntpq/ntpq.1ntpqmdoc@1.62 +2 -2 + NTP_4_2_7P246 + + ntpq/ntpq.man.in@1.62 +2 -2 + NTP_4_2_7P246 + + ntpq/ntpq.mdoc.in@1.62 +2 -2 + NTP_4_2_7P246 + + ntpsnmpd/ntpsnmpd-opts.c@1.248 +3 -3 + NTP_4_2_7P246 + + ntpsnmpd/ntpsnmpd-opts.h@1.248 +3 -3 + NTP_4_2_7P246 + + ntpsnmpd/ntpsnmpd-opts.texi@1.248 +2 -2 + NTP_4_2_7P246 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.62 +2 -2 + NTP_4_2_7P246 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.62 +2 -2 + NTP_4_2_7P246 + + ntpsnmpd/ntpsnmpd.man.in@1.62 +2 -2 + NTP_4_2_7P246 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.62 +2 -2 + NTP_4_2_7P246 + + packageinfo.sh@1.249 +1 -1 + NTP_4_2_7P246 + + scripts/ntp-wait-opts.texi@1.66 +1 -1 + NTP_4_2_7P246 + + scripts/ntp-wait.1ntp-waitman@1.62 +2 -2 + NTP_4_2_7P246 + + scripts/ntp-wait.1ntp-waitmdoc@1.62 +2 -2 + NTP_4_2_7P246 + + scripts/ntp-wait.html@1.66 +1 -1 + NTP_4_2_7P246 + + scripts/ntp-wait.man.in@1.62 +2 -2 + NTP_4_2_7P246 + + scripts/ntp-wait.mdoc.in@1.62 +2 -2 + NTP_4_2_7P246 + + sntp/sntp-opts.c@1.244 +3 -3 + NTP_4_2_7P246 + + sntp/sntp-opts.h@1.244 +3 -3 + NTP_4_2_7P246 + + sntp/sntp-opts.texi@1.244 +2 -2 + NTP_4_2_7P246 + + sntp/sntp.1sntpman@1.64 +2 -2 + NTP_4_2_7P246 + + sntp/sntp.1sntpmdoc@1.64 +2 -2 + NTP_4_2_7P246 + + sntp/sntp.html@1.244 +2 -2 + NTP_4_2_7P246 + + sntp/sntp.man.in@1.64 +2 -2 + NTP_4_2_7P246 + + sntp/sntp.mdoc.in@1.64 +2 -2 + NTP_4_2_7P246 + + util/ntp-keygen-opts.c@1.248 +3 -3 + NTP_4_2_7P246 + + util/ntp-keygen-opts.h@1.248 +3 -3 + NTP_4_2_7P246 + + util/ntp-keygen-opts.texi@1.249 +2 -2 + NTP_4_2_7P246 + + util/ntp-keygen.1ntp-keygenman@1.62 +2 -2 + NTP_4_2_7P246 + + util/ntp-keygen.1ntp-keygenmdoc@1.62 +2 -2 + NTP_4_2_7P246 + + util/ntp-keygen.man.in@1.62 +2 -2 + NTP_4_2_7P246 + + util/ntp-keygen.mdoc.in@1.62 +2 -2 + NTP_4_2_7P246 + +ChangeSet@1.2732.1.1, 2012-01-05 19:29:42+00:00, davehart@dlh-7551.ad.hartbrothers.com + [Bug 2104] ntpdc fault with oversize -c command. + [Bug 2106] Fix warnings when using -Wformat-security. + Refactor timespecops.h and timevalops.h into inline functions. + + BitKeeper/deleted/0e/fptoa.c~3e480692@1.5 +0 -0 + Rename: libntp/fptoa.c -> BitKeeper/deleted/0e/fptoa.c~3e480692 + + BitKeeper/deleted/22/mfptoa.c~3e480692@1.5 +0 -0 + Rename: libntp/mfptoa.c -> BitKeeper/deleted/22/mfptoa.c~3e480692 + + BitKeeper/deleted/40/tsftomsu.c~3e480692@1.5 +0 -0 + Rename: libntp/tsftomsu.c -> BitKeeper/deleted/40/tsftomsu.c~3e480692 + + BitKeeper/deleted/6d/mfptoms.c~3e480692@1.5 +0 -0 + Rename: libntp/mfptoms.c -> BitKeeper/deleted/6d/mfptoms.c~3e480692 + + BitKeeper/deleted/84/tvtots.c~3e480692@1.5 +0 -0 + Rename: libntp/tvtots.c -> BitKeeper/deleted/84/tvtots.c~3e480692 + + BitKeeper/deleted/b0/tstotv.c~3e480692@1.5 +0 -0 + Rename: libntp/tstotv.c -> BitKeeper/deleted/b0/tstotv.c~3e480692 + + BitKeeper/deleted/b2/msutotsf.c~3e480692@1.5 +0 -0 + Rename: libntp/msutotsf.c -> BitKeeper/deleted/b2/msutotsf.c~3e480692 + + BitKeeper/deleted/b2/timespecops.c~89e74bdf8b9e22c4@1.8.1.1 +0 -0 + Rename: libntp/timespecops.c -> BitKeeper/deleted/b2/timespecops.c~89e74bdf8b9e22c4 + + BitKeeper/deleted/ed/tsftomsu.cpp~5ef492abb78ec38b@1.2 +0 -0 + Rename: tests/libntp/tsftomsu.cpp -> BitKeeper/deleted/ed/tsftomsu.cpp~5ef492abb78ec38b + + BitKeeper/deleted/f5/fptoms.c~3e480692@1.5 +0 -0 + Rename: libntp/fptoms.c -> BitKeeper/deleted/f5/fptoms.c~3e480692 + + BitKeeper/etc/ignore@1.84 +1 -0 + added ports/winnt/vs2008/ntp.suo + + ChangeLog@1.1085.1.1 +3 -0 + [Bug 2104] ntpdc fault with oversize -c command. + [Bug 2106] Fix warnings when using -Wformat-security. + Refactor timespecops.h and timevalops.h into inline functions. + + deps-ver@1.6 +1 -1 + No longer building some libntp source files can trigger breakage via + stale Makefiles including nonexistent .deps/*.Po files. Bumping + deps-ver cleans older .deps dirs to cure the problem. + + depsver.mf@1.3 +3 -10 + Support tests/libntp use of depsver.mf by removing requirement that + consuming Makefile.am files be no deeper than one subdirectory from + the top $srcdir. + + include/ntp_fp.h@1.28 +83 -59 + remove lfp.l_f signed fraction, which has little legit use. + remove unused fraction argument from M_ISNEG(). + style cleanup. + + include/ntp_stdlib.h@1.70 +3 -3 + use u_int32 not u_long for mfpto*() l_fp halves + + include/ntp_types.h@1.31 +9 -0 + provide NONEMPTY_TRANSLATION_UNIT macro for conditionally-compiled files. + + include/ntp_unixtime.h@1.13 +1 -98 + consolidate timeval conversion in timevalops.[ch] + + include/timespecops.h@1.5 +295 -46 + experiment with two levels of inlining timespecops/timevalops + + include/timevalops.h@1.4 +369 -38 + experiment with two levels of inlining timespecops/timevalops + + lib/isc/include/isc/util.h@1.6 +1 -1 + suppress "defined but not used" warning re: nonempty_translation_unit. + + lib/isc/unix/ifiter_sysctl.c@1.17 +5 -4 + [Bug 2106] Fix warnings when using -Wformat-security. + + libntp/Makefile.am@1.63 +0 -9 + consolidate several single-function source files + + libntp/buftvtots.c@1.6 +7 -22 + consolidate timeval conversion in timevalops.[ch] + + libntp/dofptoa.c@1.9 +40 -0 + consolidate several single-function source files + + libntp/dolfptoa.c@1.11 +42 -3 + consolidate several single-function source files + + libntp/ntp_calendar.c@1.10 +1 -1 + remove unused M_ISNEG() fraction argument + + libntp/systime.c@1.62 +34 -48 + Refine recent get_systime() fuzzing changes on non-interpolated clocks. + Conditionalize less iin get_systime() so measure_precision() sees + performance while calibrating which is closer to get_systime() use + later. Instead of comparing two doubles to decide if the rarely- + used simulation of a low-precision clock is configured via "tinker + tick", use a Bool-like int trunc_os_clock. + + libntp/timevalops.c@1.7.1.1 +278 -347 + refactor time*ops.h with renamed inline functions + + libntp/work_thread.c@1.12 +1 -1 + experiment with two levels of inlining timespecops/timevalops + + libparse/clk_trimtsip.c@1.11 +1 -1 + move timeval fraction macros to timevalops.h + + libparse/parse.c@1.15 +1 -1 + move timeval fraction macros to timevalops.h + + ntpd/ntp_io.c@1.365 +3 -3 + include timevalops.h explicitly + + ntpd/ntp_proto.c@1.338 +41 -22 + Minor refinement of prior precision and fuzz determination changes. + + ntpd/ntp_request.c@1.109 +1 -1 + remove l_fp.l_f signed fraction + + ntpd/refclock_arc.c@1.28 +4 -2 + remove l_fp.l_f signed fraction + + ntpd/refclock_chu.c@1.53 +4 -2 + remove l_fp.l_f signed fraction + + ntpd/refclock_datum.c@1.20 +4 -2 + move timeval fraction macros to timevalops.h + + ntpd/refclock_leitch.c@1.15 +4 -2 + move milllisecond/l_fp conversion macro to timevalops.h + + ntpd/refclock_msfees.c@1.16 +7 -6 + use tval_stamp_to_lfp() rather than buftvtots() + + ntpd/refclock_nmea.c@1.65 +5 -3 + refactor time*ops.h with renamed inline functions + + ntpd/refclock_parse.c@1.63 +15 -34 + use tval_stamp_to_lfp() rather than buftvtots(). + remove l_fp.l_f signed fraction. + + ntpd/refclock_shm.c@1.23 +7 -5 + move timeval fraction macros to timevalops.h + + ntpdate/ntpdate.c@1.90 +1 -1 + move timeval fraction macros to timevalops.h + + ntpdc/ntpdc.c@1.98 +5 -0 + [Bug 2104] ntpdc fault with oversize -c command. + + ports/winnt/include/termios.h@1.15 +1 -0 + add overlooked tcflush() prototype referenced by refclock_parse.c + + ports/winnt/vs2005/libntp.vcproj@1.21 +0 -36 + consolidate several single-function source files + + ports/winnt/vs2008/libntp/libntp.vcproj@1.44 +2 -38 + consolidate several single-function source files + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.42 +8 -0 + add timespecops.h and timevalops.h references + + sntp/main.c@1.80 +4 -4 + refactor time*ops.h with renamed inline functions + + tests/libntp/Makefile.am@1.37 +0 -1 + remove tsftomsu.cpp as tested code was unused and removed. + + tests/libntp/lfptostr.cpp@1.3 +2 -2 + remove l_fp.l_f signed fraction + + tests/libntp/strtolfp.cpp@1.9 +1 -1 + remove l_fp.l_f signed fraction + + tests/libntp/timespecops.cpp@1.6.1.1 +260 -144 + refactor time*ops.h with renamed inline functions (thanks to Juergen + for helping refactor the tests). + + tests/libntp/timestructs.cpp@1.1.1.1 +36 -7 + refactor time*ops.h with renamed inline functions + + tests/libntp/timestructs.h@1.1.1.1 +28 -2 + Cherry-picked from Juergen's [Bug 2100] fix + + tests/libntp/timevalops.cpp@1.6.1.1 +140 -59 + experiment with two levels of inlining timespecops/timevalops + + tests/libntp/tstotv.cpp@1.2 +1 -1 + move timeval fraction macros to timevalops.h + + tests/libntp/tvtots.cpp@1.6 +1 -1 + move timeval fraction macros to timevalops.h + + util/ntp-keygen.c@1.89 +1 -1 + Resolve MAXFILENAME redefinition warning. + + util/ntptime.c@1.24 +8 -1 + move timeval fraction macros to timevalops.h + +ChangeSet@1.2736, 2011-12-31 11:27:35+00:00, stenn@deacon.udel.edu + NTP_4_2_7P245 + TAG: NTP_4_2_7P245 + + ChangeLog@1.1088 +1 -0 + NTP_4_2_7P245 + + ntpd/ntpd-opts.c@1.250 +3 -3 + NTP_4_2_7P245 + + ntpd/ntpd-opts.h@1.250 +3 -3 + NTP_4_2_7P245 + + ntpd/ntpd-opts.texi@1.248 +2 -2 + NTP_4_2_7P245 + + ntpd/ntpd.1ntpdman@1.61 +2 -2 + NTP_4_2_7P245 + + ntpd/ntpd.1ntpdmdoc@1.61 +2 -2 + NTP_4_2_7P245 + + ntpd/ntpd.man.in@1.61 +2 -2 + NTP_4_2_7P245 + + ntpd/ntpd.mdoc.in@1.61 +2 -2 + NTP_4_2_7P245 + + ntpdc/ntpdc-opts.c@1.245 +3 -3 + NTP_4_2_7P245 + + ntpdc/ntpdc-opts.h@1.245 +3 -3 + NTP_4_2_7P245 + + ntpdc/ntpdc-opts.texi@1.245 +2 -2 + NTP_4_2_7P245 + + ntpdc/ntpdc.1ntpdcman@1.61 +2 -2 + NTP_4_2_7P245 + + ntpdc/ntpdc.1ntpdcmdoc@1.61 +2 -2 + NTP_4_2_7P245 + + ntpdc/ntpdc.html@1.73 +2 -2 + NTP_4_2_7P245 + + ntpdc/ntpdc.man.in@1.61 +2 -2 + NTP_4_2_7P245 + + ntpdc/ntpdc.mdoc.in@1.61 +2 -2 + NTP_4_2_7P245 + + ntpq/ntpq-opts.c@1.247 +3 -3 + NTP_4_2_7P245 + + ntpq/ntpq-opts.h@1.247 +3 -3 + NTP_4_2_7P245 + + ntpq/ntpq-opts.texi@1.247 +2 -2 + NTP_4_2_7P245 + + ntpq/ntpq.1ntpqman@1.61 +2 -2 + NTP_4_2_7P245 + + ntpq/ntpq.1ntpqmdoc@1.61 +2 -2 + NTP_4_2_7P245 + + ntpq/ntpq.man.in@1.61 +2 -2 + NTP_4_2_7P245 + + ntpq/ntpq.mdoc.in@1.61 +2 -2 + NTP_4_2_7P245 + + ntpsnmpd/ntpsnmpd-opts.c@1.247 +3 -3 + NTP_4_2_7P245 + + ntpsnmpd/ntpsnmpd-opts.h@1.247 +3 -3 + NTP_4_2_7P245 + + ntpsnmpd/ntpsnmpd-opts.texi@1.247 +2 -2 + NTP_4_2_7P245 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.61 +2 -2 + NTP_4_2_7P245 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.61 +2 -2 + NTP_4_2_7P245 + + ntpsnmpd/ntpsnmpd.man.in@1.61 +2 -2 + NTP_4_2_7P245 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.61 +2 -2 + NTP_4_2_7P245 + + packageinfo.sh@1.248 +1 -1 + NTP_4_2_7P245 + + scripts/ntp-wait-opts.texi@1.65 +1 -1 + NTP_4_2_7P245 + + scripts/ntp-wait.1ntp-waitman@1.61 +2 -2 + NTP_4_2_7P245 + + scripts/ntp-wait.1ntp-waitmdoc@1.61 +2 -2 + NTP_4_2_7P245 + + scripts/ntp-wait.html@1.65 +1 -1 + NTP_4_2_7P245 + + scripts/ntp-wait.man.in@1.61 +2 -2 + NTP_4_2_7P245 + + scripts/ntp-wait.mdoc.in@1.61 +2 -2 + NTP_4_2_7P245 + + sntp/sntp-opts.c@1.243 +3 -3 + NTP_4_2_7P245 + + sntp/sntp-opts.h@1.243 +3 -3 + NTP_4_2_7P245 + + sntp/sntp-opts.texi@1.243 +2 -2 + NTP_4_2_7P245 + + sntp/sntp.1sntpman@1.63 +2 -2 + NTP_4_2_7P245 + + sntp/sntp.1sntpmdoc@1.63 +2 -2 + NTP_4_2_7P245 + + sntp/sntp.html@1.243 +2 -2 + NTP_4_2_7P245 + + sntp/sntp.man.in@1.63 +2 -2 + NTP_4_2_7P245 + + sntp/sntp.mdoc.in@1.63 +2 -2 + NTP_4_2_7P245 + + util/ntp-keygen-opts.c@1.247 +3 -3 + NTP_4_2_7P245 + + util/ntp-keygen-opts.h@1.247 +3 -3 + NTP_4_2_7P245 + + util/ntp-keygen-opts.texi@1.248 +2 -2 + NTP_4_2_7P245 + + util/ntp-keygen.1ntp-keygenman@1.61 +2 -2 + NTP_4_2_7P245 + + util/ntp-keygen.1ntp-keygenmdoc@1.61 +2 -2 + NTP_4_2_7P245 + + util/ntp-keygen.man.in@1.61 +2 -2 + NTP_4_2_7P245 + + util/ntp-keygen.mdoc.in@1.61 +2 -2 + NTP_4_2_7P245 + +ChangeSet@1.2735, 2011-12-30 21:10:00-05:00, stenn@deacon.udel.edu + typo + + ChangeLog@1.1087 +3 -2 + typo + +ChangeSet@1.2734, 2011-12-30 12:17:49+01:00, jnperlin@hydra.localnet + [Bug2100] conversion timespec/timeval <--> l_fp fixed + + ChangeLog@1.1086 +2 -0 + [Bug2100] conversion timespec/timeval <--> l_fp fixed + + libntp/timespecops.c@1.9 +2 -2 + [Bug2100] conversion l_fp --> timespec fixed + + libntp/timevalops.c@1.8 +2 -2 + [Bug2100] conversion lfp --> timeval fixed + +ChangeSet@1.2733, 2011-12-30 12:12:49+01:00, jnperlin@hydra.localnet + add test cases to reveal bug#2100 + cleanup of test code + + tests/libntp/timespecops.cpp@1.7 +229 -130 + add test cases to reveal bug#2100 + synchronise test cases & coding between timeval <--> timespec + + tests/libntp/timestructs.cpp@1.2 +34 -1 + use 'lfptoa' for printing l_fp values + timespec closeness predicate implementation + + tests/libntp/timestructs.h@1.2 +27 -0 + added copy C'TORs to timespec/timeval wrappers, + added a timespec closeness predicate class + + tests/libntp/timevalops.cpp@1.7 +109 -45 + add test cases to reveal bug#2100 + synchronise test cases & coding between timeval <--> timespec + +ChangeSet@1.2732, 2011-12-25 11:32:25+00:00, stenn@deacon.udel.edu + NTP_4_2_7P244 + TAG: NTP_4_2_7P244 + + ChangeLog@1.1085 +1 -0 + NTP_4_2_7P244 + + ntpd/ntpd-opts.c@1.249 +3 -3 + NTP_4_2_7P244 + + ntpd/ntpd-opts.h@1.249 +3 -3 + NTP_4_2_7P244 + + ntpd/ntpd-opts.texi@1.247 +2 -2 + NTP_4_2_7P244 + + ntpd/ntpd.1ntpdman@1.60 +2 -2 + NTP_4_2_7P244 + + ntpd/ntpd.1ntpdmdoc@1.60 +2 -2 + NTP_4_2_7P244 + + ntpd/ntpd.man.in@1.60 +2 -2 + NTP_4_2_7P244 + + ntpd/ntpd.mdoc.in@1.60 +2 -2 + NTP_4_2_7P244 + + ntpdc/ntpdc-opts.c@1.244 +3 -3 + NTP_4_2_7P244 + + ntpdc/ntpdc-opts.h@1.244 +3 -3 + NTP_4_2_7P244 + + ntpdc/ntpdc-opts.texi@1.244 +2 -2 + NTP_4_2_7P244 + + ntpdc/ntpdc.1ntpdcman@1.60 +2 -2 + NTP_4_2_7P244 + + ntpdc/ntpdc.1ntpdcmdoc@1.60 +2 -2 + NTP_4_2_7P244 + + ntpdc/ntpdc.html@1.72 +2 -2 + NTP_4_2_7P244 + + ntpdc/ntpdc.man.in@1.60 +2 -2 + NTP_4_2_7P244 + + ntpdc/ntpdc.mdoc.in@1.60 +2 -2 + NTP_4_2_7P244 + + ntpq/ntpq-opts.c@1.246 +3 -3 + NTP_4_2_7P244 + + ntpq/ntpq-opts.h@1.246 +3 -3 + NTP_4_2_7P244 + + ntpq/ntpq-opts.texi@1.246 +2 -2 + NTP_4_2_7P244 + + ntpq/ntpq.1ntpqman@1.60 +2 -2 + NTP_4_2_7P244 + + ntpq/ntpq.1ntpqmdoc@1.60 +2 -2 + NTP_4_2_7P244 + + ntpq/ntpq.man.in@1.60 +2 -2 + NTP_4_2_7P244 + + ntpq/ntpq.mdoc.in@1.60 +2 -2 + NTP_4_2_7P244 + + ntpsnmpd/ntpsnmpd-opts.c@1.246 +3 -3 + NTP_4_2_7P244 + + ntpsnmpd/ntpsnmpd-opts.h@1.246 +3 -3 + NTP_4_2_7P244 + + ntpsnmpd/ntpsnmpd-opts.texi@1.246 +2 -2 + NTP_4_2_7P244 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.60 +2 -2 + NTP_4_2_7P244 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.60 +2 -2 + NTP_4_2_7P244 + + ntpsnmpd/ntpsnmpd.man.in@1.60 +2 -2 + NTP_4_2_7P244 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.60 +2 -2 + NTP_4_2_7P244 + + packageinfo.sh@1.247 +1 -1 + NTP_4_2_7P244 + + scripts/ntp-wait-opts.texi@1.64 +1 -1 + NTP_4_2_7P244 + + scripts/ntp-wait.1ntp-waitman@1.60 +2 -2 + NTP_4_2_7P244 + + scripts/ntp-wait.1ntp-waitmdoc@1.60 +2 -2 + NTP_4_2_7P244 + + scripts/ntp-wait.html@1.64 +1 -1 + NTP_4_2_7P244 + + scripts/ntp-wait.man.in@1.60 +2 -2 + NTP_4_2_7P244 + + scripts/ntp-wait.mdoc.in@1.60 +2 -2 + NTP_4_2_7P244 + + sntp/sntp-opts.c@1.242 +3 -3 + NTP_4_2_7P244 + + sntp/sntp-opts.h@1.242 +3 -3 + NTP_4_2_7P244 + + sntp/sntp-opts.texi@1.242 +2 -2 + NTP_4_2_7P244 + + sntp/sntp.1sntpman@1.62 +2 -2 + NTP_4_2_7P244 + + sntp/sntp.1sntpmdoc@1.62 +2 -2 + NTP_4_2_7P244 + + sntp/sntp.html@1.242 +2 -2 + NTP_4_2_7P244 + + sntp/sntp.man.in@1.62 +2 -2 + NTP_4_2_7P244 + + sntp/sntp.mdoc.in@1.62 +2 -2 + NTP_4_2_7P244 + + util/ntp-keygen-opts.c@1.246 +3 -3 + NTP_4_2_7P244 + + util/ntp-keygen-opts.h@1.246 +3 -3 + NTP_4_2_7P244 + + util/ntp-keygen-opts.texi@1.247 +2 -2 + NTP_4_2_7P244 + + util/ntp-keygen.1ntp-keygenman@1.60 +2 -2 + NTP_4_2_7P244 + + util/ntp-keygen.1ntp-keygenmdoc@1.60 +2 -2 + NTP_4_2_7P244 + + util/ntp-keygen.man.in@1.60 +2 -2 + NTP_4_2_7P244 + + util/ntp-keygen.mdoc.in@1.60 +2 -2 + NTP_4_2_7P244 + +ChangeSet@1.2082.4.262, 2011-12-24 18:34:58-05:00, stenn@deacon.udel.edu + NTP_4_2_6P5 + TAG: NTP_4_2_6P5 + + ChangeLog@1.496.26.186 +1 -0 + NTP_4_2_6P5 + + ntpd/ntpd-opts.c@1.248.43.1 +5 -5 + NTP_4_2_6P5 + + ntpd/ntpd-opts.h@1.248.43.1 +3 -3 + NTP_4_2_6P5 + + ntpd/ntpd-opts.texi@1.246.42.1 +2 -2 + NTP_4_2_6P5 + + ntpd/ntpd.1@1.246.42.1 +2 -2 + NTP_4_2_6P5 + + ntpdc/ntpdc-opts.c@1.244.43.1 +5 -5 + NTP_4_2_6P5 + + ntpdc/ntpdc-opts.h@1.244.43.1 +3 -3 + NTP_4_2_6P5 + + ntpdc/ntpdc-opts.texi@1.243.42.1 +2 -2 + NTP_4_2_6P5 + + ntpdc/ntpdc.1@1.243.42.1 +2 -2 + NTP_4_2_6P5 + + ntpq/ntpq-opts.c@1.245.43.1 +5 -5 + NTP_4_2_6P5 + + ntpq/ntpq-opts.h@1.245.43.1 +3 -3 + NTP_4_2_6P5 + + ntpq/ntpq-opts.texi@1.244.42.1 +2 -2 + NTP_4_2_6P5 + + ntpq/ntpq.1@1.244.42.1 +2 -2 + NTP_4_2_6P5 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.44.1 +5 -5 + NTP_4_2_6P5 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.44.1 +3 -3 + NTP_4_2_6P5 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.43.1 +2 -2 + NTP_4_2_6P5 + + ntpsnmpd/ntpsnmpd.1@1.122.43.1 +2 -2 + NTP_4_2_6P5 + + packageinfo.sh@1.255.40.2 +2 -2 + NTP_4_2_6P5 + + sntp/sntp-opts.c@1.117.42.1 +5 -5 + NTP_4_2_6P5 + + sntp/sntp-opts.h@1.117.42.1 +3 -3 + NTP_4_2_6P5 + + sntp/sntp-opts.texi@1.117.41.1 +2 -2 + NTP_4_2_6P5 + + sntp/sntp.1@1.117.41.1 +2 -2 + NTP_4_2_6P5 + + sntp/sntp.html@1.7.42.1 +2 -2 + NTP_4_2_6P5 + + util/ntp-keygen-opts.c@1.247.43.1 +5 -5 + NTP_4_2_6P5 + + util/ntp-keygen-opts.h@1.247.43.1 +3 -3 + NTP_4_2_6P5 + + util/ntp-keygen-opts.texi@1.246.42.1 +2 -2 + NTP_4_2_6P5 + + util/ntp-keygen.1@1.246.42.1 +2 -2 + NTP_4_2_6P5 + +ChangeSet@1.2082.4.261, 2011-12-24 18:21:54-05:00, stenn@deacon.udel.edu + ntp-4.2.6p5 + + packageinfo.sh@1.255.40.1 +3 -2 + ntp-4.2.6p5 + +ChangeSet@1.2082.4.260, 2011-12-24 18:08:51-05:00, stenn@deacon.udel.edu + fix typos + + NEWS@1.122.1.5 +8 -8 + fix typos + +ChangeSet@1.2082.4.259, 2011-12-24 17:47:02-05:00, stenn@deacon.udel.edu + NEWS cleanup + + NEWS@1.122.1.4 +25 -21 + NEWS cleanup + +ChangeSet@1.2082.4.258, 2011-12-23 22:48:14-05:00, stenn@deacon.udel.edu + NEWS file cleanup + + ChangeLog@1.496.26.185 +3 -0 + NEWS file cleanup + + NEWS@1.122.1.3 +6 -8 + NEWS file cleanup + +ChangeSet@1.2730, 2011-12-23 04:43:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P243 + TAG: NTP_4_2_7P243 + + ChangeLog@1.1083 +1 -0 + NTP_4_2_7P243 + + ntpd/ntpd-opts.c@1.248 +3 -3 + NTP_4_2_7P243 + + ntpd/ntpd-opts.h@1.248 +3 -3 + NTP_4_2_7P243 + + ntpd/ntpd-opts.texi@1.246 +2 -2 + NTP_4_2_7P243 + + ntpd/ntpd.1ntpdman@1.59 +2 -2 + NTP_4_2_7P243 + + ntpd/ntpd.1ntpdmdoc@1.59 +2 -2 + NTP_4_2_7P243 + + ntpd/ntpd.man.in@1.59 +2 -2 + NTP_4_2_7P243 + + ntpd/ntpd.mdoc.in@1.59 +2 -2 + NTP_4_2_7P243 + + ntpdc/ntpdc-opts.c@1.243 +3 -3 + NTP_4_2_7P243 + + ntpdc/ntpdc-opts.h@1.243 +3 -3 + NTP_4_2_7P243 + + ntpdc/ntpdc-opts.texi@1.243 +2 -2 + NTP_4_2_7P243 + + ntpdc/ntpdc.1ntpdcman@1.59 +2 -2 + NTP_4_2_7P243 + + ntpdc/ntpdc.1ntpdcmdoc@1.59 +2 -2 + NTP_4_2_7P243 + + ntpdc/ntpdc.html@1.71 +2 -2 + NTP_4_2_7P243 + + ntpdc/ntpdc.man.in@1.59 +2 -2 + NTP_4_2_7P243 + + ntpdc/ntpdc.mdoc.in@1.59 +2 -2 + NTP_4_2_7P243 + + ntpq/ntpq-opts.c@1.245 +3 -3 + NTP_4_2_7P243 + + ntpq/ntpq-opts.h@1.245 +3 -3 + NTP_4_2_7P243 + + ntpq/ntpq-opts.texi@1.245 +2 -2 + NTP_4_2_7P243 + + ntpq/ntpq.1ntpqman@1.59 +2 -2 + NTP_4_2_7P243 + + ntpq/ntpq.1ntpqmdoc@1.59 +2 -2 + NTP_4_2_7P243 + + ntpq/ntpq.man.in@1.59 +2 -2 + NTP_4_2_7P243 + + ntpq/ntpq.mdoc.in@1.59 +2 -2 + NTP_4_2_7P243 + + ntpsnmpd/ntpsnmpd-opts.c@1.245 +3 -3 + NTP_4_2_7P243 + + ntpsnmpd/ntpsnmpd-opts.h@1.245 +3 -3 + NTP_4_2_7P243 + + ntpsnmpd/ntpsnmpd-opts.texi@1.245 +2 -2 + NTP_4_2_7P243 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.59 +2 -2 + NTP_4_2_7P243 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.59 +2 -2 + NTP_4_2_7P243 + + ntpsnmpd/ntpsnmpd.man.in@1.59 +2 -2 + NTP_4_2_7P243 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.59 +2 -2 + NTP_4_2_7P243 + + packageinfo.sh@1.246 +1 -1 + NTP_4_2_7P243 + + scripts/ntp-wait-opts.texi@1.63 +1 -1 + NTP_4_2_7P243 + + scripts/ntp-wait.1ntp-waitman@1.59 +2 -2 + NTP_4_2_7P243 + + scripts/ntp-wait.1ntp-waitmdoc@1.59 +2 -2 + NTP_4_2_7P243 + + scripts/ntp-wait.html@1.63 +1 -1 + NTP_4_2_7P243 + + scripts/ntp-wait.man.in@1.59 +2 -2 + NTP_4_2_7P243 + + scripts/ntp-wait.mdoc.in@1.59 +2 -2 + NTP_4_2_7P243 + + sntp/sntp-opts.c@1.241 +3 -3 + NTP_4_2_7P243 + + sntp/sntp-opts.h@1.241 +3 -3 + NTP_4_2_7P243 + + sntp/sntp-opts.texi@1.241 +2 -2 + NTP_4_2_7P243 + + sntp/sntp.1sntpman@1.61 +2 -2 + NTP_4_2_7P243 + + sntp/sntp.1sntpmdoc@1.61 +2 -2 + NTP_4_2_7P243 + + sntp/sntp.html@1.241 +2 -2 + NTP_4_2_7P243 + + sntp/sntp.man.in@1.61 +2 -2 + NTP_4_2_7P243 + + sntp/sntp.mdoc.in@1.61 +2 -2 + NTP_4_2_7P243 + + util/ntp-keygen-opts.c@1.245 +3 -3 + NTP_4_2_7P243 + + util/ntp-keygen-opts.h@1.245 +3 -3 + NTP_4_2_7P243 + + util/ntp-keygen-opts.texi@1.246 +2 -2 + NTP_4_2_7P243 + + util/ntp-keygen.1ntp-keygenman@1.59 +2 -2 + NTP_4_2_7P243 + + util/ntp-keygen.1ntp-keygenmdoc@1.59 +2 -2 + NTP_4_2_7P243 + + util/ntp-keygen.man.in@1.59 +2 -2 + NTP_4_2_7P243 + + util/ntp-keygen.mdoc.in@1.59 +2 -2 + NTP_4_2_7P243 + +ChangeSet@1.2729, 2011-12-22 23:22:36-05:00, stenn@deacon.udel.edu + typo + + ChangeLog@1.1082 +1 -1 + typo + +ChangeSet@1.2728, 2011-12-22 23:07:30-05:00, stenn@deacon.udel.edu + [Bug 2095] ntptrace now needs 'rv' instead pf 'pstat', reported by Michael Tatarinov + + ChangeLog@1.1081 +2 -0 + [Bug 2095] ntptrace now needs 'rv' instead pf 'pstat', reported by Michael Tatarinov + + scripts/ntptrace.in@1.7 +1 -1 + [Bug 2095] ntptrace now needs 'rv' instead pf 'pstat', reported by Michael Tatarinov + +ChangeSet@1.2727, 2011-12-21 21:08:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P242 + TAG: NTP_4_2_7P242 + + ChangeLog@1.1080 +1 -0 + NTP_4_2_7P242 + + ntpd/ntpd-opts.c@1.247 +3 -3 + NTP_4_2_7P242 + + ntpd/ntpd-opts.h@1.247 +3 -3 + NTP_4_2_7P242 + + ntpd/ntpd-opts.texi@1.245 +2 -2 + NTP_4_2_7P242 + + ntpd/ntpd.1ntpdman@1.58 +2 -2 + NTP_4_2_7P242 + + ntpd/ntpd.1ntpdmdoc@1.58 +2 -2 + NTP_4_2_7P242 + + ntpd/ntpd.man.in@1.58 +2 -2 + NTP_4_2_7P242 + + ntpd/ntpd.mdoc.in@1.58 +2 -2 + NTP_4_2_7P242 + + ntpdc/ntpdc-opts.c@1.242 +3 -3 + NTP_4_2_7P242 + + ntpdc/ntpdc-opts.h@1.242 +3 -3 + NTP_4_2_7P242 + + ntpdc/ntpdc-opts.texi@1.242 +2 -2 + NTP_4_2_7P242 + + ntpdc/ntpdc.1ntpdcman@1.58 +2 -2 + NTP_4_2_7P242 + + ntpdc/ntpdc.1ntpdcmdoc@1.58 +2 -2 + NTP_4_2_7P242 + + ntpdc/ntpdc.html@1.70 +2 -2 + NTP_4_2_7P242 + + ntpdc/ntpdc.man.in@1.58 +2 -2 + NTP_4_2_7P242 + + ntpdc/ntpdc.mdoc.in@1.58 +2 -2 + NTP_4_2_7P242 + + ntpq/ntpq-opts.c@1.244 +3 -3 + NTP_4_2_7P242 + + ntpq/ntpq-opts.h@1.244 +3 -3 + NTP_4_2_7P242 + + ntpq/ntpq-opts.texi@1.244 +2 -2 + NTP_4_2_7P242 + + ntpq/ntpq.1ntpqman@1.58 +2 -2 + NTP_4_2_7P242 + + ntpq/ntpq.1ntpqmdoc@1.58 +2 -2 + NTP_4_2_7P242 + + ntpq/ntpq.man.in@1.58 +2 -2 + NTP_4_2_7P242 + + ntpq/ntpq.mdoc.in@1.58 +2 -2 + NTP_4_2_7P242 + + ntpsnmpd/ntpsnmpd-opts.c@1.244 +3 -3 + NTP_4_2_7P242 + + ntpsnmpd/ntpsnmpd-opts.h@1.244 +3 -3 + NTP_4_2_7P242 + + ntpsnmpd/ntpsnmpd-opts.texi@1.244 +2 -2 + NTP_4_2_7P242 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.58 +2 -2 + NTP_4_2_7P242 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.58 +2 -2 + NTP_4_2_7P242 + + ntpsnmpd/ntpsnmpd.man.in@1.58 +2 -2 + NTP_4_2_7P242 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.58 +2 -2 + NTP_4_2_7P242 + + packageinfo.sh@1.245 +1 -1 + NTP_4_2_7P242 + + scripts/ntp-wait-opts.texi@1.62 +1 -1 + NTP_4_2_7P242 + + scripts/ntp-wait.1ntp-waitman@1.58 +2 -2 + NTP_4_2_7P242 + + scripts/ntp-wait.1ntp-waitmdoc@1.58 +2 -2 + NTP_4_2_7P242 + + scripts/ntp-wait.html@1.62 +1 -1 + NTP_4_2_7P242 + + scripts/ntp-wait.man.in@1.58 +2 -2 + NTP_4_2_7P242 + + scripts/ntp-wait.mdoc.in@1.58 +2 -2 + NTP_4_2_7P242 + + sntp/sntp-opts.c@1.240 +3 -3 + NTP_4_2_7P242 + + sntp/sntp-opts.h@1.240 +3 -3 + NTP_4_2_7P242 + + sntp/sntp-opts.texi@1.240 +2 -2 + NTP_4_2_7P242 + + sntp/sntp.1sntpman@1.60 +2 -2 + NTP_4_2_7P242 + + sntp/sntp.1sntpmdoc@1.60 +2 -2 + NTP_4_2_7P242 + + sntp/sntp.html@1.240 +2 -2 + NTP_4_2_7P242 + + sntp/sntp.man.in@1.60 +2 -2 + NTP_4_2_7P242 + + sntp/sntp.mdoc.in@1.60 +2 -2 + NTP_4_2_7P242 + + util/ntp-keygen-opts.c@1.244 +3 -3 + NTP_4_2_7P242 + + util/ntp-keygen-opts.h@1.244 +3 -3 + NTP_4_2_7P242 + + util/ntp-keygen-opts.texi@1.245 +2 -2 + NTP_4_2_7P242 + + util/ntp-keygen.1ntp-keygenman@1.58 +2 -2 + NTP_4_2_7P242 + + util/ntp-keygen.1ntp-keygenmdoc@1.58 +2 -2 + NTP_4_2_7P242 + + util/ntp-keygen.man.in@1.58 +2 -2 + NTP_4_2_7P242 + + util/ntp-keygen.mdoc.in@1.58 +2 -2 + NTP_4_2_7P242 + +ChangeSet@1.2726, 2011-12-21 15:05:08-05:00, stenn@deacon.udel.edu + Documentation updates + + ChangeLog@1.1079 +1 -0 + Include missing html/icons/sitemap.png, reported by Michael Tatarinov + + ChangeLog@1.1078 +1 -0 + Documentation updates from Dave Mills + + html/icons/sitemap.png@1.1 +64 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/icons/sitemap.png + + html/icons/sitemap.png@1.0 +0 -0 + + html/prefer.html@1.30 +3 -3 + Documentation updates from Dave Mills + + html/select.html@1.6 +2 -2 + Documentation updates from Dave Mills + + html/warp.html@1.21 +6 -8 + Documentation updates from Dave Mills + +ChangeSet@1.2725, 2011-12-18 22:08:57+00:00, stenn@deacon.udel.edu + NTP_4_2_7P241 + TAG: NTP_4_2_7P241 + + ChangeLog@1.1077 +1 -0 + NTP_4_2_7P241 + + ntpd/ntpd-opts.c@1.246 +3 -3 + NTP_4_2_7P241 + + ntpd/ntpd-opts.h@1.246 +3 -3 + NTP_4_2_7P241 + + ntpd/ntpd-opts.texi@1.244 +2 -2 + NTP_4_2_7P241 + + ntpd/ntpd.1ntpdman@1.57 +2 -2 + NTP_4_2_7P241 + + ntpd/ntpd.1ntpdmdoc@1.57 +2 -2 + NTP_4_2_7P241 + + ntpd/ntpd.man.in@1.57 +2 -2 + NTP_4_2_7P241 + + ntpd/ntpd.mdoc.in@1.57 +2 -2 + NTP_4_2_7P241 + + ntpdc/ntpdc-opts.c@1.241 +3 -3 + NTP_4_2_7P241 + + ntpdc/ntpdc-opts.h@1.241 +3 -3 + NTP_4_2_7P241 + + ntpdc/ntpdc-opts.texi@1.241 +2 -2 + NTP_4_2_7P241 + + ntpdc/ntpdc.1ntpdcman@1.57 +2 -2 + NTP_4_2_7P241 + + ntpdc/ntpdc.1ntpdcmdoc@1.57 +2 -2 + NTP_4_2_7P241 + + ntpdc/ntpdc.html@1.69 +2 -2 + NTP_4_2_7P241 + + ntpdc/ntpdc.man.in@1.57 +2 -2 + NTP_4_2_7P241 + + ntpdc/ntpdc.mdoc.in@1.57 +2 -2 + NTP_4_2_7P241 + + ntpq/ntpq-opts.c@1.243 +3 -3 + NTP_4_2_7P241 + + ntpq/ntpq-opts.h@1.243 +3 -3 + NTP_4_2_7P241 + + ntpq/ntpq-opts.texi@1.243 +2 -2 + NTP_4_2_7P241 + + ntpq/ntpq.1ntpqman@1.57 +2 -2 + NTP_4_2_7P241 + + ntpq/ntpq.1ntpqmdoc@1.57 +2 -2 + NTP_4_2_7P241 + + ntpq/ntpq.man.in@1.57 +2 -2 + NTP_4_2_7P241 + + ntpq/ntpq.mdoc.in@1.57 +2 -2 + NTP_4_2_7P241 + + ntpsnmpd/ntpsnmpd-opts.c@1.243 +3 -3 + NTP_4_2_7P241 + + ntpsnmpd/ntpsnmpd-opts.h@1.243 +3 -3 + NTP_4_2_7P241 + + ntpsnmpd/ntpsnmpd-opts.texi@1.243 +2 -2 + NTP_4_2_7P241 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.57 +2 -2 + NTP_4_2_7P241 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.57 +2 -2 + NTP_4_2_7P241 + + ntpsnmpd/ntpsnmpd.man.in@1.57 +2 -2 + NTP_4_2_7P241 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.57 +2 -2 + NTP_4_2_7P241 + + packageinfo.sh@1.244 +1 -1 + NTP_4_2_7P241 + + scripts/ntp-wait-opts.texi@1.61 +1 -1 + NTP_4_2_7P241 + + scripts/ntp-wait.1ntp-waitman@1.57 +2 -2 + NTP_4_2_7P241 + + scripts/ntp-wait.1ntp-waitmdoc@1.57 +2 -2 + NTP_4_2_7P241 + + scripts/ntp-wait.html@1.61 +1 -1 + NTP_4_2_7P241 + + scripts/ntp-wait.man.in@1.57 +2 -2 + NTP_4_2_7P241 + + scripts/ntp-wait.mdoc.in@1.57 +2 -2 + NTP_4_2_7P241 + + sntp/sntp-opts.c@1.239 +3 -3 + NTP_4_2_7P241 + + sntp/sntp-opts.h@1.239 +3 -3 + NTP_4_2_7P241 + + sntp/sntp-opts.texi@1.239 +2 -2 + NTP_4_2_7P241 + + sntp/sntp.1sntpman@1.59 +2 -2 + NTP_4_2_7P241 + + sntp/sntp.1sntpmdoc@1.59 +2 -2 + NTP_4_2_7P241 + + sntp/sntp.html@1.239 +2 -2 + NTP_4_2_7P241 + + sntp/sntp.man.in@1.59 +2 -2 + NTP_4_2_7P241 + + sntp/sntp.mdoc.in@1.59 +2 -2 + NTP_4_2_7P241 + + util/ntp-keygen-opts.c@1.243 +3 -3 + NTP_4_2_7P241 + + util/ntp-keygen-opts.h@1.243 +3 -3 + NTP_4_2_7P241 + + util/ntp-keygen-opts.texi@1.244 +2 -2 + NTP_4_2_7P241 + + util/ntp-keygen.1ntp-keygenman@1.57 +2 -2 + NTP_4_2_7P241 + + util/ntp-keygen.1ntp-keygenmdoc@1.57 +2 -2 + NTP_4_2_7P241 + + util/ntp-keygen.man.in@1.57 +2 -2 + NTP_4_2_7P241 + + util/ntp-keygen.mdoc.in@1.57 +2 -2 + NTP_4_2_7P241 + +ChangeSet@1.2724, 2011-12-18 04:24:58+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2015] Overriding sys_tick should recalculate sys_precision. + [Bug 2068] "tos ceiling" default and cap changed to 15. + Floor peer delay using system precision, as with jitter, reflecting + inability to measure shorter intervals. + + ChangeLog@1.1076 +4 -0 + [Bug 2015] Overriding sys_tick should recalculate sys_precision. + [Bug 2068] "tos ceiling" default and cap changed to 15. + Floor peer delay using system precision, as with jitter, reflecting + inability to measure shorter intervals. + + include/ntp.h@1.202 +2 -1 + move sys_tick override from proto_config() to loop_config() + + include/ntp_stdlib.h@1.69 +1 -0 + [Bug 2015] Overriding sys_tick should recalculate sys_precision. + + include/ntp_unixtime.h@1.12 +2 -0 + include timespecops.h and timevalops.h + + include/ntpd.h@1.171 +1 -0 + [Bug 2015] Overriding sys_tick should recalculate sys_precision. + + libntp/systime.c@1.61 +11 -3 + [Bug 2015] Overriding sys_tick should recalculate sys_precision. + + ntpd/complete.conf@1.21 +1 -1 + add "tinker tick 0.01" coverage + + ntpd/ntp_config.c@1.296 +17 -4 + support "tinker tick 0.01" syntax alongside older "tick 0.01" + [Bug 2068] "tos ceiling" default and cap changed to 15. + + ntpd/ntp_control.c@1.178 +8 -2 + Expose sys_fuzz to ntpq as nondefault system variable fuzz. + + ntpd/ntp_io.c@1.364 +30 -25 + [Bug 2015] Overriding sys_tick should recalculate sys_precision. + + ntpd/ntp_loopfilter.c@1.169 +5 -1 + move sys_tick override from proto_config() to loop_config() + + ntpd/ntp_parser.c@1.78 +428 -424 + Bison output for ntp_parser.y + + ntpd/ntp_parser.y@1.72 +1 -0 + support "tinker tick 0.01" syntax alongside older "tick 0.01" + + ntpd/ntp_proto.c@1.337 +46 -17 + [Bug 2015] Overriding sys_tick should recalculate sys_precision. + [Bug 2068] "tos ceiling" default and cap changed to 15. + Floor peer delay using system precision, as with jitter, reflecting + inability to measure shorter intervals. + + ports/winnt/ntpd/nt_clockstuff.c@1.55 +6 -13 + nonfunctional cleanup + + util/ntp-keygen.c@1.88 +1 -2 + remove now-redundant MAXHOSTNAME declaration (in ntp.h) + +ChangeSet@1.2713.1.1, 2011-12-17 02:30:42+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + ChangeLog@1.1065.1.1 +1 -0 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + include/ntp_fp.h@1.27 +7 -1 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + include/ntp_stdlib.h@1.68 +2 -1 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + libntp/systime.c@1.58.1.1 +151 -74 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + libntp/timespecops.c@1.8 +1 -1 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + ntpd/ntp_proto.c@1.332.1.1 +57 -23 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + ntpd/refclock_arc.c@1.27 +1 -1 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + + ports/winnt/ntpd/nt_clockstuff.c@1.54 +11 -2 + [Bug 2037] Fuzzed non-interpolated clock may decrease. + +ChangeSet@1.2722, 2011-12-15 08:50:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P240 + TAG: NTP_4_2_7P240 + + ChangeLog@1.1074 +1 -0 + NTP_4_2_7P240 + + ntpd/ntpd-opts.c@1.245 +3 -3 + NTP_4_2_7P240 + + ntpd/ntpd-opts.h@1.245 +3 -3 + NTP_4_2_7P240 + + ntpd/ntpd-opts.texi@1.243 +2 -2 + NTP_4_2_7P240 + + ntpd/ntpd.1ntpdman@1.56 +2 -2 + NTP_4_2_7P240 + + ntpd/ntpd.1ntpdmdoc@1.56 +2 -2 + NTP_4_2_7P240 + + ntpd/ntpd.man.in@1.56 +2 -2 + NTP_4_2_7P240 + + ntpd/ntpd.mdoc.in@1.56 +2 -2 + NTP_4_2_7P240 + + ntpdc/ntpdc-opts.c@1.240 +3 -3 + NTP_4_2_7P240 + + ntpdc/ntpdc-opts.h@1.240 +3 -3 + NTP_4_2_7P240 + + ntpdc/ntpdc-opts.texi@1.240 +2 -2 + NTP_4_2_7P240 + + ntpdc/ntpdc.1ntpdcman@1.56 +2 -2 + NTP_4_2_7P240 + + ntpdc/ntpdc.1ntpdcmdoc@1.56 +2 -2 + NTP_4_2_7P240 + + ntpdc/ntpdc.html@1.68 +2 -2 + NTP_4_2_7P240 + + ntpdc/ntpdc.man.in@1.56 +2 -2 + NTP_4_2_7P240 + + ntpdc/ntpdc.mdoc.in@1.56 +2 -2 + NTP_4_2_7P240 + + ntpq/ntpq-opts.c@1.242 +3 -3 + NTP_4_2_7P240 + + ntpq/ntpq-opts.h@1.242 +3 -3 + NTP_4_2_7P240 + + ntpq/ntpq-opts.texi@1.242 +2 -2 + NTP_4_2_7P240 + + ntpq/ntpq.1ntpqman@1.56 +2 -2 + NTP_4_2_7P240 + + ntpq/ntpq.1ntpqmdoc@1.56 +2 -2 + NTP_4_2_7P240 + + ntpq/ntpq.man.in@1.56 +2 -2 + NTP_4_2_7P240 + + ntpq/ntpq.mdoc.in@1.56 +2 -2 + NTP_4_2_7P240 + + ntpsnmpd/ntpsnmpd-opts.c@1.242 +3 -3 + NTP_4_2_7P240 + + ntpsnmpd/ntpsnmpd-opts.h@1.242 +3 -3 + NTP_4_2_7P240 + + ntpsnmpd/ntpsnmpd-opts.texi@1.242 +2 -2 + NTP_4_2_7P240 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.56 +2 -2 + NTP_4_2_7P240 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.56 +2 -2 + NTP_4_2_7P240 + + ntpsnmpd/ntpsnmpd.man.in@1.56 +2 -2 + NTP_4_2_7P240 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.56 +2 -2 + NTP_4_2_7P240 + + packageinfo.sh@1.243 +1 -1 + NTP_4_2_7P240 + + scripts/ntp-wait-opts.texi@1.60 +1 -1 + NTP_4_2_7P240 + + scripts/ntp-wait.1ntp-waitman@1.56 +2 -2 + NTP_4_2_7P240 + + scripts/ntp-wait.1ntp-waitmdoc@1.56 +2 -2 + NTP_4_2_7P240 + + scripts/ntp-wait.html@1.60 +1 -1 + NTP_4_2_7P240 + + scripts/ntp-wait.man.in@1.56 +2 -2 + NTP_4_2_7P240 + + scripts/ntp-wait.mdoc.in@1.56 +2 -2 + NTP_4_2_7P240 + + sntp/sntp-opts.c@1.238 +3 -3 + NTP_4_2_7P240 + + sntp/sntp-opts.h@1.238 +3 -3 + NTP_4_2_7P240 + + sntp/sntp-opts.texi@1.238 +2 -2 + NTP_4_2_7P240 + + sntp/sntp.1sntpman@1.58 +2 -2 + NTP_4_2_7P240 + + sntp/sntp.1sntpmdoc@1.58 +2 -2 + NTP_4_2_7P240 + + sntp/sntp.html@1.238 +2 -2 + NTP_4_2_7P240 + + sntp/sntp.man.in@1.58 +2 -2 + NTP_4_2_7P240 + + sntp/sntp.mdoc.in@1.58 +2 -2 + NTP_4_2_7P240 + + util/ntp-keygen-opts.c@1.242 +3 -3 + NTP_4_2_7P240 + + util/ntp-keygen-opts.h@1.242 +3 -3 + NTP_4_2_7P240 + + util/ntp-keygen-opts.texi@1.243 +2 -2 + NTP_4_2_7P240 + + util/ntp-keygen.1ntp-keygenman@1.56 +2 -2 + NTP_4_2_7P240 + + util/ntp-keygen.1ntp-keygenmdoc@1.56 +2 -2 + NTP_4_2_7P240 + + util/ntp-keygen.man.in@1.56 +2 -2 + NTP_4_2_7P240 + + util/ntp-keygen.mdoc.in@1.56 +2 -2 + NTP_4_2_7P240 + +ChangeSet@1.2721, 2011-12-15 03:27:02+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2092] clock_select() selection jitter miscalculated. + [Bug 2093] Reintroduce smaller stratum factor to system peer metric. + + ChangeLog@1.1073 +2 -0 + [Bug 2092] clock_select() selection jitter miscalculated. + [Bug 2093] Reintroduce smaller stratum factor to system peer metric. + + include/ntp_calendar.h@1.11 +14 -12 + Reduce use of magic precomputed numbers in favor of construction. + + include/ntp_unixtime.h@1.11 +5 -2 + Reduce use of magic precomputed numbers in favor of construction. + + libntp/humandate.c@1.11 +0 -1 + Remove declaration now redundant with ntp_calendar.h + + ntpd/ntp_proto.c@1.335 +157 -164 + [Bug 2092] clock_select() selection jitter miscalculated. + [Bug 2093] Reintroduce smaller stratum factor to system peer metric. + Refactor clock_select() to use single peers array of new peer_select + struct instead of separate synch and error arrays kept in sync, + no longer sort peers array by selection metric. + +ChangeSet@1.2720, 2011-12-11 11:39:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P239 + TAG: NTP_4_2_7P239 + + ChangeLog@1.1072 +1 -0 + NTP_4_2_7P239 + + ntpd/ntpd-opts.c@1.244 +3 -3 + NTP_4_2_7P239 + + ntpd/ntpd-opts.h@1.244 +3 -3 + NTP_4_2_7P239 + + ntpd/ntpd-opts.texi@1.242 +2 -2 + NTP_4_2_7P239 + + ntpd/ntpd.1ntpdman@1.55 +2 -2 + NTP_4_2_7P239 + + ntpd/ntpd.1ntpdmdoc@1.55 +2 -2 + NTP_4_2_7P239 + + ntpd/ntpd.man.in@1.55 +2 -2 + NTP_4_2_7P239 + + ntpd/ntpd.mdoc.in@1.55 +2 -2 + NTP_4_2_7P239 + + ntpdc/ntpdc-opts.c@1.239 +3 -3 + NTP_4_2_7P239 + + ntpdc/ntpdc-opts.h@1.239 +3 -3 + NTP_4_2_7P239 + + ntpdc/ntpdc-opts.texi@1.239 +2 -2 + NTP_4_2_7P239 + + ntpdc/ntpdc.1ntpdcman@1.55 +2 -2 + NTP_4_2_7P239 + + ntpdc/ntpdc.1ntpdcmdoc@1.55 +2 -2 + NTP_4_2_7P239 + + ntpdc/ntpdc.html@1.67 +2 -2 + NTP_4_2_7P239 + + ntpdc/ntpdc.man.in@1.55 +2 -2 + NTP_4_2_7P239 + + ntpdc/ntpdc.mdoc.in@1.55 +2 -2 + NTP_4_2_7P239 + + ntpq/ntpq-opts.c@1.241 +3 -3 + NTP_4_2_7P239 + + ntpq/ntpq-opts.h@1.241 +3 -3 + NTP_4_2_7P239 + + ntpq/ntpq-opts.texi@1.241 +2 -2 + NTP_4_2_7P239 + + ntpq/ntpq.1ntpqman@1.55 +2 -2 + NTP_4_2_7P239 + + ntpq/ntpq.1ntpqmdoc@1.55 +2 -2 + NTP_4_2_7P239 + + ntpq/ntpq.man.in@1.55 +2 -2 + NTP_4_2_7P239 + + ntpq/ntpq.mdoc.in@1.55 +2 -2 + NTP_4_2_7P239 + + ntpsnmpd/ntpsnmpd-opts.c@1.241 +3 -3 + NTP_4_2_7P239 + + ntpsnmpd/ntpsnmpd-opts.h@1.241 +3 -3 + NTP_4_2_7P239 + + ntpsnmpd/ntpsnmpd-opts.texi@1.241 +2 -2 + NTP_4_2_7P239 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.55 +2 -2 + NTP_4_2_7P239 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.55 +2 -2 + NTP_4_2_7P239 + + ntpsnmpd/ntpsnmpd.man.in@1.55 +2 -2 + NTP_4_2_7P239 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.55 +2 -2 + NTP_4_2_7P239 + + packageinfo.sh@1.242 +1 -1 + NTP_4_2_7P239 + + scripts/ntp-wait-opts.texi@1.59 +1 -1 + NTP_4_2_7P239 + + scripts/ntp-wait.1ntp-waitman@1.55 +2 -2 + NTP_4_2_7P239 + + scripts/ntp-wait.1ntp-waitmdoc@1.55 +2 -2 + NTP_4_2_7P239 + + scripts/ntp-wait.html@1.59 +1 -1 + NTP_4_2_7P239 + + scripts/ntp-wait.man.in@1.55 +2 -2 + NTP_4_2_7P239 + + scripts/ntp-wait.mdoc.in@1.55 +2 -2 + NTP_4_2_7P239 + + sntp/sntp-opts.c@1.237 +3 -3 + NTP_4_2_7P239 + + sntp/sntp-opts.h@1.237 +3 -3 + NTP_4_2_7P239 + + sntp/sntp-opts.texi@1.237 +2 -2 + NTP_4_2_7P239 + + sntp/sntp.1sntpman@1.57 +2 -2 + NTP_4_2_7P239 + + sntp/sntp.1sntpmdoc@1.57 +2 -2 + NTP_4_2_7P239 + + sntp/sntp.html@1.237 +2 -2 + NTP_4_2_7P239 + + sntp/sntp.man.in@1.57 +2 -2 + NTP_4_2_7P239 + + sntp/sntp.mdoc.in@1.57 +2 -2 + NTP_4_2_7P239 + + util/ntp-keygen-opts.c@1.241 +3 -3 + NTP_4_2_7P239 + + util/ntp-keygen-opts.h@1.241 +3 -3 + NTP_4_2_7P239 + + util/ntp-keygen-opts.texi@1.242 +2 -2 + NTP_4_2_7P239 + + util/ntp-keygen.1ntp-keygenman@1.55 +2 -2 + NTP_4_2_7P239 + + util/ntp-keygen.1ntp-keygenmdoc@1.55 +2 -2 + NTP_4_2_7P239 + + util/ntp-keygen.man.in@1.55 +2 -2 + NTP_4_2_7P239 + + util/ntp-keygen.mdoc.in@1.55 +2 -2 + NTP_4_2_7P239 + +ChangeSet@1.2719, 2011-12-11 05:57:08-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1071 +1 -0 + Documentation updates from Dave Mills + + html/cluster.html@1.7 +4 -3 + Documentation updates from Dave Mills + + html/filter.html@1.5 +7 -6 + Documentation updates from Dave Mills + + html/prefer.html@1.29 +20 -33 + Documentation updates from Dave Mills + + html/select.html@1.5 +10 -3 + Documentation updates from Dave Mills + + html/warp.html@1.20 +12 -12 + Documentation updates from Dave Mills + +ChangeSet@1.2718, 2011-12-09 19:19:04+00:00, stenn@deacon.udel.edu + NTP_4_2_7P238 + TAG: NTP_4_2_7P238 + + ChangeLog@1.1070 +1 -0 + NTP_4_2_7P238 + + ntpd/ntpd-opts.c@1.243 +3 -3 + NTP_4_2_7P238 + + ntpd/ntpd-opts.h@1.243 +3 -3 + NTP_4_2_7P238 + + ntpd/ntpd-opts.texi@1.241 +2 -2 + NTP_4_2_7P238 + + ntpd/ntpd.1ntpdman@1.54 +2 -2 + NTP_4_2_7P238 + + ntpd/ntpd.1ntpdmdoc@1.54 +2 -2 + NTP_4_2_7P238 + + ntpd/ntpd.man.in@1.54 +2 -2 + NTP_4_2_7P238 + + ntpd/ntpd.mdoc.in@1.54 +2 -2 + NTP_4_2_7P238 + + ntpdc/ntpdc-opts.c@1.238 +3 -3 + NTP_4_2_7P238 + + ntpdc/ntpdc-opts.h@1.238 +3 -3 + NTP_4_2_7P238 + + ntpdc/ntpdc-opts.texi@1.238 +2 -2 + NTP_4_2_7P238 + + ntpdc/ntpdc.1ntpdcman@1.54 +2 -2 + NTP_4_2_7P238 + + ntpdc/ntpdc.1ntpdcmdoc@1.54 +2 -2 + NTP_4_2_7P238 + + ntpdc/ntpdc.html@1.66 +2 -2 + NTP_4_2_7P238 + + ntpdc/ntpdc.man.in@1.54 +2 -2 + NTP_4_2_7P238 + + ntpdc/ntpdc.mdoc.in@1.54 +2 -2 + NTP_4_2_7P238 + + ntpq/ntpq-opts.c@1.240 +3 -3 + NTP_4_2_7P238 + + ntpq/ntpq-opts.h@1.240 +3 -3 + NTP_4_2_7P238 + + ntpq/ntpq-opts.texi@1.240 +2 -2 + NTP_4_2_7P238 + + ntpq/ntpq.1ntpqman@1.54 +2 -2 + NTP_4_2_7P238 + + ntpq/ntpq.1ntpqmdoc@1.54 +2 -2 + NTP_4_2_7P238 + + ntpq/ntpq.man.in@1.54 +2 -2 + NTP_4_2_7P238 + + ntpq/ntpq.mdoc.in@1.54 +2 -2 + NTP_4_2_7P238 + + ntpsnmpd/ntpsnmpd-opts.c@1.240 +3 -3 + NTP_4_2_7P238 + + ntpsnmpd/ntpsnmpd-opts.h@1.240 +3 -3 + NTP_4_2_7P238 + + ntpsnmpd/ntpsnmpd-opts.texi@1.240 +2 -2 + NTP_4_2_7P238 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.54 +2 -2 + NTP_4_2_7P238 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.54 +2 -2 + NTP_4_2_7P238 + + ntpsnmpd/ntpsnmpd.man.in@1.54 +2 -2 + NTP_4_2_7P238 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.54 +2 -2 + NTP_4_2_7P238 + + packageinfo.sh@1.241 +1 -1 + NTP_4_2_7P238 + + scripts/ntp-wait-opts.texi@1.58 +1 -1 + NTP_4_2_7P238 + + scripts/ntp-wait.1ntp-waitman@1.54 +2 -2 + NTP_4_2_7P238 + + scripts/ntp-wait.1ntp-waitmdoc@1.54 +2 -2 + NTP_4_2_7P238 + + scripts/ntp-wait.html@1.58 +1 -1 + NTP_4_2_7P238 + + scripts/ntp-wait.man.in@1.54 +2 -2 + NTP_4_2_7P238 + + scripts/ntp-wait.mdoc.in@1.54 +2 -2 + NTP_4_2_7P238 + + sntp/sntp-opts.c@1.236 +3 -3 + NTP_4_2_7P238 + + sntp/sntp-opts.h@1.236 +3 -3 + NTP_4_2_7P238 + + sntp/sntp-opts.texi@1.236 +2 -2 + NTP_4_2_7P238 + + sntp/sntp.1sntpman@1.56 +2 -2 + NTP_4_2_7P238 + + sntp/sntp.1sntpmdoc@1.56 +2 -2 + NTP_4_2_7P238 + + sntp/sntp.html@1.236 +2 -2 + NTP_4_2_7P238 + + sntp/sntp.man.in@1.56 +2 -2 + NTP_4_2_7P238 + + sntp/sntp.mdoc.in@1.56 +2 -2 + NTP_4_2_7P238 + + util/ntp-keygen-opts.c@1.240 +3 -3 + NTP_4_2_7P238 + + util/ntp-keygen-opts.h@1.240 +3 -3 + NTP_4_2_7P238 + + util/ntp-keygen-opts.texi@1.241 +2 -2 + NTP_4_2_7P238 + + util/ntp-keygen.1ntp-keygenman@1.54 +2 -2 + NTP_4_2_7P238 + + util/ntp-keygen.1ntp-keygenmdoc@1.54 +2 -2 + NTP_4_2_7P238 + + util/ntp-keygen.man.in@1.54 +2 -2 + NTP_4_2_7P238 + + util/ntp-keygen.mdoc.in@1.54 +2 -2 + NTP_4_2_7P238 + +ChangeSet@1.2082.4.257, 2011-12-08 21:09:05-05:00, stenn@deacon.udel.edu + NTP_4_2_6P5_RC3 + TAG: NTP_4_2_6P5_RC3 + + ChangeLog@1.496.26.184 +1 -0 + NTP_4_2_6P5_RC3 + + ntpd/ntpd-opts.c@1.248.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpd/ntpd-opts.h@1.248.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpd/ntpd-opts.texi@1.246.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + ntpd/ntpd.1@1.246.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + ntpdc/ntpdc-opts.c@1.244.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpdc/ntpdc-opts.h@1.244.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpdc/ntpdc-opts.texi@1.243.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + ntpdc/ntpdc.1@1.243.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + ntpq/ntpq-opts.c@1.245.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpq/ntpq-opts.h@1.245.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpq/ntpq-opts.texi@1.244.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + ntpq/ntpq.1@1.244.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.43.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.43.1 +3 -3 + NTP_4_2_6P5_RC3 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.42.1 +2 -2 + NTP_4_2_6P5_RC3 + + ntpsnmpd/ntpsnmpd.1@1.122.42.1 +2 -2 + NTP_4_2_6P5_RC3 + + packageinfo.sh@1.255.39.1 +1 -1 + NTP_4_2_6P5_RC3 + + sntp/sntp-opts.c@1.117.41.1 +3 -3 + NTP_4_2_6P5_RC3 + + sntp/sntp-opts.h@1.117.41.1 +3 -3 + NTP_4_2_6P5_RC3 + + sntp/sntp-opts.texi@1.117.40.1 +2 -2 + NTP_4_2_6P5_RC3 + + sntp/sntp.1@1.117.40.1 +2 -2 + NTP_4_2_6P5_RC3 + + sntp/sntp.html@1.7.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + util/ntp-keygen-opts.c@1.247.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + util/ntp-keygen-opts.h@1.247.42.1 +3 -3 + NTP_4_2_6P5_RC3 + + util/ntp-keygen-opts.texi@1.246.41.1 +2 -2 + NTP_4_2_6P5_RC3 + + util/ntp-keygen.1@1.246.41.1 +2 -2 + NTP_4_2_6P5_RC3 + +ChangeSet@1.2082.4.256, 2011-12-08 00:21:36-05:00, stenn@deacon.udel.edu + Update NEWS for RC3 + + NEWS@1.122.1.2 +6 -1 + Update NEWS for RC3 + +ChangeSet@1.2716, 2011-12-07 23:17:43+00:00, davehart@shiny.ad.hartbrothers.com + Correct ChangeLog merge to duplicate -stable entries in -dev section. + + ChangeLog@1.1068 +6 -0 + Correct ChangeLog merge to duplicate -stable entries in -dev section. + +ChangeSet@1.2082.4.255, 2011-12-07 22:28:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2087] sys_jitter calculation overweights sys.peer jitter. + + ChangeLog@1.496.26.183 +1 -0 + [Bug 2087] sys_jitter calculation overweights sys.peer jitter. + + ntpd/ntp_proto.c@1.297.2.10 +2 -2 + [Bug 2087] sys_jitter calculation overweights sys.peer jitter. + +ChangeSet@1.2082.4.254, 2011-12-07 22:24:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2086] get_systime() should not offset by sys_residual. + + ChangeLog@1.496.26.182 +1 -0 + [Bug 2086] get_systime() should not offset by sys_residual. + + libntp/systime.c@1.48.1.1 +2 -2 + [Bug 2086] get_systime() should not offset by sys_residual. + +ChangeSet@1.2082.4.253, 2011-12-07 22:21:41+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2085] clock_update() sys_rootdisp calculation omits root delay. + + ChangeLog@1.496.26.181 +1 -0 + [Bug 2085] clock_update() sys_rootdisp calculation omits root delay. + + ntpd/ntp_proto.c@1.297.2.9 +2 -1 + [Bug 2085] clock_update() sys_rootdisp calculation omits root delay. + +ChangeSet@1.2082.4.252, 2011-12-05 17:07:40+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2082] 3-char refid sent by ntpd 4.2.6p5-RC2 ends with extra dot. + Ensure NULL peer->dstadr is not accessed in orphan parent selection. + + ChangeLog@1.496.26.180 +5 -0 + [Bug 2082] 3-char refid sent by ntpd 4.2.6p5-RC2 ends with extra dot. + Ensure NULL peer->dstadr is not accessed in orphan parent selection. + + ntpd/ntp_control.c@1.129.1.8 +2 -1 + [Bug 2082] 3-char refid sent by ntpd 4.2.6p5-RC2 ends with extra dot. + + ntpd/ntp_proto.c@1.297.2.8 +4 -1 + Ensure NULL peer->dstadr is not accessed in orphan parent selection. + +ChangeSet@1.2713, 2011-12-01 05:30:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P237 + TAG: NTP_4_2_7P237 + + ChangeLog@1.1065 +1 -0 + NTP_4_2_7P237 + + ntpd/ntpd-opts.c@1.242 +3 -3 + NTP_4_2_7P237 + + ntpd/ntpd-opts.h@1.242 +3 -3 + NTP_4_2_7P237 + + ntpd/ntpd-opts.texi@1.240 +2 -2 + NTP_4_2_7P237 + + ntpd/ntpd.1ntpdman@1.53 +2 -2 + NTP_4_2_7P237 + + ntpd/ntpd.1ntpdmdoc@1.53 +2 -2 + NTP_4_2_7P237 + + ntpd/ntpd.man.in@1.53 +2 -2 + NTP_4_2_7P237 + + ntpd/ntpd.mdoc.in@1.53 +2 -2 + NTP_4_2_7P237 + + ntpdc/ntpdc-opts.c@1.237 +3 -3 + NTP_4_2_7P237 + + ntpdc/ntpdc-opts.h@1.237 +3 -3 + NTP_4_2_7P237 + + ntpdc/ntpdc-opts.texi@1.237 +2 -2 + NTP_4_2_7P237 + + ntpdc/ntpdc.1ntpdcman@1.53 +2 -2 + NTP_4_2_7P237 + + ntpdc/ntpdc.1ntpdcmdoc@1.53 +2 -2 + NTP_4_2_7P237 + + ntpdc/ntpdc.html@1.65 +2 -2 + NTP_4_2_7P237 + + ntpdc/ntpdc.man.in@1.53 +2 -2 + NTP_4_2_7P237 + + ntpdc/ntpdc.mdoc.in@1.53 +2 -2 + NTP_4_2_7P237 + + ntpq/ntpq-opts.c@1.239 +3 -3 + NTP_4_2_7P237 + + ntpq/ntpq-opts.h@1.239 +3 -3 + NTP_4_2_7P237 + + ntpq/ntpq-opts.texi@1.239 +2 -2 + NTP_4_2_7P237 + + ntpq/ntpq.1ntpqman@1.53 +2 -2 + NTP_4_2_7P237 + + ntpq/ntpq.1ntpqmdoc@1.53 +2 -2 + NTP_4_2_7P237 + + ntpq/ntpq.man.in@1.53 +2 -2 + NTP_4_2_7P237 + + ntpq/ntpq.mdoc.in@1.53 +2 -2 + NTP_4_2_7P237 + + ntpsnmpd/ntpsnmpd-opts.c@1.239 +3 -3 + NTP_4_2_7P237 + + ntpsnmpd/ntpsnmpd-opts.h@1.239 +3 -3 + NTP_4_2_7P237 + + ntpsnmpd/ntpsnmpd-opts.texi@1.239 +2 -2 + NTP_4_2_7P237 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.53 +2 -2 + NTP_4_2_7P237 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.53 +2 -2 + NTP_4_2_7P237 + + ntpsnmpd/ntpsnmpd.man.in@1.53 +2 -2 + NTP_4_2_7P237 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.53 +2 -2 + NTP_4_2_7P237 + + packageinfo.sh@1.240 +1 -1 + NTP_4_2_7P237 + + scripts/ntp-wait-opts.texi@1.57 +1 -1 + NTP_4_2_7P237 + + scripts/ntp-wait.1ntp-waitman@1.53 +2 -2 + NTP_4_2_7P237 + + scripts/ntp-wait.1ntp-waitmdoc@1.53 +2 -2 + NTP_4_2_7P237 + + scripts/ntp-wait.html@1.57 +1 -1 + NTP_4_2_7P237 + + scripts/ntp-wait.man.in@1.53 +2 -2 + NTP_4_2_7P237 + + scripts/ntp-wait.mdoc.in@1.53 +2 -2 + NTP_4_2_7P237 + + sntp/sntp-opts.c@1.235 +3 -3 + NTP_4_2_7P237 + + sntp/sntp-opts.h@1.235 +3 -3 + NTP_4_2_7P237 + + sntp/sntp-opts.texi@1.235 +2 -2 + NTP_4_2_7P237 + + sntp/sntp.1sntpman@1.55 +2 -2 + NTP_4_2_7P237 + + sntp/sntp.1sntpmdoc@1.55 +2 -2 + NTP_4_2_7P237 + + sntp/sntp.html@1.235 +2 -2 + NTP_4_2_7P237 + + sntp/sntp.man.in@1.55 +2 -2 + NTP_4_2_7P237 + + sntp/sntp.mdoc.in@1.55 +2 -2 + NTP_4_2_7P237 + + util/ntp-keygen-opts.c@1.239 +3 -3 + NTP_4_2_7P237 + + util/ntp-keygen-opts.h@1.239 +3 -3 + NTP_4_2_7P237 + + util/ntp-keygen-opts.texi@1.240 +2 -2 + NTP_4_2_7P237 + + util/ntp-keygen.1ntp-keygenman@1.53 +2 -2 + NTP_4_2_7P237 + + util/ntp-keygen.1ntp-keygenmdoc@1.53 +2 -2 + NTP_4_2_7P237 + + util/ntp-keygen.man.in@1.53 +2 -2 + NTP_4_2_7P237 + + util/ntp-keygen.mdoc.in@1.53 +2 -2 + NTP_4_2_7P237 + +ChangeSet@1.2082.4.251, 2011-11-30 22:06:41-05:00, stenn@deacon.udel.edu + NTP_4_2_6P5_RC2 + TAG: NTP_4_2_6P5_RC2 + + ChangeLog@1.496.26.179 +1 -0 + NTP_4_2_6P5_RC2 + + ntpd/ntpd-opts.c@1.248.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpd/ntpd-opts.h@1.248.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpd/ntpd-opts.texi@1.246.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + ntpd/ntpd.1@1.246.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + ntpdc/ntpdc-opts.c@1.244.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpdc/ntpdc-opts.h@1.244.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpdc/ntpdc-opts.texi@1.243.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + ntpdc/ntpdc.1@1.243.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + ntpq/ntpq-opts.c@1.245.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpq/ntpq-opts.h@1.245.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpq/ntpq-opts.texi@1.244.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + ntpq/ntpq.1@1.244.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.42.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.42.1 +3 -3 + NTP_4_2_6P5_RC2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.41.1 +2 -2 + NTP_4_2_6P5_RC2 + + ntpsnmpd/ntpsnmpd.1@1.122.41.1 +2 -2 + NTP_4_2_6P5_RC2 + + packageinfo.sh@1.255.38.1 +1 -1 + NTP_4_2_6P5_RC2 + + sntp/sntp-opts.c@1.117.40.1 +3 -3 + NTP_4_2_6P5_RC2 + + sntp/sntp-opts.h@1.117.40.1 +3 -3 + NTP_4_2_6P5_RC2 + + sntp/sntp-opts.texi@1.117.39.1 +2 -2 + NTP_4_2_6P5_RC2 + + sntp/sntp.1@1.117.39.1 +2 -2 + NTP_4_2_6P5_RC2 + + sntp/sntp.html@1.7.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + util/ntp-keygen-opts.c@1.247.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + util/ntp-keygen-opts.h@1.247.41.1 +3 -3 + NTP_4_2_6P5_RC2 + + util/ntp-keygen-opts.texi@1.246.40.1 +2 -2 + NTP_4_2_6P5_RC2 + + util/ntp-keygen.1@1.246.40.1 +2 -2 + NTP_4_2_6P5_RC2 + +ChangeSet@1.2082.4.250, 2011-11-30 21:49:45-05:00, stenn@pogo.udel.edu + update + + NEWS@1.122.1.1 +20 -5 + update + +ChangeSet@1.2711, 2011-11-30 04:00:32+00:00, davehart@shiny.ad.hartbrothers.com + Floor calculation of sys_rootdisp at sys_mindisp in clock_update (from + Dave Mills). + + ChangeLog@1.1063 +2 -0 + Floor calculation of sys_rootdisp at sys_mindisp in clock_update (from + Dave Mills). + + ntpd/ntp_proto.c@1.332 +6 -3 + Floor calculation of sys_rootdisp at sys_mindisp in clock_update (from + Dave Mills). + +ChangeSet@1.2709, 2011-11-29 21:58:49+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2073] Correct ntpq billboard's MODE_PASSIVE t from 'u' to 'S'. + Round l_fp traffic interval when converting to integer in rate limit + and KoD calculation. + + ChangeLog@1.1061 +4 -1 + [Bug 2073] Correct ntpq billboard's MODE_PASSIVE t from 'u' to 'S'. + Round l_fp traffic interval when converting to integer in rate limit + and KoD calculation. + + include/ntp.h@1.201 +1 -1 + MDF_UCLNT indicates preemptible, not ephemeral (comment fix). + + ntpd/ntp_monitor.c@1.40 +5 -1 + Round l_fp traffic interval when converting to integer in rate limit + and KoD calculation. + + ntpd/ntp_peer.c@1.151 +20 -2 + provide debug trace output of newpeer()/findexistingpeer() search + for duplicate associations. + + ntpd/ntp_proto.c@1.330 +12 -10 + Avoid duplicate "no servers found". + + ntpq/ntpq-subs.c@1.95 +6 -2 + [Bug 2073] Correct ntpq billboard's MODE_PASSIVE t from 'u' to 'S'. + +ChangeSet@1.2082.4.249, 2011-11-29 13:35:16+00:00, davehart@shiny.ad.hartbrothers.com + merge cleanup + + ChangeLog@1.496.26.178 +0 -1 + merge cleanup + +ChangeSet@1.2082.47.2, 2011-11-29 13:33:26+00:00, davehart@shiny.ad.hartbrothers.com + Never send KoD rate limiting response to MODE_SERVER response. + + ChangeLog@1.496.61.2 +3 -1 + Never send KoD rate limiting response to MODE_SERVER response. + + ntpd/ntp_crypto.c@1.146.1.1 +1 -1 + Use () to enforce intended precendence of & and && operators + + ntpd/ntp_proto.c@1.297.3.2 +3 -3 + Never send KoD rate limiting response to MODE_SERVER response. + +ChangeSet@1.2082.48.2, 2011-11-27 00:39:11+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2072] Orphan parent selection metric needs ntohl(). + + ChangeLog@1.496.62.1 +1 -0 + [Bug 2072] Orphan parent selection metric needs ntohl(). + + libntp/a_md5encrypt.c@1.26.1.2 +1 -0 + [Bug 2072] Orphan parent selection metric needs ntohl(). + + ntpd/ntp_proto.c@1.297.4.1 +3 -3 + [Bug 2072] Orphan parent selection metric needs ntohl(). + +ChangeSet@1.2707, 2011-11-26 23:06:48+00:00, davehart@shiny.ad.hartbrothers.com + more merge cleanup + + include/lib_strbuf.h@1.11 +4 -0 + guard against multiple inclusion (more merge cleanup) + + include/ntp_fp.h@1.26 +1 -1 + more merge cleanup + + include/ntp_types.h@1.30 +11 -11 + more merge cleanup + +ChangeSet@1.2082.48.1, 2011-11-26 19:43:12+00:00, davehart@shiny.ad.hartbrothers.com + Avoid redefinition warnings for INT32_MIN, INT32_MAX, U_INT32_MAX. + + include/ntp_types.h@1.14.1.3 +18 -6 + Avoid redefinition warnings for INT32_MIN, INT32_MAX, U_INT32_MAX. + +ChangeSet@1.2705, 2011-11-26 12:50:07+00:00, davehart@shiny.ad.hartbrothers.com + Restore 4.2.6 clock_combine() weighting to ntp-dev, reverting + to pre-4.2.7p70 logic and avoiding divide-by-zero (from Dave Mills). + + ChangeLog@1.1059 +3 -1 + Restore 4.2.6 clock_combine() weighting to ntp-dev, reverting + to pre-4.2.7p70 logic and avoiding divide-by-zero (from Dave Mills). + + ntpd/ntp_proto.c@1.328 +5 -5 + Restore 4.2.6 clock_combine() weighting to ntp-dev, reverting + to pre-4.2.7p70 logic and avoiding divide-by-zero (from Dave Mills). + +ChangeSet@1.2704, 2011-11-26 12:11:56+00:00, davehart@shiny.ad.hartbrothers.com + merge cleanup + + ntpd/ntp_control.c@1.176 +6 -6 + merge cleanup + + ntpd/ntp_io.c@1.363 +0 -11 + merge cleanup + + ntpd/ntp_peer.c@1.150 +6 -4 + merge cleanup + + ntpd/ntp_proto.c@1.327 +1 -1 + merge cleanup + + ntpq/ntpq-subs.c@1.94 +28 -18 + merge cleanup + + ntpq/ntpq.c@1.143 +3 -3 + merge cleanup + + ntpq/ntpq.h@1.26 +2 -2 + merge cleanup + +ChangeSet@1.2082.47.1, 2011-11-25 10:23:58+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2059] optional billboard column "server" does not honor -n. + [Bug 2066] ntpq lopeers ipv6 "local" column overrun. + [Bug 2068] ntpd sends nonprintable stratum 16 refid to ntpq. + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + Exclude not-yet-determined sys_refid from use in loopback TEST12 + (from David Mills). + + ChangeLog@1.496.61.1 +9 -0 + [Bug 2059] optional billboard column "server" does not honor -n. + [Bug 2066] ntpq lopeers ipv6 "local" column overrun. + [Bug 2068] ntpd sends nonprintable stratum 16 refid to ntpq. + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + Exclude not-yet-determined sys_refid from use in loopback TEST12 + (from David Mills). + + include/ntp.h@1.168.1.7 +1 -0 + Add peer flag FLAG_BC_VOL indicating the broadcastclient delay + calibration is still in progress. + + include/ntp_refclock.h@1.24.1.2 +1 -1 + [Bug 2068] ntpd sends nonprintable stratum 16 refid to ntpq. + + include/ntp_request.h@1.40.1.1 +2 -2 + [Bug 2068] ntpd sends nonprintable stratum 16 refid to ntpq. + + include/ntpd.h@1.137.2.7 +3 -1 + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + backport latoa() -> localaddrtoa(endpt *) from 4.2.7 + + ntpd/ntp_config.c@1.241.1.10 +1 -1 + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + + ntpd/ntp_control.c@1.129.1.7 +50 -37 + [Bug 2068] ntpd sends nonprintable stratum 16 refid to ntpq. + + ntpd/ntp_io.c@1.306.1.17 +11 -0 + backport latoa() -> localaddrtoa(endpt *) from 4.2.7 + + ntpd/ntp_peer.c@1.126.1.4 +40 -21 + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + + ntpd/ntp_proto.c@1.297.3.1 +53 -14 + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + Exclude not-yet-determined sys_refid from use in loopback TEST12 + (from David Mills). + + ntpd/ntp_refclock.c@1.92.1.3 +2 -2 + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + + ntpd/ntp_request.c@1.82.1.6 +13 -11 + [Bug 2069] broadcastclient, multicastclient spin up duplicate + ephemeral associations without broadcastdelay. + + ntpq/ntpq-subs.c@1.39.2.6 +42 -22 + [Bug 2059] optional billboard column "server" does not honor -n. + [Bug 2066] ntpq lopeers ipv6 "local" column overrun. + + ntpq/ntpq.c@1.97.1.10 +94 -9 + [Bug 2059] optional billboard column "server" does not honor -n. + + ntpq/ntpq.h@1.10.1.5 +4 -0 + [Bug 2059] optional billboard column "server" does not honor -n. + [Bug 2066] ntpq lopeers ipv6 "local" column overrun. + +ChangeSet@1.2082.4.244, 2011-11-21 09:35:28+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2050] Orphan mode stratum counting to infinity. + + ChangeLog@1.496.26.174 +4 -0 + [Bug 2050] Orphan mode stratum counting to infinity. + + include/ntp_types.h@1.14.1.2 +6 -0 + [Bug 2050] Orphan mode stratum counting to infinity. + + ntpd/ntp_proto.c@1.297.2.4 +31 -8 + [Bug 2050] Orphan mode stratum counting to infinity. + + ntpd/ntp_timer.c@1.56.1.1 +2 -2 + [Bug 2050] Orphan mode stratum counting to infinity. + +ChangeSet@1.2702, 2011-11-16 10:47:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P236 + TAG: NTP_4_2_7P236 + + ChangeLog@1.1057 +1 -0 + NTP_4_2_7P236 + + ntpd/ntpd-opts.c@1.241 +3 -3 + NTP_4_2_7P236 + + ntpd/ntpd-opts.h@1.241 +3 -3 + NTP_4_2_7P236 + + ntpd/ntpd-opts.texi@1.239 +2 -2 + NTP_4_2_7P236 + + ntpd/ntpd.1ntpdman@1.52 +2 -2 + NTP_4_2_7P236 + + ntpd/ntpd.1ntpdmdoc@1.52 +1 -1 + NTP_4_2_7P236 + + ntpd/ntpd.man.in@1.52 +2 -2 + NTP_4_2_7P236 + + ntpd/ntpd.mdoc.in@1.52 +1 -1 + NTP_4_2_7P236 + + ntpdc/ntpdc-opts.c@1.236 +3 -3 + NTP_4_2_7P236 + + ntpdc/ntpdc-opts.h@1.236 +3 -3 + NTP_4_2_7P236 + + ntpdc/ntpdc-opts.texi@1.236 +2 -2 + NTP_4_2_7P236 + + ntpdc/ntpdc.1ntpdcman@1.52 +2 -2 + NTP_4_2_7P236 + + ntpdc/ntpdc.1ntpdcmdoc@1.52 +1 -1 + NTP_4_2_7P236 + + ntpdc/ntpdc.html@1.64 +2 -2 + NTP_4_2_7P236 + + ntpdc/ntpdc.man.in@1.52 +2 -2 + NTP_4_2_7P236 + + ntpdc/ntpdc.mdoc.in@1.52 +1 -1 + NTP_4_2_7P236 + + ntpq/ntpq-opts.c@1.238 +3 -3 + NTP_4_2_7P236 + + ntpq/ntpq-opts.h@1.238 +3 -3 + NTP_4_2_7P236 + + ntpq/ntpq-opts.texi@1.238 +2 -2 + NTP_4_2_7P236 + + ntpq/ntpq.1ntpqman@1.52 +2 -2 + NTP_4_2_7P236 + + ntpq/ntpq.1ntpqmdoc@1.52 +1 -1 + NTP_4_2_7P236 + + ntpq/ntpq.man.in@1.52 +2 -2 + NTP_4_2_7P236 + + ntpq/ntpq.mdoc.in@1.52 +1 -1 + NTP_4_2_7P236 + + ntpsnmpd/ntpsnmpd-opts.c@1.238 +3 -3 + NTP_4_2_7P236 + + ntpsnmpd/ntpsnmpd-opts.h@1.238 +3 -3 + NTP_4_2_7P236 + + ntpsnmpd/ntpsnmpd-opts.texi@1.238 +2 -2 + NTP_4_2_7P236 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.52 +2 -2 + NTP_4_2_7P236 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.52 +1 -1 + NTP_4_2_7P236 + + ntpsnmpd/ntpsnmpd.man.in@1.52 +2 -2 + NTP_4_2_7P236 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.52 +1 -1 + NTP_4_2_7P236 + + packageinfo.sh@1.239 +1 -1 + NTP_4_2_7P236 + + scripts/ntp-wait-opts.texi@1.56 +1 -1 + NTP_4_2_7P236 + + scripts/ntp-wait.1ntp-waitman@1.52 +2 -2 + NTP_4_2_7P236 + + scripts/ntp-wait.1ntp-waitmdoc@1.52 +1 -1 + NTP_4_2_7P236 + + scripts/ntp-wait.html@1.56 +1 -1 + NTP_4_2_7P236 + + scripts/ntp-wait.man.in@1.52 +2 -2 + NTP_4_2_7P236 + + scripts/ntp-wait.mdoc.in@1.52 +1 -1 + NTP_4_2_7P236 + + sntp/sntp-opts.c@1.234 +3 -3 + NTP_4_2_7P236 + + sntp/sntp-opts.h@1.234 +3 -3 + NTP_4_2_7P236 + + sntp/sntp-opts.texi@1.234 +2 -2 + NTP_4_2_7P236 + + sntp/sntp.1sntpman@1.54 +2 -2 + NTP_4_2_7P236 + + sntp/sntp.1sntpmdoc@1.54 +1 -1 + NTP_4_2_7P236 + + sntp/sntp.html@1.234 +2 -2 + NTP_4_2_7P236 + + sntp/sntp.man.in@1.54 +2 -2 + NTP_4_2_7P236 + + sntp/sntp.mdoc.in@1.54 +1 -1 + NTP_4_2_7P236 + + util/ntp-keygen-opts.c@1.238 +3 -3 + NTP_4_2_7P236 + + util/ntp-keygen-opts.h@1.238 +3 -3 + NTP_4_2_7P236 + + util/ntp-keygen-opts.texi@1.239 +2 -2 + NTP_4_2_7P236 + + util/ntp-keygen.1ntp-keygenman@1.52 +2 -2 + NTP_4_2_7P236 + + util/ntp-keygen.1ntp-keygenmdoc@1.52 +1 -1 + NTP_4_2_7P236 + + util/ntp-keygen.man.in@1.52 +2 -2 + NTP_4_2_7P236 + + util/ntp-keygen.mdoc.in@1.52 +1 -1 + NTP_4_2_7P236 + +ChangeSet@1.2701, 2011-11-16 00:27:58-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1056 +1 -0 + Documentation updates from Dave Mills + + html/index.html@1.44 +8 -8 + Documentation updates from Dave Mills + + html/rate.html@1.10 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2700, 2011-11-16 03:15:06+00:00, stenn@deacon.udel.edu + NTP_4_2_7P235 + TAG: NTP_4_2_7P235 + + ChangeLog@1.1055 +1 -0 + NTP_4_2_7P235 + + ntpd/ntpd-opts.c@1.240 +3 -3 + NTP_4_2_7P235 + + ntpd/ntpd-opts.h@1.240 +3 -3 + NTP_4_2_7P235 + + ntpd/ntpd-opts.texi@1.238 +2 -2 + NTP_4_2_7P235 + + ntpd/ntpd.1ntpdman@1.51 +2 -2 + NTP_4_2_7P235 + + ntpd/ntpd.1ntpdmdoc@1.51 +2 -2 + NTP_4_2_7P235 + + ntpd/ntpd.man.in@1.51 +2 -2 + NTP_4_2_7P235 + + ntpd/ntpd.mdoc.in@1.51 +2 -2 + NTP_4_2_7P235 + + ntpdc/ntpdc-opts.c@1.235 +3 -3 + NTP_4_2_7P235 + + ntpdc/ntpdc-opts.h@1.235 +3 -3 + NTP_4_2_7P235 + + ntpdc/ntpdc-opts.texi@1.235 +2 -2 + NTP_4_2_7P235 + + ntpdc/ntpdc.1ntpdcman@1.51 +2 -2 + NTP_4_2_7P235 + + ntpdc/ntpdc.1ntpdcmdoc@1.51 +2 -2 + NTP_4_2_7P235 + + ntpdc/ntpdc.html@1.63 +2 -2 + NTP_4_2_7P235 + + ntpdc/ntpdc.man.in@1.51 +2 -2 + NTP_4_2_7P235 + + ntpdc/ntpdc.mdoc.in@1.51 +2 -2 + NTP_4_2_7P235 + + ntpq/ntpq-opts.c@1.237 +3 -3 + NTP_4_2_7P235 + + ntpq/ntpq-opts.h@1.237 +3 -3 + NTP_4_2_7P235 + + ntpq/ntpq-opts.texi@1.237 +2 -2 + NTP_4_2_7P235 + + ntpq/ntpq.1ntpqman@1.51 +2 -2 + NTP_4_2_7P235 + + ntpq/ntpq.1ntpqmdoc@1.51 +2 -2 + NTP_4_2_7P235 + + ntpq/ntpq.man.in@1.51 +2 -2 + NTP_4_2_7P235 + + ntpq/ntpq.mdoc.in@1.51 +2 -2 + NTP_4_2_7P235 + + ntpsnmpd/ntpsnmpd-opts.c@1.237 +3 -3 + NTP_4_2_7P235 + + ntpsnmpd/ntpsnmpd-opts.h@1.237 +3 -3 + NTP_4_2_7P235 + + ntpsnmpd/ntpsnmpd-opts.texi@1.237 +2 -2 + NTP_4_2_7P235 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.51 +2 -2 + NTP_4_2_7P235 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.51 +2 -2 + NTP_4_2_7P235 + + ntpsnmpd/ntpsnmpd.man.in@1.51 +2 -2 + NTP_4_2_7P235 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.51 +2 -2 + NTP_4_2_7P235 + + packageinfo.sh@1.238 +1 -1 + NTP_4_2_7P235 + + scripts/ntp-wait-opts.texi@1.55 +1 -1 + NTP_4_2_7P235 + + scripts/ntp-wait.1ntp-waitman@1.51 +2 -2 + NTP_4_2_7P235 + + scripts/ntp-wait.1ntp-waitmdoc@1.51 +2 -2 + NTP_4_2_7P235 + + scripts/ntp-wait.html@1.55 +1 -1 + NTP_4_2_7P235 + + scripts/ntp-wait.man.in@1.51 +2 -2 + NTP_4_2_7P235 + + scripts/ntp-wait.mdoc.in@1.51 +2 -2 + NTP_4_2_7P235 + + sntp/sntp-opts.c@1.233 +3 -3 + NTP_4_2_7P235 + + sntp/sntp-opts.h@1.233 +3 -3 + NTP_4_2_7P235 + + sntp/sntp-opts.texi@1.233 +2 -2 + NTP_4_2_7P235 + + sntp/sntp.1sntpman@1.53 +2 -2 + NTP_4_2_7P235 + + sntp/sntp.1sntpmdoc@1.53 +2 -2 + NTP_4_2_7P235 + + sntp/sntp.html@1.233 +2 -2 + NTP_4_2_7P235 + + sntp/sntp.man.in@1.53 +2 -2 + NTP_4_2_7P235 + + sntp/sntp.mdoc.in@1.53 +2 -2 + NTP_4_2_7P235 + + util/ntp-keygen-opts.c@1.237 +3 -3 + NTP_4_2_7P235 + + util/ntp-keygen-opts.h@1.237 +3 -3 + NTP_4_2_7P235 + + util/ntp-keygen-opts.texi@1.238 +2 -2 + NTP_4_2_7P235 + + util/ntp-keygen.1ntp-keygenman@1.51 +2 -2 + NTP_4_2_7P235 + + util/ntp-keygen.1ntp-keygenmdoc@1.51 +2 -2 + NTP_4_2_7P235 + + util/ntp-keygen.man.in@1.51 +2 -2 + NTP_4_2_7P235 + + util/ntp-keygen.mdoc.in@1.51 +2 -2 + NTP_4_2_7P235 + +ChangeSet@1.2699, 2011-11-08 18:44:39+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2052] Autokey CRYPTO_ASSOC host@group vallen needs checking. + + ChangeLog@1.1054 +1 -0 + [Bug 2052] Autokey CRYPTO_ASSOC host@group vallen needs checking. + + ntpd/ntp_proto.c@1.325 +27 -18 + [Bug 2052] Autokey CRYPTO_ASSOC host@group vallen needs checking. + Fix a number of comment typos. + +ChangeSet@1.2698, 2011-11-07 23:09:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P234 + TAG: NTP_4_2_7P234 + + ChangeLog@1.1053 +1 -0 + NTP_4_2_7P234 + + ntpd/ntpd-opts.c@1.239 +3 -3 + NTP_4_2_7P234 + + ntpd/ntpd-opts.h@1.239 +3 -3 + NTP_4_2_7P234 + + ntpd/ntpd-opts.texi@1.237 +2 -2 + NTP_4_2_7P234 + + ntpd/ntpd.1ntpdman@1.50 +2 -2 + NTP_4_2_7P234 + + ntpd/ntpd.1ntpdmdoc@1.50 +2 -2 + NTP_4_2_7P234 + + ntpd/ntpd.man.in@1.50 +2 -2 + NTP_4_2_7P234 + + ntpd/ntpd.mdoc.in@1.50 +2 -2 + NTP_4_2_7P234 + + ntpdc/ntpdc-opts.c@1.234 +3 -3 + NTP_4_2_7P234 + + ntpdc/ntpdc-opts.h@1.234 +3 -3 + NTP_4_2_7P234 + + ntpdc/ntpdc-opts.texi@1.234 +2 -2 + NTP_4_2_7P234 + + ntpdc/ntpdc.1ntpdcman@1.50 +2 -2 + NTP_4_2_7P234 + + ntpdc/ntpdc.1ntpdcmdoc@1.50 +2 -2 + NTP_4_2_7P234 + + ntpdc/ntpdc.html@1.62 +2 -2 + NTP_4_2_7P234 + + ntpdc/ntpdc.man.in@1.50 +2 -2 + NTP_4_2_7P234 + + ntpdc/ntpdc.mdoc.in@1.50 +2 -2 + NTP_4_2_7P234 + + ntpq/ntpq-opts.c@1.236 +3 -3 + NTP_4_2_7P234 + + ntpq/ntpq-opts.h@1.236 +3 -3 + NTP_4_2_7P234 + + ntpq/ntpq-opts.texi@1.236 +2 -2 + NTP_4_2_7P234 + + ntpq/ntpq.1ntpqman@1.50 +2 -2 + NTP_4_2_7P234 + + ntpq/ntpq.1ntpqmdoc@1.50 +2 -2 + NTP_4_2_7P234 + + ntpq/ntpq.man.in@1.50 +2 -2 + NTP_4_2_7P234 + + ntpq/ntpq.mdoc.in@1.50 +2 -2 + NTP_4_2_7P234 + + ntpsnmpd/ntpsnmpd-opts.c@1.236 +3 -3 + NTP_4_2_7P234 + + ntpsnmpd/ntpsnmpd-opts.h@1.236 +3 -3 + NTP_4_2_7P234 + + ntpsnmpd/ntpsnmpd-opts.texi@1.236 +2 -2 + NTP_4_2_7P234 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.50 +2 -2 + NTP_4_2_7P234 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.50 +2 -2 + NTP_4_2_7P234 + + ntpsnmpd/ntpsnmpd.man.in@1.50 +2 -2 + NTP_4_2_7P234 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.50 +2 -2 + NTP_4_2_7P234 + + packageinfo.sh@1.237 +1 -1 + NTP_4_2_7P234 + + scripts/ntp-wait-opts.texi@1.54 +1 -1 + NTP_4_2_7P234 + + scripts/ntp-wait.1ntp-waitman@1.50 +2 -2 + NTP_4_2_7P234 + + scripts/ntp-wait.1ntp-waitmdoc@1.50 +2 -2 + NTP_4_2_7P234 + + scripts/ntp-wait.html@1.54 +1 -1 + NTP_4_2_7P234 + + scripts/ntp-wait.man.in@1.50 +2 -2 + NTP_4_2_7P234 + + scripts/ntp-wait.mdoc.in@1.50 +2 -2 + NTP_4_2_7P234 + + sntp/sntp-opts.c@1.232 +3 -3 + NTP_4_2_7P234 + + sntp/sntp-opts.h@1.232 +3 -3 + NTP_4_2_7P234 + + sntp/sntp-opts.texi@1.232 +2 -2 + NTP_4_2_7P234 + + sntp/sntp.1sntpman@1.52 +2 -2 + NTP_4_2_7P234 + + sntp/sntp.1sntpmdoc@1.52 +2 -2 + NTP_4_2_7P234 + + sntp/sntp.html@1.232 +2 -2 + NTP_4_2_7P234 + + sntp/sntp.man.in@1.52 +2 -2 + NTP_4_2_7P234 + + sntp/sntp.mdoc.in@1.52 +2 -2 + NTP_4_2_7P234 + + util/ntp-keygen-opts.c@1.236 +3 -3 + NTP_4_2_7P234 + + util/ntp-keygen-opts.h@1.236 +3 -3 + NTP_4_2_7P234 + + util/ntp-keygen-opts.texi@1.237 +2 -2 + NTP_4_2_7P234 + + util/ntp-keygen.1ntp-keygenman@1.50 +2 -2 + NTP_4_2_7P234 + + util/ntp-keygen.1ntp-keygenmdoc@1.50 +2 -2 + NTP_4_2_7P234 + + util/ntp-keygen.man.in@1.50 +2 -2 + NTP_4_2_7P234 + + util/ntp-keygen.mdoc.in@1.50 +2 -2 + NTP_4_2_7P234 + +ChangeSet@1.2697, 2011-11-07 01:54:46-05:00, stenn@deacon.udel.edu + LDADD cleanup + + libparse/Makefile.am@1.28 +2 -2 + LDADD cleanup + + ntpdc/Makefile.am@1.68 +1 -1 + LDADD cleanup + + ntpq/Makefile.am@1.64 +1 -1 + LDADD cleanup + +ChangeSet@1.2696, 2011-11-07 01:04:24-05:00, stenn@deacon.udel.edu + Clean up -libm entries regarding libntp.a + + ChangeLog@1.1052 +1 -0 + Clean up -libm entries regarding libntp.a + + adjtimed/Makefile.am@1.15 +1 -1 + Clean up -libm entries regarding libntp.a + + clockstuff/Makefile.am@1.21 +2 -2 + Clean up -libm entries regarding libntp.a + + libparse/Makefile.am@1.27 +2 -2 + Clean up -libm entries regarding libntp.a + + ntpd/Makefile.am@1.111 +3 -3 + Clean up -libm entries regarding libntp.a + + ntpdc/Makefile.am@1.67 +3 -2 + Clean up -libm entries regarding libntp.a + + ntpq/Makefile.am@1.63 +3 -2 + Clean up -libm entries regarding libntp.a + + parseutil/Makefile.am@1.17 +1 -1 + Clean up -libm entries regarding libntp.a + + sntp/Makefile.am@1.69 +1 -3 + Clean up -libm entries regarding libntp.a + + util/Makefile.am@1.67 +2 -2 + Clean up -libm entries regarding libntp.a + +ChangeSet@1.2695, 2011-11-06 11:16:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P233 + TAG: NTP_4_2_7P233 + + ChangeLog@1.1051 +1 -0 + NTP_4_2_7P233 + + ntpd/ntpd-opts.c@1.238 +3 -3 + NTP_4_2_7P233 + + ntpd/ntpd-opts.h@1.238 +3 -3 + NTP_4_2_7P233 + + ntpd/ntpd-opts.texi@1.236 +2 -2 + NTP_4_2_7P233 + + ntpd/ntpd.1ntpdman@1.49 +2 -2 + NTP_4_2_7P233 + + ntpd/ntpd.1ntpdmdoc@1.49 +2 -2 + NTP_4_2_7P233 + + ntpd/ntpd.man.in@1.49 +2 -2 + NTP_4_2_7P233 + + ntpd/ntpd.mdoc.in@1.49 +2 -2 + NTP_4_2_7P233 + + ntpdc/ntpdc-opts.c@1.233 +3 -3 + NTP_4_2_7P233 + + ntpdc/ntpdc-opts.h@1.233 +3 -3 + NTP_4_2_7P233 + + ntpdc/ntpdc-opts.texi@1.233 +2 -2 + NTP_4_2_7P233 + + ntpdc/ntpdc.1ntpdcman@1.49 +2 -2 + NTP_4_2_7P233 + + ntpdc/ntpdc.1ntpdcmdoc@1.49 +2 -2 + NTP_4_2_7P233 + + ntpdc/ntpdc.html@1.61 +2 -2 + NTP_4_2_7P233 + + ntpdc/ntpdc.man.in@1.49 +2 -2 + NTP_4_2_7P233 + + ntpdc/ntpdc.mdoc.in@1.49 +2 -2 + NTP_4_2_7P233 + + ntpq/ntpq-opts.c@1.235 +3 -3 + NTP_4_2_7P233 + + ntpq/ntpq-opts.h@1.235 +3 -3 + NTP_4_2_7P233 + + ntpq/ntpq-opts.texi@1.235 +2 -2 + NTP_4_2_7P233 + + ntpq/ntpq.1ntpqman@1.49 +2 -2 + NTP_4_2_7P233 + + ntpq/ntpq.1ntpqmdoc@1.49 +2 -2 + NTP_4_2_7P233 + + ntpq/ntpq.man.in@1.49 +2 -2 + NTP_4_2_7P233 + + ntpq/ntpq.mdoc.in@1.49 +2 -2 + NTP_4_2_7P233 + + ntpsnmpd/ntpsnmpd-opts.c@1.235 +3 -3 + NTP_4_2_7P233 + + ntpsnmpd/ntpsnmpd-opts.h@1.235 +3 -3 + NTP_4_2_7P233 + + ntpsnmpd/ntpsnmpd-opts.texi@1.235 +2 -2 + NTP_4_2_7P233 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.49 +2 -2 + NTP_4_2_7P233 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.49 +2 -2 + NTP_4_2_7P233 + + ntpsnmpd/ntpsnmpd.man.in@1.49 +2 -2 + NTP_4_2_7P233 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.49 +2 -2 + NTP_4_2_7P233 + + packageinfo.sh@1.236 +1 -1 + NTP_4_2_7P233 + + scripts/ntp-wait-opts.texi@1.53 +1 -1 + NTP_4_2_7P233 + + scripts/ntp-wait.1ntp-waitman@1.49 +2 -2 + NTP_4_2_7P233 + + scripts/ntp-wait.1ntp-waitmdoc@1.49 +2 -2 + NTP_4_2_7P233 + + scripts/ntp-wait.html@1.53 +1 -1 + NTP_4_2_7P233 + + scripts/ntp-wait.man.in@1.49 +2 -2 + NTP_4_2_7P233 + + scripts/ntp-wait.mdoc.in@1.49 +2 -2 + NTP_4_2_7P233 + + sntp/sntp-opts.c@1.231 +3 -3 + NTP_4_2_7P233 + + sntp/sntp-opts.h@1.231 +3 -3 + NTP_4_2_7P233 + + sntp/sntp-opts.texi@1.231 +2 -2 + NTP_4_2_7P233 + + sntp/sntp.1sntpman@1.51 +2 -2 + NTP_4_2_7P233 + + sntp/sntp.1sntpmdoc@1.51 +2 -2 + NTP_4_2_7P233 + + sntp/sntp.html@1.231 +2 -2 + NTP_4_2_7P233 + + sntp/sntp.man.in@1.51 +2 -2 + NTP_4_2_7P233 + + sntp/sntp.mdoc.in@1.51 +2 -2 + NTP_4_2_7P233 + + util/ntp-keygen-opts.c@1.235 +3 -3 + NTP_4_2_7P233 + + util/ntp-keygen-opts.h@1.235 +3 -3 + NTP_4_2_7P233 + + util/ntp-keygen-opts.texi@1.236 +2 -2 + NTP_4_2_7P233 + + util/ntp-keygen.1ntp-keygenman@1.49 +2 -2 + NTP_4_2_7P233 + + util/ntp-keygen.1ntp-keygenmdoc@1.49 +2 -2 + NTP_4_2_7P233 + + util/ntp-keygen.man.in@1.49 +2 -2 + NTP_4_2_7P233 + + util/ntp-keygen.mdoc.in@1.49 +2 -2 + NTP_4_2_7P233 + +ChangeSet@1.2694, 2011-11-06 01:37:19-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1050 +1 -0 + Documentation updates from Dave Mills + + html/discipline.html@1.7 +1 -1 + Documentation updates from Dave Mills + + html/miscopt.html@1.68 +5 -3 + Documentation updates from Dave Mills + + html/prefer.html@1.28 +28 -30 + Documentation updates from Dave Mills + +ChangeSet@1.2693, 2011-11-05 10:46:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P232 + TAG: NTP_4_2_7P232 + + ChangeLog@1.1049 +1 -0 + NTP_4_2_7P232 + + ntpd/ntpd-opts.c@1.237 +3 -3 + NTP_4_2_7P232 + + ntpd/ntpd-opts.h@1.237 +3 -3 + NTP_4_2_7P232 + + ntpd/ntpd-opts.texi@1.235 +2 -2 + NTP_4_2_7P232 + + ntpd/ntpd.1ntpdman@1.48 +2 -2 + NTP_4_2_7P232 + + ntpd/ntpd.1ntpdmdoc@1.48 +2 -2 + NTP_4_2_7P232 + + ntpd/ntpd.man.in@1.48 +2 -2 + NTP_4_2_7P232 + + ntpd/ntpd.mdoc.in@1.48 +2 -2 + NTP_4_2_7P232 + + ntpdc/ntpdc-opts.c@1.232 +3 -3 + NTP_4_2_7P232 + + ntpdc/ntpdc-opts.h@1.232 +3 -3 + NTP_4_2_7P232 + + ntpdc/ntpdc-opts.texi@1.232 +2 -2 + NTP_4_2_7P232 + + ntpdc/ntpdc.1ntpdcman@1.48 +2 -2 + NTP_4_2_7P232 + + ntpdc/ntpdc.1ntpdcmdoc@1.48 +2 -2 + NTP_4_2_7P232 + + ntpdc/ntpdc.html@1.60 +2 -2 + NTP_4_2_7P232 + + ntpdc/ntpdc.man.in@1.48 +2 -2 + NTP_4_2_7P232 + + ntpdc/ntpdc.mdoc.in@1.48 +2 -2 + NTP_4_2_7P232 + + ntpq/ntpq-opts.c@1.234 +3 -3 + NTP_4_2_7P232 + + ntpq/ntpq-opts.h@1.234 +3 -3 + NTP_4_2_7P232 + + ntpq/ntpq-opts.texi@1.234 +2 -2 + NTP_4_2_7P232 + + ntpq/ntpq.1ntpqman@1.48 +2 -2 + NTP_4_2_7P232 + + ntpq/ntpq.1ntpqmdoc@1.48 +2 -2 + NTP_4_2_7P232 + + ntpq/ntpq.man.in@1.48 +2 -2 + NTP_4_2_7P232 + + ntpq/ntpq.mdoc.in@1.48 +2 -2 + NTP_4_2_7P232 + + ntpsnmpd/ntpsnmpd-opts.c@1.234 +3 -3 + NTP_4_2_7P232 + + ntpsnmpd/ntpsnmpd-opts.h@1.234 +3 -3 + NTP_4_2_7P232 + + ntpsnmpd/ntpsnmpd-opts.texi@1.234 +2 -2 + NTP_4_2_7P232 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.48 +2 -2 + NTP_4_2_7P232 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.48 +2 -2 + NTP_4_2_7P232 + + ntpsnmpd/ntpsnmpd.man.in@1.48 +2 -2 + NTP_4_2_7P232 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.48 +2 -2 + NTP_4_2_7P232 + + packageinfo.sh@1.235 +1 -1 + NTP_4_2_7P232 + + scripts/ntp-wait-opts.texi@1.52 +1 -1 + NTP_4_2_7P232 + + scripts/ntp-wait.1ntp-waitman@1.48 +2 -2 + NTP_4_2_7P232 + + scripts/ntp-wait.1ntp-waitmdoc@1.48 +2 -2 + NTP_4_2_7P232 + + scripts/ntp-wait.html@1.52 +1 -1 + NTP_4_2_7P232 + + scripts/ntp-wait.man.in@1.48 +2 -2 + NTP_4_2_7P232 + + scripts/ntp-wait.mdoc.in@1.48 +2 -2 + NTP_4_2_7P232 + + sntp/sntp-opts.c@1.230 +3 -3 + NTP_4_2_7P232 + + sntp/sntp-opts.h@1.230 +3 -3 + NTP_4_2_7P232 + + sntp/sntp-opts.texi@1.230 +2 -2 + NTP_4_2_7P232 + + sntp/sntp.1sntpman@1.50 +2 -2 + NTP_4_2_7P232 + + sntp/sntp.1sntpmdoc@1.50 +2 -2 + NTP_4_2_7P232 + + sntp/sntp.html@1.230 +2 -2 + NTP_4_2_7P232 + + sntp/sntp.man.in@1.50 +2 -2 + NTP_4_2_7P232 + + sntp/sntp.mdoc.in@1.50 +2 -2 + NTP_4_2_7P232 + + util/ntp-keygen-opts.c@1.234 +3 -3 + NTP_4_2_7P232 + + util/ntp-keygen-opts.h@1.234 +3 -3 + NTP_4_2_7P232 + + util/ntp-keygen-opts.texi@1.235 +2 -2 + NTP_4_2_7P232 + + util/ntp-keygen.1ntp-keygenman@1.48 +2 -2 + NTP_4_2_7P232 + + util/ntp-keygen.1ntp-keygenmdoc@1.48 +2 -2 + NTP_4_2_7P232 + + util/ntp-keygen.man.in@1.48 +2 -2 + NTP_4_2_7P232 + + util/ntp-keygen.mdoc.in@1.48 +2 -2 + NTP_4_2_7P232 + +ChangeSet@1.2692, 2011-11-05 00:03:53-04:00, stenn@deacon.udel.edu + Clean up some bitrotted code in libntp/socket.c + + ChangeLog@1.1048 +1 -0 + Clean up some bitrotted code in libntp/socket.c + + libntp/socket.c@1.8 +2 -503 + Clean up some bitrotted code in libntp/socket.c + +ChangeSet@1.2691, 2011-11-05 00:01:22-04:00, stenn@deacon.udel.edu + Update the NEWS file so we note the default disable of mode 7 requests + + ChangeLog@1.1047 +1 -0 + Update the NEWS file so we note the default disable of mode 7 requests + + NEWS@1.124 +35 -0 + Update the NEWS file so we note the default disable of mode 7 requests + +ChangeSet@1.2690, 2011-11-03 19:28:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P231 + TAG: NTP_4_2_7P231 + + ChangeLog@1.1046 +1 -0 + NTP_4_2_7P231 + + ntpd/ntpd-opts.c@1.236 +3 -3 + NTP_4_2_7P231 + + ntpd/ntpd-opts.h@1.236 +3 -3 + NTP_4_2_7P231 + + ntpd/ntpd-opts.texi@1.234 +2 -2 + NTP_4_2_7P231 + + ntpd/ntpd.1ntpdman@1.47 +2 -2 + NTP_4_2_7P231 + + ntpd/ntpd.1ntpdmdoc@1.47 +2 -2 + NTP_4_2_7P231 + + ntpd/ntpd.man.in@1.47 +2 -2 + NTP_4_2_7P231 + + ntpd/ntpd.mdoc.in@1.47 +2 -2 + NTP_4_2_7P231 + + ntpdc/ntpdc-opts.c@1.231 +3 -3 + NTP_4_2_7P231 + + ntpdc/ntpdc-opts.h@1.231 +3 -3 + NTP_4_2_7P231 + + ntpdc/ntpdc-opts.texi@1.231 +2 -2 + NTP_4_2_7P231 + + ntpdc/ntpdc.1ntpdcman@1.47 +2 -2 + NTP_4_2_7P231 + + ntpdc/ntpdc.1ntpdcmdoc@1.47 +2 -2 + NTP_4_2_7P231 + + ntpdc/ntpdc.html@1.59 +2 -2 + NTP_4_2_7P231 + + ntpdc/ntpdc.man.in@1.47 +2 -2 + NTP_4_2_7P231 + + ntpdc/ntpdc.mdoc.in@1.47 +2 -2 + NTP_4_2_7P231 + + ntpq/ntpq-opts.c@1.233 +3 -3 + NTP_4_2_7P231 + + ntpq/ntpq-opts.h@1.233 +3 -3 + NTP_4_2_7P231 + + ntpq/ntpq-opts.texi@1.233 +2 -2 + NTP_4_2_7P231 + + ntpq/ntpq.1ntpqman@1.47 +2 -2 + NTP_4_2_7P231 + + ntpq/ntpq.1ntpqmdoc@1.47 +2 -2 + NTP_4_2_7P231 + + ntpq/ntpq.man.in@1.47 +2 -2 + NTP_4_2_7P231 + + ntpq/ntpq.mdoc.in@1.47 +2 -2 + NTP_4_2_7P231 + + ntpsnmpd/ntpsnmpd-opts.c@1.233 +3 -3 + NTP_4_2_7P231 + + ntpsnmpd/ntpsnmpd-opts.h@1.233 +3 -3 + NTP_4_2_7P231 + + ntpsnmpd/ntpsnmpd-opts.texi@1.233 +2 -2 + NTP_4_2_7P231 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.47 +2 -2 + NTP_4_2_7P231 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.47 +2 -2 + NTP_4_2_7P231 + + ntpsnmpd/ntpsnmpd.man.in@1.47 +2 -2 + NTP_4_2_7P231 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.47 +2 -2 + NTP_4_2_7P231 + + packageinfo.sh@1.234 +1 -1 + NTP_4_2_7P231 + + scripts/ntp-wait-opts.texi@1.51 +1 -1 + NTP_4_2_7P231 + + scripts/ntp-wait.1ntp-waitman@1.47 +2 -2 + NTP_4_2_7P231 + + scripts/ntp-wait.1ntp-waitmdoc@1.47 +2 -2 + NTP_4_2_7P231 + + scripts/ntp-wait.html@1.51 +1 -1 + NTP_4_2_7P231 + + scripts/ntp-wait.man.in@1.47 +2 -2 + NTP_4_2_7P231 + + scripts/ntp-wait.mdoc.in@1.47 +2 -2 + NTP_4_2_7P231 + + sntp/sntp-opts.c@1.229 +3 -3 + NTP_4_2_7P231 + + sntp/sntp-opts.h@1.229 +3 -3 + NTP_4_2_7P231 + + sntp/sntp-opts.texi@1.229 +2 -2 + NTP_4_2_7P231 + + sntp/sntp.1sntpman@1.49 +2 -2 + NTP_4_2_7P231 + + sntp/sntp.1sntpmdoc@1.49 +2 -2 + NTP_4_2_7P231 + + sntp/sntp.html@1.229 +2 -2 + NTP_4_2_7P231 + + sntp/sntp.man.in@1.49 +2 -2 + NTP_4_2_7P231 + + sntp/sntp.mdoc.in@1.49 +2 -2 + NTP_4_2_7P231 + + util/ntp-keygen-opts.c@1.233 +3 -3 + NTP_4_2_7P231 + + util/ntp-keygen-opts.h@1.233 +3 -3 + NTP_4_2_7P231 + + util/ntp-keygen-opts.texi@1.234 +2 -2 + NTP_4_2_7P231 + + util/ntp-keygen.1ntp-keygenman@1.47 +2 -2 + NTP_4_2_7P231 + + util/ntp-keygen.1ntp-keygenmdoc@1.47 +2 -2 + NTP_4_2_7P231 + + util/ntp-keygen.man.in@1.47 +2 -2 + NTP_4_2_7P231 + + util/ntp-keygen.mdoc.in@1.47 +2 -2 + NTP_4_2_7P231 + +ChangeSet@1.2689, 2011-11-03 10:46:39+00:00, davehart@shiny.ad.hartbrothers.com + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + ChangeLog@1.1045 +2 -0 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + include/ntp_control.h@1.58 +9 -1 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + include/ntp_stdlib.h@1.67 +3 -0 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + libntp/decodenetnum.c@1.16 +1 -0 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + libntp/socktoa.c@1.18 +26 -6 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + libntp/statestr.c@1.27 +49 -0 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + ntpd/ntp_control.c@1.174 +263 -66 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + ntpq/ntpq-subs.c@1.92 +218 -13 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + + ntpq/ntpq.c@1.141 +40 -31 + Add ntpq reslist command to query access restrictions, similar to + ntpdc's reslist. + +ChangeSet@1.2688, 2011-11-03 05:55:39+00:00, stenn@psp-fb1.ntp.org + cleanup + + ChangeLog@1.1044 +1 -1 + cleanup + +ChangeSet@1.2687, 2011-11-02 22:39:22+01:00, jnperlin@hydra.localnet + [Bug 1940] ignore auth key if hex decoding fails + + ChangeLog@1.1043 +1 -0 + [Bug 1940] ignore auth key if hex decoding fails + + libntp/authreadkeys.c@1.18 +8 -6 + [Bug 1940] ignore auth key if hex decoding fails + +ChangeSet@1.2686, 2011-11-01 10:56:11+00:00, stenn@deacon.udel.edu + NTP_4_2_7P230 + TAG: NTP_4_2_7P230 + + ChangeLog@1.1042 +1 -0 + NTP_4_2_7P230 + + ntpd/ntpd-opts.c@1.235 +3 -3 + NTP_4_2_7P230 + + ntpd/ntpd-opts.h@1.235 +3 -3 + NTP_4_2_7P230 + + ntpd/ntpd-opts.texi@1.233 +2 -2 + NTP_4_2_7P230 + + ntpd/ntpd.1ntpdman@1.46 +2 -2 + NTP_4_2_7P230 + + ntpd/ntpd.1ntpdmdoc@1.46 +2 -2 + NTP_4_2_7P230 + + ntpd/ntpd.man.in@1.46 +2 -2 + NTP_4_2_7P230 + + ntpd/ntpd.mdoc.in@1.46 +2 -2 + NTP_4_2_7P230 + + ntpdc/ntpdc-opts.c@1.230 +3 -3 + NTP_4_2_7P230 + + ntpdc/ntpdc-opts.h@1.230 +3 -3 + NTP_4_2_7P230 + + ntpdc/ntpdc-opts.texi@1.230 +2 -2 + NTP_4_2_7P230 + + ntpdc/ntpdc.1ntpdcman@1.46 +2 -2 + NTP_4_2_7P230 + + ntpdc/ntpdc.1ntpdcmdoc@1.46 +2 -2 + NTP_4_2_7P230 + + ntpdc/ntpdc.html@1.58 +2 -2 + NTP_4_2_7P230 + + ntpdc/ntpdc.man.in@1.46 +2 -2 + NTP_4_2_7P230 + + ntpdc/ntpdc.mdoc.in@1.46 +2 -2 + NTP_4_2_7P230 + + ntpq/ntpq-opts.c@1.232 +3 -3 + NTP_4_2_7P230 + + ntpq/ntpq-opts.h@1.232 +3 -3 + NTP_4_2_7P230 + + ntpq/ntpq-opts.texi@1.232 +2 -2 + NTP_4_2_7P230 + + ntpq/ntpq.1ntpqman@1.46 +2 -2 + NTP_4_2_7P230 + + ntpq/ntpq.1ntpqmdoc@1.46 +2 -2 + NTP_4_2_7P230 + + ntpq/ntpq.man.in@1.46 +2 -2 + NTP_4_2_7P230 + + ntpq/ntpq.mdoc.in@1.46 +2 -2 + NTP_4_2_7P230 + + ntpsnmpd/ntpsnmpd-opts.c@1.232 +3 -3 + NTP_4_2_7P230 + + ntpsnmpd/ntpsnmpd-opts.h@1.232 +3 -3 + NTP_4_2_7P230 + + ntpsnmpd/ntpsnmpd-opts.texi@1.232 +2 -2 + NTP_4_2_7P230 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.46 +2 -2 + NTP_4_2_7P230 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.46 +2 -2 + NTP_4_2_7P230 + + ntpsnmpd/ntpsnmpd.man.in@1.46 +2 -2 + NTP_4_2_7P230 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.46 +2 -2 + NTP_4_2_7P230 + + packageinfo.sh@1.233 +1 -1 + NTP_4_2_7P230 + + scripts/ntp-wait-opts.texi@1.50 +1 -1 + NTP_4_2_7P230 + + scripts/ntp-wait.1ntp-waitman@1.46 +2 -2 + NTP_4_2_7P230 + + scripts/ntp-wait.1ntp-waitmdoc@1.46 +2 -2 + NTP_4_2_7P230 + + scripts/ntp-wait.html@1.50 +1 -1 + NTP_4_2_7P230 + + scripts/ntp-wait.man.in@1.46 +2 -2 + NTP_4_2_7P230 + + scripts/ntp-wait.mdoc.in@1.46 +2 -2 + NTP_4_2_7P230 + + sntp/sntp-opts.c@1.228 +3 -3 + NTP_4_2_7P230 + + sntp/sntp-opts.h@1.228 +3 -3 + NTP_4_2_7P230 + + sntp/sntp-opts.texi@1.228 +2 -2 + NTP_4_2_7P230 + + sntp/sntp.1sntpman@1.48 +2 -2 + NTP_4_2_7P230 + + sntp/sntp.1sntpmdoc@1.48 +2 -2 + NTP_4_2_7P230 + + sntp/sntp.html@1.228 +2 -2 + NTP_4_2_7P230 + + sntp/sntp.man.in@1.48 +2 -2 + NTP_4_2_7P230 + + sntp/sntp.mdoc.in@1.48 +2 -2 + NTP_4_2_7P230 + + util/ntp-keygen-opts.c@1.232 +3 -3 + NTP_4_2_7P230 + + util/ntp-keygen-opts.h@1.232 +3 -3 + NTP_4_2_7P230 + + util/ntp-keygen-opts.texi@1.233 +2 -2 + NTP_4_2_7P230 + + util/ntp-keygen.1ntp-keygenman@1.46 +2 -2 + NTP_4_2_7P230 + + util/ntp-keygen.1ntp-keygenmdoc@1.46 +2 -2 + NTP_4_2_7P230 + + util/ntp-keygen.man.in@1.46 +2 -2 + NTP_4_2_7P230 + + util/ntp-keygen.mdoc.in@1.46 +2 -2 + NTP_4_2_7P230 + +ChangeSet@1.2685, 2011-10-31 15:38:17-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1041 +1 -0 + Documentation updates from Dave Mills + + html/cluster.html@1.6 +7 -7 + Documentation updates from Dave Mills + + html/discipline.html@1.6 +2 -2 + Documentation updates from Dave Mills + + html/discover.html@1.4 +14 -12 + Documentation updates from Dave Mills + + html/drivers/driver22.html@1.20 +3 -3 + Documentation updates from Dave Mills + + html/filter.html@1.4 +4 -4 + Documentation updates from Dave Mills + + html/prefer.html@1.27 +12 -11 + Documentation updates from Dave Mills + + html/rate.html@1.9 +22 -17 + Documentation updates from Dave Mills + + html/select.html@1.4 +5 -4 + Documentation updates from Dave Mills + + html/warp.html@1.19 +21 -20 + Documentation updates from Dave Mills + +ChangeSet@1.2684, 2011-10-31 14:54:08+00:00, davehart@shiny.ad.hartbrothers.com + use rand() twice to get about 32 bits of noise for mrulist. + + ntpd/ntp_control.c@1.173 +3 -3 + use rand() twice to get about 32 bits of noise for mrulist. + +ChangeSet@1.2683, 2011-10-31 04:40:04+00:00, davehart@shiny.ad.hartbrothers.com + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + + ChangeLog@1.1040 +5 -0 + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + + include/ntp.h@1.199 +1 -0 + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + + ntpd/complete.conf@1.20 +1 -1 + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + + ntpd/keyword-gen-utd@1.15 +1 -1 + derived from ntp_keyword.h + + ntpd/keyword-gen.c@1.20 +1 -0 + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + + ntpd/ntp_config.c@1.294 +5 -1 + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + + ntpd/ntp_keyword.h@1.17 +545 -543 + keyword-gen output + + ntpd/ntp_parser.c@1.77 +831 -823 + Bison output + + ntpd/ntp_parser.h@1.44 +175 -173 + Bison output + + ntpd/ntp_parser.y@1.71 +14 -2 + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + + ntpd/ntp_proto.c@1.324 +7 -2 + Disable mode 7 (ntpdc) query processing in ntpd by default. ntpq is + believed to provide all functionality ntpdc did, and uses a less- + fragile protocol that's safer and easier to maintain. If you do find + some management via ntpdc is needed, you can use "enable mode7" in the + ntpd configuration. + +ChangeSet@1.2682, 2011-10-31 03:52:23+00:00, davehart@shiny.ad.hartbrothers.com + Directly limit the number of datagrams in a mrulist response, rather + than limiting the number of entries returned to indirectly limit the + datagram count. + + ChangeLog@1.1039 +3 -0 + Directly limit the number of datagrams in a mrulist response, rather + than limiting the number of entries returned to indirectly limit the + datagram count. + + include/ntp.h@1.198 +2 -0 + Directly limit the number of datagrams in a mrulist response, rather + than limiting the number of entries returned to indirectly limit the + datagram count. + + libntp/ntp_random.c@1.9 +8 -5 + Seed rand() while seeding ntp_random(), so that code needing low-grade + random numbers can use the former. + + ntpd/ntp_control.c@1.172 +53 -28 + Directly limit the number of datagrams in a mrulist response, rather + than limiting the number of entries returned to indirectly limit the + datagram count. + + ntpq/ntpq-subs.c@1.91 +53 -21 + Directly limit the number of datagrams in a mrulist response, rather + than limiting the number of entries returned to indirectly limit the + datagram count. + + util/ntp-keygen.c@1.87 +1 -1 + Use a better random seed for ntp-keygen (tv_sec + tv_usec) + +ChangeSet@1.2681, 2011-10-26 00:22:53+00:00, stenn@deacon.udel.edu + NTP_4_2_7P229 + TAG: NTP_4_2_7P229 + + ChangeLog@1.1038 +1 -0 + NTP_4_2_7P229 + + ntpd/ntpd-opts.c@1.234 +3 -3 + NTP_4_2_7P229 + + ntpd/ntpd-opts.h@1.234 +3 -3 + NTP_4_2_7P229 + + ntpd/ntpd-opts.texi@1.232 +2 -2 + NTP_4_2_7P229 + + ntpd/ntpd.1ntpdman@1.45 +2 -2 + NTP_4_2_7P229 + + ntpd/ntpd.1ntpdmdoc@1.45 +2 -2 + NTP_4_2_7P229 + + ntpd/ntpd.man.in@1.45 +2 -2 + NTP_4_2_7P229 + + ntpd/ntpd.mdoc.in@1.45 +2 -2 + NTP_4_2_7P229 + + ntpdc/ntpdc-opts.c@1.229 +3 -3 + NTP_4_2_7P229 + + ntpdc/ntpdc-opts.h@1.229 +3 -3 + NTP_4_2_7P229 + + ntpdc/ntpdc-opts.texi@1.229 +2 -2 + NTP_4_2_7P229 + + ntpdc/ntpdc.1ntpdcman@1.45 +2 -2 + NTP_4_2_7P229 + + ntpdc/ntpdc.1ntpdcmdoc@1.45 +2 -2 + NTP_4_2_7P229 + + ntpdc/ntpdc.html@1.57 +2 -2 + NTP_4_2_7P229 + + ntpdc/ntpdc.man.in@1.45 +2 -2 + NTP_4_2_7P229 + + ntpdc/ntpdc.mdoc.in@1.45 +2 -2 + NTP_4_2_7P229 + + ntpq/ntpq-opts.c@1.231 +3 -3 + NTP_4_2_7P229 + + ntpq/ntpq-opts.h@1.231 +3 -3 + NTP_4_2_7P229 + + ntpq/ntpq-opts.texi@1.231 +2 -2 + NTP_4_2_7P229 + + ntpq/ntpq.1ntpqman@1.45 +2 -2 + NTP_4_2_7P229 + + ntpq/ntpq.1ntpqmdoc@1.45 +2 -2 + NTP_4_2_7P229 + + ntpq/ntpq.man.in@1.45 +2 -2 + NTP_4_2_7P229 + + ntpq/ntpq.mdoc.in@1.45 +2 -2 + NTP_4_2_7P229 + + ntpsnmpd/ntpsnmpd-opts.c@1.231 +3 -3 + NTP_4_2_7P229 + + ntpsnmpd/ntpsnmpd-opts.h@1.231 +3 -3 + NTP_4_2_7P229 + + ntpsnmpd/ntpsnmpd-opts.texi@1.231 +2 -2 + NTP_4_2_7P229 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.45 +2 -2 + NTP_4_2_7P229 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.45 +2 -2 + NTP_4_2_7P229 + + ntpsnmpd/ntpsnmpd.man.in@1.45 +2 -2 + NTP_4_2_7P229 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.45 +2 -2 + NTP_4_2_7P229 + + packageinfo.sh@1.232 +1 -1 + NTP_4_2_7P229 + + scripts/ntp-wait-opts.texi@1.49 +1 -1 + NTP_4_2_7P229 + + scripts/ntp-wait.1ntp-waitman@1.45 +2 -2 + NTP_4_2_7P229 + + scripts/ntp-wait.1ntp-waitmdoc@1.45 +2 -2 + NTP_4_2_7P229 + + scripts/ntp-wait.html@1.49 +1 -1 + NTP_4_2_7P229 + + scripts/ntp-wait.man.in@1.45 +2 -2 + NTP_4_2_7P229 + + scripts/ntp-wait.mdoc.in@1.45 +2 -2 + NTP_4_2_7P229 + + sntp/sntp-opts.c@1.227 +3 -3 + NTP_4_2_7P229 + + sntp/sntp-opts.h@1.227 +3 -3 + NTP_4_2_7P229 + + sntp/sntp-opts.texi@1.227 +2 -2 + NTP_4_2_7P229 + + sntp/sntp.1sntpman@1.47 +2 -2 + NTP_4_2_7P229 + + sntp/sntp.1sntpmdoc@1.47 +2 -2 + NTP_4_2_7P229 + + sntp/sntp.html@1.227 +2 -2 + NTP_4_2_7P229 + + sntp/sntp.man.in@1.47 +2 -2 + NTP_4_2_7P229 + + sntp/sntp.mdoc.in@1.47 +2 -2 + NTP_4_2_7P229 + + util/ntp-keygen-opts.c@1.231 +3 -3 + NTP_4_2_7P229 + + util/ntp-keygen-opts.h@1.231 +3 -3 + NTP_4_2_7P229 + + util/ntp-keygen-opts.texi@1.232 +2 -2 + NTP_4_2_7P229 + + util/ntp-keygen.1ntp-keygenman@1.45 +2 -2 + NTP_4_2_7P229 + + util/ntp-keygen.1ntp-keygenmdoc@1.45 +2 -2 + NTP_4_2_7P229 + + util/ntp-keygen.man.in@1.45 +2 -2 + NTP_4_2_7P229 + + util/ntp-keygen.mdoc.in@1.45 +2 -2 + NTP_4_2_7P229 + +ChangeSet@1.2680, 2011-10-25 17:18:33-04:00, perlinger@psp-deb1.ntp.org + [bug 1995] fixed wrong use of ZERO() macro in ntp_calendar.c + + ChangeLog@1.1037 +1 -0 + [bug 1995] fixed wrong use of ZERO() macro in ntp_calendar.c + + libntp/ntp_calendar.c@1.9 +1 -1 + [bug 1995] fixed wron use of ZERO() macro in ntp_calendar.c + +ChangeSet@1.2679, 2011-10-23 10:52:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P228 + TAG: NTP_4_2_7P228 + + ChangeLog@1.1036 +1 -0 + NTP_4_2_7P228 + + ntpd/ntpd-opts.c@1.233 +3 -3 + NTP_4_2_7P228 + + ntpd/ntpd-opts.h@1.233 +3 -3 + NTP_4_2_7P228 + + ntpd/ntpd-opts.texi@1.231 +2 -2 + NTP_4_2_7P228 + + ntpd/ntpd.1ntpdman@1.44 +2 -2 + NTP_4_2_7P228 + + ntpd/ntpd.1ntpdmdoc@1.44 +2 -2 + NTP_4_2_7P228 + + ntpd/ntpd.man.in@1.44 +2 -2 + NTP_4_2_7P228 + + ntpd/ntpd.mdoc.in@1.44 +2 -2 + NTP_4_2_7P228 + + ntpdc/ntpdc-opts.c@1.228 +3 -3 + NTP_4_2_7P228 + + ntpdc/ntpdc-opts.h@1.228 +3 -3 + NTP_4_2_7P228 + + ntpdc/ntpdc-opts.texi@1.228 +2 -2 + NTP_4_2_7P228 + + ntpdc/ntpdc.1ntpdcman@1.44 +2 -2 + NTP_4_2_7P228 + + ntpdc/ntpdc.1ntpdcmdoc@1.44 +2 -2 + NTP_4_2_7P228 + + ntpdc/ntpdc.html@1.56 +2 -2 + NTP_4_2_7P228 + + ntpdc/ntpdc.man.in@1.44 +2 -2 + NTP_4_2_7P228 + + ntpdc/ntpdc.mdoc.in@1.44 +2 -2 + NTP_4_2_7P228 + + ntpq/ntpq-opts.c@1.230 +3 -3 + NTP_4_2_7P228 + + ntpq/ntpq-opts.h@1.230 +3 -3 + NTP_4_2_7P228 + + ntpq/ntpq-opts.texi@1.230 +2 -2 + NTP_4_2_7P228 + + ntpq/ntpq.1ntpqman@1.44 +2 -2 + NTP_4_2_7P228 + + ntpq/ntpq.1ntpqmdoc@1.44 +2 -2 + NTP_4_2_7P228 + + ntpq/ntpq.man.in@1.44 +2 -2 + NTP_4_2_7P228 + + ntpq/ntpq.mdoc.in@1.44 +2 -2 + NTP_4_2_7P228 + + ntpsnmpd/ntpsnmpd-opts.c@1.230 +3 -3 + NTP_4_2_7P228 + + ntpsnmpd/ntpsnmpd-opts.h@1.230 +3 -3 + NTP_4_2_7P228 + + ntpsnmpd/ntpsnmpd-opts.texi@1.230 +2 -2 + NTP_4_2_7P228 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.44 +2 -2 + NTP_4_2_7P228 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.44 +2 -2 + NTP_4_2_7P228 + + ntpsnmpd/ntpsnmpd.man.in@1.44 +2 -2 + NTP_4_2_7P228 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.44 +2 -2 + NTP_4_2_7P228 + + packageinfo.sh@1.231 +1 -1 + NTP_4_2_7P228 + + scripts/ntp-wait-opts.texi@1.48 +1 -1 + NTP_4_2_7P228 + + scripts/ntp-wait.1ntp-waitman@1.44 +2 -2 + NTP_4_2_7P228 + + scripts/ntp-wait.1ntp-waitmdoc@1.44 +2 -2 + NTP_4_2_7P228 + + scripts/ntp-wait.html@1.48 +1 -1 + NTP_4_2_7P228 + + scripts/ntp-wait.man.in@1.44 +2 -2 + NTP_4_2_7P228 + + scripts/ntp-wait.mdoc.in@1.44 +2 -2 + NTP_4_2_7P228 + + sntp/sntp-opts.c@1.226 +3 -3 + NTP_4_2_7P228 + + sntp/sntp-opts.h@1.226 +3 -3 + NTP_4_2_7P228 + + sntp/sntp-opts.texi@1.226 +2 -2 + NTP_4_2_7P228 + + sntp/sntp.1sntpman@1.46 +2 -2 + NTP_4_2_7P228 + + sntp/sntp.1sntpmdoc@1.46 +2 -2 + NTP_4_2_7P228 + + sntp/sntp.html@1.226 +2 -2 + NTP_4_2_7P228 + + sntp/sntp.man.in@1.46 +2 -2 + NTP_4_2_7P228 + + sntp/sntp.mdoc.in@1.46 +2 -2 + NTP_4_2_7P228 + + util/ntp-keygen-opts.c@1.230 +3 -3 + NTP_4_2_7P228 + + util/ntp-keygen-opts.h@1.230 +3 -3 + NTP_4_2_7P228 + + util/ntp-keygen-opts.texi@1.231 +2 -2 + NTP_4_2_7P228 + + util/ntp-keygen.1ntp-keygenman@1.44 +2 -2 + NTP_4_2_7P228 + + util/ntp-keygen.1ntp-keygenmdoc@1.44 +2 -2 + NTP_4_2_7P228 + + util/ntp-keygen.man.in@1.44 +2 -2 + NTP_4_2_7P228 + + util/ntp-keygen.mdoc.in@1.44 +2 -2 + NTP_4_2_7P228 + +ChangeSet@1.2678, 2011-10-22 18:05:27-04:00, stenn@deacon.udel.edu + Start the NEWS file updates in preparation for 4.2.8 + + NEWS@1.123 +18 -0 + Start the NEWS file updates in preparation for 4.2.8 + +ChangeSet@1.2673.1.50, 2011-10-22 10:34:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P227 + TAG: NTP_4_2_7P227 + + ChangeLog@1.1032.1.42 +1 -0 + NTP_4_2_7P227 + + ntpd/ntpd-opts.c@1.232 +3 -3 + NTP_4_2_7P227 + + ntpd/ntpd-opts.h@1.232 +3 -3 + NTP_4_2_7P227 + + ntpd/ntpd-opts.texi@1.230 +2 -2 + NTP_4_2_7P227 + + ntpd/ntpd.1ntpdman@1.43 +2 -2 + NTP_4_2_7P227 + + ntpd/ntpd.1ntpdmdoc@1.43 +2 -2 + NTP_4_2_7P227 + + ntpd/ntpd.man.in@1.43 +2 -2 + NTP_4_2_7P227 + + ntpd/ntpd.mdoc.in@1.43 +2 -2 + NTP_4_2_7P227 + + ntpdc/ntpdc-opts.c@1.227 +3 -3 + NTP_4_2_7P227 + + ntpdc/ntpdc-opts.h@1.227 +3 -3 + NTP_4_2_7P227 + + ntpdc/ntpdc-opts.texi@1.227 +2 -2 + NTP_4_2_7P227 + + ntpdc/ntpdc.1ntpdcman@1.43 +2 -2 + NTP_4_2_7P227 + + ntpdc/ntpdc.1ntpdcmdoc@1.43 +2 -2 + NTP_4_2_7P227 + + ntpdc/ntpdc.html@1.55 +2 -2 + NTP_4_2_7P227 + + ntpdc/ntpdc.man.in@1.43 +2 -2 + NTP_4_2_7P227 + + ntpdc/ntpdc.mdoc.in@1.43 +2 -2 + NTP_4_2_7P227 + + ntpq/ntpq-opts.c@1.229 +3 -3 + NTP_4_2_7P227 + + ntpq/ntpq-opts.h@1.229 +3 -3 + NTP_4_2_7P227 + + ntpq/ntpq-opts.texi@1.229 +2 -2 + NTP_4_2_7P227 + + ntpq/ntpq.1ntpqman@1.43 +2 -2 + NTP_4_2_7P227 + + ntpq/ntpq.1ntpqmdoc@1.43 +2 -2 + NTP_4_2_7P227 + + ntpq/ntpq.man.in@1.43 +2 -2 + NTP_4_2_7P227 + + ntpq/ntpq.mdoc.in@1.43 +2 -2 + NTP_4_2_7P227 + + ntpsnmpd/ntpsnmpd-opts.c@1.229 +3 -3 + NTP_4_2_7P227 + + ntpsnmpd/ntpsnmpd-opts.h@1.229 +3 -3 + NTP_4_2_7P227 + + ntpsnmpd/ntpsnmpd-opts.texi@1.229 +2 -2 + NTP_4_2_7P227 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.43 +2 -2 + NTP_4_2_7P227 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.43 +2 -2 + NTP_4_2_7P227 + + ntpsnmpd/ntpsnmpd.man.in@1.43 +2 -2 + NTP_4_2_7P227 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.43 +2 -2 + NTP_4_2_7P227 + + packageinfo.sh@1.230 +1 -1 + NTP_4_2_7P227 + + scripts/ntp-wait-opts.texi@1.47 +1 -1 + NTP_4_2_7P227 + + scripts/ntp-wait.1ntp-waitman@1.43 +2 -2 + NTP_4_2_7P227 + + scripts/ntp-wait.1ntp-waitmdoc@1.43 +2 -2 + NTP_4_2_7P227 + + scripts/ntp-wait.html@1.47 +1 -1 + NTP_4_2_7P227 + + scripts/ntp-wait.man.in@1.43 +2 -2 + NTP_4_2_7P227 + + scripts/ntp-wait.mdoc.in@1.43 +2 -2 + NTP_4_2_7P227 + + sntp/sntp-opts.c@1.225 +3 -3 + NTP_4_2_7P227 + + sntp/sntp-opts.h@1.225 +3 -3 + NTP_4_2_7P227 + + sntp/sntp-opts.texi@1.225 +2 -2 + NTP_4_2_7P227 + + sntp/sntp.1sntpman@1.45 +2 -2 + NTP_4_2_7P227 + + sntp/sntp.1sntpmdoc@1.45 +2 -2 + NTP_4_2_7P227 + + sntp/sntp.html@1.225 +2 -2 + NTP_4_2_7P227 + + sntp/sntp.man.in@1.45 +2 -2 + NTP_4_2_7P227 + + sntp/sntp.mdoc.in@1.45 +2 -2 + NTP_4_2_7P227 + + util/ntp-keygen-opts.c@1.229 +3 -3 + NTP_4_2_7P227 + + util/ntp-keygen-opts.h@1.229 +3 -3 + NTP_4_2_7P227 + + util/ntp-keygen-opts.texi@1.230 +2 -2 + NTP_4_2_7P227 + + util/ntp-keygen.1ntp-keygenman@1.43 +2 -2 + NTP_4_2_7P227 + + util/ntp-keygen.1ntp-keygenmdoc@1.43 +2 -2 + NTP_4_2_7P227 + + util/ntp-keygen.man.in@1.43 +2 -2 + NTP_4_2_7P227 + + util/ntp-keygen.mdoc.in@1.43 +2 -2 + NTP_4_2_7P227 + +ChangeSet@1.2673.1.49, 2011-10-21 19:10:02+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2036] gcc 2.95.3 preprocessor can't nest #ifdef in macro args. + A number of compiler warnings eliminated. + + ChangeLog@1.1032.1.41 +2 -0 + [Bug 2036] gcc 2.95.3 preprocessor can't nest #ifdef in macro args. + A number of compiler warnings eliminated. + + lib/isc/include/isc/file.h@1.5 +2 -2 + A number of compiler warnings eliminated. + + lib/isc/include/isc/util.h@1.5 +1 -1 + A number of compiler warnings eliminated. + + lib/isc/inet_ntop.c@1.12 +2 -1 + A number of compiler warnings eliminated. + + lib/isc/inet_pton.c@1.6 +1 -0 + A number of compiler warnings eliminated. + + lib/isc/result.c@1.2 +13 -13 + A number of compiler warnings eliminated. + + lib/isc/unix/file.c@1.4 +7 -7 + A number of compiler warnings eliminated. + + libntp/msyslog.c@1.48 +6 -2 + A number of compiler warnings eliminated. + + libntp/snprintf.c@1.12 +0 -2 + A number of compiler warnings eliminated. + + ntpd/ntp_io.c@1.361 +6 -1 + A number of compiler warnings eliminated. + + ntpd/refclock_nmea.c@1.64 +2 -0 + A number of compiler warnings eliminated. + + ntpd/refclock_parse.c@1.62 +9 -11 + [Bug 2036] gcc 2.95.3 preprocessor can't nest #ifdef in macro args. + A number of compiler warnings eliminated. + + ntpd/refclock_wwvb.c@1.33 +2 -0 + A number of compiler warnings eliminated. + +ChangeSet@1.2673.1.48, 2011-10-21 18:40:55+00:00, stenn@deacon.udel.edu + NTP_4_2_7P226 + TAG: NTP_4_2_7P226 + + ChangeLog@1.1032.1.40 +1 -0 + NTP_4_2_7P226 + + ntpd/ntpd-opts.c@1.231 +3 -3 + NTP_4_2_7P226 + + ntpd/ntpd-opts.h@1.231 +3 -3 + NTP_4_2_7P226 + + ntpd/ntpd-opts.texi@1.229 +2 -2 + NTP_4_2_7P226 + + ntpd/ntpd.1ntpdman@1.42 +2 -2 + NTP_4_2_7P226 + + ntpd/ntpd.1ntpdmdoc@1.42 +2 -2 + NTP_4_2_7P226 + + ntpd/ntpd.man.in@1.42 +2 -2 + NTP_4_2_7P226 + + ntpd/ntpd.mdoc.in@1.42 +2 -2 + NTP_4_2_7P226 + + ntpdc/ntpdc-opts.c@1.226 +3 -3 + NTP_4_2_7P226 + + ntpdc/ntpdc-opts.h@1.226 +3 -3 + NTP_4_2_7P226 + + ntpdc/ntpdc-opts.texi@1.226 +2 -2 + NTP_4_2_7P226 + + ntpdc/ntpdc.1ntpdcman@1.42 +2 -2 + NTP_4_2_7P226 + + ntpdc/ntpdc.1ntpdcmdoc@1.42 +2 -2 + NTP_4_2_7P226 + + ntpdc/ntpdc.html@1.54 +2 -2 + NTP_4_2_7P226 + + ntpdc/ntpdc.man.in@1.42 +2 -2 + NTP_4_2_7P226 + + ntpdc/ntpdc.mdoc.in@1.42 +2 -2 + NTP_4_2_7P226 + + ntpq/ntpq-opts.c@1.228 +3 -3 + NTP_4_2_7P226 + + ntpq/ntpq-opts.h@1.228 +3 -3 + NTP_4_2_7P226 + + ntpq/ntpq-opts.texi@1.228 +2 -2 + NTP_4_2_7P226 + + ntpq/ntpq.1ntpqman@1.42 +2 -2 + NTP_4_2_7P226 + + ntpq/ntpq.1ntpqmdoc@1.42 +2 -2 + NTP_4_2_7P226 + + ntpq/ntpq.man.in@1.42 +2 -2 + NTP_4_2_7P226 + + ntpq/ntpq.mdoc.in@1.42 +2 -2 + NTP_4_2_7P226 + + ntpsnmpd/ntpsnmpd-opts.c@1.228 +3 -3 + NTP_4_2_7P226 + + ntpsnmpd/ntpsnmpd-opts.h@1.228 +3 -3 + NTP_4_2_7P226 + + ntpsnmpd/ntpsnmpd-opts.texi@1.228 +2 -2 + NTP_4_2_7P226 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.42 +2 -2 + NTP_4_2_7P226 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.42 +2 -2 + NTP_4_2_7P226 + + ntpsnmpd/ntpsnmpd.man.in@1.42 +2 -2 + NTP_4_2_7P226 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.42 +2 -2 + NTP_4_2_7P226 + + packageinfo.sh@1.229 +1 -1 + NTP_4_2_7P226 + + scripts/ntp-wait-opts.texi@1.46 +1 -1 + NTP_4_2_7P226 + + scripts/ntp-wait.1ntp-waitman@1.42 +2 -2 + NTP_4_2_7P226 + + scripts/ntp-wait.1ntp-waitmdoc@1.42 +2 -2 + NTP_4_2_7P226 + + scripts/ntp-wait.html@1.46 +1 -1 + NTP_4_2_7P226 + + scripts/ntp-wait.man.in@1.42 +2 -2 + NTP_4_2_7P226 + + scripts/ntp-wait.mdoc.in@1.42 +2 -2 + NTP_4_2_7P226 + + sntp/sntp-opts.c@1.224 +3 -3 + NTP_4_2_7P226 + + sntp/sntp-opts.h@1.224 +3 -3 + NTP_4_2_7P226 + + sntp/sntp-opts.texi@1.224 +2 -2 + NTP_4_2_7P226 + + sntp/sntp.1sntpman@1.44 +2 -2 + NTP_4_2_7P226 + + sntp/sntp.1sntpmdoc@1.44 +2 -2 + NTP_4_2_7P226 + + sntp/sntp.html@1.224 +2 -2 + NTP_4_2_7P226 + + sntp/sntp.man.in@1.44 +2 -2 + NTP_4_2_7P226 + + sntp/sntp.mdoc.in@1.44 +2 -2 + NTP_4_2_7P226 + + util/ntp-keygen-opts.c@1.228 +3 -3 + NTP_4_2_7P226 + + util/ntp-keygen-opts.h@1.228 +3 -3 + NTP_4_2_7P226 + + util/ntp-keygen-opts.texi@1.229 +2 -2 + NTP_4_2_7P226 + + util/ntp-keygen.1ntp-keygenman@1.42 +2 -2 + NTP_4_2_7P226 + + util/ntp-keygen.1ntp-keygenmdoc@1.42 +2 -2 + NTP_4_2_7P226 + + util/ntp-keygen.man.in@1.42 +2 -2 + NTP_4_2_7P226 + + util/ntp-keygen.mdoc.in@1.42 +2 -2 + NTP_4_2_7P226 + +ChangeSet@1.2676, 2011-10-21 02:07:25+00:00, davehart@shiny.ad.hartbrothers.com + Minor style cleanup of ntp_calendar.c and systime.c + + include/ntp_types.h@1.27 +4 -1 + provide UNUSED_LOCAL() like UNUSED_ARG() to quiet warnings. + + libntp/ntp_calendar.c@1.8 +180 -119 + Remove shadowing "tmp" redeclaration in time_to_vint64(), rename tmp to tt. + Minor style cleanup, including older code. + + libntp/systime.c@1.58 +25 -28 + minor style cleanup, reduce indenting + +ChangeSet@1.2673.1.47, 2011-10-18 23:37:23-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1032.1.39 +1 -0 + Documentation updates from Dave Mills + + html/cluster.html@1.5 +5 -5 + Documentation updates from Dave Mills + + html/drivers/scripts/footer.txt@1.4 +5 -3 + Documentation updates from Dave Mills + + html/scripts/command.txt@1.5 +7 -9 + Documentation updates from Dave Mills + + html/scripts/confopt.txt@1.5 +5 -5 + Documentation updates from Dave Mills + + html/scripts/footer.txt@1.5 +5 -8 + Documentation updates from Dave Mills + +ChangeSet@1.2082.4.243, 2011-10-18 23:14:54+00:00, stenn@deacon.udel.edu + NTP_4_2_6P5_RC1 + TAG: NTP_4_2_6P5_RC1 + + ChangeLog@1.496.26.173 +1 -0 + NTP_4_2_6P5_RC1 + + ntpd/ntpd-opts.c@1.248.40.1 +5 -5 + NTP_4_2_6P5_RC1 + + ntpd/ntpd-opts.h@1.248.40.1 +3 -3 + NTP_4_2_6P5_RC1 + + ntpd/ntpd-opts.texi@1.246.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + ntpd/ntpd.1@1.246.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + ntpdc/ntpdc-opts.c@1.244.40.1 +5 -5 + NTP_4_2_6P5_RC1 + + ntpdc/ntpdc-opts.h@1.244.40.1 +3 -3 + NTP_4_2_6P5_RC1 + + ntpdc/ntpdc-opts.texi@1.243.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + ntpdc/ntpdc.1@1.243.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + ntpq/ntpq-opts.c@1.245.40.1 +5 -5 + NTP_4_2_6P5_RC1 + + ntpq/ntpq-opts.h@1.245.40.1 +3 -3 + NTP_4_2_6P5_RC1 + + ntpq/ntpq-opts.texi@1.244.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + ntpq/ntpq.1@1.244.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.41.1 +5 -5 + NTP_4_2_6P5_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.41.1 +3 -3 + NTP_4_2_6P5_RC1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.40.1 +2 -2 + NTP_4_2_6P5_RC1 + + ntpsnmpd/ntpsnmpd.1@1.122.40.1 +2 -2 + NTP_4_2_6P5_RC1 + + packageinfo.sh@1.255.37.2 +2 -2 + NTP_4_2_6P5_RC1 + + sntp/sntp-opts.c@1.117.39.1 +5 -5 + NTP_4_2_6P5_RC1 + + sntp/sntp-opts.h@1.117.39.1 +3 -3 + NTP_4_2_6P5_RC1 + + sntp/sntp-opts.texi@1.117.38.1 +2 -2 + NTP_4_2_6P5_RC1 + + sntp/sntp.1@1.117.38.1 +2 -2 + NTP_4_2_6P5_RC1 + + sntp/sntp.html@1.7.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + util/ntp-keygen-opts.c@1.247.40.1 +5 -5 + NTP_4_2_6P5_RC1 + + util/ntp-keygen-opts.h@1.247.40.1 +3 -3 + NTP_4_2_6P5_RC1 + + util/ntp-keygen-opts.texi@1.246.39.1 +2 -2 + NTP_4_2_6P5_RC1 + + util/ntp-keygen.1@1.246.39.1 +2 -2 + NTP_4_2_6P5_RC1 + +ChangeSet@1.2082.4.242, 2011-10-18 14:31:10-04:00, stenn@deacon.udel.edu + ntp-4.2.6p5-RC1 + + packageinfo.sh@1.255.37.1 +1 -1 + ntp-4.2.6p5-RC1 + +ChangeSet@1.2082.4.241, 2011-10-18 14:27:46-04:00, stenn@deacon.udel.edu + update NEWS file + + NEWS@1.122 +5 -5 + update + +ChangeSet@1.2673.1.45, 2011-10-18 06:33:06+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2035] ntpq -c mrulist sleeps 1 sec between queries, not 5 msec. + + ChangeLog@1.1032.1.37 +1 -0 + [Bug 2035] ntpq -c mrulist sleeps 1 sec between queries, not 5 msec. + + configure.ac@1.538 +1 -1 + [Bug 2035] ntpq -c mrulist sleeps 1 sec between queries, not 5 msec. + + ntpq/ntpq-subs.c@1.90 +6 -10 + Move add_mru trace output from -D 1 to -D 2 + +ChangeSet@1.2082.4.240, 2011-10-18 02:35:21+00:00, davehart@shiny.ad.hartbrothers.com + Generalize [Bug 2034] summary, correct NEWS description of same. + + ChangeLog@1.496.26.172 +1 -1 + Generalize [Bug 2034] summary, correct NEWS description of same. + + NEWS@1.121 +7 -4 + Generalize [Bug 2034] summary, correct NEWS description of same. + +ChangeSet@1.2082.4.239, 2011-10-17 20:43:13-04:00, stenn@deacon.udel.edu + Update NEWS file for 4.2.6p5 + + NEWS@1.120 +15 -0 + Update NEWS file for 4.2.6p5 + +ChangeSet@1.2082.4.238, 2011-10-17 20:14:44+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2034] interface ignore fe80::/64 mismatches ::, ::1... + + ChangeLog@1.496.26.171 +4 -1 + [Bug 2034] interface ignore fe80::/64 mismatches ::, ::1... + + ntpd/ntp_io.c@1.306.1.16 +7 -4 + [Bug 2034] interface ignore fe80::/64 mismatches ::, ::1... + +ChangeSet@1.2673.1.42, 2011-10-15 10:36:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P225 + TAG: NTP_4_2_7P225 + + ChangeLog@1.1032.1.34 +1 -0 + NTP_4_2_7P225 + + ntpd/ntpd-opts.c@1.230 +3 -3 + NTP_4_2_7P225 + + ntpd/ntpd-opts.h@1.230 +3 -3 + NTP_4_2_7P225 + + ntpd/ntpd-opts.texi@1.228 +2 -2 + NTP_4_2_7P225 + + ntpd/ntpd.1ntpdman@1.41 +2 -2 + NTP_4_2_7P225 + + ntpd/ntpd.1ntpdmdoc@1.41 +2 -2 + NTP_4_2_7P225 + + ntpd/ntpd.man.in@1.41 +2 -2 + NTP_4_2_7P225 + + ntpd/ntpd.mdoc.in@1.41 +2 -2 + NTP_4_2_7P225 + + ntpdc/ntpdc-opts.c@1.225 +3 -3 + NTP_4_2_7P225 + + ntpdc/ntpdc-opts.h@1.225 +3 -3 + NTP_4_2_7P225 + + ntpdc/ntpdc-opts.texi@1.225 +2 -2 + NTP_4_2_7P225 + + ntpdc/ntpdc.1ntpdcman@1.41 +2 -2 + NTP_4_2_7P225 + + ntpdc/ntpdc.1ntpdcmdoc@1.41 +2 -2 + NTP_4_2_7P225 + + ntpdc/ntpdc.html@1.53 +2 -2 + NTP_4_2_7P225 + + ntpdc/ntpdc.man.in@1.41 +2 -2 + NTP_4_2_7P225 + + ntpdc/ntpdc.mdoc.in@1.41 +2 -2 + NTP_4_2_7P225 + + ntpq/ntpq-opts.c@1.227 +3 -3 + NTP_4_2_7P225 + + ntpq/ntpq-opts.h@1.227 +3 -3 + NTP_4_2_7P225 + + ntpq/ntpq-opts.texi@1.227 +2 -2 + NTP_4_2_7P225 + + ntpq/ntpq.1ntpqman@1.41 +2 -2 + NTP_4_2_7P225 + + ntpq/ntpq.1ntpqmdoc@1.41 +2 -2 + NTP_4_2_7P225 + + ntpq/ntpq.man.in@1.41 +2 -2 + NTP_4_2_7P225 + + ntpq/ntpq.mdoc.in@1.41 +2 -2 + NTP_4_2_7P225 + + ntpsnmpd/ntpsnmpd-opts.c@1.227 +3 -3 + NTP_4_2_7P225 + + ntpsnmpd/ntpsnmpd-opts.h@1.227 +3 -3 + NTP_4_2_7P225 + + ntpsnmpd/ntpsnmpd-opts.texi@1.227 +2 -2 + NTP_4_2_7P225 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.41 +2 -2 + NTP_4_2_7P225 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.41 +2 -2 + NTP_4_2_7P225 + + ntpsnmpd/ntpsnmpd.man.in@1.41 +2 -2 + NTP_4_2_7P225 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.41 +2 -2 + NTP_4_2_7P225 + + packageinfo.sh@1.228 +1 -1 + NTP_4_2_7P225 + + scripts/ntp-wait-opts.texi@1.45 +1 -1 + NTP_4_2_7P225 + + scripts/ntp-wait.1ntp-waitman@1.41 +2 -2 + NTP_4_2_7P225 + + scripts/ntp-wait.1ntp-waitmdoc@1.41 +2 -2 + NTP_4_2_7P225 + + scripts/ntp-wait.html@1.45 +1 -1 + NTP_4_2_7P225 + + scripts/ntp-wait.man.in@1.41 +2 -2 + NTP_4_2_7P225 + + scripts/ntp-wait.mdoc.in@1.41 +2 -2 + NTP_4_2_7P225 + + sntp/sntp-opts.c@1.223 +3 -3 + NTP_4_2_7P225 + + sntp/sntp-opts.h@1.223 +3 -3 + NTP_4_2_7P225 + + sntp/sntp-opts.texi@1.223 +2 -2 + NTP_4_2_7P225 + + sntp/sntp.1sntpman@1.43 +2 -2 + NTP_4_2_7P225 + + sntp/sntp.1sntpmdoc@1.43 +2 -2 + NTP_4_2_7P225 + + sntp/sntp.html@1.223 +2 -2 + NTP_4_2_7P225 + + sntp/sntp.man.in@1.43 +2 -2 + NTP_4_2_7P225 + + sntp/sntp.mdoc.in@1.43 +2 -2 + NTP_4_2_7P225 + + util/ntp-keygen-opts.c@1.227 +3 -3 + NTP_4_2_7P225 + + util/ntp-keygen-opts.h@1.227 +3 -3 + NTP_4_2_7P225 + + util/ntp-keygen-opts.texi@1.228 +2 -2 + NTP_4_2_7P225 + + util/ntp-keygen.1ntp-keygenman@1.41 +2 -2 + NTP_4_2_7P225 + + util/ntp-keygen.1ntp-keygenmdoc@1.41 +2 -2 + NTP_4_2_7P225 + + util/ntp-keygen.man.in@1.41 +2 -2 + NTP_4_2_7P225 + + util/ntp-keygen.mdoc.in@1.41 +2 -2 + NTP_4_2_7P225 + +ChangeSet@1.2673.1.41, 2011-10-14 21:01:03-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1032.1.33 +1 -0 + Documentation updates from Dave Mills + + html/accopt.html@1.41 +2 -1 + Documentation updates from Dave Mills + + html/assoc.html@1.38 +3 -3 + Documentation updates from Dave Mills + + html/authopt.html@1.73 +3 -6 + Documentation updates from Dave Mills + + html/cluster.html@1.4 +3 -3 + Documentation updates from Dave Mills + + html/confopt.html@1.57 +7 -7 + Documentation updates from Dave Mills + + html/discover.html@1.3 +7 -6 + Documentation updates from Dave Mills + + html/huffpuff.html@1.3 +9 -3 + Documentation updates from Dave Mills + + html/warp.html@1.18 +3 -3 + Documentation updates from Dave Mills + +ChangeSet@1.2673.1.40, 2011-10-14 10:39:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P224 + TAG: NTP_4_2_7P224 + + ChangeLog@1.1032.1.32 +1 -0 + NTP_4_2_7P224 + + ntpd/ntpd-opts.c@1.229 +3 -3 + NTP_4_2_7P224 + + ntpd/ntpd-opts.h@1.229 +3 -3 + NTP_4_2_7P224 + + ntpd/ntpd-opts.texi@1.227 +2 -2 + NTP_4_2_7P224 + + ntpd/ntpd.1ntpdman@1.40 +2 -2 + NTP_4_2_7P224 + + ntpd/ntpd.1ntpdmdoc@1.40 +2 -2 + NTP_4_2_7P224 + + ntpd/ntpd.man.in@1.40 +2 -2 + NTP_4_2_7P224 + + ntpd/ntpd.mdoc.in@1.40 +2 -2 + NTP_4_2_7P224 + + ntpdc/ntpdc-opts.c@1.224 +3 -3 + NTP_4_2_7P224 + + ntpdc/ntpdc-opts.h@1.224 +3 -3 + NTP_4_2_7P224 + + ntpdc/ntpdc-opts.texi@1.224 +2 -2 + NTP_4_2_7P224 + + ntpdc/ntpdc.1ntpdcman@1.40 +2 -2 + NTP_4_2_7P224 + + ntpdc/ntpdc.1ntpdcmdoc@1.40 +2 -2 + NTP_4_2_7P224 + + ntpdc/ntpdc.html@1.52 +2 -2 + NTP_4_2_7P224 + + ntpdc/ntpdc.man.in@1.40 +2 -2 + NTP_4_2_7P224 + + ntpdc/ntpdc.mdoc.in@1.40 +2 -2 + NTP_4_2_7P224 + + ntpq/ntpq-opts.c@1.226 +3 -3 + NTP_4_2_7P224 + + ntpq/ntpq-opts.h@1.226 +3 -3 + NTP_4_2_7P224 + + ntpq/ntpq-opts.texi@1.226 +2 -2 + NTP_4_2_7P224 + + ntpq/ntpq.1ntpqman@1.40 +2 -2 + NTP_4_2_7P224 + + ntpq/ntpq.1ntpqmdoc@1.40 +2 -2 + NTP_4_2_7P224 + + ntpq/ntpq.man.in@1.40 +2 -2 + NTP_4_2_7P224 + + ntpq/ntpq.mdoc.in@1.40 +2 -2 + NTP_4_2_7P224 + + ntpsnmpd/ntpsnmpd-opts.c@1.226 +3 -3 + NTP_4_2_7P224 + + ntpsnmpd/ntpsnmpd-opts.h@1.226 +3 -3 + NTP_4_2_7P224 + + ntpsnmpd/ntpsnmpd-opts.texi@1.226 +2 -2 + NTP_4_2_7P224 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.40 +2 -2 + NTP_4_2_7P224 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.40 +2 -2 + NTP_4_2_7P224 + + ntpsnmpd/ntpsnmpd.man.in@1.40 +2 -2 + NTP_4_2_7P224 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.40 +2 -2 + NTP_4_2_7P224 + + packageinfo.sh@1.227 +1 -1 + NTP_4_2_7P224 + + scripts/ntp-wait-opts.texi@1.44 +1 -1 + NTP_4_2_7P224 + + scripts/ntp-wait.1ntp-waitman@1.40 +2 -2 + NTP_4_2_7P224 + + scripts/ntp-wait.1ntp-waitmdoc@1.40 +2 -2 + NTP_4_2_7P224 + + scripts/ntp-wait.html@1.44 +1 -1 + NTP_4_2_7P224 + + scripts/ntp-wait.man.in@1.40 +2 -2 + NTP_4_2_7P224 + + scripts/ntp-wait.mdoc.in@1.40 +2 -2 + NTP_4_2_7P224 + + sntp/sntp-opts.c@1.222 +3 -3 + NTP_4_2_7P224 + + sntp/sntp-opts.h@1.222 +3 -3 + NTP_4_2_7P224 + + sntp/sntp-opts.texi@1.222 +2 -2 + NTP_4_2_7P224 + + sntp/sntp.1sntpman@1.42 +2 -2 + NTP_4_2_7P224 + + sntp/sntp.1sntpmdoc@1.42 +2 -2 + NTP_4_2_7P224 + + sntp/sntp.html@1.222 +2 -2 + NTP_4_2_7P224 + + sntp/sntp.man.in@1.42 +2 -2 + NTP_4_2_7P224 + + sntp/sntp.mdoc.in@1.42 +2 -2 + NTP_4_2_7P224 + + util/ntp-keygen-opts.c@1.226 +3 -3 + NTP_4_2_7P224 + + util/ntp-keygen-opts.h@1.226 +3 -3 + NTP_4_2_7P224 + + util/ntp-keygen-opts.texi@1.227 +2 -2 + NTP_4_2_7P224 + + util/ntp-keygen.1ntp-keygenman@1.40 +2 -2 + NTP_4_2_7P224 + + util/ntp-keygen.1ntp-keygenmdoc@1.40 +2 -2 + NTP_4_2_7P224 + + util/ntp-keygen.man.in@1.40 +2 -2 + NTP_4_2_7P224 + + util/ntp-keygen.mdoc.in@1.40 +2 -2 + NTP_4_2_7P224 + +ChangeSet@1.2673.1.39, 2011-10-13 18:13:58+00:00, davehart@shiny.ad.hartbrothers.com + ntpq mrulist shows intermediate counts every five seconds while + retrieving list, and allows Ctrl-C interruption of the retrieval, + showing the incomplete list as retrieved. Reduce delay between + successive mrulist retrieval queries from 30 to 5 msec. Do not + give up mrulist retrieval when a single query times out. + + ChangeLog@1.1032.1.31 +5 -0 + ntpq mrulist shows intermediate counts every five seconds while + retrieving list, and allows Ctrl-C interruption of the retrieval, + showing the incomplete list as retrieved. Reduce delay between + successive mrulist retrieval queries from 30 to 5 msec. Do not + give up mrulist retrieval when a single query times out. + + include/ntp_stdlib.h@1.66 +3 -0 + provide portable POSIX/Win32 Ctrl-C interception. + + libntp/syssignal.c@1.15 +79 -0 + provide portable POSIX/Win32 Ctrl-C interception. + + ntpq/ntpq-subs.c@1.89 +53 -8 + ntpq mrulist shows intermediate counts every five seconds while + retrieving list, and allows Ctrl-C interruption of the retrieval, + showing the incomplete list as retrieved. Reduce delay between + successive mrulist retrieval queries from 30 to 5 msec. Do not + give up mrulist retrieval when a single query times out. + + ntpq/ntpq.h@1.24 +5 -0 + ntpq mrulist shows intermediate counts every five seconds while + retrieving list. + +ChangeSet@1.2673.1.38, 2011-10-12 10:41:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P223 + TAG: NTP_4_2_7P223 + + ChangeLog@1.1032.1.30 +1 -0 + NTP_4_2_7P223 + + ntpd/ntpd-opts.c@1.228 +3 -3 + NTP_4_2_7P223 + + ntpd/ntpd-opts.h@1.228 +3 -3 + NTP_4_2_7P223 + + ntpd/ntpd-opts.texi@1.226 +2 -2 + NTP_4_2_7P223 + + ntpd/ntpd.1ntpdman@1.39 +2 -2 + NTP_4_2_7P223 + + ntpd/ntpd.1ntpdmdoc@1.39 +2 -2 + NTP_4_2_7P223 + + ntpd/ntpd.man.in@1.39 +2 -2 + NTP_4_2_7P223 + + ntpd/ntpd.mdoc.in@1.39 +2 -2 + NTP_4_2_7P223 + + ntpdc/ntpdc-opts.c@1.223 +3 -3 + NTP_4_2_7P223 + + ntpdc/ntpdc-opts.h@1.223 +3 -3 + NTP_4_2_7P223 + + ntpdc/ntpdc-opts.texi@1.223 +2 -2 + NTP_4_2_7P223 + + ntpdc/ntpdc.1ntpdcman@1.39 +2 -2 + NTP_4_2_7P223 + + ntpdc/ntpdc.1ntpdcmdoc@1.39 +2 -2 + NTP_4_2_7P223 + + ntpdc/ntpdc.html@1.51 +2 -2 + NTP_4_2_7P223 + + ntpdc/ntpdc.man.in@1.39 +2 -2 + NTP_4_2_7P223 + + ntpdc/ntpdc.mdoc.in@1.39 +2 -2 + NTP_4_2_7P223 + + ntpq/ntpq-opts.c@1.225 +3 -3 + NTP_4_2_7P223 + + ntpq/ntpq-opts.h@1.225 +3 -3 + NTP_4_2_7P223 + + ntpq/ntpq-opts.texi@1.225 +2 -2 + NTP_4_2_7P223 + + ntpq/ntpq.1ntpqman@1.39 +2 -2 + NTP_4_2_7P223 + + ntpq/ntpq.1ntpqmdoc@1.39 +2 -2 + NTP_4_2_7P223 + + ntpq/ntpq.man.in@1.39 +2 -2 + NTP_4_2_7P223 + + ntpq/ntpq.mdoc.in@1.39 +2 -2 + NTP_4_2_7P223 + + ntpsnmpd/ntpsnmpd-opts.c@1.225 +3 -3 + NTP_4_2_7P223 + + ntpsnmpd/ntpsnmpd-opts.h@1.225 +3 -3 + NTP_4_2_7P223 + + ntpsnmpd/ntpsnmpd-opts.texi@1.225 +2 -2 + NTP_4_2_7P223 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.39 +2 -2 + NTP_4_2_7P223 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.39 +2 -2 + NTP_4_2_7P223 + + ntpsnmpd/ntpsnmpd.man.in@1.39 +2 -2 + NTP_4_2_7P223 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.39 +2 -2 + NTP_4_2_7P223 + + packageinfo.sh@1.226 +1 -1 + NTP_4_2_7P223 + + scripts/ntp-wait-opts.texi@1.43 +1 -1 + NTP_4_2_7P223 + + scripts/ntp-wait.1ntp-waitman@1.39 +2 -2 + NTP_4_2_7P223 + + scripts/ntp-wait.1ntp-waitmdoc@1.39 +2 -2 + NTP_4_2_7P223 + + scripts/ntp-wait.html@1.43 +1 -1 + NTP_4_2_7P223 + + scripts/ntp-wait.man.in@1.39 +2 -2 + NTP_4_2_7P223 + + scripts/ntp-wait.mdoc.in@1.39 +2 -2 + NTP_4_2_7P223 + + sntp/sntp-opts.c@1.221 +3 -3 + NTP_4_2_7P223 + + sntp/sntp-opts.h@1.221 +3 -3 + NTP_4_2_7P223 + + sntp/sntp-opts.texi@1.221 +2 -2 + NTP_4_2_7P223 + + sntp/sntp.1sntpman@1.41 +2 -2 + NTP_4_2_7P223 + + sntp/sntp.1sntpmdoc@1.41 +2 -2 + NTP_4_2_7P223 + + sntp/sntp.html@1.221 +2 -2 + NTP_4_2_7P223 + + sntp/sntp.man.in@1.41 +2 -2 + NTP_4_2_7P223 + + sntp/sntp.mdoc.in@1.41 +2 -2 + NTP_4_2_7P223 + + util/ntp-keygen-opts.c@1.225 +3 -3 + NTP_4_2_7P223 + + util/ntp-keygen-opts.h@1.225 +3 -3 + NTP_4_2_7P223 + + util/ntp-keygen-opts.texi@1.226 +2 -2 + NTP_4_2_7P223 + + util/ntp-keygen.1ntp-keygenman@1.39 +2 -2 + NTP_4_2_7P223 + + util/ntp-keygen.1ntp-keygenmdoc@1.39 +2 -2 + NTP_4_2_7P223 + + util/ntp-keygen.man.in@1.39 +2 -2 + NTP_4_2_7P223 + + util/ntp-keygen.mdoc.in@1.39 +2 -2 + NTP_4_2_7P223 + +ChangeSet@1.2673.1.37, 2011-10-12 02:48:59-04:00, stenn@deacon.udel.edu + revert bogus changes + + html/accopt.html@1.40 +72 -55 + revert bogus changes + + html/assoc.html@1.37 +61 -671 + revert bogus changes + +ChangeSet@1.2673.1.36, 2011-10-12 02:28:11-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1032.1.29 +1 -0 + Documentation updates from Dave Mills + + html/accopt.html@1.39 +55 -72 + Documentation updates from Dave Mills + + html/assoc.html@1.36 +671 -61 + Documentation updates from Dave Mills + + html/decode.html@1.18 +1 -11 + Documentation updates from Dave Mills + + html/discover.html@1.2 +2 -2 + Documentation updates from Dave Mills + + html/warp.html@1.17 +3 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2673.1.35, 2011-10-11 09:09:30+00:00, stenn@deacon.udel.edu + NTP_4_2_7P222 + TAG: NTP_4_2_7P222 + + ChangeLog@1.1032.1.28 +1 -0 + NTP_4_2_7P222 + + ntpd/ntpd-opts.c@1.227 +3 -3 + NTP_4_2_7P222 + + ntpd/ntpd-opts.h@1.227 +3 -3 + NTP_4_2_7P222 + + ntpd/ntpd-opts.texi@1.225 +2 -2 + NTP_4_2_7P222 + + ntpd/ntpd.1ntpdman@1.38 +2 -2 + NTP_4_2_7P222 + + ntpd/ntpd.1ntpdmdoc@1.38 +2 -2 + NTP_4_2_7P222 + + ntpd/ntpd.man.in@1.38 +2 -2 + NTP_4_2_7P222 + + ntpd/ntpd.mdoc.in@1.38 +2 -2 + NTP_4_2_7P222 + + ntpdc/ntpdc-opts.c@1.222 +3 -3 + NTP_4_2_7P222 + + ntpdc/ntpdc-opts.h@1.222 +3 -3 + NTP_4_2_7P222 + + ntpdc/ntpdc-opts.texi@1.222 +2 -2 + NTP_4_2_7P222 + + ntpdc/ntpdc.1ntpdcman@1.38 +2 -2 + NTP_4_2_7P222 + + ntpdc/ntpdc.1ntpdcmdoc@1.38 +2 -2 + NTP_4_2_7P222 + + ntpdc/ntpdc.html@1.50 +2 -2 + NTP_4_2_7P222 + + ntpdc/ntpdc.man.in@1.38 +2 -2 + NTP_4_2_7P222 + + ntpdc/ntpdc.mdoc.in@1.38 +2 -2 + NTP_4_2_7P222 + + ntpq/ntpq-opts.c@1.224 +3 -3 + NTP_4_2_7P222 + + ntpq/ntpq-opts.h@1.224 +3 -3 + NTP_4_2_7P222 + + ntpq/ntpq-opts.texi@1.224 +2 -2 + NTP_4_2_7P222 + + ntpq/ntpq.1ntpqman@1.38 +2 -2 + NTP_4_2_7P222 + + ntpq/ntpq.1ntpqmdoc@1.38 +2 -2 + NTP_4_2_7P222 + + ntpq/ntpq.man.in@1.38 +2 -2 + NTP_4_2_7P222 + + ntpq/ntpq.mdoc.in@1.38 +2 -2 + NTP_4_2_7P222 + + ntpsnmpd/ntpsnmpd-opts.c@1.224 +3 -3 + NTP_4_2_7P222 + + ntpsnmpd/ntpsnmpd-opts.h@1.224 +3 -3 + NTP_4_2_7P222 + + ntpsnmpd/ntpsnmpd-opts.texi@1.224 +2 -2 + NTP_4_2_7P222 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.38 +2 -2 + NTP_4_2_7P222 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.38 +2 -2 + NTP_4_2_7P222 + + ntpsnmpd/ntpsnmpd.man.in@1.38 +2 -2 + NTP_4_2_7P222 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.38 +2 -2 + NTP_4_2_7P222 + + packageinfo.sh@1.225 +1 -1 + NTP_4_2_7P222 + + scripts/ntp-wait-opts.texi@1.42 +14 -2 + NTP_4_2_7P222 + + scripts/ntp-wait.1ntp-waitman@1.38 +2 -2 + NTP_4_2_7P222 + + scripts/ntp-wait.1ntp-waitmdoc@1.38 +2 -2 + NTP_4_2_7P222 + + scripts/ntp-wait.html@1.42 +14 -2 + NTP_4_2_7P222 + + scripts/ntp-wait.man.in@1.38 +2 -2 + NTP_4_2_7P222 + + scripts/ntp-wait.mdoc.in@1.38 +2 -2 + NTP_4_2_7P222 + + sntp/sntp-opts.c@1.220 +3 -3 + NTP_4_2_7P222 + + sntp/sntp-opts.h@1.220 +3 -3 + NTP_4_2_7P222 + + sntp/sntp-opts.texi@1.220 +2 -2 + NTP_4_2_7P222 + + sntp/sntp.1sntpman@1.40 +2 -2 + NTP_4_2_7P222 + + sntp/sntp.1sntpmdoc@1.40 +2 -2 + NTP_4_2_7P222 + + sntp/sntp.html@1.220 +2 -2 + NTP_4_2_7P222 + + sntp/sntp.man.in@1.40 +2 -2 + NTP_4_2_7P222 + + sntp/sntp.mdoc.in@1.40 +2 -2 + NTP_4_2_7P222 + + util/ntp-keygen-opts.c@1.224 +3 -3 + NTP_4_2_7P222 + + util/ntp-keygen-opts.h@1.224 +3 -3 + NTP_4_2_7P222 + + util/ntp-keygen-opts.texi@1.225 +2 -2 + NTP_4_2_7P222 + + util/ntp-keygen.1ntp-keygenman@1.38 +2 -2 + NTP_4_2_7P222 + + util/ntp-keygen.1ntp-keygenmdoc@1.38 +2 -2 + NTP_4_2_7P222 + + util/ntp-keygen.man.in@1.38 +2 -2 + NTP_4_2_7P222 + + util/ntp-keygen.mdoc.in@1.38 +2 -2 + NTP_4_2_7P222 + +ChangeSet@1.2673.1.34, 2011-10-11 02:04:21+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2029] "make check" clutters syslog. + Log signal description along with number on ntpd exit. + + ChangeLog@1.1032.1.27 +2 -0 + [Bug 2029] "make check" clutters syslog. + Log signal description along with number on ntpd exit. + + + configure.ac@1.537 +1 -4 + Log signal description along with number on ntpd exit. + + include/ntpd.h@1.169 +1 -1 + cosmetic only + + ntpd/ntpd.c@1.129 +26 -47 + [Bug 2029] "make check" clutters syslog. + Log signal description along with number on ntpd exit. + + +ChangeSet@1.2673.1.33, 2011-10-10 05:59:08+00:00, stenn@deacon.udel.edu + NTP_4_2_7P221 + TAG: NTP_4_2_7P221 + + ChangeLog@1.1032.1.26 +1 -0 + NTP_4_2_7P221 + + ntpd/ntpd-opts.c@1.226 +3 -3 + NTP_4_2_7P221 + + ntpd/ntpd-opts.h@1.226 +3 -3 + NTP_4_2_7P221 + + ntpd/ntpd-opts.texi@1.224 +2 -2 + NTP_4_2_7P221 + + ntpd/ntpd.1ntpdman@1.37 +2 -2 + NTP_4_2_7P221 + + ntpd/ntpd.1ntpdmdoc@1.37 +2 -2 + NTP_4_2_7P221 + + ntpd/ntpd.man.in@1.37 +2 -2 + NTP_4_2_7P221 + + ntpd/ntpd.mdoc.in@1.37 +2 -2 + NTP_4_2_7P221 + + ntpdc/ntpdc-opts.c@1.221 +3 -3 + NTP_4_2_7P221 + + ntpdc/ntpdc-opts.h@1.221 +3 -3 + NTP_4_2_7P221 + + ntpdc/ntpdc-opts.texi@1.221 +2 -2 + NTP_4_2_7P221 + + ntpdc/ntpdc.1ntpdcman@1.37 +2 -2 + NTP_4_2_7P221 + + ntpdc/ntpdc.1ntpdcmdoc@1.37 +2 -2 + NTP_4_2_7P221 + + ntpdc/ntpdc.html@1.49 +2 -2 + NTP_4_2_7P221 + + ntpdc/ntpdc.man.in@1.37 +2 -2 + NTP_4_2_7P221 + + ntpdc/ntpdc.mdoc.in@1.37 +2 -2 + NTP_4_2_7P221 + + ntpq/ntpq-opts.c@1.223 +3 -3 + NTP_4_2_7P221 + + ntpq/ntpq-opts.h@1.223 +3 -3 + NTP_4_2_7P221 + + ntpq/ntpq-opts.texi@1.223 +2 -2 + NTP_4_2_7P221 + + ntpq/ntpq.1ntpqman@1.37 +2 -2 + NTP_4_2_7P221 + + ntpq/ntpq.1ntpqmdoc@1.37 +2 -2 + NTP_4_2_7P221 + + ntpq/ntpq.man.in@1.37 +2 -2 + NTP_4_2_7P221 + + ntpq/ntpq.mdoc.in@1.37 +2 -2 + NTP_4_2_7P221 + + ntpsnmpd/ntpsnmpd-opts.c@1.223 +3 -3 + NTP_4_2_7P221 + + ntpsnmpd/ntpsnmpd-opts.h@1.223 +3 -3 + NTP_4_2_7P221 + + ntpsnmpd/ntpsnmpd-opts.texi@1.223 +2 -2 + NTP_4_2_7P221 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.37 +2 -2 + NTP_4_2_7P221 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.37 +2 -2 + NTP_4_2_7P221 + + ntpsnmpd/ntpsnmpd.man.in@1.37 +2 -2 + NTP_4_2_7P221 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.37 +2 -2 + NTP_4_2_7P221 + + packageinfo.sh@1.224 +1 -1 + NTP_4_2_7P221 + + scripts/ntp-wait-opts.texi@1.41 +2 -14 + NTP_4_2_7P221 + + scripts/ntp-wait.1ntp-waitman@1.37 +2 -2 + NTP_4_2_7P221 + + scripts/ntp-wait.1ntp-waitmdoc@1.37 +2 -2 + NTP_4_2_7P221 + + scripts/ntp-wait.html@1.41 +2 -14 + NTP_4_2_7P221 + + scripts/ntp-wait.man.in@1.37 +2 -2 + NTP_4_2_7P221 + + scripts/ntp-wait.mdoc.in@1.37 +2 -2 + NTP_4_2_7P221 + + sntp/sntp-opts.c@1.219 +3 -3 + NTP_4_2_7P221 + + sntp/sntp-opts.h@1.219 +3 -3 + NTP_4_2_7P221 + + sntp/sntp-opts.texi@1.219 +2 -2 + NTP_4_2_7P221 + + sntp/sntp.1sntpman@1.39 +2 -2 + NTP_4_2_7P221 + + sntp/sntp.1sntpmdoc@1.39 +2 -2 + NTP_4_2_7P221 + + sntp/sntp.html@1.219 +2 -2 + NTP_4_2_7P221 + + sntp/sntp.man.in@1.39 +2 -2 + NTP_4_2_7P221 + + sntp/sntp.mdoc.in@1.39 +2 -2 + NTP_4_2_7P221 + + util/ntp-keygen-opts.c@1.223 +3 -3 + NTP_4_2_7P221 + + util/ntp-keygen-opts.h@1.223 +3 -3 + NTP_4_2_7P221 + + util/ntp-keygen-opts.texi@1.224 +2 -2 + NTP_4_2_7P221 + + util/ntp-keygen.1ntp-keygenman@1.37 +2 -2 + NTP_4_2_7P221 + + util/ntp-keygen.1ntp-keygenmdoc@1.37 +2 -2 + NTP_4_2_7P221 + + util/ntp-keygen.man.in@1.37 +2 -2 + NTP_4_2_7P221 + + util/ntp-keygen.mdoc.in@1.37 +2 -2 + NTP_4_2_7P221 + +ChangeSet@1.2673.1.32, 2011-10-10 04:49:18+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2028] ntpd -n (nofork) redirects logging to stderr. + + ChangeLog@1.1032.1.25 +1 -0 + [Bug 2028] ntpd -n (nofork) redirects logging to stderr. + + ntpd/ntpd.c@1.128 +2 -5 + [Bug 2028] ntpd -n (nofork) redirects logging to stderr. + +ChangeSet@1.2673.1.31, 2011-10-09 16:48:41-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1032.1.24 +1 -0 + Documentation updates from Dave Mills + + html/authentic.html@1.9 +6 -13 + Documentation updates from Dave Mills + + html/drivers/scripts/footer.txt@1.3 +1 -1 + Documentation updates from Dave Mills + +ChangeSet@1.2673.1.30, 2011-10-09 20:33:29+00:00, davehart@shiny.ad.hartbrothers.com + DLM does not want STA_UNSYNC set in kernel when ntpd exits. + + ntpd/ntp_loopfilter.c@1.168 +1 -17 + DLM does not want STA_UNSYNC set in kernel when ntpd exits. + +ChangeSet@1.2673.1.29, 2011-10-09 05:08:21+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2025] Switching between daemon and kernel loops can doubly- + correct drift + + ChangeLog@1.1032.1.23 +2 -0 + [Bug 2025] Switching between daemon and kernel loops can doubly- + correct drift + + include/ntp_stdlib.h@1.65 +2 -0 + conditionalize k_st_flags() prototype to match implementation. + + include/ntpd.h@1.168 +1 -0 + [Bug 2025] Switching between daemon and kernel loops can doubly- + correct drift + + include/refclock_atom.h@1.4 +1 -0 + Quiet NANOSECOND redeclaration warning with #undef. + + libntp/statestr.c@1.26 +3 -0 + Make decode_bitflags() (and thereby its wrappers like k_st_flags()) + safe for using in msyslog/DPRINTF/msnprintf arguments with %m by + preserving errno across the function. + + ntpd/cmd_args.c@1.60 +2 -4 + Use loop_config() instead of duplicating logic for -x handling. + + ntpd/ntp_loopfilter.c@1.167 +135 -62 + [Bug 2025] Switching between daemon and kernel loops can doubly- + correct drift + + ntpd/ntp_proto.c@1.323 +1 -1 + [Bug 2025] Switching between daemon and kernel loops can doubly- + correct drift + +ChangeSet@1.2673.1.28, 2011-10-05 09:03:57+00:00, stenn@deacon.udel.edu + NTP_4_2_7P220 + TAG: NTP_4_2_7P220 + + ChangeLog@1.1032.1.22 +1 -0 + NTP_4_2_7P220 + + ntpd/ntpd-opts.c@1.225 +3 -3 + NTP_4_2_7P220 + + ntpd/ntpd-opts.h@1.225 +3 -3 + NTP_4_2_7P220 + + ntpd/ntpd-opts.texi@1.223 +2 -2 + NTP_4_2_7P220 + + ntpd/ntpd.1ntpdman@1.36 +2 -2 + NTP_4_2_7P220 + + ntpd/ntpd.1ntpdmdoc@1.36 +2 -2 + NTP_4_2_7P220 + + ntpd/ntpd.man.in@1.36 +2 -2 + NTP_4_2_7P220 + + ntpd/ntpd.mdoc.in@1.36 +2 -2 + NTP_4_2_7P220 + + ntpdc/ntpdc-opts.c@1.220 +3 -3 + NTP_4_2_7P220 + + ntpdc/ntpdc-opts.h@1.220 +3 -3 + NTP_4_2_7P220 + + ntpdc/ntpdc-opts.texi@1.220 +2 -2 + NTP_4_2_7P220 + + ntpdc/ntpdc.1ntpdcman@1.36 +2 -2 + NTP_4_2_7P220 + + ntpdc/ntpdc.1ntpdcmdoc@1.36 +2 -2 + NTP_4_2_7P220 + + ntpdc/ntpdc.html@1.48 +2 -2 + NTP_4_2_7P220 + + ntpdc/ntpdc.man.in@1.36 +2 -2 + NTP_4_2_7P220 + + ntpdc/ntpdc.mdoc.in@1.36 +2 -2 + NTP_4_2_7P220 + + ntpq/ntpq-opts.c@1.222 +3 -3 + NTP_4_2_7P220 + + ntpq/ntpq-opts.h@1.222 +3 -3 + NTP_4_2_7P220 + + ntpq/ntpq-opts.texi@1.222 +2 -2 + NTP_4_2_7P220 + + ntpq/ntpq.1ntpqman@1.36 +2 -2 + NTP_4_2_7P220 + + ntpq/ntpq.1ntpqmdoc@1.36 +2 -2 + NTP_4_2_7P220 + + ntpq/ntpq.man.in@1.36 +2 -2 + NTP_4_2_7P220 + + ntpq/ntpq.mdoc.in@1.36 +2 -2 + NTP_4_2_7P220 + + ntpsnmpd/ntpsnmpd-opts.c@1.222 +3 -3 + NTP_4_2_7P220 + + ntpsnmpd/ntpsnmpd-opts.h@1.222 +3 -3 + NTP_4_2_7P220 + + ntpsnmpd/ntpsnmpd-opts.texi@1.222 +2 -2 + NTP_4_2_7P220 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.36 +2 -2 + NTP_4_2_7P220 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.36 +2 -2 + NTP_4_2_7P220 + + ntpsnmpd/ntpsnmpd.man.in@1.36 +2 -2 + NTP_4_2_7P220 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.36 +2 -2 + NTP_4_2_7P220 + + packageinfo.sh@1.223 +1 -1 + NTP_4_2_7P220 + + scripts/ntp-wait-opts.texi@1.40 +1 -1 + NTP_4_2_7P220 + + scripts/ntp-wait.1ntp-waitman@1.36 +2 -2 + NTP_4_2_7P220 + + scripts/ntp-wait.1ntp-waitmdoc@1.36 +2 -2 + NTP_4_2_7P220 + + scripts/ntp-wait.html@1.40 +1 -1 + NTP_4_2_7P220 + + scripts/ntp-wait.man.in@1.36 +2 -2 + NTP_4_2_7P220 + + scripts/ntp-wait.mdoc.in@1.36 +2 -2 + NTP_4_2_7P220 + + sntp/sntp-opts.c@1.218 +3 -3 + NTP_4_2_7P220 + + sntp/sntp-opts.h@1.218 +3 -3 + NTP_4_2_7P220 + + sntp/sntp-opts.texi@1.218 +2 -2 + NTP_4_2_7P220 + + sntp/sntp.1sntpman@1.38 +2 -2 + NTP_4_2_7P220 + + sntp/sntp.1sntpmdoc@1.38 +2 -2 + NTP_4_2_7P220 + + sntp/sntp.html@1.218 +2 -2 + NTP_4_2_7P220 + + sntp/sntp.man.in@1.38 +2 -2 + NTP_4_2_7P220 + + sntp/sntp.mdoc.in@1.38 +2 -2 + NTP_4_2_7P220 + + util/ntp-keygen-opts.c@1.222 +3 -3 + NTP_4_2_7P220 + + util/ntp-keygen-opts.h@1.222 +3 -3 + NTP_4_2_7P220 + + util/ntp-keygen-opts.texi@1.223 +2 -2 + NTP_4_2_7P220 + + util/ntp-keygen.1ntp-keygenman@1.36 +2 -2 + NTP_4_2_7P220 + + util/ntp-keygen.1ntp-keygenmdoc@1.36 +2 -2 + NTP_4_2_7P220 + + util/ntp-keygen.man.in@1.36 +2 -2 + NTP_4_2_7P220 + + util/ntp-keygen.mdoc.in@1.36 +2 -2 + NTP_4_2_7P220 + +ChangeSet@1.2673.1.27, 2011-10-05 08:34:46+00:00, davehart@shiny.ad.hartbrothers.com + Keep add_full_recv_buffer() and SetEvent(WaitableIoEventHandle) 1:1 + + include/ntp_refclock.h@1.32 +4 -0 + Keep add_full_recv_buffer() and SetEvent(WaitableIoEventHandle) 1:1 + + ntpd/ntp_refclock.c@1.109 +3 -1 + Keep add_full_recv_buffer() and SetEvent(WaitableIoEventHandle) 1:1 + + ntpd/refclock_parse.c@1.61 +3 -0 + Keep add_full_recv_buffer() and SetEvent(WaitableIoEventHandle) 1:1 + + ports/winnt/ntpd/ntp_iocompletionport.c@1.60 +2 -4 + Keep add_full_recv_buffer() and SetEvent(WaitableIoEventHandle) 1:1 + +ChangeSet@1.2673.1.26, 2011-10-05 07:49:15+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1945] mbg_gps166.h use of _TM_DEFINED conflicts with MS VC. + [Bug 1946] parse_start uses open; does not work on Windows. + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ChangeLog@1.1032.1.21 +3 -0 + [Bug 1945] mbg_gps166.h use of _TM_DEFINED conflicts with MS VC. + [Bug 1946] parse_start uses open; does not work on Windows. + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + include/mbg_gps166.h@1.11 +2 -2 + [Bug 1945] mbg_gps166.h use of _TM_DEFINED conflicts with MS VC. + + include/ntp_refclock.h@1.31 +4 -1 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + libparse/clk_wharton.c@1.8 +1 -1 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ntpd/ntp_io.c@1.359 +15 -22 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ntpd/ntp_refclock.c@1.108 +33 -0 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ntpd/refclock_parse.c@1.60 +13 -10 + [Bug 1946] parse_start uses open; does not work on Windows. + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ports/winnt/include/config.h@1.102 +14 -1 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.59 +17 -15 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ports/winnt/vs2005/ntpd.vcproj@1.16 +12 -240 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.41 +4 -336 + [Bug 1947] Porting parse-based Wharton refclock driver to Windows. + +ChangeSet@1.2673.1.25, 2011-10-04 21:34:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2024] Remove unused system event code EVNT_CLKHOP. + + ChangeLog@1.1032.1.20 +1 -0 + [Bug 2024] Remove unused system event code EVNT_CLKHOP. + + include/ntp.h@1.197 +0 -1 + [Bug 2024] Remove unused system event code EVNT_CLKHOP. + + libntp/statestr.c@1.25 +0 -1 + [Bug 2024] Remove unused system event code EVNT_CLKHOP. + +ChangeSet@1.2673.1.24, 2011-10-04 10:54:55+00:00, stenn@deacon.udel.edu + NTP_4_2_7P219 + TAG: NTP_4_2_7P219 + + ChangeLog@1.1032.1.19 +1 -0 + NTP_4_2_7P219 + + ntpd/ntpd-opts.c@1.224 +3 -3 + NTP_4_2_7P219 + + ntpd/ntpd-opts.h@1.224 +3 -3 + NTP_4_2_7P219 + + ntpd/ntpd-opts.texi@1.222 +2 -2 + NTP_4_2_7P219 + + ntpd/ntpd.1ntpdman@1.35 +2 -2 + NTP_4_2_7P219 + + ntpd/ntpd.1ntpdmdoc@1.35 +2 -2 + NTP_4_2_7P219 + + ntpd/ntpd.man.in@1.35 +2 -2 + NTP_4_2_7P219 + + ntpd/ntpd.mdoc.in@1.35 +2 -2 + NTP_4_2_7P219 + + ntpdc/ntpdc-opts.c@1.219 +3 -3 + NTP_4_2_7P219 + + ntpdc/ntpdc-opts.h@1.219 +3 -3 + NTP_4_2_7P219 + + ntpdc/ntpdc-opts.texi@1.219 +2 -2 + NTP_4_2_7P219 + + ntpdc/ntpdc.1ntpdcman@1.35 +2 -2 + NTP_4_2_7P219 + + ntpdc/ntpdc.1ntpdcmdoc@1.35 +2 -2 + NTP_4_2_7P219 + + ntpdc/ntpdc.html@1.47 +2 -2 + NTP_4_2_7P219 + + ntpdc/ntpdc.man.in@1.35 +2 -2 + NTP_4_2_7P219 + + ntpdc/ntpdc.mdoc.in@1.35 +2 -2 + NTP_4_2_7P219 + + ntpq/ntpq-opts.c@1.221 +3 -3 + NTP_4_2_7P219 + + ntpq/ntpq-opts.h@1.221 +3 -3 + NTP_4_2_7P219 + + ntpq/ntpq-opts.texi@1.221 +2 -2 + NTP_4_2_7P219 + + ntpq/ntpq.1ntpqman@1.35 +2 -2 + NTP_4_2_7P219 + + ntpq/ntpq.1ntpqmdoc@1.35 +2 -2 + NTP_4_2_7P219 + + ntpq/ntpq.man.in@1.35 +2 -2 + NTP_4_2_7P219 + + ntpq/ntpq.mdoc.in@1.35 +2 -2 + NTP_4_2_7P219 + + ntpsnmpd/ntpsnmpd-opts.c@1.221 +3 -3 + NTP_4_2_7P219 + + ntpsnmpd/ntpsnmpd-opts.h@1.221 +3 -3 + NTP_4_2_7P219 + + ntpsnmpd/ntpsnmpd-opts.texi@1.221 +2 -2 + NTP_4_2_7P219 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.35 +2 -2 + NTP_4_2_7P219 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.35 +2 -2 + NTP_4_2_7P219 + + ntpsnmpd/ntpsnmpd.man.in@1.35 +2 -2 + NTP_4_2_7P219 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.35 +2 -2 + NTP_4_2_7P219 + + packageinfo.sh@1.222 +1 -1 + NTP_4_2_7P219 + + scripts/ntp-wait-opts.texi@1.39 +1 -1 + NTP_4_2_7P219 + + scripts/ntp-wait.1ntp-waitman@1.35 +2 -2 + NTP_4_2_7P219 + + scripts/ntp-wait.1ntp-waitmdoc@1.35 +2 -2 + NTP_4_2_7P219 + + scripts/ntp-wait.html@1.39 +1 -1 + NTP_4_2_7P219 + + scripts/ntp-wait.man.in@1.35 +2 -2 + NTP_4_2_7P219 + + scripts/ntp-wait.mdoc.in@1.35 +2 -2 + NTP_4_2_7P219 + + sntp/sntp-opts.c@1.217 +3 -3 + NTP_4_2_7P219 + + sntp/sntp-opts.h@1.217 +3 -3 + NTP_4_2_7P219 + + sntp/sntp-opts.texi@1.217 +2 -2 + NTP_4_2_7P219 + + sntp/sntp.1sntpman@1.37 +2 -2 + NTP_4_2_7P219 + + sntp/sntp.1sntpmdoc@1.37 +2 -2 + NTP_4_2_7P219 + + sntp/sntp.html@1.217 +2 -2 + NTP_4_2_7P219 + + sntp/sntp.man.in@1.37 +2 -2 + NTP_4_2_7P219 + + sntp/sntp.mdoc.in@1.37 +2 -2 + NTP_4_2_7P219 + + util/ntp-keygen-opts.c@1.221 +3 -3 + NTP_4_2_7P219 + + util/ntp-keygen-opts.h@1.221 +3 -3 + NTP_4_2_7P219 + + util/ntp-keygen-opts.texi@1.222 +2 -2 + NTP_4_2_7P219 + + util/ntp-keygen.1ntp-keygenman@1.35 +2 -2 + NTP_4_2_7P219 + + util/ntp-keygen.1ntp-keygenmdoc@1.35 +2 -2 + NTP_4_2_7P219 + + util/ntp-keygen.man.in@1.35 +2 -2 + NTP_4_2_7P219 + + util/ntp-keygen.mdoc.in@1.35 +2 -2 + NTP_4_2_7P219 + +ChangeSet@1.2673.1.23, 2011-10-03 17:51:59-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1032.1.18 +1 -0 + Documentation updates from Dave Mills + + html/authentic.html@1.8 +12 -5 + Documentation updates from Dave Mills + + html/autokey.html@1.21 +3 -3 + Documentation updates from Dave Mills + + html/drivers/driver20.html@1.25 +12 -21 + Documentation updates from Dave Mills + + html/drivers/driver8.html@1.28 +2 -2 + Documentation updates from Dave Mills + + html/history.html@1.2 +2 -2 + Documentation updates from Dave Mills + + html/keygen.html@1.31 +10 -10 + Documentation updates from Dave Mills + + html/release.html@1.42 +3 -3 + Documentation updates from Dave Mills + + html/scripts/footer.txt@1.4 +6 -1 + Documentation updates from Dave Mills + + html/sntp.html@1.9 +4 -4 + Documentation updates from Dave Mills + +ChangeSet@1.2673.1.22, 2011-10-03 05:00:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P218 + TAG: NTP_4_2_7P218 + + ChangeLog@1.1032.1.17 +1 -0 + NTP_4_2_7P218 + + ntpd/ntpd-opts.c@1.223 +3 -3 + NTP_4_2_7P218 + + ntpd/ntpd-opts.h@1.223 +3 -3 + NTP_4_2_7P218 + + ntpd/ntpd-opts.texi@1.221 +2 -2 + NTP_4_2_7P218 + + ntpd/ntpd.1ntpdman@1.34 +2 -2 + NTP_4_2_7P218 + + ntpd/ntpd.1ntpdmdoc@1.34 +2 -2 + NTP_4_2_7P218 + + ntpd/ntpd.man.in@1.34 +2 -2 + NTP_4_2_7P218 + + ntpd/ntpd.mdoc.in@1.34 +2 -2 + NTP_4_2_7P218 + + ntpdc/ntpdc-opts.c@1.218 +3 -3 + NTP_4_2_7P218 + + ntpdc/ntpdc-opts.h@1.218 +3 -3 + NTP_4_2_7P218 + + ntpdc/ntpdc-opts.texi@1.218 +2 -2 + NTP_4_2_7P218 + + ntpdc/ntpdc.1ntpdcman@1.34 +2 -2 + NTP_4_2_7P218 + + ntpdc/ntpdc.1ntpdcmdoc@1.34 +2 -2 + NTP_4_2_7P218 + + ntpdc/ntpdc.html@1.46 +2 -2 + NTP_4_2_7P218 + + ntpdc/ntpdc.man.in@1.34 +2 -2 + NTP_4_2_7P218 + + ntpdc/ntpdc.mdoc.in@1.34 +2 -2 + NTP_4_2_7P218 + + ntpq/ntpq-opts.c@1.220 +3 -3 + NTP_4_2_7P218 + + ntpq/ntpq-opts.h@1.220 +3 -3 + NTP_4_2_7P218 + + ntpq/ntpq-opts.texi@1.220 +2 -2 + NTP_4_2_7P218 + + ntpq/ntpq.1ntpqman@1.34 +2 -2 + NTP_4_2_7P218 + + ntpq/ntpq.1ntpqmdoc@1.34 +2 -2 + NTP_4_2_7P218 + + ntpq/ntpq.man.in@1.34 +2 -2 + NTP_4_2_7P218 + + ntpq/ntpq.mdoc.in@1.34 +2 -2 + NTP_4_2_7P218 + + ntpsnmpd/ntpsnmpd-opts.c@1.220 +3 -3 + NTP_4_2_7P218 + + ntpsnmpd/ntpsnmpd-opts.h@1.220 +3 -3 + NTP_4_2_7P218 + + ntpsnmpd/ntpsnmpd-opts.texi@1.220 +2 -2 + NTP_4_2_7P218 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.34 +2 -2 + NTP_4_2_7P218 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.34 +2 -2 + NTP_4_2_7P218 + + ntpsnmpd/ntpsnmpd.man.in@1.34 +2 -2 + NTP_4_2_7P218 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.34 +2 -2 + NTP_4_2_7P218 + + packageinfo.sh@1.221 +1 -1 + NTP_4_2_7P218 + + scripts/ntp-wait-opts.texi@1.38 +1 -1 + NTP_4_2_7P218 + + scripts/ntp-wait.1ntp-waitman@1.34 +2 -2 + NTP_4_2_7P218 + + scripts/ntp-wait.1ntp-waitmdoc@1.34 +2 -2 + NTP_4_2_7P218 + + scripts/ntp-wait.html@1.38 +1 -1 + NTP_4_2_7P218 + + scripts/ntp-wait.man.in@1.34 +2 -2 + NTP_4_2_7P218 + + scripts/ntp-wait.mdoc.in@1.34 +2 -2 + NTP_4_2_7P218 + + sntp/sntp-opts.c@1.216 +3 -3 + NTP_4_2_7P218 + + sntp/sntp-opts.h@1.216 +3 -3 + NTP_4_2_7P218 + + sntp/sntp-opts.texi@1.216 +2 -2 + NTP_4_2_7P218 + + sntp/sntp.1sntpman@1.36 +2 -2 + NTP_4_2_7P218 + + sntp/sntp.1sntpmdoc@1.36 +2 -2 + NTP_4_2_7P218 + + sntp/sntp.html@1.216 +2 -2 + NTP_4_2_7P218 + + sntp/sntp.man.in@1.36 +2 -2 + NTP_4_2_7P218 + + sntp/sntp.mdoc.in@1.36 +2 -2 + NTP_4_2_7P218 + + util/ntp-keygen-opts.c@1.220 +3 -3 + NTP_4_2_7P218 + + util/ntp-keygen-opts.h@1.220 +3 -3 + NTP_4_2_7P218 + + util/ntp-keygen-opts.texi@1.221 +22 -3 + NTP_4_2_7P218 + + util/ntp-keygen.1ntp-keygenman@1.34 +11 -3 + NTP_4_2_7P218 + + util/ntp-keygen.1ntp-keygenmdoc@1.34 +10 -3 + NTP_4_2_7P218 + + util/ntp-keygen.man.in@1.34 +11 -3 + NTP_4_2_7P218 + + util/ntp-keygen.mdoc.in@1.34 +10 -3 + NTP_4_2_7P218 + +ChangeSet@1.2673.1.21, 2011-10-02 19:41:17-04:00, stenn@deacon.udel.edu + typo + + util/ntp-keygen-opts.def@1.19 +1 -1 + typo + +ChangeSet@1.2673.1.19, 2011-10-02 22:12:47+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2019] Allow selection of cipher for private key files. + ntp-keygen private key cipher default now triple-key triple DES CBC. + ntp-keygen on Windows XP and later systems will now create links + expected by ntpd. They are hardlinks on Windows, soft on POSIX. + + ChangeLog@1.1032.1.15 +4 -0 + [Bug 2019] Allow selection of cipher for private key files. + ntp-keygen private key cipher default now triple-key triple DES CBC. + ntp-keygen on Windows XP and later systems will now create links + expected by ntpd. They are hardlinks on Windows, soft on POSIX. + + + util/ntp-keygen-opts.c@1.219 +68 -38 + [Bug 2019] add -c/--cipher + + util/ntp-keygen-opts.def@1.18 +1 -1 + Minor correction. + + util/ntp-keygen-opts.h@1.219 +32 -25 + [Bug 2019] add -c/--cipher + + util/ntp-keygen.c@1.86 +81 -38 + Change multiple fclose(stdout) to fflush(stdout). + Generate ntp-keygen (hard) links correctly on Windows XP and later. + Use PEM_write_PKCS8PrivateKey() in place of deprecated predecessor. + Existing clients going back to at least 2002 can use the new format + with no changes to deployed code. + + +ChangeSet@1.2673.3.2, 2011-10-02 18:09:07-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/history.html@1.1 +74 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/history.html + + html/history.html@1.0 +0 -0 + +ChangeSet@1.2673.3.1, 2011-10-02 17:43:54-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.1032.3.1 +1 -0 + Documentation updates from Dave Mills + + html/authentic.html@1.7 +10 -10 + Documentation updates from Dave Mills + + html/keygen.html@1.30 +2 -3 + Documentation updates from Dave Mills + + html/release.html@1.41 +2 -1 + Documentation updates from Dave Mills + +ChangeSet@1.2673.1.18, 2011-10-02 19:14:22+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2019] Allow selection of cipher for private key files. + Change default cipher from DES CBC to triple-key triple DES CBC. + + util/ntp-keygen-opts.def@1.17 +15 -0 + Add -C/--cipher option to ntp-keygen for [Bug 2019] + + util/ntp-keygen.c@1.85 +20 -8 + [Bug 2019] Allow selection of cipher for private key files. + Change default cipher from DES CBC to triple-key triple DES CBC. + +ChangeSet@1.2673.1.17, 2011-10-02 08:47:56+00:00, davehart@shiny.ad.hartbrothers.com + ntp-keygen -M is intended to ignore all other defaults and + options, so do not attempt to open existing Autokey host certificate + before generating symmetric keys and terminating. + Restore IFF, MV, and GQ identity parameter filename convention to + ntpkey_par_ in ntpd, matching ntp-keygen. + Change some error logging to syslog to ignore logconfig mask, such + as reporting PPSAPI failure in NMEA and WWVB refclocks. + Conditionalize NMEA serial open message under clockevent. + Send all peer variables to trappers in report_event(). + + ChangeLog@1.1032.1.14 +9 -0 + ntp-keygen -M is intended to ignore all other defaults and + options, so do not attempt to open existing Autokey host certificate + before generating symmetric keys and terminating. + Restore IFF, MV, and GQ identity parameter filename convention to + ntpkey_par_ in ntpd, matching ntp-keygen. + Change some error logging to syslog to ignore logconfig mask, such + as reporting PPSAPI failure in NMEA and WWVB refclocks. + Conditionalize NMEA serial open message under clockevent. + Send all peer variables to trappers in report_event(). + + + include/ntp_syslog.h@1.8 +8 -1 + Provide LOGIF(CLOCKINFO, (LOG_INFO, "msyslog %s", "args")) + as alternative to + NLOG(NLOG_CLOCKINFO) + msyslog(LOG_INFO, "msyslog %s", args); + + ntpd/ntp_control.c@1.171 +6 -21 + Send all peer variables to trappers, as intended. + + ntpd/ntp_crypto.c@1.159 +37 -27 + Restore IFF, MV, and GQ identity parameter filename convention to + ntpkey_par_ in ntpd, matching ntp-keygen. + + ntpd/ntp_loopfilter.c@1.166 +1 -1 + Fix spelling in comment. + + ntpd/refclock_nmea.c@1.63 +32 -34 + Make failure and GPS time syslog output ignore logconfig. + Conditionalize serial output syslog under clockevent. + + ntpd/refclock_wwvb.c@1.32 +10 -11 + Report PPSAPI failure to log regardless of logconfig. + + util/ntp-keygen.c@1.84 +11 -11 + ntp-keygen -M is intended to ignore all other defaults and + options, so do not attempt to open existing Autokey host certificate + before generating symmetric keys and terminating. + +ChangeSet@1.2673.1.16, 2011-09-29 08:06:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P217 + TAG: NTP_4_2_7P217 + + ChangeLog@1.1032.1.13 +1 -0 + NTP_4_2_7P217 + + ntpd/ntpd-opts.c@1.222 +3 -3 + NTP_4_2_7P217 + + ntpd/ntpd-opts.h@1.222 +3 -3 + NTP_4_2_7P217 + + ntpd/ntpd-opts.texi@1.220 +2 -2 + NTP_4_2_7P217 + + ntpd/ntpd.1ntpdman@1.33 +2 -2 + NTP_4_2_7P217 + + ntpd/ntpd.1ntpdmdoc@1.33 +2 -2 + NTP_4_2_7P217 + + ntpd/ntpd.man.in@1.33 +2 -2 + NTP_4_2_7P217 + + ntpd/ntpd.mdoc.in@1.33 +2 -2 + NTP_4_2_7P217 + + ntpdc/ntpdc-opts.c@1.217 +3 -3 + NTP_4_2_7P217 + + ntpdc/ntpdc-opts.h@1.217 +3 -3 + NTP_4_2_7P217 + + ntpdc/ntpdc-opts.texi@1.217 +2 -2 + NTP_4_2_7P217 + + ntpdc/ntpdc.1ntpdcman@1.33 +2 -2 + NTP_4_2_7P217 + + ntpdc/ntpdc.1ntpdcmdoc@1.33 +2 -2 + NTP_4_2_7P217 + + ntpdc/ntpdc.html@1.45 +2 -2 + NTP_4_2_7P217 + + ntpdc/ntpdc.man.in@1.33 +2 -2 + NTP_4_2_7P217 + + ntpdc/ntpdc.mdoc.in@1.33 +2 -2 + NTP_4_2_7P217 + + ntpq/ntpq-opts.c@1.219 +3 -3 + NTP_4_2_7P217 + + ntpq/ntpq-opts.h@1.219 +3 -3 + NTP_4_2_7P217 + + ntpq/ntpq-opts.texi@1.219 +2 -2 + NTP_4_2_7P217 + + ntpq/ntpq.1ntpqman@1.33 +2 -2 + NTP_4_2_7P217 + + ntpq/ntpq.1ntpqmdoc@1.33 +2 -2 + NTP_4_2_7P217 + + ntpq/ntpq.man.in@1.33 +2 -2 + NTP_4_2_7P217 + + ntpq/ntpq.mdoc.in@1.33 +2 -2 + NTP_4_2_7P217 + + ntpsnmpd/ntpsnmpd-opts.c@1.219 +3 -3 + NTP_4_2_7P217 + + ntpsnmpd/ntpsnmpd-opts.h@1.219 +3 -3 + NTP_4_2_7P217 + + ntpsnmpd/ntpsnmpd-opts.texi@1.219 +2 -2 + NTP_4_2_7P217 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.33 +2 -2 + NTP_4_2_7P217 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.33 +2 -2 + NTP_4_2_7P217 + + ntpsnmpd/ntpsnmpd.man.in@1.33 +2 -2 + NTP_4_2_7P217 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.33 +2 -2 + NTP_4_2_7P217 + + packageinfo.sh@1.220 +1 -1 + NTP_4_2_7P217 + + scripts/ntp-wait-opts.texi@1.37 +1 -1 + NTP_4_2_7P217 + + scripts/ntp-wait.1ntp-waitman@1.33 +2 -2 + NTP_4_2_7P217 + + scripts/ntp-wait.1ntp-waitmdoc@1.33 +2 -2 + NTP_4_2_7P217 + + scripts/ntp-wait.html@1.37 +1 -1 + NTP_4_2_7P217 + + scripts/ntp-wait.man.in@1.33 +2 -2 + NTP_4_2_7P217 + + scripts/ntp-wait.mdoc.in@1.33 +2 -2 + NTP_4_2_7P217 + + sntp/sntp-opts.c@1.215 +3 -3 + NTP_4_2_7P217 + + sntp/sntp-opts.h@1.215 +3 -3 + NTP_4_2_7P217 + + sntp/sntp-opts.texi@1.215 +2 -2 + NTP_4_2_7P217 + + sntp/sntp.1sntpman@1.35 +2 -2 + NTP_4_2_7P217 + + sntp/sntp.1sntpmdoc@1.35 +2 -2 + NTP_4_2_7P217 + + sntp/sntp.html@1.215 +2 -2 + NTP_4_2_7P217 + + sntp/sntp.man.in@1.35 +2 -2 + NTP_4_2_7P217 + + sntp/sntp.mdoc.in@1.35 +2 -2 + NTP_4_2_7P217 + + util/ntp-keygen-opts.c@1.218 +3 -3 + NTP_4_2_7P217 + + util/ntp-keygen-opts.h@1.218 +3 -3 + NTP_4_2_7P217 + + util/ntp-keygen-opts.texi@1.220 +34 -20 + NTP_4_2_7P217 + + util/ntp-keygen.1ntp-keygenman@1.33 +24 -10 + NTP_4_2_7P217 + + util/ntp-keygen.1ntp-keygenmdoc@1.33 +24 -10 + NTP_4_2_7P217 + + util/ntp-keygen.man.in@1.33 +24 -10 + NTP_4_2_7P217 + + util/ntp-keygen.mdoc.in@1.33 +24 -10 + NTP_4_2_7P217 + +ChangeSet@1.2673.1.15, 2011-09-29 03:52:53-04:00, stenn@deacon.udel.edu + cleanup + + ChangeLog@1.1032.1.12 +2 -2 + cleanup + +ChangeSet@1.2673.1.14, 2011-09-29 07:17:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2020] ntp-keygen -s no longer sets host in cert file name. + ntp-keygen -i option long name changed from misleading --issuer-name + to --ident. [Backward Incompatible] + + ChangeLog@1.1032.1.11 +3 -0 + [Bug 2020] ntp-keygen -s no longer sets host in cert file name. + ntp-keygen -i option long name changed from misleading --issuer-name + to --ident. [Backward Incompatible] + + ports/winnt/include/sys/time.h@1.7 +1 -1 + Correct type of unused 2nd argument in port's gettimeofday() + + ports/winnt/libntp/util_clockstuff.c@1.6 +2 -2 + Correct type of unused 2nd argument in port's gettimeofday() + + util/ntp-keygen-opts.c@1.217 +17 -17 + ntp-keygen -i option long name changed from misleading --issuer-name + to --ident. [Backward Incompatible] + + util/ntp-keygen-opts.h@1.217 +7 -7 + ntp-keygen -i option long name changed from misleading --issuer-name + to --ident. [Backward Incompatible] + + util/ntp-keygen.c@1.83 +51 -28 + [Bug 2020] ntp-keygen -s no longer sets host in cert file name. + ntp-keygen -i option long name changed from misleading --issuer-name + to --ident. [Backward Incompatible] + +ChangeSet@1.2673.1.13, 2011-09-29 05:16:02+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2009] cleanup warning about adj_systime() returning no value. + [Bug 2020] Expand ntp-keygen-opts.def explanations of host name and + group name options and how they affect output, rename -i long form + from --issuer-name to --ident to match reality. + + libntp/systime.c@1.55.1.2 +3 -3 + [Bug 2009] cleanup: adj_systime() must return a value. + + util/ntp-keygen-opts.def@1.16 +23 -9 + [Bug 2020] groundwork. Clarify interaction of -i group and -s host[@group] + options and rename long option for -i from --issuer-name to --ident, as + the group name is never used for certificate issuer. Spell out how group + and host names are used. Backward compatibility is a relatively minor + issue as the official documentation and Steve's examples mention only + the short flag -i. + + util/ntp-keygen.c@1.82 +9 -9 + [Bug 2020] groundwork. Clarify interaction of -i group and -s host[@group] + options and rename long option for -i from --issuer-name to --ident, as + the group name is never used for certificate issuer. Spell out how group + and host names are used. Backward compatibility is a relatively minor + issue as the official documentation and Steve's examples mention only + the short flag -i. + +ChangeSet@1.2673.1.12, 2011-09-27 10:41:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P216 + TAG: NTP_4_2_7P216 + + ChangeLog@1.1032.1.10 +1 -0 + NTP_4_2_7P216 + + ntpd/ntpd-opts.c@1.221 +3 -3 + NTP_4_2_7P216 + + ntpd/ntpd-opts.h@1.221 +3 -3 + NTP_4_2_7P216 + + ntpd/ntpd-opts.texi@1.219 +2 -2 + NTP_4_2_7P216 + + ntpd/ntpd.1ntpdman@1.32 +2 -2 + NTP_4_2_7P216 + + ntpd/ntpd.1ntpdmdoc@1.32 +2 -2 + NTP_4_2_7P216 + + ntpd/ntpd.man.in@1.32 +2 -2 + NTP_4_2_7P216 + + ntpd/ntpd.mdoc.in@1.32 +2 -2 + NTP_4_2_7P216 + + ntpdc/ntpdc-opts.c@1.216 +3 -3 + NTP_4_2_7P216 + + ntpdc/ntpdc-opts.h@1.216 +3 -3 + NTP_4_2_7P216 + + ntpdc/ntpdc-opts.texi@1.216 +2 -2 + NTP_4_2_7P216 + + ntpdc/ntpdc.1ntpdcman@1.32 +8 -8 + NTP_4_2_7P216 + + ntpdc/ntpdc.1ntpdcmdoc@1.32 +2 -2 + NTP_4_2_7P216 + + ntpdc/ntpdc.html@1.44 +2 -2 + NTP_4_2_7P216 + + ntpdc/ntpdc.man.in@1.32 +8 -8 + NTP_4_2_7P216 + + ntpdc/ntpdc.mdoc.in@1.32 +2 -2 + NTP_4_2_7P216 + + ntpq/ntpq-opts.c@1.218 +3 -3 + NTP_4_2_7P216 + + ntpq/ntpq-opts.h@1.218 +3 -3 + NTP_4_2_7P216 + + ntpq/ntpq-opts.texi@1.218 +2 -2 + NTP_4_2_7P216 + + ntpq/ntpq.1ntpqman@1.32 +2 -2 + NTP_4_2_7P216 + + ntpq/ntpq.1ntpqmdoc@1.32 +2 -2 + NTP_4_2_7P216 + + ntpq/ntpq.man.in@1.32 +2 -2 + NTP_4_2_7P216 + + ntpq/ntpq.mdoc.in@1.32 +2 -2 + NTP_4_2_7P216 + + ntpsnmpd/ntpsnmpd-opts.c@1.218 +3 -3 + NTP_4_2_7P216 + + ntpsnmpd/ntpsnmpd-opts.h@1.218 +3 -3 + NTP_4_2_7P216 + + ntpsnmpd/ntpsnmpd-opts.texi@1.218 +2 -2 + NTP_4_2_7P216 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.32 +2 -2 + NTP_4_2_7P216 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.32 +2 -2 + NTP_4_2_7P216 + + ntpsnmpd/ntpsnmpd.man.in@1.32 +2 -2 + NTP_4_2_7P216 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.32 +2 -2 + NTP_4_2_7P216 + + packageinfo.sh@1.219 +1 -1 + NTP_4_2_7P216 + + scripts/ntp-wait-opts.texi@1.36 +1 -1 + NTP_4_2_7P216 + + scripts/ntp-wait.1ntp-waitman@1.32 +2 -2 + NTP_4_2_7P216 + + scripts/ntp-wait.1ntp-waitmdoc@1.32 +2 -2 + NTP_4_2_7P216 + + scripts/ntp-wait.html@1.36 +1 -1 + NTP_4_2_7P216 + + scripts/ntp-wait.man.in@1.32 +2 -2 + NTP_4_2_7P216 + + scripts/ntp-wait.mdoc.in@1.32 +2 -2 + NTP_4_2_7P216 + + sntp/sntp-opts.c@1.214 +9 -9 + NTP_4_2_7P216 + + sntp/sntp-opts.h@1.214 +3 -3 + NTP_4_2_7P216 + + sntp/sntp-opts.texi@1.214 +21 -21 + NTP_4_2_7P216 + + sntp/sntp.1sntpman@1.34 +15 -15 + NTP_4_2_7P216 + + sntp/sntp.1sntpmdoc@1.34 +15 -15 + NTP_4_2_7P216 + + sntp/sntp.html@1.214 +21 -21 + NTP_4_2_7P216 + + sntp/sntp.man.in@1.34 +15 -15 + NTP_4_2_7P216 + + sntp/sntp.mdoc.in@1.34 +15 -15 + NTP_4_2_7P216 + + util/ntp-keygen-opts.c@1.216 +3 -3 + NTP_4_2_7P216 + + util/ntp-keygen-opts.h@1.216 +3 -3 + NTP_4_2_7P216 + + util/ntp-keygen-opts.texi@1.219 +2 -2 + NTP_4_2_7P216 + + util/ntp-keygen.1ntp-keygenman@1.32 +2 -2 + NTP_4_2_7P216 + + util/ntp-keygen.1ntp-keygenmdoc@1.32 +2 -2 + NTP_4_2_7P216 + + util/ntp-keygen.man.in@1.32 +2 -2 + NTP_4_2_7P216 + + util/ntp-keygen.mdoc.in@1.32 +2 -2 + NTP_4_2_7P216 + +ChangeSet@1.2673.2.1, 2011-09-27 05:49:23-04:00, stenn@psp-deb1.ntp.org + mdoc2man improvements + + ChangeLog@1.1032.2.2 +1 -0 + mdoc2man improvements + + ChangeLog@1.1032.2.1 +1 -0 + sntp documentation tag cleanup + + sntp/ag-tpl/mdoc2man@1.2 +27 -14 + mdoc2man improvements + + sntp/sntp-opts.def@1.39 +13 -13 + sntp documentation tag cleanup + +ChangeSet@1.2673.1.10, 2011-09-24 02:03:00+00:00, stenn@deacon.udel.edu + NTP_4_2_7P215 + TAG: NTP_4_2_7P215 + + ChangeLog@1.1032.1.8 +1 -0 + NTP_4_2_7P215 + + ntpd/ntpd-opts.c@1.220 +3 -3 + NTP_4_2_7P215 + + ntpd/ntpd-opts.h@1.220 +3 -3 + NTP_4_2_7P215 + + ntpd/ntpd-opts.texi@1.218 +2 -2 + NTP_4_2_7P215 + + ntpd/ntpd.1ntpdman@1.31 +2 -2 + NTP_4_2_7P215 + + ntpd/ntpd.1ntpdmdoc@1.31 +2 -2 + NTP_4_2_7P215 + + ntpd/ntpd.man.in@1.31 +2 -2 + NTP_4_2_7P215 + + ntpd/ntpd.mdoc.in@1.31 +2 -2 + NTP_4_2_7P215 + + ntpdc/ntpdc-opts.c@1.215 +3 -3 + NTP_4_2_7P215 + + ntpdc/ntpdc-opts.h@1.215 +3 -3 + NTP_4_2_7P215 + + ntpdc/ntpdc-opts.texi@1.215 +2 -2 + NTP_4_2_7P215 + + ntpdc/ntpdc.1ntpdcman@1.31 +309 -3 + NTP_4_2_7P215 + + ntpdc/ntpdc.1ntpdcmdoc@1.31 +2 -2 + NTP_4_2_7P215 + + ntpdc/ntpdc.html@1.43 +2 -2 + NTP_4_2_7P215 + + ntpdc/ntpdc.man.in@1.31 +309 -3 + NTP_4_2_7P215 + + ntpdc/ntpdc.mdoc.in@1.31 +2 -2 + NTP_4_2_7P215 + + ntpq/ntpq-opts.c@1.217 +3 -3 + NTP_4_2_7P215 + + ntpq/ntpq-opts.h@1.217 +3 -3 + NTP_4_2_7P215 + + ntpq/ntpq-opts.texi@1.217 +2 -2 + NTP_4_2_7P215 + + ntpq/ntpq.1ntpqman@1.31 +2 -2 + NTP_4_2_7P215 + + ntpq/ntpq.1ntpqmdoc@1.31 +2 -2 + NTP_4_2_7P215 + + ntpq/ntpq.man.in@1.31 +2 -2 + NTP_4_2_7P215 + + ntpq/ntpq.mdoc.in@1.31 +2 -2 + NTP_4_2_7P215 + + ntpsnmpd/ntpsnmpd-opts.c@1.217 +3 -3 + NTP_4_2_7P215 + + ntpsnmpd/ntpsnmpd-opts.h@1.217 +3 -3 + NTP_4_2_7P215 + + ntpsnmpd/ntpsnmpd-opts.texi@1.217 +2 -2 + NTP_4_2_7P215 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.31 +2 -2 + NTP_4_2_7P215 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.31 +2 -2 + NTP_4_2_7P215 + + ntpsnmpd/ntpsnmpd.man.in@1.31 +2 -2 + NTP_4_2_7P215 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.31 +2 -2 + NTP_4_2_7P215 + + packageinfo.sh@1.218 +1 -1 + NTP_4_2_7P215 + + scripts/ntp-wait-opts.texi@1.35 +1 -1 + NTP_4_2_7P215 + + scripts/ntp-wait.1ntp-waitman@1.31 +2 -2 + NTP_4_2_7P215 + + scripts/ntp-wait.1ntp-waitmdoc@1.31 +2 -2 + NTP_4_2_7P215 + + scripts/ntp-wait.html@1.35 +1 -1 + NTP_4_2_7P215 + + scripts/ntp-wait.man.in@1.31 +2 -2 + NTP_4_2_7P215 + + scripts/ntp-wait.mdoc.in@1.31 +2 -2 + NTP_4_2_7P215 + + sntp/sntp-opts.c@1.213 +3 -3 + NTP_4_2_7P215 + + sntp/sntp-opts.h@1.213 +3 -3 + NTP_4_2_7P215 + + sntp/sntp-opts.texi@1.213 +2 -2 + NTP_4_2_7P215 + + sntp/sntp.1sntpman@1.33 +2 -2 + NTP_4_2_7P215 + + sntp/sntp.1sntpmdoc@1.33 +2 -2 + NTP_4_2_7P215 + + sntp/sntp.html@1.213 +2 -2 + NTP_4_2_7P215 + + sntp/sntp.man.in@1.33 +2 -2 + NTP_4_2_7P215 + + sntp/sntp.mdoc.in@1.33 +2 -2 + NTP_4_2_7P215 + + util/ntp-keygen-opts.c@1.215 +3 -3 + NTP_4_2_7P215 + + util/ntp-keygen-opts.h@1.215 +3 -3 + NTP_4_2_7P215 + + util/ntp-keygen-opts.texi@1.218 +2 -2 + NTP_4_2_7P215 + + util/ntp-keygen.1ntp-keygenman@1.31 +2 -2 + NTP_4_2_7P215 + + util/ntp-keygen.1ntp-keygenmdoc@1.31 +2 -2 + NTP_4_2_7P215 + + util/ntp-keygen.man.in@1.31 +2 -2 + NTP_4_2_7P215 + + util/ntp-keygen.mdoc.in@1.31 +2 -2 + NTP_4_2_7P215 + +ChangeSet@1.2673.1.9, 2011-09-23 21:47:46-04:00, stenn@deacon.udel.edu + Use patched mdoc2man script, from Eric Feng + + ChangeLog@1.1032.1.7 +2 -0 + Use patched mdoc2man script, from Eric Feng + +ChangeSet@1.2673.1.8, 2011-09-23 05:32:43+00:00, stenn@psp-fb1.ntp.org + Use updated mdoc2man + + sntp/ag-tpl/mdoc2man@1.1 +288 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev/sntp/ag-tpl/mdoc2man + + sntp/ag-tpl/mdoc2man@1.0 +0 -0 + +ChangeSet@1.2082.4.237, 2011-09-23 03:38:30+00:00, stenn@deacon.udel.edu + NTP_4_2_6P4 + TAG: NTP_4_2_6P4 + + ChangeLog@1.496.26.170 +1 -0 + NTP_4_2_6P4 + + ntpd/ntpd-opts.c@1.248.39.1 +5 -5 + NTP_4_2_6P4 + + ntpd/ntpd-opts.h@1.248.39.1 +3 -3 + NTP_4_2_6P4 + + ntpd/ntpd-opts.texi@1.246.38.1 +2 -2 + NTP_4_2_6P4 + + ntpd/ntpd.1@1.246.38.1 +2 -2 + NTP_4_2_6P4 + + ntpdc/ntpdc-opts.c@1.244.39.1 +5 -5 + NTP_4_2_6P4 + + ntpdc/ntpdc-opts.h@1.244.39.1 +3 -3 + NTP_4_2_6P4 + + ntpdc/ntpdc-opts.texi@1.243.38.1 +2 -2 + NTP_4_2_6P4 + + ntpdc/ntpdc.1@1.243.38.1 +2 -2 + NTP_4_2_6P4 + + ntpq/ntpq-opts.c@1.245.39.1 +5 -5 + NTP_4_2_6P4 + + ntpq/ntpq-opts.h@1.245.39.1 +3 -3 + NTP_4_2_6P4 + + ntpq/ntpq-opts.texi@1.244.38.1 +2 -2 + NTP_4_2_6P4 + + ntpq/ntpq.1@1.244.38.1 +2 -2 + NTP_4_2_6P4 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.40.1 +5 -5 + NTP_4_2_6P4 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.40.1 +3 -3 + NTP_4_2_6P4 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.39.1 +2 -2 + NTP_4_2_6P4 + + ntpsnmpd/ntpsnmpd.1@1.122.39.1 +2 -2 + NTP_4_2_6P4 + + packageinfo.sh@1.255.36.2 +3 -3 + NTP_4_2_6P4 + + sntp/sntp-opts.c@1.117.38.1 +7 -7 + NTP_4_2_6P4 + + sntp/sntp-opts.h@1.117.38.1 +3 -3 + NTP_4_2_6P4 + + sntp/sntp-opts.texi@1.117.37.1 +4 -4 + NTP_4_2_6P4 + + sntp/sntp.1@1.117.37.1 +2 -2 + NTP_4_2_6P4 + + sntp/sntp.html@1.7.38.1 +42 -60 + NTP_4_2_6P4 + + util/ntp-keygen-opts.c@1.247.39.1 +5 -5 + NTP_4_2_6P4 + + util/ntp-keygen-opts.h@1.247.39.1 +3 -3 + NTP_4_2_6P4 + + util/ntp-keygen-opts.texi@1.246.38.1 +2 -2 + NTP_4_2_6P4 + + util/ntp-keygen.1@1.246.38.1 +2 -2 + NTP_4_2_6P4 + +ChangeSet@1.2082.4.236, 2011-09-22 22:40:12-04:00, stenn@deacon.udel.edu + ntp-4.2.6p4 + + ChangeLog@1.496.26.169 +1 -0 + ntp-4.2.6p4 + + NEWS@1.119 +62 -37 + ntp-4.2.6p4 + + packageinfo.sh@1.255.36.1 +1 -1 + ntp-4.2.6p4 + +ChangeSet@1.2673.1.6, 2011-09-20 19:45:00+00:00, stenn@deacon.udel.edu + NTP_4_2_7P214 + TAG: NTP_4_2_7P214 + + ChangeLog@1.1032.1.5 +1 -0 + NTP_4_2_7P214 + + ntpd/ntpd-opts.c@1.219 +3 -3 + NTP_4_2_7P214 + + ntpd/ntpd-opts.h@1.219 +3 -3 + NTP_4_2_7P214 + + ntpd/ntpd-opts.texi@1.217 +2 -2 + NTP_4_2_7P214 + + ntpd/ntpd.1ntpdman@1.30 +2 -2 + NTP_4_2_7P214 + + ntpd/ntpd.1ntpdmdoc@1.30 +2 -2 + NTP_4_2_7P214 + + ntpd/ntpd.man.in@1.30 +2 -2 + NTP_4_2_7P214 + + ntpd/ntpd.mdoc.in@1.30 +2 -2 + NTP_4_2_7P214 + + ntpdc/ntpdc-opts.c@1.214 +3 -3 + NTP_4_2_7P214 + + ntpdc/ntpdc-opts.h@1.214 +3 -3 + NTP_4_2_7P214 + + ntpdc/ntpdc-opts.texi@1.214 +2 -2 + NTP_4_2_7P214 + + ntpdc/ntpdc.1ntpdcman@1.30 +2 -2 + NTP_4_2_7P214 + + ntpdc/ntpdc.1ntpdcmdoc@1.30 +2 -2 + NTP_4_2_7P214 + + ntpdc/ntpdc.html@1.42 +2 -2 + NTP_4_2_7P214 + + ntpdc/ntpdc.man.in@1.30 +2 -2 + NTP_4_2_7P214 + + ntpdc/ntpdc.mdoc.in@1.30 +2 -2 + NTP_4_2_7P214 + + ntpq/ntpq-opts.c@1.216 +3 -3 + NTP_4_2_7P214 + + ntpq/ntpq-opts.h@1.216 +3 -3 + NTP_4_2_7P214 + + ntpq/ntpq-opts.texi@1.216 +2 -2 + NTP_4_2_7P214 + + ntpq/ntpq.1ntpqman@1.30 +2 -2 + NTP_4_2_7P214 + + ntpq/ntpq.1ntpqmdoc@1.30 +2 -2 + NTP_4_2_7P214 + + ntpq/ntpq.man.in@1.30 +2 -2 + NTP_4_2_7P214 + + ntpq/ntpq.mdoc.in@1.30 +2 -2 + NTP_4_2_7P214 + + ntpsnmpd/ntpsnmpd-opts.c@1.216 +3 -3 + NTP_4_2_7P214 + + ntpsnmpd/ntpsnmpd-opts.h@1.216 +3 -3 + NTP_4_2_7P214 + + ntpsnmpd/ntpsnmpd-opts.texi@1.216 +2 -2 + NTP_4_2_7P214 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.30 +2 -2 + NTP_4_2_7P214 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.30 +2 -2 + NTP_4_2_7P214 + + ntpsnmpd/ntpsnmpd.man.in@1.30 +2 -2 + NTP_4_2_7P214 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.30 +2 -2 + NTP_4_2_7P214 + + packageinfo.sh@1.217 +1 -1 + NTP_4_2_7P214 + + scripts/ntp-wait-opts.texi@1.34 +1 -1 + NTP_4_2_7P214 + + scripts/ntp-wait.1ntp-waitman@1.30 +2 -2 + NTP_4_2_7P214 + + scripts/ntp-wait.1ntp-waitmdoc@1.30 +2 -2 + NTP_4_2_7P214 + + scripts/ntp-wait.html@1.34 +1 -1 + NTP_4_2_7P214 + + scripts/ntp-wait.man.in@1.30 +2 -2 + NTP_4_2_7P214 + + scripts/ntp-wait.mdoc.in@1.30 +2 -2 + NTP_4_2_7P214 + + sntp/sntp-opts.c@1.212 +3 -3 + NTP_4_2_7P214 + + sntp/sntp-opts.h@1.212 +3 -3 + NTP_4_2_7P214 + + sntp/sntp-opts.texi@1.212 +2 -2 + NTP_4_2_7P214 + + sntp/sntp.1sntpman@1.32 +2 -2 + NTP_4_2_7P214 + + sntp/sntp.1sntpmdoc@1.32 +2 -2 + NTP_4_2_7P214 + + sntp/sntp.html@1.212 +2 -2 + NTP_4_2_7P214 + + sntp/sntp.man.in@1.32 +2 -2 + NTP_4_2_7P214 + + sntp/sntp.mdoc.in@1.32 +2 -2 + NTP_4_2_7P214 + + util/ntp-keygen-opts.c@1.214 +3 -3 + NTP_4_2_7P214 + + util/ntp-keygen-opts.h@1.214 +3 -3 + NTP_4_2_7P214 + + util/ntp-keygen-opts.texi@1.217 +2 -2 + NTP_4_2_7P214 + + util/ntp-keygen.1ntp-keygenman@1.30 +2 -2 + NTP_4_2_7P214 + + util/ntp-keygen.1ntp-keygenmdoc@1.30 +2 -2 + NTP_4_2_7P214 + + util/ntp-keygen.man.in@1.30 +2 -2 + NTP_4_2_7P214 + + util/ntp-keygen.mdoc.in@1.30 +2 -2 + NTP_4_2_7P214 + +ChangeSet@1.2673.1.5, 2011-09-20 15:29:47-04:00, stenn@deacon.udel.edu + whitespace cleanup + + Makefile.am@1.114 +3 -3 + whitespace cleanup + +ChangeSet@1.2673.1.4, 2011-09-20 01:32:36+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2009] EVNT_NSET adj_systime() mishandled by Windows ntpd. + + ChangeLog@1.1032.1.4 +1 -0 + [Bug 2009] EVNT_NSET adj_systime() mishandled by Windows ntpd. + + ports/winnt/ntpd/nt_clockstuff.c@1.53 +33 -19 + [Bug 2009] EVNT_NSET adj_systime() mishandled by Windows ntpd. + +ChangeSet@1.2673.1.3, 2011-09-19 18:09:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1981] Initial offset convergence applies frequency correction 2x + with kernel discipline. + [Bug 2008] Initial offset convergence degraded with 500 PPM adjtime(). + + ChangeLog@1.1032.1.3 +3 -0 + [Bug 1981] Initial offset convergence applies frequency correction 2x + with kernel discipline. + [Bug 2008] Initial offset convergence degraded with 500 PPM adjtime(). + + libntp/systime.c@1.55.1.1 +12 -0 + [Bug 1981] Initial offset convergence applies frequency correction 2x + with kernel discipline. + [Bug 2008] Initial offset convergence degraded with 500 PPM adjtime(). + + ntpd/ntp_loopfilter.c@1.165 +61 -47 + [Bug 1981] Initial offset convergence applies frequency correction 2x + with kernel discipline. + [Bug 2008] Initial offset convergence degraded with 500 PPM adjtime(). + +ChangeSet@1.2673.1.2, 2011-09-08 11:46:02+00:00, stenn@deacon.udel.edu + NTP_4_2_7P213 + TAG: NTP_4_2_7P213 + + ChangeLog@1.1032.1.2 +1 -0 + NTP_4_2_7P213 + + ntpd/ntpd-opts.c@1.218 +3 -3 + NTP_4_2_7P213 + + ntpd/ntpd-opts.h@1.218 +3 -3 + NTP_4_2_7P213 + + ntpd/ntpd-opts.texi@1.216 +2 -2 + NTP_4_2_7P213 + + ntpd/ntpd.1ntpdman@1.29 +2 -2 + NTP_4_2_7P213 + + ntpd/ntpd.1ntpdmdoc@1.29 +2 -2 + NTP_4_2_7P213 + + ntpd/ntpd.man.in@1.29 +2 -2 + NTP_4_2_7P213 + + ntpd/ntpd.mdoc.in@1.29 +2 -2 + NTP_4_2_7P213 + + ntpdc/ntpdc-opts.c@1.213 +3 -3 + NTP_4_2_7P213 + + ntpdc/ntpdc-opts.h@1.213 +3 -3 + NTP_4_2_7P213 + + ntpdc/ntpdc-opts.texi@1.213 +2 -2 + NTP_4_2_7P213 + + ntpdc/ntpdc.1ntpdcman@1.29 +2 -2 + NTP_4_2_7P213 + + ntpdc/ntpdc.1ntpdcmdoc@1.29 +2 -2 + NTP_4_2_7P213 + + ntpdc/ntpdc.html@1.41 +2 -2 + NTP_4_2_7P213 + + ntpdc/ntpdc.man.in@1.29 +2 -2 + NTP_4_2_7P213 + + ntpdc/ntpdc.mdoc.in@1.29 +2 -2 + NTP_4_2_7P213 + + ntpq/ntpq-opts.c@1.215 +3 -3 + NTP_4_2_7P213 + + ntpq/ntpq-opts.h@1.215 +3 -3 + NTP_4_2_7P213 + + ntpq/ntpq-opts.texi@1.215 +2 -2 + NTP_4_2_7P213 + + ntpq/ntpq.1ntpqman@1.29 +2 -2 + NTP_4_2_7P213 + + ntpq/ntpq.1ntpqmdoc@1.29 +2 -2 + NTP_4_2_7P213 + + ntpq/ntpq.man.in@1.29 +2 -2 + NTP_4_2_7P213 + + ntpq/ntpq.mdoc.in@1.29 +2 -2 + NTP_4_2_7P213 + + ntpsnmpd/ntpsnmpd-opts.c@1.215 +3 -3 + NTP_4_2_7P213 + + ntpsnmpd/ntpsnmpd-opts.h@1.215 +3 -3 + NTP_4_2_7P213 + + ntpsnmpd/ntpsnmpd-opts.texi@1.215 +2 -2 + NTP_4_2_7P213 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.29 +2 -2 + NTP_4_2_7P213 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.29 +2 -2 + NTP_4_2_7P213 + + ntpsnmpd/ntpsnmpd.man.in@1.29 +2 -2 + NTP_4_2_7P213 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.29 +2 -2 + NTP_4_2_7P213 + + packageinfo.sh@1.216 +1 -1 + NTP_4_2_7P213 + + scripts/ntp-wait-opts.texi@1.33 +1 -1 + NTP_4_2_7P213 + + scripts/ntp-wait.1ntp-waitman@1.29 +2 -2 + NTP_4_2_7P213 + + scripts/ntp-wait.1ntp-waitmdoc@1.29 +2 -2 + NTP_4_2_7P213 + + scripts/ntp-wait.html@1.33 +1 -1 + NTP_4_2_7P213 + + scripts/ntp-wait.man.in@1.29 +2 -2 + NTP_4_2_7P213 + + scripts/ntp-wait.mdoc.in@1.29 +2 -2 + NTP_4_2_7P213 + + sntp/sntp-opts.c@1.211 +3 -3 + NTP_4_2_7P213 + + sntp/sntp-opts.h@1.211 +3 -3 + NTP_4_2_7P213 + + sntp/sntp-opts.texi@1.211 +2 -2 + NTP_4_2_7P213 + + sntp/sntp.1sntpman@1.31 +2 -2 + NTP_4_2_7P213 + + sntp/sntp.1sntpmdoc@1.31 +2 -2 + NTP_4_2_7P213 + + sntp/sntp.html@1.211 +2 -2 + NTP_4_2_7P213 + + sntp/sntp.man.in@1.31 +2 -2 + NTP_4_2_7P213 + + sntp/sntp.mdoc.in@1.31 +2 -2 + NTP_4_2_7P213 + + util/ntp-keygen-opts.c@1.213 +3 -3 + NTP_4_2_7P213 + + util/ntp-keygen-opts.h@1.213 +3 -3 + NTP_4_2_7P213 + + util/ntp-keygen-opts.texi@1.216 +2 -2 + NTP_4_2_7P213 + + util/ntp-keygen.1ntp-keygenman@1.29 +2 -2 + NTP_4_2_7P213 + + util/ntp-keygen.1ntp-keygenmdoc@1.29 +2 -2 + NTP_4_2_7P213 + + util/ntp-keygen.man.in@1.29 +2 -2 + NTP_4_2_7P213 + + util/ntp-keygen.mdoc.in@1.29 +2 -2 + NTP_4_2_7P213 + +ChangeSet@1.2673.1.1, 2011-09-07 20:08:08+02:00, jnperlin@hydra.localnet + [Bug 1999] NMEA driver should not send PMOTG once per second + + ChangeLog@1.1032.1.1 +1 -0 + [Bug 1999] NMEA driver should not send PMOTG once per second + + ntpd/refclock_nmea.c@1.62 +27 -7 + [Bug 1999] NMEA driver should not send PMOTG once per second. NMEA ouput support disabled by preprocessor conditionals. + +ChangeSet@1.2674, 2011-09-07 19:25:23+02:00, jnperlin@hydra.localnet + [Bug 1995] added support for getting build time stamp + + ChangeLog@1.1033 +2 -0 + [Bug 1995] compile time stamp support for 'step_systime()' + + include/ntp_calendar.h@1.10 +18 -0 + [Bug 1995] added support for getting build time stamp + + libntp/ntp_calendar.c@1.7 +169 -41 + [Bug 1995] added support for getting build time stamp; refactoring of some code pathes + + libntp/systime.c@1.56 +105 -62 + [Bug 1995] added support for NTP era unfolding based on build time stamp in 'step_systime()' + +ChangeSet@1.2673, 2011-09-07 11:53:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P212 + TAG: NTP_4_2_7P212 + + ChangeLog@1.1032 +1 -0 + NTP_4_2_7P212 + + ntpd/ntpd-opts.c@1.217 +3 -3 + NTP_4_2_7P212 + + ntpd/ntpd-opts.h@1.217 +3 -3 + NTP_4_2_7P212 + + ntpd/ntpd-opts.texi@1.215 +2 -2 + NTP_4_2_7P212 + + ntpd/ntpd.1ntpdman@1.28 +2 -2 + NTP_4_2_7P212 + + ntpd/ntpd.1ntpdmdoc@1.28 +2 -2 + NTP_4_2_7P212 + + ntpd/ntpd.man.in@1.28 +2 -2 + NTP_4_2_7P212 + + ntpd/ntpd.mdoc.in@1.28 +2 -2 + NTP_4_2_7P212 + + ntpdc/ntpdc-opts.c@1.212 +3 -3 + NTP_4_2_7P212 + + ntpdc/ntpdc-opts.h@1.212 +3 -3 + NTP_4_2_7P212 + + ntpdc/ntpdc-opts.texi@1.212 +2 -2 + NTP_4_2_7P212 + + ntpdc/ntpdc.1ntpdcman@1.28 +2 -2 + NTP_4_2_7P212 + + ntpdc/ntpdc.1ntpdcmdoc@1.28 +2 -2 + NTP_4_2_7P212 + + ntpdc/ntpdc.html@1.40 +2 -2 + NTP_4_2_7P212 + + ntpdc/ntpdc.man.in@1.28 +2 -2 + NTP_4_2_7P212 + + ntpdc/ntpdc.mdoc.in@1.28 +2 -2 + NTP_4_2_7P212 + + ntpq/ntpq-opts.c@1.214 +3 -3 + NTP_4_2_7P212 + + ntpq/ntpq-opts.h@1.214 +3 -3 + NTP_4_2_7P212 + + ntpq/ntpq-opts.texi@1.214 +2 -2 + NTP_4_2_7P212 + + ntpq/ntpq.1ntpqman@1.28 +2 -2 + NTP_4_2_7P212 + + ntpq/ntpq.1ntpqmdoc@1.28 +2 -2 + NTP_4_2_7P212 + + ntpq/ntpq.man.in@1.28 +2 -2 + NTP_4_2_7P212 + + ntpq/ntpq.mdoc.in@1.28 +2 -2 + NTP_4_2_7P212 + + ntpsnmpd/ntpsnmpd-opts.c@1.214 +3 -3 + NTP_4_2_7P212 + + ntpsnmpd/ntpsnmpd-opts.h@1.214 +3 -3 + NTP_4_2_7P212 + + ntpsnmpd/ntpsnmpd-opts.texi@1.214 +2 -2 + NTP_4_2_7P212 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.28 +2 -2 + NTP_4_2_7P212 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.28 +2 -2 + NTP_4_2_7P212 + + ntpsnmpd/ntpsnmpd.man.in@1.28 +2 -2 + NTP_4_2_7P212 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.28 +2 -2 + NTP_4_2_7P212 + + packageinfo.sh@1.215 +1 -1 + NTP_4_2_7P212 + + scripts/ntp-wait-opts.texi@1.32 +1 -1 + NTP_4_2_7P212 + + scripts/ntp-wait.1ntp-waitman@1.28 +2 -2 + NTP_4_2_7P212 + + scripts/ntp-wait.1ntp-waitmdoc@1.28 +2 -2 + NTP_4_2_7P212 + + scripts/ntp-wait.html@1.32 +1 -1 + NTP_4_2_7P212 + + scripts/ntp-wait.man.in@1.28 +2 -2 + NTP_4_2_7P212 + + scripts/ntp-wait.mdoc.in@1.28 +2 -2 + NTP_4_2_7P212 + + sntp/sntp-opts.c@1.210 +3 -3 + NTP_4_2_7P212 + + sntp/sntp-opts.h@1.210 +3 -3 + NTP_4_2_7P212 + + sntp/sntp-opts.texi@1.210 +2 -2 + NTP_4_2_7P212 + + sntp/sntp.1sntpman@1.30 +2 -2 + NTP_4_2_7P212 + + sntp/sntp.1sntpmdoc@1.30 +2 -2 + NTP_4_2_7P212 + + sntp/sntp.html@1.210 +2 -2 + NTP_4_2_7P212 + + sntp/sntp.man.in@1.30 +2 -2 + NTP_4_2_7P212 + + sntp/sntp.mdoc.in@1.30 +2 -2 + NTP_4_2_7P212 + + util/ntp-keygen-opts.c@1.212 +3 -3 + NTP_4_2_7P212 + + util/ntp-keygen-opts.h@1.212 +3 -3 + NTP_4_2_7P212 + + util/ntp-keygen-opts.texi@1.215 +2 -2 + NTP_4_2_7P212 + + util/ntp-keygen.1ntp-keygenman@1.28 +2 -2 + NTP_4_2_7P212 + + util/ntp-keygen.1ntp-keygenmdoc@1.28 +2 -2 + NTP_4_2_7P212 + + util/ntp-keygen.man.in@1.28 +2 -2 + NTP_4_2_7P212 + + util/ntp-keygen.mdoc.in@1.28 +2 -2 + NTP_4_2_7P212 + +ChangeSet@1.2082.4.235, 2011-09-07 04:29:25+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2003] libntpq ntpq_read_assoc_peervars() broken. + + ChangeLog@1.496.26.168 +1 -0 + [Bug 2003] libntpq ntpq_read_assoc_peervars() broken. + + ntpq/libntpq.c@1.3.1.6 +56 -66 + [Bug 2003] libntpq ntpq_read_assoc_peervars() broken. + + ntpq/libntpq.h@1.3.1.4 +1 -1 + [Bug 2003] libntpq ntpq_read_assoc_peervars() broken. + +ChangeSet@1.2671, 2011-09-01 11:04:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P211 + TAG: NTP_4_2_7P211 + + ChangeLog@1.1030 +1 -0 + NTP_4_2_7P211 + + ntpd/ntpd-opts.c@1.216 +3 -3 + NTP_4_2_7P211 + + ntpd/ntpd-opts.h@1.216 +3 -3 + NTP_4_2_7P211 + + ntpd/ntpd-opts.texi@1.214 +2 -2 + NTP_4_2_7P211 + + ntpd/ntpd.1ntpdman@1.27 +2 -2 + NTP_4_2_7P211 + + ntpd/ntpd.1ntpdmdoc@1.27 +2 -2 + NTP_4_2_7P211 + + ntpd/ntpd.man.in@1.27 +2 -2 + NTP_4_2_7P211 + + ntpd/ntpd.mdoc.in@1.27 +2 -2 + NTP_4_2_7P211 + + ntpdc/ntpdc-opts.c@1.211 +3 -3 + NTP_4_2_7P211 + + ntpdc/ntpdc-opts.h@1.211 +3 -3 + NTP_4_2_7P211 + + ntpdc/ntpdc-opts.texi@1.211 +2 -2 + NTP_4_2_7P211 + + ntpdc/ntpdc.1ntpdcman@1.27 +2 -2 + NTP_4_2_7P211 + + ntpdc/ntpdc.1ntpdcmdoc@1.27 +2 -2 + NTP_4_2_7P211 + + ntpdc/ntpdc.html@1.39 +2 -2 + NTP_4_2_7P211 + + ntpdc/ntpdc.man.in@1.27 +2 -2 + NTP_4_2_7P211 + + ntpdc/ntpdc.mdoc.in@1.27 +2 -2 + NTP_4_2_7P211 + + ntpq/ntpq-opts.c@1.213 +3 -3 + NTP_4_2_7P211 + + ntpq/ntpq-opts.h@1.213 +3 -3 + NTP_4_2_7P211 + + ntpq/ntpq-opts.texi@1.213 +2 -2 + NTP_4_2_7P211 + + ntpq/ntpq.1ntpqman@1.27 +2 -2 + NTP_4_2_7P211 + + ntpq/ntpq.1ntpqmdoc@1.27 +2 -2 + NTP_4_2_7P211 + + ntpq/ntpq.man.in@1.27 +2 -2 + NTP_4_2_7P211 + + ntpq/ntpq.mdoc.in@1.27 +2 -2 + NTP_4_2_7P211 + + ntpsnmpd/ntpsnmpd-opts.c@1.213 +3 -3 + NTP_4_2_7P211 + + ntpsnmpd/ntpsnmpd-opts.h@1.213 +3 -3 + NTP_4_2_7P211 + + ntpsnmpd/ntpsnmpd-opts.texi@1.213 +2 -2 + NTP_4_2_7P211 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.27 +2 -2 + NTP_4_2_7P211 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.27 +2 -2 + NTP_4_2_7P211 + + ntpsnmpd/ntpsnmpd.man.in@1.27 +2 -2 + NTP_4_2_7P211 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.27 +2 -2 + NTP_4_2_7P211 + + packageinfo.sh@1.214 +1 -1 + NTP_4_2_7P211 + + scripts/ntp-wait-opts.texi@1.31 +1 -1 + NTP_4_2_7P211 + + scripts/ntp-wait.1ntp-waitman@1.27 +2 -2 + NTP_4_2_7P211 + + scripts/ntp-wait.1ntp-waitmdoc@1.27 +2 -2 + NTP_4_2_7P211 + + scripts/ntp-wait.html@1.31 +1 -1 + NTP_4_2_7P211 + + scripts/ntp-wait.man.in@1.27 +2 -2 + NTP_4_2_7P211 + + scripts/ntp-wait.mdoc.in@1.27 +2 -2 + NTP_4_2_7P211 + + sntp/sntp-opts.c@1.209 +3 -3 + NTP_4_2_7P211 + + sntp/sntp-opts.h@1.209 +3 -3 + NTP_4_2_7P211 + + sntp/sntp-opts.texi@1.209 +2 -2 + NTP_4_2_7P211 + + sntp/sntp.1sntpman@1.29 +2 -2 + NTP_4_2_7P211 + + sntp/sntp.1sntpmdoc@1.29 +2 -2 + NTP_4_2_7P211 + + sntp/sntp.html@1.209 +2 -2 + NTP_4_2_7P211 + + sntp/sntp.man.in@1.29 +2 -2 + NTP_4_2_7P211 + + sntp/sntp.mdoc.in@1.29 +2 -2 + NTP_4_2_7P211 + + util/ntp-keygen-opts.c@1.211 +3 -3 + NTP_4_2_7P211 + + util/ntp-keygen-opts.h@1.211 +3 -3 + NTP_4_2_7P211 + + util/ntp-keygen-opts.texi@1.214 +2 -2 + NTP_4_2_7P211 + + util/ntp-keygen.1ntp-keygenman@1.27 +2 -2 + NTP_4_2_7P211 + + util/ntp-keygen.1ntp-keygenmdoc@1.27 +2 -2 + NTP_4_2_7P211 + + util/ntp-keygen.man.in@1.27 +2 -2 + NTP_4_2_7P211 + + util/ntp-keygen.mdoc.in@1.27 +2 -2 + NTP_4_2_7P211 + +ChangeSet@1.2461.1.9, 2011-08-31 17:07:44+00:00, davehart@shiny.ad.hartbrothers.com + make libevent/test/*.sh scripts executable + + sntp/libevent/test/rpcgen_wrapper.sh@1.2 +0 -0 + Change mode to -rwxrwxr-x + + sntp/libevent/test/test-ratelim.sh@1.2 +0 -0 + Change mode to -rwxrwxr-x + +ChangeSet@1.2669, 2011-08-31 16:46:40+00:00, davehart@shiny.ad.hartbrothers.com + Update libevent to git head (2.1 branch) as of 2.0.14-stable. + + Applies to prior merge cset. + + ChangeLog@1.1029 +1 -0 + Update libevent to git head (2.1 branch) as of 2.0.14-stable. + +ChangeSet@1.2667, 2011-08-31 16:37:06+00:00, davehart@shiny.ad.hartbrothers.com + Remove now-unsupported vc6 and vs2003 subdirs of ports/winnt. + + BitKeeper/deleted/04/ntpkeygen.vcproj~7e53b51bab97a85@1.7 +0 -0 + Delete: ports/winnt/vs2003/ntpkeygen.vcproj + + BitKeeper/deleted/11/libntp.vcproj~ae0be90114fde0a7@1.23 +0 -0 + Delete: ports/winnt/vs2003/libntp.vcproj + + BitKeeper/deleted/42/ntpdc.vcproj~531302457eef61a9@1.7 +0 -0 + Delete: ports/winnt/vs2003/ntpdc.vcproj + + BitKeeper/deleted/43/ntpdc.dsp~29080509@1.31 +0 -0 + Delete: ports/winnt/vc6/ntpdc.dsp + + BitKeeper/deleted/4a/ntp.sln~b86a8294928e984c@1.3 +0 -0 + Delete: ports/winnt/vs2003/ntp.sln + + BitKeeper/deleted/67/ntpq.dsp~29080509@1.32 +0 -0 + Delete: ports/winnt/vc6/ntpq.dsp + + BitKeeper/deleted/69/ntp.dsw~29080509@1.14 +0 -0 + Delete: ports/winnt/vc6/ntp.dsw + + BitKeeper/deleted/9a/ntpdate.dsp~29080509@1.26 +0 -0 + Delete: ports/winnt/vc6/ntpdate.dsp + + BitKeeper/deleted/a2/ntpdate.vcproj~208e4d43d00e01e7@1.5 +0 -0 + Delete: ports/winnt/vs2003/ntpdate.vcproj + + BitKeeper/deleted/ad/Instsrv.vcproj~aa43ae49bdb6d4d6@1.2 +0 -0 + Delete: ports/winnt/vs2003/Instsrv.vcproj + + BitKeeper/deleted/ae/libntp.dsp~29080509@1.64 +0 -0 + Delete: ports/winnt/vc6/libntp.dsp + + BitKeeper/deleted/b0/Instsrv.dsp~29080509@1.13 +0 -0 + Delete: ports/winnt/vc6/Instsrv.dsp + + BitKeeper/deleted/c9/ntpd.vcproj~c453035eff854e7c@1.15 +0 -0 + Delete: ports/winnt/vs2003/ntpd.vcproj + + BitKeeper/deleted/db/ntpkeygen.dsp~d24bb34d@1.24 +0 -0 + Delete: ports/winnt/vc6/ntpkeygen.dsp + + BitKeeper/deleted/e2/ntpq.vcproj~dbbd02e21a47962f@1.7 +0 -0 + Delete: ports/winnt/vs2003/ntpq.vcproj + + BitKeeper/deleted/f7/ntpd.dsp~29080509@1.54 +0 -0 + Delete: ports/winnt/vc6/ntpd.dsp + +ChangeSet@1.2461.1.8, 2011-08-31 16:12:20+00:00, davehart@shiny.ad.hartbrothers.com + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/ChangeLog@1.5 +25 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/Makefile.am@1.1.1.5 +1 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/buffer.c@1.6 +12 -6 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/buffer_iocp.c@1.4 +3 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/bufferevent-internal.h@1.4 +4 -1 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/bufferevent.c@1.4 +15 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/bufferevent_async.c@1.4 +41 -15 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/bufferevent_filter.c@1.4 +1 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/bufferevent_openssl.c@1.5 +5 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/bufferevent_ratelim.c@1.3 +33 -2 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/bufferevent_sock.c@1.4 +4 -2 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/configure.in@1.1.1.4 +18 -16 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/defer-internal.h@1.3 +4 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/evbuffer-internal.h@1.4 +2 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/evdns.c@1.1.1.4 +2 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/event-internal.h@1.1.1.4 +10 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/event.c@1.1.1.5 +234 -100 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/evrpc.c@1.4 +16 -5 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/evutil.c@1.1.1.4 +1 -1 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/evutil_rand.c@1.4 +12 -4 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/http.c@1.1.1.5 +1 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/include/event2/dns.h@1.4 +1 -1 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/include/event2/event.h@1.1.1.4 +32 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/include/event2/event_compat.h@1.3 +2 -2 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/kqueue.c@1.5 +7 -9 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/m4/libevent_openssl.m4@1.1 +47 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/m4/libevent_openssl.m4@1.0 +0 -0 + + sntp/libevent/m4/ntp_pkg_config.m4@1.1 +27 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/m4/ntp_pkg_config.m4@1.0 +0 -0 + + sntp/libevent/minheap-internal.h@1.3 +34 -6 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/sample/Makefile.am@1.1.1.4 +1 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/sample/dns-example.c@1.1.1.3 +4 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/sample/http-server.c@1.1.1.4 +4 -1 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/signal.c@1.5 +3 -1 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/test/Makefile.am@1.1.1.4 +10 -5 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/test/bench_http.c@1.3 +16 -3 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/test/rpcgen_wrapper.sh@1.1 +41 -0 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + + sntp/libevent/test/rpcgen_wrapper.sh@1.0 +0 -0 + + sntp/libevent/test/test-ratelim.c@1.1.1.3 +18 -1 + Update to libevent master (to be 2.1) as of 2.0.14-stable, HEAD git commit + 148458e0a1fd25e167aa2ef229d1c9a70b27c3e9 + +ChangeSet@1.2666, 2011-08-31 04:15:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P210 + TAG: NTP_4_2_7P210 + + ChangeLog@1.1028 +1 -0 + NTP_4_2_7P210 + + ntpd/ntpd-opts.c@1.215 +3 -3 + NTP_4_2_7P210 + + ntpd/ntpd-opts.h@1.215 +3 -3 + NTP_4_2_7P210 + + ntpd/ntpd-opts.texi@1.213 +2 -2 + NTP_4_2_7P210 + + ntpd/ntpd.1ntpdman@1.26 +2 -2 + NTP_4_2_7P210 + + ntpd/ntpd.1ntpdmdoc@1.26 +2 -2 + NTP_4_2_7P210 + + ntpd/ntpd.man.in@1.26 +2 -2 + NTP_4_2_7P210 + + ntpd/ntpd.mdoc.in@1.26 +2 -2 + NTP_4_2_7P210 + + ntpdc/ntpdc-opts.c@1.210 +3 -3 + NTP_4_2_7P210 + + ntpdc/ntpdc-opts.h@1.210 +3 -3 + NTP_4_2_7P210 + + ntpdc/ntpdc-opts.texi@1.210 +2 -2 + NTP_4_2_7P210 + + ntpdc/ntpdc.1ntpdcman@1.26 +2 -2 + NTP_4_2_7P210 + + ntpdc/ntpdc.1ntpdcmdoc@1.26 +2 -2 + NTP_4_2_7P210 + + ntpdc/ntpdc.html@1.38 +2 -2 + NTP_4_2_7P210 + + ntpdc/ntpdc.man.in@1.26 +2 -2 + NTP_4_2_7P210 + + ntpdc/ntpdc.mdoc.in@1.26 +2 -2 + NTP_4_2_7P210 + + ntpq/ntpq-opts.c@1.212 +3 -3 + NTP_4_2_7P210 + + ntpq/ntpq-opts.h@1.212 +3 -3 + NTP_4_2_7P210 + + ntpq/ntpq-opts.texi@1.212 +2 -2 + NTP_4_2_7P210 + + ntpq/ntpq.1ntpqman@1.26 +2 -2 + NTP_4_2_7P210 + + ntpq/ntpq.1ntpqmdoc@1.26 +2 -2 + NTP_4_2_7P210 + + ntpq/ntpq.man.in@1.26 +2 -2 + NTP_4_2_7P210 + + ntpq/ntpq.mdoc.in@1.26 +2 -2 + NTP_4_2_7P210 + + ntpsnmpd/ntpsnmpd-opts.c@1.212 +3 -3 + NTP_4_2_7P210 + + ntpsnmpd/ntpsnmpd-opts.h@1.212 +3 -3 + NTP_4_2_7P210 + + ntpsnmpd/ntpsnmpd-opts.texi@1.212 +2 -2 + NTP_4_2_7P210 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.26 +2 -2 + NTP_4_2_7P210 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.26 +2 -2 + NTP_4_2_7P210 + + ntpsnmpd/ntpsnmpd.man.in@1.26 +2 -2 + NTP_4_2_7P210 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.26 +2 -2 + NTP_4_2_7P210 + + packageinfo.sh@1.213 +1 -1 + NTP_4_2_7P210 + + scripts/ntp-wait-opts.texi@1.30 +1 -1 + NTP_4_2_7P210 + + scripts/ntp-wait.1ntp-waitman@1.26 +2 -2 + NTP_4_2_7P210 + + scripts/ntp-wait.1ntp-waitmdoc@1.26 +2 -2 + NTP_4_2_7P210 + + scripts/ntp-wait.html@1.30 +1 -1 + NTP_4_2_7P210 + + scripts/ntp-wait.man.in@1.26 +2 -2 + NTP_4_2_7P210 + + scripts/ntp-wait.mdoc.in@1.26 +2 -2 + NTP_4_2_7P210 + + sntp/sntp-opts.c@1.208 +3 -3 + NTP_4_2_7P210 + + sntp/sntp-opts.h@1.208 +3 -3 + NTP_4_2_7P210 + + sntp/sntp-opts.texi@1.208 +2 -2 + NTP_4_2_7P210 + + sntp/sntp.1sntpman@1.28 +2 -2 + NTP_4_2_7P210 + + sntp/sntp.1sntpmdoc@1.28 +2 -2 + NTP_4_2_7P210 + + sntp/sntp.html@1.208 +2 -2 + NTP_4_2_7P210 + + sntp/sntp.man.in@1.28 +2 -2 + NTP_4_2_7P210 + + sntp/sntp.mdoc.in@1.28 +2 -2 + NTP_4_2_7P210 + + util/ntp-keygen-opts.c@1.210 +3 -3 + NTP_4_2_7P210 + + util/ntp-keygen-opts.h@1.210 +3 -3 + NTP_4_2_7P210 + + util/ntp-keygen-opts.texi@1.213 +2 -2 + NTP_4_2_7P210 + + util/ntp-keygen.1ntp-keygenman@1.26 +2 -2 + NTP_4_2_7P210 + + util/ntp-keygen.1ntp-keygenmdoc@1.26 +2 -2 + NTP_4_2_7P210 + + util/ntp-keygen.man.in@1.26 +2 -2 + NTP_4_2_7P210 + + util/ntp-keygen.mdoc.in@1.26 +2 -2 + NTP_4_2_7P210 + +ChangeSet@1.2665, 2011-08-30 09:01:00+00:00, davehart@shiny.ad.hartbrothers.com + Require -D4 or higher for ntpd SIGALRM debug trace from [Bug 2000]. + + ChangeLog@1.1027 +1 -0 + Require -D4 or higher for ntpd SIGALRM debug trace from [Bug 2000]. + + ntpd/ntp_timer.c@1.65 +10 -10 + Require -D4 or higher for ntpd SIGALRM debug trace from [Bug 2000]. + +ChangeSet@1.2664, 2011-08-27 10:47:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P209 + TAG: NTP_4_2_7P209 + + ChangeLog@1.1026 +1 -0 + NTP_4_2_7P209 + + ntpd/ntpd-opts.c@1.214 +3 -3 + NTP_4_2_7P209 + + ntpd/ntpd-opts.h@1.214 +3 -3 + NTP_4_2_7P209 + + ntpd/ntpd-opts.texi@1.212 +2 -2 + NTP_4_2_7P209 + + ntpd/ntpd.1ntpdman@1.25 +2 -2 + NTP_4_2_7P209 + + ntpd/ntpd.1ntpdmdoc@1.25 +2 -2 + NTP_4_2_7P209 + + ntpd/ntpd.man.in@1.25 +2 -2 + NTP_4_2_7P209 + + ntpd/ntpd.mdoc.in@1.25 +2 -2 + NTP_4_2_7P209 + + ntpdc/ntpdc-opts.c@1.209 +3 -3 + NTP_4_2_7P209 + + ntpdc/ntpdc-opts.h@1.209 +3 -3 + NTP_4_2_7P209 + + ntpdc/ntpdc-opts.texi@1.209 +2 -2 + NTP_4_2_7P209 + + ntpdc/ntpdc.1ntpdcman@1.25 +2 -2 + NTP_4_2_7P209 + + ntpdc/ntpdc.1ntpdcmdoc@1.25 +2 -2 + NTP_4_2_7P209 + + ntpdc/ntpdc.html@1.37 +2 -2 + NTP_4_2_7P209 + + ntpdc/ntpdc.man.in@1.25 +2 -2 + NTP_4_2_7P209 + + ntpdc/ntpdc.mdoc.in@1.25 +2 -2 + NTP_4_2_7P209 + + ntpq/ntpq-opts.c@1.211 +3 -3 + NTP_4_2_7P209 + + ntpq/ntpq-opts.h@1.211 +3 -3 + NTP_4_2_7P209 + + ntpq/ntpq-opts.texi@1.211 +2 -2 + NTP_4_2_7P209 + + ntpq/ntpq.1ntpqman@1.25 +2 -2 + NTP_4_2_7P209 + + ntpq/ntpq.1ntpqmdoc@1.25 +2 -2 + NTP_4_2_7P209 + + ntpq/ntpq.man.in@1.25 +2 -2 + NTP_4_2_7P209 + + ntpq/ntpq.mdoc.in@1.25 +2 -2 + NTP_4_2_7P209 + + ntpsnmpd/ntpsnmpd-opts.c@1.211 +3 -3 + NTP_4_2_7P209 + + ntpsnmpd/ntpsnmpd-opts.h@1.211 +3 -3 + NTP_4_2_7P209 + + ntpsnmpd/ntpsnmpd-opts.texi@1.211 +2 -2 + NTP_4_2_7P209 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.25 +2 -2 + NTP_4_2_7P209 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.25 +2 -2 + NTP_4_2_7P209 + + ntpsnmpd/ntpsnmpd.man.in@1.25 +2 -2 + NTP_4_2_7P209 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.25 +2 -2 + NTP_4_2_7P209 + + packageinfo.sh@1.212 +1 -1 + NTP_4_2_7P209 + + scripts/ntp-wait-opts.texi@1.29 +1 -1 + NTP_4_2_7P209 + + scripts/ntp-wait.1ntp-waitman@1.25 +2 -2 + NTP_4_2_7P209 + + scripts/ntp-wait.1ntp-waitmdoc@1.25 +2 -2 + NTP_4_2_7P209 + + scripts/ntp-wait.html@1.29 +1 -1 + NTP_4_2_7P209 + + scripts/ntp-wait.man.in@1.25 +2 -2 + NTP_4_2_7P209 + + scripts/ntp-wait.mdoc.in@1.25 +2 -2 + NTP_4_2_7P209 + + sntp/sntp-opts.c@1.207 +3 -3 + NTP_4_2_7P209 + + sntp/sntp-opts.h@1.207 +3 -3 + NTP_4_2_7P209 + + sntp/sntp-opts.texi@1.207 +2 -2 + NTP_4_2_7P209 + + sntp/sntp.1sntpman@1.27 +2 -2 + NTP_4_2_7P209 + + sntp/sntp.1sntpmdoc@1.27 +2 -2 + NTP_4_2_7P209 + + sntp/sntp.html@1.207 +2 -2 + NTP_4_2_7P209 + + sntp/sntp.man.in@1.27 +2 -2 + NTP_4_2_7P209 + + sntp/sntp.mdoc.in@1.27 +2 -2 + NTP_4_2_7P209 + + util/ntp-keygen-opts.c@1.209 +3 -3 + NTP_4_2_7P209 + + util/ntp-keygen-opts.h@1.209 +3 -3 + NTP_4_2_7P209 + + util/ntp-keygen-opts.texi@1.212 +2 -2 + NTP_4_2_7P209 + + util/ntp-keygen.1ntp-keygenman@1.25 +2 -2 + NTP_4_2_7P209 + + util/ntp-keygen.1ntp-keygenmdoc@1.25 +2 -2 + NTP_4_2_7P209 + + util/ntp-keygen.man.in@1.25 +2 -2 + NTP_4_2_7P209 + + util/ntp-keygen.mdoc.in@1.25 +2 -2 + NTP_4_2_7P209 + +ChangeSet@1.2663, 2011-08-27 03:38:01-04:00, stenn@deacon.udel.edu + Use pre-calculated values for the sntp synch distance checks + + sntp/tests/packetHandling.cpp@1.9 +5 -7 + Use pre-calculated values for the sntp synch distance checks + +ChangeSet@1.2662, 2011-08-27 03:18:26-04:00, stenn@deacon.udel.edu + Update sntp test to use synch distance instead of root dispersion + + ChangeLog@1.1025 +2 -0 + Update sntp test to use synch distance instead of root dispersion + + sntp/tests/packetHandling.cpp@1.8 +10 -6 + Update sntp test to use synch distance instead of root dispersion + +ChangeSet@1.2661, 2011-08-27 07:07:45+00:00, davehart@shiny.ad.hartbrothers.com + Fix copy/paste error (SIGIO -> SIGPOLL) + + libntp/work_thread.c@1.11 +3 -3 + Fix copy/paste error (SIGIO -> SIGPOLL) + +ChangeSet@1.2660, 2011-08-27 02:33:48-04:00, stenn@deacon.udel.edu + cleanup + + ChangeLog@1.1024 +2 -0 + cleanup + +ChangeSet@1.2659, 2011-08-27 05:24:07+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2000] ntpd worker threads must block signals expected in main thread. + + ChangeLog@1.1023 +2 -0 + [Bug 2000] ntpd worker threads must block signals expected in main thread. + + include/ntpd.h@1.167 +14 -0 + Expose signal number macros previously private to ntpd.c for use by work_thread.c. + + libntp/syssignal.c@1.14 +1 -1 + tiny tweak + + libntp/work_thread.c@1.10 +57 -0 + [Bug 2000] ntpd worker threads must block signals expected in main thread. + + ntpd/ntp_timer.c@1.64 +116 -81 + Check for failures setting interval timer, use more common code in + setitimer()/timer_settime() paths. + + ntpd/ntpd.c@1.127 +44 -47 + [Bug 2000] ntpd worker threads must block signals expected in main thread. + +ChangeSet@1.2658, 2011-08-27 04:19:04+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2001] add ntpq -c timerstats like ntpdc -c timerstats. + + ChangeLog@1.1022 +1 -0 + [Bug 2001] add ntpq -c timerstats like ntpdc -c timerstats. + + ntpd/ntp_control.c@1.170 +21 -2 + [Bug 2001] add ntpq -c timerstats like ntpdc -c timerstats. + + ntpq/ntpq-subs.c@1.88 +25 -1 + [Bug 2001] add ntpq -c timerstats like ntpdc -c timerstats. + +ChangeSet@1.2082.4.234, 2011-08-27 03:34:10+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 2001] ntpdc timerstats reports overruns as handled. + + ChangeLog@1.496.26.167 +1 -0 + [Bug 2001] ntpdc timerstats reports overruns as handled. + + ntpd/ntp_request.c@1.82.1.5 +11 -16 + [Bug 2001] ntpdc timerstats reports overruns as handled. + +ChangeSet@1.2656, 2011-08-24 09:02:39+00:00, stenn@deacon.udel.edu + NTP_4_2_7P208 + TAG: NTP_4_2_7P208 + + ChangeLog@1.1020 +1 -0 + NTP_4_2_7P208 + + ntpd/ntpd-opts.c@1.213 +3 -3 + NTP_4_2_7P208 + + ntpd/ntpd-opts.h@1.213 +3 -3 + NTP_4_2_7P208 + + ntpd/ntpd-opts.texi@1.211 +2 -2 + NTP_4_2_7P208 + + ntpd/ntpd.1ntpdman@1.24 +2 -2 + NTP_4_2_7P208 + + ntpd/ntpd.1ntpdmdoc@1.24 +2 -2 + NTP_4_2_7P208 + + ntpd/ntpd.man.in@1.24 +2 -2 + NTP_4_2_7P208 + + ntpd/ntpd.mdoc.in@1.24 +2 -2 + NTP_4_2_7P208 + + ntpdc/ntpdc-opts.c@1.208 +3 -3 + NTP_4_2_7P208 + + ntpdc/ntpdc-opts.h@1.208 +3 -3 + NTP_4_2_7P208 + + ntpdc/ntpdc-opts.texi@1.208 +2 -2 + NTP_4_2_7P208 + + ntpdc/ntpdc.1ntpdcman@1.24 +2 -2 + NTP_4_2_7P208 + + ntpdc/ntpdc.1ntpdcmdoc@1.24 +2 -2 + NTP_4_2_7P208 + + ntpdc/ntpdc.html@1.36 +2 -2 + NTP_4_2_7P208 + + ntpdc/ntpdc.man.in@1.24 +2 -2 + NTP_4_2_7P208 + + ntpdc/ntpdc.mdoc.in@1.24 +2 -2 + NTP_4_2_7P208 + + ntpq/ntpq-opts.c@1.210 +3 -3 + NTP_4_2_7P208 + + ntpq/ntpq-opts.h@1.210 +3 -3 + NTP_4_2_7P208 + + ntpq/ntpq-opts.texi@1.210 +2 -2 + NTP_4_2_7P208 + + ntpq/ntpq.1ntpqman@1.24 +2 -2 + NTP_4_2_7P208 + + ntpq/ntpq.1ntpqmdoc@1.24 +2 -2 + NTP_4_2_7P208 + + ntpq/ntpq.man.in@1.24 +2 -2 + NTP_4_2_7P208 + + ntpq/ntpq.mdoc.in@1.24 +2 -2 + NTP_4_2_7P208 + + ntpsnmpd/ntpsnmpd-opts.c@1.210 +3 -3 + NTP_4_2_7P208 + + ntpsnmpd/ntpsnmpd-opts.h@1.210 +3 -3 + NTP_4_2_7P208 + + ntpsnmpd/ntpsnmpd-opts.texi@1.210 +2 -2 + NTP_4_2_7P208 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.24 +2 -2 + NTP_4_2_7P208 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.24 +2 -2 + NTP_4_2_7P208 + + ntpsnmpd/ntpsnmpd.man.in@1.24 +2 -2 + NTP_4_2_7P208 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.24 +2 -2 + NTP_4_2_7P208 + + packageinfo.sh@1.211 +1 -1 + NTP_4_2_7P208 + + scripts/ntp-wait-opts.texi@1.28 +1 -1 + NTP_4_2_7P208 + + scripts/ntp-wait.1ntp-waitman@1.24 +2 -2 + NTP_4_2_7P208 + + scripts/ntp-wait.1ntp-waitmdoc@1.24 +2 -2 + NTP_4_2_7P208 + + scripts/ntp-wait.html@1.28 +1 -1 + NTP_4_2_7P208 + + scripts/ntp-wait.man.in@1.24 +2 -2 + NTP_4_2_7P208 + + scripts/ntp-wait.mdoc.in@1.24 +2 -2 + NTP_4_2_7P208 + + sntp/sntp-opts.c@1.206 +3 -3 + NTP_4_2_7P208 + + sntp/sntp-opts.h@1.206 +3 -3 + NTP_4_2_7P208 + + sntp/sntp-opts.texi@1.206 +2 -2 + NTP_4_2_7P208 + + sntp/sntp.1sntpman@1.26 +2 -2 + NTP_4_2_7P208 + + sntp/sntp.1sntpmdoc@1.26 +2 -2 + NTP_4_2_7P208 + + sntp/sntp.html@1.206 +2 -2 + NTP_4_2_7P208 + + sntp/sntp.man.in@1.26 +2 -2 + NTP_4_2_7P208 + + sntp/sntp.mdoc.in@1.26 +2 -2 + NTP_4_2_7P208 + + util/ntp-keygen-opts.c@1.208 +3 -3 + NTP_4_2_7P208 + + util/ntp-keygen-opts.h@1.208 +3 -3 + NTP_4_2_7P208 + + util/ntp-keygen-opts.texi@1.211 +2 -2 + NTP_4_2_7P208 + + util/ntp-keygen.1ntp-keygenman@1.24 +2 -2 + NTP_4_2_7P208 + + util/ntp-keygen.1ntp-keygenmdoc@1.24 +2 -2 + NTP_4_2_7P208 + + util/ntp-keygen.man.in@1.24 +2 -2 + NTP_4_2_7P208 + + util/ntp-keygen.mdoc.in@1.24 +2 -2 + NTP_4_2_7P208 + +ChangeSet@1.2655, 2011-08-24 03:50:28-04:00, stenn@deacon.udel.edu + Fix the CLOCK_MONOTONIC TRACE() message + + ChangeLog@1.1019 +1 -0 + Fix the CLOCK_MONOTONIC TRACE() message + + sntp/main.c@1.79 +2 -1 + Fix the CLOCK_MONOTONIC TRACE() message + +ChangeSet@1.2654, 2011-08-22 05:13:12+00:00, stenn@deacon.udel.edu + NTP_4_2_7P207 + TAG: NTP_4_2_7P207 + + ChangeLog@1.1018 +1 -0 + NTP_4_2_7P207 + + ntpd/ntpd-opts.c@1.212 +3 -3 + NTP_4_2_7P207 + + ntpd/ntpd-opts.h@1.212 +3 -3 + NTP_4_2_7P207 + + ntpd/ntpd-opts.texi@1.210 +2 -2 + NTP_4_2_7P207 + + ntpd/ntpd.1ntpdman@1.23 +2 -2 + NTP_4_2_7P207 + + ntpd/ntpd.1ntpdmdoc@1.23 +2 -2 + NTP_4_2_7P207 + + ntpd/ntpd.man.in@1.23 +2 -2 + NTP_4_2_7P207 + + ntpd/ntpd.mdoc.in@1.23 +2 -2 + NTP_4_2_7P207 + + ntpdc/ntpdc-opts.c@1.207 +3 -3 + NTP_4_2_7P207 + + ntpdc/ntpdc-opts.h@1.207 +3 -3 + NTP_4_2_7P207 + + ntpdc/ntpdc-opts.texi@1.207 +2 -2 + NTP_4_2_7P207 + + ntpdc/ntpdc.1ntpdcman@1.23 +2 -2 + NTP_4_2_7P207 + + ntpdc/ntpdc.1ntpdcmdoc@1.23 +2 -2 + NTP_4_2_7P207 + + ntpdc/ntpdc.html@1.35 +2 -2 + NTP_4_2_7P207 + + ntpdc/ntpdc.man.in@1.23 +2 -2 + NTP_4_2_7P207 + + ntpdc/ntpdc.mdoc.in@1.23 +2 -2 + NTP_4_2_7P207 + + ntpq/ntpq-opts.c@1.209 +3 -3 + NTP_4_2_7P207 + + ntpq/ntpq-opts.h@1.209 +3 -3 + NTP_4_2_7P207 + + ntpq/ntpq-opts.texi@1.209 +2 -2 + NTP_4_2_7P207 + + ntpq/ntpq.1ntpqman@1.23 +2 -2 + NTP_4_2_7P207 + + ntpq/ntpq.1ntpqmdoc@1.23 +2 -2 + NTP_4_2_7P207 + + ntpq/ntpq.man.in@1.23 +2 -2 + NTP_4_2_7P207 + + ntpq/ntpq.mdoc.in@1.23 +2 -2 + NTP_4_2_7P207 + + ntpsnmpd/ntpsnmpd-opts.c@1.209 +3 -3 + NTP_4_2_7P207 + + ntpsnmpd/ntpsnmpd-opts.h@1.209 +3 -3 + NTP_4_2_7P207 + + ntpsnmpd/ntpsnmpd-opts.texi@1.209 +2 -2 + NTP_4_2_7P207 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.23 +2 -2 + NTP_4_2_7P207 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.23 +2 -2 + NTP_4_2_7P207 + + ntpsnmpd/ntpsnmpd.man.in@1.23 +2 -2 + NTP_4_2_7P207 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.23 +2 -2 + NTP_4_2_7P207 + + packageinfo.sh@1.210 +1 -1 + NTP_4_2_7P207 + + scripts/ntp-wait-opts.texi@1.27 +1 -1 + NTP_4_2_7P207 + + scripts/ntp-wait.1ntp-waitman@1.23 +8 -7 + NTP_4_2_7P207 + + scripts/ntp-wait.1ntp-waitmdoc@1.23 +7 -6 + NTP_4_2_7P207 + + scripts/ntp-wait.html@1.27 +1 -1 + NTP_4_2_7P207 + + scripts/ntp-wait.man.in@1.23 +8 -7 + NTP_4_2_7P207 + + scripts/ntp-wait.mdoc.in@1.23 +7 -6 + NTP_4_2_7P207 + + sntp/sntp-opts.c@1.205 +3 -3 + NTP_4_2_7P207 + + sntp/sntp-opts.h@1.205 +3 -3 + NTP_4_2_7P207 + + sntp/sntp-opts.texi@1.205 +2 -2 + NTP_4_2_7P207 + + sntp/sntp.1sntpman@1.25 +2 -2 + NTP_4_2_7P207 + + sntp/sntp.1sntpmdoc@1.25 +2 -2 + NTP_4_2_7P207 + + sntp/sntp.html@1.205 +2 -2 + NTP_4_2_7P207 + + sntp/sntp.man.in@1.25 +2 -2 + NTP_4_2_7P207 + + sntp/sntp.mdoc.in@1.25 +2 -2 + NTP_4_2_7P207 + + util/ntp-keygen-opts.c@1.207 +3 -3 + NTP_4_2_7P207 + + util/ntp-keygen-opts.h@1.207 +3 -3 + NTP_4_2_7P207 + + util/ntp-keygen-opts.texi@1.210 +2 -2 + NTP_4_2_7P207 + + util/ntp-keygen.1ntp-keygenman@1.23 +2 -2 + NTP_4_2_7P207 + + util/ntp-keygen.1ntp-keygenmdoc@1.23 +2 -2 + NTP_4_2_7P207 + + util/ntp-keygen.man.in@1.23 +2 -2 + NTP_4_2_7P207 + + util/ntp-keygen.mdoc.in@1.23 +2 -2 + NTP_4_2_7P207 + +ChangeSet@1.2653, 2011-08-22 02:58:47+00:00, stenn@psp-fb2.ntp.org + Cleanups for ntp-wait-opts.def + + scripts/ntp-wait-opts.def@1.4 +1 -1 + Cleanups for ntp-wait-opts.def + +ChangeSet@1.2652, 2011-08-21 23:45:28+00:00, stenn@psp-fb2.ntp.org + cleanup ntp.keys.def + + ntpd/ntp.keys.def@1.5 +5 -1 + cleanup ntp.keys.def + +ChangeSet@1.2651, 2011-08-21 09:13:07+00:00, stenn@psp-fb2.ntp.org + ntp.keys.def cleanup + + ntpd/ntp.keys.def@1.4 +2 -2 + ntp.keys.def cleanup + +ChangeSet@1.2650, 2011-08-21 01:24:12-04:00, stenn@deacon.udel.edu + Restore the original CLOCK_MONOTONIC output format in sntp + + ChangeLog@1.1017 +1 -0 + Restore the original CLOCK_MONOTONIC output format in sntp + + sntp/main.c@1.78 +2 -1 + Restore the original CLOCK_MONOTONIC output format in sntp + +ChangeSet@1.2649, 2011-08-21 05:04:33+00:00, stenn@psp-fb2.ntp.org + Cleanups for ntp-wait-opts.def and ntp.keys.def + + ChangeLog@1.1016 +1 -0 + Cleanups for ntp-wait-opts.def and ntp.keys.def + + ntpd/ntp.keys.def@1.3 +11 -8 + Cleanups for ntp-wait-opts.def and ntp.keys.def + + scripts/ntp-wait-opts.def@1.3 +6 -5 + Cleanups for ntp-wait-opts.def and ntp.keys.def + +ChangeSet@1.2648, 2011-08-20 06:04:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P206 + TAG: NTP_4_2_7P206 + + ChangeLog@1.1015 +1 -0 + NTP_4_2_7P206 + + ntpd/ntpd-opts.c@1.211 +3 -3 + NTP_4_2_7P206 + + ntpd/ntpd-opts.h@1.211 +3 -3 + NTP_4_2_7P206 + + ntpd/ntpd-opts.texi@1.209 +2 -2 + NTP_4_2_7P206 + + ntpd/ntpd.1ntpdman@1.22 +2 -2 + NTP_4_2_7P206 + + ntpd/ntpd.1ntpdmdoc@1.22 +2 -2 + NTP_4_2_7P206 + + ntpd/ntpd.man.in@1.22 +2 -2 + NTP_4_2_7P206 + + ntpd/ntpd.mdoc.in@1.22 +2 -2 + NTP_4_2_7P206 + + ntpdc/ntpdc-opts.c@1.206 +3 -3 + NTP_4_2_7P206 + + ntpdc/ntpdc-opts.h@1.206 +3 -3 + NTP_4_2_7P206 + + ntpdc/ntpdc-opts.texi@1.206 +2 -2 + NTP_4_2_7P206 + + ntpdc/ntpdc.1ntpdcman@1.22 +2 -2 + NTP_4_2_7P206 + + ntpdc/ntpdc.1ntpdcmdoc@1.22 +2 -2 + NTP_4_2_7P206 + + ntpdc/ntpdc.html@1.34 +2 -2 + NTP_4_2_7P206 + + ntpdc/ntpdc.man.in@1.22 +2 -2 + NTP_4_2_7P206 + + ntpdc/ntpdc.mdoc.in@1.22 +2 -2 + NTP_4_2_7P206 + + ntpq/ntpq-opts.c@1.208 +3 -3 + NTP_4_2_7P206 + + ntpq/ntpq-opts.h@1.208 +3 -3 + NTP_4_2_7P206 + + ntpq/ntpq-opts.texi@1.208 +2 -2 + NTP_4_2_7P206 + + ntpq/ntpq.1ntpqman@1.22 +2 -2 + NTP_4_2_7P206 + + ntpq/ntpq.1ntpqmdoc@1.22 +2 -2 + NTP_4_2_7P206 + + ntpq/ntpq.man.in@1.22 +2 -2 + NTP_4_2_7P206 + + ntpq/ntpq.mdoc.in@1.22 +2 -2 + NTP_4_2_7P206 + + ntpsnmpd/ntpsnmpd-opts.c@1.208 +3 -3 + NTP_4_2_7P206 + + ntpsnmpd/ntpsnmpd-opts.h@1.208 +3 -3 + NTP_4_2_7P206 + + ntpsnmpd/ntpsnmpd-opts.texi@1.208 +2 -2 + NTP_4_2_7P206 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.22 +2 -2 + NTP_4_2_7P206 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.22 +2 -2 + NTP_4_2_7P206 + + ntpsnmpd/ntpsnmpd.man.in@1.22 +2 -2 + NTP_4_2_7P206 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.22 +2 -2 + NTP_4_2_7P206 + + packageinfo.sh@1.209 +1 -1 + NTP_4_2_7P206 + + scripts/ntp-wait-opts.texi@1.26 +1 -1 + NTP_4_2_7P206 + + scripts/ntp-wait.1ntp-waitman@1.22 +9 -5 + NTP_4_2_7P206 + + scripts/ntp-wait.1ntp-waitmdoc@1.22 +9 -5 + NTP_4_2_7P206 + + scripts/ntp-wait.html@1.26 +1 -1 + NTP_4_2_7P206 + + scripts/ntp-wait.man.in@1.22 +9 -5 + NTP_4_2_7P206 + + scripts/ntp-wait.mdoc.in@1.22 +9 -5 + NTP_4_2_7P206 + + sntp/sntp-opts.c@1.204 +7 -7 + NTP_4_2_7P206 + + sntp/sntp-opts.h@1.204 +3 -3 + NTP_4_2_7P206 + + sntp/sntp-opts.texi@1.204 +52 -37 + NTP_4_2_7P206 + + sntp/sntp.1sntpman@1.24 +50 -35 + NTP_4_2_7P206 + + sntp/sntp.1sntpmdoc@1.24 +50 -35 + NTP_4_2_7P206 + + sntp/sntp.html@1.204 +49 -37 + NTP_4_2_7P206 + + sntp/sntp.man.in@1.24 +50 -35 + NTP_4_2_7P206 + + sntp/sntp.mdoc.in@1.24 +50 -35 + NTP_4_2_7P206 + + util/ntp-keygen-opts.c@1.206 +3 -3 + NTP_4_2_7P206 + + util/ntp-keygen-opts.h@1.206 +3 -3 + NTP_4_2_7P206 + + util/ntp-keygen-opts.texi@1.209 +2 -2 + NTP_4_2_7P206 + + util/ntp-keygen.1ntp-keygenman@1.22 +2 -2 + NTP_4_2_7P206 + + util/ntp-keygen.1ntp-keygenmdoc@1.22 +2 -2 + NTP_4_2_7P206 + + util/ntp-keygen.man.in@1.22 +2 -2 + NTP_4_2_7P206 + + util/ntp-keygen.mdoc.in@1.22 +2 -2 + NTP_4_2_7P206 + +ChangeSet@1.2645.1.2, 2011-08-20 02:51:43+00:00, stenn@psp-fb2.ntp.org + sntp documentation and behavior improvements suggested by Steven Sommars + + ChangeLog@1.1012.1.3 +2 -0 + sntp documentation and behavior improvements suggested by Steven Sommars + + sntp/sntp-opts.def@1.38 +72 -42 + sntp documentation and behavior improvements suggested by Steven Sommars + +ChangeSet@1.2645.1.1, 2011-08-20 02:42:48+00:00, stenn@psp-fb2.ntp.org + Have sntp report synchronization distance instead of root dispersion + + ChangeLog@1.1012.1.2 +1 -0 + Have sntp report synchronization distance instead of root dispersion + + ChangeLog@1.1012.1.1 +1 -0 + Clean up ntp-wait-opts.def + + scripts/ntp-wait-opts.def@1.2 +16 -18 + Clean up ntp-wait-opts.def + + sntp/main.c@1.77 +9 -10 + Have sntp report synchronization distance instead of root dispersion + +ChangeSet@1.2646, 2011-08-19 16:06:28+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1993] ntpd Windows port adj_systime() broken in 4.2.7p203. + + ChangeLog@1.1013 +1 -0 + [Bug 1993] ntpd Windows port adj_systime() broken in 4.2.7p203. + + include/ntp_fp.h@1.25 +1 -1 + Work around DebugBreak() in debug build of Windows port when a cast from + 64 to 32 bits changes the value by masking off upper 32 bits explicitly + in DTOLFP(). + + include/ntp_types.h@1.26 +5 -0 + Provide UINT32_MAX corresponding to u_int32 type. + + ports/winnt/ntpd/nt_clockstuff.c@1.52 +29 -23 + [Bug 1993] ntpd Windows port adj_systime() broken in 4.2.7p203. + +ChangeSet@1.2645, 2011-08-19 07:46:19+00:00, stenn@deacon.udel.edu + NTP_4_2_7P205 + TAG: NTP_4_2_7P205 + + ChangeLog@1.1012 +1 -0 + NTP_4_2_7P205 + + ntpd/ntpd-opts.c@1.210 +3 -3 + NTP_4_2_7P205 + + ntpd/ntpd-opts.h@1.210 +3 -3 + NTP_4_2_7P205 + + ntpd/ntpd-opts.texi@1.208 +2 -2 + NTP_4_2_7P205 + + ntpd/ntpd.1ntpdman@1.21 +2 -2 + NTP_4_2_7P205 + + ntpd/ntpd.1ntpdmdoc@1.21 +2 -2 + NTP_4_2_7P205 + + ntpd/ntpd.man.in@1.21 +2 -2 + NTP_4_2_7P205 + + ntpd/ntpd.mdoc.in@1.21 +2 -2 + NTP_4_2_7P205 + + ntpdc/ntpdc-opts.c@1.205 +3 -3 + NTP_4_2_7P205 + + ntpdc/ntpdc-opts.h@1.205 +3 -3 + NTP_4_2_7P205 + + ntpdc/ntpdc-opts.texi@1.205 +2 -2 + NTP_4_2_7P205 + + ntpdc/ntpdc.1ntpdcman@1.21 +2 -2 + NTP_4_2_7P205 + + ntpdc/ntpdc.1ntpdcmdoc@1.21 +2 -2 + NTP_4_2_7P205 + + ntpdc/ntpdc.html@1.33 +2 -2 + NTP_4_2_7P205 + + ntpdc/ntpdc.man.in@1.21 +2 -2 + NTP_4_2_7P205 + + ntpdc/ntpdc.mdoc.in@1.21 +2 -2 + NTP_4_2_7P205 + + ntpq/ntpq-opts.c@1.207 +3 -3 + NTP_4_2_7P205 + + ntpq/ntpq-opts.h@1.207 +3 -3 + NTP_4_2_7P205 + + ntpq/ntpq-opts.texi@1.207 +2 -2 + NTP_4_2_7P205 + + ntpq/ntpq.1ntpqman@1.21 +2 -2 + NTP_4_2_7P205 + + ntpq/ntpq.1ntpqmdoc@1.21 +2 -2 + NTP_4_2_7P205 + + ntpq/ntpq.man.in@1.21 +2 -2 + NTP_4_2_7P205 + + ntpq/ntpq.mdoc.in@1.21 +2 -2 + NTP_4_2_7P205 + + ntpsnmpd/ntpsnmpd-opts.c@1.207 +3 -3 + NTP_4_2_7P205 + + ntpsnmpd/ntpsnmpd-opts.h@1.207 +3 -3 + NTP_4_2_7P205 + + ntpsnmpd/ntpsnmpd-opts.texi@1.207 +2 -2 + NTP_4_2_7P205 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.21 +2 -2 + NTP_4_2_7P205 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.21 +2 -2 + NTP_4_2_7P205 + + ntpsnmpd/ntpsnmpd.man.in@1.21 +2 -2 + NTP_4_2_7P205 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.21 +2 -2 + NTP_4_2_7P205 + + packageinfo.sh@1.208 +1 -1 + NTP_4_2_7P205 + + scripts/ntp-wait-opts.texi@1.25 +1 -1 + NTP_4_2_7P205 + + scripts/ntp-wait.1ntp-waitman@1.21 +2 -2 + NTP_4_2_7P205 + + scripts/ntp-wait.1ntp-waitmdoc@1.21 +2 -2 + NTP_4_2_7P205 + + scripts/ntp-wait.html@1.25 +1 -1 + NTP_4_2_7P205 + + scripts/ntp-wait.man.in@1.21 +2 -2 + NTP_4_2_7P205 + + scripts/ntp-wait.mdoc.in@1.21 +2 -2 + NTP_4_2_7P205 + + sntp/sntp-opts.c@1.203 +3 -3 + NTP_4_2_7P205 + + sntp/sntp-opts.h@1.203 +3 -3 + NTP_4_2_7P205 + + sntp/sntp-opts.texi@1.203 +2 -2 + NTP_4_2_7P205 + + sntp/sntp.1sntpman@1.23 +2 -2 + NTP_4_2_7P205 + + sntp/sntp.1sntpmdoc@1.23 +2 -2 + NTP_4_2_7P205 + + sntp/sntp.html@1.203 +2 -2 + NTP_4_2_7P205 + + sntp/sntp.man.in@1.23 +2 -2 + NTP_4_2_7P205 + + sntp/sntp.mdoc.in@1.23 +2 -2 + NTP_4_2_7P205 + + util/ntp-keygen-opts.c@1.205 +3 -3 + NTP_4_2_7P205 + + util/ntp-keygen-opts.h@1.205 +3 -3 + NTP_4_2_7P205 + + util/ntp-keygen-opts.texi@1.208 +2 -2 + NTP_4_2_7P205 + + util/ntp-keygen.1ntp-keygenman@1.21 +2 -2 + NTP_4_2_7P205 + + util/ntp-keygen.1ntp-keygenmdoc@1.21 +2 -2 + NTP_4_2_7P205 + + util/ntp-keygen.man.in@1.21 +2 -2 + NTP_4_2_7P205 + + util/ntp-keygen.mdoc.in@1.21 +2 -2 + NTP_4_2_7P205 + +ChangeSet@1.2644, 2011-08-18 02:26:57+00:00, davehart@shiny.ad.hartbrothers.com + Fix typo in libevent/test/rpcgen_wrapper.sh spotted by Nick Mathewson. + + sntp/libevent/test/rpcgen_wrapper.sh@1.2 +1 -1 + Fix typo in libevent/test/rpcgen_wrapper.sh spotted by Nick Mathewson. + +ChangeSet@1.2643, 2011-08-18 02:25:11+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1992] util/tg2 doesn't compile, needs libntp. + Patch supplied by kukabu@gmail.com: + http://bugs.ntp.org/attachment.cgi?id=786 + + ChangeLog@1.1011 +1 -0 + [Bug 1992] util/tg2 doesn't compile, needs libntp. + + util/Makefile.am@1.66 +1 -1 + [Bug 1992] util/tg2 doesn't compile, needs libntp. + + util/tg2.c@1.6 +2 -3 + [Bug 1992] util/tg2 doesn't compile, needs libntp. + +ChangeSet@1.2642, 2011-08-16 11:18:13+00:00, stenn@deacon.udel.edu + NTP_4_2_7P204 + TAG: NTP_4_2_7P204 + + ChangeLog@1.1010 +1 -0 + NTP_4_2_7P204 + + ntpd/ntpd-opts.c@1.209 +3 -3 + NTP_4_2_7P204 + + ntpd/ntpd-opts.h@1.209 +3 -3 + NTP_4_2_7P204 + + ntpd/ntpd-opts.texi@1.207 +2 -2 + NTP_4_2_7P204 + + ntpd/ntpd.1ntpdman@1.20 +2 -2 + NTP_4_2_7P204 + + ntpd/ntpd.1ntpdmdoc@1.20 +2 -2 + NTP_4_2_7P204 + + ntpd/ntpd.man.in@1.20 +2 -2 + NTP_4_2_7P204 + + ntpd/ntpd.mdoc.in@1.20 +2 -2 + NTP_4_2_7P204 + + ntpdc/ntpdc-opts.c@1.204 +3 -3 + NTP_4_2_7P204 + + ntpdc/ntpdc-opts.h@1.204 +3 -3 + NTP_4_2_7P204 + + ntpdc/ntpdc-opts.texi@1.204 +2 -2 + NTP_4_2_7P204 + + ntpdc/ntpdc.1ntpdcman@1.20 +2 -2 + NTP_4_2_7P204 + + ntpdc/ntpdc.1ntpdcmdoc@1.20 +2 -2 + NTP_4_2_7P204 + + ntpdc/ntpdc.html@1.32 +2 -2 + NTP_4_2_7P204 + + ntpdc/ntpdc.man.in@1.20 +2 -2 + NTP_4_2_7P204 + + ntpdc/ntpdc.mdoc.in@1.20 +2 -2 + NTP_4_2_7P204 + + ntpq/ntpq-opts.c@1.206 +3 -3 + NTP_4_2_7P204 + + ntpq/ntpq-opts.h@1.206 +3 -3 + NTP_4_2_7P204 + + ntpq/ntpq-opts.texi@1.206 +2 -2 + NTP_4_2_7P204 + + ntpq/ntpq.1ntpqman@1.20 +2 -2 + NTP_4_2_7P204 + + ntpq/ntpq.1ntpqmdoc@1.20 +2 -2 + NTP_4_2_7P204 + + ntpq/ntpq.man.in@1.20 +2 -2 + NTP_4_2_7P204 + + ntpq/ntpq.mdoc.in@1.20 +2 -2 + NTP_4_2_7P204 + + ntpsnmpd/ntpsnmpd-opts.c@1.206 +3 -3 + NTP_4_2_7P204 + + ntpsnmpd/ntpsnmpd-opts.h@1.206 +3 -3 + NTP_4_2_7P204 + + ntpsnmpd/ntpsnmpd-opts.texi@1.206 +2 -2 + NTP_4_2_7P204 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.20 +2 -2 + NTP_4_2_7P204 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.20 +2 -2 + NTP_4_2_7P204 + + ntpsnmpd/ntpsnmpd.man.in@1.20 +2 -2 + NTP_4_2_7P204 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.20 +2 -2 + NTP_4_2_7P204 + + packageinfo.sh@1.207 +1 -1 + NTP_4_2_7P204 + + scripts/ntp-wait-opts.texi@1.24 +1 -1 + NTP_4_2_7P204 + + scripts/ntp-wait.1ntp-waitman@1.20 +2 -2 + NTP_4_2_7P204 + + scripts/ntp-wait.1ntp-waitmdoc@1.20 +2 -2 + NTP_4_2_7P204 + + scripts/ntp-wait.html@1.24 +1 -1 + NTP_4_2_7P204 + + scripts/ntp-wait.man.in@1.20 +2 -2 + NTP_4_2_7P204 + + scripts/ntp-wait.mdoc.in@1.20 +2 -2 + NTP_4_2_7P204 + + sntp/sntp-opts.c@1.202 +3 -3 + NTP_4_2_7P204 + + sntp/sntp-opts.h@1.202 +3 -3 + NTP_4_2_7P204 + + sntp/sntp-opts.texi@1.202 +13 -15 + NTP_4_2_7P204 + + sntp/sntp.1sntpman@1.22 +13 -15 + NTP_4_2_7P204 + + sntp/sntp.1sntpmdoc@1.22 +13 -15 + NTP_4_2_7P204 + + sntp/sntp.html@1.202 +14 -16 + NTP_4_2_7P204 + + sntp/sntp.man.in@1.22 +13 -15 + NTP_4_2_7P204 + + sntp/sntp.mdoc.in@1.22 +13 -15 + NTP_4_2_7P204 + + util/ntp-keygen-opts.c@1.204 +3 -3 + NTP_4_2_7P204 + + util/ntp-keygen-opts.h@1.204 +3 -3 + NTP_4_2_7P204 + + util/ntp-keygen-opts.texi@1.207 +2 -2 + NTP_4_2_7P204 + + util/ntp-keygen.1ntp-keygenman@1.20 +2 -2 + NTP_4_2_7P204 + + util/ntp-keygen.1ntp-keygenmdoc@1.20 +2 -2 + NTP_4_2_7P204 + + util/ntp-keygen.man.in@1.20 +2 -2 + NTP_4_2_7P204 + + util/ntp-keygen.mdoc.in@1.20 +2 -2 + NTP_4_2_7P204 + +ChangeSet@1.2637.1.3, 2011-08-15 18:24:53-04:00, stenn@psp-deb1.ntp.org + [Bug 1989] sntp manual page sometimes refers to SNTP as a program + + ChangeLog@1.1005.1.3 +1 -0 + [Bug 1989] sntp manual page sometimes refers to SNTP as a program + + sntp/sntp-opts.def@1.37 +12 -14 + [Bug 1989] sntp manual page sometimes refers to SNTP as a program + +ChangeSet@1.2637.1.2, 2011-08-14 23:08:50+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + ChangeLog@1.1005.1.2 +2 -0 + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + include/ntp_syslog.h@1.7 +2 -0 + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + libntp/msyslog.c@1.47 +21 -6 + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + libntp/socktoa.c@1.17 +9 -2 + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + sntp/log.c@1.22 +2 -1 + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + sntp/main.c@1.76 +42 -25 + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + sntp/networking.c@1.61 +11 -14 + [Bug 1988] Better sntp send failed error message needed. + [Bug 1990] sntp output should include stratum. + + sntp/networking.h@1.27 +2 -3 + return FALSE from sendpkt() on error. + + sntp/utilities.c@1.19 +33 -0 + add hostnameaddr() to display given hostname and resolved numeric + IP address, avoid duplication if the input was a numeric address. + + sntp/utilities.h@1.11 +14 -12 + add hostnameaddr() to display given hostname and resolved numeric + IP address, avoid duplication if the input was a numeric address. + +ChangeSet@1.2637.1.1, 2011-08-13 10:46:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P203 + TAG: NTP_4_2_7P203 + + ChangeLog@1.1005.1.1 +1 -0 + NTP_4_2_7P203 + + ntpd/ntpd-opts.c@1.208 +3 -3 + NTP_4_2_7P203 + + ntpd/ntpd-opts.h@1.208 +3 -3 + NTP_4_2_7P203 + + ntpd/ntpd-opts.texi@1.206 +2 -2 + NTP_4_2_7P203 + + ntpd/ntpd.1ntpdman@1.19 +2 -2 + NTP_4_2_7P203 + + ntpd/ntpd.1ntpdmdoc@1.19 +2 -2 + NTP_4_2_7P203 + + ntpd/ntpd.man.in@1.19 +2 -2 + NTP_4_2_7P203 + + ntpd/ntpd.mdoc.in@1.19 +2 -2 + NTP_4_2_7P203 + + ntpdc/ntpdc-opts.c@1.203 +3 -3 + NTP_4_2_7P203 + + ntpdc/ntpdc-opts.h@1.203 +3 -3 + NTP_4_2_7P203 + + ntpdc/ntpdc-opts.texi@1.203 +2 -2 + NTP_4_2_7P203 + + ntpdc/ntpdc.1ntpdcman@1.19 +2 -2 + NTP_4_2_7P203 + + ntpdc/ntpdc.1ntpdcmdoc@1.19 +2 -2 + NTP_4_2_7P203 + + ntpdc/ntpdc.html@1.31 +2 -2 + NTP_4_2_7P203 + + ntpdc/ntpdc.man.in@1.19 +2 -2 + NTP_4_2_7P203 + + ntpdc/ntpdc.mdoc.in@1.19 +2 -2 + NTP_4_2_7P203 + + ntpq/ntpq-opts.c@1.205 +3 -3 + NTP_4_2_7P203 + + ntpq/ntpq-opts.h@1.205 +3 -3 + NTP_4_2_7P203 + + ntpq/ntpq-opts.texi@1.205 +2 -2 + NTP_4_2_7P203 + + ntpq/ntpq.1ntpqman@1.19 +2 -2 + NTP_4_2_7P203 + + ntpq/ntpq.1ntpqmdoc@1.19 +2 -2 + NTP_4_2_7P203 + + ntpq/ntpq.man.in@1.19 +2 -2 + NTP_4_2_7P203 + + ntpq/ntpq.mdoc.in@1.19 +2 -2 + NTP_4_2_7P203 + + ntpsnmpd/ntpsnmpd-opts.c@1.205 +3 -3 + NTP_4_2_7P203 + + ntpsnmpd/ntpsnmpd-opts.h@1.205 +3 -3 + NTP_4_2_7P203 + + ntpsnmpd/ntpsnmpd-opts.texi@1.205 +2 -2 + NTP_4_2_7P203 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.19 +2 -2 + NTP_4_2_7P203 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.19 +2 -2 + NTP_4_2_7P203 + + ntpsnmpd/ntpsnmpd.man.in@1.19 +2 -2 + NTP_4_2_7P203 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.19 +2 -2 + NTP_4_2_7P203 + + packageinfo.sh@1.206 +1 -1 + NTP_4_2_7P203 + + scripts/ntp-wait-opts.texi@1.23 +1 -1 + NTP_4_2_7P203 + + scripts/ntp-wait.1ntp-waitman@1.19 +2 -2 + NTP_4_2_7P203 + + scripts/ntp-wait.1ntp-waitmdoc@1.19 +2 -2 + NTP_4_2_7P203 + + scripts/ntp-wait.html@1.23 +1 -1 + NTP_4_2_7P203 + + scripts/ntp-wait.man.in@1.19 +2 -2 + NTP_4_2_7P203 + + scripts/ntp-wait.mdoc.in@1.19 +2 -2 + NTP_4_2_7P203 + + sntp/sntp-opts.c@1.201 +3 -3 + NTP_4_2_7P203 + + sntp/sntp-opts.h@1.201 +3 -3 + NTP_4_2_7P203 + + sntp/sntp-opts.texi@1.201 +2 -2 + NTP_4_2_7P203 + + sntp/sntp.1sntpman@1.21 +2 -2 + NTP_4_2_7P203 + + sntp/sntp.1sntpmdoc@1.21 +2 -2 + NTP_4_2_7P203 + + sntp/sntp.html@1.201 +2 -2 + NTP_4_2_7P203 + + sntp/sntp.man.in@1.21 +2 -2 + NTP_4_2_7P203 + + sntp/sntp.mdoc.in@1.21 +2 -2 + NTP_4_2_7P203 + + util/ntp-keygen-opts.c@1.203 +3 -3 + NTP_4_2_7P203 + + util/ntp-keygen-opts.h@1.203 +3 -3 + NTP_4_2_7P203 + + util/ntp-keygen-opts.texi@1.206 +2 -2 + NTP_4_2_7P203 + + util/ntp-keygen.1ntp-keygenman@1.19 +2 -2 + NTP_4_2_7P203 + + util/ntp-keygen.1ntp-keygenmdoc@1.19 +2 -2 + NTP_4_2_7P203 + + util/ntp-keygen.man.in@1.19 +2 -2 + NTP_4_2_7P203 + + util/ntp-keygen.mdoc.in@1.19 +2 -2 + NTP_4_2_7P203 + +ChangeSet@1.2638, 2011-08-13 08:59:34+02:00, jnperlin@hydra.localnet + PGRMF support in NMEA driver + + ChangeLog@1.1006 +1 -0 + PGRMF support in NMEA driver + + ntpd/refclock_nmea.c@1.61 +647 -475 + PGRMF support in NMEA driver + +ChangeSet@1.2637, 2011-08-12 15:04:45-04:00, stenn@deacon.udel.edu + Note that 1986 was fixed by this changeset + + ChangeLog@1.1005 +1 -1 + Note that 1986 was fixed by this changeset + +ChangeSet@1.2636, 2011-08-12 17:17:54+00:00, davehart@shiny.ad.hartbrothers.com + Actually use long long for (u_)int64 by correcting spelling + of SIZEOF_LONG_LONG in ntp_types.h. + Require Visual C++ 2005 or later compilers in Windows port. + Force .exe minimum Windows version to 0x0400 to allow NT4 in + vs2005/*.vcproj files. + + ChangeLog@1.1004 +5 -0 + Actually use long long for (u_)int64 by correcting spelling of + SIZEOF_LONG_LONG in ntp_types.h. + Require Visual C++ 2005 or later compilers in Windows port. + Force .exe minimum Windows version to 0x0400 to allow NT4 in + vs2005/*.vcproj files. + + + include/ntp_machine.h@1.36 +0 -5 + Remove long-untested SYS_CYGWIN32-specific block. + + include/ntp_types.h@1.25 +1 -6 + Correct spelling of SIZEOF_LONG_LONG, which will restore NTP's int64 on a + number of platforms. + With VC++ 2005 the minimum requirement, remove _MSC_VER __int64 block, + using the same "long long" types for (u_)int64. + + include/timetoa.h@1.4 +3 -2 + comment cleanup + + lib/isc/win32/include/isc/platform.h@1.8 +2 -0 + Allow presetting ISC_PLATFORM_QUADFORMAT, as ports\winnt\include\config.h + now does. + + libntp/timespecops.c@1.7 +4 -3 + Use u_int64 where available, instead of only where long is 64-bit. + + ntpd/complete.conf@1.19 +1 -0 + test "server" with IPv6 link-local with interface specifier + + ports/winnt/include/config.h@1.101 +54 -63 + Require Visual C++ 2005 or later, enabling portable "long long" and + "%lld" for 64-bit scalars. + Switch libisc from %I64 to %ll. + + ports/winnt/ntpd/nt_clockstuff.c@1.51 +77 -121 + Require Visual C++ 2005 or later, enabling portable "long long" and + "%lld" for 64-bit scalars. + Switch from %I64 to %ll. + Remove workarounds for VC6 deficit converting u_int64 to double, + removing many (LONGLONG) casts of ULONGLONGs in particular. + Code style cleanup. + + ports/winnt/vs2005/Instsrv.vcproj@1.3 +2 -0 + Force .exe minimum Windows version to 0x0400 to allow NT4 + + ports/winnt/vs2005/ntpd.vcproj@1.15 +2 -0 + Force .exe minimum Windows version to 0x0400 to allow NT4 + + ports/winnt/vs2005/ntpdate.vcproj@1.5 +2 -0 + Force .exe minimum Windows version to 0x0400 to allow NT4 + + ports/winnt/vs2005/ntpdc.vcproj@1.7 +2 -0 + Force .exe minimum Windows version to 0x0400 to allow NT4 + + ports/winnt/vs2005/ntpkeygen.vcproj@1.7 +2 -0 + Force .exe minimum Windows version to 0x0400 to allow NT4 + + ports/winnt/vs2005/ntpq.vcproj@1.7 +2 -0 + Force .exe minimum Windows version to 0x0400 to allow NT4 + +ChangeSet@1.2635, 2011-08-12 06:25:53+00:00, davehart@shiny.ad.hartbrothers.com + Correct init_logging()'s def_syslogmask type to u_int32 following + change of ntp_syslogmask from u_long to u_int32 in p202. + + ChangeLog@1.1003 +2 -0 + Correct init_logging()'s def_syslogmask type to u_int32 following + change of ntp_syslogmask from u_long to u_int32 in p202. + + include/ntp_stdlib.h@1.64 +1 -1 + change init_logging()'s def_syslogmask type to u_int32 to match + recent change of ntp_syslogmask from u_long to u_int32. + + libntp/msyslog.c@1.46 +7 -3 + More (u_long) to (u_int32) around ntp_syslogmask type change. + + sntp/m4/ntp_libevent.m4@1.9 +6 -1 + Detect --gc-sections support by default for our tearoff libevent, + now that libevent has opted to default to --disable-function-sections. + +ChangeSet@1.2634, 2011-08-12 06:21:59+00:00, davehart@shiny.ad.hartbrothers.com + Attempt to fix libevent "make distcheck" failure related to read-only + srcdir and event_rpcgen.py by avoiding creating stub regress.gen.h and + regress.gen.c in the build directory when $srcdir has both already. + + ChangeLog@1.1002 +2 -0 + Fix make distcheck with --enable-libevent-regress problem with + unwritable $srcdir. + + sntp/libevent/test/Makefile.am@1.8 +9 -4 + Attempt to fix libevent "make distcheck" failure related to read-only + srcdir and event_rpcgen.py by avoiding creating stub regress.gen.h and + regress.gen.c in the build directory when $srcdir has both already. + + sntp/libevent/test/rpcgen_wrapper.sh@1.1 +42 -0 + BitKeeper file C:/ntp/ntp-dev-1986/sntp/libevent/test/rpcgen_wrapper.sh + + sntp/libevent/test/rpcgen_wrapper.sh@1.0 +0 -0 + +ChangeSet@1.2633, 2011-08-09 08:20:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P202 + TAG: NTP_4_2_7P202 + + ChangeLog@1.1001 +1 -0 + NTP_4_2_7P202 + + ntpd/ntpd-opts.c@1.207 +3 -3 + NTP_4_2_7P202 + + ntpd/ntpd-opts.h@1.207 +3 -3 + NTP_4_2_7P202 + + ntpd/ntpd-opts.texi@1.205 +2 -2 + NTP_4_2_7P202 + + ntpd/ntpd.1ntpdman@1.18 +2 -2 + NTP_4_2_7P202 + + ntpd/ntpd.1ntpdmdoc@1.18 +2 -2 + NTP_4_2_7P202 + + ntpd/ntpd.man.in@1.18 +2 -2 + NTP_4_2_7P202 + + ntpd/ntpd.mdoc.in@1.18 +2 -2 + NTP_4_2_7P202 + + ntpdc/ntpdc-opts.c@1.202 +3 -3 + NTP_4_2_7P202 + + ntpdc/ntpdc-opts.h@1.202 +3 -3 + NTP_4_2_7P202 + + ntpdc/ntpdc-opts.texi@1.202 +2 -2 + NTP_4_2_7P202 + + ntpdc/ntpdc.1ntpdcman@1.18 +2 -2 + NTP_4_2_7P202 + + ntpdc/ntpdc.1ntpdcmdoc@1.18 +2 -2 + NTP_4_2_7P202 + + ntpdc/ntpdc.html@1.30 +2 -2 + NTP_4_2_7P202 + + ntpdc/ntpdc.man.in@1.18 +2 -2 + NTP_4_2_7P202 + + ntpdc/ntpdc.mdoc.in@1.18 +2 -2 + NTP_4_2_7P202 + + ntpq/ntpq-opts.c@1.204 +3 -3 + NTP_4_2_7P202 + + ntpq/ntpq-opts.h@1.204 +3 -3 + NTP_4_2_7P202 + + ntpq/ntpq-opts.texi@1.204 +2 -2 + NTP_4_2_7P202 + + ntpq/ntpq.1ntpqman@1.18 +2 -2 + NTP_4_2_7P202 + + ntpq/ntpq.1ntpqmdoc@1.18 +2 -2 + NTP_4_2_7P202 + + ntpq/ntpq.man.in@1.18 +2 -2 + NTP_4_2_7P202 + + ntpq/ntpq.mdoc.in@1.18 +2 -2 + NTP_4_2_7P202 + + ntpsnmpd/ntpsnmpd-opts.c@1.204 +3 -3 + NTP_4_2_7P202 + + ntpsnmpd/ntpsnmpd-opts.h@1.204 +3 -3 + NTP_4_2_7P202 + + ntpsnmpd/ntpsnmpd-opts.texi@1.204 +2 -2 + NTP_4_2_7P202 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.18 +2 -2 + NTP_4_2_7P202 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.18 +2 -2 + NTP_4_2_7P202 + + ntpsnmpd/ntpsnmpd.man.in@1.18 +2 -2 + NTP_4_2_7P202 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.18 +2 -2 + NTP_4_2_7P202 + + packageinfo.sh@1.205 +1 -1 + NTP_4_2_7P202 + + scripts/ntp-wait-opts.texi@1.22 +1 -1 + NTP_4_2_7P202 + + scripts/ntp-wait.1ntp-waitman@1.18 +2 -2 + NTP_4_2_7P202 + + scripts/ntp-wait.1ntp-waitmdoc@1.18 +2 -2 + NTP_4_2_7P202 + + scripts/ntp-wait.html@1.22 +1 -1 + NTP_4_2_7P202 + + scripts/ntp-wait.man.in@1.18 +2 -2 + NTP_4_2_7P202 + + scripts/ntp-wait.mdoc.in@1.18 +2 -2 + NTP_4_2_7P202 + + sntp/sntp-opts.c@1.200 +3 -3 + NTP_4_2_7P202 + + sntp/sntp-opts.h@1.200 +3 -3 + NTP_4_2_7P202 + + sntp/sntp-opts.texi@1.200 +2 -2 + NTP_4_2_7P202 + + sntp/sntp.1sntpman@1.20 +2 -2 + NTP_4_2_7P202 + + sntp/sntp.1sntpmdoc@1.20 +2 -2 + NTP_4_2_7P202 + + sntp/sntp.html@1.200 +2 -2 + NTP_4_2_7P202 + + sntp/sntp.man.in@1.20 +2 -2 + NTP_4_2_7P202 + + sntp/sntp.mdoc.in@1.20 +2 -2 + NTP_4_2_7P202 + + util/ntp-keygen-opts.c@1.202 +3 -3 + NTP_4_2_7P202 + + util/ntp-keygen-opts.h@1.202 +3 -3 + NTP_4_2_7P202 + + util/ntp-keygen-opts.texi@1.205 +2 -2 + NTP_4_2_7P202 + + util/ntp-keygen.1ntp-keygenman@1.18 +2 -2 + NTP_4_2_7P202 + + util/ntp-keygen.1ntp-keygenmdoc@1.18 +2 -2 + NTP_4_2_7P202 + + util/ntp-keygen.man.in@1.18 +2 -2 + NTP_4_2_7P202 + + util/ntp-keygen.mdoc.in@1.18 +2 -2 + NTP_4_2_7P202 + +ChangeSet@1.2632, 2011-08-09 03:58:30-04:00, stenn@psp-deb1.ntp.org + [Bug 1983] --without-sntp build breaks in sntp subdir + + sntp/Makefile.am@1.68 +0 -2 + [Bug 1983] --without-sntp build breaks in sntp subdir + + sntp/configure.ac@1.68 +8 -0 + [Bug 1983] --without-sntp build breaks in sntp subdir + +ChangeSet@1.2631, 2011-08-09 05:46:47+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1983] --without-sntp build breaks in sntp subdir. + + ChangeLog@1.1000 +1 -0 + [Bug 1983] --without-sntp build breaks in sntp subdir. + + sntp/Makefile.am@1.67 +5 -3 + [Bug 1983] --without-sntp build breaks in sntp subdir. + + Wrap *_PROGRAMS assignments with "if BUILD_SNTP" / "endif". + +ChangeSet@1.2082.4.233, 2011-08-09 04:27:25+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1985] "logconfig =allall" rejected. + + ChangeLog@1.496.26.166 +1 -0 + [Bug 1985] "logconfig =allall" rejected. + + include/ntp_syslog.h@1.3.1.2 +7 -5 + convert spaces to tabs, change ntp_syslogmask type from u_long to u_int32. + + include/ntpd.h@1.137.2.6 +1 -2 + #include ntp.h before ntp_syslog.h + + libntp/machines.c@1.21.1.1 +1 -0 + #include ntp.h before ntp_syslog.h + + libntp/msyslog.c@1.24.1.5 +1 -1 + [Bug 1985] "logconfig =allall" rejected. + + ntpd/complete.conf@1.3.1.2 +1 -1 + [Bug 1985] "logconfig =allall" rejected. + + ntpd/ntp_config.c@1.241.1.9 +53 -40 + [Bug 1985] "logconfig =allall" rejected. + +ChangeSet@1.2628, 2011-08-08 20:03:45+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). + + ChangeLog@1.997 +1 -0 + [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). + + sntp/m4/ntp_ipv6.m4@1.5 +7 -0 + [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). + +ChangeSet@1.2082.4.232, 2011-08-08 18:13:07+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). + + ChangeLog@1.496.26.165 +1 -0 + [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). + + + configure.ac@1.465.1.30 +7 -0 + [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). + + + sntp/configure.ac@1.31.1.10 +7 -0 + [Bug 1984] ntp/libisc fails to compile on OS X 10.7 (Lion). + + +ChangeSet@1.2627, 2011-08-05 04:59:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P201 + TAG: NTP_4_2_7P201 + + ChangeLog@1.996 +1 -0 + NTP_4_2_7P201 + + ntpd/ntpd-opts.c@1.206 +3 -3 + NTP_4_2_7P201 + + ntpd/ntpd-opts.h@1.206 +3 -3 + NTP_4_2_7P201 + + ntpd/ntpd-opts.texi@1.204 +2 -2 + NTP_4_2_7P201 + + ntpd/ntpd.1ntpdman@1.17 +2 -2 + NTP_4_2_7P201 + + ntpd/ntpd.1ntpdmdoc@1.17 +2 -2 + NTP_4_2_7P201 + + ntpd/ntpd.man.in@1.17 +2 -2 + NTP_4_2_7P201 + + ntpd/ntpd.mdoc.in@1.17 +2 -2 + NTP_4_2_7P201 + + ntpdc/ntpdc-opts.c@1.201 +3 -3 + NTP_4_2_7P201 + + ntpdc/ntpdc-opts.h@1.201 +3 -3 + NTP_4_2_7P201 + + ntpdc/ntpdc-opts.texi@1.201 +2 -2 + NTP_4_2_7P201 + + ntpdc/ntpdc.1ntpdcman@1.17 +2 -2 + NTP_4_2_7P201 + + ntpdc/ntpdc.1ntpdcmdoc@1.17 +2 -2 + NTP_4_2_7P201 + + ntpdc/ntpdc.html@1.29 +2 -2 + NTP_4_2_7P201 + + ntpdc/ntpdc.man.in@1.17 +2 -2 + NTP_4_2_7P201 + + ntpdc/ntpdc.mdoc.in@1.17 +2 -2 + NTP_4_2_7P201 + + ntpq/ntpq-opts.c@1.203 +3 -3 + NTP_4_2_7P201 + + ntpq/ntpq-opts.h@1.203 +3 -3 + NTP_4_2_7P201 + + ntpq/ntpq-opts.texi@1.203 +2 -2 + NTP_4_2_7P201 + + ntpq/ntpq.1ntpqman@1.17 +2 -2 + NTP_4_2_7P201 + + ntpq/ntpq.1ntpqmdoc@1.17 +2 -2 + NTP_4_2_7P201 + + ntpq/ntpq.man.in@1.17 +2 -2 + NTP_4_2_7P201 + + ntpq/ntpq.mdoc.in@1.17 +2 -2 + NTP_4_2_7P201 + + ntpsnmpd/ntpsnmpd-opts.c@1.203 +3 -3 + NTP_4_2_7P201 + + ntpsnmpd/ntpsnmpd-opts.h@1.203 +3 -3 + NTP_4_2_7P201 + + ntpsnmpd/ntpsnmpd-opts.texi@1.203 +2 -2 + NTP_4_2_7P201 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.17 +2 -2 + NTP_4_2_7P201 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.17 +2 -2 + NTP_4_2_7P201 + + ntpsnmpd/ntpsnmpd.man.in@1.17 +2 -2 + NTP_4_2_7P201 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.17 +2 -2 + NTP_4_2_7P201 + + packageinfo.sh@1.204 +1 -1 + NTP_4_2_7P201 + + scripts/ntp-wait-opts.texi@1.21 +1 -1 + NTP_4_2_7P201 + + scripts/ntp-wait.1ntp-waitman@1.17 +2 -2 + NTP_4_2_7P201 + + scripts/ntp-wait.1ntp-waitmdoc@1.17 +2 -2 + NTP_4_2_7P201 + + scripts/ntp-wait.html@1.21 +1 -1 + NTP_4_2_7P201 + + scripts/ntp-wait.man.in@1.17 +2 -2 + NTP_4_2_7P201 + + scripts/ntp-wait.mdoc.in@1.17 +2 -2 + NTP_4_2_7P201 + + sntp/sntp-opts.c@1.199 +3 -3 + NTP_4_2_7P201 + + sntp/sntp-opts.h@1.199 +3 -3 + NTP_4_2_7P201 + + sntp/sntp-opts.texi@1.199 +2 -2 + NTP_4_2_7P201 + + sntp/sntp.1sntpman@1.19 +2 -2 + NTP_4_2_7P201 + + sntp/sntp.1sntpmdoc@1.19 +3 -3 + NTP_4_2_7P201 + + sntp/sntp.html@1.199 +51 -78 + NTP_4_2_7P201 + + sntp/sntp.man.in@1.19 +2 -2 + NTP_4_2_7P201 + + sntp/sntp.mdoc.in@1.19 +3 -3 + NTP_4_2_7P201 + + util/ntp-keygen-opts.c@1.201 +3 -3 + NTP_4_2_7P201 + + util/ntp-keygen-opts.h@1.201 +3 -3 + NTP_4_2_7P201 + + util/ntp-keygen-opts.texi@1.204 +2 -2 + NTP_4_2_7P201 + + util/ntp-keygen.1ntp-keygenman@1.17 +2 -2 + NTP_4_2_7P201 + + util/ntp-keygen.1ntp-keygenmdoc@1.17 +2 -2 + NTP_4_2_7P201 + + util/ntp-keygen.man.in@1.17 +2 -2 + NTP_4_2_7P201 + + util/ntp-keygen.mdoc.in@1.17 +2 -2 + NTP_4_2_7P201 + +ChangeSet@1.2626, 2011-08-04 19:41:51-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.995 +1 -0 + Documentation updates from Dave Mills + + html/authentic.html@1.6 +2 -2 + Documentation updates from Dave Mills + + html/authopt.html@1.72 +7 -7 + Documentation updates from Dave Mills + + html/clock.html@1.3 +5 -4 + Documentation updates from Dave Mills + + html/cluster.html@1.3 +5 -4 + Documentation updates from Dave Mills + + html/copyright.html@1.58 +8 -4 + Documentation updates from Dave Mills + + html/discipline.html@1.5 +6 -6 + Documentation updates from Dave Mills + + html/filter.html@1.3 +2 -2 + Documentation updates from Dave Mills + + html/miscopt.html@1.67 +3 -1 + Documentation updates from Dave Mills + + html/orphan.html@1.3 +17 -11 + Documentation updates from Dave Mills + + html/poll.html@1.2 +2 -2 + Documentation updates from Dave Mills + + html/prefer.html@1.26 +18 -28 + Documentation updates from Dave Mills + + html/scripts/authopt.txt@1.5 +2 -0 + Documentation updates from Dave Mills + + html/scripts/miscopt.txt@1.8 +1 -0 + Documentation updates from Dave Mills + + html/select.html@1.3 +4 -3 + Documentation updates from Dave Mills + + html/sntp.html@1.8 +50 -26 + Documentation updates from Dave Mills + +ChangeSet@1.2625, 2011-08-04 18:51:13-04:00, stenn@psp-deb1.ntp.org + sntp autogen regenerate after merge cleanup + + sntp/sntp-opts.c@1.198 +26 -28 + sntp autogen regenerate after merge cleanup + + sntp/sntp-opts.def@1.36 +1 -1 + sntp autogen regenerate after merge cleanup + + sntp/sntp-opts.h@1.198 +9 -9 + sntp autogen regenerate after merge cleanup + + sntp/sntp-opts.texi@1.198 +12 -14 + sntp autogen regenerate after merge cleanup + + sntp/sntp.1sntpman@1.18 +4 -4 + sntp autogen regenerate after merge cleanup + + sntp/sntp.1sntpmdoc@1.18 +4 -4 + sntp autogen regenerate after merge cleanup + + sntp/sntp.html@1.198 +98 -73 + sntp autogen regenerate after merge cleanup + + sntp/sntp.man.in@1.18 +4 -4 + sntp autogen regenerate after merge cleanup + + sntp/sntp.mdoc.in@1.18 +4 -4 + sntp autogen regenerate after merge cleanup + +ChangeSet@1.2620.1.1, 2011-08-04 16:13:31-04:00, stenn@psp-deb1.ntp.org + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + ChangeLog@1.990.1.1 +2 -0 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/main.c@1.74 +6 -6 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp-opts.c@1.195.1.1 +20 -20 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp-opts.def@1.34 +3 -3 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp-opts.h@1.195.1.1 +8 -8 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp-opts.texi@1.195.1.1 +6 -6 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp.1sntpman@1.15.1.1 +4 -4 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp.1sntpmdoc@1.15.1.1 +5 -5 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp.html@1.195.1.1 +7 -7 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp.man.in@1.15.1.1 +4 -4 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + + sntp/sntp.mdoc.in@1.15.1.1 +5 -5 + sntp: change -h/--headspace to -g/--gap, and change the default gap from 10 to 50ms + +ChangeSet@1.2082.4.231, 2011-08-04 15:45:08-04:00, stenn@psp-deb1.ntp.org + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + sntp/sntp-opts.c@1.117.37.1 +19 -19 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + sntp/sntp-opts.h@1.117.37.1 +7 -7 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + sntp/sntp-opts.texi@1.117.36.1 +30 -29 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + sntp/sntp.1@1.117.36.1 +8 -8 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + sntp/sntp.html@1.7.37.1 +96 -77 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + +ChangeSet@1.2082.4.230, 2011-08-04 15:39:31-04:00, stenn@psp-deb1.ntp.org + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + ChangeLog@1.496.26.164 +2 -0 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + sntp/main.c@1.24.1.10 +2 -2 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + + sntp/sntp-opts.def@1.19.1.1 +9 -14 + [Backward Incompatible] sntp: -l/--filelog -> -l/--logfile, to be consistent with ntpd + +ChangeSet@1.2082.4.229, 2011-08-04 15:17:36-04:00, stenn@psp-deb1.ntp.org + libopts/file.c fix from Bruce Korb (arg-type=file) + + ChangeLog@1.496.26.163 +4 -0 + libopts/file.c fix from Bruce Korb (arg-type=file) + + sntp/libopts/file.c@1.8 +4 -2 + libopts/file.c fix from Bruce Korb (arg-type=file) + +ChangeSet@1.2622, 2011-08-04 13:37:42-04:00, stenn@deacon.udel.edu + Update Changelog + + ChangeLog@1.992 +1 -0 + Update Changelog + +ChangeSet@1.2621, 2011-08-04 11:56:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P200 + TAG: NTP_4_2_7P200 + + ChangeLog@1.991 +1 -0 + NTP_4_2_7P200 + + ntpd/ntpd-opts.c@1.205 +3 -3 + NTP_4_2_7P200 + + ntpd/ntpd-opts.h@1.205 +3 -3 + NTP_4_2_7P200 + + ntpd/ntpd-opts.texi@1.203 +2 -2 + NTP_4_2_7P200 + + ntpd/ntpd.1ntpdman@1.16 +2 -2 + NTP_4_2_7P200 + + ntpd/ntpd.1ntpdmdoc@1.16 +2 -2 + NTP_4_2_7P200 + + ntpd/ntpd.man.in@1.16 +2 -2 + NTP_4_2_7P200 + + ntpd/ntpd.mdoc.in@1.16 +2 -2 + NTP_4_2_7P200 + + ntpdc/ntpdc-opts.c@1.200 +3 -3 + NTP_4_2_7P200 + + ntpdc/ntpdc-opts.h@1.200 +3 -3 + NTP_4_2_7P200 + + ntpdc/ntpdc-opts.texi@1.200 +2 -2 + NTP_4_2_7P200 + + ntpdc/ntpdc.1ntpdcman@1.16 +2 -2 + NTP_4_2_7P200 + + ntpdc/ntpdc.1ntpdcmdoc@1.16 +2 -2 + NTP_4_2_7P200 + + ntpdc/ntpdc.html@1.28 +2 -2 + NTP_4_2_7P200 + + ntpdc/ntpdc.man.in@1.16 +2 -2 + NTP_4_2_7P200 + + ntpdc/ntpdc.mdoc.in@1.16 +2 -2 + NTP_4_2_7P200 + + ntpq/ntpq-opts.c@1.202 +3 -3 + NTP_4_2_7P200 + + ntpq/ntpq-opts.h@1.202 +3 -3 + NTP_4_2_7P200 + + ntpq/ntpq-opts.texi@1.202 +2 -2 + NTP_4_2_7P200 + + ntpq/ntpq.1ntpqman@1.16 +2 -2 + NTP_4_2_7P200 + + ntpq/ntpq.1ntpqmdoc@1.16 +2 -2 + NTP_4_2_7P200 + + ntpq/ntpq.man.in@1.16 +2 -2 + NTP_4_2_7P200 + + ntpq/ntpq.mdoc.in@1.16 +2 -2 + NTP_4_2_7P200 + + ntpsnmpd/ntpsnmpd-opts.c@1.202 +3 -3 + NTP_4_2_7P200 + + ntpsnmpd/ntpsnmpd-opts.h@1.202 +3 -3 + NTP_4_2_7P200 + + ntpsnmpd/ntpsnmpd-opts.texi@1.202 +2 -2 + NTP_4_2_7P200 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.16 +2 -2 + NTP_4_2_7P200 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.16 +2 -2 + NTP_4_2_7P200 + + ntpsnmpd/ntpsnmpd.man.in@1.16 +2 -2 + NTP_4_2_7P200 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.16 +2 -2 + NTP_4_2_7P200 + + packageinfo.sh@1.203 +1 -1 + NTP_4_2_7P200 + + scripts/ntp-wait-opts.texi@1.20 +1 -1 + NTP_4_2_7P200 + + scripts/ntp-wait.1ntp-waitman@1.16 +2 -2 + NTP_4_2_7P200 + + scripts/ntp-wait.1ntp-waitmdoc@1.16 +2 -2 + NTP_4_2_7P200 + + scripts/ntp-wait.html@1.20 +1 -1 + NTP_4_2_7P200 + + scripts/ntp-wait.man.in@1.16 +2 -2 + NTP_4_2_7P200 + + scripts/ntp-wait.mdoc.in@1.16 +2 -2 + NTP_4_2_7P200 + + sntp/sntp-opts.c@1.196 +3 -3 + NTP_4_2_7P200 + + sntp/sntp-opts.h@1.196 +3 -3 + NTP_4_2_7P200 + + sntp/sntp-opts.texi@1.196 +2 -2 + NTP_4_2_7P200 + + sntp/sntp.1sntpman@1.16 +2 -2 + NTP_4_2_7P200 + + sntp/sntp.1sntpmdoc@1.16 +2 -2 + NTP_4_2_7P200 + + sntp/sntp.html@1.196 +2 -2 + NTP_4_2_7P200 + + sntp/sntp.man.in@1.16 +2 -2 + NTP_4_2_7P200 + + sntp/sntp.mdoc.in@1.16 +2 -2 + NTP_4_2_7P200 + + util/ntp-keygen-opts.c@1.200 +3 -3 + NTP_4_2_7P200 + + util/ntp-keygen-opts.h@1.200 +3 -3 + NTP_4_2_7P200 + + util/ntp-keygen-opts.texi@1.203 +2 -2 + NTP_4_2_7P200 + + util/ntp-keygen.1ntp-keygenman@1.16 +2 -2 + NTP_4_2_7P200 + + util/ntp-keygen.1ntp-keygenmdoc@1.16 +2 -2 + NTP_4_2_7P200 + + util/ntp-keygen.man.in@1.16 +2 -2 + NTP_4_2_7P200 + + util/ntp-keygen.mdoc.in@1.16 +2 -2 + NTP_4_2_7P200 + +ChangeSet@1.2082.4.228, 2011-08-04 04:50:12+00:00, stenn@deacon.udel.edu + NTP_4_2_6P4_RC2 + TAG: NTP_4_2_6P4_RC2 + + ChangeLog@1.496.26.162 +1 -0 + NTP_4_2_6P4_RC2 + + ntpd/ntpd-opts.c@1.248.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpd/ntpd-opts.h@1.248.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpd/ntpd-opts.texi@1.246.37.1 +2 -2 + NTP_4_2_6P4_RC2 + + ntpd/ntpd.1@1.246.37.1 +2 -2 + NTP_4_2_6P4_RC2 + + ntpdc/ntpdc-opts.c@1.244.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpdc/ntpdc-opts.h@1.244.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpdc/ntpdc-opts.texi@1.243.37.1 +2 -2 + NTP_4_2_6P4_RC2 + + ntpdc/ntpdc.1@1.243.37.1 +2 -2 + NTP_4_2_6P4_RC2 + + ntpq/ntpq-opts.c@1.245.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpq/ntpq-opts.h@1.245.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpq/ntpq-opts.texi@1.244.37.1 +2 -2 + NTP_4_2_6P4_RC2 + + ntpq/ntpq.1@1.244.37.1 +2 -2 + NTP_4_2_6P4_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.39.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.39.1 +3 -3 + NTP_4_2_6P4_RC2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.38.1 +2 -2 + NTP_4_2_6P4_RC2 + + ntpsnmpd/ntpsnmpd.1@1.122.38.1 +2 -2 + NTP_4_2_6P4_RC2 + + packageinfo.sh@1.255.35.1 +1 -1 + NTP_4_2_6P4_RC2 + + sntp/sntp-opts.c@1.117.36.1 +3 -3 + NTP_4_2_6P4_RC2 + + sntp/sntp-opts.h@1.117.36.1 +3 -3 + NTP_4_2_6P4_RC2 + + sntp/sntp-opts.texi@1.117.35.1 +2 -2 + NTP_4_2_6P4_RC2 + + sntp/sntp.1@1.117.35.1 +2 -2 + NTP_4_2_6P4_RC2 + + sntp/sntp.html@1.7.36.1 +2 -2 + NTP_4_2_6P4_RC2 + + util/ntp-keygen-opts.c@1.247.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + util/ntp-keygen-opts.h@1.247.38.1 +3 -3 + NTP_4_2_6P4_RC2 + + util/ntp-keygen-opts.texi@1.246.37.1 +2 -2 + NTP_4_2_6P4_RC2 + + util/ntp-keygen.1@1.246.37.1 +2 -2 + NTP_4_2_6P4_RC2 + +ChangeSet@1.2619, 2011-07-29 11:12:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P199 + TAG: NTP_4_2_7P199 + + ChangeLog@1.989 +1 -0 + NTP_4_2_7P199 + + ntpd/ntpd-opts.c@1.204 +3 -3 + NTP_4_2_7P199 + + ntpd/ntpd-opts.h@1.204 +3 -3 + NTP_4_2_7P199 + + ntpd/ntpd-opts.texi@1.202 +2 -2 + NTP_4_2_7P199 + + ntpd/ntpd.1ntpdman@1.15 +2 -2 + NTP_4_2_7P199 + + ntpd/ntpd.1ntpdmdoc@1.15 +2 -2 + NTP_4_2_7P199 + + ntpd/ntpd.man.in@1.15 +2 -2 + NTP_4_2_7P199 + + ntpd/ntpd.mdoc.in@1.15 +2 -2 + NTP_4_2_7P199 + + ntpdc/ntpdc-opts.c@1.199 +3 -3 + NTP_4_2_7P199 + + ntpdc/ntpdc-opts.h@1.199 +3 -3 + NTP_4_2_7P199 + + ntpdc/ntpdc-opts.texi@1.199 +2 -2 + NTP_4_2_7P199 + + ntpdc/ntpdc.1ntpdcman@1.15 +2 -2 + NTP_4_2_7P199 + + ntpdc/ntpdc.1ntpdcmdoc@1.15 +2 -2 + NTP_4_2_7P199 + + ntpdc/ntpdc.html@1.27 +2 -2 + NTP_4_2_7P199 + + ntpdc/ntpdc.man.in@1.15 +2 -2 + NTP_4_2_7P199 + + ntpdc/ntpdc.mdoc.in@1.15 +2 -2 + NTP_4_2_7P199 + + ntpq/ntpq-opts.c@1.201 +3 -3 + NTP_4_2_7P199 + + ntpq/ntpq-opts.h@1.201 +3 -3 + NTP_4_2_7P199 + + ntpq/ntpq-opts.texi@1.201 +2 -2 + NTP_4_2_7P199 + + ntpq/ntpq.1ntpqman@1.15 +2 -2 + NTP_4_2_7P199 + + ntpq/ntpq.1ntpqmdoc@1.15 +2 -2 + NTP_4_2_7P199 + + ntpq/ntpq.man.in@1.15 +2 -2 + NTP_4_2_7P199 + + ntpq/ntpq.mdoc.in@1.15 +2 -2 + NTP_4_2_7P199 + + ntpsnmpd/ntpsnmpd-opts.c@1.201 +3 -3 + NTP_4_2_7P199 + + ntpsnmpd/ntpsnmpd-opts.h@1.201 +3 -3 + NTP_4_2_7P199 + + ntpsnmpd/ntpsnmpd-opts.texi@1.201 +2 -2 + NTP_4_2_7P199 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.15 +2 -2 + NTP_4_2_7P199 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.15 +2 -2 + NTP_4_2_7P199 + + ntpsnmpd/ntpsnmpd.man.in@1.15 +2 -2 + NTP_4_2_7P199 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.15 +2 -2 + NTP_4_2_7P199 + + packageinfo.sh@1.202 +1 -1 + NTP_4_2_7P199 + + scripts/ntp-wait-opts.texi@1.19 +1 -1 + NTP_4_2_7P199 + + scripts/ntp-wait.1ntp-waitman@1.15 +2 -2 + NTP_4_2_7P199 + + scripts/ntp-wait.1ntp-waitmdoc@1.15 +2 -2 + NTP_4_2_7P199 + + scripts/ntp-wait.html@1.19 +1 -1 + NTP_4_2_7P199 + + scripts/ntp-wait.man.in@1.15 +2 -2 + NTP_4_2_7P199 + + scripts/ntp-wait.mdoc.in@1.15 +2 -2 + NTP_4_2_7P199 + + sntp/sntp-opts.c@1.195 +3 -3 + NTP_4_2_7P199 + + sntp/sntp-opts.h@1.195 +3 -3 + NTP_4_2_7P199 + + sntp/sntp-opts.texi@1.195 +2 -2 + NTP_4_2_7P199 + + sntp/sntp.1sntpman@1.15 +2 -2 + NTP_4_2_7P199 + + sntp/sntp.1sntpmdoc@1.15 +2 -2 + NTP_4_2_7P199 + + sntp/sntp.html@1.195 +2 -2 + NTP_4_2_7P199 + + sntp/sntp.man.in@1.15 +2 -2 + NTP_4_2_7P199 + + sntp/sntp.mdoc.in@1.15 +2 -2 + NTP_4_2_7P199 + + util/ntp-keygen-opts.c@1.199 +3 -3 + NTP_4_2_7P199 + + util/ntp-keygen-opts.h@1.199 +3 -3 + NTP_4_2_7P199 + + util/ntp-keygen-opts.texi@1.202 +2 -2 + NTP_4_2_7P199 + + util/ntp-keygen.1ntp-keygenman@1.15 +2 -2 + NTP_4_2_7P199 + + util/ntp-keygen.1ntp-keygenmdoc@1.15 +2 -2 + NTP_4_2_7P199 + + util/ntp-keygen.man.in@1.15 +2 -2 + NTP_4_2_7P199 + + util/ntp-keygen.mdoc.in@1.15 +2 -2 + NTP_4_2_7P199 + +ChangeSet@1.2618, 2011-07-29 04:19:55-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.988 +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.56 +2 -2 + Documentation updates from Dave Mills + + html/warp.html@1.16 +20 -12 + Documentation updates from Dave Mills + +ChangeSet@1.2617, 2011-07-28 08:48:08+00:00, stenn@deacon.udel.edu + NTP_4_2_7P198 + TAG: NTP_4_2_7P198 + + ChangeLog@1.987 +1 -0 + NTP_4_2_7P198 + + ntpd/ntpd-opts.c@1.203 +3 -3 + NTP_4_2_7P198 + + ntpd/ntpd-opts.h@1.203 +3 -3 + NTP_4_2_7P198 + + ntpd/ntpd-opts.texi@1.201 +2 -2 + NTP_4_2_7P198 + + ntpd/ntpd.1ntpdman@1.14 +2 -2 + NTP_4_2_7P198 + + ntpd/ntpd.1ntpdmdoc@1.14 +1 -1 + NTP_4_2_7P198 + + ntpd/ntpd.man.in@1.14 +2 -2 + NTP_4_2_7P198 + + ntpd/ntpd.mdoc.in@1.14 +1 -1 + NTP_4_2_7P198 + + ntpdc/ntpdc-opts.c@1.198 +3 -3 + NTP_4_2_7P198 + + ntpdc/ntpdc-opts.h@1.198 +3 -3 + NTP_4_2_7P198 + + ntpdc/ntpdc-opts.texi@1.198 +2 -2 + NTP_4_2_7P198 + + ntpdc/ntpdc.1ntpdcman@1.14 +2 -2 + NTP_4_2_7P198 + + ntpdc/ntpdc.1ntpdcmdoc@1.14 +1 -1 + NTP_4_2_7P198 + + ntpdc/ntpdc.html@1.26 +2 -2 + NTP_4_2_7P198 + + ntpdc/ntpdc.man.in@1.14 +2 -2 + NTP_4_2_7P198 + + ntpdc/ntpdc.mdoc.in@1.14 +1 -1 + NTP_4_2_7P198 + + ntpq/ntpq-opts.c@1.200 +3 -3 + NTP_4_2_7P198 + + ntpq/ntpq-opts.h@1.200 +3 -3 + NTP_4_2_7P198 + + ntpq/ntpq-opts.texi@1.200 +2 -2 + NTP_4_2_7P198 + + ntpq/ntpq.1ntpqman@1.14 +2 -2 + NTP_4_2_7P198 + + ntpq/ntpq.1ntpqmdoc@1.14 +1 -1 + NTP_4_2_7P198 + + ntpq/ntpq.man.in@1.14 +2 -2 + NTP_4_2_7P198 + + ntpq/ntpq.mdoc.in@1.14 +1 -1 + NTP_4_2_7P198 + + ntpsnmpd/ntpsnmpd-opts.c@1.200 +3 -3 + NTP_4_2_7P198 + + ntpsnmpd/ntpsnmpd-opts.h@1.200 +3 -3 + NTP_4_2_7P198 + + ntpsnmpd/ntpsnmpd-opts.texi@1.200 +2 -2 + NTP_4_2_7P198 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.14 +2 -2 + NTP_4_2_7P198 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.14 +1 -1 + NTP_4_2_7P198 + + ntpsnmpd/ntpsnmpd.man.in@1.14 +2 -2 + NTP_4_2_7P198 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.14 +1 -1 + NTP_4_2_7P198 + + packageinfo.sh@1.201 +1 -1 + NTP_4_2_7P198 + + scripts/ntp-wait-opts.texi@1.18 +1 -1 + NTP_4_2_7P198 + + scripts/ntp-wait.1ntp-waitman@1.14 +2 -2 + NTP_4_2_7P198 + + scripts/ntp-wait.1ntp-waitmdoc@1.14 +1 -1 + NTP_4_2_7P198 + + scripts/ntp-wait.html@1.18 +1 -1 + NTP_4_2_7P198 + + scripts/ntp-wait.man.in@1.14 +2 -2 + NTP_4_2_7P198 + + scripts/ntp-wait.mdoc.in@1.14 +1 -1 + NTP_4_2_7P198 + + sntp/sntp-opts.c@1.194 +3 -3 + NTP_4_2_7P198 + + sntp/sntp-opts.h@1.194 +3 -3 + NTP_4_2_7P198 + + sntp/sntp-opts.texi@1.194 +2 -2 + NTP_4_2_7P198 + + sntp/sntp.1sntpman@1.14 +2 -2 + NTP_4_2_7P198 + + sntp/sntp.1sntpmdoc@1.14 +1 -1 + NTP_4_2_7P198 + + sntp/sntp.html@1.194 +2 -2 + NTP_4_2_7P198 + + sntp/sntp.man.in@1.14 +2 -2 + NTP_4_2_7P198 + + sntp/sntp.mdoc.in@1.14 +1 -1 + NTP_4_2_7P198 + + util/ntp-keygen-opts.c@1.198 +3 -3 + NTP_4_2_7P198 + + util/ntp-keygen-opts.h@1.198 +3 -3 + NTP_4_2_7P198 + + util/ntp-keygen-opts.texi@1.201 +2 -2 + NTP_4_2_7P198 + + util/ntp-keygen.1ntp-keygenman@1.14 +2 -2 + NTP_4_2_7P198 + + util/ntp-keygen.1ntp-keygenmdoc@1.14 +1 -1 + NTP_4_2_7P198 + + util/ntp-keygen.man.in@1.14 +2 -2 + NTP_4_2_7P198 + + util/ntp-keygen.mdoc.in@1.14 +1 -1 + NTP_4_2_7P198 + +ChangeSet@1.2616, 2011-07-28 04:04:18-04:00, stenn@deacon.udel.edu + remove old binsubdir stuff from SNTP, as NTP_LOCINFO does that now. + + ChangeLog@1.986 +1 -0 + remove old binsubdir stuff from SNTP, as NTP_LOCINFO does that now. + + sntp/configure.ac@1.66 +0 -100 + remove old binsubdir stuff from SNTP, as NTP_LOCINFO does that now. + +ChangeSet@1.2615, 2011-07-28 07:03:09+00:00, stenn@deacon.udel.edu + NTP_4_2_7P197 + TAG: NTP_4_2_7P197 + + ChangeLog@1.985 +1 -0 + NTP_4_2_7P197 + + ntpd/ntpd-opts.c@1.202 +3 -3 + NTP_4_2_7P197 + + ntpd/ntpd-opts.h@1.202 +3 -3 + NTP_4_2_7P197 + + ntpd/ntpd-opts.texi@1.200 +2 -2 + NTP_4_2_7P197 + + ntpd/ntpd.1ntpdman@1.13 +2 -2 + NTP_4_2_7P197 + + ntpd/ntpd.1ntpdmdoc@1.13 +2 -2 + NTP_4_2_7P197 + + ntpd/ntpd.man.in@1.13 +2 -2 + NTP_4_2_7P197 + + ntpd/ntpd.mdoc.in@1.13 +2 -2 + NTP_4_2_7P197 + + ntpdc/ntpdc-opts.c@1.197 +3 -3 + NTP_4_2_7P197 + + ntpdc/ntpdc-opts.h@1.197 +3 -3 + NTP_4_2_7P197 + + ntpdc/ntpdc-opts.texi@1.197 +2 -2 + NTP_4_2_7P197 + + ntpdc/ntpdc.1ntpdcman@1.13 +2 -2 + NTP_4_2_7P197 + + ntpdc/ntpdc.1ntpdcmdoc@1.13 +2 -2 + NTP_4_2_7P197 + + ntpdc/ntpdc.html@1.25 +2 -2 + NTP_4_2_7P197 + + ntpdc/ntpdc.man.in@1.13 +2 -2 + NTP_4_2_7P197 + + ntpdc/ntpdc.mdoc.in@1.13 +2 -2 + NTP_4_2_7P197 + + ntpq/ntpq-opts.c@1.199 +3 -3 + NTP_4_2_7P197 + + ntpq/ntpq-opts.h@1.199 +3 -3 + NTP_4_2_7P197 + + ntpq/ntpq-opts.texi@1.199 +2 -2 + NTP_4_2_7P197 + + ntpq/ntpq.1ntpqman@1.13 +2 -2 + NTP_4_2_7P197 + + ntpq/ntpq.1ntpqmdoc@1.13 +2 -2 + NTP_4_2_7P197 + + ntpq/ntpq.man.in@1.13 +2 -2 + NTP_4_2_7P197 + + ntpq/ntpq.mdoc.in@1.13 +2 -2 + NTP_4_2_7P197 + + ntpsnmpd/ntpsnmpd-opts.c@1.199 +3 -3 + NTP_4_2_7P197 + + ntpsnmpd/ntpsnmpd-opts.h@1.199 +3 -3 + NTP_4_2_7P197 + + ntpsnmpd/ntpsnmpd-opts.texi@1.199 +2 -2 + NTP_4_2_7P197 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.13 +2 -2 + NTP_4_2_7P197 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.13 +2 -2 + NTP_4_2_7P197 + + ntpsnmpd/ntpsnmpd.man.in@1.13 +2 -2 + NTP_4_2_7P197 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.13 +2 -2 + NTP_4_2_7P197 + + packageinfo.sh@1.200 +1 -1 + NTP_4_2_7P197 + + scripts/ntp-wait-opts.texi@1.17 +1 -1 + NTP_4_2_7P197 + + scripts/ntp-wait.1ntp-waitman@1.13 +2 -2 + NTP_4_2_7P197 + + scripts/ntp-wait.1ntp-waitmdoc@1.13 +2 -2 + NTP_4_2_7P197 + + scripts/ntp-wait.html@1.17 +1 -1 + NTP_4_2_7P197 + + scripts/ntp-wait.man.in@1.13 +2 -2 + NTP_4_2_7P197 + + scripts/ntp-wait.mdoc.in@1.13 +2 -2 + NTP_4_2_7P197 + + sntp/sntp-opts.c@1.193 +3 -3 + NTP_4_2_7P197 + + sntp/sntp-opts.h@1.193 +3 -3 + NTP_4_2_7P197 + + sntp/sntp-opts.texi@1.193 +2 -2 + NTP_4_2_7P197 + + sntp/sntp.1sntpman@1.13 +2 -2 + NTP_4_2_7P197 + + sntp/sntp.1sntpmdoc@1.13 +2 -2 + NTP_4_2_7P197 + + sntp/sntp.html@1.193 +2 -2 + NTP_4_2_7P197 + + sntp/sntp.man.in@1.13 +2 -2 + NTP_4_2_7P197 + + sntp/sntp.mdoc.in@1.13 +2 -2 + NTP_4_2_7P197 + + util/ntp-keygen-opts.c@1.197 +3 -3 + NTP_4_2_7P197 + + util/ntp-keygen-opts.h@1.197 +3 -3 + NTP_4_2_7P197 + + util/ntp-keygen-opts.texi@1.200 +4 -4 + NTP_4_2_7P197 + + util/ntp-keygen.1ntp-keygenman@1.13 +4 -4 + NTP_4_2_7P197 + + util/ntp-keygen.1ntp-keygenmdoc@1.13 +4 -4 + NTP_4_2_7P197 + + util/ntp-keygen.man.in@1.13 +4 -4 + NTP_4_2_7P197 + + util/ntp-keygen.mdoc.in@1.13 +4 -4 + NTP_4_2_7P197 + +ChangeSet@1.2082.4.227, 2011-07-28 02:59:20-04:00, stenn@deacon.udel.edu + Backport if_nametoindex() check for hpux + + ChangeLog@1.496.26.161 +1 -0 + Backport if_nametoindex() check for hpux + + configure.ac@1.465.1.29 +4 -10 + Backport if_nametoindex() check for hpux + +ChangeSet@1.2612.1.9, 2011-07-28 02:25:31-04:00, stenn@deacon.udel.edu + cleanup + + ChangeLog@1.984 +1 -1 + cleanup + +ChangeSet@1.2612.1.8, 2011-07-27 22:10:08-07:00, harlan@hms-mbp.local + [Bug 1977] Mismatch between flag and description in ntp-keygen-opts.def + + ChangeLog@1.983 +1 -0 + [Bug 1977] Mismatch between flag and description in ntp-keygen-opts.def + + util/ntp-keygen-opts.def@1.15 +2 -2 + [Bug 1977] Mismatch between flag and description in ntp-keygen-opts.def + +ChangeSet@1.2612.1.7, 2011-07-27 19:45:16-04:00, stenn@deacon.udel.edu + Update sntp/loc/solaris to conform to stock locations + + ChangeLog@1.982 +1 -0 + Update sntp/loc/solaris to conform to stock locations + + sntp/loc/solaris@1.3 +11 -11 + Update sntp/loc/solaris to conform to stock locations + +ChangeSet@1.2612.1.6, 2011-07-27 22:42:23+00:00, davehart@shiny.ad.hartbrothers.com + Fix warnings in ntp_request.c ([Bug 1973] oversight) and sntp/main.c + (CID 159, apparent overrun due to union, actually correct). + + ChangeLog@1.981 +2 -0 + Fix warnings in ntp_request.c ([Bug 1973] oversight) and sntp/main.c + (CID 159, apparent overrun due to union, actually correct). + + ntpd/ntp_request.c@1.106 +1 -1 + Fix warning in ntp_request.c ([Bug 1973] fix oversight, peer->ttl is now + 32 bits but mode 7 protocol still uses 8 bits, cast to avoid truncation + warning. + + sntp/main.c@1.73 +1 -1 + Fix CID 159, apparent overrun due to union, actually correct. + + sntp/networking.c@1.60 +3 -3 + Fix CID 159, apparent overrun due to union, actually correct. + + sntp/networking.h@1.26 +1 -1 + Fix CID 159, apparent overrun due to union, actually correct. + +ChangeSet@1.2082.4.226, 2011-07-27 22:22:03+00:00, davehart@shiny.ad.hartbrothers.com + Correct [Bug 1978] description in ChangeLog. + + ChangeLog@1.496.26.160 +1 -1 + [Bug 1978] [Bug 1134] fix in 4.2.6p4-RC1 doesn't build on older Linux. + +ChangeSet@1.2082.4.225, 2011-07-27 21:41:02+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1978] Ignore tentative IP addresses on Linux. + Backport several fixes for Coverity warnings from ntp-dev. + + ChangeLog@1.496.26.159 +2 -0 + [Bug 1978] Ignore tentative IP addresses on Linux. + Backport several fixes for Coverity warnings from ntp-dev. + + configure.ac@1.465.1.28 +9 -0 + [Bug 1978] Ignore tentative IP addresses on Linux. + + include/ntp_rfc2553.h@1.33.1.1 +10 -2 + Backport several fixes for Coverity warnings from ntp-dev. + + lib/isc/unix/interfaceiter.c@1.19.1.2 +5 -3 + [Bug 1978] Ignore tentative IP addresses on Linux. + + libntp/audio.c@1.27.1.1 +29 -29 + Backport several fixes for Coverity warnings from ntp-dev. + + libntp/decodenetnum.c@1.10.1.1 +43 -10 + Backport several fixes for Coverity warnings from ntp-dev. + + libntp/icom.c@1.11.1.1 +34 -10 + Backport several fixes for Coverity warnings from ntp-dev. + + ntpd/refclock_arc.c@1.22.1.1 +37 -34 + Backport several fixes for Coverity warnings from ntp-dev. + + ntpdc/ntpdc.c@1.75.1.5 +25 -17 + Backport several fixes for Coverity warnings from ntp-dev. + + ntpq/ntpq.c@1.97.1.9 +25 -17 + Backport several fixes for Coverity warnings from ntp-dev. + +ChangeSet@1.2612.1.3, 2011-07-27 16:38:38+00:00, davehart@shiny.ad.hartbrothers.com + Do not force "legacy" when --with-locfile is not given, genLocInfo + will find the correct default for the system. + + ChangeLog@1.978 +2 -0 + Do not force "legacy" when --with-locfile is not given, genLocInfo + will find the correct default for the system. + + sntp/m4/ntp_locinfo.m4@1.14 +13 -4 + Do not force "legacy" when --with-locfile is not given, genLocInfo + will find the correct default for the system. + +ChangeSet@1.2612.1.1, 2011-07-27 06:27:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1976] genLocInfo writes to srcdir break 'make distcheck'. + + ChangeLog@1.976 +2 -1 + [Bug 1976] genLocInfo writes to srcdir break 'make distcheck'. + + sntp/m4/ntp_locinfo.m4@1.13 +8 -6 + [Bug 1976] genLocInfo writes to srcdir break 'make distcheck'. + + sntp/scripts/Makefile.am@1.3 +0 -3 + Remove unneeded DISTCLEANFILES=config.log in sntp/scripts/Makefile.am. + + sntp/scripts/genLocInfo@1.14.1.1 +17 -11 + [Bug 1976] genLocInfo writes to srcdir break 'make distcheck'. + +ChangeSet@1.2613, 2011-07-26 22:44:46-04:00, stenn@deacon.udel.edu + cleanup + + sntp/scripts/genLocInfo@1.15 +1 -1 + cleanup + +ChangeSet@1.2612, 2011-07-27 02:25:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P196 + TAG: NTP_4_2_7P196 + + ChangeLog@1.975 +1 -0 + NTP_4_2_7P196 + + ntpd/ntpd-opts.c@1.201 +3 -3 + NTP_4_2_7P196 + + ntpd/ntpd-opts.h@1.201 +3 -3 + NTP_4_2_7P196 + + ntpd/ntpd-opts.texi@1.199 +2 -2 + NTP_4_2_7P196 + + ntpd/ntpd.1ntpdman@1.12 +2 -2 + NTP_4_2_7P196 + + ntpd/ntpd.1ntpdmdoc@1.12 +2 -2 + NTP_4_2_7P196 + + ntpd/ntpd.man.in@1.12 +2 -2 + NTP_4_2_7P196 + + ntpd/ntpd.mdoc.in@1.12 +2 -2 + NTP_4_2_7P196 + + ntpdc/ntpdc-opts.c@1.196 +3 -3 + NTP_4_2_7P196 + + ntpdc/ntpdc-opts.h@1.196 +3 -3 + NTP_4_2_7P196 + + ntpdc/ntpdc-opts.texi@1.196 +2 -2 + NTP_4_2_7P196 + + ntpdc/ntpdc.1ntpdcman@1.12 +2 -2 + NTP_4_2_7P196 + + ntpdc/ntpdc.1ntpdcmdoc@1.12 +2 -2 + NTP_4_2_7P196 + + ntpdc/ntpdc.html@1.24 +2 -2 + NTP_4_2_7P196 + + ntpdc/ntpdc.man.in@1.12 +2 -2 + NTP_4_2_7P196 + + ntpdc/ntpdc.mdoc.in@1.12 +2 -2 + NTP_4_2_7P196 + + ntpq/ntpq-opts.c@1.198 +3 -3 + NTP_4_2_7P196 + + ntpq/ntpq-opts.h@1.198 +3 -3 + NTP_4_2_7P196 + + ntpq/ntpq-opts.texi@1.198 +2 -2 + NTP_4_2_7P196 + + ntpq/ntpq.1ntpqman@1.12 +2 -2 + NTP_4_2_7P196 + + ntpq/ntpq.1ntpqmdoc@1.12 +2 -2 + NTP_4_2_7P196 + + ntpq/ntpq.man.in@1.12 +2 -2 + NTP_4_2_7P196 + + ntpq/ntpq.mdoc.in@1.12 +2 -2 + NTP_4_2_7P196 + + ntpsnmpd/ntpsnmpd-opts.c@1.198 +3 -3 + NTP_4_2_7P196 + + ntpsnmpd/ntpsnmpd-opts.h@1.198 +3 -3 + NTP_4_2_7P196 + + ntpsnmpd/ntpsnmpd-opts.texi@1.198 +2 -2 + NTP_4_2_7P196 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.12 +2 -2 + NTP_4_2_7P196 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.12 +2 -2 + NTP_4_2_7P196 + + ntpsnmpd/ntpsnmpd.man.in@1.12 +2 -2 + NTP_4_2_7P196 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.12 +2 -2 + NTP_4_2_7P196 + + packageinfo.sh@1.199 +1 -1 + NTP_4_2_7P196 + + scripts/ntp-wait-opts.texi@1.16 +1 -1 + NTP_4_2_7P196 + + scripts/ntp-wait.1ntp-waitman@1.12 +2 -2 + NTP_4_2_7P196 + + scripts/ntp-wait.1ntp-waitmdoc@1.12 +2 -2 + NTP_4_2_7P196 + + scripts/ntp-wait.html@1.16 +1 -1 + NTP_4_2_7P196 + + scripts/ntp-wait.man.in@1.12 +2 -2 + NTP_4_2_7P196 + + scripts/ntp-wait.mdoc.in@1.12 +2 -2 + NTP_4_2_7P196 + + sntp/sntp-opts.c@1.192 +3 -3 + NTP_4_2_7P196 + + sntp/sntp-opts.h@1.192 +3 -3 + NTP_4_2_7P196 + + sntp/sntp-opts.texi@1.192 +2 -2 + NTP_4_2_7P196 + + sntp/sntp.1sntpman@1.12 +2 -2 + NTP_4_2_7P196 + + sntp/sntp.1sntpmdoc@1.12 +2 -2 + NTP_4_2_7P196 + + sntp/sntp.html@1.192 +2 -2 + NTP_4_2_7P196 + + sntp/sntp.man.in@1.12 +2 -2 + NTP_4_2_7P196 + + sntp/sntp.mdoc.in@1.12 +2 -2 + NTP_4_2_7P196 + + util/ntp-keygen-opts.c@1.196 +3 -3 + NTP_4_2_7P196 + + util/ntp-keygen-opts.h@1.196 +3 -3 + NTP_4_2_7P196 + + util/ntp-keygen-opts.texi@1.199 +2 -2 + NTP_4_2_7P196 + + util/ntp-keygen.1ntp-keygenman@1.12 +2 -2 + NTP_4_2_7P196 + + util/ntp-keygen.1ntp-keygenmdoc@1.12 +2 -2 + NTP_4_2_7P196 + + util/ntp-keygen.man.in@1.12 +2 -2 + NTP_4_2_7P196 + + util/ntp-keygen.mdoc.in@1.12 +2 -2 + NTP_4_2_7P196 + +ChangeSet@1.2611, 2011-07-26 21:55:09-04:00, stenn@deacon.udel.edu + use --with-loc=legacy in br-flock + + br-flock@1.16 +1 -1 + use --with-loc=legacy in br-flock + +ChangeSet@1.2610, 2011-07-26 21:51:16-04:00, stenn@deacon.udel.edu + cleanup + + ChangeLog@1.974 +1 -1 + cleanup + +ChangeSet@1.2609, 2011-07-26 21:38:54-04:00, stenn@pogo.udel.edu + work around solaris /bin/sh issues for genLocInfo. + + ChangeLog@1.973 +1 -0 + work around solaris /bin/sh issues for genLocInfo. + + sntp/scripts/genLocInfo@1.14 +23 -12 + work around solaris /bin/sh issues for genLocInfo. + +ChangeSet@1.2608, 2011-07-26 14:26:17-04:00, stenn@psp-deb1.ntp.org + Be louder about loc/ changes + + ChangeLog@1.972 +2 -0 + Be louder about loc/ changes + +ChangeSet@1.2607, 2011-07-26 14:23:35-04:00, stenn@psp-deb1.ntp.org + Improve the help text: --with-locfile=XXX + + ChangeLog@1.971 +1 -0 + Improve the help text: --with-locfile=XXX + + sntp/m4/ntp_locinfo.m4@1.12 +1 -1 + Improve the help text: --with-locfile=XXX + +ChangeSet@1.2606, 2011-07-26 14:10:34-04:00, stenn@psp-deb1.ntp.org + genLocInfo cleanup + + ChangeLog@1.970 +10 -0 + genLocInfo cleanup + + Makefile.am@1.113 +0 -1 + genLocInfo cleanup + + build@1.46 +4 -4 + genLocInfo cleanup + + configure.ac@1.533 +1 -20 + genLocInfo cleanup + + ntpd/Makefile.am@1.110 +4 -4 + genLocInfo cleanup + + ntpdc/Makefile.am@1.66 +4 -4 + genLocInfo cleanup + + ntpq/Makefile.am@1.62 +4 -4 + genLocInfo cleanup + + ntpsnmpd/Makefile.am@1.33 +4 -4 + genLocInfo cleanup + + scripts/Makefile.am@1.29 +4 -6 + genLocInfo cleanup + + sntp/Makefile.am@1.66 +7 -6 + genLocInfo cleanup + + sntp/configure.ac@1.65 +2 -2 + genLocInfo cleanup + + sntp/include/Makefile.am@1.4 +0 -1 + genLocInfo cleanup + + sntp/loc/README@1.1 +9 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/loc/README + + sntp/loc/README@1.0 +0 -0 + + sntp/loc/freebsd@1.4 +0 -0 + Rename: loc/freebsd -> sntp/loc/freebsd + + sntp/loc/legacy@1.4 +0 -0 + Rename: loc/legacy -> sntp/loc/legacy + + sntp/loc/redhat@1.2 +0 -0 + Rename: loc/redhat -> sntp/loc/redhat + + sntp/loc/solaris@1.2 +0 -0 + Rename: loc/solaris -> sntp/loc/solaris + + sntp/m4/ntp_locinfo.m4@1.11 +59 -58 + genLocInfo cleanup + + sntp/scripts/Makefile.am@1.2 +1 -0 + genLocInfo cleanup + + sntp/scripts/Makefile.am@1.1 +9 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/scripts/Makefile.am + + sntp/scripts/Makefile.am@1.0 +0 -0 + + sntp/scripts/cvo.sh@1.7 +0 -0 + Rename: scripts/cvo.sh -> sntp/scripts/cvo.sh + + sntp/scripts/genLocInfo@1.13 +37 -3 + genLocInfo cleanup + + sntp/scripts/genLocInfo@1.12 +0 -0 + Rename: scripts/genLocInfo -> sntp/scripts/genLocInfo + + sntp/scripts/mansec2subst.sed@1.2 +0 -0 + Rename: sntp/include/mansec2subst.sed -> sntp/scripts/mansec2subst.sed + + util/Makefile.am@1.65 +4 -4 + genLocInfo cleanup + +ChangeSet@1.2082.4.224, 2011-07-26 11:21:46+02:00, karlsson@beam.lund.zozs.se + [Bug 1975] libntp/mktime.c won't work with 64-bit time_t + + ChangeLog@1.496.26.158 +1 -0 + [Bug 1975] libntp/mktime.c won't work with 64-bit time_t + + libntp/mktime.c@1.8.1.2 +4 -0 + [Bug 1975] libntp/mktime.c won't work with 64-bit time_t + +ChangeSet@1.2605, 2011-07-26 01:57:56-04:00, stenn@psp-deb1.ntp.org + Removed sntp/m4/ntp_bindir.m4 - no longer needed + + BitKeeper/deleted/a9/ntp_bindir.m4~14281a43d40ac9cd@1.2 +0 -0 + Delete: sntp/m4/ntp_bindir.m4 + + ChangeLog@1.969 +1 -0 + Removed sntp/m4/ntp_bindir.m4 - no longer needed + +ChangeSet@1.2604, 2011-07-26 01:59:51+00:00, davehart@shiny.ad.hartbrothers.com + Fix build on Linux systems lacking linux/if_addr.h or IFA_F_TENTATIVE. + + lib/isc/unix/interfaceiter.c@1.22 +3 -1 + Fix build on Linux systems lacking linux/if_addr.h or IFA_F_TENTATIVE. + + sntp/m4/ntp_libntp.m4@1.16 +9 -0 + Fix build on Linux systems lacking linux/if_addr.h or IFA_F_TENTATIVE. + +ChangeSet@1.2603, 2011-07-26 00:18:29+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + ChangeLog@1.968 +1 -0 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + include/ntp.h@1.196 +1 -1 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + include/ntp_config.h@1.74 +2 -1 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + include/ntpd.h@1.165 +3 -3 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + libntp/tsftomsu.c@1.4 +10 -7 + Eliminate warning: "round" shadows global (use "round_it"). + + ntpd/complete.conf@1.17 +1 -1 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + ntpd/keyword-gen-utd@1.14 +1 -1 + keyword-gen output + + ntpd/ntp_config.c@1.292 +18 -6 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + ntpd/ntp_keyword.h@1.16 +62 -61 + keyword-gen output + + ntpd/ntp_parser.c@1.76 +747 -744 + Bison output + + ntpd/ntp_parser.h@1.43 +44 -41 + Bison output + + ntpd/ntp_parser.y@1.70 +7 -3 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + ntpd/ntp_peer.c@1.148 +6 -6 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + ntpd/ntp_scanner.c@1.43 +103 -26 + [Bug 1973] Widen reference clock mode from 8 to 32 bits. + + sntp/main.c@1.72 +1 -1 + Quiet incompatible type to recvdata() warning. + +ChangeSet@1.2082.4.223, 2011-07-25 14:10:27+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1972] checking for struct rtattr fails. + + ChangeLog@1.496.26.157 +1 -0 + [Bug 1972] checking for struct rtattr fails. + + configure.ac@1.465.1.27 +6 -5 + [Bug 1972] checking for struct rtattr fails. + +ChangeSet@1.2601, 2011-07-25 08:10:23+00:00, stenn@deacon.udel.edu + NTP_4_2_7P195 + TAG: NTP_4_2_7P195 + + ChangeLog@1.966 +1 -0 + NTP_4_2_7P195 + + ntpd/ntpd-opts.c@1.200 +3 -3 + NTP_4_2_7P195 + + ntpd/ntpd-opts.h@1.200 +3 -3 + NTP_4_2_7P195 + + ntpd/ntpd-opts.texi@1.198 +2 -2 + NTP_4_2_7P195 + + ntpd/ntpd.1ntpdman@1.11 +2 -2 + NTP_4_2_7P195 + + ntpd/ntpd.1ntpdmdoc@1.11 +1 -1 + NTP_4_2_7P195 + + ntpd/ntpd.man.in@1.11 +2 -2 + NTP_4_2_7P195 + + ntpd/ntpd.mdoc.in@1.11 +1 -1 + NTP_4_2_7P195 + + ntpdc/ntpdc-opts.c@1.195 +3 -3 + NTP_4_2_7P195 + + ntpdc/ntpdc-opts.h@1.195 +3 -3 + NTP_4_2_7P195 + + ntpdc/ntpdc-opts.texi@1.195 +2 -2 + NTP_4_2_7P195 + + ntpdc/ntpdc.1ntpdcman@1.11 +2 -2 + NTP_4_2_7P195 + + ntpdc/ntpdc.1ntpdcmdoc@1.11 +1 -1 + NTP_4_2_7P195 + + ntpdc/ntpdc.html@1.23 +2 -2 + NTP_4_2_7P195 + + ntpdc/ntpdc.man.in@1.11 +2 -2 + NTP_4_2_7P195 + + ntpdc/ntpdc.mdoc.in@1.11 +1 -1 + NTP_4_2_7P195 + + ntpq/ntpq-opts.c@1.197 +3 -3 + NTP_4_2_7P195 + + ntpq/ntpq-opts.h@1.197 +3 -3 + NTP_4_2_7P195 + + ntpq/ntpq-opts.texi@1.197 +2 -2 + NTP_4_2_7P195 + + ntpq/ntpq.1ntpqman@1.11 +2 -2 + NTP_4_2_7P195 + + ntpq/ntpq.1ntpqmdoc@1.11 +1 -1 + NTP_4_2_7P195 + + ntpq/ntpq.man.in@1.11 +2 -2 + NTP_4_2_7P195 + + ntpq/ntpq.mdoc.in@1.11 +1 -1 + NTP_4_2_7P195 + + ntpsnmpd/ntpsnmpd-opts.c@1.197 +3 -3 + NTP_4_2_7P195 + + ntpsnmpd/ntpsnmpd-opts.h@1.197 +3 -3 + NTP_4_2_7P195 + + ntpsnmpd/ntpsnmpd-opts.texi@1.197 +2 -2 + NTP_4_2_7P195 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.11 +2 -2 + NTP_4_2_7P195 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.11 +1 -1 + NTP_4_2_7P195 + + ntpsnmpd/ntpsnmpd.man.in@1.11 +2 -2 + NTP_4_2_7P195 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.11 +1 -1 + NTP_4_2_7P195 + + packageinfo.sh@1.198 +1 -1 + NTP_4_2_7P195 + + scripts/ntp-wait-opts.texi@1.15 +1 -1 + NTP_4_2_7P195 + + scripts/ntp-wait.1ntp-waitman@1.11 +2 -2 + NTP_4_2_7P195 + + scripts/ntp-wait.1ntp-waitmdoc@1.11 +1 -1 + NTP_4_2_7P195 + + scripts/ntp-wait.html@1.15 +1 -1 + NTP_4_2_7P195 + + scripts/ntp-wait.man.in@1.11 +2 -2 + NTP_4_2_7P195 + + scripts/ntp-wait.mdoc.in@1.11 +1 -1 + NTP_4_2_7P195 + + sntp/sntp-opts.c@1.191 +3 -3 + NTP_4_2_7P195 + + sntp/sntp-opts.h@1.191 +3 -3 + NTP_4_2_7P195 + + sntp/sntp-opts.texi@1.191 +2 -2 + NTP_4_2_7P195 + + sntp/sntp.1sntpman@1.11 +2 -2 + NTP_4_2_7P195 + + sntp/sntp.1sntpmdoc@1.11 +1 -1 + NTP_4_2_7P195 + + sntp/sntp.html@1.191 +2 -2 + NTP_4_2_7P195 + + sntp/sntp.man.in@1.11 +2 -2 + NTP_4_2_7P195 + + sntp/sntp.mdoc.in@1.11 +1 -1 + NTP_4_2_7P195 + + util/ntp-keygen-opts.c@1.195 +3 -3 + NTP_4_2_7P195 + + util/ntp-keygen-opts.h@1.195 +3 -3 + NTP_4_2_7P195 + + util/ntp-keygen-opts.texi@1.198 +2 -2 + NTP_4_2_7P195 + + util/ntp-keygen.1ntp-keygenman@1.11 +2 -2 + NTP_4_2_7P195 + + util/ntp-keygen.1ntp-keygenmdoc@1.11 +1 -1 + NTP_4_2_7P195 + + util/ntp-keygen.man.in@1.11 +2 -2 + NTP_4_2_7P195 + + util/ntp-keygen.mdoc.in@1.11 +1 -1 + NTP_4_2_7P195 + +ChangeSet@1.2598.1.10, 2011-07-25 07:02:42+00:00, stenn@deacon.udel.edu + NTP_4_2_7P194 + TAG: NTP_4_2_7P194 + + ChangeLog@1.963.1.8 +1 -0 + NTP_4_2_7P194 + + ntpd/ntpd-opts.c@1.199 +3 -3 + NTP_4_2_7P194 + + ntpd/ntpd-opts.h@1.199 +3 -3 + NTP_4_2_7P194 + + ntpd/ntpd-opts.texi@1.197 +2 -2 + NTP_4_2_7P194 + + ntpd/ntpd.1ntpdman@1.10 +2 -2 + NTP_4_2_7P194 + + ntpd/ntpd.1ntpdmdoc@1.10 +2 -2 + NTP_4_2_7P194 + + ntpd/ntpd.man.in@1.10 +2 -2 + NTP_4_2_7P194 + + ntpd/ntpd.mdoc.in@1.10 +2 -2 + NTP_4_2_7P194 + + ntpdc/ntpdc-opts.c@1.194 +3 -3 + NTP_4_2_7P194 + + ntpdc/ntpdc-opts.h@1.194 +3 -3 + NTP_4_2_7P194 + + ntpdc/ntpdc-opts.texi@1.194 +2 -2 + NTP_4_2_7P194 + + ntpdc/ntpdc.1ntpdcman@1.10 +2 -2 + NTP_4_2_7P194 + + ntpdc/ntpdc.1ntpdcmdoc@1.10 +2 -2 + NTP_4_2_7P194 + + ntpdc/ntpdc.html@1.22 +2 -2 + NTP_4_2_7P194 + + ntpdc/ntpdc.man.in@1.10 +2 -2 + NTP_4_2_7P194 + + ntpdc/ntpdc.mdoc.in@1.10 +2 -2 + NTP_4_2_7P194 + + ntpq/ntpq-opts.c@1.196 +3 -3 + NTP_4_2_7P194 + + ntpq/ntpq-opts.h@1.196 +3 -3 + NTP_4_2_7P194 + + ntpq/ntpq-opts.texi@1.196 +2 -2 + NTP_4_2_7P194 + + ntpq/ntpq.1ntpqman@1.10 +2 -2 + NTP_4_2_7P194 + + ntpq/ntpq.1ntpqmdoc@1.10 +2 -2 + NTP_4_2_7P194 + + ntpq/ntpq.man.in@1.10 +2 -2 + NTP_4_2_7P194 + + ntpq/ntpq.mdoc.in@1.10 +2 -2 + NTP_4_2_7P194 + + ntpsnmpd/ntpsnmpd-opts.c@1.196 +3 -3 + NTP_4_2_7P194 + + ntpsnmpd/ntpsnmpd-opts.h@1.196 +3 -3 + NTP_4_2_7P194 + + ntpsnmpd/ntpsnmpd-opts.texi@1.196 +2 -2 + NTP_4_2_7P194 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.10 +2 -2 + NTP_4_2_7P194 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.10 +2 -2 + NTP_4_2_7P194 + + ntpsnmpd/ntpsnmpd.man.in@1.10 +2 -2 + NTP_4_2_7P194 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.10 +2 -2 + NTP_4_2_7P194 + + packageinfo.sh@1.197 +1 -1 + NTP_4_2_7P194 + + scripts/ntp-wait-opts.texi@1.14 +1 -1 + NTP_4_2_7P194 + + scripts/ntp-wait.1ntp-waitman@1.10 +2 -2 + NTP_4_2_7P194 + + scripts/ntp-wait.1ntp-waitmdoc@1.10 +2 -2 + NTP_4_2_7P194 + + scripts/ntp-wait.html@1.14 +1 -1 + NTP_4_2_7P194 + + scripts/ntp-wait.man.in@1.10 +2 -2 + NTP_4_2_7P194 + + scripts/ntp-wait.mdoc.in@1.10 +2 -2 + NTP_4_2_7P194 + + sntp/sntp-opts.c@1.190 +3 -3 + NTP_4_2_7P194 + + sntp/sntp-opts.h@1.190 +3 -3 + NTP_4_2_7P194 + + sntp/sntp-opts.texi@1.190 +2 -2 + NTP_4_2_7P194 + + sntp/sntp.1sntpman@1.10 +2 -2 + NTP_4_2_7P194 + + sntp/sntp.1sntpmdoc@1.10 +2 -2 + NTP_4_2_7P194 + + sntp/sntp.html@1.190 +2 -2 + NTP_4_2_7P194 + + sntp/sntp.man.in@1.10 +2 -2 + NTP_4_2_7P194 + + sntp/sntp.mdoc.in@1.10 +2 -2 + NTP_4_2_7P194 + + util/ntp-keygen-opts.c@1.194 +3 -3 + NTP_4_2_7P194 + + util/ntp-keygen-opts.h@1.194 +3 -3 + NTP_4_2_7P194 + + util/ntp-keygen-opts.texi@1.197 +2 -2 + NTP_4_2_7P194 + + util/ntp-keygen.1ntp-keygenman@1.10 +2 -2 + NTP_4_2_7P194 + + util/ntp-keygen.1ntp-keygenmdoc@1.10 +2 -2 + NTP_4_2_7P194 + + util/ntp-keygen.man.in@1.10 +2 -2 + NTP_4_2_7P194 + + util/ntp-keygen.mdoc.in@1.10 +2 -2 + NTP_4_2_7P194 + +ChangeSet@1.2598.1.9, 2011-07-25 02:23:52-04:00, stenn@deacon.udel.edu + Added loc/solaris + + ChangeLog@1.963.1.7 +1 -0 + Added loc/solaris + + loc/solaris@1.1 +14 -0 + BitKeeper file /deacon/backroom/ntp-dev/loc/solaris + + loc/solaris@1.0 +0 -0 + +ChangeSet@1.2598.1.8, 2011-07-25 02:21:49-04:00, stenn@deacon.udel.edu + Add support for installing programs and scripts to libexec + + ChangeLog@1.963.1.6 +1 -0 + Add support for installing programs and scripts to libexec + + adjtimed/Makefile.am@1.14 +1 -0 + Add support for installing programs and scripts to libexec + + configure.ac@1.531 +11 -0 + Add support for installing programs and scripts to libexec + + ntpd/Makefile.am@1.109 +1 -0 + Add support for installing programs and scripts to libexec + + ntpdate/Makefile.am@1.32 +1 -0 + Add support for installing programs and scripts to libexec + + ntpdc/Makefile.am@1.65 +1 -0 + Add support for installing programs and scripts to libexec + + ntpq/Makefile.am@1.61 +1 -0 + Add support for installing programs and scripts to libexec + + ntpsnmpd/Makefile.am@1.32 +1 -0 + Add support for installing programs and scripts to libexec + + scripts/Makefile.am@1.28 +1 -0 + Add support for installing programs and scripts to libexec + + scripts/genLocInfo@1.11 +13 -3 + Add support for installing programs and scripts to libexec + + sntp/Makefile.am@1.65 +1 -0 + Add support for installing programs and scripts to libexec + + sntp/configure.ac@1.64 +11 -2 + Add support for installing programs and scripts to libexec + + sntp/m4/ntp_locinfo.m4@1.10 +14 -1 + Add support for installing programs and scripts to libexec + + util/Makefile.am@1.64 +1 -0 + Add support for installing programs and scripts to libexec + +ChangeSet@1.2082.4.222, 2011-07-25 00:09:06-04:00, stenn@deacon.udel.edu + [Bug 1608] Parse Refclock driver should honor trusttime + + ChangeLog@1.496.26.156 +2 -1 + [Bug 1608] Parse Refclock driver should honor trusttime + + html/drivers/driver8.html@1.25.1.1 +9 -0 + [Bug 1608] Parse Refclock driver should honor trusttime + + ntpd/refclock_parse.c@1.52.1.2 +62 -13 + [Bug 1608] Parse Refclock driver should honor trusttime + +ChangeSet@1.2598.1.6, 2011-07-24 12:28:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P193 + TAG: NTP_4_2_7P193 + + ChangeLog@1.963.1.4 +1 -0 + NTP_4_2_7P193 + + ntpd/ntpd-opts.c@1.198 +3 -3 + NTP_4_2_7P193 + + ntpd/ntpd-opts.h@1.198 +3 -3 + NTP_4_2_7P193 + + ntpd/ntpd-opts.texi@1.196 +2 -2 + NTP_4_2_7P193 + + ntpd/ntpd.1ntpdman@1.9 +2 -2 + NTP_4_2_7P193 + + ntpd/ntpd.1ntpdmdoc@1.9 +2 -2 + NTP_4_2_7P193 + + ntpd/ntpd.man.in@1.9 +2 -2 + NTP_4_2_7P193 + + ntpd/ntpd.mdoc.in@1.9 +2 -2 + NTP_4_2_7P193 + + ntpdc/ntpdc-opts.c@1.193 +3 -3 + NTP_4_2_7P193 + + ntpdc/ntpdc-opts.h@1.193 +3 -3 + NTP_4_2_7P193 + + ntpdc/ntpdc-opts.texi@1.193 +2 -2 + NTP_4_2_7P193 + + ntpdc/ntpdc.1ntpdcman@1.9 +2 -2 + NTP_4_2_7P193 + + ntpdc/ntpdc.1ntpdcmdoc@1.9 +2 -2 + NTP_4_2_7P193 + + ntpdc/ntpdc.html@1.21 +2 -2 + NTP_4_2_7P193 + + ntpdc/ntpdc.man.in@1.9 +2 -2 + NTP_4_2_7P193 + + ntpdc/ntpdc.mdoc.in@1.9 +2 -2 + NTP_4_2_7P193 + + ntpq/ntpq-opts.c@1.195 +3 -3 + NTP_4_2_7P193 + + ntpq/ntpq-opts.h@1.195 +3 -3 + NTP_4_2_7P193 + + ntpq/ntpq-opts.texi@1.195 +2 -2 + NTP_4_2_7P193 + + ntpq/ntpq.1ntpqman@1.9 +2 -2 + NTP_4_2_7P193 + + ntpq/ntpq.1ntpqmdoc@1.9 +2 -2 + NTP_4_2_7P193 + + ntpq/ntpq.man.in@1.9 +2 -2 + NTP_4_2_7P193 + + ntpq/ntpq.mdoc.in@1.9 +2 -2 + NTP_4_2_7P193 + + ntpsnmpd/ntpsnmpd-opts.c@1.195 +3 -3 + NTP_4_2_7P193 + + ntpsnmpd/ntpsnmpd-opts.h@1.195 +3 -3 + NTP_4_2_7P193 + + ntpsnmpd/ntpsnmpd-opts.texi@1.195 +2 -2 + NTP_4_2_7P193 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.9 +2 -2 + NTP_4_2_7P193 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.9 +2 -2 + NTP_4_2_7P193 + + ntpsnmpd/ntpsnmpd.man.in@1.9 +2 -2 + NTP_4_2_7P193 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.9 +2 -2 + NTP_4_2_7P193 + + packageinfo.sh@1.196 +1 -1 + NTP_4_2_7P193 + + scripts/ntp-wait-opts.texi@1.13 +1 -1 + NTP_4_2_7P193 + + scripts/ntp-wait.1ntp-waitman@1.9 +2 -2 + NTP_4_2_7P193 + + scripts/ntp-wait.1ntp-waitmdoc@1.9 +2 -2 + NTP_4_2_7P193 + + scripts/ntp-wait.html@1.13 +1 -1 + NTP_4_2_7P193 + + scripts/ntp-wait.man.in@1.9 +2 -2 + NTP_4_2_7P193 + + scripts/ntp-wait.mdoc.in@1.9 +2 -2 + NTP_4_2_7P193 + + sntp/sntp-opts.c@1.189 +3 -3 + NTP_4_2_7P193 + + sntp/sntp-opts.h@1.189 +3 -3 + NTP_4_2_7P193 + + sntp/sntp-opts.texi@1.189 +2 -2 + NTP_4_2_7P193 + + sntp/sntp.1sntpman@1.9 +2 -2 + NTP_4_2_7P193 + + sntp/sntp.1sntpmdoc@1.9 +2 -2 + NTP_4_2_7P193 + + sntp/sntp.html@1.189 +2 -2 + NTP_4_2_7P193 + + sntp/sntp.man.in@1.9 +2 -2 + NTP_4_2_7P193 + + sntp/sntp.mdoc.in@1.9 +2 -2 + NTP_4_2_7P193 + + util/ntp-keygen-opts.c@1.193 +3 -3 + NTP_4_2_7P193 + + util/ntp-keygen-opts.h@1.193 +3 -3 + NTP_4_2_7P193 + + util/ntp-keygen-opts.texi@1.196 +2 -2 + NTP_4_2_7P193 + + util/ntp-keygen.1ntp-keygenman@1.9 +2 -2 + NTP_4_2_7P193 + + util/ntp-keygen.1ntp-keygenmdoc@1.9 +2 -2 + NTP_4_2_7P193 + + util/ntp-keygen.man.in@1.9 +2 -2 + NTP_4_2_7P193 + + util/ntp-keygen.mdoc.in@1.9 +2 -2 + NTP_4_2_7P193 + +ChangeSet@1.2598.1.5, 2011-07-24 01:41:56+00:00, davehart@shiny.ad.hartbrothers.com + Update libevent to 2.1 HEAD as of merge of 2.0.13-stable-dev. + (applies to prior cset) + Match addr_eqprefix() sizeof and memcpy destination to make it clear + to static analysis that there is no buffer overrun (CID 402). + + ChangeLog@1.963.1.3 +3 -0 + Update libevent to 2.1 HEAD as of merge of 2.0.13-stable-dev. + Match addr_eqprefix() sizeof and memcpy destination to make it clear + to static analysis that there is no buffer overrun (CID 402). + + + ntpd/ntp_io.c@1.358 +2 -4 + Match addr_eqprefix() sizeof and memcpy destination to make it clear + to static analysis that there is no buffer overrun (CID 402). + +ChangeSet@1.2461.1.7, 2011-07-24 00:59:52+00:00, davehart@shiny.ad.hartbrothers.com + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/ChangeLog@1.4 +28 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/Doxyfile@1.2 +31 -18 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/Makefile.am@1.1.1.4 +3 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/README@1.4 +2 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/buffer.c@1.5 +50 -19 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/buffer_iocp.c@1.3 +2 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/bufferevent_openssl.c@1.4 +2 -2 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/bufferevent_pair.c@1.4 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evdns.h@1.2 +10 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/event-internal.h@1.1.1.3 +3 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/event.c@1.1.1.4 +25 -7 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/event.h@1.3 +6 -127 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evhttp.h@1.2 +10 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evmap.c@1.4 +6 -3 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evrpc.h@1.2 +10 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evthread-internal.h@1.4 +18 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evthread.c@1.1.1.3 +90 -2 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evutil.c@1.1.1.3 +3 -3 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evutil.h@1.2 +8 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/evutil_rand.c@1.3 +16 -3 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/ht-internal.h@1.2 +1 -3 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/http.c@1.1.1.4 +21 -13 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/buffer.h@1.3 +153 -68 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/buffer_compat.h@1.2 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/bufferevent.h@1.2 +99 -37 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/bufferevent_compat.h@1.2 +4 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/bufferevent_ssl.h@1.2 +31 -2 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/bufferevent_struct.h@1.2 +4 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/dns.h@1.3 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/dns_compat.h@1.3 +2 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/dns_struct.h@1.2 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/event.h@1.1.1.3 +553 -151 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/event_compat.h@1.2 +48 -152 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/event_struct.h@1.2 +5 -3 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/http.h@1.3 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/http_compat.h@1.2 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/http_struct.h@1.2 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/rpc_compat.h@1.2 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/rpc_struct.h@1.2 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/tag.h@1.2 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/tag_compat.h@1.2 +11 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/thread.h@1.3 +36 -25 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/include/event2/util.h@1.3 +131 -33 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/kqueue.c@1.4 +46 -19 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/sample/Makefile.am@1.1.1.3 +1 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/select.c@1.1.1.3 +19 -9 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/signal.c@1.4 +9 -5 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/test/Makefile.am@1.1.1.3 +7 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/test/Makefile.nmake@1.3 +5 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/test/regress_buffer.c@1.4 +103 -1 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/test/regress_rpc.c@1.3 +9 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/test/regress_util.c@1.3 +18 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/test/test.sh@1.1.1.2 +18 -40 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/test/tinytest.c@1.3 +8 -3 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + + sntp/libevent/util-internal.h@1.1.1.3 +37 -0 + Update to libevent HEAD as of 20110723, 77a4d7f406be9d78876ba8a1b7c7d834d8998479 + Snapshot of libevent 2.1, as of 2.0.13-stable-dev release. + +ChangeSet@1.2598.1.3, 2011-07-20 20:12:25+00:00, davehart@shiny.ad.hartbrothers.com + slight ChangeLog cleanup (wrap after 72 chars, s/4.2.6p4/4.2.6p4-RC2/) + + ChangeLog@1.963.1.2 +2 -1 + slight ChangeLog cleanup (wrap after 72 chars, s/4.2.6p4/4.2.6p4-RC2/) + +ChangeSet@1.2082.4.221, 2011-07-20 19:37:50+00:00, davehart@shiny.ad.hartbrothers.com + Backport latest ntp_lists.h from ntp-dev, remove redundant () in + UNLINK_EXPR_SLIST(). + + include/ntp_lists.h@1.1.1.3 +213 -28 + Backport latest ntp_lists.h from ntp-dev, remove redundant () in + UNLINK_EXPR_SLIST(). + +ChangeSet@1.2082.4.220, 2011-07-20 13:06:51+02:00, karlsson@beam.lund.zozs.se + [BUG 1970] UNLINK_EXPR_SLIST() causes crash if list is empty. + + ChangeLog@1.496.26.155 +1 -0 + [BUG 1970] UNLINK_EXPR_SLIST() causes crash if list is empty. + + include/ntp_lists.h@1.1.1.2 +4 -3 + [BUG 1970] UNLINK_EXPR_SLIST() causes crash if list is empty. + +ChangeSet@1.2599, 2011-07-19 06:55:38-04:00, stenn@psp-deb1.ntp.org + Added loc/redhat + + ChangeLog@1.964 +1 -0 + Added loc/redhat + + loc/redhat@1.1 +15 -0 + BitKeeper file /home/stenn/ntp-dev/loc/redhat + + loc/redhat@1.0 +0 -0 + +ChangeSet@1.2598, 2011-07-18 11:53:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P192 + TAG: NTP_4_2_7P192 + + ChangeLog@1.963 +1 -0 + NTP_4_2_7P192 + + ntpd/ntpd-opts.c@1.197 +3 -3 + NTP_4_2_7P192 + + ntpd/ntpd-opts.h@1.197 +3 -3 + NTP_4_2_7P192 + + ntpd/ntpd-opts.texi@1.195 +2 -2 + NTP_4_2_7P192 + + ntpd/ntpd.1ntpdman@1.8 +2 -2 + NTP_4_2_7P192 + + ntpd/ntpd.1ntpdmdoc@1.8 +2 -2 + NTP_4_2_7P192 + + ntpd/ntpd.man.in@1.8 +2 -2 + NTP_4_2_7P192 + + ntpd/ntpd.mdoc.in@1.8 +2 -2 + NTP_4_2_7P192 + + ntpdc/ntpdc-opts.c@1.192 +3 -3 + NTP_4_2_7P192 + + ntpdc/ntpdc-opts.h@1.192 +3 -3 + NTP_4_2_7P192 + + ntpdc/ntpdc-opts.texi@1.192 +2 -2 + NTP_4_2_7P192 + + ntpdc/ntpdc.1ntpdcman@1.8 +2 -2 + NTP_4_2_7P192 + + ntpdc/ntpdc.1ntpdcmdoc@1.8 +2 -2 + NTP_4_2_7P192 + + ntpdc/ntpdc.html@1.20 +2 -2 + NTP_4_2_7P192 + + ntpdc/ntpdc.man.in@1.8 +2 -2 + NTP_4_2_7P192 + + ntpdc/ntpdc.mdoc.in@1.8 +2 -2 + NTP_4_2_7P192 + + ntpq/ntpq-opts.c@1.194 +3 -3 + NTP_4_2_7P192 + + ntpq/ntpq-opts.h@1.194 +3 -3 + NTP_4_2_7P192 + + ntpq/ntpq-opts.texi@1.194 +2 -2 + NTP_4_2_7P192 + + ntpq/ntpq.1ntpqman@1.8 +2 -2 + NTP_4_2_7P192 + + ntpq/ntpq.1ntpqmdoc@1.8 +2 -2 + NTP_4_2_7P192 + + ntpq/ntpq.man.in@1.8 +2 -2 + NTP_4_2_7P192 + + ntpq/ntpq.mdoc.in@1.8 +2 -2 + NTP_4_2_7P192 + + ntpsnmpd/ntpsnmpd-opts.c@1.194 +3 -3 + NTP_4_2_7P192 + + ntpsnmpd/ntpsnmpd-opts.h@1.194 +3 -3 + NTP_4_2_7P192 + + ntpsnmpd/ntpsnmpd-opts.texi@1.194 +2 -2 + NTP_4_2_7P192 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.8 +2 -2 + NTP_4_2_7P192 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.8 +2 -2 + NTP_4_2_7P192 + + ntpsnmpd/ntpsnmpd.man.in@1.8 +2 -2 + NTP_4_2_7P192 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.8 +2 -2 + NTP_4_2_7P192 + + packageinfo.sh@1.195 +1 -1 + NTP_4_2_7P192 + + scripts/ntp-wait-opts.texi@1.12 +1 -1 + NTP_4_2_7P192 + + scripts/ntp-wait.1ntp-waitman@1.8 +2 -2 + NTP_4_2_7P192 + + scripts/ntp-wait.1ntp-waitmdoc@1.8 +2 -2 + NTP_4_2_7P192 + + scripts/ntp-wait.html@1.12 +1 -1 + NTP_4_2_7P192 + + scripts/ntp-wait.man.in@1.8 +2 -2 + NTP_4_2_7P192 + + scripts/ntp-wait.mdoc.in@1.8 +2 -2 + NTP_4_2_7P192 + + sntp/sntp-opts.c@1.188 +3 -3 + NTP_4_2_7P192 + + sntp/sntp-opts.h@1.188 +3 -3 + NTP_4_2_7P192 + + sntp/sntp-opts.texi@1.188 +2 -2 + NTP_4_2_7P192 + + sntp/sntp.1sntpman@1.8 +2 -2 + NTP_4_2_7P192 + + sntp/sntp.1sntpmdoc@1.8 +2 -2 + NTP_4_2_7P192 + + sntp/sntp.html@1.188 +2 -2 + NTP_4_2_7P192 + + sntp/sntp.man.in@1.8 +2 -2 + NTP_4_2_7P192 + + sntp/sntp.mdoc.in@1.8 +2 -2 + NTP_4_2_7P192 + + util/ntp-keygen-opts.c@1.192 +3 -3 + NTP_4_2_7P192 + + util/ntp-keygen-opts.h@1.192 +3 -3 + NTP_4_2_7P192 + + util/ntp-keygen-opts.texi@1.195 +2 -2 + NTP_4_2_7P192 + + util/ntp-keygen.1ntp-keygenman@1.8 +2 -2 + NTP_4_2_7P192 + + util/ntp-keygen.1ntp-keygenmdoc@1.8 +2 -2 + NTP_4_2_7P192 + + util/ntp-keygen.man.in@1.8 +2 -2 + NTP_4_2_7P192 + + util/ntp-keygen.mdoc.in@1.8 +2 -2 + NTP_4_2_7P192 + +ChangeSet@1.2597, 2011-07-17 19:09:30-04:00, stenn@deacon.udel.edu + [Bug 1966] Broken FILES section for ntp.keys.def + + ChangeLog@1.962 +1 -0 + [Bug 1966] Broken FILES section for ntp.keys.def + + ntpd/ntp.keys.def@1.2 +4 -0 + [Bug 1966] Broken FILES section for ntp.keys.def + +ChangeSet@1.2596, 2011-07-17 06:51:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P191 + TAG: NTP_4_2_7P191 + + ChangeLog@1.961 +1 -0 + NTP_4_2_7P191 + + ntpd/ntpd-opts.c@1.196 +3 -3 + NTP_4_2_7P191 + + ntpd/ntpd-opts.h@1.196 +3 -3 + NTP_4_2_7P191 + + ntpd/ntpd-opts.texi@1.194 +2 -2 + NTP_4_2_7P191 + + ntpd/ntpd.1ntpdman@1.7 +2 -2 + NTP_4_2_7P191 + + ntpd/ntpd.1ntpdmdoc@1.7 +2 -2 + NTP_4_2_7P191 + + ntpd/ntpd.man.in@1.7 +2 -2 + NTP_4_2_7P191 + + ntpd/ntpd.mdoc.in@1.7 +2 -2 + NTP_4_2_7P191 + + ntpdc/ntpdc-opts.c@1.191 +3 -3 + NTP_4_2_7P191 + + ntpdc/ntpdc-opts.h@1.191 +3 -3 + NTP_4_2_7P191 + + ntpdc/ntpdc-opts.texi@1.191 +2 -2 + NTP_4_2_7P191 + + ntpdc/ntpdc.1ntpdcman@1.7 +2 -2 + NTP_4_2_7P191 + + ntpdc/ntpdc.1ntpdcmdoc@1.7 +2 -2 + NTP_4_2_7P191 + + ntpdc/ntpdc.html@1.19 +2 -2 + NTP_4_2_7P191 + + ntpdc/ntpdc.man.in@1.7 +2 -2 + NTP_4_2_7P191 + + ntpdc/ntpdc.mdoc.in@1.7 +2 -2 + NTP_4_2_7P191 + + ntpq/ntpq-opts.c@1.193 +3 -3 + NTP_4_2_7P191 + + ntpq/ntpq-opts.h@1.193 +3 -3 + NTP_4_2_7P191 + + ntpq/ntpq-opts.texi@1.193 +2 -2 + NTP_4_2_7P191 + + ntpq/ntpq.1ntpqman@1.7 +2 -2 + NTP_4_2_7P191 + + ntpq/ntpq.1ntpqmdoc@1.7 +2 -2 + NTP_4_2_7P191 + + ntpq/ntpq.man.in@1.7 +2 -2 + NTP_4_2_7P191 + + ntpq/ntpq.mdoc.in@1.7 +2 -2 + NTP_4_2_7P191 + + ntpsnmpd/ntpsnmpd-opts.c@1.193 +3 -3 + NTP_4_2_7P191 + + ntpsnmpd/ntpsnmpd-opts.h@1.193 +3 -3 + NTP_4_2_7P191 + + ntpsnmpd/ntpsnmpd-opts.texi@1.193 +2 -2 + NTP_4_2_7P191 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.7 +2 -2 + NTP_4_2_7P191 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.7 +2 -2 + NTP_4_2_7P191 + + ntpsnmpd/ntpsnmpd.man.in@1.7 +2 -2 + NTP_4_2_7P191 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.7 +2 -2 + NTP_4_2_7P191 + + packageinfo.sh@1.194 +1 -1 + NTP_4_2_7P191 + + scripts/ntp-wait-opts.texi@1.11 +1 -1 + NTP_4_2_7P191 + + scripts/ntp-wait.1ntp-waitman@1.7 +2 -2 + NTP_4_2_7P191 + + scripts/ntp-wait.1ntp-waitmdoc@1.7 +2 -2 + NTP_4_2_7P191 + + scripts/ntp-wait.html@1.11 +1 -1 + NTP_4_2_7P191 + + scripts/ntp-wait.man.in@1.7 +2 -2 + NTP_4_2_7P191 + + scripts/ntp-wait.mdoc.in@1.7 +2 -2 + NTP_4_2_7P191 + + sntp/sntp-opts.c@1.187 +3 -3 + NTP_4_2_7P191 + + sntp/sntp-opts.h@1.187 +3 -3 + NTP_4_2_7P191 + + sntp/sntp-opts.texi@1.187 +2 -2 + NTP_4_2_7P191 + + sntp/sntp.1sntpman@1.7 +2 -2 + NTP_4_2_7P191 + + sntp/sntp.1sntpmdoc@1.7 +2 -2 + NTP_4_2_7P191 + + sntp/sntp.html@1.187 +2 -2 + NTP_4_2_7P191 + + sntp/sntp.man.in@1.7 +2 -2 + NTP_4_2_7P191 + + sntp/sntp.mdoc.in@1.7 +2 -2 + NTP_4_2_7P191 + + util/ntp-keygen-opts.c@1.191 +3 -3 + NTP_4_2_7P191 + + util/ntp-keygen-opts.h@1.191 +3 -3 + NTP_4_2_7P191 + + util/ntp-keygen-opts.texi@1.194 +2 -2 + NTP_4_2_7P191 + + util/ntp-keygen.1ntp-keygenman@1.7 +2 -2 + NTP_4_2_7P191 + + util/ntp-keygen.1ntp-keygenmdoc@1.7 +2 -2 + NTP_4_2_7P191 + + util/ntp-keygen.man.in@1.7 +2 -2 + NTP_4_2_7P191 + + util/ntp-keygen.mdoc.in@1.7 +2 -2 + NTP_4_2_7P191 + +ChangeSet@1.2593.1.2, 2011-07-16 18:00:11-04:00, stenn@deacon.udel.edu + [Bug 1948] Update man page section layout + + ChangeLog@1.958.1.2 +1 -0 + [Bug 1948] Update man page section layout + + scripts/html2man.in@1.7 +12 -12 + [Bug 1948] Update man page section layout + +ChangeSet@1.2593.1.1, 2011-07-16 17:07:59-04:00, stenn@psp-deb1.ntp.org + [Bug 1964] --without-sntp should not build sntp + + ChangeLog@1.958.1.1 +1 -0 + [Bug 1964] --without-sntp should not build sntp + + sntp/configure.ac@1.63 +4 -4 + [Bug 1964] --without-sntp should not build sntp + +ChangeSet@1.2594, 2011-07-16 15:26:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ChangeLog@1.959 +1 -0 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + include/ntp_config.h@1.73 +1 -0 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + include/ntp_request.h@1.44 +9 -3 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + include/ntpd.h@1.164 +1 -0 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ntpd/complete.conf@1.16 +1 -0 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ntpd/keyword-gen-utd@1.13 +1 -1 + keyword-gen.c output + + ntpd/keyword-gen.c@1.19 +7 -0 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ntpd/ntp_config.c@1.291 +77 -2 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ntpd/ntp_keyword.h@1.15 +971 -951 + keyword-gen.c output + + ntpd/ntp_parser.c@1.75 +1029 -969 + ntp_parser.y output + + ntpd/ntp_parser.h@1.42 +353 -339 + ntp_parser.y output + + ntpd/ntp_parser.y@1.69 +40 -0 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ntpd/ntp_request.c@1.105 +1 -2 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ntpdc/ntpdc_ops.c@1.78 +9 -8 + [Bug 1963] add reset command for ntpq :config, similar to ntpdc's + + ntpq/ntpq.c@1.139 +1 -1 + Silence signed/unsigned comparison warning from VC++ 2008. + +ChangeSet@1.2593, 2011-07-13 09:55:12+00:00, stenn@deacon.udel.edu + NTP_4_2_7P190 + TAG: NTP_4_2_7P190 + + ChangeLog@1.958 +1 -0 + NTP_4_2_7P190 + + ntpd/ntpd-opts.c@1.195 +3 -3 + NTP_4_2_7P190 + + ntpd/ntpd-opts.h@1.195 +3 -3 + NTP_4_2_7P190 + + ntpd/ntpd-opts.texi@1.193 +2 -2 + NTP_4_2_7P190 + + ntpd/ntpd.1ntpdman@1.6 +2 -2 + NTP_4_2_7P190 + + ntpd/ntpd.1ntpdmdoc@1.6 +2 -2 + NTP_4_2_7P190 + + ntpd/ntpd.man.in@1.6 +2 -2 + NTP_4_2_7P190 + + ntpd/ntpd.mdoc.in@1.6 +2 -2 + NTP_4_2_7P190 + + ntpdc/ntpdc-opts.c@1.190 +3 -3 + NTP_4_2_7P190 + + ntpdc/ntpdc-opts.h@1.190 +3 -3 + NTP_4_2_7P190 + + ntpdc/ntpdc-opts.texi@1.190 +2 -2 + NTP_4_2_7P190 + + ntpdc/ntpdc.1ntpdcman@1.6 +2 -2 + NTP_4_2_7P190 + + ntpdc/ntpdc.1ntpdcmdoc@1.6 +2 -2 + NTP_4_2_7P190 + + ntpdc/ntpdc.html@1.18 +2 -2 + NTP_4_2_7P190 + + ntpdc/ntpdc.man.in@1.6 +2 -2 + NTP_4_2_7P190 + + ntpdc/ntpdc.mdoc.in@1.6 +2 -2 + NTP_4_2_7P190 + + ntpq/ntpq-opts.c@1.192 +3 -3 + NTP_4_2_7P190 + + ntpq/ntpq-opts.h@1.192 +3 -3 + NTP_4_2_7P190 + + ntpq/ntpq-opts.texi@1.192 +2 -2 + NTP_4_2_7P190 + + ntpq/ntpq.1ntpqman@1.6 +2 -2 + NTP_4_2_7P190 + + ntpq/ntpq.1ntpqmdoc@1.6 +2 -2 + NTP_4_2_7P190 + + ntpq/ntpq.man.in@1.6 +2 -2 + NTP_4_2_7P190 + + ntpq/ntpq.mdoc.in@1.6 +2 -2 + NTP_4_2_7P190 + + ntpsnmpd/ntpsnmpd-opts.c@1.192 +3 -3 + NTP_4_2_7P190 + + ntpsnmpd/ntpsnmpd-opts.h@1.192 +3 -3 + NTP_4_2_7P190 + + ntpsnmpd/ntpsnmpd-opts.texi@1.192 +2 -2 + NTP_4_2_7P190 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.6 +2 -2 + NTP_4_2_7P190 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.6 +2 -2 + NTP_4_2_7P190 + + ntpsnmpd/ntpsnmpd.man.in@1.6 +2 -2 + NTP_4_2_7P190 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.6 +2 -2 + NTP_4_2_7P190 + + packageinfo.sh@1.193 +1 -1 + NTP_4_2_7P190 + + scripts/ntp-wait-opts.texi@1.10 +1 -1 + NTP_4_2_7P190 + + scripts/ntp-wait.1ntp-waitman@1.6 +2 -2 + NTP_4_2_7P190 + + scripts/ntp-wait.1ntp-waitmdoc@1.6 +2 -2 + NTP_4_2_7P190 + + scripts/ntp-wait.html@1.10 +1 -1 + NTP_4_2_7P190 + + scripts/ntp-wait.man.in@1.6 +2 -2 + NTP_4_2_7P190 + + scripts/ntp-wait.mdoc.in@1.6 +2 -2 + NTP_4_2_7P190 + + sntp/sntp-opts.c@1.186 +3 -3 + NTP_4_2_7P190 + + sntp/sntp-opts.h@1.186 +3 -3 + NTP_4_2_7P190 + + sntp/sntp-opts.texi@1.186 +2 -2 + NTP_4_2_7P190 + + sntp/sntp.1sntpman@1.6 +2 -2 + NTP_4_2_7P190 + + sntp/sntp.1sntpmdoc@1.6 +2 -2 + NTP_4_2_7P190 + + sntp/sntp.html@1.186 +2 -2 + NTP_4_2_7P190 + + sntp/sntp.man.in@1.6 +2 -2 + NTP_4_2_7P190 + + sntp/sntp.mdoc.in@1.6 +2 -2 + NTP_4_2_7P190 + + util/ntp-keygen-opts.c@1.190 +3 -3 + NTP_4_2_7P190 + + util/ntp-keygen-opts.h@1.190 +3 -3 + NTP_4_2_7P190 + + util/ntp-keygen-opts.texi@1.193 +2 -2 + NTP_4_2_7P190 + + util/ntp-keygen.1ntp-keygenman@1.6 +2 -2 + NTP_4_2_7P190 + + util/ntp-keygen.1ntp-keygenmdoc@1.6 +2 -2 + NTP_4_2_7P190 + + util/ntp-keygen.man.in@1.6 +2 -2 + NTP_4_2_7P190 + + util/ntp-keygen.mdoc.in@1.6 +2 -2 + NTP_4_2_7P190 + +ChangeSet@1.2592, 2011-07-12 22:11:22-04:00, stenn@deacon.udel.edu + Require autogen-5.12 + + ChangeLog@1.957 +2 -0 + Require autogen-5.12 + + sntp/include/autogen-version.def@1.8 +1 -1 + Require autogen-5.12 + +ChangeSet@1.2082.4.219, 2011-07-12 21:46:20-04:00, stenn@psp-deb1.ntp.org + [Bug 1961] html2man update: distribute ntp-wait.html + + ChangeLog@1.496.26.154 +4 -0 + [Bug 1961] html2man update: distribute ntp-wait.html + + html/ntp-wait.html@1.1 +30 -0 + BitKeeper file /home/stenn/ntp-stable/html/ntp-wait.html + + html/ntp-wait.html@1.0 +0 -0 + +ChangeSet@1.2590, 2011-07-11 06:29:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P189 + TAG: NTP_4_2_7P189 + + ChangeLog@1.955 +1 -0 + NTP_4_2_7P189 + + ntpd/ntpd-opts.c@1.194 +3 -3 + NTP_4_2_7P189 + + ntpd/ntpd-opts.h@1.194 +3 -3 + NTP_4_2_7P189 + + ntpd/ntpd-opts.texi@1.192 +2 -2 + NTP_4_2_7P189 + + ntpd/ntpd.1ntpdman@1.5 +4 -5 + NTP_4_2_7P189 + + ntpd/ntpd.1ntpdmdoc@1.5 +4 -5 + NTP_4_2_7P189 + + ntpd/ntpd.man.in@1.5 +4 -5 + NTP_4_2_7P189 + + ntpd/ntpd.mdoc.in@1.5 +4 -5 + NTP_4_2_7P189 + + ntpdc/ntpdc-opts.c@1.189 +3 -3 + NTP_4_2_7P189 + + ntpdc/ntpdc-opts.h@1.189 +3 -3 + NTP_4_2_7P189 + + ntpdc/ntpdc-opts.texi@1.189 +2 -2 + NTP_4_2_7P189 + + ntpdc/ntpdc.1ntpdcman@1.5 +2 -2 + NTP_4_2_7P189 + + ntpdc/ntpdc.1ntpdcmdoc@1.5 +3 -3 + NTP_4_2_7P189 + + ntpdc/ntpdc.html@1.17 +2 -2 + NTP_4_2_7P189 + + ntpdc/ntpdc.man.in@1.5 +2 -2 + NTP_4_2_7P189 + + ntpdc/ntpdc.mdoc.in@1.5 +3 -3 + NTP_4_2_7P189 + + ntpq/ntpq-opts.c@1.191 +3 -3 + NTP_4_2_7P189 + + ntpq/ntpq-opts.h@1.191 +3 -3 + NTP_4_2_7P189 + + ntpq/ntpq-opts.texi@1.191 +2 -2 + NTP_4_2_7P189 + + ntpq/ntpq.1ntpqman@1.5 +2 -2 + NTP_4_2_7P189 + + ntpq/ntpq.1ntpqmdoc@1.5 +2 -2 + NTP_4_2_7P189 + + ntpq/ntpq.man.in@1.5 +2 -2 + NTP_4_2_7P189 + + ntpq/ntpq.mdoc.in@1.5 +2 -2 + NTP_4_2_7P189 + + ntpsnmpd/ntpsnmpd-opts.c@1.191 +3 -3 + NTP_4_2_7P189 + + ntpsnmpd/ntpsnmpd-opts.h@1.191 +3 -3 + NTP_4_2_7P189 + + ntpsnmpd/ntpsnmpd-opts.texi@1.191 +2 -2 + NTP_4_2_7P189 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.5 +2 -2 + NTP_4_2_7P189 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.5 +2 -2 + NTP_4_2_7P189 + + ntpsnmpd/ntpsnmpd.man.in@1.5 +2 -2 + NTP_4_2_7P189 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.5 +2 -2 + NTP_4_2_7P189 + + packageinfo.sh@1.192 +1 -1 + NTP_4_2_7P189 + + scripts/ntp-wait-opts.texi@1.9 +1 -1 + NTP_4_2_7P189 + + scripts/ntp-wait.1ntp-waitman@1.5 +2 -2 + NTP_4_2_7P189 + + scripts/ntp-wait.1ntp-waitmdoc@1.5 +2 -2 + NTP_4_2_7P189 + + scripts/ntp-wait.html@1.9 +1 -1 + NTP_4_2_7P189 + + scripts/ntp-wait.man.in@1.5 +2 -2 + NTP_4_2_7P189 + + scripts/ntp-wait.mdoc.in@1.5 +2 -2 + NTP_4_2_7P189 + + sntp/sntp-opts.c@1.185 +3 -3 + NTP_4_2_7P189 + + sntp/sntp-opts.h@1.185 +3 -3 + NTP_4_2_7P189 + + sntp/sntp-opts.texi@1.185 +2 -2 + NTP_4_2_7P189 + + sntp/sntp.1sntpman@1.5 +3 -3 + NTP_4_2_7P189 + + sntp/sntp.1sntpmdoc@1.5 +3 -3 + NTP_4_2_7P189 + + sntp/sntp.html@1.185 +2 -2 + NTP_4_2_7P189 + + sntp/sntp.man.in@1.5 +3 -3 + NTP_4_2_7P189 + + sntp/sntp.mdoc.in@1.5 +3 -3 + NTP_4_2_7P189 + + util/ntp-keygen-opts.c@1.189 +3 -3 + NTP_4_2_7P189 + + util/ntp-keygen-opts.h@1.189 +3 -3 + NTP_4_2_7P189 + + util/ntp-keygen-opts.texi@1.192 +2 -2 + NTP_4_2_7P189 + + util/ntp-keygen.1ntp-keygenman@1.5 +4 -5 + NTP_4_2_7P189 + + util/ntp-keygen.1ntp-keygenmdoc@1.5 +4 -5 + NTP_4_2_7P189 + + util/ntp-keygen.man.in@1.5 +4 -5 + NTP_4_2_7P189 + + util/ntp-keygen.mdoc.in@1.5 +4 -5 + NTP_4_2_7P189 + +ChangeSet@1.2082.4.218, 2011-07-10 23:03:48-04:00, stenn@deacon.udel.edu + NTP_4_2_6P4_RC1 + TAG: NTP_4_2_6P4_RC1 + + ChangeLog@1.496.26.153 +1 -0 + NTP_4_2_6P4_RC1 + + ntpd/ntpd-opts.c@1.248.37.1 +7 -9 + NTP_4_2_6P4_RC1 + + ntpd/ntpd-opts.h@1.248.37.1 +9 -11 + NTP_4_2_6P4_RC1 + + ntpd/ntpd-opts.texi@1.246.36.1 +3 -3 + NTP_4_2_6P4_RC1 + + ntpd/ntpd.1@1.246.36.1 +2 -2 + NTP_4_2_6P4_RC1 + + ntpdc/ntpdc-opts.c@1.244.37.1 +7 -9 + NTP_4_2_6P4_RC1 + + ntpdc/ntpdc-opts.h@1.244.37.1 +9 -11 + NTP_4_2_6P4_RC1 + + ntpdc/ntpdc-opts.texi@1.243.36.1 +3 -3 + NTP_4_2_6P4_RC1 + + ntpdc/ntpdc.1@1.243.36.1 +2 -2 + NTP_4_2_6P4_RC1 + + ntpq/ntpq-opts.c@1.245.37.1 +7 -9 + NTP_4_2_6P4_RC1 + + ntpq/ntpq-opts.h@1.245.37.1 +9 -11 + NTP_4_2_6P4_RC1 + + ntpq/ntpq-opts.texi@1.244.36.1 +3 -3 + NTP_4_2_6P4_RC1 + + ntpq/ntpq.1@1.244.36.1 +2 -2 + NTP_4_2_6P4_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.38.1 +7 -9 + NTP_4_2_6P4_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.38.1 +9 -11 + NTP_4_2_6P4_RC1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.37.1 +3 -3 + NTP_4_2_6P4_RC1 + + ntpsnmpd/ntpsnmpd.1@1.122.37.1 +2 -2 + NTP_4_2_6P4_RC1 + + packageinfo.sh@1.255.34.2 +1 -1 + NTP_4_2_6P4_RC1 + + sntp/sntp-opts.c@1.117.35.1 +7 -9 + NTP_4_2_6P4_RC1 + + sntp/sntp-opts.h@1.117.35.1 +9 -11 + NTP_4_2_6P4_RC1 + + sntp/sntp-opts.texi@1.117.34.1 +3 -3 + NTP_4_2_6P4_RC1 + + sntp/sntp.1@1.117.34.1 +2 -2 + NTP_4_2_6P4_RC1 + + sntp/sntp.html@1.7.35.1 +3 -3 + NTP_4_2_6P4_RC1 + + util/ntp-keygen-opts.c@1.247.37.1 +7 -9 + NTP_4_2_6P4_RC1 + + util/ntp-keygen-opts.h@1.247.37.1 +9 -11 + NTP_4_2_6P4_RC1 + + util/ntp-keygen-opts.texi@1.246.36.1 +3 -3 + NTP_4_2_6P4_RC1 + + util/ntp-keygen.1@1.246.36.1 +2 -2 + NTP_4_2_6P4_RC1 + +ChangeSet@1.2082.4.217, 2011-07-10 22:14:53-04:00, stenn@deacon.udel.edu + 4.2.6p4-RC1 + + packageinfo.sh@1.255.34.1 +1 -1 + 4.2.6p4-RC1 + +ChangeSet@1.2082.4.216, 2011-07-10 17:51:34-04:00, stenn@deacon.udel.edu + Update the NEWS file + + ChangeLog@1.496.26.152 +1 -0 + Update the NEWS file + + NEWS@1.118 +39 -0 + Update the NEWS file + +ChangeSet@1.2082.4.215, 2011-07-10 08:02:44-04:00, stenn@psp-deb1.ntp.org + [Bug 1961] html2man needs an update + + ChangeLog@1.496.26.151 +1 -0 + [Bug 1961] html2man needs an update + + html/authopt.html@1.60.1.1 +1 -5 + [Bug 1961] html2man needs an update + + html/keygen.html@1.19.1.1 +1 -0 + [Bug 1961] html2man needs an update + + html/ntpd.html@1.51.1.1 +12 -4 + [Bug 1961] html2man needs an update + + html/ntpdate.html@1.18.1.1 +6 -6 + [Bug 1961] html2man needs an update + + html/ntpdc.html@1.30.1.1 +10 -8 + [Bug 1961] html2man needs an update + + html/ntpq.html@1.36.1.2 +2 -2 + [Bug 1961] html2man needs an update + + html/ntptrace.html@1.14.1.1 +2 -10 + [Bug 1961] html2man needs an update + + html/tickadj.html@1.15.1.1 +3 -1 + [Bug 1961] html2man needs an update + + scripts/html2man.in@1.6 +99 -37 + [Bug 1961] html2man needs an update + +ChangeSet@1.2082.4.214, 2011-07-10 07:34:24-04:00, stenn@deacon.udel.edu + [Bug 1790] Update config.guess and config.sub to detect AIX6 + + ChangeLog@1.496.26.150 +1 -0 + [Bug 1790] Update config.guess and config.sub to detect AIX6 + +ChangeSet@1.2082.4.213, 2011-07-05 03:39:02-04:00, stenn@psp-deb1.ntp.org + [Bug 1134] ntpd fails binding to tentative IPv6 addresses + + ChangeLog@1.496.26.149 +4 -0 + [Bug 1134] ntpd fails binding to tentative IPv6 addresses + + lib/isc/unix/interfaceiter.c@1.19.1.1 +11 -0 + [Bug 1134] ntpd fails binding to tentative IPv6 addresses + +ChangeSet@1.2587, 2011-06-28 07:07:51+00:00, stenn@deacon.udel.edu + NTP_4_2_7P188 + TAG: NTP_4_2_7P188 + + ChangeLog@1.952 +1 -0 + NTP_4_2_7P188 + + ntpd/ntpd-opts.c@1.193 +3 -3 + NTP_4_2_7P188 + + ntpd/ntpd-opts.h@1.193 +3 -3 + NTP_4_2_7P188 + + ntpd/ntpd-opts.texi@1.191 +2 -2 + NTP_4_2_7P188 + + ntpd/ntpd.1ntpdman@1.4 +2 -2 + NTP_4_2_7P188 + + ntpd/ntpd.1ntpdmdoc@1.4 +2 -2 + NTP_4_2_7P188 + + ntpd/ntpd.man.in@1.4 +2 -2 + NTP_4_2_7P188 + + ntpd/ntpd.mdoc.in@1.4 +2 -2 + NTP_4_2_7P188 + + ntpdc/ntpdc-opts.c@1.188 +3 -3 + NTP_4_2_7P188 + + ntpdc/ntpdc-opts.h@1.188 +3 -3 + NTP_4_2_7P188 + + ntpdc/ntpdc-opts.texi@1.188 +2 -2 + NTP_4_2_7P188 + + ntpdc/ntpdc.1ntpdcman@1.4 +2 -2 + NTP_4_2_7P188 + + ntpdc/ntpdc.1ntpdcmdoc@1.4 +2 -2 + NTP_4_2_7P188 + + ntpdc/ntpdc.html@1.16 +2 -2 + NTP_4_2_7P188 + + ntpdc/ntpdc.man.in@1.4 +2 -2 + NTP_4_2_7P188 + + ntpdc/ntpdc.mdoc.in@1.4 +2 -2 + NTP_4_2_7P188 + + ntpq/ntpq-opts.c@1.190 +3 -3 + NTP_4_2_7P188 + + ntpq/ntpq-opts.h@1.190 +3 -3 + NTP_4_2_7P188 + + ntpq/ntpq-opts.texi@1.190 +2 -2 + NTP_4_2_7P188 + + ntpq/ntpq.1ntpqman@1.4 +2 -2 + NTP_4_2_7P188 + + ntpq/ntpq.1ntpqmdoc@1.4 +2 -2 + NTP_4_2_7P188 + + ntpq/ntpq.man.in@1.4 +2 -2 + NTP_4_2_7P188 + + ntpq/ntpq.mdoc.in@1.4 +2 -2 + NTP_4_2_7P188 + + ntpsnmpd/ntpsnmpd-opts.c@1.190 +3 -3 + NTP_4_2_7P188 + + ntpsnmpd/ntpsnmpd-opts.h@1.190 +3 -3 + NTP_4_2_7P188 + + ntpsnmpd/ntpsnmpd-opts.texi@1.190 +2 -2 + NTP_4_2_7P188 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.4 +2 -2 + NTP_4_2_7P188 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.4 +2 -2 + NTP_4_2_7P188 + + ntpsnmpd/ntpsnmpd.man.in@1.4 +2 -2 + NTP_4_2_7P188 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.4 +2 -2 + NTP_4_2_7P188 + + packageinfo.sh@1.191 +1 -1 + NTP_4_2_7P188 + + scripts/ntp-wait-opts.texi@1.8 +14 -2 + NTP_4_2_7P188 + + scripts/ntp-wait.1ntp-waitman@1.4 +2 -2 + NTP_4_2_7P188 + + scripts/ntp-wait.1ntp-waitmdoc@1.4 +2 -2 + NTP_4_2_7P188 + + scripts/ntp-wait.html@1.8 +14 -2 + NTP_4_2_7P188 + + scripts/ntp-wait.man.in@1.4 +2 -2 + NTP_4_2_7P188 + + scripts/ntp-wait.mdoc.in@1.4 +2 -2 + NTP_4_2_7P188 + + sntp/sntp-opts.c@1.184 +3 -3 + NTP_4_2_7P188 + + sntp/sntp-opts.h@1.184 +3 -3 + NTP_4_2_7P188 + + sntp/sntp-opts.texi@1.184 +2 -2 + NTP_4_2_7P188 + + sntp/sntp.1sntpman@1.4 +2 -2 + NTP_4_2_7P188 + + sntp/sntp.1sntpmdoc@1.4 +2 -2 + NTP_4_2_7P188 + + sntp/sntp.html@1.184 +2 -2 + NTP_4_2_7P188 + + sntp/sntp.man.in@1.4 +2 -2 + NTP_4_2_7P188 + + sntp/sntp.mdoc.in@1.4 +2 -2 + NTP_4_2_7P188 + + util/ntp-keygen-opts.c@1.188 +3 -3 + NTP_4_2_7P188 + + util/ntp-keygen-opts.h@1.188 +3 -3 + NTP_4_2_7P188 + + util/ntp-keygen-opts.texi@1.191 +2 -2 + NTP_4_2_7P188 + + util/ntp-keygen.1ntp-keygenman@1.4 +2 -2 + NTP_4_2_7P188 + + util/ntp-keygen.1ntp-keygenmdoc@1.4 +2 -2 + NTP_4_2_7P188 + + util/ntp-keygen.man.in@1.4 +2 -2 + NTP_4_2_7P188 + + util/ntp-keygen.mdoc.in@1.4 +2 -2 + NTP_4_2_7P188 + +ChangeSet@1.2586, 2011-06-27 22:31:27-07:00, harlan@hms-mbp.local + ntp-wait: some versions of ntpd spell "associd" differently + + ChangeLog@1.951 +1 -0 + ntp-wait: some versions of ntpd spell "associd" differently + + scripts/ntp-wait.in@1.7 +1 -1 + ntp-wait: some versions of ntpd spell "associd" differently + +ChangeSet@1.2585, 2011-06-27 22:30:17-07:00, harlan@hms-mbp.local + [Bug 1958] genLocInfo must export PATH + + ChangeLog@1.950 +1 -0 + [Bug 1958] genLocInfo must export PATH + + scripts/genLocInfo@1.10 +1 -0 + [Bug 1958] genLocInfo must export PATH + +ChangeSet@1.2584, 2011-06-24 08:03:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P187 + TAG: NTP_4_2_7P187 + + ChangeLog@1.949 +1 -0 + NTP_4_2_7P187 + + ntpd/ntpd-opts.c@1.192 +3 -3 + NTP_4_2_7P187 + + ntpd/ntpd-opts.h@1.192 +3 -3 + NTP_4_2_7P187 + + ntpd/ntpd-opts.texi@1.190 +2 -2 + NTP_4_2_7P187 + + ntpd/ntpd.1ntpdman@1.3 +2 -2 + NTP_4_2_7P187 + + ntpd/ntpd.1ntpdmdoc@1.3 +2 -2 + NTP_4_2_7P187 + + ntpd/ntpd.man.in@1.3 +2 -2 + NTP_4_2_7P187 + + ntpd/ntpd.mdoc.in@1.3 +2 -2 + NTP_4_2_7P187 + + ntpdc/ntpdc-opts.c@1.187 +3 -3 + NTP_4_2_7P187 + + ntpdc/ntpdc-opts.h@1.187 +3 -3 + NTP_4_2_7P187 + + ntpdc/ntpdc-opts.texi@1.187 +2 -2 + NTP_4_2_7P187 + + ntpdc/ntpdc.1ntpdcman@1.3 +2 -2 + NTP_4_2_7P187 + + ntpdc/ntpdc.1ntpdcmdoc@1.3 +2 -2 + NTP_4_2_7P187 + + ntpdc/ntpdc.html@1.15 +2 -2 + NTP_4_2_7P187 + + ntpdc/ntpdc.man.in@1.3 +2 -2 + NTP_4_2_7P187 + + ntpdc/ntpdc.mdoc.in@1.3 +2 -2 + NTP_4_2_7P187 + + ntpq/ntpq-opts.c@1.189 +3 -3 + NTP_4_2_7P187 + + ntpq/ntpq-opts.h@1.189 +3 -3 + NTP_4_2_7P187 + + ntpq/ntpq-opts.texi@1.189 +2 -2 + NTP_4_2_7P187 + + ntpq/ntpq.1ntpqman@1.3 +2 -2 + NTP_4_2_7P187 + + ntpq/ntpq.1ntpqmdoc@1.3 +2 -2 + NTP_4_2_7P187 + + ntpq/ntpq.man.in@1.3 +2 -2 + NTP_4_2_7P187 + + ntpq/ntpq.mdoc.in@1.3 +2 -2 + NTP_4_2_7P187 + + ntpsnmpd/ntpsnmpd-opts.c@1.189 +3 -3 + NTP_4_2_7P187 + + ntpsnmpd/ntpsnmpd-opts.h@1.189 +3 -3 + NTP_4_2_7P187 + + ntpsnmpd/ntpsnmpd-opts.texi@1.189 +2 -2 + NTP_4_2_7P187 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.3 +2 -2 + NTP_4_2_7P187 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.3 +2 -2 + NTP_4_2_7P187 + + ntpsnmpd/ntpsnmpd.man.in@1.3 +2 -2 + NTP_4_2_7P187 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.3 +2 -2 + NTP_4_2_7P187 + + packageinfo.sh@1.190 +1 -1 + NTP_4_2_7P187 + + scripts/ntp-wait-opts.texi@1.7 +1 -1 + NTP_4_2_7P187 + + scripts/ntp-wait.1ntp-waitman@1.3 +2 -2 + NTP_4_2_7P187 + + scripts/ntp-wait.1ntp-waitmdoc@1.3 +2 -2 + NTP_4_2_7P187 + + scripts/ntp-wait.html@1.7 +1 -1 + NTP_4_2_7P187 + + scripts/ntp-wait.man.in@1.3 +2 -2 + NTP_4_2_7P187 + + scripts/ntp-wait.mdoc.in@1.3 +2 -2 + NTP_4_2_7P187 + + sntp/sntp-opts.c@1.183 +3 -3 + NTP_4_2_7P187 + + sntp/sntp-opts.h@1.183 +3 -3 + NTP_4_2_7P187 + + sntp/sntp-opts.texi@1.183 +2 -2 + NTP_4_2_7P187 + + sntp/sntp.1sntpman@1.3 +2 -2 + NTP_4_2_7P187 + + sntp/sntp.1sntpmdoc@1.3 +2 -2 + NTP_4_2_7P187 + + sntp/sntp.html@1.183 +2 -2 + NTP_4_2_7P187 + + sntp/sntp.man.in@1.3 +2 -2 + NTP_4_2_7P187 + + sntp/sntp.mdoc.in@1.3 +2 -2 + NTP_4_2_7P187 + + util/ntp-keygen-opts.c@1.187 +3 -3 + NTP_4_2_7P187 + + util/ntp-keygen-opts.h@1.187 +3 -3 + NTP_4_2_7P187 + + util/ntp-keygen-opts.texi@1.190 +2 -2 + NTP_4_2_7P187 + + util/ntp-keygen.1ntp-keygenman@1.3 +2 -2 + NTP_4_2_7P187 + + util/ntp-keygen.1ntp-keygenmdoc@1.3 +2 -2 + NTP_4_2_7P187 + + util/ntp-keygen.man.in@1.3 +2 -2 + NTP_4_2_7P187 + + util/ntp-keygen.mdoc.in@1.3 +2 -2 + NTP_4_2_7P187 + +ChangeSet@1.2583, 2011-06-24 03:02:21-04:00, stenn@deacon.udel.edu + Implement --with-locfile=filename configure argument + + ChangeLog@1.948 +4 -0 + Implement --with-locfile=filename configure argument + + scripts/genLocInfo@1.9 +71 -50 + Implement --with-locfile=filename configure argument + + sntp/m4/ntp_locinfo.m4@1.9 +13 -1 + Implement --with-locfile=filename configure argument + +ChangeSet@1.2582, 2011-06-24 02:52:59-04:00, stenn@deacon.udel.edu + [Bug 1954] Fix typos in [s]bin_PROGRAMS in ntpd/Makefile.am + + ChangeLog@1.947 +1 -1 + [Bug 1954] Fix typos in [s]bin_PROGRAMS in ntpd/Makefile.am + +ChangeSet@1.2581, 2011-06-24 01:25:47-04:00, stenn@deacon.udel.edu + Fix typos in [s]bin_PROGRAMS in ntpd/Makefile.am + + ChangeLog@1.946 +1 -0 + Fix typos in [s]bin_PROGRAMS in ntpd/Makefile.am + + ntpd/Makefile.am@1.108 +2 -2 + Fix typos in [s]bin_PROGRAMS in ntpd/Makefile.am + +ChangeSet@1.2580, 2011-06-23 11:29:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P186 + TAG: NTP_4_2_7P186 + + ChangeLog@1.945 +1 -0 + NTP_4_2_7P186 + + ntpd/ntpd-opts.c@1.191 +3 -3 + NTP_4_2_7P186 + + ntpd/ntpd-opts.h@1.191 +3 -3 + NTP_4_2_7P186 + + ntpd/ntpd-opts.texi@1.189 +1 -1 + NTP_4_2_7P186 + + ntpd/ntpd.1ntpdman@1.2 +2 -2 + NTP_4_2_7P186 + + ntpd/ntpd.1ntpdmdoc@1.2 +3 -3 + NTP_4_2_7P186 + + ntpd/ntpd.man.in@1.2 +2 -2 + NTP_4_2_7P186 + + ntpd/ntpd.mdoc.in@1.2 +3 -3 + NTP_4_2_7P186 + + ntpdc/ntpdc-opts.c@1.186 +3 -3 + NTP_4_2_7P186 + + ntpdc/ntpdc-opts.h@1.186 +3 -3 + NTP_4_2_7P186 + + ntpdc/ntpdc-opts.texi@1.186 +2 -2 + NTP_4_2_7P186 + + ntpdc/ntpdc.1ntpdcman@1.2 +3 -31 + NTP_4_2_7P186 + + ntpdc/ntpdc.1ntpdcmdoc@1.2 +3 -3 + NTP_4_2_7P186 + + ntpdc/ntpdc.html@1.14 +2 -2 + NTP_4_2_7P186 + + ntpdc/ntpdc.man.in@1.2 +3 -31 + NTP_4_2_7P186 + + ntpdc/ntpdc.mdoc.in@1.2 +3 -3 + NTP_4_2_7P186 + + ntpq/ntpq-opts.c@1.188 +3 -3 + NTP_4_2_7P186 + + ntpq/ntpq-opts.h@1.188 +3 -3 + NTP_4_2_7P186 + + ntpq/ntpq-opts.texi@1.188 +2 -2 + NTP_4_2_7P186 + + ntpq/ntpq.1ntpqman@1.2 +2 -2 + NTP_4_2_7P186 + + ntpq/ntpq.1ntpqmdoc@1.2 +3 -3 + NTP_4_2_7P186 + + ntpq/ntpq.man.in@1.2 +2 -2 + NTP_4_2_7P186 + + ntpq/ntpq.mdoc.in@1.2 +3 -3 + NTP_4_2_7P186 + + ntpsnmpd/ntpsnmpd-opts.c@1.188 +3 -3 + NTP_4_2_7P186 + + ntpsnmpd/ntpsnmpd-opts.h@1.188 +3 -3 + NTP_4_2_7P186 + + ntpsnmpd/ntpsnmpd-opts.texi@1.188 +2 -2 + NTP_4_2_7P186 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.2 +2 -2 + NTP_4_2_7P186 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.2 +3 -3 + NTP_4_2_7P186 + + ntpsnmpd/ntpsnmpd.man.in@1.2 +2 -2 + NTP_4_2_7P186 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.2 +3 -3 + NTP_4_2_7P186 + + packageinfo.sh@1.189 +1 -1 + NTP_4_2_7P186 + + scripts/ntp-wait-opts.texi@1.6 +1 -1 + NTP_4_2_7P186 + + scripts/ntp-wait.1ntp-waitman@1.2 +2 -2 + NTP_4_2_7P186 + + scripts/ntp-wait.1ntp-waitmdoc@1.2 +3 -3 + NTP_4_2_7P186 + + scripts/ntp-wait.html@1.6 +1 -1 + NTP_4_2_7P186 + + scripts/ntp-wait.man.in@1.2 +2 -2 + NTP_4_2_7P186 + + scripts/ntp-wait.mdoc.in@1.2 +3 -3 + NTP_4_2_7P186 + + sntp/sntp-opts.c@1.182 +3 -3 + NTP_4_2_7P186 + + sntp/sntp-opts.h@1.182 +3 -3 + NTP_4_2_7P186 + + sntp/sntp-opts.texi@1.182 +2 -2 + NTP_4_2_7P186 + + sntp/sntp.1sntpman@1.2 +2 -2 + NTP_4_2_7P186 + + sntp/sntp.1sntpmdoc@1.2 +3 -3 + NTP_4_2_7P186 + + sntp/sntp.html@1.182 +2 -2 + NTP_4_2_7P186 + + sntp/sntp.man.in@1.2 +2 -2 + NTP_4_2_7P186 + + sntp/sntp.mdoc.in@1.2 +3 -3 + NTP_4_2_7P186 + + util/ntp-keygen-opts.c@1.186 +3 -3 + NTP_4_2_7P186 + + util/ntp-keygen-opts.h@1.186 +3 -3 + NTP_4_2_7P186 + + util/ntp-keygen-opts.texi@1.189 +2 -2 + NTP_4_2_7P186 + + util/ntp-keygen.1ntp-keygenman@1.2 +2 -2 + NTP_4_2_7P186 + + util/ntp-keygen.1ntp-keygenmdoc@1.2 +3 -3 + NTP_4_2_7P186 + + util/ntp-keygen.man.in@1.2 +2 -2 + NTP_4_2_7P186 + + util/ntp-keygen.mdoc.in@1.2 +3 -3 + NTP_4_2_7P186 + +ChangeSet@1.2577.1.1, 2011-06-23 03:27:04-04:00, stenn@psp-deb1.ntp.org + Update .point-changed-filelist for the new man pages + + .point-changed-filelist@1.13 +25 -7 + Update .point-changed-filelist for the new man pages + + ChangeLog@1.942.1.1 +1 -0 + Update .point-changed-filelist for the new man pages + +ChangeSet@1.2578, 2011-06-23 02:47:56-04:00, stenn@deacon.udel.edu + Documentation update from Dave Mills + + ChangeLog@1.943 +2 -1 + Documentation update from Dave Mills + + html/warp.html@1.15 +11 -3 + Documentation update from Dave Mills + +ChangeSet@1.2577, 2011-06-23 02:42:14-04:00, stenn@psp-deb1.ntp.org + merge cleanup + + ChangeLog@1.942 +1 -2 + merge cleanup + +ChangeSet@1.2574.1.6, 2011-06-23 02:16:14-04:00, stenn@psp-deb1.ntp.org + Update the building of OS-specific programs + + ChangeLog@1.939.1.3 +1 -0 + Update the building of OS-specific programs + + configure.ac@1.530 +25 -2 + Update the building of OS-specific programs + +ChangeSet@1.2574.1.5, 2011-06-22 23:14:06-04:00, stenn@psp-deb1.ntp.org + generated man page updates + + bootstrap@1.39 +1 -1 + generated man page updates + + ntpd/ntpd.1ntpdman@1.1 +909 -0 + BitKeeper file /home/stenn/ntp-dev/ntpd/ntpd.1ntpdman + + ntpd/ntpd.1ntpdman@1.0 +0 -0 + + ntpd/ntpd.1ntpdmdoc@1.1 +878 -0 + BitKeeper file /home/stenn/ntp-dev/ntpd/ntpd.1ntpdmdoc + + ntpd/ntpd.1ntpdmdoc@1.0 +0 -0 + + ntpd/ntpd.man.in@1.1 +909 -0 + BitKeeper file /home/stenn/ntp-dev/ntpd/ntpd.man.in + + ntpd/ntpd.man.in@1.0 +0 -0 + + ntpd/ntpd.mdoc.in@1.1 +878 -0 + BitKeeper file /home/stenn/ntp-dev/ntpd/ntpd.mdoc.in + + ntpd/ntpd.mdoc.in@1.0 +0 -0 + + ntpdc/ntpdc.1ntpdcman@1.1 +569 -0 + BitKeeper file /home/stenn/ntp-dev/ntpdc/ntpdc.1ntpdcman + + ntpdc/ntpdc.1ntpdcman@1.0 +0 -0 + + ntpdc/ntpdc.1ntpdcmdoc@1.1 +793 -0 + BitKeeper file /home/stenn/ntp-dev/ntpdc/ntpdc.1ntpdcmdoc + + ntpdc/ntpdc.1ntpdcmdoc@1.0 +0 -0 + + ntpdc/ntpdc.man.in@1.1 +569 -0 + BitKeeper file /home/stenn/ntp-dev/ntpdc/ntpdc.man.in + + ntpdc/ntpdc.man.in@1.0 +0 -0 + + ntpdc/ntpdc.mdoc.in@1.1 +793 -0 + BitKeeper file /home/stenn/ntp-dev/ntpdc/ntpdc.mdoc.in + + ntpdc/ntpdc.mdoc.in@1.0 +0 -0 + + ntpq/ntpq.1ntpqman@1.1 +397 -0 + BitKeeper file /home/stenn/ntp-dev/ntpq/ntpq.1ntpqman + + ntpq/ntpq.1ntpqman@1.0 +0 -0 + + ntpq/ntpq.1ntpqmdoc@1.1 +375 -0 + BitKeeper file /home/stenn/ntp-dev/ntpq/ntpq.1ntpqmdoc + + ntpq/ntpq.1ntpqmdoc@1.0 +0 -0 + + ntpq/ntpq.man.in@1.1 +397 -0 + BitKeeper file /home/stenn/ntp-dev/ntpq/ntpq.man.in + + ntpq/ntpq.man.in@1.0 +0 -0 + + ntpq/ntpq.mdoc.in@1.1 +375 -0 + BitKeeper file /home/stenn/ntp-dev/ntpq/ntpq.mdoc.in + + ntpq/ntpq.mdoc.in@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.1 +92 -0 + BitKeeper file /home/stenn/ntp-dev/ntpsnmpd/ntpsnmpd.1ntpsnmpdman + + ntpsnmpd/ntpsnmpd.1ntpsnmpdman@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.1 +89 -0 + BitKeeper file /home/stenn/ntp-dev/ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc + + ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.man.in@1.1 +92 -0 + BitKeeper file /home/stenn/ntp-dev/ntpsnmpd/ntpsnmpd.man.in + + ntpsnmpd/ntpsnmpd.man.in@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.mdoc.in@1.1 +89 -0 + BitKeeper file /home/stenn/ntp-dev/ntpsnmpd/ntpsnmpd.mdoc.in + + ntpsnmpd/ntpsnmpd.mdoc.in@1.0 +0 -0 + + scripts/ntp-wait.1ntp-waitman@1.1 +93 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait.1ntp-waitman + + scripts/ntp-wait.1ntp-waitman@1.0 +0 -0 + + scripts/ntp-wait.1ntp-waitmdoc@1.1 +92 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait.1ntp-waitmdoc + + scripts/ntp-wait.1ntp-waitmdoc@1.0 +0 -0 + + scripts/ntp-wait.man.in@1.1 +93 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait.man.in + + scripts/ntp-wait.man.in@1.0 +0 -0 + + scripts/ntp-wait.mdoc.in@1.1 +92 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait.mdoc.in + + scripts/ntp-wait.mdoc.in@1.0 +0 -0 + + sntp/include/mansec2subst.sed@1.1 +26 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/include/mansec2subst.sed + + sntp/include/mansec2subst.sed@1.0 +0 -0 + + sntp/sntp.1sntpman@1.1 +293 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/sntp.1sntpman + + sntp/sntp.1sntpman@1.0 +0 -0 + + sntp/sntp.1sntpmdoc@1.1 +275 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/sntp.1sntpmdoc + + sntp/sntp.1sntpmdoc@1.0 +0 -0 + + sntp/sntp.man.in@1.1 +293 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/sntp.man.in + + sntp/sntp.man.in@1.0 +0 -0 + + sntp/sntp.mdoc.in@1.1 +275 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/sntp.mdoc.in + + sntp/sntp.mdoc.in@1.0 +0 -0 + + util/ntp-keygen.1ntp-keygenman@1.1 +917 -0 + BitKeeper file /home/stenn/ntp-dev/util/ntp-keygen.1ntp-keygenman + + util/ntp-keygen.1ntp-keygenman@1.0 +0 -0 + + util/ntp-keygen.1ntp-keygenmdoc@1.1 +884 -0 + BitKeeper file /home/stenn/ntp-dev/util/ntp-keygen.1ntp-keygenmdoc + + util/ntp-keygen.1ntp-keygenmdoc@1.0 +0 -0 + + util/ntp-keygen.man.in@1.1 +917 -0 + BitKeeper file /home/stenn/ntp-dev/util/ntp-keygen.man.in + + util/ntp-keygen.man.in@1.0 +0 -0 + + util/ntp-keygen.mdoc.in@1.1 +884 -0 + BitKeeper file /home/stenn/ntp-dev/util/ntp-keygen.mdoc.in + + util/ntp-keygen.mdoc.in@1.0 +0 -0 + +ChangeSet@1.2574.1.4, 2011-06-22 22:57:47-04:00, stenn@psp-deb1.ntp.org + Work around solaris /bin/sh braindamage + + scripts/genLocInfo@1.8 +2 -12 + Work around solaris /bin/sh braindamage + +ChangeSet@1.2574.1.3, 2011-06-22 22:57:21-04:00, stenn@psp-deb1.ntp.org + Do not ignore generated man pages + + BitKeeper/etc/ignore@1.83 +0 -4 + Do not ignore generated man pages + +ChangeSet@1.2574.1.2, 2011-06-22 20:18:20-04:00, stenn@psp-deb1.ntp.org + validate MANTAGFMT in genLocInfo + + ChangeLog@1.939.1.2 +1 -0 + validate MANTAGFMT in genLocInfo + + scripts/genLocInfo@1.7 +9 -1 + validate MANTAGFMT in genLocInfo + +ChangeSet@1.2573.1.4, 2011-06-22 18:49:43-04:00, stenn@psp-deb1.ntp.org + Finish conversion to genLocInfo. + + .point-changed-filelist@1.12 +4 -1 + Finish conversion to genLocInfo. + + BitKeeper/deleted/10/ntp-wait.1~5aa615f3f31c2873@1.4.1.1 +0 -0 + Delete: scripts/ntp-wait.1 + + BitKeeper/deleted/1d/ntp-keygen.1~ef7a6b66bc6794e8@1.187.1.1 +0 -0 + Delete: util/ntp-keygen.1 + + BitKeeper/deleted/4d/sntp.1~9b6f13948b8b0ead@1.181 +0 -0 + Delete: sntp/sntp.1 + + BitKeeper/deleted/70/ntpdsim.1~916fd6f22320fcad@1.16 +0 -0 + Delete: ntpd/ntpdsim.1 + + BitKeeper/deleted/a7/ntpdc.1~1dd38e607d4b7e9a@1.184.1.1 +0 -0 + Delete: ntpdc/ntpdc.1 + + BitKeeper/deleted/ac/ntpd.1~e95786c25d7ce6ae@1.187.1.1 +0 -0 + Delete: ntpd/ntpd.1 + + BitKeeper/deleted/ad/ntpq.1~b5913739d03602e2@1.186.1.1 +0 -0 + Delete: ntpq/ntpq.1 + + BitKeeper/deleted/e5/ntpsnmpd.1~14083c7c951dc39f@1.186.1.1 +0 -0 + Delete: ntpsnmpd/ntpsnmpd.1 + + BitKeeper/etc/ignore@1.82 +5 -0 + Finish conversion to genLocInfo. + + ChangeLog@1.938.1.3 +1 -0 + Finish conversion to genLocInfo. + + Makefile.am@1.112 +1 -2 + Finish conversion to genLocInfo. + + adjtimed/Makefile.am@1.13 +2 -5 + Finish conversion to genLocInfo. + + bincheck.mf@1.4 +9 -7 + Finish conversion to genLocInfo. + + configure.ac@1.529 +26 -0 + Finish conversion to genLocInfo. + + loc/freebsd@1.3 +0 -0 + Rename: loc.freebsd -> loc/freebsd + + loc/legacy@1.3 +0 -0 + Rename: loc.legacy -> loc/legacy + + ntpd/Makefile.am@1.107 +45 -13 + Finish conversion to genLocInfo. + + ntpdate/Makefile.am@1.31 +3 -6 + Finish conversion to genLocInfo. + + ntpdc/Makefile.am@1.64 +38 -15 + Finish conversion to genLocInfo. + + ntpq/Makefile.am@1.60 +49 -15 + Finish conversion to genLocInfo. + + ntpsnmpd/Makefile.am@1.31 +50 -13 + Finish conversion to genLocInfo. + + scripts/Makefile.am@1.27 +42 -13 + Finish conversion to genLocInfo. + + scripts/genLocInfo@1.6 +7 -5 + Finish conversion to genLocInfo. + + sntp/Makefile.am@1.64 +39 -12 + Finish conversion to genLocInfo. + + sntp/configure.ac@1.62 +97 -0 + Finish conversion to genLocInfo. + + sntp/include/Makefile.am@1.3 +1 -0 + Finish conversion to genLocInfo. + + sntp/m4/ntp_libntp.m4@1.15 +0 -1 + Finish conversion to genLocInfo. + + sntp/m4/ntp_locinfo.m4@1.5.1.3 +2 -1 + Finish conversion to genLocInfo. + + sntp/sntp-opts.def@1.33 +1 -1 + Finish conversion to genLocInfo. + + util/Makefile.am@1.63 +54 -19 + Finish conversion to genLocInfo. + +ChangeSet@1.2575, 2011-06-21 11:29:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P185 + TAG: NTP_4_2_7P185 + + ChangeLog@1.940 +1 -0 + NTP_4_2_7P185 + + ntpd/ntpd-opts.c@1.190 +3 -3 + NTP_4_2_7P185 + + ntpd/ntpd-opts.h@1.190 +3 -3 + NTP_4_2_7P185 + + ntpd/ntpd-opts.texi@1.188 +2 -2 + NTP_4_2_7P185 + + ntpd/ntpd.1@1.188 +2 -2 + NTP_4_2_7P185 + + ntpdc/ntpdc-opts.c@1.185 +3 -3 + NTP_4_2_7P185 + + ntpdc/ntpdc-opts.h@1.185 +3 -3 + NTP_4_2_7P185 + + ntpdc/ntpdc-opts.texi@1.185 +2 -2 + NTP_4_2_7P185 + + ntpdc/ntpdc.1@1.185 +2 -2 + NTP_4_2_7P185 + + ntpdc/ntpdc.html@1.13 +2 -2 + NTP_4_2_7P185 + + ntpq/ntpq-opts.c@1.187 +3 -3 + NTP_4_2_7P185 + + ntpq/ntpq-opts.h@1.187 +3 -3 + NTP_4_2_7P185 + + ntpq/ntpq-opts.texi@1.187 +2 -2 + NTP_4_2_7P185 + + ntpq/ntpq.1@1.187 +2 -2 + NTP_4_2_7P185 + + ntpsnmpd/ntpsnmpd-opts.c@1.187 +3 -3 + NTP_4_2_7P185 + + ntpsnmpd/ntpsnmpd-opts.h@1.187 +3 -3 + NTP_4_2_7P185 + + ntpsnmpd/ntpsnmpd-opts.texi@1.187 +2 -2 + NTP_4_2_7P185 + + ntpsnmpd/ntpsnmpd.1@1.187 +2 -2 + NTP_4_2_7P185 + + packageinfo.sh@1.188 +1 -1 + NTP_4_2_7P185 + + scripts/ntp-wait-opts.texi@1.5 +1 -1 + NTP_4_2_7P185 + + scripts/ntp-wait.1@1.5 +2 -2 + NTP_4_2_7P185 + + scripts/ntp-wait.html@1.5 +1 -1 + NTP_4_2_7P185 + + sntp/sntp-opts.c@1.181 +3 -3 + NTP_4_2_7P185 + + sntp/sntp-opts.h@1.181 +3 -3 + NTP_4_2_7P185 + + sntp/sntp-opts.texi@1.181 +2 -2 + NTP_4_2_7P185 + + sntp/sntp.1@1.180.1.1 +2 -2 + NTP_4_2_7P185 + + sntp/sntp.html@1.181 +2 -2 + NTP_4_2_7P185 + + util/ntp-keygen-opts.c@1.185 +3 -3 + NTP_4_2_7P185 + + util/ntp-keygen-opts.h@1.185 +3 -3 + NTP_4_2_7P185 + + util/ntp-keygen-opts.texi@1.188 +2 -2 + NTP_4_2_7P185 + + util/ntp-keygen.1@1.188 +2 -2 + NTP_4_2_7P185 + +ChangeSet@1.2573.1.3, 2011-06-21 02:14:29-04:00, stenn@psp-deb1.ntp.org + Rename ntp_locs.m4 to ntp_locinfo.m4 + + sntp/m4/ntp_locinfo.m4@1.5.1.2 +0 -0 + Rename: sntp/m4/ntp_locs.m4 -> sntp/m4/ntp_locinfo.m4 + +ChangeSet@1.2573.1.2, 2011-06-21 02:09:40-04:00, stenn@psp-deb1.ntp.org + ntp_locs.m4: handle the case where . is not in the PATH + + ChangeLog@1.938.1.2 +1 -0 + ntp_locs.m4: handle the case where . is not in the PATH + + sntp/m4/ntp_locs.m4@1.5.1.1 +1 -1 + ntp_locs.m4: handle the case where . is not in the PATH + +ChangeSet@1.2573.1.1, 2011-06-21 01:58:35-04:00, stenn@psp-deb1.ntp.org + [Bug 1950] Control installation of event_rpcgen.py + + ChangeLog@1.938.1.1 +1 -0 + [Bug 1950] Control installation of event_rpcgen.py + + sntp/libevent/Makefile.am@1.7 +3 -0 + [Bug 1950] Control installation of event_rpcgen.py + +ChangeSet@1.2574, 2011-06-20 18:50:41-04:00, stenn@deacon.udel.edu + . may not be in the PATH - ntp_locs.m4 fix + + ChangeLog@1.939 +1 -0 + . may not be in the PATH - ntp_locs.m4 fix + + sntp/m4/ntp_locs.m4@1.6 +1 -1 + . may not be in the PATH - ntp_locs.m4 fix + +ChangeSet@1.2573, 2011-06-20 07:02:17-04:00, stenn@psp-deb1.ntp.org + More genLocInfo cleanup + + ChangeLog@1.938 +1 -0 + More genLocInfo cleanup + + configure.ac@1.528 +2 -0 + More genLocInfo cleanup + + scripts/genLocInfo@1.5 +1 -0 + More genLocInfo cleanup + + sntp/m4/ntp_locs.m4@1.5 +7 -1 + More genLocInfo cleanup + +ChangeSet@1.2572, 2011-06-20 05:58:04-04:00, stenn@deacon.udel.edu + genLocInfo is EXTRA_DIST, not noinst_SCRIPT + + scripts/Makefile.am@1.26 +1 -1 + genLocInfo is EXTRA_DIST, not noinst_SCRIPT + +ChangeSet@1.2571, 2011-06-20 09:46:53+00:00, stenn@deacon.udel.edu + NTP_4_2_7P184 + TAG: NTP_4_2_7P184 + + ChangeLog@1.937 +1 -0 + NTP_4_2_7P184 + + ntpd/ntpd-opts.c@1.189 +3 -3 + NTP_4_2_7P184 + + ntpd/ntpd-opts.h@1.189 +3 -3 + NTP_4_2_7P184 + + ntpd/ntpd-opts.texi@1.187 +2 -2 + NTP_4_2_7P184 + + ntpd/ntpd.1@1.187 +2 -2 + NTP_4_2_7P184 + + ntpdc/ntpdc-opts.c@1.184 +3 -3 + NTP_4_2_7P184 + + ntpdc/ntpdc-opts.h@1.184 +3 -3 + NTP_4_2_7P184 + + ntpdc/ntpdc-opts.texi@1.184 +2 -2 + NTP_4_2_7P184 + + ntpdc/ntpdc.1@1.184 +2 -2 + NTP_4_2_7P184 + + ntpdc/ntpdc.html@1.12 +2 -2 + NTP_4_2_7P184 + + ntpq/ntpq-opts.c@1.186 +3 -3 + NTP_4_2_7P184 + + ntpq/ntpq-opts.h@1.186 +3 -3 + NTP_4_2_7P184 + + ntpq/ntpq-opts.texi@1.186 +2 -2 + NTP_4_2_7P184 + + ntpq/ntpq.1@1.186 +2 -2 + NTP_4_2_7P184 + + ntpsnmpd/ntpsnmpd-opts.c@1.186 +3 -3 + NTP_4_2_7P184 + + ntpsnmpd/ntpsnmpd-opts.h@1.186 +3 -3 + NTP_4_2_7P184 + + ntpsnmpd/ntpsnmpd-opts.texi@1.186 +2 -2 + NTP_4_2_7P184 + + ntpsnmpd/ntpsnmpd.1@1.186 +2 -2 + NTP_4_2_7P184 + + packageinfo.sh@1.187 +1 -1 + NTP_4_2_7P184 + + scripts/ntp-wait-opts.texi@1.4 +1 -1 + NTP_4_2_7P184 + + scripts/ntp-wait.1@1.4 +2 -2 + NTP_4_2_7P184 + + scripts/ntp-wait.html@1.4 +1 -1 + NTP_4_2_7P184 + + sntp/sntp-opts.c@1.180 +3 -3 + NTP_4_2_7P184 + + sntp/sntp-opts.h@1.180 +3 -3 + NTP_4_2_7P184 + + sntp/sntp-opts.texi@1.180 +2 -2 + NTP_4_2_7P184 + + sntp/sntp.1@1.180 +2 -2 + NTP_4_2_7P184 + + sntp/sntp.html@1.180 +2 -2 + NTP_4_2_7P184 + + util/ntp-keygen-opts.c@1.184 +3 -3 + NTP_4_2_7P184 + + util/ntp-keygen-opts.h@1.184 +3 -3 + NTP_4_2_7P184 + + util/ntp-keygen-opts.texi@1.187 +2 -2 + NTP_4_2_7P184 + + util/ntp-keygen.1@1.187 +2 -2 + NTP_4_2_7P184 + +ChangeSet@1.2570, 2011-06-20 05:31:49-04:00, stenn@psp-deb1.ntp.org + genLocInfo cleanup + + scripts/genLocInfo@1.4 +4 -0 + genLocInfo cleanup + +ChangeSet@1.2569, 2011-06-20 05:24:55-04:00, stenn@psp-deb1.ntp.org + genLocInfo cleanup + + sntp/m4/ntp_locs.m4@1.4 +2 -2 + genLocInfo cleanup + +ChangeSet@1.2568, 2011-06-20 04:54:00-04:00, stenn@psp-deb1.ntp.org + genLocInfo cleanup + + sntp/m4/ntp_locs.m4@1.3 +2 -1 + genLocInfo cleanup + +ChangeSet@1.2567, 2011-06-20 03:58:19-04:00, stenn@psp-deb1.ntp.org + Updates to ntp_locs.m4 + + ChangeLog@1.936 +1 -0 + Updates to ntp_locs.m4 + + sntp/m4/ntp_locs.m4@1.2 +1 -1 + Updates to ntp_locs.m4 + + sntp/m4/ntp_locs.m4@1.1 +57 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/m4/ntp_locs.m4 + + sntp/m4/ntp_locs.m4@1.0 +0 -0 + +ChangeSet@1.2566, 2011-06-20 02:08:50-04:00, stenn@psp-deb1.ntp.org + genLocInfo improvements + + scripts/genLocInfo@1.3 +8 -3 + genLocInfo improvements + +ChangeSet@1.2565, 2011-06-19 23:07:56-04:00, stenn@psp-deb1.ntp.org + genLocInfo improvements + + ChangeLog@1.935 +1 -0 + genLocInfo improvements + + scripts/genLocInfo@1.2 +97 -12 + genLocInfo improvements + +ChangeSet@1.2561.1.2, 2011-06-19 19:06:27-04:00, stenn@psp-deb1.ntp.org + Add the man page tag "flavor" to the loc.* files + + ChangeLog@1.931.1.2 +1 -0 + Add the man page tag "flavor" to the loc.* files + + loc.freebsd@1.2 +1 -0 + Add the man page tag "flavor" to the loc.* files + + loc.legacy@1.2 +1 -0 + Add the man page tag "flavor" to the loc.* files + +ChangeSet@1.2561.1.1, 2011-06-19 19:04:22-04:00, stenn@psp-deb1.ntp.org + Add/distribute genLocInfo + + ChangeLog@1.931.1.1 +1 -0 + Add/distribute genLocInfo + + scripts/Makefile.am@1.23.1.1 +1 -0 + Distribute genLocInfo + + scripts/genLocInfo@1.1 +66 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/genLocInfo + + scripts/genLocInfo@1.0 +0 -0 + +ChangeSet@1.2563, 2011-06-19 22:34:06+00:00, stenn@deacon.udel.edu + NTP_4_2_7P183 + TAG: NTP_4_2_7P183 + + ChangeLog@1.933 +1 -1 + NTP_4_2_7P183 + + ntpd/ntpd-opts.c@1.188 +3 -3 + NTP_4_2_7P183 + + ntpd/ntpd-opts.h@1.188 +3 -3 + NTP_4_2_7P183 + + ntpd/ntpd-opts.texi@1.186 +2 -2 + NTP_4_2_7P183 + + ntpd/ntpd.1@1.186 +2 -2 + NTP_4_2_7P183 + + ntpdc/ntpdc-opts.c@1.183 +3 -3 + NTP_4_2_7P183 + + ntpdc/ntpdc-opts.h@1.183 +3 -3 + NTP_4_2_7P183 + + ntpdc/ntpdc-opts.texi@1.183 +2 -2 + NTP_4_2_7P183 + + ntpdc/ntpdc.1@1.183 +2 -2 + NTP_4_2_7P183 + + ntpdc/ntpdc.html@1.11 +2 -2 + NTP_4_2_7P183 + + ntpq/ntpq-opts.c@1.185 +3 -3 + NTP_4_2_7P183 + + ntpq/ntpq-opts.h@1.185 +3 -3 + NTP_4_2_7P183 + + ntpq/ntpq-opts.texi@1.185 +2 -2 + NTP_4_2_7P183 + + ntpq/ntpq.1@1.185 +2 -2 + NTP_4_2_7P183 + + ntpsnmpd/ntpsnmpd-opts.c@1.185 +3 -3 + NTP_4_2_7P183 + + ntpsnmpd/ntpsnmpd-opts.h@1.185 +3 -3 + NTP_4_2_7P183 + + ntpsnmpd/ntpsnmpd-opts.texi@1.185 +2 -2 + NTP_4_2_7P183 + + ntpsnmpd/ntpsnmpd.1@1.185 +2 -2 + NTP_4_2_7P183 + + packageinfo.sh@1.186 +1 -1 + NTP_4_2_7P183 + + scripts/ntp-wait-opts.texi@1.3 +1 -1 + NTP_4_2_7P183 + + scripts/ntp-wait.1@1.3 +2 -2 + NTP_4_2_7P183 + + scripts/ntp-wait.html@1.3 +1 -1 + NTP_4_2_7P183 + + sntp/sntp-opts.c@1.179 +3 -3 + NTP_4_2_7P183 + + sntp/sntp-opts.h@1.179 +3 -3 + NTP_4_2_7P183 + + sntp/sntp-opts.texi@1.179 +2 -2 + NTP_4_2_7P183 + + sntp/sntp.1@1.179 +2 -2 + NTP_4_2_7P183 + + sntp/sntp.html@1.179 +2 -2 + NTP_4_2_7P183 + + util/ntp-keygen-opts.c@1.183 +3 -3 + NTP_4_2_7P183 + + util/ntp-keygen-opts.h@1.183 +3 -3 + NTP_4_2_7P183 + + util/ntp-keygen-opts.texi@1.186 +2 -2 + NTP_4_2_7P183 + + util/ntp-keygen.1@1.186 +2 -2 + NTP_4_2_7P183 + +ChangeSet@1.2562, 2011-06-19 18:17:53-04:00, stenn@deacon.udel.edu + Update the autogen include list for scripts/Makefile.am + + ChangeLog@1.932 +2 -0 + Update the autogen include list for scripts/Makefile.am + + scripts/Makefile.am@1.24 +1 -1 + Update the autogen include list for scripts/Makefile.am + +ChangeSet@1.2561, 2011-06-19 03:07:32-04:00, stenn@psp-deb1.ntp.org + Added loc.freebsd (and distribute it) + + ChangeLog@1.931 +1 -0 + Added loc.freebsd (and distribute it) + + Makefile.am@1.111 +1 -0 + Added loc.freebsd (and distribute it) + + loc.freebsd@1.1 +12 -0 + BitKeeper file /home/stenn/ntp-dev/loc.freebsd + + loc.freebsd@1.0 +0 -0 + +ChangeSet@1.2560, 2011-06-19 01:27:46-04:00, stenn@psp-deb1.ntp.org + Added loc.legacy (and distribute it) + + ChangeLog@1.930 +1 -0 + Added loc.legacy (and distribute it) + + Makefile.am@1.110 +1 -0 + Added loc.legacy (and distribute it) + + loc.legacy@1.1 +14 -0 + BitKeeper file /home/stenn/ntp-dev/loc.legacy + + loc.legacy@1.0 +0 -0 + +ChangeSet@1.2559, 2011-06-15 09:03:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P182 + TAG: NTP_4_2_7P182 + + ChangeLog@1.929 +1 -0 + NTP_4_2_7P182 + + ntpd/ntpd-opts.c@1.187 +21 -6 + NTP_4_2_7P182 + + ntpd/ntpd-opts.h@1.187 +23 -8 + NTP_4_2_7P182 + + ntpd/ntpd-opts.texi@1.185 +4 -5 + NTP_4_2_7P182 + + ntpd/ntpd.1@1.185 +623 -102 + NTP_4_2_7P182 + + ntpdc/ntpdc-opts.c@1.182 +21 -15 + NTP_4_2_7P182 + + ntpdc/ntpdc-opts.h@1.182 +23 -8 + NTP_4_2_7P182 + + ntpdc/ntpdc-opts.texi@1.182 +4 -29 + NTP_4_2_7P182 + + ntpdc/ntpdc.1@1.182 +11 -9 + NTP_4_2_7P182 + + ntpdc/ntpdc.html@1.10 +6 -31 + NTP_4_2_7P182 + + ntpq/ntpq-opts.c@1.184 +20 -11 + NTP_4_2_7P182 + + ntpq/ntpq-opts.h@1.184 +23 -8 + NTP_4_2_7P182 + + ntpq/ntpq-opts.texi@1.184 +3 -17 + NTP_4_2_7P182 + + ntpq/ntpq.1@1.184 +106 -124 + NTP_4_2_7P182 + + ntpsnmpd/ntpsnmpd-opts.c@1.184 +20 -5 + NTP_4_2_7P182 + + ntpsnmpd/ntpsnmpd-opts.h@1.184 +23 -8 + NTP_4_2_7P182 + + ntpsnmpd/ntpsnmpd-opts.texi@1.184 +4 -3 + NTP_4_2_7P182 + + ntpsnmpd/ntpsnmpd.1@1.184 +52 -45 + NTP_4_2_7P182 + + packageinfo.sh@1.185 +1 -1 + NTP_4_2_7P182 + + scripts/ntp-wait-opts.texi@1.2 +2 -14 + NTP_4_2_7P182 + + scripts/ntp-wait.1@1.2 +3 -3 + NTP_4_2_7P182 + + scripts/ntp-wait.html@1.2 +14 -37 + NTP_4_2_7P182 + + sntp/sntp-opts.c@1.178 +19 -4 + NTP_4_2_7P182 + + sntp/sntp-opts.h@1.178 +23 -8 + NTP_4_2_7P182 + + sntp/sntp-opts.texi@1.178 +2 -2 + NTP_4_2_7P182 + + sntp/sntp.1@1.178 +11 -13 + NTP_4_2_7P182 + + sntp/sntp.html@1.178 +2 -2 + NTP_4_2_7P182 + + util/ntp-keygen-opts.c@1.182 +21 -8 + NTP_4_2_7P182 + + util/ntp-keygen-opts.h@1.182 +23 -8 + NTP_4_2_7P182 + + util/ntp-keygen-opts.texi@1.185 +5 -8 + NTP_4_2_7P182 + + util/ntp-keygen.1@1.185 +772 -78 + NTP_4_2_7P182 + +ChangeSet@1.2558, 2011-06-15 04:50:01-04:00, stenn@deacon.udel.edu + Update .point-changed-filelist + + .point-changed-filelist@1.11 +3 -0 + Update .point-changed-filelist + + ChangeLog@1.928 +1 -0 + Update .point-changed-filelist + +ChangeSet@1.2557, 2011-06-15 04:21:57-04:00, stenn@psp-deb1.ntp.org + [Bug 1304] Update sntp.html to reflect new implementation + + ChangeLog@1.927 +1 -0 + [Bug 1304] Update sntp.html to reflect new implementation + +ChangeSet@1.2556, 2011-06-15 04:11:33-04:00, stenn@psp-deb1.ntp.org + ntpdc documentation fixes + + ChangeLog@1.926 +1 -0 + ntpdc documentation fixes + + ntpdc/ntpdc-opts.def@1.19 +3 -0 + ntpdc documentation fixes + + ntpdc/ntpdc.texi@1.2 +1 -1 + ntpdc documentation fixes + +ChangeSet@1.2555, 2011-06-15 04:10:12-04:00, stenn@psp-deb1.ntp.org + Update ntp-wait autogen docs + + ChangeLog@1.925 +1 -0 + Update ntp-wait autogen docs + + scripts/Makefile.am@1.23 +40 -0 + Update ntp-wait autogen docs + + scripts/ntp-wait-opts.def@1.1 +106 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait-opts.def + + scripts/ntp-wait-opts.def@1.0 +0 -0 + + scripts/ntp-wait-opts.menu@1.1 +1 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait-opts.menu + + scripts/ntp-wait-opts.menu@1.0 +0 -0 + + scripts/ntp-wait-opts.texi@1.1 +58 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait-opts.texi + + scripts/ntp-wait-opts.texi@1.0 +0 -0 + + scripts/ntp-wait.1@1.1 +92 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait.1 + + scripts/ntp-wait.1@1.0 +0 -0 + + scripts/ntp-wait.html@1.1 +174 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait.html + + scripts/ntp-wait.html@1.0 +0 -0 + + scripts/ntp-wait.texi@1.1 +91 -0 + BitKeeper file /home/stenn/ntp-dev/scripts/ntp-wait.texi + + scripts/ntp-wait.texi@1.0 +0 -0 + +ChangeSet@1.2554, 2011-06-14 08:10:15+00:00, stenn@psp-fb2.ntp.org + Update the ntpd autogen docs + + ChangeLog@1.924 +1 -0 + Update the ntpd autogen docs + + ntpd/Makefile.am@1.106 +3 -1 + Update the ntpd autogen docs + + ntpd/ntpd-opts.def@1.7 +590 -2 + Update the ntpd autogen docs + +ChangeSet@1.2553, 2011-06-13 22:24:35-07:00, stenn@psp-os1.ntp.org + Update the ntpsnmpd autogen docs + + ChangeLog@1.923 +1 -0 + Update the ntpsnmpd autogen docs + + ntpsnmpd/Makefile.am@1.30 +3 -1 + Update the ntpsnmpd autogen docs + + ntpsnmpd/ntpsnmpd-opts.def@1.3 +51 -0 + Update the ntpsnmpd autogen docs + +ChangeSet@1.2552, 2011-06-12 14:53:25-07:00, stenn@psp-os1.ntp.org + Use autogen to produce ntp-keygen docs + + ChangeLog@1.922 +1 -0 + Use autogen to produce ntp-keygen docs + + util/Makefile.am@1.62 +3 -1 + Use autogen to produce ntp-keygen docs + + util/ntp-keygen-opts.def@1.14 +743 -4 + Use autogen to produce ntp-keygen docs + +ChangeSet@1.2551, 2011-06-12 14:52:05-07:00, stenn@psp-os1.ntp.org + Add "license name" to ntp.lic for autogen-5.11.10 + + ChangeLog@1.921 +1 -0 + Add "license name" to ntp.lic for autogen-5.11.10 + + sntp/include/ntp.lic@1.5 +2 -0 + Add "license name" to ntp.lic for autogen-5.11.10 + +ChangeSet@1.2550, 2011-06-12 14:40:43-07:00, stenn@psp-os1.ntp.org + Prepare for ntp.keys.5 + + ChangeLog@1.920 +1 -0 + Prepare for ntp.keys.5 + + ntpd/ntp.keys.def@1.1 +153 -0 + BitKeeper file /home/stenn/ntp-dev/ntpd/ntp.keys.def + + ntpd/ntp.keys.def@1.0 +0 -0 + +ChangeSet@1.2544.1.5, 2011-06-07 10:34:42+00:00, stenn@deacon.udel.edu + NTP_4_2_7P181 + TAG: NTP_4_2_7P181 + + ChangeLog@1.915.1.4 +1 -0 + NTP_4_2_7P181 + + ntpd/ntpd-opts.c@1.186 +3 -3 + NTP_4_2_7P181 + + ntpd/ntpd-opts.h@1.186 +3 -3 + NTP_4_2_7P181 + + ntpd/ntpd-opts.texi@1.184 +2 -2 + NTP_4_2_7P181 + + ntpd/ntpd.1@1.184 +2 -2 + NTP_4_2_7P181 + + ntpdc/ntpdc-opts.c@1.181 +3 -3 + NTP_4_2_7P181 + + ntpdc/ntpdc-opts.h@1.181 +3 -3 + NTP_4_2_7P181 + + ntpdc/ntpdc-opts.texi@1.181 +2 -2 + NTP_4_2_7P181 + + ntpdc/ntpdc.1@1.181 +2 -2 + NTP_4_2_7P181 + + ntpdc/ntpdc.html@1.9 +2 -2 + NTP_4_2_7P181 + + ntpq/ntpq-opts.c@1.183 +3 -3 + NTP_4_2_7P181 + + ntpq/ntpq-opts.h@1.183 +3 -3 + NTP_4_2_7P181 + + ntpq/ntpq-opts.texi@1.183 +2 -2 + NTP_4_2_7P181 + + ntpq/ntpq.1@1.183 +2 -2 + NTP_4_2_7P181 + + ntpsnmpd/ntpsnmpd-opts.c@1.183 +3 -3 + NTP_4_2_7P181 + + ntpsnmpd/ntpsnmpd-opts.h@1.183 +3 -3 + NTP_4_2_7P181 + + ntpsnmpd/ntpsnmpd-opts.texi@1.183 +2 -2 + NTP_4_2_7P181 + + ntpsnmpd/ntpsnmpd.1@1.183 +2 -2 + NTP_4_2_7P181 + + packageinfo.sh@1.184 +1 -1 + NTP_4_2_7P181 + + sntp/sntp-opts.c@1.177 +3 -3 + NTP_4_2_7P181 + + sntp/sntp-opts.h@1.177 +3 -3 + NTP_4_2_7P181 + + sntp/sntp-opts.texi@1.177 +2 -2 + NTP_4_2_7P181 + + sntp/sntp.1@1.177 +2 -2 + NTP_4_2_7P181 + + sntp/sntp.html@1.177 +2 -2 + NTP_4_2_7P181 + + util/ntp-keygen-opts.c@1.181 +3 -3 + NTP_4_2_7P181 + + util/ntp-keygen-opts.h@1.181 +3 -3 + NTP_4_2_7P181 + + util/ntp-keygen-opts.texi@1.184 +2 -2 + NTP_4_2_7P181 + + util/ntp-keygen.1@1.184 +2 -2 + NTP_4_2_7P181 + +ChangeSet@1.2544.1.4, 2011-06-07 02:25:51-04:00, stenn@deacon.udel.edu + [Bug 1938] addr_eqprefix() doesn't clear enough storage + + ChangeLog@1.915.1.3 +1 -0 + [Bug 1938] addr_eqprefix() doesn't clear enough storage + + ntpd/ntp_io.c@1.357 +2 -2 + [Bug 1938] addr_eqprefix() doesn't clear enough storage + +ChangeSet@1.2544.1.3, 2011-06-06 18:10:10-04:00, stenn@deacon.udel.edu + p180 was: Upgrade to libevent-2.0.12 + + ChangeLog@1.915.1.2 +1 -0 + p180 was: Upgrade to libevent-2.0.12 + +ChangeSet@1.2544.1.2, 2011-06-06 10:41:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P180 + TAG: NTP_4_2_7P180 + + ChangeLog@1.915.1.1 +1 -0 + NTP_4_2_7P180 + + ntpd/ntpd-opts.c@1.185 +3 -3 + NTP_4_2_7P180 + + ntpd/ntpd-opts.h@1.185 +3 -3 + NTP_4_2_7P180 + + ntpd/ntpd-opts.texi@1.183 +2 -2 + NTP_4_2_7P180 + + ntpd/ntpd.1@1.183 +2 -2 + NTP_4_2_7P180 + + ntpdc/ntpdc-opts.c@1.180 +3 -3 + NTP_4_2_7P180 + + ntpdc/ntpdc-opts.h@1.180 +3 -3 + NTP_4_2_7P180 + + ntpdc/ntpdc-opts.texi@1.180 +2 -2 + NTP_4_2_7P180 + + ntpdc/ntpdc.1@1.180 +2 -2 + NTP_4_2_7P180 + + ntpdc/ntpdc.html@1.8 +2 -2 + NTP_4_2_7P180 + + ntpq/ntpq-opts.c@1.182 +3 -3 + NTP_4_2_7P180 + + ntpq/ntpq-opts.h@1.182 +3 -3 + NTP_4_2_7P180 + + ntpq/ntpq-opts.texi@1.182 +2 -2 + NTP_4_2_7P180 + + ntpq/ntpq.1@1.182 +2 -2 + NTP_4_2_7P180 + + ntpsnmpd/ntpsnmpd-opts.c@1.182 +3 -3 + NTP_4_2_7P180 + + ntpsnmpd/ntpsnmpd-opts.h@1.182 +3 -3 + NTP_4_2_7P180 + + ntpsnmpd/ntpsnmpd-opts.texi@1.182 +2 -2 + NTP_4_2_7P180 + + ntpsnmpd/ntpsnmpd.1@1.182 +2 -2 + NTP_4_2_7P180 + + packageinfo.sh@1.183 +1 -1 + NTP_4_2_7P180 + + sntp/sntp-opts.c@1.176 +3 -3 + NTP_4_2_7P180 + + sntp/sntp-opts.h@1.176 +3 -3 + NTP_4_2_7P180 + + sntp/sntp-opts.texi@1.176 +2 -2 + NTP_4_2_7P180 + + sntp/sntp.1@1.176 +2 -2 + NTP_4_2_7P180 + + sntp/sntp.html@1.176 +2 -2 + NTP_4_2_7P180 + + util/ntp-keygen-opts.c@1.180 +3 -3 + NTP_4_2_7P180 + + util/ntp-keygen-opts.h@1.180 +3 -3 + NTP_4_2_7P180 + + util/ntp-keygen-opts.texi@1.183 +2 -2 + NTP_4_2_7P180 + + util/ntp-keygen.1@1.183 +2 -2 + NTP_4_2_7P180 + +ChangeSet@1.2548, 2011-06-06 03:59:08-04:00, stenn@psp-deb1.ntp.org + More sntp.1 cleanups + + BitKeeper/deleted/3d/agmdoc-cmd.tpl~35a32d60c0791c7f@1.3 +0 -0 + Delete: sntp/ag-tpl/agmdoc-cmd.tpl + + BitKeeper/deleted/97/mdoc2man~9f658b3ccb67c829@1.3 +0 -0 + Delete: sntp/ag-tpl/mdoc2man + + BitKeeper/deleted/bf/aginfo.tpl~67b16ec8b8871afe@1.2 +0 -0 + Delete: sntp/ag-tpl/aginfo.tpl + + BitKeeper/deleted/f2/cmd-doc.tlib~e5f798f139ab3308@1.5 +0 -0 + Delete: sntp/ag-tpl/cmd-doc.tlib + + ChangeLog@1.918 +1 -0 + More sntp.1 cleanups + + sntp/sntp-opts.def@1.32 +0 -10 + More sntp.1 cleanups + +ChangeSet@1.2461.1.6, 2011-06-05 11:23:00+00:00, davehart@shiny.ad.hartbrothers.com + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/ChangeLog@1.3 +40 -0 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/Makefile.am@1.1.1.3 +16 -1 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/README@1.3 +5 -0 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/buffer.c@1.4 +41 -16 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/configure.in@1.1.1.3 +15 -0 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/event.c@1.1.1.3 +5 -1 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/event_iocp.c@1.4 +4 -0 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/evport.c@1.1.1.2 +85 -112 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/evthread_win32.c@1.4 +4 -0 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/http.c@1.1.1.3 +45 -11 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/listener.c@1.4 +4 -0 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/select.c@1.1.1.2 +3 -3 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/test/regress_http.c@1.1.1.3 +3 -3 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + + sntp/libevent/test/regress_ssl.c@1.3 +1 -0 + Update to libevent HEAD as of 20110604, e40bafe796a8e544e9e54e247cb3aa30c95e06b0 + Snapshot of libevent 2.1, as of 2.0.12-stable release. + +ChangeSet@1.2461.1.5, 2011-06-05 11:16:07+00:00, davehart@shiny.ad.hartbrothers.com + cleanup arlib cruft. + add sntp/libevent/.git and .gitignore to ease shared bk/git repo for libevent upstream. + + BitKeeper/etc/ignore@1.77.1.1 +2 -4 + cleanup arlib cruft. + add sntp/libevent/.git and .gitignore to ease shared bk/git repo for libevent upstream. + + +ChangeSet@1.2546, 2011-06-04 04:22:32-04:00, stenn@psp-deb1.ntp.org + Produce ntpq.1 with the new autogen macros + + ChangeLog@1.917 +1 -0 + Produce ntpq.1 with the new autogen macros + + ntpq/Makefile.am@1.59 +6 -1 + Produce ntpq.1 with the new autogen macros + + ntpq/ntpq-opts.def@1.15 +254 -259 + Produce ntpq.1 with the new autogen macros + +ChangeSet@1.2545, 2011-06-04 02:57:47-04:00, stenn@psp-deb1.ntp.org + Remove the deprecated "detail" stanza from ntpdc-opts.def + + ChangeLog@1.916 +1 -0 + Remove the deprecated "detail" stanza from ntpdc-opts.def + + ntpdc/ntpdc-opts.def@1.18 +0 -20 + Remove the deprecated "detail" stanza from ntpdc-opts.def + +ChangeSet@1.2544, 2011-06-03 08:00:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P179 + TAG: NTP_4_2_7P179 + + ChangeLog@1.915 +1 -0 + NTP_4_2_7P179 + + ntpd/ntpd-opts.c@1.184 +3 -3 + NTP_4_2_7P179 + + ntpd/ntpd-opts.h@1.184 +3 -3 + NTP_4_2_7P179 + + ntpd/ntpd-opts.texi@1.182 +2 -2 + NTP_4_2_7P179 + + ntpd/ntpd.1@1.182 +2 -2 + NTP_4_2_7P179 + + ntpdc/ntpdc-opts.c@1.179 +3 -3 + NTP_4_2_7P179 + + ntpdc/ntpdc-opts.h@1.179 +3 -3 + NTP_4_2_7P179 + + ntpdc/ntpdc-opts.texi@1.179 +2 -2 + NTP_4_2_7P179 + + ntpdc/ntpdc.1@1.179 +5 -5 + NTP_4_2_7P179 + + ntpdc/ntpdc.html@1.7 +2 -2 + NTP_4_2_7P179 + + ntpq/ntpq-opts.c@1.181 +3 -3 + NTP_4_2_7P179 + + ntpq/ntpq-opts.h@1.181 +3 -3 + NTP_4_2_7P179 + + ntpq/ntpq-opts.texi@1.181 +2 -2 + NTP_4_2_7P179 + + ntpq/ntpq.1@1.181 +2 -2 + NTP_4_2_7P179 + + ntpsnmpd/ntpsnmpd-opts.c@1.181 +3 -3 + NTP_4_2_7P179 + + ntpsnmpd/ntpsnmpd-opts.h@1.181 +3 -3 + NTP_4_2_7P179 + + ntpsnmpd/ntpsnmpd-opts.texi@1.181 +2 -2 + NTP_4_2_7P179 + + ntpsnmpd/ntpsnmpd.1@1.181 +2 -2 + NTP_4_2_7P179 + + packageinfo.sh@1.182 +1 -1 + NTP_4_2_7P179 + + sntp/sntp-opts.c@1.175 +3 -3 + NTP_4_2_7P179 + + sntp/sntp-opts.h@1.175 +3 -3 + NTP_4_2_7P179 + + sntp/sntp-opts.texi@1.175 +2 -2 + NTP_4_2_7P179 + + sntp/sntp.1@1.175 +9 -5 + NTP_4_2_7P179 + + sntp/sntp.html@1.175 +2 -2 + NTP_4_2_7P179 + + util/ntp-keygen-opts.c@1.179 +3 -3 + NTP_4_2_7P179 + + util/ntp-keygen-opts.h@1.179 +3 -3 + NTP_4_2_7P179 + + util/ntp-keygen-opts.texi@1.182 +2 -2 + NTP_4_2_7P179 + + util/ntp-keygen.1@1.182 +2 -2 + NTP_4_2_7P179 + +ChangeSet@1.2543, 2011-06-03 02:55:13-04:00, stenn@psp-deb1.ntp.org + Upgrade local autoopts templates to 5.11.10pre5 + + ChangeLog@1.914 +1 -0 + Upgrade local autoopts templates to 5.11.10pre5 + + sntp/ag-tpl/agmdoc-cmd.tpl@1.2 +19 -18 + Upgrade local autoopts templates to 5.11.10pre5 + + sntp/ag-tpl/mdoc2man@1.2 +15 -12 + Upgrade local autoopts templates to 5.11.10pre5 + +ChangeSet@1.2542, 2011-06-02 15:51:22-04:00, stenn@psp-deb1.ntp.org + Update cmd-doc.tlib to autogen-5.11.10pre5 + + ChangeLog@1.913 +1 -0 + Update cmd-doc.tlib to autogen-5.11.10pre5 + + sntp/ag-tpl/cmd-doc.tlib@1.4 +10 -9 + Update cmd-doc.tlib to autogen-5.11.10pre5 + +ChangeSet@1.2541, 2011-06-02 07:29:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P178 + TAG: NTP_4_2_7P178 + + ChangeLog@1.912 +1 -0 + NTP_4_2_7P178 + + ntpd/ntpd-opts.c@1.183 +5 -4 + NTP_4_2_7P178 + + ntpd/ntpd-opts.h@1.183 +3 -3 + NTP_4_2_7P178 + + ntpd/ntpd-opts.texi@1.181 +2 -2 + NTP_4_2_7P178 + + ntpd/ntpd.1@1.181 +2 -2 + NTP_4_2_7P178 + + ntpdc/ntpdc-opts.c@1.178 +5 -4 + NTP_4_2_7P178 + + ntpdc/ntpdc-opts.h@1.178 +3 -3 + NTP_4_2_7P178 + + ntpdc/ntpdc-opts.texi@1.178 +2 -2 + NTP_4_2_7P178 + + ntpdc/ntpdc.1@1.178 +2 -2 + NTP_4_2_7P178 + + ntpdc/ntpdc.html@1.6 +2 -2 + NTP_4_2_7P178 + + ntpq/ntpq-opts.c@1.180 +5 -4 + NTP_4_2_7P178 + + ntpq/ntpq-opts.h@1.180 +3 -3 + NTP_4_2_7P178 + + ntpq/ntpq-opts.texi@1.180 +2 -2 + NTP_4_2_7P178 + + ntpq/ntpq.1@1.180 +2 -2 + NTP_4_2_7P178 + + ntpsnmpd/ntpsnmpd-opts.c@1.180 +5 -4 + NTP_4_2_7P178 + + ntpsnmpd/ntpsnmpd-opts.h@1.180 +3 -3 + NTP_4_2_7P178 + + ntpsnmpd/ntpsnmpd-opts.texi@1.180 +2 -2 + NTP_4_2_7P178 + + ntpsnmpd/ntpsnmpd.1@1.180 +2 -2 + NTP_4_2_7P178 + + packageinfo.sh@1.181 +1 -1 + NTP_4_2_7P178 + + sntp/sntp-opts.c@1.174 +5 -4 + NTP_4_2_7P178 + + sntp/sntp-opts.h@1.174 +3 -3 + NTP_4_2_7P178 + + sntp/sntp-opts.texi@1.174 +2 -2 + NTP_4_2_7P178 + + sntp/sntp.1@1.174 +2 -2 + NTP_4_2_7P178 + + sntp/sntp.html@1.174 +2 -2 + NTP_4_2_7P178 + + util/ntp-keygen-opts.c@1.178 +5 -4 + NTP_4_2_7P178 + + util/ntp-keygen-opts.h@1.178 +3 -3 + NTP_4_2_7P178 + + util/ntp-keygen-opts.texi@1.181 +2 -2 + NTP_4_2_7P178 + + util/ntp-keygen.1@1.181 +2 -2 + NTP_4_2_7P178 + +ChangeSet@1.2540, 2011-06-02 02:25:52-04:00, stenn@psp-deb1.ntp.org + Update the std_def_list to include the ntp.lic file. + + ChangeLog@1.911 +1 -0 + Update the std_def_list to include the ntp.lic file. + + ntpd/Makefile.am@1.105 +1 -0 + Update the std_def_list to include the ntp.lic file. + + ntpdc/Makefile.am@1.63 +1 -0 + Update the std_def_list to include the ntp.lic file. + + ntpq/Makefile.am@1.58 +1 -0 + Update the std_def_list to include the ntp.lic file. + + ntpsnmpd/Makefile.am@1.29 +1 -0 + Update the std_def_list to include the ntp.lic file. + + sntp/Makefile.am@1.63 +11 -3 + Update the std_def_list to include the ntp.lic file. + + util/Makefile.am@1.61 +1 -0 + Update the std_def_list to include the ntp.lic file. + +ChangeSet@1.2539, 2011-06-01 22:03:22-04:00, stenn@deacon.udel.edu + Distribute ntp.lic + + ChangeLog@1.910 +2 -0 + Distribute ntp.lic + +ChangeSet@1.2538, 2011-06-01 21:59:17-04:00, stenn@deacon.udel.edu + Distribute ntp.lic + + sntp/include/Makefile.am@1.2 +1 -0 + Distribute ntp.lic + + sntp/include/ntp.lic@1.4 +0 -0 + Rename: sntp/ag-tpl/ntp.lic -> sntp/include/ntp.lic + + sntp/ag-tpl/ntp.lic@1.3 +1 -0 + Add http://ntp.org/license to the ntp.lic file + +ChangeSet@1.2537, 2011-06-01 11:01:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P177 + TAG: NTP_4_2_7P177 + + ChangeLog@1.909 +1 -0 + NTP_4_2_7P177 + + ntpd/ntpd-opts.c@1.182 +21 -11 + NTP_4_2_7P177 + + ntpd/ntpd-opts.h@1.182 +4 -7 + NTP_4_2_7P177 + + ntpd/ntpd-opts.texi@1.180 +3 -3 + NTP_4_2_7P177 + + ntpd/ntpd.1@1.180 +4 -9 + NTP_4_2_7P177 + + ntpdc/ntpdc-opts.c@1.177 +21 -11 + NTP_4_2_7P177 + + ntpdc/ntpdc-opts.h@1.177 +4 -7 + NTP_4_2_7P177 + + ntpdc/ntpdc-opts.texi@1.177 +2 -2 + NTP_4_2_7P177 + + ntpdc/ntpdc.1@1.177 +3 -7 + NTP_4_2_7P177 + + ntpdc/ntpdc.html@1.5 +2 -2 + NTP_4_2_7P177 + + ntpq/ntpq-opts.c@1.179 +21 -11 + NTP_4_2_7P177 + + ntpq/ntpq-opts.h@1.179 +4 -7 + NTP_4_2_7P177 + + ntpq/ntpq-opts.texi@1.179 +3 -3 + NTP_4_2_7P177 + + ntpq/ntpq.1@1.179 +4 -9 + NTP_4_2_7P177 + + ntpsnmpd/ntpsnmpd-opts.c@1.179 +21 -11 + NTP_4_2_7P177 + + ntpsnmpd/ntpsnmpd-opts.h@1.179 +4 -7 + NTP_4_2_7P177 + + ntpsnmpd/ntpsnmpd-opts.texi@1.179 +3 -3 + NTP_4_2_7P177 + + ntpsnmpd/ntpsnmpd.1@1.179 +4 -9 + NTP_4_2_7P177 + + packageinfo.sh@1.180 +1 -1 + NTP_4_2_7P177 + + sntp/sntp-opts.c@1.173 +21 -11 + NTP_4_2_7P177 + + sntp/sntp-opts.h@1.173 +4 -7 + NTP_4_2_7P177 + + sntp/sntp-opts.texi@1.173 +2 -2 + NTP_4_2_7P177 + + sntp/sntp.1@1.173 +3 -7 + NTP_4_2_7P177 + + sntp/sntp.html@1.173 +2 -2 + NTP_4_2_7P177 + + util/ntp-keygen-opts.c@1.177 +21 -11 + NTP_4_2_7P177 + + util/ntp-keygen-opts.h@1.177 +4 -7 + NTP_4_2_7P177 + + util/ntp-keygen-opts.texi@1.180 +3 -3 + NTP_4_2_7P177 + + util/ntp-keygen.1@1.180 +4 -9 + NTP_4_2_7P177 + +ChangeSet@1.2536, 2011-06-01 03:26:00-04:00, stenn@deacon.udel.edu + Clean up the ntp.lic file + + ChangeLog@1.908 +1 -0 + Clean up the ntp.lic file + + sntp/ag-tpl/ntp.lic@1.2 +2 -2 + Clean up the ntp.lic file + +ChangeSet@1.2535, 2011-06-01 03:14:41-04:00, stenn@psp-deb1.ntp.org + Provide ntp.lic for the new autogen license template + + sntp/ag-tpl/ntp.lic@1.1 +15 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/ag-tpl/ntp.lic + + sntp/ag-tpl/ntp.lic@1.0 +0 -0 + +ChangeSet@1.2534, 2011-06-01 03:11:05-04:00, stenn@psp-deb1.ntp.org + Use the latest autogen's new copyright template code + + ChangeLog@1.907 +1 -0 + Use the latest autogen's new copyright template code + + ntpd/Makefile.am@1.104 +1 -1 + Use the latest autogen's new copyright template code + + ntpq/Makefile.am@1.57 +1 -1 + Use the latest autogen's new copyright template code + + ntpsnmpd/Makefile.am@1.28 +1 -1 + Use the latest autogen's new copyright template code + + sntp/include/copyright.def@1.18 +2 -6 + Use the latest autogen's new copyright template code + + util/Makefile.am@1.60 +1 -1 + Use the latest autogen's new copyright template code + +ChangeSet@1.2533, 2011-06-01 02:07:55-04:00, stenn@deacon.udel.edu + p176 cleaned up sntp docs and autogen doc templates + + ChangeLog@1.906 +2 -0 + p176 cleaned up sntp docs and autogen doc templates + +ChangeSet@1.2532, 2011-05-31 11:00:25+00:00, stenn@deacon.udel.edu + NTP_4_2_7P176 + TAG: NTP_4_2_7P176 + + ChangeLog@1.905 +1 -0 + NTP_4_2_7P176 + + ntpd/ntpd-opts.c@1.181 +3 -3 + NTP_4_2_7P176 + + ntpd/ntpd-opts.h@1.181 +3 -3 + NTP_4_2_7P176 + + ntpd/ntpd-opts.texi@1.179 +2 -2 + NTP_4_2_7P176 + + ntpd/ntpd.1@1.179 +2 -2 + NTP_4_2_7P176 + + ntpdc/ntpdc-opts.c@1.176 +3 -3 + NTP_4_2_7P176 + + ntpdc/ntpdc-opts.h@1.176 +3 -3 + NTP_4_2_7P176 + + ntpdc/ntpdc-opts.texi@1.176 +3 -3 + NTP_4_2_7P176 + + ntpdc/ntpdc.1@1.176 +2 -2 + NTP_4_2_7P176 + + ntpdc/ntpdc.html@1.4 +3 -3 + NTP_4_2_7P176 + + ntpq/ntpq-opts.c@1.178 +3 -3 + NTP_4_2_7P176 + + ntpq/ntpq-opts.h@1.178 +3 -3 + NTP_4_2_7P176 + + ntpq/ntpq-opts.texi@1.178 +2 -2 + NTP_4_2_7P176 + + ntpq/ntpq.1@1.178 +2 -2 + NTP_4_2_7P176 + + ntpsnmpd/ntpsnmpd-opts.c@1.178 +3 -3 + NTP_4_2_7P176 + + ntpsnmpd/ntpsnmpd-opts.h@1.178 +3 -3 + NTP_4_2_7P176 + + ntpsnmpd/ntpsnmpd-opts.texi@1.178 +2 -2 + NTP_4_2_7P176 + + ntpsnmpd/ntpsnmpd.1@1.178 +2 -2 + NTP_4_2_7P176 + + packageinfo.sh@1.179 +1 -1 + NTP_4_2_7P176 + + sntp/sntp-opts.c@1.172 +4 -10 + NTP_4_2_7P176 + + sntp/sntp-opts.h@1.172 +3 -3 + NTP_4_2_7P176 + + sntp/sntp-opts.texi@1.172 +4 -13 + NTP_4_2_7P176 + + sntp/sntp.1@1.172 +3 -3 + NTP_4_2_7P176 + + sntp/sntp.html@1.172 +4 -13 + NTP_4_2_7P176 + + util/ntp-keygen-opts.c@1.176 +3 -3 + NTP_4_2_7P176 + + util/ntp-keygen-opts.h@1.176 +3 -3 + NTP_4_2_7P176 + + util/ntp-keygen-opts.texi@1.179 +2 -2 + NTP_4_2_7P176 + + util/ntp-keygen.1@1.179 +2 -2 + NTP_4_2_7P176 + +ChangeSet@1.2529.1.1, 2011-05-30 11:16:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P175 + TAG: NTP_4_2_7P175 + + ChangeLog@1.902.1.1 +1 -0 + NTP_4_2_7P175 + + ntpd/ntpd-opts.c@1.180 +3 -3 + NTP_4_2_7P175 + + ntpd/ntpd-opts.h@1.180 +3 -3 + NTP_4_2_7P175 + + ntpd/ntpd-opts.texi@1.178 +2 -2 + NTP_4_2_7P175 + + ntpd/ntpd.1@1.178 +2 -2 + NTP_4_2_7P175 + + ntpdc/ntpdc-opts.c@1.175 +3 -3 + NTP_4_2_7P175 + + ntpdc/ntpdc-opts.h@1.175 +3 -3 + NTP_4_2_7P175 + + ntpdc/ntpdc-opts.texi@1.175 +2 -2 + NTP_4_2_7P175 + + ntpdc/ntpdc.1@1.175 +13 -12 + NTP_4_2_7P175 + + ntpdc/ntpdc.html@1.3 +2 -2 + NTP_4_2_7P175 + + ntpq/ntpq-opts.c@1.177 +3 -3 + NTP_4_2_7P175 + + ntpq/ntpq-opts.h@1.177 +3 -3 + NTP_4_2_7P175 + + ntpq/ntpq-opts.texi@1.177 +2 -2 + NTP_4_2_7P175 + + ntpq/ntpq.1@1.177 +2 -2 + NTP_4_2_7P175 + + ntpsnmpd/ntpsnmpd-opts.c@1.177 +3 -3 + NTP_4_2_7P175 + + ntpsnmpd/ntpsnmpd-opts.h@1.177 +3 -3 + NTP_4_2_7P175 + + ntpsnmpd/ntpsnmpd-opts.texi@1.177 +2 -2 + NTP_4_2_7P175 + + ntpsnmpd/ntpsnmpd.1@1.177 +2 -2 + NTP_4_2_7P175 + + packageinfo.sh@1.178 +1 -1 + NTP_4_2_7P175 + + sntp/sntp-opts.c@1.171 +3 -3 + NTP_4_2_7P175 + + sntp/sntp-opts.h@1.171 +3 -3 + NTP_4_2_7P175 + + sntp/sntp-opts.texi@1.171 +2 -2 + NTP_4_2_7P175 + + sntp/sntp.1@1.171 +9 -6 + NTP_4_2_7P175 + + sntp/sntp.html@1.171 +2 -2 + NTP_4_2_7P175 + + util/ntp-keygen-opts.c@1.175 +3 -3 + NTP_4_2_7P175 + + util/ntp-keygen-opts.h@1.175 +3 -3 + NTP_4_2_7P175 + + util/ntp-keygen-opts.texi@1.178 +2 -2 + NTP_4_2_7P175 + + util/ntp-keygen.1@1.178 +2 -2 + NTP_4_2_7P175 + +ChangeSet@1.2530, 2011-05-30 04:44:11-04:00, stenn@psp-deb1.ntp.org + sntp documentation updates + + ChangeLog@1.903 +1 -0 + sntp documentation cleanup + + sntp/ag-tpl/aginfo.tpl@1.1 +308 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/ag-tpl/aginfo.tpl + + sntp/ag-tpl/aginfo.tpl@1.0 +0 -0 + + sntp/ag-tpl/mdoc2man@1.1 +284 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/ag-tpl/mdoc2man + + sntp/ag-tpl/mdoc2man@1.0 +0 -0 + + sntp/sntp-opts.def@1.31 +31 -42 + documentation cleanup + +ChangeSet@1.2529, 2011-05-29 21:36:04-04:00, stenn@psp-deb1.ntp.org + cmd-doc.tlib cleanup from Bruce Korb + + ChangeLog@1.902 +1 -0 + cmd-doc.tlib cleanup from Bruce Korb + + sntp/ag-tpl/cmd-doc.tlib@1.3 +50 -35 + cmd-doc.tlib cleanup from Bruce Korb + +ChangeSet@1.2528, 2011-05-29 21:28:17-04:00, stenn@psp-deb1.ntp.org + [Bug 1936] Correctly set IPV6_MULTICAST_LOOP + + ChangeLog@1.901 +1 -0 + [Bug 1936] Correctly set IPV6_MULTICAST_LOOP + + ntpd/ntp_io.c@1.356 +7 -2 + [Bug 1936] Correctly set IPV6_MULTICAST_LOOP + +ChangeSet@1.2527, 2011-05-28 11:03:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P174 + TAG: NTP_4_2_7P174 + + ChangeLog@1.900 +1 -0 + NTP_4_2_7P174 + + ntpd/ntpd-opts.c@1.179 +7 -7 + NTP_4_2_7P174 + + ntpd/ntpd-opts.h@1.179 +5 -5 + NTP_4_2_7P174 + + ntpd/ntpd-opts.texi@1.177 +2 -2 + NTP_4_2_7P174 + + ntpd/ntpd.1@1.177 +4 -4 + NTP_4_2_7P174 + + ntpdc/ntpdc-opts.c@1.174 +95 -95 + NTP_4_2_7P174 + + ntpdc/ntpdc-opts.h@1.174 +36 -36 + NTP_4_2_7P174 + + ntpdc/ntpdc-opts.texi@1.174 +20 -22 + NTP_4_2_7P174 + + ntpdc/ntpdc.1@1.174 +719 -86 + NTP_4_2_7P174 + + ntpdc/ntpdc.html@1.2 +50 -73 + NTP_4_2_7P174 + + ntpq/ntpq-opts.c@1.176 +10 -10 + NTP_4_2_7P174 + + ntpq/ntpq-opts.h@1.176 +5 -5 + NTP_4_2_7P174 + + ntpq/ntpq-opts.texi@1.176 +7 -10 + NTP_4_2_7P174 + + ntpq/ntpq.1@1.176 +8 -9 + NTP_4_2_7P174 + + ntpsnmpd/ntpsnmpd-opts.c@1.176 +7 -7 + NTP_4_2_7P174 + + ntpsnmpd/ntpsnmpd-opts.h@1.176 +5 -5 + NTP_4_2_7P174 + + ntpsnmpd/ntpsnmpd-opts.texi@1.176 +2 -2 + NTP_4_2_7P174 + + ntpsnmpd/ntpsnmpd.1@1.176 +4 -4 + NTP_4_2_7P174 + + packageinfo.sh@1.177 +1 -1 + NTP_4_2_7P174 + + sntp/sntp-opts.c@1.170 +15 -13 + NTP_4_2_7P174 + + sntp/sntp-opts.h@1.170 +5 -5 + NTP_4_2_7P174 + + sntp/sntp-opts.texi@1.170 +21 -20 + NTP_4_2_7P174 + + sntp/sntp.1@1.170 +27 -36 + NTP_4_2_7P174 + + sntp/sntp.html@1.170 +19 -22 + NTP_4_2_7P174 + + util/ntp-keygen-opts.c@1.174 +10 -10 + NTP_4_2_7P174 + + util/ntp-keygen-opts.h@1.174 +5 -5 + NTP_4_2_7P174 + + util/ntp-keygen-opts.texi@1.177 +8 -9 + NTP_4_2_7P174 + + util/ntp-keygen.1@1.177 +8 -9 + NTP_4_2_7P174 + +ChangeSet@1.2526, 2011-05-27 16:40:04-04:00, stenn@psp-deb1.ntp.org + sntp documentation cleanup + + sntp/include/debug-opt.def@1.7 +4 -7 + sntp documentation cleanup + + sntp/sntp-opts.def@1.30 +9 -9 + sntp documentation cleanup + +ChangeSet@1.2525, 2011-05-27 06:32:14-04:00, stenn@psp-deb1.ntp.org + sntp documentation cleanup (for autogen) + + ChangeLog@1.899 +1 -0 + sntp documentation cleanup (for autogen) + + sntp/ag-tpl/cmd-doc.tlib@1.2 +42 -151 + documentation cleanup (for autogen) + + sntp/include/copyright.def@1.17 +2 -2 + documentation cleanup (for autogen) + + sntp/sntp-opts.def@1.29 +28 -5 + documentation cleanup (for autogen) + +ChangeSet@1.2524, 2011-05-27 05:15:52-04:00, stenn@psp-deb1.ntp.org + ntpdc documentation cleanup + + ChangeLog@1.898 +1 -0 + ntpdc documentation cleanup + + ntpdc/ntpdc-opts.def@1.17 +4 -2 + ntpdc documentation cleanup + +ChangeSet@1.2523, 2011-05-26 18:54:06-04:00, stenn@psp-deb1.ntp.org + Don't build libevent with openssl support + + ChangeLog@1.897 +2 -0 + Don't build libevent with openssl support + + sntp/m4/ntp_libevent.m4@1.8 +1 -0 + Don't build libevent with openssl support + +ChangeSet@1.2461.1.4, 2011-05-26 07:10:45+00:00, davehart@shiny.ad.hartbrothers.com + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/ChangeLog@1.2 +84 -0 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/Makefile.am@1.1.1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/Makefile.nmake@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/README@1.2 +8 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/WIN32-Code/event2/event-config.h@1.1.1.2 +3 -0 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/arc4random.c@1.1.1.2 +5 -5 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/buffer.c@1.3 +12 -12 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/bufferevent-internal.h@1.3 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/bufferevent.c@1.3 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/bufferevent_async.c@1.3 +10 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/bufferevent_filter.c@1.3 +2 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/bufferevent_openssl.c@1.3 +2 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/bufferevent_pair.c@1.3 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/bufferevent_sock.c@1.3 +7 -6 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/compat/sys/queue.h@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/configure.in@1.1.1.2 +58 -25 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evbuffer-internal.h@1.3 +4 -4 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evdns.3@1.1 +322 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/evdns.3 + + sntp/libevent/evdns.3@1.0 +0 -0 + + sntp/libevent/evdns.c@1.1.1.3 +20 -8 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/event-internal.h@1.1.1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/event.3@1.1 +624 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/event.3 + + sntp/libevent/event.3@1.0 +0 -0 + + sntp/libevent/event.c@1.1.1.2 +12 -12 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/event.h@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/event_iocp.c@1.3 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/event_tagging.c@1.3 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evmap.c@1.3 +4 -4 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evrpc.c@1.3 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evthread-internal.h@1.3 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evthread.c@1.1.1.2 +1 -0 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evthread_win32.c@1.3 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/evutil.c@1.1.1.2 +19 -19 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/http.c@1.1.1.2 +165 -55 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/include/Makefile.am@1.1.1.1 +9 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/include/event2/dns.h@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/include/event2/dns_compat.h@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/include/event2/event.h@1.1.1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/include/event2/rpc.h@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/include/event2/thread.h@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/include/event2/util.h@1.2 +8 -8 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/iocp-internal.h@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/kqueue.c@1.3 +37 -9 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/libevent_openssl.pc.in@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/listener.c@1.3 +6 -6 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/log.c@1.3 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/m4/ac_backport_259_ssizet.m4@1.1 +3 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/m4/ac_backport_259_ssizet.m4 + + sntp/libevent/m4/ac_backport_259_ssizet.m4@1.0 +0 -0 + + sntp/libevent/make_epoll_table.py@1.1 +57 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/make_epoll_table.py + + sntp/libevent/make_epoll_table.py@1.0 +0 -0 + + sntp/libevent/sample/Makefile.am@1.1.1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/sample/dns-example.c@1.1.1.2 +4 -5 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/sample/event-test.c@1.2 +6 -6 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/sample/hello-world.c@1.1.1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/sample/http-server.c@1.1.1.3 +11 -8 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/sample/le-proxy.c@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/sample/signal-test.c@1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/sample/time-test.c@1.2 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/signal.c@1.3 +5 -5 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/Makefile.am@1.1.1.2 +6 -4 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/Makefile.nmake@1.2 +1 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/bench.c@1.2 +11 -6 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/bench_cascade.c@1.2 +10 -5 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/bench_http.c@1.2 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/bench_httpclient.c@1.1.1.2 +9 -6 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress.c@1.2 +28 -16 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_buffer.c@1.3 +4 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_bufferevent.c@1.2 +5 -5 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_dns.c@1.1.1.2 +5 -6 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_et.c@1.2 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_http.c@1.1.1.2 +67 -4 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_listener.c@1.1.1.2 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_main.c@1.3 +9 -9 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_rpc.c@1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_ssl.c@1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_testutils.c@1.1.1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_thread.c@1.2 +5 -5 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_util.c@1.2 +7 -7 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/regress_zlib.c@1.2 +25 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/test-changelist.c@1.2 +7 -7 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/test-eof.c@1.1.1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/test-init.c@1.2 +2 -2 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/test-ratelim.c@1.1.1.2 +5 -5 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/test-time.c@1.2 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/test-weof.c@1.2 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/tinytest.c@1.2 +4 -4 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/test/tinytest_local.h@1.2 +4 -1 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + + sntp/libevent/util-internal.h@1.1.1.2 +3 -3 + libevent HEAD (will be 2.1) 20110526 95f70166df3bc9c0817ef98aa3711564300d5bb3 + +ChangeSet@1.2517.1.14, 2011-05-25 19:29:28+00:00, stenn@deacon.udel.edu + NTP_4_2_7P173 + TAG: NTP_4_2_7P173 + + ChangeLog@1.896 +1 -0 + NTP_4_2_7P173 + + ntpd/ntpd-opts.c@1.178 +3 -3 + NTP_4_2_7P173 + + ntpd/ntpd-opts.h@1.178 +3 -3 + NTP_4_2_7P173 + + ntpd/ntpd-opts.texi@1.176 +2 -2 + NTP_4_2_7P173 + + ntpd/ntpd.1@1.176 +2 -2 + NTP_4_2_7P173 + + ntpdc/ntpdc-opts.c@1.170.1.5 +3 -3 + NTP_4_2_7P173 + + ntpdc/ntpdc-opts.h@1.170.1.5 +3 -3 + NTP_4_2_7P173 + + ntpdc/ntpdc-opts.texi@1.170.1.5 +2 -2 + NTP_4_2_7P173 + + ntpdc/ntpdc.1@1.170.1.5 +2 -2 + NTP_4_2_7P173 + + ntpq/ntpq-opts.c@1.175 +3 -3 + NTP_4_2_7P173 + + ntpq/ntpq-opts.h@1.175 +3 -3 + NTP_4_2_7P173 + + ntpq/ntpq-opts.texi@1.175 +2 -2 + NTP_4_2_7P173 + + ntpq/ntpq.1@1.175 +2 -2 + NTP_4_2_7P173 + + ntpsnmpd/ntpsnmpd-opts.c@1.175 +3 -3 + NTP_4_2_7P173 + + ntpsnmpd/ntpsnmpd-opts.h@1.175 +3 -3 + NTP_4_2_7P173 + + ntpsnmpd/ntpsnmpd-opts.texi@1.175 +2 -2 + NTP_4_2_7P173 + + ntpsnmpd/ntpsnmpd.1@1.175 +2 -2 + NTP_4_2_7P173 + + packageinfo.sh@1.176 +1 -1 + NTP_4_2_7P173 + + sntp/sntp-opts.c@1.169 +3 -3 + NTP_4_2_7P173 + + sntp/sntp-opts.h@1.169 +3 -3 + NTP_4_2_7P173 + + sntp/sntp-opts.texi@1.169 +2 -2 + NTP_4_2_7P173 + + sntp/sntp.1@1.169 +2 -2 + NTP_4_2_7P173 + + sntp/sntp.html@1.169 +2 -2 + NTP_4_2_7P173 + + util/ntp-keygen-opts.c@1.173 +3 -3 + NTP_4_2_7P173 + + util/ntp-keygen-opts.h@1.173 +3 -3 + NTP_4_2_7P173 + + util/ntp-keygen-opts.texi@1.176 +2 -2 + NTP_4_2_7P173 + + util/ntp-keygen.1@1.176 +2 -2 + NTP_4_2_7P173 + +ChangeSet@1.2517.2.1, 2011-05-25 07:35:27+00:00, davehart@shiny.ad.hartbrothers.com + parsesolaris.c compile fails on SPARC Solaris with conflicting printf. + ntp_util.c compile fails on AIX and OSF with conflicting statsdir. + + ChangeLog@1.893.1.1 +2 -0 + parsesolaris.c compile fails on SPARC Solaris with conflicting printf. + ntp_util.c compile fails on AIX and OSF with conflicting statsdir. + + + include/ntp_fp.h@1.24 +11 -2 + parsesolaris.c compile fails on SPARC Solaris with conflicting printf. + + include/ntpd.h@1.163 +1 -4 + ntp_util.c compile fails on AIX and OSF with conflicting statsdir. + + ntpd/ntp_util.c@1.96 +1 -1 + ntp_util.c compile fails on AIX and OSF with conflicting statsdir. + +ChangeSet@1.2082.4.212, 2011-05-25 05:27:31+00:00, stenn@deacon.udel.edu + NTP_4_2_6P4_BETA2 + TAG: NTP_4_2_6P4_BETA2 + + ChangeLog@1.496.26.148 +1 -0 + NTP_4_2_6P4_BETA2 + + ntpd/ntpd-opts.c@1.248.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpd/ntpd-opts.h@1.248.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpd/ntpd-opts.texi@1.246.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + + ntpd/ntpd.1@1.246.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + + ntpdc/ntpdc-opts.c@1.244.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpdc/ntpdc-opts.h@1.244.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpdc/ntpdc-opts.texi@1.243.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + + ntpdc/ntpdc.1@1.243.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + + ntpq/ntpq-opts.c@1.245.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpq/ntpq-opts.h@1.245.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpq/ntpq-opts.texi@1.244.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + + ntpq/ntpq.1@1.244.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.37.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.37.1 +3 -3 + NTP_4_2_6P4_BETA2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.36.1 +2 -2 + NTP_4_2_6P4_BETA2 + + ntpsnmpd/ntpsnmpd.1@1.122.36.1 +2 -2 + NTP_4_2_6P4_BETA2 + + packageinfo.sh@1.255.33.1 +1 -1 + NTP_4_2_6P4_BETA2 + + sntp/sntp-opts.c@1.117.34.1 +3 -3 + NTP_4_2_6P4_BETA2 + + sntp/sntp-opts.h@1.117.34.1 +3 -3 + NTP_4_2_6P4_BETA2 + + sntp/sntp-opts.texi@1.117.33.1 +2 -2 + NTP_4_2_6P4_BETA2 + + sntp/sntp.1@1.117.33.1 +2 -2 + NTP_4_2_6P4_BETA2 + + sntp/sntp.html@1.7.34.1 +2 -2 + NTP_4_2_6P4_BETA2 + + util/ntp-keygen-opts.c@1.247.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + util/ntp-keygen-opts.h@1.247.36.1 +3 -3 + NTP_4_2_6P4_BETA2 + + util/ntp-keygen-opts.texi@1.246.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + + util/ntp-keygen.1@1.246.35.1 +2 -2 + NTP_4_2_6P4_BETA2 + +ChangeSet@1.2517.1.10, 2011-05-25 03:52:15+00:00, davehart@shiny.ad.hartbrothers.com + typo in #ifndef EREALLOC_CALLSITE hides file/line number from + emalloc() error message where available. + + libntp/emalloc.c@1.15 +1 -1 + typo in #ifndef EREALLOC_CALLSITE hides file/line number from + emalloc() error message where available. + +ChangeSet@1.2082.4.211, 2011-05-25 03:44:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1695] ntpdate takes longer than necessary. + [Bug 1832] ntpdate doesn't allow timeout > 2s. + [Bug 1933] WWVB/Spectracom driver timestamps LFs, not CRs. + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + + ChangeLog@1.496.26.147 +7 -0 + [Bug 1695] ntpdate takes longer than necessary. + [Bug 1832] ntpdate doesn't allow timeout > 2s. + [Bug 1933] WWVB/Spectracom driver timestamps LFs, not CRs. + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + + include/ntp_assert.h@1.3.1.1 +54 -17 + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + + include/ntp_malloc.h@1.3.1.1 +46 -4 + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + + include/ntp_refclock.h@1.24.1.1 +1 -1 + Use void * instead of char * for pp->unitptr to ease backports from 4.2.7. + + include/ntp_stdlib.h@1.40.1.5 +37 -14 + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + + include/ntp_types.h@1.14.1.1 +7 -0 + provide TRUE, FALSE definitions. + + libntp/emalloc.c@1.10.1.1 +53 -79 + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + + libntp/msyslog.c@1.24.1.4 +80 -7 + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + + libntp/strdup.c@1.5.1.1 +16 -14 + include first, include to resolve incompatible + implicit declaration warnings. + + ntpd/refclock_wwvb.c@1.24.1.1 +61 -23 + [Bug 1933] WWVB/Spectracom driver timestamps LFs, not CRs. + + ntpdate/ntpdate.c@1.69.2.3 +50 -92 + [Bug 1695] ntpdate takes longer than necessary. + [Bug 1832] ntpdate doesn't allow timeout > 2s. + + + ports/winnt/include/config.h@1.79.1.6 +2 -0 + Backport utility routines from ntp-dev: mprintf(), emalloc_zero(). + +ChangeSet@1.2517.1.9, 2011-05-24 06:09:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P172 + TAG: NTP_4_2_7P172 + + ChangeLog@1.892 +1 -0 + NTP_4_2_7P172 + + ntpd/ntpd-opts.c@1.177 +3 -3 + NTP_4_2_7P172 + + ntpd/ntpd-opts.h@1.177 +3 -3 + NTP_4_2_7P172 + + ntpd/ntpd-opts.texi@1.175 +2 -2 + NTP_4_2_7P172 + + ntpd/ntpd.1@1.175 +2 -2 + NTP_4_2_7P172 + + ntpdc/ntpdc-opts.c@1.170.1.4 +3 -3 + NTP_4_2_7P172 + + ntpdc/ntpdc-opts.h@1.170.1.4 +3 -3 + NTP_4_2_7P172 + + ntpdc/ntpdc-opts.texi@1.170.1.4 +2 -2 + NTP_4_2_7P172 + + ntpdc/ntpdc.1@1.170.1.4 +2 -2 + NTP_4_2_7P172 + + ntpq/ntpq-opts.c@1.174 +3 -3 + NTP_4_2_7P172 + + ntpq/ntpq-opts.h@1.174 +3 -3 + NTP_4_2_7P172 + + ntpq/ntpq-opts.texi@1.174 +2 -2 + NTP_4_2_7P172 + + ntpq/ntpq.1@1.174 +2 -2 + NTP_4_2_7P172 + + ntpsnmpd/ntpsnmpd-opts.c@1.174 +3 -3 + NTP_4_2_7P172 + + ntpsnmpd/ntpsnmpd-opts.h@1.174 +3 -3 + NTP_4_2_7P172 + + ntpsnmpd/ntpsnmpd-opts.texi@1.174 +2 -2 + NTP_4_2_7P172 + + ntpsnmpd/ntpsnmpd.1@1.174 +2 -2 + NTP_4_2_7P172 + + packageinfo.sh@1.175 +1 -1 + NTP_4_2_7P172 + + sntp/sntp-opts.c@1.168 +3 -3 + NTP_4_2_7P172 + + sntp/sntp-opts.h@1.168 +3 -3 + NTP_4_2_7P172 + + sntp/sntp-opts.texi@1.168 +2 -2 + NTP_4_2_7P172 + + sntp/sntp.1@1.168 +2 -2 + NTP_4_2_7P172 + + sntp/sntp.html@1.168 +2 -2 + NTP_4_2_7P172 + + util/ntp-keygen-opts.c@1.172 +3 -3 + NTP_4_2_7P172 + + util/ntp-keygen-opts.h@1.172 +3 -3 + NTP_4_2_7P172 + + util/ntp-keygen-opts.texi@1.175 +2 -2 + NTP_4_2_7P172 + + util/ntp-keygen.1@1.175 +2 -2 + NTP_4_2_7P172 + +ChangeSet@1.2517.1.8, 2011-05-24 05:27:19+00:00, davehart@shiny.ad.hartbrothers.com + Remove hardcoded 1/960 s. fudge for transmission time at 9600 8n1 + from WWVB/Spectracom driver introduced in 4.2.7p169. + + ChangeLog@1.891 +2 -0 + Remove hardcoded 1/960 s. fudge for transmission time at 9600 8n1 + from WWVB/Spectracom driver introduced in 4.2.7p169. + + ntpd/refclock_wwvb.c@1.30 +0 -7 + Remove hardcoded 1/960 s. fudge for transmission time at 9600 8n1 + from WWVB/Spectracom driver introduced in 4.2.7p169. + +ChangeSet@1.2517.1.7, 2011-05-23 06:42:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P171 + TAG: NTP_4_2_7P171 + + ChangeLog@1.890 +1 -0 + NTP_4_2_7P171 + + ntpd/ntpd-opts.c@1.176 +3 -3 + NTP_4_2_7P171 + + ntpd/ntpd-opts.h@1.176 +3 -3 + NTP_4_2_7P171 + + ntpd/ntpd-opts.texi@1.174 +2 -2 + NTP_4_2_7P171 + + ntpd/ntpd.1@1.174 +2 -2 + NTP_4_2_7P171 + + ntpdc/ntpdc-opts.c@1.170.1.3 +3 -3 + NTP_4_2_7P171 + + ntpdc/ntpdc-opts.h@1.170.1.3 +3 -3 + NTP_4_2_7P171 + + ntpdc/ntpdc-opts.texi@1.170.1.3 +2 -2 + NTP_4_2_7P171 + + ntpdc/ntpdc.1@1.170.1.3 +2 -2 + NTP_4_2_7P171 + + ntpq/ntpq-opts.c@1.173 +3 -3 + NTP_4_2_7P171 + + ntpq/ntpq-opts.h@1.173 +3 -3 + NTP_4_2_7P171 + + ntpq/ntpq-opts.texi@1.173 +2 -2 + NTP_4_2_7P171 + + ntpq/ntpq.1@1.173 +2 -2 + NTP_4_2_7P171 + + ntpsnmpd/ntpsnmpd-opts.c@1.173 +3 -3 + NTP_4_2_7P171 + + ntpsnmpd/ntpsnmpd-opts.h@1.173 +3 -3 + NTP_4_2_7P171 + + ntpsnmpd/ntpsnmpd-opts.texi@1.173 +2 -2 + NTP_4_2_7P171 + + ntpsnmpd/ntpsnmpd.1@1.173 +2 -2 + NTP_4_2_7P171 + + packageinfo.sh@1.174 +1 -1 + NTP_4_2_7P171 + + sntp/sntp-opts.c@1.167 +3 -3 + NTP_4_2_7P171 + + sntp/sntp-opts.h@1.167 +3 -3 + NTP_4_2_7P171 + + sntp/sntp-opts.texi@1.167 +2 -2 + NTP_4_2_7P171 + + sntp/sntp.1@1.167 +2 -2 + NTP_4_2_7P171 + + sntp/sntp.html@1.167 +2 -2 + NTP_4_2_7P171 + + util/ntp-keygen-opts.c@1.171 +3 -3 + NTP_4_2_7P171 + + util/ntp-keygen-opts.h@1.171 +3 -3 + NTP_4_2_7P171 + + util/ntp-keygen-opts.texi@1.174 +2 -2 + NTP_4_2_7P171 + + util/ntp-keygen.1@1.174 +2 -2 + NTP_4_2_7P171 + +ChangeSet@1.2517.1.6, 2011-05-23 02:28:42-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.889 +1 -0 + Documentation updates from Dave Mills + + html/discipline.html@1.4 +8 -8 + Documentation updates from Dave Mills + + html/ntpq.html@1.44 +41 -35 + Documentation updates from Dave Mills + + html/warp.html@1.14 +4 -3 + Documentation updates from Dave Mills + + html/xleave.html@1.7 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2517.1.5, 2011-05-23 04:26:31+00:00, davehart@shiny.ad.hartbrothers.com + Eliminate warnings about shadowing global "basename" on Linux. + Use filegen_config() consistently when changing filegen options. + mprintf() should go to stdout, not stderr. + Repair a few simulator problems (more remain). + + ChangeLog@1.888 +4 -0 + Eliminate warnings about shadowing global "basename" on Linux. + Use filegen_config() consistently when changing filegen options. + mprintf() should go to stdout, not stderr. + Repair a few simulator problems (more remain). + + include/ntp_filegen.h@1.10 +13 -12 + Eliminate warnings about shadowing global "basename" on Linux. + Use filegen_config() consistently when changing filegen options. + + include/ntpd.h@1.162 +10 -4 + expose statsdir globally + + include/ntpsim.h@1.16 +18 -20 + whitespace -> tabs + + libntp/msyslog.c@1.43 +1 -1 + mprintf() should go to stdout, not stderr. + + libntp/systime.c@1.55 +2 -13 + remove empty #else block for SIM + + ntpd/ntp_config.c@1.290 +13 -8 + Eliminate warnings about shadowing global "basename" on Linux. + Use filegen_config() consistently when changing filegen options. + + ntpd/ntp_filegen.c@1.24 +102 -71 + Eliminate warnings about shadowing global "basename" on Linux. + Use filegen_config() consistently when changing filegen options. + + ntpd/ntp_io.c@1.355 +71 -0 + Move select_peerinterface() from ntp_peer.c to ntp_io.c so it can + use #ifdef SIM. + + ntpd/ntp_monitor.c@1.39 +1 -1 + struct interface -> endpt + + ntpd/ntp_peer.c@1.147 +25 -95 + Move select_peerinterface() from ntp_peer.c to ntp_io.c so it can + use #ifdef SIM. + + ntpd/ntp_util.c@1.95 +9 -70 + Eliminate warnings about shadowing global "basename" on Linux. + Use filegen_config() consistently when changing filegen options. + + ntpd/ntpsim.c@1.32 +87 -50 + Set msyslog_term = TRUE in ntpsim() to get syslog messages on console. + Use HTONL_FP() and NTOHL_FP() to byteswap simulated on-wire timestamps. + Use loopback IPv4 interface for simulator peer->dstadr. + + ntpd/refclock_wwvb.c@1.29 +6 -0 + timestamp 'T' polls in -D1 output + +ChangeSet@1.2517.1.4, 2011-05-19 11:26:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P170 + TAG: NTP_4_2_7P170 + + ChangeLog@1.887 +1 -0 + NTP_4_2_7P170 + + ntpd/ntpd-opts.c@1.175 +3 -3 + NTP_4_2_7P170 + + ntpd/ntpd-opts.h@1.175 +3 -3 + NTP_4_2_7P170 + + ntpd/ntpd-opts.texi@1.173 +2 -2 + NTP_4_2_7P170 + + ntpd/ntpd.1@1.173 +2 -2 + NTP_4_2_7P170 + + ntpdc/ntpdc-opts.c@1.170.1.2 +3 -3 + NTP_4_2_7P170 + + ntpdc/ntpdc-opts.h@1.170.1.2 +3 -3 + NTP_4_2_7P170 + + ntpdc/ntpdc-opts.texi@1.170.1.2 +2 -2 + NTP_4_2_7P170 + + ntpdc/ntpdc.1@1.170.1.2 +2 -2 + NTP_4_2_7P170 + + ntpq/ntpq-opts.c@1.172 +3 -3 + NTP_4_2_7P170 + + ntpq/ntpq-opts.h@1.172 +3 -3 + NTP_4_2_7P170 + + ntpq/ntpq-opts.texi@1.172 +2 -2 + NTP_4_2_7P170 + + ntpq/ntpq.1@1.172 +2 -2 + NTP_4_2_7P170 + + ntpsnmpd/ntpsnmpd-opts.c@1.172 +3 -3 + NTP_4_2_7P170 + + ntpsnmpd/ntpsnmpd-opts.h@1.172 +3 -3 + NTP_4_2_7P170 + + ntpsnmpd/ntpsnmpd-opts.texi@1.172 +2 -2 + NTP_4_2_7P170 + + ntpsnmpd/ntpsnmpd.1@1.172 +2 -2 + NTP_4_2_7P170 + + packageinfo.sh@1.173 +1 -1 + NTP_4_2_7P170 + + sntp/sntp-opts.c@1.166 +3 -3 + NTP_4_2_7P170 + + sntp/sntp-opts.h@1.166 +3 -3 + NTP_4_2_7P170 + + sntp/sntp-opts.texi@1.166 +2 -2 + NTP_4_2_7P170 + + sntp/sntp.1@1.166 +2 -2 + NTP_4_2_7P170 + + sntp/sntp.html@1.166 +2 -2 + NTP_4_2_7P170 + + util/ntp-keygen-opts.c@1.170 +3 -3 + NTP_4_2_7P170 + + util/ntp-keygen-opts.h@1.170 +3 -3 + NTP_4_2_7P170 + + util/ntp-keygen-opts.texi@1.173 +2 -2 + NTP_4_2_7P170 + + util/ntp-keygen.1@1.173 +2 -2 + NTP_4_2_7P170 + +ChangeSet@1.2517.1.3, 2011-05-19 02:46:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1932] libevent/util_internal.h builtin_expect compile error with + gcc 2.95. + Use 64-bit scalars in LFPTOD() and DTOLFP() on more platforms by + conditionalizing on HAVE_U_INT64 rather than UINT64_MAX. + + ChangeLog@1.886 +5 -1 + [Bug 1932] libevent/util_internal.h builtin_expect compile error with + gcc 2.95. + Use 64-bit scalars in LFPTOD() and DTOLFP() on more platforms by + conditionalizing on HAVE_U_INT64 rather than UINT64_MAX. + + + include/ntp_fp.h@1.23 +12 -8 + Use 64-bit scalars in LFPTOD() and DTOLFP() on more platforms by + conditionalizing on HAVE_U_INT64 rather than UINT64_MAX. + + sntp/libevent/util-internal.h@1.4 +1 -1 + [Bug 1932] libevent/util_internal.h builtin_expect compile error with + gcc 2.95. + +ChangeSet@1.2517.1.2, 2011-05-18 11:24:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P169 + TAG: NTP_4_2_7P169 + + ChangeLog@1.885 +1 -0 + NTP_4_2_7P169 + + ntpd/ntpd-opts.c@1.174 +3 -3 + NTP_4_2_7P169 + + ntpd/ntpd-opts.h@1.174 +3 -3 + NTP_4_2_7P169 + + ntpd/ntpd-opts.texi@1.172 +2 -2 + NTP_4_2_7P169 + + ntpd/ntpd.1@1.172 +2 -2 + NTP_4_2_7P169 + + ntpdc/ntpdc-opts.c@1.170.1.1 +3 -3 + NTP_4_2_7P169 + + ntpdc/ntpdc-opts.h@1.170.1.1 +3 -3 + NTP_4_2_7P169 + + ntpdc/ntpdc-opts.texi@1.170.1.1 +2 -2 + NTP_4_2_7P169 + + ntpdc/ntpdc.1@1.170.1.1 +2 -2 + NTP_4_2_7P169 + + ntpq/ntpq-opts.c@1.171 +3 -3 + NTP_4_2_7P169 + + ntpq/ntpq-opts.h@1.171 +3 -3 + NTP_4_2_7P169 + + ntpq/ntpq-opts.texi@1.171 +2 -2 + NTP_4_2_7P169 + + ntpq/ntpq.1@1.171 +2 -2 + NTP_4_2_7P169 + + ntpsnmpd/ntpsnmpd-opts.c@1.171 +3 -3 + NTP_4_2_7P169 + + ntpsnmpd/ntpsnmpd-opts.h@1.171 +3 -3 + NTP_4_2_7P169 + + ntpsnmpd/ntpsnmpd-opts.texi@1.171 +2 -2 + NTP_4_2_7P169 + + ntpsnmpd/ntpsnmpd.1@1.171 +2 -2 + NTP_4_2_7P169 + + packageinfo.sh@1.172 +1 -1 + NTP_4_2_7P169 + + sntp/sntp-opts.c@1.165 +3 -3 + NTP_4_2_7P169 + + sntp/sntp-opts.h@1.165 +3 -3 + NTP_4_2_7P169 + + sntp/sntp-opts.texi@1.165 +2 -2 + NTP_4_2_7P169 + + sntp/sntp.1@1.165 +2 -2 + NTP_4_2_7P169 + + sntp/sntp.html@1.165 +2 -2 + NTP_4_2_7P169 + + util/ntp-keygen-opts.c@1.169 +3 -3 + NTP_4_2_7P169 + + util/ntp-keygen-opts.h@1.169 +3 -3 + NTP_4_2_7P169 + + util/ntp-keygen-opts.texi@1.172 +2 -2 + NTP_4_2_7P169 + + util/ntp-keygen.1@1.172 +2 -2 + NTP_4_2_7P169 + +ChangeSet@1.2520, 2011-05-18 04:48:08-04:00, stenn@psp-deb1.ntp.org + More cleanup around autogen-erating ntpdc.1 and ntpdc.html + + sntp/ag-tpl/cmd-doc.tlib@1.1 +943 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/ag-tpl/cmd-doc.tlib + + sntp/ag-tpl/cmd-doc.tlib@1.0 +0 -0 + + sntp/ag-tpl/mdoc2mdoc@1.1 +2 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/ag-tpl/mdoc2mdoc + + sntp/ag-tpl/mdoc2mdoc@1.0 +0 -0 + +ChangeSet@1.2519, 2011-05-18 04:46:41-04:00, stenn@psp-deb1.ntp.org + More cleanup around autogen-erating ntpdc.1 and ntpdc.html + + .point-changed-filelist@1.10 +1 -0 + Deal with the creation of ntpdc/ntpdc.html + + ntpdc/Makefile.am@1.62 +8 -1 + autogen ntpdc.1 cleanup + + ntpdc/ntpdc-opts.def@1.16 +29 -5 + autogen ntpdc.1 cleanup + + sntp/sntp-opts.def@1.28 +2 -6 + Use the homerc.def file like the other programs do + +ChangeSet@1.2517.1.1, 2011-05-17 23:17:51+00:00, davehart@shiny.ad.hartbrothers.com + Bug 1933 - WWVB/Spectracom driver timestamps LFs, not CRs + + ChangeLog@1.884 +1 -0 + Bug 1933 - WWVB/Spectracom driver timestamps LFs, not CRs + + ntpd/refclock_wwvb.c@1.28 +49 -9 + Bug 1933 - WWVB/Spectracom driver timestamps LFs, not CRs + +ChangeSet@1.2516.1.2, 2011-05-17 02:38:20-04:00, stenn@psp-deb1.ntp.org + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/ntpdc-opts.c@1.169.1.1 +95 -95 + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/ntpdc-opts.h@1.169.1.1 +32 -32 + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/ntpdc-opts.texi@1.169.1.1 +22 -23 + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/ntpdc.1@1.169.1.1 +718 -81 + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/ntpdc.html@1.1 +445 -0 + BitKeeper file /home/stenn/ntp-dev/ntpdc/ntpdc.html + + ntpdc/ntpdc.html@1.0 +0 -0 + +ChangeSet@1.2516.1.1, 2011-05-17 02:19:23-04:00, stenn@psp-deb1.ntp.org + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/Makefile.am@1.61 +26 -5 + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/ntpdc-opts.def@1.15 +696 -25 + Prepare for the autogen versions of ntpdc.1 and friends + + ntpdc/ntpdc.texi@1.1 +88 -0 + BitKeeper file /home/stenn/ntp-dev/ntpdc/ntpdc.texi + + ntpdc/ntpdc.texi@1.0 +0 -0 + +ChangeSet@1.2517, 2011-05-16 07:40:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P168 + TAG: NTP_4_2_7P168 + + ChangeLog@1.883 +1 -0 + NTP_4_2_7P168 + + ntpd/ntpd-opts.c@1.173 +3 -3 + NTP_4_2_7P168 + + ntpd/ntpd-opts.h@1.173 +3 -3 + NTP_4_2_7P168 + + ntpd/ntpd-opts.texi@1.171 +2 -2 + NTP_4_2_7P168 + + ntpd/ntpd.1@1.171 +2 -2 + NTP_4_2_7P168 + + ntpdc/ntpdc-opts.c@1.170 +3 -3 + NTP_4_2_7P168 + + ntpdc/ntpdc-opts.h@1.170 +3 -3 + NTP_4_2_7P168 + + ntpdc/ntpdc-opts.texi@1.170 +2 -2 + NTP_4_2_7P168 + + ntpdc/ntpdc.1@1.170 +2 -2 + NTP_4_2_7P168 + + ntpq/ntpq-opts.c@1.170 +3 -3 + NTP_4_2_7P168 + + ntpq/ntpq-opts.h@1.170 +3 -3 + NTP_4_2_7P168 + + ntpq/ntpq-opts.texi@1.170 +2 -2 + NTP_4_2_7P168 + + ntpq/ntpq.1@1.170 +2 -2 + NTP_4_2_7P168 + + ntpsnmpd/ntpsnmpd-opts.c@1.170 +3 -3 + NTP_4_2_7P168 + + ntpsnmpd/ntpsnmpd-opts.h@1.170 +3 -3 + NTP_4_2_7P168 + + ntpsnmpd/ntpsnmpd-opts.texi@1.170 +2 -2 + NTP_4_2_7P168 + + ntpsnmpd/ntpsnmpd.1@1.170 +2 -2 + NTP_4_2_7P168 + + packageinfo.sh@1.171 +1 -1 + NTP_4_2_7P168 + + sntp/sntp-opts.c@1.164 +3 -3 + NTP_4_2_7P168 + + sntp/sntp-opts.h@1.164 +3 -3 + NTP_4_2_7P168 + + sntp/sntp-opts.texi@1.164 +2 -2 + NTP_4_2_7P168 + + sntp/sntp.1@1.164 +2 -2 + NTP_4_2_7P168 + + sntp/sntp.html@1.164 +2 -2 + NTP_4_2_7P168 + + util/ntp-keygen-opts.c@1.168 +3 -3 + NTP_4_2_7P168 + + util/ntp-keygen-opts.h@1.168 +3 -3 + NTP_4_2_7P168 + + util/ntp-keygen-opts.texi@1.171 +2 -2 + NTP_4_2_7P168 + + util/ntp-keygen.1@1.171 +2 -2 + NTP_4_2_7P168 + +ChangeSet@1.2516, 2011-05-16 05:18:56+00:00, davehart@shiny.ad.hartbrothers.com + Convert receive buffer queue from doubly-linked list to FIFO. + + ChangeLog@1.882 +1 -0 + Convert receive buffer queue from doubly-linked list to FIFO. + + include/ntp_config.h@1.72 +0 -10 + Convert receive buffer queue from doubly-linked list to FIFO. + + include/ntp_lists.h@1.12 +50 -3 + Convert receive buffer queue from doubly-linked list to FIFO. + + include/recvbuff.h@1.25 +20 -20 + Convert receive buffer queue from doubly-linked list to FIFO. + + libntp/recvbuff.c@1.38 +52 -34 + Convert receive buffer queue from doubly-linked list to FIFO. + + ntpd/ntp_config.c@1.289 +0 -24 + Convert receive buffer queue from doubly-linked list to FIFO. + +ChangeSet@1.2514, 2011-05-16 00:47:02-04:00, stenn@deacon.udel.edu + update the comments in packageinfo.sh + + packageinfo.sh@1.170 +13 -0 + update the comments in packageinfo.sh + +ChangeSet@1.2082.4.210, 2011-05-16 04:25:03+00:00, stenn@deacon.udel.edu + NTP_4_2_6P4_BETA1 + TAG: NTP_4_2_6P4_BETA1 + + ChangeLog@1.496.26.146 +1 -0 + NTP_4_2_6P4_BETA1 + + ntpd/ntpd-opts.c@1.248.35.1 +43 -48 + NTP_4_2_6P4_BETA1 + + ntpd/ntpd-opts.h@1.248.35.1 +12 -12 + NTP_4_2_6P4_BETA1 + + ntpd/ntpd-opts.texi@1.246.34.1 +4 -4 + NTP_4_2_6P4_BETA1 + + ntpd/ntpd.1@1.246.34.1 +3 -2 + NTP_4_2_6P4_BETA1 + + ntpdc/ntpdc-opts.c@1.244.35.1 +43 -48 + NTP_4_2_6P4_BETA1 + + ntpdc/ntpdc-opts.h@1.244.35.1 +12 -12 + NTP_4_2_6P4_BETA1 + + ntpdc/ntpdc-opts.texi@1.243.34.1 +12 -19 + NTP_4_2_6P4_BETA1 + + ntpdc/ntpdc.1@1.243.34.1 +3 -2 + NTP_4_2_6P4_BETA1 + + ntpq/ntpq-opts.c@1.245.35.1 +43 -48 + NTP_4_2_6P4_BETA1 + + ntpq/ntpq-opts.h@1.245.35.1 +12 -12 + NTP_4_2_6P4_BETA1 + + ntpq/ntpq-opts.texi@1.244.34.1 +10 -12 + NTP_4_2_6P4_BETA1 + + ntpq/ntpq.1@1.244.34.1 +3 -2 + NTP_4_2_6P4_BETA1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.36.1 +43 -48 + NTP_4_2_6P4_BETA1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.36.1 +12 -12 + NTP_4_2_6P4_BETA1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.35.1 +4 -4 + NTP_4_2_6P4_BETA1 + + ntpsnmpd/ntpsnmpd.1@1.122.35.1 +3 -2 + NTP_4_2_6P4_BETA1 + + packageinfo.sh@1.255.32.1 +3 -3 + NTP_4_2_6P4_BETA1 + + sntp/sntp-opts.c@1.117.33.1 +43 -48 + NTP_4_2_6P4_BETA1 + + sntp/sntp-opts.h@1.117.33.1 +12 -12 + NTP_4_2_6P4_BETA1 + + sntp/sntp-opts.texi@1.117.32.1 +7 -7 + NTP_4_2_6P4_BETA1 + + sntp/sntp.1@1.117.32.1 +3 -2 + NTP_4_2_6P4_BETA1 + + sntp/sntp.html@1.7.33.1 +7 -7 + NTP_4_2_6P4_BETA1 + + util/ntp-keygen-opts.c@1.247.35.1 +52 -75 + NTP_4_2_6P4_BETA1 + + util/ntp-keygen-opts.h@1.247.35.1 +12 -12 + NTP_4_2_6P4_BETA1 + + util/ntp-keygen-opts.texi@1.246.34.1 +8 -7 + NTP_4_2_6P4_BETA1 + + util/ntp-keygen.1@1.246.34.1 +3 -2 + NTP_4_2_6P4_BETA1 + +ChangeSet@1.2082.4.209, 2011-05-15 19:19:24+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1554] peer may stay selected as system peer after becoming + unreachable. + [Bug 1921] LOCAL, ACTS drivers with "prefer" excluded from initial + candidate list. + [Bug 1923] orphan parent favored over LOCAL, ACTS drivers. + [Bug 1924] Billboard tally codes sometimes do not match operation, + variables. + Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. + + ChangeLog@1.496.26.145 +9 -0 + [Bug 1554] peer may stay selected as system peer after becoming + unreachable. + [Bug 1921] LOCAL, ACTS drivers with "prefer" excluded from initial + candidate list. + [Bug 1923] orphan parent favored over LOCAL, ACTS drivers. + [Bug 1924] Billboard tally codes sometimes do not match operation, + variables. + Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. + + include/ntp.h@1.168.1.6 +9 -9 + [Bug 1924] Billboard tally codes sometimes do not match operation, + variables. + + + libntp/mktime.c@1.8.1.1 +2 -2 + leading spaces -> tabs + + ntpd/ntp_loopfilter.c@1.153.2.1 +1 -1 + Comment typo + + ntpd/ntp_proto.c@1.297.2.3 +37 -29 + [Bug 1554] peer may stay selected as system peer after becoming + unreachable. + [Bug 1921] LOCAL, ACTS drivers with "prefer" excluded from initial + candidate list. + [Bug 1923] orphan parent favored over LOCAL, ACTS drivers. + [Bug 1924] Billboard tally codes sometimes do not match operation, + variables. + + + ports/winnt/include/config.h@1.79.1.5 +2 -0 + Use _mkgmtime() for timegm() in Windows ports, resolves crash at startup + loading Autokey host certificate. + + ports/winnt/ntpd/nt_clockstuff.c@1.38.1.5 +23 -0 + Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. + +ChangeSet@1.2512, 2011-05-14 11:34:43+00:00, stenn@deacon.udel.edu + NTP_4_2_7P167 + TAG: NTP_4_2_7P167 + + ChangeLog@1.879 +1 -0 + NTP_4_2_7P167 + + ntpd/ntpd-opts.c@1.172 +3 -3 + NTP_4_2_7P167 + + ntpd/ntpd-opts.h@1.172 +3 -3 + NTP_4_2_7P167 + + ntpd/ntpd-opts.texi@1.170 +2 -2 + NTP_4_2_7P167 + + ntpd/ntpd.1@1.170 +2 -2 + NTP_4_2_7P167 + + ntpdc/ntpdc-opts.c@1.169 +3 -3 + NTP_4_2_7P167 + + ntpdc/ntpdc-opts.h@1.169 +3 -3 + NTP_4_2_7P167 + + ntpdc/ntpdc-opts.texi@1.169 +2 -2 + NTP_4_2_7P167 + + ntpdc/ntpdc.1@1.169 +2 -2 + NTP_4_2_7P167 + + ntpq/ntpq-opts.c@1.169 +3 -3 + NTP_4_2_7P167 + + ntpq/ntpq-opts.h@1.169 +3 -3 + NTP_4_2_7P167 + + ntpq/ntpq-opts.texi@1.169 +2 -2 + NTP_4_2_7P167 + + ntpq/ntpq.1@1.169 +2 -2 + NTP_4_2_7P167 + + ntpsnmpd/ntpsnmpd-opts.c@1.169 +3 -3 + NTP_4_2_7P167 + + ntpsnmpd/ntpsnmpd-opts.h@1.169 +3 -3 + NTP_4_2_7P167 + + ntpsnmpd/ntpsnmpd-opts.texi@1.169 +2 -2 + NTP_4_2_7P167 + + ntpsnmpd/ntpsnmpd.1@1.169 +2 -2 + NTP_4_2_7P167 + + packageinfo.sh@1.169 +1 -1 + NTP_4_2_7P167 + + sntp/sntp-opts.c@1.163 +3 -3 + NTP_4_2_7P167 + + sntp/sntp-opts.h@1.163 +3 -3 + NTP_4_2_7P167 + + sntp/sntp-opts.texi@1.163 +2 -2 + NTP_4_2_7P167 + + sntp/sntp.1@1.163 +2 -2 + NTP_4_2_7P167 + + sntp/sntp.html@1.163 +2 -2 + NTP_4_2_7P167 + + util/ntp-keygen-opts.c@1.167 +3 -3 + NTP_4_2_7P167 + + util/ntp-keygen-opts.h@1.167 +3 -3 + NTP_4_2_7P167 + + util/ntp-keygen-opts.texi@1.170 +2 -2 + NTP_4_2_7P167 + + util/ntp-keygen.1@1.170 +2 -2 + NTP_4_2_7P167 + +ChangeSet@1.2511, 2011-05-14 01:11:38-04:00, stenn@deacon.udel.edu + 4.2.7p164 documentation updates regarding 'tos orphanwait' expanded scope + + ChangeLog@1.878 +1 -0 + 4.2.7p164 documentation updates regarding 'tos orphanwait' expanded scope + + html/assoc.html@1.35 +2 -2 + 4.2.7p164 documentation updates regarding 'tos orphanwait' expanded scope + + html/miscopt.html@1.66 +3 -4 + 4.2.7p164 documentation updates regarding 'tos orphanwait' expanded scope + + html/orphan.html@1.2 +3 -3 + 4.2.7p164 documentation updates regarding 'tos orphanwait' expanded scope + +ChangeSet@1.2510, 2011-05-14 03:37:31+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1931] cv always includes fudgetime1, never fudgetime2. + + ChangeLog@1.877 +1 -0 + [Bug 1931] cv always includes fudgetime1, never fudgetime2. + + ntpd/ntp_control.c@1.169 +33 -32 + [Bug 1931] cv always includes fudgetime1, never fudgetime2. + + ntpd/ntp_refclock.c@1.107 +17 -6 + [Bug 1931] cv always includes fudgetime1, never fudgetime2. + +ChangeSet@1.2509, 2011-05-13 21:38:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1927] io_closeclock() should purge pending recvbufs. + Use acts_close() in acts_shutdown() to avoid leaving a stale lockfile + if unpeered via runtime configuration while the modem is open. + Correct acts_close() test of pp->io.fd to see if it is open. + + ChangeLog@1.876 +4 -0 + [Bug 1927] io_closeclock() should purge pending recvbufs. + Use acts_close() in acts_shutdown() to avoid leaving a stale lockfile + if unpeered via runtime configuration while the modem is open. + Correct acts_close() test of pp->io.fd to see if it is open. + + include/recvbuff.h@1.24 +21 -14 + [Bug 1927] io_closeclock() should purge pending recvbufs. + + libntp/recvbuff.c@1.37 +35 -1 + [Bug 1927] io_closeclock() should purge pending recvbufs. + + ntpd/ntp_io.c@1.354 +15 -22 + [Bug 1927] io_closeclock() should purge pending recvbufs. + + ntpd/refclock_acts.c@1.51 +7 -9 + Use acts_close() in acts_shutdown() to avoid leaving a stale lockfile + if unpeered via runtime configuration while the modem is open. + Correct acts_close() test of pp->io.fd to see if it is open. + +ChangeSet@1.2508, 2011-05-13 11:42:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P166 + TAG: NTP_4_2_7P166 + + ChangeLog@1.875 +1 -0 + NTP_4_2_7P166 + + ntpd/ntpd-opts.c@1.171 +3 -3 + NTP_4_2_7P166 + + ntpd/ntpd-opts.h@1.171 +3 -3 + NTP_4_2_7P166 + + ntpd/ntpd-opts.texi@1.169 +2 -2 + NTP_4_2_7P166 + + ntpd/ntpd.1@1.169 +2 -2 + NTP_4_2_7P166 + + ntpdc/ntpdc-opts.c@1.168 +3 -3 + NTP_4_2_7P166 + + ntpdc/ntpdc-opts.h@1.168 +3 -3 + NTP_4_2_7P166 + + ntpdc/ntpdc-opts.texi@1.168 +2 -2 + NTP_4_2_7P166 + + ntpdc/ntpdc.1@1.168 +2 -2 + NTP_4_2_7P166 + + ntpq/ntpq-opts.c@1.168 +3 -3 + NTP_4_2_7P166 + + ntpq/ntpq-opts.h@1.168 +3 -3 + NTP_4_2_7P166 + + ntpq/ntpq-opts.texi@1.168 +2 -2 + NTP_4_2_7P166 + + ntpq/ntpq.1@1.168 +2 -2 + NTP_4_2_7P166 + + ntpsnmpd/ntpsnmpd-opts.c@1.168 +3 -3 + NTP_4_2_7P166 + + ntpsnmpd/ntpsnmpd-opts.h@1.168 +3 -3 + NTP_4_2_7P166 + + ntpsnmpd/ntpsnmpd-opts.texi@1.168 +2 -2 + NTP_4_2_7P166 + + ntpsnmpd/ntpsnmpd.1@1.168 +2 -2 + NTP_4_2_7P166 + + packageinfo.sh@1.168 +1 -1 + NTP_4_2_7P166 + + sntp/sntp-opts.c@1.162 +3 -3 + NTP_4_2_7P166 + + sntp/sntp-opts.h@1.162 +3 -3 + NTP_4_2_7P166 + + sntp/sntp-opts.texi@1.162 +2 -2 + NTP_4_2_7P166 + + sntp/sntp.1@1.162 +27 -22 + NTP_4_2_7P166 + + sntp/sntp.html@1.162 +2 -2 + NTP_4_2_7P166 + + util/ntp-keygen-opts.c@1.166 +3 -3 + NTP_4_2_7P166 + + util/ntp-keygen-opts.h@1.166 +3 -3 + NTP_4_2_7P166 + + util/ntp-keygen-opts.texi@1.169 +2 -2 + NTP_4_2_7P166 + + util/ntp-keygen.1@1.169 +2 -2 + NTP_4_2_7P166 + +ChangeSet@1.2507, 2011-05-13 06:05:54-04:00, stenn@psp-deb1.ntp.org + Distribute sntp/ag-tpl/ + + sntp/Makefile.am@1.62 +1 -0 + Distribute sntp/ag-tpl/ + +ChangeSet@1.2506, 2011-05-13 05:08:53-04:00, stenn@psp-deb1.ntp.org + Use our autogen templates if we have any + + ChangeLog@1.874 +2 -0 + Use our autogen templates if we have any + + sntp/Makefile.am@1.61 +1 -1 + Use our autogen templates if we have any + + sntp/ag-tpl/agmdoc-cmd.tpl@1.1 +115 -0 + BitKeeper file /home/stenn/ntp-dev/sntp/ag-tpl/agmdoc-cmd.tpl + + sntp/ag-tpl/agmdoc-cmd.tpl@1.0 +0 -0 + + sntp/sntp-opts.def@1.27 +24 -20 + Update sntp docs + +ChangeSet@1.2505, 2011-05-11 19:29:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P165 + TAG: NTP_4_2_7P165 + + ChangeLog@1.873 +1 -0 + NTP_4_2_7P165 + + ntpd/ntpd-opts.c@1.170 +5 -5 + NTP_4_2_7P165 + + ntpd/ntpd-opts.h@1.170 +3 -3 + NTP_4_2_7P165 + + ntpd/ntpd-opts.texi@1.168 +2 -2 + NTP_4_2_7P165 + + ntpd/ntpd.1@1.168 +2 -2 + NTP_4_2_7P165 + + ntpdc/ntpdc-opts.c@1.167 +5 -5 + NTP_4_2_7P165 + + ntpdc/ntpdc-opts.h@1.167 +3 -3 + NTP_4_2_7P165 + + ntpdc/ntpdc-opts.texi@1.167 +2 -2 + NTP_4_2_7P165 + + ntpdc/ntpdc.1@1.167 +2 -2 + NTP_4_2_7P165 + + ntpq/ntpq-opts.c@1.167 +5 -5 + NTP_4_2_7P165 + + ntpq/ntpq-opts.h@1.167 +3 -3 + NTP_4_2_7P165 + + ntpq/ntpq-opts.texi@1.167 +2 -2 + NTP_4_2_7P165 + + ntpq/ntpq.1@1.167 +2 -2 + NTP_4_2_7P165 + + ntpsnmpd/ntpsnmpd-opts.c@1.167 +5 -5 + NTP_4_2_7P165 + + ntpsnmpd/ntpsnmpd-opts.h@1.167 +3 -3 + NTP_4_2_7P165 + + ntpsnmpd/ntpsnmpd-opts.texi@1.167 +2 -2 + NTP_4_2_7P165 + + ntpsnmpd/ntpsnmpd.1@1.167 +2 -2 + NTP_4_2_7P165 + + packageinfo.sh@1.167 +1 -1 + NTP_4_2_7P165 + + sntp/sntp-opts.c@1.161 +60 -60 + NTP_4_2_7P165 + + sntp/sntp-opts.h@1.161 +24 -24 + NTP_4_2_7P165 + + sntp/sntp-opts.texi@1.161 +23 -18 + NTP_4_2_7P165 + + sntp/sntp.1@1.161 +127 -121 + NTP_4_2_7P165 + + sntp/sntp.html@1.161 +23 -18 + NTP_4_2_7P165 + + util/ntp-keygen-opts.c@1.165 +5 -5 + NTP_4_2_7P165 + + util/ntp-keygen-opts.h@1.165 +3 -3 + NTP_4_2_7P165 + + util/ntp-keygen-opts.texi@1.168 +2 -2 + NTP_4_2_7P165 + + util/ntp-keygen.1@1.168 +2 -2 + NTP_4_2_7P165 + +ChangeSet@1.2082.4.208, 2011-05-11 04:40:35-04:00, stenn@deacon.udel.edu + Upgrade to AutoGen 5.11.9 (and require it) + + ChangeLog@1.496.26.144 +1 -0 + Upgrade to AutoGen 5.11.9 (and require it) + + include/autogen-version.def@1.4.1.1 +1 -1 + Upgrade to AutoGen 5.11.9 (and require it) + +ChangeSet@1.2503, 2011-05-11 03:21:39-04:00, stenn@psp-deb1.ntp.org + Convert snmp docs to mdoc format, which requires autogen 5.11.9 + + ChangeLog@1.871 +1 -0 + Convert snmp docs to mdoc format, which requires autogen 5.11.9 + + sntp/Makefile.am@1.60 +3 -1 + Convert snmp docs to mdoc format, which requires autogen 5.11.9 + + sntp/include/autogen-version.def@1.6 +1 -1 + Upgrade autogen to 5.11.9 + + sntp/sntp-opts.def@1.26 +146 -130 + Convert snmp docs to mdoc format, which requires autogen 5.11.9 + + sntp/sntp.texi@1.8 +1 -1 + Convert snmp docs to mdoc format, which requires autogen 5.11.9 + +ChangeSet@1.2502, 2011-05-11 00:48:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P164 + TAG: NTP_4_2_7P164 + + ChangeLog@1.870 +1 -0 + NTP_4_2_7P164 + + ntpd/ntpd-opts.c@1.169 +3 -3 + NTP_4_2_7P164 + + ntpd/ntpd-opts.h@1.169 +3 -3 + NTP_4_2_7P164 + + ntpd/ntpd-opts.texi@1.167 +2 -2 + NTP_4_2_7P164 + + ntpd/ntpd.1@1.167 +2 -2 + NTP_4_2_7P164 + + ntpdc/ntpdc-opts.c@1.166 +3 -3 + NTP_4_2_7P164 + + ntpdc/ntpdc-opts.h@1.166 +3 -3 + NTP_4_2_7P164 + + ntpdc/ntpdc-opts.texi@1.166 +2 -2 + NTP_4_2_7P164 + + ntpdc/ntpdc.1@1.166 +2 -2 + NTP_4_2_7P164 + + ntpq/ntpq-opts.c@1.166 +3 -3 + NTP_4_2_7P164 + + ntpq/ntpq-opts.h@1.166 +3 -3 + NTP_4_2_7P164 + + ntpq/ntpq-opts.texi@1.166 +2 -2 + NTP_4_2_7P164 + + ntpq/ntpq.1@1.166 +2 -2 + NTP_4_2_7P164 + + ntpsnmpd/ntpsnmpd-opts.c@1.166 +3 -3 + NTP_4_2_7P164 + + ntpsnmpd/ntpsnmpd-opts.h@1.166 +3 -3 + NTP_4_2_7P164 + + ntpsnmpd/ntpsnmpd-opts.texi@1.166 +2 -2 + NTP_4_2_7P164 + + ntpsnmpd/ntpsnmpd.1@1.166 +2 -2 + NTP_4_2_7P164 + + packageinfo.sh@1.166 +1 -1 + NTP_4_2_7P164 + + sntp/sntp-opts.c@1.160 +3 -3 + NTP_4_2_7P164 + + sntp/sntp-opts.h@1.160 +3 -3 + NTP_4_2_7P164 + + sntp/sntp-opts.texi@1.160 +2 -2 + NTP_4_2_7P164 + + sntp/sntp.1@1.160 +2 -2 + NTP_4_2_7P164 + + sntp/sntp.html@1.160 +1 -1 + NTP_4_2_7P164 + + util/ntp-keygen-opts.c@1.164 +3 -3 + NTP_4_2_7P164 + + util/ntp-keygen-opts.h@1.164 +3 -3 + NTP_4_2_7P164 + + util/ntp-keygen-opts.texi@1.167 +2 -2 + NTP_4_2_7P164 + + util/ntp-keygen.1@1.167 +2 -2 + NTP_4_2_7P164 + +ChangeSet@1.2501, 2011-05-10 15:46:36-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.869 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.20 +36 -52 + Documentation updates from Dave Mills + + html/drivers/driver6.html@1.27 +1 -2 + Documentation updates from Dave Mills + + html/miscopt.html@1.65 +2 -2 + Documentation updates from Dave Mills + + html/release.html@1.40 +9 -7 + Documentation updates from Dave Mills + + html/warp.html@1.13 +8 -7 + Documentation updates from Dave Mills + + html/xleave.html@1.6 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2479.13.2, 2011-05-09 23:20:17+00:00, davehart@shiny.ad.hartbrothers.com + Update ChangeLog additions for ntp_proto.c changes to reference newly-filed + bug reports: [Bug 1921] [Bug 1922] [Bug 1923] [Bug 1924] + + ChangeLog@1.867 +9 -5 + Update ChangeLog additions for ntp_proto.c changes to reference newly-filed + bug reports: [Bug 1921] [Bug 1922] [Bug 1923] [Bug 1924] + +ChangeSet@1.2499, 2011-05-08 09:10:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P163 + TAG: NTP_4_2_7P163 + + ChangeLog@1.865.1.11 +1 -0 + NTP_4_2_7P163 + + ntpd/ntpd-opts.c@1.168 +3 -3 + NTP_4_2_7P163 + + ntpd/ntpd-opts.h@1.168 +3 -3 + NTP_4_2_7P163 + + ntpd/ntpd-opts.texi@1.166 +2 -2 + NTP_4_2_7P163 + + ntpd/ntpd.1@1.166 +2 -2 + NTP_4_2_7P163 + + ntpdc/ntpdc-opts.c@1.165 +3 -3 + NTP_4_2_7P163 + + ntpdc/ntpdc-opts.h@1.165 +3 -3 + NTP_4_2_7P163 + + ntpdc/ntpdc-opts.texi@1.165 +2 -2 + NTP_4_2_7P163 + + ntpdc/ntpdc.1@1.165 +2 -2 + NTP_4_2_7P163 + + ntpq/ntpq-opts.c@1.165 +3 -3 + NTP_4_2_7P163 + + ntpq/ntpq-opts.h@1.165 +3 -3 + NTP_4_2_7P163 + + ntpq/ntpq-opts.texi@1.165 +2 -2 + NTP_4_2_7P163 + + ntpq/ntpq.1@1.165 +2 -2 + NTP_4_2_7P163 + + ntpsnmpd/ntpsnmpd-opts.c@1.165 +3 -3 + NTP_4_2_7P163 + + ntpsnmpd/ntpsnmpd-opts.h@1.165 +3 -3 + NTP_4_2_7P163 + + ntpsnmpd/ntpsnmpd-opts.texi@1.165 +2 -2 + NTP_4_2_7P163 + + ntpsnmpd/ntpsnmpd.1@1.165 +2 -2 + NTP_4_2_7P163 + + packageinfo.sh@1.165 +1 -1 + NTP_4_2_7P163 + + sntp/sntp-opts.c@1.159 +3 -3 + NTP_4_2_7P163 + + sntp/sntp-opts.h@1.159 +3 -3 + NTP_4_2_7P163 + + sntp/sntp-opts.texi@1.159 +2 -2 + NTP_4_2_7P163 + + sntp/sntp.1@1.159 +2 -2 + NTP_4_2_7P163 + + sntp/sntp.html@1.159 +1 -1 + NTP_4_2_7P163 + + util/ntp-keygen-opts.c@1.163 +3 -3 + NTP_4_2_7P163 + + util/ntp-keygen-opts.h@1.163 +3 -3 + NTP_4_2_7P163 + + util/ntp-keygen-opts.texi@1.166 +2 -2 + NTP_4_2_7P163 + + util/ntp-keygen.1@1.166 +2 -2 + NTP_4_2_7P163 + +ChangeSet@1.2498, 2011-05-08 01:58:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1911] missing curly brace in libntp/ntp_rfc2553.c + + ChangeLog@1.865.1.10 +1 -0 + [Bug 1911] missing curly brace in libntp/ntp_rfc2553.c + + libntp/ntp_rfc2553.c@1.47 +57 -35 + [Bug 1911] missing curly brace in libntp/ntp_rfc2553.c + Refactor copy_addrinfo_common() code out of copy_addrinfo_impl() + and copy_addrinfo_list_impl(). + +ChangeSet@1.2497, 2011-05-03 09:00:25+00:00, stenn@deacon.udel.edu + NTP_4_2_7P162 + TAG: NTP_4_2_7P162 + + ChangeLog@1.865.1.9 +1 -0 + NTP_4_2_7P162 + + ntpd/ntpd-opts.c@1.167 +3 -3 + NTP_4_2_7P162 + + ntpd/ntpd-opts.h@1.167 +3 -3 + NTP_4_2_7P162 + + ntpd/ntpd-opts.texi@1.165 +2 -2 + NTP_4_2_7P162 + + ntpd/ntpd.1@1.165 +2 -2 + NTP_4_2_7P162 + + ntpdc/ntpdc-opts.c@1.164 +3 -3 + NTP_4_2_7P162 + + ntpdc/ntpdc-opts.h@1.164 +3 -3 + NTP_4_2_7P162 + + ntpdc/ntpdc-opts.texi@1.164 +2 -2 + NTP_4_2_7P162 + + ntpdc/ntpdc.1@1.164 +2 -2 + NTP_4_2_7P162 + + ntpq/ntpq-opts.c@1.164 +3 -3 + NTP_4_2_7P162 + + ntpq/ntpq-opts.h@1.164 +3 -3 + NTP_4_2_7P162 + + ntpq/ntpq-opts.texi@1.164 +2 -2 + NTP_4_2_7P162 + + ntpq/ntpq.1@1.164 +2 -2 + NTP_4_2_7P162 + + ntpsnmpd/ntpsnmpd-opts.c@1.164 +3 -3 + NTP_4_2_7P162 + + ntpsnmpd/ntpsnmpd-opts.h@1.164 +3 -3 + NTP_4_2_7P162 + + ntpsnmpd/ntpsnmpd-opts.texi@1.164 +2 -2 + NTP_4_2_7P162 + + ntpsnmpd/ntpsnmpd.1@1.164 +2 -2 + NTP_4_2_7P162 + + packageinfo.sh@1.164 +1 -1 + NTP_4_2_7P162 + + sntp/sntp-opts.c@1.158 +3 -3 + NTP_4_2_7P162 + + sntp/sntp-opts.h@1.158 +3 -3 + NTP_4_2_7P162 + + sntp/sntp-opts.texi@1.158 +2 -2 + NTP_4_2_7P162 + + sntp/sntp.1@1.158 +2 -2 + NTP_4_2_7P162 + + sntp/sntp.html@1.158 +1 -1 + NTP_4_2_7P162 + + util/ntp-keygen-opts.c@1.162 +3 -3 + NTP_4_2_7P162 + + util/ntp-keygen-opts.h@1.162 +3 -3 + NTP_4_2_7P162 + + util/ntp-keygen-opts.texi@1.165 +2 -2 + NTP_4_2_7P162 + + util/ntp-keygen.1@1.165 +2 -2 + NTP_4_2_7P162 + +ChangeSet@1.2496, 2011-05-02 21:16:22-07:00, harlan@hms-mbp.local + [Bug 1910] Support the Tristate Ltd. TS-GPSclock-01 + + ChangeLog@1.865.1.8 +1 -0 + [Bug 1910] Support the Tristate Ltd. TS-GPSclock-01 + + html/drivers/driver40.html@1.15 +95 -23 + [Bug 1910] Support the Tristate Ltd. TS-GPSclock-01 + + ntpd/refclock_jjy.c@1.24 +368 -24 + [Bug 1910] Support the Tristate Ltd. TS-GPSclock-01 + +ChangeSet@1.2495, 2011-05-02 17:58:58-04:00, stenn@deacon.udel.edu + more ignore file cleanup + + BitKeeper/etc/ignore@1.80 +7 -11 + more ignore file cleanup + +ChangeSet@1.2494, 2011-05-02 21:14:30+00:00, stenn@deacon.udel.edu + NTP_4_2_7P161 + TAG: NTP_4_2_7P161 + + ChangeLog@1.865.1.7 +1 -0 + NTP_4_2_7P161 + + ntpd/ntpd-opts.c@1.166 +3 -3 + NTP_4_2_7P161 + + ntpd/ntpd-opts.h@1.166 +3 -3 + NTP_4_2_7P161 + + ntpd/ntpd-opts.texi@1.164 +2 -2 + NTP_4_2_7P161 + + ntpd/ntpd.1@1.164 +2 -2 + NTP_4_2_7P161 + + ntpdc/ntpdc-opts.c@1.163 +3 -3 + NTP_4_2_7P161 + + ntpdc/ntpdc-opts.h@1.163 +3 -3 + NTP_4_2_7P161 + + ntpdc/ntpdc-opts.texi@1.163 +2 -2 + NTP_4_2_7P161 + + ntpdc/ntpdc.1@1.163 +2 -2 + NTP_4_2_7P161 + + ntpq/ntpq-opts.c@1.163 +3 -3 + NTP_4_2_7P161 + + ntpq/ntpq-opts.h@1.163 +3 -3 + NTP_4_2_7P161 + + ntpq/ntpq-opts.texi@1.163 +2 -2 + NTP_4_2_7P161 + + ntpq/ntpq.1@1.163 +2 -2 + NTP_4_2_7P161 + + ntpsnmpd/ntpsnmpd-opts.c@1.163 +3 -3 + NTP_4_2_7P161 + + ntpsnmpd/ntpsnmpd-opts.h@1.163 +3 -3 + NTP_4_2_7P161 + + ntpsnmpd/ntpsnmpd-opts.texi@1.163 +2 -2 + NTP_4_2_7P161 + + ntpsnmpd/ntpsnmpd.1@1.163 +2 -2 + NTP_4_2_7P161 + + packageinfo.sh@1.163 +1 -1 + NTP_4_2_7P161 + + sntp/sntp-opts.c@1.157 +3 -3 + NTP_4_2_7P161 + + sntp/sntp-opts.h@1.157 +3 -3 + NTP_4_2_7P161 + + sntp/sntp-opts.texi@1.157 +2 -2 + NTP_4_2_7P161 + + sntp/sntp.1@1.157 +2 -2 + NTP_4_2_7P161 + + sntp/sntp.html@1.157 +1 -1 + NTP_4_2_7P161 + + util/ntp-keygen-opts.c@1.161 +3 -3 + NTP_4_2_7P161 + + util/ntp-keygen-opts.h@1.161 +3 -3 + NTP_4_2_7P161 + + util/ntp-keygen-opts.texi@1.164 +2 -2 + NTP_4_2_7P161 + + util/ntp-keygen.1@1.164 +2 -2 + NTP_4_2_7P161 + +ChangeSet@1.2493, 2011-05-01 22:57:03+00:00, davehart@shiny.ad.hartbrothers.com + Add missing --enable-local-libevent help to top-level configure. + + ChangeLog@1.865.1.6 +1 -0 + Add missing --enable-local-libevent help to top-level configure. + + configure.ac@1.527 +2 -0 + Add missing --enable-local-libevent help to top-level configure. + + sntp/m4/ntp_libevent.m4@1.7 +24 -10 + Add missing --enable-local-libevent help to top-level configure. + +ChangeSet@1.2492, 2011-05-01 21:15:54+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + + ChangeLog@1.865.1.5 +4 -0 + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + + Makefile.am@1.109 +1 -1 + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + + build@1.45 +2 -2 + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + + configure.ac@1.526 +1 -1 + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + + flock-build@1.52 +1 -1 + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + + sntp/configure.ac@1.61 +1 -1 + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + + sntp/libevent/configure.in@1.7 +1 -0 + [Bug 1906] 4.2.7p160 - libtool: compile: cannot determine name of + library object in ./libevent + Share a single sntp/libevent/build-aux directory between all three + configure scripts. + +ChangeSet@1.2491, 2011-05-01 10:40:29+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog entry needed for -dev, which rolled with the bug. + + ChangeLog@1.865.1.4 +1 -0 + ChangeLog entry needed for -dev, which rolled with the bug. + +ChangeSet@1.2082.4.207, 2011-05-01 10:37:55+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1904] New: 4.2.7p160 Windows build broken (POSIX_SHELL). + + ports/winnt/include/config.h@1.79.1.4 +1 -0 + [Bug 1904] New: 4.2.7p160 Windows build broken (POSIX_SHELL). + +ChangeSet@1.2489, 2011-05-01 08:30:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P160 + TAG: NTP_4_2_7P160 + + ChangeLog@1.865.1.3 +1 -0 + NTP_4_2_7P160 + + ntpd/ntpd-opts.c@1.165 +41 -46 + NTP_4_2_7P160 + + ntpd/ntpd-opts.h@1.165 +12 -12 + NTP_4_2_7P160 + + ntpd/ntpd-opts.texi@1.163 +2 -2 + NTP_4_2_7P160 + + ntpd/ntpd.1@1.163 +3 -2 + NTP_4_2_7P160 + + ntpdc/ntpdc-opts.c@1.162 +41 -46 + NTP_4_2_7P160 + + ntpdc/ntpdc-opts.h@1.162 +12 -12 + NTP_4_2_7P160 + + ntpdc/ntpdc-opts.texi@1.162 +2 -2 + NTP_4_2_7P160 + + ntpdc/ntpdc.1@1.162 +3 -2 + NTP_4_2_7P160 + + ntpq/ntpq-opts.c@1.162 +41 -46 + NTP_4_2_7P160 + + ntpq/ntpq-opts.h@1.162 +12 -12 + NTP_4_2_7P160 + + ntpq/ntpq-opts.texi@1.162 +2 -2 + NTP_4_2_7P160 + + ntpq/ntpq.1@1.162 +3 -2 + NTP_4_2_7P160 + + ntpsnmpd/ntpsnmpd-opts.c@1.162 +41 -46 + NTP_4_2_7P160 + + ntpsnmpd/ntpsnmpd-opts.h@1.162 +12 -12 + NTP_4_2_7P160 + + ntpsnmpd/ntpsnmpd-opts.texi@1.162 +2 -2 + NTP_4_2_7P160 + + ntpsnmpd/ntpsnmpd.1@1.162 +3 -2 + NTP_4_2_7P160 + + packageinfo.sh@1.162 +1 -1 + NTP_4_2_7P160 + + sntp/sntp-opts.c@1.156 +57 -97 + NTP_4_2_7P160 + + sntp/sntp-opts.h@1.156 +12 -12 + NTP_4_2_7P160 + + sntp/sntp-opts.texi@1.156 +6 -4 + NTP_4_2_7P160 + + sntp/sntp.1@1.156 +69 -90 + NTP_4_2_7P160 + + sntp/sntp.html@1.156 +5 -3 + NTP_4_2_7P160 + + util/ntp-keygen-opts.c@1.160 +50 -73 + NTP_4_2_7P160 + + util/ntp-keygen-opts.h@1.160 +12 -12 + NTP_4_2_7P160 + + util/ntp-keygen-opts.texi@1.163 +4 -3 + NTP_4_2_7P160 + + util/ntp-keygen.1@1.163 +3 -2 + NTP_4_2_7P160 + +ChangeSet@1.2082.4.206, 2011-05-01 02:47:38-04:00, stenn@deacon.udel.edu + hack around a possible regression in the new autogen + + include/copyright.def@1.13.1.1 +4 -1 + hack around a possible regression in the new autogen + +ChangeSet@1.2082.4.205, 2011-05-01 02:41:53-04:00, stenn@deacon.udel.edu + Upgrade to libopts 35.0.10 from AutoGen 5.11.9pre8 + + ChangeLog@1.496.26.143 +4 -0 + Upgrade to libopts 35.0.10 from AutoGen 5.11.9pre8 + + sntp/libopts/Makefile.am@1.10 +16 -16 + Updated to libopts-35.0.10 + + sntp/libopts/ag-char-map.h@1.13 +6 -6 + Updated to libopts-35.0.10 + + sntp/libopts/autoopts.c@1.10 +2 -12 + Updated to libopts-35.0.10 + + sntp/libopts/autoopts.h@1.9 +3 -37 + Updated to libopts-35.0.10 + + sntp/libopts/autoopts/options.h@1.12 +21 -23 + Updated to libopts-35.0.10 + + sntp/libopts/autoopts/project.h@1.1 +50 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/project.h + + sntp/libopts/autoopts/project.h@1.0 +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.12 +100 -95 + Updated to libopts-35.0.10 + + sntp/libopts/configfile.c@1.11 +9 -9 + Updated to libopts-35.0.10 + + sntp/libopts/cook.c@1.8 +85 -67 + Updated to libopts-35.0.10 + + sntp/libopts/enumeration.c@1.8 +15 -10 + Updated to libopts-35.0.10 + + sntp/libopts/environment.c@1.10 +22 -13 + Updated to libopts-35.0.10 + + sntp/libopts/genshell.c@1.13 +58 -56 + Updated to libopts-35.0.10 + + sntp/libopts/genshell.h@1.13 +46 -46 + Updated to libopts-35.0.10 + + sntp/libopts/libopts.c@1.3 +5 -2 + Updated to libopts-35.0.10 + + sntp/libopts/m4/libopts.m4@1.16 +22 -3 + Updated to libopts-35.0.10 + + sntp/libopts/makeshell.c@1.9 +84 -58 + Updated to libopts-35.0.10 + + sntp/libopts/numeric.c@1.8 +39 -47 + Updated to libopts-35.0.10 + + sntp/libopts/parse-duration.c@1.5 +73 -54 + Updated to libopts-35.0.10 + + sntp/libopts/parse-duration.h@1.5 +14 -14 + Updated to libopts-35.0.10 + + sntp/libopts/pgusage.c@1.8 +1 -3 + Updated to libopts-35.0.10 + + sntp/libopts/proto.h@1.13 +1 -4 + Updated to libopts-35.0.10 + + sntp/libopts/save.c@1.9 +34 -41 + Updated to libopts-35.0.10 + + sntp/libopts/time.c@1.8 +77 -29 + Updated to libopts-35.0.10 + + sntp/libopts/value-type.h@1.13 +1 -1 + Updated to libopts-35.0.10 + + sntp/libopts/version.c@1.8 +82 -51 + Updated to libopts-35.0.10 + + sntp/libopts/xat-attribute.h@1.13 +1 -1 + Updated to libopts-35.0.10 + +ChangeSet@1.2487, 2011-04-30 03:15:11-04:00, stenn@psp-deb1.ntp.org + [Bug 1901] Simulator does not set progname. + + ChangeLog@1.865.1.1 +1 -0 + [Bug 1901] Simulator does not set progname. + + ntpd/ntpd.c@1.126 +1 -0 + [Bug 1901] Simulator does not set progname. + +ChangeSet@1.2479.13.1, 2011-04-29 19:44:06+00:00, davehart@shiny.ad.hartbrothers.com + Change "pool DNS" messages from msyslog to debug trace output. + Prefer LOCAL and ACTS drivers to orphan parent peer as documented. + Include LOCAL and ACTS drivers marked prefer in candidate list. + Remove unused FLAG_SYSPEER from peer->status. + Respect "tos orphanwait 0" at startup. Previously there was an + unconditional 300 s. startup orphanwait, though other values were + respected for subsequent orphan wait periods after no_sys_peer events. + Apply "tos orphanwait" (def. 300 seconds) to LOCAL and ACTS reference + clock drivers, in addition to orphan parent operation. LOCAL and ACTS + are not selectable during the orphanwait delay at startup and after + each no_sys_peer event. This prevents a particular form of clock- + hopping, such as using LOCAL briefly at startup before remote peers + are selectable. This fixes the issue reported in [Bug 988]. + [Bug 988] Local clock eats up -g option, so ntpd stops with large + initial time offset. + + ChangeLog@1.866 +15 -0 + Change "pool DNS" messages from msyslog to debug trace output. + Prefer LOCAL and ACTS drivers to orphan parent peer as documented. + Include LOCAL and ACTS drivers marked prefer in candidate list. + Remove unused FLAG_SYSPEER from peer->status. + Respect "tos orphanwait 0" at startup. Previously there was an + unconditional 300 s. startup orphanwait, though other values were + respected for subsequent orphan wait periods after no_sys_peer events. + Apply "tos orphanwait" (def. 300 seconds) to LOCAL and ACTS reference + clock drivers, in addition to orphan parent operation. LOCAL and ACTS + are not selectable during the orphanwait delay at startup and after + each no_sys_peer event. This prevents a particular form of clock- + hopping, such as using LOCAL briefly at startup before remote peers + are selectable. This fixes the issue reported in [Bug 988]. + [Bug 988] Local clock eats up -g option, so ntpd stops with large + initial time offset. + + include/ntp.h@1.194 +9 -9 + Remove unused FLAG_SYSPEER from peer->status. + + ntpd/ntp_loopfilter.c@1.163 +1 -1 + comment typo fix + + ntpd/ntp_proto.c@1.321 +41 -33 + Change "pool DNS" messages from msyslog to debug trace output. + Prefer LOCAL and ACTS drivers to orphan parent peer as documented. + Include LOCAL and ACTS drivers marked prefer in candidate list. + Remove unused FLAG_SYSPEER from peer->status. + Respect "tos orphanwait 0" at startup. Previously there was an + unconditional 300 s. startup orphanwait, though other values were + respected for subsequent orphan wait periods after no_sys_peer events. + Apply "tos orphanwait" (def. 300 seconds) to LOCAL and ACTS reference + clock drivers, in addition to orphan parent operation. LOCAL and ACTS + are not selectable during the orphanwait delay at startup and after + each no_sys_peer event. This prevents a particular form of clock- + hopping, such as using LOCAL briefly at startup before remote peers + are selectable. This fixes the issue reported in [Bug 988]. + [Bug 988] Local clock eats up -g option, so ntpd stops with large + initial time offset. + + ntpd/refclock_acts.c@1.50 +7 -6 + whitespace-only cleanup + +ChangeSet@1.2479.1.82, 2011-04-28 21:42:13-04:00, stenn@deacon.udel.edu + cleanup the bk ignore file - add sntp/scm-rev, remove old version stuff + + BitKeeper/etc/ignore@1.79 +12 -11 + cleanup the bk ignore file - add sntp/scm-rev, remove old version stuff + +ChangeSet@1.2479.1.81, 2011-04-28 06:47:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P159 + TAG: NTP_4_2_7P159 + + ChangeLog@1.865 +1 -0 + NTP_4_2_7P159 + + ntpd/ntpd-opts.c@1.164 +2 -2 + NTP_4_2_7P159 + + ntpd/ntpd-opts.h@1.164 +3 -3 + NTP_4_2_7P159 + + ntpd/ntpd-opts.texi@1.162 +2 -2 + NTP_4_2_7P159 + + ntpd/ntpd.1@1.162 +2 -2 + NTP_4_2_7P159 + + ntpdc/ntpdc-opts.c@1.161 +2 -2 + NTP_4_2_7P159 + + ntpdc/ntpdc-opts.h@1.161 +3 -3 + NTP_4_2_7P159 + + ntpdc/ntpdc-opts.texi@1.161 +2 -2 + NTP_4_2_7P159 + + ntpdc/ntpdc.1@1.161 +2 -2 + NTP_4_2_7P159 + + ntpq/ntpq-opts.c@1.161 +2 -2 + NTP_4_2_7P159 + + ntpq/ntpq-opts.h@1.161 +3 -3 + NTP_4_2_7P159 + + ntpq/ntpq-opts.texi@1.161 +2 -2 + NTP_4_2_7P159 + + ntpq/ntpq.1@1.161 +2 -2 + NTP_4_2_7P159 + + ntpsnmpd/ntpsnmpd-opts.c@1.161 +2 -2 + NTP_4_2_7P159 + + ntpsnmpd/ntpsnmpd-opts.h@1.161 +3 -3 + NTP_4_2_7P159 + + ntpsnmpd/ntpsnmpd-opts.texi@1.161 +2 -2 + NTP_4_2_7P159 + + ntpsnmpd/ntpsnmpd.1@1.161 +2 -2 + NTP_4_2_7P159 + + packageinfo.sh@1.161 +1 -1 + NTP_4_2_7P159 + + sntp/sntp-opts.c@1.155 +2 -2 + NTP_4_2_7P159 + + sntp/sntp-opts.h@1.155 +3 -3 + NTP_4_2_7P159 + + sntp/sntp-opts.texi@1.155 +2 -2 + NTP_4_2_7P159 + + sntp/sntp.1@1.155 +2 -2 + NTP_4_2_7P159 + + sntp/sntp.html@1.155 +1 -1 + NTP_4_2_7P159 + + util/ntp-keygen-opts.c@1.159 +2 -2 + NTP_4_2_7P159 + + util/ntp-keygen-opts.h@1.159 +3 -3 + NTP_4_2_7P159 + + util/ntp-keygen-opts.texi@1.162 +2 -2 + NTP_4_2_7P159 + + util/ntp-keygen.1@1.162 +2 -2 + NTP_4_2_7P159 + +ChangeSet@1.2479.12.3, 2011-04-28 00:05:49-04:00, murray@pogo.udel.edu + ntp_io.c: + Fix unused variable warning (no IPv6) + ntp_control.c: + Fix unused variable warning (no REFCLOCKs) + ChangeLog: + Fix unused variable warnings. + + ChangeLog@1.861.1.3 +1 -0 + Fix unused variable warnings. + + ntpd/ntp_control.c@1.168 +2 -0 + Fix unused variable warning (no REFCLOCKs) + + ntpd/ntp_io.c@1.353 +4 -1 + Fix unused variable warning (no IPv6) + +ChangeSet@1.2479.12.2, 2011-04-24 07:38:50+00:00, stenn@deacon.udel.edu + NTP_4_2_7P158 + TAG: NTP_4_2_7P158 + + ChangeLog@1.861.1.2 +1 -0 + NTP_4_2_7P158 + + ntpd/ntpd-opts.c@1.163 +2 -2 + NTP_4_2_7P158 + + ntpd/ntpd-opts.h@1.163 +3 -3 + NTP_4_2_7P158 + + ntpd/ntpd-opts.texi@1.161 +2 -2 + NTP_4_2_7P158 + + ntpd/ntpd.1@1.161 +2 -2 + NTP_4_2_7P158 + + ntpdc/ntpdc-opts.c@1.160 +2 -2 + NTP_4_2_7P158 + + ntpdc/ntpdc-opts.h@1.160 +3 -3 + NTP_4_2_7P158 + + ntpdc/ntpdc-opts.texi@1.160 +2 -2 + NTP_4_2_7P158 + + ntpdc/ntpdc.1@1.160 +2 -2 + NTP_4_2_7P158 + + ntpq/ntpq-opts.c@1.160 +2 -2 + NTP_4_2_7P158 + + ntpq/ntpq-opts.h@1.160 +3 -3 + NTP_4_2_7P158 + + ntpq/ntpq-opts.texi@1.160 +2 -2 + NTP_4_2_7P158 + + ntpq/ntpq.1@1.160 +2 -2 + NTP_4_2_7P158 + + ntpsnmpd/ntpsnmpd-opts.c@1.160 +2 -2 + NTP_4_2_7P158 + + ntpsnmpd/ntpsnmpd-opts.h@1.160 +3 -3 + NTP_4_2_7P158 + + ntpsnmpd/ntpsnmpd-opts.texi@1.160 +2 -2 + NTP_4_2_7P158 + + ntpsnmpd/ntpsnmpd.1@1.160 +2 -2 + NTP_4_2_7P158 + + packageinfo.sh@1.160 +1 -1 + NTP_4_2_7P158 + + sntp/sntp-opts.c@1.154 +2 -2 + NTP_4_2_7P158 + + sntp/sntp-opts.h@1.154 +3 -3 + NTP_4_2_7P158 + + sntp/sntp-opts.texi@1.154 +2 -2 + NTP_4_2_7P158 + + sntp/sntp.1@1.154 +2 -2 + NTP_4_2_7P158 + + sntp/sntp.html@1.154 +1 -1 + NTP_4_2_7P158 + + util/ntp-keygen-opts.c@1.158 +2 -2 + NTP_4_2_7P158 + + util/ntp-keygen-opts.h@1.158 +3 -3 + NTP_4_2_7P158 + + util/ntp-keygen-opts.texi@1.161 +2 -2 + NTP_4_2_7P158 + + util/ntp-keygen.1@1.161 +2 -2 + NTP_4_2_7P158 + +ChangeSet@1.2479.12.1, 2011-04-23 16:50:09+00:00, davehart@shiny.ad.hartbrothers.com + Update libevent --disable-libevent-regress handling to work when + building libevent using mingw. + + ChangeLog@1.861.1.1 +2 -0 + Update libevent --disable-libevent-regress handling to work when + building libevent using mingw. + + sntp/libevent/configure.in@1.6 +0 -6 + Update libevent --disable-libevent-regress handling to work when + building libevent using mingw. + + sntp/libevent/test/Makefile.am@1.5 +4 -1 + Update libevent --disable-libevent-regress handling to work when + building libevent using mingw. + +ChangeSet@1.2479.1.78, 2011-04-23 11:38:29+02:00, jnperlin@hydra.localnet + minor cleanup in timespecops/timevalops + + ChangeLog@1.862 +1 -0 + minor cleanup in timespecops/timevalops + + libntp/timespecops.c@1.6 +12 -69 + unified with tvalops, use string formatting in libntp, fixed misleading comments + + libntp/timevalops.c@1.7 +9 -4 + fixed misleading comments + +ChangeSet@1.2479.1.77, 2011-04-21 06:16:26+00:00, stenn@deacon.udel.edu + NTP_4_2_7P157 + TAG: NTP_4_2_7P157 + + ChangeLog@1.861 +1 -0 + NTP_4_2_7P157 + + ntpd/ntpd-opts.c@1.162 +2 -2 + NTP_4_2_7P157 + + ntpd/ntpd-opts.h@1.162 +3 -3 + NTP_4_2_7P157 + + ntpd/ntpd-opts.texi@1.160 +2 -2 + NTP_4_2_7P157 + + ntpd/ntpd.1@1.160 +2 -2 + NTP_4_2_7P157 + + ntpdc/ntpdc-opts.c@1.159 +2 -2 + NTP_4_2_7P157 + + ntpdc/ntpdc-opts.h@1.159 +3 -3 + NTP_4_2_7P157 + + ntpdc/ntpdc-opts.texi@1.159 +2 -2 + NTP_4_2_7P157 + + ntpdc/ntpdc.1@1.159 +2 -2 + NTP_4_2_7P157 + + ntpq/ntpq-opts.c@1.159 +2 -2 + NTP_4_2_7P157 + + ntpq/ntpq-opts.h@1.159 +3 -3 + NTP_4_2_7P157 + + ntpq/ntpq-opts.texi@1.159 +2 -2 + NTP_4_2_7P157 + + ntpq/ntpq.1@1.159 +2 -2 + NTP_4_2_7P157 + + ntpsnmpd/ntpsnmpd-opts.c@1.159 +2 -2 + NTP_4_2_7P157 + + ntpsnmpd/ntpsnmpd-opts.h@1.159 +3 -3 + NTP_4_2_7P157 + + ntpsnmpd/ntpsnmpd-opts.texi@1.159 +2 -2 + NTP_4_2_7P157 + + ntpsnmpd/ntpsnmpd.1@1.159 +2 -2 + NTP_4_2_7P157 + + packageinfo.sh@1.159 +1 -1 + NTP_4_2_7P157 + + sntp/sntp-opts.c@1.153 +2 -2 + NTP_4_2_7P157 + + sntp/sntp-opts.h@1.153 +3 -3 + NTP_4_2_7P157 + + sntp/sntp-opts.texi@1.153 +2 -2 + NTP_4_2_7P157 + + sntp/sntp.1@1.153 +2 -2 + NTP_4_2_7P157 + + sntp/sntp.html@1.153 +1 -1 + NTP_4_2_7P157 + + util/ntp-keygen-opts.c@1.157 +2 -2 + NTP_4_2_7P157 + + util/ntp-keygen-opts.h@1.157 +3 -3 + NTP_4_2_7P157 + + util/ntp-keygen-opts.texi@1.160 +2 -2 + NTP_4_2_7P157 + + util/ntp-keygen.1@1.160 +2 -2 + NTP_4_2_7P157 + +ChangeSet@1.2479.1.76, 2011-04-19 09:38:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1890] 4.2.7p156 segfault in duplicate freeaddrinfo(). + + ChangeLog@1.860 +1 -0 + [Bug 1890] 4.2.7p156 segfault in duplicate freeaddrinfo(). + + libntp/ntp_intres.c@1.97 +0 -1 + [Bug 1890] 4.2.7p156 segfault in duplicate freeaddrinfo(). + +ChangeSet@1.2479.1.75, 2011-04-19 06:55:02+00:00, stenn@deacon.udel.edu + NTP_4_2_7P156 + TAG: NTP_4_2_7P156 + + ChangeLog@1.859 +1 -0 + NTP_4_2_7P156 + + ntpd/ntpd-opts.c@1.161 +2 -2 + NTP_4_2_7P156 + + ntpd/ntpd-opts.h@1.161 +3 -3 + NTP_4_2_7P156 + + ntpd/ntpd-opts.texi@1.159 +2 -2 + NTP_4_2_7P156 + + ntpd/ntpd.1@1.159 +2 -2 + NTP_4_2_7P156 + + ntpdc/ntpdc-opts.c@1.158 +2 -2 + NTP_4_2_7P156 + + ntpdc/ntpdc-opts.h@1.158 +3 -3 + NTP_4_2_7P156 + + ntpdc/ntpdc-opts.texi@1.158 +2 -2 + NTP_4_2_7P156 + + ntpdc/ntpdc.1@1.158 +2 -2 + NTP_4_2_7P156 + + ntpq/ntpq-opts.c@1.158 +2 -2 + NTP_4_2_7P156 + + ntpq/ntpq-opts.h@1.158 +3 -3 + NTP_4_2_7P156 + + ntpq/ntpq-opts.texi@1.158 +2 -2 + NTP_4_2_7P156 + + ntpq/ntpq.1@1.158 +2 -2 + NTP_4_2_7P156 + + ntpsnmpd/ntpsnmpd-opts.c@1.158 +2 -2 + NTP_4_2_7P156 + + ntpsnmpd/ntpsnmpd-opts.h@1.158 +3 -3 + NTP_4_2_7P156 + + ntpsnmpd/ntpsnmpd-opts.texi@1.158 +2 -2 + NTP_4_2_7P156 + + ntpsnmpd/ntpsnmpd.1@1.158 +2 -2 + NTP_4_2_7P156 + + packageinfo.sh@1.158 +1 -1 + NTP_4_2_7P156 + + sntp/sntp-opts.c@1.152 +2 -2 + NTP_4_2_7P156 + + sntp/sntp-opts.h@1.152 +3 -3 + NTP_4_2_7P156 + + sntp/sntp-opts.texi@1.152 +2 -2 + NTP_4_2_7P156 + + sntp/sntp.1@1.152 +2 -2 + NTP_4_2_7P156 + + sntp/sntp.html@1.152 +1 -1 + NTP_4_2_7P156 + + util/ntp-keygen-opts.c@1.156 +2 -2 + NTP_4_2_7P156 + + util/ntp-keygen-opts.h@1.156 +3 -3 + NTP_4_2_7P156 + + util/ntp-keygen-opts.texi@1.159 +2 -2 + NTP_4_2_7P156 + + util/ntp-keygen.1@1.159 +2 -2 + NTP_4_2_7P156 + +ChangeSet@1.2479.1.74, 2011-04-18 22:32:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1851] freeaddrinfo() called after getaddrinfo() fails. + + ChangeLog@1.858 +1 -0 + [Bug 1851] freeaddrinfo() called after getaddrinfo() fails. + + libntp/ntp_intres.c@1.96 +8 -7 + [Bug 1851] freeaddrinfo() called after getaddrinfo() fails. + +ChangeSet@1.2479.1.73, 2011-04-18 04:58:45+00:00, stenn@deacon.udel.edu + NTP_4_2_7P155 + TAG: NTP_4_2_7P155 + + ChangeLog@1.857 +1 -0 + NTP_4_2_7P155 + + ntpd/ntpd-opts.c@1.160 +2 -2 + NTP_4_2_7P155 + + ntpd/ntpd-opts.h@1.160 +3 -3 + NTP_4_2_7P155 + + ntpd/ntpd-opts.texi@1.158 +2 -2 + NTP_4_2_7P155 + + ntpd/ntpd.1@1.158 +2 -2 + NTP_4_2_7P155 + + ntpdc/ntpdc-opts.c@1.157 +2 -2 + NTP_4_2_7P155 + + ntpdc/ntpdc-opts.h@1.157 +3 -3 + NTP_4_2_7P155 + + ntpdc/ntpdc-opts.texi@1.157 +2 -2 + NTP_4_2_7P155 + + ntpdc/ntpdc.1@1.157 +2 -2 + NTP_4_2_7P155 + + ntpq/ntpq-opts.c@1.157 +2 -2 + NTP_4_2_7P155 + + ntpq/ntpq-opts.h@1.157 +3 -3 + NTP_4_2_7P155 + + ntpq/ntpq-opts.texi@1.157 +2 -2 + NTP_4_2_7P155 + + ntpq/ntpq.1@1.157 +2 -2 + NTP_4_2_7P155 + + ntpsnmpd/ntpsnmpd-opts.c@1.157 +2 -2 + NTP_4_2_7P155 + + ntpsnmpd/ntpsnmpd-opts.h@1.157 +3 -3 + NTP_4_2_7P155 + + ntpsnmpd/ntpsnmpd-opts.texi@1.157 +2 -2 + NTP_4_2_7P155 + + ntpsnmpd/ntpsnmpd.1@1.157 +2 -2 + NTP_4_2_7P155 + + packageinfo.sh@1.157 +1 -1 + NTP_4_2_7P155 + + sntp/sntp-opts.c@1.151 +2 -2 + NTP_4_2_7P155 + + sntp/sntp-opts.h@1.151 +3 -3 + NTP_4_2_7P155 + + sntp/sntp-opts.texi@1.151 +2 -2 + NTP_4_2_7P155 + + sntp/sntp.1@1.151 +2 -2 + NTP_4_2_7P155 + + sntp/sntp.html@1.151 +1 -1 + NTP_4_2_7P155 + + util/ntp-keygen-opts.c@1.155 +2 -2 + NTP_4_2_7P155 + + util/ntp-keygen-opts.h@1.155 +3 -3 + NTP_4_2_7P155 + + util/ntp-keygen-opts.texi@1.158 +2 -2 + NTP_4_2_7P155 + + util/ntp-keygen.1@1.158 +2 -2 + NTP_4_2_7P155 + +ChangeSet@1.2479.1.72, 2011-04-17 20:08:44+00:00, davehart@shiny.ad.hartbrothers.com + Automerge of ChangeLog got it wrong. + + ChangeLog@1.856 +1 -1 + Automerge of ChangeLog got it wrong. + +ChangeSet@1.2479.11.1, 2011-04-17 11:32:14+00:00, stenn@deacon.udel.edu + NTP_4_2_7P154 + TAG: NTP_4_2_7P154 + + ChangeLog@1.853.1.1 +1 -0 + NTP_4_2_7P154 + + ntpd/ntpd-opts.c@1.159 +2 -2 + NTP_4_2_7P154 + + ntpd/ntpd-opts.h@1.159 +3 -3 + NTP_4_2_7P154 + + ntpd/ntpd-opts.texi@1.157 +2 -2 + NTP_4_2_7P154 + + ntpd/ntpd.1@1.157 +2 -2 + NTP_4_2_7P154 + + ntpdc/ntpdc-opts.c@1.156 +2 -2 + NTP_4_2_7P154 + + ntpdc/ntpdc-opts.h@1.156 +3 -3 + NTP_4_2_7P154 + + ntpdc/ntpdc-opts.texi@1.156 +2 -2 + NTP_4_2_7P154 + + ntpdc/ntpdc.1@1.156 +2 -2 + NTP_4_2_7P154 + + ntpq/ntpq-opts.c@1.156 +2 -2 + NTP_4_2_7P154 + + ntpq/ntpq-opts.h@1.156 +3 -3 + NTP_4_2_7P154 + + ntpq/ntpq-opts.texi@1.156 +2 -2 + NTP_4_2_7P154 + + ntpq/ntpq.1@1.156 +2 -2 + NTP_4_2_7P154 + + ntpsnmpd/ntpsnmpd-opts.c@1.156 +2 -2 + NTP_4_2_7P154 + + ntpsnmpd/ntpsnmpd-opts.h@1.156 +3 -3 + NTP_4_2_7P154 + + ntpsnmpd/ntpsnmpd-opts.texi@1.156 +2 -2 + NTP_4_2_7P154 + + ntpsnmpd/ntpsnmpd.1@1.156 +2 -2 + NTP_4_2_7P154 + + packageinfo.sh@1.156 +1 -1 + NTP_4_2_7P154 + + sntp/sntp-opts.c@1.150 +2 -2 + NTP_4_2_7P154 + + sntp/sntp-opts.h@1.150 +3 -3 + NTP_4_2_7P154 + + sntp/sntp-opts.texi@1.150 +2 -2 + NTP_4_2_7P154 + + sntp/sntp.1@1.150 +2 -2 + NTP_4_2_7P154 + + sntp/sntp.html@1.150 +1 -1 + NTP_4_2_7P154 + + util/ntp-keygen-opts.c@1.154 +2 -2 + NTP_4_2_7P154 + + util/ntp-keygen-opts.h@1.154 +3 -3 + NTP_4_2_7P154 + + util/ntp-keygen-opts.texi@1.157 +2 -2 + NTP_4_2_7P154 + + util/ntp-keygen.1@1.157 +2 -2 + NTP_4_2_7P154 + +ChangeSet@1.2479.1.70, 2011-04-17 08:22:57+00:00, davehart@shiny.ad.hartbrothers.com + Correct includes in lib/isc for strlcpy(), strlcat() prototypes. + + lib/isc/log.c@1.5 +1 -1 + Correct includes in lib/isc for strlcpy(), strlcat() prototypes. + + lib/isc/netaddr.c@1.11 +1 -1 + Correct includes in lib/isc for strlcpy(), strlcat() prototypes. + + lib/isc/unix/dir.c@1.3 +1 -1 + Correct includes in lib/isc for strlcpy(), strlcat() prototypes. + + lib/isc/unix/file.c@1.3 +1 -1 + Correct includes in lib/isc for strlcpy(), strlcat() prototypes. + +ChangeSet@1.2479.1.69, 2011-04-17 08:10:39+00:00, davehart@shiny.ad.hartbrothers.com + Fix leak in refclock_datum.c start failure path. + + ChangeLog@1.854 +1 -0 + Fix leak in refclock_datum.c start failure path. + + ntpd/refclock_datum.c@1.19 +1 -0 + Fix leak in refclock_datum.c start failure path. + +ChangeSet@1.2479.1.68, 2011-04-16 18:14:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1887] DNS fails on 4.2.7p153 using threads. + + ChangeLog@1.853 +1 -0 + [Bug 1887] DNS fails on 4.2.7p153 using threads. + + libntp/work_thread.c@1.9 +4 -3 + [Bug 1887] DNS fails on 4.2.7p153 using threads. + +ChangeSet@1.2479.1.67, 2011-04-16 07:31:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P153 + TAG: NTP_4_2_7P153 + + ChangeLog@1.852 +1 -0 + NTP_4_2_7P153 + + ntpd/ntpd-opts.c@1.158 +2 -2 + NTP_4_2_7P153 + + ntpd/ntpd-opts.h@1.158 +3 -3 + NTP_4_2_7P153 + + ntpd/ntpd-opts.texi@1.156 +2 -2 + NTP_4_2_7P153 + + ntpd/ntpd.1@1.156 +2 -2 + NTP_4_2_7P153 + + ntpdc/ntpdc-opts.c@1.155 +2 -2 + NTP_4_2_7P153 + + ntpdc/ntpdc-opts.h@1.155 +3 -3 + NTP_4_2_7P153 + + ntpdc/ntpdc-opts.texi@1.155 +2 -2 + NTP_4_2_7P153 + + ntpdc/ntpdc.1@1.155 +2 -2 + NTP_4_2_7P153 + + ntpq/ntpq-opts.c@1.155 +2 -2 + NTP_4_2_7P153 + + ntpq/ntpq-opts.h@1.155 +3 -3 + NTP_4_2_7P153 + + ntpq/ntpq-opts.texi@1.155 +2 -2 + NTP_4_2_7P153 + + ntpq/ntpq.1@1.155 +2 -2 + NTP_4_2_7P153 + + ntpsnmpd/ntpsnmpd-opts.c@1.155 +2 -2 + NTP_4_2_7P153 + + ntpsnmpd/ntpsnmpd-opts.h@1.155 +3 -3 + NTP_4_2_7P153 + + ntpsnmpd/ntpsnmpd-opts.texi@1.155 +2 -2 + NTP_4_2_7P153 + + ntpsnmpd/ntpsnmpd.1@1.155 +2 -2 + NTP_4_2_7P153 + + packageinfo.sh@1.155 +1 -1 + NTP_4_2_7P153 + + sntp/sntp-opts.c@1.149 +2 -2 + NTP_4_2_7P153 + + sntp/sntp-opts.h@1.149 +3 -3 + NTP_4_2_7P153 + + sntp/sntp-opts.texi@1.149 +2 -2 + NTP_4_2_7P153 + + sntp/sntp.1@1.149 +2 -2 + NTP_4_2_7P153 + + sntp/sntp.html@1.149 +1 -1 + NTP_4_2_7P153 + + util/ntp-keygen-opts.c@1.153 +2 -2 + NTP_4_2_7P153 + + util/ntp-keygen-opts.h@1.153 +3 -3 + NTP_4_2_7P153 + + util/ntp-keygen-opts.texi@1.156 +2 -2 + NTP_4_2_7P153 + + util/ntp-keygen.1@1.156 +2 -2 + NTP_4_2_7P153 + +ChangeSet@1.2479.1.66, 2011-04-15 19:53:04+00:00, davehart@shiny.ad.hartbrothers.com + A few more Coverity Scan cleanups. + + ChangeLog@1.851 +1 -0 + A few more Coverity Scan cleanups. + + lib/isc/inet_ntop.c@1.11 +6 -5 + strcpy() -> memcpy() + sprintf() -> snprintf() + + lib/isc/log.c@1.4 +5 -2 + strcpy() -> strlcpy() + + lib/isc/netaddr.c@1.10 +2 -1 + strcpy() -> strlcpy() + + lib/isc/task.c@1.5 +3 -1 + Lock manager object during destruction to keep Coverity Scan lock + analysis on track. + + lib/isc/unix/dir.c@1.2 +10 -5 + strcpy() -> strlcpy() + + lib/isc/unix/file.c@1.2 +6 -5 + strncpy() -> strlcpy() + strcat() -> strlcat() + + libntp/icom.c@1.16 +1 -1 + Add missed assignment in tcsetattr() error check. + + libntp/work_thread.c@1.8 +3 -1 + Another attempt at convincing Coverity sizeof(*hdr) - hdr->octets is + always positive. + + ntpd/refclock_datum.c@1.18 +7 -1 + Check tcsetattr() return value. + +ChangeSet@1.2461.1.3, 2011-04-15 11:33:32+00:00, davehart@shiny.ad.hartbrothers.com + libevent HEAD 20110415 11:33 UTC d28fc52815023113840fb9e108ada0126964a799 + + sntp/libevent/CommitLog@1.2 +19 -0 + libevent HEAD 20110415 11:33 UTC d28fc52815023113840fb9e108ada0126964a799 + + sntp/libevent/evdns.c@1.1.1.2 +2 -1 + libevent HEAD 20110415 11:33 UTC d28fc52815023113840fb9e108ada0126964a799 + + sntp/libevent/sample/http-server.c@1.1.1.2 +5 -4 + libevent HEAD 20110415 11:33 UTC d28fc52815023113840fb9e108ada0126964a799 + +ChangeSet@1.2479.1.64, 2011-04-15 08:46:52+00:00, stenn@deacon.udel.edu + NTP_4_2_7P152 + TAG: NTP_4_2_7P152 + + ChangeLog@1.850 +1 -0 + NTP_4_2_7P152 + + ntpd/ntpd-opts.c@1.157 +2 -2 + NTP_4_2_7P152 + + ntpd/ntpd-opts.h@1.157 +3 -3 + NTP_4_2_7P152 + + ntpd/ntpd-opts.texi@1.155 +2 -2 + NTP_4_2_7P152 + + ntpd/ntpd.1@1.155 +2 -2 + NTP_4_2_7P152 + + ntpdc/ntpdc-opts.c@1.154 +2 -2 + NTP_4_2_7P152 + + ntpdc/ntpdc-opts.h@1.154 +3 -3 + NTP_4_2_7P152 + + ntpdc/ntpdc-opts.texi@1.154 +2 -2 + NTP_4_2_7P152 + + ntpdc/ntpdc.1@1.154 +2 -2 + NTP_4_2_7P152 + + ntpq/ntpq-opts.c@1.154 +2 -2 + NTP_4_2_7P152 + + ntpq/ntpq-opts.h@1.154 +3 -3 + NTP_4_2_7P152 + + ntpq/ntpq-opts.texi@1.154 +2 -2 + NTP_4_2_7P152 + + ntpq/ntpq.1@1.154 +2 -2 + NTP_4_2_7P152 + + ntpsnmpd/ntpsnmpd-opts.c@1.154 +2 -2 + NTP_4_2_7P152 + + ntpsnmpd/ntpsnmpd-opts.h@1.154 +3 -3 + NTP_4_2_7P152 + + ntpsnmpd/ntpsnmpd-opts.texi@1.154 +2 -2 + NTP_4_2_7P152 + + ntpsnmpd/ntpsnmpd.1@1.154 +2 -2 + NTP_4_2_7P152 + + packageinfo.sh@1.154 +1 -1 + NTP_4_2_7P152 + + sntp/sntp-opts.c@1.148 +2 -2 + NTP_4_2_7P152 + + sntp/sntp-opts.h@1.148 +3 -3 + NTP_4_2_7P152 + + sntp/sntp-opts.texi@1.148 +2 -2 + NTP_4_2_7P152 + + sntp/sntp.1@1.148 +2 -2 + NTP_4_2_7P152 + + sntp/sntp.html@1.148 +1 -1 + NTP_4_2_7P152 + + util/ntp-keygen-opts.c@1.152 +2 -2 + NTP_4_2_7P152 + + util/ntp-keygen-opts.h@1.152 +3 -3 + NTP_4_2_7P152 + + util/ntp-keygen-opts.texi@1.155 +2 -2 + NTP_4_2_7P152 + + util/ntp-keygen.1@1.155 +2 -2 + NTP_4_2_7P152 + +ChangeSet@1.2479.1.63, 2011-04-15 00:12:03+00:00, davehart@shiny.ad.hartbrothers.com + Automerge cleanup + + ChangeLog@1.849 +1 -0 + Update embedded libevent to current 2.1 git HEAD. + + sntp/libevent/event.c@1.4 +2 -70 + Automerge cleanup + +ChangeSet@1.2461.1.2, 2011-04-14 23:28:43+00:00, davehart@shiny.ad.hartbrothers.com + overlooked file + + sntp/libevent/evconfig-private.h.in@1.1 +43 -0 + BitKeeper file C:/ntp/ntp-dev-libevent-upstream/sntp/libevent/evconfig-private.h.in + + sntp/libevent/evconfig-private.h.in@1.0 +0 -0 + +ChangeSet@1.2461.1.1, 2011-04-14 19:55:12+00:00, davehart@shiny.ad.hartbrothers.com + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/CommitLog@1.1 +18272 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/CommitLog@1.0 +0 -0 + + sntp/libevent/Makefile.am@1.1.1.1 +27 -24 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/WIN32-Code/evconfig-private.h@1.1 +6 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/WIN32-Code/evconfig-private.h@1.0 +0 -0 + + sntp/libevent/WIN32-Code/event2/event-config.h@1.1.1.1 +2 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/arc4random.c@1.1.1.1 +6 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/buffer.c@1.2 +283 -266 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/buffer_iocp.c@1.2 +2 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent-internal.h@1.2 +16 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent.c@1.2 +21 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent_async.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent_filter.c@1.2 +2 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent_openssl.c@1.2 +3 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent_pair.c@1.2 +2 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent_ratelim.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/bufferevent_sock.c@1.2 +3 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/configure.in@1.1.1.1 +162 -17 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/defer-internal.h@1.2 +2 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/devpoll.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/epoll.c@1.2 +251 -140 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/epoll_sub.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evbuffer-internal.h@1.2 +45 -12 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evdns.c@1.1.1.1 +7 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/event-internal.h@1.1.1.1 +13 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/event.c@1.1.1.1 +29 -7 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/event_iocp.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/event_tagging.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evmap.c@1.2 +8 -12 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evport.c@1.1.1.1 +15 -4 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evrpc.c@1.2 +8 -7 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evthread-internal.h@1.2 +3 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evthread.c@1.1.1.1 +13 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evthread_pthread.c@1.1.1.1 +4 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evthread_win32.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evutil.c@1.1.1.1 +94 -22 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/evutil_rand.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/http-internal.h@1.2 +2 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/http.c@1.1.1.1 +212 -47 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/include/event2/buffer.h@1.2 +102 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/include/event2/event.h@1.1.1.1 +13 -3 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/include/event2/http.h@1.2 +45 -3 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/ipv6-internal.h@1.1.1.1 +12 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/kqueue.c@1.2 +1 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/listener.c@1.2 +3 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/log.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/minheap-internal.h@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/poll.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/sample/Makefile.am@1.1.1.1 +1 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/sample/dns-example.c@1.1.1.1 +3 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/sample/hello-world.c@1.1.1.1 +3 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/sample/http-server.c@1.1.1.1 +6 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/select.c@1.1.1.1 +28 -9 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/signal.c@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/strlcpy-internal.h@1.2 +1 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/strlcpy.c@1.2 +3 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/Makefile.am@1.1.1.1 +14 -9 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/bench_httpclient.c@1.1.1.1 +3 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/regress.h@1.2 +1 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/regress_buffer.c@1.2 +219 -46 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/regress_dns.c@1.1.1.1 +2 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/regress_http.c@1.1.1.1 +62 -53 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/regress_listener.c@1.1.1.1 +3 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/regress_main.c@1.2 +5 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/regress_testutils.c@1.1.1.1 +2 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/test-eof.c@1.1.1.1 +9 -3 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/test-ratelim.c@1.1.1.1 +5 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/test-ratelim.sh@1.1 +77 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/test-ratelim.sh@1.0 +0 -0 + + sntp/libevent/test/test.sh@1.1.1.1 +12 -5 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/tinytest_demo.c@1.1 +215 -0 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/test/tinytest_demo.c@1.0 +0 -0 + + sntp/libevent/util-internal.h@1.1.1.1 +25 -2 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/whatsnew-2.0.txt@1.2 +1 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + + sntp/libevent/win32select.c@1.2 +2 -1 + libevent 2.1 (prerelease git head bfdda26534ea66b847760720260a4b4d8fcefe58) + +ChangeSet@1.2479.1.60, 2011-04-14 08:03:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P151 + TAG: NTP_4_2_7P151 + + ChangeLog@1.848 +1 -0 + NTP_4_2_7P151 + + ntpd/ntpd-opts.c@1.156 +2 -2 + NTP_4_2_7P151 + + ntpd/ntpd-opts.h@1.156 +3 -3 + NTP_4_2_7P151 + + ntpd/ntpd-opts.texi@1.154 +2 -2 + NTP_4_2_7P151 + + ntpd/ntpd.1@1.154 +2 -2 + NTP_4_2_7P151 + + ntpdc/ntpdc-opts.c@1.153 +2 -2 + NTP_4_2_7P151 + + ntpdc/ntpdc-opts.h@1.153 +3 -3 + NTP_4_2_7P151 + + ntpdc/ntpdc-opts.texi@1.153 +2 -2 + NTP_4_2_7P151 + + ntpdc/ntpdc.1@1.153 +2 -2 + NTP_4_2_7P151 + + ntpq/ntpq-opts.c@1.153 +2 -2 + NTP_4_2_7P151 + + ntpq/ntpq-opts.h@1.153 +3 -3 + NTP_4_2_7P151 + + ntpq/ntpq-opts.texi@1.153 +2 -2 + NTP_4_2_7P151 + + ntpq/ntpq.1@1.153 +2 -2 + NTP_4_2_7P151 + + ntpsnmpd/ntpsnmpd-opts.c@1.153 +2 -2 + NTP_4_2_7P151 + + ntpsnmpd/ntpsnmpd-opts.h@1.153 +3 -3 + NTP_4_2_7P151 + + ntpsnmpd/ntpsnmpd-opts.texi@1.153 +2 -2 + NTP_4_2_7P151 + + ntpsnmpd/ntpsnmpd.1@1.153 +2 -2 + NTP_4_2_7P151 + + packageinfo.sh@1.153 +1 -1 + NTP_4_2_7P151 + + sntp/sntp-opts.c@1.147 +2 -2 + NTP_4_2_7P151 + + sntp/sntp-opts.h@1.147 +3 -3 + NTP_4_2_7P151 + + sntp/sntp-opts.texi@1.147 +2 -2 + NTP_4_2_7P151 + + sntp/sntp.1@1.147 +2 -2 + NTP_4_2_7P151 + + sntp/sntp.html@1.147 +1 -1 + NTP_4_2_7P151 + + util/ntp-keygen-opts.c@1.151 +2 -2 + NTP_4_2_7P151 + + util/ntp-keygen-opts.h@1.151 +3 -3 + NTP_4_2_7P151 + + util/ntp-keygen-opts.texi@1.154 +2 -2 + NTP_4_2_7P151 + + util/ntp-keygen.1@1.154 +2 -2 + NTP_4_2_7P151 + +ChangeSet@1.2479.1.59, 2011-04-14 05:30:10+00:00, davehart@shiny.ad.hartbrothers.com + Log failure to fetch time from HOPF_P hardware. + Check HOPF_S sscanf() conversion count before converted values. + Correct mvsnprintf() and mvfprintf() for vsnprintf() that handles %m. + + ChangeLog@1.847 +2 -0 + Log failure to fetch time from HOPF_P hardware. + Check HOPF_S sscanf() conversion count before converted values. + + libntp/msyslog.c@1.42 +59 -54 + Correct mvsnprintf() and mvfprintf() for vsnprintf() that handles %m. + + ntpd/refclock_hopfpci.c@1.13 +3 -1 + Log failure to fetch time from HOPF_P hardware. + + ntpd/refclock_hopfser.c@1.16 +11 -10 + Check HOPF_S sscanf() conversion count before converted values. + + sntp/crypto.c@1.17 +2 -1 + Minor leak fix. + + sntp/main.c@1.71 +7 -7 + nonfunctional, makes static analysis happy. + +ChangeSet@1.2479.1.58, 2011-04-14 02:00:02+00:00, davehart@shiny.ad.hartbrothers.com + Detect vsnprintf() support for "%m" and disable our "%m" expansion. + Add --enable-c99-sprintf to configure args for -noopenssl variety of + flock-build to avoid regressions in (v)snprintf() replacement. + More msnprintf() unit tests. + Coverity Scan error checking fixes. + + ChangeLog@1.846 +5 -0 + Detect vsnprintf() support for "%m" and disable our "%m" expansion. + Add --enable-c99-sprintf to configure args for -noopenssl variety of + flock-build to avoid regressions in (v)snprintf() replacement. + More msnprintf() unit tests. + Coverity Scan error checking fixes. + + flock-build@1.51 +2 -2 + Add --enable-c99-sprintf to configure args for -noopenssl variety of + flock-build to avoid regressions in (v)snprintf() replacement. + + libntp/audio.c@1.31 +8 -8 + check sscanf() return values + + libntp/msyslog.c@1.41 +71 -66 + Detect vsnprintf() support for "%m" and disable our "%m" expansion. + Remove pre-C99-snprintf() workaround. + + libntp/snprintf.c@1.11 +1 -0 + Add /* FALLTHROUGH */ comment to %F handling. + + ntpd/refclock_arc.c@1.25 +30 -27 + use msyslog instead of printf for failure to open clock. + + ntpq/ntpq-subs.c@1.87 +10 -3 + Check decodenetnum() return value. + + ntpq/ntpq.c@1.138 +3 -3 + printf format mismatch on 64-bit. + + parseutil/dcfd.c@1.24 +2 -2 + printf format mismatch on 64-bit. + + sntp/m4/ntp_libntp.m4@1.14 +62 -0 + Detect vsnprintf() support for "%m" and disable our "%m" expansion. + + tests/libntp/msyslog.cpp@1.3 +74 -22 + More msnprintf() unit tests. + +ChangeSet@1.2479.1.57, 2011-04-13 04:57:19+00:00, stenn@deacon.udel.edu + NTP_4_2_7P150 + TAG: NTP_4_2_7P150 + + ChangeLog@1.845 +1 -0 + NTP_4_2_7P150 + + ntpd/ntpd-opts.c@1.155 +2 -2 + NTP_4_2_7P150 + + ntpd/ntpd-opts.h@1.155 +3 -3 + NTP_4_2_7P150 + + ntpd/ntpd-opts.texi@1.153 +2 -2 + NTP_4_2_7P150 + + ntpd/ntpd.1@1.153 +2 -2 + NTP_4_2_7P150 + + ntpdc/ntpdc-opts.c@1.152 +2 -2 + NTP_4_2_7P150 + + ntpdc/ntpdc-opts.h@1.152 +3 -3 + NTP_4_2_7P150 + + ntpdc/ntpdc-opts.texi@1.152 +2 -2 + NTP_4_2_7P150 + + ntpdc/ntpdc.1@1.152 +2 -2 + NTP_4_2_7P150 + + ntpq/ntpq-opts.c@1.152 +2 -2 + NTP_4_2_7P150 + + ntpq/ntpq-opts.h@1.152 +3 -3 + NTP_4_2_7P150 + + ntpq/ntpq-opts.texi@1.152 +2 -2 + NTP_4_2_7P150 + + ntpq/ntpq.1@1.152 +2 -2 + NTP_4_2_7P150 + + ntpsnmpd/ntpsnmpd-opts.c@1.152 +2 -2 + NTP_4_2_7P150 + + ntpsnmpd/ntpsnmpd-opts.h@1.152 +3 -3 + NTP_4_2_7P150 + + ntpsnmpd/ntpsnmpd-opts.texi@1.152 +2 -2 + NTP_4_2_7P150 + + ntpsnmpd/ntpsnmpd.1@1.152 +2 -2 + NTP_4_2_7P150 + + packageinfo.sh@1.152 +1 -1 + NTP_4_2_7P150 + + sntp/sntp-opts.c@1.146 +2 -2 + NTP_4_2_7P150 + + sntp/sntp-opts.h@1.146 +3 -3 + NTP_4_2_7P150 + + sntp/sntp-opts.texi@1.146 +2 -2 + NTP_4_2_7P150 + + sntp/sntp.1@1.146 +2 -2 + NTP_4_2_7P150 + + sntp/sntp.html@1.146 +1 -1 + NTP_4_2_7P150 + + util/ntp-keygen-opts.c@1.150 +2 -2 + NTP_4_2_7P150 + + util/ntp-keygen-opts.h@1.150 +3 -3 + NTP_4_2_7P150 + + util/ntp-keygen-opts.texi@1.153 +2 -2 + NTP_4_2_7P150 + + util/ntp-keygen.1@1.153 +2 -2 + NTP_4_2_7P150 + +ChangeSet@1.2479.1.56, 2011-04-13 02:22:24+00:00, davehart@shiny.ad.hartbrothers.com + ntp_proto.c sprintf() -> snprintf() + + ChangeLog@1.844 +1 -1 + ntp_proto.c sprintf() -> snprintf() + + ntpd/ntp_proto.c@1.320 +3 -2 + ntp_proto.c sprintf() -> snprintf() + +ChangeSet@1.2479.1.55, 2011-04-13 01:02:31+00:00, davehart@shiny.ad.hartbrothers.com + Move rpl_vsnprintf() declaration and #define vsnprintf to config.h + + include/l_stdlib.h@1.20 +0 -10 + Move rpl_vsnprintf() declaration and #define vsnprintf to config.h + + lib/isc/inet_ntop.c@1.10 +2 -3 + leftover SNPRINTF() -> snprintf() overlooked in prior cset. + + libntp/msyslog.c@1.40 +19 -2 + Work around strerror_r return type misdetection. + + ports/winnt/include/config.h@1.97 +5 -0 + Move rpl_vsnprintf() declaration and #define vsnprintf to config.h + + ports/winnt/libntp/syslog.c@1.11 +2 -0 + include ntp_stdlib.h for strlcpy() declaration + + sntp/m4/ntp_libntp.m4@1.13 +45 -19 + Move rpl_vsnprintf() declaration and #define vsnprintf to config.h + + sntp/m4/snprintf.m4@1.2 +1 -6 + Update comment. + + tests/libntp/msyslog.cpp@1.2 +1 -0 + strerror() prototyped by string.h + +ChangeSet@1.2479.1.54, 2011-04-12 06:01:57+00:00, davehart@shiny.ad.hartbrothers.com + Remove remaining sprintf() calls except refclock_ripencc.c (which is + kept out of --enable-all-clocks as a result), upstream libs which use + sprintf() ony after careful buffer sizing, and ntp_proto.c. + + BitKeeper/deleted/14/ntp_sprintf.h~a4bd6474a120d477@1.2 +0 -0 + Delete: include/ntp_sprintf.h + + BitKeeper/deleted/53/refclock_trimbledc.c~29080509@1.5 +0 -0 + Delete: ports/winnt/ntpd/refclock_trimbledc.c + + BitKeeper/deleted/ab/refclock_trimbledc.h~29080509@1.4 +0 -0 + Delete: ports/winnt/ntpd/refclock_trimbledc.h + + ChangeLog@1.843 +3 -0 + Remove remaining sprintf() calls except refclock_ripencc.c (which is + kept out of --enable-all-clocks as a result), upstream libs which use + sprintf() ony after careful buffer sizing, and ntp_proto.c. + + configure.ac@1.525 +0 -6 + SPRINTF_CHAR check is not needed, ANSI C mandates int return type. + + include/Makefile.am@1.49 +0 -1 + Remove ntp_sprintf.h workaround for pre-ANSI C sprintf(). + + lib/isc/inet_ntop.c@1.9 +1 -3 + Remove ntp_sprintf.h workaround for pre-ANSI C sprintf(). + + libntp/bsd_strerror.c@1.6 +4 -3 + sprintf() -> snprintf(). + + libntp/snprintf.c@1.10 +4 -4 + clarify HAVE_* macros in non-Autoconf use. + + libparse/ieee754io.c@1.11 +19 -15 + sprintf() -> snprintf(). + + ntpd/refclock_mx4200.c@1.30 +0 -2 + Remove ntp_sprintf.h workaround for pre-ANSI C sprintf(). + + ntpd/refclock_tpro.c@1.13 +1 -1 + comment only. + + ntpd/refclock_tt560.c@1.3 +6 -6 + sprintf() -> snprintf(). + + ntpd/refclock_wwv.c@1.77 +2 -2 + sprintf() -> snprintf(). + + ntpdate/ntptimeset.c@1.15 +4 -29 + sprintf() -> msyslog(). + Remove replacement vsprintf(), ANSI C mandates it. + + ports/winnt/include/config.h@1.96 +4 -2 + Comment out #define vsnprintf _vsnprintf as l_stdlib.h #defines them now. + + ports/winnt/libntp/syslog.c@1.10 +1 -1 + vsprintf() -> vsnprintf(). + + ports/winnt/ntpd/hopf_PCI_io.c@1.9 +2 -0 + include ntp_stdlib.h for snprintf define. + + ports/winnt/vs2003/libntp.vcproj@1.22 +0 -3 + Remove ntp_sprintf.h workaround for pre-ANSI C sprintf(). + + ports/winnt/vs2005/libntp.vcproj@1.20 +0 -4 + Remove ntp_sprintf.h workaround for pre-ANSI C sprintf(). + + ports/winnt/vs2008/libntp/libntp.vcproj@1.43 +0 -4 + Remove ntp_sprintf.h workaround for pre-ANSI C sprintf(). + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.40 +4 -0 + add refclock_tt560.c + + util/audio-pcm.c@1.2 +2 -2 + sprintf() -> snprintf(). + + util/sht.c@1.4 +1 -1 + sprintf() -> snprintf(). + + util/tg.c@1.5 +8 -7 + sprintf() -> snprintf(). + + util/tg2.c@1.5 +28 -19 + sprintf() -> snprintf(). + +ChangeSet@1.2479.9.1, 2011-04-11 21:24:15+00:00, davehart@shiny.ad.hartbrothers.com + Remove never-used, incomplete ports/winnt/ntpd/refclock_trimbledc.[ch] + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + + ChangeLog@1.839.1.1 +3 -0 + Remove never-used, incomplete ports/winnt/ntpd/refclock_trimbledc.[ch] + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + + configure.ac@1.521.1.1 +2 -2 + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + + include/l_stdlib.h@1.19 +6 -6 + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + + include/ntp_machine.h@1.35 +0 -1 + Remove unused MAXHOSTNAMELEN. + + libntp/ntp_intres.c@1.95 +1 -1 + Remove unused MAXHOSTNAMELEN. + + libntp/snprintf.c@1.9 +2115 -44 + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + + ntpd/ntp_io.c@1.352 +3 -1 + Add #ifdef REFCLOCK to quiet input_handler() unused locals warning. + + ntpdate/ntpdate.c@1.88 +0 -51 + vsprintf() is required by ANSI C, remove fallback implementation. + Remove #if 0'd signal_no_reset() replacement. + + ntpq/ntpq.c@1.137 +2 -2 + Correct printf() format mismatch on 64-bit systems. + + parseutil/Makefile.am@1.16 +1 -1 + dcfd needs libntp.a when using rpl_snprintf(). + + ports/winnt/include/config.h@1.95 +23 -24 + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + Remove unused MAXHOSTNAMELEN. + + ports/winnt/ntpd/hopf_PCI_io.c@1.8 +6 -0 + #ifdef away unused code. + + ports/winnt/vc6/libntp.dsp@1.63 +4 -0 + add libntp/snprintf.c reference. + + ports/winnt/vs2003/libntp.vcproj@1.21 +4 -344 + add libntp/snprintf.c reference. + + ports/winnt/vs2005/libntp.vcproj@1.19 +4 -0 + add libntp/snprintf.c reference. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.42 +6 -2 + add libntp/snprintf.c reference. + + sntp/configure.ac@1.58.1.1 +1 -1 + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + + sntp/m4/ntp_libntp.m4@1.9.1.1 +27 -1 + On systems without C99-compliant (v)snprintf(), use C99-snprintf + replacements. (http://www.jhweiss.de/software/snprintf.html) + + sntp/m4/snprintf.m4@1.1 +293 -0 + BitKeeper file C:/ntp/ntp-dev-C99-snprintf/sntp/m4/snprintf.m4 + --- + Adapt snprintf.m4 for integration in NTP. + + sntp/m4/snprintf.m4@1.0 +0 -0 + +ChangeSet@1.2479.1.52, 2011-04-11 07:20:42+00:00, stenn@deacon.udel.edu + NTP_4_2_7P149 + TAG: NTP_4_2_7P149 + + ChangeLog@1.841 +1 -0 + NTP_4_2_7P149 + + ntpd/ntpd-opts.c@1.154 +2 -2 + NTP_4_2_7P149 + + ntpd/ntpd-opts.h@1.154 +3 -3 + NTP_4_2_7P149 + + ntpd/ntpd-opts.texi@1.152 +2 -2 + NTP_4_2_7P149 + + ntpd/ntpd.1@1.152 +2 -2 + NTP_4_2_7P149 + + ntpdc/ntpdc-opts.c@1.151 +2 -2 + NTP_4_2_7P149 + + ntpdc/ntpdc-opts.h@1.151 +3 -3 + NTP_4_2_7P149 + + ntpdc/ntpdc-opts.texi@1.151 +2 -2 + NTP_4_2_7P149 + + ntpdc/ntpdc.1@1.151 +2 -2 + NTP_4_2_7P149 + + ntpq/ntpq-opts.c@1.151 +2 -2 + NTP_4_2_7P149 + + ntpq/ntpq-opts.h@1.151 +3 -3 + NTP_4_2_7P149 + + ntpq/ntpq-opts.texi@1.151 +2 -2 + NTP_4_2_7P149 + + ntpq/ntpq.1@1.151 +2 -2 + NTP_4_2_7P149 + + ntpsnmpd/ntpsnmpd-opts.c@1.151 +2 -2 + NTP_4_2_7P149 + + ntpsnmpd/ntpsnmpd-opts.h@1.151 +3 -3 + NTP_4_2_7P149 + + ntpsnmpd/ntpsnmpd-opts.texi@1.151 +2 -2 + NTP_4_2_7P149 + + ntpsnmpd/ntpsnmpd.1@1.151 +2 -2 + NTP_4_2_7P149 + + packageinfo.sh@1.151 +1 -1 + NTP_4_2_7P149 + + sntp/sntp-opts.c@1.145 +2 -2 + NTP_4_2_7P149 + + sntp/sntp-opts.h@1.145 +3 -3 + NTP_4_2_7P149 + + sntp/sntp-opts.texi@1.145 +2 -2 + NTP_4_2_7P149 + + sntp/sntp.1@1.145 +2 -2 + NTP_4_2_7P149 + + sntp/sntp.html@1.145 +1 -1 + NTP_4_2_7P149 + + util/ntp-keygen-opts.c@1.149 +2 -2 + NTP_4_2_7P149 + + util/ntp-keygen-opts.h@1.149 +3 -3 + NTP_4_2_7P149 + + util/ntp-keygen-opts.texi@1.152 +2 -2 + NTP_4_2_7P149 + + util/ntp-keygen.1@1.152 +2 -2 + NTP_4_2_7P149 + +ChangeSet@1.2479.1.51, 2011-04-10 22:39:36-07:00, harlan@hms-mbp.local + Cleanup autoconf macro ordering/dependencies + + configure.ac@1.523 +1 -0 + Cleanup autoconf macro ordering/dependencies + + sntp/configure.ac@1.59 +1 -0 + Cleanup autoconf macro ordering/dependencies + + sntp/m4/ntp_libntp.m4@1.11 +1 -12 + Cleanup autoconf macro ordering/dependencies + + sntp/m4/ntp_prog_cc.m4@1.1 +21 -0 + BitKeeper file /Users/harlan/src/ntp-dev/sntp/m4/ntp_prog_cc.m4 + + sntp/m4/ntp_prog_cc.m4@1.0 +0 -0 + +ChangeSet@1.2479.1.50, 2011-04-10 18:45:38-07:00, harlan@hms-mbp.local + [Bug 1881] describe the {+,-,s} characters in configure --help output + + ChangeLog@1.840 +1 -0 + [Bug 1881] describe the {+,-,s} characters in configure --help output + +ChangeSet@1.2479.8.1, 2011-04-10 18:39:40-07:00, harlan@hms-mbp.local + Bug 1881: describe the {+,-,s} characters in configure --help output + + configure.ac@1.522 +5 -2 + Bug 1881: describe the {+,-,s} characters in configure --help output + + sntp/m4/ntp_googletest.m4@1.4 +1 -1 + Bug 1881: describe the {+,-,s} characters in configure --help output + + sntp/m4/ntp_libntp.m4@1.10 +10 -2 + Bug 1881: describe the {+,-,s} characters in configure --help output + +ChangeSet@1.2479.1.48, 2011-04-09 07:09:13+00:00, stenn@deacon.udel.edu + NTP_4_2_7P148 + TAG: NTP_4_2_7P148 + + ChangeLog@1.839 +1 -0 + NTP_4_2_7P148 + + ntpd/ntpd-opts.c@1.153 +2 -2 + NTP_4_2_7P148 + + ntpd/ntpd-opts.h@1.153 +3 -3 + NTP_4_2_7P148 + + ntpd/ntpd-opts.texi@1.151 +2 -2 + NTP_4_2_7P148 + + ntpd/ntpd.1@1.151 +2 -2 + NTP_4_2_7P148 + + ntpdc/ntpdc-opts.c@1.150 +2 -2 + NTP_4_2_7P148 + + ntpdc/ntpdc-opts.h@1.150 +3 -3 + NTP_4_2_7P148 + + ntpdc/ntpdc-opts.texi@1.150 +2 -2 + NTP_4_2_7P148 + + ntpdc/ntpdc.1@1.150 +2 -2 + NTP_4_2_7P148 + + ntpq/ntpq-opts.c@1.150 +2 -2 + NTP_4_2_7P148 + + ntpq/ntpq-opts.h@1.150 +3 -3 + NTP_4_2_7P148 + + ntpq/ntpq-opts.texi@1.150 +2 -2 + NTP_4_2_7P148 + + ntpq/ntpq.1@1.150 +2 -2 + NTP_4_2_7P148 + + ntpsnmpd/ntpsnmpd-opts.c@1.150 +2 -2 + NTP_4_2_7P148 + + ntpsnmpd/ntpsnmpd-opts.h@1.150 +3 -3 + NTP_4_2_7P148 + + ntpsnmpd/ntpsnmpd-opts.texi@1.150 +2 -2 + NTP_4_2_7P148 + + ntpsnmpd/ntpsnmpd.1@1.150 +2 -2 + NTP_4_2_7P148 + + packageinfo.sh@1.150 +1 -1 + NTP_4_2_7P148 + + sntp/sntp-opts.c@1.144 +2 -2 + NTP_4_2_7P148 + + sntp/sntp-opts.h@1.144 +3 -3 + NTP_4_2_7P148 + + sntp/sntp-opts.texi@1.144 +2 -2 + NTP_4_2_7P148 + + sntp/sntp.1@1.144 +2 -2 + NTP_4_2_7P148 + + sntp/sntp.html@1.144 +1 -1 + NTP_4_2_7P148 + + util/ntp-keygen-opts.c@1.148 +2 -2 + NTP_4_2_7P148 + + util/ntp-keygen-opts.h@1.148 +3 -3 + NTP_4_2_7P148 + + util/ntp-keygen-opts.texi@1.151 +2 -2 + NTP_4_2_7P148 + + util/ntp-keygen.1@1.151 +2 -2 + NTP_4_2_7P148 + +ChangeSet@1.2479.1.47, 2011-04-09 06:20:32+00:00, davehart@shiny.ad.hartbrothers.com + Buffer safety and sign extension fixes (thanks Coverity Scan). + + ChangeLog@1.838 +1 -0 + Buffer safety and sign extension fixes (thanks Coverity Scan). + + libntp/icom.c@1.15 +18 -3 + Check for failure of tcgetattr() and tcsetattr() in icom_init(). + + libparse/binio.c@1.8 +2 -2 + Avoid sign-extension on 64-bit platforms. + + libparse/ieee754io.c@1.10 +5 -5 + Avoid sign-extension on 64-bit platforms. + + ntpd/refclock_fg.c@1.14 +86 -91 + Whitespace cleanup of refclock_fg.c. + Replace literal ctrl-P with '\x10'. + sprintf() -> snprintf(). + + ntpd/refclock_ulink.c@1.17 +1 -1 + sprintf() -> snprintf(). + + ntpd/refclock_wwv.c@1.76 +8 -6 + sprintf() -> snprintf(). + + ntpd/refclock_zyfer.c@1.9 +1 -1 + sprintf() -> snprintf(). + + ntpq/ntpq.c@1.136 +2 -2 + printf signed/unsigned format mismatch. + + parseutil/dcfd.c@1.23 +10 -5 + printf signed/unsigned format mismatch. + sprintf() -> snprintf(). + + util/ntptime.c@1.23 +120 -93 + sprintf() -> snprintf(). + Protect against buffer overrun in sprintb(). + +ChangeSet@1.2479.7.4, 2011-04-08 02:02:48+00:00, davehart@shiny.ad.hartbrothers.com + Use _mkgmtime() as timegm() in the Windows port, rather than + libntp/mktime.c's timegm(). Fixed [Bug 1875] on Windows using the old + asn2ntp() code from before 4.2.7p147. + ntp_crypto.c string buffer safety. + Remove use of MAXFILENAME in mode 7 (ntpdc) on-wire structs. + Change ntpd MAXFILENAME from 128 to 256 to match ntp-keygen. + + ChangeLog@1.834.1.1 +6 -0 + Use _mkgmtime() as timegm() in the Windows port, rather than + libntp/mktime.c's timegm(). Fixed [Bug 1875] on Windows using the old + asn2ntp() code from before 4.2.7p147. + ntp_crypto.c string buffer safety. + Remove use of MAXFILENAME in mode 7 (ntpdc) on-wire structs. + Change ntpd MAXFILENAME from 128 to 256 to match ntp-keygen. + + include/ntp.h@1.193 +1 -1 + Change ntpd's MAXFILENAME to 256 to match what ntp-keygen uses. + + include/ntp_request.h@1.43 +6 -5 + Remove use of MAXFILENAME in mode 7 (ntpdc) on-wire structs. + + ntpd/ntp_control.c@1.167 +2 -2 + use sizeof(buffer) rather than inside knowledge of buffer size. + + ntpd/ntp_crypto.c@1.155.1.1 +46 -51 + emalloc() + strcpy() -> estrdup(). + fstostr() + strcpy() + fstostr() + strcpy() + snprintf() + report_event() + -> fstostr() + mprintf_event(). + Use sizeof(buffer) rather than hardcoded knowledge of buffer size. + + ntpd/ntp_util.c@1.94 +2 -5 + fstostr() can now safely return strings longer than 19 characters. + + ports/winnt/include/config.h@1.94 +2 -0 + Use _mkgmtime() as timegm() in the Windows port, rather than + libntp/mktime.c's timegm(). Fixes [Bug 1875] on Windows, however that + bug is still present on systems without timegm(). + + sntp/tests/keyFile.cpp@1.4 +7 -6 + strncpy() -> strlcpy() + + util/ntp-keygen.c@1.81 +26 -21 + Remove duplicate BN_CTX_new() call from gen_gqkey(), flagged by Coverity. + +ChangeSet@1.2479.1.45, 2011-04-07 11:30:15+00:00, stenn@deacon.udel.edu + NTP_4_2_7P147 + TAG: NTP_4_2_7P147 + + ChangeLog@1.836 +1 -0 + NTP_4_2_7P147 + + ntpd/ntpd-opts.c@1.152 +2 -2 + NTP_4_2_7P147 + + ntpd/ntpd-opts.h@1.152 +3 -3 + NTP_4_2_7P147 + + ntpd/ntpd-opts.texi@1.150 +2 -2 + NTP_4_2_7P147 + + ntpd/ntpd.1@1.150 +2 -2 + NTP_4_2_7P147 + + ntpdc/ntpdc-opts.c@1.149 +2 -2 + NTP_4_2_7P147 + + ntpdc/ntpdc-opts.h@1.149 +3 -3 + NTP_4_2_7P147 + + ntpdc/ntpdc-opts.texi@1.149 +2 -2 + NTP_4_2_7P147 + + ntpdc/ntpdc.1@1.149 +2 -2 + NTP_4_2_7P147 + + ntpq/ntpq-opts.c@1.149 +2 -2 + NTP_4_2_7P147 + + ntpq/ntpq-opts.h@1.149 +3 -3 + NTP_4_2_7P147 + + ntpq/ntpq-opts.texi@1.149 +2 -2 + NTP_4_2_7P147 + + ntpq/ntpq.1@1.149 +2 -2 + NTP_4_2_7P147 + + ntpsnmpd/ntpsnmpd-opts.c@1.149 +2 -2 + NTP_4_2_7P147 + + ntpsnmpd/ntpsnmpd-opts.h@1.149 +3 -3 + NTP_4_2_7P147 + + ntpsnmpd/ntpsnmpd-opts.texi@1.149 +2 -2 + NTP_4_2_7P147 + + ntpsnmpd/ntpsnmpd.1@1.149 +2 -2 + NTP_4_2_7P147 + + packageinfo.sh@1.149 +1 -1 + NTP_4_2_7P147 + + sntp/sntp-opts.c@1.143 +2 -2 + NTP_4_2_7P147 + + sntp/sntp-opts.h@1.143 +3 -3 + NTP_4_2_7P147 + + sntp/sntp-opts.texi@1.143 +2 -2 + NTP_4_2_7P147 + + sntp/sntp.1@1.143 +2 -2 + NTP_4_2_7P147 + + sntp/sntp.html@1.143 +1 -1 + NTP_4_2_7P147 + + util/ntp-keygen-opts.c@1.147 +2 -2 + NTP_4_2_7P147 + + util/ntp-keygen-opts.h@1.147 +3 -3 + NTP_4_2_7P147 + + util/ntp-keygen-opts.texi@1.150 +2 -2 + NTP_4_2_7P147 + + util/ntp-keygen.1@1.150 +2 -2 + NTP_4_2_7P147 + +ChangeSet@1.2479.1.43, 2011-04-05 19:23:34+02:00, jnperlin@hydra.localnet + [bug 1875] 'asn2ntp()' rewritten in terms of 'caltontp()' (ChangeLog update) + + ChangeLog@1.832.1.1 +2 -0 + [bug 1875] 'asn2ntp()' rewritten in terms of 'caltontp()' + +ChangeSet@1.2479.7.3, 2011-04-05 07:50:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P146 + TAG: NTP_4_2_7P146 + + ChangeLog@1.834 +1 -0 + NTP_4_2_7P146 + + ntpd/ntpd-opts.c@1.151 +2 -2 + NTP_4_2_7P146 + + ntpd/ntpd-opts.h@1.151 +3 -3 + NTP_4_2_7P146 + + ntpd/ntpd-opts.texi@1.149 +2 -2 + NTP_4_2_7P146 + + ntpd/ntpd.1@1.149 +2 -2 + NTP_4_2_7P146 + + ntpdc/ntpdc-opts.c@1.148 +2 -2 + NTP_4_2_7P146 + + ntpdc/ntpdc-opts.h@1.148 +3 -3 + NTP_4_2_7P146 + + ntpdc/ntpdc-opts.texi@1.148 +2 -2 + NTP_4_2_7P146 + + ntpdc/ntpdc.1@1.148 +2 -2 + NTP_4_2_7P146 + + ntpq/ntpq-opts.c@1.148 +2 -2 + NTP_4_2_7P146 + + ntpq/ntpq-opts.h@1.148 +3 -3 + NTP_4_2_7P146 + + ntpq/ntpq-opts.texi@1.148 +2 -2 + NTP_4_2_7P146 + + ntpq/ntpq.1@1.148 +2 -2 + NTP_4_2_7P146 + + ntpsnmpd/ntpsnmpd-opts.c@1.148 +2 -2 + NTP_4_2_7P146 + + ntpsnmpd/ntpsnmpd-opts.h@1.148 +3 -3 + NTP_4_2_7P146 + + ntpsnmpd/ntpsnmpd-opts.texi@1.148 +2 -2 + NTP_4_2_7P146 + + ntpsnmpd/ntpsnmpd.1@1.148 +2 -2 + NTP_4_2_7P146 + + packageinfo.sh@1.148 +1 -1 + NTP_4_2_7P146 + + sntp/sntp-opts.c@1.142 +2 -2 + NTP_4_2_7P146 + + sntp/sntp-opts.h@1.142 +3 -3 + NTP_4_2_7P146 + + sntp/sntp-opts.texi@1.142 +2 -2 + NTP_4_2_7P146 + + sntp/sntp.1@1.142 +2 -2 + NTP_4_2_7P146 + + sntp/sntp.html@1.142 +1 -1 + NTP_4_2_7P146 + + util/ntp-keygen-opts.c@1.146 +2 -2 + NTP_4_2_7P146 + + util/ntp-keygen-opts.h@1.146 +3 -3 + NTP_4_2_7P146 + + util/ntp-keygen-opts.texi@1.149 +2 -2 + NTP_4_2_7P146 + + util/ntp-keygen.1@1.149 +2 -2 + NTP_4_2_7P146 + +ChangeSet@1.2479.7.2, 2011-04-05 07:30:59+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog entry for prior cset. + String buffer safety cleanup, converting to strlcpy() and strlcat(). + Use utmpname() before pututline() so repeated steps do not + accidentally record into wtmp where utmp was intended. + Use setutent() before each pututline() including first. + + ChangeLog@1.833 +4 -0 + ChangeLog entry for prior cset. + String buffer safety cleanup, converting to strlcpy() and strlcat(). + Use utmpname() before pututline() so repeated steps do not + accidentally record into wtmp where utmp was intended. + Use setutent() before each pututline() including first. + +ChangeSet@1.2479.7.1, 2011-04-05 07:05:55+00:00, davehart@shiny.ad.hartbrothers.com + String buffer safety cleanup, converting to strlcpy() and strlcat(). + Use utmpname() before pututline() so repeated steps do not accidentally + record into wtmp where utmp was intended. + Use setutent() before each pututline() including first. + + BitKeeper/deleted/e7/ntp_resolver.c~47dd06e9@1.19 +0 -0 + Rename: ntpd/ntp_resolver.c -> BitKeeper/deleted/e7/ntp_resolver.c~47dd06e9 + + include/ntp_stdlib.h@1.62 +21 -0 + Conditional declarations for strlcpy(), strlcat() for systems which + do not provide them. + + libntp/Makefile.am@1.62 +1 -0 + add strl_obsd.c containing fallback strlcpy() and strlcat() picked up + from OpenBSD. + + libntp/audio.c@1.30 +4 -4 + strncpy() -> strlcpy() + + libntp/authkeys.c@1.22 +2 -2 + strncpy() -> strlcpy() + + libntp/decodenetnum.c@1.14 +1 -1 + strncpy() -> strlcpy() + + libntp/findconfig.c@1.5 +2 -2 + strncpy() -> strlcpy() + + libntp/msyslog.c@1.39 +1 -1 + strncpy() -> strlcpy() + + libntp/ntp_rfc2553.c@1.46 +1 -10 + strncpy() -> strlcpy() + + libntp/numtoa.c@1.7 +1 -1 + strncpy() -> memcpy() + + libntp/numtohost.c@1.6 +2 -3 + strncpy() -> strlcpy() + + libntp/socktoa.c@1.16 +1 -1 + strncpy() -> strlcpy() + + libntp/ssl_init.c@1.15 +1 -1 + strncpy() -> strlcpy() + + libntp/strl_obsd.c@1.1 +123 -0 + BitKeeper file C:/ntp/ntp-dev-strlcpy/libntp/strl_obsd.c + + libntp/strl_obsd.c@1.0 +0 -0 + + libntp/systime.c@1.54 +22 -11 + Use utmpname() before pututline() so repeated steps do not accidentally + record into wtmp where utmp was intended. + Use setutent() before each pututline() including first. + strncpy() -> strlcpy() + + libparse/data_mbg.c@1.11 +3 -3 + strncpy() -> strlcpy() + + libparse/parsesolaris.c@1.11 +1 -1 + strncpy() -> strlcpy() + + ntpd/ntp_config.c@1.288 +2 -4 + strncpy() -> strlcpy() + Remove leftover redundant CHECK_FIFO_CONSISTENCY() calls added to + get correct line numbers from failures. CONCAT_FIFO() has same. + + ntpd/ntp_control.c@1.166 +12 -10 + strncpy() -> strlcpy() + + ntpd/ntp_filegen.c@1.23 +8 -9 + strncpy() -> strlcpy() + + ntpd/ntp_io.c@1.351 +11 -11 + strncpy() -> strlcpy() + + ntpd/ntp_request.c@1.104 +1 -1 + strncpy() -> strlcpy() + + ntpd/ntp_scanner.c@1.42 +1 -1 + strncpy() -> strlcpy() + + ntpd/ntp_signd.c@1.4 +1 -1 + strncpy() -> strlcpy() + + ntpd/ntp_util.c@1.93 +7 -7 + strncpy() -> strlcpy() + + ntpd/refclock_acts.c@1.49 +2 -2 + strncpy() -> strlcpy() + + ntpd/refclock_arbiter.c@1.20 +11 -11 + strcat() -> strlcat() + strncpy() -> strlcpy() + + ntpd/refclock_chu.c@1.52 +1 -1 + strncpy() -> strlcpy() + + ntpd/refclock_hpgps.c@1.14 +1 -1 + strncpy() -> strlcpy() + + ntpd/refclock_jjy.c@1.23 +8 -11 + strncat() -> strlcat() (was nearly the only correct use of strncat() in NTP) + strncpy() -> strlcpy() + + ntpd/refclock_neoclock4x.c@1.21 +10 -10 + strncpy() -> strlcpy() + + ntpd/refclock_oncore.c@1.94 +17 -18 + strncat() -> strlcat() + strncpy() -> strlcpy() + + ntpd/refclock_parse.c@1.58 +110 -106 + strncat() -> strlcat() + strncpy() -> strlcpy() + + ntpd/refclock_true.c@1.19 +105 -97 + strncpy() -> strlcpy() + indent cleanup + + ntpd/refclock_wwv.c@1.75 +18 -13 + sprintf() -> snprintf() + strcat() -> strlcat() + + ntpdate/ntpdate.c@1.87 +2 -2 + strncpy() -> strlcpy() + + ntpdate/ntptime_config.c@1.6 +2 -4 + emalloc() + strcpy() -> estrdup() + + ntpdc/ntpdc.c@1.96 +5 -6 + strncpy() -> strlcpy() + + ntpdc/ntpdc_ops.c@1.77 +19 -15 + strcat() -> strlcat() + strncpy() -> strlcpy() + + ntpq/ntpq-subs.c@1.86 +7 -6 + strncpy() -> strlcpy() + strncpy() -> memcpy() + + ntpq/ntpq.c@1.135 +5 -6 + strncat() -> strlcat() + strncpy() -> strlcpy() + + ntpsnmpd/ntpSnmpSubagentObject.c@1.8 +1 -1 + strncpy() -> strlcpy() + + ports/winnt/libntp/syslog.c@1.9 +1 -2 + strncpy() -> strlcpy() + + ports/winnt/vc6/libntp.dsp@1.62 +4 -0 + add strl_obsd.c containing fallback strlcpy() and strlcat() picked up + from OpenBSD. + + ports/winnt/vs2003/libntp.vcproj@1.20 +3 -18 + add strl_obsd.c containing fallback strlcpy() and strlcat() picked up + from OpenBSD. + + ports/winnt/vs2005/libntp.vcproj@1.18 +4 -0 + add strl_obsd.c containing fallback strlcpy() and strlcat() picked up + from OpenBSD. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.41 +6 -2 + add strl_obsd.c containing fallback strlcpy() and strlcat() picked up + from OpenBSD. + + sntp/kod_management.c@1.28 +1 -3 + strncpy() -> strlcpy() + + sntp/m4/ntp_libntp.m4@1.9 +1 -1 + Check for strlcpy(), strlcat() + + sntp/utilities.c@1.18 +2 -7 + emalloc() + strncpy() -> estrdup() + + util/ntp-keygen.c@1.80 +45 -19 + Handle readlink() which doesn't NUL-terminate. + strdup() -> estrdup() + strcpy() -> strlcpy() + strcat() -> strlcat() + sprintf() -> snprintf() + + util/tg.c@1.4 +2 -2 + strcpy() -> strlcpy() + + util/tg2.c@1.4 +15 -18 + strcpy() -> strlcpy() + strncat() -> strlcat() + +ChangeSet@1.2479.1.42, 2011-04-04 18:39:05+02:00, jnperlin@hydra.localnet + bug1875 added missing header + + ntpd/ntp_crypto.c@1.157 +1 -0 + added missing header + +ChangeSet@1.2479.1.41, 2011-04-04 18:37:14+02:00, jnperlin@hydra.localnet + bug1875: timegm() from libntp blows up with 64bit time_t on Windows + + ntpd/ntp_crypto.c@1.156 +14 -13 + bug1875: timegm() from libntp blows up with 64bit time_t on Windows + +ChangeSet@1.2479.1.40, 2011-04-04 11:43:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P145 + TAG: NTP_4_2_7P145 + + ChangeLog@1.832 +1 -0 + NTP_4_2_7P145 + + ntpd/ntpd-opts.c@1.150 +2 -2 + NTP_4_2_7P145 + + ntpd/ntpd-opts.h@1.150 +3 -3 + NTP_4_2_7P145 + + ntpd/ntpd-opts.texi@1.148 +2 -2 + NTP_4_2_7P145 + + ntpd/ntpd.1@1.148 +2 -2 + NTP_4_2_7P145 + + ntpdc/ntpdc-opts.c@1.147 +2 -2 + NTP_4_2_7P145 + + ntpdc/ntpdc-opts.h@1.147 +3 -3 + NTP_4_2_7P145 + + ntpdc/ntpdc-opts.texi@1.147 +2 -2 + NTP_4_2_7P145 + + ntpdc/ntpdc.1@1.147 +2 -2 + NTP_4_2_7P145 + + ntpq/ntpq-opts.c@1.147 +2 -2 + NTP_4_2_7P145 + + ntpq/ntpq-opts.h@1.147 +3 -3 + NTP_4_2_7P145 + + ntpq/ntpq-opts.texi@1.147 +2 -2 + NTP_4_2_7P145 + + ntpq/ntpq.1@1.147 +2 -2 + NTP_4_2_7P145 + + ntpsnmpd/ntpsnmpd-opts.c@1.147 +2 -2 + NTP_4_2_7P145 + + ntpsnmpd/ntpsnmpd-opts.h@1.147 +3 -3 + NTP_4_2_7P145 + + ntpsnmpd/ntpsnmpd-opts.texi@1.147 +2 -2 + NTP_4_2_7P145 + + ntpsnmpd/ntpsnmpd.1@1.147 +2 -2 + NTP_4_2_7P145 + + packageinfo.sh@1.147 +1 -1 + NTP_4_2_7P145 + + sntp/sntp-opts.c@1.141 +2 -2 + NTP_4_2_7P145 + + sntp/sntp-opts.h@1.141 +3 -3 + NTP_4_2_7P145 + + sntp/sntp-opts.texi@1.141 +2 -2 + NTP_4_2_7P145 + + sntp/sntp.1@1.141 +2 -2 + NTP_4_2_7P145 + + sntp/sntp.html@1.141 +1 -1 + NTP_4_2_7P145 + + util/ntp-keygen-opts.c@1.145 +2 -2 + NTP_4_2_7P145 + + util/ntp-keygen-opts.h@1.145 +3 -3 + NTP_4_2_7P145 + + util/ntp-keygen-opts.texi@1.148 +2 -2 + NTP_4_2_7P145 + + util/ntp-keygen.1@1.148 +2 -2 + NTP_4_2_7P145 + +ChangeSet@1.2479.1.39, 2011-04-03 19:25:33+00:00, davehart@shiny.ad.hartbrothers.com + Cleanup a few Coverity static analysis warnings. + + include/ntp_config.h@1.71 +3 -2 + Add prototype for check_gen_fifo_consistency() overlooked in prior cet. + + lib/isc/task.c@1.4 +1 -1 + shuffle lock destruction until after protected field update to quiet + Coverity's lock analysis. + + libntp/audio.c@1.29 +4 -4 + Use width with sscanf(str, "%s", ...) to avoid overrun of destination. + + libntp/work_thread.c@1.7 +3 -3 + Change several DEBUG_REQUIRE to REQUIRE so needed safety checks are + included in -nodebug builds. + + ntpd/ntp_config.c@1.287 +2 -2 + match check_gen_fifo_consistency parameter naame with ntp_config.h + + ntpd/refclock_nmea.c@1.60 +8 -6 + leave room for terminating NUL by calling readlink with sizeof(...) - 1. + +ChangeSet@1.2479.1.38, 2011-04-03 17:35:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1840] ntp_lists.h FIFO macros buggy. + + ChangeLog@1.831 +1 -0 + [Bug 1840] ntp_lists.h FIFO macros buggy. + + include/ntp_lists.h@1.11 +40 -28 + Maintain pptail correctly in UNLINK_FIFO(), CONCAT_FIFO(). + Add more checks to CHECK_FIFO_CONSISTENCY, use it more. + Re-enable NTP_DEBUG_LISTS_H on DEBUG builds. + + libntp/mktime.c@1.10 +2 -2 + whitespace only (leading blanks -> tab) + + ntpd/ntp_config.c@1.286 +31 -0 + Move CHECK_FIFO_CONSISTENCY guts from macro to function so debuggers + can highlight the failing check rather than entire macro invocation. + +ChangeSet@1.2479.1.37, 2011-04-03 06:35:28+00:00, stenn@deacon.udel.edu + NTP_4_2_7P144 + TAG: NTP_4_2_7P144 + + ChangeLog@1.830 +1 -0 + NTP_4_2_7P144 + + ntpd/ntpd-opts.c@1.149 +2 -2 + NTP_4_2_7P144 + + ntpd/ntpd-opts.h@1.149 +3 -3 + NTP_4_2_7P144 + + ntpd/ntpd-opts.texi@1.147 +2 -2 + NTP_4_2_7P144 + + ntpd/ntpd.1@1.147 +2 -2 + NTP_4_2_7P144 + + ntpdc/ntpdc-opts.c@1.146 +2 -2 + NTP_4_2_7P144 + + ntpdc/ntpdc-opts.h@1.146 +3 -3 + NTP_4_2_7P144 + + ntpdc/ntpdc-opts.texi@1.146 +2 -2 + NTP_4_2_7P144 + + ntpdc/ntpdc.1@1.146 +2 -2 + NTP_4_2_7P144 + + ntpq/ntpq-opts.c@1.146 +2 -2 + NTP_4_2_7P144 + + ntpq/ntpq-opts.h@1.146 +3 -3 + NTP_4_2_7P144 + + ntpq/ntpq-opts.texi@1.146 +2 -2 + NTP_4_2_7P144 + + ntpq/ntpq.1@1.146 +2 -2 + NTP_4_2_7P144 + + ntpsnmpd/ntpsnmpd-opts.c@1.146 +2 -2 + NTP_4_2_7P144 + + ntpsnmpd/ntpsnmpd-opts.h@1.146 +3 -3 + NTP_4_2_7P144 + + ntpsnmpd/ntpsnmpd-opts.texi@1.146 +2 -2 + NTP_4_2_7P144 + + ntpsnmpd/ntpsnmpd.1@1.146 +2 -2 + NTP_4_2_7P144 + + packageinfo.sh@1.146 +1 -1 + NTP_4_2_7P144 + + sntp/sntp-opts.c@1.140 +2 -2 + NTP_4_2_7P144 + + sntp/sntp-opts.h@1.140 +3 -3 + NTP_4_2_7P144 + + sntp/sntp-opts.texi@1.140 +2 -2 + NTP_4_2_7P144 + + sntp/sntp.1@1.140 +2 -2 + NTP_4_2_7P144 + + sntp/sntp.html@1.140 +1 -1 + NTP_4_2_7P144 + + util/ntp-keygen-opts.c@1.144 +2 -2 + NTP_4_2_7P144 + + util/ntp-keygen-opts.h@1.144 +3 -3 + NTP_4_2_7P144 + + util/ntp-keygen-opts.texi@1.147 +2 -2 + NTP_4_2_7P144 + + util/ntp-keygen.1@1.147 +2 -2 + NTP_4_2_7P144 + +ChangeSet@1.2479.1.36, 2011-04-02 06:32:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1874] ntpq -c "rv 0 sys_var_list" empty. + + ChangeLog@1.829 +1 -0 + [Bug 1874] ntpq -c "rv 0 sys_var_list" empty. + + ntpd/ntp_control.c@1.165 +27 -44 + [Bug 1874] ntpq -c "rv 0 sys_var_list" empty. + + ntpq/ntpq.c@1.134 +10 -10 + [Bug 1874] ntpq -c "rv 0 sys_var_list" empty. + +ChangeSet@1.2479.1.35, 2011-03-31 18:16:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P143 + TAG: NTP_4_2_7P143 + + ChangeLog@1.828 +1 -0 + NTP_4_2_7P143 + + ntpd/ntpd-opts.c@1.148 +2 -2 + NTP_4_2_7P143 + + ntpd/ntpd-opts.h@1.148 +3 -3 + NTP_4_2_7P143 + + ntpd/ntpd-opts.texi@1.146 +4 -4 + NTP_4_2_7P143 + + ntpd/ntpd.1@1.146 +2 -2 + NTP_4_2_7P143 + + ntpdc/ntpdc-opts.c@1.145 +2 -2 + NTP_4_2_7P143 + + ntpdc/ntpdc-opts.h@1.145 +3 -3 + NTP_4_2_7P143 + + ntpdc/ntpdc-opts.texi@1.145 +4 -4 + NTP_4_2_7P143 + + ntpdc/ntpdc.1@1.145 +2 -2 + NTP_4_2_7P143 + + ntpq/ntpq-opts.c@1.145 +2 -2 + NTP_4_2_7P143 + + ntpq/ntpq-opts.h@1.145 +3 -3 + NTP_4_2_7P143 + + ntpq/ntpq-opts.texi@1.145 +4 -4 + NTP_4_2_7P143 + + ntpq/ntpq.1@1.145 +2 -2 + NTP_4_2_7P143 + + ntpsnmpd/ntpsnmpd-opts.c@1.145 +2 -2 + NTP_4_2_7P143 + + ntpsnmpd/ntpsnmpd-opts.h@1.145 +3 -3 + NTP_4_2_7P143 + + ntpsnmpd/ntpsnmpd-opts.texi@1.145 +4 -4 + NTP_4_2_7P143 + + ntpsnmpd/ntpsnmpd.1@1.145 +2 -2 + NTP_4_2_7P143 + + packageinfo.sh@1.145 +1 -1 + NTP_4_2_7P143 + + sntp/sntp-opts.c@1.139 +2 -2 + NTP_4_2_7P143 + + sntp/sntp-opts.h@1.139 +3 -3 + NTP_4_2_7P143 + + sntp/sntp-opts.texi@1.139 +4 -4 + NTP_4_2_7P143 + + sntp/sntp.1@1.139 +2 -2 + NTP_4_2_7P143 + + sntp/sntp.html@1.139 +3 -3 + NTP_4_2_7P143 + + util/ntp-keygen-opts.c@1.143 +2 -2 + NTP_4_2_7P143 + + util/ntp-keygen-opts.h@1.143 +3 -3 + NTP_4_2_7P143 + + util/ntp-keygen-opts.texi@1.146 +4 -4 + NTP_4_2_7P143 + + util/ntp-keygen.1@1.146 +2 -2 + NTP_4_2_7P143 + +ChangeSet@1.2479.1.34, 2011-03-31 13:11:38-04:00, stenn@deacon.udel.edu + Temporarily restore legacy ppsclock global fdpps for trak, zyfer refclocks + + ntpd/ntp_refclock.c@1.106 +6 -1 + Temporarily restore legacy ppsclock global fdpps for trak, zyfer refclocks + +ChangeSet@1.2479.1.33, 2011-03-30 04:53:34+00:00, davehart@shiny.ad.hartbrothers.com + Follow Ralf Wildenhues' advice for avoiding dead-code elimination + in configure test for in6addr_any. + + sntp/m4/ntp_ipv6.m4@1.4 +23 -19 + Follow Ralf Wildenhues' advice for avoiding dead-code elimination + in configure test for in6addr_any. + +ChangeSet@1.2479.1.32, 2011-03-29 13:35:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1862] in6addr_any test in configure fooled by arm gcc 4.1.3 -O2. + + ChangeLog@1.827 +1 -0 + [Bug 1862] in6addr_any test in configure fooled by arm gcc 4.1.3 -O2. + + ntpd/ntp_crypto.c@1.155 +0 -1 + Remove dead code (excess call to X509_get_ext()). + + sntp/m4/ntp_ipv6.m4@1.3 +2 -2 + [Bug 1862] in6addr_any test in configure fooled by arm gcc 4.1.3 -O2. + +ChangeSet@1.2479.6.1, 2011-03-28 02:29:10+00:00, davehart@shiny.ad.hartbrothers.com + Remove "signal_no_reset: signal 17 had flags 4000000" logging, as it + indicates no problem and is interpreted as an error. Previously some + bits had been ignored one-by-one, but Linux SA_RESTORER definition is + unavailable to user headers. + + ChangeLog@1.824.1.1 +4 -0 + Remove "signal_no_reset: signal 17 had flags 4000000" logging, as it + indicates no problem and is interpreted as an error. Previously some + bits had been ignored one-by-one, but Linux SA_RESTORER definition is + unavailable to user headers. + + libntp/syssignal.c@1.13 +1 -29 + Remove "signal_no_reset: signal 17 had flags 4000000" logging, as it + indicates no problem and is interpreted as an error. Previously some + bits had been ignored one-by-one, but Linux SA_RESTORER definition is + unavailable to user headers. + Zero struct sigaction to silence warning about uninit vec.sa_restorer. + + sntp/m4/ntp_libntp.m4@1.8 +0 -12 + Remove unneeded dead code. + +ChangeSet@1.2479.1.30, 2011-03-26 02:03:35+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1861] tickadj build failure using uClibc. + + ChangeLog@1.825 +1 -0 + [Bug 1861] tickadj build failure using uClibc. + + configure.ac@1.521 +62 -37 + [Bug 1861] tickadj build failure using uClibc. + + include/ntp_machine.h@1.34 +0 -11 + moved to configure.ac + + include/ntp_syscall.h@1.10 +24 -28 + [Bug 1861] tickadj build failure using uClibc. + + util/tickadj.c@1.12 +12 -9 + [Bug 1861] tickadj build failure using uClibc. + +ChangeSet@1.2479.1.29, 2011-03-23 07:14:48+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1732] ntpd ties up CPU on disconnected USB refclock. + + ChangeLog@1.824 +1 -0 + [Bug 1732] ntpd ties up CPU on disconnected USB refclock. + + ntpd/ntp_io.c@1.350 +39 -12 + [Bug 1732] ntpd ties up CPU on disconnected USB refclock. + +ChangeSet@1.2479.5.2, 2011-03-21 07:57:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P142 + TAG: NTP_4_2_7P142 + + ChangeLog@1.821.1.2 +1 -0 + NTP_4_2_7P142 + + clockstuff/clktest-opts.c@1.67.1.1 +2 -2 + NTP_4_2_7P142 + + clockstuff/clktest-opts.h@1.67.1.1 +3 -3 + NTP_4_2_7P142 + + ntpd/ntpd-opts.c@1.147 +2 -2 + NTP_4_2_7P142 + + ntpd/ntpd-opts.h@1.147 +3 -3 + NTP_4_2_7P142 + + ntpd/ntpd-opts.texi@1.145 +2 -2 + NTP_4_2_7P142 + + ntpd/ntpd.1@1.145 +2 -2 + NTP_4_2_7P142 + + ntpdc/ntpdc-opts.c@1.144 +2 -2 + NTP_4_2_7P142 + + ntpdc/ntpdc-opts.h@1.144 +3 -3 + NTP_4_2_7P142 + + ntpdc/ntpdc-opts.texi@1.144 +2 -2 + NTP_4_2_7P142 + + ntpdc/ntpdc.1@1.144 +2 -2 + NTP_4_2_7P142 + + ntpq/ntpq-opts.c@1.144 +2 -2 + NTP_4_2_7P142 + + ntpq/ntpq-opts.h@1.144 +3 -3 + NTP_4_2_7P142 + + ntpq/ntpq-opts.texi@1.144 +2 -2 + NTP_4_2_7P142 + + ntpq/ntpq.1@1.144 +2 -2 + NTP_4_2_7P142 + + ntpsnmpd/ntpsnmpd-opts.c@1.144 +2 -2 + NTP_4_2_7P142 + + ntpsnmpd/ntpsnmpd-opts.h@1.144 +3 -3 + NTP_4_2_7P142 + + ntpsnmpd/ntpsnmpd-opts.texi@1.144 +2 -2 + NTP_4_2_7P142 + + ntpsnmpd/ntpsnmpd.1@1.144 +2 -2 + NTP_4_2_7P142 + + packageinfo.sh@1.144 +1 -1 + NTP_4_2_7P142 + + sntp/sntp-opts.c@1.138 +2 -2 + NTP_4_2_7P142 + + sntp/sntp-opts.h@1.138 +3 -3 + NTP_4_2_7P142 + + sntp/sntp-opts.texi@1.138 +2 -2 + NTP_4_2_7P142 + + sntp/sntp.1@1.138 +2 -2 + NTP_4_2_7P142 + + sntp/sntp.html@1.138 +1 -1 + NTP_4_2_7P142 + + util/ntp-keygen-opts.c@1.142 +2 -2 + NTP_4_2_7P142 + + util/ntp-keygen-opts.h@1.142 +3 -3 + NTP_4_2_7P142 + + util/ntp-keygen-opts.texi@1.145 +2 -2 + NTP_4_2_7P142 + + util/ntp-keygen.1@1.145 +2 -2 + NTP_4_2_7P142 + +ChangeSet@1.2479.5.1, 2011-03-21 06:28:29+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1844] ntpd 4.2.7p131 NetBSD, ld --gc-sections links bad executable. + + ChangeLog@1.821.1.1 +2 -0 + [Bug 1844] ntpd 4.2.7p131 NetBSD, ld --gc-sections links bad executable. + Fix "make distcheck" break in libevent/sample caused by typo. + + sntp/libevent/Makefile.am@1.4 +1 -1 + Fix "make distcheck" break in libevent/sample caused by typo. + + sntp/libevent/configure.in@1.4 +45 -7 + [Bug 1844] ntpd 4.2.7p131 NetBSD, ld --gc-sections links bad executable. + + sntp/m4/ntp_compiler.m4@1.2 +45 -7 + [Bug 1844] ntpd 4.2.7p131 NetBSD, ld --gc-sections links bad executable. + +ChangeSet@1.2479.4.1, 2011-03-20 20:39:43+00:00, davehart@shiny.ad.hartbrothers.com + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + .point-changed-filelist@1.9 +0 -2 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + BitKeeper/deleted/42/clktest-opts.c~28d4c334dbca58a1@1.66.1.1 +0 -0 + Rename: clockstuff/clktest-opts.c -> BitKeeper/deleted/42/clktest-opts.c~28d4c334dbca58a1 + + BitKeeper/deleted/46/tty_chu.c~3e480692@1.3 +0 -0 + Rename: kernel/tty_chu.c -> BitKeeper/deleted/46/tty_chu.c~3e480692 + + BitKeeper/deleted/69/clkinit.c~3e480692@1.4 +0 -0 + Rename: kernel/clkinit.c -> BitKeeper/deleted/69/clkinit.c~3e480692 + + BitKeeper/deleted/7d/clktest.c~3e480692@1.7 +0 -0 + Rename: clockstuff/clktest.c -> BitKeeper/deleted/7d/clktest.c~3e480692 + + BitKeeper/deleted/96/tty_clk_STREAMS.c~3e480692@1.3 +0 -0 + Rename: kernel/tty_clk_STREAMS.c -> BitKeeper/deleted/96/tty_clk_STREAMS.c~3e480692 + + BitKeeper/deleted/99/tty_clk.c~3e480692@1.3 +0 -0 + Rename: kernel/tty_clk.c -> BitKeeper/deleted/99/tty_clk.c~3e480692 + + BitKeeper/deleted/ab/chuinit.c~3e480692@1.4 +0 -0 + Rename: kernel/chuinit.c -> BitKeeper/deleted/ab/chuinit.c~3e480692 + + BitKeeper/deleted/bf/chudefs.h~3e480692@1.3 +0 -0 + Rename: kernel/sys/chudefs.h -> BitKeeper/deleted/bf/chudefs.h~3e480692 + + BitKeeper/deleted/d6/clkdefs.h~3e480692@1.3 +0 -0 + Rename: kernel/sys/clkdefs.h -> BitKeeper/deleted/d6/clkdefs.h~3e480692 + + BitKeeper/deleted/d7/README~3e480692@1.3 +0 -0 + Rename: kernel/README -> BitKeeper/deleted/d7/README~3e480692 + + BitKeeper/deleted/e1/clktest-opts.def~10c559de4ec2c50e@1.9 +0 -0 + Rename: clockstuff/clktest-opts.def -> BitKeeper/deleted/e1/clktest-opts.def~10c559de4ec2c50e + + BitKeeper/deleted/e5/clktest-opts.h~d3cf51ce6544d610@1.66.1.1 +0 -0 + Rename: clockstuff/clktest-opts.h -> BitKeeper/deleted/e5/clktest-opts.h~d3cf51ce6544d610 + + BitKeeper/deleted/ed/tty_chu_STREAMS.c~3e480692@1.3 +0 -0 + Rename: kernel/tty_chu_STREAMS.c -> BitKeeper/deleted/ed/tty_chu_STREAMS.c~3e480692 + + ChangeLog@1.820.1.1 +3 -0 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + clockstuff/Makefile.am@1.20 +3 -25 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + clockstuff/README@1.4 +4 -14 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + configure.ac@1.520 +1 -61 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + include/ntp_tty.h@1.6 +9 -7 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + include/ntpd.h@1.161 +0 -7 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + kernel/Makefile.am@1.6 +0 -1 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + kernel/sys/Makefile.am@1.7 +1 -1 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + ntpd/ntp_refclock.c@1.105 +9 -106 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + ntpd/refclock_datum.c@1.17 +0 -3 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + ntpd/refclock_leitch.c@1.14 +5 -43 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + + ntpd/refclock_oncore.c@1.93 +0 -4 + Remove kernel line discipline driver code for clk and chu, deprecate + related LDISC_ flags, and remove associated ntpd code to decode the + timestamps, remove clktest line discipline test program. + +ChangeSet@1.2479.1.26, 2011-03-20 11:16:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P141 + TAG: NTP_4_2_7P141 + + ChangeLog@1.821 +1 -0 + NTP_4_2_7P141 + + clockstuff/clktest-opts.c@1.67 +2 -2 + NTP_4_2_7P141 + + clockstuff/clktest-opts.h@1.67 +3 -3 + NTP_4_2_7P141 + + ntpd/ntpd-opts.c@1.146 +2 -2 + NTP_4_2_7P141 + + ntpd/ntpd-opts.h@1.146 +3 -3 + NTP_4_2_7P141 + + ntpd/ntpd-opts.texi@1.144 +2 -2 + NTP_4_2_7P141 + + ntpd/ntpd.1@1.144 +2 -2 + NTP_4_2_7P141 + + ntpdc/ntpdc-opts.c@1.143 +2 -2 + NTP_4_2_7P141 + + ntpdc/ntpdc-opts.h@1.143 +3 -3 + NTP_4_2_7P141 + + ntpdc/ntpdc-opts.texi@1.143 +2 -2 + NTP_4_2_7P141 + + ntpdc/ntpdc.1@1.143 +2 -2 + NTP_4_2_7P141 + + ntpq/ntpq-opts.c@1.143 +2 -2 + NTP_4_2_7P141 + + ntpq/ntpq-opts.h@1.143 +3 -3 + NTP_4_2_7P141 + + ntpq/ntpq-opts.texi@1.143 +2 -2 + NTP_4_2_7P141 + + ntpq/ntpq.1@1.143 +2 -2 + NTP_4_2_7P141 + + ntpsnmpd/ntpsnmpd-opts.c@1.143 +2 -2 + NTP_4_2_7P141 + + ntpsnmpd/ntpsnmpd-opts.h@1.143 +3 -3 + NTP_4_2_7P141 + + ntpsnmpd/ntpsnmpd-opts.texi@1.143 +2 -2 + NTP_4_2_7P141 + + ntpsnmpd/ntpsnmpd.1@1.143 +2 -2 + NTP_4_2_7P141 + + packageinfo.sh@1.143 +1 -1 + NTP_4_2_7P141 + + sntp/sntp-opts.c@1.137 +2 -2 + NTP_4_2_7P141 + + sntp/sntp-opts.h@1.137 +3 -3 + NTP_4_2_7P141 + + sntp/sntp-opts.texi@1.137 +2 -2 + NTP_4_2_7P141 + + sntp/sntp.1@1.137 +2 -2 + NTP_4_2_7P141 + + sntp/sntp.html@1.137 +1 -1 + NTP_4_2_7P141 + + util/ntp-keygen-opts.c@1.141 +2 -2 + NTP_4_2_7P141 + + util/ntp-keygen-opts.h@1.141 +3 -3 + NTP_4_2_7P141 + + util/ntp-keygen-opts.texi@1.144 +2 -2 + NTP_4_2_7P141 + + util/ntp-keygen.1@1.144 +2 -2 + NTP_4_2_7P141 + +ChangeSet@1.2479.1.25, 2011-03-19 20:14:05+00:00, davehart@shiny.ad.hartbrothers.com + Add overlooked ChangeLog entry for refclock_pps() (was in commit comment + but not ChangeLog text). + + ChangeLog@1.820 +1 -0 + Add overlooked ChangeLog entry for refclock_pps() (was in commit comment + but not ChangeLog text). + +ChangeSet@1.2479.1.24, 2011-03-19 16:38:10+00:00, davehart@shiny.ad.hartbrothers.com + Add "ntpq -c iostats" similar to "ntpdc -c iostats". + Compare entire timestamp to reject duplicates in refclock_pps(). + + ChangeLog@1.819 +1 -0 + Add "ntpq -c iostats" similar to "ntpdc -c iostats". + Compare entire timestamp to reject duplicates in refclock_pps(). + + ntpd/ntp_control.c@1.164 +74 -1 + Add "ntpq -c iostats" similar to "ntpdc -c iostats". + + ntpd/ntp_refclock.c@1.104 +1 -1 + Compare entire timestamp to reject duplicates in refclock_pps(). + + ntpq/ntpq-subs.c@1.85 +34 -1 + Add "ntpq -c iostats" similar to "ntpdc -c iostats". + + ports/winnt/ntpd/ntp_iocompletionport.c@1.58 +7 -3 + Add "ntpq -c iostats" similar to "ntpdc -c iostats". + +ChangeSet@1.2479.1.23, 2011-03-17 11:20:23+00:00, stenn@deacon.udel.edu + NTP_4_2_7P140 + TAG: NTP_4_2_7P140 + + ChangeLog@1.818 +1 -0 + NTP_4_2_7P140 + + clockstuff/clktest-opts.c@1.66 +2 -2 + NTP_4_2_7P140 + + clockstuff/clktest-opts.h@1.66 +3 -3 + NTP_4_2_7P140 + + ntpd/ntpd-opts.c@1.145 +2 -2 + NTP_4_2_7P140 + + ntpd/ntpd-opts.h@1.145 +3 -3 + NTP_4_2_7P140 + + ntpd/ntpd-opts.texi@1.143 +2 -2 + NTP_4_2_7P140 + + ntpd/ntpd.1@1.143 +2 -2 + NTP_4_2_7P140 + + ntpdc/ntpdc-opts.c@1.142 +2 -2 + NTP_4_2_7P140 + + ntpdc/ntpdc-opts.h@1.142 +3 -3 + NTP_4_2_7P140 + + ntpdc/ntpdc-opts.texi@1.142 +2 -2 + NTP_4_2_7P140 + + ntpdc/ntpdc.1@1.142 +2 -2 + NTP_4_2_7P140 + + ntpq/ntpq-opts.c@1.142 +2 -2 + NTP_4_2_7P140 + + ntpq/ntpq-opts.h@1.142 +3 -3 + NTP_4_2_7P140 + + ntpq/ntpq-opts.texi@1.142 +2 -2 + NTP_4_2_7P140 + + ntpq/ntpq.1@1.142 +2 -2 + NTP_4_2_7P140 + + ntpsnmpd/ntpsnmpd-opts.c@1.142 +2 -2 + NTP_4_2_7P140 + + ntpsnmpd/ntpsnmpd-opts.h@1.142 +3 -3 + NTP_4_2_7P140 + + ntpsnmpd/ntpsnmpd-opts.texi@1.142 +2 -2 + NTP_4_2_7P140 + + ntpsnmpd/ntpsnmpd.1@1.142 +2 -2 + NTP_4_2_7P140 + + packageinfo.sh@1.142 +1 -1 + NTP_4_2_7P140 + + sntp/sntp-opts.c@1.136 +2 -2 + NTP_4_2_7P140 + + sntp/sntp-opts.h@1.136 +3 -3 + NTP_4_2_7P140 + + sntp/sntp-opts.texi@1.136 +2 -2 + NTP_4_2_7P140 + + sntp/sntp.1@1.136 +2 -2 + NTP_4_2_7P140 + + sntp/sntp.html@1.136 +1 -1 + NTP_4_2_7P140 + + util/ntp-keygen-opts.c@1.140 +2 -2 + NTP_4_2_7P140 + + util/ntp-keygen-opts.h@1.140 +3 -3 + NTP_4_2_7P140 + + util/ntp-keygen-opts.texi@1.143 +2 -2 + NTP_4_2_7P140 + + util/ntp-keygen.1@1.143 +2 -2 + NTP_4_2_7P140 + +ChangeSet@1.2479.1.22, 2011-03-17 01:25:14+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1848] ntpd 4.2.7p139 --disable-thread-support does not compile. + Add --disable-thread-support to one flock-build variation. + One more lock-while-init in lib/isc/task.c to quiet lock analysis. + + ChangeLog@1.817 +3 -0 + [Bug 1848] ntpd 4.2.7p139 --disable-thread-support does not compile. + Add --disable-thread-support to one flock-build variation. + One more lock-while-init in lib/isc/task.c to quiet lock analysis. + + flock-build@1.50 +2 -2 + Add --disable-thread-support to one flock-build variation. + + lib/isc/task.c@1.3 +2 -0 + One more lock-while-init in lib/isc/task.c to quiet lock analysis. + + libntp/msyslog.c@1.38 +4 -3 + corner case leak fix with change_logfile("stderr") + + libntp/work_fork.c@1.10 +2 -2 + [Bug 1848] ntpd 4.2.7p139 --disable-thread-support does not compile. + +ChangeSet@1.2479.1.21, 2011-03-16 11:35:50+00:00, stenn@deacon.udel.edu + NTP_4_2_7P139 + TAG: NTP_4_2_7P139 + + ChangeLog@1.816 +1 -0 + NTP_4_2_7P139 + + clockstuff/clktest-opts.c@1.65 +2 -2 + NTP_4_2_7P139 + + clockstuff/clktest-opts.h@1.65 +3 -3 + NTP_4_2_7P139 + + ntpd/ntpd-opts.c@1.144 +2 -2 + NTP_4_2_7P139 + + ntpd/ntpd-opts.h@1.144 +3 -3 + NTP_4_2_7P139 + + ntpd/ntpd-opts.texi@1.142 +2 -2 + NTP_4_2_7P139 + + ntpd/ntpd.1@1.142 +2 -2 + NTP_4_2_7P139 + + ntpdc/ntpdc-opts.c@1.141 +2 -2 + NTP_4_2_7P139 + + ntpdc/ntpdc-opts.h@1.141 +3 -3 + NTP_4_2_7P139 + + ntpdc/ntpdc-opts.texi@1.141 +2 -2 + NTP_4_2_7P139 + + ntpdc/ntpdc.1@1.141 +2 -2 + NTP_4_2_7P139 + + ntpq/ntpq-opts.c@1.141 +2 -2 + NTP_4_2_7P139 + + ntpq/ntpq-opts.h@1.141 +3 -3 + NTP_4_2_7P139 + + ntpq/ntpq-opts.texi@1.141 +2 -2 + NTP_4_2_7P139 + + ntpq/ntpq.1@1.141 +2 -2 + NTP_4_2_7P139 + + ntpsnmpd/ntpsnmpd-opts.c@1.141 +2 -2 + NTP_4_2_7P139 + + ntpsnmpd/ntpsnmpd-opts.h@1.141 +3 -3 + NTP_4_2_7P139 + + ntpsnmpd/ntpsnmpd-opts.texi@1.141 +2 -2 + NTP_4_2_7P139 + + ntpsnmpd/ntpsnmpd.1@1.141 +2 -2 + NTP_4_2_7P139 + + packageinfo.sh@1.141 +1 -1 + NTP_4_2_7P139 + + sntp/sntp-opts.c@1.135 +2 -2 + NTP_4_2_7P139 + + sntp/sntp-opts.h@1.135 +3 -3 + NTP_4_2_7P139 + + sntp/sntp-opts.texi@1.135 +2 -2 + NTP_4_2_7P139 + + sntp/sntp.1@1.135 +2 -2 + NTP_4_2_7P139 + + sntp/sntp.html@1.135 +1 -1 + NTP_4_2_7P139 + + util/ntp-keygen-opts.c@1.139 +2 -2 + NTP_4_2_7P139 + + util/ntp-keygen-opts.h@1.139 +3 -3 + NTP_4_2_7P139 + + util/ntp-keygen-opts.texi@1.142 +2 -2 + NTP_4_2_7P139 + + util/ntp-keygen.1@1.142 +2 -2 + NTP_4_2_7P139 + +ChangeSet@1.2479.1.20, 2011-03-16 04:58:25-04:00, stenn@deacon.udel.edu + typo + + ChangeLog@1.815 +1 -1 + typo + +ChangeSet@1.2479.1.19, 2011-03-16 02:09:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1848] make check ntpd --saveconfigquit clutters syslog. + + ChangeLog@1.814 +2 -1 + [Bug 1848] make check ntpd --saveconfigquit clutters syslog. + + include/ntp_stdlib.h@1.61 +3 -4 + Move version string logging out of common logging routines where + it was increasingly unwieldy. + + libntp/msyslog.c@1.37 +5 -12 + Move version string logging out of common logging routines where + it was increasingly unwieldy. + + ntpd/ntp_config.c@1.285 +1 -1 + Move version string logging out of common logging routines where + it was increasingly unwieldy. + + ntpd/ntpd.c@1.125 +41 -40 + [Bug 1848] make check ntpd --saveconfigquit clutters syslog. + + sntp/log.c@1.21 +3 -2 + [Bug 1848] make check ntpd --saveconfigquit clutters syslog. + +ChangeSet@1.2479.1.18, 2011-03-08 11:17:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P138 + TAG: NTP_4_2_7P138 + + ChangeLog@1.813 +1 -0 + NTP_4_2_7P138 + + clockstuff/clktest-opts.c@1.64 +2 -2 + NTP_4_2_7P138 + + clockstuff/clktest-opts.h@1.64 +3 -3 + NTP_4_2_7P138 + + ntpd/ntpd-opts.c@1.143 +2 -2 + NTP_4_2_7P138 + + ntpd/ntpd-opts.h@1.143 +3 -3 + NTP_4_2_7P138 + + ntpd/ntpd-opts.texi@1.141 +2 -2 + NTP_4_2_7P138 + + ntpd/ntpd.1@1.141 +2 -2 + NTP_4_2_7P138 + + ntpdc/ntpdc-opts.c@1.140 +2 -2 + NTP_4_2_7P138 + + ntpdc/ntpdc-opts.h@1.140 +3 -3 + NTP_4_2_7P138 + + ntpdc/ntpdc-opts.texi@1.140 +2 -2 + NTP_4_2_7P138 + + ntpdc/ntpdc.1@1.140 +2 -2 + NTP_4_2_7P138 + + ntpq/ntpq-opts.c@1.140 +2 -2 + NTP_4_2_7P138 + + ntpq/ntpq-opts.h@1.140 +3 -3 + NTP_4_2_7P138 + + ntpq/ntpq-opts.texi@1.140 +2 -2 + NTP_4_2_7P138 + + ntpq/ntpq.1@1.140 +2 -2 + NTP_4_2_7P138 + + ntpsnmpd/ntpsnmpd-opts.c@1.140 +2 -2 + NTP_4_2_7P138 + + ntpsnmpd/ntpsnmpd-opts.h@1.140 +3 -3 + NTP_4_2_7P138 + + ntpsnmpd/ntpsnmpd-opts.texi@1.140 +2 -2 + NTP_4_2_7P138 + + ntpsnmpd/ntpsnmpd.1@1.140 +2 -2 + NTP_4_2_7P138 + + packageinfo.sh@1.140 +1 -1 + NTP_4_2_7P138 + + sntp/sntp-opts.c@1.134 +2 -2 + NTP_4_2_7P138 + + sntp/sntp-opts.h@1.134 +3 -3 + NTP_4_2_7P138 + + sntp/sntp-opts.texi@1.134 +2 -2 + NTP_4_2_7P138 + + sntp/sntp.1@1.134 +2 -2 + NTP_4_2_7P138 + + sntp/sntp.html@1.134 +1 -1 + NTP_4_2_7P138 + + util/ntp-keygen-opts.c@1.138 +2 -2 + NTP_4_2_7P138 + + util/ntp-keygen-opts.h@1.138 +3 -3 + NTP_4_2_7P138 + + util/ntp-keygen-opts.texi@1.141 +2 -2 + NTP_4_2_7P138 + + util/ntp-keygen.1@1.141 +2 -2 + NTP_4_2_7P138 + +ChangeSet@1.2479.1.17, 2011-03-08 01:10:53-05:00, stenn@deacon.udel.edu + [Bug 1846] MacOSX: debug symbol not found by propdelay or tickadj + + ChangeLog@1.812 +1 -0 + [Bug 1846] MacOSX: debug symbol not found by propdelay or tickadj + +ChangeSet@1.2479.1.16, 2011-03-07 12:12:49-08:00, harlan@hms-mbp.local + Call init_lib() in propdelay and tickadj just to get the debug symbol from libntp + + clockstuff/propdelay.c@1.7 +2 -0 + Call init_lib() just to get the debug symbol from libntp + + util/tickadj.c@1.11 +2 -0 + Call init_lib() just to get the debug symbol from libntp + +ChangeSet@1.2479.3.1, 2011-03-07 10:19:45+00:00, davehart@shiny.ad.hartbrothers.com + Lock under-construction task, taskmgr objects to satisfy Coverity's + mostly-correct assumptions about which variables are protected by + which locks. + + ChangeLog@1.809.1.1 +3 -0 + Lock under-construction task, taskmgr objects to satisfy Coverity's + mostly-correct assumptions about which variables are protected by + which locks. + + lib/isc/task.c@1.2 +8 -4 + Lock under-construction task, taskmgr objects to satisfy Coverity's + mostly-correct assumptions about which variables are protected by + which locks. + +ChangeSet@1.2479.1.14, 2011-03-07 10:06:50+00:00, stenn@deacon.udel.edu + NTP_4_2_7P137 + TAG: NTP_4_2_7P137 + + ChangeLog@1.810 +1 -0 + NTP_4_2_7P137 + + clockstuff/clktest-opts.c@1.63 +2 -2 + NTP_4_2_7P137 + + clockstuff/clktest-opts.h@1.63 +3 -3 + NTP_4_2_7P137 + + ntpd/ntpd-opts.c@1.142 +2 -2 + NTP_4_2_7P137 + + ntpd/ntpd-opts.h@1.142 +3 -3 + NTP_4_2_7P137 + + ntpd/ntpd-opts.texi@1.140 +2 -2 + NTP_4_2_7P137 + + ntpd/ntpd.1@1.140 +2 -2 + NTP_4_2_7P137 + + ntpdc/ntpdc-opts.c@1.139 +2 -2 + NTP_4_2_7P137 + + ntpdc/ntpdc-opts.h@1.139 +3 -3 + NTP_4_2_7P137 + + ntpdc/ntpdc-opts.texi@1.139 +2 -2 + NTP_4_2_7P137 + + ntpdc/ntpdc.1@1.139 +2 -2 + NTP_4_2_7P137 + + ntpq/ntpq-opts.c@1.139 +2 -2 + NTP_4_2_7P137 + + ntpq/ntpq-opts.h@1.139 +3 -3 + NTP_4_2_7P137 + + ntpq/ntpq-opts.texi@1.139 +2 -2 + NTP_4_2_7P137 + + ntpq/ntpq.1@1.139 +2 -2 + NTP_4_2_7P137 + + ntpsnmpd/ntpsnmpd-opts.c@1.139 +2 -2 + NTP_4_2_7P137 + + ntpsnmpd/ntpsnmpd-opts.h@1.139 +3 -3 + NTP_4_2_7P137 + + ntpsnmpd/ntpsnmpd-opts.texi@1.139 +2 -2 + NTP_4_2_7P137 + + ntpsnmpd/ntpsnmpd.1@1.139 +2 -2 + NTP_4_2_7P137 + + packageinfo.sh@1.139 +1 -1 + NTP_4_2_7P137 + + sntp/sntp-opts.c@1.133 +2 -2 + NTP_4_2_7P137 + + sntp/sntp-opts.h@1.133 +3 -3 + NTP_4_2_7P137 + + sntp/sntp-opts.texi@1.133 +2 -2 + NTP_4_2_7P137 + + sntp/sntp.1@1.133 +2 -2 + NTP_4_2_7P137 + + sntp/sntp.html@1.133 +1 -1 + NTP_4_2_7P137 + + util/ntp-keygen-opts.c@1.137 +2 -2 + NTP_4_2_7P137 + + util/ntp-keygen-opts.h@1.137 +3 -3 + NTP_4_2_7P137 + + util/ntp-keygen-opts.texi@1.140 +2 -2 + NTP_4_2_7P137 + + util/ntp-keygen.1@1.140 +2 -2 + NTP_4_2_7P137 + +ChangeSet@1.2479.1.13, 2011-03-06 01:24:22+00:00, davehart@shiny.ad.hartbrothers.com + Add overlooked ChangeLog entry for last cset. + + ChangeLog@1.809 +2 -0 + Add overlooked ChangeLog entry for last cset. + + include/declcond.h@1.2 +4 -0 + Use multiple-inclusion guard. + + ntpd/declcond.h@1.2 +4 -0 + Use multiple-inclusion guard. + +ChangeSet@1.2479.1.12, 2011-03-05 22:35:37+00:00, davehart@shiny.ad.hartbrothers.com + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + BitKeeper/deleted/16/sntptest.cpp~b166a62f6f744adb@1.4 +0 -0 + Rename: sntp/tests/sntptest.cpp -> BitKeeper/deleted/16/sntptest.cpp~b166a62f6f744adb + + BitKeeper/deleted/a3/dnslookup.c~96398d4d3428670@1.10 +0 -0 + Rename: ports/winnt/libntp/dnslookup.c -> BitKeeper/deleted/a3/dnslookup.c~96398d4d3428670 + + BitKeeper/deleted/c4/mexit.c~13b0216e@1.5 +0 -0 + Rename: ports/winnt/libntp/mexit.c -> BitKeeper/deleted/c4/mexit.c~13b0216e + + ChangeLog@1.808 +2 -0 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + clockstuff/chutest.c@1.6 +0 -1 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + clockstuff/propdelay.c@1.6 +0 -1 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + include/Makefile.am@1.48 +1 -0 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + include/declcond.h@1.1 +17 -0 + BitKeeper file C:/ntp/ntp-dev-trace/include/declcond.h + + include/declcond.h@1.0 +0 -0 + + include/ntp_debug.h@1.5 +12 -16 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + include/ntp_stdlib.h@1.60 +3 -6 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + include/ntpd.h@1.160 +23 -1 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + libntp/lib_strbuf.c@1.9 +6 -5 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + libntp/machines.c@1.24 +6 -6 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + libntp/msyslog.c@1.36 +1 -1 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + libntp/ntp_intres.c@1.94 +46 -50 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + libntp/socket.c@1.7 +26 -26 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + libntp/socktohost.c@1.14 +3 -2 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + libntp/work_fork.c@1.9 +16 -16 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + libntp/work_thread.c@1.6 +2 -2 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + ntpd/Makefile.am@1.103 +1 -0 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + ntpd/check_y2k.c@1.8 +0 -1 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + ntpd/declcond.h@1.1 +17 -0 + BitKeeper file C:/ntp/ntp-dev-trace/ntpd/declcond.h + + ntpd/declcond.h@1.0 +0 -0 + + ntpd/keyword-gen.c@1.18 +2 -1 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + ntpd/ntp_scanner.c@1.41 +1 -1 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + ntpd/ntpd.c@1.124 +0 -7 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + ntpd/refclock_bancomm.c@1.15 +0 -5 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + ntpdate/ntpdate.c@1.86 +2 -7 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + ntpdate/ntptimeset.c@1.14 +0 -5 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + ntpdc/ntpdc.c@1.95 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + ntpq/ntpq.c@1.133 +29 -48 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + ports/winnt/include/gaa_compat.h@1.2 +1 -1 + mismatched #pragma warning(pop) #ifdef _W64 + + ports/winnt/libntp/setpriority.c@1.5 +2 -3 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + ports/winnt/libntp/termios.c@1.27 +9 -13 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + ports/winnt/ntpd/ntservice.c@1.28 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.40 +6 -2 + add include/declcond.h reference + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.39 +4 -0 + add ntpd/declcond.h reference + + sntp/kod_management.c@1.27 +7 -7 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + sntp/main.c@1.70 +51 -51 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + sntp/networking.c@1.59 +7 -7 + Use TRACE() instead of DPRINTF() for libntp and utilities, which + use the "debug" variable regardless of #ifdef DEBUG. + + sntp/sntp.c@1.3 +2 -4 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + sntp/tests/Makefile.am@1.25 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + tests/libntp/libntptest.cpp@1.3 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + util/jitter.c@1.10 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + util/ntp-keygen.c@1.79 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + util/ntptime.c@1.22 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + + util/tickadj.c@1.10 +0 -1 + Declare debug in libntp instead of each program. Expose extern declaration + to utilities, libntp, and DEBUG ntpd. + +ChangeSet@1.2479.1.11, 2011-03-02 07:25:19+00:00, stenn@deacon.udel.edu + NTP_4_2_7P136 + TAG: NTP_4_2_7P136 + + ChangeLog@1.807 +1 -0 + NTP_4_2_7P136 + + clockstuff/clktest-opts.c@1.62 +2 -2 + NTP_4_2_7P136 + + clockstuff/clktest-opts.h@1.62 +3 -3 + NTP_4_2_7P136 + + ntpd/ntpd-opts.c@1.141 +2 -2 + NTP_4_2_7P136 + + ntpd/ntpd-opts.h@1.141 +3 -3 + NTP_4_2_7P136 + + ntpd/ntpd-opts.texi@1.139 +2 -2 + NTP_4_2_7P136 + + ntpd/ntpd.1@1.139 +2 -2 + NTP_4_2_7P136 + + ntpdc/ntpdc-opts.c@1.138 +2 -2 + NTP_4_2_7P136 + + ntpdc/ntpdc-opts.h@1.138 +3 -3 + NTP_4_2_7P136 + + ntpdc/ntpdc-opts.texi@1.138 +2 -2 + NTP_4_2_7P136 + + ntpdc/ntpdc.1@1.138 +2 -2 + NTP_4_2_7P136 + + ntpq/ntpq-opts.c@1.138 +2 -2 + NTP_4_2_7P136 + + ntpq/ntpq-opts.h@1.138 +3 -3 + NTP_4_2_7P136 + + ntpq/ntpq-opts.texi@1.138 +2 -2 + NTP_4_2_7P136 + + ntpq/ntpq.1@1.138 +2 -2 + NTP_4_2_7P136 + + ntpsnmpd/ntpsnmpd-opts.c@1.138 +2 -2 + NTP_4_2_7P136 + + ntpsnmpd/ntpsnmpd-opts.h@1.138 +3 -3 + NTP_4_2_7P136 + + ntpsnmpd/ntpsnmpd-opts.texi@1.138 +2 -2 + NTP_4_2_7P136 + + ntpsnmpd/ntpsnmpd.1@1.138 +2 -2 + NTP_4_2_7P136 + + packageinfo.sh@1.138 +1 -1 + NTP_4_2_7P136 + + sntp/sntp-opts.c@1.132 +2 -2 + NTP_4_2_7P136 + + sntp/sntp-opts.h@1.132 +3 -3 + NTP_4_2_7P136 + + sntp/sntp-opts.texi@1.132 +2 -2 + NTP_4_2_7P136 + + sntp/sntp.1@1.132 +2 -2 + NTP_4_2_7P136 + + sntp/sntp.html@1.132 +1 -1 + NTP_4_2_7P136 + + util/ntp-keygen-opts.c@1.136 +2 -2 + NTP_4_2_7P136 + + util/ntp-keygen-opts.h@1.136 +3 -3 + NTP_4_2_7P136 + + util/ntp-keygen-opts.texi@1.139 +2 -2 + NTP_4_2_7P136 + + util/ntp-keygen.1@1.139 +2 -2 + NTP_4_2_7P136 + +ChangeSet@1.2479.1.10, 2011-03-02 06:13:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1839] 4.2.7p135 still installs libevent ev*.h headers. + + ChangeLog@1.806 +1 -0 + [Bug 1839] 4.2.7p135 still installs libevent ev*.h headers. + + sntp/libevent/Makefile.am@1.3 +8 -2 + [Bug 1839] 4.2.7p135 still installs libevent ev*.h headers. + +ChangeSet@1.2479.1.9, 2011-03-02 00:29:27+00:00, stenn@deacon.udel.edu + NTP_4_2_7P135 + TAG: NTP_4_2_7P135 + + ChangeLog@1.805 +1 -0 + NTP_4_2_7P135 + + clockstuff/clktest-opts.c@1.61 +2 -2 + NTP_4_2_7P135 + + clockstuff/clktest-opts.h@1.61 +3 -3 + NTP_4_2_7P135 + + ntpd/ntpd-opts.c@1.140 +2 -2 + NTP_4_2_7P135 + + ntpd/ntpd-opts.h@1.140 +3 -3 + NTP_4_2_7P135 + + ntpd/ntpd-opts.texi@1.138 +2 -2 + NTP_4_2_7P135 + + ntpd/ntpd.1@1.138 +2 -2 + NTP_4_2_7P135 + + ntpdc/ntpdc-opts.c@1.137 +2 -2 + NTP_4_2_7P135 + + ntpdc/ntpdc-opts.h@1.137 +3 -3 + NTP_4_2_7P135 + + ntpdc/ntpdc-opts.texi@1.137 +2 -2 + NTP_4_2_7P135 + + ntpdc/ntpdc.1@1.137 +2 -2 + NTP_4_2_7P135 + + ntpq/ntpq-opts.c@1.137 +2 -2 + NTP_4_2_7P135 + + ntpq/ntpq-opts.h@1.137 +3 -3 + NTP_4_2_7P135 + + ntpq/ntpq-opts.texi@1.137 +2 -2 + NTP_4_2_7P135 + + ntpq/ntpq.1@1.137 +2 -2 + NTP_4_2_7P135 + + ntpsnmpd/ntpsnmpd-opts.c@1.137 +2 -2 + NTP_4_2_7P135 + + ntpsnmpd/ntpsnmpd-opts.h@1.137 +3 -3 + NTP_4_2_7P135 + + ntpsnmpd/ntpsnmpd-opts.texi@1.137 +2 -2 + NTP_4_2_7P135 + + ntpsnmpd/ntpsnmpd.1@1.137 +2 -2 + NTP_4_2_7P135 + + packageinfo.sh@1.137 +1 -1 + NTP_4_2_7P135 + + sntp/sntp-opts.c@1.131 +2 -2 + NTP_4_2_7P135 + + sntp/sntp-opts.h@1.131 +3 -3 + NTP_4_2_7P135 + + sntp/sntp-opts.texi@1.131 +2 -2 + NTP_4_2_7P135 + + sntp/sntp.1@1.131 +2 -2 + NTP_4_2_7P135 + + sntp/sntp.html@1.131 +1 -1 + NTP_4_2_7P135 + + util/ntp-keygen-opts.c@1.135 +2 -2 + NTP_4_2_7P135 + + util/ntp-keygen-opts.h@1.135 +3 -3 + NTP_4_2_7P135 + + util/ntp-keygen-opts.texi@1.138 +2 -2 + NTP_4_2_7P135 + + util/ntp-keygen.1@1.138 +2 -2 + NTP_4_2_7P135 + +ChangeSet@1.2479.1.8, 2011-03-01 04:48:43+00:00, davehart@shiny.ad.hartbrothers.com + libevent: When building on systems with CLOCK_MONOTONIC available, + separate the internal timeline (possibly counting since system boot) + from the gettimeofday() timeline in event_base cached timevals. Adds + new event_base_tv_cached() to retrieve cached callback round start + time on the internal timeline, and changes + event_based_gettimeofday_cached() to always return times using the + namesake timeline. This preserves the benefit of using the never- + stepped monotonic clock for event timeouts while providing clients + with times consistently using gettimeofday(). + Correct event_base_gettimeofday_cached() workaround code in + sntp to work with corrected libevent. + Remove sntp l_fp_output() test now that it uses prettydate(). + + BitKeeper/deleted/9f/debug-input-lfp-hex~523a3dc59a6a4e86@1.3 +0 -0 + Rename: sntp/tests/data/debug-input-lfp-hex -> BitKeeper/deleted/9f/debug-input-lfp-hex~523a3dc59a6a4e86 + + ChangeLog@1.804 +12 -0 + libevent: When building on systems with CLOCK_MONOTONIC available, + separate the internal timeline (possibly counting since system boot) + from the gettimeofday() timeline in event_base cached timevals. Adds + new event_base_tv_cached() to retrieve cached callback round start + time on the internal timeline, and changes + event_based_gettimeofday_cached() to always return times using the + namesake timeline. This preserves the benefit of using the never- + stepped monotonic clock for event timeouts while providing clients + with times consistently using gettimeofday(). + Correct event_base_gettimeofday_cached() workaround code in + sntp to work with corrected libevent. + Remove sntp l_fp_output() test now that it uses prettydate(). + + libntp/socket.c@1.6 +3 -6 + Add \n termination overlooked in msyslog()->DPRINTF() changes + + libntp/work_fork.c@1.8 +1 -1 + Add \n termination overlooked in msyslog()->DPRINTF() changes + + sntp/libevent/configure.in@1.3 +4 -0 + Add AM_SILENT_RULES patch now in git libevent. + + sntp/libevent/event-internal.h@1.2 +8 -1 + Add struct timeval tod_tv_cache to struct event_base, analogous + to tv_cache but always using the gettimeofdday() timeline. Not + needed on systems without CLOCK_MONOTONIC. + + sntp/libevent/event.c@1.2 +73 -5 + When building on systems with CLOCK_MONOTONIC available, separate the + internal timeline (possibly counting since system boot) from the + gettimeofday() timeline in event_base cached timevals. Adds new + event_base_tv_cached() to retrieve cached callback round start time + on the internal timeline, and changes + event_based_gettimeofday_cached() to always return times using the + namesake timeline. This preserves the benefit of using the never- + stepped monotonic clock for event timeouts while providing clients + with times consistently using gettimeofday(). + + sntp/libevent/evthread.c@1.2 +11 -1 + Add signature to struct debug_lock so that invalid lock pointers + can be caught sooner. + + sntp/libevent/include/event2/event.h@1.2 +18 -3 + Add event_base_tv_cached() to retrieve the start-of-callbacks + time on the internal timeline (possibly monotonic). + + sntp/m4/ntp_libevent.m4@1.6 +2 -1 + Respect a hypothetical -R/some/lib/path in libevent.pc. + Pass --enable-silent-rules to tearoff libevent configure. + + sntp/m4/ntp_openssl.m4@1.17 +1 -1 + Correct comment to match code. + + sntp/main.c@1.69 +121 -49 + Use pthread locks/mutexes/cond vars despite our so-far single-threaded + use of libevent. + Correct event_base_gettimeofday_cached() workaround code in + sntp to work with corrected libevent. + + sntp/networking.c@1.58 +31 -25 + Show server address in wrong org timestamp message. + + sntp/tests/Makefile.am@1.24 +0 -2 + Remove sntp l_fp_output() test now that it uses prettydate(). + + sntp/tests/packetProcessing.cpp@1.5 +4 -4 + whitespace cleanup only + + sntp/tests/utilities.cpp@1.7 +0 -16 + Remove sntp l_fp_output() test now that it uses prettydate(). + + sntp/utilities.c@1.17 +5 -14 + use prettydate() for l_fp_output() + +ChangeSet@1.2479.1.7, 2011-02-25 12:37:40+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1839] 4.2.7p131 installs libevent ev*.h headers. + + ChangeLog@1.803 +1 -0 + [Bug 1839] 4.2.7p131 installs libevent ev*.h headers. + + sntp/libevent/include/Makefile.am@1.2 +9 -2 + [Bug 1839] 4.2.7p131 installs libevent ev*.h headers. + +ChangeSet@1.2479.1.6, 2011-02-25 12:36:58+00:00, davehart@shiny.ad.hartbrothers.com + Ensure CONFIG_SHELL is not empty before relying on it for #! scripts. + + ChangeLog@1.802 +1 -0 + Ensure CONFIG_SHELL is not empty before relying on it for #! scripts. + + configure.ac@1.519 +1 -0 + Ensure CONFIG_SHELL is not empty before relying on it for #! scripts. + +ChangeSet@1.2479.1.5, 2011-02-24 10:50:23+00:00, stenn@deacon.udel.edu + NTP_4_2_7P134 + TAG: NTP_4_2_7P134 + + ChangeLog@1.801 +1 -0 + NTP_4_2_7P134 + + clockstuff/clktest-opts.c@1.60 +2 -2 + NTP_4_2_7P134 + + clockstuff/clktest-opts.h@1.60 +3 -3 + NTP_4_2_7P134 + + ntpd/ntpd-opts.c@1.139 +2 -2 + NTP_4_2_7P134 + + ntpd/ntpd-opts.h@1.139 +3 -3 + NTP_4_2_7P134 + + ntpd/ntpd-opts.texi@1.137 +2 -2 + NTP_4_2_7P134 + + ntpd/ntpd.1@1.137 +2 -2 + NTP_4_2_7P134 + + ntpdc/ntpdc-opts.c@1.136 +2 -2 + NTP_4_2_7P134 + + ntpdc/ntpdc-opts.h@1.136 +3 -3 + NTP_4_2_7P134 + + ntpdc/ntpdc-opts.texi@1.136 +2 -2 + NTP_4_2_7P134 + + ntpdc/ntpdc.1@1.136 +2 -2 + NTP_4_2_7P134 + + ntpq/ntpq-opts.c@1.136 +2 -2 + NTP_4_2_7P134 + + ntpq/ntpq-opts.h@1.136 +3 -3 + NTP_4_2_7P134 + + ntpq/ntpq-opts.texi@1.136 +2 -2 + NTP_4_2_7P134 + + ntpq/ntpq.1@1.136 +2 -2 + NTP_4_2_7P134 + + ntpsnmpd/ntpsnmpd-opts.c@1.136 +2 -2 + NTP_4_2_7P134 + + ntpsnmpd/ntpsnmpd-opts.h@1.136 +3 -3 + NTP_4_2_7P134 + + ntpsnmpd/ntpsnmpd-opts.texi@1.136 +2 -2 + NTP_4_2_7P134 + + ntpsnmpd/ntpsnmpd.1@1.136 +2 -2 + NTP_4_2_7P134 + + packageinfo.sh@1.136 +1 -1 + NTP_4_2_7P134 + + sntp/sntp-opts.c@1.130 +2 -2 + NTP_4_2_7P134 + + sntp/sntp-opts.h@1.130 +3 -3 + NTP_4_2_7P134 + + sntp/sntp-opts.texi@1.130 +2 -2 + NTP_4_2_7P134 + + sntp/sntp.1@1.130 +2 -2 + NTP_4_2_7P134 + + sntp/sntp.html@1.130 +1 -1 + NTP_4_2_7P134 + + util/ntp-keygen-opts.c@1.134 +2 -2 + NTP_4_2_7P134 + + util/ntp-keygen-opts.h@1.134 +3 -3 + NTP_4_2_7P134 + + util/ntp-keygen-opts.texi@1.137 +2 -2 + NTP_4_2_7P134 + + util/ntp-keygen.1@1.137 +2 -2 + NTP_4_2_7P134 + +ChangeSet@1.2479.2.4, 2011-02-24 04:21:34+00:00, davehart@shiny.ad.hartbrothers.com + Another ac_cv_path* variable needs clearing to prevent caching the + full path to pkg-config. + + sntp/m4/ntp_pkg_config.m4@1.2 +1 -0 + Another ac_cv_path* variable needs clearing to prevent caching the + full path to pkg-config. + +ChangeSet@1.2479.1.3, 2011-02-23 16:58:30-05:00, stenn@deacon.udel.edu + merge cleanup + + ChangeLog@1.800 +7 -7 + merge cleanup + +ChangeSet@1.2479.2.3, 2011-02-23 20:34:51+00:00, davehart@shiny.ad.hartbrothers.com + Fix make distcheck failure seen on psp-deb1 by distributing + sntp/tests/data files individually by name rather than + listing "data". + + sntp/tests/Makefile.am@1.23 +16 -1 + Fix make distcheck failure seen on psp-deb1 by distributing + sntp/tests/data files individually by name rather than + listing "data". + +ChangeSet@1.2479.2.1, 2011-02-23 18:57:00+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1837] Build fails on Win7 due to regedit requiring privilege. + Provide fallback definitions for GetAdaptersAddresses() for Windows + build environments lacking iphlpapi.h. + Rename file containing 1.xxxx ChangeSet revision from version to + scm-rev to avoid invoking GNU make implicit rules attempting to + compile version.c into version. Problem was with sntp/version.o + during make distcheck after fix for spurious sntp rebuilds. + + ChangeLog@1.797.1.1 +7 -0 + [Bug 1837] Build fails on Win7 due to regedit requiring privilege. + Provide fallback definitions for GetAdaptersAddresses() for Windows + build environments lacking iphlpapi.h. + Rename file containing 1.xxxx ChangeSet revision from version to + scm-rev to avoid invoking GNU make implicit rules attempting to + compile version.c into version. Problem was with sntp/version.o + during make distcheck after fix for spurious sntp rebuilds. + + lib/isc/win32/interfaceiter.c@1.21 +4 -4 + Provide fallback definitions for GetAdaptersAddresses() for Windows + build environments lacking iphlpapi.h. + + ntpd/Makefile.am@1.102 +7 -5 + Rename cset file from sntp/version to sntp/scm-rev. + + ntpdate/Makefile.am@1.30 +7 -5 + Rename cset file from sntp/version to sntp/scm-rev. + + ntpdc/Makefile.am@1.60 +7 -5 + Rename cset file from sntp/version to sntp/scm-rev. + + ntpq/Makefile.am@1.56 +8 -6 + Rename cset file from sntp/version to sntp/scm-rev. + + ports/winnt/include/gaa_compat.h@1.1 +771 -0 + BitKeeper file C:/ntp/ntp-dev-1837/ports/winnt/include/gaa_compat.h + + ports/winnt/include/gaa_compat.h@1.0 +0 -0 + + ports/winnt/scripts/mkver.bat@1.14 +11 -7 + [Bug 1837] Build fails on Win7 due to regedit requiring privilege. + Rename file containing 1.xxxx ChangeSet revision from version to + scm-rev to avoid invoking GNU make implicit rules attempting to + compile version.c into version. Problem was with sntp/version.o + during make distcheck after fix for spurious sntp rebuilds. + + + ports/winnt/vs2008/libntp/libntp.vcproj@1.39 +6 -2 + add gaa_compat.h reference + + sntp/Makefile.am@1.57.1.1 +14 -9 + Rename cset file from sntp/version to sntp/scm-rev. + Fixes psp-deb1 make distcheck failure on sntp/version.o, which was + using an implicit rule to build presumed-executable "version" from + ../../sntp/../../sntp/version.c. + + sntp/libevent/test/Makefile.am@1.3 +1 -1 + http://sourceforge.net/tracker/?func=detail&aid=3189896&group_id=50884&atid=461324 + + util/Makefile.am@1.59 +8 -6 + Rename cset file from sntp/version to sntp/scm-rev. + +ChangeSet@1.2479.1.1, 2011-02-23 11:06:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P133 + TAG: NTP_4_2_7P133 + + ChangeLog@1.798 +1 -0 + NTP_4_2_7P133 + + clockstuff/clktest-opts.c@1.59 +2 -2 + NTP_4_2_7P133 + + clockstuff/clktest-opts.h@1.59 +3 -3 + NTP_4_2_7P133 + + ntpd/ntpd-opts.c@1.138 +2 -2 + NTP_4_2_7P133 + + ntpd/ntpd-opts.h@1.138 +3 -3 + NTP_4_2_7P133 + + ntpd/ntpd-opts.texi@1.136 +2 -2 + NTP_4_2_7P133 + + ntpd/ntpd.1@1.136 +2 -2 + NTP_4_2_7P133 + + ntpdc/ntpdc-opts.c@1.135 +2 -2 + NTP_4_2_7P133 + + ntpdc/ntpdc-opts.h@1.135 +3 -3 + NTP_4_2_7P133 + + ntpdc/ntpdc-opts.texi@1.135 +2 -2 + NTP_4_2_7P133 + + ntpdc/ntpdc.1@1.135 +2 -2 + NTP_4_2_7P133 + + ntpq/ntpq-opts.c@1.135 +2 -2 + NTP_4_2_7P133 + + ntpq/ntpq-opts.h@1.135 +3 -3 + NTP_4_2_7P133 + + ntpq/ntpq-opts.texi@1.135 +2 -2 + NTP_4_2_7P133 + + ntpq/ntpq.1@1.135 +2 -2 + NTP_4_2_7P133 + + ntpsnmpd/ntpsnmpd-opts.c@1.135 +2 -2 + NTP_4_2_7P133 + + ntpsnmpd/ntpsnmpd-opts.h@1.135 +3 -3 + NTP_4_2_7P133 + + ntpsnmpd/ntpsnmpd-opts.texi@1.135 +2 -2 + NTP_4_2_7P133 + + ntpsnmpd/ntpsnmpd.1@1.135 +2 -2 + NTP_4_2_7P133 + + packageinfo.sh@1.135 +1 -1 + NTP_4_2_7P133 + + sntp/sntp-opts.c@1.129 +2 -2 + NTP_4_2_7P133 + + sntp/sntp-opts.h@1.129 +3 -3 + NTP_4_2_7P133 + + sntp/sntp-opts.texi@1.129 +2 -2 + NTP_4_2_7P133 + + sntp/sntp.1@1.129 +2 -2 + NTP_4_2_7P133 + + sntp/sntp.html@1.129 +1 -1 + NTP_4_2_7P133 + + util/ntp-keygen-opts.c@1.133 +2 -2 + NTP_4_2_7P133 + + util/ntp-keygen-opts.h@1.133 +3 -3 + NTP_4_2_7P133 + + util/ntp-keygen-opts.texi@1.136 +2 -2 + NTP_4_2_7P133 + + util/ntp-keygen.1@1.136 +2 -2 + NTP_4_2_7P133 + +ChangeSet@1.2478.1.1, 2011-02-22 19:38:18-05:00, stenn@psp-deb1.ntp.org + Start using the new autogen doc template + + sntp/Makefile.am@1.56.1.1 +1 -1 + Start using the new autogen doc template + +ChangeSet@1.2479, 2011-02-22 23:21:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1834] ntpdate 4.2.7p131 aborts with assertion failure. + Move sntp last in top-level Makefile.am SUBDIRS so that the libevent + tearoff (if required) and sntp are compiled after the rest. + Use a single set of Automake options for each package in configure.ac + AM_INIT, remove Makefile.am AUTOMAKE_OPTIONS= lines. + Correct spurious sntp rebuilds triggered by a make misperception + sntp/version was out-of-date relative to phony target FRC.version. + Do not cache paths to perl, test, or pkg-config, searching the PATH + at configure time is worth it to pick up tool updates. + + ChangeLog@1.797 +9 -0 + [Bug 1834] ntpdate 4.2.7p131 aborts with assertion failure. + Move sntp last in top-level Makefile.am SUBDIRS so that the libevent + tearoff (if required) and sntp are compiled after the rest. + Use a single set of Automake options for each package in configure.ac + AM_INIT, remove Makefile.am AUTOMAKE_OPTIONS= lines. + Correct spurious sntp rebuilds triggered by a make misperception + sntp/version was out-of-date relative to phony target FRC.version. + Do not cache paths to perl, test, or pkg-config, searching the PATH + at configure time is worth it to pick up tool updates. + + Makefile.am@1.108 +1 -5 + Distribute includes.mf. + Build sntp late in the game to exhibit problems elsewhere first. + + adjtimed/Makefile.am@1.12 +6 -11 + use check-libntp.mf. + + check-libopts.mf@1.1 +14 -0 + BitKeeper file C:/ntp/ntp-dev-1834/check-libopts.mf + + check-libopts.mf@1.0 +0 -0 + + clockstuff/Makefile.am@1.19 +3 -12 + use check-libntp.mf and check-libopts.mf. + + configure.ac@1.518 +12 -2 + Do not cache paths to perl, test, or pkg-config, searching the PATH + at configure time is worth it to pick up tool updates. + + include/Makefile.am@1.47 +0 -2 + Use a single set of Automake options per package in AM_INIT + + include/isc/Makefile.am@1.2 +0 -2 + Use a single set of Automake options per package in AM_INIT + + libparse/Makefile.am@1.26 +7 -10 + add check-libparse target for ntpd/Makefile.am use + + ntpd/Makefile.am@1.101 +12 -20 + Use a single set of Automake options per package in AM_INIT + + ntpdate/Makefile.am@1.29 +8 -15 + use check-libntp.mf. + + ntpdate/ntpdate.c@1.85 +1 -1 + [Bug 1834] ntpdate 4.2.7p131 aborts with assertion failure. + + ntpdc/Makefile.am@1.59 +3 -9 + make sure libopts.la is up-to-date. + + ntpq/Makefile.am@1.55 +3 -9 + make sure libopts.la is up-to-date. + + ntpsnmpd/Makefile.am@1.27 +3 -9 + use check-libntp.mf and check-libopts.mf. + + scripts/mkver.in@1.13 +1 -1 + Use CONFIG_SHELL for #! line instead of AC_PATH_PROG(sh). + + scripts/ntpver.in@1.3 +2 -2 + Use CONFIG_SHELL for #! line instead of AC_PATH_PROG(sh). + Use @AWK@ from AC_PROG_AWK instead of 'awk'. + + sntp/Makefile.am@1.57 +14 -20 + Distribute includes.mf. + + sntp/check-libntp.mf@1.1 +15 -0 + BitKeeper file C:/ntp/ntp-dev-1834/sntp/check-libntp.mf + + sntp/check-libntp.mf@1.0 +0 -0 + + sntp/check-libopts.mf@1.1 +14 -0 + BitKeeper file C:/ntp/ntp-dev-1834/sntp/check-libopts.mf + + sntp/check-libopts.mf@1.0 +0 -0 + + sntp/m4/ntp_googletest.m4@1.3 +1 -0 + Do not cache paths to perl, test, or pkg-config, searching the PATH + at configure time is worth it to pick up tool updates. + + sntp/m4/ntp_libevent.m4@1.5 +1 -15 + Use NTP_PKG_CONFIG. + + sntp/m4/ntp_openssl.m4@1.16 +10 -23 + Use NTP_PKG_CONFIG. + Attempt to fix broken need_dash_r logic. + + sntp/m4/ntp_pkg_config.m4@1.1 +26 -0 + BitKeeper file C:/ntp/ntp-dev-1834/sntp/m4/ntp_pkg_config.m4 + + sntp/m4/ntp_pkg_config.m4@1.0 +0 -0 + + sntp/tests/Makefile.am@1.22 +12 -0 + use adapted check-libntp.mf snippet + + tests/libntp/Makefile.am@1.36 +12 -0 + use adapted check-libntp.mf snippet + + util/Makefile.am@1.58 +3 -8 + use check-libntp.mf and check-libopts.mf. + +ChangeSet@1.2478, 2011-02-22 08:28:31+00:00, stenn@deacon.udel.edu + NTP_4_2_7P132 + TAG: NTP_4_2_7P132 + + ChangeLog@1.796 +1 -0 + NTP_4_2_7P132 + + clockstuff/clktest-opts.c@1.58 +2 -2 + NTP_4_2_7P132 + + clockstuff/clktest-opts.h@1.58 +3 -3 + NTP_4_2_7P132 + + ntpd/ntpd-opts.c@1.137 +2 -2 + NTP_4_2_7P132 + + ntpd/ntpd-opts.h@1.137 +3 -3 + NTP_4_2_7P132 + + ntpd/ntpd-opts.texi@1.135 +4 -4 + NTP_4_2_7P132 + + ntpd/ntpd.1@1.135 +2 -2 + NTP_4_2_7P132 + + ntpdc/ntpdc-opts.c@1.134 +2 -2 + NTP_4_2_7P132 + + ntpdc/ntpdc-opts.h@1.134 +3 -3 + NTP_4_2_7P132 + + ntpdc/ntpdc-opts.texi@1.134 +4 -4 + NTP_4_2_7P132 + + ntpdc/ntpdc.1@1.134 +2 -2 + NTP_4_2_7P132 + + ntpq/ntpq-opts.c@1.134 +2 -2 + NTP_4_2_7P132 + + ntpq/ntpq-opts.h@1.134 +3 -3 + NTP_4_2_7P132 + + ntpq/ntpq-opts.texi@1.134 +4 -4 + NTP_4_2_7P132 + + ntpq/ntpq.1@1.134 +2 -2 + NTP_4_2_7P132 + + ntpsnmpd/ntpsnmpd-opts.c@1.134 +2 -2 + NTP_4_2_7P132 + + ntpsnmpd/ntpsnmpd-opts.h@1.134 +3 -3 + NTP_4_2_7P132 + + ntpsnmpd/ntpsnmpd-opts.texi@1.134 +4 -4 + NTP_4_2_7P132 + + ntpsnmpd/ntpsnmpd.1@1.134 +2 -2 + NTP_4_2_7P132 + + packageinfo.sh@1.134 +1 -1 + NTP_4_2_7P132 + + sntp/sntp-opts.c@1.128 +2 -2 + NTP_4_2_7P132 + + sntp/sntp-opts.h@1.128 +3 -3 + NTP_4_2_7P132 + + sntp/sntp-opts.texi@1.128 +4 -4 + NTP_4_2_7P132 + + sntp/sntp.1@1.128 +2 -2 + NTP_4_2_7P132 + + sntp/sntp.html@1.128 +3 -3 + NTP_4_2_7P132 + + util/ntp-keygen-opts.c@1.132 +2 -2 + NTP_4_2_7P132 + + util/ntp-keygen-opts.h@1.132 +3 -3 + NTP_4_2_7P132 + + util/ntp-keygen-opts.texi@1.135 +4 -4 + NTP_4_2_7P132 + + util/ntp-keygen.1@1.135 +2 -2 + NTP_4_2_7P132 + +ChangeSet@1.2477, 2011-02-22 08:01:28+00:00, davehart@shiny.ad.hartbrothers.com + Avoid relying on remake rules for routine build/flock-build for + libevent as for the top-level and sntp subproject. + + ChangeLog@1.795 +3 -1 + Avoid relying on remake rules for routine build/flock-build for + libevent as for the top-level and sntp subproject. + + build@1.44 +8 -1 + Avoid relying on remake rules for routine build/flock-build for + libevent as for the top-level and sntp subproject. + +ChangeSet@1.2476, 2011-02-22 02:51:42-05:00, stenn@deacon.udel.edu + ElectricFence was suffering bitrot - remove it. valgrind seems better. + + BitKeeper/deleted/04/COPYING~52231e38@1.3 +0 -0 + Delete: ElectricFence/COPYING + + BitKeeper/deleted/26/Makefile-~52231e38@1.3 +0 -0 + Delete: ElectricFence/Makefile- + + BitKeeper/deleted/28/efence.h~52231e38@1.3 +0 -0 + Delete: ElectricFence/efence.h + + BitKeeper/deleted/49/Makefile.am~52231e38@1.8 +0 -0 + Delete: ElectricFence/Makefile.am + + BitKeeper/deleted/4b/README~52231e38@1.3 +0 -0 + Delete: ElectricFence/README + + BitKeeper/deleted/54/efence.c~52231e38@1.3 +0 -0 + Delete: ElectricFence/efence.c + + BitKeeper/deleted/59/print.c~52231e38@1.3 +0 -0 + Delete: ElectricFence/print.c + + BitKeeper/deleted/8b/page.c~52231e38@1.6 +0 -0 + Delete: ElectricFence/page.c + + BitKeeper/deleted/a8/eftest.c~52231e38@1.3 +0 -0 + Delete: ElectricFence/eftest.c + + BitKeeper/deleted/de/CHANGES~52231e38@1.3 +0 -0 + Delete: ElectricFence/CHANGES + + BitKeeper/deleted/e4/libefence.3~52231e38@1.3 +0 -0 + Delete: ElectricFence/libefence.3 + + BitKeeper/deleted/e8/tstheap.c~52231e38@1.3 +0 -0 + Delete: ElectricFence/tstheap.c + + ChangeLog@1.794 +1 -0 + ElectricFence was suffering bitrot - remove it. valgrind seems better. + + Makefile.am@1.107 +0 -1 + ElectricFence was suffering bitrot - remove it. valgrind seems better. + + configure.ac@1.517 +0 -24 + ElectricFence was suffering bitrot - remove it. valgrind seems better. + +ChangeSet@1.2471.1.2, 2011-02-22 01:35:03-05:00, stenn@deacon.udel.edu + Updated to AutoGen-5.11.6 + + clockstuff/clktest-opts.c@1.57 +27 -11 + Updated to AutoGen-5.11.6 + + clockstuff/clktest-opts.h@1.57 +2 -2 + Updated to AutoGen-5.11.6 + + ntpd/ntpd-opts.c@1.136 +24 -8 + Updated to AutoGen-5.11.6 + + ntpd/ntpd-opts.h@1.136 +2 -2 + Updated to AutoGen-5.11.6 + + ntpd/ntpd-opts.texi@1.134 +3 -3 + Updated to AutoGen-5.11.6 + + ntpd/ntpd.1@1.134 +2 -2 + Updated to AutoGen-5.11.6 + + ntpdc/ntpdc-opts.c@1.133 +34 -25 + Updated to AutoGen-5.11.6 + + ntpdc/ntpdc-opts.h@1.133 +2 -2 + Updated to AutoGen-5.11.6 + + ntpdc/ntpdc-opts.texi@1.133 +11 -18 + Updated to AutoGen-5.11.6 + + ntpdc/ntpdc.1@1.133 +2 -2 + Updated to AutoGen-5.11.6 + + ntpq/ntpq-opts.c@1.133 +32 -18 + Updated to AutoGen-5.11.6 + + ntpq/ntpq-opts.h@1.133 +2 -2 + Updated to AutoGen-5.11.6 + + ntpq/ntpq-opts.texi@1.133 +9 -11 + Updated to AutoGen-5.11.6 + + ntpq/ntpq.1@1.133 +2 -2 + Updated to AutoGen-5.11.6 + + ntpsnmpd/ntpsnmpd-opts.c@1.133 +24 -8 + Updated to AutoGen-5.11.6 + + ntpsnmpd/ntpsnmpd-opts.h@1.133 +2 -2 + Updated to AutoGen-5.11.6 + + ntpsnmpd/ntpsnmpd-opts.texi@1.133 +3 -3 + Updated to AutoGen-5.11.6 + + ntpsnmpd/ntpsnmpd.1@1.133 +2 -2 + Updated to AutoGen-5.11.6 + + sntp/sntp-opts.c@1.127 +28 -12 + Updated to AutoGen-5.11.6 + + sntp/sntp-opts.h@1.127 +2 -2 + Updated to AutoGen-5.11.6 + + sntp/sntp-opts.texi@1.127 +6 -6 + Updated to AutoGen-5.11.6 + + sntp/sntp.1@1.127 +2 -2 + Updated to AutoGen-5.11.6 + + sntp/sntp.html@1.127 +5 -5 + Updated to AutoGen-5.11.6 + + util/ntp-keygen-opts.c@1.131 +28 -12 + Updated to AutoGen-5.11.6 + + util/ntp-keygen-opts.h@1.131 +2 -2 + Updated to AutoGen-5.11.6 + + util/ntp-keygen-opts.texi@1.134 +5 -5 + Updated to AutoGen-5.11.6 + + util/ntp-keygen.1@1.134 +2 -2 + Updated to AutoGen-5.11.6 + +ChangeSet@1.2473, 2011-02-22 06:06:28+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1832] ntpdate doesn't allow timeout > 2s. + [Bug 1833] The checking sem_timedwait() fails without -pthread. + Enable all relevant automake warnings. + Correct Solaris 2.1x PTHREAD_ONCE_INIT extra braces test to avoid + triggering warnings due to excess braces. + Remove libevent-cfg from sntp/Makefile.am. + Provide bug report and URL options to Autoconf. + + ChangeLog@1.793 +7 -1 + [Bug 1832] ntpdate doesn't allow timeout > 2s. + [Bug 1833] The checking sem_timedwait() fails without -pthread. + Enable all relevant automake warnings. + Correct Solaris 2.1x PTHREAD_ONCE_INIT extra braces test to avoid + triggering warnings due to excess braces. + Remove libevent-cfg from sntp/Makefile.am. + Provide bug report and URL options to Autoconf. + + Makefile.am@1.106 +1 -3 + Enable all relevant automake warnings. + + + adjtimed/Makefile.am@1.11 +7 -10 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + clockstuff/Makefile.am@1.18 +7 -9 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + configure.ac@1.516 +11 -4 + Pass automake options via AM_INIT_AUTOMAKE so they apply to all Makefile.am + without requiring duplicative AUTOMAKE_OPTIONS = lines. + Enable all relevant automake warnings. + + includes.mf@1.1 +6 -0 + BitKeeper file C:/ntp/ntp-dev-m4quote/includes.mf + + includes.mf@1.0 +0 -0 + + kernel/Makefile.am@1.5 +0 -2 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + kernel/sys/Makefile.am@1.6 +0 -5 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + libntp/Makefile.am@1.61 +7 -11 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + libparse/Makefile.am@1.25 +5 -10 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + ntpd/Makefile.am@1.100 +6 -8 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + ntpd/refclock_true.c@1.18 +3 -3 + include system and C runtime headers before NTP's + + ntpdate/Makefile.am@1.28 +6 -10 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + ntpdate/ntpdate.c@1.84 +1 -12 + [Bug 1832] ntpdate doesn't allow timeout > 2s. + + ntpdate/ntpdate.h@1.13 +6 -3 + [Bug 1832] ntpdate doesn't allow timeout > 2s. + + ntpdc/Makefile.am@1.58 +8 -10 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + ntpq/Makefile.am@1.54 +8 -10 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + ntpsnmpd/Makefile.am@1.26 +10 -12 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + parseutil/Makefile.am@1.15 +7 -9 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + sntp/Makefile.am@1.56 +15 -17 + Enable all relevant automake warnings. + + + sntp/configure.ac@1.58 +10 -4 + Pass automake options via AM_INIT_AUTOMAKE so they apply to all Makefile.am + without requiring duplicative AUTOMAKE_OPTIONS = lines. + Enable all relevant automake warnings. + + sntp/includes.mf@1.1 +6 -0 + BitKeeper file C:/ntp/ntp-dev-m4quote/sntp/includes.mf + + sntp/includes.mf@1.0 +0 -0 + + sntp/m4/ntp_libevent.m4@1.4 +3 -3 + $ac_configure_args is maintained with a leading space, particularly important + with Autoconf 2.61, not so much with 2.68. + + sntp/m4/ntp_libntp.m4@1.7 +27 -10 + [Bug 1833] The checking sem_timedwait() fails without -pthread. + + sntp/tests/Makefile.am@1.21 +20 -17 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + tests/libntp/Makefile.am@1.35 +18 -15 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + + util/Makefile.am@1.57 +8 -13 + automake deprecates INCLUDES, use AM_CPPFLAGS instead + +ChangeSet@1.2082.4.204, 2011-02-22 00:38:53-05:00, stenn@deacon.udel.edu + upgrade to libopts-34.0.9 + + clockstuff/clktest-opts.c@1.12.1.1 +100 -76 + upgrade to libopts-34.0.9 + + clockstuff/clktest-opts.h@1.12.1.1 +32 -25 + upgrade to libopts-34.0.9 + + ntpd/ntpd-opts.c@1.248.34.1 +24 -8 + upgrade to libopts-34.0.9 + + ntpd/ntpd-opts.h@1.248.34.1 +2 -2 + upgrade to libopts-34.0.9 + + ntpd/ntpdsim-opts.c@1.18 +202 -171 + upgrade to libopts-34.0.9 + + ntpd/ntpdsim-opts.h@1.18 +32 -28 + upgrade to libopts-34.0.9 + + ntpdc/ntpdc-opts.c@1.244.34.1 +34 -25 + upgrade to libopts-34.0.9 + + ntpdc/ntpdc-opts.h@1.244.34.1 +2 -2 + upgrade to libopts-34.0.9 + + ntpq/ntpq-opts.c@1.245.34.1 +32 -18 + upgrade to libopts-34.0.9 + + ntpq/ntpq-opts.h@1.245.34.1 +2 -2 + upgrade to libopts-34.0.9 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.35.1 +24 -8 + upgrade to libopts-34.0.9 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.35.1 +2 -2 + upgrade to libopts-34.0.9 + + sntp/libopts/COPYING.gplv3@1.4 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/COPYING.lgplv3@1.4 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/Makefile.am@1.9 +3 -3 + upgrade to libopts-34.0.9 + + sntp/libopts/README@1.6 +63 -34 + upgrade to libopts-34.0.9 + + sntp/libopts/ag-char-map.h@1.12 +3 -3 + upgrade to libopts-34.0.9 + + sntp/libopts/autoopts.c@1.9 +23 -19 + upgrade to libopts-34.0.9 + + sntp/libopts/autoopts.h@1.8 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/autoopts/options.h@1.11 +11 -10 + upgrade to libopts-34.0.9 + + sntp/libopts/autoopts/usage-txt.h@1.11 +4 -4 + upgrade to libopts-34.0.9 + + sntp/libopts/boolean.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/compat/compat.h@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/compat/windows-config.h@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/configfile.c@1.10 +174 -51 + upgrade to libopts-34.0.9 + + sntp/libopts/cook.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/enumeration.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/environment.c@1.9 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/file.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/genshell.c@1.12 +29 -13 + upgrade to libopts-34.0.9 + + sntp/libopts/genshell.h@1.12 +3 -3 + upgrade to libopts-34.0.9 + + sntp/libopts/load.c@1.9 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/m4/libopts.m4@1.15 +10 -21 + upgrade to libopts-34.0.9 + + sntp/libopts/m4/liboptschk.m4@1.8 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/makeshell.c@1.8 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/nested.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/numeric.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/parse-duration.c@1.4 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/parse-duration.h@1.4 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/pgusage.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/proto.h@1.12 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/putshell.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/reset.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/restore.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/save.c@1.8 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/sort.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/stack.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/streqvcmp.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/text_mmap.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/time.c@1.7 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/tokenize.c@1.5 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/usage.c@1.8 +11 -7 + upgrade to libopts-34.0.9 + + sntp/libopts/value-type.h@1.12 +1 -1 + upgrade to libopts-34.0.9 + + sntp/libopts/version.c@1.7 +9 -12 + upgrade to libopts-34.0.9 + + sntp/libopts/xat-attribute.h@1.12 +1 -1 + upgrade to libopts-34.0.9 + + sntp/sntp-opts.c@1.117.32.1 +27 -11 + upgrade to libopts-34.0.9 + + sntp/sntp-opts.h@1.117.32.1 +2 -2 + upgrade to libopts-34.0.9 + + util/ntp-keygen-opts.c@1.247.34.1 +28 -12 + upgrade to libopts-34.0.9 + + util/ntp-keygen-opts.h@1.247.34.1 +2 -2 + upgrade to libopts-34.0.9 + +ChangeSet@1.2467.1.1, 2011-02-21 20:50:01+00:00, davehart@shiny.ad.hartbrothers.com + Autoconf 2.61 workarounds + + sntp/m4/ntp_cacheversion.m4@1.13 +8 -1 + Autoconf 2.61 workaround: do not use AS_UNSET with a variable variable name. + + sntp/m4/ntp_libntp.m4@1.4.1.1 +12 -13 + Autoconf 2.61 workarounds: do not use [] for action-if-not-found with + AC_CHECK_LIB and AC_CHECK_FUNC + +ChangeSet@1.2471, 2011-02-21 06:04:08-05:00, stenn@deacon.udel.edu + Remove libevent-cfg from sntp/Makefile.am + + ChangeLog@1.792 +1 -0 + Remove libevent-cfg from sntp/Makefile.am + + sntp/Makefile.am@1.55 +0 -1 + Remove libevent-cfg from sntp/Makefile.am + +ChangeSet@1.2470, 2011-02-21 09:21:02+00:00, stenn@deacon.udel.edu + NTP_4_2_7P131 + TAG: NTP_4_2_7P131 + + ChangeLog@1.791 +1 -0 + NTP_4_2_7P131 + + clockstuff/clktest-opts.c@1.55 +2 -2 + NTP_4_2_7P131 + + clockstuff/clktest-opts.h@1.55 +3 -3 + NTP_4_2_7P131 + + ntpd/ntpd-opts.c@1.135 +2 -2 + NTP_4_2_7P131 + + ntpd/ntpd-opts.h@1.135 +3 -3 + NTP_4_2_7P131 + + ntpd/ntpd-opts.texi@1.133 +2 -2 + NTP_4_2_7P131 + + ntpd/ntpd.1@1.133 +2 -2 + NTP_4_2_7P131 + + ntpdc/ntpdc-opts.c@1.132 +2 -2 + NTP_4_2_7P131 + + ntpdc/ntpdc-opts.h@1.132 +3 -3 + NTP_4_2_7P131 + + ntpdc/ntpdc-opts.texi@1.132 +2 -2 + NTP_4_2_7P131 + + ntpdc/ntpdc.1@1.132 +2 -2 + NTP_4_2_7P131 + + ntpq/ntpq-opts.c@1.132 +2 -2 + NTP_4_2_7P131 + + ntpq/ntpq-opts.h@1.132 +3 -3 + NTP_4_2_7P131 + + ntpq/ntpq-opts.texi@1.132 +2 -2 + NTP_4_2_7P131 + + ntpq/ntpq.1@1.132 +2 -2 + NTP_4_2_7P131 + + ntpsnmpd/ntpsnmpd-opts.c@1.132 +2 -2 + NTP_4_2_7P131 + + ntpsnmpd/ntpsnmpd-opts.h@1.132 +3 -3 + NTP_4_2_7P131 + + ntpsnmpd/ntpsnmpd-opts.texi@1.132 +2 -2 + NTP_4_2_7P131 + + ntpsnmpd/ntpsnmpd.1@1.132 +2 -2 + NTP_4_2_7P131 + + packageinfo.sh@1.133 +1 -1 + NTP_4_2_7P131 + + sntp/sntp-opts.c@1.126 +13 -29 + NTP_4_2_7P131 + + sntp/sntp-opts.h@1.126 +4 -4 + NTP_4_2_7P131 + + sntp/sntp-opts.texi@1.126 +7 -8 + NTP_4_2_7P131 + + sntp/sntp.1@1.126 +2 -2 + NTP_4_2_7P131 + + sntp/sntp.html@1.126 +56 -84 + NTP_4_2_7P131 + + util/ntp-keygen-opts.c@1.130 +2 -2 + NTP_4_2_7P131 + + util/ntp-keygen-opts.h@1.130 +3 -3 + NTP_4_2_7P131 + + util/ntp-keygen-opts.texi@1.133 +2 -2 + NTP_4_2_7P131 + + util/ntp-keygen.1@1.133 +2 -2 + NTP_4_2_7P131 + +ChangeSet@1.2469, 2011-02-21 03:59:49-05:00, stenn@deacon.udel.edu + The fixes for bugs 1087 and 1088 are in the udated SNTP code + + ChangeLog@1.790 +2 -0 + The fixes for bugs 1087 and 1088 are in the udated SNTP code + +ChangeSet@1.2468, 2011-02-21 00:26:17-08:00, harlan@hms-mbp.local + older autoconf sometimes dislikes []. + + ChangeLog@1.789 +1 -0 + older autoconf sometimes dislikes []. + + sntp/m4/ntp_libntp.m4@1.5 +4 -6 + older autoconf sometimes dislikes []. + +ChangeSet@1.2422.10.1, 2011-02-20 23:11:05-05:00, stenn@deacon.udel.edu + refclock_acts.c cleanup from Dave Mills + + ChangeLog@1.784.2.1 +1 -0 + refclock_acts.c cleanup from Dave Mills + + ntpd/refclock_acts.c@1.46.1.1 +4 -3 + refclock_acts.c cleanup from Dave Mills + +ChangeSet@1.2466, 2011-02-20 21:20:21+00:00, davehart@shiny.ad.hartbrothers.com + Cleanup for prior merge cset + + include/ntp_machine.h@1.33 +5 -1 + Cleanup for prior merge cset + + include/ntp_unixtime.h@1.10 +1 -6 + Cleanup for prior merge cset + + libntp/systime.c@1.53 +2 -2 + Cleanup for prior merge cset + + ports/winnt/libntp/SetSystemTime.c@1.10 +2 -0 + Cleanup for prior merge cset + + ports/winnt/libntp/getclock.c@1.3 +2 -0 + Cleanup for prior merge cset + + ports/winnt/libntp/util_clockstuff.c@1.5 +1 -0 + Cleanup for prior merge cset + + util/ntp-keygen.c@1.78 +2 -2 + Cleanup for prior merge cset + +ChangeSet@1.2464, 2011-02-20 20:23:00+00:00, davehart@shiny.ad.hartbrothers.com + Attempt typical subpackage approach for libevent + sntp test cleanup + IPv6 hackery + Split up ntp_lib.m4 into smaller, more specific subsets + Use {step,adj}_systime from libntp. Use EX_* codes for exit status. + libevent cleanup + libevent upgrade + Move blocking worker and intres from ntpd to libntp. + Move AC_FUNC_FORK and AC_FUNC_ALLOCA to ntp_libntp.m4 along with move + of intres/blocking worker to libntp. + Use %m instead of strerror(). + make -lz depend on zlib.h + hp-ux portability fix + portability + Allow libevent's regress to be skipped in make check. + Switch sntp from evdns to blocking worker intres. + Quiet "signal_no_reset: signal 18 had flags 20000" on OpenSolaris, + adding SA_NOCLDSTOP to IGNORED_SA_FLAGS. + Be consistent about how blocking children go away: + 1. Parent requests them to go by closing pipe or CHILD_EXIT_REQ. + 2. Child goes away quietly. + 3. Parent sees them gone via broken resp pipe or CHILD_GONE_RESP. + 4. Parent clears blocking_children entry for reuse. + Make delay between queries to addresses resolved from same hostname + per-family in sntp, as ntpd won't consider our v4 and v6 source + addresses to be one remote rate-limit target. + use freeaddrinfo() in ntpq's getnetnum(). + valgrind warned of branch dependent on uninitialized value, + irig_decode()'s local syncdig. + Free OpenSSL dynamic allocations atexit. + Enable pthreads build + libntp autoconf macro cleanup + Move "can't write KoD file" warning from sntp shutdown to startup. + Use libevent log callback to redirect messages from stderr to msyslog() + enable libevent debug mode if sntp debug > 0 + Issue a single read event for each socket, rather than one per query. + Do not attempt to read in socket callback for EV_TIMEOUT. + ipv6 fixes for sntp + Crib some pthread m4 from BIND for libisc. + Fix step/slew logic in sntp. + sntp --headspace option (default 10ms) spaces queries. + Provide less-broken gettimeofday_cached(). + Add support for --(no-)wait and -uctimeout + Remove duplicate clock_gettime/clock_settime logic from sntp/configure.ac, + it's now in sntp/m4/ntp_libntp.m4. + Bump config.cache version stamps to account for cache-incompatible change + to librt detection. + Omit unused code with recent gcc and gnu ld. + AC_LANG update for openldap autoconf macros + Clean up AC_DEFINE and AC_DEFINE_UNQUOTED arg quoting in openldap*.m4 + add a timeout for test-eof.c as it may hang under HP-UX 10.20 + Use pthreads for blocking worker rather than fork, if possible. + Quiet alignment warning due to casting sockaddr * to sockaddr_u * + Quiet ntp_control.c and ntp_request.c warnings about casting char * + to u_int32 * using unions. + Use void * rather than char * for variant pointers to help with + pointer cast increases required alignment warnings. + Fix many warnings enabled with -Wcast-align, when casting + a pointer to a more-strictly-aligned underlying type. + preset ol_with_yielding_select=${ol_with_yielding_select-auto} + Also change tests to use x prefix as insurance against other issues. + We always need the PTHREADS AM_CONDITIONAL. Use the OL check. + Use NTP_LIBEVENT m4sh macro to decide between installed and tearoff + libevent. + Add readonly arg to kod_init_kod_db() for tests -- prevents editing + test baseline input KoD files during make check, regression limited + to sntp/libevent branch. + Switch libevent-2.0.10-stable from ACX_PTHREADS to OL_THREAD_CHECK + Use socketpair() instead of pipe() when available, as avoiding + EV_FEATURE_FDS allows libevent to use a faster backend on + systems like Linux without an O(1) backend that handles pipes. + Remove contentious libevent-cfg sentinel files, modify libevent's + confgure args via $ac_configure_args. + Strip unneeded checks from ntp_ipv6.m4: + for struct sockaddr_storage member ss_family + for struct sockaddr_storage member ss_len + for struct sockaddr_storage member __ss_len + Move things used by libntp from top-level configure.ac to NTP_LIBNTP and NTP_IPV6 + Change "forked worker child (pid 0)" from msyslog() to DPRINTF(). + Change initial socket boundary message from DEBUG-only msyslog() to DPRINTF(). + + BitKeeper/deleted/2b/regress.gen.c~aa03b6be21193937@1.2 +0 -0 + Rename: sntp/libevent/test/regress.gen.c -> BitKeeper/deleted/2b/regress.gen.c~aa03b6be21193937 + + BitKeeper/deleted/31/Makefile.am~a4dc04c7982322c0@1.2 +0 -0 + Rename: sntp/build-libevent/Makefile.am -> BitKeeper/deleted/31/Makefile.am~a4dc04c7982322c0 + + BitKeeper/deleted/5f/acx_pthread.m4~2200dd7a1a4e6b33@1.2 +0 -0 + Rename: sntp/libevent/m4/acx_pthread.m4 -> BitKeeper/deleted/5f/acx_pthread.m4~2200dd7a1a4e6b33 + + BitKeeper/deleted/67/regress.gen.h~23d0c5b9df595958@1.2 +0 -0 + Rename: sntp/libevent/test/regress.gen.h -> BitKeeper/deleted/67/regress.gen.h~23d0c5b9df595958 + + BitKeeper/etc/ignore@1.78 +2 -0 + added regress.gen.c regress.gen.h + + ChangeLog@1.786 +19 -1 + Convert sntp to libevent event-driven socket programming. Instead of + blocking name resolution and querying one NTP server at a time, + resolve server names and send NTP queries without blocking. Add + sntp command-line options to adjust timing and optionally wait for all + servers to respond instead of exiting after the first. + Move "can't write KoD file" warning from sntp shutdown to startup. + Import libevent 2.0.10-stable plus local patches as a tearoff, used + only if the target system lacks an installed libevent 2.0.9 or later. + Move blocking worker and resolver to libntp from ntpd. + Use threads rather than forked child processes for blocking worker + when possible. Override with configure --disable-thread-support. + Move init_logging(), change_logfile(), and setup_logfile() from ntpd + to libntp, use them in sntp. + Test --without-sntp in flock-build script's -no-refclocks variety. + Avoid invoking config.status twice in a row in build script. + Move more m4sh tests needed by libntp to shared .m4 files. + Split up ntp_libntp.m4 into smaller, more specific subsets. + Enable gcc -Wcast-align, fix many instances of warnings when casting + a pointer to a more-strictly-aligned underlying type. + + + Makefile.am@1.105 +2 -23 + SUBDIRS and DIST_SUBDIRS were identical, remove definition of DIST_SUBDIRS + and allow Automake to default it to SUBDIRS. + Add -I sntp/libevent/m4 to ACLOCAL_AMFLAGS to find openldap*.m4. + + adjtimed/Makefile.am@1.10 +2 -2 + enable pthreads build. + + build@1.43 +5 -4 + build: Do not invoke config.status unless Makefile is out of date. + Avoids re-running config.status right after configure ran it, which + triggers spurious am--remake because Makefile is newer than config.h + + clockstuff/Makefile.am@1.17 +2 -2 + enable pthreads build. + + configure.ac@1.515 +41 -806 + Split up ntp_lib.m4 into smaller, more specific subsets + Move AC_FUNC_FORK and AC_FUNC_ALLOCA to ntp_libntp.m4 along with move + of intres/blocking worker to libntp. + Move droproot configure test to libntp with intres. + Bump config.cache version stamps to account for cache-incompatible change + to librt detection. + Move more m4 code needed by libntp to sntp/m4/*.m4 from top-level configure.ac + + deps-ver@1.5 +1 -1 + bump deps-ver to avoid build breaks from moved source files. + + flock-build@1.49 +2 -2 + test --without-sntp in one of the flock-build variants + + include/Makefile.am@1.44.1.1 +1 -0 + rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + + include/intreswork.h@1.5 +11 -5 + Move blocking worker and intres from ntpd to libntp. + rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + + include/intreswork.h@1.4 +0 -0 + Rename: include/ntp_intres.h -> include/intreswork.h + + include/libntp.h@1.2 +3 -1 + use getdtablesize() if available and _SC_OPEN_MAX is not. + + include/ntp_calendar.h@1.9 +2 -0 + include time.h in ntp_calendar.h which uses struct tm. + + include/ntp_control.h@1.57 +7 -2 + Quiet ntp_control.c and ntp_request.c -Wcast-align warnings. + + include/ntp_debug.h@1.4 +2 -1 + Allow %m in DPRINTF + + include/ntp_intres.h@1.1 +45 -0 + Former ntp_intres.h renamed to intreswork.h. + New public interface header for intres, contents moved from ntpd.h. + + include/ntp_intres.h@1.0 +0 -0 + + include/ntp_io.h@1.21 +4 -5 + Move blocking worker and intres from ntpd to libntp. + Move close_all_beyond() and close_all_except() to libntp. + + include/ntp_lists.h@1.8.1.1 +3 -3 + Do not invoke (beforecur) test in LINK_SORT_SLIST with a previously-empty list. + + include/ntp_machine.h@1.32 +1 -11 + Nothing sets TIME_WITH_SYS_TIME, remove it. + + include/ntp_refclock.h@1.29 +2 -17 + Use void * for variant clock/unit pointers. + Remove duplicate LDISC_* definitions. + + include/ntp_request.h@1.42 +26 -17 + Quiet ntp_control.c and ntp_request.c -Wcast-align warnings. + + include/ntp_rfc2553.h@1.38 +9 -0 + Add copy_addrinfo() to copy a single addrinfo and pointed-to + constituents. + + include/ntp_stdlib.h@1.57.1.1 +14 -3 + Add more m*printf() varieties. + Move init_logging(), change_logfile(), and setup_logfile() from ntpd + to libntp. + + include/ntp_tty.h@1.5 +10 -10 + Whitespace, imply maximum LDISC_ flag value with leading 0s. + + include/ntp_unixtime.h@1.7.1.1 +6 -5 + Several files comment that ntp_unixtime.h includes sys/time.h and + time.h, make it so. + Provide GETTIMEOFDAY() macro on systems with getclock() for sntp. + + + include/ntp_worker.h@1.2 +120 -10 + Move blocking worker and intres from ntpd to libntp. + Be consistent about how blocking children go away: + 1. Parent requests them to go by closing pipe or CHILD_EXIT_REQ. + 2. Child goes away quietly. + 3. Parent sees them gone via broken resp pipe or CHILD_GONE_RESP. + 4. Parent clears blocking_children entry for reuse. + Use pthreads for blocking worker rather than fork, if possible. + Use socketpair() instead of pipe() when available, as avoiding + EV_FEATURE_FDS allows libevent to use a faster backend on + systems like Linux without an O(1) backend that handles pipes. + + include/ntp_workimpl.h@1.2 +6 -1 + Move blocking worker and intres from ntpd to libntp. + Use pthreads for blocking worker rather than fork, if possible. + + include/ntpd.h@1.159 +4 -61 + Move blocking worker and intres from ntpd to libntp. + Rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + Move close_all_beyond() and close_all_except() to libntp. + + include/recvbuff.h@1.23 +1 -1 + include ntp_net.h for sockaddr_u declaration + + lib/isc/pthreads/mutex.c@1.2 +9 -0 + Work with very first draft posix M:N threads on HP-UX 10.20 + + lib/isc/unix/ifiter_ioctl.c@1.30 +2 -2 + lib/isc/unix/ifiter_ioctl.c:456: warning: cast increases required alignment of target type + lib/isc/unix/ifiter_ioctl.c:669: warning: cast increases required alignment of target type + + + lib/isc/unix/interfaceiter.c@1.20 +2 -2 + lib/isc/unix/interfaceiter.c:83: warning: cast increases required alignment of target type + lib/isc/unix/interfaceiter.c:87: warning: cast increases required alignment of target type + + libntp/Makefile.am@1.58.1.1 +43 -29 + Move blocking worker and intres from ntpd to libntp. + Enable pthreads build. + + libntp/a_md5encrypt.c@1.30 +1 -1 + Use sizeof() rather than hard-coding in addr2refid(). + + libntp/caljulian.c@1.14 +5 -4 + style only + + libntp/humandate.c@1.10 +2 -1 + whitespace + + libntp/lib_strbuf.c@1.8 +2 -0 + Make sure init_lib() is called before ssl_init() returns. + + libntp/machines.c@1.23 +14 -32 + use %m instead of strerror() + + libntp/msyslog.c@1.35 +281 -0 + Add more m*printf() varieties. + Move init_logging(), change_logfile(), and setup_logfile() from ntpd + to libntp. + strip .exe from program name in init_logging(). + Log new logfile name to syslog on switching, as we do when switching + from one logfile to another. + + libntp/ntp_intres.c@1.93 +322 -122 + Move blocking worker and intres from ntpd to libntp. + Rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + Use freeaddrinfo() in blocking_getaddrinfo(). + Use pthreads for blocking worker rather than fork, if possible. + + libntp/ntp_intres.c@1.92 +0 -0 + Rename: ntpd/ntp_intres.c -> libntp/ntp_intres.c + + libntp/ntp_libopts.c@1.4 +18 -12 + Quiet -Wcast-align warnings in ntpOptionProcess const-silliness workaround. + + libntp/ntp_lineedit.c@1.11 +1 -2 + use %m instead of strerror() + + libntp/ntp_random.c@1.8 +20 -7 + #ifdef away unused code that triggers alignment warnings. + + libntp/ntp_rfc2553.c@1.45 +40 -1 + Add copy_addrinfo() to copy a single addrinfo and pointed-to + constituents. + + libntp/ntp_worker.c@1.4 +221 -36 + Move blocking worker and intres from ntpd to libntp. + Rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + Quiet worker process startup/shutdown. + Be consistent about how blocking children go away: + 1. Parent requests them to go by closing pipe or CHILD_EXIT_REQ. + 2. Child goes away quietly. + 3. Parent sees them gone via broken resp pipe or CHILD_GONE_RESP. + 4. Parent clears blocking_children entry for reuse. + Use pthreads for blocking worker rather than fork, if possible. + Use socketpair() instead of pipe() when available, as avoiding + EV_FEATURE_FDS allows libevent to use a faster backend on + systems like Linux without an O(1) backend that handles pipes. + + libntp/ntp_worker.c@1.3 +0 -0 + Rename: ntpd/ntp_worker.c -> libntp/ntp_worker.c + + libntp/socket.c@1.5 +6 -8 + Change initial socket boundary message from DEBUG-only msyslog() to DPRINTF(). + + libntp/socktohost.c@1.13 +15 -2 + Quiet -Wcast-align warning due to casting sockaddr * to sockaddr_u * + + libntp/ssl_init.c@1.14 +17 -1 + Free OpenSSL dynamic allocations atexit. + Make sure init_lib() is called before ssl_init() returns. + + libntp/syssignal.c@1.12 +24 -9 + quiet "signal_no_reset: signal 18 had flags 20000" on OpenSolaris, + adding SA_NOCLDSTOP to IGNORED_SA_FLAGS. + Enable pthreads build. + + libntp/work_fork.c@1.7 +211 -148 + Move blocking worker and intres from ntpd to libntp. + Move init_logging(), change_logfile(), and setup_logfile() from ntpd + to libntp. + Do not complain of short read 0 of 24 on normal forked worker exit. + Be consistent about how blocking children go away: + 1. Parent requests them to go by closing pipe or CHILD_EXIT_REQ. + 2. Child goes away quietly. + 3. Parent sees them gone via broken resp pipe or CHILD_GONE_RESP. + 4. Parent clears blocking_children entry for reuse. + Use pthreads for blocking worker rather than fork, if possible. + Use socketpair() instead of pipe() when available, as avoiding + EV_FEATURE_FDS allows libevent to use a faster backend on + systems like Linux without an O(1) backend that handles pipes. + Change "forked worker child (pid 0)" from msyslog() to DPRINTF(). + + libntp/work_fork.c@1.6 +0 -0 + Rename: ntpd/work_fork.c -> libntp/work_fork.c + + libntp/work_thread.c@1.5 +479 -179 + Move blocking worker and intres from ntpd to libntp. + Be consistent about how blocking children go away: + 1. Parent requests them to go by closing pipe or CHILD_EXIT_REQ. + 2. Child goes away quietly. + 3. Parent sees them gone via broken resp pipe or CHILD_GONE_RESP. + 4. Parent clears blocking_children entry for reuse. + Use pthreads for blocking worker rather than fork, if possible. + Use socketpair() instead of pipe() when available, as avoiding + EV_FEATURE_FDS allows libevent to use a faster backend on + systems like Linux without an O(1) backend that handles pipes. + Work around cast discards volatile qualifier realloc'ing request and + response arrays. + + libntp/work_thread.c@1.4 +0 -0 + Rename: ntpd/work_thread.c -> libntp/work_thread.c + + libparse/Makefile.am@1.24 +1 -1 + Enable pthreads build. + + libparse/parsesolaris.c@1.10 +6 -5 + Silence cast increases required alignment warnings. + + ntpd/Makefile.am@1.99 +11 -12 + Move blocking worker and intres from ntpd to libntp. + Enable pthreads build. + + ntpd/cmd_args.c@1.59 +4 -1 + Make user and group string pointers distinct allocations. + + ntpd/ntp_config.c@1.284 +17 -20 + Use %m instead of strerror(). + Rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + Avoid "gai_error" shadowing warning using "gai_err" instead. + + ntpd/ntp_control.c@1.161.1.1 +8 -8 + Quiet ntp_control.c and ntp_request.c -Wcast-align warnings. + + ntpd/ntp_io.c@1.348 +54 -221 + Move blocking worker and intres from ntpd to libntp. + Move close_all_beyond() and close_all_except() to libntp. + Use pthreads for blocking worker rather than fork, if possible. + Avoid -Wcast-align warnings in routing message handling. + Use socketpair() instead of pipe() when available, as avoiding + EV_FEATURE_FDS allows libevent to use a faster backend on + systems like Linux without an O(1) backend that handles pipes. + + ntpd/ntp_request.c@1.103 +305 -358 + Quiet ntp_control.c and ntp_request.c -Wcast-align warnings. + struct interface -> endpt. + + ntpd/ntp_timer.c@1.63 +22 -9 + Move blocking worker and intres from ntpd to libntp. + Generalize intres_timeout_req(), provide ntpd and sntp implementations. + + ntpd/ntpd.c@1.121.1.1 +32 -226 + move init_logging(), change_logfile(), and setup_logfile() from ntpd + to libntp. + free(user) before replacement estrdup(). + Call INIT_SSL() early with other init_*() routines. + + ntpd/refclock_acts.c@1.45.1.1 +12 -13 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_arbiter.c@1.19 +7 -8 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_arc.c@1.24 +9 -10 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_as2201.c@1.13.1.1 +6 -7 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_atom.c@1.62 +3 -3 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_bancomm.c@1.14 +5 -6 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_chronolog.c@1.12 +7 -8 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_chu.c@1.51 +20 -21 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_datum.c@1.16 +32 -127 + Get rid of units array, follow common idioms. + + ntpd/refclock_dumbclock.c@1.18 +7 -8 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_fg.c@1.13 +5 -5 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_gpsvme.c@1.9 +2 -2 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_heath.c@1.17 +2 -2 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_hopfpci.c@1.12 +3 -4 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_hopfser.c@1.15 +7 -8 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_hpgps.c@1.13 +7 -8 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_irig.c@1.35 +13 -13 + valgrind warned of branch dependent on uninitialized value, + irig_decode()'s local syncdig. + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_jjy.c@1.22 +16 -16 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_jupiter.c@1.27 +28 -40 + Use %m instead of strerror(). + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_leitch.c@1.13 +2 -2 + silence increased alignment requirement from pointer cast. + + ntpd/refclock_msfees.c@1.15 +2 -2 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_mx4200.c@1.29 +18 -32 + Use %m instead of strerror(). + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_neoclock4x.c@1.20 +8 -8 + Use %m instead of strerror(). + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_nmea.c@1.59 +40 -28 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_oncore.c@1.92 +6 -6 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_palisade.c@1.38 +20 -17 + Use %m instead of strerror(). + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_parse.c@1.57 +9 -9 + silence cast increases required alignment warning. + + ntpd/refclock_pcf.c@1.12 +2 -2 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_pst.c@1.12 +7 -8 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_ripencc.c@1.16 +9 -10 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_shm.c@1.22 +9 -9 + Use %m instead of strerror(). + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_tpro.c@1.12 +5 -6 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_trak.c@1.11 +7 -8 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_true.c@1.17 +9 -10 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_ulink.c@1.16 +5 -5 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_wwv.c@1.74 +23 -27 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_wwvb.c@1.27 +9 -10 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpd/refclock_zyfer.c@1.8 +6 -6 + nonfunctional: + Use rbufp->recv_peer instead of casting rbufp->recv_srcclock. + pp->unitptr is now void *, no cast needed. + + ntpdate/Makefile.am@1.27 +4 -3 + Enable pthreads build. + + ntpdate/ntpdate.c@1.83 +19 -11 + Avoid alignment warnings from casting sockaddr * to sockaddr_u *. + + ntpdc/Makefile.am@1.57 +5 -4 + Enable pthreads build. + Make $(PROGRAMS) depend solely on version.o, whose dependencies should + take care of the rest. + + ntpdc/layout.std@1.11 +10 -2 + Adjust to less-trivial ntp_request.h. + + ntpdc/nl.pl.in@1.9 +8 -2 + Adjust to less-trivial ntp_request.h. + + ntpdc/ntpdc.c@1.94 +33 -40 + Quiet -Wcast-align warnings. + JAN_1970 definition now provided by ntp_unixtime.h + + ntpdc/ntpdc_ops.c@1.76 +55 -52 + Avoid increased required alignment warnings casting pointers. + + ntpq/Makefile.am@1.53 +5 -5 + Enable pthreads build. + Make $(PROGRAMS) depend on version.o alone, its dependencies should + handle the rest. + + ntpq/ntpq.c@1.130.1.1 +35 -26 + Use %m instead of strerror(). + Use freeaddrinfo() in ntpq's getnetnum(). + Quiet -Wcast-align warnings. + + ntpsnmpd/Makefile.am@1.25 +5 -4 + Enable pthreads build. + + parseutil/Makefile.am@1.14 +5 -3 + Enable pthreads build. + pick up -lresolv, needed by dcfd, via LDADD_LIBNTP. + + ports/winnt/include/ntp_iocompletionport.h@1.19 +3 -3 + Move blocking worker and intres from ntpd to libntp. + Get rid of accessor for WaitableExitEventHandle. + + ports/winnt/include/ntp_timer.h@1.7 +0 -4 + Move blocking worker and intres from ntpd to libntp. + + ports/winnt/libntp/win32_io.c@1.2 +3 -2 + Use %m instead of strerror(). + + ports/winnt/ntpd/ntp_iocompletionport.c@1.57 +92 -53 + Move blocking worker and intres from ntpd to libntp. + Get rid of accessor for WaitableExitEventHandle. + Use pthreads for blocking worker rather than fork, if possible. + + ports/winnt/ntpd/ntservice.c@1.27 +11 -13 + Get rid of accessor for WaitableExitEventHandle. + + ports/winnt/vc6/libntp.dsp@1.59.1.1 +24 -0 + Move blocking worker and intres from ntpd to libntp. + rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + + ports/winnt/vc6/ntpd.dsp@1.53 +0 -20 + Move blocking worker and intres from ntpd to libntp. + + ports/winnt/vs2003/libntp.vcproj@1.17.1.1 +18 -90 + Move blocking worker and intres from ntpd to libntp. + rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + + ports/winnt/vs2003/ntpd.vcproj@1.14 +0 -32 + Move blocking worker and intres from ntpd to libntp. + + ports/winnt/vs2005/libntp.vcproj@1.15.1.1 +24 -1404 + Move blocking worker and intres from ntpd to libntp. + rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + + ports/winnt/vs2005/ntpd.vcproj@1.14 +0 -34 + Move blocking worker and intres from ntpd to libntp. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.36.1.1 +30 -2 + Move blocking worker and intres from ntpd to libntp. + Rename former ntp_intres.h to intreswork.h, move intres public + interface declarations from ntpd.h to new ntp_intres.h. + Add lib/isc/win32/include/isc/mutex.h reference. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.38 +4 -1031 + Move blocking worker and intres from ntpd to libntp. + Add refclock_wwv.c reference. + + sntp/Makefile.am@1.53 +50 -16 + Enable pthreads build. + Link against the smaller libevent_core.la which suits us since sntp + no longer uses evdns. + Use NTP_LIBEVENT m4sh macro to decide between installed and tearoff + libevent. + + sntp/configure.ac@1.57 +12 -96 + Split up ntp_lib.m4 into smaller, more specific subsets + Remove duplicate clock_gettime/clock_settime logic now in ntp_libntp.m4. + Bump config.cache version stamps to account for cache-incompatible change + to librt detection. + Use NTP_LIBEVENT m4sh macro to decide between installed and tearoff + libevent. + Move more m4 code needed by libntp to sntp/m4/*.m4 from top-level configure.ac + + sntp/deps-ver@1.3 +1 -1 + bump deps-ver to avoid build breaks from moved source files. + + sntp/kod_management.c@1.26 +29 -15 + Do not write_kod_db() work atexit in forked children. + Move "can't write KoD file" warning from sntp shutdown to startup. + Use pthreads for blocking worker rather than fork, if possible. + Add readonly arg to kod_init_kod_db() for tests + + sntp/kod_management.h@1.10 +3 -2 + Move "can't write KoD file" warning from sntp shutdown to startup. + Add readonly arg to kod_init_kod_db() for tests. + + sntp/libevent/Makefile.am@1.2 +14 -6 + make -lz depend on zlib.h + We always need the PTHREADS AM_CONDITIONAL. Use the OL check. + + sntp/libevent/WIN32-Code/event2/event-config.h@1.2 +2 -2 + libevent upgrade + + sntp/libevent/arc4random.c@1.2 +5 -1 + update from upstream + + sntp/libevent/configure.in@1.2 +137 -33 + Attempt typical subpackage approach for libevent + IPv6 hackery + Update from upstream. + make -lz depend on zlib.h + Allow libevent's regress to be skipped in make check. + Detect gcc (ld) support for --gc-sections and use it if available along + with --fdata-sections and -ffunction-sections to omit unused code and + data. + Add openldap thread check, remove ACX_PTHREAD + upstream patch to quiet autoreconf warnings + http://levent.git.sourceforge.net/git/gitweb.cgi?p=levent/libevent;a=commit;h=f663112fa238a3f5a1bdfddfd26c17e625e182df + We always need the PTHREADS AM_CONDITIONAL. Use the OL check. + + sntp/libevent/evdns.c@1.2 +4 -0 + libevent upgrade + + sntp/libevent/evport.c@1.2 +6 -0 + libevent upgrade + + sntp/libevent/evthread_pthread.c@1.2 +13 -1 + Work with very first draft posix M:N threads on HP-UX 10.20 + + sntp/libevent/evutil.c@1.2 +44 -3 + IPv6 hackery. + libevent upgrade. + + sntp/libevent/http.c@1.2 +47 -6 + libevent upgrade. + + sntp/libevent/ipv6-internal.h@1.2 +9 -0 + libevent upgrade + + sntp/libevent/m4/LICENSE-OPENLDAP@1.1 +47 -0 + BitKeeper file /home/stenn/ntp-dev-libevent-subpkg/sntp/m4/LICENSE-OPENLDAP + + sntp/libevent/m4/LICENSE-OPENLDAP@1.0 +0 -0 + + sntp/libevent/m4/openldap-thread-check.m4@1.1 +681 -0 + AC_LANG update for openldap autoconf macros + Clean up AC_DEFINE and AC_DEFINE_UNQUOTED arg quoting. + preset ol_with_yielding_select=${ol_with_yielding_select-auto} + Also change tests to use x prefix as insurance against other issues. + Move PTHREAD_LIBS AC_SUBST to ntp_libntp.m4 + + sntp/libevent/m4/openldap-thread-check.m4@1.0 +0 -0 + + sntp/libevent/m4/openldap.m4@1.1 +1131 -0 + AC_LANG_SOURCE: unknown language: _AC_LANG on 588 + Clean up AC_DEFINE and AC_DEFINE_UNQUOTED arg quoting. + + sntp/libevent/m4/openldap.m4@1.0 +0 -0 + + sntp/libevent/sample/Makefile.am@1.2 +1 -1 + Detect gcc (ld) support for --gc-sections and use it if available along + with --fdata-sections and -ffunction-sections to omit unused code and + data. + + sntp/libevent/sample/dns-example.c@1.2 +2 -0 + libevent upgrade + + sntp/libevent/sample/hello-world.c@1.2 +3 -0 + hp-ux portability fix. + + sntp/libevent/sample/http-server.c@1.2 +7 -0 + libevent upgrade + portability + + sntp/libevent/select.c@1.2 +27 -9 + libevent upgrade + + sntp/libevent/test/Makefile.am@1.2 +13 -8 + Allow libevent's regress to be skipped in make check. + Detect gcc (ld) support for --gc-sections and use it if available along + with --fdata-sections and -ffunction-sections to omit unused code and + data. + + sntp/libevent/test/bench_httpclient.c@1.2 +3 -0 + portability + + sntp/libevent/test/regress_dns.c@1.2 +2 -0 + cleanup + + sntp/libevent/test/regress_http.c@1.2 +5 -21 + libevent upgrade + + sntp/libevent/test/regress_listener.c@1.2 +3 -0 + cleanup + + sntp/libevent/test/regress_testutils.c@1.2 +2 -0 + libevent upgrade + + + sntp/libevent/test/test-eof.c@1.2 +9 -3 + Add a timeout for test-eof.c as it may hang under HP-UX 10.20. + + + sntp/libevent/test/test-ratelim.c@1.2 +5 -0 + cleanup + + sntp/libevent/test/test.sh@1.2 +10 -4 + Allow libevent's regress to be skipped in make check. + + sntp/libevent/util-internal.h@1.2 +23 -2 + update + --- + libevent upgrade + + sntp/log.c@1.20 +6 -10 + Rename init_logging() to sntp_init_logging() to avoid libntp conflict. + Use msyslog common code relocated from ntpd. + + sntp/log.h@1.11 +3 -1 + Rename init_logging() to sntp_init_logging() to avoid libntp conflict. + Use msyslog common code relocated from ntpd. + Declare extern char *progname. + + sntp/m4/ntp_bindir.m4@1.1 +31 -0 + Split up ntp_lib.m4 into smaller, more specific subsets. + + sntp/m4/ntp_bindir.m4@1.0 +0 -0 + + sntp/m4/ntp_cacheversion.m4@1.12 +11 -9 + Attempt to make better use of header comment space. + + sntp/m4/ntp_compiler.m4@1.1 +124 -0 + Split up ntp_lib.m4 into smaller, more specific subsets. + Omit unused code with gcc and gnu LD of recent vintage. + Ask autoconf for c89 only, AC_PROG_CC_STDC now means c99. + + sntp/m4/ntp_compiler.m4@1.0 +0 -0 + + sntp/m4/ntp_crosscompile.m4@1.1 +8 -0 + Split up ntp_lib.m4 into smaller, more specific subsets. + + sntp/m4/ntp_crosscompile.m4@1.0 +0 -0 + + sntp/m4/ntp_debug.m4@1.1 +22 -0 + Split up ntp_lib.m4 into smaller, more specific subsets. + + sntp/m4/ntp_debug.m4@1.0 +0 -0 + + sntp/m4/ntp_ipv6.m4@1.2 +127 -112 + Strip unneeded checks from ntp_ipv6.m4: + for struct sockaddr_storage member ss_family + for struct sockaddr_storage member ss_len + for struct sockaddr_storage member __ss_len + Move things used by libntp from top-level configure.ac to NTP_IPV6 + + sntp/m4/ntp_libevent.m4@1.3 +82 -35 + Use NTP_LIBEVENT m4sh macro to decide between installed and tearoff + libevent. + Remove contentious libevent-cfg sentinel files, modify libevent's + confgure args via $ac_configure_args. + + sntp/m4/ntp_libntp.m4@1.4 +753 -156 + Split up ntp_lib.m4 into smaller, more specific subsets. + Move AC_FUNC_FORK and AC_FUNC_ALLOCA to ntp_libntp.m4 along with move + of intres/blocking worker to libntp. + Move droproot configure test to libntp with intres. + Enable pthreads build. + crib some pthread m4 from BIND for libisc + move clock_gettime/clock_settime earlier within NTP_LIBNTP + check for socketpair() + Move more m4 code needed by libntp to sntp/m4/*.m4 from top-level configure.ac + + sntp/m4/ntp_sntp.m4@1.1 +29 -0 + Split up ntp_lib.m4 into smaller, more specific subsets. + + sntp/m4/ntp_sntp.m4@1.0 +0 -0 + + sntp/main.c@1.68 +820 -313 + Use {step,adj}_systime from libntp. Use EX_* codes for exit status. + Switch sntp from evdns to blocking worker intres. + Make delay between queries to addresses resolved from same hostname + per-family in sntp, as ntpd won't consider our v4 and v6 source + addresses to be one remote rate-limit target. + use ntpOptionProcess() to get verbose --version output. + Use libevent log callback to redirect messages from stderr to msyslog() + enable libevent debug mode if sntp debug > 0 + Issue a single read event for each socket, rather than one per query. + Do not attempt to read in socket callback for EV_TIMEOUT. + Be conservative in KoD response claim + Fix step/slew logic in sntp + sntp --headroom option (default 10ms) spaces queries. + Provide less-broken gettimeofday_cached() + Add support for --(no-)wait and -uctimeout + remove duplicate progname declaration (log.c has it). + add readonly arg to kod_init_kod_db() for tests + Use socketpair() instead of pipe() when available, as avoiding + EV_FEATURE_FDS allows libevent to use a faster backend on + systems like Linux without an O(1) backend that handles pipes. + + sntp/main.h@1.6 +18 -16 + Switch sntp from evdns to blocking worker intres. + More -Wcast-align warnings workarounds. + + sntp/networking.c@1.57 +36 -51 + Authentication and debug cleanup. + remove recvpkt(), its two parts now done separately in sock_cb() + Quiet -Wcast-align warnings. + + sntp/networking.h@1.25 +7 -8 + Quiet -Wcast-align warnings. + + sntp/sntp-opts.c@1.124 +499 -145 + generated file updates from sntp def file changes + + sntp/sntp-opts.def@1.25 +51 -11 + generated file updates from sntp def file changes + + sntp/sntp-opts.h@1.124 +135 -68 + generated file updates from sntp def file changes + + sntp/sntp-opts.texi@1.124 +168 -88 + generated file updates from sntp def file changes + + sntp/sntp.1@1.124 +135 -60 + generated file updates from sntp def file changes + + sntp/sntp.html@1.124 +95 -30 + generated file updates from sntp def file changes + + sntp/tests/Makefile.am@1.20 +54 -45 + Enable pthreads build. + Link against the smaller libevent_core.la which suits us since sntp + no longer uses evdns. + Use NTP_LIBEVENT m4sh macro to decide between installed and tearoff + libevent. + Pick up -lresolv from @LDADD_LIBNTP@, + + sntp/tests/kodDatabase.cpp@1.3 +1 -1 + Add readonly arg to kod_init_kod_db() for tests. + + sntp/tests/kodFile.cpp@1.8 +3 -11 + Add readonly arg to kod_init_kod_db() for tests -- prevents editing + test baseline input KoD files during make check. + + sntp/tests/nameresolution.cpp@1.1 +171 -0 + Move name resolution unit test code to nameresolution.cpp. + + sntp/tests/nameresolution.cpp@1.0 +0 -0 + + sntp/tests/networking.cpp@1.8 +0 -166 + Move name resolution unit test code to nameresolution.cpp. + + sntp/tests/packetHandling.cpp@1.7 +58 -46 + Change handle_pkt() args to include hostname. + Add readonly arg to kod_init_kod_db() for tests. + + sntp/utilities.c@1.16 +5 -5 + const-ify addrinfo_to_str() + + sntp/utilities.h@1.10 +1 -1 + const-ify addrinfo_to_str() + + tests/libntp/Makefile.am@1.30.1.1 +8 -6 + Enable pthreads build. + + tests/libntp/clocktime.cpp@1.4 +19 -7 + Reduce runtime of AlwaysInLimit by an order of magnitude. + + util/Makefile.am@1.56 +9 -7 + Enable pthreads build. + correct cut-n-paste reference to ntpq_OBJECTS, make $(PROGRAMS) depend + on version.o. + + util/ntp-keygen.c@1.77 +0 -1 + JAN_1970 definition provided by ntp_unixtime.h now + +ChangeSet@1.2422.1.61, 2011-02-19 03:29:55+00:00, davehart@shiny.ad.hartbrothers.com + Add INC_ALIGNED_PTR() macro to align pointers like malloc(). + + ChangeLog@1.784.1.21 +1 -0 + Add INC_ALIGNED_PTR() macro to align pointers like malloc(). + + include/ntp_types.h@1.23 +26 -0 + Add INC_ALIGNED_PTR() macro to align pointers like malloc(). + + ntpd/ntp_crypto.c@1.154 +16 -9 + strdup() -> estrdup() + + ntpd/ntp_proto.c@1.319 +11 -10 + Add INC_ALIGNED_PTR() macro to align pointers like malloc(). + + ntpd/refclock_as2201.c@1.14 +2 -2 + Use memcpy() after bounds check instead of strcpy(). + Correct a different bounds check that was off by one. + + sntp/tests_main.h@1.7 +3 -2 + #include config.h before all others, system before lib/app. + +ChangeSet@1.2422.1.60, 2011-02-12 11:07:51+00:00, stenn@deacon.udel.edu + NTP_4_2_7P130 + TAG: NTP_4_2_7P130 + + ChangeLog@1.784.1.20 +1 -0 + NTP_4_2_7P130 + + clockstuff/clktest-opts.c@1.54 +2 -2 + NTP_4_2_7P130 + + clockstuff/clktest-opts.h@1.54 +3 -3 + NTP_4_2_7P130 + + ntpd/ntpd-opts.c@1.134 +2 -2 + NTP_4_2_7P130 + + ntpd/ntpd-opts.h@1.134 +3 -3 + NTP_4_2_7P130 + + ntpd/ntpd-opts.texi@1.132 +2 -2 + NTP_4_2_7P130 + + ntpd/ntpd.1@1.132 +2 -2 + NTP_4_2_7P130 + + ntpdc/ntpdc-opts.c@1.131 +2 -2 + NTP_4_2_7P130 + + ntpdc/ntpdc-opts.h@1.131 +3 -3 + NTP_4_2_7P130 + + ntpdc/ntpdc-opts.texi@1.131 +2 -2 + NTP_4_2_7P130 + + ntpdc/ntpdc.1@1.131 +2 -2 + NTP_4_2_7P130 + + ntpq/ntpq-opts.c@1.131 +2 -2 + NTP_4_2_7P130 + + ntpq/ntpq-opts.h@1.131 +3 -3 + NTP_4_2_7P130 + + ntpq/ntpq-opts.texi@1.131 +2 -2 + NTP_4_2_7P130 + + ntpq/ntpq.1@1.131 +2 -2 + NTP_4_2_7P130 + + ntpsnmpd/ntpsnmpd-opts.c@1.131 +2 -2 + NTP_4_2_7P130 + + ntpsnmpd/ntpsnmpd-opts.h@1.131 +3 -3 + NTP_4_2_7P130 + + ntpsnmpd/ntpsnmpd-opts.texi@1.131 +2 -2 + NTP_4_2_7P130 + + ntpsnmpd/ntpsnmpd.1@1.131 +2 -2 + NTP_4_2_7P130 + + packageinfo.sh@1.132 +1 -1 + NTP_4_2_7P130 + + sntp/sntp-opts.c@1.115.1.16 +2 -2 + NTP_4_2_7P130 + + sntp/sntp-opts.h@1.115.1.16 +3 -3 + NTP_4_2_7P130 + + sntp/sntp-opts.texi@1.115.1.16 +2 -2 + NTP_4_2_7P130 + + sntp/sntp.1@1.115.1.16 +2 -2 + NTP_4_2_7P130 + + sntp/sntp.html@1.115.1.16 +1 -1 + NTP_4_2_7P130 + + util/ntp-keygen-opts.c@1.129 +2 -2 + NTP_4_2_7P130 + + util/ntp-keygen-opts.h@1.129 +3 -3 + NTP_4_2_7P130 + + util/ntp-keygen-opts.texi@1.132 +2 -2 + NTP_4_2_7P130 + + util/ntp-keygen.1@1.132 +2 -2 + NTP_4_2_7P130 + +ChangeSet@1.2422.1.59, 2011-02-11 07:26:12-05:00, stenn@deacon.udel.edu + [Bug 1811] Update the download location in WHERE-TO-START + + ChangeLog@1.784.1.19 +1 -0 + [Bug 1811] Update the download location in WHERE-TO-START + + WHERE-TO-START@1.9 +2 -1 + [Bug 1811] Update the download location in WHERE-TO-START + +ChangeSet@1.2422.1.58, 2011-02-09 08:55:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P129 + TAG: NTP_4_2_7P129 + + ChangeLog@1.784.1.18 +1 -0 + NTP_4_2_7P129 + + clockstuff/clktest-opts.c@1.53 +2 -2 + NTP_4_2_7P129 + + clockstuff/clktest-opts.h@1.53 +3 -3 + NTP_4_2_7P129 + + ntpd/ntpd-opts.c@1.133 +2 -2 + NTP_4_2_7P129 + + ntpd/ntpd-opts.h@1.133 +3 -3 + NTP_4_2_7P129 + + ntpd/ntpd-opts.texi@1.131 +2 -2 + NTP_4_2_7P129 + + ntpd/ntpd.1@1.131 +2 -2 + NTP_4_2_7P129 + + ntpdc/ntpdc-opts.c@1.130 +2 -2 + NTP_4_2_7P129 + + ntpdc/ntpdc-opts.h@1.130 +3 -3 + NTP_4_2_7P129 + + ntpdc/ntpdc-opts.texi@1.130 +2 -2 + NTP_4_2_7P129 + + ntpdc/ntpdc.1@1.130 +2 -2 + NTP_4_2_7P129 + + ntpq/ntpq-opts.c@1.130 +2 -2 + NTP_4_2_7P129 + + ntpq/ntpq-opts.h@1.130 +3 -3 + NTP_4_2_7P129 + + ntpq/ntpq-opts.texi@1.130 +2 -2 + NTP_4_2_7P129 + + ntpq/ntpq.1@1.130 +2 -2 + NTP_4_2_7P129 + + ntpsnmpd/ntpsnmpd-opts.c@1.130 +2 -2 + NTP_4_2_7P129 + + ntpsnmpd/ntpsnmpd-opts.h@1.130 +3 -3 + NTP_4_2_7P129 + + ntpsnmpd/ntpsnmpd-opts.texi@1.130 +2 -2 + NTP_4_2_7P129 + + ntpsnmpd/ntpsnmpd.1@1.130 +2 -2 + NTP_4_2_7P129 + + packageinfo.sh@1.131 +1 -1 + NTP_4_2_7P129 + + sntp/sntp-opts.c@1.115.1.15 +2 -2 + NTP_4_2_7P129 + + sntp/sntp-opts.h@1.115.1.15 +3 -3 + NTP_4_2_7P129 + + sntp/sntp-opts.texi@1.115.1.15 +2 -2 + NTP_4_2_7P129 + + sntp/sntp.1@1.115.1.15 +2 -2 + NTP_4_2_7P129 + + sntp/sntp.html@1.115.1.15 +1 -1 + NTP_4_2_7P129 + + util/ntp-keygen-opts.c@1.128 +2 -2 + NTP_4_2_7P129 + + util/ntp-keygen-opts.h@1.128 +3 -3 + NTP_4_2_7P129 + + util/ntp-keygen-opts.texi@1.131 +2 -2 + NTP_4_2_7P129 + + util/ntp-keygen.1@1.131 +2 -2 + NTP_4_2_7P129 + +ChangeSet@1.2422.1.57, 2011-02-09 07:14:49+00:00, davehart@shiny.ad.hartbrothers.com + Add missing "break;" to ntp_control.c ctl_putsys() for caliberrs, used + by ntpq -c kerninfo introduced in 4.2.7p104. + Fix leak in ntp_control.c read_mru_list(). + + ChangeLog@1.784.1.17 +3 -0 + Add missing "break;" to ntp_control.c ctl_putsys() for caliberrs, used + by ntpq -c kerninfo introduced in 4.2.7p104. + Fix leak in ntp_control.c read_mru_list(). + + include/ntp_assert.h@1.5 +7 -1 + Attempt allowing Coverity to analyze our actual assertion paths. + + include/ntp_lists.h@1.9 +4 -19 + Correct bug in LINK_SORT_SLIST() with an empty list. + + ntpd/ntp_control.c@1.162 +5 -2 + Fix leak in ntp_control.c read_mru_list(). + Add missing "break;" to ntp_control.c ctl_putsys() for caliberrs, used + by ntpq -c kerninfo introduced in 4.2.7p104. + + + ntpd/ntp_io.c@1.346.1.1 +5 -0 + Do not attempt setsockopt() for unopened -1 descriptors. + + ntpd/ntp_monitor.c@1.38 +4 -2 + Add debug-only assertion of non-NULL argument to mon_reclaim_entry(). + +ChangeSet@1.2422.1.56, 2011-01-30 11:40:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P128 + TAG: NTP_4_2_7P128 + + ChangeLog@1.784.1.16 +1 -0 + NTP_4_2_7P128 + + clockstuff/clktest-opts.c@1.52 +2 -2 + NTP_4_2_7P128 + + clockstuff/clktest-opts.h@1.52 +3 -3 + NTP_4_2_7P128 + + ntpd/ntpd-opts.c@1.132 +2 -2 + NTP_4_2_7P128 + + ntpd/ntpd-opts.h@1.132 +3 -3 + NTP_4_2_7P128 + + ntpd/ntpd-opts.texi@1.130 +2 -2 + NTP_4_2_7P128 + + ntpd/ntpd.1@1.130 +2 -2 + NTP_4_2_7P128 + + ntpdc/ntpdc-opts.c@1.129 +2 -2 + NTP_4_2_7P128 + + ntpdc/ntpdc-opts.h@1.129 +3 -3 + NTP_4_2_7P128 + + ntpdc/ntpdc-opts.texi@1.129 +2 -2 + NTP_4_2_7P128 + + ntpdc/ntpdc.1@1.129 +2 -2 + NTP_4_2_7P128 + + ntpq/ntpq-opts.c@1.129 +2 -2 + NTP_4_2_7P128 + + ntpq/ntpq-opts.h@1.129 +3 -3 + NTP_4_2_7P128 + + ntpq/ntpq-opts.texi@1.129 +2 -2 + NTP_4_2_7P128 + + ntpq/ntpq.1@1.129 +2 -2 + NTP_4_2_7P128 + + ntpsnmpd/ntpsnmpd-opts.c@1.129 +2 -2 + NTP_4_2_7P128 + + ntpsnmpd/ntpsnmpd-opts.h@1.129 +3 -3 + NTP_4_2_7P128 + + ntpsnmpd/ntpsnmpd-opts.texi@1.129 +2 -2 + NTP_4_2_7P128 + + ntpsnmpd/ntpsnmpd.1@1.129 +2 -2 + NTP_4_2_7P128 + + packageinfo.sh@1.130 +1 -1 + NTP_4_2_7P128 + + sntp/sntp-opts.c@1.115.1.14 +2 -2 + NTP_4_2_7P128 + + sntp/sntp-opts.h@1.115.1.14 +3 -3 + NTP_4_2_7P128 + + sntp/sntp-opts.texi@1.115.1.14 +2 -2 + NTP_4_2_7P128 + + sntp/sntp.1@1.115.1.14 +2 -2 + NTP_4_2_7P128 + + sntp/sntp.html@1.115.1.14 +1 -1 + NTP_4_2_7P128 + + util/ntp-keygen-opts.c@1.127 +2 -2 + NTP_4_2_7P128 + + util/ntp-keygen-opts.h@1.127 +3 -3 + NTP_4_2_7P128 + + util/ntp-keygen-opts.texi@1.130 +2 -2 + NTP_4_2_7P128 + + util/ntp-keygen.1@1.130 +2 -2 + NTP_4_2_7P128 + +ChangeSet@1.2422.1.55, 2011-01-29 23:06:16+00:00, davehart@shiny.ad.hartbrothers.com + * [Bug 1799] ntpq mrv crash. + * [Bug 1801] ntpq mreadvar requires prior association caching. + + ChangeLog@1.784.1.15 +3 -1 + * [Bug 1799] ntpq mrv crash. + * [Bug 1801] ntpq mreadvar requires prior association caching. + Correct p126 ChangeLog entry to refer to format_time_fraction(). + + ntpq/ntpq-subs.c@1.84 +26 -19 + * [Bug 1799] ntpq mrv crash. + * [Bug 1801] ntpq mreadvar requires prior association caching. + +ChangeSet@1.2422.1.54, 2011-01-28 06:31:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P127 + TAG: NTP_4_2_7P127 + + ChangeLog@1.784.1.14 +1 -0 + NTP_4_2_7P127 + + clockstuff/clktest-opts.c@1.51 +2 -2 + NTP_4_2_7P127 + + clockstuff/clktest-opts.h@1.51 +3 -3 + NTP_4_2_7P127 + + ntpd/ntpd-opts.c@1.131 +2 -2 + NTP_4_2_7P127 + + ntpd/ntpd-opts.h@1.131 +3 -3 + NTP_4_2_7P127 + + ntpd/ntpd-opts.texi@1.129 +2 -2 + NTP_4_2_7P127 + + ntpd/ntpd.1@1.129 +2 -2 + NTP_4_2_7P127 + + ntpdc/ntpdc-opts.c@1.128 +2 -2 + NTP_4_2_7P127 + + ntpdc/ntpdc-opts.h@1.128 +3 -3 + NTP_4_2_7P127 + + ntpdc/ntpdc-opts.texi@1.128 +2 -2 + NTP_4_2_7P127 + + ntpdc/ntpdc.1@1.128 +2 -2 + NTP_4_2_7P127 + + ntpq/ntpq-opts.c@1.128 +2 -2 + NTP_4_2_7P127 + + ntpq/ntpq-opts.h@1.128 +3 -3 + NTP_4_2_7P127 + + ntpq/ntpq-opts.texi@1.128 +2 -2 + NTP_4_2_7P127 + + ntpq/ntpq.1@1.128 +2 -2 + NTP_4_2_7P127 + + ntpsnmpd/ntpsnmpd-opts.c@1.128 +2 -2 + NTP_4_2_7P127 + + ntpsnmpd/ntpsnmpd-opts.h@1.128 +3 -3 + NTP_4_2_7P127 + + ntpsnmpd/ntpsnmpd-opts.texi@1.128 +2 -2 + NTP_4_2_7P127 + + ntpsnmpd/ntpsnmpd.1@1.128 +2 -2 + NTP_4_2_7P127 + + packageinfo.sh@1.129 +1 -1 + NTP_4_2_7P127 + + sntp/sntp-opts.c@1.115.1.13 +2 -2 + NTP_4_2_7P127 + + sntp/sntp-opts.h@1.115.1.13 +3 -3 + NTP_4_2_7P127 + + sntp/sntp-opts.texi@1.115.1.13 +2 -2 + NTP_4_2_7P127 + + sntp/sntp.1@1.115.1.13 +2 -2 + NTP_4_2_7P127 + + sntp/sntp.html@1.115.1.13 +1 -1 + NTP_4_2_7P127 + + util/ntp-keygen-opts.c@1.126 +2 -2 + NTP_4_2_7P127 + + util/ntp-keygen-opts.h@1.126 +3 -3 + NTP_4_2_7P127 + + util/ntp-keygen-opts.texi@1.129 +2 -2 + NTP_4_2_7P127 + + util/ntp-keygen.1@1.129 +2 -2 + NTP_4_2_7P127 + +ChangeSet@1.2422.1.53, 2011-01-28 01:07:13-05:00, stenn@deacon.udel.edu + [Bug 1797] Restore stale timestamp check from the RANGEGATE cleanup + + ChangeLog@1.784.1.13 +1 -0 + [Bug 1797] Restore stale timestamp check from the RANGEGATE cleanup + + ntpd/ntp_refclock.c@1.103 +3 -0 + [Bug 1797] Restore stale timestamp check from the RANGEGATE cleanup + +ChangeSet@1.2422.1.52, 2011-01-27 10:28:37+00:00, stenn@deacon.udel.edu + NTP_4_2_7P126 + TAG: NTP_4_2_7P126 + + ChangeLog@1.784.1.12 +1 -0 + NTP_4_2_7P126 + + clockstuff/clktest-opts.c@1.50 +2 -2 + NTP_4_2_7P126 + + clockstuff/clktest-opts.h@1.50 +3 -3 + NTP_4_2_7P126 + + ntpd/ntpd-opts.c@1.130 +2 -2 + NTP_4_2_7P126 + + ntpd/ntpd-opts.h@1.130 +3 -3 + NTP_4_2_7P126 + + ntpd/ntpd-opts.texi@1.128 +2 -2 + NTP_4_2_7P126 + + ntpd/ntpd.1@1.128 +2 -2 + NTP_4_2_7P126 + + ntpdc/ntpdc-opts.c@1.127 +2 -2 + NTP_4_2_7P126 + + ntpdc/ntpdc-opts.h@1.127 +3 -3 + NTP_4_2_7P126 + + ntpdc/ntpdc-opts.texi@1.127 +2 -2 + NTP_4_2_7P126 + + ntpdc/ntpdc.1@1.127 +2 -2 + NTP_4_2_7P126 + + ntpq/ntpq-opts.c@1.127 +2 -2 + NTP_4_2_7P126 + + ntpq/ntpq-opts.h@1.127 +3 -3 + NTP_4_2_7P126 + + ntpq/ntpq-opts.texi@1.127 +2 -2 + NTP_4_2_7P126 + + ntpq/ntpq.1@1.127 +2 -2 + NTP_4_2_7P126 + + ntpsnmpd/ntpsnmpd-opts.c@1.127 +2 -2 + NTP_4_2_7P126 + + ntpsnmpd/ntpsnmpd-opts.h@1.127 +3 -3 + NTP_4_2_7P126 + + ntpsnmpd/ntpsnmpd-opts.texi@1.127 +2 -2 + NTP_4_2_7P126 + + ntpsnmpd/ntpsnmpd.1@1.127 +2 -2 + NTP_4_2_7P126 + + packageinfo.sh@1.128 +1 -1 + NTP_4_2_7P126 + + sntp/sntp-opts.c@1.115.1.12 +2 -2 + NTP_4_2_7P126 + + sntp/sntp-opts.h@1.115.1.12 +3 -3 + NTP_4_2_7P126 + + sntp/sntp-opts.texi@1.115.1.12 +2 -2 + NTP_4_2_7P126 + + sntp/sntp.1@1.115.1.12 +2 -2 + NTP_4_2_7P126 + + sntp/sntp.html@1.115.1.12 +1 -1 + NTP_4_2_7P126 + + util/ntp-keygen-opts.c@1.125 +2 -2 + NTP_4_2_7P126 + + util/ntp-keygen-opts.h@1.125 +3 -3 + NTP_4_2_7P126 + + util/ntp-keygen-opts.texi@1.128 +2 -2 + NTP_4_2_7P126 + + util/ntp-keygen.1@1.128 +2 -2 + NTP_4_2_7P126 + +ChangeSet@1.2422.1.51, 2011-01-27 01:38:59-05:00, stenn@deacon.udel.edu + Add entries for updates from Dave Hart + + ChangeLog@1.784.1.11 +2 -0 + Add entries for updates from Dave Hart + +ChangeSet@1.2422.9.3, 2011-01-26 19:39:27+00:00, davehart@shiny.ad.hartbrothers.com + silence signed overflow warning + mark isc_assertioncallback_t __attribute((__noreturn__)) + + include/ntp_stdlib.h@1.58 +9 -6 + add __attribute((__noreturn__)) to __attribute__ compat header snippet. + + lib/isc/assertions.c@1.5 +2 -1 + mark default_callback() __attribute__ ((__noreturn__)) + + lib/isc/include/isc/assertions.h@1.5 +21 -1 + Mark isc_assertioncallback_t __attribute((__noreturn__)) + + libntp/timetoa.c@1.4 +18 -16 + silence warning from recent gcc: + libntp/timetoa.c:53:1: warning: assuming signed overflow does not occur when simplifying conditional to constant + + ntpd/ntpd.c@1.122 +2 -1 + mark assertion_failed() __attribute__ ((__noreturn__)) + +ChangeSet@1.2422.9.2, 2011-01-26 17:03:48+00:00, davehart@shiny.ad.hartbrothers.com + Rename tests/libntp/t{val|spec}ops.cpp to time{val|spec}ops.cpp so + base filename matches tested source file, as with others. + + tests/libntp/Makefile.am@1.33 +2 -2 + Rename tests/libntp/t{val|spec}ops.cpp to time{val|spec}ops.cpp so + base filename matches tested source file, as with others. + + tests/libntp/timespecops.cpp@1.6 +0 -0 + Rename: tests/libntp/tspecops.cpp -> tests/libntp/timespecops.cpp + + tests/libntp/timevalops.cpp@1.6 +0 -0 + Rename: tests/libntp/tvalops.cpp -> tests/libntp/timevalops.cpp + +ChangeSet@1.2422.9.1, 2011-01-26 16:50:03+00:00, davehart@shiny.ad.hartbrothers.com + Fix off-by-one bug in format_time_fraction() introduced by hart@ntp.org. + Remove abs(prec) <= 9 requirement from format_time_fraction(). + Add more time{spec|val}_tostr() tests. + + include/timetoa.h@1.3 +3 -5 + remove abs(prec) <= 9 limitation from format_time_fraction() + + libntp/timetoa.c@1.3 +18 -26 + remove abs(prec) <= 9 limitation from format_time_fraction(). + calculate fraclimit from prec rather than use powers of ten lookup table. + fixes off-by-one bug introduced by hart@ntp.org (COUNTOF(limit) should have + been COUNTOF(limit) - 1). + + tests/libntp/tspecops.cpp@1.5 +3 -1 + add more timespec_tostr() tests + + tests/libntp/tvalops.cpp@1.5 +3 -1 + add more timeval_tostr() tests + +ChangeSet@1.2422.1.49, 2011-01-26 10:31:57+00:00, stenn@deacon.udel.edu + NTP_4_2_7P125 + TAG: NTP_4_2_7P125 + + ChangeLog@1.784.1.10 +1 -0 + NTP_4_2_7P125 + + clockstuff/clktest-opts.c@1.49 +2 -2 + NTP_4_2_7P125 + + clockstuff/clktest-opts.h@1.49 +3 -3 + NTP_4_2_7P125 + + ntpd/ntpd-opts.c@1.129 +2 -2 + NTP_4_2_7P125 + + ntpd/ntpd-opts.h@1.129 +3 -3 + NTP_4_2_7P125 + + ntpd/ntpd-opts.texi@1.127 +2 -2 + NTP_4_2_7P125 + + ntpd/ntpd.1@1.127 +2 -2 + NTP_4_2_7P125 + + ntpdc/ntpdc-opts.c@1.126 +2 -2 + NTP_4_2_7P125 + + ntpdc/ntpdc-opts.h@1.126 +3 -3 + NTP_4_2_7P125 + + ntpdc/ntpdc-opts.texi@1.126 +2 -2 + NTP_4_2_7P125 + + ntpdc/ntpdc.1@1.126 +2 -2 + NTP_4_2_7P125 + + ntpq/ntpq-opts.c@1.126 +2 -2 + NTP_4_2_7P125 + + ntpq/ntpq-opts.h@1.126 +3 -3 + NTP_4_2_7P125 + + ntpq/ntpq-opts.texi@1.126 +2 -2 + NTP_4_2_7P125 + + ntpq/ntpq.1@1.126 +2 -2 + NTP_4_2_7P125 + + ntpsnmpd/ntpsnmpd-opts.c@1.126 +2 -2 + NTP_4_2_7P125 + + ntpsnmpd/ntpsnmpd-opts.h@1.126 +3 -3 + NTP_4_2_7P125 + + ntpsnmpd/ntpsnmpd-opts.texi@1.126 +2 -2 + NTP_4_2_7P125 + + ntpsnmpd/ntpsnmpd.1@1.126 +2 -2 + NTP_4_2_7P125 + + packageinfo.sh@1.127 +1 -1 + NTP_4_2_7P125 + + sntp/sntp-opts.c@1.115.1.11 +2 -2 + NTP_4_2_7P125 + + sntp/sntp-opts.h@1.115.1.11 +3 -3 + NTP_4_2_7P125 + + sntp/sntp-opts.texi@1.115.1.11 +2 -2 + NTP_4_2_7P125 + + sntp/sntp.1@1.115.1.11 +2 -2 + NTP_4_2_7P125 + + sntp/sntp.html@1.115.1.11 +1 -1 + NTP_4_2_7P125 + + util/ntp-keygen-opts.c@1.124 +2 -2 + NTP_4_2_7P125 + + util/ntp-keygen-opts.h@1.124 +3 -3 + NTP_4_2_7P125 + + util/ntp-keygen-opts.texi@1.127 +2 -2 + NTP_4_2_7P125 + + util/ntp-keygen.1@1.127 +2 -2 + NTP_4_2_7P125 + +ChangeSet@1.2422.8.3, 2011-01-26 03:07:53+00:00, davehart@shiny.ad.hartbrothers.com + Add new files to Windows build. + Fix make distcheck by distributing include/timetoa.h and + tests/libntp/timestructs.h + + include/Makefile.am@1.45 +1 -0 + distribute include/timetoa.h + + include/timetoa.h@1.2 +0 -1 + config.h should be included only once, first, by each .c file + + libntp/timetoa.c@1.2 +21 -18 + nonfunctional style cleanup + + ports/winnt/vc6/libntp.dsp@1.60 +4 -0 + add libntp/timetoa.c reference + + ports/winnt/vs2003/libntp.vcproj@1.18 +5 -2 + add libntp/timetoa.c reference + + ports/winnt/vs2005/libntp.vcproj@1.16 +4 -0 + add libntp/timetoa.c reference + + ports/winnt/vs2008/libntp/libntp.vcproj@1.37 +10 -2 + add libntp/timetoa.c, include/timetoa.h references + + tests/libntp/Makefile.am@1.32 +5 -2 + distribute tests/libntp/timestructs.h + +ChangeSet@1.2422.8.2, 2011-01-25 22:04:11+01:00, jnperlin@hydra.localnet + fixed cut&paste error in tests/libntp/tvalops.cpp + + tests/libntp/tvalops.cpp@1.4 +1 -1 + fixed cut&paste error + +ChangeSet@1.2422.7.1, 2011-01-25 21:08:29+01:00, jnperlin@hydra.localnet + Refactoring of struct timeval string conversion, extended regression tests for struct timeval processing + + include/timespecops.h@1.4 +1 -1 + cleaner expression for normality test (leave optimisation to the optimiser) + + include/timetoa.h@1.1 +85 -0 + new module for string conversion of time_t related values + + include/timetoa.h@1.0 +0 -0 + + include/timevalops.h@1.3 +1 -1 + cleaner expression for normality test (leave optimisation to the optimiser) + + libntp/Makefile.am@1.59 +1 -0 + new module for string conversion of time_t related values + + libntp/timetoa.c@1.1 +112 -0 + new module for string conversion of time_t related values + + libntp/timetoa.c@1.0 +0 -0 + + libntp/timevalops.c@1.6 +4 -58 + moved string formatting stuff to 'timetoa.c' + + tests/libntp/Makefile.am@1.31 +1 -0 + timestruct.cpp added + + tests/libntp/timestructs.cpp@1.1 +127 -0 + new module for adapting / testing time-related structures (l_fp, struct timeval, struct timespec) + + tests/libntp/timestructs.cpp@1.0 +0 -0 + + tests/libntp/timestructs.h@1.1 +159 -0 + new module for adapting / testing time-related structures (l_fp, struct timeval, struct timespec) + + tests/libntp/timestructs.h@1.0 +0 -0 + + tests/libntp/tvalops.cpp@1.3 +162 -141 + moved useful code to timestructs.{h,cpp}; + closeness of l_fp and timeval values tested by special predicate objects; + added some roundtrip tests; + + +ChangeSet@1.2422.1.47, 2011-01-25 19:25:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1794] ntpq -c rv missing clk_wander information. + [Bug 1795] ntpq readvar does not display last variable. + bk rm libntp/tvtoa.c libntp/utvtoa.c + Thanks to Pearly for noticing these dead, nondistributed files in + the version control system. + + BitKeeper/deleted/4a/tvtoa.c~3aed0663@1.5 +0 -0 + Delete: libntp/tvtoa.c + + BitKeeper/deleted/ee/utvtoa.c~3aed0663@1.5 +0 -0 + Delete: libntp/utvtoa.c + + ChangeLog@1.784.1.9 +2 -0 + [Bug 1794] ntpq -c rv missing clk_wander information. + [Bug 1795] ntpq readvar does not display last variable. + + + ntpq/ntpq-subs.c@1.83 +12 -11 + nonfunctional cleanup + + ntpq/ntpq.c@1.131 +7 -6 + [Bug 1794] ntpq -c rv missing clk_wander information. + [Bug 1795] ntpq readvar does not display last variable. + + +ChangeSet@1.2422.1.46, 2011-01-25 11:16:51+00:00, stenn@deacon.udel.edu + NTP_4_2_7P124 + TAG: NTP_4_2_7P124 + + ChangeLog@1.784.1.8 +1 -0 + NTP_4_2_7P124 + + clockstuff/clktest-opts.c@1.48 +2 -2 + NTP_4_2_7P124 + + clockstuff/clktest-opts.h@1.48 +3 -3 + NTP_4_2_7P124 + + ntpd/ntpd-opts.c@1.128 +2 -2 + NTP_4_2_7P124 + + ntpd/ntpd-opts.h@1.128 +3 -3 + NTP_4_2_7P124 + + ntpd/ntpd-opts.texi@1.126 +2 -2 + NTP_4_2_7P124 + + ntpd/ntpd.1@1.126 +2 -2 + NTP_4_2_7P124 + + ntpdc/ntpdc-opts.c@1.125 +2 -2 + NTP_4_2_7P124 + + ntpdc/ntpdc-opts.h@1.125 +3 -3 + NTP_4_2_7P124 + + ntpdc/ntpdc-opts.texi@1.125 +2 -2 + NTP_4_2_7P124 + + ntpdc/ntpdc.1@1.125 +2 -2 + NTP_4_2_7P124 + + ntpq/ntpq-opts.c@1.125 +2 -2 + NTP_4_2_7P124 + + ntpq/ntpq-opts.h@1.125 +3 -3 + NTP_4_2_7P124 + + ntpq/ntpq-opts.texi@1.125 +2 -2 + NTP_4_2_7P124 + + ntpq/ntpq.1@1.125 +2 -2 + NTP_4_2_7P124 + + ntpsnmpd/ntpsnmpd-opts.c@1.125 +2 -2 + NTP_4_2_7P124 + + ntpsnmpd/ntpsnmpd-opts.h@1.125 +3 -3 + NTP_4_2_7P124 + + ntpsnmpd/ntpsnmpd-opts.texi@1.125 +2 -2 + NTP_4_2_7P124 + + ntpsnmpd/ntpsnmpd.1@1.125 +2 -2 + NTP_4_2_7P124 + + packageinfo.sh@1.126 +1 -1 + NTP_4_2_7P124 + + sntp/sntp-opts.c@1.115.1.10 +2 -2 + NTP_4_2_7P124 + + sntp/sntp-opts.h@1.115.1.10 +3 -3 + NTP_4_2_7P124 + + sntp/sntp-opts.texi@1.115.1.10 +2 -2 + NTP_4_2_7P124 + + sntp/sntp.1@1.115.1.10 +2 -2 + NTP_4_2_7P124 + + sntp/sntp.html@1.115.1.10 +1 -1 + NTP_4_2_7P124 + + util/ntp-keygen-opts.c@1.123 +2 -2 + NTP_4_2_7P124 + + util/ntp-keygen-opts.h@1.123 +3 -3 + NTP_4_2_7P124 + + util/ntp-keygen-opts.texi@1.126 +2 -2 + NTP_4_2_7P124 + + util/ntp-keygen.1@1.126 +2 -2 + NTP_4_2_7P124 + +ChangeSet@1.2422.1.45, 2011-01-24 22:35:18-05:00, stenn@deacon.udel.edu + On second thought... + + sntp/Makefile.am@1.47.1.8 +1 -1 + On second thought... + +ChangeSet@1.2422.1.44, 2011-01-24 22:05:31-05:00, stenn@deacon.udel.edu + sntp/Makefile.am needs any passed-in CFLAGS. + + ChangeLog@1.784.1.7 +1 -0 + sntp/Makefile.am needs any passed-in CFLAGS. + + sntp/Makefile.am@1.47.1.7 +1 -1 + sntp/Makefile.am needs any passed-in CFLAGS. + +ChangeSet@1.2422.1.43, 2011-01-24 11:19:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P123 + TAG: NTP_4_2_7P123 + + ChangeLog@1.784.1.6 +1 -0 + NTP_4_2_7P123 + + clockstuff/clktest-opts.c@1.47 +2 -2 + NTP_4_2_7P123 + + clockstuff/clktest-opts.h@1.47 +3 -3 + NTP_4_2_7P123 + + ntpd/ntpd-opts.c@1.127 +2 -2 + NTP_4_2_7P123 + + ntpd/ntpd-opts.h@1.127 +3 -3 + NTP_4_2_7P123 + + ntpd/ntpd-opts.texi@1.125 +2 -2 + NTP_4_2_7P123 + + ntpd/ntpd.1@1.125 +2 -2 + NTP_4_2_7P123 + + ntpdc/ntpdc-opts.c@1.124 +2 -2 + NTP_4_2_7P123 + + ntpdc/ntpdc-opts.h@1.124 +3 -3 + NTP_4_2_7P123 + + ntpdc/ntpdc-opts.texi@1.124 +2 -2 + NTP_4_2_7P123 + + ntpdc/ntpdc.1@1.124 +2 -2 + NTP_4_2_7P123 + + ntpq/ntpq-opts.c@1.124 +2 -2 + NTP_4_2_7P123 + + ntpq/ntpq-opts.h@1.124 +3 -3 + NTP_4_2_7P123 + + ntpq/ntpq-opts.texi@1.124 +2 -2 + NTP_4_2_7P123 + + ntpq/ntpq.1@1.124 +2 -2 + NTP_4_2_7P123 + + ntpsnmpd/ntpsnmpd-opts.c@1.124 +2 -2 + NTP_4_2_7P123 + + ntpsnmpd/ntpsnmpd-opts.h@1.124 +3 -3 + NTP_4_2_7P123 + + ntpsnmpd/ntpsnmpd-opts.texi@1.124 +2 -2 + NTP_4_2_7P123 + + ntpsnmpd/ntpsnmpd.1@1.124 +2 -2 + NTP_4_2_7P123 + + packageinfo.sh@1.125 +1 -1 + NTP_4_2_7P123 + + sntp/sntp-opts.c@1.115.1.9 +2 -2 + NTP_4_2_7P123 + + sntp/sntp-opts.h@1.115.1.9 +3 -3 + NTP_4_2_7P123 + + sntp/sntp-opts.texi@1.115.1.9 +2 -2 + NTP_4_2_7P123 + + sntp/sntp.1@1.115.1.9 +2 -2 + NTP_4_2_7P123 + + sntp/sntp.html@1.115.1.9 +1 -1 + NTP_4_2_7P123 + + util/ntp-keygen-opts.c@1.122 +2 -2 + NTP_4_2_7P123 + + util/ntp-keygen-opts.h@1.122 +3 -3 + NTP_4_2_7P123 + + util/ntp-keygen-opts.texi@1.125 +2 -2 + NTP_4_2_7P123 + + util/ntp-keygen.1@1.125 +2 -2 + NTP_4_2_7P123 + +ChangeSet@1.2422.1.42, 2011-01-23 12:08:42+01:00, jnperlin@hydra.localnet + [Bug 1788] tables in libntp/tvtots.c imprecise + + ChangeLog@1.784.1.5 +1 -0 + [Bug 1788] tables in libntp/tvtots.c imprecise; tables used long/u_long values instead of 'const u_int32' + + clockstuff/chutest.c@1.5 +0 -12 + removed unused declarations of conversion timestamp conversion tables + + clockstuff/clktest.c@1.6 +0 -4 + removed unused declarations of conversion timestamp conversion tables + + include/ntp_unixtime.h@1.8 +8 -8 + timestamp conversion tables type changed to 'const u_int32' arrays + + libntp/msutotsf.c@1.4 +2 -2 + table type changed to 'const u_int32' arrays + + libntp/tstotv.c@1.4 +3 -3 + table type changed to 'const u_int32' arrays + + libntp/tvtots.c@1.4 +75 -75 + values recalculated and table type changed to 'const u_int32' arrays + + libparse/parse.c@1.14 +0 -4 + removed unused declarations of conversion timestamp conversion tables + +ChangeSet@1.2422.1.41, 2011-01-22 11:28:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P122 + TAG: NTP_4_2_7P122 + + ChangeLog@1.784.1.4 +1 -0 + NTP_4_2_7P122 + + clockstuff/clktest-opts.c@1.46 +2 -2 + NTP_4_2_7P122 + + clockstuff/clktest-opts.h@1.46 +3 -3 + NTP_4_2_7P122 + + ntpd/ntpd-opts.c@1.126 +2 -2 + NTP_4_2_7P122 + + ntpd/ntpd-opts.h@1.126 +3 -3 + NTP_4_2_7P122 + + ntpd/ntpd-opts.texi@1.124 +2 -2 + NTP_4_2_7P122 + + ntpd/ntpd.1@1.124 +2 -2 + NTP_4_2_7P122 + + ntpdc/ntpdc-opts.c@1.123 +2 -2 + NTP_4_2_7P122 + + ntpdc/ntpdc-opts.h@1.123 +3 -3 + NTP_4_2_7P122 + + ntpdc/ntpdc-opts.texi@1.123 +2 -2 + NTP_4_2_7P122 + + ntpdc/ntpdc.1@1.123 +2 -2 + NTP_4_2_7P122 + + ntpq/ntpq-opts.c@1.123 +2 -2 + NTP_4_2_7P122 + + ntpq/ntpq-opts.h@1.123 +3 -3 + NTP_4_2_7P122 + + ntpq/ntpq-opts.texi@1.123 +2 -2 + NTP_4_2_7P122 + + ntpq/ntpq.1@1.123 +2 -2 + NTP_4_2_7P122 + + ntpsnmpd/ntpsnmpd-opts.c@1.123 +2 -2 + NTP_4_2_7P122 + + ntpsnmpd/ntpsnmpd-opts.h@1.123 +3 -3 + NTP_4_2_7P122 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123 +2 -2 + NTP_4_2_7P122 + + ntpsnmpd/ntpsnmpd.1@1.123 +2 -2 + NTP_4_2_7P122 + + packageinfo.sh@1.124 +1 -1 + NTP_4_2_7P122 + + sntp/sntp-opts.c@1.115.1.8 +2 -2 + NTP_4_2_7P122 + + sntp/sntp-opts.h@1.115.1.8 +3 -3 + NTP_4_2_7P122 + + sntp/sntp-opts.texi@1.115.1.8 +2 -2 + NTP_4_2_7P122 + + sntp/sntp.1@1.115.1.8 +2 -2 + NTP_4_2_7P122 + + sntp/sntp.html@1.115.1.8 +1 -1 + NTP_4_2_7P122 + + util/ntp-keygen-opts.c@1.121 +2 -2 + NTP_4_2_7P122 + + util/ntp-keygen-opts.h@1.121 +3 -3 + NTP_4_2_7P122 + + util/ntp-keygen-opts.texi@1.124 +2 -2 + NTP_4_2_7P122 + + util/ntp-keygen.1@1.124 +2 -2 + NTP_4_2_7P122 + +ChangeSet@1.2422.1.40, 2011-01-22 01:22:35-05:00, stenn@deacon.udel.edu + ACTS refclock cleanup from Dave Mills + + ChangeLog@1.784.1.3 +1 -0 + ACTS refclock cleanup from Dave Mills + + ntpd/refclock_acts.c@1.46 +8 -17 + ACTS refclock cleanup from Dave Mills + +ChangeSet@1.2422.1.39, 2011-01-22 01:16:02-05:00, stenn@deacon.udel.edu + Avoid shadowing the "group" global variable + + ChangeLog@1.784.1.2 +1 -0 + Avoid shadowing the "group" global variable + + ntpd/ntp_proto.c@1.318 +8 -8 + Avoid shadowing the "group" global variable + +ChangeSet@1.2422.1.38, 2011-01-21 11:15:05+00:00, stenn@deacon.udel.edu + NTP_4_2_7P121 + TAG: NTP_4_2_7P121 + + ChangeLog@1.784.1.1 +1 -0 + NTP_4_2_7P121 + + clockstuff/clktest-opts.c@1.45 +2 -2 + NTP_4_2_7P121 + + clockstuff/clktest-opts.h@1.45 +3 -3 + NTP_4_2_7P121 + + ntpd/ntpd-opts.c@1.125 +2 -2 + NTP_4_2_7P121 + + ntpd/ntpd-opts.h@1.125 +3 -3 + NTP_4_2_7P121 + + ntpd/ntpd-opts.texi@1.123 +2 -2 + NTP_4_2_7P121 + + ntpd/ntpd.1@1.123 +2 -2 + NTP_4_2_7P121 + + ntpdc/ntpdc-opts.c@1.122 +2 -2 + NTP_4_2_7P121 + + ntpdc/ntpdc-opts.h@1.122 +3 -3 + NTP_4_2_7P121 + + ntpdc/ntpdc-opts.texi@1.122 +2 -2 + NTP_4_2_7P121 + + ntpdc/ntpdc.1@1.122 +2 -2 + NTP_4_2_7P121 + + ntpq/ntpq-opts.c@1.122 +2 -2 + NTP_4_2_7P121 + + ntpq/ntpq-opts.h@1.122 +3 -3 + NTP_4_2_7P121 + + ntpq/ntpq-opts.texi@1.122 +2 -2 + NTP_4_2_7P121 + + ntpq/ntpq.1@1.122 +2 -2 + NTP_4_2_7P121 + + ntpsnmpd/ntpsnmpd-opts.c@1.122 +2 -2 + NTP_4_2_7P121 + + ntpsnmpd/ntpsnmpd-opts.h@1.122 +3 -3 + NTP_4_2_7P121 + + ntpsnmpd/ntpsnmpd-opts.texi@1.122 +2 -2 + NTP_4_2_7P121 + + ntpsnmpd/ntpsnmpd.1@1.122 +2 -2 + NTP_4_2_7P121 + + packageinfo.sh@1.123 +1 -1 + NTP_4_2_7P121 + + sntp/sntp-opts.c@1.115.1.7 +2 -2 + NTP_4_2_7P121 + + sntp/sntp-opts.h@1.115.1.7 +3 -3 + NTP_4_2_7P121 + + sntp/sntp-opts.texi@1.115.1.7 +2 -2 + NTP_4_2_7P121 + + sntp/sntp.1@1.115.1.7 +2 -2 + NTP_4_2_7P121 + + sntp/sntp.html@1.115.1.7 +1 -1 + NTP_4_2_7P121 + + util/ntp-keygen-opts.c@1.120 +2 -2 + NTP_4_2_7P121 + + util/ntp-keygen-opts.h@1.120 +3 -3 + NTP_4_2_7P121 + + util/ntp-keygen-opts.texi@1.123 +2 -2 + NTP_4_2_7P121 + + util/ntp-keygen.1@1.123 +2 -2 + NTP_4_2_7P121 + +ChangeSet@1.2422.1.37, 2011-01-21 01:36:18-05:00, stenn@deacon.udel.edu + [Bug 1786] Remove extra semicolon from ntp_proto.c + + ChangeLog@1.784 +1 -0 + [Bug 1786] Remove extra semicolon from ntp_proto.c + + ntpd/ntp_proto.c@1.317 +1 -1 + [Bug 1786] Remove extra semicolon from ntp_proto.c + +ChangeSet@1.2422.1.36, 2011-01-20 11:33:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P120 + TAG: NTP_4_2_7P120 + + ChangeLog@1.783 +1 -0 + NTP_4_2_7P120 + + clockstuff/clktest-opts.c@1.44 +2 -2 + NTP_4_2_7P120 + + clockstuff/clktest-opts.h@1.44 +3 -3 + NTP_4_2_7P120 + + ntpd/ntpd-opts.c@1.124 +2 -2 + NTP_4_2_7P120 + + ntpd/ntpd-opts.h@1.124 +3 -3 + NTP_4_2_7P120 + + ntpd/ntpd-opts.texi@1.122 +2 -2 + NTP_4_2_7P120 + + ntpd/ntpd.1@1.122 +2 -2 + NTP_4_2_7P120 + + ntpdc/ntpdc-opts.c@1.121 +2 -2 + NTP_4_2_7P120 + + ntpdc/ntpdc-opts.h@1.121 +3 -3 + NTP_4_2_7P120 + + ntpdc/ntpdc-opts.texi@1.121 +2 -2 + NTP_4_2_7P120 + + ntpdc/ntpdc.1@1.121 +2 -2 + NTP_4_2_7P120 + + ntpq/ntpq-opts.c@1.121 +2 -2 + NTP_4_2_7P120 + + ntpq/ntpq-opts.h@1.121 +3 -3 + NTP_4_2_7P120 + + ntpq/ntpq-opts.texi@1.121 +2 -2 + NTP_4_2_7P120 + + ntpq/ntpq.1@1.121 +2 -2 + NTP_4_2_7P120 + + ntpsnmpd/ntpsnmpd-opts.c@1.121 +2 -2 + NTP_4_2_7P120 + + ntpsnmpd/ntpsnmpd-opts.h@1.121 +3 -3 + NTP_4_2_7P120 + + ntpsnmpd/ntpsnmpd-opts.texi@1.121 +2 -2 + NTP_4_2_7P120 + + ntpsnmpd/ntpsnmpd.1@1.121 +2 -2 + NTP_4_2_7P120 + + packageinfo.sh@1.122 +1 -1 + NTP_4_2_7P120 + + sntp/sntp-opts.c@1.115.1.6 +2 -2 + NTP_4_2_7P120 + + sntp/sntp-opts.h@1.115.1.6 +3 -3 + NTP_4_2_7P120 + + sntp/sntp-opts.texi@1.115.1.6 +2 -2 + NTP_4_2_7P120 + + sntp/sntp.1@1.115.1.6 +2 -2 + NTP_4_2_7P120 + + sntp/sntp.html@1.115.1.6 +1 -1 + NTP_4_2_7P120 + + util/ntp-keygen-opts.c@1.119 +2 -2 + NTP_4_2_7P120 + + util/ntp-keygen-opts.h@1.119 +3 -3 + NTP_4_2_7P120 + + util/ntp-keygen-opts.texi@1.122 +2 -2 + NTP_4_2_7P120 + + util/ntp-keygen.1@1.122 +2 -2 + NTP_4_2_7P120 + +ChangeSet@1.2422.1.35, 2011-01-20 08:27:32+00:00, davehart@shiny.ad.hartbrothers.com + Change new timeval and timespec to string routines to use snprintf() + rather than hand-crafted conversion, avoid signed int overflow there. + Add configure support for SIZEOF_LONG_LONG to enable portable use of + snprintf() with time_t. + + ChangeLog@1.782 +4 -3 + Change new timeval and timespec to string routines to use snprintf() + rather than hand-crafted conversion, avoid signed int overflow there. + Add configure support for SIZEOF_LONG_LONG to enable portable use of + snprintf() with time_t. + + configure.ac@1.512.1.1 +0 -44 + move more m4 code to ntp_libntp.m4 + + libntp/timespecops.c@1.5 +2 -2 + Change new timeval and timespec to string routines to use snprintf() + rather than hand-crafted conversion, avoid signed int overflow there. + + libntp/timevalops.c@1.5 +2 -2 + Change new timeval and timespec to string routines to use snprintf() + rather than hand-crafted conversion, avoid signed int overflow there. + + ports/winnt/include/config.h@1.93 +3 -1 + SIZEOF_LONG, SIZEOF_LONG_LONG definitions for Win32 + + sntp/configure.ac@1.50.1.5 +0 -42 + move more m4 code to ntp_libntp.m4 + + sntp/m4/ntp_libntp.m4@1.1.1.1 +53 -0 + Add configure support for SIZEOF_LONG_LONG to enable portable use of + snprintf() with time_t. + + +ChangeSet@1.2462, 2011-01-20 03:07:50-05:00, stenn@psp-deb1.ntp.org + Import libevent + + ChangeLog@1.780.1.1 +1 -0 + Import libevent + +ChangeSet@1.2461, 2011-01-20 03:07:20-05:00, stenn@psp-deb1.ntp.org + Import libevent + + BitKeeper/etc/ignore@1.77 +7 -7 + + sntp/libevent/ChangeLog@1.1 +951 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/ChangeLog + + sntp/libevent/ChangeLog@1.0 +0 -0 + + sntp/libevent/Doxyfile@1.1 +244 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/Doxyfile + + sntp/libevent/Doxyfile@1.0 +0 -0 + + sntp/libevent/LICENSE@1.1 +74 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/LICENSE + + sntp/libevent/LICENSE@1.0 +0 -0 + + sntp/libevent/Makefile.am@1.1 +223 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/Makefile.am + + sntp/libevent/Makefile.am@1.0 +0 -0 + + sntp/libevent/Makefile.nmake@1.1 +47 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/Makefile.nmake + + sntp/libevent/Makefile.nmake@1.0 +0 -0 + + sntp/libevent/README@1.1 +152 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/README + + sntp/libevent/README@1.0 +0 -0 + + sntp/libevent/WIN32-Code/event2/event-config.h@1.1 +360 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/WIN32-Code/event2/event-config.h + + sntp/libevent/WIN32-Code/event2/event-config.h@1.0 +0 -0 + + sntp/libevent/WIN32-Code/tree.h@1.1 +1354 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/WIN32-Code/tree.h + + sntp/libevent/WIN32-Code/tree.h@1.0 +0 -0 + + sntp/libevent/arc4random.c@1.1 +534 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/arc4random.c + + sntp/libevent/arc4random.c@1.0 +0 -0 + + sntp/libevent/autogen.sh@1.1 +15 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/autogen.sh + + sntp/libevent/autogen.sh@1.0 +0 -0 + + sntp/libevent/buffer.c@1.1 +2985 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/buffer.c + + sntp/libevent/buffer.c@1.0 +0 -0 + + sntp/libevent/buffer_iocp.c@1.1 +320 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/buffer_iocp.c + + sntp/libevent/buffer_iocp.c@1.0 +0 -0 + + sntp/libevent/bufferevent-internal.h@1.1 +392 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent-internal.h + + sntp/libevent/bufferevent-internal.h@1.0 +0 -0 + + sntp/libevent/bufferevent.c@1.1 +842 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent.c + + sntp/libevent/bufferevent.c@1.0 +0 -0 + + sntp/libevent/bufferevent_async.c@1.1 +655 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent_async.c + + sntp/libevent/bufferevent_async.c@1.0 +0 -0 + + sntp/libevent/bufferevent_filter.c@1.1 +509 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent_filter.c + + sntp/libevent/bufferevent_filter.c@1.0 +0 -0 + + sntp/libevent/bufferevent_openssl.c@1.1 +1345 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent_openssl.c + + sntp/libevent/bufferevent_openssl.c@1.0 +0 -0 + + sntp/libevent/bufferevent_pair.c@1.1 +333 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent_pair.c + + sntp/libevent/bufferevent_pair.c@1.0 +0 -0 + + sntp/libevent/bufferevent_ratelim.c@1.1 +980 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent_ratelim.c + + sntp/libevent/bufferevent_ratelim.c@1.0 +0 -0 + + sntp/libevent/bufferevent_sock.c@1.1 +689 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/bufferevent_sock.c + + sntp/libevent/bufferevent_sock.c@1.0 +0 -0 + + sntp/libevent/changelist-internal.h@1.1 +101 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/changelist-internal.h + + sntp/libevent/changelist-internal.h@1.0 +0 -0 + + sntp/libevent/compat/sys/queue.h@1.1 +488 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/compat/sys/queue.h + + sntp/libevent/compat/sys/queue.h@1.0 +0 -0 + + sntp/libevent/configure.in@1.1 +603 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/configure.in + + sntp/libevent/configure.in@1.0 +0 -0 + + sntp/libevent/defer-internal.h@1.1 +100 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/defer-internal.h + + sntp/libevent/defer-internal.h@1.0 +0 -0 + + sntp/libevent/devpoll.c@1.1 +306 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/devpoll.c + + sntp/libevent/devpoll.c@1.0 +0 -0 + + sntp/libevent/epoll.c@1.1 +470 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/epoll.c + + sntp/libevent/epoll.c@1.0 +0 -0 + + sntp/libevent/epoll_sub.c@1.1 +52 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/epoll_sub.c + + sntp/libevent/epoll_sub.c@1.0 +0 -0 + + sntp/libevent/evbuffer-internal.h@1.1 +277 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evbuffer-internal.h + + sntp/libevent/evbuffer-internal.h@1.0 +0 -0 + + sntp/libevent/evdns.c@1.1 +4544 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evdns.c + + sntp/libevent/evdns.c@1.0 +0 -0 + + sntp/libevent/evdns.h@1.1 +35 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evdns.h + + sntp/libevent/evdns.h@1.0 +0 -0 + + sntp/libevent/event-internal.h@1.1 +339 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/event-internal.h + + sntp/libevent/event-internal.h@1.0 +0 -0 + + sntp/libevent/event.c@1.1 +2794 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/event.c + + sntp/libevent/event.c@1.0 +0 -0 + + sntp/libevent/event.h@1.1 +206 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/event.h + + sntp/libevent/event.h@1.0 +0 -0 + + sntp/libevent/event_iocp.c@1.1 +286 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/event_iocp.c + + sntp/libevent/event_iocp.c@1.0 +0 -0 + + sntp/libevent/event_rpcgen.py@1.1 +1716 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/event_rpcgen.py + + sntp/libevent/event_rpcgen.py@1.0 +0 -0 + + sntp/libevent/event_tagging.c@1.1 +590 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/event_tagging.c + + sntp/libevent/event_tagging.c@1.0 +0 -0 + + sntp/libevent/evhttp.h@1.1 +35 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evhttp.h + + sntp/libevent/evhttp.h@1.0 +0 -0 + + sntp/libevent/evmap-internal.h@1.1 +90 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evmap-internal.h + + sntp/libevent/evmap-internal.h@1.0 +0 -0 + + sntp/libevent/evmap.c@1.1 +724 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evmap.c + + sntp/libevent/evmap.c@1.0 +0 -0 + + sntp/libevent/evport.c@1.1 +460 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evport.c + + sntp/libevent/evport.c@1.0 +0 -0 + + sntp/libevent/evrpc-internal.h@1.1 +204 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evrpc-internal.h + + sntp/libevent/evrpc-internal.h@1.0 +0 -0 + + sntp/libevent/evrpc.c@1.1 +1163 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evrpc.c + + sntp/libevent/evrpc.c@1.0 +0 -0 + + sntp/libevent/evrpc.h@1.1 +35 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evrpc.h + + sntp/libevent/evrpc.h@1.0 +0 -0 + + sntp/libevent/evsignal-internal.h@1.1 +64 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evsignal-internal.h + + sntp/libevent/evsignal-internal.h@1.0 +0 -0 + + sntp/libevent/evthread-internal.h@1.1 +354 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evthread-internal.h + + sntp/libevent/evthread-internal.h@1.0 +0 -0 + + sntp/libevent/evthread.c@1.1 +341 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evthread.c + + sntp/libevent/evthread.c@1.0 +0 -0 + + sntp/libevent/evthread_pthread.c@1.1 +189 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evthread_pthread.c + + sntp/libevent/evthread_pthread.c@1.0 +0 -0 + + sntp/libevent/evthread_win32.c@1.1 +335 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evthread_win32.c + + sntp/libevent/evthread_win32.c@1.0 +0 -0 + + sntp/libevent/evutil.c@1.1 +2095 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evutil.c + + sntp/libevent/evutil.c@1.0 +0 -0 + + sntp/libevent/evutil.h@1.1 +31 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evutil.h + + sntp/libevent/evutil.h@1.0 +0 -0 + + sntp/libevent/evutil_rand.c@1.1 +126 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/evutil_rand.c + + sntp/libevent/evutil_rand.c@1.0 +0 -0 + + sntp/libevent/ht-internal.h@1.1 +486 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/ht-internal.h + + sntp/libevent/ht-internal.h@1.0 +0 -0 + + sntp/libevent/http-internal.h@1.1 +195 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/http-internal.h + + sntp/libevent/http-internal.h@1.0 +0 -0 + + sntp/libevent/http.c@1.1 +4315 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/http.c + + sntp/libevent/http.c@1.0 +0 -0 + + sntp/libevent/include/Makefile.am@1.1 +34 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/Makefile.am + + sntp/libevent/include/Makefile.am@1.0 +0 -0 + + sntp/libevent/include/event2/buffer.h@1.1 +736 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/buffer.h + + sntp/libevent/include/event2/buffer.h@1.0 +0 -0 + + sntp/libevent/include/event2/buffer_compat.h@1.1 +110 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/buffer_compat.h + + sntp/libevent/include/event2/buffer_compat.h@1.0 +0 -0 + + sntp/libevent/include/event2/bufferevent.h@1.1 +759 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/bufferevent.h + + sntp/libevent/include/event2/bufferevent.h@1.0 +0 -0 + + sntp/libevent/include/event2/bufferevent_compat.h@1.1 +96 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/bufferevent_compat.h + + sntp/libevent/include/event2/bufferevent_compat.h@1.0 +0 -0 + + sntp/libevent/include/event2/bufferevent_ssl.h@1.1 +78 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/bufferevent_ssl.h + + sntp/libevent/include/event2/bufferevent_ssl.h@1.0 +0 -0 + + sntp/libevent/include/event2/bufferevent_struct.h@1.1 +113 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/bufferevent_struct.h + + sntp/libevent/include/event2/bufferevent_struct.h@1.0 +0 -0 + + sntp/libevent/include/event2/dns.h@1.1 +639 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/dns.h + + sntp/libevent/include/event2/dns.h@1.0 +0 -0 + + sntp/libevent/include/event2/dns_compat.h@1.1 +335 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/dns_compat.h + + sntp/libevent/include/event2/dns_compat.h@1.0 +0 -0 + + sntp/libevent/include/event2/dns_struct.h@1.1 +80 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/dns_struct.h + + sntp/libevent/include/event2/dns_struct.h@1.0 +0 -0 + + sntp/libevent/include/event2/event.h@1.1 +785 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/event.h + + sntp/libevent/include/event2/event.h@1.0 +0 -0 + + sntp/libevent/include/event2/event_compat.h@1.1 +324 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/event_compat.h + + sntp/libevent/include/event2/event_compat.h@1.0 +0 -0 + + sntp/libevent/include/event2/event_struct.h@1.1 +139 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/event_struct.h + + sntp/libevent/include/event2/event_struct.h@1.0 +0 -0 + + sntp/libevent/include/event2/http.h@1.1 +828 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/http.h + + sntp/libevent/include/event2/http.h@1.0 +0 -0 + + sntp/libevent/include/event2/http_compat.h@1.1 +90 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/http_compat.h + + sntp/libevent/include/event2/http_compat.h@1.0 +0 -0 + + sntp/libevent/include/event2/http_struct.h@1.1 +130 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/http_struct.h + + sntp/libevent/include/event2/http_struct.h@1.0 +0 -0 + + sntp/libevent/include/event2/keyvalq_struct.h@1.1 +80 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/keyvalq_struct.h + + sntp/libevent/include/event2/keyvalq_struct.h@1.0 +0 -0 + + sntp/libevent/include/event2/listener.h@1.1 +143 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/listener.h + + sntp/libevent/include/event2/listener.h@1.0 +0 -0 + + sntp/libevent/include/event2/rpc.h@1.1 +596 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/rpc.h + + sntp/libevent/include/event2/rpc.h@1.0 +0 -0 + + sntp/libevent/include/event2/rpc_compat.h@1.1 +61 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/rpc_compat.h + + sntp/libevent/include/event2/rpc_compat.h@1.0 +0 -0 + + sntp/libevent/include/event2/rpc_struct.h@1.1 +100 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/rpc_struct.h + + sntp/libevent/include/event2/rpc_struct.h@1.0 +0 -0 + + sntp/libevent/include/event2/tag.h@1.1 +124 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/tag.h + + sntp/libevent/include/event2/tag.h@1.0 +0 -0 + + sntp/libevent/include/event2/tag_compat.h@1.1 +39 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/tag_compat.h + + sntp/libevent/include/event2/tag_compat.h@1.0 +0 -0 + + sntp/libevent/include/event2/thread.h@1.1 +225 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/thread.h + + sntp/libevent/include/event2/thread.h@1.0 +0 -0 + + sntp/libevent/include/event2/util.h@1.1 +593 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/include/event2/util.h + + sntp/libevent/include/event2/util.h@1.0 +0 -0 + + sntp/libevent/iocp-internal.h@1.1 +201 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/iocp-internal.h + + sntp/libevent/iocp-internal.h@1.0 +0 -0 + + sntp/libevent/ipv6-internal.h@1.1 +72 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/ipv6-internal.h + + sntp/libevent/ipv6-internal.h@1.0 +0 -0 + + sntp/libevent/kqueue.c@1.1 +415 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/kqueue.c + + sntp/libevent/kqueue.c@1.0 +0 -0 + + sntp/libevent/libevent.pc.in@1.1 +16 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/libevent.pc.in + + sntp/libevent/libevent.pc.in@1.0 +0 -0 + + sntp/libevent/libevent_openssl.pc.in@1.1 +16 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/libevent_openssl.pc.in + + sntp/libevent/libevent_openssl.pc.in@1.0 +0 -0 + + sntp/libevent/libevent_pthreads.pc.in@1.1 +16 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/libevent_pthreads.pc.in + + sntp/libevent/libevent_pthreads.pc.in@1.0 +0 -0 + + sntp/libevent/listener.c@1.1 +865 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/listener.c + + sntp/libevent/listener.c@1.0 +0 -0 + + sntp/libevent/log-internal.h@1.1 +59 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/log-internal.h + + sntp/libevent/log-internal.h@1.0 +0 -0 + + sntp/libevent/log.c@1.1 +224 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/log.c + + sntp/libevent/log.c@1.0 +0 -0 + + sntp/libevent/m4/acx_pthread.m4@1.1 +279 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/m4/acx_pthread.m4 + + sntp/libevent/m4/acx_pthread.m4@1.0 +0 -0 + + sntp/libevent/minheap-internal.h@1.1 +160 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/minheap-internal.h + + sntp/libevent/minheap-internal.h@1.0 +0 -0 + + sntp/libevent/mm-internal.h@1.1 +61 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/mm-internal.h + + sntp/libevent/mm-internal.h@1.0 +0 -0 + + sntp/libevent/poll.c@1.1 +333 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/poll.c + + sntp/libevent/poll.c@1.0 +0 -0 + + sntp/libevent/ratelim-internal.h@1.1 +105 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/ratelim-internal.h + + sntp/libevent/ratelim-internal.h@1.0 +0 -0 + + sntp/libevent/sample/Makefile.am@1.1 +23 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/Makefile.am + + sntp/libevent/sample/Makefile.am@1.0 +0 -0 + + sntp/libevent/sample/dns-example.c@1.1 +221 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/dns-example.c + + sntp/libevent/sample/dns-example.c@1.0 +0 -0 + + sntp/libevent/sample/event-test.c@1.1 +143 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/event-test.c + + sntp/libevent/sample/event-test.c@1.0 +0 -0 + + sntp/libevent/sample/hello-world.c@1.1 +138 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/hello-world.c + + sntp/libevent/sample/hello-world.c@1.0 +0 -0 + + sntp/libevent/sample/http-server.c@1.1 +392 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/http-server.c + + sntp/libevent/sample/http-server.c@1.0 +0 -0 + + sntp/libevent/sample/le-proxy.c@1.1 +278 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/le-proxy.c + + sntp/libevent/sample/le-proxy.c@1.0 +0 -0 + + sntp/libevent/sample/signal-test.c@1.1 +77 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/signal-test.c + + sntp/libevent/sample/signal-test.c@1.0 +0 -0 + + sntp/libevent/sample/time-test.c@1.1 +108 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/sample/time-test.c + + sntp/libevent/sample/time-test.c@1.0 +0 -0 + + sntp/libevent/select.c@1.1 +311 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/select.c + + sntp/libevent/select.c@1.0 +0 -0 + + sntp/libevent/signal.c@1.1 +438 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/signal.c + + sntp/libevent/signal.c@1.0 +0 -0 + + sntp/libevent/strlcpy-internal.h@1.1 +21 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/strlcpy-internal.h + + sntp/libevent/strlcpy-internal.h@1.0 +0 -0 + + sntp/libevent/strlcpy.c@1.1 +74 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/strlcpy.c + + sntp/libevent/strlcpy.c@1.0 +0 -0 + + sntp/libevent/test/Makefile.am@1.1 +74 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/Makefile.am + + sntp/libevent/test/Makefile.am@1.0 +0 -0 + + sntp/libevent/test/Makefile.nmake@1.1 +56 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/Makefile.nmake + + sntp/libevent/test/Makefile.nmake@1.0 +0 -0 + + sntp/libevent/test/bench.c@1.1 +191 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/bench.c + + sntp/libevent/test/bench.c@1.0 +0 -0 + + sntp/libevent/test/bench_cascade.c@1.1 +169 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/bench_cascade.c + + sntp/libevent/test/bench_cascade.c@1.0 +0 -0 + + sntp/libevent/test/bench_http.c@1.1 +178 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/bench_http.c + + sntp/libevent/test/bench_http.c@1.0 +0 -0 + + sntp/libevent/test/bench_httpclient.c@1.1 +216 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/bench_httpclient.c + + sntp/libevent/test/bench_httpclient.c@1.0 +0 -0 + + sntp/libevent/test/regress.c@1.1 +2339 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress.c + + sntp/libevent/test/regress.c@1.0 +0 -0 + + sntp/libevent/test/regress.gen.c@1.1 +1225 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress.gen.c + + sntp/libevent/test/regress.gen.c@1.0 +0 -0 + + sntp/libevent/test/regress.gen.h@1.1 +207 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress.gen.h + + sntp/libevent/test/regress.gen.h@1.0 +0 -0 + + sntp/libevent/test/regress.h@1.1 +125 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress.h + + sntp/libevent/test/regress.h@1.0 +0 -0 + + sntp/libevent/test/regress.rpc@1.1 +25 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress.rpc + + sntp/libevent/test/regress.rpc@1.0 +0 -0 + + sntp/libevent/test/regress_buffer.c@1.1 +1567 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_buffer.c + + sntp/libevent/test/regress_buffer.c@1.0 +0 -0 + + sntp/libevent/test/regress_bufferevent.c@1.1 +835 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_bufferevent.c + + sntp/libevent/test/regress_bufferevent.c@1.0 +0 -0 + + sntp/libevent/test/regress_dns.c@1.1 +1706 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_dns.c + + sntp/libevent/test/regress_dns.c@1.0 +0 -0 + + sntp/libevent/test/regress_et.c@1.1 +197 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_et.c + + sntp/libevent/test/regress_et.c@1.0 +0 -0 + + sntp/libevent/test/regress_http.c@1.1 +3542 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_http.c + + sntp/libevent/test/regress_http.c@1.0 +0 -0 + + sntp/libevent/test/regress_iocp.c@1.1 +352 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_iocp.c + + sntp/libevent/test/regress_iocp.c@1.0 +0 -0 + + sntp/libevent/test/regress_listener.c@1.1 +211 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_listener.c + + sntp/libevent/test/regress_listener.c@1.0 +0 -0 + + sntp/libevent/test/regress_main.c@1.1 +392 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_main.c + + sntp/libevent/test/regress_main.c@1.0 +0 -0 + + sntp/libevent/test/regress_minheap.c@1.1 +98 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_minheap.c + + sntp/libevent/test/regress_minheap.c@1.0 +0 -0 + + sntp/libevent/test/regress_rpc.c@1.1 +884 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_rpc.c + + sntp/libevent/test/regress_rpc.c@1.0 +0 -0 + + sntp/libevent/test/regress_ssl.c@1.1 +448 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_ssl.c + + sntp/libevent/test/regress_ssl.c@1.0 +0 -0 + + sntp/libevent/test/regress_testutils.c@1.1 +196 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_testutils.c + + sntp/libevent/test/regress_testutils.c@1.0 +0 -0 + + sntp/libevent/test/regress_testutils.h@1.1 +66 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_testutils.h + + sntp/libevent/test/regress_testutils.h@1.0 +0 -0 + + sntp/libevent/test/regress_thread.c@1.1 +511 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_thread.c + + sntp/libevent/test/regress_thread.c@1.0 +0 -0 + + sntp/libevent/test/regress_util.c@1.1 +1076 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_util.c + + sntp/libevent/test/regress_util.c@1.0 +0 -0 + + sntp/libevent/test/regress_zlib.c@1.1 +322 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/regress_zlib.c + + sntp/libevent/test/regress_zlib.c@1.0 +0 -0 + + sntp/libevent/test/test-changelist.c@1.1 +198 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/test-changelist.c + + sntp/libevent/test/test-changelist.c@1.0 +0 -0 + + sntp/libevent/test/test-eof.c@1.1 +96 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/test-eof.c + + sntp/libevent/test/test-eof.c@1.0 +0 -0 + + sntp/libevent/test/test-init.c@1.1 +44 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/test-init.c + + sntp/libevent/test/test-init.c@1.0 +0 -0 + + sntp/libevent/test/test-ratelim.c@1.1 +456 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/test-ratelim.c + + sntp/libevent/test/test-ratelim.c@1.0 +0 -0 + + sntp/libevent/test/test-time.c@1.1 +92 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/test-time.c + + sntp/libevent/test/test-time.c@1.0 +0 -0 + + sntp/libevent/test/test-weof.c@1.1 +96 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/test-weof.c + + sntp/libevent/test/test-weof.c@1.0 +0 -0 + + sntp/libevent/test/test.sh@1.1 +156 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/test.sh + + sntp/libevent/test/test.sh@1.0 +0 -0 + + sntp/libevent/test/tinytest.c@1.1 +383 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/tinytest.c + + sntp/libevent/test/tinytest.c@1.0 +0 -0 + + sntp/libevent/test/tinytest.h@1.1 +87 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/tinytest.h + + sntp/libevent/test/tinytest.h@1.0 +0 -0 + + sntp/libevent/test/tinytest_local.h@1.1 +9 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/tinytest_local.h + + sntp/libevent/test/tinytest_local.h@1.0 +0 -0 + + sntp/libevent/test/tinytest_macros.h@1.1 +184 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/test/tinytest_macros.h + + sntp/libevent/test/tinytest_macros.h@1.0 +0 -0 + + sntp/libevent/util-internal.h@1.1 +256 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/util-internal.h + + sntp/libevent/util-internal.h@1.0 +0 -0 + + sntp/libevent/whatsnew-2.0.txt@1.1 +609 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/whatsnew-2.0.txt + + sntp/libevent/whatsnew-2.0.txt@1.0 +0 -0 + + sntp/libevent/win32select.c@1.1 +376 -0 + BitKeeper file /home/stenn/ntp-dev-libevent/sntp/libevent/win32select.c + + sntp/libevent/win32select.c@1.0 +0 -0 + +ChangeSet@1.2460, 2011-01-20 02:57:31-05:00, stenn@psp-deb1.ntp.org + Add #ifdef DEBUG lines to sntp/main.c + + sntp/main.c@1.67 +16 -0 + Add #ifdef DEBUG lines to sntp/main.c + +ChangeSet@1.2422.1.34, 2011-01-19 20:43:27+01:00, jnperlin@hydra.localnet + changed timeval / timespec string conversion (snprintf() format strings for time_t vs. int / long / long long; avoid signed integer overflow) + + ChangeLog@1.781 +3 -0 + struct timeval / struct timespec string formatting changes + + libntp/timespecops.c@1.4 +79 -85 + changed struct timespec string conversion (snprintf() format for time_t) + + libntp/timevalops.c@1.4 +82 -56 + changed struct timeval string conversion (snprintf() format for time_t) + +ChangeSet@1.2422.1.33, 2011-01-19 12:26:17+00:00, davehart@shiny.ad.hartbrothers.com + Grow ntpd/work_thread.c arrays as needed. + Add DEBUG_* variants of ntp_assert.h macros which compile away using + ./configure --disable-debugging. + Fix tvalops.cpp unit test failures for 32-bit builds. + Return to a single autoreconf invocation in ./bootstrap script. + Fix warnings seen on FreeBSD 9. + NMEA driver documentation update from Juergen Perlinger. + + ChangeLog@1.780 +8 -1 + Grow ntpd/work_thread.c arrays as needed. + Add DEBUG_* variants of ntp_assert.h macros which compile away using + ./configure --disable-debugging. + Fix tvalops.cpp unit test failures for 32-bit builds. + Return to a single autoreconf invocation in ./bootstrap script. + Fix warnings seen on FreeBSD 9. + NMEA driver documentation update from Juergen Perlinger. + + bootstrap@1.38 +6 -2 + Use recursive autoreconf again now that we don't trigger bug. + + include/ntp_assert.h@1.4 +47 -16 + provide assertion macros without NTP_ prefix. + provide debug-only DEBUG_REQUIRE(), DEBUG_INSIST(), etc. + + include/ntp_md5.h@1.8 +3 -2 + silence warning seen on FreeBSD 9 + + include/timespecops.h@1.3 +37 -27 + style cleanup. + reduce duplication. + comment fixes and additions. + TIMESPECOPS_H typos. + + include/timevalops.h@1.2 +42 -35 + style cleanup. + reduce duplication. + comment fixes and additions. + TIMEVALOPS_H typos. + + libntp/socket.c@1.4 +0 -3 + isc/util.h is for use by lib/isc code only, not clients + + libntp/timespecops.c@1.3 +91 -88 + style cleanup. + comment fixes and additions. + use abs(), labs() where appropriate. + reduce duplication. + silence int->char trucation warnings. + + libntp/timevalops.c@1.3 +99 -103 + style cleanup. + comment fixes and additions. + use abs(), labs() where appropriate. + reduce duplication. + silence int->char trucation warnings. + + ntpd/refclock_zyfer.c@1.7 +3 -1 + FreeBSD 9 warns of sys/termios.h deprecation, prefer termios.h + + ntpd/work_thread.c@1.3 +92 -46 + use dynamic-sized request and response arrays of pointers + + ports/winnt/vc6/libntp.dsp@1.59 +10 -2 + add timespecops.c, timevalops.c references + + ports/winnt/vs2003/libntp.vcproj@1.17 +7 -19 + add timespecops.c, timevalops.c references + + ports/winnt/vs2005/libntp.vcproj@1.15 +8 -18 + add timespecops.c, timevalops.c references + + ports/winnt/vs2008/libntp/libntp.vcproj@1.36 +17 -1 + add references to timespecops.c and timevalops.c + + tests/libntp/tspecops.cpp@1.4 +54 -33 + style cleanup. + use class not struct for TVAL, LFP. + + tests/libntp/tvalops.cpp@1.2 +109 -75 + style cleanup. + use class not struct for TVAL, LFP. + use ASSERT_NEAR() for fuzzy double equality test, fixes 32-bit failures. + + util/ntp-keygen.c@1.76 +1 -1 + silence time_t -> u_int truncation warning. + +ChangeSet@1.2422.1.32, 2011-01-19 02:07:09-05:00, stenn@deacon.udel.edu + crypo group changes from Dave Mills + + ChangeLog@1.779 +1 -0 + crypo group changes from Dave Mills + + ntpd/ntp_crypto.c@1.153 +20 -23 + crypo group changes from Dave Mills + + ntpd/ntp_proto.c@1.316 +119 -9 + crypo group changes from Dave Mills + +ChangeSet@1.2422.1.31, 2011-01-19 02:03:53-05:00, stenn@deacon.udel.edu + Lose the RANGEGATE check in PPS, from Dave Mills + + ChangeLog@1.778 +1 -0 + Lose the RANGEGATE check in PPS, from Dave Mills + + include/refclock_atom.h@1.3 +0 -1 + Lose the RANGEGATE check in PPS, from Dave Mills + + ntpd/ntp_refclock.c@1.102 +0 -10 + Lose the RANGEGATE check in PPS, from Dave Mills + +ChangeSet@1.2422.1.30, 2011-01-19 02:01:33-05:00, stenn@deacon.udel.edu + ACTS refclock cleanup from Dave Mills + + ChangeLog@1.777 +1 -0 + ACTS refclock cleanup from Dave Mills + + ntpd/refclock_acts.c@1.45 +2 -28 + ACTS refclock cleanup from Dave Mills + +ChangeSet@1.2422.1.29, 2011-01-19 01:58:52-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.776 +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.70 +5 -5 + Documentation updates from Dave Mills + + html/autokey.html@1.19 +14 -10 + Documentation updates from Dave Mills + + html/copyright.html@1.57 +2 -2 + Documentation updates from Dave Mills + + html/drivers/driver20.html@1.24 +339 -101 + Documentation updates from Dave Mills + + html/keygen.html@1.28 +4 -9 + Documentation updates from Dave Mills + + html/miscopt.html@1.64 +2 -2 + Documentation updates from Dave Mills + + html/select.html@1.2 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2458, 2011-01-19 06:06:52+00:00, stenn@psp-fb1.ntp.org + Move DEBUG-enablement checks to ntp_libntp.m4 + + configure.ac@1.513 +0 -16 + Move DEBUG-enablement checks to ntp_libntp.m4 + + sntp/m4/ntp_libntp.m4@1.2 +17 -1 + Move DEBUG-enablement checks to ntp_libntp.m4 + +ChangeSet@1.2457, 2011-01-19 06:05:57+00:00, stenn@psp-fb1.ntp.org + DEBUG cleanup + + sntp/header.h@1.7 +0 -4 + DEBUG cleanup + + sntp/main.h@1.5 +0 -1 + DEBUG cleanup + +ChangeSet@1.2422.6.2, 2011-01-18 19:35:18+01:00, jnperlin@hydra.localnet + added tests for timevalops.c, enhancements for timespecops.c tests + + tests/libntp/Makefile.am@1.30 +1 -0 + added timeval tests + + tests/libntp/tspecops.cpp@1.3 +39 -47 + refactoring and signed conversion tests + + tests/libntp/tvalops.cpp@1.1 +342 -0 + tests for tvalops + + tests/libntp/tvalops.cpp@1.0 +0 -0 + +ChangeSet@1.2422.5.1, 2011-01-18 18:09:37+01:00, jnperlin@hydra.localnet + Improvements on timeval / timespec ops + + include/lib_strbuf.h@1.10 +3 -2 + made LIB_BUFLENGTH useable for preprocessor tests + + include/timespecops.h@1.2 +3 -0 + additional explanation + + libntp/timespecops.c@1.2 +108 -22 + fixed string conversion and signed conversion + + libntp/timevalops.c@1.2 +75 -27 + fixed string conversion and signed conversion + + tests/libntp/tspecops.cpp@1.2 +22 -0 + added string conversion tests + +ChangeSet@1.2456, 2011-01-18 12:35:26+00:00, stenn@psp-fb1.ntp.org + autogen and debug cleanup + + sntp/main.c@1.66 +4 -13 + autogen and debug cleanup + + sntp/main.h@1.4 +1 -0 + autogen and debug cleanup + +ChangeSet@1.2422.1.27, 2011-01-18 11:32:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P119 + TAG: NTP_4_2_7P119 + + ChangeLog@1.775 +1 -0 + NTP_4_2_7P119 + + clockstuff/clktest-opts.c@1.43 +2 -2 + NTP_4_2_7P119 + + clockstuff/clktest-opts.h@1.43 +3 -3 + NTP_4_2_7P119 + + ntpd/ntpd-opts.c@1.123 +2 -2 + NTP_4_2_7P119 + + ntpd/ntpd-opts.h@1.123 +3 -3 + NTP_4_2_7P119 + + ntpd/ntpd-opts.texi@1.121 +2 -2 + NTP_4_2_7P119 + + ntpd/ntpd.1@1.121 +2 -2 + NTP_4_2_7P119 + + ntpdc/ntpdc-opts.c@1.120 +2 -2 + NTP_4_2_7P119 + + ntpdc/ntpdc-opts.h@1.120 +3 -3 + NTP_4_2_7P119 + + ntpdc/ntpdc-opts.texi@1.120 +2 -2 + NTP_4_2_7P119 + + ntpdc/ntpdc.1@1.120 +2 -2 + NTP_4_2_7P119 + + ntpq/ntpq-opts.c@1.120 +2 -2 + NTP_4_2_7P119 + + ntpq/ntpq-opts.h@1.120 +3 -3 + NTP_4_2_7P119 + + ntpq/ntpq-opts.texi@1.120 +2 -2 + NTP_4_2_7P119 + + ntpq/ntpq.1@1.120 +2 -2 + NTP_4_2_7P119 + + ntpsnmpd/ntpsnmpd-opts.c@1.120 +2 -2 + NTP_4_2_7P119 + + ntpsnmpd/ntpsnmpd-opts.h@1.120 +3 -3 + NTP_4_2_7P119 + + ntpsnmpd/ntpsnmpd-opts.texi@1.120 +2 -2 + NTP_4_2_7P119 + + ntpsnmpd/ntpsnmpd.1@1.120 +2 -2 + NTP_4_2_7P119 + + packageinfo.sh@1.121 +1 -1 + NTP_4_2_7P119 + + sntp/sntp-opts.c@1.115.1.5 +2 -2 + NTP_4_2_7P119 + + sntp/sntp-opts.h@1.115.1.5 +3 -3 + NTP_4_2_7P119 + + sntp/sntp-opts.texi@1.115.1.5 +2 -2 + NTP_4_2_7P119 + + sntp/sntp.1@1.115.1.5 +2 -2 + NTP_4_2_7P119 + + sntp/sntp.html@1.115.1.5 +1 -1 + NTP_4_2_7P119 + + util/ntp-keygen-opts.c@1.118 +2 -2 + NTP_4_2_7P119 + + util/ntp-keygen-opts.h@1.118 +3 -3 + NTP_4_2_7P119 + + util/ntp-keygen-opts.texi@1.121 +2 -2 + NTP_4_2_7P119 + + util/ntp-keygen.1@1.121 +2 -2 + NTP_4_2_7P119 + +ChangeSet@1.2422.4.6, 2011-01-18 07:14:14+00:00, stenn@psp-fb1.ntp.org + Distribute timespecops.h and timevalops.h + + include/Makefile.am@1.44 +2 -0 + Distribute timespecops.h and timevalops.h + +ChangeSet@1.2422.4.5, 2011-01-16 14:56:08+01:00, jnperlin@hydra.localnet + added timespecops and timevalops for operations on struct timespec and struct timeval + + ChangeLog@1.771.1.4 +2 -0 + added timespecops and timevalops for operations on struct timespec and struct timeval + + include/timespecops.h@1.1 +131 -0 + operations on struct timespec + + include/timespecops.h@1.0 +0 -0 + + include/timevalops.h@1.1 +108 -0 + operations on struct timeval + + include/timevalops.h@1.0 +0 -0 + + libntp/Makefile.am@1.58 +2 -0 + added timespecops and timevalops for operations on struct timespec and struct timeval + + libntp/timespecops.c@1.1 +347 -0 + operations on struct timespec + + libntp/timespecops.c@1.0 +0 -0 + + libntp/timevalops.c@1.1 +346 -0 + operations on struct timeval + + libntp/timevalops.c@1.0 +0 -0 + + tests/libntp/Makefile.am@1.29 +2 -1 + added test for timespecops + + tests/libntp/tspecops.cpp@1.1 +327 -0 + tests for timespecops + + tests/libntp/tspecops.cpp@1.0 +0 -0 + +ChangeSet@1.2455, 2011-01-16 10:49:33+00:00, stenn@psp-fb1.ntp.org + sntp option cleanup + + sntp/main.c@1.65 +49 -24 + sntp option cleanup + + sntp/sntp-opts.c@1.121 +267 -184 + sntp option cleanup + + sntp/sntp-opts.def@1.24 +93 -94 + sntp option cleanup + + sntp/sntp-opts.h@1.121 +73 -71 + sntp option cleanup + + sntp/sntp-opts.texi@1.121 +55 -104 + sntp option cleanup + + sntp/sntp.1@1.121 +75 -66 + sntp option cleanup + + sntp/sntp.html@1.121 +94 -133 + sntp option cleanup + + sntp/sntp.texi@1.7 +6 -2 + sntp option cleanup + +ChangeSet@1.2454, 2011-01-16 10:48:00+00:00, stenn@psp-fb1.ntp.org + libevent cleanup + + sntp/Makefile.am@1.52 +1 -10 + libevent cleanup + + sntp/m4/ntp_libevent.m4@1.2, stenn@psp-deb1.ntp.org +0 -0 + Rename: m4/ntp_libevent.m4 -> sntp/m4/ntp_libevent.m4 + +ChangeSet@1.2422.4.4, 2011-01-15 10:47:08+00:00, stenn@deacon.udel.edu + NTP_4_2_7P118 + TAG: NTP_4_2_7P118 + + ChangeLog@1.771.1.3 +1 -0 + NTP_4_2_7P118 + + clockstuff/clktest-opts.c@1.42 +2 -2 + NTP_4_2_7P118 + + clockstuff/clktest-opts.h@1.42 +3 -3 + NTP_4_2_7P118 + + ntpd/ntpd-opts.c@1.122 +2 -2 + NTP_4_2_7P118 + + ntpd/ntpd-opts.h@1.122 +3 -3 + NTP_4_2_7P118 + + ntpd/ntpd-opts.texi@1.120 +2 -2 + NTP_4_2_7P118 + + ntpd/ntpd.1@1.120 +2 -2 + NTP_4_2_7P118 + + ntpdc/ntpdc-opts.c@1.119 +2 -2 + NTP_4_2_7P118 + + ntpdc/ntpdc-opts.h@1.119 +3 -3 + NTP_4_2_7P118 + + ntpdc/ntpdc-opts.texi@1.119 +2 -2 + NTP_4_2_7P118 + + ntpdc/ntpdc.1@1.119 +2 -2 + NTP_4_2_7P118 + + ntpq/ntpq-opts.c@1.119 +2 -2 + NTP_4_2_7P118 + + ntpq/ntpq-opts.h@1.119 +3 -3 + NTP_4_2_7P118 + + ntpq/ntpq-opts.texi@1.119 +2 -2 + NTP_4_2_7P118 + + ntpq/ntpq.1@1.119 +2 -2 + NTP_4_2_7P118 + + ntpsnmpd/ntpsnmpd-opts.c@1.119 +2 -2 + NTP_4_2_7P118 + + ntpsnmpd/ntpsnmpd-opts.h@1.119 +3 -3 + NTP_4_2_7P118 + + ntpsnmpd/ntpsnmpd-opts.texi@1.119 +2 -2 + NTP_4_2_7P118 + + ntpsnmpd/ntpsnmpd.1@1.119 +2 -2 + NTP_4_2_7P118 + + packageinfo.sh@1.120 +1 -1 + NTP_4_2_7P118 + + sntp/sntp-opts.c@1.115.1.4 +2 -2 + NTP_4_2_7P118 + + sntp/sntp-opts.h@1.115.1.4 +3 -3 + NTP_4_2_7P118 + + sntp/sntp-opts.texi@1.115.1.4 +2 -2 + NTP_4_2_7P118 + + sntp/sntp.1@1.115.1.4 +2 -2 + NTP_4_2_7P118 + + sntp/sntp.html@1.115.1.4 +1 -1 + NTP_4_2_7P118 + + util/ntp-keygen-opts.c@1.117 +2 -2 + NTP_4_2_7P118 + + util/ntp-keygen-opts.h@1.117 +3 -3 + NTP_4_2_7P118 + + util/ntp-keygen-opts.texi@1.120 +2 -2 + NTP_4_2_7P118 + + util/ntp-keygen.1@1.120 +2 -2 + NTP_4_2_7P118 + +ChangeSet@1.2422.4.3, 2011-01-15 02:04:43-05:00, stenn@deacon.udel.edu + Use a do-nothing rule to avoid an SCCS "get" + + sntp/Makefile.am@1.47.1.6 +1 -0 + Use a do-nothing rule to avoid an SCCS "get" + +ChangeSet@1.2422.4.2, 2011-01-15 00:16:55-05:00, stenn@deacon.udel.edu + Simplify the built-sources stuff in sntp/ + + ChangeLog@1.771.1.2 +1 -0 + Simplify the built-sources stuff in sntp/ + + sntp/Makefile.am@1.47.1.5 +0 -1 + Simplify the built-sources stuff in sntp/ + +ChangeSet@1.2422.4.1, 2011-01-14 23:06:12-05:00, stenn@deacon.udel.edu + Fix check for -lipv6 on HP-UX 11 + + ChangeLog@1.771.1.1 +1 -0 + + configure.ac@1.512 +4 -8 + +ChangeSet@1.2422.1.24, 2011-01-14 07:50:28+00:00, davehart@shiny.ad.hartbrothers.com + Correct msyslog.c build break on Solaris 2.9 from #ifdef/#if mixup. + + ChangeLog@1.772 +1 -0 + Correct msyslog.c build break on Solaris 2.9 from #ifdef/#if mixup. + + libntp/msyslog.c@1.34 +12 -3 + Correct msyslog.c build break on Solaris 2.9 from #ifdef/#if mixup. + +ChangeSet@1.2422.1.23, 2011-01-13 07:32:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P117 + TAG: NTP_4_2_7P117 + + ChangeLog@1.771 +1 -0 + NTP_4_2_7P117 + + clockstuff/clktest-opts.c@1.41 +3 -3 + NTP_4_2_7P117 + + clockstuff/clktest-opts.h@1.41 +3 -3 + NTP_4_2_7P117 + + ntpd/ntpd-opts.c@1.121 +3 -3 + NTP_4_2_7P117 + + ntpd/ntpd-opts.h@1.121 +3 -3 + NTP_4_2_7P117 + + ntpd/ntpd-opts.texi@1.119 +2 -2 + NTP_4_2_7P117 + + ntpd/ntpd.1@1.119 +2 -2 + NTP_4_2_7P117 + + ntpdc/ntpdc-opts.c@1.118 +4 -4 + NTP_4_2_7P117 + + ntpdc/ntpdc-opts.h@1.118 +3 -3 + NTP_4_2_7P117 + + ntpdc/ntpdc-opts.texi@1.118 +2 -2 + NTP_4_2_7P117 + + ntpdc/ntpdc.1@1.118 +2 -2 + NTP_4_2_7P117 + + ntpq/ntpq-opts.c@1.118 +4 -4 + NTP_4_2_7P117 + + ntpq/ntpq-opts.h@1.118 +3 -3 + NTP_4_2_7P117 + + ntpq/ntpq-opts.texi@1.118 +2 -2 + NTP_4_2_7P117 + + ntpq/ntpq.1@1.118 +2 -2 + NTP_4_2_7P117 + + ntpsnmpd/ntpsnmpd-opts.c@1.118 +3 -3 + NTP_4_2_7P117 + + ntpsnmpd/ntpsnmpd-opts.h@1.118 +3 -3 + NTP_4_2_7P117 + + ntpsnmpd/ntpsnmpd-opts.texi@1.118 +2 -2 + NTP_4_2_7P117 + + ntpsnmpd/ntpsnmpd.1@1.118 +2 -2 + NTP_4_2_7P117 + + packageinfo.sh@1.119 +1 -1 + NTP_4_2_7P117 + + sntp/sntp-opts.c@1.115.1.3 +3 -3 + NTP_4_2_7P117 + + sntp/sntp-opts.h@1.115.1.3 +3 -3 + NTP_4_2_7P117 + + sntp/sntp-opts.texi@1.115.1.3 +2 -2 + NTP_4_2_7P117 + + sntp/sntp.1@1.115.1.3 +2 -2 + NTP_4_2_7P117 + + sntp/sntp.html@1.115.1.3 +1 -1 + NTP_4_2_7P117 + + util/ntp-keygen-opts.c@1.116 +4 -4 + NTP_4_2_7P117 + + util/ntp-keygen-opts.h@1.116 +3 -3 + NTP_4_2_7P117 + + util/ntp-keygen-opts.texi@1.119 +2 -2 + NTP_4_2_7P117 + + util/ntp-keygen.1@1.119 +2 -2 + NTP_4_2_7P117 + +ChangeSet@1.2422.1.22, 2011-01-13 01:53:03-05:00, stenn@deacon.udel.edu + Make sure the built-sources-only target is writable + + sntp/Makefile.am@1.47.1.4 +1 -1 + Make sure the built-sources-only target is writable + +ChangeSet@1.2422.1.21, 2011-01-12 18:57:28-05:00, stenn@deacon.udel.edu + Some systems do not have strerror_r + + libntp/msyslog.c@1.33 +3 -12 + Some systems do not have strerror_r + +ChangeSet@1.2422.1.20, 2011-01-12 16:11:01-05:00, stenn@deacon.udel.edu + Improve libntp.a dependency checking + + adjtimed/Makefile.am@1.9 +6 -1 + Improve libntp.a dependency checking + + clockstuff/Makefile.am@1.16 +6 -1 + Improve libntp.a dependency checking + + libparse/Makefile.am@1.23 +6 -1 + Improve libntp.a dependency checking + + ntpd/Makefile.am@1.98 +7 -1 + Improve libntp.a dependency checking + + ntpdate/Makefile.am@1.26 +6 -1 + Improve libntp.a dependency checking + + ntpdc/Makefile.am@1.56 +7 -2 + Improve libntp.a dependency checking + + ntpq/Makefile.am@1.52 +6 -1 + Improve libntp.a dependency checking + + ntpsnmpd/Makefile.am@1.24 +9 -1 + Improve libntp.a dependency checking + + sntp/Makefile.am@1.47.1.3 +5 -1 + Improve libntp.a dependency checking + + util/Makefile.am@1.55 +6 -1 + Improve libntp.a dependency checking + +ChangeSet@1.2422.1.19, 2011-01-12 15:59:20-05:00, stenn@deacon.udel.edu + Keep AC_PROG_LIBTOOL, instead of changing to LT_INIT + + configure.ac@1.511 +1 -1 + Keep AC_PROG_LIBTOOL, instead of changing to LT_INIT + + sntp/configure.ac@1.50.1.4 +1 -1 + Keep AC_PROG_LIBTOOL, instead of changing to LT_INIT + +ChangeSet@1.2422.1.18, 2011-01-12 05:23:49+00:00, davehart@shiny.ad.hartbrothers.com + Add configure --without-sntp option to disable building sntp and + sntp/tests. withsntp=no in the environment changes the default. + Build infrastructure cleanup: + Move m4 directory to sntp/m4. + Share a single set of genver output between sntp and the top level. + Share a single set of autogen included .defs in sntp/include. + Share a single set of build-aux scripts (e.g. config.guess, missing). + Add ntp_libntp.m4 and ntp_ipv6.m4 to reduce configure.ac duplication. + Warn and exit build/flock-build if bootstrap needs to be run. + + BitKeeper/deleted/cc/excludes~3e480692@1.6 +0 -0 + Rename: excludes -> BitKeeper/deleted/cc/excludes~3e480692 + + ChangeLog@1.770 +9 -0 + Add configure --without-sntp option to disable building sntp and + sntp/tests. withsntp=no in the environment changes the default. + Build infrastructure cleanup: + Move m4 directory to sntp/m4. + Share a single set of genver output between sntp and the top level. + Share a single set of autogen included .defs in sntp/include. + Share a single set of build-aux scripts (e.g. config.guess, missing). + Add ntp_libntp.m4 and ntp_ipv6.m4 to reduce configure.ac duplication. + Warn and exit build/flock-build if bootstrap needs to be run. + + + Makefile.am@1.104 +10 -40 + move m4 subdir to sntp/m4. + use sntp/version.* files directly in top-level. + remove old CVS leftover file "excludes" + + adjtimed/Makefile.am@1.8 +10 -1 + Use CFGLAGS_NTP, AM_CFLAGS and leave CFLAGS to end user. + + bootstrap@1.37 +12 -17 + no more duplication of version.* to sntp subdir + + build@1.42 +7 -4 + use build-aux directory for autotools scripts. + Error out if bootstrap is needed. + + clockstuff/Makefile.am@1.15 +15 -8 + move autogen included .def files to sntp/include + + configure.ac@1.510 +13 -805 + move m4 subdir to sntp/m4 + use sntp/version.* files directly in top-level + move hunks of common code to ntp_libntp.m4 and ntp_ipv6.m4 + + flock-build@1.48 +5 -1 + Error out if bootstrap is needed. + Change with the times, default LIST=pogo + + include/Makefile.am@1.43 +0 -1 + move autogen included files to sntp/include. + + include/lib_strbuf.h@1.9 +1 -2 + No need to call init_lib(), lib_nextbuf is already zero initially. + + include/ntp_stdlib.h@1.57 +3 -0 + add errno_to_str() thread-safe alternative to strerror() + + kernel/Makefile.am@1.4 +0 -1 + remove ancient cruft + + kernel/sys/Makefile.am@1.5 +0 -1 + remove old cruft + + libntp/Makefile.am@1.57 +9 -4 + Use CFGLAGS_NTP, AM_CFLAGS and leave CFLAGS to end user. + + libntp/lib_strbuf.c@1.7 +2 -3 + no need to zero lib_nextbuf in init_lib(), it's zero initially. + + libntp/msyslog.c@1.32 +45 -4 + add errno_to_str(), thread-safe alternative to strerror() + + libparse/Makefile.am@1.22 +7 -3 + Use CFGLAGS_NTP, AM_CFLAGS and leave CFLAGS to end user. + + ntpd/Makefile.am@1.97 +20 -11 + move autogen included .def files to sntp/include + + ntpdate/Makefile.am@1.25 +12 -8 + move version to sntp/version + + ntpdc/Makefile.am@1.55 +23 -14 + move autogen included .def files to sntp/include + + ntpq/Makefile.am@1.51 +20 -13 + move autogen included .def files to sntp/include + + ntpsnmpd/Makefile.am@1.23 +17 -11 + move autogen included .def files to sntp/include + + parseutil/Makefile.am@1.13 +4 -2 + Use CFGLAGS_NTP, AM_CFLAGS and leave CFLAGS to end user. + + ports/winnt/include/config.h@1.92 +4 -4 + add errno_to_str(), thread-safe alternative to strerror() + + ports/winnt/libntp/syslog.c@1.8 +5 -3 + Use LIB_GETBUF instead of a static buffer for ntp_strerror() + + ports/winnt/scripts/mkver.bat@1.13 +4 -4 + move version to sntp/version + + scripts/genver@1.7 +7 -7 + move m4 subdir to sntp/m4 + use sntp/version.* files directly in top-level + + sntp/Makefile.am@1.47.1.2 +63 -75 + move m4 subdir to sntp/m4 + use sntp/version.* files directly in top-level + add --without-sntp configure option + remove FRC from libntp.a rule, it trips up BSD make + + sntp/configure.ac@1.50.1.3 +11 -751 + move m4 subdir to sntp/m4 + use sntp/version.* files directly in top-level + move hunks of common m4sh code to ntp_libntp.m4 and ntp_ipv6.m4 + + sntp/include/Makefile.am@1.1 +18 -0 + move autogen-included .def files to sntp/include + + sntp/include/Makefile.am@1.0 +0 -0 + + sntp/include/autogen-version.def@1.5 +0 -0 + Rename: include/autogen-version.def -> sntp/include/autogen-version.def + + sntp/include/copyright.def@1.15 +1 -1 + move version.m4 to sntp/m4 + + sntp/include/copyright.def@1.14 +0 -0 + Rename: include/copyright.def -> sntp/include/copyright.def + + sntp/include/debug-opt.def@1.6 +0 -0 + Rename: include/debug-opt.def -> sntp/include/debug-opt.def + + sntp/include/homerc.def@1.2 +0 -0 + Rename: include/homerc.def -> sntp/include/homerc.def + + sntp/m4/define_dir.m4@1.3 +0 -0 + Rename: m4/define_dir.m4 -> sntp/m4/define_dir.m4 + + sntp/m4/ntp_cacheversion.m4@1.11 +0 -0 + Rename: m4/ntp_cacheversion.m4 -> sntp/m4/ntp_cacheversion.m4 + + sntp/m4/ntp_dir_sep.m4@1.4 +0 -0 + Rename: m4/ntp_dir_sep.m4 -> sntp/m4/ntp_dir_sep.m4 + + sntp/m4/ntp_googletest.m4@1.2 +0 -0 + Rename: m4/ntp_googletest.m4 -> sntp/m4/ntp_googletest.m4 + + sntp/m4/ntp_ipv6.m4@1.1 +527 -0 + Consolidate duplicated IPv6 detection between configure.ac and sntp/configure.ac + + sntp/m4/ntp_ipv6.m4@1.0 +0 -0 + + sntp/m4/ntp_lib_m.m4@1.3 +0 -0 + Rename: m4/ntp_lib_m.m4 -> sntp/m4/ntp_lib_m.m4 + + sntp/m4/ntp_libntp.m4@1.1 +281 -0 + Add configure --without-sntp option to disable building sntp and + sntp/tests. withsntp=no in the environment changes the default. + + + sntp/m4/ntp_libntp.m4@1.0 +0 -0 + + sntp/m4/ntp_lineeditlibs.m4@1.11 +0 -0 + Rename: m4/ntp_lineeditlibs.m4 -> sntp/m4/ntp_lineeditlibs.m4 + + sntp/m4/ntp_openssl.m4@1.15 +18 -8 + modify CPPFLAGS_NTP not end-user variable CPPFLAGS + + sntp/m4/ntp_openssl.m4@1.14 +0 -0 + Rename: m4/ntp_openssl.m4 -> sntp/m4/ntp_openssl.m4 + + sntp/m4/ntp_vpathhack.m4@1.5 +0 -0 + Rename: m4/ntp_vpathhack.m4 -> sntp/m4/ntp_vpathhack.m4 + + sntp/m4/os_cflags.m4@1.8 +2 -2 + modify CFLAGS_NTP not end-user variable CFLAGS + + sntp/m4/os_cflags.m4@1.7 +0 -0 + Rename: m4/os_cflags.m4 -> sntp/m4/os_cflags.m4 + + sntp/tests/Makefile.am@1.19 +9 -4 + use a single NTP_CROSSCOMPILE conditional for sntp and top-level + stay out of user CFLAGS, CPPFLAGS + + tests/libntp/Makefile.am@1.28 +14 -3 + use AM_CFLAGS and leave CFLAGS to end-user + + util/Makefile.am@1.54 +20 -13 + move autogen included .def files to sntp/include + keep hands off CFLAGS, CPPFLAGS so end-user can override at make time. + +ChangeSet@1.2452, 2011-01-11 11:18:09+00:00, stenn@psp-fb1.ntp.org + Implement -u for sntp + + sntp/main.c@1.64 +1 -1 + Implement -u for sntp + +ChangeSet@1.2451, 2011-01-11 11:01:26+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/networking.h@1.24 +0 -11 + cleanup + +ChangeSet@1.2450, 2011-01-11 08:38:31+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/networking.c@1.56 +25 -317 + cleanup + + sntp/sntp-opts.c@1.119 +23 -2 + cleanup + + sntp/sntp-opts.def@1.23 +8 -0 + cleanup + + sntp/sntp-opts.h@1.119 +14 -7 + cleanup + + sntp/sntp-opts.texi@1.119 +9 -1 + cleanup + + sntp/sntp.1@1.119 +6 -1 + cleanup + + sntp/sntp.html@1.119 +17 -0 + cleanup + +ChangeSet@1.2449, 2011-01-11 07:49:54+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.63 +5 -0 + cleanup + +ChangeSet@1.2448, 2011-01-11 06:43:59+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.62 +2 -1 + cleanup + +ChangeSet@1.2447, 2011-01-11 05:39:51+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.61 +1 -1 + cleanup + +ChangeSet@1.2446, 2011-01-11 05:34:29+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/kod_management.c@1.25 +2 -2 + cleanup + + sntp/main.c@1.60 +4 -4 + cleanup + + sntp/networking.c@1.55 +2 -2 + cleanup + +ChangeSet@1.2445, 2011-01-11 05:17:39+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.59 +205 -101 + cleanup + +ChangeSet@1.2444, 2011-01-11 01:41:18+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.58 +2 -2 + cleanup + +ChangeSet@1.2443, 2011-01-11 01:32:44+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.57 +71 -111 + cleanup + + sntp/sntp-opts.c@1.118 +6 -5 + cleanup + + sntp/sntp-opts.def@1.22 +3 -0 + cleanup + + sntp/sntp-opts.h@1.118 +1 -1 + cleanup + + sntp/sntp-opts.texi@1.118 +9 -1 + cleanup + + sntp/sntp.1@1.118 +6 -2 + cleanup + + sntp/sntp.html@1.118 +9 -2 + cleanup + +ChangeSet@1.2442, 2011-01-10 23:45:26+00:00, stenn@psp-fb1.ntp.org + debug level cleanup + + sntp/main.c@1.56 +3 -5 + debug level cleanup + + sntp/networking.c@1.54 +1 -4 + debug level cleanup + +ChangeSet@1.2441, 2011-01-10 23:29:43+00:00, stenn@psp-fb1.ntp.org + autogen cleanup, debug level cleanup, add --concurrent support + + sntp/main.c@1.55 +16 -4 + autogen cleanup, debug level cleanup, add --concurrent support + + sntp/sntp-opts.c@1.117 +134 -29 + autogen cleanup, debug level cleanup, add --concurrent support + + sntp/sntp-opts.def@1.21 +48 -16 + autogen cleanup, debug level cleanup, add --concurrent support + + sntp/sntp-opts.h@1.117 +29 -13 + autogen cleanup, debug level cleanup, add --concurrent support + + sntp/sntp-opts.texi@1.117 +57 -9 + autogen cleanup, debug level cleanup, add --concurrent support + + sntp/sntp.1@1.117 +28 -6 + autogen cleanup, debug level cleanup, add --concurrent support + + sntp/sntp.html@1.117 +89 -27 + autogen cleanup, debug level cleanup, add --concurrent support + +ChangeSet@1.2422.1.17, 2011-01-10 11:38:28+00:00, stenn@deacon.udel.edu + NTP_4_2_7P116 + TAG: NTP_4_2_7P116 + + ChangeLog@1.769 +1 -0 + NTP_4_2_7P116 + + clockstuff/clktest-opts.c@1.40 +2 -2 + NTP_4_2_7P116 + + clockstuff/clktest-opts.h@1.40 +3 -3 + NTP_4_2_7P116 + + ntpd/ntpd-opts.c@1.120 +2 -2 + NTP_4_2_7P116 + + ntpd/ntpd-opts.h@1.120 +3 -3 + NTP_4_2_7P116 + + ntpd/ntpd-opts.texi@1.118 +2 -2 + NTP_4_2_7P116 + + ntpd/ntpd.1@1.118 +2 -2 + NTP_4_2_7P116 + + ntpdc/ntpdc-opts.c@1.117 +2 -2 + NTP_4_2_7P116 + + ntpdc/ntpdc-opts.h@1.117 +3 -3 + NTP_4_2_7P116 + + ntpdc/ntpdc-opts.texi@1.117 +2 -2 + NTP_4_2_7P116 + + ntpdc/ntpdc.1@1.117 +2 -2 + NTP_4_2_7P116 + + ntpq/ntpq-opts.c@1.117 +2 -2 + NTP_4_2_7P116 + + ntpq/ntpq-opts.h@1.117 +3 -3 + NTP_4_2_7P116 + + ntpq/ntpq-opts.texi@1.117 +2 -2 + NTP_4_2_7P116 + + ntpq/ntpq.1@1.117 +2 -2 + NTP_4_2_7P116 + + ntpsnmpd/ntpsnmpd-opts.c@1.117 +2 -2 + NTP_4_2_7P116 + + ntpsnmpd/ntpsnmpd-opts.h@1.117 +3 -3 + NTP_4_2_7P116 + + ntpsnmpd/ntpsnmpd-opts.texi@1.117 +2 -2 + NTP_4_2_7P116 + + ntpsnmpd/ntpsnmpd.1@1.117 +2 -2 + NTP_4_2_7P116 + + packageinfo.sh@1.118 +1 -1 + NTP_4_2_7P116 + + sntp/sntp-opts.c@1.115.1.2 +2 -2 + NTP_4_2_7P116 + + sntp/sntp-opts.h@1.115.1.2 +3 -3 + NTP_4_2_7P116 + + sntp/sntp-opts.texi@1.115.1.2 +2 -2 + NTP_4_2_7P116 + + sntp/sntp.1@1.115.1.2 +2 -2 + NTP_4_2_7P116 + + sntp/sntp.html@1.115.1.2 +2 -2 + NTP_4_2_7P116 + + util/ntp-keygen-opts.c@1.115 +2 -2 + NTP_4_2_7P116 + + util/ntp-keygen-opts.h@1.115 +3 -3 + NTP_4_2_7P116 + + util/ntp-keygen-opts.texi@1.118 +2 -2 + NTP_4_2_7P116 + + util/ntp-keygen.1@1.118 +2 -2 + NTP_4_2_7P116 + +ChangeSet@1.2422.1.16, 2011-01-10 00:22:04+00:00, davehart@shiny.ad.hartbrothers.com + refclock_nmea.c refactoring by Juergen Perlinger. + + ChangeLog@1.768 +1 -0 + refclock_nmea.c refactoring by Juergen Perlinger. + + html/drivers/driver20.html@1.23 +99 -341 + restore current ntp-dev driver20.html, all html edits need to + flow through Dr. Mills. + + ntpd/refclock_nmea.c@1.58 +24 -22 + refclock_nmea.c refactoring by Juergen Perlinger. + +ChangeSet@1.2254.1.3, 2011-01-09 20:19:31+00:00, davehart@shiny.ad.hartbrothers.com + minor style cleanup of Juergen's refactored NMEA driver + + libntp/atouint.c@1.4 +18 -12 + Add detailed atouint() doc comment + + ntpd/refclock_nmea.c@1.57 +142 -91 + minor style cleanup of Juergen's refactored NMEA driver + +ChangeSet@1.2422.1.14, 2011-01-09 12:55:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P115 + TAG: NTP_4_2_7P115 + + ChangeLog@1.767 +1 -0 + NTP_4_2_7P115 + + clockstuff/clktest-opts.c@1.39 +2 -2 + NTP_4_2_7P115 + + clockstuff/clktest-opts.h@1.39 +3 -3 + NTP_4_2_7P115 + + ntpd/ntpd-opts.c@1.119 +2 -2 + NTP_4_2_7P115 + + ntpd/ntpd-opts.h@1.119 +3 -3 + NTP_4_2_7P115 + + ntpd/ntpd-opts.texi@1.117 +2 -2 + NTP_4_2_7P115 + + ntpd/ntpd.1@1.117 +2 -2 + NTP_4_2_7P115 + + ntpdc/ntpdc-opts.c@1.116 +2 -2 + NTP_4_2_7P115 + + ntpdc/ntpdc-opts.h@1.116 +3 -3 + NTP_4_2_7P115 + + ntpdc/ntpdc-opts.texi@1.116 +2 -2 + NTP_4_2_7P115 + + ntpdc/ntpdc.1@1.116 +2 -2 + NTP_4_2_7P115 + + ntpq/ntpq-opts.c@1.116 +2 -2 + NTP_4_2_7P115 + + ntpq/ntpq-opts.h@1.116 +3 -3 + NTP_4_2_7P115 + + ntpq/ntpq-opts.texi@1.116 +2 -2 + NTP_4_2_7P115 + + ntpq/ntpq.1@1.116 +2 -2 + NTP_4_2_7P115 + + ntpsnmpd/ntpsnmpd-opts.c@1.116 +2 -2 + NTP_4_2_7P115 + + ntpsnmpd/ntpsnmpd-opts.h@1.116 +3 -3 + NTP_4_2_7P115 + + ntpsnmpd/ntpsnmpd-opts.texi@1.116 +2 -2 + NTP_4_2_7P115 + + ntpsnmpd/ntpsnmpd.1@1.116 +2 -2 + NTP_4_2_7P115 + + packageinfo.sh@1.117 +1 -1 + NTP_4_2_7P115 + + sntp/sntp-opts.c@1.115.1.1 +2 -2 + NTP_4_2_7P115 + + sntp/sntp-opts.h@1.115.1.1 +3 -3 + NTP_4_2_7P115 + + sntp/sntp-opts.texi@1.115.1.1 +2 -2 + NTP_4_2_7P115 + + sntp/sntp.1@1.115.1.1 +2 -2 + NTP_4_2_7P115 + + sntp/sntp.html@1.115.1.1 +2 -2 + NTP_4_2_7P115 + + util/ntp-keygen-opts.c@1.114 +2 -2 + NTP_4_2_7P115 + + util/ntp-keygen-opts.h@1.114 +3 -3 + NTP_4_2_7P115 + + util/ntp-keygen-opts.texi@1.117 +2 -2 + NTP_4_2_7P115 + + util/ntp-keygen.1@1.117 +2 -2 + NTP_4_2_7P115 + +ChangeSet@1.2440, 2011-01-09 12:14:54+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/kod_management.c@1.24 +6 -12 + cleanup + + sntp/main.c@1.54 +81 -104 + cleanup + + sntp/networking.c@1.53 +7 -5 + cleanup + +ChangeSet@1.2439, 2011-01-09 10:34:59+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.53 +6 -1 + cleanup + +ChangeSet@1.2438, 2011-01-09 10:23:51+00:00, stenn@psp-fb1.ntp.org + progress and cleanup + + sntp/main.c@1.52 +15 -77 + progress and cleanup + + sntp/networking.c@1.52 +38 -63 + progress and cleanup + +ChangeSet@1.2437, 2011-01-09 08:32:33+00:00, stenn@psp-fb1.ntp.org + debug cleanup. Use our stock Version string stuff + + sntp/Makefile.am@1.50 +18 -1 + debug cleanup. Use our stock Version string stuff + + sntp/networking.c@1.51 +13 -8 + debug cleanup. Use our stock Version string stuff + +ChangeSet@1.2436, 2011-01-09 06:52:29+00:00, stenn@psp-fb1.ntp.org + Use the same "debug" mechanism that the rest of NTP uses + + sntp/configure.ac@1.54 +16 -0 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/crypto.c@1.16 +2 -2 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/kod_management.c@1.23 +1 -1 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/main.c@1.51 +15 -9 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/main.h@1.3 +1 -0 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/networking.c@1.50 +24 -24 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/sntp-opts.c@1.116 +107 -49 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/sntp-opts.def@1.20 +1 -12 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/sntp-opts.h@1.116 +34 -27 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/sntp-opts.texi@1.116 +35 -12 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/sntp.1@1.116 +15 -10 + Use the same "debug" mechanism that the rest of NTP uses + + sntp/sntp.html@1.116 +107 -58 + Use the same "debug" mechanism that the rest of NTP uses + +ChangeSet@1.2435, 2011-01-09 05:00:18+00:00, davehart@shiny.ad.hartbrothers.com + ntp_io.c minor cleanup + sntp/main.c use sockaddr_u in new code + + ntpd/ntp_io.c@1.347 +2 -2 + INADDR_ANY is in network order, match IPv6 code + + sntp/main.c@1.50 +31 -33 + use sockaddr_u, ntp_net.h macros + memset() -> ZERO() + +ChangeSet@1.2434, 2011-01-09 04:28:36+00:00, stenn@psp-fb1.ntp.org + Use sptoa() in various places, so we can see the port # + + sntp/networking.c@1.49 +7 -9 + Use sptoa() in various places, so we can see the port # + +ChangeSet@1.2433, 2011-01-09 03:44:33+00:00, stenn@psp-fb1.ntp.org + cleanup + + sntp/main.c@1.49 +54 -25 + cleanup + +ChangeSet@1.2422.1.13, 2011-01-09 02:46:20+00:00, davehart@shiny.ad.hartbrothers.com + correct ntpq nextvar() warning cleanp + + ntpq/ntpq.c@1.130 +2 -2 + min()/max() mixup + +ChangeSet@1.2431, 2011-01-09 01:21:24+00:00, stenn@psp-fb1.ntp.org + cleanup, and start in on the NTP packet callback + + sntp/main.c@1.47 +63 -34 + cleanup, and start in on the NTP packet callback + +ChangeSet@1.2422.1.12, 2011-01-08 20:34:39+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1781] longlong undefined in sntp handle_pkt() on Debian amd64. + Bump deps-ver and sntp/deps-ver to force each directory to be cleaned once, + to work around build breaks triggered by changing erealloc() and + estrdup() from functions to macros. + + ChangeLog@1.766 +1 -0 + [Bug 1781] longlong undefined in sntp handle_pkt() on Debian amd64. + + deps-ver@1.4 +1 -1 + force each directory to be cleaned once, to work around build + breaks triggered by changing erealloc() and estrdup() from + functions to macros. + + ntpd/ntp_control.c@1.161 +1 -1 + more gcc 4.5.2 warning hunting + + ntpq/ntpq.c@1.129 +23 -22 + more gcc 4.5.2 warning hunting + + sntp/Makefile.am@1.47.1.1 +1 -1 + let libntp Makefile decide if libntp.a is up to date, fixes + building in sntp subdir before top level. + + sntp/deps-ver@1.2 +1 -1 + force each directory to be cleaned once, to work around build + breaks triggered by changing erealloc() and estrdup() from + functions to macros. + + sntp/main.c@1.41.1.2 +1 -1 + [Bug 1781] longlong undefined in sntp handle_pkt() on Debian amd64. + + tests/libntp/Makefile.am@1.27 +1 -1 + @LCRYPTO@ after libntp.a in LDADD + +ChangeSet@1.2422.1.11, 2011-01-08 10:54:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1780] Windows ntpd 4.2.7p114 crashes in ioctl(). + + ChangeLog@1.765 +1 -0 + [Bug 1780] Windows ntpd 4.2.7p114 crashes in ioctl(). + + libntp/socket.c@1.3 +8 -0 + [Bug 1780] Windows ntpd 4.2.7p114 crashes in ioctl(). + + ntpd/ntp_io.c@1.346 +1 -69 + [Bug 1780] Windows ntpd 4.2.7p114 crashes in ioctl(). + +ChangeSet@1.2422.1.10, 2011-01-08 09:53:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P114 + TAG: NTP_4_2_7P114 + + ChangeLog@1.764 +1 -0 + NTP_4_2_7P114 + + clockstuff/clktest-opts.c@1.38 +2 -2 + NTP_4_2_7P114 + + clockstuff/clktest-opts.h@1.38 +3 -3 + NTP_4_2_7P114 + + ntpd/ntpd-opts.c@1.118 +2 -2 + NTP_4_2_7P114 + + ntpd/ntpd-opts.h@1.118 +3 -3 + NTP_4_2_7P114 + + ntpd/ntpd-opts.texi@1.116 +2 -2 + NTP_4_2_7P114 + + ntpd/ntpd.1@1.116 +2 -2 + NTP_4_2_7P114 + + ntpdc/ntpdc-opts.c@1.115 +2 -2 + NTP_4_2_7P114 + + ntpdc/ntpdc-opts.h@1.115 +3 -3 + NTP_4_2_7P114 + + ntpdc/ntpdc-opts.texi@1.115 +2 -2 + NTP_4_2_7P114 + + ntpdc/ntpdc.1@1.115 +2 -2 + NTP_4_2_7P114 + + ntpq/ntpq-opts.c@1.115 +2 -2 + NTP_4_2_7P114 + + ntpq/ntpq-opts.h@1.115 +3 -3 + NTP_4_2_7P114 + + ntpq/ntpq-opts.texi@1.115 +2 -2 + NTP_4_2_7P114 + + ntpq/ntpq.1@1.115 +2 -2 + NTP_4_2_7P114 + + ntpsnmpd/ntpsnmpd-opts.c@1.115 +2 -2 + NTP_4_2_7P114 + + ntpsnmpd/ntpsnmpd-opts.h@1.115 +3 -3 + NTP_4_2_7P114 + + ntpsnmpd/ntpsnmpd-opts.texi@1.115 +2 -2 + NTP_4_2_7P114 + + ntpsnmpd/ntpsnmpd.1@1.115 +2 -2 + NTP_4_2_7P114 + + packageinfo.sh@1.116 +1 -1 + NTP_4_2_7P114 + + sntp/sntp-opts.c@1.115 +2 -2 + NTP_4_2_7P114 + + sntp/sntp-opts.h@1.115 +3 -3 + NTP_4_2_7P114 + + sntp/sntp-opts.texi@1.115 +2 -2 + NTP_4_2_7P114 + + sntp/sntp.1@1.115 +2 -2 + NTP_4_2_7P114 + + sntp/sntp.html@1.115 +2 -2 + NTP_4_2_7P114 + + util/ntp-keygen-opts.c@1.113 +2 -2 + NTP_4_2_7P114 + + util/ntp-keygen-opts.h@1.113 +3 -3 + NTP_4_2_7P114 + + util/ntp-keygen-opts.texi@1.116 +2 -2 + NTP_4_2_7P114 + + util/ntp-keygen.1@1.116 +2 -2 + NTP_4_2_7P114 + +ChangeSet@1.2422.1.9, 2011-01-08 08:45:17+00:00, davehart@shiny.ad.hartbrothers.com + Fix for openssl pkg-config detection eval failure. + (applies to prior cset) + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + ChangeLog@1.763 +4 -0 + Fix for openssl pkg-config detection eval failure. + (applies to prior cset) + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + configure.ac@1.509 +1 -43 + Accept gtest versions greater than 1.5 + Move google test detection to m4\ntp_googletest.m4 + + include/lib_strbuf.h@1.8 +1 -1 + memset() -> ZERO() + + include/ntp_control.h@1.56 +1 -1 + rename ctl_trap[] to ctl_traps[] to be distinct from struct tag + + include/ntp_malloc.h@1.5 +17 -0 + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + include/ntp_net.h@1.11 +2 -1 + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + include/ntp_rfc2553.h@1.37 +11 -7 + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + include/ntp_stdlib.h@1.56 +27 -14 + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + libntp/authkeys.c@1.21 +2 -2 + memset() -> ZERO() + + libntp/decodenetnum.c@1.13 +1 -1 + memset() -> ZERO() + + libntp/dofptoa.c@1.8 +1 -1 + memset() -> ZERO() + + libntp/dolfptoa.c@1.10 +1 -1 + memset() -> ZERO() + + libntp/emalloc.c@1.14 +56 -102 + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + libntp/netof.c@1.9 +1 -1 + memset() -> zero_mem() + + libntp/ntp_lineedit.c@1.10 +1 -1 + memset() -> ZERO() + + libntp/ntp_rfc2553.c@1.44 +7 -16 + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + libntp/recvbuff.c@1.36 +3 -4 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + libntp/socktohost.c@1.12 +1 -1 + memset() -> ZERO() + + libntp/syssignal.c@1.11 +1 -1 + memset() -> ZERO() + + libntp/systime.c@1.52 +2 -2 + memset() -> ZERO() + + m4/ntp_googletest.m4@1.1 +52 -0 + BitKeeper file C:/ntp/ntp-dev-erealloc-zero/m4/ntp_googletest.m4 + + m4/ntp_googletest.m4@1.0 +0 -0 + + ntpd/keyword-gen.c@1.17 +1 -2 + memset() -> ZERO() + + ntpd/ntp_config.c@1.283 +12 -12 + memset() -> ZERO() + + ntpd/ntp_control.c@1.160 +126 -135 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ntpd/ntp_intres.c@1.91 +3 -6 + emalloc() + memset() -> emalloc_zero() + + ntpd/ntp_io.c@1.345 +16 -18 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ntpd/ntp_monitor.c@1.37 +4 -5 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ntpd/ntp_peer.c@1.146 +2 -3 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ntpd/ntp_refclock.c@1.101 +3 -4 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ntpd/ntp_request.c@1.102 +20 -43 + memset() -> ZERO() + + ntpd/ntp_restrict.c@1.34 +5 -7 + memset() -> ZERO() + memset() -> zero_mem() + emalloc() + memset() -> emalloc_zero() + + ntpd/ntp_signd.c@1.3 +5 -5 + memset() -> ZERO() + + ntpd/ntp_util.c@1.92 +2 -0 + save a hundred bytes or so on Windows + + ntpd/ntpsim.c@1.31 +2 -2 + memset() -> ZERO() + + ntpdate/ntpdate.c@1.82 +8 -8 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ntpdc/ntpdc.c@1.93 +10 -9 + use erealloc_zero + + ntpdc/ntpdc_ops.c@1.75 +28 -55 + memset() -> ZERO() + + ntpq/ntpq-subs.c@1.82 +36 -41 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ntpq/ntpq.c@1.128 +21 -26 + memset() -> ZERO() + + ports/winnt/include/config.h@1.91 +7 -5 + Add erealloc_zero(), refactor estrdup(), emalloc(), emalloc_zero() to + separate tracking callsite file/line from using debug MS C runtime, + and to reduce code duplication. + + ports/winnt/libntp/termios.c@1.26 +2 -3 + erealloc() + memset() -> erealloc_zero() + + ports/winnt/ntpd/nt_clockstuff.c@1.49 +2 -2 + memset() -> ZERO() + + ports/winnt/ntpd/ntp_iocompletionport.c@1.56 +2 -3 + memset() -> ZERO() + emalloc() + memset() -> emalloc_zero() + + ports/winnt/ntpd/ntservice.c@1.26 +1 -1 + memset() -> ZERO() + + sntp/configure.ac@1.50.1.2 +3 -42 + Move google test detection to m4\ntp_googletest.m4 + + sntp/tests/Makefile.am@1.18 +4 -4 + put @GTEST_LDFLAGS@ @GTEST_LIBS@ after @LCRYPTO@ in LDADD + +ChangeSet@1.2422.3.2, 2011-01-07 17:46:18+00:00, davehart@shiny.ad.hartbrothers.com + use tr to deal with trailing newline from pkg-config in ntp_openssl.m4 + + m4/ntp_openssl.m4@1.13 +4 -6 + use tr to deal with trailing newline from pkg-config in ntp_openssl.m4 + +ChangeSet@1.2422.3.1, 2011-01-07 15:31:38+00:00, davehart@shiny.ad.hartbrothers.com + add libntp/socket.c references to Windows libntp projects. + + ports/winnt/vc6/libntp.dsp@1.58 +4 -0 + add libntp/socket.c references to Windows libntp projects. + + ports/winnt/vs2003/libntp.vcproj@1.16 +3 -18 + add libntp/socket.c references to Windows libntp projects. + + ports/winnt/vs2005/libntp.vcproj@1.14 +4 -18 + add libntp/socket.c references to Windows libntp projects. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.35 +6 -16 + add libntp/socket.c references to Windows libntp projects. + +ChangeSet@1.2429, 2011-01-07 11:34:06+00:00, stenn@psp-fb1.ntp.org + first cut at key auth and the initial packet send for SNTP + + sntp/main.c@1.46 +83 -1 + first cut at key auth and the initial packet send + +ChangeSet@1.2422.1.7, 2011-01-07 11:16:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P113 + TAG: NTP_4_2_7P113 + + ChangeLog@1.762 +1 -0 + NTP_4_2_7P113 + + clockstuff/clktest-opts.c@1.37 +2 -2 + NTP_4_2_7P113 + + clockstuff/clktest-opts.h@1.37 +3 -3 + NTP_4_2_7P113 + + ntpd/ntpd-opts.c@1.117 +2 -2 + NTP_4_2_7P113 + + ntpd/ntpd-opts.h@1.117 +3 -3 + NTP_4_2_7P113 + + ntpd/ntpd-opts.texi@1.115 +2 -2 + NTP_4_2_7P113 + + ntpd/ntpd.1@1.115 +2 -2 + NTP_4_2_7P113 + + ntpdc/ntpdc-opts.c@1.114 +2 -2 + NTP_4_2_7P113 + + ntpdc/ntpdc-opts.h@1.114 +3 -3 + NTP_4_2_7P113 + + ntpdc/ntpdc-opts.texi@1.114 +2 -2 + NTP_4_2_7P113 + + ntpdc/ntpdc.1@1.114 +2 -2 + NTP_4_2_7P113 + + ntpq/ntpq-opts.c@1.114 +2 -2 + NTP_4_2_7P113 + + ntpq/ntpq-opts.h@1.114 +3 -3 + NTP_4_2_7P113 + + ntpq/ntpq-opts.texi@1.114 +2 -2 + NTP_4_2_7P113 + + ntpq/ntpq.1@1.114 +2 -2 + NTP_4_2_7P113 + + ntpsnmpd/ntpsnmpd-opts.c@1.114 +2 -2 + NTP_4_2_7P113 + + ntpsnmpd/ntpsnmpd-opts.h@1.114 +3 -3 + NTP_4_2_7P113 + + ntpsnmpd/ntpsnmpd-opts.texi@1.114 +2 -2 + NTP_4_2_7P113 + + ntpsnmpd/ntpsnmpd.1@1.114 +2 -2 + NTP_4_2_7P113 + + packageinfo.sh@1.115 +1 -1 + NTP_4_2_7P113 + + sntp/sntp-opts.c@1.114 +2 -2 + NTP_4_2_7P113 + + sntp/sntp-opts.h@1.114 +3 -3 + NTP_4_2_7P113 + + sntp/sntp-opts.texi@1.114 +2 -2 + NTP_4_2_7P113 + + sntp/sntp.1@1.114 +2 -2 + NTP_4_2_7P113 + + sntp/sntp.html@1.114 +2 -2 + NTP_4_2_7P113 + + util/ntp-keygen-opts.c@1.112 +2 -2 + NTP_4_2_7P113 + + util/ntp-keygen-opts.h@1.112 +3 -3 + NTP_4_2_7P113 + + util/ntp-keygen-opts.texi@1.115 +2 -2 + NTP_4_2_7P113 + + util/ntp-keygen.1@1.115 +2 -2 + NTP_4_2_7P113 + +ChangeSet@1.2428, 2011-01-07 09:30:07+00:00, stenn@psp-fb1.ntp.org + Handle initial socket creation for sntp + + sntp/main.c@1.45 +27 -5 + progress + +ChangeSet@1.2422.1.6, 2011-01-07 04:16:46-05:00, stenn@deacon.udel.edu + portability adjustment + + include/ntp_io.h@1.20 +2 -1 + portability adjustment + +ChangeSet@1.2422.1.5, 2011-01-07 04:03:07-05:00, stenn@deacon.udel.edu + typo + + libntp/socket.c@1.2 +1 -1 + typo + +ChangeSet@1.2422.1.4, 2011-01-07 03:38:35-05:00, stenn@deacon.udel.edu + Begin moving some of the low-level socket stuff to libntp + + ChangeLog@1.761 +1 -0 + Begin moving some of the low-level socket stuff to libntp + + include/Makefile.am@1.42 +1 -0 + Begin moving some of the low-level socket stuff to libntp + + include/libntp.h@1.1 +16 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/libntp.h + + include/libntp.h@1.0 +0 -0 + + include/ntp_io.h@1.19 +1 -0 + Begin moving some of the low-level socket stuff to libntp + + libntp/Makefile.am@1.56 +1 -0 + Begin moving some of the low-level socket stuff to libntp + + libntp/socket.c@1.1 +732 -0 + BitKeeper file /deacon/backroom/ntp-dev/libntp/socket.c + + libntp/socket.c@1.0 +0 -0 + + ntpd/ntp_io.c@1.344 +8 -11 + Begin moving some of the low-level socket stuff to libntp + +ChangeSet@1.2422.2.1, 2011-01-06 23:06:38-05:00, stenn@deacon.udel.edu + If the subject-name begins with @, prefix it with the certname + + util/ntp-keygen.c@1.73.1.1 +10 -2 + If the subject-name begins with @, prefix it with the certname + +ChangeSet@1.2422.1.2, 2011-01-06 20:56:23+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1776] sntp mishandles -t/--timeout and -a/--authentication. + Default to silent make rules, override with make V=1 or ./configure + --disable-silent-rules. + Correct --with-openssl-incdir defaulting with pkg-config. + Correct ./build on systems without gtest available. + + ChangeLog@1.760 +5 -0 + [Bug 1776] sntp mishandles -t/--timeout and -a/--authentication. + Default to silent make rules, override with make V=1 or ./configure + --disable-silent-rules. + Correct --with-openssl-incdir defaulting with pkg-config. + Correct ./build on systems without gtest available. + + build@1.41 +1 -5 + Do not attempt to build tests unconditionally, some systems do not have gtest. + + configure.ac@1.508 +2 -40 + default to silent make rules. + move --without-rpath/need_dash_r logic to m4/ntp_openssl.m4 which depends on it. + + include/ntp_md5.h@1.7 +1 -1 + quiet gcc 4.5.1 warning re: pointers to incompatible types + + libntp/ssl_init.c@1.13 +1 -1 + quiet unused local warning building w/o openssl + + libparse/Makefile.am@1.21 +2 -17 + Remove old transitional rule from move of generated .c to $srcdir + + m4/ntp_openssl.m4@1.12 +58 -7 + Correct --with-openssl-incdir defaulting with pkg-config. + + ntpd/ntp_control.c@1.159 +2 -2 + quiet shadowing warning seen on linux + + ntpd/ntp_io.c@1.343 +1 -0 + quiet used potentially uninit warning for some members of sockaddr_u + + ntpd/ntp_peer.c@1.145 +5 -5 + quiet "group" shadows global warning + + ntpd/ntp_refclock.c@1.100 +1 -1 + correct printf() format to match change from int to size_t + + ntpd/refclock_acts.c@1.44 +1 -1 + printf format mismatch %d vs size_t + + ntpdate/ntpdate.c@1.81 +1 -1 + quiet warning re: recvfrom() fromlen arg by using socklen_t not int. + + ntpdc/ntpdc.c@1.92 +2 -1 + correct printf() args to match change from int to size_t + + ntpq/ntpq-subs.c@1.81 +16 -15 + correct printf format mismatch warnings. + + ntpq/ntpq.c@1.127 +12 -16 + correct printf format mismatch warnings. + + sntp/configure.ac@1.50.1.1 +2 -2 + default to silent make rules + + sntp/main.c@1.41.1.1 +22 -9 + [Bug 1776] sntp mishandles -t/--timeout and -a/--authentication. + tighten resolve_hosts 1st arg constness to quiet gcc 4.5.1 warning. + + sntp/networking.c@1.46.1.1 +10 -8 + [Bug 1776] sntp mishandles -t/--timeout and -a/--authentication. + tighten resolve_hosts 1st arg constness to quiet gcc 4.5.1 warning. + + sntp/networking.h@1.23 +2 -1 + tighten resolve_hosts 1st arg constness to quiet gcc 4.5.1 warning. + + util/ntp-keygen.c@1.74 +1 -1 + quiet warning when building without AUTOKEY + +ChangeSet@1.2424, 2011-01-06 10:04:48+00:00, stenn@psp-fb1.ntp.org + libevent + + sntp/main.c@1.43 +93 -73 + libevent + +ChangeSet@1.2422.1.1, 2011-01-06 08:55:50+00:00, stenn@deacon.udel.edu + NTP_4_2_7P112 + TAG: NTP_4_2_7P112 + + ChangeLog@1.759 +1 -0 + NTP_4_2_7P112 + + clockstuff/clktest-opts.c@1.36 +2 -2 + NTP_4_2_7P112 + + clockstuff/clktest-opts.h@1.36 +3 -3 + NTP_4_2_7P112 + + ntpd/ntpd-opts.c@1.116 +2 -2 + NTP_4_2_7P112 + + ntpd/ntpd-opts.h@1.116 +3 -3 + NTP_4_2_7P112 + + ntpd/ntpd-opts.texi@1.114 +2 -2 + NTP_4_2_7P112 + + ntpd/ntpd.1@1.114 +2 -2 + NTP_4_2_7P112 + + ntpdc/ntpdc-opts.c@1.113 +2 -2 + NTP_4_2_7P112 + + ntpdc/ntpdc-opts.h@1.113 +3 -3 + NTP_4_2_7P112 + + ntpdc/ntpdc-opts.texi@1.113 +2 -2 + NTP_4_2_7P112 + + ntpdc/ntpdc.1@1.113 +2 -2 + NTP_4_2_7P112 + + ntpq/ntpq-opts.c@1.113 +2 -2 + NTP_4_2_7P112 + + ntpq/ntpq-opts.h@1.113 +3 -3 + NTP_4_2_7P112 + + ntpq/ntpq-opts.texi@1.113 +2 -2 + NTP_4_2_7P112 + + ntpq/ntpq.1@1.113 +2 -2 + NTP_4_2_7P112 + + ntpsnmpd/ntpsnmpd-opts.c@1.113 +2 -2 + NTP_4_2_7P112 + + ntpsnmpd/ntpsnmpd-opts.h@1.113 +3 -3 + NTP_4_2_7P112 + + ntpsnmpd/ntpsnmpd-opts.texi@1.113 +2 -2 + NTP_4_2_7P112 + + ntpsnmpd/ntpsnmpd.1@1.113 +2 -2 + NTP_4_2_7P112 + + packageinfo.sh@1.114 +1 -1 + NTP_4_2_7P112 + + sntp/sntp-opts.c@1.113 +2 -2 + NTP_4_2_7P112 + + sntp/sntp-opts.h@1.113 +3 -3 + NTP_4_2_7P112 + + sntp/sntp-opts.texi@1.113 +2 -2 + NTP_4_2_7P112 + + sntp/sntp.1@1.113 +2 -2 + NTP_4_2_7P112 + + sntp/sntp.html@1.113 +2 -2 + NTP_4_2_7P112 + + util/ntp-keygen-opts.c@1.111 +2 -2 + NTP_4_2_7P112 + + util/ntp-keygen-opts.h@1.111 +3 -3 + NTP_4_2_7P112 + + util/ntp-keygen-opts.texi@1.114 +2 -2 + NTP_4_2_7P112 + + util/ntp-keygen.1@1.114 +2 -2 + NTP_4_2_7P112 + +ChangeSet@1.2393.1.1, 2011-01-06 07:58:30+00:00, stenn@psp-fb1.ntp.org + libevent changes + + m4/ntp_libevent.m4@1.1 +80 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-libevent/m4/ntp_libevent.m4 + + m4/ntp_libevent.m4@1.0 +0 -0 + + sntp/Makefile.am@1.48 +14 -7 + libevent changes + + sntp/build-libevent/Makefile.am@1.1 +61 -0 + BitKeeper file /a/etc/amd.stage/thump2-g3/export/ntp/home/stenn/ntp-dev-libevent/sntp/build-libevent/Makefile.am + + sntp/build-libevent/Makefile.am@1.0 +0 -0 + + sntp/configure.ac@1.49.1.1 +8 -0 + libevent changes + + sntp/main.c@1.42 +252 -53 + libevent changes + + sntp/networking.c@1.47 +86 -42 + libevent changes + +ChangeSet@1.2422, 2011-01-06 04:43:56+00:00, davehart@shiny.ad.hartbrothers.com + ./build makes unit tests with V=0 before make check + + build@1.40 +4 -0 + Build unit tests first with V=0 + + tests/libntp/Makefile.am@1.26 +5 -6 + Remove tabs from $INCLUDES to make compiler command lines less sparse + +ChangeSet@1.2421, 2011-01-06 04:37:31+00:00, hart@psp-deb1.ntp.org + Use silent rules for first make invocation in build + + ChangeLog@1.758 +1 -0 + Use make V=0 in build script to increase signal/noise ratio. + + build@1.39 +1 -1 + Use make V=0 in build script to increase signal/noise ratio. + +ChangeSet@1.2420, 2011-01-06 04:02:24+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1773] openssl not detected during ./configure. + [Bug 1774] Segfaults if cryptostats enabled and built without OpenSSL. + + ChangeLog@1.757 +2 -0 + [Bug 1773] openssl not detected during ./configure. + [Bug 1774] Segfaults if cryptostats enabled and built without OpenSSL. + + + m4/ntp_openssl.m4@1.11 +16 -22 + [Bug 1773] openssl not detected during ./configure. + + + ntpd/ntp_config.c@1.282 +12 -0 + [Bug 1774] Segfaults if cryptostats enabled and built without OpenSSL. + + + ntpd/ntp_util.c@1.91 +2 -10 + filegen_register() timingstats and cryptostats unconditionally, so we do + not consider them unrecognized, as it's harmless to attempt to enable + cryptostats with a non-autokey ntpd. + +ChangeSet@1.2419, 2011-01-05 08:46:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P111 + TAG: NTP_4_2_7P111 + + ChangeLog@1.756 +1 -0 + NTP_4_2_7P111 + + clockstuff/clktest-opts.c@1.35 +2 -2 + NTP_4_2_7P111 + + clockstuff/clktest-opts.h@1.35 +3 -3 + NTP_4_2_7P111 + + ntpd/ntpd-opts.c@1.115 +2 -2 + NTP_4_2_7P111 + + ntpd/ntpd-opts.h@1.115 +3 -3 + NTP_4_2_7P111 + + ntpd/ntpd-opts.texi@1.113 +2 -2 + NTP_4_2_7P111 + + ntpd/ntpd.1@1.113 +2 -2 + NTP_4_2_7P111 + + ntpdc/ntpdc-opts.c@1.112 +2 -2 + NTP_4_2_7P111 + + ntpdc/ntpdc-opts.h@1.112 +3 -3 + NTP_4_2_7P111 + + ntpdc/ntpdc-opts.texi@1.112 +2 -2 + NTP_4_2_7P111 + + ntpdc/ntpdc.1@1.112 +2 -2 + NTP_4_2_7P111 + + ntpq/ntpq-opts.c@1.112 +2 -2 + NTP_4_2_7P111 + + ntpq/ntpq-opts.h@1.112 +3 -3 + NTP_4_2_7P111 + + ntpq/ntpq-opts.texi@1.112 +2 -2 + NTP_4_2_7P111 + + ntpq/ntpq.1@1.112 +2 -2 + NTP_4_2_7P111 + + ntpsnmpd/ntpsnmpd-opts.c@1.112 +2 -2 + NTP_4_2_7P111 + + ntpsnmpd/ntpsnmpd-opts.h@1.112 +3 -3 + NTP_4_2_7P111 + + ntpsnmpd/ntpsnmpd-opts.texi@1.112 +2 -2 + NTP_4_2_7P111 + + ntpsnmpd/ntpsnmpd.1@1.112 +2 -2 + NTP_4_2_7P111 + + packageinfo.sh@1.113 +1 -1 + NTP_4_2_7P111 + + sntp/sntp-opts.c@1.112 +2 -2 + NTP_4_2_7P111 + + sntp/sntp-opts.h@1.112 +3 -3 + NTP_4_2_7P111 + + sntp/sntp-opts.texi@1.112 +2 -2 + NTP_4_2_7P111 + + sntp/sntp.1@1.112 +2 -2 + NTP_4_2_7P111 + + sntp/sntp.html@1.112 +2 -2 + NTP_4_2_7P111 + + util/ntp-keygen-opts.c@1.110 +2 -2 + NTP_4_2_7P111 + + util/ntp-keygen-opts.h@1.110 +3 -3 + NTP_4_2_7P111 + + util/ntp-keygen-opts.texi@1.113 +2 -2 + NTP_4_2_7P111 + + util/ntp-keygen.1@1.113 +2 -2 + NTP_4_2_7P111 + +ChangeSet@1.2418, 2011-01-05 08:08:26+00:00, davehart@shiny.ad.hartbrothers.com + Quiet warnings + + libntp/ntp_calendar.c@1.6 +15 -15 + Quiet definition isn't declaration warning for now(), use + leading tabs for indents. + + libntp/ssl_init.c@1.12 +2 -2 + Quiet warning about printf formaat mismatch re: OPENSSL_VERSION_NUMBER + building against OpenSSL 1.0.0c. + +ChangeSet@1.2417, 2011-01-05 07:35:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1772] refclock_open() return value check wrong for ACTS. + Default --with-openssl-libdir and --with-openssl-incdir to the values + from pkg-config, falling back on our usual search paths if pkg-config + is not available or does not have openssl.pc on PKG_CONFIG_PATH. + Change refclock_open() to return -1 on failure like open(). + Update all refclock_open() callers to check for fd <= 0 indicating + failure, so they work with older and newer refclock_open() and can + easily backport. + Initialize refclockproc.rio.fd to -1, harmonize refclock shutdown + entrypoints to avoid crashing, particularly if refclock_open() fails. + Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. + + ChangeLog@1.755 +12 -0 + [Bug 1772] refclock_open() return value check wrong for ACTS. + Change refclock_open() to return -1 on failure like open(). + Update all refclock_open() callers to check for fd <= 0 indicating + failure, so they work with older and newer refclock_open() and can + easily backport. + Initialize refclockproc.rio.fd to -1, harmonize refclock shutdown + entrypoints to avoid crashing, particularly if refclock_open() fails. + Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. + + + include/ntp_refclock.h@1.28 +1 -2 + Remove refclock_ioctl() declaration, it's private to ntp_refclock.c + + include/ntp_stdlib.h@1.55 +11 -0 + SAVE_ERRNO(somecode();) macro + + m4/ntp_openssl.m4@1.10 +37 -3 + try pkg-config for openssl default location, then our traditional + lib and include search paths. + + ntpd/ntp_io.c@1.342 +1 -0 + initialize refclockproc.rio.fd to -1 + + ntpd/ntp_refclock.c@1.99 +72 -41 + Follow open() convention for refclock_open(), returning -1 on failure. + + ntpd/refclock_acts.c@1.43 +3 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_arbiter.c@1.18 +2 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_arc.c@1.23 +2 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_as2201.c@1.13 +2 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_bancomm.c@1.13 +1 -0 + add comment about lack of io_addclock() + + ntpd/refclock_chronolog.c@1.11 +2 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_dumbclock.c@1.17 +1 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_fg.c@1.12 +22 -24 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_heath.c@1.16 +3 -2 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_hpgps.c@1.12 +7 -8 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_irig.c@1.34 +1 -2 + minor cleanup + + ntpd/refclock_jjy.c@1.21 +2 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_jupiter.c@1.26 +2 -2 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_mx4200.c@1.28 +3 -3 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_oncore.c@1.91 +16 -11 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_palisade.c@1.37 +2 -3 + minor cleanup + + ntpd/refclock_pst.c@1.11 +2 -1 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_ripencc.c@1.15 +5 -8 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_trak.c@1.10 +7 -6 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_true.c@1.16 +11 -11 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_ulink.c@1.15 +11 -28 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_wwvb.c@1.26 +3 -3 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ntpd/refclock_zyfer.c@1.6 +11 -11 + Update refclocks to treat 0 and -1 as failure so they can backport. + + ports/winnt/libntp/termios.c@1.25 +44 -22 + Follow open() convention for refclock_open(), returning -1 on failure. + + ports/winnt/ntpd/nt_clockstuff.c@1.48 +26 -3 + Enable tickadj-like taming of wildly off-spec Windows clock using + NTPD_TICKADJ_PPM env. var. specifying baseline slew. + + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.37 +13 -25 + Add refclock_fg, refclock_ulink, refclock_zyfer.c references. + Remove reference to nonexistent refclock_usno.c + +ChangeSet@1.2416, 2011-01-04 10:07:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P110 + TAG: NTP_4_2_7P110 + + ChangeLog@1.754 +1 -0 + NTP_4_2_7P110 + + clockstuff/clktest-opts.c@1.34 +2 -2 + NTP_4_2_7P110 + + clockstuff/clktest-opts.h@1.34 +3 -3 + NTP_4_2_7P110 + + ntpd/ntpd-opts.c@1.114 +2 -2 + NTP_4_2_7P110 + + ntpd/ntpd-opts.h@1.114 +3 -3 + NTP_4_2_7P110 + + ntpd/ntpd-opts.texi@1.112 +2 -2 + NTP_4_2_7P110 + + ntpd/ntpd.1@1.112 +2 -2 + NTP_4_2_7P110 + + ntpdc/ntpdc-opts.c@1.111 +2 -2 + NTP_4_2_7P110 + + ntpdc/ntpdc-opts.h@1.111 +3 -3 + NTP_4_2_7P110 + + ntpdc/ntpdc-opts.texi@1.111 +2 -2 + NTP_4_2_7P110 + + ntpdc/ntpdc.1@1.111 +2 -2 + NTP_4_2_7P110 + + ntpq/ntpq-opts.c@1.111 +2 -2 + NTP_4_2_7P110 + + ntpq/ntpq-opts.h@1.111 +3 -3 + NTP_4_2_7P110 + + ntpq/ntpq-opts.texi@1.111 +2 -2 + NTP_4_2_7P110 + + ntpq/ntpq.1@1.111 +2 -2 + NTP_4_2_7P110 + + ntpsnmpd/ntpsnmpd-opts.c@1.111 +2 -2 + NTP_4_2_7P110 + + ntpsnmpd/ntpsnmpd-opts.h@1.111 +3 -3 + NTP_4_2_7P110 + + ntpsnmpd/ntpsnmpd-opts.texi@1.111 +2 -2 + NTP_4_2_7P110 + + ntpsnmpd/ntpsnmpd.1@1.111 +2 -2 + NTP_4_2_7P110 + + packageinfo.sh@1.112 +1 -1 + NTP_4_2_7P110 + + sntp/sntp-opts.c@1.111 +2 -2 + NTP_4_2_7P110 + + sntp/sntp-opts.h@1.111 +3 -3 + NTP_4_2_7P110 + + sntp/sntp-opts.texi@1.111 +2 -2 + NTP_4_2_7P110 + + sntp/sntp.1@1.111 +2 -2 + NTP_4_2_7P110 + + sntp/sntp.html@1.111 +2 -2 + NTP_4_2_7P110 + + util/ntp-keygen-opts.c@1.109 +2 -2 + NTP_4_2_7P110 + + util/ntp-keygen-opts.h@1.109 +3 -3 + NTP_4_2_7P110 + + util/ntp-keygen-opts.texi@1.112 +2 -2 + NTP_4_2_7P110 + + util/ntp-keygen.1@1.112 +2 -2 + NTP_4_2_7P110 + +ChangeSet@1.2415, 2011-01-04 08:47:26+00:00, davehart@shiny.ad.hartbrothers.com + don't stop the search on a prefix match in get_ext_sys_var() + + ntpd/ntp_control.c@1.158 +5 -3 + don't stop the search on a prefix match in get_ext_sys_var() + +ChangeSet@1.2414, 2011-01-04 07:06:40+00:00, davehart@shiny.ad.hartbrothers.com + make V=0 and configure --enable-silent-rules supported. + + ChangeLog@1.753 +1 -0 + make V=0 and configure --enable-silent-rules supported. + + configure.ac@1.507 +5 -0 + support make V=0 and configure --enable-silent-rules + + sntp/configure.ac@1.50 +5 -0 + support make V=0 and configure --enable-silent-rules + +ChangeSet@1.2413, 2011-01-04 06:27:59+00:00, davehart@shiny.ad.hartbrothers.com + setvar modemsetup = ATE0... overrides ACTS driver default. + Preserve last timecode in ACTS driver (ntpq -ccv). + Tolerate previous ATE1 state when sending ACTS setup. + Enable raw tty line discipline in Windows port. + Allow tty open/close/open to succeed on Windows port. + Enable ACTS and CHU reference clock drivers on Windows. + + ChangeLog@1.752 +8 -2 + setvar modemsetup = ATE0... overrides ACTS driver default. + Preserve last timecode in ACTS driver (ntpq -ccv). + Tolerate previous ATE1 state when sending ACTS setup. + Enable raw tty line discipline in Windows port. + Allow tty open/close/open to succeed on Windows port. + Enable ACTS and CHU reference clock drivers on Windows. + + + include/ntp_machine.h@1.31 +0 -17 + consolidate windows/posix compatibility shims in ntp_types.h + + include/ntp_refclock.h@1.27 +2 -1 + add active flag to struct refclockio to help dispense with pending + refclock input on Windows serial port close. + + include/ntp_types.h@1.22 +12 -1 + consolidate windows/posix compatibility shims in ntp_types.h + + include/ntpd.h@1.158 +1 -0 + add get_ext_sys_var() to retrieve value of user-defined vars + + libntp/dolfptoa.c@1.9 +3 -3 + quiet warning about signed/unsigned > comparison + + libntp/icom.c@1.14 +10 -2 + enable CHU refclock for Windows ntpd + + libntp/msyslog.c@1.31 +1 -3 + slight cleanup + + libntp/recvbuff.c@1.35 +18 -14 + cleanup + + ntpd/complete.conf@1.15 +1 -0 + add coverage for phone directive + + ntpd/ntp_config.c@1.281 +1 -1 + quote phone strings in saveconfig output + + ntpd/ntp_control.c@1.157 +30 -1 + add get_ext_sys_var() to retrieve value of user-defined vars + + ntpd/ntp_io.c@1.341 +26 -21 + add active flag to struct refclockio to help dispense with pending + refclock input on Windows serial port close. + use closeserial() instead of close() for refclock ttys for Windows' + port benefit. + + ntpd/refclock_acts.c@1.42 +96 -64 + Increment pp->polls in acts_poll(). + Change UART rate from 9600 to 19200. + Allow modem setup string override using: setvar modemsetup = ATE0... + Tolerate echo of the setup string in case ATE1 was set previously. + Buffer incomplete input lines in unit struct leaving pp->a_lastcode with + the last complete line, allowing "ntpq -c cv" to retrieve it. + Enable ACTS driver in the Windows port. + + ntpd/refclock_chu.c@1.50 +2 -2 + Enable CHU driver in the Windows port (MINCHAR in Windows .h files). + + ntpd/refclock_pcf.c@1.11 +2 -1 + attempt to avoid fault in pcf_shutdown() after unsuccessful start. + + ports/winnt/include/config.h@1.90 +3 -0 + Enable ACTS and CHU refclock drivers in Windows port. + + ports/winnt/include/termios.h@1.14 +8 -12 + Support raw line discipline and serial open/close/open in Windows port. + + ports/winnt/libntp/termios.c@1.24 +134 -40 + Support raw line discipline and serial open/close/open in Windows port. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.55 +196 -70 + Support raw line discipline and serial open/close/open in Windows port. + + ports/winnt/vc6/libntp.dsp@1.57 +4 -0 + Enable icom.c compile on Windows. + + ports/winnt/vc6/ntpd.dsp@1.52 +0 -2 + Enable ACTS and CHU refclocks on Windows. + + ports/winnt/vs2003/libntp.vcproj@1.15 +3 -0 + Enable icom.c compile on Windows. + + ports/winnt/vs2003/ntpd.vcproj@1.13 +0 -42 + Enable ACTS and CHU refclocks on Windows. + + ports/winnt/vs2005/libntp.vcproj@1.13 +4 -0 + Enable icom.c compile on Windows. + + ports/winnt/vs2005/ntpd.vcproj@1.13 +0 -40 + Enable ACTS and CHU refclocks on Windows. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.34 +2 -4 + Enable icom.c compile on Windows. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.36 +2 -6 + Enable ACTS and CHU refclocks on Windows. + +ChangeSet@1.2082.4.203, 2011-01-03 21:20:42-05:00, stenn@deacon.udel.edu + NTP_4_2_6P3 + TAG: NTP_4_2_6P3 + + ChangeLog@1.496.26.142 +1 -0 + NTP_4_2_6P3 + + ntpd/ntpd-opts.c@1.248.33.1 +5 -5 + NTP_4_2_6P3 + + ntpd/ntpd-opts.h@1.248.33.1 +4 -4 + NTP_4_2_6P3 + + ntpd/ntpd-opts.texi@1.246.33.1 +61 -2 + NTP_4_2_6P3 + + ntpd/ntpd.1@1.246.33.1 +2 -2 + NTP_4_2_6P3 + + ntpdc/ntpdc-opts.c@1.244.33.1 +5 -5 + NTP_4_2_6P3 + + ntpdc/ntpdc-opts.h@1.244.33.1 +4 -4 + NTP_4_2_6P3 + + ntpdc/ntpdc-opts.texi@1.243.33.1 +66 -2 + NTP_4_2_6P3 + + ntpdc/ntpdc.1@1.243.33.1 +2 -2 + NTP_4_2_6P3 + + ntpq/ntpq-opts.c@1.245.33.1 +5 -5 + NTP_4_2_6P3 + + ntpq/ntpq-opts.h@1.245.33.1 +4 -4 + NTP_4_2_6P3 + + ntpq/ntpq-opts.texi@1.244.33.1 +51 -2 + NTP_4_2_6P3 + + ntpq/ntpq.1@1.244.33.1 +2 -2 + NTP_4_2_6P3 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.34.1 +5 -5 + NTP_4_2_6P3 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.34.1 +4 -4 + NTP_4_2_6P3 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.34.1 +24 -2 + NTP_4_2_6P3 + + ntpsnmpd/ntpsnmpd.1@1.122.34.1 +2 -2 + NTP_4_2_6P3 + + packageinfo.sh@1.255.31.2 +3 -3 + NTP_4_2_6P3 + + sntp/sntp-opts.c@1.117.31.1 +5 -5 + NTP_4_2_6P3 + + sntp/sntp-opts.h@1.117.31.1 +4 -4 + NTP_4_2_6P3 + + sntp/sntp-opts.texi@1.117.31.1 +56 -2 + NTP_4_2_6P3 + + sntp/sntp.1@1.117.31.1 +2 -2 + NTP_4_2_6P3 + + sntp/sntp.html@1.7.32.1 +56 -2 + NTP_4_2_6P3 + + util/ntp-keygen-opts.c@1.247.33.1 +5 -5 + NTP_4_2_6P3 + + util/ntp-keygen-opts.h@1.247.33.1 +4 -4 + NTP_4_2_6P3 + + util/ntp-keygen-opts.texi@1.246.33.1 +45 -2 + NTP_4_2_6P3 + + util/ntp-keygen.1@1.246.33.1 +2 -2 + NTP_4_2_6P3 + +ChangeSet@1.2082.4.202, 2011-01-03 17:52:19-05:00, stenn@deacon.udel.edu + 4.2.6p3 + + packageinfo.sh@1.255.31.1 +1 -1 + 4.2.6p3 + +ChangeSet@1.2082.4.201, 2011-01-03 17:50:01-05:00, stenn@deacon.udel.edu + Fix release date + + NEWS@1.117 +1 -1 + Fix release date + +ChangeSet@1.2082.4.200, 2011-01-03 17:04:32-05:00, stenn@deacon.udel.edu + cleanup NEWS file for 4.2.6p3 + + NEWS@1.116 +4 -5 + cleanup + +ChangeSet@1.2411, 2011-01-03 20:19:11+01:00, jnperlin@hydra.localnet + [Bug 1771] fixed and test cases provided + + ChangeLog@1.750 +2 -0 + Bug 1771 + + include/ntp_calendar.h@1.8 +9 -0 + [Bug 1771] add 'time()' mockup facility + + libntp/clocktime.c@1.6 +10 -29 + [Bug 1771] fix algorithmic problem (result should ALWAYS be in +/- 0.5yrs around receive time) + + libntp/ntp_calendar.c@1.5 +36 -4 + [Bug 1771] add 'time()' mockup facility + + tests/libntp/caljulian.cpp@1.5 +15 -0 + [Bug 1771] use 'time()' mockup facility + + tests/libntp/calyearstart.cpp@1.3 +21 -11 + [Bug 1771] use 'time()' mockup facility + + tests/libntp/clocktime.cpp@1.3 +58 -18 + [Bug 1771] use 'time()' mockup facility, added test for 'wild' clocktime input (lengthy) + + tests/libntp/libntptest.cpp@1.2 +19 -0 + [Bug 1771] use 'time()' mockup facility + + tests/libntp/libntptest.h@1.4 +6 -0 + [Bug 1771] use 'time()' mockup facility + +ChangeSet@1.2410, 2011-01-02 10:23:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P109 + TAG: NTP_4_2_7P109 + + ChangeLog@1.749 +1 -0 + NTP_4_2_7P109 + + clockstuff/clktest-opts.c@1.33 +2 -2 + NTP_4_2_7P109 + + clockstuff/clktest-opts.h@1.33 +3 -3 + NTP_4_2_7P109 + + ntpd/ntpd-opts.c@1.113 +2 -2 + NTP_4_2_7P109 + + ntpd/ntpd-opts.h@1.113 +3 -3 + NTP_4_2_7P109 + + ntpd/ntpd-opts.texi@1.111 +2 -2 + NTP_4_2_7P109 + + ntpd/ntpd.1@1.111 +2 -2 + NTP_4_2_7P109 + + ntpdc/ntpdc-opts.c@1.110 +2 -2 + NTP_4_2_7P109 + + ntpdc/ntpdc-opts.h@1.110 +3 -3 + NTP_4_2_7P109 + + ntpdc/ntpdc-opts.texi@1.110 +2 -2 + NTP_4_2_7P109 + + ntpdc/ntpdc.1@1.110 +2 -2 + NTP_4_2_7P109 + + ntpq/ntpq-opts.c@1.110 +2 -2 + NTP_4_2_7P109 + + ntpq/ntpq-opts.h@1.110 +3 -3 + NTP_4_2_7P109 + + ntpq/ntpq-opts.texi@1.110 +2 -2 + NTP_4_2_7P109 + + ntpq/ntpq.1@1.110 +2 -2 + NTP_4_2_7P109 + + ntpsnmpd/ntpsnmpd-opts.c@1.110 +2 -2 + NTP_4_2_7P109 + + ntpsnmpd/ntpsnmpd-opts.h@1.110 +3 -3 + NTP_4_2_7P109 + + ntpsnmpd/ntpsnmpd-opts.texi@1.110 +2 -2 + NTP_4_2_7P109 + + ntpsnmpd/ntpsnmpd.1@1.110 +2 -2 + NTP_4_2_7P109 + + packageinfo.sh@1.111 +1 -1 + NTP_4_2_7P109 + + sntp/sntp-opts.c@1.110 +2 -2 + NTP_4_2_7P109 + + sntp/sntp-opts.h@1.110 +3 -3 + NTP_4_2_7P109 + + sntp/sntp-opts.texi@1.110 +2 -2 + NTP_4_2_7P109 + + sntp/sntp.1@1.110 +2 -2 + NTP_4_2_7P109 + + sntp/sntp.html@1.110 +2 -2 + NTP_4_2_7P109 + + util/ntp-keygen-opts.c@1.108 +2 -2 + NTP_4_2_7P109 + + util/ntp-keygen-opts.h@1.108 +3 -3 + NTP_4_2_7P109 + + util/ntp-keygen-opts.texi@1.111 +2 -2 + NTP_4_2_7P109 + + util/ntp-keygen.1@1.111 +2 -2 + NTP_4_2_7P109 + +ChangeSet@1.2409, 2011-01-02 09:50:53+00:00, davehart@shiny.ad.hartbrothers.com + quiet warning about n potentially used uninit in ntpq's collect_display_vdc() + + ntpq/ntpq-subs.c@1.80 +1 -0 + quiet warning about n potentially used uninit in collect_display_vdc() + +ChangeSet@1.2408, 2011-01-02 09:41:39+00:00, davehart@shiny.ad.hartbrothers.com + refactor peer_st_flags() and kstatus_to_text() to use common + data-driven loop instead of repeated macro expansions. + + include/lib_strbuf.h@1.7 +15 -15 + increase LIB_GETBUF() line limit to 128 from 80, reduce number + of buffers from 200 to 16. Reduces memory footprint from 16k + to 4k. k_st_flags() in statestr.c needs more than 80. + + include/ntp.h@1.192 +0 -6 + move TRUE/FALSE defines to ntp_types.h so lib_strbuf.h has them. + + include/ntp_stdlib.h@1.54 +3 -5 + add k_st_flags() declaration, remove declarations for three functions + apparently removed long ago. + + include/ntp_types.h@1.21 +8 -0 + move TRUE/FALSE defines to ntp_types.h so lib_strbuf.h has them. + + libntp/lib_strbuf.c@1.6 +1 -1 + increase LIB_GETBUF() line limit to 128 from 80, reduce number + of buffers from 200 to 16. Reduces memory footprint from 16k + to 4k. k_st_flags() in statestr.c needs more than 80. + + libntp/statestr.c@1.24 +140 -26 + refactor peer_st_flags() and kstatus_to_text() to use common + data-driven loop instead of repeated macro expansions. + + ntpd/ntp_control.c@1.156 +3 -133 + use common code from statestr.c for server side of ntpq -c kerninfo's + decoding of kernel loop status bits. + + ntpq/ntpq-subs.c@1.79 +2 -0 + Do not crash on an empty value in collect_display_vdc() + +ChangeSet@1.2407, 2011-01-02 06:15:33+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog was omitted accidentally from last cset + + ChangeLog@1.748 +3 -0 + Remove nearly all strcpy() and most strcat() from NTP distribution. + One major pocket remains in ntp_crypto.c. libopts & libisc also have + (safe) uses of strcpy() and strcat() remaining. + +ChangeSet@1.2406, 2011-01-02 05:13:56+00:00, davehart@shiny.ad.hartbrothers.com + Remove nearly all strcpy() and most strcat() from NTP distribution. + One major pocket remains in ntp_crypto.c. libopts & libisc also have + (safe) uses of strcpy() and strcat() remaining + + include/ntpd.h@1.157 +2 -0 + add mprintf_event() alternative to report_event() + + libntp/findconfig.c@1.4 +4 -2 + strcpy() -> strncpy() + + libntp/statestr.c@1.23 +88 -82 + get rid of strcpy(), strcat() use in statustoa() + mark constant statestr.c arrays such. + + libntp/systime.c@1.51 +10 -10 + strcpy() -> strncpy() + + ntpd/ntp_control.c@1.155 +41 -22 + add mprintf_event() alternative to report_event() + + ntpd/ntp_peer.c@1.144 +2 -7 + use mprintf_event() in a two places + + ntpd/ntp_util.c@1.90 +38 -33 + strcpy() -> strncpy() + + ntpd/refclock_arbiter.c@1.17 +3 -2 + strcpy() -> strncpy() + + ntpd/refclock_as2201.c@1.12 +9 -4 + bounds-checked strcpy() -> memcpy() + + ntpd/refclock_chu.c@1.49 +1 -1 + strcpy() -> strncpy() + + ntpd/refclock_hpgps.c@1.11 +2 -2 + bounds-checked strcpy() -> memcpy(), strcpy() -> strncpy() + + ntpd/refclock_neoclock4x.c@1.19 +9 -8 + strcpy() -> strncpy() + + ntpd/refclock_oncore.c@1.90 +2 -1 + add gcc printf format attribute to oncore_log_f declaration. + + ntpd/refclock_parse.c@1.56 +4 -3 + bounds-checked strcpy() -> memcpy() + + ntpd/refclock_true.c@1.15 +1 -1 + strcpy() -> strncpy() + + ntpdate/ntpdate.c@1.80 +6 -6 + strcpy() -> strncpy() + + ntpdc/ntpdc.c@1.91 +2 -2 + strcpy() -> strncpy() + + ntpdc/ntpdc_ops.c@1.74 +1 -1 + strcpy() -> strncpy() + + ntpq/ntpq.c@1.126 +1 -1 + strcpy() -> strncpy() + + ports/winnt/libntp/randfile.c@1.5 +1 -2 + strcpy()+strcat() -> snprintf() + +ChangeSet@1.2405, 2011-01-01 11:30:29+00:00, hart@psp-os1.ntp.org + copyright.html: + bump copyright.html for 2011 + + html/copyright.html@1.56 +2 -2 + bump copyright.html for 2011 + +ChangeSet@1.2403, 2011-01-01 06:23:20-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.747 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.18 +2 -3 + Documentation updates from Dave Mills + + html/copyright.html@1.54 +19 -1 + Documentation updates from Dave Mills + +ChangeSet@1.2402, 2011-01-01 10:32:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P108 + TAG: NTP_4_2_7P108 + + ChangeLog@1.746 +1 -0 + NTP_4_2_7P108 + + clockstuff/clktest-opts.c@1.32 +4 -4 + NTP_4_2_7P108 + + clockstuff/clktest-opts.h@1.32 +4 -4 + NTP_4_2_7P108 + + ntpd/ntpd-opts.c@1.112 +4 -4 + NTP_4_2_7P108 + + ntpd/ntpd-opts.h@1.112 +4 -4 + NTP_4_2_7P108 + + ntpd/ntpd-opts.texi@1.110 +2 -2 + NTP_4_2_7P108 + + ntpd/ntpd.1@1.110 +2 -2 + NTP_4_2_7P108 + + ntpdc/ntpdc-opts.c@1.109 +4 -4 + NTP_4_2_7P108 + + ntpdc/ntpdc-opts.h@1.109 +4 -4 + NTP_4_2_7P108 + + ntpdc/ntpdc-opts.texi@1.109 +2 -2 + NTP_4_2_7P108 + + ntpdc/ntpdc.1@1.109 +2 -2 + NTP_4_2_7P108 + + ntpq/ntpq-opts.c@1.109 +4 -4 + NTP_4_2_7P108 + + ntpq/ntpq-opts.h@1.109 +4 -4 + NTP_4_2_7P108 + + ntpq/ntpq-opts.texi@1.109 +2 -2 + NTP_4_2_7P108 + + ntpq/ntpq.1@1.109 +2 -2 + NTP_4_2_7P108 + + ntpsnmpd/ntpsnmpd-opts.c@1.109 +4 -4 + NTP_4_2_7P108 + + ntpsnmpd/ntpsnmpd-opts.h@1.109 +4 -4 + NTP_4_2_7P108 + + ntpsnmpd/ntpsnmpd-opts.texi@1.109 +2 -2 + NTP_4_2_7P108 + + ntpsnmpd/ntpsnmpd.1@1.109 +2 -2 + NTP_4_2_7P108 + + packageinfo.sh@1.110 +1 -1 + NTP_4_2_7P108 + + sntp/sntp-opts.c@1.109 +4 -4 + NTP_4_2_7P108 + + sntp/sntp-opts.h@1.109 +4 -4 + NTP_4_2_7P108 + + sntp/sntp-opts.texi@1.109 +2 -2 + NTP_4_2_7P108 + + sntp/sntp.1@1.109 +2 -2 + NTP_4_2_7P108 + + sntp/sntp.html@1.109 +2 -2 + NTP_4_2_7P108 + + util/ntp-keygen-opts.c@1.107 +4 -4 + NTP_4_2_7P108 + + util/ntp-keygen-opts.h@1.107 +4 -4 + NTP_4_2_7P108 + + util/ntp-keygen-opts.texi@1.110 +2 -2 + NTP_4_2_7P108 + + util/ntp-keygen.1@1.110 +2 -2 + NTP_4_2_7P108 + +ChangeSet@1.2082.4.199, 2011-01-01 08:35:01+00:00, hart@psp-os1.ntp.org + copyright.html: + bump copyright.html to 2011 + + html/copyright.html@1.46.1.3 +2 -2 + bump copyright.html to 2011 + +ChangeSet@1.2400, 2010-12-31 20:41:55-05:00, stenn@deacon.udel.edu + Typo cleanup from DLM's recent changes + + ntpd/ntp_control.c@1.154 +1 -1 + Typo cleanup from DLM's recent changes + + ntpd/ntp_crypto.c@1.152 +0 -1 + Typo cleanup from DLM's recent changes + +ChangeSet@1.2082.4.198, 2010-12-31 20:38:09-05:00, stenn@deacon.udel.edu + Update the copyright year + + ChangeLog@1.496.26.141 +1 -0 + Update the copyright year + + include/copyright.def@1.13 +1 -1 + Update the copyright year + +ChangeSet@1.2396.1.1, 2010-12-31 19:47:13-05:00, stenn@deacon.udel.edu + typo + + ChangeLog@1.742.1.1 +1 -1 + typo + +ChangeSet@1.2398, 2010-12-31 23:55:50+00:00, davehart@shiny.ad.hartbrothers.com + remove -dev-only remains of earlier [Bug 1764] fix from + ntpd/refclock_conf.c + + include/ntpd.h@1.156 +4 -3 + use gcc printf() format attribute in mprintf_clock_stats() decl + + ntpd/ntp_util.c@1.89 +2 -3 + fix warning about return; from mprintf_clock_stats() without value. + + ntpd/refclock_conf.c@1.31 +0 -6 + remove -dev-only remains of earlier [Bug 1764] fix + +ChangeSet@1.2082.4.197, 2010-12-31 23:12:25+00:00, davehart@shiny.ad.hartbrothers.com + Test for modem control just once in configure.ac + + configure.ac@1.465.1.26 +39 -45 + Test for modem control support just once + + include/ntpd.h@1.137.2.5 +2 -1 + make refclock_conf[] pointers const + + ntpd/refclock_conf.c@1.28.1.2 +2 -2 + make refclock_conf[] pointers const + +ChangeSet@1.2396, 2010-12-31 17:34:44-05:00, stenn@deacon.udel.edu + Autokey multiple identity group improvements from Dave Mills + + ChangeLog@1.742 +1 -0 + Autokey multiple identity group improvements from Dave Mills + + html/authopt.html@1.69 +11 -8 + Autokey multiple identity group improvements from Dave Mills + + html/confopt.html@1.55 +2 -2 + Autokey multiple identity group improvements from Dave Mills + + ntpd/ntp_control.c@1.153 +2 -2 + Autokey multiple identity group improvements from Dave Mills + + ntpd/ntp_crypto.c@1.151 +24 -19 + Autokey multiple identity group improvements from Dave Mills + + util/ntp-keygen.c@1.73 +3 -8 + Autokey multiple identity group improvements from Dave Mills + +ChangeSet@1.2395, 2010-12-31 17:29:22-05:00, stenn@deacon.udel.edu + [Bug 1768] TIOCFLUSH undefined in linux for refclock_acts + + ChangeLog@1.741 +1 -0 + [Bug 1768] TIOCFLUSH undefined in linux for refclock_acts + + ntpd/refclock_acts.c@1.41 +47 -29 + [Bug 1768] TIOCFLUSH undefined in linux for refclock_acts + +ChangeSet@1.2082.4.196, 2010-12-31 16:28:55-05:00, murray@malarky.udel.edu + refclock_conf.c, configure.ac, refclock_palisade.c, ChangeLog: + [Bug 1764] Palisade driver doesn't build on Linux. (cleanup) + + ChangeLog@1.496.26.140 +1 -0 + [Bug 1764] Palisade driver doesn't build on Linux. (cleanup) + + configure.ac@1.465.1.25 +16 -9 + [Bug 1764] Palisade driver doesn't build on Linux. (cleanup) + + ntpd/refclock_conf.c@1.28.1.1 +1 -1 + [Bug 1764] Palisade driver doesn't build on Linux. (cleanup) + + ntpd/refclock_palisade.c@1.31.1.3 +0 -5 + [Bug 1764] Palisade driver doesn't build on Linux. (cleanup) + +ChangeSet@1.2394, 2010-12-31 10:50:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P107 + TAG: NTP_4_2_7P107 + + ChangeLog@1.740 +1 -0 + NTP_4_2_7P107 + + clockstuff/clktest-opts.c@1.31 +2 -2 + NTP_4_2_7P107 + + clockstuff/clktest-opts.h@1.31 +3 -3 + NTP_4_2_7P107 + + ntpd/ntpd-opts.c@1.111 +2 -2 + NTP_4_2_7P107 + + ntpd/ntpd-opts.h@1.111 +3 -3 + NTP_4_2_7P107 + + ntpd/ntpd-opts.texi@1.109 +2 -2 + NTP_4_2_7P107 + + ntpd/ntpd.1@1.109 +2 -2 + NTP_4_2_7P107 + + ntpdc/ntpdc-opts.c@1.108 +2 -2 + NTP_4_2_7P107 + + ntpdc/ntpdc-opts.h@1.108 +3 -3 + NTP_4_2_7P107 + + ntpdc/ntpdc-opts.texi@1.108 +2 -2 + NTP_4_2_7P107 + + ntpdc/ntpdc.1@1.108 +2 -2 + NTP_4_2_7P107 + + ntpq/ntpq-opts.c@1.108 +2 -2 + NTP_4_2_7P107 + + ntpq/ntpq-opts.h@1.108 +3 -3 + NTP_4_2_7P107 + + ntpq/ntpq-opts.texi@1.108 +2 -2 + NTP_4_2_7P107 + + ntpq/ntpq.1@1.108 +2 -2 + NTP_4_2_7P107 + + ntpsnmpd/ntpsnmpd-opts.c@1.108 +2 -2 + NTP_4_2_7P107 + + ntpsnmpd/ntpsnmpd-opts.h@1.108 +3 -3 + NTP_4_2_7P107 + + ntpsnmpd/ntpsnmpd-opts.texi@1.108 +2 -2 + NTP_4_2_7P107 + + ntpsnmpd/ntpsnmpd.1@1.108 +2 -2 + NTP_4_2_7P107 + + packageinfo.sh@1.109 +1 -1 + NTP_4_2_7P107 + + sntp/sntp-opts.c@1.108 +2 -2 + NTP_4_2_7P107 + + sntp/sntp-opts.h@1.108 +3 -3 + NTP_4_2_7P107 + + sntp/sntp-opts.texi@1.108 +2 -2 + NTP_4_2_7P107 + + sntp/sntp.1@1.108 +2 -2 + NTP_4_2_7P107 + + sntp/sntp.html@1.108 +2 -2 + NTP_4_2_7P107 + + util/ntp-keygen-opts.c@1.106 +2 -2 + NTP_4_2_7P107 + + util/ntp-keygen-opts.h@1.106 +3 -3 + NTP_4_2_7P107 + + util/ntp-keygen-opts.texi@1.109 +2 -2 + NTP_4_2_7P107 + + util/ntp-keygen.1@1.109 +2 -2 + NTP_4_2_7P107 + +ChangeSet@1.2393, 2010-12-31 01:45:11-05:00, stenn@deacon.udel.edu + refclock_acts.c updates from Dave Mills + + ChangeLog@1.739 +1 -0 + refclock_acts.c updates from Dave Mills + + ntpd/refclock_acts.c@1.40 +335 -380 + refclock_acts.c updates from Dave Mills + +ChangeSet@1.2392, 2010-12-31 03:31:28+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1766] Oncore clock has offset/high jitter at startup. + + ChangeLog@1.738 +1 -0 + [Bug 1766] Oncore clock has offset/high jitter at startup. + + include/ntp_stdlib.h@1.53 +2 -2 + correct return types of mvsnprintf() and msnprintf() to match + vsnprintf() and snprintf(). + + include/ntpd.h@1.154 +1 -0 + add mprintf_clock_stats() vararg alternative to record_clock_stats() + + libntp/msyslog.c@1.30 +9 -3 + correct return types of mvsnprintf() and msnprintf() to match + vsnprintf() and snprintf(). + + ntpd/ntp_util.c@1.88 +25 -0 + add mprintf_clock_stats() vararg alternative to record_clock_stats() + + ntpd/refclock_oncore.c@1.89 +263 -358 + [Bug 1766] Oncore clock has offset/high jitter at startup. + + ntpd/refclock_parse.c@1.55 +1 -1 + eliminate warning + +ChangeSet@1.2389.1.1, 2010-12-30 10:52:24+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1764] Palisade driver doesn't build on Linux. + Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. + + ChangeLog@1.735.1.1 +4 -0 + [Bug 1764] Palisade driver doesn't build on Linux. + Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. + + include/ntp_control.h@1.55 +0 -178 + Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. + + libntp/refnumtoa.c@1.10 +12 -13 + make refnumtoa() return socktoa() for non-refclock addresses to + simplify ntpq peers billboard use. + + ntpd/ntp_control.c@1.152 +178 -0 + Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. + + ntpd/ntp_io.c@1.340 +2 -1 + Do not log an error if setsockopt(IPV6_MULTICAST_IF) returns an error and + the ifindex we attempted to set is already the scope in the bound address. + + ntpd/refclock_conf.c@1.29 +6 -0 + [Bug 1764] Palisade driver doesn't build on Linux. + + ntpd/refclock_palisade.c@1.35 +3 -0 + [Bug 1764] Palisade driver doesn't build on Linux. + + ntpq/ntpq-subs.c@1.78 +46 -123 + Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. + + ntpq/ntpq.c@1.125 +124 -290 + Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. + + ntpq/ntpq.h@1.23 +5 -8 + Move ntp_control.h variable IDs to ntp_control.c, remove their use by + ntpq. They are implementation details private to ntpd. [Bug 597] was + caused by ntpq's reliance on these IDs it need not know about. + +ChangeSet@1.2390, 2010-12-30 10:32:31+00:00, stenn@deacon.udel.edu + NTP_4_2_7P106 + TAG: NTP_4_2_7P106 + + ChangeLog@1.736 +1 -0 + NTP_4_2_7P106 + + clockstuff/clktest-opts.c@1.30 +2 -2 + NTP_4_2_7P106 + + clockstuff/clktest-opts.h@1.30 +3 -3 + NTP_4_2_7P106 + + ntpd/ntpd-opts.c@1.110 +2 -2 + NTP_4_2_7P106 + + ntpd/ntpd-opts.h@1.110 +3 -3 + NTP_4_2_7P106 + + ntpd/ntpd-opts.texi@1.108 +2 -2 + NTP_4_2_7P106 + + ntpd/ntpd.1@1.108 +2 -2 + NTP_4_2_7P106 + + ntpdc/ntpdc-opts.c@1.107 +2 -2 + NTP_4_2_7P106 + + ntpdc/ntpdc-opts.h@1.107 +3 -3 + NTP_4_2_7P106 + + ntpdc/ntpdc-opts.texi@1.107 +2 -2 + NTP_4_2_7P106 + + ntpdc/ntpdc.1@1.107 +2 -2 + NTP_4_2_7P106 + + ntpq/ntpq-opts.c@1.107 +2 -2 + NTP_4_2_7P106 + + ntpq/ntpq-opts.h@1.107 +3 -3 + NTP_4_2_7P106 + + ntpq/ntpq-opts.texi@1.107 +2 -2 + NTP_4_2_7P106 + + ntpq/ntpq.1@1.107 +2 -2 + NTP_4_2_7P106 + + ntpsnmpd/ntpsnmpd-opts.c@1.107 +2 -2 + NTP_4_2_7P106 + + ntpsnmpd/ntpsnmpd-opts.h@1.107 +3 -3 + NTP_4_2_7P106 + + ntpsnmpd/ntpsnmpd-opts.texi@1.107 +2 -2 + NTP_4_2_7P106 + + ntpsnmpd/ntpsnmpd.1@1.107 +2 -2 + NTP_4_2_7P106 + + packageinfo.sh@1.108 +1 -1 + NTP_4_2_7P106 + + sntp/sntp-opts.c@1.107 +2 -2 + NTP_4_2_7P106 + + sntp/sntp-opts.h@1.107 +3 -3 + NTP_4_2_7P106 + + sntp/sntp-opts.texi@1.107 +2 -2 + NTP_4_2_7P106 + + sntp/sntp.1@1.107 +2 -2 + NTP_4_2_7P106 + + sntp/sntp.html@1.107 +2 -2 + NTP_4_2_7P106 + + util/ntp-keygen-opts.c@1.105 +2 -2 + NTP_4_2_7P106 + + util/ntp-keygen-opts.h@1.105 +3 -3 + NTP_4_2_7P106 + + util/ntp-keygen-opts.texi@1.108 +2 -2 + NTP_4_2_7P106 + + util/ntp-keygen.1@1.108 +2 -2 + NTP_4_2_7P106 + +ChangeSet@1.2082.4.195, 2010-12-29 19:24:12-05:00, stenn@deacon.udel.edu + Update genCommitLog for the bk-5 release + + ChangeLog@1.496.26.139 +1 -0 + Update genCommitLog for the bk-5 release + + scripts/genCommitLog@1.5.1.2 +1 -1 + Update genCommitLog for the bk-5 release + +ChangeSet@1.2388, 2010-12-29 08:13:01+00:00, stenn@deacon.udel.edu + NTP_4_2_7P105 + TAG: NTP_4_2_7P105 + + ChangeLog@1.734 +1 -0 + NTP_4_2_7P105 + + clockstuff/clktest-opts.c@1.29 +2 -2 + NTP_4_2_7P105 + + clockstuff/clktest-opts.h@1.29 +3 -3 + NTP_4_2_7P105 + + ntpd/ntpd-opts.c@1.109 +2 -2 + NTP_4_2_7P105 + + ntpd/ntpd-opts.h@1.109 +3 -3 + NTP_4_2_7P105 + + ntpd/ntpd-opts.texi@1.107 +2 -2 + NTP_4_2_7P105 + + ntpd/ntpd.1@1.107 +2 -2 + NTP_4_2_7P105 + + ntpdc/ntpdc-opts.c@1.106 +2 -2 + NTP_4_2_7P105 + + ntpdc/ntpdc-opts.h@1.106 +3 -3 + NTP_4_2_7P105 + + ntpdc/ntpdc-opts.texi@1.106 +2 -2 + NTP_4_2_7P105 + + ntpdc/ntpdc.1@1.106 +2 -2 + NTP_4_2_7P105 + + ntpq/ntpq-opts.c@1.106 +2 -2 + NTP_4_2_7P105 + + ntpq/ntpq-opts.h@1.106 +3 -3 + NTP_4_2_7P105 + + ntpq/ntpq-opts.texi@1.106 +2 -2 + NTP_4_2_7P105 + + ntpq/ntpq.1@1.106 +2 -2 + NTP_4_2_7P105 + + ntpsnmpd/ntpsnmpd-opts.c@1.106 +2 -2 + NTP_4_2_7P105 + + ntpsnmpd/ntpsnmpd-opts.h@1.106 +3 -3 + NTP_4_2_7P105 + + ntpsnmpd/ntpsnmpd-opts.texi@1.106 +2 -2 + NTP_4_2_7P105 + + ntpsnmpd/ntpsnmpd.1@1.106 +2 -2 + NTP_4_2_7P105 + + packageinfo.sh@1.107 +1 -1 + NTP_4_2_7P105 + + sntp/sntp-opts.c@1.106 +2 -2 + NTP_4_2_7P105 + + sntp/sntp-opts.h@1.106 +3 -3 + NTP_4_2_7P105 + + sntp/sntp-opts.texi@1.106 +56 -2 + NTP_4_2_7P105 + + sntp/sntp.1@1.106 +2 -2 + NTP_4_2_7P105 + + sntp/sntp.html@1.106 +56 -2 + NTP_4_2_7P105 + + util/ntp-keygen-opts.c@1.104 +2 -2 + NTP_4_2_7P105 + + util/ntp-keygen-opts.h@1.104 +3 -3 + NTP_4_2_7P105 + + util/ntp-keygen-opts.texi@1.107 +2 -2 + NTP_4_2_7P105 + + util/ntp-keygen.1@1.107 +2 -2 + NTP_4_2_7P105 + +ChangeSet@1.2082.4.194, 2010-12-29 02:06:21-05:00, stenn@deacon.udel.edu + Distribute check--help from the correct variable + + scripts/Makefile.am@1.17.1.4 +1 -1 + Distribute check--help from the correct variable + +ChangeSet@1.2386, 2010-12-28 09:37:12+00:00, stenn@deacon.udel.edu + NTP_4_2_7P104 + TAG: NTP_4_2_7P104 + + ChangeLog@1.733 +1 -0 + NTP_4_2_7P104 + + clockstuff/clktest-opts.c@1.28 +2 -2 + NTP_4_2_7P104 + + clockstuff/clktest-opts.h@1.28 +3 -3 + NTP_4_2_7P104 + + ntpd/ntpd-opts.c@1.108 +2 -2 + NTP_4_2_7P104 + + ntpd/ntpd-opts.h@1.108 +3 -3 + NTP_4_2_7P104 + + ntpd/ntpd-opts.texi@1.106 +75 -2 + NTP_4_2_7P104 + + ntpd/ntpd.1@1.106 +2 -2 + NTP_4_2_7P104 + + ntpdc/ntpdc-opts.c@1.105 +2 -2 + NTP_4_2_7P104 + + ntpdc/ntpdc-opts.h@1.105 +3 -3 + NTP_4_2_7P104 + + ntpdc/ntpdc-opts.texi@1.105 +66 -2 + NTP_4_2_7P104 + + ntpdc/ntpdc.1@1.105 +2 -2 + NTP_4_2_7P104 + + ntpq/ntpq-opts.c@1.105 +2 -2 + NTP_4_2_7P104 + + ntpq/ntpq-opts.h@1.105 +3 -3 + NTP_4_2_7P104 + + ntpq/ntpq-opts.texi@1.105 +51 -2 + NTP_4_2_7P104 + + ntpq/ntpq.1@1.105 +2 -2 + NTP_4_2_7P104 + + ntpsnmpd/ntpsnmpd-opts.c@1.105 +2 -2 + NTP_4_2_7P104 + + ntpsnmpd/ntpsnmpd-opts.h@1.105 +3 -3 + NTP_4_2_7P104 + + ntpsnmpd/ntpsnmpd-opts.texi@1.105 +24 -2 + NTP_4_2_7P104 + + ntpsnmpd/ntpsnmpd.1@1.105 +2 -2 + NTP_4_2_7P104 + + packageinfo.sh@1.106 +1 -1 + NTP_4_2_7P104 + + sntp/sntp-opts.c@1.105 +2 -2 + NTP_4_2_7P104 + + sntp/sntp-opts.h@1.105 +3 -3 + NTP_4_2_7P104 + + sntp/sntp-opts.texi@1.105 +1 -1 + NTP_4_2_7P104 + + sntp/sntp.1@1.105 +2 -2 + NTP_4_2_7P104 + + sntp/sntp.html@1.105 +1 -1 + NTP_4_2_7P104 + + util/ntp-keygen-opts.c@1.103 +2 -2 + NTP_4_2_7P104 + + util/ntp-keygen-opts.h@1.103 +3 -3 + NTP_4_2_7P104 + + util/ntp-keygen-opts.texi@1.106 +46 -2 + NTP_4_2_7P104 + + util/ntp-keygen.1@1.106 +2 -2 + NTP_4_2_7P104 + +ChangeSet@1.2082.4.193, 2010-12-28 04:20:11-05:00, stenn@deacon.udel.edu + Fix location of check--help for sntp + + sntp/Makefile.am@1.21.1.16 +1 -1 + Fix location of check--help for sntp + +ChangeSet@1.2385, 2010-12-28 04:17:05-05:00, stenn@deacon.udel.edu + Fix location of check--help for sntp + + sntp/Makefile.am@1.46 +1 -1 + Fix location of check--help for sntp + +ChangeSet@1.2082.4.192, 2010-12-28 03:30:18-05:00, stenn@deacon.udel.edu + typo + + scripts/check--help@1.2 +1 -1 + typo + +ChangeSet@1.2082.4.191, 2010-12-28 03:16:01-05:00, stenn@deacon.udel.edu + Create and use scripts/check--help when generating .texi files + + ChangeLog@1.496.26.138 +2 -0 + Create and use scripts/check--help when generating .texi files + + ntpd/Makefile.am@1.80.1.8 +1 -0 + Create and use scripts/check--help when generating .texi files + + ntpdc/Makefile.am@1.48.1.5 +1 -0 + Create and use scripts/check--help when generating .texi files + + ntpq/Makefile.am@1.43.1.5 +1 -0 + Create and use scripts/check--help when generating .texi files + + ntpsnmpd/Makefile.am@1.16.1.5 +1 -0 + Create and use scripts/check--help when generating .texi files + + scripts/Makefile.am@1.17.1.3 +1 -0 + Create and use scripts/check--help when generating .texi files + + scripts/check--help@1.1 +22 -0 + BitKeeper file /deacon/backroom/ntp-stable/scripts/check--help + + scripts/check--help@1.0 +0 -0 + + sntp/Makefile.am@1.21.1.15 +1 -0 + Create and use scripts/check--help when generating .texi files + + util/Makefile.am@1.45.1.6 +1 -0 + Create and use scripts/check--help when generating .texi files + +ChangeSet@1.2382, 2010-12-28 01:35:52-05:00, stenn@deacon.udel.edu + Support for multiple Autokey identity groups from Dave Mills + + ChangeLog@1.730 +2 -0 + Support for multiple Autokey identity groups from Dave Mills + + html/autokey.html@1.17 +8 -44 + Support for multiple Autokey identity groups from Dave Mills + + include/ntp_control.h@1.54 +1 -1 + Support for multiple Autokey identity groups from Dave Mills + + include/ntpd.h@1.153 +1 -0 + Support for multiple Autokey identity groups from Dave Mills + + ntpd/ntp_config.c@1.280 +1 -1 + Support for multiple Autokey identity groups from Dave Mills + + ntpd/ntp_control.c@1.151 +6 -6 + Support for multiple Autokey identity groups from Dave Mills + + ntpd/ntp_crypto.c@1.150 +48 -58 + Support for multiple Autokey identity groups from Dave Mills + + ntpd/ntp_proto.c@1.315 +5 -4 + Support for multiple Autokey identity groups from Dave Mills + +ChangeSet@1.2082.4.190, 2010-12-28 01:22:04-05:00, stenn@deacon.udel.edu + Update bk triggers for the bk-5 release + + BitKeeper/triggers/post-incoming.license-warn@1.8 +3 -0 + Update bk triggers for the bk-5 release + + BitKeeper/triggers/pre-resolve.license-chk@1.9 +3 -0 + Update bk triggers for the bk-5 release + + BitKeeper/triggers/send@1.15 +2 -2 + Update bk triggers for the bk-5 release + + ChangeLog@1.496.26.137 +3 -0 + Update bk triggers for the bk-5 release + +ChangeSet@1.2381, 2010-12-27 21:29:19+00:00, davehart@shiny.ad.hartbrothers.com + Add ntpq kerninfo command similar to ntpdc's. + + ChangeLog@1.729 +1 -2 + Add ntpq kerninfo, authinfo, and sysinfo commands similar to ntpdc's. + + include/ntp_control.h@1.53 +19 -1 + Add variables needed by ntpq -c kerninfo + + include/ntp_stdlib.h@1.52 +1 -1 + make socktohost() return const char * now that stoa() and friends do. + + include/ntpd.h@1.152 +1 -1 + make stoa() clone localaddrtoa() return const char * as socktoa() now does. + + libntp/socktohost.c@1.11 +1 -1 + make socktohost() return const char * now that stoa() and friends do. + + ntpd/ntp_control.c@1.150 +410 -84 + Add variables needed by ntpq -c kerninfo + + ntpd/ntp_io.c@1.339 +2 -2 + make stoa() clone localaddrtoa() return const char * as socktoa() now does. + + ntpd/ntp_request.c@1.101 +4 -4 + declare constant tables using const. + + ntpdate/ntpdate.c@1.79 +1 -1 + respect const stoa() + + ntpdc/ntpdc.c@1.90 +1 -1 + make nntohost() return const char * now that stao() and friends do. + + ntpdc/ntpdc.h@1.10 +1 -1 + make nntohost() return const char * now that stao() and friends do. + + ntpdc/ntpdc_ops.c@1.73 +4 -4 + correct kerninfo maxerror/esterror scaling + + ntpq/ntpq-subs.c@1.77 +53 -7 + Add ntpq kerninfo command similar to ntpdc's. + + ntpq/ntpq.c@1.124 +5 -5 + make nntohost() const char * to match similar change to stoa() etc. + + ntpq/ntpq.h@1.22 +2 -2 + make nntohost() const char * to match similar change to stoa() etc. + + sntp/kod_management.c@1.22 +8 -9 + quiet sntp/tests deprecated conversion from string constant to char * + warnings by making search_entry(), add_entry(), and del_entry() + hostname args const char *. + + sntp/kod_management.h@1.9 +3 -4 + quiet sntp/tests deprecated conversion from string constant to char * + warnings by making search_entry(), add_entry(), and del_entry() + hostname args const char *. + +ChangeSet@1.2380, 2010-12-25 23:34:57+00:00, davehart@shiny.ad.hartbrothers.com + Add ntpq authinfo command, similar to ntpdc's authinfo. + + ChangeLog@1.728 +1 -0 + Add ntpq authinfo command, similar to ntpdc's authinfo. + + include/ntp_control.h@1.52 +10 -1 + add variables for ntpq -c authinfo + + include/ntpd.h@1.151 +1 -0 + extern auth_timereset from ntp_request.c + + ntpd/ntp_control.c@1.149 +47 -1 + add variables for ntpq -c authinfo + + ntpd/ntp_request.c@1.100 +1 -1 + extern auth_timereset from ntp_request.c + + ntpq/ntpq-subs.c@1.76 +31 -1 + Add ntpq authinfo command, similar to ntpdc's authinfo. + +ChangeSet@1.2082.4.189, 2010-12-25 16:24:06-05:00, stenn@deacon.udel.edu + Fix typo in NEWS file + + NEWS@1.115 +1 -1 + Fix typo in NEWS file + +ChangeSet@1.2082.4.188, 2010-12-25 10:23:24+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC12 + TAG: NTP_4_2_6P3_RC12 + + ChangeLog@1.496.26.136 +1 -0 + NTP_4_2_6P3_RC12 + + ntpd/ntpd-opts.c@1.248.32.1 +5 -5 + NTP_4_2_6P3_RC12 + + ntpd/ntpd-opts.h@1.248.32.1 +4 -4 + NTP_4_2_6P3_RC12 + + ntpd/ntpd-opts.texi@1.246.32.1 +2 -61 + NTP_4_2_6P3_RC12 + + ntpd/ntpd.1@1.246.32.1 +2 -2 + NTP_4_2_6P3_RC12 + + ntpdc/ntpdc-opts.c@1.244.32.1 +5 -5 + NTP_4_2_6P3_RC12 + + ntpdc/ntpdc-opts.h@1.244.32.1 +4 -4 + NTP_4_2_6P3_RC12 + + ntpdc/ntpdc-opts.texi@1.243.32.1 +2 -66 + NTP_4_2_6P3_RC12 + + ntpdc/ntpdc.1@1.243.32.1 +2 -2 + NTP_4_2_6P3_RC12 + + ntpq/ntpq-opts.c@1.245.32.1 +5 -5 + NTP_4_2_6P3_RC12 + + ntpq/ntpq-opts.h@1.245.32.1 +4 -4 + NTP_4_2_6P3_RC12 + + ntpq/ntpq-opts.texi@1.244.32.1 +2 -51 + NTP_4_2_6P3_RC12 + + ntpq/ntpq.1@1.244.32.1 +2 -2 + NTP_4_2_6P3_RC12 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.33.1 +5 -5 + NTP_4_2_6P3_RC12 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.33.1 +4 -4 + NTP_4_2_6P3_RC12 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.33.1 +1 -1 + NTP_4_2_6P3_RC12 + + ntpsnmpd/ntpsnmpd.1@1.122.33.1 +2 -2 + NTP_4_2_6P3_RC12 + + packageinfo.sh@1.255.30.1 +1 -1 + NTP_4_2_6P3_RC12 + + sntp/sntp-opts.c@1.117.30.1 +5 -5 + NTP_4_2_6P3_RC12 + + sntp/sntp-opts.h@1.117.30.1 +4 -4 + NTP_4_2_6P3_RC12 + + sntp/sntp-opts.texi@1.117.30.1 +6 -59 + NTP_4_2_6P3_RC12 + + sntp/sntp.1@1.117.30.1 +8 -4 + NTP_4_2_6P3_RC12 + + sntp/sntp.html@1.7.31.1 +6 -59 + NTP_4_2_6P3_RC12 + + util/ntp-keygen-opts.c@1.247.32.1 +5 -5 + NTP_4_2_6P3_RC12 + + util/ntp-keygen-opts.h@1.247.32.1 +4 -4 + NTP_4_2_6P3_RC12 + + util/ntp-keygen-opts.texi@1.246.32.1 +2 -45 + NTP_4_2_6P3_RC12 + + util/ntp-keygen.1@1.246.32.1 +2 -2 + NTP_4_2_6P3_RC12 + +ChangeSet@1.2082.4.187, 2010-12-25 04:14:17-05:00, stenn@deacon.udel.edu + RC12 NEWS updates + + NEWS@1.114 +23 -4 + RC12 NEWS updates + +ChangeSet@1.2379, 2010-12-25 06:12:51+00:00, davehart@shiny.ad.hartbrothers.com + Add ntpq sysinfo command, similar to ntpdc's sysinfo. + + ChangeLog@1.727 +1 -0 + Add ntpq sysinfo command, similar to ntpdc's sysinfo. + + include/ntp_control.h@1.51 +5 -1 + add variables needed by ntpq -c sysinfo + + include/ntp_stdlib.h@1.51 +4 -3 + make stoa() and friends return const char * + + libntp/modetoa.c@1.5 +1 -1 + make modestrings[] pointers const + + libntp/numtoa.c@1.6 +26 -0 + add refid_str() using code lifted from ntp_control.c + + libntp/refnumtoa.c@1.9 +4 -4 + make stoa() and friends return const char * + + libntp/socktoa.c@1.15 +2 -2 + make stoa() and friends return const char * + + ntpd/ntp_control.c@1.148 +44 -14 + add variables needed by ntpq -c sysinfo + + ntpd/ntp_request.c@1.99 +1 -1 + ntpdc -c sysinfo stability units are supposed to be ppm but were s/s + + ntpdc/ntpdc_ops.c@1.72 +5 -5 + correct bug in last change to print_pflag() + + ntpq/ntpq-subs.c@1.75 +94 -20 + Add ntpq sysinfo command, similar to ntpdc's sysinfo. + + ntpq/ntpq.h@1.21 +4 -0 + Add ntpq sysinfo command, similar to ntpdc's sysinfo. + + sntp/networking.c@1.46 +1 -1 + Silence warnings about deprecated conversion from string constant to + char *. + + sntp/networking.h@1.22 +2 -1 + Silence warnings about deprecated conversion from string constant to + char *. + +ChangeSet@1.2378, 2010-12-24 09:44:20+00:00, stenn@deacon.udel.edu + NTP_4_2_7P103 + TAG: NTP_4_2_7P103 + + ChangeLog@1.726 +1 -0 + NTP_4_2_7P103 + + clockstuff/clktest-opts.c@1.27 +2 -2 + NTP_4_2_7P103 + + clockstuff/clktest-opts.h@1.27 +3 -3 + NTP_4_2_7P103 + + ntpd/ntpd-opts.c@1.107 +2 -2 + NTP_4_2_7P103 + + ntpd/ntpd-opts.h@1.107 +3 -3 + NTP_4_2_7P103 + + ntpd/ntpd-opts.texi@1.105 +1 -1 + NTP_4_2_7P103 + + ntpd/ntpd.1@1.105 +2 -2 + NTP_4_2_7P103 + + ntpdc/ntpdc-opts.c@1.104 +2 -2 + NTP_4_2_7P103 + + ntpdc/ntpdc-opts.h@1.104 +3 -3 + NTP_4_2_7P103 + + ntpdc/ntpdc-opts.texi@1.104 +1 -1 + NTP_4_2_7P103 + + ntpdc/ntpdc.1@1.104 +2 -2 + NTP_4_2_7P103 + + ntpq/ntpq-opts.c@1.104 +2 -2 + NTP_4_2_7P103 + + ntpq/ntpq-opts.h@1.104 +3 -3 + NTP_4_2_7P103 + + ntpq/ntpq-opts.texi@1.104 +1 -1 + NTP_4_2_7P103 + + ntpq/ntpq.1@1.104 +2 -2 + NTP_4_2_7P103 + + ntpsnmpd/ntpsnmpd-opts.c@1.104 +2 -2 + NTP_4_2_7P103 + + ntpsnmpd/ntpsnmpd-opts.h@1.104 +3 -3 + NTP_4_2_7P103 + + ntpsnmpd/ntpsnmpd-opts.texi@1.104 +1 -1 + NTP_4_2_7P103 + + ntpsnmpd/ntpsnmpd.1@1.104 +2 -2 + NTP_4_2_7P103 + + packageinfo.sh@1.105 +1 -1 + NTP_4_2_7P103 + + sntp/sntp-opts.c@1.104 +2 -2 + NTP_4_2_7P103 + + sntp/sntp-opts.h@1.104 +3 -3 + NTP_4_2_7P103 + + sntp/sntp-opts.texi@1.104 +1 -1 + NTP_4_2_7P103 + + sntp/sntp.1@1.104 +2 -2 + NTP_4_2_7P103 + + sntp/sntp.html@1.104 +1 -1 + NTP_4_2_7P103 + + util/ntp-keygen-opts.c@1.102 +2 -2 + NTP_4_2_7P103 + + util/ntp-keygen-opts.h@1.102 +3 -3 + NTP_4_2_7P103 + + util/ntp-keygen-opts.texi@1.105 +1 -1 + NTP_4_2_7P103 + + util/ntp-keygen.1@1.105 +2 -2 + NTP_4_2_7P103 + +ChangeSet@1.2377, 2010-12-24 04:03:04-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.725 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.16 +33 -40 + Documentation updates from Dave Mills + +ChangeSet@1.2376, 2010-12-24 08:05:27+00:00, davehart@shiny.ad.hartbrothers.com + Add ntpq pstats command similar to ntpdc's. + Remove ntpq pstatus command, rv/readvar does the same and more. + + ChangeLog@1.724 +2 -0 + Add ntpq pstats command similar to ntpdc's. + Remove ntpq pstatus command, rv/readvar does the same and more. + + include/ntp_control.h@1.50 +9 -1 + add peer variables needed for ntpq -c "pstats &1" similar to + ntpdc -c "pstats 127.127.20.0". + + libntp/statestr.c@1.22 +4 -4 + correct switch/case indents. + + ntpd/ntp_control.c@1.147 +59 -16 + add peer variables needed for ntpq -c "pstats &1" similar to + ntpdc -c "pstats 127.127.20.0". + + ntpdc/ntpdc_ops.c@1.71 +47 -40 + repair print_pflag() removing inappropriate bclient, add missing flags. + + ntpq/ntpq-subs.c@1.74 +120 -62 + Add ntpq pstats command similar to ntpdc's. + Remove ntpq pstatus command, rv/readvar does the same and more. + + ntpq/ntpq.c@1.123 +24 -0 + add nntohostp() like nntohost() but including port. + + ntpq/ntpq.h@1.20 +1 -0 + add nntohostp() + +ChangeSet@1.2372.1.1, 2010-12-23 19:18:14+00:00, davehart@shiny.ad.hartbrothers.com + Correct ntpq handling of &1 with multiple servers on cmd line. + + include/ntp_calendar.h@1.7 +6 -5 + make pointers in months[] and daynames[] const + + libntp/prettydate.c@1.18 +2 -2 + make pointers in months[] and daynames[] const + + ntpq/ntpq-subs.c@1.73 +2 -2 + clean up signed/unsigned comparison warnings + + ntpq/ntpq.c@1.122 +10 -16 + Correct ntpq handling of &1 with multiple servers on cmd line. + +ChangeSet@1.2374, 2010-12-23 11:12:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P102 + TAG: NTP_4_2_7P102 + + ChangeLog@1.723 +1 -0 + NTP_4_2_7P102 + + clockstuff/clktest-opts.c@1.26 +2 -2 + NTP_4_2_7P102 + + clockstuff/clktest-opts.h@1.26 +3 -3 + NTP_4_2_7P102 + + ntpd/ntpd-opts.c@1.106 +2 -2 + NTP_4_2_7P102 + + ntpd/ntpd-opts.h@1.106 +3 -3 + NTP_4_2_7P102 + + ntpd/ntpd-opts.texi@1.104 +1 -1 + NTP_4_2_7P102 + + ntpd/ntpd.1@1.104 +2 -2 + NTP_4_2_7P102 + + ntpdc/ntpdc-opts.c@1.103 +2 -2 + NTP_4_2_7P102 + + ntpdc/ntpdc-opts.h@1.103 +3 -3 + NTP_4_2_7P102 + + ntpdc/ntpdc-opts.texi@1.103 +1 -1 + NTP_4_2_7P102 + + ntpdc/ntpdc.1@1.103 +2 -2 + NTP_4_2_7P102 + + ntpq/ntpq-opts.c@1.103 +2 -2 + NTP_4_2_7P102 + + ntpq/ntpq-opts.h@1.103 +3 -3 + NTP_4_2_7P102 + + ntpq/ntpq-opts.texi@1.103 +1 -1 + NTP_4_2_7P102 + + ntpq/ntpq.1@1.103 +2 -2 + NTP_4_2_7P102 + + ntpsnmpd/ntpsnmpd-opts.c@1.103 +2 -2 + NTP_4_2_7P102 + + ntpsnmpd/ntpsnmpd-opts.h@1.103 +3 -3 + NTP_4_2_7P102 + + ntpsnmpd/ntpsnmpd-opts.texi@1.103 +1 -1 + NTP_4_2_7P102 + + ntpsnmpd/ntpsnmpd.1@1.103 +2 -2 + NTP_4_2_7P102 + + packageinfo.sh@1.104 +1 -1 + NTP_4_2_7P102 + + sntp/sntp-opts.c@1.103 +2 -2 + NTP_4_2_7P102 + + sntp/sntp-opts.h@1.103 +3 -3 + NTP_4_2_7P102 + + sntp/sntp-opts.texi@1.103 +1 -1 + NTP_4_2_7P102 + + sntp/sntp.1@1.103 +2 -2 + NTP_4_2_7P102 + + sntp/sntp.html@1.103 +1 -1 + NTP_4_2_7P102 + + util/ntp-keygen-opts.c@1.101 +2 -2 + NTP_4_2_7P102 + + util/ntp-keygen-opts.h@1.101 +3 -3 + NTP_4_2_7P102 + + util/ntp-keygen-opts.texi@1.104 +1 -1 + NTP_4_2_7P102 + + util/ntp-keygen.1@1.104 +2 -2 + NTP_4_2_7P102 + +ChangeSet@1.2373, 2010-12-23 02:22:35-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.722 +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.68 +2 -2 + Documentation updates from Dave Mills + + html/autokey.html@1.15 +33 -23 + Documentation updates from Dave Mills + + html/keygen.html@1.27 +2 -2 + Documentation updates from Dave Mills + + html/ntpd.html@1.54 +14 -14 + Documentation updates from Dave Mills + + html/ntpq.html@1.43 +27 -23 + Documentation updates from Dave Mills + +ChangeSet@1.2372, 2010-12-23 07:03:00+00:00, davehart@shiny.ad.hartbrothers.com + Allow ntpq &1 associd use without preceding association-fetching. + + ChangeLog@1.721 +1 -0 + Allow ntpq &1 associd use without preceding association-fetching. + + include/ntp_calendar.h@1.6 +2 -0 + declare months[] + + libntp/ntp_calendar.c@1.4 +7 -7 + avoid shadows declaration warning with months[] + + libntp/prettydate.c@1.17 +4 -4 + match declaration to extern + + ntpd/refclock_oncore.c@1.88 +5 -5 + use libntp's months[] instead of local array + + ntpdc/ntpdc.c@1.89 +0 -57 + remove ntp_getopt() remains from ntpdc + + ntpq/libntpq_subs.c@1.6 +7 -9 + changes reflect dogetassoc() is no longer static + + ntpq/ntpq-subs.c@1.72 +8 -11 + make dogetassoc() global so ntpq.c getargs() can use it + + ntpq/ntpq.c@1.121 +64 -123 + Allow ntpq &1 associd use without preceding association-fetching. + Use libntp's months[] + + ntpq/ntpq.h@1.19 +6 -3 + use const + +ChangeSet@1.2371, 2010-12-22 12:37:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P101 + TAG: NTP_4_2_7P101 + + ChangeLog@1.720 +1 -0 + NTP_4_2_7P101 + + clockstuff/clktest-opts.c@1.25 +2 -2 + NTP_4_2_7P101 + + clockstuff/clktest-opts.h@1.25 +3 -3 + NTP_4_2_7P101 + + ntpd/ntpd-opts.c@1.105 +2 -2 + NTP_4_2_7P101 + + ntpd/ntpd-opts.h@1.105 +3 -3 + NTP_4_2_7P101 + + ntpd/ntpd-opts.texi@1.103 +1 -1 + NTP_4_2_7P101 + + ntpd/ntpd.1@1.103 +2 -2 + NTP_4_2_7P101 + + ntpdc/ntpdc-opts.c@1.102 +2 -2 + NTP_4_2_7P101 + + ntpdc/ntpdc-opts.h@1.102 +3 -3 + NTP_4_2_7P101 + + ntpdc/ntpdc-opts.texi@1.102 +1 -1 + NTP_4_2_7P101 + + ntpdc/ntpdc.1@1.102 +2 -2 + NTP_4_2_7P101 + + ntpq/ntpq-opts.c@1.102 +2 -2 + NTP_4_2_7P101 + + ntpq/ntpq-opts.h@1.102 +3 -3 + NTP_4_2_7P101 + + ntpq/ntpq-opts.texi@1.102 +1 -1 + NTP_4_2_7P101 + + ntpq/ntpq.1@1.102 +2 -2 + NTP_4_2_7P101 + + ntpsnmpd/ntpsnmpd-opts.c@1.102 +2 -2 + NTP_4_2_7P101 + + ntpsnmpd/ntpsnmpd-opts.h@1.102 +3 -3 + NTP_4_2_7P101 + + ntpsnmpd/ntpsnmpd-opts.texi@1.102 +1 -1 + NTP_4_2_7P101 + + ntpsnmpd/ntpsnmpd.1@1.102 +2 -2 + NTP_4_2_7P101 + + packageinfo.sh@1.103 +1 -1 + NTP_4_2_7P101 + + sntp/sntp-opts.c@1.102 +2 -2 + NTP_4_2_7P101 + + sntp/sntp-opts.h@1.102 +3 -3 + NTP_4_2_7P101 + + sntp/sntp-opts.texi@1.102 +1 -1 + NTP_4_2_7P101 + + sntp/sntp.1@1.102 +2 -2 + NTP_4_2_7P101 + + sntp/sntp.html@1.102 +1 -1 + NTP_4_2_7P101 + + util/ntp-keygen-opts.c@1.100 +2 -2 + NTP_4_2_7P101 + + util/ntp-keygen-opts.h@1.100 +3 -3 + NTP_4_2_7P101 + + util/ntp-keygen-opts.texi@1.103 +1 -1 + NTP_4_2_7P101 + + util/ntp-keygen.1@1.103 +2 -2 + NTP_4_2_7P101 + +ChangeSet@1.2082.4.186, 2010-12-22 08:57:41+00:00, davehart@shiny.ad.hartbrothers.com + libopts 34.0.9 from AutoGen 5.11.6pre7 + Relax minimum Automake version to 1.10 with updated libopts.m4. + + ChangeLog@1.496.26.135 +2 -1 + libopts 34.0.9 from AutoGen 5.11.6pre7 + Relax minimum Automake version to 1.10 with updated libopts.m4. + + Makefile.am@1.93.2.7 +2 -2 + Relax minimum Automake version to 1.10 with updated libopts.m4. + + configure.ac@1.465.1.24 +1 -1 + libopts 34.0.9 from AutoGen 5.11.6pre7 + + sntp/Makefile.am@1.21.1.14 +2 -2 + Relax minimum Automake version to 1.10 with updated libopts.m4. + + sntp/libopts/m4/libopts.m4@1.14 +45 -17 + libopts 34.0.9 from AutoGen 5.11.6pre7 + +ChangeSet@1.2369, 2010-12-21 16:21:21-05:00, stenn@deacon.udel.edu + Documentation updates for sntp + + ChangeLog@1.718 +2 -0 + Documentation updates for sntp + +ChangeSet@1.2368, 2010-12-21 11:27:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P100 + TAG: NTP_4_2_7P100 + + ChangeLog@1.717 +1 -0 + NTP_4_2_7P100 + + clockstuff/clktest-opts.c@1.24 +3 -3 + NTP_4_2_7P100 + + clockstuff/clktest-opts.h@1.24 +3 -3 + NTP_4_2_7P100 + + ntpd/ntpd-opts.c@1.104 +3 -3 + NTP_4_2_7P100 + + ntpd/ntpd-opts.h@1.104 +3 -3 + NTP_4_2_7P100 + + ntpd/ntpd-opts.texi@1.102 +1 -1 + NTP_4_2_7P100 + + ntpd/ntpd.1@1.102 +2 -2 + NTP_4_2_7P100 + + ntpdc/ntpdc-opts.c@1.101 +3 -3 + NTP_4_2_7P100 + + ntpdc/ntpdc-opts.h@1.101 +3 -3 + NTP_4_2_7P100 + + ntpdc/ntpdc-opts.texi@1.101 +1 -1 + NTP_4_2_7P100 + + ntpdc/ntpdc.1@1.101 +2 -2 + NTP_4_2_7P100 + + ntpq/ntpq-opts.c@1.101 +3 -3 + NTP_4_2_7P100 + + ntpq/ntpq-opts.h@1.101 +3 -3 + NTP_4_2_7P100 + + ntpq/ntpq-opts.texi@1.101 +1 -1 + NTP_4_2_7P100 + + ntpq/ntpq.1@1.101 +2 -2 + NTP_4_2_7P100 + + ntpsnmpd/ntpsnmpd-opts.c@1.101 +3 -3 + NTP_4_2_7P100 + + ntpsnmpd/ntpsnmpd-opts.h@1.101 +3 -3 + NTP_4_2_7P100 + + ntpsnmpd/ntpsnmpd-opts.texi@1.101 +1 -1 + NTP_4_2_7P100 + + ntpsnmpd/ntpsnmpd.1@1.101 +2 -2 + NTP_4_2_7P100 + + packageinfo.sh@1.102 +1 -1 + NTP_4_2_7P100 + + sntp/sntp-opts.c@1.101 +3 -3 + NTP_4_2_7P100 + + sntp/sntp-opts.h@1.101 +3 -3 + NTP_4_2_7P100 + + sntp/sntp-opts.texi@1.101 +5 -4 + NTP_4_2_7P100 + + sntp/sntp.1@1.101 +8 -4 + NTP_4_2_7P100 + + sntp/sntp.html@1.101 +5 -4 + NTP_4_2_7P100 + + util/ntp-keygen-opts.c@1.99 +3 -3 + NTP_4_2_7P100 + + util/ntp-keygen-opts.h@1.99 +3 -3 + NTP_4_2_7P100 + + util/ntp-keygen-opts.texi@1.102 +1 -1 + NTP_4_2_7P100 + + util/ntp-keygen.1@1.102 +2 -2 + NTP_4_2_7P100 + +ChangeSet@1.2366, 2010-12-21 09:36:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P99 + TAG: NTP_4_2_7P99 + + ChangeLog@1.716 +1 -0 + NTP_4_2_7P99 + + clockstuff/clktest-opts.c@1.23 +2 -2 + NTP_4_2_7P99 + + clockstuff/clktest-opts.h@1.23 +3 -3 + NTP_4_2_7P99 + + ntpd/ntpd-opts.c@1.103 +2 -2 + NTP_4_2_7P99 + + ntpd/ntpd-opts.h@1.103 +3 -3 + NTP_4_2_7P99 + + ntpd/ntpd-opts.texi@1.101 +1 -1 + NTP_4_2_7P99 + + ntpd/ntpd.1@1.101 +2 -2 + NTP_4_2_7P99 + + ntpdc/ntpdc-opts.c@1.100 +2 -2 + NTP_4_2_7P99 + + ntpdc/ntpdc-opts.h@1.100 +3 -3 + NTP_4_2_7P99 + + ntpdc/ntpdc-opts.texi@1.100 +1 -1 + NTP_4_2_7P99 + + ntpdc/ntpdc.1@1.100 +2 -2 + NTP_4_2_7P99 + + ntpq/ntpq-opts.c@1.100 +2 -2 + NTP_4_2_7P99 + + ntpq/ntpq-opts.h@1.100 +3 -3 + NTP_4_2_7P99 + + ntpq/ntpq-opts.texi@1.100 +1 -1 + NTP_4_2_7P99 + + ntpq/ntpq.1@1.100 +2 -2 + NTP_4_2_7P99 + + ntpsnmpd/ntpsnmpd-opts.c@1.100 +2 -2 + NTP_4_2_7P99 + + ntpsnmpd/ntpsnmpd-opts.h@1.100 +3 -3 + NTP_4_2_7P99 + + ntpsnmpd/ntpsnmpd-opts.texi@1.100 +1 -1 + NTP_4_2_7P99 + + ntpsnmpd/ntpsnmpd.1@1.100 +2 -2 + NTP_4_2_7P99 + + packageinfo.sh@1.101 +1 -1 + NTP_4_2_7P99 + + sntp/sntp-opts.c@1.100 +2 -2 + NTP_4_2_7P99 + + sntp/sntp-opts.h@1.100 +3 -3 + NTP_4_2_7P99 + + sntp/sntp-opts.texi@1.100 +1 -1 + NTP_4_2_7P99 + + sntp/sntp.1@1.100 +2 -2 + NTP_4_2_7P99 + + sntp/sntp.html@1.100 +1 -1 + NTP_4_2_7P99 + + util/ntp-keygen-opts.c@1.98 +2 -2 + NTP_4_2_7P99 + + util/ntp-keygen-opts.h@1.98 +3 -3 + NTP_4_2_7P99 + + util/ntp-keygen-opts.texi@1.101 +1 -1 + NTP_4_2_7P99 + + util/ntp-keygen.1@1.101 +2 -2 + NTP_4_2_7P99 + +ChangeSet@1.2082.46.1, 2010-12-21 07:15:24+00:00, davehart@shiny.ad.hartbrothers.com + handle % at end of string correctly in format_errmsg(). + do not force trailing newline in m[v]snprintf(). + + libntp/msyslog.c@1.24.1.3 +54 -29 + handle % at end of string correctly in format_errmsg(). + do not force trailing newline in m[v]snprintf(). + +ChangeSet@1.2364, 2010-12-21 06:58:01+00:00, davehart@shiny.ad.hartbrothers.com + Add unit tests for msnprintf(). + move responsibility for adding newline if not present from + format_errmsg() to addto_syslog() so that msnprintf() does + not also force a trailing newline. + Correct corner case of "%\0" in msyslog() and friends. + + ChangeLog@1.715 +1 -0 + Add unit tests for msnprintf(). + + libntp/msyslog.c@1.28 +49 -29 + Move responsibility for adding newline if not present from + format_errmsg() to addto_syslog() so that msnprintf() does + not also force a trailing newline. + Correct corner case of %\0 in msyslog() and friends. + + tests/libntp/Makefile.am@1.25 +1 -0 + add msyslog.cpp + + tests/libntp/msyslog.cpp@1.1 +84 -0 + unit tests for msnprintf() and format_errmsg() + + tests/libntp/msyslog.cpp@1.0 +0 -0 + +ChangeSet@1.2082.4.184, 2010-12-20 18:41:39-08:00, stenn@stenn.ntp.org + [Bug 1743] update SNTP time reporting documentation + + sntp/sntp-opts.def@1.19 +10 -5 + [Bug 1743] update SNTP time reporting documentation + +ChangeSet@1.2363, 2010-12-20 18:13:16-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/pic/flt8.gif@1.1 +134 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt8.gif + + html/pic/flt8.gif@1.0 +0 -0 + + html/pic/flt9.gif@1.1 +200 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt9.gif + + html/pic/flt9.gif@1.0 +0 -0 + +ChangeSet@1.2361, 2010-12-20 09:04:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P98 + TAG: NTP_4_2_7P98 + + ChangeLog@1.713 +1 -0 + NTP_4_2_7P98 + + clockstuff/clktest-opts.c@1.22 +2 -2 + NTP_4_2_7P98 + + clockstuff/clktest-opts.h@1.22 +3 -3 + NTP_4_2_7P98 + + ntpd/ntpd-opts.c@1.102 +2 -2 + NTP_4_2_7P98 + + ntpd/ntpd-opts.h@1.102 +3 -3 + NTP_4_2_7P98 + + ntpd/ntpd-opts.texi@1.100 +1 -1 + NTP_4_2_7P98 + + ntpd/ntpd.1@1.100 +2 -2 + NTP_4_2_7P98 + + ntpdc/ntpdc-opts.c@1.99 +2 -2 + NTP_4_2_7P98 + + ntpdc/ntpdc-opts.h@1.99 +3 -3 + NTP_4_2_7P98 + + ntpdc/ntpdc-opts.texi@1.99 +1 -1 + NTP_4_2_7P98 + + ntpdc/ntpdc.1@1.99 +2 -2 + NTP_4_2_7P98 + + ntpq/ntpq-opts.c@1.99 +2 -2 + NTP_4_2_7P98 + + ntpq/ntpq-opts.h@1.99 +3 -3 + NTP_4_2_7P98 + + ntpq/ntpq-opts.texi@1.99 +1 -1 + NTP_4_2_7P98 + + ntpq/ntpq.1@1.99 +2 -2 + NTP_4_2_7P98 + + ntpsnmpd/ntpsnmpd-opts.c@1.99 +2 -2 + NTP_4_2_7P98 + + ntpsnmpd/ntpsnmpd-opts.h@1.99 +3 -3 + NTP_4_2_7P98 + + ntpsnmpd/ntpsnmpd-opts.texi@1.99 +1 -1 + NTP_4_2_7P98 + + ntpsnmpd/ntpsnmpd.1@1.99 +2 -2 + NTP_4_2_7P98 + + packageinfo.sh@1.100 +1 -1 + NTP_4_2_7P98 + + sntp/sntp-opts.c@1.99 +2 -2 + NTP_4_2_7P98 + + sntp/sntp-opts.h@1.99 +3 -3 + NTP_4_2_7P98 + + sntp/sntp-opts.texi@1.99 +1 -1 + NTP_4_2_7P98 + + sntp/sntp.1@1.99 +2 -2 + NTP_4_2_7P98 + + sntp/sntp.html@1.99 +1 -1 + NTP_4_2_7P98 + + util/ntp-keygen-opts.c@1.97 +2 -2 + NTP_4_2_7P98 + + util/ntp-keygen-opts.h@1.97 +3 -3 + NTP_4_2_7P98 + + util/ntp-keygen-opts.texi@1.100 +1 -1 + NTP_4_2_7P98 + + util/ntp-keygen.1@1.100 +2 -2 + NTP_4_2_7P98 + +ChangeSet@1.2360, 2010-12-20 03:50:47-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.712 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.14 +23 -17 + Documentation updates from Dave Mills + +ChangeSet@1.2359, 2010-12-20 08:24:12+00:00, hart@psp-fb1.ntp.org + ntp_parser.c: + Bison output + complete.conf: + add top-level ident directive + + ntpd/complete.conf@1.14 +1 -0 + add top-level ident directive + + ntpd/ntp_parser.c@1.74 +393 -381 + Bison output + +ChangeSet@1.2358, 2010-12-20 08:12:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1761] clockstuff/clktest-opts.h omitted from tarball. + + ChangeLog@1.711 +1 -0 + [Bug 1761] clockstuff/clktest-opts.h omitted from tarball. + + clockstuff/Makefile.am@1.14 +1 -1 + [Bug 1761] clockstuff/clktest-opts.h omitted from tarball. + + ntpd/ntp_config.c@1.279 +4 -0 + add "ident " top-level directive at DLM request. + + ntpd/ntp_parser.y@1.68 +2 -1 + add "ident " top-level directive at DLM request. + +ChangeSet@1.2082.44.8, 2010-12-20 07:54:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1458] Can not compile NTP on FreeBSD 4.7. + -- applies to prior lineedit cset which overlooked ChangeLog + [Bug 1762] manycastclient solicitation responses interfere. + + ChangeLog@1.496.60.3 +2 -0 + [Bug 1458] Can not compile NTP on FreeBSD 4.7. + -- applies to prior lineedit cset which overlooked ChangeLog + [Bug 1762] manycastclient solicitation responses interfere. + + include/ntp.h@1.168.1.5 +1 -1 + struct interface -> endpt + + include/ntpd.h@1.137.2.4 +1 -1 + [Bug 1762] manycastclient solicitation responses interfere. + + include/recvbuff.h@1.19.1.1 +1 -1 + struct interface -> endpt + + ntpd/ntp_peer.c@1.126.1.3 +33 -13 + [Bug 1762] manycastclient solicitation responses interfere. + + ntpd/ntp_proto.c@1.297.2.2 +1 -2 + [Bug 1762] manycastclient solicitation responses interfere. + +ChangeSet@1.2356, 2010-12-19 09:38:06+00:00, stenn@deacon.udel.edu + NTP_4_2_7P97 + TAG: NTP_4_2_7P97 + + ChangeLog@1.709 +1 -0 + NTP_4_2_7P97 + + clockstuff/clktest-opts.c@1.21 +21 -16 + NTP_4_2_7P97 + + clockstuff/clktest-opts.h@1.21 +5 -5 + NTP_4_2_7P97 + + ntpd/ntpd-opts.c@1.101 +16 -11 + NTP_4_2_7P97 + + ntpd/ntpd-opts.h@1.101 +5 -5 + NTP_4_2_7P97 + + ntpd/ntpd-opts.texi@1.99 +1 -1 + NTP_4_2_7P97 + + ntpd/ntpd.1@1.99 +2 -2 + NTP_4_2_7P97 + + ntpdc/ntpdc-opts.c@1.98 +21 -16 + NTP_4_2_7P97 + + ntpdc/ntpdc-opts.h@1.98 +5 -5 + NTP_4_2_7P97 + + ntpdc/ntpdc-opts.texi@1.98 +1 -1 + NTP_4_2_7P97 + + ntpdc/ntpdc.1@1.98 +2 -2 + NTP_4_2_7P97 + + ntpq/ntpq-opts.c@1.98 +21 -16 + NTP_4_2_7P97 + + ntpq/ntpq-opts.h@1.98 +5 -5 + NTP_4_2_7P97 + + ntpq/ntpq-opts.texi@1.98 +1 -1 + NTP_4_2_7P97 + + ntpq/ntpq.1@1.98 +2 -2 + NTP_4_2_7P97 + + ntpsnmpd/ntpsnmpd-opts.c@1.98 +20 -15 + NTP_4_2_7P97 + + ntpsnmpd/ntpsnmpd-opts.h@1.98 +5 -5 + NTP_4_2_7P97 + + ntpsnmpd/ntpsnmpd-opts.texi@1.98 +1 -1 + NTP_4_2_7P97 + + ntpsnmpd/ntpsnmpd.1@1.98 +2 -2 + NTP_4_2_7P97 + + packageinfo.sh@1.99 +1 -1 + NTP_4_2_7P97 + + sntp/sntp-opts.c@1.98 +23 -18 + NTP_4_2_7P97 + + sntp/sntp-opts.h@1.98 +5 -5 + NTP_4_2_7P97 + + sntp/sntp-opts.texi@1.98 +1 -1 + NTP_4_2_7P97 + + sntp/sntp.1@1.98 +2 -2 + NTP_4_2_7P97 + + sntp/sntp.html@1.98 +1 -1 + NTP_4_2_7P97 + + util/ntp-keygen-opts.c@1.96 +21 -16 + NTP_4_2_7P97 + + util/ntp-keygen-opts.h@1.96 +5 -5 + NTP_4_2_7P97 + + util/ntp-keygen-opts.texi@1.99 +1 -1 + NTP_4_2_7P97 + + util/ntp-keygen.1@1.99 +2 -2 + NTP_4_2_7P97 + +ChangeSet@1.2082.44.7, 2010-12-19 00:04:39-05:00, stenn@deacon.udel.edu + Remove unused libntp/net.c.bak file + + BitKeeper/deleted/.del-net.c.bak~d1c71b19@1.3 +0 -0 + Delete: libntp/net.c.bak + +ChangeSet@1.2355, 2010-12-19 00:00:18-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.708 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.13 +17 -29 + Documentation updates from Dave Mills + +ChangeSet@1.2082.44.6, 2010-12-19 03:42:39+00:00, hart@psp-os1.ntp.org + sntp AutoGen 5.11.6pre5 output + + sntp/sntp-opts.c@1.117.29.1 +29 -30 + sntp AutoGen 5.11.6pre5 output + + sntp/sntp-opts.h@1.117.29.1 +13 -4 + sntp AutoGen 5.11.6pre5 output + + sntp/sntp-opts.texi@1.117.29.1 +85 -19 + sntp AutoGen 5.11.6pre5 output + + sntp/sntp.1@1.117.29.1 +8 -6 + sntp AutoGen 5.11.6pre5 output + + sntp/sntp.html@1.7.30.1 +79 -16 + sntp AutoGen 5.11.6pre5 output + +ChangeSet@1.2082.44.5, 2010-12-19 01:10:44+00:00, hart@psp-os1.ntp.org + AutoGen 5.11.6pre5 output + + ntpd/ntpd-opts.c@1.248.31.1 +15 -10 + AutoGen 5.11.6pre5 output + + ntpd/ntpd-opts.h@1.248.31.1 +3 -3 + AutoGen 5.11.6pre5 output + + ntpd/ntpd-opts.texi@1.246.31.1 +61 -2 + AutoGen 5.11.6pre5 output + + ntpd/ntpd.1@1.246.31.1 +2 -2 + AutoGen 5.11.6pre5 output + + ntpdc/ntpdc-opts.c@1.244.31.1 +20 -15 + AutoGen 5.11.6pre5 output + + ntpdc/ntpdc-opts.h@1.244.31.1 +3 -3 + AutoGen 5.11.6pre5 output + + ntpdc/ntpdc-opts.texi@1.243.31.1 +66 -2 + AutoGen 5.11.6pre5 output + + ntpdc/ntpdc.1@1.243.31.1 +2 -2 + AutoGen 5.11.6pre5 output + + ntpq/ntpq-opts.c@1.245.31.1 +20 -15 + AutoGen 5.11.6pre5 output + + ntpq/ntpq-opts.h@1.245.31.1 +3 -3 + AutoGen 5.11.6pre5 output + + ntpq/ntpq-opts.texi@1.244.31.1 +51 -2 + AutoGen 5.11.6pre5 output + + ntpq/ntpq.1@1.244.31.1 +2 -2 + AutoGen 5.11.6pre5 output + + ntpsnmpd/ntpsnmpd-opts.c@1.123.32.1 +19 -14 + AutoGen 5.11.6pre5 output + + ntpsnmpd/ntpsnmpd-opts.h@1.123.32.1 +3 -3 + AutoGen 5.11.6pre5 output + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.32.1 +1 -1 + AutoGen 5.11.6pre5 output + + ntpsnmpd/ntpsnmpd.1@1.122.32.1 +2 -2 + AutoGen 5.11.6pre5 output + + util/ntp-keygen-opts.c@1.247.31.1 +20 -15 + AutoGen 5.11.6pre5 output + + util/ntp-keygen-opts.h@1.247.31.1 +3 -3 + AutoGen 5.11.6pre5 output + + util/ntp-keygen-opts.texi@1.246.31.1 +45 -2 + AutoGen 5.11.6pre5 output + + util/ntp-keygen.1@1.246.31.1 +2 -2 + AutoGen 5.11.6pre5 output + +ChangeSet@1.2082.44.4, 2010-12-19 00:59:46+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1760] ntpd Windows interpolation cannot be disabled. + Upgrade to libopts 34.0.9 from AutoGen 5.11.6pre5. + applies to prior cset merged from ntp-stable-libopts-upstream + + ChangeLog@1.496.60.2 +2 -1 + [Bug 1760] ntpd Windows interpolation cannot be disabled. + Upgrade to libopts 34.0.9 from AutoGen 5.11.6pre5. + + + ports/winnt/ntpd/nt_clockstuff.c@1.38.1.4 +3 -1 + [Bug 1760] ntpd Windows interpolation cannot be disabled. + +ChangeSet@1.2082.45.1, 2010-12-19 00:50:10+00:00, davehart@shiny.ad.hartbrothers.com + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/Makefile.am@1.8 +5 -5 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/ag-char-map.h@1.11 +32 -32 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/autoopts.c@1.8 +21 -10 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/autoopts.h@1.7 +19 -18 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/autoopts/options.h@1.10 +11 -6 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/autoopts/usage-txt.h@1.10 +175 -168 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/genshell.c@1.11 +16 -11 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/genshell.h@1.11 +3 -3 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/load.c@1.8 +27 -31 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/m4/libopts.m4@1.11.1.1 +1 -1 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/proto.h@1.11 +1 -1 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/usage.c@1.7 +23 -24 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/value-type.h@1.11 +1 -1 + libopts 34.0.9 (AutoGen 5.11.6pre5) + + sntp/libopts/xat-attribute.h@1.11 +1 -1 + libopts 34.0.9 (AutoGen 5.11.6pre5) + +ChangeSet@1.2352, 2010-12-18 11:29:06+00:00, stenn@deacon.udel.edu + NTP_4_2_7P96 + TAG: NTP_4_2_7P96 + + ChangeLog@1.706 +1 -0 + NTP_4_2_7P96 + + clockstuff/clktest-opts.c@1.20 +3 -3 + NTP_4_2_7P96 + + clockstuff/clktest-opts.h@1.20 +5 -5 + NTP_4_2_7P96 + + ntpd/ntpd-opts.c@1.100 +3 -3 + NTP_4_2_7P96 + + ntpd/ntpd-opts.h@1.100 +5 -5 + NTP_4_2_7P96 + + ntpd/ntpd-opts.texi@1.98 +1 -1 + NTP_4_2_7P96 + + ntpd/ntpd.1@1.98 +2 -2 + NTP_4_2_7P96 + + ntpdc/ntpdc-opts.c@1.97 +3 -3 + NTP_4_2_7P96 + + ntpdc/ntpdc-opts.h@1.97 +5 -5 + NTP_4_2_7P96 + + ntpdc/ntpdc-opts.texi@1.97 +1 -1 + NTP_4_2_7P96 + + ntpdc/ntpdc.1@1.97 +2 -2 + NTP_4_2_7P96 + + ntpq/ntpq-opts.c@1.97 +3 -3 + NTP_4_2_7P96 + + ntpq/ntpq-opts.h@1.97 +5 -5 + NTP_4_2_7P96 + + ntpq/ntpq-opts.texi@1.97 +1 -1 + NTP_4_2_7P96 + + ntpq/ntpq.1@1.97 +2 -2 + NTP_4_2_7P96 + + ntpsnmpd/ntpsnmpd-opts.c@1.97 +3 -3 + NTP_4_2_7P96 + + ntpsnmpd/ntpsnmpd-opts.h@1.97 +5 -5 + NTP_4_2_7P96 + + ntpsnmpd/ntpsnmpd-opts.texi@1.97 +1 -1 + NTP_4_2_7P96 + + ntpsnmpd/ntpsnmpd.1@1.97 +2 -2 + NTP_4_2_7P96 + + packageinfo.sh@1.98 +1 -1 + NTP_4_2_7P96 + + sntp/sntp-opts.c@1.97 +3 -3 + NTP_4_2_7P96 + + sntp/sntp-opts.h@1.97 +5 -5 + NTP_4_2_7P96 + + sntp/sntp-opts.texi@1.97 +1 -1 + NTP_4_2_7P96 + + sntp/sntp.1@1.97 +2 -2 + NTP_4_2_7P96 + + sntp/sntp.html@1.97 +1 -1 + NTP_4_2_7P96 + + util/ntp-keygen-opts.c@1.95 +3 -3 + NTP_4_2_7P96 + + util/ntp-keygen-opts.h@1.95 +5 -5 + NTP_4_2_7P96 + + util/ntp-keygen-opts.texi@1.98 +1 -1 + NTP_4_2_7P96 + + util/ntp-keygen.1@1.98 +2 -2 + NTP_4_2_7P96 + +ChangeSet@1.2082.44.2, 2010-12-18 06:57:45+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1458] Can not compile NTP on FreeBSD 4.7 + + libntp/ntp_lineedit.c@1.9 +17 -10 + [Bug 1458] Can not compile NTP on FreeBSD 4.7 + + m4/ntp_lineeditlibs.m4@1.10 +26 -0 + [Bug 1458] Can not compile NTP on FreeBSD 4.7 + +ChangeSet@1.2351, 2010-12-18 01:07:11-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.705 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.12 +24 -3 + Documentation updates from Dave Mills + +ChangeSet@1.2350, 2010-12-18 03:22:45+00:00, davehart@shiny.ad.hartbrothers.com + Log listening address as addr:port. + remove assoc_number < 0 check now that it is unsigned. + + ntpd/ntp_io.c@1.337 +2 -3 + Log listening address as addr:port + + ntpq/libntpq.c@1.10 +1 -1 + remove assoc_number < 0 check now that it is unsigned. + +ChangeSet@1.2082.44.1, 2010-12-18 02:38:28+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1758] setsockopt IPV6_MULTICAST_IF with wrong ifindex. + + ChangeLog@1.496.60.1 +1 -0 + [Bug 1758] setsockopt IPV6_MULTICAST_IF with wrong ifindex. + + ntpd/ntp_io.c@1.306.3.1 +48 -72 + [Bug 1758] setsockopt IPV6_MULTICAST_IF with wrong ifindex. + +ChangeSet@1.2348, 2010-12-17 04:38:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P95 + TAG: NTP_4_2_7P95 + + ChangeLog@1.703 +1 -0 + NTP_4_2_7P95 + + clockstuff/clktest-opts.c@1.19 +3 -3 + NTP_4_2_7P95 + + clockstuff/clktest-opts.h@1.19 +15 -6 + NTP_4_2_7P95 + + ntpd/ntpd-opts.c@1.99 +3 -3 + NTP_4_2_7P95 + + ntpd/ntpd-opts.h@1.99 +15 -6 + NTP_4_2_7P95 + + ntpd/ntpd-opts.texi@1.97 +2 -75 + NTP_4_2_7P95 + + ntpd/ntpd.1@1.97 +2 -2 + NTP_4_2_7P95 + + ntpdc/ntpdc-opts.c@1.96 +3 -3 + NTP_4_2_7P95 + + ntpdc/ntpdc-opts.h@1.96 +15 -6 + NTP_4_2_7P95 + + ntpdc/ntpdc-opts.texi@1.96 +2 -66 + NTP_4_2_7P95 + + ntpdc/ntpdc.1@1.96 +2 -2 + NTP_4_2_7P95 + + ntpq/ntpq-opts.c@1.96 +3 -3 + NTP_4_2_7P95 + + ntpq/ntpq-opts.h@1.96 +15 -6 + NTP_4_2_7P95 + + ntpq/ntpq-opts.texi@1.96 +2 -51 + NTP_4_2_7P95 + + ntpq/ntpq.1@1.96 +2 -2 + NTP_4_2_7P95 + + ntpsnmpd/ntpsnmpd-opts.c@1.96 +3 -3 + NTP_4_2_7P95 + + ntpsnmpd/ntpsnmpd-opts.h@1.96 +15 -6 + NTP_4_2_7P95 + + ntpsnmpd/ntpsnmpd-opts.texi@1.96 +2 -24 + NTP_4_2_7P95 + + ntpsnmpd/ntpsnmpd.1@1.96 +2 -2 + NTP_4_2_7P95 + + packageinfo.sh@1.97 +1 -1 + NTP_4_2_7P95 + + sntp/sntp-opts.c@1.96 +3 -3 + NTP_4_2_7P95 + + sntp/sntp-opts.h@1.96 +15 -6 + NTP_4_2_7P95 + + sntp/sntp-opts.texi@1.96 +2 -56 + NTP_4_2_7P95 + + sntp/sntp.1@1.96 +2 -2 + NTP_4_2_7P95 + + sntp/sntp.html@1.96 +2 -56 + NTP_4_2_7P95 + + util/ntp-keygen-opts.c@1.94 +3 -3 + NTP_4_2_7P95 + + util/ntp-keygen-opts.h@1.94 +15 -6 + NTP_4_2_7P95 + + util/ntp-keygen-opts.texi@1.97 +2 -47 + NTP_4_2_7P95 + + util/ntp-keygen.1@1.97 +2 -2 + NTP_4_2_7P95 + +ChangeSet@1.2346, 2010-12-16 22:02:02-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.701 +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.54 +10 -8 + Documentation updates from Dave Mills + +ChangeSet@1.2082.4.182, 2010-12-17 02:53:54+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1757] oncore snprintf("%m") doesn't expand %m. + + ChangeLog@1.496.26.133 +1 -0 + [Bug 1757] oncore snprintf("%m") doesn't expand %m. + + include/ntp_stdlib.h@1.40.1.4 +4 -1 + add mvsnprintf(), msnprintf() clones of vsnprintf() and snprintf() which + expand %m to strerror(errno) like msyslog() + + libntp/msyslog.c@1.24.1.2 +43 -23 + add mvsnprintf(), msnprintf() clones of vsnprintf() and snprintf() which + expand %m to strerror(errno) like msyslog() + + ntpd/ntp_io.c@1.306.1.14 +1 -1 + silence potentially uninit warning + + ntpd/refclock_oncore.c@1.82.1.1 +5 -5 + [Bug 1757] oncore snprintf("%m") doesn't expand %m. + +ChangeSet@1.2082.42.3, 2010-12-17 01:59:53+00:00, hart@psp-os1.ntp.org + Many files: + Autogen 5.11.6pre3 output + + ntpd/ntpd-opts.c@1.248.30.1 +5 -5 + Autogen 5.11.6pre3 output + + ntpd/ntpd-opts.h@1.248.30.1 +13 -4 + Autogen 5.11.6pre3 output + + ntpd/ntpd-opts.texi@1.246.30.1 +1 -1 + Autogen 5.11.6pre3 output + + ntpd/ntpd.1@1.246.30.1 +2 -2 + Autogen 5.11.6pre3 output + + ntpdc/ntpdc-opts.c@1.244.30.1 +5 -5 + Autogen 5.11.6pre3 output + + ntpdc/ntpdc-opts.h@1.244.30.1 +13 -4 + Autogen 5.11.6pre3 output + + ntpdc/ntpdc-opts.texi@1.243.30.1 +1 -1 + Autogen 5.11.6pre3 output + + ntpdc/ntpdc.1@1.243.30.1 +2 -2 + Autogen 5.11.6pre3 output + + ntpq/ntpq-opts.c@1.245.30.1 +5 -5 + Autogen 5.11.6pre3 output + + ntpq/ntpq-opts.h@1.245.30.1 +13 -4 + Autogen 5.11.6pre3 output + + ntpq/ntpq-opts.texi@1.244.30.1 +1 -1 + Autogen 5.11.6pre3 output + + ntpq/ntpq.1@1.244.30.1 +2 -2 + Autogen 5.11.6pre3 output + + ntpsnmpd/ntpsnmpd-opts.c@1.123.31.1 +5 -5 + Autogen 5.11.6pre3 output + + ntpsnmpd/ntpsnmpd-opts.h@1.123.31.1 +13 -4 + Autogen 5.11.6pre3 output + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.31.1 +1 -1 + Autogen 5.11.6pre3 output + + ntpsnmpd/ntpsnmpd.1@1.122.31.1 +2 -2 + Autogen 5.11.6pre3 output + + util/ntp-keygen-opts.c@1.247.30.1 +5 -5 + Autogen 5.11.6pre3 output + + util/ntp-keygen-opts.h@1.247.30.1 +13 -4 + Autogen 5.11.6pre3 output + + util/ntp-keygen-opts.texi@1.246.30.1 +1 -1 + Autogen 5.11.6pre3 output + + util/ntp-keygen.1@1.246.30.1 +2 -2 + Autogen 5.11.6pre3 output + +ChangeSet@1.2082.42.2, 2010-12-17 01:46:51+00:00, davehart@shiny.ad.hartbrothers.com + restore NTP local patch to LIBOPTS_CHECK to not build libopts + from the top-level configure.ac. + + sntp/libopts/m4/libopts.m4@1.12 +10 -7 + restore NTP local patch to LIBOPTS_CHECK to not build libopts + from the top-level configure.ac. + +ChangeSet@1.2082.42.1, 2010-12-17 01:43:41+00:00, davehart@shiny.ad.hartbrothers.com + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + ChangeLog@1.496.26.132 +1 -1 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/Makefile.am@1.7 +5 -5 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/README@1.5 +1 -1 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/ag-char-map.h@1.10 +1 -1 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/autoopts/options.h@1.9 +12 -5 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/autoopts/usage-txt.h@1.9 +1 -1 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/configfile.c@1.9 +14 -7 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/genshell.c@1.10 +2 -2 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/genshell.h@1.10 +3 -3 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/m4/libopts.m4@1.11 +8 -11 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/makeshell.c@1.7 +17 -9 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/proto.h@1.10 +1 -1 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/value-type.h@1.10 +1 -1 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + + sntp/libopts/xat-attribute.h@1.10 +1 -1 + libopts 33.5.8 unmodified from AutoGen 5.11.6pre3 + +ChangeSet@1.2082.4.179, 2010-12-16 20:22:36-05:00, stenn@deacon.udel.edu + libopts upgrade + + ntpd/ntpd-opts.c@1.248.29.1 +5 -5 + libopts upgrade + + ntpd/ntpd-opts.h@1.248.29.1 +13 -4 + libopts upgrade + + ntpd/ntpd-opts.texi@1.246.29.1 +61 -2 + libopts upgrade + + ntpd/ntpd.1@1.246.29.1 +2 -2 + libopts upgrade + + ntpdc/ntpdc-opts.c@1.244.29.1 +5 -5 + libopts upgrade + + ntpdc/ntpdc-opts.h@1.244.29.1 +13 -4 + libopts upgrade + + ntpdc/ntpdc-opts.texi@1.243.29.1 +66 -2 + libopts upgrade + + ntpdc/ntpdc.1@1.243.29.1 +2 -2 + libopts upgrade + + ntpq/ntpq-opts.c@1.245.29.1 +5 -5 + libopts upgrade + + ntpq/ntpq-opts.h@1.245.29.1 +13 -4 + libopts upgrade + + ntpq/ntpq-opts.texi@1.244.29.1 +51 -2 + libopts upgrade + + ntpq/ntpq.1@1.244.29.1 +2 -2 + libopts upgrade + + ntpsnmpd/ntpsnmpd-opts.c@1.123.30.1 +5 -5 + libopts upgrade + + ntpsnmpd/ntpsnmpd-opts.h@1.123.30.1 +13 -4 + libopts upgrade + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.30.1 +24 -2 + libopts upgrade + + ntpsnmpd/ntpsnmpd.1@1.122.30.1 +2 -2 + libopts upgrade + + util/ntp-keygen-opts.c@1.247.29.1 +5 -5 + libopts upgrade + + util/ntp-keygen-opts.h@1.247.29.1 +13 -4 + libopts upgrade + + util/ntp-keygen-opts.texi@1.246.29.1 +45 -2 + libopts upgrade + + util/ntp-keygen.1@1.246.29.1 +2 -2 + libopts upgrade + +ChangeSet@1.2082.4.178, 2010-12-16 23:57:51+00:00, davehart@shiny.ad.hartbrothers.com + first verbose --version attempt caused --help to segfault. + + libntp/ntp_libopts.c@1.3 +7 -6 + first verbose --version attempt caused --help to segfault. + +ChangeSet@1.2082.4.177, 2010-12-16 09:07:58+00:00, davehart@shiny.ad.hartbrothers.com + Upgrade to libopts 33.4.8 from AutoGen 5.11.6pre1. + + ChangeLog@1.496.26.131 +1 -0 + Upgrade to libopts 33.4.8 from AutoGen 5.11.6pre1. + + sntp/libopts/Makefile.am@1.6 +5 -5 + libopts 33.4.8 + + sntp/libopts/ag-char-map.h@1.9 +1 -1 + libopts 33.4.8 + + sntp/libopts/autoopts.c@1.7 +5 -5 + libopts 33.4.8 + + sntp/libopts/autoopts/options.h@1.8 +4 -4 + libopts 33.4.8 + + sntp/libopts/autoopts/usage-txt.h@1.8 +1 -1 + libopts 33.4.8 + + sntp/libopts/configfile.c@1.8 +4 -1 + libopts 33.4.8 + + sntp/libopts/environment.c@1.8 +26 -20 + libopts 33.4.8 + + sntp/libopts/genshell.c@1.9 +2 -2 + libopts 33.4.8 + + sntp/libopts/genshell.h@1.9 +13 -4 + libopts 33.4.8 + + sntp/libopts/load.c@1.7 +2 -2 + libopts 33.4.8 + + sntp/libopts/m4/libopts.m4@1.10 +6 -6 + libopts 33.4.8 + plus local patch to fix single shared libopts between sntp subproj + and top-level + + sntp/libopts/m4/liboptschk.m4@1.7 +20 -33 + libopts 33.4.8 + + sntp/libopts/proto.h@1.9 +2 -2 + libopts 33.4.8 + + sntp/libopts/value-type.h@1.9 +1 -1 + libopts 33.4.8 + + sntp/libopts/xat-attribute.h@1.9 +1 -1 + libopts 33.4.8 + +ChangeSet@1.2082.4.176, 2010-12-16 06:16:02+00:00, davehart@shiny.ad.hartbrothers.com + #include in new file libntp/ntp_libopts.c + add libopts includes to libntp INCLUDES = now that ntp_libopts.c + uses them. + + ChangeLog@1.496.26.130 +1 -1 + typo + + libntp/Makefile.am@1.51.1.2 +3 -3 + add libopts includes to libntp INCLUDES = now that ntp_libopts.c + uses them. + + libntp/ntp_libopts.c@1.2 +4 -1 + #include in new file libntp/ntp_libopts.c + +ChangeSet@1.2082.4.175, 2010-12-16 04:42:37+00:00, davehart@shiny.ad.hartbrothers.com + * [Bug 1740] ntpdc treats many counters as signed. (backport) + * [Bug 1754] --version output should be more verbose. + * Suppress ntp-keygen OpenSSL version display for --help, --version, + display both build and runtime OpenSLL versions when they differ. + + ChangeLog@1.496.26.129 +4 -0 + * [Bug 1740] ntpdc treats many counters as signed. (backport) + * [Bug 1754] --version output should be more verbose. + * Suppress ntp-keygen OpenSSL version display for --help, --version, + display both build and runtime OpenSLL versions when they differ. + + + include/Makefile.am@1.38.1.1 +1 -0 + add ntp_libopts.h + + include/ntp_libopts.h@1.1 +13 -0 + new wrapper ntpOptionProcess() makes --version output more verbose. + + include/ntp_libopts.h@1.0 +0 -0 + + libntp/Makefile.am@1.51.1.1 +1 -0 + add ntp_libopts.c + + libntp/ntp_libopts.c@1.1 +50 -0 + new wrapper ntpOptionProcess() makes --version output more verbose. + + libntp/ntp_libopts.c@1.0 +0 -0 + + ntpd/ntp_scanner.c@1.31.1.3 +2 -2 + suppress gcc4 warning about signed overflow by using + unsigned counter and index + + ntpd/ntpd.c@1.110.2.3 +2 -1 + [Bug 1754] --version output should be more verbose. + + ntpdc/ntpdc.c@1.75.1.4 +2 -1 + [Bug 1754] --version output should be more verbose. + + ntpdc/ntpdc_ops.c@1.62.1.3 +191 -197 + [Bug 1740] ntpdc treats many counters as signed. (backport) + + ntpq/ntpq.c@1.97.1.8 +2 -1 + [Bug 1754] --version output should be more verbose. + + ports/winnt/vc6/libntp.dsp@1.43.1.11 +4 -0 + add libntp/ntp_libopts.c reference + + ports/winnt/vc6/ntpkeygen.dsp@1.20.1.2 +2 -2 + correct ntp-keygen Version string to mention ntp-keygen not ntpkeygen + + ports/winnt/vs2003/libntp.vcproj@1.4.1.5 +3 -0 + add libntp/ntp_libopts.c reference + + ports/winnt/vs2003/ntpkeygen.vcproj@1.3.1.2 +2 -2 + correct ntp-keygen Version string to mention ntp-keygen not ntpkeygen + + ports/winnt/vs2005/libntp.vcproj@1.4.1.5 +4 -0 + add libntp/ntp_libopts.c reference + + ports/winnt/vs2005/ntpkeygen.vcproj@1.3.1.2 +2 -2 + correct ntp-keygen Version string to mention ntp-keygen not ntpkeygen + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20.3.1 +8 -0 + add libntp/ntp_libopts.c reference + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.9.2.1 +2 -68 + correct ntp-keygen Version string to mention ntp-keygen not ntpkeygen + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.21.2.1 +4 -0 + add include/ntp_libopts.h reference + + util/Makefile.am@1.45.1.5 +9 -1 + Generate, use version.c for verbose --version output + + util/ntp-keygen.c@1.64.1.2 +13 -2 + [Bug 1754] --version output should be more verbose. + +ChangeSet@1.2082.4.174, 2010-12-15 20:23:17+00:00, davehart@shiny.ad.hartbrothers.com + Use LIBS not LDFLAGS for configure tests of -lcrypto, -lcrypto -lz + + m4/ntp_openssl.m4@1.4.1.4 +6 -6 + Use LIBS not LDFLAGS for configure tests of -lcrypto, -lcrypto -lz + +ChangeSet@1.2338, 2010-12-15 19:01:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1753] 4.2.7p94 faults on startup in newpeer(), strdup(NULL). + + ChangeLog@1.696 +1 -0 + [Bug 1753] 4.2.7p94 faults on startup in newpeer(), strdup(NULL). + + ntpd/ntp_peer.c@1.142 +2 -1 + [Bug 1753] 4.2.7p94 faults on startup in newpeer(), strdup(NULL). + +ChangeSet@1.2337, 2010-12-15 10:12:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P94 + TAG: NTP_4_2_7P94 + + ChangeLog@1.695 +1 -0 + NTP_4_2_7P94 + + clockstuff/clktest-opts.c@1.18 +2 -2 + NTP_4_2_7P94 + + clockstuff/clktest-opts.h@1.18 +3 -3 + NTP_4_2_7P94 + + ntpd/ntpd-opts.c@1.98 +2 -2 + NTP_4_2_7P94 + + ntpd/ntpd-opts.h@1.98 +3 -3 + NTP_4_2_7P94 + + ntpd/ntpd-opts.texi@1.96 +2 -2 + NTP_4_2_7P94 + + ntpd/ntpd.1@1.96 +2 -2 + NTP_4_2_7P94 + + ntpdc/ntpdc-opts.c@1.95 +2 -2 + NTP_4_2_7P94 + + ntpdc/ntpdc-opts.h@1.95 +3 -3 + NTP_4_2_7P94 + + ntpdc/ntpdc-opts.texi@1.95 +2 -2 + NTP_4_2_7P94 + + ntpdc/ntpdc.1@1.95 +2 -2 + NTP_4_2_7P94 + + ntpq/ntpq-opts.c@1.95 +2 -2 + NTP_4_2_7P94 + + ntpq/ntpq-opts.h@1.95 +3 -3 + NTP_4_2_7P94 + + ntpq/ntpq-opts.texi@1.95 +2 -2 + NTP_4_2_7P94 + + ntpq/ntpq.1@1.95 +2 -2 + NTP_4_2_7P94 + + ntpsnmpd/ntpsnmpd-opts.c@1.95 +2 -2 + NTP_4_2_7P94 + + ntpsnmpd/ntpsnmpd-opts.h@1.95 +3 -3 + NTP_4_2_7P94 + + ntpsnmpd/ntpsnmpd-opts.texi@1.95 +2 -2 + NTP_4_2_7P94 + + ntpsnmpd/ntpsnmpd.1@1.95 +2 -2 + NTP_4_2_7P94 + + packageinfo.sh@1.96 +1 -1 + NTP_4_2_7P94 + + sntp/sntp-opts.c@1.95 +2 -2 + NTP_4_2_7P94 + + sntp/sntp-opts.h@1.95 +3 -3 + NTP_4_2_7P94 + + sntp/sntp-opts.texi@1.95 +2 -2 + NTP_4_2_7P94 + + sntp/sntp.1@1.95 +2 -2 + NTP_4_2_7P94 + + sntp/sntp.html@1.95 +4 -7 + NTP_4_2_7P94 + + util/ntp-keygen-opts.c@1.93 +2 -2 + NTP_4_2_7P94 + + util/ntp-keygen-opts.h@1.93 +3 -3 + NTP_4_2_7P94 + + util/ntp-keygen-opts.texi@1.96 +2 -2 + NTP_4_2_7P94 + + util/ntp-keygen.1@1.96 +2 -2 + NTP_4_2_7P94 + +ChangeSet@1.2082.4.173, 2010-12-15 08:27:35+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1618] Unreachable code in jjy_start(). (backport from ntp-dev) + (applies to -stable changes previously pulled to -dev only) + [Bug 1719] ntp-keygen -V crash. (backport) + + ChangeLog@1.496.26.128 +2 -0 + [Bug 1618] Unreachable code in jjy_start(). (backport from ntp-dev) + [Bug 1719] ntp-keygen -V crash. (backport) + + util/ntp-keygen.c@1.64.1.1 +0 -1 + [Bug 1719] ntp-keygen -V crash. (backport) + +ChangeSet@1.2329.1.1, 2010-12-15 01:49:59-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills. + + ChangeLog@1.691.1.1 +1 -0 + Documentation updates from Dave Mills. + + html/authopt.html@1.67 +13 -10 + Documentation updates from Dave Mills. + + html/autokey.html@1.11 +49 -62 + Documentation updates from Dave Mills. + + html/copyright.html@1.53 +61 -82 + Documentation updates from Dave Mills. + + html/drivers/driver8.html@1.26 +244 -278 + Documentation updates from Dave Mills. + + html/keygen.html@1.26 +9 -10 + Documentation updates from Dave Mills. + +ChangeSet@1.2082.40.22, 2010-12-15 01:23:25+00:00, davehart@shiny.ad.hartbrothers.com + get along better with OpenSSL 1.0.0c headers by including + evp.h instead of rand.h in ssl_init.c and configure.ac tests. + + libntp/ssl_init.c@1.4.1.3 +1 -1 + get along better with OpenSSL 1.0.0c headers by including + evp.h instead of rand.h in ssl_init.c and configure.ac tests. + + m4/ntp_openssl.m4@1.4.1.3 +2 -2 + get along better with OpenSSL 1.0.0c headers by including + evp.h instead of rand.h in ssl_init.c and configure.ac tests. + +ChangeSet@1.2333, 2010-12-15 00:14:11+00:00, davehart@shiny.ad.hartbrothers.com + quiet gcc4 warnings + alloc/free peer group identity member + + ntpd/ntp_control.c@1.146 +0 -1 + remove unused local 'pkid' from ctl_error() + + ntpd/ntp_io.c@1.334 +2 -1 + use unsigned type for select_count to silence gcc signed + overflow warning. + + ntpd/ntp_peer.c@1.141 +4 -1 + make copy of group identity in newpeer() + + ntpd/refclock_jjy.c@1.20 +15 -10 + quiet gcc4 signed overflow warnings with unsigned use. + + ntpd/refclock_mx4200.c@1.27 +1 -1 + eliminate int compared to pointer warning + + sntp/tests/packetHandling.cpp@1.6 +2 -2 + suppress gcc4 warning of negative left shift count from use + of LOGTOD(), substitute ULOGTOD() + +ChangeSet@1.2082.40.21, 2010-12-14 20:49:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1751] correct -lcrypto -lz dependency test + + m4/ntp_openssl.m4@1.4.1.2 +4 -0 + [Bug 1751] correct -lcrypto -lz dependency test + +ChangeSet@1.2331, 2010-12-14 20:10:12+00:00, davehart@shiny.ad.hartbrothers.com + cleanup merge flub + + ntpq/ntpq-subs.c@1.71 +4 -2 + cleanup merge flub + +ChangeSet@1.2082.40.20, 2010-12-14 19:40:18+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1751] Support for Atari FreeMiNT OS. + + ChangeLog@1.496.26.127 +1 -0 + [Bug 1751] Support for Atari FreeMiNT OS. + + configure.ac@1.465.1.23 +4 -1 + [Bug 1751] Support for Atari FreeMiNT OS. + + lib/isc/unix/net.c@1.15 +1 -1 + [Bug 1751] Support for Atari FreeMiNT OS. + + m4/ntp_openssl.m4@1.4.1.1 +52 -0 + [Bug 1751] Atari FreeMiNT needs -lcrypto -lz for LCRYPTO + + ntpd/ntp_config.c@1.241.1.8 +4 -5 + attempt to silence gcc4 apparently bogus warning about simplifying + conditional "if (i)" to a constant. + + ntpd/ntp_control.c@1.129.1.6 +3 -1 + quiet gcc4 signed overflow warning + + ntpd/ntp_refclock.c@1.92.1.2 +6 -32 + quiet gcc4 signed overflow warning + + ntpd/refclock_conf.c@1.28 +1 -1 + [Bug 1751] Atari FreeMiNT termios.h doesn't have TIOCMSET + + ntpd/refclock_palisade.c@1.31.1.2 +12 -6 + [Bug 1751] Atari FreeMiNT termios.h doesn't have TIOCMSET + + ntpdate/ntpdate.c@1.69.2.2 +32 -27 + attempt to silence gcc4 signed wraparound/overflow warnings. + + ntpdc/ntpdc.c@1.75.1.3 +35 -55 + 4.2.6 requires ANSI C so qsort() signature is nailed down. + + ntpdc/ntpdc_ops.c@1.62.1.2 +65 -67 + Attempt to silence apparently bogus "simplifying conditional + to constant" warning from gcc4 re "if (res)" + + ntpq/libntpq.c@1.3.1.5 +62 -73 + use associd_t instead of int + + ntpq/libntpq.h@1.3.1.3 +10 -12 + use associd_t instead of int + + ntpq/libntpq_subs.c@1.2.1.2 +4 -10 + use associd_t instead of int + + ntpq/ntpq-subs.c@1.39.2.5 +99 -88 + use associd_t instead of int + + ntpq/ntpq.c@1.97.1.7 +119 -174 + use associd_t instead of int + + ntpq/ntpq.h@1.10.1.4 +1 -1 + use associd_t not int + + sntp/main.c@1.24.1.9 +5 -4 + toy with gcc4 apparently spurious "simplifying conditional to constant" + warning. + + util/tickadj.c@1.9 +3 -1 + [Bug 1751] Support for Atari FreeMiNT OS. + +ChangeSet@1.2329, 2010-12-13 08:28:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P93 + TAG: NTP_4_2_7P93 + + ChangeLog@1.691 +1 -0 + NTP_4_2_7P93 + + clockstuff/clktest-opts.c@1.17 +2 -2 + NTP_4_2_7P93 + + clockstuff/clktest-opts.h@1.17 +3 -3 + NTP_4_2_7P93 + + ntpd/ntpd-opts.c@1.97 +2 -2 + NTP_4_2_7P93 + + ntpd/ntpd-opts.h@1.97 +3 -3 + NTP_4_2_7P93 + + ntpd/ntpd-opts.texi@1.95 +2 -2 + NTP_4_2_7P93 + + ntpd/ntpd.1@1.95 +2 -2 + NTP_4_2_7P93 + + ntpdc/ntpdc-opts.c@1.94 +2 -2 + NTP_4_2_7P93 + + ntpdc/ntpdc-opts.h@1.94 +3 -3 + NTP_4_2_7P93 + + ntpdc/ntpdc-opts.texi@1.94 +2 -2 + NTP_4_2_7P93 + + ntpdc/ntpdc.1@1.94 +2 -2 + NTP_4_2_7P93 + + ntpq/ntpq-opts.c@1.94 +2 -2 + NTP_4_2_7P93 + + ntpq/ntpq-opts.h@1.94 +3 -3 + NTP_4_2_7P93 + + ntpq/ntpq-opts.texi@1.94 +2 -2 + NTP_4_2_7P93 + + ntpq/ntpq.1@1.94 +2 -2 + NTP_4_2_7P93 + + ntpsnmpd/ntpsnmpd-opts.c@1.94 +2 -2 + NTP_4_2_7P93 + + ntpsnmpd/ntpsnmpd-opts.h@1.94 +3 -3 + NTP_4_2_7P93 + + ntpsnmpd/ntpsnmpd-opts.texi@1.94 +2 -2 + NTP_4_2_7P93 + + ntpsnmpd/ntpsnmpd.1@1.94 +2 -2 + NTP_4_2_7P93 + + packageinfo.sh@1.95 +1 -1 + NTP_4_2_7P93 + + sntp/sntp-opts.c@1.94 +2 -2 + NTP_4_2_7P93 + + sntp/sntp-opts.h@1.94 +3 -3 + NTP_4_2_7P93 + + sntp/sntp-opts.texi@1.94 +2 -2 + NTP_4_2_7P93 + + sntp/sntp.1@1.94 +2 -2 + NTP_4_2_7P93 + + sntp/sntp.html@1.94 +2 -2 + NTP_4_2_7P93 + + util/ntp-keygen-opts.c@1.92 +2 -2 + NTP_4_2_7P93 + + util/ntp-keygen-opts.h@1.92 +3 -3 + NTP_4_2_7P93 + + util/ntp-keygen-opts.texi@1.95 +2 -2 + NTP_4_2_7P93 + + util/ntp-keygen.1@1.95 +2 -2 + NTP_4_2_7P93 + +ChangeSet@1.2328, 2010-12-13 01:55:38-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills. + + html/autokey.html@1.10 +47 -48 + Documentation updates from Dave Mills. + + html/keygen.html@1.25 +2 -1 + Documentation updates from Dave Mills. + +ChangeSet@1.2323.2.2, 2010-12-13 01:29:30-05:00, stenn@deacon.udel.edu + "server ... ident " changes from Dave Mills + + ChangeLog@1.687.1.2 +1 -0 + "server ... ident " changes from Dave Mills + + include/ntp.h@1.188.1.1 +1 -0 + "server ... ident " changes from Dave Mills + + include/ntp_control.h@1.47.1.1 +2 -1 + "server ... ident " changes from Dave Mills + + include/ntpd.h@1.147.1.1 +1 -1 + "server ... ident " changes from Dave Mills + + ntpd/ntp_control.c@1.141.1.1 +12 -2 + "server ... ident " changes from Dave Mills + + ntpd/ntp_crypto.c@1.149 +7 -29 + "server ... ident " changes from Dave Mills + + ntpd/ntp_peer.c@1.138.1.1 +4 -2 + "server ... ident " changes from Dave Mills + + ntpd/ntp_proto.c@1.313 +4 -4 + "server ... ident " changes from Dave Mills + + util/ntp-keygen.c@1.70 +7 -23 + "server ... ident " changes from Dave Mills + +ChangeSet@1.2323.2.1, 2010-12-13 01:16:09-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills. + + ChangeLog@1.687.1.1 +1 -0 + Documentation updates from Dave Mills. + + html/autokey.html@1.9 +23 -3 + Documentation updates from Dave Mills. + + html/keygen.html@1.24 +39 -49 + Documentation updates from Dave Mills. + + html/miscopt.html@1.63 +3 -3 + Documentation updates from Dave Mills. + +ChangeSet@1.2082.40.19, 2010-12-13 01:06:37-05:00, stenn@deacon.udel.edu + SNTP documentation cleanup + + sntp/Makefile.am@1.21.1.13 +4 -0 + SNTP documentation cleanup + + sntp/sntp.html@1.7.29.1 +297 -11 + SNTP documentation cleanup + + sntp/sntp.texi@1.6 +2 -2 + SNTP documentation cleanup + +ChangeSet@1.2323.1.3, 2010-12-12 08:30:28+00:00, davehart@shiny.ad.hartbrothers.com + Add test for socktoa(), sockporttoa() with scoped address. + Correct unit tests for sntp offset_calculation() arg change. + + ntpd/ntp_control.c@1.143 +0 -2 + Cleanup merge, remove redundant local maclen that triggered + shadow warning. + + ntpd/ntpsim.c@1.30 +19 -17 + correct ntpsim.c for peer_config group ident arg change. + + sntp/tests/packetHandling.cpp@1.5 +4 -2 + Correct unit tests for sntp offset_calculation() arg change. + + sntp/tests/utilities.cpp@1.6 +3 -2 + No stack garbage for scope ID, thanks. + + tests/libntp/socktoa.cpp@1.2 +32 -5 + Add test for socktoa(), sockporttoa() with scoped address. + +ChangeSet@1.2323.1.1, 2010-12-12 07:23:59+00:00, davehart@shiny.ad.hartbrothers.com + include non-zero scope in IPv6 stoa() output + + libntp/socktoa.c@1.13 +24 -13 + include non-zero scope in IPv6 stoa() output + +ChangeSet@1.2082.40.17, 2010-12-12 07:11:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1741] Enable multicast reception on each address (Windows). + Minimize local address flip-flopping by avoiding peer_refresh_allinterfaces() + if nothing has changed in the interface list since the last scan. + Separate handling of scope ID embedded in many in6_addr from ifindex used + for IPv6 multicasting ioctls. + Add INT_PRIVACY endpt bit flag for IPv6 RFC 4941 privacy addresses. + Enable outbound multicast from only one address per interface in the same + subnet, and in that case prefer embedded MAC address modified EUI-64 IPv6 + addresses first, then static, and last RFC 4941 privacy addresses. + Use setsockopt(IP[V6]_MULTICAST_IF) before each send to multicast to select + the local source address, using the correct socket isn't enough. + + ChangeLog@1.496.59.1 +12 -0 + * [Bug 1741] Enable multicast reception on each address (Windows). + * Other manycastclient repairs: + Separate handling of scope ID embedded in many in6_addr from ifindex + used for IPv6 multicasting ioctls. + Add INT_PRIVACY endpt bit flag for IPv6 RFC 4941 privacy addresses. + Enable outbound multicast from only one address per interface in the + same subnet, and in that case prefer embedded MAC address modified + EUI-64 IPv6 addresses first, then static, and last RFC 4941 privacy + addresses. + Use setsockopt(IP[V6]_MULTICAST_IF) before each send to multicast to + select the local source address, using the correct socket is not + enough. + + + include/isc/mem.h@1.4 +9 -8 + use macro-arg-protecting () only where helpful. + + include/ntp.h@1.168.1.4 +3 -2 + add INT_PRIVACY endpt.flags bit to indicate RFC 4941 privacy addresses + + include/ntp_control.h@1.38.1.1 +1 -1 + use offsetof instead of hard_coding CTL_HEADER_LEN + + include/ntp_io.h@1.13.1.2 +4 -4 + housekeeping (use #ifdef not #if for HAVE_*) + + include/ntp_net.h@1.3.1.3 +4 -0 + add IS_IID_UNIV() to test for universal scope interface identifier + to differentiate embedded-MAC modified EUI-64 from static and + privacy addresses. + + include/ntp_stdlib.h@1.40.1.3 +2 -2 + mark socktoa(), socktohost() args const + + include/ntpd.h@1.137.2.3 +1 -1 + whitespace only + + lib/isc/include/isc/interfaceiter.h@1.8 +2 -0 + add ifindex to struct isc_interface to manage need for index + distinct from sin6_scope_id for setsockopt IPV6_MULTICAST_IF + and IPV6_JOIN_GROUP. + add INTERFACE_F_PRIVACY flag set when the source of the IID + is RFC 4941 privacy addresses or another random scheme. + + lib/isc/unix/ifiter_ioctl.c@1.29 +2 -6 + set ifindex in libisc interface enumerator, and for link-local + addresses, use it as the scope ID (AKA zone). + + lib/isc/unix/ifiter_sysctl.c@1.16 +1 -0 + set ifindex in libisc interface enumerator + + lib/isc/unix/interfaceiter.c@1.19 +3 -1 + set ifindex in libisc interface enumerator + + lib/isc/win32/include/isc/ipv6.h@1.10 +4 -4 + Fix bugs in Windows libisc IN6_IS_ADDR_{LINK|SITE}LOCAL() + + lib/isc/win32/interfaceiter.c@1.20 +29 -16 + Add INTERFACE_F_PRIVACY detection, set new ifindex in isc_interface_t. + Skip deprecated addresses. + nonfunctional cleanup of [Bug 1738] changes. + + libntp/socktoa.c@1.11.1.1 +1 -1 + socktoa() input now const + + libntp/socktohost.c@1.7.1.1 +1 -1 + socktohost() input now const + + ntpd/ntp_control.c@1.129.1.5 +0 -2 + eliminate gcc4 warning in rendundant code by removing it. + authencrypt() jams the keyid into the packet structure. + + ntpd/ntp_io.c@1.306.1.13 +357 -308 + [Bug 1741] Enable multicast reception on each address (Windows). + Minimize local address flip-flopping by avoiding peer_refresh_allinterfaces() + if nothing has changed in the interface list since the last scan. + Separate handling of scope ID embedded in many in6_addr from ifindex used + for IPv6 multicasting ioctls. + Add INT_PRIVACY endpt bit flag for IPv6 RFC 4941 privacy addresses. + Enable outbound multicast from only one address per interface in the same + subnet, and in that case prefer embedded MAC address modified EUI-64 IPv6 + addresses first, then static, and last RFC 4941 privacy addresses. + Use setsockopt(IP[V6]_MULTICAST_IF) before each send to multicast to select + the local source address, using the correct socket isn't enough. + + ntpd/ntp_peer.c@1.126.1.2 +49 -50 + cleanup + + ntpd/ntp_request.c@1.82.1.4 +18 -16 + scopeid member of endpt replaced with ifindex + + ntpd/ntpd.c@1.110.2.2 +1 -1 + typo in msyslog text "Attemping" + +ChangeSet@1.2082.41.5, 2010-12-10 12:52:28+01:00, burnicki@pogo.udel.edu + Updated changelog. + + ChangeLog@1.496.26.125 +1 -0 + Updated changelog. + +ChangeSet@1.2082.41.4, 2010-12-10 12:47:54+01:00, burnicki@pogo.udel.edu + [Bug 1510] Add modes 20/21 for driver 8 to support RAWDCF @ 75 baud. + + html/drivers/driver8.html@1.25 +12 -0 + [Bug 1510] Add modes 20/21 for driver 8 to support RAWDCF @ 75 baud. + + ntpd/refclock_parse.c@1.52.1.1 +49 -0 + [Bug 1510] Add modes 20/21 for driver 8 to support RAWDCF @ 75 baud. + +ChangeSet@1.2323, 2010-12-08 10:11:00+00:00, stenn@deacon.udel.edu + NTP_4_2_7P92 + TAG: NTP_4_2_7P92 + + ChangeLog@1.687 +1 -0 + NTP_4_2_7P92 + + clockstuff/clktest-opts.c@1.16 +2 -2 + NTP_4_2_7P92 + + clockstuff/clktest-opts.h@1.16 +3 -3 + NTP_4_2_7P92 + + ntpd/ntpd-opts.c@1.96 +2 -2 + NTP_4_2_7P92 + + ntpd/ntpd-opts.h@1.96 +3 -3 + NTP_4_2_7P92 + + ntpd/ntpd-opts.texi@1.94 +2 -2 + NTP_4_2_7P92 + + ntpd/ntpd.1@1.94 +2 -2 + NTP_4_2_7P92 + + ntpdc/ntpdc-opts.c@1.93 +2 -2 + NTP_4_2_7P92 + + ntpdc/ntpdc-opts.h@1.93 +3 -3 + NTP_4_2_7P92 + + ntpdc/ntpdc-opts.texi@1.93 +2 -2 + NTP_4_2_7P92 + + ntpdc/ntpdc.1@1.93 +2 -2 + NTP_4_2_7P92 + + ntpq/ntpq-opts.c@1.93 +2 -2 + NTP_4_2_7P92 + + ntpq/ntpq-opts.h@1.93 +3 -3 + NTP_4_2_7P92 + + ntpq/ntpq-opts.texi@1.93 +2 -2 + NTP_4_2_7P92 + + ntpq/ntpq.1@1.93 +2 -2 + NTP_4_2_7P92 + + ntpsnmpd/ntpsnmpd-opts.c@1.93 +2 -2 + NTP_4_2_7P92 + + ntpsnmpd/ntpsnmpd-opts.h@1.93 +3 -3 + NTP_4_2_7P92 + + ntpsnmpd/ntpsnmpd-opts.texi@1.93 +2 -2 + NTP_4_2_7P92 + + ntpsnmpd/ntpsnmpd.1@1.93 +2 -2 + NTP_4_2_7P92 + + packageinfo.sh@1.94 +1 -1 + NTP_4_2_7P92 + + sntp/sntp-opts.c@1.93 +3 -3 + NTP_4_2_7P92 + + sntp/sntp-opts.h@1.93 +3 -3 + NTP_4_2_7P92 + + sntp/sntp-opts.texi@1.93 +4 -3 + NTP_4_2_7P92 + + sntp/sntp.1@1.93 +4 -2 + NTP_4_2_7P92 + + sntp/sntp.html@1.93 +10 -9 + NTP_4_2_7P92 + + util/ntp-keygen-opts.c@1.91 +2 -2 + NTP_4_2_7P92 + + util/ntp-keygen-opts.h@1.91 +3 -3 + NTP_4_2_7P92 + + util/ntp-keygen-opts.texi@1.94 +2 -2 + NTP_4_2_7P92 + + util/ntp-keygen.1@1.94 +2 -2 + NTP_4_2_7P92 + +ChangeSet@1.2082.41.3, 2010-12-08 02:34:17-05:00, stenn@psp-deb1.ntp.org + [Bug 1743] Display timezone offset when showing time for sntp in the local timezone. + + ChangeLog@1.496.26.124 +2 -0 + [Bug 1743] Display timezone offset when showing time for sntp in the local timezone. + + sntp/configure.ac@1.31.1.9 +1 -0 + [Bug 1743] Display timezone offset when showing time for sntp in the local timezone. + + sntp/main.c@1.24.1.8 +20 -2 + [Bug 1743] Display timezone offset when showing time for sntp in the local timezone. + + sntp/utilities.c@1.10.1.3 +40 -26 + [Bug 1743] Display timezone offset when showing time for sntp in the local timezone. + + sntp/utilities.h@1.9 +1 -1 + [Bug 1743] Display timezone offset when showing time for sntp in the local timezone. + +ChangeSet@1.2082.41.2, 2010-12-08 02:28:13-05:00, stenn@deacon.udel.edu + Clean up the SNTP documentation + + sntp/sntp-opts.def@1.18 +4 -0 + Clean up the SNTP documentation + + sntp/sntp.texi@1.5 +3 -3 + Clean up the SNTP documentation + +ChangeSet@1.2321, 2010-12-07 10:11:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P91 + TAG: NTP_4_2_7P91 + + ChangeLog@1.685 +1 -0 + NTP_4_2_7P91 + + clockstuff/clktest-opts.c@1.15 +2 -2 + NTP_4_2_7P91 + + clockstuff/clktest-opts.h@1.15 +3 -3 + NTP_4_2_7P91 + + ntpd/ntpd-opts.c@1.95 +2 -2 + NTP_4_2_7P91 + + ntpd/ntpd-opts.h@1.95 +3 -3 + NTP_4_2_7P91 + + ntpd/ntpd-opts.texi@1.93 +2 -2 + NTP_4_2_7P91 + + ntpd/ntpd.1@1.93 +2 -2 + NTP_4_2_7P91 + + ntpdc/ntpdc-opts.c@1.92 +2 -2 + NTP_4_2_7P91 + + ntpdc/ntpdc-opts.h@1.92 +3 -3 + NTP_4_2_7P91 + + ntpdc/ntpdc-opts.texi@1.92 +2 -2 + NTP_4_2_7P91 + + ntpdc/ntpdc.1@1.92 +2 -2 + NTP_4_2_7P91 + + ntpq/ntpq-opts.c@1.92 +2 -2 + NTP_4_2_7P91 + + ntpq/ntpq-opts.h@1.92 +3 -3 + NTP_4_2_7P91 + + ntpq/ntpq-opts.texi@1.92 +2 -2 + NTP_4_2_7P91 + + ntpq/ntpq.1@1.92 +2 -2 + NTP_4_2_7P91 + + ntpsnmpd/ntpsnmpd-opts.c@1.92 +2 -2 + NTP_4_2_7P91 + + ntpsnmpd/ntpsnmpd-opts.h@1.92 +3 -3 + NTP_4_2_7P91 + + ntpsnmpd/ntpsnmpd-opts.texi@1.92 +2 -2 + NTP_4_2_7P91 + + ntpsnmpd/ntpsnmpd.1@1.92 +2 -2 + NTP_4_2_7P91 + + packageinfo.sh@1.93 +1 -1 + NTP_4_2_7P91 + + sntp/sntp-opts.c@1.92 +2 -2 + NTP_4_2_7P91 + + sntp/sntp-opts.h@1.92 +3 -3 + NTP_4_2_7P91 + + sntp/sntp-opts.texi@1.92 +2 -2 + NTP_4_2_7P91 + + sntp/sntp.1@1.92 +2 -2 + NTP_4_2_7P91 + + sntp/sntp.html@1.92 +2 -2 + NTP_4_2_7P91 + + util/ntp-keygen-opts.c@1.90 +2 -2 + NTP_4_2_7P91 + + util/ntp-keygen-opts.h@1.90 +3 -3 + NTP_4_2_7P91 + + util/ntp-keygen-opts.texi@1.93 +2 -2 + NTP_4_2_7P91 + + util/ntp-keygen.1@1.93 +2 -2 + NTP_4_2_7P91 + +ChangeSet@1.2319, 2010-12-07 08:42:46+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1732] ntpd ties up CPU on disconnected USB device. + + ChangeLog@1.683 +1 -0 + [Bug 1732] ntpd ties up CPU on disconnected USB device. + + ntpd/ntp_io.c@1.332 +16 -9 + Remove closed file descriptors from I/O loop select() set. + +ChangeSet@1.2082.41.1, 2010-12-07 03:37:36-05:00, stenn@deacon.udel.edu + [Bug 1742] Fix a typo in an error message in the "build" script + + ChangeLog@1.496.26.123 +1 -0 + [Bug 1742] Fix a typo in an error message in the "build" script + + build@1.38 +1 -1 + [Bug 1742] Fix a typo in an error message in the "build" script + +ChangeSet@1.2082.40.14, 2010-12-06 08:01:24+00:00, davehart@shiny.ad.hartbrothers.com + correct relatively harmless retrying GetAdaptersAddresses() on errors + other than ERROR_BUFFER_OVERFLOW. + + lib/isc/win32/interfaceiter.c@1.19 +2 -2 + correct relatively harmless retrying GetAdaptersAddresses() on errors + other than ERROR_BUFFER_OVERFLOW. + +ChangeSet@1.2317, 2010-12-06 07:49:43+00:00, stenn@deacon.udel.edu + NTP_4_2_7P90 + TAG: NTP_4_2_7P90 + + ChangeLog@1.682 +1 -0 + NTP_4_2_7P90 + + clockstuff/clktest-opts.c@1.14 +2 -2 + NTP_4_2_7P90 + + clockstuff/clktest-opts.h@1.14 +3 -3 + NTP_4_2_7P90 + + ntpd/ntpd-opts.c@1.94 +2 -2 + NTP_4_2_7P90 + + ntpd/ntpd-opts.h@1.94 +3 -3 + NTP_4_2_7P90 + + ntpd/ntpd-opts.texi@1.92 +2 -2 + NTP_4_2_7P90 + + ntpd/ntpd.1@1.92 +2 -2 + NTP_4_2_7P90 + + ntpdc/ntpdc-opts.c@1.91 +2 -2 + NTP_4_2_7P90 + + ntpdc/ntpdc-opts.h@1.91 +3 -3 + NTP_4_2_7P90 + + ntpdc/ntpdc-opts.texi@1.91 +2 -2 + NTP_4_2_7P90 + + ntpdc/ntpdc.1@1.91 +2 -2 + NTP_4_2_7P90 + + ntpq/ntpq-opts.c@1.91 +2 -2 + NTP_4_2_7P90 + + ntpq/ntpq-opts.h@1.91 +3 -3 + NTP_4_2_7P90 + + ntpq/ntpq-opts.texi@1.91 +2 -2 + NTP_4_2_7P90 + + ntpq/ntpq.1@1.91 +2 -2 + NTP_4_2_7P90 + + ntpsnmpd/ntpsnmpd-opts.c@1.91 +2 -2 + NTP_4_2_7P90 + + ntpsnmpd/ntpsnmpd-opts.h@1.91 +3 -3 + NTP_4_2_7P90 + + ntpsnmpd/ntpsnmpd-opts.texi@1.91 +2 -2 + NTP_4_2_7P90 + + ntpsnmpd/ntpsnmpd.1@1.91 +2 -2 + NTP_4_2_7P90 + + packageinfo.sh@1.92 +1 -1 + NTP_4_2_7P90 + + sntp/sntp-opts.c@1.91 +2 -2 + NTP_4_2_7P90 + + sntp/sntp-opts.h@1.91 +3 -3 + NTP_4_2_7P90 + + sntp/sntp-opts.texi@1.91 +2 -2 + NTP_4_2_7P90 + + sntp/sntp.1@1.91 +2 -2 + NTP_4_2_7P90 + + sntp/sntp.html@1.91 +2 -2 + NTP_4_2_7P90 + + util/ntp-keygen-opts.c@1.89 +2 -2 + NTP_4_2_7P90 + + util/ntp-keygen-opts.h@1.89 +3 -3 + NTP_4_2_7P90 + + util/ntp-keygen-opts.texi@1.92 +2 -2 + NTP_4_2_7P90 + + util/ntp-keygen.1@1.92 +2 -2 + NTP_4_2_7P90 + +ChangeSet@1.2316, 2010-12-06 05:04:53+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1740] ntpdc -c reslist packet count wrongly treated as signed. + + ChangeLog@1.681 +1 -0 + [Bug 1740] ntpdc -c reslist packet count wrongly treated as signed. + + ntpdc/ntpdc_ops.c@1.68 +191 -197 + [Bug 1740] ntpdc -c reslist packet count wrongly treated as signed. + +ChangeSet@1.2315, 2010-12-06 02:15:22+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1738] Windows ntpd has wrong net adapter name. + Applies to prior cset merged from ntp-stable-1738 + + ChangeLog@1.680 +1 -0 + [Bug 1738] Windows ntpd has wrong net adapter name. + +ChangeSet@1.2082.40.13, 2010-12-06 02:14:03+00:00, davehart@shiny.ad.hartbrothers.com + Add GetAdaptersAddress()-based interface enumeration to libisc Windows code, + runtime linked on Windows XP SP1 and later only, which provides correct + interface name with each address. + + include/isc/mem.h@1.3 +19 -7 + Silence unreferenced warnings from Microsoft C compiler + + lib/isc/inet_pton.c@1.5 +3 -3 + Avoid C++ keyword "new" for variable name, silence Microsoft C + warning about truncation. + + lib/isc/netaddr.c@1.9 +1 -1 + Silence Microsoft C warning that const var 'zeros' should be initialized. + + lib/isc/win32/include/isc/once.h@1.5 +1 -1 + Use correct type for InterlockedExchange() target. + + lib/isc/win32/interfaceiter.c@1.18 +264 -70 + Add GetAdaptersAddress()-based interface enumeration, runtime linked on + Windows XP SP1 and later only, which provides correct interface name + with each address. + + lib/isc/win32/net.c@1.15 +0 -1 + Removed unused local, silencing warning. + + lib/isc/win32/stdtime.c@1.2 +1 -1 + Silence type conversion warning. + +ChangeSet@1.2313, 2010-12-04 20:54:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P89 + TAG: NTP_4_2_7P89 + + ChangeLog@1.679 +1 -0 + NTP_4_2_7P89 + + clockstuff/clktest-opts.c@1.13 +65 -62 + NTP_4_2_7P89 + + clockstuff/clktest-opts.h@1.13 +23 -59 + NTP_4_2_7P89 + + ntpd/ntpd-opts.c@1.93 +2 -2 + NTP_4_2_7P89 + + ntpd/ntpd-opts.h@1.93 +3 -3 + NTP_4_2_7P89 + + ntpd/ntpd-opts.texi@1.91 +2 -2 + NTP_4_2_7P89 + + ntpd/ntpd.1@1.91 +2 -2 + NTP_4_2_7P89 + + ntpdc/ntpdc-opts.c@1.90 +2 -2 + NTP_4_2_7P89 + + ntpdc/ntpdc-opts.h@1.90 +3 -3 + NTP_4_2_7P89 + + ntpdc/ntpdc-opts.texi@1.90 +2 -2 + NTP_4_2_7P89 + + ntpdc/ntpdc.1@1.90 +2 -2 + NTP_4_2_7P89 + + ntpq/ntpq-opts.c@1.90 +2 -2 + NTP_4_2_7P89 + + ntpq/ntpq-opts.h@1.90 +3 -3 + NTP_4_2_7P89 + + ntpq/ntpq-opts.texi@1.90 +2 -2 + NTP_4_2_7P89 + + ntpq/ntpq.1@1.90 +2 -2 + NTP_4_2_7P89 + + ntpsnmpd/ntpsnmpd-opts.c@1.90 +2 -2 + NTP_4_2_7P89 + + ntpsnmpd/ntpsnmpd-opts.h@1.90 +3 -3 + NTP_4_2_7P89 + + ntpsnmpd/ntpsnmpd-opts.texi@1.90 +2 -2 + NTP_4_2_7P89 + + ntpsnmpd/ntpsnmpd.1@1.90 +2 -2 + NTP_4_2_7P89 + + packageinfo.sh@1.91 +1 -1 + NTP_4_2_7P89 + + sntp/sntp-opts.c@1.90 +8 -14 + NTP_4_2_7P89 + + sntp/sntp-opts.h@1.90 +3 -3 + NTP_4_2_7P89 + + sntp/sntp-opts.texi@1.90 +38 -31 + NTP_4_2_7P89 + + sntp/sntp.1@1.90 +6 -6 + NTP_4_2_7P89 + + sntp/sntp.html@1.90 +356 -5 + NTP_4_2_7P89 + + util/ntp-keygen-opts.c@1.88 +2 -2 + NTP_4_2_7P89 + + util/ntp-keygen-opts.h@1.88 +3 -3 + NTP_4_2_7P89 + + util/ntp-keygen-opts.texi@1.91 +2 -2 + NTP_4_2_7P89 + + util/ntp-keygen.1@1.91 +2 -2 + NTP_4_2_7P89 + +ChangeSet@1.2312, 2010-12-04 15:54:37-05:00, stenn@deacon.udel.edu + Add clktest-opts.[ch] to .point-changed-filelist + + .point-changed-filelist@1.8 +2 -0 + Add clktest-opts.[ch] to .point-changed-filelist + +ChangeSet@1.2082.40.12, 2010-12-04 05:32:55-05:00, stenn@deacon.udel.edu + Clean up the SNTP documentation + + ChangeLog@1.496.26.122 +1 -0 + Clean up the SNTP documentation + + sntp/sntp-opts.def@1.17 +49 -27 + Clean up the SNTP documentation + + sntp/sntp.texi@1.4 +2 -2 + Clean up the SNTP documentation + +ChangeSet@1.2309, 2010-12-04 08:15:35+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1736] tos int, bool options broken in 4.2.7p66. + + ChangeLog@1.675.1.1 +2 -1 + [Bug 1736] tos int, bool options broken in 4.2.7p66. + + clockstuff/Makefile.am@1.13 +2 -1 + repair distcheck + + ntpd/ntp_config.c@1.277 +3 -8 + [Bug 1736] tos int, bool options broken in 4.2.7p66. + + ntpd/ntp_parser.c@1.73 +2 -2 + bison output + + ntpd/ntp_parser.y@1.67 +2 -2 + [Bug 1736] tos int, bool options broken in 4.2.7p66. + +ChangeSet@1.2308, 2010-12-04 07:42:26+00:00, davehart@shiny.ad.hartbrothers.com + centralize TTY header goop in ntp_tty.h. + move clockstuff utils closer to building cleanly. + + clockstuff/Makefile.am@1.12 +2 -2 + revive, repair bitrot + + clockstuff/clktest-opts.def@1.8 +0 -32 + remove hard-coded relative paths from #includes + + clockstuff/clktest.c@1.5 +34 -0 + include config.h + + include/ntp_machine.h@1.30 +0 -35 + move tty logic from ntp_machine.h to ntp_tty.h, include the latter + from ntp_refclock.h + + include/ntp_refclock.h@1.26 +2 -32 + move tty logic from ntp_machine.h to ntp_tty.h, include the latter + from ntp_refclock.h + + include/ntp_tty.h@1.4 +57 -11 + move tty logic from ntp_machine.h to ntp_tty.h, include the latter + from ntp_refclock.h + + libntp/icom.c@1.13 +4 -4 + use snprintf() + + ntpd/refclock_datum.c@1.15 +1 -11 + #include ntp_tty.h for TTY includes + +ChangeSet@1.2304.1.3, 2010-12-02 10:10:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P88 + TAG: NTP_4_2_7P88 + + ChangeLog@1.676 +1 -0 + NTP_4_2_7P88 + + ntpd/ntpd-opts.c@1.92 +2 -2 + NTP_4_2_7P88 + + ntpd/ntpd-opts.h@1.92 +3 -3 + NTP_4_2_7P88 + + ntpd/ntpd-opts.texi@1.90 +2 -2 + NTP_4_2_7P88 + + ntpd/ntpd.1@1.90 +2 -2 + NTP_4_2_7P88 + + ntpdc/ntpdc-opts.c@1.89 +2 -2 + NTP_4_2_7P88 + + ntpdc/ntpdc-opts.h@1.89 +3 -3 + NTP_4_2_7P88 + + ntpdc/ntpdc-opts.texi@1.89 +2 -2 + NTP_4_2_7P88 + + ntpdc/ntpdc.1@1.89 +2 -2 + NTP_4_2_7P88 + + ntpq/ntpq-opts.c@1.89 +2 -2 + NTP_4_2_7P88 + + ntpq/ntpq-opts.h@1.89 +3 -3 + NTP_4_2_7P88 + + ntpq/ntpq-opts.texi@1.89 +2 -2 + NTP_4_2_7P88 + + ntpq/ntpq.1@1.89 +2 -2 + NTP_4_2_7P88 + + ntpsnmpd/ntpsnmpd-opts.c@1.89 +2 -2 + NTP_4_2_7P88 + + ntpsnmpd/ntpsnmpd-opts.h@1.89 +3 -3 + NTP_4_2_7P88 + + ntpsnmpd/ntpsnmpd-opts.texi@1.89 +2 -2 + NTP_4_2_7P88 + + ntpsnmpd/ntpsnmpd.1@1.89 +2 -2 + NTP_4_2_7P88 + + packageinfo.sh@1.90 +1 -1 + NTP_4_2_7P88 + + sntp/sntp-opts.c@1.89 +2 -2 + NTP_4_2_7P88 + + sntp/sntp-opts.h@1.89 +3 -3 + NTP_4_2_7P88 + + sntp/sntp-opts.texi@1.89 +2 -2 + NTP_4_2_7P88 + + sntp/sntp.1@1.89 +2 -2 + NTP_4_2_7P88 + + sntp/sntp.html@1.89 +1 -1 + NTP_4_2_7P88 + + util/ntp-keygen-opts.c@1.87 +2 -2 + NTP_4_2_7P88 + + util/ntp-keygen-opts.h@1.87 +3 -3 + NTP_4_2_7P88 + + util/ntp-keygen-opts.texi@1.90 +2 -2 + NTP_4_2_7P88 + + util/ntp-keygen.1@1.90 +2 -2 + NTP_4_2_7P88 + +ChangeSet@1.2304.1.2, 2010-12-01 23:05:13+01:00, jnperlin@hydra.localnet + [Bug 1735] clocktime() aborts ntpd on bogus input: changed to regular error indication + + ChangeLog@1.675 +1 -0 + [Bug 1735] clocktime() aborts ntpd on bogus input: changed to regular error indication + + libntp/clocktime.c@1.5 +8 -7 + [Bug 1735] clocktime() aborts ntpd on bogus input: changed to regular error indication + +ChangeSet@1.2304.1.1, 2010-12-01 10:10:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P87 + TAG: NTP_4_2_7P87 + + ChangeLog@1.674 +1 -0 + NTP_4_2_7P87 + + ntpd/ntpd-opts.c@1.91 +2 -2 + NTP_4_2_7P87 + + ntpd/ntpd-opts.h@1.91 +3 -3 + NTP_4_2_7P87 + + ntpd/ntpd-opts.texi@1.89 +2 -2 + NTP_4_2_7P87 + + ntpd/ntpd.1@1.89 +2 -2 + NTP_4_2_7P87 + + ntpdc/ntpdc-opts.c@1.88 +2 -2 + NTP_4_2_7P87 + + ntpdc/ntpdc-opts.h@1.88 +3 -3 + NTP_4_2_7P87 + + ntpdc/ntpdc-opts.texi@1.88 +2 -2 + NTP_4_2_7P87 + + ntpdc/ntpdc.1@1.88 +2 -2 + NTP_4_2_7P87 + + ntpq/ntpq-opts.c@1.88 +2 -2 + NTP_4_2_7P87 + + ntpq/ntpq-opts.h@1.88 +3 -3 + NTP_4_2_7P87 + + ntpq/ntpq-opts.texi@1.88 +2 -2 + NTP_4_2_7P87 + + ntpq/ntpq.1@1.88 +2 -2 + NTP_4_2_7P87 + + ntpsnmpd/ntpsnmpd-opts.c@1.88 +2 -2 + NTP_4_2_7P87 + + ntpsnmpd/ntpsnmpd-opts.h@1.88 +3 -3 + NTP_4_2_7P87 + + ntpsnmpd/ntpsnmpd-opts.texi@1.88 +2 -2 + NTP_4_2_7P87 + + ntpsnmpd/ntpsnmpd.1@1.88 +2 -2 + NTP_4_2_7P87 + + packageinfo.sh@1.89 +1 -1 + NTP_4_2_7P87 + + sntp/sntp-opts.c@1.88 +2 -2 + NTP_4_2_7P87 + + sntp/sntp-opts.h@1.88 +3 -3 + NTP_4_2_7P87 + + sntp/sntp-opts.texi@1.88 +2 -2 + NTP_4_2_7P87 + + sntp/sntp.1@1.88 +2 -2 + NTP_4_2_7P87 + + sntp/sntp.html@1.88 +1 -1 + NTP_4_2_7P87 + + util/ntp-keygen-opts.c@1.86 +2 -2 + NTP_4_2_7P87 + + util/ntp-keygen-opts.h@1.86 +3 -3 + NTP_4_2_7P87 + + util/ntp-keygen-opts.texi@1.89 +2 -2 + NTP_4_2_7P87 + + util/ntp-keygen.1@1.89 +2 -2 + NTP_4_2_7P87 + +ChangeSet@1.2306, 2010-12-01 07:48:54+00:00, davehart@shiny.ad.hartbrothers.com + restore HP-UX net/if.h workaround to sntp subproj, needed by ntp.h + inclusion leading to isc/net.h and then net/if.h. + + clockstuff/chutest.c@1.4 +18 -7 + clean up bitrot in clockstuff + + sntp/configure.ac@1.48 +71 -0 + restore HP-UX net/if.h workaround to sntp subproj, needed by ntp.h + inclusion leading to isc/net.h and then net/if.h. + +ChangeSet@1.2305, 2010-12-01 04:50:51+00:00, davehart@shiny.ad.hartbrothers.com + Refine HP-UX mpinfou workaround to add predeclaration only if it helps. + Remove unused u_int8_t and u_int64_t tests. + Remove qsort type check, ANSI C nails it down. + Remove AC_C_CONST for similar reason. + Enable propdelay, chutest, clktest builds. + + clockstuff/Makefile.am@1.11 +29 -13 + revive, repair bitrot + + clockstuff/chutest.c@1.3 +31 -24 + include config.h + + clockstuff/clktest.c@1.4 +3 -0 + include config.h + + clockstuff/propdelay.c@1.5 +3 -0 + include config.h + + configure.ac@1.503 +175 -197 + Refine HP-UX mpinfou workaround to add predeclaration only if it helps. + Remove unused u_int8_t and u_int64_t tests. + Remove qsort type check, ANSI C nails it down. + Remove AC_C_CONST for similar reason. + Enable propdelay, chutest, clktest builds. + + m4/ntp_openssl.m4@1.5 +1 -1 + unset temp var + + sntp/configure.ac@1.47 +2 -48 + Remove HP-UX net/if.h workaround from sntp/configure.ac, no sntp code + uses net/if.h. + + util/Makefile.am@1.51 +1 -2 + remove archaic ansi2knr reference + +ChangeSet@1.2082.40.11, 2010-11-30 06:45:17+00:00, davehart@shiny.ad.hartbrothers.com + cleanup last changeset + + configure.ac@1.465.1.22 +2 -1 + AS_UNSET() works on only one variable, not a list + + m4/ntp_cacheversion.m4@1.10 +3 -1 + AS_UNSET() works on only one variable, not a list + + m4/ntp_lineeditlibs.m4@1.9 +4 -1 + AS_UNSET() works on only one variable, not a list + + sntp/configure.ac@1.31.1.8 +2 -1 + AS_UNSET() works on only one variable, not a list + +ChangeSet@1.2082.40.10, 2010-11-30 05:12:51+00:00, davehart@shiny.ad.hartbrothers.com + Clean up m4 quoting in configure.ac, *.m4 files, resolving + intermittent AC_LANG_PROGRAM possibly undefined errors. + + ChangeLog@1.496.26.121 +5 -0 + Clean up m4 quoting in configure.ac, *.m4 files, resolving + intermittent AC_LANG_PROGRAM possibly undefined errors. + + configure.ac@1.465.1.21 +3076 -2291 + M4 quoting cleanup + + m4/define_dir.m4@1.2 +4 -4 + M4 quoting cleanup + + m4/ntp_cacheversion.m4@1.9 +4 -8 + use AS_UNSET() equivalent consistently + + m4/ntp_dir_sep.m4@1.3 +19 -13 + m4 quoting cleanup + + m4/ntp_lib_m.m4@1.2 +2 -1 + m4 quoting cleannup + use AS_UNSET, m4/os_cflags has for a while without complaint. + + m4/ntp_lineeditlibs.m4@1.8 +23 -16 + m4 quoting cleannup + use AS_UNSET, m4/os_cflags has for a while without complaint. + + m4/ntp_openssl.m4@1.4 +76 -39 + m4 quoting cleannup + + m4/ntp_vpathhack.m4@1.2.1.1 +1 -1 + m4 quoting cleannup + + sntp/configure.ac@1.31.1.7 +364 -298 + M4 quoting cleanup, fix for 'possibly undefined AC_LANG_PROGRAM' seen + with bootstrap --force, triggered by errant getsockname() socklen type + check. + +ChangeSet@1.2302, 2010-11-29 09:19:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P86 + TAG: NTP_4_2_7P86 + + ChangeLog@1.672 +1 -0 + NTP_4_2_7P86 + + ntpd/ntpd-opts.c@1.90 +2 -2 + NTP_4_2_7P86 + + ntpd/ntpd-opts.h@1.90 +3 -3 + NTP_4_2_7P86 + + ntpd/ntpd-opts.texi@1.88 +2 -2 + NTP_4_2_7P86 + + ntpd/ntpd.1@1.88 +2 -2 + NTP_4_2_7P86 + + ntpdc/ntpdc-opts.c@1.87 +2 -2 + NTP_4_2_7P86 + + ntpdc/ntpdc-opts.h@1.87 +3 -3 + NTP_4_2_7P86 + + ntpdc/ntpdc-opts.texi@1.87 +2 -2 + NTP_4_2_7P86 + + ntpdc/ntpdc.1@1.87 +2 -2 + NTP_4_2_7P86 + + ntpq/ntpq-opts.c@1.87 +2 -2 + NTP_4_2_7P86 + + ntpq/ntpq-opts.h@1.87 +3 -3 + NTP_4_2_7P86 + + ntpq/ntpq-opts.texi@1.87 +2 -2 + NTP_4_2_7P86 + + ntpq/ntpq.1@1.87 +2 -2 + NTP_4_2_7P86 + + ntpsnmpd/ntpsnmpd-opts.c@1.87 +2 -2 + NTP_4_2_7P86 + + ntpsnmpd/ntpsnmpd-opts.h@1.87 +3 -3 + NTP_4_2_7P86 + + ntpsnmpd/ntpsnmpd-opts.texi@1.87 +2 -2 + NTP_4_2_7P86 + + ntpsnmpd/ntpsnmpd.1@1.87 +2 -2 + NTP_4_2_7P86 + + packageinfo.sh@1.88 +1 -1 + NTP_4_2_7P86 + + sntp/sntp-opts.c@1.87 +2 -2 + NTP_4_2_7P86 + + sntp/sntp-opts.h@1.87 +3 -3 + NTP_4_2_7P86 + + sntp/sntp-opts.texi@1.87 +2 -2 + NTP_4_2_7P86 + + sntp/sntp.1@1.87 +2 -2 + NTP_4_2_7P86 + + sntp/sntp.html@1.87 +1 -1 + NTP_4_2_7P86 + + util/ntp-keygen-opts.c@1.85 +2 -2 + NTP_4_2_7P86 + + util/ntp-keygen-opts.h@1.85 +3 -3 + NTP_4_2_7P86 + + util/ntp-keygen-opts.texi@1.88 +2 -2 + NTP_4_2_7P86 + + util/ntp-keygen.1@1.88 +2 -2 + NTP_4_2_7P86 + +ChangeSet@1.2301, 2010-11-28 19:24:29+00:00, davehart@shiny.ad.hartbrothers.com + implement configuration of association option ident specifying + the autokey group. Implementation not yet complete. + + include/ntp_config.h@1.70 +1 -0 + add group member to peer_node for ident option + + include/ntpd.h@1.147 +1 -1 + change previously unused last arg to peer_config() to group + for ident option. + + ntpd/complete.conf@1.13 +1 -1 + add peer ... ident test case + + ntpd/ntp_config.c@1.276 +24 -19 + add group member to peer_resolved_ctx, with group name from + ident option. + + ntpd/ntp_parser.c@1.72 +691 -689 + bison output + + ntpd/ntp_parser.y@1.66 +12 -0 + add ident option to association directives specifying Autokey group + + ntpd/ntp_peer.c@1.138 +11 -11 + change previously unused last arg to peer_config() to group + for ident option. + +ChangeSet@1.2082.40.9, 2010-11-28 01:03:45-05:00, stenn@deacon.udel.edu + Use A.host build directory names at ntp.org + + build@1.37 +5 -1 + Use A.host build directory names at ntp.org + +ChangeSet@1.2082.40.8, 2010-11-28 04:53:12+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC11 + TAG: NTP_4_2_6P3_RC11 + + ChangeLog@1.496.26.120 +1 -0 + NTP_4_2_6P3_RC11 + + ntpd/ntpd-opts.c@1.248.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + ntpd/ntpd-opts.h@1.248.28.1 +3 -3 + NTP_4_2_6P3_RC11 + + ntpd/ntpd-opts.menu@1.3.1.1 +1 -122 + NTP_4_2_6P3_RC11 + + ntpd/ntpd-opts.texi@1.246.28.1 +522 -0 + NTP_4_2_6P3_RC11 + + ntpd/ntpd.1@1.246.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + ntpdc/ntpdc-opts.c@1.244.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + ntpdc/ntpdc-opts.h@1.244.28.1 +3 -3 + NTP_4_2_6P3_RC11 + + ntpdc/ntpdc-opts.menu@1.3.1.1 +1 -122 + NTP_4_2_6P3_RC11 + + ntpdc/ntpdc-opts.texi@1.243.28.1 +207 -0 + NTP_4_2_6P3_RC11 + + ntpdc/ntpdc.1@1.243.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + ntpq/ntpq-opts.c@1.245.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + ntpq/ntpq-opts.h@1.245.28.1 +3 -3 + NTP_4_2_6P3_RC11 + + ntpq/ntpq-opts.menu@1.3.1.1 +1 -96 + NTP_4_2_6P3_RC11 + + ntpq/ntpq-opts.texi@1.244.28.1 +177 -0 + NTP_4_2_6P3_RC11 + + ntpq/ntpq.1@1.244.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.29.1 +2 -2 + NTP_4_2_6P3_RC11 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.29.1 +3 -3 + NTP_4_2_6P3_RC11 + + ntpsnmpd/ntpsnmpd-opts.menu@1.3.1.1 +1 -56 + NTP_4_2_6P3_RC11 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.29.1 +55 -0 + NTP_4_2_6P3_RC11 + + ntpsnmpd/ntpsnmpd.1@1.122.29.1 +2 -2 + NTP_4_2_6P3_RC11 + + packageinfo.sh@1.255.29.1 +1 -1 + NTP_4_2_6P3_RC11 + + sntp/sntp-opts.c@1.117.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + sntp/sntp-opts.h@1.117.28.1 +3 -3 + NTP_4_2_6P3_RC11 + + sntp/sntp-opts.menu@1.3.1.1 +1 -56 + NTP_4_2_6P3_RC11 + + sntp/sntp-opts.texi@1.117.28.1 +213 -0 + NTP_4_2_6P3_RC11 + + sntp/sntp.1@1.117.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + sntp/sntp.html@1.7.28.1 +6 -62 + NTP_4_2_6P3_RC11 + + util/ntp-keygen-opts.c@1.247.28.1 +2 -2 + NTP_4_2_6P3_RC11 + + util/ntp-keygen-opts.h@1.247.28.1 +3 -3 + NTP_4_2_6P3_RC11 + + util/ntp-keygen-opts.menu@1.3.1.1 +1 -94 + NTP_4_2_6P3_RC11 + + util/ntp-keygen-opts.texi@1.246.28.1 +314 -0 + NTP_4_2_6P3_RC11 + + util/ntp-keygen.1@1.246.28.1 +2 -2 + NTP_4_2_6P3_RC11 + +ChangeSet@1.2082.40.7, 2010-11-27 23:10:00-05:00, stenn@deacon.udel.edu + Improvements to the 'build' script + + ChangeLog@1.496.26.119 +1 -0 + Improvements to the 'build' script + + build@1.36 +60 -18 + Improvements to the 'build' script + +ChangeSet@1.2299, 2010-11-27 17:56:17-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.670 +1 -0 + Documentation updates from Dave Mills + + html/pic/sx5.gif@1.1 +456 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/sx5.gif + + html/pic/sx5.gif@1.0 +0 -0 + +ChangeSet@1.2298, 2010-11-27 22:30:13+00:00, stenn@deacon.udel.edu + NTP_4_2_7P85 + TAG: NTP_4_2_7P85 + + ChangeLog@1.669 +1 -0 + NTP_4_2_7P85 + + ntpd/ntpd-opts.c@1.89 +2 -2 + NTP_4_2_7P85 + + ntpd/ntpd-opts.h@1.89 +3 -3 + NTP_4_2_7P85 + + ntpd/ntpd-opts.menu@1.5 +1 -64 + NTP_4_2_7P85 + + ntpd/ntpd-opts.texi@1.87 +642 -0 + NTP_4_2_7P85 + + ntpd/ntpd.1@1.87 +2 -2 + NTP_4_2_7P85 + + ntpdc/ntpdc-opts.c@1.86 +2 -2 + NTP_4_2_7P85 + + ntpdc/ntpdc-opts.h@1.86 +3 -3 + NTP_4_2_7P85 + + ntpdc/ntpdc-opts.menu@1.5 +1 -58 + NTP_4_2_7P85 + + ntpdc/ntpdc-opts.texi@1.86 +271 -0 + NTP_4_2_7P85 + + ntpdc/ntpdc.1@1.86 +2 -2 + NTP_4_2_7P85 + + ntpq/ntpq-opts.c@1.86 +2 -2 + NTP_4_2_7P85 + + ntpq/ntpq-opts.h@1.86 +3 -3 + NTP_4_2_7P85 + + ntpq/ntpq-opts.menu@1.5 +1 -47 + NTP_4_2_7P85 + + ntpq/ntpq-opts.texi@1.86 +226 -0 + NTP_4_2_7P85 + + ntpq/ntpq.1@1.86 +2 -2 + NTP_4_2_7P85 + + ntpsnmpd/ntpsnmpd-opts.c@1.86 +2 -2 + NTP_4_2_7P85 + + ntpsnmpd/ntpsnmpd-opts.h@1.86 +3 -3 + NTP_4_2_7P85 + + ntpsnmpd/ntpsnmpd-opts.menu@1.5 +1 -34 + NTP_4_2_7P85 + + ntpsnmpd/ntpsnmpd-opts.texi@1.86 +77 -0 + NTP_4_2_7P85 + + ntpsnmpd/ntpsnmpd.1@1.86 +2 -2 + NTP_4_2_7P85 + + packageinfo.sh@1.87 +1 -1 + NTP_4_2_7P85 + + sntp/sntp-opts.c@1.86 +2 -2 + NTP_4_2_7P85 + + sntp/sntp-opts.h@1.86 +3 -3 + NTP_4_2_7P85 + + sntp/sntp-opts.menu@1.5 +1 -56 + NTP_4_2_7P85 + + sntp/sntp-opts.texi@1.86 +271 -0 + NTP_4_2_7P85 + + sntp/sntp.1@1.86 +2 -2 + NTP_4_2_7P85 + + sntp/sntp.html@1.86 +6 -62 + NTP_4_2_7P85 + + util/ntp-keygen-opts.c@1.84 +2 -2 + NTP_4_2_7P85 + + util/ntp-keygen-opts.h@1.84 +3 -3 + NTP_4_2_7P85 + + util/ntp-keygen-opts.menu@1.6 +1 -51 + NTP_4_2_7P85 + + util/ntp-keygen-opts.texi@1.87 +374 -0 + NTP_4_2_7P85 + + util/ntp-keygen.1@1.87 +2 -2 + NTP_4_2_7P85 + +ChangeSet@1.2297, 2010-11-24 05:32:32-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.668 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.8 +77 -69 + Documentation updates from Dave Mills + +ChangeSet@1.2082.40.6, 2010-11-24 04:13:50-05:00, stenn@deacon.udel.edu + Update the NEWS file to include work done in RC11 + + NEWS@1.113 +6 -1 + Update the NEWS file to include work done in RC11 + +ChangeSet@1.2082.40.5, 2010-11-24 04:00:30-05:00, stenn@deacon.udel.edu + [Bug 1733] IRIX doesn't have 'head' (affects scripts/checkChangeLog) + + ChangeLog@1.496.26.118 +1 -0 + [Bug 1733] IRIX doesn't have 'head' (affects scripts/checkChangeLog) + + scripts/checkChangeLog@1.1.2.2 +2 -1 + [Bug 1733] IRIX doesn't have 'head' (affects scripts/checkChangeLog) + +ChangeSet@1.2296, 2010-11-24 00:36:54+00:00, davehart@shiny.ad.hartbrothers.com + cleanup AC_LANG_PROGRAM quoting to silence autoreconf + + configure.ac@1.500 +4 -4 + cleanup AC_LANG_PROGRAM quoting to silence autoreconf + +ChangeSet@1.2082.40.4, 2010-11-23 14:58:05+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac m4 quoting cleanup + attempt to quiet expanded before required warnings from libopts + + configure.ac@1.465.1.20 +8 -8 + correct m4 quoting + + sntp/configure.ac@1.31.1.6 +6 -6 + configure.ac m4 quoting cleanup + + sntp/libopts/m4/libopts.m4@1.9 +6 -9 + attempt to quiet expanded before required warnings from libopts + +ChangeSet@1.2082.40.3, 2010-11-23 12:26:32+00:00, davehart@shiny.ad.hartbrothers.com + workaround for HP-UX /usr/include/machine/sys/getppdp.h gcc4 break. + + configure.ac@1.465.1.19 +61 -26 + workaround for HP-UX /usr/include/machine/sys/getppdp.h gcc4 break. + + sntp/configure.ac@1.31.1.5 +49 -1 + workaround for HP-UX /usr/include/machine/sys/getppdp.h gcc4 break. + + +ChangeSet@1.2082.40.2, 2010-11-23 09:49:49+00:00, davehart@shiny.ad.hartbrothers.com + correct m4 quoting to quiet autoreconf warnings + enable ./bootstrap --force + + bootstrap@1.28.1.7 +4 -2 + enable ./bootstrap --force + + configure.ac@1.465.1.18 +17 -14 + correct m4 quoting to quiet autoreconf warnings + + m4/ntp_openssl.m4@1.3 +7 -7 + correct m4 quoting to quiet autoreconf warnings + + sntp/configure.ac@1.31.1.4 +11 -8 + correct m4 quoting to quiet autoreconf warnings + +ChangeSet@1.2082.39.4, 2010-11-23 03:54:56+00:00, hart@psp-fb1.ntp.org + build: + Do not skip configure if it is newer than config.status + + build@1.35 +7 -3 + Do not skip configure if it is newer than config.status + +ChangeSet@1.2082.39.3, 2010-11-22 22:54:53+00:00, davehart@shiny.ad.hartbrothers.com + Reduce bootstrap redundancy with autoreconf --no-recursive in the + top level, followed by recursive autoreconf in sntp. + + bootstrap@1.28.1.6 +2 -1 + Reduce bootstrap redundancy with autoreconf --no-recursive in the + top level, followed by recursive autoreconf in sntp. + +ChangeSet@1.2082.39.2, 2010-11-22 07:03:31+00:00, davehart@shiny.ad.hartbrothers.com + BBF to the rescue finding typos in #ifdef'd code + + ntpd/ntp_io.c@1.306.1.12 +1 -1 + BBF to the rescue finding typos in #ifdef'd code + + sntp/networking.c@1.29.1.11 +2 -1 + BBF to the rescue finding typos in #ifdef'd code + +ChangeSet@1.2293, 2010-11-22 05:27:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P84 + TAG: NTP_4_2_7P84 + + ChangeLog@1.667 +1 -0 + NTP_4_2_7P84 + + ntpd/ntpd-opts.c@1.88 +5 -5 + NTP_4_2_7P84 + + ntpd/ntpd-opts.h@1.88 +4 -4 + NTP_4_2_7P84 + + ntpd/ntpd-opts.menu@1.4 +3 -61 + NTP_4_2_7P84 + + ntpd/ntpd-opts.texi@1.86 +0 -642 + NTP_4_2_7P84 + + ntpd/ntpd.1@1.86 +4 -3 + NTP_4_2_7P84 + + ntpdc/ntpdc-opts.c@1.85 +75 -72 + NTP_4_2_7P84 + + ntpdc/ntpdc-opts.h@1.85 +22 -24 + NTP_4_2_7P84 + + ntpdc/ntpdc-opts.menu@1.4 +2 -66 + NTP_4_2_7P84 + + ntpdc/ntpdc-opts.texi@1.85 +0 -271 + NTP_4_2_7P84 + + ntpdc/ntpdc.1@1.85 +2 -2 + NTP_4_2_7P84 + + ntpq/ntpq-opts.c@1.85 +73 -68 + NTP_4_2_7P84 + + ntpq/ntpq-opts.h@1.85 +22 -24 + NTP_4_2_7P84 + + ntpq/ntpq-opts.menu@1.4 +2 -51 + NTP_4_2_7P84 + + ntpq/ntpq-opts.texi@1.85 +0 -226 + NTP_4_2_7P84 + + ntpq/ntpq.1@1.85 +2 -2 + NTP_4_2_7P84 + + ntpsnmpd/ntpsnmpd-opts.c@1.85 +55 -52 + NTP_4_2_7P84 + + ntpsnmpd/ntpsnmpd-opts.h@1.85 +22 -24 + NTP_4_2_7P84 + + ntpsnmpd/ntpsnmpd-opts.menu@1.4 +2 -24 + NTP_4_2_7P84 + + ntpsnmpd/ntpsnmpd-opts.texi@1.85 +0 -78 + NTP_4_2_7P84 + + ntpsnmpd/ntpsnmpd.1@1.85 +2 -2 + NTP_4_2_7P84 + + packageinfo.sh@1.86 +1 -1 + NTP_4_2_7P84 + + sntp/sntp-opts.c@1.85 +81 -78 + NTP_4_2_7P84 + + sntp/sntp-opts.h@1.85 +22 -24 + NTP_4_2_7P84 + + sntp/sntp-opts.menu@1.4 +1 -1 + NTP_4_2_7P84 + + sntp/sntp-opts.texi@1.85 +0 -213 + NTP_4_2_7P84 + + sntp/sntp.1@1.85 +2 -2 + NTP_4_2_7P84 + + sntp/sntp.html@1.85 +62 -6 + NTP_4_2_7P84 + + util/ntp-keygen-opts.c@1.83 +5 -5 + NTP_4_2_7P84 + + util/ntp-keygen-opts.h@1.83 +4 -4 + NTP_4_2_7P84 + + util/ntp-keygen-opts.menu@1.5 +51 -1 + NTP_4_2_7P84 + + util/ntp-keygen-opts.texi@1.86 +0 -374 + NTP_4_2_7P84 + + util/ntp-keygen.1@1.86 +2 -2 + NTP_4_2_7P84 + +ChangeSet@1.2082.39.1, 2010-11-22 03:54:12+00:00, davehart@shiny.ad.hartbrothers.com + Bump minimum Automake version to 1.11, required for AM_COND_IF + use in LIBOPTS_CHECK. + + ChangeLog@1.496.26.117 +3 -1 + Bump minimum Automake version to 1.11, required for AM_COND_IF + use in LIBOPTS_CHECK. + + Makefile.am@1.93.2.6 +2 -1 + bump minimum Automake version to 1.11 for AM_COND_IF support + needed by local mod to libopts/m4/libopts.m4 + + sntp/Makefile.am@1.21.2.1 +2 -1 + bump minimum Automake version to 1.11 for AM_COND_IF support + needed by local mod to libopts/m4/libopts.m4 + +ChangeSet@1.2291, 2010-11-22 03:17:40+00:00, davehart@shiny.ad.hartbrothers.com + Add "nonvolatile" ntp.conf directive to control how often the + driftfile is written. + + ChangeLog@1.665 +2 -0 + Add "nonvolatile" ntp.conf directive to control how often the + driftfile is written. + + include/ntp.h@1.188 +0 -1 + "tos nonvolatile" was mistaken + + ntpd/complete.conf@1.12 +3 -2 + Add "nonvolatile" ntp.conf directive to control how often the + driftfile is written. + + ntpd/ntp_config.c@1.275 +63 -34 + Add "nonvolatile" ntp.conf directive to control how often the + driftfile is written. + + ntpd/ntp_parser.c@1.71 +403 -401 + bison output + + ntpd/ntp_parser.y@1.65 +1 -1 + Add "nonvolatile" ntp.conf directive to control how often the + driftfile is written. + + ntpd/ntp_scanner.c@1.39 +6 -8 + Allow doubles with exponent and without a decimal point. + +ChangeSet@1.2290, 2010-11-21 23:12:16+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1618] Unreachable code in jjy_start(). + JJY driver improvements for Tristate JJY01/02, including changes + to its clockstats format. + + applies to prior cset merged from a -stable repo + + ChangeLog@1.664 +3 -0 + [Bug 1618] Unreachable code in jjy_start(). + JJY driver improvements for Tristate JJY01/02, including changes + to its clockstats format. + + +ChangeSet@1.2082.4.171, 2010-11-21 23:03:15+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1618] jjy_start() unreachable code. + refclock_jjy.c Tristate JJY01/02 improvements. + + html/copyright.html@1.46.1.2 +1 -0 + Credit refclock_jjy author Takao Abe + + ntpd/refclock_jjy.c@1.19 +586 -348 + [Bug 1618] jjy_start() unreachable code. + refclock_jjy.c Tristate JJY01/02 improvements. + +ChangeSet@1.2287, 2010-11-20 23:22:10+00:00, davehart@shiny.ad.hartbrothers.com + remove Autogen 5.10 --wait-sync workaround from ntpdbase-opts.def, ntpd.c + + ntpd/ntpd-opts.c@1.87 +147 -170 + autogen output + + ntpd/ntpd-opts.h@1.87 +24 -22 + autogen output + + ntpd/ntpd.c@1.119 +1 -2 + remove Autogen 5.10 --wait-sync workaround from ntpdbase-opts.def, ntpd.c + + ntpd/ntpdbase-opts.def@1.22 +1 -6 + remove Autogen 5.10 --wait-sync workaround from ntpdbase-opts.def, ntpd.c + +ChangeSet@1.2082.4.170, 2010-11-20 17:18:02-05:00, stenn@deacon.udel.edu + hack around a problem building sntp/sntp.html + + sntp/Makefile.am@1.21.1.11 +1 -1 + hack around a problem building sntp/sntp.html + +ChangeSet@1.2082.4.169, 2010-11-20 16:54:28-05:00, stenn@deacon.udel.edu + Add support for "br-flock -1" + + br-flock@1.15 +14 -1 + Add support for "br-flock -1" + +ChangeSet@1.2082.4.168, 2010-11-20 20:53:00+00:00, davehart@shiny.ad.hartbrothers.com + repair make distcheck failure with sntp/libopts/Makefile + + Makefile.am@1.93.2.5 +2 -8 + move sntp earlier than libopts users in SUBDIRS, + remove sntp/libopts from SUBDIRS, to repair make distcheck + with a shared libopts. + + bootstrap@1.28.1.5 +5 -1 + once again use workaround of invoking autoreconf in sntp after the + top level, to ensure a correct sntp/libopts/Makefile.in. + + configure.ac@1.465.1.17 +1 -1 + do not AC_CONFIG_FILES(sntp/libopts/Makefile) + + sntp/Makefile.am@1.21.1.10 +10 -11 + remove . from SUBDIRS + + sntp/libopts/m4/libopts.m4@1.8 +12 -7 + add 2nd arg to LIBOPTS_CHECK controlling AC_CONFIG_FILES(libopts/Makefile]) + +ChangeSet@1.2082.4.167, 2010-11-20 02:50:43-05:00, stenn@deacon.udel.edu + Remove top-level libopts/ + + BitKeeper/deleted/.del-COPYING.gplv3~f03d8366c675c284@1.1.1.1 +0 -0 + Delete: libopts/COPYING.gplv3 + + BitKeeper/deleted/.del-COPYING.lgplv3~40be4cbf4ae10117@1.1.1.1 +0 -0 + Delete: libopts/COPYING.lgplv3 + + BitKeeper/deleted/.del-COPYING.mbsd~a5472d893521969b@1.1.1.1 +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc~c629403b9830e97a@1.1.1.1 +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~b7467cbc80acbbcc@1.2.1.1 +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-README~5bc90a91ec6411e6@1.2.1.1 +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-ag-char-map.h~bedbb0c05ab02a70@1.5.1.1 +0 -0 + Delete: libopts/ag-char-map.h + + BitKeeper/deleted/.del-autoopts.c~54350751ea38f4a9@1.4.1.1 +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~56d3d4b1ff6e5a32@1.4.1.1 +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~8e1af2515312893c@1.4.1.1 +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~7caca4e98e77c39@1.4.1.1 +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~edfc1b173dd4ca72@1.4.1.1 +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-cook.c~a6052eddf9363b9@1.4.1.1 +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c~95e4ac5ad1bbc51d@1.4.1.1 +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~3cd90226bb7b2b17@1.5.1.1 +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-file.c~67e1b8b29a3953c9@1.4.1.1 +0 -0 + Delete: libopts/file.c + + BitKeeper/deleted/.del-genshell.c~3290a02566a5dbb7@1.5.1.1 +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~c39a618c8d4061cd@1.5.1.1 +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c~3ef92daf425d2b@1.1.1.1 +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~93a05c922cf88420@1.5.1.1 +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~1413f38bcfcfd143@1.4.1.1 +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~1667134a8de0561c@1.4.1.1 +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-makeshell.c~20cbf9416110166e@1.4.1.1 +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~f07a7d9124c8d2aa@1.4.1.1 +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~2cd8f01381095e42@1.4.1.1 +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-options.h~f2e0c23c8e5e59e8@1.5.1.1 +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-parse-duration.c~43baef4a99281837@1.1.1.1 +0 -0 + Delete: libopts/parse-duration.c + + BitKeeper/deleted/.del-parse-duration.h~17a3a3e1c22145d@1.1.1.1 +0 -0 + Delete: libopts/parse-duration.h + + BitKeeper/deleted/.del-pathfind.c~91eee34e6931c147@1.4.1.1 +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~a31853764946ed10@1.4.1.1 +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~f433f2d660b72a7d@1.5.1.1 +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~1e2cc4a1ffb8fafd@1.4.1.1 +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-reset.c~676b344e8e06553d@1.4.1.1 +0 -0 + Delete: libopts/reset.c + + BitKeeper/deleted/.del-restore.c~7503fbe1eb367c27@1.4.1.1 +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-save.c~c7023eeab566cc5a@1.5.1.1 +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~4020216a304b1fdf@1.1.1.1 +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c~a0f0aca832b2554c@1.4.1.1 +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-stack.c~159a2b84f1ceafab@1.4.1.1 +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~e00f88c19bec996f@1.1.1.1 +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~d58e7b55af5b3f83@1.1.1.1 +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~59b1ce7223f3432@1.4.1.1 +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~b601dfb63675456e@1.4.1.1 +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-time.c~41f39a05ffd762ac@1.4.1.1 +0 -0 + Delete: libopts/time.c + + BitKeeper/deleted/.del-tokenize.c~c52b9718bf168782@1.2.1.1 +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h~ca24f451aac51f1f@1.5.1.1 +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~5148c9dc95efdc1a@1.4.1.1 +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-value-type.c~eab6702e458dce8d@1.2.1.1 +0 -0 + Delete: libopts/value-type.c + + BitKeeper/deleted/.del-value-type.h~8c9e9714f716dd59@1.5.1.1 +0 -0 + Delete: libopts/value-type.h + + BitKeeper/deleted/.del-version.c~c1c141f1786ce61c@1.4.1.1 +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~461ddbe1169c297b@1.4.1.1 +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-xat-attribute.c~8a808fcad835c47f@1.2.1.1 +0 -0 + Delete: libopts/xat-attribute.c + + BitKeeper/deleted/.del-xat-attribute.h~7d19c77e5ff1a904@1.5.1.1 +0 -0 + Delete: libopts/xat-attribute.h + +ChangeSet@1.2082.4.166, 2010-11-20 02:18:46-05:00, stenn@deacon.udel.edu + backport the html timestamp fixes for bootstrap + + bootstrap@1.28.1.4 +8 -4 + backport the html timestamp fixes for bootstrap + +ChangeSet@1.2284, 2010-11-20 07:15:32+00:00, davehart@shiny.ad.hartbrothers.com + Add ntp-keygen -l/--lifetime to control certificate expiry. + + ChangeLog@1.663 +1 -0 + Add ntp-keygen -l/--lifetime to control certificate expiry. + + util/ntp-keygen-opts.c@1.82 +149 -126 + add ntp-keygen -l/--lifetime # to set days until expiration + + util/ntp-keygen-opts.def@1.13 +13 -1 + add ntp-keygen -l/--lifetime # to set days until expiration + + util/ntp-keygen-opts.h@1.82 +47 -38 + add ntp-keygen -l/--lifetime # to set days until expiration + + util/ntp-keygen-opts.menu@1.2.1.1 +1 -94 + add ntp-keygen -l/--lifetime # to set days until expiration + + util/ntp-keygen-opts.texi@1.85 +95 -79 + add ntp-keygen -l/--lifetime # to set days until expiration + + util/ntp-keygen.1@1.85 +9 -3 + add ntp-keygen -l/--lifetime # to set days until expiration + + util/ntp-keygen.c@1.69 +4 -1 + add ntp-keygen -l/--lifetime # to set days until expiration + +ChangeSet@1.2082.4.165, 2010-11-20 00:20:40-05:00, stenn@deacon.udel.edu + Properly quote the configure.ac LIBOPTS_CHECK argument + + configure.ac@1.465.1.16 +1 -1 + Properly quote the configure.ac LIBOPTS_CHECK argument + +ChangeSet@1.2082.4.164, 2010-11-20 00:18:39-05:00, stenn@deacon.udel.edu + autogen-5.11.3 upgrade + + sntp/libopts/Makefile.am@1.5 +3 -3 + autogen-5.11.3 upgrade + + sntp/libopts/ag-char-map.h@1.8 +1 -1 + autogen-5.11.3 upgrade + + sntp/libopts/configfile.c@1.7 +7 -5 + autogen-5.11.3 upgrade + + sntp/libopts/genshell.c@1.8 +1 -1 + autogen-5.11.3 upgrade + + sntp/libopts/genshell.h@1.8 +1 -1 + autogen-5.11.3 upgrade + + sntp/libopts/proto.h@1.8 +1 -1 + autogen-5.11.3 upgrade + + sntp/libopts/value-type.h@1.8 +1 -1 + autogen-5.11.3 upgrade + + sntp/libopts/xat-attribute.h@1.8 +1 -1 + autogen-5.11.3 upgrade + +ChangeSet@1.2082.4.163, 2010-11-20 00:16:33-05:00, stenn@deacon.udel.edu + autogen upgrade + + ntpd/ntpd-opts.menu@1.3 +1 -1 + autogen upgrade + + ntpdc/ntpdc-opts.menu@1.3 +3 -3 + autogen upgrade + + ntpq/ntpq-opts.menu@1.3 +3 -3 + autogen upgrade + + ntpsnmpd/ntpsnmpd-opts.menu@1.3 +24 -2 + autogen upgrade + + sntp/sntp-opts.menu@1.3 +56 -1 + autogen upgrade + + util/ntp-keygen-opts.menu@1.3 +4 -4 + autogen upgrade + +ChangeSet@1.2082.4.162, 2010-11-20 00:14:13-05:00, stenn@deacon.udel.edu + autogen upgrade + + ntpd/ntpd-opts.c@1.248.27.1 +142 -140 + autogen upgrade + + ntpd/ntpd-opts.h@1.248.27.1 +20 -22 + autogen upgrade + + ntpd/ntpd-opts.texi@1.246.27.1 +0 -583 + autogen upgrade + + ntpd/ntpd.1@1.246.27.1 +2 -2 + autogen upgrade + + ntpdc/ntpdc-opts.c@1.244.27.1 +74 -71 + autogen upgrade + + ntpdc/ntpdc-opts.h@1.244.27.1 +20 -22 + autogen upgrade + + ntpdc/ntpdc-opts.texi@1.243.27.1 +0 -271 + autogen upgrade + + ntpdc/ntpdc.1@1.243.27.1 +2 -2 + autogen upgrade + + ntpq/ntpq-opts.c@1.245.27.1 +72 -67 + autogen upgrade + + ntpq/ntpq-opts.h@1.245.27.1 +20 -22 + autogen upgrade + + ntpq/ntpq-opts.texi@1.244.27.1 +0 -226 + autogen upgrade + + ntpq/ntpq.1@1.244.27.1 +2 -2 + autogen upgrade + + ntpsnmpd/ntpsnmpd-opts.c@1.123.28.1 +54 -51 + autogen upgrade + + ntpsnmpd/ntpsnmpd-opts.h@1.123.28.1 +20 -22 + autogen upgrade + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.28.1 +0 -78 + autogen upgrade + + ntpsnmpd/ntpsnmpd.1@1.122.28.1 +2 -2 + autogen upgrade + + sntp/sntp-opts.c@1.117.27.1 +80 -77 + autogen upgrade + + sntp/sntp-opts.h@1.117.27.1 +20 -22 + autogen upgrade + + sntp/sntp-opts.texi@1.117.27.1 +0 -213 + autogen upgrade + + sntp/sntp.1@1.117.27.1 +2 -2 + autogen upgrade + + sntp/sntp.html@1.7.27.1 +61 -5 + autogen upgrade + + util/ntp-keygen-opts.c@1.247.27.1 +98 -105 + autogen upgrade + + util/ntp-keygen-opts.h@1.247.27.1 +20 -22 + autogen upgrade + + util/ntp-keygen-opts.texi@1.246.27.1 +0 -358 + autogen upgrade + + util/ntp-keygen.1@1.246.27.1 +2 -2 + autogen upgrade + +ChangeSet@1.2282, 2010-11-20 04:35:13+00:00, davehart@shiny.ad.hartbrothers.com + add "tos nonvolatile" to control interval between driftfile writes. + + include/ntp.h@1.187 +1 -0 + add "tos nonvolatile" to control interval between driftfile writes. + + ntpd/complete.conf@1.11 +1 -1 + add "tos nonvolatile" to control interval between driftfile writes. + + ntpd/keyword-gen-utd@1.12 +1 -1 + keyword-gen output + + ntpd/keyword-gen.c@1.16 +1 -0 + add "tos nonvolatile" to control interval between driftfile writes. + + ntpd/ntp_config.c@1.274 +4 -0 + add "tos nonvolatile" to control interval between driftfile writes. + + ntpd/ntp_keyword.h@1.14 +512 -503 + keyword-gen output + + ntpd/ntp_parser.c@1.70 +810 -805 + bison output + + ntpd/ntp_parser.h@1.41 +149 -147 + bison output + + ntpd/ntp_parser.y@1.64 +2 -0 + add "tos nonvolatile" to control interval between driftfile writes. + +ChangeSet@1.2082.4.161, 2010-11-19 23:29:22-05:00, stenn@psp-deb1.ntp.org + Update generated .menu files + + ntpd/ntpd-opts.menu@1.2 +122 -1 + Update generated .menu files + + ntpdc/ntpdc-opts.menu@1.2 +122 -1 + Update generated .menu files + + ntpq/ntpq-opts.menu@1.2 +96 -1 + Update generated .menu files + + ntpsnmpd/ntpsnmpd-opts.menu@1.2 +34 -1 + Update generated .menu files + + util/ntp-keygen-opts.menu@1.2 +94 -1 + Update generated .menu files + +ChangeSet@1.2082.4.160, 2010-11-19 23:27:51-05:00, stenn@psp-deb1.ntp.org + Use the new autoopts no-misuse-usage keyword + + include/copyright.def@1.12 +1 -0 + Use the new autoopts no-misuse-usage keyword + +ChangeSet@1.2082.4.159, 2010-11-19 23:26:17-05:00, stenn@psp-deb1.ntp.org + Upgrade libopts to 33.3.8 and autogen to 5.11.3 + + ChangeLog@1.496.26.116 +2 -0 + Use a single copy of libopts/, in sntp/ + + Makefile.am@1.93.2.4 +11 -15 + Use a single copy of libopts/, in sntp/ + + configure.ac@1.465.1.15 +1 -1 + Use a single copy of libopts/, in sntp/ + + deps-ver@1.1.1.1 +1 -1 + Use a single copy of libopts/, in sntp/ + + sntp/libopts/COPYING.gplv3@1.3 +1 -1 + libopts-33.3.8 + + sntp/libopts/COPYING.lgplv3@1.3 +1 -1 + libopts-33.3.8 + + sntp/libopts/Makefile.am@1.4 +5 -5 + libopts-33.3.8 + + sntp/libopts/README@1.4 +1 -1 + libopts-33.3.8 + + sntp/libopts/ag-char-map.h@1.7 +89 -57 + libopts-33.3.8 + + sntp/libopts/autoopts.c@1.6 +84 -83 + libopts-33.3.8 + + sntp/libopts/autoopts.h@1.6 +24 -21 + libopts-33.3.8 + + sntp/libopts/autoopts/options.h@1.7 +48 -44 + libopts-33.3.8 + + sntp/libopts/autoopts/usage-txt.h@1.7 +151 -144 + libopts-33.3.8 + + sntp/libopts/boolean.c@1.6 +5 -4 + libopts-33.3.8 + + sntp/libopts/compat/compat.h@1.6 +4 -5 + libopts-33.3.8 + + sntp/libopts/compat/pathfind.c@1.6 +1 -4 + libopts-33.3.8 + + sntp/libopts/compat/windows-config.h@1.6 +2 -3 + libopts-33.3.8 + + sntp/libopts/configfile.c@1.6 +242 -219 + libopts-33.3.8 + + sntp/libopts/cook.c@1.6 +5 -5 + libopts-33.3.8 + + sntp/libopts/enumeration.c@1.6 +145 -140 + libopts-33.3.8 + + sntp/libopts/environment.c@1.7 +27 -24 + libopts-33.3.8 + + sntp/libopts/file.c@1.6 +5 -4 + libopts-33.3.8 + + sntp/libopts/genshell.c@1.7 +36 -35 + libopts-33.3.8 + + sntp/libopts/genshell.h@1.7 +20 -22 + libopts-33.3.8 + + sntp/libopts/load.c@1.6 +47 -65 + libopts-33.3.8 + + sntp/libopts/m4/libopts.m4@1.7 +48 -46 + libopts-33.3.8 + + sntp/libopts/m4/liboptschk.m4@1.6 +2 -2 + libopts-33.3.8 + + sntp/libopts/makeshell.c@1.6 +203 -188 + libopts-33.3.8 + + sntp/libopts/nested.c@1.6 +116 -136 + libopts-33.3.8 + + sntp/libopts/numeric.c@1.6 +5 -4 + libopts-33.3.8 + + sntp/libopts/parse-duration.c@1.3 +2 -2 + libopts-33.3.8 + + sntp/libopts/parse-duration.h@1.3 +9 -1 + libopts-33.3.8 + + sntp/libopts/pgusage.c@1.6 +19 -18 + libopts-33.3.8 + + sntp/libopts/proto.h@1.7 +20 -17 + libopts-33.3.8 + + sntp/libopts/putshell.c@1.6 +179 -127 + libopts-33.3.8 + + sntp/libopts/reset.c@1.6 +5 -4 + libopts-33.3.8 + + sntp/libopts/restore.c@1.6 +20 -19 + libopts-33.3.8 + + sntp/libopts/save.c@1.7 +77 -77 + libopts-33.3.8 + + sntp/libopts/sort.c@1.6 +35 -35 + libopts-33.3.8 + + sntp/libopts/stack.c@1.6 +19 -19 + libopts-33.3.8 + + sntp/libopts/streqvcmp.c@1.6 +13 -12 + libopts-33.3.8 + + sntp/libopts/text_mmap.c@1.6 +31 -31 + libopts-33.3.8 + + sntp/libopts/time.c@1.6 +7 -6 + libopts-33.3.8 + + sntp/libopts/tokenize.c@1.4 +117 -105 + libopts-33.3.8 + + sntp/libopts/usage.c@1.6 +299 -196 + libopts-33.3.8 + + sntp/libopts/value-type.c@1.4 +4 -1 + libopts-33.3.8 + + sntp/libopts/value-type.h@1.7 +1 -1 + libopts-33.3.8 + + sntp/libopts/version.c@1.6 +32 -28 + libopts-33.3.8 + + sntp/libopts/xat-attribute.c@1.4 +4 -1 + libopts-33.3.8 + + sntp/libopts/xat-attribute.h@1.7 +1 -1 + libopts-33.3.8 + +ChangeSet@1.2272.1.7, 2010-11-19 22:27:35-05:00, stenn@deacon.udel.edu + Initial loopfilter overhaul from Dave Mills + + ChangeLog@1.655.1.7 +4 -0 + Initial loopfilter overhaul from Dave Mills + + html/keygen.html@1.23 +3 -1 + Initial loopfilter overhaul from Dave Mills + + html/miscopt.html@1.62 +16 -19 + Initial loopfilter overhaul from Dave Mills + + include/ntp.h@1.184.1.1 +4 -5 + Initial loopfilter overhaul from Dave Mills + + include/ntpd.h@1.143.1.1 +0 -3 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntp_config.c@1.271.1.1 +0 -8 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntp_loopfilter.c@1.162 +39 -53 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntp_proto.c@1.312 +5 -5 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntp_request.c@1.95.1.1 +0 -8 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntp_timer.c@1.62 +4 -6 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntp_util.c@1.87 +60 -73 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntpd.c@1.118 +1 -1 + Initial loopfilter overhaul from Dave Mills + + ntpd/ntpsim.c@1.29 +1 -1 + Initial loopfilter overhaul from Dave Mills + +ChangeSet@1.2082.4.158, 2010-11-18 05:09:05+00:00, davehart@shiny.ad.hartbrothers.com + convert Windows build to share single sntp/libopts + + ports/winnt/vc6/libntp.dsp@1.43.1.10 +3 -3 + convert Windows build to share single sntp/libopts + + ports/winnt/vc6/ntpd.dsp@1.39.1.4 +4 -4 + convert Windows build to share single sntp/libopts + + ports/winnt/vc6/ntpdc.dsp@1.28.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vc6/ntpkeygen.dsp@1.20.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vc6/ntpq.dsp@1.29.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2003/libntp.vcproj@1.4.1.4 +3 -3 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2003/ntpd.vcproj@1.4.1.2 +3 -3 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2003/ntpdc.vcproj@1.4.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2003/ntpkeygen.vcproj@1.3.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2003/ntpq.vcproj@1.4.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2005/libntp.vcproj@1.4.1.4 +3 -3 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2005/ntpd.vcproj@1.4.1.2 +3 -3 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2005/ntpdc.vcproj@1.4.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2005/ntpkeygen.vcproj@1.3.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2005/ntpq.vcproj@1.4.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20.1.6 +4 -4 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.9.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.21.1.3 +3 -3 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.12.1.1 +2 -2 + convert Windows build to share single sntp/libopts + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.11.1.1 +2 -2 + convert Windows build to share single sntp/libopts + +ChangeSet@1.2272.1.6, 2010-11-17 10:10:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P83 + TAG: NTP_4_2_7P83 + + ChangeLog@1.655.1.6 +1 -0 + NTP_4_2_7P83 + + ntpd/ntpd-opts.c@1.86 +2 -2 + NTP_4_2_7P83 + + ntpd/ntpd-opts.h@1.86 +3 -3 + NTP_4_2_7P83 + + ntpd/ntpd-opts.texi@1.85 +2 -2 + NTP_4_2_7P83 + + ntpd/ntpd.1@1.85 +2 -2 + NTP_4_2_7P83 + + ntpdc/ntpdc-opts.c@1.84 +2 -2 + NTP_4_2_7P83 + + ntpdc/ntpdc-opts.h@1.84 +3 -3 + NTP_4_2_7P83 + + ntpdc/ntpdc-opts.texi@1.84 +2 -2 + NTP_4_2_7P83 + + ntpdc/ntpdc.1@1.84 +2 -2 + NTP_4_2_7P83 + + ntpq/ntpq-opts.c@1.84 +2 -2 + NTP_4_2_7P83 + + ntpq/ntpq-opts.h@1.84 +3 -3 + NTP_4_2_7P83 + + ntpq/ntpq-opts.texi@1.84 +2 -2 + NTP_4_2_7P83 + + ntpq/ntpq.1@1.84 +2 -2 + NTP_4_2_7P83 + + ntpsnmpd/ntpsnmpd-opts.c@1.84 +2 -2 + NTP_4_2_7P83 + + ntpsnmpd/ntpsnmpd-opts.h@1.84 +3 -3 + NTP_4_2_7P83 + + ntpsnmpd/ntpsnmpd-opts.texi@1.84 +2 -2 + NTP_4_2_7P83 + + ntpsnmpd/ntpsnmpd.1@1.84 +2 -2 + NTP_4_2_7P83 + + packageinfo.sh@1.85 +1 -1 + NTP_4_2_7P83 + + sntp/sntp-opts.c@1.84 +2 -2 + NTP_4_2_7P83 + + sntp/sntp-opts.h@1.84 +3 -3 + NTP_4_2_7P83 + + sntp/sntp-opts.texi@1.84 +1 -1 + NTP_4_2_7P83 + + sntp/sntp.1@1.84 +2 -2 + NTP_4_2_7P83 + + sntp/sntp.html@1.84 +1 -1 + NTP_4_2_7P83 + + util/ntp-keygen-opts.c@1.81 +2 -2 + NTP_4_2_7P83 + + util/ntp-keygen-opts.h@1.81 +3 -3 + NTP_4_2_7P83 + + util/ntp-keygen-opts.texi@1.84 +2 -2 + NTP_4_2_7P83 + + util/ntp-keygen.1@1.84 +2 -2 + NTP_4_2_7P83 + +ChangeSet@1.2277, 2010-11-17 05:31:02+00:00, davehart@shiny.ad.hartbrothers.com + remove ChangeLog reference to 1727, integrated first from another branch. + + ChangeLog@1.658 +0 -1 + remove ChangeLog reference to 1727, integrated first from another branch. + +ChangeSet@1.2272.2.1, 2010-11-16 20:00:54-05:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.655.2.1 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.7 +2 -2 + Documentation updates from Dave Mills + + html/miscopt.html@1.61 +4 -4 + Documentation updates from Dave Mills + +ChangeSet@1.2272.1.4, 2010-11-16 20:36:48+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1727] ntp-keygen PLEN, ILEN undeclared --without-crypto. + + ChangeLog@1.655.1.4 +1 -0 + [Bug 1727] ntp-keygen PLEN, ILEN undeclared --without-crypto. + + util/ntp-keygen.c@1.66.1.1 +2 -2 + [Bug 1727] ntp-keygen PLEN, ILEN undeclared --without-crypto. + +ChangeSet@1.2272.1.3, 2010-11-16 19:52:26+00:00, davehart@shiny.ad.hartbrothers.com + get rid of duplicate libopts copy + + BitKeeper/deleted/04/README~5bc90a91ec6411e6@1.3 +0 -0 + Rename: libopts/README -> BitKeeper/deleted/04/README~5bc90a91ec6411e6 + + BitKeeper/deleted/04/value-type.h~8c9e9714f716dd59@1.6 +0 -0 + Rename: libopts/value-type.h -> BitKeeper/deleted/04/value-type.h~8c9e9714f716dd59 + + BitKeeper/deleted/07/usage.c~5148c9dc95efdc1a@1.5 +0 -0 + Rename: libopts/usage.c -> BitKeeper/deleted/07/usage.c~5148c9dc95efdc1a + + BitKeeper/deleted/0e/putshell.c~1e2cc4a1ffb8fafd@1.5 +0 -0 + Rename: libopts/putshell.c -> BitKeeper/deleted/0e/putshell.c~1e2cc4a1ffb8fafd + + BitKeeper/deleted/13/tokenize.c~c52b9718bf168782@1.3 +0 -0 + Rename: libopts/tokenize.c -> BitKeeper/deleted/13/tokenize.c~c52b9718bf168782 + + BitKeeper/deleted/16/load.c~1667134a8de0561c@1.5 +0 -0 + Rename: libopts/load.c -> BitKeeper/deleted/16/load.c~1667134a8de0561c + + BitKeeper/deleted/18/streqvcmp.c~59b1ce7223f3432@1.5 +0 -0 + Rename: libopts/streqvcmp.c -> BitKeeper/deleted/18/streqvcmp.c~59b1ce7223f3432 + + BitKeeper/deleted/1b/file.c~67e1b8b29a3953c9@1.5 +0 -0 + Rename: libopts/file.c -> BitKeeper/deleted/1b/file.c~67e1b8b29a3953c9 + + BitKeeper/deleted/20/cook.c~a6052eddf9363b9@1.5 +0 -0 + Rename: libopts/cook.c -> BitKeeper/deleted/20/cook.c~a6052eddf9363b9 + + BitKeeper/deleted/27/makeshell.c~20cbf9416110166e@1.5 +0 -0 + Rename: libopts/makeshell.c -> BitKeeper/deleted/27/makeshell.c~20cbf9416110166e + + BitKeeper/deleted/29/compat.h~7caca4e98e77c39@1.5 +0 -0 + Rename: libopts/compat/compat.h -> BitKeeper/deleted/29/compat.h~7caca4e98e77c39 + + BitKeeper/deleted/29/enumeration.c~95e4ac5ad1bbc51d@1.5 +0 -0 + Rename: libopts/enumeration.c -> BitKeeper/deleted/29/enumeration.c~95e4ac5ad1bbc51d + + BitKeeper/deleted/2a/genshell.c~3290a02566a5dbb7@1.6 +0 -0 + Rename: libopts/genshell.c -> BitKeeper/deleted/2a/genshell.c~3290a02566a5dbb7 + + BitKeeper/deleted/2b/sort.c~a0f0aca832b2554c@1.5 +0 -0 + Rename: libopts/sort.c -> BitKeeper/deleted/2b/sort.c~a0f0aca832b2554c + + BitKeeper/deleted/2c/pgusage.c~a31853764946ed10@1.5 +0 -0 + Rename: libopts/pgusage.c -> BitKeeper/deleted/2c/pgusage.c~a31853764946ed10 + + BitKeeper/deleted/36/version.c~c1c141f1786ce61c@1.5 +0 -0 + Rename: libopts/version.c -> BitKeeper/deleted/36/version.c~c1c141f1786ce61c + + BitKeeper/deleted/3b/text_mmap.c~b601dfb63675456e@1.5 +0 -0 + Rename: libopts/text_mmap.c -> BitKeeper/deleted/3b/text_mmap.c~b601dfb63675456e + + BitKeeper/deleted/46/strchr.c~e00f88c19bec996f@1.2 +0 -0 + Rename: libopts/compat/strchr.c -> BitKeeper/deleted/46/strchr.c~e00f88c19bec996f + + BitKeeper/deleted/48/MakeDefs.inc~c629403b9830e97a@1.2 +0 -0 + Rename: libopts/MakeDefs.inc -> BitKeeper/deleted/48/MakeDefs.inc~c629403b9830e97a + + BitKeeper/deleted/4b/value-type.c~eab6702e458dce8d@1.3 +0 -0 + Rename: libopts/value-type.c -> BitKeeper/deleted/4b/value-type.c~eab6702e458dce8d + + BitKeeper/deleted/4c/boolean.c~8e1af2515312893c@1.5 +0 -0 + Rename: libopts/boolean.c -> BitKeeper/deleted/4c/boolean.c~8e1af2515312893c + + BitKeeper/deleted/67/environment.c~3cd90226bb7b2b17@1.6 +0 -0 + Rename: libopts/environment.c -> BitKeeper/deleted/67/environment.c~3cd90226bb7b2b17 + + BitKeeper/deleted/6b/usage-txt.h~ca24f451aac51f1f@1.6 +0 -0 + Rename: libopts/autoopts/usage-txt.h -> BitKeeper/deleted/6b/usage-txt.h~ca24f451aac51f1f + + BitKeeper/deleted/6c/snprintf.c~4020216a304b1fdf@1.2 +0 -0 + Rename: libopts/compat/snprintf.c -> BitKeeper/deleted/6c/snprintf.c~4020216a304b1fdf + + BitKeeper/deleted/6c/windows-config.h~461ddbe1169c297b@1.5 +0 -0 + Rename: libopts/compat/windows-config.h -> BitKeeper/deleted/6c/windows-config.h~461ddbe1169c297b + + BitKeeper/deleted/7a/autoopts.c~54350751ea38f4a9@1.5 +0 -0 + Rename: libopts/autoopts.c -> BitKeeper/deleted/7a/autoopts.c~54350751ea38f4a9 + + BitKeeper/deleted/82/xat-attribute.h~7d19c77e5ff1a904@1.6 +0 -0 + Rename: libopts/xat-attribute.h -> BitKeeper/deleted/82/xat-attribute.h~7d19c77e5ff1a904 + + BitKeeper/deleted/8f/options.h~f2e0c23c8e5e59e8@1.6 +0 -0 + Rename: libopts/autoopts/options.h -> BitKeeper/deleted/8f/options.h~f2e0c23c8e5e59e8 + + BitKeeper/deleted/91/parse-duration.c~43baef4a99281837@1.2 +0 -0 + Rename: libopts/parse-duration.c -> BitKeeper/deleted/91/parse-duration.c~43baef4a99281837 + + BitKeeper/deleted/94/xat-attribute.c~8a808fcad835c47f@1.3 +0 -0 + Rename: libopts/xat-attribute.c -> BitKeeper/deleted/94/xat-attribute.c~8a808fcad835c47f + + BitKeeper/deleted/9b/genshell.h~c39a618c8d4061cd@1.6 +0 -0 + Rename: libopts/genshell.h -> BitKeeper/deleted/9b/genshell.h~c39a618c8d4061cd + + BitKeeper/deleted/9c/nested.c~f07a7d9124c8d2aa@1.5 +0 -0 + Rename: libopts/nested.c -> BitKeeper/deleted/9c/nested.c~f07a7d9124c8d2aa + + BitKeeper/deleted/a0/autoopts.h~56d3d4b1ff6e5a32@1.5 +0 -0 + Rename: libopts/autoopts.h -> BitKeeper/deleted/a0/autoopts.h~56d3d4b1ff6e5a32 + + BitKeeper/deleted/a0/reset.c~676b344e8e06553d@1.5 +0 -0 + Rename: libopts/reset.c -> BitKeeper/deleted/a0/reset.c~676b344e8e06553d + + BitKeeper/deleted/bb/configfile.c~edfc1b173dd4ca72@1.5 +0 -0 + Rename: libopts/configfile.c -> BitKeeper/deleted/bb/configfile.c~edfc1b173dd4ca72 + + BitKeeper/deleted/bc/COPYING.mbsd~a5472d893521969b@1.2 +0 -0 + Rename: libopts/COPYING.mbsd -> BitKeeper/deleted/bc/COPYING.mbsd~a5472d893521969b + + BitKeeper/deleted/c0/COPYING.lgplv3~40be4cbf4ae10117@1.2 +0 -0 + Rename: libopts/COPYING.lgplv3 -> BitKeeper/deleted/c0/COPYING.lgplv3~40be4cbf4ae10117 + + BitKeeper/deleted/c4/strdup.c~d58e7b55af5b3f83@1.2 +0 -0 + Rename: libopts/compat/strdup.c -> BitKeeper/deleted/c4/strdup.c~d58e7b55af5b3f83 + + BitKeeper/deleted/c6/stack.c~159a2b84f1ceafab@1.5 +0 -0 + Rename: libopts/stack.c -> BitKeeper/deleted/c6/stack.c~159a2b84f1ceafab + + BitKeeper/deleted/cd/libopts.c~3ef92daf425d2b@1.2 +0 -0 + Rename: libopts/libopts.c -> BitKeeper/deleted/cd/libopts.c~3ef92daf425d2b + + BitKeeper/deleted/ce/numeric.c~2cd8f01381095e42@1.5 +0 -0 + Rename: libopts/numeric.c -> BitKeeper/deleted/ce/numeric.c~2cd8f01381095e42 + + BitKeeper/deleted/d4/pathfind.c~91eee34e6931c147@1.5 +0 -0 + Rename: libopts/compat/pathfind.c -> BitKeeper/deleted/d4/pathfind.c~91eee34e6931c147 + + BitKeeper/deleted/d7/time.c~41f39a05ffd762ac@1.5 +0 -0 + Rename: libopts/time.c -> BitKeeper/deleted/d7/time.c~41f39a05ffd762ac + + BitKeeper/deleted/da/liboptschk.m4~1413f38bcfcfd143@1.5 +0 -0 + Rename: libopts/m4/liboptschk.m4 -> BitKeeper/deleted/da/liboptschk.m4~1413f38bcfcfd143 + + BitKeeper/deleted/e1/Makefile.am~b7467cbc80acbbcc@1.3 +0 -0 + Rename: libopts/Makefile.am -> BitKeeper/deleted/e1/Makefile.am~b7467cbc80acbbcc + + BitKeeper/deleted/e5/ag-char-map.h~bedbb0c05ab02a70@1.6 +0 -0 + Rename: libopts/ag-char-map.h -> BitKeeper/deleted/e5/ag-char-map.h~bedbb0c05ab02a70 + + BitKeeper/deleted/e8/libopts.m4~93a05c922cf88420@1.6 +0 -0 + Rename: libopts/m4/libopts.m4 -> BitKeeper/deleted/e8/libopts.m4~93a05c922cf88420 + + BitKeeper/deleted/f4/proto.h~f433f2d660b72a7d@1.6 +0 -0 + Rename: libopts/proto.h -> BitKeeper/deleted/f4/proto.h~f433f2d660b72a7d + + BitKeeper/deleted/f6/COPYING.gplv3~f03d8366c675c284@1.2 +0 -0 + Rename: libopts/COPYING.gplv3 -> BitKeeper/deleted/f6/COPYING.gplv3~f03d8366c675c284 + + BitKeeper/deleted/f7/parse-duration.h~17a3a3e1c22145d@1.2 +0 -0 + Rename: libopts/parse-duration.h -> BitKeeper/deleted/f7/parse-duration.h~17a3a3e1c22145d + + BitKeeper/deleted/f8/restore.c~7503fbe1eb367c27@1.5 +0 -0 + Rename: libopts/restore.c -> BitKeeper/deleted/f8/restore.c~7503fbe1eb367c27 + + BitKeeper/deleted/fc/save.c~c7023eeab566cc5a@1.6 +0 -0 + Rename: libopts/save.c -> BitKeeper/deleted/fc/save.c~c7023eeab566cc5a + + ChangeLog@1.655.1.3 +1 -0 + Remove top-level libopts, use sntp/libopts. + + Makefile.am@1.99 +8 -12 + Remove top-level libopts, use sntp/libopts. + + configure.ac@1.496 +1 -1 + Remove top-level libopts, use sntp/libopts. + + deps-ver@1.2 +1 -1 + bump deps-ver to trigger clean build with removal of top-level + copy of libopts + + ports/winnt/vc6/libntp.dsp@1.54 +3 -3 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vc6/ntpd.dsp@1.50 +3 -3 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vc6/ntpdc.dsp@1.29 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vc6/ntpkeygen.dsp@1.21 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vc6/ntpq.dsp@1.30 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2003/libntp.vcproj@1.12 +3 -3 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2003/ntpd.vcproj@1.11 +3 -3 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2003/ntpdc.vcproj@1.5 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2003/ntpkeygen.vcproj@1.4 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2003/ntpq.vcproj@1.5 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2005/libntp.vcproj@1.10 +3 -3 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2005/ntpd.vcproj@1.11 +3 -3 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2005/ntpdc.vcproj@1.5 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2005/ntpkeygen.vcproj@1.4 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2005/ntpq.vcproj@1.5 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.31 +4 -4 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.11 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.33 +3 -3 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.14 +2 -2 + Remove top-level libopts, use sntp/libopts. + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.13 +2 -2 + Remove top-level libopts, use sntp/libopts. + +ChangeSet@1.2272.1.2, 2010-11-16 10:10:15+00:00, stenn@deacon.udel.edu + NTP_4_2_7P82 + TAG: NTP_4_2_7P82 + + ChangeLog@1.655.1.2 +1 -0 + NTP_4_2_7P82 + + ntpd/ntpd-opts.c@1.85 +2 -2 + NTP_4_2_7P82 + + ntpd/ntpd-opts.h@1.85 +3 -3 + NTP_4_2_7P82 + + ntpd/ntpd-opts.texi@1.84 +2 -2 + NTP_4_2_7P82 + + ntpd/ntpd.1@1.84 +2 -2 + NTP_4_2_7P82 + + ntpdc/ntpdc-opts.c@1.83 +2 -2 + NTP_4_2_7P82 + + ntpdc/ntpdc-opts.h@1.83 +3 -3 + NTP_4_2_7P82 + + ntpdc/ntpdc-opts.texi@1.83 +2 -2 + NTP_4_2_7P82 + + ntpdc/ntpdc.1@1.83 +2 -2 + NTP_4_2_7P82 + + ntpq/ntpq-opts.c@1.83 +2 -2 + NTP_4_2_7P82 + + ntpq/ntpq-opts.h@1.83 +3 -3 + NTP_4_2_7P82 + + ntpq/ntpq-opts.texi@1.83 +2 -2 + NTP_4_2_7P82 + + ntpq/ntpq.1@1.83 +2 -2 + NTP_4_2_7P82 + + ntpsnmpd/ntpsnmpd-opts.c@1.83 +2 -2 + NTP_4_2_7P82 + + ntpsnmpd/ntpsnmpd-opts.h@1.83 +3 -3 + NTP_4_2_7P82 + + ntpsnmpd/ntpsnmpd-opts.texi@1.83 +2 -2 + NTP_4_2_7P82 + + ntpsnmpd/ntpsnmpd.1@1.83 +2 -2 + NTP_4_2_7P82 + + packageinfo.sh@1.84 +1 -1 + NTP_4_2_7P82 + + sntp/sntp-opts.c@1.83 +2 -2 + NTP_4_2_7P82 + + sntp/sntp-opts.h@1.83 +3 -3 + NTP_4_2_7P82 + + sntp/sntp-opts.texi@1.83 +1 -1 + NTP_4_2_7P82 + + sntp/sntp.1@1.83 +2 -2 + NTP_4_2_7P82 + + sntp/sntp.html@1.83 +1 -1 + NTP_4_2_7P82 + + util/ntp-keygen-opts.c@1.80 +2 -2 + NTP_4_2_7P82 + + util/ntp-keygen-opts.h@1.80 +3 -3 + NTP_4_2_7P82 + + util/ntp-keygen-opts.texi@1.83 +2 -2 + NTP_4_2_7P82 + + util/ntp-keygen.1@1.83 +2 -2 + NTP_4_2_7P82 + +ChangeSet@1.2082.38.1, 2010-11-15 23:53:16-05:00, stenn@deacon.udel.edu + [Bug 1728] In ntp_openssl.m4, don't add -I/usr/include or -L/usr/lib to CPPFLAGS or LDFLAGS + + ChangeLog@1.496.58.1 +5 -0 + [Bug 1728] In ntp_openssl.m4, don't add -I/usr/include or -L/usr/lib to CPPFLAGS or LDFLAGS + + m4/ntp_openssl.m4@1.2 +12 -4 + [Bug 1728] In ntp_openssl.m4, don't add -I/usr/include or -L/usr/lib to CPPFLAGS or LDFLAGS + +ChangeSet@1.2082.4.156, 2010-11-16 00:53:57+00:00, davehart@shiny.ad.hartbrothers.com + correct tests for link-local (fe80) and site-local (fec0) unicast + IPv6 addresses in selecting default multicast source addresses. + + ntpd/ntp_io.c@1.306.1.11 +19 -18 + correct tests for link-local (fe80) and site-local (fec0) unicast + IPv6 addresses in selecting default multicast source addresses. + +ChangeSet@1.2275, 2010-11-16 00:07:47+00:00, davehart@shiny.ad.hartbrothers.com + merge repair + + BitKeeper/deleted/3e/log-expected-log~2cb22a7a98bc5f12@1.3 +0 -0 + Rename: sntp/tests/data/log-expected-log -> BitKeeper/deleted/3e/log-expected-log~2cb22a7a98bc5f12 + + BitKeeper/deleted/70/log-expected-debug~2e237608238fd4f0@1.3 +0 -0 + Rename: sntp/tests/data/log-expected-debug -> BitKeeper/deleted/70/log-expected-debug~2e237608238fd4f0 + + BitKeeper/deleted/cc/logFile.cpp~7fc28eb9a26c17c2@1.7 +0 -0 + Rename: sntp/tests/logFile.cpp -> BitKeeper/deleted/cc/logFile.cpp~7fc28eb9a26c17c2 + + include/ntpd.h@1.145 +1 -1 + merge repair + + libntp/ntp_calendar.c@1.3 +10 -10 + silence warnings about truncation + + ntpd/ntp_control.c@1.141 +2 -2 + merge repair + + ntpd/ntp_filegen.c@1.22 +1 -2 + silence warnings + + ntpd/ntp_io.c@1.329 +5 -6 + merge repair + + ntpd/ntp_peer.c@1.137 +8 -10 + merge repair + + sntp/tests/Makefile.am@1.17 +1 -4 + remove sntp logging unit tests, as sntp uses only msyslog now. + +ChangeSet@1.2082.4.155, 2010-11-15 22:39:31+00:00, davehart@shiny.ad.hartbrothers.com + Remove log_msg() and debug_msg() from sntp in favor of msyslog(). + + ChangeLog@1.496.26.114 +1 -0 + Remove log_msg() and debug_msg() from sntp in favor of msyslog(). + + sntp/log.c@1.11.1.4 +0 -19 + Remove log_msg() and debug_msg() from sntp in favor of msyslog(). + + sntp/log.h@1.10 +0 -3 + Remove log_msg() and debug_msg() from sntp in favor of msyslog(). + + sntp/main.c@1.24.1.7 +6 -11 + Remove log_msg() and debug_msg() from sntp in favor of msyslog(). + +ChangeSet@1.2273, 2010-11-15 22:30:55+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1727] ntp-keygen PLEN, ILEN undeclared --without-crypto. + + ChangeLog@1.656 +1 -0 + [Bug 1727] ntp-keygen PLEN, ILEN undeclared --without-crypto. + + util/ntp-keygen.c@1.67 +2 -2 + [Bug 1727] ntp-keygen PLEN, ILEN undeclared --without-crypto. + +ChangeSet@1.2082.4.154, 2010-11-15 20:09:00+00:00, davehart@shiny.ad.hartbrothers.com + Do not send multicast from both link-local and global addresses on + the same underlying network interface. + + ntpd/ntp_io.c@1.306.1.10 +74 -32 + Do not send multicast from both link-local and global addresses on + the same underlying network interface. + +ChangeSet@1.2082.4.153, 2010-11-15 18:24:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1725] ntpd sends multicast from only one address. + + ChangeLog@1.496.26.113 +4 -0 + [Bug 1725] ntpd sends multicast from only one address. + + include/ntp.h@1.168.1.3 +29 -23 + [Bug 1725] ntpd sends multicast from only one address. + begin changing internal references from "struct interface" to "endpt" + + include/ntpd.h@1.137.2.2 +9 -9 + [Bug 1725] ntpd sends multicast from only one address. + begin changing internal references from "struct interface" to "endpt" + + ntpd/ntp_config.c@1.241.1.7 +2 -3 + use ZERO_SOCK() in two places + + ntpd/ntp_io.c@1.306.1.9 +320 -283 + [Bug 1725] ntpd sends multicast from only one address. + begin changing internal references from "struct interface" to "endpt" + + ntpd/ntp_peer.c@1.126.1.1 +62 -69 + refactor select_peerinterface() to reduce duplication, indents + reduce #ifdef WINNT clutter + + ntpd/ntp_request.c@1.82.1.3 +21 -21 + [Bug 1725] ntpd sends multicast from only one address. + begin changing internal references from "struct interface" to "endpt" + + ports/winnt/include/ntp_iocompletionport.h@1.18 +1 -2 + reduce sendpkt() ifdefs around sendto() + + ports/winnt/ntpd/ntp_iocompletionport.c@1.49.1.1 +34 -32 + reduce sendpkt() ifdefs around sendto() + + ports/winnt/ntpd/ntservice.c@1.22.1.1 +3 -3 + reduce #ifdef WINNT clutter + +ChangeSet@1.2272, 2010-11-14 23:36:16+00:00, stenn@deacon.udel.edu + NTP_4_2_7P81 + TAG: NTP_4_2_7P81 + + ChangeLog@1.655 +1 -0 + NTP_4_2_7P81 + + ntpd/ntpd-opts.c@1.84 +2 -2 + NTP_4_2_7P81 + + ntpd/ntpd-opts.h@1.84 +3 -3 + NTP_4_2_7P81 + + ntpd/ntpd-opts.texi@1.83 +2 -2 + NTP_4_2_7P81 + + ntpd/ntpd.1@1.83 +2 -2 + NTP_4_2_7P81 + + ntpdc/ntpdc-opts.c@1.82 +2 -2 + NTP_4_2_7P81 + + ntpdc/ntpdc-opts.h@1.82 +3 -3 + NTP_4_2_7P81 + + ntpdc/ntpdc-opts.texi@1.82 +2 -2 + NTP_4_2_7P81 + + ntpdc/ntpdc.1@1.82 +2 -2 + NTP_4_2_7P81 + + ntpq/ntpq-opts.c@1.82 +2 -2 + NTP_4_2_7P81 + + ntpq/ntpq-opts.h@1.82 +3 -3 + NTP_4_2_7P81 + + ntpq/ntpq-opts.texi@1.82 +2 -2 + NTP_4_2_7P81 + + ntpq/ntpq.1@1.82 +2 -2 + NTP_4_2_7P81 + + ntpsnmpd/ntpsnmpd-opts.c@1.82 +2 -2 + NTP_4_2_7P81 + + ntpsnmpd/ntpsnmpd-opts.h@1.82 +3 -3 + NTP_4_2_7P81 + + ntpsnmpd/ntpsnmpd-opts.texi@1.82 +2 -2 + NTP_4_2_7P81 + + ntpsnmpd/ntpsnmpd.1@1.82 +2 -2 + NTP_4_2_7P81 + + packageinfo.sh@1.83 +1 -1 + NTP_4_2_7P81 + + sntp/sntp-opts.c@1.82 +3 -3 + NTP_4_2_7P81 + + sntp/sntp-opts.h@1.82 +3 -3 + NTP_4_2_7P81 + + sntp/sntp-opts.texi@1.82 +2 -2 + NTP_4_2_7P81 + + sntp/sntp.1@1.82 +3 -5 + NTP_4_2_7P81 + + sntp/sntp.html@1.82 +1 -1 + NTP_4_2_7P81 + + util/ntp-keygen-opts.c@1.79 +2 -2 + NTP_4_2_7P81 + + util/ntp-keygen-opts.h@1.79 +3 -3 + NTP_4_2_7P81 + + util/ntp-keygen-opts.texi@1.82 +2 -2 + NTP_4_2_7P81 + + util/ntp-keygen.1@1.82 +2 -2 + NTP_4_2_7P81 + +ChangeSet@1.2271, 2010-11-14 18:13:53-05:00, stenn@deacon.udel.edu + [Bug 1719] Cleanup for ntp-keygen and fix -V crash, from Dave Mills + + ChangeLog@1.654 +1 -0 + [Bug 1719] Cleanup for ntp-keygen and fix -V crash, from Dave Mills + + html/autokey.html@1.6 +11 -11 + [Bug 1719] Cleanup for ntp-keygen and fix -V crash, from Dave Mills + + util/ntp-keygen.c@1.66 +16 -21 + [Bug 1719] Cleanup for ntp-keygen and fix -V crash, from Dave Mills + +ChangeSet@1.2082.4.152, 2010-11-14 08:56:20+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC10 + TAG: NTP_4_2_6P3_RC10 + + ChangeLog@1.496.26.112 +1 -0 + NTP_4_2_6P3_RC10 + + ntpd/ntpd-opts.c@1.248.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpd/ntpd-opts.h@1.248.26.1 +3 -3 + NTP_4_2_6P3_RC10 + + ntpd/ntpd-opts.texi@1.246.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpd/ntpd.1@1.246.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpdc/ntpdc-opts.c@1.244.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpdc/ntpdc-opts.h@1.244.26.1 +3 -3 + NTP_4_2_6P3_RC10 + + ntpdc/ntpdc-opts.texi@1.243.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpdc/ntpdc.1@1.243.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpq/ntpq-opts.c@1.245.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpq/ntpq-opts.h@1.245.26.1 +3 -3 + NTP_4_2_6P3_RC10 + + ntpq/ntpq-opts.texi@1.244.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpq/ntpq.1@1.244.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.27.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.27.1 +3 -3 + NTP_4_2_6P3_RC10 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.27.1 +2 -2 + NTP_4_2_6P3_RC10 + + ntpsnmpd/ntpsnmpd.1@1.122.27.1 +2 -2 + NTP_4_2_6P3_RC10 + + packageinfo.sh@1.255.28.1 +1 -1 + NTP_4_2_6P3_RC10 + + sntp/sntp-opts.c@1.117.26.1 +3 -3 + NTP_4_2_6P3_RC10 + + sntp/sntp-opts.h@1.117.26.1 +3 -3 + NTP_4_2_6P3_RC10 + + sntp/sntp-opts.texi@1.117.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + sntp/sntp.1@1.117.26.1 +3 -5 + NTP_4_2_6P3_RC10 + + sntp/sntp.html@1.7.26.1 +1 -1 + NTP_4_2_6P3_RC10 + + util/ntp-keygen-opts.c@1.247.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + util/ntp-keygen-opts.h@1.247.26.1 +3 -3 + NTP_4_2_6P3_RC10 + + util/ntp-keygen-opts.texi@1.246.26.1 +2 -2 + NTP_4_2_6P3_RC10 + + util/ntp-keygen.1@1.246.26.1 +2 -2 + NTP_4_2_6P3_RC10 + +ChangeSet@1.2082.4.151, 2010-11-14 03:23:12-05:00, stenn@deacon.udel.edu + Update NEWS file for changes thru RC10 + + NEWS@1.112 +24 -15 + Update NEWS file for changes thru RC10 + +ChangeSet@1.2269, 2010-11-14 07:38:20+00:00, davehart@shiny.ad.hartbrothers.com + temporarily disable sntp unit tests that need rework after changes to use msyslog + + sntp/tests/logFile.cpp@1.6 +2 -0 + temporarily disable sntp unit tests that need rework after changes to use msyslog + + sntp/tests/sntptest.cpp@1.3 +0 -1 + we need the progname to match sntp to ease comparing output + +ChangeSet@1.2082.4.150, 2010-11-14 07:00:29+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1681] More sntp logging cleanup. + + ChangeLog@1.496.26.111 +1 -0 + [Bug 1681] More sntp logging cleanup. + + include/ntp_syslog.h@1.3.1.1 +3 -1 + expose msyslog_term flag to duplicate msyslog() output to stdout/stderr + + libntp/msyslog.c@1.24.1.1 +52 -38 + expose msyslog_term flag to duplicate msyslog() output to stdout/stderr + + sntp/crypto.c@1.10.1.5 +2 -24 + [Bug 1681] More sntp logging cleanup. + + sntp/kod_management.c@1.16.1.3 +11 -35 + [Bug 1681] More sntp logging cleanup. + + sntp/log.c@1.11.1.3 +39 -44 + [Bug 1681] More sntp logging cleanup. + + sntp/log.h@1.9 +15 -6 + [Bug 1681] More sntp logging cleanup. + + sntp/main.c@1.24.1.6 +34 -39 + [Bug 1681] More sntp logging cleanup. + + sntp/main.h@1.2 +0 -1 + move config.h include to main.c for consistency and because it has no + multiple-inclusion guard. + + sntp/networking.c@1.29.1.10 +14 -14 + [Bug 1681] More sntp logging cleanup. + + sntp/sntp-opts.def@1.16 +2 -4 + update RFC status + + sntp/sntp.c@1.2 +2 -1 + #include first + +ChangeSet@1.2267, 2010-11-11 20:37:23+00:00, davehart@shiny.ad.hartbrothers.com + fix merge typo + + ntpd/ntp_config.c@1.271 +2 -19 + merge cleanup -- -dev only uses of is_ip_address() + + ntpd/ntp_io.c@1.327 +1 -1 + fix merge typo + +ChangeSet@1.2082.4.149, 2010-11-11 19:20:40+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1683] Non-localhost on loopback exempted from nic rules. + + ChangeLog@1.496.26.110 +4 -0 + [Bug 1683] Non-localhost on loopback exempted from nic rules. + + include/ntp.h@1.168.1.2 +1 -1 + nail down size of struct interface.flags to 32 bits. + + include/ntp_io.h@1.13.1.1 +1 -1 + [Bug 1683] Non-localhost on loopback exempted from nic rules. + + ntpd/ntp_config.c@1.241.1.6 +13 -11 + [Bug 1683] Non-localhost on loopback exempted from nic rules. + + ntpd/ntp_io.c@1.306.1.8 +72 -58 + [Bug 1683] Non-localhost on loopback exempted from nic rules. + + ntpd/ntpd.c@1.110.2.1 +3 -3 + [Bug 1683] Non-localhost on loopback exempted from nic rules. + +ChangeSet@1.2254.1.2, 2010-11-10 19:29:43+01:00, jnperlin@hydra.localnet + fixed doc error, improved comments + + html/drivers/driver20.html@1.22 +1 -1 + fixed wrong mode bit nuber + + ntpd/refclock_nmea.c@1.56 +7 -4 + changed / moved comments for better strategic grouping + +ChangeSet@1.2265, 2010-11-10 05:44:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P80 + TAG: NTP_4_2_7P80 + + ChangeLog@1.650 +1 -0 + NTP_4_2_7P80 + + ntpd/ntpd-opts.c@1.83 +2 -2 + NTP_4_2_7P80 + + ntpd/ntpd-opts.h@1.83 +3 -3 + NTP_4_2_7P80 + + ntpd/ntpd-opts.texi@1.82 +2 -2 + NTP_4_2_7P80 + + ntpd/ntpd.1@1.82 +2 -2 + NTP_4_2_7P80 + + ntpdc/ntpdc-opts.c@1.81 +2 -2 + NTP_4_2_7P80 + + ntpdc/ntpdc-opts.h@1.81 +3 -3 + NTP_4_2_7P80 + + ntpdc/ntpdc-opts.texi@1.81 +2 -2 + NTP_4_2_7P80 + + ntpdc/ntpdc.1@1.81 +2 -2 + NTP_4_2_7P80 + + ntpq/ntpq-opts.c@1.81 +2 -2 + NTP_4_2_7P80 + + ntpq/ntpq-opts.h@1.81 +3 -3 + NTP_4_2_7P80 + + ntpq/ntpq-opts.texi@1.81 +2 -2 + NTP_4_2_7P80 + + ntpq/ntpq.1@1.81 +2 -2 + NTP_4_2_7P80 + + ntpsnmpd/ntpsnmpd-opts.c@1.81 +2 -2 + NTP_4_2_7P80 + + ntpsnmpd/ntpsnmpd-opts.h@1.81 +3 -3 + NTP_4_2_7P80 + + ntpsnmpd/ntpsnmpd-opts.texi@1.81 +2 -2 + NTP_4_2_7P80 + + ntpsnmpd/ntpsnmpd.1@1.81 +2 -2 + NTP_4_2_7P80 + + packageinfo.sh@1.82 +1 -1 + NTP_4_2_7P80 + + sntp/sntp-opts.c@1.81 +2 -2 + NTP_4_2_7P80 + + sntp/sntp-opts.h@1.81 +3 -3 + NTP_4_2_7P80 + + sntp/sntp-opts.texi@1.81 +1 -1 + NTP_4_2_7P80 + + sntp/sntp.1@1.81 +2 -2 + NTP_4_2_7P80 + + sntp/sntp.html@1.81 +1 -1 + NTP_4_2_7P80 + + util/ntp-keygen-opts.c@1.78 +2 -2 + NTP_4_2_7P80 + + util/ntp-keygen-opts.h@1.78 +3 -3 + NTP_4_2_7P80 + + util/ntp-keygen-opts.texi@1.81 +2 -2 + NTP_4_2_7P80 + + util/ntp-keygen.1@1.81 +2 -2 + NTP_4_2_7P80 + +ChangeSet@1.2082.4.148, 2010-11-10 03:48:21+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC9 + TAG: NTP_4_2_6P3_RC9 + + ChangeLog@1.496.26.109 +1 -0 + NTP_4_2_6P3_RC9 + + ntpd/ntpd-opts.c@1.248.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpd/ntpd-opts.h@1.248.25.1 +3 -3 + NTP_4_2_6P3_RC9 + + ntpd/ntpd-opts.texi@1.246.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpd/ntpd.1@1.246.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpdc/ntpdc-opts.c@1.244.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpdc/ntpdc-opts.h@1.244.25.1 +3 -3 + NTP_4_2_6P3_RC9 + + ntpdc/ntpdc-opts.texi@1.243.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpdc/ntpdc.1@1.243.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpq/ntpq-opts.c@1.245.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpq/ntpq-opts.h@1.245.25.1 +3 -3 + NTP_4_2_6P3_RC9 + + ntpq/ntpq-opts.texi@1.244.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpq/ntpq.1@1.244.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.26.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.26.1 +3 -3 + NTP_4_2_6P3_RC9 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.26.1 +2 -2 + NTP_4_2_6P3_RC9 + + ntpsnmpd/ntpsnmpd.1@1.122.26.1 +2 -2 + NTP_4_2_6P3_RC9 + + packageinfo.sh@1.255.27.1 +1 -1 + NTP_4_2_6P3_RC9 + + sntp/sntp-opts.c@1.117.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + sntp/sntp-opts.h@1.117.25.1 +3 -3 + NTP_4_2_6P3_RC9 + + sntp/sntp-opts.texi@1.117.25.1 +1 -1 + NTP_4_2_6P3_RC9 + + sntp/sntp.1@1.117.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + sntp/sntp.html@1.7.25.1 +1 -1 + NTP_4_2_6P3_RC9 + + util/ntp-keygen-opts.c@1.247.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + util/ntp-keygen-opts.h@1.247.25.1 +3 -3 + NTP_4_2_6P3_RC9 + + util/ntp-keygen-opts.texi@1.246.25.1 +2 -2 + NTP_4_2_6P3_RC9 + + util/ntp-keygen.1@1.246.25.1 +2 -2 + NTP_4_2_6P3_RC9 + +ChangeSet@1.2082.4.147, 2010-11-09 22:07:27-05:00, stenn@deacon.udel.edu + Backport sntp from -dev + + ChangeLog@1.496.26.108 +1 -0 + Backport sntp from -dev + +ChangeSet@1.2262, 2010-11-10 02:52:31+00:00, davehart@shiny.ad.hartbrothers.com + pave the way for pulling -stable backport which has these as new files + + BitKeeper/deleted/.del-main.h~17d37ce1cf2a5389@1.4 +0 -0 + Delete: sntp/main.h + + BitKeeper/deleted/.del-ntp_lib_m.m4~bbfbbd5c5add8c5@1.4 +0 -0 + Delete: m4/ntp_lib_m.m4 + + BitKeeper/deleted/.del-sntp.c~ef953de048542b83@1.3 +0 -0 + Delete: sntp/sntp.c + +ChangeSet@1.2082.4.146, 2010-11-10 02:29:39+00:00, davehart@shiny.ad.hartbrothers.com + Backport sntp changes from -dev + + m4/ntp_lib_m.m4@1.1 +16 -0 + Backport sntp changes from -dev + + m4/ntp_lib_m.m4@1.0 +0 -0 + + sntp/Makefile.am@1.21.1.9 +3 -1 + Backport sntp changes from -dev + + sntp/configure.ac@1.31.1.3 +1 -0 + Backport sntp changes from -dev + + sntp/crypto.c@1.10.1.4 +1 -0 + Backport sntp changes from -dev + + sntp/header.h@1.4.1.1 +1 -1 + Backport sntp changes from -dev + + sntp/kod_management.c@1.16.1.2 +2 -1 + Backport sntp changes from -dev + + sntp/log.c@1.11.1.2 +3 -2 + Backport sntp changes from -dev + + sntp/main.c@1.24.1.5 +191 -166 + Backport sntp changes from -dev + + sntp/main.h@1.1 +29 -0 + Backport sntp changes from -dev + + sntp/main.h@1.0 +0 -0 + + sntp/networking.c@1.29.1.9 +22 -20 + Backport sntp changes from -dev + + sntp/networking.h@1.18.2.1 +13 -3 + Backport sntp changes from -dev + + sntp/sntp.c@1.1 +13 -0 + Backport sntp changes from -dev + + sntp/sntp.c@1.0 +0 -0 + + sntp/utilities.c@1.10.1.2 +14 -14 + Backport sntp changes from -dev + +ChangeSet@1.2261, 2010-11-09 23:32:32+00:00, stenn@psp-fb1.ntp.org + ChangeLog: + [Bug 1708] "make check" fails with googletest 1.4.0 + [Bug 1718] Improve gtest checks in configure.ac + + ChangeLog@1.648 +2 -0 + [Bug 1708] "make check" fails with googletest 1.4.0 + [Bug 1718] Improve gtest checks in configure.ac + l + + configure.ac@1.495 +38 -12 + + sntp/configure.ac@1.42 +39 -12 + +ChangeSet@1.2082.37.1, 2010-11-09 16:50:10-05:00, stenn@deacon.udel.edu + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + + ChangeLog@1.496.57.1 +4 -0 + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + + scripts/checkChangeLog@1.1.2.1 +1 -1 + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + + scripts/genCommitLog@1.5.1.1 +1 -1 + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + +ChangeSet@1.2259, 2010-11-09 20:08:29+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1715] sntp utilitiesTest.IPv6Address failed. + + ChangeLog@1.646 +1 -0 + [Bug 1715] sntp utilitiesTest.IPv6Address failed. + + sntp/tests/utilities.cpp@1.5 +11 -17 + Nonfunctional (whitespace, use SIZEOF_SOCKADDR(), declare locals first). + + sntp/utilities.c@1.13 +13 -14 + [Bug 1715] sntp utilitiesTest.IPv6Address failed. + +ChangeSet@1.2252.1.1, 2010-11-09 19:38:19+01:00, jnperlin@hydra.localnet + reformed NMEA driver implementation and doc + + html/drivers/driver20.html@1.21 +341 -99 + updated / extended doc + + ntpd/refclock_nmea.c@1.55 +712 -537 + restructured ('reformed') driver + +ChangeSet@1.2082.4.144, 2010-11-09 06:01:12+00:00, davehart@shiny.ad.hartbrothers.com + Correct missing leading zeros in sntp tv_usec display from tv_to_str(). + + sntp/utilities.c@1.10.1.1 +1 -1 + Correct missing leading zeros in sntp tv_usec display from tv_to_str(). + +ChangeSet@1.2082.4.143, 2010-11-09 05:52:27+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1681] sntp logging cleanup. + + ChangeLog@1.496.26.106 +1 -0 + [Bug 1681] sntp logging cleanup. + + sntp/kod_management.c@1.16.1.1 +4 -4 + [Bug 1681] sntp logging cleanup. + + sntp/log.c@1.11.1.1 +3 -18 + [Bug 1681] sntp logging cleanup. + + sntp/log.h@1.8 +1 -1 + [Bug 1681] sntp logging cleanup. + + sntp/main.c@1.24.1.4 +4 -4 + [Bug 1681] sntp logging cleanup. + + sntp/networking.c@1.29.1.8 +1 -1 + [Bug 1681] sntp logging cleanup. + +ChangeSet@1.2257, 2010-11-09 05:14:53+00:00, davehart@shiny.ad.hartbrothers.com + merge from -stable cleanup + + ntpd/ntp_io.c@1.325 +1 -2 + repair merge from -stable -- getinterface() is no longer static in -dev + + sntp/main.c@1.35 +0 -9 + merge from -stable repair -- sntp's main() has moved to sntp.c in -dev + +ChangeSet@1.2082.4.140, 2010-11-09 04:40:06+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1691] Use first NMEA sentence each second. + -- applies to prior cset + + ChangeLog@1.496.56.1 +4 -0 + [Bug 1691] Use first NMEA sentence each second. + +ChangeSet@1.2082.36.1, 2010-11-09 04:26:03+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1709] ntpdate ignores replies with equal receive and transmit timestamps. + + ChangeLog@1.496.55.1 +5 -0 + [Bug 1709] ntpdate ignores replies with equal receive and transmit timestamps. + + ntpdate/ntpdate.c@1.69.2.1 +1 -2 + [Bug 1709] ntpdate ignores replies with equal receive and transmit timestamps. + +ChangeSet@1.2082.35.1, 2010-11-09 03:52:20+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1574] sntp:set_time doesn't set tv_usec correctly. + + ChangeLog@1.496.54.1 +4 -0 + [Bug 1574] sntp:set_time doesn't set tv_usec correctly. + + sntp/main.c@1.24.1.3 +23 -8 + [Bug 1574] sntp:set_time doesn't set tv_usec correctly. + +ChangeSet@1.2082.34.1, 2010-11-09 03:14:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1683] Interface binding does not seem to work as intended. + + ChangeLog@1.496.26.102 +4 -0 + [Bug 1683] Interface binding does not seem to work as intended. + + include/ntp_machine.h@1.26.2.1 +3 -0 + add socket_errno() to reduce #ifdef clutter + + ntpd/ntp_io.c@1.306.1.7 +175 -125 + [Bug 1683] Interface binding does not seem to work as intended. + +ChangeSet@1.2082.33.1, 2010-11-08 18:26:21+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1709] ntpdate ignores replies with equal receive and transmit timestamps. + + ntpdate/ntpdate.c@1.69.1.2 +1 -2 + [Bug 1709] ntpdate ignores replies with equal receive and transmit timestamps. + +ChangeSet@1.2254, 2010-11-07 02:15:51+00:00, stenn@deacon.udel.edu + NTP_4_2_7P79 + TAG: NTP_4_2_7P79 + + ChangeLog@1.643 +1 -0 + NTP_4_2_7P79 + + ntpd/ntpd-opts.c@1.82 +2 -2 + NTP_4_2_7P79 + + ntpd/ntpd-opts.h@1.82 +3 -3 + NTP_4_2_7P79 + + ntpd/ntpd-opts.texi@1.81 +2 -2 + NTP_4_2_7P79 + + ntpd/ntpd.1@1.81 +2 -2 + NTP_4_2_7P79 + + ntpdc/ntpdc-opts.c@1.80 +2 -2 + NTP_4_2_7P79 + + ntpdc/ntpdc-opts.h@1.80 +3 -3 + NTP_4_2_7P79 + + ntpdc/ntpdc-opts.texi@1.80 +2 -2 + NTP_4_2_7P79 + + ntpdc/ntpdc.1@1.80 +2 -2 + NTP_4_2_7P79 + + ntpq/ntpq-opts.c@1.80 +2 -2 + NTP_4_2_7P79 + + ntpq/ntpq-opts.h@1.80 +3 -3 + NTP_4_2_7P79 + + ntpq/ntpq-opts.texi@1.80 +2 -2 + NTP_4_2_7P79 + + ntpq/ntpq.1@1.80 +2 -2 + NTP_4_2_7P79 + + ntpsnmpd/ntpsnmpd-opts.c@1.80 +2 -2 + NTP_4_2_7P79 + + ntpsnmpd/ntpsnmpd-opts.h@1.80 +3 -3 + NTP_4_2_7P79 + + ntpsnmpd/ntpsnmpd-opts.texi@1.80 +2 -2 + NTP_4_2_7P79 + + ntpsnmpd/ntpsnmpd.1@1.80 +2 -2 + NTP_4_2_7P79 + + packageinfo.sh@1.81 +1 -1 + NTP_4_2_7P79 + + sntp/sntp-opts.c@1.80 +2 -2 + NTP_4_2_7P79 + + sntp/sntp-opts.h@1.80 +3 -3 + NTP_4_2_7P79 + + sntp/sntp-opts.texi@1.80 +1 -1 + NTP_4_2_7P79 + + sntp/sntp.1@1.80 +2 -2 + NTP_4_2_7P79 + + sntp/sntp.html@1.80 +1 -1 + NTP_4_2_7P79 + + util/ntp-keygen-opts.c@1.77 +2 -2 + NTP_4_2_7P79 + + util/ntp-keygen-opts.h@1.77 +3 -3 + NTP_4_2_7P79 + + util/ntp-keygen-opts.texi@1.80 +2 -2 + NTP_4_2_7P79 + + util/ntp-keygen.1@1.80 +2 -2 + NTP_4_2_7P79 + +ChangeSet@1.2253, 2010-11-06 22:00:48-04:00, stenn@deacon.udel.edu + Correct frequency estimate with no drift file, from David Mills + + ChangeLog@1.642 +1 -0 + Correct frequency estimate with no drift file, from David Mills + + ntpd/ntp_loopfilter.c@1.161 +1 -1 + Correct frequency estimate with no drift file, from David Mills + +ChangeSet@1.2252, 2010-11-04 10:10:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P78 + TAG: NTP_4_2_7P78 + + ChangeLog@1.641 +1 -0 + NTP_4_2_7P78 + + ntpd/ntpd-opts.c@1.81 +2 -2 + NTP_4_2_7P78 + + ntpd/ntpd-opts.h@1.81 +3 -3 + NTP_4_2_7P78 + + ntpd/ntpd-opts.texi@1.80 +2 -2 + NTP_4_2_7P78 + + ntpd/ntpd.1@1.80 +2 -2 + NTP_4_2_7P78 + + ntpdc/ntpdc-opts.c@1.79 +2 -2 + NTP_4_2_7P78 + + ntpdc/ntpdc-opts.h@1.79 +3 -3 + NTP_4_2_7P78 + + ntpdc/ntpdc-opts.texi@1.79 +2 -2 + NTP_4_2_7P78 + + ntpdc/ntpdc.1@1.79 +2 -2 + NTP_4_2_7P78 + + ntpq/ntpq-opts.c@1.79 +2 -2 + NTP_4_2_7P78 + + ntpq/ntpq-opts.h@1.79 +3 -3 + NTP_4_2_7P78 + + ntpq/ntpq-opts.texi@1.79 +2 -2 + NTP_4_2_7P78 + + ntpq/ntpq.1@1.79 +2 -2 + NTP_4_2_7P78 + + ntpsnmpd/ntpsnmpd-opts.c@1.79 +2 -2 + NTP_4_2_7P78 + + ntpsnmpd/ntpsnmpd-opts.h@1.79 +3 -3 + NTP_4_2_7P78 + + ntpsnmpd/ntpsnmpd-opts.texi@1.79 +2 -2 + NTP_4_2_7P78 + + ntpsnmpd/ntpsnmpd.1@1.79 +2 -2 + NTP_4_2_7P78 + + packageinfo.sh@1.80 +1 -1 + NTP_4_2_7P78 + + sntp/sntp-opts.c@1.79 +2 -2 + NTP_4_2_7P78 + + sntp/sntp-opts.h@1.79 +3 -3 + NTP_4_2_7P78 + + sntp/sntp-opts.texi@1.79 +1 -1 + NTP_4_2_7P78 + + sntp/sntp.1@1.79 +2 -2 + NTP_4_2_7P78 + + sntp/sntp.html@1.79 +1 -1 + NTP_4_2_7P78 + + util/ntp-keygen-opts.c@1.76 +2 -2 + NTP_4_2_7P78 + + util/ntp-keygen-opts.h@1.76 +3 -3 + NTP_4_2_7P78 + + util/ntp-keygen-opts.texi@1.79 +2 -2 + NTP_4_2_7P78 + + util/ntp-keygen.1@1.79 +2 -2 + NTP_4_2_7P78 + +ChangeSet@1.2251, 2010-11-04 03:05:07-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.640 +1 -0 + Documentation updates from Dave Mills + + html/autokey.html@1.5 +28 -4 + Documentation updates from Dave Mills + + html/pps.html@1.23 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2250, 2010-11-04 02:24:39+00:00, hart@psp-deb1.ntp.org + Makefile.am: + move test-driver from EXTRA_DIST to noinst_check_SCRIPTS + + sntp/tests/Makefile.am@1.16 +3 -3 + move test-driver from EXTRA_DIST to noinst_check_SCRIPTS + +ChangeSet@1.2249, 2010-11-04 00:06:45+00:00, davehart@shiny.ad.hartbrothers.com + fix make distcheck with gtest by distributing test pieces + + sntp/Makefile.am@1.37 +1 -0 + fix make distcheck with gtest by distributing test pieces + + sntp/tests/Makefile.am@1.15 +35 -11 + fix make distcheck with gtest by distributing test pieces. + get rid of most tabs in INCLUDES which show up in command lines. + + tests/libntp/Makefile.am@1.24 +3 -0 + fix make distcheck with gtest by distributing test pieces + +ChangeSet@1.2248, 2010-11-03 21:24:43+00:00, davehart@shiny.ad.hartbrothers.com + Add ChangeLog entries, Windows build tweaks to Juergen Perlinger's + calendar refactoring and [Bug 1697] + + ChangeLog@1.639 +2 -0 + [Bug 1697] filegen implementation should be improved. + Refactor calendar functions in terms of new common code. + + + configure.ac@1.494 +4 -3 + Add sizeof(short) test since we now depend on SIZEOF_SHORT + + ports/winnt/include/config.h@1.89 +1 -0 + add SIZEOF_SHORT needed by perlinger's calendar changes + + ports/winnt/vc6/libntp.dsp@1.53 +4 -0 + add libntp/ntp_calendar.c to Windows build + + ports/winnt/vs2003/libntp.vcproj@1.11 +21 -0 + add libntp/ntp_calendar.c to Windows build + + ports/winnt/vs2005/libntp.vcproj@1.9 +22 -0 + add libntp/ntp_calendar.c to Windows build + + ports/winnt/vs2008/libntp/libntp.vcproj@1.30 +6 -2 + add libntp/ntp_calendar.c to Windows build + + sntp/configure.ac@1.41 +1 -0 + Add sizeof(short) test since we now depend on SIZEOF_SHORT + + sntp/tests/crypto.cpp@1.4 +4 -0 + conditionalize tests that only work with OPENSSL + + tests/libntp/a_md5encrypt.cpp@1.4 +5 -0 + ensure NID_md5 is defined (by openssl headers or ntp_stdlib.h) + + tests/libntp/authkeys.cpp@1.6 +5 -0 + ensure NID_md5 is defined (by openssl headers or ntp_stdlib.h) + + tests/libntp/refnumtoa.cpp@1.2 +4 -0 + conditionalize tests that require REFCLOCK + + tests/libntp/ssl_init.cpp@1.3 +9 -0 + ensure NID_md5 is defined (by openssl headers or ntp_stdlib.h) + conditionalize tests that only work with OPENSSL + +ChangeSet@1.2243.1.3, 2010-11-03 19:42:16+01:00, jnperlin@hydra.localnet + added calendar regression tests, fixed german umlaut mixup + + include/ntp_filegen.h@1.9 +1 -1 + fixed german umlaut codepage problem + + libntp/ntp_calendar.c@1.2 +11 -73 + removed runtime assert, since regression test is available + + ntpd/ntp_filegen.c@1.21 +1 -1 + fixed german umlaut codepage problem + + tests/libntp/Makefile.am@1.23 +1 -0 + added calendar regression tests + + tests/libntp/calendar.cpp@1.1 +337 -0 + calendar module regression tests + + tests/libntp/calendar.cpp@1.0 +0 -0 + +ChangeSet@1.2246, 2010-11-03 10:10:10+00:00, stenn@deacon.udel.edu + NTP_4_2_7P77 + TAG: NTP_4_2_7P77 + + ChangeLog@1.638 +1 -0 + NTP_4_2_7P77 + + ntpd/ntpd-opts.c@1.80 +2 -2 + NTP_4_2_7P77 + + ntpd/ntpd-opts.h@1.80 +3 -3 + NTP_4_2_7P77 + + ntpd/ntpd-opts.texi@1.79 +2 -2 + NTP_4_2_7P77 + + ntpd/ntpd.1@1.79 +2 -2 + NTP_4_2_7P77 + + ntpdc/ntpdc-opts.c@1.78 +2 -2 + NTP_4_2_7P77 + + ntpdc/ntpdc-opts.h@1.78 +3 -3 + NTP_4_2_7P77 + + ntpdc/ntpdc-opts.texi@1.78 +2 -2 + NTP_4_2_7P77 + + ntpdc/ntpdc.1@1.78 +2 -2 + NTP_4_2_7P77 + + ntpq/ntpq-opts.c@1.78 +2 -2 + NTP_4_2_7P77 + + ntpq/ntpq-opts.h@1.78 +3 -3 + NTP_4_2_7P77 + + ntpq/ntpq-opts.texi@1.78 +2 -2 + NTP_4_2_7P77 + + ntpq/ntpq.1@1.78 +2 -2 + NTP_4_2_7P77 + + ntpsnmpd/ntpsnmpd-opts.c@1.78 +2 -2 + NTP_4_2_7P77 + + ntpsnmpd/ntpsnmpd-opts.h@1.78 +3 -3 + NTP_4_2_7P77 + + ntpsnmpd/ntpsnmpd-opts.texi@1.78 +2 -2 + NTP_4_2_7P77 + + ntpsnmpd/ntpsnmpd.1@1.78 +2 -2 + NTP_4_2_7P77 + + packageinfo.sh@1.79 +1 -1 + NTP_4_2_7P77 + + sntp/sntp-opts.c@1.78 +2 -2 + NTP_4_2_7P77 + + sntp/sntp-opts.h@1.78 +3 -3 + NTP_4_2_7P77 + + sntp/sntp-opts.texi@1.78 +1 -1 + NTP_4_2_7P77 + + sntp/sntp.1@1.78 +2 -2 + NTP_4_2_7P77 + + sntp/sntp.html@1.78 +1 -1 + NTP_4_2_7P77 + + util/ntp-keygen-opts.c@1.75 +2 -2 + NTP_4_2_7P77 + + util/ntp-keygen-opts.h@1.75 +3 -3 + NTP_4_2_7P77 + + util/ntp-keygen-opts.texi@1.78 +2 -2 + NTP_4_2_7P77 + + util/ntp-keygen.1@1.78 +2 -2 + NTP_4_2_7P77 + +ChangeSet@1.2243.3.1, 2010-11-02 21:46:55-04:00, stenn@deacon.udel.edu + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + + ChangeLog@1.635.1.1 +1 -0 + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + + scripts/checkChangeLog@1.1.1.1 +1 -1 + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + + scripts/genCommitLog@1.6 +1 -1 + [Bug 1692] packageinfo.sh needs to be "sourced" using ./ + +ChangeSet@1.2243.1.2, 2010-11-02 20:21:30+01:00, jnperlin@hydra.localnet + fixes for regression test + + libntp/prettydate.c@1.16 +2 -2 + changed format string back according to regression test expectation + + libntp/ymd2yd.c@1.5 +13 -25 + rewritten in terms of low-level calendar function + + scripts/checkChangeLog@1.2 +1 -1 + added path spec to '.' (source) command -- sh balked about it + + tests/libntp/calyearstart.cpp@1.2 +14 -15 + fixed testcases for new calyearstart() API + +ChangeSet@1.2243.2.1, 2010-11-02 18:55:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1695] ntpdate takes longer than necessary. + + ChangeLog@1.636 +1 -0 + [Bug 1695] ntpdate takes longer than necessary. + + ntpdate/ntpdate.c@1.75 +11 -0 + [Bug 1695] ntpdate takes longer than necessary. + +ChangeSet@1.2156.20.1, 2010-11-02 07:12:48+01:00, jnperlin@hydra.localnet + added modular calendar functions + + include/ntp_calendar.h@1.5 +278 -23 + added prototypes for modular calendar functions + + include/ntp_filegen.h@1.8 +5 -4 + fixed prototypes to use u_int32 for NTP timestamps + + include/ntp_fp.h@1.22 +1 -1 + fixed prototypes to use u_int32 for NTP timestamps + + include/ntp_stdlib.h@1.48 +12 -2 + fixed prototypes to use u_int32 for NTP timestamps; added functions for start of month/week/day + + include/ntp_types.h@1.20 +92 -1 + added 'vint64' type definition + + include/ntp_unixtime.h@1.7 +5 -0 + added multiple inclusion guard + + libntp/Makefile.am@1.53 +1 -0 + added calendar module + + libntp/caljulian.c@1.13 +15 -173 + rewritten in terms of modular calendar + + libntp/caltontp.c@1.5 +19 -57 + rewritten in terms of modular calendar + + libntp/calyearstart.c@1.6 +70 -39 + rewritten in terms of modular calendar; added month/wee/day start fuctions + + libntp/clocktime.c@1.4 +128 -94 + rewritten in terms of modular calendar; changed algorithm to *always* find the smallest difference solution for a time-of-year spec. + + libntp/ntp_calendar.c@1.1 +1390 -0 + modular calendar functions + + libntp/ntp_calendar.c@1.0 +0 -0 + + libntp/prettydate.c@1.15 +149 -123 + rewritten in terms of modular calendar + + ntpd/ntp_filegen.c@1.20 +126 -126 + minimise calendar calculations + + ntpd/ntp_util.c@1.86 +35 -56 + changed 'leap_month' to use modular alendar + +ChangeSet@1.2244, 2010-11-02 01:31:41-04:00, stenn@deacon.udel.edu + Distribute the test/ subdir + + Makefile.am@1.98 +1 -3 + Distribute the test/ subdir + +ChangeSet@1.2243, 2010-11-02 04:50:36+00:00, stenn@deacon.udel.edu + NTP_4_2_7P76 + TAG: NTP_4_2_7P76 + + ChangeLog@1.635 +1 -0 + NTP_4_2_7P76 + + ntpd/ntpd-opts.c@1.79 +2 -2 + NTP_4_2_7P76 + + ntpd/ntpd-opts.h@1.79 +3 -3 + NTP_4_2_7P76 + + ntpd/ntpd-opts.texi@1.78 +2 -2 + NTP_4_2_7P76 + + ntpd/ntpd.1@1.78 +2 -2 + NTP_4_2_7P76 + + ntpdc/ntpdc-opts.c@1.77 +2 -2 + NTP_4_2_7P76 + + ntpdc/ntpdc-opts.h@1.77 +3 -3 + NTP_4_2_7P76 + + ntpdc/ntpdc-opts.texi@1.77 +2 -2 + NTP_4_2_7P76 + + ntpdc/ntpdc.1@1.77 +2 -2 + NTP_4_2_7P76 + + ntpq/ntpq-opts.c@1.77 +2 -2 + NTP_4_2_7P76 + + ntpq/ntpq-opts.h@1.77 +3 -3 + NTP_4_2_7P76 + + ntpq/ntpq-opts.texi@1.77 +2 -2 + NTP_4_2_7P76 + + ntpq/ntpq.1@1.77 +2 -2 + NTP_4_2_7P76 + + ntpsnmpd/ntpsnmpd-opts.c@1.77 +2 -2 + NTP_4_2_7P76 + + ntpsnmpd/ntpsnmpd-opts.h@1.77 +3 -3 + NTP_4_2_7P76 + + ntpsnmpd/ntpsnmpd-opts.texi@1.77 +2 -2 + NTP_4_2_7P76 + + ntpsnmpd/ntpsnmpd.1@1.77 +2 -2 + NTP_4_2_7P76 + + packageinfo.sh@1.78 +1 -1 + NTP_4_2_7P76 + + sntp/sntp-opts.c@1.77 +2 -2 + NTP_4_2_7P76 + + sntp/sntp-opts.h@1.77 +3 -3 + NTP_4_2_7P76 + + sntp/sntp-opts.texi@1.77 +1 -1 + NTP_4_2_7P76 + + sntp/sntp.1@1.77 +2 -2 + NTP_4_2_7P76 + + sntp/sntp.html@1.77 +1 -1 + NTP_4_2_7P76 + + util/ntp-keygen-opts.c@1.74 +2 -2 + NTP_4_2_7P76 + + util/ntp-keygen-opts.h@1.74 +3 -3 + NTP_4_2_7P76 + + util/ntp-keygen-opts.texi@1.77 +2 -2 + NTP_4_2_7P76 + + util/ntp-keygen.1@1.77 +2 -2 + NTP_4_2_7P76 + +ChangeSet@1.2242, 2010-11-01 00:46:10-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.634 +1 -0 + Documentation updates from Dave Mills + + html/authentic.html@1.5 +9 -7 + Documentation updates from Dave Mills + + html/authopt.html@1.66 +16 -16 + Documentation updates from Dave Mills + + html/autokey.html@1.4 +10 -9 + Documentation updates from Dave Mills + + html/keygen.html@1.22 +9 -3 + Documentation updates from Dave Mills + + html/scripts/external.txt@1.5 +1 -0 + Documentation updates from Dave Mills + +ChangeSet@1.2240, 2010-11-01 00:29:29-04:00, stenn@deacon.udel.edu + [Bug 1692] in sntp/, -lrt may only be needed in tests/ + + sntp/configure.ac@1.40 +1 -0 + [Bug 1692] in sntp/, -lrt may only be needed in tests/ + +ChangeSet@1.2238.1.2, 2010-11-01 00:23:48+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog entry for [Bug 1691] -dev first + + ChangeLog@1.631.1.1 +1 -0 + [Bug 1691] Use first NMEA sentence each second. + +ChangeSet@1.2082.4.139, 2010-11-01 00:22:07+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1691] Use first NMEA sentence each second. + + ntpd/refclock_nmea.c@1.46.1.10 +26 -9 + [Bug 1691] Use first NMEA sentence each second. + +ChangeSet@1.2239, 2010-10-31 07:57:32-04:00, karlsson@psp-deb1.ntp.org + [BUG 1690] Unit tests fails to build on some systems + + ChangeLog@1.632 +1 -0 + [BUG 1690] Unit tests fails to build on some systems + + sntp/configure.ac@1.39 +18 -0 + [BUG 1690] Unit tests fails to build on some systems + +ChangeSet@1.2238, 2010-10-31 01:30:37-04:00, stenn@deacon.udel.edu + Only build/run the sntp tests if we have gtest + + ChangeLog@1.631 +1 -0 + Only build/run the sntp tests if we have gtest + + sntp/Makefile.am@1.36 +3 -0 + Only build/run the sntp tests if we have gtest + +ChangeSet@1.2235.1.1, 2010-10-30 20:28:54-07:00, harlan@hms-mbp.lan + Put the sntp tests under sntp/ + --- + Put the sntp tests under sntp/ + + ChangeLog@1.628.1.1 +1 -0 + Put the sntp tests under sntp/ + + configure.ac@1.493 +0 -1 + Put the sntp tests under sntp/ + + sntp/Makefile.am@1.35 +1 -0 + Put the sntp tests under sntp/ + + sntp/configure.ac@1.38 +20 -0 + Put the sntp tests under sntp/ + + sntp/tests/Makefile.am@1.14 +19 -17 + Put the sntp tests under sntp/ + + sntp/tests/Makefile.am@1.13 +0 -0 + Rename: tests/sntp/Makefile.am -> sntp/tests/Makefile.am + + sntp/tests/crypto.cpp@1.3 +0 -0 + Rename: tests/sntp/crypto.cpp -> sntp/tests/crypto.cpp + + sntp/tests/data/debug-input-lfp-bin@1.2 +0 -0 + Rename: tests/sntp/data/debug-input-lfp-bin -> sntp/tests/data/debug-input-lfp-bin + + sntp/tests/data/debug-input-lfp-dec@1.2 +0 -0 + Rename: tests/sntp/data/debug-input-lfp-dec -> sntp/tests/data/debug-input-lfp-dec + + sntp/tests/data/debug-input-lfp-hex@1.2 +0 -0 + Rename: tests/sntp/data/debug-input-lfp-hex -> sntp/tests/data/debug-input-lfp-hex + + sntp/tests/data/debug-input-pkt@1.2 +0 -0 + Rename: tests/sntp/data/debug-input-pkt -> sntp/tests/data/debug-input-pkt + + sntp/tests/data/key-test-ascii@1.2 +0 -0 + Rename: tests/sntp/data/key-test-ascii -> sntp/tests/data/key-test-ascii + + sntp/tests/data/key-test-comments@1.2 +0 -0 + Rename: tests/sntp/data/key-test-comments -> sntp/tests/data/key-test-comments + + sntp/tests/data/key-test-empty@1.2 +0 -0 + Rename: tests/sntp/data/key-test-empty -> sntp/tests/data/key-test-empty + + sntp/tests/data/key-test-hex@1.2 +0 -0 + Rename: tests/sntp/data/key-test-hex -> sntp/tests/data/key-test-hex + + sntp/tests/data/key-test-invalid-hex@1.2 +0 -0 + Rename: tests/sntp/data/key-test-invalid-hex -> sntp/tests/data/key-test-invalid-hex + + sntp/tests/data/kod-expected-multiple@1.2 +0 -0 + Rename: tests/sntp/data/kod-expected-multiple -> sntp/tests/data/kod-expected-multiple + + sntp/tests/data/kod-expected-single@1.2 +0 -0 + Rename: tests/sntp/data/kod-expected-single -> sntp/tests/data/kod-expected-single + + sntp/tests/data/kod-test-blanks@1.3 +0 -0 + Rename: tests/sntp/data/kod-test-blanks -> sntp/tests/data/kod-test-blanks + + sntp/tests/data/kod-test-correct@1.3 +0 -0 + Rename: tests/sntp/data/kod-test-correct -> sntp/tests/data/kod-test-correct + + sntp/tests/data/kod-test-empty@1.2 +0 -0 + Rename: tests/sntp/data/kod-test-empty -> sntp/tests/data/kod-test-empty + + sntp/tests/data/log-expected-debug@1.2 +0 -0 + Rename: tests/sntp/data/log-expected-debug -> sntp/tests/data/log-expected-debug + + sntp/tests/data/log-expected-log@1.2 +0 -0 + Rename: tests/sntp/data/log-expected-log -> sntp/tests/data/log-expected-log + + sntp/tests/fileHandlingTest.h@1.4 +0 -0 + Rename: tests/sntp/fileHandlingTest.h -> sntp/tests/fileHandlingTest.h + + sntp/tests/keyFile.cpp@1.3 +0 -0 + Rename: tests/sntp/keyFile.cpp -> sntp/tests/keyFile.cpp + + sntp/tests/kodDatabase.cpp@1.2 +0 -0 + Rename: tests/sntp/kodDatabase.cpp -> sntp/tests/kodDatabase.cpp + + sntp/tests/kodFile.cpp@1.7 +0 -0 + Rename: tests/sntp/kodFile.cpp -> sntp/tests/kodFile.cpp + + sntp/tests/logFile.cpp@1.5 +0 -0 + Rename: tests/sntp/logFile.cpp -> sntp/tests/logFile.cpp + + sntp/tests/networking.cpp@1.7 +0 -0 + Rename: tests/sntp/networking.cpp -> sntp/tests/networking.cpp + + sntp/tests/packetHandling.cpp@1.4 +0 -0 + Rename: tests/sntp/packetHandling.cpp -> sntp/tests/packetHandling.cpp + + sntp/tests/packetProcessing.cpp@1.4 +0 -0 + Rename: tests/sntp/packetProcessing.cpp -> sntp/tests/packetProcessing.cpp + + sntp/tests/sntptest.cpp@1.2 +0 -0 + Rename: tests/sntp/sntptest.cpp -> sntp/tests/sntptest.cpp + + sntp/tests/sntptest.h@1.5 +0 -0 + Rename: tests/sntp/sntptest.h -> sntp/tests/sntptest.h + + sntp/tests/test-driver@1.4 +0 -0 + Rename: tests/sntp/test-driver -> sntp/tests/test-driver + + sntp/tests/utilities.cpp@1.4 +0 -0 + Rename: tests/sntp/utilities.cpp -> sntp/tests/utilities.cpp + + sntp/tests_main.cpp@1.6 +0 -0 + Rename: tests/tests_main.cpp -> sntp/tests_main.cpp + + sntp/tests_main.h@1.6 +0 -0 + Rename: tests/tests_main.h -> sntp/tests_main.h + + tests/Makefile.am@1.4 +1 -1 + Put the sntp tests under sntp/ + + tests/libntp/Makefile.am@1.22 +7 -5 + Put the sntp tests under sntp/ + +ChangeSet@1.2236, 2010-10-30 10:23:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P75 + TAG: NTP_4_2_7P75 + + ChangeLog@1.629 +1 -0 + NTP_4_2_7P75 + + ntpd/ntpd-opts.c@1.78 +2 -2 + NTP_4_2_7P75 + + ntpd/ntpd-opts.h@1.78 +3 -3 + NTP_4_2_7P75 + + ntpd/ntpd-opts.texi@1.77 +2 -2 + NTP_4_2_7P75 + + ntpd/ntpd.1@1.77 +2 -2 + NTP_4_2_7P75 + + ntpdc/ntpdc-opts.c@1.76 +2 -2 + NTP_4_2_7P75 + + ntpdc/ntpdc-opts.h@1.76 +3 -3 + NTP_4_2_7P75 + + ntpdc/ntpdc-opts.texi@1.76 +2 -2 + NTP_4_2_7P75 + + ntpdc/ntpdc.1@1.76 +2 -2 + NTP_4_2_7P75 + + ntpq/ntpq-opts.c@1.76 +2 -2 + NTP_4_2_7P75 + + ntpq/ntpq-opts.h@1.76 +3 -3 + NTP_4_2_7P75 + + ntpq/ntpq-opts.texi@1.76 +2 -2 + NTP_4_2_7P75 + + ntpq/ntpq.1@1.76 +2 -2 + NTP_4_2_7P75 + + ntpsnmpd/ntpsnmpd-opts.c@1.76 +2 -2 + NTP_4_2_7P75 + + ntpsnmpd/ntpsnmpd-opts.h@1.76 +3 -3 + NTP_4_2_7P75 + + ntpsnmpd/ntpsnmpd-opts.texi@1.76 +2 -2 + NTP_4_2_7P75 + + ntpsnmpd/ntpsnmpd.1@1.76 +2 -2 + NTP_4_2_7P75 + + packageinfo.sh@1.77 +1 -1 + NTP_4_2_7P75 + + sntp/sntp-opts.c@1.76 +2 -2 + NTP_4_2_7P75 + + sntp/sntp-opts.h@1.76 +3 -3 + NTP_4_2_7P75 + + sntp/sntp-opts.texi@1.76 +1 -1 + NTP_4_2_7P75 + + sntp/sntp.1@1.76 +2 -2 + NTP_4_2_7P75 + + sntp/sntp.html@1.76 +1 -1 + NTP_4_2_7P75 + + util/ntp-keygen-opts.c@1.73 +2 -2 + NTP_4_2_7P75 + + util/ntp-keygen-opts.h@1.73 +3 -3 + NTP_4_2_7P75 + + util/ntp-keygen-opts.texi@1.76 +2 -2 + NTP_4_2_7P75 + + util/ntp-keygen.1@1.76 +2 -2 + NTP_4_2_7P75 + +ChangeSet@1.2235, 2010-10-29 23:37:04-04:00, stenn@deacon.udel.edu + Include Linus Karlsson's GSoC 2010 testing code. + + ChangeLog@1.628 +1 -0 + Include Linus Karlsson's GSoC 2010 testing code. + +ChangeSet@1.2156.1.152, 2010-10-29 22:20:16-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.98 +1 -0 + Documentation updates from Dave Mills + + html/prefer.html@1.25 +13 -14 + Documentation updates from Dave Mills + +ChangeSet@1.2233, 2010-10-29 11:41:29-07:00, karlsson@psp-os1.ntp.org + Fixed required include on Solaris + + tests/libntp/buftvtots.cpp@1.3 +3 -0 + Fixed required include on Solaris + + tests/libntp/tvtots.cpp@1.5 +3 -0 + Fixed required include on Solaris + +ChangeSet@1.2232, 2010-10-29 20:13:53+02:00, linus@beam.lund.zozs.se + Fixed floating point test errors. + + tests/libntp/buftvtots.cpp@1.2 +11 -2 + Fixed floating point test errors. + + tests/libntp/tvtots.cpp@1.4 +13 -5 + Fixed floating point test errors. + +ChangeSet@1.2156.1.151, 2010-10-29 09:45:21+00:00, stenn@deacon.udel.edu + NTP_4_2_7P74 + TAG: NTP_4_2_7P74 + + ChangeLog@1.622.1.97 +1 -0 + NTP_4_2_7P74 + + ntpd/ntpd-opts.c@1.77 +2 -2 + NTP_4_2_7P74 + + ntpd/ntpd-opts.h@1.77 +3 -3 + NTP_4_2_7P74 + + ntpd/ntpd-opts.texi@1.76 +2 -2 + NTP_4_2_7P74 + + ntpd/ntpd.1@1.76 +2 -2 + NTP_4_2_7P74 + + ntpdc/ntpdc-opts.c@1.75 +2 -2 + NTP_4_2_7P74 + + ntpdc/ntpdc-opts.h@1.75 +3 -3 + NTP_4_2_7P74 + + ntpdc/ntpdc-opts.texi@1.75 +2 -2 + NTP_4_2_7P74 + + ntpdc/ntpdc.1@1.75 +2 -2 + NTP_4_2_7P74 + + ntpq/ntpq-opts.c@1.75 +2 -2 + NTP_4_2_7P74 + + ntpq/ntpq-opts.h@1.75 +3 -3 + NTP_4_2_7P74 + + ntpq/ntpq-opts.texi@1.75 +2 -2 + NTP_4_2_7P74 + + ntpq/ntpq.1@1.75 +2 -2 + NTP_4_2_7P74 + + ntpsnmpd/ntpsnmpd-opts.c@1.75 +2 -2 + NTP_4_2_7P74 + + ntpsnmpd/ntpsnmpd-opts.h@1.75 +3 -3 + NTP_4_2_7P74 + + ntpsnmpd/ntpsnmpd-opts.texi@1.75 +2 -2 + NTP_4_2_7P74 + + ntpsnmpd/ntpsnmpd.1@1.75 +2 -2 + NTP_4_2_7P74 + + packageinfo.sh@1.76 +1 -1 + NTP_4_2_7P74 + + sntp/sntp-opts.c@1.75 +2 -2 + NTP_4_2_7P74 + + sntp/sntp-opts.h@1.75 +3 -3 + NTP_4_2_7P74 + + sntp/sntp-opts.texi@1.75 +1 -1 + NTP_4_2_7P74 + + sntp/sntp.1@1.75 +2 -2 + NTP_4_2_7P74 + + sntp/sntp.html@1.75 +1 -1 + NTP_4_2_7P74 + + util/ntp-keygen-opts.c@1.72 +2 -2 + NTP_4_2_7P74 + + util/ntp-keygen-opts.h@1.72 +3 -3 + NTP_4_2_7P74 + + util/ntp-keygen-opts.texi@1.75 +2 -2 + NTP_4_2_7P74 + + util/ntp-keygen.1@1.75 +2 -2 + NTP_4_2_7P74 + +ChangeSet@1.2156.1.150, 2010-10-29 04:56:14-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.96 +1 -0 + Documentation updates from Dave Mills + + html/authentic.html@1.4 +10 -3 + Documentation updates from Dave Mills + +ChangeSet@1.2082.4.138, 2010-10-29 04:44:28-04:00, stenn@deacon.udel.edu + checkChangeLog fix for Makefile.am + + Makefile.am@1.93.2.3 +1 -1 + checkChangeLog fix for Makefile.am + +ChangeSet@1.2082.4.137, 2010-10-29 08:25:39+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC8 + TAG: NTP_4_2_6P3_RC8 + + ChangeLog@1.496.26.101 +1 -0 + NTP_4_2_6P3_RC8 + + ntpd/ntpd-opts.c@1.248.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpd/ntpd-opts.h@1.248.24.1 +3 -3 + NTP_4_2_6P3_RC8 + + ntpd/ntpd-opts.texi@1.246.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpd/ntpd.1@1.246.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpdc/ntpdc-opts.c@1.244.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpdc/ntpdc-opts.h@1.244.24.1 +3 -3 + NTP_4_2_6P3_RC8 + + ntpdc/ntpdc-opts.texi@1.243.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpdc/ntpdc.1@1.243.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpq/ntpq-opts.c@1.245.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpq/ntpq-opts.h@1.245.24.1 +3 -3 + NTP_4_2_6P3_RC8 + + ntpq/ntpq-opts.texi@1.244.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpq/ntpq.1@1.244.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.25.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.25.1 +3 -3 + NTP_4_2_6P3_RC8 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.25.1 +2 -2 + NTP_4_2_6P3_RC8 + + ntpsnmpd/ntpsnmpd.1@1.122.25.1 +2 -2 + NTP_4_2_6P3_RC8 + + packageinfo.sh@1.255.26.1 +1 -1 + NTP_4_2_6P3_RC8 + + sntp/sntp-opts.c@1.117.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + sntp/sntp-opts.h@1.117.24.1 +3 -3 + NTP_4_2_6P3_RC8 + + sntp/sntp-opts.texi@1.117.24.1 +1 -1 + NTP_4_2_6P3_RC8 + + sntp/sntp.1@1.117.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + sntp/sntp.html@1.7.24.1 +1 -1 + NTP_4_2_6P3_RC8 + + util/ntp-keygen-opts.c@1.247.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + util/ntp-keygen-opts.h@1.247.24.1 +3 -3 + NTP_4_2_6P3_RC8 + + util/ntp-keygen-opts.texi@1.246.24.1 +2 -2 + NTP_4_2_6P3_RC8 + + util/ntp-keygen.1@1.246.24.1 +2 -2 + NTP_4_2_6P3_RC8 + +ChangeSet@1.2082.4.136, 2010-10-29 04:13:47-04:00, stenn@deacon.udel.edu + First cut at using scripts/checkChangeLog + + ChangeLog@1.496.26.100 +1 -0 + First cut at using scripts/checkChangeLog + + Makefile.am@1.93.2.2 +5 -0 + First cut at using scripts/checkChangeLog + +ChangeSet@1.2082.4.135, 2010-10-29 03:39:15-04:00, stenn@psp-deb1.ntp.org + typo + + ChangeLog@1.496.26.99 +1 -1 + typo + +ChangeSet@1.2082.4.134, 2010-10-28 18:07:23+00:00, hart@psp-os1.ntp.org + for perlinger, [Bug 1685] + + ChangeLog@1.496.26.98 +4 -0 + for perlinger, [Bug 1685] + + ntpd/refclock_nmea.c@1.46.1.9 +2 -1 + for perlinger, [Bug 1685] + +ChangeSet@1.2156.1.148, 2010-10-27 07:35:29+00:00, stenn@deacon.udel.edu + NTP_4_2_7P73 + TAG: NTP_4_2_7P73 + + ChangeLog@1.622.1.94 +1 -0 + NTP_4_2_7P73 + + ntpd/ntpd-opts.c@1.76 +2 -2 + NTP_4_2_7P73 + + ntpd/ntpd-opts.h@1.76 +3 -3 + NTP_4_2_7P73 + + ntpd/ntpd-opts.texi@1.75 +2 -2 + NTP_4_2_7P73 + + ntpd/ntpd.1@1.75 +2 -2 + NTP_4_2_7P73 + + ntpdc/ntpdc-opts.c@1.74 +2 -2 + NTP_4_2_7P73 + + ntpdc/ntpdc-opts.h@1.74 +3 -3 + NTP_4_2_7P73 + + ntpdc/ntpdc-opts.texi@1.74 +2 -2 + NTP_4_2_7P73 + + ntpdc/ntpdc.1@1.74 +2 -2 + NTP_4_2_7P73 + + ntpq/ntpq-opts.c@1.74 +2 -2 + NTP_4_2_7P73 + + ntpq/ntpq-opts.h@1.74 +3 -3 + NTP_4_2_7P73 + + ntpq/ntpq-opts.texi@1.74 +2 -2 + NTP_4_2_7P73 + + ntpq/ntpq.1@1.74 +2 -2 + NTP_4_2_7P73 + + ntpsnmpd/ntpsnmpd-opts.c@1.74 +2 -2 + NTP_4_2_7P73 + + ntpsnmpd/ntpsnmpd-opts.h@1.74 +3 -3 + NTP_4_2_7P73 + + ntpsnmpd/ntpsnmpd-opts.texi@1.74 +2 -2 + NTP_4_2_7P73 + + ntpsnmpd/ntpsnmpd.1@1.74 +2 -2 + NTP_4_2_7P73 + + packageinfo.sh@1.75 +1 -1 + NTP_4_2_7P73 + + sntp/sntp-opts.c@1.74 +2 -2 + NTP_4_2_7P73 + + sntp/sntp-opts.h@1.74 +3 -3 + NTP_4_2_7P73 + + sntp/sntp-opts.texi@1.74 +1 -1 + NTP_4_2_7P73 + + sntp/sntp.1@1.74 +2 -2 + NTP_4_2_7P73 + + sntp/sntp.html@1.74 +1 -1 + NTP_4_2_7P73 + + util/ntp-keygen-opts.c@1.71 +2 -2 + NTP_4_2_7P73 + + util/ntp-keygen-opts.h@1.71 +3 -3 + NTP_4_2_7P73 + + util/ntp-keygen-opts.texi@1.74 +2 -2 + NTP_4_2_7P73 + + util/ntp-keygen.1@1.74 +2 -2 + NTP_4_2_7P73 + +ChangeSet@1.2156.1.147, 2010-10-26 21:24:02+00:00, davehart@shiny.ad.hartbrothers.com + add test case that would have caught [Bug 1678] + + ChangeLog@1.622.1.93 +1 -0 + add test case that would have caught [Bug 1678] + + ntpd/complete.conf@1.10 +2 -0 + add test case that would have caught [Bug 1678] + +ChangeSet@1.2156.1.146, 2010-10-26 17:20:17-04:00, stenn@deacon.udel.edu + ntp_loopfilter.c, ntpd.h, ChangeLog, ntp_proto.c: + * [Bug 1680] Fix alignment of clock_select() arrays. + * refinements to new startup behavior from David Mills. + + ChangeLog@1.622.1.92 +2 -0 + * [Bug 1680] Fix alignment of clock_select() arrays. + * refinements to new startup behavior from David Mills. + + include/ntpd.h@1.143 +1 -0 + * [Bug 1680] Fix alignment of clock_select() arrays. + * refinements to new startup behavior from David Mills. + + ntpd/ntp_loopfilter.c@1.160 +8 -9 + * [Bug 1680] Fix alignment of clock_select() arrays. + * refinements to new startup behavior from David Mills. + + ntpd/ntp_proto.c@1.311 +12 -12 + * [Bug 1680] Fix alignment of clock_select() arrays. + * refinements to new startup behavior from David Mills. + +ChangeSet@1.2156.1.145, 2010-10-26 16:42:45-04:00, stenn@deacon.udel.edu + For the bootstrap script, touch .html files last + + ChangeLog@1.622.1.91 +1 -0 + For the bootstrap script, touch .html files last + + bootstrap@1.33 +8 -4 + For the bootstrap script, touch .html files last + +ChangeSet@1.2156.1.144, 2010-10-26 09:20:22+00:00, stenn@deacon.udel.edu + NTP_4_2_7P72 + TAG: NTP_4_2_7P72 + + ChangeLog@1.622.1.90 +1 -0 + NTP_4_2_7P72 + + ntpd/ntpd-opts.c@1.75 +2 -2 + NTP_4_2_7P72 + + ntpd/ntpd-opts.h@1.75 +3 -3 + NTP_4_2_7P72 + + ntpd/ntpd-opts.texi@1.74 +2 -2 + NTP_4_2_7P72 + + ntpd/ntpd.1@1.74 +2 -2 + NTP_4_2_7P72 + + ntpdc/ntpdc-opts.c@1.73 +2 -2 + NTP_4_2_7P72 + + ntpdc/ntpdc-opts.h@1.73 +3 -3 + NTP_4_2_7P72 + + ntpdc/ntpdc-opts.texi@1.73 +2 -2 + NTP_4_2_7P72 + + ntpdc/ntpdc.1@1.73 +2 -2 + NTP_4_2_7P72 + + ntpq/ntpq-opts.c@1.73 +2 -2 + NTP_4_2_7P72 + + ntpq/ntpq-opts.h@1.73 +3 -3 + NTP_4_2_7P72 + + ntpq/ntpq-opts.texi@1.73 +2 -2 + NTP_4_2_7P72 + + ntpq/ntpq.1@1.73 +2 -2 + NTP_4_2_7P72 + + ntpsnmpd/ntpsnmpd-opts.c@1.73 +2 -2 + NTP_4_2_7P72 + + ntpsnmpd/ntpsnmpd-opts.h@1.73 +3 -3 + NTP_4_2_7P72 + + ntpsnmpd/ntpsnmpd-opts.texi@1.73 +2 -2 + NTP_4_2_7P72 + + ntpsnmpd/ntpsnmpd.1@1.73 +2 -2 + NTP_4_2_7P72 + + packageinfo.sh@1.74 +1 -1 + NTP_4_2_7P72 + + sntp/sntp-opts.c@1.73 +2 -2 + NTP_4_2_7P72 + + sntp/sntp-opts.h@1.73 +3 -3 + NTP_4_2_7P72 + + sntp/sntp-opts.texi@1.73 +1 -1 + NTP_4_2_7P72 + + sntp/sntp.1@1.73 +2 -2 + NTP_4_2_7P72 + + sntp/sntp.html@1.73 +1 -1 + NTP_4_2_7P72 + + util/ntp-keygen-opts.c@1.70 +2 -2 + NTP_4_2_7P72 + + util/ntp-keygen-opts.h@1.70 +3 -3 + NTP_4_2_7P72 + + util/ntp-keygen-opts.texi@1.73 +2 -2 + NTP_4_2_7P72 + + util/ntp-keygen.1@1.73 +2 -2 + NTP_4_2_7P72 + +ChangeSet@1.2156.1.143, 2010-10-26 05:05:56-04:00, stenn@deacon.udel.edu + [Bug 1679] Fix test for -lsocket. + + sntp/configure.ac@1.37 +5 -0 + [Bug 1679] Fix test for -lsocket. + +ChangeSet@1.2156.1.142, 2010-10-26 04:49:14-04:00, stenn@deacon.udel.edu + configure.ac, ChangeLog: + * [Bug 1679] Fix test for -lsocket. + * Clean up missing ;; entries in configure.ac + + ChangeLog@1.622.1.89 +2 -0 + * [Bug 1679] Fix test for -lsocket. + * Clean up missing ;; entries in configure.ac + + configure.ac@1.483.1.11 +89 -27 + * [Bug 1679] Fix test for -lsocket. + * Clean up missing ;; entries in configure.ac + +ChangeSet@1.2156.1.141, 2010-10-25 08:33:05+00:00, stenn@deacon.udel.edu + NTP_4_2_7P71 + TAG: NTP_4_2_7P71 + + ChangeLog@1.622.1.88 +1 -0 + NTP_4_2_7P71 + + ntpd/ntpd-opts.c@1.74 +2 -2 + NTP_4_2_7P71 + + ntpd/ntpd-opts.h@1.74 +3 -3 + NTP_4_2_7P71 + + ntpd/ntpd-opts.texi@1.73 +2 -2 + NTP_4_2_7P71 + + ntpd/ntpd.1@1.73 +2 -2 + NTP_4_2_7P71 + + ntpdc/ntpdc-opts.c@1.72 +2 -2 + NTP_4_2_7P71 + + ntpdc/ntpdc-opts.h@1.72 +3 -3 + NTP_4_2_7P71 + + ntpdc/ntpdc-opts.texi@1.72 +2 -2 + NTP_4_2_7P71 + + ntpdc/ntpdc.1@1.72 +2 -2 + NTP_4_2_7P71 + + ntpq/ntpq-opts.c@1.72 +2 -2 + NTP_4_2_7P71 + + ntpq/ntpq-opts.h@1.72 +3 -3 + NTP_4_2_7P71 + + ntpq/ntpq-opts.texi@1.72 +2 -2 + NTP_4_2_7P71 + + ntpq/ntpq.1@1.72 +2 -2 + NTP_4_2_7P71 + + ntpsnmpd/ntpsnmpd-opts.c@1.72 +2 -2 + NTP_4_2_7P71 + + ntpsnmpd/ntpsnmpd-opts.h@1.72 +3 -3 + NTP_4_2_7P71 + + ntpsnmpd/ntpsnmpd-opts.texi@1.72 +2 -2 + NTP_4_2_7P71 + + ntpsnmpd/ntpsnmpd.1@1.72 +2 -2 + NTP_4_2_7P71 + + packageinfo.sh@1.73 +1 -1 + NTP_4_2_7P71 + + sntp/sntp-opts.c@1.72 +2 -2 + NTP_4_2_7P71 + + sntp/sntp-opts.h@1.72 +3 -3 + NTP_4_2_7P71 + + sntp/sntp-opts.texi@1.72 +1 -1 + NTP_4_2_7P71 + + sntp/sntp.1@1.72 +2 -2 + NTP_4_2_7P71 + + sntp/sntp.html@1.72 +1 -1 + NTP_4_2_7P71 + + util/ntp-keygen-opts.c@1.69 +2 -2 + NTP_4_2_7P71 + + util/ntp-keygen-opts.h@1.69 +3 -3 + NTP_4_2_7P71 + + util/ntp-keygen-opts.texi@1.72 +2 -2 + NTP_4_2_7P71 + + util/ntp-keygen.1@1.72 +2 -2 + NTP_4_2_7P71 + +ChangeSet@1.2156.1.139, 2010-10-25 04:06:09-04:00, stenn@deacon.udel.edu + merge cleanup + + ChangeLog@1.622.1.86 +3 -0 + merge cleanup + +ChangeSet@1.2082.4.133, 2010-10-25 07:49:22+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC7 + TAG: NTP_4_2_6P3_RC7 + + ChangeLog@1.496.26.97 +1 -0 + NTP_4_2_6P3_RC7 + + ntpd/ntpd-opts.c@1.248.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpd/ntpd-opts.h@1.248.23.1 +3 -3 + NTP_4_2_6P3_RC7 + + ntpd/ntpd-opts.texi@1.246.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpd/ntpd.1@1.246.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpdc/ntpdc-opts.c@1.244.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpdc/ntpdc-opts.h@1.244.23.1 +3 -3 + NTP_4_2_6P3_RC7 + + ntpdc/ntpdc-opts.texi@1.243.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpdc/ntpdc.1@1.243.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpq/ntpq-opts.c@1.245.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpq/ntpq-opts.h@1.245.23.1 +3 -3 + NTP_4_2_6P3_RC7 + + ntpq/ntpq-opts.texi@1.244.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpq/ntpq.1@1.244.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.24.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.24.1 +3 -3 + NTP_4_2_6P3_RC7 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.24.1 +2 -2 + NTP_4_2_6P3_RC7 + + ntpsnmpd/ntpsnmpd.1@1.122.24.1 +2 -2 + NTP_4_2_6P3_RC7 + + packageinfo.sh@1.255.25.1 +1 -1 + NTP_4_2_6P3_RC7 + + sntp/sntp-opts.c@1.117.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + sntp/sntp-opts.h@1.117.23.1 +3 -3 + NTP_4_2_6P3_RC7 + + sntp/sntp-opts.texi@1.117.23.1 +1 -1 + NTP_4_2_6P3_RC7 + + sntp/sntp.1@1.117.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + sntp/sntp.html@1.7.23.1 +1 -1 + NTP_4_2_6P3_RC7 + + util/ntp-keygen-opts.c@1.247.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + util/ntp-keygen-opts.h@1.247.23.1 +3 -3 + NTP_4_2_6P3_RC7 + + util/ntp-keygen-opts.texi@1.246.23.1 +2 -2 + NTP_4_2_6P3_RC7 + + util/ntp-keygen.1@1.246.23.1 +2 -2 + NTP_4_2_6P3_RC7 + +ChangeSet@1.2156.1.138, 2010-10-25 03:34:31-04:00, stenn@deacon.udel.edu + merge cleanup + + ChangeLog@1.622.1.85 +0 -1 + merge cleanup + +ChangeSet@1.2082.4.132, 2010-10-25 03:26:31-04:00, stenn@deacon.udel.edu + Added scripts/checkChangeLog + + ChangeLog@1.496.26.96 +4 -3 + Added scripts/checkChangeLog + + scripts/Makefile.am@1.17.1.2 +1 -0 + Added scripts/checkChangeLog + + scripts/checkChangeLog@1.1 +28 -0 + BitKeeper file /deacon/backroom/ntp-stable/scripts/checkChangeLog + + scripts/checkChangeLog@1.0 +0 -0 + +ChangeSet@1.2156.19.1, 2010-10-25 02:19:58-04:00, stenn@deacon.udel.edu + typo fixes + + ChangeLog@1.622.9.1 +2 -2 + typo fixes + +ChangeSet@1.2156.1.135, 2010-10-25 05:42:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1678] "restrict source" treated as "restrict default". + + ChangeLog@1.622.1.82 +1 -0 + [Bug 1678] "restrict source" treated as "restrict default". + + ntpd/Makefile.am@1.95 +1 -0 + Make complete.conf roundtrip saveconfig failures easier to see. + + ntpd/ntp_parser.c@1.69 +676 -723 + Bison output + + ntpd/ntp_parser.y@1.63 +16 -36 + [Bug 1678] "restrict source" treated as "restrict default". + +ChangeSet@1.2082.4.131, 2010-10-24 06:17:47-04:00, perlinger@psp-deb1.ntp.org + [Bug 1676] fixed in refclock_nmea (GPGLL did not work after fix 1571) + + ChangeLog@1.496.26.95 +4 -0 + [Bug 1676] fixed in refclock_nmea (GPGLL did not work after fix 1571) + + ntpd/refclock_nmea.c@1.46.1.8 +1 -1 + fixed cut&paste error that lead to bug 1676 + +ChangeSet@1.2156.1.134, 2010-10-24 07:48:42+00:00, stenn@deacon.udel.edu + NTP_4_2_7P70 + TAG: NTP_4_2_7P70 + + ChangeLog@1.622.1.81 +1 -0 + NTP_4_2_7P70 + + ntpd/ntpd-opts.c@1.73 +2 -2 + NTP_4_2_7P70 + + ntpd/ntpd-opts.h@1.73 +3 -3 + NTP_4_2_7P70 + + ntpd/ntpd-opts.texi@1.72 +2 -2 + NTP_4_2_7P70 + + ntpd/ntpd.1@1.72 +2 -2 + NTP_4_2_7P70 + + ntpdc/ntpdc-opts.c@1.71 +2 -2 + NTP_4_2_7P70 + + ntpdc/ntpdc-opts.h@1.71 +3 -3 + NTP_4_2_7P70 + + ntpdc/ntpdc-opts.texi@1.71 +2 -2 + NTP_4_2_7P70 + + ntpdc/ntpdc.1@1.71 +2 -2 + NTP_4_2_7P70 + + ntpq/ntpq-opts.c@1.71 +2 -2 + NTP_4_2_7P70 + + ntpq/ntpq-opts.h@1.71 +3 -3 + NTP_4_2_7P70 + + ntpq/ntpq-opts.texi@1.71 +2 -2 + NTP_4_2_7P70 + + ntpq/ntpq.1@1.71 +2 -2 + NTP_4_2_7P70 + + ntpsnmpd/ntpsnmpd-opts.c@1.71 +2 -2 + NTP_4_2_7P70 + + ntpsnmpd/ntpsnmpd-opts.h@1.71 +3 -3 + NTP_4_2_7P70 + + ntpsnmpd/ntpsnmpd-opts.texi@1.71 +2 -2 + NTP_4_2_7P70 + + ntpsnmpd/ntpsnmpd.1@1.71 +2 -2 + NTP_4_2_7P70 + + packageinfo.sh@1.72 +1 -1 + NTP_4_2_7P70 + + sntp/sntp-opts.c@1.71 +2 -2 + NTP_4_2_7P70 + + sntp/sntp-opts.h@1.71 +3 -3 + NTP_4_2_7P70 + + sntp/sntp-opts.texi@1.71 +1 -1 + NTP_4_2_7P70 + + sntp/sntp.1@1.71 +2 -2 + NTP_4_2_7P70 + + sntp/sntp.html@1.71 +1 -1 + NTP_4_2_7P70 + + util/ntp-keygen-opts.c@1.68 +2 -2 + NTP_4_2_7P70 + + util/ntp-keygen-opts.h@1.68 +3 -3 + NTP_4_2_7P70 + + util/ntp-keygen-opts.texi@1.71 +2 -2 + NTP_4_2_7P70 + + util/ntp-keygen.1@1.71 +2 -2 + NTP_4_2_7P70 + +ChangeSet@1.2156.1.133, 2010-10-24 03:36:28-04:00, stenn@deacon.udel.edu + merge cleanup + + ChangeLog@1.622.1.80 +2 -0 + merge cleanup + +ChangeSet@1.2156.1.132, 2010-10-24 03:28:33-04:00, stenn@deacon.udel.edu + Fix from Dave Mills for a rare singularity in clock_combine() + + ChangeLog@1.622.1.79 +1 -0 + Fix from Dave Mills for a rare singularity in clock_combine() + + ntpd/ntp_proto.c@1.310 +1 -1 + Fix from Dave Mills for a rare singularity in clock_combine() + +ChangeSet@1.2082.4.130, 2010-10-24 06:40:26+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC6 + TAG: NTP_4_2_6P3_RC6 + + ChangeLog@1.496.26.94 +1 -0 + NTP_4_2_6P3_RC6 + + ntpd/ntpd-opts.c@1.248.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpd/ntpd-opts.h@1.248.22.1 +3 -3 + NTP_4_2_6P3_RC6 + + ntpd/ntpd-opts.texi@1.246.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpd/ntpd.1@1.246.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpdc/ntpdc-opts.c@1.244.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpdc/ntpdc-opts.h@1.244.22.1 +3 -3 + NTP_4_2_6P3_RC6 + + ntpdc/ntpdc-opts.texi@1.243.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpdc/ntpdc.1@1.243.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpq/ntpq-opts.c@1.245.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpq/ntpq-opts.h@1.245.22.1 +3 -3 + NTP_4_2_6P3_RC6 + + ntpq/ntpq-opts.texi@1.244.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpq/ntpq.1@1.244.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.23.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.23.1 +3 -3 + NTP_4_2_6P3_RC6 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.23.1 +2 -2 + NTP_4_2_6P3_RC6 + + ntpsnmpd/ntpsnmpd.1@1.122.23.1 +2 -2 + NTP_4_2_6P3_RC6 + + packageinfo.sh@1.255.24.1 +1 -1 + NTP_4_2_6P3_RC6 + + sntp/sntp-opts.c@1.117.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + sntp/sntp-opts.h@1.117.22.1 +3 -3 + NTP_4_2_6P3_RC6 + + sntp/sntp-opts.texi@1.117.22.1 +1 -1 + NTP_4_2_6P3_RC6 + + sntp/sntp.1@1.117.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + sntp/sntp.html@1.7.22.1 +1 -1 + NTP_4_2_6P3_RC6 + + util/ntp-keygen-opts.c@1.247.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + util/ntp-keygen-opts.h@1.247.22.1 +3 -3 + NTP_4_2_6P3_RC6 + + util/ntp-keygen-opts.texi@1.246.22.1 +2 -2 + NTP_4_2_6P3_RC6 + + util/ntp-keygen.1@1.246.22.1 +2 -2 + NTP_4_2_6P3_RC6 + +ChangeSet@1.2156.17.4, 2010-10-24 06:29:15+00:00, davehart@shiny.ad.hartbrothers.com + revert prior overly-successful merge (ntp-dev and ntp-stable + tos attr_val types differ) + + ntpd/ntp_parser.y@1.62 +1 -1 + revert prior overly-successful merge (ntp-dev and ntp-stable + tos attr_val types differ) + +ChangeSet@1.2082.4.128, 2010-10-24 02:22:00-04:00, stenn@deacon.udel.edu + NEWS file update + + NEWS@1.111 +3 -1 + NEWS file update + +ChangeSet@1.2082.30.5, 2010-10-24 06:21:08+00:00, davehart@shiny.ad.hartbrothers.com + fix bad "tos cohort" backport from -dev + + ntpd/ntp_parser.c@1.52.1.6 +1 -1 + fix bad "tos cohort" backport from -dev + + ntpd/ntp_parser.y@1.47.1.6 +1 -1 + fix bad "tos cohort" backport from -dev + +ChangeSet@1.2082.30.4, 2010-10-24 03:23:09+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1675] Prohibit includefile remote config. + + ChangeLog@1.496.53.1 +4 -0 + [Bug 1675] Prohibit includefile remote config. + + ntpd/ntp_parser.c@1.52.1.5 +939 -1247 + ntp_parser.y Bison output + + ntpd/ntp_parser.y@1.47.1.5 +266 -177 + [Bug 1675] Prohibit includefile remote config. + Collapse duplicated C snippets into common actions. + + ntpd/ntp_scanner.c@1.31.1.2 +4 -1 + [Bug 1675] Prohibit includefile remote config. + +ChangeSet@1.2082.4.126, 2010-10-23 18:59:27+02:00, jnperlin@hydra.localnet + ntp_fp.h: HTONL_MFP() uses ntohl(), should use htonl() (benign error) + + include/ntp_fp.h@1.15.1.1 +16 -16 + HTONL_MFP() uses ntohl(), should use htonl() (benign error) + +ChangeSet@1.2156.17.1, 2010-10-23 10:09:49+00:00, stenn@deacon.udel.edu + NTP_4_2_7P69 + TAG: NTP_4_2_7P69 + + ChangeLog@1.622.7.1 +1 -0 + NTP_4_2_7P69 + + ntpd/ntpd-opts.c@1.72 +2 -2 + NTP_4_2_7P69 + + ntpd/ntpd-opts.h@1.72 +3 -3 + NTP_4_2_7P69 + + ntpd/ntpd-opts.texi@1.71 +2 -2 + NTP_4_2_7P69 + + ntpd/ntpd.1@1.71 +2 -2 + NTP_4_2_7P69 + + ntpdc/ntpdc-opts.c@1.70 +2 -2 + NTP_4_2_7P69 + + ntpdc/ntpdc-opts.h@1.70 +3 -3 + NTP_4_2_7P69 + + ntpdc/ntpdc-opts.texi@1.70 +2 -2 + NTP_4_2_7P69 + + ntpdc/ntpdc.1@1.70 +2 -2 + NTP_4_2_7P69 + + ntpq/ntpq-opts.c@1.70 +2 -2 + NTP_4_2_7P69 + + ntpq/ntpq-opts.h@1.70 +3 -3 + NTP_4_2_7P69 + + ntpq/ntpq-opts.texi@1.70 +2 -2 + NTP_4_2_7P69 + + ntpq/ntpq.1@1.70 +2 -2 + NTP_4_2_7P69 + + ntpsnmpd/ntpsnmpd-opts.c@1.70 +2 -2 + NTP_4_2_7P69 + + ntpsnmpd/ntpsnmpd-opts.h@1.70 +3 -3 + NTP_4_2_7P69 + + ntpsnmpd/ntpsnmpd-opts.texi@1.70 +2 -2 + NTP_4_2_7P69 + + ntpsnmpd/ntpsnmpd.1@1.70 +2 -2 + NTP_4_2_7P69 + + packageinfo.sh@1.71 +1 -1 + NTP_4_2_7P69 + + sntp/sntp-opts.c@1.70 +2 -2 + NTP_4_2_7P69 + + sntp/sntp-opts.h@1.70 +3 -3 + NTP_4_2_7P69 + + sntp/sntp-opts.texi@1.70 +1 -1 + NTP_4_2_7P69 + + sntp/sntp.1@1.70 +2 -2 + NTP_4_2_7P69 + + sntp/sntp.html@1.70 +1 -1 + NTP_4_2_7P69 + + util/ntp-keygen-opts.c@1.67 +2 -2 + NTP_4_2_7P69 + + util/ntp-keygen-opts.h@1.67 +3 -3 + NTP_4_2_7P69 + + util/ntp-keygen-opts.texi@1.70 +2 -2 + NTP_4_2_7P69 + + util/ntp-keygen.1@1.70 +2 -2 + NTP_4_2_7P69 + +ChangeSet@1.2082.4.125, 2010-10-23 03:07:11+02:00, jnperlin@hydra.localnet + polish to NMEA driver + + ntpd/refclock_nmea.c@1.46.1.7 +55 -53 + formatting issues + +ChangeSet@1.2082.4.124, 2010-10-23 02:24:08+02:00, jnperlin@hydra.localnet + final update for [Bug 1571] and [Bug 1572] + + ChangeLog@1.496.26.92 +5 -0 + [Bug 1571] NMEA does not relate data to PPS edge + [Bug 1572] NMEA time adjustment for GPZDG buggy + + ntpd/refclock_nmea.c@1.46.1.6 +0 -10 + removed tag for temporary version + +ChangeSet@1.2082.25.2, 2010-10-23 01:48:37+02:00, jnperlin@hydra.localnet + nmea calendar cleanup + + ntpd/refclock_nmea.c@1.46.3.1 +16 -40 + calendar cleanup + +ChangeSet@1.2156.1.127, 2010-10-22 23:13:04+00:00, hart@malarky.udel.edu + correct POSIX file permissions in ports/winnt + + ports/winnt/libntp/MSG00001.bin@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/libntp/getclock.c@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/libntp/messages.h@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/libntp/messages.rc@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/libntp/setpriority.c@1.4 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/ntpd/ntservice.c@1.24 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.c@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.def@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.h@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.sln@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.vcproj@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/ppsapi/skelprov/sys/time.h@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/instsrv/instsrv.vcproj@1.5 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/libntp/libntp.vcproj@1.29 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.10 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/ntp.sln@1.9 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/ntpd/gen-ntp_keyword.bat@1.2 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.32 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.13 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.13 +0 -0 + Change mode to -rw-rw-r-- + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.12 +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.2156.1.126, 2010-10-22 21:26:52+00:00, davehart@shiny.ad.hartbrothers.com + Enable generating ntpd/ntp_keyword.h after ntpd/keyword-gen.c changes + on Windows as well as POSIX platforms. + + ChangeLog@1.622.1.75 +2 -0 + Enable generating ntpd/ntp_keyword.h after ntpd/keyword-gen.c changes + on Windows as well as POSIX platforms. + + ntpd/keyword-gen.c@1.15 +33 -32 + use u_short instead of int for token/state vars. + + ports/winnt/vs2008/ntp.sln@1.8 +14 -4 + add ntpd-keyword-gen project to generate ntpd/ntp_keyword.h on Windows + using ntpd/keyword-gen.c. + + ports/winnt/vs2008/ntpd-keyword-gen/ntpd-keyword-gen.vcproj@1.1 +263 -0 + BitKeeper file C:/ntp/ntp-dev-win-keyword/ports/winnt/vs2008/ntpd-keyword-gen/ntpd-keyword-gen.vcproj + + ports/winnt/vs2008/ntpd-keyword-gen/ntpd-keyword-gen.vcproj@1.0 +0 -0 + + ports/winnt/vs2008/ntpd/gen-ntp_keyword.bat@1.1 +39 -0 + BitKeeper file C:/ntp/ntp-dev-win-keyword/ports/winnt/vs2008/ntpd/gen-ntp_keyword.bat + + ports/winnt/vs2008/ntpd/gen-ntp_keyword.bat@1.0 +0 -0 + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.31 +28 -5 + Add custom build rule for ntp_keyword.h invoking keyword-gen.exe + +ChangeSet@1.2156.1.125, 2010-10-22 14:57:46-04:00, stenn@deacon.udel.edu + [Bug 1671] Audoomatic delay calibration is sometimes inaccurate + + ChangeLog@1.622.1.74 +1 -0 + [Bug 1671] Audoomatic delay calibration is sometimes inaccurate + + ntpd/ntp_loopfilter.c@1.159 +1 -1 + [Bug 1671] Audoomatic delay calibration is sometimes inaccurate + + ntpd/ntp_proto.c@1.309 +1 -1 + [Bug 1671] Audoomatic delay calibration is sometimes inaccurate + +ChangeSet@1.2156.1.124, 2010-10-22 08:31:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P68 + TAG: NTP_4_2_7P68 + + ChangeLog@1.622.1.73 +1 -0 + NTP_4_2_7P68 + + ntpd/ntpd-opts.c@1.71 +2 -2 + NTP_4_2_7P68 + + ntpd/ntpd-opts.h@1.71 +3 -3 + NTP_4_2_7P68 + + ntpd/ntpd-opts.texi@1.70 +2 -2 + NTP_4_2_7P68 + + ntpd/ntpd.1@1.70 +2 -2 + NTP_4_2_7P68 + + ntpdc/ntpdc-opts.c@1.69 +2 -2 + NTP_4_2_7P68 + + ntpdc/ntpdc-opts.h@1.69 +3 -3 + NTP_4_2_7P68 + + ntpdc/ntpdc-opts.texi@1.69 +2 -2 + NTP_4_2_7P68 + + ntpdc/ntpdc.1@1.69 +2 -2 + NTP_4_2_7P68 + + ntpq/ntpq-opts.c@1.69 +2 -2 + NTP_4_2_7P68 + + ntpq/ntpq-opts.h@1.69 +3 -3 + NTP_4_2_7P68 + + ntpq/ntpq-opts.texi@1.69 +2 -2 + NTP_4_2_7P68 + + ntpq/ntpq.1@1.69 +2 -2 + NTP_4_2_7P68 + + ntpsnmpd/ntpsnmpd-opts.c@1.69 +2 -2 + NTP_4_2_7P68 + + ntpsnmpd/ntpsnmpd-opts.h@1.69 +3 -3 + NTP_4_2_7P68 + + ntpsnmpd/ntpsnmpd-opts.texi@1.69 +2 -2 + NTP_4_2_7P68 + + ntpsnmpd/ntpsnmpd.1@1.69 +2 -2 + NTP_4_2_7P68 + + packageinfo.sh@1.70 +1 -1 + NTP_4_2_7P68 + + sntp/sntp-opts.c@1.69 +2 -2 + NTP_4_2_7P68 + + sntp/sntp-opts.h@1.69 +3 -3 + NTP_4_2_7P68 + + sntp/sntp-opts.texi@1.69 +1 -1 + NTP_4_2_7P68 + + sntp/sntp.1@1.69 +2 -2 + NTP_4_2_7P68 + + sntp/sntp.html@1.69 +1 -1 + NTP_4_2_7P68 + + util/ntp-keygen-opts.c@1.66 +2 -2 + NTP_4_2_7P68 + + util/ntp-keygen-opts.h@1.66 +3 -3 + NTP_4_2_7P68 + + util/ntp-keygen-opts.texi@1.69 +2 -2 + NTP_4_2_7P68 + + util/ntp-keygen.1@1.69 +2 -2 + NTP_4_2_7P68 + +ChangeSet@1.2082.30.3, 2010-10-22 07:46:08+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC5 + TAG: NTP_4_2_6P3_RC5 + + ChangeLog@1.496.26.91 +1 -0 + NTP_4_2_6P3_RC5 + + ntpd/ntpd-opts.c@1.248.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpd/ntpd-opts.h@1.248.21.1 +3 -3 + NTP_4_2_6P3_RC5 + + ntpd/ntpd-opts.texi@1.246.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpd/ntpd.1@1.246.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpdc/ntpdc-opts.c@1.244.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpdc/ntpdc-opts.h@1.244.21.1 +3 -3 + NTP_4_2_6P3_RC5 + + ntpdc/ntpdc-opts.texi@1.243.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpdc/ntpdc.1@1.243.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpq/ntpq-opts.c@1.245.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpq/ntpq-opts.h@1.245.21.1 +3 -3 + NTP_4_2_6P3_RC5 + + ntpq/ntpq-opts.texi@1.244.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpq/ntpq.1@1.244.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.22.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.22.1 +3 -3 + NTP_4_2_6P3_RC5 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.22.1 +2 -2 + NTP_4_2_6P3_RC5 + + ntpsnmpd/ntpsnmpd.1@1.122.22.1 +2 -2 + NTP_4_2_6P3_RC5 + + packageinfo.sh@1.255.23.1 +1 -1 + NTP_4_2_6P3_RC5 + + sntp/sntp-opts.c@1.117.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + sntp/sntp-opts.h@1.117.21.1 +3 -3 + NTP_4_2_6P3_RC5 + + sntp/sntp-opts.texi@1.117.21.1 +1 -1 + NTP_4_2_6P3_RC5 + + sntp/sntp.1@1.117.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + sntp/sntp.html@1.7.21.1 +1 -1 + NTP_4_2_6P3_RC5 + + util/ntp-keygen-opts.c@1.247.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + util/ntp-keygen-opts.h@1.247.21.1 +3 -3 + NTP_4_2_6P3_RC5 + + util/ntp-keygen-opts.texi@1.246.21.1 +2 -2 + NTP_4_2_6P3_RC5 + + util/ntp-keygen.1@1.246.21.1 +2 -2 + NTP_4_2_6P3_RC5 + +ChangeSet@1.2156.1.122, 2010-10-22 02:02:49-04:00, stenn@deacon.udel.edu + Documentation cleanup + + BitKeeper/deleted/.del-manyopt.htm~8bee686d28f0c2b7@1.24 +0 -0 + Delete: html/manyopt.html + +ChangeSet@1.2156.1.121, 2010-10-22 01:56:16-04:00, stenn@deacon.udel.edu + [Bug 1670] Fix peer->bias and broadcastdelay + + ChangeLog@1.622.1.71 +1 -0 + [Bug 1670] Fix peer->bias and broadcastdelay + + html/miscopt.html@1.60 +4 -3 + [Bug 1670] Fix peer->bias and broadcastdelay + + include/ntp.h@1.183 +1 -1 + [Bug 1670] Fix peer->bias and broadcastdelay + + ntpd/ntp_proto.c@1.308 +2 -5 + [Bug 1670] Fix peer->bias and broadcastdelay + +ChangeSet@1.2156.1.120, 2010-10-21 23:57:11-04:00, stenn@deacon.udel.edu + Documentation EOL cleanup + + ChangeLog@1.622.1.70 +1 -0 + Documentation EOL cleanup + + html/config.html@1.24 +1 -1 + Documentation EOL cleanup + + html/drivers/driver16.html@1.12 +1 -1 + Documentation EOL cleanup + + html/drivers/driver2.html@1.13 +1 -1 + Documentation EOL cleanup + + html/drivers/driver27.html@1.16 +1 -1 + Documentation EOL cleanup + + html/drivers/driver29.html@1.16 +1 -1 + Documentation EOL cleanup + + html/drivers/driver30.html@1.20 +1 -1 + Documentation EOL cleanup + + html/drivers/driver31.html@1.3 +1 -1 + Documentation EOL cleanup + + html/drivers/driver32.html@1.13 +1 -1 + Documentation EOL cleanup + + html/drivers/driver33.html@1.13 +1 -1 + Documentation EOL cleanup + + html/drivers/driver35.html@1.15 +1 -1 + Documentation EOL cleanup + + html/drivers/driver37.html@1.13 +1 -1 + Documentation EOL cleanup + + html/drivers/driver38.html@1.15 +1 -1 + Documentation EOL cleanup + + html/drivers/driver39.html@1.14 +1 -1 + Documentation EOL cleanup + + html/drivers/driver42.html@1.13 +1 -1 + Documentation EOL cleanup + + html/drivers/driver43.html@1.11 +1 -1 + Documentation EOL cleanup + + html/drivers/driver44.html@1.14 +1 -1 + Documentation EOL cleanup + + html/drivers/driver5.html@1.14 +1 -1 + Documentation EOL cleanup + + html/drivers/driver9.html@1.15 +1 -1 + Documentation EOL cleanup + + html/drivers/mx4200data.html@1.2 +1 -1 + Documentation EOL cleanup + + html/drivers/oncore-shmem.html@1.13 +1 -1 + Documentation EOL cleanup + + html/drivers/scripts/footer.txt@1.2 +1 -1 + Documentation EOL cleanup + + html/drivers/scripts/style.css@1.2 +1 -1 + Documentation EOL cleanup + + html/drivers/tf582_4.html@1.3 +1 -1 + Documentation EOL cleanup + + html/hints/sco.html@1.11 +1 -1 + Documentation EOL cleanup + + html/hints/vxworks.html@1.10 +1 -1 + Documentation EOL cleanup + + html/parsedata.html@1.13 +1 -1 + Documentation EOL cleanup + + html/scripts/accopt.txt@1.3 +1 -1 + Documentation EOL cleanup + + html/scripts/audio.txt@1.3 +1 -1 + Documentation EOL cleanup + + html/scripts/authopt.txt@1.4 +1 -1 + Documentation EOL cleanup + + html/scripts/clockopt.txt@1.3 +1 -1 + Documentation EOL cleanup + + html/scripts/command.txt@1.4 +1 -1 + Documentation EOL cleanup + + html/scripts/confopt.txt@1.4 +1 -1 + Documentation EOL cleanup + + html/scripts/external.txt@1.4 +1 -1 + Documentation EOL cleanup + + html/scripts/footer.txt@1.3 +1 -1 + Documentation EOL cleanup + + html/scripts/hand.txt@1.2 +1 -1 + Documentation EOL cleanup + + html/scripts/install.txt@1.4 +1 -1 + Documentation EOL cleanup + + html/scripts/manual.txt@1.4 +1 -1 + Documentation EOL cleanup + + html/scripts/misc.txt@1.3 +1 -1 + Documentation EOL cleanup + + html/scripts/miscopt.txt@1.7 +1 -1 + Documentation EOL cleanup + + html/scripts/monopt.txt@1.3 +1 -1 + Documentation EOL cleanup + + html/scripts/refclock.txt@1.3 +1 -1 + Documentation EOL cleanup + + html/scripts/special.txt@1.6 +1 -1 + Documentation EOL cleanup + + html/scripts/style.css@1.3 +1 -1 + Documentation EOL cleanup + +ChangeSet@1.2156.1.119, 2010-10-21 23:42:06-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.69 +1 -0 + Documentation updates from Dave Mills + + html/build.html@1.25 +1 -1 + Documentation updates from Dave Mills + + html/drivers/driver1.html@1.18 +5 -5 + Documentation updates from Dave Mills + + html/scripts/config.txt@1.4 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2082.31.1, 2010-10-22 00:33:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1669] NTP 4.2.6p2 fails to compile on IBM AIX 5.3. + + ChangeLog@1.496.52.1 +4 -0 + [Bug 1669] NTP 4.2.6p2 fails to compile on IBM AIX 5.3. + + ntpd/ntp_util.c@1.75.1.2 +9 -8 + [Bug 1669] NTP 4.2.6p2 fails to compile on IBM AIX 5.3. + +ChangeSet@1.2156.1.117, 2010-10-21 10:10:05+00:00, stenn@deacon.udel.edu + NTP_4_2_7P67 + TAG: NTP_4_2_7P67 + + ChangeLog@1.622.1.67 +1 -0 + NTP_4_2_7P67 + + ntpd/ntpd-opts.c@1.70 +2 -2 + NTP_4_2_7P67 + + ntpd/ntpd-opts.h@1.70 +3 -3 + NTP_4_2_7P67 + + ntpd/ntpd-opts.texi@1.69 +2 -2 + NTP_4_2_7P67 + + ntpd/ntpd.1@1.69 +2 -2 + NTP_4_2_7P67 + + ntpdc/ntpdc-opts.c@1.68 +2 -2 + NTP_4_2_7P67 + + ntpdc/ntpdc-opts.h@1.68 +3 -3 + NTP_4_2_7P67 + + ntpdc/ntpdc-opts.texi@1.68 +2 -2 + NTP_4_2_7P67 + + ntpdc/ntpdc.1@1.68 +2 -2 + NTP_4_2_7P67 + + ntpq/ntpq-opts.c@1.68 +2 -2 + NTP_4_2_7P67 + + ntpq/ntpq-opts.h@1.68 +3 -3 + NTP_4_2_7P67 + + ntpq/ntpq-opts.texi@1.68 +2 -2 + NTP_4_2_7P67 + + ntpq/ntpq.1@1.68 +2 -2 + NTP_4_2_7P67 + + ntpsnmpd/ntpsnmpd-opts.c@1.68 +2 -2 + NTP_4_2_7P67 + + ntpsnmpd/ntpsnmpd-opts.h@1.68 +3 -3 + NTP_4_2_7P67 + + ntpsnmpd/ntpsnmpd-opts.texi@1.68 +2 -2 + NTP_4_2_7P67 + + ntpsnmpd/ntpsnmpd.1@1.68 +2 -2 + NTP_4_2_7P67 + + packageinfo.sh@1.69 +1 -1 + NTP_4_2_7P67 + + sntp/sntp-opts.c@1.68 +2 -2 + NTP_4_2_7P67 + + sntp/sntp-opts.h@1.68 +3 -3 + NTP_4_2_7P67 + + sntp/sntp-opts.texi@1.68 +1 -1 + NTP_4_2_7P67 + + sntp/sntp.1@1.68 +2 -2 + NTP_4_2_7P67 + + sntp/sntp.html@1.68 +1 -1 + NTP_4_2_7P67 + + util/ntp-keygen-opts.c@1.65 +2 -2 + NTP_4_2_7P67 + + util/ntp-keygen-opts.h@1.65 +3 -3 + NTP_4_2_7P67 + + util/ntp-keygen-opts.texi@1.68 +2 -2 + NTP_4_2_7P67 + + util/ntp-keygen.1@1.68 +2 -2 + NTP_4_2_7P67 + +ChangeSet@1.2156.1.116, 2010-10-19 21:30:15+00:00, davehart@shiny.ad.hartbrothers.com + Exclude keyword-gen.c and ntp_parser.y from release as well as + debug Windows builds. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.30 +16 -0 + Exclude keyword-gen.c and ntp_parser.y from release as well as + debug Windows builds. + +ChangeSet@1.2082.30.1, 2010-10-19 21:10:14+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1649] Require NMEA checksum if $GPRMC or previously seen. + + ChangeLog@1.496.26.89 +4 -0 + [Bug 1649] Require NMEA checksum if $GPRMC or previously seen. + + ntpd/refclock_nmea.c@1.46.2.1 +104 -56 + [Bug 1649] Require NMEA checksum if $GPRMC or previously seen. + +ChangeSet@1.2156.1.114, 2010-10-19 10:10:23+00:00, stenn@deacon.udel.edu + NTP_4_2_7P66 + TAG: NTP_4_2_7P66 + + ChangeLog@1.622.1.65 +1 -0 + NTP_4_2_7P66 + + ntpd/ntpd-opts.c@1.69 +2 -2 + NTP_4_2_7P66 + + ntpd/ntpd-opts.h@1.69 +3 -3 + NTP_4_2_7P66 + + ntpd/ntpd-opts.texi@1.68 +2 -2 + NTP_4_2_7P66 + + ntpd/ntpd.1@1.68 +2 -2 + NTP_4_2_7P66 + + ntpdc/ntpdc-opts.c@1.67 +2 -2 + NTP_4_2_7P66 + + ntpdc/ntpdc-opts.h@1.67 +3 -3 + NTP_4_2_7P66 + + ntpdc/ntpdc-opts.texi@1.67 +2 -2 + NTP_4_2_7P66 + + ntpdc/ntpdc.1@1.67 +2 -2 + NTP_4_2_7P66 + + ntpq/ntpq-opts.c@1.67 +2 -2 + NTP_4_2_7P66 + + ntpq/ntpq-opts.h@1.67 +3 -3 + NTP_4_2_7P66 + + ntpq/ntpq-opts.texi@1.67 +2 -2 + NTP_4_2_7P66 + + ntpq/ntpq.1@1.67 +2 -2 + NTP_4_2_7P66 + + ntpsnmpd/ntpsnmpd-opts.c@1.67 +2 -2 + NTP_4_2_7P66 + + ntpsnmpd/ntpsnmpd-opts.h@1.67 +3 -3 + NTP_4_2_7P66 + + ntpsnmpd/ntpsnmpd-opts.texi@1.67 +2 -2 + NTP_4_2_7P66 + + ntpsnmpd/ntpsnmpd.1@1.67 +2 -2 + NTP_4_2_7P66 + + packageinfo.sh@1.68 +1 -1 + NTP_4_2_7P66 + + sntp/sntp-opts.c@1.67 +2 -2 + NTP_4_2_7P66 + + sntp/sntp-opts.h@1.67 +3 -3 + NTP_4_2_7P66 + + sntp/sntp-opts.texi@1.67 +1 -1 + NTP_4_2_7P66 + + sntp/sntp.1@1.67 +2 -2 + NTP_4_2_7P66 + + sntp/sntp.html@1.67 +1 -1 + NTP_4_2_7P66 + + util/ntp-keygen-opts.c@1.64 +2 -2 + NTP_4_2_7P66 + + util/ntp-keygen-opts.h@1.64 +3 -3 + NTP_4_2_7P66 + + util/ntp-keygen-opts.texi@1.67 +2 -2 + NTP_4_2_7P66 + + util/ntp-keygen.1@1.67 +2 -2 + NTP_4_2_7P66 + +ChangeSet@1.2156.1.113, 2010-10-18 20:15:32-04:00, stenn@deacon.udel.edu + ChangeLog: + * [Bug 1277] Provide and use O(1) FIFOs, esp. in the config tree code. + * Remove unused 'bias' configuration keyword. + + ChangeLog@1.622.1.64 +2 -0 + * [Bug 1277] Provide and use O(1) FIFOs, esp. in the config tree code. + * Remove unused 'bias' configuration keyword. + +ChangeSet@1.2156.1.112, 2010-10-18 15:42:39+00:00, davehart@shiny.ad.hartbrothers.com + quiet ntpdsim build warnings about unused funcs, + + include/ntpd.h@1.142 +1 -2 + quiet ntpdsim build warnings about unused funcs, + + libntp/emalloc.c@1.13 +2 -0 + warning pointed out bug + + ntpd/ntp_config.c@1.269 +57 -33 + quiet ntpdsim build warnings about unused funcs, + + ntpd/ntp_scanner.h@1.17 +2 -0 + quiet ntpdsim build warnings about unused funcs, + + ntpd/ntpsim.c@1.28 +1 -1 + do the header shuffle + +ChangeSet@1.2156.1.111, 2010-10-18 14:49:33+00:00, davehart@shiny.ad.hartbrothers.com + merge cleanup, simulator fixes, generated files from previous merge. + + ntpd/keyword-gen-utd@1.11 +1 -1 + generated from previously merged source + + ntpd/ntp_keyword.h@1.13 +705 -709 + generated from previously merged source + + ntpd/ntp_parser.c@1.66 +1298 -1173 + generated from previously merged source + + ntpd/ntp_parser.h@1.40 +133 -132 + generated from previously merged source + + ntpd/ntp_parser.y@1.59 +6 -3 + merge cleanup, simulator fix + + ntpd/ntpsim.c@1.27 +5 -5 + correct config tree walking in simulator + +ChangeSet@1.2156.16.1, 2010-10-18 13:35:09+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + include/Makefile.am@1.40 +1 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build + + include/ntp_config.h@1.69 +204 -125 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + include/ntp_lists.h@1.8 +142 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Add FIFO (A.K.A. STAILQ) macros. + + include/ntp_prio_q.h@1.7.1.2 +6 -7 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build + + include/ntp_prio_q.h@1.7.1.1 +0 -0 + Rename: include/ntp_data_structures.h -> include/ntp_prio_q.h + + include/ntp_stdlib.h@1.47 +5 -3 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + add emalloc_zero() + + include/ntpd.h@1.141 +2 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + include/ntpsim.h@1.15 +22 -17 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + libntp/emalloc.c@1.12 +20 -3 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + add emalloc_zero() + + libntp/ntp_rfc2553.c@1.43 +2 -2 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + add emalloc_zero() + + ntpd/Makefile.am@1.94 +1 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build + + ntpd/complete.conf@1.9 +1 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Remove unused "bias" server option + + ntpd/keyword-gen-utd@1.7.1.1 +1 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Remove unused "bias" server option + + ntpd/keyword-gen.c@1.12.1.1 +0 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Remove unused "bias" server option + + ntpd/ntp_config.c@1.263.1.1 +1008 -1074 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + ntpd/ntp_filegen.c@1.17.1.1 +1 -1 + whitespace only + + ntpd/ntp_keyword.h@1.9.1.1 +713 -717 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Remove unused "bias" server option + + ntpd/ntp_parser.c@1.59.1.1 +1508 -1373 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + ntpd/ntp_parser.h@1.37.1.1 +139 -139 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + ntpd/ntp_parser.y@1.54.1.1 +483 -263 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + ntpd/ntp_prio_q.c@1.12.1.2 +5 -5 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build + + ntpd/ntp_prio_q.c@1.12.1.1 +0 -0 + Rename: ntpd/ntp_data_structures.c -> ntpd/ntp_prio_q.c + + ntpd/ntp_scanner.h@1.16 +1 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + ntpd/ntp_util.c@1.82.1.1 +1 -1 + whitespace only + + ntpd/ntpsim.c@1.24.1.1 +0 -1 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + + ports/winnt/vc6/ntpd.dsp@1.47.1.1 +0 -4 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build. + + ports/winnt/vs2003/ntpd.vcproj@1.8.1.1 +0 -22 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build. + + ports/winnt/vs2005/ntpd.vcproj@1.8.1.1 +0 -22 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.27.1.1 +24 -8 + [Bug 1277] provide, use O(1) FIFOs, esp. config tree. + Rename ntp_data_structures.[ch] to ntp_prio_q.[ch], use + them only in the simulator build. + +ChangeSet@1.2156.1.109, 2010-10-16 05:20:17+00:00, stenn@deacon.udel.edu + NTP_4_2_7P65 + TAG: NTP_4_2_7P65 + + ChangeLog@1.622.1.63 +1 -0 + NTP_4_2_7P65 + + ntpd/ntpd-opts.c@1.68 +2 -2 + NTP_4_2_7P65 + + ntpd/ntpd-opts.h@1.68 +3 -3 + NTP_4_2_7P65 + + ntpd/ntpd-opts.texi@1.67 +2 -2 + NTP_4_2_7P65 + + ntpd/ntpd.1@1.67 +2 -2 + NTP_4_2_7P65 + + ntpdc/ntpdc-opts.c@1.66 +2 -2 + NTP_4_2_7P65 + + ntpdc/ntpdc-opts.h@1.66 +3 -3 + NTP_4_2_7P65 + + ntpdc/ntpdc-opts.texi@1.66 +2 -2 + NTP_4_2_7P65 + + ntpdc/ntpdc.1@1.66 +2 -2 + NTP_4_2_7P65 + + ntpq/ntpq-opts.c@1.66 +2 -2 + NTP_4_2_7P65 + + ntpq/ntpq-opts.h@1.66 +3 -3 + NTP_4_2_7P65 + + ntpq/ntpq-opts.texi@1.66 +2 -2 + NTP_4_2_7P65 + + ntpq/ntpq.1@1.66 +2 -2 + NTP_4_2_7P65 + + ntpsnmpd/ntpsnmpd-opts.c@1.66 +2 -2 + NTP_4_2_7P65 + + ntpsnmpd/ntpsnmpd-opts.h@1.66 +3 -3 + NTP_4_2_7P65 + + ntpsnmpd/ntpsnmpd-opts.texi@1.66 +2 -2 + NTP_4_2_7P65 + + ntpsnmpd/ntpsnmpd.1@1.66 +2 -2 + NTP_4_2_7P65 + + packageinfo.sh@1.67 +1 -1 + NTP_4_2_7P65 + + sntp/sntp-opts.c@1.66 +2 -2 + NTP_4_2_7P65 + + sntp/sntp-opts.h@1.66 +3 -3 + NTP_4_2_7P65 + + sntp/sntp-opts.texi@1.66 +1 -1 + NTP_4_2_7P65 + + sntp/sntp.1@1.66 +2 -2 + NTP_4_2_7P65 + + sntp/sntp.html@1.66 +1 -1 + NTP_4_2_7P65 + + util/ntp-keygen-opts.c@1.63 +2 -2 + NTP_4_2_7P65 + + util/ntp-keygen-opts.h@1.63 +3 -3 + NTP_4_2_7P65 + + util/ntp-keygen-opts.texi@1.66 +2 -2 + NTP_4_2_7P65 + + util/ntp-keygen.1@1.66 +2 -2 + NTP_4_2_7P65 + +ChangeSet@1.2082.4.120, 2010-10-16 04:24:10+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC4 + TAG: NTP_4_2_6P3_RC4 + + ChangeLog@1.496.26.88 +1 -0 + NTP_4_2_6P3_RC4 + + ntpd/ntpd-opts.c@1.248.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpd/ntpd-opts.h@1.248.20.1 +3 -3 + NTP_4_2_6P3_RC4 + + ntpd/ntpd-opts.texi@1.246.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpd/ntpd.1@1.246.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpdc/ntpdc-opts.c@1.244.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpdc/ntpdc-opts.h@1.244.20.1 +3 -3 + NTP_4_2_6P3_RC4 + + ntpdc/ntpdc-opts.texi@1.243.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpdc/ntpdc.1@1.243.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpq/ntpq-opts.c@1.245.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpq/ntpq-opts.h@1.245.20.1 +3 -3 + NTP_4_2_6P3_RC4 + + ntpq/ntpq-opts.texi@1.244.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpq/ntpq.1@1.244.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.21.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.21.1 +3 -3 + NTP_4_2_6P3_RC4 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.21.1 +2 -2 + NTP_4_2_6P3_RC4 + + ntpsnmpd/ntpsnmpd.1@1.122.21.1 +2 -2 + NTP_4_2_6P3_RC4 + + packageinfo.sh@1.255.22.1 +1 -1 + NTP_4_2_6P3_RC4 + + sntp/sntp-opts.c@1.117.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + sntp/sntp-opts.h@1.117.20.1 +3 -3 + NTP_4_2_6P3_RC4 + + sntp/sntp-opts.texi@1.117.20.1 +1 -1 + NTP_4_2_6P3_RC4 + + sntp/sntp.1@1.117.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + sntp/sntp.html@1.7.20.1 +1 -1 + NTP_4_2_6P3_RC4 + + util/ntp-keygen-opts.c@1.247.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + util/ntp-keygen-opts.h@1.247.20.1 +3 -3 + NTP_4_2_6P3_RC4 + + util/ntp-keygen-opts.texi@1.246.20.1 +2 -2 + NTP_4_2_6P3_RC4 + + util/ntp-keygen.1@1.246.20.1 +2 -2 + NTP_4_2_6P3_RC4 + +ChangeSet@1.2082.29.1, 2010-10-16 04:02:17+00:00, davehart@shiny.ad.hartbrothers.com + min/max confusion in ntpsnmpd change + + ntpsnmpd/ntpSnmpSubagentObject.c@1.3.1.3 +4 -1 + min/max confusion + +ChangeSet@1.2082.4.118, 2010-10-15 23:52:31-04:00, stenn@deacon.udel.edu + Update NEWS to 4.2.6p3-RC4 + + NEWS@1.110 +7 -0 + Update to 4.2.6p3-RC4 + +ChangeSet@1.2156.1.106, 2010-10-16 01:18:29+00:00, davehart@shiny.ad.hartbrothers.com + Remove 'calldelay' and 'sign' remnants from parser, ntp_config.c. + + ChangeLog@1.622.1.61 +1 -0 + Remove 'calldelay' and 'sign' remnants from parser, ntp_config.c. + + ntpd/keyword-gen-utd@1.9 +1 -1 + cascade from ntp_parser.h update + + ntpd/ntp_config.c@1.267 +0 -4 + Remove 'calldelay' and 'sign' remnants from parser, ntp_config.c. + + ntpd/ntp_keyword.h@1.11 +460 -462 + cascade from ntp_parser.h update + + ntpd/ntp_parser.c@1.64 +1308 -1334 + Bison output fromm ntp_parser.y + + ntpd/ntp_parser.h@1.38 +320 -325 + Bison output fromm ntp_parser.y + + ntpd/ntp_parser.y@1.57 +0 -6 + Remove 'calldelay' and 'sign' remnants from parser, ntp_config.c. + +ChangeSet@1.2082.4.117, 2010-10-16 00:40:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1584] wrong SNMP type for precision, resolution. + + ChangeLog@1.496.26.87 +1 -0 + [Bug 1584] wrong SNMP type for precision, resolution. + + ntpsnmpd/ntpSnmpSubagentObject.c@1.3.1.2 +160 -130 + Correct ASN type for ntp_EntTimeResolution and ntp_EntTimePrecision. + Use precision as best guess for unavailable resolution. + + ntpsnmpd/ntpSnmpSubagentObject.h@1.4 +6 -6 + const fun + +ChangeSet@1.2156.1.104, 2010-10-15 07:18:13+00:00, stenn@deacon.udel.edu + NTP_4_2_7P64 + TAG: NTP_4_2_7P64 + + ChangeLog@1.622.1.59 +1 -0 + NTP_4_2_7P64 + + ntpd/ntpd-opts.c@1.67 +2 -2 + NTP_4_2_7P64 + + ntpd/ntpd-opts.h@1.67 +3 -3 + NTP_4_2_7P64 + + ntpd/ntpd-opts.texi@1.66 +2 -2 + NTP_4_2_7P64 + + ntpd/ntpd.1@1.66 +2 -2 + NTP_4_2_7P64 + + ntpdc/ntpdc-opts.c@1.65 +2 -2 + NTP_4_2_7P64 + + ntpdc/ntpdc-opts.h@1.65 +3 -3 + NTP_4_2_7P64 + + ntpdc/ntpdc-opts.texi@1.65 +2 -2 + NTP_4_2_7P64 + + ntpdc/ntpdc.1@1.65 +2 -2 + NTP_4_2_7P64 + + ntpq/ntpq-opts.c@1.65 +2 -2 + NTP_4_2_7P64 + + ntpq/ntpq-opts.h@1.65 +3 -3 + NTP_4_2_7P64 + + ntpq/ntpq-opts.texi@1.65 +2 -2 + NTP_4_2_7P64 + + ntpq/ntpq.1@1.65 +2 -2 + NTP_4_2_7P64 + + ntpsnmpd/ntpsnmpd-opts.c@1.65 +2 -2 + NTP_4_2_7P64 + + ntpsnmpd/ntpsnmpd-opts.h@1.65 +3 -3 + NTP_4_2_7P64 + + ntpsnmpd/ntpsnmpd-opts.texi@1.65 +2 -2 + NTP_4_2_7P64 + + ntpsnmpd/ntpsnmpd.1@1.65 +2 -2 + NTP_4_2_7P64 + + packageinfo.sh@1.66 +1 -1 + NTP_4_2_7P64 + + sntp/sntp-opts.c@1.65 +2 -2 + NTP_4_2_7P64 + + sntp/sntp-opts.h@1.65 +3 -3 + NTP_4_2_7P64 + + sntp/sntp-opts.texi@1.65 +1 -1 + NTP_4_2_7P64 + + sntp/sntp.1@1.65 +2 -2 + NTP_4_2_7P64 + + sntp/sntp.html@1.65 +1 -1 + NTP_4_2_7P64 + + util/ntp-keygen-opts.c@1.62 +2 -2 + NTP_4_2_7P64 + + util/ntp-keygen-opts.h@1.62 +3 -3 + NTP_4_2_7P64 + + util/ntp-keygen-opts.texi@1.65 +2 -2 + NTP_4_2_7P64 + + util/ntp-keygen.1@1.65 +2 -2 + NTP_4_2_7P64 + +ChangeSet@1.2156.1.103, 2010-10-15 03:00:04-04:00, stenn@deacon.udel.edu + typo cleanup + + ChangeLog@1.622.1.58 +2 -2 + typo cleanup + +ChangeSet@1.2156.1.102, 2010-10-15 02:56:35-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/authopt.html@1.65 +4 -4 + Documentation updates from Dave Mills + + html/confopt.html@1.53 +9 -9 + Documentation updates from Dave Mills + + html/decode.html@1.17 +15 -15 + Documentation updates from Dave Mills + + html/drivers/driver16.html@1.11 +24 -24 + Documentation updates from Dave Mills + + html/drivers/driver2.html@1.12 +50 -50 + Documentation updates from Dave Mills + + html/drivers/driver5.html@1.13 +65 -65 + Documentation updates from Dave Mills + + html/pic/fig_3_1.gif@1.2 +232 -527 + Documentation updates from Dave Mills + + html/warp.html@1.12 +3 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.101, 2010-10-15 02:24:55-04:00, stenn@deacon.udel.edu + Remove 'calldelay' and 'sign' keywords (Dave Mills) + + ChangeLog@1.622.1.57 +1 -0 + Remove 'calldelay' and 'sign' keywords (Dave Mills) + + include/ntp_crypto.h@1.50 +3 -4 + Remove 'calldelay' and 'sign' keywords (Dave Mills) + + ntpd/ntp_config.c@1.266 +1 -5 + Remove 'calldelay' and 'sign' keywords (Dave Mills) + +ChangeSet@1.2156.1.100, 2010-10-15 01:56:16+00:00, davehart@shiny.ad.hartbrothers.com + removed unused "calldelay" and "sign" tokens from keyword + scanner, yet to be removed from parser once DLM's update + to ntp_config.c is integrated. + + ntpd/keyword-gen-utd@1.8 +1 -1 + removed unused "calldelay" and "sign" tokens from keyword + scanner, yet to be removed from parser once DLM's update + to ntp_config.c is integrated. + + ntpd/keyword-gen.c@1.13 +0 -2 + removed unused "calldelay" and "sign" tokens from keyword + scanner, yet to be removed from parser once DLM's update + to ntp_config.c is integrated. + + ntpd/ntp_keyword.h@1.10 +571 -579 + removed unused "calldelay" and "sign" tokens from keyword + scanner, yet to be removed from parser once DLM's update + to ntp_config.c is integrated. + +ChangeSet@1.2156.1.99, 2010-10-15 00:23:01+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1663] ntpdsim should not open net sockets. + + ChangeLog@1.622.1.56 +1 -0 + [Bug 1663] ntpdsim should not open net sockets. + + include/ntp_data_structures.h@1.8 +13 -9 + [Bug 1663] ntpdsim should not open net sockets. + + ntpd/ntp_data_structures.c@1.13 +4 -6 + [Bug 1663] ntpdsim should not open net sockets. + + ntpd/ntp_io.c@1.323 +4 -4 + [Bug 1663] ntpdsim should not open net sockets. + + ntpd/ntp_timer.c@1.61 +2 -2 + [Bug 1663] ntpdsim should not open net sockets. + + ntpd/ntpsim.c@1.25 +102 -89 + [Bug 1663] ntpdsim should not open net sockets. + +ChangeSet@1.2082.4.116, 2010-10-14 19:13:29+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1659] Need CLOCK_TRUETIME not CLOCK_TRUE. + + ChangeLog@1.496.26.86 +1 -0 + [Bug 1659] Need CLOCK_TRUETIME not CLOCK_TRUE. + + ports/winnt/include/config.h@1.79.1.3 +1 -1 + [Bug 1659] Need CLOCK_TRUETIME not CLOCK_TRUE. + +ChangeSet@1.2082.4.115, 2010-10-14 14:47:37+00:00, davehart@shiny.ad.hartbrothers.com + constantly more fun + + ntpq/libntpq.c@1.3.1.4 +6 -6 + constantly more fun + +ChangeSet@1.2156.1.96, 2010-10-14 14:32:58+00:00, davehart@shiny.ad.hartbrothers.com + correct prior merge of ntpq.c + + ntpq/libntpq.c@1.7 +6 -6 + more const fun + + ntpq/ntpq.c@1.118 +0 -70 + correct prior merge of ntpq.c + +ChangeSet@1.2082.4.114, 2010-10-14 14:07:21+00:00, davehart@shiny.ad.hartbrothers.com + const additions needed for ntp-dev + + ChangeLog@1.496.26.85 +1 -0 + [Bug 1665] is_anycast() u_int32_t should be u_int32. + const additions needed for ntp-dev + + ntpd/ntp_io.c@1.306.1.6 +1 -1 + [Bug 1665] is_anycast() u_int32_t should be u_int32. + + ntpq/libntpq.c@1.3.1.3 +66 -62 + const additions needed for ntp-dev + + ntpq/libntpq.h@1.3.1.2 +2 -2 + const additions needed for ntp-dev + + ntpq/libntpq_subs.c@1.2.1.1 +13 -3 + const additions needed for ntp-dev + + ntpq/ntpq-subs.c@1.39.2.4 +42 -38 + const additions needed for ntp-dev + + ntpq/ntpq.c@1.97.1.6 +144 -84 + const additions needed for ntp-dev + + ntpq/ntpq.h@1.10.1.3 +7 -3 + const additions needed for ntp-dev + +ChangeSet@1.2082.4.113, 2010-10-14 09:38:42+00:00, davehart@shiny.ad.hartbrothers.com + ntpsnmpd, libntpq warning cleanup. + + + ChangeLog@1.496.26.84 +5 -1 + ntpsnmpd, libntpq warning cleanup. + + + ntpq/libntpq.c@1.3.1.2 +1 -1 + ntpsnmpd, libntpq warning cleanup. + + + ntpsnmpd/ntpsnmpd.c@1.3.1.3 +1 -2 + ntpsnmpd, libntpq warning cleanup. + + +ChangeSet@1.2082.4.112, 2010-10-14 07:51:07+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC3 + TAG: NTP_4_2_6P3_RC3 + + ChangeLog@1.496.26.83 +1 -0 + NTP_4_2_6P3_RC3 + + ntpd/ntpd-opts.c@1.248.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpd/ntpd-opts.h@1.248.19.1 +3 -3 + NTP_4_2_6P3_RC3 + + ntpd/ntpd-opts.texi@1.246.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpd/ntpd.1@1.246.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpdc/ntpdc-opts.c@1.244.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpdc/ntpdc-opts.h@1.244.19.1 +3 -3 + NTP_4_2_6P3_RC3 + + ntpdc/ntpdc-opts.texi@1.243.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpdc/ntpdc.1@1.243.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpq/ntpq-opts.c@1.245.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpq/ntpq-opts.h@1.245.19.1 +3 -3 + NTP_4_2_6P3_RC3 + + ntpq/ntpq-opts.texi@1.244.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpq/ntpq.1@1.244.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.20.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.20.1 +3 -3 + NTP_4_2_6P3_RC3 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.20.1 +2 -2 + NTP_4_2_6P3_RC3 + + ntpsnmpd/ntpsnmpd.1@1.122.20.1 +2 -2 + NTP_4_2_6P3_RC3 + + packageinfo.sh@1.255.21.1 +1 -1 + NTP_4_2_6P3_RC3 + + sntp/sntp-opts.c@1.117.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + sntp/sntp-opts.h@1.117.19.1 +3 -3 + NTP_4_2_6P3_RC3 + + sntp/sntp-opts.texi@1.117.19.1 +1 -1 + NTP_4_2_6P3_RC3 + + sntp/sntp.1@1.117.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + sntp/sntp.html@1.7.19.1 +1 -1 + NTP_4_2_6P3_RC3 + + util/ntp-keygen-opts.c@1.247.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + util/ntp-keygen-opts.h@1.247.19.1 +3 -3 + NTP_4_2_6P3_RC3 + + util/ntp-keygen-opts.texi@1.246.19.1 +2 -2 + NTP_4_2_6P3_RC3 + + util/ntp-keygen.1@1.246.19.1 +2 -2 + NTP_4_2_6P3_RC3 + +ChangeSet@1.2082.4.110, 2010-10-14 03:19:02-04:00, stenn@deacon.udel.edu + Update the NEWS file + + NEWS@1.109 +5 -1 + Update the NEWS file + +ChangeSet@1.2156.1.93, 2010-10-14 02:34:58-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.52 +1 -0 + Documentation updates from Dave Mills + + html/assoc.html@1.34 +14 -18 + Documentation updates from Dave Mills + + html/decode.html@1.16 +3 -3 + Documentation updates from Dave Mills + + html/warp.html@1.11 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.92, 2010-10-13 10:13:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P63 + TAG: NTP_4_2_7P63 + + ChangeLog@1.622.1.51 +1 -0 + NTP_4_2_7P63 + + ntpd/ntpd-opts.c@1.66 +2 -2 + NTP_4_2_7P63 + + ntpd/ntpd-opts.h@1.66 +3 -3 + NTP_4_2_7P63 + + ntpd/ntpd-opts.texi@1.65 +2 -2 + NTP_4_2_7P63 + + ntpd/ntpd.1@1.65 +2 -2 + NTP_4_2_7P63 + + ntpdc/ntpdc-opts.c@1.64 +2 -2 + NTP_4_2_7P63 + + ntpdc/ntpdc-opts.h@1.64 +3 -3 + NTP_4_2_7P63 + + ntpdc/ntpdc-opts.texi@1.64 +2 -2 + NTP_4_2_7P63 + + ntpdc/ntpdc.1@1.64 +2 -2 + NTP_4_2_7P63 + + ntpq/ntpq-opts.c@1.64 +2 -2 + NTP_4_2_7P63 + + ntpq/ntpq-opts.h@1.64 +3 -3 + NTP_4_2_7P63 + + ntpq/ntpq-opts.texi@1.64 +2 -2 + NTP_4_2_7P63 + + ntpq/ntpq.1@1.64 +2 -2 + NTP_4_2_7P63 + + ntpsnmpd/ntpsnmpd-opts.c@1.64 +2 -2 + NTP_4_2_7P63 + + ntpsnmpd/ntpsnmpd-opts.h@1.64 +3 -3 + NTP_4_2_7P63 + + ntpsnmpd/ntpsnmpd-opts.texi@1.64 +2 -2 + NTP_4_2_7P63 + + ntpsnmpd/ntpsnmpd.1@1.64 +2 -2 + NTP_4_2_7P63 + + packageinfo.sh@1.65 +1 -1 + NTP_4_2_7P63 + + sntp/sntp-opts.c@1.64 +2 -2 + NTP_4_2_7P63 + + sntp/sntp-opts.h@1.64 +3 -3 + NTP_4_2_7P63 + + sntp/sntp-opts.texi@1.64 +1 -1 + NTP_4_2_7P63 + + sntp/sntp.1@1.64 +2 -2 + NTP_4_2_7P63 + + sntp/sntp.html@1.64 +1 -1 + NTP_4_2_7P63 + + util/ntp-keygen-opts.c@1.61 +2 -2 + NTP_4_2_7P63 + + util/ntp-keygen-opts.h@1.61 +3 -3 + NTP_4_2_7P63 + + util/ntp-keygen-opts.texi@1.64 +2 -2 + NTP_4_2_7P63 + + util/ntp-keygen.1@1.64 +2 -2 + NTP_4_2_7P63 + +ChangeSet@1.2156.15.1, 2010-10-13 02:10:33-04:00, stenn@deacon.udel.edu + Add missing [bug 750] update to Changelog + + ChangeLog@1.622.6.1 +2 -0 + Add missing [bug 750] update to Changelog + +ChangeSet@1.2156.1.89, 2010-10-12 21:33:17-07:00, stenn@stenn.ntp.org + Documentation nit cleanup + + ChangeLog@1.622.1.48 +1 -0 + Documentation nit cleanup + + html/drivers/driver38.html@1.14 +1 -1 + Documentation nit cleanup + + html/parsenew.html@1.12 +2 -2 + Documentation nit cleanup + +ChangeSet@1.2156.1.88, 2010-10-13 00:19:17-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.47 +1 -0 + Documentation updates from Dave Mills + + html/poll.html@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/poll.html + + html/poll.html@1.0 +0 -0 + +ChangeSet@1.2082.22.21, 2010-10-12 14:27:43+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1080] ntpd on ipv6 routers very chatty. + + ChangeLog@1.496.47.17 +1 -0 + [Bug 1080] ntpd on ipv6 routers very chatty. + + configure.ac@1.465.1.14 +33 -11 + [Bug 1080] ntpd on ipv6 routers very chatty. + + include/ntp_net.h@1.3.1.2 +9 -0 + [Bug 1080] ntpd on ipv6 routers very chatty. + + ntpd/ntp_io.c@1.306.1.5 +39 -0 + [Bug 1080] ntpd on ipv6 routers very chatty. + patch originally supplied to freebsd's head/contrib/ntp/ntpd/ntp_io.c + by ume@freebsd.org + http://www.mail-archive.com/svn-src-all@freebsd.org/msg16141.html + +ChangeSet@1.2156.1.87, 2010-10-12 10:13:07+00:00, stenn@deacon.udel.edu + NTP_4_2_7P62 + TAG: NTP_4_2_7P62 + + ChangeLog@1.622.1.46 +1 -0 + NTP_4_2_7P62 + + ntpd/ntpd-opts.c@1.65 +2 -2 + NTP_4_2_7P62 + + ntpd/ntpd-opts.h@1.65 +3 -3 + NTP_4_2_7P62 + + ntpd/ntpd-opts.texi@1.64 +2 -2 + NTP_4_2_7P62 + + ntpd/ntpd.1@1.64 +2 -2 + NTP_4_2_7P62 + + ntpdc/ntpdc-opts.c@1.63 +2 -2 + NTP_4_2_7P62 + + ntpdc/ntpdc-opts.h@1.63 +3 -3 + NTP_4_2_7P62 + + ntpdc/ntpdc-opts.texi@1.63 +2 -2 + NTP_4_2_7P62 + + ntpdc/ntpdc.1@1.63 +2 -2 + NTP_4_2_7P62 + + ntpq/ntpq-opts.c@1.63 +2 -2 + NTP_4_2_7P62 + + ntpq/ntpq-opts.h@1.63 +3 -3 + NTP_4_2_7P62 + + ntpq/ntpq-opts.texi@1.63 +2 -2 + NTP_4_2_7P62 + + ntpq/ntpq.1@1.63 +2 -2 + NTP_4_2_7P62 + + ntpsnmpd/ntpsnmpd-opts.c@1.63 +2 -2 + NTP_4_2_7P62 + + ntpsnmpd/ntpsnmpd-opts.h@1.63 +3 -3 + NTP_4_2_7P62 + + ntpsnmpd/ntpsnmpd-opts.texi@1.63 +2 -2 + NTP_4_2_7P62 + + ntpsnmpd/ntpsnmpd.1@1.63 +2 -2 + NTP_4_2_7P62 + + packageinfo.sh@1.64 +1 -1 + NTP_4_2_7P62 + + sntp/sntp-opts.c@1.63 +2 -2 + NTP_4_2_7P62 + + sntp/sntp-opts.h@1.63 +3 -3 + NTP_4_2_7P62 + + sntp/sntp-opts.texi@1.63 +1 -1 + NTP_4_2_7P62 + + sntp/sntp.1@1.63 +2 -2 + NTP_4_2_7P62 + + sntp/sntp.html@1.63 +1 -1 + NTP_4_2_7P62 + + util/ntp-keygen-opts.c@1.60 +2 -2 + NTP_4_2_7P62 + + util/ntp-keygen-opts.h@1.60 +3 -3 + NTP_4_2_7P62 + + util/ntp-keygen-opts.texi@1.63 +2 -2 + NTP_4_2_7P62 + + util/ntp-keygen.1@1.63 +2 -2 + NTP_4_2_7P62 + +ChangeSet@1.2082.22.20, 2010-10-12 01:28:24-04:00, stenn@deacon.udel.edu + [Bug 750]: Non-existing device causes coredump with RIPE-NCC driver + + ChangeLog@1.496.47.16 +7 -7 + [Bug 750]: Non-existing device causes coredump with RIPE-NCC driver + + ntpd/refclock_ripencc.c@1.7.1.5 +1 -1 + [Bug 750]: Non-existing device causes coredump with RIPE-NCC driver + +ChangeSet@1.2082.22.19, 2010-10-12 01:06:48-04:00, stenn@deacon.udel.edu + [Bug 750]: Non-existing device causes coredump with RIPE-NCC driver + + ChangeLog@1.496.47.15 +3 -2 + [Bug 750]: Non-existing device causes coredump with RIPE-NCC driver + + ntpd/refclock_ripencc.c@1.7.1.4 +18 -9 + [Bug 750]: Non-existing device causes coredump with RIPE-NCC driver + +ChangeSet@1.2156.1.84, 2010-10-12 00:11:52-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.43 +1 -0 + Documentation updates from Dave Mills + + html/assoc.html@1.33 +8 -9 + Documentation updates from Dave Mills + + html/confopt.html@1.52 +38 -113 + Documentation updates from Dave Mills + + html/discipline.html@1.3 +2 -8 + Documentation updates from Dave Mills + + html/ntpq.html@1.42 +2 -2 + Documentation updates from Dave Mills + + html/scripts/special.txt@1.5 +1 -0 + Documentation updates from Dave Mills + + html/warp.html@1.10 +12 -10 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.83, 2010-10-12 00:06:48-04:00, stenn@deacon.udel.edu + Lose peer_count from ntp_peer.c and ntp_proto.c (Dave Mills) + + ChangeLog@1.622.1.42 +1 -0 + Lose peer_count from ntp_peer.c and ntp_proto.c (Dave Mills) + + ntpd/ntp_peer.c@1.135 +1 -8 + Lose peer_count from ntp_peer.c and ntp_proto.c (Dave Mills) + + ntpd/ntp_proto.c@1.307 +10 -5 + Lose peer_count from ntp_peer.c and ntp_proto.c (Dave Mills) + +ChangeSet@1.2082.22.17, 2010-10-11 20:18:23-07:00, stenn@stenn.ntp.org + [Bug 1661]: Re-indent refclock_ripencc.c + + ChangeLog@1.496.47.13 +1 -0 + [Bug 1661]: Re-indent refclock_ripencc.c + + ntpd/refclock_ripencc.c@1.7.1.3 +1909 -1530 + [Bug 1661]: Re-indent refclock_ripencc.c + +ChangeSet@1.2082.28.1, 2010-10-11 22:36:49-04:00, stenn@deacon.udel.edu + [Bug 1660]: On some systems, test is in /usr/bin, not /bin + + ChangeLog@1.496.51.1 +1 -0 + [Bug 1660]: On some systems, test is in /usr/bin, not /bin + + Makefile.am@1.93.2.1 +1 -1 + [Bug 1660]: On some systems, test is in /usr/bin, not /bin + + configure.ac@1.465.1.13 +3 -1 + [Bug 1660]: On some systems, test is in /usr/bin, not /bin + +ChangeSet@1.2082.27.1, 2010-10-12 01:16:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ChangeLog@1.496.50.1 +1 -0 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ntpq/libntpq.c@1.3.1.1 +58 -65 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ntpq/libntpq.h@1.3.1.1 +5 -5 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ntpsnmpd/Makefile.am@1.16.1.4 +2 -2 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ntpsnmpd/ntpSnmpSubagentObject.c@1.3.1.1 +96 -285 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ntpsnmpd/ntpSnmpSubagentObject.h@1.3 +41 -35 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ntpsnmpd/ntp_snmp.h@1.1 +34 -0 + work around PACKAGE_* redefinitions with net-snmp/net-snmp-config.h + + ntpsnmpd/ntp_snmp.h@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.c@1.3.1.2 +1 -11 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + + ntpsnmpd/ntpv4-mib.mib@1.2 +244 -357 + [Bug 1584]: ntpsnmpd OID must be mib-2.197. + +ChangeSet@1.2082.26.3, 2010-10-09 10:10:10+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + + ChangeLog@1.496.49.2 +4 -2 + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + + ntpd/refclock_arbiter.c@1.16 +34 -9 + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + + + ntpd/refclock_true.c@1.11.1.2 +15 -0 + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + + ports/winnt/include/config.h@1.79.1.2 +2 -0 + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + + ports/winnt/vc6/ntpd.dsp@1.39.1.3 +0 -2 + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + + ports/winnt/vs2003/ntpd.vcproj@1.4.1.1 +4 -8 + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + + ports/winnt/vs2005/ntpd.vcproj@1.4.1.1 +0 -4 + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.21.1.2 +0 -4 + [Bug 1567] Support Arbiter 1093C Satellite Clock on Windows. + [Bug 1659] Support Truetime Satellite Clocks on Windows. + + +ChangeSet@1.2156.1.80, 2010-10-06 10:09:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P61 + TAG: NTP_4_2_7P61 + + ChangeLog@1.622.1.39 +1 -0 + NTP_4_2_7P61 + + ntpd/ntpd-opts.c@1.64 +2 -2 + NTP_4_2_7P61 + + ntpd/ntpd-opts.h@1.64 +3 -3 + NTP_4_2_7P61 + + ntpd/ntpd-opts.texi@1.63 +2 -2 + NTP_4_2_7P61 + + ntpd/ntpd.1@1.63 +2 -2 + NTP_4_2_7P61 + + ntpdc/ntpdc-opts.c@1.62 +2 -2 + NTP_4_2_7P61 + + ntpdc/ntpdc-opts.h@1.62 +3 -3 + NTP_4_2_7P61 + + ntpdc/ntpdc-opts.texi@1.62 +2 -2 + NTP_4_2_7P61 + + ntpdc/ntpdc.1@1.62 +2 -2 + NTP_4_2_7P61 + + ntpq/ntpq-opts.c@1.62 +2 -2 + NTP_4_2_7P61 + + ntpq/ntpq-opts.h@1.62 +3 -3 + NTP_4_2_7P61 + + ntpq/ntpq-opts.texi@1.62 +2 -2 + NTP_4_2_7P61 + + ntpq/ntpq.1@1.62 +2 -2 + NTP_4_2_7P61 + + ntpsnmpd/ntpsnmpd-opts.c@1.62 +2 -2 + NTP_4_2_7P61 + + ntpsnmpd/ntpsnmpd-opts.h@1.62 +3 -3 + NTP_4_2_7P61 + + ntpsnmpd/ntpsnmpd-opts.texi@1.62 +2 -2 + NTP_4_2_7P61 + + ntpsnmpd/ntpsnmpd.1@1.62 +2 -2 + NTP_4_2_7P61 + + packageinfo.sh@1.63 +1 -1 + NTP_4_2_7P61 + + sntp/sntp-opts.c@1.62 +2 -2 + NTP_4_2_7P61 + + sntp/sntp-opts.h@1.62 +3 -3 + NTP_4_2_7P61 + + sntp/sntp-opts.texi@1.62 +1 -1 + NTP_4_2_7P61 + + sntp/sntp.1@1.62 +2 -2 + NTP_4_2_7P61 + + sntp/sntp.html@1.62 +1 -1 + NTP_4_2_7P61 + + util/ntp-keygen-opts.c@1.59 +2 -2 + NTP_4_2_7P61 + + util/ntp-keygen-opts.h@1.59 +3 -3 + NTP_4_2_7P61 + + util/ntp-keygen-opts.texi@1.62 +2 -2 + NTP_4_2_7P61 + + util/ntp-keygen.1@1.62 +2 -2 + NTP_4_2_7P61 + +ChangeSet@1.2156.1.79, 2010-10-06 00:17:06-04:00, stenn@deacon.udel.edu + Documentation and code cleanup from Dave Mills. No more NTP_MAXASSOC. + + ChangeLog@1.622.1.38 +1 -0 + Documentation and code cleanup from Dave Mills. No more NTP_MAXASSOC. + + html/cluster.html@1.2 +5 -6 + Documentation and code cleanup from Dave Mills. No more NTP_MAXASSOC. + + include/ntp.h@1.182 +0 -1 + Documentation and code cleanup from Dave Mills. No more NTP_MAXASSOC. + + ntpd/ntp_proto.c@1.306 +40 -63 + Documentation and code cleanup from Dave Mills. No more NTP_MAXASSOC. + +ChangeSet@1.2156.1.78, 2010-10-04 10:13:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P60 + TAG: NTP_4_2_7P60 + + ChangeLog@1.622.1.37 +1 -0 + NTP_4_2_7P60 + + ntpd/ntpd-opts.c@1.63 +2 -2 + NTP_4_2_7P60 + + ntpd/ntpd-opts.h@1.63 +3 -3 + NTP_4_2_7P60 + + ntpd/ntpd-opts.texi@1.62 +2 -2 + NTP_4_2_7P60 + + ntpd/ntpd.1@1.62 +2 -2 + NTP_4_2_7P60 + + ntpdc/ntpdc-opts.c@1.61 +2 -2 + NTP_4_2_7P60 + + ntpdc/ntpdc-opts.h@1.61 +3 -3 + NTP_4_2_7P60 + + ntpdc/ntpdc-opts.texi@1.61 +2 -2 + NTP_4_2_7P60 + + ntpdc/ntpdc.1@1.61 +2 -2 + NTP_4_2_7P60 + + ntpq/ntpq-opts.c@1.61 +2 -2 + NTP_4_2_7P60 + + ntpq/ntpq-opts.h@1.61 +3 -3 + NTP_4_2_7P60 + + ntpq/ntpq-opts.texi@1.61 +2 -2 + NTP_4_2_7P60 + + ntpq/ntpq.1@1.61 +2 -2 + NTP_4_2_7P60 + + ntpsnmpd/ntpsnmpd-opts.c@1.61 +2 -2 + NTP_4_2_7P60 + + ntpsnmpd/ntpsnmpd-opts.h@1.61 +3 -3 + NTP_4_2_7P60 + + ntpsnmpd/ntpsnmpd-opts.texi@1.61 +2 -2 + NTP_4_2_7P60 + + ntpsnmpd/ntpsnmpd.1@1.61 +2 -2 + NTP_4_2_7P60 + + packageinfo.sh@1.62 +1 -1 + NTP_4_2_7P60 + + sntp/sntp-opts.c@1.61 +2 -2 + NTP_4_2_7P60 + + sntp/sntp-opts.h@1.61 +3 -3 + NTP_4_2_7P60 + + sntp/sntp-opts.texi@1.61 +1 -1 + NTP_4_2_7P60 + + sntp/sntp.1@1.61 +2 -2 + NTP_4_2_7P60 + + sntp/sntp.html@1.61 +1 -1 + NTP_4_2_7P60 + + util/ntp-keygen-opts.c@1.58 +2 -2 + NTP_4_2_7P60 + + util/ntp-keygen-opts.h@1.58 +3 -3 + NTP_4_2_7P60 + + util/ntp-keygen-opts.texi@1.61 +2 -2 + NTP_4_2_7P60 + + util/ntp-keygen.1@1.61 +2 -2 + NTP_4_2_7P60 + +ChangeSet@1.2156.1.77, 2010-10-04 01:30:19-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/pic/flt3.gif@1.1 +43 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt3.gif + + html/pic/flt3.gif@1.0 +0 -0 + + html/pic/flt6.gif@1.1 +347 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt6.gif + + html/pic/flt6.gif@1.0 +0 -0 + + html/pic/flt7.gif@1.1 +176 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt7.gif + + html/pic/flt7.gif@1.0 +0 -0 + +ChangeSet@1.2156.1.76, 2010-10-04 01:22:59-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/pic/flt4.gif@1.1 +88 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt4.gif + + html/pic/flt4.gif@1.0 +0 -0 + +ChangeSet@1.2156.1.75, 2010-10-04 01:14:16-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.36 +1 -0 + Documentation updates from Dave Mills + + html/authentic.html@1.3 +1 -1 + Documentation updates from Dave Mills + + html/authopt.html@1.64 +2 -1 + Documentation updates from Dave Mills + + html/cluster.html@1.1 +31 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/cluster.html + + html/cluster.html@1.0 +0 -0 + + html/comdex.html@1.4 +3 -1 + Documentation updates from Dave Mills + + html/debug.html@1.31 +3 -2 + Documentation updates from Dave Mills + + html/ntp_conf.html@1.6 +2 -2 + Documentation updates from Dave Mills + + html/ntpdsim_new.html@1.6 +2 -1 + Documentation updates from Dave Mills + + html/select.html@1.1 +32 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/select.html + + html/select.html@1.0 +0 -0 + + html/warp.html@1.9 +12 -18 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.74, 2010-10-02 08:00:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P59 + TAG: NTP_4_2_7P59 + + ChangeLog@1.622.1.35 +1 -0 + NTP_4_2_7P59 + + ntpd/ntpd-opts.c@1.62 +2 -2 + NTP_4_2_7P59 + + ntpd/ntpd-opts.h@1.62 +3 -3 + NTP_4_2_7P59 + + ntpd/ntpd-opts.texi@1.61 +2 -2 + NTP_4_2_7P59 + + ntpd/ntpd.1@1.61 +2 -2 + NTP_4_2_7P59 + + ntpdc/ntpdc-opts.c@1.60 +2 -2 + NTP_4_2_7P59 + + ntpdc/ntpdc-opts.h@1.60 +3 -3 + NTP_4_2_7P59 + + ntpdc/ntpdc-opts.texi@1.60 +2 -2 + NTP_4_2_7P59 + + ntpdc/ntpdc.1@1.60 +2 -2 + NTP_4_2_7P59 + + ntpq/ntpq-opts.c@1.60 +2 -2 + NTP_4_2_7P59 + + ntpq/ntpq-opts.h@1.60 +3 -3 + NTP_4_2_7P59 + + ntpq/ntpq-opts.texi@1.60 +2 -2 + NTP_4_2_7P59 + + ntpq/ntpq.1@1.60 +2 -2 + NTP_4_2_7P59 + + ntpsnmpd/ntpsnmpd-opts.c@1.60 +2 -2 + NTP_4_2_7P59 + + ntpsnmpd/ntpsnmpd-opts.h@1.60 +3 -3 + NTP_4_2_7P59 + + ntpsnmpd/ntpsnmpd-opts.texi@1.60 +2 -2 + NTP_4_2_7P59 + + ntpsnmpd/ntpsnmpd.1@1.60 +2 -2 + NTP_4_2_7P59 + + packageinfo.sh@1.61 +1 -1 + NTP_4_2_7P59 + + sntp/sntp-opts.c@1.60 +2 -2 + NTP_4_2_7P59 + + sntp/sntp-opts.h@1.60 +3 -3 + NTP_4_2_7P59 + + sntp/sntp-opts.texi@1.60 +1 -1 + NTP_4_2_7P59 + + sntp/sntp.1@1.60 +2 -2 + NTP_4_2_7P59 + + sntp/sntp.html@1.60 +1 -1 + NTP_4_2_7P59 + + util/ntp-keygen-opts.c@1.57 +2 -2 + NTP_4_2_7P59 + + util/ntp-keygen-opts.h@1.57 +3 -3 + NTP_4_2_7P59 + + util/ntp-keygen-opts.texi@1.60 +2 -2 + NTP_4_2_7P59 + + util/ntp-keygen.1@1.60 +2 -2 + NTP_4_2_7P59 + +ChangeSet@1.2156.1.72, 2010-10-02 03:47:56-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.34 +1 -0 + Documentation updates from Dave Mills + + html/filter.html@1.2 +7 -6 + Documentation updates from Dave Mills + + html/huffpuff.html@1.2 +8 -3 + Documentation updates from Dave Mills + + html/scripts/special.txt@1.4 +3 -0 + Documentation updates from Dave Mills + + html/warp.html@1.8 +9 -10 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.71, 2010-10-02 03:45:18-04:00, stenn@deacon.udel.edu + Variable name cleanup from Dave Mills + + ChangeLog@1.622.1.33 +1 -0 + Variable name cleanup from Dave Mills + + ntpd/ntp_proto.c@1.305 +4 -4 + Variable name cleanup from Dave Mills + +ChangeSet@1.2156.1.70, 2010-10-02 00:36:46-07:00, harlan@hms-mbp.lan + [Bug 1657] darwin needs res_9_init, not res_init. + + ChangeLog@1.622.1.32 +1 -0 + [Bug 1657] darwin needs res_9_init, not res_init. + + configure.ac@1.483.1.8 +5 -3 + [Bug 1657] darwin needs res_9_init, not res_init. + +ChangeSet@1.2082.26.2, 2010-10-02 00:31:32-04:00, stenn@deacon.udel.edu + Update the NEWS file for 4.2.6p3 + + NEWS@1.108 +31 -0 + Update the NEWS file for 4.2.6p3 + +ChangeSet@1.2156.1.69, 2010-09-30 05:11:53+00:00, stenn@deacon.udel.edu + NTP_4_2_7P58 + TAG: NTP_4_2_7P58 + + ChangeLog@1.622.1.31 +1 -0 + NTP_4_2_7P58 + + ntpd/ntpd-opts.c@1.61 +2 -2 + NTP_4_2_7P58 + + ntpd/ntpd-opts.h@1.61 +3 -3 + NTP_4_2_7P58 + + ntpd/ntpd-opts.texi@1.60 +2 -2 + NTP_4_2_7P58 + + ntpd/ntpd.1@1.60 +2 -2 + NTP_4_2_7P58 + + ntpdc/ntpdc-opts.c@1.59 +2 -2 + NTP_4_2_7P58 + + ntpdc/ntpdc-opts.h@1.59 +3 -3 + NTP_4_2_7P58 + + ntpdc/ntpdc-opts.texi@1.59 +2 -2 + NTP_4_2_7P58 + + ntpdc/ntpdc.1@1.59 +2 -2 + NTP_4_2_7P58 + + ntpq/ntpq-opts.c@1.59 +2 -2 + NTP_4_2_7P58 + + ntpq/ntpq-opts.h@1.59 +3 -3 + NTP_4_2_7P58 + + ntpq/ntpq-opts.texi@1.59 +2 -2 + NTP_4_2_7P58 + + ntpq/ntpq.1@1.59 +2 -2 + NTP_4_2_7P58 + + ntpsnmpd/ntpsnmpd-opts.c@1.59 +2 -2 + NTP_4_2_7P58 + + ntpsnmpd/ntpsnmpd-opts.h@1.59 +3 -3 + NTP_4_2_7P58 + + ntpsnmpd/ntpsnmpd-opts.texi@1.59 +2 -2 + NTP_4_2_7P58 + + ntpsnmpd/ntpsnmpd.1@1.59 +2 -2 + NTP_4_2_7P58 + + packageinfo.sh@1.60 +1 -1 + NTP_4_2_7P58 + + sntp/sntp-opts.c@1.59 +2 -2 + NTP_4_2_7P58 + + sntp/sntp-opts.h@1.59 +3 -3 + NTP_4_2_7P58 + + sntp/sntp-opts.texi@1.59 +1 -1 + NTP_4_2_7P58 + + sntp/sntp.1@1.59 +2 -2 + NTP_4_2_7P58 + + sntp/sntp.html@1.59 +1 -1 + NTP_4_2_7P58 + + util/ntp-keygen-opts.c@1.56 +2 -2 + NTP_4_2_7P58 + + util/ntp-keygen-opts.h@1.56 +3 -3 + NTP_4_2_7P58 + + util/ntp-keygen-opts.texi@1.59 +2 -2 + NTP_4_2_7P58 + + util/ntp-keygen.1@1.59 +2 -2 + NTP_4_2_7P58 + +ChangeSet@1.2156.1.67, 2010-09-30 00:50:30-04:00, stenn@deacon.udel.edu + Clock select bugfix from Dave Mills. + [Bug 1554]: peer may stay selected as system peer after becoming + unreachable. + + ChangeLog@1.622.1.29 +3 -0 + Clock select bugfix from Dave Mills. + [Bug 155]: peer may stay selected as system peer after becoming + unreachable. + + ntpd/ntp_proto.c@1.304 +10 -3 + Clock select bugfix from Dave Mills. + [Bug 155]: peer may stay selected as system peer after becoming + unreachable. + +ChangeSet@1.2156.1.65, 2010-09-30 00:16:29-04:00, stenn@deacon.udel.edu + ChangeLog cleanup + + ChangeLog@1.622.1.27 +1 -1 + cleanup + +ChangeSet@1.2082.26.1, 2010-09-30 00:14:03-04:00, stenn@deacon.udel.edu + [Bug 1644]: cvo.sh should use lsb_release to identify linux distros. + + ChangeLog@1.496.49.1 +2 -0 + [Bug 1644]: cvo.sh should use lsb_release to identify linux distros. + + scripts/cvo.sh@1.3.2.1 +4 -3 + [Bug 1644]: cvo.sh should use lsb_release to identify linux distros. + +ChangeSet@1.2156.13.1, 2010-09-27 18:06:28+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1646] ntpd crashes with relative path to logfile. + + ChangeLog@1.622.4.1 +1 -0 + [Bug 1646] ntpd crashes with relative path to logfile. + + ntpd/ntpd.c@1.116 +2 -5 + [Bug 1646] ntpd crashes with relative path to logfile. + +ChangeSet@1.2156.12.1, 2010-09-27 10:11:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P57 + TAG: NTP_4_2_7P57 + + ChangeLog@1.622.3.1 +1 -0 + NTP_4_2_7P57 + + ntpd/ntpd-opts.c@1.60 +2 -2 + NTP_4_2_7P57 + + ntpd/ntpd-opts.h@1.60 +3 -3 + NTP_4_2_7P57 + + ntpd/ntpd-opts.texi@1.59 +2 -2 + NTP_4_2_7P57 + + ntpd/ntpd.1@1.59 +2 -2 + NTP_4_2_7P57 + + ntpdc/ntpdc-opts.c@1.58 +2 -2 + NTP_4_2_7P57 + + ntpdc/ntpdc-opts.h@1.58 +3 -3 + NTP_4_2_7P57 + + ntpdc/ntpdc-opts.texi@1.58 +2 -2 + NTP_4_2_7P57 + + ntpdc/ntpdc.1@1.58 +2 -2 + NTP_4_2_7P57 + + ntpq/ntpq-opts.c@1.58 +2 -2 + NTP_4_2_7P57 + + ntpq/ntpq-opts.h@1.58 +3 -3 + NTP_4_2_7P57 + + ntpq/ntpq-opts.texi@1.58 +2 -2 + NTP_4_2_7P57 + + ntpq/ntpq.1@1.58 +2 -2 + NTP_4_2_7P57 + + ntpsnmpd/ntpsnmpd-opts.c@1.58 +2 -2 + NTP_4_2_7P57 + + ntpsnmpd/ntpsnmpd-opts.h@1.58 +3 -3 + NTP_4_2_7P57 + + ntpsnmpd/ntpsnmpd-opts.texi@1.58 +2 -2 + NTP_4_2_7P57 + + ntpsnmpd/ntpsnmpd.1@1.58 +2 -2 + NTP_4_2_7P57 + + packageinfo.sh@1.59 +1 -1 + NTP_4_2_7P57 + + sntp/sntp-opts.c@1.58 +2 -2 + NTP_4_2_7P57 + + sntp/sntp-opts.h@1.58 +3 -3 + NTP_4_2_7P57 + + sntp/sntp-opts.texi@1.58 +1 -1 + NTP_4_2_7P57 + + sntp/sntp.1@1.58 +2 -2 + NTP_4_2_7P57 + + sntp/sntp.html@1.58 +1 -1 + NTP_4_2_7P57 + + util/ntp-keygen-opts.c@1.55 +2 -2 + NTP_4_2_7P57 + + util/ntp-keygen-opts.h@1.55 +3 -3 + NTP_4_2_7P57 + + util/ntp-keygen-opts.texi@1.58 +2 -2 + NTP_4_2_7P57 + + util/ntp-keygen.1@1.58 +2 -2 + NTP_4_2_7P57 + +ChangeSet@1.2082.22.15, 2010-09-27 01:33:39-04:00, stenn@psp-deb1.ntp.org + [Bug 1644]: cvo.sh doesn't handle some unstable/testing linux distros + + ChangeLog@1.496.47.11 +2 -0 + [Bug 1644]: cvo.sh doesn't handle some unstable/testing linux distros + + scripts/cvo.sh@1.3.1.1 +4 -3 + [Bug 1644]: cvo.sh doesn't handle some unstable/testing linux distros + +ChangeSet@1.2156.1.63, 2010-09-27 01:31:15-04:00, stenn@psp-deb1.ntp.org + [Bug 1644] from 4.2.6p3: cvo.sh doesn't handle some unstable/testing linux distros + + ChangeLog@1.622.1.25 +2 -0 + [Bug 1644] from 4.2.6p3: cvo.sh doesn't handle some unstable/testing linux distros + + scripts/cvo.sh@1.4 +4 -3 + [Bug 1644] from 4.2.6p3: cvo.sh doesn't handle some unstable/testing linux distros + +ChangeSet@1.2156.1.62, 2010-09-26 15:27:53-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/pic/flt1.gif@1.1 +202 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt1.gif + + html/pic/flt1.gif@1.0 +0 -0 + + html/pic/flt2.gif@1.1 +71 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt2.gif + + html/pic/flt2.gif@1.0 +0 -0 + + html/pic/flt5.gif@1.1 +237 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flt5.gif + + html/pic/flt5.gif@1.0 +0 -0 + +ChangeSet@1.2156.1.61, 2010-09-26 15:23:27-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/filter.html@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/filter.html + + html/filter.html@1.0 +0 -0 + +ChangeSet@1.2156.1.60, 2010-09-26 14:40:09-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.24 +1 -0 + Documentation updates from Dave Mills + + html/scripts/special.txt@1.3 +1 -0 + Documentation updates from Dave Mills + + html/warp.html@1.7 +2 -5 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.59, 2010-09-25 21:45:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P56 + TAG: NTP_4_2_7P56 + + ChangeLog@1.622.1.23 +1 -0 + NTP_4_2_7P56 + + ntpd/ntpd-opts.c@1.59 +2 -2 + NTP_4_2_7P56 + + ntpd/ntpd-opts.h@1.59 +3 -3 + NTP_4_2_7P56 + + ntpd/ntpd-opts.texi@1.58 +2 -2 + NTP_4_2_7P56 + + ntpd/ntpd.1@1.58 +2 -2 + NTP_4_2_7P56 + + ntpdc/ntpdc-opts.c@1.57 +2 -2 + NTP_4_2_7P56 + + ntpdc/ntpdc-opts.h@1.57 +3 -3 + NTP_4_2_7P56 + + ntpdc/ntpdc-opts.texi@1.57 +2 -2 + NTP_4_2_7P56 + + ntpdc/ntpdc.1@1.57 +2 -2 + NTP_4_2_7P56 + + ntpq/ntpq-opts.c@1.57 +2 -2 + NTP_4_2_7P56 + + ntpq/ntpq-opts.h@1.57 +3 -3 + NTP_4_2_7P56 + + ntpq/ntpq-opts.texi@1.57 +2 -2 + NTP_4_2_7P56 + + ntpq/ntpq.1@1.57 +2 -2 + NTP_4_2_7P56 + + ntpsnmpd/ntpsnmpd-opts.c@1.57 +2 -2 + NTP_4_2_7P56 + + ntpsnmpd/ntpsnmpd-opts.h@1.57 +3 -3 + NTP_4_2_7P56 + + ntpsnmpd/ntpsnmpd-opts.texi@1.57 +2 -2 + NTP_4_2_7P56 + + ntpsnmpd/ntpsnmpd.1@1.57 +2 -2 + NTP_4_2_7P56 + + packageinfo.sh@1.58 +1 -1 + NTP_4_2_7P56 + + sntp/sntp-opts.c@1.57 +2 -2 + NTP_4_2_7P56 + + sntp/sntp-opts.h@1.57 +3 -3 + NTP_4_2_7P56 + + sntp/sntp-opts.texi@1.57 +1 -1 + NTP_4_2_7P56 + + sntp/sntp.1@1.57 +2 -2 + NTP_4_2_7P56 + + sntp/sntp.html@1.57 +1 -1 + NTP_4_2_7P56 + + util/ntp-keygen-opts.c@1.54 +2 -2 + NTP_4_2_7P56 + + util/ntp-keygen-opts.h@1.54 +3 -3 + NTP_4_2_7P56 + + util/ntp-keygen-opts.texi@1.57 +2 -2 + NTP_4_2_7P56 + + util/ntp-keygen.1@1.57 +2 -2 + NTP_4_2_7P56 + +ChangeSet@1.2082.22.14, 2010-09-25 17:32:37-04:00, stenn@deacon.udel.edu + typo fix + + ntpd/refclock_ripencc.c@1.7.1.2 +1 -1 + typo fix + +ChangeSet@1.2082.22.13, 2010-09-25 21:14:57+00:00, stenn@psp-fb2.ntp.org + [Bug 1643]: Range-check the decoding of the RIPE-NCC status codes + + ChangeLog@1.496.47.10 +3 -0 + [Bug 1643]: Range-check the decoding of the RIPE-NCC status codes + + ntpd/refclock_ripencc.c@1.7.1.1 +11 -6 + [Bug 1643]: Range-check the decoding of the RIPE-NCC status codes + +ChangeSet@1.2156.1.56, 2010-09-25 21:11:34+00:00, stenn@psp-fb2.ntp.org + [Bug 1643] from 4.2.6p3: Range-check the decoding of the RIPE-NCC status codes + + ChangeLog@1.622.1.21 +2 -0 + [Bug 1643] from 4.2.6p3: Range-check the decoding of the RIPE-NCC status codes + + ntpd/refclock_ripencc.c@1.9 +8 -3 + [Bug 1643] from 4.2.6p3: Range-check the decoding of the RIPE-NCC status codes + +ChangeSet@1.2082.22.12, 2010-09-25 18:22:19+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC2 + TAG: NTP_4_2_6P3_RC2 + + ChangeLog@1.496.47.9 +1 -0 + NTP_4_2_6P3_RC2 + + ntpd/ntpd-opts.c@1.248.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpd/ntpd-opts.h@1.248.18.1 +3 -3 + NTP_4_2_6P3_RC2 + + ntpd/ntpd-opts.texi@1.246.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpd/ntpd.1@1.246.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpdc/ntpdc-opts.c@1.244.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpdc/ntpdc-opts.h@1.244.18.1 +3 -3 + NTP_4_2_6P3_RC2 + + ntpdc/ntpdc-opts.texi@1.243.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpdc/ntpdc.1@1.243.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpq/ntpq-opts.c@1.245.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpq/ntpq-opts.h@1.245.18.1 +3 -3 + NTP_4_2_6P3_RC2 + + ntpq/ntpq-opts.texi@1.244.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpq/ntpq.1@1.244.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.19.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.19.1 +3 -3 + NTP_4_2_6P3_RC2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.19.1 +2 -2 + NTP_4_2_6P3_RC2 + + ntpsnmpd/ntpsnmpd.1@1.122.19.1 +2 -2 + NTP_4_2_6P3_RC2 + + packageinfo.sh@1.255.20.1 +1 -1 + NTP_4_2_6P3_RC2 + + sntp/sntp-opts.c@1.117.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + sntp/sntp-opts.h@1.117.18.1 +3 -3 + NTP_4_2_6P3_RC2 + + sntp/sntp-opts.texi@1.117.18.1 +1 -1 + NTP_4_2_6P3_RC2 + + sntp/sntp.1@1.117.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + sntp/sntp.html@1.7.18.1 +1 -1 + NTP_4_2_6P3_RC2 + + util/ntp-keygen-opts.c@1.247.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + util/ntp-keygen-opts.h@1.247.18.1 +3 -3 + NTP_4_2_6P3_RC2 + + util/ntp-keygen-opts.texi@1.246.18.1 +2 -2 + NTP_4_2_6P3_RC2 + + util/ntp-keygen.1@1.246.18.1 +2 -2 + NTP_4_2_6P3_RC2 + +ChangeSet@1.2156.1.54, 2010-09-25 13:43:49-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.19 +1 -0 + Documentation updates from Dave Mills + + html/discipline.html@1.2 +11 -9 + Documentation updates from Dave Mills + + html/kern.html@1.19 +4 -3 + Documentation updates from Dave Mills + + html/prefer.html@1.24 +13 -6 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.53, 2010-09-25 13:39:59-04:00, stenn@deacon.udel.edu + Clock combining algorithm improvements from Dave Mills + + ChangeLog@1.622.1.18 +1 -0 + Clock combining algorithm improvements from Dave Mills + + ntpd/ntp_proto.c@1.303 +7 -7 + Clock combining algorithm improvements from Dave Mills + +ChangeSet@1.2156.1.52, 2010-09-25 07:44:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1642] ntpdsim can't find simulate block in config file. + + ChangeLog@1.622.1.17 +1 -0 + [Bug 1642] ntpdsim can't find simulate block in config file. + + ntpd/ntp_config.c@1.265 +14 -13 + Invert #ifdef SIM conditionalization of create_sim_script_info(), + create_sim_server(), and get_next_address(). + Fix infinite loop in create_sim_script_info() caused by failing to + advance my_attr_val through script_queue before looping. + + ntpd/ntp_scanner.c@1.37 +15 -6 + Assumption that '=' is followed by a string (for setvar) is not + valid inside simulator configuration. + Assumption that 'server' is always followed by a string (not a + token) is not valid inside simulator config block. + + ntpd/ntpd.c@1.115 +5 -1 + Honor -d and -D in ntpdsim. + +ChangeSet@1.2082.24.1, 2010-09-22 20:14:51+02:00, jnperlin@hydra.localnet + [Bug 1571][Bug 1572] first clean-running version + + ntpd/refclock_nmea.c@1.46.1.3 +42 -27 + some more cleanup + + ntpd/refclock_nmea.c@1.46.1.2 +310 -70 + [Bug 1571][Bug 1572] first clean-running version + +ChangeSet@1.2156.1.51, 2010-09-22 10:10:38+00:00, stenn@deacon.udel.edu + NTP_4_2_7P55 + TAG: NTP_4_2_7P55 + + ChangeLog@1.622.1.16 +1 -0 + NTP_4_2_7P55 + + ntpd/ntpd-opts.c@1.58 +2 -2 + NTP_4_2_7P55 + + ntpd/ntpd-opts.h@1.58 +3 -3 + NTP_4_2_7P55 + + ntpd/ntpd-opts.texi@1.57 +2 -2 + NTP_4_2_7P55 + + ntpd/ntpd.1@1.57 +2 -2 + NTP_4_2_7P55 + + ntpdc/ntpdc-opts.c@1.56 +2 -2 + NTP_4_2_7P55 + + ntpdc/ntpdc-opts.h@1.56 +3 -3 + NTP_4_2_7P55 + + ntpdc/ntpdc-opts.texi@1.56 +2 -2 + NTP_4_2_7P55 + + ntpdc/ntpdc.1@1.56 +2 -2 + NTP_4_2_7P55 + + ntpq/ntpq-opts.c@1.56 +2 -2 + NTP_4_2_7P55 + + ntpq/ntpq-opts.h@1.56 +3 -3 + NTP_4_2_7P55 + + ntpq/ntpq-opts.texi@1.56 +2 -2 + NTP_4_2_7P55 + + ntpq/ntpq.1@1.56 +2 -2 + NTP_4_2_7P55 + + ntpsnmpd/ntpsnmpd-opts.c@1.56 +2 -2 + NTP_4_2_7P55 + + ntpsnmpd/ntpsnmpd-opts.h@1.56 +3 -3 + NTP_4_2_7P55 + + ntpsnmpd/ntpsnmpd-opts.texi@1.56 +2 -2 + NTP_4_2_7P55 + + ntpsnmpd/ntpsnmpd.1@1.56 +2 -2 + NTP_4_2_7P55 + + packageinfo.sh@1.57 +1 -1 + NTP_4_2_7P55 + + sntp/sntp-opts.c@1.56 +2 -2 + NTP_4_2_7P55 + + sntp/sntp-opts.h@1.56 +3 -3 + NTP_4_2_7P55 + + sntp/sntp-opts.texi@1.56 +1 -1 + NTP_4_2_7P55 + + sntp/sntp.1@1.56 +2 -2 + NTP_4_2_7P55 + + sntp/sntp.html@1.56 +1 -1 + NTP_4_2_7P55 + + util/ntp-keygen-opts.c@1.53 +2 -2 + NTP_4_2_7P55 + + util/ntp-keygen-opts.h@1.53 +3 -3 + NTP_4_2_7P55 + + util/ntp-keygen-opts.texi@1.56 +2 -2 + NTP_4_2_7P55 + + util/ntp-keygen.1@1.56 +2 -2 + NTP_4_2_7P55 + +ChangeSet@1.2156.1.50, 2010-09-22 01:22:45-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/pic/discipline.gif@1.1 +153 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/discipline.gif + + html/pic/discipline.gif@1.0 +0 -0 + +ChangeSet@1.2156.1.49, 2010-09-22 01:18:30-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + html/discipline.html@1.1 +45 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/discipline.html + + html/discipline.html@1.0 +0 -0 + +ChangeSet@1.2156.1.48, 2010-09-22 01:08:53-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.15 +1 -0 + Documentation updates from Dave Mills + + html/miscopt.html@1.59 +2 -2 + Documentation updates from Dave Mills + + html/scripts/special.txt@1.2 +1 -0 + Documentation updates from Dave Mills + + html/warp.html@1.6 +27 -91 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.47, 2010-09-21 17:10:47+00:00, davehart@shiny.ad.hartbrothers.com + correct Bison output of merged ntp_parser.y + + ntpd/ntp_parser.c@1.63 +165 -155 + correct Bison output of merged ntp_parser.y + +ChangeSet@1.2082.22.11, 2010-09-21 16:29:51+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1636] yyparse() segfault after denied filegen remote config. + + ChangeLog@1.496.47.8 +1 -0 + [Bug 1636] yyparse() segfault after denied filegen remote config. + + ntpd/ntp_parser.c@1.52.1.4 +149 -139 + [Bug 1636] yyparse() segfault after denied filegen remote config. + + ntpd/ntp_parser.y@1.47.1.4 +13 -3 + [Bug 1636] yyparse() segfault after denied filegen remote config. + +ChangeSet@1.2156.1.45, 2010-09-21 05:39:47+00:00, stenn@deacon.udel.edu + NTP_4_2_7P54 + TAG: NTP_4_2_7P54 + + ChangeLog@1.622.1.13 +1 -0 + NTP_4_2_7P54 + + ntpd/ntpd-opts.c@1.57 +2 -2 + NTP_4_2_7P54 + + ntpd/ntpd-opts.h@1.57 +3 -3 + NTP_4_2_7P54 + + ntpd/ntpd-opts.texi@1.56 +2 -2 + NTP_4_2_7P54 + + ntpd/ntpd.1@1.56 +2 -2 + NTP_4_2_7P54 + + ntpdc/ntpdc-opts.c@1.55 +2 -2 + NTP_4_2_7P54 + + ntpdc/ntpdc-opts.h@1.55 +3 -3 + NTP_4_2_7P54 + + ntpdc/ntpdc-opts.texi@1.55 +2 -2 + NTP_4_2_7P54 + + ntpdc/ntpdc.1@1.55 +2 -2 + NTP_4_2_7P54 + + ntpq/ntpq-opts.c@1.55 +2 -2 + NTP_4_2_7P54 + + ntpq/ntpq-opts.h@1.55 +3 -3 + NTP_4_2_7P54 + + ntpq/ntpq-opts.texi@1.55 +2 -2 + NTP_4_2_7P54 + + ntpq/ntpq.1@1.55 +2 -2 + NTP_4_2_7P54 + + ntpsnmpd/ntpsnmpd-opts.c@1.55 +2 -2 + NTP_4_2_7P54 + + ntpsnmpd/ntpsnmpd-opts.h@1.55 +3 -3 + NTP_4_2_7P54 + + ntpsnmpd/ntpsnmpd-opts.texi@1.55 +2 -2 + NTP_4_2_7P54 + + ntpsnmpd/ntpsnmpd.1@1.55 +2 -2 + NTP_4_2_7P54 + + packageinfo.sh@1.56 +1 -1 + NTP_4_2_7P54 + + sntp/sntp-opts.c@1.55 +2 -2 + NTP_4_2_7P54 + + sntp/sntp-opts.h@1.55 +3 -3 + NTP_4_2_7P54 + + sntp/sntp-opts.texi@1.55 +1 -1 + NTP_4_2_7P54 + + sntp/sntp.1@1.55 +2 -2 + NTP_4_2_7P54 + + sntp/sntp.html@1.55 +1 -1 + NTP_4_2_7P54 + + util/ntp-keygen-opts.c@1.52 +2 -2 + NTP_4_2_7P54 + + util/ntp-keygen-opts.h@1.52 +3 -3 + NTP_4_2_7P54 + + util/ntp-keygen-opts.texi@1.55 +2 -2 + NTP_4_2_7P54 + + util/ntp-keygen.1@1.55 +2 -2 + NTP_4_2_7P54 + +ChangeSet@1.2156.1.44, 2010-09-21 01:26:14-04:00, stenn@deacon.udel.edu + More initial convergence improvements from Dave Mills + + ChangeLog@1.622.1.12 +1 -0 + More initial convergence improvements from Dave Mills + + ntpd/ntp_loopfilter.c@1.158 +4 -1 + More initial convergence improvements from Dave Mills + +ChangeSet@1.2156.1.43, 2010-09-21 01:23:50-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.11 +1 -0 + Documentation updates from Dave Mills + + html/clock.html@1.2 +48 -15 + Documentation updates from Dave Mills + + html/miscopt.html@1.58 +5 -5 + Documentation updates from Dave Mills + + html/monopt.html@1.34 +3 -3 + Documentation updates from Dave Mills + + html/warp.html@1.5 +11 -18 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.42, 2010-09-20 23:22:02+00:00, davehart@shiny.ad.hartbrothers.com + Correct skipped merge of generated file ntp_parser.c + + ntpd/ntp_parser.c@1.61 +1174 -999 + Bison output of merged ntp_parser.y + +ChangeSet@1.2082.22.10, 2010-09-20 22:41:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1635] "filegen ... enable" is not default. + + ChangeLog@1.496.47.7 +4 -0 + [Bug 1635] "filegen ... enable" is not default. + + ntpd/ntp_config.c@1.241.1.5 +5 -2 + [Bug 1635] "filegen ... enable" is not default. + + ntpd/ntp_filegen.c@1.18 +5 -7 + nonfunctional cleanup (whitespace, use estrdup()). + + ntpd/ntp_parser.c@1.52.1.3 +383 -386 + Bison output for ntp_parser.y + + ntpd/ntp_parser.y@1.47.1.3 +4 -12 + [Bug 1635] "filegen ... enable" is not default. + + ntpd/ntp_util.c@1.75.1.1 +2 -2 + whitespace + +ChangeSet@1.2156.1.40, 2010-09-20 04:27:28+00:00, stenn@deacon.udel.edu + NTP_4_2_7P53 + TAG: NTP_4_2_7P53 + + ChangeLog@1.622.1.9 +1 -0 + NTP_4_2_7P53 + + ntpd/ntpd-opts.c@1.56 +2 -2 + NTP_4_2_7P53 + + ntpd/ntpd-opts.h@1.56 +3 -3 + NTP_4_2_7P53 + + ntpd/ntpd-opts.texi@1.55 +2 -2 + NTP_4_2_7P53 + + ntpd/ntpd.1@1.55 +2 -2 + NTP_4_2_7P53 + + ntpdc/ntpdc-opts.c@1.54 +2 -2 + NTP_4_2_7P53 + + ntpdc/ntpdc-opts.h@1.54 +3 -3 + NTP_4_2_7P53 + + ntpdc/ntpdc-opts.texi@1.54 +2 -2 + NTP_4_2_7P53 + + ntpdc/ntpdc.1@1.54 +2 -2 + NTP_4_2_7P53 + + ntpq/ntpq-opts.c@1.54 +2 -2 + NTP_4_2_7P53 + + ntpq/ntpq-opts.h@1.54 +3 -3 + NTP_4_2_7P53 + + ntpq/ntpq-opts.texi@1.54 +2 -2 + NTP_4_2_7P53 + + ntpq/ntpq.1@1.54 +2 -2 + NTP_4_2_7P53 + + ntpsnmpd/ntpsnmpd-opts.c@1.54 +2 -2 + NTP_4_2_7P53 + + ntpsnmpd/ntpsnmpd-opts.h@1.54 +3 -3 + NTP_4_2_7P53 + + ntpsnmpd/ntpsnmpd-opts.texi@1.54 +2 -2 + NTP_4_2_7P53 + + ntpsnmpd/ntpsnmpd.1@1.54 +2 -2 + NTP_4_2_7P53 + + packageinfo.sh@1.55 +1 -1 + NTP_4_2_7P53 + + sntp/sntp-opts.c@1.54 +2 -2 + NTP_4_2_7P53 + + sntp/sntp-opts.h@1.54 +3 -3 + NTP_4_2_7P53 + + sntp/sntp-opts.texi@1.54 +1 -1 + NTP_4_2_7P53 + + sntp/sntp.1@1.54 +2 -2 + NTP_4_2_7P53 + + sntp/sntp.html@1.54 +1 -1 + NTP_4_2_7P53 + + util/ntp-keygen-opts.c@1.51 +2 -2 + NTP_4_2_7P53 + + util/ntp-keygen-opts.h@1.51 +3 -3 + NTP_4_2_7P53 + + util/ntp-keygen-opts.texi@1.54 +2 -2 + NTP_4_2_7P53 + + util/ntp-keygen.1@1.54 +2 -2 + NTP_4_2_7P53 + +ChangeSet@1.2156.1.39, 2010-09-19 23:41:49-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.622.1.8 +1 -0 + Documentation updates from Dave Mills + + html/release.html@1.39 +2 -1 + Documentation updates from Dave Mills + + html/warp.html@1.4 +66 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.38, 2010-09-19 23:37:34-04:00, stenn@deacon.udel.edu + More initial convergence improvements from Dave Mills + + ChangeLog@1.622.1.7 +1 -0 + More initial convergence improvements from Dave Mills + + ntpd/ntp_loopfilter.c@1.157 +15 -12 + More initial convergence improvements from Dave Mills + +ChangeSet@1.2156.1.37, 2010-09-19 10:10:15+00:00, stenn@deacon.udel.edu + NTP_4_2_7P52 + TAG: NTP_4_2_7P52 + + ChangeLog@1.622.1.6 +1 -0 + NTP_4_2_7P52 + + ntpd/ntpd-opts.c@1.55 +2 -2 + NTP_4_2_7P52 + + ntpd/ntpd-opts.h@1.55 +3 -3 + NTP_4_2_7P52 + + ntpd/ntpd-opts.texi@1.54 +2 -2 + NTP_4_2_7P52 + + ntpd/ntpd.1@1.54 +2 -2 + NTP_4_2_7P52 + + ntpdc/ntpdc-opts.c@1.53 +2 -2 + NTP_4_2_7P52 + + ntpdc/ntpdc-opts.h@1.53 +3 -3 + NTP_4_2_7P52 + + ntpdc/ntpdc-opts.texi@1.53 +2 -2 + NTP_4_2_7P52 + + ntpdc/ntpdc.1@1.53 +2 -2 + NTP_4_2_7P52 + + ntpq/ntpq-opts.c@1.53 +2 -2 + NTP_4_2_7P52 + + ntpq/ntpq-opts.h@1.53 +3 -3 + NTP_4_2_7P52 + + ntpq/ntpq-opts.texi@1.53 +2 -2 + NTP_4_2_7P52 + + ntpq/ntpq.1@1.53 +2 -2 + NTP_4_2_7P52 + + ntpsnmpd/ntpsnmpd-opts.c@1.53 +2 -2 + NTP_4_2_7P52 + + ntpsnmpd/ntpsnmpd-opts.h@1.53 +3 -3 + NTP_4_2_7P52 + + ntpsnmpd/ntpsnmpd-opts.texi@1.53 +2 -2 + NTP_4_2_7P52 + + ntpsnmpd/ntpsnmpd.1@1.53 +2 -2 + NTP_4_2_7P52 + + packageinfo.sh@1.54 +1 -1 + NTP_4_2_7P52 + + sntp/sntp-opts.c@1.53 +2 -2 + NTP_4_2_7P52 + + sntp/sntp-opts.h@1.53 +3 -3 + NTP_4_2_7P52 + + sntp/sntp-opts.texi@1.53 +1 -1 + NTP_4_2_7P52 + + sntp/sntp.1@1.53 +2 -2 + NTP_4_2_7P52 + + sntp/sntp.html@1.53 +1 -1 + NTP_4_2_7P52 + + util/ntp-keygen-opts.c@1.50 +2 -2 + NTP_4_2_7P52 + + util/ntp-keygen-opts.h@1.50 +3 -3 + NTP_4_2_7P52 + + util/ntp-keygen-opts.texi@1.53 +2 -2 + NTP_4_2_7P52 + + util/ntp-keygen.1@1.53 +2 -2 + NTP_4_2_7P52 + +ChangeSet@1.2156.1.36, 2010-09-18 18:40:06-04:00, stenn@deacon.udel.edu + Initial convergence improvements from Dave Mills + + ChangeLog@1.622.1.5 +1 -0 + Initial convergence improvements from Dave Mills + + ntpd/ntp_loopfilter.c@1.156 +52 -53 + Initial convergence improvements from Dave Mills + +ChangeSet@1.2156.1.35, 2010-09-18 10:10:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P51 + TAG: NTP_4_2_7P51 + + ChangeLog@1.622.1.4 +1 -0 + NTP_4_2_7P51 + + ntpd/ntpd-opts.c@1.54 +2 -2 + NTP_4_2_7P51 + + ntpd/ntpd-opts.h@1.54 +3 -3 + NTP_4_2_7P51 + + ntpd/ntpd-opts.texi@1.53 +2 -2 + NTP_4_2_7P51 + + ntpd/ntpd.1@1.53 +2 -2 + NTP_4_2_7P51 + + ntpdc/ntpdc-opts.c@1.52 +2 -2 + NTP_4_2_7P51 + + ntpdc/ntpdc-opts.h@1.52 +3 -3 + NTP_4_2_7P51 + + ntpdc/ntpdc-opts.texi@1.52 +2 -2 + NTP_4_2_7P51 + + ntpdc/ntpdc.1@1.52 +2 -2 + NTP_4_2_7P51 + + ntpq/ntpq-opts.c@1.52 +2 -2 + NTP_4_2_7P51 + + ntpq/ntpq-opts.h@1.52 +3 -3 + NTP_4_2_7P51 + + ntpq/ntpq-opts.texi@1.52 +2 -2 + NTP_4_2_7P51 + + ntpq/ntpq.1@1.52 +2 -2 + NTP_4_2_7P51 + + ntpsnmpd/ntpsnmpd-opts.c@1.52 +2 -2 + NTP_4_2_7P51 + + ntpsnmpd/ntpsnmpd-opts.h@1.52 +3 -3 + NTP_4_2_7P51 + + ntpsnmpd/ntpsnmpd-opts.texi@1.52 +2 -2 + NTP_4_2_7P51 + + ntpsnmpd/ntpsnmpd.1@1.52 +2 -2 + NTP_4_2_7P51 + + packageinfo.sh@1.53 +1 -1 + NTP_4_2_7P51 + + sntp/sntp-opts.c@1.52 +2 -2 + NTP_4_2_7P51 + + sntp/sntp-opts.h@1.52 +3 -3 + NTP_4_2_7P51 + + sntp/sntp-opts.texi@1.52 +1 -1 + NTP_4_2_7P51 + + sntp/sntp.1@1.52 +2 -2 + NTP_4_2_7P51 + + sntp/sntp.html@1.52 +1 -1 + NTP_4_2_7P51 + + util/ntp-keygen-opts.c@1.49 +2 -2 + NTP_4_2_7P51 + + util/ntp-keygen-opts.h@1.49 +3 -3 + NTP_4_2_7P51 + + util/ntp-keygen-opts.texi@1.52 +2 -2 + NTP_4_2_7P51 + + util/ntp-keygen.1@1.52 +2 -2 + NTP_4_2_7P51 + +ChangeSet@1.2082.22.9, 2010-09-18 05:42:06+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_RC1 + TAG: NTP_4_2_6P3_RC1 + + ChangeLog@1.496.47.6 +1 -0 + NTP_4_2_6P3_RC1 + + ntpd/ntpd-opts.c@1.248.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpd/ntpd-opts.h@1.248.17.1 +3 -3 + NTP_4_2_6P3_RC1 + + ntpd/ntpd-opts.texi@1.246.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpd/ntpd.1@1.246.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpdc/ntpdc-opts.c@1.244.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpdc/ntpdc-opts.h@1.244.17.1 +3 -3 + NTP_4_2_6P3_RC1 + + ntpdc/ntpdc-opts.texi@1.243.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpdc/ntpdc.1@1.243.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpq/ntpq-opts.c@1.245.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpq/ntpq-opts.h@1.245.17.1 +3 -3 + NTP_4_2_6P3_RC1 + + ntpq/ntpq-opts.texi@1.244.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpq/ntpq.1@1.244.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.18.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.18.1 +3 -3 + NTP_4_2_6P3_RC1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.18.1 +2 -2 + NTP_4_2_6P3_RC1 + + ntpsnmpd/ntpsnmpd.1@1.122.18.1 +2 -2 + NTP_4_2_6P3_RC1 + + packageinfo.sh@1.255.19.2 +1 -1 + NTP_4_2_6P3_RC1 + + sntp/sntp-opts.c@1.117.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + sntp/sntp-opts.h@1.117.17.1 +3 -3 + NTP_4_2_6P3_RC1 + + sntp/sntp-opts.texi@1.117.17.1 +1 -1 + NTP_4_2_6P3_RC1 + + sntp/sntp.1@1.117.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + sntp/sntp.html@1.7.17.1 +1 -1 + NTP_4_2_6P3_RC1 + + util/ntp-keygen-opts.c@1.247.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + util/ntp-keygen-opts.h@1.247.17.1 +3 -3 + NTP_4_2_6P3_RC1 + + util/ntp-keygen-opts.texi@1.246.17.1 +2 -2 + NTP_4_2_6P3_RC1 + + util/ntp-keygen.1@1.246.17.1 +2 -2 + NTP_4_2_6P3_RC1 + +ChangeSet@1.2082.22.8, 2010-09-18 01:25:26-04:00, stenn@deacon.udel.edu + 4.2.6p3-RC1 + + packageinfo.sh@1.255.19.1 +1 -1 + 4.2.6p3-RC1 + +ChangeSet@1.2082.22.7, 2010-09-17 04:20:03+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1344] ntpd on Windows exits without logging cause. + + + ChangeLog@1.496.47.5 +4 -0 + [Bug 1344] ntpd on Windows exits without logging cause. + + + ports/winnt/ntpd/nt_clockstuff.c@1.38.1.3 +4 -2 + [Bug 1344] ntpd on Windows exits without logging cause. + + +ChangeSet@1.2156.1.32, 2010-09-16 19:32:11+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1629] 4.2.7p50 configure.ac changes invalidate config.cache. + [Bug 1630] 4.2.7p50 cannot bootstrap on Autoconf 2.61. + + + ChangeLog@1.622.1.1 +2 -0 + [Bug 1629] 4.2.7p50 configure.ac changes invalidate config.cache. + [Bug 1630] 4.2.7p50 cannot bootstrap on Autoconf 2.61. + + + configure.ac@1.483.1.7 +34 -36 + [Bug 1629] 4.2.7p50 configure.ac changes invalidate config.cache. + [Bug 1630] 4.2.7p50 cannot bootstrap on Autoconf 2.61. + + + sntp/configure.ac@1.36 +27 -13 + [Bug 1629] 4.2.7p50 configure.ac changes invalidate config.cache. + [Bug 1630] 4.2.7p50 cannot bootstrap on Autoconf 2.61. + + +ChangeSet@1.2156.1.31, 2010-09-16 06:21:34+00:00, stenn@deacon.udel.edu + NTP_4_2_7P50 + TAG: NTP_4_2_7P50 + + ChangeLog@1.622 +1 -0 + NTP_4_2_7P50 + + ntpd/ntpd-opts.c@1.53 +2 -2 + NTP_4_2_7P50 + + ntpd/ntpd-opts.h@1.53 +3 -3 + NTP_4_2_7P50 + + ntpd/ntpd-opts.texi@1.52 +2 -2 + NTP_4_2_7P50 + + ntpd/ntpd.1@1.52 +2 -2 + NTP_4_2_7P50 + + ntpdc/ntpdc-opts.c@1.51 +2 -2 + NTP_4_2_7P50 + + ntpdc/ntpdc-opts.h@1.51 +3 -3 + NTP_4_2_7P50 + + ntpdc/ntpdc-opts.texi@1.51 +2 -2 + NTP_4_2_7P50 + + ntpdc/ntpdc.1@1.51 +2 -2 + NTP_4_2_7P50 + + ntpq/ntpq-opts.c@1.51 +2 -2 + NTP_4_2_7P50 + + ntpq/ntpq-opts.h@1.51 +3 -3 + NTP_4_2_7P50 + + ntpq/ntpq-opts.texi@1.51 +2 -2 + NTP_4_2_7P50 + + ntpq/ntpq.1@1.51 +2 -2 + NTP_4_2_7P50 + + ntpsnmpd/ntpsnmpd-opts.c@1.51 +2 -2 + NTP_4_2_7P50 + + ntpsnmpd/ntpsnmpd-opts.h@1.51 +3 -3 + NTP_4_2_7P50 + + ntpsnmpd/ntpsnmpd-opts.texi@1.51 +2 -2 + NTP_4_2_7P50 + + ntpsnmpd/ntpsnmpd.1@1.51 +2 -2 + NTP_4_2_7P50 + + packageinfo.sh@1.52 +1 -1 + NTP_4_2_7P50 + + sntp/sntp-opts.c@1.51 +2 -2 + NTP_4_2_7P50 + + sntp/sntp-opts.h@1.51 +3 -3 + NTP_4_2_7P50 + + sntp/sntp-opts.texi@1.51 +1 -1 + NTP_4_2_7P50 + + sntp/sntp.1@1.51 +2 -2 + NTP_4_2_7P50 + + sntp/sntp.html@1.51 +1 -1 + NTP_4_2_7P50 + + util/ntp-keygen-opts.c@1.48 +2 -2 + NTP_4_2_7P50 + + util/ntp-keygen-opts.h@1.48 +3 -3 + NTP_4_2_7P50 + + util/ntp-keygen-opts.texi@1.51 +2 -2 + NTP_4_2_7P50 + + util/ntp-keygen.1@1.51 +2 -2 + NTP_4_2_7P50 + +ChangeSet@1.2156.1.30, 2010-09-16 01:59:29-04:00, stenn@deacon.udel.edu + Clean up NTP_LIB_M + + ChangeLog@1.621 +1 -0 + Clean up NTP_LIB_M + + m4/ntp_lib_m.m4@1.3 +2 -0 + Clean up NTP_LIB_M + +ChangeSet@1.2156.1.29, 2010-09-16 01:57:24-04:00, stenn@deacon.udel.edu + [Bug 1628] Clean up -lxnet/-lsocket usage for (open)solaris + + configure.ac@1.483.1.6 +14 -5 + [Bug 1628] Clean up -lxnet/-lsocket usage for (open)solaris + +ChangeSet@1.2156.1.28, 2010-09-15 23:49:40-04:00, stenn@deacon.udel.edu + [Bug 1628] Clean up -lxnet/-lsocket usage for (open)solaris + + ChangeLog@1.620 +1 -0 + [Bug 1628] Clean up -lxnet/-lsocket usage for (open)solaris + + configure.ac@1.483.1.5 +7 -4 + [Bug 1628] Clean up -lxnet/-lsocket usage for (open)solaris + +ChangeSet@1.2156.1.27, 2010-09-13 05:32:06+00:00, stenn@deacon.udel.edu + NTP_4_2_7P49 + TAG: NTP_4_2_7P49 + + ChangeLog@1.619 +1 -0 + NTP_4_2_7P49 + + ntpd/ntpd-opts.c@1.52 +2 -2 + NTP_4_2_7P49 + + ntpd/ntpd-opts.h@1.52 +3 -3 + NTP_4_2_7P49 + + ntpd/ntpd-opts.texi@1.51 +2 -2 + NTP_4_2_7P49 + + ntpd/ntpd.1@1.51 +2 -2 + NTP_4_2_7P49 + + ntpdc/ntpdc-opts.c@1.50 +2 -2 + NTP_4_2_7P49 + + ntpdc/ntpdc-opts.h@1.50 +3 -3 + NTP_4_2_7P49 + + ntpdc/ntpdc-opts.texi@1.50 +2 -2 + NTP_4_2_7P49 + + ntpdc/ntpdc.1@1.50 +2 -2 + NTP_4_2_7P49 + + ntpq/ntpq-opts.c@1.50 +2 -2 + NTP_4_2_7P49 + + ntpq/ntpq-opts.h@1.50 +3 -3 + NTP_4_2_7P49 + + ntpq/ntpq-opts.texi@1.50 +2 -2 + NTP_4_2_7P49 + + ntpq/ntpq.1@1.50 +2 -2 + NTP_4_2_7P49 + + ntpsnmpd/ntpsnmpd-opts.c@1.50 +2 -2 + NTP_4_2_7P49 + + ntpsnmpd/ntpsnmpd-opts.h@1.50 +3 -3 + NTP_4_2_7P49 + + ntpsnmpd/ntpsnmpd-opts.texi@1.50 +2 -2 + NTP_4_2_7P49 + + ntpsnmpd/ntpsnmpd.1@1.50 +2 -2 + NTP_4_2_7P49 + + packageinfo.sh@1.51 +1 -1 + NTP_4_2_7P49 + + sntp/sntp-opts.c@1.50 +2 -2 + NTP_4_2_7P49 + + sntp/sntp-opts.h@1.50 +3 -3 + NTP_4_2_7P49 + + sntp/sntp-opts.texi@1.50 +1 -1 + NTP_4_2_7P49 + + sntp/sntp.1@1.50 +2 -2 + NTP_4_2_7P49 + + sntp/sntp.html@1.50 +1 -1 + NTP_4_2_7P49 + + util/ntp-keygen-opts.c@1.47 +2 -2 + NTP_4_2_7P49 + + util/ntp-keygen-opts.h@1.47 +3 -3 + NTP_4_2_7P49 + + util/ntp-keygen-opts.texi@1.50 +2 -2 + NTP_4_2_7P49 + + util/ntp-keygen.1@1.50 +2 -2 + NTP_4_2_7P49 + +ChangeSet@1.2156.1.26, 2010-09-13 01:21:03-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.618 +1 -0 + Documentation updates from Dave Mills + + html/assoc.html@1.32 +5 -5 + Documentation updates from Dave Mills + + html/authopt.html@1.63 +3 -3 + Documentation updates from Dave Mills + + html/autokey.html@1.3 +3 -3 + Documentation updates from Dave Mills + + html/confopt.html@1.51 +3 -3 + Documentation updates from Dave Mills + + html/keygen.html@1.21 +11 -58 + Documentation updates from Dave Mills + + html/miscopt.html@1.57 +9 -14 + Documentation updates from Dave Mills + + html/ntp_conf.html@1.5 +2 -2 + Documentation updates from Dave Mills + + html/ntpd.html@1.53 +0 -1 + Documentation updates from Dave Mills + + html/pps.html@1.22 +3 -2 + Documentation updates from Dave Mills + + html/quick.html@1.22 +3 -3 + Documentation updates from Dave Mills + + html/rate.html@1.8 +0 -2 + Documentation updates from Dave Mills + + html/release.html@1.38 +3 -3 + Documentation updates from Dave Mills + + html/warp.html@1.3 +10 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.25, 2010-09-12 10:10:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P48 + TAG: NTP_4_2_7P48 + + ChangeLog@1.617 +1 -0 + NTP_4_2_7P48 + + ntpd/ntpd-opts.c@1.51 +2 -2 + NTP_4_2_7P48 + + ntpd/ntpd-opts.h@1.51 +3 -3 + NTP_4_2_7P48 + + ntpd/ntpd-opts.texi@1.50 +2 -2 + NTP_4_2_7P48 + + ntpd/ntpd.1@1.50 +2 -2 + NTP_4_2_7P48 + + ntpdc/ntpdc-opts.c@1.49 +2 -2 + NTP_4_2_7P48 + + ntpdc/ntpdc-opts.h@1.49 +3 -3 + NTP_4_2_7P48 + + ntpdc/ntpdc-opts.texi@1.49 +2 -2 + NTP_4_2_7P48 + + ntpdc/ntpdc.1@1.49 +2 -2 + NTP_4_2_7P48 + + ntpq/ntpq-opts.c@1.49 +2 -2 + NTP_4_2_7P48 + + ntpq/ntpq-opts.h@1.49 +3 -3 + NTP_4_2_7P48 + + ntpq/ntpq-opts.texi@1.49 +2 -2 + NTP_4_2_7P48 + + ntpq/ntpq.1@1.49 +2 -2 + NTP_4_2_7P48 + + ntpsnmpd/ntpsnmpd-opts.c@1.49 +2 -2 + NTP_4_2_7P48 + + ntpsnmpd/ntpsnmpd-opts.h@1.49 +3 -3 + NTP_4_2_7P48 + + ntpsnmpd/ntpsnmpd-opts.texi@1.49 +2 -2 + NTP_4_2_7P48 + + ntpsnmpd/ntpsnmpd.1@1.49 +2 -2 + NTP_4_2_7P48 + + packageinfo.sh@1.50 +1 -1 + NTP_4_2_7P48 + + sntp/sntp-opts.c@1.49 +2 -2 + NTP_4_2_7P48 + + sntp/sntp-opts.h@1.49 +3 -3 + NTP_4_2_7P48 + + sntp/sntp-opts.texi@1.49 +1 -1 + NTP_4_2_7P48 + + sntp/sntp.1@1.49 +2 -2 + NTP_4_2_7P48 + + sntp/sntp.html@1.49 +1 -1 + NTP_4_2_7P48 + + util/ntp-keygen-opts.c@1.46 +2 -2 + NTP_4_2_7P48 + + util/ntp-keygen-opts.h@1.46 +3 -3 + NTP_4_2_7P48 + + util/ntp-keygen-opts.texi@1.49 +2 -2 + NTP_4_2_7P48 + + util/ntp-keygen.1@1.49 +2 -2 + NTP_4_2_7P48 + +ChangeSet@1.2156.1.24, 2010-09-11 17:53:59-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.616 +1 -0 + Documentation updates from Dave Mills + + html/accopt.html@1.38 +5 -5 + Documentation updates from Dave Mills + + html/authentic.html@1.2 +10 -8 + Documentation updates from Dave Mills + + html/authopt.html@1.62 +1 -2 + Documentation updates from Dave Mills + + html/autokey.html@1.2 +3 -2 + Documentation updates from Dave Mills + + html/index.html@1.43 +8 -35 + Documentation updates from Dave Mills + + html/monopt.html@1.33 +2 -2 + Documentation updates from Dave Mills + + html/rate.html@1.7 +10 -2 + Documentation updates from Dave Mills + + html/scripts/miscopt.txt@1.6 +0 -1 + Documentation updates from Dave Mills + + html/warp.html@1.2 +16 -7 + Documentation updates from Dave Mills + +ChangeSet@1.2156.10.2, 2010-09-11 10:16:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P47 + TAG: NTP_4_2_7P47 + + ChangeLog@1.614 +1 -0 + NTP_4_2_7P47 + + ntpd/ntpd-opts.c@1.50 +2 -2 + NTP_4_2_7P47 + + ntpd/ntpd-opts.h@1.50 +3 -3 + NTP_4_2_7P47 + + ntpd/ntpd-opts.texi@1.49 +2 -2 + NTP_4_2_7P47 + + ntpd/ntpd.1@1.49 +2 -2 + NTP_4_2_7P47 + + ntpdc/ntpdc-opts.c@1.48 +2 -2 + NTP_4_2_7P47 + + ntpdc/ntpdc-opts.h@1.48 +3 -3 + NTP_4_2_7P47 + + ntpdc/ntpdc-opts.texi@1.48 +2 -2 + NTP_4_2_7P47 + + ntpdc/ntpdc.1@1.48 +2 -2 + NTP_4_2_7P47 + + ntpq/ntpq-opts.c@1.48 +2 -2 + NTP_4_2_7P47 + + ntpq/ntpq-opts.h@1.48 +3 -3 + NTP_4_2_7P47 + + ntpq/ntpq-opts.texi@1.48 +2 -2 + NTP_4_2_7P47 + + ntpq/ntpq.1@1.48 +2 -2 + NTP_4_2_7P47 + + ntpsnmpd/ntpsnmpd-opts.c@1.48 +2 -2 + NTP_4_2_7P47 + + ntpsnmpd/ntpsnmpd-opts.h@1.48 +3 -3 + NTP_4_2_7P47 + + ntpsnmpd/ntpsnmpd-opts.texi@1.48 +2 -2 + NTP_4_2_7P47 + + ntpsnmpd/ntpsnmpd.1@1.48 +2 -2 + NTP_4_2_7P47 + + packageinfo.sh@1.49 +1 -1 + NTP_4_2_7P47 + + sntp/sntp-opts.c@1.48 +2 -2 + NTP_4_2_7P47 + + sntp/sntp-opts.h@1.48 +3 -3 + NTP_4_2_7P47 + + sntp/sntp-opts.texi@1.48 +1 -1 + NTP_4_2_7P47 + + sntp/sntp.1@1.48 +2 -2 + NTP_4_2_7P47 + + sntp/sntp.html@1.48 +1 -1 + NTP_4_2_7P47 + + util/ntp-keygen-opts.c@1.45 +5 -5 + NTP_4_2_7P47 + + util/ntp-keygen-opts.h@1.45 +4 -4 + NTP_4_2_7P47 + + util/ntp-keygen-opts.texi@1.48 +17 -17 + NTP_4_2_7P47 + + util/ntp-keygen.1@1.48 +2 -2 + NTP_4_2_7P47 + +ChangeSet@1.2082.22.6, 2010-09-11 06:50:03+00:00, stenn@deacon.udel.edu + NTP_4_2_6P3_BETA1 + TAG: NTP_4_2_6P3_BETA1 + + ChangeLog@1.496.47.4 +1 -0 + NTP_4_2_6P3_BETA1 + + ntpd/ntpd-opts.c@1.248.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpd/ntpd-opts.h@1.248.16.1 +3 -3 + NTP_4_2_6P3_BETA1 + + ntpd/ntpd-opts.texi@1.246.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpd/ntpd.1@1.246.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpdc/ntpdc-opts.c@1.244.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpdc/ntpdc-opts.h@1.244.16.1 +3 -3 + NTP_4_2_6P3_BETA1 + + ntpdc/ntpdc-opts.texi@1.243.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpdc/ntpdc.1@1.243.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpq/ntpq-opts.c@1.245.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpq/ntpq-opts.h@1.245.16.1 +3 -3 + NTP_4_2_6P3_BETA1 + + ntpq/ntpq-opts.texi@1.244.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpq/ntpq.1@1.244.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.17.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.17.1 +3 -3 + NTP_4_2_6P3_BETA1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.17.1 +2 -2 + NTP_4_2_6P3_BETA1 + + ntpsnmpd/ntpsnmpd.1@1.122.17.1 +2 -2 + NTP_4_2_6P3_BETA1 + + packageinfo.sh@1.255.18.1 +3 -3 + NTP_4_2_6P3_BETA1 + + sntp/sntp-opts.c@1.117.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + sntp/sntp-opts.h@1.117.16.1 +3 -3 + NTP_4_2_6P3_BETA1 + + sntp/sntp-opts.texi@1.117.16.1 +1 -1 + NTP_4_2_6P3_BETA1 + + sntp/sntp.1@1.117.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + sntp/sntp.html@1.7.16.1 +1 -1 + NTP_4_2_6P3_BETA1 + + util/ntp-keygen-opts.c@1.247.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + util/ntp-keygen-opts.h@1.247.16.1 +3 -3 + NTP_4_2_6P3_BETA1 + + util/ntp-keygen-opts.texi@1.246.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + + util/ntp-keygen.1@1.246.16.1 +2 -2 + NTP_4_2_6P3_BETA1 + +ChangeSet@1.2082.22.5, 2010-09-11 02:14:22-04:00, stenn@deacon.udel.edu + temporary mirror trigger update + + BitKeeper/triggers/2mirrors@1.7 +2 -1 + temporary mirror trigger update + +ChangeSet@1.2156.1.21, 2010-09-11 01:56:46-04:00, stenn@deacon.udel.edu + Documentation updates from Dave Mills + + BitKeeper/deleted/.del-description.jpg~1683404a7f1dcae@1.2 +0 -0 + Delete: html/description_files/description.jpg + + BitKeeper/deleted/.del-gadget.html~155e509d29e44428@1.5 +0 -0 + Delete: html/gadget.html + + ChangeLog@1.613 +1 -0 + Documentation updates from Dave Mills + + html/access.html@1.1 +50 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/access.html + + html/access.html@1.0 +0 -0 + + html/accopt.html@1.37 +65 -184 + Documentation updates from Dave Mills + + html/assoc.html@1.31 +83 -94 + Documentation updates from Dave Mills + + html/audio.html@1.22 +178 -179 + Documentation updates from Dave Mills + + html/authentic.html@1.1 +54 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/authentic.html + + html/authentic.html@1.0 +0 -0 + + html/authopt.html@1.61 +68 -473 + Documentation updates from Dave Mills + + html/autokey.html@1.1 +206 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/autokey.html + + html/autokey.html@1.0 +0 -0 + + html/bugs.html@1.6 +28 -30 + Documentation updates from Dave Mills + + html/build.html@1.24 +55 -57 + Documentation updates from Dave Mills + + html/clock.html@1.1 +31 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/clock.html + + html/clock.html@1.0 +0 -0 + + html/clockopt.html@1.23 +55 -67 + Documentation updates from Dave Mills + + html/comdex.html@1.3 +24 -29 + Documentation updates from Dave Mills + + html/confopt.html@1.50 +13 -37 + Documentation updates from Dave Mills + + html/copyright.html@1.51 +75 -79 + Documentation updates from Dave Mills + + html/debug.html@1.30 +90 -94 + Documentation updates from Dave Mills + + html/decode.html@1.15 +628 -806 + Documentation updates from Dave Mills + + html/discover.html@1.1 +72 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/discover.html + + html/discover.html@1.0 +0 -0 + + html/drivers/driver1.html@1.17 +48 -48 + Documentation updates from Dave Mills + + html/drivers/driver10.html@1.13 +51 -51 + Documentation updates from Dave Mills + + html/drivers/driver11.html@1.13 +60 -60 + Documentation updates from Dave Mills + + html/drivers/driver12.html@1.12 +47 -47 + Documentation updates from Dave Mills + + html/drivers/driver18.html@1.17 +80 -80 + Documentation updates from Dave Mills + + html/drivers/driver19.html@1.12 +53 -53 + Documentation updates from Dave Mills + + html/drivers/driver22.html@1.19 +81 -93 + Documentation updates from Dave Mills + + html/drivers/driver3.html@1.12 +52 -52 + Documentation updates from Dave Mills + + html/drivers/driver36.html@1.33 +148 -145 + Documentation updates from Dave Mills + + html/drivers/driver4.html@1.16 +39 -71 + Documentation updates from Dave Mills + + html/drivers/driver6.html@1.26 +79 -74 + Documentation updates from Dave Mills + + html/drivers/driver7.html@1.28 +123 -129 + Documentation updates from Dave Mills + + html/extern.html@1.16 +46 -48 + Documentation updates from Dave Mills + + html/hints.html@1.18 +20 -22 + Documentation updates from Dave Mills + + html/howto.html@1.23 +106 -114 + Documentation updates from Dave Mills + + html/huffpuff.html@1.1 +20 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/huffpuff.html + + html/huffpuff.html@1.0 +0 -0 + + html/index.html@1.42 +97 -89 + Documentation updates from Dave Mills + + html/kern.html@1.18 +29 -31 + Documentation updates from Dave Mills + + html/kernpps.html@1.3 +46 -47 + Documentation updates from Dave Mills + + html/keygen.html@1.20 +103 -174 + Documentation updates from Dave Mills + + html/leap.html@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/leap.html + + html/leap.html@1.0 +0 -0 + + html/miscopt.html@1.56 +164 -167 + Documentation updates from Dave Mills + + html/monopt.html@1.32 +486 -487 + Documentation updates from Dave Mills + + html/msyslog.html@1.10 +127 -123 + Documentation updates from Dave Mills + + html/ntp_conf.html@1.4 +171 -171 + Documentation updates from Dave Mills + + html/ntpd.html@1.52 +166 -223 + Documentation updates from Dave Mills + + html/ntpdate.html@1.19 +67 -69 + Documentation updates from Dave Mills + + html/ntpdc.html@1.32 +170 -213 + Documentation updates from Dave Mills + + html/ntpdsim.html@1.8 +61 -63 + Documentation updates from Dave Mills + + html/ntpdsim_new.html@1.5 +55 -55 + Documentation updates from Dave Mills + + html/ntpq.html@1.41 +639 -655 + Documentation updates from Dave Mills + + html/ntptime.html@1.17 +44 -46 + Documentation updates from Dave Mills + + html/ntptrace.html@1.15 +41 -43 + Documentation updates from Dave Mills + + html/orphan.html@1.1 +36 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/orphan.html + + html/orphan.html@1.0 +0 -0 + + html/pic/fig_3_1.gif@1.1 +528 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/fig_3_1.gif + + html/pic/fig_3_1.gif@1.0 +0 -0 + + html/pic/group.gif@1.1 +63 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/group.gif + + html/pic/group.gif@1.0 +0 -0 + + html/pps.html@1.21 +44 -47 + Documentation updates from Dave Mills + + html/prefer.html@1.23 +61 -112 + Documentation updates from Dave Mills + + html/quick.html@1.21 +43 -44 + Documentation updates from Dave Mills + + html/rate.html@1.6 +53 -69 + Documentation updates from Dave Mills + + html/rdebug.html@1.17 +29 -29 + Documentation updates from Dave Mills + + html/refclock.html@1.35 +89 -88 + Documentation updates from Dave Mills + + html/release.html@1.37 +66 -59 + Documentation updates from Dave Mills + + html/scripts/accopt.txt@1.2 +4 -4 + Documentation updates from Dave Mills + + html/scripts/audio.txt@1.2 +6 -6 + Documentation updates from Dave Mills + + html/scripts/authopt.txt@1.3 +9 -9 + Documentation updates from Dave Mills + + html/scripts/clockopt.txt@1.2 +3 -3 + Documentation updates from Dave Mills + + html/scripts/command.txt@1.3 +9 -11 + Documentation updates from Dave Mills + + html/scripts/config.txt@1.3 +5 -7 + Documentation updates from Dave Mills + + html/scripts/confopt.txt@1.3 +11 -11 + Documentation updates from Dave Mills + + html/scripts/external.txt@1.3 +17 -15 + Documentation updates from Dave Mills + + html/scripts/hand.txt@1.1 +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/hand.txt + + html/scripts/hand.txt@1.0 +0 -0 + + html/scripts/install.txt@1.3 +10 -12 + Documentation updates from Dave Mills + + html/scripts/manual.txt@1.3 +13 -13 + Documentation updates from Dave Mills + + html/scripts/misc.txt@1.2 +9 -9 + Documentation updates from Dave Mills + + html/scripts/miscopt.txt@1.5 +19 -19 + Documentation updates from Dave Mills + + html/scripts/monopt.txt@1.2 +4 -4 + Documentation updates from Dave Mills + + html/scripts/refclock.txt@1.2 +6 -6 + Documentation updates from Dave Mills + + html/scripts/special.txt@1.1 +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/special.txt + + html/scripts/special.txt@1.0 +0 -0 + + html/sitemap.html@1.4 +31 -34 + Documentation updates from Dave Mills + + html/sntp.html@1.7 +52 -54 + Documentation updates from Dave Mills + + html/tickadj.html@1.16 +43 -44 + Documentation updates from Dave Mills + + html/warp.html@1.1 +51 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/warp.html + + html/warp.html@1.0 +0 -0 + + html/xleave.html@1.5 +28 -39 + Documentation updates from Dave Mills + +ChangeSet@1.2156.1.20, 2010-09-11 01:16:34-04:00, stenn@deacon.udel.edu + [Bug 1616] refclock_acts.c: if (pp->leap == 2) is always false. + + ChangeLog@1.612 +1 -0 + [Bug 1616] refclock_acts.c: if (pp->leap == 2) is always false. + + ntpd/refclock_acts.c@1.39 +1 -1 + [Bug 1616] refclock_acts.c: if (pp->leap == 2) is always false. + +ChangeSet@1.2156.1.19, 2010-09-11 01:11:46-04:00, stenn@pogo.udel.edu + [Bug 1620] [Backward Incompatible] "discard minimum" value should be in seconds, not log2 seconds + + ChangeLog@1.611 +2 -0 + [Bug 1620] [Backward Incompatible] "discard minimum" value should be in seconds, not log2 seconds + + include/ntp.h@1.181 +1 -1 + [Bug 1620] [Backward Incompatible] "discard minimum" value should be in seconds, not log2 seconds + + ntpd/ntp_monitor.c@1.36 +1 -1 + [Bug 1620] [Backward Incompatible] "discard minimum" value should be in seconds, not log2 seconds + + ntpd/ntp_proto.c@1.302 +4 -6 + [Bug 1620] [Backward Incompatible] "discard minimum" value should be in seconds, not log2 seconds + +ChangeSet@1.2156.3.15, 2010-09-10 10:12:03+00:00, stenn@deacon.udel.edu + NTP_4_2_7P46 + TAG: NTP_4_2_7P46 + + ChangeLog@1.607.8.5 +1 -0 + NTP_4_2_7P46 + + ntpd/ntpd-opts.c@1.49 +2 -2 + NTP_4_2_7P46 + + ntpd/ntpd-opts.h@1.49 +3 -3 + NTP_4_2_7P46 + + ntpd/ntpd-opts.texi@1.48 +2 -2 + NTP_4_2_7P46 + + ntpd/ntpd.1@1.48 +2 -2 + NTP_4_2_7P46 + + ntpdc/ntpdc-opts.c@1.47 +2 -2 + NTP_4_2_7P46 + + ntpdc/ntpdc-opts.h@1.47 +3 -3 + NTP_4_2_7P46 + + ntpdc/ntpdc-opts.texi@1.47 +2 -2 + NTP_4_2_7P46 + + ntpdc/ntpdc.1@1.47 +2 -2 + NTP_4_2_7P46 + + ntpq/ntpq-opts.c@1.47 +2 -2 + NTP_4_2_7P46 + + ntpq/ntpq-opts.h@1.47 +3 -3 + NTP_4_2_7P46 + + ntpq/ntpq-opts.texi@1.47 +2 -2 + NTP_4_2_7P46 + + ntpq/ntpq.1@1.47 +2 -2 + NTP_4_2_7P46 + + ntpsnmpd/ntpsnmpd-opts.c@1.47 +2 -2 + NTP_4_2_7P46 + + ntpsnmpd/ntpsnmpd-opts.h@1.47 +3 -3 + NTP_4_2_7P46 + + ntpsnmpd/ntpsnmpd-opts.texi@1.47 +2 -2 + NTP_4_2_7P46 + + ntpsnmpd/ntpsnmpd.1@1.47 +2 -2 + NTP_4_2_7P46 + + packageinfo.sh@1.48 +1 -1 + NTP_4_2_7P46 + + sntp/sntp-opts.c@1.47 +2 -2 + NTP_4_2_7P46 + + sntp/sntp-opts.h@1.47 +3 -3 + NTP_4_2_7P46 + + sntp/sntp-opts.texi@1.47 +1 -1 + NTP_4_2_7P46 + + sntp/sntp.1@1.47 +2 -2 + NTP_4_2_7P46 + + sntp/sntp.html@1.47 +1 -1 + NTP_4_2_7P46 + + util/ntp-keygen-opts.c@1.41.1.6 +2 -2 + NTP_4_2_7P46 + + util/ntp-keygen-opts.h@1.41.1.6 +3 -3 + NTP_4_2_7P46 + + util/ntp-keygen-opts.texi@1.47 +2 -2 + NTP_4_2_7P46 + + util/ntp-keygen.1@1.47 +2 -2 + NTP_4_2_7P46 + +ChangeSet@1.2156.3.14, 2010-09-10 00:26:46-04:00, stenn@deacon.udel.edu + Use AC_SEARCH_LIBS instead of AC_CHECK_LIB for NTP_LIB_M + + ChangeLog@1.607.8.4 +1 -0 + Use AC_SEARCH_LIBS instead of AC_CHECK_LIB for NTP_LIB_M + + m4/ntp_lib_m.m4@1.2 +1 -1 + Use AC_SEARCH_LIBS instead of AC_CHECK_LIB for NTP_LIB_M + +ChangeSet@1.2156.3.13, 2010-09-05 10:11:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P45 + TAG: NTP_4_2_7P45 + + ChangeLog@1.607.8.3 +1 -0 + NTP_4_2_7P45 + + ntpd/ntpd-opts.c@1.48 +2 -2 + NTP_4_2_7P45 + + ntpd/ntpd-opts.h@1.48 +3 -3 + NTP_4_2_7P45 + + ntpd/ntpd-opts.texi@1.47 +2 -2 + NTP_4_2_7P45 + + ntpd/ntpd.1@1.47 +2 -2 + NTP_4_2_7P45 + + ntpdc/ntpdc-opts.c@1.46 +2 -2 + NTP_4_2_7P45 + + ntpdc/ntpdc-opts.h@1.46 +3 -3 + NTP_4_2_7P45 + + ntpdc/ntpdc-opts.texi@1.46 +2 -2 + NTP_4_2_7P45 + + ntpdc/ntpdc.1@1.46 +2 -2 + NTP_4_2_7P45 + + ntpq/ntpq-opts.c@1.46 +2 -2 + NTP_4_2_7P45 + + ntpq/ntpq-opts.h@1.46 +3 -3 + NTP_4_2_7P45 + + ntpq/ntpq-opts.texi@1.46 +2 -2 + NTP_4_2_7P45 + + ntpq/ntpq.1@1.46 +2 -2 + NTP_4_2_7P45 + + ntpsnmpd/ntpsnmpd-opts.c@1.46 +2 -2 + NTP_4_2_7P45 + + ntpsnmpd/ntpsnmpd-opts.h@1.46 +3 -3 + NTP_4_2_7P45 + + ntpsnmpd/ntpsnmpd-opts.texi@1.46 +2 -2 + NTP_4_2_7P45 + + ntpsnmpd/ntpsnmpd.1@1.46 +2 -2 + NTP_4_2_7P45 + + packageinfo.sh@1.47 +1 -1 + NTP_4_2_7P45 + + sntp/sntp-opts.c@1.46 +2 -2 + NTP_4_2_7P45 + + sntp/sntp-opts.h@1.46 +3 -3 + NTP_4_2_7P45 + + sntp/sntp-opts.texi@1.46 +1 -1 + NTP_4_2_7P45 + + sntp/sntp.1@1.46 +2 -2 + NTP_4_2_7P45 + + sntp/sntp.html@1.46 +1 -1 + NTP_4_2_7P45 + + util/ntp-keygen-opts.c@1.41.1.5 +2 -2 + NTP_4_2_7P45 + + util/ntp-keygen-opts.h@1.41.1.5 +3 -3 + NTP_4_2_7P45 + + util/ntp-keygen-opts.texi@1.46 +2 -2 + NTP_4_2_7P45 + + util/ntp-keygen.1@1.46 +2 -2 + NTP_4_2_7P45 + +ChangeSet@1.2156.3.12, 2010-09-05 02:41:15-04:00, stenn@deacon.udel.edu + [Bug 1578] Consistently use -lm when needed + + ChangeLog@1.607.8.2 +1 -0 + [Bug 1578] Consistently use -lm when needed + + clockstuff/Makefile.am@1.10 +1 -2 + [Bug 1578] Consistently use -lm when needed + + configure.ac@1.483.2.1 +1 -0 + [Bug 1578] Consistently use -lm when needed + + m4/ntp_lib_m.m4@1.1 +14 -0 + BitKeeper file /deacon/backroom/ntp-dev-1578/m4/ntp_lib_m.m4 + + m4/ntp_lib_m.m4@1.0 +0 -0 + + ntpd/Makefile.am@1.93 +2 -7 + [Bug 1578] Consistently use -lm when needed + + ntpdate/Makefile.am@1.24 +1 -1 + [Bug 1578] Consistently use -lm when needed + + ntpq/Makefile.am@1.49 +1 -1 + [Bug 1578] Consistently use -lm when needed + + sntp/Makefile.am@1.34 +1 -1 + [Bug 1578] Consistently use -lm when needed + + sntp/configure.ac@1.35 +1 -1 + [Bug 1578] Consistently use -lm when needed + + util/Makefile.am@1.50 +1 -1 + [Bug 1578] Consistently use -lm when needed + +ChangeSet@1.2156.3.11, 2010-08-27 10:09:33+00:00, stenn@deacon.udel.edu + NTP_4_2_7P44 + TAG: NTP_4_2_7P44 + + ChangeLog@1.607.8.1 +1 -0 + NTP_4_2_7P44 + + ntpd/ntpd-opts.c@1.47 +2 -2 + NTP_4_2_7P44 + + ntpd/ntpd-opts.h@1.47 +3 -3 + NTP_4_2_7P44 + + ntpd/ntpd-opts.texi@1.46 +2 -2 + NTP_4_2_7P44 + + ntpd/ntpd.1@1.46 +2 -2 + NTP_4_2_7P44 + + ntpdc/ntpdc-opts.c@1.45 +2 -2 + NTP_4_2_7P44 + + ntpdc/ntpdc-opts.h@1.45 +3 -3 + NTP_4_2_7P44 + + ntpdc/ntpdc-opts.texi@1.45 +2 -2 + NTP_4_2_7P44 + + ntpdc/ntpdc.1@1.45 +2 -2 + NTP_4_2_7P44 + + ntpq/ntpq-opts.c@1.45 +2 -2 + NTP_4_2_7P44 + + ntpq/ntpq-opts.h@1.45 +3 -3 + NTP_4_2_7P44 + + ntpq/ntpq-opts.texi@1.45 +2 -2 + NTP_4_2_7P44 + + ntpq/ntpq.1@1.45 +2 -2 + NTP_4_2_7P44 + + ntpsnmpd/ntpsnmpd-opts.c@1.45 +2 -2 + NTP_4_2_7P44 + + ntpsnmpd/ntpsnmpd-opts.h@1.45 +3 -3 + NTP_4_2_7P44 + + ntpsnmpd/ntpsnmpd-opts.texi@1.45 +2 -2 + NTP_4_2_7P44 + + ntpsnmpd/ntpsnmpd.1@1.45 +2 -2 + NTP_4_2_7P44 + + packageinfo.sh@1.46 +1 -1 + NTP_4_2_7P44 + + sntp/sntp-opts.c@1.45 +2 -2 + NTP_4_2_7P44 + + sntp/sntp-opts.h@1.45 +3 -3 + NTP_4_2_7P44 + + sntp/sntp-opts.texi@1.45 +1 -1 + NTP_4_2_7P44 + + sntp/sntp.1@1.45 +2 -2 + NTP_4_2_7P44 + + sntp/sntp.html@1.45 +1 -1 + NTP_4_2_7P44 + + util/ntp-keygen-opts.c@1.41.1.4 +2 -2 + NTP_4_2_7P44 + + util/ntp-keygen-opts.h@1.41.1.4 +3 -3 + NTP_4_2_7P44 + + util/ntp-keygen-opts.texi@1.45 +2 -2 + NTP_4_2_7P44 + + util/ntp-keygen.1@1.45 +2 -2 + NTP_4_2_7P44 + +ChangeSet@1.2156.8.5, 2010-08-26 09:34:12+00:00, stenn@deacon.udel.edu + NTP_4_2_7P43 + TAG: NTP_4_2_7P43 + + ChangeLog@1.607.7.3 +1 -0 + NTP_4_2_7P43 + + ntpd/ntpd-opts.c@1.46 +2 -2 + NTP_4_2_7P43 + + ntpd/ntpd-opts.h@1.46 +3 -3 + NTP_4_2_7P43 + + ntpd/ntpd-opts.texi@1.45 +2 -2 + NTP_4_2_7P43 + + ntpd/ntpd.1@1.45 +2 -2 + NTP_4_2_7P43 + + ntpdc/ntpdc-opts.c@1.44 +2 -2 + NTP_4_2_7P43 + + ntpdc/ntpdc-opts.h@1.44 +3 -3 + NTP_4_2_7P43 + + ntpdc/ntpdc-opts.texi@1.44 +2 -2 + NTP_4_2_7P43 + + ntpdc/ntpdc.1@1.44 +2 -2 + NTP_4_2_7P43 + + ntpq/ntpq-opts.c@1.44 +2 -2 + NTP_4_2_7P43 + + ntpq/ntpq-opts.h@1.44 +3 -3 + NTP_4_2_7P43 + + ntpq/ntpq-opts.texi@1.44 +2 -2 + NTP_4_2_7P43 + + ntpq/ntpq.1@1.44 +2 -2 + NTP_4_2_7P43 + + ntpsnmpd/ntpsnmpd-opts.c@1.44 +2 -2 + NTP_4_2_7P43 + + ntpsnmpd/ntpsnmpd-opts.h@1.44 +3 -3 + NTP_4_2_7P43 + + ntpsnmpd/ntpsnmpd-opts.texi@1.44 +2 -2 + NTP_4_2_7P43 + + ntpsnmpd/ntpsnmpd.1@1.44 +2 -2 + NTP_4_2_7P43 + + packageinfo.sh@1.45 +1 -1 + NTP_4_2_7P43 + + sntp/sntp-opts.c@1.44 +2 -2 + NTP_4_2_7P43 + + sntp/sntp-opts.h@1.44 +3 -3 + NTP_4_2_7P43 + + sntp/sntp-opts.texi@1.44 +1 -1 + NTP_4_2_7P43 + + sntp/sntp.1@1.44 +2 -2 + NTP_4_2_7P43 + + sntp/sntp.html@1.44 +1 -1 + NTP_4_2_7P43 + + util/ntp-keygen-opts.c@1.41.1.3 +2 -2 + NTP_4_2_7P43 + + util/ntp-keygen-opts.h@1.41.1.3 +3 -3 + NTP_4_2_7P43 + + util/ntp-keygen-opts.texi@1.44 +2 -2 + NTP_4_2_7P43 + + util/ntp-keygen.1@1.44 +2 -2 + NTP_4_2_7P43 + +ChangeSet@1.2225, 2010-08-21 12:15:45+02:00, linus@beam.lund.zozs.se + Modified tests to redirect stderr themselves, instead of relying on an external variable in sntp/log.c + + tests/sntp/logFile.cpp@1.4 +16 -3 + Modified tests to redirect stderr themselves, instead of relying on an external variable in sntp/log.c + +ChangeSet@1.2156.9.1, 2010-08-21 12:05:58+02:00, linus@beam.lund.zozs.se + Reverted sntp/log.c refactoring. + + sntp/log.c@1.15 +1 -2 + Reverted sntp/log.c refactoring. + +ChangeSet@1.2156.8.3, 2010-08-19 06:16:56+00:00, stenn@psp-fb2.ntp.org + [Bug 1602] Refactor some of the sntp/ directory to facililtate testing + + ChangeLog@1.607.7.2 +1 -0 + [Bug 1602] Refactor some of the sntp/ directory to facililtate testing + +ChangeSet@1.2220, 2010-08-18 07:46:34-04:00, karlsson@psp-deb1.ntp.org + Fixed a testing bug, where key type was not null terminated + + tests/sntp/crypto.cpp@1.2 +6 -6 + Fixed a testing bug, where key type was not null terminated + +ChangeSet@1.2156.8.1, 2010-08-18 10:09:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P42 + TAG: NTP_4_2_7P42 + + ChangeLog@1.607.7.1 +1 -0 + NTP_4_2_7P42 + + ntpd/ntpd-opts.c@1.45 +2 -2 + NTP_4_2_7P42 + + ntpd/ntpd-opts.h@1.45 +3 -3 + NTP_4_2_7P42 + + ntpd/ntpd-opts.texi@1.44 +2 -2 + NTP_4_2_7P42 + + ntpd/ntpd.1@1.44 +2 -2 + NTP_4_2_7P42 + + ntpdc/ntpdc-opts.c@1.43 +2 -2 + NTP_4_2_7P42 + + ntpdc/ntpdc-opts.h@1.43 +3 -3 + NTP_4_2_7P42 + + ntpdc/ntpdc-opts.texi@1.43 +2 -2 + NTP_4_2_7P42 + + ntpdc/ntpdc.1@1.43 +2 -2 + NTP_4_2_7P42 + + ntpq/ntpq-opts.c@1.43 +2 -2 + NTP_4_2_7P42 + + ntpq/ntpq-opts.h@1.43 +3 -3 + NTP_4_2_7P42 + + ntpq/ntpq-opts.texi@1.43 +2 -2 + NTP_4_2_7P42 + + ntpq/ntpq.1@1.43 +2 -2 + NTP_4_2_7P42 + + ntpsnmpd/ntpsnmpd-opts.c@1.43 +2 -2 + NTP_4_2_7P42 + + ntpsnmpd/ntpsnmpd-opts.h@1.43 +3 -3 + NTP_4_2_7P42 + + ntpsnmpd/ntpsnmpd-opts.texi@1.43 +2 -2 + NTP_4_2_7P42 + + ntpsnmpd/ntpsnmpd.1@1.43 +2 -2 + NTP_4_2_7P42 + + packageinfo.sh@1.44 +1 -1 + NTP_4_2_7P42 + + sntp/sntp-opts.c@1.43 +2 -2 + NTP_4_2_7P42 + + sntp/sntp-opts.h@1.43 +3 -3 + NTP_4_2_7P42 + + sntp/sntp-opts.texi@1.43 +1 -1 + NTP_4_2_7P42 + + sntp/sntp.1@1.43 +2 -2 + NTP_4_2_7P42 + + sntp/sntp.html@1.43 +1 -1 + NTP_4_2_7P42 + + util/ntp-keygen-opts.c@1.41.1.2 +2 -2 + NTP_4_2_7P42 + + util/ntp-keygen-opts.h@1.41.1.2 +3 -3 + NTP_4_2_7P42 + + util/ntp-keygen-opts.texi@1.43 +2 -2 + NTP_4_2_7P42 + + util/ntp-keygen.1@1.43 +2 -2 + NTP_4_2_7P42 + +ChangeSet@1.2082.22.4, 2010-08-18 11:26:41+02:00, linus@beam.lund.zozs.se + [BUG 1573] Miscalculation of offset in sntp. + + ChangeLog@1.496.47.3 +1 -0 + [BUG 1573] Miscalculation of offset in sntp. + + sntp/main.c@1.24.1.2 +2 -2 + [BUG 1573] Miscalculation of offset in sntp. + +ChangeSet@1.2218, 2010-08-13 17:51:26+02:00, linus@beam.lund.zozs.se + Added test for debug_msg() + + tests/sntp/data/log-expected-debug@1.1 +4 -0 + Added test for debug_msg() + + tests/sntp/data/log-expected-debug@1.0 +0 -0 + + tests/sntp/logFile.cpp@1.3 +25 -6 + Added test for debug_msg() + + tests/sntp/packetProcessing.cpp@1.3 +0 -17 + Moved common code to superclass + + tests/sntp/sntptest.h@1.4 +26 -0 + Moved common code to superclass + +ChangeSet@1.2156.6.11, 2010-08-13 16:54:32+02:00, linus@beam.lund.zozs.se + Minor refactoring to allow redirection of debug messages from unit tests. + + sntp/log.c@1.14 +2 -1 + Minor refactoring to allow redirection of debug messages from unit tests. + +ChangeSet@1.2216, 2010-08-12 20:26:04+02:00, linus@beam.lund.zozs.se + Added tests for debug functions in utilities.c + Minor cleanups. + + tests/sntp/data/debug-input-lfp-bin@1.1 +3 -0 + Added tests for debug functions + + tests/sntp/data/debug-input-lfp-bin@1.0 +0 -0 + + tests/sntp/data/debug-input-lfp-dec@1.1 +3 -0 + Added tests for debug functions + + tests/sntp/data/debug-input-lfp-dec@1.0 +0 -0 + + tests/sntp/data/debug-input-lfp-hex@1.1 +3 -0 + Added tests for debug functions + + tests/sntp/data/debug-input-lfp-hex@1.0 +0 -0 + + tests/sntp/data/debug-input-pkt@1.1 +8 -0 + Added tests for debug functions + + tests/sntp/data/debug-input-pkt@1.0 +0 -0 + + tests/sntp/fileHandlingTest.h@1.3 +11 -0 + Added include guard, and moved common code to base class + + tests/sntp/sntptest.h@1.3 +5 -0 + Added include guard + + tests/sntp/utilities.cpp@1.3 +103 -0 + Added tests for debug functions in utilities.c + + tests/tests_main.h@1.5 +5 -0 + Added include guard. + +ChangeSet@1.2215, 2010-08-11 23:39:59+02:00, linus@beam.lund.zozs.se + Added more tests in different areas. + + tests/sntp/data/key-test-invalid-hex@1.1 +2 -0 + Added extra tests for reading of key files. + + tests/sntp/data/key-test-invalid-hex@1.0 +0 -0 + + tests/sntp/keyFile.cpp@1.2 +18 -0 + Added extra tests for reading of key files. + + tests/sntp/networking.cpp@1.6 +30 -0 + Added tests when preferring IPv4/IPv6 addresses in name resolution. + + tests/sntp/utilities.cpp@1.2 +27 -0 + Added tests for set_li_vn_mode() + +ChangeSet@1.2156.7.3, 2010-08-11 01:40:34+02:00, linus@beam.lund.zozs.se + [Bug 1597] packet processing ignores RATE KoD packets. + + ChangeLog@1.607.4.3 +1 -1 + [Bug 1597] packet processing ignores RATE KoD packets. + +ChangeSet@1.2156.7.2, 2010-08-11 01:34:52+02:00, linus@beam.lund.zozs.se + [Bug 1597] packet processing ignores RATE KoD packets, because of a bug in string comparision. + + ChangeLog@1.607.4.2 +7 -2 + [Bug 1597] packet processing ignores RATE KoD packets, because of a bug in string comparision. + +ChangeSet@1.2156.5.4, 2010-08-11 01:31:43+02:00, linus@beam.lund.zozs.se + [Bug 1595] empty last line in key file causes duplicate key to be added + + ChangeLog@1.607.5.1 +6 -1 + [Bug 1595] empty last line in key file causes duplicate key to be added + +ChangeSet@1.2212, 2010-08-10 18:30:22+02:00, linus@beam.lund.zozs.se + Creates the output directory before running the tests. + + tests/sntp/Makefile.am@1.12 +4 -1 + Some cleanup. + + tests/sntp/test-driver@1.3 +3 -0 + Create the output directory before running the tests. + +ChangeSet@1.2211, 2010-08-10 13:14:24+02:00, linus@beam.lund.zozs.se + Modified tests to use the new prototype of process_pkt() + Added tests for reply/response check moved to process_pkt() in refactoring. + + tests/sntp/packetProcessing.cpp@1.2 +57 -18 + Modified tests to use the new prototype of process_pkt() + Added tests for reply/response check moved to process_pkt() in refactoring. + +ChangeSet@1.2156.6.10, 2010-08-10 13:04:29+02:00, linus@beam.lund.zozs.se + Modified evaluation order to accept NULL as argument to spkt. + + sntp/networking.c@1.37.1.2 +1 -1 + Modified evaluation order to accept NULL as argument to spkt. + +ChangeSet@1.2156.6.9, 2010-08-10 12:09:28+02:00, linus@beam.lund.zozs.se + Moved check for valid response to process_pkt() to simplify testing. + + sntp/networking.c@1.37.1.1 +21 -19 + Moved check for valid response to process_pkt() to simplify testing. + + sntp/networking.h@1.18.1.2 +1 -1 + Moved check for valid response to process_pkt() to simplify testing. + +ChangeSet@1.2208, 2010-08-09 17:15:14+02:00, linus@beam.lund.zozs.se + Moved packet processing tests to a new unit. + Added tests for resolve_hosts() + + tests/sntp/Makefile.am@1.11 +1 -0 + Moved packet processing tests to a separate unit. + + tests/sntp/logFile.cpp@1.2 +0 -2 + Removed multiple calls to cleanup_log to prevent segfault. + + tests/sntp/networking.cpp@1.5 +97 -271 + Moved packet processing tests to a new unit. + Added tests for resolve_hosts() + + tests/sntp/packetProcessing.cpp@1.1 +312 -0 + Moved packet processing tests to a new unit. + + tests/sntp/packetProcessing.cpp@1.0 +0 -0 + +ChangeSet@1.2207, 2010-08-09 12:53:37+02:00, linus@beam.lund.zozs.se + Added tests for log file. + Added test for packets signed with SHA1. + + tests/sntp/Makefile.am@1.10 +1 -0 + Added tests for log file. + + tests/sntp/data/log-expected-log@1.1 +4 -0 + Added test for log file. + + tests/sntp/data/log-expected-log@1.0 +0 -0 + + tests/sntp/logFile.cpp@1.1 +39 -0 + Added test for log file. + + tests/sntp/logFile.cpp@1.0 +0 -0 + + tests/sntp/networking.cpp@1.4 +29 -3 + Added test for correct packet signed with SHA1. + +ChangeSet@1.2206, 2010-08-05 22:59:12+02:00, linus@beam.lund.zozs.se + Added tests for authentication + + tests/sntp/Makefile.am@1.9 +1 -0 + Added tests for authentication + + tests/sntp/crypto.cpp@1.1 +125 -0 + Added tests for authentication + + tests/sntp/crypto.cpp@1.0 +0 -0 + +ChangeSet@1.2205, 2010-08-05 15:10:49+02:00, linus@beam.lund.zozs.se + Added tests for handle_packet() function. + + tests/sntp/packetHandling.cpp@1.3 +82 -0 + Added tests for handle_packet() function. + +ChangeSet@1.2204, 2010-08-04 23:40:16+02:00, linus@beam.lund.zozs.se + Added test for negative offset calculation. + + tests/sntp/packetHandling.cpp@1.2 +41 -0 + Added test for negative offset calculation. + +ChangeSet@1.2203, 2010-08-04 00:37:25+02:00, linus@beam.lund.zozs.se + Renamed main class for tests. + Added tests for packet generation and time offset calculations. + + tests/libntp/Makefile.am@1.21 +1 -1 + Renamed main file for tests. + + tests/libntp/libntptest.h@1.3 +1 -1 + Renamed main file for tests. + + tests/sntp/Makefile.am@1.8 +3 -1 + Renamed main file for tests. + Added tests for packet generation. + + tests/sntp/packetHandling.cpp@1.1 +124 -0 + Added new tests for packet generation and time offset calculations. + + tests/sntp/packetHandling.cpp@1.0 +0 -0 + + tests/sntp/sntptest.h@1.2 +1 -1 + Renamed main file for tests. + + tests/tests_main.cpp@1.5 +1 -1 + Renamed main class for tests. + + tests/tests_main.cpp@1.4 +0 -0 + Rename: tests/main.cpp -> tests/tests_main.cpp + + tests/tests_main.h@1.4 +0 -0 + Rename: tests/main.h -> tests/tests_main.h + +ChangeSet@1.2156.6.8, 2010-08-03 23:44:21+02:00, linus@beam.lund.zozs.se + Moved time dependent code out of the offset calculations. + + sntp/main.c@1.32 +3 -2 + Moved time dependent code out of the offset calculations. + +ChangeSet@1.2156.6.7, 2010-08-03 15:10:22+02:00, linus@beam.lund.zozs.se + Moved definition of progname and debug to sntp.c + + sntp/main.c@1.31 +0 -3 + Moved definition of progname and debug to sntp.c + + sntp/sntp.c@1.2 +3 -0 + Moved definition of progname and debug to sntp.c + +ChangeSet@1.2156.6.6, 2010-08-03 13:26:19+02:00, linus@beam.lund.zozs.se + Moved the time offset calculations to a separate function. + + sntp/main.c@1.30 +72 -56 + Moved the time offset calculations to a separate function. + + sntp/main.h@1.3 +4 -0 + Added prototypes for the new functions. + +ChangeSet@1.2156.6.5, 2010-08-02 20:36:02+02:00, linus@beam.lund.zozs.se + Refactoring of packet parsing for unit testing. + Moved packet parsing to a new function. + + sntp/main.c@1.29 +142 -126 + Refactoring of packet parsing for unit testing. + Moved packet parsing to a new function. + +ChangeSet@1.2156.6.4, 2010-08-02 17:53:13+02:00, linus@beam.lund.zozs.se + Factored out packet generation to a new function. + + sntp/main.c@1.28 +32 -19 + Factored out packet generation to a new function. + + sntp/main.h@1.2 +7 -3 + Factored out packet generation to a new function. + +ChangeSet@1.2156.6.3, 2010-08-02 14:20:12+02:00, linus@beam.lund.zozs.se + Moved main() function to a new file to make unit testing easier. + + sntp/Makefile.am@1.33 +2 -0 + Moved main() function to a new file to make unit testing easier. + + sntp/main.c@1.27 +1 -26 + Moved main() function to a new file to make unit testing easier. + + sntp/main.h@1.1 +21 -0 + Moved main() function to a new file to make unit testing easier. + + sntp/main.h@1.0 +0 -0 + + sntp/sntp.c@1.1 +10 -0 + Moved main() function to a new file to make unit testing easier. + + sntp/sntp.c@1.0 +0 -0 + +ChangeSet@1.2199, 2010-07-31 23:13:39+02:00, linus@beam.lund.zozs.se + * Added more tests for packet processing. + * Refactored the authenticated tests. + + tests/sntp/networking.cpp@1.3 +18 -37 + Added more tests for packet processing, and refactored the tests using authenticated packets. + +ChangeSet@1.2198, 2010-07-31 22:49:46+02:00, linus@beam.lund.zozs.se + Added more tests for packet processing. + + tests/sntp/networking.cpp@1.2 +142 -20 + Added more tests. + +ChangeSet@1.2082.23.1, 2010-07-31 21:59:50+02:00, linus@beam.lund.zozs.se + [BUG 1597] packet processing ignores RATE KoD packets because of a bug in string comparison. + + ChangeLog@1.496.48.1 +5 -0 + [BUG 1597] packet processing ignores RATE KoD packets because of a bug in string comparison. + + sntp/networking.c@1.29.1.7 +3 -3 + [BUG 1597] packet processing ignores RATE KoD packets because of a bug in string comparison. + +ChangeSet@1.2196, 2010-07-30 22:02:44+02:00, linus@beam.lund.zozs.se + Added tests for packet processing. + + tests/sntp/Makefile.am@1.7 +2 -0 + Added networking tests. + + tests/sntp/networking.cpp@1.1 +186 -0 + Added tests for packet processing. + + tests/sntp/networking.cpp@1.0 +0 -0 + +ChangeSet@1.2156.6.2, 2010-07-30 13:14:50+02:00, linus@beam.lund.zozs.se + Added prototype to header + + sntp/networking.h@1.18.1.1 +2 -0 + Added prototype to header + +ChangeSet@1.2156.6.1, 2010-07-30 12:37:05+02:00, linus@beam.lund.zozs.se + Made process_pkt() a public function to ease testing. + + sntp/networking.c@1.37 +1 -1 + Made process_pkt() a public function to ease testing. + +ChangeSet@1.2192, 2010-07-30 10:41:21+02:00, linus@beam.lund.zozs.se + Moved file handling code from test to superclass + + tests/sntp/fileHandlingTest.h@1.2 +29 -0 + Moved file handling code from test to superclass + + tests/sntp/kodFile.cpp@1.6 +0 -27 + Moved file handling code from test to superclass + +ChangeSet@1.2191, 2010-07-28 22:59:08+02:00, linus@beam.lund.zozs.se + Added tests for some utilities functions. + + tests/sntp/Makefile.am@1.6 +4 -2 + Added tests for some utilities functions. + + tests/sntp/utilities.cpp@1.1 +66 -0 + Added tests for some utilities functions. + + tests/sntp/utilities.cpp@1.0 +0 -0 + +ChangeSet@1.2082.22.2, 2010-07-28 18:30:17+02:00, linus@beam.lund.zozs.se + [Bug 1595] empty last line in key file causes duplicate key to be added + + ChangeLog@1.496.47.1 +4 -0 + [Bug 1595] empty last line in key file causes duplicate key to be added + +ChangeSet@1.2082.22.1, 2010-07-28 18:18:55+02:00, linus@beam.lund.zozs.se + [Bug 1595] empty last line in key file causes duplicate key to be added + + sntp/crypto.c@1.10.1.3 +3 -1 + [Bug 1595] empty last line in key file causes duplicate key to be added + +ChangeSet@1.2189, 2010-07-28 13:38:35+02:00, linus@beam.lund.zozs.se + Added tests for reading of key file. + + tests/sntp/Makefile.am@1.5 +4 -1 + Added tests for reading of key file. + + tests/sntp/data/key-test-ascii@1.1 +2 -0 + Input files for key file tests + + tests/sntp/data/key-test-ascii@1.0 +0 -0 + + tests/sntp/data/key-test-comments@1.1 +3 -0 + Input files for key file test + + tests/sntp/data/key-test-comments@1.0 +0 -0 + + tests/sntp/data/key-test-empty@1.1 +0 -0 + Input file for key file test + + tests/sntp/data/key-test-empty@1.0 +0 -0 + + tests/sntp/data/key-test-hex@1.1 +3 -0 + Input files for key file test + + tests/sntp/data/key-test-hex@1.0 +0 -0 + + tests/sntp/fileHandlingTest.h@1.1 +24 -0 + Moved file handling code to superclass + + tests/sntp/fileHandlingTest.h@1.0 +0 -0 + + tests/sntp/keyFile.cpp@1.1 +112 -0 + Added tests for key file reading. + + tests/sntp/keyFile.cpp@1.0 +0 -0 + + tests/sntp/kodFile.cpp@1.5 +2 -22 + Moved file handling code to superclass. + +ChangeSet@1.2156.5.1, 2010-07-28 05:48:23+00:00, stenn@deacon.udel.edu + NTP_4_2_7P41 + TAG: NTP_4_2_7P41 + + ChangeLog@1.607.3.1 +1 -0 + NTP_4_2_7P41 + + ntpd/ntpd-opts.c@1.44 +2 -2 + NTP_4_2_7P41 + + ntpd/ntpd-opts.h@1.44 +3 -3 + NTP_4_2_7P41 + + ntpd/ntpd-opts.texi@1.43 +2 -2 + NTP_4_2_7P41 + + ntpd/ntpd.1@1.43 +2 -2 + NTP_4_2_7P41 + + ntpdc/ntpdc-opts.c@1.42 +2 -2 + NTP_4_2_7P41 + + ntpdc/ntpdc-opts.h@1.42 +3 -3 + NTP_4_2_7P41 + + ntpdc/ntpdc-opts.texi@1.42 +2 -2 + NTP_4_2_7P41 + + ntpdc/ntpdc.1@1.42 +2 -2 + NTP_4_2_7P41 + + ntpq/ntpq-opts.c@1.42 +2 -2 + NTP_4_2_7P41 + + ntpq/ntpq-opts.h@1.42 +3 -3 + NTP_4_2_7P41 + + ntpq/ntpq-opts.texi@1.42 +2 -2 + NTP_4_2_7P41 + + ntpq/ntpq.1@1.42 +2 -2 + NTP_4_2_7P41 + + ntpsnmpd/ntpsnmpd-opts.c@1.42 +2 -2 + NTP_4_2_7P41 + + ntpsnmpd/ntpsnmpd-opts.h@1.42 +3 -3 + NTP_4_2_7P41 + + ntpsnmpd/ntpsnmpd-opts.texi@1.42 +2 -2 + NTP_4_2_7P41 + + ntpsnmpd/ntpsnmpd.1@1.42 +2 -2 + NTP_4_2_7P41 + + packageinfo.sh@1.43 +1 -1 + NTP_4_2_7P41 + + sntp/sntp-opts.c@1.42 +2 -2 + NTP_4_2_7P41 + + sntp/sntp-opts.h@1.42 +3 -3 + NTP_4_2_7P41 + + sntp/sntp-opts.texi@1.42 +1 -1 + NTP_4_2_7P41 + + sntp/sntp.1@1.42 +2 -2 + NTP_4_2_7P41 + + sntp/sntp.html@1.42 +1 -1 + NTP_4_2_7P41 + + util/ntp-keygen-opts.c@1.41.1.1 +2 -2 + NTP_4_2_7P41 + + util/ntp-keygen-opts.h@1.41.1.1 +3 -3 + NTP_4_2_7P41 + + util/ntp-keygen-opts.texi@1.42 +2 -2 + NTP_4_2_7P41 + + util/ntp-keygen.1@1.42 +2 -2 + NTP_4_2_7P41 + +ChangeSet@1.2156.3.5, 2010-07-28 05:33:53+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1593] ntpd abort in free() with logconfig syntax error. + + ChangeLog@1.607.1.5 +1 -0 + [Bug 1593] ntpd abort in free() with logconfig syntax error. + + ntpd/ntp_parser.c@1.59 +62 -52 + Bison output + + ntpd/ntp_parser.y@1.54 +17 -7 + [Bug 1593] ntpd abort in free() with logconfig syntax error. + +ChangeSet@1.2156.3.4, 2010-07-27 23:14:28-04:00, stenn@pogo.udel.edu + merge cleanup + + ChangeLog@1.607.1.4 +2 -0 + merge cleanup + +ChangeSet@1.2156.4.1, 2010-07-27 22:59:12-04:00, stenn@deacon.udel.edu + orphanwait documentation changes + + ChangeLog@1.607.2.1 +1 -0 + orphanwait documentation changes + + html/assoc.html@1.30 +4 -3 + orphanwait documentation changes + + html/miscopt.html@1.55 +8 -4 + orphanwait documentation changes + +ChangeSet@1.2187, 2010-07-27 23:54:49+02:00, linus@beam.lund.zozs.se + Removed DEBUG definitions so output from Google Test more clear. + + sntp/header.h@1.5 +1 -1 + Commented out DEBUG defintion to clean up test output. + + sntp/kod_management.c@1.18 +1 -1 + Commented out DEBUG definition to clear up test output. + + tests/sntp/Makefile.am@1.4 +13 -8 + Uses the built object files from sntp, instead of compiling the sntp sources again for the tests. This is a good thing to do, since sntp has it's own configure scripts. + +ChangeSet@1.2186, 2010-07-27 14:53:27-04:00, karlsson@psp-deb1.ntp.org + Fixed integer constants so they work on 32-bit systems, which have 32-bit time_t + + tests/sntp/data/kod-test-blanks@1.2 +1 -1 + Fixed integer constants so they work on 32-bit systems which have 32-bit time_t + + tests/sntp/data/kod-test-correct@1.2 +1 -1 + Fixed integer constants so they work on 32-bit systems which have 32-bit time_t + + tests/sntp/kodFile.cpp@1.4 +2 -2 + Fixed integer constants so they work on 32-bit systems which have 32-bit time_t + +ChangeSet@1.2185, 2010-07-27 20:38:53+02:00, linus@beam.lund.zozs.se + Added tests for writing of KoD database to file. + + tests/sntp/data/kod-expected-multiple@1.1 +3 -0 + Expected output of tests. + + tests/sntp/data/kod-expected-multiple@1.0 +0 -0 + + tests/sntp/data/kod-expected-single@1.1 +1 -0 + Expected output of tests + + tests/sntp/data/kod-expected-single@1.0 +0 -0 + + tests/sntp/kodFile.cpp@1.3 +101 -4 + Added tests for writing of KoD database. + +ChangeSet@1.2184, 2010-07-27 18:08:05+02:00, linus@beam.lund.zozs.se + Modified test code to accept multiple parameters. + + tests/main.cpp@1.3 +8 -6 + Modified code to accept multiple parameters. + + tests/main.h@1.3 +3 -2 + Modified code to accept multiple parameteres. + + tests/sntp/Makefile.am@1.3 +1 -1 + Pass the path to the build dir, in addition to the source dir. + + tests/sntp/kodFile.cpp@1.2 +9 -5 + Modified code to handle multiple parameters. + + tests/sntp/test-driver@1.2 +1 -1 + Two parameters can be sent to the test executable. + +ChangeSet@1.2183, 2010-07-27 14:42:53+02:00, linus@beam.lund.zozs.se + New tests for KoD-database file reading. + + tests/main.cpp@1.2 +16 -2 + Modified test base class to accept an extra parameter. + + tests/main.h@1.2 +6 -1 + Modified test base class to accept an extra parameter. + + tests/sntp/Makefile.am@1.2 +8 -4 + Provided another test runner, that passes the data directory as a parameter to the tests. + + tests/sntp/data/kod-test-blanks@1.1 +6 -0 + Input file for KoD-reading test. + + tests/sntp/data/kod-test-blanks@1.0 +0 -0 + + tests/sntp/data/kod-test-correct@1.1 +2 -0 + Input file for KoD-reading test. + + tests/sntp/data/kod-test-correct@1.0 +0 -0 + + tests/sntp/data/kod-test-empty@1.1 +0 -0 + Input file for KoD-reading test. + + tests/sntp/data/kod-test-empty@1.0 +0 -0 + + tests/sntp/kodFile.cpp@1.1 +92 -0 + Added tests for reading a KoD-database file. + + tests/sntp/kodFile.cpp@1.0 +0 -0 + + tests/sntp/test-driver@1.1 +3 -0 + A basic TESTS_ENVIRONMENT wrapper, that provides an extra parameter to the test executable + + tests/sntp/test-driver@1.0 +0 -0 + +ChangeSet@1.2182, 2010-07-26 23:27:05+02:00, linus@beam.lund.zozs.se + Boilerplate for sntp tests, and tests for KoD-database. + + configure.ac@1.489 +1 -0 + Added Makefile creation for sntp tests. + + tests/Makefile.am@1.3 +1 -1 + Added sntp subdir. + + tests/sntp/Makefile.am@1.1 +28 -0 + Added Makefile.am for sntp tests. + + tests/sntp/Makefile.am@1.0 +0 -0 + + tests/sntp/kodDatabase.cpp@1.1 +118 -0 + Tests for KoD-database. + + tests/sntp/kodDatabase.cpp@1.0 +0 -0 + + tests/sntp/sntptest.cpp@1.1 +9 -0 + Base class for sntp tests. + + tests/sntp/sntptest.cpp@1.0 +0 -0 + + tests/sntp/sntptest.h@1.1 +4 -0 + Base class for sntp tests. + + tests/sntp/sntptest.h@1.0 +0 -0 + +ChangeSet@1.2156.3.2, 2010-07-20 18:02:12+00:00, davehart@shiny.ad.hartbrothers.com + Avoid race with parallel builds using same source directory in + scripts/genver by using build directory for temporary files. + + ChangeLog@1.607.1.2 +2 -0 + Avoid race with parallel builds using same source directory in + scripts/genver by using build directory for temporary files. + + Makefile.am@1.93.1.1 +3 -3 + Avoid race with parallel builds using same source directory in + scripts/genver by using build directory for temporary files. + + scripts/genver@1.6 +23 -15 + Avoid race with parallel builds using same source directory in + scripts/genver by using build directory for temporary files. + +ChangeSet@1.2156.3.1, 2010-07-20 15:21:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1586] ntpd 4.2.7p40 doesn't write to syslog after fork on QNX. + Add closelog() before closing most or all descriptors after fork(). + + ChangeLog@1.607.1.1 +1 -0 + [Bug 1586] ntpd 4.2.7p40 doesn't write to syslog after fork on QNX. + Add closelog() before closing most or all descriptors after fork(). + + include/ntp_io.h@1.16 +1 -0 + [Bug 1586] ntpd 4.2.7p40 doesn't write to syslog after fork on QNX. + + ntpd/ntp_io.c@1.320 +19 -0 + [Bug 1586] ntpd 4.2.7p40 doesn't write to syslog after fork on QNX. + Add closelog() before closing most or all descriptors after fork(). + Close all descriptors (excepting waitsync_fd_to_close) not only those + after it. This was a merge failure. + + ntpd/ntpd.c@1.114 +4 -3 + [Bug 1586] ntpd 4.2.7p40 doesn't write to syslog after fork on QNX. + Add closelog() before closing most or all descriptors after fork(). + Close all descriptors (excepting waitsync_fd_to_close) not only those + after it. This was a merge failure. + + ntpd/work_fork.c@1.5 +2 -1 + [Bug 1586] ntpd 4.2.7p40 doesn't write to syslog after fork on QNX. + Add closelog() before closing most or all descriptors after fork(). + +ChangeSet@1.2156.1.16, 2010-07-19 16:58:15+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1588] finish configure --disable-autokey implementation, + add --disable-autokey to flock-build -no-refclocks flavor. + + ChangeLog@1.608 +1 -0 + [Bug 1588] finish configure --disable-autokey implementation. + + configure.ac@1.483.1.3 +1 -1 + [Bug 1588] finish configure --disable-autokey implementation. + + flock-build@1.47 +3 -2 + add --disable-autokey to -no-refclocks flavor + + include/ntp.h@1.180 +6 -8 + [Bug 1588] finish configure --disable-autokey implementation. + + include/ntp_control.h@1.47 +110 -109 + [Bug 1588] finish configure --disable-autokey implementation. + + include/ntp_crypto.h@1.49 +9 -8 + [Bug 1588] finish configure --disable-autokey implementation. + + include/ntp_md5.h@1.6 +17 -11 + [Bug 1588] finish configure --disable-autokey implementation. + + include/ntpd.h@1.140 +4 -4 + [Bug 1588] finish configure --disable-autokey implementation. + + libntp/a_md5encrypt.c@1.29 +1 -5 + [Bug 1588] finish configure --disable-autokey implementation. + + libntp/authreadkeys.c@1.17 +9 -8 + [Bug 1588] finish configure --disable-autokey implementation. + + libntp/ssl_init.c@1.10 +1 -0 + [Bug 1588] finish configure --disable-autokey implementation. + + libntp/statestr.c@1.21 +4 -4 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_config.c@1.263 +9 -9 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_control.c@1.140 +124 -131 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_crypto.c@1.148 +3 -3 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_peer.c@1.134 +4 -7 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_proto.c@1.301 +51 -51 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_request.c@1.95 +4 -4 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_timer.c@1.60 +13 -13 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpd/ntp_util.c@1.82 +25 -25 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpdc/ntpdc.c@1.86 +4 -0 + [Bug 1588] finish configure --disable-autokey implementation. + + ntpq/ntpq.c@1.116 +4 -0 + [Bug 1588] finish configure --disable-autokey implementation. + + ports/winnt/include/ntp_timer.h@1.6 +4 -6 + [Bug 1588] finish configure --disable-autokey implementation. + + sntp/crypto.h@1.10 +1 -5 + [Bug 1588] finish configure --disable-autokey implementation. + + sntp/networking.h@1.19 +3 -3 + [Bug 1588] finish configure --disable-autokey implementation. + + util/ntp-keygen-opts.c@1.42 +46 -46 + [Bug 1588] finish configure --disable-autokey implementation. + + util/ntp-keygen-opts.def@1.12 +15 -15 + [Bug 1588] finish configure --disable-autokey implementation. + + util/ntp-keygen-opts.h@1.42 +8 -8 + [Bug 1588] finish configure --disable-autokey implementation. + + util/ntp-keygen.c@1.65 +19 -19 + [Bug 1588] finish configure --disable-autokey implementation. + +ChangeSet@1.2156.1.15, 2010-07-12 10:09:56+00:00, stenn@deacon.udel.edu + NTP_4_2_7P40 + TAG: NTP_4_2_7P40 + + ChangeLog@1.607 +1 -0 + NTP_4_2_7P40 + + ntpd/ntpd-opts.c@1.43 +5 -5 + NTP_4_2_7P40 + + ntpd/ntpd-opts.h@1.43 +4 -4 + NTP_4_2_7P40 + + ntpd/ntpd-opts.texi@1.42 +2 -2 + NTP_4_2_7P40 + + ntpd/ntpd.1@1.42 +2 -2 + NTP_4_2_7P40 + + ntpdc/ntpdc-opts.c@1.41 +2 -2 + NTP_4_2_7P40 + + ntpdc/ntpdc-opts.h@1.41 +3 -3 + NTP_4_2_7P40 + + ntpdc/ntpdc-opts.texi@1.41 +2 -2 + NTP_4_2_7P40 + + ntpdc/ntpdc.1@1.41 +2 -2 + NTP_4_2_7P40 + + ntpq/ntpq-opts.c@1.41 +2 -2 + NTP_4_2_7P40 + + ntpq/ntpq-opts.h@1.41 +3 -3 + NTP_4_2_7P40 + + ntpq/ntpq-opts.texi@1.41 +2 -2 + NTP_4_2_7P40 + + ntpq/ntpq.1@1.41 +2 -2 + NTP_4_2_7P40 + + ntpsnmpd/ntpsnmpd-opts.c@1.41 +2 -2 + NTP_4_2_7P40 + + ntpsnmpd/ntpsnmpd-opts.h@1.41 +3 -3 + NTP_4_2_7P40 + + ntpsnmpd/ntpsnmpd-opts.texi@1.41 +2 -2 + NTP_4_2_7P40 + + ntpsnmpd/ntpsnmpd.1@1.41 +2 -2 + NTP_4_2_7P40 + + packageinfo.sh@1.42 +1 -1 + NTP_4_2_7P40 + + sntp/sntp-opts.c@1.41 +2 -2 + NTP_4_2_7P40 + + sntp/sntp-opts.h@1.41 +3 -3 + NTP_4_2_7P40 + + sntp/sntp-opts.texi@1.41 +1 -1 + NTP_4_2_7P40 + + sntp/sntp.1@1.41 +2 -2 + NTP_4_2_7P40 + + sntp/sntp.html@1.41 +1 -1 + NTP_4_2_7P40 + + util/ntp-keygen-opts.c@1.41 +2 -2 + NTP_4_2_7P40 + + util/ntp-keygen-opts.h@1.41 +3 -3 + NTP_4_2_7P40 + + util/ntp-keygen-opts.texi@1.41 +2 -2 + NTP_4_2_7P40 + + util/ntp-keygen.1@1.41 +2 -2 + NTP_4_2_7P40 + +ChangeSet@1.2082.4.108, 2010-07-10 18:11:54+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1581] missed one previously + + ChangeLog@1.496.26.80 +4 -0 + [Bug 1581] missed one previously + + ntpd/ntp_intres.c@1.79.1.2 +1 -1 + [Bug 1581] missed one previously + +ChangeSet@1.2156.1.14, 2010-07-09 23:35:54+00:00, davehart@shiny.ad.hartbrothers.com + updated output of ntpdbase-opts.def + + ntpd/ntpd-opts.c@1.42 +2 -2 + updated output of ntpdbase-opts.def + + ntpd/ntpd-opts.h@1.42 +3 -3 + updated output of ntpdbase-opts.def + + ntpd/ntpd-opts.texi@1.41 +64 -5 + updated output of ntpdbase-opts.def + + ntpd/ntpd.1@1.41 +27 -5 + updated output of ntpdbase-opts.def + +ChangeSet@1.2156.1.12, 2010-07-09 10:09:15+00:00, stenn@deacon.udel.edu + NTP_4_2_7P39 + TAG: NTP_4_2_7P39 + + ChangeLog@1.605 +1 -0 + NTP_4_2_7P39 + + ntpd/ntpd-opts.c@1.39.1.1 +2 -2 + NTP_4_2_7P39 + + ntpd/ntpd-opts.h@1.39.1.1 +3 -3 + NTP_4_2_7P39 + + ntpd/ntpd-opts.texi@1.40 +2 -2 + NTP_4_2_7P39 + + ntpd/ntpd.1@1.40 +2 -2 + NTP_4_2_7P39 + + ntpdc/ntpdc-opts.c@1.40 +2 -2 + NTP_4_2_7P39 + + ntpdc/ntpdc-opts.h@1.40 +3 -3 + NTP_4_2_7P39 + + ntpdc/ntpdc-opts.texi@1.40 +2 -2 + NTP_4_2_7P39 + + ntpdc/ntpdc.1@1.40 +2 -2 + NTP_4_2_7P39 + + ntpq/ntpq-opts.c@1.40 +2 -2 + NTP_4_2_7P39 + + ntpq/ntpq-opts.h@1.40 +3 -3 + NTP_4_2_7P39 + + ntpq/ntpq-opts.texi@1.40 +2 -2 + NTP_4_2_7P39 + + ntpq/ntpq.1@1.40 +2 -2 + NTP_4_2_7P39 + + ntpsnmpd/ntpsnmpd-opts.c@1.40 +2 -2 + NTP_4_2_7P39 + + ntpsnmpd/ntpsnmpd-opts.h@1.40 +3 -3 + NTP_4_2_7P39 + + ntpsnmpd/ntpsnmpd-opts.texi@1.40 +2 -2 + NTP_4_2_7P39 + + ntpsnmpd/ntpsnmpd.1@1.40 +2 -2 + NTP_4_2_7P39 + + packageinfo.sh@1.41 +1 -1 + NTP_4_2_7P39 + + sntp/sntp-opts.c@1.40 +2 -2 + NTP_4_2_7P39 + + sntp/sntp-opts.h@1.40 +3 -3 + NTP_4_2_7P39 + + sntp/sntp-opts.texi@1.40 +1 -1 + NTP_4_2_7P39 + + sntp/sntp.1@1.40 +2 -2 + NTP_4_2_7P39 + + sntp/sntp.html@1.40 +1 -1 + NTP_4_2_7P39 + + util/ntp-keygen-opts.c@1.40 +2 -2 + NTP_4_2_7P39 + + util/ntp-keygen-opts.h@1.40 +3 -3 + NTP_4_2_7P39 + + util/ntp-keygen-opts.texi@1.40 +2 -2 + NTP_4_2_7P39 + + util/ntp-keygen.1@1.40 +2 -2 + NTP_4_2_7P39 + +ChangeSet@1.2156.1.11, 2010-07-09 02:03:53-04:00, stenn@deacon.udel.edu + Fix typo in driver28.html + + ChangeLog@1.604 +1 -0 + Fix typo in driver28.html + + html/drivers/driver28.html@1.13 +1 -1 + Fix typo in driver28.html + +ChangeSet@1.2082.4.107, 2010-07-09 02:25:58+00:00, stenn@deacon.udel.edu + NTP_4_2_6P2 + TAG: NTP_4_2_6P2 + + ChangeLog@1.496.26.79 +1 -0 + NTP_4_2_6P2 + + ntpd/ntpd-opts.c@1.248.15.1 +2 -2 + NTP_4_2_6P2 + + ntpd/ntpd-opts.h@1.248.15.1 +3 -3 + NTP_4_2_6P2 + + ntpd/ntpd-opts.texi@1.246.15.1 +2 -2 + NTP_4_2_6P2 + + ntpd/ntpd.1@1.246.15.1 +2 -2 + NTP_4_2_6P2 + + ntpdc/ntpdc-opts.c@1.244.15.1 +2 -2 + NTP_4_2_6P2 + + ntpdc/ntpdc-opts.h@1.244.15.1 +3 -3 + NTP_4_2_6P2 + + ntpdc/ntpdc-opts.texi@1.243.15.1 +2 -2 + NTP_4_2_6P2 + + ntpdc/ntpdc.1@1.243.15.1 +2 -2 + NTP_4_2_6P2 + + ntpq/ntpq-opts.c@1.245.15.1 +2 -2 + NTP_4_2_6P2 + + ntpq/ntpq-opts.h@1.245.15.1 +3 -3 + NTP_4_2_6P2 + + ntpq/ntpq-opts.texi@1.244.15.1 +2 -2 + NTP_4_2_6P2 + + ntpq/ntpq.1@1.244.15.1 +2 -2 + NTP_4_2_6P2 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.16.1 +2 -2 + NTP_4_2_6P2 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.16.1 +3 -3 + NTP_4_2_6P2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.16.1 +2 -2 + NTP_4_2_6P2 + + ntpsnmpd/ntpsnmpd.1@1.122.16.1 +2 -2 + NTP_4_2_6P2 + + packageinfo.sh@1.255.17.2 +2 -2 + NTP_4_2_6P2 + + sntp/sntp-opts.c@1.117.15.1 +2 -2 + NTP_4_2_6P2 + + sntp/sntp-opts.h@1.117.15.1 +3 -3 + NTP_4_2_6P2 + + sntp/sntp-opts.texi@1.117.15.1 +1 -1 + NTP_4_2_6P2 + + sntp/sntp.1@1.117.15.1 +2 -2 + NTP_4_2_6P2 + + sntp/sntp.html@1.7.15.1 +1 -1 + NTP_4_2_6P2 + + util/ntp-keygen-opts.c@1.247.15.1 +2 -2 + NTP_4_2_6P2 + + util/ntp-keygen-opts.h@1.247.15.1 +3 -3 + NTP_4_2_6P2 + + util/ntp-keygen-opts.texi@1.246.15.1 +2 -2 + NTP_4_2_6P2 + + util/ntp-keygen.1@1.246.15.1 +2 -2 + NTP_4_2_6P2 + +ChangeSet@1.2156.1.9, 2010-07-09 01:59:14+00:00, davehart@shiny.ad.hartbrothers.com + Correct the attribution of the next -stable tarball to 4.2.6p2 + + ChangeLog@1.602 +3 -3 + Correct the attribution of the next -stable tarball to 4.2.6p2 + +ChangeSet@1.2082.4.106, 2010-07-08 21:55:47-04:00, stenn@deacon.udel.edu + release 4.2.6p2 + + NEWS@1.107 +39 -0 + NEWS file for 4.2.6p2 + + packageinfo.sh@1.255.17.1 +1 -1 + release 4.2.6p2 + +ChangeSet@1.2082.4.105, 2010-07-08 21:49:08-04:00, stenn@deacon.udel.edu + Use the new mirror server names for the trigger mirror update script + + BitKeeper/triggers/2mirrors@1.6 +2 -2 + Use the new mirror server names for the trigger mirror update script + +ChangeSet@1.2156.2.3, 2010-07-06 04:18:16+00:00, davehart@shiny.ad.hartbrothers.com + Remove orphan mode startup workaround from ntp_proto.c, it's + not needed with the addition of sys_orphwait. + Add "tos orphanwait" to set sys_orphwait. + + ntpd/complete.conf@1.8 +1 -1 + add "tos orphanwait 300" + + ntpd/keyword-gen-utd@1.7 +1 -1 + sentinel that ntp_keyword.h is current with keyword-gen.c + + ntpd/keyword-gen.c@1.12 +1 -0 + add T_Orphanwait "orphanwait" for tos orphanwait + + ntpd/ntp_config.c@1.260.1.3 +5 -0 + tos orphanwait + + ntpd/ntp_keyword.h@1.9 +498 -493 + generated by keyword-gen.c + + ntpd/ntp_parser.c@1.58 +907 -898 + generated from ntp_parser.y + + ntpd/ntp_parser.h@1.37 +131 -129 + generated from ntp_parser.y + + ntpd/ntp_parser.y@1.53 +3 -0 + tos orphanwait + + ntpd/ntp_proto.c@1.300 +1 -6 + remove orphan mode at startup workaround, no longer needed for + [Bug 1395] --wait-sync with DLM's sys_orphwait change. + + ntpd/ntpd.c@1.113 +0 -7 + leftover merge cleanup, remove locals leftover from code + moved from ntpdmain() to close_all_beyond(). + +ChangeSet@1.2156.2.2, 2010-07-05 14:58:16+00:00, davehart@shiny.ad.hartbrothers.com + merge cleanup + + ntpd/ntp_config.c@1.260.1.2 +2 -2 + correct merge for removal of default_ai_family from ntpd. + + ntpd/ntpd-opts.c@1.40 +97 -20 + Autogen output + + ntpd/ntpd-opts.h@1.40 +18 -11 + Autogen output + +ChangeSet@1.2180, 2010-07-04 21:56:55+02:00, linus@beam.lund.zozs.se + Fixed a bug that showed up when shuffling the tests, because the key cache was not emptied in test SetUp() + + tests/libntp/authkeys.cpp@1.5 +12 -26 + Fixed a bug that showed up when shuffling the tests, because the key cache was not emptied in test SetUp(). + +ChangeSet@1.2082.4.104, 2010-07-02 07:43:21+01:00, davehart@shiny.ad.hartbrothers.com + [Bug 1581] size_t printf format string mismatches, IRIG string buffers + undersized. Mostly backported from earlier ntp-dev fixes by Jürgen + Perlinger, The exceptions are ntp_intres.c and refclock_irig.c. + + ChangeLog@1.496.26.78 +6 -0 + [Bug 1581] size_t printf format string mismatches, IRIG string buffers + undersized. Mostly backported from earlier ntp-dev fixes by Jürgen + Perlinger, The exceptions are ntp_intres.c and refclock_irig.c. + + libntp/ssl_init.c@1.4.1.2 +5 -4 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). + + ntpd/ntp_config.c@1.241.1.4 +4 -4 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). + + ntpd/ntp_intres.c@1.79.1.1 +6 -4 + [Bug 1581] size_t printf format string mismatches. + + ntpd/ntp_request.c@1.82.1.2 +8 -7 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). + + ntpd/ntp_scanner.c@1.31.1.1 +2 -2 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). + + ntpd/refclock_acts.c@1.36.1.1 +3 -3 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). + + ntpd/refclock_irig.c@1.33 +3 -3 + [Bug 1581] sscanf() target buffers lack room for terminating null. + + ntpdc/ntpdc.c@1.75.1.2 +7 -7 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). + + ntpq/ntpq.c@1.97.1.5 +6 -6 + [Bug 1581] size_t printf format string mismatches (backported from ntp-dev). + +ChangeSet@1.2179, 2010-06-29 12:20:10+02:00, linus@beam.lund.zozs.se + Fixed compilation warnings. + + tests/libntp/prettydate.cpp@1.3 +1 -1 + Fixed compilation warnings. + + tests/libntp/uglydate.cpp@1.2 +1 -1 + Fixed compilation warnings. + +ChangeSet@1.2178, 2010-06-29 10:18:55+00:00, karlsson@psp-fb1.ntp.org + Fixed compilation errors and warnings under FreeBSD + + tests/libntp/ssl_init.cpp@1.2 +4 -4 + Fixed compilation errors and warnings on FreeBSD + + tests/libntp/strtolfp.cpp@1.8 +12 -3 + Fixed compilation errors and warnings on FreeBSD + +ChangeSet@1.2177, 2010-06-29 00:17:05+02:00, linus@beam.lund.zozs.se + Added more tests. + + tests/libntp/caljulian.cpp@1.4 +11 -0 + Added tests for leap year. + + tests/libntp/clocktime.cpp@1.2 +72 -2 + Added more tests. + + tests/libntp/prettydate.cpp@1.2 +0 -4 + Removed empty test stub. + +ChangeSet@1.2176, 2010-06-28 00:18:01+02:00, linus@beam.lund.zozs.se + Added tests for buftvtots and recvbuff. + Also cleaned up code using the lfptest superclass. + + tests/libntp/Makefile.am@1.20 +2 -0 + Added tests for buftvtots and recvbuff + + tests/libntp/buftvtots.cpp@1.1 +49 -0 + New tests + + tests/libntp/buftvtots.cpp@1.0 +0 -0 + + tests/libntp/hextolfp.cpp@1.5 +0 -3 + Moved constants to lfptest superclass. + + tests/libntp/lfptest.h@1.3 +6 -0 + Moved constants to lfptest superclass. + + tests/libntp/recvbuff.cpp@1.1 +38 -0 + New tests + + tests/libntp/recvbuff.cpp@1.0 +0 -0 + + tests/libntp/strtolfp.cpp@1.7 +0 -4 + Moved constants to lfptest superclass. + + tests/libntp/tvtots.cpp@1.3 +0 -4 + Moved constants to lfptest superclass. + +ChangeSet@1.2175, 2010-06-24 23:26:58+02:00, linus@beam.lund.zozs.se + Added tests for calyearstart and clocktime. + + tests/libntp/Makefile.am@1.19 +2 -0 + Added tests for calyearstart, and some tests for clocktime + + tests/libntp/calyearstart.cpp@1.1 +34 -0 + Added tests + + tests/libntp/calyearstart.cpp@1.0 +0 -0 + + tests/libntp/clocktime.cpp@1.1 +65 -0 + Added some tests + + tests/libntp/clocktime.cpp@1.0 +0 -0 + + tests/libntp/tvtots.cpp@1.2 +1 -1 + Disabled one test until I figure out whether it is failing or if I'm just stupid. + +ChangeSet@1.2174, 2010-06-24 15:36:26+02:00, linus@beam.lund.zozs.se + Added tests for caltontp.c + + tests/libntp/Makefile.am@1.18 +1 -0 + Added tests for caltontp() + + tests/libntp/caltontp.cpp@1.1 +49 -0 + Added tests + + tests/libntp/caltontp.cpp@1.0 +0 -0 + +ChangeSet@1.2173, 2010-06-23 14:21:42+02:00, linus@beam.lund.zozs.se + Added tests for statestr, tstotv and tvtots. + + tests/libntp/Makefile.am@1.17 +3 -0 + Added tests for statestr, tstotv and tvtots. + + tests/libntp/lfptest.h@1.2 +3 -1 + Added extra debugging code in comparision code. + + tests/libntp/statestr.cpp@1.1 +27 -0 + Added tests + + tests/libntp/statestr.cpp@1.0 +0 -0 + + tests/libntp/tstotv.cpp@1.1 +57 -0 + Added tests + + tests/libntp/tstotv.cpp@1.0 +0 -0 + + tests/libntp/tvtots.cpp@1.1 +47 -0 + Added tests + + tests/libntp/tvtots.cpp@1.0 +0 -0 + +ChangeSet@1.2172, 2010-06-21 22:49:41+02:00, linus@beam.lund.zozs.se + Added tests for modetoa() and tsftomsu(), and added more tests for authkeys. + + tests/libntp/Makefile.am@1.16 +2 -0 + Added tests for modetoa() and tsftomsu() + + tests/libntp/authkeys.cpp@1.4 +30 -17 + Added some more tests for authusekey.cpp, and removed commented code. + + tests/libntp/modetoa.cpp@1.1 +16 -0 + Added new tests + + tests/libntp/modetoa.cpp@1.0 +0 -0 + + tests/libntp/tsftomsu.cpp@1.1 +29 -0 + Added new tests + + tests/libntp/tsftomsu.cpp@1.0 +0 -0 + +ChangeSet@1.2156.1.7, 2010-06-20 10:10:46+00:00, stenn@deacon.udel.edu + NTP_4_2_7P38 + TAG: NTP_4_2_7P38 + + ChangeLog@1.600 +1 -0 + NTP_4_2_7P38 + + ntpd/ntpd-opts.c@1.39 +2 -2 + NTP_4_2_7P38 + + ntpd/ntpd-opts.h@1.39 +3 -3 + NTP_4_2_7P38 + + ntpd/ntpd-opts.texi@1.39 +2 -2 + NTP_4_2_7P38 + + ntpd/ntpd.1@1.39 +2 -2 + NTP_4_2_7P38 + + ntpdc/ntpdc-opts.c@1.39 +2 -2 + NTP_4_2_7P38 + + ntpdc/ntpdc-opts.h@1.39 +3 -3 + NTP_4_2_7P38 + + ntpdc/ntpdc-opts.texi@1.39 +2 -2 + NTP_4_2_7P38 + + ntpdc/ntpdc.1@1.39 +2 -2 + NTP_4_2_7P38 + + ntpq/ntpq-opts.c@1.39 +2 -2 + NTP_4_2_7P38 + + ntpq/ntpq-opts.h@1.39 +3 -3 + NTP_4_2_7P38 + + ntpq/ntpq-opts.texi@1.39 +2 -2 + NTP_4_2_7P38 + + ntpq/ntpq.1@1.39 +2 -2 + NTP_4_2_7P38 + + ntpsnmpd/ntpsnmpd-opts.c@1.39 +2 -2 + NTP_4_2_7P38 + + ntpsnmpd/ntpsnmpd-opts.h@1.39 +3 -3 + NTP_4_2_7P38 + + ntpsnmpd/ntpsnmpd-opts.texi@1.39 +2 -2 + NTP_4_2_7P38 + + ntpsnmpd/ntpsnmpd.1@1.39 +2 -2 + NTP_4_2_7P38 + + packageinfo.sh@1.40 +1 -1 + NTP_4_2_7P38 + + sntp/sntp-opts.c@1.39 +2 -2 + NTP_4_2_7P38 + + sntp/sntp-opts.h@1.39 +3 -3 + NTP_4_2_7P38 + + sntp/sntp-opts.texi@1.39 +1 -1 + NTP_4_2_7P38 + + sntp/sntp.1@1.39 +2 -2 + NTP_4_2_7P38 + + sntp/sntp.html@1.39 +1 -1 + NTP_4_2_7P38 + + util/ntp-keygen-opts.c@1.39 +2 -2 + NTP_4_2_7P38 + + util/ntp-keygen-opts.h@1.39 +3 -3 + NTP_4_2_7P38 + + util/ntp-keygen-opts.texi@1.39 +2 -2 + NTP_4_2_7P38 + + util/ntp-keygen.1@1.39 +2 -2 + NTP_4_2_7P38 + +ChangeSet@1.2156.1.6, 2010-06-19 18:28:21-04:00, stenn@deacon.udel.edu + typo fix in comment + + ChangeLog@1.599 +1 -0 + typo fix in comment + + ntpd/ntp_proto.c@1.297.1.15 +1 -1 + typo fix in comment + +ChangeSet@1.2156.1.4, 2010-06-19 10:09:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P37 + TAG: NTP_4_2_7P37 + + ChangeLog@1.597 +1 -0 + NTP_4_2_7P37 + + ntpd/ntpd-opts.c@1.38 +2 -2 + NTP_4_2_7P37 + + ntpd/ntpd-opts.h@1.38 +3 -3 + NTP_4_2_7P37 + + ntpd/ntpd-opts.texi@1.38 +2 -2 + NTP_4_2_7P37 + + ntpd/ntpd.1@1.38 +2 -2 + NTP_4_2_7P37 + + ntpdc/ntpdc-opts.c@1.38 +2 -2 + NTP_4_2_7P37 + + ntpdc/ntpdc-opts.h@1.38 +3 -3 + NTP_4_2_7P37 + + ntpdc/ntpdc-opts.texi@1.38 +2 -2 + NTP_4_2_7P37 + + ntpdc/ntpdc.1@1.38 +2 -2 + NTP_4_2_7P37 + + ntpq/ntpq-opts.c@1.38 +2 -2 + NTP_4_2_7P37 + + ntpq/ntpq-opts.h@1.38 +3 -3 + NTP_4_2_7P37 + + ntpq/ntpq-opts.texi@1.38 +2 -2 + NTP_4_2_7P37 + + ntpq/ntpq.1@1.38 +2 -2 + NTP_4_2_7P37 + + ntpsnmpd/ntpsnmpd-opts.c@1.38 +2 -2 + NTP_4_2_7P37 + + ntpsnmpd/ntpsnmpd-opts.h@1.38 +3 -3 + NTP_4_2_7P37 + + ntpsnmpd/ntpsnmpd-opts.texi@1.38 +2 -2 + NTP_4_2_7P37 + + ntpsnmpd/ntpsnmpd.1@1.38 +2 -2 + NTP_4_2_7P37 + + packageinfo.sh@1.39 +1 -1 + NTP_4_2_7P37 + + sntp/sntp-opts.c@1.38 +2 -2 + NTP_4_2_7P37 + + sntp/sntp-opts.h@1.38 +3 -3 + NTP_4_2_7P37 + + sntp/sntp-opts.texi@1.38 +1 -1 + NTP_4_2_7P37 + + sntp/sntp.1@1.38 +2 -2 + NTP_4_2_7P37 + + sntp/sntp.html@1.38 +1 -1 + NTP_4_2_7P37 + + util/ntp-keygen-opts.c@1.38 +2 -2 + NTP_4_2_7P37 + + util/ntp-keygen-opts.h@1.38 +3 -3 + NTP_4_2_7P37 + + util/ntp-keygen-opts.texi@1.38 +2 -2 + NTP_4_2_7P37 + + util/ntp-keygen.1@1.38 +2 -2 + NTP_4_2_7P37 + +ChangeSet@1.2170, 2010-06-19 10:58:13+02:00, linus@beam.lund.zozs.se + Missed a change in the last commit. + + tests/libntp/lfptostr.cpp@1.2 +8 -1 + Forgot to check this file in... + +ChangeSet@1.2169, 2010-06-19 10:57:33+02:00, linus@beam.lund.zozs.se + Added tests for more prettydate, refnumtoa, uflydate, uinttoa and ymd2yd. + + tests/libntp/Makefile.am@1.15 +6 -1 + Added tests for prettydate, refnumtoa, uglydate, uinttoa and ymd2yd. + + tests/libntp/prettydate.cpp@1.1 +20 -0 + Added tests + + tests/libntp/prettydate.cpp@1.0 +0 -0 + + tests/libntp/refnumtoa.cpp@1.1 +48 -0 + Added tests + + tests/libntp/refnumtoa.cpp@1.0 +0 -0 + + tests/libntp/uglydate.cpp@1.1 +18 -0 + Added tests + + tests/libntp/uglydate.cpp@1.0 +0 -0 + + tests/libntp/ymd2yd.cpp@1.1 +23 -0 + Added tests + + tests/libntp/ymd2yd.cpp@1.0 +0 -0 + +ChangeSet@1.2082.4.103, 2010-06-19 02:49:04-04:00, stenn@deacon.udel.edu + NTP_4_2_6P2_RC7 + TAG: NTP_4_2_6P2_RC7 + + ChangeLog@1.496.26.77 +1 -0 + NTP_4_2_6P2_RC7 + + ntpd/ntpd-opts.c@1.248.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpd/ntpd-opts.h@1.248.14.1 +3 -3 + NTP_4_2_6P2_RC7 + + ntpd/ntpd-opts.texi@1.246.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpd/ntpd.1@1.246.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpdc/ntpdc-opts.c@1.244.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpdc/ntpdc-opts.h@1.244.14.1 +3 -3 + NTP_4_2_6P2_RC7 + + ntpdc/ntpdc-opts.texi@1.243.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpdc/ntpdc.1@1.243.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpq/ntpq-opts.c@1.245.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpq/ntpq-opts.h@1.245.14.1 +3 -3 + NTP_4_2_6P2_RC7 + + ntpq/ntpq-opts.texi@1.244.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpq/ntpq.1@1.244.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.15.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.15.1 +3 -3 + NTP_4_2_6P2_RC7 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.15.1 +2 -2 + NTP_4_2_6P2_RC7 + + ntpsnmpd/ntpsnmpd.1@1.122.15.1 +2 -2 + NTP_4_2_6P2_RC7 + + packageinfo.sh@1.255.16.1 +1 -1 + NTP_4_2_6P2_RC7 + + sntp/sntp-opts.c@1.117.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + sntp/sntp-opts.h@1.117.14.1 +3 -3 + NTP_4_2_6P2_RC7 + + sntp/sntp-opts.texi@1.117.14.1 +1 -1 + NTP_4_2_6P2_RC7 + + sntp/sntp.1@1.117.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + sntp/sntp.html@1.7.14.1 +1 -1 + NTP_4_2_6P2_RC7 + + util/ntp-keygen-opts.c@1.247.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + util/ntp-keygen-opts.h@1.247.14.1 +3 -3 + NTP_4_2_6P2_RC7 + + util/ntp-keygen-opts.texi@1.246.14.1 +2 -2 + NTP_4_2_6P2_RC7 + + util/ntp-keygen.1@1.246.14.1 +2 -2 + NTP_4_2_6P2_RC7 + +ChangeSet@1.2082.4.102, 2010-06-19 02:32:32-04:00, stenn@deacon.udel.edu + [Bug 1570] serial clock drivers get outdated input from kernel tty line buffer after startup + + ChangeLog@1.496.26.76 +2 -0 + [Bug 1570] serial clock drivers get outdated input from kernel tty line buffer after startup + + ntpd/ntp_refclock.c@1.92.1.1 +21 -0 + [Bug 1570] serial clock drivers get outdated input from kernel tty line buffer after startup + +ChangeSet@1.2082.4.101, 2010-06-19 01:59:33-04:00, stenn@deacon.udel.edu + merge cleanup + + ChangeLog@1.496.26.75 +2 -3 + merge cleanup + +ChangeSet@1.2082.21.1, 2010-06-19 01:57:32-04:00, stenn@deacon.udel.edu + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD + + ChangeLog@1.496.46.1 +4 -0 + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD + + configure.ac@1.465.1.12 +7 -2 + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD + +ChangeSet@1.2156.1.3, 2010-06-18 21:59:28-07:00, stenn@stenn.ntp.org + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD + + ChangeLog@1.596 +1 -0 + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD + + configure.ac@1.483.1.1 +7 -2 + [Bug 1576] sys/sysctl.h depends on sys/param.h on OpenBSD + +ChangeSet@1.2167, 2010-06-17 08:33:16-04:00, karlsson@psp-deb1.ntp.org + Fixed C90 warnings on psp-deb1, complaining about negative integer constants. + + tests/libntp/hextolfp.cpp@1.4 +1 -1 + Fixed warnings with C90 integer constants + + tests/libntp/inttoa.cpp@1.4 +1 -1 + Fixed warnings with C90 integer constants + + tests/libntp/strtolfp.cpp@1.6 +1 -1 + Fixed warnings with C90 integer constants + +ChangeSet@1.2166, 2010-06-17 13:44:17+02:00, linus@beam.lund.zozs.se + Cleanups, fixed some warnings issued when compiling on psp-deb1. + + tests/libntp/caljulian.cpp@1.3 +2 -2 + Fixed warnings about constant only being unsigned in ISO C90. + + tests/libntp/hextoint.cpp@1.3 +1 -1 + Fixed warnings about constant only being unsigned in ISO C90. + + tests/libntp/hextolfp.cpp@1.3 +5 -2 + Gave some magic constants a name. + + tests/libntp/inttoa.cpp@1.3 +1 -1 + Fixed warnings about constant only being unsigned in ISO C90. + + tests/libntp/numtoa.cpp@1.2 +3 -2 + Fixed integer overflow. + + tests/libntp/octtoint.cpp@1.2 +1 -1 + Fixed warnings about constant only being unsigned in ISO C90. + +ChangeSet@1.2165, 2010-06-17 13:20:09+02:00, linus@beam.lund.zozs.se + Added tests for functions in ssl_init.c and uinttoa.c + + tests/libntp/Makefile.am@1.14 +3 -1 + Added more tests. + + tests/libntp/ssl_init.cpp@1.1 +41 -0 + Added tests for keytype_from_text() and keytype_name() + + tests/libntp/ssl_init.cpp@1.0 +0 -0 + + tests/libntp/uinttoa.cpp@1.1 +12 -0 + Added tests + + tests/libntp/uinttoa.cpp@1.0 +0 -0 + +ChangeSet@1.2164, 2010-06-15 14:10:00-04:00, karlsson@psp-deb1.ntp.org + Fixed formatting issue in humandate() test + + tests/libntp/humandate.cpp@1.2 +4 -3 + Fixed formatting issue + +ChangeSet@1.2161.1.1, 2010-06-15 19:36:59+02:00, linus@beam.lund.zozs.se + Added tests for a number of functions. Tests for inttoa() won't pass until bug 1575 if pulled into repo. + + tests/libntp/Makefile.am@1.13 +8 -2 + Added new tests to build. + + tests/libntp/decodenetnum.cpp@1.2 +2 -37 + Moved comparision code to a super class for all sockaddr_u-related tests. + + tests/libntp/humandate.cpp@1.1 +40 -0 + Added tests for humandate() + + tests/libntp/humandate.cpp@1.0 +0 -0 + + tests/libntp/inttoa.cpp@1.2 +3 -1 + Make sure it is a long. + + tests/libntp/netof.cpp@1.1 +69 -0 + Added tests for netof() + + tests/libntp/netof.cpp@1.0 +0 -0 + + tests/libntp/numtoa.cpp@1.1 +17 -0 + New tests + + tests/libntp/numtoa.cpp@1.0 +0 -0 + + tests/libntp/numtohost.cpp@1.1 +15 -0 + New tests + + tests/libntp/numtohost.cpp@1.0 +0 -0 + + tests/libntp/octtoint.cpp@1.1 +57 -0 + New tests + + tests/libntp/octtoint.cpp@1.0 +0 -0 + + tests/libntp/sockaddrtest.h@1.1 +58 -0 + Extracted common comparision code to super class. + + tests/libntp/sockaddrtest.h@1.0 +0 -0 + + tests/libntp/socktoa.cpp@1.1 +73 -0 + New tests + + tests/libntp/socktoa.cpp@1.0 +0 -0 + + tests/libntp/strtolfp.cpp@1.5 +68 -13 + Renamed from atolfpTest to strtolfpTest, and add test cases for both atolfp and mstolfp. + + tests/libntp/strtolfp.cpp@1.4 +0 -0 + Rename: tests/libntp/atolfp.cpp -> tests/libntp/strtolfp.cpp + +ChangeSet@1.2082.4.99, 2010-06-15 08:25:18-04:00, perlinger@psp-deb1.ntp.org + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c + + ChangeLog@1.496.26.73 +3 -0 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c + + libntp/inttoa.c@1.4 +1 -1 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c + + libntp/tvtoa.c@1.4 +1 -1 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c + + libntp/utvtoa.c@1.4 +1 -1 + [Bug 1575] use snprintf with LIB_BUFLENGTH in inttoa.c, tvtoa.c, utvtoa.c + +ChangeSet@1.2156.1.2, 2010-06-15 10:09:41+00:00, stenn@deacon.udel.edu + NTP_4_2_7P36 + TAG: NTP_4_2_7P36 + + ChangeLog@1.595 +1 -0 + NTP_4_2_7P36 + + ntpd/ntpd-opts.c@1.37 +2 -2 + NTP_4_2_7P36 + + ntpd/ntpd-opts.h@1.37 +3 -3 + NTP_4_2_7P36 + + ntpd/ntpd-opts.texi@1.37 +2 -2 + NTP_4_2_7P36 + + ntpd/ntpd.1@1.37 +2 -2 + NTP_4_2_7P36 + + ntpdc/ntpdc-opts.c@1.37 +2 -2 + NTP_4_2_7P36 + + ntpdc/ntpdc-opts.h@1.37 +3 -3 + NTP_4_2_7P36 + + ntpdc/ntpdc-opts.texi@1.37 +2 -2 + NTP_4_2_7P36 + + ntpdc/ntpdc.1@1.37 +2 -2 + NTP_4_2_7P36 + + ntpq/ntpq-opts.c@1.37 +2 -2 + NTP_4_2_7P36 + + ntpq/ntpq-opts.h@1.37 +3 -3 + NTP_4_2_7P36 + + ntpq/ntpq-opts.texi@1.37 +2 -2 + NTP_4_2_7P36 + + ntpq/ntpq.1@1.37 +2 -2 + NTP_4_2_7P36 + + ntpsnmpd/ntpsnmpd-opts.c@1.37 +2 -2 + NTP_4_2_7P36 + + ntpsnmpd/ntpsnmpd-opts.h@1.37 +3 -3 + NTP_4_2_7P36 + + ntpsnmpd/ntpsnmpd-opts.texi@1.37 +2 -2 + NTP_4_2_7P36 + + ntpsnmpd/ntpsnmpd.1@1.37 +2 -2 + NTP_4_2_7P36 + + packageinfo.sh@1.38 +1 -1 + NTP_4_2_7P36 + + sntp/sntp-opts.c@1.37 +2 -2 + NTP_4_2_7P36 + + sntp/sntp-opts.h@1.37 +3 -3 + NTP_4_2_7P36 + + sntp/sntp-opts.texi@1.37 +1 -1 + NTP_4_2_7P36 + + sntp/sntp.1@1.37 +2 -2 + NTP_4_2_7P36 + + sntp/sntp.html@1.37 +1 -1 + NTP_4_2_7P36 + + util/ntp-keygen-opts.c@1.37 +2 -2 + NTP_4_2_7P36 + + util/ntp-keygen-opts.h@1.37 +3 -3 + NTP_4_2_7P36 + + util/ntp-keygen-opts.texi@1.37 +2 -2 + NTP_4_2_7P36 + + util/ntp-keygen.1@1.37 +2 -2 + NTP_4_2_7P36 + +ChangeSet@1.2161, 2010-06-15 12:05:16+02:00, linus@beam.lund.zozs.se + Added inttoa tests. + + tests/libntp/Makefile.am@1.12 +1 -0 + Added inttoa + + tests/libntp/inttoa.cpp@1.1 +24 -0 + Tests for inttoa. + + tests/libntp/inttoa.cpp@1.0 +0 -0 + +ChangeSet@1.2156.1.1, 2010-06-15 00:24:37-04:00, stenn@deacon.udel.edu + orphanwait changes (Bug 1560) and clockfilter/reachability fixes from Dave Mills + + ChangeLog@1.594 +2 -0 + orphanwait changes (Bug 1560) and clockfilter/reachability fixes from Dave Mills + + include/ntp.h@1.179 +2 -0 + orphanwait changes from Dave Mills + + include/ntpd.h@1.137.1.16 +1 -0 + orphanwait changes from Dave Mills + + ntpd/ntp_proto.c@1.297.1.14 +14 -6 + orphanwait changes and clockfilter/reachability fixes from Dave Mills + + ntpd/ntp_timer.c@1.59 +3 -1 + orphanwait changes from Dave Mills + +ChangeSet@1.2160, 2010-06-14 20:20:24+02:00, linus@beam.lund.zozs.se + Added tests for l_fp string conversions. + + tests/libntp/Makefile.am@1.11 +1 -0 + Added tests for string conversions of l_fp. + + tests/libntp/lfptostr.cpp@1.1 +96 -0 + Added tests for mfptoa, mfptoms and dolfptoa. + + tests/libntp/lfptostr.cpp@1.0 +0 -0 + +ChangeSet@1.2159, 2010-06-14 03:26:21-07:00, karlsson@psp-os1.ntp.org + Corrected configure checks for google test + + configure.ac@1.486 +11 -8 + Added conditional used in automake to decide to build tests or not + + tests/Makefile.am@1.2 +6 -1 + Only recurse into libntp if we have google test installed + +ChangeSet@1.2158, 2010-06-14 11:11:54+02:00, linus@beam.lund.zozs.se + Uses configure script to check for gtest-config. + + configure.ac@1.485 +11 -0 + Uses gtest-config + + tests/libntp/Makefile.am@1.10 +5 -2 + Uses variables from configure script + + tests/main.cpp@1.1 +6 -0 + Main function. + + tests/main.cpp@1.0 +0 -0 + +ChangeSet@1.2152.2.3, 2010-06-13 16:04:31+02:00, linus@beam.lund.zozs.se + Fixed a serious bug when testing a_md5encrypt(), and added more tests for hextolfp + + tests/libntp/a_md5encrypt.cpp@1.3 +10 -5 + Fixed a number of embarrasing bugs (most serious taking memcmp() != 0 as a success when comparing two memory blocks...) + + tests/libntp/hextolfp.cpp@1.2 +33 -0 + Added more tests for hextolfp. + +ChangeSet@1.2156, 2010-06-12 04:25:31-04:00, stenn@deacon.udel.edu + NTP_4_2_7P35 + TAG: NTP_4_2_7P35 + + ChangeLog@1.593 +1 -0 + NTP_4_2_7P35 + + ntpd/ntpd-opts.c@1.36 +2 -2 + NTP_4_2_7P35 + + ntpd/ntpd-opts.h@1.36 +3 -3 + NTP_4_2_7P35 + + ntpd/ntpd-opts.texi@1.36 +2 -2 + NTP_4_2_7P35 + + ntpd/ntpd.1@1.36 +2 -2 + NTP_4_2_7P35 + + ntpdc/ntpdc-opts.c@1.36 +2 -2 + NTP_4_2_7P35 + + ntpdc/ntpdc-opts.h@1.36 +3 -3 + NTP_4_2_7P35 + + ntpdc/ntpdc-opts.texi@1.36 +2 -2 + NTP_4_2_7P35 + + ntpdc/ntpdc.1@1.36 +2 -2 + NTP_4_2_7P35 + + ntpq/ntpq-opts.c@1.36 +2 -2 + NTP_4_2_7P35 + + ntpq/ntpq-opts.h@1.36 +3 -3 + NTP_4_2_7P35 + + ntpq/ntpq-opts.texi@1.36 +2 -2 + NTP_4_2_7P35 + + ntpq/ntpq.1@1.36 +2 -2 + NTP_4_2_7P35 + + ntpsnmpd/ntpsnmpd-opts.c@1.36 +2 -2 + NTP_4_2_7P35 + + ntpsnmpd/ntpsnmpd-opts.h@1.36 +3 -3 + NTP_4_2_7P35 + + ntpsnmpd/ntpsnmpd-opts.texi@1.36 +2 -2 + NTP_4_2_7P35 + + ntpsnmpd/ntpsnmpd.1@1.36 +2 -2 + NTP_4_2_7P35 + + packageinfo.sh@1.37 +1 -1 + NTP_4_2_7P35 + + sntp/sntp-opts.c@1.36 +2 -2 + NTP_4_2_7P35 + + sntp/sntp-opts.h@1.36 +3 -3 + NTP_4_2_7P35 + + sntp/sntp-opts.texi@1.36 +1 -1 + NTP_4_2_7P35 + + sntp/sntp.1@1.36 +2 -2 + NTP_4_2_7P35 + + sntp/sntp.html@1.36 +1 -1 + NTP_4_2_7P35 + + util/ntp-keygen-opts.c@1.36 +2 -2 + NTP_4_2_7P35 + + util/ntp-keygen-opts.h@1.36 +3 -3 + NTP_4_2_7P35 + + util/ntp-keygen-opts.texi@1.36 +2 -2 + NTP_4_2_7P35 + + util/ntp-keygen.1@1.36 +2 -2 + NTP_4_2_7P35 + +ChangeSet@1.2155, 2010-06-12 04:04:03-04:00, stenn@deacon.udel.edu + merge cleanup + + ChangeLog@1.592 +0 -4 + merge cleanup + +ChangeSet@1.2082.4.98, 2010-06-12 02:21:49-04:00, stenn@deacon.udel.edu + NTP_4_2_6P2_RC6 + TAG: NTP_4_2_6P2_RC6 + + ChangeLog@1.496.26.72 +1 -0 + NTP_4_2_6P2_RC6 + + ntpd/ntpd-opts.c@1.248.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpd/ntpd-opts.h@1.248.13.1 +3 -3 + NTP_4_2_6P2_RC6 + + ntpd/ntpd-opts.texi@1.246.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpd/ntpd.1@1.246.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpdc/ntpdc-opts.c@1.244.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpdc/ntpdc-opts.h@1.244.13.1 +3 -3 + NTP_4_2_6P2_RC6 + + ntpdc/ntpdc-opts.texi@1.243.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpdc/ntpdc.1@1.243.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpq/ntpq-opts.c@1.245.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpq/ntpq-opts.h@1.245.13.1 +3 -3 + NTP_4_2_6P2_RC6 + + ntpq/ntpq-opts.texi@1.244.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpq/ntpq.1@1.244.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.14.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.14.1 +3 -3 + NTP_4_2_6P2_RC6 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.14.1 +2 -2 + NTP_4_2_6P2_RC6 + + ntpsnmpd/ntpsnmpd.1@1.122.14.1 +2 -2 + NTP_4_2_6P2_RC6 + + packageinfo.sh@1.255.15.1 +1 -1 + NTP_4_2_6P2_RC6 + + sntp/sntp-opts.c@1.117.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + sntp/sntp-opts.h@1.117.13.1 +3 -3 + NTP_4_2_6P2_RC6 + + sntp/sntp-opts.texi@1.117.13.1 +1 -1 + NTP_4_2_6P2_RC6 + + sntp/sntp.1@1.117.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + sntp/sntp.html@1.7.13.1 +1 -1 + NTP_4_2_6P2_RC6 + + util/ntp-keygen-opts.c@1.247.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + util/ntp-keygen-opts.h@1.247.13.1 +3 -3 + NTP_4_2_6P2_RC6 + + util/ntp-keygen-opts.texi@1.246.13.1 +2 -2 + NTP_4_2_6P2_RC6 + + util/ntp-keygen.1@1.246.13.1 +2 -2 + NTP_4_2_6P2_RC6 + +ChangeSet@1.2152.2.2, 2010-06-10 18:23:22+02:00, linus@beam.(none) + Tests for atolfp, hextoint, decodenetnum, hextolfp, fptoa and fptoms. + + tests/libntp/Makefile.am@1.9 +4 -1 + Added test source files to Makefile.am + + tests/libntp/atolfp.cpp@1.3 +2 -16 + Moved equality check to common base class. + + tests/libntp/decodenetnum.cpp@1.1 +128 -0 + Added tests for decodenetnum() + + tests/libntp/decodenetnum.cpp@1.0 +0 -0 + + tests/libntp/hextoint.cpp@1.2 +33 -20 + Added tests + + tests/libntp/hextolfp.cpp@1.1 +25 -0 + Tests for hextolfp() + + tests/libntp/hextolfp.cpp@1.0 +0 -0 + + tests/libntp/lfptest.h@1.1 +23 -0 + Extracted common code for tests that tests l_fp for equality. + + tests/libntp/lfptest.h@1.0 +0 -0 + + tests/libntp/sfptostr.cpp@1.1 +71 -0 + Tests for fptoa, fptoms and dofptoa. + + tests/libntp/sfptostr.cpp@1.0 +0 -0 + +ChangeSet@1.2147.1.6, 2010-06-09 22:56:19+02:00, linus@beam.(none) + Changes in caljulian tests. + + tests/libntp/caljulian.cpp@1.2 +47 -14 + Added comparition function for calendar structs. + +ChangeSet@1.2147.1.5, 2010-06-09 14:15:12+02:00, linus@beam.(none) + Added tests for atouint and atolfp. + + tests/libntp/Makefile.am@1.8 +2 -0 + Added atouint and caljulian to test suite. + + tests/libntp/a_md5encrypt.cpp@1.2 +13 -12 + Modified name of constants and changed comparision to memcmp instead of strcmp. + + tests/libntp/atoint.cpp@1.2 +2 -6 + Changed some assertions to ASSERT instead of EXPECT (no use to check the value if the conversion was aborted) + + tests/libntp/atolfp.cpp@1.2 +48 -1 + Added tests for atolfp + + tests/libntp/atouint.cpp@1.1 +40 -0 + Tests for atouint. + + tests/libntp/atouint.cpp@1.0 +0 -0 + + tests/libntp/caljulian.cpp@1.1 +35 -0 + Template for caljulian. + + tests/libntp/caljulian.cpp@1.0 +0 -0 + + tests/libntp/libntptest.h@1.2 +4 -0 + ntp_stdlib.h is required by all tests, put it here instead of in each separate test. + +ChangeSet@1.2147.1.4, 2010-06-08 17:07:07+02:00, linus@beam.(none) + Added tests for atoint and atolfp + + tests/libntp/Makefile.am@1.7 +2 -0 + Added atoint and atolfp files to SOURCES. + + tests/libntp/atoint.cpp@1.1 +52 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/atoint.cpp + + tests/libntp/atoint.cpp@1.0 +0 -0 + + tests/libntp/atolfp.cpp@1.1 +14 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/atolfp.cpp + + tests/libntp/atolfp.cpp@1.0 +0 -0 + +ChangeSet@1.2082.4.97, 2010-06-08 13:15:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. + + ChangeLog@1.496.26.71 +4 -0 + [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. + + lib/isc/unix/interfaceiter.c@1.18 +32 -3 + [Bug 715] libisc Linux IPv6 interface iteration drops multicast flags. + patch from joerg@dorchain.net adapted from original by + peter.pramberger@1012surf.net + +ChangeSet@1.2147.1.3, 2010-06-08 12:53:18+02:00, linus@beam.(none) + Added tests for a_md5encrypt. + + tests/libntp/Makefile.am@1.6 +3 -2 + Added tests for a_md5encrypt. + + tests/libntp/a_md5encrypt.cpp@1.1 +78 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/a_md5encrypt.cpp + + tests/libntp/a_md5encrypt.cpp@1.0 +0 -0 + + tests/libntp/authkeys.cpp@1.3 +31 -4 + Modified some of the tests for authkeys + +ChangeSet@1.2147.1.2, 2010-06-08 09:44:46+02:00, linus@beam.(none) + Added tests for authkeys. + + tests/libntp/Makefile.am@1.5 +4 -2 + Fixed linking errors because a crypto library was needed + + tests/libntp/authkeys.cpp@1.2 +48 -4 + Added tests for both auth_havekey and authhavekey. + + tests/libntp/authkeys.cpp@1.1 +29 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/authkeys.cpp + + tests/libntp/authkeys.cpp@1.0 +0 -0 + + tests/libntp/libntptest.cpp@1.1 +9 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/libntptest.cpp + + tests/libntp/libntptest.cpp@1.0 +0 -0 + +ChangeSet@1.2153, 2010-06-08 02:24:01+02:00, jnperlin@hydra.localnet + Rewrite of multiprecision macros in 'ntp_fp.h' from J. Perlinger + + ChangeLog@1.590 +2 -0 + Rewrite of multiprecision macros in 'ntp_fp.h' from J. Perlinger + + include/ntp_fp.h@1.20 +97 -132 + Rewrite of M_xxx macros: cleanup in unsigned & overflow handling + +ChangeSet@1.2152, 2010-06-05 06:47:24+00:00, stenn@deacon.udel.edu + NTP_4_2_7P34 + TAG: NTP_4_2_7P34 + + ChangeLog@1.589 +1 -0 + NTP_4_2_7P34 + + ntpd/ntpd-opts.c@1.35 +2 -2 + NTP_4_2_7P34 + + ntpd/ntpd-opts.h@1.35 +3 -3 + NTP_4_2_7P34 + + ntpd/ntpd-opts.texi@1.35 +2 -2 + NTP_4_2_7P34 + + ntpd/ntpd.1@1.35 +2 -2 + NTP_4_2_7P34 + + ntpdc/ntpdc-opts.c@1.35 +2 -2 + NTP_4_2_7P34 + + ntpdc/ntpdc-opts.h@1.35 +3 -3 + NTP_4_2_7P34 + + ntpdc/ntpdc-opts.texi@1.35 +2 -2 + NTP_4_2_7P34 + + ntpdc/ntpdc.1@1.35 +2 -2 + NTP_4_2_7P34 + + ntpq/ntpq-opts.c@1.35 +2 -2 + NTP_4_2_7P34 + + ntpq/ntpq-opts.h@1.35 +3 -3 + NTP_4_2_7P34 + + ntpq/ntpq-opts.texi@1.35 +2 -2 + NTP_4_2_7P34 + + ntpq/ntpq.1@1.35 +2 -2 + NTP_4_2_7P34 + + ntpsnmpd/ntpsnmpd-opts.c@1.35 +2 -2 + NTP_4_2_7P34 + + ntpsnmpd/ntpsnmpd-opts.h@1.35 +3 -3 + NTP_4_2_7P34 + + ntpsnmpd/ntpsnmpd-opts.texi@1.35 +2 -2 + NTP_4_2_7P34 + + ntpsnmpd/ntpsnmpd.1@1.35 +2 -2 + NTP_4_2_7P34 + + packageinfo.sh@1.36 +1 -1 + NTP_4_2_7P34 + + sntp/sntp-opts.c@1.35 +2 -2 + NTP_4_2_7P34 + + sntp/sntp-opts.h@1.35 +3 -3 + NTP_4_2_7P34 + + sntp/sntp-opts.texi@1.35 +1 -1 + NTP_4_2_7P34 + + sntp/sntp.1@1.35 +2 -2 + NTP_4_2_7P34 + + sntp/sntp.html@1.35 +1 -1 + NTP_4_2_7P34 + + util/ntp-keygen-opts.c@1.35 +2 -2 + NTP_4_2_7P34 + + util/ntp-keygen-opts.h@1.35 +3 -3 + NTP_4_2_7P34 + + util/ntp-keygen-opts.texi@1.35 +2 -2 + NTP_4_2_7P34 + + util/ntp-keygen.1@1.35 +2 -2 + NTP_4_2_7P34 + +ChangeSet@1.2150, 2010-06-04 23:12:55-07:00, stenn@stenn.ntp.org + fix typo + + ntpd/ntp_refclock.c@1.96 +1 -1 + fix typo + +ChangeSet@1.2149, 2010-06-04 19:21:26+02:00, jnperlin@hydra.localnet + [Bug 1570] serial line drivers get outdated data from kernel tty line buffer after startup + + BitKeeper/etc/ignore@1.76 +5 -0 + Added m4/libtool.m4 m4/ltoptions.m4 m4/ltsugar.m4 m4/ltversion.m4 m4/lt~obsolete.m4 to the ignore list + + ChangeLog@1.587 +2 -2 + [Bug 1570] serial line drivers get outdated data from kernel tty line buffer after startup + + ntpd/ntp_refclock.c@1.95 +8 -9 + [Bug 1570] flush I/O buffers and read all old data when opening a serial line + +ChangeSet@1.2146.1.2, 2010-06-04 03:26:47-04:00, perlinger@psp-deb1.ntp.org + bug 1580 fix + + ChangeLog@1.584.1.1 +2 -0 + added bug 1580 + +ChangeSet@1.2146.1.1, 2010-06-04 08:34:03+02:00, jnperlin@hydra.localnet + [Bug 1580] Purge tty line buffers so serial refclocks do not get outdated data immediately after startup. + + ntpd/ntp_refclock.c@1.94 +22 -0 + [Bug 1580] Try to flush all buffers and/or read away old input data when opening a serial line for a refclock. + +ChangeSet@1.2147, 2010-06-04 02:10:49-04:00, stenn@deacon.udel.edu + NTP_4_2_7P33 + TAG: NTP_4_2_7P33 + + ChangeLog@1.585 +1 -0 + NTP_4_2_7P33 + + ntpd/ntpd-opts.c@1.34 +2 -2 + NTP_4_2_7P33 + + ntpd/ntpd-opts.h@1.34 +3 -3 + NTP_4_2_7P33 + + ntpd/ntpd-opts.texi@1.34 +2 -2 + NTP_4_2_7P33 + + ntpd/ntpd.1@1.34 +2 -2 + NTP_4_2_7P33 + + ntpdc/ntpdc-opts.c@1.34 +2 -2 + NTP_4_2_7P33 + + ntpdc/ntpdc-opts.h@1.34 +3 -3 + NTP_4_2_7P33 + + ntpdc/ntpdc-opts.texi@1.34 +2 -2 + NTP_4_2_7P33 + + ntpdc/ntpdc.1@1.34 +2 -2 + NTP_4_2_7P33 + + ntpq/ntpq-opts.c@1.34 +2 -2 + NTP_4_2_7P33 + + ntpq/ntpq-opts.h@1.34 +3 -3 + NTP_4_2_7P33 + + ntpq/ntpq-opts.texi@1.34 +2 -2 + NTP_4_2_7P33 + + ntpq/ntpq.1@1.34 +2 -2 + NTP_4_2_7P33 + + ntpsnmpd/ntpsnmpd-opts.c@1.34 +2 -2 + NTP_4_2_7P33 + + ntpsnmpd/ntpsnmpd-opts.h@1.34 +3 -3 + NTP_4_2_7P33 + + ntpsnmpd/ntpsnmpd-opts.texi@1.34 +24 -2 + NTP_4_2_7P33 + + ntpsnmpd/ntpsnmpd.1@1.34 +2 -2 + NTP_4_2_7P33 + + packageinfo.sh@1.35 +1 -1 + NTP_4_2_7P33 + + sntp/sntp-opts.c@1.34 +2 -2 + NTP_4_2_7P33 + + sntp/sntp-opts.h@1.34 +3 -3 + NTP_4_2_7P33 + + sntp/sntp-opts.texi@1.34 +1 -1 + NTP_4_2_7P33 + + sntp/sntp.1@1.34 +2 -2 + NTP_4_2_7P33 + + sntp/sntp.html@1.34 +1 -1 + NTP_4_2_7P33 + + util/ntp-keygen-opts.c@1.34 +2 -2 + NTP_4_2_7P33 + + util/ntp-keygen-opts.h@1.34 +3 -3 + NTP_4_2_7P33 + + util/ntp-keygen-opts.texi@1.34 +2 -2 + NTP_4_2_7P33 + + util/ntp-keygen.1@1.34 +2 -2 + NTP_4_2_7P33 + +ChangeSet@1.2082.4.96, 2010-06-03 02:24:13-04:00, stenn@deacon.udel.edu + NTP_4_2_6P2_RC5 + TAG: NTP_4_2_6P2_RC5 + + ChangeLog@1.496.26.70 +1 -0 + NTP_4_2_6P2_RC5 + + ntpd/ntpd-opts.c@1.248.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpd/ntpd-opts.h@1.248.12.1 +3 -3 + NTP_4_2_6P2_RC5 + + ntpd/ntpd-opts.texi@1.246.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpd/ntpd.1@1.246.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpdc/ntpdc-opts.c@1.244.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpdc/ntpdc-opts.h@1.244.12.1 +3 -3 + NTP_4_2_6P2_RC5 + + ntpdc/ntpdc-opts.texi@1.243.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpdc/ntpdc.1@1.243.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpq/ntpq-opts.c@1.245.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpq/ntpq-opts.h@1.245.12.1 +3 -3 + NTP_4_2_6P2_RC5 + + ntpq/ntpq-opts.texi@1.244.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpq/ntpq.1@1.244.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.13.1 +2 -2 + NTP_4_2_6P2_RC5 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.13.1 +3 -3 + NTP_4_2_6P2_RC5 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.13.1 +24 -2 + NTP_4_2_6P2_RC5 + + ntpsnmpd/ntpsnmpd.1@1.122.13.1 +2 -2 + NTP_4_2_6P2_RC5 + + packageinfo.sh@1.255.14.1 +1 -1 + NTP_4_2_6P2_RC5 + + sntp/sntp-opts.c@1.117.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + sntp/sntp-opts.h@1.117.12.1 +3 -3 + NTP_4_2_6P2_RC5 + + sntp/sntp-opts.texi@1.117.12.1 +1 -1 + NTP_4_2_6P2_RC5 + + sntp/sntp.1@1.117.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + sntp/sntp.html@1.7.12.1 +1 -1 + NTP_4_2_6P2_RC5 + + util/ntp-keygen-opts.c@1.247.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + util/ntp-keygen-opts.h@1.247.12.1 +3 -3 + NTP_4_2_6P2_RC5 + + util/ntp-keygen-opts.texi@1.246.12.1 +2 -2 + NTP_4_2_6P2_RC5 + + util/ntp-keygen.1@1.246.12.1 +2 -2 + NTP_4_2_6P2_RC5 + +ChangeSet@1.2144.1.5, 2010-06-01 22:25:33+02:00, linus@beam.(none) + Modified Makefile for conditional testing + + tests/libntp/Makefile.am@1.4 +3 -1 + Modified conditionals + +ChangeSet@1.2144.1.4, 2010-06-01 20:21:04+02:00, linus@beam.(none) + Changed so that tests are not run during a cross compilation + + tests/libntp/Makefile.am@1.3 +2 -0 + Tests are not run when cross-compiling + +ChangeSet@1.2082.4.95, 2010-05-31 18:59:05+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). + + + ChangeLog@1.496.26.69 +1 -0 + [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). + + + sntp/configure.ac@1.31.1.2 +1 -1 + [Bug 1565] sntp/crypto.c compile fails on MacOS over vsnprintf(). + + +ChangeSet@1.2144.1.3, 2010-05-28 15:31:29+02:00, linus@beam.(none) + Tuned makefile.am + + tests/libntp/Makefile.am@1.2 +5 -1 + Copied include directories from Makefile.am in libntp/ + +ChangeSet@1.2144.1.2, 2010-05-28 14:13:18+02:00, linus@beam.(none) + Added base test classes and makefiles to repo + + tests/Makefile.am@1.1 +1 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/Makefile.am + + tests/Makefile.am@1.0 +0 -0 + + tests/libntp/Makefile.am@1.1 +6 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/Makefile.am + + tests/libntp/Makefile.am@1.0 +0 -0 + + tests/libntp/hextoint.cpp@1.1 +29 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/hextoint.cpp + + tests/libntp/hextoint.cpp@1.0 +0 -0 + + tests/libntp/libntptest.h@1.1 +5 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/libntp/libntptest.h + + tests/libntp/libntptest.h@1.0 +0 -0 + + tests/main.h@1.1 +7 -0 + BitKeeper file /home/linus/programming/gsoc/ntp/ntp-gsoc-testing/tests/main.h + + tests/main.h@1.0 +0 -0 + +ChangeSet@1.2144.1.1, 2010-05-28 07:59:21-04:00, karlsson@psp-deb1.ntp.org + Modified autotools to recurse into tests + + Makefile.am@1.94 +4 -0 + Added tests subdir + + configure.ac@1.484 +4 -0 + Added configure changes to create makefiles + +ChangeSet@1.2082.4.94, 2010-05-24 15:46:36+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. + Support "passwd blah" syntax in ntpq. + + ChangeLog@1.496.26.68 +7 -0 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. + Support "passwd blah" syntax in ntpq. + + include/ntp_stdlib.h@1.40.1.2 +1 -0 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + + libntp/ssl_init.c@1.4.1.1 +25 -0 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + + ntpdc/ntpdc.c@1.75.1.1 +2 -14 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + + ntpq/ntpq.c@1.97.1.4 +16 -21 + [Bug 1561] ntpq, ntpdc "passwd" prompts for MD5 password w/SHA1. + Support "passwd blah" syntax in ntpq. + + ports/winnt/ntpd/nt_clockstuff.c@1.38.1.2 +6 -3 + Windows port: do not exit in ntp_timestamp_from_counter() without + first logging the reason. + +ChangeSet@1.2144, 2010-05-19 10:09:40+00:00, stenn@deacon.udel.edu + NTP_4_2_7P32 + TAG: NTP_4_2_7P32 + + ChangeLog@1.582 +1 -0 + NTP_4_2_7P32 + + ntpd/ntpd-opts.c@1.33 +2 -2 + NTP_4_2_7P32 + + ntpd/ntpd-opts.h@1.33 +3 -3 + NTP_4_2_7P32 + + ntpd/ntpd-opts.texi@1.33 +2 -2 + NTP_4_2_7P32 + + ntpd/ntpd.1@1.33 +2 -2 + NTP_4_2_7P32 + + ntpdc/ntpdc-opts.c@1.33 +2 -2 + NTP_4_2_7P32 + + ntpdc/ntpdc-opts.h@1.33 +3 -3 + NTP_4_2_7P32 + + ntpdc/ntpdc-opts.texi@1.33 +2 -2 + NTP_4_2_7P32 + + ntpdc/ntpdc.1@1.33 +2 -2 + NTP_4_2_7P32 + + ntpq/ntpq-opts.c@1.33 +2 -2 + NTP_4_2_7P32 + + ntpq/ntpq-opts.h@1.33 +3 -3 + NTP_4_2_7P32 + + ntpq/ntpq-opts.texi@1.33 +2 -2 + NTP_4_2_7P32 + + ntpq/ntpq.1@1.33 +2 -2 + NTP_4_2_7P32 + + ntpsnmpd/ntpsnmpd-opts.c@1.33 +2 -2 + NTP_4_2_7P32 + + ntpsnmpd/ntpsnmpd-opts.h@1.33 +3 -3 + NTP_4_2_7P32 + + ntpsnmpd/ntpsnmpd-opts.texi@1.33 +1 -1 + NTP_4_2_7P32 + + ntpsnmpd/ntpsnmpd.1@1.33 +2 -2 + NTP_4_2_7P32 + + packageinfo.sh@1.34 +1 -1 + NTP_4_2_7P32 + + sntp/sntp-opts.c@1.33 +2 -2 + NTP_4_2_7P32 + + sntp/sntp-opts.h@1.33 +3 -3 + NTP_4_2_7P32 + + sntp/sntp-opts.texi@1.33 +1 -1 + NTP_4_2_7P32 + + sntp/sntp.1@1.33 +2 -2 + NTP_4_2_7P32 + + sntp/sntp.html@1.33 +1 -1 + NTP_4_2_7P32 + + util/ntp-keygen-opts.c@1.33 +2 -2 + NTP_4_2_7P32 + + util/ntp-keygen-opts.h@1.33 +3 -3 + NTP_4_2_7P32 + + util/ntp-keygen-opts.texi@1.33 +2 -2 + NTP_4_2_7P32 + + util/ntp-keygen.1@1.33 +2 -2 + NTP_4_2_7P32 + +ChangeSet@1.2143, 2010-05-19 00:55:54-04:00, stenn@deacon.udel.edu + Copyright file cleanup from Dave Mills + + ChangeLog@1.581 +1 -0 + Copyright file cleanup from Dave Mills + + html/copyright.html@1.50 +4 -4 + Copyright file cleanup from Dave Mills + +ChangeSet@1.2082.4.93, 2010-05-19 00:02:06-04:00, stenn@deacon.udel.edu + NTP_4_2_6P2_RC4 + TAG: NTP_4_2_6P2_RC4 + + ChangeLog@1.496.26.67 +1 -0 + NTP_4_2_6P2_RC4 + + ntpd/ntpd-opts.c@1.248.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpd/ntpd-opts.h@1.248.11.1 +3 -3 + NTP_4_2_6P2_RC4 + + ntpd/ntpd-opts.texi@1.246.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpd/ntpd.1@1.246.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpdc/ntpdc-opts.c@1.244.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpdc/ntpdc-opts.h@1.244.11.1 +3 -3 + NTP_4_2_6P2_RC4 + + ntpdc/ntpdc-opts.texi@1.243.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpdc/ntpdc.1@1.243.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpq/ntpq-opts.c@1.245.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpq/ntpq-opts.h@1.245.11.1 +3 -3 + NTP_4_2_6P2_RC4 + + ntpq/ntpq-opts.texi@1.244.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpq/ntpq.1@1.244.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.12.1 +2 -2 + NTP_4_2_6P2_RC4 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.12.1 +3 -3 + NTP_4_2_6P2_RC4 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.12.1 +1 -1 + NTP_4_2_6P2_RC4 + + ntpsnmpd/ntpsnmpd.1@1.122.12.1 +2 -2 + NTP_4_2_6P2_RC4 + + packageinfo.sh@1.255.13.1 +1 -1 + NTP_4_2_6P2_RC4 + + sntp/sntp-opts.c@1.117.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + sntp/sntp-opts.h@1.117.11.1 +3 -3 + NTP_4_2_6P2_RC4 + + sntp/sntp-opts.texi@1.117.11.1 +1 -1 + NTP_4_2_6P2_RC4 + + sntp/sntp.1@1.117.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + sntp/sntp.html@1.7.11.1 +1 -1 + NTP_4_2_6P2_RC4 + + util/ntp-keygen-opts.c@1.247.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + util/ntp-keygen-opts.h@1.247.11.1 +3 -3 + NTP_4_2_6P2_RC4 + + util/ntp-keygen-opts.texi@1.246.11.1 +2 -2 + NTP_4_2_6P2_RC4 + + util/ntp-keygen.1@1.246.11.1 +2 -2 + NTP_4_2_6P2_RC4 + +ChangeSet@1.2141, 2010-05-18 01:36:23+00:00, davehart@shiny.ad.hartbrothers.com + Windows port: Add msyslog() on path to exit(), relax PPS timestamp + within one minute of now check to be used only if debug tracing is + enabled. + + ports/winnt/ntpd/nt_clockstuff.c@1.44 +6 -3 + Windows port: Add msyslog() on path to exit(), relax PPS timestamp + within one minute of now check to be used only if debug tracing is + enabled. + +ChangeSet@1.2140, 2010-05-18 00:36:59+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1558] pool prototype associations have 0.0.0.0 for remote addr. + + ChangeLog@1.579 +1 -0 + [Bug 1558] pool prototype associations have 0.0.0.0 for remote addr. + + ntpq/ntpq-subs.c@1.68 +3 -1 + [Bug 1558] pool prototype associations have 0.0.0.0 for remote addr. + +ChangeSet@1.2139, 2010-05-17 21:32:08+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: add --disable-autokey, #define AUTOKEY to enable future + support for building without Autokey, but with OpenSSL for its digest + algorithms (hash functions). Code must be modified to use #ifdef + AUTOKEY instead of #ifdef OPENSSL where appropriate to complete this. + include/ntp_crypto.h: make assumption AUTOKEY implies OPENSSL explicit. + + ChangeLog@1.578 +5 -0 + configure.ac: add --disable-autokey, #define AUTOKEY to enable future + support for building without Autokey, but with OpenSSL for its digest + algorithms (hash functions). Code must be modified to use #ifdef + AUTOKEY instead of #ifdef OPENSSL where appropriate to complete this. + include/ntp_crypto.h: make assumption AUTOKEY implies OPENSSL explicit. + + configure.ac@1.483 +27 -9 + Add --disable-autokey, #define AUTOKEY to enable future + support for building without Autokey, but with OpenSSL for its digest + algorithms (hash functions). Code must be modified to use #ifdef + AUTOKEY instead of #ifdef OPENSSL where appropriate to complete this. + Remove long-dead RSAREF-related configure.ac commented code. + + include/ntp_crypto.h@1.48 +5 -0 + Ensure code can assume OPENSSL is defined if AUTOKEY is. + +ChangeSet@1.2082.4.92, 2010-05-13 15:39:47+00:00, davehart@shiny.ad.hartbrothers.com + * [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + + + ChangeLog@1.496.26.66 +4 -0 + * [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + + + sntp/networking.c@1.29.1.6 +5 -3 + * [Bug 1555] 4.2.6p2-RC3 sntp illegal C (mixed code and declarations). + + +ChangeSet@1.2137, 2010-05-11 10:10:19+00:00, stenn@deacon.udel.edu + NTP_4_2_7P31 + TAG: NTP_4_2_7P31 + + ChangeLog@1.576 +1 -0 + NTP_4_2_7P31 + + ntpd/ntpd-opts.c@1.32 +2 -2 + NTP_4_2_7P31 + + ntpd/ntpd-opts.h@1.32 +3 -3 + NTP_4_2_7P31 + + ntpd/ntpd-opts.texi@1.32 +2 -2 + NTP_4_2_7P31 + + ntpd/ntpd.1@1.32 +2 -2 + NTP_4_2_7P31 + + ntpdc/ntpdc-opts.c@1.32 +2 -2 + NTP_4_2_7P31 + + ntpdc/ntpdc-opts.h@1.32 +3 -3 + NTP_4_2_7P31 + + ntpdc/ntpdc-opts.texi@1.32 +2 -2 + NTP_4_2_7P31 + + ntpdc/ntpdc.1@1.32 +2 -2 + NTP_4_2_7P31 + + ntpq/ntpq-opts.c@1.32 +2 -2 + NTP_4_2_7P31 + + ntpq/ntpq-opts.h@1.32 +3 -3 + NTP_4_2_7P31 + + ntpq/ntpq-opts.texi@1.32 +2 -2 + NTP_4_2_7P31 + + ntpq/ntpq.1@1.32 +2 -2 + NTP_4_2_7P31 + + ntpsnmpd/ntpsnmpd-opts.c@1.32 +2 -2 + NTP_4_2_7P31 + + ntpsnmpd/ntpsnmpd-opts.h@1.32 +3 -3 + NTP_4_2_7P31 + + ntpsnmpd/ntpsnmpd-opts.texi@1.32 +1 -1 + NTP_4_2_7P31 + + ntpsnmpd/ntpsnmpd.1@1.32 +2 -2 + NTP_4_2_7P31 + + packageinfo.sh@1.33 +1 -1 + NTP_4_2_7P31 + + sntp/sntp-opts.c@1.32 +2 -2 + NTP_4_2_7P31 + + sntp/sntp-opts.h@1.32 +3 -3 + NTP_4_2_7P31 + + sntp/sntp-opts.texi@1.32 +2 -60 + NTP_4_2_7P31 + + sntp/sntp.1@1.32 +2 -2 + NTP_4_2_7P31 + + sntp/sntp.html@1.32 +1 -1 + NTP_4_2_7P31 + + util/ntp-keygen-opts.c@1.32 +2 -2 + NTP_4_2_7P31 + + util/ntp-keygen-opts.h@1.32 +3 -3 + NTP_4_2_7P31 + + util/ntp-keygen-opts.texi@1.32 +2 -2 + NTP_4_2_7P31 + + util/ntp-keygen.1@1.32 +2 -2 + NTP_4_2_7P31 + +ChangeSet@1.2082.4.91, 2010-05-11 03:56:04-04:00, stenn@deacon.udel.edu + NTP_4_2_6P2_RC3 + TAG: NTP_4_2_6P2_RC3 + + ChangeLog@1.496.26.65 +1 -0 + NTP_4_2_6P2_RC3 + + ntpd/ntpd-opts.c@1.248.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpd/ntpd-opts.h@1.248.10.1 +3 -3 + NTP_4_2_6P2_RC3 + + ntpd/ntpd-opts.texi@1.246.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpd/ntpd.1@1.246.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc-opts.c@1.244.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc-opts.h@1.244.10.1 +3 -3 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc-opts.texi@1.243.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpdc/ntpdc.1@1.243.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpq/ntpq-opts.c@1.245.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpq/ntpq-opts.h@1.245.10.1 +3 -3 + NTP_4_2_6P2_RC3 + + ntpq/ntpq-opts.texi@1.244.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpq/ntpq.1@1.244.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.11.1 +5 -5 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.11.1 +4 -4 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.11.1 +2 -24 + NTP_4_2_6P2_RC3 + + ntpsnmpd/ntpsnmpd.1@1.122.11.1 +2 -2 + NTP_4_2_6P2_RC3 + + packageinfo.sh@1.255.12.1 +1 -1 + NTP_4_2_6P2_RC3 + + sntp/sntp-opts.c@1.117.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + sntp/sntp-opts.h@1.117.10.1 +3 -3 + NTP_4_2_6P2_RC3 + + sntp/sntp-opts.texi@1.117.10.1 +2 -60 + NTP_4_2_6P2_RC3 + + sntp/sntp.1@1.117.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + sntp/sntp.html@1.7.10.1 +1 -1 + NTP_4_2_6P2_RC3 + + util/ntp-keygen-opts.c@1.247.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + util/ntp-keygen-opts.h@1.247.10.1 +3 -3 + NTP_4_2_6P2_RC3 + + util/ntp-keygen-opts.texi@1.246.10.1 +2 -2 + NTP_4_2_6P2_RC3 + + util/ntp-keygen.1@1.246.10.1 +2 -2 + NTP_4_2_6P2_RC3 + +ChangeSet@1.2082.20.1, 2010-05-11 02:31:19-04:00, stenn@deacon.udel.edu + Windows compiling hints/winnt.html update from G. Sunil Tej + + ChangeLog@1.496.45.1 +1 -0 + Windows compiling hints/winnt.html update from G. Sunil Tej + + html/hints/winnt.html@1.19.1.1 +13 -11 + Windows compiling hints/winnt.html update from G. Sunil Tej + +ChangeSet@1.2082.4.89, 2010-05-11 04:44:37+00:00, davehart@shiny.ad.hartbrothers.com + Add Nelson B Bolyard to html/copyright.html. + Update ChangeLog entries to reflect filing of [Bug 1552], [Bug 1553]. + + ChangeLog@1.496.26.63 +2 -29 + Update ChangeLog entries to reflect filing of [Bug 1552], [Bug 1553]. + + html/copyright.html@1.46.1.1 +4 -3 + Add Nelson B Bolyard to html/copyright.html. + +ChangeSet@1.2082.4.88, 2010-05-10 13:16:18+00:00, davehart@shiny.ad.hartbrothers.com + Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) + Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. + + ChangeLog@1.496.26.62 +3 -0 + Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) + Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. + + include/ntp_md5.h@1.3.1.1 +21 -5 + expose OpenSSL hash API even when building without OpenSSL, + to simplify client code. Backport from ntp-dev. + + libntp/a_md5encrypt.c@1.26.1.1 +3 -38 + expose OpenSSL hash API even when building without OpenSSL, + to simplify client code. Backport from ntp-dev. + + sntp/crypto.c@1.10.1.2 +34 -64 + remove s_keytype_from_text(), use similar keytype_from_text() from libntp. + + sntp/crypto.h@1.9 +4 -7 + bring in line with other ntp_md5.h client code + + sntp/networking.c@1.29.1.5 +15 -16 + Simplify hash client code by providing OpenSSL EVP_*() API when built + without OpenSSL. (from ntp-dev) + Do not depend on ASCII values for ('A' - '0'), ('a' - '0') in sntp. + +ChangeSet@1.2082.4.87, 2010-05-09 10:38:44+00:00, davehart@shiny.ad.hartbrothers.com + Correct ChangeLog spelling of Nelson Bolyard's name, add email address. + + ChangeLog@1.496.26.61 +1 -1 + Correct ChangeLog spelling of Nelson Bolyard's name, add email address. + +ChangeSet@1.2082.4.86, 2010-05-09 08:12:20+00:00, davehart@shiny.ad.hartbrothers.com + cleanup prior changeset, ease -dev merge. + + ntpq/ntpq-subs.c@1.39.2.3 +7 -7 + remove leftover of earlier approach, match AF_UNSPEC use to ntp-dev. + align with ntp-dev regarding empty refid= value from ntpd. + + ntpq/ntpq.c@1.97.1.3 +1 -1 + use const qualifier for makeascii char *. + + ntpq/ntpq.h@1.10.1.2 +1 -1 + use const qualifier for makeascii char *. + +ChangeSet@1.2082.4.85, 2010-05-09 06:33:09+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1325] unreachable code in sntp recv_bcst_data(). + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + Escape unprintable characters in a refid in ntpq -p billboard. + + ChangeLog@1.496.26.60 +32 -0 + [Bug 1325] unreachable code in sntp recv_bcst_data(). + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + Escape unprintable characters in a refid in ntpq -p billboard. + + configure.ac@1.465.1.11 +1 -175 + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + + m4/ntp_openssl.m4@1.1 +182 -0 + moved from configure.ac to include to share with sntp/configure.ac + + m4/ntp_openssl.m4@1.0 +0 -0 + + ntpq/ntpq-subs.c@1.39.2.2 +9 -3 + Escape unprintable characters in a refid in ntpq -p billboard. + + ntpq/ntpq.c@1.97.1.2 +1 -2 + Escape unprintable characters in a refid in ntpq -p billboard. + + ntpq/ntpq.h@1.10.1.1 +1 -0 + Escape unprintable characters in a refid in ntpq -p billboard. + + sntp/Makefile.am@1.21.1.8 +1 -1 + add conditional -lcrypto to LDADD to link against OpenSSL. + + sntp/configure.ac@1.31.1.1 +3 -0 + sntp/configure.ac OpenSSL support now that sntp optionally uses it. + + sntp/crypto.c@1.10.1.1 +134 -69 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + + + sntp/crypto.h@1.8 +12 -6 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + + + sntp/main.c@1.24.1.1 +110 -103 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + + + sntp/networking.c@1.29.1.4 +216 -432 + [Bug 1325] unreachable code in sntp recv_bcst_data(). + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + + + sntp/networking.h@1.18 +3 -3 + [Bug 1459] sntp MD5 authentication does not work with ntpd. + Many sntp fixes from Nelson Boyard: + 1. sntp properly handles hex key strings in the keyfile, instead of + just treating the text as binary strings. + 2. sntp handles SHA1 as well as MD5. + 3. If the key file contains more than one key, sntp can use keys + other than the first one in the file. + 4. sntp computes the MAC using the key, then the data (was other way). + 5. sntp handles responses with extensions now. + 6. sntp implements the -b (broadcast/multicast) option. Tested. + The -b option takes an argument which is the broadcast/multicast + address on which to listen for packets. The command still requires a + host address at the end of the command line. This is the address + expected to do the broadcasting/multicasting. + 7. sntp correctly handles network-order key IDs on little-endian. + 8. Eliminated a huge amount of code duplication between the sntp + unicast and multicast code paths, creating a single process_pkt() + function that is used for both paths after the packet is received. + 9. The -t timeout option now works with both unicast and multicast. + Previously it worked with neither. It wasn't coded for unicast, and + was incorrectly coded for multicast. + 10. In unicast mode, the requests are sent MACed using the key + specified with the -a command line option. + 11. Cleaned up indentation consistent with the predominant style in + the files changed, namely, using tab stop characters and not spaces + for indentation. This way, you can set your tab stop spacing as you + like it and the indentation looks correct. This was not a big change. + The files were mostly consistent before. + 12. Eliminated LOTS of blank lines. + + +ChangeSet@1.2133, 2010-05-06 10:09:32+00:00, stenn@deacon.udel.edu + NTP_4_2_7P30 + TAG: NTP_4_2_7P30 + + ChangeLog@1.572 +1 -0 + NTP_4_2_7P30 + + ntpd/ntpd-opts.c@1.31 +2 -2 + NTP_4_2_7P30 + + ntpd/ntpd-opts.h@1.31 +3 -3 + NTP_4_2_7P30 + + ntpd/ntpd-opts.texi@1.31 +2 -2 + NTP_4_2_7P30 + + ntpd/ntpd.1@1.31 +2 -2 + NTP_4_2_7P30 + + ntpdc/ntpdc-opts.c@1.31 +2 -2 + NTP_4_2_7P30 + + ntpdc/ntpdc-opts.h@1.31 +3 -3 + NTP_4_2_7P30 + + ntpdc/ntpdc-opts.texi@1.31 +2 -2 + NTP_4_2_7P30 + + ntpdc/ntpdc.1@1.31 +2 -2 + NTP_4_2_7P30 + + ntpq/ntpq-opts.c@1.31 +2 -2 + NTP_4_2_7P30 + + ntpq/ntpq-opts.h@1.31 +3 -3 + NTP_4_2_7P30 + + ntpq/ntpq-opts.texi@1.31 +2 -2 + NTP_4_2_7P30 + + ntpq/ntpq.1@1.31 +2 -2 + NTP_4_2_7P30 + + ntpsnmpd/ntpsnmpd-opts.c@1.31 +2 -2 + NTP_4_2_7P30 + + ntpsnmpd/ntpsnmpd-opts.h@1.31 +3 -3 + NTP_4_2_7P30 + + ntpsnmpd/ntpsnmpd-opts.texi@1.31 +1 -1 + NTP_4_2_7P30 + + ntpsnmpd/ntpsnmpd.1@1.31 +2 -2 + NTP_4_2_7P30 + + packageinfo.sh@1.32 +1 -1 + NTP_4_2_7P30 + + sntp/sntp-opts.c@1.31 +2 -2 + NTP_4_2_7P30 + + sntp/sntp-opts.h@1.31 +3 -3 + NTP_4_2_7P30 + + sntp/sntp-opts.texi@1.31 +2 -2 + NTP_4_2_7P30 + + sntp/sntp.1@1.31 +2 -2 + NTP_4_2_7P30 + + sntp/sntp.html@1.31 +1 -1 + NTP_4_2_7P30 + + util/ntp-keygen-opts.c@1.31 +2 -2 + NTP_4_2_7P30 + + util/ntp-keygen-opts.h@1.31 +3 -3 + NTP_4_2_7P30 + + util/ntp-keygen-opts.texi@1.31 +2 -2 + NTP_4_2_7P30 + + util/ntp-keygen.1@1.31 +2 -2 + NTP_4_2_7P30 + +ChangeSet@1.2132, 2010-05-05 10:27:23+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1526] ntpd DNS pipe read EINTR with no network at startup. + + ChangeLog@1.571 +1 -0 + [Bug 1526] ntpd DNS pipe read EINTR with no network at startup. + + ntpd/work_fork.c@1.4 +1 -9 + [Bug 1526] ntpd DNS pipe read EINTR with no network at startup. + +ChangeSet@1.2131, 2010-05-05 03:58:07-04:00, stenn@deacon.udel.edu + Update the ChangeLog entries when merging items from -stable + + ChangeLog@1.570 +52 -51 + Update the ChangeLog entries when merging items from -stable + +ChangeSet@1.2126.1.5, 2010-05-04 22:34:37-04:00, stenn@deacon.udel.edu + NTP_4_2_7P29 + TAG: NTP_4_2_7P29 + + ChangeLog@1.566.1.5 +1 -0 + NTP_4_2_7P29 + + ntpd/ntpd-opts.c@1.30 +2 -2 + NTP_4_2_7P29 + + ntpd/ntpd-opts.h@1.30 +3 -3 + NTP_4_2_7P29 + + ntpd/ntpd-opts.texi@1.30 +2 -2 + NTP_4_2_7P29 + + ntpd/ntpd.1@1.30 +2 -2 + NTP_4_2_7P29 + + ntpdc/ntpdc-opts.c@1.30 +2 -2 + NTP_4_2_7P29 + + ntpdc/ntpdc-opts.h@1.30 +3 -3 + NTP_4_2_7P29 + + ntpdc/ntpdc-opts.texi@1.30 +2 -2 + NTP_4_2_7P29 + + ntpdc/ntpdc.1@1.30 +2 -2 + NTP_4_2_7P29 + + ntpq/ntpq-opts.c@1.30 +2 -2 + NTP_4_2_7P29 + + ntpq/ntpq-opts.h@1.30 +3 -3 + NTP_4_2_7P29 + + ntpq/ntpq-opts.texi@1.30 +2 -2 + NTP_4_2_7P29 + + ntpq/ntpq.1@1.30 +2 -2 + NTP_4_2_7P29 + + ntpsnmpd/ntpsnmpd-opts.c@1.30 +2 -2 + NTP_4_2_7P29 + + ntpsnmpd/ntpsnmpd-opts.h@1.30 +3 -3 + NTP_4_2_7P29 + + ntpsnmpd/ntpsnmpd-opts.texi@1.30 +1 -1 + NTP_4_2_7P29 + + ntpsnmpd/ntpsnmpd.1@1.30 +2 -2 + NTP_4_2_7P29 + + packageinfo.sh@1.31 +1 -1 + NTP_4_2_7P29 + + sntp/sntp-opts.c@1.30 +2 -2 + NTP_4_2_7P29 + + sntp/sntp-opts.h@1.30 +3 -3 + NTP_4_2_7P29 + + sntp/sntp-opts.texi@1.30 +2 -2 + NTP_4_2_7P29 + + sntp/sntp.1@1.30 +2 -2 + NTP_4_2_7P29 + + sntp/sntp.html@1.30 +1 -1 + NTP_4_2_7P29 + + util/ntp-keygen-opts.c@1.30 +2 -2 + NTP_4_2_7P29 + + util/ntp-keygen-opts.h@1.30 +3 -3 + NTP_4_2_7P29 + + util/ntp-keygen-opts.texi@1.30 +2 -2 + NTP_4_2_7P29 + + util/ntp-keygen.1@1.30 +2 -2 + NTP_4_2_7P29 + +ChangeSet@1.2129, 2010-05-04 01:43:50-04:00, stenn@deacon.udel.edu + Documentation patches from Dave Mills + + html/accopt.html@1.36 +1 -1 + Documentation patches from Dave Mills + + html/monopt.html@1.31 +3 -3 + Documentation patches from Dave Mills + +ChangeSet@1.2126.1.4, 2010-05-03 10:15:58+00:00, stenn@deacon.udel.edu + NTP_4_2_7P28 + TAG: NTP_4_2_7P28 + + ChangeLog@1.566.1.4 +1 -0 + NTP_4_2_7P28 + + ntpd/ntpd-opts.c@1.29 +2 -2 + NTP_4_2_7P28 + + ntpd/ntpd-opts.h@1.29 +3 -3 + NTP_4_2_7P28 + + ntpd/ntpd-opts.texi@1.29 +2 -2 + NTP_4_2_7P28 + + ntpd/ntpd.1@1.29 +2 -2 + NTP_4_2_7P28 + + ntpdc/ntpdc-opts.c@1.29 +2 -2 + NTP_4_2_7P28 + + ntpdc/ntpdc-opts.h@1.29 +3 -3 + NTP_4_2_7P28 + + ntpdc/ntpdc-opts.texi@1.29 +2 -2 + NTP_4_2_7P28 + + ntpdc/ntpdc.1@1.29 +2 -2 + NTP_4_2_7P28 + + ntpq/ntpq-opts.c@1.29 +2 -2 + NTP_4_2_7P28 + + ntpq/ntpq-opts.h@1.29 +3 -3 + NTP_4_2_7P28 + + ntpq/ntpq-opts.texi@1.29 +2 -2 + NTP_4_2_7P28 + + ntpq/ntpq.1@1.29 +2 -2 + NTP_4_2_7P28 + + ntpsnmpd/ntpsnmpd-opts.c@1.29 +27 -4 + NTP_4_2_7P28 + + ntpsnmpd/ntpsnmpd-opts.h@1.29 +18 -11 + NTP_4_2_7P28 + + ntpsnmpd/ntpsnmpd-opts.texi@1.29 +10 -1 + NTP_4_2_7P28 + + ntpsnmpd/ntpsnmpd.1@1.29 +11 -2 + NTP_4_2_7P28 + + packageinfo.sh@1.30 +1 -1 + NTP_4_2_7P28 + + sntp/sntp-opts.c@1.29 +2 -2 + NTP_4_2_7P28 + + sntp/sntp-opts.h@1.29 +3 -3 + NTP_4_2_7P28 + + sntp/sntp-opts.texi@1.29 +2 -2 + NTP_4_2_7P28 + + sntp/sntp.1@1.29 +2 -2 + NTP_4_2_7P28 + + sntp/sntp.html@1.29 +1 -1 + NTP_4_2_7P28 + + util/ntp-keygen-opts.c@1.29 +2 -2 + NTP_4_2_7P28 + + util/ntp-keygen-opts.h@1.29 +3 -3 + NTP_4_2_7P28 + + util/ntp-keygen-opts.texi@1.29 +2 -2 + NTP_4_2_7P28 + + util/ntp-keygen.1@1.29 +2 -2 + NTP_4_2_7P28 + +ChangeSet@1.2082.4.84, 2010-05-03 04:35:06-04:00, stenn@deacon.udel.edu + [Bug 1541] Fix wrong keyword for "maxclock". + + ChangeLog@1.496.26.59 +1 -0 + [Bug 1541] Fix wrong keyword for "maxclock". + + html/decode.html@1.11.1.2 +2 -2 + [Bug 1541] Fix wrong keyword for "maxclock". + +ChangeSet@1.2126.1.2, 2010-05-03 04:20:43-04:00, stenn@deacon.udel.edu + merge cleanup + + ChangeLog@1.566.1.2 +5 -0 + merge cleanup + +ChangeSet@1.2127, 2010-04-30 17:24:16+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1542] ntpd mrulist response may have incorrect last.older. + [Bug 1543] ntpq mrulist must refresh nonce when retrying. + [Bug 1544] ntpq mrulist sscanf timestamp format mismatch on 64-bit. + Windows compiling hints/winnt.html update from Sunil Tej S. + + ChangeLog@1.567 +8 -2 + [Bug 1542] ntpd mrulist response may have incorrect last.older. + [Bug 1543] ntpq mrulist must refresh nonce when retrying. + [Bug 1544] ntpq mrulist sscanf timestamp format mismatch on 64-bit. + Windows compiling hints/winnt.html update from Sunil Tej S. + + html/hints/winnt.html@1.20 +13 -11 + Windows compiling hints/winnt.html update from Sunil Tej S. + + ntpd/ntp_control.c@1.139 +5 -2 + [Bug 1542] ntpd mrulist response may have incorrect last.older. + + ntpq/ntpq-subs.c@1.66 +145 -67 + [Bug 1543] ntpq mrulist must refresh nonce when retrying. + [Bug 1544] ntpq mrulist sscanf timestamp format mismatch on 64-bit. + +ChangeSet@1.2082.4.83, 2010-04-30 09:03:12+00:00, stenn@psp-fb1.ntp.org + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + + ChangeLog@1.496.26.58 +2 -0 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + + ntpsnmpd/ntpsnmpd-opts.c@1.123.10.1 +29 -6 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + + ntpsnmpd/ntpsnmpd-opts.def@1.2 +12 -0 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + + ntpsnmpd/ntpsnmpd-opts.h@1.123.10.1 +17 -10 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.10.1 +33 -2 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + + ntpsnmpd/ntpsnmpd.1@1.122.10.1 +11 -2 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + + ntpsnmpd/ntpsnmpd.c@1.3.1.1 +1 -1 + [Bug 1512] ntpsnmpd should connect to net-snmpd via a unix-domain socket by default. Provide a command-line 'socket name' option. + +ChangeSet@1.2082.4.82, 2010-04-30 08:54:29+00:00, stenn@psp-fb1.ntp.org + [Bug 1538] update refclock_nmea.c's call to getprotobyname() + + ChangeLog@1.496.26.57 +6 -0 + [Bug 1538] update refclock_nmea.c's call to getprotobyname() + + ntpd/refclock_nmea.c@1.46.1.1 +1 -1 + [Bug 1538] update refclock_nmea.c's call to getprotobyname() + +ChangeSet@1.2126, 2010-04-27 10:08:54+00:00, stenn@deacon.udel.edu + NTP_4_2_7P27 + TAG: NTP_4_2_7P27 + + ChangeLog@1.566 +1 -0 + NTP_4_2_7P27 + + ntpd/ntpd-opts.c@1.28 +2 -2 + NTP_4_2_7P27 + + ntpd/ntpd-opts.h@1.28 +3 -3 + NTP_4_2_7P27 + + ntpd/ntpd-opts.texi@1.28 +2 -2 + NTP_4_2_7P27 + + ntpd/ntpd.1@1.28 +2 -2 + NTP_4_2_7P27 + + ntpdc/ntpdc-opts.c@1.28 +2 -2 + NTP_4_2_7P27 + + ntpdc/ntpdc-opts.h@1.28 +3 -3 + NTP_4_2_7P27 + + ntpdc/ntpdc-opts.texi@1.28 +2 -2 + NTP_4_2_7P27 + + ntpdc/ntpdc.1@1.28 +2 -2 + NTP_4_2_7P27 + + ntpq/ntpq-opts.c@1.28 +2 -2 + NTP_4_2_7P27 + + ntpq/ntpq-opts.h@1.28 +3 -3 + NTP_4_2_7P27 + + ntpq/ntpq-opts.texi@1.28 +2 -2 + NTP_4_2_7P27 + + ntpq/ntpq.1@1.28 +2 -2 + NTP_4_2_7P27 + + ntpsnmpd/ntpsnmpd-opts.c@1.28 +2 -2 + NTP_4_2_7P27 + + ntpsnmpd/ntpsnmpd-opts.h@1.28 +3 -3 + NTP_4_2_7P27 + + ntpsnmpd/ntpsnmpd-opts.texi@1.28 +1 -1 + NTP_4_2_7P27 + + ntpsnmpd/ntpsnmpd.1@1.28 +2 -2 + NTP_4_2_7P27 + + packageinfo.sh@1.29 +1 -1 + NTP_4_2_7P27 + + sntp/sntp-opts.c@1.28 +2 -2 + NTP_4_2_7P27 + + sntp/sntp-opts.h@1.28 +3 -3 + NTP_4_2_7P27 + + sntp/sntp-opts.texi@1.28 +2 -2 + NTP_4_2_7P27 + + sntp/sntp.1@1.28 +2 -2 + NTP_4_2_7P27 + + sntp/sntp.html@1.28 +1 -1 + NTP_4_2_7P27 + + util/ntp-keygen-opts.c@1.28 +2 -2 + NTP_4_2_7P27 + + util/ntp-keygen-opts.h@1.28 +3 -3 + NTP_4_2_7P27 + + util/ntp-keygen-opts.texi@1.28 +2 -2 + NTP_4_2_7P27 + + util/ntp-keygen.1@1.28 +2 -2 + NTP_4_2_7P27 + +ChangeSet@1.2082.4.81, 2010-04-27 02:53:34-04:00, stenn@deacon.udel.edu + NTP_4_2_6P2_RC2 + TAG: NTP_4_2_6P2_RC2 + + ChangeLog@1.496.26.56 +1 -0 + NTP_4_2_6P2_RC2 + + ntpd/ntpd-opts.c@1.248.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpd/ntpd-opts.h@1.248.9.1 +3 -3 + NTP_4_2_6P2_RC2 + + ntpd/ntpd-opts.texi@1.246.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpd/ntpd.1@1.246.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpdc/ntpdc-opts.c@1.244.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpdc/ntpdc-opts.h@1.244.9.1 +3 -3 + NTP_4_2_6P2_RC2 + + ntpdc/ntpdc-opts.texi@1.243.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpdc/ntpdc.1@1.243.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpq/ntpq-opts.c@1.245.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpq/ntpq-opts.h@1.245.9.1 +3 -3 + NTP_4_2_6P2_RC2 + + ntpq/ntpq-opts.texi@1.244.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpq/ntpq.1@1.244.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.9.1 +3 -3 + NTP_4_2_6P2_RC2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.9.1 +1 -1 + NTP_4_2_6P2_RC2 + + ntpsnmpd/ntpsnmpd.1@1.122.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + packageinfo.sh@1.255.11.1 +1 -1 + NTP_4_2_6P2_RC2 + + sntp/sntp-opts.c@1.117.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + sntp/sntp-opts.h@1.117.9.1 +3 -3 + NTP_4_2_6P2_RC2 + + sntp/sntp-opts.texi@1.117.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + sntp/sntp.1@1.117.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + sntp/sntp.html@1.7.9.1 +1 -1 + NTP_4_2_6P2_RC2 + + util/ntp-keygen-opts.c@1.247.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + util/ntp-keygen-opts.h@1.247.9.1 +3 -3 + NTP_4_2_6P2_RC2 + + util/ntp-keygen-opts.texi@1.246.9.1 +2 -2 + NTP_4_2_6P2_RC2 + + util/ntp-keygen.1@1.246.9.1 +2 -2 + NTP_4_2_6P2_RC2 + +ChangeSet@1.2124, 2010-04-24 10:09:18+00:00, stenn@deacon.udel.edu + NTP_4_2_7P26 + TAG: NTP_4_2_7P26 + + ChangeLog@1.564 +1 -0 + NTP_4_2_7P26 + + ntpd/ntpd-opts.c@1.27 +2 -2 + NTP_4_2_7P26 + + ntpd/ntpd-opts.h@1.27 +3 -3 + NTP_4_2_7P26 + + ntpd/ntpd-opts.texi@1.27 +2 -2 + NTP_4_2_7P26 + + ntpd/ntpd.1@1.27 +2 -2 + NTP_4_2_7P26 + + ntpdc/ntpdc-opts.c@1.27 +2 -2 + NTP_4_2_7P26 + + ntpdc/ntpdc-opts.h@1.27 +3 -3 + NTP_4_2_7P26 + + ntpdc/ntpdc-opts.texi@1.27 +2 -2 + NTP_4_2_7P26 + + ntpdc/ntpdc.1@1.27 +2 -2 + NTP_4_2_7P26 + + ntpq/ntpq-opts.c@1.27 +2 -2 + NTP_4_2_7P26 + + ntpq/ntpq-opts.h@1.27 +3 -3 + NTP_4_2_7P26 + + ntpq/ntpq-opts.texi@1.27 +2 -2 + NTP_4_2_7P26 + + ntpq/ntpq.1@1.27 +2 -2 + NTP_4_2_7P26 + + ntpsnmpd/ntpsnmpd-opts.c@1.27 +2 -2 + NTP_4_2_7P26 + + ntpsnmpd/ntpsnmpd-opts.h@1.27 +3 -3 + NTP_4_2_7P26 + + ntpsnmpd/ntpsnmpd-opts.texi@1.27 +1 -1 + NTP_4_2_7P26 + + ntpsnmpd/ntpsnmpd.1@1.27 +2 -2 + NTP_4_2_7P26 + + packageinfo.sh@1.28 +1 -1 + NTP_4_2_7P26 + + sntp/sntp-opts.c@1.27 +2 -2 + NTP_4_2_7P26 + + sntp/sntp-opts.h@1.27 +3 -3 + NTP_4_2_7P26 + + sntp/sntp-opts.texi@1.27 +2 -2 + NTP_4_2_7P26 + + sntp/sntp.1@1.27 +2 -2 + NTP_4_2_7P26 + + sntp/sntp.html@1.27 +1 -1 + NTP_4_2_7P26 + + util/ntp-keygen-opts.c@1.27 +2 -2 + NTP_4_2_7P26 + + util/ntp-keygen-opts.h@1.27 +3 -3 + NTP_4_2_7P26 + + util/ntp-keygen-opts.texi@1.27 +2 -2 + NTP_4_2_7P26 + + util/ntp-keygen.1@1.27 +2 -2 + NTP_4_2_7P26 + +ChangeSet@1.2082.4.80, 2010-04-24 05:57:35+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. + [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. + + ChangeLog@1.496.26.55 +4 -1 + [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. + [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. + + lib/isc/win32/include/isc/net.h@1.10 +30 -0 + [Bug 1534] win32/include/isc/net.h conflicts with VC++ 2010 errno.h. + + ntpd/ntp_parser.c@1.52.1.2 +2 -2 + Bison output from ntp_parser.y + + ntpd/ntp_parser.y@1.47.1.2 +2 -2 + [Bug 1535] "restrict -4 default" and "restrict -6 default" ignored. + +ChangeSet@1.2119.1.1, 2010-04-22 10:06:01+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1531] Require nonce with mrulist requests. + [Bug 1532] Remove ntpd support for ntpdc's monlist in favor of ntpq's + mrulist. + + ChangeLog@1.559.1.1 +3 -0 + [Bug 1531] Require nonce with mrulist requests. + [Bug 1532] Remove ntpd support for ntpdc's monlist in favor of ntpq's + mrulist. + + include/ntp_control.h@1.46 +1 -0 + [Bug 1531] Require nonce with mrulist requests. + + include/ntp_md5.h@1.4 +21 -5 + Hide #ifdefs related to selection between OpenSSL and host/libisc MD5 + implementations in one place, NTP code can then use the OpenSSL API + regardless. + + include/ntpd.h@1.137.1.15 +3 -0 + expose ntp_scanner.c's conf_file_sum + + libntp/a_md5encrypt.c@1.27 +3 -38 + Hide #ifdefs related to selection between OpenSSL and host/libisc MD5 + implementations in one place, NTP code can then use the OpenSSL API + regardless. + + ntpd/ntp_control.c@1.138 +150 -9 + [Bug 1531] Require nonce with mrulist requests. + + ntpd/ntp_request.c@1.93 +5 -116 + [Bug 1532] Remove ntpd support for ntpdc's monlist in favor of ntpq's + mrulist. + + ntpd/ntp_scanner.c@1.35 +5 -0 + [Bug 1531] Require nonce with mrulist requests. + + ntpq/ntpq-subs.c@1.65 +38 -5 + [Bug 1531] Require nonce with mrulist requests. + +ChangeSet@1.2121, 2010-04-20 21:58:50+00:00, stenn@deacon.udel.edu + NTP_4_2_7P25 + TAG: NTP_4_2_7P25 + + ChangeLog@1.561 +1 -0 + NTP_4_2_7P25 + + ntpd/ntpd-opts.c@1.26 +2 -2 + NTP_4_2_7P25 + + ntpd/ntpd-opts.h@1.26 +3 -3 + NTP_4_2_7P25 + + ntpd/ntpd-opts.texi@1.26 +2 -2 + NTP_4_2_7P25 + + ntpd/ntpd.1@1.26 +2 -2 + NTP_4_2_7P25 + + ntpdc/ntpdc-opts.c@1.26 +2 -2 + NTP_4_2_7P25 + + ntpdc/ntpdc-opts.h@1.26 +3 -3 + NTP_4_2_7P25 + + ntpdc/ntpdc-opts.texi@1.26 +2 -2 + NTP_4_2_7P25 + + ntpdc/ntpdc.1@1.26 +2 -2 + NTP_4_2_7P25 + + ntpq/ntpq-opts.c@1.26 +2 -2 + NTP_4_2_7P25 + + ntpq/ntpq-opts.h@1.26 +3 -3 + NTP_4_2_7P25 + + ntpq/ntpq-opts.texi@1.26 +2 -2 + NTP_4_2_7P25 + + ntpq/ntpq.1@1.26 +2 -2 + NTP_4_2_7P25 + + ntpsnmpd/ntpsnmpd-opts.c@1.26 +2 -2 + NTP_4_2_7P25 + + ntpsnmpd/ntpsnmpd-opts.h@1.26 +3 -3 + NTP_4_2_7P25 + + ntpsnmpd/ntpsnmpd-opts.texi@1.26 +1 -1 + NTP_4_2_7P25 + + ntpsnmpd/ntpsnmpd.1@1.26 +2 -2 + NTP_4_2_7P25 + + packageinfo.sh@1.27 +1 -1 + NTP_4_2_7P25 + + sntp/sntp-opts.c@1.26 +2 -2 + NTP_4_2_7P25 + + sntp/sntp-opts.h@1.26 +3 -3 + NTP_4_2_7P25 + + sntp/sntp-opts.texi@1.26 +2 -2 + NTP_4_2_7P25 + + sntp/sntp.1@1.26 +2 -2 + NTP_4_2_7P25 + + sntp/sntp.html@1.26 +1 -1 + NTP_4_2_7P25 + + util/ntp-keygen-opts.c@1.26 +2 -2 + NTP_4_2_7P25 + + util/ntp-keygen-opts.h@1.26 +3 -3 + NTP_4_2_7P25 + + util/ntp-keygen-opts.texi@1.26 +2 -2 + NTP_4_2_7P25 + + util/ntp-keygen.1@1.26 +2 -2 + NTP_4_2_7P25 + +ChangeSet@1.2082.4.79, 2010-04-20 01:55:16-04:00, stenn@deacon.udel.edu + [Bug 1465] Make sure time from TS2100 is not invalid (backport from -dev) + + ChangeLog@1.496.26.54 +1 -0 + [Bug 1465] Make sure time from TS2100 is not invalid (backport from -dev) + + ntpd/refclock_true.c@1.11.1.1 +2 -1 + [Bug 1465] Make sure time from TS2100 is not invalid (backport from -dev) + +ChangeSet@1.2082.4.78, 2010-04-20 01:45:17-04:00, stenn@deacon.udel.edu + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc + + ChangeLog@1.496.26.53 +1 -0 + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc + + ntpdc/Makefile.am@1.48.1.4 +2 -2 + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc + + ntpq/Makefile.am@1.43.1.4 +2 -2 + [Bug 1528] Fix EDITLINE_LIBS link order for ntpq and ntpdc + +ChangeSet@1.2082.4.77, 2010-04-20 01:30:11-04:00, stenn@deacon.udel.edu + Remove --with-arlib from br-flock + + ChangeLog@1.496.26.52 +2 -0 + Remove --with-arlib from br-flock + + br-flock@1.14 +1 -1 + Remove --with-arlib from br-flock + +ChangeSet@1.2082.4.76, 2010-04-18 04:14:33-04:00, stenn@deacon.udel.edu + NTP_4_2_6P2_RC1 + TAG: NTP_4_2_6P2_RC1 + + ChangeLog@1.496.26.51 +1 -0 + NTP_4_2_6P2_RC1 + + ntpd/ntpd-opts.c@1.248.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpd/ntpd-opts.h@1.248.8.1 +3 -3 + NTP_4_2_6P2_RC1 + + ntpd/ntpd-opts.texi@1.246.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpd/ntpd.1@1.246.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpdc/ntpdc-opts.c@1.244.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpdc/ntpdc-opts.h@1.244.8.1 +3 -3 + NTP_4_2_6P2_RC1 + + ntpdc/ntpdc-opts.texi@1.243.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpdc/ntpdc.1@1.243.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpq/ntpq-opts.c@1.245.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpq/ntpq-opts.h@1.245.8.1 +3 -3 + NTP_4_2_6P2_RC1 + + ntpq/ntpq-opts.texi@1.244.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpq/ntpq.1@1.244.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.8.1 +3 -3 + NTP_4_2_6P2_RC1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.8.1 +1 -1 + NTP_4_2_6P2_RC1 + + ntpsnmpd/ntpsnmpd.1@1.122.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + packageinfo.sh@1.255.10.2 +2 -2 + NTP_4_2_6P2_RC1 + + sntp/sntp-opts.c@1.117.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + sntp/sntp-opts.h@1.117.8.1 +3 -3 + NTP_4_2_6P2_RC1 + + sntp/sntp-opts.texi@1.117.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + sntp/sntp.1@1.117.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + sntp/sntp.html@1.7.8.1 +1 -1 + NTP_4_2_6P2_RC1 + + util/ntp-keygen-opts.c@1.247.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + util/ntp-keygen-opts.h@1.247.8.1 +3 -3 + NTP_4_2_6P2_RC1 + + util/ntp-keygen-opts.texi@1.246.8.1 +2 -2 + NTP_4_2_6P2_RC1 + + util/ntp-keygen.1@1.246.8.1 +2 -2 + NTP_4_2_6P2_RC1 + +ChangeSet@1.2082.4.75, 2010-04-18 03:57:37-04:00, stenn@deacon.udel.edu + 4.2.6p2-RC1 + + packageinfo.sh@1.255.10.1 +1 -1 + 4.2.6p2-RC1 + +ChangeSet@1.2082.4.74, 2010-04-16 13:59:44+00:00, davehart@shiny.ad.hartbrothers.com + fix backport (should have copied and pasted from -dev). + + sntp/networking.c@1.29.1.3 +2 -2 + fix backport (should have copied and pasted from -dev). + +ChangeSet@1.2082.4.71, 2010-04-14 21:16:25+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + + + ChangeLog@1.496.44.1 +5 -0 + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + + applies to previous changeset, deferred to ease pulling the + prior changeset into -dev ahead of -stable. + +ChangeSet@1.2082.19.2, 2010-04-14 20:55:27+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". + Update html/authopt.html controlkey, requestkey, and trustedkey docs. + + ChangeLog@1.496.43.1 +5 -0 + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". + Update html/authopt.html controlkey, requestkey, and trustedkey docs. + + The first entry applies to the prior changeset, which intentionally + lacked a ChangeLog entry to smooth pulling into -dev before -stable. + + html/authopt.html@1.60 +29 -7 + Update html/authopt.html controlkey, requestkey, and trustedkey docs, + add range syntax to trustedkey docs. + + +ChangeSet@1.2082.18.3, 2010-04-14 04:44:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. + + ChangeLog@1.496.26.48 +6 -0 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. + + include/ntp.h@1.168.1.1 +25 -16 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + include/ntp_lists.h@1.1.1.1 +163 -10 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + include/ntp_net.h@1.3.1.1 +34 -13 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + include/ntpd.h@1.137.2.1 +4 -4 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + ntpd/ntp_io.c@1.306.1.4 +2 -2 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + ntpd/ntp_monitor.c@1.25.1.1 +4 -4 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + ntpd/ntp_request.c@1.82.1.1 +72 -37 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + ntpd/ntp_restrict.c@1.27.1.1 +448 -429 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + ntpdate/ntpdate.c@1.69.1.1 +63 -55 + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. + + ntpdate/ntpdate.h@1.10.1.1 +2 -1 + [Bug 1504] ntpdate tickles ntpd "discard minimum 1" rate limit if + "restrict ... limited" is used. + + ntpdc/ntpdc_ops.c@1.62.1.1 +3 -3 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + + sntp/networking.c@1.29.1.2 +2 -2 + [Bug 1503] Auto-enabling of monitor for "restrict ... limited" wrong. + +ChangeSet@1.2116, 2010-04-13 21:19:19+00:00, stenn@deacon.udel.edu + NTP_4_2_7P24 + TAG: NTP_4_2_7P24 + + ChangeLog@1.557 +1 -0 + NTP_4_2_7P24 + + ntpd/ntpd-opts.c@1.25 +2 -2 + NTP_4_2_7P24 + + ntpd/ntpd-opts.h@1.25 +3 -3 + NTP_4_2_7P24 + + ntpd/ntpd-opts.texi@1.25 +2 -2 + NTP_4_2_7P24 + + ntpd/ntpd.1@1.25 +2 -2 + NTP_4_2_7P24 + + ntpdc/ntpdc-opts.c@1.25 +2 -2 + NTP_4_2_7P24 + + ntpdc/ntpdc-opts.h@1.25 +3 -3 + NTP_4_2_7P24 + + ntpdc/ntpdc-opts.texi@1.25 +2 -2 + NTP_4_2_7P24 + + ntpdc/ntpdc.1@1.25 +2 -2 + NTP_4_2_7P24 + + ntpq/ntpq-opts.c@1.25 +2 -2 + NTP_4_2_7P24 + + ntpq/ntpq-opts.h@1.25 +3 -3 + NTP_4_2_7P24 + + ntpq/ntpq-opts.texi@1.25 +2 -2 + NTP_4_2_7P24 + + ntpq/ntpq.1@1.25 +2 -2 + NTP_4_2_7P24 + + ntpsnmpd/ntpsnmpd-opts.c@1.25 +2 -2 + NTP_4_2_7P24 + + ntpsnmpd/ntpsnmpd-opts.h@1.25 +3 -3 + NTP_4_2_7P24 + + ntpsnmpd/ntpsnmpd-opts.texi@1.25 +1 -1 + NTP_4_2_7P24 + + ntpsnmpd/ntpsnmpd.1@1.25 +2 -2 + NTP_4_2_7P24 + + packageinfo.sh@1.26 +1 -1 + NTP_4_2_7P24 + + sntp/sntp-opts.c@1.25 +2 -2 + NTP_4_2_7P24 + + sntp/sntp-opts.h@1.25 +3 -3 + NTP_4_2_7P24 + + sntp/sntp-opts.texi@1.25 +2 -2 + NTP_4_2_7P24 + + sntp/sntp.1@1.25 +2 -2 + NTP_4_2_7P24 + + sntp/sntp.html@1.25 +1 -1 + NTP_4_2_7P24 + + util/ntp-keygen-opts.c@1.25 +2 -2 + NTP_4_2_7P24 + + util/ntp-keygen-opts.h@1.25 +3 -3 + NTP_4_2_7P24 + + util/ntp-keygen-opts.texi@1.25 +2 -2 + NTP_4_2_7P24 + + util/ntp-keygen.1@1.25 +2 -2 + NTP_4_2_7P24 + +ChangeSet@1.2115, 2010-04-13 02:04:47-04:00, stenn@pogo.udel.edu + [Bug 1390] Control PPS on the Oncore M12 + + ChangeLog@1.556 +1 -0 + [Bug 1390] Control PPS on the Oncore M12 + +ChangeSet@1.2112.7.1, 2010-04-13 00:31:34-04:00, stenn@deacon.udel.edu + accopt.html: non-ntpport doc changes from Dave Mills + + ChangeLog@1.551.2.1 +1 -0 + accopt.html: non-ntpport doc changes from Dave Mills + + html/accopt.html@1.33.1.1 +7 -8 + accopt.html: non-ntpport doc changes from Dave Mills + +ChangeSet@1.2112.6.3, 2010-04-12 06:50:58+00:00, davehart@shiny.ad.hartbrothers.com + Hal Murray caught another html/manyopt.html typo. + + html/manyopt.html@1.23 +1 -1 + Hal Murray caught another html/manyopt.html typo. + +ChangeSet@1.2112.6.2, 2010-04-12 06:17:50+00:00, davehart@shiny.ad.hartbrothers.com + Rephrase awkward pool description, correct "descovery" typo. + + html/manyopt.html@1.22 +10 -11 + Rephrase awkward pool description, correct "descovery" typo + (thanks Hal Murray) + +ChangeSet@1.2112.6.1, 2010-04-11 23:13:44+00:00, davehart@shiny.ad.hartbrothers.com + Documentation updates for 4.2.7p22 changes and additions, updating + ntpdc.html, ntpq.html, accopt.html, confopt.html, manyopt.html, + miscopt.html, and miscopt.txt. + Modify full MRU list preemption when full to match "discard monitor" + documentation, by removing exception for count == 1. + + ChangeLog@1.551.1.1 +5 -0 + Documentation updates for 4.2.7p22 changes and additions, updating + ntpdc.html, ntpq.html, accopt.html, confopt.html, manyopt.html, + miscopt.html, and miscopt.txt. + Modify full MRU list preemption when full to match "discard monitor" + documentation, by removing exception for count == 1. + + + html/accopt.html@1.34 +19 -12 + clarify "discard monitor". + clarify "restrict default", add "restrict source". + be more explicit about futility of kod restriction without limited. + + html/confopt.html@1.49 +7 -6 + correct link for automatic server discovery info from pool command. + + html/manyopt.html@1.21 +20 -7 + Document fully-formed "pool" command that act much like + "manycastclient". + + html/miscopt.html@1.54 +37 -6 + change "disable monitor" documentation to explain automatic + enabling by "restrict ... limited" and refer to ntpq's mrulist + instead of ntpdc's monlist. + correct logconfig's second example. + add "mru" command to set MRU list limits. + + html/ntpdc.html@1.31 +2 -2 + Note 600 row limitation of ntpdc -c monlist, refer to ntpq -c mrulist. + + html/ntpq.html@1.40 +64 -1 + add "mrulist", "monstats", "sysstats" commands. + + html/scripts/miscopt.txt@1.4 +1 -0 + add "mru" command + + ntpd/ntp_monitor.c@1.34 +3 -11 + Modify full MRU list preemption when full to match "discard monitor" + documentation, by removing exception for count == 1. + +ChangeSet@1.2112.1.20, 2010-04-10 03:55:22+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1520] '%u' formats for size_t gives warnings with 64-bit builds. + + applies to prior merge + + ChangeLog@1.553 +1 -0 + [Bug 1520] '%u' formats for size_t gives warnings with 64-bit builds. + +ChangeSet@1.2112.1.18, 2010-04-10 03:29:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". + + covers previous two merges + + ChangeLog@1.552 +3 -0 + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". + +ChangeSet@1.2082.19.1, 2010-04-10 02:26:43+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1522] Enable range syntax "trustedkey (301 ... 399)". + + include/ntp_config.h@1.66.2.1 +7 -5 + add u_int u to attr_val.value union. + + include/ntp_stdlib.h@1.40.1.1 +2 -0 + add extern ref to int cache_key from authkeys.c + + ntpd/complete.conf@1.3.1.1 +1 -1 + add key ranges to trustedkey + + ntpd/keyword-gen-utd@1.1.1.1 +1 -1 + to indicate ntp_keyword.h is current with keyword-gen.c + + ntpd/keyword-gen.c@1.5.1.1 +1 -0 + add T_Ellipsis "..." for + trustedkey (1...65533) 65534 + syntax support. + + ntpd/ntp_config.c@1.241.1.3 +45 -14 + support key ranges for trustedkey + + ntpd/ntp_keyword.h@1.3.1.1 +848 -844 + add "..." T_Ellipsis + + ntpd/ntp_parser.c@1.52.1.1 +918 -894 + Bison output + + ntpd/ntp_parser.h@1.32.1.1 +265 -263 + Bison output + + ntpd/ntp_parser.y@1.47.1.1 +23 -1 + support key ranges for trustedkey + +ChangeSet@1.2112.3.2, 2010-04-09 12:33:43-04:00, perlinger@psp-deb1.ntp.org + fixed minor format glitch in ntpd/ntpd.c + + ntpd/ntpd.c@1.110.1.7 +4 -1 + parametric length in format strings must be 'int' -- fixed that in 'change_logfile()' + +ChangeSet@1.2082.18.2, 2010-04-09 08:15:04+00:00, stenn@deacon.udel.edu + NTP_4_2_6P1 + TAG: NTP_4_2_6P1 + + ChangeLog@1.496.26.47 +1 -0 + NTP_4_2_6P1 + + ntpd/ntpd-opts.c@1.248.7.1 +2 -2 + NTP_4_2_6P1 + + ntpd/ntpd-opts.h@1.248.7.1 +3 -3 + NTP_4_2_6P1 + + ntpd/ntpd-opts.texi@1.246.7.1 +2 -2 + NTP_4_2_6P1 + + ntpd/ntpd.1@1.246.7.1 +2 -2 + NTP_4_2_6P1 + + ntpdc/ntpdc-opts.c@1.244.7.1 +2 -2 + NTP_4_2_6P1 + + ntpdc/ntpdc-opts.h@1.244.7.1 +3 -3 + NTP_4_2_6P1 + + ntpdc/ntpdc-opts.texi@1.243.7.1 +2 -2 + NTP_4_2_6P1 + + ntpdc/ntpdc.1@1.243.7.1 +2 -2 + NTP_4_2_6P1 + + ntpq/ntpq-opts.c@1.245.7.1 +2 -2 + NTP_4_2_6P1 + + ntpq/ntpq-opts.h@1.245.7.1 +3 -3 + NTP_4_2_6P1 + + ntpq/ntpq-opts.texi@1.244.7.1 +2 -2 + NTP_4_2_6P1 + + ntpq/ntpq.1@1.244.7.1 +2 -2 + NTP_4_2_6P1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.7.1 +2 -2 + NTP_4_2_6P1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.7.1 +3 -3 + NTP_4_2_6P1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.7.1 +1 -1 + NTP_4_2_6P1 + + ntpsnmpd/ntpsnmpd.1@1.122.7.1 +2 -2 + NTP_4_2_6P1 + + packageinfo.sh@1.255.9.2 +2 -2 + NTP_4_2_6P1 + + sntp/sntp-opts.c@1.117.7.1 +2 -2 + NTP_4_2_6P1 + + sntp/sntp-opts.h@1.117.7.1 +3 -3 + NTP_4_2_6P1 + + sntp/sntp-opts.texi@1.117.7.1 +2 -2 + NTP_4_2_6P1 + + sntp/sntp.1@1.117.7.1 +2 -2 + NTP_4_2_6P1 + + sntp/sntp.html@1.7.7.1 +1 -1 + NTP_4_2_6P1 + + util/ntp-keygen-opts.c@1.247.7.1 +2 -2 + NTP_4_2_6P1 + + util/ntp-keygen-opts.h@1.247.7.1 +3 -3 + NTP_4_2_6P1 + + util/ntp-keygen-opts.texi@1.246.7.1 +2 -2 + NTP_4_2_6P1 + + util/ntp-keygen.1@1.246.7.1 +2 -2 + NTP_4_2_6P1 + +ChangeSet@1.2082.18.1, 2010-04-09 03:43:19-04:00, stenn@deacon.udel.edu + Release ntp-4.2.6p1 + + NEWS@1.106 +14 -0 + Release ntp-4.2.6p1 + + packageinfo.sh@1.255.9.1 +1 -1 + Release ntp-4.2.6p1 + +ChangeSet@1.2112.3.1, 2010-04-06 19:08:47+02:00, jnperlin@hydra.localnet + fix format string warnings (64-bit); avoid (m)syslog format string attacks + + ntpd/ntp_config.c@1.259 +4 -4 + format 'size_t' with '%lu' (64-bit issue) + + ntpd/ntp_control.c@1.137 +2 -2 + avoid possible format string attack to msyslog() + + ntpd/ntp_intres.c@1.88 +4 -4 + format 'size_t' with '%lu' (64-bit issue) + + ntpd/ntp_request.c@1.91 +7 -7 + format 'size_t' with '%lu' (64-bit issue) + + ntpd/ntp_scanner.c@1.34 +3 -3 + format 'size_t' with '%lu' (64-bit issue); fixed is_special() (also 64-bit trouble) + + ntpd/ntpd.c@1.110.1.6 +3 -3 + format 'size_t' with '%lu' (64-bit issue); avoid possible format string attack to msyslog() + + ntpd/refclock_acts.c@1.37 +2 -2 + format 'size_t' with '%lu' (64-bit issue) + + ntpd/work_fork.c@1.3 +8 -8 + format 'size_t' with '%lu' (64-bit issue) + + ntpdc/ntpdc.c@1.83 +7 -7 + format 'size_t' with '%lu' (64-bit issue) + + sntp/log.c@1.13 +2 -2 + avoid possible format string attack to syslog() + +ChangeSet@1.2082.4.70, 2010-04-06 05:37:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + + ports/winnt/ntpd/nt_clockstuff.c@1.38.1.1 +144 -108 + [Bug 1518] Windows ntpd should lock to one processor more + conservatively. + +ChangeSet@1.2112.1.15, 2010-04-04 10:09:44+00:00, stenn@deacon.udel.edu + NTP_4_2_7P23 + TAG: NTP_4_2_7P23 + + ChangeLog@1.550 +1 -0 + NTP_4_2_7P23 + + ntpd/ntpd-opts.c@1.24 +2 -2 + NTP_4_2_7P23 + + ntpd/ntpd-opts.h@1.24 +3 -3 + NTP_4_2_7P23 + + ntpd/ntpd-opts.texi@1.24 +2 -2 + NTP_4_2_7P23 + + ntpd/ntpd.1@1.24 +2 -2 + NTP_4_2_7P23 + + ntpdc/ntpdc-opts.c@1.24 +2 -2 + NTP_4_2_7P23 + + ntpdc/ntpdc-opts.h@1.24 +3 -3 + NTP_4_2_7P23 + + ntpdc/ntpdc-opts.texi@1.24 +2 -2 + NTP_4_2_7P23 + + ntpdc/ntpdc.1@1.24 +2 -2 + NTP_4_2_7P23 + + ntpq/ntpq-opts.c@1.24 +2 -2 + NTP_4_2_7P23 + + ntpq/ntpq-opts.h@1.24 +3 -3 + NTP_4_2_7P23 + + ntpq/ntpq-opts.texi@1.24 +2 -2 + NTP_4_2_7P23 + + ntpq/ntpq.1@1.24 +2 -2 + NTP_4_2_7P23 + + ntpsnmpd/ntpsnmpd-opts.c@1.24 +2 -2 + NTP_4_2_7P23 + + ntpsnmpd/ntpsnmpd-opts.h@1.24 +3 -3 + NTP_4_2_7P23 + + ntpsnmpd/ntpsnmpd-opts.texi@1.24 +1 -1 + NTP_4_2_7P23 + + ntpsnmpd/ntpsnmpd.1@1.24 +2 -2 + NTP_4_2_7P23 + + packageinfo.sh@1.25 +1 -1 + NTP_4_2_7P23 + + sntp/sntp-opts.c@1.24 +2 -2 + NTP_4_2_7P23 + + sntp/sntp-opts.h@1.24 +3 -3 + NTP_4_2_7P23 + + sntp/sntp-opts.texi@1.24 +2 -2 + NTP_4_2_7P23 + + sntp/sntp.1@1.24 +2 -2 + NTP_4_2_7P23 + + sntp/sntp.html@1.24 +1 -1 + NTP_4_2_7P23 + + util/ntp-keygen-opts.c@1.24 +2 -2 + NTP_4_2_7P23 + + util/ntp-keygen-opts.h@1.24 +3 -3 + NTP_4_2_7P23 + + util/ntp-keygen-opts.texi@1.24 +2 -2 + NTP_4_2_7P23 + + util/ntp-keygen.1@1.24 +2 -2 + NTP_4_2_7P23 + +ChangeSet@1.2112.1.14, 2010-04-04 04:07:40+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1516] unpeer by IP address fails, DNS name works. + [Bug 1517] ntpq and ntpdc should verify reverse DNS before use. + ntpq and ntpdc now use the following format for showing purported + DNS names from IP address "reverse" DNS lookups when the DNS name + does not exist or does not include the original IP address among + the results: "192.168.1.2 (fake.dns.local)". + + ChangeLog@1.549 +6 -0 + [Bug 1516] unpeer by IP address fails, DNS name works. + [Bug 1517] ntpq and ntpdc should verify reverse DNS before use. + ntpq and ntpdc now use the following format for showing purported + DNS names from IP address "reverse" DNS lookups when the DNS name + does not exist or does not include the original IP address among + the results: "192.168.1.2 (fake.dns.local)". + + libntp/socktohost.c@1.9 +66 -6 + [Bug 1517] ntpq and ntpdc should verify reverse DNS before use. + ntpq and ntpdc now use the following format for showing purported + DNS names from IP address "reverse" DNS lookups when the DNS name + does not exist or does not include the original IP address among + the results: "192.168.1.2 (fake.dns.local)". + + ntpd/ntp_config.c@1.258 +7 -14 + * [Bug 1516] unpeer by IP address fails, DNS name works. + + ntpq/ntpq.c@1.112 +7 -7 + [Bug 1517] ntpq and ntpdc should verify reverse DNS before use. + ntpq and ntpdc now use the following format for showing purported + DNS names from IP address "reverse" DNS lookups when the DNS name + does not exist or does not include the original IP address among + the results: "192.168.1.2 (fake.dns.local)". + +ChangeSet@1.2112.1.13, 2010-04-02 02:08:59+00:00, stenn@deacon.udel.edu + NTP_4_2_7P22 + TAG: NTP_4_2_7P22 + + ChangeLog@1.548 +1 -0 + NTP_4_2_7P22 + + ntpd/ntpd-opts.c@1.23 +2 -2 + NTP_4_2_7P22 + + ntpd/ntpd-opts.h@1.23 +3 -3 + NTP_4_2_7P22 + + ntpd/ntpd-opts.texi@1.23 +2 -2 + NTP_4_2_7P22 + + ntpd/ntpd.1@1.23 +2 -2 + NTP_4_2_7P22 + + ntpdc/ntpdc-opts.c@1.23 +2 -2 + NTP_4_2_7P22 + + ntpdc/ntpdc-opts.h@1.23 +3 -3 + NTP_4_2_7P22 + + ntpdc/ntpdc-opts.texi@1.23 +2 -2 + NTP_4_2_7P22 + + ntpdc/ntpdc.1@1.23 +2 -2 + NTP_4_2_7P22 + + ntpq/ntpq-opts.c@1.23 +2 -2 + NTP_4_2_7P22 + + ntpq/ntpq-opts.h@1.23 +3 -3 + NTP_4_2_7P22 + + ntpq/ntpq-opts.texi@1.23 +2 -2 + NTP_4_2_7P22 + + ntpq/ntpq.1@1.23 +2 -2 + NTP_4_2_7P22 + + ntpsnmpd/ntpsnmpd-opts.c@1.23 +2 -2 + NTP_4_2_7P22 + + ntpsnmpd/ntpsnmpd-opts.h@1.23 +3 -3 + NTP_4_2_7P22 + + ntpsnmpd/ntpsnmpd-opts.texi@1.23 +1 -1 + NTP_4_2_7P22 + + ntpsnmpd/ntpsnmpd.1@1.23 +2 -2 + NTP_4_2_7P22 + + packageinfo.sh@1.24 +1 -1 + NTP_4_2_7P22 + + sntp/sntp-opts.c@1.23 +2 -2 + NTP_4_2_7P22 + + sntp/sntp-opts.h@1.23 +3 -3 + NTP_4_2_7P22 + + sntp/sntp-opts.texi@1.23 +2 -2 + NTP_4_2_7P22 + + sntp/sntp.1@1.23 +2 -2 + NTP_4_2_7P22 + + sntp/sntp.html@1.23 +1 -1 + NTP_4_2_7P22 + + util/ntp-keygen-opts.c@1.23 +2 -2 + NTP_4_2_7P22 + + util/ntp-keygen-opts.h@1.23 +3 -3 + NTP_4_2_7P22 + + util/ntp-keygen-opts.texi@1.23 +2 -2 + NTP_4_2_7P22 + + util/ntp-keygen.1@1.23 +2 -2 + NTP_4_2_7P22 + +ChangeSet@1.2082.4.69, 2010-04-01 03:33:20-04:00, stenn@deacon.udel.edu + lose whimsy from br-flock + + br-flock@1.13 +1 -1 + lose whimsy from br-flock + +ChangeSet@1.2112.1.11, 2010-04-01 03:20:04-04:00, stenn@deacon.udel.edu + [Bug 1465] Make sure time from TS2100 is not invalid + + ChangeLog@1.547 +1 -0 + [Bug 1465] Make sure time from TS2100 is not invalid + + ntpd/refclock_true.c@1.12 +2 -1 + [Bug 1465] Make sure time from TS2100 is not invalid + +ChangeSet@1.2112.1.10, 2010-04-01 03:13:14-04:00, stenn@deacon.udel.edu + [Bug 1432] Don't set inheritable flag for linux capabilities + + ChangeLog@1.546 +1 -0 + [Bug 1432] Don't set inheritable flag for linux capabilities + + ntpd/ntpd.c@1.110.1.5 +2 -2 + [Bug 1432] Don't set inheritable flag for linux capabilities + +ChangeSet@1.2112.2.7, 2010-03-31 09:16:48+00:00, stenn@deacon.udel.edu + NTP_4_2_7P21 + TAG: NTP_4_2_7P21 + + ChangeLog@1.543.1.3 +1 -0 + NTP_4_2_7P21 + + ntpd/ntpd-opts.c@1.22 +2 -2 + NTP_4_2_7P21 + + ntpd/ntpd-opts.h@1.22 +3 -3 + NTP_4_2_7P21 + + ntpd/ntpd-opts.texi@1.22 +2 -2 + NTP_4_2_7P21 + + ntpd/ntpd.1@1.22 +2 -2 + NTP_4_2_7P21 + + ntpdc/ntpdc-opts.c@1.22 +2 -2 + NTP_4_2_7P21 + + ntpdc/ntpdc-opts.h@1.22 +3 -3 + NTP_4_2_7P21 + + ntpdc/ntpdc-opts.texi@1.22 +2 -2 + NTP_4_2_7P21 + + ntpdc/ntpdc.1@1.22 +2 -2 + NTP_4_2_7P21 + + ntpq/ntpq-opts.c@1.22 +2 -2 + NTP_4_2_7P21 + + ntpq/ntpq-opts.h@1.22 +3 -3 + NTP_4_2_7P21 + + ntpq/ntpq-opts.texi@1.22 +2 -2 + NTP_4_2_7P21 + + ntpq/ntpq.1@1.22 +2 -2 + NTP_4_2_7P21 + + ntpsnmpd/ntpsnmpd-opts.c@1.22 +2 -2 + NTP_4_2_7P21 + + ntpsnmpd/ntpsnmpd-opts.h@1.22 +3 -3 + NTP_4_2_7P21 + + ntpsnmpd/ntpsnmpd-opts.texi@1.22 +2 -23 + NTP_4_2_7P21 + + ntpsnmpd/ntpsnmpd.1@1.22 +2 -2 + NTP_4_2_7P21 + + packageinfo.sh@1.23 +1 -1 + NTP_4_2_7P21 + + sntp/sntp-opts.c@1.22 +2 -2 + NTP_4_2_7P21 + + sntp/sntp-opts.h@1.22 +3 -3 + NTP_4_2_7P21 + + sntp/sntp-opts.texi@1.22 +2 -2 + NTP_4_2_7P21 + + sntp/sntp.1@1.22 +2 -2 + NTP_4_2_7P21 + + sntp/sntp.html@1.22 +10 -14 + NTP_4_2_7P21 + + util/ntp-keygen-opts.c@1.22 +2 -2 + NTP_4_2_7P21 + + util/ntp-keygen-opts.h@1.22 +3 -3 + NTP_4_2_7P21 + + util/ntp-keygen-opts.texi@1.22 +2 -2 + NTP_4_2_7P21 + + util/ntp-keygen.1@1.22 +2 -2 + NTP_4_2_7P21 + +ChangeSet@1.2082.4.68, 2010-03-31 08:45:31+00:00, stenn@deacon.udel.edu + NTP_4_2_6P1_RC6 + TAG: NTP_4_2_6P1_RC6 + + ChangeLog@1.496.26.46 +1 -0 + NTP_4_2_6P1_RC6 + + ntpd/ntpd-opts.c@1.248.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpd/ntpd-opts.h@1.248.6.1 +3 -3 + NTP_4_2_6P1_RC6 + + ntpd/ntpd-opts.texi@1.246.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpd/ntpd.1@1.246.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpdc/ntpdc-opts.c@1.244.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpdc/ntpdc-opts.h@1.244.6.1 +3 -3 + NTP_4_2_6P1_RC6 + + ntpdc/ntpdc-opts.texi@1.243.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpdc/ntpdc.1@1.243.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpq/ntpq-opts.c@1.245.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpq/ntpq-opts.h@1.245.6.1 +3 -3 + NTP_4_2_6P1_RC6 + + ntpq/ntpq-opts.texi@1.244.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpq/ntpq.1@1.244.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.6.1 +3 -3 + NTP_4_2_6P1_RC6 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.6.1 +2 -23 + NTP_4_2_6P1_RC6 + + ntpsnmpd/ntpsnmpd.1@1.122.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + packageinfo.sh@1.255.8.1 +1 -1 + NTP_4_2_6P1_RC6 + + sntp/sntp-opts.c@1.117.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + sntp/sntp-opts.h@1.117.6.1 +3 -3 + NTP_4_2_6P1_RC6 + + sntp/sntp-opts.texi@1.117.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + sntp/sntp.1@1.117.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + sntp/sntp.html@1.7.6.1 +10 -14 + NTP_4_2_6P1_RC6 + + util/ntp-keygen-opts.c@1.247.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + util/ntp-keygen-opts.h@1.247.6.1 +3 -3 + NTP_4_2_6P1_RC6 + + util/ntp-keygen-opts.texi@1.246.6.1 +2 -2 + NTP_4_2_6P1_RC6 + + util/ntp-keygen.1@1.246.6.1 +2 -2 + NTP_4_2_6P1_RC6 + +ChangeSet@1.2082.4.67, 2010-03-31 04:14:28-04:00, stenn@deacon.udel.edu + Quiet some trigger debugging + + BitKeeper/triggers/triggert@1.6.1.2 +1 -1 + Quiet some trigger debugging + +ChangeSet@1.2082.4.66, 2010-03-31 04:11:55-04:00, stenn@deacon.udel.edu + [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 + + ChangeLog@1.496.26.45 +1 -0 + [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 + + ntpd/ntp_proto.c@1.297.2.1 +1 -1 + [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 + +ChangeSet@1.2082.4.65, 2010-03-31 03:17:27-04:00, stenn@deacon.udel.edu + trigger cleanup + + BitKeeper/triggers/trigger.README@1.4.1.1 +5 -3 + trigger cleanup + + BitKeeper/triggers/trigger.cfg@1.12.1.1 +6 -0 + trigger cleanup + + BitKeeper/triggers/trigger.mk@1.9.1.1 +3 -1 + trigger cleanup + + BitKeeper/triggers/triggert@1.6.1.1 +17 -6 + trigger cleanup + +ChangeSet@1.2112.2.3, 2010-03-31 03:13:36-04:00, stenn@deacon.udel.edu + trigger cleanup + + BitKeeper/triggers/trigger.README@1.5 +5 -3 + trigger cleanup + + BitKeeper/triggers/trigger.cfg@1.13 +6 -0 + trigger cleanup + + BitKeeper/triggers/trigger.mk@1.10 +3 -1 + trigger cleanup + + BitKeeper/triggers/triggert@1.7 +17 -6 + trigger cleanup + +ChangeSet@1.2082.4.64, 2010-03-29 05:16:32-04:00, stenn@deacon.udel.edu + With the new bk, the trigger push needs the -q (quiet) flag + + BitKeeper/triggers/2mirrors@1.5 +3 -3 + With the new bk, the trigger push needs the -q (quiet) flag + +ChangeSet@1.2112.2.1, 2010-03-25 23:40:34-04:00, stenn@deacon.udel.edu + whitespace cleanup + + html/copyright.html@1.48 +1 -1 + whitespace cleanup + +ChangeSet@1.2112.1.8, 2010-03-25 16:12:20+00:00, davehart@shiny.ad.hartbrothers.com + ntpq-subs.c: + Add ntpq "mrulist limited" and "mrulist kod" support, equivalent to + ntpq -c "mrulist resany=0x20" and ntpq -c "mrulist resany=0x400" + respectively. + Add "r" rate limiting column to mrulist output containing a period, + or K for KoD sent in response to last packet, or L for no response + to last packet due to rate limiting. These are redundant with bits + 0x400 and 0x20 in the rstr column and treated differently than other + restrict bits, reflecting not if the restriction bit is enabled for + the remote address, but if RES_KOD or RES_LIMITED handling was + triggered by the last packet from them. + it. + ntp.h, ntpdc_ops.c, ntp_proto.c, ntp_config.c: + rename RES_TIMEOUT to RES_FLAKE to reflect v4 use (as a flakeway which + drops 10% of incoming packets from matching addresses). + ntp_intres.c: + rename RES_TIMEOUT to RES_FLAKE to reflect v4 use (as a flakeway which + drops 10% of incoming packets from matching addresses), eliminating + conflict with RES_TIMEOUT provided by some systems DNS headers. + + include/ntp.h@1.177 +2 -2 + rename RES_TIMEOUT to RES_FLAKE to reflect v4 use (as a flakeway which + drops 10% of incoming packets from matching addresses). + + ntpd/ntp_config.c@1.257 +1 -1 + rename RES_TIMEOUT to RES_FLAKE to reflect v4 use (as a flakeway which + drops 10% of incoming packets from matching addresses). + + ntpd/ntp_intres.c@1.87 +0 -3 + rename RES_TIMEOUT to RES_FLAKE to reflect v4 use (as a flakeway which + drops 10% of incoming packets from matching addresses), eliminating + conflict with RES_TIMEOUT provided by some systems DNS headers. + + ntpd/ntp_proto.c@1.297.1.12 +1 -1 + rename RES_TIMEOUT to RES_FLAKE to reflect v4 use (as a flakeway which + drops 10% of incoming packets from matching addresses). + + ntpdc/ntpdc_ops.c@1.66 +1 -1 + rename RES_TIMEOUT to RES_FLAKE to reflect v4 use (as a flakeway which + drops 10% of incoming packets from matching addresses). + + ntpq/ntpq-subs.c@1.64 +25 -5 + Add ntpq "mrulist limited" and "mrulist kod" support, equivalent to + ntpq -c "mrulist resany=0x20" and ntpq -c "mrulist resany=0x400" + respectively. + Add "r" rate limiting column to mrulist output containing a period, + or K for KoD sent in response to last packet, or L for no response + to last packet due to rate limiting. These are redundant with bits + 0x400 and 0x20 in the rstr column and treated differently than other + restrict bits, reflecting not if the restriction bit is enabled for + the remote address, but if RES_KOD or RES_LIMITED handling was + triggered by the last packet from them. + it. + +ChangeSet@1.2112.1.7, 2010-03-25 13:28:10+00:00, davehart@shiny.ad.hartbrothers.com + ntp_control.c: + use ctl_putts() instead of handrolled equivalent for read_mru_list(). + + ntpd/ntp_control.c@1.136 +9 -23 + use ctl_putts() instead of handrolled equivalent for read_mru_list(). + +ChangeSet@1.2112.1.6, 2010-03-25 03:54:17+00:00, davehart@shiny.ad.hartbrothers.com + ssl_init.c: + MAX_MAC_LEN will always be > sizeof(keyid_t) so make max_digest_len + const u_long instead of u_long, initialize unconditionally. + + libntp/ssl_init.c@1.7 +7 -8 + MAX_MAC_LEN will always be > sizeof(keyid_t) so make max_digest_len + const u_long instead of u_long, initialize unconditionally. + +ChangeSet@1.2110.1.30, 2010-03-25 01:42:06+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + Catch up ChangeLog with several weeks' changes. + ntpq-subs.c, ntp_peer.c, ntp_io.c, ntp_proto.c: + debug message cleanup for integration with ntp-dev + + ChangeLog@1.541.1.2 +64 -1 + Catch up ChangeLog with several weeks' changes. + + ntpd/ntp_io.c@1.318 +2 -2 + debug message cleanup for integration with ntp-dev + + ntpd/ntp_peer.c@1.133 +0 -3 + debug message cleanup for integration with ntp-dev + + ntpd/ntp_proto.c@1.297.1.11 +1 -2 + debug message cleanup for integration with ntp-dev + + ntpq/ntpq-subs.c@1.63 +13 -14 + debug message cleanup for integration with ntp-dev + +ChangeSet@1.2112.1.4, 2010-03-24 22:46:41+01:00, jnperlin@hydra.localnet + ntpq.c: + fix printf format warnings + + ntpq/ntpq.c@1.100.1.1 +6 -6 + fix printf format warnings + +ChangeSet@1.2112.1.3, 2010-03-24 20:04:35+01:00, jnperlin@hydra.localnet + ssl_init.c: + cast size_t expressions to u_long in formatting + + libntp/ssl_init.c@1.6 +3 -3 + cast size_t expressions to u_long in formatting + +ChangeSet@1.2112.1.2, 2010-03-23 22:05:52+01:00, jnperlin@hydra.localnet + ssl_init.c: + fixed printf format warnings + + libntp/ssl_init.c@1.5 +7 -5 + fixed printf format warnings + +ChangeSet@1.2112.1.1, 2010-03-23 20:40:52+01:00, jnperlin@hydra.localnet + ntp_fp.h: + fix prototype for 'dolfptoa' + dolfptoa.c: + avoid pointer wrap-around warnings, fixed prototype, + did some rework to make the implementation cleaner. + + include/ntp_fp.h@1.16.1.1 +1 -1 + fix prototype for 'dolfptoa' + + libntp/dolfptoa.c@1.8 +62 -101 + avoid pointer wrap-around warnings, fixed prototype, + did some rework to make the implementation cleaner. + +ChangeSet@1.2110.1.29, 2010-03-19 22:26:01+00:00, davehart@shiny.ad.hartbrothers.com + remove unused PEVNT_TAI + + include/ntp.h@1.176 +0 -1 + remove unused PEVNT_TAI + + libntp/statestr.c@1.20 +0 -1 + remove unused PEVNT_TAI + +ChangeSet@1.2110.1.28, 2010-03-19 04:09:05+00:00, davehart@shiny.ad.hartbrothers.com + Fine-tune "ntpq -c mrulimit" row limit backoff and growth after + testing over WiFi and a lossy go6.net UDP tunnel. + + include/ntp.h@1.175 +2 -0 + Add MRU_ROW_LIMIT to share between ntp_control.c and ntpq-subs.c + + libntp/authusekey.c@1.9 +3 -5 + eliminate redundant strlen() + + ntpd/ntp_control.c@1.133.1.14 +2 -2 + Add MRU_ROW_LIMIT to share between ntp_control.c and ntpq-subs.c, + use CERR_BADVALUE for error when exceeded. + + ntpq/ntpq-subs.c@1.62 +11 -4 + Add MRU_ROW_LIMIT to share between ntp_control.c and ntpq-subs.c, + use CERR_BADVALUE for error when exceeded. + Fine-tune row limit backoff and growth after testing over WiFi + and a lossy go6.net UDP tunnel. + + ntpq/ntpq.c@1.110 +33 -17 + Increase timeout for 2nd and later response packets from 2s to 3s, + elaborate on ntpq timeout behavior in comment. + Improve debug output in the case of a missing packet while + reassembling a response, making it easier to spot the hole. + + ntpq/ntpq.h@1.15 +18 -2 + Lower MAXFRAGS from experimental (never committed) 64 to 32, still + an increase over the historical value 24. Add comments exploring + impact of adjusting MAXFRAGS. + + ports/winnt/include/config.h@1.86 +1 -1 + note HAVE_STRCHR is left in for libopts (NTP itself requires + ANSI C which mandates strchr()). + +ChangeSet@1.2110.1.27, 2010-03-12 21:25:12+00:00, davehart@shiny.ad.hartbrothers.com + add "ntpq -c ifstats" modeled on "ntpdc -c ifstats" + + include/ntp_control.h@1.45 +2 -1 + add "ntpq -c ifstats" modeled on "ntpdc -c ifstats" + + include/ntpd.h@1.137.1.13 +2 -0 + add "ntpq -c ifstats" modeled on "ntpdc -c ifstats" + + ntpd/ntp_control.c@1.133.1.13 +224 -47 + add "ntpq -c ifstats" modeled on "ntpdc -c ifstats" + + ntpd/ntp_io.c@1.317 +14 -9 + expose sys_ifnum to ntp_control.c for ntpq -c ifstats. + add code to test if reset of addr_refid is needed. + + ntpd/ntp_scanner.c@1.33 +3 -3 + Do not abort on non-ASCII character in ntp.conf, ignore it. + + ntpdc/ntpdc.c@1.82 +8 -11 + correct "passwd" to only examine arg if present. + + ntpq/ntpq-subs.c@1.61 +321 -45 + add "ntpq -c ifstats" modeled on "ntpdc -c ifstats" + + ntpq/ntpq.c@1.109 +13 -10 + allow ntpq -c "passwd MYPASS" as with ntpdc + +ChangeSet@1.2110.1.26, 2010-03-10 03:02:42+00:00, davehart@shiny.ad.hartbrothers.com + Fetch 32 rows initially in ntpq -cmrulist. + Tweak runtime adjustment of limit in response to errors, now + will grow number of rows 50% each success and cut it in + half each failure. + Sleep 0.3s instead of 1s between requests in ntpq -cmrulist + on platforms that have nanosleep() or similar. + + configure.ac@1.481 +34 -36 + test for nanosleep() for ntpq -c mrulist + + ntpd/ntp_control.c@1.133.1.12 +2 -2 + change row limit for read_mru_list() to 256 + + ntpq/ntpq-subs.c@1.60 +14 -5 + Fetch 32 rows initially in ntpq -cmrulist. + Tweak runtime adjustment of limit in response to errors, now + will grow number of rows 50% each success and cut it in + half each failure. + Sleep 0.3s instead of 1s between requests in ntpq -cmrulist + on platforms that have nanosleep() or similar. + +ChangeSet@1.2110.1.25, 2010-03-09 15:32:25+00:00, davehart@shiny.ad.hartbrothers.com + add "sort=count", "sort=-count" options to ntpq -c mrulist. + + ntpq/ntpq-subs.c@1.59 +43 -0 + add "sort=count", "sort=-count" options to ntpq -c mrulist. + +ChangeSet@1.2110.1.24, 2010-03-09 15:11:28+00:00, davehart@shiny.ad.hartbrothers.com + ntpq-subs.c: + use "sort=lstint" and "sort=-lstint" for default and reverse + default sort order of "ntpq -c mrulist" + ntp_control.c: + Attempt to enforce clients ignoring unknown tag=value pairs + in CTL_OP_READ_MRU (ntpq -c mrulist) by including a randomly- + named tag in the last row. + + ntpd/ntp_control.c@1.133.1.11 +36 -10 + Attempt to enforce clients ignoring unknown tag=value pairs + in CTL_OP_READ_MRU (ntpq -c mrulist) by including a randomly- + named tag in the last row. + + ntpq/ntpq-subs.c@1.58 +2 -2 + use "sort=lstint" and "sort=-lstint" for default and reverse + default sort order of "ntpq -c mrulist" + +ChangeSet@1.2110.1.23, 2010-03-09 03:32:38+00:00, davehart@shiny.ad.hartbrothers.com + add reverse sorting to ntpq -c mrulist, generalize. + + include/ntp_lists.h@1.6 +15 -4 + add REV_ITER_DLIST_BEGIN/END macros + + ntpd/refclock_neoclock4x.c@1.18 +10 -10 + leftover const chasing + + ntpq/ntpq-subs.c@1.57 +94 -25 + add reverse sorting to ntpq -c mrulist, generalize. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.27 +4 -0 + add reference to ntpd/refclock_neoclock4x.c + +ChangeSet@1.2110.1.22, 2010-03-09 01:53:35+00:00, davehart@shiny.ad.hartbrothers.com + Add "sort=avgint" option to mrulist: ntpq -c "mru sort=avgint". + Add "sort=addr" option to mrulist to sort by remote address. + Remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + configure.ac@1.480 +0 -26 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + include/ntp_net.h@1.7 +5 -0 + add SIZEOF_INADDR(family) macro to fetch sizeof either + struct in_addr or struct in_addr6. + + ntpd/keyword-gen.c@1.10 +10 -16 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + ntpd/ntp_refclock.c@1.91.1.4 +1 -29 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + ntpd/refclock_msfees.c@1.14 +3 -23 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + ntpd/refclock_mx4200.c@1.26 +0 -4 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + ntpdc/ntpdc.c@1.81 +22 -43 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + ntpq/ntpq-subs.c@1.56 +164 -17 + Add "sort=avgint" option to mrulist: ntpq -c "mru sort=avgint". + Add "sort=addr" option to mrulist to sort by remote address. + Remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + ntpq/ntpq.c@1.108 +11 -53 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + ports/winnt/include/config.h@1.85 +2 -2 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + + util/hist.c@1.8 +16 -19 + remove check for qsort() using other than void *, ANSI C is + required and it ensures void * for qsort(). + +ChangeSet@1.2110.1.21, 2010-03-08 21:23:01+00:00, davehart@shiny.ad.hartbrothers.com + add support for filtering MRU list by interface (local addr): + ntpq -c "mru laddr=192.168.1.1" + + include/ntpd.h@1.137.1.12 +3 -2 + expose ntp_io.c getinterface() for ntp_control.c use. + + ntpd/ntp_control.c@1.133.1.10 +133 -50 + add support for filtering MRU list by interface (local addr): + ntpq -c "mru laddr=192.168.1.1" + + ntpd/ntp_io.c@1.316 +1 -2 + expose ntp_io.c getinterface() for ntp_control.c use. + + ntpq/ntpq-subs.c@1.55 +7 -5 + add support for filtering MRU list by interface (local addr): + ntpq -c "mru laddr=192.168.1.1" + +ChangeSet@1.2110.1.20, 2010-03-08 10:44:22+00:00, davehart@shiny.ad.hartbrothers.com + add "ntpq -c sysstats" modeled on "ntpdc -c sysstats" + + include/ntp_control.h@1.44 +13 -2 + expose variables needed for "ntpq -c sysstats" similar to "ntpdc -c sysstats" + + ntpd/ntp_control.c@1.133.1.9 +74 -20 + expose variables needed for "ntpq -c sysstats" similar to "ntpdc -c sysstats" + + ntpd/ntp_proto.c@1.297.1.10 +2 -1 + reset sys_kodsent in proto_clr_stats(). + + ntpd/ntp_request.c@1.90 +0 -3 + remove no longer relevant comment + + ntpq/libntpq.c@1.4 +106 -95 + const chasing + + ntpq/libntpq.h@1.4 +25 -17 + const chasing + + ntpq/libntpq_subs.c@1.3 +14 -3 + const chasing + + ntpq/ntpq-subs.c@1.54 +143 -48 + add "ntpq -c sysstats" modeled on "ntpdc -c sysstats" + + ntpq/ntpq.c@1.107 +26 -23 + const chasing + + ntpq/ntpq.h@1.14 +4 -4 + const chasing + +ChangeSet@1.2110.1.19, 2010-03-07 20:01:29+00:00, davehart@shiny.ad.hartbrothers.com + rate limit ntpdate packets to 2s interval per server to stay + within the "restrict ... limited" default limit set by + "discard minimum 1", plus 1s of enforcement slop. + Respect KoD rate-limiting responses from ntpd. + + + ntpdate/ntpdate.c@1.73 +39 -11 + rate limit ntpdate packets to 2s interval per server to stay + within the "restrict ... limited" default limit set by + "discard minimum 1", plus 1s of enforcement slop. + Respect KoD rate-limiting responses from ntpd. + + + ntpdate/ntpdate.h@1.11 +2 -1 + rate limit ntpdate packets to 2s interval per server to stay + within the "restrict ... limited" default limit set by + "discard minimum 1", plus 1s of enforcement slop. + +ChangeSet@1.2110.1.18, 2010-03-07 17:36:49+00:00, davehart@shiny.ad.hartbrothers.com + ntp_util.c: + whitespace only + ntpq-subs.c: + split mrulist() into mrulist() and collect_mru_list(). + adjust row limit based on success/failure of individual + queries for collect_mru_list(). + revert to one MRU entry per IP address regardless of port. + ntp_monitor.c: + correct MRU list preemption logic. + revert to one MRU entry per IP address regardless of port. + ntp_control.h, ntp_control.c: + add "kod_sent" non-default system variable for sys_kodsent. + config.h: + #undef STRINGIZE after use to avoid accidentally using on + Windows without noticing it's specific to Windows port. + ntpq.c, ntpq.h: + move definitions to ntpq.h needed by mrulist code in + ntpq-subs.h. + + include/ntp_control.h@1.43 +11 -9 + add "kod_sent" non-default system variable for sys_kodsent. + + ntpd/ntp_control.c@1.133.1.8 +66 -21 + add "kod_sent" non-default system variable for sys_kodsent. + + ntpd/ntp_monitor.c@1.33 +10 -3 + correct MRU list preemption logic. + revert to one MRU entry per IP address regardless of port. + + ntpd/ntp_util.c@1.81 +1 -1 + whitespace only + + ntpq/ntpq-subs.c@1.53 +155 -46 + split mrulist() into mrulist() and collect_mru_list(). + adjust row limit based on success/failure of individual + queries for collect_mru_list(). + revert to one MRU entry per IP address regardless of port. + + ntpq/ntpq.c@1.106 +4 -9 + move definitions to ntpq.h needed by mrulist code in + ntpq-subs.h. + + ntpq/ntpq.h@1.13 +11 -1 + move definitions to ntpq.h needed by mrulist code in + ntpq-subs.h. + + ports/winnt/include/config.h@1.84 +2 -0 + #undef STRINGIZE after use to avoid accidentally using on + Windows without noticing it's specific to Windows port. + +ChangeSet@1.2110.1.17, 2010-03-05 19:22:27+00:00, davehart@shiny.ad.hartbrothers.com + ntpq-subs.c: + use ========= instead of --------- to separate column headings + from rows in mrulist(). + ntp_config.c: + unpeer by hostname, needed to unpeer pool prototype + assocations. + + ntpd/ntp_config.c@1.256 +72 -78 + unpeer by hostname, needed to unpeer pool prototype + assocations. + + ntpq/ntpq-subs.c@1.52 +1 -1 + use ========= instead of --------- to separate column headings + from rows in mrulist(). + +ChangeSet@1.2110.1.16, 2010-03-04 17:17:47+00:00, davehart@shiny.ad.hartbrothers.com + new "ntpq -c mrulist" along lines of "ntpdc -c monlist" but + without being limited to a single request response, and + designed to work reliably even with an arbitrarily large + MRU list. + + include/ntp_fp.h@1.18 +1 -0 + add sptoa()/sockporttoa() similar to stoa()/socktoa(). + + include/ntp_lists.h@1.5 +27 -5 + add NEXT_DLIST(), PREV_DLIST(), LINK_TAIL_DLIST() macros. + + include/ntp_stdlib.h@1.44 +3 -1 + move sock_hash from ntpd/ntp_util.c to libntp/socktoa.c so + ntpq can use it. + add sptoa()/sockporttoa() similar to stoa()/socktoa(). + + include/ntpd.h@1.137.1.11 +6 -2 + move sock_hash from ntpd/ntp_util.c to libntp/socktoa.c so + ntpq can use it. + expose MON_HASH(), mon_hash[] so ntp_control.c can use them. + + libntp/decodenetnum.c@1.12 +40 -8 + support 1.2.3.4:123, [2001::1]:123 port specification in + decodenetnum(). + + libntp/socktoa.c@1.12 +72 -2 + move sock_hash from ntpd/ntp_util.c to libntp/socktoa.c so + ntpq can use it. + add sptoa()/sockporttoa() similar to stoa()/socktoa(). + + ntpd/ntp_control.c@1.133.1.7 +221 -21 + read_mru_list() for ntpq -c mrulist + + ntpd/ntp_monitor.c@1.32 +2 -5 + expose MON_HASH(), mon_hash[] so ntp_control.c can use them. + + ntpd/ntp_restrict.c@1.32 +2 -1 + correct type for restrictions() local flags to u_short. + + ntpd/ntp_util.c@1.80 +4 -50 + move sock_hash from ntpd/ntp_util.c to libntp/socktoa.c so + ntpq can use it. + use memcpy() instead of memmove() when buffers can't overlap. + + ntpq/ntpq-subs.c@1.51 +430 -28 + new "ntpq -c mrulist" along lines of "ntpdc -c monlist" but + without being limited to a single request response, and + designed to work reliably even with an arbitrarily large + MRU list. + + ntpq/ntpq.c@1.105 +100 -51 + bump MAXFRAGS from 24 to 64 to enable larger responses. + add show_error_msg(), doqueryex() for mrulist(). + + + ntpq/ntpq.h@1.12 +11 -2 + add show_error_msg(), doqueryex() for mrulist(). + +ChangeSet@1.2110.1.15, 2010-03-02 10:00:34+00:00, davehart@shiny.ad.hartbrothers.com + ntp_net.h: + add ADDR_EQ_PORT() like SOCK_EQ() but testing port as well. + ntpq-subs.c, ntpq.c, ntpq.h: + use associd_t for association IDs instead of int. + systime.c, ntp_fp.h: + provide callback from step_systime() to allow ntpd to flush + the MRU list when stepping the clock. + ntp_proto.c: + use u_short for restrict_mask type in receive(), expand comment. + ntp_util.c: + Use callback from step_systime() to flush the MRU list when + stepping the clock. Previously the MRU timestamps were in + current_time units, which are monotonically increasing despite + any steps of the system clock. Now they are l_fp and subject + to steps, so flush the MRU list when the clock is stepped to + ensure all timestamps are comparable. + recvbuff.h: + whitespace only + ntp_request.c: + prepare for ntpq mrulist command by converting MRU entry timestamps + from current_time (seconds) to l_fp (32:32 NTP standard). + rename info_monitor, info_monitor_1 fields to reflect their + use, lasttime -> avg_int and firsttime -> last_int. + ntp_iocompletionport.c: + validate recv_srcadr_len against (now smaller) sockaddr_u size. + ntp_control.h: + add CTL_OP_READMRU for ntpq mrulist + ntpd.h: + add prototype for win_time_stepped(), previously called + time_stepped(). + ntp_control.c: + add CTL_OP_READ_MRU for ntpq -c mrulist + layout.std, ntpdc_ops.c: + rename info_monitor, info_monitor_1 fields to reflect their + use, lasttime -> avg_int and firsttime -> last_int + ntp_restrict.c: + wrap a long line + ntp_monitor.c, ntp.h: + prepare for ntpq mrulist command by converting MRU entry timestamps + from current_time (seconds) to l_fp (32:32 NTP standard). + ntp_request.h: + rename info_monitor, info_monitor_1 fields to reflect their + use, lasttime -> avg_int and firsttime -> last_int. + SetSystemTime.c, nt_clockstuff.c, clockstuff.h: + rename time_stepped() callback to win_time_stepped(), move + callback registration from Windows port to portable code + now that ntpd/ntp_util.c is using it. + + include/ntp.h@1.174 +7 -7 + prepare for ntpq mrulist command by converting MRU entry timestamps + from current_time (seconds) to l_fp (32:32 NTP standard). + + include/ntp_control.h@1.42 +5 -4 + add CTL_OP_READMRU for ntpq mrulist + + include/ntp_fp.h@1.17 +8 -2 + provide callback from step_systime() to allow ntpd to flush + the MRU list when stepping the clock. + + include/ntp_net.h@1.6 +7 -1 + add ADDR_EQ_PORT() like SOCK_EQ() but testing port as well. + + include/ntp_request.h@1.41 +5 -5 + rename info_monitor, info_monitor_1 fields to reflect their + use, lasttime -> avg_int and firsttime -> last_int. + + include/ntpd.h@1.137.1.10 +7 -3 + add prototype for win_time_stepped(), previously called + time_stepped(). + + include/recvbuff.h@1.21 +1 -1 + whitespace only + + libntp/systime.c@1.50 +3 -0 + provide callback from step_systime() to allow ntpd to flush + the MRU list when stepping the clock. + + ntpd/ntp_control.c@1.133.1.6 +93 -3 + add CTL_OP_READ_MRU for ntpq -c mrulist + + ntpd/ntp_monitor.c@1.31 +117 -102 + prepare for ntpq mrulist command by converting MRU entry timestamps + from current_time (seconds) to l_fp (32:32 NTP standard). + + ntpd/ntp_proto.c@1.297.1.9 +3 -1 + use u_short for restrict_mask type in receive(), expand comment. + + ntpd/ntp_request.c@1.89 +23 -13 + prepare for ntpq mrulist command by converting MRU entry timestamps + from current_time (seconds) to l_fp (32:32 NTP standard). + rename info_monitor, info_monitor_1 fields to reflect their + use, lasttime -> avg_int and firsttime -> last_int. + + ntpd/ntp_restrict.c@1.31 +3 -2 + wrap a long line + + ntpd/ntp_util.c@1.79 +37 -8 + Use callback from step_systime() to flush the MRU list when + stepping the clock. Previously the MRU timestamps were in + current_time units, which are monotonically increasing despite + any steps of the system clock. Now they are l_fp and subject + to steps, so flush the MRU list when the clock is stepped to + ensure all timestamps are comparable. + + ntpdc/layout.std@1.10 +4 -4 + rename info_monitor, info_monitor_1 fields to reflect their + use, lasttime -> avg_int and firsttime -> last_int + + ntpdc/ntpdc_ops.c@1.65 +4 -4 + rename info_monitor, info_monitor_1 fields to reflect their + use, lasttime -> avg_int and firsttime -> last_int + + ntpq/ntpq-subs.c@1.50 +25 -22 + use associd_t for association IDs instead of int. + + ntpq/ntpq.c@1.104 +4 -4 + use associd_t for association IDs instead of int. + + ntpq/ntpq.h@1.11 +1 -1 + use associd_t for association IDs instead of int. + + ports/winnt/include/clockstuff.h@1.11 +0 -11 + rename time_stepped() callback to win_time_stepped(), move + callback registration from Windows port to portable code + now that ntpd/ntp_util.c is using it. + + ports/winnt/libntp/SetSystemTime.c@1.9 +0 -5 + rename time_stepped() callback to win_time_stepped(), move + callback registration from Windows port to portable code + now that ntpd/ntp_util.c is using it. + + ports/winnt/ntpd/nt_clockstuff.c@1.42 +3 -9 + rename time_stepped() callback to win_time_stepped(), move + callback registration from Windows port to portable code + now that ntpd/ntp_util.c is using it. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.53 +9 -5 + validate recv_srcadr_len against (now smaller) sockaddr_u size. + +ChangeSet@1.2110.1.14, 2010-03-01 12:47:33+00:00, davehart@shiny.ad.hartbrothers.com + determine MRU hash table size at runtime, attempting to + average 8 entries per bucket at mru_maxdepth capacity. + adjust defaults for mru_maxdepth, mru_initmem. + + include/ntp.h@1.173 +1 -1 + determine MRU hash table size at runtime, attempting to + average 8 entries per bucket at mru_maxdepth capacity. + + ntpd/ntp_monitor.c@1.30 +32 -10 + determine MRU hash table size at runtime, attempting to + average 8 entries per bucket at mru_maxdepth capacity. + adjust defaults for mru_maxdepth, mru_initmem. + + ntpd/ntp_util.c@1.78 +2 -3 + determine MRU hash table size at runtime, attempting to + average 8 entries per bucket at mru_maxdepth capacity. + +ChangeSet@1.2110.1.13, 2010-03-01 09:20:28+00:00, davehart@shiny.ad.hartbrothers.com + remove bloated (128 byte on win32) sockaddr_storage from sockaddr_u + union since the largest we use is sockaddr_in6 (28 bytes on win32). + + include/ntp_net.h@1.5 +2 -3 + remove bloated (128 byte on win32) sockaddr_storage from sockaddr_u + union since the largest we use is sockaddr_in6 (28 bytes on win32). + + ntpd/ntp_config.c@1.255 +1 -1 + remove bloated (128 byte on win32) sockaddr_storage from sockaddr_u + union since the largest we use is sockaddr_in6 (28 bytes on win32). + + ntpd/ntp_io.c@1.315 +3 -3 + remove bloated (128 byte on win32) sockaddr_storage from sockaddr_u + union since the largest we use is sockaddr_in6 (28 bytes on win32). + + ntpd/ntp_monitor.c@1.29 +5 -0 + comment about mon_age implementation + + ntpd/ntp_request.c@1.88 +10 -10 + remove bloated (128 byte on win32) sockaddr_storage from sockaddr_u + union since the largest we use is sockaddr_in6 (28 bytes on win32). + + ntpd/refclock_nmea.c@1.48 +0 -2 + remove unused macros left over from distinct PPSAPI code + + ntpdc/ntpdc_ops.c@1.64 +3 -3 + remove bloated (128 byte on win32) sockaddr_storage from sockaddr_u + union since the largest we use is sockaddr_in6 (28 bytes on win32). + + sntp/networking.c@1.32 +2 -2 + remove bloated (128 byte on win32) sockaddr_storage from sockaddr_u + union since the largest we use is sockaddr_in6 (28 bytes on win32). + +ChangeSet@1.2110.1.12, 2010-02-27 23:34:22+00:00, davehart@shiny.ad.hartbrothers.com + ntp_proto.c: + broadcast demobilization fix from DLM + + ntpd/ntp_proto.c@1.297.1.8 +4 -4 + broadcast demobilization fix from DLM + +ChangeSet@1.2110.1.11, 2010-02-27 22:48:05+00:00, davehart@shiny.ad.hartbrothers.com + Many files: + more MRU knobs + ntp_keyword.h, keyword-gen-utd: + keyword-gen.c product + ntp_parser.h, ntp_parser.c: + ntp_parser.y product + ntp_request.c: + limit 'ntpdc -c monlist' response to most recent 600 entries, to + be consistent with the historical maximum MRU list size. + ntpq-subs.c: + read up to three named variables at once: + ntpq -c "rv 0 version mru_depth mru_maxmem" + + include/ntp_control.h@1.41 +17 -9 + more MRU knobs + + include/ntpd.h@1.137.1.9 +11 -7 + more MRU knobs + + ntpd/complete.conf@1.6 +1 -1 + more MRU knobs + + ntpd/keyword-gen-utd@1.5 +1 -1 + keyword-gen.c product + + ntpd/keyword-gen.c@1.9 +5 -1 + more MRU knobs + + ntpd/ntp_config.c@1.254 +48 -15 + more MRU knobs + + ntpd/ntp_control.c@1.133.1.5 +59 -9 + more MRU knobs + + ntpd/ntp_keyword.h@1.7 +679 -657 + keyword-gen.c product + + ntpd/ntp_monitor.c@1.28 +145 -96 + more MRU knobs + + ntpd/ntp_parser.c@1.55 +992 -949 + ntp_parser.y product + + ntpd/ntp_parser.h@1.35 +247 -239 + ntp_parser.y product + + ntpd/ntp_parser.y@1.50 +12 -4 + more MRU knobs + + ntpd/ntp_request.c@1.87 +8 -2 + limit 'ntpdc -c monlist' response to most recent 600 entries, to + be consistent with the historical maximum MRU list size. + + ntpq/ntpq-subs.c@1.49 +12 -7 + read up to three named variables at once: + ntpq -c "rv 0 version mru_depth mru_maxmem" + +ChangeSet@1.2110.1.10, 2010-02-27 10:03:55+00:00, davehart@shiny.ad.hartbrothers.com + keyword-gen.c: + include matching keyword prefix in ntp_keyword.h state entry comment. + + ntpd/keyword-gen-utd@1.4 +1 -1 + product of keyword-gen.c + + ntpd/keyword-gen.c@1.8 +70 -13 + include matching keyword prefix in ntp_keyword.h state entry comment. + + ntpd/ntp_keyword.h@1.6 +579 -579 + product of keyword-gen.c + +ChangeSet@1.2110.1.9, 2010-02-27 08:47:04+00:00, davehart@shiny.ad.hartbrothers.com + ntp_parser.h, ntp_parser.c: + product of ntp_parser.y + keyword-gen-utd: + accompanies new keyword-gen.c and ntp_keyword.h + Many files: + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + ntp.h, ntp_request.c: + remove redundant storage of port in mon_entry, rmtadr has it. + ntp_keyword.h: + product of keyword-gen.c + + include/ntp.h@1.172 +0 -1 + remove redundant storage of port in mon_entry, rmtadr has it. + + include/ntp_config.h@1.66.1.5 +1 -0 + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + + include/ntpd.h@1.137.1.8 +4 -1 + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + + ntpd/complete.conf@1.5 +2 -1 + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + + ntpd/keyword-gen-utd@1.3 +1 -1 + accompanies new keyword-gen.c and ntp_keyword.h + + ntpd/keyword-gen.c@1.7 +6 -0 + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + + ntpd/ntp_config.c@1.253 +67 -4 + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + + ntpd/ntp_keyword.h@1.5 +534 -513 + product of keyword-gen.c + + ntpd/ntp_monitor.c@1.27 +61 -32 + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + + ntpd/ntp_parser.c@1.54 +973 -897 + product of ntp_parser.y + + ntpd/ntp_parser.h@1.34 +191 -181 + product of ntp_parser.y + + ntpd/ntp_parser.y@1.49 +25 -0 + add MRU sizing knobs: + mru mindepth 600 maxage 64 maxdepth 1024 maxmem 4096 + entries beyond 600 which are older than 64s are reclaimed, + with a hard upper limit on the size of maxdepth (indirectly + set by maxmem). + + ntpd/ntp_request.c@1.86 +2 -2 + remove redundant storage of port in mon_entry, rmtadr has it. + +ChangeSet@1.2110.1.8, 2010-02-26 22:59:36+00:00, davehart@shiny.ad.hartbrothers.com + ntp_config.c: + Dr. Mills doesn't like depending on && not evaluating right side + if left is false. + ntp_proto.c: + timeout demobilizations don't seem to be working for preemptibles. + + ntpd/ntp_config.c@1.252 +10 -6 + Dr. Mills doesn't like depending on && not evaluating right side + if left is false. + + ntpd/ntp_proto.c@1.297.1.7 +21 -12 + timeout demobilizations don't seem to be working for preemptibles. + +ChangeSet@1.2110.1.7, 2010-02-26 15:53:49+00:00, davehart@shiny.ad.hartbrothers.com + ntpq-subs.c: + just the facts, ma'am + ntp_control.c: + DLM changes via email notes + ntp_proto.c: + DLM changes via email notes. + remove "unlucky" experiment to track DLM changes. + + ntpd/ntp_control.c@1.133.1.4 +1 -1 + DLM changes via email notes + + ntpd/ntp_proto.c@1.297.1.6 +15 -42 + DLM changes via email notes. + remove "unlucky" experiment to track DLM changes. + + ntpq/ntpq-subs.c@1.48 +1 -2 + just the facts, ma'am + +ChangeSet@1.2110.1.6, 2010-02-25 15:45:14+00:00, davehart@shiny.ad.hartbrothers.com + nt_clockstuff.c: + suppress reports of interpolated clock "would have" gone backward + for less than 10 usec. + ntp_proto.c: + experiment with turning over 50% of preemptibles daily + + ntpd/ntp_proto.c@1.297.1.5 +26 -2 + experiment with turning over 50% of preemptibles daily + + ports/winnt/ntpd/nt_clockstuff.c@1.41 +23 -19 + suppress reports of interpolated clock "would have" gone backward + for less than 10 usec. + +ChangeSet@1.2110.1.5, 2010-02-25 06:34:58+00:00, davehart@shiny.ad.hartbrothers.com + ntp_proto.c: + cull from preemptibles randomly as well as when unreachable + long enough. + work_thread.c: + increase blocking_workitems max queue depth to 128 on Windows + ntp_control.h: + whitespace only + nt_clockstuff.c: + expose performance counter drift as ctr_frequency sysvar. + ntp_intres.c, ntpd.h, ntp_config.c: + add retry argument to getaddrinfo_sometime() so that pool lookups + can be one-shot. + ntp_peer.c: + test speer->flags not peer->flags for FLAG_PREEMPT + + include/ntp_control.h@1.40 +3 -3 + whitespace only + + include/ntpd.h@1.137.1.7 +4 -2 + add retry argument to getaddrinfo_sometime() so that pool lookups + can be one-shot. + + ntpd/ntp_config.c@1.251 +14 -6 + add retry argument to getaddrinfo_sometime() so that pool lookups + can be one-shot. + + ntpd/ntp_intres.c@1.86 +2 -3 + add retry argument to getaddrinfo_sometime() so that pool lookups + can be one-shot. + + ntpd/ntp_peer.c@1.132 +11 -7 + test speer->flags not peer->flags for FLAG_PREEMPT + + ntpd/ntp_proto.c@1.297.1.4 +17 -11 + cull from preemptibles randomly as well as when unreachable + long enough. + + ntpd/work_thread.c@1.2 +1 -1 + increase blocking_workitems max queue depth to 128 on Windows + + ports/winnt/ntpd/nt_clockstuff.c@1.40 +24 -16 + expose performance counter drift as ctr_frequency sysvar. + +ChangeSet@1.2113, 2010-02-25 00:53:22-05:00, clemens@pogo.udel.edu + This is a group of 4 patches that + (1) replace blanks with tabs in the source. + (2) provide a cleaner solution to turning FLAG_PPS on/off in oncore_get_timestamp. + (3) change LOG_INFO -> LOG_DEFAULT for one message, reducing the extraneous message + in the messages log. + (4) an implementation of [Bug1390] initially provided by Russell Yount, to turn the + PPS signal on/off. Note that this does NOT affect timekeeping. + + ntpd/refclock_oncore.c@1.86 +60 -3 + Bug[1390] allows the user to turn PPS on/off, and determine what + causes it to go off (off, on always, on if tracking 1 or more satellites, + or controled by TRAIM). + + Note that OFF is not implemented, since w/o the PPS, the oncore driver + will not run. + + Note that we default to an initial OFF state, since this seems most + reasonable till the driver gets to the RUN state. Once in the RUN + state, we determine if we should turn the PPS signal on/off each cycle. + + + ntpd/refclock_oncore.c@1.85 +2 -2 + Just an indent and change a LOG_INFO -> LOG_DEBUG to reduce default output. + + + ntpd/refclock_oncore.c@1.84 +3 -11 + Cleaner solution to flipping FLAG_PPS on/off in oncore_get_timestamp. + + + ntpd/refclock_oncore.c@1.83 +12 -12 + The source for the oncore driver uses tabs wherever possible to + replace strings of blanks. Replace blanks with tabs from a + previous patch that did not adhere to this strategy. + + +ChangeSet@1.2110.1.4, 2010-02-24 06:25:27+00:00, davehart@shiny.ad.hartbrothers.com + new peer variable "srchost" shown instead of 0.0.0.0 srcadr in + ntpq peers billboard for .POOL. prototype associations. + + include/ntp_control.h@1.39 +9 -8 + new peer variable "srchost" shown instead of 0.0.0.0 srcadr in + ntpq peers billboard for .POOL. prototype associations. + + ntpd/ntp_control.c@1.133.1.3 +16 -8 + new peer variable "srchost" shown instead of 0.0.0.0 srcadr in + ntpq peers billboard for .POOL. prototype associations. + + ntpd/ntp_peer.c@1.131 +8 -3 + ignore "preempt" on manycastclient, pool prototype associations. + + ntpq/ntpq-subs.c@1.47 +28 -11 + new peer variable "srchost" shown instead of 0.0.0.0 srcadr in + ntpq peers billboard for .POOL. prototype associations. + + ntpq/ntpq.c@1.103 +9 -8 + new peer variable "srchost" shown instead of 0.0.0.0 srcadr in + ntpq peers billboard for .POOL. prototype associations. + +ChangeSet@1.2110.1.3, 2010-02-23 09:47:25+00:00, davehart@shiny.ad.hartbrothers.com + "restrict source ..." to set restrictions for peers. + [Bug 1497] fudge is broken by getnetnum() change + + include/ntp.h@1.171 +2 -0 + add RESM_SOURCE for "restrict source ..." + + include/ntp_lists.h@1.4 +12 -0 + add CHECK_SLIST() debugging helper macro to detect a couple of + ways a singly-linked list can go awry. + + include/ntp_refclock.h@1.25 +11 -16 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + remove prototypes for previously-removed functions. + + include/ntpd.h@1.137.1.6 +3 -2 + add restrict_source() to add/remove restrictions for each + association automatically ("restrict source ...") + + ntpd/complete.conf@1.4 +2 -1 + add "restrict source ..." test + + ntpd/keyword-gen-utd@1.2 +1 -1 + generated from ntp_keyword.c + + ntpd/keyword-gen.c@1.6 +15 -1 + add "source" as in "restrict source ..." + + ntpd/ntp_config.c@1.250 +136 -105 + "restrict source ..." to set restrictions for peers. + [Bug 1497] fudge is broken by getnetnum() change + + ntpd/ntp_intres.c@1.85 +0 -9 + test use of copy_addrinfo_list() no longer helpful as it has a real + consumer now. + + ntpd/ntp_io.c@1.314 +2 -2 + "restrict source ..." to set restrictions for peers. + + ntpd/ntp_keyword.h@1.4 +421 -415 + generated from ntp_keyword.c + + ntpd/ntp_parser.c@1.53 +788 -774 + ntp_parser.y compiled + + ntpd/ntp_parser.h@1.33 +83 -81 + ntp_parser.y compiled + + ntpd/ntp_parser.y@1.48 +11 -2 + "restrict source ..." to set restrictions for peers. + + ntpd/ntp_peer.c@1.130 +17 -13 + "restrict source ..." to set restrictions for peers. + + ntpd/ntp_proto.c@1.297.1.3 +10 -0 + "restrict source ..." to set restrictions for peers. + + ntpd/ntp_refclock.c@1.91.1.3 +3 -2 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpd/ntp_request.c@1.85 +1 -1 + "restrict source ..." to set restrictions for peers. + + ntpd/ntp_restrict.c@1.30 +144 -32 + "restrict source ..." to set restrictions for peers. + + ntpd/refclock_datum.c@1.14 +3 -3 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpd/refclock_jupiter.c@1.25 +5 -5 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpd/refclock_leitch.c@1.12 +2 -2 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpd/refclock_nmea.c@1.47 +2 -2 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpd/refclock_parse.c@1.53 +3 -3 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpd/refclock_ripencc.c@1.8 +3 -3 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpd/refclock_wwvb.c@1.23.1.2 +2 -2 + make refclock control entrypoint, refclock_control()'s input + struct refclockstat pointer const. + + ntpdc/ntpdc_ops.c@1.63 +1 -0 + "restrict source ..." to set restrictions for peers. + +ChangeSet@1.2110.1.2, 2010-02-20 17:52:58+00:00, davehart@shiny.ad.hartbrothers.com + new pool implementation modeled on manycastclient. + + include/ntp.h@1.170 +26 -16 + add hostname, addrs, ai members to struct peer for pool. + remove unused PPSREFID. + add MDF_POOL, rename MDF_ACLNT -> MDF_UCLNT to cover both + manycastclient and pool ephemeral associations. + add MDF_SOLICIT_MASK (MDF_ACAST | MDF_POOL). + + + include/ntp_config.h@1.66.1.4 +2 -2 + change address_node->type (family) type from short to u_short. + + include/ntpd.h@1.137.1.5 +10 -7 + changes for pool + + ntpd/ntp_config.c@1.249 +54 -53 + changes for pool + + ntpd/ntp_control.c@1.133.1.2 +1 -1 + rename MDF_SRVCASTMASK -> MDF_TXONLY_MASK. + + ntpd/ntp_peer.c@1.129 +198 -109 + changes for pool + + ntpd/ntp_proto.c@1.297.1.2 +215 -58 + changes for pool + + ntpd/ntp_refclock.c@1.91.1.2 +2 -2 + changes for pool + + ntpd/ntp_request.c@1.84 +12 -29 + changes for pool + + ntpd/ntp_worker.c@1.2 +1 -1 + Change worker child idle timeout to 3 minutes (was 15s) + + ntpd/ntpsim.c@1.24 +1 -0 + changes for pool + + ntpdc/ntpdc.c@1.80 +23 -13 + fix sizeof() abuse in getnetnum(), incorrect assumption that ai_canonname + is always non-NULL + + ntpq/ntpq-subs.c@1.46 +4 -2 + correct T column comments, value for manycastclient (A -> a). + + ntpq/ntpq.c@1.102 +22 -16 + fix sizeof() abuse in getnetnum(), incorrect assumption that ai_canonname + is always non-NULL + +ChangeSet@1.2110.1.1, 2010-02-17 09:54:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1483] AI_NUMERICSERV undefined in 4.2.7p20. + Maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + Remove more workarounds unneeded since we require ISO C90 AKA ANSI C: + - remove fallback implementations for memmove(), memset, strstr(). + - do not test for atexit() or memcpy(). + Collapse a bunch of code duplication in ntpd/ntp_restrict.c added with + support for IPv6. + Correct some corner case failures in automatically enabling the MRU + list if any "restrict ... limited" is in effect, and in disabling MRU + maintenance. (ntp_monitor.c, ntp_restrict.c) + Reverse the internal sort order of the address restriction lists, but + preserve the same behavior. This allows removal of special-case code + related to the default restrictions and more straightforward lookups + of restrictions for a given address (now, stop on first match). + Move ntp_restrict.c MRU doubly-linked list maintenance code into + ntp_lists.h macros, allowing more duplicated source excision. + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + Repair ntpdate.c to handle no longer testing HAVE_TIMER_SETTIME. + Do not reference peer_node/unpeer_node after freeing when built with + --disable-saveconfig and using DNS. + + BitKeeper/deleted/.del-memmove.c~3e480692@1.4 +0 -0 + Rename: libntp/memmove.c -> BitKeeper/deleted/.del-memmove.c~3e480692 + + BitKeeper/deleted/.del-strstr.c~55aa8716fa42aa@1.2 +0 -0 + Rename: libntp/strstr.c -> BitKeeper/deleted/.del-strstr.c~55aa8716fa42aa + + ChangeLog@1.541.1.1 +23 -0 + [Bug 1483] AI_NUMERICSERV undefined in 4.2.7p20. + Maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + Remove more workarounds unneeded since we require ISO C90 AKA ANSI C: + - remove fallback implementations for memmove(), memset, strstr(). + - do not test for atexit() or memcpy(). + Collapse a bunch of code duplication in ntpd/ntp_restrict.c added with + support for IPv6. + Correct some corner case failures in automatically enabling the MRU + list if any "restrict ... limited" is in effect, and in disabling MRU + maintenance. (ntp_monitor.c, ntp_restrict.c) + Reverse the internal sort order of the address restriction lists, but + preserve the same behavior. This allows removal of special-case code + related to the default restrictions and more straightforward lookups + of restrictions for a given address (now, stop on first match). + Move ntp_restrict.c MRU doubly-linked list maintenance code into + ntp_lists.h macros, allowing more duplicated source excision. + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + Repair ntpdate.c to handle no longer testing HAVE_TIMER_SETTIME. + Do not reference peer_node/unpeer_node after freeing when built with + --disable-saveconfig and using DNS. + + configure.ac@1.479 +1 -2 + Remove more workarounds unneeded since we require ISO C90 AKA ANSI C: + - remove fallback implementations for memmove(), memset, strstr(). + - do not test for memcpy(). + + + flock-build@1.44.1.1 +26 -21 + fix bug with SIMUL=2 flock-build -1 + + include/ntp.h@1.169 +57 -46 + maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + rename peer link members: next -> adr_link, ass_next->aid_link. + add VN_MODE() for MRU list, which doesn't store LI but does now + combine version and mode in one octet. use VN_MODE() in + PKT_LI_VN_MODE. + add mon_entry typedef for struct mon_data. + move ntp_restrict.c MRU doubly-linked list maintenance code into + ntp_lists.h macros, allowing more duplicated source excision. + rename struct mon_data.interface -> mon_entry.lcladr to mirror + mon_entry.rmtadr. + note disuse of MDF_LCAST without removing it. + add MDF_SRVCASTMASK (MDF_MCAST | MDF_BCAST | ACAST). + Combine IPv4 and IPv6 restrict list entry structures into one + variable-size structure with a union at the end of V4 and v6 + addresses, enabling removal of duplicated code. + + + include/ntp_config.h@1.66.1.3 +19 -18 + add uint u to attr_val.value union. + + include/ntp_crypto.h@1.47 +1 -1 + use void * for variant pointer struct value.ptr. + + include/ntp_lists.h@1.3 +119 -7 + Add LINK_SORT_SLIST() macro to insert into a sorted list. + Add doubly-linked list macros wrapping existing logic from ntp_restrict.c: + INIT_DLIST(), HEAD_DLIST(), TAIL_DLIST(), LINK_DLIST(), UNLINK_DLIST(), + ITER_DLIST_BEGIN(), ITER_DLIST_END(). + + include/ntp_net.h@1.4 +20 -9 + remove unhelpful (void *) cast in MEMSET_ADDR6(). + add ADDR6_CMP(), ADDR6_EQ() helpers for in6_addr. + + include/ntp_rfc2553.h@1.36 +9 -1 + handle AI_NUMERICSERV being unavailable. + + include/ntp_stdlib.h@1.43 +0 -4 + relocate latoa(), localaddrtoa() to ntpd.h + + include/ntp_string.h@1.6 +1 -15 + NTP requires ISO C90/ANSI C, remove workarounds for missing + strchr(), strrchr(), memcpy(). + + include/ntp_types.h@1.19 +3 -1 + add ASSOCID_MAX, KEYID_T_MAX + + include/ntpd.h@1.137.1.4 +73 -59 + Add comments clarifying and demarcing division of file into + two parts, with only variable extern declarations in the + second half. + rename ntp_monclearinterface() -> mon_clearinterface(). + correct many scalar type declarations and function argument + types to eliminate truncation and implicit pointer cast + warnings, particularly int -> u_char and int -> u_short. + introduce mon_entry typedef (alias of struct mon_data) and + convert most references. + include hash array size in external declaration to better + inform compilers. + maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + adds peer_list, peer_count globals. + rename restrictlist -> restrictlist4. + + libntp/Makefile.am@1.52 +0 -2 + NTP requires an ISO C90 (ANSI C) compiler: + - remove fallback memmove(), strstr() + + libntp/decodenetnum.c@1.11 +1 -1 + use Z_AI_NUMERICHOST to document it may be zero and should not + be used with bitwise NOT (~) + + libntp/machines.c@1.22 +0 -13 + NTP requires an ISO C90 (ANSI C) compiler: + - remove fallback memset() + + libntp/strdup.c@1.7 +15 -14 + minor cleanup, use memcpy() instead of strcpy() + + ntpd/Makefile.am@1.91 +1 -1 + ntp_data_structures does not need to be built in both SIM and + normal versions as it and its headers do not use #ifdef SIM. + + ntpd/ntp_config.c@1.248 +129 -98 + Eliminate warnings by correcting many scalar types. + Do not reference peer_node/unpeer_node after freeing when built with + --disable-saveconfig and using DNS. + + ntpd/ntp_control.c@1.133.1.1 +571 -614 + [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). + Use memcpy() instead of memmove() where the buffers can not overlap. + Re-enable "Possible 'ntpdx' exploit" message with rate-limiting to + 12 per hour. + maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + adds peer_list, peer_count globals. + use erealloc() in place of free() then emalloc(). + + ntpd/ntp_crypto.c@1.147 +28 -25 + eliminate warnings with casts and type corrections. + + ntpd/ntp_intres.c@1.84 +3 -3 + use \n with DPRINTF + + ntpd/ntp_io.c@1.313 +12 -1 + rename ntp_monclearinterface() -> mon_clearinterface(). + implement localaddrtoa(), similar to socktoa(). + + ntpd/ntp_loopfilter.c@1.153.1.1 +0 -4 + remove VMS-specific include that is no longer required. + + ntpd/ntp_monitor.c@1.26 +98 -132 + rename MAXMONMEM -> MAX_MONLIST + rename MONMEMINC -> INC_MONLIST + in both cases, respect the old name if defined (likely with -D). + change most struct mon_data references to mon_entry. + move doubly-linked list code to ntp_lists *_DLIST() macros. + use *_SLIST() macros for monitor hash lists. + rename ntp_monclearinterface() -> mon_clearinterface(). + rename struct mon_data.interface -> mon_entry.lcladr to mirror + mon_entry.rmtadr. + no point in memset(p, 0, size); then memcpy(p, src, size);. + combine mon_entry.version and mon_entry.mode into mon_entry.vn_mode. + + + ntpd/ntp_peer.c@1.128 +184 -224 + maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + change initial, incremental peer allocs from 15, 5 to 8, 4. + do not zero variables at startup that are zero-initialized. + + ntpd/ntp_proto.c@1.297.1.1 +125 -137 + remove VMS-specific include of ntp_refclock.h, appears unneeded. + silence many truncation and implicit conversion warnings by changing + types or typecasting. + maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + rename clock_select() array of peers from peer_list to peers to avoid + conflicting with new global listhead peers_list. + use erealloc() instead of free() then emalloc(). + allocate clock_select()'s three peer-related arrays together to + minimize cache lines used. + do not reuse hpoll local in poll_update as scratch int. + + ntpd/ntp_refclock.c@1.91.1.1 +3 -1 + eliminate truncation warning for 64-bit time_t with (u_int32) + + ntpd/ntp_request.c@1.83 +196 -253 + maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + rename peer_list() -> list_peers() to avoid conflict with new global + listhead peer_list. + rename peer_list_sum -> list_peers_sum() to maintain consistency. + add list_restrict4(), list_restrict6() helpers for list_restrict() + which reverse the order of the returned restrictions to match + previous behavior and documentation, now that it's maintained in + a reversed sort order internally vs. previously. + get rid of duplicative extern references to global variables in + a number of functions (rely on ntpd.h). + + ntpd/ntp_restrict.c@1.29 +394 -419 + collapse a bunch of code duplication in ntpd/ntp_restrict.c added with + support for IPv6. Correct mistaken split of res_limited_refcount + code and data, one RES_LIMITED reference count should apply to both. + reverse the internal sort order of the address restriction lists, but + preserve the same behavior. This allows removal of special-case code + related to the default restrictions and more straightforward lookups + of restrictions for a given address (we can stop on the first match). + move ntp_restrict.c MRU doubly-linked list maintenance code into + ntp_lists.h macros, allowing more duplicated source excision. + use *_SLIST() macros for mon_hash[] lists. + + ntpd/ntp_timer.c@1.58 +23 -28 + maintain and use linked list of associations (struct peer) in ntpd, + avoiding walking 128 hash table entries to iterate over peers. + + + ntpd/ntp_util.c@1.77 +3 -0 + #include for getpid(). + + ntpd/refclock_chronolog.c@1.10 +1 -1 + fix truncation warning with typecast. + + ntpd/refclock_chu.c@1.46.1.1 +1 -1 + refclock_open() returns 0 on failure + + ntpd/refclock_dumbclock.c@1.14.1.1 +1 -1 + refclock_open() returns 0 on failure + + ntpd/refclock_jupiter.c@1.24 +7 -7 + eliminate a raft of truncation and type conversion warnings. + + ntpd/refclock_wwvb.c@1.23.1.1 +1 -1 + refclock_open() returns 0 on failure + + ntpdate/ntpdate.c@1.72 +24 -44 + configure.ac no longer tests for timer_settime() separately fromm + timer_create().. + + ntpdc/ntpdc.c@1.79 +12 -9 + #include , for open(), close(), and isatty(). + + ntpq/ntpq.c@1.101 +15 -12 + #include , for open() and close(). + + ports/winnt/include/config.h@1.83 +0 -1 + HAVE_STRCHR is no longer needed. + + ports/winnt/libntp/termios.c@1.21.1.1 +14 -9 + refclock_open() returns 0 on failure + + ports/winnt/vc6/libntp.dsp@1.52 +0 -4 + remove memmove.c reference. + + ports/winnt/vs2003/libntp.vcproj@1.10 +0 -21 + remove memmove.c reference. + + ports/winnt/vs2005/libntp.vcproj@1.8 +0 -22 + remove memmove.c reference. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.28 +6 -14 + remove memmove.c and strstr.c references. + + sntp/configure.ac@1.32 +1 -1 + NTP requires ISO C90 (ANSI C) so don't test for atexit() or memset(). + +ChangeSet@1.2112, 2010-02-16 09:40:11+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1306] constant conditionals in audio_gain(). + + ChangeLog@1.543 +1 -0 + [Bug 1306] constant conditionals in audio_gain(). + + libntp/audio.c@1.28 +21 -21 + [Bug 1306] constant conditionals in audio_gain(). + +ChangeSet@1.2082.4.63, 2010-02-15 23:19:19+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. + + + ChangeLog@1.496.26.44 +9 -0 + [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. + + + flock-build@1.45 +26 -21 + Correct "SIMUL=4 ./flock-build -1" to prioritize -1/--one. + + ntpd/ntp_control.c@1.129.1.4 +2 -2 + [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) + and SHM (28). + + ntpd/ntp_refclock.c@1.92 +4 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + + ntpd/refclock_chu.c@1.47 +1 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + + ntpd/refclock_dumbclock.c@1.15 +1 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + + ntpd/refclock_wwvb.c@1.24 +1 -1 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + + ports/winnt/ntpd/win32_io.c@1.19.1.1 +15 -9 + Correct Windows port's refclock_open() to return 0 on failure not -1. + Correct CHU, dumbclock, and WWVB drivers to check for 0 returned from + refclock_open() on failure. + +ChangeSet@1.2110, 2010-02-13 11:56:48+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P20 + TAG: NTP_4_2_7P20 + + ChangeLog@1.541 +1 -0 + NTP_4_2_7P20 + + ntpd/ntpd-opts.c@1.21 +2 -2 + NTP_4_2_7P20 + + ntpd/ntpd-opts.h@1.21 +3 -3 + NTP_4_2_7P20 + + ntpd/ntpd-opts.texi@1.21 +2 -2 + NTP_4_2_7P20 + + ntpd/ntpd.1@1.21 +2 -2 + NTP_4_2_7P20 + + ntpdc/ntpdc-opts.c@1.21 +2 -2 + NTP_4_2_7P20 + + ntpdc/ntpdc-opts.h@1.21 +3 -3 + NTP_4_2_7P20 + + ntpdc/ntpdc-opts.texi@1.21 +2 -2 + NTP_4_2_7P20 + + ntpdc/ntpdc.1@1.21 +2 -2 + NTP_4_2_7P20 + + ntpq/ntpq-opts.c@1.21 +2 -2 + NTP_4_2_7P20 + + ntpq/ntpq-opts.h@1.21 +3 -3 + NTP_4_2_7P20 + + ntpq/ntpq-opts.texi@1.21 +2 -2 + NTP_4_2_7P20 + + ntpq/ntpq.1@1.21 +2 -2 + NTP_4_2_7P20 + + ntpsnmpd/ntpsnmpd-opts.c@1.21 +2 -2 + NTP_4_2_7P20 + + ntpsnmpd/ntpsnmpd-opts.h@1.21 +3 -3 + NTP_4_2_7P20 + + ntpsnmpd/ntpsnmpd-opts.texi@1.21 +2 -2 + NTP_4_2_7P20 + + ntpsnmpd/ntpsnmpd.1@1.21 +2 -2 + NTP_4_2_7P20 + + packageinfo.sh@1.22 +1 -1 + NTP_4_2_7P20 + + sntp/sntp-opts.c@1.21 +2 -2 + NTP_4_2_7P20 + + sntp/sntp-opts.h@1.21 +3 -3 + NTP_4_2_7P20 + + sntp/sntp-opts.texi@1.21 +2 -2 + NTP_4_2_7P20 + + sntp/sntp.1@1.21 +2 -2 + NTP_4_2_7P20 + + sntp/sntp.html@1.21 +1 -1 + NTP_4_2_7P20 + + util/ntp-keygen-opts.c@1.21 +2 -2 + NTP_4_2_7P20 + + util/ntp-keygen-opts.h@1.21 +3 -3 + NTP_4_2_7P20 + + util/ntp-keygen-opts.texi@1.21 +2 -2 + NTP_4_2_7P20 + + util/ntp-keygen.1@1.21 +2 -2 + NTP_4_2_7P20 + +ChangeSet@1.2102.2.1, 2010-02-09 18:19:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1483] hostname in ntp.conf "restrict" parameter rejected. + Use all addresses for each restrict by hostname. + Use async DNS to resolve trap directive hostnames. + + + ChangeLog@1.533.2.1 +3 -0 + [Bug 1483] hostname in ntp.conf "restrict" parameter rejected. + Use all addresses for each restrict by hostname. + Use async DNS to resolve trap directive hostnames. + + + include/ntp_config.h@1.66.1.2 +13 -2 + add settrap_params structure for trap_name_resolved() + + include/ntp_stdlib.h@1.42 +4 -0 + add localaddrtoa() alias latoa() macro evaluating to text of + a given struct interface *'s local address, or in the + case of a NULL struct interface *. + + ntpd/ntp_config.c@1.247 +177 -25 + [Bug 1483] use blocking DNS resolution for restrict hostnames. + Use all addresses resolved from a restrict hostname, instead + of only the first. + Use async DNS for trap directive hostnames. + + ntpd/ntp_peer.c@1.127 +4 -6 + use latoa(peer->dstadr) instead of more verbose equivalent. + + ntpd/ntp_restrict.c@1.28 +5 -5 + DPRINTF args to hack_restrict() for v6 as well as v4 addresses. + +ChangeSet@1.2108, 2010-02-09 11:57:34+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P19 + TAG: NTP_4_2_7P19 + + ChangeLog@1.539 +1 -0 + NTP_4_2_7P19 + + ntpd/ntpd-opts.c@1.20 +2 -2 + NTP_4_2_7P19 + + ntpd/ntpd-opts.h@1.20 +3 -3 + NTP_4_2_7P19 + + ntpd/ntpd-opts.texi@1.20 +2 -2 + NTP_4_2_7P19 + + ntpd/ntpd.1@1.20 +2 -2 + NTP_4_2_7P19 + + ntpdc/ntpdc-opts.c@1.20 +2 -2 + NTP_4_2_7P19 + + ntpdc/ntpdc-opts.h@1.20 +3 -3 + NTP_4_2_7P19 + + ntpdc/ntpdc-opts.texi@1.20 +2 -2 + NTP_4_2_7P19 + + ntpdc/ntpdc.1@1.20 +2 -2 + NTP_4_2_7P19 + + ntpq/ntpq-opts.c@1.20 +2 -2 + NTP_4_2_7P19 + + ntpq/ntpq-opts.h@1.20 +3 -3 + NTP_4_2_7P19 + + ntpq/ntpq-opts.texi@1.20 +2 -2 + NTP_4_2_7P19 + + ntpq/ntpq.1@1.20 +2 -2 + NTP_4_2_7P19 + + ntpsnmpd/ntpsnmpd-opts.c@1.20 +2 -2 + NTP_4_2_7P19 + + ntpsnmpd/ntpsnmpd-opts.h@1.20 +3 -3 + NTP_4_2_7P19 + + ntpsnmpd/ntpsnmpd-opts.texi@1.20 +2 -2 + NTP_4_2_7P19 + + ntpsnmpd/ntpsnmpd.1@1.20 +2 -2 + NTP_4_2_7P19 + + packageinfo.sh@1.21 +1 -1 + NTP_4_2_7P19 + + sntp/sntp-opts.c@1.20 +2 -2 + NTP_4_2_7P19 + + sntp/sntp-opts.h@1.20 +3 -3 + NTP_4_2_7P19 + + sntp/sntp-opts.texi@1.20 +2 -2 + NTP_4_2_7P19 + + sntp/sntp.1@1.20 +2 -2 + NTP_4_2_7P19 + + sntp/sntp.html@1.20 +1 -1 + NTP_4_2_7P19 + + util/ntp-keygen-opts.c@1.20 +2 -2 + NTP_4_2_7P19 + + util/ntp-keygen-opts.h@1.20 +3 -3 + NTP_4_2_7P19 + + util/ntp-keygen-opts.texi@1.20 +2 -2 + NTP_4_2_7P19 + + util/ntp-keygen.1@1.20 +2 -2 + NTP_4_2_7P19 + +ChangeSet@1.2082.4.62, 2010-02-09 10:34:59+00:00, stenn@whimsy.udel.edu + NTP_4_2_6P1_RC5 + TAG: NTP_4_2_6P1_RC5 + + ChangeLog@1.496.26.43 +1 -0 + NTP_4_2_6P1_RC5 + + ntpd/ntpd-opts.c@1.248.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpd/ntpd-opts.h@1.248.5.1 +3 -3 + NTP_4_2_6P1_RC5 + + ntpd/ntpd-opts.texi@1.246.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpd/ntpd.1@1.246.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpdc/ntpdc-opts.c@1.244.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpdc/ntpdc-opts.h@1.244.5.1 +3 -3 + NTP_4_2_6P1_RC5 + + ntpdc/ntpdc-opts.texi@1.243.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpdc/ntpdc.1@1.243.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpq/ntpq-opts.c@1.245.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpq/ntpq-opts.h@1.245.5.1 +3 -3 + NTP_4_2_6P1_RC5 + + ntpq/ntpq-opts.texi@1.244.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpq/ntpq.1@1.244.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.5.1 +3 -3 + NTP_4_2_6P1_RC5 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + ntpsnmpd/ntpsnmpd.1@1.122.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + packageinfo.sh@1.255.7.1 +1 -1 + NTP_4_2_6P1_RC5 + + sntp/sntp-opts.c@1.117.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + sntp/sntp-opts.h@1.117.5.1 +3 -3 + NTP_4_2_6P1_RC5 + + sntp/sntp-opts.texi@1.117.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + sntp/sntp.1@1.117.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + sntp/sntp.html@1.7.5.1 +1 -1 + NTP_4_2_6P1_RC5 + + util/ntp-keygen-opts.c@1.247.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + util/ntp-keygen-opts.h@1.247.5.1 +3 -3 + NTP_4_2_6P1_RC5 + + util/ntp-keygen-opts.texi@1.246.5.1 +2 -2 + NTP_4_2_6P1_RC5 + + util/ntp-keygen.1@1.246.5.1 +2 -2 + NTP_4_2_6P1_RC5 + +ChangeSet@1.2082.4.61, 2010-02-09 04:02:59-05:00, stenn@whimsy.udel.edu + [Bug 1438] Remove dead code from sntp/networking.c + + ChangeLog@1.496.26.42 +1 -0 + [Bug 1438] Remove dead code from sntp/networking.c + + sntp/networking.c@1.29.1.1 +0 -1 + [Bug 1438] Remove dead code from sntp/networking.c + +ChangeSet@1.2106, 2010-02-09 03:51:10-05:00, stenn@whimsy.udel.edu + [Bug 1338] Update the association type codes in ntpq.html. + + ChangeLog@1.537 +1 -0 + [Bug 1338] Update the association type codes in ntpq.html. + + html/copyright.html@1.47 +1 -1 + cleanup + + html/ntpq.html@1.39 +5 -2 + [Bug 1338] Update the association type codes in ntpq.html. + +ChangeSet@1.2102.1.1, 2010-02-09 03:23:58-05:00, stenn@whimsy.udel.edu + cleanup + + ChangeLog@1.533.1.1 +2 -1 + cleanup + +ChangeSet@1.2082.17.1, 2010-02-09 02:49:34-05:00, stenn@whimsy.udel.edu + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + ChangeLog@1.496.42.1 +1 -0 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + html/debug.html@1.27.1.1 +3 -3 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + html/decode.html@1.11.1.1 +11 -7 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + html/ntpq.html@1.36.1.1 +11 -7 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + +ChangeSet@1.2082.4.59, 2010-02-08 14:11:12+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. + [Bug 1479] Compilation fails because of not finding readline headers. + [Bug 1484] ushort is not defined in QNX6. + + ChangeLog@1.496.26.40 +3 -0 + [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. + [Bug 1479] Compilation fails because of not finding readline headers. + [Bug 1484] ushort is not defined in QNX6. + + include/mbg_gps166.h@1.10 +1 -1 + [Bug 1484] ushort is not defined in QNX6. + + libntp/ntp_lineedit.c@1.8 +29 -32 + [Bug 1479] Compilation fails because of not finding readline headers. + + m4/ntp_lineeditlibs.m4@1.7 +0 -2 + [Bug 1479] Compilation fails because of not finding readline headers. + + ntpd/ntp_control.c@1.129.1.3 +1 -0 + [Bug 1478] linking fails with undefined reference EVP_MD_pkey_type. + +ChangeSet@1.2102, 2010-02-07 10:31:29+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P18 + TAG: NTP_4_2_7P18 + + ChangeLog@1.533 +1 -0 + NTP_4_2_7P18 + + ntpd/ntpd-opts.c@1.19 +2 -2 + NTP_4_2_7P18 + + ntpd/ntpd-opts.h@1.19 +3 -3 + NTP_4_2_7P18 + + ntpd/ntpd-opts.texi@1.19 +2 -2 + NTP_4_2_7P18 + + ntpd/ntpd.1@1.19 +2 -2 + NTP_4_2_7P18 + + ntpdc/ntpdc-opts.c@1.19 +2 -2 + NTP_4_2_7P18 + + ntpdc/ntpdc-opts.h@1.19 +3 -3 + NTP_4_2_7P18 + + ntpdc/ntpdc-opts.texi@1.19 +2 -2 + NTP_4_2_7P18 + + ntpdc/ntpdc.1@1.19 +2 -2 + NTP_4_2_7P18 + + ntpq/ntpq-opts.c@1.19 +2 -2 + NTP_4_2_7P18 + + ntpq/ntpq-opts.h@1.19 +3 -3 + NTP_4_2_7P18 + + ntpq/ntpq-opts.texi@1.19 +2 -2 + NTP_4_2_7P18 + + ntpq/ntpq.1@1.19 +2 -2 + NTP_4_2_7P18 + + ntpsnmpd/ntpsnmpd-opts.c@1.19 +2 -2 + NTP_4_2_7P18 + + ntpsnmpd/ntpsnmpd-opts.h@1.19 +3 -3 + NTP_4_2_7P18 + + ntpsnmpd/ntpsnmpd-opts.texi@1.19 +2 -2 + NTP_4_2_7P18 + + ntpsnmpd/ntpsnmpd.1@1.19 +2 -2 + NTP_4_2_7P18 + + packageinfo.sh@1.20 +1 -1 + NTP_4_2_7P18 + + sntp/sntp-opts.c@1.19 +2 -2 + NTP_4_2_7P18 + + sntp/sntp-opts.h@1.19 +3 -3 + NTP_4_2_7P18 + + sntp/sntp-opts.texi@1.19 +2 -2 + NTP_4_2_7P18 + + sntp/sntp.1@1.19 +2 -2 + NTP_4_2_7P18 + + sntp/sntp.html@1.19 +1 -1 + NTP_4_2_7P18 + + util/ntp-keygen-opts.c@1.19 +2 -2 + NTP_4_2_7P18 + + util/ntp-keygen-opts.h@1.19 +3 -3 + NTP_4_2_7P18 + + util/ntp-keygen-opts.texi@1.19 +2 -2 + NTP_4_2_7P18 + + util/ntp-keygen.1@1.19 +2 -2 + NTP_4_2_7P18 + +ChangeSet@1.2101, 2010-02-06 05:22:44+00:00, davehart@shiny.ad.hartbrothers.com + Stop using getaddrinfo() to convert numeric address strings to on-wire + addresses in favor of is_ip_address() alone. + + ChangeLog@1.532 +2 -0 + Stop using getaddrinfo() to convert numeric address strings to on-wire + addresses in favor of is_ip_address() alone. + + include/ntp_rfc2553.h@1.35 +10 -1 + add copy_addrinfo_list() + + include/ntpd.h@1.137.1.3 +15 -6 + mention copy_addrinfo_list() near getaddrinfo_sometime() prototype. + + libntp/ntp_rfc2553.c@1.42 +92 -0 + add copy_addrinfo_list() + + ntpd/ntp_config.c@1.246 +18 -116 + Stop using getaddrinfo() to convert numeric address strings to on-wire + addresses in favor of is_ip_address() alone. + + ntpd/ntp_intres.c@1.83 +10 -1 + add DEBUG code to exercise copy_addrinfo_list() harmlessly + +ChangeSet@1.2082.4.58, 2010-02-05 22:26:34+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. + + ChangeLog@1.496.26.39 +1 -0 + [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. + + ntpd/ntp_control.c@1.129.1.2 +1 -1 + [Bug 1480] snprintf() cleanup caused unterminated refclock IDs. + +ChangeSet@1.2099, 2010-02-05 10:31:56+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P17 + TAG: NTP_4_2_7P17 + + ChangeLog@1.530 +1 -0 + NTP_4_2_7P17 + + ntpd/ntpd-opts.c@1.18 +2 -2 + NTP_4_2_7P17 + + ntpd/ntpd-opts.h@1.18 +3 -3 + NTP_4_2_7P17 + + ntpd/ntpd-opts.texi@1.18 +2 -2 + NTP_4_2_7P17 + + ntpd/ntpd.1@1.18 +2 -2 + NTP_4_2_7P17 + + ntpdc/ntpdc-opts.c@1.18 +2 -2 + NTP_4_2_7P17 + + ntpdc/ntpdc-opts.h@1.18 +3 -3 + NTP_4_2_7P17 + + ntpdc/ntpdc-opts.texi@1.18 +2 -2 + NTP_4_2_7P17 + + ntpdc/ntpdc.1@1.18 +2 -2 + NTP_4_2_7P17 + + ntpq/ntpq-opts.c@1.18 +2 -2 + NTP_4_2_7P17 + + ntpq/ntpq-opts.h@1.18 +3 -3 + NTP_4_2_7P17 + + ntpq/ntpq-opts.texi@1.18 +2 -2 + NTP_4_2_7P17 + + ntpq/ntpq.1@1.18 +2 -2 + NTP_4_2_7P17 + + ntpsnmpd/ntpsnmpd-opts.c@1.18 +2 -2 + NTP_4_2_7P17 + + ntpsnmpd/ntpsnmpd-opts.h@1.18 +3 -3 + NTP_4_2_7P17 + + ntpsnmpd/ntpsnmpd-opts.texi@1.18 +2 -2 + NTP_4_2_7P17 + + ntpsnmpd/ntpsnmpd.1@1.18 +2 -2 + NTP_4_2_7P17 + + packageinfo.sh@1.19 +1 -1 + NTP_4_2_7P17 + + sntp/sntp-opts.c@1.18 +2 -2 + NTP_4_2_7P17 + + sntp/sntp-opts.h@1.18 +3 -3 + NTP_4_2_7P17 + + sntp/sntp-opts.texi@1.18 +2 -2 + NTP_4_2_7P17 + + sntp/sntp.1@1.18 +2 -2 + NTP_4_2_7P17 + + sntp/sntp.html@1.18 +1 -1 + NTP_4_2_7P17 + + util/ntp-keygen-opts.c@1.18 +2 -2 + NTP_4_2_7P17 + + util/ntp-keygen-opts.h@1.18 +3 -3 + NTP_4_2_7P17 + + util/ntp-keygen-opts.texi@1.18 +2 -2 + NTP_4_2_7P17 + + util/ntp-keygen.1@1.18 +2 -2 + NTP_4_2_7P17 + +ChangeSet@1.2096.1.1, 2010-02-05 05:07:21+00:00, davehart@shiny.ad.hartbrothers.com + Attempts to cure CID 108 CID 118 CID 119 TAINTED_SCALAR warnings. + Broaden ylwrap workaround VPATH_HACK to all non-GNU make. + + ChangeLog@1.527.1.1 +6 -0 + Attempts to cure CID 108 CID 118 CID 119 TAINTED_SCALAR warnings. + Broaden ylwrap workaround VPATH_HACK to all non-GNU make. + + include/ntp_debug.h@1.3 +2 -0 + include ntp_assert.h so source files can include one less .h + + m4/ntp_vpathhack.m4@1.3 +25 -11 + ABroaden ylwrap workaround VPATH_HACK to all non-GNU make. + + ntpd/Makefile.am@1.90 +3 -3 + use $(srcdir)/ prefix for ntpd-opts.[ch] in BS_DIST + + ntpd/ntp_scanner.c@1.32 +13 -6 + Attempt to cure CID 108 TAINTED_SCALAR warning. + + ntpd/work_fork.c@1.2 +10 -2 + Attempts to cure CID 118 CID 119 TAINTED_SCALAR warnings. + +ChangeSet@1.2082.4.57, 2010-02-04 23:13:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. + + ChangeLog@1.496.26.38 +4 -0 + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. + + Makefile.am@1.93 +3 -3 + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. + + sntp/Makefile.am@1.21.1.7 +3 -3 + [Bug 1477] 1st non-gmake make in clone w/VPATH can't make COPYRIGHT. + +ChangeSet@1.2096, 2010-02-04 10:32:08+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P16 + TAG: NTP_4_2_7P16 + + ChangeLog@1.527 +1 -0 + NTP_4_2_7P16 + + ntpd/ntpd-opts.c@1.17 +2 -2 + NTP_4_2_7P16 + + ntpd/ntpd-opts.h@1.17 +3 -3 + NTP_4_2_7P16 + + ntpd/ntpd-opts.texi@1.17 +2 -2 + NTP_4_2_7P16 + + ntpd/ntpd.1@1.17 +2 -2 + NTP_4_2_7P16 + + ntpdc/ntpdc-opts.c@1.17 +2 -2 + NTP_4_2_7P16 + + ntpdc/ntpdc-opts.h@1.17 +3 -3 + NTP_4_2_7P16 + + ntpdc/ntpdc-opts.texi@1.17 +2 -2 + NTP_4_2_7P16 + + ntpdc/ntpdc.1@1.17 +2 -2 + NTP_4_2_7P16 + + ntpq/ntpq-opts.c@1.17 +2 -2 + NTP_4_2_7P16 + + ntpq/ntpq-opts.h@1.17 +3 -3 + NTP_4_2_7P16 + + ntpq/ntpq-opts.texi@1.17 +2 -2 + NTP_4_2_7P16 + + ntpq/ntpq.1@1.17 +2 -2 + NTP_4_2_7P16 + + ntpsnmpd/ntpsnmpd-opts.c@1.17 +2 -2 + NTP_4_2_7P16 + + ntpsnmpd/ntpsnmpd-opts.h@1.17 +3 -3 + NTP_4_2_7P16 + + ntpsnmpd/ntpsnmpd-opts.texi@1.17 +2 -2 + NTP_4_2_7P16 + + ntpsnmpd/ntpsnmpd.1@1.17 +2 -2 + NTP_4_2_7P16 + + packageinfo.sh@1.18 +1 -1 + NTP_4_2_7P16 + + sntp/sntp-opts.c@1.17 +2 -2 + NTP_4_2_7P16 + + sntp/sntp-opts.h@1.17 +3 -3 + NTP_4_2_7P16 + + sntp/sntp-opts.texi@1.17 +2 -2 + NTP_4_2_7P16 + + sntp/sntp.1@1.17 +2 -2 + NTP_4_2_7P16 + + sntp/sntp.html@1.17 +1 -1 + NTP_4_2_7P16 + + util/ntp-keygen-opts.c@1.17 +2 -2 + NTP_4_2_7P16 + + util/ntp-keygen-opts.h@1.17 +3 -3 + NTP_4_2_7P16 + + util/ntp-keygen-opts.texi@1.17 +2 -2 + NTP_4_2_7P16 + + util/ntp-keygen.1@1.17 +2 -2 + NTP_4_2_7P16 + +ChangeSet@1.2082.4.56, 2010-02-04 02:57:49-05:00, stenn@whimsy.udel.edu + NTP_4_2_6P1_RC4 + TAG: NTP_4_2_6P1_RC4 + + ChangeLog@1.496.26.37 +1 -0 + NTP_4_2_6P1_RC4 + + ntpd/ntpd-opts.c@1.248.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpd/ntpd-opts.h@1.248.4.1 +3 -3 + NTP_4_2_6P1_RC4 + + ntpd/ntpd-opts.texi@1.246.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpd/ntpd.1@1.246.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpdc/ntpdc-opts.c@1.244.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpdc/ntpdc-opts.h@1.244.4.1 +3 -3 + NTP_4_2_6P1_RC4 + + ntpdc/ntpdc-opts.texi@1.243.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpdc/ntpdc.1@1.243.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpq/ntpq-opts.c@1.245.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpq/ntpq-opts.h@1.245.4.1 +3 -3 + NTP_4_2_6P1_RC4 + + ntpq/ntpq-opts.texi@1.244.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpq/ntpq.1@1.244.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.4.1 +3 -3 + NTP_4_2_6P1_RC4 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + ntpsnmpd/ntpsnmpd.1@1.122.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + packageinfo.sh@1.255.6.1 +1 -1 + NTP_4_2_6P1_RC4 + + sntp/sntp-opts.c@1.117.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + sntp/sntp-opts.h@1.117.4.1 +3 -3 + NTP_4_2_6P1_RC4 + + sntp/sntp-opts.texi@1.117.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + sntp/sntp.1@1.117.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + sntp/sntp.html@1.7.4.1 +1 -1 + NTP_4_2_6P1_RC4 + + util/ntp-keygen-opts.c@1.247.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + util/ntp-keygen-opts.h@1.247.4.1 +3 -3 + NTP_4_2_6P1_RC4 + + util/ntp-keygen-opts.texi@1.246.4.1 +2 -2 + NTP_4_2_6P1_RC4 + + util/ntp-keygen.1@1.246.4.1 +2 -2 + NTP_4_2_6P1_RC4 + +ChangeSet@1.2082.4.55, 2010-02-04 03:01:42+00:00, hart@psp-fb1.ntp.org + Makefile.am: + fix make distdir before make all on FreeBSD make + + Makefile.am@1.92 +5 -5 + fix make distdir before make all on FreeBSD make + + sntp/Makefile.am@1.21.1.6 +26 -25 + fix make distdir before make all on FreeBSD make + +ChangeSet@1.2082.4.54, 2010-02-03 23:51:52+00:00, davehart@shiny.ad.hartbrothers.com + Remove arlib. + + BitKeeper/deleted/.del-COPYING~1e5c94deb8b25a03@1.3 +0 -0 + Rename: arlib/COPYING -> BitKeeper/deleted/.del-COPYING~1e5c94deb8b25a03 + + BitKeeper/deleted/.del-INSTALL~4c77da0d9f1f3464@1.2 +0 -0 + Rename: arlib/INSTALL -> BitKeeper/deleted/.del-INSTALL~4c77da0d9f1f3464 + + BitKeeper/deleted/.del-Makefile.am~501d14b0d06d3031@1.4 +0 -0 + Rename: arlib/Makefile.am -> BitKeeper/deleted/.del-Makefile.am~501d14b0d06d3031 + + BitKeeper/deleted/.del-README~4de4615d76ebba47@1.2 +0 -0 + Rename: arlib/README -> BitKeeper/deleted/.del-README~4de4615d76ebba47 + + BitKeeper/deleted/.del-UNSHAR.HDR~6aa2f933ef5d86df@1.2 +0 -0 + Rename: arlib/UNSHAR.HDR -> BitKeeper/deleted/.del-UNSHAR.HDR~6aa2f933ef5d86df + + BitKeeper/deleted/.del-arlib.3~11ae3dd9cdb6a32@1.2 +0 -0 + Rename: arlib/arlib.3 -> BitKeeper/deleted/.del-arlib.3~11ae3dd9cdb6a32 + + BitKeeper/deleted/.del-arlib.c~fdde50d6ab7b6f64@1.2 +0 -0 + Rename: arlib/arlib.c -> BitKeeper/deleted/.del-arlib.c~fdde50d6ab7b6f64 + + BitKeeper/deleted/.del-arlib.h~22218072d10baf8e@1.2 +0 -0 + Rename: arlib/arlib.h -> BitKeeper/deleted/.del-arlib.h~22218072d10baf8e + + BitKeeper/deleted/.del-arplib.h~8ccbd9af28d9aa3b@1.2 +0 -0 + Rename: arlib/arplib.h -> BitKeeper/deleted/.del-arplib.h~8ccbd9af28d9aa3b + + BitKeeper/deleted/.del-configure.in~282cad3ea077c564@1.4 +0 -0 + Rename: arlib/configure.in -> BitKeeper/deleted/.del-configure.in~282cad3ea077c564 + + BitKeeper/deleted/.del-sample.c~4c74b15f3881e611@1.2 +0 -0 + Rename: arlib/sample.c -> BitKeeper/deleted/.del-sample.c~4c74b15f3881e611 + + ChangeLog@1.496.26.36 +1 -0 + Remove arlib. + + Makefile.am@1.91 +1 -4 + Remove arlib. + + configure.ac@1.465.1.10 +7 -13 + Remove arlib, replace --with-arlib handling with deprecation warning. + +ChangeSet@1.2091, 2010-02-03 10:36:19+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P15 + TAG: NTP_4_2_7P15 + + ChangeLog@1.523 +1 -0 + NTP_4_2_7P15 + + ntpd/ntpd-opts.c@1.16 +2 -2 + NTP_4_2_7P15 + + ntpd/ntpd-opts.h@1.16 +3 -3 + NTP_4_2_7P15 + + ntpd/ntpd-opts.texi@1.16 +2 -2 + NTP_4_2_7P15 + + ntpd/ntpd.1@1.16 +2 -2 + NTP_4_2_7P15 + + ntpdc/ntpdc-opts.c@1.16 +2 -2 + NTP_4_2_7P15 + + ntpdc/ntpdc-opts.h@1.16 +3 -3 + NTP_4_2_7P15 + + ntpdc/ntpdc-opts.texi@1.16 +2 -2 + NTP_4_2_7P15 + + ntpdc/ntpdc.1@1.16 +2 -2 + NTP_4_2_7P15 + + ntpq/ntpq-opts.c@1.16 +2 -2 + NTP_4_2_7P15 + + ntpq/ntpq-opts.h@1.16 +3 -3 + NTP_4_2_7P15 + + ntpq/ntpq-opts.texi@1.16 +2 -2 + NTP_4_2_7P15 + + ntpq/ntpq.1@1.16 +2 -2 + NTP_4_2_7P15 + + ntpsnmpd/ntpsnmpd-opts.c@1.16 +2 -2 + NTP_4_2_7P15 + + ntpsnmpd/ntpsnmpd-opts.h@1.16 +3 -3 + NTP_4_2_7P15 + + ntpsnmpd/ntpsnmpd-opts.texi@1.16 +2 -2 + NTP_4_2_7P15 + + ntpsnmpd/ntpsnmpd.1@1.16 +2 -2 + NTP_4_2_7P15 + + packageinfo.sh@1.17 +1 -1 + NTP_4_2_7P15 + + sntp/sntp-opts.c@1.16 +2 -2 + NTP_4_2_7P15 + + sntp/sntp-opts.h@1.16 +3 -3 + NTP_4_2_7P15 + + sntp/sntp-opts.texi@1.16 +2 -2 + NTP_4_2_7P15 + + sntp/sntp.1@1.16 +2 -2 + NTP_4_2_7P15 + + sntp/sntp.html@1.16 +1 -1 + NTP_4_2_7P15 + + util/ntp-keygen-opts.c@1.16 +2 -2 + NTP_4_2_7P15 + + util/ntp-keygen-opts.h@1.16 +3 -3 + NTP_4_2_7P15 + + util/ntp-keygen-opts.texi@1.16 +2 -2 + NTP_4_2_7P15 + + util/ntp-keygen.1@1.16 +2 -2 + NTP_4_2_7P15 + +ChangeSet@1.2082.4.53, 2010-02-03 05:28:18-05:00, stenn@whimsy.udel.edu + [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a + + ChangeLog@1.496.26.35 +1 -0 + [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a + + util/Makefile.am@1.45.1.4 +1 -1 + [Bug 1474] ntp_keygen needs LCRYPTO after libntp.a + +ChangeSet@1.2082.4.52, 2010-02-03 04:58:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1455] ntpd does not try /etc/ntp.audio as documented. + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ChangeLog@1.496.26.34 +4 -0 + [Bug 1455] ntpd does not try /etc/ntp.audio as documented. + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + lib/isc/win32/interfaceiter.c@1.17 +11 -8 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + libntp/audio.c@1.27 +8 -5 + [Bug 1455] ntpd does not try /etc/ntp.audio as documented. + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + libntp/findconfig.c@1.3 +3 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + libntp/humandate.c@1.7.1.1 +7 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + libntp/modetoa.c@1.2.1.1 +2 -2 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + libntp/prettydate.c@1.12.1.1 +11 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + libntp/uglydate.c@1.3.1.1 +5 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + libntp/uinttoa.c@1.2.1.1 +1 -1 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/ntp_control.c@1.129.1.1 +35 -32 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_arbiter.c@1.15 +9 -9 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + ntpd/refclock_arc.c@1.22 +13 -7 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_as2201.c@1.11 +9 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_atom.c@1.61 +4 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_bancomm.c@1.12 +28 -21 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + + ntpd/refclock_chronolog.c@1.9 +10 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_chu.c@1.46 +44 -20 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_dumbclock.c@1.14 +10 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_gpsvme.c@1.8 +10 -11 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_heath.c@1.15 +6 -4 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + ntpd/refclock_hopfpci.c@1.11 +18 -26 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_hopfser.c@1.14 +13 -18 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_hpgps.c@1.10 +9 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_irig.c@1.32 +11 -11 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_jjy.c@1.18 +22 -22 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_jupiter.c@1.21.1.1 +6 -10 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_leitch.c@1.11 +12 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + call io_closeclock() on shutdown if io_addclock() succeeded. + + ntpd/refclock_msfees.c@1.13 +20 -13 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_mx4200.c@1.25 +11 -12 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_palisade.c@1.31.1.1 +11 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + ntpd/refclock_parse.c@1.52 +3 -3 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_pcf.c@1.10 +2 -2 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpd/refclock_pst.c@1.10 +9 -9 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_shm.c@1.21 +8 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_tpro.c@1.11 +12 -14 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_trak.c@1.9 +8 -9 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + Remove some dead code checking for emalloc() returning NULL. + + ntpd/refclock_wwvb.c@1.23 +10 -6 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + Fix widely cut-n-pasted bug in refclock shutdown after failed start. + + ntpq/ntpq-subs.c@1.39.2.1 +28 -22 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ntpq/ntpq.c@1.97.1.1 +23 -12 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + + ports/winnt/ntpd/hopf_PCI_io.c@1.7 +173 -136 + Convert many sprintf() calls to snprintf(), also strcpy(), strcat(). + clean up indent mess. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20.1.5 +6 -2 + add reference to libntp/audio.c + +ChangeSet@1.2089, 2010-02-02 10:34:20+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P14 + TAG: NTP_4_2_7P14 + + ChangeLog@1.521 +1 -0 + NTP_4_2_7P14 + + ntpd/ntpd-opts.c@1.15 +2 -2 + NTP_4_2_7P14 + + ntpd/ntpd-opts.h@1.15 +3 -3 + NTP_4_2_7P14 + + ntpd/ntpd-opts.texi@1.15 +2 -2 + NTP_4_2_7P14 + + ntpd/ntpd.1@1.15 +2 -2 + NTP_4_2_7P14 + + ntpdc/ntpdc-opts.c@1.15 +2 -2 + NTP_4_2_7P14 + + ntpdc/ntpdc-opts.h@1.15 +3 -3 + NTP_4_2_7P14 + + ntpdc/ntpdc-opts.texi@1.15 +2 -2 + NTP_4_2_7P14 + + ntpdc/ntpdc.1@1.15 +2 -2 + NTP_4_2_7P14 + + ntpq/ntpq-opts.c@1.15 +2 -2 + NTP_4_2_7P14 + + ntpq/ntpq-opts.h@1.15 +3 -3 + NTP_4_2_7P14 + + ntpq/ntpq-opts.texi@1.15 +2 -2 + NTP_4_2_7P14 + + ntpq/ntpq.1@1.15 +2 -2 + NTP_4_2_7P14 + + ntpsnmpd/ntpsnmpd-opts.c@1.15 +2 -2 + NTP_4_2_7P14 + + ntpsnmpd/ntpsnmpd-opts.h@1.15 +3 -3 + NTP_4_2_7P14 + + ntpsnmpd/ntpsnmpd-opts.texi@1.15 +2 -2 + NTP_4_2_7P14 + + ntpsnmpd/ntpsnmpd.1@1.15 +2 -2 + NTP_4_2_7P14 + + packageinfo.sh@1.16 +1 -1 + NTP_4_2_7P14 + + sntp/sntp-opts.c@1.15 +2 -2 + NTP_4_2_7P14 + + sntp/sntp-opts.h@1.15 +3 -3 + NTP_4_2_7P14 + + sntp/sntp-opts.texi@1.15 +2 -2 + NTP_4_2_7P14 + + sntp/sntp.1@1.15 +2 -2 + NTP_4_2_7P14 + + sntp/sntp.html@1.15 +1 -1 + NTP_4_2_7P14 + + util/ntp-keygen-opts.c@1.15 +2 -2 + NTP_4_2_7P14 + + util/ntp-keygen-opts.h@1.15 +3 -3 + NTP_4_2_7P14 + + util/ntp-keygen-opts.texi@1.15 +2 -2 + NTP_4_2_7P14 + + util/ntp-keygen.1@1.15 +2 -2 + NTP_4_2_7P14 + +ChangeSet@1.2084.1.40, 2010-02-02 04:18:56-05:00, stenn@pogo.udel.edu + cleanup + + configure.ac@1.477 +0 -1 + cleanup + +ChangeSet@1.2084.1.37, 2010-02-02 08:28:17+00:00, stenn@poog.il.thewrittenword.com + [Bug 1469] more int32 cleanup + + configure.ac@1.476 +1 -1 + [Bug 1469] more int32 cleanup + + include/ntp_types.h@1.18 +4 -3 + [Bug 1469] more int32 cleanup + +ChangeSet@1.2082.4.51, 2010-02-02 08:09:04+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1473] "make distcheck" before build can't make sntp/version.m4. + + ChangeLog@1.496.26.33 +1 -0 + [Bug 1473] "make distcheck" before build can't make sntp/version.m4. + + Makefile.am@1.90 +12 -1 + add COPYRIGHT-please target for use by sntp/Makefile.am + minor tweak to COPYRIGHT action to create intermediate file in + build dir not $(srcdir) to minimize parallel VPATH makes + interfering with each other. + add do-nothing action for rule lacking one to avoid any use + of SCCS get default. + + sntp/Makefile.am@1.21.1.5 +34 -5 + [Bug 1473] "make distcheck" before build can't make sntp/version.m4. + add targets for autogen-version.def, version.def, version.m4, and + version.texi which invoke a submake on the corresponding check-* + targets, avoiding an explicit dependency which would cause Autogen + to be invoked to make sntp-opts.h, which would be considered out- + of-date because version.def is, and version,def because it depends + on non-existent check-version.def. The submake ensures the check + action is taken without introducing the troublesome dependency. + use "cd .. && $(MAKE) COPYRIGHT-please" to work around quirk with + FreeBSD 6.x make which fails with "make COPYRIGHT" when + "make ./COPYRIGHT" would work. + +ChangeSet@1.2082.4.50, 2010-02-02 01:29:56+00:00, davehart@shiny.ad.hartbrothers.com + Makefile.am: + keyword-gen-utd is intended to have one line of content. + + ntpd/Makefile.am@1.80.1.7 +1 -1 + keyword-gen-utd is intended to have one line of content. + +ChangeSet@1.2084.14.1, 2010-02-01 18:15:31+00:00, davehart@shiny.ad.hartbrothers.com + ntp_data_structures.h: + ensure size_t is available by including stddef.h + + include/ntp_data_structures.h@1.7 +1 -0 + ensure size_t is available by including stddef.h + +ChangeSet@1.2084.13.5, 2010-02-01 04:40:15+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1471] CID 120 CID 121 CID 122 is_ip_address() uninit family. + [Bug 1472] CID 116 CID 117 minor warnings in new DNS code. + + ChangeLog@1.513.1.5 +2 -0 + [Bug 1471] CID 120 CID 121 CID 122 is_ip_address() uninit family. + [Bug 1472] CID 116 CID 117 minor warnings in new DNS code. + + include/ntp_io.h@1.15 +1 -1 + [Bug 1471] CID 120 CID 121 CID 122 is_ip_address() uninit family. + [Bug 1472] CID 116 CID 117 minor warnings in new DNS code. + + ntpd/ntp_config.c@1.245 +7 -9 + [Bug 1471] CID 120 CID 121 CID 122 is_ip_address() uninit family. + + ntpd/ntp_intres.c@1.80.1.1 +4 -1 + [Bug 1472] CID 116 CID 117 minor warnings in new DNS code. + + ntpd/ntp_io.c@1.312 +5 -3 + [Bug 1471] CID 120 CID 121 CID 122 is_ip_address() uninit family. + + ntpd/ntpd.c@1.110.1.4 +7 -4 + [Bug 1471] CID 120 CID 121 CID 122 is_ip_address() uninit family. + [Bug 1472] CID 116 CID 117 minor warnings in new DNS code. + +ChangeSet@1.2082.4.49, 2010-02-01 01:56:41+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. + + ChangeLog@1.496.26.32 +1 -0 + [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. + + bootstrap@1.28.1.3 +5 -6 + add ntpd/keyword-gen.out to touch targets, at same time as ntp_parser.h. + + ntpd/Makefile.am@1.80.1.6 +41 -26 + [Bug 1470] "make distdir" in $srcdir builds keyword-gen, libntp.a. + Avoid building keyword-gen if its output is up-to-date in general. + + ntpd/keyword-gen-utd@1.1 +1 -0 + intermediate Makefile target used in avoiding building keyword-gen + after bootstrap or from tarball unless sources change, necessary + to ensure "make distdir" can succeed before compiling without + compiling. See [Bug 1470]. + + ntpd/keyword-gen-utd@1.0 +0 -0 + +ChangeSet@1.2084.13.4, 2010-01-31 10:32:07+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P13 + TAG: NTP_4_2_7P13 + + ChangeLog@1.513.1.4 +1 -0 + NTP_4_2_7P13 + + ntpd/ntpd-opts.c@1.14 +2 -2 + NTP_4_2_7P13 + + ntpd/ntpd-opts.h@1.14 +3 -3 + NTP_4_2_7P13 + + ntpd/ntpd-opts.texi@1.14 +2 -2 + NTP_4_2_7P13 + + ntpd/ntpd.1@1.14 +2 -2 + NTP_4_2_7P13 + + ntpdc/ntpdc-opts.c@1.14 +2 -2 + NTP_4_2_7P13 + + ntpdc/ntpdc-opts.h@1.14 +3 -3 + NTP_4_2_7P13 + + ntpdc/ntpdc-opts.texi@1.14 +2 -2 + NTP_4_2_7P13 + + ntpdc/ntpdc.1@1.14 +2 -2 + NTP_4_2_7P13 + + ntpq/ntpq-opts.c@1.14 +2 -2 + NTP_4_2_7P13 + + ntpq/ntpq-opts.h@1.14 +3 -3 + NTP_4_2_7P13 + + ntpq/ntpq-opts.texi@1.14 +2 -2 + NTP_4_2_7P13 + + ntpq/ntpq.1@1.14 +2 -2 + NTP_4_2_7P13 + + ntpsnmpd/ntpsnmpd-opts.c@1.14 +2 -2 + NTP_4_2_7P13 + + ntpsnmpd/ntpsnmpd-opts.h@1.14 +3 -3 + NTP_4_2_7P13 + + ntpsnmpd/ntpsnmpd-opts.texi@1.14 +2 -2 + NTP_4_2_7P13 + + ntpsnmpd/ntpsnmpd.1@1.14 +2 -2 + NTP_4_2_7P13 + + packageinfo.sh@1.15 +1 -1 + NTP_4_2_7P13 + + sntp/sntp-opts.c@1.14 +2 -2 + NTP_4_2_7P13 + + sntp/sntp-opts.h@1.14 +3 -3 + NTP_4_2_7P13 + + sntp/sntp-opts.texi@1.14 +2 -2 + NTP_4_2_7P13 + + sntp/sntp.1@1.14 +2 -2 + NTP_4_2_7P13 + + sntp/sntp.html@1.14 +1 -1 + NTP_4_2_7P13 + + util/ntp-keygen-opts.c@1.14 +2 -2 + NTP_4_2_7P13 + + util/ntp-keygen-opts.h@1.14 +3 -3 + NTP_4_2_7P13 + + util/ntp-keygen-opts.texi@1.14 +2 -2 + NTP_4_2_7P13 + + util/ntp-keygen.1@1.14 +2 -2 + NTP_4_2_7P13 + +ChangeSet@1.2084.13.3, 2010-01-31 02:18:32-05:00, stenn@whimsy.udel.edu + cleanup + + ChangeLog@1.513.1.3 +1 -1 + cleanup + +ChangeSet@1.2082.4.48, 2010-01-30 18:06:35-05:00, stenn@whimsy.udel.edu + [Bug 1467] Fix bogus rebuild of sntp/sntp.html + + ChangeLog@1.496.26.31 +4 -0 + [Bug 1467] Fix bogus rebuild of sntp/sntp.html + + bootstrap@1.28.1.2 +1 -1 + [Bug 1467] Fix bogus rebuild of sntp/sntp.html + +ChangeSet@1.2084.13.2, 2010-01-30 18:02:25-05:00, stenn@whimsy.udel.edu + [Bug 1467] Fix bogus rebuild of sntp/sntp.html + + ChangeLog@1.513.1.2 +1 -0 + [Bug 1467] Fix bogus rebuild of sntp/sntp.html + + bootstrap@1.31 +1 -1 + [Bug 1467] Fix bogus rebuild of sntp/sntp.html + +ChangeSet@1.2084.1.35, 2010-01-30 22:35:13+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + reword to better fit with surrounding messages + + configure.ac@1.475 +2 -2 + reword to better fit with surrounding messages + +ChangeSet@1.2084.1.34, 2010-01-30 22:28:30+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + attempt to properly quote all args to AC_LANG_PROGRAM() + + configure.ac@1.474 +39 -39 + attempt to properly quote all args to AC_LANG_PROGRAM() + +ChangeSet@1.2084.1.33, 2010-01-30 22:16:54+00:00, davehart@shiny.ad.hartbrothers.com + check for int32, u_int32 before testing result. + + configure.ac@1.473 +3 -1 + check for int32, u_int32 before testing result. + +ChangeSet@1.2084.1.32, 2010-01-30 17:53:03+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + + ChangeLog@1.516 +1 -1 + [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + + configure.ac@1.472 +56 -22 + [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + + include/ntp_types.h@1.17 +11 -7 + [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + + ntpd/ntp_intres.c@1.81 +6 -0 + [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + +ChangeSet@1.2084.13.1, 2010-01-30 10:31:55+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P12 + TAG: NTP_4_2_7P12 + + ChangeLog@1.513.1.1 +1 -0 + NTP_4_2_7P12 + + ntpd/ntpd-opts.c@1.13 +2 -2 + NTP_4_2_7P12 + + ntpd/ntpd-opts.h@1.13 +3 -3 + NTP_4_2_7P12 + + ntpd/ntpd-opts.texi@1.13 +2 -2 + NTP_4_2_7P12 + + ntpd/ntpd.1@1.13 +2 -2 + NTP_4_2_7P12 + + ntpdc/ntpdc-opts.c@1.13 +2 -2 + NTP_4_2_7P12 + + ntpdc/ntpdc-opts.h@1.13 +3 -3 + NTP_4_2_7P12 + + ntpdc/ntpdc-opts.texi@1.13 +2 -2 + NTP_4_2_7P12 + + ntpdc/ntpdc.1@1.13 +2 -2 + NTP_4_2_7P12 + + ntpq/ntpq-opts.c@1.13 +2 -2 + NTP_4_2_7P12 + + ntpq/ntpq-opts.h@1.13 +3 -3 + NTP_4_2_7P12 + + ntpq/ntpq-opts.texi@1.13 +2 -2 + NTP_4_2_7P12 + + ntpq/ntpq.1@1.13 +2 -2 + NTP_4_2_7P12 + + ntpsnmpd/ntpsnmpd-opts.c@1.13 +2 -2 + NTP_4_2_7P12 + + ntpsnmpd/ntpsnmpd-opts.h@1.13 +3 -3 + NTP_4_2_7P12 + + ntpsnmpd/ntpsnmpd-opts.texi@1.13 +2 -2 + NTP_4_2_7P12 + + ntpsnmpd/ntpsnmpd.1@1.13 +2 -2 + NTP_4_2_7P12 + + packageinfo.sh@1.14 +1 -1 + NTP_4_2_7P12 + + sntp/sntp-opts.c@1.13 +2 -2 + NTP_4_2_7P12 + + sntp/sntp-opts.h@1.13 +3 -3 + NTP_4_2_7P12 + + sntp/sntp-opts.texi@1.13 +2 -2 + NTP_4_2_7P12 + + sntp/sntp.1@1.13 +2 -2 + NTP_4_2_7P12 + + sntp/sntp.html@1.13 +1 -1 + NTP_4_2_7P12 + + util/ntp-keygen-opts.c@1.13 +2 -2 + NTP_4_2_7P12 + + util/ntp-keygen-opts.h@1.13 +3 -3 + NTP_4_2_7P12 + + util/ntp-keygen-opts.texi@1.13 +2 -2 + NTP_4_2_7P12 + + util/ntp-keygen.1@1.13 +2 -2 + NTP_4_2_7P12 + +ChangeSet@1.2084.1.30, 2010-01-30 06:26:12+00:00, davehart@shiny.ad.hartbrothers.com + * [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + + ChangeLog@1.514 +1 -0 + * [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + + include/ntp_types.h@1.16 +8 -6 + * [Bug 1469] u_int32, int32 changes broke HP-UX 10.20 build. + +ChangeSet@1.2084.1.29, 2010-01-29 20:11:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1468] 'make install' broken for root on default NFS mount. + + ChangeLog@1.513 +3 -0 + * [Bug 1468] 'make install' broken for root on default NFS mount. + Add a more explicit note to 4.2.7p11 section about new DNS code. + + libparse/Makefile.am@1.20 +21 -37 + [Bug 1468] 'make install' broken for root on default NFS mount. + Ensure workaround to clean any stale $(builddir)/info_trimble.c + completes its work in "make all" so it does not fire during + "make install" where creating files in $(builddir) may not be + possible, such as root on a default NFS-mounted directory. + +ChangeSet@1.2084.1.28, 2010-01-28 10:35:48+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P11 + TAG: NTP_4_2_7P11 + + ChangeLog@1.512 +1 -0 + NTP_4_2_7P11 + + ntpd/ntpd-opts.c@1.12 +2 -2 + NTP_4_2_7P11 + + ntpd/ntpd-opts.h@1.12 +3 -3 + NTP_4_2_7P11 + + ntpd/ntpd-opts.texi@1.12 +2 -2 + NTP_4_2_7P11 + + ntpd/ntpd.1@1.12 +2 -2 + NTP_4_2_7P11 + + ntpdc/ntpdc-opts.c@1.12 +2 -2 + NTP_4_2_7P11 + + ntpdc/ntpdc-opts.h@1.12 +3 -3 + NTP_4_2_7P11 + + ntpdc/ntpdc-opts.texi@1.12 +2 -2 + NTP_4_2_7P11 + + ntpdc/ntpdc.1@1.12 +2 -2 + NTP_4_2_7P11 + + ntpq/ntpq-opts.c@1.12 +2 -2 + NTP_4_2_7P11 + + ntpq/ntpq-opts.h@1.12 +3 -3 + NTP_4_2_7P11 + + ntpq/ntpq-opts.texi@1.12 +2 -2 + NTP_4_2_7P11 + + ntpq/ntpq.1@1.12 +2 -2 + NTP_4_2_7P11 + + ntpsnmpd/ntpsnmpd-opts.c@1.12 +2 -2 + NTP_4_2_7P11 + + ntpsnmpd/ntpsnmpd-opts.h@1.12 +3 -3 + NTP_4_2_7P11 + + ntpsnmpd/ntpsnmpd-opts.texi@1.12 +2 -2 + NTP_4_2_7P11 + + ntpsnmpd/ntpsnmpd.1@1.12 +2 -2 + NTP_4_2_7P11 + + packageinfo.sh@1.13 +1 -1 + NTP_4_2_7P11 + + sntp/sntp-opts.c@1.12 +2 -2 + NTP_4_2_7P11 + + sntp/sntp-opts.h@1.12 +3 -3 + NTP_4_2_7P11 + + sntp/sntp-opts.texi@1.12 +2 -2 + NTP_4_2_7P11 + + sntp/sntp.1@1.12 +2 -2 + NTP_4_2_7P11 + + sntp/sntp.html@1.12 +1 -1 + NTP_4_2_7P11 + + util/ntp-keygen-opts.c@1.12 +2 -2 + NTP_4_2_7P11 + + util/ntp-keygen-opts.h@1.12 +3 -3 + NTP_4_2_7P11 + + util/ntp-keygen-opts.texi@1.12 +2 -2 + NTP_4_2_7P11 + + util/ntp-keygen.1@1.12 +2 -2 + NTP_4_2_7P11 + +ChangeSet@1.2084.1.27, 2010-01-27 21:16:20+00:00, davehart@shiny.ad.hartbrothers.com + convert leftover debugging msyslog() to DPRINTF() + "attempting to open log %s" + + ntpd/ntpd.c@1.110.1.3 +1 -1 + convert leftover debugging msyslog() to DPRINTF() + "attempting to open log %s" + +ChangeSet@1.2084.1.26, 2010-01-27 20:21:24+00:00, davehart@shiny.ad.hartbrothers.com + Fix libparse build in $(srcdir) + + libparse/Makefile.am@1.19 +1 -1 + Fix libparse build in $(srcdir) + +ChangeSet@1.2084.1.25, 2010-01-27 18:45:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 47] Debugging and logging do not work after a fork. + [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. + #include from all .c files and do not include it + from any .h files. Previously config.h appeared a dozen times in + preprocessed output of some .c files. + handle relative path to logfile correctly despite re-opening + after fork() with a different curdir. + eliminate hand-crafted byte-swapping code from refclock_palisade.c in + preference to using htonl(), htons(). Tested by Fernando Hauscarriaga. + + + BitKeeper/etc/ignore@1.75 +4 -2 + add *.vcproj.*.user + correct .buildkey to .buildkey-* to reflect changed build script, + add .flockbuild-* along the same lines. + tell BK to not attempt any operations in A.*/ dirs via -prune, + particularly handy when there's a broken make dist distdir, + which may contain copies of BK metadata (s.* files). + + ChangeLog@1.511 +3 -0 + [Bug 47] Debugging and logging do not work after a fork. + [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. + + configure.ac@1.471 +18 -18 + add AC_FUNC_ALLOCA (used by ntp_malloc.h, ntp_intres.c). + add AC_CHECK_FUNCS(closefrom) + remove AC_CHECK_FUNCS(timer_settime) which is redundant with + AC_CHECK_FUNCS(timer_create). + add AC_CHECK_FUNCS(_exit) + remove --enable-force-defer-DNS switch to configure, as the intres + path is always taken now. + + include/Makefile.am@1.39 +2 -0 + add ntp_worker.h, ntp_workimpl.h + + include/iosignal.h@1.5 +36 -8 + Move USE_SIGIO/USE_SIGPOLL definition from iosignal.c to share with + ntpd/work_fork.c. + Stay out of system/compiler underscore-prefixed namespace. + + include/l_stdlib.h@1.18 +4 -8 + #include from all .c files and do not include it + from any .h files. + Stay out of system/compiler underscore-prefixed namespace. + + include/ntp_data_structures.h@1.6 +39 -13 + Preserve callsite __FILE__ and __LINE__ for create_priority_queue() + and get_node() for heap leak detection when available. + Stay out of system/compiler underscore-prefixed namespace. + + include/ntp_fp.h@1.16 +2 -2 + whitespace cleanup (spaces -> tabs) + + include/ntp_intres.h@1.3 +19 -10 + repurpose ntp_intres.h, which used to solely be responsible for + defining NO_INTRES if needed. Now ntp_workimpl.h handles the + declaration of the opposite-sense WORKER as needed, and + ntp_intres.h is an internal header for intres declarations + used by ntp_worker.c and ntp_intres.c. + + include/ntp_io.h@1.14 +13 -7 + #include from all .c files and do not include it + from any .h files. + Add close_all_beyond() and update_resp_pipe_fd() declarations. + + include/ntp_lists.h@1.2 +0 -4 + #include from all .c files and do not include it + from any .h files. + + include/ntp_machine.h@1.26.1.1 +6 -170 + #include from all .c files and do not include it + from any .h files. + Remove huge blob of #if 0 code from pre-Autoconf days, our + transition to handling most platform differences via + configure is long past. + + include/ntp_malloc.h@1.4 +29 -4 + #include from all .c files and do not include it + from any .h files. + Handle platform differences with alloca() + + include/ntp_proto.h@1.4.1.1 +3 -7 + #include from all .c files and do not include it + from any .h files. + Stay out of system/compiler underscore-prefixed namespace. + + include/ntp_rfc2553.h@1.34 +0 -5 + #include from all .c files and do not include it + from any .h files. + + include/ntp_select.h@1.5 +16 -21 + whitespace (indent preprocessor directives) + + include/ntp_stdlib.h@1.41 +1 -1 + add humantime() declaration (libntp/humandate.c) + remove superfluous #include "ntp_rfc2553.h" + + include/ntp_string.h@1.5 +3 -7 + #include from all .c files and do not include it + from any .h files. + Stay out of system/compiler underscore-prefixed namespace. + + include/ntp_syscall.h@1.9 +0 -4 + #include from all .c files and do not include it + from any .h files. + + include/ntp_syslog.h@1.4 +11 -9 + handle relative path to logfile correctly despite re-opening + after fork() with a different curdir. + + include/ntp_types.h@1.15 +8 -8 + Use typedef instead of #define to declare int32, u_int32. + + include/ntp_worker.h@1.1 +52 -0 + worker internals used by ntp_worker.c, work_fork.c, work_thread.c, + and ntp_intres.c. + + include/ntp_worker.h@1.0 +0 -0 + + include/ntp_workimpl.h@1.1 +25 -0 + defines WORKER, WORK_FORK, and WORK_THREAD as appropriate (chooses + implementation to use). + + include/ntp_workimpl.h@1.0 +0 -0 + + include/ntpd.h@1.137.1.2 +72 -42 + handle relative path to logfile correctly despite re-opening + after fork() with a different curdir. + remove declarations from old ntp_intres.c implementation, add + declarations for new ntp_intres.c, ntp_worker.c, work_fork.c, + and work_thread.c. + Correct a few misplaces variable and function declarations. ntpd.h + declares all the functions from various files first, then all + the variables, so there are two spots for declarations for each + source file. + + include/recvbuff.h@1.20 +1 -5 + #include from all .c files and do not include it + from any .h files. + + libntp/atoint.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/atolfp.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/atouint.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/authusekey.c@1.8 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/caljulian.c@1.12 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/caltontp.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/calyearstart.c@1.5 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/clocktime.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/clocktypes.c@1.19 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/dofptoa.c@1.7 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/dolfptoa.c@1.7 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/emalloc.c@1.11 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/fptoa.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/fptoms.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/getopt.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/hextoint.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/hextolfp.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/humandate.c@1.8 +33 -6 + sprintf() -> snprintf() + add humantime() used by ntp_intres.c DPRINTF() calls. + #include from all .c files and do not include it + from any .h files. + + libntp/icom.c@1.12 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/iosignal.c@1.15 +0 -28 + Move USE_SIGIO/USE_SIGPOLL definition to iosignal.h to share with + ntpd/work_fork.c. + + libntp/mfptoa.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/mfptoms.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/mktime.c@1.9 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/modetoa.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/mstolfp.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/msutotsf.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/msyslog.c@1.25 +40 -38 + handle relative path to logfile correctly despite re-opening + after fork() with a different curdir. + mimic syslog() behavior adding a trailing \n if not present + when logging to a file. + + libntp/netof.c@1.8 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/octtoint.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/prettydate.c@1.13 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/refnumtoa.c@1.8 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/socktohost.c@1.8 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/strdup.c@1.6 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/syssignal.c@1.10 +40 -51 + Do not msyslog(LOG_DEBUG) about signal flags simply because SA_SIGINFO + flag bit is set. + Define SIG_ERR, Z_SA_RESTART, Z_SA_SIGINFO to reduce #ifdef nesting. + + libntp/systime.c@1.49 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/tsftomsu.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/tstotv.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/tvtots.c@1.3 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/uglydate.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libntp/uinttoa.c@1.3 +2 -1 + sprintf() -> snprintf() + #include from all .c files and do not include it + from any .h files. + + libntp/ymd2yd.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libparse/Makefile.am@1.18 +61 -69 + Correct generation of info_trimble.c to create it in $(srcdir) + instead of $(builddir) + Add temporary workaround to avoid breaking existing build trees + with this change, which aggressively removes info_trimble.c + from $(builddir) where it tends to have precedence. + Correct k*.o rule dependencies to use $(srcdir)/ prefix. + Remove ansi2knr crud (such as kclk_computime_.o: clk_computime_.c + rule). + Correct workaround which generates local sys/systm.h to be able + to work more than once by not breaking if sys/ subdir exists. + + libparse/binio.c@1.7 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libparse/data_mbg.c@1.10 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libparse/gpstolfp.c@1.10 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libparse/info_trimble.c@1.5 +1 -1 + #include from all .c files and do not include it + from any .h files. + (produced by updated mkinfo_rcmd.sed and mkinfo_scmd.sed) + + libparse/mfp_mul.c@1.8 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libparse/mkinfo_rcmd.sed@1.3 +4 -4 + produce the same output using FreeBSD or GNU sed + + libparse/mkinfo_scmd.sed@1.3 +5 -6 + produce the same output using FreeBSD or GNU sed. + #include from all .c files and do not include it + from any .h files. + + libparse/parsesolaris.c@1.9 +1 -0 + #include from all .c files and do not include it + from any .h files. + + libparse/trim_info.c@1.5 +1 -0 + #include from all .c files and do not include it + from any .h files. + + ntpd/Makefile.am@1.87 +4 -1 + add ntp_worker.c, work_fork.c, work_thread.c references. + + ntpd/cmd_args.c@1.56.1.3 +2 -3 + remove unused leftover global specific_interface. + rindex() -> strrchr() + + ntpd/ntp_config.c@1.244 +359 -589 + [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. + handle relative path to logfile correctly despite re-opening + after fork() with a different curdir. + include system headers before NTP ones. + No need to include ntpsim.h in ntp_config.c these days. + + ntpd/ntp_control.c@1.130 +2 -3 + style only + + ntpd/ntp_data_structures.c@1.12 +108 -67 + Preserve callsite __FILE__ and __LINE__ for create_priority_queue() + and get_node() for heap leak detection when available. + #include from all .c files and do not include it + from any .h files. + + ntpd/ntp_intres.c@1.80 +765 -1119 + [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. + + ntpd/ntp_io.c@1.311 +134 -70 + [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. + + ntpd/ntp_timer.c@1.57 +53 -46 + add worker_idle_timer and worker_idle_timer_fired() for + ntp_worker.c. + remove references to HAVE_TIMER_SETTIME which is redundant with + HAVE_TIMER_CREATE. + define TC_ERR macro to reduce #ifdef clutter. + eliminate global sys_time which was referenced only by timer(), + replacing with a local. call get_systime() only if the + result will be used in timer(). + + ntpd/ntp_worker.c@1.1 +155 -0 + blocking worker child process/thread cross-platform code + + ntpd/ntp_worker.c@1.0 +0 -0 + + ntpd/ntpd.c@1.110.1.2 +231 -123 + [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. + remove unused leftover global specific_interface. + move close-all-descriptors code to ntp_io.c close_all_beyond(), + used by work_fork.c as well. + handle relative path to logfile correctly despite re-opening + after fork() with a different curdir. + + ntpd/ntpsim.c@1.23 +1 -0 + #include from all .c files and do not include it + from any .h files. + + ntpd/refclock_jupiter.c@1.22 +1 -1 + XNTP_BIG_ENDIAN -> WORDS_BIG_ENDIAN (from config.h) + + ntpd/refclock_palisade.c@1.32 +33 -58 + eliminate hand-crafted byte-swapping code in preference + to using htonl(), htons(). Tested by Fernando Hauscarriaga. + + ntpd/refclock_palisade.h@1.14 +8 -12 + #include from all .c files and do not include it + from any .h files. + eliminate hand-crafted byte-swapping code in preference + to using htonl(), htons(). Tested by Fernando Hauscarriaga. + stay out of system/compiler underscore-prefixed namespace. + + ntpd/work_fork.c@1.1 +460 -0 + blocking worker child process fork()/pipe() platform code + + ntpd/work_fork.c@1.0 +0 -0 + + ntpd/work_thread.c@1.1 +314 -0 + blocking worker child thread platform code + + ntpd/work_thread.c@1.0 +0 -0 + + ntpdc/ntpdc-layout.c@1.2 +1 -0 + #include from all .c files and do not include it + from any .h files. + + ntpdc/ntpdc.c@1.78 +1 -0 + #include from all .c files and do not include it + from any .h files. + + ntpq/ntpq-subs.c@1.39.1.3 +40 -40 + #include from all .c files and do not include it + from any .h files. + dump received association IDs if (debug). + Remove bogus sanity check (requiring all peers use port 123 or + be silently excluded from ntpq -p output). + + ntpq/ntpq.c@1.99 +1 -1 + #include from all .c files and do not include it + from any .h files. + + ntpsnmpd/ntpSnmpSubagentObject.c@1.4 +6 -0 + #undef PACKAGE_* names that net-snmp-* headers often define + in conflict with ours. + #include from all .c files and do not include it + from any .h files. + + ntpsnmpd/ntpsnmpd.c@1.4 +1 -0 + #include from all .c files and do not include it + from any .h files. + + parseutil/testdcf.c@1.8 +1 -0 + #include from all .c files and do not include it + from any .h files. + + ports/winnt/include/config.h@1.82 +43 -8 + Use macros for ntohl() and friends, which are real function calls + by default on Windows. + + ports/winnt/include/sys/time.h@1.6 +0 -2 + #include from all .c files and do not include it + from any .h files. + + ports/winnt/include/win32_io.h@1.2 +2 -3 + style + + ports/winnt/libntp/SetSystemTime.c@1.8 +1 -0 + #include from all .c files and do not include it + from any .h files. + + ports/winnt/ntpd/nt_clockstuff.c@1.39 +1 -1 + Now that main ntpd directory is on include path, remove path to + ntpd-opts.h from #include. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.52 +18 -13 + [Bug 1010] getaddrinfo() could block and thus should not be called by + the main thread/process. + + ports/winnt/vc6/ntpd.dsp@1.47 +23 -0 + add ntp_worker.c, work_fork.c, work_thread.c, ntp_worker.h, + ntp_workimpl.h references. + + ports/winnt/vs2003/ntpd.vcproj@1.8 +15 -0 + add ntp_worker.c, work_fork.c, work_thread.c, ntp_worker.h, + ntp_workimpl.h references. + + ports/winnt/vs2005/ntpd.vcproj@1.8 +20 -0 + add ntp_worker.c, work_fork.c, work_thread.c, ntp_worker.h, + ntp_workimpl.h references. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.26 +28 -0 + add icom.c, strdup.c, strstr.c references. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.26 +200 -0 + add ntp_worker.c, work_fork.c, work_thread.c, ntp_worker.h, + ntp_workimpl.h, ntpsim.c, ntp_data_structures.h, + refclock_ripencc.c, libparse/binio.c, libparse/gsptolfp.c, + libparse/ieee754io.c, libparse/info_trimble.c, + libparse/mfp_mul.c, libparse/parsesolaris.c, + libparse/parsestreams.c, libparse/trim_info.c references. + + sntp/crypto.c@1.11 +1 -0 + #include from all .c files and do not include it + from any .h files. + + sntp/kod_management.c@1.17 +1 -0 + #include from all .c files and do not include it + from any .h files. + + sntp/log.c@1.12 +1 -0 + #include from all .c files and do not include it + from any .h files. + + sntp/main.c@1.25 +1 -0 + #include from all .c files and do not include it + from any .h files. + + sntp/networking.c@1.30 +1 -0 + #include from all .c files and do not include it + from any .h files. + + sntp/utilities.c@1.11 +1 -0 + #include from all .c files and do not include it + from any .h files. + +ChangeSet@1.2084.1.24, 2010-01-24 11:44:49+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P10 + TAG: NTP_4_2_7P10 + + ChangeLog@1.510 +1 -0 + NTP_4_2_7P10 + + ntpd/ntpd-opts.c@1.11 +2 -2 + NTP_4_2_7P10 + + ntpd/ntpd-opts.h@1.11 +3 -3 + NTP_4_2_7P10 + + ntpd/ntpd-opts.texi@1.11 +2 -2 + NTP_4_2_7P10 + + ntpd/ntpd.1@1.11 +2 -2 + NTP_4_2_7P10 + + ntpdc/ntpdc-opts.c@1.11 +2 -2 + NTP_4_2_7P10 + + ntpdc/ntpdc-opts.h@1.11 +3 -3 + NTP_4_2_7P10 + + ntpdc/ntpdc-opts.texi@1.11 +2 -2 + NTP_4_2_7P10 + + ntpdc/ntpdc.1@1.11 +2 -2 + NTP_4_2_7P10 + + ntpq/ntpq-opts.c@1.11 +2 -2 + NTP_4_2_7P10 + + ntpq/ntpq-opts.h@1.11 +3 -3 + NTP_4_2_7P10 + + ntpq/ntpq-opts.texi@1.11 +2 -2 + NTP_4_2_7P10 + + ntpq/ntpq.1@1.11 +2 -2 + NTP_4_2_7P10 + + ntpsnmpd/ntpsnmpd-opts.c@1.11 +2 -2 + NTP_4_2_7P10 + + ntpsnmpd/ntpsnmpd-opts.h@1.11 +3 -3 + NTP_4_2_7P10 + + ntpsnmpd/ntpsnmpd-opts.texi@1.11 +2 -2 + NTP_4_2_7P10 + + ntpsnmpd/ntpsnmpd.1@1.11 +2 -2 + NTP_4_2_7P10 + + packageinfo.sh@1.12 +1 -1 + NTP_4_2_7P10 + + sntp/sntp-opts.c@1.11 +2 -2 + NTP_4_2_7P10 + + sntp/sntp-opts.h@1.11 +3 -3 + NTP_4_2_7P10 + + sntp/sntp-opts.texi@1.11 +2 -2 + NTP_4_2_7P10 + + sntp/sntp.1@1.11 +2 -2 + NTP_4_2_7P10 + + sntp/sntp.html@1.11 +1 -1 + NTP_4_2_7P10 + + util/ntp-keygen-opts.c@1.11 +2 -2 + NTP_4_2_7P10 + + util/ntp-keygen-opts.h@1.11 +3 -3 + NTP_4_2_7P10 + + util/ntp-keygen-opts.texi@1.11 +2 -2 + NTP_4_2_7P10 + + util/ntp-keygen.1@1.11 +2 -2 + NTP_4_2_7P10 + +ChangeSet@1.2082.4.47, 2010-01-24 10:31:32+00:00, stenn@whimsy.udel.edu + NTP_4_2_6P1_RC3 + TAG: NTP_4_2_6P1_RC3 + + ChangeLog@1.496.26.30 +1 -0 + NTP_4_2_6P1_RC3 + + ntpd/ntpd-opts.c@1.248.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpd/ntpd-opts.h@1.248.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpd/ntpd-opts.texi@1.246.3.1 +2 -2 + NTP_4_2_6P1_RC3 + + ntpd/ntpd.1@1.246.3.1 +2 -2 + NTP_4_2_6P1_RC3 + + ntpdc/ntpdc-opts.c@1.244.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpdc/ntpdc-opts.h@1.244.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpdc/ntpdc-opts.texi@1.243.3.1 +3 -3 + NTP_4_2_6P1_RC3 + + ntpdc/ntpdc.1@1.243.3.1 +2 -2 + NTP_4_2_6P1_RC3 + + ntpq/ntpq-opts.c@1.245.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpq/ntpq-opts.h@1.245.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpq/ntpq-opts.texi@1.244.3.1 +3 -3 + NTP_4_2_6P1_RC3 + + ntpq/ntpq.1@1.244.3.1 +2 -2 + NTP_4_2_6P1_RC3 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.3.1 +3 -3 + NTP_4_2_6P1_RC3 + + ntpsnmpd/ntpsnmpd.1@1.122.3.1 +2 -2 + NTP_4_2_6P1_RC3 + + packageinfo.sh@1.255.5.1 +1 -1 + NTP_4_2_6P1_RC3 + + sntp/sntp-opts.c@1.117.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + sntp/sntp-opts.h@1.117.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + sntp/sntp-opts.texi@1.117.3.1 +3 -3 + NTP_4_2_6P1_RC3 + + sntp/sntp.1@1.117.3.1 +2 -2 + NTP_4_2_6P1_RC3 + + sntp/sntp.html@1.7.3.1 +1 -1 + NTP_4_2_6P1_RC3 + + util/ntp-keygen-opts.c@1.247.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + util/ntp-keygen-opts.h@1.247.3.1 +4 -4 + NTP_4_2_6P1_RC3 + + util/ntp-keygen-opts.texi@1.246.3.1 +3 -3 + NTP_4_2_6P1_RC3 + + util/ntp-keygen.1@1.246.3.1 +2 -2 + NTP_4_2_6P1_RC3 + +ChangeSet@1.2084.1.23, 2010-01-24 04:30:32-05:00, stenn@whimsy.udel.edu + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + ChangeLog@1.509 +1 -0 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + html/debug.html@1.28 +3 -3 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + html/decode.html@1.12 +11 -7 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + + html/ntpq.html@1.37 +11 -7 + [Bug 1140] Clean up debug.html, decode.html, and ntpq.html + +ChangeSet@1.2082.4.46, 2010-01-24 03:49:59-05:00, stenn@whimsy.udel.edu + Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in + + ChangeLog@1.496.26.29 +4 -3 + Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in + + scripts/mkver.in@1.12 +1 -1 + Use TZ=UTC instead of TZ= when calling date in scripts/mkver.in + +ChangeSet@1.2082.4.45, 2010-01-24 03:44:05-05:00, stenn@whimsy.udel.edu + cleanup + + ChangeLog@1.496.26.28 +2 -2 + cleanup + +ChangeSet@1.2082.4.44, 2010-01-24 03:39:27-05:00, stenn@whimsy.udel.edu + [Bug 1449] SLEW is no longer needed by the simulator + + include/ntpsim.h@1.12.1.1 +0 -1 + [Bug 1449] SLEW is no longer needed by the simulator + +ChangeSet@1.2084.1.21, 2010-01-24 00:16:39-05:00, mayer@pogo.udel.edu + Fix move results for vc6 + + ports/winnt/vc6/libntp.dsp@1.51 +17 -17 + Fix move results for vc6 + + ports/winnt/vc6/ntpd.dsp@1.46 +3 -4 + Fix move results for vc6 + +ChangeSet@1.2084.1.20, 2010-01-24 00:03:42-05:00, mayer@pogo.udel.edu + Remerge of bugs 1448-1450 + + ChangeLog@1.507 +4 -0 + Remerge of bugs 1448-1450 + +ChangeSet@1.2082.4.43, 2010-01-23 23:09:00-05:00, mayer@pogo.udel.edu + Bad inputdir reference + + ports/winnt/vc6/libntp.dsp@1.43.1.9 +1 -1 + Bad inputdir reference + +ChangeSet@1.2082.4.42, 2010-01-22 11:49:48+01:00, burnicki@pogo.udel.edu + Create the instserv binaries in the correct directories. + + ports/winnt/vc6/Instsrv.dsp@1.12 +2 -2 + Create the instserv binaries in the correct directories. + +ChangeSet@1.2082.4.41, 2010-01-21 23:37:23-05:00, mayer@pogo.udel.edu + Remove ipv6.c as unnecessary + + ports/winnt/vc6/libntp.dsp@1.43.1.8 +0 -4 + Remove ipv6.c as unnecessary + +ChangeSet@1.2082.4.40, 2010-01-17 22:28:21-05:00, mayer@pogo.udel.edu + Temporarily include ntpsim.h unconditionally + + ntpd/ntp_config.c@1.241.1.2 +5 -2 + Temporarily include ntpsim.h unconditionally + +ChangeSet@1.2082.4.38, 2010-01-16 23:20:10-05:00, mayer@pogo.udel.edu + [Bug 1448] Additional fixes for Windows VC6 + + lib/isc/win32/net.c@1.14 +2 -2 + [Bug 1448] Additional fixes for Windows VC6 + + ports/winnt/vc6/libntp.dsp@1.43.1.7 +23 -15 + [Bug 1448] Additional fixes for Windows VC6 + +ChangeSet@1.2084.1.18, 2010-01-13 10:30:51+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P9 + TAG: NTP_4_2_7P9 + + ChangeLog@1.505 +1 -0 + NTP_4_2_7P9 + + ntpd/ntpd-opts.c@1.10 +2 -2 + NTP_4_2_7P9 + + ntpd/ntpd-opts.h@1.10 +3 -3 + NTP_4_2_7P9 + + ntpd/ntpd-opts.texi@1.10 +2 -2 + NTP_4_2_7P9 + + ntpd/ntpd.1@1.10 +2 -2 + NTP_4_2_7P9 + + ntpdc/ntpdc-opts.c@1.10 +2 -2 + NTP_4_2_7P9 + + ntpdc/ntpdc-opts.h@1.10 +3 -3 + NTP_4_2_7P9 + + ntpdc/ntpdc-opts.texi@1.10 +2 -2 + NTP_4_2_7P9 + + ntpdc/ntpdc.1@1.10 +2 -2 + NTP_4_2_7P9 + + ntpq/ntpq-opts.c@1.10 +2 -2 + NTP_4_2_7P9 + + ntpq/ntpq-opts.h@1.10 +3 -3 + NTP_4_2_7P9 + + ntpq/ntpq-opts.texi@1.10 +2 -2 + NTP_4_2_7P9 + + ntpq/ntpq.1@1.10 +2 -2 + NTP_4_2_7P9 + + ntpsnmpd/ntpsnmpd-opts.c@1.10 +2 -2 + NTP_4_2_7P9 + + ntpsnmpd/ntpsnmpd-opts.h@1.10 +3 -3 + NTP_4_2_7P9 + + ntpsnmpd/ntpsnmpd-opts.texi@1.10 +2 -2 + NTP_4_2_7P9 + + ntpsnmpd/ntpsnmpd.1@1.10 +2 -2 + NTP_4_2_7P9 + + packageinfo.sh@1.11 +1 -1 + NTP_4_2_7P9 + + sntp/sntp-opts.c@1.10 +2 -2 + NTP_4_2_7P9 + + sntp/sntp-opts.h@1.10 +3 -3 + NTP_4_2_7P9 + + sntp/sntp-opts.texi@1.10 +2 -2 + NTP_4_2_7P9 + + sntp/sntp.1@1.10 +2 -2 + NTP_4_2_7P9 + + sntp/sntp.html@1.10 +1 -1 + NTP_4_2_7P9 + + util/ntp-keygen-opts.c@1.10 +2 -2 + NTP_4_2_7P9 + + util/ntp-keygen-opts.h@1.10 +3 -3 + NTP_4_2_7P9 + + util/ntp-keygen-opts.texi@1.10 +2 -2 + NTP_4_2_7P9 + + util/ntp-keygen.1@1.10 +2 -2 + NTP_4_2_7P9 + +ChangeSet@1.2084.6.45, 2010-01-12 10:34:14+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P8 + TAG: NTP_4_2_7P8 + + ChangeLog@1.501.1.37 +1 -0 + NTP_4_2_7P8 + + ntpd/ntpd-opts.c@1.9 +4 -4 + NTP_4_2_7P8 + + ntpd/ntpd-opts.h@1.9 +4 -4 + NTP_4_2_7P8 + + ntpd/ntpd-opts.texi@1.9 +2 -2 + NTP_4_2_7P8 + + ntpd/ntpd.1@1.9 +2 -2 + NTP_4_2_7P8 + + ntpdc/ntpdc-opts.c@1.9 +4 -4 + NTP_4_2_7P8 + + ntpdc/ntpdc-opts.h@1.9 +4 -4 + NTP_4_2_7P8 + + ntpdc/ntpdc-opts.texi@1.9 +3 -3 + NTP_4_2_7P8 + + ntpdc/ntpdc.1@1.9 +2 -2 + NTP_4_2_7P8 + + ntpq/ntpq-opts.c@1.9 +4 -4 + NTP_4_2_7P8 + + ntpq/ntpq-opts.h@1.9 +4 -4 + NTP_4_2_7P8 + + ntpq/ntpq-opts.texi@1.9 +3 -3 + NTP_4_2_7P8 + + ntpq/ntpq.1@1.9 +2 -2 + NTP_4_2_7P8 + + ntpsnmpd/ntpsnmpd-opts.c@1.9 +4 -4 + NTP_4_2_7P8 + + ntpsnmpd/ntpsnmpd-opts.h@1.9 +4 -4 + NTP_4_2_7P8 + + ntpsnmpd/ntpsnmpd-opts.texi@1.9 +3 -3 + NTP_4_2_7P8 + + ntpsnmpd/ntpsnmpd.1@1.9 +2 -2 + NTP_4_2_7P8 + + packageinfo.sh@1.10 +1 -1 + NTP_4_2_7P8 + + sntp/sntp-opts.c@1.9 +4 -4 + NTP_4_2_7P8 + + sntp/sntp-opts.h@1.9 +4 -4 + NTP_4_2_7P8 + + sntp/sntp-opts.texi@1.9 +3 -3 + NTP_4_2_7P8 + + sntp/sntp.1@1.9 +2 -2 + NTP_4_2_7P8 + + sntp/sntp.html@1.9 +1 -1 + NTP_4_2_7P8 + + util/ntp-keygen-opts.c@1.9 +4 -4 + NTP_4_2_7P8 + + util/ntp-keygen-opts.h@1.9 +4 -4 + NTP_4_2_7P8 + + util/ntp-keygen-opts.texi@1.9 +3 -3 + NTP_4_2_7P8 + + util/ntp-keygen.1@1.9 +2 -2 + NTP_4_2_7P8 + +ChangeSet@1.2084.10.4, 2010-01-11 17:06:06+01:00, burnicki@pogo.udel.edu + Syntax fix in ntp.dsw and ntpd.dsp for VC6. + + ports/winnt/vc6/ntp.dsw@1.13 +0 -1 + Syntax fix. + + ports/winnt/vc6/ntpd.dsp@1.43.1.1 +2 -1 + Syntax fix. + +ChangeSet@1.2084.12.2, 2010-01-08 20:00:10+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: Include (4.2.6p1-RC3) - [Bug 1453] Use $CC in config.cache filename. + + ChangeLog@1.501.6.2 +1 -0 + ChangeLog: Include (4.2.6p1-RC3) - [Bug 1453] Use $CC in config.cache filename. + +ChangeSet@1.2082.16.3, 2010-01-08 19:11:53+00:00, davehart@shiny.ad.hartbrothers.com + Makefile.am: + add dependencies on copyright.def + correct dependencies to refer to $(srcdir)/version.def not + $(srcdir)/../include/version.def + add COPYRIGHT to BUILT_SOURCES, correct EXTRA_DIST reference to + remove unneeded $(srcdir)/ prefix + + sntp/Makefile.am@1.21.1.4 +5 -4 + add dependencies on copyright.def + correct dependencies to refer to $(srcdir)/version.def not + $(srcdir)/../include/version.def + add COPYRIGHT to BUILT_SOURCES, correct EXTRA_DIST reference to + remove unneeded $(srcdir)/ prefix + +ChangeSet@1.2082.16.2, 2010-01-08 17:21:14+00:00, davehart@shiny.ad.hartbrothers.com + bump copyright year to 2010 + + html/copyright.html@1.46 +2 -2 + bump copyright year to 2010 + + include/copyright.def@1.11 +1 -1 + bump copyright year to 2010 + +ChangeSet@1.2082.16.1, 2010-01-06 18:52:49+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1453] Use $CC in config.cache filename in ./build script. + + ChangeLog@1.496.41.1 +4 -3 + [Bug 1453] Use $CC in config.cache filename in ./build script. + + build@1.34 +26 -27 + [Bug 1453] Use $CC in config.cache filename in ./build script. + +ChangeSet@1.2082.4.37, 2010-01-03 23:03:48-05:00, mayer@pogo.udel.edu + Undo unneeded change + + lib/isc/netaddr.c@1.8 +1 -1 + Undo unneeded change + +ChangeSet@1.2084.11.2, 2010-01-03 21:56:54+00:00, davehart@shiny.ad.hartbrothers.com + Correct ChangeLog to reflect [Bug 1451] in -dev section as well. + + ChangeLog@1.501.5.2 +1 -0 + Correct ChangeLog to reflect [Bug 1451] in -dev section as well. + +ChangeSet@1.2082.15.1, 2010-01-03 21:52:33+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1451] CID 115: sntp leaks KoD entry when updating existing + entry. + + ChangeLog@1.496.40.1 +4 -3 + [Bug 1451] CID 115: sntp leaks KoD entry when updating existing + entry. + + sntp/kod_management.c@1.16 +1 -0 + [Bug 1451] CID 115: sntp leaks KoD entry when updating existing + entry. + +ChangeSet@1.2084.10.2, 2010-01-02 22:47:59-05:00, mayer@pogo.udel.edu + Fixes for Bugs 1448-1450 + + ChangeLog@1.501.4.2 +4 -0 + Fixes for Bugs 1448-1450 + +ChangeSet@1.2082.4.36, 2010-01-01 23:49:35-05:00, mayer@pogo.udel.edu + Fixes for bugs 1448-1450 + + ChangeLog@1.496.26.26 +4 -0 + Fixes for bug 1448-1450 + + lib/isc/netaddr.c@1.7 +1 -1 + [Bug 1448] scope_id and ipv6 any address not defined on vc6 compiler + + lib/isc/win32/include/isc/platform.h@1.7 +2 -2 + [Bug 1448] Macros not correctly conditionally defined + + lib/isc/win32/interfaceiter.c@1.16 +2 -0 + [Bug 1448] scope_id and ipv6 any address not defined on vc6 compiler + + ntpd/ntp_config.c@1.241.1.1 +3 -1 + [Bug 1449] ntpsim.h should only be conditionally included and after ntpd-opts.h + + ports/winnt/include/config.h@1.79.1.1 +2 -2 + [Bug 1448] Macros not correctly conditionally defined + + ports/winnt/vc6/libntp.dsp@1.43.1.6 +0 -4 + [Bug 1448] stdtime.c misspelled but not needed at all + +ChangeSet@1.2084.6.41, 2009-12-30 21:55:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 702] ntpd service logic should use libopts to examine cmdline. + + ChangeLog@1.501.1.33 +1 -0 + [Bug 702] ntpd service logic should use libopts to examine cmdline. + + include/ntp_cmdargs.h@1.6 +1 -4 + remove unused cruft + + include/ntpd.h@1.137.1.1 +1 -0 + expose parse_cmdline_opts() for use by ntservice.c + + ntpd/cmd_args.c@1.56.1.2 +6 -3 + comment only + + ntpd/ntp_config.c@1.242 +3 -3 + minor cleanup + + ntpd/ntpd.c@1.110.1.1 +12 -10 + [Bug 702] ntpd service logic should use libopts to examine cmdline. + + ports/winnt/include/ntservice.h@1.4 +4 -9 + [Bug 702] ntpd service logic should use libopts to examine cmdline. + + ports/winnt/ntpd/ntservice.c@1.23 +40 -49 + [Bug 702] ntpd service logic should use libopts to examine cmdline. + + ports/winnt/vc6/ntpd.dsp@1.44 +2 -2 + top-level ntpd directory needs to be in include search path + for ntservice.c to #include "ntpd-opts.h" + + ports/winnt/vs2003/ntpd.vcproj@1.7 +2 -2 + top-level ntpd directory needs to be in include search path + for ntservice.c to #include "ntpd-opts.h" + + ports/winnt/vs2005/ntpd.vcproj@1.7 +2 -2 + top-level ntpd directory needs to be in include search path + for ntservice.c to #include "ntpd-opts.h" + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.25 +2 -2 + top-level ntpd directory needs to be in include search path + for ntservice.c to #include "ntpd-opts.h" + +ChangeSet@1.2084.6.40, 2009-12-30 10:27:13+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P7 + TAG: NTP_4_2_7P7 + + ChangeLog@1.501.1.32 +1 -0 + NTP_4_2_7P7 + + ntpd/ntpd-opts.c@1.8 +2 -2 + NTP_4_2_7P7 + + ntpd/ntpd-opts.h@1.8 +3 -3 + NTP_4_2_7P7 + + ntpd/ntpd-opts.texi@1.8 +2 -2 + NTP_4_2_7P7 + + ntpd/ntpd.1@1.8 +2 -2 + NTP_4_2_7P7 + + ntpdc/ntpdc-opts.c@1.8 +2 -2 + NTP_4_2_7P7 + + ntpdc/ntpdc-opts.h@1.8 +3 -3 + NTP_4_2_7P7 + + ntpdc/ntpdc-opts.texi@1.8 +2 -2 + NTP_4_2_7P7 + + ntpdc/ntpdc.1@1.8 +2 -2 + NTP_4_2_7P7 + + ntpq/ntpq-opts.c@1.8 +2 -2 + NTP_4_2_7P7 + + ntpq/ntpq-opts.h@1.8 +3 -3 + NTP_4_2_7P7 + + ntpq/ntpq-opts.texi@1.8 +2 -2 + NTP_4_2_7P7 + + ntpq/ntpq.1@1.8 +2 -2 + NTP_4_2_7P7 + + ntpsnmpd/ntpsnmpd-opts.c@1.8 +2 -2 + NTP_4_2_7P7 + + ntpsnmpd/ntpsnmpd-opts.h@1.8 +3 -3 + NTP_4_2_7P7 + + ntpsnmpd/ntpsnmpd-opts.texi@1.8 +2 -2 + NTP_4_2_7P7 + + ntpsnmpd/ntpsnmpd.1@1.8 +2 -2 + NTP_4_2_7P7 + + packageinfo.sh@1.9 +1 -1 + NTP_4_2_7P7 + + sntp/sntp-opts.c@1.8 +2 -2 + NTP_4_2_7P7 + + sntp/sntp-opts.h@1.8 +3 -3 + NTP_4_2_7P7 + + sntp/sntp-opts.texi@1.8 +2 -2 + NTP_4_2_7P7 + + sntp/sntp.1@1.8 +2 -2 + NTP_4_2_7P7 + + sntp/sntp.html@1.8 +1 -1 + NTP_4_2_7P7 + + util/ntp-keygen-opts.c@1.8 +2 -2 + NTP_4_2_7P7 + + util/ntp-keygen-opts.h@1.8 +3 -3 + NTP_4_2_7P7 + + util/ntp-keygen-opts.texi@1.8 +2 -2 + NTP_4_2_7P7 + + util/ntp-keygen.1@1.8 +2 -2 + NTP_4_2_7P7 + +ChangeSet@1.2084.9.2, 2009-12-30 05:56:00+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1446] 4.2.7p6 requires autogen, missing ntpd.1, *.texi, *.menu. + Applies to prior Makefile.am changesets pulled from ntp-stable, + where there is no ChangeLog entry as no tarball rolled with the bug. + + ChangeLog@1.501.3.1 +1 -0 + [Bug 1446] 4.2.7p6 requires autogen, missing ntpd.1, *.texi, *.menu. + Applies to prior Makefile.am changesets pulled from ntp-stable, + where there is no ChangeLog entry as no tarball rolled with the bug. + +ChangeSet@1.2082.4.35, 2009-12-30 05:48:36+00:00, davehart@shiny.ad.hartbrothers.com + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html Makefile rules are not needed. + + ntpd/Makefile.am@1.80.1.5 +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + ntpdc/Makefile.am@1.48.1.3 +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + ntpq/Makefile.am@1.43.1.3 +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + ntpsnmpd/Makefile.am@1.16.1.3 +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + sntp/Makefile.am@1.21.1.3 +3 -12 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + + util/Makefile.am@1.45.1.3 +2 -9 + With EXTRA_DIST fix from [Bug 1446] read-only $(srcdir) hacks in + *.1, *.texi, and *.html rules are not needed. + +ChangeSet@1.2082.4.34, 2009-12-30 00:23:25+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1446] 4.2.7p6 requires autogen to build missing ntpd.1, *.texi, *.menu. + + ntpd/Makefile.am@1.80.1.4 +4 -1 + [Bug 1446] 4.2.7p6 requires autogen to build missing ntpd.1, *.texi, *.menu. + +ChangeSet@1.2084.6.38, 2009-12-29 16:07:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 620] ntpdc getresponse() esize != *rsize s/b size != *rsize. + + ChangeLog@1.501.1.30 +1 -0 + [Bug 620] ntpdc getresponse() esize != *rsize s/b size != *rsize. + + ntpdc/ntpdc.c@1.77 +1 -1 + [Bug 620] ntpdc getresponse() esize != *rsize s/b size != *rsize. + +ChangeSet@1.2084.6.37, 2009-12-28 10:30:49+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P6 + TAG: NTP_4_2_7P6 + + ChangeLog@1.501.1.29 +1 -0 + NTP_4_2_7P6 + + ntpd/ntpd-opts.c@1.7 +2 -2 + NTP_4_2_7P6 + + ntpd/ntpd-opts.h@1.7 +3 -3 + NTP_4_2_7P6 + + ntpd/ntpd-opts.texi@1.7 +61 -2 + NTP_4_2_7P6 + + ntpd/ntpd.1@1.7 +2 -2 + NTP_4_2_7P6 + + ntpdc/ntpdc-opts.c@1.7 +2 -2 + NTP_4_2_7P6 + + ntpdc/ntpdc-opts.h@1.7 +3 -3 + NTP_4_2_7P6 + + ntpdc/ntpdc-opts.texi@1.7 +66 -2 + NTP_4_2_7P6 + + ntpdc/ntpdc.1@1.7 +2 -2 + NTP_4_2_7P6 + + ntpq/ntpq-opts.c@1.7 +2 -2 + NTP_4_2_7P6 + + ntpq/ntpq-opts.h@1.7 +3 -3 + NTP_4_2_7P6 + + ntpq/ntpq-opts.texi@1.7 +51 -2 + NTP_4_2_7P6 + + ntpq/ntpq.1@1.7 +2 -2 + NTP_4_2_7P6 + + ntpsnmpd/ntpsnmpd-opts.c@1.7 +2 -2 + NTP_4_2_7P6 + + ntpsnmpd/ntpsnmpd-opts.h@1.7 +3 -3 + NTP_4_2_7P6 + + ntpsnmpd/ntpsnmpd-opts.texi@1.7 +23 -2 + NTP_4_2_7P6 + + ntpsnmpd/ntpsnmpd.1@1.7 +2 -2 + NTP_4_2_7P6 + + packageinfo.sh@1.8 +1 -1 + NTP_4_2_7P6 + + sntp/sntp-opts.c@1.7 +2 -2 + NTP_4_2_7P6 + + sntp/sntp-opts.h@1.7 +3 -3 + NTP_4_2_7P6 + + sntp/sntp-opts.texi@1.7 +60 -2 + NTP_4_2_7P6 + + sntp/sntp.1@1.7 +2 -2 + NTP_4_2_7P6 + + sntp/sntp.html@1.7 +1 -1 + NTP_4_2_7P6 + + util/ntp-keygen-opts.c@1.7 +2 -2 + NTP_4_2_7P6 + + util/ntp-keygen-opts.h@1.7 +3 -3 + NTP_4_2_7P6 + + util/ntp-keygen-opts.texi@1.7 +46 -2 + NTP_4_2_7P6 + + util/ntp-keygen.1@1.7 +2 -2 + NTP_4_2_7P6 + +ChangeSet@1.2084.6.36, 2009-12-28 04:24:27-05:00, stenn@whimsy.udel.edu + cleanup + + ChangeLog@1.501.1.28 +2 -0 + cleanup + +ChangeSet@1.2082.4.33, 2009-12-28 04:17:49-05:00, stenn@whimsy.udel.edu + [Bug 1445] IRIX does not have -lcap or support linux capabilities + + ChangeLog@1.496.26.25 +2 -1 + [Bug 1445] IRIX does not have -lcap or support linux capabilities + + configure.ac@1.465.1.9 +7 -1 + [Bug 1445] IRIX does not have -lcap or support linux capabilities + +ChangeSet@1.2084.6.33, 2009-12-28 00:57:22-05:00, stenn@whimsy.udel.edu + ntpdate.c still needs ntp_io.h + + ntpdate/ntpdate.c@1.71 +1 -0 + ntpdate.c still needs ntp_io.h + +ChangeSet@1.2084.8.7, 2009-12-28 05:24:22+00:00, mayer@psp-fb1.ntp.org + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vs2003/libntp.vcproj@1.9 +1 -1 + [Bug 1442] Move Windows functions into libntp files + +ChangeSet@1.2084.8.6, 2009-12-28 02:21:48+00:00, mayer@psp-fb1.ntp.org + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vc6/libntp.dsp@1.48 +2 -2 + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vs2003/libntp.vcproj@1.8 +2 -2 + [Bug 1442] Move Windows functions into libntp files + +ChangeSet@1.2084.8.5, 2009-12-28 01:56:22+00:00, mayer@psp-fb1.ntp.org + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vs2008/libntp/libntp.vcproj@1.25 +2 -2 + [Bug 1442] Move Windows functions into libntp files + +ChangeSet@1.2084.8.4, 2009-12-27 22:03:56+00:00, mayer@psp-fb1.ntp.org + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/libntp/termios.c@1.21 +1 -0 + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vs2008/libntp/libntp.vcproj@1.24 +1 -1 + [Bug 1442] Move Windows functions into libntp files + +ChangeSet@1.2084.8.3, 2009-12-27 21:35:25+00:00, mayer@psp-fb1.ntp.org + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vc6/libntp.dsp@1.47 +12 -0 + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vc6/ntp.dsw@1.12 +4 -0 + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vc6/ntpd.dsp@1.43 +0 -6 + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vs2003/libntp.vcproj@1.7 +42 -0 + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vs2003/ntp.sln@1.2 +1 -0 + [Bug 1442] Move Windows functions into libntp files + + ports/winnt/vs2003/ntpd.vcproj@1.6 +0 -23 + [Bug 1442] Move Windows functions into libntp files + +ChangeSet@1.2084.8.2, 2009-12-27 21:08:21+00:00, mayer@psp-fb1.ntp.org + [Bug 1442] and [Bug 1443] + + ChangeLog@1.501.2.1 +2 -0 + [Bug 1442] and [Bug 1443] + +ChangeSet@1.2084.7.3, 2009-12-27 21:02:00+00:00, mayer@psp-fb1.ntp.org + [Bug 1443] Remove unnecessary dependencies on ntp_io.h + + libntp/recvbuff.c@1.34 +0 -1 + [Bug 1443] Remove unnecessary dependencies on ntp_io.h + + ntpd/ntp_io.c@1.310 +1 -37 + [Bug 1443] Remove unnecessary dependencies on ntp_io.h + + ntpd/ntp_util.c@1.76 +0 -1 + [Bug 1443] Remove unnecessary dependencies on ntp_io.h + + ntpdate/ntpdate.c@1.70 +0 -1 + [Bug 1443] Remove unnecessary dependencies on ntp_io.h + + ntpdc/ntpdc.c@1.76 +0 -1 + [Bug 1443] Remove unnecessary dependencies on ntp_io.h + + ntpq/ntpq.c@1.98 +0 -1 + [Bug 1443] Remove unnecessary dependencies on ntp_io.h + +ChangeSet@1.2084.7.2, 2009-12-27 20:52:30+00:00, mayer@psp-fb1.ntp.org + [Bug 1442] Move functions into libntp files + + ports/winnt/include/config.h@1.80 +0 -13 + [Bug 1442] Move functions into libntp files + + ports/winnt/include/termios.h@1.13 +3 -3 + [Bug 1442] Move functions into libntp files + + ports/winnt/include/win32_io.h@1.1 +8 -0 + [Bug 1442] Move functions into libntp files + + ports/winnt/include/win32_io.h@1.0 +0 -0 + + ports/winnt/libntp/setpriority.c@1.3 +0 -30 + [Bug 1442] Move functions into libntp files + + ports/winnt/libntp/win32_io.c@1.1 +80 -0 + [Bug 1442] Move functions into libntp files + + ports/winnt/libntp/win32_io.c@1.0 +0 -0 + + ports/winnt/vs2005/Instsrv.vcproj@1.2 +2 -2 + [Bug 1442] Move functions into libntp files + + ports/winnt/vs2005/libntp.vcproj@1.7 +12 -4 + [Bug 1442] Move functions into libntp files + + ports/winnt/vs2005/ntp.sln@1.2 +3 -1 + [Bug 1442] Move functions into libntp files + + ports/winnt/vs2005/ntpd.vcproj@1.6 +2 -24 + [Bug 1442] Move functions into libntp files + + ports/winnt/vs2008/libntp/libntp.vcproj@1.23 +8 -0 + [Bug 1442] Move functions into libntp files + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.24 +0 -22 + [Bug 1442] Move functions into libntp files + +ChangeSet@1.2084.7.1, 2009-12-27 20:38:02+00:00, mayer@psp-fb1.ntp.org + [Bug 1442} Move some windows-specific files to linntp + + BitKeeper/deleted/.del-termios.h~8b711e53@1.3 +0 -0 + Delete: ports/winnt/include/termios.h + + ports/winnt/include/termios.h@1.12 +0 -0 + Rename: ports/winnt/include/win32_io.h -> ports/winnt/include/termios.h + + ports/winnt/libntp/termios.c@1.20 +0 -0 + Rename: ports/winnt/ntpd/win32_io.c -> ports/winnt/libntp/termios.c + +ChangeSet@1.2084.6.31, 2009-12-27 17:37:15+00:00, davehart@shiny.ad.hartbrothers.com + correct ChangeLog merge from -stable + + ChangeLog@1.501.1.25 +1 -0 + correct ChangeLog merge from -stable + +ChangeSet@1.2082.14.1, 2009-12-27 09:16:20+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1439] .texi generation must wait until after binary is linked. + Quiet RES_TIMEOUT redefinition warning compiling ntp_intres.c + + ChangeLog@1.496.39.1 +4 -0 + [Bug 1439] .texi generation must wait until after binary is linked. + + ntpd/Makefile.am@1.80.1.3 +16 -10 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + ntpd/ntp_intres.c@1.79 +7 -3 + follow AC_HEADER_RESOLV suggestion to include sys/types.h ahead + of netinet/in.h + quiet RES_TIMEOUT redefinition warning (resolv.h vs. ntp.h) + + ntpdc/Makefile.am@1.48.1.2 +17 -10 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + ntpq/Makefile.am@1.43.1.2 +17 -10 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + ntpsnmpd/Makefile.am@1.16.1.2 +17 -12 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + sntp/Makefile.am@1.21.1.2 +26 -23 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1, .texi, and .html rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + + util/Makefile.am@1.45.1.2 +17 -9 + remove *.texi *.menu *.html *.1 from BUILT_SOURCES, add all except .1 + to noinst_DATA, and remove sub-make hack to build binary [Bug 1439]. + change man_MANS= reference to .1 to have $(srcdir)/ prefix, work around + make distcheck R/O srcdir in .1 and ,texi rules. + separate .menu rule from .texi to avoid redundant Autogen invocation. + +ChangeSet@1.2084.6.29, 2009-12-27 01:59:48-05:00, stenn@whimsy.udel.edu + merge cleanup + + ChangeLog@1.501.1.23 +1 -0 + merge cleanup + +ChangeSet@1.2082.4.31, 2009-12-27 01:54:07-05:00, stenn@whimsy.udel.edu + cleanup + + ChangeLog@1.496.26.23 +5 -2 + cleanup + +ChangeSet@1.2082.4.30, 2009-12-27 01:47:48-05:00, stenn@whimsy.udel.edu + [Bug 1440] Update configure.ac to support kfreebsd + + ChangeLog@1.496.26.22 +1 -0 + [Bug 1440] Update configure.ac to support kfreebsd + + configure.ac@1.465.1.8 +12 -0 + [Bug 1440] Update configure.ac to support kfreebsd + +ChangeSet@1.2082.4.29, 2009-12-27 00:40:27-05:00, stenn@whimsy.udel.edu + [Bug 1127] Properly check the return of X590_verify() - missed one + + ChangeLog@1.496.26.21 +1 -0 + [Bug 1127] Properly check the return of X590_verify() - missed one + + util/ntp-keygen.c@1.64 +1 -1 + [Bug 1127] Properly check the return of X590_verify() - missed one + +ChangeSet@1.2084.6.26, 2009-12-25 10:34:17+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P5 + TAG: NTP_4_2_7P5 + + ChangeLog@1.501.1.20 +1 -0 + NTP_4_2_7P5 + + ntpd/ntpd-opts.c@1.6 +2 -2 + NTP_4_2_7P5 + + ntpd/ntpd-opts.h@1.6 +3 -3 + NTP_4_2_7P5 + + ntpd/ntpd-opts.texi@1.6 +1 -1 + NTP_4_2_7P5 + + ntpd/ntpd.1@1.6 +2 -2 + NTP_4_2_7P5 + + ntpdc/ntpdc-opts.c@1.6 +2 -2 + NTP_4_2_7P5 + + ntpdc/ntpdc-opts.h@1.6 +3 -3 + NTP_4_2_7P5 + + ntpdc/ntpdc-opts.texi@1.6 +1 -1 + NTP_4_2_7P5 + + ntpdc/ntpdc.1@1.6 +2 -2 + NTP_4_2_7P5 + + ntpq/ntpq-opts.c@1.6 +2 -2 + NTP_4_2_7P5 + + ntpq/ntpq-opts.h@1.6 +3 -3 + NTP_4_2_7P5 + + ntpq/ntpq-opts.texi@1.6 +1 -1 + NTP_4_2_7P5 + + ntpq/ntpq.1@1.6 +2 -2 + NTP_4_2_7P5 + + ntpsnmpd/ntpsnmpd-opts.c@1.6 +2 -2 + NTP_4_2_7P5 + + ntpsnmpd/ntpsnmpd-opts.h@1.6 +3 -3 + NTP_4_2_7P5 + + ntpsnmpd/ntpsnmpd-opts.texi@1.6 +1 -1 + NTP_4_2_7P5 + + ntpsnmpd/ntpsnmpd.1@1.6 +2 -2 + NTP_4_2_7P5 + + packageinfo.sh@1.7 +1 -1 + NTP_4_2_7P5 + + sntp/sntp-opts.c@1.6 +2 -2 + NTP_4_2_7P5 + + sntp/sntp-opts.h@1.6 +3 -3 + NTP_4_2_7P5 + + sntp/sntp-opts.texi@1.6 +1 -1 + NTP_4_2_7P5 + + sntp/sntp.1@1.6 +2 -2 + NTP_4_2_7P5 + + sntp/sntp.html@1.6 +1 -1 + NTP_4_2_7P5 + + util/ntp-keygen-opts.c@1.6 +2 -2 + NTP_4_2_7P5 + + util/ntp-keygen-opts.h@1.6 +3 -3 + NTP_4_2_7P5 + + util/ntp-keygen-opts.texi@1.6 +1 -1 + NTP_4_2_7P5 + + util/ntp-keygen.1@1.6 +2 -2 + NTP_4_2_7P5 + +ChangeSet@1.2082.4.28, 2009-12-25 09:31:42+00:00, stenn@whimsy.udel.edu + NTP_4_2_6P1_RC2 + TAG: NTP_4_2_6P1_RC2 + + ChangeLog@1.496.26.20 +1 -0 + NTP_4_2_6P1_RC2 + + ntpd/ntpd-opts.c@1.248.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpd/ntpd-opts.h@1.248.2.1 +3 -3 + NTP_4_2_6P1_RC2 + + ntpd/ntpd-opts.texi@1.246.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpd/ntpd.1@1.246.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpdc/ntpdc-opts.c@1.244.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpdc/ntpdc-opts.h@1.244.2.1 +3 -3 + NTP_4_2_6P1_RC2 + + ntpdc/ntpdc-opts.texi@1.243.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpdc/ntpdc.1@1.243.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpq/ntpq-opts.c@1.245.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpq/ntpq-opts.h@1.245.2.1 +3 -3 + NTP_4_2_6P1_RC2 + + ntpq/ntpq-opts.texi@1.244.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpq/ntpq.1@1.244.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.2.1 +3 -3 + NTP_4_2_6P1_RC2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + ntpsnmpd/ntpsnmpd.1@1.122.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + packageinfo.sh@1.255.4.1 +1 -1 + NTP_4_2_6P1_RC2 + + sntp/sntp-opts.c@1.117.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + sntp/sntp-opts.h@1.117.2.1 +3 -3 + NTP_4_2_6P1_RC2 + + sntp/sntp-opts.texi@1.117.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + sntp/sntp.1@1.117.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + sntp/sntp.html@1.7.2.1 +1 -1 + NTP_4_2_6P1_RC2 + + util/ntp-keygen-opts.c@1.247.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + util/ntp-keygen-opts.h@1.247.2.1 +3 -3 + NTP_4_2_6P1_RC2 + + util/ntp-keygen-opts.texi@1.246.2.1 +2 -2 + NTP_4_2_6P1_RC2 + + util/ntp-keygen.1@1.246.2.1 +2 -2 + NTP_4_2_6P1_RC2 + +ChangeSet@1.2082.13.1, 2009-12-25 00:19:40-05:00, stenn@whimsy.udel.edu + [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp + + ChangeLog@1.496.38.1 +1 -0 + [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp + + sntp/configure.ac@1.29.1.1 +3 -0 + [Bug 1435] sntp: Test for -lresolv using the same tests as in ntp + +ChangeSet@1.2082.4.26, 2009-12-24 22:04:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1425] unpeer by association ID sets up for duplicate free(). + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. + Use HAVE_WORKING_FORK instead of HAVE_FORK to avoid broken fork(). + + ChangeLog@1.496.26.18 +2 -0 + [Bug 1425] unpeer by association ID sets up for duplicate free(). + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. + + configure.ac@1.465.1.7 +50 -29 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. + + include/ntp_intres.h@1.2 +1 -1 + Use HAVE_WORKING_FORK instead of HAVE_FORK preemptively, some rare + systems have a broken fork() + + m4/os_cflags.m4@1.6 +2 -0 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. + + ntpd/ntp_config.c@1.241 +0 -2 + [Bug 1425] unpeer by association ID sets up for duplicate free(). + + ntpsnmpd/netsnmp_daemonize.c@1.1.1.1 +2 -2 + Use HAVE_WORKING_FORK instead of HAVE_FORK preemptively, some rare + systems have a broken fork() + + sntp/configure.ac@1.30 +53 -0 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. + + sntp/networking.c@1.29 +7 -1 + [Bug 1434] HP-UX 11 ip_mreq undeclared, _HPUX_SOURCE helps some. + +ChangeSet@1.2084.6.24, 2009-12-24 10:27:41+00:00, stenn@whimsy.udel.edu + NTP_4_2_7P4 + TAG: NTP_4_2_7P4 + + ChangeLog@1.501.1.18 +1 -0 + NTP_4_2_7P4 + + ntpd/ntpd-opts.c@1.5 +2 -2 + NTP_4_2_7P4 + + ntpd/ntpd-opts.h@1.5 +3 -3 + NTP_4_2_7P4 + + ntpd/ntpd-opts.texi@1.5 +1 -1 + NTP_4_2_7P4 + + ntpd/ntpd.1@1.5 +2 -2 + NTP_4_2_7P4 + + ntpdc/ntpdc-opts.c@1.5 +2 -2 + NTP_4_2_7P4 + + ntpdc/ntpdc-opts.h@1.5 +3 -3 + NTP_4_2_7P4 + + ntpdc/ntpdc-opts.texi@1.5 +1 -1 + NTP_4_2_7P4 + + ntpdc/ntpdc.1@1.5 +2 -2 + NTP_4_2_7P4 + + ntpq/ntpq-opts.c@1.5 +2 -2 + NTP_4_2_7P4 + + ntpq/ntpq-opts.h@1.5 +3 -3 + NTP_4_2_7P4 + + ntpq/ntpq-opts.texi@1.5 +1 -1 + NTP_4_2_7P4 + + ntpq/ntpq.1@1.5 +2 -2 + NTP_4_2_7P4 + + ntpsnmpd/ntpsnmpd-opts.c@1.5 +2 -2 + NTP_4_2_7P4 + + ntpsnmpd/ntpsnmpd-opts.h@1.5 +3 -3 + NTP_4_2_7P4 + + ntpsnmpd/ntpsnmpd-opts.texi@1.5 +1 -1 + NTP_4_2_7P4 + + ntpsnmpd/ntpsnmpd.1@1.5 +2 -2 + NTP_4_2_7P4 + + packageinfo.sh@1.6 +1 -1 + NTP_4_2_7P4 + + sntp/sntp-opts.c@1.5 +2 -2 + NTP_4_2_7P4 + + sntp/sntp-opts.h@1.5 +3 -3 + NTP_4_2_7P4 + + sntp/sntp-opts.texi@1.5 +1 -1 + NTP_4_2_7P4 + + sntp/sntp.1@1.5 +2 -2 + NTP_4_2_7P4 + + sntp/sntp.html@1.5 +1 -1 + NTP_4_2_7P4 + + util/ntp-keygen-opts.c@1.5 +2 -2 + NTP_4_2_7P4 + + util/ntp-keygen-opts.h@1.5 +3 -3 + NTP_4_2_7P4 + + util/ntp-keygen-opts.texi@1.5 +1 -1 + NTP_4_2_7P4 + + util/ntp-keygen.1@1.5 +2 -2 + NTP_4_2_7P4 + +ChangeSet@1.2084.6.23, 2009-12-24 07:42:08+00:00, davehart@shiny.ad.hartbrothers.com + Correct ChangeLog merge from stable + + ChangeLog@1.501.1.17 +2 -0 + Correct ChangeLog merge from stable + +ChangeSet@1.2082.12.1, 2009-12-24 02:27:39-05:00, stenn@deacon.udel.edu + System headers must come before ntp headers in ntp_intres.c + + ChangeLog@1.496.37.1 +1 -0 + System headers must come before ntp headers in ntp_intres.c + + include/Makefile.am@1.38 +1 -0 + System headers must come before ntp headers in ntp_intres.c + + include/ntp_config.h@1.66.1.1 +0 -10 + System headers must come before ntp headers in ntp_intres.c + + include/ntp_intres.h@1.1 +14 -0 + BitKeeper file /deacon/backroom/ntp-stable/include/ntp_intres.h + + include/ntp_intres.h@1.0 +0 -0 + + ntpd/ntp_config.c@1.238.1.1 +1 -0 + System headers must come before ntp headers in ntp_intres.c + + ntpd/ntp_intres.c@1.78 +10 -8 + System headers must come before ntp headers in ntp_intres.c + +ChangeSet@1.2082.4.24, 2009-12-23 11:01:44+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution + + ChangeLog@1.496.26.16 +1 -0 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution + + ntpd/cmd_args.c@1.56.1.1 +12 -5 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution + + ntpd/ntp_config.c@1.239 +2 -8 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution + + ntpd/ntp_scanner.h@1.15 +0 -1 + [Bug 1429] -4 command line option to ntpd does not reliably force IPv4 resolution + +ChangeSet@1.2084.1.16, 2009-12-22 12:10:14-05:00, murray@pogo.udel.edu + tg2.c: + Change mode to -rw-rw-r-- + + util/tg2.c@1.3, stenn@pogo.udel.edu +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.2084.6.20, 2009-12-22 05:29:27-05:00, stenn@whimsy.udel.edu + NTP_4_2_7P3 + TAG: NTP_4_2_7P3 + + ChangeLog@1.501.1.14 +1 -0 + NTP_4_2_7P3 + + ntpd/ntpd-opts.c@1.4 +2 -2 + NTP_4_2_7P3 + + ntpd/ntpd-opts.h@1.4 +3 -3 + NTP_4_2_7P3 + + ntpd/ntpd-opts.texi@1.4 +1 -1 + NTP_4_2_7P3 + + ntpd/ntpd.1@1.4 +2 -2 + NTP_4_2_7P3 + + ntpdc/ntpdc-opts.c@1.4 +2 -2 + NTP_4_2_7P3 + + ntpdc/ntpdc-opts.h@1.4 +3 -3 + NTP_4_2_7P3 + + ntpdc/ntpdc-opts.texi@1.4 +1 -1 + NTP_4_2_7P3 + + ntpdc/ntpdc.1@1.4 +2 -2 + NTP_4_2_7P3 + + ntpq/ntpq-opts.c@1.4 +2 -2 + NTP_4_2_7P3 + + ntpq/ntpq-opts.h@1.4 +3 -3 + NTP_4_2_7P3 + + ntpq/ntpq-opts.texi@1.4 +1 -1 + NTP_4_2_7P3 + + ntpq/ntpq.1@1.4 +2 -2 + NTP_4_2_7P3 + + ntpsnmpd/ntpsnmpd-opts.c@1.4 +2 -2 + NTP_4_2_7P3 + + ntpsnmpd/ntpsnmpd-opts.h@1.4 +3 -3 + NTP_4_2_7P3 + + ntpsnmpd/ntpsnmpd-opts.texi@1.4 +1 -1 + NTP_4_2_7P3 + + ntpsnmpd/ntpsnmpd.1@1.4 +2 -2 + NTP_4_2_7P3 + + packageinfo.sh@1.5 +1 -1 + NTP_4_2_7P3 + + sntp/sntp-opts.c@1.4 +2 -2 + NTP_4_2_7P3 + + sntp/sntp-opts.h@1.4 +3 -3 + NTP_4_2_7P3 + + sntp/sntp-opts.texi@1.4 +1 -1 + NTP_4_2_7P3 + + sntp/sntp.1@1.4 +2 -2 + NTP_4_2_7P3 + + sntp/sntp.html@1.4 +1 -1 + NTP_4_2_7P3 + + util/ntp-keygen-opts.c@1.4 +2 -2 + NTP_4_2_7P3 + + util/ntp-keygen-opts.h@1.4 +3 -3 + NTP_4_2_7P3 + + util/ntp-keygen-opts.texi@1.4 +1 -1 + NTP_4_2_7P3 + + util/ntp-keygen.1@1.4 +2 -2 + NTP_4_2_7P3 + +ChangeSet@1.2082.4.23, 2009-12-22 08:36:49+00:00, hart@psp-deb1.ntp.org + UpdatePoint: + correct handling of beta-free stable RC bumps + + scripts/UpdatePoint@1.4 +15 -7 + correct handling of beta-free stable RC bumps + +ChangeSet@1.2082.4.22, 2009-12-22 03:00:22-05:00, stenn@whimsy.udel.edu + [Bug 1424] Fix check for rtattr (rtnetlink.h) + + ChangeLog@1.496.26.15 +1 -0 + [Bug 1424] Fix check for rtattr (rtnetlink.h) + + configure.ac@1.465.1.6 +1 -0 + [Bug 1424] Fix check for rtattr (rtnetlink.h) + +ChangeSet@1.2082.4.21, 2009-12-22 02:52:08-05:00, stenn@whimsy.udel.edu + [Bug 1416] MAXDNAME undefined on Solaris 2.6 + + ChangeLog@1.496.26.14 +1 -0 + [Bug 1416] MAXDNAME undefined on Solaris 2.6 + +ChangeSet@1.2082.4.20, 2009-12-22 02:29:35-05:00, stenn@whimsy.udel.edu + Bootstrap script should also touch .html files + + bootstrap@1.28.1.1 +1 -1 + Bootstrap script should also touch .html files + +ChangeSet@1.2082.4.19, 2009-12-22 02:26:26-05:00, stenn@whimsy.udel.edu + [Bug 1411] Fix status messages in refclock_oncore.c + + ChangeLog@1.496.26.13 +1 -0 + [Bug 1411] Fix status messages in refclock_oncore.c + + ntpd/refclock_oncore.c@1.82 +31 -8 + [Bug 1411] Fix status messages in refclock_oncore.c + +ChangeSet@1.2082.4.18, 2009-12-22 04:15:31+00:00, davehart@shiny.ad.hartbrothers.com + bring Windows mkver.bat in line with packaginfo.sh and + scripts/VersionName changes + + ports/winnt/scripts/mkver.bat@1.12 +14 -11 + bring Windows mkver.bat in line with packaginfo.sh and + scripts/VersionName changes + +ChangeSet@1.2082.11.1, 2009-12-22 00:55:19+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h + + ChangeLog@1.496.36.1 +4 -0 + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h + + configure.ac@1.465.1.4 +1 -0 + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h + + ntpd/ntp_intres.c@1.77 +16 -3 + [Bug 1428] Use AC_HEADER_RESOLV to fix breaks from resolv.h + changes include of resolv.h to match Autoconf doc suggestion + +ChangeSet@1.2082.4.15, 2009-12-21 06:26:25+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1427] quote missing in ./build - shows up on NetBSD. + + ChangeLog@1.496.26.10 +1 -0 + [Bug 1427] quote missing in ./build - shows up on NetBSD. + + build@1.33 +1 -1 + [Bug 1427] quote missing in ./build - shows up on NetBSD. + +ChangeSet@1.2082.4.14, 2009-12-21 05:19:15+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1426] scripts/VersionName needs . on the search path. + correct permissions to 0775 for scripts/UpdatePoint. + + ChangeLog@1.496.26.9 +4 -0 + [Bug 1426] scripts/VersionName needs . on the search path. + + scripts/UpdatePoint@1.3 +2 -2 + work correctly without . on $PATH + + scripts/UpdatePoint@1.2 +0 -0 + Change mode to -rwxrwxr-x + + scripts/VersionName@1.6 +3 -3 + [Bug 1426] scripts/VersionName needs . on the search path. + +ChangeSet@1.2084.6.13, 2009-12-20 05:29:12-05:00, stenn@whimsy.udel.edu + NTP_4_2_7P2 + TAG: NTP_4_2_7P2 + + ChangeLog@1.501.1.9 +1 -0 + NTP_4_2_7P2 + + ntpd/ntpd-opts.c@1.3 +2 -2 + NTP_4_2_7P2 + + ntpd/ntpd-opts.h@1.3 +3 -3 + NTP_4_2_7P2 + + ntpd/ntpd-opts.texi@1.3 +1 -1 + NTP_4_2_7P2 + + ntpd/ntpd.1@1.3 +2 -2 + NTP_4_2_7P2 + + ntpdc/ntpdc-opts.c@1.3 +2 -2 + NTP_4_2_7P2 + + ntpdc/ntpdc-opts.h@1.3 +3 -3 + NTP_4_2_7P2 + + ntpdc/ntpdc-opts.texi@1.3 +1 -1 + NTP_4_2_7P2 + + ntpdc/ntpdc.1@1.3 +2 -2 + NTP_4_2_7P2 + + ntpq/ntpq-opts.c@1.3 +2 -2 + NTP_4_2_7P2 + + ntpq/ntpq-opts.h@1.3 +3 -3 + NTP_4_2_7P2 + + ntpq/ntpq-opts.texi@1.3 +1 -1 + NTP_4_2_7P2 + + ntpq/ntpq.1@1.3 +2 -2 + NTP_4_2_7P2 + + ntpsnmpd/ntpsnmpd-opts.c@1.3 +2 -2 + NTP_4_2_7P2 + + ntpsnmpd/ntpsnmpd-opts.h@1.3 +3 -3 + NTP_4_2_7P2 + + ntpsnmpd/ntpsnmpd-opts.texi@1.3 +1 -1 + NTP_4_2_7P2 + + ntpsnmpd/ntpsnmpd.1@1.3 +2 -2 + NTP_4_2_7P2 + + packageinfo.sh@1.4 +1 -1 + NTP_4_2_7P2 + + sntp/sntp-opts.c@1.3 +2 -2 + NTP_4_2_7P2 + + sntp/sntp-opts.h@1.3 +3 -3 + NTP_4_2_7P2 + + sntp/sntp-opts.texi@1.3 +1 -1 + NTP_4_2_7P2 + + sntp/sntp.1@1.3 +2 -2 + NTP_4_2_7P2 + + sntp/sntp.html@1.3 +1 -1 + NTP_4_2_7P2 + + util/ntp-keygen-opts.c@1.3 +2 -2 + NTP_4_2_7P2 + + util/ntp-keygen-opts.h@1.3 +3 -3 + NTP_4_2_7P2 + + util/ntp-keygen-opts.texi@1.3 +1 -1 + NTP_4_2_7P2 + + util/ntp-keygen.1@1.3 +2 -2 + NTP_4_2_7P2 + +ChangeSet@1.2084.6.11, 2009-12-20 01:04:33-05:00, stenn@whimsy.udel.edu + Touch any html file from autogen + + bootstrap@1.29 +1 -1 + Touch any html file from autogen + +ChangeSet@1.2082.4.13, 2009-12-20 00:52:48-05:00, stenn@whimsy.udel.edu + NTP_4_2_6P1_RC1 + TAG: NTP_4_2_6P1_RC1 + + ChangeLog@1.496.26.8 +1 -0 + NTP_4_2_6P1_RC1 + + ntpd/ntpd-opts.c@1.248.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpd/ntpd-opts.h@1.248.1.1 +3 -3 + NTP_4_2_6P1_RC1 + + ntpd/ntpd-opts.texi@1.246.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpd/ntpd.1@1.246.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpdc/ntpdc-opts.c@1.244.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpdc/ntpdc-opts.h@1.244.1.1 +3 -3 + NTP_4_2_6P1_RC1 + + ntpdc/ntpdc-opts.texi@1.243.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpdc/ntpdc.1@1.243.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpq/ntpq-opts.c@1.245.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpq/ntpq-opts.h@1.245.1.1 +3 -3 + NTP_4_2_6P1_RC1 + + ntpq/ntpq-opts.texi@1.244.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpq/ntpq.1@1.244.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpsnmpd/ntpsnmpd-opts.c@1.123.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpsnmpd/ntpsnmpd-opts.h@1.123.1.1 +3 -3 + NTP_4_2_6P1_RC1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + ntpsnmpd/ntpsnmpd.1@1.122.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + packageinfo.sh@1.255.3.1 +2 -2 + NTP_4_2_6P1_RC1 + + sntp/sntp-opts.c@1.117.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + sntp/sntp-opts.h@1.117.1.1 +3 -3 + NTP_4_2_6P1_RC1 + + sntp/sntp-opts.texi@1.117.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + sntp/sntp.1@1.117.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + sntp/sntp.html@1.7.1.1 +1 -1 + NTP_4_2_6P1_RC1 + + util/ntp-keygen-opts.c@1.247.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + util/ntp-keygen-opts.h@1.247.1.1 +3 -3 + NTP_4_2_6P1_RC1 + + util/ntp-keygen-opts.texi@1.246.1.1 +2 -2 + NTP_4_2_6P1_RC1 + + util/ntp-keygen.1@1.246.1.1 +2 -2 + NTP_4_2_6P1_RC1 + +ChangeSet@1.2082.4.12, 2009-12-19 23:55:09-05:00, stenn@pogo.udel.edu + Put refclock_neoclock4x.c under the NTP COPYRIGHT + + ChangeLog@1.496.26.7 +4 -0 + Put refclock_neoclock4x.c under the NTP COPYRIGHT + + html/copyright.html@1.45 +1 -0 + Put refclock_neoclock4x.c under the NTP COPYRIGHT + + ntpd/refclock_neoclock4x.c@1.17 +20 -9 + Put refclock_neoclock4x.c under the NTP COPYRIGHT + +ChangeSet@1.2082.4.11, 2009-12-19 22:05:09-05:00, stenn@whimsy.udel.edu + Start the 4.2.6p1-RC cycle + + packageinfo.sh@1.255.2.1 +14 -1 + Start the 4.2.6p1-RC cycle + +ChangeSet@1.2082.4.10, 2009-12-19 21:47:40-05:00, stenn@whimsy.udel.edu + [Bug 1415] Fix Mac OS X link problem + + ChangeLog@1.496.26.6 +1 -0 + [Bug 1415] Fix Mac OS X link problem + + configure.ac@1.465.1.3 +5 -0 + [Bug 1415] Fix Mac OS X link problem + + ntpsnmpd/Makefile.am@1.15.1.1 +1 -1 + [Bug 1415] Fix Mac OS X link problem + +ChangeSet@1.2060.25.1, 2009-12-19 03:29:38+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1395] ease ntpdate elimination with ntpd -w/--wait-sync + [Bug 1396] allow servers on ntpd command line like ntpdate + + ChangeLog@1.496.35.1 +2 -0 + [Bug 1395] ease ntpdate elimination with ntpd -w/--wait-sync + [Bug 1396] allow servers on ntpd command line like ntpdate + + include/ntp_config.h@1.67 +5 -1 + [Bug 1396] allow servers on ntpd command line like ntpdate + + include/ntp_machine.h@1.27 +0 -2 + remove NODETACH, nptd uses HAVE_WORKING_FORK instead + + include/ntp_proto.h@1.5 +3 -3 + stay out of system/compiler underscore namespace + + include/ntpd.h@1.138 +5 -1 + add waitsync_fd_to_close from ntpd.c + + include/ntpsim.h@1.13 +0 -1 + remove no-longer-used SLEW which conflicted with autoopts over -x/--slew + + ntpd/Makefile.am@1.78.1.1 +1 -1 + cmd_args.c no longer differs between SIM and !SIM + + ntpd/cmd_args.c@1.57 +18 -19 + [Bug 1396] allow servers on ntpd command line like ntpdate + + ntpd/ntp_config.c@1.237.1.1 +65 -22 + [Bug 1396] allow servers on ntpd command line like ntpdate + + ntpd/ntp_loopfilter.c@1.154 +7 -7 + comment typo corrections, leading tabs cleanup, msyslog + "kernel time sync disabledx" + excess 'x' excised. + + ntpd/ntp_proto.c@1.298 +21 -3 + [Bug 1396] allow servers on ntpd command line like ntpdate + + ntpd/ntpd-opts.c@1.242.1.1 +97 -20 + Autogen output + + ntpd/ntpd-opts.def@1.6 +3 -2 + [Bug 1396] allow servers on ntpd command line like ntpdate + + ntpd/ntpd-opts.h@1.242.1.1 +18 -11 + Autogen output + + ntpd/ntpd-opts.texi@1.240.1.1 +72 -8 + Autogen output + + ntpd/ntpd.1@1.240.1.1 +28 -6 + Autogen output + + ntpd/ntpd.c@1.111 +440 -309 + [Bug 1395] ease ntpdate elimination with ntpd -w/--wait-sync + + ntpd/ntpdbase-opts.def@1.21 +34 -2 + [Bug 1395] ease ntpdate elimination with ntpd -w/--wait-sync + + ntpsnmpd/netsnmp_daemonize.c@1.2 +7 -3 + HAVE_WORKING_FORK is more appropriate than HAVE_FORK here + +ChangeSet@1.2084.1.15, 2009-12-18 03:39:13-05:00, murray@pogo.udel.edu + ChangeLog: + Add bug number to tg2 comment + + ChangeLog@1.503 +1 -1 + Add bug number to tg2 comment + +ChangeSet@1.2082.10.1, 2009-12-18 05:18:12+00:00, davehart@shiny.ad.hartbrothers.com + correct NTP_OS_CFLAGS [Bug 1412] + allow $CC to contain slash and space in build + + build@1.32 +3 -3 + allow space and slash in $CC without breaking build/flock-build + + m4/os_cflags.m4@1.5 +90 -93 + the name of the macro to define must be on the same line as AC_DEFUN( + +ChangeSet@1.2084.6.5, 2009-12-17 09:17:17+00:00, davehart@shiny.ad.hartbrothers.com + correct ChangeLog merge from ntp-stable-updatepoint + + ChangeLog@1.501.1.4 +1 -3 + correct ChangeLog merge from ntp-stable-updatepoint + +ChangeSet@1.2084.6.4, 2009-12-17 08:27:16+00:00, davehart@shiny.ad.hartbrothers.com + scripts/UpdatePoint changes to packageinfo.sh's -dev copy + adds support for beta releases in ntp-stable + + packageinfo.sh@1.3 +68 -15 + scripts/UpdatePoint changes to packageinfo.sh's -dev copy + adds support for beta releases in ntp-stable + +ChangeSet@1.2084.6.2, 2009-12-17 04:25:31+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + correct ChangeLog merge from ntp-stable-1419, bk remerge/fm3tool hates me + + ChangeLog@1.501.1.2 +1 -3 + correct ChangeLog merge from ntp-stable-1419, bk remerge/fm3tool hates me + +ChangeSet@1.2084.1.14, 2009-12-16 21:00:16-05:00, murray@malarky.udel.edu + tg2.c: + Fix warnings on Solaris. + + util/tg2.c@1.2 +4 -2 + Fix warnings on Solaris. + +ChangeSet@1.2082.9.1, 2009-12-16 21:26:45+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + ChangeLog@1.496.34.1 +4 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + adjtimed/Makefile.am@1.7 +5 -1 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + bincheck.mf@1.3 +5 -5 + respect $bindir, $sbindir instead of assuming $exec_prefix/$BINSUBDIR + + configure.ac@1.465.3.1 +2 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + ntpd/Makefile.am@1.79.2.1 +4 -2 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + ntpdate/Makefile.am@1.23 +6 -2 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + ntpdc/Makefile.am@1.47.1.1 +5 -1 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + ntpq/Makefile.am@1.42.1.1 +4 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + ntpsnmpd/Makefile.am@1.16 +5 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + scripts/Makefile.am@1.16.1.1 +4 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + sntp/Makefile.am@1.20.1.1 +5 -1 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + sntp/configure.ac@1.29 +2 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + + util/Makefile.am@1.45.1.1 +6 -0 + [Bug 1419] ntpdate, ntpdc, sntp, ntpd ignore configure --bindir. + +ChangeSet@1.2082.8.1, 2009-12-16 20:21:10+00:00, davehart@shiny.ad.hartbrothers.com + updated packageinfo.sh, VersionName, and UpdatePoint to use prerelease= + from packageinfo.sh instead of releasecandidate= and added support for + beta releases. + + ChangeLog@1.496.33.1 +4 -0 + Build infrastructure updates to enable beta releases of ntp-stable. + + packageinfo.sh@1.255.1.3 +69 -16 + updated to use prerelease= instead of releasecandidate=, with support + for prerelease=beta for ntp-stable pre-RC1 test releases + + scripts/Makefile.am@1.17 +36 -5 + reformat, add UpdatePoint to EXTRA_DIST + + scripts/UpdatePoint@1.1 +323 -0 + updated to use prerelease= from packageinfo.sh instead of releasecandidate= + added support for beta releases + + scripts/UpdatePoint@1.0 +0 -0 + + scripts/VersionName@1.5 +32 -18 + updated to use prerelease= from packageinfo.sh instead of releasecandidate= + added support for beta releases + +ChangeSet@1.2084.1.12, 2009-12-15 05:28:39-05:00, stenn@whimsy.udel.edu + NTP_4_2_7P1 + TAG: NTP_4_2_7P1 + + ChangeLog@1.501 +1 -0 + NTP_4_2_7P1 + + ntpd/ntpd-opts.c@1.2 +2 -2 + NTP_4_2_7P1 + + ntpd/ntpd-opts.h@1.2 +3 -3 + NTP_4_2_7P1 + + ntpd/ntpd-opts.texi@1.2 +1 -1 + NTP_4_2_7P1 + + ntpd/ntpd.1@1.2 +2 -2 + NTP_4_2_7P1 + + ntpdc/ntpdc-opts.c@1.2 +2 -2 + NTP_4_2_7P1 + + ntpdc/ntpdc-opts.h@1.2 +3 -3 + NTP_4_2_7P1 + + ntpdc/ntpdc-opts.texi@1.2 +1 -1 + NTP_4_2_7P1 + + ntpdc/ntpdc.1@1.2 +2 -2 + NTP_4_2_7P1 + + ntpq/ntpq-opts.c@1.2 +2 -2 + NTP_4_2_7P1 + + ntpq/ntpq-opts.h@1.2 +3 -3 + NTP_4_2_7P1 + + ntpq/ntpq-opts.texi@1.2 +1 -1 + NTP_4_2_7P1 + + ntpq/ntpq.1@1.2 +2 -2 + NTP_4_2_7P1 + + ntpsnmpd/ntpsnmpd-opts.c@1.2 +2 -2 + NTP_4_2_7P1 + + ntpsnmpd/ntpsnmpd-opts.h@1.2 +3 -3 + NTP_4_2_7P1 + + ntpsnmpd/ntpsnmpd-opts.texi@1.2 +1 -1 + NTP_4_2_7P1 + + ntpsnmpd/ntpsnmpd.1@1.2 +2 -2 + NTP_4_2_7P1 + + packageinfo.sh@1.2 +1 -1 + NTP_4_2_7P1 + + sntp/sntp-opts.c@1.2 +2 -2 + NTP_4_2_7P1 + + sntp/sntp-opts.h@1.2 +3 -3 + NTP_4_2_7P1 + + sntp/sntp-opts.texi@1.2 +1 -1 + NTP_4_2_7P1 + + sntp/sntp.1@1.2 +2 -2 + NTP_4_2_7P1 + + sntp/sntp.html@1.2 +1 -1 + NTP_4_2_7P1 + + util/ntp-keygen-opts.c@1.2 +2 -2 + NTP_4_2_7P1 + + util/ntp-keygen-opts.h@1.2 +3 -3 + NTP_4_2_7P1 + + util/ntp-keygen-opts.texi@1.2 +1 -1 + NTP_4_2_7P1 + + util/ntp-keygen.1@1.2 +2 -2 + NTP_4_2_7P1 + +ChangeSet@1.2084.5.2, 2009-12-14 21:45:36+00:00, davehart@shiny.ad.hartbrothers.com + Correct ChangeLog merge from ntp-stable-1418 + + ChangeLog@1.496.32.2 +1 -3 + Correct ChangeLog merge from ntp-stable-1418 + +ChangeSet@1.2082.7.1, 2009-12-14 21:18:10+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1418] building ntpd/ntpdc/ntpq statically with ssl fails. + + ChangeLog@1.496.31.1 +4 -0 + [Bug 1418] building ntpd/ntpdc/ntpq statically with ssl fails. + + ntpd/Makefile.am@1.79.1.1 +2 -2 + move libntp.a ahead of @LCRYPTO@ to fix static openssl link + + ntpdc/Makefile.am@1.48 +2 -2 + move libntp.a ahead of @LCRYPTO@ to fix static openssl link + + ntpq/Makefile.am@1.43 +2 -2 + move libntp.a ahead of @LCRYPTO@ to fix static openssl link + +ChangeSet@1.2084.1.9, 2009-12-14 02:51:13+00:00, davehart@shiny.ad.hartbrothers.com + correct merge of [Bug 1413] ChangeLog line from ntp-stable-1413 + + ChangeLog@1.496.25.7 +1 -3 + correct merge of [Bug 1413] line from ntp-stable-1413 + +ChangeSet@1.2084.4.2, 2009-12-14 02:32:16+00:00, davehart@shiny.ad.hartbrothers.com + transmitbuff.h is gone + + ntpd/ntp_io.c@1.309 +0 -1 + transmitbuff.h is gone + + ports/winnt/ntpd/ntp_iocompletionport.c@1.51 +0 -1 + transmitbuff.h is gone + +ChangeSet@1.2084.1.8, 2009-12-13 21:05:40+00:00, davehart@shiny.ad.hartbrothers.com + bk rm 4.2.6 version-dependent files, bk new identical replacements + + BitKeeper/deleted/.del-ntp-keygen-opts.c~d0a1ce0533b25b2@1.250 +0 -0 + Delete: util/ntp-keygen-opts.c + + BitKeeper/deleted/.del-ntp-keygen-opts.h~f0717b94e4446b26@1.250 +0 -0 + Delete: util/ntp-keygen-opts.h + + BitKeeper/deleted/.del-ntp-keygen-opts.texi~8c66011d5d8b8946@1.249 +0 -0 + Delete: util/ntp-keygen-opts.texi + + BitKeeper/deleted/.del-ntp-keygen.1~5f9bc1fd9c40085a@1.249 +0 -0 + Delete: util/ntp-keygen.1 + + BitKeeper/deleted/.del-ntpd-opts.c~144b52caa1ef699c@1.251 +0 -0 + Delete: ntpd/ntpd-opts.c + + BitKeeper/deleted/.del-ntpd-opts.h~2b00d71c3cee10a7@1.251 +0 -0 + Delete: ntpd/ntpd-opts.h + + BitKeeper/deleted/.del-ntpd-opts.texi~9cb5bac4bf6450c1@1.249 +0 -0 + Delete: ntpd/ntpd-opts.texi + + BitKeeper/deleted/.del-ntpd.1~28d9b05264c45059@1.249 +0 -0 + Delete: ntpd/ntpd.1 + + BitKeeper/deleted/.del-ntpdc-opts.c~58e4a492bd134fb8@1.247 +0 -0 + Delete: ntpdc/ntpdc-opts.c + + BitKeeper/deleted/.del-ntpdc-opts.h~b31c10ed4f5c2052@1.247 +0 -0 + Delete: ntpdc/ntpdc-opts.h + + BitKeeper/deleted/.del-ntpdc-opts.texi~5fe1056039fe6e4f@1.246 +0 -0 + Delete: ntpdc/ntpdc-opts.texi + + BitKeeper/deleted/.del-ntpdc.1~574c84f3f3e91d36@1.246 +0 -0 + Delete: ntpdc/ntpdc.1 + + BitKeeper/deleted/.del-ntpq-opts.c~e22ebc44f822119e@1.248 +0 -0 + Delete: ntpq/ntpq-opts.c + + BitKeeper/deleted/.del-ntpq-opts.h~bebfd8975972779e@1.248 +0 -0 + Delete: ntpq/ntpq-opts.h + + BitKeeper/deleted/.del-ntpq-opts.texi~fd912c16181424e@1.247 +0 -0 + Delete: ntpq/ntpq-opts.texi + + BitKeeper/deleted/.del-ntpq.1~abfc5609a4b9cf4d@1.247 +0 -0 + Delete: ntpq/ntpq.1 + + BitKeeper/deleted/.del-ntpsnmpd-opts.c~8c4453f3336dd4b7@1.126 +0 -0 + Delete: ntpsnmpd/ntpsnmpd-opts.c + + BitKeeper/deleted/.del-ntpsnmpd-opts.h~59291b93d938a895@1.126 +0 -0 + Delete: ntpsnmpd/ntpsnmpd-opts.h + + BitKeeper/deleted/.del-ntpsnmpd-opts.texi~4cc265b9fc7e692d@1.126 +0 -0 + Delete: ntpsnmpd/ntpsnmpd-opts.texi + + BitKeeper/deleted/.del-ntpsnmpd.1~489dddca797b117c@1.125 +0 -0 + Delete: ntpsnmpd/ntpsnmpd.1 + + BitKeeper/deleted/.del-packageinfo.sh~ff4c82dd98fc4a4@1.260 +0 -0 + Delete: packageinfo.sh + + BitKeeper/deleted/.del-sntp-opts.c~134d906c1bc0bd88@1.120 +0 -0 + Delete: sntp/sntp-opts.c + + BitKeeper/deleted/.del-sntp-opts.h~5df6f04e80275ab3@1.120 +0 -0 + Delete: sntp/sntp-opts.h + + BitKeeper/deleted/.del-sntp-opts.texi~313e154133ec6f3c@1.120 +0 -0 + Delete: sntp/sntp-opts.texi + + BitKeeper/deleted/.del-sntp.1~4b2813589f2f7814@1.120 +0 -0 + Delete: sntp/sntp.1 + + BitKeeper/deleted/.del-sntp.html~ca24a75c4b6cb914@1.10 +0 -0 + Delete: sntp/sntp.html + + ntpd/ntpd-opts.c@1.1 +1144 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpd/ntpd-opts.c + + ntpd/ntpd-opts.c@1.0 +0 -0 + + ntpd/ntpd-opts.h@1.1 +385 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpd/ntpd-opts.h + + ntpd/ntpd-opts.h@1.0 +0 -0 + + ntpd/ntpd-opts.texi@1.1 +529 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpd/ntpd-opts.texi + + ntpd/ntpd-opts.texi@1.0 +0 -0 + + ntpd/ntpd.1@1.1 +338 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpd/ntpd.1 + + ntpd/ntpd.1@1.0 +0 -0 + + ntpdc/ntpdc-opts.c@1.1 +656 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpdc/ntpdc-opts.c + + ntpdc/ntpdc-opts.c@1.0 +0 -0 + + ntpdc/ntpdc-opts.h@1.1 +235 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpdc/ntpdc-opts.h + + ntpdc/ntpdc-opts.h@1.0 +0 -0 + + ntpdc/ntpdc-opts.texi@1.1 +212 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpdc/ntpdc-opts.texi + + ntpdc/ntpdc-opts.texi@1.0 +0 -0 + + ntpdc/ntpdc.1@1.1 +160 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpdc/ntpdc.1 + + ntpdc/ntpdc.1@1.0 +0 -0 + + ntpq/ntpq-opts.c@1.1 +623 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpq/ntpq-opts.c + + ntpq/ntpq-opts.c@1.0 +0 -0 + + ntpq/ntpq-opts.h@1.1 +228 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpq/ntpq-opts.h + + ntpq/ntpq-opts.h@1.0 +0 -0 + + ntpq/ntpq-opts.texi@1.1 +182 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpq/ntpq-opts.texi + + ntpq/ntpq-opts.texi@1.0 +0 -0 + + ntpq/ntpq.1@1.1 +398 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpq/ntpq.1 + + ntpq/ntpq.1@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd-opts.c@1.1 +408 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpsnmpd/ntpsnmpd-opts.c + + ntpsnmpd/ntpsnmpd-opts.c@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd-opts.h@1.1 +179 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpsnmpd/ntpsnmpd-opts.h + + ntpsnmpd/ntpsnmpd-opts.h@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd-opts.texi@1.1 +52 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpsnmpd/ntpsnmpd-opts.texi + + ntpsnmpd/ntpsnmpd-opts.texi@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.1@1.1 +77 -0 + BitKeeper file C:/ntp/ntp-dev-1413/ntpsnmpd/ntpsnmpd.1 + + ntpsnmpd/ntpsnmpd.1@1.0 +0 -0 + + packageinfo.sh@1.1 +28 -0 + BitKeeper file C:/ntp/ntp-dev-1413/packageinfo.sh + + packageinfo.sh@1.0 +0 -0 + + sntp/sntp-opts.c@1.1 +661 -0 + BitKeeper file C:/ntp/ntp-dev-1413/sntp/sntp-opts.c + + sntp/sntp-opts.c@1.0 +0 -0 + + sntp/sntp-opts.h@1.1 +253 -0 + BitKeeper file C:/ntp/ntp-dev-1413/sntp/sntp-opts.h + + sntp/sntp-opts.h@1.0 +0 -0 + + sntp/sntp-opts.texi@1.1 +218 -0 + BitKeeper file C:/ntp/ntp-dev-1413/sntp/sntp-opts.texi + + sntp/sntp-opts.texi@1.0 +0 -0 + + sntp/sntp.1@1.1 +214 -0 + BitKeeper file C:/ntp/ntp-dev-1413/sntp/sntp.1 + + sntp/sntp.1@1.0 +0 -0 + + sntp/sntp.html@1.1 +105 -0 + BitKeeper file C:/ntp/ntp-dev-1413/sntp/sntp.html + + sntp/sntp.html@1.0 +0 -0 + + util/ntp-keygen-opts.c@1.1 +981 -0 + BitKeeper file C:/ntp/ntp-dev-1413/util/ntp-keygen-opts.c + + util/ntp-keygen-opts.c@1.0 +0 -0 + + util/ntp-keygen-opts.h@1.1 +303 -0 + BitKeeper file C:/ntp/ntp-dev-1413/util/ntp-keygen-opts.h + + util/ntp-keygen-opts.h@1.0 +0 -0 + + util/ntp-keygen-opts.texi@1.1 +319 -0 + BitKeeper file C:/ntp/ntp-dev-1413/util/ntp-keygen-opts.texi + + util/ntp-keygen-opts.texi@1.0 +0 -0 + + util/ntp-keygen.1@1.1 +189 -0 + BitKeeper file C:/ntp/ntp-dev-1413/util/ntp-keygen.1 + + util/ntp-keygen.1@1.0 +0 -0 + +ChangeSet@1.2082.6.1, 2009-12-13 19:45:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1413] test OpenSSL headers regarding -Wno-strict-prototypes. + + ChangeLog@1.496.30.1 +4 -0 + [Bug 1413] test OpenSSL headers regarding -Wno-strict-prototypes. + + configure.ac@1.465.2.1 +52 -10 + [Bug 1413] test OpenSSL headers to see if they trigger warnings before + enablng -Wno-strict-prototypes for gcc. + -Wall does not include -Wstrict-prototypes, so add it expclitly. + +ChangeSet@1.2084.1.6, 2009-12-13 05:28:33-05:00, stenn@whimsy.udel.edu + NTP_4_2_7P0 + TAG: NTP_4_2_7P0 + + ChangeLog@1.496.25.5 +1 -0 + NTP_4_2_7P0 + + ntpd/ntpd-opts.c@1.250 +2 -2 + NTP_4_2_7P0 + + ntpd/ntpd-opts.h@1.250 +3 -3 + NTP_4_2_7P0 + + ntpd/ntpd-opts.texi@1.248 +1 -1 + NTP_4_2_7P0 + + ntpd/ntpd.1@1.248 +2 -2 + NTP_4_2_7P0 + + ntpdc/ntpdc-opts.c@1.246 +2 -2 + NTP_4_2_7P0 + + ntpdc/ntpdc-opts.h@1.246 +3 -3 + NTP_4_2_7P0 + + ntpdc/ntpdc-opts.texi@1.245 +1 -1 + NTP_4_2_7P0 + + ntpdc/ntpdc.1@1.245 +2 -2 + NTP_4_2_7P0 + + ntpq/ntpq-opts.c@1.247 +2 -2 + NTP_4_2_7P0 + + ntpq/ntpq-opts.h@1.247 +3 -3 + NTP_4_2_7P0 + + ntpq/ntpq-opts.texi@1.246 +1 -1 + NTP_4_2_7P0 + + ntpq/ntpq.1@1.246 +2 -2 + NTP_4_2_7P0 + + ntpsnmpd/ntpsnmpd-opts.c@1.125 +2 -2 + NTP_4_2_7P0 + + ntpsnmpd/ntpsnmpd-opts.h@1.125 +3 -3 + NTP_4_2_7P0 + + ntpsnmpd/ntpsnmpd-opts.texi@1.125 +1 -1 + NTP_4_2_7P0 + + ntpsnmpd/ntpsnmpd.1@1.124 +2 -2 + NTP_4_2_7P0 + + packageinfo.sh@1.259 +1 -1 + NTP_4_2_7P0 + + sntp/sntp-opts.c@1.119 +2 -2 + NTP_4_2_7P0 + + sntp/sntp-opts.h@1.119 +3 -3 + NTP_4_2_7P0 + + sntp/sntp-opts.texi@1.119 +1 -1 + NTP_4_2_7P0 + + sntp/sntp.1@1.119 +2 -2 + NTP_4_2_7P0 + + sntp/sntp.html@1.9 +1 -1 + NTP_4_2_7P0 + + util/ntp-keygen-opts.c@1.249 +2 -2 + NTP_4_2_7P0 + + util/ntp-keygen-opts.h@1.249 +3 -3 + NTP_4_2_7P0 + + util/ntp-keygen-opts.texi@1.248 +1 -1 + NTP_4_2_7P0 + + util/ntp-keygen.1@1.248 +2 -2 + NTP_4_2_7P0 + +ChangeSet@1.2084.3.2, 2009-12-13 04:45:48-05:00, murray@malarky.udel.edu + README: + Add a few words about tg and tg2. + + util/README@1.5 +7 -0 + Add a few words about tg and tg2. + +ChangeSet@1.2084.3.1, 2009-12-13 03:23:02-05:00, murray@malarky.udel.edu + configure.ac: + comment for Bug 254 + ChangeLog: + Adding tg2.c + tg2.c: + BitKeeper file /m/pogo/users/murray/tg2/util/tg2.c + Makefile.am: + Adding tg2 + + ChangeLog@1.496.29.1 +1 -0 + Adding tg2.c + + configure.ac@1.466.1.1 +1 -1 + comment for Bug 254 + + util/Makefile.am@1.46 +2 -1 + Adding tg2 + + util/tg2.c@1.1 +2499 -0 + BitKeeper file /m/pogo/users/murray/tg2/util/tg2.c + + util/tg2.c@1.0 +0 -0 + +ChangeSet@1.2084.2.2, 2009-12-13 05:10:51+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + correct merge from ntp-stable-1412 + + ChangeLog@1.496.28.2 +1 -4 + correct merge from ntp-stable-1412 + +ChangeSet@1.2084.1.4, 2009-12-13 04:18:43+00:00, davehart@shiny.ad.hartbrothers.com + correct merge from ntp-stable-1414 + + ChangeLog@1.496.25.3 +1 -4 + correct merge from ntp-stable-1414 + +ChangeSet@1.2082.5.1, 2009-12-12 19:55:30+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1414] Enable "make distcheck" success with BSD make. + + ChangeLog@1.496.27.1 +4 -0 + [Bug 1414] Enable "make distcheck" success with BSD make. + + libparse/Makefile.am@1.17 +23 -22 + add info_trimble.c to CLEANFILES [Bug 1414]. + remove references to $U leftover from ansi2knr use. + + ntpd/Makefile.am@1.80 +18 -4 + remove $VPHACK and $VPHACK_AFTER from EXTRA_DIST [Bug 1414] + + sntp/Makefile.am@1.21 +1 -1 + reference $(srcdir)/COPYRIGHT in EXTRA_DIST not COPYRIGHT [Bug 1414] + +ChangeSet@1.2082.4.4, 2009-12-12 08:31:39+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. + + ChangeLog@1.496.26.1 +4 -0 + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. + + configure.ac@1.465.1.1 +1 -47 + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. + + m4/os_cflags.m4@1.4 +82 -72 + [Bug 1412] m4/os_cflags.m4 caches results that depend on $CC. + +ChangeSet@1.2084.1.1, 2009-12-10 06:24:33-05:00, stenn@whimsy.udel.edu + NTP_4_2_7 + TAG: NTP_4_2_7 + + ChangeLog@1.496.25.1 +1 -0 + NTP_4_2_7 + + ntpd/ntpd-opts.c@1.247.1.1 +2 -2 + NTP_4_2_7 + + ntpd/ntpd-opts.h@1.247.1.1 +3 -3 + NTP_4_2_7 + + ntpd/ntpd-opts.texi@1.245.1.1 +2 -61 + NTP_4_2_7 + + ntpd/ntpd.1@1.245.1.1 +2 -2 + NTP_4_2_7 + + ntpdc/ntpdc-opts.c@1.243.1.1 +2 -2 + NTP_4_2_7 + + ntpdc/ntpdc-opts.h@1.243.1.1 +3 -3 + NTP_4_2_7 + + ntpdc/ntpdc-opts.texi@1.242.1.1 +2 -66 + NTP_4_2_7 + + ntpdc/ntpdc.1@1.242.1.1 +2 -2 + NTP_4_2_7 + + ntpq/ntpq-opts.c@1.244.1.1 +2 -2 + NTP_4_2_7 + + ntpq/ntpq-opts.h@1.244.1.1 +3 -3 + NTP_4_2_7 + + ntpq/ntpq-opts.texi@1.243.1.1 +2 -51 + NTP_4_2_7 + + ntpq/ntpq.1@1.243.1.1 +2 -2 + NTP_4_2_7 + + ntpsnmpd/ntpsnmpd-opts.c@1.122.1.1 +2 -2 + NTP_4_2_7 + + ntpsnmpd/ntpsnmpd-opts.h@1.122.1.1 +3 -3 + NTP_4_2_7 + + ntpsnmpd/ntpsnmpd-opts.texi@1.122.1.1 +1 -1 + NTP_4_2_7 + + ntpsnmpd/ntpsnmpd.1@1.121.1.1 +2 -2 + NTP_4_2_7 + + packageinfo.sh@1.258 +1 -1 + NTP_4_2_7 + + sntp/sntp-opts.c@1.116.1.1 +2 -2 + NTP_4_2_7 + + sntp/sntp-opts.h@1.116.1.1 +3 -3 + NTP_4_2_7 + + sntp/sntp-opts.texi@1.116.1.1 +2 -60 + NTP_4_2_7 + + sntp/sntp.1@1.116.1.1 +2 -2 + NTP_4_2_7 + + sntp/sntp.html@1.6.1.1 +14 -10 + NTP_4_2_7 + + util/ntp-keygen-opts.c@1.246.1.1 +2 -2 + NTP_4_2_7 + + util/ntp-keygen-opts.h@1.246.1.1 +3 -3 + NTP_4_2_7 + + util/ntp-keygen-opts.texi@1.245.1.1 +2 -46 + NTP_4_2_7 + + util/ntp-keygen.1@1.245.1.1 +2 -2 + NTP_4_2_7 + +ChangeSet@1.2082.4.3, 2009-12-10 05:49:19-05:00, stenn@whimsy.udel.edu + 4.2.6 + TAG: NTP_4_2_6 + + ntpd/ntpd-opts.c@1.248 +1 -1 + 4.2.6 + + ntpd/ntpd-opts.h@1.248 +1 -1 + 4.2.6 + + ntpd/ntpd-opts.texi@1.246 +1 -1 + 4.2.6 + + ntpd/ntpd.1@1.246 +2 -2 + 4.2.6 + + ntpdc/ntpdc-opts.c@1.244 +1 -1 + 4.2.6 + + ntpdc/ntpdc-opts.h@1.244 +1 -1 + 4.2.6 + + ntpdc/ntpdc-opts.texi@1.243 +2 -2 + 4.2.6 + + ntpdc/ntpdc.1@1.243 +2 -2 + 4.2.6 + + ntpq/ntpq-opts.c@1.245 +1 -1 + 4.2.6 + + ntpq/ntpq-opts.h@1.245 +1 -1 + 4.2.6 + + ntpq/ntpq-opts.texi@1.244 +2 -2 + 4.2.6 + + ntpq/ntpq.1@1.244 +2 -2 + 4.2.6 + + ntpsnmpd/ntpsnmpd-opts.c@1.123 +1 -1 + 4.2.6 + + ntpsnmpd/ntpsnmpd-opts.h@1.123 +1 -1 + 4.2.6 + + ntpsnmpd/ntpsnmpd-opts.texi@1.123 +23 -2 + 4.2.6 + + ntpsnmpd/ntpsnmpd.1@1.122 +2 -2 + 4.2.6 + + sntp/sntp-opts.c@1.117 +1 -1 + 4.2.6 + + sntp/sntp-opts.h@1.117 +1 -1 + 4.2.6 + + sntp/sntp-opts.texi@1.117 +2 -2 + 4.2.6 + + sntp/sntp.1@1.117 +2 -2 + 4.2.6 + + sntp/sntp.html@1.7 +13 -9 + 4.2.6 + + util/ntp-keygen-opts.c@1.247 +1 -1 + 4.2.6 + + util/ntp-keygen-opts.h@1.247 +1 -1 + 4.2.6 + + util/ntp-keygen-opts.texi@1.246 +2 -2 + 4.2.6 + + util/ntp-keygen.1@1.246 +2 -2 + 4.2.6 + +ChangeSet@1.2087, 2009-12-10 04:55:00+00:00, davehart@shiny.ad.hartbrothers.com + use 's' for symmetric mode in billboard type column + + ntpq/ntpq-subs.c@1.43 +1 -1 + use 's' for symmetric mode in billboard type column + +ChangeSet@1.2086, 2009-12-10 02:30:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1338] ntpq displays incorrect association type codes. + + ChangeLog@1.496.1.67 +1 -0 + [Bug 1338] ntpq displays incorrect association type codes. + +ChangeSet@1.2050.3.2, 2009-12-10 02:09:19+00:00, davehart@shiny.ad.hartbrothers.com + use 'A' for manycast server to be consistent with B, M + + ntpq/ntpq-subs.c@1.41 +1 -1 + use 'A' for manycast server to be consistent with B, M + +ChangeSet@1.2082.1.8, 2009-12-09 03:55:07-05:00, stenn@deacon.udel.edu + -dev is now 4.2.7 + + ChangeLog@1.496.23.8 +1 -0 + -dev is now 4.2.7 + +ChangeSet@1.2082.4.2, 2009-12-09 03:46:30-05:00, stenn@deacon.udel.edu + cleanup + + ChangeLog@1.496.23.7 +1 -1 + cleanup + + ntpd/ntpd-opts.c@1.247 +2 -2 + cleanup + + ntpd/ntpd-opts.h@1.247 +3 -3 + cleanup + + ntpd/ntpd-opts.texi@1.245 +2 -2 + cleanup + + ntpd/ntpd.1@1.245 +2 -2 + cleanup + + ntpdc/ntpdc-opts.c@1.243 +2 -2 + cleanup + + ntpdc/ntpdc-opts.h@1.243 +3 -3 + cleanup + + ntpdc/ntpdc-opts.texi@1.242 +3 -3 + cleanup + + ntpdc/ntpdc.1@1.242 +2 -2 + cleanup + + ntpq/ntpq-opts.c@1.244 +2 -2 + cleanup + + ntpq/ntpq-opts.h@1.244 +3 -3 + cleanup + + ntpq/ntpq-opts.texi@1.243 +3 -3 + cleanup + + ntpq/ntpq.1@1.243 +2 -2 + cleanup + + ntpsnmpd/ntpsnmpd-opts.c@1.122 +2 -2 + cleanup + + ntpsnmpd/ntpsnmpd-opts.h@1.122 +3 -3 + cleanup + + ntpsnmpd/ntpsnmpd-opts.texi@1.122 +1 -1 + cleanup + + ntpsnmpd/ntpsnmpd.1@1.121 +2 -2 + cleanup + + packageinfo.sh@1.255.1.2 +1 -1 + cleanup + + sntp/sntp-opts.c@1.116 +2 -2 + cleanup + + sntp/sntp-opts.h@1.116 +3 -3 + cleanup + + sntp/sntp-opts.texi@1.116 +3 -3 + cleanup + + sntp/sntp.1@1.116 +2 -2 + cleanup + + sntp/sntp.html@1.6 +1 -1 + cleanup + + util/ntp-keygen-opts.c@1.246 +2 -2 + cleanup + + util/ntp-keygen-opts.h@1.246 +3 -3 + cleanup + + util/ntp-keygen-opts.texi@1.245 +3 -3 + cleanup + + util/ntp-keygen.1@1.245 +2 -2 + cleanup + +ChangeSet@1.2082.4.1, 2009-12-09 02:58:13-05:00, stenn@deacon.udel.edu + NTP_4_2_6_RC + TAG: NTP_4_2_6_RC + + ChangeLog@1.496.23.6 +1 -0 + NTP_4_2_6_RC + + ntpd/ntpd-opts.c@1.246 +2 -2 + NTP_4_2_6_RC + + ntpd/ntpd-opts.h@1.246 +3 -3 + NTP_4_2_6_RC + + ntpd/ntpd-opts.texi@1.244 +61 -2 + NTP_4_2_6_RC + + ntpd/ntpd.1@1.244 +2 -2 + NTP_4_2_6_RC + + ntpdc/ntpdc-opts.c@1.242 +2 -2 + NTP_4_2_6_RC + + ntpdc/ntpdc-opts.h@1.242 +3 -3 + NTP_4_2_6_RC + + ntpdc/ntpdc-opts.texi@1.241 +66 -2 + NTP_4_2_6_RC + + ntpdc/ntpdc.1@1.241 +2 -2 + NTP_4_2_6_RC + + ntpq/ntpq-opts.c@1.243 +2 -2 + NTP_4_2_6_RC + + ntpq/ntpq-opts.h@1.243 +3 -3 + NTP_4_2_6_RC + + ntpq/ntpq-opts.texi@1.242 +51 -2 + NTP_4_2_6_RC + + ntpq/ntpq.1@1.242 +2 -2 + NTP_4_2_6_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.121 +2 -2 + NTP_4_2_6_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.121 +3 -3 + NTP_4_2_6_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.121 +1 -1 + NTP_4_2_6_RC + + ntpsnmpd/ntpsnmpd.1@1.120 +2 -2 + NTP_4_2_6_RC + + packageinfo.sh@1.255.1.1 +3 -3 + NTP_4_2_6_RC + + sntp/sntp-opts.c@1.115 +2 -2 + NTP_4_2_6_RC + + sntp/sntp-opts.h@1.115 +3 -3 + NTP_4_2_6_RC + + sntp/sntp-opts.texi@1.115 +60 -2 + NTP_4_2_6_RC + + sntp/sntp.1@1.115 +2 -2 + NTP_4_2_6_RC + + sntp/sntp.html@1.5 +10 -14 + NTP_4_2_6_RC + + util/ntp-keygen-opts.c@1.245 +2 -2 + NTP_4_2_6_RC + + util/ntp-keygen-opts.h@1.245 +3 -3 + NTP_4_2_6_RC + + util/ntp-keygen-opts.texi@1.244 +46 -2 + NTP_4_2_6_RC + + util/ntp-keygen.1@1.244 +2 -2 + NTP_4_2_6_RC + +ChangeSet@1.2082.3.1, 2009-12-09 00:16:12-05:00, stenn@deacon.udel.edu + 4.2.7 + + packageinfo.sh@1.254.1.1 +4 -4 + 4.2.7 + +ChangeSet@1.2082.1.5, 2009-12-09 00:06:06-05:00, stenn@deacon.udel.edu + 4.2.6 + + ChangeLog@1.496.23.5 +1 -0 + 4.2.6 + + packageinfo.sh@1.255 +5 -5 + 4.2.6 + +ChangeSet@1.2082.1.4, 2009-12-08 10:09:30-05:00, stenn@deacon.udel.edu + Include 4.2.4p8 + + ChangeLog@1.496.23.4 +1 -0 + +ChangeSet@1.1436.15.75, 2009-12-08 08:30:54-05:00, stenn@whimsy.udel.edu + ChangeLog: + typo + + ChangeLog@1.1.1.94 +0 -1 + typo + +ChangeSet@1.1436.15.74, 2009-12-08 08:23:12-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P8 + TAG: NTP_4_2_4P8 + + ChangeLog@1.1.1.93 +1 -0 + NTP_4_2_4P8 + + ntpd/ntpd-opts.c@1.50.26.2 +2 -2 + NTP_4_2_4P8 + + ntpd/ntpd-opts.h@1.50.26.2 +3 -3 + NTP_4_2_4P8 + + ntpd/ntpd-opts.texi@1.49.26.2 +1 -1 + NTP_4_2_4P8 + + ntpd/ntpd.1@1.48.26.2 +2 -2 + NTP_4_2_4P8 + + ntpd/ntpdsim-opts.c@1.50.26.2 +2 -2 + NTP_4_2_4P8 + + ntpd/ntpdsim-opts.h@1.50.26.2 +3 -3 + NTP_4_2_4P8 + + ntpd/ntpdsim-opts.texi@1.48.26.2 +1 -1 + NTP_4_2_4P8 + + ntpd/ntpdsim.1@1.48.26.2 +2 -2 + NTP_4_2_4P8 + + ntpdc/ntpdc-opts.c@1.50.26.2 +2 -2 + NTP_4_2_4P8 + + ntpdc/ntpdc-opts.h@1.50.26.2 +3 -3 + NTP_4_2_4P8 + + ntpdc/ntpdc-opts.texi@1.48.26.2 +1 -1 + NTP_4_2_4P8 + + ntpdc/ntpdc.1@1.48.26.2 +2 -2 + NTP_4_2_4P8 + + ntpq/ntpq-opts.c@1.52.26.2 +2 -2 + NTP_4_2_4P8 + + ntpq/ntpq-opts.h@1.52.26.2 +3 -3 + NTP_4_2_4P8 + + ntpq/ntpq-opts.texi@1.49.26.2 +1 -1 + NTP_4_2_4P8 + + ntpq/ntpq.1@1.48.26.2 +2 -2 + NTP_4_2_4P8 + + packageinfo.sh@1.65.34.3 +4 -4 + NTP_4_2_4P8 + + sntp/sntp-opts.c@1.49.26.2 +2 -2 + NTP_4_2_4P8 + + sntp/sntp-opts.h@1.49.26.2 +3 -3 + NTP_4_2_4P8 + + sntp/sntp-opts.texi@1.46.26.2 +1 -1 + NTP_4_2_4P8 + + sntp/sntp.1@1.49.26.2 +2 -2 + NTP_4_2_4P8 + + util/ntp-keygen-opts.c@1.49.26.2 +2 -2 + NTP_4_2_4P8 + + util/ntp-keygen-opts.h@1.49.26.2 +3 -3 + NTP_4_2_4P8 + + util/ntp-keygen-opts.texi@1.47.26.2 +1 -1 + NTP_4_2_4P8 + + util/ntp-keygen.1@1.47.26.2 +2 -2 + NTP_4_2_4P8 + +ChangeSet@1.1436.15.73, 2009-12-08 07:45:28-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P9_RC1 + TAG: NTP_4_2_4P9_RC1 + + ChangeLog@1.1.1.92 +1 -0 + NTP_4_2_4P9_RC1 + + ntpd/ntpd-opts.c@1.50.26.1 +5 -5 + NTP_4_2_4P9_RC1 + + ntpd/ntpd-opts.h@1.50.26.1 +4 -4 + NTP_4_2_4P9_RC1 + + ntpd/ntpd-opts.texi@1.49.26.1 +13 -6 + NTP_4_2_4P9_RC1 + + ntpd/ntpd.1@1.48.26.1 +2 -2 + NTP_4_2_4P9_RC1 + + ntpd/ntpdsim-opts.c@1.50.26.1 +5 -5 + NTP_4_2_4P9_RC1 + + ntpd/ntpdsim-opts.h@1.50.26.1 +4 -4 + NTP_4_2_4P9_RC1 + + ntpd/ntpdsim-opts.texi@1.48.26.1 +61 -2 + NTP_4_2_4P9_RC1 + + ntpd/ntpdsim.1@1.48.26.1 +2 -2 + NTP_4_2_4P9_RC1 + + ntpdc/ntpdc-opts.c@1.50.26.1 +5 -5 + NTP_4_2_4P9_RC1 + + ntpdc/ntpdc-opts.h@1.50.26.1 +4 -4 + NTP_4_2_4P9_RC1 + + ntpdc/ntpdc-opts.texi@1.48.26.1 +7 -4 + NTP_4_2_4P9_RC1 + + ntpdc/ntpdc.1@1.48.26.1 +2 -2 + NTP_4_2_4P9_RC1 + + ntpq/ntpq-opts.c@1.52.26.1 +5 -5 + NTP_4_2_4P9_RC1 + + ntpq/ntpq-opts.h@1.52.26.1 +4 -4 + NTP_4_2_4P9_RC1 + + ntpq/ntpq-opts.texi@1.49.26.1 +8 -4 + NTP_4_2_4P9_RC1 + + ntpq/ntpq.1@1.48.26.1 +2 -2 + NTP_4_2_4P9_RC1 + + packageinfo.sh@1.65.34.2 +3 -3 + NTP_4_2_4P9_RC1 + + sntp/sntp-opts.c@1.49.26.1 +5 -5 + NTP_4_2_4P9_RC1 + + sntp/sntp-opts.h@1.49.26.1 +4 -4 + NTP_4_2_4P9_RC1 + + sntp/sntp-opts.texi@1.46.26.1 +54 -2 + NTP_4_2_4P9_RC1 + + sntp/sntp.1@1.49.26.1 +2 -2 + NTP_4_2_4P9_RC1 + + util/ntp-keygen-opts.c@1.49.26.1 +5 -5 + NTP_4_2_4P9_RC1 + + util/ntp-keygen-opts.h@1.49.26.1 +4 -4 + NTP_4_2_4P9_RC1 + + util/ntp-keygen-opts.texi@1.47.26.1 +4 -4 + NTP_4_2_4P9_RC1 + + util/ntp-keygen.1@1.47.26.1 +2 -2 + NTP_4_2_4P9_RC1 + +ChangeSet@1.1436.15.72, 2009-12-08 05:36:47-05:00, stenn@whimsy.udel.edu + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + + NEWS@1.86.1.16 +34 -0 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + + packageinfo.sh@1.65.34.1 +2 -2 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563 + +ChangeSet@1.2082.1.1, 2009-12-07 11:58:19+01:00, burnicki@pogo.udel.edu + [Bug 508] Fixed leap second handling for Windows. + + ChangeLog@1.496.23.1 +1 -0 + [Bug 508] Fixed leap second handling for Windows. + + ntpd/ntp_timer.c@1.56 +2 -0 + [Bug 508] Fixed leap second handling for Windows. + + ports/winnt/ntpd/nt_clockstuff.c@1.38 +17 -2 + [Bug 508] Fixed leap second handling for Windows. + +ChangeSet@1.2083, 2009-12-06 20:46:44+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1407] configure.ac: recent GNU Make -v does not include "version". + + ChangeLog@1.496.1.65 +1 -0 + [Bug 1407] configure.ac: recent GNU Make -v does not include "version". + + configure.ac@1.466 +1 -4 + clone GNU Make test from m4/ntp_vpathhack.m4, recognize newer GNU Make + which does not include "version" in its -v output + +ChangeSet@1.2082, 2009-11-30 05:29:50-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P250_RC + TAG: NTP_4_2_5P250_RC + + ChangeLog@1.496.1.64 +1 -0 + NTP_4_2_5P250_RC + + ntpd/ntpd-opts.c@1.245 +2 -2 + NTP_4_2_5P250_RC + + ntpd/ntpd-opts.h@1.245 +3 -3 + NTP_4_2_5P250_RC + + ntpd/ntpd-opts.texi@1.243 +1 -1 + NTP_4_2_5P250_RC + + ntpd/ntpd.1@1.243 +2 -2 + NTP_4_2_5P250_RC + + ntpdc/ntpdc-opts.c@1.241 +2 -2 + NTP_4_2_5P250_RC + + ntpdc/ntpdc-opts.h@1.241 +3 -3 + NTP_4_2_5P250_RC + + ntpdc/ntpdc-opts.texi@1.240 +1 -1 + NTP_4_2_5P250_RC + + ntpdc/ntpdc.1@1.240 +2 -2 + NTP_4_2_5P250_RC + + ntpq/ntpq-opts.c@1.242 +2 -2 + NTP_4_2_5P250_RC + + ntpq/ntpq-opts.h@1.242 +3 -3 + NTP_4_2_5P250_RC + + ntpq/ntpq-opts.texi@1.241 +1 -1 + NTP_4_2_5P250_RC + + ntpq/ntpq.1@1.241 +2 -2 + NTP_4_2_5P250_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.120 +2 -2 + NTP_4_2_5P250_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.120 +3 -3 + NTP_4_2_5P250_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.120 +1 -1 + NTP_4_2_5P250_RC + + ntpsnmpd/ntpsnmpd.1@1.119 +2 -2 + NTP_4_2_5P250_RC + + packageinfo.sh@1.254 +1 -1 + NTP_4_2_5P250_RC + + sntp/sntp-opts.c@1.114 +4 -4 + NTP_4_2_5P250_RC + + sntp/sntp-opts.h@1.114 +3 -3 + NTP_4_2_5P250_RC + + sntp/sntp-opts.texi@1.114 +7 -7 + NTP_4_2_5P250_RC + + sntp/sntp.1@1.114 +37 -37 + NTP_4_2_5P250_RC + + sntp/sntp.html@1.4 +5 -5 + NTP_4_2_5P250_RC + + util/ntp-keygen-opts.c@1.244 +2 -2 + NTP_4_2_5P250_RC + + util/ntp-keygen-opts.h@1.244 +3 -3 + NTP_4_2_5P250_RC + + util/ntp-keygen-opts.texi@1.243 +1 -1 + NTP_4_2_5P250_RC + + util/ntp-keygen.1@1.243 +2 -2 + NTP_4_2_5P250_RC + +ChangeSet@1.2081, 2009-11-30 04:19:28-05:00, stenn@whimsy.udel.edu + sntp documentation updates + + sntp/sntp.texi@1.3 +2 -2 + sntp documentation updates + +ChangeSet@1.2080, 2009-11-30 04:15:15-05:00, stenn@whimsy.udel.edu + sntp documentation updates + + sntp/sntp.texi@1.2 +4 -4 + sntp documentation updates + +ChangeSet@1.2079, 2009-11-30 04:06:48-05:00, stenn@whimsy.udel.edu + sntp documentation updates + + ChangeLog@1.496.1.63 +1 -0 + sntp documentation updates + + sntp/sntp-opts.def@1.15 +21 -12 + sntp documentation updates + +ChangeSet@1.2075.1.2, 2009-11-29 23:36:52-05:00, murray@malarky.udel.edu + ntp_intres.c, ChangeLog: + Fix for bug 1386: Deferred DNS doesn't work on NetBSD + + ChangeLog@1.496.20.10 +1 -0 + Fix for bug 1386: Deferred DNS doesn't work on NetBSD + + ntpd/ntp_intres.c@1.76 +28 -12 + Fix for bug 1386: Deferred DNS doesn't work on NetBSD + +ChangeSet@1.2075.1.1, 2009-11-28 21:30:09-05:00, murray@malarky.udel.edu + configure.ac: + Add --enable-force-defer-DNS + Helps debugging deferred DNS lookups. + ChangeLog: + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + ntp_config.c: + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + FORCE_DEFER_DNS helps debugging. + Pass no_needed to ntp_intres, first step on Bug 975. + ntp_intres.c: + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + Take no_needed from ntp_config, first step on Bug 975. + + ChangeLog@1.496.20.9 +3 -0 + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + + configure.ac@1.465 +16 -0 + Add --enable-force-defer-DNS + Helps debugging deferred DNS lookups. + + ntpd/ntp_config.c@1.238 +20 -10 + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + FORCE_DEFER_DNS helps debugging. + Pass no_needed to ntp_intres, first step on Bug 975. + + ntpd/ntp_intres.c@1.75 +31 -17 + Bug 761: internal resolver does not seem to honor -4/-6 qualifiers + Take no_needed from ntp_config, first step on Bug 975. + +ChangeSet@1.2077, 2009-11-28 23:42:10+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1391] avoid invoking autogen twice for .c and .h files. + + ChangeLog@1.496.1.61 +1 -0 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + + ntpd/Makefile.am@1.79 +6 -2 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + + ntpdc/Makefile.am@1.47 +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + + ntpq/Makefile.am@1.42 +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + + ntpsnmpd/Makefile.am@1.15 +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + + sntp/Makefile.am@1.20 +12 -3 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + when recursively building sntp binary for .texi rule, make libopts.la first + + util/Makefile.am@1.45 +4 -1 + [Bug 1391] avoid invoking autogen twice for .c and .h files. + +ChangeSet@1.2075, 2009-11-28 05:29:18-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P249_RC + TAG: NTP_4_2_5P249_RC + + ChangeLog@1.496.20.8 +1 -0 + NTP_4_2_5P249_RC + + ntpd/ntpd-opts.c@1.244 +2 -2 + NTP_4_2_5P249_RC + + ntpd/ntpd-opts.h@1.244 +3 -3 + NTP_4_2_5P249_RC + + ntpd/ntpd-opts.texi@1.242 +2 -61 + NTP_4_2_5P249_RC + + ntpd/ntpd.1@1.242 +2 -2 + NTP_4_2_5P249_RC + + ntpdc/ntpdc-opts.c@1.240 +2 -2 + NTP_4_2_5P249_RC + + ntpdc/ntpdc-opts.h@1.240 +3 -3 + NTP_4_2_5P249_RC + + ntpdc/ntpdc-opts.texi@1.239 +2 -66 + NTP_4_2_5P249_RC + + ntpdc/ntpdc.1@1.239 +2 -2 + NTP_4_2_5P249_RC + + ntpq/ntpq-opts.c@1.241 +2 -2 + NTP_4_2_5P249_RC + + ntpq/ntpq-opts.h@1.241 +3 -3 + NTP_4_2_5P249_RC + + ntpq/ntpq-opts.texi@1.240 +2 -51 + NTP_4_2_5P249_RC + + ntpq/ntpq.1@1.240 +2 -2 + NTP_4_2_5P249_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.119 +2 -2 + NTP_4_2_5P249_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.119 +3 -3 + NTP_4_2_5P249_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.119 +2 -23 + NTP_4_2_5P249_RC + + ntpsnmpd/ntpsnmpd.1@1.118 +2 -2 + NTP_4_2_5P249_RC + + packageinfo.sh@1.253 +1 -1 + NTP_4_2_5P249_RC + + sntp/sntp-opts.c@1.113 +6 -5 + NTP_4_2_5P249_RC + + sntp/sntp-opts.h@1.113 +3 -3 + NTP_4_2_5P249_RC + + sntp/sntp-opts.texi@1.113 +4 -55 + NTP_4_2_5P249_RC + + sntp/sntp.1@1.113 +18 -75 + NTP_4_2_5P249_RC + + sntp/sntp.html@1.3 +26 -22 + NTP_4_2_5P249_RC + + util/ntp-keygen-opts.c@1.243 +2 -2 + NTP_4_2_5P249_RC + + util/ntp-keygen-opts.h@1.243 +3 -3 + NTP_4_2_5P249_RC + + util/ntp-keygen-opts.texi@1.242 +2 -46 + NTP_4_2_5P249_RC + + util/ntp-keygen.1@1.242 +2 -2 + NTP_4_2_5P249_RC + +ChangeSet@1.2074, 2009-11-28 04:25:13-05:00, stenn@whimsy.udel.edu + cleanup + + sntp/main.c@1.24 +2 -1 + cleanup + +ChangeSet@1.2072, 2009-11-28 01:43:01-05:00, stenn@whimsy.udel.edu + sntp cleanup + + ChangeLog@1.496.20.6 +1 -0 + sntp documentation cleanup + + ChangeLog@1.496.20.5 +3 -0 + sntp: Show dispersion. Clean up error messages and offset + + sntp/main.c@1.23 +33 -18 + sntp: Show dispersion. Clean up error messages and offset + + sntp/networking.h@1.17 +1 -1 + cleanup + + sntp/sntp-opts.def@1.14 +16 -74 + sntp documentation cleanup + +ChangeSet@1.2070.1.1, 2009-11-28 06:31:50+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1400] An empty KOD DB file causes sntp to coredump. + + ChangeLog@1.496.22.1 +1 -0 + [Bug 1400] An empty KOD DB file causes sntp to coredump. + + sntp/kod_management.c@1.15 +45 -26 + [Bug 1400] An empty KOD DB file causes sntp to coredump. + +ChangeSet@1.2071, 2009-11-28 01:27:47-05:00, stenn@whimsy.udel.edu + Cleanup from the autoconf/automake upgrades + + ChangeLog@1.496.20.4 +1 -0 + Cleanup from the autoconf/automake upgrades + + Makefile.am@1.89 +1 -1 + Cleanup from the autoconf/automake upgrades + + configure.ac@1.464 +1 -1 + Cleanup from the autoconf/automake upgrades + + sntp/Makefile.am@1.19 +18 -12 + Cleanup from the autoconf/automake upgrades + + sntp/configure.ac@1.28 +1 -0 + Cleanup from the autoconf/automake upgrades + +ChangeSet@1.2070, 2009-11-26 05:39:41-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P248_RC + TAG: NTP_4_2_5P248_RC + + ChangeLog@1.496.20.3 +1 -0 + NTP_4_2_5P248_RC + + ntpd/ntpd-opts.c@1.243 +2 -2 + NTP_4_2_5P248_RC + + ntpd/ntpd-opts.h@1.243 +3 -3 + NTP_4_2_5P248_RC + + ntpd/ntpd-opts.texi@1.241 +9 -4 + NTP_4_2_5P248_RC + + ntpd/ntpd.1@1.241 +2 -2 + NTP_4_2_5P248_RC + + ntpdc/ntpdc-opts.c@1.239 +2 -2 + NTP_4_2_5P248_RC + + ntpdc/ntpdc-opts.h@1.239 +3 -3 + NTP_4_2_5P248_RC + + ntpdc/ntpdc-opts.texi@1.238 +7 -4 + NTP_4_2_5P248_RC + + ntpdc/ntpdc.1@1.238 +2 -2 + NTP_4_2_5P248_RC + + ntpq/ntpq-opts.c@1.240 +2 -2 + NTP_4_2_5P248_RC + + ntpq/ntpq-opts.h@1.240 +3 -3 + NTP_4_2_5P248_RC + + ntpq/ntpq-opts.texi@1.239 +3 -3 + NTP_4_2_5P248_RC + + ntpq/ntpq.1@1.239 +2 -2 + NTP_4_2_5P248_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.118 +2 -2 + NTP_4_2_5P248_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.118 +3 -3 + NTP_4_2_5P248_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.118 +23 -2 + NTP_4_2_5P248_RC + + ntpsnmpd/ntpsnmpd.1@1.117 +2 -2 + NTP_4_2_5P248_RC + + packageinfo.sh@1.252 +1 -1 + NTP_4_2_5P248_RC + + sntp/sntp-opts.c@1.112 +13 -9 + NTP_4_2_5P248_RC + + sntp/sntp-opts.h@1.112 +3 -3 + NTP_4_2_5P248_RC + + sntp/sntp-opts.texi@1.112 +18 -10 + NTP_4_2_5P248_RC + + sntp/sntp.1@1.112 +7 -38 + NTP_4_2_5P248_RC + + sntp/sntp.html@1.2 +22 -26 + NTP_4_2_5P248_RC + + util/ntp-keygen-opts.c@1.242 +2 -2 + NTP_4_2_5P248_RC + + util/ntp-keygen-opts.h@1.242 +3 -3 + NTP_4_2_5P248_RC + + util/ntp-keygen-opts.texi@1.241 +3 -3 + NTP_4_2_5P248_RC + + util/ntp-keygen.1@1.241 +2 -2 + NTP_4_2_5P248_RC + +ChangeSet@1.2069, 2009-11-26 03:45:44-05:00, stenn@whimsy.udel.edu + updates for sntp/sntp.html + + .point-changed-filelist@1.7 +1 -0 + updates for sntp/sntp.html + + BitKeeper/deleted/.del-version.texi~39e8aa5321c3de71@1.2 +0 -0 + Delete: include/version.texi + + BitKeeper/deleted/.del-version.texi~dc1d08ee311794@1.2 +0 -0 + Delete: sntp/version.texi + + BitKeeper/etc/ignore@1.74 +4 -3 + updates for sntp/sntp.html + + BitKeeper/etc/ignore@1.73 +1 -0 + added version.texi + +ChangeSet@1.2068, 2009-11-26 07:04:26+00:00, hart@pogo.udel.edu + .del-depsver.mf~797b9b4e1db319be: + Delete: sntp/depsver.mf + ignore: + added sntp/depsver.mf + + sntp/depsver.mf is 'generated' (copied) from top-level depsver.mf + by bootstrap script + + + BitKeeper/deleted/.del-depsver.mf~797b9b4e1db319be@1.2 +0 -0 + Delete: sntp/depsver.mf + + BitKeeper/etc/ignore@1.72 +1 -0 + added sntp/depsver.mf + +ChangeSet@1.2067, 2009-11-26 01:42:32-05:00, stenn@psp-deb1.ntp.org + bk: ignore ltmain.sh + + BitKeeper/etc/ignore@1.71 +1 -0 + added ltmain.sh + +ChangeSet@1.2065, 2009-11-26 01:33:57-05:00, stenn@psp-deb1.ntp.org + Prepare for the generation of sntp.html + + BitKeeper/etc/ignore@1.70 +1 -9 + Update the bk ignore list + + BitKeeper/etc/ignore@1.69 +1 -0 + added config.cache-* + + ChangeLog@1.496.21.1 +1 -0 + Prepare for the generation of sntp.html + + include/version.texi@1.1 +3 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/include/version.texi + + include/version.texi@1.0 +0 -0 + + sntp/Makefile.am@1.17 +1 -5 + Prepare for the generation of sntp.html + + sntp/depsver.mf@1.1 +67 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/sntp/depsver.mf + + sntp/depsver.mf@1.0 +0 -0 + + sntp/sntp.html@1.1 +105 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/sntp/sntp.html + + sntp/sntp.html@1.0 +0 -0 + + sntp/version.texi@1.1 +3 -0 + BitKeeper file /home/stenn/ntp-dev-sntp/sntp/version.texi + + sntp/version.texi@1.0 +0 -0 + +ChangeSet@1.2060.24.1, 2009-11-26 01:16:35-05:00, stenn@whimsy.udel.edu + Documentation changes from Dave Mills + + ChangeLog@1.496.20.1 +1 -0 + Documentation changes from Dave Mills + + html/confopt.html@1.48 +53 -60 + Documentation changes from Dave Mills + + html/manyopt.html@1.20 +5 -3 + Documentation changes from Dave Mills + + html/quick.html@1.20 +17 -4 + Documentation changes from Dave Mills + +ChangeSet@1.2060.3.52, 2009-11-26 01:06:36-05:00, stenn@pogo.udel.edu + typo nit + + ChangeLog@1.496.1.59 +1 -1 + +ChangeSet@1.2060.23.1, 2009-11-25 14:19:20-05:00, murray@malarky.udel.edu + refclock_shm.c, ChangeLog: + Bug-1397: shmget() failing because of file mode + + ChangeLog@1.496.19.1 +1 -0 + Bug-1397: shmget() failing because of file mode + + ntpd/refclock_shm.c@1.20 +1 -1 + Bug-1397: shmget() failing because of file mode + +ChangeSet@1.2060.3.50, 2009-11-24 22:05:54+00:00, davehart@shiny.ad.hartbrothers.com + One more missing free(), thanks to Hal Murray's sharp eyes + + ntpd/ntp_intres.c@1.74 +2 -0 + One more missing free(), thanks to Hal Murray's sharp eyes + +ChangeSet@1.2060.3.49, 2009-11-24 14:51:38+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1387] free() conf_entry in ntp_intres removeentry(). + [Bug 1392] intres retries duplicate assocations endlessly. + + ChangeLog@1.496.1.57 +1 -0 + [Bug 1387] free() conf_entry in ntp_intres removeentry(). + [Bug 1392] intres retries duplicate assocations endlessly. + + ntpd/ntp_intres.c@1.73 +31 -26 + [Bug 1387] free() conf_entry in ntp_intres removeentry(). + [Bug 1392] intres retries duplicate assocations endlessly. + + ntpd/ntp_peer.c@1.126 +6 -11 + use DPRINTF + +ChangeSet@1.2060.3.48, 2009-11-23 17:43:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1387] Storage leak in ntp_intres (minor). + [Bug 1389] buffer overflow in refclock_oncore.c + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + + + ChangeLog@1.496.1.56 +4 -0 + [Bug 1387] Storage leak in ntp_intres (minor). + [Bug 1389] buffer overflow in refclock_oncore.c + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + + + configure.ac@1.459.1.14 +3 -4 + [Bug 1391] .texi usage text from installed, not built binaries. + no functional change to configure.ac, eliminate duplicate + "checking for net-snmp-config" messages and clarify help text + for --with-ntpsnmpd. + + ntpd/Makefile.am@1.78 +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + + ntpd/ntp_intres.c@1.72 +1 -0 + [Bug 1387] Storage leak in ntp_intres (minor). + + ntpd/refclock_oncore.c@1.81 +306 -191 + * [Bug 1389] buffer overflow in refclock_oncore.c + + ntpdc/Makefile.am@1.46 +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + + ntpq/Makefile.am@1.41 +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + + ntpsnmpd/Makefile.am@1.14 +8 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + + sntp/Makefile.am@1.13.1.6 +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + + util/Makefile.am@1.44 +5 -3 + [Bug 1391] .texi usage text from installed, not built binaries. + Correct *-opts.h dependency so default 'get' action isn't used. + +ChangeSet@1.2060.3.47, 2009-11-20 05:36:49-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P247_RC + TAG: NTP_4_2_5P247_RC + + ChangeLog@1.496.1.55 +1 -0 + NTP_4_2_5P247_RC + + ntpd/ntpd-opts.c@1.242 +5 -5 + NTP_4_2_5P247_RC + + ntpd/ntpd-opts.h@1.242 +4 -4 + NTP_4_2_5P247_RC + + ntpd/ntpd-opts.texi@1.240 +2 -2 + NTP_4_2_5P247_RC + + ntpd/ntpd.1@1.240 +2 -2 + NTP_4_2_5P247_RC + + ntpdc/ntpdc-opts.c@1.238 +5 -5 + NTP_4_2_5P247_RC + + ntpdc/ntpdc-opts.h@1.238 +4 -4 + NTP_4_2_5P247_RC + + ntpdc/ntpdc-opts.texi@1.237 +4 -4 + NTP_4_2_5P247_RC + + ntpdc/ntpdc.1@1.237 +2 -2 + NTP_4_2_5P247_RC + + ntpq/ntpq-opts.c@1.239 +5 -5 + NTP_4_2_5P247_RC + + ntpq/ntpq-opts.h@1.239 +4 -4 + NTP_4_2_5P247_RC + + ntpq/ntpq-opts.texi@1.238 +4 -4 + NTP_4_2_5P247_RC + + ntpq/ntpq.1@1.238 +2 -2 + NTP_4_2_5P247_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.117 +5 -5 + NTP_4_2_5P247_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.117 +4 -4 + NTP_4_2_5P247_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.117 +2 -23 + NTP_4_2_5P247_RC + + ntpsnmpd/ntpsnmpd.1@1.116 +2 -2 + NTP_4_2_5P247_RC + + packageinfo.sh@1.251 +1 -1 + NTP_4_2_5P247_RC + + sntp/sntp-opts.c@1.111 +5 -5 + NTP_4_2_5P247_RC + + sntp/sntp-opts.h@1.111 +4 -4 + NTP_4_2_5P247_RC + + sntp/sntp-opts.texi@1.111 +4 -4 + NTP_4_2_5P247_RC + + sntp/sntp.1@1.111 +2 -2 + NTP_4_2_5P247_RC + + util/ntp-keygen-opts.c@1.241 +5 -5 + NTP_4_2_5P247_RC + + util/ntp-keygen-opts.h@1.241 +4 -4 + NTP_4_2_5P247_RC + + util/ntp-keygen-opts.texi@1.240 +5 -5 + NTP_4_2_5P247_RC + + util/ntp-keygen.1@1.240 +2 -2 + NTP_4_2_5P247_RC + +ChangeSet@1.2060.3.46, 2009-11-18 04:29:17+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1308] support systems that lack fork(). + + ChangeLog@1.496.1.54 +1 -0 + [Bug 1308] support systems that lack fork(). + + configure.ac@1.459.1.13 +2 -0 + [Bug 1308] support systems that lack fork(). + + include/ntp_config.h@1.66 +12 -1 + setup NO_INTRES macro on systems which do not support fork or threads + + include/ntp_machine.h@1.26 +3 -3 + stay out of compiler/system underscore namespace + + ntpd/ntp_config.c@1.237 +12 -23 + [Bug 1308] support systems that lack fork(). + + ntpd/ntp_intres.c@1.71 +7 -0 + [Bug 1308] support systems that lack fork(). + +ChangeSet@1.2060.3.45, 2009-11-17 19:43:44+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1142] nodebug builds shed no light on -d, -D option failure. + [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + -4/-6 are not equivalent in the libopts sense + + ChangeLog@1.496.1.53 +3 -0 + * [Bug 1142] nodebug builds shed no light on -d, -D option failure. + * [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + + + ntpd/cmd_args.c@1.56 +9 -41 + [Bug 1142] nodebug builds shed no light on -d, -D option failure. + [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + -4/-6 are not equivalent in the libopts sense + --authreq and --authnoreq are mutually exclusive + + ntpd/ntpd-opts.c@1.241 +28 -20 + updated Autogen output + + ntpd/ntpd-opts.h@1.241 +2 -5 + updated Autogen output + + ntpd/ntpd-opts.texi@1.239 +17 -7 + updated Autogen output + + ntpd/ntpd.1@1.239 +16 -6 + updated Autogen output + + ntpd/ntpdbase-opts.def@1.20 +18 -6 + [Bug 1142] nodebug builds shed no light on -d, -D option failure. + [Bug 1179] point out the problem with -i/--jaildir and -u/--user when + they are disabled by configure. + -4/-6 are not equivalent in the libopts sense + + ntpdc/ntpdc-opts.c@1.237 +19 -11 + updated Autogen output + + ntpdc/ntpdc-opts.def@1.14 +2 -2 + -4/-6 are not equivalent in the libopts sense + + ntpdc/ntpdc-opts.h@1.237 +2 -5 + updated Autogen output + + ntpdc/ntpdc-opts.texi@1.236 +8 -6 + updated Autogen output + + ntpdc/ntpdc.1@1.236 +5 -3 + updated Autogen output + + ntpdc/ntpdc.c@1.75 +3 -8 + -4/-6 are not equivalent in the libopts sense + + ntpq/ntpq-opts.c@1.238 +4 -4 + updated Autogen output + + ntpq/ntpq-opts.h@1.238 +2 -2 + updated Autogen output + + ntpq/ntpq-opts.texi@1.237 +4 -4 + updated Autogen output + + ntpq/ntpq.1@1.237 +1 -1 + updated Autogen output + + ntpq/ntpq.c@1.97 +2 -1 + Don't use DPRINTF because #ifdef DEBUG isn't valid in utils + + ntpsnmpd/ntpsnmpd-opts.c@1.116 +4 -4 + updated Autogen output + + ntpsnmpd/ntpsnmpd-opts.h@1.116 +2 -2 + updated Autogen output + + ntpsnmpd/ntpsnmpd-opts.texi@1.116 +23 -2 + updated Autogen output + + sntp/main.c@1.22 +3 -5 + -4/-6 are not equivalent in the libopts sense + + sntp/sntp-opts.c@1.110 +19 -11 + updated Autogen output + + sntp/sntp-opts.def@1.11.1.1 +3 -2 + -4/-6 are not equivalent in the libopts sense + + sntp/sntp-opts.h@1.110 +2 -5 + updated Autogen output + + sntp/sntp-opts.texi@1.110 +8 -6 + updated Autogen output + + sntp/sntp.1@1.110 +5 -3 + updated Autogen output + + util/ntp-keygen-opts.c@1.240 +4 -4 + updated Autogen output + + util/ntp-keygen-opts.h@1.240 +2 -2 + updated Autogen output + + util/ntp-keygen-opts.texi@1.239 +5 -5 + updated Autogen output + + util/ntp-keygen.1@1.239 +1 -1 + updated Autogen output + +ChangeSet@1.2060.3.44, 2009-11-17 16:15:53+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1343] sntp doesn't link on Solaris 7, needs -lresolv. + + ChangeLog@1.496.1.52 +1 -0 + [Bug 1343] sntp doesn't link on Solaris 7, needs -lresolv. + + configure.ac@1.459.1.12 +2 -1 + Search for inet_ntop in -lresolv if not in default libs, needed + for sntp on Solaris 7 + + sntp/configure.ac@1.27 +2 -1 + Search for inet_ntop in -lresolv if not in default libs, needed + for sntp on Solaris 7 + +ChangeSet@1.2060.3.43, 2009-11-17 07:34:00-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P246_RC + TAG: NTP_4_2_5P246_RC + + ChangeLog@1.496.1.51 +1 -0 + NTP_4_2_5P246_RC + + ntpd/ntpd-opts.c@1.240 +32 -33 + NTP_4_2_5P246_RC + + ntpd/ntpd-opts.h@1.240 +8 -21 + NTP_4_2_5P246_RC + + ntpd/ntpd-opts.texi@1.238 +1 -1 + NTP_4_2_5P246_RC + + ntpd/ntpd.1@1.238 +3 -3 + NTP_4_2_5P246_RC + + ntpdc/ntpdc-opts.c@1.236 +24 -17 + NTP_4_2_5P246_RC + + ntpdc/ntpdc-opts.h@1.236 +6 -5 + NTP_4_2_5P246_RC + + ntpdc/ntpdc-opts.texi@1.235 +1 -1 + NTP_4_2_5P246_RC + + ntpdc/ntpdc.1@1.235 +3 -3 + NTP_4_2_5P246_RC + + ntpq/ntpq-opts.c@1.237 +24 -17 + NTP_4_2_5P246_RC + + ntpq/ntpq-opts.h@1.237 +5 -5 + NTP_4_2_5P246_RC + + ntpq/ntpq-opts.texi@1.236 +1 -1 + NTP_4_2_5P246_RC + + ntpq/ntpq.1@1.236 +3 -3 + NTP_4_2_5P246_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.115 +24 -17 + NTP_4_2_5P246_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.115 +5 -5 + NTP_4_2_5P246_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.115 +1 -1 + NTP_4_2_5P246_RC + + ntpsnmpd/ntpsnmpd.1@1.115 +3 -3 + NTP_4_2_5P246_RC + + packageinfo.sh@1.250 +1 -1 + NTP_4_2_5P246_RC + + sntp/sntp-opts.c@1.109 +24 -17 + NTP_4_2_5P246_RC + + sntp/sntp-opts.h@1.109 +8 -5 + NTP_4_2_5P246_RC + + sntp/sntp-opts.texi@1.109 +1 -1 + NTP_4_2_5P246_RC + + sntp/sntp.1@1.109 +3 -3 + NTP_4_2_5P246_RC + + util/ntp-keygen-opts.c@1.239 +39 -47 + NTP_4_2_5P246_RC + + util/ntp-keygen-opts.h@1.239 +11 -32 + NTP_4_2_5P246_RC + + util/ntp-keygen-opts.texi@1.238 +1 -1 + NTP_4_2_5P246_RC + + util/ntp-keygen.1@1.238 +3 -3 + NTP_4_2_5P246_RC + +ChangeSet@1.2060.3.42, 2009-11-17 06:53:35-05:00, stenn@whimsy.udel.edu + autogen upgrade cleanup + + clockstuff/clktest-opts.c@1.12 +130 -361 + autogen upgrade cleanup + + clockstuff/clktest-opts.h@1.12 +90 -100 + autogen upgrade cleanup + + libopts/autoopts/options.h@1.5 +7 -5 + autogen upgrade cleanup + + libopts/autoopts/usage-txt.h@1.5 +161 -152 + autogen upgrade cleanup + + libopts/genshell.c@1.5 +22 -15 + autogen upgrade cleanup + + libopts/genshell.h@1.5 +2 -2 + autogen upgrade cleanup + + ntpd/ntpdsim-opts.c@1.17 +237 -319 + autogen upgrade cleanup + + ntpd/ntpdsim-opts.h@1.17 +112 -139 + autogen upgrade cleanup + + sntp/libopts/autoopts/options.h@1.6 +7 -5 + autogen upgrade cleanup + + sntp/libopts/autoopts/usage-txt.h@1.6 +161 -152 + autogen upgrade cleanup + + sntp/libopts/genshell.c@1.6 +22 -15 + autogen upgrade cleanup + + sntp/libopts/genshell.h@1.6 +2 -2 + autogen upgrade cleanup + +ChangeSet@1.2060.3.41, 2009-11-17 06:44:44-05:00, stenn@whimsy.udel.edu + Upgrade to autogen 5.10 + + ChangeLog@1.496.1.50 +1 -0 + Upgrade to autogen 5.10 + + libopts/Makefile.am@1.2 +1 -1 + Upgrade to autogen 5.10 + + libopts/ag-char-map.h@1.5 +1 -1 + Upgrade to autogen 5.10 + + libopts/autoopts.c@1.4 +43 -26 + Upgrade to autogen 5.10 + + libopts/autoopts.h@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/boolean.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/compat/compat.h@1.4 +48 -25 + Upgrade to autogen 5.10 + + libopts/compat/pathfind.c@1.4 +1 -2 + Upgrade to autogen 5.10 + + libopts/compat/windows-config.h@1.4 +0 -1 + Upgrade to autogen 5.10 + + libopts/configfile.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/cook.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/enumeration.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/environment.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + libopts/file.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/load.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/m4/libopts.m4@1.5 +2 -8 + Upgrade to autogen 5.10 + + libopts/m4/liboptschk.m4@1.4 +0 -1 + Upgrade to autogen 5.10 + + libopts/makeshell.c@1.4 +41 -41 + Upgrade to autogen 5.10 + + libopts/nested.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/numeric.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/pgusage.c@1.4 +5 -4 + Upgrade to autogen 5.10 + + libopts/proto.h@1.5 +1 -1 + Upgrade to autogen 5.10 + + libopts/putshell.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/reset.c@1.4 +8 -2 + Upgrade to autogen 5.10 + + libopts/restore.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/save.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + libopts/sort.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/stack.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/streqvcmp.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/text_mmap.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/time.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/usage.c@1.4 +53 -18 + Upgrade to autogen 5.10 + + libopts/value-type.h@1.5 +1 -1 + Upgrade to autogen 5.10 + + libopts/version.c@1.4 +1 -1 + Upgrade to autogen 5.10 + + libopts/xat-attribute.h@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/Makefile.am@1.3 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/ag-char-map.h@1.6 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/autoopts.c@1.5 +43 -26 + Upgrade to autogen 5.10 + + sntp/libopts/autoopts.h@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/boolean.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/compat/compat.h@1.5 +48 -25 + Upgrade to autogen 5.10 + + sntp/libopts/compat/pathfind.c@1.5 +1 -2 + Upgrade to autogen 5.10 + + sntp/libopts/compat/windows-config.h@1.5 +0 -1 + Upgrade to autogen 5.10 + + sntp/libopts/configfile.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/cook.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/enumeration.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/environment.c@1.6 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/file.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/load.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/m4/libopts.m4@1.6 +2 -8 + Upgrade to autogen 5.10 + + sntp/libopts/m4/liboptschk.m4@1.5 +0 -1 + Upgrade to autogen 5.10 + + sntp/libopts/makeshell.c@1.5 +41 -41 + Upgrade to autogen 5.10 + + sntp/libopts/nested.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/numeric.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/pgusage.c@1.5 +5 -4 + Upgrade to autogen 5.10 + + sntp/libopts/proto.h@1.6 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/putshell.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/reset.c@1.5 +8 -2 + Upgrade to autogen 5.10 + + sntp/libopts/restore.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/save.c@1.6 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/sort.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/stack.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/streqvcmp.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/text_mmap.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/time.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/usage.c@1.5 +53 -18 + Upgrade to autogen 5.10 + + sntp/libopts/value-type.h@1.6 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/version.c@1.5 +1 -1 + Upgrade to autogen 5.10 + + sntp/libopts/xat-attribute.h@1.6 +1 -1 + Upgrade to autogen 5.10 + +ChangeSet@1.2060.3.40, 2009-11-17 07:27:53+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1384] ntpq :config core dumped with a blank password. + + ChangeLog@1.496.1.49 +1 -0 + [Bug 1384] ntpq :config core dumped with a blank password. + + ntpq/ntpq-subs.c@1.39.1.2 +60 -41 + [Bug 1384] ntpq :config core dumped with a blank password. + +ChangeSet@1.2060.22.1, 2009-11-17 04:25:42+00:00, davehart@shiny.ad.hartbrothers.com + use (peer->pmode == MODE_BROADCAST) rather than + (peer->castflags & MDF_BCLNT) to detect ephemeral broadcastclient + associations to exempt from peer_clear("XFAC") + + ChangeLog@1.496.18.1 +1 -0 + [Bug 1378] Unnecessary resetting of peers during interface update. + + ntpd/ntp_peer.c@1.125 +1 -1 + use (peer->pmode == MODE_BROADCAST) rather than + (peer->castflags & MDF_BCLNT) to detect broadcastclient + associations to exempt from peer_clear("XFAC"), suggested + by Frank Kardel. + +ChangeSet@1.2060.3.38, 2009-11-16 05:41:46+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1382] p245 configure --disable-dependency-tracking won't build + + ChangeLog@1.496.1.47 +1 -0 + [Bug 1382] p245 configure --disable-dependency-tracking won't build + + Makefile.am@1.86.1.3 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + adjtimed/Makefile.am@1.6 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + clockstuff/Makefile.am@1.9 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + depsver.mf@1.2 +31 -7 + tolerate --disable-dependency-tracking + use a more targeted ./config.status run + + include/ntpd.h@1.137 +1 -1 + silence "assignment discards qualifier" warning by using const char * + + libntp/Makefile.am@1.51 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + ntpd/cmd_args.c@1.55 +1 -4 + silence assignment discards qualifiers warning by eliminating assignment + + ntpd/ntpd.c@1.110 +1 -1 + silence "assignment discards qualifier" warning by using const char * + + ntpdate/Makefile.am@1.22 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + ntpq/Makefile.am@1.40 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + ntpsnmpd/Makefile.am@1.13 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + parseutil/Makefile.am@1.12 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + sntp/Makefile.am@1.13.1.5 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + + util/Makefile.am@1.43 +1 -0 + depsver.mf requires CLEANFILES be set even if empty + +ChangeSet@1.2060.3.37, 2009-11-14 08:29:21-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P245_RC + TAG: NTP_4_2_5P245_RC + + ChangeLog@1.496.1.46 +1 -0 + NTP_4_2_5P245_RC + + ntpd/ntpd-opts.c@1.239 +2 -2 + NTP_4_2_5P245_RC + + ntpd/ntpd-opts.h@1.239 +3 -3 + NTP_4_2_5P245_RC + + ntpd/ntpd-opts.texi@1.237 +1 -1 + NTP_4_2_5P245_RC + + ntpd/ntpd.1@1.237 +2 -2 + NTP_4_2_5P245_RC + + ntpdc/ntpdc-opts.c@1.235 +2 -2 + NTP_4_2_5P245_RC + + ntpdc/ntpdc-opts.h@1.235 +3 -3 + NTP_4_2_5P245_RC + + ntpdc/ntpdc-opts.texi@1.234 +1 -1 + NTP_4_2_5P245_RC + + ntpdc/ntpdc.1@1.234 +2 -2 + NTP_4_2_5P245_RC + + ntpq/ntpq-opts.c@1.236 +2 -2 + NTP_4_2_5P245_RC + + ntpq/ntpq-opts.h@1.236 +3 -3 + NTP_4_2_5P245_RC + + ntpq/ntpq-opts.texi@1.235 +1 -1 + NTP_4_2_5P245_RC + + ntpq/ntpq.1@1.235 +2 -2 + NTP_4_2_5P245_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.114 +2 -2 + NTP_4_2_5P245_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.114 +3 -3 + NTP_4_2_5P245_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.114 +1 -1 + NTP_4_2_5P245_RC + + ntpsnmpd/ntpsnmpd.1@1.114 +2 -2 + NTP_4_2_5P245_RC + + packageinfo.sh@1.249 +1 -1 + NTP_4_2_5P245_RC + + sntp/sntp-opts.c@1.108 +2 -2 + NTP_4_2_5P245_RC + + sntp/sntp-opts.h@1.108 +3 -3 + NTP_4_2_5P245_RC + + sntp/sntp-opts.texi@1.108 +1 -1 + NTP_4_2_5P245_RC + + sntp/sntp.1@1.108 +2 -2 + NTP_4_2_5P245_RC + + util/ntp-keygen-opts.c@1.238 +2 -2 + NTP_4_2_5P245_RC + + util/ntp-keygen-opts.h@1.238 +3 -3 + NTP_4_2_5P245_RC + + util/ntp-keygen-opts.texi@1.237 +1 -1 + NTP_4_2_5P245_RC + + util/ntp-keygen.1@1.237 +2 -2 + NTP_4_2_5P245_RC + +ChangeSet@1.2060.3.36, 2009-11-14 07:23:50-05:00, stenn@whimsy.udel.edu + Changes from Dave Mills + + ChangeLog@1.496.1.45 +1 -0 + Changes from Dave Mills + + html/authopt.html@1.59 +6 -5 + Cleanup from Dave Mills + + html/keygen.html@1.19 +6 -6 + Cleanup from Dave Mills + + html/miscopt.html@1.53 +9 -3 + Cleanup from Dave Mills + + libntp/authreadkeys.c@1.16 +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.153 +1 -1 + Cleanup from Dave Mills + + ntpd/refclock_local.c@1.20 +0 -9 + Cleanup from Dave Mills + +ChangeSet@1.2060.21.1, 2009-11-14 02:20:06+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1381] Version .deps generated include file dependencies to allow + known dependecy-breaking changes to force .deps to be cleaned, + triggered by changing the contents of deps-ver and/or sntp/deps-ver. + + ChangeLog@1.496.17.1 +3 -0 + [Bug 1381] Version .deps generated include file dependencies to allow + known dependecy-breaking changes to force .deps to be cleaned, + triggered by changing the contents of deps-ver and/or sntp/deps-ver. + + Makefile.am@1.86.1.2 +39 -39 + whitespace cleanup + no longer hunt down and remove CVS directories in distclean, + as we don't have them. + + adjtimed/Makefile.am@1.5 +3 -1 + include depsver.mf + + arlib/configure.in@1.3 +6 -3 + bring res_init check in line with main configure.ac to fix + arlib build break + + bootstrap@1.28 +1 -17 + remove disabled first whack at this issue + + clockstuff/Makefile.am@1.8 +3 -0 + include depsver.mf + + configure.ac@1.459.3.1 +0 -3 + remove duplicate AC_SEARCH_LIBS for setsockopt + + deps-ver@1.1 +1 -0 + a change to the contents of this file cleans any existing .deps + + deps-ver@1.0 +0 -0 + + depsver.mf@1.1 +43 -0 + .am include to implement .deps include file dependency versioning + + depsver.mf@1.0 +0 -0 + + libntp/Makefile.am@1.50 +2 -3 + include depsver.mf + remove ../include/des.h rule, no longer used + + libparse/Makefile.am@1.16 +3 -0 + include depsver.mf + + ntpd/Makefile.am@1.77 +2 -1 + include depsver.mf + + ntpd/ntp_peer.c@1.124 +0 -1 + remove stale comment, stoa() uses LIB_GETBUF() and is safe to call + repeatedly in the same printf(). + + ntpdate/Makefile.am@1.21 +4 -2 + include depsver.mf + + ntpdc/Makefile.am@1.45 +2 -1 + include depsver.mf + + ntpq/Makefile.am@1.39 +3 -0 + include depsver.mf + + ntpsnmpd/Makefile.am@1.12 +2 -0 + include depsver.mf + + parseutil/Makefile.am@1.11 +3 -0 + include depsver.mf + + sntp/Makefile.am@1.13.1.4 +4 -1 + include depsver.mf + + sntp/configure.ac@1.24.1.1 +1 -2 + AC_SEARCH_LIBS already tries without any libs, so wrapping with + AC_CHECK_FUNC just bloats + + sntp/deps-ver@1.1 +1 -0 + a change to the contents of this file cleans any existing .deps + + sntp/deps-ver@1.0 +0 -0 + + util/Makefile.am@1.42 +3 -0 + include depsver.mf + +ChangeSet@1.2060.3.34, 2009-11-13 13:31:39+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + mirror inet_ntop(), inet_pton() tests from top configure.ac + remomve ISC_PLATFORM_NEEDATON test, no longer used by libisc + + configure.ac@1.459.1.10 +0 -1 + remomve ISC_PLATFORM_NEEDATON test, no longer used by libisc + + sntp/configure.ac@1.25 +3 -0 + mirror inet_ntop(), inet_pton() tests from top configure.ac + +ChangeSet@1.2060.3.33, 2009-11-12 13:37:43+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1343] sntp illegal C does not compile on Solaris 7. + Windows VC9/VS2008: use generic library name libeay32.lib + instead of variants encoding build type to match what you + get building OpenSSL from source. + + ChangeLog@1.496.1.43 +1 -0 + [Bug 1343] sntp illegal C does not compile on Solaris 7. + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.9 +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.21.1.1 +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.12 +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.12 +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.11 +2 -2 + use generic library name libeay32.lib instead of variants + encoding build type to match what you get building OpenSSL + from source. + + sntp/log.c@1.11 +9 -9 + [Bug 1343] sntp illegal C does not compile on Solaris 7. + + sntp/main.c@1.21 +5 -8 + [Bug 1343] sntp illegal C does not compile on Solaris 7. + + sntp/networking.c@1.28 +14 -11 + [Bug 1343] sntp illegal C does not compile on Solaris 7. + +ChangeSet@1.2060.3.32, 2009-11-12 06:10:27-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P244_RC + TAG: NTP_4_2_5P244_RC + + ChangeLog@1.496.1.42 +1 -0 + NTP_4_2_5P244_RC + + ntpd/ntpd-opts.c@1.238 +2 -2 + NTP_4_2_5P244_RC + + ntpd/ntpd-opts.h@1.238 +3 -3 + NTP_4_2_5P244_RC + + ntpd/ntpd-opts.texi@1.236 +1 -1 + NTP_4_2_5P244_RC + + ntpd/ntpd.1@1.236 +2 -2 + NTP_4_2_5P244_RC + + ntpdc/ntpdc-opts.c@1.234 +2 -2 + NTP_4_2_5P244_RC + + ntpdc/ntpdc-opts.h@1.234 +3 -3 + NTP_4_2_5P244_RC + + ntpdc/ntpdc-opts.texi@1.233 +1 -1 + NTP_4_2_5P244_RC + + ntpdc/ntpdc.1@1.233 +2 -2 + NTP_4_2_5P244_RC + + ntpq/ntpq-opts.c@1.235 +2 -2 + NTP_4_2_5P244_RC + + ntpq/ntpq-opts.h@1.235 +3 -3 + NTP_4_2_5P244_RC + + ntpq/ntpq-opts.texi@1.234 +1 -1 + NTP_4_2_5P244_RC + + ntpq/ntpq.1@1.234 +2 -2 + NTP_4_2_5P244_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.113 +2 -2 + NTP_4_2_5P244_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.113 +3 -3 + NTP_4_2_5P244_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.113 +1 -1 + NTP_4_2_5P244_RC + + ntpsnmpd/ntpsnmpd.1@1.113 +2 -2 + NTP_4_2_5P244_RC + + packageinfo.sh@1.248 +1 -1 + NTP_4_2_5P244_RC + + sntp/sntp-opts.c@1.107 +2 -2 + NTP_4_2_5P244_RC + + sntp/sntp-opts.h@1.107 +3 -3 + NTP_4_2_5P244_RC + + sntp/sntp-opts.texi@1.107 +1 -1 + NTP_4_2_5P244_RC + + sntp/sntp.1@1.107 +2 -2 + NTP_4_2_5P244_RC + + util/ntp-keygen-opts.c@1.237 +2 -2 + NTP_4_2_5P244_RC + + util/ntp-keygen-opts.h@1.237 +3 -3 + NTP_4_2_5P244_RC + + util/ntp-keygen-opts.texi@1.236 +1 -1 + NTP_4_2_5P244_RC + + util/ntp-keygen.1@1.236 +2 -2 + NTP_4_2_5P244_RC + +ChangeSet@1.2060.3.31, 2009-11-12 04:26:17-05:00, stenn@whimsy.udel.edu + keygen.html updates from Dave Mills + + ChangeLog@1.496.1.41 +1 -0 + keygen.html updates from Dave Mills + + html/keygen.html@1.18 +46 -26 + keygen.html updates from Dave Mills + +ChangeSet@1.2060.3.30, 2009-11-12 02:29:11+00:00, davehart@shiny.ad.hartbrothers.com + ntp-keygen.c: + 21 bytes don't fit well in a 17 byte buffer + + util/ntp-keygen.c@1.63 +1 -1 + 21 bytes don't fit well in a 17 byte buffer + +ChangeSet@1.2060.3.29, 2009-11-12 00:51:35+00:00, davehart@shiny.ad.hartbrothers.com + Cleanup, fix ntp_intres when requestkey type means digests + larger than 16 octets. + Add /lib to OpenSSL library search path, OpenSolaris has it there. + + configure.ac@1.459.1.9 +1 -2 + Add /lib to OpenSSL library search path, OpenSolaris has it there. + + include/ntp_request.h@1.40 +5 -2 + accomodate larger digests in mode 7 struct req_pkt. + introduce REQ_TAIL_MIN to represent struct req_pkt_tail size with a + 16-octet digest. + + include/ntpd.h@1.136 +2 -0 + expose req_keytype, req_hashlen for ntp_config.c use + + libntp/authreadkeys.c@1.15 +6 -4 + bounds check keystr[] access, eliminate truncation warning + + libntp/hextoint.c@1.3 +14 -12 + fix indents, more error checks + + libntp/ssl_init.c@1.4 +17 -5 + #include for toupper() + + ntpd/ntp_config.c@1.236 +21 -6 + change #if 0 to #ifdef FORCE_DEFER_DNS + + ntpd/ntp_intres.c@1.70 +67 -27 + support new authentication layout with larger digests + remove dead debugging code, style + + ntpd/ntp_request.c@1.80.1.6 +3 -3 + account for growth of struct req_pkt_tail beyond 16-octet digest + by using REQ_TAIL_MIN instead of sizeof(req_pkt_tail). + fix format string warnings. + + ntpdc/layout.std@1.9 +2 -2 + req_pkt and req_pkt_tail both grew by 4 octets, but interop is + preserved + + ntpdc/ntpdc.c@1.74 +4 -4 + quiet shadows global warning + +ChangeSet@1.2060.20.1, 2009-11-11 12:36:24+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. + + ChangeLog@1.496.16.1 +5 -0 + [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. + + include/ntp_request.h@1.39 +10 -11 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + + include/ntp_stdlib.h@1.40 +7 -2 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + + libntp/a_md5encrypt.c@1.26 +2 -2 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + + libntp/authreadkeys.c@1.12.1.1 +5 -10 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + + libntp/ssl_init.c@1.3 +88 -5 + ntp-keygen, Autokey OpenSSL build vs. run version mismatch is now a + non-fatal warning. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + + ntpd/keyword-gen.c@1.5 +5 -5 + use + + do + a; + while (b); + + rather than equivalent + + a; + while(b) + a; + + ntpd/ntp_intres.c@1.67.1.1 +1 -1 + use sizeof buffer not (formerly) equivalent macro + + ntpd/ntp_request.c@1.80.1.5 +80 -88 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + + ntpdc/ntpdc.c@1.73 +143 -94 + [Bug 1003] ntpdc unconfig command doesn't prompt for keyid. + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + + ntpdc/ntpdc_ops.c@1.62 +2 -2 + whitespace only + + ntpq/ntpq-subs.c@1.39.1.1 +1 -1 + typo pointed out by Michael Tatarinov + + ntpq/ntpq.c@1.96 +93 -69 + [Bug 1376] Enable authenticated ntpq and ntpdc using newly-available + digest types. + +ChangeSet@1.2060.3.27, 2009-11-11 05:46:08-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P243_RC + TAG: NTP_4_2_5P243_RC + + ChangeLog@1.496.1.39 +1 -0 + NTP_4_2_5P243_RC + + ntpd/ntpd-opts.c@1.237 +2 -2 + NTP_4_2_5P243_RC + + ntpd/ntpd-opts.h@1.237 +3 -3 + NTP_4_2_5P243_RC + + ntpd/ntpd-opts.texi@1.235 +2 -2 + NTP_4_2_5P243_RC + + ntpd/ntpd.1@1.235 +2 -2 + NTP_4_2_5P243_RC + + ntpdc/ntpdc-opts.c@1.233 +2 -2 + NTP_4_2_5P243_RC + + ntpdc/ntpdc-opts.h@1.233 +3 -3 + NTP_4_2_5P243_RC + + ntpdc/ntpdc-opts.texi@1.232 +2 -2 + NTP_4_2_5P243_RC + + ntpdc/ntpdc.1@1.232 +2 -2 + NTP_4_2_5P243_RC + + ntpq/ntpq-opts.c@1.234 +2 -2 + NTP_4_2_5P243_RC + + ntpq/ntpq-opts.h@1.234 +3 -3 + NTP_4_2_5P243_RC + + ntpq/ntpq-opts.texi@1.233 +2 -2 + NTP_4_2_5P243_RC + + ntpq/ntpq.1@1.233 +2 -2 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.112 +2 -2 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.112 +3 -3 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.112 +1 -1 + NTP_4_2_5P243_RC + + ntpsnmpd/ntpsnmpd.1@1.112 +2 -2 + NTP_4_2_5P243_RC + + packageinfo.sh@1.247 +1 -1 + NTP_4_2_5P243_RC + + sntp/sntp-opts.c@1.106 +2 -2 + NTP_4_2_5P243_RC + + sntp/sntp-opts.h@1.106 +3 -3 + NTP_4_2_5P243_RC + + sntp/sntp-opts.texi@1.106 +2 -2 + NTP_4_2_5P243_RC + + sntp/sntp.1@1.106 +2 -2 + NTP_4_2_5P243_RC + + util/ntp-keygen-opts.c@1.236 +2 -2 + NTP_4_2_5P243_RC + + util/ntp-keygen-opts.h@1.236 +3 -3 + NTP_4_2_5P243_RC + + util/ntp-keygen-opts.texi@1.235 +2 -2 + NTP_4_2_5P243_RC + + util/ntp-keygen.1@1.235 +2 -2 + NTP_4_2_5P243_RC + +ChangeSet@1.2060.3.26, 2009-11-11 04:04:33-05:00, stenn@pogo.udel.edu + [Bug 1226] Fix deferred DNS lookups + + ChangeLog@1.496.1.38 +1 -0 + [Bug 1226] Fix deferred DNS lookups + +ChangeSet@1.2060.19.2, 2009-11-11 03:08:32-05:00, stenn@whimsy.udel.edu + new crypto signature cleanup + + ChangeLog@1.496.1.37 +1 -0 + new crypto signature cleanup + + html/authopt.html@1.58 +14 -5 + new crypto signature cleanup + + html/keygen.html@1.17 +12 -3 + new crypto signature cleanup + + libntp/authkeys.c@1.20 +11 -2 + new crypto signature cleanup + + libntp/authreadkeys.c@1.13 +38 -12 + new crypto signature cleanup + + util/ntp-keygen.c@1.62 +24 -4 + new crypto signature cleanup + +ChangeSet@1.2060.19.1, 2009-11-10 05:02:56-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P242_RC + TAG: NTP_4_2_5P242_RC + + ChangeLog@1.496.1.36 +1 -0 + NTP_4_2_5P242_RC + + ntpd/ntpd-opts.c@1.236 +2 -2 + NTP_4_2_5P242_RC + + ntpd/ntpd-opts.h@1.236 +3 -3 + NTP_4_2_5P242_RC + + ntpd/ntpd-opts.texi@1.234 +2 -2 + NTP_4_2_5P242_RC + + ntpd/ntpd.1@1.234 +2 -2 + NTP_4_2_5P242_RC + + ntpdc/ntpdc-opts.c@1.232 +2 -2 + NTP_4_2_5P242_RC + + ntpdc/ntpdc-opts.h@1.232 +3 -3 + NTP_4_2_5P242_RC + + ntpdc/ntpdc-opts.texi@1.231 +2 -2 + NTP_4_2_5P242_RC + + ntpdc/ntpdc.1@1.231 +2 -2 + NTP_4_2_5P242_RC + + ntpq/ntpq-opts.c@1.233 +2 -2 + NTP_4_2_5P242_RC + + ntpq/ntpq-opts.h@1.233 +3 -3 + NTP_4_2_5P242_RC + + ntpq/ntpq-opts.texi@1.232 +2 -2 + NTP_4_2_5P242_RC + + ntpq/ntpq.1@1.232 +2 -2 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.111 +2 -2 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.111 +3 -3 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.111 +1 -1 + NTP_4_2_5P242_RC + + ntpsnmpd/ntpsnmpd.1@1.111 +2 -2 + NTP_4_2_5P242_RC + + packageinfo.sh@1.246 +1 -1 + NTP_4_2_5P242_RC + + sntp/sntp-opts.c@1.105 +2 -2 + NTP_4_2_5P242_RC + + sntp/sntp-opts.h@1.105 +3 -3 + NTP_4_2_5P242_RC + + sntp/sntp-opts.texi@1.105 +2 -2 + NTP_4_2_5P242_RC + + sntp/sntp.1@1.105 +2 -2 + NTP_4_2_5P242_RC + + util/ntp-keygen-opts.c@1.235 +2 -2 + NTP_4_2_5P242_RC + + util/ntp-keygen-opts.h@1.235 +3 -3 + NTP_4_2_5P242_RC + + util/ntp-keygen-opts.texi@1.234 +2 -2 + NTP_4_2_5P242_RC + + util/ntp-keygen.1@1.234 +2 -2 + NTP_4_2_5P242_RC + +ChangeSet@1.2060.3.24, 2009-11-09 18:15:07-05:00, murray@malarky.udel.edu + configure.ac, ntp_intres.c: + Fix for bug-1266: reload /etc/resolv.conf on deferred DNS + ntp_config.c: + Hacks to help debug deferred DNS + (default off) + + configure.ac@1.459.1.8 +4 -0 + Fix for bug-1266: reload /etc/resolv.conf on deferred DNS + + ntpd/ntp_config.c@1.235 +16 -0 + Hacks to help debug deferred DNS + (default off) + + ntpd/ntp_intres.c@1.68 +15 -7 + Fix for bug-1266: reload /etc/resolv.conf on deferred DNS + +ChangeSet@1.2060.18.2, 2009-11-09 04:14:13-05:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.496.15.2 +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.57 +5 -3 + Documentation updates from Dave Mills + + html/index.html@1.41 +25 -4 + Documentation updates from Dave Mills + +ChangeSet@1.2060.18.1, 2009-11-09 04:08:41-05:00, stenn@whimsy.udel.edu + authkeys.c cleanup from Dave Mills + + ChangeLog@1.496.15.1 +1 -0 + authkeys.c cleanup from Dave Mills + + libntp/authkeys.c@1.17.1.1 +3 -4 + authkeys.c cleanup from Dave Mills + +ChangeSet@1.2060.3.22, 2009-11-09 08:03:02+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1371] deferred DNS lookup failing with INFO_ERR_AUTH. + fixed in prior changeset with ntp_request.h modification + to REQ_LEN_NOMAC. + + ChangeLog@1.496.1.34 +1 -0 + [Bug 1371] deferred DNS lookup failing with INFO_ERR_AUTH. + +ChangeSet@1.2060.5.2, 2009-11-09 07:19:52+00:00, davehart@shiny.ad.hartbrothers.com + Shrink keyword scanner FSM entries from 64 to 32 bits apiece. + applies to prior changeset and this ChangeLog update + + ChangeLog@1.496.14.1 +1 -0 + Shrink keyword scanner FSM entries from 64 to 32 bits apiece. + +ChangeSet@1.2060.3.19, 2009-11-09 07:17:29+00:00, davehart@shiny.ad.hartbrothers.com + Stub out isc/mem.h, shaving 47k from a MIPS ntpd binary. + (applies to prior changeset along with this one) + + ChangeLog@1.496.13.1 +1 -0 + Stub out isc/mem.h, shaving 47k from a MIPS ntpd binary. + + include/isc/mem.h@1.2 +1 -0 + also stub out isc_mem_printallactive() to silence warning and avoid + trouble down the road, it's referenced by tasks.c + +ChangeSet@1.2060.17.1, 2009-11-08 12:32:55+00:00, kardel@pogo.udel.edu + clk_trimtsip.c: + [Bug 1363] CID 92 clarify fallthrough case + ChangeLog: + [Bug 1363] CID 92 clarify fallthrough case in clk_trimtsip.c + + ChangeLog@1.496.12.1 +1 -0 + [Bug 1363] CID 92 clarify fallthrough case in clk_trimtsip.c + + libparse/clk_trimtsip.c@1.10 +10 -3 + [Bug 1363] CID 92 clarify fallthrough case + +ChangeSet@1.2060.9.22, 2009-11-07 23:44:10+00:00, davehart@shiny.ad.hartbrothers.com + Use Frank Kardel's suggestion to collapse 3 cases to 1 for NetBSD + USE_FSETOWNCTTY test. + + configure.ac@1.459.2.4 +4 -9 + Use Frank Kardel's suggestion to collapse 3 cases to 1 for NetBSD + USE_FSETOWNCTTY test. + +ChangeSet@1.2060.16.2, 2009-11-07 22:46:41+00:00, davehart@shiny.ad.hartbrothers.com + Fix authenticated ntpdc, broken in p240. + + ChangeLog@1.496.11.2 +1 -0 + Fix authenticated ntpdc, broken in p240. + + include/ntp.h@1.168 +4 -4 + parenthesize macro expansions such as: + 12 * sizeof(u_int32) + + include/ntp_request.h@1.38 +4 -4 + comments only + + include/ntp_stdlib.h@1.39 +3 -2 + separate OpenSSL version check from INIT_SSL() + + libntp/a_md5encrypt.c@1.23.1.2 +2 -2 + [Bug 1368] libntp does not compile --without-crypto + merge cleanup + + libntp/authkeys.c@1.18 +3 -4 + move break; in authhavekey() back where it belongs after recent + flub + + libntp/authreadkeys.c@1.10.1.2 +1 -1 + [Bug 1368] libntp doesn't compile --without-crypto + + libntp/ssl_init.c@1.2 +11 -3 + separate OpenSSL version check from INIT_SSL() + + ntpd/ntp_control.c@1.129 +1 -1 + correct harmless htons()/ntohs() mixup + + ntpd/ntp_crypto.c@1.146 +3 -2 + separate OpenSSL version check from INIT_SSL() + + ntpd/ntp_intres.c@1.67 +2 -2 + use sizeof rather than REQ_MAC_LEN for recv buffer size to prepare + for enabling authenticated mode 7 with non-MD5 keys + + ntpd/ntp_request.c@1.80.1.4 +8 -7 + eliminate extra parentheses, return after req_ack() + + ntpdc/ntpdc.c@1.72 +11 -11 + Fix authenticated ntpdc, broken in p240. + + util/ntp-keygen.c@1.61 +1 -1 + separate OpenSSL version check from INIT_SSL() + +ChangeSet@1.2060.9.20, 2009-11-07 12:16:01-05:00, murray@pogo.udel.edu + a_md5encrypt.c, authreadkeys.c, ChangeLog: + Fix for bug 1368 - typos in --without-crypto case + + ChangeLog@1.496.1.30 +1 -0 + Fix for bug 1368 + + libntp/a_md5encrypt.c@1.24 +1 -0 + Fix for bug 1368 + + libntp/authreadkeys.c@1.11 +1 -1 + Fix for bug 1368 + +ChangeSet@1.2060.9.19, 2009-11-07 05:42:36-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P241_RC + TAG: NTP_4_2_5P241_RC + + ChangeLog@1.496.1.29 +1 -0 + NTP_4_2_5P241_RC + + ntpd/ntpd-opts.c@1.235 +2 -2 + NTP_4_2_5P241_RC + + ntpd/ntpd-opts.h@1.235 +3 -3 + NTP_4_2_5P241_RC + + ntpd/ntpd-opts.texi@1.233 +2 -2 + NTP_4_2_5P241_RC + + ntpd/ntpd.1@1.233 +2 -2 + NTP_4_2_5P241_RC + + ntpdc/ntpdc-opts.c@1.231 +2 -2 + NTP_4_2_5P241_RC + + ntpdc/ntpdc-opts.h@1.231 +3 -3 + NTP_4_2_5P241_RC + + ntpdc/ntpdc-opts.texi@1.230 +2 -2 + NTP_4_2_5P241_RC + + ntpdc/ntpdc.1@1.230 +2 -2 + NTP_4_2_5P241_RC + + ntpq/ntpq-opts.c@1.232 +2 -2 + NTP_4_2_5P241_RC + + ntpq/ntpq-opts.h@1.232 +3 -3 + NTP_4_2_5P241_RC + + ntpq/ntpq-opts.texi@1.231 +2 -2 + NTP_4_2_5P241_RC + + ntpq/ntpq.1@1.231 +2 -2 + NTP_4_2_5P241_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.110 +2 -2 + NTP_4_2_5P241_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.110 +3 -3 + NTP_4_2_5P241_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.110 +1 -1 + NTP_4_2_5P241_RC + + ntpsnmpd/ntpsnmpd.1@1.110 +2 -2 + NTP_4_2_5P241_RC + + packageinfo.sh@1.245 +1 -1 + NTP_4_2_5P241_RC + + sntp/sntp-opts.c@1.104 +2 -2 + NTP_4_2_5P241_RC + + sntp/sntp-opts.h@1.104 +3 -3 + NTP_4_2_5P241_RC + + sntp/sntp-opts.texi@1.104 +2 -2 + NTP_4_2_5P241_RC + + sntp/sntp.1@1.104 +2 -2 + NTP_4_2_5P241_RC + + util/ntp-keygen-opts.c@1.234 +2 -2 + NTP_4_2_5P241_RC + + util/ntp-keygen-opts.h@1.234 +3 -3 + NTP_4_2_5P241_RC + + util/ntp-keygen-opts.texi@1.233 +2 -2 + NTP_4_2_5P241_RC + + util/ntp-keygen.1@1.233 +2 -2 + NTP_4_2_5P241_RC + +ChangeSet@1.2060.15.1, 2009-11-07 07:57:11+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. + initialize OpenSSL before first use in libntp + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + add crypto digest and setvar default tests to ntpd/complete.conf + + ChangeLog@1.496.10.1 +2 -0 + [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. + CID 87 dead code in ntpq.c atoascii(). + + + configure.ac@1.459.2.3 +44 -26 + [Bug 1366] ioctl(TIOCSCTTY, 0) fails on NetBSD *[0-2].* > 3.99.7. + + include/Makefile.am@1.35.2.2 +1 -0 + new file include/ssl_applink.c + + include/ntp.h@1.167 +2 -1 + make KEY_TYPE_MD5 equivalence to NID_md5 explicit + + include/ntp_request.h@1.37 +1 -1 + req_pkt uses MAX_MD5_LEN not MAX_MAC_LEN now + + include/ntp_stdlib.h@1.38 +13 -0 + add ssl_init.c references + + include/ssl_applink.c@1.1 +74 -0 + common code for Windows OpenSSL applink (ntpd, ntpdate, ntpdc, ntpq, ntp-keygen) + + include/ssl_applink.c@1.0 +0 -0 + + libntp/Makefile.am@1.47.1.1 +65 -13 + add ssl_init.c + + libntp/a_md5encrypt.c@1.22.1.1 +15 -6 + ensure OpenSSL has been initialized before use + use u_int instead of unsigned consistently + + libntp/authreadkeys.c@1.9.1.1 +3 -7 + warning + + libntp/ssl_init.c@1.1 +42 -0 + Shared OpenSSL initialization code for libntp, ntpd, ntp-keygen + + libntp/ssl_init.c@1.0 +0 -0 + + ntpd/complete.conf@1.3 +3 -2 + add crypto digest test, setvar default test + + ntpd/ntp_config.c@1.234 +1 -1 + KEY_TYPE_MD5 -> NID_md5 + + ntpd/ntp_crypto.c@1.145 +13 -23 + use common libntp OpenSSL initialization code + + ntpd/ntp_request.c@1.80.1.3 +3 -5 + don't compare floats for equality, use DPRINTF + + ntpdate/ntpdate.c@1.69 +10 -16 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ntpdc/ntpdc.c@1.71 +6 -11 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ntpq/Makefile.am@1.38 +3 -0 + add rule to build libntp.a + + ntpq/ntpq.c@1.95 +77 -78 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ports/winnt/ntpd/ntservice.c@1.22 +3 -39 + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + + ports/winnt/vc6/libntp.dsp@1.43.3.1 +4 -0 + add ssl_init.c + + ports/winnt/vs2003/libntp.vcproj@1.4.2.1 +4 -0 + add ssl_init.c + + ports/winnt/vs2005/libntp.vcproj@1.4.2.1 +4 -0 + add ssl_init.c + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20.2.1 +6 -2 + add ssl_init.c + + sntp/Makefile.am@1.13.2.1 +9 -1 + remove reference to bk rm'd netutils.h + add rule to build libntp.a + add rule to build COPYRIGHT with zero-byte version bk rm'd + + util/ntp-keygen.c@1.60 +7 -23 + Use common OpenSSL initialization from libntp + ntpq, ntpdc, ntpdate use OpenSSL and need applink on Windows + +ChangeSet@1.2060.9.18, 2009-11-07 01:15:29-05:00, stenn@whimsy.udel.edu + authopt.html update from Dave Mills + + ChangeLog@1.496.1.28 +1 -0 + authopt.html update from Dave Mills + + html/authopt.html@1.56 +59 -29 + authopt.html update from Dave Mills + +ChangeSet@1.2060.9.17, 2009-11-07 01:09:12-05:00, stenn@whimsy.udel.edu + Remove unused file from the sntp/Makefile.am + + ChangeLog@1.496.1.27 +1 -0 + Remove unused file from the sntp/Makefile.am + + ChangeLog@1.496.1.26 +1 -0 + new crypto signature cleanup + + libntp/a_md5encrypt.c@1.23 +23 -23 + new crypto signature cleanup + + libntp/authkeys.c@1.17 +54 -13 + new crypto signature cleanup + + libntp/authreadkeys.c@1.10 +31 -22 + new crypto signature cleanup + + sntp/Makefile.am@1.13.1.2 +0 -1 + Remove unused file from the sntp/Makefile.am + +ChangeSet@1.2060.9.16, 2009-11-05 04:05:18-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P240_RC + TAG: NTP_4_2_5P240_RC + + ChangeLog@1.496.1.25 +1 -0 + NTP_4_2_5P240_RC + + ntpd/ntpd-opts.c@1.234 +2 -2 + NTP_4_2_5P240_RC + + ntpd/ntpd-opts.h@1.234 +3 -3 + NTP_4_2_5P240_RC + + ntpd/ntpd-opts.texi@1.232 +4 -4 + NTP_4_2_5P240_RC + + ntpd/ntpd.1@1.232 +2 -2 + NTP_4_2_5P240_RC + + ntpdc/ntpdc-opts.c@1.230 +2 -2 + NTP_4_2_5P240_RC + + ntpdc/ntpdc-opts.h@1.230 +3 -3 + NTP_4_2_5P240_RC + + ntpdc/ntpdc-opts.texi@1.229 +2 -2 + NTP_4_2_5P240_RC + + ntpdc/ntpdc.1@1.229 +2 -2 + NTP_4_2_5P240_RC + + ntpq/ntpq-opts.c@1.231 +2 -2 + NTP_4_2_5P240_RC + + ntpq/ntpq-opts.h@1.231 +3 -3 + NTP_4_2_5P240_RC + + ntpq/ntpq-opts.texi@1.230 +2 -2 + NTP_4_2_5P240_RC + + ntpq/ntpq.1@1.230 +2 -2 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.109 +2 -2 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.109 +3 -3 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.109 +1 -1 + NTP_4_2_5P240_RC + + ntpsnmpd/ntpsnmpd.1@1.109 +2 -2 + NTP_4_2_5P240_RC + + packageinfo.sh@1.244 +1 -1 + NTP_4_2_5P240_RC + + sntp/sntp-opts.c@1.103 +2 -2 + NTP_4_2_5P240_RC + + sntp/sntp-opts.h@1.103 +3 -3 + NTP_4_2_5P240_RC + + sntp/sntp-opts.texi@1.103 +2 -2 + NTP_4_2_5P240_RC + + sntp/sntp.1@1.103 +2 -2 + NTP_4_2_5P240_RC + + util/ntp-keygen-opts.c@1.233 +2 -2 + NTP_4_2_5P240_RC + + util/ntp-keygen-opts.h@1.233 +3 -3 + NTP_4_2_5P240_RC + + util/ntp-keygen-opts.texi@1.232 +2 -2 + NTP_4_2_5P240_RC + + util/ntp-keygen.1@1.232 +2 -2 + NTP_4_2_5P240_RC + +ChangeSet@1.2060.14.2, 2009-11-05 02:04:25-05:00, stenn@whimsy.udel.edu + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + ChangeLog@1.496.9.2 +1 -1 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + html/authopt.html@1.55 +20 -17 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + html/keygen.html@1.16 +33 -9 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + libntp/a_md5encrypt.c@1.20.1.1 +2 -2 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + + libntp/authkeys.c@1.16 +1 -2 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS 140-2) + +ChangeSet@1.2060.9.14, 2009-11-05 01:33:53+00:00, davehart@shiny.ad.hartbrothers.com + remove leftover RSAREF tidbit global.h no longer used + + BitKeeper/deleted/.del-global.h~3aed0663@1.5 +0 -0 + Delete: include/global.h + + include/Makefile.am@1.35.2.1 +0 -1 + remove leftover RSAREF tidbit global.h no longer used + +ChangeSet@1.2060.9.13, 2009-11-05 00:24:26+00:00, davehart@shiny.ad.hartbrothers.com + remove testing leftover #undef OPENSSL + warning cleanup + linking with libntp now requires -lcrypto / libeay32.lib + + + include/ntp_stdlib.h@1.37 +8 -0 + #define NID_md5 when not building with OpenSSL + + libntp/a_md5encrypt.c@1.21 +22 -28 + remove testing leftover #undef OPENSSL + warning cleanup + assert rather than crash if openssl isn't working + + libntp/authreadkeys.c@1.9 +6 -6 + remove testing leftover #undef OPENSSL + warning cleanup + + ntpdate/Makefile.am@1.20 +1 -0 + add -lcrypto to ntpdate_LDADD now that libntp references openssl + + ntpdc/Makefile.am@1.44 +2 -1 + linking with libntp now requires -lcrypto + + ntpq/Makefile.am@1.37 +2 -1 + linking with libntp now requires -lcrypto + + ports/winnt/vc6/ntpdate.dsp@1.25 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vc6/ntpdc.dsp@1.28 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vc6/ntpq.dsp@1.29 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2003/ntpdate.vcproj@1.4 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2003/ntpdc.vcproj@1.4 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2003/ntpq.vcproj@1.4 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2005/ntpdate.vcproj@1.4 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2005/ntpdc.vcproj@1.4 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2005/ntpq.vcproj@1.4 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.11 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.11 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.10 +2 -2 + add reference to libeay32.lib needed by symmetric key crypto now + +ChangeSet@1.2060.14.1, 2009-11-04 14:53:24-05:00, stenn@whimsy.udel.edu + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ChangeLog@1.496.9.1 +1 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + html/authopt.html@1.54 +32 -3 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + html/ntpq.html@1.36 +12 -4 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp.h@1.166 +4 -4 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_control.h@1.38 +5 -4 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_crypto.h@1.46 +2 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_request.h@1.36 +2 -2 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + include/ntp_stdlib.h@1.36 +3 -3 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/a_md5encrypt.c@1.20 +63 -21 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/authkeys.c@1.15 +13 -17 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/authreadkeys.c@1.8 +50 -38 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + libntp/authusekey.c@1.7 +1 -13 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/keyword-gen.c@1.1.1.2 +1 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_config.c@1.233 +8 -18 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_control.c@1.128 +17 -7 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_crypto.c@1.144 +17 -3 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_keyword.h@1.1.1.1 +737 -732 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_parser.c@1.52 +1031 -1013 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_parser.h@1.32 +277 -275 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_parser.y@1.47 +3 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + ntpd/ntp_proto.c@1.297 +13 -18 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + + sntp/crypto.h@1.5.1.1 +1 -0 + Provide all of OpenSSL's signature methods for ntp.keys (FIPS xxx) + +ChangeSet@1.2060.9.11, 2009-11-02 19:31:57+00:00, davehart@shiny.ad.hartbrothers.com + correct linuxcaps AC_MSG_RESULT() to occur after considering + --enable-linuxcaps + + configure.ac@1.459.2.2 +1 -4 + correct linuxcaps AC_MSG_RESULT() to occur after considering + --enable-linuxcaps + +ChangeSet@1.2060.13.1, 2009-11-02 06:08:22+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. + + ChangeLog@1.496.1.22 +1 -0 + [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. + + configure.ac@1.459.2.1 +4 -2 + [Bug 1364] clock_gettime() not detected, need -lrt on Debian 5.0.3. + bump cache version so previous results not finding clock_gettime() will + be tossed. + +ChangeSet@1.2060.9.9, 2009-10-31 06:38:39+09:00, Amidamaru@yumi.mxiesoft.com + .del-netutils.c~1f7e234e73bebdf5: + Delete: sntp/netutils.c + .del-COPYRIGHT~cdd0795ee52aa7b5: + Delete: sntp/COPYRIGHT + .del-netutils.h~b347f6069a2cfce1: + Delete: sntp/netutils.h + Many files: + Removed copyright statement + + BitKeeper/deleted/.del-COPYRIGHT~cdd0795ee52aa7b5@1.3 +0 -0 + Delete: sntp/COPYRIGHT + + BitKeeper/deleted/.del-netutils.c~1f7e234e73bebdf5@1.4 +0 -0 + Delete: sntp/netutils.c + + BitKeeper/deleted/.del-netutils.h~b347f6069a2cfce1@1.3 +0 -0 + Delete: sntp/netutils.h + + sntp/crypto.c@1.10 +0 -17 + Removed copyright statement + + sntp/crypto.h@1.6 +0 -17 + Removed copyright statement + + sntp/kod_management.c@1.14 +0 -18 + Removed copyright statement + + sntp/kod_management.h@1.8 +0 -17 + Removed copyright statement + + sntp/log.c@1.10 +0 -17 + Removed copyright statement + + sntp/log.h@1.7 +0 -17 + Removed copyright statement + + sntp/networking.c@1.27 +0 -17 + Removed copyright statement + + sntp/networking.h@1.16 +0 -17 + Removed copyright statement + + sntp/utilities.c@1.10 +0 -17 + Removed copyright statement + + sntp/utilities.h@1.8 +0 -34 + Removed copyright statement + +ChangeSet@1.2060.9.8, 2009-10-30 01:30:30-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P239_RC + TAG: NTP_4_2_5P239_RC + + ChangeLog@1.496.1.21 +1 -0 + NTP_4_2_5P239_RC + + ntpd/ntpd-opts.c@1.233 +2 -2 + NTP_4_2_5P239_RC + + ntpd/ntpd-opts.h@1.233 +3 -3 + NTP_4_2_5P239_RC + + ntpd/ntpd-opts.texi@1.231 +1 -1 + NTP_4_2_5P239_RC + + ntpd/ntpd.1@1.231 +2 -2 + NTP_4_2_5P239_RC + + ntpdc/ntpdc-opts.c@1.229 +2 -2 + NTP_4_2_5P239_RC + + ntpdc/ntpdc-opts.h@1.229 +3 -3 + NTP_4_2_5P239_RC + + ntpdc/ntpdc-opts.texi@1.228 +1 -1 + NTP_4_2_5P239_RC + + ntpdc/ntpdc.1@1.228 +2 -2 + NTP_4_2_5P239_RC + + ntpq/ntpq-opts.c@1.230 +2 -2 + NTP_4_2_5P239_RC + + ntpq/ntpq-opts.h@1.230 +3 -3 + NTP_4_2_5P239_RC + + ntpq/ntpq-opts.texi@1.229 +1 -1 + NTP_4_2_5P239_RC + + ntpq/ntpq.1@1.229 +2 -2 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.108 +2 -2 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.108 +3 -3 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.108 +1 -1 + NTP_4_2_5P239_RC + + ntpsnmpd/ntpsnmpd.1@1.108 +2 -2 + NTP_4_2_5P239_RC + + packageinfo.sh@1.243 +1 -1 + NTP_4_2_5P239_RC + + sntp/sntp-opts.c@1.102 +2 -2 + NTP_4_2_5P239_RC + + sntp/sntp-opts.h@1.102 +3 -3 + NTP_4_2_5P239_RC + + sntp/sntp-opts.texi@1.102 +1 -1 + NTP_4_2_5P239_RC + + sntp/sntp.1@1.102 +2 -2 + NTP_4_2_5P239_RC + + util/ntp-keygen-opts.c@1.232 +2 -2 + NTP_4_2_5P239_RC + + util/ntp-keygen-opts.h@1.232 +3 -3 + NTP_4_2_5P239_RC + + util/ntp-keygen-opts.texi@1.231 +1 -1 + NTP_4_2_5P239_RC + + util/ntp-keygen.1@1.231 +2 -2 + NTP_4_2_5P239_RC + +ChangeSet@1.2060.12.1, 2009-10-29 02:55:07-05:00, stenn@whimsy.udel.edu + CID 101 and Bug 1359 + + ChangeLog@1.496.8.2 +1 -0 + CID 101: more pointer/array cleanup + + ChangeLog@1.496.8.1 +1 -0 + CID 101: more pointer/array cleanup + + ntpd/ntp_crypto.c@1.143 +2 -1 + CID 101: more pointer/array cleanup + + ntpd/ntp_loopfilter.c@1.152 +2 -1 + CID 101: more pointer/array cleanup + +ChangeSet@1.2060.9.6, 2009-10-28 15:49:51-04:00, murray@pogo.udel.edu + ChangeLog: + Bug-1357: bogus assert in refclock_shm + + ChangeLog@1.496.1.19 +1 -0 + Bug-1357: bogus assert in refclock_shm + +ChangeSet@1.2060.9.5, 2009-10-28 13:32:36-04:00, murray@pogo.udel.edu + refclock_shm.c: + Fix for bug-1357: bogus assert in refclock_shm + + ntpd/refclock_shm.c@1.19 +4 -1 + Fix for bug-1357: bogus assert in refclock_shm + +ChangeSet@1.2060.10.2, 2009-10-28 09:19:39+00:00, davehart@shiny.ad.hartbrothers.com + networking.c: + 2nd half of [Bug 1158] in recv_bcast_data() + + sntp/networking.c@1.26 +1 -1 + 2nd half of [Bug 1158] in recv_bcast_data() + +ChangeSet@1.2060.11.1, 2009-10-28 03:47:47-05:00, stenn@whimsy.udel.edu + CID 101: pointer/array cleanup + + ChangeLog@1.496.7.1 +1 -0 + CID 101: pointer/array cleanup + + ntpd/ntp_crypto.c@1.142 +10 -10 + CID 101: pointer/array cleanup + +ChangeSet@1.2060.10.1, 2009-10-28 07:35:54+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. + + ChangeLog@1.496.6.1 +1 -0 + [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. + + include/ntp_rfc2553.h@1.33 +17 -2 + conditionalize definition of AI_ flags on AI_PASSIVE instead of + AI_NUMERICHOST, as the latter isn't defined on AIX 4.3 while + AI_PASSIVE is. + provide a 0 definition for AI_NUMERICHOST for those platforms + that don't have that flag. + + ntpd/ntp_io.c@1.306.2.1 +0 -14 + move INCLUDE_IPV6_SUPPORT and INCLUDE_IPV6_MULTICAST_SUPPORT + definitions to ntp_rfc2553.h to share with sntp + + sntp/networking.c@1.25 +8 -3 + Compile on systems such as AIX 4.3 with IPv6 but without IPv6 multicast + support via setsockopt(), + [Bug 1358] AIX 4.3 sntp/networking.c IPV6_JOIN_GROUP undeclared. + + sntp/networking.h@1.15 +1 -0 + pick up INCLUDE_IPV6_MULTICAST_SUPPORT from ntp_rfc2553.h + +ChangeSet@1.2060.9.1, 2009-10-28 03:42:47+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. + + ChangeLog@1.496.1.16 +1 -0 + [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. + + ntpd/refclock_nmea.c@1.46 +17 -8 + [Bug 1356] core dump from refclock_nmea when can't open /dev/gpsU. + +ChangeSet@1.2060.3.18, 2009-10-27 21:53:59+00:00, davehart@shiny.ad.hartbrothers.com + stub out isc/mem.c using NTP-local /include/isc/mem.h (leaving + /lib/isc/include/isc/mem.h untouched). + + configure.ac@1.459.1.6 +1 -0 + add reference to include/isc/Makefile + + include/Makefile.am@1.35.1.2 +3 -2 + add reference to include/isc/Makefile.am + + include/isc/Makefile.am@1.1 +7 -0 + Override isc/mem.h for NTP to stub it out and save ~50KB + + include/isc/Makefile.am@1.0 +0 -0 + + include/isc/mem.h@1.1 +54 -0 + Override isc/mem.h for NTP to stub it out and save ~50KB + + include/isc/mem.h@1.0 +0 -0 + + libntp/Makefile.am@1.48 +0 -1 + mem.c is stubbed out + + libntp/emalloc.c@1.10 +3 -2 + implement GNU malloc behavior in emalloc() and erealloc(), libisc mem.h + stubs depend on it (could be implemented in mem.h, but other code may + grow a dependency being tested only on GNU malloc, so play it safe.) + + ntpd/ntp_io.c@1.306.1.2 +1 -37 + remove ntp_memalloc(), ntp_memfree(), pass dummy non-null mctx + to to libisc interface iterator. + + ports/winnt/vc6/libntp.dsp@1.43.1.4 +0 -4 + lib/isc/mem.c is no longer compiled + + ports/winnt/vs2003/libntp.vcproj@1.4.1.2 +1 -4 + remove change mem.h reference to NTP override copy in include/isc + lib/isc/mem.c is no longer compiled. + + ports/winnt/vs2005/libntp.vcproj@1.4.1.2 +1 -5 + remove change mem.h reference to NTP override copy in include/isc + lib/isc/mem.c is no longer compiled. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20.1.3 +1 -5 + remove change mem.h reference to NTP override copy in include/isc + lib/isc/mem.c is no longer compiled. + + util/ntptime.c@1.21 +1 -0 + add "int debug;" global for libntp consumption + +ChangeSet@1.2060.3.17, 2009-10-27 05:47:37-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P238_RC + TAG: NTP_4_2_5P238_RC + + ChangeLog@1.496.1.15 +1 -0 + NTP_4_2_5P238_RC + + ntpd/ntpd-opts.c@1.232 +2 -2 + NTP_4_2_5P238_RC + + ntpd/ntpd-opts.h@1.232 +3 -3 + NTP_4_2_5P238_RC + + ntpd/ntpd-opts.texi@1.230 +1 -1 + NTP_4_2_5P238_RC + + ntpd/ntpd.1@1.230 +2 -2 + NTP_4_2_5P238_RC + + ntpdc/ntpdc-opts.c@1.228 +2 -2 + NTP_4_2_5P238_RC + + ntpdc/ntpdc-opts.h@1.228 +3 -3 + NTP_4_2_5P238_RC + + ntpdc/ntpdc-opts.texi@1.227 +1 -1 + NTP_4_2_5P238_RC + + ntpdc/ntpdc.1@1.227 +2 -2 + NTP_4_2_5P238_RC + + ntpq/ntpq-opts.c@1.229 +2 -2 + NTP_4_2_5P238_RC + + ntpq/ntpq-opts.h@1.229 +3 -3 + NTP_4_2_5P238_RC + + ntpq/ntpq-opts.texi@1.228 +1 -1 + NTP_4_2_5P238_RC + + ntpq/ntpq.1@1.228 +2 -2 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.107 +2 -2 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.107 +3 -3 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.107 +1 -1 + NTP_4_2_5P238_RC + + ntpsnmpd/ntpsnmpd.1@1.107 +2 -2 + NTP_4_2_5P238_RC + + packageinfo.sh@1.242 +1 -1 + NTP_4_2_5P238_RC + + sntp/sntp-opts.c@1.101 +2 -2 + NTP_4_2_5P238_RC + + sntp/sntp-opts.h@1.101 +3 -3 + NTP_4_2_5P238_RC + + sntp/sntp-opts.texi@1.101 +1 -1 + NTP_4_2_5P238_RC + + sntp/sntp.1@1.101 +2 -2 + NTP_4_2_5P238_RC + + util/ntp-keygen-opts.c@1.231 +2 -2 + NTP_4_2_5P238_RC + + util/ntp-keygen-opts.h@1.231 +3 -3 + NTP_4_2_5P238_RC + + util/ntp-keygen-opts.texi@1.230 +1 -1 + NTP_4_2_5P238_RC + + util/ntp-keygen.1@1.230 +2 -2 + NTP_4_2_5P238_RC + +ChangeSet@1.2060.8.3, 2009-10-26 22:25:38-05:00, stenn@whimsy.udel.edu + Changes from Dave Mills + + ChangeLog@1.496.5.3 +1 -0 + Changes from Dave Mills + + ntpd/ntp_refclock.c@1.91 +1 -1 + Changes from Dave Mills + + ntpd/refclock_wwv.c@1.73 +0 -1 + Changes from Dave Mills + +ChangeSet@1.2060.8.2, 2009-10-26 22:20:49-05:00, stenn@whimsy.udel.edu + driver4.html updates from Dave Mills + + ChangeLog@1.496.5.2 +1 -0 + driver4.html updates from Dave Mills + + html/drivers/driver4.html@1.15 +2 -2 + driver4.html updates from Dave Mills + +ChangeSet@1.2060.8.1, 2009-10-26 22:16:02-05:00, stenn@whimsy.udel.edu + PPSAPI Cleanup of ntpd/refclock_wwvb.c + + ChangeLog@1.496.5.1 +1 -0 + PPSAPI Cleanup of ntpd/refclock_wwvb.c + + ntpd/refclock_wwvb.c@1.22 +73 -23 + PPSAPI Cleanup of ntpd/refclock_wwvb.c + +ChangeSet@1.2060.3.15, 2009-10-27 00:16:02+00:00, davehart@shiny.ad.hartbrothers.com + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + + ChangeLog@1.496.1.13 +2 -0 + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + + configure.ac@1.459.1.5 +175 -107 + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + + sntp/configure.ac@1.24 +141 -46 + Get rid of configure tests for __ss_family and __ss_len when the more + common ss_family and ss_len are present. + +ChangeSet@1.2060.3.14, 2009-10-26 20:49:30+00:00, davehart@shiny.ad.hartbrothers.com + CIDs 94-99 make it more clearly impossible for sock_hash() to return + a negative number. + CID 105, 106 ensure ntpdc arrays are not overrun even if callers + misbehave. + CID 113 use va_end() in refclock_true.c true_debug(). + + ChangeLog@1.496.1.12 +5 -0 + CIDs 94-99 make it more clearly impossible for sock_hash() to return + a negative number. + CID 105, 106 ensure ntpdc arrays are not overrun even if callers + misbehave. + CID 113 use va_end() in refclock_true.c true_debug(). + + include/ntpd.h@1.135 +1 -1 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + libntp/ntp_rfc2553.c@1.41 +2 -0 + protect sys/socket.h inclusion with #ifdef HAVE_SYS_SOCKET_H + + ntpd/ntp_monitor.c@1.25 +6 -6 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + ntpd/ntp_peer.c@1.123 +9 -9 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + ntpd/ntp_util.c@1.75 +15 -18 + CIDs 94-99 -- make it more clearly impossible for sock_hash to + return a negative number + + ntpd/refclock_true.c@1.11 +1 -0 + CID 113 use va_end() + + ntpdc/ntpdc_ops.c@1.61 +23 -14 + CID 105, 106 -- ensure array are not overrun even if callers + misbehave + +ChangeSet@1.2060.3.12, 2009-10-26 05:45:09-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P237_RC + TAG: NTP_4_2_5P237_RC + + ChangeLog@1.496.1.10 +1 -0 + NTP_4_2_5P237_RC + + ntpd/ntpd-opts.c@1.231 +2 -2 + NTP_4_2_5P237_RC + + ntpd/ntpd-opts.h@1.231 +3 -3 + NTP_4_2_5P237_RC + + ntpd/ntpd-opts.texi@1.229 +1 -1 + NTP_4_2_5P237_RC + + ntpd/ntpd.1@1.229 +2 -2 + NTP_4_2_5P237_RC + + ntpdc/ntpdc-opts.c@1.227 +2 -2 + NTP_4_2_5P237_RC + + ntpdc/ntpdc-opts.h@1.227 +3 -3 + NTP_4_2_5P237_RC + + ntpdc/ntpdc-opts.texi@1.226 +1 -1 + NTP_4_2_5P237_RC + + ntpdc/ntpdc.1@1.226 +2 -2 + NTP_4_2_5P237_RC + + ntpq/ntpq-opts.c@1.228 +2 -2 + NTP_4_2_5P237_RC + + ntpq/ntpq-opts.h@1.228 +3 -3 + NTP_4_2_5P237_RC + + ntpq/ntpq-opts.texi@1.227 +1 -1 + NTP_4_2_5P237_RC + + ntpq/ntpq.1@1.227 +2 -2 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.106 +2 -2 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.106 +3 -3 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.106 +1 -1 + NTP_4_2_5P237_RC + + ntpsnmpd/ntpsnmpd.1@1.106 +2 -2 + NTP_4_2_5P237_RC + + packageinfo.sh@1.241 +1 -1 + NTP_4_2_5P237_RC + + sntp/sntp-opts.c@1.100 +2 -2 + NTP_4_2_5P237_RC + + sntp/sntp-opts.h@1.100 +3 -3 + NTP_4_2_5P237_RC + + sntp/sntp-opts.texi@1.100 +1 -1 + NTP_4_2_5P237_RC + + sntp/sntp.1@1.100 +2 -2 + NTP_4_2_5P237_RC + + util/ntp-keygen-opts.c@1.230 +2 -2 + NTP_4_2_5P237_RC + + util/ntp-keygen-opts.h@1.230 +3 -3 + NTP_4_2_5P237_RC + + util/ntp-keygen-opts.texi@1.229 +1 -1 + NTP_4_2_5P237_RC + + util/ntp-keygen.1@1.229 +2 -2 + NTP_4_2_5P237_RC + +ChangeSet@1.2060.7.1, 2009-10-25 11:25:16+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + + BitKeeper/deleted/.del-in.h~29080509@1.4 +0 -0 + Rename: ports/winnt/include/netinet/in.h -> BitKeeper/deleted/.del-in.h~29080509 + + BitKeeper/deleted/.del-in_system.h~c86910dc@1.3 +0 -0 + Rename: ports/winnt/include/netinet/in_system.h -> BitKeeper/deleted/.del-in_system.h~c86910dc + + BitKeeper/deleted/.del-ip.h~eb192092@1.3 +0 -0 + Rename: ports/winnt/include/netinet/ip.h -> BitKeeper/deleted/.del-ip.h~eb192092 + + BitKeeper/deleted/.del-socket.h~29080509@1.4 +0 -0 + Rename: ports/winnt/include/sys/socket.h -> BitKeeper/deleted/.del-socket.h~29080509 + + ChangeLog@1.496.4.1 +1 -0 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + + include/Makefile.am@1.35.1.1 +1 -0 + move lib_strbuf.h from libntp to include + + include/l_stdlib.h@1.17 +1 -4 + require sys/types.h + + include/lib_strbuf.h@1.6 +0 -0 + Rename: libntp/lib_strbuf.h -> include/lib_strbuf.h + + include/ntp_io.h@1.13 +1 -3 + require sys/types.h + + include/ntp_net.h@1.3 +4 -0 + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + include/ntp_stdlib.h@1.35 +2 -0 + protect sys/socket.h inclusion with #ifdef HAVE_SYS_SOCKET_H + + include/ntp_types.h@1.14 +4 -5 + stay out of system/compiler underscore namespace + + include/ntpsim.h@1.12 +8 -7 + protect sys/socket.h inclusion with #ifdef HAVE_SYS_SOCKET_H + + libntp/Makefile.am@1.47 +0 -2 + move lib_strbuf.h from libntp to include + + libntp/decodenetnum.c@1.10 +5 -0 + include config.h + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + libntp/inttoa.c@1.3 +3 -2 + include config.h + use snprintf() in favor of sprintf() + + libntp/msyslog.c@1.24 +1 -3 + require sys/types.h + + libntp/ntp_random.c@1.7 +1 -3 + require sys/types.h + + libntp/numtoa.c@1.5 +2 -3 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + libntp/numtohost.c@1.5 +2 -4 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + libntp/socktoa.c@1.11 +4 -0 + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + libntp/socktohost.c@1.7 +4 -0 + protect sys/socket.h, netinet/in.h inclusion with config.h macros + + ntpd/keyword-gen.c@1.1.1.1 +1 -1 + [Bug 1355] ntp-dev won't compile on OpenBSD 4.6. + + ntpd/ntp_control.c@1.127 +2 -0 + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + ntpd/ntp_intres.c@1.66 +2 -0 + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + ntpd/ntp_request.c@1.80.1.2 +2 -0 + protect netinet/in.h inclusion with HAVE_NETINET_IN_H + + ntpdc/ntpdc_ops.c@1.60 +9 -4 + protect netinet/in.h inclusion with #ifdef HAVE_NETINET_IN_H. + stay within array bounds in clockstat() even if calling code + misbehaves. + + + ports/winnt/vc6/libntp.dsp@1.43.2.1 +1 -1 + move lib_strbuf.h from libntp to include + + ports/winnt/vs2003/libntp.vcproj@1.4.1.1 +1 -1 + move lib_strbuf.h from libntp to include + + ports/winnt/vs2005/libntp.vcproj@1.4.1.1 +1 -1 + move lib_strbuf.h from libntp to include + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20.1.2 +1 -1 + move lib_strbuf.h from libntp to include + + util/ntp-keygen.c@1.59 +1 -9 + require sys/types.h + remove old #ifdef SYS_WINNT related to ntp_getopt, ntp-keygen uses libopts + +ChangeSet@1.2060.6.1, 2009-10-25 03:06:29+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1354] libtool error building after bootstrap with Autoconf 2.64. + Allow NTP_VPATH_HACK configure test to handle newer gmake versions. + + BitKeeper/deleted/.del-ltmain.sh~1dcd783dfc596fc7@1.3 +0 -0 + Rename: sntp/ltmain.sh -> BitKeeper/deleted/.del-ltmain.sh~1dcd783dfc596fc7 + + BitKeeper/deleted/.del-ltmain.sh~2b9d9fc0af8c0735@1.2 +0 -0 + Rename: ltmain.sh -> BitKeeper/deleted/.del-ltmain.sh~2b9d9fc0af8c0735 + + ChangeLog@1.496.3.1 +2 -0 + [Bug 1354] libtool error building after bootstrap with Autoconf 2.64. + Allow NTP_VPATH_HACK configure test to handle newer gmake versions. + + Makefile.am@1.86.1.1 +11 -3 + add rule to rebuild libtool if needed. + no need to use unix2dos on *.ds* after bk admin -fEOLN_WINDOWS + + configure.ac@1.459.1.4 +3 -1 + use AC_CONFIG_MACRO_DIR() to keep m4 files in m4 + + m4/ntp_vpathhack.m4@1.2 +23 -17 + NTP_VPATH_HACK was misfiring on FreeBSD with recent GNU Make due to + a change from "GNU Make version" to "GNU Make" as the gmake -v output. + Also do not cache the result, running make -v and grep is worth it to + allow changing make without flushing the cache. + + ports/winnt/vc6/Instsrv.dsp@1.11 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/Instsrv.dsp@1.10 +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/libntp.dsp@1.43.1.2 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/libntp.dsp@1.43.1.1 +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntp.dsw@1.11 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntp.dsw@1.10 +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpd.dsp@1.39.1.2 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpd.dsp@1.39.1.1 +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpdate.dsp@1.24 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpdate.dsp@1.23 +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpdc.dsp@1.27 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpdc.dsp@1.26 +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpkeygen.dsp@1.20 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpkeygen.dsp@1.19 +0 -0 + Turn off EOLN_NATIVE flag + + ports/winnt/vc6/ntpq.dsp@1.28 +0 -0 + Turn on EOLN_WINDOWS flag + + ports/winnt/vc6/ntpq.dsp@1.27 +0 -0 + Turn off EOLN_NATIVE flag + + scripts/genCommitLog@1.5 +9 -0 + crude workaround for read-only srcdir seen in make distcheck + + sntp/Makefile.am@1.13.1.1 +13 -2 + add rule to rebuild libtool if needed + + sntp/configure.ac@1.23 +2 -0 + use AC_CONFIG_MACRO_DIR() to keep m4 files in m4 + +ChangeSet@1.2060.3.10, 2009-10-24 05:55:49+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 610] NMEA support for using PPSAPI on a different device. + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + ChangeLog@1.496.1.8 +2 -0 + [Bug 610] NMEA support for using PPSAPI on a different device. + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + include/ntp_refclock.h@1.24 +2 -1 + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + ntpd/ntp_refclock.c@1.90 +15 -5 + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + + ntpd/refclock_nmea.c@1.45 +45 -13 + [Bug 610] NMEA support for using PPSAPI on a different device. + [Bug 1238] use only fudge time2 to offset NMEA serial timestamp. + +ChangeSet@1.2060.5.1, 2009-10-23 16:57:07+00:00, davehart@shiny.ad.hartbrothers.com + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/keyword-gen.c@1.2 +133 -18 + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/ntp_keyword.h@1.2 +741 -741 + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/ntp_scanner.c@1.31 +20 -16 + shrink 750 keyword scanner states from 64 to 32 bits apiece + + ntpd/ntp_scanner.h@1.14 +37 -10 + shrink 750 keyword scanner states from 64 to 32 bits apiece + +ChangeSet@1.2060.3.9, 2009-10-22 06:47:25-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P236_RC + TAG: NTP_4_2_5P236_RC + + ChangeLog@1.496.1.7 +1 -0 + NTP_4_2_5P236_RC + + ntpd/ntpd-opts.c@1.230 +2 -2 + NTP_4_2_5P236_RC + + ntpd/ntpd-opts.h@1.230 +3 -3 + NTP_4_2_5P236_RC + + ntpd/ntpd-opts.texi@1.228 +1 -1 + NTP_4_2_5P236_RC + + ntpd/ntpd.1@1.228 +2 -2 + NTP_4_2_5P236_RC + + ntpdc/ntpdc-opts.c@1.226 +2 -2 + NTP_4_2_5P236_RC + + ntpdc/ntpdc-opts.h@1.226 +3 -3 + NTP_4_2_5P236_RC + + ntpdc/ntpdc-opts.texi@1.225 +1 -1 + NTP_4_2_5P236_RC + + ntpdc/ntpdc.1@1.225 +2 -2 + NTP_4_2_5P236_RC + + ntpq/ntpq-opts.c@1.227 +2 -2 + NTP_4_2_5P236_RC + + ntpq/ntpq-opts.h@1.227 +3 -3 + NTP_4_2_5P236_RC + + ntpq/ntpq-opts.texi@1.226 +1 -1 + NTP_4_2_5P236_RC + + ntpq/ntpq.1@1.226 +2 -2 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.105 +2 -2 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.105 +3 -3 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.105 +1 -1 + NTP_4_2_5P236_RC + + ntpsnmpd/ntpsnmpd.1@1.105 +2 -2 + NTP_4_2_5P236_RC + + packageinfo.sh@1.240 +1 -1 + NTP_4_2_5P236_RC + + sntp/sntp-opts.c@1.99 +2 -2 + NTP_4_2_5P236_RC + + sntp/sntp-opts.h@1.99 +3 -3 + NTP_4_2_5P236_RC + + sntp/sntp-opts.texi@1.99 +1 -1 + NTP_4_2_5P236_RC + + sntp/sntp.1@1.99 +2 -2 + NTP_4_2_5P236_RC + + util/ntp-keygen-opts.c@1.229 +2 -2 + NTP_4_2_5P236_RC + + util/ntp-keygen-opts.h@1.229 +3 -3 + NTP_4_2_5P236_RC + + util/ntp-keygen-opts.texi@1.228 +1 -1 + NTP_4_2_5P236_RC + + util/ntp-keygen.1@1.228 +2 -2 + NTP_4_2_5P236_RC + +ChangeSet@1.2060.3.8, 2009-10-22 05:02:37-04:00, stenn@whimsy.udel.edu + Cleanup from Dave Mills + + ChangeLog@1.496.1.6 +1 -0 + Cleanup from Dave Mills + + html/authopt.html@1.53 +42 -9 + Cleanup from Dave Mills + + html/ntpq.html@1.35 +10 -9 + Cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.151 +4 -5 + Cleanup from Dave Mills + +ChangeSet@1.2060.4.1, 2009-10-21 21:59:17+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ChangeLog@1.496.2.1 +1 -0 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + include/ntp_stdlib.h@1.34 +7 -1 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + libntp/machines.c@1.21 +49 -16 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ntpd/ntp_config.c@1.232 +25 -4 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ports/winnt/libntp/SetSystemTime.c@1.7 +1 -1 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + + ports/winnt/ntpd/nt_clockstuff.c@1.37 +6 -0 + [Bug 1353] ntpq "rv 0 settimeofday" always shows UNKNOWN on unix. + +ChangeSet@1.2060.3.6, 2009-10-21 15:38:30+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + AC_FUNC_MALLOC is unneeded, breaks cross-compile with uClibc with + undefined references to rpl_malloc + + sntp/configure.ac@1.22 +0 -1 + AC_FUNC_MALLOC is unneeded, breaks cross-compile with uClibc with + undefined references to rpl_malloc + +ChangeSet@1.2060.3.5, 2009-10-21 04:27:03+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + correct sa_len test butchered recently + + configure.ac@1.459.1.3 +20 -2 + correct sa_len test butchered recently + +ChangeSet@1.2060.3.4, 2009-10-20 17:47:04+00:00, davehart@shiny.ad.hartbrothers.com + Do not attempt to execute built binaries from ntpd/Makefile when + cross-compiling (keyword-gen and ntpd --saveconfigquit). + sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. + Correct in6addr_any test in configure.ac to attempt link too. + + ChangeLog@1.496.1.4 +5 -0 + Do not attempt to execute built binaries from ntpd/Makefile when + cross-compiling (keyword-gen and ntpd --saveconfigquit). + sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. + Correct in6addr_any test in configure.ac to attempt link too. + + configure.ac@1.459.1.2 +8 -6 + Correct in6addr_any test in configure.ac to attempt link too. + Introduce NTP_CROSSCOMPILE automake conditional + + ntpd/Makefile.am@1.76 +17 -3 + Use NTP_CROSSCOMPILE automake conditional to avoid attempting to execute + built binaries when cross-compiling (keyword-gen and ntpd --saveconfigquit) + + sntp/configure.ac@1.21 +6 -5 + Correct in6addr_any test in configure.ac to attempt link too. + + sntp/main.c@1.20 +9 -9 + sntp/main.c: Remove duplicate global adr_buf[] (also defined in + networking.c) which Piotr Grudzinski identified breaking his build. + +ChangeSet@1.2060.3.3, 2009-10-19 17:23:04+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1343] ntpd/ntp_io.c close_fd() does not compile on Solaris 7. + Also includes similar fix to sntp/crypto.c identified on same machine. + + ChangeLog@1.496.1.3 +1 -0 + [Bug 1343] ntpd/ntp_io.c close_fd() does not compile on Solaris 7. + Also includes similar fix to sntp/crypto.c identified on same machine. + + ntpd/ntp_io.c@1.306.1.1 +4 -2 + move code after local variable declaration in move_fd() to cure + compiling with compilers that know the difference between C and C++ + + sntp/crypto.c@1.9 +44 -43 + move digest_data variable declaration ahead of code in auth_md5() for + compatibility with ANSI C. + +ChangeSet@1.2060.3.2, 2009-10-18 06:46:43-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P235_RC + TAG: NTP_4_2_5P235_RC + + ChangeLog@1.496.1.2 +1 -0 + NTP_4_2_5P235_RC + + ntpd/ntpd-opts.c@1.229 +2 -2 + NTP_4_2_5P235_RC + + ntpd/ntpd-opts.h@1.229 +3 -3 + NTP_4_2_5P235_RC + + ntpd/ntpd-opts.texi@1.227 +1 -1 + NTP_4_2_5P235_RC + + ntpd/ntpd.1@1.227 +2 -2 + NTP_4_2_5P235_RC + + ntpdc/ntpdc-opts.c@1.225 +2 -2 + NTP_4_2_5P235_RC + + ntpdc/ntpdc-opts.h@1.225 +3 -3 + NTP_4_2_5P235_RC + + ntpdc/ntpdc-opts.texi@1.224 +1 -1 + NTP_4_2_5P235_RC + + ntpdc/ntpdc.1@1.224 +2 -2 + NTP_4_2_5P235_RC + + ntpq/ntpq-opts.c@1.226 +2 -2 + NTP_4_2_5P235_RC + + ntpq/ntpq-opts.h@1.226 +3 -3 + NTP_4_2_5P235_RC + + ntpq/ntpq-opts.texi@1.225 +1 -1 + NTP_4_2_5P235_RC + + ntpq/ntpq.1@1.225 +2 -2 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.104 +2 -2 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.104 +3 -3 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.104 +1 -1 + NTP_4_2_5P235_RC + + ntpsnmpd/ntpsnmpd.1@1.104 +2 -2 + NTP_4_2_5P235_RC + + packageinfo.sh@1.239 +1 -1 + NTP_4_2_5P235_RC + + sntp/sntp-opts.c@1.98 +2 -2 + NTP_4_2_5P235_RC + + sntp/sntp-opts.h@1.98 +3 -3 + NTP_4_2_5P235_RC + + sntp/sntp-opts.texi@1.98 +1 -1 + NTP_4_2_5P235_RC + + sntp/sntp.1@1.98 +2 -2 + NTP_4_2_5P235_RC + + util/ntp-keygen-opts.c@1.228 +2 -2 + NTP_4_2_5P235_RC + + util/ntp-keygen-opts.h@1.228 +3 -3 + NTP_4_2_5P235_RC + + util/ntp-keygen-opts.texi@1.227 +1 -1 + NTP_4_2_5P235_RC + + util/ntp-keygen.1@1.227 +2 -2 + NTP_4_2_5P235_RC + +ChangeSet@1.2060.3.1, 2009-10-18 01:54:01+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ChangeLog@1.496.1.1 +1 -0 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + configure.ac@1.459.1.1 +22 -23 + remove one of two sockaddr sa_len tests. + convert in_port_t tested to cached. + + include/ntp_rfc2553.h@1.32 +4 -87 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/unix/include/isc/net.h@1.11 +1 -1 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/unix/net.c@1.14 +4 -3 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/win32/include/isc/ipv6.h@1.9 +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/win32/include/isc/net.h@1.9 +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + lib/isc/win32/net.c@1.13 +5 -0 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + libntp/ntp_rfc2553.c@1.40 +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ntpd/ntp_request.c@1.80.1.1 +10 -10 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ntpdc/ntpdc_ops.c@1.59 +2 -2 + [Bug 1343] lib/isc build breaks on systems without IPv6 headers. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20.1.1 +3 -3 + correct isc/net.h path + + sntp/configure.ac@1.20 +56 -21 + libisc on systems without in_port_t wasn't compiling. + cache in_port_t test. + +ChangeSet@1.2060.1.5, 2009-10-16 21:00:05+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1348] ntpd Windows port should wait for sendto() completion. + + BitKeeper/deleted/.del-transmitbuff.c~29080509@1.10 +0 -0 + Delete: ports/winnt/libntp/transmitbuff.c + + BitKeeper/deleted/.del-transmitbuff.h~29080509@1.9 +0 -0 + Delete: ports/winnt/include/transmitbuff.h + + ChangeLog@1.497 +1 -0 + [Bug 1348] ntpd Windows port should wait for sendto() completion. + + ntpd/ntp_io.c@1.307 +4 -5 + [Bug 1348] ntpd Windows port should wait for sendto() completion. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.50 +65 -162 + [Bug 1348] ntpd Windows port should wait for sendto() completion. + + ports/winnt/vc6/libntp.dsp@1.44 +0 -8 + remove references to transmitbuff.[ch] + + ports/winnt/vc6/ntpd.dsp@1.40 +0 -4 + remove references to transmitbuff.[ch] + + ports/winnt/vs2003/libntp.vcproj@1.5 +0 -24 + remove references to transmitbuff.[ch] + + ports/winnt/vs2003/ntpd.vcproj@1.5 +0 -3 + remove references to transmitbuff.[ch] + + ports/winnt/vs2005/libntp.vcproj@1.5 +0 -26 + remove references to transmitbuff.[ch] + + ports/winnt/vs2005/ntpd.vcproj@1.5 +0 -4 + remove references to transmitbuff.[ch] + + ports/winnt/vs2008/libntp/libntp.vcproj@1.21 +1 -9 + remove references to transmitbuff.[ch] + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.22 +0 -4 + remove references to transmitbuff.[ch] + +ChangeSet@1.2060.1.4, 2009-10-16 06:48:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P234_RC + TAG: NTP_4_2_5P234_RC + + ChangeLog@1.496 +1 -0 + NTP_4_2_5P234_RC + + ntpd/ntpd-opts.c@1.228 +2 -2 + NTP_4_2_5P234_RC + + ntpd/ntpd-opts.h@1.228 +3 -3 + NTP_4_2_5P234_RC + + ntpd/ntpd-opts.texi@1.226 +1 -1 + NTP_4_2_5P234_RC + + ntpd/ntpd.1@1.226 +2 -2 + NTP_4_2_5P234_RC + + ntpdc/ntpdc-opts.c@1.224 +2 -2 + NTP_4_2_5P234_RC + + ntpdc/ntpdc-opts.h@1.224 +3 -3 + NTP_4_2_5P234_RC + + ntpdc/ntpdc-opts.texi@1.223 +1 -1 + NTP_4_2_5P234_RC + + ntpdc/ntpdc.1@1.223 +2 -2 + NTP_4_2_5P234_RC + + ntpq/ntpq-opts.c@1.225 +2 -2 + NTP_4_2_5P234_RC + + ntpq/ntpq-opts.h@1.225 +3 -3 + NTP_4_2_5P234_RC + + ntpq/ntpq-opts.texi@1.224 +1 -1 + NTP_4_2_5P234_RC + + ntpq/ntpq.1@1.224 +2 -2 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.103 +2 -2 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.103 +3 -3 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.103 +1 -1 + NTP_4_2_5P234_RC + + ntpsnmpd/ntpsnmpd.1@1.103 +2 -2 + NTP_4_2_5P234_RC + + packageinfo.sh@1.238 +1 -1 + NTP_4_2_5P234_RC + + sntp/sntp-opts.c@1.97 +2 -2 + NTP_4_2_5P234_RC + + sntp/sntp-opts.h@1.97 +3 -3 + NTP_4_2_5P234_RC + + sntp/sntp-opts.texi@1.97 +1 -1 + NTP_4_2_5P234_RC + + sntp/sntp.1@1.97 +2 -2 + NTP_4_2_5P234_RC + + util/ntp-keygen-opts.c@1.227 +2 -2 + NTP_4_2_5P234_RC + + util/ntp-keygen-opts.h@1.227 +3 -3 + NTP_4_2_5P234_RC + + util/ntp-keygen-opts.texi@1.226 +1 -1 + NTP_4_2_5P234_RC + + util/ntp-keygen.1@1.226 +2 -2 + NTP_4_2_5P234_RC + +ChangeSet@1.2060.2.1, 2009-10-16 07:32:59+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + ChangeLog@1.493.1.1 +2 -0 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + include/ntp_stdlib.h@1.33 +12 -3 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + lib/isc/win32/strerror.c@1.13 +10 -18 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + ports/winnt/include/config.h@1.79 +12 -8 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + + ports/winnt/include/syslog.h@1.6 +0 -3 + [Bug 1339] redux, use unmodified lib/isc/win32/strerror.c and + move #define strerror... to a header not used by lib/isc code. + +ChangeSet@1.2060.1.2, 2009-10-15 22:09:06+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1345] illegal 'grep' option prevents compilation. + [Bug 1346] keyword scanner broken where char defaults to unsigned. + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ChangeLog@1.494 +3 -0 + [Bug 1345] illegal 'grep' option prevents compilation. + [Bug 1346] keyword scanner broken where char defaults to unsigned. + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ntpd/Makefile.am@1.75 +2 -2 + [Bug 1345] illegal 'grep' option prevents compilation. + + ntpd/complete.conf@1.2 +1 -0 + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ntpd/ntp_config.c@1.231 +9 -15 + [Bug 1347] ntpd/complete.conf missing multicastclient test case. + + ntpd/ntp_scanner.c@1.30 +20 -18 + [Bug 1346] keyword scanner broken where char defaults to unsigned. + + ntpd/ntp_scanner.h@1.13 +0 -1 + [Bug 1346] keyword scanner broken where char defaults to unsigned. + +ChangeSet@1.2062, 2009-10-15 04:15:55-07:00, hstenn@lgmac-hstenn.local + sntp doc updates + + sntp/Makefile.am@1.15 +1 -0 + distribute sntp.texi + + sntp/sntp.texi@1.1 +84 -0 + BitKeeper file /Users/hstenn/src/ntp-dev-snmp/sntp/sntp.texi + + sntp/sntp.texi@1.0 +0 -0 + +ChangeSet@1.2060.1.1, 2009-10-15 06:43:07-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P233_RC + TAG: NTP_4_2_5P233_RC + + ChangeLog@1.493 +1 -0 + NTP_4_2_5P233_RC + + ntpd/ntpd-opts.c@1.227 +2 -2 + NTP_4_2_5P233_RC + + ntpd/ntpd-opts.h@1.227 +3 -3 + NTP_4_2_5P233_RC + + ntpd/ntpd-opts.texi@1.225 +1 -1 + NTP_4_2_5P233_RC + + ntpd/ntpd.1@1.225 +2 -2 + NTP_4_2_5P233_RC + + ntpdc/ntpdc-opts.c@1.223 +2 -2 + NTP_4_2_5P233_RC + + ntpdc/ntpdc-opts.h@1.223 +3 -3 + NTP_4_2_5P233_RC + + ntpdc/ntpdc-opts.texi@1.222 +1 -1 + NTP_4_2_5P233_RC + + ntpdc/ntpdc.1@1.222 +2 -2 + NTP_4_2_5P233_RC + + ntpq/ntpq-opts.c@1.224 +2 -2 + NTP_4_2_5P233_RC + + ntpq/ntpq-opts.h@1.224 +3 -3 + NTP_4_2_5P233_RC + + ntpq/ntpq-opts.texi@1.223 +1 -1 + NTP_4_2_5P233_RC + + ntpq/ntpq.1@1.223 +2 -2 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.102 +2 -2 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.102 +3 -3 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.102 +1 -1 + NTP_4_2_5P233_RC + + ntpsnmpd/ntpsnmpd.1@1.102 +2 -2 + NTP_4_2_5P233_RC + + packageinfo.sh@1.237 +1 -1 + NTP_4_2_5P233_RC + + sntp/sntp-opts.c@1.96 +2 -2 + NTP_4_2_5P233_RC + + sntp/sntp-opts.h@1.96 +3 -3 + NTP_4_2_5P233_RC + + sntp/sntp-opts.texi@1.96 +1 -1 + NTP_4_2_5P233_RC + + sntp/sntp.1@1.96 +2 -2 + NTP_4_2_5P233_RC + + util/ntp-keygen-opts.c@1.226 +2 -2 + NTP_4_2_5P233_RC + + util/ntp-keygen-opts.h@1.226 +3 -3 + NTP_4_2_5P233_RC + + util/ntp-keygen-opts.texi@1.225 +1 -1 + NTP_4_2_5P233_RC + + util/ntp-keygen.1@1.225 +2 -2 + NTP_4_2_5P233_RC + +ChangeSet@1.2061, 2009-10-15 03:43:07-07:00, hstenn@lgmac-hstenn.local + Prep for sntp docs + + Makefile.am@1.87 +5 -1 + Create include/version.texi + + configure.ac@1.460 +7 -2 + K_open() is not used anymore. kvm_open() needs kvm.h + + include/Makefile.am@1.36 +1 -1 + include version.texi + + scripts/genver@1.5 +22 -1 + Handle version.texi + + sntp/Makefile.am@1.14 +17 -2 + Prep for building sntp.html + + sntp/sntp-opts.def@1.12 +15 -41 + updates + +ChangeSet@1.2057.1.1, 2009-10-15 00:53:23-04:00, stenn@whimsy.udel.edu + Documentation cleanup and updates + + ChangeLog@1.489.1.1 +1 -0 + Documentation cleanup and updates + + html/miscopt.html@1.52 +1 -1 + Documentation cleanup and updates + + html/ntpd.html@1.51 +72 -54 + Documentation cleanup and updates + + html/ntpq.html@1.34 +99 -73 + Documentation cleanup and updates + +ChangeSet@1.2058, 2009-10-15 03:30:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. + + ChangeLog@1.490 +2 -0 + [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. + + lib/isc/win32/interfaceiter.c@1.15 +10 -25 + Cleanup incomplete merge of NTP local changes from recent libisc update + + ntpd/ntp_config.c@1.230 +1 -1 + Use NULL for peer_config() interface arg instead of wildcard + to ensure the correct interface is used from the start. + + ntpd/ntp_io.c@1.304.1.1 +17 -14 + [Bug 1342] ignore|drop one IPv6 address on an interface blocks all + addresses on that interface. + + ntpd/ntp_peer.c@1.122 +1 -1 + Do not peer_clear("XFAC") manycast server associations or they will + never regain their ACST refid. + + ports/winnt/ntpd/ntservice.c@1.21 +20 -8 + Make windows-only command-line hack a little less broken + +ChangeSet@1.2057, 2009-10-14 04:22:12-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P232_RC + TAG: NTP_4_2_5P232_RC + + ChangeLog@1.489 +1 -0 + NTP_4_2_5P232_RC + + ntpd/ntpd-opts.c@1.226 +4 -4 + NTP_4_2_5P232_RC + + ntpd/ntpd-opts.h@1.226 +3 -3 + NTP_4_2_5P232_RC + + ntpd/ntpd-opts.texi@1.224 +15 -6 + NTP_4_2_5P232_RC + + ntpd/ntpd.1@1.224 +16 -7 + NTP_4_2_5P232_RC + + ntpdc/ntpdc-opts.c@1.222 +2 -2 + NTP_4_2_5P232_RC + + ntpdc/ntpdc-opts.h@1.222 +3 -3 + NTP_4_2_5P232_RC + + ntpdc/ntpdc-opts.texi@1.221 +1 -1 + NTP_4_2_5P232_RC + + ntpdc/ntpdc.1@1.221 +2 -2 + NTP_4_2_5P232_RC + + ntpq/ntpq-opts.c@1.223 +2 -2 + NTP_4_2_5P232_RC + + ntpq/ntpq-opts.h@1.223 +3 -3 + NTP_4_2_5P232_RC + + ntpq/ntpq-opts.texi@1.222 +1 -1 + NTP_4_2_5P232_RC + + ntpq/ntpq.1@1.222 +2 -2 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.101 +2 -2 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.101 +3 -3 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.101 +1 -1 + NTP_4_2_5P232_RC + + ntpsnmpd/ntpsnmpd.1@1.101 +2 -2 + NTP_4_2_5P232_RC + + packageinfo.sh@1.236 +1 -1 + NTP_4_2_5P232_RC + + sntp/sntp-opts.c@1.95 +2 -2 + NTP_4_2_5P232_RC + + sntp/sntp-opts.h@1.95 +3 -3 + NTP_4_2_5P232_RC + + sntp/sntp-opts.texi@1.95 +1 -1 + NTP_4_2_5P232_RC + + sntp/sntp.1@1.95 +2 -2 + NTP_4_2_5P232_RC + + util/ntp-keygen-opts.c@1.225 +2 -2 + NTP_4_2_5P232_RC + + util/ntp-keygen-opts.h@1.225 +3 -3 + NTP_4_2_5P232_RC + + util/ntp-keygen-opts.texi@1.224 +1 -1 + NTP_4_2_5P232_RC + + util/ntp-keygen.1@1.224 +2 -2 + NTP_4_2_5P232_RC + +ChangeSet@1.2050.6.1, 2009-10-13 23:48:18+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. + + ChangeLog@1.482.5.1 +1 -0 + [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. + + libntp/refnumtoa.c@1.7 +2 -5 + do not require refnumtoa() callers to have called ISREFCLOCKADR() first + + ntpd/ntp_control.c@1.126 +1 -2 + remove unneeded #ifdef REFCLOCK, ISREFCLOCKADR() is now always present + and refnumtoa() has long been always present, even without REFCLOCK. + + ntpd/refclock_nmea.c@1.44 +73 -22 + [Bug 1341] NMEA driver requires working PPSAPI #ifdef HAVE_PPSAPI. + +ChangeSet@1.2050.5.1, 2009-10-13 02:24:57+00:00, davehart@shiny.ad.hartbrothers.com + Documentation updates for ntpq --oldrv, saveconfig, saveconfigdir, + ntpd -I -L and -M switches and interface/nic directive + + ChangeLog@1.482.4.1 +2 -0 + Update documentation for ntpq --old-rv, saveconfig, saveconfigdir, + ntpd -I -L and -M, and interface/nic rules. (From Dave Hart) + + html/miscopt.html@1.51 +4 -2 + Add saveconfigdir docs. + Add wildcard match class to interface/nic docs. + + html/ntpd.html@1.50 +7 -3 + Update -L docs, add -I + + html/ntpq.html@1.33 +5 -3 + Add ntpq --old-rv docs. + Update saveconfig docs to mention saveconfigdir. + + html/scripts/miscopt.txt@1.3 +1 -0 + Add saveconfigdir + + ntpd/ntpdbase-opts.def@1.19 +14 -4 + Update -L and -I docs to match HTML updates. + Expand -M docs. + +ChangeSet@1.2050.4.1, 2009-10-12 15:24:02+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ChangeLog@1.482.3.1 +1 -0 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + lib/isc/win32/strerror.c@1.12 +7 -4 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ports/winnt/include/config.h@1.78 +0 -3 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ports/winnt/include/syslog.h@1.5 +3 -0 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + + ports/winnt/libntp/syslog.c@1.7 +4 -10 + [Bug 1339] Fix Windows-only ntp_strerror() infinite recursion. + +ChangeSet@1.2050.3.1, 2009-10-12 04:48:04+00:00, davehart@shiny.ad.hartbrothers.com + better t column in peers/opeers using hmode peer variable + + ntpq/ntpq-subs.c@1.40 +86 -53 + better t column in peers/opeers using hmode peer variable + +ChangeSet@1.2050.1.2, 2009-10-12 03:40:08+00:00, kardel@pogo.udel.edu + ntp_io.c, ChangeLog: + cast address pointer to void * for bug 1337 + + ChangeLog@1.482.1.2 +1 -0 + cast address pointer to void * for bug 1337 + + ntpd/ntp_io.c@1.305 +1 -1 + cast address pointer to void * for bug 1337 + +ChangeSet@1.2050.2.2, 2009-10-11 22:09:53+00:00, davehart@shiny.ad.hartbrothers.com + Fix build break --with-arlib and config.cache + + arlib/configure.in@1.2 +6 -7 + Fix build break --with-arlib and config.cache + +ChangeSet@1.2050.2.1, 2009-10-11 19:27:05+00:00, davehart@shiny.ad.hartbrothers.com + Construct ntpd keyword scanner finite state machine at compile time + rather than at runtime, shrink entries from 40+ to 8 bytes. + + ChangeLog@1.482.2.1 +2 -0 + Construct ntpd keyword scanner finite state machine at compile time + rather than at runtime, shrink entries from 40+ to 8 bytes. + + bootstrap@1.27 +4 -0 + touch new generated file ntp_keyword.h after ntp_parser.[ch] + + include/ntp_filegen.h@1.7 +11 -11 + const is a virus + + ntpd/Makefile.am@1.74 +17 -4 + add keyword-gen program which produces ntp_keyword.h + + ntpd/keyword-gen.c@1.1 +546 -0 + new build-time tool to generate ntp_keyword.h with keyword scanner + finite state machine and token text array. + remove duplicate token table entries for "disable", "enable", + "monitor", and "version". + + ntpd/keyword-gen.c@1.0 +0 -0 + + ntpd/ntp_config.c@1.229 +2 -10 + remove references to create/delete_keyword_scanner() + + ntpd/ntp_filegen.c@1.17 +12 -14 + const is a virus + + ntpd/ntp_keyword.h@1.1 +920 -0 + generated by keyword-gen.c, contains keyword_text array and + keyword scanner finite state machine. + + ntpd/ntp_keyword.h@1.0 +0 -0 + + ntpd/ntp_scanner.c@1.29 +26 -343 + remove pieces to keyword-gen.c, new generated ntp_keyword.h + + ntpd/ntp_scanner.h@1.12 +19 -16 + move struct key_tok to keyword-gen.c, add scan_state struct replacing + previous struct state. + add multiple-inclusion protection + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.21 +4 -0 + add reference to ntp_keyword.h + +ChangeSet@1.2050.1.1, 2009-10-11 11:50:51+00:00, kardel@pogo.udel.edu + ntp_io.c, ChangeLog: + [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) + + ChangeLog@1.482.1.1 +1 -0 + [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) + + ntpd/ntp_io.c@1.304 +1 -1 + [Bug 1337] fix incorrect args to setsockopt(fd, IP_MULTICAST_IF,...) + +ChangeSet@1.2051, 2009-10-11 02:36:55+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1302] OpenSSL under Windows needs applink support. + + ChangeLog@1.483 +1 -0 + [Bug 1302] OpenSSL under Windows needs applink support. + + ports/winnt/ntpd/ntservice.c@1.20 +54 -12 + [Bug 1302] OpenSSL under Windows needs applink support. + + util/ntp-keygen.c@1.58 +7 -1 + [Bug 1302] OpenSSL under Windows needs applink support. + +ChangeSet@1.2050, 2009-10-10 06:41:51-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P231_RC + TAG: NTP_4_2_5P231_RC + + ChangeLog@1.482 +1 -0 + NTP_4_2_5P231_RC + + ntpd/ntpd-opts.c@1.225 +2 -2 + NTP_4_2_5P231_RC + + ntpd/ntpd-opts.h@1.225 +3 -3 + NTP_4_2_5P231_RC + + ntpd/ntpd-opts.texi@1.223 +1 -1 + NTP_4_2_5P231_RC + + ntpd/ntpd.1@1.223 +2 -2 + NTP_4_2_5P231_RC + + ntpdc/ntpdc-opts.c@1.221 +2 -2 + NTP_4_2_5P231_RC + + ntpdc/ntpdc-opts.h@1.221 +3 -3 + NTP_4_2_5P231_RC + + ntpdc/ntpdc-opts.texi@1.220 +1 -1 + NTP_4_2_5P231_RC + + ntpdc/ntpdc.1@1.220 +2 -2 + NTP_4_2_5P231_RC + + ntpq/ntpq-opts.c@1.222 +2 -2 + NTP_4_2_5P231_RC + + ntpq/ntpq-opts.h@1.222 +3 -3 + NTP_4_2_5P231_RC + + ntpq/ntpq-opts.texi@1.221 +1 -1 + NTP_4_2_5P231_RC + + ntpq/ntpq.1@1.221 +2 -2 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.100 +2 -2 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.100 +3 -3 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.100 +1 -1 + NTP_4_2_5P231_RC + + ntpsnmpd/ntpsnmpd.1@1.100 +2 -2 + NTP_4_2_5P231_RC + + packageinfo.sh@1.235 +1 -1 + NTP_4_2_5P231_RC + + sntp/sntp-opts.c@1.94 +2 -2 + NTP_4_2_5P231_RC + + sntp/sntp-opts.h@1.94 +3 -3 + NTP_4_2_5P231_RC + + sntp/sntp-opts.texi@1.94 +1 -1 + NTP_4_2_5P231_RC + + sntp/sntp.1@1.94 +2 -2 + NTP_4_2_5P231_RC + + util/ntp-keygen-opts.c@1.224 +2 -2 + NTP_4_2_5P231_RC + + util/ntp-keygen-opts.h@1.224 +3 -3 + NTP_4_2_5P231_RC + + util/ntp-keygen-opts.texi@1.223 +1 -1 + NTP_4_2_5P231_RC + + util/ntp-keygen.1@1.223 +2 -2 + NTP_4_2_5P231_RC + +ChangeSet@1.2049, 2009-10-09 17:15:23+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1335] Broadcast client degraded by wildcard default change. + + ChangeLog@1.481 +1 -0 + [Bug 1335] Broadcast client degraded by wildcard default change. + + ntpd/ntp_io.c@1.303 +16 -3 + default wildcard addresses to drop, exclude from "all" match class + +ChangeSet@1.2048, 2009-10-09 02:25:40-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P230_RC + TAG: NTP_4_2_5P230_RC + + ChangeLog@1.480 +1 -0 + NTP_4_2_5P230_RC + + ntpd/ntpd-opts.c@1.224 +2 -2 + NTP_4_2_5P230_RC + + ntpd/ntpd-opts.h@1.224 +3 -3 + NTP_4_2_5P230_RC + + ntpd/ntpd-opts.texi@1.222 +1 -1 + NTP_4_2_5P230_RC + + ntpd/ntpd.1@1.222 +2 -2 + NTP_4_2_5P230_RC + + ntpdc/ntpdc-opts.c@1.220 +2 -2 + NTP_4_2_5P230_RC + + ntpdc/ntpdc-opts.h@1.220 +3 -3 + NTP_4_2_5P230_RC + + ntpdc/ntpdc-opts.texi@1.219 +1 -1 + NTP_4_2_5P230_RC + + ntpdc/ntpdc.1@1.219 +2 -2 + NTP_4_2_5P230_RC + + ntpq/ntpq-opts.c@1.221 +2 -2 + NTP_4_2_5P230_RC + + ntpq/ntpq-opts.h@1.221 +3 -3 + NTP_4_2_5P230_RC + + ntpq/ntpq-opts.texi@1.220 +1 -1 + NTP_4_2_5P230_RC + + ntpq/ntpq.1@1.220 +2 -2 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd-opts.c@1.99 +2 -2 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd-opts.h@1.99 +3 -3 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd-opts.texi@1.99 +1 -1 + NTP_4_2_5P230_RC + + ntpsnmpd/ntpsnmpd.1@1.99 +2 -2 + NTP_4_2_5P230_RC + + packageinfo.sh@1.234 +1 -1 + NTP_4_2_5P230_RC + + sntp/sntp-opts.c@1.93 +2 -2 + NTP_4_2_5P230_RC + + sntp/sntp-opts.h@1.93 +3 -3 + NTP_4_2_5P230_RC + + sntp/sntp-opts.texi@1.93 +1 -1 + NTP_4_2_5P230_RC + + sntp/sntp.1@1.93 +2 -2 + NTP_4_2_5P230_RC + + util/ntp-keygen-opts.c@1.223 +2 -2 + NTP_4_2_5P230_RC + + util/ntp-keygen-opts.h@1.223 +3 -3 + NTP_4_2_5P230_RC + + util/ntp-keygen-opts.texi@1.222 +1 -1 + NTP_4_2_5P230_RC + + util/ntp-keygen.1@1.222 +2 -2 + NTP_4_2_5P230_RC + +ChangeSet@1.2047, 2009-10-08 23:54:02-04:00, stenn@whimsy.udel.edu + Start the 4.2.6 Release Candidate cycle + + ChangeLog@1.479 +1 -0 + Start the 4.2.6 Release Candidate cycle + + packageinfo.sh@1.233 +2 -2 + Start the 4.2.6 Release Candidate cycle + +ChangeSet@1.2046, 2009-10-08 19:48:15-04:00, stenn@whimsy.udel.edu + Broadcast and transit phase cleanup from Dave Mills + + ChangeLog@1.478 +1 -0 + Broadcast and transit phase cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.141 +2 -2 + Broadcast and transit phase cleanup from Dave Mills + + ntpd/ntp_proto.c@1.296 +7 -1 + Broadcast and transit phase cleanup from Dave Mills + +ChangeSet@1.2045, 2009-10-07 06:41:31-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P229 + TAG: NTP_4_2_5P229 + + ChangeLog@1.477 +1 -0 + NTP_4_2_5P229 + + ntpd/ntpd-opts.c@1.223 +2 -2 + NTP_4_2_5P229 + + ntpd/ntpd-opts.h@1.223 +3 -3 + NTP_4_2_5P229 + + ntpd/ntpd-opts.texi@1.221 +4 -2 + NTP_4_2_5P229 + + ntpd/ntpd.1@1.221 +2 -2 + NTP_4_2_5P229 + + ntpdc/ntpdc-opts.c@1.219 +2 -2 + NTP_4_2_5P229 + + ntpdc/ntpdc-opts.h@1.219 +3 -3 + NTP_4_2_5P229 + + ntpdc/ntpdc-opts.texi@1.218 +2 -2 + NTP_4_2_5P229 + + ntpdc/ntpdc.1@1.218 +2 -2 + NTP_4_2_5P229 + + ntpq/ntpq-opts.c@1.220 +2 -2 + NTP_4_2_5P229 + + ntpq/ntpq-opts.h@1.220 +3 -3 + NTP_4_2_5P229 + + ntpq/ntpq-opts.texi@1.219 +7 -3 + NTP_4_2_5P229 + + ntpq/ntpq.1@1.219 +2 -2 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd-opts.c@1.98 +2 -2 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd-opts.h@1.98 +3 -3 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd-opts.texi@1.98 +1 -1 + NTP_4_2_5P229 + + ntpsnmpd/ntpsnmpd.1@1.98 +2 -2 + NTP_4_2_5P229 + + packageinfo.sh@1.232 +1 -1 + NTP_4_2_5P229 + + sntp/sntp-opts.c@1.92 +2 -2 + NTP_4_2_5P229 + + sntp/sntp-opts.h@1.92 +3 -3 + NTP_4_2_5P229 + + sntp/sntp-opts.texi@1.92 +2 -2 + NTP_4_2_5P229 + + sntp/sntp.1@1.92 +2 -2 + NTP_4_2_5P229 + + util/ntp-keygen-opts.c@1.222 +2 -2 + NTP_4_2_5P229 + + util/ntp-keygen-opts.h@1.222 +3 -3 + NTP_4_2_5P229 + + util/ntp-keygen-opts.texi@1.221 +2 -2 + NTP_4_2_5P229 + + util/ntp-keygen.1@1.221 +2 -2 + NTP_4_2_5P229 + +ChangeSet@1.1436.15.71, 2009-10-07 01:33:22+00:00, davehart@shiny.ad.hartbrothers.com + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + + ChangeLog@1.1.1.91 +4 -0 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + + ntpd/ntp_request.c@1.65.1.3 +9 -2 + [Sec 1331] DoS with mode 7 packets - CVE-2009-3563. + +ChangeSet@1.2044, 2009-10-06 15:37:07+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + Change ntpsnmpd/Makefile.am include file order to fix FreeBSD build. + + ChangeLog@1.476 +2 -0 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + Change ntpsnmpd/Makefile.am include file order to fix FreeBSD build. + + ntpq/ntpq-subs.c@1.39 +1 -1 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + + ntpq/ntpq.c@1.94 +11 -0 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + + ntpq/ntpq.h@1.10 +1 -0 + [Bug 1334] ntpsnmpd undefined reference to `ntpqOptions'. + + ntpsnmpd/Makefile.am@1.11 +1 -1 + list $(LIBOPTS_CFLAGS) ahead of @SNMP_CPPFLAGS@ to pick up our copy + of autoopts/options.h ahead of any on the generous include search + path in @SNMP_CPPFLAGS@ + +ChangeSet@1.2043, 2009-10-06 04:55:16-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P228 + TAG: NTP_4_2_5P228 + + ChangeLog@1.475 +1 -0 + NTP_4_2_5P228 + + ntpd/ntpd-opts.c@1.222 +2 -2 + NTP_4_2_5P228 + + ntpd/ntpd-opts.h@1.222 +3 -3 + NTP_4_2_5P228 + + ntpd/ntpd-opts.texi@1.220 +1 -1 + NTP_4_2_5P228 + + ntpd/ntpd.1@1.220 +2 -2 + NTP_4_2_5P228 + + ntpdc/ntpdc-opts.c@1.218 +2 -2 + NTP_4_2_5P228 + + ntpdc/ntpdc-opts.h@1.218 +3 -3 + NTP_4_2_5P228 + + ntpdc/ntpdc-opts.texi@1.217 +1 -1 + NTP_4_2_5P228 + + ntpdc/ntpdc.1@1.217 +2 -2 + NTP_4_2_5P228 + + ntpq/ntpq-opts.c@1.219 +2 -2 + NTP_4_2_5P228 + + ntpq/ntpq-opts.h@1.219 +3 -3 + NTP_4_2_5P228 + + ntpq/ntpq-opts.texi@1.218 +1 -1 + NTP_4_2_5P228 + + ntpq/ntpq.1@1.218 +2 -2 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd-opts.c@1.97 +2 -2 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd-opts.h@1.97 +3 -3 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd-opts.texi@1.97 +1 -1 + NTP_4_2_5P228 + + ntpsnmpd/ntpsnmpd.1@1.97 +2 -2 + NTP_4_2_5P228 + + packageinfo.sh@1.231 +1 -1 + NTP_4_2_5P228 + + sntp/sntp-opts.c@1.91 +2 -2 + NTP_4_2_5P228 + + sntp/sntp-opts.h@1.91 +3 -3 + NTP_4_2_5P228 + + sntp/sntp-opts.texi@1.91 +1 -1 + NTP_4_2_5P228 + + sntp/sntp.1@1.91 +2 -2 + NTP_4_2_5P228 + + util/ntp-keygen-opts.c@1.221 +2 -2 + NTP_4_2_5P228 + + util/ntp-keygen-opts.h@1.221 +3 -3 + NTP_4_2_5P228 + + util/ntp-keygen-opts.texi@1.220 +1 -1 + NTP_4_2_5P228 + + util/ntp-keygen.1@1.220 +2 -2 + NTP_4_2_5P228 + +ChangeSet@1.2042, 2009-10-06 06:48:31+00:00, davehart@shiny.ad.hartbrothers.com + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + + ChangeLog@1.474 +2 -0 + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + + include/ntp_config.h@1.65 +10 -0 + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + + ntpd/ntp_config.c@1.228 +57 -43 + Reclaim syntax tree memory after application in ntpd built with + configure --disable-saveconfig. + +ChangeSet@1.2039.1.1, 2009-10-06 03:49:05+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. + add new file ntpd/complete.conf to ntpd/Makefile.am EXTRA_DIST + + ChangeLog@1.471.1.1 +2 -1 + [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. + wrap [Bug 1327] line at 72 chars + + Makefile.am@1.86 +1 -1 + run distcheck configure with -C so arlib, sntp configure runs benefit + from top-level configure.cache + + ntpd/Makefile.am@1.73 +6 -2 + add new file ntpd/complete.conf to ntpd/Makefile.am EXTRA_DIST + + ntpq/ntpq.c@1.93 +16 -17 + [Bug 1135] ntpq uses sizeof(u_long) where sizeof(u_int32) is meant. + +ChangeSet@1.2040, 2009-10-05 16:34:09+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1333] ntpd --interface precedence over --novirtualips lost. + + ChangeLog@1.472 +1 -0 + [Bug 1333] ntpd --interface precedence over --novirtualips lost. + + ntpd/ntp_io.c@1.302 +39 -26 + [Bug 1333] ntpd --interface precedence over --novirtualips lost. + +ChangeSet@1.2039, 2009-10-05 07:45:16-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P227 + TAG: NTP_4_2_5P227 + + ChangeLog@1.471 +1 -0 + NTP_4_2_5P227 + + ntpd/ntpd-opts.c@1.221 +2 -2 + NTP_4_2_5P227 + + ntpd/ntpd-opts.h@1.221 +3 -3 + NTP_4_2_5P227 + + ntpd/ntpd-opts.texi@1.219 +1 -1 + NTP_4_2_5P227 + + ntpd/ntpd.1@1.219 +2 -2 + NTP_4_2_5P227 + + ntpdc/ntpdc-opts.c@1.217 +2 -2 + NTP_4_2_5P227 + + ntpdc/ntpdc-opts.h@1.217 +3 -3 + NTP_4_2_5P227 + + ntpdc/ntpdc-opts.texi@1.216 +1 -1 + NTP_4_2_5P227 + + ntpdc/ntpdc.1@1.216 +2 -2 + NTP_4_2_5P227 + + ntpq/ntpq-opts.c@1.218 +3 -3 + NTP_4_2_5P227 + + ntpq/ntpq-opts.h@1.218 +4 -4 + NTP_4_2_5P227 + + ntpq/ntpq-opts.texi@1.217 +3 -3 + NTP_4_2_5P227 + + ntpq/ntpq.1@1.217 +2 -2 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd-opts.c@1.96 +2 -2 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd-opts.h@1.96 +3 -3 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd-opts.texi@1.96 +1 -1 + NTP_4_2_5P227 + + ntpsnmpd/ntpsnmpd.1@1.96 +2 -2 + NTP_4_2_5P227 + + packageinfo.sh@1.230 +1 -1 + NTP_4_2_5P227 + + sntp/sntp-opts.c@1.90 +2 -2 + NTP_4_2_5P227 + + sntp/sntp-opts.h@1.90 +3 -3 + NTP_4_2_5P227 + + sntp/sntp-opts.texi@1.90 +1 -1 + NTP_4_2_5P227 + + sntp/sntp.1@1.90 +2 -2 + NTP_4_2_5P227 + + util/ntp-keygen-opts.c@1.220 +2 -2 + NTP_4_2_5P227 + + util/ntp-keygen-opts.h@1.220 +3 -3 + NTP_4_2_5P227 + + util/ntp-keygen-opts.texi@1.219 +1 -1 + NTP_4_2_5P227 + + util/ntp-keygen.1@1.219 +2 -2 + NTP_4_2_5P227 + +ChangeSet@1.2038, 2009-10-05 07:29:55+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1135] :config fails with "Server disallowed request" + + ChangeLog@1.470 +1 -0 + [Bug 1135] :config fails with "Server disallowed request" + + ntpd/ntp_control.c@1.125 +1 -1 + [Bug 1135] :config fails with "Server disallowed request" + +ChangeSet@1.2037, 2009-10-05 06:35:21+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + add ntpq --old-rv + fix ipv4/ipv6 which are not equivalent in the libopts sense + + ChangeLog@1.469 +1 -0 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + + ntpq/ntpq-opts.c@1.217 +39 -10 + autogen output + + ntpq/ntpq-opts.def@1.14 +16 -2 + add ntpq --old-rv + fix ipv4/ipv6 which are not equivalent in the libopts sense + + ntpq/ntpq-opts.h@1.217 +15 -10 + autogen output + + ntpq/ntpq-opts.texi@1.216 +21 -5 + autogen output + + ntpq/ntpq-subs.c@1.38 +38 -21 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + add ntpq --old-rv + + ntpq/ntpq.1@1.216 +17 -4 + autogen output + + ntpq/ntpq.c@1.92 +22 -25 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + + ntpq/ntpq.h@1.9 +1 -1 + [Bug 1332] ntpq -c 'rv 0 variablename' returns extra stuff. + +ChangeSet@1.2032.1.1, 2009-10-04 18:35:23-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Hart/Dave Mills + + ChangeLog@1.465.1.1 +1 -0 + Documentation updates from Dave Hart/Dave Mills + + html/clockopt.html@1.22 +7 -5 + Documentation updates from Dave Hart/Dave Mills + + html/miscopt.html@1.50 +32 -35 + Documentation updates from Dave Hart/Dave Mills + +ChangeSet@1.2035, 2009-10-04 22:17:11+00:00, davehart@shiny.ad.hartbrothers.com + actually ignore nic/interface via :config with -I or -L, saying so + isn't enough. + + ntpd/ntp_config.c@1.227 +2 -0 + actually ignore nic/interface via :config with -I or -L, saying so + isn't enough. + +ChangeSet@1.2034, 2009-10-04 20:28:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. + + ChangeLog@1.467 +4 -2 + [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. + add missing "* " prefix to 1318, 1327 entries + + ntpd/ntp_config.c@1.226 +12 -1 + [Bug 1330] disallow interface/nic rules when --novirtualips or + --interface are used. + +ChangeSet@1.2033, 2009-10-04 18:14:14+00:00, davehart@shiny.ad.hartbrothers.com + Add test of ntpd --saveconfigquit fidelity using new complete.conf. + + ChangeLog@1.466 +1 -0 + Add test of ntpd --saveconfigquit fidelity using new complete.conf. + + configure.ac@1.459 +3 -0 + make "if SAVECONFIG_ENABLED" work in ntpd/Makefile.am + + ntpd/Makefile.am@1.72 +14 -1 + add check_saveconfig target and list in check-local: to validate + --saveconfigquit produces the same configuration it is given. + + ntpd/complete.conf@1.1 +54 -0 + This file represents an attempt to hit every keyword and syntax nook + + ntpd/complete.conf@1.0 +0 -0 + + ntpd/ntp_config.c@1.225 +39 -19 + move --saveconfigquit handling to before application of initial + syntax tree + + ntpdc/Makefile.am@1.43 +1 -1 + correct reference to $(srcdir)/layout.std + +ChangeSet@1.2032, 2009-10-04 07:49:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P226 + TAG: NTP_4_2_5P226 + + ChangeLog@1.465 +1 -0 + NTP_4_2_5P226 + + ntpd/ntpd-opts.c@1.220 +3 -3 + NTP_4_2_5P226 + + ntpd/ntpd-opts.h@1.220 +4 -4 + NTP_4_2_5P226 + + ntpd/ntpd-opts.texi@1.218 +1 -1 + NTP_4_2_5P226 + + ntpd/ntpd.1@1.218 +2 -2 + NTP_4_2_5P226 + + ntpdc/ntpdc-opts.c@1.216 +3 -3 + NTP_4_2_5P226 + + ntpdc/ntpdc-opts.h@1.216 +4 -4 + NTP_4_2_5P226 + + ntpdc/ntpdc-opts.texi@1.215 +3 -3 + NTP_4_2_5P226 + + ntpdc/ntpdc.1@1.215 +2 -2 + NTP_4_2_5P226 + + ntpq/ntpq-opts.c@1.216 +3 -3 + NTP_4_2_5P226 + + ntpq/ntpq-opts.h@1.216 +4 -4 + NTP_4_2_5P226 + + ntpq/ntpq-opts.texi@1.215 +3 -3 + NTP_4_2_5P226 + + ntpq/ntpq.1@1.215 +2 -2 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd-opts.c@1.95 +2 -2 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd-opts.h@1.95 +3 -3 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd-opts.texi@1.95 +1 -1 + NTP_4_2_5P226 + + ntpsnmpd/ntpsnmpd.1@1.95 +2 -2 + NTP_4_2_5P226 + + packageinfo.sh@1.229 +1 -1 + NTP_4_2_5P226 + + sntp/sntp-opts.c@1.89 +2 -2 + NTP_4_2_5P226 + + sntp/sntp-opts.h@1.89 +3 -3 + NTP_4_2_5P226 + + sntp/sntp-opts.texi@1.89 +2 -2 + NTP_4_2_5P226 + + sntp/sntp.1@1.89 +2 -2 + NTP_4_2_5P226 + + util/ntp-keygen-opts.c@1.219 +3 -3 + NTP_4_2_5P226 + + util/ntp-keygen-opts.h@1.219 +4 -4 + NTP_4_2_5P226 + + util/ntp-keygen-opts.texi@1.218 +3 -3 + NTP_4_2_5P226 + + util/ntp-keygen.1@1.218 +2 -2 + NTP_4_2_5P226 + +ChangeSet@1.2029.1.2, 2009-10-03 01:26:37-04:00, stenn@whimsy.udel.edu + Clockhop and autokey cleanup from Dave Mills + + ChangeLog@1.462.1.2 +1 -0 + Clockhop and autokey cleanup from Dave Mills + + include/ntp.h@1.165 +1 -1 + Clockhop and autokey cleanup from Dave Mills + + libntp/statestr.c@1.19 +3 -3 + Clockhop and autokey cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.140 +8 -10 + Clockhop and autokey cleanup from Dave Mills + + ntpd/ntp_proto.c@1.295 +10 -9 + Clockhop and autokey cleanup from Dave Mills + +ChangeSet@1.2029.1.1, 2009-10-03 01:19:40-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.462.1.1 +1 -0 + Documentation updates from Dave Mills + + html/accopt.html@1.33 +6 -6 + Documentation updates from Dave Mills + + html/assoc.html@1.29 +8 -2 + Documentation updates from Dave Mills + +ChangeSet@1.2030, 2009-10-03 05:13:07+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1318] Allow multiple -g options on ntpd command line. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ChangeLog@1.463 +5 -0 + [Bug 1318] Allow multiple -g options on ntpd command line. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + configure.ac@1.458 +3 -3 + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + + include/debug-opt.def@1.5 +0 -2 + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + + include/ntp_config.h@1.64 +2 -2 + add comment parameter to dump_config_tree() and dump_all_config_trees() + + libntp/Makefile.am@1.46 +3 -9 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + libparse/Makefile.am@1.15 +13 -15 + convert leading spaces to tabs. + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpd/Makefile.am@1.71 +87 -39 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + + ntpd/ntp_config.c@1.224 +41 -17 + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntp_control.c@1.124 +1 -1 + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntp_io.c@1.301 +2 -1 + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntpd-opts.c@1.219 +55 -24 + autogen output + + ntpd/ntpd-opts.h@1.219 +28 -19 + autogen output + + ntpd/ntpd-opts.texi@1.217 +26 -2 + autogen output + + ntpd/ntpd.1@1.217 +10 -2 + autogen output + + ntpd/ntpd.c@1.109 +36 -28 + ntpdsim --help was crashing due to failure to init autoopts. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpd/ntpdbase-opts.def@1.18 +46 -1 + [Bug 1318] Allow multiple -g options on ntpd command line. + [Bug 1327] ntpq, ntpdc, ntp-keygen -d and -D should work with configure + --disable-debugging. + Add ntpd --saveconfigquit option for future build-time + testing of saveconfig fidelity. + + ntpdate/Makefile.am@1.19 +5 -5 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpdc/Makefile.am@1.42 +3 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpdc/ntpdc-opts.c@1.215 +5 -30 + autogen output + + ntpdc/ntpdc-opts.h@1.215 +2 -6 + autogen output + + ntpdc/ntpdc-opts.texi@1.214 +4 -8 + autogen output + + ntpdc/ntpdc.1@1.214 +2 -2 + autogen output + + ntpq/Makefile.am@1.36 +5 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ntpq/ntpq-opts.c@1.215 +5 -30 + autogen output + + ntpq/ntpq-opts.h@1.215 +2 -6 + autogen output + + ntpq/ntpq-opts.texi@1.214 +4 -8 + autogen output + + ntpq/ntpq.1@1.214 +2 -2 + autogen output + + ntpsnmpd/Makefile.am@1.10 +7 -10 + ntpsnmpd-opts.def doesn't include debug-opt.def. + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + parseutil/Makefile.am@1.10 +5 -5 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + ports/winnt/ntpd/ntservice.c@1.19 +7 -1 + recognize alternate spellings of option names in win32 service startup hack + + ports/winnt/vs2008/libntp/libntp.vcproj@1.20 +6 -2 + add reference to ntp_md5.h + + sntp/Makefile.am@1.13 +5 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + util/Makefile.am@1.41 +4 -6 + remove as much whitespace as possible from -I include dir sequence to + keep the signal-to-noise ratio higher on BSD make, which leaves tabs + in the constructed gcc command lines. + + util/ntp-keygen-opts.c@1.218 +5 -30 + autogen output + + util/ntp-keygen-opts.h@1.218 +2 -6 + autogen output + + util/ntp-keygen-opts.texi@1.217 +4 -8 + autogen output + + util/ntp-keygen.1@1.217 +2 -2 + autogen output + +ChangeSet@1.2029, 2009-09-30 07:43:31-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P225 + TAG: NTP_4_2_5P225 + + ChangeLog@1.462 +1 -0 + NTP_4_2_5P225 + + ntpd/ntpd-opts.c@1.218 +2 -2 + NTP_4_2_5P225 + + ntpd/ntpd-opts.h@1.218 +3 -3 + NTP_4_2_5P225 + + ntpd/ntpd-opts.texi@1.216 +1 -1 + NTP_4_2_5P225 + + ntpd/ntpd.1@1.216 +2 -2 + NTP_4_2_5P225 + + ntpdc/ntpdc-opts.c@1.214 +2 -2 + NTP_4_2_5P225 + + ntpdc/ntpdc-opts.h@1.214 +3 -3 + NTP_4_2_5P225 + + ntpdc/ntpdc-opts.texi@1.213 +1 -1 + NTP_4_2_5P225 + + ntpdc/ntpdc.1@1.213 +2 -2 + NTP_4_2_5P225 + + ntpq/ntpq-opts.c@1.214 +2 -2 + NTP_4_2_5P225 + + ntpq/ntpq-opts.h@1.214 +3 -3 + NTP_4_2_5P225 + + ntpq/ntpq-opts.texi@1.213 +1 -1 + NTP_4_2_5P225 + + ntpq/ntpq.1@1.213 +2 -2 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd-opts.c@1.94 +2 -2 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd-opts.h@1.94 +3 -3 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd-opts.texi@1.94 +1 -1 + NTP_4_2_5P225 + + ntpsnmpd/ntpsnmpd.1@1.94 +2 -2 + NTP_4_2_5P225 + + packageinfo.sh@1.228 +1 -1 + NTP_4_2_5P225 + + sntp/sntp-opts.c@1.88 +2 -2 + NTP_4_2_5P225 + + sntp/sntp-opts.h@1.88 +3 -3 + NTP_4_2_5P225 + + sntp/sntp-opts.texi@1.88 +1 -1 + NTP_4_2_5P225 + + sntp/sntp.1@1.88 +2 -2 + NTP_4_2_5P225 + + util/ntp-keygen-opts.c@1.217 +2 -2 + NTP_4_2_5P225 + + util/ntp-keygen-opts.h@1.217 +3 -3 + NTP_4_2_5P225 + + util/ntp-keygen-opts.texi@1.216 +1 -1 + NTP_4_2_5P225 + + util/ntp-keygen.1@1.216 +2 -2 + NTP_4_2_5P225 + +ChangeSet@1.2026.1.1, 2009-09-30 06:32:09+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + + ChangeLog@1.459.1.1 +1 -0 + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + + ntpd/ntp_config.c@1.223 +73 -43 + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + + ntpd/ntp_io.c@1.300 +13 -7 + [Bug 1324] support bracketed IPv6 numeric addresses for restrict. + +ChangeSet@1.2027, 2009-09-30 02:10:49-04:00, stenn@whimsy.udel.edu + authopt documentation changes from Dave Mills/Dave Hart + + ChangeLog@1.460 +1 -0 + authopt documentation changes from Dave Mills/Dave Hart + + html/authopt.html@1.52 +2 -2 + authopt documentation changes from Dave Mills/Dave Hart + + html/scripts/authopt.txt@1.2 +3 -4 + authopt documentation changes from Dave Mills/Dave Hart + +ChangeSet@1.2026, 2009-09-29 07:44:52-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P224 + TAG: NTP_4_2_5P224 + + ChangeLog@1.459 +1 -0 + NTP_4_2_5P224 + + ntpd/ntpd-opts.c@1.217 +2 -2 + NTP_4_2_5P224 + + ntpd/ntpd-opts.h@1.217 +3 -3 + NTP_4_2_5P224 + + ntpd/ntpd-opts.texi@1.215 +1 -1 + NTP_4_2_5P224 + + ntpd/ntpd.1@1.215 +2 -2 + NTP_4_2_5P224 + + ntpdc/ntpdc-opts.c@1.213 +2 -2 + NTP_4_2_5P224 + + ntpdc/ntpdc-opts.h@1.213 +3 -3 + NTP_4_2_5P224 + + ntpdc/ntpdc-opts.texi@1.212 +1 -1 + NTP_4_2_5P224 + + ntpdc/ntpdc.1@1.212 +2 -2 + NTP_4_2_5P224 + + ntpq/ntpq-opts.c@1.213 +2 -2 + NTP_4_2_5P224 + + ntpq/ntpq-opts.h@1.213 +3 -3 + NTP_4_2_5P224 + + ntpq/ntpq-opts.texi@1.212 +1 -1 + NTP_4_2_5P224 + + ntpq/ntpq.1@1.212 +2 -2 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd-opts.c@1.93 +2 -2 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd-opts.h@1.93 +3 -3 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd-opts.texi@1.93 +1 -1 + NTP_4_2_5P224 + + ntpsnmpd/ntpsnmpd.1@1.93 +2 -2 + NTP_4_2_5P224 + + packageinfo.sh@1.227 +1 -1 + NTP_4_2_5P224 + + sntp/sntp-opts.c@1.87 +2 -2 + NTP_4_2_5P224 + + sntp/sntp-opts.h@1.87 +3 -3 + NTP_4_2_5P224 + + sntp/sntp-opts.texi@1.87 +1 -1 + NTP_4_2_5P224 + + sntp/sntp.1@1.87 +2 -2 + NTP_4_2_5P224 + + util/ntp-keygen-opts.c@1.216 +2 -2 + NTP_4_2_5P224 + + util/ntp-keygen-opts.h@1.216 +3 -3 + NTP_4_2_5P224 + + util/ntp-keygen-opts.texi@1.215 +1 -1 + NTP_4_2_5P224 + + util/ntp-keygen.1@1.215 +2 -2 + NTP_4_2_5P224 + +ChangeSet@1.2025, 2009-09-29 06:38:31+00:00, davehart@shiny.ad.hartbrothers.com + Remove "tos maxhop" ntp.conf knob. + + ChangeLog@1.458 +1 -0 + Remove "tos maxhop" ntp.conf knob. + + ntpd/ntp_parser.c@1.51 +888 -902 + Bison output from ntp_parser.y + + ntpd/ntp_parser.h@1.31 +175 -177 + Bison output from ntp_parser.y + + ntpd/ntp_parser.y@1.46 +0 -3 + Remove "tos maxhop" ntp.conf knob. + + ntpd/ntp_scanner.c@1.28 +0 -1 + Remove "tos maxhop" ntp.conf knob. + +ChangeSet@1.2024, 2009-09-28 22:36:59-04:00, stenn@whimsy.udel.edu + Clockhop and documentation fixes from Dave Mills + + ChangeLog@1.457 +1 -0 + Clockhop and documentation fixes from Dave Mills + + html/confopt.html@1.47 +1 -3 + Clockhop and documentation fixes from Dave Mills + + html/copyright.html@1.44 +7 -4 + Clockhop and documentation fixes from Dave Mills + + html/decode.html@1.11 +6 -1 + Clockhop and documentation fixes from Dave Mills + + html/miscopt.html@1.49 +7 -2 + Clockhop and documentation fixes from Dave Mills + + include/ntp.h@1.164 +1 -0 + Clockhop and documentation fixes from Dave Mills + + libntp/statestr.c@1.18 +1 -0 + Clockhop and documentation fixes from Dave Mills + + ntpd/ntp_config.c@1.222 +0 -5 + Clockhop and documentation fixes from Dave Mills + + ntpd/ntp_proto.c@1.294 +49 -31 + Clockhop and documentation fixes from Dave Mills + +ChangeSet@1.2023, 2009-09-28 07:43:25-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P223 + TAG: NTP_4_2_5P223 + + ChangeLog@1.456 +1 -0 + NTP_4_2_5P223 + + ntpd/ntpd-opts.c@1.216 +2 -2 + NTP_4_2_5P223 + + ntpd/ntpd-opts.h@1.216 +3 -3 + NTP_4_2_5P223 + + ntpd/ntpd-opts.texi@1.214 +1 -1 + NTP_4_2_5P223 + + ntpd/ntpd.1@1.214 +2 -2 + NTP_4_2_5P223 + + ntpdc/ntpdc-opts.c@1.212 +2 -2 + NTP_4_2_5P223 + + ntpdc/ntpdc-opts.h@1.212 +3 -3 + NTP_4_2_5P223 + + ntpdc/ntpdc-opts.texi@1.211 +1 -1 + NTP_4_2_5P223 + + ntpdc/ntpdc.1@1.211 +2 -2 + NTP_4_2_5P223 + + ntpq/ntpq-opts.c@1.212 +2 -2 + NTP_4_2_5P223 + + ntpq/ntpq-opts.h@1.212 +3 -3 + NTP_4_2_5P223 + + ntpq/ntpq-opts.texi@1.211 +1 -1 + NTP_4_2_5P223 + + ntpq/ntpq.1@1.211 +2 -2 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd-opts.c@1.92 +2 -2 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd-opts.h@1.92 +3 -3 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd-opts.texi@1.92 +1 -1 + NTP_4_2_5P223 + + ntpsnmpd/ntpsnmpd.1@1.92 +2 -2 + NTP_4_2_5P223 + + packageinfo.sh@1.226 +1 -1 + NTP_4_2_5P223 + + sntp/sntp-opts.c@1.86 +2 -2 + NTP_4_2_5P223 + + sntp/sntp-opts.h@1.86 +3 -3 + NTP_4_2_5P223 + + sntp/sntp-opts.texi@1.86 +1 -1 + NTP_4_2_5P223 + + sntp/sntp.1@1.86 +2 -2 + NTP_4_2_5P223 + + util/ntp-keygen-opts.c@1.215 +2 -2 + NTP_4_2_5P223 + + util/ntp-keygen-opts.h@1.215 +3 -3 + NTP_4_2_5P223 + + util/ntp-keygen-opts.texi@1.214 +1 -1 + NTP_4_2_5P223 + + util/ntp-keygen.1@1.214 +2 -2 + NTP_4_2_5P223 + +ChangeSet@1.2020.1.1, 2009-09-28 00:58:51+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ChangeLog@1.453.1.1 +2 -0 + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ntpd/ntp_config.c@1.221 +4 -4 + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ntpd/ntp_parser.c@1.50 +675 -661 + Bison output from ntp_parser.y + + ntpd/ntp_parser.y@1.45 +6 -0 + [Bug 1323] Implement "revoke #" to match documentation, deprecate + "crypto revoke #". + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.8 +2 -2 + fix lingering references to $(OPENSSL)\lib to $(OPENSSL_LIB) + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.20 +2 -2 + fix lingering references to $(OPENSSL)\lib to $(OPENSSL_LIB) + +ChangeSet@1.2021, 2009-09-27 20:24:13+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1321] build doesn't work if . isn't on $PATH. + + ChangeLog@1.454 +1 -0 + [Bug 1321] build doesn't work if . isn't on $PATH. + + build@1.31 +6 -1 + [Bug 1321] build doesn't work if . isn't on $PATH. + +ChangeSet@1.2020, 2009-09-27 15:31:58-04:00, stenn@whimsy.udel.edu + Hold off on the .deps cleanup for now + + bootstrap@1.26 +13 -3 + Hold off on the .deps cleanup for now + +ChangeSet@1.2019, 2009-09-27 07:50:18-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P222 + TAG: NTP_4_2_5P222 + + ChangeLog@1.453 +1 -0 + NTP_4_2_5P222 + + ntpd/ntpd-opts.c@1.215 +2 -2 + NTP_4_2_5P222 + + ntpd/ntpd-opts.h@1.215 +3 -3 + NTP_4_2_5P222 + + ntpd/ntpd-opts.texi@1.213 +1 -1 + NTP_4_2_5P222 + + ntpd/ntpd.1@1.213 +2 -2 + NTP_4_2_5P222 + + ntpdc/ntpdc-opts.c@1.211 +2 -2 + NTP_4_2_5P222 + + ntpdc/ntpdc-opts.h@1.211 +3 -3 + NTP_4_2_5P222 + + ntpdc/ntpdc-opts.texi@1.210 +1 -1 + NTP_4_2_5P222 + + ntpdc/ntpdc.1@1.210 +2 -2 + NTP_4_2_5P222 + + ntpq/ntpq-opts.c@1.211 +2 -2 + NTP_4_2_5P222 + + ntpq/ntpq-opts.h@1.211 +3 -3 + NTP_4_2_5P222 + + ntpq/ntpq-opts.texi@1.210 +1 -1 + NTP_4_2_5P222 + + ntpq/ntpq.1@1.210 +2 -2 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd-opts.c@1.91 +2 -2 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd-opts.h@1.91 +3 -3 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd-opts.texi@1.91 +1 -1 + NTP_4_2_5P222 + + ntpsnmpd/ntpsnmpd.1@1.91 +2 -2 + NTP_4_2_5P222 + + packageinfo.sh@1.225 +1 -1 + NTP_4_2_5P222 + + sntp/sntp-opts.c@1.85 +2 -2 + NTP_4_2_5P222 + + sntp/sntp-opts.h@1.85 +3 -3 + NTP_4_2_5P222 + + sntp/sntp-opts.texi@1.85 +1 -1 + NTP_4_2_5P222 + + sntp/sntp.1@1.85 +2 -2 + NTP_4_2_5P222 + + util/ntp-keygen-opts.c@1.214 +2 -2 + NTP_4_2_5P222 + + util/ntp-keygen-opts.h@1.214 +3 -3 + NTP_4_2_5P222 + + util/ntp-keygen-opts.texi@1.213 +1 -1 + NTP_4_2_5P222 + + util/ntp-keygen.1@1.213 +2 -2 + NTP_4_2_5P222 + +ChangeSet@1.2018, 2009-09-27 06:07:50-04:00, stenn@whimsy.udel.edu + Use find/xargs to remove .deps files + + bootstrap@1.25 +1 -2 + Use find/xargs to remove .deps files + +ChangeSet@1.2017, 2009-09-27 09:34:20+00:00, davehart@shiny.ad.hartbrothers.com + .del-Makefile.am~f0c497c686043766: + Delete: lib/isc/nothreads/include/isc/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~f0c497c686043766@1.2 +0 -0 + Delete: lib/isc/nothreads/include/isc/Makefile.am + +ChangeSet@1.2011.1.3, 2009-09-27 05:22:57-04:00, stenn@whimsy.udel.edu + Remove unneeded Makefile.am files from lib/isc/include + + BitKeeper/deleted/.del-Makefile.am~3d21d1b06f4d0a5e@1.1.1.1 +0 -0 + Delete: lib/isc/unix/include/isc/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~5be91011328ee7b@1.9.1.1 +0 -0 + Delete: lib/isc/include/isc/Makefile.am + + ChangeLog@1.450.1.1 +1 -0 + Remove unneeded Makefile.am files from lib/isc/include + + Makefile.am@1.83.1.1 +0 -2 + Remove unneeded Makefile.am files from lib/isc/include + + configure.ac@1.455.1.1 +0 -2 + Remove unneeded Makefile.am files from lib/isc/include + +ChangeSet@1.2014, 2009-09-27 06:53:59+00:00, davehart@shiny.ad.hartbrothers.com + Updated build and flock-build scripts. flock-build --one is a way + to perform a flock-build compatible solitary build, handy for a repo + clone's first build on a machine with autoconf, automake, etc. + Compiling ntp_parser.y using BSD make correctly places ntp_parser.h + in the top-level ntpd directory instead of A.*/ntpd. + bootstrap script updated to remove potentially stale .deps dirs. + + + ChangeLog@1.449.1.2 +6 -0 + Updated build and flock-build scripts. flock-build --one is a way + to perform a flock-build compatible solitary build, handy for a repo + clone's first build on a machine with autoconf, automake, etc. + Compiling ntp_parser.y using BSD make correctly places ntp_parser.h + in the top-level ntpd directory instead of A.*/ntpd. + bootstrap script updated to remove potentially stale .deps dirs. + + + bootstrap@1.24 +8 -0 + remove .deps directories to handle source code shuffles + + build@1.30 +26 -19 + store configure cache in top srcdir config.cache-{hostname} + so flock-build runs configure uncached once + + flock-build@1.44 +54 -37 + add --one option to invoke a single build on the invoking + host using flock-build's options to configure, useful to + bring a repo clone tree to a state like a tarball, ready + for flock-building on hosts without all dev tools (such + as autoconf, automake, bison). + update udel flock default LIST + + ntpd/Makefile.am@1.70 +27 -1 + introduce vphack_after rule to fix ntp_parser.h placement when + using build and BSD make. Thanks for Harlan's help on this. + +ChangeSet@1.2011.1.2, 2009-09-26 07:42:06-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P221 + TAG: NTP_4_2_5P221 + + ChangeLog@1.450 +1 -0 + NTP_4_2_5P221 + + ntpd/ntpd-opts.c@1.214 +2 -2 + NTP_4_2_5P221 + + ntpd/ntpd-opts.h@1.214 +3 -3 + NTP_4_2_5P221 + + ntpd/ntpd-opts.texi@1.212 +2 -2 + NTP_4_2_5P221 + + ntpd/ntpd.1@1.212 +2 -2 + NTP_4_2_5P221 + + ntpdc/ntpdc-opts.c@1.210 +2 -2 + NTP_4_2_5P221 + + ntpdc/ntpdc-opts.h@1.210 +3 -3 + NTP_4_2_5P221 + + ntpdc/ntpdc-opts.texi@1.209 +2 -2 + NTP_4_2_5P221 + + ntpdc/ntpdc.1@1.209 +2 -2 + NTP_4_2_5P221 + + ntpq/ntpq-opts.c@1.210 +2 -2 + NTP_4_2_5P221 + + ntpq/ntpq-opts.h@1.210 +3 -3 + NTP_4_2_5P221 + + ntpq/ntpq-opts.texi@1.209 +2 -2 + NTP_4_2_5P221 + + ntpq/ntpq.1@1.209 +2 -2 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd-opts.c@1.90 +2 -2 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd-opts.h@1.90 +3 -3 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd-opts.texi@1.90 +1 -1 + NTP_4_2_5P221 + + ntpsnmpd/ntpsnmpd.1@1.90 +2 -2 + NTP_4_2_5P221 + + packageinfo.sh@1.224 +1 -1 + NTP_4_2_5P221 + + sntp/sntp-opts.c@1.84 +2 -2 + NTP_4_2_5P221 + + sntp/sntp-opts.h@1.84 +3 -3 + NTP_4_2_5P221 + + sntp/sntp-opts.texi@1.84 +2 -2 + NTP_4_2_5P221 + + sntp/sntp.1@1.84 +2 -2 + NTP_4_2_5P221 + + util/ntp-keygen-opts.c@1.213 +2 -2 + NTP_4_2_5P221 + + util/ntp-keygen-opts.h@1.213 +3 -3 + NTP_4_2_5P221 + + util/ntp-keygen-opts.texi@1.212 +2 -2 + NTP_4_2_5P221 + + util/ntp-keygen.1@1.212 +2 -2 + NTP_4_2_5P221 + +ChangeSet@1.2010.1.1, 2009-09-26 03:55:56-04:00, murray@pogo.udel.edu + ChangeLog, refclock_nmea.c: + Fix for Bug 1316: segfault from refclock_nmea + + ChangeLog@1.448 +1 -0 + Fix for Bug 1316 + + ntpd/refclock_nmea.c@1.43 +4 -2 + Fix for Bug 1316 + +ChangeSet@1.2011, 2009-09-25 19:32:13-04:00, stenn@whimsy.udel.edu + [Bug 1317] Distribute cvo.sh + + ChangeLog@1.447.1.1 +1 -0 + [Bug 1317] Distribute cvo.sh + + scripts/Makefile.am@1.16 +2 -2 + [Bug 1317] Distribute cvo.sh + +ChangeSet@1.2004.2.1, 2009-09-25 19:30:24+00:00, davehart@shiny.ad.hartbrothers.com + correct a few overlooked bk mv's in upstream libisc repo related to + lib/isc/nothreads/include/isc + + BitKeeper/deleted/.del-mutex.h~d46b831ccac8e078@1.2 +0 -0 + Delete: lib/isc/nothreads/include/isc/mutex.h + + BitKeeper/deleted/.del-once.h~79619f1c64fdf49b@1.2 +0 -0 + Delete: lib/isc/nothreads/include/isc/once.h + + BitKeeper/deleted/.del-strerror.c~5704d44@1.2.1.1 +0 -0 + Delete: ports/winnt/libntp/strerror.c + + lib/isc/nothreads/include/isc/mutex.h@1.3.1.2 +10 -10 + correct a few overlooked bk mv's in upstream libisc repo related to + lib/isc/nothreads/include/isc + + lib/isc/nothreads/include/isc/mutex.h@1.3.1.1 +0 -0 + Rename: lib/isc/include/isc/mutex.h -> lib/isc/nothreads/include/isc/mutex.h + + lib/isc/nothreads/include/isc/once.h@1.3.1.2 +10 -10 + correct a few overlooked bk mv's in upstream libisc repo related to + lib/isc/nothreads/include/isc + + lib/isc/nothreads/include/isc/once.h@1.3.1.1 +0 -0 + Rename: lib/isc/include/isc/once.h -> lib/isc/nothreads/include/isc/once.h + +ChangeSet@1.2004.1.3, 2009-09-25 19:17:24+00:00, davehart@shiny.ad.hartbrothers.com + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + BitKeeper/deleted/.del-mutex.h~cf2fbab1@1.4 +0 -0 + Rename: lib/isc/include/isc/mutex.h -> BitKeeper/deleted/.del-mutex.h~cf2fbab1 + + BitKeeper/deleted/.del-once.h~cfad354a@1.4 +0 -0 + Rename: lib/isc/include/isc/once.h -> BitKeeper/deleted/.del-once.h~cfad354a + + BitKeeper/deleted/.del-strerror.c~5704d44@1.3 +0 -0 + Rename: ports/winnt/libntp/strerror.c -> BitKeeper/deleted/.del-strerror.c~5704d44 + + ChangeLog@1.443.1.1 +6 -0 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + Makefile.am@1.82.1.1 +2 -1 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + configure.ac@1.456 +1 -0 + add reference to lib/isc/nothreads/include/isc/Makefile.am + + lib/isc/include/isc/Makefile.am@1.10 +71 -30 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + lib/isc/include/isc/interfaceiter.h@1.7 +3 -0 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/include/isc/msgs.h@1.6 +1 -0 + add ISC_MSG_GETBCSTADDR used by NTP-local interface iterator changes + + lib/isc/inet_ntop.c@1.8 +6 -2 + use ntp_snprintf.h's SNPRINTF for SunOS 4 compat + + lib/isc/nothreads/include/isc/Makefile.am@1.1 +12 -0 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + lib/isc/nothreads/include/isc/Makefile.am@1.0 +0 -0 + + lib/isc/sockaddr.c@1.9 +1 -1 + cast to silence warning + + lib/isc/unix/ifiter_getifaddrs.c@1.8 +14 -1 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/unix/ifiter_ioctl.c@1.28 +76 -0 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/unix/ifiter_sysctl.c@1.15 +13 -0 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/unix/include/isc/Makefile.am@1.2 +12 -8 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + lib/isc/unix/net.c@1.13 +2 -2 + NTP-local change, use GETSOCKNAME_SOCKLEN_TYPE + + lib/isc/unix/strerror.c@1.6 +2 -0 + NTP local change, #include "l_stdlib.h" + + lib/isc/win32/include/isc/platform.h@1.6 +20 -11 + NTP-local change, disable __declspec(dllimport) for libisc public + interfaces with #define ISC_STATIC_WIN + + lib/isc/win32/include/isc/stat.h@1.4 +15 -0 + NTP-local changes: alias more identifiers from POSIX names to Microsoft's, + with leading underscores, so libopts builds on Windows + + lib/isc/win32/include/isc/thread.h@1.2 +1 -1 + NTP-local fix type, silence warning + + lib/isc/win32/interfaceiter.c@1.10.1.3 +36 -1 + add NTP-local broadcast address, broadcast & multicast bitflags + to libisc network interface iterator + + lib/isc/win32/net.c@1.12 +3 -3 + NTP-local changes fix closeocket(s) typo, silence two warnings with casts + + lib/isc/win32/strerror.c@1.11 +15 -10 + NTP-local changes: use CRT_strerror() not strerror() to avoid our + #define strerror, do not reference _sys_nerr when calling strerror() + will do and avoids a deprecation warning for _sys_nerr + + lib/isc/win32/thread.c@1.2 +7 -3 + NTP-local change, handle 64-bit isc_threadresult_t correctly + + libntp/Makefile.am@1.45 +44 -19 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + libparse/Makefile.am@1.14 +9 -6 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpd/Makefile.am@1.69 +9 -7 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpd/ntp_io.c@1.297.1.1 +54 -11 + libisc network interface iterator now requires a mctx, build one + on top of emalloc() + + ntpdate/Makefile.am@1.18 +4 -3 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpdc/Makefile.am@1.41 +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpq/Makefile.am@1.35 +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ntpsnmpd/Makefile.am@1.9 +7 -6 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + parseutil/Makefile.am@1.9 +4 -3 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + ports/winnt/include/config.h@1.77 +9 -2 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/libntp/syslog.c@1.6 +28 -1 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/ntpd/ntservice.c@1.18 +4 -14 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/ntpd/win32_io.c@1.19 +1 -0 + #include to quiet warning about _open_osfhandle + + ports/winnt/vc6/libntp.dsp@1.43 +38 -2 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vc6/ntpd.dsp@1.39 +5 -5 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2003/libntp.vcproj@1.4 +98 -47 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2003/ntpd.vcproj@1.4 +5 -5 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2005/libntp.vcproj@1.4 +102 -46 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2005/ntpd.vcproj@1.4 +5 -5 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.19 +102 -1358 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.19 +6 -6 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream, reapply NTP-local changes. + + sntp/Makefile.am@1.12 +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + sntp/main.c@1.19 +2 -2 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + + util/Makefile.am@1.40 +5 -4 + Update libisc from bind-9.6.1-P1.tar.gz, rearrange directory layout + to match upstream + +ChangeSet@1.2008.1.1, 2009-09-25 15:48:47+00:00, davehart@shiny.ad.hartbrothers.com + Makefile.am: correct EXTRA_DIST reference from libisc to lib/isc + + Makefile.am@1.83 +1 -1 + correct EXTRA_DIST reference from libisc to lib/isc + +ChangeSet@1.2009, 2009-09-25 07:47:32-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P220 + TAG: NTP_4_2_5P220 + + ChangeLog@1.447 +1 -0 + NTP_4_2_5P220 + + ntpd/ntpd-opts.c@1.213 +2 -2 + NTP_4_2_5P220 + + ntpd/ntpd-opts.h@1.213 +3 -3 + NTP_4_2_5P220 + + ntpd/ntpd-opts.texi@1.211 +1 -1 + NTP_4_2_5P220 + + ntpd/ntpd.1@1.211 +2 -2 + NTP_4_2_5P220 + + ntpdc/ntpdc-opts.c@1.209 +2 -2 + NTP_4_2_5P220 + + ntpdc/ntpdc-opts.h@1.209 +3 -3 + NTP_4_2_5P220 + + ntpdc/ntpdc-opts.texi@1.208 +1 -1 + NTP_4_2_5P220 + + ntpdc/ntpdc.1@1.208 +2 -2 + NTP_4_2_5P220 + + ntpq/ntpq-opts.c@1.209 +2 -2 + NTP_4_2_5P220 + + ntpq/ntpq-opts.h@1.209 +3 -3 + NTP_4_2_5P220 + + ntpq/ntpq-opts.texi@1.208 +1 -1 + NTP_4_2_5P220 + + ntpq/ntpq.1@1.208 +2 -2 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd-opts.c@1.89 +2 -2 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd-opts.h@1.89 +3 -3 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd-opts.texi@1.89 +1 -1 + NTP_4_2_5P220 + + ntpsnmpd/ntpsnmpd.1@1.89 +2 -2 + NTP_4_2_5P220 + + packageinfo.sh@1.223 +1 -1 + NTP_4_2_5P220 + + sntp/sntp-opts.c@1.83 +2 -2 + NTP_4_2_5P220 + + sntp/sntp-opts.h@1.83 +3 -3 + NTP_4_2_5P220 + + sntp/sntp-opts.texi@1.83 +1 -1 + NTP_4_2_5P220 + + sntp/sntp.1@1.83 +2 -2 + NTP_4_2_5P220 + + util/ntp-keygen-opts.c@1.212 +2 -2 + NTP_4_2_5P220 + + util/ntp-keygen-opts.h@1.212 +3 -3 + NTP_4_2_5P220 + + util/ntp-keygen-opts.texi@1.211 +1 -1 + NTP_4_2_5P220 + + util/ntp-keygen.1@1.211 +2 -2 + NTP_4_2_5P220 + +ChangeSet@1.2008, 2009-09-25 07:09:49+00:00, davehart@shiny.ad.hartbrothers.com + Rearrange libisc code to match the upstream layout in BIND. This is + step one of two, changing the layout but keeping our existing libisc. + + ChangeLog@1.446 +2 -0 + Rearrange libisc code to match the upstream layout in BIND. This is + step one of two, changing the layout but keeping our existing libisc. + +ChangeSet@1.2004.1.2, 2009-09-24 15:52:46+00:00, davehart@shiny.ad.hartbrothers.com + import unmodified lib/isc from ISC bind-9.6.1-P1.tar.gz + + lib/isc/alpha/include/isc/atomic.h@1.1 +184 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/alpha/include/isc/atomic.h@1.0 +0 -0 + + lib/isc/api@1.1 +3 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/api@1.0 +0 -0 + + lib/isc/assertions.c@1.4 +17 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/base32.c@1.1 +371 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/base32.c@1.0 +0 -0 + + lib/isc/base64.c@1.1 +250 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/base64.c@1.0 +0 -0 + + lib/isc/bitstring.c@1.1 +127 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/bitstring.c@1.0 +0 -0 + + lib/isc/buffer.c@1.1 +489 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/buffer.c@1.0 +0 -0 + + lib/isc/bufferlist.c@1.1 +64 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/bufferlist.c@1.0 +0 -0 + + lib/isc/commandline.c@1.1 +225 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/commandline.c@1.0 +0 -0 + + lib/isc/entropy.c@1.1 +1274 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/entropy.c@1.0 +0 -0 + + lib/isc/error.c@1.4 +15 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/event.c@1.1 +88 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/event.c@1.0 +0 -0 + + lib/isc/fsaccess.c@1.1 +102 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/fsaccess.c@1.0 +0 -0 + + lib/isc/hash.c@1.1 +390 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hash.c@1.0 +0 -0 + + lib/isc/heap.c@1.1 +262 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/heap.c@1.0 +0 -0 + + lib/isc/hex.c@1.1 +201 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hex.c@1.0 +0 -0 + + lib/isc/hmacmd5.c@1.1 +118 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hmacmd5.c@1.0 +0 -0 + + lib/isc/hmacsha.c@1.1 +438 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/hmacsha.c@1.0 +0 -0 + + lib/isc/httpd.c@1.1 +987 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/httpd.c@1.0 +0 -0 + + lib/isc/ia64/include/isc/atomic.h@1.1 +100 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/ia64/include/isc/atomic.h@1.0 +0 -0 + + lib/isc/include/isc/app.h@1.4 +57 -57 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/assertions.h@1.4 +16 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/base32.h@1.1 +128 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/base32.h@1.0 +0 -0 + + lib/isc/include/isc/base64.h@1.1 +99 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/base64.h@1.0 +0 -0 + + lib/isc/include/isc/bitstring.h@1.1 +157 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/bitstring.h@1.0 +0 -0 + + lib/isc/include/isc/boolean.h@1.4 +12 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/buffer.h@1.4 +251 -147 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/bufferlist.h@1.1 +86 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/bufferlist.h@1.0 +0 -0 + + lib/isc/include/isc/commandline.h@1.1 +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/commandline.h@1.0 +0 -0 + + lib/isc/include/isc/entropy.h@1.1 +314 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/entropy.h@1.0 +0 -0 + + lib/isc/include/isc/error.h@1.4 +17 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/event.h@1.1 +121 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/event.h@1.0 +0 -0 + + lib/isc/include/isc/eventclass.h@1.1 +53 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/eventclass.h@1.0 +0 -0 + + lib/isc/include/isc/file.h@1.4 +8 -8 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/formatcheck.h@1.4 +20 -14 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/fsaccess.h@1.1 +178 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/fsaccess.h@1.0 +0 -0 + + lib/isc/include/isc/hash.h@1.1 +185 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hash.h@1.0 +0 -0 + + lib/isc/include/isc/heap.h@1.1 +170 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/heap.h@1.0 +0 -0 + + lib/isc/include/isc/hex.h@1.1 +98 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hex.h@1.0 +0 -0 + + lib/isc/include/isc/hmacmd5.h@1.1 +63 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hmacmd5.h@1.0 +0 -0 + + lib/isc/include/isc/hmacsha.h@1.1 +156 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/hmacsha.h@1.0 +0 -0 + + lib/isc/include/isc/httpd.h@1.1 +64 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/httpd.h@1.0 +0 -0 + + lib/isc/include/isc/interfaceiter.h@1.6 +46 -50 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ipv6.h@1.9 +22 -29 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/iterated_hash.h@1.1 +47 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/iterated_hash.h@1.0 +0 -0 + + lib/isc/include/isc/lang.h@1.4 +12 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/lex.h@1.1 +431 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/lex.h@1.0 +0 -0 + + lib/isc/include/isc/lfsr.h@1.1 +130 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/lfsr.h@1.0 +0 -0 + + lib/isc/include/isc/lib.h@1.4 +14 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/list.h@1.4 +17 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/log.h@1.3 +15 -14 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/magic.h@1.4 +13 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/mem.h@1.5 +612 -19 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/msgcat.h@1.4 +33 -34 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/msgs.h@1.5 +137 -126 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/mutexblock.h@1.1 +71 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/mutexblock.h@1.0 +0 -0 + + lib/isc/include/isc/netaddr.h@1.6 +58 -27 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/netscope.h@1.3 +9 -6 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ondestroy.h@1.1 +116 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ondestroy.h@1.0 +0 -0 + + lib/isc/include/isc/os.h@1.1 +38 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/os.h@1.0 +0 -0 + + lib/isc/include/isc/parseint.h@1.1 +64 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/parseint.h@1.0 +0 -0 + + lib/isc/include/isc/platform.h.in@1.1 +339 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/platform.h.in@1.0 +0 -0 + + lib/isc/include/isc/portset.h@1.1 +141 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/portset.h@1.0 +0 -0 + + lib/isc/include/isc/print.h@1.4 +31 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/quota.h@1.1 +119 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/quota.h@1.0 +0 -0 + + lib/isc/include/isc/radix.h@1.1 +240 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/radix.h@1.0 +0 -0 + + lib/isc/include/isc/random.h@1.1 +62 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/random.h@1.0 +0 -0 + + lib/isc/include/isc/ratelimiter.h@1.1 +134 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/ratelimiter.h@1.0 +0 -0 + + lib/isc/include/isc/refcount.h@1.1 +233 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/refcount.h@1.0 +0 -0 + + lib/isc/include/isc/region.h@1.3 +14 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resource.h@1.1 +97 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resource.h@1.0 +0 -0 + + lib/isc/include/isc/result.h@1.5 +69 -68 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resultclass.h@1.1 +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/resultclass.h@1.0 +0 -0 + + lib/isc/include/isc/rwlock.h@1.1 +135 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/rwlock.h@1.0 +0 -0 + + lib/isc/include/isc/serial.h@1.1 +75 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/serial.h@1.0 +0 -0 + + lib/isc/include/isc/sha1.h@1.1 +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/sha1.h@1.0 +0 -0 + + lib/isc/include/isc/sha2.h@1.1 +132 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/sha2.h@1.0 +0 -0 + + lib/isc/include/isc/sockaddr.h@1.5 +83 -44 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/socket.h@1.1 +1007 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/socket.h@1.0 +0 -0 + + lib/isc/include/isc/stats.h@1.1 +121 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/stats.h@1.0 +0 -0 + + lib/isc/include/isc/stdio.h@1.3 +4 -4 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/stdlib.h@1.1 +40 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/stdlib.h@1.0 +0 -0 + + lib/isc/include/isc/string.h@1.4 +188 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/symtab.h@1.1 +131 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/symtab.h@1.0 +0 -0 + + lib/isc/include/isc/task.h@1.1 +624 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/task.h@1.0 +0 -0 + + lib/isc/include/isc/taskpool.h@1.1 +105 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/taskpool.h@1.0 +0 -0 + + lib/isc/include/isc/timer.h@1.1 +344 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/timer.h@1.0 +0 -0 + + lib/isc/include/isc/types.h@1.4 +81 -59 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/util.h@1.4 +26 -18 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/version.h@1.1 +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/version.h@1.0 +0 -0 + + lib/isc/include/isc/xml.h@1.1 +41 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/include/isc/xml.h@1.0 +0 -0 + + lib/isc/inet_aton.c@1.4 +9 -8 + bind-9.6.1-P1.tar.gz + + lib/isc/inet_ntop.c@1.7 +25 -31 + bind-9.6.1-P1.tar.gz + + lib/isc/inet_pton.c@1.4 +34 -37 + bind-9.6.1-P1.tar.gz + + lib/isc/iterated_hash.c@1.1 +48 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/iterated_hash.c@1.0 +0 -0 + + lib/isc/lex.c@1.1 +959 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/lex.c@1.0 +0 -0 + + lib/isc/lfsr.c@1.1 +161 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/lfsr.c@1.0 +0 -0 + + lib/isc/lib.c@1.4 +13 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/log.c@1.3 +15 -15 + bind-9.6.1-P1.tar.gz + + lib/isc/mem.c@1.5 +2181 -23 + bind-9.6.1-P1.tar.gz + + lib/isc/mips/include/isc/atomic.h@1.1 +98 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/mips/include/isc/atomic.h@1.0 +0 -0 + + lib/isc/mutexblock.c@1.1 +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/mutexblock.c@1.0 +0 -0 + + lib/isc/netaddr.c@1.6 +83 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/netscope.c@1.3 +5 -3 + bind-9.6.1-P1.tar.gz + + lib/isc/nls/msgcat.c@1.6 +14 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/noatomic/include/isc/atomic.h@1.1 +24 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/noatomic/include/isc/atomic.h@1.0 +0 -0 + + lib/isc/nothreads/condition.c@1.1 +24 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/condition.c@1.0 +0 -0 + + lib/isc/nothreads/include/isc/condition.h@1.1 +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/condition.h@1.0 +0 -0 + + lib/isc/nothreads/include/isc/mutex.h@1.1 +39 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/mutex.h@1.0 +0 -0 + + lib/isc/nothreads/include/isc/once.h@1.1 +32 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/once.h@1.0 +0 -0 + + lib/isc/nothreads/include/isc/thread.h@1.1 +35 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/include/isc/thread.h@1.0 +0 -0 + + lib/isc/nothreads/mutex.c@1.1 +25 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/mutex.c@1.0 +0 -0 + + lib/isc/nothreads/thread.c@1.1 +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/nothreads/thread.c@1.0 +0 -0 + + lib/isc/ondestroy.c@1.1 +85 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/ondestroy.c@1.0 +0 -0 + + lib/isc/parseint.c@1.1 +72 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/parseint.c@1.0 +0 -0 + + lib/isc/portset.c@1.1 +143 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/portset.c@1.0 +0 -0 + + lib/isc/powerpc/include/isc/atomic.h@1.1 +160 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/powerpc/include/isc/atomic.h@1.0 +0 -0 + + lib/isc/print.c@1.1 +624 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/print.c@1.0 +0 -0 + + lib/isc/pthreads/condition.c@1.1 +74 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/condition.c@1.0 +0 -0 + + lib/isc/pthreads/include/isc/condition.h@1.1 +65 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/condition.h@1.0 +0 -0 + + lib/isc/pthreads/include/isc/mutex.h@1.1 +145 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/mutex.h@1.0 +0 -0 + + lib/isc/pthreads/include/isc/once.h@1.1 +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/once.h@1.0 +0 -0 + + lib/isc/pthreads/include/isc/thread.h@1.1 +60 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/include/isc/thread.h@1.0 +0 -0 + + lib/isc/pthreads/mutex.c@1.1 +272 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/mutex.c@1.0 +0 -0 + + lib/isc/pthreads/thread.c@1.1 +76 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/pthreads/thread.c@1.0 +0 -0 + + lib/isc/quota.c@1.1 +101 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/quota.c@1.0 +0 -0 + + lib/isc/radix.c@1.1 +706 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/radix.c@1.0 +0 -0 + + lib/isc/random.c@1.1 +104 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/random.c@1.0 +0 -0 + + lib/isc/ratelimiter.c@1.1 +328 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/ratelimiter.c@1.0 +0 -0 + + lib/isc/refcount.c@1.1 +37 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/refcount.c@1.0 +0 -0 + + lib/isc/region.c@1.1 +45 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/region.c@1.0 +0 -0 + + lib/isc/result.c@1.1 +213 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/result.c@1.0 +0 -0 + + lib/isc/rwlock.c@1.1 +808 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/rwlock.c@1.0 +0 -0 + + lib/isc/serial.c@1.1 +59 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/serial.c@1.0 +0 -0 + + lib/isc/sha1.c@1.1 +315 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/sha1.c@1.0 +0 -0 + + lib/isc/sha2.c@1.1 +1234 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/sha2.c@1.0 +0 -0 + + lib/isc/sockaddr.c@1.8 +87 -64 + bind-9.6.1-P1.tar.gz + + lib/isc/sparc64/include/isc/atomic.h@1.1 +127 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/sparc64/include/isc/atomic.h@1.0 +0 -0 + + lib/isc/stats.c@1.1 +326 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/stats.c@1.0 +0 -0 + + lib/isc/string.c@1.1 +270 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/string.c@1.0 +0 -0 + + lib/isc/strtoul.c@1.1 +129 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/strtoul.c@1.0 +0 -0 + + lib/isc/symtab.c@1.1 +252 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/symtab.c@1.0 +0 -0 + + lib/isc/task.c@1.1 +1376 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/task.c@1.0 +0 -0 + + lib/isc/task_p.h@1.1 +31 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/task_p.h@1.0 +0 -0 + + lib/isc/taskpool.c@1.1 +96 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/taskpool.c@1.0 +0 -0 + + lib/isc/timer.c@1.1 +933 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/timer.c@1.0 +0 -0 + + lib/isc/timer_p.h@1.1 +31 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/timer_p.h@1.0 +0 -0 + + lib/isc/unix/app.c@1.1 +684 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/app.c@1.0 +0 -0 + + lib/isc/unix/dir.c@1.1 +251 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/dir.c@1.0 +0 -0 + + lib/isc/unix/entropy.c@1.1 +605 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/entropy.c@1.0 +0 -0 + + lib/isc/unix/errno2result.c@1.1 +123 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/errno2result.c@1.0 +0 -0 + + lib/isc/unix/errno2result.h@1.1 +39 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/errno2result.h@1.0 +0 -0 + + lib/isc/unix/file.c@1.1 +444 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/file.c@1.0 +0 -0 + + lib/isc/unix/fsaccess.c@1.1 +93 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/fsaccess.c@1.0 +0 -0 + + lib/isc/unix/ifiter_getifaddrs.c@1.7 +72 -29 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ifiter_ioctl.c@1.27 +49 -236 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ifiter_sysctl.c@1.14 +6 -19 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/dir.h@1.3 +3 -3 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/int.h@1.4 +13 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/keyboard.h@1.1 +52 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/keyboard.h@1.0 +0 -0 + + lib/isc/unix/include/isc/net.h@1.10 +91 -56 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/netdb.h@1.1 +57 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/netdb.h@1.0 +0 -0 + + lib/isc/unix/include/isc/offset.h@1.4 +14 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/stat.h@1.3 +3 -3 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/stdtime.h@1.1 +60 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/stdtime.h@1.0 +0 -0 + + lib/isc/unix/include/isc/strerror.h@1.4 +15 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/syslog.h@1.1 +47 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/include/isc/syslog.h@1.0 +0 -0 + + lib/isc/unix/include/isc/time.h@1.3 +40 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/interfaceiter.c@1.17 +99 -7 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ipv6.c@1.1 +27 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/ipv6.c@1.0 +0 -0 + + lib/isc/unix/keyboard.c@1.1 +126 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/keyboard.c@1.0 +0 -0 + + lib/isc/unix/net.c@1.12 +232 -19 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/os.c@1.1 +94 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/os.c@1.0 +0 -0 + + lib/isc/unix/resource.c@1.1 +231 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/resource.c@1.0 +0 -0 + + lib/isc/unix/socket.c@1.1 +5550 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/socket.c@1.0 +0 -0 + + lib/isc/unix/socket_p.h@1.1 +32 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/socket_p.h@1.0 +0 -0 + + lib/isc/unix/stdio.c@1.1 +117 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/stdio.c@1.0 +0 -0 + + lib/isc/unix/stdtime.c@1.1 +86 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/stdtime.c@1.0 +0 -0 + + lib/isc/unix/strerror.c@1.5 +15 -15 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/syslog.c@1.1 +84 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/syslog.c@1.0 +0 -0 + + lib/isc/unix/time.c@1.1 +438 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/unix/time.c@1.0 +0 -0 + + lib/isc/version.c@1.1 +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/version.c@1.0 +0 -0 + + lib/isc/win32/DLLMain.c@1.1 +58 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/DLLMain.c@1.0 +0 -0 + + lib/isc/win32/app.c@1.1 +260 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/app.c@1.0 +0 -0 + + lib/isc/win32/condition.c@1.1 +258 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/condition.c@1.0 +0 -0 + + lib/isc/win32/dir.c@1.1 +312 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/dir.c@1.0 +0 -0 + + lib/isc/win32/entropy.c@1.1 +307 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/entropy.c@1.0 +0 -0 + + lib/isc/win32/errno2result.c@1.1 +113 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/errno2result.c@1.0 +0 -0 + + lib/isc/win32/errno2result.h@1.1 +40 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/errno2result.h@1.0 +0 -0 + + lib/isc/win32/file.c@1.1 +507 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/file.c@1.0 +0 -0 + + lib/isc/win32/fsaccess.c@1.1 +375 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/fsaccess.c@1.0 +0 -0 + + lib/isc/win32/include/isc/bind_registry.h@1.1 +50 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/bind_registry.h@1.0 +0 -0 + + lib/isc/win32/include/isc/bindevt.h@1.1 +91 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/bindevt.h@1.0 +0 -0 + + lib/isc/win32/include/isc/condition.h@1.1 +67 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/condition.h@1.0 +0 -0 + + lib/isc/win32/include/isc/dir.h@1.1 +83 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/dir.h@1.0 +0 -0 + + lib/isc/win32/include/isc/int.h@1.4 +10 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/ipv6.h@1.8 +10 -15 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/keyboard.h@1.1 +47 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/keyboard.h@1.0 +0 -0 + + lib/isc/win32/include/isc/mutex.h@1.4 +17 -13 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/netdb.h@1.1 +54 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/netdb.h@1.0 +0 -0 + + lib/isc/win32/include/isc/ntgroups.h@1.1 +35 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/ntgroups.h@1.0 +0 -0 + + lib/isc/win32/include/isc/ntpaths.h@1.1 +71 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/ntpaths.h@1.0 +0 -0 + + lib/isc/win32/include/isc/offset.h@1.4 +11 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/once.h@1.4 +10 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/platform.h@1.5 +26 -23 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/stat.h@1.3 +3 -23 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/stdtime.h@1.1 +58 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/stdtime.h@1.0 +0 -0 + + lib/isc/win32/include/isc/strerror.h@1.4 +10 -10 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/syslog.h@1.1 +45 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/syslog.h@1.0 +0 -0 + + lib/isc/win32/include/isc/thread.h@1.1 +100 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/thread.h@1.0 +0 -0 + + lib/isc/win32/include/isc/time.h@1.1 +291 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/include/isc/time.h@1.0 +0 -0 + + lib/isc/win32/include/isc/win32os.h@1.4 +11 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/interfaceiter.c@1.10.1.2 +11 -45 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ipv6.c@1.1 +27 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ipv6.c@1.0 +0 -0 + + lib/isc/win32/keyboard.c@1.1 +89 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/keyboard.c@1.0 +0 -0 + + lib/isc/win32/libisc.def@1.1 +551 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.def@1.0 +0 -0 + + lib/isc/win32/libisc.dsp@1.1 +784 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.dsp@1.0 +0 -0 + + lib/isc/win32/libisc.dsw@1.1 +29 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.dsw@1.0 +0 -0 + + lib/isc/win32/libisc.mak@1.1 +2006 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/libisc.mak@1.0 +0 -0 + + lib/isc/win32/net.c@1.11 +4 -4 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/netdb.h@1.1 +187 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/netdb.h@1.0 +0 -0 + + lib/isc/win32/ntgroups.c@1.1 +186 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ntgroups.c@1.0 +0 -0 + + lib/isc/win32/ntpaths.c@1.1 +140 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/ntpaths.c@1.0 +0 -0 + + lib/isc/win32/once.c@1.4 +15 -12 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/os.c@1.1 +45 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/os.c@1.0 +0 -0 + + lib/isc/win32/resource.c@1.1 +72 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/resource.c@1.0 +0 -0 + + lib/isc/win32/socket.c@1.1 +3674 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/socket.c@1.0 +0 -0 + + lib/isc/win32/stdio.c@1.1 +117 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/stdio.c@1.0 +0 -0 + + lib/isc/win32/stdtime.c@1.1 +37 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/stdtime.c@1.0 +0 -0 + + lib/isc/win32/strerror.c@1.10 +71 -221 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/syslog.c@1.1 +181 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/syslog.c@1.0 +0 -0 + + lib/isc/win32/syslog.h@1.1 +76 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/syslog.h@1.0 +0 -0 + + lib/isc/win32/thread.c@1.1 +90 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/thread.c@1.0 +0 -0 + + lib/isc/win32/time.c@1.1 +295 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/time.c@1.0 +0 -0 + + lib/isc/win32/unistd.h@1.1 +53 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/unistd.h@1.0 +0 -0 + + lib/isc/win32/version.c@1.1 +28 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/win32/version.c@1.0 +0 -0 + + lib/isc/win32/win32os.c@1.4 +11 -11 + bind-9.6.1-P1.tar.gz + + lib/isc/x86_32/include/isc/atomic.h@1.1 +176 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/x86_32/include/isc/atomic.h@1.0 +0 -0 + + lib/isc/x86_64/include/isc/atomic.h@1.1 +123 -0 + bind-9.6.1-P1.tar.gz + + lib/isc/x86_64/include/isc/atomic.h@1.0 +0 -0 + +ChangeSet@1.2006, 2009-09-24 07:52:55-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P219 + TAG: NTP_4_2_5P219 + + ChangeLog@1.445 +1 -0 + NTP_4_2_5P219 + + ntpd/ntpd-opts.c@1.212 +2 -2 + NTP_4_2_5P219 + + ntpd/ntpd-opts.h@1.212 +3 -3 + NTP_4_2_5P219 + + ntpd/ntpd-opts.texi@1.210 +1 -1 + NTP_4_2_5P219 + + ntpd/ntpd.1@1.210 +2 -2 + NTP_4_2_5P219 + + ntpdc/ntpdc-opts.c@1.208 +2 -2 + NTP_4_2_5P219 + + ntpdc/ntpdc-opts.h@1.208 +3 -3 + NTP_4_2_5P219 + + ntpdc/ntpdc-opts.texi@1.207 +1 -1 + NTP_4_2_5P219 + + ntpdc/ntpdc.1@1.207 +2 -2 + NTP_4_2_5P219 + + ntpq/ntpq-opts.c@1.208 +2 -2 + NTP_4_2_5P219 + + ntpq/ntpq-opts.h@1.208 +3 -3 + NTP_4_2_5P219 + + ntpq/ntpq-opts.texi@1.207 +1 -1 + NTP_4_2_5P219 + + ntpq/ntpq.1@1.207 +2 -2 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd-opts.c@1.88 +2 -2 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd-opts.h@1.88 +3 -3 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd-opts.texi@1.88 +1 -1 + NTP_4_2_5P219 + + ntpsnmpd/ntpsnmpd.1@1.88 +2 -2 + NTP_4_2_5P219 + + packageinfo.sh@1.222 +1 -1 + NTP_4_2_5P219 + + sntp/sntp-opts.c@1.82 +2 -2 + NTP_4_2_5P219 + + sntp/sntp-opts.h@1.82 +3 -3 + NTP_4_2_5P219 + + sntp/sntp-opts.texi@1.82 +1 -1 + NTP_4_2_5P219 + + sntp/sntp.1@1.82 +2 -2 + NTP_4_2_5P219 + + util/ntp-keygen-opts.c@1.211 +2 -2 + NTP_4_2_5P219 + + util/ntp-keygen-opts.h@1.211 +3 -3 + NTP_4_2_5P219 + + util/ntp-keygen-opts.texi@1.210 +1 -1 + NTP_4_2_5P219 + + util/ntp-keygen.1@1.210 +2 -2 + NTP_4_2_5P219 + +ChangeSet@1.2004.1.1, 2009-09-24 07:27:15+00:00, davehart@shiny.ad.hartbrothers.com + Reorganize our copy of libisc code to match BIND 9 tarball layout, preparing + for easier drop-in of newer libisc code in the future via a + "ntp-dev-libisc-upstream" repo which gets only unmodified ISC source, and is + pulled into ntp-dev allowing BK to assist with the merge of local changes in + the future. + + BitKeeper/deleted/.del-interfaceiter.c~554505c@1.4 +0 -0 + Rename: ports/winnt/libntp/interfaceiter.c -> BitKeeper/deleted/.del-interfaceiter.c~554505c + + BitKeeper/deleted/.del-strerror.c~7b58fc6b@1.3 +0 -0 + Rename: libisc/strerror.c -> BitKeeper/deleted/.del-strerror.c~7b58fc6b + + Makefile.am@1.82 +7 -4 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + configure.ac@1.455 +2 -1 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + include/Makefile.am@1.35 +0 -2 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + lib/isc/assertions.c@1.3 +0 -0 + Rename: libisc/assertions.c -> lib/isc/assertions.c + + lib/isc/error.c@1.3 +0 -0 + Rename: libisc/error.c -> lib/isc/error.c + + lib/isc/include/isc/Makefile.am@1.9 +3 -8 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + lib/isc/include/isc/Makefile.am@1.8 +0 -0 + Rename: include/isc/Makefile.am -> lib/isc/include/isc/Makefile.am + + lib/isc/include/isc/app.h@1.3 +0 -0 + Rename: include/isc/app.h -> lib/isc/include/isc/app.h + + lib/isc/include/isc/assertions.h@1.3 +0 -0 + Rename: include/isc/assertions.h -> lib/isc/include/isc/assertions.h + + lib/isc/include/isc/boolean.h@1.3 +0 -0 + Rename: include/isc/boolean.h -> lib/isc/include/isc/boolean.h + + lib/isc/include/isc/buffer.h@1.3 +0 -0 + Rename: include/isc/buffer.h -> lib/isc/include/isc/buffer.h + + lib/isc/include/isc/error.h@1.3 +0 -0 + Rename: include/isc/error.h -> lib/isc/include/isc/error.h + + lib/isc/include/isc/file.h@1.3 +0 -0 + Rename: include/isc/file.h -> lib/isc/include/isc/file.h + + lib/isc/include/isc/formatcheck.h@1.3 +0 -0 + Rename: include/isc/formatcheck.h -> lib/isc/include/isc/formatcheck.h + + lib/isc/include/isc/interfaceiter.h@1.5 +0 -0 + Rename: include/isc/interfaceiter.h -> lib/isc/include/isc/interfaceiter.h + + lib/isc/include/isc/ipv6.h@1.8 +0 -0 + Rename: include/isc/ipv6.h -> lib/isc/include/isc/ipv6.h + + lib/isc/include/isc/lang.h@1.3 +0 -0 + Rename: include/isc/lang.h -> lib/isc/include/isc/lang.h + + lib/isc/include/isc/lib.h@1.3 +0 -0 + Rename: include/isc/lib.h -> lib/isc/include/isc/lib.h + + lib/isc/include/isc/list.h@1.3 +0 -0 + Rename: include/isc/list.h -> lib/isc/include/isc/list.h + + lib/isc/include/isc/log.h@1.2 +0 -0 + Rename: include/isc/log.h -> lib/isc/include/isc/log.h + + lib/isc/include/isc/magic.h@1.3 +0 -0 + Rename: include/isc/magic.h -> lib/isc/include/isc/magic.h + + lib/isc/include/isc/md5.h@1.2 +0 -0 + Rename: include/isc/md5.h -> lib/isc/include/isc/md5.h + + lib/isc/include/isc/mem.h@1.4 +0 -0 + Rename: include/isc/mem.h -> lib/isc/include/isc/mem.h + + lib/isc/include/isc/msgcat.h@1.3 +0 -0 + Rename: include/isc/msgcat.h -> lib/isc/include/isc/msgcat.h + + lib/isc/include/isc/msgs.h@1.4 +0 -0 + Rename: include/isc/msgs.h -> lib/isc/include/isc/msgs.h + + lib/isc/include/isc/mutex.h@1.3 +0 -0 + Rename: include/isc/mutex.h -> lib/isc/include/isc/mutex.h + + lib/isc/include/isc/netaddr.h@1.5 +0 -0 + Rename: include/isc/netaddr.h -> lib/isc/include/isc/netaddr.h + + lib/isc/include/isc/netscope.h@1.2 +0 -0 + Rename: include/isc/netscope.h -> lib/isc/include/isc/netscope.h + + lib/isc/include/isc/once.h@1.3 +0 -0 + Rename: include/isc/once.h -> lib/isc/include/isc/once.h + + lib/isc/include/isc/platform.h@1.3 +0 -0 + Rename: include/isc/platform.h -> lib/isc/include/isc/platform.h + + lib/isc/include/isc/print.h@1.3 +0 -0 + Rename: include/isc/print.h -> lib/isc/include/isc/print.h + + lib/isc/include/isc/region.h@1.2 +0 -0 + Rename: include/isc/region.h -> lib/isc/include/isc/region.h + + lib/isc/include/isc/result.h@1.4 +0 -0 + Rename: include/isc/result.h -> lib/isc/include/isc/result.h + + lib/isc/include/isc/sockaddr.h@1.4 +0 -0 + Rename: include/isc/sockaddr.h -> lib/isc/include/isc/sockaddr.h + + lib/isc/include/isc/stdio.h@1.2 +0 -0 + Rename: include/isc/stdio.h -> lib/isc/include/isc/stdio.h + + lib/isc/include/isc/string.h@1.3 +0 -0 + Rename: include/isc/string.h -> lib/isc/include/isc/string.h + + lib/isc/include/isc/types.h@1.3 +0 -0 + Rename: include/isc/types.h -> lib/isc/include/isc/types.h + + lib/isc/include/isc/util.h@1.3 +0 -0 + Rename: include/isc/util.h -> lib/isc/include/isc/util.h + + lib/isc/inet_aton.c@1.3 +0 -0 + Rename: libisc/inet_aton.c -> lib/isc/inet_aton.c + + lib/isc/inet_ntop.c@1.6 +0 -0 + Rename: libisc/inet_ntop.c -> lib/isc/inet_ntop.c + + lib/isc/inet_pton.c@1.3 +0 -0 + Rename: libisc/inet_pton.c -> lib/isc/inet_pton.c + + lib/isc/lib.c@1.3 +0 -0 + Rename: libisc/lib.c -> lib/isc/lib.c + + lib/isc/log.c@1.2 +0 -0 + Rename: libisc/log.c -> lib/isc/log.c + + lib/isc/md5.c@1.2 +0 -0 + Rename: libisc/md5.c -> lib/isc/md5.c + + lib/isc/mem.c@1.4 +0 -0 + Rename: libisc/mem.c -> lib/isc/mem.c + + lib/isc/netaddr.c@1.5 +0 -0 + Rename: libisc/netaddr.c -> lib/isc/netaddr.c + + lib/isc/netscope.c@1.2 +0 -0 + Rename: libisc/netscope.c -> lib/isc/netscope.c + + lib/isc/nls/msgcat.c@1.5 +0 -0 + Rename: lib/isc/msgcat.c -> lib/isc/nls/msgcat.c + + lib/isc/msgcat.c@1.4 +0 -0 + Rename: libisc/msgcat.c -> lib/isc/msgcat.c + + lib/isc/sockaddr.c@1.7 +0 -0 + Rename: libisc/sockaddr.c -> lib/isc/sockaddr.c + + lib/isc/unix/ifiter_getifaddrs.c@1.6 +0 -0 + Rename: libisc/ifiter_getifaddrs.c -> lib/isc/unix/ifiter_getifaddrs.c + + lib/isc/unix/ifiter_ioctl.c@1.26 +0 -0 + Rename: libisc/ifiter_ioctl.c -> lib/isc/unix/ifiter_ioctl.c + + lib/isc/unix/ifiter_sysctl.c@1.13 +0 -0 + Rename: libisc/ifiter_sysctl.c -> lib/isc/unix/ifiter_sysctl.c + + lib/isc/unix/include/isc/Makefile.am@1.1 +15 -0 + overlooked lib/isc/unix/include/isc + + lib/isc/unix/include/isc/Makefile.am@1.0 +0 -0 + + lib/isc/unix/include/isc/dir.h@1.2 +0 -0 + Rename: include/isc/dir.h -> lib/isc/unix/include/isc/dir.h + + lib/isc/unix/include/isc/int.h@1.3 +0 -0 + Rename: include/isc/int.h -> lib/isc/unix/include/isc/int.h + + lib/isc/unix/include/isc/net.h@1.9 +0 -0 + Rename: include/isc/net.h -> lib/isc/unix/include/isc/net.h + + lib/isc/unix/include/isc/offset.h@1.3 +0 -0 + Rename: include/isc/offset.h -> lib/isc/unix/include/isc/offset.h + + lib/isc/unix/include/isc/stat.h@1.2 +0 -0 + Rename: include/isc/stat.h -> lib/isc/unix/include/isc/stat.h + + lib/isc/unix/include/isc/strerror.h@1.3 +0 -0 + Rename: include/isc/strerror.h -> lib/isc/unix/include/isc/strerror.h + + lib/isc/unix/include/isc/time.h@1.2 +0 -0 + Rename: include/isc/time.h -> lib/isc/unix/include/isc/time.h + + lib/isc/unix/interfaceiter.c@1.16 +0 -0 + Rename: libisc/interfaceiter.c -> lib/isc/unix/interfaceiter.c + + lib/isc/unix/net.c@1.11 +0 -0 + Rename: libisc/net.c -> lib/isc/unix/net.c + + lib/isc/unix/strerror.c@1.4 +0 -0 + Rename: libisc/isc_strerror.c -> lib/isc/unix/strerror.c + + lib/isc/win32/include/isc/int.h@1.3 +0 -0 + Rename: ports/winnt/include/isc/int.h -> lib/isc/win32/include/isc/int.h + + lib/isc/win32/include/isc/ipv6.h@1.7 +0 -0 + Rename: ports/winnt/include/isc/ipv6.h -> lib/isc/win32/include/isc/ipv6.h + + lib/isc/win32/include/isc/mutex.h@1.3 +0 -0 + Rename: ports/winnt/include/isc/mutex.h -> lib/isc/win32/include/isc/mutex.h + + lib/isc/win32/include/isc/net.h@1.8 +0 -0 + Rename: ports/winnt/include/isc/net.h -> lib/isc/win32/include/isc/net.h + + lib/isc/win32/include/isc/offset.h@1.3 +0 -0 + Rename: ports/winnt/include/isc/offset.h -> lib/isc/win32/include/isc/offset.h + + lib/isc/win32/include/isc/once.h@1.3 +0 -0 + Rename: ports/winnt/include/isc/once.h -> lib/isc/win32/include/isc/once.h + + lib/isc/win32/include/isc/platform.h@1.4 +0 -0 + Rename: ports/winnt/include/isc/platform.h -> lib/isc/win32/include/isc/platform.h + + lib/isc/win32/include/isc/stat.h@1.2 +0 -0 + Rename: ports/winnt/include/isc/stat.h -> lib/isc/win32/include/isc/stat.h + + lib/isc/win32/include/isc/strerror.h@1.3 +0 -0 + Rename: ports/winnt/include/isc/strerror.h -> lib/isc/win32/include/isc/strerror.h + + lib/isc/win32/include/isc/win32os.h@1.3 +0 -0 + Rename: ports/winnt/include/isc/win32os.h -> lib/isc/win32/include/isc/win32os.h + + lib/isc/win32/interfaceiter.c@1.10.1.1 +0 -0 + Rename: ports/winnt/libisc/interfaceiter.c -> lib/isc/win32/interfaceiter.c + + lib/isc/win32/net.c@1.10 +0 -0 + Rename: ports/winnt/libisc/net.c -> lib/isc/win32/net.c + + lib/isc/win32/once.c@1.3 +0 -0 + Rename: ports/winnt/libisc/once.c -> lib/isc/win32/once.c + + lib/isc/win32/strerror.c@1.9 +0 -0 + Rename: ports/winnt/libisc/isc_strerror.c -> lib/isc/win32/strerror.c + + lib/isc/win32/win32os.c@1.3 +0 -0 + Rename: ports/winnt/libisc/win32os.c -> lib/isc/win32/win32os.c + + libntp/Makefile.am@1.44 +16 -9 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + libntp/bsd_strerror.c@1.5 +0 -0 + Rename: libntp/strerror.c -> libntp/bsd_strerror.c + + libparse/Makefile.am@1.13 +6 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpd/Makefile.am@1.68 +9 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpdate/Makefile.am@1.17 +5 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpdc/Makefile.am@1.40 +6 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpq/Makefile.am@1.34 +6 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ntpsnmpd/Makefile.am@1.8 +8 -2 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + parseutil/Makefile.am@1.8 +5 -1 + Reorganize our copy of libisc code to match BIND 9 tarball layout + + ports/winnt/vc6/libntp.dsp@1.42 +18 -18 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpd.dsp@1.38 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpdate.dsp@1.22 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpdc.dsp@1.25 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpkeygen.dsp@1.18 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vc6/ntpq.dsp@1.26 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/libntp.vcproj@1.3 +18 -18 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpd.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpdate.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpdc.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpkeygen.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2003/ntpq.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/libntp.vcproj@1.3 +18 -18 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpd.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpdate.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpdc.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpkeygen.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2005/ntpq.vcproj@1.3 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/libntp/libntp.vcproj@1.18 +18 -36 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.7 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.18 +12 -12 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.10 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.10 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.9 +2 -2 + out with ports/winnt/include/isc and include/isc, in with + lib/isc/include/win32/isc and lib/isc/include/isc + + sntp/Makefile.am@1.11 +7 -3 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + + util/Makefile.am@1.39 +6 -1 + out with include/isc, in with lib/isc/include/isc and + lib/isc/unix/include/isc + +ChangeSet@1.2005, 2009-09-22 19:22:09+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1315] "interface ignore 0.0.0.0" is ignored. + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + add wildcard match class for interface/nic rules. + fix mistaken carryover of prefixlen from one rule to the next. + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + ChangeLog@1.444 +8 -0 + [Bug 1315] "interface ignore 0.0.0.0" is ignored. + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + add wildcard match class for interface/nic rules. + fix mistaken carryover of prefixlen from one rule to the next. + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + include/ntp_io.h@1.12 +4 -2 + add wildcard match class for interface/nic rules. + add sau_from_netaddr() prototype + + ntpd/ntp_config.c@1.220 +26 -9 + fix mistaken carryover of prefixlen from one rule to the next. + add wildcard match class for interface/nic rules. + + ntpd/ntp_io.c@1.298 +193 -76 + [Bug 1315] "interface ignore 0.0.0.0" is ignored. + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + add wildcard match class for interface/nic rules. + + + ntpd/ntp_parser.c@1.49 +595 -595 + Bison product + + ntpd/ntp_parser.h@1.30 +33 -31 + Bison product + + ntpd/ntp_parser.y@1.44 +2 -0 + add wildcard match class for interface/nic rules. + + ntpd/ntp_scanner.c@1.27 +18 -9 + add wildcard match class for interface/nic rules. + better fix for Sunday's change to close-double-quote handling. + + ntpd/ntp_scanner.h@1.11 +4 -0 + FOLLBY_TOKEN/FOLLBY_STRING use clarification comment + + ntpd/ntpd.c@1.108 +0 -6 + add implicit "nic ignore all" rule before any rules from ntp.conf, so + "nic listen eth0" alone means the same as "-I eth0". + + ntpdc/ntpdc.c@1.70 +0 -8 + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + ntpq/ntpq.c@1.91 +0 -8 + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + + ports/winnt/libisc/interfaceiter.c@1.11 +72 -11 + Ensure IPv6 localhost address ::1 is included in libisc's Windows IPv6 + address enumeration, allowing ntpq and ntpdc's hardcoding to 127.0.0.1 + on Windows to end. + +ChangeSet@1.2004, 2009-09-21 07:51:38-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P218 + TAG: NTP_4_2_5P218 + + ChangeLog@1.443 +1 -0 + NTP_4_2_5P218 + + ntpd/ntpd-opts.c@1.211 +2 -2 + NTP_4_2_5P218 + + ntpd/ntpd-opts.h@1.211 +3 -3 + NTP_4_2_5P218 + + ntpd/ntpd-opts.texi@1.209 +1 -1 + NTP_4_2_5P218 + + ntpd/ntpd.1@1.209 +2 -2 + NTP_4_2_5P218 + + ntpdc/ntpdc-opts.c@1.207 +2 -2 + NTP_4_2_5P218 + + ntpdc/ntpdc-opts.h@1.207 +3 -3 + NTP_4_2_5P218 + + ntpdc/ntpdc-opts.texi@1.206 +1 -1 + NTP_4_2_5P218 + + ntpdc/ntpdc.1@1.206 +2 -2 + NTP_4_2_5P218 + + ntpq/ntpq-opts.c@1.207 +2 -2 + NTP_4_2_5P218 + + ntpq/ntpq-opts.h@1.207 +3 -3 + NTP_4_2_5P218 + + ntpq/ntpq-opts.texi@1.206 +1 -1 + NTP_4_2_5P218 + + ntpq/ntpq.1@1.206 +2 -2 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd-opts.c@1.87 +2 -2 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd-opts.h@1.87 +3 -3 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd-opts.texi@1.87 +1 -1 + NTP_4_2_5P218 + + ntpsnmpd/ntpsnmpd.1@1.87 +2 -2 + NTP_4_2_5P218 + + packageinfo.sh@1.221 +1 -1 + NTP_4_2_5P218 + + sntp/sntp-opts.c@1.81 +2 -2 + NTP_4_2_5P218 + + sntp/sntp-opts.h@1.81 +3 -3 + NTP_4_2_5P218 + + sntp/sntp-opts.texi@1.81 +1 -1 + NTP_4_2_5P218 + + sntp/sntp.1@1.81 +2 -2 + NTP_4_2_5P218 + + util/ntp-keygen-opts.c@1.210 +2 -2 + NTP_4_2_5P218 + + util/ntp-keygen-opts.h@1.210 +3 -3 + NTP_4_2_5P218 + + util/ntp-keygen-opts.texi@1.209 +1 -1 + NTP_4_2_5P218 + + util/ntp-keygen.1@1.209 +2 -2 + NTP_4_2_5P218 + +ChangeSet@1.2003, 2009-09-21 04:57:32+00:00, davehart@shiny.ad.hartbrothers.com + correct parsing and processing of setvar directive. + highlight location of ntpq :config syntax errors with ^. + + ChangeLog@1.442 +2 -0 + correct parsing and processing of setvar directive. + highlight location of ntpq :config syntax errors with ^. + + include/ntp_config.h@1.63 +2 -1 + correct parsing and processing of setvar directive. + + ntpd/ntp_config.c@1.219 +62 -55 + correct parsing and processing of setvar directive. + + ntpd/ntp_scanner.c@1.26 +35 -5 + correct parsing and processing of setvar directive. + + ntpd/ntp_scanner.h@1.10 +7 -6 + correct parsing and processing of setvar directive. + + ntpq/ntpq-subs.c@1.37 +25 -9 + highlight location of ntpq :config syntax errors with ^. + + ntpq/ntpq.h@1.8 +2 -0 + expose interactive variable to ntpq-subs.c + +ChangeSet@1.2000.1.1, 2009-09-21 00:10:58+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1314] saveconfig emits -4 and -6 on when not given. + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + ChangeLog@1.439.1.1 +4 -0 + [Bug 1314] saveconfig emits -4 and -6 on when not given. + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + include/ntp_config.h@1.62 +8 -9 + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + ntpd/ntp_config.c@1.218 +612 -947 + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + move scanner's keyword table from ntp_config.c to ntp_scanner.c + + ntpd/ntp_parser.c@1.48 +275 -466 + Bison product + + ntpd/ntp_parser.h@1.29 +3 -3 + Bison output + + ntpd/ntp_parser.y@1.43 +100 -96 + parser, saveconfig cleanup to store T_ identifiers in syntax tree. + + ntpd/ntp_scanner.c@1.25 +269 -64 + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + move scanner's keyword table from ntp_config.c to ntp_scanner.c + + ntpd/ntp_scanner.h@1.9 +25 -9 + clarify (former) NO_ARG, SINGLE_ARG, MULTIPLE_ARG renaming to + FOLLBY_TOKEN, FOLLBY_STRING, FOLLBY_STRINGS_TO_EOC. + +ChangeSet@1.2001, 2009-09-20 07:51:55-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P217 + TAG: NTP_4_2_5P217 + + ChangeLog@1.440 +1 -0 + NTP_4_2_5P217 + + ntpd/ntpd-opts.c@1.210 +2 -2 + NTP_4_2_5P217 + + ntpd/ntpd-opts.h@1.210 +3 -3 + NTP_4_2_5P217 + + ntpd/ntpd-opts.texi@1.208 +1 -1 + NTP_4_2_5P217 + + ntpd/ntpd.1@1.208 +2 -2 + NTP_4_2_5P217 + + ntpdc/ntpdc-opts.c@1.206 +2 -2 + NTP_4_2_5P217 + + ntpdc/ntpdc-opts.h@1.206 +3 -3 + NTP_4_2_5P217 + + ntpdc/ntpdc-opts.texi@1.205 +1 -1 + NTP_4_2_5P217 + + ntpdc/ntpdc.1@1.205 +2 -2 + NTP_4_2_5P217 + + ntpq/ntpq-opts.c@1.206 +2 -2 + NTP_4_2_5P217 + + ntpq/ntpq-opts.h@1.206 +3 -3 + NTP_4_2_5P217 + + ntpq/ntpq-opts.texi@1.205 +1 -1 + NTP_4_2_5P217 + + ntpq/ntpq.1@1.205 +2 -2 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd-opts.c@1.86 +2 -2 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd-opts.h@1.86 +3 -3 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd-opts.texi@1.86 +1 -1 + NTP_4_2_5P217 + + ntpsnmpd/ntpsnmpd.1@1.86 +2 -2 + NTP_4_2_5P217 + + packageinfo.sh@1.220 +1 -1 + NTP_4_2_5P217 + + sntp/sntp-opts.c@1.80 +2 -2 + NTP_4_2_5P217 + + sntp/sntp-opts.h@1.80 +3 -3 + NTP_4_2_5P217 + + sntp/sntp-opts.texi@1.80 +1 -1 + NTP_4_2_5P217 + + sntp/sntp.1@1.80 +2 -2 + NTP_4_2_5P217 + + util/ntp-keygen-opts.c@1.209 +2 -2 + NTP_4_2_5P217 + + util/ntp-keygen-opts.h@1.209 +3 -3 + NTP_4_2_5P217 + + util/ntp-keygen-opts.texi@1.208 +1 -1 + NTP_4_2_5P217 + + util/ntp-keygen.1@1.208 +2 -2 + NTP_4_2_5P217 + +ChangeSet@1.2000, 2009-09-19 16:52:44+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1300] reject remote configuration of dangerous items. + + ChangeLog@1.439 +1 -0 + [Bug 1300] reject remote configuration of dangerous items. + + include/ntpd.h@1.134 +1 -0 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/ntp_config.c@1.217 +43 -10 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/ntp_control.c@1.123 +61 -74 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/ntp_parser.c@1.47 +838 -743 + Bison output + + ntpd/ntp_parser.h@1.28 +87 -85 + Bison output + + ntpd/ntp_parser.y@1.42 +106 -17 + [Bug 1300] reject remote configuration of dangerous items. + + ntpd/refclock_palisade.c@1.31 +2 -5 + un-revert another earlier fix (no need for Windows-specific COM%d:) + + ntpq/ntpq-subs.c@1.36 +19 -15 + trim one trailing newline from :config response + +ChangeSet@1.1999, 2009-09-19 07:53:27-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P216 + TAG: NTP_4_2_5P216 + + ChangeLog@1.438 +1 -0 + NTP_4_2_5P216 + + ntpd/ntpd-opts.c@1.209 +2 -2 + NTP_4_2_5P216 + + ntpd/ntpd-opts.h@1.209 +3 -3 + NTP_4_2_5P216 + + ntpd/ntpd-opts.texi@1.207 +1 -1 + NTP_4_2_5P216 + + ntpd/ntpd.1@1.207 +2 -2 + NTP_4_2_5P216 + + ntpdc/ntpdc-opts.c@1.205 +2 -2 + NTP_4_2_5P216 + + ntpdc/ntpdc-opts.h@1.205 +3 -3 + NTP_4_2_5P216 + + ntpdc/ntpdc-opts.texi@1.204 +1 -1 + NTP_4_2_5P216 + + ntpdc/ntpdc.1@1.204 +2 -2 + NTP_4_2_5P216 + + ntpq/ntpq-opts.c@1.205 +2 -2 + NTP_4_2_5P216 + + ntpq/ntpq-opts.h@1.205 +3 -3 + NTP_4_2_5P216 + + ntpq/ntpq-opts.texi@1.204 +1 -1 + NTP_4_2_5P216 + + ntpq/ntpq.1@1.204 +2 -2 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd-opts.c@1.85 +2 -2 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd-opts.h@1.85 +3 -3 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd-opts.texi@1.85 +1 -1 + NTP_4_2_5P216 + + ntpsnmpd/ntpsnmpd.1@1.85 +2 -2 + NTP_4_2_5P216 + + packageinfo.sh@1.219 +1 -1 + NTP_4_2_5P216 + + sntp/sntp-opts.c@1.79 +2 -2 + NTP_4_2_5P216 + + sntp/sntp-opts.h@1.79 +3 -3 + NTP_4_2_5P216 + + sntp/sntp-opts.texi@1.79 +1 -1 + NTP_4_2_5P216 + + sntp/sntp.1@1.79 +2 -2 + NTP_4_2_5P216 + + util/ntp-keygen-opts.c@1.208 +2 -2 + NTP_4_2_5P216 + + util/ntp-keygen-opts.h@1.208 +3 -3 + NTP_4_2_5P216 + + util/ntp-keygen-opts.texi@1.207 +1 -1 + NTP_4_2_5P216 + + util/ntp-keygen.1@1.207 +2 -2 + NTP_4_2_5P216 + +ChangeSet@1.1998, 2009-09-19 06:21:08+00:00, davehart@shiny.ad.hartbrothers.com + CID 10 missing free(up); in refclock_palisade.c error return, again. + CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). + + ChangeLog@1.437 +3 -0 + CID 10 missing free(up); in refclock_palisade.c error return, again. + CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). + + ntpd/ntp_config.c@1.216 +1 -0 + CID 83 added assertion to demonstrate config_nic_rules() does not + call strchr(NULL, '/'). + + ntpd/refclock_palisade.c@1.30 +3 -9 + CID 10 missing free(up); in refclock_palisade.c error return, again. + +ChangeSet@1.1997, 2009-09-19 02:18:44+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + + ChangeLog@1.436 +1 -0 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + + configure.ac@1.454 +16 -0 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + + include/ntp_stdlib.h@1.32 +4 -3 + make #include "ntp_stdlib.h" all that's needed to use msyslog() by + including ntp_syslog.h from ntp_stdlib.h + + ntpdc/ntpdc.c@1.69 +12 -4 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + Clean up authenticated request codepath. + + ntpq/ntpq.c@1.90 +13 -17 + [Bug 1312] ntpq/ntpdc MD5 passwords truncated to 8 chars on Suns. + Clean up authenticated request codepath. + Remove unneeded SYS_WINNT libntp workarounds from last century. + +ChangeSet@1.1996, 2009-09-18 07:51:03-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P215 + TAG: NTP_4_2_5P215 + + ChangeLog@1.435 +1 -0 + NTP_4_2_5P215 + + ntpd/ntpd-opts.c@1.208 +2 -2 + NTP_4_2_5P215 + + ntpd/ntpd-opts.h@1.208 +3 -3 + NTP_4_2_5P215 + + ntpd/ntpd-opts.texi@1.206 +1 -1 + NTP_4_2_5P215 + + ntpd/ntpd.1@1.206 +2 -2 + NTP_4_2_5P215 + + ntpdc/ntpdc-opts.c@1.204 +2 -2 + NTP_4_2_5P215 + + ntpdc/ntpdc-opts.h@1.204 +3 -3 + NTP_4_2_5P215 + + ntpdc/ntpdc-opts.texi@1.203 +1 -1 + NTP_4_2_5P215 + + ntpdc/ntpdc.1@1.203 +2 -2 + NTP_4_2_5P215 + + ntpq/ntpq-opts.c@1.204 +2 -2 + NTP_4_2_5P215 + + ntpq/ntpq-opts.h@1.204 +3 -3 + NTP_4_2_5P215 + + ntpq/ntpq-opts.texi@1.203 +1 -1 + NTP_4_2_5P215 + + ntpq/ntpq.1@1.203 +2 -2 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd-opts.c@1.84 +2 -2 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd-opts.h@1.84 +3 -3 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd-opts.texi@1.84 +1 -1 + NTP_4_2_5P215 + + ntpsnmpd/ntpsnmpd.1@1.84 +2 -2 + NTP_4_2_5P215 + + packageinfo.sh@1.218 +1 -1 + NTP_4_2_5P215 + + sntp/sntp-opts.c@1.78 +2 -2 + NTP_4_2_5P215 + + sntp/sntp-opts.h@1.78 +3 -3 + NTP_4_2_5P215 + + sntp/sntp-opts.texi@1.78 +1 -1 + NTP_4_2_5P215 + + sntp/sntp.1@1.78 +2 -2 + NTP_4_2_5P215 + + util/ntp-keygen-opts.c@1.207 +2 -2 + NTP_4_2_5P215 + + util/ntp-keygen-opts.h@1.207 +3 -3 + NTP_4_2_5P215 + + util/ntp-keygen-opts.texi@1.206 +1 -1 + NTP_4_2_5P215 + + util/ntp-keygen.1@1.206 +2 -2 + NTP_4_2_5P215 + +ChangeSet@1.1995, 2009-09-17 23:25:59-04:00, stenn@pogo.udel.edu + [Bug 1292] Workaround last VC6 unsigned __int64 kink + + ChangeLog@1.434 +1 -0 + [Bug 1292] Workaround last VC6 unsigned __int64 kink + +ChangeSet@1.1994, 2009-09-17 15:28:57+02:00, burnicki@pogo.udel.edu + [Bug 1292] Workaround last VC6 unsigned __int64 kink. + + ports/winnt/ntpd/nt_clockstuff.c@1.36 +1 -1 + [Bug 1292] Workaround last VC6 unsigned __int64 kink. + +ChangeSet@1.1993, 2009-09-17 07:55:35-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P214 + TAG: NTP_4_2_5P214 + + ChangeLog@1.433 +1 -0 + NTP_4_2_5P214 + + ntpd/ntpd-opts.c@1.207 +2 -2 + NTP_4_2_5P214 + + ntpd/ntpd-opts.h@1.207 +3 -3 + NTP_4_2_5P214 + + ntpd/ntpd-opts.texi@1.205 +1 -1 + NTP_4_2_5P214 + + ntpd/ntpd.1@1.205 +2 -2 + NTP_4_2_5P214 + + ntpdc/ntpdc-opts.c@1.203 +2 -2 + NTP_4_2_5P214 + + ntpdc/ntpdc-opts.h@1.203 +3 -3 + NTP_4_2_5P214 + + ntpdc/ntpdc-opts.texi@1.202 +1 -1 + NTP_4_2_5P214 + + ntpdc/ntpdc.1@1.202 +2 -2 + NTP_4_2_5P214 + + ntpq/ntpq-opts.c@1.203 +2 -2 + NTP_4_2_5P214 + + ntpq/ntpq-opts.h@1.203 +3 -3 + NTP_4_2_5P214 + + ntpq/ntpq-opts.texi@1.202 +1 -1 + NTP_4_2_5P214 + + ntpq/ntpq.1@1.202 +2 -2 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd-opts.c@1.83 +2 -2 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd-opts.h@1.83 +3 -3 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd-opts.texi@1.83 +1 -1 + NTP_4_2_5P214 + + ntpsnmpd/ntpsnmpd.1@1.83 +2 -2 + NTP_4_2_5P214 + + packageinfo.sh@1.217 +1 -1 + NTP_4_2_5P214 + + sntp/sntp-opts.c@1.77 +2 -2 + NTP_4_2_5P214 + + sntp/sntp-opts.h@1.77 +3 -3 + NTP_4_2_5P214 + + sntp/sntp-opts.texi@1.77 +1 -1 + NTP_4_2_5P214 + + sntp/sntp.1@1.77 +2 -2 + NTP_4_2_5P214 + + util/ntp-keygen-opts.c@1.206 +2 -2 + NTP_4_2_5P214 + + util/ntp-keygen-opts.h@1.206 +3 -3 + NTP_4_2_5P214 + + util/ntp-keygen-opts.texi@1.205 +1 -1 + NTP_4_2_5P214 + + util/ntp-keygen.1@1.205 +2 -2 + NTP_4_2_5P214 + +ChangeSet@1.1992, 2009-09-17 01:31:14+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1303] remove top-level "autokey" directive. + correct "checking" message for --disable-bug1243-fix. + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16" + + ChangeLog@1.432 +3 -0 + [Bug 1303] remove top-level "autokey" directive. + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + configure.ac@1.453 +1 -1 + correct "checking" message for --disable-bug1243-fix. + + html/miscopt.html@1.48 +2 -2 + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + include/ntp_config.h@1.61 +1 -3 + [Bug 1303] remove top-level "autokey" directive. + + ntpd/ntp_config.c@1.215 +28 -10 + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + ntpd/ntp_parser.c@1.46 +758 -789 + Bison output + + ntpd/ntp_parser.h@1.27 +103 -105 + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + + ntpd/ntp_parser.y@1.41 +4 -12 + [Bug 1303] remove top-level "autokey" directive. + use "nic listen 192.168.0.0/16" instead of + "nic listen 192.168.0.0 prefixlen 16". + +ChangeSet@1.1991, 2009-09-16 07:51:15-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P213 + TAG: NTP_4_2_5P213 + + ChangeLog@1.431 +1 -0 + NTP_4_2_5P213 + + ntpd/ntpd-opts.c@1.206 +2 -2 + NTP_4_2_5P213 + + ntpd/ntpd-opts.h@1.206 +3 -3 + NTP_4_2_5P213 + + ntpd/ntpd-opts.texi@1.204 +1 -1 + NTP_4_2_5P213 + + ntpd/ntpd.1@1.204 +2 -2 + NTP_4_2_5P213 + + ntpdc/ntpdc-opts.c@1.202 +2 -2 + NTP_4_2_5P213 + + ntpdc/ntpdc-opts.h@1.202 +3 -3 + NTP_4_2_5P213 + + ntpdc/ntpdc-opts.texi@1.201 +1 -1 + NTP_4_2_5P213 + + ntpdc/ntpdc.1@1.201 +2 -2 + NTP_4_2_5P213 + + ntpq/ntpq-opts.c@1.202 +2 -2 + NTP_4_2_5P213 + + ntpq/ntpq-opts.h@1.202 +3 -3 + NTP_4_2_5P213 + + ntpq/ntpq-opts.texi@1.201 +1 -1 + NTP_4_2_5P213 + + ntpq/ntpq.1@1.201 +2 -2 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd-opts.c@1.82 +2 -2 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd-opts.h@1.82 +3 -3 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd-opts.texi@1.82 +1 -1 + NTP_4_2_5P213 + + ntpsnmpd/ntpsnmpd.1@1.82 +2 -2 + NTP_4_2_5P213 + + packageinfo.sh@1.216 +1 -1 + NTP_4_2_5P213 + + sntp/sntp-opts.c@1.76 +2 -2 + NTP_4_2_5P213 + + sntp/sntp-opts.h@1.76 +3 -3 + NTP_4_2_5P213 + + sntp/sntp-opts.texi@1.76 +1 -1 + NTP_4_2_5P213 + + sntp/sntp.1@1.76 +2 -2 + NTP_4_2_5P213 + + util/ntp-keygen-opts.c@1.205 +2 -2 + NTP_4_2_5P213 + + util/ntp-keygen-opts.h@1.205 +3 -3 + NTP_4_2_5P213 + + util/ntp-keygen-opts.texi@1.204 +1 -1 + NTP_4_2_5P213 + + util/ntp-keygen.1@1.204 +2 -2 + NTP_4_2_5P213 + +ChangeSet@1.1988.1.1, 2009-09-15 13:08:48-04:00, murray@pogo.udel.edu + refclock_palisade.c, ChangeLog: + Fix for bug 1310 + + ChangeLog@1.428.1.1 +1 -0 + Fix for bug 1310 + + ntpd/refclock_palisade.c@1.29 +12 -9 + Fix for bug 1310 + +ChangeSet@1.1989, 2009-09-15 07:57:12-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P212 + TAG: NTP_4_2_5P212 + + ChangeLog@1.429 +1 -0 + NTP_4_2_5P212 + + ntpd/ntpd-opts.c@1.205 +2 -2 + NTP_4_2_5P212 + + ntpd/ntpd-opts.h@1.205 +3 -3 + NTP_4_2_5P212 + + ntpd/ntpd-opts.texi@1.203 +1 -1 + NTP_4_2_5P212 + + ntpd/ntpd.1@1.203 +2 -2 + NTP_4_2_5P212 + + ntpdc/ntpdc-opts.c@1.201 +2 -2 + NTP_4_2_5P212 + + ntpdc/ntpdc-opts.h@1.201 +3 -3 + NTP_4_2_5P212 + + ntpdc/ntpdc-opts.texi@1.200 +1 -1 + NTP_4_2_5P212 + + ntpdc/ntpdc.1@1.200 +2 -2 + NTP_4_2_5P212 + + ntpq/ntpq-opts.c@1.201 +2 -2 + NTP_4_2_5P212 + + ntpq/ntpq-opts.h@1.201 +3 -3 + NTP_4_2_5P212 + + ntpq/ntpq-opts.texi@1.200 +1 -1 + NTP_4_2_5P212 + + ntpq/ntpq.1@1.200 +2 -2 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd-opts.c@1.81 +2 -2 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd-opts.h@1.81 +3 -3 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd-opts.texi@1.81 +1 -1 + NTP_4_2_5P212 + + ntpsnmpd/ntpsnmpd.1@1.81 +2 -2 + NTP_4_2_5P212 + + packageinfo.sh@1.215 +1 -1 + NTP_4_2_5P212 + + sntp/sntp-opts.c@1.75 +2 -2 + NTP_4_2_5P212 + + sntp/sntp-opts.h@1.75 +3 -3 + NTP_4_2_5P212 + + sntp/sntp-opts.texi@1.75 +1 -1 + NTP_4_2_5P212 + + sntp/sntp.1@1.75 +2 -2 + NTP_4_2_5P212 + + util/ntp-keygen-opts.c@1.204 +2 -2 + NTP_4_2_5P212 + + util/ntp-keygen-opts.h@1.204 +3 -3 + NTP_4_2_5P212 + + util/ntp-keygen-opts.texi@1.203 +1 -1 + NTP_4_2_5P212 + + util/ntp-keygen.1@1.203 +2 -2 + NTP_4_2_5P212 + +ChangeSet@1.1988, 2009-09-15 03:49:51-04:00, stenn@whimsy.udel.edu + Typo cleanup + + ChangeLog@1.428 +1 -2 + Typo cleanup + +ChangeSet@1.1987, 2009-09-15 07:25:11+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. + + ChangeLog@1.427 +3 -1 + [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. + + ntpd/refclock_palisade.c@1.28 +73 -68 + [Bug 1311] 4.2.5p211 doesn't build in no-debug mode. + convert leading whitespace to tabs + + ntpd/refclock_palisade.h@1.13 +12 -10 + convert leading whitespace to tabs + +ChangeSet@1.1984.1.3, 2009-09-15 02:21:46-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.421.2.6 +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.51 +2 -2 + Documentation updates from Dave Mills + + html/miscopt.html@1.43.1.1 +2 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1984.1.2, 2009-09-15 01:28:52-04:00, stenn@whimsy.udel.edu + Make the code agree with the spec and the book (Dave Mills) + + ChangeLog@1.421.2.5 +1 -0 + Make the code agree with the spec and the book (Dave Mills) + + include/ntp.h@1.163 +1 -1 + Make the code agree with the spec and the book (Dave Mills) + + libntp/systime.c@1.48 +24 -19 + Make the code agree with the spec and the book (Dave Mills) + + ntpd/ntp_proto.c@1.293 +22 -29 + Make the code agree with the spec and the book (Dave Mills) + + ntpd/ntp_timer.c@1.55 +1 -1 + Make the code agree with the spec and the book (Dave Mills) + +ChangeSet@1.1984.1.1, 2009-09-14 07:52:01-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P211 + TAG: NTP_4_2_5P211 + + ChangeLog@1.421.2.4 +1 -0 + NTP_4_2_5P211 + + ntpd/ntpd-opts.c@1.204 +2 -2 + NTP_4_2_5P211 + + ntpd/ntpd-opts.h@1.204 +3 -3 + NTP_4_2_5P211 + + ntpd/ntpd-opts.texi@1.202 +2 -2 + NTP_4_2_5P211 + + ntpd/ntpd.1@1.202 +2 -2 + NTP_4_2_5P211 + + ntpdc/ntpdc-opts.c@1.200 +2 -2 + NTP_4_2_5P211 + + ntpdc/ntpdc-opts.h@1.200 +3 -3 + NTP_4_2_5P211 + + ntpdc/ntpdc-opts.texi@1.199 +2 -2 + NTP_4_2_5P211 + + ntpdc/ntpdc.1@1.199 +2 -2 + NTP_4_2_5P211 + + ntpq/ntpq-opts.c@1.200 +12 -6 + NTP_4_2_5P211 + + ntpq/ntpq-opts.h@1.200 +3 -3 + NTP_4_2_5P211 + + ntpq/ntpq-opts.texi@1.199 +2 -2 + NTP_4_2_5P211 + + ntpq/ntpq.1@1.199 +2 -2 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd-opts.c@1.80 +2 -2 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd-opts.h@1.80 +3 -3 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd-opts.texi@1.80 +1 -1 + NTP_4_2_5P211 + + ntpsnmpd/ntpsnmpd.1@1.80 +2 -2 + NTP_4_2_5P211 + + packageinfo.sh@1.214 +1 -1 + NTP_4_2_5P211 + + sntp/sntp-opts.c@1.74 +2 -2 + NTP_4_2_5P211 + + sntp/sntp-opts.h@1.74 +3 -3 + NTP_4_2_5P211 + + sntp/sntp-opts.texi@1.74 +51 -2 + NTP_4_2_5P211 + + sntp/sntp.1@1.74 +2 -2 + NTP_4_2_5P211 + + util/ntp-keygen-opts.c@1.203 +2 -2 + NTP_4_2_5P211 + + util/ntp-keygen-opts.h@1.203 +3 -3 + NTP_4_2_5P211 + + util/ntp-keygen-opts.texi@1.202 +3 -3 + NTP_4_2_5P211 + + util/ntp-keygen.1@1.202 +2 -2 + NTP_4_2_5P211 + +ChangeSet@1.1983, 2009-09-14 03:30:37-04:00, stenn@pogo.udel.edu + [Bug 1296] Added Support for Trimble Acutime Gold + + ChangeLog@1.421.4.1 +1 -0 + [Bug 1296] Added Support for Trimble Acutime Gold + +ChangeSet@1.1981.4.1, 2009-09-12 11:54:54+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1292] more VC6 unsigned __int64 workarounds. + + ChangeLog@1.421.3.1 +1 -0 + [Bug 1292] more VC6 unsigned __int64 workarounds. + + ports/winnt/ntpd/nt_clockstuff.c@1.35 +11 -4 + [Bug 1292] more VC6 unsigned __int64 workarounds. + +ChangeSet@1.1981.3.1, 2009-09-12 07:25:45+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 663] respect ntpq -c and -p order on command line. + + ChangeLog@1.421.2.1 +1 -0 + [Bug 663] respect ntpq -c and -p order on command line. + + ntpq/ntpq-opts.def@1.13 +2 -1 + [Bug 663] respect ntpq -c and -p order on command line. + + ntpq/ntpq.c@1.89 +37 -13 + [Bug 663] respect ntpq -c and -p order on command line. + +ChangeSet@1.1981.2.1, 2009-09-11 06:55:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. + [Bug 1295] leftover fix, do not crash on exit in free_config_trap() + when "trap 1.2.3.4" is used without any further options. + CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths. + CID 80: attempt to quiet Coverity false positive re: leaking "reason" + in main(). + CID 81: savedconfig leaked in save_config(). + + ChangeLog@1.421.1.1 +7 -0 + [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. + [Bug 1295] leftover fix, do not crash on exit in free_config_trap() + when "trap 1.2.3.4" is used without any further options. + CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths. + CID 80: attempt to quiet Coverity false positive re: leaking "reason" + in main(). + CID 81: savedconfig leaked in save_config(). + + configure.ac@1.450.1.1 +20 -0 + add support for --disable-bug1243-fix + + include/ntpd.h@1.131.1.1 +12 -0 + add framework from "enable bc_bug1243" under #ifdef for future use + + libntp/authkeys.c@1.14 +18 -16 + [Bug 1243] MD5auth_setkey zero-fills key from first zero octet. + + ntpd/ntp_config.c@1.211.1.1 +122 -84 + add framework from "enable bc_bug1243" under #ifdef for future use. + [Bug 1295] leftover fix, do not crash on exit in free_config_trap() when + "trap 1.2.3.4" is used without any further options. + + ntpd/ntp_control.c@1.120.1.1 +2 -2 + CID 81: savedconfig leaked in save_config() + + ntpd/ntp_parser.c@1.42.1.1 +207 -210 + Bison product + + ntpd/ntp_parser.y@1.37.1.1 +11 -15 + do not crash applying "crypto" command with no options. + add framework from "enable bc_bug1243" under #ifdef for future use. + + sntp/kod_management.c@1.13 +6 -2 + CID 79: kod_init_kod_db() fails to fclose(db_s) in two error paths + CID 80: attempt to quiet Coverity false positive re: leaking + "reason" in main() + +ChangeSet@1.1981.1.3, 2009-09-10 20:12:31+00:00, davehart@shiny.ad.hartbrothers.com + pick up Dr. Mills' miscopt.html leapfile indent correction from 8-Sep + + html/miscopt.html@1.46 +2 -2 + pick up Dr. Mills' leapfile indent correction from 8-Sep + +ChangeSet@1.1981.1.2, 2009-09-10 04:31:45+00:00, davehart@shiny.ad.hartbrothers.com + switch to verb then object order, "nic listen all", "interface drop eth0" + Correct syntax error line & column numbers. + + ChangeLog@1.423 +2 -1 + switch to verb then object order, "nic listen all", "interface drop eth0" + Correct syntax error line & column numbers. + + html/miscopt.html@1.45 +2 -2 + switch to verb then object order, "nic listen all", "interface drop eth0" + + ntpd/ntp_config.c@1.213 +27 -21 + switch to verb then object order, "nic listen all", "interface drop eth0" + + ntpd/ntp_control.c@1.121 +4 -8 + pass parser error message on to ntpq :config/config-from-file + + ntpd/ntp_parser.c@1.44 +338 -346 + Bison product + + ntpd/ntp_parser.y@1.39 +22 -30 + switch to verb then object order, "nic listen all", "interface drop eth0" + + ntpd/ntp_scanner.c@1.24 +23 -4 + get syntax error position right in more cases + + ntpd/ntp_scanner.h@1.8 +4 -0 + get syntax error position right in more cases + +ChangeSet@1.1981.1.1, 2009-09-09 16:58:54+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 983] add interface ... [listen | ignore | drop] directive. + document interface (alias nic) and unpeer + make sure accessing ip_file->line_no is safe for :config + + ChangeLog@1.422 +2 -0 + [Bug 983] add interface ... [listen | ignore | drop] directive. + document interface (alias nic) and unpeer + + configure.ac@1.451 +0 -17 + remove --disable-listen-read-drop + + html/confopt.html@1.46 +10 -4 + document unpeer ntp.conf/ntpq :config directive + + html/copyright.html@1.43 +2 -1 + add Dave Hart, fix @@ typo for John Hay + + html/miscopt.html@1.44 +2 -0 + document interface ... [listen | ignore | drop] + + html/scripts/confopt.txt@1.2 +1 -0 + add unpeer + + html/scripts/miscopt.txt@1.2 +2 -0 + add interface and alias nic + + include/ntp_config.h@1.60 +25 -7 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + include/ntp_io.h@1.11 +26 -3 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + include/ntpd.h@1.132 +1 -0 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + ntpd/ntp_config.c@1.212 +224 -31 + [Bug 983] add interface ... [listen | ignore | drop] directive. + make sure accessing ipfile->line_no and similar is safe during + runtime configuration + + ntpd/ntp_io.c@1.297 +193 -132 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + ntpd/ntp_parser.c@1.43 +1055 -984 + Bison output + + ntpd/ntp_parser.h@1.26 +321 -307 + Bison output + + ntpd/ntp_parser.y@1.38 +53 -4 + [Bug 983] add interface ... [listen | ignore | drop] directive. + + ntpd/ntpd.c@1.107 +16 -3 + [Bug 983] add interface ... [listen | ignore | drop] directive. + +ChangeSet@1.1982, 2009-09-06 12:00:45-04:00, fernandoph@pogo.udel.edu + refclock_palisade.c, refclock_palisade.h: + [BUG 1296] Added Support for Trimble Acutime Gold. + + ntpd/refclock_palisade.c@1.27 +131 -23 + [BUG 1296] Added Support for Trimble Acutime Gold. + + ntpd/refclock_palisade.h@1.12 +6 -4 + [BUG 1296] Added Support for Trimble Acutime Gold. + +ChangeSet@1.1981, 2009-09-06 07:51:31-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P210 + TAG: NTP_4_2_5P210 + + ChangeLog@1.421 +1 -0 + NTP_4_2_5P210 + + ntpd/ntpd-opts.c@1.203 +2 -2 + NTP_4_2_5P210 + + ntpd/ntpd-opts.h@1.203 +3 -3 + NTP_4_2_5P210 + + ntpd/ntpd-opts.texi@1.201 +1 -1 + NTP_4_2_5P210 + + ntpd/ntpd.1@1.201 +2 -2 + NTP_4_2_5P210 + + ntpdc/ntpdc-opts.c@1.199 +2 -2 + NTP_4_2_5P210 + + ntpdc/ntpdc-opts.h@1.199 +3 -3 + NTP_4_2_5P210 + + ntpdc/ntpdc-opts.texi@1.198 +1 -1 + NTP_4_2_5P210 + + ntpdc/ntpdc.1@1.198 +2 -2 + NTP_4_2_5P210 + + ntpq/ntpq-opts.c@1.199 +2 -2 + NTP_4_2_5P210 + + ntpq/ntpq-opts.h@1.199 +3 -3 + NTP_4_2_5P210 + + ntpq/ntpq-opts.texi@1.198 +1 -1 + NTP_4_2_5P210 + + ntpq/ntpq.1@1.198 +2 -2 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd-opts.c@1.79 +2 -2 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd-opts.h@1.79 +3 -3 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd-opts.texi@1.79 +1 -1 + NTP_4_2_5P210 + + ntpsnmpd/ntpsnmpd.1@1.79 +2 -2 + NTP_4_2_5P210 + + packageinfo.sh@1.213 +1 -1 + NTP_4_2_5P210 + + sntp/sntp-opts.c@1.73 +2 -2 + NTP_4_2_5P210 + + sntp/sntp-opts.h@1.73 +3 -3 + NTP_4_2_5P210 + + sntp/sntp-opts.texi@1.73 +1 -1 + NTP_4_2_5P210 + + sntp/sntp.1@1.73 +2 -2 + NTP_4_2_5P210 + + util/ntp-keygen-opts.c@1.202 +2 -2 + NTP_4_2_5P210 + + util/ntp-keygen-opts.h@1.202 +3 -3 + NTP_4_2_5P210 + + util/ntp-keygen-opts.texi@1.201 +1 -1 + NTP_4_2_5P210 + + util/ntp-keygen.1@1.201 +2 -2 + NTP_4_2_5P210 + +ChangeSet@1.1979, 2009-09-06 08:38:28+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/libntp/libntp.vcproj@1.17 +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.6 +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.17 +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.9 +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.9 +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.8 +2 -2 + [Bug 1294] change vs2008 include search path for OpenSSL from + $(OPENSSL)\inc32,$(OPENSSL)\include + to + $(OPENSSL_INC) + to match vc6, vs2003, and vs2005 changes from Danny + +ChangeSet@1.1976.1.1, 2009-09-06 04:00:32+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1295] trap directive options are not optional. + [Bug 1297] yylex() must always set yylval before returning. + + ChangeLog@1.418.1.1 +2 -0 + [Bug 1295] trap directive options are not optional. + [Bug 1297] yylex() must always set yylval before returning. + + include/ntp.h@1.162 +1 -1 + comment typo + + include/ntp_config.h@1.59 +3 -0 + add token_name() declaration + + ntpd/Makefile.am@1.67 +1 -1 + enable yacc/Bison report file (ntp_parser.output) generation + when making ntp_parser.[ch]. There is no need to commit + or distribute ntp_parser.output, it is only useful when + testing ntp_parser.y changes. + + + ntpd/ntp_config.c@1.211 +11 -10 + enable yydebug verbose parser output with -D5 and higher + [Bug 1295] config_trap() bug introduced with dumper in 4.2.5p203 + + + ntpd/ntp_control.c@1.120 +2 -1 + truncate saveconfig output file at open so remnants of longer file + do not remain at the end after overwriting. + + ntpd/ntp_parser.c@1.42 +876 -924 + Bison product + + ntpd/ntp_parser.h@1.25 +200 -204 + Bison product + + ntpd/ntp_parser.y@1.37 +230 -208 + [Bug 1295] trap directive options are not optional. + [Bug 1297] yylex() debug output improvement needs %token-table and + new function to access it, token_name() + make all terminal T_ tokens type Integer so they can be used in + actions as $1, $2, etc: { imaginary_func($2) } instead of + { imaginary_func(T_Sometoken) } + + + ntpd/ntp_scanner.c@1.23 +56 -27 + fix $1 style references to T_ values by setting yylval.Integer to the + T_ token for simple tokens with no other semantic value + improve debug output: yylex: lexeme 'trap' -> T_Trap + + +ChangeSet@1.1978, 2009-09-02 14:15:16-04:00, mayer@pogo.udel.edu + [Bug 1294] + + ChangeLog@1.419 +2 -0 + [Bug 1294] + +ChangeSet@1.1977, 2009-09-02 14:13:00-04:00, mayer@pogo.udel.edu + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros for windows and Remove unnecessary OPENSSL applink.c include + + ntpdc/ntpdc.c@1.68 +0 -6 + [Bug1294] Remove unnecessary OPENSSL applink.c include + + ntpq/ntpq.c@1.88 +0 -6 + [Bug1294] Remove unnecessary OPENSSL applink.c include + + ports/winnt/vc6/libntp.dsp@1.41 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpd.dsp@1.37 +4 -4 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpdate.dsp@1.21 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpdc.dsp@1.24 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpkeygen.dsp@1.17 +4 -4 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vc6/ntpq.dsp@1.25 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/libntp.vcproj@1.2 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpd.vcproj@1.2 +6 -6 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpdate.vcproj@1.2 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpdc.vcproj@1.2 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpkeygen.vcproj@1.2 +4 -4 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2003/ntpq.vcproj@1.2 +2 -2 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/libntp.vcproj@1.2 +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpd.vcproj@1.2 +7 -7 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpdate.vcproj@1.2 +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpdc.vcproj@1.2 +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpkeygen.vcproj@1.2 +5 -5 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + + ports/winnt/vs2005/ntpq.vcproj@1.2 +3 -3 + [Bug 1294] Use OPENSSL_INC and OPENSSL_LIB macros + +ChangeSet@1.1976, 2009-09-01 07:51:38-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P209 + TAG: NTP_4_2_5P209 + + ChangeLog@1.418 +1 -0 + NTP_4_2_5P209 + + ntpd/ntpd-opts.c@1.202 +2 -2 + NTP_4_2_5P209 + + ntpd/ntpd-opts.h@1.202 +3 -3 + NTP_4_2_5P209 + + ntpd/ntpd-opts.texi@1.200 +1 -1 + NTP_4_2_5P209 + + ntpd/ntpd.1@1.200 +2 -2 + NTP_4_2_5P209 + + ntpdc/ntpdc-opts.c@1.198 +2 -2 + NTP_4_2_5P209 + + ntpdc/ntpdc-opts.h@1.198 +3 -3 + NTP_4_2_5P209 + + ntpdc/ntpdc-opts.texi@1.197 +1 -1 + NTP_4_2_5P209 + + ntpdc/ntpdc.1@1.197 +2 -2 + NTP_4_2_5P209 + + ntpq/ntpq-opts.c@1.198 +2 -2 + NTP_4_2_5P209 + + ntpq/ntpq-opts.h@1.198 +3 -3 + NTP_4_2_5P209 + + ntpq/ntpq-opts.texi@1.197 +1 -1 + NTP_4_2_5P209 + + ntpq/ntpq.1@1.197 +2 -2 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd-opts.c@1.78 +2 -2 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd-opts.h@1.78 +3 -3 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd-opts.texi@1.78 +1 -1 + NTP_4_2_5P209 + + ntpsnmpd/ntpsnmpd.1@1.78 +2 -2 + NTP_4_2_5P209 + + packageinfo.sh@1.212 +1 -1 + NTP_4_2_5P209 + + sntp/sntp-opts.c@1.72 +2 -2 + NTP_4_2_5P209 + + sntp/sntp-opts.h@1.72 +3 -3 + NTP_4_2_5P209 + + sntp/sntp-opts.texi@1.72 +1 -1 + NTP_4_2_5P209 + + sntp/sntp.1@1.72 +2 -2 + NTP_4_2_5P209 + + util/ntp-keygen-opts.c@1.201 +2 -2 + NTP_4_2_5P209 + + util/ntp-keygen-opts.h@1.201 +3 -3 + NTP_4_2_5P209 + + util/ntp-keygen-opts.texi@1.200 +1 -1 + NTP_4_2_5P209 + + util/ntp-keygen.1@1.200 +2 -2 + NTP_4_2_5P209 + +ChangeSet@1.1974, 2009-09-01 08:20:19+00:00, davehart@shiny.ad.hartbrothers.com + revert accidental pull of wrong repo (windowscompiler) + + BitKeeper/deleted/.del-instsrv-VS2008.vcproj~af3a7a4284dd8b4f@1.2 +0 -0 + Delete: ports/winnt/instsrv/instsrv-VS2008.vcproj + + BitKeeper/deleted/.del-libntp-VS2008.vcproj~e944822ae4545d06@1.2 +0 -0 + Delete: ports/winnt/libntp/libntp-VS2008.vcproj + + BitKeeper/deleted/.del-ntp-VS2008.sln~b08951bb97303271@1.2 +0 -0 + Delete: ports/winnt/ntp-VS2008.sln + + BitKeeper/deleted/.del-ntp-keygen-VS2008.vcproj~f2e7f85d5942b392@1.2 +0 -0 + Delete: ports/winnt/ntp-keygen/ntp-keygen-VS2008.vcproj + + BitKeeper/deleted/.del-ntpd-VS2008.vcproj~63a1a8b5a4f17de8@1.2 +0 -0 + Delete: ports/winnt/ntpd/ntpd-VS2008.vcproj + + BitKeeper/deleted/.del-ntpdate-VS2008.vcproj~dcb57743d0d7d96d@1.2 +0 -0 + Delete: ports/winnt/ntpdate/ntpdate-VS2008.vcproj + + BitKeeper/deleted/.del-ntpdc-VS2008.vcproj~6b071c10ef40334b@1.2 +0 -0 + Delete: ports/winnt/ntpdc/ntpdc-VS2008.vcproj + + BitKeeper/deleted/.del-ntpkeygen.vcproj~9130c0edbfb4b39b@1.2 +0 -0 + Delete: ports/winnt/ntp-keygen/ntpkeygen.vcproj + + BitKeeper/deleted/.del-ntpq-VS2008.vcproj~3d9c726f33ecd5f@1.2 +0 -0 + Delete: ports/winnt/ntpq/ntpq-VS2008.vcproj + + ChangeLog@1.416 +0 -2 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/libntp/libntp.dsp@1.38 +0 -4 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/libntp/libntp.vcproj@1.14 +47 -148 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.14 +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntp.sln@1.5 +46 -43 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpd/ntpd.dsp@1.34 +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpd/ntpd.vcproj@1.14 +117 -119 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdate/ntpdate.dsp@1.18 +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdate/ntpdate.vcproj@1.6 +85 -20 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdc/ntpdc.dsp@1.21 +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpdc/ntpdc.vcproj@1.6 +46 -20 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpq/ntpq.dsp@1.22 +4 -0 + revert accidental pull of wrong repo (windowscompiler) + + ports/winnt/ntpq/ntpq.vcproj@1.5 +36 -20 + revert accidental pull of wrong repo (windowscompiler) + +ChangeSet@1.1968.1.18, 2009-08-31 21:57:23-04:00, mayer@pogo.udel.edu + [Bug 1289] update to add VS2003 + + ChangeLog@1.413.1.11 +1 -1 + [Bug 1289] update to add VS2003 + +ChangeSet@1.1968.1.17, 2009-08-31 16:58:47-04:00, mayer@pogo.udel.edu + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/Instsrv.vcproj@1.1 +174 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/Instsrv.vcproj@1.0 +0 -0 + + ports/winnt/vs2003/libntp.vcproj@1.1 +2058 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/libntp.vcproj@1.0 +0 -0 + + ports/winnt/vs2003/ntp.sln@1.1 +73 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntp.sln@1.0 +0 -0 + + ports/winnt/vs2003/ntpd.vcproj@1.1 +2113 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpd.vcproj@1.0 +0 -0 + + ports/winnt/vs2003/ntpdate.vcproj@1.1 +221 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpdate.vcproj@1.0 +0 -0 + + ports/winnt/vs2003/ntpdc.vcproj@1.1 +265 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpdc.vcproj@1.0 +0 -0 + + ports/winnt/vs2003/ntpkeygen.vcproj@1.1 +302 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpkeygen.vcproj@1.0 +0 -0 + + ports/winnt/vs2003/ntpq.vcproj@1.1 +263 -0 + [Bug 1289] Add vs2003 compiler files + + ports/winnt/vs2003/ntpq.vcproj@1.0 +0 -0 + +ChangeSet@1.1968.1.16, 2009-08-31 09:56:29-04:00, mayer@pogo.udel.edu + [Bug 1290] + + ChangeLog@1.413.1.10 +2 -1 + [Bug 1290] + +ChangeSet@1.1968.1.15, 2009-08-31 09:54:57-04:00, mayer@pogo.udel.edu + [Bug 1290] Fix to use GETTIMEOFDAY macro + + ntpd/refclock_oncore.c@1.78.1.1 +1 -1 + [Bug 1290] Fix to use GETTIMEOFDAY macro + +ChangeSet@1.1968.1.14, 2009-08-31 09:50:13-04:00, mayer@pogo.udel.edu + [Bug 1289] Use quotes instead of angle brackets for include of messages.h + + ports/winnt/libntp/syslog.c@1.5 +1 -1 + [Bug 1289] Use quotes instead of angle brackets for include of messages.h + +ChangeSet@1.1968.1.13, 2009-08-30 23:47:19-04:00, mayer@pogo.udel.edu + [Bug 1289] + + ChangeLog@1.413.1.9 +1 -0 + [Bug 1289] + +ChangeSet@1.1968.1.12, 2009-08-30 23:36:44-04:00, mayer@pogo.udel.edu + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/Instsrv.vcproj@1.1 +242 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/Instsrv.vcproj@1.0 +0 -0 + + ports/winnt/vs2005/libntp.vcproj@1.1 +2250 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/libntp.vcproj@1.0 +0 -0 + + ports/winnt/vs2005/ntp.sln@1.1 +68 -0 + [Bug #1289] Update project files for VS6 + + ports/winnt/vs2005/ntp.sln@1.0 +0 -0 + + ports/winnt/vs2005/ntpd.vcproj@1.1 +2237 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpd.vcproj@1.0 +0 -0 + + ports/winnt/vs2005/ntpdate.vcproj@1.1 +292 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpdate.vcproj@1.0 +0 -0 + + ports/winnt/vs2005/ntpdc.vcproj@1.1 +336 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpdc.vcproj@1.0 +0 -0 + + ports/winnt/vs2005/ntpkeygen.vcproj@1.1 +376 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpkeygen.vcproj@1.0 +0 -0 + + ports/winnt/vs2005/ntpq.vcproj@1.1 +336 -0 + [Bug #1289] Update project files for VS2005 + + ports/winnt/vs2005/ntpq.vcproj@1.0 +0 -0 + +ChangeSet@1.1968.1.11, 2009-08-30 23:30:53-04:00, mayer@pogo.udel.edu + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/Instsrv.dsp@1.9 +9 -9 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/libntp.dsp@1.36.1.2 +23 -19 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntp.dsw@1.9 +7 -7 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpd.dsp@1.32.1.2 +17 -21 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpdate.dsp@1.16.1.2 +12 -16 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpdc.dsp@1.19.1.2 +13 -17 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpkeygen.dsp@1.12.1.2 +10 -14 + [Bug #1289] Update project files for VS6 + + ports/winnt/vc6/ntpq.dsp@1.20.1.2 +12 -16 + [Bug #1289] Update project files for VS6 + +ChangeSet@1.1968.1.10, 2009-08-30 23:28:42-04:00, mayer@pogo.udel.edu + [Bug #1289] Move compiler project for VS6 + + ports/winnt/vc6/Instsrv.dsp@1.8 +0 -0 + Rename: ports/winnt/instsrv/Instsrv.dsp -> ports/winnt/vc6/Instsrv.dsp + + ports/winnt/vc6/libntp.dsp@1.36.1.1 +0 -0 + Rename: ports/winnt/libntp/libntp.dsp -> ports/winnt/vc6/libntp.dsp + + ports/winnt/vc6/ntp.dsw@1.8 +0 -0 + Rename: ports/winnt/ntp.dsw -> ports/winnt/vc6/ntp.dsw + + ports/winnt/vc6/ntpd.dsp@1.32.1.1 +0 -0 + Rename: ports/winnt/ntpd/ntpd.dsp -> ports/winnt/vc6/ntpd.dsp + + ports/winnt/vc6/ntpdate.dsp@1.16.1.1 +0 -0 + Rename: ports/winnt/ntpdate/ntpdate.dsp -> ports/winnt/vc6/ntpdate.dsp + + ports/winnt/vc6/ntpdc.dsp@1.19.1.1 +0 -0 + Rename: ports/winnt/ntpdc/ntpdc.dsp -> ports/winnt/vc6/ntpdc.dsp + + ports/winnt/vc6/ntpkeygen.dsp@1.12.1.1 +0 -0 + Rename: ports/winnt/ntp-keygen/ntpkeygen.dsp -> ports/winnt/vc6/ntpkeygen.dsp + + ports/winnt/vc6/ntpq.dsp@1.20.1.1 +0 -0 + Rename: ports/winnt/ntpq/ntpq.dsp -> ports/winnt/vc6/ntpq.dsp + +ChangeSet@1.1968.1.8, 2009-08-30 03:02:04-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P208 + TAG: NTP_4_2_5P208 + + ChangeLog@1.413.1.7 +1 -0 + NTP_4_2_5P208 + + ntpd/ntpd-opts.c@1.201 +2 -2 + NTP_4_2_5P208 + + ntpd/ntpd-opts.h@1.201 +3 -3 + NTP_4_2_5P208 + + ntpd/ntpd-opts.texi@1.199 +1 -1 + NTP_4_2_5P208 + + ntpd/ntpd.1@1.199 +2 -2 + NTP_4_2_5P208 + + ntpdc/ntpdc-opts.c@1.197 +2 -2 + NTP_4_2_5P208 + + ntpdc/ntpdc-opts.h@1.197 +3 -3 + NTP_4_2_5P208 + + ntpdc/ntpdc-opts.texi@1.196 +1 -1 + NTP_4_2_5P208 + + ntpdc/ntpdc.1@1.196 +2 -2 + NTP_4_2_5P208 + + ntpq/ntpq-opts.c@1.197 +2 -2 + NTP_4_2_5P208 + + ntpq/ntpq-opts.h@1.197 +3 -3 + NTP_4_2_5P208 + + ntpq/ntpq-opts.texi@1.196 +1 -1 + NTP_4_2_5P208 + + ntpq/ntpq.1@1.196 +2 -2 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd-opts.c@1.77 +2 -2 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd-opts.h@1.77 +3 -3 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd-opts.texi@1.77 +1 -1 + NTP_4_2_5P208 + + ntpsnmpd/ntpsnmpd.1@1.77 +2 -2 + NTP_4_2_5P208 + + packageinfo.sh@1.211 +1 -1 + NTP_4_2_5P208 + + sntp/sntp-opts.c@1.71 +2 -2 + NTP_4_2_5P208 + + sntp/sntp-opts.h@1.71 +3 -3 + NTP_4_2_5P208 + + sntp/sntp-opts.texi@1.71 +1 -1 + NTP_4_2_5P208 + + sntp/sntp.1@1.71 +2 -2 + NTP_4_2_5P208 + + util/ntp-keygen-opts.c@1.200 +2 -2 + NTP_4_2_5P208 + + util/ntp-keygen-opts.h@1.200 +3 -3 + NTP_4_2_5P208 + + util/ntp-keygen-opts.texi@1.199 +1 -1 + NTP_4_2_5P208 + + util/ntp-keygen.1@1.199 +2 -2 + NTP_4_2_5P208 + +ChangeSet@1.1968.3.2, 2009-08-29 21:22:45+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1293] make configuration dumper ready for release, specifically: + rename ntpq dumpcfg command to "saveconfig". + require authentication for saveconfig. + "restrict ... nomodify" prevents saveconfig and :config. + "saveconfig ." shorthand to save to startup configuration file. + support strftime() substitution in saveconfig arg to timestamp + the output filename, for example "saveconfig %Y%m%d-%H%M%S.conf". + display saveconfig response message from ntpd in ntpq. + save output filename in "savedconfig" variable, fetched with ntpq -c + "rv 0 savedconfig". + document saveconfig in html/ntpq.html. + add ./configure --disable-saveconfig to build a smaller ntpd. + log saveconfig failures and successes to syslog. + + + ChangeLog@1.413.3.1 +13 -0 + [Bug 1293] make configuration dumper ready for release, specifically: + rename ntpq dumpcfg command to "saveconfig". + require authentication for saveconfig. + "restrict ... nomodify" prevents saveconfig and :config. + "saveconfig ." shorthand to save to startup configuration file. + support strftime() substitution in saveconfig arg to timestamp + the output filename, for example "saveconfig %Y%m%d-%H%M%S.conf". + display saveconfig response message from ntpd in ntpq. + save output filename in "savedconfig" variable, fetched with ntpq -c + "rv 0 savedconfig". + document saveconfig in html/ntpq.html. + add ./configure --disable-saveconfig to build a smaller ntpd. + log saveconfig failures and successes to syslog. + + + html/ntpq.html@1.32 +13 -8 + document "config-from-file" and "saveconfig" + use
and no
between "cv" and "clockvar" as with other synonyms. + typo "helpl" -> "help". + typo "apear" -> "appear" + + include/ntp_config.h@1.58 +2 -1 + support ./configure --disable-saveconfig + + include/ntp_control.h@1.37 +2 -2 + CTL_OP_DUMPCONFIG renamed CTL_OP_SAVECONFIG + + include/ntpd.h@1.131 +1 -1 + expose cfg_tree_history as extern for ntp_control.c save_config() + + ntpd/ntp_config.c@1.210 +5 -1 + support ./configure --disable-saveconfig + + ntpd/ntp_control.c@1.119 +101 -35 + dump_config() renamed save_config() + CTL_OP_DUMPCONFIG renamed CTL_OP_SAVECONFIG + add "savedconfig" system variable containing last saveconfig filename + support ./configure --disable-saveconfig + log saveconfig failures and successes to syslog + enforce "restrict ... nomodify" preventing ntpq :config, config-from-file, + and saveconfig + require authentication for saveconfig + remove restrictions on saveconfig output directory, allow overwriting + exiting files + support "saveconfig ." to replace the startup configuration file + allow strftime() format specifiers in saveconfig filename, such as + "saveconfig ntp-%Y%m%d-%H%M%S.conf" + + ntpd/ntp_intres.c@1.65 +2 -2 + clean up unreferenced local warnings + + ntpd/ntp_io.c@1.296 +1 -2 + clean up unreferenced local warning + + ntpq/ntpq-subs.c@1.35 +21 -13 + rename ntpq dumpcfg to saveconfig, require authentication + + ports/winnt/include/config.h@1.74.1.1 +1 -1 + default to equivalent of --enable-saveconfig as with Unix + warn on unreferenced local variables + + ports/winnt/ntpd/ntp_iocompletionport.c@1.49 +0 -2 + remove unreferenced locals + +ChangeSet@1.1968.1.6, 2009-08-29 07:50:13-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P207 + TAG: NTP_4_2_5P207 + + ChangeLog@1.413.1.5 +1 -0 + NTP_4_2_5P207 + + ntpd/ntpd-opts.c@1.200 +2 -2 + NTP_4_2_5P207 + + ntpd/ntpd-opts.h@1.200 +3 -3 + NTP_4_2_5P207 + + ntpd/ntpd-opts.texi@1.198 +1 -1 + NTP_4_2_5P207 + + ntpd/ntpd.1@1.198 +2 -2 + NTP_4_2_5P207 + + ntpdc/ntpdc-opts.c@1.196 +2 -2 + NTP_4_2_5P207 + + ntpdc/ntpdc-opts.h@1.196 +3 -3 + NTP_4_2_5P207 + + ntpdc/ntpdc-opts.texi@1.195 +1 -1 + NTP_4_2_5P207 + + ntpdc/ntpdc.1@1.195 +2 -2 + NTP_4_2_5P207 + + ntpq/ntpq-opts.c@1.196 +2 -2 + NTP_4_2_5P207 + + ntpq/ntpq-opts.h@1.196 +3 -3 + NTP_4_2_5P207 + + ntpq/ntpq-opts.texi@1.195 +1 -1 + NTP_4_2_5P207 + + ntpq/ntpq.1@1.195 +2 -2 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd-opts.c@1.76 +2 -2 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd-opts.h@1.76 +3 -3 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd-opts.texi@1.76 +1 -1 + NTP_4_2_5P207 + + ntpsnmpd/ntpsnmpd.1@1.76 +2 -2 + NTP_4_2_5P207 + + packageinfo.sh@1.210 +1 -1 + NTP_4_2_5P207 + + sntp/sntp-opts.c@1.70 +2 -2 + NTP_4_2_5P207 + + sntp/sntp-opts.h@1.70 +3 -3 + NTP_4_2_5P207 + + sntp/sntp-opts.texi@1.70 +1 -1 + NTP_4_2_5P207 + + sntp/sntp.1@1.70 +2 -2 + NTP_4_2_5P207 + + util/ntp-keygen-opts.c@1.199 +2 -2 + NTP_4_2_5P207 + + util/ntp-keygen-opts.h@1.199 +3 -3 + NTP_4_2_5P207 + + util/ntp-keygen-opts.texi@1.198 +1 -1 + NTP_4_2_5P207 + + util/ntp-keygen.1@1.198 +2 -2 + NTP_4_2_5P207 + +ChangeSet@1.1968.3.1, 2009-08-29 05:08:56-04:00, stenn@pogo.udel.edu + [Bug 1293] add support for --disable-saveconfig to configure.ac + + configure.ac@1.450 +10 -0 + [Bug 1293] add support for --disable-saveconfig to configure.ac + +ChangeSet@1.1968.2.1, 2009-08-28 07:40:42+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ChangeLog@1.413.2.1 +1 -0 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/scripts/mkver.bat@1.11 +19 -24 + support per-compiler build subdirs under winnt + remove no-longer-needed support for getting version from version.m4 + (packageinfo.sh has been used for some time) + + ports/winnt/vs2008/instsrv/instsrv.vcproj@1.4 +15 -15 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/instsrv/instsrv.vcproj@1.3 +0 -0 + Rename: ports/winnt/vs2008/instsrv.vcproj -> ports/winnt/vs2008/instsrv/instsrv.vcproj + + ports/winnt/vs2008/instsrv.vcproj@1.2 +0 -0 + Rename: ports/winnt/instsrv/instsrv.vcproj -> ports/winnt/vs2008/instsrv.vcproj + + ports/winnt/vs2008/libntp/libntp.vcproj@1.12.1.3 +150 -150 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/libntp/libntp.vcproj@1.12.1.2 +0 -0 + Rename: ports/winnt/vs2008/libntp.vcproj -> ports/winnt/vs2008/libntp/libntp.vcproj + + ports/winnt/vs2008/libntp.vcproj@1.12.1.1 +0 -0 + Rename: ports/winnt/libntp/libntp.vcproj -> ports/winnt/vs2008/libntp.vcproj + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.5 +27 -27 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj@1.4 +0 -0 + Rename: ports/winnt/vs2008/ntp-keygen.vcproj -> ports/winnt/vs2008/ntp-keygen/ntp-keygen.vcproj + + ports/winnt/vs2008/ntp-keygen.vcproj@1.3 +0 -0 + Rename: ports/winnt/ntp-keygen/ntp-keygen.vcproj -> ports/winnt/vs2008/ntp-keygen.vcproj + + ports/winnt/vs2008/ntp.sln@1.3.1.1 +0 -0 + Rename: ports/winnt/ntp.sln -> ports/winnt/vs2008/ntp.sln + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.12.1.3 +169 -169 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpd/ntpd.vcproj@1.12.1.2 +0 -0 + Rename: ports/winnt/vs2008/ntpd.vcproj -> ports/winnt/vs2008/ntpd/ntpd.vcproj + + ports/winnt/vs2008/ntpd.vcproj@1.12.1.1 +0 -0 + Rename: ports/winnt/ntpd/ntpd.vcproj -> ports/winnt/vs2008/ntpd.vcproj + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.4.1.3 +35 -35 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpdate/ntpdate.vcproj@1.4.1.2 +0 -0 + Rename: ports/winnt/vs2008/ntpdate.vcproj -> ports/winnt/vs2008/ntpdate/ntpdate.vcproj + + ports/winnt/vs2008/ntpdate.vcproj@1.4.1.1 +0 -0 + Rename: ports/winnt/ntpdate/ntpdate.vcproj -> ports/winnt/vs2008/ntpdate.vcproj + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.4.1.3 +26 -26 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpdc/ntpdc.vcproj@1.4.1.2 +0 -0 + Rename: ports/winnt/vs2008/ntpdc.vcproj -> ports/winnt/vs2008/ntpdc/ntpdc.vcproj + + ports/winnt/vs2008/ntpdc.vcproj@1.4.1.1 +0 -0 + Rename: ports/winnt/ntpdc/ntpdc.vcproj -> ports/winnt/vs2008/ntpdc.vcproj + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.3.1.3 +25 -25 + [Bug 1289] Move vc9/vs2008 build to ports\winnt\vs2008. + + ports/winnt/vs2008/ntpq/ntpq.vcproj@1.3.1.2 +0 -0 + Rename: ports/winnt/vs2008/ntpq.vcproj -> ports/winnt/vs2008/ntpq/ntpq.vcproj + + ports/winnt/vs2008/ntpq.vcproj@1.3.1.1 +0 -0 + Rename: ports/winnt/ntpq/ntpq.vcproj -> ports/winnt/vs2008/ntpq.vcproj + +ChangeSet@1.1968.1.5, 2009-08-27 20:02:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1292] Minor Windows source tweaks for VC6-era SDK headers. + From Martin Burnicki + + ChangeLog@1.413.1.4 +1 -0 + [Bug 1292] Minor Windows source tweaks for VC6-era SDK headers. + From Martin Burnicki + + ports/winnt/include/config.h@1.75 +3 -1 + #include before for VC6 header compatibility + unconditionally #define ISC_PLATFORM_HAVEIN6PKTINFO + Thanks Martin Burnicki + + ports/winnt/libisc/interfaceiter.c@1.10 +2 -0 + protect reference to sin6_scope_id with ISC_PLATFORM_HAVESCOPEID for + VC6 SDK headers compatibility + +ChangeSet@1.1972, 2009-08-26 23:42:30-04:00, mayer@pogo.udel.edu + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/instsrv/instsrv-VS2008.vcproj@1.1 +253 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/instsrv/instsrv-VS2008.vcproj@1.0 +0 -0 + + ports/winnt/libntp/libntp-VS2008.vcproj@1.1 +2149 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/libntp/libntp-VS2008.vcproj@1.0 +0 -0 + + ports/winnt/ntp-VS2008.sln@1.1 +71 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntp-VS2008.sln@1.0 +0 -0 + + ports/winnt/ntp-keygen/ntp-keygen-VS2008.vcproj@1.1 +397 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntp-keygen/ntp-keygen-VS2008.vcproj@1.0 +0 -0 + + ports/winnt/ntpd/ntpd-VS2008.vcproj@1.1 +2235 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpd/ntpd-VS2008.vcproj@1.0 +0 -0 + + ports/winnt/ntpdate/ntpdate-VS2008.vcproj@1.1 +357 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpdate/ntpdate-VS2008.vcproj@1.0 +0 -0 + + ports/winnt/ntpdc/ntpdc-VS2008.vcproj@1.1 +362 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpdc/ntpdc-VS2008.vcproj@1.0 +0 -0 + + ports/winnt/ntpq/ntpq-VS2008.vcproj@1.1 +352 -0 + Bug #1289 - separate compiler files for VS 2008 + + ports/winnt/ntpq/ntpq-VS2008.vcproj@1.0 +0 -0 + +ChangeSet@1.1968.1.4, 2009-08-26 07:54:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P206 + TAG: NTP_4_2_5P206 + + ChangeLog@1.413.1.3 +1 -0 + NTP_4_2_5P206 + + ntpd/ntpd-opts.c@1.199 +2 -2 + NTP_4_2_5P206 + + ntpd/ntpd-opts.h@1.199 +3 -3 + NTP_4_2_5P206 + + ntpd/ntpd-opts.texi@1.197 +1 -1 + NTP_4_2_5P206 + + ntpd/ntpd.1@1.197 +2 -2 + NTP_4_2_5P206 + + ntpdc/ntpdc-opts.c@1.195 +2 -2 + NTP_4_2_5P206 + + ntpdc/ntpdc-opts.h@1.195 +3 -3 + NTP_4_2_5P206 + + ntpdc/ntpdc-opts.texi@1.194 +1 -1 + NTP_4_2_5P206 + + ntpdc/ntpdc.1@1.194 +2 -2 + NTP_4_2_5P206 + + ntpq/ntpq-opts.c@1.195 +2 -2 + NTP_4_2_5P206 + + ntpq/ntpq-opts.h@1.195 +3 -3 + NTP_4_2_5P206 + + ntpq/ntpq-opts.texi@1.194 +1 -1 + NTP_4_2_5P206 + + ntpq/ntpq.1@1.194 +2 -2 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd-opts.c@1.75 +2 -2 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd-opts.h@1.75 +3 -3 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd-opts.texi@1.75 +1 -1 + NTP_4_2_5P206 + + ntpsnmpd/ntpsnmpd.1@1.75 +2 -2 + NTP_4_2_5P206 + + packageinfo.sh@1.209 +1 -1 + NTP_4_2_5P206 + + sntp/sntp-opts.c@1.69 +11 -11 + NTP_4_2_5P206 + + sntp/sntp-opts.h@1.69 +6 -6 + NTP_4_2_5P206 + + sntp/sntp-opts.texi@1.69 +11 -9 + NTP_4_2_5P206 + + sntp/sntp.1@1.69 +15 -13 + NTP_4_2_5P206 + + util/ntp-keygen-opts.c@1.198 +2 -2 + NTP_4_2_5P206 + + util/ntp-keygen-opts.h@1.198 +3 -3 + NTP_4_2_5P206 + + util/ntp-keygen-opts.texi@1.197 +1 -1 + NTP_4_2_5P206 + + util/ntp-keygen.1@1.197 +2 -2 + NTP_4_2_5P206 + +ChangeSet@1.1968.1.3, 2009-08-26 04:48:50-04:00, stenn@whimsy.udel.edu + accopt.html typo fixes from Dave Mills + + ChangeLog@1.413.1.2 +1 -0 + accopt.html typo fixes from Dave Mills + + html/accopt.html@1.32 +3 -3 + accopt.html typo fixes from Dave Mills + +ChangeSet@1.1968.1.2, 2009-08-26 04:14:45-04:00, stenn@whimsy.udel.edu + The 2nd fopen in write_kod_db() must be inside the block. From Dave Hart. + + sntp/kod_management.c@1.12 +16 -17 + The 2nd fopen in write_kod_db() must be inside the block. From Dave Hart. + +ChangeSet@1.1968.1.1, 2009-08-26 00:48:46+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1283] default to remembering KoD in sntp + clean up numerous sntp/kod_management.c bugs + use all addresses resolved from each DNS name + + ChangeLog@1.413.1.1 +3 -0 + [Bug 1283] default to remembering KoD in sntp. + clean up numerous sntp/kod_management.c bugs. + use all addresses resolved from each DNS name. + + configure.ac@1.449 +1 -1 + change "permanent DNS errors" to "permanent DNS failures" to make + it simpler to grep for errors in make.log + + libntp/emalloc.c@1.9 +22 -9 + send emalloc() and friends fatal error messages to stderr as well as syslog + + ntpd/ntp_config.c@1.209 +6 -11 + clean up unreferenced locals warnings in free_config_*() + + sntp/configure.ac@1.19 +1 -0 + add NTP_DIR_SEP to define DIR_SEP (/ or \) + + sntp/crypto.c@1.8 +2 -2 + malloc() -> emalloc() + + sntp/kod_management.c@1.11 +148 -142 + KOD -> KoD + Do not complain about KoD file format if it's named /dev/null + change KoD field separator from colon to space to support IPv6 addresses + save KoD file even if one wasn't loaded + create directories if needed while writing KoD file + clean up confusion over kod_db being an array of pointers or structs + + + sntp/kod_management.h@1.7 +8 -9 + use time_t for KoD timestamp instead of uint + remove unused items + + sntp/main.c@1.18 +83 -68 + [Bug 1283] default to remembering KoD in sntp + use all addresses resolved from each DNS name + add test code for KoD DB (disabled by #ifdef) + resolve alloca() implicit decl warnings by eliminating its use + don't treat pkt.refid as zero terminated, it's not + + sntp/netutils.c@1.3 +5 -5 + malloc() -> emalloc() + + sntp/networking.c@1.24 +5 -5 + malloc() -> emalloc() + change default broadcast timeout from 60 to 68 since ntpd + broadcasts every 64 seconds + + sntp/sntp-opts.def@1.11 +11 -17 + Update --kod/-K descrip and doc + use common copyright.def instead of explicit copyright block + Update -b & -t descrip/doc to reflect change to 68 second timeout + + sntp/utilities.c@1.9 +8 -19 + malloc() -> emalloc() + use pointer cast instead of copy in pkt_output() + + sntp/utilities.h@1.7 +1 -0 + include ntp_stdlib.h for emalloc() + +ChangeSet@1.1971, 2009-08-24 15:25:59-04:00, mayer@pogo.udel.edu + Bug fixes 1289 and 1290 + + ChangeLog@1.414 +2 -0 + Bug fixes 1289 and 1290 + + ntpd/refclock_oncore.c@1.79 +1 -1 + [Bug 1290] use macro GETTIMEOFDAY instead of gettimeofday() + +ChangeSet@1.1970, 2009-08-24 15:19:05-04:00, mayer@pogo.udel.edu + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.1 +376 -0 + keygen file + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.0 +0 -0 + +ChangeSet@1.1969, 2009-08-24 15:14:02-04:00, mayer@pogo.udel.edu + [Bug 1289] Fix compiler files for Windows + + ports/winnt/libntp/libntp.dsp@1.37 +4 -0 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/libntp/libntp.vcproj@1.13 +148 -47 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.13 +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntp.sln@1.4 +43 -46 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpd/ntpd.dsp@1.33 +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpd/ntpd.vcproj@1.13 +119 -117 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdate/ntpdate.dsp@1.17 +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdate/ntpdate.vcproj@1.5 +20 -85 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdc/ntpdc.dsp@1.20 +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpdc/ntpdc.vcproj@1.5 +20 -46 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpq/ntpq.dsp@1.21 +0 -4 + [Bug 1289] Fix compiler files for Windows + + ports/winnt/ntpq/ntpq.vcproj@1.4 +20 -36 + [Bug 1289] Fix compiler files for Windows + +ChangeSet@1.1968, 2009-08-18 07:50:08-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P205 + TAG: NTP_4_2_5P205 + + ChangeLog@1.413 +1 -0 + NTP_4_2_5P205 + + ntpd/ntpd-opts.c@1.198 +2 -2 + NTP_4_2_5P205 + + ntpd/ntpd-opts.h@1.198 +3 -3 + NTP_4_2_5P205 + + ntpd/ntpd-opts.texi@1.196 +1 -1 + NTP_4_2_5P205 + + ntpd/ntpd.1@1.196 +2 -2 + NTP_4_2_5P205 + + ntpdc/ntpdc-opts.c@1.194 +2 -2 + NTP_4_2_5P205 + + ntpdc/ntpdc-opts.h@1.194 +3 -3 + NTP_4_2_5P205 + + ntpdc/ntpdc-opts.texi@1.193 +1 -1 + NTP_4_2_5P205 + + ntpdc/ntpdc.1@1.193 +2 -2 + NTP_4_2_5P205 + + ntpq/ntpq-opts.c@1.194 +2 -2 + NTP_4_2_5P205 + + ntpq/ntpq-opts.h@1.194 +3 -3 + NTP_4_2_5P205 + + ntpq/ntpq-opts.texi@1.193 +1 -1 + NTP_4_2_5P205 + + ntpq/ntpq.1@1.193 +2 -2 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd-opts.c@1.74 +2 -2 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd-opts.h@1.74 +3 -3 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd-opts.texi@1.74 +1 -1 + NTP_4_2_5P205 + + ntpsnmpd/ntpsnmpd.1@1.74 +2 -2 + NTP_4_2_5P205 + + packageinfo.sh@1.208 +1 -1 + NTP_4_2_5P205 + + sntp/sntp-opts.c@1.68 +2 -2 + NTP_4_2_5P205 + + sntp/sntp-opts.h@1.68 +3 -3 + NTP_4_2_5P205 + + sntp/sntp-opts.texi@1.68 +1 -1 + NTP_4_2_5P205 + + sntp/sntp.1@1.68 +2 -2 + NTP_4_2_5P205 + + util/ntp-keygen-opts.c@1.197 +2 -2 + NTP_4_2_5P205 + + util/ntp-keygen-opts.h@1.197 +3 -3 + NTP_4_2_5P205 + + util/ntp-keygen-opts.texi@1.196 +1 -1 + NTP_4_2_5P205 + + util/ntp-keygen.1@1.196 +2 -2 + NTP_4_2_5P205 + +ChangeSet@1.1967, 2009-08-18 02:18:21-04:00, stenn@whimsy.udel.edu + accopt.html typo fixes from Dave Mills + + ChangeLog@1.412 +1 -0 + accopt.html typo fixes from Dave Mills + + html/accopt.html@1.31 +7 -11 + accopt.html typo fixes from Dave Mills + +ChangeSet@1.1966, 2009-08-18 05:05:46+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1285] Log ntpq :config/config-from-file events. + + ChangeLog@1.411 +1 -0 + [Bug 1285] Log ntpq :config/config-from-file events. + + include/ntp_config.h@1.57 +1 -1 + provide source address to config_remotely + + ntpd/ntp_config.c@1.208 +17 -1 + Log source of each dumpcfg section (startup config or ntpq) + + ntpd/ntp_control.c@1.118 +52 -30 + [Bug 1285] Log ntpq :config/config-from-file events. + + ntpq/ntpq-subs.c@1.34 +11 -2 + display each line while sending in ntpq config-from-file + +ChangeSet@1.1965, 2009-08-17 16:32:18+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1286] dumpcfg omits statsdir, mangles filegen + + ChangeLog@1.410 +1 -0 + [Bug 1286] dumpcfg omits statsdir, mangles filegen + + ntpd/ntp_config.c@1.207 +425 -432 + [Bug 1286] dumpcfg omits statsdir, mangles filegen + rearrange dump output to group related items, come closer to examples + +ChangeSet@1.1964, 2009-08-17 07:50:54-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P204 + TAG: NTP_4_2_5P204 + + ChangeLog@1.409 +1 -0 + NTP_4_2_5P204 + + ntpd/ntpd-opts.c@1.197 +2 -2 + NTP_4_2_5P204 + + ntpd/ntpd-opts.h@1.197 +3 -3 + NTP_4_2_5P204 + + ntpd/ntpd-opts.texi@1.195 +1 -1 + NTP_4_2_5P204 + + ntpd/ntpd.1@1.195 +2 -2 + NTP_4_2_5P204 + + ntpdc/ntpdc-opts.c@1.193 +2 -2 + NTP_4_2_5P204 + + ntpdc/ntpdc-opts.h@1.193 +3 -3 + NTP_4_2_5P204 + + ntpdc/ntpdc-opts.texi@1.192 +1 -1 + NTP_4_2_5P204 + + ntpdc/ntpdc.1@1.192 +2 -2 + NTP_4_2_5P204 + + ntpq/ntpq-opts.c@1.193 +2 -2 + NTP_4_2_5P204 + + ntpq/ntpq-opts.h@1.193 +3 -3 + NTP_4_2_5P204 + + ntpq/ntpq-opts.texi@1.192 +1 -1 + NTP_4_2_5P204 + + ntpq/ntpq.1@1.192 +2 -2 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd-opts.c@1.73 +2 -2 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd-opts.h@1.73 +3 -3 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd-opts.texi@1.73 +1 -1 + NTP_4_2_5P204 + + ntpsnmpd/ntpsnmpd.1@1.73 +2 -2 + NTP_4_2_5P204 + + packageinfo.sh@1.207 +1 -1 + NTP_4_2_5P204 + + sntp/sntp-opts.c@1.67 +2 -2 + NTP_4_2_5P204 + + sntp/sntp-opts.h@1.67 +3 -3 + NTP_4_2_5P204 + + sntp/sntp-opts.texi@1.67 +1 -1 + NTP_4_2_5P204 + + sntp/sntp.1@1.67 +2 -2 + NTP_4_2_5P204 + + util/ntp-keygen-opts.c@1.196 +2 -2 + NTP_4_2_5P204 + + util/ntp-keygen-opts.h@1.196 +3 -3 + NTP_4_2_5P204 + + util/ntp-keygen-opts.texi@1.195 +1 -1 + NTP_4_2_5P204 + + util/ntp-keygen.1@1.195 +2 -2 + NTP_4_2_5P204 + +ChangeSet@1.1963, 2009-08-17 03:07:26+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1284] infinite loop in ntpd dumping more than one trustedkey + use free_config_*() routines at exit on DEBUG builds to free + config tree and expose remaining leaks + + ChangeLog@1.408 +1 -0 + [Bug 1284] infinite loop in ntpd dumping more than one trustedkey + + ntpd/ntp_config.c@1.206 +55 -10 + [Bug 1284] infinite loop in ntpd dumping more than one trustedkey + use free_config_*() routines at exit on DEBUG builds to free + config tree and expose remaining leaks + +ChangeSet@1.1962, 2009-08-16 20:53:29-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P203 + TAG: NTP_4_2_5P203 + + ChangeLog@1.407 +1 -0 + NTP_4_2_5P203 + + ntpd/ntpd-opts.c@1.196 +2 -2 + NTP_4_2_5P203 + + ntpd/ntpd-opts.h@1.196 +3 -3 + NTP_4_2_5P203 + + ntpd/ntpd-opts.texi@1.194 +1 -1 + NTP_4_2_5P203 + + ntpd/ntpd.1@1.194 +2 -2 + NTP_4_2_5P203 + + ntpdc/ntpdc-opts.c@1.192 +2 -2 + NTP_4_2_5P203 + + ntpdc/ntpdc-opts.h@1.192 +3 -3 + NTP_4_2_5P203 + + ntpdc/ntpdc-opts.texi@1.191 +1 -1 + NTP_4_2_5P203 + + ntpdc/ntpdc.1@1.191 +2 -2 + NTP_4_2_5P203 + + ntpq/ntpq-opts.c@1.192 +2 -2 + NTP_4_2_5P203 + + ntpq/ntpq-opts.h@1.192 +3 -3 + NTP_4_2_5P203 + + ntpq/ntpq-opts.texi@1.191 +1 -1 + NTP_4_2_5P203 + + ntpq/ntpq.1@1.191 +2 -2 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd-opts.c@1.72 +2 -2 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd-opts.h@1.72 +3 -3 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd-opts.texi@1.72 +1 -1 + NTP_4_2_5P203 + + ntpsnmpd/ntpsnmpd.1@1.72 +2 -2 + NTP_4_2_5P203 + + packageinfo.sh@1.206 +1 -1 + NTP_4_2_5P203 + + sntp/sntp-opts.c@1.66 +2 -2 + NTP_4_2_5P203 + + sntp/sntp-opts.h@1.66 +3 -3 + NTP_4_2_5P203 + + sntp/sntp-opts.texi@1.66 +1 -1 + NTP_4_2_5P203 + + sntp/sntp.1@1.66 +2 -2 + NTP_4_2_5P203 + + util/ntp-keygen-opts.c@1.195 +2 -2 + NTP_4_2_5P203 + + util/ntp-keygen-opts.h@1.195 +3 -3 + NTP_4_2_5P203 + + util/ntp-keygen-opts.texi@1.194 +1 -1 + NTP_4_2_5P203 + + util/ntp-keygen.1@1.194 +2 -2 + NTP_4_2_5P203 + +ChangeSet@1.1961, 2009-08-16 17:41:19+00:00, davehart@shiny.ad.hartbrothers.com + Add extra heap-checking calls to atexit-invoked routines + dump -4 and -6 switches to server/peer + use %g printf format instead of %f to trim uninformative zeros + switch enable/disable dumper to correct oddball identifiers + Do not free in-use receive buffers at exit to avoid race for now + + ntpd/ntp_config.c@1.205 +77 -114 + Add extra heap-checking calls to atexit-invoked routines + dump -4 and -6 switches to server/peer + use %g printf format instead of %f to trim uninformative zeros + switch enable/disable dumper to correct oddball identifiers + + ntpd/ntp_util.c@1.74 +7 -0 + Add extra heap-checking calls to atexit-invoked routines + + ports/winnt/ntpd/ntp_iocompletionport.c@1.48 +15 -1 + Do not free in-use receive buffers at exit to avoid race for now + Add extra heap-checking calls to atexit-invoked routines + +ChangeSet@1.1960, 2009-08-16 14:08:44+00:00, hart@pogo.udel.edu + ntp_control.c: + include for S_IRUSR, S_IWUSR + + ntpd/ntp_control.c@1.117 +1 -0 + include for S_IRUSR, S_IWUSR + +ChangeSet@1.1959, 2009-08-16 13:59:26+00:00, davehart@shiny.ad.hartbrothers.com + ntpq -c "dumpcfg ntp.conf.out" works ok for me now + + include/ntp_config.h@1.56 +4 -4 + rename config_tree.prior to link to reflect use + + ntpd/ntp_config.c@1.204 +139 -118 + correct merge with ntp-dev regarding default_ntp_signd_socket + rename config_tree.prior to link to reflect use + dump keysdir, keys, trustedkey, requestkey, controlkey + collapse multiple manycastserver, multicastclient lines to one each + correct tinker, tos, restrict dump code to use oddball identifiers + fix ntpq :config (process correct config tree) + + ntpd/ntp_control.c@1.116 +6 -3 + use macros for open() perm bits, different values on Windows + +ChangeSet@1.1958, 2009-08-16 09:38:50+00:00, davehart@shiny.ad.hartbrothers.com + add dumpcfg ChangeLog entry + fix unix build + + ChangeLog@1.406 +1 -0 + Add ntpq -c dumpcfg, Google Summer of Code project of Max Kuehn + + ntpd/ntp_control.c@1.115 +1 -1 + no MAX_PATH on unix apparently + +ChangeSet@1.1957, 2009-08-16 09:31:04+00:00, hart@pogo.udel.edu + ntp_parser.h, ntp_parser.c: + Bison products + + ntpd/ntp_parser.c@1.41 +950 -960 + Bison products + + ntpd/ntp_parser.h@1.24 +133 -135 + Bison products + +ChangeSet@1.1956, 2009-08-16 09:14:30+00:00, davehart@shiny.ad.hartbrothers.com + ntp_config.c: + use correct union member not union itself + + ntpd/ntp_config.c@1.203 +2 -2 + use correct union member not union itself + +ChangeSet@1.1955, 2009-08-16 09:10:06+00:00, davehart@shiny.ad.hartbrothers.com + preserve peer options queue for dumper + remove remnants of "broadcastclient novolley" + dump correct peer keywords (server, pool, etc) + dump peer options (minpoll, iburst, etc) + quote dumped filenames (better to do so only if needed) + dump only to /var/tmp (unix) or %TEMP% (windows) directories + create dump file with 0600 (owner-only) permission + + include/ntp_config.h@1.55 +1 -5 + preserve peer options queue for dumper + remove remnants of "broadcastclient novolley" + + ntpd/ntp_config.c@1.202 +152 -28 + preserve peer options queue for dumper + remove remnants of "broadcastclient novolley" + dump correct peer keywords (server, pool, etc) + dump peer options (minpoll, iburst, etc) + quote dumped filenames (better to do so only if needed) + + ntpd/ntp_control.c@1.114 +27 -10 + dump only to /var/tmp (unix) or %TEMP% (windows) directories + create dump file with 0600 (owner-only) permission + + ntpd/ntp_parser.y@1.36 +1 -4 + remove remnants of "broadcastclient novolley" + + ports/winnt/include/config.h@1.74 +1 -1 + comment only + +ChangeSet@1.1954, 2009-08-16 04:45:36+00:00, davehart@shiny.ad.hartbrothers.com + more ntp_config.c merge cleanup + + ntpd/ntp_config.c@1.201 +4 -4 + more merge cleanup + +ChangeSet@1.1877.3.11, 2009-08-16 02:58:43+00:00, davehart@shiny.ad.hartbrothers.com + add default: cases to config dumper switch statements + move variable declarations ahead of code for C compliance + use sizeof(buf) not hardcoded constants + + ntpd/ntp_config.c@1.193.1.8 +164 -82 + move variable declarations before code for C compliance + add default: cases to config dumper switch statements + + ntpd/ntp_control.c@1.110.1.3 +9 -10 + use sizeof(buf) not hardcoded constants + + ntpq/ntpq-subs.c@1.30.1.3 +1 -3 + remove unused local a + +ChangeSet@1.1877.3.10, 2009-08-16 02:47:29+09:00, Amidamaru@yumi.mxiesoft.com + ntp_config.h: + Added source and timestamp to the config_tree structure + + include/ntp_config.h@1.52.1.4 +9 -0 + Added source and timestamp to the config_tree structure + +ChangeSet@1.1877.3.9, 2009-08-15 02:15:30+09:00, Amidamaru@yumi.mxiesoft.com + ntp_control.c: + Handling the dumpfile argument of the dumpcfg command + ntp_config.c: + Config dumper: Combined the server and fudge output + ntpq-subs.c: + Added the dumpfile argument to the dumpcfg command + + ntpd/ntp_config.c@1.193.1.7 +38 -5 + Config dumper: Combined the server and fudge output + + ntpd/ntp_control.c@1.110.1.2 +13 -2 + Handling the dumpfile argument of the dumpcfg command + + ntpq/ntpq-subs.c@1.30.1.2 +12 -13 + Added the dumpfile argument to the dumpcfg command + +ChangeSet@1.1952, 2009-08-14 07:51:00-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P202 + TAG: NTP_4_2_5P202 + + ChangeLog@1.405 +1 -0 + NTP_4_2_5P202 + + ntpd/ntpd-opts.c@1.195 +2 -2 + NTP_4_2_5P202 + + ntpd/ntpd-opts.h@1.195 +3 -3 + NTP_4_2_5P202 + + ntpd/ntpd-opts.texi@1.193 +1 -1 + NTP_4_2_5P202 + + ntpd/ntpd.1@1.193 +2 -2 + NTP_4_2_5P202 + + ntpdc/ntpdc-opts.c@1.191 +2 -2 + NTP_4_2_5P202 + + ntpdc/ntpdc-opts.h@1.191 +3 -3 + NTP_4_2_5P202 + + ntpdc/ntpdc-opts.texi@1.190 +1 -1 + NTP_4_2_5P202 + + ntpdc/ntpdc.1@1.190 +2 -2 + NTP_4_2_5P202 + + ntpq/ntpq-opts.c@1.191 +2 -2 + NTP_4_2_5P202 + + ntpq/ntpq-opts.h@1.191 +3 -3 + NTP_4_2_5P202 + + ntpq/ntpq-opts.texi@1.190 +1 -1 + NTP_4_2_5P202 + + ntpq/ntpq.1@1.190 +2 -2 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd-opts.c@1.71 +2 -2 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd-opts.h@1.71 +3 -3 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd-opts.texi@1.71 +1 -1 + NTP_4_2_5P202 + + ntpsnmpd/ntpsnmpd.1@1.71 +2 -2 + NTP_4_2_5P202 + + packageinfo.sh@1.205 +1 -1 + NTP_4_2_5P202 + + sntp/sntp-opts.c@1.65 +2 -2 + NTP_4_2_5P202 + + sntp/sntp-opts.h@1.65 +3 -3 + NTP_4_2_5P202 + + sntp/sntp-opts.texi@1.65 +1 -1 + NTP_4_2_5P202 + + sntp/sntp.1@1.65 +2 -2 + NTP_4_2_5P202 + + util/ntp-keygen-opts.c@1.194 +2 -2 + NTP_4_2_5P202 + + util/ntp-keygen-opts.h@1.194 +3 -3 + NTP_4_2_5P202 + + util/ntp-keygen-opts.texi@1.193 +1 -1 + NTP_4_2_5P202 + + util/ntp-keygen.1@1.193 +2 -2 + NTP_4_2_5P202 + +ChangeSet@1.1951, 2009-08-13 16:27:44-04:00, stenn@whimsy.udel.edu + install the binary and man page for sntp + + ChangeLog@1.404 +1 -0 + install the binary and man page for sntp + + sntp/Makefile.am@1.10 +7 -11 + install the binary and man page for sntp + +ChangeSet@1.1950, 2009-08-13 07:57:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P201 + TAG: NTP_4_2_5P201 + + ChangeLog@1.403 +1 -0 + NTP_4_2_5P201 + + ntpd/ntpd-opts.c@1.194 +2 -2 + NTP_4_2_5P201 + + ntpd/ntpd-opts.h@1.194 +3 -3 + NTP_4_2_5P201 + + ntpd/ntpd-opts.texi@1.192 +1 -1 + NTP_4_2_5P201 + + ntpd/ntpd.1@1.192 +2 -2 + NTP_4_2_5P201 + + ntpdc/ntpdc-opts.c@1.190 +2 -2 + NTP_4_2_5P201 + + ntpdc/ntpdc-opts.h@1.190 +3 -3 + NTP_4_2_5P201 + + ntpdc/ntpdc-opts.texi@1.189 +1 -1 + NTP_4_2_5P201 + + ntpdc/ntpdc.1@1.189 +2 -2 + NTP_4_2_5P201 + + ntpq/ntpq-opts.c@1.190 +2 -2 + NTP_4_2_5P201 + + ntpq/ntpq-opts.h@1.190 +3 -3 + NTP_4_2_5P201 + + ntpq/ntpq-opts.texi@1.189 +1 -1 + NTP_4_2_5P201 + + ntpq/ntpq.1@1.189 +2 -2 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd-opts.c@1.70 +2 -2 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd-opts.h@1.70 +3 -3 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd-opts.texi@1.70 +1 -1 + NTP_4_2_5P201 + + ntpsnmpd/ntpsnmpd.1@1.70 +2 -2 + NTP_4_2_5P201 + + packageinfo.sh@1.204 +1 -1 + NTP_4_2_5P201 + + sntp/sntp-opts.c@1.64 +1 -1 + NTP_4_2_5P201 + + sntp/sntp-opts.h@1.64 +1 -1 + NTP_4_2_5P201 + + sntp/sntp-opts.texi@1.64 +1 -1 + NTP_4_2_5P201 + + sntp/sntp.1@1.64 +2 -2 + NTP_4_2_5P201 + + util/ntp-keygen-opts.c@1.193 +2 -2 + NTP_4_2_5P201 + + util/ntp-keygen-opts.h@1.193 +3 -3 + NTP_4_2_5P201 + + util/ntp-keygen-opts.texi@1.192 +1 -1 + NTP_4_2_5P201 + + util/ntp-keygen.1@1.192 +2 -2 + NTP_4_2_5P201 + +ChangeSet@1.1947.1.1, 2009-08-12 07:57:54-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P200 + TAG: NTP_4_2_5P200 + + ChangeLog@1.400.1.1 +1 -0 + NTP_4_2_5P200 + + gsoc_sntp/sntp-opts.c@1.61.1.1 +2 -2 + NTP_4_2_5P200 + + gsoc_sntp/sntp-opts.h@1.61.1.1 +3 -3 + NTP_4_2_5P200 + + gsoc_sntp/sntp-opts.texi@1.61.1.1 +1 -1 + NTP_4_2_5P200 + + gsoc_sntp/sntp.1@1.61.1.1 +2 -2 + NTP_4_2_5P200 + + ntpd/ntpd-opts.c@1.193 +2 -2 + NTP_4_2_5P200 + + ntpd/ntpd-opts.h@1.193 +3 -3 + NTP_4_2_5P200 + + ntpd/ntpd-opts.texi@1.191 +1 -1 + NTP_4_2_5P200 + + ntpd/ntpd.1@1.191 +2 -2 + NTP_4_2_5P200 + + ntpdc/ntpdc-opts.c@1.189 +2 -2 + NTP_4_2_5P200 + + ntpdc/ntpdc-opts.h@1.189 +3 -3 + NTP_4_2_5P200 + + ntpdc/ntpdc-opts.texi@1.188 +1 -1 + NTP_4_2_5P200 + + ntpdc/ntpdc.1@1.188 +2 -2 + NTP_4_2_5P200 + + ntpq/ntpq-opts.c@1.189 +2 -2 + NTP_4_2_5P200 + + ntpq/ntpq-opts.h@1.189 +3 -3 + NTP_4_2_5P200 + + ntpq/ntpq-opts.texi@1.188 +1 -1 + NTP_4_2_5P200 + + ntpq/ntpq.1@1.188 +2 -2 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd-opts.c@1.69 +2 -2 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd-opts.h@1.69 +3 -3 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd-opts.texi@1.69 +1 -1 + NTP_4_2_5P200 + + ntpsnmpd/ntpsnmpd.1@1.69 +2 -2 + NTP_4_2_5P200 + + packageinfo.sh@1.203 +1 -1 + NTP_4_2_5P200 + + sntp/sntp-opts.c@1.188.1.1 +2 -2 + NTP_4_2_5P200 + + sntp/sntp-opts.h@1.188.1.1 +3 -3 + NTP_4_2_5P200 + + sntp/sntp-opts.texi@1.187.1.1 +1 -1 + NTP_4_2_5P200 + + sntp/sntp.1@1.187.1.1 +2 -2 + NTP_4_2_5P200 + + util/ntp-keygen-opts.c@1.192 +2 -2 + NTP_4_2_5P200 + + util/ntp-keygen-opts.h@1.192 +3 -3 + NTP_4_2_5P200 + + util/ntp-keygen-opts.texi@1.191 +1 -1 + NTP_4_2_5P200 + + util/ntp-keygen.1@1.191 +2 -2 + NTP_4_2_5P200 + +ChangeSet@1.1948, 2009-08-12 07:09:37-04:00, stenn@whimsy.udel.edu + sntp: out with the old, in with the new + + .point-changed-filelist@1.6 +0 -4 + sntp: out with the old, in with the new + + BitKeeper/deleted/.del-COPYING.gplv3@1.2 +0 -0 + Delete: sntp/libopts/COPYING.gplv3 + + BitKeeper/deleted/.del-COPYING.lgplv3@1.2 +0 -0 + Delete: sntp/libopts/COPYING.lgplv3 + + BitKeeper/deleted/.del-COPYING.mbsd~dfd1a50aaa7f1a01@1.2 +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYRIGHT@1.3 +0 -0 + Delete: sntp/COPYRIGHT + + BitKeeper/deleted/.del-MakeDefs.inc~f7b11e92a11b82c@1.2 +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~7eb131bb540e19f2@1.26 +0 -0 + Delete: sntp/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~84a984572db47579@1.2 +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Mf@1.2 +0 -0 + Delete: sntp/Mf + + BitKeeper/deleted/.del-README~9ce987ed19d4905a@1.3 +0 -0 + Delete: sntp/README + + BitKeeper/deleted/.del-README~cb95e57599607dd8@1.3 +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-RFC2030.TXT@1.2 +0 -0 + Delete: sntp/RFC2030.TXT + + BitKeeper/deleted/.del-RFC4330.TXT@1.2 +0 -0 + Delete: sntp/RFC4330.TXT + + BitKeeper/deleted/.del-ag-char-map.h@1.5 +0 -0 + Delete: sntp/libopts/ag-char-map.h + + BitKeeper/deleted/.del-autoopts.c~524f4366bd5298d@1.4 +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~8da4370be20d3b14@1.4 +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~b7c57a2b81d3da1d@1.4 +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~e2f82823ab217382@1.4 +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~107d2e38a77fa938@1.4 +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-configure.ac@1.24 +0 -0 + Delete: sntp/configure.ac + + BitKeeper/deleted/.del-cook.c~dabc0ea67f8d04b@1.4 +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-draft-mills-sntp-v4-00.txt@1.2 +0 -0 + Delete: sntp/draft-mills-sntp-v4-00.txt + + BitKeeper/deleted/.del-enumeration.c~bb2f678a6e7847e4@1.4 +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~a4572011a478e1f8@1.5 +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-file.c@1.4 +0 -0 + Delete: sntp/libopts/file.c + + BitKeeper/deleted/.del-genshell.c~b902390cefc557fe@1.5 +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~3aefffa4f2e6155e@1.5 +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-header.h@1.7 +0 -0 + Delete: sntp/header.h + + BitKeeper/deleted/.del-internet.c@1.5 +0 -0 + Delete: sntp/internet.c + + BitKeeper/deleted/.del-internet.h@1.4 +0 -0 + Delete: sntp/internet.h + + BitKeeper/deleted/.del-kludges.h@1.2 +0 -0 + Delete: sntp/kludges.h + + BitKeeper/deleted/.del-libopts.c~fa546a962604b990@1.2 +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~cea4d9dfe3c6ddbf@1.5 +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~3a61aba4c71ee48a@1.4 +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~d526b4ded3e5d941@1.4 +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-ltmain.sh@1.2 +0 -0 + Delete: sntp/ltmain.sh + + BitKeeper/deleted/.del-main.c@1.11 +0 -0 + Delete: sntp/main.c + + BitKeeper/deleted/.del-makeshell.c~dcec62d7527150f2@1.4 +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~9a65b1b3c71987c2@1.4 +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~6843f965b3b4e5d4@1.4 +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-options.h~756b87b5d8493503@1.5 +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-parse-duration.c@1.2 +0 -0 + Delete: sntp/libopts/parse-duration.c + + BitKeeper/deleted/.del-parse-duration.h@1.2 +0 -0 + Delete: sntp/libopts/parse-duration.h + + BitKeeper/deleted/.del-pathfind.c~d124c4b9c98df625@1.4 +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~7f2f61c96b4f690@1.4 +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~3f55e562dfc99640@1.5 +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~6ddb7f83260a15cb@1.4 +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-reset.c@1.4 +0 -0 + Delete: sntp/libopts/reset.c + + BitKeeper/deleted/.del-restore.c~36055bf073cf20d2@1.4 +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-save.c~818d9fbdc6efce79@1.5 +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~e2a566791af51ab1@1.2 +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sntp-opts.c~4bdc915913c58b8d@1.189 +0 -0 + Delete: sntp/sntp-opts.c + + BitKeeper/deleted/.del-sntp-opts.def@1.13 +0 -0 + Delete: sntp/sntp-opts.def + + BitKeeper/deleted/.del-sntp-opts.h~6c9afb942ebc8da5@1.189 +0 -0 + Delete: sntp/sntp-opts.h + + BitKeeper/deleted/.del-sntp-opts.menu@1.5 +0 -0 + Delete: sntp/sntp-opts.menu + + BitKeeper/deleted/.del-sntp-opts.texi~a472a50d2839eadc@1.188 +0 -0 + Delete: sntp/sntp-opts.texi + + BitKeeper/deleted/.del-sntp.1~852b6b2cb9eef68@1.188 +0 -0 + Delete: sntp/sntp.1 + + BitKeeper/deleted/.del-socket.c@1.9 +0 -0 + Delete: sntp/socket.c + + BitKeeper/deleted/.del-sort.c~2b3c290f2056ef51@1.4 +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-stack.c~275738ac7e7d319d@1.4 +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~1aac99425a598121@1.2 +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~5fa61194752a37e3@1.2 +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~e58f9bd033a84719@1.4 +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~7c49bd8e3f86066f@1.4 +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-time.c@1.4 +0 -0 + Delete: sntp/libopts/time.c + + BitKeeper/deleted/.del-timing.c@1.4 +0 -0 + Delete: sntp/timing.c + + BitKeeper/deleted/.del-tokenize.c~be5669e7aebf805@1.3 +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-unix.c@1.4 +0 -0 + Delete: sntp/unix.c + + BitKeeper/deleted/.del-usage-txt.h~e9f5b7f89caa54c2@1.5 +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~84e8c04ecb3c0839@1.4 +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-value-type.c@1.3 +0 -0 + Delete: sntp/libopts/value-type.c + + BitKeeper/deleted/.del-value-type.h@1.5 +0 -0 + Delete: sntp/libopts/value-type.h + + BitKeeper/deleted/.del-version.c~f331be699b32ed05@1.4 +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~c97f2a667a4b84f5@1.4 +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + BitKeeper/deleted/.del-xat-attribute.c@1.3 +0 -0 + Delete: sntp/libopts/xat-attribute.c + + BitKeeper/deleted/.del-xat-attribute.h@1.5 +0 -0 + Delete: sntp/libopts/xat-attribute.h + + ChangeLog@1.401 +1 -0 + sntp: out with the old, in with the new + + Makefile.am@1.81 +0 -2 + sntp: out with the old, in with the new + + bootstrap@1.23 +0 -1 + sntp: out with the old, in with the new + + configure.ac@1.448 +0 -1 + sntp: out with the old, in with the new + + sntp/COPYRIGHT@1.2 +0 -0 + Rename: gsoc_sntp/COPYRIGHT -> sntp/COPYRIGHT + + sntp/Makefile.am@1.9 +0 -0 + Rename: gsoc_sntp/Makefile.am -> sntp/Makefile.am + + sntp/configure.ac@1.18 +0 -0 + Rename: gsoc_sntp/configure.ac -> sntp/configure.ac + + sntp/crypto.c@1.7 +0 -0 + Rename: gsoc_sntp/crypto.c -> sntp/crypto.c + + sntp/crypto.h@1.5 +0 -0 + Rename: gsoc_sntp/crypto.h -> sntp/crypto.h + + sntp/data_formats.h@1.5 +0 -0 + Rename: gsoc_sntp/data_formats.h -> sntp/data_formats.h + + sntp/fetch-stubs@1.6 +0 -0 + Rename: gsoc_sntp/fetch-stubs -> sntp/fetch-stubs + + sntp/header.h@1.4 +0 -0 + Rename: gsoc_sntp/header.h -> sntp/header.h + + sntp/kod_management.c@1.10 +0 -0 + Rename: gsoc_sntp/kod_management.c -> sntp/kod_management.c + + sntp/kod_management.h@1.6 +0 -0 + Rename: gsoc_sntp/kod_management.h -> sntp/kod_management.h + + sntp/libopts/COPYING.gplv3@1.2 +0 -0 + Rename: gsoc_sntp/libopts/COPYING.gplv3 -> sntp/libopts/COPYING.gplv3 + + sntp/libopts/COPYING.lgplv3@1.2 +0 -0 + Rename: gsoc_sntp/libopts/COPYING.lgplv3 -> sntp/libopts/COPYING.lgplv3 + + sntp/libopts/COPYING.mbsd@1.2 +0 -0 + Rename: gsoc_sntp/libopts/COPYING.mbsd -> sntp/libopts/COPYING.mbsd + + sntp/libopts/MakeDefs.inc@1.2 +0 -0 + Rename: gsoc_sntp/libopts/MakeDefs.inc -> sntp/libopts/MakeDefs.inc + + sntp/libopts/Makefile.am@1.2 +0 -0 + Rename: gsoc_sntp/libopts/Makefile.am -> sntp/libopts/Makefile.am + + sntp/libopts/README@1.3 +0 -0 + Rename: gsoc_sntp/libopts/README -> sntp/libopts/README + + sntp/libopts/ag-char-map.h@1.5 +0 -0 + Rename: gsoc_sntp/libopts/ag-char-map.h -> sntp/libopts/ag-char-map.h + + sntp/libopts/autoopts.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/autoopts.c -> sntp/libopts/autoopts.c + + sntp/libopts/autoopts.h@1.4 +0 -0 + Rename: gsoc_sntp/libopts/autoopts.h -> sntp/libopts/autoopts.h + + sntp/libopts/autoopts/options.h@1.5 +0 -0 + Rename: gsoc_sntp/libopts/autoopts/options.h -> sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/usage-txt.h@1.5 +0 -0 + Rename: gsoc_sntp/libopts/autoopts/usage-txt.h -> sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/boolean.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/boolean.c -> sntp/libopts/boolean.c + + sntp/libopts/compat/compat.h@1.4 +0 -0 + Rename: gsoc_sntp/libopts/compat/compat.h -> sntp/libopts/compat/compat.h + + sntp/libopts/compat/pathfind.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/compat/pathfind.c -> sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/snprintf.c@1.2 +0 -0 + Rename: gsoc_sntp/libopts/compat/snprintf.c -> sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/strchr.c@1.2 +0 -0 + Rename: gsoc_sntp/libopts/compat/strchr.c -> sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strdup.c@1.2 +0 -0 + Rename: gsoc_sntp/libopts/compat/strdup.c -> sntp/libopts/compat/strdup.c + + sntp/libopts/compat/windows-config.h@1.4 +0 -0 + Rename: gsoc_sntp/libopts/compat/windows-config.h -> sntp/libopts/compat/windows-config.h + + sntp/libopts/configfile.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/configfile.c -> sntp/libopts/configfile.c + + sntp/libopts/cook.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/cook.c -> sntp/libopts/cook.c + + sntp/libopts/enumeration.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/enumeration.c -> sntp/libopts/enumeration.c + + sntp/libopts/environment.c@1.5 +0 -0 + Rename: gsoc_sntp/libopts/environment.c -> sntp/libopts/environment.c + + sntp/libopts/file.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/file.c -> sntp/libopts/file.c + + sntp/libopts/genshell.c@1.5 +0 -0 + Rename: gsoc_sntp/libopts/genshell.c -> sntp/libopts/genshell.c + + sntp/libopts/genshell.h@1.5 +0 -0 + Rename: gsoc_sntp/libopts/genshell.h -> sntp/libopts/genshell.h + + sntp/libopts/libopts.c@1.2 +0 -0 + Rename: gsoc_sntp/libopts/libopts.c -> sntp/libopts/libopts.c + + sntp/libopts/load.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/load.c -> sntp/libopts/load.c + + sntp/libopts/m4/libopts.m4@1.5 +0 -0 + Rename: gsoc_sntp/libopts/m4/libopts.m4 -> sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/liboptschk.m4@1.4 +0 -0 + Rename: gsoc_sntp/libopts/m4/liboptschk.m4 -> sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/makeshell.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/makeshell.c -> sntp/libopts/makeshell.c + + sntp/libopts/nested.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/nested.c -> sntp/libopts/nested.c + + sntp/libopts/numeric.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/numeric.c -> sntp/libopts/numeric.c + + sntp/libopts/parse-duration.c@1.2 +0 -0 + Rename: gsoc_sntp/libopts/parse-duration.c -> sntp/libopts/parse-duration.c + + sntp/libopts/parse-duration.h@1.2 +0 -0 + Rename: gsoc_sntp/libopts/parse-duration.h -> sntp/libopts/parse-duration.h + + sntp/libopts/pgusage.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/pgusage.c -> sntp/libopts/pgusage.c + + sntp/libopts/proto.h@1.5 +0 -0 + Rename: gsoc_sntp/libopts/proto.h -> sntp/libopts/proto.h + + sntp/libopts/putshell.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/putshell.c -> sntp/libopts/putshell.c + + sntp/libopts/reset.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/reset.c -> sntp/libopts/reset.c + + sntp/libopts/restore.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/restore.c -> sntp/libopts/restore.c + + sntp/libopts/save.c@1.5 +0 -0 + Rename: gsoc_sntp/libopts/save.c -> sntp/libopts/save.c + + sntp/libopts/sort.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/sort.c -> sntp/libopts/sort.c + + sntp/libopts/stack.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/stack.c -> sntp/libopts/stack.c + + sntp/libopts/streqvcmp.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/streqvcmp.c -> sntp/libopts/streqvcmp.c + + sntp/libopts/text_mmap.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/text_mmap.c -> sntp/libopts/text_mmap.c + + sntp/libopts/time.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/time.c -> sntp/libopts/time.c + + sntp/libopts/tokenize.c@1.3 +0 -0 + Rename: gsoc_sntp/libopts/tokenize.c -> sntp/libopts/tokenize.c + + sntp/libopts/usage.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/usage.c -> sntp/libopts/usage.c + + sntp/libopts/value-type.c@1.3 +0 -0 + Rename: gsoc_sntp/libopts/value-type.c -> sntp/libopts/value-type.c + + sntp/libopts/value-type.h@1.5 +0 -0 + Rename: gsoc_sntp/libopts/value-type.h -> sntp/libopts/value-type.h + + sntp/libopts/version.c@1.4 +0 -0 + Rename: gsoc_sntp/libopts/version.c -> sntp/libopts/version.c + + sntp/libopts/xat-attribute.c@1.3 +0 -0 + Rename: gsoc_sntp/libopts/xat-attribute.c -> sntp/libopts/xat-attribute.c + + sntp/libopts/xat-attribute.h@1.5 +0 -0 + Rename: gsoc_sntp/libopts/xat-attribute.h -> sntp/libopts/xat-attribute.h + + sntp/log.c@1.9 +0 -0 + Rename: gsoc_sntp/log.c -> sntp/log.c + + sntp/log.h@1.6 +0 -0 + Rename: gsoc_sntp/log.h -> sntp/log.h + + sntp/ltmain.sh@1.2 +0 -0 + Rename: gsoc_sntp/ltmain.sh -> sntp/ltmain.sh + + sntp/main.c@1.17 +0 -0 + Rename: gsoc_sntp/main.c -> sntp/main.c + + sntp/netutils.c@1.2 +0 -0 + Rename: gsoc_sntp/netutils.c -> sntp/netutils.c + + sntp/netutils.h@1.2 +0 -0 + Rename: gsoc_sntp/netutils.h -> sntp/netutils.h + + sntp/networking.c@1.23 +0 -0 + Rename: gsoc_sntp/networking.c -> sntp/networking.c + + sntp/networking.h@1.14 +0 -0 + Rename: gsoc_sntp/networking.h -> sntp/networking.h + + sntp/sntp-opts.c@1.62 +0 -0 + Rename: gsoc_sntp/sntp-opts.c -> sntp/sntp-opts.c + + sntp/sntp-opts.def@1.10 +0 -0 + Rename: gsoc_sntp/sntp-opts.def -> sntp/sntp-opts.def + + sntp/sntp-opts.h@1.62 +0 -0 + Rename: gsoc_sntp/sntp-opts.h -> sntp/sntp-opts.h + + sntp/sntp-opts.menu@1.2 +0 -0 + Rename: gsoc_sntp/sntp-opts.menu -> sntp/sntp-opts.menu + + sntp/sntp-opts.texi@1.62 +0 -0 + Rename: gsoc_sntp/sntp-opts.texi -> sntp/sntp-opts.texi + + sntp/sntp.1@1.62 +0 -0 + Rename: gsoc_sntp/sntp.1 -> sntp/sntp.1 + + sntp/utilities.c@1.8 +0 -0 + Rename: gsoc_sntp/utilities.c -> sntp/utilities.c + + sntp/utilities.h@1.6 +0 -0 + Rename: gsoc_sntp/utilities.h -> sntp/utilities.h + +ChangeSet@1.1877.3.7, 2009-08-12 17:25:58+09:00, Amidamaru@yumi.mxiesoft.com + ntp_config.c: + Config dumper: Added fudge output to server/peer output + + ntpd/ntp_config.c@1.193.1.6 +96 -78 + Config dumper: Added fudge output to server/peer output + +ChangeSet@1.1877.4.1, 2009-08-12 17:09:40+09:00, Amidamaru@yumi.mxiesoft.com + ntp_control.c: + Added handler for dump opcode + + ntpd/ntp_control.c@1.110.1.1 +25 -0 + Added handler for dump opcode + +ChangeSet@1.1947, 2009-08-10 23:09:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1281] Build ntpd on Windows without big SDK download, burn, + and install by checking in essentially unchanging messages.mc build + products to avoid requiring mc.exe, which is not included with VC++ + 2008 EE. + + ChangeLog@1.400 +4 -0 + [Bug 1281] Build ntpd on Windows without big SDK download, burn, + and install by checking in essentially unchanging messages.mc build + products to avoid requiring mc.exe, which is not included with VC++ + 2008 EE. + + ports/winnt/libntp/MSG00001.bin@1.1 +4 -0 + BitKeeper file C:/ntp/ntp-dev-1281/ports/winnt/libntp/MSG00001.bin + + ports/winnt/libntp/MSG00001.bin@1.0 +0 -0 + + ports/winnt/libntp/messages.h@1.1 +199 -0 + BitKeeper file C:/ntp/ntp-dev-1281/ports/winnt/libntp/messages.h + + ports/winnt/libntp/messages.h@1.0 +0 -0 + + ports/winnt/libntp/messages.rc@1.1 +2 -0 + BitKeeper file C:/ntp/ntp-dev-1281/ports/winnt/libntp/messages.rc + + ports/winnt/libntp/messages.rc@1.0 +0 -0 + +ChangeSet@1.1946, 2009-08-09 07:55:30-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P199 + TAG: NTP_4_2_5P199 + + ChangeLog@1.399 +1 -0 + NTP_4_2_5P199 + + gsoc_sntp/sntp-opts.c@1.61 +2 -2 + NTP_4_2_5P199 + + gsoc_sntp/sntp-opts.h@1.61 +3 -3 + NTP_4_2_5P199 + + gsoc_sntp/sntp-opts.texi@1.61 +1 -1 + NTP_4_2_5P199 + + gsoc_sntp/sntp.1@1.61 +2 -2 + NTP_4_2_5P199 + + ntpd/ntpd-opts.c@1.192 +2 -2 + NTP_4_2_5P199 + + ntpd/ntpd-opts.h@1.192 +3 -3 + NTP_4_2_5P199 + + ntpd/ntpd-opts.texi@1.190 +1 -1 + NTP_4_2_5P199 + + ntpd/ntpd.1@1.190 +2 -2 + NTP_4_2_5P199 + + ntpdc/ntpdc-opts.c@1.188 +2 -2 + NTP_4_2_5P199 + + ntpdc/ntpdc-opts.h@1.188 +3 -3 + NTP_4_2_5P199 + + ntpdc/ntpdc-opts.texi@1.187 +1 -1 + NTP_4_2_5P199 + + ntpdc/ntpdc.1@1.187 +2 -2 + NTP_4_2_5P199 + + ntpq/ntpq-opts.c@1.188 +2 -2 + NTP_4_2_5P199 + + ntpq/ntpq-opts.h@1.188 +3 -3 + NTP_4_2_5P199 + + ntpq/ntpq-opts.texi@1.187 +1 -1 + NTP_4_2_5P199 + + ntpq/ntpq.1@1.187 +2 -2 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd-opts.c@1.68 +2 -2 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd-opts.h@1.68 +3 -3 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd-opts.texi@1.68 +1 -1 + NTP_4_2_5P199 + + ntpsnmpd/ntpsnmpd.1@1.68 +2 -2 + NTP_4_2_5P199 + + packageinfo.sh@1.202 +1 -1 + NTP_4_2_5P199 + + sntp/sntp-opts.c@1.188 +2 -2 + NTP_4_2_5P199 + + sntp/sntp-opts.h@1.188 +3 -3 + NTP_4_2_5P199 + + sntp/sntp-opts.texi@1.187 +1 -1 + NTP_4_2_5P199 + + sntp/sntp.1@1.187 +2 -2 + NTP_4_2_5P199 + + util/ntp-keygen-opts.c@1.191 +2 -2 + NTP_4_2_5P199 + + util/ntp-keygen-opts.h@1.191 +3 -3 + NTP_4_2_5P199 + + util/ntp-keygen-opts.texi@1.190 +1 -1 + NTP_4_2_5P199 + + util/ntp-keygen.1@1.190 +2 -2 + NTP_4_2_5P199 + +ChangeSet@1.1945, 2009-08-08 16:39:12-04:00, stenn@whimsy.udel.edu + [Bug 1279] Cleanup for warnings from Veracode static analysis + + ChangeLog@1.398 +1 -0 + [Bug 1279] Cleanup for warnings from Veracode static analysis + +ChangeSet@1.1944, 2009-08-08 17:30:14+00:00, davehart@shiny.ad.hartbrothers.com + First pass at quieting Veracode static analysis warnings, + mostly buffer manipulation that is already safe but used + unsafe interface functions such as strcpy() and sprintf(). + use emalloc(), estrdup() where appropriate. + + libntp/msyslog.c@1.23 +7 -6 + use memcpy instead of strcpy to quiet Veracode analysis warning + + libntp/ntp_rfc2553.c@1.39 +2 -6 + use estrdup() instead of malloc() then strcpy() + + libntp/statestr.c@1.17 +5 -4 + sprintf() -> snprintf() Veracode + + libparse/parse.c@1.13 +1 -1 + See if cast is enough to quiet Veracode int truncation warning + + ntpd/ntp_config.c@1.199 +7 -3 + sprintf()->snprintf() + check for unlink() failure + + ntpd/ntp_control.c@1.112 +28 -27 + strcpy() + strcat() -> snprintf() + strcpy() -> memcpy() + correct 'be" buffer end calculations + + ntpd/ntp_intres.c@1.64 +7 -3 + check for unlink() failure + ensure zero termination with strncpy() + + ntpd/ntp_io.c@1.295 +1 -0 + ensure null termination with strncpy + + ntpd/ntp_scanner.c@1.22 +30 -5 + bounds-check access to yytext[] + + ntpd/ntp_signd.c@1.2 +1 -4 + use emalloc() + + ntpd/ntp_util.c@1.73 +8 -3 + check for rename(), _unlink() failures + + ntpd/ntpd.c@1.106 +7 -3 + add chdir("/") after chroot(), can't hurt and Veracode wants it + + ntpd/refclock_acts.c@1.36 +0 -3 + emalloc() never returns NULL + + ntpd/refclock_bancomm.c@1.11 +2 -3 + use emalloc() + + ntpd/refclock_datum.c@1.13 +1 -1 + use emalloc() + + ntpd/refclock_oncore.c@1.78 +7 -24 + use emalloc() + + ntpdate/ntpdate.c@1.68 +1 -1 + use emalloc() + + ntpdc/ntpdc.c@1.67 +1 -5 + use emalloc() + + ntpq/ntpq-subs.c@1.32 +2 -26 + remove strsave from ntpq, same as libntp's estrdup() + + ports/winnt/libisc/isc_strerror.c@1.8 +9 -6 + use emalloc() + #undef our strerror() before calling the CRT version, infinite + recursion is no fun + + ports/winnt/ntpd/ntp_iocompletionport.c@1.47 +8 -5 + calloc() -> emalloc() then memset zero + +ChangeSet@1.1877.3.6, 2009-08-06 12:04:59+00:00, davehart@shiny.ad.hartbrothers.com + maintain history of config trees + + include/ntp_config.h@1.52.1.3 +2 -40 + remove unused leftovers, add list link field to struct config_tree + + include/ntp_data_structures.h@1.5 +0 -8 + remove unused s_list + + libntp/ntp_lineedit.c@1.7 +4 -5 + use estrdup() instead of strdup() + + ntpd/ntp_config.c@1.193.1.5 +112 -79 + maintain history of config trees + + ntpd/ntp_data_structures.c@1.11 +5 -2 + make next_node() actually work + + ntpd/ntp_parser.c@1.38.1.1 +50 -50 + parse to struct config_tree cfgt rather than my_config + + ntpd/ntp_parser.y@1.33.1.1 +50 -50 + parse to struct config_tree cfgt rather than my_config + + ntpd/ntp_scanner.h@1.7 +4 -4 + parse to struct config_tree cfgt rather than my_config + +ChangeSet@1.1877.3.5, 2009-08-05 21:13:22+00:00, davehart@shiny.ad.hartbrothers.com + separate consumption (freeing) of syntax tree from application + by introducing free_config_*() routines for each config_*() + which allocates memory pointed to by a node. + + include/ntpd.h@1.127.1.1 +1 -1 + make sizeof(sys_ttl) work + + ntpd/ntp_config.c@1.193.1.4 +526 -194 + separate consumption (freeing) of syntax tree from application + by introducing free_config_*() routines for each config_*() + which allocates memory pointed to by a node. + + ntpd/ntp_filegen.c@1.16 +4 -2 + use bounded copy function (memcpy instead of strcpy) + +ChangeSet@1.1877.3.4, 2009-08-05 14:26:32+00:00, davehart@shiny.ad.hartbrothers.com + Dump from config tree not s_list clone + + include/ntp_config.h@1.52.1.2 +1 -1 + Dump from config tree not clone + + include/ntp_data_structures.h@1.4 +2 -2 + add routines to walk queue without destroying + + ntpd/ntp_config.c@1.193.1.3 +389 -402 + lay groundwork for keeping list of config trees, one from file then + one from each ntpq :config + + ntpd/ntp_data_structures.c@1.10 +27 -48 + add routines to walk queue without destroying + +ChangeSet@1.1877.3.3, 2009-08-05 00:45:45+00:00, davehart@shiny.ad.hartbrothers.com + fix problems compiling as C with Visual C++ + + ntpd/ntp_config.c@1.193.1.2 +20 -15 + fix problems compiling as C with Visual C++ + + ntpd/ntp_data_structures.c@1.9 +10 -6 + fix problems compiling as C with Visual C++ + +ChangeSet@1.1877.3.2, 2009-08-04 19:40:02+02:00, amidamaru@melchior.mxiesoft.com + ntp_control.h: + Added dumpcfg bindings + + include/ntp_control.h@1.34.1.1 +1 -0 + Added dumpcfg bindings + +ChangeSet@1.1877.3.1, 2009-08-04 17:31:42+02:00, amidamaru@melchior.mxiesoft.com + ntp_data_structures.h: + Added singly-linked list datatype s_list + ntp_data_structures.c: + Added functions for dealing with singly linked lists + ntp_config.c: + Added config dumper and functions dealing with the linked-list copy of the configuration tree + ntpq-subs.c: + Added config dumper bindings + ntp_config.h: + Added config dumper prototypes + + include/ntp_config.h@1.52.1.1 +43 -0 + Added config dumper prototypes + + include/ntp_data_structures.h@1.3 +10 -0 + Added singly-linked list datatype s_list + + ntpd/ntp_config.c@1.193.1.1 +891 -31 + Added config dumper and functions dealing with the linked-list copy of the configuration tree + + ntpd/ntp_data_structures.c@1.8 +44 -0 + Added functions for dealing with singly linked lists + + ntpq/ntpq-subs.c@1.30.1.1 +33 -1 + Added config dumper bindings + +ChangeSet@1.1943, 2009-08-03 08:00:33-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P198 + TAG: NTP_4_2_5P198 + + ChangeLog@1.397 +1 -0 + NTP_4_2_5P198 + + gsoc_sntp/sntp-opts.c@1.60 +3 -3 + NTP_4_2_5P198 + + gsoc_sntp/sntp-opts.h@1.60 +4 -4 + NTP_4_2_5P198 + + gsoc_sntp/sntp-opts.texi@1.60 +1 -1 + NTP_4_2_5P198 + + gsoc_sntp/sntp.1@1.60 +2 -2 + NTP_4_2_5P198 + + ntpd/ntpd-opts.c@1.191 +3 -3 + NTP_4_2_5P198 + + ntpd/ntpd-opts.h@1.191 +4 -4 + NTP_4_2_5P198 + + ntpd/ntpd-opts.texi@1.189 +1 -1 + NTP_4_2_5P198 + + ntpd/ntpd.1@1.189 +2 -2 + NTP_4_2_5P198 + + ntpdc/ntpdc-opts.c@1.187 +3 -3 + NTP_4_2_5P198 + + ntpdc/ntpdc-opts.h@1.187 +4 -4 + NTP_4_2_5P198 + + ntpdc/ntpdc-opts.texi@1.186 +1 -1 + NTP_4_2_5P198 + + ntpdc/ntpdc.1@1.186 +2 -2 + NTP_4_2_5P198 + + ntpq/ntpq-opts.c@1.187 +3 -3 + NTP_4_2_5P198 + + ntpq/ntpq-opts.h@1.187 +4 -4 + NTP_4_2_5P198 + + ntpq/ntpq-opts.texi@1.186 +1 -1 + NTP_4_2_5P198 + + ntpq/ntpq.1@1.186 +2 -2 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd-opts.c@1.67 +3 -3 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd-opts.h@1.67 +4 -4 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd-opts.texi@1.67 +1 -1 + NTP_4_2_5P198 + + ntpsnmpd/ntpsnmpd.1@1.67 +2 -2 + NTP_4_2_5P198 + + packageinfo.sh@1.201 +1 -1 + NTP_4_2_5P198 + + sntp/sntp-opts.c@1.187 +3 -3 + NTP_4_2_5P198 + + sntp/sntp-opts.h@1.187 +4 -4 + NTP_4_2_5P198 + + sntp/sntp-opts.texi@1.186 +1 -1 + NTP_4_2_5P198 + + sntp/sntp.1@1.186 +2 -2 + NTP_4_2_5P198 + + util/ntp-keygen-opts.c@1.190 +3 -3 + NTP_4_2_5P198 + + util/ntp-keygen-opts.h@1.190 +4 -4 + NTP_4_2_5P198 + + util/ntp-keygen-opts.texi@1.189 +1 -1 + NTP_4_2_5P198 + + util/ntp-keygen.1@1.189 +2 -2 + NTP_4_2_5P198 + +ChangeSet@1.1940.1.1, 2009-08-03 01:32:51-04:00, stenn@whimsy.udel.edu + Upgraded to autogen-5.9.9-pre5 + + ChangeLog@1.396 +1 -0 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/ag-char-map.h@1.4 +37 -6 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts.h@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts/options.h@1.4 +34 -40 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/boolean.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/compat/compat.h@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/compat/pathfind.c@1.3 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/compat/windows-config.h@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/configfile.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/cook.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/enumeration.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/environment.c@1.4 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/file.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/genshell.c@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/genshell.h@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/load.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/m4/libopts.m4@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/makeshell.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/nested.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/numeric.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/pgusage.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/proto.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/putshell.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/reset.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/restore.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/save.c@1.4 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/sort.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/stack.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/streqvcmp.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/text_mmap.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/time.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/tokenize.c@1.2 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/usage.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/value-type.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/version.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + gsoc_sntp/libopts/xat-attribute.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/ag-char-map.h@1.4 +37 -6 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts.h@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts/options.h@1.4 +34 -40 + Upgraded to autogen-5.9.9-pre5 + + libopts/autoopts/usage-txt.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/boolean.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/compat/compat.h@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/compat/pathfind.c@1.3 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/compat/windows-config.h@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/configfile.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/cook.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/enumeration.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/environment.c@1.4 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/file.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/genshell.c@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/genshell.h@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/load.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/m4/libopts.m4@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/m4/liboptschk.m4@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/makeshell.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/nested.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/numeric.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/pgusage.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/proto.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/putshell.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/reset.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/restore.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/save.c@1.4 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/sort.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/stack.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/streqvcmp.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/text_mmap.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/time.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/tokenize.c@1.2 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + libopts/usage.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/value-type.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + libopts/version.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + libopts/xat-attribute.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/ag-char-map.h@1.4 +37 -6 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts.h@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts/options.h@1.4 +34 -40 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/autoopts/usage-txt.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/boolean.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/compat/compat.h@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/compat/pathfind.c@1.3 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/compat/windows-config.h@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/configfile.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/cook.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/enumeration.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/environment.c@1.4 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/file.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/genshell.c@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/genshell.h@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/load.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/m4/libopts.m4@1.4 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/m4/liboptschk.m4@1.3 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/makeshell.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/nested.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/numeric.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/pgusage.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/proto.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/putshell.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/reset.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/restore.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/save.c@1.4 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/sort.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/stack.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/streqvcmp.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/text_mmap.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/time.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/tokenize.c@1.2 +2 -2 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/usage.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/value-type.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/version.c@1.3 +3 -3 + Upgraded to autogen-5.9.9-pre5 + + sntp/libopts/xat-attribute.h@1.4 +1 -1 + Upgraded to autogen-5.9.9-pre5 + +ChangeSet@1.1941, 2009-08-03 05:01:24+00:00, davehart@shiny.ad.hartbrothers.com + remove workaround ports/winnt/include/inttypes.h for Autogen 5.98 + problem fixed in 5.99 + + BitKeeper/deleted/.del-inttypes.h~d8eb65583f310a51@1.2 +0 -0 + Delete: ports/winnt/include/inttypes.h + + ports/winnt/include/config.h@1.73 +0 -1 + remove empty inttypes.h workaround for Autogen 5.98 problem fixed in 5.99 + + ports/winnt/libntp/libntp.vcproj@1.12 +4 -4 + add libopts\ag-char-map.h reference, remove workaround inttypes.h + +ChangeSet@1.1940, 2009-07-30 07:53:13-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P197 + TAG: NTP_4_2_5P197 + + ChangeLog@1.395 +1 -0 + NTP_4_2_5P197 + + gsoc_sntp/sntp-opts.c@1.59 +2 -2 + NTP_4_2_5P197 + + gsoc_sntp/sntp-opts.h@1.59 +3 -3 + NTP_4_2_5P197 + + gsoc_sntp/sntp-opts.texi@1.59 +1 -1 + NTP_4_2_5P197 + + gsoc_sntp/sntp.1@1.59 +2 -2 + NTP_4_2_5P197 + + ntpd/ntpd-opts.c@1.190 +2 -2 + NTP_4_2_5P197 + + ntpd/ntpd-opts.h@1.190 +3 -3 + NTP_4_2_5P197 + + ntpd/ntpd-opts.texi@1.188 +1 -1 + NTP_4_2_5P197 + + ntpd/ntpd.1@1.188 +2 -2 + NTP_4_2_5P197 + + ntpdc/ntpdc-opts.c@1.186 +2 -2 + NTP_4_2_5P197 + + ntpdc/ntpdc-opts.h@1.186 +3 -3 + NTP_4_2_5P197 + + ntpdc/ntpdc-opts.texi@1.185 +1 -1 + NTP_4_2_5P197 + + ntpdc/ntpdc.1@1.185 +2 -2 + NTP_4_2_5P197 + + ntpq/ntpq-opts.c@1.186 +2 -2 + NTP_4_2_5P197 + + ntpq/ntpq-opts.h@1.186 +3 -3 + NTP_4_2_5P197 + + ntpq/ntpq-opts.texi@1.185 +1 -1 + NTP_4_2_5P197 + + ntpq/ntpq.1@1.185 +2 -2 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd-opts.c@1.66 +2 -2 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd-opts.h@1.66 +3 -3 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd-opts.texi@1.66 +1 -1 + NTP_4_2_5P197 + + ntpsnmpd/ntpsnmpd.1@1.66 +2 -2 + NTP_4_2_5P197 + + packageinfo.sh@1.200 +1 -1 + NTP_4_2_5P197 + + sntp/sntp-opts.c@1.186 +2 -2 + NTP_4_2_5P197 + + sntp/sntp-opts.h@1.186 +3 -3 + NTP_4_2_5P197 + + sntp/sntp-opts.texi@1.185 +1 -1 + NTP_4_2_5P197 + + sntp/sntp.1@1.185 +2 -2 + NTP_4_2_5P197 + + util/ntp-keygen-opts.c@1.189 +2 -2 + NTP_4_2_5P197 + + util/ntp-keygen-opts.h@1.189 +3 -3 + NTP_4_2_5P197 + + util/ntp-keygen-opts.texi@1.188 +1 -1 + NTP_4_2_5P197 + + util/ntp-keygen.1@1.188 +2 -2 + NTP_4_2_5P197 + +ChangeSet@1.1939, 2009-07-30 02:38:38-04:00, stenn@whimsy.udel.edu + The build script now has . at the end of PATH for config.guess + + ChangeLog@1.394 +1 -0 + The build script now has . at the end of PATH for config.guess + + build@1.29 +3 -0 + The build script now has . at the end of PATH for config.guess + +ChangeSet@1.1938, 2009-07-29 07:54:11-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P196 + TAG: NTP_4_2_5P196 + + ChangeLog@1.393 +1 -0 + NTP_4_2_5P196 + + gsoc_sntp/sntp-opts.c@1.58 +2 -2 + NTP_4_2_5P196 + + gsoc_sntp/sntp-opts.h@1.58 +3 -3 + NTP_4_2_5P196 + + gsoc_sntp/sntp-opts.texi@1.58 +1 -1 + NTP_4_2_5P196 + + gsoc_sntp/sntp.1@1.58 +2 -2 + NTP_4_2_5P196 + + ntpd/ntpd-opts.c@1.189 +2 -2 + NTP_4_2_5P196 + + ntpd/ntpd-opts.h@1.189 +3 -3 + NTP_4_2_5P196 + + ntpd/ntpd-opts.texi@1.187 +1 -1 + NTP_4_2_5P196 + + ntpd/ntpd.1@1.187 +2 -2 + NTP_4_2_5P196 + + ntpdc/ntpdc-opts.c@1.185 +2 -2 + NTP_4_2_5P196 + + ntpdc/ntpdc-opts.h@1.185 +3 -3 + NTP_4_2_5P196 + + ntpdc/ntpdc-opts.texi@1.184 +1 -1 + NTP_4_2_5P196 + + ntpdc/ntpdc.1@1.184 +2 -2 + NTP_4_2_5P196 + + ntpq/ntpq-opts.c@1.185 +2 -2 + NTP_4_2_5P196 + + ntpq/ntpq-opts.h@1.185 +3 -3 + NTP_4_2_5P196 + + ntpq/ntpq-opts.texi@1.184 +1 -1 + NTP_4_2_5P196 + + ntpq/ntpq.1@1.184 +2 -2 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd-opts.c@1.65 +2 -2 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd-opts.h@1.65 +3 -3 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd-opts.texi@1.65 +1 -1 + NTP_4_2_5P196 + + ntpsnmpd/ntpsnmpd.1@1.65 +2 -2 + NTP_4_2_5P196 + + packageinfo.sh@1.199 +1 -1 + NTP_4_2_5P196 + + sntp/sntp-opts.c@1.185 +2 -2 + NTP_4_2_5P196 + + sntp/sntp-opts.h@1.185 +3 -3 + NTP_4_2_5P196 + + sntp/sntp-opts.texi@1.184 +1 -1 + NTP_4_2_5P196 + + sntp/sntp.1@1.184 +2 -2 + NTP_4_2_5P196 + + util/ntp-keygen-opts.c@1.188 +2 -2 + NTP_4_2_5P196 + + util/ntp-keygen-opts.h@1.188 +3 -3 + NTP_4_2_5P196 + + util/ntp-keygen-opts.texi@1.187 +1 -1 + NTP_4_2_5P196 + + util/ntp-keygen.1@1.187 +2 -2 + NTP_4_2_5P196 + +ChangeSet@1.1937, 2009-07-29 02:25:28-04:00, stenn@whimsy.udel.edu + Typo fix, and note cvo.sh supports QNX now, too + + ChangeLog@1.392 +1 -1 + cvo.sh now supports QNX + + ChangeLog@1.391 +1 -1 + typo + +ChangeSet@1.1934.1.1, 2009-07-29 02:03:51-04:00, stenn@whimsy.udel.edu + [Bug 1276 normal] CID 52: crypto_xmit() may call crypto_alice[23]() with NULL peer + + ChangeLog@1.388.1.1 +2 -0 + [Bug 1276 normal] CID 52: crypto_xmit() may call crypto_alice[23]() with NULL peer + + ntpd/ntp_crypto.c@1.139 +9 -0 + [Bug 1276 normal] CID 52: crypto_xmit() may call crypto_alice[23]() with NULL peer + +ChangeSet@1.1935, 2009-07-29 04:13:53+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. + [Bug 1273] CID 10: Palisade leaks unit struct in error path. + [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. + [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. + + + ChangeLog@1.389 +6 -0 + [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. + [Bug 1273] CID 10: Palisade leaks unit struct in error path. + [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. + [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. + + + gsoc_sntp/networking.c@1.22 +11 -3 + [Bug 1272] gsoc_sntp IPv6 build problems under HP-UX 10. + [Bug 1274] CID 67: ensure resolve_hosts() output count and pointers + are consistent. + + ntpd/ntp_io.c@1.294 +1 -1 + cleanup from sockaddr_u introduction, stoa needs pointer to sockaddr_u not interface + + ntpd/refclock_palisade.c@1.26 +3 -9 + [Bug 1273] CID 10: Palisade leaks unit struct in error path. + + + sntp/main.c@1.10 +3 -0 + [Bug 1275] CID 45: CID 46: old sntp uses uninitialized guesses[0], + precs[0]. + + +ChangeSet@1.1934, 2009-07-27 07:54:24-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P195 + TAG: NTP_4_2_5P195 + + ChangeLog@1.388 +1 -0 + NTP_4_2_5P195 + + gsoc_sntp/sntp-opts.c@1.57 +2 -2 + NTP_4_2_5P195 + + gsoc_sntp/sntp-opts.h@1.57 +3 -3 + NTP_4_2_5P195 + + gsoc_sntp/sntp-opts.texi@1.57 +1 -1 + NTP_4_2_5P195 + + gsoc_sntp/sntp.1@1.57 +2 -2 + NTP_4_2_5P195 + + ntpd/ntpd-opts.c@1.188 +2 -2 + NTP_4_2_5P195 + + ntpd/ntpd-opts.h@1.188 +3 -3 + NTP_4_2_5P195 + + ntpd/ntpd-opts.texi@1.186 +1 -1 + NTP_4_2_5P195 + + ntpd/ntpd.1@1.186 +2 -2 + NTP_4_2_5P195 + + ntpdc/ntpdc-opts.c@1.184 +2 -2 + NTP_4_2_5P195 + + ntpdc/ntpdc-opts.h@1.184 +3 -3 + NTP_4_2_5P195 + + ntpdc/ntpdc-opts.texi@1.183 +1 -1 + NTP_4_2_5P195 + + ntpdc/ntpdc.1@1.183 +2 -2 + NTP_4_2_5P195 + + ntpq/ntpq-opts.c@1.184 +2 -2 + NTP_4_2_5P195 + + ntpq/ntpq-opts.h@1.184 +3 -3 + NTP_4_2_5P195 + + ntpq/ntpq-opts.texi@1.183 +1 -1 + NTP_4_2_5P195 + + ntpq/ntpq.1@1.183 +2 -2 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd-opts.c@1.64 +2 -2 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd-opts.h@1.64 +3 -3 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd-opts.texi@1.64 +1 -1 + NTP_4_2_5P195 + + ntpsnmpd/ntpsnmpd.1@1.64 +2 -2 + NTP_4_2_5P195 + + packageinfo.sh@1.198 +1 -1 + NTP_4_2_5P195 + + sntp/sntp-opts.c@1.184 +2 -2 + NTP_4_2_5P195 + + sntp/sntp-opts.h@1.184 +3 -3 + NTP_4_2_5P195 + + sntp/sntp-opts.texi@1.183 +1 -1 + NTP_4_2_5P195 + + sntp/sntp.1@1.183 +2 -2 + NTP_4_2_5P195 + + util/ntp-keygen-opts.c@1.187 +2 -2 + NTP_4_2_5P195 + + util/ntp-keygen-opts.h@1.187 +3 -3 + NTP_4_2_5P195 + + util/ntp-keygen-opts.texi@1.186 +1 -1 + NTP_4_2_5P195 + + util/ntp-keygen.1@1.186 +2 -2 + NTP_4_2_5P195 + +ChangeSet@1.1933, 2009-07-27 06:57:03+00:00, stenn@psp-fb1.ntp.org + cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE + + ChangeLog@1.387 +1 -0 + cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE + + scripts/cvo.sh@1.3 +30 -6 + cvo.sh: Add support for CentOS, Fedora, Slackware, SuSE + +ChangeSet@1.1932, 2009-07-26 07:54:22-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P194 + TAG: NTP_4_2_5P194 + + ChangeLog@1.386 +1 -0 + NTP_4_2_5P194 + + gsoc_sntp/sntp-opts.c@1.56 +2 -2 + NTP_4_2_5P194 + + gsoc_sntp/sntp-opts.h@1.56 +3 -3 + NTP_4_2_5P194 + + gsoc_sntp/sntp-opts.texi@1.56 +1 -1 + NTP_4_2_5P194 + + gsoc_sntp/sntp.1@1.56 +2 -2 + NTP_4_2_5P194 + + ntpd/ntpd-opts.c@1.187 +2 -2 + NTP_4_2_5P194 + + ntpd/ntpd-opts.h@1.187 +3 -3 + NTP_4_2_5P194 + + ntpd/ntpd-opts.texi@1.185 +1 -1 + NTP_4_2_5P194 + + ntpd/ntpd.1@1.185 +2 -2 + NTP_4_2_5P194 + + ntpdc/ntpdc-opts.c@1.183 +2 -2 + NTP_4_2_5P194 + + ntpdc/ntpdc-opts.h@1.183 +3 -3 + NTP_4_2_5P194 + + ntpdc/ntpdc-opts.texi@1.182 +1 -1 + NTP_4_2_5P194 + + ntpdc/ntpdc.1@1.182 +2 -2 + NTP_4_2_5P194 + + ntpq/ntpq-opts.c@1.183 +2 -2 + NTP_4_2_5P194 + + ntpq/ntpq-opts.h@1.183 +3 -3 + NTP_4_2_5P194 + + ntpq/ntpq-opts.texi@1.182 +1 -1 + NTP_4_2_5P194 + + ntpq/ntpq.1@1.182 +2 -2 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd-opts.c@1.63 +2 -2 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd-opts.h@1.63 +3 -3 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd-opts.texi@1.63 +1 -1 + NTP_4_2_5P194 + + ntpsnmpd/ntpsnmpd.1@1.63 +2 -2 + NTP_4_2_5P194 + + packageinfo.sh@1.197 +1 -1 + NTP_4_2_5P194 + + sntp/sntp-opts.c@1.183 +2 -2 + NTP_4_2_5P194 + + sntp/sntp-opts.h@1.183 +3 -3 + NTP_4_2_5P194 + + sntp/sntp-opts.texi@1.182 +1 -1 + NTP_4_2_5P194 + + sntp/sntp.1@1.182 +2 -2 + NTP_4_2_5P194 + + util/ntp-keygen-opts.c@1.186 +2 -2 + NTP_4_2_5P194 + + util/ntp-keygen-opts.h@1.186 +3 -3 + NTP_4_2_5P194 + + util/ntp-keygen-opts.texi@1.185 +1 -1 + NTP_4_2_5P194 + + util/ntp-keygen.1@1.185 +2 -2 + NTP_4_2_5P194 + +ChangeSet@1.1931, 2009-07-25 22:36:56-04:00, stenn@psp-deb1.ntp.org + Handle debian + + scripts/cvo.sh@1.2 +5 -0 + Handle debian + +ChangeSet@1.1930, 2009-07-25 22:36:32-04:00, stenn@psp-deb1.ntp.org + better sanity checking in "build" + + build@1.28 +3 -0 + better sanity checking in "build" + +ChangeSet@1.1929, 2009-07-25 21:47:07-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.385 +1 -0 + Documentation updates from Dave Mills + + html/debug.html@1.27 +6 -5 + Documentation updates from Dave Mills + +ChangeSet@1.1928, 2009-07-25 21:41:08-04:00, stenn@whimsy.udel.edu + Use scripts/cvo.sh in the build script to get better subdir names + + ChangeLog@1.384 +1 -0 + Use scripts/cvo.sh in the build script to get better subdir names + + build@1.27 +1 -1 + Use scripts/cvo.sh in the build script to get better subdir names + + scripts/cvo.sh@1.1 +120 -0 + BitKeeper file /deacon/backroom/ntp-dev/scripts/cvo.sh + + scripts/cvo.sh@1.0 +0 -0 + +ChangeSet@1.1927, 2009-07-25 07:54:56-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P193 + TAG: NTP_4_2_5P193 + + ChangeLog@1.383 +1 -0 + NTP_4_2_5P193 + + gsoc_sntp/sntp-opts.c@1.55 +2 -2 + NTP_4_2_5P193 + + gsoc_sntp/sntp-opts.h@1.55 +3 -3 + NTP_4_2_5P193 + + gsoc_sntp/sntp-opts.texi@1.55 +1 -1 + NTP_4_2_5P193 + + gsoc_sntp/sntp.1@1.55 +2 -2 + NTP_4_2_5P193 + + ntpd/ntpd-opts.c@1.186 +2 -2 + NTP_4_2_5P193 + + ntpd/ntpd-opts.h@1.186 +3 -3 + NTP_4_2_5P193 + + ntpd/ntpd-opts.texi@1.184 +1 -1 + NTP_4_2_5P193 + + ntpd/ntpd.1@1.184 +2 -2 + NTP_4_2_5P193 + + ntpdc/ntpdc-opts.c@1.182 +2 -2 + NTP_4_2_5P193 + + ntpdc/ntpdc-opts.h@1.182 +3 -3 + NTP_4_2_5P193 + + ntpdc/ntpdc-opts.texi@1.181 +1 -1 + NTP_4_2_5P193 + + ntpdc/ntpdc.1@1.181 +2 -2 + NTP_4_2_5P193 + + ntpq/ntpq-opts.c@1.182 +2 -2 + NTP_4_2_5P193 + + ntpq/ntpq-opts.h@1.182 +3 -3 + NTP_4_2_5P193 + + ntpq/ntpq-opts.texi@1.181 +1 -1 + NTP_4_2_5P193 + + ntpq/ntpq.1@1.181 +2 -2 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd-opts.c@1.62 +2 -2 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd-opts.h@1.62 +3 -3 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd-opts.texi@1.62 +1 -1 + NTP_4_2_5P193 + + ntpsnmpd/ntpsnmpd.1@1.62 +2 -2 + NTP_4_2_5P193 + + packageinfo.sh@1.196 +1 -1 + NTP_4_2_5P193 + + sntp/sntp-opts.c@1.182 +2 -2 + NTP_4_2_5P193 + + sntp/sntp-opts.h@1.182 +3 -3 + NTP_4_2_5P193 + + sntp/sntp-opts.texi@1.181 +1 -1 + NTP_4_2_5P193 + + sntp/sntp.1@1.181 +2 -2 + NTP_4_2_5P193 + + util/ntp-keygen-opts.c@1.185 +2 -2 + NTP_4_2_5P193 + + util/ntp-keygen-opts.h@1.185 +3 -3 + NTP_4_2_5P193 + + util/ntp-keygen-opts.texi@1.184 +1 -1 + NTP_4_2_5P193 + + util/ntp-keygen.1@1.184 +2 -2 + NTP_4_2_5P193 + +ChangeSet@1.1926, 2009-07-25 01:12:25+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. + [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. + [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. + [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. + [Bug 1267] CID 44: old sntp handle_saving() writes stack garbage to + file when clearing. + [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. + [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. + [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. + + + ChangeLog@1.382 +14 -0 + [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. + [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. + [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. + [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. + [Bug 1267] CID 44: old sntp handle_saving() writes stack garbage to + file when clearing. + [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. + [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. + [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. + + + gsoc_sntp/main.c@1.16 +7 -10 + [Bug 1264] CID 64: gsoc_sntp on_wire() frees wrong ptr receiving KoD. + [Bug 1265] CID 65: CID 66: gsoc_sntp on_wire() leaks x_pkt, r_pkt. + + + gsoc_sntp/networking.c@1.21 +3 -3 + [Bug 1268] CID 63: resolve_hosts() leaks error message buffer. + [Bug 1270] CID 70: gsoc_sntp recv_bcst_data mdevadr.ipv6mr_interface + uninitialized. + + + ntpd/ntp_io.c@1.293 +2 -0 + [Bug 1269] CID 74: use assertion to ensure move_fd() does not return + negative descriptors. + + ntpd/ntpsim.c@1.22 +3 -0 + [Bug 1261] CID 34: simulate_server() rbuf.msg_flags uninitialized. + [Bug 1262] CID 35: xpkt.mac uninitialized in simulate_server(). + + + ntpd/refclock_arc.c@1.21 +129 -127 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ntpd/refclock_chronolog.c@1.8 +2 -0 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ntpd/refclock_datum.c@1.12 +2 -0 + [Bug 1266] CID 39: datum_pts_start() uninitialized arg.c_ospeed. + + + ntpd/refclock_dumbclock.c@1.13 +20 -26 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ntpd/refclock_pcf.c@1.9 +2 -0 + [Bug 1263] CID 37: CID 38: CID 40: CID 43: multiple refclocks + uninitialized tm_zone (arc, chronolog, dumbclock, pcf). + + + ports/winnt/include/config.h@1.72 +2 -1 + Enable dumbclock, Chronolog refclock drivers in Windows ntpd + + ports/winnt/ntpd/ntpd.dsp@1.32 +4 -0 + add refclock_chronolog.c + + ports/winnt/ntpd/ntpd.vcproj@1.12 +4 -0 + add refclock_chronolog.c + + sntp/main.c@1.9 +2 -0 + zero stack buffer before writing to file in save_clear operation + +ChangeSet@1.1925, 2009-07-24 08:00:56-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P192 + TAG: NTP_4_2_5P192 + + ChangeLog@1.381 +1 -0 + NTP_4_2_5P192 + + gsoc_sntp/sntp-opts.c@1.54 +2 -2 + NTP_4_2_5P192 + + gsoc_sntp/sntp-opts.h@1.54 +3 -3 + NTP_4_2_5P192 + + gsoc_sntp/sntp-opts.texi@1.54 +1 -1 + NTP_4_2_5P192 + + gsoc_sntp/sntp.1@1.54 +2 -2 + NTP_4_2_5P192 + + ntpd/ntpd-opts.c@1.185 +2 -2 + NTP_4_2_5P192 + + ntpd/ntpd-opts.h@1.185 +3 -3 + NTP_4_2_5P192 + + ntpd/ntpd-opts.texi@1.183 +1 -1 + NTP_4_2_5P192 + + ntpd/ntpd.1@1.183 +2 -2 + NTP_4_2_5P192 + + ntpdc/ntpdc-opts.c@1.181 +2 -2 + NTP_4_2_5P192 + + ntpdc/ntpdc-opts.h@1.181 +3 -3 + NTP_4_2_5P192 + + ntpdc/ntpdc-opts.texi@1.180 +1 -1 + NTP_4_2_5P192 + + ntpdc/ntpdc.1@1.180 +2 -2 + NTP_4_2_5P192 + + ntpq/ntpq-opts.c@1.181 +2 -2 + NTP_4_2_5P192 + + ntpq/ntpq-opts.h@1.181 +3 -3 + NTP_4_2_5P192 + + ntpq/ntpq-opts.texi@1.180 +1 -1 + NTP_4_2_5P192 + + ntpq/ntpq.1@1.180 +2 -2 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd-opts.c@1.61 +2 -2 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd-opts.h@1.61 +3 -3 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd-opts.texi@1.61 +1 -1 + NTP_4_2_5P192 + + ntpsnmpd/ntpsnmpd.1@1.61 +2 -2 + NTP_4_2_5P192 + + packageinfo.sh@1.195 +1 -1 + NTP_4_2_5P192 + + sntp/sntp-opts.c@1.181 +2 -2 + NTP_4_2_5P192 + + sntp/sntp-opts.h@1.181 +3 -3 + NTP_4_2_5P192 + + sntp/sntp-opts.texi@1.180 +1 -1 + NTP_4_2_5P192 + + sntp/sntp.1@1.180 +2 -2 + NTP_4_2_5P192 + + util/ntp-keygen-opts.c@1.184 +2 -2 + NTP_4_2_5P192 + + util/ntp-keygen-opts.h@1.184 +3 -3 + NTP_4_2_5P192 + + util/ntp-keygen-opts.texi@1.183 +1 -1 + NTP_4_2_5P192 + + util/ntp-keygen.1@1.183 +2 -2 + NTP_4_2_5P192 + +ChangeSet@1.1922.1.1, 2009-07-24 06:41:17+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 965] CID 42: ss_family uninitialized. + [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. + [Bug 1251] CID 68: search_entry() mishandles dst argument. + [Bug 1252] CID 32: Quiet Coverity warning with assertion. + [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. + [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. + [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. + [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. + [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. + [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). + + + ChangeLog@1.378.1.1 +15 -0 + [Bug 965] CID 42: ss_family uninitialized. + [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. + [Bug 1251] CID 68: search_entry() mishandles dst argument. + [Bug 1252] CID 32: Quiet Coverity warning with assertion. + [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. + [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. + [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. + [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. + [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. + [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). + + + gsoc_sntp/crypto.c@1.6 +8 -10 + use sizeof(buf) rather than hardcode + [Bug 1253] CID 50: gsoc_sntp/crypto.c auth_init() always returns a + list with one entry. + [Bug 1257] CID 57: gsoc_sntp auth_init() fails to fclose(keyfile). + + + gsoc_sntp/kod_management.c@1.9 +55 -40 + [Bug 1250] CID 53: kod_init_kod_db() overruns kod_db malloc'd buffer. + [Bug 1251] CID 68: search_entry() mishandles dst argument. + + + gsoc_sntp/main.c@1.15 +25 -26 + [Bug 1251] CID 68: search_entry() mishandles dst argument. + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + + + gsoc_sntp/networking.c@1.20 +35 -58 + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + [Bug 1259] CID 59: gsoc_sntp recv_bcast_data() fails to free(rdata) + on error paths. + [Bug 1260] CID 60: gsoc_sntp recvpkt() fails to free(rdata). + + + gsoc_sntp/networking.h@1.13 +1 -1 + [Bug 1258] CID 54: gsoc_sntp resolve_hosts() needs simplification. + + + gsoc_sntp/utilities.c@1.7 +9 -2 + [Bug 1254] CID 56: tv_to_str() leaks a struct tm each call. + [Bug 1255] CID 55: pkt_output() leaks a copy of each packet. + + + include/ntp_assert.h@1.3 +46 -13 + [Bug 1256] CID 51: Coverity doesn't recognize our assertion macros as + terminal. + + + ntpd/refclock_nmea.c@1.42 +1 -0 + [Bug 965] CID 42: ss_family uninitialized. + + ntpdc/ntpdc.c@1.66 +9 -2 + [Bug 1252] CID 32: Quiet Coverity warning with assertion. + + + ports/winnt/libntp/libntp.vcproj@1.11 +4 -0 + add ntp_assert.h reference + + ports/winnt/ntpd/ntpd.vcproj@1.11 +4 -0 + add ntp_assert.h reference + + ports/winnt/ntpdc/ntpdc.vcproj@1.4 +4 -0 + add ntp_assert.h reference + +ChangeSet@1.1923, 2009-07-24 01:21:05-04:00, stenn@whimsy.udel.edu + Upgrade to autogen-5.9.9pre2 + + ChangeLog@1.379 +1 -0 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/README@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/ag-char-map.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts/options.h@1.3 +2 -2 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/boolean.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/compat/compat.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/compat/pathfind.c@1.2 +2 -2 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/compat/windows-config.h@1.2 +3 -3 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/configfile.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/cook.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/enumeration.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/environment.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/file.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/genshell.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/genshell.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/load.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/m4/libopts.m4@1.3 +4 -4 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.2 +4 -3 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/makeshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/nested.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/numeric.c@1.2 +9 -8 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/pgusage.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/proto.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/putshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/reset.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/restore.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/save.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/sort.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/stack.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/streqvcmp.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/text_mmap.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/time.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/usage.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/value-type.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/version.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + gsoc_sntp/libopts/xat-attribute.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/README@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/ag-char-map.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts/options.h@1.3 +2 -2 + Upgrade to autogen-5.9.9pre2 + + libopts/autoopts/usage-txt.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/boolean.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/compat/compat.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/compat/pathfind.c@1.2 +2 -2 + Upgrade to autogen-5.9.9pre2 + + libopts/compat/windows-config.h@1.2 +3 -3 + Upgrade to autogen-5.9.9pre2 + + libopts/configfile.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/cook.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/enumeration.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/environment.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/file.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre2 + + libopts/genshell.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/genshell.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/load.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/m4/libopts.m4@1.3 +4 -4 + Upgrade to autogen-5.9.9pre2 + + libopts/m4/liboptschk.m4@1.2 +4 -3 + Upgrade to autogen-5.9.9pre2 + + libopts/makeshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/nested.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/numeric.c@1.2 +9 -8 + Upgrade to autogen-5.9.9pre2 + + libopts/pgusage.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/proto.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/putshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/reset.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/restore.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/save.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/sort.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/stack.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/streqvcmp.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/text_mmap.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/time.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/usage.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/value-type.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/version.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + libopts/xat-attribute.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/README@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/ag-char-map.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts/options.h@1.3 +2 -2 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/autoopts/usage-txt.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/boolean.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/compat/compat.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/compat/pathfind.c@1.2 +2 -2 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/compat/windows-config.h@1.2 +3 -3 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/configfile.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/cook.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/enumeration.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/environment.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/file.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/genshell.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/genshell.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/load.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/m4/libopts.m4@1.3 +4 -4 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/m4/liboptschk.m4@1.2 +4 -3 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/makeshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/nested.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/numeric.c@1.2 +9 -8 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/pgusage.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/proto.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/putshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/reset.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/restore.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/save.c@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/sort.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/stack.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/streqvcmp.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/text_mmap.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/time.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/usage.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/value-type.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/version.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre2 + + sntp/libopts/xat-attribute.h@1.3 +1 -1 + Upgrade to autogen-5.9.9pre2 + +ChangeSet@1.1922, 2009-07-21 07:59:39-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P191 + TAG: NTP_4_2_5P191 + + ChangeLog@1.378 +1 -0 + NTP_4_2_5P191 + + gsoc_sntp/sntp-opts.c@1.53 +2 -2 + NTP_4_2_5P191 + + gsoc_sntp/sntp-opts.h@1.53 +3 -3 + NTP_4_2_5P191 + + gsoc_sntp/sntp-opts.texi@1.53 +1 -1 + NTP_4_2_5P191 + + gsoc_sntp/sntp.1@1.53 +2 -2 + NTP_4_2_5P191 + + ntpd/ntpd-opts.c@1.184 +2 -2 + NTP_4_2_5P191 + + ntpd/ntpd-opts.h@1.184 +3 -3 + NTP_4_2_5P191 + + ntpd/ntpd-opts.texi@1.182 +1 -1 + NTP_4_2_5P191 + + ntpd/ntpd.1@1.182 +2 -2 + NTP_4_2_5P191 + + ntpdc/ntpdc-opts.c@1.180 +2 -2 + NTP_4_2_5P191 + + ntpdc/ntpdc-opts.h@1.180 +3 -3 + NTP_4_2_5P191 + + ntpdc/ntpdc-opts.texi@1.179 +1 -1 + NTP_4_2_5P191 + + ntpdc/ntpdc.1@1.179 +2 -2 + NTP_4_2_5P191 + + ntpq/ntpq-opts.c@1.180 +2 -2 + NTP_4_2_5P191 + + ntpq/ntpq-opts.h@1.180 +3 -3 + NTP_4_2_5P191 + + ntpq/ntpq-opts.texi@1.179 +1 -1 + NTP_4_2_5P191 + + ntpq/ntpq.1@1.179 +2 -2 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd-opts.c@1.60 +2 -2 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd-opts.h@1.60 +3 -3 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd-opts.texi@1.60 +1 -1 + NTP_4_2_5P191 + + ntpsnmpd/ntpsnmpd.1@1.60 +2 -2 + NTP_4_2_5P191 + + packageinfo.sh@1.194 +1 -1 + NTP_4_2_5P191 + + sntp/sntp-opts.c@1.180 +2 -2 + NTP_4_2_5P191 + + sntp/sntp-opts.h@1.180 +3 -3 + NTP_4_2_5P191 + + sntp/sntp-opts.texi@1.179 +1 -1 + NTP_4_2_5P191 + + sntp/sntp.1@1.179 +2 -2 + NTP_4_2_5P191 + + util/ntp-keygen-opts.c@1.183 +2 -2 + NTP_4_2_5P191 + + util/ntp-keygen-opts.h@1.183 +3 -3 + NTP_4_2_5P191 + + util/ntp-keygen-opts.texi@1.182 +1 -1 + NTP_4_2_5P191 + + util/ntp-keygen.1@1.182 +2 -2 + NTP_4_2_5P191 + +ChangeSet@1.1921, 2009-07-21 04:22:31-04:00, stenn@whimsy.udel.edu + Upgrade to autogen-5.9.9pre1 + + ChangeLog@1.377 +1 -0 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/ag-char-map.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/autoopts/options.h@1.2 +2 -2 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/environment.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/genshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/genshell.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/m4/libopts.m4@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/proto.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/save.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/value-type.c@1.2 +1 -4 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/value-type.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/xat-attribute.c@1.2 +1 -4 + Upgrade to autogen-5.9.9pre1 + + gsoc_sntp/libopts/xat-attribute.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/ag-char-map.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/autoopts/options.h@1.2 +2 -2 + Upgrade to autogen-5.9.9pre1 + + libopts/autoopts/usage-txt.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/environment.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre1 + + libopts/genshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/genshell.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/m4/libopts.m4@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/proto.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/save.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre1 + + libopts/value-type.c@1.2 +1 -4 + Upgrade to autogen-5.9.9pre1 + + libopts/value-type.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + libopts/xat-attribute.c@1.2 +1 -4 + Upgrade to autogen-5.9.9pre1 + + libopts/xat-attribute.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/ag-char-map.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/autoopts/options.h@1.2 +2 -2 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/autoopts/usage-txt.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/environment.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/genshell.c@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/genshell.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/m4/libopts.m4@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/proto.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/save.c@1.2 +4 -3 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/value-type.c@1.2 +1 -4 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/value-type.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/xat-attribute.c@1.2 +1 -4 + Upgrade to autogen-5.9.9pre1 + + sntp/libopts/xat-attribute.h@1.2 +1 -1 + Upgrade to autogen-5.9.9pre1 + +ChangeSet@1.1920, 2009-07-20 08:08:06-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P190 + TAG: NTP_4_2_5P190 + + ChangeLog@1.376 +1 -0 + NTP_4_2_5P190 + + gsoc_sntp/sntp-opts.c@1.52 +2 -2 + NTP_4_2_5P190 + + gsoc_sntp/sntp-opts.h@1.52 +3 -3 + NTP_4_2_5P190 + + gsoc_sntp/sntp-opts.texi@1.52 +1 -1 + NTP_4_2_5P190 + + gsoc_sntp/sntp.1@1.52 +2 -2 + NTP_4_2_5P190 + + ntpd/ntpd-opts.c@1.183 +66 -60 + NTP_4_2_5P190 + + ntpd/ntpd-opts.h@1.183 +75 -56 + NTP_4_2_5P190 + + ntpd/ntpd-opts.texi@1.181 +1 -1 + NTP_4_2_5P190 + + ntpd/ntpd.1@1.181 +4 -4 + NTP_4_2_5P190 + + ntpdc/ntpdc-opts.c@1.179 +2 -2 + NTP_4_2_5P190 + + ntpdc/ntpdc-opts.h@1.179 +3 -3 + NTP_4_2_5P190 + + ntpdc/ntpdc-opts.texi@1.178 +2 -2 + NTP_4_2_5P190 + + ntpdc/ntpdc.1@1.178 +2 -2 + NTP_4_2_5P190 + + ntpq/ntpq-opts.c@1.179 +2 -2 + NTP_4_2_5P190 + + ntpq/ntpq-opts.h@1.179 +3 -3 + NTP_4_2_5P190 + + ntpq/ntpq-opts.texi@1.178 +2 -2 + NTP_4_2_5P190 + + ntpq/ntpq.1@1.178 +2 -2 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd-opts.c@1.59 +66 -63 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd-opts.h@1.59 +48 -29 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd-opts.texi@1.59 +1 -1 + NTP_4_2_5P190 + + ntpsnmpd/ntpsnmpd.1@1.59 +4 -4 + NTP_4_2_5P190 + + packageinfo.sh@1.193 +1 -1 + NTP_4_2_5P190 + + sntp/sntp-opts.c@1.179 +2 -2 + NTP_4_2_5P190 + + sntp/sntp-opts.h@1.179 +3 -3 + NTP_4_2_5P190 + + sntp/sntp-opts.texi@1.178 +1 -1 + NTP_4_2_5P190 + + sntp/sntp.1@1.178 +2 -2 + NTP_4_2_5P190 + + util/ntp-keygen-opts.c@1.182 +2 -2 + NTP_4_2_5P190 + + util/ntp-keygen-opts.h@1.182 +3 -3 + NTP_4_2_5P190 + + util/ntp-keygen-opts.texi@1.181 +2 -2 + NTP_4_2_5P190 + + util/ntp-keygen.1@1.181 +2 -2 + NTP_4_2_5P190 + +ChangeSet@1.1919, 2009-07-20 09:39:06+00:00, davehart@shiny.ad.hartbrothers.com + Windows port fixes for new Autogen and libopts + + ports/winnt/include/config.h@1.71 +5 -0 + Windows port fixes for new Autogen and libopts + + ports/winnt/include/inttypes.h@1.1 +1 -0 + add dummy (empty) inttypes.h to work around problem with new libopts + + ports/winnt/include/inttypes.h@1.0 +0 -0 + + ports/winnt/libntp/libntp.dsp@1.36 +4 -0 + add dummy (empty) inttypes.h to work around problem with new libopts + + ports/winnt/libntp/libntp.vcproj@1.10 +4 -0 + add dummy (empty) inttypes.h to work around problem with new libopts + +ChangeSet@1.1918, 2009-07-20 05:20:37-04:00, stenn@whimsy.udel.edu + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp-opts.c@1.51 +65 -62 + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp-opts.h@1.51 +56 -37 + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp-opts.texi@1.51 +1 -1 + Updated to AutoGen-5.9.8 + + gsoc_sntp/sntp.1@1.51 +4 -4 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc-opts.c@1.178 +67 -68 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc-opts.h@1.178 +54 -35 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc-opts.texi@1.177 +2 -2 + Updated to AutoGen-5.9.8 + + ntpdc/ntpdc.1@1.177 +4 -4 + Updated to AutoGen-5.9.8 + + ntpq/ntpq-opts.c@1.178 +67 -68 + Updated to AutoGen-5.9.8 + + ntpq/ntpq-opts.h@1.178 +52 -33 + Updated to AutoGen-5.9.8 + + ntpq/ntpq-opts.texi@1.177 +2 -2 + Updated to AutoGen-5.9.8 + + ntpq/ntpq.1@1.177 +4 -4 + Updated to AutoGen-5.9.8 + + sntp/sntp-opts.c@1.178 +81 -81 + Updated to AutoGen-5.9.8 + + sntp/sntp-opts.h@1.178 +52 -33 + Updated to AutoGen-5.9.8 + + sntp/sntp-opts.texi@1.177 +1 -1 + Updated to AutoGen-5.9.8 + + sntp/sntp.1@1.177 +4 -4 + Updated to AutoGen-5.9.8 + + util/ntp-keygen-opts.c@1.181 +90 -91 + Updated to AutoGen-5.9.8 + + util/ntp-keygen-opts.h@1.181 +62 -43 + Updated to AutoGen-5.9.8 + + util/ntp-keygen-opts.texi@1.180 +2 -2 + Updated to AutoGen-5.9.8 + + util/ntp-keygen.1@1.180 +4 -4 + Updated to AutoGen-5.9.8 + +ChangeSet@1.1917, 2009-07-20 04:59:15-04:00, stenn@whimsy.udel.edu + Updated to AutoGen-5.9.8 + + gsoc_sntp/Makefile.am@1.8 +1 -1 + Updated to AutoGen-5.9.8 + +ChangeSet@1.1916, 2009-07-20 04:52:47-04:00, stenn@whimsy.udel.edu + Updated to AutoGen-5.9.8 + + ChangeLog@1.375 +1 -0 + Updated to AutoGen-5.9.8 + +ChangeSet@1.1915, 2009-07-20 04:45:24-04:00, stenn@whimsy.udel.edu + Updated to AutoGen-5.9.8 + + BitKeeper/deleted/.del-COPYING.lgpl~1ddc43fbfc0a8d91@1.2 +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~356acd7e9a658616@1.3 +0 -0 + Delete: gsoc_sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~91629dd76e5e4436@1.2 +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd~506f41bf4379b14b@1.2 +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~c869a8655e2d3668@1.3 +0 -0 + Delete: gsoc_sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~dc651c8bedf8ab57@1.2 +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc~31cdb1dbe002e14a@1.2 +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~3c0055ac72058207@1.2 +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~eeacd10582f902ab@1.3 +0 -0 + Delete: gsoc_sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~2469a6a54aac94a1@1.3 +0 -0 + Delete: gsoc_sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~83bfe0c1134a9dfb@1.2 +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~92f4a0c4f9cd9ea9@1.2 +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-README~6c0e8c52bc2917b1@1.2 +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-README~b02c8a60f4cf32fe@1.2 +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-README~f742f7fd37644d2@1.3 +0 -0 + Delete: gsoc_sntp/libopts/README + + BitKeeper/deleted/.del-autoopts.c~3e84323623aff6e7@1.2 +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~9fb35908790bfaa9@1.3 +0 -0 + Delete: gsoc_sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~b42b972a53764910@1.2 +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~5bc4082052258182@1.2 +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~63e256b712b3cc83@1.3 +0 -0 + Delete: gsoc_sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~7ed5c5ad6dbc0297@1.2 +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~131707465ccb681@1.2 +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~3fc4c58774ba3ff@1.2 +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~7e6a10bd3f3866cf@1.3 +0 -0 + Delete: gsoc_sntp/libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~d62907f830867563@1.2 +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~d716e3994afa17ee@1.3 +0 -0 + Delete: gsoc_sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~ff97c2854c9b9586@1.2 +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~b6f779d27e6c4608@1.2 +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~b9949d5548dc9e7d@1.2 +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~bc87cafa8bb69d84@1.3 +0 -0 + Delete: gsoc_sntp/libopts/configfile.c + + BitKeeper/deleted/.del-cook.c~23f6c5524e2fd0b9@1.2 +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~d29aaca7ee3c2e03@1.3 +0 -0 + Delete: gsoc_sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~e72da2a3e260c2ae@1.2 +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c~1a1ac98e84630322@1.2 +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~56f8f00f64229802@1.2 +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~73f8914b25fdf1cb@1.3 +0 -0 + Delete: gsoc_sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~3fc0f27d83271522@1.3 +0 -0 + Delete: gsoc_sntp/libopts/environment.c + + BitKeeper/deleted/.del-environment.c~43f215aff8170b0d@1.2 +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-environment.c~654c5635a28f680a@1.2 +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-genshell.c~19c1b0098a7d195e@1.2 +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~8cec4f90c9677dad@1.3 +0 -0 + Delete: gsoc_sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~d151b9234159786e@1.2 +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~39a68cd82b716d3d@1.2 +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~4684aecaf31474bd@1.3 +0 -0 + Delete: gsoc_sntp/libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~fba29f6d134cf39@1.2 +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c~3fdfbf411c197e0b@1.2 +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~d2eaf9d4d9c22da8@1.2 +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~e6b4ffdc895fd9c7@1.3 +0 -0 + Delete: gsoc_sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~1e6c2484e7bcaa8e@1.2 +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~22764fd769234d87@1.3 +0 -0 + Delete: gsoc_sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~babfee32f8439fb7@1.2 +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~5684906422d310d5@1.3 +0 -0 + Delete: gsoc_sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~7f8c6092b16525fa@1.2 +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~f7c5b75baf234b93@1.2 +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~49f0fde1bda6dab1@1.2 +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-load.c~7fe0c22d7c968b7@1.2 +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-load.c~e9afe1c55b052708@1.3 +0 -0 + Delete: gsoc_sntp/libopts/load.c + + BitKeeper/deleted/.del-makeshell.c~271eaff05907e0a2@1.2 +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~67d09f76ea0a6ed5@1.3 +0 -0 + Delete: gsoc_sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~ba6349435fd3fc83@1.2 +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~5752e76eefab7f9f@1.2 +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-nested.c~7f5db28ad8a858b9@1.3 +0 -0 + Delete: gsoc_sntp/libopts/nested.c + + BitKeeper/deleted/.del-nested.c~a7ab0b07538b5e49@1.2 +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~a21fe674dc3847e2@1.3 +0 -0 + Delete: gsoc_sntp/libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~ab97d8c3d6609e2a@1.2 +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~e1d7cbb7cecbff8c@1.2 +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-options.h~56723cc66b175bd8@1.3 +0 -0 + Delete: gsoc_sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~ce496734ff365a8f@1.2 +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~eaf98d11dd68785b@1.2 +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c~5eb7c4a7238a3334@1.2 +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~660d016d9d4bfaf0@1.2 +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~ad86b5a5886760c0@1.3 +0 -0 + Delete: gsoc_sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~7a129c2a1b3dc002@1.2 +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~8894b938253faf7a@1.3 +0 -0 + Delete: gsoc_sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~f3a06f0e78822dea@1.2 +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~322bc5cfd3f14a53@1.2 +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-proto.h~600f5c521621fb7@1.2 +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-proto.h~77f289b58b0425ed@1.3 +0 -0 + Delete: gsoc_sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~454ab3a4821e880@1.3 +0 -0 + Delete: gsoc_sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~afc504b27eed29b0@1.2 +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~b671799440bdb0e6@1.2 +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-restore.c~11e16df450dfc6be@1.3 +0 -0 + Delete: gsoc_sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~4e87dc67454a7987@1.2 +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~a699a151ee8b8476@1.2 +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-save.c~4b1d83a0b1611d7c@1.3 +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-save.c~efa5c354e672893a@1.4 +0 -0 + Delete: gsoc_sntp/libopts/save.c + + BitKeeper/deleted/.del-save.c~f88133d32eccbf4b@1.3 +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~147cb0d37c1e7307@1.2 +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~8f0c3b04d748ef30@1.2 +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~d3120f77949ff1f1@1.3 +0 -0 + Delete: gsoc_sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c~2a84210ffa0f5197@1.2 +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-sort.c~3d68b8c2f01ade31@1.3 +0 -0 + Delete: gsoc_sntp/libopts/sort.c + + BitKeeper/deleted/.del-sort.c~91f412b45a139031@1.2 +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-stack.c~3275408d176af9c1@1.3 +0 -0 + Delete: gsoc_sntp/libopts/stack.c + + BitKeeper/deleted/.del-stack.c~591385237e0f3ce2@1.2 +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-stack.c~ade9ed5bb7b8fb6c@1.2 +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~45ec0a98e0025509@1.2 +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~62e63feb4f1bb259@1.3 +0 -0 + Delete: gsoc_sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~ee5d954d3d137acf@1.2 +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~516aa8c43634df59@1.2 +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~bf4073cb7820ac7e@1.2 +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~f6c99142400aadb0@1.3 +0 -0 + Delete: gsoc_sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~2b8aaed8d8cbdfa@1.3 +0 -0 + Delete: gsoc_sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~3a8c4c9ed2c0bb96@1.2 +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~7c57f427df22897@1.2 +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~24b4f1774aa17978@1.2 +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~73112689c5763d@1.3 +0 -0 + Delete: gsoc_sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~d9d668bcff3485b5@1.2 +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c~4fd8a727c28d24c@1.3 +0 -0 + Delete: gsoc_sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~a50a40638aa720cf@1.2 +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~fffe49aa64a78644@1.2 +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h~36c2f46a3cd8cbd@1.2 +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~6abe748ce418395@1.3 +0 -0 + Delete: gsoc_sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~6fa28bed13f28bc9@1.2 +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~79a0f715733bdccf@1.2 +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-usage.c~e8da7f6b2f71a374@1.3 +0 -0 + Delete: gsoc_sntp/libopts/usage.c + + BitKeeper/deleted/.del-usage.c~eb257c90352f0b1a@1.2 +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-version.c~45de4739ab05f47b@1.3 +0 -0 + Delete: gsoc_sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~96adea57d42d29f6@1.2 +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~f18bf6a7860ad7f7@1.2 +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~1665be9c16e9725d@1.2 +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~c8c7442a9420d50@1.2 +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~e3ddaca75ec0f439@1.3 +0 -0 + Delete: gsoc_sntp/libopts/compat/windows-config.h + + gsoc_sntp/libopts/COPYING.gplv3@1.1 +674 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/COPYING.gplv3 + + gsoc_sntp/libopts/COPYING.gplv3@1.0 +0 -0 + + gsoc_sntp/libopts/COPYING.lgplv3@1.1 +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/COPYING.lgplv3 + + gsoc_sntp/libopts/COPYING.lgplv3@1.0 +0 -0 + + gsoc_sntp/libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/COPYING.mbsd + + gsoc_sntp/libopts/COPYING.mbsd@1.0 +0 -0 + + gsoc_sntp/libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/MakeDefs.inc + + gsoc_sntp/libopts/MakeDefs.inc@1.0 +0 -0 + + gsoc_sntp/libopts/Makefile.am@1.1 +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/Makefile.am + + gsoc_sntp/libopts/Makefile.am@1.0 +0 -0 + + gsoc_sntp/libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/README + + gsoc_sntp/libopts/README@1.0 +0 -0 + + gsoc_sntp/libopts/ag-char-map.h@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/ag-char-map.h + + gsoc_sntp/libopts/ag-char-map.h@1.0 +0 -0 + + gsoc_sntp/libopts/autoopts.c@1.1 +1164 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts.c + + gsoc_sntp/libopts/autoopts.c@1.0 +0 -0 + + gsoc_sntp/libopts/autoopts.h@1.1 +364 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts.h + + gsoc_sntp/libopts/autoopts.h@1.0 +0 -0 + + gsoc_sntp/libopts/autoopts/options.h@1.1 +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts/options.h + + gsoc_sntp/libopts/autoopts/options.h@1.0 +0 -0 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.1 +393 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/autoopts/usage-txt.h + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 + + gsoc_sntp/libopts/boolean.c@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/boolean.c + + gsoc_sntp/libopts/boolean.c@1.0 +0 -0 + + gsoc_sntp/libopts/compat/compat.h@1.1 +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/compat.h + + gsoc_sntp/libopts/compat/compat.h@1.0 +0 -0 + + gsoc_sntp/libopts/compat/pathfind.c@1.1 +338 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/pathfind.c + + gsoc_sntp/libopts/compat/pathfind.c@1.0 +0 -0 + + gsoc_sntp/libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/snprintf.c + + gsoc_sntp/libopts/compat/snprintf.c@1.0 +0 -0 + + gsoc_sntp/libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/strchr.c + + gsoc_sntp/libopts/compat/strchr.c@1.0 +0 -0 + + gsoc_sntp/libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/strdup.c + + gsoc_sntp/libopts/compat/strdup.c@1.0 +0 -0 + + gsoc_sntp/libopts/compat/windows-config.h@1.1 +147 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/compat/windows-config.h + + gsoc_sntp/libopts/compat/windows-config.h@1.0 +0 -0 + + gsoc_sntp/libopts/configfile.c@1.1 +1251 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/configfile.c + + gsoc_sntp/libopts/configfile.c@1.0 +0 -0 + + gsoc_sntp/libopts/cook.c@1.1 +293 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/cook.c + + gsoc_sntp/libopts/cook.c@1.0 +0 -0 + + gsoc_sntp/libopts/enumeration.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/enumeration.c + + gsoc_sntp/libopts/enumeration.c@1.0 +0 -0 + + gsoc_sntp/libopts/environment.c@1.1 +240 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/environment.c + + gsoc_sntp/libopts/environment.c@1.0 +0 -0 + + gsoc_sntp/libopts/file.c@1.1 +169 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/file.c + + gsoc_sntp/libopts/file.c@1.0 +0 -0 + + gsoc_sntp/libopts/genshell.c@1.1 +358 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/genshell.c + + gsoc_sntp/libopts/genshell.c@1.0 +0 -0 + + gsoc_sntp/libopts/genshell.h@1.1 +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/genshell.h + + gsoc_sntp/libopts/genshell.h@1.0 +0 -0 + + gsoc_sntp/libopts/libopts.c@1.1 +38 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/libopts.c + + gsoc_sntp/libopts/libopts.c@1.0 +0 -0 + + gsoc_sntp/libopts/load.c@1.1 +540 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/load.c + + gsoc_sntp/libopts/load.c@1.0 +0 -0 + + gsoc_sntp/libopts/m4/libopts.m4@1.1 +548 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/m4/libopts.m4 + + gsoc_sntp/libopts/m4/libopts.m4@1.0 +0 -0 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/m4/liboptschk.m4 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.0 +0 -0 + + gsoc_sntp/libopts/makeshell.c@1.1 +1099 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/makeshell.c + + gsoc_sntp/libopts/makeshell.c@1.0 +0 -0 + + gsoc_sntp/libopts/nested.c@1.1 +843 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/nested.c + + gsoc_sntp/libopts/nested.c@1.0 +0 -0 + + gsoc_sntp/libopts/numeric.c@1.1 +175 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/numeric.c + + gsoc_sntp/libopts/numeric.c@1.0 +0 -0 + + gsoc_sntp/libopts/parse-duration.c@1.1 +582 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/parse-duration.c + + gsoc_sntp/libopts/parse-duration.c@1.0 +0 -0 + + gsoc_sntp/libopts/parse-duration.h@1.1 +82 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/parse-duration.h + + gsoc_sntp/libopts/parse-duration.h@1.0 +0 -0 + + gsoc_sntp/libopts/pgusage.c@1.1 +140 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/pgusage.c + + gsoc_sntp/libopts/pgusage.c@1.0 +0 -0 + + gsoc_sntp/libopts/proto.h@1.1 +112 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/proto.h + + gsoc_sntp/libopts/proto.h@1.0 +0 -0 + + gsoc_sntp/libopts/putshell.c@1.1 +320 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/putshell.c + + gsoc_sntp/libopts/putshell.c@1.0 +0 -0 + + gsoc_sntp/libopts/reset.c@1.1 +128 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/reset.c + + gsoc_sntp/libopts/reset.c@1.0 +0 -0 + + gsoc_sntp/libopts/restore.c@1.1 +227 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/restore.c + + gsoc_sntp/libopts/restore.c@1.0 +0 -0 + + gsoc_sntp/libopts/save.c@1.1 +790 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/save.c + + gsoc_sntp/libopts/save.c@1.0 +0 -0 + + gsoc_sntp/libopts/sort.c@1.1 +336 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/sort.c + + gsoc_sntp/libopts/sort.c@1.0 +0 -0 + + gsoc_sntp/libopts/stack.c@1.1 +264 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/stack.c + + gsoc_sntp/libopts/stack.c@1.0 +0 -0 + + gsoc_sntp/libopts/streqvcmp.c@1.1 +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/streqvcmp.c + + gsoc_sntp/libopts/streqvcmp.c@1.0 +0 -0 + + gsoc_sntp/libopts/text_mmap.c@1.1 +383 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/text_mmap.c + + gsoc_sntp/libopts/text_mmap.c@1.0 +0 -0 + + gsoc_sntp/libopts/time.c@1.1 +88 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/time.c + + gsoc_sntp/libopts/time.c@1.0 +0 -0 + + gsoc_sntp/libopts/tokenize.c@1.1 +323 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/tokenize.c + + gsoc_sntp/libopts/tokenize.c@1.0 +0 -0 + + gsoc_sntp/libopts/usage.c@1.1 +756 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/usage.c + + gsoc_sntp/libopts/usage.c@1.0 +0 -0 + + gsoc_sntp/libopts/value-type.c@1.1 +123 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/value-type.c + + gsoc_sntp/libopts/value-type.c@1.0 +0 -0 + + gsoc_sntp/libopts/value-type.h@1.1 +25 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/value-type.h + + gsoc_sntp/libopts/value-type.h@1.0 +0 -0 + + gsoc_sntp/libopts/version.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/version.c + + gsoc_sntp/libopts/version.c@1.0 +0 -0 + + gsoc_sntp/libopts/xat-attribute.c@1.1 +114 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/xat-attribute.c + + gsoc_sntp/libopts/xat-attribute.c@1.0 +0 -0 + + gsoc_sntp/libopts/xat-attribute.h@1.1 +22 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/libopts/xat-attribute.h + + gsoc_sntp/libopts/xat-attribute.h@1.0 +0 -0 + + libopts/COPYING.gplv3@1.1 +674 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.gplv3 + + libopts/COPYING.gplv3@1.0 +0 -0 + + libopts/COPYING.lgplv3@1.1 +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.lgplv3 + + libopts/COPYING.lgplv3@1.0 +0 -0 + + libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0 +0 -0 + + libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0 +0 -0 + + libopts/Makefile.am@1.1 +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/Makefile.am + + libopts/Makefile.am@1.0 +0 -0 + + libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/README + + libopts/README@1.0 +0 -0 + + libopts/ag-char-map.h@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/ag-char-map.h + + libopts/ag-char-map.h@1.0 +0 -0 + + libopts/autoopts.c@1.1 +1164 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.c + + libopts/autoopts.c@1.0 +0 -0 + + libopts/autoopts.h@1.1 +364 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.h + + libopts/autoopts.h@1.0 +0 -0 + + libopts/autoopts/options.h@1.1 +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0 +0 -0 + + libopts/autoopts/usage-txt.h@1.1 +393 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0 +0 -0 + + libopts/boolean.c@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/boolean.c + + libopts/boolean.c@1.0 +0 -0 + + libopts/compat/compat.h@1.1 +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/compat.h + + libopts/compat/compat.h@1.0 +0 -0 + + libopts/compat/pathfind.c@1.1 +338 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0 +0 -0 + + libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0 +0 -0 + + libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0 +0 -0 + + libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0 +0 -0 + + libopts/compat/windows-config.h@1.1 +147 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0 +0 -0 + + libopts/configfile.c@1.1 +1251 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/configfile.c + + libopts/configfile.c@1.0 +0 -0 + + libopts/cook.c@1.1 +293 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/cook.c + + libopts/cook.c@1.0 +0 -0 + + libopts/enumeration.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/enumeration.c + + libopts/enumeration.c@1.0 +0 -0 + + libopts/environment.c@1.1 +240 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/environment.c + + libopts/environment.c@1.0 +0 -0 + + libopts/file.c@1.1 +169 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/file.c + + libopts/file.c@1.0 +0 -0 + + libopts/genshell.c@1.1 +358 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.c + + libopts/genshell.c@1.0 +0 -0 + + libopts/genshell.h@1.1 +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.h + + libopts/genshell.h@1.0 +0 -0 + + libopts/libopts.c@1.1 +38 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/libopts.c + + libopts/libopts.c@1.0 +0 -0 + + libopts/load.c@1.1 +540 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/load.c + + libopts/load.c@1.0 +0 -0 + + libopts/m4/libopts.m4@1.1 +548 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0 +0 -0 + + libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0 +0 -0 + + libopts/makeshell.c@1.1 +1099 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/makeshell.c + + libopts/makeshell.c@1.0 +0 -0 + + libopts/nested.c@1.1 +843 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/nested.c + + libopts/nested.c@1.0 +0 -0 + + libopts/numeric.c@1.1 +175 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/numeric.c + + libopts/numeric.c@1.0 +0 -0 + + libopts/parse-duration.c@1.1 +582 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/parse-duration.c + + libopts/parse-duration.c@1.0 +0 -0 + + libopts/parse-duration.h@1.1 +82 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/parse-duration.h + + libopts/parse-duration.h@1.0 +0 -0 + + libopts/pgusage.c@1.1 +140 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/pgusage.c + + libopts/pgusage.c@1.0 +0 -0 + + libopts/proto.h@1.1 +112 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/proto.h + + libopts/proto.h@1.0 +0 -0 + + libopts/putshell.c@1.1 +320 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/putshell.c + + libopts/putshell.c@1.0 +0 -0 + + libopts/reset.c@1.1 +128 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/reset.c + + libopts/reset.c@1.0 +0 -0 + + libopts/restore.c@1.1 +227 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/restore.c + + libopts/restore.c@1.0 +0 -0 + + libopts/save.c@1.1 +790 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/save.c + + libopts/save.c@1.0 +0 -0 + + libopts/sort.c@1.1 +336 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/sort.c + + libopts/sort.c@1.0 +0 -0 + + libopts/stack.c@1.1 +264 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/stack.c + + libopts/stack.c@1.0 +0 -0 + + libopts/streqvcmp.c@1.1 +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0 +0 -0 + + libopts/text_mmap.c@1.1 +383 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/text_mmap.c + + libopts/text_mmap.c@1.0 +0 -0 + + libopts/time.c@1.1 +88 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/time.c + + libopts/time.c@1.0 +0 -0 + + libopts/tokenize.c@1.1 +323 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/tokenize.c + + libopts/tokenize.c@1.0 +0 -0 + + libopts/usage.c@1.1 +756 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/usage.c + + libopts/usage.c@1.0 +0 -0 + + libopts/value-type.c@1.1 +123 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/value-type.c + + libopts/value-type.c@1.0 +0 -0 + + libopts/value-type.h@1.1 +25 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/value-type.h + + libopts/value-type.h@1.0 +0 -0 + + libopts/version.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/version.c + + libopts/version.c@1.0 +0 -0 + + libopts/xat-attribute.c@1.1 +114 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/xat-attribute.c + + libopts/xat-attribute.c@1.0 +0 -0 + + libopts/xat-attribute.h@1.1 +22 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/xat-attribute.h + + libopts/xat-attribute.h@1.0 +0 -0 + + sntp/libopts/COPYING.gplv3@1.1 +674 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.gplv3 + + sntp/libopts/COPYING.gplv3@1.0 +0 -0 + + sntp/libopts/COPYING.lgplv3@1.1 +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.lgplv3 + + sntp/libopts/COPYING.lgplv3@1.0 +0 -0 + + sntp/libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0 +0 -0 + + sntp/libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0 +0 -0 + + sntp/libopts/Makefile.am@1.1 +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0 +0 -0 + + sntp/libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/README + + sntp/libopts/README@1.0 +0 -0 + + sntp/libopts/ag-char-map.h@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/ag-char-map.h + + sntp/libopts/ag-char-map.h@1.0 +0 -0 + + sntp/libopts/autoopts.c@1.1 +1164 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0 +0 -0 + + sntp/libopts/autoopts.h@1.1 +364 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0 +0 -0 + + sntp/libopts/autoopts/options.h@1.1 +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0 +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1 +393 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 + + sntp/libopts/boolean.c@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0 +0 -0 + + sntp/libopts/compat/compat.h@1.1 +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0 +0 -0 + + sntp/libopts/compat/pathfind.c@1.1 +338 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0 +0 -0 + + sntp/libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0 +0 -0 + + sntp/libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0 +0 -0 + + sntp/libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0 +0 -0 + + sntp/libopts/compat/windows-config.h@1.1 +147 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0 +0 -0 + + sntp/libopts/configfile.c@1.1 +1251 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0 +0 -0 + + sntp/libopts/cook.c@1.1 +293 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0 +0 -0 + + sntp/libopts/enumeration.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0 +0 -0 + + sntp/libopts/environment.c@1.1 +240 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0 +0 -0 + + sntp/libopts/file.c@1.1 +169 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/file.c + + sntp/libopts/file.c@1.0 +0 -0 + + sntp/libopts/genshell.c@1.1 +358 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0 +0 -0 + + sntp/libopts/genshell.h@1.1 +165 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0 +0 -0 + + sntp/libopts/libopts.c@1.1 +38 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0 +0 -0 + + sntp/libopts/load.c@1.1 +540 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/load.c + + sntp/libopts/load.c@1.0 +0 -0 + + sntp/libopts/m4/libopts.m4@1.1 +548 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0 +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0 +0 -0 + + sntp/libopts/makeshell.c@1.1 +1099 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0 +0 -0 + + sntp/libopts/nested.c@1.1 +843 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0 +0 -0 + + sntp/libopts/numeric.c@1.1 +175 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0 +0 -0 + + sntp/libopts/parse-duration.c@1.1 +582 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/parse-duration.c + + sntp/libopts/parse-duration.c@1.0 +0 -0 + + sntp/libopts/parse-duration.h@1.1 +82 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/parse-duration.h + + sntp/libopts/parse-duration.h@1.0 +0 -0 + + sntp/libopts/pgusage.c@1.1 +140 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0 +0 -0 + + sntp/libopts/proto.h@1.1 +112 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0 +0 -0 + + sntp/libopts/putshell.c@1.1 +320 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0 +0 -0 + + sntp/libopts/reset.c@1.1 +128 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/reset.c + + sntp/libopts/reset.c@1.0 +0 -0 + + sntp/libopts/restore.c@1.1 +227 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0 +0 -0 + + sntp/libopts/save.c@1.1 +790 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/save.c + + sntp/libopts/save.c@1.0 +0 -0 + + sntp/libopts/sort.c@1.1 +336 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0 +0 -0 + + sntp/libopts/stack.c@1.1 +264 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0 +0 -0 + + sntp/libopts/streqvcmp.c@1.1 +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0 +0 -0 + + sntp/libopts/text_mmap.c@1.1 +383 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0 +0 -0 + + sntp/libopts/time.c@1.1 +88 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/time.c + + sntp/libopts/time.c@1.0 +0 -0 + + sntp/libopts/tokenize.c@1.1 +323 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0 +0 -0 + + sntp/libopts/usage.c@1.1 +756 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0 +0 -0 + + sntp/libopts/value-type.c@1.1 +123 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/value-type.c + + sntp/libopts/value-type.c@1.0 +0 -0 + + sntp/libopts/value-type.h@1.1 +25 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/value-type.h + + sntp/libopts/value-type.h@1.0 +0 -0 + + sntp/libopts/version.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/version.c + + sntp/libopts/version.c@1.0 +0 -0 + + sntp/libopts/xat-attribute.c@1.1 +114 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/xat-attribute.c + + sntp/libopts/xat-attribute.c@1.0 +0 -0 + + sntp/libopts/xat-attribute.h@1.1 +22 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/xat-attribute.h + + sntp/libopts/xat-attribute.h@1.0 +0 -0 + +ChangeSet@1.1914, 2009-07-20 00:18:45-04:00, stenn@whimsy.udel.edu + [Bug 1248] RES_MSSNTP typo in ntp_proto.c + + ChangeLog@1.374 +1 -0 + [Bug 1248] RES_MSSNTP typo in ntp_proto.c + + ntpd/ntp_proto.c@1.292 +1 -1 + [Bug 1248] RES_MSSNTP typo in ntp_proto.c + +ChangeSet@1.1913, 2009-07-19 22:02:21-04:00, stenn@pogo.udel.edu + distribute ntp_lists.h + + include/Makefile.am@1.34 +1 -0 + distribute ntp_lists.h + +ChangeSet@1.1910.1.1, 2009-07-20 00:11:58+00:00, davehart@shiny.ad.hartbrothers.com + Log warning about signd operations blocking ntpd when mssntp restrict keyword seen + + ChangeLog@1.371.1.1 +1 -0 + Log warning about signd operations blocking ntpd when mssntp restrict keyword seen + + ntpd/ntp_config.c@1.198 +13 -0 + Log warning about signd operations blocking ntpd when mssntp restrict keyword seen + +ChangeSet@1.1901.4.1, 2009-07-16 16:23:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1246] use a common template for singly-linked lists, convert most + doubly-linked lists to singly-linked. + + ChangeLog@1.362.4.1 +2 -0 + [Bug 1246] use a common template for singly-linked lists, convert most + doubly-linked lists to singly-linked. + + include/ntp.h@1.159.1.1 +24 -25 + use singly-linked lists instead of ISC's doubly-linked + + include/ntp_io.h@1.10 +3 -5 + remove no-longer-needed doubly-linked list initialization routines + + include/ntp_lists.h@1.1 +104 -0 + singly-linked list template macros + + include/ntp_lists.h@1.0 +0 -0 + + include/recvbuff.h@1.19 +5 -6 + use singly-linked list for free_recv_buff + + libntp/recvbuff.c@1.33 +29 -42 + use singly-linked list for free_recv_buff + + ntpd/ntp_io.c@1.289.2.1 +128 -203 + use singly-linked lists instead of ISC's doubly-linked + + ntpd/ntp_peer.c@1.121 +51 -72 + use new common singly-linked list template macros for + peer_hash and assoc_hash + + ntpd/ntpd.c@1.105 +1 -5 + remove no-longer-needed doubly-linked list initialization routines + + ports/winnt/libntp/libntp.dsp@1.35 +4 -0 + add include/ntp_lists.h reference + + ports/winnt/libntp/libntp.vcproj@1.9 +4 -0 + add include/ntp_lists.h reference + + ports/winnt/ntpd/ntp_iocompletionport.c@1.44.1.1 +20 -13 + use singly-linked list for compl_info_list + + ports/winnt/ntpd/ntpd.vcproj@1.10 +5 -0 + add include/ntp_lists.h reference + +ChangeSet@1.1910, 2009-07-16 07:54:10-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P189 + TAG: NTP_4_2_5P189 + + ChangeLog@1.371 +1 -0 + NTP_4_2_5P189 + + gsoc_sntp/sntp-opts.c@1.50 +2 -2 + NTP_4_2_5P189 + + gsoc_sntp/sntp-opts.h@1.50 +3 -3 + NTP_4_2_5P189 + + gsoc_sntp/sntp-opts.texi@1.50 +1 -1 + NTP_4_2_5P189 + + gsoc_sntp/sntp.1@1.50 +2 -2 + NTP_4_2_5P189 + + ntpd/ntpd-opts.c@1.182 +2 -2 + NTP_4_2_5P189 + + ntpd/ntpd-opts.h@1.182 +3 -3 + NTP_4_2_5P189 + + ntpd/ntpd-opts.texi@1.180 +1 -1 + NTP_4_2_5P189 + + ntpd/ntpd.1@1.180 +2 -2 + NTP_4_2_5P189 + + ntpdc/ntpdc-opts.c@1.177 +2 -2 + NTP_4_2_5P189 + + ntpdc/ntpdc-opts.h@1.177 +3 -3 + NTP_4_2_5P189 + + ntpdc/ntpdc-opts.texi@1.176 +1 -1 + NTP_4_2_5P189 + + ntpdc/ntpdc.1@1.176 +2 -2 + NTP_4_2_5P189 + + ntpq/ntpq-opts.c@1.177 +2 -2 + NTP_4_2_5P189 + + ntpq/ntpq-opts.h@1.177 +3 -3 + NTP_4_2_5P189 + + ntpq/ntpq-opts.texi@1.176 +1 -1 + NTP_4_2_5P189 + + ntpq/ntpq.1@1.176 +2 -2 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd-opts.c@1.58 +2 -2 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd-opts.h@1.58 +3 -3 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd-opts.texi@1.58 +1 -1 + NTP_4_2_5P189 + + ntpsnmpd/ntpsnmpd.1@1.58 +2 -2 + NTP_4_2_5P189 + + packageinfo.sh@1.192 +1 -1 + NTP_4_2_5P189 + + sntp/sntp-opts.c@1.177 +2 -2 + NTP_4_2_5P189 + + sntp/sntp-opts.h@1.177 +3 -3 + NTP_4_2_5P189 + + sntp/sntp-opts.texi@1.176 +1 -1 + NTP_4_2_5P189 + + sntp/sntp.1@1.176 +2 -2 + NTP_4_2_5P189 + + util/ntp-keygen-opts.c@1.180 +2 -2 + NTP_4_2_5P189 + + util/ntp-keygen-opts.h@1.180 +3 -3 + NTP_4_2_5P189 + + util/ntp-keygen-opts.texi@1.179 +1 -1 + NTP_4_2_5P189 + + util/ntp-keygen.1@1.179 +2 -2 + NTP_4_2_5P189 + +ChangeSet@1.1909, 2009-07-15 16:51:50-04:00, stenn@whimsy.udel.edu + Documentation cleanup from Dave Mills + + ChangeLog@1.370 +1 -0 + Documentation cleanup from Dave Mills + + html/accopt.html@1.30 +99 -28 + Documentation cleanup from Dave Mills + + html/assoc.html@1.28 +10 -1 + Documentation cleanup from Dave Mills + + html/audio.html@1.21 +29 -4 + Documentation cleanup from Dave Mills + + html/authopt.html@1.50 +18 -2 + Documentation cleanup from Dave Mills + + html/bugs.html@1.5 +4 -1 + Documentation cleanup from Dave Mills + + html/config.html@1.23 +1 -1 + Documentation cleanup from Dave Mills + + html/confopt.html@1.45 +15 -13 + Documentation cleanup from Dave Mills + + html/debug.html@1.26 +29 -5 + Documentation cleanup from Dave Mills + + html/decode.html@1.10 +9 -5 + Documentation cleanup from Dave Mills + + html/extern.html@1.15 +21 -4 + Documentation cleanup from Dave Mills + + html/gadget.html@1.4 +9 -1 + Documentation cleanup from Dave Mills + + html/howto.html@1.22 +19 -4 + Documentation cleanup from Dave Mills + + html/index.html@1.40 +7 -2 + Documentation cleanup from Dave Mills + + html/manyopt.html@1.19 +5 -1 + Documentation cleanup from Dave Mills + +ChangeSet@1.1908, 2009-07-15 07:52:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P188 + TAG: NTP_4_2_5P188 + + ChangeLog@1.369 +1 -0 + NTP_4_2_5P188 + + gsoc_sntp/sntp-opts.c@1.49 +2 -2 + NTP_4_2_5P188 + + gsoc_sntp/sntp-opts.h@1.49 +3 -3 + NTP_4_2_5P188 + + gsoc_sntp/sntp-opts.texi@1.49 +1 -1 + NTP_4_2_5P188 + + gsoc_sntp/sntp.1@1.49 +2 -2 + NTP_4_2_5P188 + + ntpd/ntpd-opts.c@1.181 +2 -2 + NTP_4_2_5P188 + + ntpd/ntpd-opts.h@1.181 +3 -3 + NTP_4_2_5P188 + + ntpd/ntpd-opts.texi@1.179 +2 -2 + NTP_4_2_5P188 + + ntpd/ntpd.1@1.179 +2 -2 + NTP_4_2_5P188 + + ntpdc/ntpdc-opts.c@1.176 +2 -2 + NTP_4_2_5P188 + + ntpdc/ntpdc-opts.h@1.176 +3 -3 + NTP_4_2_5P188 + + ntpdc/ntpdc-opts.texi@1.175 +2 -2 + NTP_4_2_5P188 + + ntpdc/ntpdc.1@1.175 +2 -2 + NTP_4_2_5P188 + + ntpq/ntpq-opts.c@1.176 +2 -2 + NTP_4_2_5P188 + + ntpq/ntpq-opts.h@1.176 +3 -3 + NTP_4_2_5P188 + + ntpq/ntpq-opts.texi@1.175 +2 -2 + NTP_4_2_5P188 + + ntpq/ntpq.1@1.175 +2 -2 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd-opts.c@1.57 +2 -2 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd-opts.h@1.57 +3 -3 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd-opts.texi@1.57 +1 -1 + NTP_4_2_5P188 + + ntpsnmpd/ntpsnmpd.1@1.57 +2 -2 + NTP_4_2_5P188 + + packageinfo.sh@1.191 +1 -1 + NTP_4_2_5P188 + + sntp/sntp-opts.c@1.176 +2 -2 + NTP_4_2_5P188 + + sntp/sntp-opts.h@1.176 +3 -3 + NTP_4_2_5P188 + + sntp/sntp-opts.texi@1.175 +1 -1 + NTP_4_2_5P188 + + sntp/sntp.1@1.175 +2 -2 + NTP_4_2_5P188 + + util/ntp-keygen-opts.c@1.179 +2 -2 + NTP_4_2_5P188 + + util/ntp-keygen-opts.h@1.179 +3 -3 + NTP_4_2_5P188 + + util/ntp-keygen-opts.texi@1.178 +2 -2 + NTP_4_2_5P188 + + util/ntp-keygen.1@1.178 +2 -2 + NTP_4_2_5P188 + +ChangeSet@1.1907, 2009-07-15 00:35:46-04:00, stenn@whimsy.udel.edu + [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187 + + ChangeLog@1.368 +1 -0 + [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187 + + ntpd/ntp_proto.c@1.291 +1 -2 + [Bug 1245] Broken xmt time sent in fast_xmit() of 4.2.5p187 + +ChangeSet@1.1906, 2009-07-11 07:57:23-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P187 + TAG: NTP_4_2_5P187 + + ChangeLog@1.367 +1 -0 + NTP_4_2_5P187 + + gsoc_sntp/sntp-opts.c@1.48 +2 -2 + NTP_4_2_5P187 + + gsoc_sntp/sntp-opts.h@1.48 +3 -3 + NTP_4_2_5P187 + + gsoc_sntp/sntp-opts.texi@1.48 +1 -1 + NTP_4_2_5P187 + + gsoc_sntp/sntp.1@1.48 +2 -2 + NTP_4_2_5P187 + + ntpd/ntpd-opts.c@1.180 +2 -2 + NTP_4_2_5P187 + + ntpd/ntpd-opts.h@1.180 +3 -3 + NTP_4_2_5P187 + + ntpd/ntpd-opts.texi@1.178 +1 -1 + NTP_4_2_5P187 + + ntpd/ntpd.1@1.178 +2 -2 + NTP_4_2_5P187 + + ntpdc/ntpdc-opts.c@1.175 +2 -2 + NTP_4_2_5P187 + + ntpdc/ntpdc-opts.h@1.175 +3 -3 + NTP_4_2_5P187 + + ntpdc/ntpdc-opts.texi@1.174 +1 -1 + NTP_4_2_5P187 + + ntpdc/ntpdc.1@1.174 +2 -2 + NTP_4_2_5P187 + + ntpq/ntpq-opts.c@1.175 +2 -2 + NTP_4_2_5P187 + + ntpq/ntpq-opts.h@1.175 +3 -3 + NTP_4_2_5P187 + + ntpq/ntpq-opts.texi@1.174 +1 -1 + NTP_4_2_5P187 + + ntpq/ntpq.1@1.174 +2 -2 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd-opts.c@1.56 +2 -2 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd-opts.h@1.56 +3 -3 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd-opts.texi@1.56 +1 -1 + NTP_4_2_5P187 + + ntpsnmpd/ntpsnmpd.1@1.56 +2 -2 + NTP_4_2_5P187 + + packageinfo.sh@1.190 +1 -1 + NTP_4_2_5P187 + + sntp/sntp-opts.c@1.175 +2 -2 + NTP_4_2_5P187 + + sntp/sntp-opts.h@1.175 +3 -3 + NTP_4_2_5P187 + + sntp/sntp-opts.texi@1.174 +1 -1 + NTP_4_2_5P187 + + sntp/sntp.1@1.174 +2 -2 + NTP_4_2_5P187 + + util/ntp-keygen-opts.c@1.178 +2 -2 + NTP_4_2_5P187 + + util/ntp-keygen-opts.h@1.178 +3 -3 + NTP_4_2_5P187 + + util/ntp-keygen-opts.texi@1.177 +1 -1 + NTP_4_2_5P187 + + util/ntp-keygen.1@1.177 +2 -2 + NTP_4_2_5P187 + +ChangeSet@1.1901.2.2, 2009-07-11 01:48:52-04:00, stenn@whimsy.udel.edu + [Bug 1242] Remove --enable-wintime + + configure.ac@1.447 +0 -25 + [Bug 1242] Remove --enable-wintime + +ChangeSet@1.1901.3.1, 2009-07-11 05:47:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1237] Windows serial code treat CR and LF both as line + terminators. + [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. + document fudge time1 as PPS offset, fudge time2 as serial timecode offset + for driver20.html (NMEA) + + ChangeLog@1.362.3.1 +5 -1 + [Bug 1237] Windows serial code treat CR and LF both as line + terminators. + [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. + + html/drivers/driver20.html@1.20 +2 -2 + Document fudge time2 as serial-only offset, time1 as PPS-only + + ntpd/refclock_nmea.c@1.41 +14 -2 + [Bug 1238] use fudge time2 for serial timecode offset in NMEA driver. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.45 +22 -2 + [Bug 1237] Windows serial code treat CR and LF both as line terminators. + +ChangeSet@1.1901.2.1, 2009-07-11 01:37:42-04:00, stenn@whimsy.udel.edu + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ChangeLog@1.362.2.1 +3 -0 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + html/accopt.html@1.29 +13 -12 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + include/ntp.h@1.160 +15 -16 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_config.c@1.197 +1 -0 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_parser.c@1.39 +897 -887 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_parser.h@1.23 +203 -201 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_parser.y@1.34 +2 -0 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + + ntpd/ntp_proto.c@1.290 +35 -39 + Added restrict keyword "mssntp" for Samba4 DC operation, by Dave Mills + +ChangeSet@1.1901.1.3, 2009-07-11 04:41:58+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child + + ChangeLog@1.362.1.3 +1 -0 + [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child + + include/ntpd.h@1.129 +3 -1 + conditionalize kill_asyncio(), not used on Windows + + ntpd/ntp_io.c@1.289.1.1 +13 -0 + [Bug 1244] NTP_INSIST(fd != maxactivefd) failure in intres child + +ChangeSet@1.1901.1.2, 2009-07-08 07:53:10-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P186 + TAG: NTP_4_2_5P186 + + ChangeLog@1.362.1.2 +1 -0 + NTP_4_2_5P186 + + gsoc_sntp/sntp-opts.c@1.47 +2 -2 + NTP_4_2_5P186 + + gsoc_sntp/sntp-opts.h@1.47 +3 -3 + NTP_4_2_5P186 + + gsoc_sntp/sntp-opts.texi@1.47 +1 -1 + NTP_4_2_5P186 + + gsoc_sntp/sntp.1@1.47 +2 -2 + NTP_4_2_5P186 + + ntpd/ntpd-opts.c@1.179 +2 -2 + NTP_4_2_5P186 + + ntpd/ntpd-opts.h@1.179 +3 -3 + NTP_4_2_5P186 + + ntpd/ntpd-opts.texi@1.177 +1 -1 + NTP_4_2_5P186 + + ntpd/ntpd.1@1.177 +2 -2 + NTP_4_2_5P186 + + ntpdc/ntpdc-opts.c@1.174 +2 -2 + NTP_4_2_5P186 + + ntpdc/ntpdc-opts.h@1.174 +3 -3 + NTP_4_2_5P186 + + ntpdc/ntpdc-opts.texi@1.173 +1 -1 + NTP_4_2_5P186 + + ntpdc/ntpdc.1@1.173 +2 -2 + NTP_4_2_5P186 + + ntpq/ntpq-opts.c@1.174 +2 -2 + NTP_4_2_5P186 + + ntpq/ntpq-opts.h@1.174 +3 -3 + NTP_4_2_5P186 + + ntpq/ntpq-opts.texi@1.173 +1 -1 + NTP_4_2_5P186 + + ntpq/ntpq.1@1.173 +2 -2 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd-opts.c@1.55 +2 -2 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd-opts.h@1.55 +3 -3 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd-opts.texi@1.55 +1 -1 + NTP_4_2_5P186 + + ntpsnmpd/ntpsnmpd.1@1.55 +2 -2 + NTP_4_2_5P186 + + packageinfo.sh@1.189 +1 -1 + NTP_4_2_5P186 + + sntp/sntp-opts.c@1.174 +2 -2 + NTP_4_2_5P186 + + sntp/sntp-opts.h@1.174 +3 -3 + NTP_4_2_5P186 + + sntp/sntp-opts.texi@1.173 +1 -1 + NTP_4_2_5P186 + + sntp/sntp.1@1.173 +2 -2 + NTP_4_2_5P186 + + util/ntp-keygen-opts.c@1.177 +2 -2 + NTP_4_2_5P186 + + util/ntp-keygen-opts.h@1.177 +3 -3 + NTP_4_2_5P186 + + util/ntp-keygen-opts.texi@1.176 +1 -1 + NTP_4_2_5P186 + + util/ntp-keygen.1@1.176 +2 -2 + NTP_4_2_5P186 + +ChangeSet@1.1901.1.1, 2009-07-08 02:47:48-04:00, stenn@whimsy.udel.edu + ntp_proto.c cleanup from Dave Mills + + ChangeLog@1.362.1.1 +1 -0 + ntp_proto.c cleanup from Dave Mills + + ntpd/ntp_proto.c@1.289 +19 -30 + cleanup from Dave Mills + +ChangeSet@1.1889.2.1, 2009-07-03 03:26:28+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + ntp_io.c: + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + more detailed DPRINTFs + + ChangeLog@1.351.2.1 +1 -0 + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + + ntpd/ntp_io.c@1.288.1.1 +10 -3 + [Bug 1042] multicast listeners IPv4+6 ignore new interfaces + more detailed DPRINTFs + +ChangeSet@1.1901, 2009-07-01 07:53:52-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P185 + TAG: NTP_4_2_5P185 + + ChangeLog@1.362 +1 -0 + NTP_4_2_5P185 + + gsoc_sntp/sntp-opts.c@1.46 +2 -2 + NTP_4_2_5P185 + + gsoc_sntp/sntp-opts.h@1.46 +3 -3 + NTP_4_2_5P185 + + gsoc_sntp/sntp-opts.texi@1.46 +1 -1 + NTP_4_2_5P185 + + gsoc_sntp/sntp.1@1.46 +2 -2 + NTP_4_2_5P185 + + ntpd/ntpd-opts.c@1.178 +2 -2 + NTP_4_2_5P185 + + ntpd/ntpd-opts.h@1.178 +3 -3 + NTP_4_2_5P185 + + ntpd/ntpd-opts.texi@1.176 +1 -1 + NTP_4_2_5P185 + + ntpd/ntpd.1@1.176 +2 -2 + NTP_4_2_5P185 + + ntpdc/ntpdc-opts.c@1.173 +2 -2 + NTP_4_2_5P185 + + ntpdc/ntpdc-opts.h@1.173 +3 -3 + NTP_4_2_5P185 + + ntpdc/ntpdc-opts.texi@1.172 +1 -1 + NTP_4_2_5P185 + + ntpdc/ntpdc.1@1.172 +2 -2 + NTP_4_2_5P185 + + ntpq/ntpq-opts.c@1.173 +2 -2 + NTP_4_2_5P185 + + ntpq/ntpq-opts.h@1.173 +3 -3 + NTP_4_2_5P185 + + ntpq/ntpq-opts.texi@1.172 +1 -1 + NTP_4_2_5P185 + + ntpq/ntpq.1@1.172 +2 -2 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd-opts.c@1.54 +2 -2 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd-opts.h@1.54 +3 -3 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd-opts.texi@1.54 +1 -1 + NTP_4_2_5P185 + + ntpsnmpd/ntpsnmpd.1@1.54 +2 -2 + NTP_4_2_5P185 + + packageinfo.sh@1.188 +1 -1 + NTP_4_2_5P185 + + sntp/sntp-opts.c@1.173 +2 -2 + NTP_4_2_5P185 + + sntp/sntp-opts.h@1.173 +3 -3 + NTP_4_2_5P185 + + sntp/sntp-opts.texi@1.172 +1 -1 + NTP_4_2_5P185 + + sntp/sntp.1@1.172 +2 -2 + NTP_4_2_5P185 + + util/ntp-keygen-opts.c@1.176 +2 -2 + NTP_4_2_5P185 + + util/ntp-keygen-opts.h@1.176 +3 -3 + NTP_4_2_5P185 + + util/ntp-keygen-opts.texi@1.175 +1 -1 + NTP_4_2_5P185 + + util/ntp-keygen.1@1.175 +2 -2 + NTP_4_2_5P185 + +ChangeSet@1.1900, 2009-07-01 03:06:34-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.361 +2 -1 + Documentation updates from Dave Mills + + html/miscopt.html@1.43 +2 -2 + Documentation updates from Dave Mills + + html/ntpd.html@1.49 +2 -2 + Documentation updates from Dave Mills + + html/prefer.html@1.22 +134 -31 + Documentation updates from Dave Mills + +ChangeSet@1.1898, 2009-06-30 14:46:05-04:00, clemens@pogo.udel.edu + Fix order of declarations. + + ntpd/refclock_oncore.c@1.77 +1 -2 + +ChangeSet@1.1895.1.2, 2009-06-30 07:59:26+00:00, davehart@shiny.ad.hartbrothers.com + driver20.html: + note fudge flag1 now enables/disables (default) PPSAPI support + make bitrate setting values more obvious to those not fluent in binary shifting + ChangeLog: + punctuation + + ChangeLog@1.359 +1 -1 + punctuation + + html/drivers/driver20.html@1.19 +6 -6 + note fudge flag1 now enables/disables (default) PPSAPI support + make bitrate setting values more obvious to those not fluent in binary shifting + +ChangeSet@1.1897, 2009-06-30 03:41:23-04:00, stenn@pogo.udel.edu + typos + + ChangeLog@1.357.1.2 +2 -2 + typos + + ChangeLog@1.357.1.1, clemens@pogo.udel.edu +3 -0 + Declaration order fixed. + +ChangeSet@1.1896, 2009-06-25 02:13:57-04:00, clemens@pogo.udel.edu + ChangeLog additon, ONCORE use of #if 0 where it used #ifdef DEBUG + + ntpd/refclock_oncore.c@1.76 +14 -22 + No BUG[]. NTP now uses the DEBUG preprocessor variable. I have now bracketed + private debug statements with #if 0 rather than #ifdef DEBUG + +ChangeSet@1.1895, 2009-06-24 07:52:37-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P184 + TAG: NTP_4_2_5P184 + + ChangeLog@1.357 +1 -0 + NTP_4_2_5P184 + + gsoc_sntp/sntp-opts.c@1.45 +2 -2 + NTP_4_2_5P184 + + gsoc_sntp/sntp-opts.h@1.45 +3 -3 + NTP_4_2_5P184 + + gsoc_sntp/sntp-opts.texi@1.45 +1 -1 + NTP_4_2_5P184 + + gsoc_sntp/sntp.1@1.45 +2 -2 + NTP_4_2_5P184 + + ntpd/ntpd-opts.c@1.177 +2 -2 + NTP_4_2_5P184 + + ntpd/ntpd-opts.h@1.177 +3 -3 + NTP_4_2_5P184 + + ntpd/ntpd-opts.texi@1.175 +1 -1 + NTP_4_2_5P184 + + ntpd/ntpd.1@1.175 +2 -2 + NTP_4_2_5P184 + + ntpdc/ntpdc-opts.c@1.172 +2 -2 + NTP_4_2_5P184 + + ntpdc/ntpdc-opts.h@1.172 +3 -3 + NTP_4_2_5P184 + + ntpdc/ntpdc-opts.texi@1.171 +1 -1 + NTP_4_2_5P184 + + ntpdc/ntpdc.1@1.171 +2 -2 + NTP_4_2_5P184 + + ntpq/ntpq-opts.c@1.172 +2 -2 + NTP_4_2_5P184 + + ntpq/ntpq-opts.h@1.172 +3 -3 + NTP_4_2_5P184 + + ntpq/ntpq-opts.texi@1.171 +1 -1 + NTP_4_2_5P184 + + ntpq/ntpq.1@1.171 +2 -2 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd-opts.c@1.53 +2 -2 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd-opts.h@1.53 +3 -3 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd-opts.texi@1.53 +1 -1 + NTP_4_2_5P184 + + ntpsnmpd/ntpsnmpd.1@1.53 +2 -2 + NTP_4_2_5P184 + + packageinfo.sh@1.187 +1 -1 + NTP_4_2_5P184 + + sntp/sntp-opts.c@1.172 +2 -2 + NTP_4_2_5P184 + + sntp/sntp-opts.h@1.172 +3 -3 + NTP_4_2_5P184 + + sntp/sntp-opts.texi@1.171 +1 -1 + NTP_4_2_5P184 + + sntp/sntp.1@1.171 +2 -2 + NTP_4_2_5P184 + + util/ntp-keygen-opts.c@1.175 +2 -2 + NTP_4_2_5P184 + + util/ntp-keygen-opts.h@1.175 +3 -3 + NTP_4_2_5P184 + + util/ntp-keygen-opts.texi@1.174 +1 -1 + NTP_4_2_5P184 + + util/ntp-keygen.1@1.174 +2 -2 + NTP_4_2_5P184 + +ChangeSet@1.1894, 2009-06-24 01:25:37-04:00, stenn@whimsy.udel.edu + [Bg 1233] atom refclock fudge time1 sign flipped in 4.2.4p164 + + ChangeLog@1.356 +1 -0 + [Bg 1233] atom refclock fudge time1 sign flipped in 4.2.4p164 + + ntpd/ntp_refclock.c@1.89 +1 -1 + [Bg 1233] atom refclock fudge time1 sign flipped in 4.2.4p164 + +ChangeSet@1.1893, 2009-06-23 07:55:19-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P183 + TAG: NTP_4_2_5P183 + + ChangeLog@1.355 +1 -0 + NTP_4_2_5P183 + + gsoc_sntp/sntp-opts.c@1.44 +2 -2 + NTP_4_2_5P183 + + gsoc_sntp/sntp-opts.h@1.44 +3 -3 + NTP_4_2_5P183 + + gsoc_sntp/sntp-opts.texi@1.44 +1 -1 + NTP_4_2_5P183 + + gsoc_sntp/sntp.1@1.44 +2 -2 + NTP_4_2_5P183 + + ntpd/ntpd-opts.c@1.176 +2 -2 + NTP_4_2_5P183 + + ntpd/ntpd-opts.h@1.176 +3 -3 + NTP_4_2_5P183 + + ntpd/ntpd-opts.texi@1.174 +2 -2 + NTP_4_2_5P183 + + ntpd/ntpd.1@1.174 +2 -2 + NTP_4_2_5P183 + + ntpdc/ntpdc-opts.c@1.171 +2 -2 + NTP_4_2_5P183 + + ntpdc/ntpdc-opts.h@1.171 +3 -3 + NTP_4_2_5P183 + + ntpdc/ntpdc-opts.texi@1.170 +2 -2 + NTP_4_2_5P183 + + ntpdc/ntpdc.1@1.170 +2 -2 + NTP_4_2_5P183 + + ntpq/ntpq-opts.c@1.171 +2 -2 + NTP_4_2_5P183 + + ntpq/ntpq-opts.h@1.171 +3 -3 + NTP_4_2_5P183 + + ntpq/ntpq-opts.texi@1.170 +2 -2 + NTP_4_2_5P183 + + ntpq/ntpq.1@1.170 +2 -2 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd-opts.c@1.52 +2 -2 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd-opts.h@1.52 +3 -3 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd-opts.texi@1.52 +1 -1 + NTP_4_2_5P183 + + ntpsnmpd/ntpsnmpd.1@1.52 +2 -2 + NTP_4_2_5P183 + + packageinfo.sh@1.186 +1 -1 + NTP_4_2_5P183 + + sntp/sntp-opts.c@1.171 +2 -2 + NTP_4_2_5P183 + + sntp/sntp-opts.h@1.171 +3 -3 + NTP_4_2_5P183 + + sntp/sntp-opts.texi@1.170 +1 -1 + NTP_4_2_5P183 + + sntp/sntp.1@1.170 +2 -2 + NTP_4_2_5P183 + + util/ntp-keygen-opts.c@1.174 +2 -2 + NTP_4_2_5P183 + + util/ntp-keygen-opts.h@1.174 +3 -3 + NTP_4_2_5P183 + + util/ntp-keygen-opts.texi@1.173 +2 -2 + NTP_4_2_5P183 + + util/ntp-keygen.1@1.173 +2 -2 + NTP_4_2_5P183 + +ChangeSet@1.1881.3.2, 2009-06-19 02:45:57+00:00, hart@pogo.udel.edu + ChangeLog: + [Bug 1210], [Bug 1218], ONCORE logs to msyslog as well as clockstats + + ChangeLog@1.343.3.2 +5 -2 + [Bug 1210], [Bug 1218], ONCORE logs to msyslog as well as clockstats + +ChangeSet@1.1889.1.1, 2009-06-18 21:28:09+00:00, davehart@shiny.ad.hartbrothers.com + libntpq.h, ChangeLog: + [Bug 1231] ntpsnmpd build fails after sockaddr union changes + + ChangeLog@1.351.1.1 +1 -0 + [Bug 1231] ntpsnmpd build fails after sockaddr union changes + + ntpq/libntpq.h@1.3 +2 -0 + [Bug 1231] ntpsnmpd build fails after sockaddr union changes + +ChangeSet@1.1890, 2009-06-18 12:35:02+00:00, davehart@shiny.ad.hartbrothers.com + ntp_io.c, ChangeLog: + [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. + nt_clockstuff.c: + fix EOPNOTSUPP macro redefinition warning introduced with support for + PPSAPI on Windows. + + ChangeLog@1.352 +2 -0 + [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. + + ntpd/ntp_io.c@1.289 +24 -4 + [Bug 1196] setsockopt(SO_EXCLUSIVEADDRUSE) can fail on Windows 2000 + and earlier with WSAINVAL, do not log a complaint in that case. + + ports/winnt/ntpd/nt_clockstuff.c@1.34 +8 -1 + fix EOPNOTSUPP macro redefinition warning introduced with support for + PPSAPI on Windows. + +ChangeSet@1.1889, 2009-06-18 08:00:58-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P182 + TAG: NTP_4_2_5P182 + + ChangeLog@1.351 +1 -0 + NTP_4_2_5P182 + + gsoc_sntp/sntp-opts.c@1.43 +2 -2 + NTP_4_2_5P182 + + gsoc_sntp/sntp-opts.h@1.43 +3 -3 + NTP_4_2_5P182 + + gsoc_sntp/sntp-opts.texi@1.43 +1 -1 + NTP_4_2_5P182 + + gsoc_sntp/sntp.1@1.43 +2 -2 + NTP_4_2_5P182 + + ntpd/ntpd-opts.c@1.175 +2 -2 + NTP_4_2_5P182 + + ntpd/ntpd-opts.h@1.175 +3 -3 + NTP_4_2_5P182 + + ntpd/ntpd-opts.texi@1.173 +37 -2 + NTP_4_2_5P182 + + ntpd/ntpd.1@1.173 +17 -2 + NTP_4_2_5P182 + + ntpdc/ntpdc-opts.c@1.170 +2 -2 + NTP_4_2_5P182 + + ntpdc/ntpdc-opts.h@1.170 +3 -3 + NTP_4_2_5P182 + + ntpdc/ntpdc-opts.texi@1.169 +2 -2 + NTP_4_2_5P182 + + ntpdc/ntpdc.1@1.169 +2 -2 + NTP_4_2_5P182 + + ntpq/ntpq-opts.c@1.170 +2 -2 + NTP_4_2_5P182 + + ntpq/ntpq-opts.h@1.170 +3 -3 + NTP_4_2_5P182 + + ntpq/ntpq-opts.texi@1.169 +2 -2 + NTP_4_2_5P182 + + ntpq/ntpq.1@1.169 +2 -2 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd-opts.c@1.51 +2 -2 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd-opts.h@1.51 +3 -3 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd-opts.texi@1.51 +1 -1 + NTP_4_2_5P182 + + ntpsnmpd/ntpsnmpd.1@1.51 +2 -2 + NTP_4_2_5P182 + + packageinfo.sh@1.185 +1 -1 + NTP_4_2_5P182 + + sntp/sntp-opts.c@1.170 +2 -2 + NTP_4_2_5P182 + + sntp/sntp-opts.h@1.170 +3 -3 + NTP_4_2_5P182 + + sntp/sntp-opts.texi@1.169 +1 -1 + NTP_4_2_5P182 + + sntp/sntp.1@1.169 +2 -2 + NTP_4_2_5P182 + + util/ntp-keygen-opts.c@1.173 +2 -2 + NTP_4_2_5P182 + + util/ntp-keygen-opts.h@1.173 +3 -3 + NTP_4_2_5P182 + + util/ntp-keygen-opts.texi@1.172 +2 -2 + NTP_4_2_5P182 + + util/ntp-keygen.1@1.172 +2 -2 + NTP_4_2_5P182 + +ChangeSet@1.1888, 2009-06-18 05:09:12-04:00, stenn@whimsy.udel.edu + Add missing header dependencies to the ntpdc layout verification + + ChangeLog@1.350 +1 -0 + Add missing header dependencies to the ntpdc layout verification + + ntpdc/Makefile.am@1.39 +1 -1 + Add missing header dependencies to the ntpdc layout verification + +ChangeSet@1.1887, 2009-06-18 05:04:55-04:00, stenn@whimsy.udel.edu + prefer.html updates from Dave Mills + + ChangeLog@1.349 +1 -0 + prefer.html updates from Dave Mills + + html/prefer.html@1.21 +31 -134 + prefer.html updates from Dave Mills + +ChangeSet@1.1886, 2009-06-18 08:10:30+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + merge cleanup cleanup + + ChangeLog@1.348 +2 -2 + merge cleanup cleanup + +ChangeSet@1.1881.4.1, 2009-06-18 03:54:37-04:00, stenn@whimsy.udel.edu + [Bug 1229] autokey segfaults in cert_install() + + ChangeLog@1.343.4.1 +1 -0 + [Bug 1229] autokey segfaults in cert_install() + + ntpd/ntp_crypto.c@1.136.1.1 +7 -8 + [Bug 1229] autokey segfaults in cert_install() + +ChangeSet@1.1881.3.1, 2009-06-17 17:02:49-04:00, clemens@pogo.udel.edu + refclock_oncore.c: + BUG[no bug report] A bytes available message for the input subsystem (Debug message). + BUG[no bug report] Change exit statements to return(0) in ONCORE driver top + level program. This signals an error to the calling code. + BUG[1218] The comment on where the oncore driver gets its input file does not + * agree with the code. Change the comment. + BUGS[no bug report] This patch puts back in some code to interpret @@Bl messages + on the VP and extract LEAP SECOND information. See the code for a more complete + comment. + ChangeLog: + Add comment re ONCORE changes to message subsystem. + refclock_oncore.c: + BUG[no bug report] This code adds a message for TRAIM messages. Users often worry about the + driver not starting up, and it is often because of signal strength being low. + Low signal strength will give TRAIM messages. + BUG[1220] OK, big patch, but mostly done mechanically. Change direct calls to write + to clockstats to a call to oncore_log, which now calls the old routine plus msyslog. + Have to set the LOG_LEVELS of the calls for msyslog, and this was done by hand. New + routine oncore_log. + BUGS[no bug report] Users often worry that the code is hung when there is + no output after a restart. If the receiver does not have battery backup + can take up to 30minutes to acuqire an almanac and this is necessary before + the driver can start. This message should reasurre the user that the driver + has not died. + + ChangeLog@1.343.3.1 +2 -0 + Add comment re ONCORE changes to message subsystem. + + ntpd/refclock_oncore.c@1.75 +387 -331 + BUG[1220] OK, big patch, but mostly done mechanically. Change direct calls to write + to clockstats to a call to oncore_log, which now calls the old routine plus msyslog. + Have to set the LOG_LEVELS of the calls for msyslog, and this was done by hand. New + routine oncore_log. + + ntpd/refclock_oncore.c@1.74 +6 -2 + BUG[1218] The comment on where the oncore driver gets its input file does not + * agree with the code. Change the comment. + + + ntpd/refclock_oncore.c@1.73 +11 -6 + BUG[no bug report] Change exit statements to return(0) in ONCORE driver top + level program. This signals an error to the calling code. + + ntpd/refclock_oncore.c@1.72 +4 -0 + BUG[no bug report] A bytes available message for the input subsystem (Debug message). + + + ntpd/refclock_oncore.c@1.71 +8 -1 + BUG[no bug report] This code adds a message for TRAIM messages. Users often worry about the + driver not starting up, and it is often because of signal strength being low. + Low signal strength will give TRAIM messages. + + ntpd/refclock_oncore.c@1.70 +11 -4 + BUGS[no bug report] Users often worry that the code is hung when there is + no output after a restart. If the receiver does not have battery backup + can take up to 30minutes to acuqire an almanac and this is necessary before + the driver can start. This message should reasurre the user that the driver + has not died. + + ntpd/refclock_oncore.c@1.69 +149 -1 + BUGS[no bug report] This patch puts back in some code to interpret @@Bl messages + on the VP and extract LEAP SECOND information. See the code for a more complete + comment. + +ChangeSet@1.1881.2.2, 2009-06-16 04:22:15+00:00, davehart@shiny.ad.hartbrothers.com + remove netsyslog(), equivalent to msyslog() + update ports/winnt/libisc/net.c winnt/include/net.h from BIND 9.6.1b1 + to pick up change to call InitSockets (WSAStartup) in net.c + initialize_action (used by isc_net_probe...() routines), making + it safe to initialize ipv4_works and ipv6_works before init_io() + various fixes for build and runtime issues exposed by building + on Solaris, FreeBSD and Linux and testing on Linux + + ChangeLog@1.343.2.2 +1 -0 + [Bug 1225] Broadcast address miscalculated on Windows 4.2.5p180 + + gsoc_sntp/main.c@1.14 +1 -1 + close_socket -> closesocket + + include/ntp.h@1.159 +3 -2 + spaces -> tab + + include/ntp_rfc2553.h@1.31 +7 -7 + stay out of system namespace by avoiding leading underscore + + include/ntp_select.h@1.4 +10 -5 + add InitSockets prototype (new with updated win32 libisc net.c) + + include/ntp_stdlib.h@1.31 +0 -2 + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + + libntp/lib_strbuf.c@1.5 +3 -2 + correct test for isc_net_probeipvX() return value + + libntp/lib_strbuf.h@1.5 +0 -2 + ipv4_works, ipv6_works are in ntp_stdlib.h + + libntp/msyslog.c@1.22 +0 -51 + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + + libntp/socktoa.c@1.10 +10 -7 + allow AF_UNSPEC again, add missing break to case AF_INET6 + + ntpd/ntp_intres.c@1.63 +7 -14 + remove unused LOCALHOST #define, use ipv6_works instead of isc_net_probeipv6() + use estrdup() + remove \n from msyslog() format string + + ntpd/ntp_io.c@1.288 +40 -51 + one missed merge cleanup + header shuffle to fix unix build + a = b = c == d is an assignment but not the one intended + itf_flags = -> itf_flags |=, parentheses + use isc_net_probe_ipv6only() to decide if we setsockopt(IPV6_V6ONLY) + extraneous '&' broke unix recvfrom/recvmsg + + ntpd/ntpd.c@1.102.1.2 +3 -3 + move init_lib() call back to original location + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + + ntpdate/ntpdate.c@1.67 +24 -34 + if (isc_net_probeipv6() != ISC_R_SUCCESS) -> if (!ipv6_works) + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + remove explicit WSAStartup() call on Windows, now handled in init_lib() + + ntpdc/ntpdc.c@1.65 +3 -10 + if (isc_net_probeipv6() != ISC_R_SUCCESS) -> if (!ipv6_works) + remove Win32InitSockets call, handled by init_lib() now + + ntpq/ntpq.c@1.87 +2 -8 + if (isc_net_probeipv6() != ISC_R_SUCCESS) -> if (!ipv6_works) + remove Win32InitSockets call, handled by init_lib() now + + ports/winnt/include/config.h@1.67.2.2 +0 -2 + remove INCLUDE_IPV6_SUPPORT, INCLUDE_IPV6_MULTICAST_SUPPORT, unneeded + + ports/winnt/include/isc/net.h@1.7 +50 -31 + updated from BIND 9.6.1.b1 + + ports/winnt/libisc/interfaceiter.c@1.9 +6 -6 + [Bug 1225] set netmask before using it to calculate broadcast address + in internal_current() + + ports/winnt/libisc/net.c@1.9 +79 -72 + updated from BIND 9.6.1.b1 + + ports/winnt/libntp/libntp.vcproj@1.8 +0 -22 + remove dnslookup.c reference, unused code unlikely to be revived + + ports/winnt/libntp/setpriority.c@1.2 +28 -0 + Add InitSockets() to libntp for Windows (needed by updated + ports/winnt/libisc/net.c) + + ports/winnt/ntpd/ntp_iocompletionport.c@1.42.1.2 +1 -13 + remove short-lived dummy InitSockets from mixed libisc versions, + now lives in libntp (ports/winnt/libntp/setpriority.c) + remove netsyslog, WSAGetLastError tested equivalent to GetLastError + in Windows NT 4.0 and later at least. + +ChangeSet@1.1873.1.1, 2009-06-15 03:46:17+00:00, davehart@shiny.ad.hartbrothers.com + Use a union for structs sockaddr, sockaddr_storage, sockaddr_in, and + sockaddr_in6 to remove casts and enable type checking. Collapse + some previously separate IPv4/IPv6 paths into a single codepath. + + ChangeLog@1.336.1.1 +4 -1 + Use a union for structs sockaddr, sockaddr_storage, sockaddr_in, and + sockaddr_in6 to remove casts and enable type checking. Collapse + some previously separate IPv4/IPv6 paths into a single codepath. + + gsoc_sntp/main.c@1.13 +5 -5 + struct sockaddr_storage -> sockaddr_u + use sizeof instead of constant + + gsoc_sntp/networking.c@1.19 +117 -130 + struct sockaddr_storage -> sockaddr_u + use sizeof instead of constant + + gsoc_sntp/networking.h@1.12 +6 -8 + struct sockaddr_storage -> sockaddr_u + + gsoc_sntp/utilities.c@1.6 +5 -3 + struct sockaddr_storage -> sockaddr_u + + gsoc_sntp/utilities.h@1.5 +1 -1 + struct sockaddr_storage -> sockaddr_u + + include/interfaceiter.h@1.4 +0 -0 + Rename: BitKeeper/deleted/.del-interfaceiter.h~52531bc -> include/interfaceiter.h + + BitKeeper/deleted/.del-interfaceiter.h~52531bc@1.3 +0 -0 + Rename: include/interfaceiter.h -> BitKeeper/deleted/.del-interfaceiter.h~52531bc + + include/iosignal.h@1.4 +8 -8 + whitespace cleanup + + include/ntp.h@1.155.2.1 +16 -102 + whitespace cleanup, move sockaddr macros to ntp_net.h + + include/ntp_control.h@1.35 +1 -1 + struct sockaddr_storage -> sockaddr_u + + include/ntp_fp.h@1.15 +10 -12 + whitespace cleanup, stay out of system namespace by avoiding + leading underscore for identifiers + + include/ntp_malloc.h@1.3 +5 -5 + stay out of system namespace _ntp_malloc_h -> NTP_MALLOC_H + + include/ntp_net.h@1.2 +189 -0 + move sockaddr macros from ntp.h, add more + + include/ntp_refclock.h@1.23 +2 -2 + struct sockaddr_storage -> sockaddr_u + + include/ntp_request.h@1.35 +5 -5 + rename struct info_monitor.lastdrop to restr to reflect its use + + include/ntp_stdlib.h@1.30 +13 -6 + struct sockaddr_storage -> sockaddr_u + + include/ntpd.h@1.128 +37 -39 + struct sockaddr_storage -> sockaddr_u + whitespace cleanup + + include/ntpsim.h@1.11 +2 -2 + struct sockaddr_storage -> sockaddr_u + + include/recvbuff.h@1.16.1.1 +5 -6 + struct sockaddr_storage -> sockaddr_u + + libntp/a_md5encrypt.c@1.19 +4 -4 + struct sockaddr_storage -> sockaddr_u + + libntp/clocktypes.c@1.18 +4 -4 + spaces to tabs + + libntp/decodenetnum.c@1.6.1.1 +2 -2 + struct sockaddr_storage -> sockaddr_u + + libntp/lib_strbuf.c@1.4 +8 -0 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + libntp/lib_strbuf.h@1.4 +2 -0 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + libntp/netof.c@1.7 +30 -24 + struct sockaddr_storage -> sockaddr_u + + libntp/numtoa.c@1.4 +5 -3 + sprintf -> snprintf + + libntp/recvbuff.c@1.29.1.1 +2 -7 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + libntp/refnumtoa.c@1.6 +13 -10 + struct sockaddr_storage -> sockaddr_u + sprintf -> snprintf + + libntp/socktoa.c@1.9 +12 -13 + struct sockaddr_storage -> sockaddr_u + strcpy -> strncpy + + libntp/socktohost.c@1.6 +4 -4 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_config.c@1.192.1.1 +93 -124 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_control.c@1.111 +9 -9 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_crypto.c@1.137 +15 -23 + struct sockaddr_storage -> sockaddr_u + use DPRINTF + emalloc + strcpy -> estrdup + + ntpd/ntp_intres.c@1.62 +12 -12 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_io.c@1.285.1.1 +1470 -1649 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_monitor.c@1.24 +2 -2 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_peer.c@1.118.1.1 +45 -50 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_proto.c@1.286.1.1 +11 -13 + struct sockaddr_storage -> sockaddr_u + use DPRINTF + + ntpd/ntp_refclock.c@1.86.1.1 +2 -14 + struct sockaddr_storage -> sockaddr_u + ISREFCLOCKADR() no longer assumes address given is IPv4 + + ntpd/ntp_request.c@1.78.1.1 +323 -339 + struct sockaddr_storage -> sockaddr_u + ISREFCLOCKADR() no longer assumes address given is IPv4 + + ntpd/ntp_restrict.c@1.27 +19 -23 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntp_timer.c@1.54 +2 -2 + eliminate truncation warning, whitespace + + ntpd/ntp_util.c@1.72 +14 -14 + struct sockaddr_storage -> sockaddr_u + + ntpd/ntpd.c@1.102.1.1 +18 -15 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + remove 3rd call to setup_logfile(), only needed once after daemonizing + + ntpd/ntpsim.c@1.21 +132 -133 + struct sockaddr_storage -> sockaddr_u + use sizeof(var) not sizeof(typeof(var)) to insulate against breakage + whitespace cleanup + + ntpd/refclock_nmea.c@1.37.1.1 +2 -2 + SOCKLEN misuse + use struct recvbuff.recv_peer instead of unioned recv_srcclock to avoid cast + + ntpdate/ntpdate.c@1.66 +28 -45 + struct sockaddr_storage -> sockaddr_u + + ntpdate/ntpdate.h@1.10 +1 -1 + struct sockaddr_storage -> sockaddr_u + + ntpdc/layout.std@1.8 +2 -2 + rename monlist lastdrop field to restr as it hold restrict bits not time + + ntpdc/ntpdc.c@1.62.1.1 +8 -10 + struct sockaddr_storage -> sockaddr_u + + ntpdc/ntpdc.h@1.9 +2 -2 + struct sockaddr_storage -> sockaddr_u + + ntpdc/ntpdc_ops.c@1.56.1.1 +165 -219 + struct sockaddr_storage -> sockaddr_u + + ntpq/libntpq.c@1.3 +4 -4 + struct sockaddr_storage -> sockaddr_u + + ntpq/libntpq.h@1.2 +1 -1 + struct sockaddr_storage -> sockaddr_u + + ntpq/libntpq_subs.c@1.2 +2 -2 + struct sockaddr_storage -> sockaddr_u + + ntpq/ntpq-subs.c@1.31 +23 -26 + struct sockaddr_storage -> sockaddr_u + + ntpq/ntpq.c@1.84.1.1 +8 -11 + struct sockaddr_storage -> sockaddr_u + ISREFCLOCKADR() includes IS_IPV4 check + + ntpq/ntpq.h@1.7 +3 -3 + struct sockaddr_storage -> sockaddr_u + + ports/winnt/include/config.h@1.65.1.1 +29 -12 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/include/ntp_iocompletionport.h@1.17 +8 -9 + struct sockaddr_storage -> sockaddr_u + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/include/transmitbuff.h@1.6.1.1 +3 -7 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/include/win32_io.h@1.9.1.1 +3 -1 + groundwork for bug 1016 (refclock_arc.c support on Windows) + + ports/winnt/libntp/libntp.vcproj@1.5.1.1 +4 -0 + add ntp_net.h reference + + ports/winnt/libntp/transmitbuff.c@1.7.1.1 +10 -6 + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/ntpd/nt_clockstuff.c@1.29.1.1 +14 -1 + abort if SIZEOF_ macros are wrong on DEBUG + + ports/winnt/ntpd/ntp_iocompletionport.c@1.41.1.1 +68 -67 + struct sockaddr_storage -> sockaddr_u + IPv6 on Windows (cherry picked and previously committed, [Bug 1200]) + + ports/winnt/ntpd/ntpd.vcproj@1.5.1.1 +8 -1 + add ntp_net.h, ntp_signd.c references + no need to exclude refclock_arc.c from build, CLOCK_ARCRON_MSF is not + defined in ports/winnt/include/config.h yet + + ports/winnt/ntpdate/ntpdate.vcproj@1.2.1.1 +52 -0 + add references to a bunch of headers ntpdate uses + +ChangeSet@1.1881.1.2, 2009-06-12 21:05:42+00:00, davehart@shiny.ad.hartbrothers.com + document Windows-specific ntpd options -M, --pccfreq, --usepcc + + html/ntpd.html@1.48 +6 -0 + document Windows-specific ntpd options -M, --pccfreq, --usepcc + +ChangeSet@1.1881.1.1, 2009-06-12 17:53:01+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + + ChangeLog@1.343.1.1 +1 -0 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + + ntpd/ntpd-opts.c@1.174 +63 -2 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + generated by autogen autoopts + + ntpd/ntpd-opts.h@1.174 +23 -5 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + generated by autogen autoopts + + ntpd/ntpd.c@1.103 +2 -2 + Switch to configured logfile from syslog just before init_winnt_time() + (rather than just after) + + ntpd/ntpdbase-opts.def@1.17 +24 -0 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + + ports/winnt/ntpd/nt_clockstuff.c@1.32 +10 -5 + [Bug 1205] Add ntpd --usepcc and --pccfreq options on Windows + +ChangeSet@1.1880.1.1, 2009-06-09 22:36:51+00:00, davehart@shiny.ad.hartbrothers.com + timepps-Solaris.h pps_handle_t changed from pointer to scalar + NMEA refclock converted to use common PPSAPI code + Spectracom refclock added to Windows port of ntpd + + ChangeLog@1.342.1.1 +3 -0 + timepps-Solaris.h pps_handle_t changed from pointer to scalar + NMEA refclock converted to use common PPSAPI code + Spectracom refclock added to Windows port of ntpd + + include/timepps-Solaris.h@1.6 +50 -31 + timepps-Solaris.h pps_handle_t changed from pointer to scalar + + ntpd/refclock_nmea.c@1.39 +77 -242 + NMEA refclock converted to use common PPSAPI code + + ports/winnt/include/config.h@1.67.1.1 +3 -2 + Spectracom refclock added to Windows port of ntpd + + ports/winnt/ntpd/ntpd.vcproj@1.8 +0 -2 + Spectracom refclock added to Windows port of ntpd + +ChangeSet@1.1882, 2009-06-08 17:51:47+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1215] unpeer by association ID + + ChangeLog@1.344 +1 -0 + [Bug 1215] unpeer by association ID + + include/ntp_config.h@1.53 +7 -6 + [Bug 1215] unpeer by association ID + + libntp/recvbuff.c@1.31 +49 -5 + free receive buffers on free, full lists at shutdown on DEBUG + + ntpd/ntp_config.c@1.195 +43 -7 + [Bug 1215] unpeer by association ID + + ports/winnt/include/config.h@1.68 +1 -0 + added commented #define MALLOC_LINT for ease of enabling it + + ports/winnt/ntpd/ntp_iocompletionport.c@1.43 +79 -19 + free receive buffers on free, full lists at shutdown on DEBUG + free in-use (receive or send) I/O buffers at shutdown on DEBUG + +ChangeSet@1.1881, 2009-06-06 07:53:58-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P181 + TAG: NTP_4_2_5P181 + + ChangeLog@1.343 +1 -0 + NTP_4_2_5P181 + + gsoc_sntp/sntp-opts.c@1.42 +2 -2 + NTP_4_2_5P181 + + gsoc_sntp/sntp-opts.h@1.42 +3 -3 + NTP_4_2_5P181 + + gsoc_sntp/sntp-opts.texi@1.42 +1 -1 + NTP_4_2_5P181 + + gsoc_sntp/sntp.1@1.42 +2 -2 + NTP_4_2_5P181 + + ntpd/ntpd-opts.c@1.173 +2 -2 + NTP_4_2_5P181 + + ntpd/ntpd-opts.h@1.173 +3 -3 + NTP_4_2_5P181 + + ntpd/ntpd-opts.texi@1.172 +1 -1 + NTP_4_2_5P181 + + ntpd/ntpd.1@1.172 +2 -2 + NTP_4_2_5P181 + + ntpdc/ntpdc-opts.c@1.169 +2 -2 + NTP_4_2_5P181 + + ntpdc/ntpdc-opts.h@1.169 +3 -3 + NTP_4_2_5P181 + + ntpdc/ntpdc-opts.texi@1.168 +1 -1 + NTP_4_2_5P181 + + ntpdc/ntpdc.1@1.168 +2 -2 + NTP_4_2_5P181 + + ntpq/ntpq-opts.c@1.169 +2 -2 + NTP_4_2_5P181 + + ntpq/ntpq-opts.h@1.169 +3 -3 + NTP_4_2_5P181 + + ntpq/ntpq-opts.texi@1.168 +1 -1 + NTP_4_2_5P181 + + ntpq/ntpq.1@1.168 +2 -2 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd-opts.c@1.50 +2 -2 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd-opts.h@1.50 +3 -3 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd-opts.texi@1.50 +1 -1 + NTP_4_2_5P181 + + ntpsnmpd/ntpsnmpd.1@1.50 +2 -2 + NTP_4_2_5P181 + + packageinfo.sh@1.184 +1 -1 + NTP_4_2_5P181 + + sntp/sntp-opts.c@1.169 +2 -2 + NTP_4_2_5P181 + + sntp/sntp-opts.h@1.169 +3 -3 + NTP_4_2_5P181 + + sntp/sntp-opts.texi@1.168 +1 -1 + NTP_4_2_5P181 + + sntp/sntp.1@1.168 +2 -2 + NTP_4_2_5P181 + + util/ntp-keygen-opts.c@1.172 +2 -2 + NTP_4_2_5P181 + + util/ntp-keygen-opts.h@1.172 +3 -3 + NTP_4_2_5P181 + + util/ntp-keygen-opts.texi@1.171 +1 -1 + NTP_4_2_5P181 + + util/ntp-keygen.1@1.171 +2 -2 + NTP_4_2_5P181 + +ChangeSet@1.1877.1.4, 2009-06-06 04:29:46+00:00, davehart@shiny.ad.hartbrothers.com + timepps.h: + Use FreeLibrary in load_pps_provider failure paths, correct + (provtime_pps_destroy) cast, and fix for always returning -1 + meaning failure but errno 0 on successful time_pps_destroy() + + ports/winnt/include/timepps.h@1.2 +10 -2 + Use FreeLibrary in load_pps_provider failure paths, correct + (provtime_pps_destroy) cast, and fix for always returning -1 + meaning failure but errno 0 on successful time_pps_destroy() + +ChangeSet@1.1877.2.1, 2009-06-05 23:35:04+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1084] PPSAPI for ntpd on Windows with DLL backends + [Bug 1204] Unix-style refclock device paths on Windows + [Bug 1205] partial fix, disable RDTSC use by default on Windows + Enable ONCORE, ARCRON refclocks on Windows (untested) + + + + ChangeLog@1.340.2.1 +4 -0 + [Bug 1084] PPSAPI for ntpd on Windows with DLL backends + [Bug 1204] Unix-style refclock device paths on Windows + [Bug 1205] partial fix, disable RDTSC use by default on Windows + Enable ONCORE, ARCRON refclocks on Windows (untested) + + + include/ntp_types.h@1.13 +14 -0 + [Bug 1204] Unix-style refclock device paths on Windows + + ntpd/refclock_arc.c@1.20 +4 -2 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ntpd/refclock_atom.c@1.60 +1 -1 + [Bug 1204] Unix-style refclock device paths on Windows + + ntpd/refclock_hopfser.c@1.13 +1 -4 + [Bug 1204] Unix-style refclock device paths on Windows + + ntpd/refclock_nmea.c@1.38 +12 -12 + [Bug 1204] Unix-style refclock device paths on Windows + quiet type conversion warning + + ntpd/refclock_oncore.c@1.68 +12 -4 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ntpd/refclock_palisade.c@1.25 +2 -4 + [Bug 1204] Unix-style refclock device paths on Windows + + ports/winnt/include/clockstuff.h@1.10 +1 -1 + #include "ntp_fp.h" + + ports/winnt/include/config.h@1.67 +21 -5 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ports/winnt/include/timepps.h@1.1 +803 -0 + [Bug 1084] PPSAPI for ntpd on Windows with DLL backends + + ports/winnt/include/timepps.h@1.0 +0 -0 + + ports/winnt/ntpd/nt_clockstuff.c@1.31 +46 -1 + [Bug 1205] partial fix, disable RDTSC use by default on Windows + + ports/winnt/ntpd/ntpd.vcproj@1.7 +0 -3 + Enable ONCORE, ARCRON refclocks on Windows (untested) + + ports/winnt/ntpd/win32_io.c@1.18 +75 -34 + [Bug 1204] Unix-style refclock device paths on Windows + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.c@1.1 +382 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.c@1.0 +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.def@1.1 +9 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.def@1.0 +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.h@1.1 +22 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.h@1.0 +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.sln@1.1 +19 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.sln@1.0 +0 -0 + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.vcproj@1.1 +227 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/skeleton-ppsapi-provider.vcproj@1.0 +0 -0 + + ports/winnt/ppsapi/skelprov/sys/time.h@1.1 +18 -0 + Sample source for Windows PPSAPI provider DLL implementing interface + defined in ports/winnt/include/timepps.h + + ports/winnt/ppsapi/skelprov/sys/time.h@1.0 +0 -0 + +ChangeSet@1.1877.1.2, 2009-06-03 01:35:02+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1211] keysdir free()d twice #ifdef DEBUG + + ChangeLog@1.340.1.2 +1 -0 + [Bug 1211] keysdir free()d twice #ifdef DEBUG + + libntp/decodenetnum.c@1.8 +3 -3 + this 1208 fix works + + ntpd/ntp_config.c@1.194 +10 -32 + [Bug 1211] keysdir free()d twice #ifdef DEBUG + + ports/winnt/ntpd/ntservice.c@1.17 +23 -10 + turn on more heap checking on Windows DEBUG build + +ChangeSet@1.1877.1.1, 2009-06-02 22:04:37+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1208] decodenetnum() buffer overrun on [ with no ] + + ChangeLog@1.340.1.1 +1 -0 + [Bug 1208] decodenetnum() buffer overrun on [ with no ] + + libntp/decodenetnum.c@1.7 +17 -11 + [Bug 1208] decodenetnum() buffer overrun on [ with no ] + +ChangeSet@1.1878, 2009-06-01 08:52:39-04:00, mayer@pogo.udel.edu + [Bug 1206] Required compiler changes for Windows + + ChangeLog@1.341 +1 -0 + [Bug 1206] Required compiler changes for Windows + + ports/winnt/libntp/libntp.dsp@1.34 +8 -12 + [Bug 1206] Required compiler changes for Windows + +ChangeSet@1.1877, 2009-05-29 07:54:39-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P180 + TAG: NTP_4_2_5P180 + + ChangeLog@1.340 +1 -0 + NTP_4_2_5P180 + + gsoc_sntp/sntp-opts.c@1.41 +2 -2 + NTP_4_2_5P180 + + gsoc_sntp/sntp-opts.h@1.41 +3 -3 + NTP_4_2_5P180 + + gsoc_sntp/sntp-opts.texi@1.41 +1 -1 + NTP_4_2_5P180 + + gsoc_sntp/sntp.1@1.41 +2 -2 + NTP_4_2_5P180 + + ntpd/ntpd-opts.c@1.172 +2 -2 + NTP_4_2_5P180 + + ntpd/ntpd-opts.h@1.172 +3 -3 + NTP_4_2_5P180 + + ntpd/ntpd-opts.texi@1.171 +2 -2 + NTP_4_2_5P180 + + ntpd/ntpd.1@1.171 +2 -2 + NTP_4_2_5P180 + + ntpdc/ntpdc-opts.c@1.168 +2 -2 + NTP_4_2_5P180 + + ntpdc/ntpdc-opts.h@1.168 +3 -3 + NTP_4_2_5P180 + + ntpdc/ntpdc-opts.texi@1.167 +2 -2 + NTP_4_2_5P180 + + ntpdc/ntpdc.1@1.167 +2 -2 + NTP_4_2_5P180 + + ntpq/ntpq-opts.c@1.168 +2 -2 + NTP_4_2_5P180 + + ntpq/ntpq-opts.h@1.168 +3 -3 + NTP_4_2_5P180 + + ntpq/ntpq-opts.texi@1.167 +2 -2 + NTP_4_2_5P180 + + ntpq/ntpq.1@1.167 +2 -2 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd-opts.c@1.49 +2 -2 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd-opts.h@1.49 +3 -3 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd-opts.texi@1.49 +1 -1 + NTP_4_2_5P180 + + ntpsnmpd/ntpsnmpd.1@1.49 +2 -2 + NTP_4_2_5P180 + + packageinfo.sh@1.183 +1 -1 + NTP_4_2_5P180 + + sntp/sntp-opts.c@1.168 +2 -2 + NTP_4_2_5P180 + + sntp/sntp-opts.h@1.168 +3 -3 + NTP_4_2_5P180 + + sntp/sntp-opts.texi@1.167 +1 -1 + NTP_4_2_5P180 + + sntp/sntp.1@1.167 +2 -2 + NTP_4_2_5P180 + + util/ntp-keygen-opts.c@1.171 +2 -2 + NTP_4_2_5P180 + + util/ntp-keygen-opts.h@1.171 +3 -3 + NTP_4_2_5P180 + + util/ntp-keygen-opts.texi@1.170 +2 -2 + NTP_4_2_5P180 + + util/ntp-keygen.1@1.170 +2 -2 + NTP_4_2_5P180 + +ChangeSet@1.1874.1.1, 2009-05-29 03:50:53-04:00, stenn@whimsy.udel.edu + Lose FLAG_FIXPOLL, from Dave Mills + + ChangeLog@1.337.1.1 +1 -0 + Lose FLAG_FIXPOLL, from Dave Mills + + include/ntp.h@1.155.1.1 +3 -4 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_config.c@1.193 +2 -2 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_peer.c@1.119 +20 -3 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_proto.c@1.287 +1 -2 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/ntp_refclock.c@1.87 +1 -1 + Lose FLAG_FIXPOLL, from Dave Mills + + ntpd/refclock_acts.c@1.35 +0 -1 + Lose FLAG_FIXPOLL, from Dave Mills + +ChangeSet@1.1875, 2009-05-29 04:29:18+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1200] Enable IPv6 in Windows port + + ChangeLog@1.338 +1 -0 + [Bug 1200] Enable IPv6 in Windows port + + include/isc/interfaceiter.h@1.4 +1 -3 + remove unnecessary additions to struct isc_interface, eases + future integration of libisc drops + + include/ntp.h@1.156 +7 -8 + [Bug 1200] Enable IPv6 in Windows port + remove never used ifindex from struct interface, make phase u_short + instead of u_char, move next to u_short family for better packing + + include/recvbuff.h@1.17 +4 -5 + [Bug 1200] Enable IPv6 in Windows port + rename Windows-only src_addr_len to recv_srcadr_len to clarify it is + associated with recv_srcadr + remove wsabuff, send/recv routines can safely put it on stack + + libntp/recvbuff.c@1.30 +0 -5 + recvbuff.wsabuff removal + + ntpd/ntp_io.c@1.286 +4 -21 + [Bug 1200] Enable IPv6 in Windows port + remove unused ifindex from struct interface + do not initialize unused transmitbuff.c code + + ntpd/ntp_request.c@1.79 +2 -1 + remove unused ifindex from struct interface + + ntpdc/ntpdc.c@1.63 +9 -1 + [Bug 1200] Enable IPv6 in Windows port + + ntpdc/ntpdc_ops.c@1.57 +4 -5 + do not display ifindex in ifstats, was always zero and now removed + + ntpq/ntpq.c@1.85 +13 -4 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/include/config.h@1.66 +39 -14 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/include/transmitbuff.h@1.7 +3 -7 + remove wsabuff, stack allocation is no problem for it + + ports/winnt/include/win32_io.h@1.10 +3 -1 + prep for future refclock_arc.c support on windows + + ports/winnt/libisc/interfaceiter.c@1.8 +203 -92 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/libisc/net.c@1.8 +8 -18 + [Bug 1200] Enable IPv6 in Windows port + + ports/winnt/libntp/interfaceiter.c@1.3 +188 -68 + not used, upstream drop from BIND 9.6.1b1 is baseline for + ports/winnt/libisc/interfaceiter.c + + ports/winnt/libntp/libntp.vcproj@1.6 +4 -0 + add ntp_net.h reference + + ports/winnt/libntp/transmitbuff.c@1.8 +10 -6 + remove wsabuf initialization, note the code is dead in top comment + + ports/winnt/ntpd/nt_clockstuff.c@1.30 +16 -1 + complain on DEBUG builds if hardcoded SIZEOF_ macros are wrong + + ports/winnt/ntpd/ntp_iocompletionport.c@1.42 +86 -79 + [Bug 1200] Enable IPv6 on Windows + remove wsabuf from transmitbuff_t, recvbuff + + ports/winnt/ntpd/ntpd.vcproj@1.6 +8 -1 + add ntp_signd.c, ntp_net.h references + + ports/winnt/ntpdate/ntpdate.vcproj@1.3 +52 -0 + add a bunch of missing header references (not all by far though) + +ChangeSet@1.1874, 2009-05-23 07:55:15-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P179 + TAG: NTP_4_2_5P179 + + ChangeLog@1.337 +1 -0 + NTP_4_2_5P179 + + gsoc_sntp/sntp-opts.c@1.40 +2 -2 + NTP_4_2_5P179 + + gsoc_sntp/sntp-opts.h@1.40 +3 -3 + NTP_4_2_5P179 + + gsoc_sntp/sntp-opts.texi@1.40 +1 -1 + NTP_4_2_5P179 + + gsoc_sntp/sntp.1@1.40 +2 -2 + NTP_4_2_5P179 + + ntpd/ntpd-opts.c@1.171 +2 -2 + NTP_4_2_5P179 + + ntpd/ntpd-opts.h@1.171 +3 -3 + NTP_4_2_5P179 + + ntpd/ntpd-opts.texi@1.170 +2 -2 + NTP_4_2_5P179 + + ntpd/ntpd.1@1.170 +2 -2 + NTP_4_2_5P179 + + ntpdc/ntpdc-opts.c@1.167 +2 -2 + NTP_4_2_5P179 + + ntpdc/ntpdc-opts.h@1.167 +3 -3 + NTP_4_2_5P179 + + ntpdc/ntpdc-opts.texi@1.166 +2 -2 + NTP_4_2_5P179 + + ntpdc/ntpdc.1@1.166 +2 -2 + NTP_4_2_5P179 + + ntpq/ntpq-opts.c@1.167 +2 -2 + NTP_4_2_5P179 + + ntpq/ntpq-opts.h@1.167 +3 -3 + NTP_4_2_5P179 + + ntpq/ntpq-opts.texi@1.166 +2 -2 + NTP_4_2_5P179 + + ntpq/ntpq.1@1.166 +2 -2 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd-opts.c@1.48 +2 -2 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd-opts.h@1.48 +3 -3 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd-opts.texi@1.48 +1 -1 + NTP_4_2_5P179 + + ntpsnmpd/ntpsnmpd.1@1.48 +2 -2 + NTP_4_2_5P179 + + packageinfo.sh@1.182 +1 -1 + NTP_4_2_5P179 + + sntp/sntp-opts.c@1.167 +2 -2 + NTP_4_2_5P179 + + sntp/sntp-opts.h@1.167 +3 -3 + NTP_4_2_5P179 + + sntp/sntp-opts.texi@1.166 +1 -1 + NTP_4_2_5P179 + + sntp/sntp.1@1.166 +2 -2 + NTP_4_2_5P179 + + util/ntp-keygen-opts.c@1.170 +2 -2 + NTP_4_2_5P179 + + util/ntp-keygen-opts.h@1.170 +3 -3 + NTP_4_2_5P179 + + util/ntp-keygen-opts.texi@1.169 +2 -2 + NTP_4_2_5P179 + + util/ntp-keygen.1@1.169 +2 -2 + NTP_4_2_5P179 + +ChangeSet@1.1871.1.1, 2009-05-22 22:13:36-04:00, stenn@whimsy.udel.edu + Dave's latest change fixes a reported bug - update the ChangeLog + + ChangeLog@1.334.1.1 +3 -2 + Dave's latest change fixes a reported bug - update the ChangeLog + +ChangeSet@1.1872, 2009-05-23 02:02:18+00:00, davehart@shiny.ad.hartbrothers.com + Bug [1041] manycastclient fails with 4.2.5p120. + (fixed by Dave Mills' prior delta to ntp_peer.c xmt -> aorg) + Bug [1196] VC6 winsock2.h does not define SO_EXLUSIVEADDRUSE. + + + ChangeLog@1.335 +3 -1 + Bug [1041] manycastclient fails with 4.2.5p120. + Bug [1196] VC6 winsock2.h does not define SO_EXLUSIVEADDRUSE. + + + ntpd/ntp_io.c@1.285 +17 -6 + disambiguate two identical DPRINTFs in findbcastinter() + + ports/winnt/include/config.h@1.65 +7 -0 + Bug [1196] VC6 winsock2.h does not define SO_EXLUSIVEADDRUSE. + + +ChangeSet@1.1869.1.1, 2009-05-22 21:16:18-04:00, stenn@whimsy.udel.edu + xmt/aorg and leap_expire fixes from Dave Mills + + ChangeLog@1.332.1.2 +1 -0 + xmt -> aorg timestamp cleanup from Dave Mills, reported by Dave Hart + + ChangeLog@1.332.1.1 +1 -0 + Leap/expire cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.136 +1 -0 + Leap/expire cleanup from Dave Mills + + ntpd/ntp_peer.c@1.118 +1 -1 + xmt -> aorg timestamp cleanup from Dave Mills, reported by Dave Hart + + ntpd/ntp_proto.c@1.286 +7 -6 + xmt -> aorg timestamp cleanup from Dave Mills, reported by Dave Hart + +ChangeSet@1.1870, 2009-05-21 18:34:36+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1193] Compile error: conflicting types for emalloc + + ChangeLog@1.333 +1 -0 + [Bug 1193] Compile error: conflicting types for emalloc + + libntp/emalloc.c@1.8 +3 -3 + [Bug 1193] correct emalloc arg type from u_int -> size_t to match header + correct printf format specifier mismatch of %d (int) and strlen (size_t) + +ChangeSet@1.1869, 2009-05-21 07:54:56-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P178 + TAG: NTP_4_2_5P178 + + ChangeLog@1.332 +1 -0 + NTP_4_2_5P178 + + gsoc_sntp/sntp-opts.c@1.39 +2 -2 + NTP_4_2_5P178 + + gsoc_sntp/sntp-opts.h@1.39 +3 -3 + NTP_4_2_5P178 + + gsoc_sntp/sntp-opts.texi@1.39 +1 -1 + NTP_4_2_5P178 + + gsoc_sntp/sntp.1@1.39 +2 -2 + NTP_4_2_5P178 + + ntpd/ntpd-opts.c@1.170 +2 -2 + NTP_4_2_5P178 + + ntpd/ntpd-opts.h@1.170 +3 -3 + NTP_4_2_5P178 + + ntpd/ntpd-opts.texi@1.169 +1 -1 + NTP_4_2_5P178 + + ntpd/ntpd.1@1.169 +2 -2 + NTP_4_2_5P178 + + ntpdc/ntpdc-opts.c@1.166 +2 -2 + NTP_4_2_5P178 + + ntpdc/ntpdc-opts.h@1.166 +3 -3 + NTP_4_2_5P178 + + ntpdc/ntpdc-opts.texi@1.165 +1 -1 + NTP_4_2_5P178 + + ntpdc/ntpdc.1@1.165 +2 -2 + NTP_4_2_5P178 + + ntpq/ntpq-opts.c@1.166 +2 -2 + NTP_4_2_5P178 + + ntpq/ntpq-opts.h@1.166 +3 -3 + NTP_4_2_5P178 + + ntpq/ntpq-opts.texi@1.165 +1 -1 + NTP_4_2_5P178 + + ntpq/ntpq.1@1.165 +2 -2 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd-opts.c@1.47 +2 -2 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd-opts.h@1.47 +3 -3 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd-opts.texi@1.47 +1 -1 + NTP_4_2_5P178 + + ntpsnmpd/ntpsnmpd.1@1.47 +2 -2 + NTP_4_2_5P178 + + packageinfo.sh@1.181 +1 -1 + NTP_4_2_5P178 + + sntp/sntp-opts.c@1.166 +2 -2 + NTP_4_2_5P178 + + sntp/sntp-opts.h@1.166 +3 -3 + NTP_4_2_5P178 + + sntp/sntp-opts.texi@1.165 +1 -1 + NTP_4_2_5P178 + + sntp/sntp.1@1.165 +2 -2 + NTP_4_2_5P178 + + util/ntp-keygen-opts.c@1.169 +2 -2 + NTP_4_2_5P178 + + util/ntp-keygen-opts.h@1.169 +3 -3 + NTP_4_2_5P178 + + util/ntp-keygen-opts.texi@1.168 +1 -1 + NTP_4_2_5P178 + + util/ntp-keygen.1@1.168 +2 -2 + NTP_4_2_5P178 + +ChangeSet@1.1868, 2009-05-21 03:03:04-04:00, stenn@whimsy.udel.edu + Note fixes for bugs 320 and 1192, and erealloc() and estrdup(), along with better config parser error messages. + + ChangeLog@1.331 +4 -0 + Note fixes for bugs 320 and 1192, and erealloc() and estrdup(), along with better config parser error messages. + +ChangeSet@1.1867, 2009-05-21 05:30:18+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 320] restrict default should apply to both IPv4 and IPv6 + [Bug 1192] restrict -4 default / restrict -6 default lost with new + ntp.conf parser. + Dynamically allocate Windows serial handles array to save 1KB static + show column of syntax errors as well as line + add erealloc(), estrdup() + save column number at start of each token for more precise syntax + error messages + + include/ntp_calendar.h@1.4 +13 -13 + whitespace cleanup, parenthesize macro arg + + include/ntp_config.h@1.52 +1 -1 + whitespace + + include/ntp_filegen.h@1.6 +1 -1 + changed prototype for filegen_unregister() + + include/ntp_stdlib.h@1.29 +10 -5 + add erealloc(), estrdup() + + include/ntp_types.h@1.12 +5 -0 + add COUNTOF(array) macro + + include/ntpd.h@1.127 +1 -1 + add comment that fstostr time_t arg isn't a typical time_t + + libntp/emalloc.c@1.7 +75 -14 + add erealloc(), estrdup() + + libntp/ntp_lineedit.c@1.6 +2 -1 + strdup() -> estrdup() + + ntpd/ntp_config.c@1.192 +310 -244 + [Bug 320] restrict default should apply to both IPv4 and IPv6 + [Bug 1192] restrict -4 default / restrict -6 default lost with new + ntp.conf parser. + Remove unnecessary casts, use sizeof(*ptr) instead of sizeof(ptr_type) + change switch/case indents to NTP style + wrap long lines, remove unneeded casts, silence uninit warning + strdup() -> estrdup() + + ntpd/ntp_filegen.c@1.15 +226 -194 + free more malloc()'d memory at shutdown #ifdef DEBUG + whitespace cleanup, wrap long lines + remove unnecessary casts + sprintf()->snprintf() + constants on left side of == to catch accidental change to =, and put + more informative item first + '/' -> DIR_SEP + restore DPRINTF()s that gave Alpha compiler fits by using %p printf format + + ntpd/ntp_parser.c@1.38 +1000 -955 + Bison output from ntp_parser.y + + + ntpd/ntp_parser.h@1.22 +225 -225 + Bison output from ntp_parser.y + + + ntpd/ntp_parser.y@1.33 +50 -22 + [Bug 1192] restrict -4 default / restrict -6 default lost with new + ntp.conf parser. + correct else block indent in include processing code + remove unwanted \n from end of msyslog() in yyerror() + strdup() -> estrdup() + display line and column numbers in syntax error messages + save column number at start of each token for more precise syntax + error messages + + ntpd/ntp_scanner.c@1.21 +110 -118 + strdup() -> estrdup() + first line number is one not zero + save column number at start of each token for more precise syntax + error messages + clarify reason for -4/-6 hack in yylex() comment + + ntpd/ntp_scanner.h@1.6 +16 -13 + save column number at start of each token for more precise syntax + error messages + whitespace cleanup + + ntpd/ntp_util.c@1.71 +42 -52 + free() then emalloc() becomes erealloc() + thin #ifdef forest + + ports/winnt/include/win32_io.h@1.9 +95 -85 + whitespace and indent cleanup + stay out of system namespace (leading _) + + ports/winnt/ntpd/nt_clockstuff.c@1.29 +0 -3 + COUNTOF() macro moved to ntp_types.h + + ports/winnt/ntpd/win32_io.c@1.17 +420 -202 + dynamically allocate serial handles array (saves 1 KB static) + change switch/case intents to NTP style + add TIOCMGET tty ioctl emulation, improve TIOCMSET emulation + correct tcsetattr() & tcgetattr() return values + remove superfluous NT_COM: prefix from error texts + +ChangeSet@1.1866, 2009-05-18 08:14:01-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P177 + TAG: NTP_4_2_5P177 + + ChangeLog@1.330 +1 -0 + NTP_4_2_5P177 + + gsoc_sntp/sntp-opts.c@1.38 +2 -2 + NTP_4_2_5P177 + + gsoc_sntp/sntp-opts.h@1.38 +3 -3 + NTP_4_2_5P177 + + gsoc_sntp/sntp-opts.texi@1.38 +1 -1 + NTP_4_2_5P177 + + gsoc_sntp/sntp.1@1.38 +2 -2 + NTP_4_2_5P177 + + ntpd/ntpd-opts.c@1.169 +4 -4 + NTP_4_2_5P177 + + ntpd/ntpd-opts.h@1.169 +4 -4 + NTP_4_2_5P177 + + ntpd/ntpd-opts.texi@1.168 +1 -1 + NTP_4_2_5P177 + + ntpd/ntpd.1@1.168 +2 -2 + NTP_4_2_5P177 + + ntpdc/ntpdc-opts.c@1.165 +4 -4 + NTP_4_2_5P177 + + ntpdc/ntpdc-opts.h@1.165 +4 -4 + NTP_4_2_5P177 + + ntpdc/ntpdc-opts.texi@1.164 +1 -1 + NTP_4_2_5P177 + + ntpdc/ntpdc.1@1.164 +2 -2 + NTP_4_2_5P177 + + ntpq/ntpq-opts.c@1.165 +4 -4 + NTP_4_2_5P177 + + ntpq/ntpq-opts.h@1.165 +4 -4 + NTP_4_2_5P177 + + ntpq/ntpq-opts.texi@1.164 +1 -1 + NTP_4_2_5P177 + + ntpq/ntpq.1@1.164 +2 -2 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd-opts.c@1.46 +4 -4 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd-opts.h@1.46 +4 -4 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd-opts.texi@1.46 +1 -1 + NTP_4_2_5P177 + + ntpsnmpd/ntpsnmpd.1@1.46 +2 -2 + NTP_4_2_5P177 + + packageinfo.sh@1.180 +1 -1 + NTP_4_2_5P177 + + sntp/sntp-opts.c@1.165 +2 -2 + NTP_4_2_5P177 + + sntp/sntp-opts.h@1.165 +3 -3 + NTP_4_2_5P177 + + sntp/sntp-opts.texi@1.164 +1 -1 + NTP_4_2_5P177 + + sntp/sntp.1@1.164 +2 -2 + NTP_4_2_5P177 + + util/ntp-keygen-opts.c@1.168 +4 -4 + NTP_4_2_5P177 + + util/ntp-keygen-opts.h@1.168 +4 -4 + NTP_4_2_5P177 + + util/ntp-keygen-opts.texi@1.167 +1 -1 + NTP_4_2_5P177 + + util/ntp-keygen.1@1.167 +2 -2 + NTP_4_2_5P177 + +ChangeSet@1.1436.15.70, 2009-05-18 05:04:41-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P7 + TAG: NTP_4_2_4P7 + + ChangeLog@1.1.1.90 +1 -0 + NTP_4_2_4P7 + + ntpd/ntpd-opts.c@1.50.25.1 +4 -4 + NTP_4_2_4P7 + + ntpd/ntpd-opts.h@1.50.25.1 +4 -4 + NTP_4_2_4P7 + + ntpd/ntpd-opts.texi@1.49.25.1 +1 -1 + NTP_4_2_4P7 + + ntpd/ntpd.1@1.48.25.1 +2 -2 + NTP_4_2_4P7 + + ntpd/ntpdsim-opts.c@1.50.25.1 +4 -4 + NTP_4_2_4P7 + + ntpd/ntpdsim-opts.h@1.50.25.1 +4 -4 + NTP_4_2_4P7 + + ntpd/ntpdsim-opts.texi@1.48.25.1 +1 -1 + NTP_4_2_4P7 + + ntpd/ntpdsim.1@1.48.25.1 +2 -2 + NTP_4_2_4P7 + + ntpdc/ntpdc-opts.c@1.50.25.1 +4 -4 + NTP_4_2_4P7 + + ntpdc/ntpdc-opts.h@1.50.25.1 +4 -4 + NTP_4_2_4P7 + + ntpdc/ntpdc-opts.texi@1.48.25.1 +1 -1 + NTP_4_2_4P7 + + ntpdc/ntpdc.1@1.48.25.1 +2 -2 + NTP_4_2_4P7 + + ntpq/ntpq-opts.c@1.52.25.1 +4 -4 + NTP_4_2_4P7 + + ntpq/ntpq-opts.h@1.52.25.1 +4 -4 + NTP_4_2_4P7 + + ntpq/ntpq-opts.texi@1.49.25.1 +1 -1 + NTP_4_2_4P7 + + ntpq/ntpq.1@1.48.25.1 +2 -2 + NTP_4_2_4P7 + + packageinfo.sh@1.65.33.2 +2 -2 + NTP_4_2_4P7 + + sntp/sntp-opts.c@1.49.25.1 +2 -2 + NTP_4_2_4P7 + + sntp/sntp-opts.h@1.49.25.1 +3 -3 + NTP_4_2_4P7 + + sntp/sntp-opts.texi@1.46.25.1 +1 -1 + NTP_4_2_4P7 + + sntp/sntp.1@1.49.25.1 +2 -2 + NTP_4_2_4P7 + + util/ntp-keygen-opts.c@1.49.25.1 +4 -4 + NTP_4_2_4P7 + + util/ntp-keygen-opts.h@1.49.25.1 +4 -4 + NTP_4_2_4P7 + + util/ntp-keygen-opts.texi@1.47.25.1 +1 -1 + NTP_4_2_4P7 + + util/ntp-keygen.1@1.47.25.1 +2 -2 + NTP_4_2_4P7 + +ChangeSet@1.1436.15.69, 2009-05-18 03:14:59-04:00, stenn@whimsy.udel.edu + 4.2.4p7 + + NEWS@1.86.1.15 +38 -0 + 4.2.4p7 + + packageinfo.sh@1.65.33.1 +1 -1 + 4.2.4p7 + +ChangeSet@1.1436.15.68, 2009-05-18 02:56:36-04:00, stenn@whimsy.udel.edu + [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + + ChangeLog@1.1.1.89 +1 -0 + [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + + ntpd/ntp_crypto.c@1.107.1.3 +22 -17 + [Sec 1151] Remote exploit if autokey is enabled - CVE-2009-1252 + +ChangeSet@1.1436.15.67, 2009-05-18 02:24:31-04:00, stenn@whimsy.udel.edu + [Bug 1187] Update the copyright date. + + ChangeLog@1.1.1.88 +1 -0 + [Bug 1187] Update the copyright date. + + include/copyright.def@1.5.1.3 +1 -1 + [Bug 1187] Update the copyright date. + +ChangeSet@1.1436.15.66, 2009-05-17 08:59:06+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix + for [Sec 1149]. + + ChangeLog@1.1.1.87 +5 -0 + [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix + for [Sec 1149]. + + ntpd/ntp_io.c@1.244.2.17 +45 -34 + [Bug 1191] ntpd fails on Win2000 - "Address already in use" after fix + for [Sec 1149]. + +ChangeSet@1.1860.1.2, 2009-05-15 19:54:46+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned + + ChangeLog@1.325.1.2 +1 -0 + [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned + + ntpd/refclock_nmea.c@1.37 +6 -2 + [Bug 1174] nmea_shutdown assumes that nmea has a unit assigned + +ChangeSet@1.1860.1.1, 2009-05-15 19:37:17+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode + Update NMEA documentation for a number of changes over the last year + + ChangeLog@1.325.1.1 +2 -0 + [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode + Update NMEA documentation for a number of changes over the last year + + html/drivers/driver20.html@1.18 +18 -21 + Update NMEA documentation for a number of changes over the last year + + ntpd/refclock_nmea.c@1.36 +89 -13 + [Bug 1190] NMEA refclock fudge flag4 1 obscures position in timecode + +ChangeSet@1.1436.15.65, 2009-05-14 04:42:10+00:00, davehart@shiny.ad.hartbrothers.com + fix error from BitKeeper/triggers/pre-resolve.licfix triggered (ahem) + by recent BitKeeper/etc/config delta updating repologs email address + + BitKeeper/triggers/pre-resolve.licfix@1.5 +4 -1 + bk sccscat has been removed, replaced by bk annotate -R + -q grep -> grep -q (untested until recent BitKeeper/etc/config commit + changing repologs@ntp.isc.org to repologs@ntp.org + +ChangeSet@1.1861, 2009-05-14 01:33:16+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + remove duplicate [Bug 1154] entry from failed first fix + + ChangeLog@1.326 +0 -2 + remove duplicate [Bug 1154] entry from failed first fix + +ChangeSet@1.1860, 2009-05-13 07:54:55-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P176 + TAG: NTP_4_2_5P176 + + ChangeLog@1.325 +1 -0 + NTP_4_2_5P176 + + gsoc_sntp/sntp-opts.c@1.37 +2 -2 + NTP_4_2_5P176 + + gsoc_sntp/sntp-opts.h@1.37 +3 -3 + NTP_4_2_5P176 + + gsoc_sntp/sntp-opts.texi@1.37 +1 -1 + NTP_4_2_5P176 + + gsoc_sntp/sntp.1@1.37 +2 -2 + NTP_4_2_5P176 + + ntpd/ntpd-opts.c@1.168 +2 -2 + NTP_4_2_5P176 + + ntpd/ntpd-opts.h@1.168 +3 -3 + NTP_4_2_5P176 + + ntpd/ntpd-opts.texi@1.167 +1 -1 + NTP_4_2_5P176 + + ntpd/ntpd.1@1.167 +2 -2 + NTP_4_2_5P176 + + ntpdc/ntpdc-opts.c@1.164 +2 -2 + NTP_4_2_5P176 + + ntpdc/ntpdc-opts.h@1.164 +3 -3 + NTP_4_2_5P176 + + ntpdc/ntpdc-opts.texi@1.163 +1 -1 + NTP_4_2_5P176 + + ntpdc/ntpdc.1@1.163 +2 -2 + NTP_4_2_5P176 + + ntpq/ntpq-opts.c@1.164 +2 -2 + NTP_4_2_5P176 + + ntpq/ntpq-opts.h@1.164 +3 -3 + NTP_4_2_5P176 + + ntpq/ntpq-opts.texi@1.163 +1 -1 + NTP_4_2_5P176 + + ntpq/ntpq.1@1.163 +2 -2 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd-opts.c@1.45 +2 -2 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd-opts.h@1.45 +3 -3 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd-opts.texi@1.45 +1 -1 + NTP_4_2_5P176 + + ntpsnmpd/ntpsnmpd.1@1.45 +2 -2 + NTP_4_2_5P176 + + packageinfo.sh@1.179 +1 -1 + NTP_4_2_5P176 + + sntp/sntp-opts.c@1.164 +2 -2 + NTP_4_2_5P176 + + sntp/sntp-opts.h@1.164 +3 -3 + NTP_4_2_5P176 + + sntp/sntp-opts.texi@1.163 +1 -1 + NTP_4_2_5P176 + + sntp/sntp.1@1.163 +2 -2 + NTP_4_2_5P176 + + util/ntp-keygen-opts.c@1.167 +2 -2 + NTP_4_2_5P176 + + util/ntp-keygen-opts.h@1.167 +3 -3 + NTP_4_2_5P176 + + util/ntp-keygen-opts.texi@1.166 +1 -1 + NTP_4_2_5P176 + + util/ntp-keygen.1@1.166 +2 -2 + NTP_4_2_5P176 + +ChangeSet@1.1845.6.2, 2009-05-12 08:57:55-04:00, utterback@pogo.udel.edu + ntpd.c: + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + + ntpd/ntpd.c@1.100.1.1 +29 -7 + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + +ChangeSet@1.1845.6.1, 2009-05-12 08:51:48-04:00, utterback@pogo.udel.edu + ChangeLog: + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + + ChangeLog@1.310.5.1 +2 -0 + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + +ChangeSet@1.1858, 2009-05-12 08:07:45-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P175 + TAG: NTP_4_2_5P175 + + ChangeLog@1.323 +1 -0 + NTP_4_2_5P175 + + gsoc_sntp/sntp-opts.c@1.36 +2 -2 + NTP_4_2_5P175 + + gsoc_sntp/sntp-opts.h@1.36 +3 -3 + NTP_4_2_5P175 + + gsoc_sntp/sntp-opts.texi@1.36 +1 -1 + NTP_4_2_5P175 + + gsoc_sntp/sntp.1@1.36 +2 -2 + NTP_4_2_5P175 + + ntpd/ntpd-opts.c@1.167 +2 -2 + NTP_4_2_5P175 + + ntpd/ntpd-opts.h@1.167 +3 -3 + NTP_4_2_5P175 + + ntpd/ntpd-opts.texi@1.166 +1 -1 + NTP_4_2_5P175 + + ntpd/ntpd.1@1.166 +2 -2 + NTP_4_2_5P175 + + ntpdc/ntpdc-opts.c@1.163 +2 -2 + NTP_4_2_5P175 + + ntpdc/ntpdc-opts.h@1.163 +3 -3 + NTP_4_2_5P175 + + ntpdc/ntpdc-opts.texi@1.162 +1 -1 + NTP_4_2_5P175 + + ntpdc/ntpdc.1@1.162 +2 -2 + NTP_4_2_5P175 + + ntpq/ntpq-opts.c@1.163 +2 -2 + NTP_4_2_5P175 + + ntpq/ntpq-opts.h@1.163 +3 -3 + NTP_4_2_5P175 + + ntpq/ntpq-opts.texi@1.162 +1 -1 + NTP_4_2_5P175 + + ntpq/ntpq.1@1.162 +2 -2 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd-opts.c@1.44 +2 -2 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd-opts.h@1.44 +3 -3 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd-opts.texi@1.44 +1 -1 + NTP_4_2_5P175 + + ntpsnmpd/ntpsnmpd.1@1.44 +2 -2 + NTP_4_2_5P175 + + packageinfo.sh@1.178 +1 -1 + NTP_4_2_5P175 + + sntp/sntp-opts.c@1.163 +2 -2 + NTP_4_2_5P175 + + sntp/sntp-opts.h@1.163 +3 -3 + NTP_4_2_5P175 + + sntp/sntp-opts.texi@1.162 +1 -1 + NTP_4_2_5P175 + + sntp/sntp.1@1.162 +2 -2 + NTP_4_2_5P175 + + util/ntp-keygen-opts.c@1.166 +2 -2 + NTP_4_2_5P175 + + util/ntp-keygen-opts.h@1.166 +3 -3 + NTP_4_2_5P175 + + util/ntp-keygen-opts.texi@1.165 +1 -1 + NTP_4_2_5P175 + + util/ntp-keygen.1@1.165 +2 -2 + NTP_4_2_5P175 + +ChangeSet@1.1857, 2009-05-12 05:37:53-04:00, stenn@whimsy.udel.edu + Merge cleanup + + ChangeLog@1.322 +1 -0 + Merge cleanup + +ChangeSet@1.1436.15.64, 2009-05-12 02:41:56-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P7_RC7 + TAG: NTP_4_2_4P7_RC7 + + ChangeLog@1.1.1.86 +1 -0 + NTP_4_2_4P7_RC7 + + ntpd/ntpd-opts.c@1.50.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpd-opts.h@1.50.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpd-opts.texi@1.49.24.1 +1 -1 + NTP_4_2_4P7_RC7 + + ntpd/ntpd.1@1.48.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim-opts.c@1.50.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim-opts.h@1.50.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim-opts.texi@1.48.24.1 +1 -1 + NTP_4_2_4P7_RC7 + + ntpd/ntpdsim.1@1.48.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc-opts.c@1.50.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc-opts.h@1.50.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc-opts.texi@1.48.24.1 +1 -1 + NTP_4_2_4P7_RC7 + + ntpdc/ntpdc.1@1.48.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpq/ntpq-opts.c@1.52.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpq/ntpq-opts.h@1.52.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + ntpq/ntpq-opts.texi@1.49.24.1 +1 -1 + NTP_4_2_4P7_RC7 + + ntpq/ntpq.1@1.48.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + packageinfo.sh@1.65.32.1 +1 -1 + NTP_4_2_4P7_RC7 + + sntp/sntp-opts.c@1.49.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + sntp/sntp-opts.h@1.49.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + sntp/sntp-opts.texi@1.46.24.1 +1 -1 + NTP_4_2_4P7_RC7 + + sntp/sntp.1@1.49.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + util/ntp-keygen-opts.c@1.49.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + util/ntp-keygen-opts.h@1.49.24.1 +3 -3 + NTP_4_2_4P7_RC7 + + util/ntp-keygen-opts.texi@1.47.24.1 +1 -1 + NTP_4_2_4P7_RC7 + + util/ntp-keygen.1@1.47.24.1 +3 -3 + NTP_4_2_4P7_RC7 + +ChangeSet@1.1436.15.63, 2009-05-12 01:07:37-04:00, stenn@whimsy.udel.edu + ntp.isc.org -> ntp.org cleanup + + BitKeeper/etc/config@1.10 +1 -1 + ntp.isc.org -> ntp.org cleanup + + ChangeLog@1.1.1.85 +1 -0 + ntp.isc.org -> ntp.org cleanup + + README@1.22.1.1 +1 -1 + ntp.isc.org -> ntp.org cleanup + + README.bk@1.18.1.1 +1 -1 + ntp.isc.org -> ntp.org cleanup + + README.patches@1.3.1.1 +1 -1 + ntp.isc.org -> ntp.org cleanup + + WHERE-TO-START@1.6.1.1 +1 -1 + ntp.isc.org -> ntp.org cleanup + + configure.ac@1.400.1.18 +1 -1 + ntp.isc.org -> ntp.org cleanup + + include/copyright.def@1.5.1.2 +1 -1 + ntp.isc.org -> ntp.org cleanup + + sntp/sntp-opts.def@1.10.1.1 +1 -1 + ntp.isc.org -> ntp.org cleanup + +ChangeSet@1.1845.5.1, 2009-05-11 21:43:27-04:00, stenn@whimsy.udel.edu + [Bug 1182] Documentation typos and missing bits + + ChangeLog@1.310.4.1 +1 -0 + [Bug 1182] Documentation typos and missing bits + + html/accopt.html@1.28 +120 -67 + [Bug 1182] Documentation typos and missing bits + + html/decode.html@1.9 +37 -25 + [Bug 1182] Documentation typos and missing bits + + html/monopt.html@1.30 +511 -457 + [Bug 1182] Documentation typos and missing bits + +ChangeSet@1.1845.4.2, 2009-05-12 00:58:59+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1183] COM port support should extend past COM3 + + ChangeLog@1.310.3.2 +1 -0 + [Bug 1183] COM port support should extend past COM3 + + libisc/sockaddr.c@1.6 +1 -1 + silence truncation warning + + ntpd/ntp_control.c@1.110 +1 -1 + silence truncation warning + + ntpd/ntp_peer.c@1.117 +7 -10 + silence truncation warnings, use NULL not 0 for pointers + + ntpd/ntp_refclock.c@1.86 +57 -81 + [Bug 1183] COM port support should extend past COM3 + silence a few truncation warnings, clean up indents + + ntpd/ntp_scanner.c@1.20 +0 -1 + remove dead code "return 1" at end of yylex(), silencing warning and + allowing the compiler to catch any future change which revives it, as + then the compiler would error on the missing "return" + + ntpd/ntpd.c@1.101 +2 -2 + fix leading whitespace, correct #endif comment + + ports/winnt/include/config.h@1.62.1.1 +1 -1 + disable CLOCK_DUMBCLOCK on Windows, it needs work first + + ports/winnt/ntpd/win32_io.c@1.16 +6 -4 + [Bug 1183] COM port support should extend past COM3 + +ChangeSet@1.1845.2.5, 2009-05-11 19:01:24+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1184] ntpd is deaf when restricted to second IP on the same net + + ChangeLog@1.310.2.3 +1 -0 + [Bug 1184] ntpd is deaf when restricted to second IP on the same net + + include/ntp.h@1.155 +10 -9 + add indents, parentheses to clarify SOCKCMP macro + + ntpd/ntp_io.c@1.283 +163 -34 + [Bug 1184] ntpd is deaf when restricted to second IP on the same net + +ChangeSet@1.1845.2.4, 2009-05-09 17:54:29+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + correct config.h comment quoting + + configure.ac@1.441.2.2 +7 -7 + correct config.h comment quoting, use AS_HELP_STRING + +ChangeSet@1.1845.4.1, 2009-05-09 07:55:25-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P174 + TAG: NTP_4_2_5P174 + + ChangeLog@1.310.3.1 +1 -0 + NTP_4_2_5P174 + + gsoc_sntp/sntp-opts.c@1.35 +2 -2 + NTP_4_2_5P174 + + gsoc_sntp/sntp-opts.h@1.35 +3 -3 + NTP_4_2_5P174 + + gsoc_sntp/sntp-opts.texi@1.35 +1 -1 + NTP_4_2_5P174 + + gsoc_sntp/sntp.1@1.35 +2 -2 + NTP_4_2_5P174 + + ntpd/ntpd-opts.c@1.166 +2 -2 + NTP_4_2_5P174 + + ntpd/ntpd-opts.h@1.166 +3 -3 + NTP_4_2_5P174 + + ntpd/ntpd-opts.texi@1.165 +1 -1 + NTP_4_2_5P174 + + ntpd/ntpd.1@1.165 +2 -2 + NTP_4_2_5P174 + + ntpdc/ntpdc-opts.c@1.162 +2 -2 + NTP_4_2_5P174 + + ntpdc/ntpdc-opts.h@1.162 +3 -3 + NTP_4_2_5P174 + + ntpdc/ntpdc-opts.texi@1.161 +1 -1 + NTP_4_2_5P174 + + ntpdc/ntpdc.1@1.161 +2 -2 + NTP_4_2_5P174 + + ntpq/ntpq-opts.c@1.162 +2 -2 + NTP_4_2_5P174 + + ntpq/ntpq-opts.h@1.162 +3 -3 + NTP_4_2_5P174 + + ntpq/ntpq-opts.texi@1.161 +1 -1 + NTP_4_2_5P174 + + ntpq/ntpq.1@1.161 +2 -2 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd-opts.c@1.43 +2 -2 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd-opts.h@1.43 +3 -3 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd-opts.texi@1.43 +1 -1 + NTP_4_2_5P174 + + ntpsnmpd/ntpsnmpd.1@1.43 +2 -2 + NTP_4_2_5P174 + + packageinfo.sh@1.177 +1 -1 + NTP_4_2_5P174 + + sntp/sntp-opts.c@1.162 +2 -2 + NTP_4_2_5P174 + + sntp/sntp-opts.h@1.162 +3 -3 + NTP_4_2_5P174 + + sntp/sntp-opts.texi@1.161 +1 -1 + NTP_4_2_5P174 + + sntp/sntp.1@1.161 +2 -2 + NTP_4_2_5P174 + + util/ntp-keygen-opts.c@1.165 +2 -2 + NTP_4_2_5P174 + + util/ntp-keygen-opts.h@1.165 +3 -3 + NTP_4_2_5P174 + + util/ntp-keygen-opts.texi@1.164 +1 -1 + NTP_4_2_5P174 + + util/ntp-keygen.1@1.164 +2 -2 + NTP_4_2_5P174 + +ChangeSet@1.1845.2.3, 2009-05-09 09:00:06+00:00, davehart@shiny.ad.hartbrothers.com + add --disable-listen-read-drop configure option for machines with more + interfaces than FD_SETSIZE [Bug 1180] + + ChangeLog@1.310.2.2 +1 -0 + [Bug 1180] ntpd won't start with more than ~1000 interfaces + + configure.ac@1.441.2.1 +18 -0 + add --disable-listen-read-drop configure option for machines with more + interfaces than FD_SETSIZE [Bug 1180] + + ntpd/ntp_io.c@1.282 +27 -7 + add --disable-listen-read-drop configure option for machines with more + interfaces than FD_SETSIZE [Bug 1180] + + ports/winnt/ntpd/ntpd.vcproj@1.5 +4 -22 + relocate cmd_args.c from ntpd header files to ntp source code in VS + +ChangeSet@1.1845.3.1, 2009-05-08 22:44:33+00:00, davehart@shiny.ad.hartbrothers.com + ntp_io.c: + make -I override -L, do not listen on unused interfaces + + ntpd/ntp_io.c@1.281 +9 -16 + make -I override -L, do not listen on unused interfaces + +ChangeSet@1.1845.2.1, 2009-05-08 17:32:49-04:00, stenn@whimsy.udel.edu + Stale leapsecond file fixes from Dave Mills + + ChangeLog@1.310.2.1 +1 -0 + Stale leapsecond file fixes from Dave Mills + + html/decode.html@1.8 +844 -683 + Stale leapsecond file fixes from Dave Mills + + include/ntp.h@1.154 +4 -0 + Stale leapsecond file fixes from Dave Mills + + include/ntpd.h@1.126 +1 -0 + Stale leapsecond file fixes from Dave Mills + + libntp/statestr.c@1.16 +3 -0 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_control.c@1.109 +2 -2 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_crypto.c@1.134 +8 -1 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_timer.c@1.51.1.1 +5 -1 + Stale leapsecond file fixes from Dave Mills + + ntpd/ntp_util.c@1.70 +33 -7 + Stale leapsecond file fixes from Dave Mills + +ChangeSet@1.1436.23.1, 2009-05-08 18:11:36+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + correct help text + + configure.ac@1.400.2.1 +11 -5 + correct help text + +ChangeSet@1.1436.15.61, 2009-05-08 17:50:37+00:00, davehart@shiny.ad.hartbrothers.com + add configure --enable-ignore-dns-errors to retry on any failure + + ChangeLog@1.1.1.84 +2 -1 + add configure --enable-ignore-dns-errors to retry on any failure + + configure.ac@1.400.1.16 +26 -4 + add configure --enable-ignore-dns-errors to retry on any failure + + ntpd/ntp_intres.c@1.48.1.7 +2 -0 + add configure --enable-ignore-dns-errors to retry on any failure + +ChangeSet@1.1436.15.60, 2009-05-08 15:34:46+00:00, davehart@shiny.ad.hartbrothers.com + Do not exceed FD_SETSIZE in ntp_intres.c + --- + ntp_intres.c: + typo + --- + ntp_intres.c: + missing comma typo + --- + ntp_intres.c: + typo + + ntpd/ntp_intres.c@1.48.1.6 +64 -33 + fix typos, refine "host name not found" log message, stay under FD_SETSIZE + + ntpd/ntp_request.c@1.65.1.2 +21 -3 + after ntp_intres adds a server entry, rescan interfaces, to notice the + return of connectivity sooner. + + ntpd/ntp_timer.c@1.33.1.1 +3 -5 + indent cleanup + + ports/winnt/include/config.h@1.46.1.6 +4 -10 + remove FORCE_DNSRETRY, no longer used + indent cleanup + +ChangeSet@1.1845.1.8, 2009-05-08 08:07:08-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P173 + TAG: NTP_4_2_5P173 + + ChangeLog@1.310.1.6 +1 -0 + NTP_4_2_5P173 + + gsoc_sntp/sntp-opts.c@1.34 +2 -2 + NTP_4_2_5P173 + + gsoc_sntp/sntp-opts.h@1.34 +3 -3 + NTP_4_2_5P173 + + gsoc_sntp/sntp-opts.texi@1.34 +1 -1 + NTP_4_2_5P173 + + gsoc_sntp/sntp.1@1.34 +2 -2 + NTP_4_2_5P173 + + ntpd/ntpd-opts.c@1.165 +2 -2 + NTP_4_2_5P173 + + ntpd/ntpd-opts.h@1.165 +3 -3 + NTP_4_2_5P173 + + ntpd/ntpd-opts.texi@1.164 +2 -2 + NTP_4_2_5P173 + + ntpd/ntpd.1@1.164 +2 -2 + NTP_4_2_5P173 + + ntpdc/ntpdc-opts.c@1.161 +2 -2 + NTP_4_2_5P173 + + ntpdc/ntpdc-opts.h@1.161 +3 -3 + NTP_4_2_5P173 + + ntpdc/ntpdc-opts.texi@1.160 +2 -2 + NTP_4_2_5P173 + + ntpdc/ntpdc.1@1.160 +2 -2 + NTP_4_2_5P173 + + ntpq/ntpq-opts.c@1.161 +2 -2 + NTP_4_2_5P173 + + ntpq/ntpq-opts.h@1.161 +3 -3 + NTP_4_2_5P173 + + ntpq/ntpq-opts.texi@1.160 +2 -2 + NTP_4_2_5P173 + + ntpq/ntpq.1@1.160 +2 -2 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd-opts.c@1.42 +2 -2 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd-opts.h@1.42 +3 -3 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd-opts.texi@1.42 +1 -1 + NTP_4_2_5P173 + + ntpsnmpd/ntpsnmpd.1@1.42 +2 -2 + NTP_4_2_5P173 + + packageinfo.sh@1.176 +1 -1 + NTP_4_2_5P173 + + sntp/sntp-opts.c@1.161 +2 -2 + NTP_4_2_5P173 + + sntp/sntp-opts.h@1.161 +3 -3 + NTP_4_2_5P173 + + sntp/sntp-opts.texi@1.160 +1 -1 + NTP_4_2_5P173 + + sntp/sntp.1@1.160 +2 -2 + NTP_4_2_5P173 + + util/ntp-keygen-opts.c@1.164 +2 -2 + NTP_4_2_5P173 + + util/ntp-keygen-opts.h@1.164 +3 -3 + NTP_4_2_5P173 + + util/ntp-keygen-opts.texi@1.163 +2 -2 + NTP_4_2_5P173 + + util/ntp-keygen.1@1.163 +2 -2 + NTP_4_2_5P173 + +ChangeSet@1.1436.22.1, 2009-05-08 11:24:43+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + + ChangeLog@1.1.17.1 +4 -0 + [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + + ntpd/ntp_intres.c@1.48.1.5 +53 -55 + [Bug 1178] Use prior FORCE_DNSRETRY behavior as needed at runtime + +ChangeSet@1.1436.15.58, 2009-05-08 04:42:52-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P7_RC6 + TAG: NTP_4_2_4P7_RC6 + + ChangeLog@1.1.1.82 +1 -0 + NTP_4_2_4P7_RC6 + + ntpd/ntpd-opts.c@1.50.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpd-opts.h@1.50.23.1 +3 -3 + NTP_4_2_4P7_RC6 + + ntpd/ntpd-opts.texi@1.49.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpd.1@1.48.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim-opts.c@1.50.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim-opts.h@1.50.23.1 +3 -3 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim-opts.texi@1.48.23.1 +1 -1 + NTP_4_2_4P7_RC6 + + ntpd/ntpdsim.1@1.48.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc-opts.c@1.50.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc-opts.h@1.50.23.1 +3 -3 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc-opts.texi@1.48.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpdc/ntpdc.1@1.48.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpq/ntpq-opts.c@1.52.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpq/ntpq-opts.h@1.52.23.1 +3 -3 + NTP_4_2_4P7_RC6 + + ntpq/ntpq-opts.texi@1.49.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + ntpq/ntpq.1@1.48.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + packageinfo.sh@1.65.31.1 +1 -1 + NTP_4_2_4P7_RC6 + + sntp/sntp-opts.c@1.49.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + sntp/sntp-opts.h@1.49.23.1 +3 -3 + NTP_4_2_4P7_RC6 + + sntp/sntp-opts.texi@1.46.23.1 +1 -1 + NTP_4_2_4P7_RC6 + + sntp/sntp.1@1.49.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + util/ntp-keygen-opts.c@1.49.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + util/ntp-keygen-opts.h@1.49.23.1 +3 -3 + NTP_4_2_4P7_RC6 + + util/ntp-keygen-opts.texi@1.47.23.1 +2 -2 + NTP_4_2_4P7_RC6 + + util/ntp-keygen.1@1.47.23.1 +2 -2 + NTP_4_2_4P7_RC6 + +ChangeSet@1.1436.15.57, 2009-05-08 03:29:16-04:00, stenn@pogo.udel.edu + typo + + ChangeLog@1.1.1.81 +1 -1 + typo + +ChangeSet@1.1436.15.56, 2009-05-08 02:13:17+00:00, davehart@shiny.ad.hartbrothers.com + Add [Bug 1071] reference to ChangeLog entry + + ChangeLog@1.1.1.80 +2 -2 + [Bug 1071] Log a message and exit before trying to use FD_SET with a + descriptor larger than FD_SETSIZE, which will corrupt memory + (adds reference to 1071 to existing description) + +ChangeSet@1.1436.15.55, 2009-05-08 01:23:43+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1179] error messages for -u/--user and -i when built w/o droproot + + ChangeLog@1.1.1.79 +1 -0 + [Bug 1179] error messages for -u/--user and -i when built w/o droproot + + ntpd/cmd_args.c@1.45.3.4 +39 -19 + descriptive error messages for -u/--user and -i without droproot + +ChangeSet@1.1436.15.54, 2009-05-07 22:15:41+00:00, davehart@shiny.ad.hartbrothers.com + ntp_io.c: do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + + ChangeLog@1.1.1.78 +3 -0 + do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + + ntpd/ntp_io.c@1.244.2.16 +23 -0 + do not use FD_SET beyond FD_SETSIZE, watch for corruption of inter_list.head + +ChangeSet@1.1436.15.53, 2009-05-07 07:39:41+00:00, davehart@shiny.ad.hartbrothers.com + refclock_jjy.c: + add missing newline before EOF + + ntpd/refclock_jjy.c@1.13.1.2 +1 -1 + add missing newline before EOF + +ChangeSet@1.1845.1.2, 2009-05-07 05:58:42+00:00, davehart@shiny.ad.hartbrothers.com + refclock_jjy.c merge from stable cleanup + + ntpd/refclock_jjy.c@1.16 +1 -0 + dropped a prototype in merge from stable + + ports/winnt/ntp.sln@1.3 +4 -4 + moving ntpd.vcproj to be listed first should make it the default project + + ports/winnt/ntpd/ntpd.vcproj@1.4 +4 -0 + add refclock_jjy.c reference + +ChangeSet@1.1436.15.52, 2009-05-07 05:19:36+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 784] Make --enable-linuxcaps the default when available + add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj + + ChangeLog@1.1.1.77 +1 -0 + [Bug 784] Make --enable-linuxcaps the default when available + + configure.ac@1.400.1.15 +34 -33 + [Bug 784] Make --enable-linuxcaps the default when available + + ports/winnt/ntpd/ntpd.vcproj@1.1.1.1 +4 -0 + add reference to refclock_jjy.c to ports/winnt/ntpd/ntpd.vcproj + +ChangeSet@1.1436.15.51, 2009-05-07 05:10:54+00:00, davehart@shiny.ad.hartbrothers.com + Updated JJY reference clock driver from Takao abe + Make ntpd the default project in Visual C++/Visual Studio + + ChangeLog@1.1.1.76 +4 -0 + Updated JJY reference clock driver from Takao abe + + html/drivers/driver40.html@1.14 +103 -48 + Updated JJY reference clock driver from Takao abe + + ntpd/refclock_jjy.c@1.13.1.1 +153 -5 + Updated JJY reference clock driver from Takao abe + + ports/winnt/ntp.sln@1.1.1.1 +4 -4 + Make ntpd the default project in Visual C++/Visual Studio + +ChangeSet@1.1846, 2009-05-06 17:29:45+00:00, davehart@shiny.ad.hartbrothers.com + Simplify configure.ac NTP_CACHEVERSION interface, update comments + + ChangeLog@1.311 +2 -0 + Clean up configure.ac NTP_CACHEVERSION interface, display cache version + when clearing. Fixes a regression. + + + configure.ac@1.442 +16 -25 + Simplify configure.ac NTP_CACHEVERSION interface, update comments + + gsoc_sntp/configure.ac@1.17 +16 -14 + Simplify configure.ac NTP_CACHEVERSION interface, update comments + + m4/ntp_cacheversion.m4@1.8 +18 -48 + Simplify configure.ac NTP_CACHEVERSION interface, display cache version + for top configure when clearing due to mismatch (fix regression) + + sntp/configure.ac@1.23 +19 -17 + Simplify configure.ac NTP_CACHEVERSION interface, update comments + +ChangeSet@1.1845, 2009-05-06 07:55:27-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P172 + TAG: NTP_4_2_5P172 + + ChangeLog@1.310 +1 -0 + NTP_4_2_5P172 + + gsoc_sntp/sntp-opts.c@1.33 +2 -2 + NTP_4_2_5P172 + + gsoc_sntp/sntp-opts.h@1.33 +3 -3 + NTP_4_2_5P172 + + gsoc_sntp/sntp-opts.texi@1.33 +1 -1 + NTP_4_2_5P172 + + gsoc_sntp/sntp.1@1.33 +2 -2 + NTP_4_2_5P172 + + ntpd/ntpd-opts.c@1.164 +2 -2 + NTP_4_2_5P172 + + ntpd/ntpd-opts.h@1.164 +3 -3 + NTP_4_2_5P172 + + ntpd/ntpd-opts.texi@1.163 +2 -2 + NTP_4_2_5P172 + + ntpd/ntpd.1@1.163 +2 -2 + NTP_4_2_5P172 + + ntpdc/ntpdc-opts.c@1.160 +2 -2 + NTP_4_2_5P172 + + ntpdc/ntpdc-opts.h@1.160 +3 -3 + NTP_4_2_5P172 + + ntpdc/ntpdc-opts.texi@1.159 +2 -2 + NTP_4_2_5P172 + + ntpdc/ntpdc.1@1.159 +2 -2 + NTP_4_2_5P172 + + ntpq/ntpq-opts.c@1.160 +2 -2 + NTP_4_2_5P172 + + ntpq/ntpq-opts.h@1.160 +3 -3 + NTP_4_2_5P172 + + ntpq/ntpq-opts.texi@1.159 +2 -2 + NTP_4_2_5P172 + + ntpq/ntpq.1@1.159 +2 -2 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd-opts.c@1.41 +2 -2 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd-opts.h@1.41 +3 -3 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd-opts.texi@1.41 +1 -1 + NTP_4_2_5P172 + + ntpsnmpd/ntpsnmpd.1@1.41 +2 -2 + NTP_4_2_5P172 + + packageinfo.sh@1.175 +1 -1 + NTP_4_2_5P172 + + sntp/sntp-opts.c@1.160 +2 -2 + NTP_4_2_5P172 + + sntp/sntp-opts.h@1.160 +3 -3 + NTP_4_2_5P172 + + sntp/sntp-opts.texi@1.159 +1 -1 + NTP_4_2_5P172 + + sntp/sntp.1@1.159 +2 -2 + NTP_4_2_5P172 + + util/ntp-keygen-opts.c@1.163 +2 -2 + NTP_4_2_5P172 + + util/ntp-keygen-opts.h@1.163 +3 -3 + NTP_4_2_5P172 + + util/ntp-keygen-opts.texi@1.162 +2 -2 + NTP_4_2_5P172 + + util/ntp-keygen.1@1.162 +2 -2 + NTP_4_2_5P172 + +ChangeSet@1.1844, 2009-05-06 02:47:31-04:00, stenn@whimsy.udel.edu + [Bug 1175] Instability in PLL daemon mode + + ChangeLog@1.309 +2 -1 + [Bug 1175] Instability in PLL daemon mode + + include/Makefile.am@1.33 +57 -55 + typo + + include/ntpd.h@1.125 +1 -1 + [Bug 1175] Instability in PLL daemon mode + + ntpd/ntp_loopfilter.c@1.150 +14 -12 + [Bug 1175] Instability in PLL daemon mode + + ntpd/ntp_proto.c@1.285 +1 -1 + [Bug 1175] Instability in PLL daemon mode + +ChangeSet@1.1840.1.1, 2009-05-05 21:07:51+00:00, davehart@shiny.ad.hartbrothers.com + Makefile.am: + add new file ntp_lineedit.h to noinst_HEADERS + + include/Makefile.am@1.32 +1 -0 + add new file ntp_lineedit.h to noinst_HEADERS + +ChangeSet@1.1842, 2009-05-05 19:19:25+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1176] refclock_parse.c does not compile without PPSAPI + + ChangeLog@1.308 +1 -0 + [Bug 1176] refclock_parse.c does not compile without PPSAPI + + ntpd/refclock_parse.c@1.51 +2 -0 + [Bug 1176] refclock_parse.c does not compile without PPSAPI + +ChangeSet@1.1841, 2009-05-04 08:02:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P171 + TAG: NTP_4_2_5P171 + + ChangeLog@1.307 +1 -0 + NTP_4_2_5P171 + + gsoc_sntp/sntp-opts.c@1.32 +2 -2 + NTP_4_2_5P171 + + gsoc_sntp/sntp-opts.h@1.32 +3 -3 + NTP_4_2_5P171 + + gsoc_sntp/sntp-opts.texi@1.32 +1 -1 + NTP_4_2_5P171 + + gsoc_sntp/sntp.1@1.32 +2 -2 + NTP_4_2_5P171 + + ntpd/ntpd-opts.c@1.163 +2 -2 + NTP_4_2_5P171 + + ntpd/ntpd-opts.h@1.163 +3 -3 + NTP_4_2_5P171 + + ntpd/ntpd-opts.texi@1.162 +2 -2 + NTP_4_2_5P171 + + ntpd/ntpd.1@1.162 +2 -2 + NTP_4_2_5P171 + + ntpdc/ntpdc-opts.c@1.159 +2 -2 + NTP_4_2_5P171 + + ntpdc/ntpdc-opts.h@1.159 +3 -3 + NTP_4_2_5P171 + + ntpdc/ntpdc-opts.texi@1.158 +2 -2 + NTP_4_2_5P171 + + ntpdc/ntpdc.1@1.158 +2 -2 + NTP_4_2_5P171 + + ntpq/ntpq-opts.c@1.159 +2 -2 + NTP_4_2_5P171 + + ntpq/ntpq-opts.h@1.159 +3 -3 + NTP_4_2_5P171 + + ntpq/ntpq-opts.texi@1.158 +2 -2 + NTP_4_2_5P171 + + ntpq/ntpq.1@1.158 +2 -2 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd-opts.c@1.40 +2 -2 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd-opts.h@1.40 +3 -3 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd-opts.texi@1.40 +1 -1 + NTP_4_2_5P171 + + ntpsnmpd/ntpsnmpd.1@1.40 +2 -2 + NTP_4_2_5P171 + + packageinfo.sh@1.174 +1 -1 + NTP_4_2_5P171 + + sntp/sntp-opts.c@1.159 +2 -2 + NTP_4_2_5P171 + + sntp/sntp-opts.h@1.159 +3 -3 + NTP_4_2_5P171 + + sntp/sntp-opts.texi@1.158 +1 -1 + NTP_4_2_5P171 + + sntp/sntp.1@1.158 +2 -2 + NTP_4_2_5P171 + + util/ntp-keygen-opts.c@1.162 +2 -2 + NTP_4_2_5P171 + + util/ntp-keygen-opts.h@1.162 +3 -3 + NTP_4_2_5P171 + + util/ntp-keygen-opts.texi@1.161 +2 -2 + NTP_4_2_5P171 + + util/ntp-keygen.1@1.161 +2 -2 + NTP_4_2_5P171 + +ChangeSet@1.1837.1.2, 2009-05-04 06:41:39+00:00, davehart@shiny.ad.hartbrothers.com + ntp_cacheversion.m4: + iterate to find the quoting problem + + m4/ntp_cacheversion.m4@1.7 +8 -8 + iterate to find the quoting problem + +ChangeSet@1.1837.1.1, 2009-05-04 06:23:22+00:00, davehart@shiny.ad.hartbrothers.com + ntp_cacheversion.m4: + m4 goes infinite + + m4/ntp_cacheversion.m4@1.6 +11 -11 + m4 goes infinite + +ChangeSet@1.1837, 2009-05-04 02:05:29+00:00, davehart@shiny.ad.hartbrothers.com + solve occasional sntp link problems with socket APIs by bringing its + AC_SEARCH_LIBS for gethostent in line with main and gsoc_sntp configure + tests, bump sntp/configure.ac cache version to 20090503 as a result + --- + ntp_cacheversion.m4: clear even other version stamps when flushing + cache iff we are the top configure this invocation. + + + ChangeLog@1.305 +3 -1 + Fix msntp link problem on Solaris when configured before parent + + configure.ac@1.439.1.1 +22 -1 + finally an idiom for "default to null not unset" that works + --- + bump cache version due to changes in sntp and gsoc_sntp gethostent + library search order, the result of which is cached and shared with + this configure. + + gsoc_sntp/configure.ac@1.16 +5 -4 + make gethostent library search compatible with parent configure, and + bump cache version because it is cached. + + m4/ntp_cacheversion.m4@1.5 +67 -36 + clear even other version stamps when flushing cache iff we are the + top configure this invocation. Prevents bump of child version stamp + and parent version stamp at the same time from causing a useless + second flush by the child just after the parent has recreated it from + empty. + + sntp/configure.ac@1.22 +15 -2 + solve occasional sntp link problems with socket APIs by bringing its + AC_SEARCH_LIBS for gethostent in line with main and gsoc_sntp configure + --- + bump config.cache version for incompatible gethostent library search + +ChangeSet@1.1833.2.1, 2009-05-03 15:21:37-04:00, stenn@whimsy.udel.edu + Autokey documentation cleanup from Dave Mills + + ChangeLog@1.302.2.1 +1 -0 + Autokey documentation cleanup from Dave Mills + + html/authopt.html@1.49 +345 -217 + Autokey documentation cleanup from Dave Mills + + html/decode.html@1.7 +8 -8 + Autokey documentation cleanup from Dave Mills + + html/rate.html@1.5 +4 -2 + Autokey documentation cleanup from Dave Mills + + html/xleave.html@1.4 +4 -2 + Autokey documentation cleanup from Dave Mills + +ChangeSet@1.1835, 2009-05-03 14:43:41+00:00, davehart@shiny.ad.hartbrothers.com + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + + gsoc_sntp/configure.ac@1.15 +10 -0 + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + + m4/ntp_cacheversion.m4@1.4 +44 -17 + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + + sntp/configure.ac@1.21 +10 -0 + reliably detect invocation of child configure (NTP_CONFIGURE_PARENT) + +ChangeSet@1.1833.1.5, 2009-05-03 09:15:12+00:00, davehart@shiny.ad.hartbrothers.com + ntp_lineedit.c: + remove leftover of another approach + + libntp/ntp_lineedit.c@1.5 +0 -2 + remove leftover of another approach + +ChangeSet@1.1833.1.4, 2009-05-03 08:37:39+00:00, davehart@shiny.ad.hartbrothers.com + ntp_lineedit.c: + emit newline at interactive EOF to avoid ntpq> osprompt$ + --- + ntp_lineedit.c: + alternating between readline and stone hammers is not good + --- + ntp_lineedit.c: + keep preprocessor # in column one, fix readline path bug + + libntp/ntp_lineedit.c@1.4 +102 -92 + emit newline at interactive EOF to avoid ntpq> osprompt$ + --- + alternating between readline and stone hammers is not good + --- + keep preprocessor # in column one, fix readline path bug + +ChangeSet@1.1833.1.3, 2009-05-03 06:25:51+00:00, davehart@shiny.ad.hartbrothers.com + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_computime.c@1.10 +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_dcf7000.c@1.10 +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_hopf6021.c@1.10 +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_rcc8000.c@1.10 +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_schmid.c@1.10 +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_trimtaip.c@1.10 +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + libparse/clk_varitext.c@1.9 +1 -1 + void printf(...) -> int printf(...) quiets gcc warning + ../../libparse/clk_computime.c:57: warning: conflicting types for built-in function 'printf' + + ports/winnt/ntpd/ntpd.vcproj@1.3 +12 -0 + add libparse/clk_varitext.c (excluded from Windows build) + +ChangeSet@1.1833.1.2, 2009-05-03 05:08:34+00:00, davehart@shiny.ad.hartbrothers.com + ../../libparse/parse.c:211: warning: implicit declaration of function 'bcopy' + ../../libparse/parse.c:211: warning: incompatible implicit declaration of built- + in function 'bcopy' + + #include in ntp_lineedit.c which uses free() + + configure.ac@1.440 +1 -0 + ../../libparse/parse.c:211: warning: implicit declaration of function 'bcopy' + ../../libparse/parse.c:211: warning: incompatible implicit declaration of built- + in function 'bcopy' + + + include/ntp_string.h@1.4 +12 -5 + ../../libparse/parse.c:211: warning: implicit declaration of function 'bcopy' + ../../libparse/parse.c:211: warning: incompatible implicit declaration of built- + in function 'bcopy' + + + libntp/ntp_lineedit.c@1.3 +1 -0 + implicit free decl warning + +ChangeSet@1.1833.1.1, 2009-05-03 01:47:51+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1171] line editing in ntpq/ntpdc + [Bug 1173] NMEA PPSAPI fails on Solaris + + ChangeLog@1.302.1.1 +2 -0 + [Bug 1171] [Bug 1173] + + include/ntp_lineedit.h@1.1 +13 -0 + centralize ntpq/ntpdc interactive line editing + + include/ntp_lineedit.h@1.0 +0 -0 + + libntp/Makefile.am@1.43 +1 -1 + add libntp/ntp_lineedit.c + + libntp/ntp_lineedit.c@1.2 +13 -6 + always return a non-empty string or NULL + + libntp/ntp_lineedit.c@1.1 +227 -0 + centralize ntpq/ntpdc interactive line editing + + libntp/ntp_lineedit.c@1.0 +0 -0 + + m4/ntp_lineeditlibs.m4@1.6 +53 -53 + [Bug 1171] + + ntpd/refclock_nmea.c@1.35 +1 -0 + [Bug 1173] set pps_params.api_version = PPS_API_VERS_1 before calling pps_params + + ntpdc/ntpdc.c@1.62 +9 -30 + [Bug 1171] + + ntpq/ntpq.c@1.84 +10 -30 + [Bug 1171] + + ports/winnt/libntp/libntp.vcproj@1.5 +8 -0 + add ntp_lineedit.c ntp_lineedit.h references + + ports/winnt/ntpdc/ntpdc.vcproj@1.3 +4 -0 + add ntp_lineedit.h reference + + ports/winnt/ntpq/ntpq.vcproj@1.3 +4 -0 + add ntp_lineedit.h reference + +ChangeSet@1.1833, 2009-05-02 08:06:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P170 + TAG: NTP_4_2_5P170 + + ChangeLog@1.302 +1 -0 + NTP_4_2_5P170 + + gsoc_sntp/sntp-opts.c@1.31 +2 -2 + NTP_4_2_5P170 + + gsoc_sntp/sntp-opts.h@1.31 +3 -3 + NTP_4_2_5P170 + + gsoc_sntp/sntp-opts.texi@1.31 +1 -1 + NTP_4_2_5P170 + + gsoc_sntp/sntp.1@1.31 +2 -2 + NTP_4_2_5P170 + + ntpd/ntpd-opts.c@1.162 +2 -2 + NTP_4_2_5P170 + + ntpd/ntpd-opts.h@1.162 +3 -3 + NTP_4_2_5P170 + + ntpd/ntpd-opts.texi@1.161 +1 -1 + NTP_4_2_5P170 + + ntpd/ntpd.1@1.161 +2 -2 + NTP_4_2_5P170 + + ntpdc/ntpdc-opts.c@1.158 +2 -2 + NTP_4_2_5P170 + + ntpdc/ntpdc-opts.h@1.158 +3 -3 + NTP_4_2_5P170 + + ntpdc/ntpdc-opts.texi@1.157 +1 -1 + NTP_4_2_5P170 + + ntpdc/ntpdc.1@1.157 +2 -2 + NTP_4_2_5P170 + + ntpq/ntpq-opts.c@1.158 +2 -2 + NTP_4_2_5P170 + + ntpq/ntpq-opts.h@1.158 +3 -3 + NTP_4_2_5P170 + + ntpq/ntpq-opts.texi@1.157 +1 -1 + NTP_4_2_5P170 + + ntpq/ntpq.1@1.157 +2 -2 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd-opts.c@1.39 +2 -2 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd-opts.h@1.39 +3 -3 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd-opts.texi@1.39 +1 -1 + NTP_4_2_5P170 + + ntpsnmpd/ntpsnmpd.1@1.39 +2 -2 + NTP_4_2_5P170 + + packageinfo.sh@1.173 +1 -1 + NTP_4_2_5P170 + + sntp/sntp-opts.c@1.158 +2 -2 + NTP_4_2_5P170 + + sntp/sntp-opts.h@1.158 +3 -3 + NTP_4_2_5P170 + + sntp/sntp-opts.texi@1.157 +1 -1 + NTP_4_2_5P170 + + sntp/sntp.1@1.157 +2 -2 + NTP_4_2_5P170 + + util/ntp-keygen-opts.c@1.161 +2 -2 + NTP_4_2_5P170 + + util/ntp-keygen-opts.h@1.161 +3 -3 + NTP_4_2_5P170 + + util/ntp-keygen-opts.texi@1.160 +1 -1 + NTP_4_2_5P170 + + util/ntp-keygen.1@1.160 +2 -2 + NTP_4_2_5P170 + +ChangeSet@1.1830.4.3, 2009-05-02 10:26:07+00:00, davehart@shiny.ad.hartbrothers.com + ntp_cacheversion.m4: + remove diagnostic after successful tests + + m4/ntp_cacheversion.m4@1.3 +0 -1 + remove diagnostic after successful tests + +ChangeSet@1.1830.4.2, 2009-05-02 08:37:14+00:00, davehart@shiny.ad.hartbrothers.com + do not clear config.cache immediately after it is created empty + + ChangeLog@1.299.4.2 +1 -0 + do not clear config.cache immediately after it is created empty + + m4/ntp_cacheversion.m4@1.2 +19 -6 + do not clear config.cache immediately after it is created empty + +ChangeSet@1.1436.15.50, 2009-05-02 02:38:49-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P7_RC5 + TAG: NTP_4_2_4P7_RC5 + + ChangeLog@1.1.1.75 +1 -0 + NTP_4_2_4P7_RC5 + + ntpd/ntpd-opts.c@1.50.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + ntpd/ntpd-opts.h@1.50.22.1 +3 -3 + NTP_4_2_4P7_RC5 + + ntpd/ntpd-opts.texi@1.49.22.1 +1 -1 + NTP_4_2_4P7_RC5 + + ntpd/ntpd.1@1.48.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim-opts.c@1.50.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim-opts.h@1.50.22.1 +3 -3 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim-opts.texi@1.48.22.1 +1 -1 + NTP_4_2_4P7_RC5 + + ntpd/ntpdsim.1@1.48.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc-opts.c@1.50.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc-opts.h@1.50.22.1 +3 -3 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc-opts.texi@1.48.22.1 +1 -1 + NTP_4_2_4P7_RC5 + + ntpdc/ntpdc.1@1.48.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + ntpq/ntpq-opts.c@1.52.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + ntpq/ntpq-opts.h@1.52.22.1 +3 -3 + NTP_4_2_4P7_RC5 + + ntpq/ntpq-opts.texi@1.49.22.1 +1 -1 + NTP_4_2_4P7_RC5 + + ntpq/ntpq.1@1.48.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + packageinfo.sh@1.65.30.1 +1 -1 + NTP_4_2_4P7_RC5 + + sntp/sntp-opts.c@1.49.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + sntp/sntp-opts.h@1.49.22.1 +3 -3 + NTP_4_2_4P7_RC5 + + sntp/sntp-opts.texi@1.46.22.1 +1 -1 + NTP_4_2_4P7_RC5 + + sntp/sntp.1@1.49.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + util/ntp-keygen-opts.c@1.49.22.1 +2 -2 + NTP_4_2_4P7_RC5 + + util/ntp-keygen-opts.h@1.49.22.1 +3 -3 + NTP_4_2_4P7_RC5 + + util/ntp-keygen-opts.texi@1.47.22.1 +1 -1 + NTP_4_2_4P7_RC5 + + util/ntp-keygen.1@1.47.22.1 +2 -2 + NTP_4_2_4P7_RC5 + +ChangeSet@1.1830.3.1, 2009-05-02 00:13:27-04:00, stenn@whimsy.udel.edu + Updates from Dave Mills + + ChangeLog@1.299.3.4 +1 -0 + loopfilter FLL/PLL crossover cleanup from Dave Mills + + ChangeLog@1.299.3.3 +1 -0 + Documentation updates from Dave Mills + + ChangeLog@1.299.3.2 +1 -0 + Cleanup from Dave Mills + + ChangeLog@1.299.3.1 +1 -0 + crypto API cleanup from Dave Mills + + html/authopt.html@1.48 +4 -2 + Documentation updates from Dave Mills + + html/keygen.html@1.15 +20 -63 + Documentation updates from Dave Mills + + include/ntpd.h@1.124 +1 -1 + crypto API cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.133 +38 -55 + crypto API cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.149 +12 -19 + loopfilter FLL/PLL crossover cleanup from Dave Mills + + ntpd/ntp_proto.c@1.284 +9 -11 + crypto API cleanup from Dave Mills + + util/ntp-keygen.c@1.57 +2 -6 + Cleanup from Dave Mills + +ChangeSet@1.1830.2.2, 2009-05-02 01:55:12+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + restore -dev version of HAS_ROUTING_SOCKET stuff after merging from + -stable un-backporting of same + + configure.ac@1.437.2.2 +12 -1 + restore -dev version of HAS_ROUTING_SOCKET stuff after merging from + -stable un-backporting of same + +ChangeSet@1.1436.15.49, 2009-05-02 01:49:02+00:00, davehart@shiny.ad.hartbrothers.com + flock-build: + set -m wasn't needed with ssh -tt and caused problems, remove + ChangeLog: + [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. + remove unportable 'set -m' from flock-build script + configure.ac: + reverse accidental backport from -dev of struct rtattr test in + configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + + ChangeLog@1.1.1.74 +5 -0 + [Bug 1172] 4.2.4p7-RC{3,4} fail to build on linux. + remove unportable 'set -m' from flock-build script + + configure.ac@1.400.1.14 +1 -12 + reverse accidental backport from -dev of struct rtattr test in + configure.ac without corresponding ntp_io.c code for HAVE_RTNETLINK + + flock-build@1.39.1.2 +3 -5 + set -m wasn't needed with ssh -tt and caused problems, remove + +ChangeSet@1.1828.1.1, 2009-05-01 20:05:24+00:00, davehart@shiny.ad.hartbrothers.com + add NTP_CACHEVERSION to toss config.cache from different version + --- + enable gcc -Wstrict-overflow for gsoc_sntp + + ChangeLog@1.297.1.1 +2 -0 + Add NTP_CACHEVERSION to configure.ac m4/ntp_cacheversion.m4 + + configure.ac@1.437.1.1 +21 -5 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + + gsoc_sntp/Makefile.am@1.7 +1 -1 + ACLOCAL_AMFLAGS += -I ../m4 + + gsoc_sntp/configure.ac@1.14 +17 -1 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + --- + enable gcc -Wstrict-overflow + + include/ntp.h@1.153 +1 -0 + references l_fp type, needs #include + + m4/ntp_cacheversion.m4@1.1 +82 -0 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + + m4/ntp_cacheversion.m4@1.0 +0 -0 + + ntpd/ntp_refclock.c@1.85 +2 -2 + pps_handle_t is properly an opaque scalar, timepps-Solaris.h will be fixed + + sntp/Makefile.am@1.25 +1 -1 + ACLOCAL_AMFLAGS += -I ../m4 + + sntp/configure.ac@1.20 +17 -1 + add NTP_CACHEVERSION() m4 macro to flush incompatible config.cache + +ChangeSet@1.1831, 2009-05-01 15:05:10+00:00, kardel@pogo.udel.edu + configure.ac, refclock_parse.c, ChangeLog: + [Bug 1152] adjust PARSE to new refclock_pps logic + + ChangeLog@1.300 +1 -0 + [Bug 1152] adjust PARSE to new refclock_pps logic + + configure.ac@1.438 +0 -4 + [Bug 1152] adjust PARSE to new refclock_pps logic + + ntpd/refclock_parse.c@1.50 +55 -42 + [Bug 1152] adjust PARSE to new refclock_pps logic + +ChangeSet@1.1830, 2009-04-30 07:58:03-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P169 + TAG: NTP_4_2_5P169 + + ChangeLog@1.299 +1 -0 + NTP_4_2_5P169 + + gsoc_sntp/sntp-opts.c@1.30 +2 -2 + NTP_4_2_5P169 + + gsoc_sntp/sntp-opts.h@1.30 +3 -3 + NTP_4_2_5P169 + + gsoc_sntp/sntp-opts.texi@1.30 +1 -1 + NTP_4_2_5P169 + + gsoc_sntp/sntp.1@1.30 +2 -2 + NTP_4_2_5P169 + + ntpd/ntpd-opts.c@1.161 +2 -2 + NTP_4_2_5P169 + + ntpd/ntpd-opts.h@1.161 +3 -3 + NTP_4_2_5P169 + + ntpd/ntpd-opts.texi@1.160 +1 -1 + NTP_4_2_5P169 + + ntpd/ntpd.1@1.160 +2 -2 + NTP_4_2_5P169 + + ntpdc/ntpdc-opts.c@1.157 +2 -2 + NTP_4_2_5P169 + + ntpdc/ntpdc-opts.h@1.157 +3 -3 + NTP_4_2_5P169 + + ntpdc/ntpdc-opts.texi@1.156 +1 -1 + NTP_4_2_5P169 + + ntpdc/ntpdc.1@1.156 +2 -2 + NTP_4_2_5P169 + + ntpq/ntpq-opts.c@1.157 +2 -2 + NTP_4_2_5P169 + + ntpq/ntpq-opts.h@1.157 +3 -3 + NTP_4_2_5P169 + + ntpq/ntpq-opts.texi@1.156 +1 -1 + NTP_4_2_5P169 + + ntpq/ntpq.1@1.156 +2 -2 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd-opts.c@1.38 +2 -2 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd-opts.h@1.38 +3 -3 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd-opts.texi@1.38 +1 -1 + NTP_4_2_5P169 + + ntpsnmpd/ntpsnmpd.1@1.38 +2 -2 + NTP_4_2_5P169 + + packageinfo.sh@1.172 +1 -1 + NTP_4_2_5P169 + + sntp/sntp-opts.c@1.157 +2 -2 + NTP_4_2_5P169 + + sntp/sntp-opts.h@1.157 +3 -3 + NTP_4_2_5P169 + + sntp/sntp-opts.texi@1.156 +1 -1 + NTP_4_2_5P169 + + sntp/sntp.1@1.156 +2 -2 + NTP_4_2_5P169 + + util/ntp-keygen-opts.c@1.160 +2 -2 + NTP_4_2_5P169 + + util/ntp-keygen-opts.h@1.160 +3 -3 + NTP_4_2_5P169 + + util/ntp-keygen-opts.texi@1.159 +1 -1 + NTP_4_2_5P169 + + util/ntp-keygen.1@1.159 +2 -2 + NTP_4_2_5P169 + +ChangeSet@1.1829, 2009-04-30 02:59:43-04:00, stenn@whimsy.udel.edu + [Bug 1171] Note that we never look for -lreadline by default + + ChangeLog@1.298 +1 -0 + [Bug 1171] Note that we never look for -lreadline by default + + m4/ntp_lineeditlibs.m4@1.5 +1 -1 + [Bug 1171] Note that we never look for -lreadline by default + +ChangeSet@1.1826.1.1, 2009-04-29 18:46:50-04:00, stenn@whimsy.udel.edu + typo fix on [Bug 1166] entry + + ChangeLog@1.295.1.1 +1 -1 + typo fix on [Bug 1166] entry + +ChangeSet@1.1826, 2009-04-29 08:04:45-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P168 + TAG: NTP_4_2_5P168 + + ChangeLog@1.295 +1 -0 + NTP_4_2_5P168 + + gsoc_sntp/sntp-opts.c@1.29 +2 -2 + NTP_4_2_5P168 + + gsoc_sntp/sntp-opts.h@1.29 +3 -3 + NTP_4_2_5P168 + + gsoc_sntp/sntp-opts.texi@1.29 +1 -1 + NTP_4_2_5P168 + + gsoc_sntp/sntp.1@1.29 +2 -2 + NTP_4_2_5P168 + + ntpd/ntpd-opts.c@1.160 +2 -2 + NTP_4_2_5P168 + + ntpd/ntpd-opts.h@1.160 +3 -3 + NTP_4_2_5P168 + + ntpd/ntpd-opts.texi@1.159 +1 -1 + NTP_4_2_5P168 + + ntpd/ntpd.1@1.159 +2 -2 + NTP_4_2_5P168 + + ntpdc/ntpdc-opts.c@1.156 +2 -2 + NTP_4_2_5P168 + + ntpdc/ntpdc-opts.h@1.156 +3 -3 + NTP_4_2_5P168 + + ntpdc/ntpdc-opts.texi@1.155 +1 -1 + NTP_4_2_5P168 + + ntpdc/ntpdc.1@1.155 +2 -2 + NTP_4_2_5P168 + + ntpq/ntpq-opts.c@1.156 +2 -2 + NTP_4_2_5P168 + + ntpq/ntpq-opts.h@1.156 +3 -3 + NTP_4_2_5P168 + + ntpq/ntpq-opts.texi@1.155 +1 -1 + NTP_4_2_5P168 + + ntpq/ntpq.1@1.155 +2 -2 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd-opts.c@1.37 +2 -2 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd-opts.h@1.37 +3 -3 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd-opts.texi@1.37 +1 -1 + NTP_4_2_5P168 + + ntpsnmpd/ntpsnmpd.1@1.37 +2 -2 + NTP_4_2_5P168 + + packageinfo.sh@1.171 +1 -1 + NTP_4_2_5P168 + + sntp/sntp-opts.c@1.156 +2 -2 + NTP_4_2_5P168 + + sntp/sntp-opts.h@1.156 +3 -3 + NTP_4_2_5P168 + + sntp/sntp-opts.texi@1.155 +1 -1 + NTP_4_2_5P168 + + sntp/sntp.1@1.155 +2 -2 + NTP_4_2_5P168 + + util/ntp-keygen-opts.c@1.159 +2 -2 + NTP_4_2_5P168 + + util/ntp-keygen-opts.h@1.159 +3 -3 + NTP_4_2_5P168 + + util/ntp-keygen-opts.texi@1.158 +1 -1 + NTP_4_2_5P168 + + util/ntp-keygen.1@1.158 +2 -2 + NTP_4_2_5P168 + +ChangeSet@1.1436.15.48, 2009-04-29 04:03:41-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P7_RC4 + TAG: NTP_4_2_4P7_RC4 + + ChangeLog@1.1.1.73 +1 -0 + NTP_4_2_4P7_RC4 + + ntpd/ntpd-opts.c@1.50.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + ntpd/ntpd-opts.h@1.50.21.1 +3 -3 + NTP_4_2_4P7_RC4 + + ntpd/ntpd-opts.texi@1.49.21.1 +1 -1 + NTP_4_2_4P7_RC4 + + ntpd/ntpd.1@1.48.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim-opts.c@1.50.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim-opts.h@1.50.21.1 +3 -3 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim-opts.texi@1.48.21.1 +1 -1 + NTP_4_2_4P7_RC4 + + ntpd/ntpdsim.1@1.48.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc-opts.c@1.50.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc-opts.h@1.50.21.1 +3 -3 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc-opts.texi@1.48.21.1 +1 -1 + NTP_4_2_4P7_RC4 + + ntpdc/ntpdc.1@1.48.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + ntpq/ntpq-opts.c@1.52.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + ntpq/ntpq-opts.h@1.52.21.1 +3 -3 + NTP_4_2_4P7_RC4 + + ntpq/ntpq-opts.texi@1.49.21.1 +1 -1 + NTP_4_2_4P7_RC4 + + ntpq/ntpq.1@1.48.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + packageinfo.sh@1.65.29.1 +1 -1 + NTP_4_2_4P7_RC4 + + sntp/sntp-opts.c@1.49.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + sntp/sntp-opts.h@1.49.21.1 +3 -3 + NTP_4_2_4P7_RC4 + + sntp/sntp-opts.texi@1.46.21.1 +1 -1 + NTP_4_2_4P7_RC4 + + sntp/sntp.1@1.49.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + util/ntp-keygen-opts.c@1.49.21.1 +2 -2 + NTP_4_2_4P7_RC4 + + util/ntp-keygen-opts.h@1.49.21.1 +3 -3 + NTP_4_2_4P7_RC4 + + util/ntp-keygen-opts.texi@1.47.21.1 +1 -1 + NTP_4_2_4P7_RC4 + + util/ntp-keygen.1@1.47.21.1 +2 -2 + NTP_4_2_4P7_RC4 + +ChangeSet@1.1436.15.47, 2009-04-29 01:50:44-04:00, stenn@pogo.udel.edu + No need to know the GCC -W items in config.h + + configure.ac@1.400.1.13 +2 -12 + No need to know the GCC -W items in config.h + +ChangeSet@1.1817.4.1, 2009-04-29 01:40:19-04:00, stenn@whimsy.udel.edu + Updates from Dave Mills + + ChangeLog@1.286.4.6 +1 -0 + Updates from Dave Mills + + ChangeLog@1.286.4.5 +1 -0 + updates + + ChangeLog@1.286.4.4 +1 -0 + Fix the error return and syslog function ID in refclock_{param,ppsapi} + + ChangeLog@1.286.4.3 +1 -0 + Make sure syspoll is within the peer's minpoll/maxpoll bounds + + ChangeLog@1.286.4.2 +1 -0 + ntp_crypto.c: Use sign_siglen, not len. sign key filename cleanup. + + ChangeLog@1.286.4.1 +1 -0 + Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths + + html/keygen.html@1.14 +222 -133 + ntp-keygen updates + + include/ntp.h@1.152 +3 -3 + Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths + + include/ntp_crypto.h@1.45 +1 -1 + Bump NTP_MAXEXTEN from 1024 to 2048, update values for some field lengths + + ntpd/ntp_crypto.c@1.132 +19 -23 + ntp_crypto.c: Use sign_siglen, not len. sign key filename cleanup. + + ntpd/ntp_proto.c@1.283 +18 -2 + Make sure syspoll is within the peer's minpoll/maxpoll bounds + + ntpd/ntp_refclock.c@1.82.1.1 +7 -7 + Fix the error return and syslog function ID in refclock_{param,ppsapi} + + util/ntp-keygen.c@1.54.1.1 +27 -16 + updates + +ChangeSet@1.1817.3.1, 2009-04-28 08:09:13-04:00, murray@pogo.udel.edu + refclock_hpgps.c: + Fix for bug 1090, bogus leapseconds + ChangeLog: + Fix for bug 1090, bogus leapseconds in refclock_hpgps + + ChangeLog@1.286.3.1 +1 -0 + Fix for bug 1090, bogus leapseconds in refclock_hpgps + + ntpd/refclock_hpgps.c@1.9 +12 -5 + Fix for bug 1090, bogus leapseconds + +ChangeSet@1.1817.2.2, 2009-04-28 08:23:30+00:00, davehart@shiny.ad.hartbrothers.com + dcfd.c: + tvsec -> tv_sec typo + + parseutil/dcfd.c@1.22 +1 -1 + tvsec -> tv_sec typo + +ChangeSet@1.1816.1.2, 2009-04-28 07:00:17+00:00, davehart@shiny.ad.hartbrothers.com + ntp_parser.h, ntp_parser.c: + bison 2.4.1 generated files + + ntpd/ntp_parser.c@1.37 +372 -214 + bison 2.4.1 generated files + + ntpd/ntp_parser.h@1.21 +159 -1 + bison 2.4.1 generated files + +ChangeSet@1.1816.1.1, 2009-04-28 06:59:44+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1169] quiet compiler warnings + Re-enable gcc -Wstrict-prototypes when not building with OpenSSL + Enable gcc -Wstrict-overflow + ntpq/ntpdc emit newline after accepting password on Windows + + ChangeLog@1.285.1.1 +4 -0 + * [Bug 1169] quiet compiler warnings + * Re-enable gcc -Wstrict-prototypes when not building with OpenSSL + * Enable gcc -Wstrict-overflow + * ntpq/ntpdc emit newline after accepting password on Windows + + + configure.ac@1.434.1.1 +40 -26 + enable -Wstrict-overflow, use -Wno-strict-prototypes only w/OpenSSL + + gsoc_sntp/crypto.c@1.5 +3 -3 + auth_init() local key_cnt shadowed global of same name + --- + add const qualifier to auth_init() keyfile argument + + gsoc_sntp/crypto.h@1.4 +1 -1 + add const qualifier to auth_init() keyfile argument + + gsoc_sntp/kod_management.c@1.8 +2 -2 + add const qualifier to kod_db_file, kod_init_kod_db() arg + + gsoc_sntp/kod_management.h@1.5 +1 -1 + add const qualifier to kod_db_file, kod_init_kod_db() arg + + gsoc_sntp/log.c@1.8 +1 -1 + add const qualifier + + gsoc_sntp/log.h@1.5 +1 -1 + add const qualifier + + gsoc_sntp/main.c@1.12 +4 -3 + #include for isc_net_probeipv6 prototype + --- + remove three casts with const qualifiers fixed + + gsoc_sntp/networking.c@1.18 +7 -17 + remove unused sockaddr_in, sockaddr_in6 + --- + char *buf shadowed declaration warning, printf %li not %i + --- + two more char *buf shadowy declarations + + include/isc/file.h@1.2 +2 -2 + change parameter name in prototype from time to mtime to avoid (noisy) + warning about shadowing another "time" declaration + + include/isc/mem.h@1.3 +10 -5 + macro away troublesom isc_mem_t incomplete type warnings + --- + #include (probably redundant with ) + + include/ntp_config.h@1.51 +1 -0 + prototype destroy_address_node() + + include/ntp_stdlib.h@1.28 +5 -5 + indent, whitespace cleanup + + include/ntpsim.h@1.10 +1 -0 + prototype entrypoint ntpsim(argc, argv) + + libisc/inet_ntop.c@1.5 +6 -0 + conditionalize code to match header + + libisc/inet_pton.c@1.2 +6 -0 + conditionalize code to match header + + libisc/mem.c@1.3 +5 -0 + note disuse of mem.c + + libntp/Makefile.am@1.42 +2 -4 + let's see if libisc/log.c is really used + --- + remove mem.c from build in favor of isc/mem.h macros + + libntp/machines.c@1.20 +3 -0 + emit newline after ntpq/ntpdc passwd prompt on Windows + + libntp/numtoa.c@1.3 +8 -0 + include config.h, netinet/in.h for htonl + + libntp/numtohost.c@1.4 +8 -0 + include config.h, netinet/in.h for htonl + + libntp/prettydate.c@1.12 +3 -1 + prototype common_prettydate() + + libntp/statestr.c@1.15 +5 -1 + flash_codes unused, see ntpq.c tstflagnames + + libparse/parsesolaris.c@1.8 +12 -12 + ctime -> c_time to quiet shadowed declaration warning + remove const from pprintf format string to match use + + ntpd/ntp_config.c@1.191 +6 -0 + missed DESTROY_QUEUE(unpeers) in merge into 1165 repo + --- + quiet compiler warning about unused get_next_address for !SIM + + ntpd/ntp_intres.c@1.59 +0 -1 + ding dong, the bong is dead. (remove unused bong() prototype) + + ntpd/ntp_parser.y@1.32 +2 -2 + missing semicolons on Unpeer, Unconfig trip up original yacc, bison -y + + ntpd/ntp_refclock.c@1.83 +2 -2 + quiet two warnings comparing scalar ap->handle with pointer NULL + + ntpd/ntp_util.c@1.69 +7 -0 + prototype uninit_util() + + ntpd/ntpsim.c@1.20 +0 -1 + prototype entry point ntpsim(argc, argv) moves to ntpdsim.h + + ntpd/refclock_mx4200.c@1.24 +12 -12 + %lu not %ul printf format specifier + local leapsec -> leapsec_warn to avoid shadowing global leapsec + + ntpd/refclock_palisade.c@1.24 +5 -3 + wrap dead sendcmd() in #ifdef UNUSED + + ntpd/refclock_palisade.h@1.11 +2 -0 + wrap sendcmd() prototype with #ifdef UNUSED + + ntpq/ntpq.c@1.83 +181 -162 + conditionalize VxWorks-only clear_globals so it doesn't compile others + --- + quiet warnings building ntpq.c for libntpq, getcmds and abortcmd + --- + quiet tokenize, getarg defined but not used for libntpq + --- + quiet xcp possibly uninitialized in help + clean up indents, whitespace + + parseutil/dcfd.c@1.21 +5 -4 + use explicit offset test rather than timercmp() to avoid 'simplifying + conditional to constant' warning with -Wstrict-overflow from testing if + constant 0 max_adj_offset.tv_sec is greater than something else. + + ports/winnt/libntp/libntp.vcproj@1.4 +0 -22 + remove libisc/mem.c from build in favor of isc/mem.h macros + + ports/winnt/ntpd/ntpd.vcproj@1.2 +4 -0 + add reference to ntpsim.h + + ports/winnt/ntpd/ntservice.c@1.16 +5 -5 + correct #ifdefs for leak debugging + + util/ntp-keygen.c@1.55 +7 -7 + use strdup to get non-const copies of string args + cast time_t to long/u_long explicitly for 64-bit time_t + +ChangeSet@1.1436.15.46, 2009-04-27 11:47:49+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + add [Bug 1167] to ChangeLog entry + + ChangeLog@1.1.1.72 +1 -1 + add [Bug 1167] to ChangeLog entry + +ChangeSet@1.1817.1.2, 2009-04-26 14:17:47+00:00, davehart@shiny.ad.hartbrothers.com + Remove truncation of position (blanking) code in refclock_nmea.c + + ChangeLog@1.286.1.2 +1 -0 + Remove truncation of position (blanking) code in refclock_nmea.c + + ntpd/refclock_nmea.c@1.34 +1 -71 + Remove truncation of position (blanking) code in refclock_nmea.c + +ChangeSet@1.1817.1.1, 2009-04-26 07:54:41-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P167 + TAG: NTP_4_2_5P167 + + ChangeLog@1.286.1.1 +1 -0 + NTP_4_2_5P167 + + gsoc_sntp/sntp-opts.c@1.28 +2 -2 + NTP_4_2_5P167 + + gsoc_sntp/sntp-opts.h@1.28 +3 -3 + NTP_4_2_5P167 + + gsoc_sntp/sntp-opts.texi@1.28 +1 -1 + NTP_4_2_5P167 + + gsoc_sntp/sntp.1@1.28 +2 -2 + NTP_4_2_5P167 + + ntpd/ntpd-opts.c@1.159 +2 -2 + NTP_4_2_5P167 + + ntpd/ntpd-opts.h@1.159 +3 -3 + NTP_4_2_5P167 + + ntpd/ntpd-opts.texi@1.158 +1 -1 + NTP_4_2_5P167 + + ntpd/ntpd.1@1.158 +2 -2 + NTP_4_2_5P167 + + ntpdc/ntpdc-opts.c@1.155 +2 -2 + NTP_4_2_5P167 + + ntpdc/ntpdc-opts.h@1.155 +3 -3 + NTP_4_2_5P167 + + ntpdc/ntpdc-opts.texi@1.154 +1 -1 + NTP_4_2_5P167 + + ntpdc/ntpdc.1@1.154 +2 -2 + NTP_4_2_5P167 + + ntpq/ntpq-opts.c@1.155 +2 -2 + NTP_4_2_5P167 + + ntpq/ntpq-opts.h@1.155 +3 -3 + NTP_4_2_5P167 + + ntpq/ntpq-opts.texi@1.154 +1 -1 + NTP_4_2_5P167 + + ntpq/ntpq.1@1.154 +2 -2 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd-opts.c@1.36 +2 -2 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd-opts.h@1.36 +3 -3 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd-opts.texi@1.36 +1 -1 + NTP_4_2_5P167 + + ntpsnmpd/ntpsnmpd.1@1.36 +2 -2 + NTP_4_2_5P167 + + packageinfo.sh@1.170 +1 -1 + NTP_4_2_5P167 + + sntp/sntp-opts.c@1.155 +2 -2 + NTP_4_2_5P167 + + sntp/sntp-opts.h@1.155 +3 -3 + NTP_4_2_5P167 + + sntp/sntp-opts.texi@1.154 +1 -1 + NTP_4_2_5P167 + + sntp/sntp.1@1.154 +2 -2 + NTP_4_2_5P167 + + util/ntp-keygen-opts.c@1.158 +2 -2 + NTP_4_2_5P167 + + util/ntp-keygen-opts.h@1.158 +3 -3 + NTP_4_2_5P167 + + util/ntp-keygen-opts.texi@1.157 +1 -1 + NTP_4_2_5P167 + + util/ntp-keygen.1@1.157 +2 -2 + NTP_4_2_5P167 + +ChangeSet@1.1819, 2009-04-26 06:18:21+00:00, davehart@shiny.ad.hartbrothers.com + NTP_LINEEDITLIBS refinements for Autoconf 2.62 warnings + + ChangeLog@1.288 +1 -0 + NTP_LINEEDITLIBS refinements for Autoconf 2.62 warnings + + m4/ntp_lineeditlibs.m4@1.4 +46 -40 + NTP_LINEEDITLIBS refinements for Autoconf 2.62 warnings + +ChangeSet@1.1436.15.45, 2009-04-26 06:10:27+00:00, davehart@shiny.ad.hartbrothers.com + gcc -Winit-self is used only if it is understood + + ChangeLog@1.1.1.71 +4 -0 + gcc -Winit-self is used only if it is understood + + configure.ac@1.400.1.12 +34 -2 + gcc -Winit-self is used only if it is understood + +ChangeSet@1.1817, 2009-04-25 20:02:54-04:00, stenn@whimsy.udel.edu + Crypto cleanup from Dave Mills + + ChangeLog@1.286 +1 -0 + Crypto cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.131 +4 -6 + Crypto cleanup from Dave Mills + + ntpd/ntp_proto.c@1.282 +16 -11 + Crypto cleanup from Dave Mills + +ChangeSet@1.1816, 2009-04-25 07:55:55-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P166 + TAG: NTP_4_2_5P166 + + ChangeLog@1.285 +1 -0 + NTP_4_2_5P166 + + gsoc_sntp/sntp-opts.c@1.27 +2 -2 + NTP_4_2_5P166 + + gsoc_sntp/sntp-opts.h@1.27 +3 -3 + NTP_4_2_5P166 + + gsoc_sntp/sntp-opts.texi@1.27 +1 -1 + NTP_4_2_5P166 + + gsoc_sntp/sntp.1@1.27 +2 -2 + NTP_4_2_5P166 + + ntpd/ntpd-opts.c@1.158 +2 -2 + NTP_4_2_5P166 + + ntpd/ntpd-opts.h@1.158 +3 -3 + NTP_4_2_5P166 + + ntpd/ntpd-opts.texi@1.157 +1 -1 + NTP_4_2_5P166 + + ntpd/ntpd.1@1.157 +2 -2 + NTP_4_2_5P166 + + ntpdc/ntpdc-opts.c@1.154 +2 -2 + NTP_4_2_5P166 + + ntpdc/ntpdc-opts.h@1.154 +3 -3 + NTP_4_2_5P166 + + ntpdc/ntpdc-opts.texi@1.153 +1 -1 + NTP_4_2_5P166 + + ntpdc/ntpdc.1@1.153 +2 -2 + NTP_4_2_5P166 + + ntpq/ntpq-opts.c@1.154 +2 -2 + NTP_4_2_5P166 + + ntpq/ntpq-opts.h@1.154 +3 -3 + NTP_4_2_5P166 + + ntpq/ntpq-opts.texi@1.153 +1 -1 + NTP_4_2_5P166 + + ntpq/ntpq.1@1.153 +2 -2 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd-opts.c@1.35 +2 -2 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd-opts.h@1.35 +3 -3 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd-opts.texi@1.35 +1 -1 + NTP_4_2_5P166 + + ntpsnmpd/ntpsnmpd.1@1.35 +2 -2 + NTP_4_2_5P166 + + packageinfo.sh@1.169 +1 -1 + NTP_4_2_5P166 + + sntp/sntp-opts.c@1.154 +2 -2 + NTP_4_2_5P166 + + sntp/sntp-opts.h@1.154 +3 -3 + NTP_4_2_5P166 + + sntp/sntp-opts.texi@1.153 +1 -1 + NTP_4_2_5P166 + + sntp/sntp.1@1.153 +2 -2 + NTP_4_2_5P166 + + util/ntp-keygen-opts.c@1.157 +2 -2 + NTP_4_2_5P166 + + util/ntp-keygen-opts.h@1.157 +3 -3 + NTP_4_2_5P166 + + util/ntp-keygen-opts.texi@1.156 +1 -1 + NTP_4_2_5P166 + + util/ntp-keygen.1@1.156 +2 -2 + NTP_4_2_5P166 + +ChangeSet@1.1815, 2009-04-25 08:22:13+00:00, davehart@shiny.ad.hartbrothers.com + bison products + + ntpd/ntp_parser.c@1.36 +649 -373 + generated from [Bug 1165] ChangeSet's ntp_parser.y + + ntpd/ntp_parser.h@1.20 +25 -177 + generated from [Bug 1165] ChangeSet's ntp_parser.y + +ChangeSet@1.1807.2.1, 2009-04-25 08:08:01+00:00, davehart@shiny.ad.hartbrothers.com + * [Bug 1165] Clean up small memory leaks in the config file parser + * Correct logconfig keyword declaration to MULTIPLE_ARG + * Enable filename and line number leak reporting on Windows when built + DEBUG for all the typical C runtime allocators such as calloc, + malloc, and strdup. Previously only emalloc calls were covered. + * Add DEBUG-only code to free dynamically allocated memory that would + otherwise remain allocated at ntpd exit, to allow less forgivable + leaks to stand out in leaks reported after exit. + * Ensure termination of strings in ports/winnt/libisc/isc_strerror.c + and quiet compiler warnings. + + + ChangeLog@1.280.2.1 +10 -0 + [Bug 1165] config parser leak + logconfig keyword correction + DEBUG-only freeing of allocated memory at exit + Windows CRT leak debugging enhanced + isc_strerror compile warnings quieted + + include/ntp_filegen.h@1.5 +3 -0 + DEBUG-only freeing of allocated memory at exit + + include/ntp_stdlib.h@1.27 +4 -4 + Windows CRT leak debugging enhanced + + include/ntpd.h@1.121.1.1 +1 -1 + no const qualifier for ntp_signd_socket matches parser return types + + libntp/emalloc.c@1.6 +17 -18 + Windows CRT leak debugging enhanced + + libntp/msyslog.c@1.21 +7 -4 + use errno for msyslog on Windows if (NO_ERROR == GetLastError()) + + ntpd/ntp_config.c@1.188.1.1 +152 -60 + [Bug 1165] config parser leak + logconfig keyword correction + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_data_structures.c@1.7 +5 -10 + C doesn't require casts from void *, emalloc doesn't return NULL + + ntpd/ntp_filegen.c@1.14 +8 -6 + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_parser.y@1.29.1.1 +10 -8 + [Bug 1165] config parser leak + + ntpd/ntp_scanner.c@1.19 +1 -1 + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_scanner.h@1.5 +1 -0 + DEBUG-only freeing of allocated memory at exit + + ntpd/ntp_util.c@1.68 +49 -12 + DEBUG-only freeing of allocated memory at exit + + ports/winnt/include/config.h@1.62 +10 -1 + Windows CRT leak debugging enhanced + + ports/winnt/libisc/isc_strerror.c@1.7 +137 -31 + ensure NULL termination of error messages + quiet compiler warnings + + ports/winnt/libntp/randfile.c@1.4 +1 -6 + quiet compiler warnings by including config.h + + ports/winnt/ntpd/ntservice.c@1.15 +22 -7 + DEBUG-only freeing of allocated memory at exit + +ChangeSet@1.1807.1.2, 2009-04-25 00:34:16-04:00, stenn@whimsy.udel.edu + PPS and crypto cleanup in ntp_proto.c from Dave Mills + + ChangeLog@1.280.1.1 +1 -0 + PPS and crypto cleanup in ntp_proto.c from Dave Mills + + ntpd/ntp_proto.c@1.281 +3 -3 + PPS and crypto cleanup in ntp_proto.c from Dave Mills + +ChangeSet@1.1812, 2009-04-24 00:01:08+00:00, davehart@shiny.ad.hartbrothers.com + bison-generated files from ntp_parser.y for [Bug 1161] + + ntpd/ntp_parser.c@1.35 +949 -914 + bison-generated files from ntp_parser.y + + ntpd/ntp_parser.h@1.19 +39 -35 + bison-generated files from ntp_parser.y + +ChangeSet@1.1811, 2009-04-23 23:58:33+00:00, davehart@shiny.ad.hartbrothers.com + Many files: + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + ChangeLog@1.282 +1 -0 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + include/ntp_config.h@1.50 +6 -0 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + ntpd/ntp_config.c@1.189 +104 -8 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + + ntpd/ntp_parser.y@1.30 +23 -1 + [Bug 1161] unpeer AKA unconfig command for ntpq :config + +ChangeSet@1.1809, 2009-04-23 19:45:43+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + [Bug 1057] ntpdc unconfig failure + + ChangeLog@1.279.1.1 +1 -0 + [Bug 1057] ntpdc unconfig failure + +ChangeSet@1.1807.1.1, 2009-04-23 08:03:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P165 + TAG: NTP_4_2_5P165 + + ChangeLog@1.280 +1 -0 + NTP_4_2_5P165 + + gsoc_sntp/sntp-opts.c@1.26 +2 -2 + NTP_4_2_5P165 + + gsoc_sntp/sntp-opts.h@1.26 +3 -3 + NTP_4_2_5P165 + + gsoc_sntp/sntp-opts.texi@1.26 +1 -1 + NTP_4_2_5P165 + + gsoc_sntp/sntp.1@1.26 +2 -2 + NTP_4_2_5P165 + + ntpd/ntpd-opts.c@1.157 +2 -2 + NTP_4_2_5P165 + + ntpd/ntpd-opts.h@1.157 +3 -3 + NTP_4_2_5P165 + + ntpd/ntpd-opts.texi@1.156 +1 -1 + NTP_4_2_5P165 + + ntpd/ntpd.1@1.156 +2 -2 + NTP_4_2_5P165 + + ntpdc/ntpdc-opts.c@1.153 +2 -2 + NTP_4_2_5P165 + + ntpdc/ntpdc-opts.h@1.153 +3 -3 + NTP_4_2_5P165 + + ntpdc/ntpdc-opts.texi@1.152 +1 -1 + NTP_4_2_5P165 + + ntpdc/ntpdc.1@1.152 +2 -2 + NTP_4_2_5P165 + + ntpq/ntpq-opts.c@1.153 +2 -2 + NTP_4_2_5P165 + + ntpq/ntpq-opts.h@1.153 +3 -3 + NTP_4_2_5P165 + + ntpq/ntpq-opts.texi@1.152 +1 -1 + NTP_4_2_5P165 + + ntpq/ntpq.1@1.152 +2 -2 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd-opts.c@1.34 +2 -2 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd-opts.h@1.34 +3 -3 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd-opts.texi@1.34 +1 -1 + NTP_4_2_5P165 + + ntpsnmpd/ntpsnmpd.1@1.34 +2 -2 + NTP_4_2_5P165 + + packageinfo.sh@1.168 +1 -1 + NTP_4_2_5P165 + + sntp/sntp-opts.c@1.153 +2 -2 + NTP_4_2_5P165 + + sntp/sntp-opts.h@1.153 +3 -3 + NTP_4_2_5P165 + + sntp/sntp-opts.texi@1.152 +1 -1 + NTP_4_2_5P165 + + sntp/sntp.1@1.152 +2 -2 + NTP_4_2_5P165 + + util/ntp-keygen-opts.c@1.156 +2 -2 + NTP_4_2_5P165 + + util/ntp-keygen-opts.h@1.156 +3 -3 + NTP_4_2_5P165 + + util/ntp-keygen-opts.texi@1.155 +1 -1 + NTP_4_2_5P165 + + util/ntp-keygen.1@1.155 +2 -2 + NTP_4_2_5P165 + +ChangeSet@1.1808, 2009-04-23 11:51:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1057] partial fix, re-enable ntpdc unconfig + + include/ntpd.h@1.122 +2 -3 + [Bug 1057] partial fix, re-enable ntpdc unconfig + + ntpd/ntp_peer.c@1.116 +0 -15 + [Bug 1057] partial fix, re-enable ntpdc unconfig + + ntpd/ntp_request.c@1.77 +26 -16 + [Bug 1057] partial fix, re-enable ntpdc unconfig + +ChangeSet@1.1807, 2009-04-23 06:42:56-04:00, stenn@whimsy.udel.edu + WWVB refclock cleanup from Dave Mills + + ChangeLog@1.279 +1 -0 + WWVB refclock cleanup from Dave Mills + + ntpd/refclock_wwvb.c@1.21 +3 -3 + WWVB refclock cleanup from Dave Mills + +ChangeSet@1.1806, 2009-04-23 06:35:25-04:00, stenn@whimsy.udel.edu + Code cleanup: requested_key -> request_key + + ChangeLog@1.278 +1 -0 + Code cleanup: requested_key -> request_key + + include/ntp_config.h@1.49 +1 -1 + Code cleanup: requested_key -> request_key + + ntpd/ntp_config.c@1.188 +4 -4 + Code cleanup: requested_key -> request_key + + ntpd/ntp_parser.c@1.34 +5 -5 + Code cleanup: requested_key -> request_key + + ntpd/ntp_parser.h@1.18 +2 -2 + Code cleanup: requested_key -> request_key + + ntpd/ntp_parser.y@1.29 +1 -1 + Code cleanup: requested_key -> request_key + +ChangeSet@1.1801.1.6, 2009-04-23 08:23:49+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + belated ntp_parser.y malloc redeclaration entry + + ChangeLog@1.273.1.2 +1 -0 + belated ntp_parser.y malloc redeclaration entry + +ChangeSet@1.1801.1.5, 2009-04-23 08:18:08+00:00, hart@pogo.udel.edu + ntp_parser.c: + generated from updated ntp_parser.y by bison 2.3 + ntp_parser.h: + force a null delta to keep this file newer than ntp_parser.y + + ntpd/ntp_parser.c@1.33 +365 -355 + generated from updated ntp_parser.y by bison 2.3 + + ntpd/ntp_parser.h@1.17 +0 -0 + force a null delta to keep this file newer than ntp_parser.y + +ChangeSet@1.1801.1.4, 2009-04-23 08:08:30+00:00, davehart@shiny.ad.hartbrothers.com + ntp_parser.y: + quiet malloc redeclaration warning compiling ntp_parser.c + + ntpd/ntp_parser.y@1.28 +2 -0 + quiet malloc redeclaration warning compiling ntp_parser.c + +ChangeSet@1.1804, 2009-04-23 03:43:50-04:00, stenn@whimsy.udel.edu + cleanup + + ChangeLog@1.276 +2 -1 + cleanup + +ChangeSet@1.1801.1.3, 2009-04-23 07:31:41+00:00, davehart@shiny.ad.hartbrothers.com + allow OpenSSL DLLs' C runtime version to differ from ntpq's and ntpdc's + [Bug 833] ignore whitespace at end of remote configuration lines + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + + ChangeLog@1.273.1.1 +2 -0 + [Bug 833] ignore whitespace at end of remote configuration lines + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + + ntpd/ntp_scanner.c@1.18 +14 -3 + [Bug 833] ignore whitespace at end of remote configuration lines + + ntpdc/ntpdc.c@1.61 +7 -1 + allow OpenSSL DLLs' C runtime version to differ from ntpdc's + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + + ntpq/ntpq.c@1.82 +7 -1 + allow OpenSSL DLLs' C runtime version to differ from ntpq's + [Bug 1033] ntpdc/ntpq crash prompting for keyid on Windows + +ChangeSet@1.1801.1.2, 2009-04-23 07:04:18+00:00, davehart@shiny.ad.hartbrothers.com + ntp_scanner.c: + quiet type conversion warnings, do not push back EOF + + ntpd/ntp_scanner.c@1.17 +10 -11 + quiet type conversion warnings, do not push back EOF + +ChangeSet@1.1801.1.1, 2009-04-23 06:59:15+00:00, davehart@shiny.ad.hartbrothers.com + ntp_parser.y, ntp_scanner.c: + whitespace and indent cleanup only + + ntpd/ntp_parser.y@1.27 +516 -510 + whitespace and indent cleanup only + + ntpd/ntp_scanner.c@1.16 +47 -50 + whitespace and indent cleanup only + +ChangeSet@1.1796.12.31, 2009-04-22 18:33:43-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + html/drivers/driver22.html@1.18 +76 -27 + Documentation updates from Dave Mills + + html/drivers/driver4.html@1.14 +103 -60 + Documentation updates from Dave Mills + +ChangeSet@1.1796.12.30, 2009-04-22 18:26:09-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.268.11.16 +1 -0 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + + ntpd/ntp_proto.c@1.276.1.5 +2 -1 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_atom.c@1.59 +21 -11 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_wwvb.c@1.20 +30 -6 + Mitigation and PPS/PPSAPI cleanup from Dave Mills + +ChangeSet@1.1796.12.29, 2009-04-22 18:20:19-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.268.11.15 +1 -0 + Documentation updates from Dave Mills + + html/miscopt.html@1.42 +2 -2 + Documentation updates from Dave Mills + + html/prefer.html@1.20 +36 -11 + Documentation updates from Dave Mills + +ChangeSet@1.1796.12.28, 2009-04-22 18:14:48-04:00, stenn@whimsy.udel.edu + timepps-Solaris.h patches from Dave Hart + + ChangeLog@1.268.11.14 +1 -0 + timepps-Solaris.h patches from Dave Hart + + include/timepps-Solaris.h@1.5 +68 -19 + timepps-Solaris.h patches from Dave Hart + +ChangeSet@1.1796.12.27, 2009-04-22 10:38:59-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P164 + TAG: NTP_4_2_5P164 + + ChangeLog@1.268.11.13 +1 -0 + NTP_4_2_5P164 + + gsoc_sntp/sntp-opts.c@1.25 +2 -2 + NTP_4_2_5P164 + + gsoc_sntp/sntp-opts.h@1.25 +3 -3 + NTP_4_2_5P164 + + gsoc_sntp/sntp-opts.texi@1.25 +1 -1 + NTP_4_2_5P164 + + gsoc_sntp/sntp.1@1.25 +2 -2 + NTP_4_2_5P164 + + ntpd/ntpd-opts.c@1.156 +2 -2 + NTP_4_2_5P164 + + ntpd/ntpd-opts.h@1.156 +3 -3 + NTP_4_2_5P164 + + ntpd/ntpd-opts.texi@1.155 +2 -2 + NTP_4_2_5P164 + + ntpd/ntpd.1@1.155 +2 -2 + NTP_4_2_5P164 + + ntpdc/ntpdc-opts.c@1.152 +2 -2 + NTP_4_2_5P164 + + ntpdc/ntpdc-opts.h@1.152 +3 -3 + NTP_4_2_5P164 + + ntpdc/ntpdc-opts.texi@1.151 +2 -2 + NTP_4_2_5P164 + + ntpdc/ntpdc.1@1.151 +2 -2 + NTP_4_2_5P164 + + ntpq/ntpq-opts.c@1.152 +2 -2 + NTP_4_2_5P164 + + ntpq/ntpq-opts.h@1.152 +3 -3 + NTP_4_2_5P164 + + ntpq/ntpq-opts.texi@1.151 +2 -2 + NTP_4_2_5P164 + + ntpq/ntpq.1@1.151 +2 -2 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd-opts.c@1.33 +2 -2 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd-opts.h@1.33 +3 -3 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd-opts.texi@1.33 +1 -1 + NTP_4_2_5P164 + + ntpsnmpd/ntpsnmpd.1@1.33 +2 -2 + NTP_4_2_5P164 + + packageinfo.sh@1.167 +1 -1 + NTP_4_2_5P164 + + sntp/sntp-opts.c@1.152 +2 -2 + NTP_4_2_5P164 + + sntp/sntp-opts.h@1.152 +3 -3 + NTP_4_2_5P164 + + sntp/sntp-opts.texi@1.151 +1 -1 + NTP_4_2_5P164 + + sntp/sntp.1@1.151 +2 -2 + NTP_4_2_5P164 + + util/ntp-keygen-opts.c@1.155 +2 -2 + NTP_4_2_5P164 + + util/ntp-keygen-opts.h@1.155 +3 -3 + NTP_4_2_5P164 + + util/ntp-keygen-opts.texi@1.154 +2 -2 + NTP_4_2_5P164 + + util/ntp-keygen.1@1.154 +2 -2 + NTP_4_2_5P164 + +ChangeSet@1.1436.15.44, 2009-04-22 08:18:29-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P7_RC3 + TAG: NTP_4_2_4P7_RC3 + + ChangeLog@1.1.1.70 +1 -0 + NTP_4_2_4P7_RC3 + + ntpd/ntpd-opts.c@1.50.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpd-opts.h@1.50.20.1 +3 -3 + NTP_4_2_4P7_RC3 + + ntpd/ntpd-opts.texi@1.49.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpd.1@1.48.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim-opts.c@1.50.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim-opts.h@1.50.20.1 +3 -3 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim-opts.texi@1.48.20.1 +1 -1 + NTP_4_2_4P7_RC3 + + ntpd/ntpdsim.1@1.48.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc-opts.c@1.50.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc-opts.h@1.50.20.1 +3 -3 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc-opts.texi@1.48.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpdc/ntpdc.1@1.48.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpq/ntpq-opts.c@1.52.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpq/ntpq-opts.h@1.52.20.1 +3 -3 + NTP_4_2_4P7_RC3 + + ntpq/ntpq-opts.texi@1.49.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + ntpq/ntpq.1@1.48.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + packageinfo.sh@1.65.28.1 +1 -1 + NTP_4_2_4P7_RC3 + + sntp/sntp-opts.c@1.49.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + sntp/sntp-opts.h@1.49.20.1 +3 -3 + NTP_4_2_4P7_RC3 + + sntp/sntp-opts.texi@1.46.20.1 +1 -1 + NTP_4_2_4P7_RC3 + + sntp/sntp.1@1.49.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + util/ntp-keygen-opts.c@1.49.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + util/ntp-keygen-opts.h@1.49.20.1 +3 -3 + NTP_4_2_4P7_RC3 + + util/ntp-keygen-opts.texi@1.47.20.1 +2 -2 + NTP_4_2_4P7_RC3 + + util/ntp-keygen.1@1.47.20.1 +2 -2 + NTP_4_2_4P7_RC3 + +ChangeSet@1.1436.15.43, 2009-04-22 07:00:20-04:00, stenn@whimsy.udel.edu + [Bug 1155] Fix compile problem on Windows with VS2005 + + ChangeLog@1.1.1.69 +1 -0 + [Bug 1155] Fix compile problem on Windows with VS2005 + +ChangeSet@1.1436.15.42, 2009-04-22 06:06:53-04:00, stenn@whimsy.udel.edu + Cleanup + + ChangeLog@1.1.1.68 +4 -2 + Cleanup + +ChangeSet@1.1796.18.1, 2009-04-22 02:35:47-04:00, stenn@whimsy.udel.edu + PPS/PPSAPI cleanup from Dave Mills + + ChangeLog@1.268.16.2 +1 -0 + PPS/PPSAPI cleanup from Dave Mills + + ChangeLog@1.268.16.1 +1 -0 + Documentation updates from Dave Mills + + html/howto.html@1.21 +54 -41 + Documentation updates from Dave Mills + + html/prefer.html@1.19 +38 -31 + Documentation updates from Dave Mills + + include/Makefile.am@1.31 +1 -0 + PPS/PPSAPI cleanup from Dave Mills + + include/ntp.h@1.148.1.2 +2 -1 + PPS/PPSAPI cleanup from Dave Mills + + include/ntpd.h@1.118.2.1 +0 -1 + PPS/PPSAPI cleanup from Dave Mills + + include/refclock_atom.h@1.2 +1 -1 + PPS/PPSAPI cleanup from Dave Mills + + include/refclock_atom.h@1.1 +15 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/refclock_atom.h + + include/refclock_atom.h@1.0 +0 -0 + + ntpd/ntp_proto.c@1.276.1.4 +30 -31 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/ntp_refclock.c@1.82 +156 -0 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/ntp_request.c@1.76 +6 -0 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_atom.c@1.58 +38 -182 + PPS/PPSAPI cleanup from Dave Mills + + ntpd/refclock_wwvb.c@1.19 +30 -1 + PPS/PPSAPI cleanup from Dave Mills + +ChangeSet@1.1436.15.41, 2009-04-20 22:55:13+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + auto merge not quite right + + ChangeLog@1.1.1.67 +3 -7 + auto merge not quite right + +ChangeSet@1.1436.15.40, 2009-04-20 22:42:59+00:00, davehart@shiny.ad.hartbrothers.com + ntp_iocompletionport.c: + revert overlooked CreateEvent naming/sharing change not conditionalized away already + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.11 +2 -2 + revert overlooked CreateEvent naming/sharing change not conditionalized away already + +ChangeSet@1.1796.12.21, 2009-04-20 06:26:09+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + merge cleanup + + ChangeLog@1.268.11.7 +1 -3 + merge cleanup + +ChangeSet@1.1436.21.11, 2009-04-20 06:17:21+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + + ChangeLog@1.1.16.3 +1 -0 + [Bug 1160] Mac OS X is like BSD regarding F_SETOWN + +ChangeSet@1.1796.12.19, 2009-04-20 06:13:35+00:00, davehart@shiny.ad.hartbrothers.com + recvbuff.c: + ENSURE that get_free_recv_buffer_alloc does not return NULL + + libntp/recvbuff.c@1.29 +2 -0 + ENSURE that get_free_recv_buffer_alloc does not return NULL + +ChangeSet@1.1436.21.10, 2009-04-20 06:02:20+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + [Bug 1160] MacOS X is like BSD regarding F_SETOWN + + configure.ac@1.400.1.11 +3 -0 + [Bug 1160] MacOS X is like BSD regarding F_SETOWN + +ChangeSet@1.1796.17.1, 2009-04-19 17:50:29+00:00, davehart@shiny.ad.hartbrothers.com + ntp_intres.c, ntpd.h, ChangeLog, ntp_config.c: + [Bug 1125] C runtime per-thread initialization on Windows + + ChangeLog@1.268.15.1 +1 -0 + [Bug 1125] C runtime per-thread initialization on Windows + + include/ntpd.h@1.118.1.2 +3 -0 + [Bug 1125] C runtime per-thread initialization on Windows + + ntpd/ntp_config.c@1.184.1.2 +12 -11 + [Bug 1125] C runtime per-thread initialization on Windows + + ntpd/ntp_intres.c@1.58 +16 -1 + [Bug 1125] C runtime per-thread initialization on Windows + +ChangeSet@1.1796.16.3, 2009-04-18 14:23:56+00:00, davehart@shiny.ad.hartbrothers.com + ntpq.c: + fix false positive duplicate detection + + ntpq/ntpq.c@1.77.1.3 +9 -3 + fix false positive duplicate detection + +ChangeSet@1.1796.16.2, 2009-04-18 13:51:18+00:00, davehart@shiny.ad.hartbrothers.com + ntpq.c: + quiet gcc, msc type warnings from decodeint calls to [hex|oct]toint + + ntpq/ntpq.c@1.77.1.2 +2 -2 + quiet gcc, msc type warnings from decodeint calls to [hex|oct]toint + +ChangeSet@1.1796.16.1, 2009-04-18 04:46:01+00:00, davehart@shiny.ad.hartbrothers.com + ntpq.c, ChangeLog: + [Bug 1159] ntpq overlap diagnostic message test buggy + + ChangeLog@1.268.14.1 +1 -0 + [Bug 1159] ntpq overlap diagnostic message test buggy + + ntpq/ntpq.c@1.77.1.1 +303 -266 + [Bug 1159] ntpq overlap diagnostic message test buggy + +ChangeSet@1.1796.15.1, 2009-04-16 19:09:05+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + do not disable refclock_true (CLOCK_TRUETIME) due to pps_sample disappearance, relevant code is under CLOCK_PPS720 ifdef which only affects rare systems with pcl720.h present + + configure.ac@1.424.1.1 +0 -1 + do not disable refclock_true (CLOCK_TRUETIME) due to pps_sample disappearance, relevant code is under CLOCK_PPS720 ifdef which only affects rare systems with pcl720.h present + +ChangeSet@1.1796.12.12, 2009-04-16 09:00:55+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + revert too-long, incorrect option text change + + configure.ac@1.432 +1 -1 + revert too-long, incorrect option text change + +ChangeSet@1.1436.21.9, 2009-04-16 02:39:01+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + fix for --enable-ntp-signd=/my/path + + configure.ac@1.400.1.10 +1 -1 + fix for --enable-ntp-signd=/my/path + +ChangeSet@1.1436.21.8, 2009-04-15 12:36:24+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + do not cache options fix + + configure.ac@1.400.1.9 +1 -1 + do not cache options fix + +ChangeSet@1.1796.12.9, 2009-04-15 11:21:07+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + choosing compilers: use C99 if available, warn if C89 is not + + configure.ac@1.429 +19 -9 + choosing compilers: use C99 if available, warn if C89 is not + + gsoc_sntp/configure.ac@1.13 +15 -4 + choosing compilers: use C99 if available, warn if C89 is not + +ChangeSet@1.1436.21.7, 2009-04-15 10:43:51+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + Do not cache configure --options, only current values matter + Default --enable-wintime when --enable-ntp-signd + + configure.ac@1.400.1.8 +575 -403 + Do not cache configure --options, only current values matter + Default --enable-wintime when --enable-ntp-signd + +ChangeSet@1.1796.12.7, 2009-04-15 01:47:06+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + switch AC_CHECK_LIB to AC_SEARCH_LIBS for sockets to avoid occasional failure to use -lsocket + + gsoc_sntp/configure.ac@1.12 +4 -5 + switch AC_CHECK_LIB to AC_SEARCH_LIBS for sockets to avoid occasional failure to use -lsocket + +ChangeSet@1.1436.21.6, 2009-04-15 01:32:33+00:00, davehart@shiny.ad.hartbrothers.com + use AC_SEARCH_LIBS to avoid problems with sntp + + configure.ac@1.400.1.7 +12 -20 + use AC_SEARCH_LIBS in preference to AC_CHECK_LIB particulary for sockets, use AM_PROG_CC_C_O which supersets prior AC_PROG_CC_C_O + + sntp/configure.ac@1.15.1.2 +4 -4 + use AC_SEARCH_LIBS which is recommended particularly for sockets over the older AC_CHECK_LIB + +ChangeSet@1.1796.12.5, 2009-04-14 13:56:37+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + merge improvments from configure.ac into gsoc_sntp/configure.ac + + gsoc_sntp/configure.ac@1.11 +210 -108 + merge improvments from configure.ac into gsoc_sntp/configure.ac + +ChangeSet@1.1436.21.5, 2009-04-14 13:47:29+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + tear off sntp/configure.ac from configure.ac + + configure.ac@1.400.1.6 +6 -1 + tear off sntp/configure.ac from configure.ac + +ChangeSet@1.1436.15.38, 2009-04-14 07:55:41-04:00, mayer@pogo.udel.edu + Added fix for Bug 813 + + ChangeLog@1.1.1.65 +1 -0 + Added fix for Bug 813 + +ChangeSet@1.1436.15.37, 2009-04-14 07:51:41-04:00, mayer@pogo.udel.edu + [Bug 813] Conditional naming of Event + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.10 +7 -1 + [Bug 813] Conditional naming of Event + +ChangeSet@1.1796.14.1, 2009-04-14 09:31:17+00:00, davehart@shiny.ad.hartbrothers.com + ntpdc.c, ntpq.c: + remove duplicate #define closesocket, in .h now + ChangeLog, refclock_nmea.c: + [Bug 1153] refclock_nmea should not mix UTC with GPS time + + ChangeLog@1.268.13.1 +1 -0 + [Bug 1153] refclock_nmea should not mix UTC with GPS time + + ntpd/refclock_nmea.c@1.33 +41 -31 + [Bug 1153] refclock_nmea should not mix UTC with GPS time + + ntpdc/ntpdc.c@1.60 +0 -2 + remove duplicate #define closesocket, in .h now + + ntpq/ntpq.c@1.78 +0 -2 + remove duplicate #define closesocket, in .h now + +ChangeSet@1.1796.13.2, 2009-04-14 08:20:36+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + complete the merge from stable cleanup + + configure.ac@1.423.1.2 +63 -1 + complete the merge from stable cleanup + +ChangeSet@1.1436.21.4, 2009-04-14 05:21:17+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac: + use unset for tickadj utility test fix + + configure.ac@1.400.1.5 +1 -1 + use unset for tickadj utility test fix + +ChangeSet@1.1436.21.3, 2009-04-14 02:59:39+00:00, hart@pogo.udel.edu + build: + do not require nice + + build@1.26 +21 -4 + do not require nice + +ChangeSet@1.1436.21.2, 2009-04-14 01:33:01+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac, ChangeLog: + [Bug 1158] support for aix6.1 + + ChangeLog@1.1.16.2 +1 -0 + [Bug 1158] support for aix6.1 + + configure.ac@1.400.1.4 +8 -8 + [Bug 1158] support for aix6.1 + +ChangeSet@1.1436.21.1, 2009-04-14 01:28:08+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1157] quiet OpenSSL warnings, clean up configure.ac + make flock-build quit before causing harm if another has not completed + + + ChangeLog@1.1.16.1 +4 -0 + [Bug 1157] quiet OpenSSL warnings, clean up configure.ac + + build@1.25 +6 -7 + prevent multiple flock-builds from stepping on each others work + + configure.ac@1.400.1.3 +613 -361 + [Bug 1157] quiet OpenSSL warnings, configure.ac cleanup + + flock-build@1.39.1.1 +76 -20 + prevent multiple flock-builds from stepping on each others work + + sntp/configure.ac@1.15.1.1 +14 -0 + bring in line with -dev to ease merges, no functional change + +ChangeSet@1.1796.12.1, 2009-04-13 20:20:58+00:00, davehart@shiny.ad.hartbrothers.com + configure.ac, ChangeLog: + [Bug 1152] temporarily disable refclock_parse and refclock_true until maintainers repair pps_sample() build break + + ChangeLog@1.268.11.1 +2 -0 + [Bug 1152] temporarily disable refclock_parse and refclock_true until maintainers repair pps_sample() build break + + configure.ac@1.424 +5 -2 + [Bug 1152] temporarily disable refclock_parse and refclock_true until maintainers repair pps_sample() build break + +ChangeSet@1.1796.1.36, 2009-04-13 11:10:38-04:00, utterback@pogo.udel.edu + ChangeLog: + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + + ChangeLog@1.268.1.36 +1 -0 + [Bug 1154] mDNS registration should be done later, repeatedly and only if asked for. + +ChangeSet@1.1436.15.36, 2009-04-13 00:00:55-04:00, mayer@pogo.udel.edu + Forgot the _WIN32_WINNT update + + ports/winnt/include/config.h@1.46.1.5 +10 -23 + Forgot the _WIN32_WINNT update + +ChangeSet@1.1436.15.35, 2009-04-12 00:55:24-04:00, mayer@pogo.udel.edu + Windows bug fixes + + ChangeLog@1.1.1.64 +7 -2 + Windows bug fixes + +ChangeSet@1.1436.15.34, 2009-04-12 00:45:48-04:00, mayer@pogo.udel.edu + [Bug 1156] lock_thread_to_processor() should be declared in header + + ports/winnt/include/clockstuff.h@1.7.1.1 +1 -0 + [Bug 1156] lock_thread_to_processor() should be declared in header + + ports/winnt/ntpd/nt_clockstuff.c@1.23.1.2 +0 -1 + [Bug 1156] lock_thread_to_processor() should be declared in header + +ChangeSet@1.1436.15.33, 2009-04-12 00:38:47-04:00, mayer@pogo.udel.edu + [Bug 1147] System errors should be logged to msyslog() + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.9 +17 -14 + [Bug 1147] System errors should be logged to msyslog() + +ChangeSet@1.1436.15.32, 2009-04-12 00:34:41-04:00, mayer@pogo.udel.edu + [Bug 1155] Wrong header included in config.h. Should have been winsock2.h + + ports/winnt/include/config.h@1.46.1.4 +1 -2 + [Bug 1155] Wrong header included in config.h. Should have been winsock2.h + +ChangeSet@1.1436.15.31, 2009-04-12 00:32:25-04:00, mayer@pogo.udel.edu + [Bug 787] Bug fixes for 64-bit time_t on Windows + + ports/winnt/libntp/SetSystemTime.c@1.3.1.1 +2 -2 + [Bug 787] Bug fixes for 64-bit time_t on Windows + +ChangeSet@1.1796.1.35, 2009-04-10 07:56:46-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P163 + TAG: NTP_4_2_5P163 + + ChangeLog@1.268.1.35 +1 -0 + NTP_4_2_5P163 + + gsoc_sntp/sntp-opts.c@1.24 +2 -2 + NTP_4_2_5P163 + + gsoc_sntp/sntp-opts.h@1.24 +3 -3 + NTP_4_2_5P163 + + gsoc_sntp/sntp-opts.texi@1.24 +1 -1 + NTP_4_2_5P163 + + gsoc_sntp/sntp.1@1.24 +2 -2 + NTP_4_2_5P163 + + ntpd/ntpd-opts.c@1.155 +2 -2 + NTP_4_2_5P163 + + ntpd/ntpd-opts.h@1.155 +3 -3 + NTP_4_2_5P163 + + ntpd/ntpd-opts.texi@1.154 +1 -1 + NTP_4_2_5P163 + + ntpd/ntpd.1@1.154 +2 -2 + NTP_4_2_5P163 + + ntpdc/ntpdc-opts.c@1.151 +2 -2 + NTP_4_2_5P163 + + ntpdc/ntpdc-opts.h@1.151 +3 -3 + NTP_4_2_5P163 + + ntpdc/ntpdc-opts.texi@1.150 +1 -1 + NTP_4_2_5P163 + + ntpdc/ntpdc.1@1.150 +2 -2 + NTP_4_2_5P163 + + ntpq/ntpq-opts.c@1.151 +2 -2 + NTP_4_2_5P163 + + ntpq/ntpq-opts.h@1.151 +3 -3 + NTP_4_2_5P163 + + ntpq/ntpq-opts.texi@1.150 +1 -1 + NTP_4_2_5P163 + + ntpq/ntpq.1@1.150 +2 -2 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd-opts.c@1.32 +2 -2 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd-opts.h@1.32 +3 -3 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd-opts.texi@1.32 +1 -1 + NTP_4_2_5P163 + + ntpsnmpd/ntpsnmpd.1@1.32 +2 -2 + NTP_4_2_5P163 + + packageinfo.sh@1.166 +1 -1 + NTP_4_2_5P163 + + sntp/sntp-opts.c@1.151 +2 -2 + NTP_4_2_5P163 + + sntp/sntp-opts.h@1.151 +3 -3 + NTP_4_2_5P163 + + sntp/sntp-opts.texi@1.150 +1 -1 + NTP_4_2_5P163 + + sntp/sntp.1@1.150 +2 -2 + NTP_4_2_5P163 + + util/ntp-keygen-opts.c@1.154 +2 -2 + NTP_4_2_5P163 + + util/ntp-keygen-opts.h@1.154 +3 -3 + NTP_4_2_5P163 + + util/ntp-keygen-opts.texi@1.153 +1 -1 + NTP_4_2_5P163 + + util/ntp-keygen.1@1.153 +2 -2 + NTP_4_2_5P163 + +ChangeSet@1.1796.1.33, 2009-04-09 09:58:19-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P162 + TAG: NTP_4_2_5P162 + + ChangeLog@1.268.1.33 +1 -0 + NTP_4_2_5P162 + + gsoc_sntp/sntp-opts.c@1.23 +2 -2 + NTP_4_2_5P162 + + gsoc_sntp/sntp-opts.h@1.23 +3 -3 + NTP_4_2_5P162 + + gsoc_sntp/sntp-opts.texi@1.23 +1 -1 + NTP_4_2_5P162 + + gsoc_sntp/sntp.1@1.23 +2 -2 + NTP_4_2_5P162 + + ntpd/ntpd-opts.c@1.154 +2 -2 + NTP_4_2_5P162 + + ntpd/ntpd-opts.h@1.154 +3 -3 + NTP_4_2_5P162 + + ntpd/ntpd-opts.texi@1.153 +2 -2 + NTP_4_2_5P162 + + ntpd/ntpd.1@1.153 +2 -2 + NTP_4_2_5P162 + + ntpdc/ntpdc-opts.c@1.150 +2 -2 + NTP_4_2_5P162 + + ntpdc/ntpdc-opts.h@1.150 +3 -3 + NTP_4_2_5P162 + + ntpdc/ntpdc-opts.texi@1.149 +2 -2 + NTP_4_2_5P162 + + ntpdc/ntpdc.1@1.149 +2 -2 + NTP_4_2_5P162 + + ntpq/ntpq-opts.c@1.150 +2 -2 + NTP_4_2_5P162 + + ntpq/ntpq-opts.h@1.150 +3 -3 + NTP_4_2_5P162 + + ntpq/ntpq-opts.texi@1.149 +2 -2 + NTP_4_2_5P162 + + ntpq/ntpq.1@1.149 +2 -2 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd-opts.c@1.31 +2 -2 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd-opts.h@1.31 +3 -3 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd-opts.texi@1.31 +1 -1 + NTP_4_2_5P162 + + ntpsnmpd/ntpsnmpd.1@1.31 +2 -2 + NTP_4_2_5P162 + + packageinfo.sh@1.165 +1 -1 + NTP_4_2_5P162 + + sntp/sntp-opts.c@1.150 +2 -2 + NTP_4_2_5P162 + + sntp/sntp-opts.h@1.150 +3 -3 + NTP_4_2_5P162 + + sntp/sntp-opts.texi@1.149 +1 -1 + NTP_4_2_5P162 + + sntp/sntp.1@1.149 +2 -2 + NTP_4_2_5P162 + + util/ntp-keygen-opts.c@1.153 +2 -2 + NTP_4_2_5P162 + + util/ntp-keygen-opts.h@1.153 +3 -3 + NTP_4_2_5P162 + + util/ntp-keygen-opts.texi@1.152 +2 -2 + NTP_4_2_5P162 + + util/ntp-keygen.1@1.152 +2 -2 + NTP_4_2_5P162 + +ChangeSet@1.1436.15.30, 2009-04-09 07:44:06-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P7_RC2 + TAG: NTP_4_2_4P7_RC2 + + ChangeLog@1.1.1.63 +1 -0 + NTP_4_2_4P7_RC2 + + ntpd/ntpd-opts.c@1.50.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpd-opts.h@1.50.19.1 +3 -3 + NTP_4_2_4P7_RC2 + + ntpd/ntpd-opts.texi@1.49.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpd.1@1.48.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim-opts.c@1.50.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim-opts.h@1.50.19.1 +3 -3 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim-opts.texi@1.48.19.1 +1 -1 + NTP_4_2_4P7_RC2 + + ntpd/ntpdsim.1@1.48.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc-opts.c@1.50.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc-opts.h@1.50.19.1 +3 -3 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc-opts.texi@1.48.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpdc/ntpdc.1@1.48.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpq/ntpq-opts.c@1.52.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpq/ntpq-opts.h@1.52.19.1 +3 -3 + NTP_4_2_4P7_RC2 + + ntpq/ntpq-opts.texi@1.49.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + ntpq/ntpq.1@1.48.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + packageinfo.sh@1.65.27.1 +1 -1 + NTP_4_2_4P7_RC2 + + sntp/sntp-opts.c@1.49.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + sntp/sntp-opts.h@1.49.19.1 +3 -3 + NTP_4_2_4P7_RC2 + + sntp/sntp-opts.texi@1.46.19.1 +1 -1 + NTP_4_2_4P7_RC2 + + sntp/sntp.1@1.49.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + util/ntp-keygen-opts.c@1.49.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + util/ntp-keygen-opts.h@1.49.19.1 +3 -3 + NTP_4_2_4P7_RC2 + + util/ntp-keygen-opts.texi@1.47.19.1 +2 -2 + NTP_4_2_4P7_RC2 + + util/ntp-keygen.1@1.47.19.1 +2 -2 + NTP_4_2_4P7_RC2 + +ChangeSet@1.1796.11.2, 2009-04-09 04:49:27-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.268.10.2 +1 -0 + Documentation updates from Dave Mills + + html/comdex.html@1.2 +4 -2 + Documentation updates from Dave Mills + + html/decode.html@1.6 +5 -3 + Documentation updates from Dave Mills + + html/index.html@1.39 +4 -3 + Documentation updates from Dave Mills + + html/miscopt.html@1.41 +64 -54 + Documentation updates from Dave Mills + + html/monopt.html@1.29 +4 -2 + Documentation updates from Dave Mills + + html/prefer.html@1.18 +123 -58 + Documentation updates from Dave Mills + + html/sitemap.html@1.3 +5 -3 + Documentation updates from Dave Mills + +ChangeSet@1.1796.11.1, 2009-04-09 04:44:58-04:00, stenn@whimsy.udel.edu + Mitigation and PPS cleanup from Dave Mills + + ChangeLog@1.268.10.1 +4 -3 + Mitigation and PPS cleanup from Dave Mills + + include/ntpd.h@1.118.1.1 +1 -2 + Mitigation and PPS cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.148 +2 -6 + Mitigation and PPS cleanup from Dave Mills + + ntpd/ntp_proto.c@1.276.1.3 +170 -161 + Mitigation and PPS cleanup from Dave Mills + + ntpd/ntp_timer.c@1.49.1.1 +7 -1 + Mitigation and PPS cleanup from Dave Mills + + ntpd/refclock_atom.c@1.57 +24 -170 + Mitigation and PPS cleanup from Dave Mills + + ntpd/refclock_conf.c@1.27 +1 -1 + Mitigation and PPS cleanup from Dave Mills + + ntpd/refclock_local.c@1.19 +18 -34 + Mitigation and PPS cleanup from Dave Mills + +ChangeSet@1.1436.15.29, 2009-04-09 04:16:50-04:00, stenn@whimsy.udel.edu + ChangLog cleanup + + ChangeLog@1.1.1.62 +1 -0 + ChangLog cleanup + +ChangeSet@1.1436.15.28, 2009-04-09 04:13:41-04:00, stenn@whimsy.udel.edu + [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + + ChangeLog@1.1.1.61 +2 -0 + [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + + ntpq/ntpq.c@1.65.2.1 +2 -2 + [Sec 1144] limited buffer overflow in ntpq. CVE-2009-0159 + +ChangeSet@1.1796.10.2, 2009-04-07 09:37:52+00:00, davehart@shiny.ad.hartbrothers.com + libntp.vcproj: + add overlooked ntp_debug.h + + ports/winnt/libntp/libntp.vcproj@1.1.1.1 +4 -0 + add overlooked ntp_debug.h + +ChangeSet@1.1436.15.27, 2009-04-07 09:14:58+00:00, davehart@shiny.ad.hartbrothers.com + [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + + ChangeLog@1.1.1.60 +4 -0 + [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + + ntpd/ntp_io.c@1.244.2.15 +64 -31 + [Sec 1149] use setsockopt(SO_EXCLUSIVEADDRUSE) on Windows + + ports/winnt/libntp/libntp.vcproj@1.1.1.1 +4 -0 + add ntp_debug.h + +ChangeSet@1.1796.9.2, 2009-04-03 19:06:56+00:00, davehart@shiny.ad.hartbrothers.com + config.h, nt_clockstuff.c: + VC6 compatibility (thanks Martin!) + + ports/winnt/include/config.h@1.60 +2 -1 + VC6 compatibility (thanks Martin!) + + ports/winnt/ntpd/nt_clockstuff.c@1.27 +27 -16 + VC6 compatibility (thanks Martin!) + +ChangeSet@1.1796.9.1, 2009-04-03 03:49:05+00:00, davehart@shiny.ad.hartbrothers.com + new Windows interpolation knocks out 1ms jitter in previous + remove dead code + thin #ifdef SYS_WINNT forest + 64-bit time_t truncation fixes, warnings silenced + do not set hardware clock on exit unless system is shutting down + + BitKeeper/deleted/.del-ntpkeygen.vcproj@1.2 +0 -0 + Rename: ports/winnt/ntp-keygen/ntpkeygen.vcproj -> BitKeeper/deleted/.del-ntpkeygen.vcproj + + ChangeLog@1.268.8.1 +5 -0 + [Bug 216] new interpolation, reduce #ifdef SYS_WINNT, 64-bit time_t cleanup, only set Windows CMOS clock at ntpd exit if the computer is shutting down + + include/ntp_machine.h@1.25 +3 -46 + remove SYS_WINNT stuff (redundant with ports/winnt/config.h) + + include/ntp_stdlib.h@1.26 +0 -1 + remove dead humandate() code + + include/ntp_types.h@1.11 +18 -0 + UNUSED_ARG macro definition, used to quiet compiler warnings + --- + define sock_timeval for Windows 64-bit time_t compatibility + + include/ntp_unixtime.h@1.6 +0 -3 + remove dead code: tvtoa(), utvtoa() declarations + + libntp/Makefile.am@1.41 +2 -2 + remove dead tvtoa.c & utvtoa.c from libntp + + libntp/buftvtots.c@1.5 +18 -0 + Windows has no tty_clock discipline, don't look for timestamp in refclock recvbuff + + libntp/humandate.c@1.7 +1 -30 + remove dead humandate() code + + libntp/prettydate.c@1.11 +17 -27 + fix compiler warning with 64-bit time_t, fold duplicate code into common helper + + libntp/systime.c@1.47 +1 -1 + quiet compiler warning with 64-bit time_t + + ntpd/ntp_config.c@1.184.1.1 +6 -6 + quiet compiler warnings about storing int into u_short with casts + + ntpd/ntp_crypto.c@1.130 +1 -1 + quiet compiler warning with 64-bit time_t + + ntpd/ntp_intres.c@1.57 +1 -1 + struct sock_timeval for 64-bit time_t compatibility on Windows + + ntpd/ntp_timer.c@1.50 +0 -27 + remove redundant code, nt_clockstuff.c enables privs earlier + + ntpd/ntpd.c@1.100 +0 -4 + chop down some #ifdef forest + + ntpd/refclock_dumbclock.c@1.12 +1 -1 + 64-bit time_t compiler warning silenced + + ntpdate/ntpdate.c@1.65 +5 -18 + struct sock_timeval for 64-bit time_t compatibility on Windows, more #ifdef SYS_WINNT deforestation + + ntpdc/ntpdc.c@1.59 +4 -16 + struct sock_timeval for 64-bit time_t compatibility on Windows + + ntpq/ntpq.c@1.76 +5 -5 + struct sock_timeval for 64-bit time_t compatibility on Windows + + ports/winnt/include/clockstuff.h@1.8 +32 -7 + new interpolation scheme knocks out 1ms jitter inherent in previous + + ports/winnt/include/config.h@1.59 +27 -5 + struct sock_timeval for 64-bit time_t compatibility on Windows, more #ifdef SYS_WINNT deforestation + + ports/winnt/include/ntservice.h@1.3 +2 -1 + expose ntservice_systemisshuttingdown(), fix calling convention mismatch + + ports/winnt/include/sys/resource.h@1.4 +10 -4 + emulate BSD setpriority() to reduce #ifdef SYS_WINNT + + ports/winnt/include/sys/time.h@1.5 +14 -6 + new interpolation scheme knocks out 1ms jitter inherent in previous + + ports/winnt/libntp/SetSystemTime.c@1.5 +18 -16 + new interpolation scheme knocks out 1ms jitter inherent in previous + do not mix C runtime and Windows Gregorian calendar routines + + ports/winnt/libntp/getclock.c@1.1 +49 -0 + emulate BSD getclock() interface + + ports/winnt/libntp/getclock.c@1.0 +0 -0 + + ports/winnt/libntp/libntp.dsp@1.33 +8 -0 + add getclock.c setpriority.c + + ports/winnt/libntp/libntp.vcproj@1.2 +13 -59 + remove dead tvtoa.c & utvtoa.c from libntp, add getclock.c setpriority.c and util_clockstuff.c + + ports/winnt/libntp/randfile.c@1.3 +3 -2 + buffer overrun protection + + ports/winnt/libntp/setpriority.c@1.1 +79 -0 + emulate BSD setpriority() to thin #ifdef forest in ntpd.c + + ports/winnt/libntp/setpriority.c@1.0 +0 -0 + + ports/winnt/libntp/syslog.c@1.4 +2 -1 + use strncpy instead of strcpy, force null termination as Windows strncpy doesn't when buffer exceeded + + ports/winnt/libntp/util_clockstuff.c@1.4 +9 -17 + no longer conflicts with ports/winnt/ntpd/nt_clockstuff.c, can be added to libntp library. + + ports/winnt/ntp-keygen/ntp-keygen.vcproj@1.2 +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/ntpd/nt_clockstuff.c@1.26 +1180 -332 + new interpolation scheme knocks out 1ms jitter inherent in previous + + ports/winnt/ntpd/ntp_iocompletionport.c@1.40 +3 -5 + move lock_thread_to_processor prototype to clockstuff.h + + ports/winnt/ntpd/ntservice.c@1.14 +52 -41 + ntservice_systemisshuttingdown(), fix mismatched calling convention, remove erroneous SetServiceStatus calls, eliminate unreachable code warning by removing exit() calls from main() + + ports/winnt/ntpd/win32_io.c@1.15 +0 -12 + emulate BSD setpriority() to reduce #ifdef SYS_WINNT + + ports/winnt/ntpdate/ntpdate.vcproj@1.2 +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/ntpdc/ntpdc.vcproj@1.2 +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/ntpq/ntpq.vcproj@1.2 +0 -22 + remove util_clockstuff.c from individual projects, it's now in libntp library + + ports/winnt/scripts/mkver.bat@1.10 +4 -4 + fix VC++ 2008 parallel build collision on %TEMP%\TZ.TMP by using a different filename for each program + + util/ntp-keygen.c@1.54 +1 -4 + remove #ifdef SYS_WINNT, gettimeofday() prototype on Windows now matches Unix + +ChangeSet@1.1796.8.2, 2009-04-01 01:13:42+00:00, davehart@shiny.ad.hartbrothers.com + bk gone the former gsoc_sntp/utilities.o so that all .o files can be removed without corrupting the repo + + BitKeeper/etc/gone@1.9 +1 -0 + bk gone the former gsoc_sntp/utilities.o so that all .o files can be removed without corrupting the repo + + ChangeLog@1.268.7.2 +2 -0 + bk gone the former gsoc_sntp/utilities.o so that all .o files can be removed without corrupting the repo + +ChangeSet@1.1796.8.1, 2009-03-31 06:56:41-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P161 + TAG: NTP_4_2_5P161 + + ChangeLog@1.268.7.1 +1 -0 + NTP_4_2_5P161 + + gsoc_sntp/sntp-opts.c@1.22 +2 -2 + NTP_4_2_5P161 + + gsoc_sntp/sntp-opts.h@1.22 +3 -3 + NTP_4_2_5P161 + + gsoc_sntp/sntp-opts.texi@1.22 +1 -1 + NTP_4_2_5P161 + + gsoc_sntp/sntp.1@1.22 +2 -2 + NTP_4_2_5P161 + + ntpd/ntpd-opts.c@1.153 +2 -2 + NTP_4_2_5P161 + + ntpd/ntpd-opts.h@1.153 +3 -3 + NTP_4_2_5P161 + + ntpd/ntpd-opts.texi@1.152 +1 -1 + NTP_4_2_5P161 + + ntpd/ntpd.1@1.152 +2 -2 + NTP_4_2_5P161 + + ntpdc/ntpdc-opts.c@1.149 +2 -2 + NTP_4_2_5P161 + + ntpdc/ntpdc-opts.h@1.149 +3 -3 + NTP_4_2_5P161 + + ntpdc/ntpdc-opts.texi@1.148 +1 -1 + NTP_4_2_5P161 + + ntpdc/ntpdc.1@1.148 +2 -2 + NTP_4_2_5P161 + + ntpq/ntpq-opts.c@1.149 +2 -2 + NTP_4_2_5P161 + + ntpq/ntpq-opts.h@1.149 +3 -3 + NTP_4_2_5P161 + + ntpq/ntpq-opts.texi@1.148 +1 -1 + NTP_4_2_5P161 + + ntpq/ntpq.1@1.148 +2 -2 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd-opts.c@1.30 +2 -2 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd-opts.h@1.30 +3 -3 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd-opts.texi@1.30 +1 -1 + NTP_4_2_5P161 + + ntpsnmpd/ntpsnmpd.1@1.30 +2 -2 + NTP_4_2_5P161 + + packageinfo.sh@1.164 +1 -1 + NTP_4_2_5P161 + + sntp/sntp-opts.c@1.149 +2 -2 + NTP_4_2_5P161 + + sntp/sntp-opts.h@1.149 +3 -3 + NTP_4_2_5P161 + + sntp/sntp-opts.texi@1.148 +1 -1 + NTP_4_2_5P161 + + sntp/sntp.1@1.148 +2 -2 + NTP_4_2_5P161 + + util/ntp-keygen-opts.c@1.152 +2 -2 + NTP_4_2_5P161 + + util/ntp-keygen-opts.h@1.152 +3 -3 + NTP_4_2_5P161 + + util/ntp-keygen-opts.texi@1.151 +1 -1 + NTP_4_2_5P161 + + util/ntp-keygen.1@1.151 +2 -2 + NTP_4_2_5P161 + +ChangeSet@1.1796.1.28, 2009-03-31 09:33:53+00:00, davehart@shiny.ad.hartbrothers.com + refclock_nmea.c: + [Bug 1148] NMEA reference clock improvements + + ChangeLog@1.268.1.28 +1 -0 + [Bug 1148] NMEA reference clock improvements + + ntpd/refclock_nmea.c@1.32 +377 -222 + [Bug 1148] NMEA reference clock improvements + +ChangeSet@1.1796.1.27, 2009-03-30 14:44:58-05:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.268.1.27 +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.44 +194 -89 + Documentation updates from Dave Mills + + html/ntpq.html@1.31 +23 -6 + Documentation updates from Dave Mills + +ChangeSet@1.1796.1.25, 2009-03-30 09:06:35-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P160 + TAG: NTP_4_2_5P160 + + ChangeLog@1.268.1.25 +1 -0 + NTP_4_2_5P160 + + gsoc_sntp/sntp-opts.c@1.21 +2 -2 + NTP_4_2_5P160 + + gsoc_sntp/sntp-opts.h@1.21 +3 -3 + NTP_4_2_5P160 + + gsoc_sntp/sntp-opts.texi@1.21 +1 -1 + NTP_4_2_5P160 + + gsoc_sntp/sntp.1@1.21 +2 -2 + NTP_4_2_5P160 + + ntpd/ntpd-opts.c@1.152 +2 -2 + NTP_4_2_5P160 + + ntpd/ntpd-opts.h@1.152 +3 -3 + NTP_4_2_5P160 + + ntpd/ntpd-opts.texi@1.151 +1 -1 + NTP_4_2_5P160 + + ntpd/ntpd.1@1.151 +2 -2 + NTP_4_2_5P160 + + ntpdc/ntpdc-opts.c@1.148 +2 -2 + NTP_4_2_5P160 + + ntpdc/ntpdc-opts.h@1.148 +3 -3 + NTP_4_2_5P160 + + ntpdc/ntpdc-opts.texi@1.147 +1 -1 + NTP_4_2_5P160 + + ntpdc/ntpdc.1@1.147 +2 -2 + NTP_4_2_5P160 + + ntpq/ntpq-opts.c@1.148 +2 -2 + NTP_4_2_5P160 + + ntpq/ntpq-opts.h@1.148 +3 -3 + NTP_4_2_5P160 + + ntpq/ntpq-opts.texi@1.147 +1 -1 + NTP_4_2_5P160 + + ntpq/ntpq.1@1.147 +2 -2 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd-opts.c@1.29 +2 -2 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd-opts.h@1.29 +3 -3 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd-opts.texi@1.29 +1 -1 + NTP_4_2_5P160 + + ntpsnmpd/ntpsnmpd.1@1.29 +2 -2 + NTP_4_2_5P160 + + packageinfo.sh@1.163 +1 -1 + NTP_4_2_5P160 + + sntp/sntp-opts.c@1.148 +2 -2 + NTP_4_2_5P160 + + sntp/sntp-opts.h@1.148 +3 -3 + NTP_4_2_5P160 + + sntp/sntp-opts.texi@1.147 +1 -1 + NTP_4_2_5P160 + + sntp/sntp.1@1.147 +2 -2 + NTP_4_2_5P160 + + util/ntp-keygen-opts.c@1.151 +2 -2 + NTP_4_2_5P160 + + util/ntp-keygen-opts.h@1.151 +3 -3 + NTP_4_2_5P160 + + util/ntp-keygen-opts.texi@1.150 +1 -1 + NTP_4_2_5P160 + + util/ntp-keygen.1@1.150 +2 -2 + NTP_4_2_5P160 + +ChangeSet@1.1436.15.26, 2009-03-30 06:47:41-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P7_RC1 + TAG: NTP_4_2_4P7_RC1 + + ChangeLog@1.1.1.59 +1 -0 + NTP_4_2_4P7_RC1 + + ntpd/ntpd-opts.c@1.50.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpd-opts.h@1.50.18.1 +3 -3 + NTP_4_2_4P7_RC1 + + ntpd/ntpd-opts.texi@1.49.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpd.1@1.48.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim-opts.c@1.50.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim-opts.h@1.50.18.1 +3 -3 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim-opts.texi@1.48.18.1 +1 -1 + NTP_4_2_4P7_RC1 + + ntpd/ntpdsim.1@1.48.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc-opts.c@1.50.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc-opts.h@1.50.18.1 +3 -3 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc-opts.texi@1.48.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpdc/ntpdc.1@1.48.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpq/ntpq-opts.c@1.52.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpq/ntpq-opts.h@1.52.18.1 +3 -3 + NTP_4_2_4P7_RC1 + + ntpq/ntpq-opts.texi@1.49.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + ntpq/ntpq.1@1.48.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + packageinfo.sh@1.65.26.1 +2 -2 + NTP_4_2_4P7_RC1 + + sntp/sntp-opts.c@1.49.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + sntp/sntp-opts.h@1.49.18.1 +3 -3 + NTP_4_2_4P7_RC1 + + sntp/sntp-opts.texi@1.46.18.1 +1 -1 + NTP_4_2_4P7_RC1 + + sntp/sntp.1@1.49.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + util/ntp-keygen-opts.c@1.49.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + util/ntp-keygen-opts.h@1.49.18.1 +3 -3 + NTP_4_2_4P7_RC1 + + util/ntp-keygen-opts.texi@1.47.18.1 +2 -2 + NTP_4_2_4P7_RC1 + + util/ntp-keygen.1@1.47.18.1 +2 -2 + NTP_4_2_4P7_RC1 + +ChangeSet@1.1436.15.25, 2009-03-30 02:31:49-05:00, stenn@whimsy.udel.edu + Release Candidate + + packageinfo.sh@1.65.25.1 +1 -1 + Release Candidate + +ChangeSet@1.1796.7.2, 2009-03-28 06:55:26-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P159 + TAG: NTP_4_2_5P159 + + ChangeLog@1.268.6.2 +1 -0 + NTP_4_2_5P159 + + gsoc_sntp/sntp-opts.c@1.20 +2 -2 + NTP_4_2_5P159 + + gsoc_sntp/sntp-opts.h@1.20 +3 -3 + NTP_4_2_5P159 + + gsoc_sntp/sntp-opts.texi@1.20 +1 -1 + NTP_4_2_5P159 + + gsoc_sntp/sntp.1@1.20 +2 -2 + NTP_4_2_5P159 + + ntpd/ntpd-opts.c@1.151 +2 -2 + NTP_4_2_5P159 + + ntpd/ntpd-opts.h@1.151 +3 -3 + NTP_4_2_5P159 + + ntpd/ntpd-opts.texi@1.150 +2 -2 + NTP_4_2_5P159 + + ntpd/ntpd.1@1.150 +2 -2 + NTP_4_2_5P159 + + ntpdc/ntpdc-opts.c@1.147 +2 -2 + NTP_4_2_5P159 + + ntpdc/ntpdc-opts.h@1.147 +3 -3 + NTP_4_2_5P159 + + ntpdc/ntpdc-opts.texi@1.146 +2 -2 + NTP_4_2_5P159 + + ntpdc/ntpdc.1@1.146 +2 -2 + NTP_4_2_5P159 + + ntpq/ntpq-opts.c@1.147 +2 -2 + NTP_4_2_5P159 + + ntpq/ntpq-opts.h@1.147 +3 -3 + NTP_4_2_5P159 + + ntpq/ntpq-opts.texi@1.146 +2 -2 + NTP_4_2_5P159 + + ntpq/ntpq.1@1.146 +2 -2 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd-opts.c@1.28 +2 -2 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd-opts.h@1.28 +3 -3 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd-opts.texi@1.28 +1 -1 + NTP_4_2_5P159 + + ntpsnmpd/ntpsnmpd.1@1.28 +2 -2 + NTP_4_2_5P159 + + packageinfo.sh@1.162 +1 -1 + NTP_4_2_5P159 + + sntp/sntp-opts.c@1.147 +2 -2 + NTP_4_2_5P159 + + sntp/sntp-opts.h@1.147 +3 -3 + NTP_4_2_5P159 + + sntp/sntp-opts.texi@1.146 +1 -1 + NTP_4_2_5P159 + + sntp/sntp.1@1.146 +2 -2 + NTP_4_2_5P159 + + util/ntp-keygen-opts.c@1.150 +2 -2 + NTP_4_2_5P159 + + util/ntp-keygen-opts.h@1.150 +3 -3 + NTP_4_2_5P159 + + util/ntp-keygen-opts.texi@1.149 +2 -2 + NTP_4_2_5P159 + + util/ntp-keygen.1@1.149 +2 -2 + NTP_4_2_5P159 + +ChangeSet@1.1436.15.23, 2009-03-28 02:46:45-05:00, stenn@whimsy.udel.edu + build system email address cleanup + + BitKeeper/triggers/changelog@1.4 +1 -1 + trigger email address cleanup + + BitKeeper/triggers/commitlogs@1.6 +1 -1 + trigger email address cleanup + + BitKeeper/triggers/delta-changelog@1.8 +2 -2 + trigger email address cleanup + + BitKeeper/triggers/notify@1.4 +1 -1 + trigger email address cleanup + + BitKeeper/triggers/paranoid@1.4 +1 -1 + trigger email address cleanup + + BitKeeper/triggers/post-incoming.license-warn@1.7 +1 -1 + trigger email address cleanup + + BitKeeper/triggers/pre-resolve.licfix@1.4 +1 -1 + trigger email address cleanup + + BitKeeper/triggers/send@1.14 +2 -2 + trigger email address cleanup + + ChangeLog@1.1.1.57 +3 -1 + build system email address cleanup + +ChangeSet@1.1796.7.1, 2009-03-28 02:14:41-05:00, stenn@whimsy.udel.edu + "bias" changes from Dave Mills + + ChangeLog@1.268.6.1 +1 -0 + "bias" changes from Dave Mills + + include/ntp.h@1.148.1.1 +2 -1 + "bias" changes from Dave Mills + + include/ntp_control.h@1.34 +9 -8 + "bias" changes from Dave Mills + + ntpd/ntp_control.c@1.108 +18 -10 + "bias" changes from Dave Mills + + ntpd/ntp_crypto.c@1.129 +13 -11 + "bias" changes from Dave Mills + + ntpd/ntp_proto.c@1.276.1.2 +69 -92 + "bias" changes from Dave Mills + +ChangeSet@1.1796.1.21, 2009-03-28 05:37:50+00:00, davehart@shiny.ad.hartbrothers.com + ntp_refclock.c, ChangeLog: + [Bug 1141] refclock_report missing braces cause spurious 'peer event: clock clk_unspec' log entries + + ChangeLog@1.268.1.21 +8 -5 + [Bug 1141] refclock_report missing braces cause spurious 'peer event: clock clk_unspec' log entries + + ntpd/ntp_refclock.c@1.81 +2 -1 + [Bug 1141] refclock_report missing braces cause spurious 'peer event: clock clk_unspec' log entries + +ChangeSet@1.1796.1.20, 2009-03-24 15:23:07+00:00, davehart@shiny.ad.hartbrothers.com + config.h: + include winsock.h before ws2tcpip.h to fix VS 2005 build + + ports/winnt/include/config.h@1.57 +8 -5 + include winsock.h before ws2tcpip.h to fix VS 2005 build + +ChangeSet@1.1436.15.22, 2009-03-24 15:22:36+00:00, davehart@shiny.ad.hartbrothers.com + config.h: + include winsock.h before ws2tcpip.h to fix VS 2005 build + + ports/winnt/include/config.h@1.46.1.3 +8 -5 + include winsock.h before ws2tcpip.h to fix VS 2005 build + +ChangeSet@1.1436.20.2, 2009-03-24 15:14:36+00:00, davehart@shiny.ad.hartbrothers.com + ntp_iocompletionport.c: + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.2.2 +10 -1 + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + +ChangeSet@1.1796.6.2, 2009-03-24 15:04:27+00:00, davehart@shiny.ad.hartbrothers.com + ntp_iocompletionport.c: + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + + ports/winnt/ntpd/ntp_iocompletionport.c@1.35.1.2 +10 -1 + use one receive per socket to avoid Win2000 afd.sys bugcheck 0x76 + +ChangeSet@1.1436.15.20, 2009-03-22 21:09:43+00:00, davehart@shiny.ad.hartbrothers.com + Makefile.am, ChangeLog: + [Bug 774] parsesolaris.c does not compile under the new Solaris + + ChangeLog@1.1.1.56 +1 -0 + [Bug 774] parsesolaris.c does not compile under the new Solaris + + libparse/Makefile.am@1.8.1.1 +1 -1 + [Bug 774] parsesolaris.c does not compile under the new Solaris + +ChangeSet@1.1436.15.19, 2009-03-20 03:39:26+00:00, hart@pogo.udel.edu + ChangeLog: + bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + + ChangeLog@1.1.1.55 +0 -2 + bk for windows isn't converting line endings correctly, remove two blank lines visible only on Unix side + +ChangeSet@1.1796.1.18, 2009-03-20 03:34:09+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + I'm learning + add DPRINTF line omitted accidentally + + ChangeLog@1.268.1.20 +1 -1 + add DPRINTF line omitted accidentally + + ChangeLog@1.268.1.19 +2 -0 + I'm learning + +ChangeSet@1.1436.15.16, 2009-03-20 03:10:22+00:00, davehart@shiny.ad.hartbrothers.com + ChangeLog: + remove blank first line + + ChangeLog@1.1.1.52 +0 -1 + remove blank first line + +ChangeSet@1.1436.20.1, 2009-03-20 01:46:15+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ChangeLog@1.1.15.1 +2 -0 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/ntp_io.c@1.244.3.1 +26 -23 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/ntpd.c@1.82.2.4 +14 -25 + slightly reduce #ifdef SYS_WINNT forest + + ntpd/refclock_dumbclock.c@1.8.1.1 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_hopfser.c@1.9.1.1 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_nmea.c@1.25.1.1 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_palisade.c@1.18.1.1 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/include/ntp_iocompletionport.h@1.13.1.1 +8 -9 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.2.1 +331 -249 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/win32_io.c@1.12.1.1 +172 -66 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + +ChangeSet@1.1796.6.1, 2009-03-20 01:31:56+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 873] Windows serial refclock proper TTY line discipline emulation + --- + Merge shiny.ad.hartbrothers.com:c:\ntp\ntp-stable-873 + into shiny.ad.hartbrothers.com:C:/ntp/ntp-dev-873 + + ChangeLog@1.268.5.1 +1 -0 [Bug 873] Windows serial refclock proper TTY line discipline emulation + + + ntpd/ntp_io.c@1.275.1.1 +25 -22 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + + ntpd/ntpd.c@1.98 +17 -29 + slightly reduce #ifdef SYS_WINNT forest + + + ntpd/refclock_dumbclock.c@1.10 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_hopfser.c@1.11 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_nmea.c@1.30 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ntpd/refclock_palisade.c@1.22 +6 -5 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + + ports/winnt/include/ntp_iocompletionport.h@1.15 +8 -9 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/ntp_iocompletionport.c@1.35.1.1 +335 -255 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + + ports/winnt/ntpd/win32_io.c@1.13 +172 -66 + [Bug 873] Windows serial refclock proper TTY line discipline emulation + +ChangeSet@1.1436.19.2, 2009-03-18 11:44:59+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + + ChangeLog@1.1.14.1 +2 -0 + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + +ChangeSet@1.1796.5.2, 2009-03-18 11:42:38+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + + ChangeLog@1.268.4.1 +1 -0 + [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + +ChangeSet@1.1436.17.4, 2009-03-18 10:14:52+00:00, davehart@shiny.ad.hartbrothers.com + [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + + ChangeLog@1.1.12.3 +2 -0 + [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + +ChangeSet@1.1796.5.1, 2009-03-17 19:21:10+00:00, davehart@shiny.ad.hartbrothers.com + [bug 1014] compile on VC9 AKA VC++ 2008 EE AKA VS 2008 + + ports/winnt/instsrv/instsrv.vcproj@1.1 +253 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/instsrv/instsrv.vcproj@1.0 +0 -0 + + ports/winnt/libntp/libntp.vcproj@1.1 +2211 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/libntp/libntp.vcproj@1.0 +0 -0 + + ports/winnt/ntp-keygen/ntp-keygen.vcproj@1.1 +419 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntp-keygen/ntp-keygen.vcproj@1.0 +0 -0 + + ports/winnt/ntp.sln@1.2 +1 -1 + [bug 1014] VC9 equivalent to ntp.dsw (checkin comment only change) + + ports/winnt/ntp.sln@1.1 +71 -0 + BitKeeper file C:/ntp/ntp-dev-1014/ports/winnt/ntp.sln + + ports/winnt/ntp.sln@1.0 +0 -0 + + ports/winnt/ntpd/ntpd.vcproj@1.1 +2218 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpd/ntpd.vcproj@1.0 +0 -0 + + ports/winnt/ntpdate/ntpdate.vcproj@1.1 +327 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpdate/ntpdate.vcproj@1.0 +0 -0 + + ports/winnt/ntpdc/ntpdc.vcproj@1.1 +376 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpdc/ntpdc.vcproj@1.0 +0 -0 + + ports/winnt/ntpq/ntpq.vcproj@1.1 +370 -0 + [bug 1014] VC9 equivalent to .dsp + + ports/winnt/ntpq/ntpq.vcproj@1.0 +0 -0 + +ChangeSet@1.1436.19.1, 2009-03-17 18:39:09+00:00, davehart@shiny.ad.hartbrothers.com + add .sln and .vcproj files for VC9 + + ports/winnt/instsrv/Instsrv.vcproj@1.1 +253 -0 + VC9 equivalent to Instsrv.dsp + + ports/winnt/instsrv/Instsrv.vcproj@1.0 +0 -0 + + ports/winnt/libntp/libntp.vcproj@1.1 +2229 -0 + VC9 equivalent to libntp.dsp + + ports/winnt/libntp/libntp.vcproj@1.0 +0 -0 + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.1 +419 -0 + VC9 equivalent to ntpkeygen.dsp + + ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.0 +0 -0 + + ports/winnt/ntp.sln@1.1 +71 -0 + VC9 equivalent to ntp.dsw + + ports/winnt/ntp.sln@1.0 +0 -0 + + ports/winnt/ntpd/ntpd.vcproj@1.1 +2198 -0 + VC9 equivalent to ntpd.dsp + + ports/winnt/ntpd/ntpd.vcproj@1.0 +0 -0 + + ports/winnt/ntpdate/ntpdate.vcproj@1.1 +327 -0 + VC9 equivalent to ntpdate.dsp + + ports/winnt/ntpdate/ntpdate.vcproj@1.0 +0 -0 + + ports/winnt/ntpdc/ntpdc.vcproj@1.1 +376 -0 + VC9 equivalent to ntpdc.dsp + + ports/winnt/ntpdc/ntpdc.vcproj@1.0 +0 -0 + + ports/winnt/ntpq/ntpq.vcproj@1.1 +370 -0 + VC9 equivalent to ntpq.dsp + + ports/winnt/ntpq/ntpq.vcproj@1.0 +0 -0 + +ChangeSet@1.1436.17.3, 2009-03-17 18:18:13+00:00, hart@pogo.udel.edu + config.h: + now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + + ports/winnt/include/config.h@1.46.1.2 +243 -96 + now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + +ChangeSet@1.1796.4.3, 2009-03-17 18:15:41+00:00, hart@pogo.udel.edu + config.h: + now works with VC6 and VC9 compilers, declares DWORD_PTR for VC6 + + ports/winnt/include/config.h@1.55 +238 -116 + now works with VC6 and VC9 compilers + +ChangeSet@1.1436.18.1, 2009-02-21 07:45:56-05:00, utterback@pogo.udel.edu + configure.ac, ChangeLog: + [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + + ChangeLog@1.1.13.1 +2 -0 + [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + + configure.ac@1.400.1.2 +3 -0 + [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + +ChangeSet@1.1436.17.2, 2009-02-07 21:13:17+00:00, hart@pogo.udel.edu + ChangeLog: + formatting of newest line + + ChangeLog@1.1.12.2 +1 -1 + formatting of newest line + +ChangeSet@1.1436.17.1, 2009-02-07 21:05:32+00:00, hart@pogo.udel.edu + nt_clockstuff.c, ChangeLog, ntp_iocompletionport.c: + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + + ChangeLog@1.1.12.1 +2 -0 + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + + ports/winnt/ntpd/nt_clockstuff.c@1.23.1.1 +89 -22 + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.6 +12 -0 + [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + +ChangeSet@1.1436.15.14, 2009-02-07 14:08:35-05:00, hart@pogo.udel.edu + ChangeLog: + DPRINTF safer + + ChangeLog@1.1.1.50 +2 -0 + DPRINTF safer + +ChangeSet@1.1436.15.13, 2009-02-06 19:00:15-05:00, hart@pogo.udel.edu + ntp_debug.h: + DPRINTF won't eat following else, always evaluates to a statement + ntp_io.c: + DPRINTF_INTERFACE always evaluates to a statement + fix DPRINTF use with misplaced semicolon + + include/ntp_debug.h@1.2 +6 -4 + DPRINTF won't eat following else, always evaluates to a statement + + ntpd/ntp_io.c@1.244.2.13 +2 -2 + DPRINTF_INTERFACE always evaluates to a statement + fix DPRINTF use with misplaced semicolon + +ChangeSet@1.1796.1.13, 2009-01-30 06:54:34-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P158 + TAG: NTP_4_2_5P158 + + ChangeLog@1.268.1.13 +1 -0 + NTP_4_2_5P158 + + gsoc_sntp/sntp-opts.c@1.19 +2 -2 + NTP_4_2_5P158 + + gsoc_sntp/sntp-opts.h@1.19 +3 -3 + NTP_4_2_5P158 + + gsoc_sntp/sntp-opts.texi@1.19 +1 -1 + NTP_4_2_5P158 + + gsoc_sntp/sntp.1@1.19 +2 -2 + NTP_4_2_5P158 + + ntpd/ntpd-opts.c@1.150 +2 -2 + NTP_4_2_5P158 + + ntpd/ntpd-opts.h@1.150 +3 -3 + NTP_4_2_5P158 + + ntpd/ntpd-opts.texi@1.149 +1 -1 + NTP_4_2_5P158 + + ntpd/ntpd.1@1.149 +2 -2 + NTP_4_2_5P158 + + ntpdc/ntpdc-opts.c@1.146 +2 -2 + NTP_4_2_5P158 + + ntpdc/ntpdc-opts.h@1.146 +3 -3 + NTP_4_2_5P158 + + ntpdc/ntpdc-opts.texi@1.145 +1 -1 + NTP_4_2_5P158 + + ntpdc/ntpdc.1@1.145 +2 -2 + NTP_4_2_5P158 + + ntpq/ntpq-opts.c@1.146 +2 -2 + NTP_4_2_5P158 + + ntpq/ntpq-opts.h@1.146 +3 -3 + NTP_4_2_5P158 + + ntpq/ntpq-opts.texi@1.145 +1 -1 + NTP_4_2_5P158 + + ntpq/ntpq.1@1.145 +2 -2 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd-opts.c@1.27 +2 -2 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd-opts.h@1.27 +3 -3 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd-opts.texi@1.27 +1 -1 + NTP_4_2_5P158 + + ntpsnmpd/ntpsnmpd.1@1.27 +2 -2 + NTP_4_2_5P158 + + packageinfo.sh@1.161 +1 -1 + NTP_4_2_5P158 + + sntp/sntp-opts.c@1.146 +2 -2 + NTP_4_2_5P158 + + sntp/sntp-opts.h@1.146 +3 -3 + NTP_4_2_5P158 + + sntp/sntp-opts.texi@1.145 +1 -1 + NTP_4_2_5P158 + + sntp/sntp.1@1.145 +2 -2 + NTP_4_2_5P158 + + util/ntp-keygen-opts.c@1.149 +2 -2 + NTP_4_2_5P158 + + util/ntp-keygen-opts.h@1.149 +3 -3 + NTP_4_2_5P158 + + util/ntp-keygen-opts.texi@1.148 +1 -1 + NTP_4_2_5P158 + + util/ntp-keygen.1@1.148 +2 -2 + NTP_4_2_5P158 + +ChangeSet@1.1796.1.12, 2009-01-30 03:47:58-05:00, stenn@whimsy.udel.edu + Fix [CID 72], a typo introduced at the latest fix to prettydate.c + + ChangeLog@1.268.1.12 +1 -0 + Fix [CID 72], a typo introduced at the latest fix to prettydate.c + + libntp/prettydate.c@1.10 +2 -1 + Fix [CID 72], a typo introduced at the latest fix to prettydate.c + +ChangeSet@1.1796.1.11, 2009-01-26 06:55:24-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P157 + TAG: NTP_4_2_5P157 + + ChangeLog@1.268.1.11 +1 -0 + NTP_4_2_5P157 + + gsoc_sntp/sntp-opts.c@1.18 +2 -2 + NTP_4_2_5P157 + + gsoc_sntp/sntp-opts.h@1.18 +3 -3 + NTP_4_2_5P157 + + gsoc_sntp/sntp-opts.texi@1.18 +1 -1 + NTP_4_2_5P157 + + gsoc_sntp/sntp.1@1.18 +2 -2 + NTP_4_2_5P157 + + ntpd/ntpd-opts.c@1.149 +2 -2 + NTP_4_2_5P157 + + ntpd/ntpd-opts.h@1.149 +3 -3 + NTP_4_2_5P157 + + ntpd/ntpd-opts.texi@1.148 +2 -2 + NTP_4_2_5P157 + + ntpd/ntpd.1@1.148 +2 -2 + NTP_4_2_5P157 + + ntpdc/ntpdc-opts.c@1.145 +2 -2 + NTP_4_2_5P157 + + ntpdc/ntpdc-opts.h@1.145 +3 -3 + NTP_4_2_5P157 + + ntpdc/ntpdc-opts.texi@1.144 +2 -2 + NTP_4_2_5P157 + + ntpdc/ntpdc.1@1.144 +2 -2 + NTP_4_2_5P157 + + ntpq/ntpq-opts.c@1.145 +2 -2 + NTP_4_2_5P157 + + ntpq/ntpq-opts.h@1.145 +3 -3 + NTP_4_2_5P157 + + ntpq/ntpq-opts.texi@1.144 +2 -2 + NTP_4_2_5P157 + + ntpq/ntpq.1@1.144 +2 -2 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd-opts.c@1.26 +2 -2 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd-opts.h@1.26 +3 -3 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd-opts.texi@1.26 +1 -1 + NTP_4_2_5P157 + + ntpsnmpd/ntpsnmpd.1@1.26 +2 -2 + NTP_4_2_5P157 + + packageinfo.sh@1.160 +1 -1 + NTP_4_2_5P157 + + sntp/sntp-opts.c@1.145 +2 -2 + NTP_4_2_5P157 + + sntp/sntp-opts.h@1.145 +3 -3 + NTP_4_2_5P157 + + sntp/sntp-opts.texi@1.144 +1 -1 + NTP_4_2_5P157 + + sntp/sntp.1@1.144 +2 -2 + NTP_4_2_5P157 + + util/ntp-keygen-opts.c@1.148 +2 -2 + NTP_4_2_5P157 + + util/ntp-keygen-opts.h@1.148 +3 -3 + NTP_4_2_5P157 + + util/ntp-keygen-opts.texi@1.147 +2 -2 + NTP_4_2_5P157 + + util/ntp-keygen.1@1.147 +2 -2 + NTP_4_2_5P157 + +ChangeSet@1.1796.1.10, 2009-01-26 02:08:57-05:00, stenn@whimsy.udel.edu + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + + ChangeLog@1.268.1.10 +1 -0 + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + + ntpd/ntp_crypto.c@1.128 +31 -16 + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + + ntpd/ntp_proto.c@1.276.1.1 +7 -12 + Cleanup/fixes for ntp_proto.c and ntp_crypto.c from Dave Mills + +ChangeSet@1.1796.1.9, 2009-01-19 06:56:21-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P156 + TAG: NTP_4_2_5P156 + + ChangeLog@1.268.1.9 +1 -0 + NTP_4_2_5P156 + + gsoc_sntp/sntp-opts.c@1.17 +2 -2 + NTP_4_2_5P156 + + gsoc_sntp/sntp-opts.h@1.17 +3 -3 + NTP_4_2_5P156 + + gsoc_sntp/sntp-opts.texi@1.17 +1 -1 + NTP_4_2_5P156 + + gsoc_sntp/sntp.1@1.17 +2 -2 + NTP_4_2_5P156 + + ntpd/ntpd-opts.c@1.148 +2 -2 + NTP_4_2_5P156 + + ntpd/ntpd-opts.h@1.148 +3 -3 + NTP_4_2_5P156 + + ntpd/ntpd-opts.texi@1.147 +1 -1 + NTP_4_2_5P156 + + ntpd/ntpd.1@1.147 +2 -2 + NTP_4_2_5P156 + + ntpdc/ntpdc-opts.c@1.144 +2 -2 + NTP_4_2_5P156 + + ntpdc/ntpdc-opts.h@1.144 +3 -3 + NTP_4_2_5P156 + + ntpdc/ntpdc-opts.texi@1.143 +1 -1 + NTP_4_2_5P156 + + ntpdc/ntpdc.1@1.143 +2 -2 + NTP_4_2_5P156 + + ntpq/ntpq-opts.c@1.144 +2 -2 + NTP_4_2_5P156 + + ntpq/ntpq-opts.h@1.144 +3 -3 + NTP_4_2_5P156 + + ntpq/ntpq-opts.texi@1.143 +1 -1 + NTP_4_2_5P156 + + ntpq/ntpq.1@1.143 +2 -2 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd-opts.c@1.25 +2 -2 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd-opts.h@1.25 +3 -3 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd-opts.texi@1.25 +1 -1 + NTP_4_2_5P156 + + ntpsnmpd/ntpsnmpd.1@1.25 +2 -2 + NTP_4_2_5P156 + + packageinfo.sh@1.159 +1 -1 + NTP_4_2_5P156 + + sntp/sntp-opts.c@1.144 +2 -2 + NTP_4_2_5P156 + + sntp/sntp-opts.h@1.144 +3 -3 + NTP_4_2_5P156 + + sntp/sntp-opts.texi@1.143 +1 -1 + NTP_4_2_5P156 + + sntp/sntp.1@1.143 +2 -2 + NTP_4_2_5P156 + + util/ntp-keygen-opts.c@1.147 +2 -2 + NTP_4_2_5P156 + + util/ntp-keygen-opts.h@1.147 +3 -3 + NTP_4_2_5P156 + + util/ntp-keygen-opts.texi@1.146 +1 -1 + NTP_4_2_5P156 + + util/ntp-keygen.1@1.146 +2 -2 + NTP_4_2_5P156 + +ChangeSet@1.1796.3.7, 2009-01-19 03:51:58-05:00, stenn@whimsy.udel.edu + [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c + + ChangeLog@1.268.3.7 +1 -0 + [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c + + ntpd/ntp_crypto.c@1.127 +7 -7 + [Bug 1119] [CID 52] Avoid a possible null-dereference in ntp_crypto.c + +ChangeSet@1.1796.3.6, 2009-01-19 03:41:10-05:00, stenn@whimsy.udel.edu + [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it + + ChangeLog@1.268.3.6 +1 -0 + [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it + + ntpd/ntp_control.c@1.107 +2 -0 + [Bug 1120] [CID 51] INSIST that peer is non-null before we dereference it + +ChangeSet@1.1796.3.5, 2009-01-19 02:58:27-05:00, stenn@whimsy.udel.edu + [Bug 1121] [CID 47] double fclose() in ntp-keygen.c + + ChangeLog@1.268.3.5 +1 -0 + [Bug 1121] [CID 47] double fclose() in ntp-keygen.c + + util/ntp-keygen.c@1.53 +0 -1 + [Bug 1121] [CID 47] double fclose() in ntp-keygen.c + +ChangeSet@1.1796.3.4, 2009-01-18 06:55:12-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P155 + TAG: NTP_4_2_5P155 + + ChangeLog@1.268.3.4 +1 -0 + NTP_4_2_5P155 + + gsoc_sntp/sntp-opts.c@1.16 +2 -2 + NTP_4_2_5P155 + + gsoc_sntp/sntp-opts.h@1.16 +3 -3 + NTP_4_2_5P155 + + gsoc_sntp/sntp-opts.texi@1.16 +1 -1 + NTP_4_2_5P155 + + gsoc_sntp/sntp.1@1.16 +2 -2 + NTP_4_2_5P155 + + ntpd/ntpd-opts.c@1.147 +2 -2 + NTP_4_2_5P155 + + ntpd/ntpd-opts.h@1.147 +3 -3 + NTP_4_2_5P155 + + ntpd/ntpd-opts.texi@1.146 +1 -1 + NTP_4_2_5P155 + + ntpd/ntpd.1@1.146 +2 -2 + NTP_4_2_5P155 + + ntpdc/ntpdc-opts.c@1.143 +2 -2 + NTP_4_2_5P155 + + ntpdc/ntpdc-opts.h@1.143 +3 -3 + NTP_4_2_5P155 + + ntpdc/ntpdc-opts.texi@1.142 +1 -1 + NTP_4_2_5P155 + + ntpdc/ntpdc.1@1.142 +2 -2 + NTP_4_2_5P155 + + ntpq/ntpq-opts.c@1.143 +2 -2 + NTP_4_2_5P155 + + ntpq/ntpq-opts.h@1.143 +3 -3 + NTP_4_2_5P155 + + ntpq/ntpq-opts.texi@1.142 +1 -1 + NTP_4_2_5P155 + + ntpq/ntpq.1@1.142 +2 -2 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd-opts.c@1.24 +2 -2 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd-opts.h@1.24 +3 -3 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd-opts.texi@1.24 +1 -1 + NTP_4_2_5P155 + + ntpsnmpd/ntpsnmpd.1@1.24 +2 -2 + NTP_4_2_5P155 + + packageinfo.sh@1.158 +1 -1 + NTP_4_2_5P155 + + sntp/sntp-opts.c@1.143 +2 -2 + NTP_4_2_5P155 + + sntp/sntp-opts.h@1.143 +3 -3 + NTP_4_2_5P155 + + sntp/sntp-opts.texi@1.142 +1 -1 + NTP_4_2_5P155 + + sntp/sntp.1@1.142 +2 -2 + NTP_4_2_5P155 + + util/ntp-keygen-opts.c@1.146 +2 -2 + NTP_4_2_5P155 + + util/ntp-keygen-opts.h@1.146 +3 -3 + NTP_4_2_5P155 + + util/ntp-keygen-opts.texi@1.145 +1 -1 + NTP_4_2_5P155 + + util/ntp-keygen.1@1.145 +2 -2 + NTP_4_2_5P155 + +ChangeSet@1.1796.3.3, 2009-01-17 19:30:18-05:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.268.3.3 +1 -0 + Documentation updates from Dave Mills + + html/assoc.html@1.27 +6 -1 + Documentation updates from Dave Mills + + html/config.html@1.22 +19 -149 + Documentation updates from Dave Mills + + html/decode.html@1.5 +9 -4 + Documentation updates from Dave Mills + + html/ntpd.html@1.47 +21 -5 + Documentation updates from Dave Mills + +ChangeSet@1.1796.3.2, 2009-01-17 19:25:33-05:00, stenn@whimsy.udel.edu + CHU Frequency updates + + ChangeLog@1.268.3.2 +1 -0 + CHU Frequency updates + + html/drivers/driver7.html@1.27 +11 -2 + CHU Frequency updates + + ntpd/refclock_chu.c@1.45 +4 -4 + CHU Frequency updates + +ChangeSet@1.1796.3.1, 2009-01-17 19:08:44-05:00, stenn@whimsy.udel.edu + Design assertion fixes for ntp_crypto.c from Dave Mills + + ChangeLog@1.268.3.1 +1 -0 + Design assertion fixes for ntp_crypto.c from Dave Mills + + ntpd/ntp_crypto.c@1.126 +3 -6 + Design assertion fixes for ntp_crypto.c from Dave Mills + +ChangeSet@1.1796.1.7, 2009-01-16 15:53:26+01:00, burnicki@pogo.udel.edu + Bug 1118: Fixed sign extension for 32 bit time_t in caljulian() and prettydate(). + Fixed some compiler warnings about missing prototypes. + Fixed some other simple compiler warnings. + + ChangeLog@1.268.1.7 +3 -0 + Bug 1118: Fixed sign extension for 32 bit time_t in caljulian() and prettydate(). + Fixed some compiler warnings about missing prototypes. + Fixed some other simple compiler warnings. + + include/recvbuff.h@1.16 +2 -1 + Added prototype for get_free_recv_buffer_alloc(). + + libntp/caljulian.c@1.11 +11 -2 + Bug 1118: Fixed sign extension for 32 bit time_t. + Added 2 casts to fix compiler warnings. + + libntp/prettydate.c@1.9 +10 -1 + Bug 1118: Fixed sign extension for 32 bit time_t. + Fixed a compiler warning. + + ntpd/ntp_timer.c@1.49 +4 -1 + Include openssl/rand.h to have prototypes available. + +ChangeSet@1.1796.1.6, 2009-01-13 06:57:59-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P154 + TAG: NTP_4_2_5P154 + + ChangeLog@1.268.1.6 +1 -0 + NTP_4_2_5P154 + + gsoc_sntp/sntp-opts.c@1.15 +2 -2 + NTP_4_2_5P154 + + gsoc_sntp/sntp-opts.h@1.15 +3 -3 + NTP_4_2_5P154 + + gsoc_sntp/sntp-opts.texi@1.15 +1 -1 + NTP_4_2_5P154 + + gsoc_sntp/sntp.1@1.15 +2 -2 + NTP_4_2_5P154 + + ntpd/ntpd-opts.c@1.146 +2 -2 + NTP_4_2_5P154 + + ntpd/ntpd-opts.h@1.146 +3 -3 + NTP_4_2_5P154 + + ntpd/ntpd-opts.texi@1.145 +1 -1 + NTP_4_2_5P154 + + ntpd/ntpd.1@1.145 +2 -2 + NTP_4_2_5P154 + + ntpdc/ntpdc-opts.c@1.142 +2 -2 + NTP_4_2_5P154 + + ntpdc/ntpdc-opts.h@1.142 +3 -3 + NTP_4_2_5P154 + + ntpdc/ntpdc-opts.texi@1.141 +1 -1 + NTP_4_2_5P154 + + ntpdc/ntpdc.1@1.141 +2 -2 + NTP_4_2_5P154 + + ntpq/ntpq-opts.c@1.142 +2 -2 + NTP_4_2_5P154 + + ntpq/ntpq-opts.h@1.142 +3 -3 + NTP_4_2_5P154 + + ntpq/ntpq-opts.texi@1.141 +1 -1 + NTP_4_2_5P154 + + ntpq/ntpq.1@1.141 +2 -2 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd-opts.c@1.23 +2 -2 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd-opts.h@1.23 +3 -3 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd-opts.texi@1.23 +1 -1 + NTP_4_2_5P154 + + ntpsnmpd/ntpsnmpd.1@1.23 +2 -2 + NTP_4_2_5P154 + + packageinfo.sh@1.157 +1 -1 + NTP_4_2_5P154 + + sntp/sntp-opts.c@1.142 +2 -2 + NTP_4_2_5P154 + + sntp/sntp-opts.h@1.142 +3 -3 + NTP_4_2_5P154 + + sntp/sntp-opts.texi@1.141 +1 -1 + NTP_4_2_5P154 + + sntp/sntp.1@1.141 +2 -2 + NTP_4_2_5P154 + + util/ntp-keygen-opts.c@1.145 +2 -2 + NTP_4_2_5P154 + + util/ntp-keygen-opts.h@1.145 +3 -3 + NTP_4_2_5P154 + + util/ntp-keygen-opts.texi@1.144 +1 -1 + NTP_4_2_5P154 + + util/ntp-keygen.1@1.144 +2 -2 + NTP_4_2_5P154 + +ChangeSet@1.1796.1.5, 2009-01-11 16:53:36+00:00, kardel@pogo.udel.edu + ChangeLog: + bug 992 - support interface event change on Linux + configure.ac, ntp_io.c: + support interface event change on Linux + + ChangeLog@1.268.1.5 +2 -0 + bug 992 - support interface event change on Linux + + configure.ac@1.422 +13 -1 + support interface event change on Linux + + ntpd/ntp_io.c@1.275 +55 -13 + support interface event change on Linux + +ChangeSet@1.1796.1.4, 2009-01-09 07:20:22-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P153 + TAG: NTP_4_2_5P153 + + ChangeLog@1.268.1.4 +1 -0 + NTP_4_2_5P153 + + gsoc_sntp/sntp-opts.c@1.14 +2 -2 + NTP_4_2_5P153 + + gsoc_sntp/sntp-opts.h@1.14 +3 -3 + NTP_4_2_5P153 + + gsoc_sntp/sntp-opts.texi@1.14 +1 -1 + NTP_4_2_5P153 + + gsoc_sntp/sntp.1@1.14 +2 -2 + NTP_4_2_5P153 + + ntpd/ntpd-opts.c@1.145 +2 -2 + NTP_4_2_5P153 + + ntpd/ntpd-opts.h@1.145 +3 -3 + NTP_4_2_5P153 + + ntpd/ntpd-opts.texi@1.144 +1 -1 + NTP_4_2_5P153 + + ntpd/ntpd.1@1.144 +2 -2 + NTP_4_2_5P153 + + ntpdc/ntpdc-opts.c@1.141 +2 -2 + NTP_4_2_5P153 + + ntpdc/ntpdc-opts.h@1.141 +3 -3 + NTP_4_2_5P153 + + ntpdc/ntpdc-opts.texi@1.140 +1 -1 + NTP_4_2_5P153 + + ntpdc/ntpdc.1@1.140 +2 -2 + NTP_4_2_5P153 + + ntpq/ntpq-opts.c@1.141 +2 -2 + NTP_4_2_5P153 + + ntpq/ntpq-opts.h@1.141 +3 -3 + NTP_4_2_5P153 + + ntpq/ntpq-opts.texi@1.140 +1 -1 + NTP_4_2_5P153 + + ntpq/ntpq.1@1.140 +2 -2 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd-opts.c@1.22 +2 -2 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd-opts.h@1.22 +3 -3 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd-opts.texi@1.22 +1 -1 + NTP_4_2_5P153 + + ntpsnmpd/ntpsnmpd.1@1.22 +2 -2 + NTP_4_2_5P153 + + packageinfo.sh@1.156 +1 -1 + NTP_4_2_5P153 + + sntp/sntp-opts.c@1.141 +2 -2 + NTP_4_2_5P153 + + sntp/sntp-opts.h@1.141 +3 -3 + NTP_4_2_5P153 + + sntp/sntp-opts.texi@1.140 +1 -1 + NTP_4_2_5P153 + + sntp/sntp.1@1.140 +2 -2 + NTP_4_2_5P153 + + util/ntp-keygen-opts.c@1.144 +2 -2 + NTP_4_2_5P153 + + util/ntp-keygen-opts.h@1.144 +3 -3 + NTP_4_2_5P153 + + util/ntp-keygen-opts.texi@1.143 +1 -1 + NTP_4_2_5P153 + + util/ntp-keygen.1@1.143 +2 -2 + NTP_4_2_5P153 + +ChangeSet@1.1796.2.3, 2009-01-08 09:46:10-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P152 + TAG: NTP_4_2_5P152 + + ChangeLog@1.268.2.2 +1 -0 + NTP_4_2_5P152 + + gsoc_sntp/sntp-opts.c@1.13 +2 -2 + NTP_4_2_5P152 + + gsoc_sntp/sntp-opts.h@1.13 +3 -3 + NTP_4_2_5P152 + + gsoc_sntp/sntp-opts.texi@1.13 +1 -1 + NTP_4_2_5P152 + + gsoc_sntp/sntp.1@1.13 +2 -2 + NTP_4_2_5P152 + + ntpd/ntpd-opts.c@1.144 +2 -2 + NTP_4_2_5P152 + + ntpd/ntpd-opts.h@1.144 +3 -3 + NTP_4_2_5P152 + + ntpd/ntpd-opts.texi@1.143 +1 -1 + NTP_4_2_5P152 + + ntpd/ntpd.1@1.143 +2 -2 + NTP_4_2_5P152 + + ntpdc/ntpdc-opts.c@1.140 +2 -2 + NTP_4_2_5P152 + + ntpdc/ntpdc-opts.h@1.140 +3 -3 + NTP_4_2_5P152 + + ntpdc/ntpdc-opts.texi@1.139 +1 -1 + NTP_4_2_5P152 + + ntpdc/ntpdc.1@1.139 +2 -2 + NTP_4_2_5P152 + + ntpq/ntpq-opts.c@1.140 +2 -2 + NTP_4_2_5P152 + + ntpq/ntpq-opts.h@1.140 +3 -3 + NTP_4_2_5P152 + + ntpq/ntpq-opts.texi@1.139 +1 -1 + NTP_4_2_5P152 + + ntpq/ntpq.1@1.139 +2 -2 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd-opts.c@1.21 +2 -2 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd-opts.h@1.21 +3 -3 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd-opts.texi@1.21 +1 -1 + NTP_4_2_5P152 + + ntpsnmpd/ntpsnmpd.1@1.21 +2 -2 + NTP_4_2_5P152 + + packageinfo.sh@1.155 +1 -1 + NTP_4_2_5P152 + + sntp/sntp-opts.c@1.140 +2 -2 + NTP_4_2_5P152 + + sntp/sntp-opts.h@1.140 +3 -3 + NTP_4_2_5P152 + + sntp/sntp-opts.texi@1.139 +1 -1 + NTP_4_2_5P152 + + sntp/sntp.1@1.139 +2 -2 + NTP_4_2_5P152 + + util/ntp-keygen-opts.c@1.143 +2 -2 + NTP_4_2_5P152 + + util/ntp-keygen-opts.h@1.143 +3 -3 + NTP_4_2_5P152 + + util/ntp-keygen-opts.texi@1.142 +1 -1 + NTP_4_2_5P152 + + util/ntp-keygen.1@1.142 +2 -2 + NTP_4_2_5P152 + +ChangeSet@1.1796.2.2, 2009-01-08 08:07:59-05:00, stenn@whimsy.udel.edu + merge cleanup + + ntpd/ntp_crypto.c@1.125 +1 -1 + merge cleanup + +ChangeSet@1.1436.15.12, 2009-01-08 06:21:48-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P6 + TAG: NTP_4_2_4P6 + + ChangeLog@1.1.1.49 +1 -2 + NTP_4_2_4P6 + + ntpd/ntpd-opts.c@1.50.17.2 +2 -2 + NTP_4_2_4P6 + + ntpd/ntpd-opts.h@1.50.17.2 +3 -3 + NTP_4_2_4P6 + + ntpd/ntpd-opts.texi@1.49.17.2 +1 -1 + NTP_4_2_4P6 + + ntpd/ntpd.1@1.48.17.2 +2 -2 + NTP_4_2_4P6 + + ntpd/ntpdsim-opts.c@1.50.17.2 +2 -2 + NTP_4_2_4P6 + + ntpd/ntpdsim-opts.h@1.50.17.2 +3 -3 + NTP_4_2_4P6 + + ntpd/ntpdsim-opts.texi@1.48.17.2 +1 -1 + NTP_4_2_4P6 + + ntpd/ntpdsim.1@1.48.17.2 +2 -2 + NTP_4_2_4P6 + + ntpdc/ntpdc-opts.c@1.50.17.2 +2 -2 + NTP_4_2_4P6 + + ntpdc/ntpdc-opts.h@1.50.17.2 +3 -3 + NTP_4_2_4P6 + + ntpdc/ntpdc-opts.texi@1.48.17.2 +1 -1 + NTP_4_2_4P6 + + ntpdc/ntpdc.1@1.48.17.2 +2 -2 + NTP_4_2_4P6 + + ntpq/ntpq-opts.c@1.52.17.2 +2 -2 + NTP_4_2_4P6 + + ntpq/ntpq-opts.h@1.52.17.2 +3 -3 + NTP_4_2_4P6 + + ntpq/ntpq-opts.texi@1.49.17.2 +1 -1 + NTP_4_2_4P6 + + ntpq/ntpq.1@1.48.17.2 +2 -2 + NTP_4_2_4P6 + + packageinfo.sh@1.65.24.4 +1 -1 + NTP_4_2_4P6 + + sntp/sntp-opts.c@1.49.17.2 +2 -2 + NTP_4_2_4P6 + + sntp/sntp-opts.h@1.49.17.2 +3 -3 + NTP_4_2_4P6 + + sntp/sntp-opts.texi@1.46.17.2 +1 -1 + NTP_4_2_4P6 + + sntp/sntp.1@1.49.17.2 +2 -2 + NTP_4_2_4P6 + + util/ntp-keygen-opts.c@1.49.17.2 +2 -2 + NTP_4_2_4P6 + + util/ntp-keygen-opts.h@1.49.17.2 +3 -3 + NTP_4_2_4P6 + + util/ntp-keygen-opts.texi@1.47.17.2 +1 -1 + NTP_4_2_4P6 + + util/ntp-keygen.1@1.47.17.2 +2 -2 + NTP_4_2_4P6 + +ChangeSet@1.1436.15.11, 2009-01-08 04:49:23-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P5 + TAG: NTP_4_2_4P5 + + ChangeLog@1.1.1.48 +1 -0 + NTP_4_2_4P5 + + ntpd/ntpd-opts.c@1.50.17.1 +1 -1 + NTP_4_2_4P5 + + ntpd/ntpd-opts.h@1.50.17.1 +1 -1 + NTP_4_2_4P5 + + ntpd/ntpd-opts.texi@1.49.17.1 +2 -2 + NTP_4_2_4P5 + + ntpd/ntpd.1@1.48.17.1 +2 -2 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.c@1.50.17.1 +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.h@1.50.17.1 +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.texi@1.48.17.1 +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim.1@1.48.17.1 +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.c@1.50.17.1 +1 -1 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.h@1.50.17.1 +1 -1 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.texi@1.48.17.1 +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc.1@1.48.17.1 +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq-opts.c@1.52.17.1 +1 -1 + NTP_4_2_4P5 + + ntpq/ntpq-opts.h@1.52.17.1 +1 -1 + NTP_4_2_4P5 + + ntpq/ntpq-opts.texi@1.49.17.1 +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq.1@1.48.17.1 +2 -2 + NTP_4_2_4P5 + + packageinfo.sh@1.65.24.3 +2 -2 + NTP_4_2_4P5 + + sntp/sntp-opts.c@1.49.17.1 +1 -1 + NTP_4_2_4P5 + + sntp/sntp-opts.h@1.49.17.1 +1 -1 + NTP_4_2_4P5 + + sntp/sntp-opts.texi@1.46.17.1 +1 -1 + NTP_4_2_4P5 + + sntp/sntp.1@1.49.17.1 +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen-opts.c@1.49.17.1 +1 -1 + NTP_4_2_4P5 + + util/ntp-keygen-opts.h@1.49.17.1 +1 -1 + NTP_4_2_4P5 + + util/ntp-keygen-opts.texi@1.47.17.1 +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen.1@1.47.17.1 +2 -2 + NTP_4_2_4P5 + +ChangeSet@1.1436.15.10, 2009-01-08 03:21:09-05:00, stenn@whimsy.udel.edu + 4.2.4p6 + + packageinfo.sh@1.65.24.2 +1 -1 + 4.2.4p6 + +ChangeSet@1.1436.15.9, 2009-01-08 03:14:17-05:00, stenn@whimsy.udel.edu + merge cleanup + + ChangeLog@1.1.1.47 +1 -1 + merge cleanup + +ChangeSet@1.1436.16.1, 2009-01-08 02:57:52-05:00, stenn@whimsy.udel.edu + 4.2.4p6 + + ChangeLog@1.1.1.45 +6 -0 + Fix incorrect check of EVP_VerifyFinal()'s return value. + + NEWS@1.86.1.14 +16 -0 + 4.2.4p6 + + html/copyright.html@1.36.1.2 +1 -1 + Update the copyright year + + ntpd/ntp_crypto.c@1.107.1.1 +1 -1 + Fix incorrect check of EVP_VerifyFinal()'s return value. + + packageinfo.sh@1.65.24.1 +1 -1 + 4.2.4p6 + +ChangeSet@1.1436.15.7, 2009-01-07 18:00:50+01:00, burnicki@pogo.udel.edu + [BUG 1113] Fixed build errors with recent versions of openSSL. + + ChangeLog@1.1.11.1 +1 -0 + [BUG 1113] Fixed build errors with recent versions of openSSL. + + ntpd/ntp_crypto.c@1.107.2.1 +2 -2 + [BUG 1113] Fixed build errors with recent versions of openSSL. + +ChangeSet@1.1796.1.2, 2009-01-07 15:18:18+01:00, burnicki@pogo.udel.edu + Renamed gsoc_sntp/:fetch-stubs to gsoc_sntp/fetch-stubs to avoid + file name problems under Windows. + Removed German umlaut from log msg for 4.2.5p142. + + ChangeLog@1.268.1.2 +4 -1 + Renamed gsoc_sntp/:fetch-stubs to gsoc_sntp/fetch-stubs to avoid + file name problems under Windows. + Removed German umlaut from log msg for 4.2.5p142. + + gsoc_sntp/fetch-stubs@1.5 +0 -0 + Rename: gsoc_sntp/:fetch-stubs -> gsoc_sntp/fetch-stubs + +ChangeSet@1.1796.1.1, 2008-12-23 06:53:33-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P151 + TAG: NTP_4_2_5P151 + + ChangeLog@1.268.1.1 +1 -0 + NTP_4_2_5P151 + + gsoc_sntp/sntp-opts.c@1.12 +2 -2 + NTP_4_2_5P151 + + gsoc_sntp/sntp-opts.h@1.12 +3 -3 + NTP_4_2_5P151 + + gsoc_sntp/sntp-opts.texi@1.12 +1 -1 + NTP_4_2_5P151 + + gsoc_sntp/sntp.1@1.12 +2 -2 + NTP_4_2_5P151 + + ntpd/ntpd-opts.c@1.143 +2 -2 + NTP_4_2_5P151 + + ntpd/ntpd-opts.h@1.143 +3 -3 + NTP_4_2_5P151 + + ntpd/ntpd-opts.texi@1.142 +1 -1 + NTP_4_2_5P151 + + ntpd/ntpd.1@1.142 +2 -2 + NTP_4_2_5P151 + + ntpdc/ntpdc-opts.c@1.139 +2 -2 + NTP_4_2_5P151 + + ntpdc/ntpdc-opts.h@1.139 +3 -3 + NTP_4_2_5P151 + + ntpdc/ntpdc-opts.texi@1.138 +1 -1 + NTP_4_2_5P151 + + ntpdc/ntpdc.1@1.138 +2 -2 + NTP_4_2_5P151 + + ntpq/ntpq-opts.c@1.139 +2 -2 + NTP_4_2_5P151 + + ntpq/ntpq-opts.h@1.139 +3 -3 + NTP_4_2_5P151 + + ntpq/ntpq-opts.texi@1.138 +1 -1 + NTP_4_2_5P151 + + ntpq/ntpq.1@1.138 +2 -2 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd-opts.c@1.20 +2 -2 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd-opts.h@1.20 +3 -3 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd-opts.texi@1.20 +1 -1 + NTP_4_2_5P151 + + ntpsnmpd/ntpsnmpd.1@1.20 +2 -2 + NTP_4_2_5P151 + + packageinfo.sh@1.154 +1 -1 + NTP_4_2_5P151 + + sntp/sntp-opts.c@1.139 +2 -2 + NTP_4_2_5P151 + + sntp/sntp-opts.h@1.139 +3 -3 + NTP_4_2_5P151 + + sntp/sntp-opts.texi@1.138 +1 -1 + NTP_4_2_5P151 + + sntp/sntp.1@1.138 +2 -2 + NTP_4_2_5P151 + + util/ntp-keygen-opts.c@1.142 +2 -2 + NTP_4_2_5P151 + + util/ntp-keygen-opts.h@1.142 +3 -3 + NTP_4_2_5P151 + + util/ntp-keygen-opts.texi@1.141 +1 -1 + NTP_4_2_5P151 + + util/ntp-keygen.1@1.141 +2 -2 + NTP_4_2_5P151 + +ChangeSet@1.1795.1.1, 2008-12-23 04:34:32-05:00, stenn@whimsy.udel.edu + [Bug 1028] Support for W32Time authentication via Samba + + ChangeLog@1.267.1.1 +1 -0 + [Bug 1028] Support for W32Time authentication via Samba + + include/ntp.h@1.149 +1 -0 + [Bug 1028] Support for W32Time authentication via Samba + + include/ntp_config.h@1.48 +1 -0 + [Bug 1028] Support for W32Time authentication via Samba + + include/ntpd.h@1.119 +14 -0 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/Makefile.am@1.66 +1 -1 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_config.c@1.185 +11 -0 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_parser.c@1.32 +908 -889 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_parser.h@1.16 +123 -121 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_parser.y@1.26 +3 -0 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_proto.c@1.277 +53 -11 + [Bug 1028] Support for W32Time authentication via Samba + + ntpd/ntp_signd.c@1.1 +242 -0 + BitKeeper file /deacon/backroom/ntp-dev-samba/ntpd/ntp_signd.c + + ntpd/ntp_signd.c@1.0 +0 -0 + +ChangeSet@1.1796, 2008-12-23 02:59:12-05:00, stenn@whimsy.udel.edu + Stats file logging cleanup from Dave Mills + + ChangeLog@1.268 +1 -0 + Stats file logging cleanup from Dave Mills + + ntpd/ntp_control.c@1.106 +31 -13 + Stats file logging cleanup from Dave Mills + +ChangeSet@1.1795, 2008-12-15 06:54:36-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P150 + TAG: NTP_4_2_5P150 + + ChangeLog@1.267 +1 -0 + NTP_4_2_5P150 + + gsoc_sntp/sntp-opts.c@1.11 +2 -2 + NTP_4_2_5P150 + + gsoc_sntp/sntp-opts.h@1.11 +3 -3 + NTP_4_2_5P150 + + gsoc_sntp/sntp-opts.texi@1.11 +1 -1 + NTP_4_2_5P150 + + gsoc_sntp/sntp.1@1.11 +2 -2 + NTP_4_2_5P150 + + ntpd/ntpd-opts.c@1.142 +2 -2 + NTP_4_2_5P150 + + ntpd/ntpd-opts.h@1.142 +3 -3 + NTP_4_2_5P150 + + ntpd/ntpd-opts.texi@1.141 +1 -1 + NTP_4_2_5P150 + + ntpd/ntpd.1@1.141 +2 -2 + NTP_4_2_5P150 + + ntpdc/ntpdc-opts.c@1.138 +2 -2 + NTP_4_2_5P150 + + ntpdc/ntpdc-opts.h@1.138 +3 -3 + NTP_4_2_5P150 + + ntpdc/ntpdc-opts.texi@1.137 +1 -1 + NTP_4_2_5P150 + + ntpdc/ntpdc.1@1.137 +2 -2 + NTP_4_2_5P150 + + ntpq/ntpq-opts.c@1.138 +2 -2 + NTP_4_2_5P150 + + ntpq/ntpq-opts.h@1.138 +3 -3 + NTP_4_2_5P150 + + ntpq/ntpq-opts.texi@1.137 +1 -1 + NTP_4_2_5P150 + + ntpq/ntpq.1@1.137 +2 -2 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd-opts.c@1.19 +2 -2 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd-opts.h@1.19 +3 -3 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd-opts.texi@1.19 +1 -1 + NTP_4_2_5P150 + + ntpsnmpd/ntpsnmpd.1@1.19 +2 -2 + NTP_4_2_5P150 + + packageinfo.sh@1.153 +1 -1 + NTP_4_2_5P150 + + sntp/sntp-opts.c@1.138 +2 -2 + NTP_4_2_5P150 + + sntp/sntp-opts.h@1.138 +3 -3 + NTP_4_2_5P150 + + sntp/sntp-opts.texi@1.137 +1 -1 + NTP_4_2_5P150 + + sntp/sntp.1@1.137 +2 -2 + NTP_4_2_5P150 + + util/ntp-keygen-opts.c@1.141 +2 -2 + NTP_4_2_5P150 + + util/ntp-keygen-opts.h@1.141 +3 -3 + NTP_4_2_5P150 + + util/ntp-keygen-opts.texi@1.140 +1 -1 + NTP_4_2_5P150 + + util/ntp-keygen.1@1.140 +2 -2 + NTP_4_2_5P150 + +ChangeSet@1.1791.1.3, 2008-12-15 04:12:45-05:00, stenn@pogo.udel.edu + [Bug 1103] Fix 64-bit issues in the new calendar code + + ChangeLog@1.264.1.9 +1 -1 + [Bug 1103] Fix 64-bit issues in the new calendar code + +ChangeSet@1.1791.2.11, 2008-12-05 07:13:56-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P149 + TAG: NTP_4_2_5P149 + + ChangeLog@1.264.1.8 +1 -0 + NTP_4_2_5P149 + + gsoc_sntp/sntp-opts.c@1.10 +2 -2 + NTP_4_2_5P149 + + gsoc_sntp/sntp-opts.h@1.10 +3 -3 + NTP_4_2_5P149 + + gsoc_sntp/sntp-opts.texi@1.10 +1 -1 + NTP_4_2_5P149 + + gsoc_sntp/sntp.1@1.10 +2 -2 + NTP_4_2_5P149 + + ntpd/ntpd-opts.c@1.141 +2 -2 + NTP_4_2_5P149 + + ntpd/ntpd-opts.h@1.141 +3 -3 + NTP_4_2_5P149 + + ntpd/ntpd-opts.texi@1.140 +1 -1 + NTP_4_2_5P149 + + ntpd/ntpd.1@1.140 +2 -2 + NTP_4_2_5P149 + + ntpdc/ntpdc-opts.c@1.137 +2 -2 + NTP_4_2_5P149 + + ntpdc/ntpdc-opts.h@1.137 +3 -3 + NTP_4_2_5P149 + + ntpdc/ntpdc-opts.texi@1.136 +1 -1 + NTP_4_2_5P149 + + ntpdc/ntpdc.1@1.136 +2 -2 + NTP_4_2_5P149 + + ntpq/ntpq-opts.c@1.137 +2 -2 + NTP_4_2_5P149 + + ntpq/ntpq-opts.h@1.137 +3 -3 + NTP_4_2_5P149 + + ntpq/ntpq-opts.texi@1.136 +1 -1 + NTP_4_2_5P149 + + ntpq/ntpq.1@1.136 +2 -2 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd-opts.c@1.18 +2 -2 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd-opts.h@1.18 +3 -3 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd-opts.texi@1.18 +1 -1 + NTP_4_2_5P149 + + ntpsnmpd/ntpsnmpd.1@1.18 +2 -2 + NTP_4_2_5P149 + + packageinfo.sh@1.152 +1 -1 + NTP_4_2_5P149 + + sntp/sntp-opts.c@1.137 +2 -2 + NTP_4_2_5P149 + + sntp/sntp-opts.h@1.137 +3 -3 + NTP_4_2_5P149 + + sntp/sntp-opts.texi@1.136 +1 -1 + NTP_4_2_5P149 + + sntp/sntp.1@1.136 +2 -2 + NTP_4_2_5P149 + + util/ntp-keygen-opts.c@1.140 +2 -2 + NTP_4_2_5P149 + + util/ntp-keygen-opts.h@1.140 +3 -3 + NTP_4_2_5P149 + + util/ntp-keygen-opts.texi@1.139 +1 -1 + NTP_4_2_5P149 + + util/ntp-keygen.1@1.139 +2 -2 + NTP_4_2_5P149 + +ChangeSet@1.1791.2.10, 2008-12-05 05:48:37-05:00, stenn@pogo.udel.edu + Distribute ntpv4-mib.mib + + ntpsnmpd/Makefile.am@1.7 +4 -2 + Distribute ntpv4-mib.mib + +ChangeSet@1.1791.2.9, 2008-12-05 11:23:22+01:00, gerstung@pogo.udel.edu + * changelog comments added for changes regarding ntpSnmpSubAgent.c and ntpv4-mib.mib + + ChangeLog@1.264.1.7 +3 -0 + * changelog comments added for changes regarding ntpSnmpSubAgent.c and ntpv4-mib.mib + +ChangeSet@1.1791.2.8, 2008-12-05 11:13:33+01:00, gerstung@pogo.udel.edu + * fixed two wrong data types + * fixed wrong OID definitions + * added preliminaray and unofficial MIB for TESTING PURPOSES ONLY + + ntpsnmpd/ntpSnmpSubagentObject.c@1.3 +16 -17 + * fixed two wrong data types + * fixed wrong OID definitions + + ntpsnmpd/ntpv4-mib.mib@1.1 +1005 -0 + * added for testing purposes --- DO NOT USE IN PRODUCTIVE ENVIRONMENTS --- this MIB file will change as soon as the NTPv4 MIB RFC has been approved and the required OID has been registered with IANA + + ntpsnmpd/ntpv4-mib.mib@1.0 +0 -0 + +ChangeSet@1.1791.2.7, 2008-12-04 06:53:18-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P148 + TAG: NTP_4_2_5P148 + + ChangeLog@1.264.1.6 +1 -0 + NTP_4_2_5P148 + + gsoc_sntp/sntp-opts.c@1.9 +2 -2 + NTP_4_2_5P148 + + gsoc_sntp/sntp-opts.h@1.9 +3 -3 + NTP_4_2_5P148 + + gsoc_sntp/sntp-opts.texi@1.9 +1 -1 + NTP_4_2_5P148 + + gsoc_sntp/sntp.1@1.9 +2 -2 + NTP_4_2_5P148 + + ntpd/ntpd-opts.c@1.140 +2 -2 + NTP_4_2_5P148 + + ntpd/ntpd-opts.h@1.140 +3 -3 + NTP_4_2_5P148 + + ntpd/ntpd-opts.texi@1.139 +1 -1 + NTP_4_2_5P148 + + ntpd/ntpd.1@1.139 +2 -2 + NTP_4_2_5P148 + + ntpdc/ntpdc-opts.c@1.136 +2 -2 + NTP_4_2_5P148 + + ntpdc/ntpdc-opts.h@1.136 +3 -3 + NTP_4_2_5P148 + + ntpdc/ntpdc-opts.texi@1.135 +1 -1 + NTP_4_2_5P148 + + ntpdc/ntpdc.1@1.135 +2 -2 + NTP_4_2_5P148 + + ntpq/ntpq-opts.c@1.136 +2 -2 + NTP_4_2_5P148 + + ntpq/ntpq-opts.h@1.136 +3 -3 + NTP_4_2_5P148 + + ntpq/ntpq-opts.texi@1.135 +1 -1 + NTP_4_2_5P148 + + ntpq/ntpq.1@1.135 +2 -2 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd-opts.c@1.17 +2 -2 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd-opts.h@1.17 +3 -3 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd-opts.texi@1.17 +1 -1 + NTP_4_2_5P148 + + ntpsnmpd/ntpsnmpd.1@1.17 +2 -2 + NTP_4_2_5P148 + + packageinfo.sh@1.151 +1 -1 + NTP_4_2_5P148 + + sntp/sntp-opts.c@1.136 +2 -2 + NTP_4_2_5P148 + + sntp/sntp-opts.h@1.136 +3 -3 + NTP_4_2_5P148 + + sntp/sntp-opts.texi@1.135 +1 -1 + NTP_4_2_5P148 + + sntp/sntp.1@1.135 +2 -2 + NTP_4_2_5P148 + + util/ntp-keygen-opts.c@1.139 +2 -2 + NTP_4_2_5P148 + + util/ntp-keygen-opts.h@1.139 +3 -3 + NTP_4_2_5P148 + + util/ntp-keygen-opts.texi@1.138 +1 -1 + NTP_4_2_5P148 + + util/ntp-keygen.1@1.138 +2 -2 + NTP_4_2_5P148 + +ChangeSet@1.1791.2.6, 2008-12-04 03:33:40-05:00, stenn@pogo.udel.edu + [Bug 1070] Fix use of ntpq_parsestring() in ntpsnmpd + + ChangeLog@1.264.1.5 +1 -0 + [Bug 1070] Fix use of ntpq_parsestring() in ntpsnmpd + +ChangeSet@1.1791.2.5, 2008-12-04 09:08:53+01:00, gerstung@pogo.udel.edu + * bug 1070 fixed (call to undefined function ntpq_parsestring) + * added new string handler functions for dealing with ntpd responses + * fixed handling of SoftwareName entity (unreachable code) + * added function prototypes to reduce/remove compiler warnings + + ntpsnmpd/ntpSnmpSubagentObject.c@1.2 +224 -8 + * bug 1070 fixed (call to undefined function ntpq_parsestring) + * added new string handler functions for dealing with ntpd responses + * fixed handling of SoftwareName entity (unreachable code) + + + ntpsnmpd/ntpSnmpSubagentObject.h@1.2 +4 -1 + * added function prototypes to avoid compiler warnings + +ChangeSet@1.1791.2.4, 2008-11-27 06:54:28-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P147 + TAG: NTP_4_2_5P147 + + ChangeLog@1.264.1.4 +1 -0 + NTP_4_2_5P147 + + gsoc_sntp/sntp-opts.c@1.8 +2 -2 + NTP_4_2_5P147 + + gsoc_sntp/sntp-opts.h@1.8 +3 -3 + NTP_4_2_5P147 + + gsoc_sntp/sntp-opts.texi@1.8 +1 -1 + NTP_4_2_5P147 + + gsoc_sntp/sntp.1@1.8 +2 -2 + NTP_4_2_5P147 + + ntpd/ntpd-opts.c@1.139 +2 -2 + NTP_4_2_5P147 + + ntpd/ntpd-opts.h@1.139 +3 -3 + NTP_4_2_5P147 + + ntpd/ntpd-opts.texi@1.138 +1 -1 + NTP_4_2_5P147 + + ntpd/ntpd.1@1.138 +2 -2 + NTP_4_2_5P147 + + ntpdc/ntpdc-opts.c@1.135 +2 -2 + NTP_4_2_5P147 + + ntpdc/ntpdc-opts.h@1.135 +3 -3 + NTP_4_2_5P147 + + ntpdc/ntpdc-opts.texi@1.134 +1 -1 + NTP_4_2_5P147 + + ntpdc/ntpdc.1@1.134 +2 -2 + NTP_4_2_5P147 + + ntpq/ntpq-opts.c@1.135 +2 -2 + NTP_4_2_5P147 + + ntpq/ntpq-opts.h@1.135 +3 -3 + NTP_4_2_5P147 + + ntpq/ntpq-opts.texi@1.134 +1 -1 + NTP_4_2_5P147 + + ntpq/ntpq.1@1.134 +2 -2 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd-opts.c@1.16 +2 -2 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd-opts.h@1.16 +3 -3 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd-opts.texi@1.16 +1 -1 + NTP_4_2_5P147 + + ntpsnmpd/ntpsnmpd.1@1.16 +2 -2 + NTP_4_2_5P147 + + packageinfo.sh@1.150 +1 -1 + NTP_4_2_5P147 + + sntp/sntp-opts.c@1.135 +2 -2 + NTP_4_2_5P147 + + sntp/sntp-opts.h@1.135 +3 -3 + NTP_4_2_5P147 + + sntp/sntp-opts.texi@1.134 +1 -1 + NTP_4_2_5P147 + + sntp/sntp.1@1.134 +2 -2 + NTP_4_2_5P147 + + util/ntp-keygen-opts.c@1.138 +2 -2 + NTP_4_2_5P147 + + util/ntp-keygen-opts.h@1.138 +3 -3 + NTP_4_2_5P147 + + util/ntp-keygen-opts.texi@1.137 +1 -1 + NTP_4_2_5P147 + + util/ntp-keygen.1@1.137 +2 -2 + NTP_4_2_5P147 + +ChangeSet@1.1791.2.3, 2008-11-27 02:56:55-05:00, stenn@whimsy.udel.edu + Update gsoc_sntp's GCC warning code + + ChangeLog@1.264.1.3 +1 -0 + Update gsoc_sntp's GCC warning code + + gsoc_sntp/Makefile.am@1.6 +2 -2 + Update gsoc_sntp's GCC warning code + + gsoc_sntp/configure.ac@1.10 +21 -0 + Update gsoc_sntp's GCC warning code + +ChangeSet@1.1791.2.2, 2008-11-26 07:09:34-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P146 + TAG: NTP_4_2_5P146 + + ChangeLog@1.264.1.2 +1 -0 + NTP_4_2_5P146 + + gsoc_sntp/sntp-opts.c@1.7 +2 -2 + NTP_4_2_5P146 + + gsoc_sntp/sntp-opts.h@1.7 +3 -3 + NTP_4_2_5P146 + + gsoc_sntp/sntp-opts.texi@1.7 +1 -1 + NTP_4_2_5P146 + + gsoc_sntp/sntp.1@1.7 +2 -2 + NTP_4_2_5P146 + + ntpd/ntpd-opts.c@1.138 +2 -2 + NTP_4_2_5P146 + + ntpd/ntpd-opts.h@1.138 +3 -3 + NTP_4_2_5P146 + + ntpd/ntpd-opts.texi@1.137 +1 -1 + NTP_4_2_5P146 + + ntpd/ntpd.1@1.137 +2 -2 + NTP_4_2_5P146 + + ntpdc/ntpdc-opts.c@1.134 +2 -2 + NTP_4_2_5P146 + + ntpdc/ntpdc-opts.h@1.134 +3 -3 + NTP_4_2_5P146 + + ntpdc/ntpdc-opts.texi@1.133 +1 -1 + NTP_4_2_5P146 + + ntpdc/ntpdc.1@1.133 +2 -2 + NTP_4_2_5P146 + + ntpq/ntpq-opts.c@1.134 +2 -2 + NTP_4_2_5P146 + + ntpq/ntpq-opts.h@1.134 +3 -3 + NTP_4_2_5P146 + + ntpq/ntpq-opts.texi@1.133 +1 -1 + NTP_4_2_5P146 + + ntpq/ntpq.1@1.133 +2 -2 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd-opts.c@1.15 +2 -2 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd-opts.h@1.15 +3 -3 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd-opts.texi@1.15 +1 -1 + NTP_4_2_5P146 + + ntpsnmpd/ntpsnmpd.1@1.15 +2 -2 + NTP_4_2_5P146 + + packageinfo.sh@1.149 +1 -1 + NTP_4_2_5P146 + + sntp/sntp-opts.c@1.134 +2 -2 + NTP_4_2_5P146 + + sntp/sntp-opts.h@1.134 +3 -3 + NTP_4_2_5P146 + + sntp/sntp-opts.texi@1.133 +1 -1 + NTP_4_2_5P146 + + sntp/sntp.1@1.133 +2 -2 + NTP_4_2_5P146 + + util/ntp-keygen-opts.c@1.137 +2 -2 + NTP_4_2_5P146 + + util/ntp-keygen-opts.h@1.137 +3 -3 + NTP_4_2_5P146 + + util/ntp-keygen-opts.texi@1.136 +1 -1 + NTP_4_2_5P146 + + util/ntp-keygen.1@1.136 +2 -2 + NTP_4_2_5P146 + +ChangeSet@1.1791.2.1, 2008-11-26 06:02:22-05:00, stenn@whimsy.udel.edu + Update Solaris CFLAGS for gsoc_sntp + + ChangeLog@1.264.1.1 +1 -0 + Update Solaris CFLAGS for gsoc_sntp + + gsoc_sntp/configure.ac@1.9 +11 -0 + Update Solaris CFLAGS for gsoc_sntp + +ChangeSet@1.1791.1.1, 2008-11-25 21:23:21+00:00, kuehn@pogo.udel.edu + prettydate.c, caljulian.c, calyearstart.c: + Added changes from Juergen + + libntp/caljulian.c@1.10 +13 -10 + Added changes from Juergen + + libntp/calyearstart.c@1.4 +5 -2 + Added changes from Juergen + + libntp/prettydate.c@1.8 +5 -6 + Added changes from Juergen + +ChangeSet@1.1793, 2008-11-22 00:54:08+00:00, kuehn@pogo.udel.edu + ChangeLog: + Added entry for bug #1099 + + ChangeLog@1.265 +1 -0 + Added entry for bug #1099 + +ChangeSet@1.1792, 2008-11-22 01:22:42+01:00, Amidamaru@melchior.mxiesoft.com + crypto.c: + Fixed auth_init to detect empty lines and malformed entries + + gsoc_sntp/crypto.c@1.4 +25 -15 + Fixed auth_init to detect empty lines and malformed entries + +ChangeSet@1.1791, 2008-11-20 06:54:56-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P145 + TAG: NTP_4_2_5P145 + + ChangeLog@1.264 +1 -0 + NTP_4_2_5P145 + + gsoc_sntp/sntp-opts.c@1.6 +2 -2 + NTP_4_2_5P145 + + gsoc_sntp/sntp-opts.h@1.6 +3 -3 + NTP_4_2_5P145 + + gsoc_sntp/sntp-opts.texi@1.6 +1 -1 + NTP_4_2_5P145 + + gsoc_sntp/sntp.1@1.6 +2 -2 + NTP_4_2_5P145 + + ntpd/ntpd-opts.c@1.137 +2 -2 + NTP_4_2_5P145 + + ntpd/ntpd-opts.h@1.137 +3 -3 + NTP_4_2_5P145 + + ntpd/ntpd-opts.texi@1.136 +1 -1 + NTP_4_2_5P145 + + ntpd/ntpd.1@1.136 +2 -2 + NTP_4_2_5P145 + + ntpdc/ntpdc-opts.c@1.133 +2 -2 + NTP_4_2_5P145 + + ntpdc/ntpdc-opts.h@1.133 +3 -3 + NTP_4_2_5P145 + + ntpdc/ntpdc-opts.texi@1.132 +1 -1 + NTP_4_2_5P145 + + ntpdc/ntpdc.1@1.132 +2 -2 + NTP_4_2_5P145 + + ntpq/ntpq-opts.c@1.133 +2 -2 + NTP_4_2_5P145 + + ntpq/ntpq-opts.h@1.133 +3 -3 + NTP_4_2_5P145 + + ntpq/ntpq-opts.texi@1.132 +1 -1 + NTP_4_2_5P145 + + ntpq/ntpq.1@1.132 +2 -2 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd-opts.c@1.14 +2 -2 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd-opts.h@1.14 +3 -3 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd-opts.texi@1.14 +1 -1 + NTP_4_2_5P145 + + ntpsnmpd/ntpsnmpd.1@1.14 +2 -2 + NTP_4_2_5P145 + + packageinfo.sh@1.148 +1 -1 + NTP_4_2_5P145 + + sntp/sntp-opts.c@1.133 +2 -2 + NTP_4_2_5P145 + + sntp/sntp-opts.h@1.133 +3 -3 + NTP_4_2_5P145 + + sntp/sntp-opts.texi@1.132 +1 -1 + NTP_4_2_5P145 + + sntp/sntp.1@1.132 +2 -2 + NTP_4_2_5P145 + + util/ntp-keygen-opts.c@1.136 +2 -2 + NTP_4_2_5P145 + + util/ntp-keygen-opts.h@1.136 +3 -3 + NTP_4_2_5P145 + + util/ntp-keygen-opts.texi@1.135 +1 -1 + NTP_4_2_5P145 + + util/ntp-keygen.1@1.135 +2 -2 + NTP_4_2_5P145 + +ChangeSet@1.1790, 2008-11-20 08:43:08+00:00, stenn@poog.il.thewrittenword.com + Deal with time.h for sntp under linux + + ChangeLog@1.263 +1 -0 + Deal with time.h for sntp under linux + + gsoc_sntp/configure.ac@1.8 +3 -1 + Deal with time.h for sntp under linux + +ChangeSet@1.1789, 2008-11-20 07:09:48+00:00, stenn@poog.il.thewrittenword.com + Provide rpl_malloc() for sntp for systems that need it + + ChangeLog@1.262 +1 -0 + Provide rpl_malloc() for sntp for systems that need it + + gsoc_sntp/main.c@1.11 +10 -0 + Provide rpl_malloc() for sntp for systems that need it + + gsoc_sntp/networking.c@1.17 +3 -3 + Handle ss_len and socklen type for sntp + +ChangeSet@1.1788, 2008-11-20 07:07:09+00:00, stenn@poog.il.thewrittenword.com + Handle ss_len and socklen type for sntp + + ChangeLog@1.261 +1 -0 + Handle ss_len and socklen type for sntp + + gsoc_sntp/configure.ac@1.7 +74 -0 + Handle ss_len and socklen type for sntp + +ChangeSet@1.1787, 2008-11-20 05:42:04+00:00, stenn@poog.il.thewrittenword.com + Fixes to the sntp configure.ac script. + + ChangeLog@1.260 +1 -0 + Fixes to the sntp configure.ac script. + + gsoc_sntp/configure.ac@1.6 +227 -20 + Fixes to the sntp configure.ac script. + +ChangeSet@1.1786, 2008-11-20 05:41:10+00:00, stenn@poog.il.thewrittenword.com + Provide INET6_ADDRSTRLEN if it is missing + + ChangeLog@1.259 +1 -0 + Provide INET6_ADDRSTRLEN if it is missing + + include/ntp_rfc2553.h@1.30 +15 -11 + Provide INET6_ADDRSTRLEN if it is missing + +ChangeSet@1.1785, 2008-11-19 22:18:03+00:00, stenn@poog.il.thewrittenword.com + [Bug 1095] overflow in caljulian.c + + ChangeLog@1.258 +1 -0 + [Bug 1095] overflow in caljulian.c + + libntp/caljulian.c@1.9 +2 -1 + [Bug 1095] overflow in caljulian.c + +ChangeSet@1.1784, 2008-11-19 06:58:01-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P144 + TAG: NTP_4_2_5P144 + + ChangeLog@1.257 +1 -0 + NTP_4_2_5P144 + + gsoc_sntp/sntp-opts.c@1.5 +2 -2 + NTP_4_2_5P144 + + gsoc_sntp/sntp-opts.h@1.5 +3 -3 + NTP_4_2_5P144 + + gsoc_sntp/sntp-opts.texi@1.5 +1 -1 + NTP_4_2_5P144 + + gsoc_sntp/sntp.1@1.5 +2 -2 + NTP_4_2_5P144 + + ntpd/ntpd-opts.c@1.136 +2 -2 + NTP_4_2_5P144 + + ntpd/ntpd-opts.h@1.136 +3 -3 + NTP_4_2_5P144 + + ntpd/ntpd-opts.texi@1.135 +1 -1 + NTP_4_2_5P144 + + ntpd/ntpd.1@1.135 +2 -2 + NTP_4_2_5P144 + + ntpdc/ntpdc-opts.c@1.132 +2 -2 + NTP_4_2_5P144 + + ntpdc/ntpdc-opts.h@1.132 +3 -3 + NTP_4_2_5P144 + + ntpdc/ntpdc-opts.texi@1.131 +1 -1 + NTP_4_2_5P144 + + ntpdc/ntpdc.1@1.131 +2 -2 + NTP_4_2_5P144 + + ntpq/ntpq-opts.c@1.132 +2 -2 + NTP_4_2_5P144 + + ntpq/ntpq-opts.h@1.132 +3 -3 + NTP_4_2_5P144 + + ntpq/ntpq-opts.texi@1.131 +1 -1 + NTP_4_2_5P144 + + ntpq/ntpq.1@1.131 +2 -2 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd-opts.c@1.13 +2 -2 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd-opts.h@1.13 +3 -3 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd-opts.texi@1.13 +1 -1 + NTP_4_2_5P144 + + ntpsnmpd/ntpsnmpd.1@1.13 +2 -2 + NTP_4_2_5P144 + + packageinfo.sh@1.147 +1 -1 + NTP_4_2_5P144 + + sntp/sntp-opts.c@1.132 +2 -2 + NTP_4_2_5P144 + + sntp/sntp-opts.h@1.132 +3 -3 + NTP_4_2_5P144 + + sntp/sntp-opts.texi@1.131 +1 -1 + NTP_4_2_5P144 + + sntp/sntp.1@1.131 +2 -2 + NTP_4_2_5P144 + + util/ntp-keygen-opts.c@1.135 +2 -2 + NTP_4_2_5P144 + + util/ntp-keygen-opts.h@1.135 +3 -3 + NTP_4_2_5P144 + + util/ntp-keygen-opts.texi@1.134 +1 -1 + NTP_4_2_5P144 + + util/ntp-keygen.1@1.134 +2 -2 + NTP_4_2_5P144 + +ChangeSet@1.1783, 2008-11-18 23:32:18+00:00, stenn@poog.il.thewrittenword.com + Use int32, not int32_t + + ChangeLog@1.256 +1 -0 + Use int32, not int32_t + + ntpdc/ntpdc_ops.c@1.56 +3 -3 + Use int32, not int32_t + +ChangeSet@1.1782, 2008-11-18 22:33:11+00:00, stenn@poog.il.thewrittenword.com + Avoid the sched*() functions under OSF - link problems + + ChangeLog@1.255 +1 -0 + Avoid the sched*() functions under OSF - link problems + + configure.ac@1.421 +5 -0 + Avoid the sched*() functions under OSF - link problems + +ChangeSet@1.1781, 2008-11-17 06:53:07-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P143 + TAG: NTP_4_2_5P143 + + ChangeLog@1.254 +1 -0 + NTP_4_2_5P143 + + gsoc_sntp/sntp-opts.c@1.4 +37 -7 + NTP_4_2_5P143 + + gsoc_sntp/sntp-opts.h@1.4 +77 -6 + NTP_4_2_5P143 + + gsoc_sntp/sntp-opts.texi@1.4 +1 -1 + NTP_4_2_5P143 + + gsoc_sntp/sntp.1@1.4 +7 -2 + NTP_4_2_5P143 + + ntpd/ntpd-opts.c@1.135 +2 -2 + NTP_4_2_5P143 + + ntpd/ntpd-opts.h@1.135 +3 -3 + NTP_4_2_5P143 + + ntpd/ntpd-opts.texi@1.134 +1 -1 + NTP_4_2_5P143 + + ntpd/ntpd.1@1.134 +2 -2 + NTP_4_2_5P143 + + ntpdc/ntpdc-opts.c@1.131 +2 -2 + NTP_4_2_5P143 + + ntpdc/ntpdc-opts.h@1.131 +3 -3 + NTP_4_2_5P143 + + ntpdc/ntpdc-opts.texi@1.130 +1 -1 + NTP_4_2_5P143 + + ntpdc/ntpdc.1@1.130 +2 -2 + NTP_4_2_5P143 + + ntpq/ntpq-opts.c@1.131 +2 -2 + NTP_4_2_5P143 + + ntpq/ntpq-opts.h@1.131 +3 -3 + NTP_4_2_5P143 + + ntpq/ntpq-opts.texi@1.130 +1 -1 + NTP_4_2_5P143 + + ntpq/ntpq.1@1.130 +2 -2 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd-opts.c@1.12 +2 -2 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd-opts.h@1.12 +3 -3 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd-opts.texi@1.12 +1 -1 + NTP_4_2_5P143 + + ntpsnmpd/ntpsnmpd.1@1.12 +2 -2 + NTP_4_2_5P143 + + packageinfo.sh@1.146 +1 -1 + NTP_4_2_5P143 + + sntp/sntp-opts.c@1.131 +2 -2 + NTP_4_2_5P143 + + sntp/sntp-opts.h@1.131 +3 -3 + NTP_4_2_5P143 + + sntp/sntp-opts.texi@1.130 +1 -1 + NTP_4_2_5P143 + + sntp/sntp.1@1.130 +2 -2 + NTP_4_2_5P143 + + util/ntp-keygen-opts.c@1.134 +2 -2 + NTP_4_2_5P143 + + util/ntp-keygen-opts.h@1.134 +3 -3 + NTP_4_2_5P143 + + util/ntp-keygen-opts.texi@1.133 +1 -1 + NTP_4_2_5P143 + + util/ntp-keygen.1@1.133 +2 -2 + NTP_4_2_5P143 + +ChangeSet@1.1780, 2008-11-17 03:29:26-05:00, stenn@whimsy.udel.edu + update generated files + + gsoc_sntp/sntp-opts.c@1.3 +7 -37 + update generated files + + gsoc_sntp/sntp-opts.h@1.3 +7 -78 + update generated files + + gsoc_sntp/sntp-opts.texi@1.3 +3 -3 + update generated files + + gsoc_sntp/sntp.1@1.3 +3 -8 + update generated files + +ChangeSet@1.1779, 2008-11-17 03:18:55-05:00, stenn@pogo.udel.edu + sntp cleanup and fixes + + ChangeLog@1.253 +1 -0 + sntp cleanup and fixes + +ChangeSet@1.1775.1.2, 2008-11-17 01:25:35+01:00, Amidamaru@melchior.mxiesoft.com + sntp-opts.def: + Set the normalverbose option to -d + + gsoc_sntp/sntp-opts.def@1.9 +1 -1 + Set the normalverbose option to -d + +ChangeSet@1.1775.1.1, 2008-11-17 01:16:44+01:00, Amidamaru@melchior.mxiesoft.com + utilities.h, utilities.c: + Added the tv_to_str function which converts a struct timeval to a timestamp string. + kod_management.c: + Replaced strlcpy with strncpy for compatibility reasons. + main.c: + Fixed the time difference report part and the set_time call part of bug #1088 + + gsoc_sntp/kod_management.c@1.7 +1 -1 + Replaced strlcpy with strncpy for compatibility reasons. + + gsoc_sntp/main.c@1.10 +23 -15 + Fixed the time difference report part and the set_time call part of bug #1088 + + gsoc_sntp/networking.c@1.16 +2 -2 + + gsoc_sntp/utilities.c@1.5 +36 -0 + Added the tv_to_str function which converts a struct timeval to a timestamp string. + + gsoc_sntp/utilities.h@1.4 +1 -0 + Added the tv_to_str function which converts a struct timeval to a timestamp string. + +ChangeSet@1.1777, 2008-11-16 07:03:17-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P142 + TAG: NTP_4_2_5P142 + + ChangeLog@1.252 +1 -0 + NTP_4_2_5P142 + + gsoc_sntp/sntp-opts.c@1.2 +2 -2 + NTP_4_2_5P142 + + gsoc_sntp/sntp-opts.h@1.2 +3 -3 + NTP_4_2_5P142 + + gsoc_sntp/sntp-opts.texi@1.2 +1 -1 + NTP_4_2_5P142 + + gsoc_sntp/sntp.1@1.2 +2 -2 + NTP_4_2_5P142 + + ntpd/ntpd-opts.c@1.134 +2 -2 + NTP_4_2_5P142 + + ntpd/ntpd-opts.h@1.134 +3 -3 + NTP_4_2_5P142 + + ntpd/ntpd-opts.texi@1.133 +1 -1 + NTP_4_2_5P142 + + ntpd/ntpd.1@1.133 +2 -2 + NTP_4_2_5P142 + + ntpdc/ntpdc-opts.c@1.130 +2 -2 + NTP_4_2_5P142 + + ntpdc/ntpdc-opts.h@1.130 +3 -3 + NTP_4_2_5P142 + + ntpdc/ntpdc-opts.texi@1.129 +1 -1 + NTP_4_2_5P142 + + ntpdc/ntpdc.1@1.129 +2 -2 + NTP_4_2_5P142 + + ntpq/ntpq-opts.c@1.130 +2 -2 + NTP_4_2_5P142 + + ntpq/ntpq-opts.h@1.130 +3 -3 + NTP_4_2_5P142 + + ntpq/ntpq-opts.texi@1.129 +1 -1 + NTP_4_2_5P142 + + ntpq/ntpq.1@1.129 +2 -2 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd-opts.c@1.11 +2 -2 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd-opts.h@1.11 +3 -3 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd-opts.texi@1.11 +1 -1 + NTP_4_2_5P142 + + ntpsnmpd/ntpsnmpd.1@1.11 +2 -2 + NTP_4_2_5P142 + + packageinfo.sh@1.145 +1 -1 + NTP_4_2_5P142 + + sntp/sntp-opts.c@1.130 +2 -2 + NTP_4_2_5P142 + + sntp/sntp-opts.h@1.130 +3 -3 + NTP_4_2_5P142 + + sntp/sntp-opts.texi@1.129 +1 -1 + NTP_4_2_5P142 + + sntp/sntp.1@1.129 +2 -2 + NTP_4_2_5P142 + + util/ntp-keygen-opts.c@1.133 +2 -2 + NTP_4_2_5P142 + + util/ntp-keygen-opts.h@1.133 +3 -3 + NTP_4_2_5P142 + + util/ntp-keygen-opts.texi@1.132 +1 -1 + NTP_4_2_5P142 + + util/ntp-keygen.1@1.132 +2 -2 + NTP_4_2_5P142 + +ChangeSet@1.1776, 2008-11-16 02:16:42-05:00, stenn@whimsy.udel.edu + Imported GSoC SNTP code from Johannes Maximilian Khn + + .point-changed-filelist@1.5 +4 -0 + Add gsoc-sntp files to .point-changed-filelist + + BitKeeper/deleted/.del-bincheck.mf@1.2 +0 -0 + Delete: gsoc_sntp/bincheck.mf + + gsoc_sntp/bincheck.mf@1.1 +15 -0 + BitKeeper file /deacon/backroom/ntp-dev/gsoc_sntp/bincheck.mf + + gsoc_sntp/bincheck.mf@1.0 +0 -0 + + BitKeeper/etc/ignore@1.68 +14 -14 + Added gsoc_sntp files to the ignore list + + ChangeLog@1.251 +1 -0 + Imported GSoC SNTP code from Johannes Maximilian Khn + + bootstrap@1.22 +1 -0 + Add gsoc_sntp files t bootstrap + +ChangeSet@1.1774, 2008-11-15 16:06:12-05:00, stenn@pogo.udel.edu + Hack gsoc_sntp for inclusion in the main tree + + BitKeeper/etc/ignore@1.67 +1 -0 + added bincheck.mf + + BitKeeper/etc/ignore@1.66 +1 -0 + added autogen-version.def + + BitKeeper/etc/ignore@1.65 +1 -0 + added version.def + + gsoc_sntp/COPYRIGHT@1.1 +0 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/COPYRIGHT + + gsoc_sntp/COPYRIGHT@1.0 +0 -0 + + gsoc_sntp/Makefile.am@1.5 +44 -16 + Hack gsoc_sntp for inclusion in the main tree + + gsoc_sntp/configure.ac@1.5 +19 -2 + Hack gsoc_sntp for inclusion in the main tree + + gsoc_sntp/ltmain.sh@1.1 +6863 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/ltmain.sh + + gsoc_sntp/ltmain.sh@1.0 +0 -0 + + gsoc_sntp/sntp-opts.c@1.1 +638 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.c + + gsoc_sntp/sntp-opts.c@1.0 +0 -0 + + gsoc_sntp/sntp-opts.h@1.1 +234 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.h + + gsoc_sntp/sntp-opts.h@1.0 +0 -0 + + gsoc_sntp/sntp-opts.menu@1.1 +1 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.menu + + gsoc_sntp/sntp-opts.menu@1.0 +0 -0 + + gsoc_sntp/sntp-opts.texi@1.1 +208 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp-opts.texi + + gsoc_sntp/sntp-opts.texi@1.0 +0 -0 + + gsoc_sntp/sntp.1@1.1 +298 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/sntp.1 + + gsoc_sntp/sntp.1@1.0 +0 -0 + +ChangeSet@1.1771.1.1, 2008-11-14 17:32:58-05:00, stenn@pogo.udel.edu + updates + + gsoc_sntp/:fetch-stubs@1.4 +0 -12 + updates + +ChangeSet@1.1735.1.72, 2008-11-13 06:42:06-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P141 + TAG: NTP_4_2_5P141 + + ChangeLog@1.250 +1 -0 + NTP_4_2_5P141 + + ntpd/ntpd-opts.c@1.133 +2 -2 + NTP_4_2_5P141 + + ntpd/ntpd-opts.h@1.133 +3 -3 + NTP_4_2_5P141 + + ntpd/ntpd-opts.texi@1.132 +1 -1 + NTP_4_2_5P141 + + ntpd/ntpd.1@1.132 +2 -2 + NTP_4_2_5P141 + + ntpdc/ntpdc-opts.c@1.129 +2 -2 + NTP_4_2_5P141 + + ntpdc/ntpdc-opts.h@1.129 +3 -3 + NTP_4_2_5P141 + + ntpdc/ntpdc-opts.texi@1.128 +1 -1 + NTP_4_2_5P141 + + ntpdc/ntpdc.1@1.128 +2 -2 + NTP_4_2_5P141 + + ntpq/ntpq-opts.c@1.129 +2 -2 + NTP_4_2_5P141 + + ntpq/ntpq-opts.h@1.129 +3 -3 + NTP_4_2_5P141 + + ntpq/ntpq-opts.texi@1.128 +1 -1 + NTP_4_2_5P141 + + ntpq/ntpq.1@1.128 +2 -2 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd-opts.c@1.10 +2 -2 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd-opts.h@1.10 +3 -3 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd-opts.texi@1.10 +1 -1 + NTP_4_2_5P141 + + ntpsnmpd/ntpsnmpd.1@1.10 +2 -2 + NTP_4_2_5P141 + + packageinfo.sh@1.144 +1 -1 + NTP_4_2_5P141 + + sntp/sntp-opts.c@1.129 +2 -2 + NTP_4_2_5P141 + + sntp/sntp-opts.h@1.129 +3 -3 + NTP_4_2_5P141 + + sntp/sntp-opts.texi@1.128 +1 -1 + NTP_4_2_5P141 + + sntp/sntp.1@1.128 +2 -2 + NTP_4_2_5P141 + + util/ntp-keygen-opts.c@1.132 +2 -2 + NTP_4_2_5P141 + + util/ntp-keygen-opts.h@1.132 +3 -3 + NTP_4_2_5P141 + + util/ntp-keygen-opts.texi@1.131 +1 -1 + NTP_4_2_5P141 + + util/ntp-keygen.1@1.131 +2 -2 + NTP_4_2_5P141 + +ChangeSet@1.1735.1.71, 2008-11-12 16:09:45-05:00, stenn@whimsy.udel.edu + New caltontp.c and calyearstart.c from Juergen Perlinger + + ChangeLog@1.249 +1 -0 + New caltontp.c and calyearstart.c from Juergen Perlinger + + libntp/caltontp.c@1.3 +88 -25 + New caltontp.c and calyearstart.c from Juergen Perlinger + + libntp/calyearstart.c@1.3 +38 -7 + New caltontp.c and calyearstart.c from Juergen Perlinger + +ChangeSet@1.1735.1.70, 2008-11-12 06:43:31-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P140 + TAG: NTP_4_2_5P140 + + ChangeLog@1.248 +1 -0 + NTP_4_2_5P140 + + ntpd/ntpd-opts.c@1.132 +2 -2 + NTP_4_2_5P140 + + ntpd/ntpd-opts.h@1.132 +3 -3 + NTP_4_2_5P140 + + ntpd/ntpd-opts.texi@1.131 +1 -1 + NTP_4_2_5P140 + + ntpd/ntpd.1@1.131 +2 -2 + NTP_4_2_5P140 + + ntpdc/ntpdc-opts.c@1.128 +2 -2 + NTP_4_2_5P140 + + ntpdc/ntpdc-opts.h@1.128 +3 -3 + NTP_4_2_5P140 + + ntpdc/ntpdc-opts.texi@1.127 +1 -1 + NTP_4_2_5P140 + + ntpdc/ntpdc.1@1.127 +2 -2 + NTP_4_2_5P140 + + ntpq/ntpq-opts.c@1.128 +2 -2 + NTP_4_2_5P140 + + ntpq/ntpq-opts.h@1.128 +3 -3 + NTP_4_2_5P140 + + ntpq/ntpq-opts.texi@1.127 +1 -1 + NTP_4_2_5P140 + + ntpq/ntpq.1@1.127 +2 -2 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd-opts.c@1.9 +2 -2 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd-opts.h@1.9 +3 -3 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd-opts.texi@1.9 +1 -1 + NTP_4_2_5P140 + + ntpsnmpd/ntpsnmpd.1@1.9 +2 -2 + NTP_4_2_5P140 + + packageinfo.sh@1.143 +1 -1 + NTP_4_2_5P140 + + sntp/sntp-opts.c@1.128 +2 -2 + NTP_4_2_5P140 + + sntp/sntp-opts.h@1.128 +3 -3 + NTP_4_2_5P140 + + sntp/sntp-opts.texi@1.127 +1 -1 + NTP_4_2_5P140 + + sntp/sntp.1@1.127 +2 -2 + NTP_4_2_5P140 + + util/ntp-keygen-opts.c@1.131 +2 -2 + NTP_4_2_5P140 + + util/ntp-keygen-opts.h@1.131 +3 -3 + NTP_4_2_5P140 + + util/ntp-keygen-opts.texi@1.130 +1 -1 + NTP_4_2_5P140 + + util/ntp-keygen.1@1.130 +2 -2 + NTP_4_2_5P140 + +ChangeSet@1.1735.1.69, 2008-11-12 02:36:31-05:00, stenn@whimsy.udel.edu + ntp_scanner lint removal + + ChangeLog@1.247 +1 -0 + ntp_scanner lint removal + + ntpd/ntp_scanner.c@1.15 +2 -1 + ntp_scanner lint removal + + ntpd/ntp_scanner.h@1.4 +1 -1 + ntp_scanner lint removal + +ChangeSet@1.1735.1.68, 2008-11-12 02:18:18-05:00, stenn@pogo.udel.edu + Reindent ntp_scanner.c + + ntpd/ntp_scanner.c@1.14 +109 -65 + Reindent ntp_scanner.c + +ChangeSet@1.1735.1.67, 2008-11-11 16:49:27-05:00, stenn@whimsy.udel.edu + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + + ChangeLog@1.246 +2 -0 + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + + libntp/caljulian.c@1.8 +121 -86 + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + + libntp/prettydate.c@1.7 +107 -39 + [Bug 1011] gmtime() returns NULL on windows where it would not under Unix + +ChangeSet@1.1735.1.66, 2008-11-11 06:42:25-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P139 + TAG: NTP_4_2_5P139 + + ChangeLog@1.245 +1 -0 + NTP_4_2_5P139 + + ntpd/ntpd-opts.c@1.131 +2 -2 + NTP_4_2_5P139 + + ntpd/ntpd-opts.h@1.131 +3 -3 + NTP_4_2_5P139 + + ntpd/ntpd-opts.texi@1.130 +1 -1 + NTP_4_2_5P139 + + ntpd/ntpd.1@1.130 +2 -2 + NTP_4_2_5P139 + + ntpdc/ntpdc-opts.c@1.127 +2 -2 + NTP_4_2_5P139 + + ntpdc/ntpdc-opts.h@1.127 +3 -3 + NTP_4_2_5P139 + + ntpdc/ntpdc-opts.texi@1.126 +1 -1 + NTP_4_2_5P139 + + ntpdc/ntpdc.1@1.126 +2 -2 + NTP_4_2_5P139 + + ntpq/ntpq-opts.c@1.127 +2 -2 + NTP_4_2_5P139 + + ntpq/ntpq-opts.h@1.127 +3 -3 + NTP_4_2_5P139 + + ntpq/ntpq-opts.texi@1.126 +1 -1 + NTP_4_2_5P139 + + ntpq/ntpq.1@1.126 +2 -2 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd-opts.c@1.8 +2 -2 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd-opts.h@1.8 +3 -3 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd-opts.texi@1.8 +1 -1 + NTP_4_2_5P139 + + ntpsnmpd/ntpsnmpd.1@1.8 +2 -2 + NTP_4_2_5P139 + + packageinfo.sh@1.142 +1 -1 + NTP_4_2_5P139 + + sntp/sntp-opts.c@1.127 +2 -2 + NTP_4_2_5P139 + + sntp/sntp-opts.h@1.127 +3 -3 + NTP_4_2_5P139 + + sntp/sntp-opts.texi@1.126 +1 -1 + NTP_4_2_5P139 + + sntp/sntp.1@1.126 +2 -2 + NTP_4_2_5P139 + + util/ntp-keygen-opts.c@1.130 +2 -2 + NTP_4_2_5P139 + + util/ntp-keygen-opts.h@1.130 +3 -3 + NTP_4_2_5P139 + + util/ntp-keygen-opts.texi@1.129 +1 -1 + NTP_4_2_5P139 + + util/ntp-keygen.1@1.129 +2 -2 + NTP_4_2_5P139 + +ChangeSet@1.1735.1.65, 2008-11-11 01:39:34-05:00, stenn@whimsy.udel.edu + Typo fix to driver20.html + + ChangeLog@1.244 +1 -0 + Typo fix to driver20.html + + html/drivers/driver20.html@1.17 +1 -1 + Typo fix to driver20.html + +ChangeSet@1.1735.1.64, 2008-11-10 06:44:15-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P138 + TAG: NTP_4_2_5P138 + + ChangeLog@1.243 +1 -0 + NTP_4_2_5P138 + + ntpd/ntpd-opts.c@1.130 +2 -2 + NTP_4_2_5P138 + + ntpd/ntpd-opts.h@1.130 +3 -3 + NTP_4_2_5P138 + + ntpd/ntpd-opts.texi@1.129 +1 -1 + NTP_4_2_5P138 + + ntpd/ntpd.1@1.129 +2 -2 + NTP_4_2_5P138 + + ntpdc/ntpdc-opts.c@1.126 +2 -2 + NTP_4_2_5P138 + + ntpdc/ntpdc-opts.h@1.126 +3 -3 + NTP_4_2_5P138 + + ntpdc/ntpdc-opts.texi@1.125 +1 -1 + NTP_4_2_5P138 + + ntpdc/ntpdc.1@1.125 +2 -2 + NTP_4_2_5P138 + + ntpq/ntpq-opts.c@1.126 +2 -2 + NTP_4_2_5P138 + + ntpq/ntpq-opts.h@1.126 +3 -3 + NTP_4_2_5P138 + + ntpq/ntpq-opts.texi@1.125 +1 -1 + NTP_4_2_5P138 + + ntpq/ntpq.1@1.125 +2 -2 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd-opts.c@1.7 +2 -2 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd-opts.h@1.7 +3 -3 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd-opts.texi@1.7 +1 -1 + NTP_4_2_5P138 + + ntpsnmpd/ntpsnmpd.1@1.7 +2 -2 + NTP_4_2_5P138 + + packageinfo.sh@1.141 +1 -1 + NTP_4_2_5P138 + + sntp/sntp-opts.c@1.126 +2 -2 + NTP_4_2_5P138 + + sntp/sntp-opts.h@1.126 +3 -3 + NTP_4_2_5P138 + + sntp/sntp-opts.texi@1.125 +1 -1 + NTP_4_2_5P138 + + sntp/sntp.1@1.125 +2 -2 + NTP_4_2_5P138 + + util/ntp-keygen-opts.c@1.129 +2 -2 + NTP_4_2_5P138 + + util/ntp-keygen-opts.h@1.129 +3 -3 + NTP_4_2_5P138 + + util/ntp-keygen-opts.texi@1.128 +1 -1 + NTP_4_2_5P138 + + util/ntp-keygen.1@1.128 +2 -2 + NTP_4_2_5P138 + +ChangeSet@1.1735.1.63, 2008-11-10 02:00:40-05:00, stenn@whimsy.udel.edu + IPv6 interfaces were being looked for twice; fix bug 474 + + ChangeLog@1.242 +2 -0 + IPv6 interfaces were being looked for twice; fix bug 474 + + ntpd/ntp_io.c@1.274 +1 -8 + IPv6 interfaces were being looked for twice; fix bug 474 + +ChangeSet@1.1735.1.62, 2008-11-09 23:19:25-05:00, stenn@pogo.udel.edu + Used ntp-4.2.5p138 instead of the date + + html/drivers/driver28.html@1.12 +1 -1 + Used ntp-4.2.5p138 instead of the date + +ChangeSet@1.1735.8.7, 2008-11-09 22:38:13-05:00, stenn@whimsy.udel.edu + decode.html and driver20.html updates from Dave Mills + + ChangeLog@1.238.1.5 +1 -0 + decode.html and driver20.html updates from Dave Mills + + html/decode.html@1.4 +12 -6 + decode.html and driver20.html updates from Dave Mills + + html/drivers/driver20.html@1.16 +1 -1 + decode.html and driver20.html updates from Dave Mills + +ChangeSet@1.1735.8.6, 2008-11-01 06:46:41-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P137 + TAG: NTP_4_2_5P137 + + ChangeLog@1.238.1.4 +1 -0 + NTP_4_2_5P137 + + ntpd/ntpd-opts.c@1.129 +2 -2 + NTP_4_2_5P137 + + ntpd/ntpd-opts.h@1.129 +3 -3 + NTP_4_2_5P137 + + ntpd/ntpd-opts.texi@1.128 +1 -1 + NTP_4_2_5P137 + + ntpd/ntpd.1@1.128 +2 -2 + NTP_4_2_5P137 + + ntpdc/ntpdc-opts.c@1.125 +2 -2 + NTP_4_2_5P137 + + ntpdc/ntpdc-opts.h@1.125 +3 -3 + NTP_4_2_5P137 + + ntpdc/ntpdc-opts.texi@1.124 +1 -1 + NTP_4_2_5P137 + + ntpdc/ntpdc.1@1.124 +2 -2 + NTP_4_2_5P137 + + ntpq/ntpq-opts.c@1.125 +2 -2 + NTP_4_2_5P137 + + ntpq/ntpq-opts.h@1.125 +3 -3 + NTP_4_2_5P137 + + ntpq/ntpq-opts.texi@1.124 +1 -1 + NTP_4_2_5P137 + + ntpq/ntpq.1@1.124 +2 -2 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd-opts.c@1.6 +2 -2 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd-opts.h@1.6 +3 -3 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd-opts.texi@1.6 +1 -1 + NTP_4_2_5P137 + + ntpsnmpd/ntpsnmpd.1@1.6 +2 -2 + NTP_4_2_5P137 + + packageinfo.sh@1.140 +1 -1 + NTP_4_2_5P137 + + sntp/sntp-opts.c@1.125 +2 -2 + NTP_4_2_5P137 + + sntp/sntp-opts.h@1.125 +3 -3 + NTP_4_2_5P137 + + sntp/sntp-opts.texi@1.124 +1 -1 + NTP_4_2_5P137 + + sntp/sntp.1@1.124 +2 -2 + NTP_4_2_5P137 + + util/ntp-keygen-opts.c@1.128 +2 -2 + NTP_4_2_5P137 + + util/ntp-keygen-opts.h@1.128 +3 -3 + NTP_4_2_5P137 + + util/ntp-keygen-opts.texi@1.127 +1 -1 + NTP_4_2_5P137 + + util/ntp-keygen.1@1.127 +2 -2 + NTP_4_2_5P137 + +ChangeSet@1.1735.8.5, 2008-11-01 00:22:33-05:00, stenn@whimsy.udel.edu + netsnmp_daemonize lib check cleanup + + configure.ac@1.417.1.5 +1 -1 + netsnmp_daemonize lib check cleanup + +ChangeSet@1.1735.8.4, 2008-10-31 23:31:45-05:00, stenn@whimsy.udel.edu + [Bug 1069] #undef netsnmp's PACKAGE_* macros + + ChangeLog@1.238.1.3 +2 -0 + [Bug 1069] #undef netsnmp's PACKAGE_* macros + + ntpsnmpd/ntpsnmpd.c@1.3 +6 -0 + [Bug 1069] #undef netsnmp's PACKAGE_* macros + +ChangeSet@1.1735.8.3, 2008-10-31 23:27:50-05:00, stenn@whimsy.udel.edu + [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize() + + configure.ac@1.417.1.4 +12 -0 + [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize() + + ntpsnmpd/Makefile.am@1.6 +1 -1 + [Bug 1068] Older versions of netsnmp do not have netsnmp_daemonize() + + ntpsnmpd/netsnmp_daemonize.c@1.1 +266 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/netsnmp_daemonize.c + + ntpsnmpd/netsnmp_daemonize.c@1.0 +0 -0 + +ChangeSet@1.1735.8.2, 2008-10-27 06:43:43-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P136 + TAG: NTP_4_2_5P136 + + ChangeLog@1.238.1.2 +1 -0 + NTP_4_2_5P136 + + ntpd/ntpd-opts.c@1.128 +2 -2 + NTP_4_2_5P136 + + ntpd/ntpd-opts.h@1.128 +3 -3 + NTP_4_2_5P136 + + ntpd/ntpd-opts.texi@1.127 +1 -1 + NTP_4_2_5P136 + + ntpd/ntpd.1@1.127 +2 -2 + NTP_4_2_5P136 + + ntpdc/ntpdc-opts.c@1.124 +2 -2 + NTP_4_2_5P136 + + ntpdc/ntpdc-opts.h@1.124 +3 -3 + NTP_4_2_5P136 + + ntpdc/ntpdc-opts.texi@1.123 +1 -1 + NTP_4_2_5P136 + + ntpdc/ntpdc.1@1.123 +2 -2 + NTP_4_2_5P136 + + ntpq/ntpq-opts.c@1.124 +2 -2 + NTP_4_2_5P136 + + ntpq/ntpq-opts.h@1.124 +3 -3 + NTP_4_2_5P136 + + ntpq/ntpq-opts.texi@1.123 +1 -1 + NTP_4_2_5P136 + + ntpq/ntpq.1@1.123 +2 -2 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd-opts.c@1.5 +2 -2 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd-opts.h@1.5 +3 -3 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd-opts.texi@1.5 +1 -1 + NTP_4_2_5P136 + + ntpsnmpd/ntpsnmpd.1@1.5 +2 -2 + NTP_4_2_5P136 + + packageinfo.sh@1.139 +1 -1 + NTP_4_2_5P136 + + sntp/sntp-opts.c@1.124 +2 -2 + NTP_4_2_5P136 + + sntp/sntp-opts.h@1.124 +3 -3 + NTP_4_2_5P136 + + sntp/sntp-opts.texi@1.123 +1 -1 + NTP_4_2_5P136 + + sntp/sntp.1@1.123 +2 -2 + NTP_4_2_5P136 + + util/ntp-keygen-opts.c@1.127 +2 -2 + NTP_4_2_5P136 + + util/ntp-keygen-opts.h@1.127 +3 -3 + NTP_4_2_5P136 + + util/ntp-keygen-opts.texi@1.126 +1 -1 + NTP_4_2_5P136 + + util/ntp-keygen.1@1.126 +2 -2 + NTP_4_2_5P136 + +ChangeSet@1.1735.8.1, 2008-10-27 02:20:45-05:00, stenn@whimsy.udel.edu + [Bug 1078] statsdir configuration parsing is broken + + ChangeLog@1.238.1.1 +1 -0 + [Bug 1078] statsdir configuration parsing is broken + + ntpd/ntp_util.c@1.67 +1 -1 + [Bug 1078] statsdir configuration parsing is broken + +ChangeSet@1.1735.1.59, 2008-10-23 19:21:21-04:00, murray@pogo.udel.edu + ChangeLog: + SHM fix. + driver28.html: + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + refclock_shm.c: + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + + ChangeLog@1.239 +1 -0 + SHM fix. + + html/drivers/driver28.html@1.11 +56 -9 + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + + ntpd/refclock_shm.c@1.18 +151 -51 + Fix to probe once per second rather + than once per polling interval. + Add clockstats for debugging if flag4 is on. (just counters) + +ChangeSet@1.1735.1.58, 2008-09-23 07:43:30-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P135 + TAG: NTP_4_2_5P135 + + ChangeLog@1.238 +1 -0 + NTP_4_2_5P135 + + ntpd/ntpd-opts.c@1.127 +2 -2 + NTP_4_2_5P135 + + ntpd/ntpd-opts.h@1.127 +3 -3 + NTP_4_2_5P135 + + ntpd/ntpd-opts.texi@1.126 +2 -2 + NTP_4_2_5P135 + + ntpd/ntpd.1@1.126 +2 -2 + NTP_4_2_5P135 + + ntpdc/ntpdc-opts.c@1.123 +2 -2 + NTP_4_2_5P135 + + ntpdc/ntpdc-opts.h@1.123 +3 -3 + NTP_4_2_5P135 + + ntpdc/ntpdc-opts.texi@1.122 +2 -2 + NTP_4_2_5P135 + + ntpdc/ntpdc.1@1.122 +2 -2 + NTP_4_2_5P135 + + ntpq/ntpq-opts.c@1.123 +2 -2 + NTP_4_2_5P135 + + ntpq/ntpq-opts.h@1.123 +3 -3 + NTP_4_2_5P135 + + ntpq/ntpq-opts.texi@1.122 +2 -2 + NTP_4_2_5P135 + + ntpq/ntpq.1@1.122 +2 -2 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd-opts.c@1.4 +2 -2 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd-opts.h@1.4 +3 -3 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd-opts.texi@1.4 +1 -1 + NTP_4_2_5P135 + + ntpsnmpd/ntpsnmpd.1@1.4 +2 -2 + NTP_4_2_5P135 + + packageinfo.sh@1.138 +1 -1 + NTP_4_2_5P135 + + sntp/sntp-opts.c@1.123 +2 -2 + NTP_4_2_5P135 + + sntp/sntp-opts.h@1.123 +3 -3 + NTP_4_2_5P135 + + sntp/sntp-opts.texi@1.122 +1 -1 + NTP_4_2_5P135 + + sntp/sntp.1@1.122 +2 -2 + NTP_4_2_5P135 + + util/ntp-keygen-opts.c@1.126 +2 -2 + NTP_4_2_5P135 + + util/ntp-keygen-opts.h@1.126 +3 -3 + NTP_4_2_5P135 + + util/ntp-keygen-opts.texi@1.125 +2 -2 + NTP_4_2_5P135 + + util/ntp-keygen.1@1.125 +2 -2 + NTP_4_2_5P135 + +ChangeSet@1.1735.1.57, 2008-09-22 20:30:50-04:00, stenn@whimsy.udel.edu + [Bug 1072] clock_update should not allow updates older than sys_epoch + + ChangeLog@1.237 +1 -0 + [Bug 1072] clock_update should not allow updates older than sys_epoch + + ntpd/ntp_proto.c@1.276 +3 -3 + [Bug 1072] clock_update should not allow updates older than sys_epoch + +ChangeSet@1.1735.1.56, 2008-09-17 07:46:56-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P134 + TAG: NTP_4_2_5P134 + + ChangeLog@1.236 +1 -0 + NTP_4_2_5P134 + + ntpd/ntpd-opts.c@1.126 +2 -2 + NTP_4_2_5P134 + + ntpd/ntpd-opts.h@1.126 +3 -3 + NTP_4_2_5P134 + + ntpd/ntpd-opts.texi@1.125 +1 -1 + NTP_4_2_5P134 + + ntpd/ntpd.1@1.125 +2 -2 + NTP_4_2_5P134 + + ntpdc/ntpdc-opts.c@1.122 +2 -2 + NTP_4_2_5P134 + + ntpdc/ntpdc-opts.h@1.122 +3 -3 + NTP_4_2_5P134 + + ntpdc/ntpdc-opts.texi@1.121 +1 -1 + NTP_4_2_5P134 + + ntpdc/ntpdc.1@1.121 +2 -2 + NTP_4_2_5P134 + + ntpq/ntpq-opts.c@1.122 +2 -2 + NTP_4_2_5P134 + + ntpq/ntpq-opts.h@1.122 +3 -3 + NTP_4_2_5P134 + + ntpq/ntpq-opts.texi@1.121 +1 -1 + NTP_4_2_5P134 + + ntpq/ntpq.1@1.121 +2 -2 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd-opts.c@1.3 +2 -2 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd-opts.h@1.3 +3 -3 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd-opts.texi@1.3 +1 -1 + NTP_4_2_5P134 + + ntpsnmpd/ntpsnmpd.1@1.3 +2 -2 + NTP_4_2_5P134 + + packageinfo.sh@1.137 +1 -1 + NTP_4_2_5P134 + + sntp/sntp-opts.c@1.122 +2 -2 + NTP_4_2_5P134 + + sntp/sntp-opts.h@1.122 +3 -3 + NTP_4_2_5P134 + + sntp/sntp-opts.texi@1.121 +1 -1 + NTP_4_2_5P134 + + sntp/sntp.1@1.121 +2 -2 + NTP_4_2_5P134 + + util/ntp-keygen-opts.c@1.125 +2 -2 + NTP_4_2_5P134 + + util/ntp-keygen-opts.h@1.125 +3 -3 + NTP_4_2_5P134 + + util/ntp-keygen-opts.texi@1.124 +1 -1 + NTP_4_2_5P134 + + util/ntp-keygen.1@1.124 +2 -2 + NTP_4_2_5P134 + +ChangeSet@1.1735.1.55, 2008-09-16 21:05:36-04:00, stenn@whimsy.udel.edu + Clean up build process for ntpsnmpd. + + ChangeLog@1.235 +1 -0 + Clean up build process for ntpsnmpd. + + Makefile.am@1.76.1.2 +1 -1 + Clean up build process for ntpsnmpd. + + configure.ac@1.417.1.3 +2 -2 + Clean up build process for ntpsnmpd. + + ntpsnmpd/Makefile.am@1.5 +2 -1 + Clean up build process for ntpsnmpd. + +ChangeSet@1.1735.1.54, 2008-09-16 19:12:17-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P133 + TAG: NTP_4_2_5P133 + + ChangeLog@1.234 +1 -0 + NTP_4_2_5P133 + + ntpd/ntpd-opts.c@1.125 +2 -2 + NTP_4_2_5P133 + + ntpd/ntpd-opts.h@1.125 +3 -3 + NTP_4_2_5P133 + + ntpd/ntpd-opts.texi@1.124 +1 -1 + NTP_4_2_5P133 + + ntpd/ntpd.1@1.124 +2 -2 + NTP_4_2_5P133 + + ntpdc/ntpdc-opts.c@1.121 +2 -2 + NTP_4_2_5P133 + + ntpdc/ntpdc-opts.h@1.121 +3 -3 + NTP_4_2_5P133 + + ntpdc/ntpdc-opts.texi@1.120 +1 -1 + NTP_4_2_5P133 + + ntpdc/ntpdc.1@1.120 +2 -2 + NTP_4_2_5P133 + + ntpq/ntpq-opts.c@1.121 +2 -2 + NTP_4_2_5P133 + + ntpq/ntpq-opts.h@1.121 +3 -3 + NTP_4_2_5P133 + + ntpq/ntpq-opts.texi@1.120 +1 -1 + NTP_4_2_5P133 + + ntpq/ntpq.1@1.120 +2 -2 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd-opts.c@1.2 +2 -2 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd-opts.h@1.2 +3 -3 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd-opts.texi@1.2 +1 -1 + NTP_4_2_5P133 + + ntpsnmpd/ntpsnmpd.1@1.2 +2 -2 + NTP_4_2_5P133 + + packageinfo.sh@1.136 +1 -1 + NTP_4_2_5P133 + + sntp/sntp-opts.c@1.121 +2 -2 + NTP_4_2_5P133 + + sntp/sntp-opts.h@1.121 +3 -3 + NTP_4_2_5P133 + + sntp/sntp-opts.texi@1.120 +1 -1 + NTP_4_2_5P133 + + sntp/sntp.1@1.120 +2 -2 + NTP_4_2_5P133 + + util/ntp-keygen-opts.c@1.124 +2 -2 + NTP_4_2_5P133 + + util/ntp-keygen-opts.h@1.124 +3 -3 + NTP_4_2_5P133 + + util/ntp-keygen-opts.texi@1.123 +1 -1 + NTP_4_2_5P133 + + util/ntp-keygen.1@1.123 +2 -2 + NTP_4_2_5P133 + +ChangeSet@1.1735.1.53, 2008-09-16 03:34:05-04:00, stenn@whimsy.udel.edu + Add options processing to ntpsnmpd. + + .point-changed-filelist@1.4 +4 -0 + Add options processing to ntpsnmpd. + + ChangeLog@1.233 +1 -0 + Add options processing to ntpsnmpd. + + ntpsnmpd/Makefile.am@1.4 +26 -3 + Add options processing to ntpsnmpd. + + ntpsnmpd/ntpsnmpd-opts.c@1.1 +398 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.c + + ntpsnmpd/ntpsnmpd-opts.c@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd-opts.def@1.1 +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.def + + ntpsnmpd/ntpsnmpd-opts.def@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd-opts.h@1.1 +160 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.h + + ntpsnmpd/ntpsnmpd-opts.h@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd-opts.menu@1.1 +1 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.menu + + ntpsnmpd/ntpsnmpd-opts.menu@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd-opts.texi@1.1 +52 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd-opts.texi + + ntpsnmpd/ntpsnmpd-opts.texi@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.1@1.1 +77 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpsnmpd/ntpsnmpd.1 + + ntpsnmpd/ntpsnmpd.1@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.c@1.2 +24 -8 + Add options processing to ntpsnmpd. + +ChangeSet@1.1735.1.52, 2008-09-16 05:40:31+00:00, stenn@ntp1.isc.org + [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. + + ChangeLog@1.232 +1 -0 + [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. + + configure.ac@1.417.1.2 +10 -1 + [Bug 1062] Check net-snmp headers before deciding to build ntpsnmpd. + +ChangeSet@1.1735.1.51, 2008-09-15 23:06:04-04:00, stenn@whimsy.udel.edu + Clean up the libntpq.a build. + + ChangeLog@1.231 +1 -0 + Clean up the libntpq.a build. + + ntpq/Makefile.am@1.33 +2 -1 + Clean up the libntpq.a build. + +ChangeSet@1.1735.1.50, 2008-09-15 21:15:48-04:00, stenn@whimsy.udel.edu + Regenerate ntp_parser.[ch] from ntp_parser.y + + ChangeLog@1.230 +1 -0 + Regenerate ntp_parser.[ch] from ntp_parser.y + + ntpd/ntp_parser.c@1.31 +8 -8 + Regenerate ntp_parser.[ch] from ntp_parser.y + + ntpd/ntp_parser.h@1.15 +1 -1 + Regenerate ntp_parser.[ch] from ntp_parser.y + +ChangeSet@1.1735.1.49, 2008-09-15 07:43:30-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P132 + TAG: NTP_4_2_5P132 + + ChangeLog@1.229 +1 -0 + NTP_4_2_5P132 + + ntpd/ntpd-opts.c@1.124 +2 -2 + NTP_4_2_5P132 + + ntpd/ntpd-opts.h@1.124 +3 -3 + NTP_4_2_5P132 + + ntpd/ntpd-opts.texi@1.123 +1 -1 + NTP_4_2_5P132 + + ntpd/ntpd.1@1.123 +2 -2 + NTP_4_2_5P132 + + ntpdc/ntpdc-opts.c@1.120 +2 -2 + NTP_4_2_5P132 + + ntpdc/ntpdc-opts.h@1.120 +3 -3 + NTP_4_2_5P132 + + ntpdc/ntpdc-opts.texi@1.119 +1 -1 + NTP_4_2_5P132 + + ntpdc/ntpdc.1@1.119 +2 -2 + NTP_4_2_5P132 + + ntpq/ntpq-opts.c@1.120 +2 -2 + NTP_4_2_5P132 + + ntpq/ntpq-opts.h@1.120 +3 -3 + NTP_4_2_5P132 + + ntpq/ntpq-opts.texi@1.119 +1 -1 + NTP_4_2_5P132 + + ntpq/ntpq.1@1.119 +2 -2 + NTP_4_2_5P132 + + packageinfo.sh@1.135 +1 -1 + NTP_4_2_5P132 + + sntp/sntp-opts.c@1.120 +2 -2 + NTP_4_2_5P132 + + sntp/sntp-opts.h@1.120 +3 -3 + NTP_4_2_5P132 + + sntp/sntp-opts.texi@1.119 +1 -1 + NTP_4_2_5P132 + + sntp/sntp.1@1.119 +2 -2 + NTP_4_2_5P132 + + util/ntp-keygen-opts.c@1.123 +2 -2 + NTP_4_2_5P132 + + util/ntp-keygen-opts.h@1.123 +3 -3 + NTP_4_2_5P132 + + util/ntp-keygen-opts.texi@1.122 +1 -1 + NTP_4_2_5P132 + + util/ntp-keygen.1@1.122 +2 -2 + NTP_4_2_5P132 + +ChangeSet@1.1735.1.48, 2008-09-14 18:41:58-04:00, stenn@whimsy.udel.edu + Remove comment made spurious by the fix for [Bug 1067] + + ntpd/ntpd.c@1.97 +0 -1 + Remove comment made spurious by the fix for [Bug 1067] + +ChangeSet@1.1735.1.47, 2008-09-14 18:32:56-04:00, stenn@pogo.udel.edu + tidy a comment + + ChangeLog@1.228 +3 -2 + tidy a comment + +ChangeSet@1.1735.1.46, 2008-09-14 18:11:27-04:00, utterback@pogo.udel.edu + ntpd.c, ChangeLog: + Multicast DNS service registration must come after the fork on Solaris. + + ChangeLog@1.227 +1 -0 + Multicast DNS service registration must come after the fork on Solaris. + + ntpd/ntpd.c@1.96 +8 -8 + Multicast DNS service registration must come after the fork on Solaris. + +ChangeSet@1.1735.1.45, 2008-09-14 10:35:32-04:00, utterback@pogo.udel.edu + ChangeLog: + Error messages should log as errors. + ntp_parser.y, ntp_config.c: + Error messages should log as errors. + + ChangeLog@1.226 +1 -0 + Error messages should log as errors + + ntpd/ntp_config.c@1.184 +1 -1 + Error messages should log as errors. + + ntpd/ntp_parser.y@1.25 +5 -5 + Error messages should log as errors. + +ChangeSet@1.1735.1.44, 2008-09-14 07:43:33-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P131 + TAG: NTP_4_2_5P131 + + ChangeLog@1.225 +1 -0 + NTP_4_2_5P131 + + ntpd/ntpd-opts.c@1.123 +2 -2 + NTP_4_2_5P131 + + ntpd/ntpd-opts.h@1.123 +3 -3 + NTP_4_2_5P131 + + ntpd/ntpd-opts.texi@1.122 +1 -1 + NTP_4_2_5P131 + + ntpd/ntpd.1@1.122 +2 -2 + NTP_4_2_5P131 + + ntpdc/ntpdc-opts.c@1.119 +2 -2 + NTP_4_2_5P131 + + ntpdc/ntpdc-opts.h@1.119 +3 -3 + NTP_4_2_5P131 + + ntpdc/ntpdc-opts.texi@1.118 +1 -1 + NTP_4_2_5P131 + + ntpdc/ntpdc.1@1.118 +2 -2 + NTP_4_2_5P131 + + ntpq/ntpq-opts.c@1.119 +2 -2 + NTP_4_2_5P131 + + ntpq/ntpq-opts.h@1.119 +3 -3 + NTP_4_2_5P131 + + ntpq/ntpq-opts.texi@1.118 +1 -1 + NTP_4_2_5P131 + + ntpq/ntpq.1@1.118 +2 -2 + NTP_4_2_5P131 + + packageinfo.sh@1.134 +1 -1 + NTP_4_2_5P131 + + sntp/sntp-opts.c@1.119 +2 -2 + NTP_4_2_5P131 + + sntp/sntp-opts.h@1.119 +3 -3 + NTP_4_2_5P131 + + sntp/sntp-opts.texi@1.118 +1 -1 + NTP_4_2_5P131 + + sntp/sntp.1@1.118 +2 -2 + NTP_4_2_5P131 + + util/ntp-keygen-opts.c@1.122 +2 -2 + NTP_4_2_5P131 + + util/ntp-keygen-opts.h@1.122 +3 -3 + NTP_4_2_5P131 + + util/ntp-keygen-opts.texi@1.121 +1 -1 + NTP_4_2_5P131 + + util/ntp-keygen.1@1.121 +2 -2 + NTP_4_2_5P131 + +ChangeSet@1.1735.1.43, 2008-09-13 23:07:30-04:00, stenn@pogo.udel.edu + [Bug 1065] Re-enable support for the timingstats file + + ChangeLog@1.224 +1 -0 + [Bug 1065] Re-enable support for the timingstats file + +ChangeSet@1.1735.1.42, 2008-09-13 23:03:22-04:00, stenn@pogo.udel.edu + rebuild ntp_parser.[ch] with newer bison + + ntpd/ntp_parser.c@1.30 +2449 -1618 + rebuild with newer bison + + ntpd/ntp_parser.h@1.14 +363 -161 + rebuild with newer bison + +ChangeSet@1.1735.1.41, 2008-09-13 21:42:40-04:00, utterback@pogo.udel.edu + ntp_config.c: + Reinstate timingstats file + + ntpd/ntp_config.c@1.183 +1 -0 + Reinstate timingstats file + +ChangeSet@1.1735.7.4, 2008-09-13 07:49:17-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P130 + TAG: NTP_4_2_5P130 + + ChangeLog@1.223 +1 -0 + NTP_4_2_5P130 + + ntpd/ntpd-opts.c@1.122 +2 -2 + NTP_4_2_5P130 + + ntpd/ntpd-opts.h@1.122 +3 -3 + NTP_4_2_5P130 + + ntpd/ntpd-opts.texi@1.121 +1 -1 + NTP_4_2_5P130 + + ntpd/ntpd.1@1.121 +2 -2 + NTP_4_2_5P130 + + ntpdc/ntpdc-opts.c@1.118 +2 -2 + NTP_4_2_5P130 + + ntpdc/ntpdc-opts.h@1.118 +3 -3 + NTP_4_2_5P130 + + ntpdc/ntpdc-opts.texi@1.117 +1 -1 + NTP_4_2_5P130 + + ntpdc/ntpdc.1@1.117 +2 -2 + NTP_4_2_5P130 + + ntpq/ntpq-opts.c@1.118 +2 -2 + NTP_4_2_5P130 + + ntpq/ntpq-opts.h@1.118 +3 -3 + NTP_4_2_5P130 + + ntpq/ntpq-opts.texi@1.117 +1 -1 + NTP_4_2_5P130 + + ntpq/ntpq.1@1.117 +2 -2 + NTP_4_2_5P130 + + packageinfo.sh@1.133 +1 -1 + NTP_4_2_5P130 + + sntp/sntp-opts.c@1.118 +2 -2 + NTP_4_2_5P130 + + sntp/sntp-opts.h@1.118 +3 -3 + NTP_4_2_5P130 + + sntp/sntp-opts.texi@1.117 +1 -1 + NTP_4_2_5P130 + + sntp/sntp.1@1.117 +2 -2 + NTP_4_2_5P130 + + util/ntp-keygen-opts.c@1.121 +2 -2 + NTP_4_2_5P130 + + util/ntp-keygen-opts.h@1.121 +3 -3 + NTP_4_2_5P130 + + util/ntp-keygen-opts.texi@1.120 +1 -1 + NTP_4_2_5P130 + + util/ntp-keygen.1@1.120 +2 -2 + NTP_4_2_5P130 + +ChangeSet@1.1735.7.3, 2008-09-13 05:04:00-04:00, stenn@whimsy.udel.edu + [Bug 1064] Implement --with-net-snmp-config=progname + + ChangeLog@1.222 +1 -1 + [Bug 1064] Implement --with-net-snmp-config=progname + +ChangeSet@1.1735.7.2, 2008-09-13 04:58:45-04:00, stenn@whimsy.udel.edu + net-snmp-config cleanup + + ChangeLog@1.221 +1 -0 + net-snmp-config cleanup + + configure.ac@1.417.1.1 +45 -3 + net-snmp-config cleanup + + ntpsnmpd/Makefile.am@1.3 +2 -13 + net-snmp-config cleanup + +ChangeSet@1.1735.7.1, 2008-09-12 15:20:13-04:00, stenn@whimsy.udel.edu + [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution + + ChangeLog@1.220 +1 -0 + [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution + + ntpsnmpd/Makefile.am@1.2 +1 -0 + [Bug 1063] ntpSnmpSubagentObject.h is missing from the distribution + +ChangeSet@1.1735.1.39, 2008-09-12 09:39:33-04:00, utterback@pogo.udel.edu + ntp_util.c, ntp_parser.y, ntp_parser.h, ntp_parser.c: + Reinstate lost timingstats file + + ntpd/ntp_parser.c@1.29 +1818 -2649 + Reinstate lost timingstats file + + ntpd/ntp_parser.h@1.13 +161 -361 + Reinstate lost timingstats file + + ntpd/ntp_parser.y@1.24 +3 -0 + Reinstate lost timingstats file + + ntpd/ntp_util.c@1.66 +8 -0 + Reinstate lost timingstats file + +ChangeSet@1.1735.1.38, 2008-09-11 07:43:06-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P129 + TAG: NTP_4_2_5P129 + + ChangeLog@1.219 +1 -0 + NTP_4_2_5P129 + + ntpd/ntpd-opts.c@1.121 +2 -2 + NTP_4_2_5P129 + + ntpd/ntpd-opts.h@1.121 +3 -3 + NTP_4_2_5P129 + + ntpd/ntpd-opts.texi@1.120 +1 -1 + NTP_4_2_5P129 + + ntpd/ntpd.1@1.120 +2 -2 + NTP_4_2_5P129 + + ntpdc/ntpdc-opts.c@1.117 +2 -2 + NTP_4_2_5P129 + + ntpdc/ntpdc-opts.h@1.117 +3 -3 + NTP_4_2_5P129 + + ntpdc/ntpdc-opts.texi@1.116 +1 -1 + NTP_4_2_5P129 + + ntpdc/ntpdc.1@1.116 +2 -2 + NTP_4_2_5P129 + + ntpq/ntpq-opts.c@1.117 +2 -2 + NTP_4_2_5P129 + + ntpq/ntpq-opts.h@1.117 +3 -3 + NTP_4_2_5P129 + + ntpq/ntpq-opts.texi@1.116 +1 -1 + NTP_4_2_5P129 + + ntpq/ntpq.1@1.116 +2 -2 + NTP_4_2_5P129 + + packageinfo.sh@1.132 +1 -1 + NTP_4_2_5P129 + + sntp/sntp-opts.c@1.117 +2 -2 + NTP_4_2_5P129 + + sntp/sntp-opts.h@1.117 +3 -3 + NTP_4_2_5P129 + + sntp/sntp-opts.texi@1.116 +1 -1 + NTP_4_2_5P129 + + sntp/sntp.1@1.116 +2 -2 + NTP_4_2_5P129 + + util/ntp-keygen-opts.c@1.120 +2 -2 + NTP_4_2_5P129 + + util/ntp-keygen-opts.h@1.120 +3 -3 + NTP_4_2_5P129 + + util/ntp-keygen-opts.texi@1.119 +1 -1 + NTP_4_2_5P129 + + util/ntp-keygen.1@1.119 +2 -2 + NTP_4_2_5P129 + +ChangeSet@1.1735.1.37, 2008-09-11 02:52:01-04:00, stenn@whimsy.udel.edu + Quiet some libntpq-related warnings + + ChangeLog@1.218 +1 -0 + Quiet some libntpq-related warnings + + ntpq/Makefile.am@1.32 +2 -2 + Quiet some libntpq-related warnings + + ntpq/libntpq.c@1.2 +1 -1 + Quiet some libntpq-related warnings + +ChangeSet@1.1771, 2008-09-11 00:35:34-04:00, stenn@pogo.udel.edu + No c++ or F77 for libtool, get socket libraries + + gsoc_sntp/configure.ac@1.4 +13 -0 + No c++ or F77 for libtool, get socket libraries + +ChangeSet@1.1770, 2008-09-11 00:32:37-04:00, stenn@pogo.udel.edu + doc strings must be tab-indented, not space + + gsoc_sntp/sntp-opts.def@1.8 +2 -4 + doc strings must be tab-indented, not space + +ChangeSet@1.1768, 2008-09-10 20:26:26-04:00, stenn@pogo.udel.edu + updates + + gsoc_sntp/Makefile.am@1.4 +1 -0 + updates + + gsoc_sntp/log.c@1.7 +5 -1 + updates + + gsoc_sntp/sntp-opts.def@1.7 +49 -33 + updates + +ChangeSet@1.1767, 2008-09-10 23:37:56+00:00, kuehn@pogo.udel.edu + main.c: + fixed includes + crypto.c, networking.c: + Fixed compile errors + + gsoc_sntp/crypto.c@1.3 +3 -3 + Fixed compile errors + + gsoc_sntp/crypto.h@1.3 +1 -1 + + gsoc_sntp/main.c@1.9 +2 -2 + fixed includes + + gsoc_sntp/networking.c@1.15 +8 -9 + Fixed compile errors + + gsoc_sntp/networking.h@1.11 +2 -0 + +ChangeSet@1.1766, 2008-09-10 22:58:04+00:00, kuehn@pogo.udel.edu + log.h: + fixed missing timestamp for file logging + kod_management.c: + Fixed the core dump when no kod file is specified + networking.c: + Some fixes for broadcast mode + remove filter reachable (no use for this function) + utilities.c: + Added a function to convert a struct sockaddr_storage to a string containing its hostname + crypto.c: + Completeted auth md5 functions + + BitKeeper/etc/gone@1.8 +14 -0 + + gsoc_sntp/crypto.c@1.2 +125 -39 + Completeted auth md5 functions + + gsoc_sntp/crypto.h@1.2 +35 -5 + + gsoc_sntp/header.h@1.3 +5 -3 + + gsoc_sntp/kod_management.c@1.6 +25 -4 + Fixed the core dump when no kod file is specified + + gsoc_sntp/kod_management.h@1.4 +18 -1 + + gsoc_sntp/log.c@1.6 +26 -5 + + gsoc_sntp/log.h@1.4 +20 -2 + fixed missing timestamp for file logging + + gsoc_sntp/main.c@1.8 +18 -11 + + gsoc_sntp/networking.c@1.14 +457 -94 + Some fixes for broadcast mode + remove filter reachable (no use for this function) + + gsoc_sntp/networking.h@1.10 +33 -3 + + gsoc_sntp/utilities.c@1.4 +46 -0 + Added a function to convert a struct sockaddr_storage to a string containing its hostname + + gsoc_sntp/utilities.h@1.3 +35 -0 + +ChangeSet@1.1735.1.36, 2008-09-08 07:46:43-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P128 + TAG: NTP_4_2_5P128 + + ChangeLog@1.217 +1 -0 + NTP_4_2_5P128 + + ntpd/ntpd-opts.c@1.120 +2 -2 + NTP_4_2_5P128 + + ntpd/ntpd-opts.h@1.120 +3 -3 + NTP_4_2_5P128 + + ntpd/ntpd-opts.texi@1.119 +2 -2 + NTP_4_2_5P128 + + ntpd/ntpd.1@1.119 +2 -2 + NTP_4_2_5P128 + + ntpdc/ntpdc-opts.c@1.116 +2 -2 + NTP_4_2_5P128 + + ntpdc/ntpdc-opts.h@1.116 +3 -3 + NTP_4_2_5P128 + + ntpdc/ntpdc-opts.texi@1.115 +2 -2 + NTP_4_2_5P128 + + ntpdc/ntpdc.1@1.115 +2 -2 + NTP_4_2_5P128 + + ntpq/ntpq-opts.c@1.116 +2 -2 + NTP_4_2_5P128 + + ntpq/ntpq-opts.h@1.116 +3 -3 + NTP_4_2_5P128 + + ntpq/ntpq-opts.texi@1.115 +2 -2 + NTP_4_2_5P128 + + ntpq/ntpq.1@1.115 +2 -2 + NTP_4_2_5P128 + + packageinfo.sh@1.131 +1 -1 + NTP_4_2_5P128 + + sntp/sntp-opts.c@1.116 +2 -2 + NTP_4_2_5P128 + + sntp/sntp-opts.h@1.116 +3 -3 + NTP_4_2_5P128 + + sntp/sntp-opts.texi@1.115 +1 -1 + NTP_4_2_5P128 + + sntp/sntp.1@1.115 +2 -2 + NTP_4_2_5P128 + + util/ntp-keygen-opts.c@1.119 +2 -2 + NTP_4_2_5P128 + + util/ntp-keygen-opts.h@1.119 +3 -3 + NTP_4_2_5P128 + + util/ntp-keygen-opts.texi@1.118 +2 -2 + NTP_4_2_5P128 + + util/ntp-keygen.1@1.118 +2 -2 + NTP_4_2_5P128 + +ChangeSet@1.1735.6.4, 2008-09-08 03:57:36-04:00, stenn@whimsy.udel.edu + Cleanup missing ChangeLog message + + ChangeLog@1.213.1.3 +1 -0 + Cleanup missing ChangeLog message + +ChangeSet@1.1759.1.1, 2008-09-05 00:08:08+00:00, kuehn@pogo.udel.edu + kod_management.h, main.c, kod_management.c: + Fixes + networking.h: + fixes + broadcast mode + crypto.h: + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.h + crypto.c: + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.c + networking.c: + Fixes + Broadcast mode + sntp-opts.def: + Added new options, removed host list + + gsoc_sntp/crypto.c@1.1 +97 -0 + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.c + + gsoc_sntp/crypto.c@1.0 +0 -0 + + gsoc_sntp/crypto.h@1.1 +19 -0 + BitKeeper file /pogo/users/kuehn/rsync_repo/ntp-dev/gsoc_sntp/crypto.h + + gsoc_sntp/crypto.h@1.0 +0 -0 + +ChangeSet@1.1735.6.3, 2008-09-01 07:42:29-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P127 + TAG: NTP_4_2_5P127 + + ChangeLog@1.213.1.2 +1 -0 + NTP_4_2_5P127 + + ntpd/ntpd-opts.c@1.119 +2 -2 + NTP_4_2_5P127 + + ntpd/ntpd-opts.h@1.119 +3 -3 + NTP_4_2_5P127 + + ntpd/ntpd-opts.texi@1.118 +1 -1 + NTP_4_2_5P127 + + ntpd/ntpd.1@1.118 +2 -2 + NTP_4_2_5P127 + + ntpdc/ntpdc-opts.c@1.115 +2 -2 + NTP_4_2_5P127 + + ntpdc/ntpdc-opts.h@1.115 +3 -3 + NTP_4_2_5P127 + + ntpdc/ntpdc-opts.texi@1.114 +1 -1 + NTP_4_2_5P127 + + ntpdc/ntpdc.1@1.114 +2 -2 + NTP_4_2_5P127 + + ntpq/ntpq-opts.c@1.115 +2 -2 + NTP_4_2_5P127 + + ntpq/ntpq-opts.h@1.115 +3 -3 + NTP_4_2_5P127 + + ntpq/ntpq-opts.texi@1.114 +1 -1 + NTP_4_2_5P127 + + ntpq/ntpq.1@1.114 +2 -2 + NTP_4_2_5P127 + + packageinfo.sh@1.130 +1 -1 + NTP_4_2_5P127 + + sntp/sntp-opts.c@1.115 +2 -2 + NTP_4_2_5P127 + + sntp/sntp-opts.h@1.115 +3 -3 + NTP_4_2_5P127 + + sntp/sntp-opts.texi@1.114 +1 -1 + NTP_4_2_5P127 + + sntp/sntp.1@1.114 +2 -2 + NTP_4_2_5P127 + + util/ntp-keygen-opts.c@1.118 +2 -2 + NTP_4_2_5P127 + + util/ntp-keygen-opts.h@1.118 +3 -3 + NTP_4_2_5P127 + + util/ntp-keygen-opts.texi@1.117 +1 -1 + NTP_4_2_5P127 + + util/ntp-keygen.1@1.117 +2 -2 + NTP_4_2_5P127 + +ChangeSet@1.1735.6.2, 2008-08-31 20:42:07-04:00, stenn@whimsy.udel.edu + regenerate ntp_parser.c + + ntpd/ntp_parser.c@1.28 +802 -851 + regenerate ntp_parser.c + +ChangeSet@1.1735.6.1, 2008-08-31 07:49:04-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P126 + TAG: NTP_4_2_5P126 + + ChangeLog@1.213.1.1 +1 -0 + NTP_4_2_5P126 + + ntpd/ntpd-opts.c@1.118 +2 -2 + NTP_4_2_5P126 + + ntpd/ntpd-opts.h@1.118 +3 -3 + NTP_4_2_5P126 + + ntpd/ntpd-opts.texi@1.117 +1 -1 + NTP_4_2_5P126 + + ntpd/ntpd.1@1.117 +2 -2 + NTP_4_2_5P126 + + ntpdc/ntpdc-opts.c@1.114 +2 -2 + NTP_4_2_5P126 + + ntpdc/ntpdc-opts.h@1.114 +3 -3 + NTP_4_2_5P126 + + ntpdc/ntpdc-opts.texi@1.113 +1 -1 + NTP_4_2_5P126 + + ntpdc/ntpdc.1@1.113 +2 -2 + NTP_4_2_5P126 + + ntpq/ntpq-opts.c@1.114 +2 -2 + NTP_4_2_5P126 + + ntpq/ntpq-opts.h@1.114 +3 -3 + NTP_4_2_5P126 + + ntpq/ntpq-opts.texi@1.113 +1 -1 + NTP_4_2_5P126 + + ntpq/ntpq.1@1.113 +2 -2 + NTP_4_2_5P126 + + packageinfo.sh@1.129 +1 -1 + NTP_4_2_5P126 + + sntp/sntp-opts.c@1.114 +2 -2 + NTP_4_2_5P126 + + sntp/sntp-opts.h@1.114 +3 -3 + NTP_4_2_5P126 + + sntp/sntp-opts.texi@1.113 +1 -1 + NTP_4_2_5P126 + + sntp/sntp.1@1.113 +2 -2 + NTP_4_2_5P126 + + util/ntp-keygen-opts.c@1.117 +2 -2 + NTP_4_2_5P126 + + util/ntp-keygen-opts.h@1.117 +3 -3 + NTP_4_2_5P126 + + util/ntp-keygen-opts.texi@1.116 +1 -1 + NTP_4_2_5P126 + + util/ntp-keygen.1@1.116 +2 -2 + NTP_4_2_5P126 + +ChangeSet@1.1764, 2008-08-31 07:15:07-04:00, stenn@pogo.udel.edu + portability fixes + + configure.ac@1.416.1.1 +1 -0 + build gsoc_snmp + +ChangeSet@1.1763, 2008-08-31 05:56:21-04:00, stenn@pogo.udel.edu + Have libtool ignore C++ and F77 + +ChangeSet@1.1735.5.1, 2008-08-31 04:59:46-04:00, stenn@pogo.udel.edu + Prepare for GSoC2008 NTP MIB daemon import + + ChangeLog@1.212.1.1 +1 -0 + Prepare for GSoC2008 NTP MIB daemon import + + Makefile.am@1.76.1.1 +2 -0 + Prepare for GSoC2008 NTP MIB daemon import + + configure.ac@1.415.1.1 +27 -0 + Prepare for GSoC2008 NTP MIB daemon import + + ntpq/Makefile.am@1.31 +6 -5 + Prepare for GSoC2008 NTP MIB daemon import + + ntpq/libntpq.c@1.1 +790 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpq/libntpq.c + + ntpq/libntpq.c@1.0 +0 -0 + + ntpq/libntpq.h@1.1 +108 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpq/libntpq.h + + ntpq/libntpq.h@1.0 +0 -0 + + ntpq/libntpq_subs.c@1.1 +50 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpq/libntpq_subs.c + + ntpq/libntpq_subs.c@1.0 +0 -0 + + ntpq/ntpq.c@1.75 +7 -2 + Prepare for GSoC2008 NTP MIB daemon import + + ntpsnmpd/Makefile.am@1.1 +19 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/Makefile.am + + ntpsnmpd/Makefile.am@1.0 +0 -0 + + ntpsnmpd/README@1.1 +40 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/README + + ntpsnmpd/README@1.0 +0 -0 + + ntpsnmpd/ntpSnmpSubagentObject.c@1.1 +490 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/ntpSnmpSubagentObject.c + + ntpsnmpd/ntpSnmpSubagentObject.c@1.0 +0 -0 + + ntpsnmpd/ntpSnmpSubagentObject.h@1.1 +72 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/ntpSnmpSubagentObject.h + + ntpsnmpd/ntpSnmpSubagentObject.h@1.0 +0 -0 + + ntpsnmpd/ntpsnmpd.c@1.1 +107 -0 + BitKeeper file /pogo/users/gerstung/gsoc/ntp-dev/ntpsnmpd/ntpsnmpd.c + + ntpsnmpd/ntpsnmpd.c@1.0 +0 -0 + +ChangeSet@1.1735.1.32, 2008-08-31 04:43:40-04:00, stenn@whimsy.udel.edu + Stop libtool-1.5 from looking for C++ or Fortran + + sntp/configure.ac@1.17 +3 -0 + Stop libtool-1.5 from looking for C++ or Fortran + +ChangeSet@1.1735.1.31, 2008-08-31 04:33:40-04:00, stenn@whimsy.udel.edu + Stop libtool-1.5 from looking for C++ or Fortran + + ChangeLog@1.213 +1 -0 + Stop libtool-1.5 from looking for C++ or Fortran + + configure.ac@1.416 +4 -0 + Stop libtool-1.5 from looking for C++ or Fortran + +ChangeSet@1.1735.4.4, 2008-08-31 02:06:36-04:00, stenn@whimsy.udel.edu + [Bug 828] Fix IPv4/IPv6 address parsing + + ChangeLog@1.210.1.4 +1 -0 + [Bug 828] Fix IPv4/IPv6 address parsing + + ntpd/ntp_config.c@1.182 +11 -2 + [Bug 828] Fix IPv4/IPv6 address parsing + + ntpd/ntp_parser.y@1.23 +9 -42 + [Bug 828] Fix IPv4/IPv6 address parsing + + ntpd/ntp_scanner.c@1.13 +43 -31 + [Bug 828] Fix IPv4/IPv6 address parsing + +ChangeSet@1.1761, 2008-08-31 01:43:34-04:00, stenn@pogo.udel.edu + portability fixes + +ChangeSet@1.1735.4.3, 2008-08-30 23:19:40-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.210.1.3 +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.43 +1 -1 + Documentation updates from Dave Mills + + html/decode.html@1.3 +0 -1 + Documentation updates from Dave Mills + + html/gadget.html@1.3 +3 -3 + Documentation updates from Dave Mills + + html/howto.html@1.20 +3 -2 + Documentation updates from Dave Mills + + html/index.html@1.38 +9 -8 + Documentation updates from Dave Mills + + html/kern.html@1.17 +3 -3 + Documentation updates from Dave Mills + + html/keygen.html@1.13 +65 -20 + Documentation updates from Dave Mills + + html/manyopt.html@1.18 +3 -3 + Documentation updates from Dave Mills + + html/ntp_conf.html@1.3 +10 -9 + Documentation updates from Dave Mills + + html/ntpd.html@1.46 +9 -9 + Documentation updates from Dave Mills + + html/ntpdsim_new.html@1.4 +8 -1 + Documentation updates from Dave Mills + + html/parsenew.html@1.11 +1 -3 + Documentation updates from Dave Mills + + html/pps.html@1.20 +6 -4 + Documentation updates from Dave Mills + + html/prefer.html@1.17 +14 -14 + Documentation updates from Dave Mills + + html/rate.html@1.4 +14 -8 + Documentation updates from Dave Mills + + html/refclock.html@1.34 +47 -47 + Documentation updates from Dave Mills + + html/release.html@1.36 +27 -24 + Documentation updates from Dave Mills + + html/xleave.html@1.3 +3 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1735.4.2, 2008-08-30 23:14:01-04:00, stenn@whimsy.udel.edu + Fix a corner case where a frequency update was reported but not set + + ChangeLog@1.210.1.2 +1 -0 + Fix a corner case where a frequency update was reported but not set + + ntpd/ntp_loopfilter.c@1.147 +6 -5 + Fix a corner case where a frequency update was reported but not set + +ChangeSet@1.1735.4.1, 2008-08-30 22:09:29-04:00, stenn@whimsy.udel.edu + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have crypto_flags + + ChangeLog@1.210.1.1 +3 -0 + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have crypto_flags + + html/pic/boom4.gif@1.1 +361 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/boom4.gif + + html/pic/boom4.gif@1.0 +0 -0 + + ntpd/ntp_proto.c@1.275 +6 -1 + When LEAP_NOTINSYNC->LEAP_NOWARNING, call crypto_update() if we have crypto_flags + +ChangeSet@1.1759, 2008-08-22 21:27:59-04:00, stenn@pogo.udel.edu + remove bogus .o file + + BitKeeper/deleted/.del-utilities.o@1.2 +0 -0 + Delete: gsoc_sntp/utilities.o + +ChangeSet@1.1735.1.29, 2008-08-21 05:05:19+00:00, gopal@pogo.udel.edu + driver20.html: + [BUG 610] Documentation update for NMEA reference clock driver. + ChangeLog: + Added appropriate comments for documentation update. + + ChangeLog@1.211 +1 -0 + Added appropriate comments for documentation update. + + html/drivers/driver20.html@1.15 +23 -6 + [BUG 610] Documentation update for NMEA reference clock driver. + +ChangeSet@1.1757, 2008-08-18 21:37:27+09:00, Amidamaru@yumi.mxiesoft.com + utilities.c, networking.c: + Fixes + sntp-opts.def: + added broadcast and timeout options + log.c: + Fixes, one bug with filelogging left + main.c: + Fixed KOD handling in on_Ãwire + + gsoc_sntp/log.c@1.5 +2 -4 + Fixes, one bug with filelogging left + + gsoc_sntp/main.c@1.7 +87 -35 + Fixed KOD handling in on_Ãwire + + gsoc_sntp/networking.c@1.13 +85 -75 + Fixes + + gsoc_sntp/networking.h@1.9 +85 -14 + + gsoc_sntp/sntp-opts.def@1.6 +23 -0 + added broadcast and timeout options + + gsoc_sntp/utilities.c@1.3 +12 -0 + Fixes + + gsoc_sntp/utilities.h@1.2 +1 -0 + +ChangeSet@1.1735.1.28, 2008-08-18 07:43:18-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P125 + TAG: NTP_4_2_5P125 + + ChangeLog@1.210 +1 -0 + NTP_4_2_5P125 + + ntpd/ntpd-opts.c@1.117 +2 -2 + NTP_4_2_5P125 + + ntpd/ntpd-opts.h@1.117 +3 -3 + NTP_4_2_5P125 + + ntpd/ntpd-opts.texi@1.116 +1 -1 + NTP_4_2_5P125 + + ntpd/ntpd.1@1.116 +2 -2 + NTP_4_2_5P125 + + ntpdc/ntpdc-opts.c@1.113 +2 -2 + NTP_4_2_5P125 + + ntpdc/ntpdc-opts.h@1.113 +3 -3 + NTP_4_2_5P125 + + ntpdc/ntpdc-opts.texi@1.112 +1 -1 + NTP_4_2_5P125 + + ntpdc/ntpdc.1@1.112 +2 -2 + NTP_4_2_5P125 + + ntpq/ntpq-opts.c@1.113 +2 -2 + NTP_4_2_5P125 + + ntpq/ntpq-opts.h@1.113 +3 -3 + NTP_4_2_5P125 + + ntpq/ntpq-opts.texi@1.112 +1 -1 + NTP_4_2_5P125 + + ntpq/ntpq.1@1.112 +2 -2 + NTP_4_2_5P125 + + packageinfo.sh@1.128 +1 -1 + NTP_4_2_5P125 + + sntp/sntp-opts.c@1.113 +2 -2 + NTP_4_2_5P125 + + sntp/sntp-opts.h@1.113 +3 -3 + NTP_4_2_5P125 + + sntp/sntp-opts.texi@1.112 +1 -1 + NTP_4_2_5P125 + + sntp/sntp.1@1.112 +2 -2 + NTP_4_2_5P125 + + util/ntp-keygen-opts.c@1.116 +2 -2 + NTP_4_2_5P125 + + util/ntp-keygen-opts.h@1.116 +3 -3 + NTP_4_2_5P125 + + util/ntp-keygen-opts.texi@1.115 +1 -1 + NTP_4_2_5P125 + + util/ntp-keygen.1@1.115 +2 -2 + NTP_4_2_5P125 + +ChangeSet@1.1735.1.27, 2008-08-17 19:38:48-04:00, stenn@pogo.udel.edu + [Bug 1052] Add linuxPPS support to ONCORE driver + + ChangeLog@1.209 +1 -0 + [Bug 1052] Add linuxPPS support to ONCORE driver + +ChangeSet@1.1735.3.3, 2008-08-17 07:52:08-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P124 + TAG: NTP_4_2_5P124 + + ChangeLog@1.208 +1 -0 + NTP_4_2_5P124 + + ntpd/ntpd-opts.c@1.116 +2 -2 + NTP_4_2_5P124 + + ntpd/ntpd-opts.h@1.116 +3 -3 + NTP_4_2_5P124 + + ntpd/ntpd-opts.texi@1.115 +1 -1 + NTP_4_2_5P124 + + ntpd/ntpd.1@1.115 +2 -2 + NTP_4_2_5P124 + + ntpdc/ntpdc-opts.c@1.112 +2 -2 + NTP_4_2_5P124 + + ntpdc/ntpdc-opts.h@1.112 +3 -3 + NTP_4_2_5P124 + + ntpdc/ntpdc-opts.texi@1.111 +1 -1 + NTP_4_2_5P124 + + ntpdc/ntpdc.1@1.111 +2 -2 + NTP_4_2_5P124 + + ntpq/ntpq-opts.c@1.112 +2 -2 + NTP_4_2_5P124 + + ntpq/ntpq-opts.h@1.112 +3 -3 + NTP_4_2_5P124 + + ntpq/ntpq-opts.texi@1.111 +1 -1 + NTP_4_2_5P124 + + ntpq/ntpq.1@1.111 +2 -2 + NTP_4_2_5P124 + + packageinfo.sh@1.127 +1 -1 + NTP_4_2_5P124 + + sntp/sntp-opts.c@1.112 +2 -2 + NTP_4_2_5P124 + + sntp/sntp-opts.h@1.112 +3 -3 + NTP_4_2_5P124 + + sntp/sntp-opts.texi@1.111 +1 -1 + NTP_4_2_5P124 + + sntp/sntp.1@1.111 +2 -2 + NTP_4_2_5P124 + + util/ntp-keygen-opts.c@1.115 +2 -2 + NTP_4_2_5P124 + + util/ntp-keygen-opts.h@1.115 +3 -3 + NTP_4_2_5P124 + + util/ntp-keygen-opts.texi@1.114 +1 -1 + NTP_4_2_5P124 + + util/ntp-keygen.1@1.114 +2 -2 + NTP_4_2_5P124 + +ChangeSet@1.1735.3.2, 2008-08-17 06:57:54-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.207 +1 -0 + Documentation updates from Dave Mills + + html/ntpd.html@1.45 +11 -1 + Documentation updates from Dave Mills + + html/xleave.html@1.2 +9 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1436.15.6, 2008-08-17 06:21:39-04:00, stenn@whimsy.udel.edu + typo + + scripts/addChangeLogTag@1.3 +0 -3 + typo + +ChangeSet@1.1436.15.5, 2008-08-17 06:16:19-04:00, stenn@whimsy.udel.edu + typo + + ChangeLog@1.1.1.44 +0 -2 + typo + +ChangeSet@1.1436.15.4, 2008-08-17 05:30:47-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P5 + TAG: NTP_4_2_4P5 + + ChangeLog@1.1.1.43 +3 -0 + NTP_4_2_4P5 + + ntpd/ntpd-opts.c@1.50.16.1 +2 -2 + NTP_4_2_4P5 + + ntpd/ntpd-opts.h@1.50.16.1 +3 -3 + NTP_4_2_4P5 + + ntpd/ntpd-opts.texi@1.49.16.1 +1 -1 + NTP_4_2_4P5 + + ntpd/ntpd.1@1.48.16.1 +2 -2 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.c@1.50.16.1 +2 -2 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.h@1.50.16.1 +3 -3 + NTP_4_2_4P5 + + ntpd/ntpdsim-opts.texi@1.48.16.1 +1 -1 + NTP_4_2_4P5 + + ntpd/ntpdsim.1@1.48.16.1 +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.c@1.50.16.1 +2 -2 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.h@1.50.16.1 +3 -3 + NTP_4_2_4P5 + + ntpdc/ntpdc-opts.texi@1.48.16.1 +1 -1 + NTP_4_2_4P5 + + ntpdc/ntpdc.1@1.48.16.1 +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq-opts.c@1.52.16.1 +2 -2 + NTP_4_2_4P5 + + ntpq/ntpq-opts.h@1.52.16.1 +3 -3 + NTP_4_2_4P5 + + ntpq/ntpq-opts.texi@1.49.16.1 +1 -1 + NTP_4_2_4P5 + + ntpq/ntpq.1@1.48.16.1 +2 -2 + NTP_4_2_4P5 + + packageinfo.sh@1.65.23.2 +2 -2 + NTP_4_2_4P5 + + sntp/sntp-opts.c@1.49.16.1 +2 -2 + NTP_4_2_4P5 + + sntp/sntp-opts.h@1.49.16.1 +3 -3 + NTP_4_2_4P5 + + sntp/sntp-opts.texi@1.46.16.1 +1 -1 + NTP_4_2_4P5 + + sntp/sntp.1@1.49.16.1 +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen-opts.c@1.49.16.1 +2 -2 + NTP_4_2_4P5 + + util/ntp-keygen-opts.h@1.49.16.1 +3 -3 + NTP_4_2_4P5 + + util/ntp-keygen-opts.texi@1.47.16.1 +1 -1 + NTP_4_2_4P5 + + util/ntp-keygen.1@1.47.16.1 +2 -2 + NTP_4_2_4P5 + +ChangeSet@1.1436.15.3, 2008-08-17 05:29:47-04:00, stenn@whimsy.udel.edu + typo + + scripts/addChangeLogTag@1.2 +1 -1 + typo + +ChangeSet@1.1436.15.2, 2008-08-17 03:28:53-04:00, stenn@whimsy.udel.edu + 4.2.4p5 prep + + .point-changed-filelist@1.1.1.1 +1 -0 + 4.2.4p5 prep + + NEWS@1.86.1.13 +17 -0 + 4.2.4p5 prep + + packageinfo.sh@1.65.23.1 +1 -1 + 4.2.4p5 prep + + scripts/addChangeLogTag@1.1 +27 -0 + BitKeeper file /deacon/backroom/ntp-stable/scripts/addChangeLogTag + + scripts/addChangeLogTag@1.0 +0 -0 + + scripts/genChangeLogTag@1.1 +6 -0 + BitKeeper file /deacon/backroom/ntp-stable/scripts/genChangeLogTag + + scripts/genChangeLogTag@1.0 +0 -0 + +ChangeSet@1.1436.15.1, 2008-08-16 22:42:08-04:00, stenn@whimsy.udel.edu + [BUG 1051] Month off by one in leap second message written to clockstats + + ChangeLog@1.1.1.42 +2 -0 + [BUG 1051] Month off by one in leap second message written to clockstats + + ntpd/refclock_oncore.c@1.60.2.1 +1 -1 + [BUG 1051] Month off by one in leap second message written to clockstats + +ChangeSet@1.1756, 2008-08-17 05:57:54+09:00, Amidamaru@yumi.mxiesoft.com + networking.h: + Removed useless prototype filter_ntp + main.c, utilities.c, networking.c, kod_management.c: + Cleaning up + + gsoc_sntp/kod_management.c@1.5 +2 -4 + Cleaning up + + gsoc_sntp/main.c@1.6 +14 -12 + Cleaning up + + gsoc_sntp/networking.c@1.12 +4 -16 + Cleaning up + + gsoc_sntp/networking.h@1.8 +2 -18 + Removed useless prototype filter_ntp + + gsoc_sntp/utilities.c@1.2 +1 -1 + Cleaning up + +ChangeSet@1.1755, 2008-08-16 06:41:28+09:00, Amidamaru@yumi.mxiesoft.com + utilities.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.h + Makefile.am: + Added sntp-opts.c to sources + + minor fixes + main.c: + on_wire, timesetting stuff etc. + log.c, kod_management.c: + Bug fixes + utilities.o: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.o + utilities.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.c + sntp-opts.def: + fixed arg-type stuff + + gsoc_sntp/Makefile.am@1.3 +6 -2 + Added sntp-opts.c to sources + + minor fixes + + gsoc_sntp/kod_management.c@1.4 +9 -7 + Bug fixes + + gsoc_sntp/kod_management.h@1.3 +2 -1 + + gsoc_sntp/log.c@1.4 +10 -11 + Bug fixes + + gsoc_sntp/log.h@1.3 +0 -3 + + gsoc_sntp/main.c@1.5 +180 -56 + on_wire, timesetting stuff etc. + + gsoc_sntp/networking.c@1.11 +82 -72 + + gsoc_sntp/networking.h@1.7 +6 -4 + + gsoc_sntp/sntp-opts.def@1.5 +21 -6 + fixed arg-type stuff + + gsoc_sntp/utilities.c@1.1 +101 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.c + + gsoc_sntp/utilities.c@1.0 +0 -0 + + gsoc_sntp/utilities.h@1.1 +21 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.h + + gsoc_sntp/utilities.h@1.0 +0 -0 + + gsoc_sntp/utilities.o@1.1 +177 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/ntp-dev/gsoc_sntp/utilities.o + + gsoc_sntp/utilities.o@1.0 +0 -0 + +ChangeSet@1.1436.1.105, 2008-08-10 21:56:17-04:00, clemens@pogo.udel.edu + BUG[1052] Minor reordering of previous patch to make it more robust. + + ntpd/refclock_oncore.c@1.60.1.6 +57 -58 + BUG[1052] Minor reordering of previous patch to make it more robust. + +ChangeSet@1.1436.1.104, 2008-08-10 18:31:13-04:00, clemens@pogo.udel.edu + [BUG 1052] Modify ONCORE driver for linuxPPS which uses a line discipline for the + PPS source. + + ntpd/refclock_oncore.c@1.60.1.5 +21 -6 + [BUG 1052] Modify ONCORE driver for linuxPPS which uses a line discipline for the + PPS source. + +ChangeSet@1.1436.1.103, 2008-08-10 18:21:32-04:00, clemens@pogo.udel.edu + Remove unneeded variable. + + ntpd/refclock_oncore.c@1.60.1.4 +2 -3 + Remove unneeded variable. + +ChangeSet@1.1436.1.102, 2008-08-10 18:18:56-04:00, clemens@pogo.udel.edu + [BUG 1051] Month off by one in leap second message written to clockstats file, fixed. + + ntpd/refclock_oncore.c@1.60.1.3 +1 -1 + [BUG 1051] Month off by one in leap second message written to clockstats file, fixed. + +ChangeSet@1.1735.1.23, 2008-08-10 09:45:36-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P123 + TAG: NTP_4_2_5P123 + + ntpd/ntpd-opts.c@1.115 +2 -2 + NTP_4_2_5P123 + + ntpd/ntpd-opts.h@1.115 +3 -3 + NTP_4_2_5P123 + + ntpd/ntpd-opts.texi@1.114 +1 -1 + NTP_4_2_5P123 + + ntpd/ntpd.1@1.114 +2 -2 + NTP_4_2_5P123 + + ntpdc/ntpdc-opts.c@1.111 +2 -2 + NTP_4_2_5P123 + + ntpdc/ntpdc-opts.h@1.111 +3 -3 + NTP_4_2_5P123 + + ntpdc/ntpdc-opts.texi@1.110 +1 -1 + NTP_4_2_5P123 + + ntpdc/ntpdc.1@1.110 +2 -2 + NTP_4_2_5P123 + + ntpq/ntpq-opts.c@1.111 +2 -2 + NTP_4_2_5P123 + + ntpq/ntpq-opts.h@1.111 +3 -3 + NTP_4_2_5P123 + + ntpq/ntpq-opts.texi@1.110 +1 -1 + NTP_4_2_5P123 + + ntpq/ntpq.1@1.110 +2 -2 + NTP_4_2_5P123 + + packageinfo.sh@1.126 +1 -1 + NTP_4_2_5P123 + + sntp/sntp-opts.c@1.111 +4 -5 + NTP_4_2_5P123 + + sntp/sntp-opts.h@1.111 +5 -6 + NTP_4_2_5P123 + + sntp/sntp-opts.texi@1.110 +2 -3 + NTP_4_2_5P123 + + sntp/sntp.1@1.110 +3 -3 + NTP_4_2_5P123 + + util/ntp-keygen-opts.c@1.114 +2 -2 + NTP_4_2_5P123 + + util/ntp-keygen-opts.h@1.114 +3 -3 + NTP_4_2_5P123 + + util/ntp-keygen-opts.texi@1.113 +1 -1 + NTP_4_2_5P123 + + util/ntp-keygen.1@1.113 +2 -2 + NTP_4_2_5P123 + +ChangeSet@1.1436.1.101, 2008-08-10 07:44:31-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P5_RC2 + TAG: NTP_4_2_4P5_RC2 + + ntpd/ntpd-opts.c@1.50.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + ntpd/ntpd-opts.h@1.50.15.1 +3 -3 + NTP_4_2_4P5_RC2 + + ntpd/ntpd-opts.texi@1.49.15.1 +1 -1 + NTP_4_2_4P5_RC2 + + ntpd/ntpd.1@1.48.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim-opts.c@1.50.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim-opts.h@1.50.15.1 +3 -3 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim-opts.texi@1.48.15.1 +1 -1 + NTP_4_2_4P5_RC2 + + ntpd/ntpdsim.1@1.48.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc-opts.c@1.50.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc-opts.h@1.50.15.1 +3 -3 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc-opts.texi@1.48.15.1 +1 -1 + NTP_4_2_4P5_RC2 + + ntpdc/ntpdc.1@1.48.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + ntpq/ntpq-opts.c@1.52.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + ntpq/ntpq-opts.h@1.52.15.1 +3 -3 + NTP_4_2_4P5_RC2 + + ntpq/ntpq-opts.texi@1.49.15.1 +1 -1 + NTP_4_2_4P5_RC2 + + ntpq/ntpq.1@1.48.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + packageinfo.sh@1.65.22.1 +1 -1 + NTP_4_2_4P5_RC2 + + sntp/sntp-opts.c@1.49.15.1 +4 -5 + NTP_4_2_4P5_RC2 + + sntp/sntp-opts.h@1.49.15.1 +5 -6 + NTP_4_2_4P5_RC2 + + sntp/sntp-opts.texi@1.46.15.1 +2 -3 + NTP_4_2_4P5_RC2 + + sntp/sntp.1@1.49.15.1 +3 -3 + NTP_4_2_4P5_RC2 + + util/ntp-keygen-opts.c@1.49.15.1 +2 -2 + NTP_4_2_4P5_RC2 + + util/ntp-keygen-opts.h@1.49.15.1 +3 -3 + NTP_4_2_4P5_RC2 + + util/ntp-keygen-opts.texi@1.47.15.1 +1 -1 + NTP_4_2_4P5_RC2 + + util/ntp-keygen.1@1.47.15.1 +2 -2 + NTP_4_2_4P5_RC2 + +ChangeSet@1.1735.1.22, 2008-08-10 03:11:51-04:00, stenn@whimsy.udel.edu + [Bug 861] leap info was not being transmitted + + ChangeLog@1.205 +1 -0 + [Bug 861] leap info was not being transmitted + + ntpd/ntp_crypto.c@1.123 +2 -2 + [Bug 861] leap info was not being transmitted + + ntpd/ntp_timer.c@1.48 +1 -1 + [Bug 861] leap info was not being transmitted + + ntpd/refclock_local.c@1.18 +4 -1 + [Bug 861] leap info was not being transmitted + +ChangeSet@1.1436.14.1, 2008-08-10 02:22:22-04:00, stenn@whimsy.udel.edu + triggert needs to handle rooted RESYNC paths now + + BitKeeper/triggers/triggert@1.4.1.1 +3 -2 + triggert needs to handle rooted RESYNC paths now + +ChangeSet@1.1735.1.20, 2008-08-09 20:56:32-04:00, stenn@whimsy.udel.edu + cleanup + + ChangeLog@1.204 +4 -10 + cleanup + +ChangeSet@1.1436.1.98, 2008-08-09 20:05:06-04:00, stenn@whimsy.udel.edu + AutoGen'd files must be writable + + sntp/Makefile.am@1.21.1.2 +2 -2 + AutoGen'd files must be writable + + sntp/sntp-opts.menu@1.2.1.1 +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.1754, 2008-08-09 07:28:37+09:00, Amidamaru@yumi.mxiesoft.com + main.c: + bug fixes + networking.c, kod_management.c: + Bug fixes + + gsoc_sntp/kod_management.c@1.3 +62 -18 + Bug fixes + + gsoc_sntp/log.c@1.3 +27 -6 + + gsoc_sntp/main.c@1.4 +124 -27 + bug fixes + + gsoc_sntp/networking.c@1.10 +115 -21 + Bug fixes + +ChangeSet@1.1436.13.1, 2008-08-07 20:44:31+02:00, burnicki@pogo.udel.edu + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + + ChangeLog@1.1.10.1 +2 -0 + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + + ntpd/ntp_peer.c@1.97.2.1 +10 -2 + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + + ports/winnt/ntpd/ntservice.c@1.9.1.2 +8 -1 + [Bug 450] Windows only: Under original Windows NT we must not discard the + wildcard socket to workaround a bug in NT's getsockname(). + +ChangeSet@1.1753, 2008-08-06 17:05:34+09:00, Amidamaru@yumi.mxiesoft.com + networking.c: + Fixed resolver and some minor stuff + + gsoc_sntp/networking.c@1.9 +70 -22 + Fixed resolver and some minor stuff + +ChangeSet@1.1735.1.15, 2008-08-05 19:56:11-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P122 + TAG: NTP_4_2_5P122 + + ntpd/ntpd-opts.c@1.114 +2 -2 + NTP_4_2_5P122 + + ntpd/ntpd-opts.h@1.114 +3 -3 + NTP_4_2_5P122 + + ntpd/ntpd-opts.texi@1.113 +1 -1 + NTP_4_2_5P122 + + ntpd/ntpd.1@1.113 +2 -2 + NTP_4_2_5P122 + + ntpdc/ntpdc-opts.c@1.110 +2 -2 + NTP_4_2_5P122 + + ntpdc/ntpdc-opts.h@1.110 +3 -3 + NTP_4_2_5P122 + + ntpdc/ntpdc-opts.texi@1.109 +1 -1 + NTP_4_2_5P122 + + ntpdc/ntpdc.1@1.109 +2 -2 + NTP_4_2_5P122 + + ntpq/ntpq-opts.c@1.110 +2 -2 + NTP_4_2_5P122 + + ntpq/ntpq-opts.h@1.110 +3 -3 + NTP_4_2_5P122 + + ntpq/ntpq-opts.texi@1.109 +1 -1 + NTP_4_2_5P122 + + ntpq/ntpq.1@1.109 +2 -2 + NTP_4_2_5P122 + + packageinfo.sh@1.125 +1 -1 + NTP_4_2_5P122 + + sntp/sntp-opts.c@1.110 +2 -2 + NTP_4_2_5P122 + + sntp/sntp-opts.h@1.110 +3 -3 + NTP_4_2_5P122 + + sntp/sntp-opts.texi@1.109 +1 -1 + NTP_4_2_5P122 + + sntp/sntp.1@1.109 +2 -2 + NTP_4_2_5P122 + + util/ntp-keygen-opts.c@1.113 +2 -2 + NTP_4_2_5P122 + + util/ntp-keygen-opts.h@1.113 +3 -3 + NTP_4_2_5P122 + + util/ntp-keygen-opts.texi@1.112 +1 -1 + NTP_4_2_5P122 + + util/ntp-keygen.1@1.112 +2 -2 + NTP_4_2_5P122 + +ChangeSet@1.1735.1.14, 2008-08-05 06:07:25-04:00, stenn@whimsy.udel.edu + [Bug 1046] refnumtoa.c is using the wrong header file + + ChangeLog@1.199 +1 -0 + [Bug 1046] refnumtoa.c is using the wrong header file + + libntp/refnumtoa.c@1.5 +1 -1 + [Bug 1046] refnumtoa.c is using the wrong header file + +ChangeSet@1.1735.1.13, 2008-08-05 05:00:05-04:00, stenn@whimsy.udel.edu + [Bug 1047] enable/disable options processing fix + + ChangeLog@1.198 +1 -0 + [Bug 1047] enable/disable options processing fix + + ntpd/ntp_config.c@1.180 +12 -15 + [Bug 1047] enable/disable options processing fix + +ChangeSet@1.1436.12.2, 2008-08-05 09:56:08+02:00, burnicki@pogo.udel.edu + Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.5 +0 -8 + Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. + +ChangeSet@1.1436.12.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. + + ChangeLog@1.1.9.1 +3 -0 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. + + html/confopt.html@1.35.1.1 +0 -2 + Bug 841: Obsolete the "dynamic" keyword. + + html/ntpdc.html@1.26.1.1 +2 -3 + Bug 841: Obsolete the "dynamic" keyword. + + include/ntp.h@1.128.1.1 +0 -1 + Bug 841: Obsolete the "dynamic" keyword. + + include/ntp_request.h@1.30.1.1 +0 -1 + Bug 841: Obsolete the "dynamic" keyword. + + ntpd/ntp_config.c@1.141.1.3 +4 -2 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + Emit a warning if that keyword is used for configuration. + + ntpd/ntp_intres.c@1.48.1.4 +1 -3 + Bug 841: Obsolete the "dynamic" keyword. + + ntpd/ntp_peer.c@1.97.1.3 +5 -25 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + + ntpd/ntp_request.c@1.65.1.1 +1 -3 + Bug 841: Obsolete the "dynamic" keyword. + + ntpdc/ntpdc_ops.c@1.46.1.4 +3 -3 + [Bug 841] Obsolete the "dynamic" keyword and make deferred binding + to local interfaces the default. + +ChangeSet@1.1749.1.2, 2008-08-02 07:02:15-04:00, stenn@pogo.udel.edu + typo + + gsoc_sntp/main.c@1.3 +2 -1 + typo + +ChangeSet@1.1749.1.1, 2008-07-29 19:04:34-04:00, stenn@pogo.udel.edu + cleanups + + gsoc_sntp/configure.ac@1.3 +1 -1 + cleanups + + gsoc_sntp/header.h@1.2 +0 -1 + cleanups + + gsoc_sntp/main.c@1.2 +9 -4 + cleanups + + gsoc_sntp/networking.h@1.6 +2 -1 + cleanups + +ChangeSet@1.1747.1.1, 2008-07-28 04:38:59+09:00, Amidamaru@yumi.mxiesoft.com + sntp-opts.def: + removed unnecessary verbosity flags + + gsoc_sntp/sntp-opts.def@1.2.1.1 +1 -15 + removed unnecessary verbosity flags + +ChangeSet@1.1749, 2008-07-27 15:10:03-04:00, stenn@pogo.udel.edu + Use ntp_machine.h + + gsoc_sntp/data_formats.h@1.4 +1 -0 + Use ntp_machine.h + +ChangeSet@1.1748, 2008-07-27 15:09:23-04:00, stenn@pogo.udel.edu + Fix the "kod" keyword + + gsoc_sntp/:fetch-stubs@1.3 +1 -1 + Fix the "kod" keyword + + gsoc_sntp/sntp-opts.def@1.3 +2 -3 + Fix the "kod" keyword + +ChangeSet@1.1735.1.12, 2008-07-24 15:28:20-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P121 + TAG: NTP_4_2_5P121 + + ntpd/ntpd-opts.c@1.113 +2 -2 + NTP_4_2_5P121 + + ntpd/ntpd-opts.h@1.113 +3 -3 + NTP_4_2_5P121 + + ntpd/ntpd-opts.texi@1.112 +1 -1 + NTP_4_2_5P121 + + ntpd/ntpd.1@1.112 +2 -2 + NTP_4_2_5P121 + + ntpdc/ntpdc-opts.c@1.109 +2 -2 + NTP_4_2_5P121 + + ntpdc/ntpdc-opts.h@1.109 +3 -3 + NTP_4_2_5P121 + + ntpdc/ntpdc-opts.texi@1.108 +1 -1 + NTP_4_2_5P121 + + ntpdc/ntpdc.1@1.108 +2 -2 + NTP_4_2_5P121 + + ntpq/ntpq-opts.c@1.109 +2 -2 + NTP_4_2_5P121 + + ntpq/ntpq-opts.h@1.109 +3 -3 + NTP_4_2_5P121 + + ntpq/ntpq-opts.texi@1.108 +1 -1 + NTP_4_2_5P121 + + ntpq/ntpq.1@1.108 +2 -2 + NTP_4_2_5P121 + + packageinfo.sh@1.124 +1 -1 + NTP_4_2_5P121 + + sntp/sntp-opts.c@1.109 +2 -2 + NTP_4_2_5P121 + + sntp/sntp-opts.h@1.109 +3 -3 + NTP_4_2_5P121 + + sntp/sntp-opts.texi@1.108 +1 -1 + NTP_4_2_5P121 + + sntp/sntp.1@1.108 +2 -2 + NTP_4_2_5P121 + + util/ntp-keygen-opts.c@1.112 +2 -2 + NTP_4_2_5P121 + + util/ntp-keygen-opts.h@1.112 +3 -3 + NTP_4_2_5P121 + + util/ntp-keygen-opts.texi@1.111 +1 -1 + NTP_4_2_5P121 + + util/ntp-keygen.1@1.111 +2 -2 + NTP_4_2_5P121 + +ChangeSet@1.1746, 2008-07-24 17:07:55+09:00, Amidamaru@yumi.mxiesoft.com + networking.c: + Fixing the mess + + gsoc_sntp/networking.c@1.7 +3 -1 + Fixing the mess + + gsoc_sntp/networking.c@1.6 +0 -2 + +ChangeSet@1.1745, 2008-07-24 16:53:33+09:00, Amidamaru@yumi.mxiesoft.com + networking.c: + redo include + + gsoc_sntp/networking.c@1.5 +2 -0 + redo include + +ChangeSet@1.1744, 2008-07-24 16:49:34+09:00, Amidamaru@yumi.mxiesoft.com + fixed includes + + gsoc_sntp/networking.c@1.4 +2 -2 + +ChangeSet@1.1739.1.8, 2008-07-24 03:47:48-04:00, stenn@pogo.udel.edu + header cleanup + + gsoc_sntp/networking.c@1.1.1.3 +2 -1 + header cleanup + + gsoc_sntp/networking.h@1.1.1.3 +3 -1 + header cleanup + +ChangeSet@1.1739.1.7, 2008-07-24 03:45:53-04:00, stenn@pogo.udel.edu + reorder headers + + gsoc_sntp/data_formats.h@1.3 +1 -1 + reorder headers + +ChangeSet@1.1739.1.6, 2008-07-24 03:44:24-04:00, stenn@pogo.udel.edu + hack ISC_PLATFORM_HAVEIPV6 + + gsoc_sntp/configure.ac@1.2 +1 -0 + hack ISC_PLATFORM_HAVEIPV6 + +ChangeSet@1.1739.1.5, 2008-07-24 03:23:31-04:00, stenn@pogo.udel.edu + header cleanup + + gsoc_sntp/networking.c@1.1.1.2 +0 -1 + header cleanup + +ChangeSet@1.1739.1.4, 2008-07-24 03:01:29-04:00, stenn@pogo.udel.edu + hacks + + gsoc_sntp/data_formats.h@1.2 +0 -3 + hacks + + gsoc_sntp/networking.c@1.1.1.1 +1 -1 + hacks + + gsoc_sntp/networking.h@1.1.1.2 +8 -8 + hacks + +ChangeSet@1.1739.1.3, 2008-07-24 02:06:52-04:00, stenn@pogo.udel.edu + cleanup + + gsoc_sntp/networking.h@1.1.1.1 +2 -5 + cleanup + +ChangeSet@1.1735.1.11, 2008-07-24 02:26:46+00:00, stenn@poog.il.thewrittenword.com + header file cleanup + + ChangeLog@1.197 +1 -0 + header file cleanup + + include/Makefile.am@1.30 +1 -0 + Added ntp_net.h + + include/ntp.h@1.147 +4 -2 + Header cleanup + + include/ntp_fp.h@1.14 +0 -6 + ntp_fp.h should have *never* been how we pulled in network stuff + + include/ntp_net.h@1.1 +14 -0 + BitKeeper file /home/stenn/ntp-dev/include/ntp_net.h + + include/ntp_net.h@1.0 +0 -0 + + include/recvbuff.h@1.15 +0 -1 + Header cleanup + +ChangeSet@1.1739.1.1, 2008-07-22 16:12:19-04:00, stenn@pogo.udel.edu + build infrastructure updates + + gsoc_sntp/:fetch-stubs@1.2 +7 -0 + updates + + gsoc_sntp/configure.ac@1.1 +89 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/configure.ac + + gsoc_sntp/configure.ac@1.0 +0 -0 + +ChangeSet@1.1737.1.1, 2008-07-23 03:52:14+09:00, Amidamaru@yumi.mxiesoft.com + log.h, log.c: + Changed name of debug output function to avoid name collision with opt flag variable + kod_management.c: + Changed from fgets to fscanf (easier data extraction) + + gsoc_sntp/Makefile@1.1.1.1 +16 -19 + + gsoc_sntp/Makefile.in@1.1.1.1 +3 -6 + + gsoc_sntp/kod_management.c@1.2 +22 -57 + Changed from fgets to fscanf (easier data extraction) + + gsoc_sntp/kod_management.h@1.2 +1 -1 + + gsoc_sntp/log.c@1.2 +1 -1 + Changed name of debug output function to avoid name collision with opt flag variable + + gsoc_sntp/log.h@1.2 +1 -1 + Changed name of debug output function to avoid name collision with opt flag variable + + gsoc_sntp/networking.c@1.2 +20 -11 + + gsoc_sntp/networking.h@1.2 +4 -4 + +ChangeSet@1.1739, 2008-07-22 14:38:08-04:00, stenn@pogo.udel.edu + added :fetch-stubs + + gsoc_sntp/:fetch-stubs@1.1 +13 -0 + BitKeeper file /pogo/users/stenn/ntp-dev-kuehn/gsoc_sntp/:fetch-stubs + + gsoc_sntp/:fetch-stubs@1.0 +0 -0 + +ChangeSet@1.1738, 2008-07-22 14:29:55-04:00, stenn@pogo.udel.edu + sntp fixes + + BitKeeper/deleted/.del-Makefile@1.2 +0 -0 + Delete: gsoc_sntp/Makefile + + BitKeeper/deleted/.del-Makefile.in@1.2 +0 -0 + Delete: gsoc_sntp/Makefile.in + + Makefile.am@1.77 +2 -0 + Add gsoc_sntp to the build + + gsoc_sntp/Makefile.am@1.2 +15 -18 + autogen stuff + + gsoc_sntp/libopts/COPYING.lgpl@1.2 +0 -0 + bk cp COPYING.lgpl ../gsoc_sntp/libopts/COPYING.lgpl + + gsoc_sntp/libopts/COPYING.lgpl@1.1, stenn@whimsy.udel.edu +502 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.lgpl + + gsoc_sntp/libopts/COPYING.lgpl@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/COPYING.mbsd@1.2 +0 -0 + bk cp COPYING.mbsd ../gsoc_sntp/libopts/COPYING.mbsd + + gsoc_sntp/libopts/COPYING.mbsd@1.1, stenn@whimsy.udel.edu +26 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.mbsd + + gsoc_sntp/libopts/COPYING.mbsd@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/MakeDefs.inc@1.2 +0 -0 + bk cp MakeDefs.inc ../gsoc_sntp/libopts/MakeDefs.inc + + gsoc_sntp/libopts/MakeDefs.inc@1.1, stenn@whimsy.udel.edu +0 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/MakeDefs.inc + + gsoc_sntp/libopts/MakeDefs.inc@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/Makefile.am@1.2 +0 -0 + bk cp Makefile.am ../gsoc_sntp/libopts/Makefile.am + + gsoc_sntp/libopts/Makefile.am@1.1, stenn@whimsy.udel.edu +24 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/Makefile.am + + gsoc_sntp/libopts/Makefile.am@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/README@1.2 +0 -0 + bk cp README ../gsoc_sntp/libopts/README + + gsoc_sntp/libopts/README@1.1, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/README + + gsoc_sntp/libopts/README@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts.c@1.2 +0 -0 + bk cp autoopts.c ../gsoc_sntp/libopts/autoopts.c + + gsoc_sntp/libopts/autoopts.c@1.1, stenn@whimsy.udel.edu +1120 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.c + + gsoc_sntp/libopts/autoopts.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts.h@1.2 +0 -0 + bk cp autoopts.h ../gsoc_sntp/libopts/autoopts.h + + gsoc_sntp/libopts/autoopts.h@1.1, stenn@whimsy.udel.edu +387 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.h + + gsoc_sntp/libopts/autoopts.h@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts/options.h@1.2 +0 -0 + bk cp autoopts/options.h ../gsoc_sntp/libopts/autoopts/options.h + + gsoc_sntp/libopts/autoopts/options.h@1.1, stenn@whimsy.udel.edu +977 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/options.h + + gsoc_sntp/libopts/autoopts/options.h@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.2 +0 -0 + bk cp autoopts/usage-txt.h ../gsoc_sntp/libopts/autoopts/usage-txt.h + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.1, stenn@whimsy.udel.edu +355 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/usage-txt.h + + gsoc_sntp/libopts/autoopts/usage-txt.h@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/boolean.c@1.2 +0 -0 + bk cp boolean.c ../gsoc_sntp/libopts/boolean.c + + gsoc_sntp/libopts/boolean.c@1.1, stenn@whimsy.udel.edu +106 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/boolean.c + + gsoc_sntp/libopts/boolean.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/compat.h@1.2 +0 -0 + bk cp compat/compat.h ../gsoc_sntp/libopts/compat/compat.h + + gsoc_sntp/libopts/compat/compat.h@1.1, stenn@whimsy.udel.edu +319 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/compat.h + + gsoc_sntp/libopts/compat/compat.h@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/pathfind.c@1.2 +0 -0 + bk cp compat/pathfind.c ../gsoc_sntp/libopts/compat/pathfind.c + + gsoc_sntp/libopts/compat/pathfind.c@1.1, stenn@whimsy.udel.edu +339 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/pathfind.c + + gsoc_sntp/libopts/compat/pathfind.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/snprintf.c@1.2 +0 -0 + bk cp compat/snprintf.c ../gsoc_sntp/libopts/compat/snprintf.c + + gsoc_sntp/libopts/compat/snprintf.c@1.1, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/snprintf.c + + gsoc_sntp/libopts/compat/snprintf.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/strchr.c@1.2 +0 -0 + bk cp compat/strchr.c ../gsoc_sntp/libopts/compat/strchr.c + + gsoc_sntp/libopts/compat/strchr.c@1.1, stenn@whimsy.udel.edu +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strchr.c + + gsoc_sntp/libopts/compat/strchr.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/strdup.c@1.2 +0 -0 + bk cp compat/strdup.c ../gsoc_sntp/libopts/compat/strdup.c + + gsoc_sntp/libopts/compat/strdup.c@1.1, stenn@whimsy.udel.edu +19 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strdup.c + + gsoc_sntp/libopts/compat/strdup.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/compat/windows-config.h@1.2 +0 -0 + bk cp compat/windows-config.h ../gsoc_sntp/libopts/compat/windows-config.h + + gsoc_sntp/libopts/compat/windows-config.h@1.1, stenn@whimsy.udel.edu +130 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/windows-config.h + + gsoc_sntp/libopts/compat/windows-config.h@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/configfile.c@1.2 +0 -0 + bk cp configfile.c ../gsoc_sntp/libopts/configfile.c + + gsoc_sntp/libopts/configfile.c@1.1, stenn@whimsy.udel.edu +1290 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/configfile.c + + gsoc_sntp/libopts/configfile.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/cook.c@1.2 +0 -0 + bk cp cook.c ../gsoc_sntp/libopts/cook.c + + gsoc_sntp/libopts/cook.c@1.1, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/cook.c + + gsoc_sntp/libopts/cook.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/enumeration.c@1.2 +0 -0 + bk cp enumeration.c ../gsoc_sntp/libopts/enumeration.c + + gsoc_sntp/libopts/enumeration.c@1.1, stenn@whimsy.udel.edu +498 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/enumeration.c + + gsoc_sntp/libopts/enumeration.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/environment.c@1.2 +0 -0 + bk cp environment.c ../gsoc_sntp/libopts/environment.c + + gsoc_sntp/libopts/environment.c@1.1, stenn@whimsy.udel.edu +279 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/environment.c + + gsoc_sntp/libopts/environment.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/genshell.c@1.2 +0 -0 + bk cp genshell.c ../gsoc_sntp/libopts/genshell.c + + gsoc_sntp/libopts/genshell.c@1.1, stenn@whimsy.udel.edu +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.c + + gsoc_sntp/libopts/genshell.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/genshell.h@1.2 +0 -0 + bk cp genshell.h ../gsoc_sntp/libopts/genshell.h + + gsoc_sntp/libopts/genshell.h@1.1, stenn@whimsy.udel.edu +149 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.h + + gsoc_sntp/libopts/genshell.h@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/libopts.c@1.2 +0 -0 + bk cp libopts.c ../gsoc_sntp/libopts/libopts.c + + gsoc_sntp/libopts/libopts.c@1.1, stenn@whimsy.udel.edu +30 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/libopts.c + + gsoc_sntp/libopts/libopts.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/load.c@1.2 +0 -0 + bk cp load.c ../gsoc_sntp/libopts/load.c + + gsoc_sntp/libopts/load.c@1.1, stenn@whimsy.udel.edu +563 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/load.c + + gsoc_sntp/libopts/load.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/m4/libopts.m4@1.2 +0 -0 + bk cp m4/libopts.m4 ../gsoc_sntp/libopts/m4/libopts.m4 + + gsoc_sntp/libopts/m4/libopts.m4@1.1, stenn@whimsy.udel.edu +509 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/libopts.m4 + + gsoc_sntp/libopts/m4/libopts.m4@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.2 +0 -0 + bk cp m4/liboptschk.m4 ../gsoc_sntp/libopts/m4/liboptschk.m4 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.1, stenn@whimsy.udel.edu +42 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/liboptschk.m4 + + gsoc_sntp/libopts/m4/liboptschk.m4@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/makeshell.c@1.2 +0 -0 + bk cp makeshell.c ../gsoc_sntp/libopts/makeshell.c + + gsoc_sntp/libopts/makeshell.c@1.1, stenn@whimsy.udel.edu +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/makeshell.c + + gsoc_sntp/libopts/makeshell.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/nested.c@1.2 +0 -0 + bk cp nested.c ../gsoc_sntp/libopts/nested.c + + gsoc_sntp/libopts/nested.c@1.1, stenn@whimsy.udel.edu +733 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/nested.c + + gsoc_sntp/libopts/nested.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/numeric.c@1.2 +0 -0 + bk cp numeric.c ../gsoc_sntp/libopts/numeric.c + + gsoc_sntp/libopts/numeric.c@1.1, stenn@whimsy.udel.edu +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/numeric.c + + gsoc_sntp/libopts/numeric.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/pgusage.c@1.2 +0 -0 + bk cp pgusage.c ../gsoc_sntp/libopts/pgusage.c + + gsoc_sntp/libopts/pgusage.c@1.1, stenn@whimsy.udel.edu +157 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/pgusage.c + + gsoc_sntp/libopts/pgusage.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/proto.h@1.2 +0 -0 + bk cp proto.h ../gsoc_sntp/libopts/proto.h + + gsoc_sntp/libopts/proto.h@1.1, stenn@whimsy.udel.edu +91 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/proto.h + + gsoc_sntp/libopts/proto.h@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/putshell.c@1.2 +0 -0 + bk cp putshell.c ../gsoc_sntp/libopts/putshell.c + + gsoc_sntp/libopts/putshell.c@1.1, stenn@whimsy.udel.edu +335 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/putshell.c + + gsoc_sntp/libopts/putshell.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/restore.c@1.2 +0 -0 + bk cp restore.c ../gsoc_sntp/libopts/restore.c + + gsoc_sntp/libopts/restore.c@1.1, stenn@whimsy.udel.edu +250 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/restore.c + + gsoc_sntp/libopts/restore.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/save.c@1.3 +0 -0 + bk cp save.c ../gsoc_sntp/libopts/save.c + + gsoc_sntp/libopts/save.c@1.2, stenn@whimsy.udel.edu +11 -2 + [Bug 902] Fix problems with the -6 flag + + gsoc_sntp/libopts/save.c@1.1, stenn@whimsy.udel.edu +512 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/save.c + + gsoc_sntp/libopts/save.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/sort.c@1.2 +0 -0 + bk cp sort.c ../gsoc_sntp/libopts/sort.c + + gsoc_sntp/libopts/sort.c@1.1, stenn@whimsy.udel.edu +359 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/sort.c + + gsoc_sntp/libopts/sort.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/stack.c@1.2 +0 -0 + bk cp stack.c ../gsoc_sntp/libopts/stack.c + + gsoc_sntp/libopts/stack.c@1.1, stenn@whimsy.udel.edu +269 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/stack.c + + gsoc_sntp/libopts/stack.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/streqvcmp.c@1.2 +0 -0 + bk cp streqvcmp.c ../gsoc_sntp/libopts/streqvcmp.c + + gsoc_sntp/libopts/streqvcmp.c@1.1, stenn@whimsy.udel.edu +289 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/streqvcmp.c + + gsoc_sntp/libopts/streqvcmp.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/text_mmap.c@1.2 +0 -0 + bk cp text_mmap.c ../gsoc_sntp/libopts/text_mmap.c + + gsoc_sntp/libopts/text_mmap.c@1.1, stenn@whimsy.udel.edu +363 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/text_mmap.c + + gsoc_sntp/libopts/text_mmap.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/tokenize.c@1.2 +0 -0 + bk cp tokenize.c ../gsoc_sntp/libopts/tokenize.c + + gsoc_sntp/libopts/tokenize.c@1.1, stenn@whimsy.udel.edu +321 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/tokenize.c + + gsoc_sntp/libopts/tokenize.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/usage.c@1.2 +0 -0 + bk cp usage.c ../gsoc_sntp/libopts/usage.c + + gsoc_sntp/libopts/usage.c@1.1, stenn@whimsy.udel.edu +740 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/usage.c + + gsoc_sntp/libopts/usage.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/libopts/version.c@1.2 +0 -0 + bk cp version.c ../gsoc_sntp/libopts/version.c + + gsoc_sntp/libopts/version.c@1.1, stenn@whimsy.udel.edu +178 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/version.c + + gsoc_sntp/libopts/version.c@1.0, stenn@whimsy.udel.edu +0 -0 + + gsoc_sntp/sntp-opts.def@1.2 +1 -1 + Update the copyright year + +ChangeSet@1.1436.1.96, 2008-07-22 11:41:26+02:00, burnicki@pogo.udel.edu + [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + + ChangeLog@1.1.1.39 +1 -0 + [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + + libntp/machines.c@1.19 +2 -2 + [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + +ChangeSet@1.1735.1.10, 2008-07-16 18:07:06-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P120 + TAG: NTP_4_2_5P120 + + ntpd/ntpd-opts.c@1.112 +2 -2 + NTP_4_2_5P120 + + ntpd/ntpd-opts.h@1.112 +3 -3 + NTP_4_2_5P120 + + ntpd/ntpd-opts.texi@1.111 +1 -1 + NTP_4_2_5P120 + + ntpd/ntpd.1@1.111 +2 -2 + NTP_4_2_5P120 + + ntpdc/ntpdc-opts.c@1.108 +2 -2 + NTP_4_2_5P120 + + ntpdc/ntpdc-opts.h@1.108 +3 -3 + NTP_4_2_5P120 + + ntpdc/ntpdc-opts.texi@1.107 +1 -1 + NTP_4_2_5P120 + + ntpdc/ntpdc.1@1.107 +2 -2 + NTP_4_2_5P120 + + ntpq/ntpq-opts.c@1.108 +2 -2 + NTP_4_2_5P120 + + ntpq/ntpq-opts.h@1.108 +3 -3 + NTP_4_2_5P120 + + ntpq/ntpq-opts.texi@1.107 +1 -1 + NTP_4_2_5P120 + + ntpq/ntpq.1@1.107 +2 -2 + NTP_4_2_5P120 + + packageinfo.sh@1.123 +1 -1 + NTP_4_2_5P120 + + sntp/sntp-opts.c@1.108 +2 -2 + NTP_4_2_5P120 + + sntp/sntp-opts.h@1.108 +3 -3 + NTP_4_2_5P120 + + sntp/sntp-opts.texi@1.107 +1 -1 + NTP_4_2_5P120 + + sntp/sntp.1@1.107 +2 -2 + NTP_4_2_5P120 + + util/ntp-keygen-opts.c@1.111 +2 -2 + NTP_4_2_5P120 + + util/ntp-keygen-opts.h@1.111 +3 -3 + NTP_4_2_5P120 + + util/ntp-keygen-opts.texi@1.110 +1 -1 + NTP_4_2_5P120 + + util/ntp-keygen.1@1.110 +2 -2 + NTP_4_2_5P120 + +ChangeSet@1.1735.1.9, 2008-07-16 17:13:00-04:00, stenn@whimsy.udel.edu + [Bug 1037]: buffer in subroutine was 1 byte short + + ChangeLog@1.196 +1 -0 + [Bug 1037]: buffer in subroutine was 1 byte short + + util/ntp-keygen.c@1.52 +1 -1 + [Bug 1037]: buffer in subroutine was 1 byte short + +ChangeSet@1.1735.1.8, 2008-07-16 06:22:25-04:00, stenn@whimsy.udel.edu + .del-genkeys.html: + Delete: html/genkeys.html + + BitKeeper/deleted/.del-genkeys.html@1.3 +0 -0 + Delete: html/genkeys.html + +ChangeSet@1.1735.1.7, 2008-07-16 06:17:22-04:00, stenn@whimsy.udel.edu + interleave documentation + + html/xleave.html@1.1 +32 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/xleave.html + + html/xleave.html@1.0 +0 -0 + +ChangeSet@1.1735.1.6, 2008-07-16 05:32:55-04:00, stenn@whimsy.udel.edu + configure.ac: cleanup, added wintime and bug 1028 options + + ChangeLog@1.195 +2 -0 + configure.ac: cleanup, added wintime and bug 1028 options + + configure.ac@1.415 +46 -6 + configure.ac: cleanup, added wintime and bug 1028 options + +ChangeSet@1.1735.1.5, 2008-07-16 05:26:43-04:00, stenn@whimsy.udel.edu + Bias and Interleave stuff from Dave Mills. + + ChangeLog@1.194 +3 -0 + Bias and Interleave stuff from Dave Mills. + + include/ntp.h@1.146 +12 -3 + Bias and Interleave stuff from Dave Mills. + + include/ntp_config.h@1.47 +1 -0 + Bias and Interleave stuff from Dave Mills. + + libntp/statestr.c@1.14 +2 -0 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_config.c@1.179 +5 -0 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_control.c@1.105 +13 -8 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_loopfilter.c@1.146 +8 -9 + separate phase/freq discipline. + + ntpd/ntp_parser.c@1.27 +1092 -1065 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_parser.h@1.12 +289 -285 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_parser.y@1.22 +4 -0 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_proto.c@1.274 +332 -160 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_refclock.c@1.80 +2 -2 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_request.c@1.74 +1 -2 + Bias and Interleave stuff from Dave Mills. + + ntpd/ntp_util.c@1.65 +4 -9 + Bias and Interleave stuff from Dave Mills. + +ChangeSet@1.1735.1.4, 2008-07-16 05:12:48-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.193 +1 -0 + Documentation updates from Dave Mills + + html/confopt.html@1.41 +28 -19 + Documentation updates from Dave Mills + + html/copyright.html@1.41 +1 -1 + Documentation updates from Dave Mills + + html/decode.html@1.2 +2 -2 + Documentation updates from Dave Mills + + html/keygen.html@1.12 +3 -2 + Documentation updates from Dave Mills + + html/monopt.html@1.28 +1 -1 + Documentation updates from Dave Mills + + html/ntpd.html@1.44 +2 -1 + Documentation updates from Dave Mills + + html/ntpq.html@1.30 +6 -2 + Documentation updates from Dave Mills + +ChangeSet@1.1735.1.3, 2008-07-16 05:06:03-04:00, stenn@whimsy.udel.edu + jitter.c: make NBUF about 10x bigger + + util/jitter.c@1.9 +1 -1 + jitter.c: make NBUF about 10x bigger + +ChangeSet@1.1735.1.2, 2008-07-15 03:44:23-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P119 + TAG: NTP_4_2_5P119 + + ntpd/ntpd-opts.c@1.111 +2 -2 + NTP_4_2_5P119 + + ntpd/ntpd-opts.h@1.111 +3 -3 + NTP_4_2_5P119 + + ntpd/ntpd-opts.texi@1.110 +1 -1 + NTP_4_2_5P119 + + ntpd/ntpd.1@1.110 +2 -2 + NTP_4_2_5P119 + + ntpdc/ntpdc-opts.c@1.107 +2 -2 + NTP_4_2_5P119 + + ntpdc/ntpdc-opts.h@1.107 +3 -3 + NTP_4_2_5P119 + + ntpdc/ntpdc-opts.texi@1.106 +1 -1 + NTP_4_2_5P119 + + ntpdc/ntpdc.1@1.106 +2 -2 + NTP_4_2_5P119 + + ntpq/ntpq-opts.c@1.107 +2 -2 + NTP_4_2_5P119 + + ntpq/ntpq-opts.h@1.107 +3 -3 + NTP_4_2_5P119 + + ntpq/ntpq-opts.texi@1.106 +1 -1 + NTP_4_2_5P119 + + ntpq/ntpq.1@1.106 +2 -2 + NTP_4_2_5P119 + + packageinfo.sh@1.122 +1 -1 + NTP_4_2_5P119 + + sntp/sntp-opts.c@1.107 +2 -2 + NTP_4_2_5P119 + + sntp/sntp-opts.h@1.107 +3 -3 + NTP_4_2_5P119 + + sntp/sntp-opts.texi@1.106 +1 -1 + NTP_4_2_5P119 + + sntp/sntp.1@1.106 +2 -2 + NTP_4_2_5P119 + + util/ntp-keygen-opts.c@1.110 +2 -2 + NTP_4_2_5P119 + + util/ntp-keygen-opts.h@1.110 +3 -3 + NTP_4_2_5P119 + + util/ntp-keygen-opts.texi@1.109 +1 -1 + NTP_4_2_5P119 + + util/ntp-keygen.1@1.109 +2 -2 + NTP_4_2_5P119 + +ChangeSet@1.1735.1.1, 2008-07-14 01:28:14-04:00, stenn@whimsy.udel.edu + [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen + + ChangeLog@1.192 +1 -0 + [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen + + util/ntp-keygen.c@1.51 +1 -1 + [Bug 1037] Use all 16 of the MD5 passwords generated by ntp-keygen + +ChangeSet@1.1737, 2008-07-09 05:45:39+09:00, Amidamaru@yumi.mxiesoft.com + networking.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.h + networking.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.c + + gsoc_sntp/networking.c@1.1 +278 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.c + + gsoc_sntp/networking.c@1.0 +0 -0 + + gsoc_sntp/networking.h@1.1 +48 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/networking.h + + gsoc_sntp/networking.h@1.0 +0 -0 + +ChangeSet@1.1736, 2008-07-09 05:14:24+09:00, Amidamaru@yumi.mxiesoft.com + ignore: + added config.guess config.h config.h.in config.log config.status config.sub + Makefile.in: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.in + netutils.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.c + header.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/header.h + sntp-opts.def: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/sntp-opts.def + netutils.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.h + kod_management.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.h + ignore: + added aclocal.m4 + kod_management.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.c + Makefile: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile + ignore: + added config.h + main.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/main.c + ignore: + added test.kod + log.c: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.c + data_formats.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/data_formats.h + log.h: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.h + Makefile.am: + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.am + + BitKeeper/etc/ignore@1.64 +1 -0 + added test.kod + + BitKeeper/etc/ignore@1.63 +1 -0 + added aclocal.m4 + + BitKeeper/etc/ignore@1.62 +6 -0 + added config.guess config.h config.h.in config.log config.status config.sub + + BitKeeper/etc/ignore@1.61 +1 -0 + added config.h + + gsoc_sntp/Makefile@1.1 +694 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile + + gsoc_sntp/Makefile@1.0 +0 -0 + + gsoc_sntp/Makefile.am@1.1 +69 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.am + + gsoc_sntp/Makefile.am@1.0 +0 -0 + + gsoc_sntp/Makefile.in@1.1 +694 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/Makefile.in + + gsoc_sntp/Makefile.in@1.0 +0 -0 + + gsoc_sntp/data_formats.h@1.1 +10 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/data_formats.h + + gsoc_sntp/data_formats.h@1.0 +0 -0 + + gsoc_sntp/header.h@1.1 +87 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/header.h + + gsoc_sntp/header.h@1.0 +0 -0 + + gsoc_sntp/kod_management.c@1.1 +258 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.c + + gsoc_sntp/kod_management.c@1.0 +0 -0 + + gsoc_sntp/kod_management.h@1.1 +20 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/kod_management.h + + gsoc_sntp/kod_management.h@1.0 +0 -0 + + gsoc_sntp/log.c@1.1 +52 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.c + + gsoc_sntp/log.c@1.0 +0 -0 + + gsoc_sntp/log.h@1.1 +21 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/log.h + + gsoc_sntp/log.h@1.0 +0 -0 + + gsoc_sntp/main.c@1.1 +86 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/main.c + + gsoc_sntp/main.c@1.0 +0 -0 + + gsoc_sntp/netutils.c@1.1 +320 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.c + + gsoc_sntp/netutils.c@1.0 +0 -0 + + gsoc_sntp/netutils.h@1.1 +10 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/netutils.h + + gsoc_sntp/netutils.h@1.0 +0 -0 + + gsoc_sntp/sntp-opts.def@1.1 +293 -0 + BitKeeper file /geom_mobile/home/Amidamaru/projects/sntp/repo/gsoc_sntp/sntp-opts.def + + gsoc_sntp/sntp-opts.def@1.0 +0 -0 + +ChangeSet@1.1735, 2008-06-06 19:56:21-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P118 + TAG: NTP_4_2_5P118 + + ntpd/ntpd-opts.c@1.110 +2 -2 + NTP_4_2_5P118 + + ntpd/ntpd-opts.h@1.110 +3 -3 + NTP_4_2_5P118 + + ntpd/ntpd-opts.texi@1.109 +1 -1 + NTP_4_2_5P118 + + ntpd/ntpd.1@1.109 +2 -2 + NTP_4_2_5P118 + + ntpdc/ntpdc-opts.c@1.106 +2 -2 + NTP_4_2_5P118 + + ntpdc/ntpdc-opts.h@1.106 +3 -3 + NTP_4_2_5P118 + + ntpdc/ntpdc-opts.texi@1.105 +1 -1 + NTP_4_2_5P118 + + ntpdc/ntpdc.1@1.105 +2 -2 + NTP_4_2_5P118 + + ntpq/ntpq-opts.c@1.106 +2 -2 + NTP_4_2_5P118 + + ntpq/ntpq-opts.h@1.106 +3 -3 + NTP_4_2_5P118 + + ntpq/ntpq-opts.texi@1.105 +1 -1 + NTP_4_2_5P118 + + ntpq/ntpq.1@1.105 +2 -2 + NTP_4_2_5P118 + + packageinfo.sh@1.121 +1 -1 + NTP_4_2_5P118 + + sntp/sntp-opts.c@1.106 +2 -2 + NTP_4_2_5P118 + + sntp/sntp-opts.h@1.106 +3 -3 + NTP_4_2_5P118 + + sntp/sntp-opts.texi@1.105 +1 -1 + NTP_4_2_5P118 + + sntp/sntp.1@1.105 +2 -2 + NTP_4_2_5P118 + + util/ntp-keygen-opts.c@1.109 +2 -2 + NTP_4_2_5P118 + + util/ntp-keygen-opts.h@1.109 +3 -3 + NTP_4_2_5P118 + + util/ntp-keygen-opts.texi@1.108 +1 -1 + NTP_4_2_5P118 + + util/ntp-keygen.1@1.108 +2 -2 + NTP_4_2_5P118 + +ChangeSet@1.1728.1.4, 2008-05-30 00:54:03-04:00, stenn@whimsy.udel.edu + Triggers are fired with an absolute (v. relative) path. + + BitKeeper/triggers/triggert@1.5 +3 -2 + Triggers are fired with an absolute (v. relative) path. + +ChangeSet@1.1728.1.3, 2008-05-23 03:00:07-04:00, stenn@whimsy.udel.edu + Poll time and local refclock documentation updates from Dave Mills + + ChangeLog@1.186.1.1 +2 -0 + Poll time and local refclock documentation updates from Dave Mills + + html/drivers/driver1.html@1.16 +3 -18 + local refclock documentation updates from Dave Mills + + ntpd/ntp_proto.c@1.273 +11 -2 + poll time updates from Dave Mills + +ChangeSet@1.1728.1.2, 2008-05-21 07:48:20-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P117 + TAG: NTP_4_2_5P117 + + ntpd/ntpd-opts.c@1.109 +2 -2 + NTP_4_2_5P117 + + ntpd/ntpd-opts.h@1.109 +3 -3 + NTP_4_2_5P117 + + ntpd/ntpd-opts.texi@1.108 +1 -1 + NTP_4_2_5P117 + + ntpd/ntpd.1@1.108 +2 -2 + NTP_4_2_5P117 + + ntpdc/ntpdc-opts.c@1.105 +2 -2 + NTP_4_2_5P117 + + ntpdc/ntpdc-opts.h@1.105 +3 -3 + NTP_4_2_5P117 + + ntpdc/ntpdc-opts.texi@1.104 +1 -1 + NTP_4_2_5P117 + + ntpdc/ntpdc.1@1.104 +2 -2 + NTP_4_2_5P117 + + ntpq/ntpq-opts.c@1.105 +2 -2 + NTP_4_2_5P117 + + ntpq/ntpq-opts.h@1.105 +3 -3 + NTP_4_2_5P117 + + ntpq/ntpq-opts.texi@1.104 +1 -1 + NTP_4_2_5P117 + + ntpq/ntpq.1@1.104 +2 -2 + NTP_4_2_5P117 + + packageinfo.sh@1.120 +1 -1 + NTP_4_2_5P117 + + sntp/sntp-opts.c@1.105 +2 -2 + NTP_4_2_5P117 + + sntp/sntp-opts.h@1.105 +3 -3 + NTP_4_2_5P117 + + sntp/sntp-opts.texi@1.104 +1 -1 + NTP_4_2_5P117 + + sntp/sntp.1@1.104 +2 -2 + NTP_4_2_5P117 + + util/ntp-keygen-opts.c@1.108 +2 -2 + NTP_4_2_5P117 + + util/ntp-keygen-opts.h@1.108 +3 -3 + NTP_4_2_5P117 + + util/ntp-keygen-opts.texi@1.107 +1 -1 + NTP_4_2_5P117 + + util/ntp-keygen.1@1.107 +2 -2 + NTP_4_2_5P117 + +ChangeSet@1.1731, 2008-05-21 09:32:13+05:30, venu@door.(none) + ChangeLog: + Corrected the comments for NMEA refclock driver. + + ChangeLog@1.190 +2 -1 + Corrected the comments for NMEA refclock driver. + +ChangeSet@1.1730, 2008-05-20 18:34:17+05:30, venu@door.(none) + ChangeLog: + Added comments for fixing the incorrect edge parameter passed to time_pps_kcbind. + refclock_nmea.c: + Fixed the incorrect edge parameter being passed to time_pps_kcbind. + + ChangeLog@1.189 +1 -0 + Added comments for fixing the incorrect edge parameter passed to time_pps_kcbind. + + ntpd/refclock_nmea.c@1.29 +1 -1 + Fixed the incorrect edge parameter being passed to time_pps_kcbind. + +ChangeSet@1.1729, 2008-05-20 08:13:42+00:00, gopal@pogo.udel.edu + ChangeLog: + Added comments for bug 985. + refclock_nmea.c: + [Bug 399] NMEA refclock driver does not honor time1 offset if flag3 set. + [Bug 985] Modifications to NMEA reference clock driver to support Accord GPS Clock. + ChangeLog: + Added comments for bug 399. + + ChangeLog@1.188 +1 -0 + Added comments for bug 399. + + ChangeLog@1.187 +1 -0 + Added comments for bug 985. + + ntpd/refclock_nmea.c@1.28 +24 -4 + [Bug 399] NMEA refclock driver does not honor time1 offset if flag3 set. + + ntpd/refclock_nmea.c@1.27 +111 -21 + [Bug 985] Modifications to NMEA reference clock driver to support Accord GPS Clock. + +ChangeSet@1.1436.1.95, 2008-05-20 03:51:01-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P5_RC1 + TAG: NTP_4_2_4P5_RC1 + + ntpd/ntpd-opts.c@1.50.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpd-opts.h@1.50.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpd-opts.texi@1.49.14.1 +8 -11 + NTP_4_2_4P5_RC1 + + ntpd/ntpd.1@1.48.14.1 +4 -4 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim-opts.c@1.50.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim-opts.h@1.50.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim-opts.texi@1.48.14.1 +3 -4 + NTP_4_2_4P5_RC1 + + ntpd/ntpdsim.1@1.48.14.1 +4 -4 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc-opts.c@1.50.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc-opts.h@1.50.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc-opts.texi@1.48.14.1 +5 -6 + NTP_4_2_4P5_RC1 + + ntpdc/ntpdc.1@1.48.14.1 +3 -3 + NTP_4_2_4P5_RC1 + + ntpq/ntpq-opts.c@1.52.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpq/ntpq-opts.h@1.52.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + ntpq/ntpq-opts.texi@1.49.14.1 +5 -6 + NTP_4_2_4P5_RC1 + + ntpq/ntpq.1@1.48.14.1 +3 -3 + NTP_4_2_4P5_RC1 + + packageinfo.sh@1.65.21.1 +2 -2 + NTP_4_2_4P5_RC1 + + sntp/sntp-opts.c@1.49.14.1 +2 -2 + NTP_4_2_4P5_RC1 + + sntp/sntp-opts.h@1.49.14.1 +3 -3 + NTP_4_2_4P5_RC1 + + sntp/sntp-opts.texi@1.46.14.1 +1 -1 + NTP_4_2_4P5_RC1 + + sntp/sntp.1@1.49.14.1 +2 -2 + NTP_4_2_4P5_RC1 + + util/ntp-keygen-opts.c@1.49.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + util/ntp-keygen-opts.h@1.49.14.1 +6 -7 + NTP_4_2_4P5_RC1 + + util/ntp-keygen-opts.texi@1.47.14.1 +7 -9 + NTP_4_2_4P5_RC1 + + util/ntp-keygen.1@1.47.14.1 +3 -3 + NTP_4_2_4P5_RC1 + +ChangeSet@1.1728, 2008-05-18 07:57:45-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P116 + TAG: NTP_4_2_5P116 + + ntpd/ntpd-opts.c@1.108 +4 -4 + NTP_4_2_5P116 + + ntpd/ntpd-opts.h@1.108 +4 -4 + NTP_4_2_5P116 + + ntpd/ntpd-opts.texi@1.107 +1 -1 + NTP_4_2_5P116 + + ntpd/ntpd.1@1.107 +2 -2 + NTP_4_2_5P116 + + ntpdc/ntpdc-opts.c@1.104 +4 -4 + NTP_4_2_5P116 + + ntpdc/ntpdc-opts.h@1.104 +4 -4 + NTP_4_2_5P116 + + ntpdc/ntpdc-opts.texi@1.103 +1 -1 + NTP_4_2_5P116 + + ntpdc/ntpdc.1@1.103 +2 -2 + NTP_4_2_5P116 + + ntpq/ntpq-opts.c@1.104 +4 -4 + NTP_4_2_5P116 + + ntpq/ntpq-opts.h@1.104 +4 -4 + NTP_4_2_5P116 + + ntpq/ntpq-opts.texi@1.103 +1 -1 + NTP_4_2_5P116 + + ntpq/ntpq.1@1.103 +2 -2 + NTP_4_2_5P116 + + packageinfo.sh@1.119 +1 -1 + NTP_4_2_5P116 + + sntp/sntp-opts.c@1.104 +5 -4 + NTP_4_2_5P116 + + sntp/sntp-opts.h@1.104 +6 -5 + NTP_4_2_5P116 + + sntp/sntp-opts.texi@1.103 +3 -2 + NTP_4_2_5P116 + + sntp/sntp.1@1.103 +3 -3 + NTP_4_2_5P116 + + util/ntp-keygen-opts.c@1.107 +4 -4 + NTP_4_2_5P116 + + util/ntp-keygen-opts.h@1.107 +4 -4 + NTP_4_2_5P116 + + util/ntp-keygen-opts.texi@1.106 +1 -1 + NTP_4_2_5P116 + + util/ntp-keygen.1@1.106 +2 -2 + NTP_4_2_5P116 + +ChangeSet@1.1436.1.94, 2008-05-18 05:14:37-04:00, stenn@whimsy.udel.edu + Start the 4.2.4p5 release candidate cycle + + packageinfo.sh@1.65.20.1 +1 -1 + Start the 4.2.4p5 release candidate cycle + +ChangeSet@1.1726, 2008-05-18 04:59:09-04:00, stenn@whimsy.udel.edu + fix a merge conflict + + ntpd/ntp_io.c@1.273 +1 -1 + fix a merge conflict + +ChangeSet@1.1724, 2008-05-15 07:44:36-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P115 + TAG: NTP_4_2_5P115 + + ntpd/ntpd-opts.c@1.107 +2 -2 + NTP_4_2_5P115 + + ntpd/ntpd-opts.h@1.107 +3 -3 + NTP_4_2_5P115 + + ntpd/ntpd-opts.texi@1.106 +1 -1 + NTP_4_2_5P115 + + ntpd/ntpd.1@1.106 +2 -2 + NTP_4_2_5P115 + + ntpdc/ntpdc-opts.c@1.103 +2 -2 + NTP_4_2_5P115 + + ntpdc/ntpdc-opts.h@1.103 +3 -3 + NTP_4_2_5P115 + + ntpdc/ntpdc-opts.texi@1.102 +1 -1 + NTP_4_2_5P115 + + ntpdc/ntpdc.1@1.102 +2 -2 + NTP_4_2_5P115 + + ntpq/ntpq-opts.c@1.103 +2 -2 + NTP_4_2_5P115 + + ntpq/ntpq-opts.h@1.103 +3 -3 + NTP_4_2_5P115 + + ntpq/ntpq-opts.texi@1.102 +1 -1 + NTP_4_2_5P115 + + ntpq/ntpq.1@1.102 +2 -2 + NTP_4_2_5P115 + + packageinfo.sh@1.118 +1 -1 + NTP_4_2_5P115 + + sntp/sntp-opts.c@1.103 +2 -2 + NTP_4_2_5P115 + + sntp/sntp-opts.h@1.103 +3 -3 + NTP_4_2_5P115 + + sntp/sntp-opts.texi@1.102 +1 -1 + NTP_4_2_5P115 + + sntp/sntp.1@1.102 +2 -2 + NTP_4_2_5P115 + + util/ntp-keygen-opts.c@1.106 +2 -2 + NTP_4_2_5P115 + + util/ntp-keygen-opts.h@1.106 +3 -3 + NTP_4_2_5P115 + + util/ntp-keygen-opts.texi@1.105 +1 -1 + NTP_4_2_5P115 + + util/ntp-keygen.1@1.105 +2 -2 + NTP_4_2_5P115 + +ChangeSet@1.1723, 2008-05-15 02:03:40-04:00, stenn@whimsy.udel.edu + [Bug 1022] Fix compilation problems with yesterday's commit + + ChangeLog@1.185 +1 -0 + [Bug 1022] Fix compilation problems with yesterday's commit + + include/ntp.h@1.145 +1 -1 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/ntp_intres.c@1.54 +5 -0 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/ntp_peer.c@1.113 +2 -0 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/ntp_request.c@1.73 +5 -1 + [Bug 1022] Fix compilation problems with yesterday's commit + + ntpd/refclock_acts.c@1.34 +1 -1 + [Bug 1022] Fix compilation problems with yesterday's commit + +ChangeSet@1.1722, 2008-05-13 07:49:21-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P114 + TAG: NTP_4_2_5P114 + + ntpd/ntpd-opts.c@1.106 +2 -2 + NTP_4_2_5P114 + + ntpd/ntpd-opts.h@1.106 +3 -3 + NTP_4_2_5P114 + + ntpd/ntpd-opts.texi@1.105 +2 -2 + NTP_4_2_5P114 + + ntpd/ntpd.1@1.105 +2 -2 + NTP_4_2_5P114 + + ntpdc/ntpdc-opts.c@1.102 +2 -2 + NTP_4_2_5P114 + + ntpdc/ntpdc-opts.h@1.102 +3 -3 + NTP_4_2_5P114 + + ntpdc/ntpdc-opts.texi@1.101 +2 -2 + NTP_4_2_5P114 + + ntpdc/ntpdc.1@1.101 +2 -2 + NTP_4_2_5P114 + + ntpq/ntpq-opts.c@1.102 +2 -2 + NTP_4_2_5P114 + + ntpq/ntpq-opts.h@1.102 +3 -3 + NTP_4_2_5P114 + + ntpq/ntpq-opts.texi@1.101 +2 -2 + NTP_4_2_5P114 + + ntpq/ntpq.1@1.101 +2 -2 + NTP_4_2_5P114 + + packageinfo.sh@1.117 +1 -1 + NTP_4_2_5P114 + + sntp/sntp-opts.c@1.102 +2 -2 + NTP_4_2_5P114 + + sntp/sntp-opts.h@1.102 +3 -3 + NTP_4_2_5P114 + + sntp/sntp-opts.texi@1.101 +1 -1 + NTP_4_2_5P114 + + sntp/sntp.1@1.101 +2 -2 + NTP_4_2_5P114 + + util/ntp-keygen-opts.c@1.105 +2 -2 + NTP_4_2_5P114 + + util/ntp-keygen-opts.h@1.105 +3 -3 + NTP_4_2_5P114 + + util/ntp-keygen-opts.texi@1.104 +2 -2 + NTP_4_2_5P114 + + util/ntp-keygen.1@1.104 +2 -2 + NTP_4_2_5P114 + +ChangeSet@1.1721, 2008-05-13 05:18:04-04:00, stenn@whimsy.udel.edu + Changes from Dave Mills (some backward-incompatible changes) + + ChangeLog@1.184 +71 -0 + Changes from Dave Mills (some backward-incompatible changes) + + html/accopt.html@1.27 +30 -21 + Documentation updated from Dave Mills + + html/accopt.html@1.26 +4 -5 + Documentation updates from Dave Mills + + html/authopt.html@1.47 +38 -24 + Documentation updated from Dave Mills + + html/bugs.html@1.4 +2 -2 + Documentation updated from Dave Mills + + html/build.html@1.23 +9 -10 + Documentation updated from Dave Mills + + html/clockopt.html@1.21 +5 -5 + Documentation updated from Dave Mills + + html/comdex.html@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/comdex.html + + html/comdex.html@1.0 +0 -0 + + html/config.html@1.21 +5 -5 + Documentation updated from Dave Mills + + html/confopt.html@1.40 +7 -6 + Documentation updated from Dave Mills + + html/copyright.html@1.39 +1 -2 + Documentation updated from Dave Mills + + html/debug.html@1.25 +20 -121 + Documentation updated from Dave Mills + + html/decode.html@1.1 +681 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/decode.html + + html/decode.html@1.0 +0 -0 + + html/genkeys.html@1.2 +1 -1 + Documentation updated from Dave Mills + + html/hints/winnt.html@1.19 +4 -3 + Documentation updated from Dave Mills + + html/index.html@1.37 +5 -4 + Documentation updated from Dave Mills + + html/kern.html@1.16 +2 -2 + Documentation updated from Dave Mills + + html/kernpps.html@1.2 +3 -0 + Documentation updated from Dave Mills + + html/manyopt.html@1.17 +22 -19 + Documentation updated from Dave Mills + + html/miscopt.html@1.40 +47 -69 + Documentation updated from Dave Mills + + html/monopt.html@1.27 +388 -356 + Documentation updated from Dave Mills + + html/monopt.html@1.26 +363 -330 + Documentation updates from Dave Mills + + html/msyslog.html@1.9 +3 -3 + Documentation updated from Dave Mills + + html/msyslog.html@1.8 +5 -2 + Documentation updates from Dave Mills + + html/ntp_conf.html@1.2 +3 -3 + Documentation updated from Dave Mills + + html/ntpd.html@1.43 +50 -71 + Documentation updated from Dave Mills + + html/ntpd.html@1.42 +2 -2 + Documentation updates from Dave Mills + + html/ntpdsim.html@1.7 +3 -3 + Documentation updated from Dave Mills + + html/ntpdsim_new.html@1.3 +3 -3 + Documentation updated from Dave Mills + + html/ntpq.html@1.29 +453 -190 + Documentation updated from Dave Mills + + html/ntptime.html@1.16 +3 -3 + Documentation updated from Dave Mills + + html/pic/alice15.gif@1.1 +587 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/alice15.gif + + html/pic/alice15.gif@1.0 +0 -0 + + html/pic/flatheads.gif@1.1 +292 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/flatheads.gif + + html/pic/flatheads.gif@1.0 +0 -0 + + html/pic/pogo7.gif@1.1 +309 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/pogo7.gif + + html/pic/pogo7.gif@1.0 +0 -0 + + html/pic/tonea.gif@1.2 +251 -347 + Documentation updated from Dave Mills + + html/pic/tribeb.gif@1.1 +675 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/tribeb.gif + + html/pic/tribeb.gif@1.0 +0 -0 + + html/pic/wingdorothy.gif@1.2 +226 -313 + Documentation updated from Dave Mills + + html/quick.html@1.19 +4 -4 + Documentation updated from Dave Mills + + html/rate.html@1.3 +24 -20 + Documentation updated from Dave Mills + + html/release.html@1.35 +2 -2 + Documentation updated from Dave Mills + + html/scripts/accopt.txt@1.1 +5 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/accopt.txt + + html/scripts/accopt.txt@1.0 +0 -0 + + html/scripts/authopt.txt@1.1 +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/authopt.txt + + html/scripts/authopt.txt@1.0 +0 -0 + + html/scripts/clockopt.txt@1.1 +5 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/clockopt.txt + + html/scripts/clockopt.txt@1.0 +0 -0 + + html/scripts/command.txt@1.2 +1 -0 + Documentation updated from Dave Mills + + html/scripts/config.txt@1.2 +1 -1 + Documentation updated from Dave Mills + + html/scripts/confopt.txt@1.1 +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/confopt.txt + + html/scripts/confopt.txt@1.0 +0 -0 + + html/scripts/external.txt@1.2 +6 -4 + Documentation updated from Dave Mills + + html/scripts/install.txt@1.2 +3 -2 + Documentation updated from Dave Mills + + html/scripts/manual.txt@1.2 +2 -2 + Documentation updated from Dave Mills + + html/scripts/miscopt.txt@1.1 +16 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/miscopt.txt + + html/scripts/miscopt.txt@1.0 +0 -0 + + html/scripts/monopt.txt@1.1 +5 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/monopt.txt + + html/scripts/monopt.txt@1.0 +0 -0 + + html/sitemap.html@1.2 +4 -4 + Documentation updated from Dave Mills + + html/sntp.html@1.6 +4 -4 + Documentation updated from Dave Mills + + include/ntp.h@1.144 +61 -46 + Changes from Dave Mills + + include/ntp_control.h@1.33 +47 -47 + Changes from Dave Mills + + include/ntp_crypto.h@1.44 +11 -10 + Changes from Dave Mills + + include/ntpd.h@1.117 +22 -24 + Changes from Dave Mills + + libntp/statestr.c@1.13 +120 -105 + Changes from Dave Mills (some backward-incompatible changes) + + ntpd/ntp_config.c@1.177 +4 -3 + Changes from Dave Mills + + ntpd/ntp_control.c@1.104 +98 -123 + Changes from Dave Mills + + ntpd/ntp_crypto.c@1.122 +337 -497 + Changes from Dave Mills + + ntpd/ntp_intres.c@1.53 +3 -6 + Changes from Dave Mills + + ntpd/ntp_loopfilter.c@1.145 +163 -177 + Changes from Dave Mills + + ntpd/ntp_monitor.c@1.23 +45 -35 + Changes from Dave Mills + + ntpd/ntp_parser.c@1.26 +964 -938 + Changes from Dave Mills + + ntpd/ntp_parser.h@1.11 +227 -223 + Changes from Dave Mills + + ntpd/ntp_parser.y@1.21 +7 -2 + Changes from Dave Mills + + ntpd/ntp_peer.c@1.112 +113 -81 + Changes from Dave Mills + + ntpd/ntp_proto.c@1.272 +511 -474 + Changes from Dave Mills + + ntpd/ntp_refclock.c@1.79 +13 -40 + Changes from Dave Mills + + ntpd/ntp_request.c@1.72 +4 -12 + Changes from Dave Mills + + ntpd/ntp_timer.c@1.47 +6 -8 + Changes from Dave Mills + + ntpd/ntp_util.c@1.64 +78 -35 + Changes from Dave Mills + + ntpd/ntpd.c@1.94 +1 -7 + Changes from Dave Mills + + ntpd/refclock_acts.c@1.33 +30 -21 + Changes from Dave Mills + + ntpd/refclock_atom.c@1.56 +4 -3 + Changes from Dave Mills + + ntpd/refclock_local.c@1.17 +11 -17 + Changes from Dave Mills + + ntpq/ntpq-subs.c@1.30 +125 -88 + Changes from Dave Mills (some backward-incompatible changes) + + ntpq/ntpq.c@1.74 +11 -12 + Changes from Dave Mills (some backward-incompatible changes) + + scripts/ntp-wait.in@1.6 +23 -11 + handle the new ntpq format + +ChangeSet@1.1436.1.93, 2008-04-11 18:41:57-04:00, stenn@whimsy.udel.edu + Solaris _XOPEN_SOURCE updates + + configure.ac@1.400.1.1 +5 -1 + Solaris _XOPEN_SOURCE updates + +ChangeSet@1.1436.11.3, 2008-04-10 02:09:52-04:00, stenn@pogo.udel.edu + Changelog cleanup + + ChangeLog@1.1.8.2 +2 -1 + +ChangeSet@1.1436.11.2, 2008-04-08 12:20:22+02:00, burnicki@pogo.udel.edu + Always sleep a little before calling doconfigure() to make sure the network is completely up. + + ntpd/ntp_intres.c@1.48.1.3 +5 -6 + Always sleep a little before calling doconfigure() to make sure the network is completely up. + +ChangeSet@1.1436.11.1, 2008-04-03 10:19:03-04:00, burnicki@pogo.udel.edu + [Bug 987] Wake up the resolver thread/process when a new interface has become available. + + ChangeLog@1.1.8.1 +1 -0 + [Bug 987] Wake up the resolver thread/process when a new interface has become available. + + include/ntpd.h@1.97.1.1 +5 -0 + Added vars used to wake up the resolver process/thread. + + ntpd/ntp_config.c@1.141.1.2 +34 -1 + Initialize synchronization variables when the resolver process/thread is started. + + ntpd/ntp_intres.c@1.48.1.2 +64 -65 + Enable the resolver to be woken up when a new interface has become available. + + ntpd/ntp_io.c@1.244.2.12 +25 -5 + Wake up the resolver thread/process when a new interface has become available. + +ChangeSet@1.1436.1.91, 2008-03-24 22:12:42-04:00, mayer@pogo.udel.edu + bugs 993 a d 959 + + ChangeLog@1.1.1.37 +2 -0 + bugs 993 a d 959 + +ChangeSet@1.1436.1.90, 2008-03-24 21:41:55-04:00, mayer@pogo.udel.edu + [Bug 959] Refclock on Windows not properly releasing recvbuffs + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.4 +25 -13 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + +ChangeSet@1.1436.1.89, 2008-03-24 21:40:32-04:00, mayer@pogo.udel.edu + [Bug 993] Windows: Fix memory leak when fetching system messages + + ports/winnt/libisc/isc_strerror.c@1.4.1.1 +78 -18 + [Bug 993] Windows: Fix memory leak when fetching system messages + +ChangeSet@1.1436.9.5, 2008-03-22 02:12:10-05:00, stenn@whimsy.udel.edu + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + ChangeLog@1.1.6.4 +1 -0 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + libisc/net.c@1.8.1.1 +1 -1 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + +ChangeSet@1.1436.9.4, 2008-03-22 02:02:36-05:00, stenn@whimsy.udel.edu + Update the copyright year + + ChangeLog@1.1.6.3 +8 -6 + Update the copyright year + + html/copyright.html@1.36.1.1 +1 -1 + Update the copyright year + + include/copyright.def@1.5.1.1 +1 -1 + Update the copyright year + +ChangeSet@1.1436.9.3, 2008-03-22 01:58:52-05:00, stenn@whimsy.udel.edu + Make autogen-generated files writable + + ntpd/Makefile.am@1.52.2.2 +1 -1 + Make autogen-generated files writable + + ntpdc/Makefile.am@1.33.1.2 +1 -1 + Make autogen-generated files writable + + ntpq/Makefile.am@1.25.1.2 +1 -1 + Make autogen-generated files writable + + sntp/Makefile.am@1.21.1.1 +1 -1 + Make autogen-generated files writable + + util/Makefile.am@1.34.1.2 +1 -1 + Make autogen-generated files writable + +ChangeSet@1.1436.10.1, 2008-03-16 09:15:13-04:00, burnicki@pogo.udel.edu + [Bug 957] Windows only: Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + + ChangeLog@1.1.7.1 +3 -0 + [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + + ports/winnt/ntpd/ntservice.c@1.9.1.1 +11 -2 + [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + +ChangeSet@1.1436.9.1, 2008-03-03 11:50:50+01:00, martin@pc-martin.py.meinberg.de + [Bug 532] nptdate timeout is too long if several servers are supplied + [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools + [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't + [Bug 908] ntpdate crashes sometimes + [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) + [Bug 997] ntpdate buffer too small and unsafe + Under Windows check whether NTP port in use under same conditions as under other OSs. + Fixed some typos and indents (tabs/spaces). + + ChangeLog@1.1.6.1 +10 -0 + [Bug 532] nptdate timeout is too long if several servers are supplied + [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools + [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't + [Bug 908] ntpdate crashes sometimes + [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) + [Bug 997] ntpdate buffer too small and unsafe + Under Windows check whether NTP port in use under same conditions as under other OSs. + Fixed some typos and indents (tabs/spaces). + + ntpdate/ntpdate.c@1.59.1.3 +101 -82 + [Bug 532] nptdate timeout is too long if several servers are supplied + [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools + [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't + [Bug 908] ntpdate crashes sometimes + [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) + [Bug 997] ntpdate buffer too small and unsafe + Under Windows check whether NTP port in use under same conditions as under other OSs. + Fixed some typos and indents (tabs/spaces). + +ChangeSet@1.1436.8.7, 2008-02-20 12:13:24+01:00, martin@pc-martin4. + [Bug 909] Define int32_t for Windows (backport from ntp-dev) + + ChangeLog@1.1.5.3 +1 -0 + [Bug 909] Define int32_t for Windows (backport from ntp-dev) + + ports/winnt/include/config.h@1.46.1.1 +2 -0 + [Bug 909] Define int32_t for Windows (backport from ntp-dev) + +ChangeSet@1.1436.8.6, 2008-02-19 11:08:55-05:00, burnicki@pogo.udel.edu + Fixed indentation. + + ntpd/ntp_io.c@1.244.2.11 +1 -1 + Fixed indentation. + +ChangeSet@1.1436.8.5, 2008-02-18 09:30:34-05:00, burnicki@pogo.udel.edu + Use new get_free_recv_buffer_alloc(). + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.3 +4 -4 + Use new get_free_recv_buffer_alloc(). + +ChangeSet@1.1436.8.4, 2008-02-17 17:48:29+00:00, kardel@pogo.udel.edu + recvbuff.c: + Bug 1000: add some pico optimizations + + libntp/recvbuff.c@1.26.1.3 +5 -8 + Bug 1000: add some pico optimizations + +ChangeSet@1.1436.8.3, 2008-02-17 08:38:07+00:00, kardel@pogo.udel.edu + ntpd.c: + Bug 1000: avoid timer() starvation during high load conditions + ChangeLog: + Bug 1000: additionally fix timer() starvation during high load + + ChangeLog@1.1.5.2 +1 -0 + Bug 1000: additionally fix timer() starvation during high load + + ntpd/ntpd.c@1.82.2.3 +11 -0 + Bug 1000: avoid timer() starvation during high load conditions + +ChangeSet@1.1436.8.2, 2008-02-17 08:10:59+00:00, kardel@pogo.udel.edu + recvbuff.c: + Bug 1000: replenish when having expeirenced empty free lists + + libntp/recvbuff.c@1.26.1.2 +1 -1 + Bug 1000: replenish when having expeirenced empty free lists + +ChangeSet@1.1436.8.1, 2008-02-17 07:31:29+00:00, kardel@pogo.udel.edu + recvbuff.c, recvbuff.h, ntp_io.c, ChangeLog: + Bug 1000: Potentially insufficient number of receive buffers at startup + + ChangeLog@1.1.5.1 +3 -0 + Bug 1000: Potentially insufficient number of receive buffers at startup + + include/recvbuff.h@1.11.1.2 +2 -1 + Bug 1000: Potentially insufficient number of receive buffers at startup + + libntp/recvbuff.c@1.26.1.1 +30 -11 + Bug 1000: Potentially insufficient number of receive buffers at startup + + ntpd/ntp_io.c@1.244.2.10 +6 -2 + Bug 1000: Potentially insufficient number of receive buffers at startup + +ChangeSet@1.1720, 2008-02-08 06:48:48-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P113 + TAG: NTP_4_2_5P113 + + ntpd/ntpd-opts.c@1.105 +2 -2 + NTP_4_2_5P113 + + ntpd/ntpd-opts.h@1.105 +3 -3 + NTP_4_2_5P113 + + ntpd/ntpd-opts.texi@1.104 +1 -1 + NTP_4_2_5P113 + + ntpd/ntpd.1@1.104 +2 -2 + NTP_4_2_5P113 + + ntpdc/ntpdc-opts.c@1.101 +2 -2 + NTP_4_2_5P113 + + ntpdc/ntpdc-opts.h@1.101 +3 -3 + NTP_4_2_5P113 + + ntpdc/ntpdc-opts.texi@1.100 +1 -1 + NTP_4_2_5P113 + + ntpdc/ntpdc.1@1.100 +2 -2 + NTP_4_2_5P113 + + ntpq/ntpq-opts.c@1.101 +2 -2 + NTP_4_2_5P113 + + ntpq/ntpq-opts.h@1.101 +3 -3 + NTP_4_2_5P113 + + ntpq/ntpq-opts.texi@1.100 +1 -1 + NTP_4_2_5P113 + + ntpq/ntpq.1@1.100 +2 -2 + NTP_4_2_5P113 + + packageinfo.sh@1.116 +1 -1 + NTP_4_2_5P113 + + sntp/sntp-opts.c@1.101 +2 -2 + NTP_4_2_5P113 + + sntp/sntp-opts.h@1.101 +3 -3 + NTP_4_2_5P113 + + sntp/sntp-opts.texi@1.100 +1 -1 + NTP_4_2_5P113 + + sntp/sntp.1@1.100 +2 -2 + NTP_4_2_5P113 + + util/ntp-keygen-opts.c@1.104 +2 -2 + NTP_4_2_5P113 + + util/ntp-keygen-opts.h@1.104 +3 -3 + NTP_4_2_5P113 + + util/ntp-keygen-opts.texi@1.103 +1 -1 + NTP_4_2_5P113 + + util/ntp-keygen.1@1.103 +2 -2 + NTP_4_2_5P113 + +ChangeSet@1.1719, 2008-02-08 05:59:25-05:00, stenn@whimsy.udel.edu + Updates and cleanup from Dave Mills + + ChangeLog@1.183 +1 -0 + Updates and cleanup from Dave Mills + + html/bugs.html@1.3 +7 -6 + Updates and cleanup from Dave Mills + + html/miscopt.html@1.39 +7 -10 + Updates and cleanup from Dave Mills + + html/monopt.html@1.25 +26 -16 + Updates and cleanup from Dave Mills + + html/rate.html@1.2 +19 -19 + Updates and cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.144 +0 -1 + Updates and cleanup from Dave Mills + + ntpd/ntp_proto.c@1.271 +50 -48 + Updates and cleanup from Dave Mills + +ChangeSet@1.1718, 2008-02-07 06:45:57-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P112 + TAG: NTP_4_2_5P112 + + ntpd/ntpd-opts.c@1.104 +2 -2 + NTP_4_2_5P112 + + ntpd/ntpd-opts.h@1.104 +3 -3 + NTP_4_2_5P112 + + ntpd/ntpd-opts.texi@1.103 +1 -1 + NTP_4_2_5P112 + + ntpd/ntpd.1@1.103 +2 -2 + NTP_4_2_5P112 + + ntpdc/ntpdc-opts.c@1.100 +2 -2 + NTP_4_2_5P112 + + ntpdc/ntpdc-opts.h@1.100 +3 -3 + NTP_4_2_5P112 + + ntpdc/ntpdc-opts.texi@1.99 +1 -1 + NTP_4_2_5P112 + + ntpdc/ntpdc.1@1.99 +2 -2 + NTP_4_2_5P112 + + ntpq/ntpq-opts.c@1.100 +2 -2 + NTP_4_2_5P112 + + ntpq/ntpq-opts.h@1.100 +3 -3 + NTP_4_2_5P112 + + ntpq/ntpq-opts.texi@1.99 +1 -1 + NTP_4_2_5P112 + + ntpq/ntpq.1@1.99 +2 -2 + NTP_4_2_5P112 + + packageinfo.sh@1.115 +1 -1 + NTP_4_2_5P112 + + sntp/sntp-opts.c@1.100 +2 -2 + NTP_4_2_5P112 + + sntp/sntp-opts.h@1.100 +3 -3 + NTP_4_2_5P112 + + sntp/sntp-opts.texi@1.99 +1 -1 + NTP_4_2_5P112 + + sntp/sntp.1@1.99 +2 -2 + NTP_4_2_5P112 + + util/ntp-keygen-opts.c@1.103 +2 -2 + NTP_4_2_5P112 + + util/ntp-keygen-opts.h@1.103 +3 -3 + NTP_4_2_5P112 + + util/ntp-keygen-opts.texi@1.102 +1 -1 + NTP_4_2_5P112 + + util/ntp-keygen.1@1.102 +2 -2 + NTP_4_2_5P112 + +ChangeSet@1.1717, 2008-02-07 01:30:59-05:00, stenn@whimsy.udel.edu + [Bug 995] Remove spurious ; from ntp-keygen.c + + ChangeLog@1.182 +1 -0 + [Bug 995] Remove spurious ; from ntp-keygen.c + + util/ntp-keygen.c@1.50 +1 -1 + [Bug 995] Remove spurious ; from ntp-keygen.c + +ChangeSet@1.1716, 2008-02-01 06:46:14-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P111 + TAG: NTP_4_2_5P111 + + ntpd/ntpd-opts.c@1.103 +2 -2 + NTP_4_2_5P111 + + ntpd/ntpd-opts.h@1.103 +3 -3 + NTP_4_2_5P111 + + ntpd/ntpd-opts.texi@1.102 +2 -2 + NTP_4_2_5P111 + + ntpd/ntpd.1@1.102 +2 -2 + NTP_4_2_5P111 + + ntpdc/ntpdc-opts.c@1.99 +2 -2 + NTP_4_2_5P111 + + ntpdc/ntpdc-opts.h@1.99 +3 -3 + NTP_4_2_5P111 + + ntpdc/ntpdc-opts.texi@1.98 +2 -2 + NTP_4_2_5P111 + + ntpdc/ntpdc.1@1.98 +2 -2 + NTP_4_2_5P111 + + ntpq/ntpq-opts.c@1.99 +2 -2 + NTP_4_2_5P111 + + ntpq/ntpq-opts.h@1.99 +3 -3 + NTP_4_2_5P111 + + ntpq/ntpq-opts.texi@1.98 +2 -2 + NTP_4_2_5P111 + + ntpq/ntpq.1@1.98 +2 -2 + NTP_4_2_5P111 + + packageinfo.sh@1.114 +1 -1 + NTP_4_2_5P111 + + sntp/sntp-opts.c@1.99 +2 -2 + NTP_4_2_5P111 + + sntp/sntp-opts.h@1.99 +3 -3 + NTP_4_2_5P111 + + sntp/sntp-opts.texi@1.98 +1 -1 + NTP_4_2_5P111 + + sntp/sntp.1@1.98 +2 -2 + NTP_4_2_5P111 + + util/ntp-keygen-opts.c@1.102 +2 -2 + NTP_4_2_5P111 + + util/ntp-keygen-opts.h@1.102 +3 -3 + NTP_4_2_5P111 + + util/ntp-keygen-opts.texi@1.101 +2 -2 + NTP_4_2_5P111 + + util/ntp-keygen.1@1.101 +2 -2 + NTP_4_2_5P111 + +ChangeSet@1.1715, 2008-02-01 01:42:27-05:00, stenn@whimsy.udel.edu + Cleanup from Dave Mills + + ChangeLog@1.181 +4 -3 + Cleanup from Dave Mills + + include/ntp.h@1.143 +3 -11 + Cleanup from Dave Mills + + include/ntpd.h@1.116 +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_config.c@1.176 +3 -3 + Cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.143 +3 -4 + Cleanup from Dave Mills + + ntpd/ntp_monitor.c@1.22 +11 -6 + Cleanup from Dave Mills + + ntpd/ntp_parser.c@1.25 +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_parser.y@1.20 +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_proto.c@1.270 +79 -116 + Cleanup from Dave Mills + + ntpd/ntp_timer.c@1.46 +0 -1 + Cleanup from Dave Mills + + ntpd/ntp_util.c@1.63 +5 -2 + Cleanup from Dave Mills + + ntpdc/ntpdc_ops.c@1.54 +1 -1 + Cleanup from Dave Mills + +ChangeSet@1.1714, 2008-01-27 21:42:55-05:00, mayer@pogo.udel.edu + [Bug #980] Direct ntptrace help to stdout + + ChangeLog@1.180 +1 -0 + [Bug #980] + + scripts/ntptrace.in@1.6 +1 -0 + [Bug #980] Direct help to stdout + +ChangeSet@1.1713, 2008-01-27 21:39:10-05:00, mayer@pogo.udel.edu + [Bug 959] Refclock on Windows not properly releasing recvbuffs + + ChangeLog@1.179 +1 -0 + Bug 959 + + libntp/recvbuff.c@1.27 +0 -4 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + + ports/winnt/ntpd/ntp_iocompletionport.c@1.33 +5 -9 + [Bug 959] Refclock on Windows not properly releasing recvbuffs + +ChangeSet@1.1712, 2008-01-27 21:06:48-05:00, mayer@pogo.udel.edu + Bug 993 + + ChangeLog@1.178 +1 -0 + Bug 993 + +ChangeSet@1.1711, 2008-01-27 21:05:20-05:00, mayer@pogo.udel.edu + [Bug 993] Fix memory leak when fetching system messages + + ports/winnt/libisc/isc_strerror.c@1.5 +78 -18 + [Bug 993] Fix memory leak when fetching system messages + +ChangeSet@1.1710, 2008-01-26 06:51:10-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P110 + TAG: NTP_4_2_5P110 + + ntpd/ntpd-opts.c@1.102 +2 -2 + NTP_4_2_5P110 + + ntpd/ntpd-opts.h@1.102 +3 -3 + NTP_4_2_5P110 + + ntpd/ntpd-opts.texi@1.101 +2 -2 + NTP_4_2_5P110 + + ntpd/ntpd.1@1.101 +2 -2 + NTP_4_2_5P110 + + ntpdc/ntpdc-opts.c@1.98 +2 -2 + NTP_4_2_5P110 + + ntpdc/ntpdc-opts.h@1.98 +3 -3 + NTP_4_2_5P110 + + ntpdc/ntpdc-opts.texi@1.97 +2 -2 + NTP_4_2_5P110 + + ntpdc/ntpdc.1@1.97 +2 -2 + NTP_4_2_5P110 + + ntpq/ntpq-opts.c@1.98 +2 -2 + NTP_4_2_5P110 + + ntpq/ntpq-opts.h@1.98 +3 -3 + NTP_4_2_5P110 + + ntpq/ntpq-opts.texi@1.97 +2 -2 + NTP_4_2_5P110 + + ntpq/ntpq.1@1.97 +2 -2 + NTP_4_2_5P110 + + packageinfo.sh@1.113 +1 -1 + NTP_4_2_5P110 + + sntp/sntp-opts.c@1.98 +2 -2 + NTP_4_2_5P110 + + sntp/sntp-opts.h@1.98 +3 -3 + NTP_4_2_5P110 + + sntp/sntp-opts.texi@1.97 +1 -1 + NTP_4_2_5P110 + + sntp/sntp.1@1.97 +2 -2 + NTP_4_2_5P110 + + util/ntp-keygen-opts.c@1.101 +2 -2 + NTP_4_2_5P110 + + util/ntp-keygen-opts.h@1.101 +3 -3 + NTP_4_2_5P110 + + util/ntp-keygen-opts.texi@1.100 +2 -2 + NTP_4_2_5P110 + + util/ntp-keygen.1@1.100 +2 -2 + NTP_4_2_5P110 + +ChangeSet@1.1709, 2008-01-26 04:02:52-05:00, stenn@whimsy.udel.edu + much cleanup, fixes, and changes from Dave Mills + + ChangeLog@1.177 +1 -0 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_crypto.c@1.121 +156 -177 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_intres.c@1.52 +4 -3 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_loopfilter.c@1.142 +176 -163 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_monitor.c@1.21 +4 -4 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_peer.c@1.111 +1 -2 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_proto.c@1.269 +218 -142 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_timer.c@1.45 +22 -28 + much cleanup, fixes, and changes from Dave Mills + + ntpd/ntp_util.c@1.62 +108 -91 + much cleanup, fixes, and changes from Dave Mills + +ChangeSet@1.1708, 2008-01-26 03:46:39-05:00, stenn@whimsy.udel.edu + ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. + + ChangeLog@1.176 +1 -0 + ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. + + ntpd/ntp_control.c@1.103 +1 -1 + ntp_control.c: LEAPTAB is a filestamp, not an unsigned. From Dave Mills. + +ChangeSet@1.1707, 2008-01-26 03:41:54-05:00, stenn@whimsy.udel.edu + ntp_config.c: ntp_minpoll fixes from Dave Mills + + ChangeLog@1.175 +1 -0 + ntp_config.c: ntp_minpoll fixes from Dave Mills + + ntpd/ntp_config.c@1.175 +4 -4 + ntp_config.c: ntp_minpoll fixes from Dave Mills + +ChangeSet@1.1706, 2008-01-26 03:36:11-05:00, stenn@whimsy.udel.edu + ntp-keygen updated from Dave Mills + + ChangeLog@1.174 +1 -0 + ntp-keygen updated from Dave Mills + + util/ntp-keygen.c@1.49 +614 -460 + ntp-keygen updated from Dave Mills + +ChangeSet@1.1705, 2008-01-26 03:30:14-05:00, stenn@whimsy.udel.edu + refresh epoch, throttle, and leap cleanup from Dave Mills + + ChangeLog@1.173 +1 -0 + refresh epoch, throttle, and leap cleanup from Dave Mills + + include/ntp.h@1.142 +9 -14 + refresh epoch, throttle, and leap cleanup from Dave Mills + + include/ntp_crypto.h@1.43 +1 -0 + refresh epoch, throttle, and leap cleanup from Dave Mills + + include/ntpd.h@1.115 +7 -16 + refresh epoch, throttle, and leap cleanup from Dave Mills + +ChangeSet@1.1704, 2008-01-26 03:16:13-05:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + BitKeeper/deleted/.del-footer.txt@1.2 +0 -0 + Delete: html/build/scripts/footer.txt + + BitKeeper/deleted/.del-groups.html@1.2 +0 -0 + Delete: html/groups.html + + BitKeeper/deleted/.del-ldisc.html@1.13 +0 -0 + Delete: html/ldisc.html + + BitKeeper/deleted/.del-links10.txt@1.2 +0 -0 + Delete: html/build/scripts/links10.txt + + BitKeeper/deleted/.del-links10.txt~2eb1ee39ee3ae750@1.3 +0 -0 + Delete: html/scripts/links10.txt + + BitKeeper/deleted/.del-links11.txt@1.2 +0 -0 + Delete: html/build/scripts/links11.txt + + BitKeeper/deleted/.del-links11.txt~6bbb69abc176cdfa@1.3 +0 -0 + Delete: html/scripts/links11.txt + + BitKeeper/deleted/.del-links12.txt@1.2 +0 -0 + Delete: html/build/scripts/links12.txt + + BitKeeper/deleted/.del-links12.txt~44ae7fa96b25e3d8@1.2 +0 -0 + Delete: html/scripts/links12.txt + + BitKeeper/deleted/.del-links7.txt@1.2 +0 -0 + Delete: html/build/scripts/links7.txt + + BitKeeper/deleted/.del-links7.txt~82fadd0532b4ef1f@1.5 +0 -0 + Delete: html/scripts/links7.txt + + BitKeeper/deleted/.del-links8.txt@1.2 +0 -0 + Delete: html/build/scripts/links8.txt + + BitKeeper/deleted/.del-links8.txt~af6a09ad412e8a40@1.3 +0 -0 + Delete: html/scripts/links8.txt + + BitKeeper/deleted/.del-links9.txt@1.2 +0 -0 + Delete: html/build/scripts/links9.txt + + BitKeeper/deleted/.del-links9.txt~8709272ab9515ec0@1.4 +0 -0 + Delete: html/scripts/links9.txt + + BitKeeper/deleted/.del-measure.html@1.12 +0 -0 + Delete: html/measure.html + + BitKeeper/deleted/.del-mx4200data.html@1.12 +0 -0 + Delete: html/mx4200data.html + + BitKeeper/deleted/.del-netbsd@1.4 +0 -0 + Delete: html/hints/netbsd + + html/hints/netbsd@1.3 +0 -0 + Rename: html/build/hints/netbsd -> html/hints/netbsd + + BitKeeper/deleted/.del-notes.html@1.19 +0 -0 + Delete: html/notes.html + + BitKeeper/deleted/.del-patches.html@1.19 +0 -0 + Delete: html/patches.html + + html/patches.html@1.18 +0 -0 + Rename: html/build/patches.html -> html/patches.html + + BitKeeper/deleted/.del-porting.html@1.15 +0 -0 + Delete: html/porting.html + + html/porting.html@1.14 +0 -0 + Rename: html/build/porting.html -> html/porting.html + + BitKeeper/deleted/.del-style.css@1.2 +0 -0 + Delete: html/build/scripts/style.css + + ChangeLog@1.172 +1 -0 + Documentation updates from Dave Mills + + html/accopt.html@1.25 +3 -3 + Documentation updates from Dave Mills + + html/assoc.html@1.26 +9 -9 + Documentation updates from Dave Mills + + html/audio.html@1.20 +3 -2 + Documentation updates from Dave Mills + + html/authopt.html@1.46 +123 -57 + Documentation updates from Dave Mills + + html/bugs.html@1.2 +8 -10 + Documentation updates from Dave Mills + + html/build.html@1.22 +53 -76 + Documentation updates from Dave Mills + + html/build.html@1.21 +0 -0 + Rename: html/build/build.html -> html/build.html + + html/clockopt.html@1.20 +4 -3 + Documentation updates from Dave Mills + + html/config.html@1.20 +48 -47 + Documentation updates from Dave Mills + + html/config.html@1.19 +0 -0 + Rename: html/build/config.html -> html/config.html + + html/confopt.html@1.39 +2 -2 + Documentation updates from Dave Mills + + html/copyright.html@1.38 +3 -4 + Documentation updates from Dave Mills + + html/debug.html@1.24 +2 -2 + Documentation updates from Dave Mills + + html/description_files/description.jpg@1.1 +761 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/description_files/description.jpg + + html/description_files/description.jpg@1.0 +0 -0 + + html/drivers/driver10.html@1.12 +46 -46 + Documentation updates from Dave Mills + + html/drivers/driver11.html@1.12 +55 -57 + Documentation updates from Dave Mills + + html/drivers/driver18.html@1.16 +2 -2 + Documentation updates from Dave Mills + + html/drivers/driver19.html@1.11 +48 -48 + Documentation updates from Dave Mills + + html/drivers/driver27.html@1.15 +0 -2 + Documentation updates from Dave Mills + + html/drivers/driver34.html@1.12 +67 -105 + Documentation updates from Dave Mills + + html/drivers/driver4.html@1.13 +3 -4 + Documentation updates from Dave Mills + + html/drivers/driver9.html@1.14 +50 -51 + Documentation updates from Dave Mills + + html/drivers/mx4200data.html@1.1 +1074 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/drivers/mx4200data.html + + html/drivers/mx4200data.html@1.0 +0 -0 + + html/gadget.html@1.2 +2 -1 + Documentation updates from Dave Mills + + html/genkeys.html@1.1 +94 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/genkeys.html + + html/genkeys.html@1.0 +0 -0 + + html/hints.html@1.17 +17 -16 + Documentation updates from Dave Mills + + html/hints.html@1.16 +0 -0 + Rename: html/build/hints.html -> html/hints.html + + html/hints/a-ux@1.4 +0 -0 + Rename: html/build/hints/a-ux -> html/hints/a-ux + + html/hints/aix@1.4 +0 -0 + Rename: html/build/hints/aix -> html/hints/aix + + html/hints/bsdi@1.4 +0 -0 + Rename: html/build/hints/bsdi -> html/hints/bsdi + + html/hints/changes@1.4 +0 -0 + Rename: html/build/hints/changes -> html/hints/changes + + html/hints/decosf1@1.4 +0 -0 + Rename: html/build/hints/decosf1 -> html/hints/decosf1 + + html/hints/decosf2@1.4 +0 -0 + Rename: html/build/hints/decosf2 -> html/hints/decosf2 + + html/hints/freebsd@1.4 +0 -0 + Rename: html/build/hints/freebsd -> html/hints/freebsd + + html/hints/hpux@1.4 +0 -0 + Rename: html/build/hints/hpux -> html/hints/hpux + + html/hints/linux@1.4 +0 -0 + Rename: html/build/hints/linux -> html/hints/linux + + html/hints/mpeix@1.4 +0 -0 + Rename: html/build/hints/mpeix -> html/hints/mpeix + + html/hints/notes-xntp-v3@1.4 +0 -0 + Rename: html/build/hints/notes-xntp-v3 -> html/hints/notes-xntp-v3 + + html/hints/parse@1.6 +1 -1 + Documentation updates from Dave Mills + + html/hints/parse@1.5 +0 -0 + Rename: html/build/hints/parse -> html/hints/parse + + html/hints/refclocks@1.4 +0 -0 + Rename: html/build/hints/refclocks -> html/hints/refclocks + + html/hints/rs6000@1.4 +0 -0 + Rename: html/build/hints/rs6000 -> html/hints/rs6000 + + html/hints/sco.html@1.10 +10 -9 + Documentation updates from Dave Mills + + html/hints/sco.html@1.9 +0 -0 + Rename: html/build/hints/sco.html -> html/hints/sco.html + + html/hints/sgi@1.4 +0 -0 + Rename: html/build/hints/sgi -> html/hints/sgi + + html/hints/solaris-dosynctodr.html@1.7 +11 -11 + Documentation updates from Dave Mills + + html/hints/solaris-dosynctodr.html@1.6 +0 -0 + Rename: html/build/hints/solaris-dosynctodr.html -> html/hints/solaris-dosynctodr.html + + html/hints/solaris.html@1.10 +1 -1 + Documentation updates from Dave Mills + + html/hints/solaris.html@1.9 +0 -0 + Rename: html/build/hints/solaris.html -> html/hints/solaris.html + + html/hints/solaris.xtra.4023118@1.4 +0 -0 + Rename: html/build/hints/solaris.xtra.4023118 -> html/hints/solaris.xtra.4023118 + + html/hints/solaris.xtra.4095849@1.4 +0 -0 + Rename: html/build/hints/solaris.xtra.4095849 -> html/hints/solaris.xtra.4095849 + + html/hints/solaris.xtra.S99ntpd@1.5 +0 -0 + Rename: html/build/hints/solaris.xtra.S99ntpd -> html/hints/solaris.xtra.S99ntpd + + html/hints/solaris.xtra.patchfreq@1.4 +0 -0 + Rename: html/build/hints/solaris.xtra.patchfreq -> html/hints/solaris.xtra.patchfreq + + html/hints/sun4@1.4 +0 -0 + Rename: html/build/hints/sun4 -> html/hints/sun4 + + html/hints/svr4-dell@1.4 +0 -0 + Rename: html/build/hints/svr4-dell -> html/hints/svr4-dell + + html/hints/svr4_package@1.4 +0 -0 + Rename: html/build/hints/svr4_package -> html/hints/svr4_package + + html/hints/todo@1.4 +0 -0 + Rename: html/build/hints/todo -> html/hints/todo + + html/hints/vxworks.html@1.9 +64 -61 + Documentation updates from Dave Mills + + html/hints/vxworks.html@1.8 +0 -0 + Rename: html/build/hints/vxworks.html -> html/hints/vxworks.html + + html/hints/winnt.html@1.18 +142 -239 + Documentation updates from Dave Mills + + html/hints/winnt.html@1.17 +0 -0 + Rename: html/build/hints/winnt.html -> html/hints/winnt.html + + html/howto.html@1.19 +31 -52 + Documentation updates from Dave Mills + + html/index.html@1.36 +28 -66 + Documentation updates from Dave Mills + + html/kern.html@1.15 +4 -5 + Documentation updates from Dave Mills + + html/kernpps.html@1.1 +47 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/kernpps.html + + html/kernpps.html@1.0 +0 -0 + + html/keygen.html@1.11 +17 -25 + Documentation updates from Dave Mills + + html/manyopt.html@1.16 +22 -32 + Documentation updates from Dave Mills + + html/miscopt.html@1.38 +8 -3 + Documentation updates from Dave Mills + + html/monopt.html@1.24 +360 -104 + Documentation updates from Dave Mills + + html/msyslog.html@1.7 +2 -2 + Documentation updates from Dave Mills + + html/ntpd.html@1.41 +2 -2 + Documentation updates from Dave Mills + + html/ntpdc.html@1.29 +2 -2 + Documentation updates from Dave Mills + + html/ntpdsim.html@1.6 +2 -2 + Documentation updates from Dave Mills + + html/ntpdsim_new.html@1.2 +4 -4 + Documentation updates from Dave Mills + + html/ntpq.html@1.28 +2 -2 + Documentation updates from Dave Mills + + html/ntptrace.html@1.14 +3 -2 + Documentation updates from Dave Mills + + html/pic/broad.gif@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/broad.gif + + html/pic/broad.gif@1.0 +0 -0 + + html/pic/peer.gif@1.1 +111 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/peer.gif + + html/pic/peer.gif@1.0 +0 -0 + + html/pps.html@1.19 +26 -20 + Documentation updates from Dave Mills + + html/prefer.html@1.16 +2 -10 + Documentation updates from Dave Mills + + html/quick.html@1.18 +26 -23 + Documentation updates from Dave Mills + + html/quick.html@1.17 +0 -0 + Rename: html/build/quick.html -> html/quick.html + + html/rate.html@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/rate.html + + html/rate.html@1.0 +0 -0 + + html/rdebug.html@1.16 +3 -4 + Documentation updates from Dave Mills + + html/refclock.html@1.33 +17 -30 + Documentation updates from Dave Mills + + html/release.html@1.34 +23 -33 + Documentation updates from Dave Mills + + html/scripts/audio.txt@1.1 +7 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/audio.txt + + html/scripts/audio.txt@1.0 +0 -0 + + html/scripts/command.txt@1.1 +10 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/command.txt + + html/scripts/command.txt@1.0 +0 -0 + + html/scripts/config.txt@1.1 +7 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/config.txt + + html/scripts/config.txt@1.0 +0 -0 + + html/scripts/external.txt@1.1 +13 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/external.txt + + html/scripts/external.txt@1.0 +0 -0 + + html/scripts/install.txt@1.1 +11 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/install.txt + + html/scripts/install.txt@1.0 +0 -0 + + html/scripts/manual.txt@1.1 +13 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/manual.txt + + html/scripts/manual.txt@1.0 +0 -0 + + html/scripts/misc.txt@1.1 +9 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/misc.txt + + html/scripts/misc.txt@1.0 +0 -0 + + html/scripts/refclock.txt@1.1 +7 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/scripts/refclock.txt + + html/scripts/refclock.txt@1.0 +0 -0 + + html/sitemap.html@1.1 +34 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/sitemap.html + + html/sitemap.html@1.0 +0 -0 + + html/sntp.html@1.5 +2 -3 + Documentation updates from Dave Mills + + html/tickadj.html@1.15 +8 -11 + Documentation updates from Dave Mills + +ChangeSet@1.1436.7.1, 2008-01-26 06:43:33+00:00, kardel@pogo.udel.edu + ntpdbase-opts.def, ChangeLog, cmd_args.c: + remove minimum interface update interval restriction + + ChangeLog@1.1.4.1 +2 -0 + remove minimum interface update interval restriction + + ntpd/cmd_args.c@1.45.3.3 +2 -2 + remove minimum interface update interval restriction + + ntpd/ntpdbase-opts.def@1.10.1.1 +1 -1 + remove minimum interface update interval restriction + +ChangeSet@1.1703, 2007-12-19 06:45:26-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P109 + TAG: NTP_4_2_5P109 + + ntpd/ntpd-opts.c@1.101 +2 -2 + NTP_4_2_5P109 + + ntpd/ntpd-opts.h@1.101 +3 -3 + NTP_4_2_5P109 + + ntpd/ntpd-opts.texi@1.100 +1 -1 + NTP_4_2_5P109 + + ntpd/ntpd.1@1.100 +2 -2 + NTP_4_2_5P109 + + ntpdc/ntpdc-opts.c@1.97 +2 -2 + NTP_4_2_5P109 + + ntpdc/ntpdc-opts.h@1.97 +3 -3 + NTP_4_2_5P109 + + ntpdc/ntpdc-opts.texi@1.96 +1 -1 + NTP_4_2_5P109 + + ntpdc/ntpdc.1@1.96 +2 -2 + NTP_4_2_5P109 + + ntpq/ntpq-opts.c@1.97 +2 -2 + NTP_4_2_5P109 + + ntpq/ntpq-opts.h@1.97 +3 -3 + NTP_4_2_5P109 + + ntpq/ntpq-opts.texi@1.96 +1 -1 + NTP_4_2_5P109 + + ntpq/ntpq.1@1.96 +2 -2 + NTP_4_2_5P109 + + packageinfo.sh@1.112 +1 -1 + NTP_4_2_5P109 + + sntp/sntp-opts.c@1.97 +2 -2 + NTP_4_2_5P109 + + sntp/sntp-opts.h@1.97 +3 -3 + NTP_4_2_5P109 + + sntp/sntp-opts.texi@1.96 +1 -1 + NTP_4_2_5P109 + + sntp/sntp.1@1.96 +2 -2 + NTP_4_2_5P109 + + util/ntp-keygen-opts.c@1.100 +2 -2 + NTP_4_2_5P109 + + util/ntp-keygen-opts.h@1.100 +3 -3 + NTP_4_2_5P109 + + util/ntp-keygen-opts.texi@1.99 +1 -1 + NTP_4_2_5P109 + + util/ntp-keygen.1@1.99 +2 -2 + NTP_4_2_5P109 + +ChangeSet@1.1702, 2007-12-18 12:05:55-05:00, burnicki@pogo.udel.edu + Account for changes due to bug 918. + + ports/winnt/libntp/libntp.dsp@1.32 +1 -1 + Account for changes due to bug 918. + +ChangeSet@1.1701, 2007-12-18 06:49:15-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P108 + TAG: NTP_4_2_5P108 + + ntpd/ntpd-opts.c@1.100 +2 -2 + NTP_4_2_5P108 + + ntpd/ntpd-opts.h@1.100 +3 -3 + NTP_4_2_5P108 + + ntpd/ntpd-opts.texi@1.99 +2 -2 + NTP_4_2_5P108 + + ntpd/ntpd.1@1.99 +2 -2 + NTP_4_2_5P108 + + ntpdc/ntpdc-opts.c@1.96 +2 -2 + NTP_4_2_5P108 + + ntpdc/ntpdc-opts.h@1.96 +3 -3 + NTP_4_2_5P108 + + ntpdc/ntpdc-opts.texi@1.95 +2 -2 + NTP_4_2_5P108 + + ntpdc/ntpdc.1@1.95 +2 -2 + NTP_4_2_5P108 + + ntpq/ntpq-opts.c@1.96 +2 -2 + NTP_4_2_5P108 + + ntpq/ntpq-opts.h@1.96 +3 -3 + NTP_4_2_5P108 + + ntpq/ntpq-opts.texi@1.95 +2 -2 + NTP_4_2_5P108 + + ntpq/ntpq.1@1.95 +2 -2 + NTP_4_2_5P108 + + packageinfo.sh@1.111 +1 -1 + NTP_4_2_5P108 + + sntp/sntp-opts.c@1.96 +2 -2 + NTP_4_2_5P108 + + sntp/sntp-opts.h@1.96 +3 -3 + NTP_4_2_5P108 + + sntp/sntp-opts.texi@1.95 +1 -1 + NTP_4_2_5P108 + + sntp/sntp.1@1.95 +2 -2 + NTP_4_2_5P108 + + util/ntp-keygen-opts.c@1.99 +2 -2 + NTP_4_2_5P108 + + util/ntp-keygen-opts.h@1.99 +3 -3 + NTP_4_2_5P108 + + util/ntp-keygen-opts.texi@1.98 +2 -2 + NTP_4_2_5P108 + + util/ntp-keygen.1@1.98 +2 -2 + NTP_4_2_5P108 + +ChangeSet@1.1700, 2007-12-18 04:02:42-05:00, stenn@whimsy.udel.edu + [Bug 918] Only use a native md5.h if MD5Init() is available + + ChangeLog@1.171 +1 -0 + [Bug 918] Only use a native md5.h if MD5Init() is available + + configure.ac@1.413 +2 -7 + [Bug 918] Only use a native md5.h if MD5Init() is available + + include/ntp_md5.h@1.3 +1 -1 + [Bug 918] Only use a native md5.h if MD5Init() is available + +ChangeSet@1.1689.1.1, 2007-12-16 12:16:08-05:00, mayer@pogo.udel.edu + Bug #830 Fix interface count + + ntpd/ntp_io.c@1.271 +3 -1 + Bug #830 Fix interface count + +ChangeSet@1.1698, 2007-12-16 06:49:22-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P107 + TAG: NTP_4_2_5P107 + + ntpd/ntpd-opts.c@1.99 +2 -2 + NTP_4_2_5P107 + + ntpd/ntpd-opts.h@1.99 +3 -3 + NTP_4_2_5P107 + + ntpd/ntpd-opts.texi@1.98 +2 -2 + NTP_4_2_5P107 + + ntpd/ntpd.1@1.98 +2 -2 + NTP_4_2_5P107 + + ntpdc/ntpdc-opts.c@1.95 +2 -2 + NTP_4_2_5P107 + + ntpdc/ntpdc-opts.h@1.95 +3 -3 + NTP_4_2_5P107 + + ntpdc/ntpdc-opts.texi@1.94 +2 -2 + NTP_4_2_5P107 + + ntpdc/ntpdc.1@1.94 +2 -2 + NTP_4_2_5P107 + + ntpq/ntpq-opts.c@1.95 +2 -2 + NTP_4_2_5P107 + + ntpq/ntpq-opts.h@1.95 +3 -3 + NTP_4_2_5P107 + + ntpq/ntpq-opts.texi@1.94 +2 -2 + NTP_4_2_5P107 + + ntpq/ntpq.1@1.94 +2 -2 + NTP_4_2_5P107 + + packageinfo.sh@1.110 +1 -1 + NTP_4_2_5P107 + + sntp/sntp-opts.c@1.95 +2 -2 + NTP_4_2_5P107 + + sntp/sntp-opts.h@1.95 +3 -3 + NTP_4_2_5P107 + + sntp/sntp-opts.texi@1.94 +1 -1 + NTP_4_2_5P107 + + sntp/sntp.1@1.94 +2 -2 + NTP_4_2_5P107 + + util/ntp-keygen-opts.c@1.98 +2 -2 + NTP_4_2_5P107 + + util/ntp-keygen-opts.h@1.98 +3 -3 + NTP_4_2_5P107 + + util/ntp-keygen-opts.texi@1.97 +2 -2 + NTP_4_2_5P107 + + util/ntp-keygen.1@1.97 +2 -2 + NTP_4_2_5P107 + +ChangeSet@1.1697, 2007-12-16 04:51:58-05:00, stenn@whimsy.udel.edu + [Bug 979] Provide ntptimeval if it is not otherwise present + + ChangeLog@1.170 +1 -0 + [Bug 979] Provide ntptimeval if it is not otherwise present + + include/ntp_syscall.h@1.8 +9 -0 + [Bug 979] Provide ntptimeval if it is not otherwise present + +ChangeSet@1.1696, 2007-12-16 02:44:58-05:00, stenn@whimsy.udel.edu + code cleanup + + ntpd/ntpd.c@1.93 +37 -35 + code cleanup + +ChangeSet@1.1695, 2007-12-15 23:29:17-05:00, stenn@whimsy.udel.edu + [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork + + ChangeLog@1.169 +1 -0 + [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork + + ntpd/ntpd.c@1.92 +4 -0 + [Bug 634] Re-instantiate syslog() and logfiles after the daemon fork + +ChangeSet@1.1694, 2007-12-15 22:41:36-05:00, stenn@whimsy.udel.edu + We no longer need to check for MD5Init() + + configure.ac@1.412 +0 -1 + We no longer need to check for MD5Init() + +ChangeSet@1.1693, 2007-12-15 07:33:48-05:00, stenn@whimsy.udel.edu + [Bug 952] Use md5 code with a friendlier license + + BitKeeper/deleted/.del-md5c.c@1.9 +0 -0 + Delete: libntp/md5c.c + + BitKeeper/deleted/.del-rsa_md5.h@1.8 +0 -0 + Delete: include/rsa_md5.h + + include/Makefile.am@1.29 +0 -1 + [Bug 952] Use md5 code with a friendlier license + + include/ntp_md5.h@1.2 +5 -1 + [Bug 952] Use md5 code with a friendlier license + +ChangeSet@1.1692, 2007-12-15 06:18:07-05:00, stenn@whimsy.udel.edu + [Bug 952] Use md5 code with a friendlier license + + ChangeLog@1.168 +1 -0 + [Bug 952] Use md5 code with a friendlier license + + include/isc/Makefile.am@1.7 +1 -0 + [Bug 952] Use md5 code with a friendlier license + + include/isc/md5.h@1.1 +73 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/include/isc/md5.h + + include/isc/md5.h@1.0 +0 -0 + + libisc/md5.c@1.1 +251 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/libisc/md5.c + + libisc/md5.c@1.0 +0 -0 + + libntp/Makefile.am@1.40 +2 -2 + [Bug 952] Use md5 code with a friendlier license + +ChangeSet@1.1691, 2007-12-13 06:46:42-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P106 + TAG: NTP_4_2_5P106 + + ntpd/ntpd-opts.c@1.98 +2 -2 + NTP_4_2_5P106 + + ntpd/ntpd-opts.h@1.98 +3 -3 + NTP_4_2_5P106 + + ntpd/ntpd-opts.texi@1.97 +2 -2 + NTP_4_2_5P106 + + ntpd/ntpd.1@1.97 +2 -2 + NTP_4_2_5P106 + + ntpdc/ntpdc-opts.c@1.94 +2 -2 + NTP_4_2_5P106 + + ntpdc/ntpdc-opts.h@1.94 +3 -3 + NTP_4_2_5P106 + + ntpdc/ntpdc-opts.texi@1.93 +2 -2 + NTP_4_2_5P106 + + ntpdc/ntpdc.1@1.93 +2 -2 + NTP_4_2_5P106 + + ntpq/ntpq-opts.c@1.94 +2 -2 + NTP_4_2_5P106 + + ntpq/ntpq-opts.h@1.94 +3 -3 + NTP_4_2_5P106 + + ntpq/ntpq-opts.texi@1.93 +2 -2 + NTP_4_2_5P106 + + ntpq/ntpq.1@1.93 +2 -2 + NTP_4_2_5P106 + + packageinfo.sh@1.109 +1 -1 + NTP_4_2_5P106 + + sntp/sntp-opts.c@1.94 +2 -2 + NTP_4_2_5P106 + + sntp/sntp-opts.h@1.94 +3 -3 + NTP_4_2_5P106 + + sntp/sntp-opts.texi@1.93 +1 -1 + NTP_4_2_5P106 + + sntp/sntp.1@1.93 +2 -2 + NTP_4_2_5P106 + + util/ntp-keygen-opts.c@1.97 +2 -2 + NTP_4_2_5P106 + + util/ntp-keygen-opts.h@1.97 +3 -3 + NTP_4_2_5P106 + + util/ntp-keygen-opts.texi@1.96 +3 -4 + NTP_4_2_5P106 + + util/ntp-keygen.1@1.96 +2 -2 + NTP_4_2_5P106 + +ChangeSet@1.1690, 2007-12-13 04:55:28-05:00, stenn@whimsy.udel.edu + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + ChangeLog@1.167 +2 -1 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + + libisc/net.c@1.9 +1 -1 + [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + +ChangeSet@1.1689, 2007-12-13 04:22:19-05:00, stenn@whimsy.udel.edu + hack around a problem + + ntpd/ntp_io.c@1.270 +1 -1 + hack around a problem + +ChangeSet@1.1685.1.1, 2007-12-13 03:47:59-05:00, stenn@whimsy.udel.edu + Clean up the logfile/syslog setup + + ChangeLog@1.164.1.1 +1 -0 + Clean up the logfile/syslog setup + + include/ntpd.h@1.114 +2 -0 + Cleanup log setup + + ntpd/ntp_config.c@1.174 +159 -165 + Cleanup log setup + + ntpd/ntpd.c@1.91 +9 -7 + Cleanup log setup + +ChangeSet@1.1687, 2007-12-12 16:59:29-05:00, mayer@pogo.udel.edu + [Bug 830] + + ChangeLog@1.165 +1 -0 + [Bug 830] + +ChangeSet@1.1686, 2007-12-12 16:57:34-05:00, mayer@pogo.udel.edu + [Bug #830] Fix the checking order of the interface options + + ntpd/ntp_io.c@1.269 +15 -39 + [Bug #830] Fix the checking order of the interface options + +ChangeSet@1.1685, 2007-12-05 06:46:56-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P105 + TAG: NTP_4_2_5P105 + + ntpd/ntpd-opts.c@1.97 +2 -2 + NTP_4_2_5P105 + + ntpd/ntpd-opts.h@1.97 +3 -3 + NTP_4_2_5P105 + + ntpd/ntpd-opts.texi@1.96 +1 -1 + NTP_4_2_5P105 + + ntpd/ntpd.1@1.96 +2 -2 + NTP_4_2_5P105 + + ntpdc/ntpdc-opts.c@1.93 +2 -2 + NTP_4_2_5P105 + + ntpdc/ntpdc-opts.h@1.93 +3 -3 + NTP_4_2_5P105 + + ntpdc/ntpdc-opts.texi@1.92 +1 -1 + NTP_4_2_5P105 + + ntpdc/ntpdc.1@1.92 +2 -2 + NTP_4_2_5P105 + + ntpq/ntpq-opts.c@1.93 +2 -2 + NTP_4_2_5P105 + + ntpq/ntpq-opts.h@1.93 +3 -3 + NTP_4_2_5P105 + + ntpq/ntpq-opts.texi@1.92 +1 -1 + NTP_4_2_5P105 + + ntpq/ntpq.1@1.92 +2 -2 + NTP_4_2_5P105 + + packageinfo.sh@1.108 +1 -1 + NTP_4_2_5P105 + + sntp/sntp-opts.c@1.93 +2 -2 + NTP_4_2_5P105 + + sntp/sntp-opts.h@1.93 +3 -3 + NTP_4_2_5P105 + + sntp/sntp-opts.texi@1.92 +1 -1 + NTP_4_2_5P105 + + sntp/sntp.1@1.92 +2 -2 + NTP_4_2_5P105 + + util/ntp-keygen-opts.c@1.96 +2 -2 + NTP_4_2_5P105 + + util/ntp-keygen-opts.h@1.96 +3 -3 + NTP_4_2_5P105 + + util/ntp-keygen-opts.texi@1.95 +2 -2 + NTP_4_2_5P105 + + util/ntp-keygen.1@1.95 +2 -2 + NTP_4_2_5P105 + +ChangeSet@1.1684, 2007-12-05 02:21:17-05:00, stenn@whimsy.udel.edu + [Bug 970] Lose obsolete -g flag to ntp-keygen + + ChangeLog@1.164 +1 -0 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.c@1.95 +28 -58 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.def@1.11 +0 -12 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.h@1.95 +20 -29 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen-opts.texi@1.94 +1 -18 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen.1@1.94 +1 -8 + [Bug 970] Lose obsolete -g flag to ntp-keygen + + util/ntp-keygen.c@1.48 +0 -4 + [Bug 970] Lose obsolete -g flag to ntp-keygen + +ChangeSet@1.1683, 2007-12-05 01:57:39-05:00, stenn@whimsy.udel.edu + The -e flag to ntp-keygen can write GQ keys now, too. + + ChangeLog@1.163 +1 -0 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.c@1.94 +2 -2 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.def@1.10 +19 -19 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.h@1.94 +1 -1 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen-opts.texi@1.93 +4 -4 + The -e flag to ntp-keygen can write GQ keys now, too. + + util/ntp-keygen.1@1.93 +4 -4 + The -e flag to ntp-keygen can write GQ keys now, too. + +ChangeSet@1.1682, 2007-12-05 01:34:40-05:00, stenn@whimsy.udel.edu + Fixes from Dave Mills + + ChangeLog@1.162 +1 -0 + sys_survivors and hpoll cleanup from Dave Mills + + ChangeLog@1.161 +1 -0 + sys_poll cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.141 +6 -7 + sys_poll cleanup from Dave Mills + + ntpd/ntp_proto.c@1.268 +9 -6 + sys_survivors and hpoll cleanup from Dave Mills + +ChangeSet@1.1681, 2007-12-05 01:24:01-05:00, stenn@whimsy.udel.edu + maximum-likelihood digit and DSYNC fixes from Dave Mills + + ChangeLog@1.160 +1 -0 + maximum-likelihood digit and DSYNC fixes from Dave Mills + + ntpd/refclock_wwv.c@1.72 +11 -15 + maximum-likelihood digit and DSYNC fixes from Dave Mills + +ChangeSet@1.1680, 2007-11-27 06:45:40-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P104 + TAG: NTP_4_2_5P104 + + ntpd/ntpd-opts.c@1.96 +2 -2 + NTP_4_2_5P104 + + ntpd/ntpd-opts.h@1.96 +3 -3 + NTP_4_2_5P104 + + ntpd/ntpd-opts.texi@1.95 +1 -1 + NTP_4_2_5P104 + + ntpd/ntpd.1@1.95 +2 -2 + NTP_4_2_5P104 + + ntpdc/ntpdc-opts.c@1.92 +2 -2 + NTP_4_2_5P104 + + ntpdc/ntpdc-opts.h@1.92 +3 -3 + NTP_4_2_5P104 + + ntpdc/ntpdc-opts.texi@1.91 +1 -1 + NTP_4_2_5P104 + + ntpdc/ntpdc.1@1.91 +2 -2 + NTP_4_2_5P104 + + ntpq/ntpq-opts.c@1.92 +2 -2 + NTP_4_2_5P104 + + ntpq/ntpq-opts.h@1.92 +3 -3 + NTP_4_2_5P104 + + ntpq/ntpq-opts.texi@1.91 +1 -1 + NTP_4_2_5P104 + + ntpq/ntpq.1@1.91 +2 -2 + NTP_4_2_5P104 + + packageinfo.sh@1.107 +1 -1 + NTP_4_2_5P104 + + sntp/sntp-opts.c@1.92 +2 -2 + NTP_4_2_5P104 + + sntp/sntp-opts.h@1.92 +3 -3 + NTP_4_2_5P104 + + sntp/sntp-opts.texi@1.91 +1 -1 + NTP_4_2_5P104 + + sntp/sntp.1@1.91 +2 -2 + NTP_4_2_5P104 + + util/ntp-keygen-opts.c@1.93 +2 -2 + NTP_4_2_5P104 + + util/ntp-keygen-opts.h@1.93 +3 -3 + NTP_4_2_5P104 + + util/ntp-keygen-opts.texi@1.92 +1 -1 + NTP_4_2_5P104 + + util/ntp-keygen.1@1.92 +2 -2 + NTP_4_2_5P104 + +ChangeSet@1.1679, 2007-11-26 17:04:10-05:00, stenn@whimsy.udel.edu + [Bug 967] preemptable associations are lost forever on a step + + ChangeLog@1.159 +1 -0 + [Bug 967] preemptable associations are lost forever on a step + + ntpd/ntp_peer.c@1.110 +0 -3 + [Bug 967] preemptable associations are lost forever on a step + +ChangeSet@1.1678, 2007-11-25 06:45:57-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P103 + TAG: NTP_4_2_5P103 + + ntpd/ntpd-opts.c@1.95 +2 -2 + NTP_4_2_5P103 + + ntpd/ntpd-opts.h@1.95 +3 -3 + NTP_4_2_5P103 + + ntpd/ntpd-opts.texi@1.94 +1 -1 + NTP_4_2_5P103 + + ntpd/ntpd.1@1.94 +2 -2 + NTP_4_2_5P103 + + ntpdc/ntpdc-opts.c@1.91 +2 -2 + NTP_4_2_5P103 + + ntpdc/ntpdc-opts.h@1.91 +3 -3 + NTP_4_2_5P103 + + ntpdc/ntpdc-opts.texi@1.90 +1 -1 + NTP_4_2_5P103 + + ntpdc/ntpdc.1@1.90 +2 -2 + NTP_4_2_5P103 + + ntpq/ntpq-opts.c@1.91 +2 -2 + NTP_4_2_5P103 + + ntpq/ntpq-opts.h@1.91 +3 -3 + NTP_4_2_5P103 + + ntpq/ntpq-opts.texi@1.90 +1 -1 + NTP_4_2_5P103 + + ntpq/ntpq.1@1.90 +2 -2 + NTP_4_2_5P103 + + packageinfo.sh@1.106 +1 -1 + NTP_4_2_5P103 + + sntp/sntp-opts.c@1.91 +2 -2 + NTP_4_2_5P103 + + sntp/sntp-opts.h@1.91 +3 -3 + NTP_4_2_5P103 + + sntp/sntp-opts.texi@1.90 +1 -1 + NTP_4_2_5P103 + + sntp/sntp.1@1.90 +2 -2 + NTP_4_2_5P103 + + util/ntp-keygen-opts.c@1.92 +2 -2 + NTP_4_2_5P103 + + util/ntp-keygen-opts.h@1.92 +3 -3 + NTP_4_2_5P103 + + util/ntp-keygen-opts.texi@1.91 +1 -1 + NTP_4_2_5P103 + + util/ntp-keygen.1@1.91 +2 -2 + NTP_4_2_5P103 + +ChangeSet@1.1673.1.2, 2007-11-24 18:52:51-05:00, stenn@whimsy.udel.edu + documentation update from Dave Mills + + html/assoc.html@1.25 +8 -8 + documentation update from Dave Mills + + html/bugs.html@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/bugs.html + + html/bugs.html@1.0 +0 -0 + +ChangeSet@1.1676, 2007-11-24 18:50:51-05:00, stenn@pogo.udel.edu + [CID 48] missing "else" clause + + ChangeLog@1.158 +1 -0 + [CID 48] missing "else" clause + +ChangeSet@1.1673.1.1, 2007-11-24 06:45:27-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P102 + TAG: NTP_4_2_5P102 + + ntpd/ntpd-opts.c@1.94 +2 -2 + NTP_4_2_5P102 + + ntpd/ntpd-opts.h@1.94 +3 -3 + NTP_4_2_5P102 + + ntpd/ntpd-opts.texi@1.93 +1 -1 + NTP_4_2_5P102 + + ntpd/ntpd.1@1.93 +2 -2 + NTP_4_2_5P102 + + ntpdc/ntpdc-opts.c@1.90 +2 -2 + NTP_4_2_5P102 + + ntpdc/ntpdc-opts.h@1.90 +3 -3 + NTP_4_2_5P102 + + ntpdc/ntpdc-opts.texi@1.89 +1 -1 + NTP_4_2_5P102 + + ntpdc/ntpdc.1@1.89 +2 -2 + NTP_4_2_5P102 + + ntpq/ntpq-opts.c@1.90 +2 -2 + NTP_4_2_5P102 + + ntpq/ntpq-opts.h@1.90 +3 -3 + NTP_4_2_5P102 + + ntpq/ntpq-opts.texi@1.89 +1 -1 + NTP_4_2_5P102 + + ntpq/ntpq.1@1.89 +2 -2 + NTP_4_2_5P102 + + packageinfo.sh@1.105 +1 -1 + NTP_4_2_5P102 + + sntp/sntp-opts.c@1.90 +2 -2 + NTP_4_2_5P102 + + sntp/sntp-opts.h@1.90 +3 -3 + NTP_4_2_5P102 + + sntp/sntp-opts.texi@1.89 +1 -1 + NTP_4_2_5P102 + + sntp/sntp.1@1.89 +2 -2 + NTP_4_2_5P102 + + util/ntp-keygen-opts.c@1.91 +2 -2 + NTP_4_2_5P102 + + util/ntp-keygen-opts.h@1.91 +3 -3 + NTP_4_2_5P102 + + util/ntp-keygen-opts.texi@1.90 +1 -1 + NTP_4_2_5P102 + + util/ntp-keygen.1@1.90 +2 -2 + NTP_4_2_5P102 + +ChangeSet@1.1674, 2007-11-23 20:01:46+00:00, kamboj@pogo.udel.edu + ntp_config.c: + Fixed a minor bug reported by coverity + + ntpd/ntp_config.c@1.173 +6 -3 + Fixed a minor bug reported by coverity + +ChangeSet@1.1673, 2007-11-23 14:59:15-05:00, stenn@whimsy.udel.edu + ChangeLog: + [Bug 833] ntpq "config" keyword is 2ble-quote-mark-unfriendly. + Rename the 'config' keyword to ':config'. + + ChangeLog@1.157 +2 -0 + [Bug 833] ntpq "config" keyword is 2ble-quote-mark-unfriendly. + Rename the 'config' keyword to ':config'. + + ntpq/ntpq-subs.c@1.29 +2 -2 + + ntpq/ntpq.c@1.73 +27 -11 + +ChangeSet@1.1672, 2007-11-23 06:49:02-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P101 + TAG: NTP_4_2_5P101 + + ntpd/ntpd-opts.c@1.93 +2 -2 + NTP_4_2_5P101 + + ntpd/ntpd-opts.h@1.93 +3 -3 + NTP_4_2_5P101 + + ntpd/ntpd-opts.texi@1.92 +3 -3 + NTP_4_2_5P101 + + ntpd/ntpd.1@1.92 +2 -2 + NTP_4_2_5P101 + + ntpdc/ntpdc-opts.c@1.89 +2 -2 + NTP_4_2_5P101 + + ntpdc/ntpdc-opts.h@1.89 +3 -3 + NTP_4_2_5P101 + + ntpdc/ntpdc-opts.texi@1.88 +2 -2 + NTP_4_2_5P101 + + ntpdc/ntpdc.1@1.88 +2 -2 + NTP_4_2_5P101 + + ntpq/ntpq-opts.c@1.89 +2 -2 + NTP_4_2_5P101 + + ntpq/ntpq-opts.h@1.89 +3 -3 + NTP_4_2_5P101 + + ntpq/ntpq-opts.texi@1.88 +2 -2 + NTP_4_2_5P101 + + ntpq/ntpq.1@1.88 +2 -2 + NTP_4_2_5P101 + + packageinfo.sh@1.104 +1 -1 + NTP_4_2_5P101 + + sntp/sntp-opts.c@1.89 +2 -2 + NTP_4_2_5P101 + + sntp/sntp-opts.h@1.89 +3 -3 + NTP_4_2_5P101 + + sntp/sntp-opts.texi@1.88 +1 -1 + NTP_4_2_5P101 + + sntp/sntp.1@1.88 +2 -2 + NTP_4_2_5P101 + + util/ntp-keygen-opts.c@1.90 +2 -2 + NTP_4_2_5P101 + + util/ntp-keygen-opts.h@1.90 +3 -3 + NTP_4_2_5P101 + + util/ntp-keygen-opts.texi@1.89 +2 -2 + NTP_4_2_5P101 + + util/ntp-keygen.1@1.89 +2 -2 + NTP_4_2_5P101 + +ChangeSet@1.1671, 2007-11-23 04:34:06-05:00, stenn@whimsy.udel.edu + Dave Mills shifted some orphan processing + + ChangeLog@1.156 +1 -0 + Dave Mills shifted some orphan processing + + include/ntpd.h@1.113 +3 -0 + Dave Mills shifted some orphan processing + + ntpd/ntp_proto.c@1.267 +2 -17 + Dave Mills shifted some orphan processing + + ntpd/ntp_timer.c@1.44 +18 -0 + Dave Mills shifted some orphan processing + +ChangeSet@1.1670, 2007-11-22 21:30:50-05:00, stenn@whimsy.udel.edu + Fix typos in the [Bug 963] patch + + ChangeLog@1.155 +1 -0 + Fix typos in the [Bug 963] patch + + libntp/systime.c@1.46 +1 -1 + Fix typos in the [Bug 963] patch + + ntpd/ntp_io.c@1.268 +1 -1 + Fix typos in the [Bug 963] patch + +ChangeSet@1.1669, 2007-11-22 16:37:57-05:00, stenn@whimsy.udel.edu + bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown + + ChangeLog@1.154 +1 -0 + bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown + + bootstrap@1.21 +2 -2 + bootstrap: squawk if genver fails. Use -f with cp in case Dave does a chown + +ChangeSet@1.1668, 2007-11-22 06:46:46-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P100 + TAG: NTP_4_2_5P100 + + ntpd/ntpd-opts.c@1.92 +2 -2 + NTP_4_2_5P100 + + ntpd/ntpd-opts.h@1.92 +3 -3 + NTP_4_2_5P100 + + ntpd/ntpd-opts.texi@1.91 +1 -1 + NTP_4_2_5P100 + + ntpd/ntpd.1@1.91 +2 -2 + NTP_4_2_5P100 + + ntpdc/ntpdc-opts.c@1.88 +2 -2 + NTP_4_2_5P100 + + ntpdc/ntpdc-opts.h@1.88 +3 -3 + NTP_4_2_5P100 + + ntpdc/ntpdc-opts.texi@1.87 +1 -1 + NTP_4_2_5P100 + + ntpdc/ntpdc.1@1.87 +2 -2 + NTP_4_2_5P100 + + ntpq/ntpq-opts.c@1.88 +2 -2 + NTP_4_2_5P100 + + ntpq/ntpq-opts.h@1.88 +3 -3 + NTP_4_2_5P100 + + ntpq/ntpq-opts.texi@1.87 +1 -1 + NTP_4_2_5P100 + + ntpq/ntpq.1@1.87 +2 -2 + NTP_4_2_5P100 + + packageinfo.sh@1.103 +1 -1 + NTP_4_2_5P100 + + sntp/sntp-opts.c@1.88 +2 -2 + NTP_4_2_5P100 + + sntp/sntp-opts.h@1.88 +3 -3 + NTP_4_2_5P100 + + sntp/sntp-opts.texi@1.87 +1 -1 + NTP_4_2_5P100 + + sntp/sntp.1@1.87 +2 -2 + NTP_4_2_5P100 + + util/ntp-keygen-opts.c@1.89 +2 -2 + NTP_4_2_5P100 + + util/ntp-keygen-opts.h@1.89 +3 -3 + NTP_4_2_5P100 + + util/ntp-keygen-opts.texi@1.88 +1 -1 + NTP_4_2_5P100 + + util/ntp-keygen.1@1.88 +2 -2 + NTP_4_2_5P100 + +ChangeSet@1.1667, 2007-11-22 04:19:55-05:00, stenn@whimsy.udel.edu + Remove obsolete simulator command-line options + + ChangeLog@1.153 +1 -0 + Remove obsolete simulator command-line options + + ntpd/ntpd-opts.c@1.91 +50 -329 + Remove obsolete simulator command-line options + + ntpd/ntpd-opts.h@1.91 +31 -112 + Remove obsolete simulator command-line options + + ntpd/ntpd-opts.texi@1.90 +1 -136 + Remove obsolete simulator command-line options + + ntpd/ntpd.1@1.90 +2 -47 + Remove obsolete simulator command-line options + + ntpd/ntpdbase-opts.def@1.15 +0 -90 + Remove obsolete simulator command-line options + +ChangeSet@1.1666, 2007-11-22 03:59:23-05:00, stenn@whimsy.udel.edu + [CID 36] zero sin_zero + + ChangeLog@1.152 +1 -0 + [CID 36] zero sin_zero + + ntpd/ntp_request.c@1.71 +1 -0 + [CID 36] zero sin_zero + +ChangeSet@1.1665, 2007-11-22 02:34:27-05:00, stenn@whimsy.udel.edu + [Bug 963] get_systime() is too noisy + + ChangeLog@1.151 +1 -0 + [Bug 963] get_systime() is too noisy + + libntp/systime.c@1.45 +26 -12 + [Bug 963] get_systime() is too noisy + + ntpd/ntp_io.c@1.267 +2 -1 + [Bug 963] get_systime() is too noisy + +ChangeSet@1.1662.1.3, 2007-11-21 06:49:11-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P99 + TAG: NTP_4_2_5P99 + + ntpd/ntpd-opts.c@1.90 +2 -2 + NTP_4_2_5P99 + + ntpd/ntpd-opts.h@1.90 +3 -3 + NTP_4_2_5P99 + + ntpd/ntpd-opts.texi@1.89 +2 -2 + NTP_4_2_5P99 + + ntpd/ntpd.1@1.89 +2 -2 + NTP_4_2_5P99 + + ntpdc/ntpdc-opts.c@1.87 +2 -2 + NTP_4_2_5P99 + + ntpdc/ntpdc-opts.h@1.87 +3 -3 + NTP_4_2_5P99 + + ntpdc/ntpdc-opts.texi@1.86 +2 -2 + NTP_4_2_5P99 + + ntpdc/ntpdc.1@1.86 +2 -2 + NTP_4_2_5P99 + + ntpq/ntpq-opts.c@1.87 +2 -2 + NTP_4_2_5P99 + + ntpq/ntpq-opts.h@1.87 +3 -3 + NTP_4_2_5P99 + + ntpq/ntpq-opts.texi@1.86 +2 -2 + NTP_4_2_5P99 + + ntpq/ntpq.1@1.86 +2 -2 + NTP_4_2_5P99 + + packageinfo.sh@1.102 +1 -1 + NTP_4_2_5P99 + + sntp/sntp-opts.c@1.87 +2 -2 + NTP_4_2_5P99 + + sntp/sntp-opts.h@1.87 +3 -3 + NTP_4_2_5P99 + + sntp/sntp-opts.texi@1.86 +1 -1 + NTP_4_2_5P99 + + sntp/sntp.1@1.86 +2 -2 + NTP_4_2_5P99 + + util/ntp-keygen-opts.c@1.88 +2 -2 + NTP_4_2_5P99 + + util/ntp-keygen-opts.h@1.88 +3 -3 + NTP_4_2_5P99 + + util/ntp-keygen-opts.texi@1.87 +2 -2 + NTP_4_2_5P99 + + util/ntp-keygen.1@1.87 +2 -2 + NTP_4_2_5P99 + +ChangeSet@1.1662.1.2, 2007-11-21 01:26:56-05:00, stenn@deacon.udel.edu + [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux + + ChangeLog@1.148.1.2 +1 -0 + [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux + + configure.ac@1.411 +16 -16 + [Bug 964] Change *-*-linux* to *-*-*linux* to allow for uclinux + +ChangeSet@1.1662.1.1, 2007-11-21 01:12:13-05:00, stenn@deacon.udel.edu + ntp_timer.c: + ntp_timer.c: watch the non-burst packet rate + ntp_monitor.c: + ntp_monitor.c: RES_LIMITED cleanup from Dave Mills + ntp_config.c: + config: average and minimum are ^2 values + ntp_peer.c: + ntp_peer.c: disallow peer_unconfig() + ntpdc_ops.c: + Dave Mills: unknownversion is really "declined", not "bad version" + ntp_restrict.c: + ntp_restrict.c: RES_LIMITED cleanup from Dave Mills + ChangeLog: + Changes from Dave Mills + ntp_crypto.c: + ntp_crypto.c: volley -> retry. Cleanup TAI leap message. + ntp_request.c: + Cleanup from Dave Mills + ntp_loopfilter.c: + ntp_loopfilter.c: poll interval cleanup from Dave Mills + ntp_proto.c: + ntp_proto.c: RES_LIMITED, rate bucktes, counters, overall cleanup from Dave Mills + ntpd.h, ntp.h: + general and packet retry cleanup from Dave Mills + ntp_util.c: + cleanup + + ChangeLog@1.148.1.1 +13 -0 + Changes from Dave Mills + + include/ntp.h@1.141 +15 -14 + general and packet retry cleanup from Dave Mills + + include/ntpd.h@1.112 +9 -9 + general and packet retry cleanup from Dave Mills + + ntpd/ntp_config.c@1.170.1.1 +2 -2 + config: average and minimum are ^2 values + + ntpd/ntp_crypto.c@1.120 +9 -6 + ntp_crypto.c: volley -> retry. Cleanup TAI leap message. + + ntpd/ntp_loopfilter.c@1.140 +18 -7 + ntp_loopfilter.c: poll interval cleanup from Dave Mills + + ntpd/ntp_monitor.c@1.20 +66 -31 + ntp_monitor.c: RES_LIMITED cleanup from Dave Mills + + ntpd/ntp_peer.c@1.109 +20 -48 + ntp_peer.c: disallow peer_unconfig() + + ntpd/ntp_proto.c@1.266 +317 -251 + ntp_proto.c: RES_LIMITED, rate bucktes, counters, overall cleanup from Dave Mills + + ntpd/ntp_request.c@1.70 +9 -7 + Cleanup from Dave Mills + + ntpd/ntp_restrict.c@1.26 +33 -60 + ntp_restrict.c: RES_LIMITED cleanup from Dave Mills + + ntpd/ntp_timer.c@1.43 +13 -2 + ntp_timer.c: watch the non-burst packet rate + + ntpd/ntp_util.c@1.61 +5 -5 + cleanup + + ntpdc/ntpdc_ops.c@1.53 +1 -1 + Dave Mills: unknownversion is really "declined", not "bad version" + +ChangeSet@1.1663, 2007-11-20 21:36:27-05:00, neal@pogo.udel.edu + ChangeLog: + [Bug 960] spurious crypto command + ntp_config.c: + [Bug 960] spurious crypto command + + ChangeLog@1.149 +1 -0 + [Bug 960] spurious crypto command message + + ntpd/ntp_config.c@1.171 +3 -1 + [Bug 960] spurious crypto command + +ChangeSet@1.1662, 2007-11-14 06:45:25-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P98 + TAG: NTP_4_2_5P98 + + ntpd/ntpd-opts.c@1.89 +2 -2 + NTP_4_2_5P98 + + ntpd/ntpd-opts.h@1.89 +3 -3 + NTP_4_2_5P98 + + ntpd/ntpd-opts.texi@1.88 +2 -2 + NTP_4_2_5P98 + + ntpd/ntpd.1@1.88 +2 -2 + NTP_4_2_5P98 + + ntpdc/ntpdc-opts.c@1.86 +2 -2 + NTP_4_2_5P98 + + ntpdc/ntpdc-opts.h@1.86 +3 -3 + NTP_4_2_5P98 + + ntpdc/ntpdc-opts.texi@1.85 +2 -2 + NTP_4_2_5P98 + + ntpdc/ntpdc.1@1.85 +2 -2 + NTP_4_2_5P98 + + ntpq/ntpq-opts.c@1.86 +2 -2 + NTP_4_2_5P98 + + ntpq/ntpq-opts.h@1.86 +3 -3 + NTP_4_2_5P98 + + ntpq/ntpq-opts.texi@1.85 +2 -2 + NTP_4_2_5P98 + + ntpq/ntpq.1@1.85 +2 -2 + NTP_4_2_5P98 + + packageinfo.sh@1.101 +1 -1 + NTP_4_2_5P98 + + sntp/sntp-opts.c@1.86 +2 -2 + NTP_4_2_5P98 + + sntp/sntp-opts.h@1.86 +3 -3 + NTP_4_2_5P98 + + sntp/sntp-opts.texi@1.85 +1 -1 + NTP_4_2_5P98 + + sntp/sntp.1@1.85 +2 -2 + NTP_4_2_5P98 + + util/ntp-keygen-opts.c@1.87 +2 -2 + NTP_4_2_5P98 + + util/ntp-keygen-opts.h@1.87 +3 -3 + NTP_4_2_5P98 + + util/ntp-keygen-opts.texi@1.86 +2 -2 + NTP_4_2_5P98 + + util/ntp-keygen.1@1.86 +2 -2 + NTP_4_2_5P98 + +ChangeSet@1.1661, 2007-11-13 16:57:44-05:00, stenn@whimsy.udel.edu + [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice + + ChangeLog@1.148 +1 -0 + [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice + + ntpd/refclock_tpro.c@1.10 +0 -1 + [Bug 961] refclock_tpro.c:tpro_poll() calls refclock_receive() twice + +ChangeSet@1.1660, 2007-11-12 06:46:23-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P97 + TAG: NTP_4_2_5P97 + + ntpd/ntpd-opts.c@1.88 +2 -2 + NTP_4_2_5P97 + + ntpd/ntpd-opts.h@1.88 +3 -3 + NTP_4_2_5P97 + + ntpd/ntpd-opts.texi@1.87 +2 -2 + NTP_4_2_5P97 + + ntpd/ntpd.1@1.87 +2 -2 + NTP_4_2_5P97 + + ntpdc/ntpdc-opts.c@1.85 +2 -2 + NTP_4_2_5P97 + + ntpdc/ntpdc-opts.h@1.85 +3 -3 + NTP_4_2_5P97 + + ntpdc/ntpdc-opts.texi@1.84 +2 -2 + NTP_4_2_5P97 + + ntpdc/ntpdc.1@1.84 +2 -2 + NTP_4_2_5P97 + + ntpq/ntpq-opts.c@1.85 +2 -2 + NTP_4_2_5P97 + + ntpq/ntpq-opts.h@1.85 +3 -3 + NTP_4_2_5P97 + + ntpq/ntpq-opts.texi@1.84 +2 -2 + NTP_4_2_5P97 + + ntpq/ntpq.1@1.84 +2 -2 + NTP_4_2_5P97 + + packageinfo.sh@1.100 +1 -1 + NTP_4_2_5P97 + + sntp/sntp-opts.c@1.85 +2 -2 + NTP_4_2_5P97 + + sntp/sntp-opts.h@1.85 +3 -3 + NTP_4_2_5P97 + + sntp/sntp-opts.texi@1.84 +1 -1 + NTP_4_2_5P97 + + sntp/sntp.1@1.84 +2 -2 + NTP_4_2_5P97 + + util/ntp-keygen-opts.c@1.86 +2 -2 + NTP_4_2_5P97 + + util/ntp-keygen-opts.h@1.86 +3 -3 + NTP_4_2_5P97 + + util/ntp-keygen-opts.texi@1.85 +2 -2 + NTP_4_2_5P97 + + util/ntp-keygen.1@1.85 +2 -2 + NTP_4_2_5P97 + +ChangeSet@1.1657.1.2, 2007-11-09 06:48:04-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P96 + TAG: NTP_4_2_5P96 + + ntpd/ntpd-opts.c@1.87 +2 -2 + NTP_4_2_5P96 + + ntpd/ntpd-opts.h@1.87 +3 -3 + NTP_4_2_5P96 + + ntpd/ntpd-opts.texi@1.86 +5 -5 + NTP_4_2_5P96 + + ntpd/ntpd.1@1.86 +2 -2 + NTP_4_2_5P96 + + ntpdc/ntpdc-opts.c@1.84 +2 -2 + NTP_4_2_5P96 + + ntpdc/ntpdc-opts.h@1.84 +3 -3 + NTP_4_2_5P96 + + ntpdc/ntpdc-opts.texi@1.83 +3 -3 + NTP_4_2_5P96 + + ntpdc/ntpdc.1@1.83 +2 -2 + NTP_4_2_5P96 + + ntpq/ntpq-opts.c@1.84 +2 -2 + NTP_4_2_5P96 + + ntpq/ntpq-opts.h@1.84 +3 -3 + NTP_4_2_5P96 + + ntpq/ntpq-opts.texi@1.83 +3 -3 + NTP_4_2_5P96 + + ntpq/ntpq.1@1.83 +2 -2 + NTP_4_2_5P96 + + packageinfo.sh@1.99 +1 -1 + NTP_4_2_5P96 + + sntp/sntp-opts.c@1.84 +2 -2 + NTP_4_2_5P96 + + sntp/sntp-opts.h@1.84 +3 -3 + NTP_4_2_5P96 + + sntp/sntp-opts.texi@1.83 +1 -1 + NTP_4_2_5P96 + + sntp/sntp.1@1.83 +2 -2 + NTP_4_2_5P96 + + util/ntp-keygen-opts.c@1.85 +2 -2 + NTP_4_2_5P96 + + util/ntp-keygen-opts.h@1.85 +3 -3 + NTP_4_2_5P96 + + util/ntp-keygen-opts.texi@1.84 +3 -3 + NTP_4_2_5P96 + + util/ntp-keygen.1@1.84 +2 -2 + NTP_4_2_5P96 + +ChangeSet@1.1657.1.1, 2007-11-09 02:10:13-05:00, stenn@whimsy.udel.edu + Work around a VPATH difference in FreeBSD's 'make' command + + ChangeLog@1.145.1.1 +1 -0 + Work around a VPATH difference in FreeBSD's 'make' command + + configure.ac@1.410 +1 -0 + Work around a VPATH difference in FreeBSD's 'make' command + + m4/ntp_vpathhack.m4@1.1 +23 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/m4/ntp_vpathhack.m4 + + m4/ntp_vpathhack.m4@1.0 +0 -0 + + ntpd/Makefile.am@1.64 +11 -1 + Work around a VPATH difference in FreeBSD's 'make' command + +ChangeSet@1.1658, 2007-11-08 12:08:38-05:00, burnicki@pogo.udel.edu + [Bug 713] Windows only: Let command line parameters from the Windows SCM GUI + override the standard parameters from the ImagePath registry key. + * Added HAVE_INT32_T to the Windows config.h to avoid duplicate definitions. + + ChangeLog@1.146 +3 -0 + Updated for bug #957. + + ports/winnt/include/config.h@1.53 +1 -0 + Added HAVE_INT32_T to the Windows config.h to avoid duplicate definitions. + + ports/winnt/ntpd/ntservice.c@1.11 +11 -2 + [Bug 957] Let command line parameters from the Windows SCM GUI + override the standard parameters from the ImagePath registry key. + +ChangeSet@1.1657, 2007-11-06 06:46:44-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P95 + TAG: NTP_4_2_5P95 + + ntpd/ntpd-opts.c@1.86 +2 -2 + NTP_4_2_5P95 + + ntpd/ntpd-opts.h@1.86 +3 -3 + NTP_4_2_5P95 + + ntpd/ntpd-opts.texi@1.85 +1 -1 + NTP_4_2_5P95 + + ntpd/ntpd.1@1.85 +2 -2 + NTP_4_2_5P95 + + ntpdc/ntpdc-opts.c@1.83 +2 -2 + NTP_4_2_5P95 + + ntpdc/ntpdc-opts.h@1.83 +3 -3 + NTP_4_2_5P95 + + ntpdc/ntpdc-opts.texi@1.82 +2 -2 + NTP_4_2_5P95 + + ntpdc/ntpdc.1@1.82 +2 -2 + NTP_4_2_5P95 + + ntpq/ntpq-opts.c@1.83 +2 -2 + NTP_4_2_5P95 + + ntpq/ntpq-opts.h@1.83 +3 -3 + NTP_4_2_5P95 + + ntpq/ntpq-opts.texi@1.82 +2 -2 + NTP_4_2_5P95 + + ntpq/ntpq.1@1.82 +2 -2 + NTP_4_2_5P95 + + packageinfo.sh@1.98 +1 -1 + NTP_4_2_5P95 + + sntp/sntp-opts.c@1.83 +2 -2 + NTP_4_2_5P95 + + sntp/sntp-opts.h@1.83 +3 -3 + NTP_4_2_5P95 + + sntp/sntp-opts.texi@1.82 +1 -1 + NTP_4_2_5P95 + + sntp/sntp.1@1.82 +2 -2 + NTP_4_2_5P95 + + util/ntp-keygen-opts.c@1.84 +2 -2 + NTP_4_2_5P95 + + util/ntp-keygen-opts.h@1.84 +3 -3 + NTP_4_2_5P95 + + util/ntp-keygen-opts.texi@1.83 +2 -2 + NTP_4_2_5P95 + + util/ntp-keygen.1@1.83 +2 -2 + NTP_4_2_5P95 + +ChangeSet@1.1656, 2007-11-06 01:50:44-05:00, stenn@whimsy.udel.edu + Update bugreport URL + + ChangeLog@1.145 +1 -0 + Update bugreport URL + + README@1.23 +1 -1 + Update bugreport URL + + README.bk@1.19 +1 -1 + Update bugreport URL + + README.patches@1.4 +1 -1 + Update bugreport URL + + WHERE-TO-START@1.7 +1 -1 + Update bugreport URL + + include/copyright.def@1.7 +1 -1 + Update bugreport URL + + ntpd/ntpd-opts.c@1.85 +2 -2 + Update bugreport URL + + ntpd/ntpd-opts.h@1.85 +1 -1 + Update bugreport URL + + ntpd/ntpd-opts.texi@1.84 +1 -1 + Update bugreport URL + + ntpd/ntpd.1@1.84 +2 -2 + Update bugreport URL + + ntpdc/ntpdc-opts.c@1.82 +2 -2 + Update bugreport URL + + ntpdc/ntpdc-opts.h@1.82 +1 -1 + Update bugreport URL + + ntpdc/ntpdc-opts.texi@1.81 +2 -2 + Update bugreport URL + + ntpdc/ntpdc.1@1.81 +3 -3 + Update bugreport URL + + ntpq/ntpq-opts.c@1.82 +2 -2 + Update bugreport URL + + ntpq/ntpq-opts.h@1.82 +1 -1 + Update bugreport URL + + ntpq/ntpq-opts.texi@1.81 +2 -2 + Update bugreport URL + + ntpq/ntpq.1@1.81 +3 -3 + Update bugreport URL + + sntp/sntp-opts.c@1.82 +2 -2 + Update bugreport URL + + sntp/sntp-opts.def@1.11 +1 -1 + Update bugreport URL + + sntp/sntp-opts.h@1.82 +1 -1 + Update bugreport URL + + sntp/sntp-opts.texi@1.81 +1 -1 + Update bugreport URL + + sntp/sntp.1@1.81 +3 -3 + Update bugreport URL + + util/ntp-keygen-opts.c@1.83 +2 -2 + Update bugreport URL + + util/ntp-keygen-opts.h@1.83 +1 -1 + Update bugreport URL + + util/ntp-keygen-opts.texi@1.82 +2 -2 + Update bugreport URL + + util/ntp-keygen.1@1.82 +3 -3 + Update bugreport URL + +ChangeSet@1.1655, 2007-11-06 00:45:47-05:00, stenn@whimsy.udel.edu + Update -I documentation + + ChangeLog@1.144 +1 -0 + Update -I documentation + + ntpd/ntpd-opts.c@1.84 +330 -51 + Update -I documentation + + ntpd/ntpd-opts.h@1.84 +112 -31 + Update -I documentation + + ntpd/ntpd-opts.texi@1.83 +137 -2 + Update -I documentation + + ntpd/ntpd.1@1.83 +48 -3 + Update -I documentation + + ntpd/ntpdbase-opts.def@1.14 +10 -19 + Update -I documentation + +ChangeSet@1.1654, 2007-11-05 21:27:36-05:00, stenn@whimsy.udel.edu + [Bug 713] Fix bug reporting information + + ChangeLog@1.143 +1 -0 + [Bug 713] Fix bug reporting information + + html/index.html@1.35 +2 -2 + [Bug 713] Fix bug reporting information + + html/msyslog.html@1.6 +3 -3 + [Bug 713] Fix bug reporting information + + html/release.html@1.33 +3 -3 + [Bug 713] Fix bug reporting information + +ChangeSet@1.1649.1.2, 2007-11-05 06:45:45-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P94 + TAG: NTP_4_2_5P94 + + ntpd/ntpd-opts.c@1.83 +2 -2 + NTP_4_2_5P94 + + ntpd/ntpd-opts.h@1.83 +3 -3 + NTP_4_2_5P94 + + ntpd/ntpd-opts.texi@1.82 +2 -2 + NTP_4_2_5P94 + + ntpd/ntpd.1@1.82 +2 -2 + NTP_4_2_5P94 + + ntpdc/ntpdc-opts.c@1.81 +2 -2 + NTP_4_2_5P94 + + ntpdc/ntpdc-opts.h@1.81 +3 -3 + NTP_4_2_5P94 + + ntpdc/ntpdc-opts.texi@1.80 +2 -2 + NTP_4_2_5P94 + + ntpdc/ntpdc.1@1.80 +2 -2 + NTP_4_2_5P94 + + ntpq/ntpq-opts.c@1.81 +2 -2 + NTP_4_2_5P94 + + ntpq/ntpq-opts.h@1.81 +3 -3 + NTP_4_2_5P94 + + ntpq/ntpq-opts.texi@1.80 +2 -2 + NTP_4_2_5P94 + + ntpq/ntpq.1@1.80 +2 -2 + NTP_4_2_5P94 + + packageinfo.sh@1.97 +1 -1 + NTP_4_2_5P94 + + sntp/sntp-opts.c@1.81 +2 -2 + NTP_4_2_5P94 + + sntp/sntp-opts.h@1.81 +3 -3 + NTP_4_2_5P94 + + sntp/sntp-opts.texi@1.80 +1 -1 + NTP_4_2_5P94 + + sntp/sntp.1@1.80 +2 -2 + NTP_4_2_5P94 + + util/ntp-keygen-opts.c@1.82 +2 -2 + NTP_4_2_5P94 + + util/ntp-keygen-opts.h@1.82 +3 -3 + NTP_4_2_5P94 + + util/ntp-keygen-opts.texi@1.81 +2 -2 + NTP_4_2_5P94 + + util/ntp-keygen.1@1.81 +2 -2 + NTP_4_2_5P94 + +ChangeSet@1.1649.1.1, 2007-11-05 03:12:05-05:00, stenn@whimsy.udel.edu + ntp_config.c: + reindent + ntp-keygen.c: + Coverity fixes [CID 33,47] + ntp_util.c, ntp_crypto.c, ntp_timer.c: + [Bug 861] Leap second cleanups from Dave Mills + systime.c: + Fuzz cleanup from Dave Mills. + ntp.h: + Volley cleanup from Dave Mills. + ntp_io.c: + Fuzz cleanup from Dave Mills + ntp_proto.c: + [Bug 861] Leap second cleanups from Dave Mills. + Volley cleanup from Dave Mills. + ntpd.h: + Leap second file cleanups from Dave Mills + + ChangeLog@1.140.1.1 +4 -0 + + include/ntp.h@1.140 +0 -1 + Volley cleanup from Dave Mills. + + include/ntpd.h@1.111 +0 -1 + Leap second file cleanups from Dave Mills + + libntp/systime.c@1.44 +2 -4 + Fuzz cleanup from Dave Mills. + + ntpd/ntp_config.c@1.170 +6 -6 + reindent + + ntpd/ntp_crypto.c@1.119 +7 -4 + [Bug 861] Leap second cleanups from Dave Mills + + ntpd/ntp_io.c@1.266 +2 -8 + Fuzz cleanup from Dave Mills + + ntpd/ntp_proto.c@1.265 +64 -115 + [Bug 861] Leap second cleanups from Dave Mills. + Volley cleanup from Dave Mills. + + ntpd/ntp_timer.c@1.42 +17 -7 + [Bug 861] Leap second cleanups from Dave Mills + + ntpd/ntp_util.c@1.60 +3 -3 + [Bug 861] Leap second cleanups from Dave Mills + + util/ntp-keygen.c@1.47 +9 -10 + Coverity fixes [CID 33,47] + +ChangeSet@1.1436.1.87, 2007-11-01 03:52:00-04:00, clemens@pogo.udel.edu + * Negative-sawtooth not applied correctly for oncore 12 channel + receiver. Fixed. + * Startup code for original LinuxPPS removed. LinuxPPS now + conforms to the PPSAPI. + + ChangeLog@1.1.1.35 +4 -0 + * Negative-sawtooth not applied correctly for oncore 12 channel + receiver. Fixed. + * Startup code for original LinuxPPS removed. LinuxPPS now + conforms to the PPSAPI. + +ChangeSet@1.1652, 2007-11-01 03:49:06-04:00, clemens@pogo.udel.edu + * A bug in the application of the negative-sawtoot for 12 channel receivers. + * The removal of unneeded startup code used for the original LinuxPPS, it now + conforms to the PPSAPI and does not need special code. + + ChangeLog@1.141 +3 -0 + * A bug in the application of the negative-sawtoot for 12 channel receivers. + * The removal of unneeded startup code used for the original LinuxPPS, it now + conforms to the PPSAPI and does not need special code. + +ChangeSet@1.1436.1.86, 2007-11-01 03:29:24-04:00, clemens@pogo.udel.edu + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + + ntpd/refclock_oncore.c@1.60.1.2 +1 -56 + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + +ChangeSet@1.1651, 2007-11-01 03:24:16-04:00, clemens@pogo.udel.edu + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + + ntpd/refclock_oncore.c@1.63 +1 -56 + The original version of LinuxPPS did not comply with the PPSAPI and required + some changes to the startup code in refclock_oncore.c . The current version + complies, and these changes can be removed. + +ChangeSet@1.1436.1.85, 2007-11-01 02:16:36-04:00, clemens@pogo.udel.edu + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + + ntpd/refclock_oncore.c@1.60.1.1 +2 -2 + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + +ChangeSet@1.1650, 2007-11-01 02:13:19-04:00, clemens@pogo.udel.edu + ntpd/refclock_oncore.c + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + + ntpd/refclock_oncore.c@1.62 +2 -2 + The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal + which is on the zero crossing of its internal clock, from its true value. the + refclock_oncore.c driver applies this difference to correct the time of the + provided timestamp. This value was being applied correctly for the 6 and 8 channel + receivers, but not for the 12 channel. This has been corrected. + +ChangeSet@1.1649, 2007-10-31 06:46:05-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P93 + TAG: NTP_4_2_5P93 + + ntpd/ntpd-opts.c@1.82 +2 -2 + NTP_4_2_5P93 + + ntpd/ntpd-opts.h@1.82 +3 -3 + NTP_4_2_5P93 + + ntpd/ntpd-opts.texi@1.81 +1 -1 + NTP_4_2_5P93 + + ntpd/ntpd.1@1.81 +2 -2 + NTP_4_2_5P93 + + ntpdc/ntpdc-opts.c@1.80 +2 -2 + NTP_4_2_5P93 + + ntpdc/ntpdc-opts.h@1.80 +3 -3 + NTP_4_2_5P93 + + ntpdc/ntpdc-opts.texi@1.79 +1 -1 + NTP_4_2_5P93 + + ntpdc/ntpdc.1@1.79 +2 -2 + NTP_4_2_5P93 + + ntpq/ntpq-opts.c@1.80 +2 -2 + NTP_4_2_5P93 + + ntpq/ntpq-opts.h@1.80 +3 -3 + NTP_4_2_5P93 + + ntpq/ntpq-opts.texi@1.79 +1 -1 + NTP_4_2_5P93 + + ntpq/ntpq.1@1.79 +2 -2 + NTP_4_2_5P93 + + packageinfo.sh@1.96 +1 -1 + NTP_4_2_5P93 + + sntp/sntp-opts.c@1.80 +2 -2 + NTP_4_2_5P93 + + sntp/sntp-opts.h@1.80 +3 -3 + NTP_4_2_5P93 + + sntp/sntp-opts.texi@1.79 +1 -1 + NTP_4_2_5P93 + + sntp/sntp.1@1.79 +2 -2 + NTP_4_2_5P93 + + util/ntp-keygen-opts.c@1.81 +2 -2 + NTP_4_2_5P93 + + util/ntp-keygen-opts.h@1.81 +3 -3 + NTP_4_2_5P93 + + util/ntp-keygen-opts.texi@1.80 +1 -1 + NTP_4_2_5P93 + + util/ntp-keygen.1@1.80 +2 -2 + NTP_4_2_5P93 + +ChangeSet@1.1648, 2007-10-31 01:26:20-05:00, stenn@whimsy.udel.edu + Document the reasoning behind the c_d directory variable + + flock-build@1.41 +2 -0 + Document the reasoning behind the c_d directory variable + +ChangeSet@1.1647, 2007-10-30 06:46:30-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P92 + TAG: NTP_4_2_5P92 + + ntpd/ntpd-opts.c@1.81 +2 -2 + NTP_4_2_5P92 + + ntpd/ntpd-opts.h@1.81 +3 -3 + NTP_4_2_5P92 + + ntpd/ntpd-opts.texi@1.80 +3 -3 + NTP_4_2_5P92 + + ntpd/ntpd.1@1.80 +2 -2 + NTP_4_2_5P92 + + ntpdc/ntpdc-opts.c@1.79 +2 -2 + NTP_4_2_5P92 + + ntpdc/ntpdc-opts.h@1.79 +3 -3 + NTP_4_2_5P92 + + ntpdc/ntpdc-opts.texi@1.78 +3 -3 + NTP_4_2_5P92 + + ntpdc/ntpdc.1@1.78 +2 -2 + NTP_4_2_5P92 + + ntpq/ntpq-opts.c@1.79 +2 -2 + NTP_4_2_5P92 + + ntpq/ntpq-opts.h@1.79 +3 -3 + NTP_4_2_5P92 + + ntpq/ntpq-opts.texi@1.78 +3 -3 + NTP_4_2_5P92 + + ntpq/ntpq.1@1.78 +2 -2 + NTP_4_2_5P92 + + packageinfo.sh@1.95 +1 -1 + NTP_4_2_5P92 + + sntp/sntp-opts.c@1.79 +2 -2 + NTP_4_2_5P92 + + sntp/sntp-opts.h@1.79 +3 -3 + NTP_4_2_5P92 + + sntp/sntp-opts.texi@1.78 +1 -1 + NTP_4_2_5P92 + + sntp/sntp.1@1.78 +2 -2 + NTP_4_2_5P92 + + util/ntp-keygen-opts.c@1.80 +2 -2 + NTP_4_2_5P92 + + util/ntp-keygen-opts.h@1.80 +3 -3 + NTP_4_2_5P92 + + util/ntp-keygen-opts.texi@1.79 +3 -3 + NTP_4_2_5P92 + + util/ntp-keygen.1@1.79 +2 -2 + NTP_4_2_5P92 + +ChangeSet@1.1646, 2007-10-30 02:27:06-05:00, stenn@whimsy.udel.edu + ntpsim.c: add missing protypes and fix [CID 34], a nit + + ChangeLog@1.140 +1 -0 + ntpsim.c: add missing protypes and fix [CID 34], a nit + + ntpd/ntpsim.c@1.19 +7 -0 + ntpsim.c: add missing protypes and fix [CID 34], a nit + +ChangeSet@1.1645, 2007-10-30 01:31:05-05:00, stenn@whimsy.udel.edu + ntp_scanner.c: + reindent + + ntpd/ntp_scanner.c@1.12 +377 -360 + reindent + +ChangeSet@1.1644, 2007-10-30 01:09:30-05:00, stenn@whimsy.udel.edu + ntp_parser.h, ntp_parser.c, ChangeLog: + Upgraded bison at UDel + br-flock, ChangeLog, flock-build: + Update br-flock and flock-build machine lists + + ChangeLog@1.139 +1 -0 + Upgraded bison at UDel + + ChangeLog@1.138 +1 -0 + Update br-flock and flock-build machine lists + + br-flock@1.12 +1 -1 + Update br-flock and flock-build machine lists + + flock-build@1.40 +6 -5 + Update br-flock and flock-build machine lists + + ntpd/ntp_parser.c@1.24 +1072 -684 + Upgraded bison at UDel + + ntpd/ntp_parser.h@1.10 +29 -20 + Upgraded bison at UDel + +ChangeSet@1.1643, 2007-10-29 17:17:35-04:00, neal@pogo.udel.edu + ntp_scanner.c: + [Bug 828] use is_ip_address from ntp_io.c in scanner + + ntpd/ntp_scanner.c@1.11 +5 -43 + [Bug 828] use is_ip_address from ntp_io.c in scanner + +ChangeSet@1.1642, 2007-10-29 10:28:31-04:00, neal@pogo.udel.edu + ntp_scanner.c: + [Bug 828] correct IPv6 address parsing + + ntpd/ntp_scanner.c@1.10 +2 -42 + [Bug 828] correct IPv6 address parsing + +ChangeSet@1.1641, 2007-10-28 20:40:12-04:00, neal@pogo.udel.edu + copyright.html: + add self to copyright notice + + html/copyright.html@1.37 +1 -0 + add self to copyright notice + +ChangeSet@1.1638.1.1, 2007-10-27 12:27:18-04:00, neal@pogo.udel.edu + ntp_io.c: + [Bug 752] QoS: add parser/config support. + Many files: + [Bug 752] QoS: add parser/config support. + + ChangeLog@1.137 +1 -0 + [Bug 752] QoS: add parser/config support. + + include/ntp_config.h@1.46 +24 -0 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_config.c@1.169 +67 -1 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_io.c@1.265 +5 -5 + [Bug 752] QoS: add parser/config support. + , + + ntpd/ntp_parser.c@1.23 +2031 -1577 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_parser.h@1.9 +341 -152 + [Bug 752] QoS: add parser/config support. + + ntpd/ntp_parser.y@1.19 +3 -0 + [Bug 752] QoS: add parser/config support. + +ChangeSet@1.1639, 2007-10-27 07:44:18-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P91 + TAG: NTP_4_2_5P91 + + ntpd/ntpd-opts.c@1.80 +2 -2 + NTP_4_2_5P91 + + ntpd/ntpd-opts.h@1.80 +3 -3 + NTP_4_2_5P91 + + ntpd/ntpd-opts.texi@1.79 +1 -1 + NTP_4_2_5P91 + + ntpd/ntpd.1@1.79 +2 -2 + NTP_4_2_5P91 + + ntpdc/ntpdc-opts.c@1.78 +2 -2 + NTP_4_2_5P91 + + ntpdc/ntpdc-opts.h@1.78 +3 -3 + NTP_4_2_5P91 + + ntpdc/ntpdc-opts.texi@1.77 +1 -1 + NTP_4_2_5P91 + + ntpdc/ntpdc.1@1.77 +2 -2 + NTP_4_2_5P91 + + ntpq/ntpq-opts.c@1.78 +2 -2 + NTP_4_2_5P91 + + ntpq/ntpq-opts.h@1.78 +3 -3 + NTP_4_2_5P91 + + ntpq/ntpq-opts.texi@1.77 +1 -1 + NTP_4_2_5P91 + + ntpq/ntpq.1@1.77 +2 -2 + NTP_4_2_5P91 + + packageinfo.sh@1.94 +1 -1 + NTP_4_2_5P91 + + sntp/sntp-opts.c@1.78 +2 -2 + NTP_4_2_5P91 + + sntp/sntp-opts.h@1.78 +3 -3 + NTP_4_2_5P91 + + sntp/sntp-opts.texi@1.77 +1 -1 + NTP_4_2_5P91 + + sntp/sntp.1@1.77 +2 -2 + NTP_4_2_5P91 + + util/ntp-keygen-opts.c@1.79 +2 -2 + NTP_4_2_5P91 + + util/ntp-keygen-opts.h@1.79 +3 -3 + NTP_4_2_5P91 + + util/ntp-keygen-opts.texi@1.78 +1 -1 + NTP_4_2_5P91 + + util/ntp-keygen.1@1.78 +2 -2 + NTP_4_2_5P91 + +ChangeSet@1.1638, 2007-10-26 17:40:27-04:00, stenn@whimsy.udel.edu + Fix the #include order in tickadj.c for picky machines + + ChangeLog@1.136 +1 -0 + Fix the #include order in tickadj.c for picky machines + + util/tickadj.c@1.8 +1 -1 + Fix the #include order in tickadj.c for picky machines + +ChangeSet@1.1637, 2007-10-26 07:43:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P90 + TAG: NTP_4_2_5P90 + + ntpd/ntpd-opts.c@1.79 +2 -2 + NTP_4_2_5P90 + + ntpd/ntpd-opts.h@1.79 +3 -3 + NTP_4_2_5P90 + + ntpd/ntpd-opts.texi@1.78 +1 -1 + NTP_4_2_5P90 + + ntpd/ntpd.1@1.78 +2 -2 + NTP_4_2_5P90 + + ntpdc/ntpdc-opts.c@1.77 +2 -2 + NTP_4_2_5P90 + + ntpdc/ntpdc-opts.h@1.77 +3 -3 + NTP_4_2_5P90 + + ntpdc/ntpdc-opts.texi@1.76 +1 -1 + NTP_4_2_5P90 + + ntpdc/ntpdc.1@1.76 +2 -2 + NTP_4_2_5P90 + + ntpq/ntpq-opts.c@1.77 +2 -2 + NTP_4_2_5P90 + + ntpq/ntpq-opts.h@1.77 +3 -3 + NTP_4_2_5P90 + + ntpq/ntpq-opts.texi@1.76 +1 -1 + NTP_4_2_5P90 + + ntpq/ntpq.1@1.76 +2 -2 + NTP_4_2_5P90 + + packageinfo.sh@1.93 +1 -1 + NTP_4_2_5P90 + + sntp/sntp-opts.c@1.77 +2 -2 + NTP_4_2_5P90 + + sntp/sntp-opts.h@1.77 +3 -3 + NTP_4_2_5P90 + + sntp/sntp-opts.texi@1.76 +1 -1 + NTP_4_2_5P90 + + sntp/sntp.1@1.76 +2 -2 + NTP_4_2_5P90 + + util/ntp-keygen-opts.c@1.78 +2 -2 + NTP_4_2_5P90 + + util/ntp-keygen-opts.h@1.78 +3 -3 + NTP_4_2_5P90 + + util/ntp-keygen-opts.texi@1.77 +1 -1 + NTP_4_2_5P90 + + util/ntp-keygen.1@1.77 +2 -2 + NTP_4_2_5P90 + +ChangeSet@1.1636, 2007-10-26 00:30:22-04:00, stenn@whimsy.udel.edu + [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h + + ChangeLog@1.135 +1 -0 + [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h + + include/ntp_io.h@1.9 +3 -0 + [Bug 752] QoS: On some systems, netinet/ip.h needs netinet/ip_systm.h + +ChangeSet@1.1635, 2007-10-25 07:48:29-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P89 + TAG: NTP_4_2_5P89 + + ntpd/ntpd-opts.c@1.78 +2 -2 + NTP_4_2_5P89 + + ntpd/ntpd-opts.h@1.78 +3 -3 + NTP_4_2_5P89 + + ntpd/ntpd-opts.texi@1.77 +1 -1 + NTP_4_2_5P89 + + ntpd/ntpd.1@1.77 +2 -2 + NTP_4_2_5P89 + + ntpdc/ntpdc-opts.c@1.76 +2 -2 + NTP_4_2_5P89 + + ntpdc/ntpdc-opts.h@1.76 +3 -3 + NTP_4_2_5P89 + + ntpdc/ntpdc-opts.texi@1.75 +1 -1 + NTP_4_2_5P89 + + ntpdc/ntpdc.1@1.75 +2 -2 + NTP_4_2_5P89 + + ntpq/ntpq-opts.c@1.76 +2 -2 + NTP_4_2_5P89 + + ntpq/ntpq-opts.h@1.76 +3 -3 + NTP_4_2_5P89 + + ntpq/ntpq-opts.texi@1.75 +1 -1 + NTP_4_2_5P89 + + ntpq/ntpq.1@1.75 +2 -2 + NTP_4_2_5P89 + + packageinfo.sh@1.92 +1 -1 + NTP_4_2_5P89 + + sntp/sntp-opts.c@1.76 +2 -2 + NTP_4_2_5P89 + + sntp/sntp-opts.h@1.76 +3 -3 + NTP_4_2_5P89 + + sntp/sntp-opts.texi@1.75 +1 -1 + NTP_4_2_5P89 + + sntp/sntp.1@1.75 +2 -2 + NTP_4_2_5P89 + + util/ntp-keygen-opts.c@1.77 +2 -2 + NTP_4_2_5P89 + + util/ntp-keygen-opts.h@1.77 +3 -3 + NTP_4_2_5P89 + + util/ntp-keygen-opts.texi@1.76 +1 -1 + NTP_4_2_5P89 + + util/ntp-keygen.1@1.76 +2 -2 + NTP_4_2_5P89 + +ChangeSet@1.1634, 2007-10-25 01:14:55-04:00, stenn@whimsy.udel.edu + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + ChangeLog@1.134 +1 -0 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + configure.ac@1.409 +18 -0 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + include/ntp_io.h@1.8 +6 -0 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + + ntpd/ntp_io.c@1.264 +18 -14 + [Bug 752] Update the QoS tagging (code only - configuration to follow) + +ChangeSet@1.1633, 2007-10-24 22:43:04-04:00, stenn@whimsy.udel.edu + ntp_proto.c: + Orphan mode and other protocol cleanup from Dave Mills + manyopt.html, assoc.html: + Documentation cleanup from Dave Mills + ChangeLog: + Documentation cleanup from Dave Mills + Orphan mode and other protocol cleanup from Dave Mills + + ChangeLog@1.133 +2 -0 + Documentation cleanup from Dave Mills + Orphan mode and other protocol cleanup from Dave Mills + + html/assoc.html@1.24 +37 -38 + Documentation cleanup from Dave Mills + + html/manyopt.html@1.15 +23 -7 + Documentation cleanup from Dave Mills + + ntpd/ntp_proto.c@1.264 +43 -68 + Orphan mode and other protocol cleanup from Dave Mills + +ChangeSet@1.1632, 2007-10-23 07:44:01-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P88 + TAG: NTP_4_2_5P88 + + ntpd/ntpd-opts.c@1.77 +2 -2 + NTP_4_2_5P88 + + ntpd/ntpd-opts.h@1.77 +4 -4 + NTP_4_2_5P88 + + ntpd/ntpd-opts.texi@1.76 +1 -1 + NTP_4_2_5P88 + + ntpd/ntpd.1@1.76 +3 -3 + NTP_4_2_5P88 + + ntpdc/ntpdc-opts.c@1.75 +2 -2 + NTP_4_2_5P88 + + ntpdc/ntpdc-opts.h@1.75 +4 -4 + NTP_4_2_5P88 + + ntpdc/ntpdc-opts.texi@1.74 +1 -1 + NTP_4_2_5P88 + + ntpdc/ntpdc.1@1.74 +3 -3 + NTP_4_2_5P88 + + ntpq/ntpq-opts.c@1.75 +2 -2 + NTP_4_2_5P88 + + ntpq/ntpq-opts.h@1.75 +4 -4 + NTP_4_2_5P88 + + ntpq/ntpq-opts.texi@1.74 +1 -1 + NTP_4_2_5P88 + + ntpq/ntpq.1@1.74 +3 -3 + NTP_4_2_5P88 + + packageinfo.sh@1.91 +1 -1 + NTP_4_2_5P88 + + sntp/sntp-opts.c@1.75 +2 -2 + NTP_4_2_5P88 + + sntp/sntp-opts.h@1.75 +3 -3 + NTP_4_2_5P88 + + sntp/sntp-opts.texi@1.74 +1 -1 + NTP_4_2_5P88 + + sntp/sntp.1@1.74 +2 -2 + NTP_4_2_5P88 + + util/ntp-keygen-opts.c@1.76 +2 -2 + NTP_4_2_5P88 + + util/ntp-keygen-opts.h@1.76 +4 -4 + NTP_4_2_5P88 + + util/ntp-keygen-opts.texi@1.75 +1 -1 + NTP_4_2_5P88 + + util/ntp-keygen.1@1.75 +3 -3 + NTP_4_2_5P88 + +ChangeSet@1.1631, 2007-10-22 21:39:01-04:00, stenn@whimsy.udel.edu + [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version + + ChangeLog@1.132 +1 -0 + [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version + + include/copyright.def@1.6 +2 -0 + [Bug 940] ntp-keygen uses -v. Disallow it as a shortcut for --version + +ChangeSet@1.1630, 2007-10-21 07:47:45-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P87 + TAG: NTP_4_2_5P87 + + ntpd/ntpd-opts.c@1.76 +2 -2 + NTP_4_2_5P87 + + ntpd/ntpd-opts.h@1.76 +3 -3 + NTP_4_2_5P87 + + ntpd/ntpd-opts.texi@1.75 +2 -2 + NTP_4_2_5P87 + + ntpd/ntpd.1@1.75 +2 -2 + NTP_4_2_5P87 + + ntpdc/ntpdc-opts.c@1.74 +2 -2 + NTP_4_2_5P87 + + ntpdc/ntpdc-opts.h@1.74 +3 -3 + NTP_4_2_5P87 + + ntpdc/ntpdc-opts.texi@1.73 +2 -2 + NTP_4_2_5P87 + + ntpdc/ntpdc.1@1.73 +2 -2 + NTP_4_2_5P87 + + ntpq/ntpq-opts.c@1.74 +2 -2 + NTP_4_2_5P87 + + ntpq/ntpq-opts.h@1.74 +3 -3 + NTP_4_2_5P87 + + ntpq/ntpq-opts.texi@1.73 +2 -2 + NTP_4_2_5P87 + + ntpq/ntpq.1@1.73 +2 -2 + NTP_4_2_5P87 + + packageinfo.sh@1.90 +1 -1 + NTP_4_2_5P87 + + sntp/sntp-opts.c@1.74 +2 -2 + NTP_4_2_5P87 + + sntp/sntp-opts.h@1.74 +3 -3 + NTP_4_2_5P87 + + sntp/sntp-opts.texi@1.73 +1 -1 + NTP_4_2_5P87 + + sntp/sntp.1@1.73 +2 -2 + NTP_4_2_5P87 + + util/ntp-keygen-opts.c@1.75 +2 -2 + NTP_4_2_5P87 + + util/ntp-keygen-opts.h@1.75 +3 -3 + NTP_4_2_5P87 + + util/ntp-keygen-opts.texi@1.74 +2 -2 + NTP_4_2_5P87 + + util/ntp-keygen.1@1.74 +2 -2 + NTP_4_2_5P87 + +ChangeSet@1.1629, 2007-10-20 18:30:10-04:00, stenn@whimsy.udel.edu + more cleanup to ntp_lineeditlibs.m4 + + ChangeLog@1.131 +1 -0 + more cleanup to ntp_lineeditlibs.m4 + + m4/ntp_lineeditlibs.m4@1.3 +46 -39 + more cleanup to ntp_lineeditlibs.m4 + +ChangeSet@1.1628, 2007-10-20 07:44:48-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P86 + TAG: NTP_4_2_5P86 + + ntpd/ntpd-opts.c@1.75 +2 -2 + NTP_4_2_5P86 + + ntpd/ntpd-opts.h@1.75 +3 -3 + NTP_4_2_5P86 + + ntpd/ntpd-opts.texi@1.74 +1 -1 + NTP_4_2_5P86 + + ntpd/ntpd.1@1.74 +2 -2 + NTP_4_2_5P86 + + ntpdc/ntpdc-opts.c@1.73 +2 -2 + NTP_4_2_5P86 + + ntpdc/ntpdc-opts.h@1.73 +3 -3 + NTP_4_2_5P86 + + ntpdc/ntpdc-opts.texi@1.72 +1 -1 + NTP_4_2_5P86 + + ntpdc/ntpdc.1@1.72 +2 -2 + NTP_4_2_5P86 + + ntpq/ntpq-opts.c@1.73 +2 -2 + NTP_4_2_5P86 + + ntpq/ntpq-opts.h@1.73 +3 -3 + NTP_4_2_5P86 + + ntpq/ntpq-opts.texi@1.72 +1 -1 + NTP_4_2_5P86 + + ntpq/ntpq.1@1.72 +2 -2 + NTP_4_2_5P86 + + packageinfo.sh@1.89 +1 -1 + NTP_4_2_5P86 + + sntp/sntp-opts.c@1.73 +2 -2 + NTP_4_2_5P86 + + sntp/sntp-opts.h@1.73 +3 -3 + NTP_4_2_5P86 + + sntp/sntp-opts.texi@1.72 +1 -1 + NTP_4_2_5P86 + + sntp/sntp.1@1.72 +2 -2 + NTP_4_2_5P86 + + util/ntp-keygen-opts.c@1.74 +2 -2 + NTP_4_2_5P86 + + util/ntp-keygen-opts.h@1.74 +3 -3 + NTP_4_2_5P86 + + util/ntp-keygen-opts.texi@1.73 +1 -1 + NTP_4_2_5P86 + + util/ntp-keygen.1@1.73 +2 -2 + NTP_4_2_5P86 + +ChangeSet@1.1627, 2007-10-20 01:32:29-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.130 +1 -0 + Documentation updates from Dave Mills + + html/assoc.html@1.23 +39 -30 + Documentation updates from Dave Mills + + html/confopt.html@1.38 +35 -35 + Documentation updates from Dave Mills + + html/manyopt.html@1.14 +6 -38 + Documentation updates from Dave Mills + + html/miscopt.html@1.37 +22 -1 + Documentation updates from Dave Mills + + html/scripts/links7.txt@1.4 +1 -0 + Documentation updates from Dave Mills + +ChangeSet@1.1626, 2007-10-19 07:44:27-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P85 + TAG: NTP_4_2_5P85 + + ntpd/ntpd-opts.c@1.74 +2 -2 + NTP_4_2_5P85 + + ntpd/ntpd-opts.h@1.74 +3 -3 + NTP_4_2_5P85 + + ntpd/ntpd-opts.texi@1.73 +1 -1 + NTP_4_2_5P85 + + ntpd/ntpd.1@1.73 +2 -2 + NTP_4_2_5P85 + + ntpdc/ntpdc-opts.c@1.72 +2 -2 + NTP_4_2_5P85 + + ntpdc/ntpdc-opts.h@1.72 +3 -3 + NTP_4_2_5P85 + + ntpdc/ntpdc-opts.texi@1.71 +1 -1 + NTP_4_2_5P85 + + ntpdc/ntpdc.1@1.71 +2 -2 + NTP_4_2_5P85 + + ntpq/ntpq-opts.c@1.72 +2 -2 + NTP_4_2_5P85 + + ntpq/ntpq-opts.h@1.72 +3 -3 + NTP_4_2_5P85 + + ntpq/ntpq-opts.texi@1.71 +1 -1 + NTP_4_2_5P85 + + ntpq/ntpq.1@1.71 +2 -2 + NTP_4_2_5P85 + + packageinfo.sh@1.88 +1 -1 + NTP_4_2_5P85 + + sntp/sntp-opts.c@1.72 +2 -2 + NTP_4_2_5P85 + + sntp/sntp-opts.h@1.72 +3 -3 + NTP_4_2_5P85 + + sntp/sntp-opts.texi@1.71 +1 -1 + NTP_4_2_5P85 + + sntp/sntp.1@1.71 +2 -2 + NTP_4_2_5P85 + + util/ntp-keygen-opts.c@1.73 +2 -2 + NTP_4_2_5P85 + + util/ntp-keygen-opts.h@1.73 +3 -3 + NTP_4_2_5P85 + + util/ntp-keygen-opts.texi@1.72 +1 -1 + NTP_4_2_5P85 + + util/ntp-keygen.1@1.72 +2 -2 + NTP_4_2_5P85 + +ChangeSet@1.1625, 2007-10-19 06:57:12+00:00, stenn@ntp1.isc.org + -ledit cleanup for ntpdc and ntpq. + + ChangeLog@1.129 +1 -0 + -ledit cleanup for ntpdc and ntpq. + + ntpdc/ntpdc.c@1.58 +3 -3 + -ledit cleanup for ntpdc and ntpq. + + ntpq/ntpq.c@1.72 +3 -3 + -ledit cleanup for ntpdc and ntpq. + +ChangeSet@1.1624, 2007-10-18 07:49:09-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P84 + TAG: NTP_4_2_5P84 + + ntpd/ntpd-opts.c@1.73 +2 -2 + NTP_4_2_5P84 + + ntpd/ntpd-opts.h@1.73 +3 -3 + NTP_4_2_5P84 + + ntpd/ntpd-opts.texi@1.72 +1 -1 + NTP_4_2_5P84 + + ntpd/ntpd.1@1.72 +2 -2 + NTP_4_2_5P84 + + ntpdc/ntpdc-opts.c@1.71 +2 -2 + NTP_4_2_5P84 + + ntpdc/ntpdc-opts.h@1.71 +3 -3 + NTP_4_2_5P84 + + ntpdc/ntpdc-opts.texi@1.70 +1 -1 + NTP_4_2_5P84 + + ntpdc/ntpdc.1@1.70 +2 -2 + NTP_4_2_5P84 + + ntpq/ntpq-opts.c@1.71 +2 -2 + NTP_4_2_5P84 + + ntpq/ntpq-opts.h@1.71 +3 -3 + NTP_4_2_5P84 + + ntpq/ntpq-opts.texi@1.70 +1 -1 + NTP_4_2_5P84 + + ntpq/ntpq.1@1.70 +2 -2 + NTP_4_2_5P84 + + packageinfo.sh@1.87 +1 -1 + NTP_4_2_5P84 + + sntp/sntp-opts.c@1.71 +2 -2 + NTP_4_2_5P84 + + sntp/sntp-opts.h@1.71 +3 -3 + NTP_4_2_5P84 + + sntp/sntp-opts.texi@1.70 +1 -1 + NTP_4_2_5P84 + + sntp/sntp.1@1.70 +2 -2 + NTP_4_2_5P84 + + util/ntp-keygen-opts.c@1.72 +2 -2 + NTP_4_2_5P84 + + util/ntp-keygen-opts.h@1.72 +3 -3 + NTP_4_2_5P84 + + util/ntp-keygen-opts.texi@1.71 +1 -1 + NTP_4_2_5P84 + + util/ntp-keygen.1@1.71 +2 -2 + NTP_4_2_5P84 + +ChangeSet@1.1623, 2007-10-18 01:57:55-04:00, stenn@whimsy.udel.edu + README.hackers: + cleanup + + README.hackers@1.11 +0 -13 + cleanup + +ChangeSet@1.1622, 2007-10-18 01:52:51-04:00, stenn@whimsy.udel.edu + refclock_acts.c, ntp_peer.c, ChangeLog, ntp_proto.c, ntp_config.c: + Association and other cleanup from Dave Mills + ntp.h: + NTP_UNREACH changes from Dave Mills. + + ChangeLog@1.128 +2 -0 + Association and other cleanup from Dave Mills + + include/ntp.h@1.139 +2 -2 + NTP_UNREACH changes from Dave Mills. + + ntpd/ntp_config.c@1.168 +20 -24 + Association and other cleanup from Dave Mills + + ntpd/ntp_peer.c@1.108 +45 -65 + Association and other cleanup from Dave Mills + + ntpd/ntp_proto.c@1.263 +11 -34 + Association and other cleanup from Dave Mills + + ntpd/refclock_acts.c@1.32 +2 -0 + Association and other cleanup from Dave Mills + +ChangeSet@1.1621, 2007-10-17 20:21:31-04:00, stenn@whimsy.udel.edu + Fix the readline history test + + ChangeLog@1.127 +1 -0 + Fix the readline history test + + m4/ntp_lineeditlibs.m4@1.2 +4 -1 + Fix the readline history test + +ChangeSet@1.1620, 2007-10-15 07:49:05-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P83 + TAG: NTP_4_2_5P83 + + ntpd/ntpd-opts.c@1.72 +2 -2 + NTP_4_2_5P83 + + ntpd/ntpd-opts.h@1.72 +3 -3 + NTP_4_2_5P83 + + ntpd/ntpd-opts.texi@1.71 +1 -1 + NTP_4_2_5P83 + + ntpd/ntpd.1@1.71 +2 -2 + NTP_4_2_5P83 + + ntpdc/ntpdc-opts.c@1.70 +2 -2 + NTP_4_2_5P83 + + ntpdc/ntpdc-opts.h@1.70 +3 -3 + NTP_4_2_5P83 + + ntpdc/ntpdc-opts.texi@1.69 +1 -1 + NTP_4_2_5P83 + + ntpdc/ntpdc.1@1.69 +2 -2 + NTP_4_2_5P83 + + ntpq/ntpq-opts.c@1.70 +2 -2 + NTP_4_2_5P83 + + ntpq/ntpq-opts.h@1.70 +3 -3 + NTP_4_2_5P83 + + ntpq/ntpq-opts.texi@1.69 +1 -1 + NTP_4_2_5P83 + + ntpq/ntpq.1@1.69 +2 -2 + NTP_4_2_5P83 + + packageinfo.sh@1.86 +1 -1 + NTP_4_2_5P83 + + sntp/sntp-opts.c@1.70 +2 -2 + NTP_4_2_5P83 + + sntp/sntp-opts.h@1.70 +3 -3 + NTP_4_2_5P83 + + sntp/sntp-opts.texi@1.69 +1 -1 + NTP_4_2_5P83 + + sntp/sntp.1@1.69 +2 -2 + NTP_4_2_5P83 + + util/ntp-keygen-opts.c@1.71 +2 -2 + NTP_4_2_5P83 + + util/ntp-keygen-opts.h@1.71 +3 -3 + NTP_4_2_5P83 + + util/ntp-keygen-opts.texi@1.70 +1 -1 + NTP_4_2_5P83 + + util/ntp-keygen.1@1.70 +2 -2 + NTP_4_2_5P83 + +ChangeSet@1.1619, 2007-10-15 04:52:10-04:00, stenn@whimsy.udel.edu + ChangeLog: + [Bug 931] Require -lreadline to be asked for explicitly. + [Bug 764] When looking for -lreadline support, also try using -lncurses. + Use new line edit library autoconf macro. + configure.ac: + Use the NTP_LINEEDITLIBS macro now. + Makefile.am, ntpdc.c, ntpq.c: + Use new line editing library detection code + ntp_lineeditlibs.m4: + BitKeeper file /deacon/backroom/ntp-dev-hms/m4/ntp_lineeditlibs.m4 + + ChangeLog@1.126 +2 -0 + [Bug 931] Require -lreadline to be asked for explicitly. + [Bug 764] When looking for -lreadline support, also try using -lncurses. + Use new line edit library autoconf macro. + + configure.ac@1.408 +2 -26 + Use the NTP_LINEEDITLIBS macro now. + + m4/ntp_lineeditlibs.m4@1.1 +86 -0 + BitKeeper file /deacon/backroom/ntp-dev-hms/m4/ntp_lineeditlibs.m4 + + m4/ntp_lineeditlibs.m4@1.0 +0 -0 + + ntpdc/Makefile.am@1.37 +1 -1 + Use new line editing library detection code + + ntpdc/ntpdc.c@1.57 +6 -2 + Use new line editing library detection code + + ntpq/Makefile.am@1.29 +1 -1 + Use new line editing library detection code + + ntpq/ntpq.c@1.71 +6 -2 + Use new line editing library detection code + +ChangeSet@1.1618, 2007-10-14 07:44:25-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P82 + TAG: NTP_4_2_5P82 + + ntpd/ntpd-opts.c@1.71 +2 -2 + NTP_4_2_5P82 + + ntpd/ntpd-opts.h@1.71 +3 -3 + NTP_4_2_5P82 + + ntpd/ntpd-opts.texi@1.70 +1 -1 + NTP_4_2_5P82 + + ntpd/ntpd.1@1.70 +2 -2 + NTP_4_2_5P82 + + ntpdc/ntpdc-opts.c@1.69 +2 -2 + NTP_4_2_5P82 + + ntpdc/ntpdc-opts.h@1.69 +3 -3 + NTP_4_2_5P82 + + ntpdc/ntpdc-opts.texi@1.68 +1 -1 + NTP_4_2_5P82 + + ntpdc/ntpdc.1@1.68 +2 -2 + NTP_4_2_5P82 + + ntpq/ntpq-opts.c@1.69 +2 -2 + NTP_4_2_5P82 + + ntpq/ntpq-opts.h@1.69 +3 -3 + NTP_4_2_5P82 + + ntpq/ntpq-opts.texi@1.68 +1 -1 + NTP_4_2_5P82 + + ntpq/ntpq.1@1.68 +2 -2 + NTP_4_2_5P82 + + packageinfo.sh@1.85 +1 -1 + NTP_4_2_5P82 + + sntp/sntp-opts.c@1.69 +2 -2 + NTP_4_2_5P82 + + sntp/sntp-opts.h@1.69 +3 -3 + NTP_4_2_5P82 + + sntp/sntp-opts.texi@1.68 +1 -1 + NTP_4_2_5P82 + + sntp/sntp.1@1.68 +2 -2 + NTP_4_2_5P82 + + util/ntp-keygen-opts.c@1.70 +2 -2 + NTP_4_2_5P82 + + util/ntp-keygen-opts.h@1.70 +3 -3 + NTP_4_2_5P82 + + util/ntp-keygen-opts.texi@1.69 +1 -1 + NTP_4_2_5P82 + + util/ntp-keygen.1@1.69 +2 -2 + NTP_4_2_5P82 + +ChangeSet@1.1617, 2007-10-14 03:35:11-04:00, stenn@pogo.udel.edu + Reformat entries + + ChangeLog@1.125 +5 -5 + Reformat entries + +ChangeSet@1.1616, 2007-10-13 21:47:27-04:00, mayer@pogo.udel.edu + Bug #909 Fix int32_t errors for ntohl() + + ntpdc/ntpdc_ops.c@1.52 +107 -107 + Bug #909 Fix int32_t errors for ntohl() + + ports/winnt/include/config.h@1.52 +1 -0 + Bug #909 Fix int32_t errors for ntohl() + +ChangeSet@1.1615, 2007-10-08 15:47:23-04:00, mayer@pogo.udel.edu + Bug #909 Fix int32_t errors for ntohl() + + ChangeLog@1.124 +1 -0 + Bug #909 Fix int32_t errors for ntohl() + +ChangeSet@1.1614, 2007-10-08 15:45:47-04:00, mayer@pogo.udel.edu + Bug #909 Fix int32_t errors for ntohl() + + ntpdc/ntpdc_ops.c@1.51 +107 -107 + Bug #909 Fix int32_t errors for ntohl() + +ChangeSet@1.1613, 2007-10-07 20:47:32-04:00, mayer@pogo.udel.edu + Bug #376/214 enhancements + + ChangeLog@1.123 +1 -0 + +ChangeSet@1.1612, 2007-10-07 12:27:06-04:00, mayer@pogo.udel.edu + Bug #376/214 Enhancements to support multiple if names and IP addresses + + include/ntp_io.h@1.7 +6 -0 + Bug #376/214 Enhancements to support multiple if names and IP addresses + + ntpd/ntp_io.c@1.263 +151 -2 + Bug #376/214 Enhancements to support multiple if names and IP addresses + + ntpd/ntpd.c@1.90 +7 -6 + Bug #376/214 Enhancements to support multiple if names and IP addresses + +ChangeSet@1.1611, 2007-10-05 09:54:42-04:00, mayer@pogo.udel.edu + Bug #788 Update macros to support VS 2005 + + ports/winnt/include/config.h@1.51 +3 -1 + Bug #788 Update macros to support VS 2005 + +ChangeSet@1.1610, 2007-10-05 09:20:49-04:00, mayer@pogo.udel.edu + New bug fixes + + ChangeLog@1.122 +3 -0 + New bug fixes + +ChangeSet@1.1609, 2007-10-05 09:17:12-04:00, mayer@pogo.udel.edu + Bug #929 int32_t is undefined on Windows. Casting wrong + + ntpdc/ntpdc_ops.c@1.50 +4 -4 + Bug #929 int32_t is undefined on Windows. Casting wrong + +ChangeSet@1.1608, 2007-10-05 08:57:08-04:00, mayer@pogo.udel.edu + Bug #928 readlink missing braces + + util/ntp-keygen.c@1.46 +2 -2 + Bug #928 readlink missing braces + +ChangeSet@1.1607, 2007-10-05 08:46:39-04:00, mayer@pogo.udel.edu + Bug #788 Update macros to support VS 2005 + + ports/winnt/instsrv/Instsrv.dsp@1.7 +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/libntp/libntp.dsp@1.31 +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.12 +4 -4 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpd/ntpd.dsp@1.31 +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpdate/ntpdate.dsp@1.16 +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpdc/ntpdc.dsp@1.19 +2 -2 + Bug #788 Update macros to support VS 2005 + + ports/winnt/ntpq/ntpq.dsp@1.20 +2 -2 + Bug #788 Update macros to support VS 2005 + +ChangeSet@1.1606, 2007-10-04 07:45:47-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P81 + TAG: NTP_4_2_5P81 + + ntpd/ntpd-opts.c@1.70 +2 -2 + NTP_4_2_5P81 + + ntpd/ntpd-opts.h@1.70 +3 -3 + NTP_4_2_5P81 + + ntpd/ntpd-opts.texi@1.69 +3 -5 + NTP_4_2_5P81 + + ntpd/ntpd.1@1.69 +2 -2 + NTP_4_2_5P81 + + ntpdc/ntpdc-opts.c@1.68 +2 -2 + NTP_4_2_5P81 + + ntpdc/ntpdc-opts.h@1.68 +3 -3 + NTP_4_2_5P81 + + ntpdc/ntpdc-opts.texi@1.67 +2 -2 + NTP_4_2_5P81 + + ntpdc/ntpdc.1@1.67 +2 -2 + NTP_4_2_5P81 + + ntpq/ntpq-opts.c@1.68 +2 -2 + NTP_4_2_5P81 + + ntpq/ntpq-opts.h@1.68 +3 -3 + NTP_4_2_5P81 + + ntpq/ntpq-opts.texi@1.67 +2 -2 + NTP_4_2_5P81 + + ntpq/ntpq.1@1.67 +2 -2 + NTP_4_2_5P81 + + packageinfo.sh@1.84 +1 -1 + NTP_4_2_5P81 + + sntp/sntp-opts.c@1.68 +2 -2 + NTP_4_2_5P81 + + sntp/sntp-opts.h@1.68 +3 -3 + NTP_4_2_5P81 + + sntp/sntp-opts.texi@1.67 +1 -1 + NTP_4_2_5P81 + + sntp/sntp.1@1.67 +2 -2 + NTP_4_2_5P81 + + util/ntp-keygen-opts.c@1.69 +2 -2 + NTP_4_2_5P81 + + util/ntp-keygen-opts.h@1.69 +3 -3 + NTP_4_2_5P81 + + util/ntp-keygen-opts.texi@1.68 +2 -2 + NTP_4_2_5P81 + + util/ntp-keygen.1@1.68 +2 -2 + NTP_4_2_5P81 + +ChangeSet@1.1605, 2007-10-04 03:02:00-04:00, stenn@whimsy.udel.edu + documentation update from Dave Mills + + html/authopt.html@1.45 +2 -2 + documentation update from Dave Mills + +ChangeSet@1.1599.1.1, 2007-10-03 21:38:31-04:00, stenn@whimsy.udel.edu + Many files: + Lose obsolete crypto subcommands + sco.html, authopt.html: + documentation cleanup + ChangeLog, ntp_control.c: + WWV is an HF source, not an LF source + + ChangeLog@1.116.1.2 +1 -0 + Lose obsolete crypto subcommands + + ChangeLog@1.116.1.1 +1 -0 + WWV is an HF source, not an LF source + + html/authopt.html@1.44 +2 -3 + documentation cleanup + + html/build/hints/sco.html@1.8 +1 -0 + documentation cleanup + + ntpd/ntp_config.c@1.167 +0 -5 + Lose obsolete crypto subcommands + + ntpd/ntp_control.c@1.102 +1 -1 + WWV is an HF source, not an LF source + + ntpd/ntp_crypto.c@1.118 +0 -25 + Lose obsolete crypto subcommands + + ntpd/ntp_parser.c@1.22 +826 -848 + Lose obsolete crypto subcommands + + ntpd/ntp_parser.h@1.8 +132 -136 + Lose obsolete crypto subcommands + + ntpd/ntp_parser.y@1.18 +9 -14 + Lose obsolete crypto subcommands + +ChangeSet@1.1603, 2007-09-30 16:40:51+00:00, kardel@pogo.udel.edu + ChangeLog: + ntpd/ntp_timer.c: add missing sys_tai parameter for debug printf + ntp_timer.c: + add missing sys_tai parameter for debug printf + + ChangeLog@1.120 +1 -0 + ntpd/ntp_timer.c: add missing sys_tai parameter for debug printf + + ntpd/ntp_timer.c@1.41 +1 -1 + add missing sys_tai parameter for debug printf + +ChangeSet@1.1602, 2007-09-30 16:09:50+00:00, kardel@pogo.udel.edu + ChangeLog: + [Bug 917] config parse leaves files open + ntp_scanner.c: + Bug 917: config parse leaves files open + + ChangeLog@1.119 +1 -0 + [Bug 917] config parse leaves files open + + ntpd/ntp_scanner.c@1.9 +3 -2 + Bug 917: config parse leaves files open + +ChangeSet@1.1601, 2007-09-30 16:05:00+00:00, kardel@pogo.udel.edu + ntp_io.c: + Bug 912: detect conflicting enable/disable configuration on interfaces sharing an IP address + ChangeLog: + [Bug 912] detect conflicting enable/disable configuration on interfaces sharing an IP address + + ChangeLog@1.118 +1 -0 + [Bug 912] detect conflicting enable/disable configuration on interfaces sharing an IP address + + ntpd/ntp_io.c@1.262 +39 -2 + Bug 912: detect conflicting enable/disable configuration on interfaces sharing an IP address + +ChangeSet@1.1600, 2007-09-30 15:57:52+00:00, kardel@pogo.udel.edu + ChangeLog: + [Bug 771] compare scopeid if available for IPv6 addresses + ntp.h: + Bug 771: compare scopeid if available for IPv6 addresses + + ChangeLog@1.117 +1 -0 + [Bug 771] compare scopeid if available for IPv6 addresses + + include/ntp.h@1.138 +7 -1 + Bug 771: compare scopeid if available for IPv6 addresses + +ChangeSet@1.1599, 2007-09-23 07:45:18-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P80 + TAG: NTP_4_2_5P80 + + ntpd/ntpd-opts.c@1.69 +2 -2 + NTP_4_2_5P80 + + ntpd/ntpd-opts.h@1.69 +3 -3 + NTP_4_2_5P80 + + ntpd/ntpd-opts.texi@1.68 +1 -1 + NTP_4_2_5P80 + + ntpd/ntpd.1@1.68 +2 -2 + NTP_4_2_5P80 + + ntpdc/ntpdc-opts.c@1.67 +2 -2 + NTP_4_2_5P80 + + ntpdc/ntpdc-opts.h@1.67 +3 -3 + NTP_4_2_5P80 + + ntpdc/ntpdc-opts.texi@1.66 +1 -1 + NTP_4_2_5P80 + + ntpdc/ntpdc.1@1.66 +2 -2 + NTP_4_2_5P80 + + ntpq/ntpq-opts.c@1.67 +2 -2 + NTP_4_2_5P80 + + ntpq/ntpq-opts.h@1.67 +3 -3 + NTP_4_2_5P80 + + ntpq/ntpq-opts.texi@1.66 +1 -1 + NTP_4_2_5P80 + + ntpq/ntpq.1@1.66 +2 -2 + NTP_4_2_5P80 + + packageinfo.sh@1.83 +1 -1 + NTP_4_2_5P80 + + sntp/sntp-opts.c@1.67 +2 -2 + NTP_4_2_5P80 + + sntp/sntp-opts.h@1.67 +3 -3 + NTP_4_2_5P80 + + sntp/sntp-opts.texi@1.66 +1 -1 + NTP_4_2_5P80 + + sntp/sntp.1@1.66 +2 -2 + NTP_4_2_5P80 + + util/ntp-keygen-opts.c@1.68 +2 -2 + NTP_4_2_5P80 + + util/ntp-keygen-opts.h@1.68 +3 -3 + NTP_4_2_5P80 + + util/ntp-keygen-opts.texi@1.67 +1 -1 + NTP_4_2_5P80 + + util/ntp-keygen.1@1.67 +2 -2 + NTP_4_2_5P80 + +ChangeSet@1.1598, 2007-09-23 03:16:18-04:00, stenn@whimsy.udel.edu + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ChangeLog@1.116 +1 -1 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd-opts.c@1.68 +40 -31 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd-opts.h@1.68 +16 -14 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd-opts.texi@1.67 +19 -12 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpd.1@1.67 +10 -10 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + + ntpd/ntpdbase-opts.def@1.13 +26 -25 + [Bug 899] Only show -i/--jaildir -u/--user options if we HAVE_DROPROOT + +ChangeSet@1.1597, 2007-09-23 02:06:55-04:00, stenn@whimsy.udel.edu + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ChangeLog@1.115 +1 -0 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd-opts.c@1.67 +10 -1 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd-opts.h@1.67 +3 -1 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd-opts.texi@1.66 +8 -1 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpd.1@1.66 +2 -2 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + + ntpd/ntpdbase-opts.def@1.12 +1 -0 + [Bug 899] Only show -i/--jaildir option if we HAVE_DROPROOT + +ChangeSet@1.1596, 2007-09-20 07:43:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P79 + TAG: NTP_4_2_5P79 + + ntpd/ntpd-opts.c@1.66 +2 -2 + NTP_4_2_5P79 + + ntpd/ntpd-opts.h@1.66 +3 -3 + NTP_4_2_5P79 + + ntpd/ntpd-opts.texi@1.65 +2 -2 + NTP_4_2_5P79 + + ntpd/ntpd.1@1.65 +2 -2 + NTP_4_2_5P79 + + ntpdc/ntpdc-opts.c@1.66 +2 -2 + NTP_4_2_5P79 + + ntpdc/ntpdc-opts.h@1.66 +3 -3 + NTP_4_2_5P79 + + ntpdc/ntpdc-opts.texi@1.65 +2 -2 + NTP_4_2_5P79 + + ntpdc/ntpdc.1@1.65 +2 -2 + NTP_4_2_5P79 + + ntpq/ntpq-opts.c@1.66 +2 -2 + NTP_4_2_5P79 + + ntpq/ntpq-opts.h@1.66 +3 -3 + NTP_4_2_5P79 + + ntpq/ntpq-opts.texi@1.65 +2 -2 + NTP_4_2_5P79 + + ntpq/ntpq.1@1.65 +2 -2 + NTP_4_2_5P79 + + packageinfo.sh@1.82 +1 -1 + NTP_4_2_5P79 + + sntp/sntp-opts.c@1.66 +2 -2 + NTP_4_2_5P79 + + sntp/sntp-opts.h@1.66 +3 -3 + NTP_4_2_5P79 + + sntp/sntp-opts.texi@1.65 +1 -1 + NTP_4_2_5P79 + + sntp/sntp.1@1.65 +2 -2 + NTP_4_2_5P79 + + util/ntp-keygen-opts.c@1.67 +2 -2 + NTP_4_2_5P79 + + util/ntp-keygen-opts.h@1.67 +3 -3 + NTP_4_2_5P79 + + util/ntp-keygen-opts.texi@1.66 +2 -2 + NTP_4_2_5P79 + + util/ntp-keygen.1@1.66 +2 -2 + NTP_4_2_5P79 + +ChangeSet@1.1595, 2007-09-19 14:40:52-04:00, stenn@whimsy.udel.edu + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + + ntpd/ntp_config.c@1.166 +0 -2 + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + +ChangeSet@1.1594, 2007-09-19 07:45:04-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P78 + TAG: NTP_4_2_5P78 + + ntpd/ntpd-opts.c@1.65 +2 -2 + NTP_4_2_5P78 + + ntpd/ntpd-opts.h@1.65 +3 -3 + NTP_4_2_5P78 + + ntpd/ntpd-opts.texi@1.64 +2 -2 + NTP_4_2_5P78 + + ntpd/ntpd.1@1.64 +2 -2 + NTP_4_2_5P78 + + ntpdc/ntpdc-opts.c@1.65 +2 -2 + NTP_4_2_5P78 + + ntpdc/ntpdc-opts.h@1.65 +3 -3 + NTP_4_2_5P78 + + ntpdc/ntpdc-opts.texi@1.64 +2 -2 + NTP_4_2_5P78 + + ntpdc/ntpdc.1@1.64 +2 -2 + NTP_4_2_5P78 + + ntpq/ntpq-opts.c@1.65 +2 -2 + NTP_4_2_5P78 + + ntpq/ntpq-opts.h@1.65 +3 -3 + NTP_4_2_5P78 + + ntpq/ntpq-opts.texi@1.64 +2 -2 + NTP_4_2_5P78 + + ntpq/ntpq.1@1.64 +2 -2 + NTP_4_2_5P78 + + packageinfo.sh@1.81 +1 -1 + NTP_4_2_5P78 + + sntp/sntp-opts.c@1.65 +2 -2 + NTP_4_2_5P78 + + sntp/sntp-opts.h@1.65 +3 -3 + NTP_4_2_5P78 + + sntp/sntp-opts.texi@1.64 +1 -1 + NTP_4_2_5P78 + + sntp/sntp.1@1.64 +2 -2 + NTP_4_2_5P78 + + util/ntp-keygen-opts.c@1.66 +2 -2 + NTP_4_2_5P78 + + util/ntp-keygen-opts.h@1.66 +3 -3 + NTP_4_2_5P78 + + util/ntp-keygen-opts.texi@1.65 +3 -3 + NTP_4_2_5P78 + + util/ntp-keygen.1@1.65 +2 -2 + NTP_4_2_5P78 + +ChangeSet@1.1593, 2007-09-19 06:46:54-04:00, stenn@whimsy.udel.edu + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + + ChangeLog@1.114 +1 -0 + [Bug 916] 'cryptosw' is undefined if built without OpenSSL + +ChangeSet@1.1592, 2007-09-19 04:16:11-04:00, stenn@whimsy.udel.edu + Documentation updates + + html/authopt.html@1.43 +45 -59 + Documentation updates + + html/keygen.html@1.10 +41 -44 + Documentation updates + +ChangeSet@1.1591, 2007-09-19 04:05:50-04:00, stenn@whimsy.udel.edu + [Bug 890] the crypto command seems to be required now\n[Bug 891] 'restrict' config file keyword does not work (partial fix) + + ChangeLog@1.113 +1 -0 + [Bug 890] the crypto command seems to be required now\n[Bug 891] 'restrict' config file keyword does not work (partial fix) + + ChangeLog@1.112 +3 -0 + [Bug 890] the crypto command seems to be required now + + ntpd/ntp_config.c@1.165 +9 -1 + [Bug 890] the crypto command seems to be required now\n[Bug 891] 'restrict' config file keyword does not work (partial fix) + + ntpd/ntp_crypto.c@1.117 +13 -17 + [Bug 915] ntpd cores during processing of x509 certificates\nRemove lint. + + ntpd/ntp_parser.c@1.21 +238 -236 + [Bug 890] the crypto command seems to be required now + + ntpd/ntp_parser.y@1.17 +2 -0 + [Bug 890] the crypto command seems to be required now + + ntpd/ntp_restrict.c@1.25 +6 -1 + restrict processing debug information + +ChangeSet@1.1590, 2007-09-16 07:44:22-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P77 + TAG: NTP_4_2_5P77 + + ntpd/ntpd-opts.c@1.64 +2 -2 + NTP_4_2_5P77 + + ntpd/ntpd-opts.h@1.64 +3 -3 + NTP_4_2_5P77 + + ntpd/ntpd-opts.texi@1.63 +1 -1 + NTP_4_2_5P77 + + ntpd/ntpd.1@1.63 +2 -2 + NTP_4_2_5P77 + + ntpdc/ntpdc-opts.c@1.64 +2 -2 + NTP_4_2_5P77 + + ntpdc/ntpdc-opts.h@1.64 +3 -3 + NTP_4_2_5P77 + + ntpdc/ntpdc-opts.texi@1.63 +1 -1 + NTP_4_2_5P77 + + ntpdc/ntpdc.1@1.63 +2 -2 + NTP_4_2_5P77 + + ntpq/ntpq-opts.c@1.64 +2 -2 + NTP_4_2_5P77 + + ntpq/ntpq-opts.h@1.64 +3 -3 + NTP_4_2_5P77 + + ntpq/ntpq-opts.texi@1.63 +1 -1 + NTP_4_2_5P77 + + ntpq/ntpq.1@1.63 +2 -2 + NTP_4_2_5P77 + + packageinfo.sh@1.80 +1 -1 + NTP_4_2_5P77 + + sntp/sntp-opts.c@1.64 +2 -2 + NTP_4_2_5P77 + + sntp/sntp-opts.h@1.64 +3 -3 + NTP_4_2_5P77 + + sntp/sntp-opts.texi@1.63 +1 -1 + NTP_4_2_5P77 + + sntp/sntp.1@1.63 +2 -2 + NTP_4_2_5P77 + + util/ntp-keygen-opts.c@1.65 +2 -2 + NTP_4_2_5P77 + + util/ntp-keygen-opts.h@1.65 +3 -3 + NTP_4_2_5P77 + + util/ntp-keygen-opts.texi@1.64 +1 -1 + NTP_4_2_5P77 + + util/ntp-keygen.1@1.64 +2 -2 + NTP_4_2_5P77 + +ChangeSet@1.1589, 2007-09-15 16:40:14-04:00, stenn@whimsy.udel.edu + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + ChangeLog@1.111 +2 -0 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + ntpd/ntp_control.c@1.101 +2 -2 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + ntpd/ntp_crypto.c@1.116 +102 -70 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + + util/ntp-keygen.c@1.45 +143 -202 + Crypto cleanup from Dave Mills.\n[Bug 897] Check RAND_status() - we may not need a .rnd file + +ChangeSet@1.1588, 2007-09-13 07:44:43-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P76 + TAG: NTP_4_2_5P76 + + ntpd/ntpd-opts.c@1.63 +2 -2 + NTP_4_2_5P76 + + ntpd/ntpd-opts.h@1.63 +3 -3 + NTP_4_2_5P76 + + ntpd/ntpd-opts.texi@1.62 +1 -1 + NTP_4_2_5P76 + + ntpd/ntpd.1@1.62 +2 -2 + NTP_4_2_5P76 + + ntpdc/ntpdc-opts.c@1.63 +2 -2 + NTP_4_2_5P76 + + ntpdc/ntpdc-opts.h@1.63 +3 -3 + NTP_4_2_5P76 + + ntpdc/ntpdc-opts.texi@1.62 +1 -1 + NTP_4_2_5P76 + + ntpdc/ntpdc.1@1.62 +2 -2 + NTP_4_2_5P76 + + ntpq/ntpq-opts.c@1.63 +2 -2 + NTP_4_2_5P76 + + ntpq/ntpq-opts.h@1.63 +3 -3 + NTP_4_2_5P76 + + ntpq/ntpq-opts.texi@1.62 +1 -1 + NTP_4_2_5P76 + + ntpq/ntpq.1@1.62 +2 -2 + NTP_4_2_5P76 + + packageinfo.sh@1.79 +1 -1 + NTP_4_2_5P76 + + sntp/sntp-opts.c@1.63 +2 -2 + NTP_4_2_5P76 + + sntp/sntp-opts.h@1.63 +3 -3 + NTP_4_2_5P76 + + sntp/sntp-opts.texi@1.62 +1 -1 + NTP_4_2_5P76 + + sntp/sntp.1@1.62 +2 -2 + NTP_4_2_5P76 + + util/ntp-keygen-opts.c@1.64 +2 -2 + NTP_4_2_5P76 + + util/ntp-keygen-opts.h@1.64 +3 -3 + NTP_4_2_5P76 + + util/ntp-keygen-opts.texi@1.63 +1 -1 + NTP_4_2_5P76 + + util/ntp-keygen.1@1.63 +2 -2 + NTP_4_2_5P76 + +ChangeSet@1.1587, 2007-09-12 17:22:55-04:00, stenn@whimsy.udel.edu + [Bug 911] Fix error message in cmd_args.c + + ChangeLog@1.110 +1 -0 + [Bug 911] Fix error message in cmd_args.c + + ntpd/cmd_args.c@1.52 +0 -1 + [Bug 911] Fix error message in cmd_args.c + +ChangeSet@1.1586, 2007-09-11 07:47:21-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P75 + TAG: NTP_4_2_5P75 + + ntpd/ntpd-opts.c@1.62 +2 -2 + NTP_4_2_5P75 + + ntpd/ntpd-opts.h@1.62 +3 -3 + NTP_4_2_5P75 + + ntpd/ntpd-opts.texi@1.61 +1 -1 + NTP_4_2_5P75 + + ntpd/ntpd.1@1.61 +2 -2 + NTP_4_2_5P75 + + ntpdc/ntpdc-opts.c@1.62 +2 -2 + NTP_4_2_5P75 + + ntpdc/ntpdc-opts.h@1.62 +3 -3 + NTP_4_2_5P75 + + ntpdc/ntpdc-opts.texi@1.61 +1 -1 + NTP_4_2_5P75 + + ntpdc/ntpdc.1@1.61 +2 -2 + NTP_4_2_5P75 + + ntpq/ntpq-opts.c@1.62 +2 -2 + NTP_4_2_5P75 + + ntpq/ntpq-opts.h@1.62 +3 -3 + NTP_4_2_5P75 + + ntpq/ntpq-opts.texi@1.61 +1 -1 + NTP_4_2_5P75 + + ntpq/ntpq.1@1.61 +2 -2 + NTP_4_2_5P75 + + packageinfo.sh@1.78 +1 -1 + NTP_4_2_5P75 + + sntp/sntp-opts.c@1.62 +2 -2 + NTP_4_2_5P75 + + sntp/sntp-opts.h@1.62 +3 -3 + NTP_4_2_5P75 + + sntp/sntp-opts.texi@1.61 +1 -1 + NTP_4_2_5P75 + + sntp/sntp.1@1.61 +2 -2 + NTP_4_2_5P75 + + util/ntp-keygen-opts.c@1.63 +2 -2 + NTP_4_2_5P75 + + util/ntp-keygen-opts.h@1.63 +3 -3 + NTP_4_2_5P75 + + util/ntp-keygen-opts.texi@1.62 +1 -1 + NTP_4_2_5P75 + + util/ntp-keygen.1@1.62 +2 -2 + NTP_4_2_5P75 + +ChangeSet@1.1585, 2007-09-11 04:14:55-04:00, murray@pogo.udel.edu + [Bug 895] Log assertion failures via syslog(), not stderr + + ChangeLog@1.109 +1 -0 + [Bug 895] Log assertion failures via syslog(), not stderr + +ChangeSet@1.1436.1.84, 2007-09-10 20:40:19-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P4 + TAG: NTP_4_2_4P4 + + ntpd/ntpd-opts.c@1.50.13.1 +2 -2 + NTP_4_2_4P4 + + ntpd/ntpd-opts.h@1.50.13.1 +3 -3 + NTP_4_2_4P4 + + ntpd/ntpd-opts.texi@1.49.13.1 +1 -1 + NTP_4_2_4P4 + + ntpd/ntpd.1@1.48.13.1 +2 -2 + NTP_4_2_4P4 + + ntpd/ntpdsim-opts.c@1.50.13.1 +2 -2 + NTP_4_2_4P4 + + ntpd/ntpdsim-opts.h@1.50.13.1 +3 -3 + NTP_4_2_4P4 + + ntpd/ntpdsim-opts.texi@1.48.13.1 +1 -1 + NTP_4_2_4P4 + + ntpd/ntpdsim.1@1.48.13.1 +2 -2 + NTP_4_2_4P4 + + ntpdc/ntpdc-opts.c@1.50.13.1 +2 -2 + NTP_4_2_4P4 + + ntpdc/ntpdc-opts.h@1.50.13.1 +3 -3 + NTP_4_2_4P4 + + ntpdc/ntpdc-opts.texi@1.48.13.1 +1 -1 + NTP_4_2_4P4 + + ntpdc/ntpdc.1@1.48.13.1 +2 -2 + NTP_4_2_4P4 + + ntpq/ntpq-opts.c@1.52.13.1 +2 -2 + NTP_4_2_4P4 + + ntpq/ntpq-opts.h@1.52.13.1 +3 -3 + NTP_4_2_4P4 + + ntpq/ntpq-opts.texi@1.49.13.1 +1 -1 + NTP_4_2_4P4 + + ntpq/ntpq.1@1.48.13.1 +2 -2 + NTP_4_2_4P4 + + packageinfo.sh@1.65.19.2 +2 -2 + NTP_4_2_4P4 + + sntp/sntp-opts.c@1.49.13.1 +2 -2 + NTP_4_2_4P4 + + sntp/sntp-opts.h@1.49.13.1 +3 -3 + NTP_4_2_4P4 + + sntp/sntp-opts.texi@1.46.13.1 +1 -1 + NTP_4_2_4P4 + + sntp/sntp.1@1.49.13.1 +2 -2 + NTP_4_2_4P4 + + util/ntp-keygen-opts.c@1.49.13.1 +2 -2 + NTP_4_2_4P4 + + util/ntp-keygen-opts.h@1.49.13.1 +3 -3 + NTP_4_2_4P4 + + util/ntp-keygen-opts.texi@1.47.13.1 +1 -1 + NTP_4_2_4P4 + + util/ntp-keygen.1@1.47.13.1 +2 -2 + NTP_4_2_4P4 + +ChangeSet@1.1436.1.83, 2007-09-10 16:56:09-04:00, stenn@whimsy.udel.edu + Release 4.2.4p4 + + ChangeLog@1.1.1.34 +3 -0 + Release 4.2.4p4 + + NEWS@1.86.1.12 +11 -0 + Release 4.2.4p4 + + packageinfo.sh@1.65.19.1 +1 -1 + Release 4.2.4p4 + +ChangeSet@1.1582.1.7, 2007-09-10 07:56:32-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P74 + TAG: NTP_4_2_5P74 + + ntpd/ntpd-opts.c@1.61 +2 -2 + NTP_4_2_5P74 + + ntpd/ntpd-opts.h@1.61 +3 -3 + NTP_4_2_5P74 + + ntpd/ntpd-opts.texi@1.60 +1 -1 + NTP_4_2_5P74 + + ntpd/ntpd.1@1.60 +2 -2 + NTP_4_2_5P74 + + ntpdc/ntpdc-opts.c@1.61 +2 -2 + NTP_4_2_5P74 + + ntpdc/ntpdc-opts.h@1.61 +3 -3 + NTP_4_2_5P74 + + ntpdc/ntpdc-opts.texi@1.60 +1 -1 + NTP_4_2_5P74 + + ntpdc/ntpdc.1@1.60 +2 -2 + NTP_4_2_5P74 + + ntpq/ntpq-opts.c@1.61 +2 -2 + NTP_4_2_5P74 + + ntpq/ntpq-opts.h@1.61 +3 -3 + NTP_4_2_5P74 + + ntpq/ntpq-opts.texi@1.60 +1 -1 + NTP_4_2_5P74 + + ntpq/ntpq.1@1.60 +2 -2 + NTP_4_2_5P74 + + packageinfo.sh@1.77 +1 -1 + NTP_4_2_5P74 + + sntp/sntp-opts.c@1.61 +2 -2 + NTP_4_2_5P74 + + sntp/sntp-opts.h@1.61 +3 -3 + NTP_4_2_5P74 + + sntp/sntp-opts.texi@1.60 +1 -1 + NTP_4_2_5P74 + + sntp/sntp.1@1.60 +2 -2 + NTP_4_2_5P74 + + util/ntp-keygen-opts.c@1.62 +2 -2 + NTP_4_2_5P74 + + util/ntp-keygen-opts.h@1.62 +3 -3 + NTP_4_2_5P74 + + util/ntp-keygen-opts.texi@1.61 +1 -1 + NTP_4_2_5P74 + + util/ntp-keygen.1@1.61 +2 -2 + NTP_4_2_5P74 + +ChangeSet@1.1582.1.6, 2007-09-10 02:32:58-04:00, stenn@whimsy.udel.edu + Documentation updates from Dave Mills + + ChangeLog@1.107 +1 -0 + Documentation updates from Dave Mills + + html/authopt.html@1.42 +56 -54 + Documentation updates from Dave Mills + + html/keygen.html@1.9 +49 -59 + Documentation updates from Dave Mills + +ChangeSet@1.1436.1.82, 2007-09-10 01:57:20-04:00, stenn@whimsy.udel.edu + [Bug 902] Fix problems with the -6 flag + + ChangeLog@1.1.1.33 +1 -0 + [Bug 902] Fix problems with the -6 flag + + libopts/save.c@1.2 +11 -2 + [Bug 902] Fix problems with the -6 flag + + sntp/libopts/save.c@1.2 +11 -2 + [Bug 902] Fix problems with the -6 flag + +ChangeSet@1.1582.1.4, 2007-09-09 07:10:45-04:00, stenn@whimsy.udel.edu + crypto fixes from Dave Mills + + ChangeLog@1.105 +2 -0 + crypto fixes from Dave Mills + + include/ntp.h@1.137 +3 -3 + crypto fixes from Dave Mills + + include/ntp_control.h@1.32 +4 -6 + crypto fixes from Dave Mills + + include/ntpd.h@1.110 +1 -0 + crypto fixes from Dave Mills + + ntpd/ntp_control.c@1.100 +12 -21 + crypto fixes from Dave Mills + + ntpd/ntp_crypto.c@1.115 +472 -540 + crypto fixes from Dave Mills + + ntpd/ntp_peer.c@1.107 +3 -0 + crypto fixes from Dave Mills + + ntpd/ntp_proto.c@1.262 +3 -6 + crypto fixes from Dave Mills + +ChangeSet@1.1582.1.3, 2007-09-09 06:48:21-04:00, stenn@whimsy.udel.edu + Avoid double peer stats logging + + ChangeLog@1.104 +1 -0 + Avoid double peer stats logging + + ntpd/ntp_refclock.c@1.78 +0 -3 + Avoid double peer stats logging + +ChangeSet@1.1582.1.2, 2007-09-09 05:30:21-04:00, stenn@whimsy.udel.edu + ntp-keygen cleanup from Dave Mills + + ChangeLog@1.103 +1 -0 + ntp-keygen cleanup from Dave Mills + + util/ntp-keygen.c@1.44 +187 -146 + ntp-keygen cleanup from Dave Mills + +ChangeSet@1.1582.1.1, 2007-09-09 05:19:17-04:00, stenn@whimsy.udel.edu + libopts needs to be built after ElectricFence + + ChangeLog@1.102 +1 -0 + libopts needs to be built after ElectricFence + + Makefile.am@1.76 +4 -3 + libopts needs to be built after ElectricFence + +ChangeSet@1.1583, 2007-09-06 16:56:06-04:00, murray@pogo.udel.edu + Fix for bug 895 + + ntpd/ntpd.c@1.89 +91 -0 + Fix for bug 895 + +ChangeSet@1.1582, 2007-08-29 07:48:23-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P73 + TAG: NTP_4_2_5P73 + + ntpd/ntpd-opts.c@1.60 +2 -2 + NTP_4_2_5P73 + + ntpd/ntpd-opts.h@1.60 +3 -3 + NTP_4_2_5P73 + + ntpd/ntpd-opts.texi@1.59 +1 -1 + NTP_4_2_5P73 + + ntpd/ntpd.1@1.59 +2 -2 + NTP_4_2_5P73 + + ntpdc/ntpdc-opts.c@1.60 +2 -2 + NTP_4_2_5P73 + + ntpdc/ntpdc-opts.h@1.60 +3 -3 + NTP_4_2_5P73 + + ntpdc/ntpdc-opts.texi@1.59 +1 -1 + NTP_4_2_5P73 + + ntpdc/ntpdc.1@1.59 +2 -2 + NTP_4_2_5P73 + + ntpq/ntpq-opts.c@1.60 +2 -2 + NTP_4_2_5P73 + + ntpq/ntpq-opts.h@1.60 +3 -3 + NTP_4_2_5P73 + + ntpq/ntpq-opts.texi@1.59 +1 -1 + NTP_4_2_5P73 + + ntpq/ntpq.1@1.59 +2 -2 + NTP_4_2_5P73 + + packageinfo.sh@1.76 +1 -1 + NTP_4_2_5P73 + + sntp/sntp-opts.c@1.60 +2 -2 + NTP_4_2_5P73 + + sntp/sntp-opts.h@1.60 +3 -3 + NTP_4_2_5P73 + + sntp/sntp-opts.texi@1.59 +1 -1 + NTP_4_2_5P73 + + sntp/sntp.1@1.59 +2 -2 + NTP_4_2_5P73 + + util/ntp-keygen-opts.c@1.61 +2 -2 + NTP_4_2_5P73 + + util/ntp-keygen-opts.h@1.61 +3 -3 + NTP_4_2_5P73 + + util/ntp-keygen-opts.texi@1.60 +1 -1 + NTP_4_2_5P73 + + util/ntp-keygen.1@1.60 +2 -2 + NTP_4_2_5P73 + +ChangeSet@1.1436.1.81, 2007-08-28 15:34:55-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P4_RC2 + TAG: NTP_4_2_4P4_RC2 + + ntpd/ntpd-opts.c@1.50.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpd-opts.h@1.50.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpd-opts.texi@1.49.12.1 +2 -2 + NTP_4_2_4P4_RC2 + + ntpd/ntpd.1@1.48.12.1 +3 -3 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim-opts.c@1.50.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim-opts.h@1.50.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim-opts.texi@1.48.12.1 +1 -1 + NTP_4_2_4P4_RC2 + + ntpd/ntpdsim.1@1.48.12.1 +3 -3 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc-opts.c@1.50.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc-opts.h@1.50.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc-opts.texi@1.48.12.1 +2 -2 + NTP_4_2_4P4_RC2 + + ntpdc/ntpdc.1@1.48.12.1 +3 -3 + NTP_4_2_4P4_RC2 + + ntpq/ntpq-opts.c@1.52.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpq/ntpq-opts.h@1.52.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + ntpq/ntpq-opts.texi@1.49.12.1 +2 -2 + NTP_4_2_4P4_RC2 + + ntpq/ntpq.1@1.48.12.1 +3 -3 + NTP_4_2_4P4_RC2 + + packageinfo.sh@1.65.18.1 +1 -1 + NTP_4_2_4P4_RC2 + + sntp/sntp-opts.c@1.49.12.1 +2 -2 + NTP_4_2_4P4_RC2 + + sntp/sntp-opts.h@1.49.12.1 +3 -3 + NTP_4_2_4P4_RC2 + + sntp/sntp-opts.texi@1.46.12.1 +1 -1 + NTP_4_2_4P4_RC2 + + sntp/sntp.1@1.49.12.1 +2 -2 + NTP_4_2_4P4_RC2 + + util/ntp-keygen-opts.c@1.49.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + util/ntp-keygen-opts.h@1.49.12.1 +4 -4 + NTP_4_2_4P4_RC2 + + util/ntp-keygen-opts.texi@1.47.12.1 +2 -2 + NTP_4_2_4P4_RC2 + + util/ntp-keygen.1@1.47.12.1 +3 -3 + NTP_4_2_4P4_RC2 + +ChangeSet@1.1580, 2007-08-28 07:52:12-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P72 + TAG: NTP_4_2_5P72 + + ntpd/ntpd-opts.c@1.59 +4 -4 + NTP_4_2_5P72 + + ntpd/ntpd-opts.h@1.59 +4 -4 + NTP_4_2_5P72 + + ntpd/ntpd-opts.texi@1.58 +2 -2 + NTP_4_2_5P72 + + ntpd/ntpd.1@1.58 +3 -3 + NTP_4_2_5P72 + + ntpdc/ntpdc-opts.c@1.59 +4 -4 + NTP_4_2_5P72 + + ntpdc/ntpdc-opts.h@1.59 +4 -4 + NTP_4_2_5P72 + + ntpdc/ntpdc-opts.texi@1.58 +2 -2 + NTP_4_2_5P72 + + ntpdc/ntpdc.1@1.58 +3 -3 + NTP_4_2_5P72 + + ntpq/ntpq-opts.c@1.59 +4 -4 + NTP_4_2_5P72 + + ntpq/ntpq-opts.h@1.59 +4 -4 + NTP_4_2_5P72 + + ntpq/ntpq-opts.texi@1.58 +2 -2 + NTP_4_2_5P72 + + ntpq/ntpq.1@1.58 +3 -3 + NTP_4_2_5P72 + + packageinfo.sh@1.75 +1 -1 + NTP_4_2_5P72 + + sntp/sntp-opts.c@1.59 +2 -2 + NTP_4_2_5P72 + + sntp/sntp-opts.h@1.59 +3 -3 + NTP_4_2_5P72 + + sntp/sntp-opts.texi@1.58 +1 -1 + NTP_4_2_5P72 + + sntp/sntp.1@1.58 +2 -2 + NTP_4_2_5P72 + + util/ntp-keygen-opts.c@1.60 +6 -5 + NTP_4_2_5P72 + + util/ntp-keygen-opts.h@1.60 +4 -4 + NTP_4_2_5P72 + + util/ntp-keygen-opts.texi@1.59 +2 -2 + NTP_4_2_5P72 + + util/ntp-keygen.1@1.59 +4 -4 + NTP_4_2_5P72 + +ChangeSet@1.1579, 2007-08-28 00:00:03-04:00, stenn@whimsy.udel.edu + [Bug 894] Initialize keysdir before calling crypto_setup() + + ChangeLog@1.101 +1 -0 + [Bug 894] Initialize keysdir before calling crypto_setup() + +ChangeSet@1.1576.1.2, 2007-08-27 23:42:20-04:00, stenn@whimsy.udel.edu + ntp-keygen-opts.def: + ntp-keygen -i takes an arg + ntpq.c: + Calysto cleanup for ntpq. + Many files: + Cleanup from Dave Mills + ChangeLog: + Cleanup from Dave Mills. + Coverity fix for ntpq. + ntp-keygen -i takes an arg. + + ChangeLog@1.100 +3 -0 + Cleanup from Dave Mills. + Coverity fix for ntpq. + ntp-keygen -i takes an arg. + + include/ntp.h@1.136 +3 -5 + Cleanup from Dave Mills + + include/ntp_crypto.h@1.42 +20 -14 + Cleanup from Dave Mills + + include/ntpd.h@1.109 +2 -1 + Cleanup from Dave Mills + + ntpd/ntp_control.c@1.99 +23 -28 + Cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.114 +337 -345 + Cleanup from Dave Mills + + ntpd/ntp_parser.c@1.20 +578 -586 + Cleanup from Dave Mills + + ntpd/ntp_parser.y@1.16 +0 -2 + Cleanup from Dave Mills + + ntpd/ntp_proto.c@1.261 +30 -43 + Cleanup from Dave Mills + + ntpq/ntpq.c@1.70 +2 -0 + Calysto cleanup for ntpq. + + util/ntp-keygen-opts.def@1.9 +2 -0 + ntp-keygen -i takes an arg + + util/ntp-keygen.c@1.43 +188 -200 + Cleanup from Dave Mills + +ChangeSet@1.1436.1.80, 2007-08-27 22:38:57-04:00, stenn@whimsy.udel.edu + Updated include/copyright.def (owner and year) + + ChangeLog@1.1.1.32 +1 -0 + Updated include/copyright.def (owner and year) + + include/copyright.def@1.5 +2 -2 + Updated include/copyright.def (owner and year) + +ChangeSet@1.1577, 2007-08-25 13:22:24+00:00, kardel@pogo.udel.edu + ntp_config.c: + Bug 894: initialize keysdir BEFORE crypto_setup() is called - so it has a fair + chance to find the keys. + + ntpd/ntp_config.c@1.164 +5 -4 + Bug 894: initialize keysdir BEFORE crypto_setup() is called - so it has a fair + chance to find the keys. + +ChangeSet@1.1576, 2007-08-19 07:45:24-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P71 + TAG: NTP_4_2_5P71 + + ntpd/ntpd-opts.c@1.58 +2 -2 + NTP_4_2_5P71 + + ntpd/ntpd-opts.h@1.58 +3 -3 + NTP_4_2_5P71 + + ntpd/ntpd-opts.texi@1.57 +1 -1 + NTP_4_2_5P71 + + ntpd/ntpd.1@1.57 +2 -2 + NTP_4_2_5P71 + + ntpdc/ntpdc-opts.c@1.58 +2 -2 + NTP_4_2_5P71 + + ntpdc/ntpdc-opts.h@1.58 +3 -3 + NTP_4_2_5P71 + + ntpdc/ntpdc-opts.texi@1.57 +1 -1 + NTP_4_2_5P71 + + ntpdc/ntpdc.1@1.57 +2 -2 + NTP_4_2_5P71 + + ntpq/ntpq-opts.c@1.58 +2 -2 + NTP_4_2_5P71 + + ntpq/ntpq-opts.h@1.58 +3 -3 + NTP_4_2_5P71 + + ntpq/ntpq-opts.texi@1.57 +1 -1 + NTP_4_2_5P71 + + ntpq/ntpq.1@1.57 +2 -2 + NTP_4_2_5P71 + + packageinfo.sh@1.74 +1 -1 + NTP_4_2_5P71 + + sntp/sntp-opts.c@1.58 +2 -2 + NTP_4_2_5P71 + + sntp/sntp-opts.h@1.58 +3 -3 + NTP_4_2_5P71 + + sntp/sntp-opts.texi@1.57 +1 -1 + NTP_4_2_5P71 + + sntp/sntp.1@1.57 +2 -2 + NTP_4_2_5P71 + + util/ntp-keygen-opts.c@1.59 +2 -2 + NTP_4_2_5P71 + + util/ntp-keygen-opts.h@1.59 +3 -3 + NTP_4_2_5P71 + + util/ntp-keygen-opts.texi@1.58 +1 -1 + NTP_4_2_5P71 + + util/ntp-keygen.1@1.58 +2 -2 + NTP_4_2_5P71 + +ChangeSet@1.1436.1.79, 2007-08-19 05:26:13-04:00, dunlop@pogo.udel.edu + ntpdc_ops.c, ChangeLog: + [BUG 881] Corrected display of pll offset on 64bit systems. + [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + [BUG 878] Avoid ntpdc use of refid value as unterminated string. + + ChangeLog@1.1.1.31 +1 -0 + [Bug 878] Avoid ntpdc use of refid value as unterminated string. + + ChangeLog@1.1.1.30 +1 -0 + [Bug 881] Corrected display of pll offset on 64bit systems. + + ChangeLog@1.1.1.29 +1 -0 + [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + + ntpdc/ntpdc_ops.c@1.46.1.3 +1 -3 + [Bug 878] Avoid ntpdc use of refid value as unterminated string. + + ntpdc/ntpdc_ops.c@1.46.1.2 +1 -1 + [Bug 881] Corrected display of pll offset on 64bit systems. + + ntpdc/ntpdc_ops.c@1.46.1.1 +2 -2 + [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + +ChangeSet@1.1575, 2007-08-19 08:35:04+00:00, stenn@ntp1.isc.org + [Bug 887] Fix error in ntp_types.h (for sizeof int != 4) + + ChangeLog@1.98 +1 -0 + [Bug 887] Fix error in ntp_types.h (for sizeof int != 4) + + dot.emacs@1.8 +4 -3 + updates + + include/ntp_types.h@1.10 +2 -2 + [Bug 887] Fix error in ntp_types.h (for sizeof int != 4) + +ChangeSet@1.1574, 2007-08-18 19:14:33-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P70 + TAG: NTP_4_2_5P70 + + ntpd/ntpd-opts.c@1.57 +2 -2 + NTP_4_2_5P70 + + ntpd/ntpd-opts.h@1.57 +3 -3 + NTP_4_2_5P70 + + ntpd/ntpd-opts.texi@1.56 +1 -1 + NTP_4_2_5P70 + + ntpd/ntpd.1@1.56 +2 -2 + NTP_4_2_5P70 + + ntpdc/ntpdc-opts.c@1.57 +2 -2 + NTP_4_2_5P70 + + ntpdc/ntpdc-opts.h@1.57 +3 -3 + NTP_4_2_5P70 + + ntpdc/ntpdc-opts.texi@1.56 +1 -1 + NTP_4_2_5P70 + + ntpdc/ntpdc.1@1.56 +2 -2 + NTP_4_2_5P70 + + ntpq/ntpq-opts.c@1.57 +2 -2 + NTP_4_2_5P70 + + ntpq/ntpq-opts.h@1.57 +3 -3 + NTP_4_2_5P70 + + ntpq/ntpq-opts.texi@1.56 +1 -1 + NTP_4_2_5P70 + + ntpq/ntpq.1@1.56 +2 -2 + NTP_4_2_5P70 + + packageinfo.sh@1.73 +1 -1 + NTP_4_2_5P70 + + sntp/sntp-opts.c@1.57 +2 -2 + NTP_4_2_5P70 + + sntp/sntp-opts.h@1.57 +3 -3 + NTP_4_2_5P70 + + sntp/sntp-opts.texi@1.56 +1 -1 + NTP_4_2_5P70 + + sntp/sntp.1@1.56 +2 -2 + NTP_4_2_5P70 + + util/ntp-keygen-opts.c@1.58 +2 -2 + NTP_4_2_5P70 + + util/ntp-keygen-opts.h@1.58 +3 -3 + NTP_4_2_5P70 + + util/ntp-keygen-opts.texi@1.57 +1 -1 + NTP_4_2_5P70 + + util/ntp-keygen.1@1.57 +2 -2 + NTP_4_2_5P70 + +ChangeSet@1.1436.1.78, 2007-08-18 17:11:19-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P4_RC1 + TAG: NTP_4_2_4P4_RC1 + + ntpd/ntpd-opts.c@1.50.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpd-opts.h@1.50.11.1 +3 -3 + NTP_4_2_4P4_RC1 + + ntpd/ntpd-opts.texi@1.49.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpd.1@1.48.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim-opts.c@1.50.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim-opts.h@1.50.11.1 +3 -3 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim-opts.texi@1.48.11.1 +1 -1 + NTP_4_2_4P4_RC1 + + ntpd/ntpdsim.1@1.48.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc-opts.c@1.50.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc-opts.h@1.50.11.1 +3 -3 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc-opts.texi@1.48.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpdc/ntpdc.1@1.48.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpq/ntpq-opts.c@1.52.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpq/ntpq-opts.h@1.52.11.1 +3 -3 + NTP_4_2_4P4_RC1 + + ntpq/ntpq-opts.texi@1.49.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + ntpq/ntpq.1@1.48.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + packageinfo.sh@1.65.17.2 +2 -2 + NTP_4_2_4P4_RC1 + + sntp/sntp-opts.c@1.49.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + sntp/sntp-opts.h@1.49.11.1 +3 -3 + NTP_4_2_4P4_RC1 + + sntp/sntp-opts.texi@1.46.11.1 +1 -1 + NTP_4_2_4P4_RC1 + + sntp/sntp.1@1.49.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + util/ntp-keygen-opts.c@1.49.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + util/ntp-keygen-opts.h@1.49.11.1 +3 -3 + NTP_4_2_4P4_RC1 + + util/ntp-keygen-opts.texi@1.47.11.1 +2 -2 + NTP_4_2_4P4_RC1 + + util/ntp-keygen.1@1.47.11.1 +2 -2 + NTP_4_2_4P4_RC1 + +ChangeSet@1.1436.1.77, 2007-08-18 16:16:22-04:00, stenn@whimsy.udel.edu + 4.2.4p4-RC + + packageinfo.sh@1.65.17.1 +1 -1 + 4.2.4p4-RC + +ChangeSet@1.1436.1.76, 2007-08-18 12:59:45+00:00, kardel@pogo.udel.edu + ntp_restrict.c: + Bug 885: clarify to allow tools to pick up + invariants easier. + Use NULL instead of 0 with pointers. + ChangeLog: + document ntp_restrict.c change + + ChangeLog@1.1.1.28 +1 -0 + document ntp_restrict.c change + + ntpd/ntp_restrict.c@1.22.1.1 +21 -21 + Bug 885: clarify to allow tools to pick up + invariants easier. + Use NULL instead of 0 with pointers. + +ChangeSet@1.1436.1.75, 2007-08-18 12:53:35+00:00, kardel@pogo.udel.edu + recvbuff.c: + Bug 889: avoid malloc() interrupted by SIGIO risk + ChangeLog: + document Bug 889 + + ChangeLog@1.1.1.27 +1 -0 + document Bug 889 + + libntp/recvbuff.c@1.26 +28 -21 + Bug 889: avoid malloc() interrupted by SIGIO risk + +ChangeSet@1.1572, 2007-08-18 07:46:58-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P69 + TAG: NTP_4_2_5P69 + + ntpd/ntpd-opts.c@1.56 +2 -2 + NTP_4_2_5P69 + + ntpd/ntpd-opts.h@1.56 +3 -3 + NTP_4_2_5P69 + + ntpd/ntpd-opts.texi@1.55 +1 -1 + NTP_4_2_5P69 + + ntpd/ntpd.1@1.55 +2 -2 + NTP_4_2_5P69 + + ntpdc/ntpdc-opts.c@1.56 +2 -2 + NTP_4_2_5P69 + + ntpdc/ntpdc-opts.h@1.56 +3 -3 + NTP_4_2_5P69 + + ntpdc/ntpdc-opts.texi@1.55 +1 -1 + NTP_4_2_5P69 + + ntpdc/ntpdc.1@1.55 +2 -2 + NTP_4_2_5P69 + + ntpq/ntpq-opts.c@1.56 +2 -2 + NTP_4_2_5P69 + + ntpq/ntpq-opts.h@1.56 +3 -3 + NTP_4_2_5P69 + + ntpq/ntpq-opts.texi@1.55 +1 -1 + NTP_4_2_5P69 + + ntpq/ntpq.1@1.55 +2 -2 + NTP_4_2_5P69 + + packageinfo.sh@1.72 +1 -1 + NTP_4_2_5P69 + + sntp/sntp-opts.c@1.56 +2 -2 + NTP_4_2_5P69 + + sntp/sntp-opts.h@1.56 +3 -3 + NTP_4_2_5P69 + + sntp/sntp-opts.texi@1.55 +1 -1 + NTP_4_2_5P69 + + sntp/sntp.1@1.55 +2 -2 + NTP_4_2_5P69 + + util/ntp-keygen-opts.c@1.57 +2 -2 + NTP_4_2_5P69 + + util/ntp-keygen-opts.h@1.57 +3 -3 + NTP_4_2_5P69 + + util/ntp-keygen-opts.texi@1.56 +1 -1 + NTP_4_2_5P69 + + util/ntp-keygen.1@1.56 +2 -2 + NTP_4_2_5P69 + +ChangeSet@1.1436.1.74, 2007-08-18 09:51:41+00:00, kardel@pogo.udel.edu + cmd_args.c: + Bug 885: fix comparison + + ntpd/cmd_args.c@1.45.3.2 +1 -1 + Bug 885: fix comparison + +ChangeSet@1.1570, 2007-08-18 04:07:51-04:00, stenn@pogo.udel.edu + merge cleanup + + ChangeLog@1.95.1.2 +13 -0 + merge cleanup + +ChangeSet@1.1564.2.2, 2007-08-17 07:46:18-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P68 + TAG: NTP_4_2_5P68 + + ntpd/ntpd-opts.c@1.55 +2 -2 + NTP_4_2_5P68 + + ntpd/ntpd-opts.h@1.55 +3 -3 + NTP_4_2_5P68 + + ntpd/ntpd-opts.texi@1.54 +2 -2 + NTP_4_2_5P68 + + ntpd/ntpd.1@1.54 +2 -2 + NTP_4_2_5P68 + + ntpdc/ntpdc-opts.c@1.55 +2 -2 + NTP_4_2_5P68 + + ntpdc/ntpdc-opts.h@1.55 +3 -3 + NTP_4_2_5P68 + + ntpdc/ntpdc-opts.texi@1.54 +2 -2 + NTP_4_2_5P68 + + ntpdc/ntpdc.1@1.54 +2 -2 + NTP_4_2_5P68 + + ntpq/ntpq-opts.c@1.55 +2 -2 + NTP_4_2_5P68 + + ntpq/ntpq-opts.h@1.55 +3 -3 + NTP_4_2_5P68 + + ntpq/ntpq-opts.texi@1.54 +2 -2 + NTP_4_2_5P68 + + ntpq/ntpq.1@1.54 +2 -2 + NTP_4_2_5P68 + + packageinfo.sh@1.71 +1 -1 + NTP_4_2_5P68 + + sntp/sntp-opts.c@1.55 +2 -2 + NTP_4_2_5P68 + + sntp/sntp-opts.h@1.55 +3 -3 + NTP_4_2_5P68 + + sntp/sntp-opts.texi@1.54 +1 -1 + NTP_4_2_5P68 + + sntp/sntp.1@1.54 +2 -2 + NTP_4_2_5P68 + + util/ntp-keygen-opts.c@1.56 +2 -2 + NTP_4_2_5P68 + + util/ntp-keygen-opts.h@1.56 +3 -3 + NTP_4_2_5P68 + + util/ntp-keygen-opts.texi@1.55 +2 -2 + NTP_4_2_5P68 + + util/ntp-keygen.1@1.55 +2 -2 + NTP_4_2_5P68 + +ChangeSet@1.1436.6.1, 2007-08-17 05:28:07-04:00, stenn@pogo.udel.edu + Use autoconf-2.59 and automake-1.9 for building 4.2.4 + + bootstrap@1.18.1.1 +18 -2 + Use autoconf-2.59 and automake-1.9 for building 4.2.4 + +ChangeSet@1.1564.2.1, 2007-08-17 01:38:48-04:00, stenn@whimsy.udel.edu + Cleanup from Dave Mills + + html/assoc.html@1.22 +22 -13 + Cleanup from Dave Mills + + html/index.html@1.34 +6 -6 + Cleanup from Dave Mills + + html/release.html@1.32 +7 -9 + Cleanup from Dave Mills + + include/ntp.h@1.135 +11 -10 + Cleanup from Dave Mills + + include/ntp_crypto.h@1.41 +21 -17 + Cleanup from Dave Mills + + include/ntp_refclock.h@1.22 +1 -1 + Cleanup from Dave Mills + + include/ntp_request.h@1.33 +2 -2 + Cleanup from Dave Mills + + include/ntpd.h@1.108 +12 -12 + Cleanup from Dave Mills + + libntp/statestr.c@1.12 +1 -1 + Cleanup from Dave Mills + + ntpd/ntp_config.c@1.161.1.1 +6 -9 + Cleanup from Dave Mills + + ntpd/ntp_control.c@1.98 +8 -5 + Cleanup from Dave Mills + + ntpd/ntp_crypto.c@1.113 +175 -101 + Cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.139 +85 -77 + Cleanup from Dave Mills + + ntpd/ntp_parser.c@1.19 +239 -261 + Cleanup from Dave Mills + + ntpd/ntp_parser.y@1.15 +1 -23 + Cleanup from Dave Mills + + ntpd/ntp_peer.c@1.106 +4 -14 + Cleanup from Dave Mills + + ntpd/ntp_proto.c@1.260 +390 -490 + Cleanup from Dave Mills + + ntpd/ntp_refclock.c@1.77 +4 -6 + Cleanup from Dave Mills + + ntpd/ntp_request.c@1.69 +4 -4 + Cleanup from Dave Mills + + ntpd/ntp_restrict.c@1.23 +2 -2 + Cleanup from Dave Mills + + ntpd/ntp_timer.c@1.40 +7 -20 + Cleanup from Dave Mills + + ntpd/ntp_util.c@1.59 +1 -3 + Cleanup from Dave Mills + + ntpd/ntpd.c@1.88 +6 -21 + Cleanup from Dave Mills + + ntpd/ntpsim.c@1.18 +1 -1 + Cleanup from Dave Mills + + ntpd/refclock_acts.c@1.31 +1 -3 + Cleanup from Dave Mills + + ntpdate/ntpdate.c@1.63 +2 -2 + Cleanup from Dave Mills + + ntpdate/ntpdate.h@1.9 +1 -1 + Cleanup from Dave Mills + + ntpq/ntpq.c@1.69 +4 -4 + Cleanup from Dave Mills + +ChangeSet@1.1564.1.4, 2007-08-14 23:01:09-04:00, mayer@pogo.udel.edu + Bug 880 fixes + + ChangeLog@1.96 +1 -0 + Bug 880 fixes + +ChangeSet@1.1564.1.3, 2007-08-14 22:55:12-04:00, mayer@pogo.udel.edu + Bug 880 bug fixes for Windows build + + ntpd/ntp_data_structures.c@1.6 +1 -0 + Bug 880 Include missing. Needed for emalloc prototype + + ports/winnt/ntpd/nt_clockstuff.c@1.24 +1 -1 + Bug 880 Use leap_sec instead of leap_next + +ChangeSet@1.1436.1.72, 2007-08-11 17:32:22+00:00, kardel@pogo.udel.edu + ChangeLog: + document refclock_parse.c fix + + ChangeLog@1.1.1.26 +1 -0 + document refclock_parse.c fix + +ChangeSet@1.1436.1.71, 2007-08-11 17:30:42+00:00, kardel@pogo.udel.edu + ChangeLog: + document Bug 885 + ntp_io.c: + Bug 885: use emalloc() to get a message at the end of the memory + cmd_args.c: + Bug 885: unsigned types cannot be less than 0 + default_ai_family is a short + ntp_config.c: + Bug 885: lose trailing , from enum list + + ChangeLog@1.1.1.25 +4 -0 + document Bug 885 + + ntpd/cmd_args.c@1.45.3.1 +2 -2 + Bug 885: unsigned types cannot be less than 0 + default_ai_family is a short + + ntpd/ntp_config.c@1.141.1.1 +1 -1 + Bug 885: lose trailing , from enum list + + ntpd/ntp_io.c@1.244.2.9 +1 -1 + Bug 885: use emalloc() to get a message at the end of the memory + +ChangeSet@1.1436.1.70, 2007-08-11 17:19:45+00:00, kardel@pogo.udel.edu + refclock_parse.c: + remove io binding before io_closeclock() closes the file descriptor + + ntpd/refclock_parse.c@1.47.1.1 +25 -10 + remove io binding before io_closeclock() closes the file descriptor + +ChangeSet@1.1436.1.69, 2007-08-09 20:30:55+00:00, kardel@pogo.udel.edu + ChangeLog: + [Bug 882] allow loopback interfaces to share addresses with other interfaces. + [Bug 884] don't access recv buffers after having them passed to the free list. + + ChangeLog@1.1.1.24 +3 -0 + [Bug 882] allow loopback interfaces to share addresses with other interfaces. + [Bug 884] don't access recv buffers after having them passed to the free list. + +ChangeSet@1.1436.1.68, 2007-08-09 19:05:17+00:00, kardel@pogo.udel.edu + ntp_io.c: + Bug 884: no access to recv buffers after they are returned to free pool + + ntpd/ntp_io.c@1.244.2.8 +9 -7 + Bug 884: no access to recv buffers after they are returned to free pool + +ChangeSet@1.1564.1.2, 2007-08-09 07:43:48-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P67 + TAG: NTP_4_2_5P67 + + ntpd/ntpd-opts.c@1.54 +2 -2 + NTP_4_2_5P67 + + ntpd/ntpd-opts.h@1.54 +3 -3 + NTP_4_2_5P67 + + ntpd/ntpd-opts.texi@1.53 +2 -2 + NTP_4_2_5P67 + + ntpd/ntpd.1@1.53 +2 -2 + NTP_4_2_5P67 + + ntpdc/ntpdc-opts.c@1.54 +2 -2 + NTP_4_2_5P67 + + ntpdc/ntpdc-opts.h@1.54 +3 -3 + NTP_4_2_5P67 + + ntpdc/ntpdc-opts.texi@1.53 +2 -2 + NTP_4_2_5P67 + + ntpdc/ntpdc.1@1.53 +2 -2 + NTP_4_2_5P67 + + ntpq/ntpq-opts.c@1.54 +2 -2 + NTP_4_2_5P67 + + ntpq/ntpq-opts.h@1.54 +3 -3 + NTP_4_2_5P67 + + ntpq/ntpq-opts.texi@1.53 +2 -2 + NTP_4_2_5P67 + + ntpq/ntpq.1@1.53 +2 -2 + NTP_4_2_5P67 + + packageinfo.sh@1.70 +1 -1 + NTP_4_2_5P67 + + sntp/sntp-opts.c@1.54 +2 -2 + NTP_4_2_5P67 + + sntp/sntp-opts.h@1.54 +3 -3 + NTP_4_2_5P67 + + sntp/sntp-opts.texi@1.53 +1 -1 + NTP_4_2_5P67 + + sntp/sntp.1@1.53 +2 -2 + NTP_4_2_5P67 + + util/ntp-keygen-opts.c@1.55 +2 -2 + NTP_4_2_5P67 + + util/ntp-keygen-opts.h@1.55 +3 -3 + NTP_4_2_5P67 + + util/ntp-keygen-opts.texi@1.54 +2 -2 + NTP_4_2_5P67 + + util/ntp-keygen.1@1.54 +2 -2 + NTP_4_2_5P67 + +ChangeSet@1.1564.1.1, 2007-08-08 20:33:49-04:00, stenn@whimsy.udel.edu + Improve Calysto support + + ChangeLog@1.95 +1 -0 + Improve Calysto support + + include/ntp_assert.h@1.2 +12 -0 + Improve Calysto support + +ChangeSet@1.1436.1.67, 2007-08-07 18:14:16+00:00, kardel@pogo.udel.edu + ntp_io.c: + Bug 882: loopback interfaces may share IP addresses with other interfaces + thus allow addresses also found on loopback interfaces to be used + as local address. + + ntpd/ntp_io.c@1.244.2.7 +1 -1 + Bug 882: loopback interfaces may share IP addresses with other interfaces + thus allow addresses also found on loopback interfaces to be used + as local address. + +ChangeSet@1.1564, 2007-08-07 07:44:49-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P66 + TAG: NTP_4_2_5P66 + + ntpd/ntpd-opts.c@1.53 +2 -2 + NTP_4_2_5P66 + + ntpd/ntpd-opts.h@1.53 +3 -3 + NTP_4_2_5P66 + + ntpd/ntpd-opts.texi@1.52 +1 -1 + NTP_4_2_5P66 + + ntpd/ntpd.1@1.52 +2 -2 + NTP_4_2_5P66 + + ntpdc/ntpdc-opts.c@1.53 +2 -2 + NTP_4_2_5P66 + + ntpdc/ntpdc-opts.h@1.53 +3 -3 + NTP_4_2_5P66 + + ntpdc/ntpdc-opts.texi@1.52 +1 -1 + NTP_4_2_5P66 + + ntpdc/ntpdc.1@1.52 +2 -2 + NTP_4_2_5P66 + + ntpq/ntpq-opts.c@1.53 +2 -2 + NTP_4_2_5P66 + + ntpq/ntpq-opts.h@1.53 +3 -3 + NTP_4_2_5P66 + + ntpq/ntpq-opts.texi@1.52 +1 -1 + NTP_4_2_5P66 + + ntpq/ntpq.1@1.52 +2 -2 + NTP_4_2_5P66 + + packageinfo.sh@1.69 +1 -1 + NTP_4_2_5P66 + + sntp/sntp-opts.c@1.53 +2 -2 + NTP_4_2_5P66 + + sntp/sntp-opts.h@1.53 +3 -3 + NTP_4_2_5P66 + + sntp/sntp-opts.texi@1.52 +1 -1 + NTP_4_2_5P66 + + sntp/sntp.1@1.52 +2 -2 + NTP_4_2_5P66 + + util/ntp-keygen-opts.c@1.54 +2 -2 + NTP_4_2_5P66 + + util/ntp-keygen-opts.h@1.54 +3 -3 + NTP_4_2_5P66 + + util/ntp-keygen-opts.texi@1.53 +1 -1 + NTP_4_2_5P66 + + util/ntp-keygen.1@1.53 +2 -2 + NTP_4_2_5P66 + +ChangeSet@1.1563, 2007-08-07 03:10:48-04:00, stenn@whimsy.udel.edu + The "revoke" parameter is a crypto command + + ChangeLog@1.94 +1 -0 + The "revoke" parameter is a crypto command + + ntpd/ntp_parser.c@1.18 +183 -193 + The "revoke" parameter is a crypto command + + ntpd/ntp_parser.y@1.14 +11 -11 + The "revoke" parameter is a crypto command + +ChangeSet@1.1562, 2007-08-07 01:21:53-04:00, stenn@whimsy.udel.edu + The driftfile wander threshold is a real number + + ChangeLog@1.93 +1 -0 + The driftfile wander threshold is a real number + + ntpd/ntp_parser.c@1.17 +151 -141 + The driftfile wander threshold is a real number + +ChangeSet@1.1561, 2007-08-05 07:44:12-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P65 + TAG: NTP_4_2_5P65 + + ntpd/ntpd-opts.c@1.52 +2 -2 + NTP_4_2_5P65 + + ntpd/ntpd-opts.h@1.52 +3 -3 + NTP_4_2_5P65 + + ntpd/ntpd-opts.texi@1.51 +1 -1 + NTP_4_2_5P65 + + ntpd/ntpd.1@1.51 +2 -2 + NTP_4_2_5P65 + + ntpdc/ntpdc-opts.c@1.52 +2 -2 + NTP_4_2_5P65 + + ntpdc/ntpdc-opts.h@1.52 +3 -3 + NTP_4_2_5P65 + + ntpdc/ntpdc-opts.texi@1.51 +1 -1 + NTP_4_2_5P65 + + ntpdc/ntpdc.1@1.51 +2 -2 + NTP_4_2_5P65 + + ntpq/ntpq-opts.c@1.52 +2 -2 + NTP_4_2_5P65 + + ntpq/ntpq-opts.h@1.52 +3 -3 + NTP_4_2_5P65 + + ntpq/ntpq-opts.texi@1.51 +1 -1 + NTP_4_2_5P65 + + ntpq/ntpq.1@1.51 +2 -2 + NTP_4_2_5P65 + + packageinfo.sh@1.68 +1 -1 + NTP_4_2_5P65 + + sntp/sntp-opts.c@1.52 +2 -2 + NTP_4_2_5P65 + + sntp/sntp-opts.h@1.52 +3 -3 + NTP_4_2_5P65 + + sntp/sntp-opts.texi@1.51 +1 -1 + NTP_4_2_5P65 + + sntp/sntp.1@1.51 +2 -2 + NTP_4_2_5P65 + + util/ntp-keygen-opts.c@1.53 +2 -2 + NTP_4_2_5P65 + + util/ntp-keygen-opts.h@1.53 +3 -3 + NTP_4_2_5P65 + + util/ntp-keygen-opts.texi@1.52 +1 -1 + NTP_4_2_5P65 + + util/ntp-keygen.1@1.52 +2 -2 + NTP_4_2_5P65 + +ChangeSet@1.1560, 2007-08-04 16:51:04-04:00, stenn@whimsy.udel.edu + [Bug 850] Fix the wander threshold parameter on the driftfile command + + ChangeLog@1.92 +1 -0 + [Bug 850] Fix the wander threshold parameter on the driftfile command + + ntpd/ntp_parser.c@1.16 +142 -152 + [Bug 850] Fix the wander threshold parameter on the driftfile command + + ntpd/ntp_parser.y@1.13 +1 -1 + [Bug 850] Fix the wander threshold parameter on the driftfile command + +ChangeSet@1.1559, 2007-07-30 07:45:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P64 + TAG: NTP_4_2_5P64 + + ntpd/ntpd-opts.c@1.51 +2 -2 + NTP_4_2_5P64 + + ntpd/ntpd-opts.h@1.51 +3 -3 + NTP_4_2_5P64 + + ntpd/ntpd-opts.texi@1.50 +2 -2 + NTP_4_2_5P64 + + ntpd/ntpd.1@1.50 +2 -2 + NTP_4_2_5P64 + + ntpdc/ntpdc-opts.c@1.51 +2 -2 + NTP_4_2_5P64 + + ntpdc/ntpdc-opts.h@1.51 +3 -3 + NTP_4_2_5P64 + + ntpdc/ntpdc-opts.texi@1.50 +2 -2 + NTP_4_2_5P64 + + ntpdc/ntpdc.1@1.50 +2 -2 + NTP_4_2_5P64 + + ntpq/ntpq-opts.c@1.51 +2 -2 + NTP_4_2_5P64 + + ntpq/ntpq-opts.h@1.51 +3 -3 + NTP_4_2_5P64 + + ntpq/ntpq-opts.texi@1.50 +2 -2 + NTP_4_2_5P64 + + ntpq/ntpq.1@1.50 +2 -2 + NTP_4_2_5P64 + + packageinfo.sh@1.67 +1 -1 + NTP_4_2_5P64 + + sntp/sntp-opts.c@1.51 +2 -2 + NTP_4_2_5P64 + + sntp/sntp-opts.h@1.51 +3 -3 + NTP_4_2_5P64 + + sntp/sntp-opts.texi@1.50 +1 -1 + NTP_4_2_5P64 + + sntp/sntp.1@1.50 +2 -2 + NTP_4_2_5P64 + + util/ntp-keygen-opts.c@1.52 +2 -2 + NTP_4_2_5P64 + + util/ntp-keygen-opts.h@1.52 +3 -3 + NTP_4_2_5P64 + + util/ntp-keygen-opts.texi@1.51 +2 -2 + NTP_4_2_5P64 + + util/ntp-keygen.1@1.51 +2 -2 + NTP_4_2_5P64 + +ChangeSet@1.1558, 2007-07-29 15:44:57-04:00, stenn@whimsy.udel.edu + ntp_peer.c, ChangeLog: + Set peer->srcadr before (not after) calling set_peerdstadr() + ntp_util.c, ChangeLog: + Leap file related cleanup from Dave Mills + ntp_io.c, ChangeLog: + Dead code cleanup - Coverity View 19 + + ChangeLog@1.91 +1 -0 + Dead code cleanup - Coverity View 19 + + ChangeLog@1.90 +1 -0 + Leap file related cleanup from Dave Mills + + ChangeLog@1.89 +1 -0 + Set peer->srcadr before (not after) calling set_peerdstadr() + + ntpd/ntp_io.c@1.259 +0 -13 + Dead code cleanup - Coverity View 19 + + ntpd/ntp_peer.c@1.105 +11 -15 + Set peer->srcadr before (not after) calling set_peerdstadr() + + ntpd/ntp_util.c@1.58 +21 -37 + Leap file related cleanup from Dave Mills + +ChangeSet@1.1557, 2007-07-29 07:44:44-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P63 + TAG: NTP_4_2_5P63 + + ntpd/ntpd-opts.c@1.50 +2 -2 + NTP_4_2_5P63 + + ntpd/ntpd-opts.h@1.50 +3 -3 + NTP_4_2_5P63 + + ntpd/ntpd-opts.texi@1.49 +2 -2 + NTP_4_2_5P63 + + ntpd/ntpd.1@1.49 +2 -2 + NTP_4_2_5P63 + + ntpdc/ntpdc-opts.c@1.50 +2 -2 + NTP_4_2_5P63 + + ntpdc/ntpdc-opts.h@1.50 +3 -3 + NTP_4_2_5P63 + + ntpdc/ntpdc-opts.texi@1.49 +2 -2 + NTP_4_2_5P63 + + ntpdc/ntpdc.1@1.49 +2 -2 + NTP_4_2_5P63 + + ntpq/ntpq-opts.c@1.50 +2 -2 + NTP_4_2_5P63 + + ntpq/ntpq-opts.h@1.50 +3 -3 + NTP_4_2_5P63 + + ntpq/ntpq-opts.texi@1.49 +2 -2 + NTP_4_2_5P63 + + ntpq/ntpq.1@1.49 +2 -2 + NTP_4_2_5P63 + + packageinfo.sh@1.66 +1 -1 + NTP_4_2_5P63 + + sntp/sntp-opts.c@1.50 +2 -2 + NTP_4_2_5P63 + + sntp/sntp-opts.h@1.50 +3 -3 + NTP_4_2_5P63 + + sntp/sntp-opts.texi@1.49 +1 -1 + NTP_4_2_5P63 + + sntp/sntp.1@1.49 +2 -2 + NTP_4_2_5P63 + + util/ntp-keygen-opts.c@1.51 +2 -2 + NTP_4_2_5P63 + + util/ntp-keygen-opts.h@1.51 +3 -3 + NTP_4_2_5P63 + + util/ntp-keygen-opts.texi@1.50 +2 -2 + NTP_4_2_5P63 + + util/ntp-keygen.1@1.50 +2 -2 + NTP_4_2_5P63 + +ChangeSet@1.1556, 2007-07-29 02:30:13-04:00, stenn@whimsy.udel.edu + Initialize offset in leap_file() - Coverity View 17 + + ChangeLog@1.88 +1 -0 + Initialize offset in leap_file() - Coverity View 17 + + ntpd/ntp_util.c@1.57 +2 -1 + Initialize offset in leap_file() - Coverity View 17 + +ChangeSet@1.1555, 2007-07-28 07:44:54-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P62 + TAG: NTP_4_2_5P62 + + ntpd/ntpd-opts.c@1.49 +2 -2 + NTP_4_2_5P62 + + ntpd/ntpd-opts.h@1.49 +3 -3 + NTP_4_2_5P62 + + ntpd/ntpd-opts.texi@1.48 +1 -1 + NTP_4_2_5P62 + + ntpd/ntpd.1@1.48 +2 -2 + NTP_4_2_5P62 + + ntpdc/ntpdc-opts.c@1.49 +2 -2 + NTP_4_2_5P62 + + ntpdc/ntpdc-opts.h@1.49 +3 -3 + NTP_4_2_5P62 + + ntpdc/ntpdc-opts.texi@1.48 +1 -1 + NTP_4_2_5P62 + + ntpdc/ntpdc.1@1.48 +2 -2 + NTP_4_2_5P62 + + ntpq/ntpq-opts.c@1.49 +2 -2 + NTP_4_2_5P62 + + ntpq/ntpq-opts.h@1.49 +3 -3 + NTP_4_2_5P62 + + ntpq/ntpq-opts.texi@1.48 +1 -1 + NTP_4_2_5P62 + + ntpq/ntpq.1@1.48 +2 -2 + NTP_4_2_5P62 + + packageinfo.sh@1.65 +1 -1 + NTP_4_2_5P62 + + sntp/sntp-opts.c@1.49 +2 -2 + NTP_4_2_5P62 + + sntp/sntp-opts.h@1.49 +3 -3 + NTP_4_2_5P62 + + sntp/sntp-opts.texi@1.48 +1 -1 + NTP_4_2_5P62 + + sntp/sntp.1@1.48 +2 -2 + NTP_4_2_5P62 + + util/ntp-keygen-opts.c@1.50 +2 -2 + NTP_4_2_5P62 + + util/ntp-keygen-opts.h@1.50 +3 -3 + NTP_4_2_5P62 + + util/ntp-keygen-opts.texi@1.49 +1 -1 + NTP_4_2_5P62 + + util/ntp-keygen.1@1.49 +2 -2 + NTP_4_2_5P62 + +ChangeSet@1.1554, 2007-07-28 02:22:13-04:00, stenn@whimsy.udel.edu + (ChangeLog entries for previous changeset) + + ChangeLog@1.87 +3 -0 + +ChangeSet@1.1553, 2007-07-27 23:47:45-04:00, stenn@whimsy.udel.edu + systime.c: + fuzz cleanup + ntp_loopfilter.c, ntp_proto.c: + Show more digits during some debug printfs. Use the correct packet stratum in KISS codes. + + libntp/systime.c@1.43 +2 -2 + fuzz cleanup + + ntpd/ntp_loopfilter.c@1.138 +1 -1 + Show more digits during some debug printfs. Use the correct packet stratum in KISS codes. + + ntpd/ntp_proto.c@1.259 +2 -2 + Show more digits during some debug printfs. Use the correct packet stratum in KISS codes. + +ChangeSet@1.1552, 2007-07-25 07:44:25-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P61 + TAG: NTP_4_2_5P61 + + ntpd/ntpd-opts.c@1.48 +2 -2 + NTP_4_2_5P61 + + ntpd/ntpd-opts.h@1.48 +3 -3 + NTP_4_2_5P61 + + ntpd/ntpd-opts.texi@1.47 +2 -2 + NTP_4_2_5P61 + + ntpd/ntpd.1@1.47 +2 -2 + NTP_4_2_5P61 + + ntpdc/ntpdc-opts.c@1.48 +2 -2 + NTP_4_2_5P61 + + ntpdc/ntpdc-opts.h@1.48 +3 -3 + NTP_4_2_5P61 + + ntpdc/ntpdc-opts.texi@1.47 +2 -2 + NTP_4_2_5P61 + + ntpdc/ntpdc.1@1.47 +2 -2 + NTP_4_2_5P61 + + ntpq/ntpq-opts.c@1.48 +2 -2 + NTP_4_2_5P61 + + ntpq/ntpq-opts.h@1.48 +3 -3 + NTP_4_2_5P61 + + ntpq/ntpq-opts.texi@1.47 +2 -2 + NTP_4_2_5P61 + + ntpq/ntpq.1@1.47 +2 -2 + NTP_4_2_5P61 + + packageinfo.sh@1.64 +1 -1 + NTP_4_2_5P61 + + sntp/sntp-opts.c@1.48 +2 -2 + NTP_4_2_5P61 + + sntp/sntp-opts.h@1.48 +3 -3 + NTP_4_2_5P61 + + sntp/sntp-opts.texi@1.47 +1 -1 + NTP_4_2_5P61 + + sntp/sntp.1@1.47 +2 -2 + NTP_4_2_5P61 + + util/ntp-keygen-opts.c@1.49 +2 -2 + NTP_4_2_5P61 + + util/ntp-keygen-opts.h@1.49 +3 -3 + NTP_4_2_5P61 + + util/ntp-keygen-opts.texi@1.48 +2 -2 + NTP_4_2_5P61 + + util/ntp-keygen.1@1.48 +2 -2 + NTP_4_2_5P61 + +ChangeSet@1.1551, 2007-07-24 15:01:03-04:00, stenn@whimsy.udel.edu + internal driftfile write control: drift_file_sw + + ChangeLog@1.86 +1 -0 + internal driftfile write control: drift_file_sw + + include/ntpd.h@1.107 +1 -0 + internal driftfile write control: drift_file_sw + + ntpd/ntp_config.c@1.161 +3 -1 + internal driftfile write control: drift_file_sw + + ntpd/ntp_loopfilter.c@1.137 +2 -1 + internal driftfile write control: drift_file_sw + + ntpd/ntp_util.c@1.56 +5 -3 + internal driftfile write control: drift_file_sw + +ChangeSet@1.1550, 2007-07-24 07:44:32-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P60 + TAG: NTP_4_2_5P60 + + ntpd/ntpd-opts.c@1.47 +2 -2 + NTP_4_2_5P60 + + ntpd/ntpd-opts.h@1.47 +3 -3 + NTP_4_2_5P60 + + ntpd/ntpd-opts.texi@1.46 +1 -1 + NTP_4_2_5P60 + + ntpd/ntpd.1@1.46 +2 -2 + NTP_4_2_5P60 + + ntpdc/ntpdc-opts.c@1.47 +2 -2 + NTP_4_2_5P60 + + ntpdc/ntpdc-opts.h@1.47 +3 -3 + NTP_4_2_5P60 + + ntpdc/ntpdc-opts.texi@1.46 +1 -1 + NTP_4_2_5P60 + + ntpdc/ntpdc.1@1.46 +2 -2 + NTP_4_2_5P60 + + ntpq/ntpq-opts.c@1.47 +2 -2 + NTP_4_2_5P60 + + ntpq/ntpq-opts.h@1.47 +3 -3 + NTP_4_2_5P60 + + ntpq/ntpq-opts.texi@1.46 +1 -1 + NTP_4_2_5P60 + + ntpq/ntpq.1@1.46 +2 -2 + NTP_4_2_5P60 + + packageinfo.sh@1.63 +1 -1 + NTP_4_2_5P60 + + sntp/sntp-opts.c@1.47 +2 -2 + NTP_4_2_5P60 + + sntp/sntp-opts.h@1.47 +3 -3 + NTP_4_2_5P60 + + sntp/sntp-opts.texi@1.46 +1 -1 + NTP_4_2_5P60 + + sntp/sntp.1@1.46 +2 -2 + NTP_4_2_5P60 + + util/ntp-keygen-opts.c@1.48 +2 -2 + NTP_4_2_5P60 + + util/ntp-keygen-opts.h@1.48 +3 -3 + NTP_4_2_5P60 + + util/ntp-keygen-opts.texi@1.47 +1 -1 + NTP_4_2_5P60 + + util/ntp-keygen.1@1.47 +2 -2 + NTP_4_2_5P60 + +ChangeSet@1.1549, 2007-07-24 01:52:29-04:00, stenn@whimsy.udel.edu + Implement the wander_threshold option for the driftfile config keyword + + ChangeLog@1.85 +1 -0 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_config.c@1.160 +3 -5 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_parser.c@1.15 +321 -319 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_parser.h@1.7 +1 -1 + Implement the wander_threshold option for the driftfile config keyword + + ntpd/ntp_parser.y@1.12 +207 -206 + Implement the wander_threshold option for the driftfile config keyword + +ChangeSet@1.1548, 2007-07-24 01:32:19-04:00, stenn@whimsy.udel.edu + c++ // comments are not allowed. + + ChangeLog@1.84 +1 -0 + c++ // comments are not allowed. + + ntpd/ntp_control.c@1.97 +449 -445 + c++ // comments are not allowed. + +ChangeSet@1.1547, 2007-07-23 07:45:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P59 + TAG: NTP_4_2_5P59 + + ntpd/ntpd-opts.c@1.46 +2 -2 + NTP_4_2_5P59 + + ntpd/ntpd-opts.h@1.46 +3 -3 + NTP_4_2_5P59 + + ntpd/ntpd-opts.texi@1.45 +2 -2 + NTP_4_2_5P59 + + ntpd/ntpd.1@1.45 +2 -2 + NTP_4_2_5P59 + + ntpdc/ntpdc-opts.c@1.46 +2 -2 + NTP_4_2_5P59 + + ntpdc/ntpdc-opts.h@1.46 +3 -3 + NTP_4_2_5P59 + + ntpdc/ntpdc-opts.texi@1.45 +2 -2 + NTP_4_2_5P59 + + ntpdc/ntpdc.1@1.45 +2 -2 + NTP_4_2_5P59 + + ntpq/ntpq-opts.c@1.46 +2 -2 + NTP_4_2_5P59 + + ntpq/ntpq-opts.h@1.46 +3 -3 + NTP_4_2_5P59 + + ntpq/ntpq-opts.texi@1.45 +2 -2 + NTP_4_2_5P59 + + ntpq/ntpq.1@1.45 +2 -2 + NTP_4_2_5P59 + + packageinfo.sh@1.62 +1 -1 + NTP_4_2_5P59 + + sntp/sntp-opts.c@1.46 +2 -2 + NTP_4_2_5P59 + + sntp/sntp-opts.h@1.46 +3 -3 + NTP_4_2_5P59 + + sntp/sntp-opts.texi@1.45 +1 -1 + NTP_4_2_5P59 + + sntp/sntp.1@1.45 +2 -2 + NTP_4_2_5P59 + + util/ntp-keygen-opts.c@1.47 +2 -2 + NTP_4_2_5P59 + + util/ntp-keygen-opts.h@1.47 +3 -3 + NTP_4_2_5P59 + + util/ntp-keygen-opts.texi@1.46 +2 -2 + NTP_4_2_5P59 + + util/ntp-keygen.1@1.46 +2 -2 + NTP_4_2_5P59 + +ChangeSet@1.1541.1.1, 2007-07-23 01:34:01-04:00, stenn@whimsy.udel.edu + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ChangeLog@1.81.1.1 +2 -0 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + html/confopt.html@1.37 +2 -0 + Documentation fixes from Dave Mills + + html/drivers/driver6.html@1.25 +4 -5 + Documentation fixes from Dave Mills + + html/index.html@1.33 +2 -2 + Documentation fixes from Dave Mills + + html/miscopt.html@1.36 +3 -13 + Documentation fixes from Dave Mills + + html/ntpd.html@1.40 +28 -20 + Documentation fixes from Dave Mills + + html/ntpdc.html@1.28 +3 -2 + Documentation fixes from Dave Mills + + html/scripts/links7.txt@1.3 +4 -1 + Documentation fixes from Dave Mills + + include/ntp.h@1.134 +12 -1 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + include/ntp_control.h@1.31 +21 -19 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + include/ntp_crypto.h@1.40 +3 -3 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + include/ntpd.h@1.106 +10 -8 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup + + ntpd/ntp_config.c@1.159 +8 -7 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_control.c@1.96 +66 -50 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_crypto.c@1.112 +153 -259 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_loopfilter.c@1.136 +6 -9 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_peer.c@1.104 +70 -71 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_proto.c@1.258 +222 -176 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_timer.c@1.39 +51 -40 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/ntp_util.c@1.55 +36 -15 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + + ntpd/refclock_acts.c@1.30 +1 -1 + Changes from Dave Mills: in/out-bound data rates, leapsecond cleanup, driftfile write cleanup, packet buffer length checks + +ChangeSet@1.1545, 2007-07-18 15:09:31-04:00, mayer@pogo.udel.edu + Undo bug #629 fixes as they cause more problems than were being solved + + ChangeLog@1.82 +1 -0 + Undo bug #629 fixes as they cause more problems than were being solved + +ChangeSet@1.1544, 2007-07-18 15:03:37-04:00, mayer@pogo.udel.edu + Undo bug #629 fixes as they cause more problems than were being solved + + ntpd/ntp_io.c@1.258 +1 -8 + Undo bug #629 fixes as they cause more problems than were eing solved + +ChangeSet@1.1543, 2007-07-18 13:57:51-04:00, mayer@pogo.udel.edu + Undo bug #629 fixes as they cause more problems than were being solved + + ports/winnt/ntpd/ntp_iocompletionport.c@1.32 +2 -4 + Undo bug #629 fixes as they cause more problems than were being solved + +ChangeSet@1.1529.2.12, 2007-07-18 13:53:24-04:00, mayer@pogo.udel.edu + Undo bug #629 fixes as they cause more problems than were eing solved + + ntpd/ntp_io.c@1.257 +1 -8 + Undo bug #629 fixes as they cause more problems than were being solved + + ports/winnt/ntpd/ntp_iocompletionport.c@1.31 +0 -15 + Undo bug #629 fixes as they cause more problems than were being solved + +ChangeSet@1.1541, 2007-06-30 07:46:53-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P58 + TAG: NTP_4_2_5P58 + + ntpd/ntpd-opts.c@1.45 +2 -2 + NTP_4_2_5P58 + + ntpd/ntpd-opts.h@1.45 +3 -3 + NTP_4_2_5P58 + + ntpd/ntpd-opts.texi@1.44 +1 -1 + NTP_4_2_5P58 + + ntpd/ntpd.1@1.44 +2 -2 + NTP_4_2_5P58 + + ntpdc/ntpdc-opts.c@1.45 +2 -2 + NTP_4_2_5P58 + + ntpdc/ntpdc-opts.h@1.45 +3 -3 + NTP_4_2_5P58 + + ntpdc/ntpdc-opts.texi@1.44 +1 -1 + NTP_4_2_5P58 + + ntpdc/ntpdc.1@1.44 +2 -2 + NTP_4_2_5P58 + + ntpq/ntpq-opts.c@1.45 +2 -2 + NTP_4_2_5P58 + + ntpq/ntpq-opts.h@1.45 +3 -3 + NTP_4_2_5P58 + + ntpq/ntpq-opts.texi@1.44 +1 -1 + NTP_4_2_5P58 + + ntpq/ntpq.1@1.44 +2 -2 + NTP_4_2_5P58 + + packageinfo.sh@1.61 +1 -1 + NTP_4_2_5P58 + + sntp/sntp-opts.c@1.45 +2 -2 + NTP_4_2_5P58 + + sntp/sntp-opts.h@1.45 +3 -3 + NTP_4_2_5P58 + + sntp/sntp-opts.texi@1.44 +1 -1 + NTP_4_2_5P58 + + sntp/sntp.1@1.44 +2 -2 + NTP_4_2_5P58 + + util/ntp-keygen-opts.c@1.46 +2 -2 + NTP_4_2_5P58 + + util/ntp-keygen-opts.h@1.46 +3 -3 + NTP_4_2_5P58 + + util/ntp-keygen-opts.texi@1.45 +1 -1 + NTP_4_2_5P58 + + util/ntp-keygen.1@1.45 +2 -2 + NTP_4_2_5P58 + +ChangeSet@1.1540, 2007-06-29 21:15:27+00:00, stenn@ntp1.isc.org + format cleanup + + ChangeLog@1.81 +37 -39 + format cleanup + +ChangeSet@1.1539, 2007-06-29 16:23:16-04:00, stenn@whimsy.udel.edu + cleanup + + NEWS@1.100 +1 -0 + cleanup + +ChangeSet@1.1436.1.66, 2007-06-29 15:46:00-04:00, stenn@deacon.udel.edu + NTP_4_2_4P3 + TAG: NTP_4_2_4P3 + + ntpd/ntpd-opts.c@1.50.10.1 +2 -2 + NTP_4_2_4P3 + + ntpd/ntpd-opts.h@1.50.10.1 +3 -3 + NTP_4_2_4P3 + + ntpd/ntpd-opts.texi@1.49.10.1 +2 -2 + NTP_4_2_4P3 + + ntpd/ntpd.1@1.48.10.1 +2 -2 + NTP_4_2_4P3 + + ntpd/ntpdsim-opts.c@1.50.10.1 +2 -2 + NTP_4_2_4P3 + + ntpd/ntpdsim-opts.h@1.50.10.1 +3 -3 + NTP_4_2_4P3 + + ntpd/ntpdsim-opts.texi@1.48.10.1 +1 -1 + NTP_4_2_4P3 + + ntpd/ntpdsim.1@1.48.10.1 +2 -2 + NTP_4_2_4P3 + + ntpdc/ntpdc-opts.c@1.50.10.1 +2 -2 + NTP_4_2_4P3 + + ntpdc/ntpdc-opts.h@1.50.10.1 +3 -3 + NTP_4_2_4P3 + + ntpdc/ntpdc-opts.texi@1.48.10.1 +2 -2 + NTP_4_2_4P3 + + ntpdc/ntpdc.1@1.48.10.1 +2 -2 + NTP_4_2_4P3 + + ntpq/ntpq-opts.c@1.52.10.1 +2 -2 + NTP_4_2_4P3 + + ntpq/ntpq-opts.h@1.52.10.1 +3 -3 + NTP_4_2_4P3 + + ntpq/ntpq-opts.texi@1.49.10.1 +2 -2 + NTP_4_2_4P3 + + ntpq/ntpq.1@1.48.10.1 +2 -2 + NTP_4_2_4P3 + + packageinfo.sh@1.65.16.2 +2 -2 + NTP_4_2_4P3 + + sntp/sntp-opts.c@1.49.10.1 +2 -2 + NTP_4_2_4P3 + + sntp/sntp-opts.h@1.49.10.1 +3 -3 + NTP_4_2_4P3 + + sntp/sntp-opts.texi@1.46.10.1 +1 -1 + NTP_4_2_4P3 + + sntp/sntp.1@1.49.10.1 +2 -2 + NTP_4_2_4P3 + + util/ntp-keygen-opts.c@1.49.10.1 +2 -2 + NTP_4_2_4P3 + + util/ntp-keygen-opts.h@1.49.10.1 +3 -3 + NTP_4_2_4P3 + + util/ntp-keygen-opts.texi@1.47.10.1 +2 -2 + NTP_4_2_4P3 + + util/ntp-keygen.1@1.47.10.1 +2 -2 + NTP_4_2_4P3 + +ChangeSet@1.1436.1.65, 2007-06-29 15:31:21-04:00, stenn@deacon.udel.edu + Release 4.2.4p3 + + ChangeLog@1.1.1.23 +1 -1 + Release 4.2.4p3 + + NEWS@1.86.1.11 +1 -1 + Release 4.2.4p3 + + packageinfo.sh@1.65.16.1 +1 -1 + Release 4.2.4p3 + +ChangeSet@1.1436.1.64, 2007-06-29 19:03:39+00:00, stenn@ntp1.isc.org + Cosmetic reformatting + + ChangeLog@1.1.1.22 +70 -16 + Cosmetic reformatting + + NEWS@1.86.1.10 +4 -0 + Cosmetic reformatting + +ChangeSet@1.1537, 2007-06-28 07:47:21-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P57 + TAG: NTP_4_2_5P57 + + ntpd/ntpd-opts.c@1.44 +2 -2 + NTP_4_2_5P57 + + ntpd/ntpd-opts.h@1.44 +3 -3 + NTP_4_2_5P57 + + ntpd/ntpd-opts.texi@1.43 +1 -1 + NTP_4_2_5P57 + + ntpd/ntpd.1@1.43 +2 -2 + NTP_4_2_5P57 + + ntpdc/ntpdc-opts.c@1.44 +2 -2 + NTP_4_2_5P57 + + ntpdc/ntpdc-opts.h@1.44 +3 -3 + NTP_4_2_5P57 + + ntpdc/ntpdc-opts.texi@1.43 +1 -1 + NTP_4_2_5P57 + + ntpdc/ntpdc.1@1.43 +2 -2 + NTP_4_2_5P57 + + ntpq/ntpq-opts.c@1.44 +2 -2 + NTP_4_2_5P57 + + ntpq/ntpq-opts.h@1.44 +3 -3 + NTP_4_2_5P57 + + ntpq/ntpq-opts.texi@1.43 +1 -1 + NTP_4_2_5P57 + + ntpq/ntpq.1@1.43 +2 -2 + NTP_4_2_5P57 + + packageinfo.sh@1.60 +1 -1 + NTP_4_2_5P57 + + sntp/sntp-opts.c@1.44 +2 -2 + NTP_4_2_5P57 + + sntp/sntp-opts.h@1.44 +3 -3 + NTP_4_2_5P57 + + sntp/sntp-opts.texi@1.43 +1 -1 + NTP_4_2_5P57 + + sntp/sntp.1@1.43 +2 -2 + NTP_4_2_5P57 + + util/ntp-keygen-opts.c@1.45 +2 -2 + NTP_4_2_5P57 + + util/ntp-keygen-opts.h@1.45 +3 -3 + NTP_4_2_5P57 + + util/ntp-keygen-opts.texi@1.44 +1 -1 + NTP_4_2_5P57 + + util/ntp-keygen.1@1.44 +2 -2 + NTP_4_2_5P57 + +ChangeSet@1.1535, 2007-06-28 04:11:15-04:00, stenn@whimsy.udel.edu + More assertion checks and malloc()->emalloc(), courtesy of Calysto + + ChangeLog@1.78 +1 -0 + More assertion checks and malloc()->emalloc(), courtesy of Calysto + + ntpd/ntp_crypto.c@1.111 +6 -1 + More assertion checks and malloc()->emalloc(), courtesy of Calysto + + ntpd/ntp_data_structures.c@1.5 +2 -2 + More assertion checks and malloc()->emalloc(), courtesy of Calysto + +ChangeSet@1.1534, 2007-06-28 04:05:43-04:00, stenn@whimsy.udel.edu + typo + + ChangeLog@1.77 +1 -1 + typo + +ChangeSet@1.1533, 2007-06-27 09:48:59-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P56 + TAG: NTP_4_2_5P56 + + ntpd/ntpd-opts.c@1.43 +2 -2 + NTP_4_2_5P56 + + ntpd/ntpd-opts.h@1.43 +3 -3 + NTP_4_2_5P56 + + ntpd/ntpd-opts.texi@1.42 +1 -1 + NTP_4_2_5P56 + + ntpd/ntpd.1@1.42 +2 -2 + NTP_4_2_5P56 + + ntpdc/ntpdc-opts.c@1.43 +2 -2 + NTP_4_2_5P56 + + ntpdc/ntpdc-opts.h@1.43 +3 -3 + NTP_4_2_5P56 + + ntpdc/ntpdc-opts.texi@1.42 +1 -1 + NTP_4_2_5P56 + + ntpdc/ntpdc.1@1.42 +2 -2 + NTP_4_2_5P56 + + ntpq/ntpq-opts.c@1.43 +2 -2 + NTP_4_2_5P56 + + ntpq/ntpq-opts.h@1.43 +3 -3 + NTP_4_2_5P56 + + ntpq/ntpq-opts.texi@1.42 +1 -1 + NTP_4_2_5P56 + + ntpq/ntpq.1@1.42 +2 -2 + NTP_4_2_5P56 + + packageinfo.sh@1.59 +1 -1 + NTP_4_2_5P56 + + sntp/sntp-opts.c@1.43 +2 -2 + NTP_4_2_5P56 + + sntp/sntp-opts.h@1.43 +3 -3 + NTP_4_2_5P56 + + sntp/sntp-opts.texi@1.42 +1 -1 + NTP_4_2_5P56 + + sntp/sntp.1@1.42 +2 -2 + NTP_4_2_5P56 + + util/ntp-keygen-opts.c@1.44 +2 -2 + NTP_4_2_5P56 + + util/ntp-keygen-opts.h@1.44 +3 -3 + NTP_4_2_5P56 + + util/ntp-keygen-opts.texi@1.43 +1 -1 + NTP_4_2_5P56 + + util/ntp-keygen.1@1.43 +2 -2 + NTP_4_2_5P56 + +ChangeSet@1.1436.1.63, 2007-06-27 07:46:44-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P3_RC1 + TAG: NTP_4_2_4P3_RC1 + + ntpd/ntpd-opts.c@1.50.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpd-opts.h@1.50.9.1 +3 -3 + NTP_4_2_4P3_RC1 + + ntpd/ntpd-opts.texi@1.49.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpd.1@1.48.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim-opts.c@1.50.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim-opts.h@1.50.9.1 +3 -3 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim-opts.texi@1.48.9.1 +1 -1 + NTP_4_2_4P3_RC1 + + ntpd/ntpdsim.1@1.48.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc-opts.c@1.50.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc-opts.h@1.50.9.1 +3 -3 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc-opts.texi@1.48.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpdc/ntpdc.1@1.48.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpq/ntpq-opts.c@1.52.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpq/ntpq-opts.h@1.52.9.1 +3 -3 + NTP_4_2_4P3_RC1 + + ntpq/ntpq-opts.texi@1.49.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + ntpq/ntpq.1@1.48.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + packageinfo.sh@1.65.15.2 +2 -2 + NTP_4_2_4P3_RC1 + + sntp/sntp-opts.c@1.49.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + sntp/sntp-opts.h@1.49.9.1 +3 -3 + NTP_4_2_4P3_RC1 + + sntp/sntp-opts.texi@1.46.9.1 +1 -1 + NTP_4_2_4P3_RC1 + + sntp/sntp.1@1.49.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + util/ntp-keygen-opts.c@1.49.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + util/ntp-keygen-opts.h@1.49.9.1 +3 -3 + NTP_4_2_4P3_RC1 + + util/ntp-keygen-opts.texi@1.47.9.1 +2 -2 + NTP_4_2_4P3_RC1 + + util/ntp-keygen.1@1.47.9.1 +2 -2 + NTP_4_2_4P3_RC1 + +ChangeSet@1.1529.3.4, 2007-06-27 02:21:23-04:00, stenn@whimsy.udel.edu + [Bug 604] ntpd regularly dies on linux/alpha + + ChangeLog@1.73.3.3 +1 -0 + [Bug 604] ntpd regularly dies on linux/alpha + + ntpd/ntp_proto.c@1.255.1.2 +2 -0 + [Bug 604] ntpd regularly dies on linux/alpha + +ChangeSet@1.1529.3.3, 2007-06-27 02:15:24-04:00, stenn@whimsy.udel.edu + More leapsecond table file fixes from Dave Mills + + ChangeLog@1.73.3.2 +1 -1 + More leapsecond table file fixes from Dave Mills + + include/ntpd.h@1.105 +1 -0 + More leapsecond table file fixes from Dave Mills + + ntpd/ntp_crypto.c@1.110 +18 -6 + More leapsecond table file fixes from Dave Mills + + ntpd/ntp_proto.c@1.255.1.1 +41 -37 + More leapsecond table file fixes from Dave Mills + + ntpd/ntp_util.c@1.54 +16 -6 + More leapsecond table file fixes from Dave Mills + +ChangeSet@1.1529.3.2, 2007-06-27 02:06:19-04:00, stenn@whimsy.udel.edu + Notes for release + + NEWS@1.95.1.1 +2 -0 + Notes for release + +ChangeSet@1.1436.1.62, 2007-06-27 01:42:30-04:00, stenn@whimsy.udel.edu + First RC for 4.2.4p3 + + ChangeLog@1.1.1.21 +2 -1 + First RC for 4.2.4p3 + + NEWS@1.86.1.9 +8 -0 + First RC for 4.2.4p3 + + packageinfo.sh@1.65.15.1 +1 -1 + First RC for 4.2.4p3 + +ChangeSet@1.1529.3.1, 2007-06-26 22:43:22-04:00, stenn@whimsy.udel.edu + [Bug 858] recent leapfile changes broke non-OpenSSL builds. + + ChangeLog@1.73.3.1 +4 -2 + [Bug 858] recent leapfile changes broke non-OpenSSL builds. + + ntpd/ntp_control.c@1.95 +2 -1 + [Bug 858] recent leapfile changes broke non-OpenSSL builds. + +ChangeSet@1.1529.2.8, 2007-06-23 09:19:06-04:00, mayer@pogo.udel.edu + Added Bug #863 + + ChangeLog@1.73.2.2 +2 -0 + Added Bug #863 + +ChangeSet@1.1523.1.2, 2007-06-23 08:50:46-04:00, mayer@pogo.udel.edu + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/include/ntp_iocompletionport.h@1.12.1.1 +3 -0 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntp_iocompletionport.c@1.29 +15 -1 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntservice.c@1.8.1.1 +9 -5 + Bug #863 Unable to stop ntpd because the handle index changed + +ChangeSet@1.1436.1.61, 2007-06-23 08:47:07-04:00, mayer@pogo.udel.edu + Added Bug #863 + + ChangeLog@1.1.1.20 +2 -0 + Added Bug #863 + +ChangeSet@1.1436.5.1, 2007-06-23 08:42:58-04:00, mayer@pogo.udel.edu + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/include/ntp_iocompletionport.h@1.13 +3 -0 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.2 +15 -1 + Bug #863 Unable to stop ntpd because the handle index changed + + ports/winnt/ntpd/ntservice.c@1.9 +9 -5 + Bug #863 Unable to stop ntpd because the handle index changed + +ChangeSet@1.1529.2.6, 2007-06-23 07:42:56-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P55 + TAG: NTP_4_2_5P55 + + ntpd/ntpd-opts.c@1.42 +2 -2 + NTP_4_2_5P55 + + ntpd/ntpd-opts.h@1.42 +3 -3 + NTP_4_2_5P55 + + ntpd/ntpd-opts.texi@1.41 +1 -1 + NTP_4_2_5P55 + + ntpd/ntpd.1@1.41 +2 -2 + NTP_4_2_5P55 + + ntpdc/ntpdc-opts.c@1.42 +2 -2 + NTP_4_2_5P55 + + ntpdc/ntpdc-opts.h@1.42 +3 -3 + NTP_4_2_5P55 + + ntpdc/ntpdc-opts.texi@1.41 +1 -1 + NTP_4_2_5P55 + + ntpdc/ntpdc.1@1.41 +2 -2 + NTP_4_2_5P55 + + ntpq/ntpq-opts.c@1.42 +2 -2 + NTP_4_2_5P55 + + ntpq/ntpq-opts.h@1.42 +3 -3 + NTP_4_2_5P55 + + ntpq/ntpq-opts.texi@1.41 +1 -1 + NTP_4_2_5P55 + + ntpq/ntpq.1@1.41 +2 -2 + NTP_4_2_5P55 + + packageinfo.sh@1.58 +1 -1 + NTP_4_2_5P55 + + sntp/sntp-opts.c@1.42 +2 -2 + NTP_4_2_5P55 + + sntp/sntp-opts.h@1.42 +3 -3 + NTP_4_2_5P55 + + sntp/sntp-opts.texi@1.41 +1 -1 + NTP_4_2_5P55 + + sntp/sntp.1@1.41 +2 -2 + NTP_4_2_5P55 + + util/ntp-keygen-opts.c@1.43 +2 -2 + NTP_4_2_5P55 + + util/ntp-keygen-opts.h@1.43 +3 -3 + NTP_4_2_5P55 + + util/ntp-keygen-opts.texi@1.42 +1 -1 + NTP_4_2_5P55 + + util/ntp-keygen.1@1.42 +2 -2 + NTP_4_2_5P55 + +ChangeSet@1.1529.2.5, 2007-06-23 01:03:58-04:00, stenn@whimsy.udel.edu + Add more assertions (Calypso) + + util/ntp-keygen.c@1.42 +57 -1 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.4, 2007-06-23 00:38:42-04:00, stenn@whimsy.udel.edu + Add more assertions (Calypso) + + util/ntp-keygen.c@1.41 +11 -8 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.3, 2007-06-23 00:30:39-04:00, stenn@whimsy.udel.edu + Add more assertions (Calypso) + + libntp/caljulian.c@1.7 +3 -0 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.2, 2007-06-23 00:18:26-04:00, stenn@whimsy.udel.edu + Add more assertions (Calypso) + + ntpd/ntp_crypto.c@1.109 +4 -1 + Add more assertions (Calypso) + +ChangeSet@1.1529.2.1, 2007-06-22 23:51:03-04:00, stenn@whimsy.udel.edu + Use emalloc() instead of malloc() in refclock_datum.c (Calypso). + + ChangeLog@1.73.2.1 +1 -0 + Use emalloc() instead of malloc() in refclock_datum.c (Calypso). + + ntpd/refclock_datum.c@1.11 +2 -2 + Use emalloc() instead of malloc() in refclock_datum.c (Calypso). + +ChangeSet@1.1529.1.5, 2007-06-22 12:52:24-04:00, utterback@pogo.udel.edu + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + ChangeLog@1.73.1.3 +1 -0 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + configure.ac@1.407 +7 -1 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + ntpd/Makefile.am@1.63 +2 -2 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + + ntpd/ntp_proto.c@1.256 +19 -0 + [Bug 864] Place ntpd service in maintenance mode if using SMF on Solaris + +ChangeSet@1.1529.1.4, 2007-06-22 07:43:48-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P54 + TAG: NTP_4_2_5P54 + + ntpd/ntpd-opts.c@1.41 +2 -2 + NTP_4_2_5P54 + + ntpd/ntpd-opts.h@1.41 +3 -3 + NTP_4_2_5P54 + + ntpd/ntpd-opts.texi@1.40 +2 -2 + NTP_4_2_5P54 + + ntpd/ntpd.1@1.40 +2 -2 + NTP_4_2_5P54 + + ntpdc/ntpdc-opts.c@1.41 +2 -2 + NTP_4_2_5P54 + + ntpdc/ntpdc-opts.h@1.41 +3 -3 + NTP_4_2_5P54 + + ntpdc/ntpdc-opts.texi@1.40 +2 -2 + NTP_4_2_5P54 + + ntpdc/ntpdc.1@1.40 +2 -2 + NTP_4_2_5P54 + + ntpq/ntpq-opts.c@1.41 +2 -2 + NTP_4_2_5P54 + + ntpq/ntpq-opts.h@1.41 +3 -3 + NTP_4_2_5P54 + + ntpq/ntpq-opts.texi@1.40 +2 -2 + NTP_4_2_5P54 + + ntpq/ntpq.1@1.40 +2 -2 + NTP_4_2_5P54 + + packageinfo.sh@1.57 +1 -1 + NTP_4_2_5P54 + + sntp/sntp-opts.c@1.41 +2 -2 + NTP_4_2_5P54 + + sntp/sntp-opts.h@1.41 +3 -3 + NTP_4_2_5P54 + + sntp/sntp-opts.texi@1.40 +1 -1 + NTP_4_2_5P54 + + sntp/sntp.1@1.40 +2 -2 + NTP_4_2_5P54 + + util/ntp-keygen-opts.c@1.42 +2 -2 + NTP_4_2_5P54 + + util/ntp-keygen-opts.h@1.42 +3 -3 + NTP_4_2_5P54 + + util/ntp-keygen-opts.texi@1.41 +2 -2 + NTP_4_2_5P54 + + util/ntp-keygen.1@1.41 +2 -2 + NTP_4_2_5P54 + +ChangeSet@1.1529.1.3, 2007-06-22 02:11:30-04:00, stenn@deacon.udel.edu + Leapsecond file support + + ChangeLog@1.73.1.2 +2 -2 + Leapsecond file support + + include/ntp.h@1.133 +1 -0 + Leapsecond file support + + ntpd/ntp_config.c@1.156.1.2 +6 -1 + Leapsecond file support + + ntpd/ntp_config.c@1.156.1.1 +1 -0 + More leapsecond fixes from Dave Mills + + ntpd/ntp_control.c@1.94 +3 -4 + More leapsecond fixes from Dave Mills + + ntpd/ntp_parser.c@1.14 +684 -675 + More leapsecond fixes from Dave Mills + + ntpd/ntp_parser.h@1.6 +92 -91 + More leapsecond fixes from Dave Mills + + ntpd/ntp_parser.y@1.11 +3 -0 + More leapsecond fixes from Dave Mills + + ntpd/ntp_proto.c@1.255 +65 -68 + More leapsecond fixes from Dave Mills + + ntpd/ntp_timer.c@1.38 +20 -7 + More leapsecond fixes from Dave Mills + + ntpd/ntp_util.c@1.53 +11 -1 + Leapsecond file support + + ntpd/ntp_util.c@1.52 +44 -43 + More leapsecond fixes from Dave Mills + +ChangeSet@1.1529.1.2, 2007-06-22 01:17:17-04:00, stenn@deacon.udel.edu + Start using 'design by contract' assertions + + ntpd/ntp_io.c@1.254.1.1 +3 -0 + Start using 'design by contract' assertions + +ChangeSet@1.1529.1.1, 2007-06-22 01:01:28-04:00, stenn@deacon.udel.edu + Start using 'design by contract' assertions + + ChangeLog@1.73.1.1 +1 -0 + Start using 'design by contract' assertions + + include/Makefile.am@1.28 +1 -0 + Start using 'design by contract' assertions + + include/ntp_assert.h@1.1 +15 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/ntp_assert.h + + include/ntp_assert.h@1.0 +0 -0 + + libntp/atolfp.c@1.3 +3 -0 + Start using 'design by contract' assertions + + libntp/prettydate.c@1.6 +2 -0 + Start using 'design by contract' assertions + +ChangeSet@1.1530, 2007-06-21 09:10:39-04:00, neal@pogo.udel.edu + ChangeLog, ntp_config.c: + [Bug 862] includefile nesting; preserve phonelist on reconfig. + ntp_scanner.h: + [Bug 862] includefile nesting. + + ChangeLog@1.74 +1 -0 + [Bug 862] includefile nesting; preserve phonelist on reconfig. + + ntpd/ntp_config.c@1.157 +3 -2 + [Bug 862] includefile nesting; preserve phonelist on reconfig. + + ntpd/ntp_scanner.h@1.3 +1 -1 + [Bug 862] includefile nesting. + +ChangeSet@1.1529, 2007-06-20 09:18:36-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P53 + TAG: NTP_4_2_5P53 + + ntpd/ntpd-opts.c@1.40 +2 -2 + NTP_4_2_5P53 + + ntpd/ntpd-opts.h@1.40 +3 -3 + NTP_4_2_5P53 + + ntpd/ntpd-opts.texi@1.39 +2 -2 + NTP_4_2_5P53 + + ntpd/ntpd.1@1.39 +2 -2 + NTP_4_2_5P53 + + ntpdc/ntpdc-opts.c@1.40 +2 -2 + NTP_4_2_5P53 + + ntpdc/ntpdc-opts.h@1.40 +3 -3 + NTP_4_2_5P53 + + ntpdc/ntpdc-opts.texi@1.39 +2 -2 + NTP_4_2_5P53 + + ntpdc/ntpdc.1@1.39 +2 -2 + NTP_4_2_5P53 + + ntpq/ntpq-opts.c@1.40 +2 -2 + NTP_4_2_5P53 + + ntpq/ntpq-opts.h@1.40 +3 -3 + NTP_4_2_5P53 + + ntpq/ntpq-opts.texi@1.39 +2 -2 + NTP_4_2_5P53 + + ntpq/ntpq.1@1.39 +2 -2 + NTP_4_2_5P53 + + packageinfo.sh@1.56 +1 -1 + NTP_4_2_5P53 + + sntp/sntp-opts.c@1.40 +2 -2 + NTP_4_2_5P53 + + sntp/sntp-opts.h@1.40 +3 -3 + NTP_4_2_5P53 + + sntp/sntp-opts.texi@1.39 +1 -1 + NTP_4_2_5P53 + + sntp/sntp.1@1.39 +2 -2 + NTP_4_2_5P53 + + util/ntp-keygen-opts.c@1.41 +2 -2 + NTP_4_2_5P53 + + util/ntp-keygen-opts.h@1.41 +3 -3 + NTP_4_2_5P53 + + util/ntp-keygen-opts.texi@1.40 +2 -2 + NTP_4_2_5P53 + + util/ntp-keygen.1@1.40 +2 -2 + NTP_4_2_5P53 + +ChangeSet@1.1436.1.59, 2007-06-20 07:45:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P2 + TAG: NTP_4_2_4P2 + + ntpd/ntpd-opts.c@1.50.8.1 +2 -2 + NTP_4_2_4P2 + + ntpd/ntpd-opts.h@1.50.8.1 +3 -3 + NTP_4_2_4P2 + + ntpd/ntpd-opts.texi@1.49.8.1 +4 -4 + NTP_4_2_4P2 + + ntpd/ntpd.1@1.48.8.1 +2 -2 + NTP_4_2_4P2 + + ntpd/ntpdsim-opts.c@1.50.8.1 +2 -2 + NTP_4_2_4P2 + + ntpd/ntpdsim-opts.h@1.50.8.1 +3 -3 + NTP_4_2_4P2 + + ntpd/ntpdsim-opts.texi@1.48.8.1 +1 -1 + NTP_4_2_4P2 + + ntpd/ntpdsim.1@1.48.8.1 +2 -2 + NTP_4_2_4P2 + + ntpdc/ntpdc-opts.c@1.50.8.1 +2 -2 + NTP_4_2_4P2 + + ntpdc/ntpdc-opts.h@1.50.8.1 +3 -3 + NTP_4_2_4P2 + + ntpdc/ntpdc-opts.texi@1.48.8.1 +2 -2 + NTP_4_2_4P2 + + ntpdc/ntpdc.1@1.48.8.1 +2 -2 + NTP_4_2_4P2 + + ntpq/ntpq-opts.c@1.52.8.1 +2 -2 + NTP_4_2_4P2 + + ntpq/ntpq-opts.h@1.52.8.1 +3 -3 + NTP_4_2_4P2 + + ntpq/ntpq-opts.texi@1.49.8.1 +2 -2 + NTP_4_2_4P2 + + ntpq/ntpq.1@1.48.8.1 +2 -2 + NTP_4_2_4P2 + + packageinfo.sh@1.65.14.2 +2 -2 + NTP_4_2_4P2 + + sntp/sntp-opts.c@1.49.8.1 +2 -2 + NTP_4_2_4P2 + + sntp/sntp-opts.h@1.49.8.1 +3 -3 + NTP_4_2_4P2 + + sntp/sntp-opts.texi@1.46.8.1 +1 -1 + NTP_4_2_4P2 + + sntp/sntp.1@1.49.8.1 +2 -2 + NTP_4_2_4P2 + + util/ntp-keygen-opts.c@1.49.8.1 +2 -2 + NTP_4_2_4P2 + + util/ntp-keygen-opts.h@1.49.8.1 +3 -3 + NTP_4_2_4P2 + + util/ntp-keygen-opts.texi@1.47.8.1 +2 -2 + NTP_4_2_4P2 + + util/ntp-keygen.1@1.47.8.1 +2 -2 + NTP_4_2_4P2 + +ChangeSet@1.1436.1.58, 2007-06-20 04:07:34-04:00, stenn@deacon.udel.edu + 4.2.4p2 + + ChangeLog@1.1.1.19 +1 -0 + 4.2.4p2 + + NEWS@1.86.1.8 +8 -13 + 4.2.4p2 + + packageinfo.sh@1.65.14.1 +1 -1 + 4.2.4p2 + +ChangeSet@1.1527, 2007-06-20 01:51:36-04:00, stenn@pogo.udel.edu + merge cleanup + + ntpd/ntp_util.c@1.51 +1 -1 + merge cleanup + +ChangeSet@1.1523.2.2, 2007-06-19 18:55:53-04:00, stenn@whimsy.udel.edu + leap second cleanup from Dave Mills + + ChangeLog@1.71.1.1 +1 -0 + leap second cleanup from Dave Mills + +ChangeSet@1.1523.2.1, 2007-06-19 18:50:51-04:00, stenn@whimsy.udel.edu + leap second cleanup from Dave Mills + + include/ntpd.h@1.104 +0 -1 + leap second cleanup from Dave Mills + + ntpd/ntp_loopfilter.c@1.135 +13 -25 + leap second cleanup from Dave Mills + + ntpd/ntp_proto.c@1.254 +44 -19 + leap second cleanup from Dave Mills + + ntpd/ntp_timer.c@1.37 +12 -8 + leap second cleanup from Dave Mills + + ntpd/ntp_util.c@1.47.1.2 +51 -40 + leap second cleanup from Dave Mills + +ChangeSet@1.1519.1.1, 2007-06-19 08:37:26-04:00, mayer@pogo.udel.edu + Bug 629 Check for broadcast mode was in wrong place + + ntpd/ntp_io.c@1.253.1.1 +35 -11 + Bug 629 Check for broadcast mode was in wrong place + + ports/winnt/ntpd/ntp_iocompletionport.c@1.28 +8 -2 + Bug 629 Additional debug info + +ChangeSet@1.1525, 2007-06-19 03:13:46-04:00, stenn@pogo.udel.edu + regenerated ntp_parser.c + + ntpd/ntp_parser.c@1.13 +504 -493 + regenerated file + +ChangeSet@1.1523, 2007-06-17 07:44:01-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P52 + TAG: NTP_4_2_5P52 + + ntpd/ntpd-opts.c@1.39 +2 -2 + NTP_4_2_5P52 + + ntpd/ntpd-opts.h@1.39 +3 -3 + NTP_4_2_5P52 + + ntpd/ntpd-opts.texi@1.38 +1 -1 + NTP_4_2_5P52 + + ntpd/ntpd.1@1.38 +2 -2 + NTP_4_2_5P52 + + ntpdc/ntpdc-opts.c@1.39 +2 -2 + NTP_4_2_5P52 + + ntpdc/ntpdc-opts.h@1.39 +3 -3 + NTP_4_2_5P52 + + ntpdc/ntpdc-opts.texi@1.38 +1 -1 + NTP_4_2_5P52 + + ntpdc/ntpdc.1@1.38 +2 -2 + NTP_4_2_5P52 + + ntpq/ntpq-opts.c@1.39 +2 -2 + NTP_4_2_5P52 + + ntpq/ntpq-opts.h@1.39 +3 -3 + NTP_4_2_5P52 + + ntpq/ntpq-opts.texi@1.38 +1 -1 + NTP_4_2_5P52 + + ntpq/ntpq.1@1.38 +2 -2 + NTP_4_2_5P52 + + packageinfo.sh@1.55 +1 -1 + NTP_4_2_5P52 + + sntp/sntp-opts.c@1.39 +2 -2 + NTP_4_2_5P52 + + sntp/sntp-opts.h@1.39 +3 -3 + NTP_4_2_5P52 + + sntp/sntp-opts.texi@1.38 +1 -1 + NTP_4_2_5P52 + + sntp/sntp.1@1.38 +2 -2 + NTP_4_2_5P52 + + util/ntp-keygen-opts.c@1.40 +2 -2 + NTP_4_2_5P52 + + util/ntp-keygen-opts.h@1.40 +3 -3 + NTP_4_2_5P52 + + util/ntp-keygen-opts.texi@1.39 +1 -1 + NTP_4_2_5P52 + + util/ntp-keygen.1@1.39 +2 -2 + NTP_4_2_5P52 + +ChangeSet@1.1522, 2007-06-17 01:24:40-04:00, stenn@whimsy.udel.edu + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ChangeLog@1.71 +1 -0 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/Makefile.am@1.62 +2 -1 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/ntp_parser.c@1.10.1.1 +1511 -1964 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/ntp_parser.h@1.3.1.1 +155 -345 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + + ntpd/ntp_parser.y@1.8.1.1 +2 -0 + Use YYERROR_VERBOSE for the new parser, and fix related BUILT_SOURCES + +ChangeSet@1.1521, 2007-06-16 07:44:30-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P51 + TAG: NTP_4_2_5P51 + + ntpd/ntpd-opts.c@1.38 +2 -2 + NTP_4_2_5P51 + + ntpd/ntpd-opts.h@1.38 +3 -3 + NTP_4_2_5P51 + + ntpd/ntpd-opts.texi@1.37 +1 -1 + NTP_4_2_5P51 + + ntpd/ntpd.1@1.37 +2 -2 + NTP_4_2_5P51 + + ntpdc/ntpdc-opts.c@1.38 +2 -2 + NTP_4_2_5P51 + + ntpdc/ntpdc-opts.h@1.38 +3 -3 + NTP_4_2_5P51 + + ntpdc/ntpdc-opts.texi@1.37 +1 -1 + NTP_4_2_5P51 + + ntpdc/ntpdc.1@1.37 +2 -2 + NTP_4_2_5P51 + + ntpq/ntpq-opts.c@1.38 +2 -2 + NTP_4_2_5P51 + + ntpq/ntpq-opts.h@1.38 +3 -3 + NTP_4_2_5P51 + + ntpq/ntpq-opts.texi@1.37 +1 -1 + NTP_4_2_5P51 + + ntpq/ntpq.1@1.37 +2 -2 + NTP_4_2_5P51 + + packageinfo.sh@1.54 +1 -1 + NTP_4_2_5P51 + + sntp/sntp-opts.c@1.38 +2 -2 + NTP_4_2_5P51 + + sntp/sntp-opts.h@1.38 +3 -3 + NTP_4_2_5P51 + + sntp/sntp-opts.texi@1.37 +1 -1 + NTP_4_2_5P51 + + sntp/sntp.1@1.37 +2 -2 + NTP_4_2_5P51 + + util/ntp-keygen-opts.c@1.39 +2 -2 + NTP_4_2_5P51 + + util/ntp-keygen-opts.h@1.39 +3 -3 + NTP_4_2_5P51 + + util/ntp-keygen-opts.texi@1.38 +1 -1 + NTP_4_2_5P51 + + util/ntp-keygen.1@1.38 +2 -2 + NTP_4_2_5P51 + +ChangeSet@1.1520, 2007-06-15 19:36:46-04:00, stenn@deacon.udel.edu + typo + + ntpd/ntp_io.c@1.254 +1 -1 + typo + +ChangeSet@1.1518, 2007-06-15 07:48:47-04:00, mayer@pogo.udel.edu + Remove unused variable + + ntpd/ntp_io.c@1.253 +0 -1 + Remove unused variable + +ChangeSet@1.1512.1.15, 2007-06-15 07:42:58-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P50 + TAG: NTP_4_2_5P50 + + ntpd/ntpd-opts.c@1.37 +2 -2 + NTP_4_2_5P50 + + ntpd/ntpd-opts.h@1.37 +3 -3 + NTP_4_2_5P50 + + ntpd/ntpd-opts.texi@1.36 +4 -4 + NTP_4_2_5P50 + + ntpd/ntpd.1@1.36 +2 -2 + NTP_4_2_5P50 + + ntpdc/ntpdc-opts.c@1.37 +2 -2 + NTP_4_2_5P50 + + ntpdc/ntpdc-opts.h@1.37 +3 -3 + NTP_4_2_5P50 + + ntpdc/ntpdc-opts.texi@1.36 +2 -2 + NTP_4_2_5P50 + + ntpdc/ntpdc.1@1.36 +2 -2 + NTP_4_2_5P50 + + ntpq/ntpq-opts.c@1.37 +2 -2 + NTP_4_2_5P50 + + ntpq/ntpq-opts.h@1.37 +3 -3 + NTP_4_2_5P50 + + ntpq/ntpq-opts.texi@1.36 +2 -2 + NTP_4_2_5P50 + + ntpq/ntpq.1@1.36 +2 -2 + NTP_4_2_5P50 + + packageinfo.sh@1.53 +1 -1 + NTP_4_2_5P50 + + sntp/sntp-opts.c@1.37 +2 -2 + NTP_4_2_5P50 + + sntp/sntp-opts.h@1.37 +3 -3 + NTP_4_2_5P50 + + sntp/sntp-opts.texi@1.36 +1 -1 + NTP_4_2_5P50 + + sntp/sntp.1@1.36 +2 -2 + NTP_4_2_5P50 + + util/ntp-keygen-opts.c@1.38 +2 -2 + NTP_4_2_5P50 + + util/ntp-keygen-opts.h@1.38 +3 -3 + NTP_4_2_5P50 + + util/ntp-keygen-opts.texi@1.37 +2 -2 + NTP_4_2_5P50 + + util/ntp-keygen.1@1.37 +2 -2 + NTP_4_2_5P50 + +ChangeSet@1.1517, 2007-06-14 23:22:06-04:00, mayer@pogo.udel.edu + Bug #629 changes to ensure broadcast works including on wildcard addresses + + ChangeLog@1.70 +1 -0 + Bug #629 changes to ensure broadcast works including on wildcard addresses + +ChangeSet@1.1515, 2007-06-14 23:06:42-04:00, mayer@pogo.udel.edu + Bug #629 changes to ensure broadcast works including on wildcard addresses + + ntpd/ntp_io.c@1.252 +22 -17 + Bug #629 changes to ensure broadcast works including on wildcard addresses + + ports/winnt/ntpd/ntp_iocompletionport.c@1.27 +12 -3 + Bug #629 changes to ensure broadcast works including on wildcard addresses + +ChangeSet@1.1512.1.14, 2007-06-14 18:42:17-04:00, stenn@whimsy.udel.edu + [Bug 853] get_node() must return a pointer to maximally-aligned memory + + ChangeLog@1.69 +1 -0 + [Bug 853] get_node() must return a pointer to maximally-aligned memory + + include/ntp_data_structures.h@1.2 +5 -1 + [Bug 853] get_node() must return a pointer to maximally-aligned memory + + ntpd/ntp_data_structures.c@1.4 +7 -7 + [Bug 853] get_node() must return a pointer to maximally-aligned memory + +ChangeSet@1.1512.1.13, 2007-06-14 07:43:15-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P49 + TAG: NTP_4_2_5P49 + + ntpd/ntpd-opts.c@1.36 +2 -2 + NTP_4_2_5P49 + + ntpd/ntpd-opts.h@1.36 +3 -3 + NTP_4_2_5P49 + + ntpd/ntpd-opts.texi@1.35 +1 -1 + NTP_4_2_5P49 + + ntpd/ntpd.1@1.35 +2 -2 + NTP_4_2_5P49 + + ntpdc/ntpdc-opts.c@1.36 +2 -2 + NTP_4_2_5P49 + + ntpdc/ntpdc-opts.h@1.36 +3 -3 + NTP_4_2_5P49 + + ntpdc/ntpdc-opts.texi@1.35 +1 -1 + NTP_4_2_5P49 + + ntpdc/ntpdc.1@1.35 +2 -2 + NTP_4_2_5P49 + + ntpq/ntpq-opts.c@1.36 +2 -2 + NTP_4_2_5P49 + + ntpq/ntpq-opts.h@1.36 +3 -3 + NTP_4_2_5P49 + + ntpq/ntpq-opts.texi@1.35 +1 -1 + NTP_4_2_5P49 + + ntpq/ntpq.1@1.35 +2 -2 + NTP_4_2_5P49 + + packageinfo.sh@1.52 +1 -1 + NTP_4_2_5P49 + + sntp/sntp-opts.c@1.36 +2 -2 + NTP_4_2_5P49 + + sntp/sntp-opts.h@1.36 +3 -3 + NTP_4_2_5P49 + + sntp/sntp-opts.texi@1.35 +1 -1 + NTP_4_2_5P49 + + sntp/sntp.1@1.35 +2 -2 + NTP_4_2_5P49 + + util/ntp-keygen-opts.c@1.37 +2 -2 + NTP_4_2_5P49 + + util/ntp-keygen-opts.h@1.37 +3 -3 + NTP_4_2_5P49 + + util/ntp-keygen-opts.texi@1.36 +1 -1 + NTP_4_2_5P49 + + util/ntp-keygen.1@1.36 +2 -2 + NTP_4_2_5P49 + +ChangeSet@1.1512.1.12, 2007-06-14 01:40:14-04:00, stenn@whimsy.udel.edu + Leap file fixes from Dave Mills + + ChangeLog@1.68 +1 -0 + Leap file fixes from Dave Mills + + include/ntpd.h@1.103 +3 -1 + Leap file fixes from Dave Mills + + ntpd/ntp_proto.c@1.253 +35 -12 + Leap file fixes from Dave Mills + + ntpd/ntp_timer.c@1.36 +9 -2 + Leap file fixes from Dave Mills + + ntpd/ntp_util.c@1.47.1.1 +52 -2 + Leap file fixes from Dave Mills + +ChangeSet@1.1512.3.1, 2007-06-12 18:03:45-04:00, neal@pogo.udel.edu + Many files: + allow null driftfile. + + ChangeLog@1.66.1.1 +1 -0 + allow null driftfile. + + ntpd/ntp_config.c@1.156 +10 -2 + allow null driftfile. + + ntpd/ntp_parser.c@1.11 +507 -509 + allow null driftfile. + + ntpd/ntp_parser.h@1.4 +1 -1 + allow null driftfile. + + ntpd/ntp_parser.y@1.9 +16 -9 + allow null driftfile. + + ntpd/ntp_scanner.c@1.8 +10 -6 + allow null driftfile. + + ntpd/ntp_util.c@1.48 +1 -1 + allow null driftfile. + +ChangeSet@1.1512.1.11, 2007-06-12 08:00:26-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P48 + TAG: NTP_4_2_5P48 + + ntpd/ntpd-opts.c@1.35 +2 -2 + NTP_4_2_5P48 + + ntpd/ntpd-opts.h@1.35 +3 -3 + NTP_4_2_5P48 + + ntpd/ntpd-opts.texi@1.34 +1 -1 + NTP_4_2_5P48 + + ntpd/ntpd.1@1.34 +2 -2 + NTP_4_2_5P48 + + ntpdc/ntpdc-opts.c@1.35 +2 -2 + NTP_4_2_5P48 + + ntpdc/ntpdc-opts.h@1.35 +3 -3 + NTP_4_2_5P48 + + ntpdc/ntpdc-opts.texi@1.34 +1 -1 + NTP_4_2_5P48 + + ntpdc/ntpdc.1@1.34 +2 -2 + NTP_4_2_5P48 + + ntpq/ntpq-opts.c@1.35 +2 -2 + NTP_4_2_5P48 + + ntpq/ntpq-opts.h@1.35 +3 -3 + NTP_4_2_5P48 + + ntpq/ntpq-opts.texi@1.34 +1 -1 + NTP_4_2_5P48 + + ntpq/ntpq.1@1.34 +2 -2 + NTP_4_2_5P48 + + packageinfo.sh@1.51 +1 -1 + NTP_4_2_5P48 + + sntp/sntp-opts.c@1.35 +2 -2 + NTP_4_2_5P48 + + sntp/sntp-opts.h@1.35 +3 -3 + NTP_4_2_5P48 + + sntp/sntp-opts.texi@1.34 +1 -1 + NTP_4_2_5P48 + + sntp/sntp.1@1.34 +2 -2 + NTP_4_2_5P48 + + util/ntp-keygen-opts.c@1.36 +2 -2 + NTP_4_2_5P48 + + util/ntp-keygen-opts.h@1.36 +3 -3 + NTP_4_2_5P48 + + util/ntp-keygen-opts.texi@1.35 +1 -1 + NTP_4_2_5P48 + + util/ntp-keygen.1@1.35 +2 -2 + NTP_4_2_5P48 + +ChangeSet@1.1512.1.10, 2007-06-11 20:40:23-04:00, stenn@deacon.udel.edu + [Bug 858] Recent leapfile changes broke without OPENSSL + + ChangeLog@1.67 +1 -0 + [Bug 858] Recent leapfile changes broke without OPENSSL + + include/ntp_crypto.h@1.39 +1 -2 + [Bug 858] Recent leapfile changes broke without OPENSSL + + include/ntpd.h@1.102 +4 -2 + [Bug 858] Recent leapfile changes broke without OPENSSL + +ChangeSet@1.1512.1.9, 2007-06-10 10:00:31-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P47 + TAG: NTP_4_2_5P47 + + ntpd/ntpd-opts.c@1.34 +2 -2 + NTP_4_2_5P47 + + ntpd/ntpd-opts.h@1.34 +3 -3 + NTP_4_2_5P47 + + ntpd/ntpd-opts.texi@1.33 +1 -1 + NTP_4_2_5P47 + + ntpd/ntpd.1@1.33 +2 -2 + NTP_4_2_5P47 + + ntpdc/ntpdc-opts.c@1.34 +2 -2 + NTP_4_2_5P47 + + ntpdc/ntpdc-opts.h@1.34 +3 -3 + NTP_4_2_5P47 + + ntpdc/ntpdc-opts.texi@1.33 +1 -1 + NTP_4_2_5P47 + + ntpdc/ntpdc.1@1.33 +2 -2 + NTP_4_2_5P47 + + ntpq/ntpq-opts.c@1.34 +2 -2 + NTP_4_2_5P47 + + ntpq/ntpq-opts.h@1.34 +3 -3 + NTP_4_2_5P47 + + ntpq/ntpq-opts.texi@1.33 +1 -1 + NTP_4_2_5P47 + + ntpq/ntpq.1@1.33 +2 -2 + NTP_4_2_5P47 + + packageinfo.sh@1.50 +1 -1 + NTP_4_2_5P47 + + sntp/sntp-opts.c@1.34 +2 -2 + NTP_4_2_5P47 + + sntp/sntp-opts.h@1.34 +3 -3 + NTP_4_2_5P47 + + sntp/sntp-opts.texi@1.33 +1 -1 + NTP_4_2_5P47 + + sntp/sntp.1@1.33 +2 -2 + NTP_4_2_5P47 + + util/ntp-keygen-opts.c@1.35 +2 -2 + NTP_4_2_5P47 + + util/ntp-keygen-opts.h@1.35 +3 -3 + NTP_4_2_5P47 + + util/ntp-keygen-opts.texi@1.34 +1 -1 + NTP_4_2_5P47 + + util/ntp-keygen.1@1.34 +2 -2 + NTP_4_2_5P47 + +ChangeSet@1.1436.1.57, 2007-06-10 07:58:59-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P2_RC6 + TAG: NTP_4_2_4P2_RC6 + + ntpd/ntpd-opts.c@1.50.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + ntpd/ntpd-opts.h@1.50.7.1 +3 -3 + NTP_4_2_4P2_RC6 + + ntpd/ntpd-opts.texi@1.49.7.1 +1 -1 + NTP_4_2_4P2_RC6 + + ntpd/ntpd.1@1.48.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim-opts.c@1.50.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim-opts.h@1.50.7.1 +3 -3 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim-opts.texi@1.48.7.1 +1 -1 + NTP_4_2_4P2_RC6 + + ntpd/ntpdsim.1@1.48.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc-opts.c@1.50.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc-opts.h@1.50.7.1 +3 -3 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc-opts.texi@1.48.7.1 +1 -1 + NTP_4_2_4P2_RC6 + + ntpdc/ntpdc.1@1.48.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + ntpq/ntpq-opts.c@1.52.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + ntpq/ntpq-opts.h@1.52.7.1 +3 -3 + NTP_4_2_4P2_RC6 + + ntpq/ntpq-opts.texi@1.49.7.1 +1 -1 + NTP_4_2_4P2_RC6 + + ntpq/ntpq.1@1.48.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + packageinfo.sh@1.65.13.1 +1 -1 + NTP_4_2_4P2_RC6 + + sntp/sntp-opts.c@1.49.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + sntp/sntp-opts.h@1.49.7.1 +3 -3 + NTP_4_2_4P2_RC6 + + sntp/sntp-opts.texi@1.46.7.1 +1 -1 + NTP_4_2_4P2_RC6 + + sntp/sntp.1@1.49.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + util/ntp-keygen-opts.c@1.49.7.1 +2 -2 + NTP_4_2_4P2_RC6 + + util/ntp-keygen-opts.h@1.49.7.1 +3 -3 + NTP_4_2_4P2_RC6 + + util/ntp-keygen-opts.texi@1.47.7.1 +1 -1 + NTP_4_2_4P2_RC6 + + util/ntp-keygen.1@1.47.7.1 +2 -2 + NTP_4_2_4P2_RC6 + +ChangeSet@1.1512.1.8, 2007-06-10 03:26:26-04:00, stenn@deacon.udel.edu + ntp_dir_sep.m4, config.h: + Use a char for DIR_SEP, not a string + ntp_util.c, ntp_loopfilter.c, ntpd.h, ntp.h, ntp_timer.c, ChangeLog: + leap file improvements from Dave Mills. + + ChangeLog@1.66 +1 -0 + leap file improvements from Dave Mills. + + include/ntp.h@1.132 +1 -0 + leap file improvements from Dave Mills. + + include/ntpd.h@1.101 +2 -1 + leap file improvements from Dave Mills. + + m4/ntp_dir_sep.m4@1.2 +3 -3 + Use a char for DIR_SEP, not a string + + ntpd/ntp_loopfilter.c@1.134 +13 -37 + leap file improvements from Dave Mills. + + ntpd/ntp_timer.c@1.35 +6 -0 + leap file improvements from Dave Mills. + + ntpd/ntp_util.c@1.47 +138 -45 + leap file improvements from Dave Mills. + + ports/winnt/include/config.h@1.50 +1 -1 + Use a char for DIR_SEP, not a string + +ChangeSet@1.1512.2.1, 2007-06-07 15:57:08-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P46 + TAG: NTP_4_2_5P46 + + ntpd/ntpd-opts.c@1.33 +2 -2 + NTP_4_2_5P46 + + ntpd/ntpd-opts.h@1.33 +3 -3 + NTP_4_2_5P46 + + ntpd/ntpd-opts.texi@1.32 +1 -1 + NTP_4_2_5P46 + + ntpd/ntpd.1@1.32 +2 -2 + NTP_4_2_5P46 + + ntpdc/ntpdc-opts.c@1.33 +2 -2 + NTP_4_2_5P46 + + ntpdc/ntpdc-opts.h@1.33 +3 -3 + NTP_4_2_5P46 + + ntpdc/ntpdc-opts.texi@1.32 +1 -1 + NTP_4_2_5P46 + + ntpdc/ntpdc.1@1.32 +2 -2 + NTP_4_2_5P46 + + ntpq/ntpq-opts.c@1.33 +2 -2 + NTP_4_2_5P46 + + ntpq/ntpq-opts.h@1.33 +3 -3 + NTP_4_2_5P46 + + ntpq/ntpq-opts.texi@1.32 +1 -1 + NTP_4_2_5P46 + + ntpq/ntpq.1@1.32 +2 -2 + NTP_4_2_5P46 + + packageinfo.sh@1.49 +1 -1 + NTP_4_2_5P46 + + sntp/sntp-opts.c@1.33 +2 -2 + NTP_4_2_5P46 + + sntp/sntp-opts.h@1.33 +3 -3 + NTP_4_2_5P46 + + sntp/sntp-opts.texi@1.32 +1 -1 + NTP_4_2_5P46 + + sntp/sntp.1@1.32 +2 -2 + NTP_4_2_5P46 + + util/ntp-keygen-opts.c@1.34 +2 -2 + NTP_4_2_5P46 + + util/ntp-keygen-opts.h@1.34 +3 -3 + NTP_4_2_5P46 + + util/ntp-keygen-opts.texi@1.33 +1 -1 + NTP_4_2_5P46 + + util/ntp-keygen.1@1.33 +2 -2 + NTP_4_2_5P46 + +ChangeSet@1.1512.1.5, 2007-06-07 10:48:26-04:00, neal@pogo.udel.edu + ntp_parser.y, ntp_parser.h, ntp_parser.c, ChangeLog, ntp_config.c: + [Bug 850] driftfile parsing changes. + + ChangeLog@1.64 +1 -0 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_config.c@1.155 +3 -0 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_parser.c@1.10 +2040 -1569 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_parser.h@1.3 +345 -154 + [Bug 850] driftfile parsing changes. + + ntpd/ntp_parser.y@1.8 +9 -2 + [Bug 850] driftfile parsing changes. + +ChangeSet@1.1436.1.56, 2007-06-07 09:28:16-04:00, mayer@pogo.udel.edu + Bug #854 Broadcast address was not correctly set for interface addresses + + ChangeLog@1.1.1.18 +1 -0 + Bug #854 Broadcast address was not correctly set for interface addresses + +ChangeSet@1.1436.1.55, 2007-06-07 09:25:17-04:00, mayer@pogo.udel.edu + Bug #854 Broadcast address was not correctly set for interface addresses + + ports/winnt/libisc/interfaceiter.c@1.7 +35 -13 + Bug #854 Broadcast address was not correctly set for interface addresses + +ChangeSet@1.1512.1.4, 2007-06-07 06:40:49-04:00, stenn@deacon.udel.edu + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + + ChangeLog@1.63 +2 -0 + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + + ntpd/ntp_util.c@1.46 +8 -15 + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + + ntpd/ntpd.c@1.87 +1 -1 + driftfile maintenance changes from Dave Mills. Use clock_phi instead of stats_write_tolerance + +ChangeSet@1.1512.1.3, 2007-06-07 01:49:17-04:00, stenn@deacon.udel.edu + IRIG refclock improvements from Dave Mills + + ntpd/refclock_irig.c@1.31 +55 -65 + IRIG refclock improvements from Dave Mills + +ChangeSet@1.1512.1.2, 2007-06-05 07:45:25-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P45 + TAG: NTP_4_2_5P45 + + ntpd/ntpd-opts.c@1.32 +2 -2 + NTP_4_2_5P45 + + ntpd/ntpd-opts.h@1.32 +3 -3 + NTP_4_2_5P45 + + ntpd/ntpd-opts.texi@1.31 +1 -1 + NTP_4_2_5P45 + + ntpd/ntpd.1@1.31 +2 -2 + NTP_4_2_5P45 + + ntpdc/ntpdc-opts.c@1.32 +2 -2 + NTP_4_2_5P45 + + ntpdc/ntpdc-opts.h@1.32 +3 -3 + NTP_4_2_5P45 + + ntpdc/ntpdc-opts.texi@1.31 +1 -1 + NTP_4_2_5P45 + + ntpdc/ntpdc.1@1.31 +2 -2 + NTP_4_2_5P45 + + ntpq/ntpq-opts.c@1.32 +2 -2 + NTP_4_2_5P45 + + ntpq/ntpq-opts.h@1.32 +3 -3 + NTP_4_2_5P45 + + ntpq/ntpq-opts.texi@1.31 +1 -1 + NTP_4_2_5P45 + + ntpq/ntpq.1@1.31 +2 -2 + NTP_4_2_5P45 + + packageinfo.sh@1.48 +1 -1 + NTP_4_2_5P45 + + sntp/sntp-opts.c@1.32 +2 -2 + NTP_4_2_5P45 + + sntp/sntp-opts.h@1.32 +3 -3 + NTP_4_2_5P45 + + sntp/sntp-opts.texi@1.31 +1 -1 + NTP_4_2_5P45 + + sntp/sntp.1@1.31 +2 -2 + NTP_4_2_5P45 + + util/ntp-keygen-opts.c@1.33 +2 -2 + NTP_4_2_5P45 + + util/ntp-keygen-opts.h@1.33 +3 -3 + NTP_4_2_5P45 + + util/ntp-keygen-opts.texi@1.32 +1 -1 + NTP_4_2_5P45 + + util/ntp-keygen.1@1.32 +2 -2 + NTP_4_2_5P45 + +ChangeSet@1.1512.1.1, 2007-06-05 02:28:01-04:00, stenn@whimsy.udel.edu + indentation cleanup + + ntpd/ntp_config.c@1.154 +1676 -1559 + indentation cleanup + +ChangeSet@1.1495.1.1, 2007-06-02 18:30:39-04:00, mayer@pogo.udel.edu + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + include/ntp_io.h@1.6 +3 -0 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + include/ntp_request.h@1.32 +7 -0 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + ntpd/ntp_io.c@1.249.1.1 +27 -2 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + ntpd/ntp_request.c@1.68 +9 -0 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + + ports/winnt/ntpd/ntp_iocompletionport.c@1.26 +20 -2 + Bug #629 Allow certain broadcast packets to be received on the wildcard socket + +ChangeSet@1.1512, 2007-06-02 07:44:39-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P44 + TAG: NTP_4_2_5P44 + + ntpd/ntpd-opts.c@1.31 +2 -2 + NTP_4_2_5P44 + + ntpd/ntpd-opts.h@1.31 +3 -3 + NTP_4_2_5P44 + + ntpd/ntpd-opts.texi@1.30 +1 -1 + NTP_4_2_5P44 + + ntpd/ntpd.1@1.30 +2 -2 + NTP_4_2_5P44 + + ntpdc/ntpdc-opts.c@1.31 +2 -2 + NTP_4_2_5P44 + + ntpdc/ntpdc-opts.h@1.31 +3 -3 + NTP_4_2_5P44 + + ntpdc/ntpdc-opts.texi@1.30 +1 -1 + NTP_4_2_5P44 + + ntpdc/ntpdc.1@1.30 +2 -2 + NTP_4_2_5P44 + + ntpq/ntpq-opts.c@1.31 +2 -2 + NTP_4_2_5P44 + + ntpq/ntpq-opts.h@1.31 +3 -3 + NTP_4_2_5P44 + + ntpq/ntpq-opts.texi@1.30 +1 -1 + NTP_4_2_5P44 + + ntpq/ntpq.1@1.30 +2 -2 + NTP_4_2_5P44 + + packageinfo.sh@1.47 +1 -1 + NTP_4_2_5P44 + + sntp/sntp-opts.c@1.31 +2 -2 + NTP_4_2_5P44 + + sntp/sntp-opts.h@1.31 +3 -3 + NTP_4_2_5P44 + + sntp/sntp-opts.texi@1.30 +1 -1 + NTP_4_2_5P44 + + sntp/sntp.1@1.30 +2 -2 + NTP_4_2_5P44 + + util/ntp-keygen-opts.c@1.32 +2 -2 + NTP_4_2_5P44 + + util/ntp-keygen-opts.h@1.32 +3 -3 + NTP_4_2_5P44 + + util/ntp-keygen-opts.texi@1.31 +1 -1 + NTP_4_2_5P44 + + util/ntp-keygen.1@1.31 +2 -2 + NTP_4_2_5P44 + +ChangeSet@1.1511, 2007-06-02 00:27:35-04:00, stenn@whimsy.udel.edu + Updated from the recent change to ntp_parser.y + + ntpd/ntp_parser.c@1.9 +196 -182 + Updated from the recent change to ntp_parser.y + +ChangeSet@1.1510, 2007-06-01 18:30:18-04:00, neal@pogo.udel.edu + ntp_scanner.c, ChangeLog: + [Bug 828] refid not being parsed correctly. + + ChangeLog@1.62 +1 -0 + [Bug 828] refid not being parsed correctly. + + ntpd/ntp_scanner.c@1.7 +8 -6 + [Bug 828] refid not being parsed correctly. + +ChangeSet@1.1506.1.2, 2007-06-01 08:13:55-04:00, neal@pogo.udel.edu + commit to correct bk merge problems. + + ChangeLog@1.59.1.2 +1 -0 + +ChangeSet@1.1506.1.1, 2007-06-01 07:52:58-04:00, neal@pogo.udel.edu + ntp_parser.y, ntp_scanner.c, ChangeLog: + [Bug 846] Correct includefile parsing. + + ChangeLog@1.59.1.1 +1 -0 + [Bug 846] Correct includefile parsing. + + ntpd/ntp_parser.y@1.7 +2 -2 + [Bug 846] Correct includefile parsing. + + ntpd/ntp_scanner.c@1.6 +7 -2 + [Bug 846] Correct includefile parsing. + +ChangeSet@1.1508, 2007-06-01 07:44:04-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P43 + TAG: NTP_4_2_5P43 + + ntpd/ntpd-opts.c@1.30 +2 -2 + NTP_4_2_5P43 + + ntpd/ntpd-opts.h@1.30 +3 -3 + NTP_4_2_5P43 + + ntpd/ntpd-opts.texi@1.29 +1 -1 + NTP_4_2_5P43 + + ntpd/ntpd.1@1.29 +2 -2 + NTP_4_2_5P43 + + ntpdc/ntpdc-opts.c@1.30 +2 -2 + NTP_4_2_5P43 + + ntpdc/ntpdc-opts.h@1.30 +3 -3 + NTP_4_2_5P43 + + ntpdc/ntpdc-opts.texi@1.29 +1 -1 + NTP_4_2_5P43 + + ntpdc/ntpdc.1@1.29 +2 -2 + NTP_4_2_5P43 + + ntpq/ntpq-opts.c@1.30 +2 -2 + NTP_4_2_5P43 + + ntpq/ntpq-opts.h@1.30 +3 -3 + NTP_4_2_5P43 + + ntpq/ntpq-opts.texi@1.29 +1 -1 + NTP_4_2_5P43 + + ntpq/ntpq.1@1.29 +2 -2 + NTP_4_2_5P43 + + packageinfo.sh@1.46 +1 -1 + NTP_4_2_5P43 + + sntp/sntp-opts.c@1.30 +2 -2 + NTP_4_2_5P43 + + sntp/sntp-opts.h@1.30 +3 -3 + NTP_4_2_5P43 + + sntp/sntp-opts.texi@1.29 +1 -1 + NTP_4_2_5P43 + + sntp/sntp.1@1.29 +2 -2 + NTP_4_2_5P43 + + util/ntp-keygen-opts.c@1.31 +2 -2 + NTP_4_2_5P43 + + util/ntp-keygen-opts.h@1.31 +3 -3 + NTP_4_2_5P43 + + util/ntp-keygen-opts.texi@1.30 +1 -1 + NTP_4_2_5P43 + + util/ntp-keygen.1@1.30 +2 -2 + NTP_4_2_5P43 + +ChangeSet@1.1507, 2007-06-01 02:17:28-04:00, stenn@whimsy.udel.edu + [Bug 827] New parsing code does not handle "fudge" correctly + + ChangeLog@1.60 +1 -0 + [Bug 827] New parsing code does not handle "fudge" correctly + +ChangeSet@1.1506, 2007-05-31 07:47:43-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P42 + TAG: NTP_4_2_5P42 + + ntpd/ntpd-opts.c@1.29 +4 -5 + NTP_4_2_5P42 + + ntpd/ntpd-opts.h@1.29 +5 -6 + NTP_4_2_5P42 + + ntpd/ntpd-opts.texi@1.28 +2 -3 + NTP_4_2_5P42 + + ntpd/ntpd.1@1.28 +3 -3 + NTP_4_2_5P42 + + ntpdc/ntpdc-opts.c@1.29 +4 -5 + NTP_4_2_5P42 + + ntpdc/ntpdc-opts.h@1.29 +5 -6 + NTP_4_2_5P42 + + ntpdc/ntpdc-opts.texi@1.28 +2 -3 + NTP_4_2_5P42 + + ntpdc/ntpdc.1@1.28 +3 -3 + NTP_4_2_5P42 + + ntpq/ntpq-opts.c@1.29 +4 -5 + NTP_4_2_5P42 + + ntpq/ntpq-opts.h@1.29 +5 -6 + NTP_4_2_5P42 + + ntpq/ntpq-opts.texi@1.28 +2 -3 + NTP_4_2_5P42 + + ntpq/ntpq.1@1.28 +3 -3 + NTP_4_2_5P42 + + packageinfo.sh@1.45 +1 -1 + NTP_4_2_5P42 + + sntp/sntp-opts.c@1.29 +4 -5 + NTP_4_2_5P42 + + sntp/sntp-opts.h@1.29 +5 -6 + NTP_4_2_5P42 + + sntp/sntp-opts.texi@1.28 +2 -3 + NTP_4_2_5P42 + + sntp/sntp.1@1.28 +3 -3 + NTP_4_2_5P42 + + util/ntp-keygen-opts.c@1.30 +4 -5 + NTP_4_2_5P42 + + util/ntp-keygen-opts.h@1.30 +5 -6 + NTP_4_2_5P42 + + util/ntp-keygen-opts.texi@1.29 +2 -3 + NTP_4_2_5P42 + + util/ntp-keygen.1@1.29 +3 -3 + NTP_4_2_5P42 + +ChangeSet@1.1505, 2007-05-31 01:32:15-04:00, stenn@whimsy.udel.edu + Enable debugging capability in the config parser. + + ChangeLog@1.59 +1 -0 + Enable debugging capability in the config parser. + + ntpd/Makefile.am@1.61 +1 -1 + Enable debugging capability in the config parser. + + ntpd/ntp_parser.c@1.8 +1 -1 + Enable debugging capability in the config parser. + +ChangeSet@1.1504, 2007-05-30 22:54:36-04:00, stenn@whimsy.udel.edu + [Bug 839] Crypto password not read from ntp.conf + + ChangeLog@1.58 +1 -0 + [Bug 839] Crypto password not read from ntp.conf + + ntpd/ntp_parser.c@1.7 +198 -194 + [Bug 839] Crypto password not read from ntp.conf + + ntpd/ntp_parser.y@1.6 +5 -1 + [Bug 839] Crypto password not read from ntp.conf + +ChangeSet@1.1503, 2007-05-30 22:44:11-04:00, stenn@whimsy.udel.edu + Have autogen produce writable output files + + ChangeLog@1.57 +1 -0 + Have autogen produce writable output files + + ntpd/Makefile.am@1.60 +1 -1 + Have autogen produce writable output files + + ntpdc/Makefile.am@1.36 +1 -1 + Have autogen produce writable output files + + ntpq/Makefile.am@1.28 +1 -1 + Have autogen produce writable output files + + sntp/Makefile.am@1.22 +2 -2 + Have autogen produce writable output files + + util/Makefile.am@1.37 +1 -1 + Have autogen produce writable output files + +ChangeSet@1.1501, 2007-05-30 07:45:27-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P41 + TAG: NTP_4_2_5P41 + + ntpd/ntpd-opts.c@1.28 +2 -2 + NTP_4_2_5P41 + + ntpd/ntpd-opts.h@1.28 +3 -3 + NTP_4_2_5P41 + + ntpd/ntpd-opts.texi@1.27 +1 -1 + NTP_4_2_5P41 + + ntpd/ntpd.1@1.27 +2 -2 + NTP_4_2_5P41 + + ntpdc/ntpdc-opts.c@1.28 +2 -2 + NTP_4_2_5P41 + + ntpdc/ntpdc-opts.h@1.28 +3 -3 + NTP_4_2_5P41 + + ntpdc/ntpdc-opts.texi@1.27 +1 -1 + NTP_4_2_5P41 + + ntpdc/ntpdc.1@1.27 +2 -2 + NTP_4_2_5P41 + + ntpq/ntpq-opts.c@1.28 +2 -2 + NTP_4_2_5P41 + + ntpq/ntpq-opts.h@1.28 +3 -3 + NTP_4_2_5P41 + + ntpq/ntpq-opts.texi@1.27 +1 -1 + NTP_4_2_5P41 + + ntpq/ntpq.1@1.27 +2 -2 + NTP_4_2_5P41 + + packageinfo.sh@1.44 +1 -1 + NTP_4_2_5P41 + + sntp/sntp-opts.c@1.28 +2 -2 + NTP_4_2_5P41 + + sntp/sntp-opts.h@1.28 +3 -3 + NTP_4_2_5P41 + + sntp/sntp-opts.texi@1.27 +1 -1 + NTP_4_2_5P41 + + sntp/sntp.1@1.27 +2 -2 + NTP_4_2_5P41 + + util/ntp-keygen-opts.c@1.29 +2 -2 + NTP_4_2_5P41 + + util/ntp-keygen-opts.h@1.29 +3 -3 + NTP_4_2_5P41 + + util/ntp-keygen-opts.texi@1.28 +1 -1 + NTP_4_2_5P41 + + util/ntp-keygen.1@1.28 +2 -2 + NTP_4_2_5P41 + +ChangeSet@1.1500, 2007-05-29 23:39:45-04:00, stenn@pogo.udel.edu + ChangeLog: + [Bug 825] Correct logconfig -/+ keyword processing. + [Bug 828] Correct parsing of " delimited strings. + + ChangeLog@1.56 +2 -0 + [Bug 825] Correct logconfig -/+ keyword processing. + [Bug 828] Correct parsing of " delimited strings. + +ChangeSet@1.1499, 2007-05-29 15:46:00-04:00, neal@pogo.udel.edu + ntp_config.c: + [Bug 825] Correct logconfig -/+ keyword processing. + ntp_scanner.c: + [Bug 828] Correct parsing of " delimited strings. + + ntpd/ntp_config.c@1.153 +1 -1 + [Bug 825] Correct logconfig -/+ keyword processing. + + ntpd/ntp_scanner.c@1.5 +14 -2 + [Bug 828] Correct parsing of " delimited strings. + +ChangeSet@1.1498, 2007-05-29 09:39:55-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P40 + TAG: NTP_4_2_5P40 + + ntpd/ntpd-opts.c@1.27 +2 -2 + NTP_4_2_5P40 + + ntpd/ntpd-opts.h@1.27 +3 -3 + NTP_4_2_5P40 + + ntpd/ntpd-opts.texi@1.26 +1 -1 + NTP_4_2_5P40 + + ntpd/ntpd.1@1.26 +2 -2 + NTP_4_2_5P40 + + ntpdc/ntpdc-opts.c@1.27 +2 -2 + NTP_4_2_5P40 + + ntpdc/ntpdc-opts.h@1.27 +3 -3 + NTP_4_2_5P40 + + ntpdc/ntpdc-opts.texi@1.26 +1 -1 + NTP_4_2_5P40 + + ntpdc/ntpdc.1@1.26 +2 -2 + NTP_4_2_5P40 + + ntpq/ntpq-opts.c@1.27 +2 -2 + NTP_4_2_5P40 + + ntpq/ntpq-opts.h@1.27 +3 -3 + NTP_4_2_5P40 + + ntpq/ntpq-opts.texi@1.26 +1 -1 + NTP_4_2_5P40 + + ntpq/ntpq.1@1.26 +2 -2 + NTP_4_2_5P40 + + packageinfo.sh@1.43 +1 -1 + NTP_4_2_5P40 + + sntp/sntp-opts.c@1.27 +2 -2 + NTP_4_2_5P40 + + sntp/sntp-opts.h@1.27 +3 -3 + NTP_4_2_5P40 + + sntp/sntp-opts.texi@1.26 +1 -1 + NTP_4_2_5P40 + + sntp/sntp.1@1.26 +2 -2 + NTP_4_2_5P40 + + util/ntp-keygen-opts.c@1.28 +2 -2 + NTP_4_2_5P40 + + util/ntp-keygen-opts.h@1.28 +3 -3 + NTP_4_2_5P40 + + util/ntp-keygen-opts.texi@1.27 +1 -1 + NTP_4_2_5P40 + + util/ntp-keygen.1@1.27 +2 -2 + NTP_4_2_5P40 + +ChangeSet@1.1436.1.54, 2007-05-29 07:43:58-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P2_RC5 + TAG: NTP_4_2_4P2_RC5 + + ntpd/ntpd-opts.c@1.50.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + ntpd/ntpd-opts.h@1.50.6.1 +3 -3 + NTP_4_2_4P2_RC5 + + ntpd/ntpd-opts.texi@1.49.6.1 +1 -1 + NTP_4_2_4P2_RC5 + + ntpd/ntpd.1@1.48.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim-opts.c@1.50.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim-opts.h@1.50.6.1 +3 -3 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim-opts.texi@1.48.6.1 +1 -1 + NTP_4_2_4P2_RC5 + + ntpd/ntpdsim.1@1.48.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc-opts.c@1.50.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc-opts.h@1.50.6.1 +3 -3 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc-opts.texi@1.48.6.1 +1 -1 + NTP_4_2_4P2_RC5 + + ntpdc/ntpdc.1@1.48.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + ntpq/ntpq-opts.c@1.52.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + ntpq/ntpq-opts.h@1.52.6.1 +3 -3 + NTP_4_2_4P2_RC5 + + ntpq/ntpq-opts.texi@1.49.6.1 +1 -1 + NTP_4_2_4P2_RC5 + + ntpq/ntpq.1@1.48.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + packageinfo.sh@1.65.12.1 +1 -1 + NTP_4_2_4P2_RC5 + + sntp/sntp-opts.c@1.49.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + sntp/sntp-opts.h@1.49.6.1 +3 -3 + NTP_4_2_4P2_RC5 + + sntp/sntp-opts.texi@1.46.6.1 +1 -1 + NTP_4_2_4P2_RC5 + + sntp/sntp.1@1.49.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + util/ntp-keygen-opts.c@1.49.6.1 +2 -2 + NTP_4_2_4P2_RC5 + + util/ntp-keygen-opts.h@1.49.6.1 +3 -3 + NTP_4_2_4P2_RC5 + + util/ntp-keygen-opts.texi@1.47.6.1 +1 -1 + NTP_4_2_4P2_RC5 + + util/ntp-keygen.1@1.47.6.1 +2 -2 + NTP_4_2_4P2_RC5 + +ChangeSet@1.1436.1.53, 2007-05-29 01:32:29-04:00, stenn@whimsy.udel.edu + typo cleanup + + ChangeLog@1.1.1.17 +1 -1 + typo cleanup + + NEWS@1.86.1.7 +1 -2 + typo cleanup + +ChangeSet@1.1496, 2007-05-29 01:07:40-04:00, stenn@whimsy.udel.edu + Cleanup FILE * usage after fclose() in ntp_filegen.c + + ChangeLog@1.54 +5 -3 + Cleanup FILE * usage after fclose() in ntp_filegen.c + + ntpd/ntp_filegen.c@1.13 +27 -19 + Cleanup FILE * usage after fclose() in ntp_filegen.c + +ChangeSet@1.1495, 2007-05-28 07:47:31-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P39 + TAG: NTP_4_2_5P39 + + ntpd/ntpd-opts.c@1.26 +2 -2 + NTP_4_2_5P39 + + ntpd/ntpd-opts.h@1.26 +3 -3 + NTP_4_2_5P39 + + ntpd/ntpd-opts.texi@1.25 +1 -1 + NTP_4_2_5P39 + + ntpd/ntpd.1@1.25 +2 -2 + NTP_4_2_5P39 + + ntpdc/ntpdc-opts.c@1.26 +2 -2 + NTP_4_2_5P39 + + ntpdc/ntpdc-opts.h@1.26 +3 -3 + NTP_4_2_5P39 + + ntpdc/ntpdc-opts.texi@1.25 +1 -1 + NTP_4_2_5P39 + + ntpdc/ntpdc.1@1.25 +2 -2 + NTP_4_2_5P39 + + ntpq/ntpq-opts.c@1.26 +2 -2 + NTP_4_2_5P39 + + ntpq/ntpq-opts.h@1.26 +3 -3 + NTP_4_2_5P39 + + ntpq/ntpq-opts.texi@1.25 +1 -1 + NTP_4_2_5P39 + + ntpq/ntpq.1@1.25 +2 -2 + NTP_4_2_5P39 + + packageinfo.sh@1.42 +1 -1 + NTP_4_2_5P39 + + sntp/sntp-opts.c@1.26 +2 -2 + NTP_4_2_5P39 + + sntp/sntp-opts.h@1.26 +3 -3 + NTP_4_2_5P39 + + sntp/sntp-opts.texi@1.25 +1 -1 + NTP_4_2_5P39 + + sntp/sntp.1@1.25 +2 -2 + NTP_4_2_5P39 + + util/ntp-keygen-opts.c@1.27 +2 -2 + NTP_4_2_5P39 + + util/ntp-keygen-opts.h@1.27 +3 -3 + NTP_4_2_5P39 + + util/ntp-keygen-opts.texi@1.26 +1 -1 + NTP_4_2_5P39 + + util/ntp-keygen.1@1.26 +2 -2 + NTP_4_2_5P39 + +ChangeSet@1.1436.1.52, 2007-05-28 10:00:27+00:00, kardel@pogo.udel.edu + NEWS, ntp_io.c, ChangeLog: + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + + ChangeLog@1.1.1.16 +2 -0 + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + + NEWS@1.86.1.6 +3 -0 + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + + ntpd/ntp_io.c@1.244.2.6 +58 -44 + Bug 829: reduce syslog noise, while there fix Enabled/Disable logging + to reflect the actual configuration + +ChangeSet@1.1493, 2007-05-27 20:13:47-04:00, mayer@pogo.udel.edu + Bug #843 Windows Completion port code was incorrectly merged from -stable + + ChangeLog@1.53 +1 -0 + Bug #843 Windows Completion port code was incorrectly merged from -stable + +ChangeSet@1.1492, 2007-05-27 20:11:03-04:00, mayer@pogo.udel.edu + Bug #843 Windows Completion port code was incorrectly merged from -stable + + ports/winnt/ntpd/ntp_iocompletionport.c@1.25 +0 -15 + Bug #843 Windows Completion port code was incorrectly merged from -stable + +ChangeSet@1.1491, 2007-05-27 09:46:31-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P38 + TAG: NTP_4_2_5P38 + + ntpd/ntpd-opts.c@1.25 +2 -2 + NTP_4_2_5P38 + + ntpd/ntpd-opts.h@1.25 +3 -3 + NTP_4_2_5P38 + + ntpd/ntpd-opts.texi@1.24 +1 -1 + NTP_4_2_5P38 + + ntpd/ntpd.1@1.24 +2 -2 + NTP_4_2_5P38 + + ntpdc/ntpdc-opts.c@1.25 +2 -2 + NTP_4_2_5P38 + + ntpdc/ntpdc-opts.h@1.25 +3 -3 + NTP_4_2_5P38 + + ntpdc/ntpdc-opts.texi@1.24 +1 -1 + NTP_4_2_5P38 + + ntpdc/ntpdc.1@1.24 +2 -2 + NTP_4_2_5P38 + + ntpq/ntpq-opts.c@1.25 +2 -2 + NTP_4_2_5P38 + + ntpq/ntpq-opts.h@1.25 +3 -3 + NTP_4_2_5P38 + + ntpq/ntpq-opts.texi@1.24 +1 -1 + NTP_4_2_5P38 + + ntpq/ntpq.1@1.24 +2 -2 + NTP_4_2_5P38 + + packageinfo.sh@1.41 +1 -1 + NTP_4_2_5P38 + + sntp/sntp-opts.c@1.25 +2 -2 + NTP_4_2_5P38 + + sntp/sntp-opts.h@1.25 +3 -3 + NTP_4_2_5P38 + + sntp/sntp-opts.texi@1.24 +1 -1 + NTP_4_2_5P38 + + sntp/sntp.1@1.24 +2 -2 + NTP_4_2_5P38 + + util/ntp-keygen-opts.c@1.26 +2 -2 + NTP_4_2_5P38 + + util/ntp-keygen-opts.h@1.26 +3 -3 + NTP_4_2_5P38 + + util/ntp-keygen-opts.texi@1.25 +1 -1 + NTP_4_2_5P38 + + util/ntp-keygen.1@1.25 +2 -2 + NTP_4_2_5P38 + +ChangeSet@1.1436.1.51, 2007-05-27 07:45:05-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P2_RC4 + TAG: NTP_4_2_4P2_RC4 + + ntpd/ntpd-opts.c@1.50.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + ntpd/ntpd-opts.h@1.50.5.1 +3 -3 + NTP_4_2_4P2_RC4 + + ntpd/ntpd-opts.texi@1.49.5.1 +1 -1 + NTP_4_2_4P2_RC4 + + ntpd/ntpd.1@1.48.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim-opts.c@1.50.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim-opts.h@1.50.5.1 +3 -3 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim-opts.texi@1.48.5.1 +1 -1 + NTP_4_2_4P2_RC4 + + ntpd/ntpdsim.1@1.48.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc-opts.c@1.50.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc-opts.h@1.50.5.1 +3 -3 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc-opts.texi@1.48.5.1 +1 -1 + NTP_4_2_4P2_RC4 + + ntpdc/ntpdc.1@1.48.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + ntpq/ntpq-opts.c@1.52.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + ntpq/ntpq-opts.h@1.52.5.1 +3 -3 + NTP_4_2_4P2_RC4 + + ntpq/ntpq-opts.texi@1.49.5.1 +1 -1 + NTP_4_2_4P2_RC4 + + ntpq/ntpq.1@1.48.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + packageinfo.sh@1.65.11.1 +1 -1 + NTP_4_2_4P2_RC4 + + sntp/sntp-opts.c@1.49.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + sntp/sntp-opts.h@1.49.5.1 +3 -3 + NTP_4_2_4P2_RC4 + + sntp/sntp-opts.texi@1.46.5.1 +1 -1 + NTP_4_2_4P2_RC4 + + sntp/sntp.1@1.49.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + util/ntp-keygen-opts.c@1.49.5.1 +2 -2 + NTP_4_2_4P2_RC4 + + util/ntp-keygen-opts.h@1.49.5.1 +3 -3 + NTP_4_2_4P2_RC4 + + util/ntp-keygen-opts.texi@1.47.5.1 +1 -1 + NTP_4_2_4P2_RC4 + + util/ntp-keygen.1@1.47.5.1 +2 -2 + NTP_4_2_4P2_RC4 + +ChangeSet@1.1436.1.50, 2007-05-27 00:52:52-04:00, stenn@whimsy.udel.edu + update NEWS file with new fixes + + NEWS@1.86.1.5 +6 -0 + update NEWS file with new fixes + +ChangeSet@1.1436.1.49, 2007-05-27 00:31:51-04:00, stenn@deacon.udel.edu + Cleanup + + ChangeLog@1.1.1.15 +2 -2 + Cleanup + +ChangeSet@1.1485.2.2, 2007-05-26 15:10:28+00:00, kardel@pogo.udel.edu + Many files: + Bug 841: make deferred binding to local interface the default + + ChangeLog@1.47.2.2 +2 -0 + Bug 841: make deferred binding to local interface the default + + html/confopt.html@1.36 +0 -2 + Bug 841: make deferred binding to local interface the default + + html/ntpdc.html@1.27 +2 -3 + Bug 841: make deferred binding to local interface the default + + include/ntp.h@1.131 +0 -1 + Bug 841: make deferred binding to local interface the default + + include/ntp_request.h@1.31 +0 -1 + Bug 841: make deferred binding to local interface the default + + ntpd/ntp_intres.c@1.51 +1 -3 + Bug 841: make deferred binding to local interface the default + + ntpd/ntp_peer.c@1.101.1.1 +1 -20 + Bug 841: make deferred binding to local interface the default + + ntpd/ntp_request.c@1.67 +1 -3 + Bug 841: make deferred binding to local interface the default + + ntpdc/ntpdc_ops.c@1.48 +2 -4 + Bug 841: make deferred binding to local interface the default + +ChangeSet@1.1485.2.1, 2007-05-26 13:29:05+00:00, kardel@pogo.udel.edu + ChangeLog: + Bug 840: do fudge configuration AFTER peers (thus refclocks) have been configured + ntp_config.c: + Bug 840: do fudge configuration AFTER peers (thus refclocks) have been configured + + ChangeLog@1.47.2.1 +1 -0 + Bug 840: do fudge configuration AFTER peers (thus refclocks) have been configured + + ntpd/ntp_config.c@1.152 +1 -1 + Bug 840: do fudge commands AFTER configuring peers (and thus refclocks) + +ChangeSet@1.1487.1.1, 2007-05-26 08:05:51-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P37 + TAG: NTP_4_2_5P37 + + ntpd/ntpd-opts.c@1.24 +2 -2 + NTP_4_2_5P37 + + ntpd/ntpd-opts.h@1.24 +3 -3 + NTP_4_2_5P37 + + ntpd/ntpd-opts.texi@1.23 +1 -1 + NTP_4_2_5P37 + + ntpd/ntpd.1@1.23 +2 -2 + NTP_4_2_5P37 + + ntpdc/ntpdc-opts.c@1.24 +2 -2 + NTP_4_2_5P37 + + ntpdc/ntpdc-opts.h@1.24 +3 -3 + NTP_4_2_5P37 + + ntpdc/ntpdc-opts.texi@1.23 +1 -1 + NTP_4_2_5P37 + + ntpdc/ntpdc.1@1.23 +2 -2 + NTP_4_2_5P37 + + ntpq/ntpq-opts.c@1.24 +2 -2 + NTP_4_2_5P37 + + ntpq/ntpq-opts.h@1.24 +3 -3 + NTP_4_2_5P37 + + ntpq/ntpq-opts.texi@1.23 +1 -1 + NTP_4_2_5P37 + + ntpq/ntpq.1@1.23 +2 -2 + NTP_4_2_5P37 + + packageinfo.sh@1.40 +1 -1 + NTP_4_2_5P37 + + sntp/sntp-opts.c@1.24 +2 -2 + NTP_4_2_5P37 + + sntp/sntp-opts.h@1.24 +3 -3 + NTP_4_2_5P37 + + sntp/sntp-opts.texi@1.23 +1 -1 + NTP_4_2_5P37 + + sntp/sntp.1@1.23 +2 -2 + NTP_4_2_5P37 + + util/ntp-keygen-opts.c@1.25 +2 -2 + NTP_4_2_5P37 + + util/ntp-keygen-opts.h@1.25 +3 -3 + NTP_4_2_5P37 + + util/ntp-keygen-opts.texi@1.24 +1 -1 + NTP_4_2_5P37 + + util/ntp-keygen.1@1.24 +2 -2 + NTP_4_2_5P37 + +ChangeSet@1.1436.1.48, 2007-05-26 08:00:03+00:00, kardel@pogo.udel.edu + ntp_io.c: + [Bug 795] Moved declaration of variable to top of function. + ChangeLog: + [Bug 795] Moved declaration of variable to top of function. + + ChangeLog@1.1.1.14 +1 -0 + Bug 795 + + ntpd/ntp_io.c@1.244.2.5 +4 -1 + [Bug 795] Moved declaration of variable to top of function. + +ChangeSet@1.1436.3.9, 2007-05-25 07:44:43-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P2_RC3 + TAG: NTP_4_2_4P2_RC3 + + ntpd/ntpd-opts.c@1.50.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + ntpd/ntpd-opts.h@1.50.4.1 +3 -3 + NTP_4_2_4P2_RC3 + + ntpd/ntpd-opts.texi@1.49.4.1 +1 -1 + NTP_4_2_4P2_RC3 + + ntpd/ntpd.1@1.48.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim-opts.c@1.50.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim-opts.h@1.50.4.1 +3 -3 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim-opts.texi@1.48.4.1 +1 -1 + NTP_4_2_4P2_RC3 + + ntpd/ntpdsim.1@1.48.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc-opts.c@1.50.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc-opts.h@1.50.4.1 +3 -3 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc-opts.texi@1.48.4.1 +1 -1 + NTP_4_2_4P2_RC3 + + ntpdc/ntpdc.1@1.48.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + ntpq/ntpq-opts.c@1.52.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + ntpq/ntpq-opts.h@1.52.4.1 +3 -3 + NTP_4_2_4P2_RC3 + + ntpq/ntpq-opts.texi@1.49.4.1 +1 -1 + NTP_4_2_4P2_RC3 + + ntpq/ntpq.1@1.48.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + packageinfo.sh@1.65.10.1 +1 -1 + NTP_4_2_4P2_RC3 + + sntp/sntp-opts.c@1.49.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + sntp/sntp-opts.h@1.49.4.1 +3 -3 + NTP_4_2_4P2_RC3 + + sntp/sntp-opts.texi@1.46.4.1 +1 -1 + NTP_4_2_4P2_RC3 + + sntp/sntp.1@1.49.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + util/ntp-keygen-opts.c@1.49.4.1 +2 -2 + NTP_4_2_4P2_RC3 + + util/ntp-keygen-opts.h@1.49.4.1 +3 -3 + NTP_4_2_4P2_RC3 + + util/ntp-keygen-opts.texi@1.47.4.1 +1 -1 + NTP_4_2_4P2_RC3 + + util/ntp-keygen.1@1.47.4.1 +2 -2 + NTP_4_2_4P2_RC3 + +ChangeSet@1.1436.3.8, 2007-05-25 02:18:59-04:00, stenn@whimsy.udel.edu + cleanup + + NEWS@1.86.1.4 +1 -0 + cleanup + +ChangeSet@1.1436.4.1, 2007-05-25 02:06:52-04:00, stenn@whimsy.udel.edu + Upgraded autogen and libopts + + ChangeLog@1.1.3.1 +1 -0 + Upgraded autogen and libopts + + NEWS@1.86.1.3 +1 -0 + Upgraded autogen and libopts + +ChangeSet@1.1436.3.6, 2007-05-25 01:07:59-04:00, stenn@pogo.udel.edu + cleanup ChangeLog + + ChangeLog@1.1.2.3 +1 -1 + cleanup ChangeLog + +ChangeSet@1.1436.3.5, 2007-05-24 08:10:30-04:00, mayer@pogo.udel.edu + Bug #527 Don't write from source address length to wrong location + + ChangeLog@1.1.2.2 +1 -0 + Bug #527 Don't write from source address length to wrong location + +ChangeSet@1.1436.3.4, 2007-05-24 08:08:34-04:00, mayer@pogo.udel.edu + Bug #527 Don't write from source address length to wrong location + + include/recvbuff.h@1.11.1.1 +2 -0 + Bug #527 Don't write from source address length to wrong location + + libntp/recvbuff.c@1.25 +27 -13 + Bug #527 Don't write from source address length to wrong location + + ports/winnt/libntp/transmitbuff.c@1.7 +10 -10 + Bug #527 Don't write from source address length to wrong location + + ports/winnt/ntpd/ntp_iocompletionport.c@1.21.1.1 +76 -62 + Bug #527 Don't write from source address length to wrong location + +ChangeSet@1.1485.1.2, 2007-05-24 07:44:46-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P36 + TAG: NTP_4_2_5P36 + + ntpd/ntpd-opts.c@1.23 +2 -2 + NTP_4_2_5P36 + + ntpd/ntpd-opts.h@1.23 +3 -3 + NTP_4_2_5P36 + + ntpd/ntpd-opts.texi@1.22 +1 -1 + NTP_4_2_5P36 + + ntpd/ntpd.1@1.22 +2 -2 + NTP_4_2_5P36 + + ntpdc/ntpdc-opts.c@1.23 +2 -2 + NTP_4_2_5P36 + + ntpdc/ntpdc-opts.h@1.23 +3 -3 + NTP_4_2_5P36 + + ntpdc/ntpdc-opts.texi@1.22 +1 -1 + NTP_4_2_5P36 + + ntpdc/ntpdc.1@1.22 +2 -2 + NTP_4_2_5P36 + + ntpq/ntpq-opts.c@1.23 +2 -2 + NTP_4_2_5P36 + + ntpq/ntpq-opts.h@1.23 +3 -3 + NTP_4_2_5P36 + + ntpq/ntpq-opts.texi@1.22 +1 -1 + NTP_4_2_5P36 + + ntpq/ntpq.1@1.22 +2 -2 + NTP_4_2_5P36 + + packageinfo.sh@1.39 +1 -1 + NTP_4_2_5P36 + + sntp/sntp-opts.c@1.23 +2 -2 + NTP_4_2_5P36 + + sntp/sntp-opts.h@1.23 +3 -3 + NTP_4_2_5P36 + + sntp/sntp-opts.texi@1.22 +1 -1 + NTP_4_2_5P36 + + sntp/sntp.1@1.22 +2 -2 + NTP_4_2_5P36 + + util/ntp-keygen-opts.c@1.24 +2 -2 + NTP_4_2_5P36 + + util/ntp-keygen-opts.h@1.24 +3 -3 + NTP_4_2_5P36 + + util/ntp-keygen-opts.texi@1.23 +1 -1 + NTP_4_2_5P36 + + util/ntp-keygen.1@1.23 +2 -2 + NTP_4_2_5P36 + +ChangeSet@1.1485.1.1, 2007-05-24 01:38:12-04:00, stenn@whimsy.udel.edu + [Bug 832] Add libisc/log.c headers to the distribution. + + ChangeLog@1.47.1.1 +1 -0 + [Bug 832] Add libisc/log.c headers to the distribution. + + include/isc/Makefile.am@1.6 +6 -0 + [Bug 832] Add libisc/log.c headers to the distribution. + +ChangeSet@1.1486, 2007-05-22 15:19:42+00:00, burnicki@pogo.udel.edu + [Bug 824] Added the new parser modules to the Windows project file. + + ChangeLog@1.48 +1 -0 + Added the new parser modules to the Windows project file. + + ports/winnt/ntpd/ntpd.dsp@1.30 +12 -0 + Added the new parser modules to the Windows project file. + +ChangeSet@1.1485, 2007-05-21 07:44:27-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P35 + TAG: NTP_4_2_5P35 + + ntpd/ntpd-opts.c@1.22 +2 -2 + NTP_4_2_5P35 + + ntpd/ntpd-opts.h@1.22 +3 -3 + NTP_4_2_5P35 + + ntpd/ntpd-opts.texi@1.21 +1 -1 + NTP_4_2_5P35 + + ntpd/ntpd.1@1.21 +2 -2 + NTP_4_2_5P35 + + ntpdc/ntpdc-opts.c@1.22 +2 -2 + NTP_4_2_5P35 + + ntpdc/ntpdc-opts.h@1.22 +3 -3 + NTP_4_2_5P35 + + ntpdc/ntpdc-opts.texi@1.21 +1 -1 + NTP_4_2_5P35 + + ntpdc/ntpdc.1@1.21 +2 -2 + NTP_4_2_5P35 + + ntpq/ntpq-opts.c@1.22 +2 -2 + NTP_4_2_5P35 + + ntpq/ntpq-opts.h@1.22 +3 -3 + NTP_4_2_5P35 + + ntpq/ntpq-opts.texi@1.21 +1 -1 + NTP_4_2_5P35 + + ntpq/ntpq.1@1.21 +2 -2 + NTP_4_2_5P35 + + packageinfo.sh@1.38 +1 -1 + NTP_4_2_5P35 + + sntp/sntp-opts.c@1.22 +2 -2 + NTP_4_2_5P35 + + sntp/sntp-opts.h@1.22 +3 -3 + NTP_4_2_5P35 + + sntp/sntp-opts.texi@1.21 +1 -1 + NTP_4_2_5P35 + + sntp/sntp.1@1.21 +2 -2 + NTP_4_2_5P35 + + util/ntp-keygen-opts.c@1.23 +2 -2 + NTP_4_2_5P35 + + util/ntp-keygen-opts.h@1.23 +3 -3 + NTP_4_2_5P35 + + util/ntp-keygen-opts.texi@1.22 +1 -1 + NTP_4_2_5P35 + + util/ntp-keygen.1@1.22 +2 -2 + NTP_4_2_5P35 + +ChangeSet@1.1484, 2007-05-21 00:29:26-04:00, stenn@whimsy.udel.edu + [Bug 808] Only write the drift file if we are in state 4 + + ChangeLog@1.47 +1 -0 + [Bug 808] Only write the drift file if we are in state 4 + + ntpd/ntp_util.c@1.45 +27 -24 + [Bug 808] Only write the drift file if we are in state 4 + +ChangeSet@1.1483, 2007-05-20 21:52:55-04:00, stenn@whimsy.udel.edu + Initial import of libisc/log.c and friends + + libntp/Makefile.am@1.39 +1 -0 + Initial import of libisc/log.c and friends + +ChangeSet@1.1482, 2007-05-20 16:32:43-04:00, stenn@whimsy.udel.edu + Initial import of libisc/log.c and friends + + ChangeLog@1.46 +1 -0 + Initial import of libisc/log.c and friends + + include/isc/dir.h@1.1 +94 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/dir.h + + include/isc/dir.h@1.0 +0 -0 + + include/isc/file.h@1.1 +256 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/file.h + + include/isc/file.h@1.0 +0 -0 + + include/isc/log.h@1.1 +913 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/log.h + + include/isc/log.h@1.0 +0 -0 + + include/isc/stat.h@1.1 +52 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/stat.h + + include/isc/stat.h@1.0 +0 -0 + + include/isc/stdio.h@1.1 +77 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/stdio.h + + include/isc/stdio.h@1.0 +0 -0 + + include/isc/time.h@1.1 +304 -0 + BitKeeper file /deacon/backroom/ntp-dev/include/isc/time.h + + include/isc/time.h@1.0 +0 -0 + + libisc/log.c@1.1 +1762 -0 + BitKeeper file /deacon/backroom/ntp-dev/libisc/log.c + + libisc/log.c@1.0 +0 -0 + +ChangeSet@1.1436.3.3, 2007-05-19 07:53:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P2_RC2 + TAG: NTP_4_2_4P2_RC2 + + ntpd/ntpd-opts.c@1.50.3.2 +4 -4 + NTP_4_2_4P2_RC2 + + ntpd/ntpd-opts.h@1.50.3.2 +3 -3 + NTP_4_2_4P2_RC2 + + ntpd/ntpd-opts.texi@1.49.3.2 +1 -1 + NTP_4_2_4P2_RC2 + + ntpd/ntpd.1@1.48.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim-opts.c@1.50.3.2 +4 -4 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim-opts.h@1.50.3.2 +3 -3 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim-opts.texi@1.48.3.2 +1 -1 + NTP_4_2_4P2_RC2 + + ntpd/ntpdsim.1@1.48.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc-opts.c@1.50.3.2 +4 -4 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc-opts.h@1.50.3.2 +3 -3 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc-opts.texi@1.48.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + ntpdc/ntpdc.1@1.48.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + ntpq/ntpq-opts.c@1.52.3.2 +4 -4 + NTP_4_2_4P2_RC2 + + ntpq/ntpq-opts.h@1.52.3.2 +3 -3 + NTP_4_2_4P2_RC2 + + ntpq/ntpq-opts.texi@1.49.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + ntpq/ntpq.1@1.48.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + packageinfo.sh@1.65.9.3 +1 -1 + NTP_4_2_4P2_RC2 + + sntp/sntp-opts.c@1.49.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + sntp/sntp-opts.h@1.49.3.2 +3 -3 + NTP_4_2_4P2_RC2 + + sntp/sntp-opts.texi@1.46.3.2 +1 -1 + NTP_4_2_4P2_RC2 + + sntp/sntp.1@1.49.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + util/ntp-keygen-opts.c@1.49.3.2 +4 -4 + NTP_4_2_4P2_RC2 + + util/ntp-keygen-opts.h@1.49.3.2 +3 -3 + NTP_4_2_4P2_RC2 + + util/ntp-keygen-opts.texi@1.47.3.2 +2 -2 + NTP_4_2_4P2_RC2 + + util/ntp-keygen.1@1.47.3.2 +2 -2 + NTP_4_2_4P2_RC2 + +ChangeSet@1.1436.3.2, 2007-05-19 02:33:04-04:00, stenn@whimsy.udel.edu + We need another RC release to be sure the new autogen/libopts works. + + BitKeeper/deleted/.del-COPYING.lgpl~492b62c9d62ba57a@1.1.1.1 +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~adfa2ac04d64c0f7@1.1.1.1 +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd~7e1baaedfa33c877@1.1.1.1 +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~e8244dcf5895b58f@1.1.1.1 +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc~3fd54e9b117bfdad@1.1.1.1 +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~511eb438badc27b@1.1.1.1 +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~65692661e68a4392@1.1.1.1 +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~fdf1a715e04b5f2c@1.1.1.1 +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-README~7ed47aff36cc39c@1.1.1.1 +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-README~cec57621589d1ea6@1.1.1.1 +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-autoopts.c~7b48d6dc5ca9c3b@1.1.1.1 +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~917f3eb3a2030087@1.1.1.1 +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~4184ad33bbb8222@1.1.1.1 +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~d0834f397c8a330d@1.1.1.1 +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~50ae286fc516eee2@1.1.1.1 +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~afd23e01a43b9536@1.1.1.1 +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~2bcdd381f6a570a1@1.1.1.1 +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~e5d9fc11f0b928f2@1.1.1.1 +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~53384c73e434a615@1.1.1.1 +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~ee0b7d49d26b4f74@1.1.1.1 +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-cook.c~760181d2119b672@1.1.1.1 +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~84c1af00a5581292@1.1.1.1 +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c~551805256cb9068c@1.1.1.1 +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~969462e75e3913a3@1.1.1.1 +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~643ce1e5a16a4f94@1.1.1.1 +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-environment.c~965d8c0fdf1150f5@1.1.1.1 +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-genshell.c~20529138c60103c3@1.1.1.1 +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~bd74153097ec640f@1.1.1.1 +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~7f41539b135f914a@1.1.1.1 +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~b2793e1ea2981ff5@1.1.1.1 +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c~9353e1c3a0c56ad@1.1.1.1 +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~bfc74bb368a309be@1.1.1.1 +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~9851dd84df41023b@1.1.1.1 +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~9fa7e371d1cc0426@1.1.1.1 +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~1828e1c4576e5aea@1.1.1.1 +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~480d5c4f1634a9fa@1.1.1.1 +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~688d4934eb14272@1.1.1.1 +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-load.c~b6aa568c6e3eaca1@1.1.1.1 +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-makeshell.c~8c63bc5a263da752@1.1.1.1 +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~a9cd96c3bfbc0835@1.1.1.1 +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~1670193227f54043@1.1.1.1 +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-nested.c~a8521c8fcff292b6@1.1.1.1 +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~eb3fbec29633e61@1.1.1.1 +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~ec644fa246942cbc@1.1.1.1 +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-options.h~3cb6af32ad01957@1.1.1.1 +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~f700d69ce23e3e23@1.1.1.1 +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c~953a96dbc9932@1.1.1.1 +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~c132dab083075929@1.1.1.1 +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~5c1f8f132e9a1546@1.1.1.1 +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~cec1309617012832@1.1.1.1 +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~697b4937ff37ca3f@1.1.1.1 +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-proto.h~e2a13f546fbc0d4f@1.1.1.1 +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~6845ea506fad6426@1.1.1.1 +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~6e39e6836261f3f7@1.1.1.1 +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-restore.c~c14d8b96be44c6a8@1.1.1.1 +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~e2a155efceab6f0d@1.1.1.1 +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-save.c~17e5ac125a404fb0@1.1.1.1 +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-save.c~e7e7366cd24e1a8f@1.1.1.1 +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~4b42e45647e9ccef@1.1.1.1 +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~988df6799c67781f@1.1.1.1 +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c~586535d7d26d958@1.1.1.1 +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-sort.c~bb92da923b5dcb7@1.1.1.1 +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-stack.c~202d33ccdfd74ec@1.1.1.1 +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-stack.c~b60d0ab82970f41f@1.1.1.1 +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~4a7e412c18f53557@1.1.1.1 +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~7f4589858587fcc4@1.1.1.1 +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~75e27662f28944b1@1.1.1.1 +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~b295027011406c46@1.1.1.1 +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~999e9cfa251ea4b3@1.1.1.1 +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~dc5534ffb1c6f28@1.1.1.1 +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~52f2f1dbe57a9743@1.1.1.1 +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~e5096667484e499a@1.1.1.1 +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c~315c26f9b162f234@1.1.1.1 +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~6a814216fa293c3c@1.1.1.1 +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h~3737a7c76813e8c3@1.1.1.1 +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~b71acc916d68c58c@1.1.1.1 +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~f21924faa210bfa9@1.1.1.1 +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-usage.c~fe9a0f55b3cc55e4@1.1.1.1 +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-version.c~b69eccbdea7f51d9@1.1.1.1 +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~de7f014d3e2ac91e@1.1.1.1 +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~11a9a57b2895598f@1.1.1.1 +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~a6ead462c3d18ff0@1.1.1.1 +0 -0 + Delete: libopts/compat/windows-config.h + + clockstuff/clktest-opts.c@1.9.1.1 +38 -270 + We need to use the upgraded autogen/libopts in -stable too. + + clockstuff/clktest-opts.def@1.5.1.1 +4 -0 + We need to use the upgraded autogen/libopts in -stable too. + + clockstuff/clktest-opts.h@1.9.1.1 +22 -57 + We need to use the upgraded autogen/libopts in -stable too. + + include/autogen-version.def@1.4 +1 -1 + We need to use the upgraded autogen/libopts in -stable too. + + libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.lgpl + + libopts/COPYING.lgpl@1.0 +0 -0 + + libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0 +0 -0 + + libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0 +0 -0 + + libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/Makefile.am + + libopts/Makefile.am@1.0 +0 -0 + + libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/README + + libopts/README@1.0 +0 -0 + + libopts/autoopts.c@1.1 +1120 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.c + + libopts/autoopts.c@1.0 +0 -0 + + libopts/autoopts.h@1.1 +387 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.h + + libopts/autoopts.h@1.0 +0 -0 + + libopts/autoopts/options.h@1.1 +977 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0 +0 -0 + + libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0 +0 -0 + + libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/boolean.c + + libopts/boolean.c@1.0 +0 -0 + + libopts/compat/compat.h@1.1 +319 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/compat.h + + libopts/compat/compat.h@1.0 +0 -0 + + libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0 +0 -0 + + libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0 +0 -0 + + libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0 +0 -0 + + libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0 +0 -0 + + libopts/compat/windows-config.h@1.1 +130 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0 +0 -0 + + libopts/configfile.c@1.1 +1290 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/configfile.c + + libopts/configfile.c@1.0 +0 -0 + + libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/cook.c + + libopts/cook.c@1.0 +0 -0 + + libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/enumeration.c + + libopts/enumeration.c@1.0 +0 -0 + + libopts/environment.c@1.1 +279 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/environment.c + + libopts/environment.c@1.0 +0 -0 + + libopts/genshell.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.c + + libopts/genshell.c@1.0 +0 -0 + + libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.h + + libopts/genshell.h@1.0 +0 -0 + + libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/libopts.c + + libopts/libopts.c@1.0 +0 -0 + + libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/load.c + + libopts/load.c@1.0 +0 -0 + + libopts/m4/libopts.m4@1.1 +509 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0 +0 -0 + + libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0 +0 -0 + + libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/makeshell.c + + libopts/makeshell.c@1.0 +0 -0 + + libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/nested.c + + libopts/nested.c@1.0 +0 -0 + + libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/numeric.c + + libopts/numeric.c@1.0 +0 -0 + + libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/pgusage.c + + libopts/pgusage.c@1.0 +0 -0 + + libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/proto.h + + libopts/proto.h@1.0 +0 -0 + + libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/putshell.c + + libopts/putshell.c@1.0 +0 -0 + + libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/restore.c + + libopts/restore.c@1.0 +0 -0 + + libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/save.c + + libopts/save.c@1.0 +0 -0 + + libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/sort.c + + libopts/sort.c@1.0 +0 -0 + + libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/stack.c + + libopts/stack.c@1.0 +0 -0 + + libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0 +0 -0 + + libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/text_mmap.c + + libopts/text_mmap.c@1.0 +0 -0 + + libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/tokenize.c + + libopts/tokenize.c@1.0 +0 -0 + + libopts/usage.c@1.1 +740 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/usage.c + + libopts/usage.c@1.0 +0 -0 + + libopts/version.c@1.1 +178 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/version.c + + libopts/version.c@1.0 +0 -0 + + ntpd/ntpd-opts.c@1.50.3.1 +20 -11 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpd-opts.h@1.50.3.1 +4 -4 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpd-opts.texi@1.49.3.1 +2 -8 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpd.1@1.48.3.1 +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim-opts.c@1.50.3.1 +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim-opts.h@1.50.3.1 +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim-opts.texi@1.48.3.1 +1 -1 + We need to use the upgraded autogen/libopts in -stable too. + + ntpd/ntpdsim.1@1.48.3.1 +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc-opts.c@1.50.3.1 +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc-opts.h@1.50.3.1 +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc-opts.texi@1.48.3.1 +3 -3 + We need to use the upgraded autogen/libopts in -stable too. + + ntpdc/ntpdc.1@1.48.3.1 +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq-opts.c@1.52.3.1 +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq-opts.h@1.52.3.1 +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq-opts.texi@1.49.3.1 +3 -3 + We need to use the upgraded autogen/libopts in -stable too. + + ntpq/ntpq.1@1.48.3.1 +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + packageinfo.sh@1.65.9.2 +1 -1 + We need another RC release to be sure the new autogen/libopts works. + + sntp/libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.lgpl + + sntp/libopts/COPYING.lgpl@1.0 +0 -0 + + sntp/libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0 +0 -0 + + sntp/libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0 +0 -0 + + sntp/libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0 +0 -0 + + sntp/libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/README + + sntp/libopts/README@1.0 +0 -0 + + sntp/libopts/autoopts.c@1.1 +1120 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0 +0 -0 + + sntp/libopts/autoopts.h@1.1 +387 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0 +0 -0 + + sntp/libopts/autoopts/options.h@1.1 +977 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0 +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 + + sntp/libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0 +0 -0 + + sntp/libopts/compat/compat.h@1.1 +319 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0 +0 -0 + + sntp/libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0 +0 -0 + + sntp/libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0 +0 -0 + + sntp/libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0 +0 -0 + + sntp/libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0 +0 -0 + + sntp/libopts/compat/windows-config.h@1.1 +130 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0 +0 -0 + + sntp/libopts/configfile.c@1.1 +1290 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0 +0 -0 + + sntp/libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0 +0 -0 + + sntp/libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0 +0 -0 + + sntp/libopts/environment.c@1.1 +279 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0 +0 -0 + + sntp/libopts/genshell.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0 +0 -0 + + sntp/libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0 +0 -0 + + sntp/libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0 +0 -0 + + sntp/libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/load.c + + sntp/libopts/load.c@1.0 +0 -0 + + sntp/libopts/m4/libopts.m4@1.1 +509 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0 +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0 +0 -0 + + sntp/libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0 +0 -0 + + sntp/libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0 +0 -0 + + sntp/libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0 +0 -0 + + sntp/libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0 +0 -0 + + sntp/libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0 +0 -0 + + sntp/libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0 +0 -0 + + sntp/libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0 +0 -0 + + sntp/libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/save.c + + sntp/libopts/save.c@1.0 +0 -0 + + sntp/libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0 +0 -0 + + sntp/libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0 +0 -0 + + sntp/libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0 +0 -0 + + sntp/libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0 +0 -0 + + sntp/libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0 +0 -0 + + sntp/libopts/usage.c@1.1 +740 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0 +0 -0 + + sntp/libopts/version.c@1.1 +178 -0 + BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/version.c + + sntp/libopts/version.c@1.0 +0 -0 + + sntp/sntp-opts.c@1.49.3.1 +21 -12 + We need to use the upgraded autogen/libopts in -stable too. + + sntp/sntp-opts.h@1.49.3.1 +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + sntp/sntp-opts.texi@1.46.3.1 +1 -1 + We need to use the upgraded autogen/libopts in -stable too. + + sntp/sntp.1@1.49.3.1 +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen-opts.c@1.49.3.1 +23 -14 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen-opts.h@1.49.3.1 +6 -6 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen-opts.texi@1.47.3.1 +3 -3 + We need to use the upgraded autogen/libopts in -stable too. + + util/ntp-keygen.1@1.47.3.1 +2 -2 + We need to use the upgraded autogen/libopts in -stable too. + +ChangeSet@1.1436.3.1, 2007-05-18 02:20:56-04:00, stenn@whimsy.udel.edu + Release 4.2.4p2 + + ChangeLog@1.1.2.1 +4 -2 + Release 4.2.4p2 + + NEWS@1.86.1.2 +6 -0 + Release 4.2.4p2 + + packageinfo.sh@1.65.9.1 +1 -1 + Release 4.2.4p2 + +ChangeSet@1.1481, 2007-05-16 07:44:03-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P34 + TAG: NTP_4_2_5P34 + + ntpd/ntpd-opts.c@1.21 +2 -2 + NTP_4_2_5P34 + + ntpd/ntpd-opts.h@1.21 +5 -5 + NTP_4_2_5P34 + + ntpd/ntpd-opts.texi@1.20 +5 -5 + NTP_4_2_5P34 + + ntpd/ntpd.1@1.20 +4 -4 + NTP_4_2_5P34 + + ntpdc/ntpdc-opts.c@1.21 +2 -2 + NTP_4_2_5P34 + + ntpdc/ntpdc-opts.h@1.21 +3 -3 + NTP_4_2_5P34 + + ntpdc/ntpdc-opts.texi@1.20 +1 -1 + NTP_4_2_5P34 + + ntpdc/ntpdc.1@1.20 +2 -2 + NTP_4_2_5P34 + + ntpq/ntpq-opts.c@1.21 +2 -2 + NTP_4_2_5P34 + + ntpq/ntpq-opts.h@1.21 +3 -3 + NTP_4_2_5P34 + + ntpq/ntpq-opts.texi@1.20 +1 -1 + NTP_4_2_5P34 + + ntpq/ntpq.1@1.20 +2 -2 + NTP_4_2_5P34 + + packageinfo.sh@1.37 +1 -1 + NTP_4_2_5P34 + + sntp/sntp-opts.c@1.21 +2 -2 + NTP_4_2_5P34 + + sntp/sntp-opts.h@1.21 +3 -3 + NTP_4_2_5P34 + + sntp/sntp-opts.texi@1.20 +1 -1 + NTP_4_2_5P34 + + sntp/sntp.1@1.20 +2 -2 + NTP_4_2_5P34 + + util/ntp-keygen-opts.c@1.22 +2 -2 + NTP_4_2_5P34 + + util/ntp-keygen-opts.h@1.22 +3 -3 + NTP_4_2_5P34 + + util/ntp-keygen-opts.texi@1.21 +1 -1 + NTP_4_2_5P34 + + util/ntp-keygen.1@1.21 +2 -2 + NTP_4_2_5P34 + +ChangeSet@1.1480, 2007-05-16 03:56:15-04:00, stenn@whimsy.udel.edu + [Bug 826] Fix redefinition of PI + + ChangeLog@1.45 +1 -0 + [Bug 826] Fix redefinition of PI + +ChangeSet@1.1479, 2007-05-16 03:47:57-04:00, stenn@whimsy.udel.edu + [Bug 825] ntp_scanner.c needs to #include + + ChangeLog@1.44 +1 -0 + [Bug 825] ntp_scanner.c needs to #include + + ntpd/ntp_scanner.c@1.4 +4 -0 + [Bug 825] ntp_scanner.c needs to #include + +ChangeSet@1.1478, 2007-05-16 03:39:02-04:00, stenn@whimsy.udel.edu + [Bug 824] New parser code has some build problems with the SIM code. + + ChangeLog@1.43 +1 -0 + [Bug 824] New parser code has some build problems with the SIM code. + + include/ntp_config.h@1.45 +1 -5 + [Bug 824] New parser code has some build problems with the SIM code. + + include/ntpsim.h@1.9 +3 -4 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_config.c@1.151 +11 -0 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_data_structures.c@1.3 +1 -1 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_parser.c@1.6 +2 -2 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntp_parser.y@1.5 +1 -1 + [Bug 824] New parser code has some build problems with the SIM code. + + ntpd/ntpsim.c@1.17 +5 -2 + [Bug 824] New parser code has some build problems with the SIM code. + +ChangeSet@1.1477, 2007-05-16 00:49:12-04:00, stenn@whimsy.udel.edu + [Bug 817] Use longnames for setting ntp variables on the command-line + + ChangeLog@1.42 +3 -0 + [Bug 817] Use longnames for setting ntp variables on the command-line + + NEWS@1.91 +5 -0 + [Bug 817] Use longnames for setting ntp variables on the command-line + + ntpd/ntpdbase-opts.def@1.11 +2 -2 + [Bug 817] Use longnames for setting ntp variables on the command-line + +ChangeSet@1.1476, 2007-05-16 00:26:17-04:00, stenn@whimsy.udel.edu + [Bug 822] set progname once, early. + + ChangeLog@1.41 +1 -0 + [Bug 822] set progname once, early. + + ntpd/ntp_config.c@1.150 +0 -1 + [Bug 822] set progname once, early. + +ChangeSet@1.1475, 2007-05-15 07:43:16-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P33 + TAG: NTP_4_2_5P33 + + ntpd/ntpd-opts.c@1.20 +2 -2 + NTP_4_2_5P33 + + ntpd/ntpd-opts.h@1.20 +3 -3 + NTP_4_2_5P33 + + ntpd/ntpd-opts.texi@1.19 +1 -1 + NTP_4_2_5P33 + + ntpd/ntpd.1@1.19 +2 -2 + NTP_4_2_5P33 + + ntpdc/ntpdc-opts.c@1.20 +2 -2 + NTP_4_2_5P33 + + ntpdc/ntpdc-opts.h@1.20 +3 -3 + NTP_4_2_5P33 + + ntpdc/ntpdc-opts.texi@1.19 +1 -1 + NTP_4_2_5P33 + + ntpdc/ntpdc.1@1.19 +2 -2 + NTP_4_2_5P33 + + ntpq/ntpq-opts.c@1.20 +2 -2 + NTP_4_2_5P33 + + ntpq/ntpq-opts.h@1.20 +3 -3 + NTP_4_2_5P33 + + ntpq/ntpq-opts.texi@1.19 +1 -1 + NTP_4_2_5P33 + + ntpq/ntpq.1@1.19 +2 -2 + NTP_4_2_5P33 + + packageinfo.sh@1.36 +1 -1 + NTP_4_2_5P33 + + sntp/sntp-opts.c@1.20 +2 -2 + NTP_4_2_5P33 + + sntp/sntp-opts.h@1.20 +3 -3 + NTP_4_2_5P33 + + sntp/sntp-opts.texi@1.19 +1 -1 + NTP_4_2_5P33 + + sntp/sntp.1@1.19 +2 -2 + NTP_4_2_5P33 + + util/ntp-keygen-opts.c@1.21 +2 -2 + NTP_4_2_5P33 + + util/ntp-keygen-opts.h@1.21 +3 -3 + NTP_4_2_5P33 + + util/ntp-keygen-opts.texi@1.20 +1 -1 + NTP_4_2_5P33 + + util/ntp-keygen.1@1.20 +2 -2 + NTP_4_2_5P33 + +ChangeSet@1.1474, 2007-05-15 06:42:51-04:00, stenn@pogo.udel.edu + Correct ChangeLog entry format + + ChangeLog@1.40 +1 -1 + Correct ChangeLog entry format + +ChangeSet@1.1473, 2007-05-14 16:58:33-04:00, mayer@pogo.udel.edu + Bug 819 remove erroneous #if 0 in Windows code + + ChangeLog@1.39 +1 -0 + Bug 819 remove erroneous #if 0 in Windows code + + ports/winnt/ntpd/ntp_iocompletionport.c@1.23 +0 -2 + Bug 819 remove erroneous #if 0 + +ChangeSet@1.1472, 2007-05-13 07:43:28-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P32 + TAG: NTP_4_2_5P32 + + ntpd/ntpd-opts.c@1.19 +2 -2 + NTP_4_2_5P32 + + ntpd/ntpd-opts.h@1.19 +3 -3 + NTP_4_2_5P32 + + ntpd/ntpd-opts.texi@1.18 +1 -1 + NTP_4_2_5P32 + + ntpd/ntpd.1@1.18 +2 -2 + NTP_4_2_5P32 + + ntpdc/ntpdc-opts.c@1.19 +2 -2 + NTP_4_2_5P32 + + ntpdc/ntpdc-opts.h@1.19 +3 -3 + NTP_4_2_5P32 + + ntpdc/ntpdc-opts.texi@1.18 +1 -1 + NTP_4_2_5P32 + + ntpdc/ntpdc.1@1.18 +2 -2 + NTP_4_2_5P32 + + ntpq/ntpq-opts.c@1.19 +2 -2 + NTP_4_2_5P32 + + ntpq/ntpq-opts.h@1.19 +3 -3 + NTP_4_2_5P32 + + ntpq/ntpq-opts.texi@1.18 +1 -1 + NTP_4_2_5P32 + + ntpq/ntpq.1@1.18 +2 -2 + NTP_4_2_5P32 + + packageinfo.sh@1.35 +1 -1 + NTP_4_2_5P32 + + sntp/sntp-opts.c@1.19 +2 -2 + NTP_4_2_5P32 + + sntp/sntp-opts.h@1.19 +3 -3 + NTP_4_2_5P32 + + sntp/sntp-opts.texi@1.18 +1 -1 + NTP_4_2_5P32 + + sntp/sntp.1@1.18 +2 -2 + NTP_4_2_5P32 + + util/ntp-keygen-opts.c@1.20 +2 -2 + NTP_4_2_5P32 + + util/ntp-keygen-opts.h@1.20 +3 -3 + NTP_4_2_5P32 + + util/ntp-keygen-opts.texi@1.19 +1 -1 + NTP_4_2_5P32 + + util/ntp-keygen.1@1.19 +2 -2 + NTP_4_2_5P32 + +ChangeSet@1.1471, 2007-05-13 03:42:41-04:00, stenn@whimsy.udel.edu + The new config code missed an #ifdef for building without refclocks + + ChangeLog@1.38 +1 -0 + The new config code missed an #ifdef for building without refclocks + + ntpd/ntp_config.c@1.149 +4 -0 + The new config code missed an #ifdef for building without refclocks + +ChangeSet@1.1470, 2007-05-13 00:04:25-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P31 + TAG: NTP_4_2_5P31 + + ntpd/ntpd-opts.c@1.18 +2 -2 + NTP_4_2_5P31 + + ntpd/ntpd-opts.h@1.18 +3 -3 + NTP_4_2_5P31 + + ntpd/ntpd-opts.texi@1.17 +1 -1 + NTP_4_2_5P31 + + ntpd/ntpd.1@1.17 +2 -2 + NTP_4_2_5P31 + + ntpdc/ntpdc-opts.c@1.18 +2 -2 + NTP_4_2_5P31 + + ntpdc/ntpdc-opts.h@1.18 +3 -3 + NTP_4_2_5P31 + + ntpdc/ntpdc-opts.texi@1.17 +1 -1 + NTP_4_2_5P31 + + ntpdc/ntpdc.1@1.17 +2 -2 + NTP_4_2_5P31 + + ntpq/ntpq-opts.c@1.18 +2 -2 + NTP_4_2_5P31 + + ntpq/ntpq-opts.h@1.18 +3 -3 + NTP_4_2_5P31 + + ntpq/ntpq-opts.texi@1.17 +1 -1 + NTP_4_2_5P31 + + ntpq/ntpq.1@1.17 +2 -2 + NTP_4_2_5P31 + + packageinfo.sh@1.34 +1 -1 + NTP_4_2_5P31 + + sntp/sntp-opts.c@1.18 +2 -2 + NTP_4_2_5P31 + + sntp/sntp-opts.h@1.18 +3 -3 + NTP_4_2_5P31 + + sntp/sntp-opts.texi@1.17 +1 -1 + NTP_4_2_5P31 + + sntp/sntp.1@1.17 +2 -2 + NTP_4_2_5P31 + + util/ntp-keygen-opts.c@1.19 +2 -2 + NTP_4_2_5P31 + + util/ntp-keygen-opts.h@1.19 +3 -3 + NTP_4_2_5P31 + + util/ntp-keygen-opts.texi@1.18 +1 -1 + NTP_4_2_5P31 + + util/ntp-keygen.1@1.18 +2 -2 + NTP_4_2_5P31 + +ChangeSet@1.1469, 2007-05-12 23:13:08-04:00, stenn@whimsy.udel.edu + Distribute some files needed by the new config parsing code + + ChangeLog@1.37 +1 -0 + Distribute some files needed by the new config parsing code + + include/Makefile.am@1.27 +1 -0 + Distribute some files needed by the new config parsing code + + ntpd/Makefile.am@1.59 +2 -1 + Distribute some files needed by the new config parsing code + +ChangeSet@1.1468, 2007-05-12 20:05:36-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P30 + TAG: NTP_4_2_5P30 + + ntpd/ntpd-opts.c@1.17 +19 -10 + NTP_4_2_5P30 + + ntpd/ntpd-opts.h@1.17 +6 -6 + NTP_4_2_5P30 + + ntpd/ntpd-opts.texi@1.16 +2 -2 + NTP_4_2_5P30 + + ntpd/ntpd.1@1.16 +2 -2 + NTP_4_2_5P30 + + ntpdc/ntpdc-opts.c@1.17 +22 -13 + NTP_4_2_5P30 + + ntpdc/ntpdc-opts.h@1.17 +8 -8 + NTP_4_2_5P30 + + ntpdc/ntpdc-opts.texi@1.16 +2 -2 + NTP_4_2_5P30 + + ntpdc/ntpdc.1@1.16 +2 -2 + NTP_4_2_5P30 + + ntpq/ntpq-opts.c@1.17 +22 -13 + NTP_4_2_5P30 + + ntpq/ntpq-opts.h@1.17 +8 -8 + NTP_4_2_5P30 + + ntpq/ntpq-opts.texi@1.16 +2 -2 + NTP_4_2_5P30 + + ntpq/ntpq.1@1.16 +2 -2 + NTP_4_2_5P30 + + packageinfo.sh@1.33 +1 -1 + NTP_4_2_5P30 + + sntp/sntp-opts.c@1.17 +22 -13 + NTP_4_2_5P30 + + sntp/sntp-opts.h@1.17 +8 -8 + NTP_4_2_5P30 + + sntp/sntp-opts.texi@1.16 +1 -1 + NTP_4_2_5P30 + + sntp/sntp.1@1.16 +2 -2 + NTP_4_2_5P30 + + util/ntp-keygen-opts.c@1.18 +22 -13 + NTP_4_2_5P30 + + util/ntp-keygen-opts.h@1.18 +8 -8 + NTP_4_2_5P30 + + util/ntp-keygen-opts.texi@1.17 +2 -2 + NTP_4_2_5P30 + + util/ntp-keygen.1@1.17 +2 -2 + NTP_4_2_5P30 + +ChangeSet@1.1467, 2007-05-12 18:51:18-04:00, stenn@whimsy.udel.edu + ntpdsim does not need a separate.def file anymore + + .point-changed-filelist@1.2 +0 -4 + ntpdsim does not need a separate.def file anymore + +ChangeSet@1.1464.1.3, 2007-05-12 15:20:21-04:00, stenn@whimsy.udel.edu + update ChangeLog + + ChangeLog@1.34.1.1 +2 -0 + update + +ChangeSet@1.1464.1.2, 2007-05-12 15:11:16-04:00, stenn@whimsy.udel.edu + ntpdsim still needs to be linked with libntpsim.a + + ntpd/Makefile.am@1.58 +1 -1 + ntpdsim still needs to be linked with libntpsim.a + +ChangeSet@1.1464.1.1, 2007-05-12 15:03:30-04:00, stenn@whimsy.udel.edu + The commandline args for clktest are different for CLKLDISC and STREAM + + BitKeeper/deleted/.del-COPYING.lgpl~10cb8d69d91c1d1a@1.2 +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~28a379c1d0a7d65b@1.2 +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd~533e88f3b3fcf954@1.2 +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~b64c211489c98f8f@1.2 +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc~1864382369b1f319@1.2 +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~834c15d5a9c89a66@1.2 +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am~1b934e5bbc1a52da@1.2 +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~6ccd1a00699fb256@1.2 +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-README~92b3aeada81a2d71@1.2 +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-README~b514dee5178a5580@1.2 +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-autoopts.c~a46d961b536d64bf@1.2 +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~bf6955d92ba49ae1@1.2 +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h~23dbdb3099b1cca4@1.2 +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~747513602f92fac1@1.2 +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c~94ccecb255a48b6e@1.2 +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~f7c50fbef5ac98e0@1.2 +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-compat.h~304782365980b0a6@1.2 +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~395225886f65b320@1.2 +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c~9bf9a8e83a3bd417@1.2 +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~c3073ecc386accae@1.2 +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-cook.c~aaac2f8aa56207ea@1.2 +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-cook.c~ab79f9ba24a65414@1.2 +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c~712ed026511a4fad@1.2 +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~8a49e92b5bc59603@1.2 +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c~8c989df39464c6e6@1.2 +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-environment.c~d00f13b319acf94@1.2 +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-genshell.c~8eefb6dfb144e83@1.2 +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~d7f99fb1e982ee07@1.2 +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h~51e39da43a911455@1.2 +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~d288760f8010eb26@1.2 +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c~58110c12582b3028@1.2 +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~752b4eb28ce283b5@1.2 +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4~3768711f3ababaf6@1.2 +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~3ff78500945f8450@1.2 +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4~7fc066e5c8ec737b@1.2 +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~874c63212488adfb@1.2 +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-load.c~5266a52b9cc7c4c@1.2 +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-load.c~a2d76f9cb0ad15c2@1.2 +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-makeshell.c~29fe57c8fbbb00e3@1.2 +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~fc83cd9174e79990@1.2 +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c~28f13939b51c52fd@1.2 +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-nested.c~b140b093a1d64d9@1.2 +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-numeric.c~65425d5a1d1c4bfe@1.2 +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~999e8ac5e2da8761@1.2 +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-options.h~5da7e2edf4e59b5a@1.2 +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~b9d54ea51e67a003@1.2 +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c~3b1936ad642daffc@1.2 +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~a2ca5c6362091a22@1.2 +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c~b5c6b4ec94715759@1.2 +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~d5c1858d8398fae@1.2 +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h~154b3828fc24cf61@1.2 +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-proto.h~a1f40edb75ffe53a@1.2 +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c~a5873e4bd316e7ed@1.2 +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~e6ab712597a00d22@1.2 +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-restore.c~5d8d9d9524a773de@1.2 +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-restore.c~88a5fde95bcff4ab@1.2 +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-save.c~be7b0aaf121ec52c@1.2 +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-save.c~c6c15efe6c1d79fd@1.2 +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-snprintf.c~755eb3e8b8fdc776@1.2 +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~bd80dbf654a1386@1.2 +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c~3107cfeb6d4410e0@1.2 +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-sort.c~fd8c39deb0ab5d4f@1.2 +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-stack.c~311ef6ab451f1f6@1.2 +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-stack.c~63cca8b0f353d8f2@1.2 +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-strchr.c~9747020ee65f676@1.2 +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~ee7c33848acad72@1.2 +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c~b372303835eae985@1.2 +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~f0c4c4c41ddd1a3@1.2 +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c~73dcf75bcf91f8b9@1.2 +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~a7f96578aba73fa7@1.2 +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c~54ffd8e6a894fd3a@1.2 +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~a418cd03686e4369@1.2 +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c~383b75d922a43542@1.2 +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~a0a274ef5a23941b@1.2 +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h~2e88ec29a506e890@1.2 +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~d982bb81a1b02298@1.2 +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c~1108ba561360111a@1.2 +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-usage.c~f5dfbb0ffd6bfc47@1.2 +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-version.c~2149af8e100594bb@1.2 +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-version.c~d6d1f6f786b289e3@1.2 +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-windows-config.h~49e33bce6ec73aa9@1.2 +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~70a3d851a9350311@1.2 +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + clockstuff/clktest-opts.def@1.6 +4 -0 + The commandline args for clktest are different for CLKLDISC and STREAM + + libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.lgpl + + libopts/COPYING.lgpl@1.0 +0 -0 + + libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0 +0 -0 + + libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0 +0 -0 + + libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/Makefile.am + + libopts/Makefile.am@1.0 +0 -0 + + libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/README + + libopts/README@1.0 +0 -0 + + libopts/autoopts.c@1.1 +1120 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.c + + libopts/autoopts.c@1.0 +0 -0 + + libopts/autoopts.h@1.1 +387 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.h + + libopts/autoopts.h@1.0 +0 -0 + + libopts/autoopts/options.h@1.1 +977 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0 +0 -0 + + libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0 +0 -0 + + libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/boolean.c + + libopts/boolean.c@1.0 +0 -0 + + libopts/compat/compat.h@1.1 +319 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/compat.h + + libopts/compat/compat.h@1.0 +0 -0 + + libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0 +0 -0 + + libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0 +0 -0 + + libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0 +0 -0 + + libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0 +0 -0 + + libopts/compat/windows-config.h@1.1 +130 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0 +0 -0 + + libopts/configfile.c@1.1 +1290 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/configfile.c + + libopts/configfile.c@1.0 +0 -0 + + libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/cook.c + + libopts/cook.c@1.0 +0 -0 + + libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/enumeration.c + + libopts/enumeration.c@1.0 +0 -0 + + libopts/environment.c@1.1 +279 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/environment.c + + libopts/environment.c@1.0 +0 -0 + + libopts/genshell.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.c + + libopts/genshell.c@1.0 +0 -0 + + libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.h + + libopts/genshell.h@1.0 +0 -0 + + libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/libopts.c + + libopts/libopts.c@1.0 +0 -0 + + libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/load.c + + libopts/load.c@1.0 +0 -0 + + libopts/m4/libopts.m4@1.1 +509 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0 +0 -0 + + libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0 +0 -0 + + libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/makeshell.c + + libopts/makeshell.c@1.0 +0 -0 + + libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/nested.c + + libopts/nested.c@1.0 +0 -0 + + libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/numeric.c + + libopts/numeric.c@1.0 +0 -0 + + libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/pgusage.c + + libopts/pgusage.c@1.0 +0 -0 + + libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/proto.h + + libopts/proto.h@1.0 +0 -0 + + libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/putshell.c + + libopts/putshell.c@1.0 +0 -0 + + libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/restore.c + + libopts/restore.c@1.0 +0 -0 + + libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/save.c + + libopts/save.c@1.0 +0 -0 + + libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/sort.c + + libopts/sort.c@1.0 +0 -0 + + libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/stack.c + + libopts/stack.c@1.0 +0 -0 + + libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0 +0 -0 + + libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/text_mmap.c + + libopts/text_mmap.c@1.0 +0 -0 + + libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/tokenize.c + + libopts/tokenize.c@1.0 +0 -0 + + libopts/usage.c@1.1 +740 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/usage.c + + libopts/usage.c@1.0 +0 -0 + + libopts/version.c@1.1 +178 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/version.c + + libopts/version.c@1.0 +0 -0 + + sntp/libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.lgpl + + sntp/libopts/COPYING.lgpl@1.0 +0 -0 + + sntp/libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.mbsd + + sntp/libopts/COPYING.mbsd@1.0 +0 -0 + + sntp/libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/MakeDefs.inc + + sntp/libopts/MakeDefs.inc@1.0 +0 -0 + + sntp/libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/Makefile.am + + sntp/libopts/Makefile.am@1.0 +0 -0 + + sntp/libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/README + + sntp/libopts/README@1.0 +0 -0 + + sntp/libopts/autoopts.c@1.1 +1120 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.c + + sntp/libopts/autoopts.c@1.0 +0 -0 + + sntp/libopts/autoopts.h@1.1 +387 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.h + + sntp/libopts/autoopts.h@1.0 +0 -0 + + sntp/libopts/autoopts/options.h@1.1 +977 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/options.h + + sntp/libopts/autoopts/options.h@1.0 +0 -0 + + sntp/libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/usage-txt.h + + sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 + + sntp/libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/boolean.c + + sntp/libopts/boolean.c@1.0 +0 -0 + + sntp/libopts/compat/compat.h@1.1 +319 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/compat.h + + sntp/libopts/compat/compat.h@1.0 +0 -0 + + sntp/libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/pathfind.c + + sntp/libopts/compat/pathfind.c@1.0 +0 -0 + + sntp/libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/snprintf.c + + sntp/libopts/compat/snprintf.c@1.0 +0 -0 + + sntp/libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strchr.c + + sntp/libopts/compat/strchr.c@1.0 +0 -0 + + sntp/libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strdup.c + + sntp/libopts/compat/strdup.c@1.0 +0 -0 + + sntp/libopts/compat/windows-config.h@1.1 +130 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h + + sntp/libopts/compat/windows-config.h@1.0 +0 -0 + + sntp/libopts/configfile.c@1.1 +1290 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/configfile.c + + sntp/libopts/configfile.c@1.0 +0 -0 + + sntp/libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/cook.c + + sntp/libopts/cook.c@1.0 +0 -0 + + sntp/libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/enumeration.c + + sntp/libopts/enumeration.c@1.0 +0 -0 + + sntp/libopts/environment.c@1.1 +279 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/environment.c + + sntp/libopts/environment.c@1.0 +0 -0 + + sntp/libopts/genshell.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.c + + sntp/libopts/genshell.c@1.0 +0 -0 + + sntp/libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.h + + sntp/libopts/genshell.h@1.0 +0 -0 + + sntp/libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/libopts.c + + sntp/libopts/libopts.c@1.0 +0 -0 + + sntp/libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/load.c + + sntp/libopts/load.c@1.0 +0 -0 + + sntp/libopts/m4/libopts.m4@1.1 +509 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/libopts.m4 + + sntp/libopts/m4/libopts.m4@1.0 +0 -0 + + sntp/libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/liboptschk.m4 + + sntp/libopts/m4/liboptschk.m4@1.0 +0 -0 + + sntp/libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/makeshell.c + + sntp/libopts/makeshell.c@1.0 +0 -0 + + sntp/libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/nested.c + + sntp/libopts/nested.c@1.0 +0 -0 + + sntp/libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/numeric.c + + sntp/libopts/numeric.c@1.0 +0 -0 + + sntp/libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/pgusage.c + + sntp/libopts/pgusage.c@1.0 +0 -0 + + sntp/libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/proto.h + + sntp/libopts/proto.h@1.0 +0 -0 + + sntp/libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/putshell.c + + sntp/libopts/putshell.c@1.0 +0 -0 + + sntp/libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/restore.c + + sntp/libopts/restore.c@1.0 +0 -0 + + sntp/libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/save.c + + sntp/libopts/save.c@1.0 +0 -0 + + sntp/libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/sort.c + + sntp/libopts/sort.c@1.0 +0 -0 + + sntp/libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/stack.c + + sntp/libopts/stack.c@1.0 +0 -0 + + sntp/libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/streqvcmp.c + + sntp/libopts/streqvcmp.c@1.0 +0 -0 + + sntp/libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/text_mmap.c + + sntp/libopts/text_mmap.c@1.0 +0 -0 + + sntp/libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/tokenize.c + + sntp/libopts/tokenize.c@1.0 +0 -0 + + sntp/libopts/usage.c@1.1 +740 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/usage.c + + sntp/libopts/usage.c@1.0 +0 -0 + + sntp/libopts/version.c@1.1 +178 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/version.c + + sntp/libopts/version.c@1.0 +0 -0 + +ChangeSet@1.1465, 2007-05-12 12:29:54-04:00, mayer@pogo.udel.edu + Bug 819 - Timeout for WaitForMultipleObjects was set to 500ms instead of INFINITE + + ChangeLog@1.35 +1 -0 + Bug 819 - Timeout for WaitForMultipleObjects was set to 500ms instead of INFINITE + + ports/winnt/ntpd/ntp_iocompletionport.c@1.22 +1 -2 + Bug 819 - Timeout for WaitForMultipleObjects was set to 500ms instead of INFINITE + +ChangeSet@1.1464, 2007-05-10 18:45:48-04:00, stenn@whimsy.udel.edu + Audio documentation updates from Dave Mills + + ChangeLog@1.34 +1 -0 + Audio documentation updates from Dave Mills + + html/audio.html@1.19 +5 -6 + Audio documentation updates from Dave Mills + + html/drivers/driver36.html@1.32 +6 -6 + Audio documentation updates from Dave Mills + + html/drivers/driver6.html@1.24 +3 -3 + Audio documentation updates from Dave Mills + + html/drivers/driver7.html@1.26 +4 -5 + Audio documentation updates from Dave Mills + +ChangeSet@1.1463, 2007-05-09 23:39:05-04:00, stenn@whimsy.udel.edu + refenerate ntp_parser.c + + ntpd/ntp_parser.c@1.5 +260 -236 + regenerate .y->.c file + +ChangeSet@1.1462, 2007-05-09 20:42:07-04:00, stenn@pogo.udel.edu + Build even if no OPENSSL + + ntpd/ntp_config.c@1.148 +12 -2 + Build even if no OPENSSL + + ntpd/ntp_parser.y@1.4 +23 -0 + Build even if no OPENSSL + +ChangeSet@1.1440.1.99, 2007-05-09 16:23:14-04:00, stenn@whimsy.udel.edu + More fuzz bit cleanup from Dave Mills + + ChangeLog@1.31.1.2 +2 -1 + More fuzz bit cleanup from Dave Mills + + libntp/systime.c@1.38.1.2 +18 -16 + More fuzz bit cleanup from Dave Mills + +ChangeSet@1.1440.1.98, 2007-05-09 07:42:10-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P29 + TAG: NTP_4_2_5P29 + + ntpd/ntpd-opts.c@1.16 +2 -2 + NTP_4_2_5P29 + + ntpd/ntpd-opts.h@1.16 +3 -3 + NTP_4_2_5P29 + + ntpd/ntpd-opts.texi@1.15 +2 -2 + NTP_4_2_5P29 + + ntpd/ntpd.1@1.15 +2 -2 + NTP_4_2_5P29 + + ntpd/ntpdsim-opts.c@1.16 +2 -2 + NTP_4_2_5P29 + + ntpd/ntpdsim-opts.h@1.16 +3 -3 + NTP_4_2_5P29 + + ntpd/ntpdsim-opts.texi@1.15 +1 -1 + NTP_4_2_5P29 + + ntpd/ntpdsim.1@1.15 +2 -2 + NTP_4_2_5P29 + + ntpdc/ntpdc-opts.c@1.16 +2 -2 + NTP_4_2_5P29 + + ntpdc/ntpdc-opts.h@1.16 +3 -3 + NTP_4_2_5P29 + + ntpdc/ntpdc-opts.texi@1.15 +2 -2 + NTP_4_2_5P29 + + ntpdc/ntpdc.1@1.15 +2 -2 + NTP_4_2_5P29 + + ntpq/ntpq-opts.c@1.16 +2 -2 + NTP_4_2_5P29 + + ntpq/ntpq-opts.h@1.16 +3 -3 + NTP_4_2_5P29 + + ntpq/ntpq-opts.texi@1.15 +2 -2 + NTP_4_2_5P29 + + ntpq/ntpq.1@1.15 +2 -2 + NTP_4_2_5P29 + + packageinfo.sh@1.32 +1 -1 + NTP_4_2_5P29 + + sntp/sntp-opts.c@1.16 +2 -2 + NTP_4_2_5P29 + + sntp/sntp-opts.h@1.16 +3 -3 + NTP_4_2_5P29 + + sntp/sntp-opts.texi@1.15 +1 -1 + NTP_4_2_5P29 + + sntp/sntp.1@1.15 +2 -2 + NTP_4_2_5P29 + + util/ntp-keygen-opts.c@1.17 +2 -2 + NTP_4_2_5P29 + + util/ntp-keygen-opts.h@1.17 +3 -3 + NTP_4_2_5P29 + + util/ntp-keygen-opts.texi@1.16 +2 -2 + NTP_4_2_5P29 + + util/ntp-keygen.1@1.16 +2 -2 + NTP_4_2_5P29 + +ChangeSet@1.1440.1.97, 2007-05-09 05:19:46-04:00, stenn@whimsy.udel.edu + Added the ChangeLog entry from the previous commit + + ChangeLog@1.31.1.1 +1 -0 + Added the ChangeLog entry from the previous commit + +ChangeSet@1.1459, 2007-05-08 20:32:56-04:00, stenn@pogo.udel.edu + Protect some "debug" references + + ntpd/ntp_control.c@1.93 +3 -0 + Protect some "debug" references + + ntpd/ntp_scanner.c@1.3 +4 -2 + Protect some "debug" references + +ChangeSet@1.1440.1.96, 2007-05-07 07:42:57-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P28 + TAG: NTP_4_2_5P28 + + ntpd/ntpd-opts.c@1.15 +2 -2 + NTP_4_2_5P28 + + ntpd/ntpd-opts.h@1.15 +3 -3 + NTP_4_2_5P28 + + ntpd/ntpd-opts.texi@1.14 +1 -1 + NTP_4_2_5P28 + + ntpd/ntpd.1@1.14 +2 -2 + NTP_4_2_5P28 + + ntpd/ntpdsim-opts.c@1.15 +2 -2 + NTP_4_2_5P28 + + ntpd/ntpdsim-opts.h@1.15 +3 -3 + NTP_4_2_5P28 + + ntpd/ntpdsim-opts.texi@1.14 +1 -1 + NTP_4_2_5P28 + + ntpd/ntpdsim.1@1.14 +2 -2 + NTP_4_2_5P28 + + ntpdc/ntpdc-opts.c@1.15 +2 -2 + NTP_4_2_5P28 + + ntpdc/ntpdc-opts.h@1.15 +3 -3 + NTP_4_2_5P28 + + ntpdc/ntpdc-opts.texi@1.14 +1 -1 + NTP_4_2_5P28 + + ntpdc/ntpdc.1@1.14 +2 -2 + NTP_4_2_5P28 + + ntpq/ntpq-opts.c@1.15 +2 -2 + NTP_4_2_5P28 + + ntpq/ntpq-opts.h@1.15 +3 -3 + NTP_4_2_5P28 + + ntpq/ntpq-opts.texi@1.14 +1 -1 + NTP_4_2_5P28 + + ntpq/ntpq.1@1.14 +2 -2 + NTP_4_2_5P28 + + packageinfo.sh@1.31 +1 -1 + NTP_4_2_5P28 + + sntp/sntp-opts.c@1.15 +2 -2 + NTP_4_2_5P28 + + sntp/sntp-opts.h@1.15 +3 -3 + NTP_4_2_5P28 + + sntp/sntp-opts.texi@1.14 +1 -1 + NTP_4_2_5P28 + + sntp/sntp.1@1.14 +2 -2 + NTP_4_2_5P28 + + util/ntp-keygen-opts.c@1.16 +2 -2 + NTP_4_2_5P28 + + util/ntp-keygen-opts.h@1.16 +3 -3 + NTP_4_2_5P28 + + util/ntp-keygen-opts.texi@1.15 +1 -1 + NTP_4_2_5P28 + + util/ntp-keygen.1@1.15 +2 -2 + NTP_4_2_5P28 + +ChangeSet@1.1440.1.95, 2007-05-07 06:43:34-04:00, stenn@whimsy.udel.edu + replay cleanup from Dave Mills + + ntpd/ntp_proto.c@1.252 +15 -18 + replay cleanup from Dave Mills + +ChangeSet@1.1440.1.94, 2007-05-07 06:35:26-04:00, stenn@whimsy.udel.edu + Cleanup random fuzz bits. (Dave Mills) + + libntp/systime.c@1.38.1.1 +7 -15 + Cleanup random fuzz bits. (Dave Mills) + +ChangeSet@1.1458, 2007-05-05 22:28:37-04:00, stenn@pogo.udel.edu + New config file parsing code + + ChangeLog@1.32 +1 -0 + New config file parsing code + +ChangeSet@1.1457, 2007-05-05 14:29:11-04:00, stenn@pogo.udel.edu + bootstrap yacc/bison files + + bootstrap@1.19 +4 -0 + bootstrap yacc/bison files + +ChangeSet@1.1455, 2007-05-05 14:15:36-04:00, stenn@pogo.udel.edu + OPENSSL and DEBUG cleanup + + ntpd/ntp_config.c@1.147 +6 -0 + OPENSSL and DEBUG cleanup + +ChangeSet@1.1436.1.46, 2007-04-28 10:19:57+00:00, kardel@pogo.udel.edu + ntp_peer.c: + Bug 789 (backported from ntp-dev): + Fix multicast client crypto authentication and make sure arriving + multicast packets do not disturb the autokey dance. + ChangeLog: + Bug 789 (backported from ntp-dev): + Fix multicast client crypto authentication and make sure arriving + multicast packets do not disturb the autokey dance. + + ChangeLog@1.1.1.12 +4 -1 + Bug 789: + Fix multicast client crypto authentication and make sure arriving + multicast packets do not disturb the autokey dance. + + ntpd/ntp_peer.c@1.97.1.2 +21 -12 + Bug 789 (backported from ntp-dev): + fix multicast client mode by re-setting + crypto information only when the local address + changes and not for BCLNTs. + Addtitionally don't update the local address while + a BCLNT is doing the autokey dance. + +ChangeSet@1.1436.1.45, 2007-04-28 10:03:26+00:00, kardel@pogo.udel.edu + ntp_io.c, ChangeLog: + bug 785 (backport from ntp-dev): + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + ntp_peer.c: + bug 785 (backport from ntp-dev): + clarify debug messages + + ChangeLog@1.1.1.11 +1 -0 + bug 785 (backport from ntp-dev): + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + + ntpd/ntp_io.c@1.244.2.4 +84 -62 + bug 785 (backport from ntp-dev): + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + + ntpd/ntp_peer.c@1.97.1.1 +2 -2 + bug 785 (backport from ntp-dev): + clarify debug messages + +ChangeSet@1.1440.1.93, 2007-04-25 07:46:23-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P27 + TAG: NTP_4_2_5P27 + + ntpd/ntpd-opts.c@1.14 +2 -2 + NTP_4_2_5P27 + + ntpd/ntpd-opts.h@1.14 +3 -3 + NTP_4_2_5P27 + + ntpd/ntpd-opts.texi@1.13 +2 -8 + NTP_4_2_5P27 + + ntpd/ntpd.1@1.13 +2 -2 + NTP_4_2_5P27 + + ntpd/ntpdsim-opts.c@1.14 +2 -2 + NTP_4_2_5P27 + + ntpd/ntpdsim-opts.h@1.14 +3 -3 + NTP_4_2_5P27 + + ntpd/ntpdsim-opts.texi@1.13 +1 -1 + NTP_4_2_5P27 + + ntpd/ntpdsim.1@1.13 +2 -2 + NTP_4_2_5P27 + + ntpdc/ntpdc-opts.c@1.14 +2 -2 + NTP_4_2_5P27 + + ntpdc/ntpdc-opts.h@1.14 +3 -3 + NTP_4_2_5P27 + + ntpdc/ntpdc-opts.texi@1.13 +2 -2 + NTP_4_2_5P27 + + ntpdc/ntpdc.1@1.13 +2 -2 + NTP_4_2_5P27 + + ntpq/ntpq-opts.c@1.14 +2 -2 + NTP_4_2_5P27 + + ntpq/ntpq-opts.h@1.14 +3 -3 + NTP_4_2_5P27 + + ntpq/ntpq-opts.texi@1.13 +2 -2 + NTP_4_2_5P27 + + ntpq/ntpq.1@1.13 +2 -2 + NTP_4_2_5P27 + + packageinfo.sh@1.30 +1 -1 + NTP_4_2_5P27 + + sntp/sntp-opts.c@1.14 +2 -2 + NTP_4_2_5P27 + + sntp/sntp-opts.h@1.14 +3 -3 + NTP_4_2_5P27 + + sntp/sntp-opts.texi@1.13 +1 -1 + NTP_4_2_5P27 + + sntp/sntp.1@1.13 +2 -2 + NTP_4_2_5P27 + + util/ntp-keygen-opts.c@1.15 +2 -2 + NTP_4_2_5P27 + + util/ntp-keygen-opts.h@1.15 +3 -3 + NTP_4_2_5P27 + + util/ntp-keygen-opts.texi@1.14 +2 -2 + NTP_4_2_5P27 + + util/ntp-keygen.1@1.14 +2 -2 + NTP_4_2_5P27 + +ChangeSet@1.1440.1.92, 2007-04-25 03:39:23-04:00, stenn@whimsy.udel.edu + The m4/ subdirectory is magically handled. + + Makefile.am@1.75 +0 -1 + The m4/ subdirectory is magically handled. + +ChangeSet@1.1440.1.91, 2007-04-25 02:45:35-04:00, stenn@whimsy.udel.edu + [Bug 542] Tolerate missing directory separator at EO statsdir + + ChangeLog@1.31 +1 -0 + [Bug 542] Tolerate missing directory separator at EO statsdir + + Makefile.am@1.74 +1 -0 + [Bug 542] Tolerate missing directory separator at EO statsdir + + configure.ac@1.404.1.1 +1 -0 + [Bug 542] Tolerate missing directory separator at EO statsdir + + m4/ntp_dir_sep.m4@1.1 +18 -0 + BitKeeper file /deacon/backroom/ntp-dev/m4/ntp_dir_sep.m4 + + m4/ntp_dir_sep.m4@1.0 +0 -0 + + ntpd/ntp_util.c@1.44 +20 -1 + [Bug 542] Tolerate missing directory separator at EO statsdir + + ports/winnt/include/config.h@1.49 +10 -7 + [Bug 542] Tolerate missing directory separator at EO statsdir + +ChangeSet@1.1454, 2007-04-23 16:33:49+00:00, kamboj@pogo.udel.edu + Includes changes to allow the seperate compilation of ntp_data_structures.c ntp_scanner.c and ntp_parser.y + Also includes other minor bugfixes. + + BitKeeper/etc/ignore@1.60, stenn@pogo.udel.edu +1 -0 + added ylwrap + + configure.ac@1.405 +1 -0 + Minor Changes + + include/ntp_config.h@1.44 +25 -9 + Moved some declarations from ntp_scanner.h to this file and vice versa. + + include/ntpsim.h@1.8 +0 -1 + Removed a comment + + libntp/systime.c@1.40 +2 -1 + No changes + + ntpd/Makefile.am@1.57 +5 -2 + Updated SOURCES to include ntp_data_structures.c ntp_scanner.c and ntp_parser.y files + + ntpd/cmd_args.c@1.49 +1 -1 + Minor bugfix + + ntpd/ntp_config.c@1.146 +8 -58 + Removed the direcrt inclusion of source files. + Including headers instead. + + ntpd/ntp_data_structures.c@1.2 +5 -2 + Updated to include a header file for the data structures. + + ntpd/ntp_parser.c@1.4 +683 -650 + New file generated from ntp_parser.y + + ntpd/ntp_parser.c@1.3, stenn@pogo.udel.edu +0 -0 + Rename: ntpd/ntp_config.tab.c -> ntpd/ntp_parser.c + + ntpd/ntp_parser.h@1.2 +4 -3 + New file generated from ntp_parser.y + + ntpd/ntp_parser.h@1.1, stenn@pogo.udel.edu +174 -0 + BitKeeper file /pogo/users/kamboj/new-config-bk-repo/ntpd/ntp_parser.h + + ntpd/ntp_parser.h@1.0, stenn@pogo.udel.edu +0 -0 + + ntpd/ntp_parser.y@1.3 +38 -1 + Added required headers to the code + + ntpd/ntp_parser.y@1.2, stenn@pogo.udel.edu +0 -0 + Rename: ntpd/ntp_config.y -> ntpd/ntp_parser.y + + ntpd/ntp_scanner.c@1.2 +25 -36 + Minor changes: + Updated function definitions to conform to ANSI C + Moved some data from ntp_scanner.h to this file + + ntpd/ntp_scanner.h@1.2 +14 -36 + Moved some declarations to ntp_config.h + + ntpd/ntp_scanner.h@1.1, stenn@pogo.udel.edu +97 -0 + BitKeeper file /pogo/users/kamboj/new-config-bk-repo/ntpd/ntp_scanner.h + + ntpd/ntp_scanner.h@1.0, stenn@pogo.udel.edu +0 -0 + + ntpd/ntpsim.c@1.16 +6 -35 + Removed some old redundant comments + +ChangeSet@1.1440.1.90, 2007-04-22 07:42:54-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P26 + TAG: NTP_4_2_5P26 + + ntpd/ntpd-opts.c@1.13 +2 -2 + NTP_4_2_5P26 + + ntpd/ntpd-opts.h@1.13 +3 -3 + NTP_4_2_5P26 + + ntpd/ntpd-opts.texi@1.12 +1 -1 + NTP_4_2_5P26 + + ntpd/ntpd.1@1.12 +2 -2 + NTP_4_2_5P26 + + ntpd/ntpdsim-opts.c@1.13 +2 -2 + NTP_4_2_5P26 + + ntpd/ntpdsim-opts.h@1.13 +3 -3 + NTP_4_2_5P26 + + ntpd/ntpdsim-opts.texi@1.12 +1 -1 + NTP_4_2_5P26 + + ntpd/ntpdsim.1@1.12 +2 -2 + NTP_4_2_5P26 + + ntpdc/ntpdc-opts.c@1.13 +2 -2 + NTP_4_2_5P26 + + ntpdc/ntpdc-opts.h@1.13 +3 -3 + NTP_4_2_5P26 + + ntpdc/ntpdc-opts.texi@1.12 +1 -1 + NTP_4_2_5P26 + + ntpdc/ntpdc.1@1.12 +2 -2 + NTP_4_2_5P26 + + ntpq/ntpq-opts.c@1.13 +2 -2 + NTP_4_2_5P26 + + ntpq/ntpq-opts.h@1.13 +3 -3 + NTP_4_2_5P26 + + ntpq/ntpq-opts.texi@1.12 +1 -1 + NTP_4_2_5P26 + + ntpq/ntpq.1@1.12 +2 -2 + NTP_4_2_5P26 + + packageinfo.sh@1.29 +1 -1 + NTP_4_2_5P26 + + sntp/sntp-opts.c@1.13 +2 -2 + NTP_4_2_5P26 + + sntp/sntp-opts.h@1.13 +3 -3 + NTP_4_2_5P26 + + sntp/sntp-opts.texi@1.12 +1 -1 + NTP_4_2_5P26 + + sntp/sntp.1@1.12 +2 -2 + NTP_4_2_5P26 + + util/ntp-keygen-opts.c@1.14 +2 -2 + NTP_4_2_5P26 + + util/ntp-keygen-opts.h@1.14 +3 -3 + NTP_4_2_5P26 + + util/ntp-keygen-opts.texi@1.13 +1 -1 + NTP_4_2_5P26 + + util/ntp-keygen.1@1.13 +2 -2 + NTP_4_2_5P26 + +ChangeSet@1.1440.1.89, 2007-04-21 13:13:03-04:00, stenn@whimsy.udel.edu + [Bug 812] ntpd should drop supplementary groups + + ChangeLog@1.30 +1 -0 + [Bug 812] ntpd should drop supplementary groups + +ChangeSet@1.1440.1.88, 2007-04-21 07:43:00-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P25 + TAG: NTP_4_2_5P25 + + ntpd/ntpd-opts.c@1.12 +2 -2 + NTP_4_2_5P25 + + ntpd/ntpd-opts.h@1.12 +3 -3 + NTP_4_2_5P25 + + ntpd/ntpd-opts.texi@1.11 +1 -1 + NTP_4_2_5P25 + + ntpd/ntpd.1@1.11 +2 -2 + NTP_4_2_5P25 + + ntpd/ntpdsim-opts.c@1.12 +2 -2 + NTP_4_2_5P25 + + ntpd/ntpdsim-opts.h@1.12 +3 -3 + NTP_4_2_5P25 + + ntpd/ntpdsim-opts.texi@1.11 +1 -1 + NTP_4_2_5P25 + + ntpd/ntpdsim.1@1.11 +2 -2 + NTP_4_2_5P25 + + ntpdc/ntpdc-opts.c@1.12 +2 -2 + NTP_4_2_5P25 + + ntpdc/ntpdc-opts.h@1.12 +3 -3 + NTP_4_2_5P25 + + ntpdc/ntpdc-opts.texi@1.11 +1 -1 + NTP_4_2_5P25 + + ntpdc/ntpdc.1@1.11 +2 -2 + NTP_4_2_5P25 + + ntpq/ntpq-opts.c@1.12 +2 -2 + NTP_4_2_5P25 + + ntpq/ntpq-opts.h@1.12 +3 -3 + NTP_4_2_5P25 + + ntpq/ntpq-opts.texi@1.11 +1 -1 + NTP_4_2_5P25 + + ntpq/ntpq.1@1.11 +2 -2 + NTP_4_2_5P25 + + packageinfo.sh@1.28 +1 -1 + NTP_4_2_5P25 + + sntp/sntp-opts.c@1.12 +2 -2 + NTP_4_2_5P25 + + sntp/sntp-opts.h@1.12 +3 -3 + NTP_4_2_5P25 + + sntp/sntp-opts.texi@1.11 +1 -1 + NTP_4_2_5P25 + + sntp/sntp.1@1.11 +2 -2 + NTP_4_2_5P25 + + util/ntp-keygen-opts.c@1.13 +2 -2 + NTP_4_2_5P25 + + util/ntp-keygen-opts.h@1.13 +3 -3 + NTP_4_2_5P25 + + util/ntp-keygen-opts.texi@1.12 +1 -1 + NTP_4_2_5P25 + + util/ntp-keygen.1@1.12 +2 -2 + NTP_4_2_5P25 + +ChangeSet@1.1440.1.87, 2007-04-21 01:14:37-04:00, stenn@whimsy.udel.edu + [Bug 812] ntpd should drop supplementary groups + + ntpd/ntpd.c@1.83.1.3 +24 -2 + [Bug 812] ntpd should drop supplementary groups + +ChangeSet@1.1453, 2007-04-20 16:18:30+00:00, kamboj@pogo.udel.edu + Minor Bugfixes + + include/ntp_config.h@1.43 +1 -1 + A minor bugfix to make a prototype ANSI C compliant + + ntpd/ntp_config.c@1.145 +5 -3 + Minor bugfixes + + ntpd/ntp_config.tab.c@1.2 +1193 -984 + Added minor bugfixes to ntp_config.y + +ChangeSet@1.1440.1.86, 2007-04-20 07:42:36-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P24 + TAG: NTP_4_2_5P24 + + ntpd/ntpd-opts.c@1.11 +2 -2 + NTP_4_2_5P24 + + ntpd/ntpd-opts.h@1.11 +3 -3 + NTP_4_2_5P24 + + ntpd/ntpd-opts.texi@1.10 +1 -1 + NTP_4_2_5P24 + + ntpd/ntpd.1@1.10 +2 -2 + NTP_4_2_5P24 + + ntpd/ntpdsim-opts.c@1.11 +2 -2 + NTP_4_2_5P24 + + ntpd/ntpdsim-opts.h@1.11 +3 -3 + NTP_4_2_5P24 + + ntpd/ntpdsim-opts.texi@1.10 +1 -1 + NTP_4_2_5P24 + + ntpd/ntpdsim.1@1.10 +2 -2 + NTP_4_2_5P24 + + ntpdc/ntpdc-opts.c@1.11 +2 -2 + NTP_4_2_5P24 + + ntpdc/ntpdc-opts.h@1.11 +3 -3 + NTP_4_2_5P24 + + ntpdc/ntpdc-opts.texi@1.10 +1 -1 + NTP_4_2_5P24 + + ntpdc/ntpdc.1@1.10 +2 -2 + NTP_4_2_5P24 + + ntpq/ntpq-opts.c@1.11 +2 -2 + NTP_4_2_5P24 + + ntpq/ntpq-opts.h@1.11 +3 -3 + NTP_4_2_5P24 + + ntpq/ntpq-opts.texi@1.10 +1 -1 + NTP_4_2_5P24 + + ntpq/ntpq.1@1.10 +2 -2 + NTP_4_2_5P24 + + packageinfo.sh@1.27 +1 -1 + NTP_4_2_5P24 + + sntp/sntp-opts.c@1.11 +2 -2 + NTP_4_2_5P24 + + sntp/sntp-opts.h@1.11 +3 -3 + NTP_4_2_5P24 + + sntp/sntp-opts.texi@1.10 +1 -1 + NTP_4_2_5P24 + + sntp/sntp.1@1.10 +2 -2 + NTP_4_2_5P24 + + util/ntp-keygen-opts.c@1.12 +2 -2 + NTP_4_2_5P24 + + util/ntp-keygen-opts.h@1.12 +3 -3 + NTP_4_2_5P24 + + util/ntp-keygen-opts.texi@1.11 +1 -1 + NTP_4_2_5P24 + + util/ntp-keygen.1@1.11 +2 -2 + NTP_4_2_5P24 + +ChangeSet@1.1440.1.85, 2007-04-20 01:04:24-04:00, stenn@whimsy.udel.edu + [Bug 815] Fix warning compiling 4.2.5p22 under Windows with VC6 + + ChangeLog@1.29 +1 -0 + [Bug 815] Fix warning compiling 4.2.5p22 under Windows with VC6 + +ChangeSet@1.1440.1.84, 2007-04-20 00:56:48-04:00, stenn@whimsy.udel.edu + Fix permissions of sntp/sntp-opts.menu + + sntp/sntp-opts.menu@1.3 +0 -0 + Change mode to -rw-rw-r-- + +ChangeSet@1.1440.1.83, 2007-04-18 12:53:10+00:00, burnicki@pogo.udel.edu + [Bug #815] Define HAVE_UINTPTR_T under Windows to avoid duplicate definition elsewhere. + + ports/winnt/include/config.h@1.48 +2 -0 + [Bug #815] Define HAVE_UINTPTR_T under Windows to avoid duplicate definition elsewhere. + +ChangeSet@1.1440.1.82, 2007-04-18 08:18:53-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P23 + TAG: NTP_4_2_5P23 + + ntpd/ntpd-opts.c@1.10 +7 -50 + NTP_4_2_5P23 + + ntpd/ntpd-opts.h@1.10 +5 -13 + NTP_4_2_5P23 + + ntpd/ntpd-opts.texi@1.9 +1 -1 + NTP_4_2_5P23 + + ntpd/ntpd.1@1.9 +3 -19 + NTP_4_2_5P23 + + ntpd/ntpdsim-opts.c@1.10 +2 -2 + NTP_4_2_5P23 + + ntpd/ntpdsim-opts.h@1.10 +3 -3 + NTP_4_2_5P23 + + ntpd/ntpdsim-opts.texi@1.9 +1 -1 + NTP_4_2_5P23 + + ntpd/ntpdsim.1@1.9 +2 -2 + NTP_4_2_5P23 + + ntpdc/ntpdc-opts.c@1.10 +2 -2 + NTP_4_2_5P23 + + ntpdc/ntpdc-opts.h@1.10 +3 -3 + NTP_4_2_5P23 + + ntpdc/ntpdc-opts.texi@1.9 +1 -1 + NTP_4_2_5P23 + + ntpdc/ntpdc.1@1.9 +2 -2 + NTP_4_2_5P23 + + ntpq/ntpq-opts.c@1.10 +2 -2 + NTP_4_2_5P23 + + ntpq/ntpq-opts.h@1.10 +3 -3 + NTP_4_2_5P23 + + ntpq/ntpq-opts.texi@1.9 +1 -1 + NTP_4_2_5P23 + + ntpq/ntpq.1@1.9 +2 -2 + NTP_4_2_5P23 + + packageinfo.sh@1.26 +1 -1 + NTP_4_2_5P23 + + sntp/sntp-opts.c@1.10 +2 -2 + NTP_4_2_5P23 + + sntp/sntp-opts.h@1.10 +3 -3 + NTP_4_2_5P23 + + sntp/sntp-opts.texi@1.9 +1 -1 + NTP_4_2_5P23 + + sntp/sntp.1@1.9 +2 -2 + NTP_4_2_5P23 + + util/ntp-keygen-opts.c@1.11 +2 -2 + NTP_4_2_5P23 + + util/ntp-keygen-opts.h@1.11 +3 -3 + NTP_4_2_5P23 + + util/ntp-keygen-opts.texi@1.10 +1 -1 + NTP_4_2_5P23 + + util/ntp-keygen.1@1.10 +2 -2 + NTP_4_2_5P23 + +ChangeSet@1.1440.5.1, 2007-04-18 06:05:04-04:00, stenn@deacon.udel.edu + [Bug 740] Fix kernel/daemon startup drift anomaly + + ChangeLog@1.26.1.1 +1 -0 + [Bug 740] Fix kernel/daemon startup drift anomaly + + conf/beauregard.conf@1.3 +1 -1 + fix a typo in a comment line + + ntpd/cmd_args.c@1.45.2.1 +3 -2 + [Bug 740] Fix kernel/daemon startup drift anomaly + + ntpd/ntp_loopfilter.c@1.133 +4 -4 + [Bug 740] Fix kernel/daemon startup drift anomaly + + ntpd/ntp_proto.c@1.251 +0 -8 + [Bug 740] Fix kernel/daemon startup drift anomaly + +ChangeSet@1.1436.1.44, 2007-04-14 19:05:07-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P2_RC1 + TAG: NTP_4_2_4P2_RC1 + + ntpd/ntpd-opts.c@1.50.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + ntpd/ntpd-opts.h@1.50.2.3 +3 -3 + NTP_4_2_4P2_RC1 + + ntpd/ntpd-opts.texi@1.49.2.3 +1 -1 + NTP_4_2_4P2_RC1 + + ntpd/ntpd.1@1.48.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim-opts.c@1.50.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim-opts.h@1.50.2.3 +3 -3 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim-opts.texi@1.48.2.3 +1 -1 + NTP_4_2_4P2_RC1 + + ntpd/ntpdsim.1@1.48.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc-opts.c@1.50.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc-opts.h@1.50.2.3 +3 -3 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc-opts.texi@1.48.2.3 +1 -1 + NTP_4_2_4P2_RC1 + + ntpdc/ntpdc.1@1.48.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + ntpq/ntpq-opts.c@1.52.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + ntpq/ntpq-opts.h@1.52.2.3 +3 -3 + NTP_4_2_4P2_RC1 + + ntpq/ntpq-opts.texi@1.49.2.3 +1 -1 + NTP_4_2_4P2_RC1 + + ntpq/ntpq.1@1.48.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + packageinfo.sh@1.65.8.4 +2 -2 + NTP_4_2_4P2_RC1 + + sntp/sntp-opts.c@1.49.2.2 +2 -2 + NTP_4_2_4P2_RC1 + + sntp/sntp-opts.h@1.49.2.2 +3 -3 + NTP_4_2_4P2_RC1 + + sntp/sntp-opts.texi@1.46.2.2 +1 -1 + NTP_4_2_4P2_RC1 + + sntp/sntp.1@1.49.2.2 +2 -2 + NTP_4_2_4P2_RC1 + + util/ntp-keygen-opts.c@1.49.2.3 +2 -2 + NTP_4_2_4P2_RC1 + + util/ntp-keygen-opts.h@1.49.2.3 +3 -3 + NTP_4_2_4P2_RC1 + + util/ntp-keygen-opts.texi@1.47.2.3 +1 -1 + NTP_4_2_4P2_RC1 + + util/ntp-keygen.1@1.47.2.3 +2 -2 + NTP_4_2_4P2_RC1 + +ChangeSet@1.1436.1.43, 2007-04-14 18:16:04-04:00, stenn@deacon.udel.edu + Distribute include/homerc.def + + include/Makefile.am@1.24.1.1 +1 -1 + Distribute include/homerc.def + + packageinfo.sh@1.65.8.3 +1 -1 + restart the RC + +ChangeSet@1.1436.1.42, 2007-04-14 07:53:43-04:00, stenn@whimsy.udel.edu + NTP_4_2_4P1_RC1 + TAG: NTP_4_2_4P1_RC1 + + ntpd/ntpd-opts.c@1.50.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpd-opts.h@1.50.2.2 +3 -3 + NTP_4_2_4P1_RC1 + + ntpd/ntpd-opts.texi@1.49.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpd.1@1.48.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim-opts.c@1.50.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim-opts.h@1.50.2.2 +3 -3 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim-opts.texi@1.48.2.2 +1 -1 + NTP_4_2_4P1_RC1 + + ntpd/ntpdsim.1@1.48.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc-opts.c@1.50.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc-opts.h@1.50.2.2 +3 -3 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc-opts.texi@1.48.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpdc/ntpdc.1@1.48.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpq/ntpq-opts.c@1.52.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpq/ntpq-opts.h@1.52.2.2 +3 -3 + NTP_4_2_4P1_RC1 + + ntpq/ntpq-opts.texi@1.49.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + ntpq/ntpq.1@1.48.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + packageinfo.sh@1.65.8.2 +2 -2 + NTP_4_2_4P1_RC1 + + sntp/sntp-opts.c@1.49.2.1 +8 -7 + NTP_4_2_4P1_RC1 + + sntp/sntp-opts.h@1.49.2.1 +8 -14 + NTP_4_2_4P1_RC1 + + sntp/sntp-opts.texi@1.46.2.1 +1 -1 + NTP_4_2_4P1_RC1 + + sntp/sntp.1@1.49.2.1 +2 -2 + NTP_4_2_4P1_RC1 + + util/ntp-keygen-opts.c@1.49.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + util/ntp-keygen-opts.h@1.49.2.2 +3 -3 + NTP_4_2_4P1_RC1 + + util/ntp-keygen-opts.texi@1.47.2.2 +2 -2 + NTP_4_2_4P1_RC1 + + util/ntp-keygen.1@1.47.2.2 +2 -2 + NTP_4_2_4P1_RC1 + +ChangeSet@1.1436.1.41, 2007-04-14 05:13:18-04:00, stenn@whimsy.udel.edu + [Bug 811] ntpd should not read a .ntprc file + + ChangeLog@1.1.1.10 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + +ChangeSet@1.1436.1.40, 2007-04-14 04:47:21-04:00, stenn@whimsy.udel.edu + start an RC cycle + + packageinfo.sh@1.65.8.1 +2 -2 + start an RC cycle + +ChangeSet@1.1436.1.39, 2007-04-14 02:38:03-04:00, stenn@whimsy.udel.edu + [Bug 811] ntpd should not read a .ntprc file + + clockstuff/Makefile.am@1.5.1.1 +1 -1 + [Bug 811] ntpd should not read a .ntprc file + + clockstuff/clktest-opts.def@1.5 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + include/copyright.def@1.4 +0 -7 + [Bug 811] ntpd should not read a .ntprc file + + include/homerc.def@1.1 +9 -0 + BitKeeper file /deacon/backroom/ntp-stable/include/homerc.def + + include/homerc.def@1.0 +0 -0 + + ntpd/Makefile.am@1.52.2.1 +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd-opts.c@1.50.2.1 +12 -54 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd-opts.h@1.50.2.1 +8 -22 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd-opts.texi@1.49.2.1 +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpd.1@1.48.2.1 +3 -19 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.c@1.50.2.1 +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.def@1.6 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.h@1.50.2.1 +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim-opts.texi@1.48.2.1 +1 -1 + [Bug 811] ntpd should not read a .ntprc file + + ntpd/ntpdsim.1@1.48.2.1 +2 -2 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/Makefile.am@1.33.1.1 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.c@1.50.2.1 +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.def@1.13 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.h@1.50.2.1 +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc-opts.texi@1.48.2.1 +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpdc/ntpdc.1@1.48.2.1 +2 -2 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/Makefile.am@1.25.1.1 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.c@1.52.2.1 +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.def@1.12 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.h@1.52.2.1 +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq-opts.texi@1.49.2.1 +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + ntpq/ntpq.1@1.48.2.1 +2 -2 + [Bug 811] ntpd should not read a .ntprc file + + util/Makefile.am@1.34.1.1 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.c@1.49.2.1 +7 -6 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.def@1.6.1.1 +1 -0 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.h@1.49.2.1 +6 -12 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen-opts.texi@1.47.2.1 +3 -3 + [Bug 811] ntpd should not read a .ntprc file + + util/ntp-keygen.1@1.47.2.1 +2 -2 + [Bug 811] ntpd should not read a .ntprc file + +ChangeSet@1.1436.1.38, 2007-04-14 01:11:33-04:00, stenn@whimsy.udel.edu + autogen/libopts upgrade + + BitKeeper/deleted/.del-COPYING.lgpl@1.2.1.1 +0 -0 + Delete: libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.lgpl~54a90ba0899593cb@1.1.1.1 +0 -0 + Delete: sntp/libopts/COPYING.lgpl + + BitKeeper/deleted/.del-COPYING.mbsd@1.1.1.1 +0 -0 + Delete: libopts/COPYING.mbsd + + BitKeeper/deleted/.del-COPYING.mbsd~9b1945bb2136c70b@1.1.1.1 +0 -0 + Delete: sntp/libopts/COPYING.mbsd + + BitKeeper/deleted/.del-MakeDefs.inc@1.1.1.1 +0 -0 + Delete: libopts/MakeDefs.inc + + BitKeeper/deleted/.del-MakeDefs.inc~2b8fdfc9df6d652d@1.1.1.1 +0 -0 + Delete: sntp/libopts/MakeDefs.inc + + BitKeeper/deleted/.del-Makefile.am@1.6.1.1 +0 -0 + Delete: libopts/Makefile.am + + BitKeeper/deleted/.del-Makefile.am~fa9bd87b6045015c@1.4.1.1 +0 -0 + Delete: sntp/libopts/Makefile.am + + BitKeeper/deleted/.del-README@1.1.1.1 +0 -0 + Delete: libopts/README + + BitKeeper/deleted/.del-README~1ae087758ee867d4@1.1.1.1 +0 -0 + Delete: sntp/libopts/README + + BitKeeper/deleted/.del-autoopts.c@1.10.1.1 +0 -0 + Delete: libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.c~5b417341bc85d7a8@1.7.1.1 +0 -0 + Delete: sntp/libopts/autoopts.c + + BitKeeper/deleted/.del-autoopts.h@1.9.1.1 +0 -0 + Delete: libopts/autoopts.h + + BitKeeper/deleted/.del-autoopts.h~8cdce21b181a1a01@1.7.1.1 +0 -0 + Delete: sntp/libopts/autoopts.h + + BitKeeper/deleted/.del-boolean.c@1.8.1.1 +0 -0 + Delete: libopts/boolean.c + + BitKeeper/deleted/.del-boolean.c~a5d10c8997e6a2e2@1.5.1.1 +0 -0 + Delete: sntp/libopts/boolean.c + + BitKeeper/deleted/.del-compat.h@1.12.1.1 +0 -0 + Delete: libopts/compat/compat.h + + BitKeeper/deleted/.del-compat.h~9682d0ac273ae32@1.8.1.1 +0 -0 + Delete: sntp/libopts/compat/compat.h + + BitKeeper/deleted/.del-configfile.c@1.10.1.1 +0 -0 + Delete: libopts/configfile.c + + BitKeeper/deleted/.del-configfile.c~8194f784686fa804@1.7.1.1 +0 -0 + Delete: sntp/libopts/configfile.c + + BitKeeper/deleted/.del-cook.c@1.9.1.1 +0 -0 + Delete: libopts/cook.c + + BitKeeper/deleted/.del-cook.c~e48d079a438432dc@1.6.1.1 +0 -0 + Delete: sntp/libopts/cook.c + + BitKeeper/deleted/.del-enumeration.c@1.9.1.1 +0 -0 + Delete: libopts/enumeration.c + + BitKeeper/deleted/.del-enumeration.c~5f4e6af2706370ae@1.6.1.1 +0 -0 + Delete: sntp/libopts/enumeration.c + + BitKeeper/deleted/.del-environment.c@1.8.1.1 +0 -0 + Delete: libopts/environment.c + + BitKeeper/deleted/.del-environment.c~2bae2966695067c2@1.5.1.1 +0 -0 + Delete: sntp/libopts/environment.c + + BitKeeper/deleted/.del-genshell.c@1.9.1.1 +0 -0 + Delete: libopts/genshell.c + + BitKeeper/deleted/.del-genshell.c~1fd152b2b52bdab@1.6.1.1 +0 -0 + Delete: sntp/libopts/genshell.c + + BitKeeper/deleted/.del-genshell.h@1.9.1.1 +0 -0 + Delete: libopts/genshell.h + + BitKeeper/deleted/.del-genshell.h~375f0fa5b925f454@1.6.1.1 +0 -0 + Delete: sntp/libopts/genshell.h + + BitKeeper/deleted/.del-libopts.c@1.3.1.1 +0 -0 + Delete: libopts/libopts.c + + BitKeeper/deleted/.del-libopts.c~58b8fbed850e6d5e@1.3.1.1 +0 -0 + Delete: sntp/libopts/libopts.c + + BitKeeper/deleted/.del-libopts.m4@1.14.1.1 +0 -0 + Delete: libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-libopts.m4~9e0f33f57d3a0a9@1.11.1.1 +0 -0 + Delete: sntp/libopts/m4/libopts.m4 + + BitKeeper/deleted/.del-liboptschk.m4@1.3.1.1 +0 -0 + Delete: libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-liboptschk.m4~bbeebebe76865058@1.3.1.1 +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 + + BitKeeper/deleted/.del-libtool.m4@1.1.1.1 +0 -0 + Delete: libopts/m4/libtool.m4 + + BitKeeper/deleted/.del-libtool.m4~db8acbd0fb34597f@1.1.1.1 +0 -0 + Delete: sntp/libopts/m4/libtool.m4 + + BitKeeper/deleted/.del-load.c@1.10.1.1 +0 -0 + Delete: libopts/load.c + + BitKeeper/deleted/.del-load.c~59960aa12bb95bf7@1.7.1.1 +0 -0 + Delete: sntp/libopts/load.c + + BitKeeper/deleted/.del-makeshell.c@1.11.1.1 +0 -0 + Delete: libopts/makeshell.c + + BitKeeper/deleted/.del-makeshell.c~4fcd12fc31c0a4a4@1.8.1.1 +0 -0 + Delete: sntp/libopts/makeshell.c + + BitKeeper/deleted/.del-nested.c@1.9.1.1 +0 -0 + Delete: libopts/nested.c + + BitKeeper/deleted/.del-nested.c~85346d5d12098689@1.6.1.1 +0 -0 + Delete: sntp/libopts/nested.c + + BitKeeper/deleted/.del-numeric.c@1.9.1.1 +0 -0 + Delete: libopts/numeric.c + + BitKeeper/deleted/.del-numeric.c~cdb7deb5cf6f27c2@1.6.1.1 +0 -0 + Delete: sntp/libopts/numeric.c + + BitKeeper/deleted/.del-options.h@1.10.1.1 +0 -0 + Delete: libopts/autoopts/options.h + + BitKeeper/deleted/.del-options.h~6eb465cb95a56bee@1.7.1.1 +0 -0 + Delete: sntp/libopts/autoopts/options.h + + BitKeeper/deleted/.del-pathfind.c@1.9.1.1 +0 -0 + Delete: libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pathfind.c~a0863179d884d4a4@1.6.1.1 +0 -0 + Delete: sntp/libopts/compat/pathfind.c + + BitKeeper/deleted/.del-pgusage.c@1.9.1.1 +0 -0 + Delete: libopts/pgusage.c + + BitKeeper/deleted/.del-pgusage.c~d981c42eb301cfdd@1.5.1.1 +0 -0 + Delete: sntp/libopts/pgusage.c + + BitKeeper/deleted/.del-proto.h@1.11.1.1 +0 -0 + Delete: libopts/proto.h + + BitKeeper/deleted/.del-proto.h~fa076f6dd9d0667e@1.8.1.1 +0 -0 + Delete: sntp/libopts/proto.h + + BitKeeper/deleted/.del-putshell.c@1.10.1.1 +0 -0 + Delete: libopts/putshell.c + + BitKeeper/deleted/.del-putshell.c~24959f5e1ba688e6@1.7.1.1 +0 -0 + Delete: sntp/libopts/putshell.c + + BitKeeper/deleted/.del-restore.c@1.9.1.1 +0 -0 + Delete: libopts/restore.c + + BitKeeper/deleted/.del-restore.c~eada4acbf21cd8bf@1.5.1.1 +0 -0 + Delete: sntp/libopts/restore.c + + BitKeeper/deleted/.del-save.c@1.10.1.1 +0 -0 + Delete: libopts/save.c + + BitKeeper/deleted/.del-save.c~a29f5bd429a568bb@1.7.1.1 +0 -0 + Delete: sntp/libopts/save.c + + BitKeeper/deleted/.del-snprintf.c@1.4.1.1 +0 -0 + Delete: libopts/compat/snprintf.c + + BitKeeper/deleted/.del-snprintf.c~66578c716014cd3d@1.3.1.1 +0 -0 + Delete: sntp/libopts/compat/snprintf.c + + BitKeeper/deleted/.del-sort.c@1.8.1.1 +0 -0 + Delete: libopts/sort.c + + BitKeeper/deleted/.del-sort.c~bec5a7fb6a01a5dc@1.4.1.1 +0 -0 + Delete: sntp/libopts/sort.c + + BitKeeper/deleted/.del-stack.c@1.10.1.1 +0 -0 + Delete: libopts/stack.c + + BitKeeper/deleted/.del-stack.c~e817b57b18b315c1@1.7.1.1 +0 -0 + Delete: sntp/libopts/stack.c + + BitKeeper/deleted/.del-strchr.c@1.3.1.1 +0 -0 + Delete: libopts/compat/strchr.c + + BitKeeper/deleted/.del-strchr.c~80e88afbe7e2209a@1.3.1.1 +0 -0 + Delete: sntp/libopts/compat/strchr.c + + BitKeeper/deleted/.del-strdup.c@1.3.1.1 +0 -0 + Delete: libopts/compat/strdup.c + + BitKeeper/deleted/.del-strdup.c~1f262be5e55c3c4a@1.2.1.1 +0 -0 + Delete: sntp/libopts/compat/strdup.c + + BitKeeper/deleted/.del-streqvcmp.c@1.9.1.1 +0 -0 + Delete: libopts/streqvcmp.c + + BitKeeper/deleted/.del-streqvcmp.c~66420c6082b06827@1.6.1.1 +0 -0 + Delete: sntp/libopts/streqvcmp.c + + BitKeeper/deleted/.del-text_mmap.c@1.8.1.1 +0 -0 + Delete: libopts/text_mmap.c + + BitKeeper/deleted/.del-text_mmap.c~f1915a52b87816ba@1.5.1.1 +0 -0 + Delete: sntp/libopts/text_mmap.c + + BitKeeper/deleted/.del-tokenize.c@1.5.1.1 +0 -0 + Delete: libopts/tokenize.c + + BitKeeper/deleted/.del-tokenize.c~ae2f23dbb2bee589@1.4.1.1 +0 -0 + Delete: sntp/libopts/tokenize.c + + BitKeeper/deleted/.del-usage-txt.h@1.9.1.1 +0 -0 + Delete: libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage-txt.h~6ce4dce87430d1b@1.6.1.1 +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h + + BitKeeper/deleted/.del-usage.c@1.9.1.1 +0 -0 + Delete: libopts/usage.c + + BitKeeper/deleted/.del-usage.c~c868ef1e661a6eb1@1.7.1.1 +0 -0 + Delete: sntp/libopts/usage.c + + BitKeeper/deleted/.del-version.c@1.9.1.1 +0 -0 + Delete: libopts/version.c + + BitKeeper/deleted/.del-version.c~a426e6b58b20d06@1.6.1.1 +0 -0 + Delete: sntp/libopts/version.c + + BitKeeper/deleted/.del-windows-config.h@1.5.1.1 +0 -0 + Delete: libopts/compat/windows-config.h + + BitKeeper/deleted/.del-windows-config.h~36f7ad2ccf764ad2@1.3.1.1 +0 -0 + Delete: sntp/libopts/compat/windows-config.h + + libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.lgpl + + libopts/COPYING.lgpl@1.0 +0 -0 + + libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.mbsd + + libopts/COPYING.mbsd@1.0 +0 -0 + + libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/MakeDefs.inc + + libopts/MakeDefs.inc@1.0 +0 -0 + + libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/Makefile.am + + libopts/Makefile.am@1.0 +0 -0 + + libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/README + + libopts/README@1.0 +0 -0 + + libopts/autoopts.c@1.1 +1101 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.c + + libopts/autoopts.c@1.0 +0 -0 + + libopts/autoopts.h@1.1 +377 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.h + + libopts/autoopts.h@1.0 +0 -0 + + libopts/autoopts/options.h@1.1 +964 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0 +0 -0 + + libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0 +0 -0 + + libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/boolean.c + + libopts/boolean.c@1.0 +0 -0 + + libopts/compat/compat.h@1.1 +314 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/compat.h + + libopts/compat/compat.h@1.0 +0 -0 + + libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0 +0 -0 + + libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0 +0 -0 + + libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0 +0 -0 + + libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0 +0 -0 + + libopts/compat/windows-config.h@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0 +0 -0 + + libopts/configfile.c@1.1 +1288 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/configfile.c + + libopts/configfile.c@1.0 +0 -0 + + libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/cook.c + + libopts/cook.c@1.0 +0 -0 + + libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/enumeration.c + + libopts/enumeration.c@1.0 +0 -0 + + libopts/environment.c@1.1 +260 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/environment.c + + libopts/environment.c@1.0 +0 -0 + + libopts/genshell.c@1.1 +345 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.c + + libopts/genshell.c@1.0 +0 -0 + + libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.h + + libopts/genshell.h@1.0 +0 -0 + + libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/libopts.c + + libopts/libopts.c@1.0 +0 -0 + + libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/load.c + + libopts/load.c@1.0 +0 -0 + + libopts/m4/libopts.m4@1.1 +489 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0 +0 -0 + + libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0 +0 -0 + + libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/makeshell.c + + libopts/makeshell.c@1.0 +0 -0 + + libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/nested.c + + libopts/nested.c@1.0 +0 -0 + + libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/numeric.c + + libopts/numeric.c@1.0 +0 -0 - ports/winnt/ntpd/ntp_iocompletionport.c@1.26.1.1, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +331 -249 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/pgusage.c - ports/winnt/ntpd/win32_io.c@1.13, 2009-03-20 01:46:13+00:00, davehart@shiny.ad.hartbrothers.com +172 -66 - [Bug 873] Windows serial refclock proper TTY line discipline emulation + libopts/pgusage.c@1.0 +0 -0 -ChangeSet@1.1549.3.2, 2009-03-18 11:44:59+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/proto.h - ChangeLog@1.50.3.1, 2009-03-18 11:44:52+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1014] Enable building with VC9 (in Visual Studio 2008, Visual C++ 2008, or SDK) + libopts/proto.h@1.0 +0 -0 -ChangeSet@1.1549.1.4, 2009-03-18 10:14:52+00:00, davehart@shiny.ad.hartbrothers.com +1 -0 - [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/putshell.c - ChangeLog@1.50.1.3, 2009-03-18 10:12:28+00:00, davehart@shiny.ad.hartbrothers.com +2 -0 - [Bug 1117] Deferred interface binding under Windows works only correctly if FORCE_DNSRETRY is defined + libopts/putshell.c@1.0 +0 -0 -ChangeSet@1.1549.3.1, 2009-03-17 18:39:09+00:00, davehart@shiny.ad.hartbrothers.com +8 -0 - add .sln and .vcproj files for VC9 + libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/restore.c - ports/winnt/instsrv/Instsrv.vcproj@1.1, 2009-03-17 18:34:21+00:00, davehart@shiny.ad.hartbrothers.com +253 -0 - VC9 equivalent to Instsrv.dsp + libopts/restore.c@1.0 +0 -0 - ports/winnt/instsrv/Instsrv.vcproj@1.0, 2009-03-17 18:34:21+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/save.c - ports/winnt/libntp/libntp.vcproj@1.1, 2009-03-17 18:35:45+00:00, davehart@shiny.ad.hartbrothers.com +2229 -0 - VC9 equivalent to libntp.dsp + libopts/save.c@1.0 +0 -0 - ports/winnt/libntp/libntp.vcproj@1.0, 2009-03-17 18:35:45+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/sort.c - ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.1, 2009-03-17 18:36:28+00:00, davehart@shiny.ad.hartbrothers.com +419 -0 - VC9 equivalent to ntpkeygen.dsp + libopts/sort.c@1.0 +0 -0 - ports/winnt/ntp-keygen/ntpkeygen.vcproj@1.0, 2009-03-17 18:36:28+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/stack.c - ports/winnt/ntp.sln@1.1, 2009-03-17 18:38:44+00:00, davehart@shiny.ad.hartbrothers.com +71 -0 - VC9 equivalent to ntp.dsw + libopts/stack.c@1.0 +0 -0 - ports/winnt/ntp.sln@1.0, 2009-03-17 18:38:44+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/streqvcmp.c - ports/winnt/ntpd/ntpd.vcproj@1.1, 2009-03-17 18:36:49+00:00, davehart@shiny.ad.hartbrothers.com +2198 -0 - VC9 equivalent to ntpd.dsp + libopts/streqvcmp.c@1.0 +0 -0 - ports/winnt/ntpd/ntpd.vcproj@1.0, 2009-03-17 18:36:49+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/text_mmap.c - ports/winnt/ntpdate/ntpdate.vcproj@1.1, 2009-03-17 18:37:19+00:00, davehart@shiny.ad.hartbrothers.com +327 -0 - VC9 equivalent to ntpdate.dsp + libopts/text_mmap.c@1.0 +0 -0 - ports/winnt/ntpdate/ntpdate.vcproj@1.0, 2009-03-17 18:37:19+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/tokenize.c - ports/winnt/ntpdc/ntpdc.vcproj@1.1, 2009-03-17 18:37:32+00:00, davehart@shiny.ad.hartbrothers.com +376 -0 - VC9 equivalent to ntpdc.dsp + libopts/tokenize.c@1.0 +0 -0 - ports/winnt/ntpdc/ntpdc.vcproj@1.0, 2009-03-17 18:37:31+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/usage.c@1.1 +731 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/usage.c - ports/winnt/ntpq/ntpq.vcproj@1.1, 2009-03-17 18:37:48+00:00, davehart@shiny.ad.hartbrothers.com +370 -0 - VC9 equivalent to ntpq.dsp + libopts/usage.c@1.0 +0 -0 - ports/winnt/ntpq/ntpq.vcproj@1.0, 2009-03-17 18:37:48+00:00, davehart@shiny.ad.hartbrothers.com +0 -0 + libopts/version.c@1.1 +176 -0 + BitKeeper file /deacon/backroom/ntp-stable/libopts/version.c -ChangeSet@1.1549.1.3, 2009-03-17 18:18:13+00:00, hart@pogo.udel.edu +1 -0 - config.h: - now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + libopts/version.c@1.0 +0 -0 - ports/winnt/include/config.h@1.48, 2009-03-17 18:18:01+00:00, hart@pogo.udel.edu +243 -96 - now works with VC6 and VC9 compilers, declares DWORD_PTR on VC6 + sntp/libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.lgpl -ChangeSet@1.1549.2.1, 2009-02-21 07:45:56-05:00, utterback@pogo.udel.edu +2 -0 - configure.ac, ChangeLog: - [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + sntp/libopts/COPYING.lgpl@1.0 +0 -0 - ChangeLog@1.50.2.1, 2009-02-20 12:30:18-05:00, utterback@pogo.udel.edu +2 -0 - [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + sntp/libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.mbsd - configure.ac@1.402, 2009-02-20 11:30:02-05:00, utterback@pogo.udel.edu +3 -0 - [BUG 1131] UDP sockets should not use SIGPOLL on Solaris. + sntp/libopts/COPYING.mbsd@1.0 +0 -0 -ChangeSet@1.1549.1.2, 2009-02-07 21:13:17+00:00, hart@pogo.udel.edu +1 -0 - ChangeLog: - formatting of newest line + sntp/libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/MakeDefs.inc - ChangeLog@1.50.1.2, 2009-02-07 21:12:26+00:00, hart@pogo.udel.edu +1 -1 - formatting of newest line + sntp/libopts/MakeDefs.inc@1.0 +0 -0 -ChangeSet@1.1549.1.1, 2009-02-07 21:05:32+00:00, hart@pogo.udel.edu +3 -0 - nt_clockstuff.c, ChangeLog, ntp_iocompletionport.c: - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + sntp/libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/Makefile.am - ChangeLog@1.50.1.1, 2009-02-07 21:04:52+00:00, hart@pogo.udel.edu +2 -0 - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + sntp/libopts/Makefile.am@1.0 +0 -0 - ports/winnt/ntpd/nt_clockstuff.c@1.24, 2009-02-07 21:02:04+00:00, hart@pogo.udel.edu +89 -22 - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + sntp/libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/README - ports/winnt/ntpd/ntp_iocompletionport.c@1.27, 2009-02-07 21:03:34+00:00, hart@pogo.udel.edu +12 -0 - [BUG 1124] Lock QueryPerformanceCounter() client threads to same CPU + sntp/libopts/README@1.0 +0 -0 -ChangeSet@1.1551, 2009-02-07 14:08:35-05:00, hart@pogo.udel.edu +1 -0 - ChangeLog: - DPRINTF safer + sntp/libopts/autoopts.c@1.1 +1101 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.c - ChangeLog@1.51, 2009-02-07 14:07:34-05:00, hart@pogo.udel.edu +2 -0 - DPRINTF safer + sntp/libopts/autoopts.c@1.0 +0 -0 -ChangeSet@1.1550, 2009-02-06 19:00:15-05:00, hart@pogo.udel.edu +2 -0 - ntp_debug.h: - DPRINTF won't eat following else, always evaluates to a statement - ntp_io.c: - DPRINTF_INTERFACE always evaluates to a statement - fix DPRINTF use with misplaced semicolon + sntp/libopts/autoopts.h@1.1 +377 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.h - include/ntp_debug.h@1.2, 2009-02-06 18:50:27-05:00, hart@pogo.udel.edu +6 -4 - DPRINTF won't eat following else, always evaluates to a statement + sntp/libopts/autoopts.h@1.0 +0 -0 - ntpd/ntp_io.c@1.257, 2009-02-06 18:53:58-05:00, hart@pogo.udel.edu +2 -2 - DPRINTF_INTERFACE always evaluates to a statement - fix DPRINTF use with misplaced semicolon + sntp/libopts/autoopts/options.h@1.1 +964 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/options.h -ChangeSet@1.1549, 2009-01-08 06:21:48-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P6 - TAG: NTP_4_2_4P6 + sntp/libopts/autoopts/options.h@1.0 +0 -0 - ChangeLog@1.50, 2009-01-08 06:21:25-05:00, stenn@whimsy.udel.edu +1 -2 - NTP_4_2_4P6 + sntp/libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/usage-txt.h - ntpd/ntpd-opts.c@1.76, 2009-01-08 06:21:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 - ntpd/ntpd-opts.h@1.76, 2009-01-08 06:21:27-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + sntp/libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/boolean.c - ntpd/ntpd-opts.texi@1.75, 2009-01-08 06:21:28-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + sntp/libopts/boolean.c@1.0 +0 -0 - ntpd/ntpd.1@1.74, 2009-01-08 06:21:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/compat/compat.h@1.1 +314 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/compat.h - ntpd/ntpdsim-opts.c@1.76, 2009-01-08 06:21:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/compat/compat.h@1.0 +0 -0 - ntpd/ntpdsim-opts.h@1.76, 2009-01-08 06:21:30-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + sntp/libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/pathfind.c - ntpd/ntpdsim-opts.texi@1.74, 2009-01-08 06:21:31-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + sntp/libopts/compat/pathfind.c@1.0 +0 -0 - ntpd/ntpdsim.1@1.74, 2009-01-08 06:21:32-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/snprintf.c - ntpdc/ntpdc-opts.c@1.76, 2009-01-08 06:21:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/compat/snprintf.c@1.0 +0 -0 - ntpdc/ntpdc-opts.h@1.76, 2009-01-08 06:21:34-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + sntp/libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strchr.c - ntpdc/ntpdc-opts.texi@1.74, 2009-01-08 06:21:34-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + sntp/libopts/compat/strchr.c@1.0 +0 -0 - ntpdc/ntpdc.1@1.74, 2009-01-08 06:21:35-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strdup.c - ntpq/ntpq-opts.c@1.78, 2009-01-08 06:21:36-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/compat/strdup.c@1.0 +0 -0 - ntpq/ntpq-opts.h@1.78, 2009-01-08 06:21:37-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + sntp/libopts/compat/windows-config.h@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/windows-config.h - ntpq/ntpq-opts.texi@1.75, 2009-01-08 06:21:37-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + sntp/libopts/compat/windows-config.h@1.0 +0 -0 - ntpq/ntpq.1@1.74, 2009-01-08 06:21:39-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/configfile.c@1.1 +1288 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/configfile.c - packageinfo.sh@1.105, 2009-01-08 06:21:39-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + sntp/libopts/configfile.c@1.0 +0 -0 - sntp/sntp-opts.c@1.74, 2009-01-08 06:21:40-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/cook.c - sntp/sntp-opts.h@1.74, 2009-01-08 06:21:41-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + sntp/libopts/cook.c@1.0 +0 -0 - sntp/sntp-opts.texi@1.71, 2009-01-08 06:21:42-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + sntp/libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/enumeration.c - sntp/sntp.1@1.74, 2009-01-08 06:21:42-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/enumeration.c@1.0 +0 -0 - util/ntp-keygen-opts.c@1.75, 2009-01-08 06:21:43-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/environment.c@1.1 +260 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/environment.c - util/ntp-keygen-opts.h@1.75, 2009-01-08 06:21:44-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P6 + sntp/libopts/environment.c@1.0 +0 -0 - util/ntp-keygen-opts.texi@1.73, 2009-01-08 06:21:44-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P6 + sntp/libopts/genshell.c@1.1 +345 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.c - util/ntp-keygen.1@1.73, 2009-01-08 06:21:45-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P6 + sntp/libopts/genshell.c@1.0 +0 -0 -ChangeSet@1.1548, 2009-01-08 04:49:23-05:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P5 - TAG: NTP_4_2_4P5 + sntp/libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.h - ChangeLog@1.49, 2009-01-08 04:48:59-05:00, stenn@whimsy.udel.edu +1 -0 - NTP_4_2_4P5 + sntp/libopts/genshell.h@1.0 +0 -0 - ntpd/ntpd-opts.c@1.75, 2009-01-08 04:49:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/libopts.c - ntpd/ntpd-opts.h@1.75, 2009-01-08 04:49:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/libopts.c@1.0 +0 -0 - ntpd/ntpd-opts.texi@1.74, 2009-01-08 04:49:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/load.c - ntpd/ntpd.1@1.73, 2009-01-08 04:49:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/load.c@1.0 +0 -0 - ntpd/ntpdsim-opts.c@1.75, 2009-01-08 04:49:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/m4/libopts.m4@1.1 +489 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/libopts.m4 - ntpd/ntpdsim-opts.h@1.75, 2009-01-08 04:49:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/m4/libopts.m4@1.0 +0 -0 - ntpd/ntpdsim-opts.texi@1.73, 2009-01-08 04:49:05-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/liboptschk.m4 - ntpd/ntpdsim.1@1.73, 2009-01-08 04:49:06-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/m4/liboptschk.m4@1.0 +0 -0 - ntpdc/ntpdc-opts.c@1.75, 2009-01-08 04:49:06-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/makeshell.c - ntpdc/ntpdc-opts.h@1.75, 2009-01-08 04:49:07-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/makeshell.c@1.0 +0 -0 - ntpdc/ntpdc-opts.texi@1.73, 2009-01-08 04:49:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/nested.c - ntpdc/ntpdc.1@1.73, 2009-01-08 04:49:09-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/nested.c@1.0 +0 -0 - ntpq/ntpq-opts.c@1.77, 2009-01-08 04:49:10-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/numeric.c - ntpq/ntpq-opts.h@1.77, 2009-01-08 04:49:10-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/numeric.c@1.0 +0 -0 - ntpq/ntpq-opts.texi@1.74, 2009-01-08 04:49:11-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/pgusage.c - ntpq/ntpq.1@1.73, 2009-01-08 04:49:12-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/pgusage.c@1.0 +0 -0 - packageinfo.sh@1.104, 2009-01-08 04:49:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/proto.h - sntp/sntp-opts.c@1.73, 2009-01-08 04:49:14-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/proto.h@1.0 +0 -0 - sntp/sntp-opts.h@1.73, 2009-01-08 04:49:15-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/putshell.c - sntp/sntp-opts.texi@1.70, 2009-01-08 04:49:16-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/putshell.c@1.0 +0 -0 - sntp/sntp.1@1.73, 2009-01-08 04:49:17-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/restore.c - util/ntp-keygen-opts.c@1.74, 2009-01-08 04:49:18-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/restore.c@1.0 +0 -0 - util/ntp-keygen-opts.h@1.74, 2009-01-08 04:49:19-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/save.c - util/ntp-keygen-opts.texi@1.72, 2009-01-08 04:49:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/save.c@1.0 +0 -0 - util/ntp-keygen.1@1.72, 2009-01-08 04:49:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/sort.c -ChangeSet@1.1547, 2009-01-08 03:21:09-05:00, stenn@whimsy.udel.edu +1 -0 - 4.2.4p6 + sntp/libopts/sort.c@1.0 +0 -0 - packageinfo.sh@1.103, 2009-01-08 03:20:56-05:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p6 + sntp/libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/stack.c -ChangeSet@1.1546, 2009-01-08 03:14:17-05:00, stenn@whimsy.udel.edu +1 -0 - merge cleanup + sntp/libopts/stack.c@1.0 +0 -0 - ChangeLog@1.48, 2009-01-08 03:14:09-05:00, stenn@whimsy.udel.edu +1 -1 - merge cleanup + sntp/libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/streqvcmp.c -ChangeSet@1.1543.1.1, 2009-01-08 02:57:52-05:00, stenn@whimsy.udel.edu +5 -0 - 4.2.4p6 + sntp/libopts/streqvcmp.c@1.0 +0 -0 - ChangeLog@1.46, 2009-01-07 05:31:52-05:00, stenn@whimsy.udel.edu +6 -0 - Fix incorrect check of EVP_VerifyFinal()'s return value. + sntp/libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/text_mmap.c - NEWS@1.100, 2009-01-08 02:57:32-05:00, stenn@whimsy.udel.edu +16 -0 - 4.2.4p6 + sntp/libopts/text_mmap.c@1.0 +0 -0 - html/copyright.html@1.38, 2009-01-07 05:30:58-05:00, stenn@whimsy.udel.edu +1 -1 - Update the copyright year + sntp/libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/tokenize.c - ntpd/ntp_crypto.c@1.108, 2009-01-07 05:31:50-05:00, stenn@whimsy.udel.edu +1 -1 - Fix incorrect check of EVP_VerifyFinal()'s return value. + sntp/libopts/tokenize.c@1.0 +0 -0 - packageinfo.sh@1.102, 2009-01-08 02:57:33-05:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p6 + sntp/libopts/usage.c@1.1 +731 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/usage.c -ChangeSet@1.1544, 2009-01-07 18:00:50+01:00, burnicki@pogo.udel.edu +2 -0 - [BUG 1113] Fixed build errors with recent versions of openSSL. + sntp/libopts/usage.c@1.0 +0 -0 - ChangeLog@1.45.1.1, 2009-01-07 18:00:47+01:00, burnicki@pogo.udel.edu +1 -0 - [BUG 1113] Fixed build errors with recent versions of openSSL. + sntp/libopts/version.c@1.1 +176 -0 + BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/version.c - ntpd/ntp_crypto.c@1.107.1.1, 2009-01-07 18:00:47+01:00, burnicki@pogo.udel.edu +2 -2 - [BUG 1113] Fixed build errors with recent versions of openSSL. + sntp/libopts/version.c@1.0 +0 -0 -ChangeSet@1.1543, 2008-08-17 06:21:39-04:00, stenn@whimsy.udel.edu +1 -0 - typo +ChangeSet@1.1440.1.79, 2007-04-13 07:42:22-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P22 + TAG: NTP_4_2_5P22 - scripts/addChangeLogTag@1.3, 2008-08-17 06:21:25-04:00, stenn@whimsy.udel.edu +0 -3 - typo + ntpd/ntpd-opts.c@1.9 +2 -2 + NTP_4_2_5P22 -ChangeSet@1.1542, 2008-08-17 06:16:19-04:00, stenn@whimsy.udel.edu +1 -0 - typo + ntpd/ntpd-opts.h@1.9 +3 -3 + NTP_4_2_5P22 - ChangeLog@1.45, 2008-08-17 06:16:08-04:00, stenn@whimsy.udel.edu +0 -2 - typo + ntpd/ntpd-opts.texi@1.8 +1 -1 + NTP_4_2_5P22 -ChangeSet@1.1541, 2008-08-17 05:30:47-04:00, stenn@whimsy.udel.edu +26 -0 - NTP_4_2_4P5 - TAG: NTP_4_2_4P5 + ntpd/ntpd.1@1.8 +2 -2 + NTP_4_2_5P22 - ChangeLog@1.44, 2008-08-17 05:30:27-04:00, stenn@whimsy.udel.edu +3 -0 - NTP_4_2_4P5 + ntpd/ntpdsim-opts.c@1.9 +2 -2 + NTP_4_2_5P22 - ntpd/ntpd-opts.c@1.74, 2008-08-17 05:30:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpd/ntpdsim-opts.h@1.9 +3 -3 + NTP_4_2_5P22 - ntpd/ntpd-opts.h@1.74, 2008-08-17 05:30:28-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + ntpd/ntpdsim-opts.texi@1.8 +1 -1 + NTP_4_2_5P22 - ntpd/ntpd-opts.texi@1.73, 2008-08-17 05:30:29-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpd/ntpdsim.1@1.8 +2 -2 + NTP_4_2_5P22 - ntpd/ntpd.1@1.72, 2008-08-17 05:30:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpdc/ntpdc-opts.c@1.9 +2 -2 + NTP_4_2_5P22 - ntpd/ntpdsim-opts.c@1.74, 2008-08-17 05:30:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpdc/ntpdc-opts.h@1.9 +3 -3 + NTP_4_2_5P22 - ntpd/ntpdsim-opts.h@1.74, 2008-08-17 05:30:31-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + ntpdc/ntpdc-opts.texi@1.8 +1 -1 + NTP_4_2_5P22 - ntpd/ntpdsim-opts.texi@1.72, 2008-08-17 05:30:32-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpdc/ntpdc.1@1.8 +2 -2 + NTP_4_2_5P22 - ntpd/ntpdsim.1@1.72, 2008-08-17 05:30:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpq/ntpq-opts.c@1.9 +2 -2 + NTP_4_2_5P22 - ntpdc/ntpdc-opts.c@1.74, 2008-08-17 05:30:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ntpq/ntpq-opts.h@1.9 +3 -3 + NTP_4_2_5P22 - ntpdc/ntpdc-opts.h@1.74, 2008-08-17 05:30:34-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + ntpq/ntpq-opts.texi@1.8 +1 -1 + NTP_4_2_5P22 - ntpdc/ntpdc-opts.texi@1.72, 2008-08-17 05:30:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + ntpq/ntpq.1@1.8 +2 -2 + NTP_4_2_5P22 - ntpdc/ntpdc.1@1.72, 2008-08-17 05:30:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + packageinfo.sh@1.25 +1 -1 + NTP_4_2_5P22 - ntpq/ntpq-opts.c@1.76, 2008-08-17 05:30:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/sntp-opts.c@1.9 +2 -2 + NTP_4_2_5P22 - ntpq/ntpq-opts.h@1.76, 2008-08-17 05:30:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + sntp/sntp-opts.h@1.9 +3 -3 + NTP_4_2_5P22 - ntpq/ntpq-opts.texi@1.73, 2008-08-17 05:30:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + sntp/sntp-opts.texi@1.8 +1 -1 + NTP_4_2_5P22 - ntpq/ntpq.1@1.72, 2008-08-17 05:30:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + sntp/sntp.1@1.8 +2 -2 + NTP_4_2_5P22 - packageinfo.sh@1.101, 2008-08-17 05:30:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + util/ntp-keygen-opts.c@1.10 +2 -2 + NTP_4_2_5P22 - sntp/sntp-opts.c@1.72, 2008-08-17 05:30:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + util/ntp-keygen-opts.h@1.10 +3 -3 + NTP_4_2_5P22 - sntp/sntp-opts.h@1.72, 2008-08-17 05:30:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + util/ntp-keygen-opts.texi@1.9 +2 -2 + NTP_4_2_5P22 - sntp/sntp-opts.texi@1.69, 2008-08-17 05:30:39-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 + util/ntp-keygen.1@1.9 +2 -2 + NTP_4_2_5P22 - sntp/sntp.1@1.72, 2008-08-17 05:30:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 +ChangeSet@1.1440.1.78, 2007-04-13 03:57:20-04:00, stenn@whimsy.udel.edu + refclock_wwv.c fixes from Dave Mills - util/ntp-keygen-opts.c@1.73, 2008-08-17 05:30:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ChangeLog@1.26 +1 -0 + refclock_wwv.c fixes from Dave Mills - util/ntp-keygen-opts.h@1.73, 2008-08-17 05:30:41-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5 + ntpd/refclock_wwv.c@1.71 +9 -7 + refclock_wwv.c fixes from Dave Mills - util/ntp-keygen-opts.texi@1.71, 2008-08-17 05:30:42-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5 +ChangeSet@1.1440.1.77, 2007-04-13 02:10:55-04:00, stenn@whimsy.udel.edu + [Bug 810] Fix ntp-keygen documentation - util/ntp-keygen.1@1.71, 2008-08-17 05:30:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5 + ChangeLog@1.25 +1 -0 + [Bug 810] Fix ntp-keygen documentation -ChangeSet@1.1540, 2008-08-17 05:29:47-04:00, stenn@whimsy.udel.edu +1 -0 - typo + util/ntp-keygen-opts.c@1.9 +1 -1 + [Bug 810] Fix ntp-keygen documentation - scripts/addChangeLogTag@1.2, 2008-08-17 05:29:37-04:00, stenn@whimsy.udel.edu +1 -1 - typo + util/ntp-keygen-opts.def@1.7 +37 -20 + [Bug 810] Fix ntp-keygen documentation -ChangeSet@1.1539, 2008-08-17 03:28:53-04:00, stenn@whimsy.udel.edu +5 -0 - 4.2.4p5 prep + util/ntp-keygen-opts.h@1.9 +1 -1 + [Bug 810] Fix ntp-keygen documentation - .point-changed-filelist@1.2, 2008-08-17 03:27:42-04:00, stenn@whimsy.udel.edu +1 -0 - 4.2.4p5 prep + util/ntp-keygen-opts.texi@1.8 +39 -19 + [Bug 810] Fix ntp-keygen documentation - NEWS@1.99, 2008-08-17 03:27:42-04:00, stenn@whimsy.udel.edu +17 -0 - 4.2.4p5 prep + util/ntp-keygen.1@1.8 +39 -19 + [Bug 810] Fix ntp-keygen documentation - packageinfo.sh@1.100, 2008-08-17 03:27:43-04:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p5 prep +ChangeSet@1.1440.1.76, 2007-04-12 08:20:16-04:00, stenn@whimsy.udel.edu + NTP_4_2_5P21 + TAG: NTP_4_2_5P21 - scripts/addChangeLogTag@1.1, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +27 -0 - BitKeeper file /deacon/backroom/ntp-stable/scripts/addChangeLogTag + ntpd/ntpd-opts.c@1.8 +4 -4 + NTP_4_2_5P21 - scripts/addChangeLogTag@1.0, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.8 +3 -3 + NTP_4_2_5P21 - scripts/genChangeLogTag@1.1, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +6 -0 - BitKeeper file /deacon/backroom/ntp-stable/scripts/genChangeLogTag + ntpd/ntpd-opts.texi@1.7 +2 -2 + NTP_4_2_5P21 - scripts/genChangeLogTag@1.0, 2008-08-17 03:27:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.1@1.7 +2 -2 + NTP_4_2_5P21 -ChangeSet@1.1538, 2008-08-16 22:42:08-04:00, stenn@whimsy.udel.edu +2 -0 - [BUG 1051] Month off by one in leap second message written to clockstats + ntpd/ntpdsim-opts.c@1.8 +4 -4 + NTP_4_2_5P21 - ChangeLog@1.43, 2008-08-16 22:41:50-04:00, stenn@whimsy.udel.edu +2 -0 - [BUG 1051] Month off by one in leap second message written to clockstats + ntpd/ntpdsim-opts.h@1.8 +3 -3 + NTP_4_2_5P21 - ntpd/refclock_oncore.c@1.63, 2008-08-16 22:41:50-04:00, stenn@whimsy.udel.edu +1 -1 - [BUG 1051] Month off by one in leap second message written to clockstats + ntpd/ntpdsim-opts.texi@1.7 +1 -1 + NTP_4_2_5P21 -ChangeSet@1.1537, 2008-08-10 07:44:31-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P5_RC2 - TAG: NTP_4_2_4P5_RC2 + ntpd/ntpdsim.1@1.7 +2 -2 + NTP_4_2_5P21 - ntpd/ntpd-opts.c@1.73, 2008-08-10 07:44:09-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + ntpdc/ntpdc-opts.c@1.8 +4 -4 + NTP_4_2_5P21 - ntpd/ntpd-opts.h@1.73, 2008-08-10 07:44:09-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + ntpdc/ntpdc-opts.h@1.8 +3 -3 + NTP_4_2_5P21 - ntpd/ntpd-opts.texi@1.72, 2008-08-10 07:44:10-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + ntpdc/ntpdc-opts.texi@1.7 +2 -2 + NTP_4_2_5P21 - ntpd/ntpd.1@1.71, 2008-08-10 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + ntpdc/ntpdc.1@1.7 +2 -2 + NTP_4_2_5P21 - ntpd/ntpdsim-opts.c@1.73, 2008-08-10 07:44:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + ntpq/ntpq-opts.c@1.8 +4 -4 + NTP_4_2_5P21 - ntpd/ntpdsim-opts.h@1.73, 2008-08-10 07:44:12-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + ntpq/ntpq-opts.h@1.8 +3 -3 + NTP_4_2_5P21 - ntpd/ntpdsim-opts.texi@1.71, 2008-08-10 07:44:12-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + ntpq/ntpq-opts.texi@1.7 +2 -2 + NTP_4_2_5P21 - ntpd/ntpdsim.1@1.71, 2008-08-10 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + ntpq/ntpq.1@1.7 +2 -2 + NTP_4_2_5P21 - ntpdc/ntpdc-opts.c@1.73, 2008-08-10 07:44:14-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + packageinfo.sh@1.24 +1 -1 + NTP_4_2_5P21 - ntpdc/ntpdc-opts.h@1.73, 2008-08-10 07:44:15-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + sntp/sntp-opts.c@1.8 +2 -2 + NTP_4_2_5P21 - ntpdc/ntpdc-opts.texi@1.71, 2008-08-10 07:44:16-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + sntp/sntp-opts.h@1.8 +3 -3 + NTP_4_2_5P21 - ntpdc/ntpdc.1@1.71, 2008-08-10 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + sntp/sntp-opts.texi@1.7 +1 -1 + NTP_4_2_5P21 - ntpq/ntpq-opts.c@1.75, 2008-08-10 07:44:17-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + sntp/sntp.1@1.7 +2 -2 + NTP_4_2_5P21 - ntpq/ntpq-opts.h@1.75, 2008-08-10 07:44:18-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + util/ntp-keygen-opts.c@1.8 +4 -4 + NTP_4_2_5P21 - ntpq/ntpq-opts.texi@1.72, 2008-08-10 07:44:19-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + util/ntp-keygen-opts.h@1.8 +3 -3 + NTP_4_2_5P21 - ntpq/ntpq.1@1.71, 2008-08-10 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + util/ntp-keygen-opts.texi@1.7 +2 -2 + NTP_4_2_5P21 - packageinfo.sh@1.99, 2008-08-10 07:44:20-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + util/ntp-keygen.1@1.7 +2 -2 + NTP_4_2_5P21 - sntp/sntp-opts.c@1.71, 2008-08-10 07:44:22-04:00, stenn@whimsy.udel.edu +4 -5 - NTP_4_2_4P5_RC2 +ChangeSet@1.1436.1.37, 2007-04-12 06:32:19-04:00, stenn@whimsy.udel.edu + Added ntp2 mirror - sntp/sntp-opts.h@1.71, 2008-08-10 07:44:23-04:00, stenn@whimsy.udel.edu +5 -6 - NTP_4_2_4P5_RC2 + BitKeeper/triggers/2mirrors@1.4 +1 -0 + Added ntp2 mirror - sntp/sntp-opts.texi@1.68, 2008-08-10 07:44:23-04:00, stenn@whimsy.udel.edu +2 -3 - NTP_4_2_4P5_RC2 +ChangeSet@1.1440.1.74, 2007-04-12 05:47:01-04:00, stenn@whimsy.udel.edu + autogen upgrade - sntp/sntp.1@1.71, 2008-08-10 07:44:24-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + BitKeeper/deleted/.del-COPYING.lgpl@1.3 +0 -0 + Delete: libopts/COPYING.lgpl - util/ntp-keygen-opts.c@1.72, 2008-08-10 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + BitKeeper/deleted/.del-COPYING.lgpl~54a90ba0899593cb@1.2 +0 -0 + Delete: sntp/libopts/COPYING.lgpl - util/ntp-keygen-opts.h@1.72, 2008-08-10 07:44:25-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC2 + BitKeeper/deleted/.del-COPYING.mbsd@1.2 +0 -0 + Delete: libopts/COPYING.mbsd - util/ntp-keygen-opts.texi@1.70, 2008-08-10 07:44:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC2 + BitKeeper/deleted/.del-COPYING.mbsd~9b1945bb2136c70b@1.2 +0 -0 + Delete: sntp/libopts/COPYING.mbsd - util/ntp-keygen.1@1.70, 2008-08-10 07:44:27-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC2 + BitKeeper/deleted/.del-MakeDefs.inc@1.2 +0 -0 + Delete: libopts/MakeDefs.inc -ChangeSet@1.1531.3.1, 2008-08-10 02:22:22-04:00, stenn@whimsy.udel.edu +1 -0 - triggert needs to handle rooted RESYNC paths now + BitKeeper/deleted/.del-MakeDefs.inc~2b8fdfc9df6d652d@1.2 +0 -0 + Delete: sntp/libopts/MakeDefs.inc - BitKeeper/triggers/triggert@1.5, 2008-08-10 02:22:11-04:00, stenn@whimsy.udel.edu +3 -2 - triggert needs to handle rooted RESYNC paths now + BitKeeper/deleted/.del-Makefile.am@1.7 +0 -0 + Delete: libopts/Makefile.am -ChangeSet@1.1534, 2008-08-09 20:05:06-04:00, stenn@whimsy.udel.edu +2 -0 - AutoGen'd files must be writable + BitKeeper/deleted/.del-Makefile.am~fa9bd87b6045015c@1.5 +0 -0 + Delete: sntp/libopts/Makefile.am - sntp/Makefile.am@1.23, 2008-08-09 20:04:56-04:00, stenn@whimsy.udel.edu +2 -2 - AutoGen'd files must be writable + BitKeeper/deleted/.del-README@1.2 +0 -0 + Delete: libopts/README - sntp/sntp-opts.menu@1.3, 2008-08-09 20:04:10-04:00, stenn@whimsy.udel.edu +0 -0 - Change mode to -rw-rw-r-- + BitKeeper/deleted/.del-README~1ae087758ee867d4@1.2 +0 -0 + Delete: sntp/libopts/README -ChangeSet@1.1531.2.1, 2008-08-07 20:44:31+02:00, burnicki@pogo.udel.edu +3 -0 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). + BitKeeper/deleted/.del-autoopts.c@1.11 +0 -0 + Delete: libopts/autoopts.c - ChangeLog@1.39.2.1, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +2 -0 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). + BitKeeper/deleted/.del-autoopts.c~5b417341bc85d7a8@1.8 +0 -0 + Delete: sntp/libopts/autoopts.c - ntpd/ntp_peer.c@1.99.1.1, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +10 -2 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). + BitKeeper/deleted/.del-autoopts.h@1.10 +0 -0 + Delete: libopts/autoopts.h - ports/winnt/ntpd/ntservice.c@1.11, 2008-08-07 20:44:30+02:00, burnicki@pogo.udel.edu +8 -1 - [Bug 450] Windows only: Under original Windows NT we must not discard the - wildcard socket to workaround a bug in NT's getsockname(). + BitKeeper/deleted/.del-autoopts.h~8cdce21b181a1a01@1.8 +0 -0 + Delete: sntp/libopts/autoopts.h -ChangeSet@1.1531.1.2, 2008-08-05 09:56:08+02:00, burnicki@pogo.udel.edu +1 -0 - Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. + BitKeeper/deleted/.del-boolean.c@1.9 +0 -0 + Delete: libopts/boolean.c - ports/winnt/ntpd/ntp_iocompletionport.c@1.26, 2008-08-05 09:56:08+02:00, burnicki@pogo.udel.edu +0 -8 - Removed Windows-specific debug code which has been added in ntp-dev and fails to compile in ntp-stable. + BitKeeper/deleted/.del-boolean.c~a5d10c8997e6a2e2@1.6 +0 -0 + Delete: sntp/libopts/boolean.c -ChangeSet@1.1531.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +10 -0 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. - Emit a warning if that keyword is used for configuration. + BitKeeper/deleted/.del-compat.h@1.13 +0 -0 + Delete: libopts/compat/compat.h - ChangeLog@1.39.1.1, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +3 -0 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. - Emit a warning if that keyword is used for configuration. + BitKeeper/deleted/.del-compat.h~9682d0ac273ae32@1.9 +0 -0 + Delete: sntp/libopts/compat/compat.h - html/confopt.html@1.36, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -2 - Bug 841: Obsolete the "dynamic" keyword. + BitKeeper/deleted/.del-configfile.c@1.11 +0 -0 + Delete: libopts/configfile.c - html/ntpdc.html@1.27, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +2 -3 - Bug 841: Obsolete the "dynamic" keyword. + BitKeeper/deleted/.del-configfile.c~8194f784686fa804@1.8 +0 -0 + Delete: sntp/libopts/configfile.c - include/ntp.h@1.129, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -1 - Bug 841: Obsolete the "dynamic" keyword. + BitKeeper/deleted/.del-cook.c@1.10 +0 -0 + Delete: libopts/cook.c - include/ntp_request.h@1.31, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +0 -1 - Bug 841: Obsolete the "dynamic" keyword. + BitKeeper/deleted/.del-cook.c~e48d079a438432dc@1.7 +0 -0 + Delete: sntp/libopts/cook.c - ntpd/ntp_config.c@1.144, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +4 -2 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. - Emit a warning if that keyword is used for configuration. + BitKeeper/deleted/.del-enumeration.c@1.10 +0 -0 + Delete: libopts/enumeration.c - ntpd/ntp_intres.c@1.52, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +1 -3 - Bug 841: Obsolete the "dynamic" keyword. + BitKeeper/deleted/.del-enumeration.c~5f4e6af2706370ae@1.7 +0 -0 + Delete: sntp/libopts/enumeration.c - ntpd/ntp_peer.c@1.100, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +5 -25 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. + BitKeeper/deleted/.del-environment.c@1.9 +0 -0 + Delete: libopts/environment.c - ntpd/ntp_request.c@1.66, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +1 -3 - Bug 841: Obsolete the "dynamic" keyword. + BitKeeper/deleted/.del-environment.c~2bae2966695067c2@1.6 +0 -0 + Delete: sntp/libopts/environment.c - ntpdc/ntpdc_ops.c@1.50, 2008-08-05 09:50:23+02:00, burnicki@pogo.udel.edu +3 -3 - [Bug 841] Obsolete the "dynamic" keyword and make deferred binding - to local interfaces the default. + BitKeeper/deleted/.del-genshell.c@1.10 +0 -0 + Delete: libopts/genshell.c -ChangeSet@1.1532, 2008-07-22 11:41:26+02:00, burnicki@pogo.udel.edu +2 -0 - [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + BitKeeper/deleted/.del-genshell.c~1fd152b2b52bdab@1.7 +0 -0 + Delete: sntp/libopts/genshell.c - ChangeLog@1.40, 2008-07-22 11:41:25+02:00, burnicki@pogo.udel.edu +1 -0 - [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + BitKeeper/deleted/.del-genshell.h@1.10 +0 -0 + Delete: libopts/genshell.h - libntp/machines.c@1.19, 2008-07-22 11:41:25+02:00, burnicki@pogo.udel.edu +2 -2 - [Bug 1038] Built-in getpass() function also prompts for password if not built with DEBUG. + BitKeeper/deleted/.del-genshell.h~375f0fa5b925f454@1.7 +0 -0 + Delete: sntp/libopts/genshell.h -ChangeSet@1.1531, 2008-05-20 03:51:01-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P5_RC1 - TAG: NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-libopts.c@1.4 +0 -0 + Delete: libopts/libopts.c - ntpd/ntpd-opts.c@1.72, 2008-05-20 03:50:37-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-libopts.c~58b8fbed850e6d5e@1.4 +0 -0 + Delete: sntp/libopts/libopts.c - ntpd/ntpd-opts.h@1.72, 2008-05-20 03:50:37-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-libopts.m4@1.15 +0 -0 + Delete: libopts/m4/libopts.m4 - ntpd/ntpd-opts.texi@1.71, 2008-05-20 03:50:38-04:00, stenn@whimsy.udel.edu +8 -11 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-libopts.m4~9e0f33f57d3a0a9@1.12 +0 -0 + Delete: sntp/libopts/m4/libopts.m4 - ntpd/ntpd.1@1.70, 2008-05-20 03:50:39-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-liboptschk.m4@1.4 +0 -0 + Delete: libopts/m4/liboptschk.m4 - ntpd/ntpdsim-opts.c@1.72, 2008-05-20 03:50:40-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-liboptschk.m4~bbeebebe76865058@1.4 +0 -0 + Delete: sntp/libopts/m4/liboptschk.m4 - ntpd/ntpdsim-opts.h@1.72, 2008-05-20 03:50:41-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-libtool.m4@1.2 +0 -0 + Delete: libopts/m4/libtool.m4 - ntpd/ntpdsim-opts.texi@1.70, 2008-05-20 03:50:42-04:00, stenn@whimsy.udel.edu +3 -4 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-libtool.m4~db8acbd0fb34597f@1.2 +0 -0 + Delete: sntp/libopts/m4/libtool.m4 - ntpd/ntpdsim.1@1.70, 2008-05-20 03:50:43-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-load.c@1.11 +0 -0 + Delete: libopts/load.c - ntpdc/ntpdc-opts.c@1.72, 2008-05-20 03:50:44-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-load.c~59960aa12bb95bf7@1.8 +0 -0 + Delete: sntp/libopts/load.c - ntpdc/ntpdc-opts.h@1.72, 2008-05-20 03:50:44-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-makeshell.c@1.12 +0 -0 + Delete: libopts/makeshell.c - ntpdc/ntpdc-opts.texi@1.70, 2008-05-20 03:50:45-04:00, stenn@whimsy.udel.edu +5 -6 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-makeshell.c~4fcd12fc31c0a4a4@1.9 +0 -0 + Delete: sntp/libopts/makeshell.c - ntpdc/ntpdc.1@1.70, 2008-05-20 03:50:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-nested.c@1.10 +0 -0 + Delete: libopts/nested.c - ntpq/ntpq-opts.c@1.74, 2008-05-20 03:50:47-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-nested.c~85346d5d12098689@1.7 +0 -0 + Delete: sntp/libopts/nested.c - ntpq/ntpq-opts.h@1.74, 2008-05-20 03:50:47-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-numeric.c@1.10 +0 -0 + Delete: libopts/numeric.c - ntpq/ntpq-opts.texi@1.71, 2008-05-20 03:50:48-04:00, stenn@whimsy.udel.edu +5 -6 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-numeric.c~cdb7deb5cf6f27c2@1.7 +0 -0 + Delete: sntp/libopts/numeric.c - ntpq/ntpq.1@1.70, 2008-05-20 03:50:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-options.h@1.11 +0 -0 + Delete: libopts/autoopts/options.h - packageinfo.sh@1.98, 2008-05-20 03:50:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-options.h~6eb465cb95a56bee@1.8 +0 -0 + Delete: sntp/libopts/autoopts/options.h - sntp/sntp-opts.c@1.70, 2008-05-20 03:50:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-pathfind.c@1.10 +0 -0 + Delete: libopts/compat/pathfind.c - sntp/sntp-opts.h@1.70, 2008-05-20 03:50:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-pathfind.c~a0863179d884d4a4@1.7 +0 -0 + Delete: sntp/libopts/compat/pathfind.c - sntp/sntp-opts.texi@1.67, 2008-05-20 03:50:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-pgusage.c@1.10 +0 -0 + Delete: libopts/pgusage.c - sntp/sntp.1@1.70, 2008-05-20 03:50:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-pgusage.c~d981c42eb301cfdd@1.6 +0 -0 + Delete: sntp/libopts/pgusage.c - util/ntp-keygen-opts.c@1.71, 2008-05-20 03:50:54-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-proto.h@1.12 +0 -0 + Delete: libopts/proto.h - util/ntp-keygen-opts.h@1.71, 2008-05-20 03:50:54-04:00, stenn@whimsy.udel.edu +6 -7 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-proto.h~fa076f6dd9d0667e@1.9 +0 -0 + Delete: sntp/libopts/proto.h - util/ntp-keygen-opts.texi@1.69, 2008-05-20 03:50:55-04:00, stenn@whimsy.udel.edu +7 -9 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-putshell.c@1.11 +0 -0 + Delete: libopts/putshell.c - util/ntp-keygen.1@1.69, 2008-05-20 03:50:56-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P5_RC1 + BitKeeper/deleted/.del-putshell.c~24959f5e1ba688e6@1.8 +0 -0 + Delete: sntp/libopts/putshell.c -ChangeSet@1.1530, 2008-05-18 05:14:37-04:00, stenn@whimsy.udel.edu +1 -0 - Start the 4.2.4p5 release candidate cycle + BitKeeper/deleted/.del-restore.c@1.10 +0 -0 + Delete: libopts/restore.c - packageinfo.sh@1.97, 2008-05-18 05:14:27-04:00, stenn@whimsy.udel.edu +1 -1 - Start the 4.2.4p5 release candidate cycle + BitKeeper/deleted/.del-restore.c~eada4acbf21cd8bf@1.6 +0 -0 + Delete: sntp/libopts/restore.c -ChangeSet@1.1529, 2008-04-11 18:41:57-04:00, stenn@whimsy.udel.edu +1 -0 - Solaris _XOPEN_SOURCE updates + BitKeeper/deleted/.del-save.c@1.11 +0 -0 + Delete: libopts/save.c - configure.ac@1.401, 2008-04-11 18:41:47-04:00, stenn@whimsy.udel.edu +5 -1 - Solaris _XOPEN_SOURCE updates + BitKeeper/deleted/.del-save.c~a29f5bd429a568bb@1.8 +0 -0 + Delete: sntp/libopts/save.c -ChangeSet@1.1524.1.3, 2008-04-10 02:09:52-04:00, stenn@pogo.udel.edu +1 -0 - Changelog cleanup + BitKeeper/deleted/.del-snprintf.c@1.5 +0 -0 + Delete: libopts/compat/snprintf.c - ChangeLog@1.37.1.2, 2008-04-10 02:08:57-04:00, stenn@pogo.udel.edu +2 -1 + BitKeeper/deleted/.del-snprintf.c~66578c716014cd3d@1.4 +0 -0 + Delete: sntp/libopts/compat/snprintf.c -ChangeSet@1.1524.1.2, 2008-04-08 12:20:22+02:00, burnicki@pogo.udel.edu +1 -0 - Always sleep a little before calling doconfigure() to make sure the network is completely up. + BitKeeper/deleted/.del-sort.c@1.9 +0 -0 + Delete: libopts/sort.c - ntpd/ntp_intres.c@1.51, 2008-04-08 12:20:21+02:00, burnicki@pogo.udel.edu +5 -6 - Always sleep a little before calling doconfigure() to make sure the network is completely up. + BitKeeper/deleted/.del-sort.c~bec5a7fb6a01a5dc@1.5 +0 -0 + Delete: sntp/libopts/sort.c -ChangeSet@1.1524.1.1, 2008-04-03 10:19:03-04:00, burnicki@pogo.udel.edu +5 -0 - [Bug 987] Wake up the resolver thread/process when a new interface has become available. + BitKeeper/deleted/.del-stack.c@1.11 +0 -0 + Delete: libopts/stack.c - ChangeLog@1.37.1.1, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +1 -0 - [Bug 987] Wake up the resolver thread/process when a new interface has become available. + BitKeeper/deleted/.del-stack.c~e817b57b18b315c1@1.8 +0 -0 + Delete: sntp/libopts/stack.c - include/ntpd.h@1.98, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +5 -0 - Added vars used to wake up the resolver process/thread. + BitKeeper/deleted/.del-strchr.c@1.4 +0 -0 + Delete: libopts/compat/strchr.c - ntpd/ntp_config.c@1.143, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +34 -1 - Initialize synchronization variables when the resolver process/thread is started. + BitKeeper/deleted/.del-strchr.c~80e88afbe7e2209a@1.4 +0 -0 + Delete: sntp/libopts/compat/strchr.c - ntpd/ntp_intres.c@1.50, 2008-04-03 10:18:59-04:00, burnicki@pogo.udel.edu +64 -65 - Enable the resolver to be woken up when a new interface has become available. + BitKeeper/deleted/.del-strdup.c@1.4 +0 -0 + Delete: libopts/compat/strdup.c - ntpd/ntp_io.c@1.256, 2008-04-03 10:19:00-04:00, burnicki@pogo.udel.edu +25 -5 - Wake up the resolver thread/process when a new interface has become available. + BitKeeper/deleted/.del-strdup.c~1f262be5e55c3c4a@1.3 +0 -0 + Delete: sntp/libopts/compat/strdup.c -ChangeSet@1.1527, 2008-03-24 22:12:42-04:00, mayer@pogo.udel.edu +1 -0 - bugs 993 a d 959 + BitKeeper/deleted/.del-streqvcmp.c@1.10 +0 -0 + Delete: libopts/streqvcmp.c - ChangeLog@1.38, 2008-03-24 22:12:26-04:00, mayer@pogo.udel.edu +2 -0 - bugs 993 a d 959 + BitKeeper/deleted/.del-streqvcmp.c~66420c6082b06827@1.7 +0 -0 + Delete: sntp/libopts/streqvcmp.c -ChangeSet@1.1526, 2008-03-24 21:41:55-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 959] Refclock on Windows not properly releasing recvbuffs + BitKeeper/deleted/.del-text_mmap.c@1.9 +0 -0 + Delete: libopts/text_mmap.c - ports/winnt/ntpd/ntp_iocompletionport.c@1.25, 2008-03-24 21:41:37-04:00, mayer@pogo.udel.edu +25 -13 - [Bug 959] Refclock on Windows not properly releasing recvbuffs + BitKeeper/deleted/.del-text_mmap.c~f1915a52b87816ba@1.6 +0 -0 + Delete: sntp/libopts/text_mmap.c -ChangeSet@1.1525, 2008-03-24 21:40:32-04:00, mayer@pogo.udel.edu +1 -0 - [Bug 993] Windows: Fix memory leak when fetching system messages + BitKeeper/deleted/.del-tokenize.c@1.6 +0 -0 + Delete: libopts/tokenize.c - ports/winnt/libisc/isc_strerror.c@1.5, 2008-03-24 21:40:07-04:00, mayer@pogo.udel.edu +78 -18 - [Bug 993] Windows: Fix memory leak when fetching system messages + BitKeeper/deleted/.del-tokenize.c~ae2f23dbb2bee589@1.5 +0 -0 + Delete: sntp/libopts/tokenize.c -ChangeSet@1.1520.3.5, 2008-03-22 02:12:10-05:00, stenn@whimsy.udel.edu +2 -0 - [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + BitKeeper/deleted/.del-usage-txt.h@1.10 +0 -0 + Delete: libopts/autoopts/usage-txt.h - ChangeLog@1.35.3.4, 2008-03-22 02:11:57-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + BitKeeper/deleted/.del-usage-txt.h~6ce4dce87430d1b@1.7 +0 -0 + Delete: sntp/libopts/autoopts/usage-txt.h - libisc/net.c@1.9, 2008-03-22 02:11:58-05:00, stenn@whimsy.udel.edu +1 -1 - [Bug 977] Fix mismatching #ifdefs for builds without IPv6 + BitKeeper/deleted/.del-usage.c@1.10 +0 -0 + Delete: libopts/usage.c -ChangeSet@1.1520.3.4, 2008-03-22 02:02:36-05:00, stenn@whimsy.udel.edu +3 -0 - Update the copyright year + BitKeeper/deleted/.del-usage.c~c868ef1e661a6eb1@1.8 +0 -0 + Delete: sntp/libopts/usage.c - ChangeLog@1.35.3.3, 2008-03-22 02:02:24-05:00, stenn@whimsy.udel.edu +8 -6 - Update the copyright year + BitKeeper/deleted/.del-version.c@1.10 +0 -0 + Delete: libopts/version.c - html/copyright.html@1.37, 2008-03-22 02:02:25-05:00, stenn@whimsy.udel.edu +1 -1 - Update the copyright year + BitKeeper/deleted/.del-version.c~a426e6b58b20d06@1.7 +0 -0 + Delete: sntp/libopts/version.c - include/copyright.def@1.6, 2008-03-22 02:02:25-05:00, stenn@whimsy.udel.edu +1 -1 - Update the copyright year + BitKeeper/deleted/.del-windows-config.h@1.6 +0 -0 + Delete: libopts/compat/windows-config.h -ChangeSet@1.1520.3.3, 2008-03-22 01:58:52-05:00, stenn@whimsy.udel.edu +5 -0 - Make autogen-generated files writable + BitKeeper/deleted/.del-windows-config.h~36f7ad2ccf764ad2@1.4 +0 -0 + Delete: sntp/libopts/compat/windows-config.h - ntpd/Makefile.am@1.54, 2008-03-22 01:57:08-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + clockstuff/clktest-opts.c@1.10 +8 -7 + autogen upgrade - ntpdc/Makefile.am@1.35, 2008-03-22 01:57:09-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + clockstuff/clktest-opts.h@1.10 +8 -14 + autogen upgrade - ntpq/Makefile.am@1.27, 2008-03-22 01:57:10-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.lgpl - sntp/Makefile.am@1.22, 2008-03-22 01:57:11-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + libopts/COPYING.lgpl@1.0 +0 -0 - util/Makefile.am@1.36, 2008-03-22 01:57:11-05:00, stenn@whimsy.udel.edu +1 -1 - Make autogen-generated files writable + libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/COPYING.mbsd -ChangeSet@1.1520.4.1, 2008-03-16 09:15:13-04:00, burnicki@pogo.udel.edu +2 -0 - [Bug 957] Windows only: Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + libopts/COPYING.mbsd@1.0 +0 -0 - ChangeLog@1.35.4.1, 2008-03-16 09:15:10-04:00, burnicki@pogo.udel.edu +3 -0 - [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/MakeDefs.inc - ports/winnt/ntpd/ntservice.c@1.10, 2008-03-16 09:15:11-04:00, burnicki@pogo.udel.edu +11 -2 - [Bug 957] Let command line parameters from the Windows SCM GUI override the standard parameters from the ImagePath registry key. + libopts/MakeDefs.inc@1.0 +0 -0 -ChangeSet@1.1520.3.1, 2008-03-03 11:50:50+01:00, martin@pc-martin.py.meinberg.de +2 -0 - [Bug 532] nptdate timeout is too long if several servers are supplied - [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools - [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't - [Bug 908] ntpdate crashes sometimes - [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) - [Bug 997] ntpdate buffer too small and unsafe - Under Windows check whether NTP port in use under same conditions as under other OSs. - Fixed some typos and indents (tabs/spaces). + libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/Makefile.am + + libopts/Makefile.am@1.0 +0 -0 + + libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/README + + libopts/README@1.0 +0 -0 + + libopts/autoopts.c@1.1 +1101 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.c + + libopts/autoopts.c@1.0 +0 -0 + + libopts/autoopts.h@1.1 +377 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts.h + + libopts/autoopts.h@1.0 +0 -0 + + libopts/autoopts/options.h@1.1 +964 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/options.h + + libopts/autoopts/options.h@1.0 +0 -0 + + libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/autoopts/usage-txt.h + + libopts/autoopts/usage-txt.h@1.0 +0 -0 + + libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/boolean.c + + libopts/boolean.c@1.0 +0 -0 + + libopts/compat/compat.h@1.1 +314 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/compat.h + + libopts/compat/compat.h@1.0 +0 -0 + + libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/pathfind.c + + libopts/compat/pathfind.c@1.0 +0 -0 + + libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/snprintf.c + + libopts/compat/snprintf.c@1.0 +0 -0 + + libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strchr.c + + libopts/compat/strchr.c@1.0 +0 -0 + + libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strdup.c + + libopts/compat/strdup.c@1.0 +0 -0 + + libopts/compat/windows-config.h@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h + + libopts/compat/windows-config.h@1.0 +0 -0 + + libopts/configfile.c@1.1 +1288 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/configfile.c + + libopts/configfile.c@1.0 +0 -0 + + libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/cook.c + + libopts/cook.c@1.0 +0 -0 + + libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/enumeration.c + + libopts/enumeration.c@1.0 +0 -0 + + libopts/environment.c@1.1 +260 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/environment.c + + libopts/environment.c@1.0 +0 -0 + + libopts/genshell.c@1.1 +345 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.c + + libopts/genshell.c@1.0 +0 -0 + + libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/genshell.h + + libopts/genshell.h@1.0 +0 -0 + + libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/libopts.c + + libopts/libopts.c@1.0 +0 -0 + + libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/load.c + + libopts/load.c@1.0 +0 -0 + + libopts/m4/libopts.m4@1.1 +489 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/libopts.m4 + + libopts/m4/libopts.m4@1.0 +0 -0 + + libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/liboptschk.m4 + + libopts/m4/liboptschk.m4@1.0 +0 -0 + + libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/makeshell.c + + libopts/makeshell.c@1.0 +0 -0 + + libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/nested.c + + libopts/nested.c@1.0 +0 -0 + + libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/numeric.c + + libopts/numeric.c@1.0 +0 -0 + + libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/pgusage.c + + libopts/pgusage.c@1.0 +0 -0 + + libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/proto.h + + libopts/proto.h@1.0 +0 -0 + + libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/putshell.c + + libopts/putshell.c@1.0 +0 -0 + + libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/restore.c + + libopts/restore.c@1.0 +0 -0 + + libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/save.c + + libopts/save.c@1.0 +0 -0 + + libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/sort.c + + libopts/sort.c@1.0 +0 -0 + + libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/stack.c + + libopts/stack.c@1.0 +0 -0 + + libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/streqvcmp.c + + libopts/streqvcmp.c@1.0 +0 -0 + + libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/text_mmap.c + + libopts/text_mmap.c@1.0 +0 -0 + + libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/tokenize.c + + libopts/tokenize.c@1.0 +0 -0 + + libopts/usage.c@1.1 +731 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/usage.c + + libopts/usage.c@1.0 +0 -0 + + libopts/version.c@1.1 +176 -0 + BitKeeper file /deacon/backroom/ntp-dev/libopts/version.c + + libopts/version.c@1.0 +0 -0 + + ntpd/ntpd-opts.c@1.7 +9 -8 + autogen upgrade + + ntpd/ntpd-opts.h@1.7 +6 -12 + autogen upgrade - ChangeLog@1.35.3.1, 2008-03-03 11:50:49+01:00, martin@pc-martin.py.meinberg.de +10 -0 - [Bug 532] nptdate timeout is too long if several servers are supplied - [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools - [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't - [Bug 908] ntpdate crashes sometimes - [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) - [Bug 997] ntpdate buffer too small and unsafe - Under Windows check whether NTP port in use under same conditions as under other OSs. - Fixed some typos and indents (tabs/spaces). + ntpd/ntpdsim-opts.c@1.7 +9 -8 + autogen upgrade - ntpdate/ntpdate.c@1.62, 2008-03-03 11:50:49+01:00, martin@pc-martin.py.meinberg.de +101 -82 - [Bug 532] nptdate timeout is too long if several servers are supplied - [Bug 698] timeBeginPeriod is called without timeEndPeriod in some NTP tools - [Bug 857] ntpdate debug mode adjusts system clock when it shouldn't - [Bug 908] ntpdate crashes sometimes - [Bug 982] ntpdate(and ntptimeset) buffer overrun if HAVE_POLL_H isn't set (dup of 908) - [Bug 997] ntpdate buffer too small and unsafe - Under Windows check whether NTP port in use under same conditions as under other OSs. - Fixed some typos and indents (tabs/spaces). + ntpd/ntpdsim-opts.h@1.7 +6 -12 + autogen upgrade -ChangeSet@1.1520.2.7, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +2 -0 - [Bug 909] Define int32_t for Windows (backport from ntp-dev) + ntpdc/ntpdc-opts.c@1.7 +9 -8 + autogen upgrade - ChangeLog@1.35.2.3, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +1 -0 - [Bug 909] Define int32_t for Windows (backport from ntp-dev) + ntpdc/ntpdc-opts.h@1.7 +6 -12 + autogen upgrade - ports/winnt/include/config.h@1.47, 2008-02-20 12:13:24+01:00, martin@pc-martin4. +2 -0 - [Bug 909] Define int32_t for Windows (backport from ntp-dev) + ntpq/ntpq-opts.c@1.7 +9 -8 + autogen upgrade -ChangeSet@1.1520.2.6, 2008-02-19 11:08:55-05:00, burnicki@pogo.udel.edu +1 -0 - Fixed indentation. + ntpq/ntpq-opts.h@1.7 +6 -12 + autogen upgrade - ntpd/ntp_io.c@1.255, 2008-02-19 11:08:52-05:00, burnicki@pogo.udel.edu +1 -1 - Fixed indentation. + sntp/libopts/COPYING.lgpl@1.1 +502 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.lgpl -ChangeSet@1.1520.2.5, 2008-02-18 09:30:34-05:00, burnicki@pogo.udel.edu +1 -0 - Use new get_free_recv_buffer_alloc(). + sntp/libopts/COPYING.lgpl@1.0 +0 -0 - ports/winnt/ntpd/ntp_iocompletionport.c@1.24, 2008-02-18 09:30:31-05:00, burnicki@pogo.udel.edu +4 -4 - Use new get_free_recv_buffer_alloc(). + sntp/libopts/COPYING.mbsd@1.1 +26 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/COPYING.mbsd -ChangeSet@1.1520.2.4, 2008-02-17 17:48:29+00:00, kardel@pogo.udel.edu +1 -0 - recvbuff.c: - Bug 1000: add some pico optimizations + sntp/libopts/COPYING.mbsd@1.0 +0 -0 - libntp/recvbuff.c@1.29, 2008-02-17 17:42:21+00:00, kardel@pogo.udel.edu +5 -8 - Bug 1000: add some pico optimizations + sntp/libopts/MakeDefs.inc@1.1 +0 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/MakeDefs.inc -ChangeSet@1.1520.2.3, 2008-02-17 08:38:07+00:00, kardel@pogo.udel.edu +2 -0 - ntpd.c: - Bug 1000: avoid timer() starvation during high load conditions - ChangeLog: - Bug 1000: additionally fix timer() starvation during high load + sntp/libopts/MakeDefs.inc@1.0 +0 -0 - ChangeLog@1.35.2.2, 2008-02-17 08:37:20+00:00, kardel@pogo.udel.edu +1 -0 - Bug 1000: additionally fix timer() starvation during high load + sntp/libopts/Makefile.am@1.1 +24 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/Makefile.am - ntpd/ntpd.c@1.85, 2008-02-17 08:34:13+00:00, kardel@pogo.udel.edu +11 -0 - Bug 1000: avoid timer() starvation during high load conditions + sntp/libopts/Makefile.am@1.0 +0 -0 -ChangeSet@1.1520.2.2, 2008-02-17 08:10:59+00:00, kardel@pogo.udel.edu +1 -0 - recvbuff.c: - Bug 1000: replenish when having expeirenced empty free lists + sntp/libopts/README@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/README - libntp/recvbuff.c@1.28, 2008-02-17 08:09:37+00:00, kardel@pogo.udel.edu +1 -1 - Bug 1000: replenish when having expeirenced empty free lists + sntp/libopts/README@1.0 +0 -0 -ChangeSet@1.1520.2.1, 2008-02-17 07:31:29+00:00, kardel@pogo.udel.edu +4 -0 - recvbuff.c, recvbuff.h, ntp_io.c, ChangeLog: - Bug 1000: Potentially insufficient number of receive buffers at startup + sntp/libopts/autoopts.c@1.1 +1101 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.c - ChangeLog@1.35.2.1, 2008-02-17 07:29:23+00:00, kardel@pogo.udel.edu +3 -0 - Bug 1000: Potentially insufficient number of receive buffers at startup + sntp/libopts/autoopts.c@1.0 +0 -0 - include/recvbuff.h@1.13, 2008-02-17 07:30:35+00:00, kardel@pogo.udel.edu +2 -1 - Bug 1000: Potentially insufficient number of receive buffers at startup + sntp/libopts/autoopts.h@1.1 +377 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts.h - libntp/recvbuff.c@1.27, 2008-02-17 07:30:09+00:00, kardel@pogo.udel.edu +30 -11 - Bug 1000: Potentially insufficient number of receive buffers at startup + sntp/libopts/autoopts.h@1.0 +0 -0 - ntpd/ntp_io.c@1.254, 2008-02-17 07:30:50+00:00, kardel@pogo.udel.edu +6 -2 - Bug 1000: Potentially insufficient number of receive buffers at startup + sntp/libopts/autoopts/options.h@1.1 +964 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/options.h -ChangeSet@1.1520.1.1, 2008-01-26 06:43:33+00:00, kardel@pogo.udel.edu +3 -0 - ntpdbase-opts.def, ChangeLog, cmd_args.c: - remove minimum interface update interval restriction + sntp/libopts/autoopts/options.h@1.0 +0 -0 - ChangeLog@1.35.1.1, 2008-01-26 06:42:11+00:00, kardel@pogo.udel.edu +2 -0 - remove minimum interface update interval restriction + sntp/libopts/autoopts/usage-txt.h@1.1 +355 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/autoopts/usage-txt.h - ntpd/cmd_args.c@1.48, 2008-01-26 06:42:47+00:00, kardel@pogo.udel.edu +2 -2 - remove minimum interface update interval restriction + sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 - ntpd/ntpdbase-opts.def@1.11, 2008-01-26 06:43:10+00:00, kardel@pogo.udel.edu +1 -1 - remove minimum interface update interval restriction + sntp/libopts/boolean.c@1.1 +106 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/boolean.c -ChangeSet@1.1523, 2007-11-01 03:52:00-04:00, clemens@pogo.udel.edu +1 -0 - * Negative-sawtooth not applied correctly for oncore 12 channel - receiver. Fixed. - * Startup code for original LinuxPPS removed. LinuxPPS now - conforms to the PPSAPI. + sntp/libopts/boolean.c@1.0 +0 -0 - ChangeLog@1.36, 2007-11-01 03:51:58-04:00, clemens@pogo.udel.edu +4 -0 - * Negative-sawtooth not applied correctly for oncore 12 channel - receiver. Fixed. - * Startup code for original LinuxPPS removed. LinuxPPS now - conforms to the PPSAPI. + sntp/libopts/compat/compat.h@1.1 +314 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/compat.h -ChangeSet@1.1522, 2007-11-01 03:29:24-04:00, clemens@pogo.udel.edu +1 -0 - The original version of LinuxPPS did not comply with the PPSAPI and required - some changes to the startup code in refclock_oncore.c . The current version - complies, and these changes can be removed. + sntp/libopts/compat/compat.h@1.0 +0 -0 - ntpd/refclock_oncore.c@1.62, 2007-11-01 03:29:21-04:00, clemens@pogo.udel.edu +1 -56 - The original version of LinuxPPS did not comply with the PPSAPI and required - some changes to the startup code in refclock_oncore.c . The current version - complies, and these changes can be removed. + sntp/libopts/compat/pathfind.c@1.1 +339 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/pathfind.c -ChangeSet@1.1521, 2007-11-01 02:16:36-04:00, clemens@pogo.udel.edu +1 -0 - The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal - which is on the zero crossing of its internal clock, from its true value. the - refclock_oncore.c driver applies this difference to correct the time of the - provided timestamp. This value was being applied correctly for the 6 and 8 channel - receivers, but not for the 12 channel. This has been corrected. + sntp/libopts/compat/pathfind.c@1.0 +0 -0 - ntpd/refclock_oncore.c@1.61, 2007-11-01 02:16:33-04:00, clemens@pogo.udel.edu +2 -2 - The oncore hardware provides a 'negative saw-tooth' the offset of the PPS signal - which is on the zero crossing of its internal clock, from its true value. the - refclock_oncore.c driver applies this difference to correct the time of the - provided timestamp. This value was being applied correctly for the 6 and 8 channel - receivers, but not for the 12 channel. This has been corrected. + sntp/libopts/compat/snprintf.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/snprintf.c -ChangeSet@1.1520, 2007-09-10 20:40:19-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P4 - TAG: NTP_4_2_4P4 + sntp/libopts/compat/snprintf.c@1.0 +0 -0 - ntpd/ntpd-opts.c@1.71, 2007-09-10 20:39:55-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/compat/strchr.c@1.1 +60 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strchr.c - ntpd/ntpd-opts.h@1.71, 2007-09-10 20:39:56-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + sntp/libopts/compat/strchr.c@1.0 +0 -0 - ntpd/ntpd-opts.texi@1.70, 2007-09-10 20:39:57-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/libopts/compat/strdup.c@1.1 +19 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strdup.c - ntpd/ntpd.1@1.69, 2007-09-10 20:39:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/compat/strdup.c@1.0 +0 -0 - ntpd/ntpdsim-opts.c@1.71, 2007-09-10 20:39:58-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/compat/windows-config.h@1.1 +129 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h - ntpd/ntpdsim-opts.h@1.71, 2007-09-10 20:39:58-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + sntp/libopts/compat/windows-config.h@1.0 +0 -0 - ntpd/ntpdsim-opts.texi@1.69, 2007-09-10 20:40:00-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/libopts/configfile.c@1.1 +1288 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/configfile.c - ntpd/ntpdsim.1@1.69, 2007-09-10 20:40:00-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/configfile.c@1.0 +0 -0 - ntpdc/ntpdc-opts.c@1.71, 2007-09-10 20:40:01-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/cook.c@1.1 +354 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/cook.c - ntpdc/ntpdc-opts.h@1.71, 2007-09-10 20:40:02-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + sntp/libopts/cook.c@1.0 +0 -0 - ntpdc/ntpdc-opts.texi@1.69, 2007-09-10 20:40:03-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/libopts/enumeration.c@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/enumeration.c - ntpdc/ntpdc.1@1.69, 2007-09-10 20:40:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/enumeration.c@1.0 +0 -0 - ntpq/ntpq-opts.c@1.73, 2007-09-10 20:40:04-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/environment.c@1.1 +260 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/environment.c - ntpq/ntpq-opts.h@1.73, 2007-09-10 20:40:05-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + sntp/libopts/environment.c@1.0 +0 -0 - ntpq/ntpq-opts.texi@1.70, 2007-09-10 20:40:06-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/libopts/genshell.c@1.1 +345 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.c - ntpq/ntpq.1@1.69, 2007-09-10 20:40:06-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/genshell.c@1.0 +0 -0 - packageinfo.sh@1.96, 2007-09-10 20:40:07-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/genshell.h@1.1 +149 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/genshell.h - sntp/sntp-opts.c@1.69, 2007-09-10 20:40:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/genshell.h@1.0 +0 -0 - sntp/sntp-opts.h@1.69, 2007-09-10 20:40:08-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + sntp/libopts/libopts.c@1.1 +30 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/libopts.c - sntp/sntp-opts.texi@1.66, 2007-09-10 20:40:09-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/libopts/libopts.c@1.0 +0 -0 - sntp/sntp.1@1.69, 2007-09-10 20:40:10-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/load.c@1.1 +563 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/load.c - util/ntp-keygen-opts.c@1.70, 2007-09-10 20:40:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/load.c@1.0 +0 -0 - util/ntp-keygen-opts.h@1.70, 2007-09-10 20:40:12-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4 + sntp/libopts/m4/libopts.m4@1.1 +489 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/libopts.m4 - util/ntp-keygen-opts.texi@1.68, 2007-09-10 20:40:13-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4 + sntp/libopts/m4/libopts.m4@1.0 +0 -0 - util/ntp-keygen.1@1.68, 2007-09-10 20:40:14-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4 + sntp/libopts/m4/liboptschk.m4@1.1 +42 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/liboptschk.m4 -ChangeSet@1.1519, 2007-09-10 16:56:09-04:00, stenn@whimsy.udel.edu +3 -0 - Release 4.2.4p4 + sntp/libopts/m4/liboptschk.m4@1.0 +0 -0 - ChangeLog@1.35, 2007-09-10 16:55:51-04:00, stenn@whimsy.udel.edu +3 -0 - Release 4.2.4p4 + sntp/libopts/makeshell.c@1.1 +1122 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/makeshell.c - NEWS@1.98, 2007-09-10 16:55:54-04:00, stenn@whimsy.udel.edu +11 -0 - Release 4.2.4p4 + sntp/libopts/makeshell.c@1.0 +0 -0 - packageinfo.sh@1.95, 2007-09-10 16:55:58-04:00, stenn@whimsy.udel.edu +1 -1 - Release 4.2.4p4 + sntp/libopts/nested.c@1.1 +733 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/nested.c -ChangeSet@1.1518, 2007-09-10 01:57:20-04:00, stenn@whimsy.udel.edu +3 -0 - [Bug 902] Fix problems with the -6 flag + sntp/libopts/nested.c@1.0 +0 -0 - ChangeLog@1.34, 2007-09-10 01:57:02-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 902] Fix problems with the -6 flag + sntp/libopts/numeric.c@1.1 +93 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/numeric.c - libopts/save.c@1.2, 2007-09-10 01:57:02-04:00, stenn@whimsy.udel.edu +11 -2 - [Bug 902] Fix problems with the -6 flag + sntp/libopts/numeric.c@1.0 +0 -0 - sntp/libopts/save.c@1.2, 2007-09-10 01:57:03-04:00, stenn@whimsy.udel.edu +11 -2 - [Bug 902] Fix problems with the -6 flag + sntp/libopts/pgusage.c@1.1 +157 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/pgusage.c -ChangeSet@1.1517, 2007-08-28 15:34:55-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P4_RC2 - TAG: NTP_4_2_4P4_RC2 + sntp/libopts/pgusage.c@1.0 +0 -0 - ntpd/ntpd-opts.c@1.70, 2007-08-28 15:34:28-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/proto.h@1.1 +91 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/proto.h - ntpd/ntpd-opts.h@1.70, 2007-08-28 15:34:29-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/proto.h@1.0 +0 -0 - ntpd/ntpd-opts.texi@1.69, 2007-08-28 15:34:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + sntp/libopts/putshell.c@1.1 +335 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/putshell.c - ntpd/ntpd.1@1.68, 2007-08-28 15:34:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + sntp/libopts/putshell.c@1.0 +0 -0 - ntpd/ntpdsim-opts.c@1.70, 2007-08-28 15:34:32-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/restore.c@1.1 +250 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/restore.c - ntpd/ntpdsim-opts.h@1.70, 2007-08-28 15:34:33-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/restore.c@1.0 +0 -0 - ntpd/ntpdsim-opts.texi@1.68, 2007-08-28 15:34:34-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC2 + sntp/libopts/save.c@1.1 +512 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/save.c - ntpd/ntpdsim.1@1.68, 2007-08-28 15:34:34-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + sntp/libopts/save.c@1.0 +0 -0 - ntpdc/ntpdc-opts.c@1.70, 2007-08-28 15:34:35-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/sort.c@1.1 +359 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/sort.c - ntpdc/ntpdc-opts.h@1.70, 2007-08-28 15:34:36-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/sort.c@1.0 +0 -0 - ntpdc/ntpdc-opts.texi@1.68, 2007-08-28 15:34:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + sntp/libopts/stack.c@1.1 +269 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/stack.c - ntpdc/ntpdc.1@1.68, 2007-08-28 15:34:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + sntp/libopts/stack.c@1.0 +0 -0 - ntpq/ntpq-opts.c@1.72, 2007-08-28 15:34:38-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/streqvcmp.c@1.1 +289 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/streqvcmp.c - ntpq/ntpq-opts.h@1.72, 2007-08-28 15:34:39-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/streqvcmp.c@1.0 +0 -0 - ntpq/ntpq-opts.texi@1.69, 2007-08-28 15:34:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + sntp/libopts/text_mmap.c@1.1 +363 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/text_mmap.c - ntpq/ntpq.1@1.68, 2007-08-28 15:34:41-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + sntp/libopts/text_mmap.c@1.0 +0 -0 - packageinfo.sh@1.94, 2007-08-28 15:34:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC2 + sntp/libopts/tokenize.c@1.1 +321 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/tokenize.c - sntp/sntp-opts.c@1.68, 2007-08-28 15:34:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + sntp/libopts/tokenize.c@1.0 +0 -0 - sntp/sntp-opts.h@1.68, 2007-08-28 15:34:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + sntp/libopts/usage.c@1.1 +731 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/usage.c - sntp/sntp-opts.texi@1.65, 2007-08-28 15:34:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC2 + sntp/libopts/usage.c@1.0 +0 -0 - sntp/sntp.1@1.68, 2007-08-28 15:34:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + sntp/libopts/version.c@1.1 +176 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/version.c - util/ntp-keygen-opts.c@1.69, 2007-08-28 15:34:45-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/libopts/version.c@1.0 +0 -0 - util/ntp-keygen-opts.h@1.69, 2007-08-28 15:34:46-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P4_RC2 + sntp/sntp-opts.c@1.7 +7 -6 + autogen upgrade - util/ntp-keygen-opts.texi@1.67, 2007-08-28 15:34:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC2 + sntp/sntp-opts.h@1.7 +6 -12 + autogen upgrade - util/ntp-keygen.1@1.67, 2007-08-28 15:34:48-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC2 + util/ntp-keygen-opts.c@1.7 +9 -8 + autogen upgrade -ChangeSet@1.1516, 2007-08-27 22:38:57-04:00, stenn@whimsy.udel.edu +2 -0 - Updated include/copyright.def (owner and year) + util/ntp-keygen-opts.h@1.7 +6 -12 + autogen upgrade - ChangeLog@1.33, 2007-08-27 22:38:46-04:00, stenn@whimsy.udel.edu +1 -0 - Updated include/copyright.def (owner and year) +ChangeSet@1.1440.1.73, 2007-03-26 06:42:22-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P20 + TAG: NTP_4_2_5P20 - include/copyright.def@1.5, 2007-08-27 22:38:47-04:00, stenn@whimsy.udel.edu +2 -2 - Updated include/copyright.def (owner and year) + ntpd/ntpd-opts.c@1.6 +2 -2 + NTP_4_2_5P20 -ChangeSet@1.1515, 2007-08-19 05:26:13-04:00, dunlop@pogo.udel.edu +2 -0 - ntpdc_ops.c, ChangeLog: - [BUG 881] Corrected display of pll offset on 64bit systems. - [BUG 886] Corrected sign extension of il->compliance on 64 bit systems - [BUG 878] Avoid ntpdc use of refid value as unterminated string. + ntpd/ntpd-opts.h@1.6 +3 -3 + NTP_4_2_5P20 - ChangeLog@1.32, 2007-08-19 05:20:42-04:00, dunlop@pogo.udel.edu +1 -0 - [Bug 878] Avoid ntpdc use of refid value as unterminated string. + ntpd/ntpd-opts.texi@1.6 +1 -1 + NTP_4_2_5P20 - ChangeLog@1.31, 2007-08-19 05:13:18-04:00, dunlop@pogo.udel.edu +1 -0 - [Bug 881] Corrected display of pll offset on 64bit systems. + ntpd/ntpd.1@1.6 +2 -2 + NTP_4_2_5P20 - ChangeLog@1.30, 2007-08-19 05:01:14-04:00, dunlop@pogo.udel.edu +1 -0 - [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + ntpd/ntpdsim-opts.c@1.6 +2 -2 + NTP_4_2_5P20 - ntpdc/ntpdc_ops.c@1.49, 2007-08-19 05:20:34-04:00, dunlop@pogo.udel.edu +1 -3 - [Bug 878] Avoid ntpdc use of refid value as unterminated string. + ntpd/ntpdsim-opts.h@1.6 +3 -3 + NTP_4_2_5P20 - ntpdc/ntpdc_ops.c@1.48, 2007-08-19 05:12:52-04:00, dunlop@pogo.udel.edu +1 -1 - [Bug 881] Corrected display of pll offset on 64bit systems. + ntpd/ntpdsim-opts.texi@1.6 +1 -1 + NTP_4_2_5P20 - ntpdc/ntpdc_ops.c@1.47, 2007-08-19 04:59:48-04:00, dunlop@pogo.udel.edu +2 -2 - [BUG 886] Corrected sign extension of il->compliance on 64 bit systems + ntpd/ntpdsim.1@1.6 +2 -2 + NTP_4_2_5P20 -ChangeSet@1.1514, 2007-08-18 17:11:19-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P4_RC1 - TAG: NTP_4_2_4P4_RC1 + ntpdc/ntpdc-opts.c@1.6 +2 -2 + NTP_4_2_5P20 - ntpd/ntpd-opts.c@1.69, 2007-08-18 17:10:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpdc/ntpdc-opts.h@1.6 +3 -3 + NTP_4_2_5P20 - ntpd/ntpd-opts.h@1.69, 2007-08-18 17:10:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + ntpdc/ntpdc-opts.texi@1.6 +1 -1 + NTP_4_2_5P20 - ntpd/ntpd-opts.texi@1.68, 2007-08-18 17:10:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpdc/ntpdc.1@1.6 +2 -2 + NTP_4_2_5P20 - ntpd/ntpd.1@1.67, 2007-08-18 17:10:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpq/ntpq-opts.c@1.6 +2 -2 + NTP_4_2_5P20 - ntpd/ntpdsim-opts.c@1.69, 2007-08-18 17:10:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpq/ntpq-opts.h@1.6 +3 -3 + NTP_4_2_5P20 - ntpd/ntpdsim-opts.h@1.69, 2007-08-18 17:10:54-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + ntpq/ntpq-opts.texi@1.6 +1 -1 + NTP_4_2_5P20 - ntpd/ntpdsim-opts.texi@1.67, 2007-08-18 17:10:56-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC1 + ntpq/ntpq.1@1.6 +2 -2 + NTP_4_2_5P20 - ntpd/ntpdsim.1@1.67, 2007-08-18 17:10:56-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + packageinfo.sh@1.23 +1 -1 + NTP_4_2_5P20 - ntpdc/ntpdc-opts.c@1.69, 2007-08-18 17:10:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + sntp/sntp-opts.c@1.6 +2 -2 + NTP_4_2_5P20 - ntpdc/ntpdc-opts.h@1.69, 2007-08-18 17:10:57-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + sntp/sntp-opts.h@1.6 +3 -3 + NTP_4_2_5P20 - ntpdc/ntpdc-opts.texi@1.67, 2007-08-18 17:10:58-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + sntp/sntp-opts.texi@1.6 +1 -1 + NTP_4_2_5P20 - ntpdc/ntpdc.1@1.67, 2007-08-18 17:10:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + sntp/sntp.1@1.6 +2 -2 + NTP_4_2_5P20 - ntpq/ntpq-opts.c@1.71, 2007-08-18 17:10:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + util/ntp-keygen-opts.c@1.6 +2 -2 + NTP_4_2_5P20 - ntpq/ntpq-opts.h@1.71, 2007-08-18 17:11:01-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 + util/ntp-keygen-opts.h@1.6 +3 -3 + NTP_4_2_5P20 - ntpq/ntpq-opts.texi@1.68, 2007-08-18 17:11:02-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + util/ntp-keygen-opts.texi@1.6 +1 -1 + NTP_4_2_5P20 - ntpq/ntpq.1@1.67, 2007-08-18 17:11:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + util/ntp-keygen.1@1.6 +2 -2 + NTP_4_2_5P20 - packageinfo.sh@1.93, 2007-08-18 17:11:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 +ChangeSet@1.1440.4.6, 2007-03-25 21:27:11+00:00, kardel@pogo.udel.edu + ChangeLog: + document fix for [Bug 789] - sntp/sntp-opts.c@1.67, 2007-08-18 17:11:04-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ChangeLog@1.22.1.1 +2 -1 + document fix for [Bug 789] - sntp/sntp-opts.h@1.67, 2007-08-18 17:11:05-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 +ChangeSet@1.1440.1.71, 2007-03-25 16:56:03-04:00, stenn@pogo.udel.edu + [Bug 787] Bug fixes for 64-bit time_t on Windows - sntp/sntp-opts.texi@1.64, 2007-08-18 17:11:07-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P4_RC1 + ChangeLog@1.23 +1 -0 + [Bug 787] Bug fixes for 64-bit time_t on Windows - sntp/sntp.1@1.67, 2007-08-18 17:11:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 +ChangeSet@1.1440.4.5, 2007-03-25 20:07:31+00:00, kardel@pogo.udel.edu + ntp_peer.c: + [Bug 789] avoid broadcast/multicast client associations + getting confused when multicast packets arrive + during the autokey/delay dance - util/ntp-keygen-opts.c@1.68, 2007-08-18 17:11:08-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntp_peer.c@1.101 +15 -3 + [Bug 789] avoid peers getting confused when multicast packets arrive + during the autokey/delay dance - util/ntp-keygen-opts.h@1.68, 2007-08-18 17:11:10-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P4_RC1 +ChangeSet@1.1440.4.4, 2007-03-20 06:42:12-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P19 + TAG: NTP_4_2_5P19 - util/ntp-keygen-opts.texi@1.66, 2007-08-18 17:11:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpd-opts.c@1.5 +2 -2 + NTP_4_2_5P19 - util/ntp-keygen.1@1.66, 2007-08-18 17:11:11-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P4_RC1 + ntpd/ntpd-opts.h@1.5 +3 -3 + NTP_4_2_5P19 -ChangeSet@1.1513, 2007-08-18 16:16:22-04:00, stenn@whimsy.udel.edu +1 -0 - 4.2.4p4-RC + ntpd/ntpd-opts.texi@1.5 +1 -1 + NTP_4_2_5P19 - packageinfo.sh@1.92, 2007-08-18 16:16:06-04:00, stenn@whimsy.udel.edu +1 -1 - 4.2.4p4-RC + ntpd/ntpd.1@1.5 +2 -2 + NTP_4_2_5P19 -ChangeSet@1.1512, 2007-08-18 12:59:45+00:00, kardel@pogo.udel.edu +2 -0 - ntp_restrict.c: - Bug 885: clarify to allow tools to pick up - invariants easier. - Use NULL instead of 0 with pointers. - ChangeLog: - document ntp_restrict.c change + ntpd/ntpdsim-opts.c@1.5 +2 -2 + NTP_4_2_5P19 - ChangeLog@1.29, 2007-08-18 12:59:05+00:00, kardel@pogo.udel.edu +1 -0 - document ntp_restrict.c change + ntpd/ntpdsim-opts.h@1.5 +3 -3 + NTP_4_2_5P19 - ntpd/ntp_restrict.c@1.23, 2007-08-18 12:56:40+00:00, kardel@pogo.udel.edu +21 -21 - Bug 885: clarify to allow tools to pick up - invariants easier. - Use NULL instead of 0 with pointers. + ntpd/ntpdsim-opts.texi@1.5 +1 -1 + NTP_4_2_5P19 -ChangeSet@1.1511, 2007-08-18 12:53:35+00:00, kardel@pogo.udel.edu +2 -0 - recvbuff.c: - Bug 889: avoid malloc() interrupted by SIGIO risk - ChangeLog: - document Bug 889 + ntpd/ntpdsim.1@1.5 +2 -2 + NTP_4_2_5P19 - ChangeLog@1.28, 2007-08-18 12:52:19+00:00, kardel@pogo.udel.edu +1 -0 - document Bug 889 + ntpdc/ntpdc-opts.c@1.5 +2 -2 + NTP_4_2_5P19 - libntp/recvbuff.c@1.26, 2007-08-18 12:49:27+00:00, kardel@pogo.udel.edu +28 -21 - Bug 889: avoid malloc() interrupted by SIGIO risk + ntpdc/ntpdc-opts.h@1.5 +3 -3 + NTP_4_2_5P19 -ChangeSet@1.1510, 2007-08-18 09:51:41+00:00, kardel@pogo.udel.edu +1 -0 - cmd_args.c: - Bug 885: fix comparison + ntpdc/ntpdc-opts.texi@1.5 +1 -1 + NTP_4_2_5P19 - ntpd/cmd_args.c@1.47, 2007-08-18 09:50:28+00:00, kardel@pogo.udel.edu +1 -1 - Bug 885: fix comparison + ntpdc/ntpdc.1@1.5 +2 -2 + NTP_4_2_5P19 -ChangeSet@1.1502.1.1, 2007-08-17 05:28:07-04:00, stenn@pogo.udel.edu +1 -0 - Use autoconf-2.59 and automake-1.9 for building 4.2.4 + ntpq/ntpq-opts.c@1.5 +2 -2 + NTP_4_2_5P19 - bootstrap@1.19, 2007-08-17 05:27:51-04:00, stenn@pogo.udel.edu +18 -2 - Use autoconf-2.59 and automake-1.9 for building 4.2.4 + ntpq/ntpq-opts.h@1.5 +3 -3 + NTP_4_2_5P19 -ChangeSet@1.1508, 2007-08-11 17:32:22+00:00, kardel@pogo.udel.edu +1 -0 - ChangeLog: - document refclock_parse.c fix + ntpq/ntpq-opts.texi@1.5 +1 -1 + NTP_4_2_5P19 - ChangeLog@1.27, 2007-08-11 17:31:30+00:00, kardel@pogo.udel.edu +1 -0 - document refclock_parse.c fix + ntpq/ntpq.1@1.5 +2 -2 + NTP_4_2_5P19 -ChangeSet@1.1507, 2007-08-11 17:30:42+00:00, kardel@pogo.udel.edu +4 -0 - ChangeLog: - document Bug 885 - ntp_io.c: - Bug 885: use emalloc() to get a message at the end of the memory - cmd_args.c: - Bug 885: unsigned types cannot be less than 0 - default_ai_family is a short - ntp_config.c: - Bug 885: lose trailing , from enum list + packageinfo.sh@1.22 +1 -1 + NTP_4_2_5P19 - ChangeLog@1.26, 2007-08-11 17:30:24+00:00, kardel@pogo.udel.edu +4 -0 - document Bug 885 + sntp/sntp-opts.c@1.5 +2 -2 + NTP_4_2_5P19 - ntpd/cmd_args.c@1.46, 2007-08-11 17:19:51+00:00, kardel@pogo.udel.edu +2 -2 - Bug 885: unsigned types cannot be less than 0 - default_ai_family is a short + sntp/sntp-opts.h@1.5 +3 -3 + NTP_4_2_5P19 - ntpd/ntp_config.c@1.142, 2007-08-11 17:20:52+00:00, kardel@pogo.udel.edu +1 -1 - Bug 885: lose trailing , from enum list + sntp/sntp-opts.texi@1.5 +1 -1 + NTP_4_2_5P19 - ntpd/ntp_io.c@1.253, 2007-08-11 17:21:17+00:00, kardel@pogo.udel.edu +1 -1 - Bug 885: use emalloc() to get a message at the end of the memory + sntp/sntp.1@1.5 +2 -2 + NTP_4_2_5P19 -ChangeSet@1.1506, 2007-08-11 17:19:45+00:00, kardel@pogo.udel.edu +1 -0 - refclock_parse.c: - remove io binding before io_closeclock() closes the file descriptor + util/ntp-keygen-opts.c@1.5 +2 -2 + NTP_4_2_5P19 - ntpd/refclock_parse.c@1.48, 2007-08-11 17:17:16+00:00, kardel@pogo.udel.edu +25 -10 - remove io binding before io_closeclock() closes the file descriptor + util/ntp-keygen-opts.h@1.5 +3 -3 + NTP_4_2_5P19 -ChangeSet@1.1505, 2007-08-09 20:30:55+00:00, kardel@pogo.udel.edu +1 -0 - ChangeLog: - [Bug 882] allow loopback interfaces to share addresses with other interfaces. - [Bug 884] don't access recv buffers after having them passed to the free list. + util/ntp-keygen-opts.texi@1.5 +1 -1 + NTP_4_2_5P19 - ChangeLog@1.25, 2007-08-09 20:30:26+00:00, kardel@pogo.udel.edu +3 -0 - [Bug 882] allow loopback interfaces to share addresses with other interfaces. - [Bug 884] don't access recv buffers after having them passed to the free list. + util/ntp-keygen.1@1.5 +2 -2 + NTP_4_2_5P19 -ChangeSet@1.1504, 2007-08-09 19:05:17+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - Bug 884: no access to recv buffers after they are returned to free pool +ChangeSet@1.1440.4.3, 2007-03-20 02:19:52-05:00, stenn@whimsy.udel.edu + Clean up some \\n's on error messages - ntpd/ntp_io.c@1.252, 2007-08-09 19:01:30+00:00, kardel@pogo.udel.edu +9 -7 - Bug 884: no access to recv buffers after they are returned to free pool + ntpd/ntpd.c@1.83.1.2 +2 -2 + Clean up some \\n's on error messages -ChangeSet@1.1503, 2007-08-07 18:14:16+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - Bug 882: loopback interfaces may share IP addresses with other interfaces - thus allow addresses also found on loopback interfaces to be used - as local address. +ChangeSet@1.1440.4.2, 2007-03-20 01:00:23-05:00, stenn@whimsy.udel.edu + [Bug 796] Clean up duplicate #defines in ntp_control.c - ntpd/ntp_io.c@1.251, 2007-08-07 18:09:50+00:00, kardel@pogo.udel.edu +1 -1 - Bug 882: loopback interfaces may share IP addresses with other interfaces - thus allow addresses also found on loopback interfaces to be used - as local address. + ChangeLog@1.22 +1 -0 + [Bug 796] Clean up duplicate #defines in ntp_control.c -ChangeSet@1.1502, 2007-06-29 15:46:00-04:00, stenn@deacon.udel.edu +25 -0 - NTP_4_2_4P3 - TAG: NTP_4_2_4P3 + ntpd/ntp_control.c@1.89.1.1 +4 -9 + [Bug 796] Clean up duplicate #defines in ntp_control.c - ntpd/ntpd-opts.c@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 +ChangeSet@1.1440.4.1, 2007-03-18 06:47:40-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P18 + TAG: NTP_4_2_5P18 - ntpd/ntpd-opts.h@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + ntpd/ntpd-opts.c@1.4 +2 -2 + NTP_4_2_5P18 - ntpd/ntpd-opts.texi@1.67, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpd/ntpd-opts.h@1.4 +3 -3 + NTP_4_2_5P18 - ntpd/ntpd.1@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpd/ntpd-opts.texi@1.4 +1 -1 + NTP_4_2_5P18 - ntpd/ntpdsim-opts.c@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpd/ntpd.1@1.4 +2 -2 + NTP_4_2_5P18 - ntpd/ntpdsim-opts.h@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + ntpd/ntpdsim-opts.c@1.4 +2 -2 + NTP_4_2_5P18 - ntpd/ntpdsim-opts.texi@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +1 -1 - NTP_4_2_4P3 + ntpd/ntpdsim-opts.h@1.4 +3 -3 + NTP_4_2_5P18 - ntpd/ntpdsim.1@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpd/ntpdsim-opts.texi@1.4 +1 -1 + NTP_4_2_5P18 - ntpdc/ntpdc-opts.c@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpd/ntpdsim.1@1.4 +2 -2 + NTP_4_2_5P18 - ntpdc/ntpdc-opts.h@1.68, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + ntpdc/ntpdc-opts.c@1.4 +2 -2 + NTP_4_2_5P18 - ntpdc/ntpdc-opts.texi@1.66, 2007-06-29 15:45:58-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpdc/ntpdc-opts.h@1.4 +3 -3 + NTP_4_2_5P18 - ntpdc/ntpdc.1@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpdc/ntpdc-opts.texi@1.4 +1 -1 + NTP_4_2_5P18 - ntpq/ntpq-opts.c@1.70, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpdc/ntpdc.1@1.4 +2 -2 + NTP_4_2_5P18 - ntpq/ntpq-opts.h@1.70, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + ntpq/ntpq-opts.c@1.4 +2 -2 + NTP_4_2_5P18 - ntpq/ntpq-opts.texi@1.67, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpq/ntpq-opts.h@1.4 +3 -3 + NTP_4_2_5P18 - ntpq/ntpq.1@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpq/ntpq-opts.texi@1.4 +1 -1 + NTP_4_2_5P18 - packageinfo.sh@1.91, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + ntpq/ntpq.1@1.4 +2 -2 + NTP_4_2_5P18 - sntp/sntp-opts.c@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + packageinfo.sh@1.21 +1 -1 + NTP_4_2_5P18 - sntp/sntp-opts.h@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + sntp/sntp-opts.c@1.4 +2 -2 + NTP_4_2_5P18 - sntp/sntp-opts.texi@1.63, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +1 -1 - NTP_4_2_4P3 + sntp/sntp-opts.h@1.4 +3 -3 + NTP_4_2_5P18 - sntp/sntp.1@1.66, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + sntp/sntp-opts.texi@1.4 +1 -1 + NTP_4_2_5P18 - util/ntp-keygen-opts.c@1.67, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + sntp/sntp.1@1.4 +2 -2 + NTP_4_2_5P18 - util/ntp-keygen-opts.h@1.67, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +3 -3 - NTP_4_2_4P3 + util/ntp-keygen-opts.c@1.4 +2 -2 + NTP_4_2_5P18 - util/ntp-keygen-opts.texi@1.65, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + util/ntp-keygen-opts.h@1.4 +3 -3 + NTP_4_2_5P18 - util/ntp-keygen.1@1.65, 2007-06-29 15:45:59-04:00, stenn@deacon.udel.edu +2 -2 - NTP_4_2_4P3 + util/ntp-keygen-opts.texi@1.4 +1 -1 + NTP_4_2_5P18 -ChangeSet@1.1501, 2007-06-29 15:31:21-04:00, stenn@deacon.udel.edu +3 -0 - Release 4.2.4p3 + util/ntp-keygen.1@1.4 +2 -2 + NTP_4_2_5P18 - ChangeLog@1.24, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 - Release 4.2.4p3 +ChangeSet@1.1410.1.1, 2007-03-18 02:35:16-04:00, mayer@pogo.udel.edu + Bug #787 Bug fixes for 64-bit time_t on Windows - NEWS@1.97, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 - Release 4.2.4p3 + ports/winnt/include/config.h@1.47 +25 -7 + Bug #787 Bug fixes for 64-bit time_t on Windows - packageinfo.sh@1.90, 2007-06-29 15:30:58-04:00, stenn@deacon.udel.edu +1 -1 - Release 4.2.4p3 + ports/winnt/include/ntp_timer.h@1.3.1.1 +2 -2 + Bug #787 Bug fixes for 64-bit time_t on Windows -ChangeSet@1.1500, 2007-06-29 19:03:39+00:00, stenn@ntp1.isc.org +2 -0 - Cosmetic reformatting + ports/winnt/libntp/SetSystemTime.c@1.4 +2 -2 + Bug #787 Bug fixes for 64-bit time_t on Windows - ChangeLog@1.23, 2007-06-29 19:03:32+00:00, stenn@ntp1.isc.org +70 -16 - Cosmetic reformatting +ChangeSet@1.1440.1.67, 2007-03-17 19:35:08-05:00, stenn@whimsy.udel.edu + [Bug 569] Use the correct precision for the Leitch CSD-5300 - NEWS@1.96, 2007-06-29 19:03:32+00:00, stenn@ntp1.isc.org +4 -0 - Cosmetic reformatting + ChangeLog@1.21 +1 -0 + [Bug 569] Use the correct precision for the Leitch CSD-5300 -ChangeSet@1.1499, 2007-06-27 07:46:44-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P3_RC1 - TAG: NTP_4_2_4P3_RC1 + ntpd/refclock_leitch.c@1.10 +2 -1 + [Bug 569] Use the correct precision for the Leitch CSD-5300 - ntpd/ntpd-opts.c@1.67, 2007-06-27 07:46:22-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 +ChangeSet@1.1440.1.66, 2007-03-17 15:19:52-05:00, stenn@whimsy.udel.edu + [Bug 798] ntpq [p typo crashes ntpdc - ntpd/ntpd-opts.h@1.67, 2007-06-27 07:46:23-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + ChangeLog@1.20 +1 -1 + [Bug 798] ntpq [p typo crashes ntpdc - ntpd/ntpd-opts.texi@1.66, 2007-06-27 07:46:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpdc/ntpdc.c@1.56 +8 -4 + [Bug 798] ntpq [p typo crashes ntpdc - ntpd/ntpd.1@1.65, 2007-06-27 07:46:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 +ChangeSet@1.1440.1.65, 2007-03-17 06:43:30-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P17 + TAG: NTP_4_2_5P17 - ntpd/ntpdsim-opts.c@1.67, 2007-06-27 07:46:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpd/ntpd-opts.c@1.3 +2 -2 + NTP_4_2_5P17 - ntpd/ntpdsim-opts.h@1.67, 2007-06-27 07:46:26-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + ntpd/ntpd-opts.h@1.3 +3 -3 + NTP_4_2_5P17 - ntpd/ntpdsim-opts.texi@1.65, 2007-06-27 07:46:27-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P3_RC1 + ntpd/ntpd-opts.texi@1.3 +1 -1 + NTP_4_2_5P17 - ntpd/ntpdsim.1@1.65, 2007-06-27 07:46:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpd/ntpd.1@1.3 +2 -2 + NTP_4_2_5P17 - ntpdc/ntpdc-opts.c@1.67, 2007-06-27 07:46:29-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpd/ntpdsim-opts.c@1.3 +2 -2 + NTP_4_2_5P17 - ntpdc/ntpdc-opts.h@1.67, 2007-06-27 07:46:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + ntpd/ntpdsim-opts.h@1.3 +3 -3 + NTP_4_2_5P17 - ntpdc/ntpdc-opts.texi@1.65, 2007-06-27 07:46:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpd/ntpdsim-opts.texi@1.3 +1 -1 + NTP_4_2_5P17 - ntpdc/ntpdc.1@1.65, 2007-06-27 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpd/ntpdsim.1@1.3 +2 -2 + NTP_4_2_5P17 - ntpq/ntpq-opts.c@1.69, 2007-06-27 07:46:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpdc/ntpdc-opts.c@1.3 +2 -2 + NTP_4_2_5P17 - ntpq/ntpq-opts.h@1.69, 2007-06-27 07:46:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + ntpdc/ntpdc-opts.h@1.3 +3 -3 + NTP_4_2_5P17 - ntpq/ntpq-opts.texi@1.66, 2007-06-27 07:46:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpdc/ntpdc-opts.texi@1.3 +1 -1 + NTP_4_2_5P17 - ntpq/ntpq.1@1.65, 2007-06-27 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpdc/ntpdc.1@1.3 +2 -2 + NTP_4_2_5P17 - packageinfo.sh@1.89, 2007-06-27 07:46:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpq/ntpq-opts.c@1.3 +2 -2 + NTP_4_2_5P17 - sntp/sntp-opts.c@1.65, 2007-06-27 07:46:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + ntpq/ntpq-opts.h@1.3 +3 -3 + NTP_4_2_5P17 - sntp/sntp-opts.h@1.65, 2007-06-27 07:46:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + ntpq/ntpq-opts.texi@1.3 +1 -1 + NTP_4_2_5P17 - sntp/sntp-opts.texi@1.62, 2007-06-27 07:46:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P3_RC1 + ntpq/ntpq.1@1.3 +2 -2 + NTP_4_2_5P17 - sntp/sntp.1@1.65, 2007-06-27 07:46:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + packageinfo.sh@1.20 +1 -1 + NTP_4_2_5P17 - util/ntp-keygen-opts.c@1.66, 2007-06-27 07:46:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp-opts.c@1.3 +2 -2 + NTP_4_2_5P17 - util/ntp-keygen-opts.h@1.66, 2007-06-27 07:46:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P3_RC1 + sntp/sntp-opts.h@1.3 +3 -3 + NTP_4_2_5P17 - util/ntp-keygen-opts.texi@1.64, 2007-06-27 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp-opts.texi@1.3 +1 -1 + NTP_4_2_5P17 - util/ntp-keygen.1@1.64, 2007-06-27 07:46:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P3_RC1 + sntp/sntp.1@1.3 +2 -2 + NTP_4_2_5P17 -ChangeSet@1.1498, 2007-06-27 01:42:30-04:00, stenn@whimsy.udel.edu +3 -0 - First RC for 4.2.4p3 + util/ntp-keygen-opts.c@1.3 +2 -2 + NTP_4_2_5P17 - ChangeLog@1.22, 2007-06-27 01:41:43-04:00, stenn@whimsy.udel.edu +2 -1 - First RC for 4.2.4p3 + util/ntp-keygen-opts.h@1.3 +3 -3 + NTP_4_2_5P17 - NEWS@1.95, 2007-06-27 01:41:46-04:00, stenn@whimsy.udel.edu +8 -0 - First RC for 4.2.4p3 + util/ntp-keygen-opts.texi@1.3 +1 -1 + NTP_4_2_5P17 - packageinfo.sh@1.88, 2007-06-27 01:41:59-04:00, stenn@whimsy.udel.edu +1 -1 - First RC for 4.2.4p3 + util/ntp-keygen.1@1.3 +2 -2 + NTP_4_2_5P17 -ChangeSet@1.1497, 2007-06-23 08:47:07-04:00, mayer@pogo.udel.edu +1 -0 - Added Bug #863 +ChangeSet@1.1440.1.64, 2007-03-17 06:54:45-04:00, stenn@pogo.udel.edu + [Bug 795] Moved declaration of variable to top of function - ChangeLog@1.21, 2007-06-23 08:46:51-04:00, mayer@pogo.udel.edu +2 -0 - Added Bug #863 + ChangeLog@1.19 +1 -0 + [Bug 795] Moved declaration of variable to top of function -ChangeSet@1.1492.1.1, 2007-06-23 08:42:58-04:00, mayer@pogo.udel.edu +3 -0 - Bug #863 Unable to stop ntpd because the handle index changed +ChangeSet@1.1440.3.1, 2007-03-17 04:53:50-05:00, stenn@whimsy.udel.edu + [Bug 798] ntpq [p typo crashes ntpq - ports/winnt/include/ntp_iocompletionport.h@1.13, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +3 -0 - Bug #863 Unable to stop ntpd because the handle index changed + ChangeLog@1.18 +1 -0 + [Bug 798] ntpq [p typo crashes ntpq - ports/winnt/ntpd/ntp_iocompletionport.c@1.23, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +15 -1 - Bug #863 Unable to stop ntpd because the handle index changed + ntpq/ntpq.c@1.66.1.1 +8 -4 + [Bug 798] ntpq [p typo crashes ntpq - ports/winnt/ntpd/ntservice.c@1.9, 2007-06-23 08:42:41-04:00, mayer@pogo.udel.edu +9 -5 - Bug #863 Unable to stop ntpd because the handle index changed +ChangeSet@1.1440.1.62, 2007-03-12 09:06:55+00:00, burnicki@pogo.udel.edu + [Bug 795] Moved declaration of variable to top of function to avoid build error. -ChangeSet@1.1495, 2007-06-20 07:45:57-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2 - TAG: NTP_4_2_4P2 + ntpd/ntp_io.c@1.245.1.4 +4 -1 + Moved declaration of variable to top of function to avoid build error. - ntpd/ntpd-opts.c@1.66, 2007-06-20 07:45:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 +ChangeSet@1.1436.1.36, 2007-03-07 06:46:09-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P0 + TAG: NTP_4_2_4P0 - ntpd/ntpd-opts.h@1.66, 2007-06-20 07:45:33-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpd/ntpd-opts.c@1.50.1.6 +2 -2 + NTP_4_2_4P0 - ntpd/ntpd-opts.texi@1.65, 2007-06-20 07:45:34-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2 + ntpd/ntpd-opts.h@1.50.1.6 +3 -3 + NTP_4_2_4P0 - ntpd/ntpd.1@1.64, 2007-06-20 07:45:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpd/ntpd-opts.texi@1.49.1.6 +1 -1 + NTP_4_2_4P0 - ntpd/ntpdsim-opts.c@1.66, 2007-06-20 07:45:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpd/ntpd.1@1.48.1.6 +2 -2 + NTP_4_2_4P0 - ntpd/ntpdsim-opts.h@1.66, 2007-06-20 07:45:36-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpd/ntpdsim-opts.c@1.50.1.6 +2 -2 + NTP_4_2_4P0 - ntpd/ntpdsim-opts.texi@1.64, 2007-06-20 07:45:37-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2 + ntpd/ntpdsim-opts.h@1.50.1.6 +3 -3 + NTP_4_2_4P0 - ntpd/ntpdsim.1@1.64, 2007-06-20 07:45:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpd/ntpdsim-opts.texi@1.48.1.6 +1 -1 + NTP_4_2_4P0 - ntpdc/ntpdc-opts.c@1.66, 2007-06-20 07:45:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpd/ntpdsim.1@1.48.1.6 +2 -2 + NTP_4_2_4P0 - ntpdc/ntpdc-opts.h@1.66, 2007-06-20 07:45:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpdc/ntpdc-opts.c@1.50.1.6 +2 -2 + NTP_4_2_4P0 - ntpdc/ntpdc-opts.texi@1.64, 2007-06-20 07:45:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpdc/ntpdc-opts.h@1.50.1.6 +3 -3 + NTP_4_2_4P0 - ntpdc/ntpdc.1@1.64, 2007-06-20 07:45:41-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpdc/ntpdc-opts.texi@1.48.1.6 +1 -1 + NTP_4_2_4P0 - ntpq/ntpq-opts.c@1.68, 2007-06-20 07:45:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpdc/ntpdc.1@1.48.1.6 +2 -2 + NTP_4_2_4P0 - ntpq/ntpq-opts.h@1.68, 2007-06-20 07:45:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + ntpq/ntpq-opts.c@1.52.1.6 +2 -2 + NTP_4_2_4P0 - ntpq/ntpq-opts.texi@1.65, 2007-06-20 07:45:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpq/ntpq-opts.h@1.52.1.6 +3 -3 + NTP_4_2_4P0 - ntpq/ntpq.1@1.64, 2007-06-20 07:45:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpq/ntpq-opts.texi@1.49.1.6 +1 -1 + NTP_4_2_4P0 - packageinfo.sh@1.87, 2007-06-20 07:45:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + ntpq/ntpq.1@1.48.1.6 +2 -2 + NTP_4_2_4P0 - sntp/sntp-opts.c@1.64, 2007-06-20 07:45:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + packageinfo.sh@1.65.7.2 +2 -2 + NTP_4_2_4P0 - sntp/sntp-opts.h@1.64, 2007-06-20 07:45:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + sntp/sntp-opts.c@1.49.1.6 +2 -2 + NTP_4_2_4P0 - sntp/sntp-opts.texi@1.61, 2007-06-20 07:45:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2 + sntp/sntp-opts.h@1.49.1.6 +3 -3 + NTP_4_2_4P0 - sntp/sntp.1@1.64, 2007-06-20 07:45:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + sntp/sntp-opts.texi@1.46.1.6 +1 -1 + NTP_4_2_4P0 - util/ntp-keygen-opts.c@1.65, 2007-06-20 07:45:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + sntp/sntp.1@1.49.1.6 +2 -2 + NTP_4_2_4P0 - util/ntp-keygen-opts.h@1.65, 2007-06-20 07:45:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2 + util/ntp-keygen-opts.c@1.49.1.6 +2 -2 + NTP_4_2_4P0 - util/ntp-keygen-opts.texi@1.63, 2007-06-20 07:45:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + util/ntp-keygen-opts.h@1.49.1.6 +3 -3 + NTP_4_2_4P0 - util/ntp-keygen.1@1.63, 2007-06-20 07:45:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2 + util/ntp-keygen-opts.texi@1.47.1.6 +1 -1 + NTP_4_2_4P0 -ChangeSet@1.1494, 2007-06-20 04:07:34-04:00, stenn@deacon.udel.edu +3 -0 - 4.2.4p2 + util/ntp-keygen.1@1.47.1.6 +2 -2 + NTP_4_2_4P0 - ChangeLog@1.20, 2007-06-20 04:07:25-04:00, stenn@deacon.udel.edu +1 -0 - 4.2.4p2 +ChangeSet@1.1436.1.35, 2007-03-07 00:53:31-05:00, stenn@whimsy.udel.edu + time to release - NEWS@1.94, 2007-06-20 04:07:25-04:00, stenn@deacon.udel.edu +8 -13 - 4.2.4p2 + packageinfo.sh@1.65.7.1 +3 -1 + time to release - packageinfo.sh@1.86, 2007-06-20 04:07:26-04:00, stenn@deacon.udel.edu +1 -1 - 4.2.4p2 +ChangeSet@1.1440.1.61, 2007-03-04 07:33:47-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P16 + TAG: NTP_4_2_5P16 -ChangeSet@1.1493, 2007-06-10 07:58:59-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC6 - TAG: NTP_4_2_4P2_RC6 + ntpd/ntpd-opts.c@1.2 +2 -2 + NTP_4_2_5P16 - ntpd/ntpd-opts.c@1.65, 2007-06-10 07:58:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpd/ntpd-opts.h@1.2 +3 -3 + NTP_4_2_5P16 - ntpd/ntpd-opts.h@1.65, 2007-06-10 07:58:37-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + ntpd/ntpd-opts.texi@1.2 +1 -1 + NTP_4_2_5P16 - ntpd/ntpd-opts.texi@1.64, 2007-06-10 07:58:38-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + ntpd/ntpd.1@1.2 +2 -2 + NTP_4_2_5P16 - ntpd/ntpd.1@1.63, 2007-06-10 07:58:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpd/ntpdsim-opts.c@1.2 +2 -2 + NTP_4_2_5P16 - ntpd/ntpdsim-opts.c@1.65, 2007-06-10 07:58:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpd/ntpdsim-opts.h@1.2 +3 -3 + NTP_4_2_5P16 - ntpd/ntpdsim-opts.h@1.65, 2007-06-10 07:58:41-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + ntpd/ntpdsim-opts.texi@1.2 +1 -1 + NTP_4_2_5P16 - ntpd/ntpdsim-opts.texi@1.63, 2007-06-10 07:58:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + ntpd/ntpdsim.1@1.2 +2 -2 + NTP_4_2_5P16 - ntpd/ntpdsim.1@1.63, 2007-06-10 07:58:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpdc/ntpdc-opts.c@1.2 +2 -2 + NTP_4_2_5P16 - ntpdc/ntpdc-opts.c@1.65, 2007-06-10 07:58:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpdc/ntpdc-opts.h@1.2 +3 -3 + NTP_4_2_5P16 - ntpdc/ntpdc-opts.h@1.65, 2007-06-10 07:58:43-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + ntpdc/ntpdc-opts.texi@1.2 +1 -1 + NTP_4_2_5P16 - ntpdc/ntpdc-opts.texi@1.63, 2007-06-10 07:58:44-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + ntpdc/ntpdc.1@1.2 +2 -2 + NTP_4_2_5P16 - ntpdc/ntpdc.1@1.63, 2007-06-10 07:58:44-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpq/ntpq-opts.c@1.2 +2 -2 + NTP_4_2_5P16 - ntpq/ntpq-opts.c@1.67, 2007-06-10 07:58:45-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + ntpq/ntpq-opts.h@1.2 +3 -3 + NTP_4_2_5P16 - ntpq/ntpq-opts.h@1.67, 2007-06-10 07:58:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + ntpq/ntpq-opts.texi@1.2 +1 -1 + NTP_4_2_5P16 - ntpq/ntpq-opts.texi@1.64, 2007-06-10 07:58:46-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + ntpq/ntpq.1@1.2 +2 -2 + NTP_4_2_5P16 - ntpq/ntpq.1@1.63, 2007-06-10 07:58:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + packageinfo.sh@1.19 +1 -1 + NTP_4_2_5P16 - packageinfo.sh@1.85, 2007-06-10 07:58:48-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + sntp/sntp-opts.c@1.2 +2 -2 + NTP_4_2_5P16 - sntp/sntp-opts.c@1.63, 2007-06-10 07:58:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + sntp/sntp-opts.h@1.2 +3 -3 + NTP_4_2_5P16 - sntp/sntp-opts.h@1.63, 2007-06-10 07:58:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + sntp/sntp-opts.texi@1.2 +1 -1 + NTP_4_2_5P16 - sntp/sntp-opts.texi@1.60, 2007-06-10 07:58:50-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + sntp/sntp.1@1.2 +2 -2 + NTP_4_2_5P16 - sntp/sntp.1@1.63, 2007-06-10 07:58:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + util/ntp-keygen-opts.c@1.2 +2 -2 + NTP_4_2_5P16 - util/ntp-keygen-opts.c@1.64, 2007-06-10 07:58:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 + util/ntp-keygen-opts.h@1.2 +3 -3 + NTP_4_2_5P16 - util/ntp-keygen-opts.h@1.64, 2007-06-10 07:58:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC6 + util/ntp-keygen-opts.texi@1.2 +1 -1 + NTP_4_2_5P16 - util/ntp-keygen-opts.texi@1.62, 2007-06-10 07:58:53-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC6 + util/ntp-keygen.1@1.2 +2 -2 + NTP_4_2_5P16 - util/ntp-keygen.1@1.62, 2007-06-10 07:58:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC6 +ChangeSet@1.1440.1.60, 2007-03-03 22:41:27-05:00, stenn@whimsy.udel.edu + .point-changed-filelist items are distinct between -stable and -dev. -ChangeSet@1.1492, 2007-06-07 09:28:16-04:00, mayer@pogo.udel.edu +1 -0 - Bug #854 Broadcast address was not correctly set for interface addresses + BitKeeper/deleted/.del-ntp-keygen-opts.c@1.71 +0 -0 + Delete: util/ntp-keygen-opts.c - ChangeLog@1.19, 2007-06-07 09:28:05-04:00, mayer@pogo.udel.edu +1 -0 - Bug #854 Broadcast address was not correctly set for interface addresses + BitKeeper/deleted/.del-ntp-keygen-opts.h@1.71 +0 -0 + Delete: util/ntp-keygen-opts.h -ChangeSet@1.1491, 2007-06-07 09:25:17-04:00, mayer@pogo.udel.edu +1 -0 - Bug #854 Broadcast address was not correctly set for interface addresses + BitKeeper/deleted/.del-ntp-keygen-opts.texi@1.69 +0 -0 + Delete: util/ntp-keygen-opts.texi - ports/winnt/libisc/interfaceiter.c@1.7, 2007-06-07 09:24:57-04:00, mayer@pogo.udel.edu +35 -13 - Bug #854 Broadcast address was not correctly set for interface addresses + BitKeeper/deleted/.del-ntp-keygen.1@1.69 +0 -0 + Delete: util/ntp-keygen.1 -ChangeSet@1.1490, 2007-05-29 07:43:58-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC5 - TAG: NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpd-opts.c@1.72 +0 -0 + Delete: ntpd/ntpd-opts.c - ntpd/ntpd-opts.c@1.64, 2007-05-29 07:43:35-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpd-opts.h@1.72 +0 -0 + Delete: ntpd/ntpd-opts.h - ntpd/ntpd-opts.h@1.64, 2007-05-29 07:43:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpd-opts.texi@1.71 +0 -0 + Delete: ntpd/ntpd-opts.texi - ntpd/ntpd-opts.texi@1.63, 2007-05-29 07:43:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpd.1@1.70 +0 -0 + Delete: ntpd/ntpd.1 - ntpd/ntpd.1@1.62, 2007-05-29 07:43:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdc-opts.c@1.72 +0 -0 + Delete: ntpdc/ntpdc-opts.c - ntpd/ntpdsim-opts.c@1.64, 2007-05-29 07:43:38-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdc-opts.h@1.72 +0 -0 + Delete: ntpdc/ntpdc-opts.h - ntpd/ntpdsim-opts.h@1.64, 2007-05-29 07:43:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdc-opts.texi@1.70 +0 -0 + Delete: ntpdc/ntpdc-opts.texi - ntpd/ntpdsim-opts.texi@1.62, 2007-05-29 07:43:40-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdc.1@1.70 +0 -0 + Delete: ntpdc/ntpdc.1 - ntpd/ntpdsim.1@1.62, 2007-05-29 07:43:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdsim-opts.c@1.72 +0 -0 + Delete: ntpd/ntpdsim-opts.c - ntpdc/ntpdc-opts.c@1.64, 2007-05-29 07:43:41-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdsim-opts.h@1.72 +0 -0 + Delete: ntpd/ntpdsim-opts.h - ntpdc/ntpdc-opts.h@1.64, 2007-05-29 07:43:42-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdsim-opts.texi@1.70 +0 -0 + Delete: ntpd/ntpdsim-opts.texi - ntpdc/ntpdc-opts.texi@1.62, 2007-05-29 07:43:43-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpdsim.1@1.70 +0 -0 + Delete: ntpd/ntpdsim.1 - ntpdc/ntpdc.1@1.62, 2007-05-29 07:43:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpq-opts.c@1.74 +0 -0 + Delete: ntpq/ntpq-opts.c - ntpq/ntpq-opts.c@1.66, 2007-05-29 07:43:44-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpq-opts.h@1.74 +0 -0 + Delete: ntpq/ntpq-opts.h - ntpq/ntpq-opts.h@1.66, 2007-05-29 07:43:45-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpq-opts.texi@1.71 +0 -0 + Delete: ntpq/ntpq-opts.texi - ntpq/ntpq-opts.texi@1.63, 2007-05-29 07:43:45-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-ntpq.1@1.70 +0 -0 + Delete: ntpq/ntpq.1 - ntpq/ntpq.1@1.62, 2007-05-29 07:43:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-sntp-opts.c@1.71 +0 -0 + Delete: sntp/sntp-opts.c - packageinfo.sh@1.84, 2007-05-29 07:43:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-sntp-opts.h@1.71 +0 -0 + Delete: sntp/sntp-opts.h - sntp/sntp-opts.c@1.62, 2007-05-29 07:43:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-sntp-opts.texi@1.68 +0 -0 + Delete: sntp/sntp-opts.texi - sntp/sntp-opts.h@1.62, 2007-05-29 07:43:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + BitKeeper/deleted/.del-sntp.1@1.71 +0 -0 + Delete: sntp/sntp.1 - sntp/sntp-opts.texi@1.59, 2007-05-29 07:43:49-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + ntpd/ntpd-opts.c@1.1 +1055 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd-opts.c - sntp/sntp.1@1.62, 2007-05-29 07:43:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + ntpd/ntpd-opts.c@1.0 +0 -0 - util/ntp-keygen-opts.c@1.63, 2007-05-29 07:43:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + ntpd/ntpd-opts.h@1.1 +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd-opts.h - util/ntp-keygen-opts.h@1.63, 2007-05-29 07:43:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC5 + ntpd/ntpd-opts.h@1.0 +0 -0 - util/ntp-keygen-opts.texi@1.61, 2007-05-29 07:43:53-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC5 + ntpd/ntpd-opts.texi@1.1 +498 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd-opts.texi - util/ntp-keygen.1@1.61, 2007-05-29 07:43:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC5 + ntpd/ntpd-opts.texi@1.0 +0 -0 -ChangeSet@1.1489, 2007-05-29 01:32:29-04:00, stenn@whimsy.udel.edu +2 -0 - typo cleanup + ntpd/ntpd.1@1.1 +312 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpd.1 - ChangeLog@1.18, 2007-05-29 01:32:14-04:00, stenn@whimsy.udel.edu +1 -1 - typo cleanup + ntpd/ntpd.1@1.0 +0 -0 - NEWS@1.93, 2007-05-29 01:32:15-04:00, stenn@whimsy.udel.edu +1 -2 - typo cleanup + ntpd/ntpdsim-opts.c@1.1 +1253 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim-opts.c -ChangeSet@1.1488, 2007-05-28 10:00:27+00:00, kardel@pogo.udel.edu +3 -0 - NEWS, ntp_io.c, ChangeLog: - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + ntpd/ntpdsim-opts.c@1.0 +0 -0 - ChangeLog@1.17, 2007-05-28 09:54:40+00:00, kardel@pogo.udel.edu +2 -0 - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + ntpd/ntpdsim-opts.h@1.1 +429 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim-opts.h - NEWS@1.92, 2007-05-28 09:55:04+00:00, kardel@pogo.udel.edu +3 -0 - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + ntpd/ntpdsim-opts.h@1.0 +0 -0 - ntpd/ntp_io.c@1.250, 2007-05-28 09:59:44+00:00, kardel@pogo.udel.edu +58 -44 - Bug 829: reduce syslog noise, while there fix Enabled/Disable logging - to reflect the actual configuration + ntpd/ntpdsim-opts.texi@1.1 +510 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim-opts.texi -ChangeSet@1.1487, 2007-05-27 07:45:05-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC4 - TAG: NTP_4_2_4P2_RC4 + ntpd/ntpdsim-opts.texi@1.0 +0 -0 - ntpd/ntpd-opts.c@1.63, 2007-05-27 07:44:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpd/ntpdsim.1@1.1 +357 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpd/ntpdsim.1 - ntpd/ntpd-opts.h@1.63, 2007-05-27 07:44:40-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + ntpd/ntpdsim.1@1.0 +0 -0 - ntpd/ntpd-opts.texi@1.62, 2007-05-27 07:44:41-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc-opts.c@1.1 +658 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc-opts.c - ntpd/ntpd.1@1.61, 2007-05-27 07:44:42-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc-opts.c@1.0 +0 -0 - ntpd/ntpdsim-opts.c@1.63, 2007-05-27 07:44:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc-opts.h@1.1 +229 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc-opts.h - ntpd/ntpdsim-opts.h@1.63, 2007-05-27 07:44:44-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc-opts.h@1.0 +0 -0 - ntpd/ntpdsim-opts.texi@1.61, 2007-05-27 07:44:45-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc-opts.texi@1.1 +276 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc-opts.texi - ntpd/ntpdsim.1@1.61, 2007-05-27 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc-opts.texi@1.0 +0 -0 - ntpdc/ntpdc-opts.c@1.63, 2007-05-27 07:44:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc.1@1.1 +158 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpdc/ntpdc.1 - ntpdc/ntpdc-opts.h@1.63, 2007-05-27 07:44:47-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + ntpdc/ntpdc.1@1.0 +0 -0 - ntpdc/ntpdc-opts.texi@1.61, 2007-05-27 07:44:48-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ntpq/ntpq-opts.c@1.1 +598 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq-opts.c - ntpdc/ntpdc.1@1.61, 2007-05-27 07:44:49-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpq/ntpq-opts.c@1.0 +0 -0 - ntpq/ntpq-opts.c@1.65, 2007-05-27 07:44:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpq/ntpq-opts.h@1.1 +215 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq-opts.h - ntpq/ntpq-opts.h@1.65, 2007-05-27 07:44:50-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + ntpq/ntpq-opts.h@1.0 +0 -0 - ntpq/ntpq-opts.texi@1.62, 2007-05-27 07:44:51-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ntpq/ntpq-opts.texi@1.1 +216 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq-opts.texi - ntpq/ntpq.1@1.61, 2007-05-27 07:44:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpq/ntpq-opts.texi@1.0 +0 -0 - packageinfo.sh@1.83, 2007-05-27 07:44:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + ntpq/ntpq.1@1.1 +385 -0 + BitKeeper file /deacon/backroom/ntp-dev/ntpq/ntpq.1 - sntp/sntp-opts.c@1.61, 2007-05-27 07:44:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + ntpq/ntpq.1@1.0 +0 -0 - sntp/sntp-opts.h@1.61, 2007-05-27 07:44:54-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + sntp/sntp-opts.c@1.1 +682 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp-opts.c - sntp/sntp-opts.texi@1.58, 2007-05-27 07:44:55-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + sntp/sntp-opts.c@1.0 +0 -0 - sntp/sntp.1@1.61, 2007-05-27 07:44:55-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + sntp/sntp-opts.h@1.1 +290 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp-opts.h - util/ntp-keygen-opts.c@1.62, 2007-05-27 07:44:56-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + sntp/sntp-opts.h@1.0 +0 -0 - util/ntp-keygen-opts.h@1.62, 2007-05-27 07:44:57-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC4 + sntp/sntp-opts.texi@1.1 +174 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp-opts.texi - util/ntp-keygen-opts.texi@1.60, 2007-05-27 07:44:58-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC4 + sntp/sntp-opts.texi@1.0 +0 -0 - util/ntp-keygen.1@1.60, 2007-05-27 07:44:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC4 + sntp/sntp.1@1.1 +400 -0 + BitKeeper file /deacon/backroom/ntp-dev/sntp/sntp.1 -ChangeSet@1.1486, 2007-05-27 00:52:52-04:00, stenn@whimsy.udel.edu +1 -0 - update NEWS file with new fixes + sntp/sntp.1@1.0 +0 -0 - NEWS@1.91, 2007-05-27 00:52:43-04:00, stenn@whimsy.udel.edu +6 -0 - update NEWS file with new fixes + util/ntp-keygen-opts.c@1.1 +1035 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen-opts.c -ChangeSet@1.1485, 2007-05-27 00:31:51-04:00, stenn@deacon.udel.edu +1 -0 - Cleanup + util/ntp-keygen-opts.c@1.0 +0 -0 - ChangeLog@1.16, 2007-05-27 00:31:40-04:00, stenn@deacon.udel.edu +2 -2 - Cleanup + util/ntp-keygen-opts.h@1.1 +325 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen-opts.h -ChangeSet@1.1484, 2007-05-26 08:00:03+00:00, kardel@pogo.udel.edu +2 -0 - ntp_io.c: - [Bug 795] Moved declaration of variable to top of function. - ChangeLog: - [Bug 795] Moved declaration of variable to top of function. + util/ntp-keygen-opts.h@1.0 +0 -0 - ChangeLog@1.15, 2007-05-26 07:57:22+00:00, kardel@pogo.udel.edu +1 -0 - Bug 795 + util/ntp-keygen-opts.texi@1.1 +366 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen-opts.texi - ntpd/ntp_io.c@1.249, 2007-05-26 07:58:40+00:00, kardel@pogo.udel.edu +4 -1 - [Bug 795] Moved declaration of variable to top of function. + util/ntp-keygen-opts.texi@1.0 +0 -0 -ChangeSet@1.1480.1.9, 2007-05-25 07:44:43-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC3 - TAG: NTP_4_2_4P2_RC3 + util/ntp-keygen.1@1.1 +176 -0 + BitKeeper file /deacon/backroom/ntp-dev/util/ntp-keygen.1 - ntpd/ntpd-opts.c@1.62, 2007-05-25 07:44:20-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + util/ntp-keygen.1@1.0 +0 -0 - ntpd/ntpd-opts.h@1.62, 2007-05-25 07:44:21-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 +ChangeSet@1.1436.1.34, 2007-03-03 19:21:29-05:00, stenn@whimsy.udel.edu + [Bug 793] Update Hans Lambermont's email address in ntpsweep - ntpd/ntpd-opts.texi@1.61, 2007-05-25 07:44:22-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ChangeLog@1.1.1.9 +1 -0 + [Bug 793] Update Hans Lambermont's email address in ntpsweep - ntpd/ntpd.1@1.60, 2007-05-25 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + scripts/ntpsweep.in@1.3 +1 -2 + [Bug 793] Update Hans Lambermont's email address in ntpsweep - ntpd/ntpdsim-opts.c@1.62, 2007-05-25 07:44:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 +ChangeSet@1.1440.1.58, 2007-03-03 06:43:50-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P15 + TAG: NTP_4_2_5P15 - ntpd/ntpdsim-opts.h@1.62, 2007-05-25 07:44:24-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ntpd/ntpd-opts.c@1.70 +2 -2 + NTP_4_2_5P15 - ntpd/ntpdsim-opts.texi@1.60, 2007-05-25 07:44:25-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpd/ntpd-opts.h@1.70 +3 -3 + NTP_4_2_5P15 - ntpd/ntpdsim.1@1.60, 2007-05-25 07:44:25-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpd/ntpd-opts.texi@1.69 +1 -1 + NTP_4_2_5P15 - ntpdc/ntpdc-opts.c@1.62, 2007-05-25 07:44:26-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpd/ntpd.1@1.68 +2 -2 + NTP_4_2_5P15 - ntpdc/ntpdc-opts.h@1.62, 2007-05-25 07:44:27-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ntpd/ntpdsim-opts.c@1.70 +2 -2 + NTP_4_2_5P15 - ntpdc/ntpdc-opts.texi@1.60, 2007-05-25 07:44:28-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpd/ntpdsim-opts.h@1.70 +3 -3 + NTP_4_2_5P15 - ntpdc/ntpdc.1@1.60, 2007-05-25 07:44:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpd/ntpdsim-opts.texi@1.68 +1 -1 + NTP_4_2_5P15 - ntpq/ntpq-opts.c@1.64, 2007-05-25 07:44:29-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpd/ntpdsim.1@1.68 +2 -2 + NTP_4_2_5P15 - ntpq/ntpq-opts.h@1.64, 2007-05-25 07:44:30-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc-opts.c@1.70 +2 -2 + NTP_4_2_5P15 - ntpq/ntpq-opts.texi@1.61, 2007-05-25 07:44:31-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc-opts.h@1.70 +3 -3 + NTP_4_2_5P15 - ntpq/ntpq.1@1.60, 2007-05-25 07:44:32-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc-opts.texi@1.68 +1 -1 + NTP_4_2_5P15 - packageinfo.sh@1.82, 2007-05-25 07:44:33-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpdc/ntpdc.1@1.68 +2 -2 + NTP_4_2_5P15 - sntp/sntp-opts.c@1.60, 2007-05-25 07:44:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpq/ntpq-opts.c@1.72 +2 -2 + NTP_4_2_5P15 - sntp/sntp-opts.h@1.60, 2007-05-25 07:44:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + ntpq/ntpq-opts.h@1.72 +3 -3 + NTP_4_2_5P15 - sntp/sntp-opts.texi@1.57, 2007-05-25 07:44:35-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + ntpq/ntpq-opts.texi@1.69 +1 -1 + NTP_4_2_5P15 - sntp/sntp.1@1.60, 2007-05-25 07:44:36-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + ntpq/ntpq.1@1.68 +2 -2 + NTP_4_2_5P15 - util/ntp-keygen-opts.c@1.61, 2007-05-25 07:44:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + packageinfo.sh@1.18 +1 -1 + NTP_4_2_5P15 - util/ntp-keygen-opts.h@1.61, 2007-05-25 07:44:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC3 + sntp/sntp-opts.c@1.69 +2 -2 + NTP_4_2_5P15 - util/ntp-keygen-opts.texi@1.59, 2007-05-25 07:44:38-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC3 + sntp/sntp-opts.h@1.69 +3 -3 + NTP_4_2_5P15 - util/ntp-keygen.1@1.59, 2007-05-25 07:44:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC3 + sntp/sntp-opts.texi@1.66 +1 -1 + NTP_4_2_5P15 -ChangeSet@1.1480.1.8, 2007-05-25 02:18:59-04:00, stenn@whimsy.udel.edu +1 -0 - cleanup + sntp/sntp.1@1.69 +2 -2 + NTP_4_2_5P15 - NEWS@1.90, 2007-05-25 02:18:48-04:00, stenn@whimsy.udel.edu +1 -0 - cleanup + util/ntp-keygen-opts.c@1.69 +2 -2 + NTP_4_2_5P15 -ChangeSet@1.1480.2.1, 2007-05-25 02:06:52-04:00, stenn@whimsy.udel.edu +2 -0 - Upgraded autogen and libopts + util/ntp-keygen-opts.h@1.69 +3 -3 + NTP_4_2_5P15 - ChangeLog@1.11.2.1, 2007-05-25 02:06:37-04:00, stenn@whimsy.udel.edu +1 -0 - Upgraded autogen and libopts + util/ntp-keygen-opts.texi@1.67 +1 -1 + NTP_4_2_5P15 - NEWS@1.89, 2007-05-25 02:06:38-04:00, stenn@whimsy.udel.edu +1 -0 - Upgraded autogen and libopts + util/ntp-keygen.1@1.67 +2 -2 + NTP_4_2_5P15 -ChangeSet@1.1480.1.6, 2007-05-25 01:07:59-04:00, stenn@pogo.udel.edu +1 -0 - cleanup ChangeLog +ChangeSet@1.1440.1.57, 2007-03-03 01:16:11-05:00, stenn@whimsy.udel.edu + [Bug 786] Fix refclock_bancomm.c on Solaris - ChangeLog@1.11.1.3, 2007-05-25 01:07:52-04:00, stenn@pogo.udel.edu +1 -1 - cleanup ChangeLog + ChangeLog@1.16 +1 -0 + [Bug 786] Fix refclock_bancomm.c on Solaris -ChangeSet@1.1480.1.5, 2007-05-24 08:10:30-04:00, mayer@pogo.udel.edu +1 -0 - Bug #527 Don't write from source address length to wrong location +ChangeSet@1.1440.1.56, 2007-03-01 10:16:30-05:00, neal@pogo.udel.edu + refclock_bancomm.c: + [BUG 786] - add Solaris 10 support - ChangeLog@1.11.1.2, 2007-05-24 08:10:20-04:00, mayer@pogo.udel.edu +1 -0 - Bug #527 Don't write from source address length to wrong location + ntpd/refclock_bancomm.c@1.10 +97 -17 + [BUG 786] - add Solaris 10 support -ChangeSet@1.1480.1.4, 2007-05-24 08:08:34-04:00, mayer@pogo.udel.edu +4 -0 - Bug #527 Don't write from source address length to wrong location +ChangeSet@1.1440.1.55, 2007-02-26 06:42:31-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P14 + TAG: NTP_4_2_5P14 - include/recvbuff.h@1.12, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +2 -0 - Bug #527 Don't write from source address length to wrong location + ntpd/ntpd-opts.c@1.69 +2 -2 + NTP_4_2_5P14 - libntp/recvbuff.c@1.25, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +27 -13 - Bug #527 Don't write from source address length to wrong location + ntpd/ntpd-opts.h@1.69 +3 -3 + NTP_4_2_5P14 - ports/winnt/libntp/transmitbuff.c@1.7, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +10 -10 - Bug #527 Don't write from source address length to wrong location + ntpd/ntpd-opts.texi@1.68 +1 -1 + NTP_4_2_5P14 - ports/winnt/ntpd/ntp_iocompletionport.c@1.22, 2007-05-24 08:08:03-04:00, mayer@pogo.udel.edu +76 -62 - Bug #527 Don't write from source address length to wrong location + ntpd/ntpd.1@1.67 +2 -2 + NTP_4_2_5P14 -ChangeSet@1.1480.1.3, 2007-05-19 07:53:57-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC2 - TAG: NTP_4_2_4P2_RC2 + ntpd/ntpdsim-opts.c@1.69 +2 -2 + NTP_4_2_5P14 - ntpd/ntpd-opts.c@1.61, 2007-05-19 07:53:35-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ntpd/ntpdsim-opts.h@1.69 +3 -3 + NTP_4_2_5P14 - ntpd/ntpd-opts.h@1.61, 2007-05-19 07:53:35-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + ntpd/ntpdsim-opts.texi@1.67 +1 -1 + NTP_4_2_5P14 - ntpd/ntpd-opts.texi@1.60, 2007-05-19 07:53:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + ntpd/ntpdsim.1@1.67 +2 -2 + NTP_4_2_5P14 - ntpd/ntpd.1@1.59, 2007-05-19 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc-opts.c@1.69 +2 -2 + NTP_4_2_5P14 - ntpd/ntpdsim-opts.c@1.61, 2007-05-19 07:53:38-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc-opts.h@1.69 +3 -3 + NTP_4_2_5P14 - ntpd/ntpdsim-opts.h@1.61, 2007-05-19 07:53:39-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc-opts.texi@1.67 +1 -1 + NTP_4_2_5P14 - ntpd/ntpdsim-opts.texi@1.59, 2007-05-19 07:53:40-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + ntpdc/ntpdc.1@1.67 +2 -2 + NTP_4_2_5P14 - ntpd/ntpdsim.1@1.59, 2007-05-19 07:53:40-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpq/ntpq-opts.c@1.71 +2 -2 + NTP_4_2_5P14 - ntpdc/ntpdc-opts.c@1.61, 2007-05-19 07:53:41-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ntpq/ntpq-opts.h@1.71 +3 -3 + NTP_4_2_5P14 - ntpdc/ntpdc-opts.h@1.61, 2007-05-19 07:53:42-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + ntpq/ntpq-opts.texi@1.68 +1 -1 + NTP_4_2_5P14 - ntpdc/ntpdc-opts.texi@1.59, 2007-05-19 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpq/ntpq.1@1.67 +2 -2 + NTP_4_2_5P14 - ntpdc/ntpdc.1@1.59, 2007-05-19 07:53:43-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + packageinfo.sh@1.17 +1 -1 + NTP_4_2_5P14 - ntpq/ntpq-opts.c@1.63, 2007-05-19 07:53:44-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + sntp/sntp-opts.c@1.68 +2 -2 + NTP_4_2_5P14 - ntpq/ntpq-opts.h@1.63, 2007-05-19 07:53:45-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + sntp/sntp-opts.h@1.68 +3 -3 + NTP_4_2_5P14 - ntpq/ntpq-opts.texi@1.60, 2007-05-19 07:53:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + sntp/sntp-opts.texi@1.65 +1 -1 + NTP_4_2_5P14 - ntpq/ntpq.1@1.59, 2007-05-19 07:53:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + sntp/sntp.1@1.68 +2 -2 + NTP_4_2_5P14 - packageinfo.sh@1.81, 2007-05-19 07:53:48-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + util/ntp-keygen-opts.c@1.68 +2 -2 + NTP_4_2_5P14 - sntp/sntp-opts.c@1.59, 2007-05-19 07:53:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + util/ntp-keygen-opts.h@1.68 +3 -3 + NTP_4_2_5P14 - sntp/sntp-opts.h@1.59, 2007-05-19 07:53:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 + util/ntp-keygen-opts.texi@1.66 +1 -1 + NTP_4_2_5P14 - sntp/sntp-opts.texi@1.56, 2007-05-19 07:53:49-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC2 + util/ntp-keygen.1@1.66 +2 -2 + NTP_4_2_5P14 - sntp/sntp.1@1.59, 2007-05-19 07:53:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 +ChangeSet@1.1440.1.54, 2007-02-25 18:42:26-05:00, stenn@whimsy.udel.edu + [Bug 789] Fix multicast client crypto authentication - util/ntp-keygen-opts.c@1.60, 2007-05-19 07:53:51-04:00, stenn@whimsy.udel.edu +4 -4 - NTP_4_2_4P2_RC2 + ChangeLog@1.15 +1 -0 + [Bug 789] Fix multicast client crypto authentication - util/ntp-keygen-opts.h@1.60, 2007-05-19 07:53:51-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC2 +ChangeSet@1.1440.1.53, 2007-02-25 17:21:59+00:00, kardel@pogo.udel.edu + ntp_peer.c: + Bug 789: + insure that crypto information is only cleared when the local address + changes. fixes multicast client mode - util/ntp-keygen-opts.texi@1.58, 2007-05-19 07:53:52-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 + ntpd/ntp_peer.c@1.100 +10 -13 + Bug 789: + insure that crypto information is only cleared when the local address + changes. fixes multicast client mode - util/ntp-keygen.1@1.58, 2007-05-19 07:53:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC2 +ChangeSet@1.1440.1.52, 2007-02-25 06:42:44-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P13 + TAG: NTP_4_2_5P13 -ChangeSet@1.1480.1.2, 2007-05-19 02:33:04-04:00, stenn@whimsy.udel.edu +193 -0 - We need another RC release to be sure the new autogen/libopts works. + ntpd/ntpd-opts.c@1.68 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-COPYING.lgpl~492b62c9d62ba57a@1.2, 2007-05-19 00:01:18-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.lgpl + ntpd/ntpd-opts.h@1.68 +3 -3 + NTP_4_2_5P13 - BitKeeper/deleted/.del-COPYING.lgpl~adfa2ac04d64c0f7@1.2, 2007-05-19 00:00:02-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.lgpl + ntpd/ntpd-opts.texi@1.67 +1 -1 + NTP_4_2_5P13 - BitKeeper/deleted/.del-COPYING.mbsd~7e1baaedfa33c877@1.2, 2007-05-19 00:00:03-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.mbsd + ntpd/ntpd.1@1.66 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-COPYING.mbsd~e8244dcf5895b58f@1.2, 2007-05-19 00:01:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.mbsd + ntpd/ntpdsim-opts.c@1.68 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-MakeDefs.inc~3fd54e9b117bfdad@1.2, 2007-05-19 00:01:20-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/MakeDefs.inc + ntpd/ntpdsim-opts.h@1.68 +3 -3 + NTP_4_2_5P13 - BitKeeper/deleted/.del-MakeDefs.inc~511eb438badc27b@1.2, 2007-05-19 00:00:04-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/MakeDefs.inc + ntpd/ntpdsim-opts.texi@1.66 +1 -1 + NTP_4_2_5P13 - BitKeeper/deleted/.del-Makefile.am~65692661e68a4392@1.2, 2007-05-19 00:00:04-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/Makefile.am + ntpd/ntpdsim.1@1.66 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-Makefile.am~fdf1a715e04b5f2c@1.2, 2007-05-19 00:01:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/Makefile.am + ntpdc/ntpdc-opts.c@1.68 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-README~7ed47aff36cc39c@1.2, 2007-05-19 00:01:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/README + ntpdc/ntpdc-opts.h@1.68 +3 -3 + NTP_4_2_5P13 - BitKeeper/deleted/.del-README~cec57621589d1ea6@1.2, 2007-05-19 00:00:05-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/README + ntpdc/ntpdc-opts.texi@1.66 +1 -1 + NTP_4_2_5P13 - BitKeeper/deleted/.del-autoopts.c~7b48d6dc5ca9c3b@1.2, 2007-05-19 00:01:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.c + ntpdc/ntpdc.1@1.66 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-autoopts.c~917f3eb3a2030087@1.2, 2007-05-19 00:00:06-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.c + ntpq/ntpq-opts.c@1.70 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-autoopts.h~4184ad33bbb8222@1.2, 2007-05-19 00:00:08-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.h + ntpq/ntpq-opts.h@1.70 +3 -3 + NTP_4_2_5P13 - BitKeeper/deleted/.del-autoopts.h~d0834f397c8a330d@1.2, 2007-05-19 00:01:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.h + ntpq/ntpq-opts.texi@1.67 +1 -1 + NTP_4_2_5P13 - BitKeeper/deleted/.del-boolean.c~50ae286fc516eee2@1.2, 2007-05-19 00:01:25-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/boolean.c + ntpq/ntpq.1@1.66 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-boolean.c~afd23e01a43b9536@1.2, 2007-05-19 00:00:09-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/boolean.c + packageinfo.sh@1.16 +1 -1 + NTP_4_2_5P13 - BitKeeper/deleted/.del-compat.h~2bcdd381f6a570a1@1.2, 2007-05-19 00:01:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/compat.h + sntp/sntp-opts.c@1.67 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-compat.h~e5d9fc11f0b928f2@1.2, 2007-05-19 00:00:35-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/compat.h + sntp/sntp-opts.h@1.67 +3 -3 + NTP_4_2_5P13 - BitKeeper/deleted/.del-configfile.c~53384c73e434a615@1.2, 2007-05-19 00:00:09-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/configfile.c + sntp/sntp-opts.texi@1.64 +1 -1 + NTP_4_2_5P13 - BitKeeper/deleted/.del-configfile.c~ee0b7d49d26b4f74@1.2, 2007-05-19 00:01:26-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/configfile.c + sntp/sntp.1@1.67 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-cook.c~760181d2119b672@1.2, 2007-05-19 00:01:27-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/cook.c + util/ntp-keygen-opts.c@1.67 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-cook.c~84c1af00a5581292@1.2, 2007-05-19 00:00:11-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/cook.c + util/ntp-keygen-opts.h@1.67 +3 -3 + NTP_4_2_5P13 - BitKeeper/deleted/.del-enumeration.c~551805256cb9068c@1.2, 2007-05-19 00:00:12-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/enumeration.c + util/ntp-keygen-opts.texi@1.65 +1 -1 + NTP_4_2_5P13 - BitKeeper/deleted/.del-enumeration.c~969462e75e3913a3@1.2, 2007-05-19 00:01:29-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/enumeration.c + util/ntp-keygen.1@1.65 +2 -2 + NTP_4_2_5P13 - BitKeeper/deleted/.del-environment.c~643ce1e5a16a4f94@1.2, 2007-05-19 00:01:30-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/environment.c +ChangeSet@1.1440.1.51, 2007-02-25 00:21:52+00:00, kardel@pogo.udel.edu + ntp_io.c: + bug 785: + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) + ntp_peer.c: + clarify debug messages - BitKeeper/deleted/.del-environment.c~965d8c0fdf1150f5@1.2, 2007-05-19 00:00:13-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/environment.c + ntpd/ntp_io.c@1.245.1.3 +84 -62 + bug 785: + improve handling of multicast interfaces + (multicast routers still need to run a multicast routing software/daemon) - BitKeeper/deleted/.del-genshell.c~20529138c60103c3@1.2, 2007-05-19 00:00:14-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.c + ntpd/ntp_peer.c@1.99 +2 -2 + clarify debug messages - BitKeeper/deleted/.del-genshell.c~bd74153097ec640f@1.2, 2007-05-19 00:01:31-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.c +ChangeSet@1.1440.1.50, 2007-02-24 08:33:25-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P12 + TAG: NTP_4_2_5P12 - BitKeeper/deleted/.del-genshell.h~7f41539b135f914a@1.2, 2007-05-19 00:00:15-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.h + ntpd/ntpd-opts.c@1.67 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-genshell.h~b2793e1ea2981ff5@1.2, 2007-05-19 00:01:32-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.h + ntpd/ntpd-opts.h@1.67 +3 -3 + NTP_4_2_5P12 - BitKeeper/deleted/.del-libopts.c~9353e1c3a0c56ad@1.2, 2007-05-19 00:00:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/libopts.c + ntpd/ntpd-opts.texi@1.66 +1 -1 + NTP_4_2_5P12 - BitKeeper/deleted/.del-libopts.c~bfc74bb368a309be@1.2, 2007-05-19 00:01:33-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/libopts.c + ntpd/ntpd.1@1.65 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-libopts.m4~9851dd84df41023b@1.2, 2007-05-19 00:00:40-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/libopts.m4 + ntpd/ntpdsim-opts.c@1.67 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-libopts.m4~9fa7e371d1cc0426@1.2, 2007-05-19 00:02:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/libopts.m4 + ntpd/ntpdsim-opts.h@1.67 +3 -3 + NTP_4_2_5P12 - BitKeeper/deleted/.del-liboptschk.m4~1828e1c4576e5aea@1.2, 2007-05-19 00:00:41-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/liboptschk.m4 + ntpd/ntpdsim-opts.texi@1.65 +1 -1 + NTP_4_2_5P12 - BitKeeper/deleted/.del-liboptschk.m4~480d5c4f1634a9fa@1.2, 2007-05-19 00:02:01-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/liboptschk.m4 + ntpd/ntpdsim.1@1.65 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-load.c~688d4934eb14272@1.2, 2007-05-19 00:01:34-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/load.c + ntpdc/ntpdc-opts.c@1.67 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-load.c~b6aa568c6e3eaca1@1.2, 2007-05-19 00:00:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/load.c + ntpdc/ntpdc-opts.h@1.67 +3 -3 + NTP_4_2_5P12 - BitKeeper/deleted/.del-makeshell.c~8c63bc5a263da752@1.2, 2007-05-19 00:01:35-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/makeshell.c + ntpdc/ntpdc-opts.texi@1.65 +1 -1 + NTP_4_2_5P12 - BitKeeper/deleted/.del-makeshell.c~a9cd96c3bfbc0835@1.2, 2007-05-19 00:00:17-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/makeshell.c + ntpdc/ntpdc.1@1.65 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-nested.c~1670193227f54043@1.2, 2007-05-19 00:01:36-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/nested.c + ntpq/ntpq-opts.c@1.69 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-nested.c~a8521c8fcff292b6@1.2, 2007-05-19 00:00:18-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/nested.c + ntpq/ntpq-opts.h@1.69 +3 -3 + NTP_4_2_5P12 - BitKeeper/deleted/.del-numeric.c~eb3fbec29633e61@1.2, 2007-05-19 00:01:37-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/numeric.c + ntpq/ntpq-opts.texi@1.66 +1 -1 + NTP_4_2_5P12 - BitKeeper/deleted/.del-numeric.c~ec644fa246942cbc@1.2, 2007-05-19 00:00:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/numeric.c + ntpq/ntpq.1@1.65 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-options.h~3cb6af32ad01957@1.2, 2007-05-19 00:01:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/options.h + packageinfo.sh@1.15 +1 -1 + NTP_4_2_5P12 - BitKeeper/deleted/.del-options.h~f700d69ce23e3e23@1.2, 2007-05-19 00:00:33-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/options.h + sntp/sntp-opts.c@1.66 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-pathfind.c~953a96dbc9932@1.2, 2007-05-19 00:01:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/pathfind.c + sntp/sntp-opts.h@1.66 +3 -3 + NTP_4_2_5P12 - BitKeeper/deleted/.del-pathfind.c~c132dab083075929@1.2, 2007-05-19 00:00:36-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/pathfind.c + sntp/sntp-opts.texi@1.63 +1 -1 + NTP_4_2_5P12 - BitKeeper/deleted/.del-pgusage.c~5c1f8f132e9a1546@1.2, 2007-05-19 00:01:39-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/pgusage.c + sntp/sntp.1@1.66 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-pgusage.c~cec1309617012832@1.2, 2007-05-19 00:00:20-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/pgusage.c + util/ntp-keygen-opts.c@1.66 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-proto.h~697b4937ff37ca3f@1.2, 2007-05-19 00:01:40-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/proto.h + util/ntp-keygen-opts.h@1.66 +3 -3 + NTP_4_2_5P12 - BitKeeper/deleted/.del-proto.h~e2a13f546fbc0d4f@1.2, 2007-05-19 00:00:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/proto.h + util/ntp-keygen-opts.texi@1.64 +1 -1 + NTP_4_2_5P12 - BitKeeper/deleted/.del-putshell.c~6845ea506fad6426@1.2, 2007-05-19 00:01:41-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/putshell.c + util/ntp-keygen.1@1.64 +2 -2 + NTP_4_2_5P12 - BitKeeper/deleted/.del-putshell.c~6e39e6836261f3f7@1.2, 2007-05-19 00:00:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/putshell.c +ChangeSet@1.1436.1.33, 2007-02-24 06:42:26-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P0_RC5 + TAG: NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-restore.c~c14d8b96be44c6a8@1.2, 2007-05-19 00:01:42-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/restore.c + ntpd/ntpd-opts.c@1.50.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-restore.c~e2a155efceab6f0d@1.2, 2007-05-19 00:00:23-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/restore.c + ntpd/ntpd-opts.h@1.50.1.5 +3 -3 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-save.c~17e5ac125a404fb0@1.2, 2007-05-19 00:00:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/save.c + ntpd/ntpd-opts.texi@1.49.1.5 +1 -1 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-save.c~e7e7366cd24e1a8f@1.2, 2007-05-19 00:01:43-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/save.c + ntpd/ntpd.1@1.48.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-snprintf.c~4b42e45647e9ccef@1.2, 2007-05-19 00:00:38-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/snprintf.c + ntpd/ntpdsim-opts.c@1.50.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-snprintf.c~988df6799c67781f@1.2, 2007-05-19 00:01:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/snprintf.c + ntpd/ntpdsim-opts.h@1.50.1.5 +3 -3 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-sort.c~586535d7d26d958@1.2, 2007-05-19 00:01:44-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/sort.c + ntpd/ntpdsim-opts.texi@1.48.1.5 +1 -1 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-sort.c~bb92da923b5dcb7@1.2, 2007-05-19 00:00:25-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/sort.c + ntpd/ntpdsim.1@1.48.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-stack.c~202d33ccdfd74ec@1.2, 2007-05-19 00:01:45-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/stack.c + ntpdc/ntpdc-opts.c@1.50.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-stack.c~b60d0ab82970f41f@1.2, 2007-05-19 00:00:26-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/stack.c + ntpdc/ntpdc-opts.h@1.50.1.5 +3 -3 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-strchr.c~4a7e412c18f53557@1.2, 2007-05-19 00:01:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strchr.c + ntpdc/ntpdc-opts.texi@1.48.1.5 +1 -1 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-strchr.c~7f4589858587fcc4@1.2, 2007-05-19 00:00:38-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strchr.c + ntpdc/ntpdc.1@1.48.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-strdup.c~75e27662f28944b1@1.2, 2007-05-19 00:01:58-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strdup.c + ntpq/ntpq-opts.c@1.52.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-strdup.c~b295027011406c46@1.2, 2007-05-19 00:00:39-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strdup.c + ntpq/ntpq-opts.h@1.52.1.5 +3 -3 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-streqvcmp.c~999e9cfa251ea4b3@1.2, 2007-05-19 00:00:28-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/streqvcmp.c + ntpq/ntpq-opts.texi@1.49.1.5 +1 -1 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-streqvcmp.c~dc5534ffb1c6f28@1.2, 2007-05-19 00:01:47-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/streqvcmp.c + ntpq/ntpq.1@1.48.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-text_mmap.c~52f2f1dbe57a9743@1.2, 2007-05-19 00:00:29-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/text_mmap.c + packageinfo.sh@1.65.6.1 +1 -1 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-text_mmap.c~e5096667484e499a@1.2, 2007-05-19 00:01:48-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/text_mmap.c + sntp/sntp-opts.c@1.49.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-tokenize.c~315c26f9b162f234@1.2, 2007-05-19 00:01:49-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/tokenize.c + sntp/sntp-opts.h@1.49.1.5 +3 -3 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-tokenize.c~6a814216fa293c3c@1.2, 2007-05-19 00:00:30-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/tokenize.c + sntp/sntp-opts.texi@1.46.1.5 +1 -1 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-usage-txt.h~3737a7c76813e8c3@1.2, 2007-05-19 00:00:34-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/usage-txt.h + sntp/sntp.1@1.49.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-usage-txt.h~b71acc916d68c58c@1.2, 2007-05-19 00:01:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/usage-txt.h + util/ntp-keygen-opts.c@1.49.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-usage.c~f21924faa210bfa9@1.2, 2007-05-19 00:01:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/usage.c + util/ntp-keygen-opts.h@1.49.1.5 +3 -3 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-usage.c~fe9a0f55b3cc55e4@1.2, 2007-05-19 00:00:31-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/usage.c + util/ntp-keygen-opts.texi@1.47.1.5 +1 -1 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-version.c~b69eccbdea7f51d9@1.2, 2007-05-19 00:01:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/version.c + util/ntp-keygen.1@1.47.1.5 +2 -2 + NTP_4_2_4P0_RC5 - BitKeeper/deleted/.del-version.c~de7f014d3e2ac91e@1.2, 2007-05-19 00:00:32-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/version.c +ChangeSet@1.1440.1.49, 2007-02-24 05:24:04-05:00, stenn@whimsy.udel.edu + Updates to ntp_loopfilter.c from Dave Mills - BitKeeper/deleted/.del-windows-config.h~11a9a57b2895598f@1.2, 2007-05-19 00:01:59-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/windows-config.h + ntpd/ntp_loopfilter.c@1.132 +2 -3 + Updates to ntp_loopfilter.c from Dave Mills - BitKeeper/deleted/.del-windows-config.h~a6ead462c3d18ff0@1.2, 2007-05-19 00:00:39-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/windows-config.h +ChangeSet@1.1436.1.32, 2007-02-24 05:07:16-05:00, stenn@whimsy.udel.edu + [Bug 628] Fallback to ntp discipline not working for large offsets - clockstuff/clktest-opts.c@1.10, 2007-05-19 02:30:32-04:00, stenn@whimsy.udel.edu +38 -270 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntp_loopfilter.c@1.127.1.1 +9 -24 + [Bug 628] Fallback to ntp discipline not working for large offsets - clockstuff/clktest-opts.def@1.6, 2007-05-19 02:27:39-04:00, stenn@whimsy.udel.edu +4 -0 - We need to use the upgraded autogen/libopts in -stable too. +ChangeSet@1.1440.1.47, 2007-02-23 06:42:48-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P11 + TAG: NTP_4_2_5P11 - clockstuff/clktest-opts.h@1.10, 2007-05-19 02:30:33-04:00, stenn@whimsy.udel.edu +22 -57 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.c@1.66 +2 -2 + NTP_4_2_5P11 - include/autogen-version.def@1.4, 2007-05-19 02:27:41-04:00, stenn@whimsy.udel.edu +1 -1 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.h@1.66 +3 -3 + NTP_4_2_5P11 - libopts/COPYING.lgpl@1.1, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.lgpl + ntpd/ntpd-opts.texi@1.65 +1 -1 + NTP_4_2_5P11 - libopts/COPYING.lgpl@1.0, 2007-05-19 00:04:01-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.1@1.64 +2 -2 + NTP_4_2_5P11 - libopts/COPYING.mbsd@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/COPYING.mbsd + ntpd/ntpdsim-opts.c@1.66 +2 -2 + NTP_4_2_5P11 - libopts/COPYING.mbsd@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.h@1.66 +3 -3 + NTP_4_2_5P11 - libopts/MakeDefs.inc@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/MakeDefs.inc + ntpd/ntpdsim-opts.texi@1.64 +1 -1 + NTP_4_2_5P11 - libopts/MakeDefs.inc@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim.1@1.64 +2 -2 + NTP_4_2_5P11 - libopts/Makefile.am@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/Makefile.am + ntpdc/ntpdc-opts.c@1.66 +2 -2 + NTP_4_2_5P11 - libopts/Makefile.am@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.h@1.66 +3 -3 + NTP_4_2_5P11 - libopts/README@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/README + ntpdc/ntpdc-opts.texi@1.64 +1 -1 + NTP_4_2_5P11 - libopts/README@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.1@1.64 +2 -2 + NTP_4_2_5P11 - libopts/autoopts.c@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +1120 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.c + ntpq/ntpq-opts.c@1.68 +2 -2 + NTP_4_2_5P11 - libopts/autoopts.c@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.h@1.68 +3 -3 + NTP_4_2_5P11 - libopts/autoopts.h@1.1, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +387 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts.h + ntpq/ntpq-opts.texi@1.65 +1 -1 + NTP_4_2_5P11 - libopts/autoopts.h@1.0, 2007-05-19 00:04:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.1@1.64 +2 -2 + NTP_4_2_5P11 - libopts/autoopts/options.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +977 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/options.h + packageinfo.sh@1.14 +1 -1 + NTP_4_2_5P11 - libopts/autoopts/options.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.65 +2 -2 + NTP_4_2_5P11 - libopts/autoopts/usage-txt.h@1.1, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/autoopts/usage-txt.h + sntp/sntp-opts.h@1.65 +3 -3 + NTP_4_2_5P11 - libopts/autoopts/usage-txt.h@1.0, 2007-05-19 00:04:14-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.texi@1.62 +1 -1 + NTP_4_2_5P11 - libopts/boolean.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/boolean.c + sntp/sntp.1@1.65 +2 -2 + NTP_4_2_5P11 - libopts/boolean.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.65 +2 -2 + NTP_4_2_5P11 - libopts/compat/compat.h@1.1, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +319 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/compat.h + util/ntp-keygen-opts.h@1.65 +3 -3 + NTP_4_2_5P11 - libopts/compat/compat.h@1.0, 2007-05-19 00:04:15-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.63 +1 -1 + NTP_4_2_5P11 - libopts/compat/pathfind.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/pathfind.c + util/ntp-keygen.1@1.63 +2 -2 + NTP_4_2_5P11 - libopts/compat/pathfind.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.46, 2007-02-23 03:16:58-05:00, stenn@whimsy.udel.edu + [Bug 774] parsesolaris.c does not compile under the new Solaris - libopts/compat/snprintf.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/snprintf.c + libparse/Makefile.am@1.11 +1 -1 + [Bug 774] parsesolaris.c does not compile under the new Solaris - libopts/compat/snprintf.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.45, 2007-02-23 02:47:57-05:00, stenn@whimsy.udel.edu + [Bug 774] parsesolaris.c does not compile under the new Solaris - libopts/compat/strchr.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strchr.c + ChangeLog@1.14 +1 -0 + [Bug 774] parsesolaris.c does not compile under the new Solaris - libopts/compat/strchr.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + libparse/Makefile.am@1.10 +1 -1 + [Bug 774] parsesolaris.c does not compile under the new Solaris - libopts/compat/strdup.c@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/strdup.c +ChangeSet@1.1440.1.44, 2007-02-22 06:46:29-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P10 + TAG: NTP_4_2_5P10 - libopts/compat/strdup.c@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.65 +2 -2 + NTP_4_2_5P10 - libopts/compat/windows-config.h@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +130 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/compat/windows-config.h + ntpd/ntpd-opts.h@1.65 +3 -3 + NTP_4_2_5P10 - libopts/compat/windows-config.h@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.64 +1 -1 + NTP_4_2_5P10 - libopts/configfile.c@1.1, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +1290 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/configfile.c + ntpd/ntpd.1@1.63 +2 -2 + NTP_4_2_5P10 - libopts/configfile.c@1.0, 2007-05-19 00:04:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.65 +2 -2 + NTP_4_2_5P10 - libopts/cook.c@1.1, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/cook.c + ntpd/ntpdsim-opts.h@1.65 +3 -3 + NTP_4_2_5P10 - libopts/cook.c@1.0, 2007-05-19 00:04:04-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.63 +1 -1 + NTP_4_2_5P10 - libopts/enumeration.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/enumeration.c + ntpd/ntpdsim.1@1.63 +2 -2 + NTP_4_2_5P10 - libopts/enumeration.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.65 +2 -2 + NTP_4_2_5P10 - libopts/environment.c@1.1, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +279 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/environment.c + ntpdc/ntpdc-opts.h@1.65 +3 -3 + NTP_4_2_5P10 - libopts/environment.c@1.0, 2007-05-19 00:04:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.63 +1 -1 + NTP_4_2_5P10 - libopts/genshell.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.c + ntpdc/ntpdc.1@1.63 +2 -2 + NTP_4_2_5P10 - libopts/genshell.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.67 +2 -2 + NTP_4_2_5P10 - libopts/genshell.h@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/genshell.h + ntpq/ntpq-opts.h@1.67 +3 -3 + NTP_4_2_5P10 - libopts/genshell.h@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.64 +1 -1 + NTP_4_2_5P10 - libopts/libopts.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/libopts.c + ntpq/ntpq.1@1.63 +2 -2 + NTP_4_2_5P10 - libopts/libopts.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.13 +1 -1 + NTP_4_2_5P10 - libopts/load.c@1.1, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/load.c + sntp/sntp-opts.c@1.64 +2 -2 + NTP_4_2_5P10 - libopts/load.c@1.0, 2007-05-19 00:04:06-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.64 +3 -3 + NTP_4_2_5P10 - libopts/m4/libopts.m4@1.1, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +509 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/libopts.m4 + sntp/sntp-opts.texi@1.61 +1 -1 + NTP_4_2_5P10 - libopts/m4/libopts.m4@1.0, 2007-05-19 00:04:16-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.64 +2 -2 + NTP_4_2_5P10 - libopts/m4/liboptschk.m4@1.1, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/m4/liboptschk.m4 + util/ntp-keygen-opts.c@1.64 +2 -2 + NTP_4_2_5P10 - libopts/m4/liboptschk.m4@1.0, 2007-05-19 00:04:17-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.64 +3 -3 + NTP_4_2_5P10 - libopts/makeshell.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/makeshell.c + util/ntp-keygen-opts.texi@1.62 +1 -1 + NTP_4_2_5P10 - libopts/makeshell.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.62 +2 -2 + NTP_4_2_5P10 - libopts/nested.c@1.1, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/nested.c +ChangeSet@1.1436.1.31, 2007-02-21 15:16:15-05:00, stenn@whimsy.udel.edu + [Bug 776] Remove the obsolete r: from the getopt string in ntpdate - libopts/nested.c@1.0, 2007-05-19 00:04:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdate/ntpdate.c@1.59.1.2 +1 -1 + [Bug 776] Remove the obsolete r: from the getopt string in ntpdate - libopts/numeric.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/numeric.c +ChangeSet@1.1440.1.42, 2007-02-19 08:43:35-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P9 + TAG: NTP_4_2_5P9 - libopts/numeric.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.63 +2 -2 + NTP_4_2_5P9 - libopts/pgusage.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/pgusage.c + ntpd/ntpd-opts.h@1.63 +3 -3 + NTP_4_2_5P9 - libopts/pgusage.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.62 +2 -2 + NTP_4_2_5P9 - libopts/proto.h@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/proto.h + ntpd/ntpd.1@1.61 +2 -2 + NTP_4_2_5P9 - libopts/proto.h@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.63 +2 -2 + NTP_4_2_5P9 - libopts/putshell.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/putshell.c + ntpd/ntpdsim-opts.h@1.63 +3 -3 + NTP_4_2_5P9 - libopts/putshell.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.61 +1 -1 + NTP_4_2_5P9 - libopts/restore.c@1.1, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/restore.c + ntpd/ntpdsim.1@1.61 +2 -2 + NTP_4_2_5P9 - libopts/restore.c@1.0, 2007-05-19 00:04:08-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.63 +2 -2 + NTP_4_2_5P9 - libopts/save.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/save.c + ntpdc/ntpdc-opts.h@1.63 +3 -3 + NTP_4_2_5P9 - libopts/save.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.61 +2 -2 + NTP_4_2_5P9 - libopts/sort.c@1.1, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/sort.c + ntpdc/ntpdc.1@1.61 +2 -2 + NTP_4_2_5P9 - libopts/sort.c@1.0, 2007-05-19 00:04:09-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.65 +2 -2 + NTP_4_2_5P9 - libopts/stack.c@1.1, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/stack.c + ntpq/ntpq-opts.h@1.65 +3 -3 + NTP_4_2_5P9 - libopts/stack.c@1.0, 2007-05-19 00:04:10-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.62 +2 -2 + NTP_4_2_5P9 - libopts/streqvcmp.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/streqvcmp.c + ntpq/ntpq.1@1.61 +2 -2 + NTP_4_2_5P9 - libopts/streqvcmp.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.12 +1 -1 + NTP_4_2_5P9 - libopts/text_mmap.c@1.1, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/text_mmap.c + sntp/sntp-opts.c@1.62 +2 -2 + NTP_4_2_5P9 - libopts/text_mmap.c@1.0, 2007-05-19 00:04:11-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.62 +3 -3 + NTP_4_2_5P9 - libopts/tokenize.c@1.1, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/tokenize.c + sntp/sntp-opts.texi@1.59 +1 -1 + NTP_4_2_5P9 - libopts/tokenize.c@1.0, 2007-05-19 00:04:12-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.62 +2 -2 + NTP_4_2_5P9 - libopts/usage.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +740 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/usage.c + util/ntp-keygen-opts.c@1.62 +2 -2 + NTP_4_2_5P9 - libopts/usage.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.62 +3 -3 + NTP_4_2_5P9 - libopts/version.c@1.1, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +178 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/libopts/version.c + util/ntp-keygen-opts.texi@1.60 +2 -2 + NTP_4_2_5P9 - libopts/version.c@1.0, 2007-05-19 00:04:13-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.60 +2 -2 + NTP_4_2_5P9 - ntpd/ntpd-opts.c@1.60, 2007-05-19 02:30:34-04:00, stenn@whimsy.udel.edu +20 -11 - We need to use the upgraded autogen/libopts in -stable too. +ChangeSet@1.1436.1.30, 2007-02-19 06:46:30-05:00, stenn@whimsy.udel.edu + NTP_4_2_4P0_RC4 + TAG: NTP_4_2_4P0_RC4 - ntpd/ntpd-opts.h@1.60, 2007-05-19 02:30:36-04:00, stenn@whimsy.udel.edu +4 -4 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.c@1.50.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpd/ntpd-opts.texi@1.59, 2007-05-19 02:30:36-04:00, stenn@whimsy.udel.edu +2 -8 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.h@1.50.1.4 +3 -3 + NTP_4_2_4P0_RC4 - ntpd/ntpd.1@1.58, 2007-05-19 02:30:37-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.texi@1.49.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpd/ntpdsim-opts.c@1.60, 2007-05-19 02:30:40-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd.1@1.48.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpd/ntpdsim-opts.h@1.60, 2007-05-19 02:30:41-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim-opts.c@1.50.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpd/ntpdsim-opts.texi@1.58, 2007-05-19 02:30:43-04:00, stenn@whimsy.udel.edu +1 -1 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim-opts.h@1.50.1.4 +3 -3 + NTP_4_2_4P0_RC4 - ntpd/ntpdsim.1@1.58, 2007-05-19 02:30:44-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim-opts.texi@1.48.1.4 +1 -1 + NTP_4_2_4P0_RC4 - ntpdc/ntpdc-opts.c@1.60, 2007-05-19 02:30:45-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim.1@1.48.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpdc/ntpdc-opts.h@1.60, 2007-05-19 02:30:48-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + ntpdc/ntpdc-opts.c@1.50.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpdc/ntpdc-opts.texi@1.58, 2007-05-19 02:30:48-04:00, stenn@whimsy.udel.edu +3 -3 - We need to use the upgraded autogen/libopts in -stable too. + ntpdc/ntpdc-opts.h@1.50.1.4 +3 -3 + NTP_4_2_4P0_RC4 - ntpdc/ntpdc.1@1.58, 2007-05-19 02:30:49-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpdc/ntpdc-opts.texi@1.48.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpq/ntpq-opts.c@1.62, 2007-05-19 02:30:50-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + ntpdc/ntpdc.1@1.48.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpq/ntpq-opts.h@1.62, 2007-05-19 02:30:51-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + ntpq/ntpq-opts.c@1.52.1.4 +2 -2 + NTP_4_2_4P0_RC4 - ntpq/ntpq-opts.texi@1.59, 2007-05-19 02:30:52-04:00, stenn@whimsy.udel.edu +3 -3 - We need to use the upgraded autogen/libopts in -stable too. + ntpq/ntpq-opts.h@1.52.1.4 +3 -3 + NTP_4_2_4P0_RC4 - ntpq/ntpq.1@1.58, 2007-05-19 02:30:53-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpq/ntpq-opts.texi@1.49.1.4 +2 -2 + NTP_4_2_4P0_RC4 - packageinfo.sh@1.80, 2007-05-19 02:28:15-04:00, stenn@whimsy.udel.edu +1 -1 - We need another RC release to be sure the new autogen/libopts works. + ntpq/ntpq.1@1.48.1.4 +2 -2 + NTP_4_2_4P0_RC4 - sntp/libopts/COPYING.lgpl@1.1, 2007-05-19 00:04:59-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.lgpl + packageinfo.sh@1.65.5.1 +3 -3 + NTP_4_2_4P0_RC4 - sntp/libopts/COPYING.lgpl@1.0, 2007-05-19 00:04:59-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.49.1.4 +2 -2 + NTP_4_2_4P0_RC4 - sntp/libopts/COPYING.mbsd@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/COPYING.mbsd + sntp/sntp-opts.h@1.49.1.4 +3 -3 + NTP_4_2_4P0_RC4 - sntp/libopts/COPYING.mbsd@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.texi@1.46.1.4 +1 -1 + NTP_4_2_4P0_RC4 - sntp/libopts/MakeDefs.inc@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/MakeDefs.inc + sntp/sntp.1@1.49.1.4 +2 -2 + NTP_4_2_4P0_RC4 - sntp/libopts/MakeDefs.inc@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.49.1.4 +2 -2 + NTP_4_2_4P0_RC4 - sntp/libopts/Makefile.am@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/Makefile.am + util/ntp-keygen-opts.h@1.49.1.4 +3 -3 + NTP_4_2_4P0_RC4 - sntp/libopts/Makefile.am@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.47.1.4 +2 -2 + NTP_4_2_4P0_RC4 - sntp/libopts/README@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/README + util/ntp-keygen.1@1.47.1.4 +2 -2 + NTP_4_2_4P0_RC4 - sntp/libopts/README@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.41, 2007-02-19 05:26:33-05:00, stenn@whimsy.udel.edu + [Bug 782] Remove P() macros from Windows files - sntp/libopts/autoopts.c@1.1, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +1120 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.c + ChangeLog@1.13 +1 -0 + [Bug 782] Remove P() macros from Windows files - sntp/libopts/autoopts.c@1.0, 2007-05-19 00:05:00-04:00, stenn@whimsy.udel.edu +0 -0 + ports/winnt/include/ntp_timer.h@1.4 +3 -5 + [Bug 782] Remove P() macros from Windows files - sntp/libopts/autoopts.h@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +387 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts.h + ports/winnt/include/transmitbuff.h@1.6 +3 -3 + [Bug 782] Remove P() macros from Windows files - sntp/libopts/autoopts.h@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + ports/winnt/include/win32_io.h@1.8 +2 -2 + [Bug 782] Remove P() macros from Windows files - sntp/libopts/autoopts/options.h@1.1, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +977 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/options.h +ChangeSet@1.1436.1.29, 2007-02-19 00:19:22-05:00, stenn@whimsy.udel.edu + Ready to go... - sntp/libopts/autoopts/options.h@1.0, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.65.4.2 +2 -2 + Ready to go... - sntp/libopts/autoopts/usage-txt.h@1.1, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/autoopts/usage-txt.h +ChangeSet@1.1436.1.28, 2007-02-19 00:14:29-05:00, stenn@whimsy.udel.edu + [Bug 776] Remove unimplemented "rate" flag from ntpdate - sntp/libopts/autoopts/usage-txt.h@1.0, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.1.1.8 +1 -0 + [Bug 776] Remove unimplemented "rate" flag from ntpdate - sntp/libopts/boolean.c@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/boolean.c + ntpdate/Makefile.am@1.14.1.1 +1 -1 + [Bug 776] Remove unimplemented "rate" flag from ntpdate - sntp/libopts/boolean.c@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdate/ntpdate.c@1.59.1.1 +1 -21 + [Bug 776] Remove unimplemented "rate" flag from ntpdate - sntp/libopts/compat/compat.h@1.1, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +319 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/compat.h +ChangeSet@1.1440.1.39, 2007-02-17 06:42:34-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P8 + TAG: NTP_4_2_5P8 - sntp/libopts/compat/compat.h@1.0, 2007-05-19 00:05:13-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.61 +2 -2 + NTP_4_2_5P8 - sntp/libopts/compat/pathfind.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/pathfind.c + ntpd/ntpd-opts.h@1.61 +3 -3 + NTP_4_2_5P8 - sntp/libopts/compat/pathfind.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.60 +1 -1 + NTP_4_2_5P8 - sntp/libopts/compat/snprintf.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/snprintf.c + ntpd/ntpd.1@1.59 +2 -2 + NTP_4_2_5P8 - sntp/libopts/compat/snprintf.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.61 +2 -2 + NTP_4_2_5P8 - sntp/libopts/compat/strchr.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strchr.c + ntpd/ntpdsim-opts.h@1.61 +3 -3 + NTP_4_2_5P8 - sntp/libopts/compat/strchr.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.59 +1 -1 + NTP_4_2_5P8 - sntp/libopts/compat/strdup.c@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/strdup.c + ntpd/ntpdsim.1@1.59 +2 -2 + NTP_4_2_5P8 - sntp/libopts/compat/strdup.c@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.61 +2 -2 + NTP_4_2_5P8 - sntp/libopts/compat/windows-config.h@1.1, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +130 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/compat/windows-config.h + ntpdc/ntpdc-opts.h@1.61 +3 -3 + NTP_4_2_5P8 - sntp/libopts/compat/windows-config.h@1.0, 2007-05-19 00:05:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.59 +1 -1 + NTP_4_2_5P8 - sntp/libopts/configfile.c@1.1, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +1290 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/configfile.c + ntpdc/ntpdc.1@1.59 +2 -2 + NTP_4_2_5P8 - sntp/libopts/configfile.c@1.0, 2007-05-19 00:05:01-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.63 +2 -2 + NTP_4_2_5P8 - sntp/libopts/cook.c@1.1, 2007-05-19 00:05:02-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/cook.c + ntpq/ntpq-opts.h@1.63 +3 -3 + NTP_4_2_5P8 - sntp/libopts/cook.c@1.0, 2007-05-19 00:05:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.60 +1 -1 + NTP_4_2_5P8 - sntp/libopts/enumeration.c@1.1, 2007-05-19 00:05:03-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/enumeration.c + ntpq/ntpq.1@1.59 +2 -2 + NTP_4_2_5P8 - sntp/libopts/enumeration.c@1.0, 2007-05-19 00:05:03-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.11 +1 -1 + NTP_4_2_5P8 - sntp/libopts/environment.c@1.1, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +279 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/environment.c + sntp/sntp-opts.c@1.60 +2 -2 + NTP_4_2_5P8 - sntp/libopts/environment.c@1.0, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.60 +3 -3 + NTP_4_2_5P8 - sntp/libopts/genshell.c@1.1, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.c + sntp/sntp-opts.texi@1.57 +1 -1 + NTP_4_2_5P8 - sntp/libopts/genshell.c@1.0, 2007-05-19 00:05:04-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.60 +2 -2 + NTP_4_2_5P8 - sntp/libopts/genshell.h@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/genshell.h + util/ntp-keygen-opts.c@1.60 +2 -2 + NTP_4_2_5P8 - sntp/libopts/genshell.h@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.60 +3 -3 + NTP_4_2_5P8 - sntp/libopts/libopts.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/libopts.c + util/ntp-keygen-opts.texi@1.58 +1 -1 + NTP_4_2_5P8 - sntp/libopts/libopts.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.58 +2 -2 + NTP_4_2_5P8 - sntp/libopts/load.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/load.c +ChangeSet@1.1440.1.38, 2007-02-17 04:40:04-05:00, stenn@whimsy.udel.edu + ntpd.h: + Lose the fabs() and sqrt() declarations because + they are in math.h and "lose" on some HP-UX machines. - sntp/libopts/load.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntpd.h@1.100 +0 -3 + Lose the fabs() and sqrt() declarations because + they are in math.h and "lose" on some HP-UX machines. - sntp/libopts/m4/libopts.m4@1.1, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +509 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/libopts.m4 +ChangeSet@1.1440.1.37, 2007-02-16 06:42:39-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P7 + TAG: NTP_4_2_5P7 - sntp/libopts/m4/libopts.m4@1.0, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.60 +2 -2 + NTP_4_2_5P7 - sntp/libopts/m4/liboptschk.m4@1.1, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/m4/liboptschk.m4 + ntpd/ntpd-opts.h@1.60 +3 -3 + NTP_4_2_5P7 - sntp/libopts/m4/liboptschk.m4@1.0, 2007-05-19 00:05:15-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.59 +1 -1 + NTP_4_2_5P7 - sntp/libopts/makeshell.c@1.1, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/makeshell.c + ntpd/ntpd.1@1.58 +2 -2 + NTP_4_2_5P7 - sntp/libopts/makeshell.c@1.0, 2007-05-19 00:05:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.60 +2 -2 + NTP_4_2_5P7 - sntp/libopts/nested.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/nested.c + ntpd/ntpdsim-opts.h@1.60 +3 -3 + NTP_4_2_5P7 - sntp/libopts/nested.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.58 +1 -1 + NTP_4_2_5P7 - sntp/libopts/numeric.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/numeric.c + ntpd/ntpdsim.1@1.58 +2 -2 + NTP_4_2_5P7 - sntp/libopts/numeric.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.60 +2 -2 + NTP_4_2_5P7 - sntp/libopts/pgusage.c@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/pgusage.c + ntpdc/ntpdc-opts.h@1.60 +3 -3 + NTP_4_2_5P7 - sntp/libopts/pgusage.c@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.58 +1 -1 + NTP_4_2_5P7 - sntp/libopts/proto.h@1.1, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/proto.h + ntpdc/ntpdc.1@1.58 +2 -2 + NTP_4_2_5P7 - sntp/libopts/proto.h@1.0, 2007-05-19 00:05:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.62 +2 -2 + NTP_4_2_5P7 - sntp/libopts/putshell.c@1.1, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/putshell.c + ntpq/ntpq-opts.h@1.62 +3 -3 + NTP_4_2_5P7 - sntp/libopts/putshell.c@1.0, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.59 +1 -1 + NTP_4_2_5P7 - sntp/libopts/restore.c@1.1, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/restore.c + ntpq/ntpq.1@1.58 +2 -2 + NTP_4_2_5P7 - sntp/libopts/restore.c@1.0, 2007-05-19 00:05:07-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.10 +1 -1 + NTP_4_2_5P7 - sntp/libopts/save.c@1.1, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/save.c + sntp/sntp-opts.c@1.59 +2 -2 + NTP_4_2_5P7 - sntp/libopts/save.c@1.0, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.59 +3 -3 + NTP_4_2_5P7 - sntp/libopts/sort.c@1.1, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/sort.c + sntp/sntp-opts.texi@1.56 +1 -1 + NTP_4_2_5P7 - sntp/libopts/sort.c@1.0, 2007-05-19 00:05:08-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.59 +2 -2 + NTP_4_2_5P7 - sntp/libopts/stack.c@1.1, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/stack.c + util/ntp-keygen-opts.c@1.59 +2 -2 + NTP_4_2_5P7 - sntp/libopts/stack.c@1.0, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.59 +3 -3 + NTP_4_2_5P7 - sntp/libopts/streqvcmp.c@1.1, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/streqvcmp.c + util/ntp-keygen-opts.texi@1.57 +1 -1 + NTP_4_2_5P7 - sntp/libopts/streqvcmp.c@1.0, 2007-05-19 00:05:09-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.57 +2 -2 + NTP_4_2_5P7 - sntp/libopts/text_mmap.c@1.1, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/text_mmap.c +ChangeSet@1.1440.1.36, 2007-02-16 03:30:53-05:00, stenn@whimsy.udel.edu + [Bug 778] ntpd fails to lock with drift=+500 when started with drift=-500 - sntp/libopts/text_mmap.c@1.0, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.11 +2 -1 + [Bug 778] ntpd fails to lock with drift=+500 when started with drift=-500 - sntp/libopts/tokenize.c@1.1, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/tokenize.c +ChangeSet@1.1440.1.35, 2007-02-16 03:24:28-05:00, stenn@whimsy.udel.edu + ntp_loopfilter.c: + Avoid setting the kernel freq if kernel mode is not disabled in the + config file and either the step threshold has been set to 0 or -x + has been given. (This is Harlan's interpretation of Dave's comment + #14 to bug 778: ) + refclock_irig.c: + Change the max PLL time constant to 10 (Dave Mills) - sntp/libopts/tokenize.c@1.0, 2007-05-19 00:05:10-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_loopfilter.c@1.130 +5 -4 + Avoid setting the kernel freq if kernel mode is not disabled in the + config file and either the step threshold has been set to 0 or -x + has been given. (This is Harlan's interpretation of Dave's comment + #14 to bug 778: ) - sntp/libopts/usage.c@1.1, 2007-05-19 00:05:11-04:00, stenn@whimsy.udel.edu +740 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/usage.c + ntpd/refclock_irig.c@1.30 +1 -1 + Change the max PLL time constant to 10 (Dave Mills) - sntp/libopts/usage.c@1.0, 2007-05-19 00:05:11-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.34, 2007-02-05 08:45:44-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P6 + TAG: NTP_4_2_5P6 - sntp/libopts/version.c@1.1, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +178 -0 - BitKeeper file /deacon/backroom/ntp-stable-hms/sntp/libopts/version.c + ntpd/ntpd-opts.c@1.59 +2 -2 + NTP_4_2_5P6 - sntp/libopts/version.c@1.0, 2007-05-19 00:05:12-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.59 +3 -3 + NTP_4_2_5P6 - sntp/sntp-opts.c@1.58, 2007-05-19 02:30:55-04:00, stenn@whimsy.udel.edu +21 -12 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd-opts.texi@1.58 +1 -1 + NTP_4_2_5P6 - sntp/sntp-opts.h@1.58, 2007-05-19 02:30:56-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpd.1@1.57 +2 -2 + NTP_4_2_5P6 - sntp/sntp-opts.texi@1.55, 2007-05-19 02:30:57-04:00, stenn@whimsy.udel.edu +1 -1 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim-opts.c@1.59 +2 -2 + NTP_4_2_5P6 - sntp/sntp.1@1.58, 2007-05-19 02:30:58-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim-opts.h@1.59 +3 -3 + NTP_4_2_5P6 - util/ntp-keygen-opts.c@1.59, 2007-05-19 02:31:00-04:00, stenn@whimsy.udel.edu +23 -14 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim-opts.texi@1.57 +1 -1 + NTP_4_2_5P6 - util/ntp-keygen-opts.h@1.59, 2007-05-19 02:31:02-04:00, stenn@whimsy.udel.edu +6 -6 - We need to use the upgraded autogen/libopts in -stable too. + ntpd/ntpdsim.1@1.57 +2 -2 + NTP_4_2_5P6 - util/ntp-keygen-opts.texi@1.57, 2007-05-19 02:31:04-04:00, stenn@whimsy.udel.edu +3 -3 - We need to use the upgraded autogen/libopts in -stable too. + ntpdc/ntpdc-opts.c@1.59 +2 -2 + NTP_4_2_5P6 - util/ntp-keygen.1@1.57, 2007-05-19 02:31:04-04:00, stenn@whimsy.udel.edu +2 -2 - We need to use the upgraded autogen/libopts in -stable too. + ntpdc/ntpdc-opts.h@1.59 +3 -3 + NTP_4_2_5P6 -ChangeSet@1.1480.1.1, 2007-05-18 02:20:56-04:00, stenn@whimsy.udel.edu +3 -0 - Release 4.2.4p2 + ntpdc/ntpdc-opts.texi@1.57 +1 -1 + NTP_4_2_5P6 - ChangeLog@1.11.1.1, 2007-05-18 02:19:13-04:00, stenn@whimsy.udel.edu +4 -2 - Release 4.2.4p2 + ntpdc/ntpdc.1@1.57 +2 -2 + NTP_4_2_5P6 - NEWS@1.88, 2007-05-18 02:19:14-04:00, stenn@whimsy.udel.edu +6 -0 - Release 4.2.4p2 + ntpq/ntpq-opts.c@1.61 +2 -2 + NTP_4_2_5P6 - packageinfo.sh@1.79, 2007-05-18 02:20:38-04:00, stenn@whimsy.udel.edu +1 -1 - Release 4.2.4p2 + ntpq/ntpq-opts.h@1.61 +3 -3 + NTP_4_2_5P6 -ChangeSet@1.1482, 2007-04-28 10:19:57+00:00, kardel@pogo.udel.edu +2 -0 - ntp_peer.c: - Bug 789 (backported from ntp-dev): - Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. - ChangeLog: - Bug 789 (backported from ntp-dev): - Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. + ntpq/ntpq-opts.texi@1.58 +1 -1 + NTP_4_2_5P6 - ChangeLog@1.13, 2007-04-28 10:15:34+00:00, kardel@pogo.udel.edu +4 -1 - Bug 789: - Fix multicast client crypto authentication and make sure arriving - multicast packets do not disturb the autokey dance. + ntpq/ntpq.1@1.57 +2 -2 + NTP_4_2_5P6 - ntpd/ntp_peer.c@1.99, 2007-04-28 10:06:31+00:00, kardel@pogo.udel.edu +21 -12 - Bug 789 (backported from ntp-dev): - fix multicast client mode by re-setting - crypto information only when the local address - changes and not for BCLNTs. - Addtitionally don't update the local address while - a BCLNT is doing the autokey dance. + packageinfo.sh@1.9 +1 -1 + NTP_4_2_5P6 -ChangeSet@1.1481, 2007-04-28 10:03:26+00:00, kardel@pogo.udel.edu +3 -0 - ntp_io.c, ChangeLog: - bug 785 (backport from ntp-dev): - improve handling of multicast interfaces - (multicast routers still need to run a multicast routing software/daemon) - ntp_peer.c: - bug 785 (backport from ntp-dev): - clarify debug messages + sntp/sntp-opts.c@1.58 +2 -2 + NTP_4_2_5P6 - ChangeLog@1.12, 2007-04-28 10:00:26+00:00, kardel@pogo.udel.edu +1 -0 - bug 785 (backport from ntp-dev): - improve handling of multicast interfaces - (multicast routers still need to run a multicast routing software/daemon) + sntp/sntp-opts.h@1.58 +3 -3 + NTP_4_2_5P6 - ntpd/ntp_io.c@1.248, 2007-04-28 09:52:18+00:00, kardel@pogo.udel.edu +84 -62 - bug 785 (backport from ntp-dev): - improve handling of multicast interfaces - (multicast routers still need to run a multicast routing software/daemon) + sntp/sntp-opts.texi@1.55 +1 -1 + NTP_4_2_5P6 - ntpd/ntp_peer.c@1.98, 2007-04-28 09:53:09+00:00, kardel@pogo.udel.edu +2 -2 - bug 785 (backport from ntp-dev): - clarify debug messages + sntp/sntp.1@1.58 +2 -2 + NTP_4_2_5P6 -ChangeSet@1.1480, 2007-04-14 19:05:07-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P2_RC1 - TAG: NTP_4_2_4P2_RC1 + util/ntp-keygen-opts.c@1.58 +2 -2 + NTP_4_2_5P6 - ntpd/ntpd-opts.c@1.59, 2007-04-14 19:04:46-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + util/ntp-keygen-opts.h@1.58 +3 -3 + NTP_4_2_5P6 - ntpd/ntpd-opts.h@1.59, 2007-04-14 19:04:46-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + util/ntp-keygen-opts.texi@1.56 +1 -1 + NTP_4_2_5P6 - ntpd/ntpd-opts.texi@1.58, 2007-04-14 19:04:47-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + util/ntp-keygen.1@1.56 +2 -2 + NTP_4_2_5P6 - ntpd/ntpd.1@1.57, 2007-04-14 19:04:47-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 +ChangeSet@1.1436.1.27, 2007-02-05 06:47:44-05:00, stenn@whimsy.udel.edu + NTP_4_2_4_RC3 + TAG: NTP_4_2_4_RC3 - ntpd/ntpdsim-opts.c@1.59, 2007-04-14 19:04:48-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntpd-opts.c@1.50.1.3 +2 -2 + NTP_4_2_4_RC3 - ntpd/ntpdsim-opts.h@1.59, 2007-04-14 19:04:49-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ntpd/ntpd-opts.h@1.50.1.3 +3 -3 + NTP_4_2_4_RC3 - ntpd/ntpdsim-opts.texi@1.57, 2007-04-14 19:04:50-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpd/ntpd-opts.texi@1.49.1.3 +1 -1 + NTP_4_2_4_RC3 - ntpd/ntpdsim.1@1.57, 2007-04-14 19:04:50-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntpd.1@1.48.1.3 +2 -2 + NTP_4_2_4_RC3 - ntpdc/ntpdc-opts.c@1.59, 2007-04-14 19:04:51-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntpdsim-opts.c@1.50.1.3 +2 -2 + NTP_4_2_4_RC3 - ntpdc/ntpdc-opts.h@1.59, 2007-04-14 19:04:52-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ntpd/ntpdsim-opts.h@1.50.1.3 +3 -3 + NTP_4_2_4_RC3 - ntpdc/ntpdc-opts.texi@1.57, 2007-04-14 19:04:52-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpd/ntpdsim-opts.texi@1.48.1.3 +1 -1 + NTP_4_2_4_RC3 - ntpdc/ntpdc.1@1.57, 2007-04-14 19:04:53-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpd/ntpdsim.1@1.48.1.3 +2 -2 + NTP_4_2_4_RC3 - ntpq/ntpq-opts.c@1.61, 2007-04-14 19:04:54-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc-opts.c@1.50.1.3 +2 -2 + NTP_4_2_4_RC3 - ntpq/ntpq-opts.h@1.61, 2007-04-14 19:04:55-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc-opts.h@1.50.1.3 +3 -3 + NTP_4_2_4_RC3 - ntpq/ntpq-opts.texi@1.58, 2007-04-14 19:04:55-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc-opts.texi@1.48.1.3 +1 -1 + NTP_4_2_4_RC3 - ntpq/ntpq.1@1.57, 2007-04-14 19:04:56-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpdc/ntpdc.1@1.48.1.3 +2 -2 + NTP_4_2_4_RC3 - packageinfo.sh@1.78, 2007-04-14 19:04:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpq/ntpq-opts.c@1.52.1.3 +2 -2 + NTP_4_2_4_RC3 - sntp/sntp-opts.c@1.57, 2007-04-14 19:04:57-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + ntpq/ntpq-opts.h@1.52.1.3 +3 -3 + NTP_4_2_4_RC3 - sntp/sntp-opts.h@1.57, 2007-04-14 19:04:58-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + ntpq/ntpq-opts.texi@1.49.1.3 +1 -1 + NTP_4_2_4_RC3 - sntp/sntp-opts.texi@1.54, 2007-04-14 19:04:59-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + ntpq/ntpq.1@1.48.1.3 +2 -2 + NTP_4_2_4_RC3 - sntp/sntp.1@1.57, 2007-04-14 19:04:59-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + packageinfo.sh@1.65.4.1 +1 -1 + NTP_4_2_4_RC3 - util/ntp-keygen-opts.c@1.58, 2007-04-14 19:05:00-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + sntp/sntp-opts.c@1.49.1.3 +2 -2 + NTP_4_2_4_RC3 - util/ntp-keygen-opts.h@1.58, 2007-04-14 19:05:01-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P2_RC1 + sntp/sntp-opts.h@1.49.1.3 +3 -3 + NTP_4_2_4_RC3 - util/ntp-keygen-opts.texi@1.56, 2007-04-14 19:05:02-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P2_RC1 + sntp/sntp-opts.texi@1.46.1.3 +1 -1 + NTP_4_2_4_RC3 - util/ntp-keygen.1@1.56, 2007-04-14 19:05:03-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P2_RC1 + sntp/sntp.1@1.49.1.3 +2 -2 + NTP_4_2_4_RC3 -ChangeSet@1.1479, 2007-04-14 18:16:04-04:00, stenn@deacon.udel.edu +2 -0 - Distribute include/homerc.def + util/ntp-keygen-opts.c@1.49.1.3 +2 -2 + NTP_4_2_4_RC3 - include/Makefile.am@1.25, 2007-04-14 18:15:53-04:00, stenn@deacon.udel.edu +1 -1 - Distribute include/homerc.def + util/ntp-keygen-opts.h@1.49.1.3 +3 -3 + NTP_4_2_4_RC3 - packageinfo.sh@1.77, 2007-04-14 18:14:54-04:00, stenn@deacon.udel.edu +1 -1 - restart the RC + util/ntp-keygen-opts.texi@1.47.1.3 +1 -1 + NTP_4_2_4_RC3 -ChangeSet@1.1478, 2007-04-14 07:53:43-04:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P1_RC1 - TAG: NTP_4_2_4P1_RC1 + util/ntp-keygen.1@1.47.1.3 +2 -2 + NTP_4_2_4_RC3 - ntpd/ntpd-opts.c@1.58, 2007-04-14 07:53:21-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 +ChangeSet@1.1440.1.33, 2007-02-05 02:16:55-05:00, stenn@whimsy.udel.edu + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpd/ntpd-opts.h@1.58, 2007-04-14 07:53:21-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 + ChangeLog@1.10 +1 -1 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpd/ntpd-opts.texi@1.57, 2007-04-14 07:53:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + html/drivers/driver36.html@1.31 +36 -30 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpd/ntpd.1@1.56, 2007-04-14 07:53:23-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + html/drivers/driver6.html@1.23 +12 -24 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpd/ntpdsim-opts.c@1.58, 2007-04-14 07:53:24-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + html/drivers/driver7.html@1.25 +11 -29 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpd/ntpdsim-opts.h@1.58, 2007-04-14 07:53:25-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 + ntpd/refclock_chu.c@1.44 +39 -31 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpd/ntpdsim-opts.texi@1.56, 2007-04-14 07:53:26-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P1_RC1 + ntpd/refclock_irig.c@1.29 +195 -128 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpd/ntpdsim.1@1.56, 2007-04-14 07:53:27-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpd/refclock_wwv.c@1.70 +50 -39 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpdc/ntpdc-opts.c@1.58, 2007-04-14 07:53:28-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpd/refclock_wwvb.c@1.18 +0 -2 + More CHU, IRIG, WWV, and WWVB fixes from Dave Mills - ntpdc/ntpdc-opts.h@1.58, 2007-04-14 07:53:29-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 +ChangeSet@1.1436.1.26, 2007-02-04 23:08:28-05:00, stenn@whimsy.udel.edu + Danny forgot to pull before editing - replace the change he undid. - ntpdc/ntpdc-opts.texi@1.56, 2007-04-14 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpq/ntpq-subs.c@1.25.2.2 +3 -2 + Danny forgot to pull before editing - replace the change he undid. - ntpdc/ntpdc.1@1.56, 2007-04-14 07:53:30-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 +ChangeSet@1.1436.1.25, 2007-02-04 22:53:32-05:00, stenn@whimsy.udel.edu + [Bug 586] Avoid lookups if AI_NUMERICHOST is set. - ntpq/ntpq-opts.c@1.60, 2007-04-14 07:53:31-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ChangeLog@1.1.1.7 +1 -0 + [Bug 586] Avoid lookups if AI_NUMERICHOST is set. - ntpq/ntpq-opts.h@1.60, 2007-04-14 07:53:32-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 +ChangeSet@1.1436.1.24, 2007-02-04 21:51:15-05:00, mayer@pogo.udel.edu + Bug #586 Don't do lookups if AI_NUMERICHOST is set - ntpq/ntpq-opts.texi@1.57, 2007-04-14 07:53:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + libntp/ntp_rfc2553.c@1.36.1.1 +6 -0 + Bug #586 Don't do lookups if AI_NUMERICHOST is set - ntpq/ntpq.1@1.56, 2007-04-14 07:53:33-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 +ChangeSet@1.1436.1.23, 2007-02-04 21:44:13-05:00, mayer@pogo.udel.edu + Bug #586 Check for <4 characters for the refid first - packageinfo.sh@1.76, 2007-04-14 07:53:34-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpq/ntpq-subs.c@1.25.2.1 +9 -10 + Bug #586 Check for <4 characters for the refid first - sntp/sntp-opts.c@1.56, 2007-04-14 07:53:35-04:00, stenn@whimsy.udel.edu +8 -7 - NTP_4_2_4P1_RC1 +ChangeSet@1.1436.1.22, 2007-02-04 17:56:17+00:00, kardel@pogo.udel.edu + ntpd.c: + comment clarification about capabilities used - sntp/sntp-opts.h@1.56, 2007-04-14 07:53:35-04:00, stenn@whimsy.udel.edu +8 -14 - NTP_4_2_4P1_RC1 + ntpd/ntpd.c@1.82.2.2 +4 -7 + comment clarification about capabilities used - sntp/sntp-opts.texi@1.53, 2007-04-14 07:53:36-04:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P1_RC1 +ChangeSet@1.1436.2.1, 2007-02-04 17:47:20+00:00, kardel@pogo.udel.edu + ntpd.c: + Bug 765: + use Linux capability mechanism to allow dynamic interface tracking to continue in + unprivileged mode. - sntp/sntp.1@1.56, 2007-04-14 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpd/ntpd.c@1.82.2.1 +11 -1 + Bug 765: + use Linux capability mechanism to allow dynamic interface tracking to continue in + unprivileged mode. - util/ntp-keygen-opts.c@1.57, 2007-04-14 07:53:37-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 +ChangeSet@1.1440.1.29, 2007-01-31 06:42:22-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P5 + TAG: NTP_4_2_5P5 - util/ntp-keygen-opts.h@1.57, 2007-04-14 07:53:38-04:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P1_RC1 + ntpd/ntpd-opts.c@1.57 +2 -2 + NTP_4_2_5P5 - util/ntp-keygen-opts.texi@1.55, 2007-04-14 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpd/ntpd-opts.h@1.57 +3 -3 + NTP_4_2_5P5 - util/ntp-keygen.1@1.55, 2007-04-14 07:53:39-04:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P1_RC1 + ntpd/ntpd-opts.texi@1.56 +1 -1 + NTP_4_2_5P5 -ChangeSet@1.1477, 2007-04-14 05:13:18-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd.1@1.55 +2 -2 + NTP_4_2_5P5 - ChangeLog@1.11, 2007-04-14 05:12:51-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.c@1.57 +2 -2 + NTP_4_2_5P5 -ChangeSet@1.1476, 2007-04-14 04:47:21-04:00, stenn@whimsy.udel.edu +1 -0 - start an RC cycle + ntpd/ntpdsim-opts.h@1.57 +3 -3 + NTP_4_2_5P5 - packageinfo.sh@1.75, 2007-04-14 04:47:01-04:00, stenn@whimsy.udel.edu +2 -2 - start an RC cycle + ntpd/ntpdsim-opts.texi@1.55 +1 -1 + NTP_4_2_5P5 -ChangeSet@1.1475, 2007-04-14 02:38:03-04:00, stenn@whimsy.udel.edu +32 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim.1@1.55 +2 -2 + NTP_4_2_5P5 - clockstuff/Makefile.am@1.6, 2007-04-14 02:35:13-04:00, stenn@whimsy.udel.edu +1 -1 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.c@1.57 +2 -2 + NTP_4_2_5P5 - clockstuff/clktest-opts.def@1.5, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.h@1.57 +3 -3 + NTP_4_2_5P5 - include/copyright.def@1.4, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +0 -7 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.texi@1.55 +1 -1 + NTP_4_2_5P5 - include/homerc.def@1.1, 2007-04-14 01:19:52-04:00, stenn@whimsy.udel.edu +9 -0 - BitKeeper file /deacon/backroom/ntp-stable/include/homerc.def + ntpdc/ntpdc.1@1.55 +2 -2 + NTP_4_2_5P5 - include/homerc.def@1.0, 2007-04-14 01:19:52-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.59 +2 -2 + NTP_4_2_5P5 - ntpd/Makefile.am@1.53, 2007-04-14 02:35:14-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq-opts.h@1.59 +3 -3 + NTP_4_2_5P5 - ntpd/ntpd-opts.c@1.57, 2007-04-14 02:36:43-04:00, stenn@whimsy.udel.edu +12 -54 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq-opts.texi@1.56 +1 -1 + NTP_4_2_5P5 - ntpd/ntpd-opts.h@1.57, 2007-04-14 02:36:44-04:00, stenn@whimsy.udel.edu +8 -22 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq.1@1.55 +2 -2 + NTP_4_2_5P5 - ntpd/ntpd-opts.texi@1.56, 2007-04-14 02:36:44-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + packageinfo.sh@1.8 +1 -1 + NTP_4_2_5P5 - ntpd/ntpd.1@1.55, 2007-04-14 02:36:45-04:00, stenn@whimsy.udel.edu +3 -19 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp-opts.c@1.56 +2 -2 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.c@1.57, 2007-04-14 02:36:46-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp-opts.h@1.56 +3 -3 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.def@1.6, 2007-04-14 02:35:15-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp-opts.texi@1.53 +1 -1 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.h@1.57, 2007-04-14 02:36:46-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file + sntp/sntp.1@1.56 +2 -2 + NTP_4_2_5P5 - ntpd/ntpdsim-opts.texi@1.55, 2007-04-14 02:36:47-04:00, stenn@whimsy.udel.edu +1 -1 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen-opts.c@1.56 +2 -2 + NTP_4_2_5P5 - ntpd/ntpdsim.1@1.55, 2007-04-14 02:36:48-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen-opts.h@1.56 +3 -3 + NTP_4_2_5P5 - ntpdc/Makefile.am@1.34, 2007-04-14 02:35:15-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen-opts.texi@1.54 +1 -1 + NTP_4_2_5P5 - ntpdc/ntpdc-opts.c@1.57, 2007-04-14 02:36:48-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + util/ntp-keygen.1@1.54 +2 -2 + NTP_4_2_5P5 - ntpdc/ntpdc-opts.def@1.13, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file +ChangeSet@1.1440.1.28, 2007-01-30 19:44:35-05:00, stenn@whimsy.udel.edu + re-indent/cleanup refclock_palisade.c - ntpdc/ntpdc-opts.h@1.57, 2007-04-14 02:36:49-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file + ntpd/refclock_palisade.c@1.21 +347 -449 + re-indent refclock_palisade.c - ntpdc/ntpdc-opts.texi@1.55, 2007-04-14 02:36:50-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file +ChangeSet@1.1440.1.27, 2007-01-30 08:41:43-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P4 + TAG: NTP_4_2_5P4 - ntpdc/ntpdc.1@1.55, 2007-04-14 02:36:51-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd-opts.c@1.56 +2 -2 + NTP_4_2_5P4 - ntpq/Makefile.am@1.26, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd-opts.h@1.56 +3 -3 + NTP_4_2_5P4 - ntpq/ntpq-opts.c@1.59, 2007-04-14 02:36:52-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd-opts.texi@1.55 +1 -1 + NTP_4_2_5P4 - ntpq/ntpq-opts.def@1.12, 2007-04-14 02:35:16-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpd.1@1.54 +2 -2 + NTP_4_2_5P4 - ntpq/ntpq-opts.h@1.59, 2007-04-14 02:36:53-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.c@1.56 +2 -2 + NTP_4_2_5P4 - ntpq/ntpq-opts.texi@1.56, 2007-04-14 02:36:53-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.h@1.56 +3 -3 + NTP_4_2_5P4 - ntpq/ntpq.1@1.55, 2007-04-14 02:36:54-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim-opts.texi@1.54 +1 -1 + NTP_4_2_5P4 - util/Makefile.am@1.35, 2007-04-14 02:35:17-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpd/ntpdsim.1@1.54 +2 -2 + NTP_4_2_5P4 - util/ntp-keygen-opts.c@1.56, 2007-04-14 02:36:55-04:00, stenn@whimsy.udel.edu +7 -6 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.c@1.56 +2 -2 + NTP_4_2_5P4 - util/ntp-keygen-opts.def@1.7, 2007-04-14 02:35:18-04:00, stenn@whimsy.udel.edu +1 -0 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.h@1.56 +3 -3 + NTP_4_2_5P4 - util/ntp-keygen-opts.h@1.56, 2007-04-14 02:36:55-04:00, stenn@whimsy.udel.edu +6 -12 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc-opts.texi@1.54 +1 -1 + NTP_4_2_5P4 - util/ntp-keygen-opts.texi@1.54, 2007-04-14 02:36:56-04:00, stenn@whimsy.udel.edu +3 -3 - [Bug 811] ntpd should not read a .ntprc file + ntpdc/ntpdc.1@1.54 +2 -2 + NTP_4_2_5P4 - util/ntp-keygen.1@1.54, 2007-04-14 02:36:57-04:00, stenn@whimsy.udel.edu +2 -2 - [Bug 811] ntpd should not read a .ntprc file + ntpq/ntpq-opts.c@1.58 +2 -2 + NTP_4_2_5P4 -ChangeSet@1.1474, 2007-04-14 01:11:33-04:00, stenn@whimsy.udel.edu +166 -0 - autogen/libopts upgrade + ntpq/ntpq-opts.h@1.58 +3 -3 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.lgpl@1.3, 2007-04-13 18:58:46-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.lgpl + ntpq/ntpq-opts.texi@1.55 +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.lgpl~54a90ba0899593cb@1.2, 2007-04-13 19:05:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.lgpl + ntpq/ntpq.1@1.54 +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.mbsd@1.2, 2007-04-13 18:58:48-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/COPYING.mbsd + packageinfo.sh@1.7 +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-COPYING.mbsd~9b1945bb2136c70b@1.2, 2007-04-13 19:05:59-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/COPYING.mbsd + sntp/sntp-opts.c@1.55 +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-MakeDefs.inc@1.2, 2007-04-13 18:58:49-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/MakeDefs.inc + sntp/sntp-opts.h@1.55 +3 -3 + NTP_4_2_5P4 - BitKeeper/deleted/.del-MakeDefs.inc~2b8fdfc9df6d652d@1.2, 2007-04-13 19:06:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/MakeDefs.inc + sntp/sntp-opts.texi@1.52 +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-Makefile.am@1.7, 2007-04-13 18:58:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/Makefile.am + sntp/sntp.1@1.55 +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-Makefile.am~fa9bd87b6045015c@1.5, 2007-04-13 19:06:01-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/Makefile.am + util/ntp-keygen-opts.c@1.55 +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-README@1.2, 2007-04-13 18:58:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/README + util/ntp-keygen-opts.h@1.55 +3 -3 + NTP_4_2_5P4 - BitKeeper/deleted/.del-README~1ae087758ee867d4@1.2, 2007-04-13 19:06:02-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/README + util/ntp-keygen-opts.texi@1.53 +1 -1 + NTP_4_2_5P4 - BitKeeper/deleted/.del-autoopts.c@1.11, 2007-04-13 18:58:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.c + util/ntp-keygen.1@1.53 +2 -2 + NTP_4_2_5P4 - BitKeeper/deleted/.del-autoopts.c~5b417341bc85d7a8@1.8, 2007-04-13 19:06:03-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.c +ChangeSet@1.1436.1.20, 2007-01-30 06:44:11-05:00, stenn@whimsy.udel.edu + NTP_4_2_4_RC2 + TAG: NTP_4_2_4_RC2 - BitKeeper/deleted/.del-autoopts.h@1.10, 2007-04-13 18:58:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts.h + ntpd/ntpd-opts.c@1.50.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-autoopts.h~8cdce21b181a1a01@1.8, 2007-04-13 19:06:05-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts.h + ntpd/ntpd-opts.h@1.50.1.2 +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-boolean.c@1.9, 2007-04-13 18:58:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/boolean.c + ntpd/ntpd-opts.texi@1.49.1.2 +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-boolean.c~a5d10c8997e6a2e2@1.6, 2007-04-13 19:06:06-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/boolean.c + ntpd/ntpd.1@1.48.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-compat.h@1.13, 2007-04-13 19:04:47-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/compat.h + ntpd/ntpdsim-opts.c@1.50.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-compat.h~9682d0ac273ae32@1.9, 2007-04-13 19:06:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/compat.h + ntpd/ntpdsim-opts.h@1.50.1.2 +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-configfile.c@1.11, 2007-04-13 18:58:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/configfile.c + ntpd/ntpdsim-opts.texi@1.48.1.2 +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-configfile.c~8194f784686fa804@1.8, 2007-04-13 19:06:07-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/configfile.c + ntpd/ntpdsim.1@1.48.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-cook.c@1.10, 2007-04-13 18:58:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/cook.c + ntpdc/ntpdc-opts.c@1.50.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-cook.c~e48d079a438432dc@1.7, 2007-04-13 19:06:08-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/cook.c + ntpdc/ntpdc-opts.h@1.50.1.2 +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-enumeration.c@1.10, 2007-04-13 18:58:59-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/enumeration.c + ntpdc/ntpdc-opts.texi@1.48.1.2 +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-enumeration.c~5f4e6af2706370ae@1.7, 2007-04-13 19:06:10-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/enumeration.c + ntpdc/ntpdc.1@1.48.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-environment.c@1.9, 2007-04-13 18:59:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/environment.c + ntpq/ntpq-opts.c@1.52.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-environment.c~2bae2966695067c2@1.6, 2007-04-13 19:06:11-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/environment.c + ntpq/ntpq-opts.h@1.52.1.2 +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.c@1.10, 2007-04-13 18:59:01-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.c + ntpq/ntpq-opts.texi@1.49.1.2 +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.c~1fd152b2b52bdab@1.7, 2007-04-13 19:06:12-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.c + ntpq/ntpq.1@1.48.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.h@1.10, 2007-04-13 18:59:02-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/genshell.h + packageinfo.sh@1.65.3.1 +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-genshell.h~375f0fa5b925f454@1.7, 2007-04-13 19:06:14-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/genshell.h + sntp/sntp-opts.c@1.49.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.c@1.4, 2007-04-13 18:59:04-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/libopts.c + sntp/sntp-opts.h@1.49.1.2 +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.c~58b8fbed850e6d5e@1.4, 2007-04-13 19:06:15-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/libopts.c + sntp/sntp-opts.texi@1.46.1.2 +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.m4@1.15, 2007-04-13 19:04:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/libopts.m4 + sntp/sntp.1@1.49.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libopts.m4~9e0f33f57d3a0a9@1.12, 2007-04-13 19:06:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/libopts.m4 + util/ntp-keygen-opts.c@1.49.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-liboptschk.m4@1.4, 2007-04-13 19:04:55-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/liboptschk.m4 + util/ntp-keygen-opts.h@1.49.1.2 +3 -3 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-liboptschk.m4~bbeebebe76865058@1.4, 2007-04-13 19:06:58-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/liboptschk.m4 + util/ntp-keygen-opts.texi@1.47.1.2 +1 -1 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libtool.m4@1.2, 2007-04-13 19:04:57-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/m4/libtool.m4 + util/ntp-keygen.1@1.47.1.2 +2 -2 + NTP_4_2_4_RC2 - BitKeeper/deleted/.del-libtool.m4~db8acbd0fb34597f@1.2, 2007-04-13 19:07:00-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/m4/libtool.m4 +ChangeSet@1.1440.1.26, 2007-01-30 01:09:52-05:00, stenn@whimsy.udel.edu + Lose K&R prototype macro - BitKeeper/deleted/.del-load.c@1.11, 2007-04-13 18:59:05-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/load.c + libntp/ntp_rfc2553.c@1.37 +2 -2 + Lose K&R prototype macro - BitKeeper/deleted/.del-load.c~59960aa12bb95bf7@1.8, 2007-04-13 19:06:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/load.c +ChangeSet@1.1436.1.19, 2007-01-29 21:20:08-05:00, stenn@whimsy.udel.edu + [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). - BitKeeper/deleted/.del-makeshell.c@1.12, 2007-04-13 18:59:06-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/makeshell.c + ChangeLog@1.1.1.6 +1 -0 + [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). - BitKeeper/deleted/.del-makeshell.c~4fcd12fc31c0a4a4@1.9, 2007-04-13 19:06:18-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/makeshell.c + util/ntp-keygen.c@1.37.1.1 +3 -3 + [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). - BitKeeper/deleted/.del-nested.c@1.10, 2007-04-13 18:59:07-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/nested.c +ChangeSet@1.1436.1.18, 2007-01-29 17:43:41-05:00, stenn@whimsy.udel.edu + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-nested.c~85346d5d12098689@1.7, 2007-04-13 19:06:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/nested.c + scripts/genCommitLog@1.4 +2 -2 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-numeric.c@1.10, 2007-04-13 18:59:08-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/numeric.c +ChangeSet@1.1436.1.17, 2007-01-29 16:52:38-05:00, stenn@whimsy.udel.edu + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-numeric.c~cdb7deb5cf6f27c2@1.7, 2007-04-13 19:06:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/numeric.c + Makefile.am@1.70.1.2 +5 -5 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-options.h@1.11, 2007-04-13 19:04:44-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/options.h + scripts/Makefile.am@1.15 +1 -1 + More ChangeLog -> CommitLog fixes - BitKeeper/deleted/.del-options.h~6eb465cb95a56bee@1.8, 2007-04-13 19:06:45-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/options.h + scripts/genCommitLog@1.3 +0 -0 + Rename: scripts/genChangeLog -> scripts/genCommitLog - BitKeeper/deleted/.del-pathfind.c@1.10, 2007-04-13 19:04:49-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/pathfind.c +ChangeSet@1.1436.1.16, 2007-01-28 23:24:05-05:00, stenn@whimsy.udel.edu + Entries for bugs 765 and 768 - BitKeeper/deleted/.del-pathfind.c~a0863179d884d4a4@1.7, 2007-04-13 19:06:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/pathfind.c + ChangeLog@1.1.1.5 +2 -0 + Entries for bugs 765 and 768 - BitKeeper/deleted/.del-pgusage.c@1.10, 2007-04-13 18:59:09-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/pgusage.c +ChangeSet@1.1436.1.15, 2007-01-27 08:54:51+00:00, kardel@pogo.udel.edu + ntp_io.c: + fix misleading error message when calling io_setbclient() and + broadcast sockets are already open and not new sockets need to + be opened. + Bug 768: fix binding for broadcast client mode (Ulrich Weber) - BitKeeper/deleted/.del-pgusage.c~d981c42eb301cfdd@1.6, 2007-04-13 19:06:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/pgusage.c + ntpd/ntp_io.c@1.244.2.3 +6 -3 + fix misleading error message when calling io_setbclient() and + broadcast sockets are already open and not new sockets need to + be opened. - BitKeeper/deleted/.del-proto.h@1.12, 2007-04-13 18:59:11-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/proto.h + ntpd/ntp_io.c@1.244.2.2 +2 -2 + Bug 768: fix binding for broadcast client mode (Ulrich Weber) - BitKeeper/deleted/.del-proto.h~fa076f6dd9d0667e@1.9, 2007-04-13 19:06:23-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/proto.h +ChangeSet@1.1440.1.22, 2007-01-25 19:55:47-05:00, stenn@whimsy.udel.edu + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-putshell.c@1.11, 2007-04-13 18:59:12-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/putshell.c + libntp/audio.c@1.26 +6 -3 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-putshell.c~24959f5e1ba688e6@1.8, 2007-04-13 19:06:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/putshell.c + ntpd/refclock_chu.c@1.43 +25 -22 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-restore.c@1.10, 2007-04-13 18:59:13-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/restore.c + ntpd/refclock_irig.c@1.28 +113 -117 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-restore.c~eada4acbf21cd8bf@1.6, 2007-04-13 19:06:26-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/restore.c + ntpd/refclock_wwv.c@1.69 +26 -28 + CHU, IRIG, and WWV improvements from Dave Mills - BitKeeper/deleted/.del-save.c@1.11, 2007-04-13 18:59:15-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/save.c +ChangeSet@1.1440.1.21, 2007-01-25 18:30:28-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P3 + TAG: NTP_4_2_5P3 - BitKeeper/deleted/.del-save.c~a29f5bd429a568bb@1.8, 2007-04-13 19:06:27-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/save.c + ntpd/ntpd-opts.c@1.55 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-snprintf.c@1.5, 2007-04-13 19:04:50-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/snprintf.c + ntpd/ntpd-opts.h@1.55 +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-snprintf.c~66578c716014cd3d@1.4, 2007-04-13 19:06:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/snprintf.c + ntpd/ntpd-opts.texi@1.54 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-sort.c@1.9, 2007-04-13 18:59:16-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/sort.c + ntpd/ntpd.1@1.53 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-sort.c~bec5a7fb6a01a5dc@1.5, 2007-04-13 19:06:28-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/sort.c + ntpd/ntpdsim-opts.c@1.55 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-stack.c@1.11, 2007-04-13 18:59:17-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/stack.c + ntpd/ntpdsim-opts.h@1.55 +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-stack.c~e817b57b18b315c1@1.8, 2007-04-13 19:06:29-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/stack.c + ntpd/ntpdsim-opts.texi@1.53 +1 -1 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strchr.c@1.4, 2007-04-13 19:04:51-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strchr.c + ntpd/ntpdsim.1@1.53 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strchr.c~80e88afbe7e2209a@1.4, 2007-04-13 19:06:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strchr.c + ntpdc/ntpdc-opts.c@1.55 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strdup.c@1.4, 2007-04-13 19:04:52-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/strdup.c + ntpdc/ntpdc-opts.h@1.55 +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-strdup.c~1f262be5e55c3c4a@1.3, 2007-04-13 19:06:54-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/strdup.c + ntpdc/ntpdc-opts.texi@1.53 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-streqvcmp.c@1.10, 2007-04-13 18:59:19-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/streqvcmp.c + ntpdc/ntpdc.1@1.53 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-streqvcmp.c~66420c6082b06827@1.7, 2007-04-13 19:06:31-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/streqvcmp.c + ntpq/ntpq-opts.c@1.57 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-text_mmap.c@1.9, 2007-04-13 18:59:20-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/text_mmap.c + ntpq/ntpq-opts.h@1.57 +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-text_mmap.c~f1915a52b87816ba@1.6, 2007-04-13 19:06:32-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/text_mmap.c + ntpq/ntpq-opts.texi@1.54 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-tokenize.c@1.6, 2007-04-13 18:59:21-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/tokenize.c + ntpq/ntpq.1@1.53 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-tokenize.c~ae2f23dbb2bee589@1.5, 2007-04-13 19:06:33-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/tokenize.c + packageinfo.sh@1.6 +1 -1 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage-txt.h@1.10, 2007-04-13 19:04:46-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/autoopts/usage-txt.h + sntp/sntp-opts.c@1.54 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage-txt.h~6ce4dce87430d1b@1.7, 2007-04-13 19:06:47-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/autoopts/usage-txt.h + sntp/sntp-opts.h@1.54 +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage.c@1.10, 2007-04-13 18:59:22-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/usage.c + sntp/sntp-opts.texi@1.51 +1 -1 + NTP_4_2_5P3 - BitKeeper/deleted/.del-usage.c~c868ef1e661a6eb1@1.8, 2007-04-13 19:06:34-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/usage.c + sntp/sntp.1@1.54 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-version.c@1.10, 2007-04-13 18:59:24-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/version.c + util/ntp-keygen-opts.c@1.54 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-version.c~a426e6b58b20d06@1.7, 2007-04-13 19:06:35-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/version.c + util/ntp-keygen-opts.h@1.54 +3 -3 + NTP_4_2_5P3 - BitKeeper/deleted/.del-windows-config.h@1.6, 2007-04-13 19:04:53-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: libopts/compat/windows-config.h + util/ntp-keygen-opts.texi@1.52 +2 -2 + NTP_4_2_5P3 - BitKeeper/deleted/.del-windows-config.h~36f7ad2ccf764ad2@1.4, 2007-04-13 19:06:56-04:00, stenn@whimsy.udel.edu +0 -0 - Delete: sntp/libopts/compat/windows-config.h + util/ntp-keygen.1@1.52 +2 -2 + NTP_4_2_5P3 - libopts/COPYING.lgpl@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.lgpl +ChangeSet@1.1440.1.20, 2007-01-23 06:44:39-05:00, stenn@whimsy.udel.edu + [Bug 592] Trimble Thunderbolt GPS support. - libopts/COPYING.lgpl@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ChangeLog@1.6 +1 -0 + [Bug 592] Trimble Thunderbolt GPS support. - libopts/COPYING.mbsd@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/COPYING.mbsd +ChangeSet@1.1436.1.14, 2007-01-23 04:47:08-05:00, stenn@whimsy.udel.edu + NTP_4_2_4_RC1 + TAG: NTP_4_2_4_RC1 - libopts/COPYING.mbsd@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.50.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/MakeDefs.inc@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/MakeDefs.inc + ntpd/ntpd-opts.h@1.50.1.1 +3 -3 + NTP_4_2_4_RC1 - libopts/MakeDefs.inc@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.49.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/Makefile.am@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/Makefile.am + ntpd/ntpd.1@1.48.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/Makefile.am@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.50.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/README@1.1, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/README + ntpd/ntpdsim-opts.h@1.50.1.1 +3 -3 + NTP_4_2_4_RC1 - libopts/README@1.0, 2007-04-13 19:10:05-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.48.1.1 +1 -1 + NTP_4_2_4_RC1 - libopts/autoopts.c@1.1, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +1101 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.c + ntpd/ntpdsim.1@1.48.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts.c@1.0, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.50.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts.h@1.1, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +377 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts.h + ntpdc/ntpdc-opts.h@1.50.1.1 +3 -3 + NTP_4_2_4_RC1 - libopts/autoopts.h@1.0, 2007-04-13 19:10:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.48.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts/options.h@1.1, 2007-04-13 19:10:30-04:00, stenn@whimsy.udel.edu +964 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/options.h + ntpdc/ntpdc.1@1.48.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts/options.h@1.0, 2007-04-13 19:10:30-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.52.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/autoopts/usage-txt.h@1.1, 2007-04-13 19:10:31-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/autoopts/usage-txt.h + ntpq/ntpq-opts.h@1.52.1.1 +3 -3 + NTP_4_2_4_RC1 - libopts/autoopts/usage-txt.h@1.0, 2007-04-13 19:10:31-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.49.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/boolean.c@1.1, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/boolean.c + ntpq/ntpq.1@1.48.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/boolean.c@1.0, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.65.2.1 +3 -3 + NTP_4_2_4_RC1 - libopts/compat/compat.h@1.1, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +314 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/compat.h + sntp/sntp-opts.c@1.49.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/compat/compat.h@1.0, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.49.1.1 +3 -3 + NTP_4_2_4_RC1 - libopts/compat/pathfind.c@1.1, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/pathfind.c + sntp/sntp-opts.texi@1.46.1.1 +1 -1 + NTP_4_2_4_RC1 - libopts/compat/pathfind.c@1.0, 2007-04-13 19:10:38-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.49.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/compat/snprintf.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/snprintf.c + util/ntp-keygen-opts.c@1.49.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/compat/snprintf.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.49.1.1 +3 -3 + NTP_4_2_4_RC1 - libopts/compat/strchr.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strchr.c + util/ntp-keygen-opts.texi@1.47.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/compat/strchr.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.47.1.1 +2 -2 + NTP_4_2_4_RC1 - libopts/compat/strdup.c@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/strdup.c +ChangeSet@1.1440.1.18, 2007-01-22 01:53:23-05:00, fernandoph@pogo.udel.edu + thunderbolt.jpg: + BitKeeper file /pogo/users/fernandoph/ntp-dev-592/html/pic/thunderbolt.jpg - libopts/compat/strdup.c@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/thunderbolt.jpg@1.1 +862 -0 + BitKeeper file /pogo/users/fernandoph/ntp-dev-592/html/pic/thunderbolt.jpg - libopts/compat/windows-config.h@1.1, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +129 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/compat/windows-config.h + html/pic/thunderbolt.jpg@1.0 +0 -0 - libopts/compat/windows-config.h@1.0, 2007-04-13 19:10:39-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.17, 2007-01-22 01:28:51-05:00, fernandoph@pogo.udel.edu + refclock_palisade.c, driver29.html, refclock_palisade.h: + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/configfile.c@1.1, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +1288 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/configfile.c + html/drivers/driver29.html@1.15 +319 -5 + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/configfile.c@1.0, 2007-04-13 19:10:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/refclock_palisade.c@1.20 +325 -9 + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/cook.c@1.1, 2007-04-13 19:10:08-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/cook.c + ntpd/refclock_palisade.h@1.10 +29 -0 + [BUG 592] Added support for Thunderbolt Receiver (mode 2). - libopts/cook.c@1.0, 2007-04-13 19:10:08-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.13, 2007-01-21 12:44:07-05:00, stenn@whimsy.udel.edu + Danny fixed bug 360 in 4.2.2 - libopts/enumeration.c@1.1, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/enumeration.c + ChangeLog@1.1.1.4 +1 -0 + Danny fixed bug 360 in 4.2.2 - libopts/enumeration.c@1.0, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.12, 2007-01-21 12:40:23-05:00, stenn@whimsy.udel.edu + Danny fixed bug 239 in 4.2.2 - libopts/environment.c@1.1, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +260 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/environment.c + ChangeLog@1.1.1.3 +2 -0 + Danny fixed bug 239 in 4.2.2 - libopts/environment.c@1.0, 2007-04-13 19:10:09-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.11, 2007-01-21 12:33:46-05:00, stenn@pogo.udel.edu + Added bug 760 description to the ChangeLog - libopts/genshell.c@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +345 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.c + ChangeLog@1.1.1.2 +1 -0 + Added bug 760 description to the ChangeLog - libopts/genshell.c@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.10, 2007-01-21 12:28:04-05:00, stenn@pogo.udel.edu + Update the ChangeLog - libopts/genshell.h@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/genshell.h + ChangeLog@1.1.1.1 +3 -0 + Update the ChangeLog - libopts/genshell.h@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.15, 2007-01-21 02:51:30-05:00, stenn@whimsy.udel.edu + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/libopts.c@1.1, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/libopts.c + ChangeLog@1.4 +1 -0 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/libopts.c@1.0, 2007-04-13 19:10:10-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver36.html@1.30 +35 -46 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/load.c@1.1, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/load.c + html/drivers/driver6.html@1.22 +18 -18 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/load.c@1.0, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver7.html@1.24 +78 -141 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/m4/libopts.m4@1.1, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +489 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/libopts.m4 + ntpd/refclock_chu.c@1.42 +168 -225 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/m4/libopts.m4@1.0, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/refclock_irig.c@1.27 +90 -146 + CHU, IRIG, and WWV refclock improvements from Dave Mills. - libopts/m4/liboptschk.m4@1.1, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/m4/liboptschk.m4 +ChangeSet@1.1436.1.9, 2007-01-21 07:49:58+00:00, kardel@pogo.udel.edu + ntp_io.c: + pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) - libopts/m4/liboptschk.m4@1.0, 2007-04-13 19:10:43-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_io.c@1.244.2.1 +1 -1 + pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) - libopts/makeshell.c@1.1, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/makeshell.c +ChangeSet@1.1436.1.8, 2007-01-20 14:38:38+00:00, kardel@pogo.udel.edu + confopt.html: + move description for "dynamic" keyword into the right section - libopts/makeshell.c@1.0, 2007-04-13 19:10:11-04:00, stenn@whimsy.udel.edu +0 -0 + html/confopt.html@1.35 +4 -3 + move description for "dynamic" keyword into the right section - libopts/nested.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/nested.c +ChangeSet@1.1440.1.14, 2007-01-16 03:45:54-05:00, stenn@pogo.udel.edu + AC_PROG_CC_C_O -> AM_PROG_CC_C_O for automake upgrade - libopts/nested.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + configure.ac@1.404 +1 -1 + AC_PROG_CC_C_O -> AM_PROG_CC_C_O for automake upgrade - libopts/numeric.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/numeric.c +ChangeSet@1.1447.1.1, 2007-01-16 02:20:41-05:00, skamboj@ferrari.local + ntp_control.c: + Added configure prototype + ntp_control.h: + Added opcode for configure. + rsa_md5.h: + Removed double bracket - libopts/numeric.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntp_control.h@1.30 +1 -0 + Added opcode for configure. - libopts/pgusage.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/pgusage.c + include/rsa_md5.h@1.5.1.1 +3 -3 + Removed double bracket - libopts/pgusage.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_control.c@1.88.1.2 +1 -0 + Added configure prototype - libopts/proto.h@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/proto.h +ChangeSet@1.1442.1.1, 2007-01-16 00:27:25-05:00, skamboj@ferrari.local + This changeset should now contain the remainder of the changes needed to incorporate the change in the configuration and simulator code. - libopts/proto.h@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntp_config.h@1.42 +138 -164 + Updated ntp_config.c to use a phrase structure grammar - libopts/putshell.c@1.1, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/putshell.c + include/ntpsim.h@1.5.1.1 +112 -61 + Replaced the simulator code to allow the use of multiple servers - libopts/putshell.c@1.0, 2007-04-13 19:10:12-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/systime.c@1.39 +3 -177 + Removed the code needed by the simulator and added it to ntpsim.c, where IMHO, it rightfully belonged. - libopts/restore.c@1.1, 2007-04-13 19:10:13-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/restore.c + ntpd/cmd_args.c@1.45.1.1 +5 -28 + Removed command line arguments from the simulator code - libopts/restore.c@1.0, 2007-04-13 19:10:13-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_config.c@1.142.1.1 +1821 -1835 + Updated ntp_config.c to use a phrase structure grammar - libopts/save.c@1.1, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/save.c + ntpd/ntp_control.c@1.87.1.1 +54 -0 + Added a configure option to allow remote configuration of NTP through the use of ntpq - libopts/save.c@1.0, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_io.c@1.244.1.1 +1 -1 + Changed the line of code that sent a packet to the simulator. - libopts/sort.c@1.1, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/sort.c + ntpd/ntpsim.c@1.13.1.1 +573 -322 + Replaced the simulator code to allow the use of multiple servers - libopts/sort.c@1.0, 2007-04-13 19:10:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-subs.c@1.25.1.1 +90 -0 + Added a configure option to allow remote configuration of NTP through the use of ntpq - libopts/stack.c@1.1, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/stack.c + ntpq/ntpq.c@1.65.1.1 +20 -3 + Modified tokenize to allow the use of a quoted string. Needed by the new configure command. - libopts/stack.c@1.0, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.7, 2007-01-14 08:46:00+00:00, kardel@pogo.udel.edu + parse.h: + Bug 753: make union timestamp anonymous (Philip Prindeville) + now there are OSes that claim that name in netinet/ip.h... - libopts/streqvcmp.c@1.1, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/streqvcmp.c + include/parse.h@1.7.1.1 +8 -4 + Bug 753: make union timestamp anonymous (Philip Prindeville) + now there are OSes that claim that name in netinet/ip.h... - libopts/streqvcmp.c@1.0, 2007-04-13 19:10:15-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.6, 2007-01-13 11:36:29+00:00, kardel@pogo.udel.edu + ntp_intres.c: + support dynamic keyword - libopts/text_mmap.c@1.1, 2007-04-13 19:10:16-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/text_mmap.c + ntpd/ntp_intres.c@1.48.1.1 +3 -1 + support dynamic keyword - libopts/text_mmap.c@1.0, 2007-04-13 19:10:16-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.13, 2007-01-08 06:01:47-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P2 + TAG: NTP_4_2_5P2 - libopts/tokenize.c@1.1, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/tokenize.c + ntpd/ntpd-opts.c@1.53 +2 -2 + NTP_4_2_5P2 - libopts/tokenize.c@1.0, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.53 +3 -3 + NTP_4_2_5P2 - libopts/usage.c@1.1, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +731 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/usage.c + ntpd/ntpd-opts.texi@1.52 +1 -1 + NTP_4_2_5P2 - libopts/usage.c@1.0, 2007-04-13 19:10:17-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.1@1.51 +2 -2 + NTP_4_2_5P2 - libopts/version.c@1.1, 2007-04-13 19:10:18-04:00, stenn@whimsy.udel.edu +176 -0 - BitKeeper file /deacon/backroom/ntp-stable/libopts/version.c + ntpd/ntpdsim-opts.c@1.53 +2 -2 + NTP_4_2_5P2 - libopts/version.c@1.0, 2007-04-13 19:10:18-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.h@1.53 +3 -3 + NTP_4_2_5P2 - sntp/libopts/COPYING.lgpl@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +502 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.lgpl + ntpd/ntpdsim-opts.texi@1.51 +1 -1 + NTP_4_2_5P2 - sntp/libopts/COPYING.lgpl@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim.1@1.51 +2 -2 + NTP_4_2_5P2 - sntp/libopts/COPYING.mbsd@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +26 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/COPYING.mbsd + ntpdc/ntpdc-opts.c@1.53 +2 -2 + NTP_4_2_5P2 - sntp/libopts/COPYING.mbsd@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.h@1.53 +3 -3 + NTP_4_2_5P2 - sntp/libopts/MakeDefs.inc@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/MakeDefs.inc + ntpdc/ntpdc-opts.texi@1.51 +1 -1 + NTP_4_2_5P2 - sntp/libopts/MakeDefs.inc@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.1@1.51 +2 -2 + NTP_4_2_5P2 - sntp/libopts/Makefile.am@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +24 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/Makefile.am + ntpq/ntpq-opts.c@1.55 +2 -2 + NTP_4_2_5P2 - sntp/libopts/Makefile.am@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.h@1.55 +3 -3 + NTP_4_2_5P2 - sntp/libopts/README@1.1, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/README + ntpq/ntpq-opts.texi@1.52 +1 -1 + NTP_4_2_5P2 - sntp/libopts/README@1.0, 2007-04-13 19:09:03-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.1@1.51 +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +1101 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.c + packageinfo.sh@1.5 +1 -1 + NTP_4_2_5P2 - sntp/libopts/autoopts.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.52 +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts.h@1.1, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +377 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts.h + sntp/sntp-opts.h@1.52 +3 -3 + NTP_4_2_5P2 - sntp/libopts/autoopts.h@1.0, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.texi@1.49 +1 -1 + NTP_4_2_5P2 - sntp/libopts/autoopts/options.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +964 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/options.h + sntp/sntp.1@1.52 +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts/options.h@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.52 +2 -2 + NTP_4_2_5P2 - sntp/libopts/autoopts/usage-txt.h@1.1, 2007-04-13 19:08:49-04:00, stenn@whimsy.udel.edu +355 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/autoopts/usage-txt.h + util/ntp-keygen-opts.h@1.52 +3 -3 + NTP_4_2_5P2 - sntp/libopts/autoopts/usage-txt.h@1.0, 2007-04-13 19:08:49-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.50 +1 -1 + NTP_4_2_5P2 - sntp/libopts/boolean.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +106 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/boolean.c + util/ntp-keygen.1@1.50 +2 -2 + NTP_4_2_5P2 - sntp/libopts/boolean.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1436.1.5, 2007-01-06 18:24:18-05:00, stenn@whimsy.udel.edu + Updated copyright year - sntp/libopts/compat/compat.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +314 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/compat.h + html/copyright.html@1.36 +2 -2 + Updated copyright year - sntp/libopts/compat/compat.h@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.11, 2007-01-06 16:09:45-05:00, stenn@whimsy.udel.edu + Documentation updates - sntp/libopts/compat/pathfind.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +339 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/pathfind.c + html/audio.html@1.18 +32 -24 + Documentation updates - sntp/libopts/compat/pathfind.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver36.html@1.29 +20 -14 + Documentation updates - sntp/libopts/compat/snprintf.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/snprintf.c + html/drivers/driver6.html@1.21 +6 -9 + Documentation updates - sntp/libopts/compat/snprintf.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver7.html@1.23 +19 -31 + Documentation updates - sntp/libopts/compat/strchr.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +60 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strchr.c + html/pic/description.jpg@1.1 +761 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/description.jpg - sntp/libopts/compat/strchr.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/description.jpg@1.0 +0 -0 - sntp/libopts/compat/strdup.c@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +19 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/strdup.c + html/pic/freq1211.gif@1.1 +255 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/freq1211.gif - sntp/libopts/compat/strdup.c@1.0, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/freq1211.gif@1.0 +0 -0 - sntp/libopts/compat/windows-config.h@1.1, 2007-04-13 19:08:48-04:00, stenn@whimsy.udel.edu +129 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/compat/windows-config.h + html/pic/offset1211.gif@1.1 +568 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/offset1211.gif - sntp/libopts/compat/windows-config.h@1.0, 2007-04-13 19:08:47-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/offset1211.gif@1.0 +0 -0 - sntp/libopts/configfile.c@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +1288 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/configfile.c + html/pic/pzf509.jpg@1.1 +291 -0 + BitKeeper file /deacon/backroom/ntp-dev/html/pic/pzf509.jpg - sntp/libopts/configfile.c@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + html/pic/pzf509.jpg@1.0 +0 -0 - sntp/libopts/cook.c@1.1, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +354 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/cook.c +ChangeSet@1.1440.1.10, 2007-01-06 05:35:24-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P1 + TAG: NTP_4_2_5P1 - sntp/libopts/cook.c@1.0, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.52 +2 -2 + NTP_4_2_5P1 - sntp/libopts/enumeration.c@1.1, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +498 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/enumeration.c + ntpd/ntpd-opts.h@1.52 +3 -3 + NTP_4_2_5P1 - sntp/libopts/enumeration.c@1.0, 2007-04-13 19:08:53-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.51 +1 -1 + NTP_4_2_5P1 - sntp/libopts/environment.c@1.1, 2007-04-13 19:08:54-04:00, stenn@whimsy.udel.edu +260 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/environment.c + ntpd/ntpd.1@1.50 +2 -2 + NTP_4_2_5P1 - sntp/libopts/environment.c@1.0, 2007-04-13 19:08:54-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.52 +2 -2 + NTP_4_2_5P1 - sntp/libopts/genshell.c@1.1, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +345 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.c + ntpd/ntpdsim-opts.h@1.52 +3 -3 + NTP_4_2_5P1 - sntp/libopts/genshell.c@1.0, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.50 +1 -1 + NTP_4_2_5P1 - sntp/libopts/genshell.h@1.1, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +149 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/genshell.h + ntpd/ntpdsim.1@1.50 +2 -2 + NTP_4_2_5P1 - sntp/libopts/genshell.h@1.0, 2007-04-13 19:08:51-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.52 +2 -2 + NTP_4_2_5P1 - sntp/libopts/libopts.c@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +30 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/libopts.c + ntpdc/ntpdc-opts.h@1.52 +3 -3 + NTP_4_2_5P1 - sntp/libopts/libopts.c@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.50 +1 -1 + NTP_4_2_5P1 - sntp/libopts/load.c@1.1, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +563 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/load.c + ntpdc/ntpdc.1@1.50 +2 -2 + NTP_4_2_5P1 - sntp/libopts/load.c@1.0, 2007-04-13 19:08:55-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.54 +2 -2 + NTP_4_2_5P1 - sntp/libopts/m4/libopts.m4@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +489 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/libopts.m4 + ntpq/ntpq-opts.h@1.54 +3 -3 + NTP_4_2_5P1 - sntp/libopts/m4/libopts.m4@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.51 +1 -1 + NTP_4_2_5P1 - sntp/libopts/m4/liboptschk.m4@1.1, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +42 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/m4/liboptschk.m4 + ntpq/ntpq.1@1.50 +2 -2 + NTP_4_2_5P1 - sntp/libopts/m4/liboptschk.m4@1.0, 2007-04-13 19:08:50-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.4 +1 -1 + NTP_4_2_5P1 - sntp/libopts/makeshell.c@1.1, 2007-04-13 19:08:56-04:00, stenn@whimsy.udel.edu +1122 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/makeshell.c + sntp/sntp-opts.c@1.51 +2 -2 + NTP_4_2_5P1 - sntp/libopts/makeshell.c@1.0, 2007-04-13 19:08:56-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.51 +3 -3 + NTP_4_2_5P1 - sntp/libopts/nested.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +733 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/nested.c + sntp/sntp-opts.texi@1.48 +1 -1 + NTP_4_2_5P1 - sntp/libopts/nested.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.51 +2 -2 + NTP_4_2_5P1 - sntp/libopts/numeric.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +93 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/numeric.c + util/ntp-keygen-opts.c@1.51 +2 -2 + NTP_4_2_5P1 - sntp/libopts/numeric.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.51 +3 -3 + NTP_4_2_5P1 - sntp/libopts/pgusage.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +157 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/pgusage.c + util/ntp-keygen-opts.texi@1.49 +1 -1 + NTP_4_2_5P1 - sntp/libopts/pgusage.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.49 +2 -2 + NTP_4_2_5P1 - sntp/libopts/proto.h@1.1, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +91 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/proto.h +ChangeSet@1.1440.1.9, 2007-01-06 04:40:47-05:00, stenn@whimsy.udel.edu + refclock_chu.c changes from Dave Mills - sntp/libopts/proto.h@1.0, 2007-04-13 19:08:52-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/refclock_chu.c@1.41 +224 -142 + refclock_chu.c changes from Dave Mills - sntp/libopts/putshell.c@1.1, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +335 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/putshell.c +ChangeSet@1.1440.1.8, 2007-01-06 04:05:36-05:00, stenn@whimsy.udel.edu + [Bug 757] Lose ULONG_CONST() - sntp/libopts/putshell.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-hs_ulong_const.m4@1.3 +0 -0 + Delete: m4/hs_ulong_const.m4 - sntp/libopts/restore.c@1.1, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +250 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/restore.c + ChangeLog@1.3 +1 -0 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/restore.c@1.0, 2007-04-13 19:08:57-04:00, stenn@whimsy.udel.edu +0 -0 + configure.ac@1.403 +0 -2 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/save.c@1.1, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +512 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/save.c + libparse/gpstolfp.c@1.9 +1 -1 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/save.c@1.0, 2007-04-13 19:08:58-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntp_control.c@1.89 +2 -2 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/sort.c@1.1, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +359 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/sort.c + util/ntp-keygen.c@1.39 +1 -1 + [Bug 757] Lose ULONG_CONST() - sntp/libopts/sort.c@1.0, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +0 -0 +ChangeSet@1.1440.1.7, 2007-01-06 03:25:15-05:00, stenn@whimsy.udel.edu + [Bug 756] Require function prototypes - sntp/libopts/stack.c@1.1, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +269 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/stack.c + configure.ac@1.402 +2 -32 + [Bug 756] Require function prototypes - sntp/libopts/stack.c@1.0, 2007-04-13 19:08:59-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntp_rfc2553.h@1.29 +6 -6 + [Bug 756] Require function prototypes - sntp/libopts/streqvcmp.c@1.1, 2007-04-13 19:09:00-04:00, stenn@whimsy.udel.edu +289 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/streqvcmp.c + include/ntp_select.h@1.3 +2 -2 + [Bug 756] Require function prototypes - sntp/libopts/streqvcmp.c@1.0, 2007-04-13 19:09:00-04:00, stenn@whimsy.udel.edu +0 -0 + include/ntp_syscall.h@1.7 +1 -1 + [Bug 756] Require function prototypes - sntp/libopts/text_mmap.c@1.1, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +363 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/text_mmap.c + include/rsa_md5.h@1.6 +3 -4 + [Bug 756] Require function prototypes - sntp/libopts/text_mmap.c@1.0, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/audio.c@1.25 +2 -2 + [Bug 756] Require function prototypes - sntp/libopts/tokenize.c@1.1, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +321 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/tokenize.c + libntp/md5c.c@1.8 +5 -7 + [Bug 756] Require function prototypes - sntp/libopts/tokenize.c@1.0, 2007-04-13 19:09:01-04:00, stenn@whimsy.udel.edu +0 -0 + libntp/syssignal.c@1.9 +1 -1 + [Bug 756] Require function prototypes - sntp/libopts/usage.c@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +731 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/usage.c + libparse/clk_wharton.c@1.7 +1 -1 + [Bug 756] Require function prototypes - sntp/libopts/usage.c@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + libparse/parsestreams.c@1.7 +23 -23 + [Bug 756] Require function prototypes - sntp/libopts/version.c@1.1, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +176 -0 - BitKeeper file /deacon/backroom/ntp-stable/sntp/libopts/version.c + ntpd/refclock_ripencc.c@1.7 +21 -21 + [Bug 756] Require function prototypes - sntp/libopts/version.c@1.0, 2007-04-13 19:09:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/refclock_tpro.c@1.9 +3 -3 + [Bug 756] Require function prototypes -ChangeSet@1.1473, 2007-04-12 06:32:19-04:00, stenn@whimsy.udel.edu +1 -0 - Added ntp2 mirror + ntpd/refclock_tt560.c@1.2 +3 -3 + [Bug 756] Require function prototypes - BitKeeper/triggers/2mirrors@1.4, 2007-04-12 06:30:59-04:00, stenn@whimsy.udel.edu +1 -0 - Added ntp2 mirror + sntp/configure.ac@1.16 +1 -1 + [Bug 756] Require function prototypes -ChangeSet@1.1472, 2007-03-07 06:46:09-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P0 - TAG: NTP_4_2_4P0 + util/hist.c@1.7 +1 -1 + [Bug 756] Require function prototypes - ntpd/ntpd-opts.c@1.56, 2007-03-07 06:45:46-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + util/jitter.h@1.3 +16 -16 + [Bug 756] Require function prototypes - ntpd/ntpd-opts.h@1.56, 2007-03-07 06:45:47-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + util/tickadj.c@1.7 +4 -4 + [Bug 756] Require function prototypes - ntpd/ntpd-opts.texi@1.55, 2007-03-07 06:45:48-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 +ChangeSet@1.1440.1.6, 2007-01-05 00:41:52-05:00, stenn@whimsy.udel.edu + Add in ntp-dev updates to the new ChangeLog - ntpd/ntpd.1@1.54, 2007-03-07 06:45:48-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ChangeLog@1.2 +3 -0 + Add in ntp-dev updates to the new ChangeLog - ntpd/ntpdsim-opts.c@1.56, 2007-03-07 06:45:49-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 +ChangeSet@1.1436.1.4, 2007-01-05 00:27:33-05:00, stenn@whimsy.udel.edu + ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS - ntpd/ntpdsim-opts.h@1.56, 2007-03-07 06:45:50-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + ChangeLog@1.1 +260 -0 + BitKeeper file /deacon/backroom/ntp-stable/ChangeLog - ntpd/ntpdsim-opts.texi@1.54, 2007-03-07 06:45:51-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + ChangeLog@1.0 +0 -0 - ntpd/ntpdsim.1@1.54, 2007-03-07 06:45:51-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + CommitLog-4.1.0@1.592 +0 -0 + Rename: ChangeLog-4.1.0 -> CommitLog-4.1.0 - ntpdc/ntpdc-opts.c@1.56, 2007-03-07 06:45:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + Makefile.am@1.70.1.1 +2 -1 + ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS - ntpdc/ntpdc-opts.h@1.56, 2007-03-07 06:45:53-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + NEWS@1.86.1.1 +14 -256 + ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS - ntpdc/ntpdc-opts.texi@1.54, 2007-03-07 06:45:53-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 +ChangeSet@1.1436.1.3, 2007-01-04 23:41:02-05:00, stenn@whimsy.udel.edu + ChangeLog->CommitLog in the ignore file - ntpdc/ntpdc.1@1.54, 2007-03-07 06:45:54-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + BitKeeper/etc/ignore@1.59 +1 -2 + ChangeLog->CommitLog in the ignore file - ntpq/ntpq-opts.c@1.58, 2007-03-07 06:45:55-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 +ChangeSet@1.1436.1.2, 2007-01-04 19:31:07-05:00, stenn@whimsy.udel.edu + hostname updates for flock-build - ntpq/ntpq-opts.h@1.58, 2007-03-07 06:45:56-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + flock-build@1.39 +15 -19 + hostname updates for flock-build - ntpq/ntpq-opts.texi@1.55, 2007-03-07 06:45:57-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 +ChangeSet@1.1445, 2007-01-04 01:22:19-05:00, stenn@pogo.udel.edu + What about ntpdsim.1? - ntpq/ntpq.1@1.54, 2007-03-07 06:45:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/Makefile.am@1.55 +2 -0 + What about ntpdsim.1? - packageinfo.sh@1.74, 2007-03-07 06:45:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 +ChangeSet@1.1443, 2007-01-03 19:12:30-05:00, stenn@pogo.udel.edu + ntpdsim no longer needs special command-line options - sntp/sntp-opts.c@1.55, 2007-03-07 06:45:59-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + NEWS@1.87.1.1 +2 -0 + ntpdsim no longer needs special command-line options - sntp/sntp-opts.h@1.55, 2007-03-07 06:46:00-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 + ntpd/Makefile.am@1.52.1.1 +3 -19 + ntpdsim no longer needs special command-line options - sntp/sntp-opts.texi@1.52, 2007-03-07 06:46:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + ntpd/cmd_args.c@1.46 +2 -9 + ntpdsim no longer needs special command-line options - sntp/sntp.1@1.55, 2007-03-07 06:46:01-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/ntpd.c@1.82.1.1 +2 -7 + ntpdsim no longer needs special command-line options - util/ntp-keygen-opts.c@1.55, 2007-03-07 06:46:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/ntpsim.c@1.14 +3 -3 + ntpdsim no longer needs special command-line options - util/ntp-keygen-opts.h@1.55, 2007-03-07 06:46:03-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0 +ChangeSet@1.1440.1.1, 2007-01-03 16:46:18-05:00, stenn@whimsy.udel.edu + CHU and IRIG changes from Dave Mills - util/ntp-keygen-opts.texi@1.53, 2007-03-07 06:46:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0 + ntpd/refclock_chu.c@1.38.1.1 +163 -230 + CHU and IRIG changes from Dave Mills - util/ntp-keygen.1@1.53, 2007-03-07 06:46:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0 + ntpd/refclock_irig.c@1.24.1.1 +7 -6 + CHU and IRIG changes from Dave Mills -ChangeSet@1.1471, 2007-03-07 00:53:31-05:00, stenn@whimsy.udel.edu +1 -0 - time to release +ChangeSet@1.1439.1.1, 2007-01-03 16:41:43-05:00, stenn@pogo.udel.edu + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.73, 2007-03-07 00:53:21-05:00, stenn@whimsy.udel.edu +3 -1 - time to release + Makefile.am@1.71 +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1470, 2007-03-03 19:21:29-05:00, stenn@whimsy.udel.edu +2 -0 - [Bug 793] Update Hans Lambermont's email address in ntpsweep + NEWS@1.88 +1 -0 + [Bug 756] Require ANSI C (function prototypes) - ChangeLog@1.10, 2007-03-03 19:21:16-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 793] Update Hans Lambermont's email address in ntpsweep + adjtimed/Makefile.am@1.4 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - scripts/ntpsweep.in@1.3, 2007-03-03 19:21:17-05:00, stenn@whimsy.udel.edu +1 -2 - [Bug 793] Update Hans Lambermont's email address in ntpsweep + arlib/Makefile.am@1.3 +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1469, 2007-02-24 06:42:26-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P0_RC5 - TAG: NTP_4_2_4P0_RC5 + clockstuff/Makefile.am@1.6 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.55, 2007-02-24 06:42:04-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + configure.ac@1.401 +4 -2 + [Bug 756] Require ANSI C. For Solaris, lose -D_XOPEN_SOURCE=500 as that conflicts with recent ANSI/POSIX stuff - ntpd/ntpd-opts.h@1.55, 2007-02-24 06:42:05-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/Makefile.am@1.25 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.54, 2007-02-24 06:42:06-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/audio.h@1.7 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.53, 2007-02-24 06:42:07-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/binio.h@1.5 +8 -8 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.55, 2007-02-24 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/global.h@1.4 +0 -19 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.55, 2007-02-24 06:42:08-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/icom.h@1.5 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.53, 2007-02-24 06:42:09-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ieee754io.h@1.5 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.53, 2007-02-24 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/iosignal.h@1.3 +6 -6 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.55, 2007-02-24 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/isc/Makefile.am@1.5 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.55, 2007-02-24 06:42:11-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/l_stdlib.h@1.16 +67 -332 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.53, 2007-02-24 06:42:12-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/mbg_gps166.h@1.9 +24 -24 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.53, 2007-02-24 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp.h@1.130 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.57, 2007-02-24 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_calendar.h@1.3 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.57, 2007-02-24 06:42:14-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/ntp_cmdargs.h@1.5 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.54, 2007-02-24 06:42:15-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntp_filegen.h@1.4 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.53, 2007-02-24 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_fp.h@1.13 +17 -17 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.72, 2007-02-24 06:42:17-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntp_machine.h@1.24 +11 -23 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.54, 2007-02-24 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_random.h@1.2 +6 -6 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.54, 2007-02-24 06:42:18-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/ntp_refclock.h@1.21 +28 -28 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.texi@1.51, 2007-02-24 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntp_stdlib.h@1.25 +64 -70 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp.1@1.54, 2007-02-24 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_string.h@1.3 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.c@1.54, 2007-02-24 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntp_types.h@1.9 +0 -11 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.h@1.54, 2007-02-24 06:42:21-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC5 + include/ntp_unixtime.h@1.5 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.texi@1.52, 2007-02-24 06:42:21-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC5 + include/ntpd.h@1.99 +120 -120 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen.1@1.52, 2007-02-24 06:42:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC5 + include/ntpsim.h@1.6 +16 -16 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1468, 2007-02-24 05:07:16-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 628] Fallback to ntp discipline not working for large offsets + include/parse.h@1.8 +32 -32 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntp_loopfilter.c@1.128, 2007-02-24 05:07:04-05:00, stenn@whimsy.udel.edu +9 -24 - [Bug 628] Fallback to ntp discipline not working for large offsets + include/recvbuff.h@1.12 +13 -13 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1467, 2007-02-21 15:16:15-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 776] Remove the obsolete r: from the getopt string in ntpdate + include/trimble.h@1.5 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdate/ntpdate.c@1.61, 2007-02-21 15:16:00-05:00, stenn@whimsy.udel.edu +1 -1 - [Bug 776] Remove the obsolete r: from the getopt string in ntpdate + kernel/Makefile.am@1.3 +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1466, 2007-02-19 06:46:30-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4P0_RC4 - TAG: NTP_4_2_4P0_RC4 + kernel/sys/Makefile.am@1.4 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.54, 2007-02-19 06:46:11-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/Makefile.am@1.38 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.h@1.54, 2007-02-19 06:46:11-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libntp/authreadkeys.c@1.7 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.53, 2007-02-19 06:46:12-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/icom.c@1.11 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.52, 2007-02-19 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/iosignal.c@1.14 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.54, 2007-02-19 06:46:13-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libntp/msyslog.c@1.20 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.54, 2007-02-19 06:46:14-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libntp/ntp_random.c@1.6 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.52, 2007-02-19 06:46:15-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC4 + libntp/statestr.c@1.11 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.52, 2007-02-19 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/Makefile.am@1.9 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.54, 2007-02-19 06:46:16-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_computime.c@1.9 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.54, 2007-02-19 06:46:17-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/clk_dcf7000.c@1.9 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.52, 2007-02-19 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_hopf6021.c@1.9 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.52, 2007-02-19 06:46:18-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_meinberg.c@1.10 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.56, 2007-02-19 06:46:19-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_rawdcf.c@1.15 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.56, 2007-02-19 06:46:19-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/clk_rcc8000.c@1.9 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.53, 2007-02-19 06:46:20-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_schmid.c@1.9 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.52, 2007-02-19 06:46:21-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_trimtaip.c@1.9 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.71, 2007-02-19 06:46:22-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/clk_trimtsip.c@1.9 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.53, 2007-02-19 06:46:22-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/clk_varitext.c@1.8 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.53, 2007-02-19 06:46:23-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + libparse/data_mbg.c@1.9 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.texi@1.50, 2007-02-19 06:46:24-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4P0_RC4 + libparse/ieee754io.c@1.9 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp.1@1.53, 2007-02-19 06:46:24-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/parse.c@1.12 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.c@1.53, 2007-02-19 06:46:25-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + libparse/parsesolaris.c@1.7 +13 -13 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.h@1.53, 2007-02-19 06:46:25-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4P0_RC4 + m4/hs_ulong_const.m4@1.2 +1 -9 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.texi@1.51, 2007-02-19 06:46:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + m4/os_cflags.m4@1.3 +8 -5 + Upgraded to the latest version from am-utils - util/ntp-keygen.1@1.51, 2007-02-19 06:46:27-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4P0_RC4 + ntpd/Makefile.am@1.53 +1 -1 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1465, 2007-02-19 00:19:22-05:00, stenn@whimsy.udel.edu +1 -0 - Ready to go... + ntpd/ntp_config.c@1.143 +15 -15 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.70, 2007-02-19 00:19:05-05:00, stenn@whimsy.udel.edu +2 -2 - Ready to go... + ntpd/ntp_control.c@1.88 +31 -31 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1464, 2007-02-19 00:14:29-05:00, stenn@whimsy.udel.edu +3 -0 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_crypto.c@1.108 +25 -25 + [Bug 756] Require ANSI C (function prototypes) - ChangeLog@1.9, 2007-02-19 00:14:19-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_filegen.c@1.12 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpdate/Makefile.am@1.15, 2007-02-19 00:13:50-05:00, stenn@whimsy.udel.edu +1 -1 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_intres.c@1.49 +12 -12 + [Bug 756] Require ANSI C (function prototypes) - ntpdate/ntpdate.c@1.60, 2007-02-19 00:13:51-05:00, stenn@whimsy.udel.edu +1 -21 - [Bug 776] Remove unimplemented "rate" flag from ntpdate + ntpd/ntp_io.c@1.245 +35 -35 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1463, 2007-02-05 06:47:44-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4_RC3 - TAG: NTP_4_2_4_RC3 + ntpd/ntp_loopfilter.c@1.129 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.53, 2007-02-05 06:47:21-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/ntp_monitor.c@1.19 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.h@1.53, 2007-02-05 06:47:21-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/ntp_peer.c@1.98 +2 -2 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.52, 2007-02-05 06:47:22-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/ntp_proto.c@1.250 +8 -8 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.51, 2007-02-05 06:47:23-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/ntp_refclock.c@1.76 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.53, 2007-02-05 06:47:24-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/ntp_request.c@1.66 +50 -50 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.53, 2007-02-05 06:47:24-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/ntp_timer.c@1.34 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.51, 2007-02-05 06:47:25-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/ntpd.c@1.83 +9 -9 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.51, 2007-02-05 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_acts.c@1.29 +9 -9 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.53, 2007-02-05 06:47:26-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_arbiter.c@1.14 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.53, 2007-02-05 06:47:28-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_arc.c@1.19 +7 -7 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.51, 2007-02-05 06:47:28-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_as2201.c@1.10 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.51, 2007-02-05 06:47:29-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_atom.c@1.55 +7 -7 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.55, 2007-02-05 06:47:30-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_chronolog.c@1.7 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.55, 2007-02-05 06:47:30-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_chu.c@1.39 +17 -17 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.52, 2007-02-05 06:47:31-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_datum.c@1.10 +8 -8 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.51, 2007-02-05 06:47:32-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_dumbclock.c@1.9 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.69, 2007-02-05 06:47:33-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_fg.c@1.11 +5 -5 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.52, 2007-02-05 06:47:33-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_heath.c@1.14 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.52, 2007-02-05 06:47:34-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_hopfser.c@1.10 +5 -5 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.texi@1.49, 2007-02-05 06:47:35-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_hpgps.c@1.8 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp.1@1.52, 2007-02-05 06:47:37-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_irig.c@1.25 +8 -8 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.c@1.52, 2007-02-05 06:47:38-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_jjy.c@1.14 +10 -10 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.h@1.52, 2007-02-05 06:47:39-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC3 + ntpd/refclock_jupiter.c@1.21 +19 -19 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen-opts.texi@1.50, 2007-02-05 06:47:39-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC3 + ntpd/refclock_leitch.c@1.9 +11 -11 + [Bug 756] Require ANSI C (function prototypes) - util/ntp-keygen.1@1.50, 2007-02-05 06:47:40-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC3 + ntpd/refclock_local.c@1.16 +2 -2 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1462, 2007-02-04 23:08:28-05:00, stenn@whimsy.udel.edu +1 -0 - Danny forgot to pull before editing - replace the change he undid. + ntpd/refclock_mx4200.c@1.23 +16 -16 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-subs.c@1.27, 2007-02-04 23:08:17-05:00, stenn@whimsy.udel.edu +3 -2 - Danny forgot to pull before editing - replace the change he undid. + ntpd/refclock_neoclock4x.c@1.16 +12 -12 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1461, 2007-02-04 22:53:32-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 586] Avoid lookups if AI_NUMERICHOST is set. + ntpd/refclock_nmea.c@1.26 +10 -10 + [Bug 756] Require ANSI C (function prototypes) - ChangeLog@1.8, 2007-02-04 22:53:22-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 586] Avoid lookups if AI_NUMERICHOST is set. + ntpd/refclock_oncore.c@1.61 +48 -48 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1460, 2007-02-04 21:51:15-05:00, mayer@pogo.udel.edu +1 -0 - Bug #586 Don't do lookups if AI_NUMERICHOST is set + ntpd/refclock_palisade.c@1.19 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - libntp/ntp_rfc2553.c@1.37, 2007-02-04 21:51:01-05:00, mayer@pogo.udel.edu +6 -0 - Bug #586 Don't do lookups if AI_NUMERICHOST is set + ntpd/refclock_palisade.h@1.9 +11 -11 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1459, 2007-02-04 21:44:13-05:00, mayer@pogo.udel.edu +1 -0 - Bug #586 Check for <4 characters for the refid first + ntpd/refclock_parse.c@1.48 +67 -67 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-subs.c@1.26, 2007-02-04 21:43:38-05:00, mayer@pogo.udel.edu +9 -10 - Bug #586 Check for <4 characters for the refid first + ntpd/refclock_pcf.c@1.8 +3 -3 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1458, 2007-02-04 17:56:17+00:00, kardel@pogo.udel.edu +1 -0 - ntpd.c: - comment clarification about capabilities used + ntpd/refclock_pst.c@1.9 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.c@1.84, 2007-02-04 17:55:31+00:00, kardel@pogo.udel.edu +4 -7 - comment clarification about capabilities used + ntpd/refclock_true.c@1.10 +7 -7 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1451.1.1, 2007-02-04 17:47:20+00:00, kardel@pogo.udel.edu +1 -0 - ntpd.c: - Bug 765: - use Linux capability mechanism to allow dynamic interface tracking to continue in - unprivileged mode. + ntpd/refclock_ulink.c@1.14 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.c@1.83, 2007-02-04 17:45:55+00:00, kardel@pogo.udel.edu +11 -1 - Bug 765: - use Linux capability mechanism to allow dynamic interface tracking to continue in - unprivileged mode. + ntpd/refclock_wwv.c@1.68 +21 -21 + [Bug 756] Require ANSI C (function prototypes) -ChangeSet@1.1456, 2007-01-30 06:44:11-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4_RC2 - TAG: NTP_4_2_4_RC2 + ntpd/refclock_wwvb.c@1.17 +5 -5 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.c@1.52, 2007-01-30 06:43:46-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpd/refclock_zyfer.c@1.5 +4 -4 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.h@1.52, 2007-01-30 06:43:46-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + ntpdate/Makefile.am@1.15 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd-opts.texi@1.51, 2007-01-30 06:43:47-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpdate/ntpdate.c@1.60 +19 -19 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpd.1@1.50, 2007-01-30 06:43:48-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpdate/ntpdate.h@1.8 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.c@1.52, 2007-01-30 06:43:49-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpdc/Makefile.am@1.34 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.h@1.52, 2007-01-30 06:43:50-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + ntpdc/ntpdc.c@1.55 +30 -30 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim-opts.texi@1.50, 2007-01-30 06:43:51-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpdc/ntpdc.h@1.8 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - ntpd/ntpdsim.1@1.50, 2007-01-30 06:43:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpdc/ntpdc_ops.c@1.47 +53 -53 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.c@1.52, 2007-01-30 06:43:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpq/Makefile.am@1.26 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.h@1.52, 2007-01-30 06:43:54-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + ntpq/ntpq-subs.c@1.26 +41 -41 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc-opts.texi@1.50, 2007-01-30 06:43:55-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpq/ntpq.c@1.66 +46 -46 + [Bug 756] Require ANSI C (function prototypes) - ntpdc/ntpdc.1@1.50, 2007-01-30 06:43:55-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpq/ntpq.h@1.6 +13 -13 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.c@1.54, 2007-01-30 06:43:56-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + parseutil/Makefile.am@1.7 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.h@1.54, 2007-01-30 06:43:57-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + parseutil/dcfd.c@1.20 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq-opts.texi@1.51, 2007-01-30 06:43:57-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + util/Makefile.am@1.35 +1 -1 + [Bug 756] Require ANSI C (function prototypes) - ntpq/ntpq.1@1.50, 2007-01-30 06:43:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + util/jitter.h@1.2 +0 -11 + [Bug 756] Require ANSI C (function prototypes) - packageinfo.sh@1.68, 2007-01-30 06:43:59-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + util/ntp-keygen.c@1.38 +14 -14 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.c@1.51, 2007-01-30 06:43:59-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + util/ntptime.c@1.20 +3 -3 + [Bug 756] Require ANSI C (function prototypes) - sntp/sntp-opts.h@1.51, 2007-01-30 06:44:00-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 +ChangeSet@1.1442, 2007-01-02 23:16:36-05:00, skamboj@ferrari.local + ntp_config.y: + New BitKeeper file ``ntpd/ntp_config.y'' - sntp/sntp-opts.texi@1.48, 2007-01-30 06:44:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + ntpd/ntp_config.y@1.1 +917 -0 + New BitKeeper file ``ntpd/ntp_config.y'' - sntp/sntp.1@1.51, 2007-01-30 06:44:02-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpd/ntp_config.y@1.0 +0 -0 - util/ntp-keygen-opts.c@1.51, 2007-01-30 06:44:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 +ChangeSet@1.1441, 2007-01-02 23:14:13-05:00, skamboj@ferrari.local + Added code for: + 1. A phrase-structure grammar based NTP configuration file parser + 2. A multi-server NTP simulator - util/ntp-keygen-opts.h@1.51, 2007-01-30 06:44:03-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC2 + include/ntp_data_structures.h@1.1 +47 -0 + New BitKeeper file ``include/ntp_data_structures.h'' - util/ntp-keygen-opts.texi@1.49, 2007-01-30 06:44:04-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC2 + include/ntp_data_structures.h@1.0 +0 -0 - util/ntp-keygen.1@1.49, 2007-01-30 06:44:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC2 + ntpd/ntp_config.tab.c@1.1 +2351 -0 + New BitKeeper file ``ntpd/ntp_config.tab.c'' -ChangeSet@1.1455, 2007-01-29 21:20:08-05:00, stenn@whimsy.udel.edu +2 -0 - [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). + ntpd/ntp_config.tab.c@1.0 +0 -0 - ChangeLog@1.7, 2007-01-29 21:19:52-05:00, stenn@whimsy.udel.edu +1 -0 - [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). + ntpd/ntp_data_structures.c@1.1 +170 -0 + New BitKeeper file ``ntpd/ntp_data_structures.c'' - util/ntp-keygen.c@1.38, 2007-01-29 21:19:53-05:00, stenn@whimsy.udel.edu +3 -3 - [Bug 770] Fix numeric parameters to ntp-keygen (Alain Guibert). + ntpd/ntp_data_structures.c@1.0 +0 -0 -ChangeSet@1.1454, 2007-01-29 17:43:41-05:00, stenn@whimsy.udel.edu +1 -0 - More ChangeLog -> CommitLog fixes + ntpd/ntp_scanner.c@1.1 +638 -0 + New BitKeeper file ``ntpd/ntp_scanner.c'' - scripts/genCommitLog@1.4, 2007-01-29 17:42:48-05:00, stenn@whimsy.udel.edu +2 -2 - More ChangeLog -> CommitLog fixes + ntpd/ntp_scanner.c@1.0 +0 -0 -ChangeSet@1.1453, 2007-01-29 16:52:38-05:00, stenn@whimsy.udel.edu +3 -0 - More ChangeLog -> CommitLog fixes +ChangeSet@1.1440, 2006-12-29 06:43:02-05:00, stenn@whimsy.udel.edu + NTP_4_2_5P0 + TAG: NTP_4_2_5P0 - Makefile.am@1.72, 2007-01-29 16:52:06-05:00, stenn@whimsy.udel.edu +5 -5 - More ChangeLog -> CommitLog fixes + ntpd/ntpd-opts.c@1.49.1.2 +2 -2 + NTP_4_2_5P0 - scripts/Makefile.am@1.15, 2007-01-29 16:52:07-05:00, stenn@whimsy.udel.edu +1 -1 - More ChangeLog -> CommitLog fixes + ntpd/ntpd-opts.h@1.49.1.2 +3 -3 + NTP_4_2_5P0 - scripts/genCommitLog@1.3, 2007-01-29 16:09:19-05:00, stenn@whimsy.udel.edu +0 -0 - Rename: scripts/genChangeLog -> scripts/genCommitLog + ntpd/ntpd-opts.texi@1.48.1.2 +1 -1 + NTP_4_2_5P0 -ChangeSet@1.1452, 2007-01-28 23:24:05-05:00, stenn@whimsy.udel.edu +1 -0 - Entries for bugs 765 and 768 + ntpd/ntpd.1@1.47.1.2 +2 -2 + NTP_4_2_5P0 - ChangeLog@1.6, 2007-01-28 23:23:45-05:00, stenn@whimsy.udel.edu +2 -0 - Entries for bugs 765 and 768 + ntpd/ntpdsim-opts.c@1.49.1.2 +2 -2 + NTP_4_2_5P0 -ChangeSet@1.1451, 2007-01-27 08:54:51+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - fix misleading error message when calling io_setbclient() and - broadcast sockets are already open and not new sockets need to - be opened. - Bug 768: fix binding for broadcast client mode (Ulrich Weber) + ntpd/ntpdsim-opts.h@1.49.1.2 +3 -3 + NTP_4_2_5P0 - ntpd/ntp_io.c@1.247, 2007-01-27 08:51:50+00:00, kardel@pogo.udel.edu +6 -3 - fix misleading error message when calling io_setbclient() and - broadcast sockets are already open and not new sockets need to - be opened. + ntpd/ntpdsim-opts.texi@1.47.1.2 +1 -1 + NTP_4_2_5P0 - ntpd/ntp_io.c@1.246, 2007-01-27 08:24:25+00:00, kardel@pogo.udel.edu +2 -2 - Bug 768: fix binding for broadcast client mode (Ulrich Weber) + ntpd/ntpdsim.1@1.47.1.2 +2 -2 + NTP_4_2_5P0 -ChangeSet@1.1450, 2007-01-23 04:47:08-05:00, stenn@whimsy.udel.edu +25 -0 - NTP_4_2_4_RC1 - TAG: NTP_4_2_4_RC1 + ntpdc/ntpdc-opts.c@1.49.1.2 +2 -2 + NTP_4_2_5P0 - ntpd/ntpd-opts.c@1.51, 2007-01-23 04:46:47-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpdc/ntpdc-opts.h@1.49.1.2 +3 -3 + NTP_4_2_5P0 - ntpd/ntpd-opts.h@1.51, 2007-01-23 04:46:48-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + ntpdc/ntpdc-opts.texi@1.47.1.2 +1 -1 + NTP_4_2_5P0 - ntpd/ntpd-opts.texi@1.50, 2007-01-23 04:46:48-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpdc/ntpdc.1@1.47.1.2 +2 -2 + NTP_4_2_5P0 - ntpd/ntpd.1@1.49, 2007-01-23 04:46:49-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpq/ntpq-opts.c@1.51.1.2 +2 -2 + NTP_4_2_5P0 - ntpd/ntpdsim-opts.c@1.51, 2007-01-23 04:46:50-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpq/ntpq-opts.h@1.51.1.2 +3 -3 + NTP_4_2_5P0 - ntpd/ntpdsim-opts.h@1.51, 2007-01-23 04:46:50-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + ntpq/ntpq-opts.texi@1.48.1.2 +1 -1 + NTP_4_2_5P0 - ntpd/ntpdsim-opts.texi@1.49, 2007-01-23 04:46:52-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC1 + ntpq/ntpq.1@1.47.1.2 +2 -2 + NTP_4_2_5P0 - ntpd/ntpdsim.1@1.49, 2007-01-23 04:46:52-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + packageinfo.sh@1.3 +1 -1 + NTP_4_2_5P0 - ntpdc/ntpdc-opts.c@1.51, 2007-01-23 04:46:53-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + sntp/sntp-opts.c@1.48.1.2 +2 -2 + NTP_4_2_5P0 - ntpdc/ntpdc-opts.h@1.51, 2007-01-23 04:46:54-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + sntp/sntp-opts.h@1.48.1.2 +3 -3 + NTP_4_2_5P0 - ntpdc/ntpdc-opts.texi@1.49, 2007-01-23 04:46:54-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + sntp/sntp-opts.texi@1.45.1.2 +1 -1 + NTP_4_2_5P0 - ntpdc/ntpdc.1@1.49, 2007-01-23 04:46:55-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + sntp/sntp.1@1.48.1.2 +2 -2 + NTP_4_2_5P0 - ntpq/ntpq-opts.c@1.53, 2007-01-23 04:46:56-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + util/ntp-keygen-opts.c@1.48.1.2 +2 -2 + NTP_4_2_5P0 - ntpq/ntpq-opts.h@1.53, 2007-01-23 04:46:57-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + util/ntp-keygen-opts.h@1.48.1.2 +3 -3 + NTP_4_2_5P0 - ntpq/ntpq-opts.texi@1.50, 2007-01-23 04:46:57-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + util/ntp-keygen-opts.texi@1.46.1.2 +1 -1 + NTP_4_2_5P0 - ntpq/ntpq.1@1.49, 2007-01-23 04:46:58-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + util/ntp-keygen.1@1.46.1.2 +2 -2 + NTP_4_2_5P0 - packageinfo.sh@1.67, 2007-01-23 04:46:59-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 +ChangeSet@1.1439, 2006-12-28 22:56:08-05:00, stenn@whimsy.udel.edu + codec (audio) and ICOM changes from Dave Mills - sntp/sntp-opts.c@1.50, 2007-01-23 04:47:00-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + NEWS@1.87 +2 -0 + codec (audio) and ICOM changes from Dave Mills - sntp/sntp-opts.h@1.50, 2007-01-23 04:47:00-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + include/ntp.h@1.129 +1 -0 + codec (audio) changes from Dave Mills - sntp/sntp-opts.texi@1.47, 2007-01-23 04:47:01-05:00, stenn@whimsy.udel.edu +1 -1 - NTP_4_2_4_RC1 + include/ntp_config.h@1.41 +1 -0 + codec (audio) changes from Dave Mills - sntp/sntp.1@1.50, 2007-01-23 04:47:02-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + include/ntpd.h@1.98 +1 -0 + codec (audio) changes from Dave Mills - util/ntp-keygen-opts.c@1.50, 2007-01-23 04:47:03-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + libntp/audio.c@1.24 +2 -1 + codec (audio) and ICOM changes from Dave Mills - util/ntp-keygen-opts.h@1.50, 2007-01-23 04:47:04-05:00, stenn@whimsy.udel.edu +3 -3 - NTP_4_2_4_RC1 + libntp/icom.c@1.10 +33 -218 + codec (audio) and ICOM changes from Dave Mills - util/ntp-keygen-opts.texi@1.48, 2007-01-23 04:47:04-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpd/ntp_config.c@1.142 +4 -0 + codec (audio) and ICOM changes from Dave Mills - util/ntp-keygen.1@1.48, 2007-01-23 04:47:05-05:00, stenn@whimsy.udel.edu +2 -2 - NTP_4_2_4_RC1 + ntpd/ntp_loopfilter.c@1.128 +5 -10 + codec (audio) and ICOM changes from Dave Mills -ChangeSet@1.1449, 2007-01-21 12:44:07-05:00, stenn@whimsy.udel.edu +1 -0 - Danny fixed bug 360 in 4.2.2 + ntpd/refclock_irig.c@1.24 +1 -1 + codec (audio) and ICOM changes from Dave Mills - ChangeLog@1.5, 2007-01-21 12:43:50-05:00, stenn@whimsy.udel.edu +1 -0 - Danny fixed bug 360 in 4.2.2 + ntpd/refclock_wwv.c@1.67 +45 -54 + codec (audio) and ICOM changes from Dave Mills -ChangeSet@1.1448, 2007-01-21 12:40:23-05:00, stenn@whimsy.udel.edu +1 -0 - Danny fixed bug 239 in 4.2.2 +ChangeSet@1.1438, 2006-12-28 21:29:25-05:00, stenn@whimsy.udel.edu + NTP_4_2_5 + TAG: NTP_4_2_5 - ChangeLog@1.4, 2007-01-21 12:40:13-05:00, stenn@whimsy.udel.edu +2 -0 - Danny fixed bug 239 in 4.2.2 + ntpd/ntpd-opts.c@1.49.1.1 +2 -2 + NTP_4_2_5 -ChangeSet@1.1447, 2007-01-21 12:33:46-05:00, stenn@pogo.udel.edu +1 -0 - Added bug 760 description to the ChangeLog + ntpd/ntpd-opts.h@1.49.1.1 +3 -3 + NTP_4_2_5 - ChangeLog@1.3, 2007-01-21 12:33:38-05:00, stenn@pogo.udel.edu +1 -0 - Added bug 760 description to the ChangeLog + ntpd/ntpd-opts.texi@1.48.1.1 +1 -1 + NTP_4_2_5 -ChangeSet@1.1446, 2007-01-21 12:28:04-05:00, stenn@pogo.udel.edu +1 -0 - Update the ChangeLog + ntpd/ntpd.1@1.47.1.1 +2 -2 + NTP_4_2_5 - ChangeLog@1.2, 2007-01-21 12:27:59-05:00, stenn@pogo.udel.edu +3 -0 - Update the ChangeLog + ntpd/ntpdsim-opts.c@1.49.1.1 +2 -2 + NTP_4_2_5 -ChangeSet@1.1445, 2007-01-21 07:49:58+00:00, kardel@pogo.udel.edu +1 -0 - ntp_io.c: - pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) + ntpd/ntpdsim-opts.h@1.49.1.1 +3 -3 + NTP_4_2_5 - ntpd/ntp_io.c@1.245, 2007-01-21 07:48:16+00:00, kardel@pogo.udel.edu +1 -1 - pick the right type for the recv*() length argument (use GETSOCKNAME_SOCKLEN_TYPE config.h define) + ntpd/ntpdsim-opts.texi@1.47.1.1 +1 -1 + NTP_4_2_5 -ChangeSet@1.1444, 2007-01-20 14:38:38+00:00, kardel@pogo.udel.edu +1 -0 - confopt.html: - move description for "dynamic" keyword into the right section + ntpd/ntpdsim.1@1.47.1.1 +2 -2 + NTP_4_2_5 - html/confopt.html@1.35, 2007-01-20 14:37:48+00:00, kardel@pogo.udel.edu +4 -3 - move description for "dynamic" keyword into the right section + ntpdc/ntpdc-opts.c@1.49.1.1 +2 -2 + NTP_4_2_5 -ChangeSet@1.1443, 2007-01-14 08:46:00+00:00, kardel@pogo.udel.edu +1 -0 - parse.h: - Bug 753: make union timestamp anonymous (Philip Prindeville) - now there are OSes that claim that name in netinet/ip.h... + ntpdc/ntpdc-opts.h@1.49.1.1 +3 -3 + NTP_4_2_5 - include/parse.h@1.8, 2007-01-14 08:41:52+00:00, kardel@pogo.udel.edu +8 -4 - Bug 753: make union timestamp anonymous (Philip Prindeville) - now there are OSes that claim that name in netinet/ip.h... + ntpdc/ntpdc-opts.texi@1.47.1.1 +1 -1 + NTP_4_2_5 -ChangeSet@1.1442, 2007-01-13 11:36:29+00:00, kardel@pogo.udel.edu +1 -0 - ntp_intres.c: - support dynamic keyword + ntpdc/ntpdc.1@1.47.1.1 +2 -2 + NTP_4_2_5 - ntpd/ntp_intres.c@1.49, 2007-01-13 11:35:58+00:00, kardel@pogo.udel.edu +3 -1 - support dynamic keyword + ntpq/ntpq-opts.c@1.51.1.1 +2 -2 + NTP_4_2_5 -ChangeSet@1.1441, 2007-01-06 18:24:18-05:00, stenn@whimsy.udel.edu +1 -0 - Updated copyright year + ntpq/ntpq-opts.h@1.51.1.1 +3 -3 + NTP_4_2_5 - html/copyright.html@1.36, 2007-01-06 18:23:45-05:00, stenn@whimsy.udel.edu +2 -2 - Updated copyright year + ntpq/ntpq-opts.texi@1.48.1.1 +1 -1 + NTP_4_2_5 -ChangeSet@1.1440, 2007-01-05 00:27:33-05:00, stenn@whimsy.udel.edu +4 -0 - ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS + ntpq/ntpq.1@1.47.1.1 +2 -2 + NTP_4_2_5 - ChangeLog@1.1, 2007-01-05 00:06:33-05:00, stenn@whimsy.udel.edu +260 -0 - BitKeeper file /deacon/backroom/ntp-stable/ChangeLog + packageinfo.sh@1.2 +1 -1 + NTP_4_2_5 - ChangeLog@1.0, 2007-01-05 00:06:33-05:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.48.1.1 +2 -2 + NTP_4_2_5 - CommitLog-4.1.0@1.592, 2007-01-05 00:05:52-05:00, stenn@whimsy.udel.edu +0 -0 - Rename: ChangeLog-4.1.0 -> CommitLog-4.1.0 + sntp/sntp-opts.h@1.48.1.1 +3 -3 + NTP_4_2_5 - Makefile.am@1.71, 2007-01-05 00:27:13-05:00, stenn@whimsy.udel.edu +2 -1 - ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS + sntp/sntp-opts.texi@1.45.1.1 +1 -1 + NTP_4_2_5 - NEWS@1.87, 2007-01-05 00:27:14-05:00, stenn@whimsy.udel.edu +14 -256 - ChangeLog->CommitLog, NEWS->ChangeLog, Release Info->NEWS + sntp/sntp.1@1.48.1.1 +2 -2 + NTP_4_2_5 -ChangeSet@1.1439, 2007-01-04 23:41:02-05:00, stenn@whimsy.udel.edu +1 -0 - ChangeLog->CommitLog in the ignore file + util/ntp-keygen-opts.c@1.48.1.1 +2 -2 + NTP_4_2_5 - BitKeeper/etc/ignore@1.59, 2007-01-04 23:40:52-05:00, stenn@whimsy.udel.edu +1 -2 - ChangeLog->CommitLog in the ignore file + util/ntp-keygen-opts.h@1.48.1.1 +3 -3 + NTP_4_2_5 -ChangeSet@1.1438, 2007-01-04 19:31:07-05:00, stenn@whimsy.udel.edu +1 -0 - hostname updates for flock-build + util/ntp-keygen-opts.texi@1.46.1.1 +1 -1 + NTP_4_2_5 - flock-build@1.39, 2007-01-04 19:30:49-05:00, stenn@whimsy.udel.edu +15 -19 - hostname updates for flock-build + util/ntp-keygen.1@1.46.1.1 +2 -2 + NTP_4_2_5 -ChangeSet@1.1437, 2006-12-28 19:21:25-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1436.1.1, 2006-12-28 19:21:25-05:00, stenn@whimsy.udel.edu NTP_4_2_4 TAG: NTP_4_2_4 - ntpd/ntpd-opts.c@1.50, 2006-12-28 19:21:05-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.50 +2 -2 NTP_4_2_4 - ntpd/ntpd-opts.h@1.50, 2006-12-28 19:21:05-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.50 +3 -3 NTP_4_2_4 - ntpd/ntpd-opts.texi@1.49, 2006-12-28 19:21:06-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.texi@1.49 +2 -2 NTP_4_2_4 - ntpd/ntpd.1@1.48, 2006-12-28 19:21:07-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.48 +2 -2 NTP_4_2_4 - ntpd/ntpdsim-opts.c@1.50, 2006-12-28 19:21:07-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.50 +2 -2 NTP_4_2_4 - ntpd/ntpdsim-opts.h@1.50, 2006-12-28 19:21:08-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.50 +3 -3 NTP_4_2_4 - ntpd/ntpdsim-opts.texi@1.48, 2006-12-28 19:21:08-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.48 +1 -1 NTP_4_2_4 - ntpd/ntpdsim.1@1.48, 2006-12-28 19:21:09-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.48 +2 -2 NTP_4_2_4 - ntpdc/ntpdc-opts.c@1.50, 2006-12-28 19:21:10-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.50 +2 -2 NTP_4_2_4 - ntpdc/ntpdc-opts.h@1.50, 2006-12-28 19:21:10-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.50 +3 -3 NTP_4_2_4 - ntpdc/ntpdc-opts.texi@1.48, 2006-12-28 19:21:11-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.48 +2 -2 NTP_4_2_4 - ntpdc/ntpdc.1@1.48, 2006-12-28 19:21:12-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.48 +2 -2 NTP_4_2_4 - ntpq/ntpq-opts.c@1.52, 2006-12-28 19:21:12-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.52 +2 -2 NTP_4_2_4 - ntpq/ntpq-opts.h@1.52, 2006-12-28 19:21:13-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.52 +3 -3 NTP_4_2_4 - ntpq/ntpq-opts.texi@1.49, 2006-12-28 19:21:13-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.texi@1.49 +2 -2 NTP_4_2_4 - ntpq/ntpq.1@1.48, 2006-12-28 19:21:14-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.48 +2 -2 NTP_4_2_4 - packageinfo.sh@1.66, 2006-12-28 19:21:15-05:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.65.1.1 +2 -2 NTP_4_2_4 - sntp/sntp-opts.c@1.49, 2006-12-28 19:21:15-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.49 +2 -2 NTP_4_2_4 - sntp/sntp-opts.h@1.49, 2006-12-28 19:21:17-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.49 +3 -3 NTP_4_2_4 - sntp/sntp-opts.texi@1.46, 2006-12-28 19:21:18-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.46 +1 -1 NTP_4_2_4 - sntp/sntp.1@1.49, 2006-12-28 19:21:18-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.49 +2 -2 NTP_4_2_4 - util/ntp-keygen-opts.c@1.49, 2006-12-28 19:21:19-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.49 +2 -2 NTP_4_2_4 - util/ntp-keygen-opts.h@1.49, 2006-12-28 19:21:20-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.49 +3 -3 NTP_4_2_4 - util/ntp-keygen-opts.texi@1.47, 2006-12-28 19:21:20-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.47 +2 -2 NTP_4_2_4 - util/ntp-keygen.1@1.47, 2006-12-28 19:21:21-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.47 +2 -2 NTP_4_2_4 -ChangeSet@1.1436, 2006-12-28 03:09:12-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1435.1.1, 2006-12-28 03:20:53-05:00, stenn@whimsy.udel.edu + ntp-4.2.5 + + BitKeeper/deleted/.del-packageinfo.sh~9547f70d1df81d4@1.64.1.1 +0 -0 + Delete: packageinfo.sh + + packageinfo.sh@1.1 +28 -0 + BitKeeper file /deacon/backroom/ntp-dev/packageinfo.sh + + packageinfo.sh@1.0 +0 -0 + +ChangeSet@1.1436, 2006-12-28 03:09:12-05:00, stenn@whimsy.udel.edu typo - packageinfo.sh@1.65, 2006-12-28 02:47:41-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.65 +1 -1 typo -ChangeSet@1.1435, 2006-12-27 21:17:55-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1435, 2006-12-27 21:17:55-05:00, stenn@whimsy.udel.edu updated backroom machine list - br-flock@1.11, 2006-12-27 21:17:39-05:00, stenn@whimsy.udel.edu +1 -1 + br-flock@1.11 +1 -1 updated backroom machine list -ChangeSet@1.1434, 2006-12-27 20:50:07-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1434, 2006-12-27 20:50:07-05:00, stenn@whimsy.udel.edu ntp-4.2.4 - NEWS@1.86, 2006-12-27 20:49:18-05:00, stenn@whimsy.udel.edu +3 -2 + NEWS@1.86 +3 -2 ntp-4.2.4 - packageinfo.sh@1.64, 2006-12-27 20:49:19-05:00, stenn@whimsy.udel.edu +7 -5 + packageinfo.sh@1.64 +7 -5 ntp-4.2.4 -ChangeSet@1.1433, 2006-12-27 02:21:39-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1433, 2006-12-27 02:21:39-05:00, stenn@whimsy.udel.edu monopt.html fixes from Dave Mills. - NEWS@1.85, 2006-12-27 02:21:25-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.85 +1 -0 monopt.html fixes from Dave Mills. - html/monopt.html@1.23, 2006-12-27 02:21:26-05:00, stenn@whimsy.udel.edu +2 -2 + html/monopt.html@1.23 +2 -2 monopt.html fixes from Dave Mills. -ChangeSet@1.1432, 2006-12-27 01:57:20-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1432, 2006-12-27 01:57:20-05:00, stenn@whimsy.udel.edu [Bug 452] Do not report kernel PLL/FLL flips. - NEWS@1.84, 2006-12-27 01:57:03-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.84 +1 -0 [Bug 452] Do not report kernel PLL/FLL flips. - ntpd/ntp_loopfilter.c@1.127, 2006-12-27 01:57:02-05:00, stenn@whimsy.udel.edu +5 -7 + ntpd/ntp_loopfilter.c@1.127 +5 -7 [Bug 452] Do not report kernel PLL/FLL flips. -ChangeSet@1.1431, 2006-12-27 01:45:38-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1431, 2006-12-27 01:45:38-05:00, stenn@whimsy.udel.edu [Bug 746] Expert mouseCLOCK USB v2.0 support added. - NEWS@1.83, 2006-12-27 01:45:24-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.83 +1 -0 [Bug 746] Expert mouseCLOCK USB v2.0 support added. -ChangeSet@1.1429, 2006-12-27 01:37:16-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1429, 2006-12-27 01:37:16-05:00, stenn@whimsy.udel.edu driver8.html updates from Martin Burnicki - NEWS@1.82, 2006-12-27 01:37:10-05:00, stenn@whimsy.udel.edu +2 -1 + NEWS@1.82 +2 -1 driver8.html updates from Martin Burnicki -ChangeSet@1.1426.2.1, 2006-12-27 01:22:30-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1426.2.1, 2006-12-27 01:22:30-05:00, stenn@whimsy.udel.edu [Bug 747] Drop tags from ntpdc.html - NEWS@1.81, 2006-12-27 01:20:47-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.81 +1 -0 [Bug 747] Drop tags from ntpdc.html - html/ntpdc.html@1.26, 2006-12-27 01:20:23-05:00, stenn@whimsy.udel.edu +3 -3 + html/ntpdc.html@1.26 +3 -3 [Bug 747] Drop tags from ntpdc.html -ChangeSet@1.1426.1.1, 2006-12-22 20:35:42+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1426.1.1, 2006-12-22 20:35:42+00:00, kardel@pogo.udel.edu driver8.html, refclock_parse.c: Bug 746 (RFE): add configuration for Expert mouseCLOCK USB v2.0 as mode 19 - html/drivers/driver8.html@1.22.1.1, 2006-12-22 20:35:14+00:00, kardel@pogo.udel.edu +5 -1 + html/drivers/driver8.html@1.22.1.1 +5 -1 Bug 746 (RFE): add configuration for Expert mouseCLOCK USB v2.0 as mode 19 - ntpd/refclock_parse.c@1.47, 2006-12-22 20:34:30+00:00, kardel@pogo.udel.edu +34 -3 + ntpd/refclock_parse.c@1.47 +34 -3 Bug 746 (RFE): add configuration for Expert mouseCLOCK USB v2.0 as mode 19 -ChangeSet@1.1427, 2006-12-06 12:18:15+00:00, burnicki@pogo.udel.edu +4 -0 +ChangeSet@1.1427, 2006-12-06 12:18:15+00:00, burnicki@pogo.udel.edu Updated Meinberg PZF509 to PZF511. Provided higher quality pictures with background color according to the web page. Removed borders around images. - html/drivers/driver8.html@1.23, 2006-12-06 12:18:12+00:00, burnicki@pogo.udel.edu +5 -5 + html/drivers/driver8.html@1.23 +5 -5 Removed borders around images. Updated Meinberg PZF509 to PZF511. - html/pic/c51.jpg@1.2, 2006-12-06 12:18:12+00:00, burnicki@pogo.udel.edu +366 -228 + html/pic/c51.jpg@1.2 +366 -228 Provided higher quality picture with background color according to the web page. - html/pic/gps167.jpg@1.2, 2006-12-06 12:18:13+00:00, burnicki@pogo.udel.edu +347 -270 + html/pic/gps167.jpg@1.2 +347 -270 Provided higher quality picture with background color according to the web page. - html/pic/pzf511.jpg@1.3, 2006-12-06 12:18:13+00:00, burnicki@pogo.udel.edu +453 -290 + html/pic/pzf511.jpg@1.3 +453 -290 Provided higher quality picture with background color according to the web page. - html/pic/pzf511.jpg@1.2, 2006-12-06 12:04:23+00:00, burnicki@pogo.udel.edu +0 -0 + html/pic/pzf511.jpg@1.2 +0 -0 Rename: html/pic/pzf509.jpg -> html/pic/pzf511.jpg -ChangeSet@1.1426, 2006-11-25 06:41:49-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1426, 2006-11-25 06:41:49-05:00, stenn@whimsy.udel.edu NTP_4_2_3P70_RC TAG: NTP_4_2_3P70_RC - ntpd/ntpd-opts.c@1.49, 2006-11-25 06:41:29-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.49 +2 -2 NTP_4_2_3P70_RC - ntpd/ntpd-opts.h@1.49, 2006-11-25 06:41:30-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.49 +3 -3 NTP_4_2_3P70_RC - ntpd/ntpd-opts.texi@1.48, 2006-11-25 06:41:31-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.48 +1 -1 NTP_4_2_3P70_RC - ntpd/ntpd.1@1.47, 2006-11-25 06:41:32-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.47 +2 -2 NTP_4_2_3P70_RC - ntpd/ntpdsim-opts.c@1.49, 2006-11-25 06:41:32-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.49 +2 -2 NTP_4_2_3P70_RC - ntpd/ntpdsim-opts.h@1.49, 2006-11-25 06:41:33-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.49 +3 -3 NTP_4_2_3P70_RC - ntpd/ntpdsim-opts.texi@1.47, 2006-11-25 06:41:33-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.47 +1 -1 NTP_4_2_3P70_RC - ntpd/ntpdsim.1@1.47, 2006-11-25 06:41:34-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.47 +2 -2 NTP_4_2_3P70_RC - ntpdc/ntpdc-opts.c@1.49, 2006-11-25 06:41:34-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.49 +2 -2 NTP_4_2_3P70_RC - ntpdc/ntpdc-opts.h@1.49, 2006-11-25 06:41:36-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.49 +3 -3 NTP_4_2_3P70_RC - ntpdc/ntpdc-opts.texi@1.47, 2006-11-25 06:41:37-05:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.47 +1 -1 NTP_4_2_3P70_RC - ntpdc/ntpdc.1@1.47, 2006-11-25 06:41:37-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.47 +2 -2 NTP_4_2_3P70_RC - ntpq/ntpq-opts.c@1.51, 2006-11-25 06:41:38-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.51 +2 -2 NTP_4_2_3P70_RC - ntpq/ntpq-opts.h@1.51, 2006-11-25 06:41:38-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.51 +3 -3 NTP_4_2_3P70_RC - ntpq/ntpq-opts.texi@1.48, 2006-11-25 06:41:39-05:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.48 +1 -1 NTP_4_2_3P70_RC - ntpq/ntpq.1@1.47, 2006-11-25 06:41:40-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.47 +2 -2 NTP_4_2_3P70_RC - packageinfo.sh@1.63, 2006-11-25 06:41:40-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.63 +1 -1 NTP_4_2_3P70_RC - sntp/sntp-opts.c@1.48, 2006-11-25 06:41:40-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.48 +2 -2 NTP_4_2_3P70_RC - sntp/sntp-opts.h@1.48, 2006-11-25 06:41:41-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.48 +3 -3 NTP_4_2_3P70_RC - sntp/sntp-opts.texi@1.45, 2006-11-25 06:41:42-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.45 +1 -1 NTP_4_2_3P70_RC - sntp/sntp.1@1.48, 2006-11-25 06:41:43-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.48 +2 -2 NTP_4_2_3P70_RC - util/ntp-keygen-opts.c@1.48, 2006-11-25 06:41:43-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.48 +2 -2 NTP_4_2_3P70_RC - util/ntp-keygen-opts.h@1.48, 2006-11-25 06:41:44-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.48 +3 -3 NTP_4_2_3P70_RC - util/ntp-keygen-opts.texi@1.46, 2006-11-25 06:41:45-05:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.46 +1 -1 NTP_4_2_3P70_RC - util/ntp-keygen.1@1.46, 2006-11-25 06:41:45-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.46 +2 -2 NTP_4_2_3P70_RC -ChangeSet@1.1425, 2006-11-25 02:31:59-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1425, 2006-11-25 02:31:59-05:00, stenn@whimsy.udel.edu sntp now uses the returned precision to control decimal places - NEWS@1.80, 2006-11-25 02:31:35-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.80 +1 -0 sntp now uses the returned precision to control decimal places - sntp/main.c@1.8, 2006-11-25 02:31:36-05:00, stenn@whimsy.udel.edu +29 -16 + sntp/main.c@1.8 +29 -16 sntp now uses the returned precision to control decimal places -ChangeSet@1.1424, 2006-11-24 06:42:33-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1424, 2006-11-24 06:42:33-05:00, stenn@whimsy.udel.edu NTP_4_2_3P69_RC TAG: NTP_4_2_3P69_RC - ntpd/ntpd-opts.c@1.48, 2006-11-24 06:42:12-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.48 +2 -2 NTP_4_2_3P69_RC - ntpd/ntpd-opts.h@1.48, 2006-11-24 06:42:13-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.48 +3 -3 NTP_4_2_3P69_RC - ntpd/ntpd-opts.texi@1.47, 2006-11-24 06:42:14-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.47 +1 -1 NTP_4_2_3P69_RC - ntpd/ntpd.1@1.46, 2006-11-24 06:42:14-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.46 +2 -2 NTP_4_2_3P69_RC - ntpd/ntpdsim-opts.c@1.48, 2006-11-24 06:42:15-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.48 +2 -2 NTP_4_2_3P69_RC - ntpd/ntpdsim-opts.h@1.48, 2006-11-24 06:42:16-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.48 +3 -3 NTP_4_2_3P69_RC - ntpd/ntpdsim-opts.texi@1.46, 2006-11-24 06:42:17-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.46 +1 -1 NTP_4_2_3P69_RC - ntpd/ntpdsim.1@1.46, 2006-11-24 06:42:18-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.46 +2 -2 NTP_4_2_3P69_RC - ntpdc/ntpdc-opts.c@1.48, 2006-11-24 06:42:18-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.48 +2 -2 NTP_4_2_3P69_RC - ntpdc/ntpdc-opts.h@1.48, 2006-11-24 06:42:19-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.48 +3 -3 NTP_4_2_3P69_RC - ntpdc/ntpdc-opts.texi@1.46, 2006-11-24 06:42:20-05:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.46 +1 -1 NTP_4_2_3P69_RC - ntpdc/ntpdc.1@1.46, 2006-11-24 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.46 +2 -2 NTP_4_2_3P69_RC - ntpq/ntpq-opts.c@1.50, 2006-11-24 06:42:21-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.50 +2 -2 NTP_4_2_3P69_RC - ntpq/ntpq-opts.h@1.50, 2006-11-24 06:42:22-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.50 +3 -3 NTP_4_2_3P69_RC - ntpq/ntpq-opts.texi@1.47, 2006-11-24 06:42:23-05:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.47 +1 -1 NTP_4_2_3P69_RC - ntpq/ntpq.1@1.46, 2006-11-24 06:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.46 +2 -2 NTP_4_2_3P69_RC - packageinfo.sh@1.62, 2006-11-24 06:42:24-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.62 +1 -1 NTP_4_2_3P69_RC - sntp/sntp-opts.c@1.47, 2006-11-24 06:42:25-05:00, stenn@whimsy.udel.edu +34 -13 + sntp/sntp-opts.c@1.47 +34 -13 NTP_4_2_3P69_RC - sntp/sntp-opts.h@1.47, 2006-11-24 06:42:26-05:00, stenn@whimsy.udel.edu +21 -14 + sntp/sntp-opts.h@1.47 +21 -14 NTP_4_2_3P69_RC - sntp/sntp-opts.texi@1.44, 2006-11-24 06:42:27-05:00, stenn@whimsy.udel.edu +9 -1 + sntp/sntp-opts.texi@1.44 +9 -1 NTP_4_2_3P69_RC - sntp/sntp.1@1.47, 2006-11-24 06:42:27-05:00, stenn@whimsy.udel.edu +8 -64 + sntp/sntp.1@1.47 +8 -64 NTP_4_2_3P69_RC - util/ntp-keygen-opts.c@1.47, 2006-11-24 06:42:28-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.47 +2 -2 NTP_4_2_3P69_RC - util/ntp-keygen-opts.h@1.47, 2006-11-24 06:42:29-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.47 +3 -3 NTP_4_2_3P69_RC - util/ntp-keygen-opts.texi@1.45, 2006-11-24 06:42:29-05:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.45 +1 -1 NTP_4_2_3P69_RC - util/ntp-keygen.1@1.45, 2006-11-24 06:42:30-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.45 +2 -2 NTP_4_2_3P69_RC -ChangeSet@1.1423, 2006-11-23 21:09:08-05:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1423, 2006-11-23 21:09:08-05:00, stenn@whimsy.udel.edu sntp -u will use an unprivileged port for its queries - NEWS@1.79, 2006-11-23 21:08:15-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.79 +1 -0 sntp -u will use an unprivileged port for its queries - sntp/main.c@1.7, 2006-11-23 21:08:04-05:00, stenn@whimsy.udel.edu +13 -2 + sntp/main.c@1.7 +13 -2 sntp -u will use an unprivileged port for its queries - sntp/sntp-opts.def@1.10, 2006-11-23 21:08:04-05:00, stenn@whimsy.udel.edu +10 -62 + sntp/sntp-opts.def@1.10 +10 -62 sntp -u will use an unprivileged port for its queries - sntp/socket.c@1.8, 2006-11-23 21:08:05-05:00, stenn@whimsy.udel.edu +4 -2 + sntp/socket.c@1.8 +4 -2 sntp -u will use an unprivileged port for its queries -ChangeSet@1.1422, 2006-11-22 06:42:29-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1422, 2006-11-22 06:42:29-05:00, stenn@whimsy.udel.edu NTP_4_2_3P68_RC TAG: NTP_4_2_3P68_RC - ntpd/ntpd-opts.c@1.47, 2006-11-22 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.47 +2 -2 NTP_4_2_3P68_RC - ntpd/ntpd-opts.h@1.47, 2006-11-22 06:42:09-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.47 +3 -3 NTP_4_2_3P68_RC - ntpd/ntpd-opts.texi@1.46, 2006-11-22 06:42:10-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.46 +3 -3 NTP_4_2_3P68_RC - ntpd/ntpd.1@1.45, 2006-11-22 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.45 +2 -2 NTP_4_2_3P68_RC - ntpd/ntpdsim-opts.c@1.47, 2006-11-22 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.47 +2 -2 NTP_4_2_3P68_RC - ntpd/ntpdsim-opts.h@1.47, 2006-11-22 06:42:12-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.47 +3 -3 NTP_4_2_3P68_RC - ntpd/ntpdsim-opts.texi@1.45, 2006-11-22 06:42:13-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.45 +1 -1 NTP_4_2_3P68_RC - ntpd/ntpdsim.1@1.45, 2006-11-22 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.45 +2 -2 NTP_4_2_3P68_RC - ntpdc/ntpdc-opts.c@1.47, 2006-11-22 06:42:14-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.47 +2 -2 NTP_4_2_3P68_RC - ntpdc/ntpdc-opts.h@1.47, 2006-11-22 06:42:15-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.47 +3 -3 NTP_4_2_3P68_RC - ntpdc/ntpdc-opts.texi@1.45, 2006-11-22 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.45 +2 -2 NTP_4_2_3P68_RC - ntpdc/ntpdc.1@1.45, 2006-11-22 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.45 +2 -2 NTP_4_2_3P68_RC - ntpq/ntpq-opts.c@1.49, 2006-11-22 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.49 +2 -2 NTP_4_2_3P68_RC - ntpq/ntpq-opts.h@1.49, 2006-11-22 06:42:18-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.49 +3 -3 NTP_4_2_3P68_RC - ntpq/ntpq-opts.texi@1.46, 2006-11-22 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.texi@1.46 +2 -2 NTP_4_2_3P68_RC - ntpq/ntpq.1@1.45, 2006-11-22 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.45 +2 -2 NTP_4_2_3P68_RC - packageinfo.sh@1.61, 2006-11-22 06:42:20-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.61 +1 -1 NTP_4_2_3P68_RC - sntp/sntp-opts.c@1.46, 2006-11-22 06:42:20-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.46 +2 -2 NTP_4_2_3P68_RC - sntp/sntp-opts.h@1.46, 2006-11-22 06:42:21-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.46 +3 -3 NTP_4_2_3P68_RC - sntp/sntp-opts.texi@1.43, 2006-11-22 06:42:22-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.43 +1 -1 NTP_4_2_3P68_RC - sntp/sntp.1@1.46, 2006-11-22 06:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.46 +2 -2 NTP_4_2_3P68_RC - util/ntp-keygen-opts.c@1.46, 2006-11-22 06:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.46 +2 -2 NTP_4_2_3P68_RC - util/ntp-keygen-opts.h@1.46, 2006-11-22 06:42:24-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.46 +3 -3 NTP_4_2_3P68_RC - util/ntp-keygen-opts.texi@1.44, 2006-11-22 06:42:25-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.44 +2 -2 NTP_4_2_3P68_RC - util/ntp-keygen.1@1.44, 2006-11-22 06:42:26-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.44 +2 -2 NTP_4_2_3P68_RC -ChangeSet@1.1421, 2006-11-22 02:15:14-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1421, 2006-11-22 02:15:14-05:00, stenn@whimsy.udel.edu [Bug 741] 'burst' doesn't work with peers - NEWS@1.78, 2006-11-22 02:14:47-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.78 +1 -0 [Bug 741] 'burst' doesn't work with !unfit peers - ntpd/ntp_proto.c@1.249, 2006-11-22 02:14:48-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.249 +1 -1 [Bug 741] 'burst' doesn't work with !unfit peers -ChangeSet@1.1420, 2006-11-21 23:53:23-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1420, 2006-11-21 23:53:23-05:00, stenn@whimsy.udel.edu [Bug 735] Fix a make/gmake VPATH issue on Solaris - Makefile.am@1.70, 2006-11-21 23:53:04-05:00, stenn@whimsy.udel.edu +1 -1 + Makefile.am@1.70 +1 -1 [Bug 735] Fix a make/gmake VPATH issue on Solaris - NEWS@1.77, 2006-11-21 23:53:03-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.77 +1 -0 [Bug 735] Fix a make/gmake VPATH issue on Solaris -ChangeSet@1.1419, 2006-11-21 06:42:26-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1419, 2006-11-21 06:42:26-05:00, stenn@whimsy.udel.edu NTP_4_2_3P67_RC TAG: NTP_4_2_3P67_RC - ntpd/ntpd-opts.c@1.46, 2006-11-21 06:42:02-05:00, stenn@whimsy.udel.edu +3 -4 + ntpd/ntpd-opts.c@1.46 +3 -4 NTP_4_2_3P67_RC - ntpd/ntpd-opts.h@1.46, 2006-11-21 06:42:02-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.46 +3 -3 NTP_4_2_3P67_RC - ntpd/ntpd-opts.texi@1.45, 2006-11-21 06:42:03-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.45 +1 -1 NTP_4_2_3P67_RC - ntpd/ntpd.1@1.44, 2006-11-21 06:42:04-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd.1@1.44 +3 -3 NTP_4_2_3P67_RC - ntpd/ntpdsim-opts.c@1.46, 2006-11-21 06:42:04-05:00, stenn@whimsy.udel.edu +3 -4 + ntpd/ntpdsim-opts.c@1.46 +3 -4 NTP_4_2_3P67_RC - ntpd/ntpdsim-opts.h@1.46, 2006-11-21 06:42:05-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.46 +3 -3 NTP_4_2_3P67_RC - ntpd/ntpdsim-opts.texi@1.44, 2006-11-21 06:42:06-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.44 +1 -1 NTP_4_2_3P67_RC - ntpd/ntpdsim.1@1.44, 2006-11-21 06:42:06-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim.1@1.44 +3 -3 NTP_4_2_3P67_RC - ntpdc/ntpdc-opts.c@1.46, 2006-11-21 06:42:07-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.46 +2 -2 NTP_4_2_3P67_RC - ntpdc/ntpdc-opts.h@1.46, 2006-11-21 06:42:08-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.46 +3 -3 NTP_4_2_3P67_RC - ntpdc/ntpdc-opts.texi@1.44, 2006-11-21 06:42:09-05:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.44 +1 -1 NTP_4_2_3P67_RC - ntpdc/ntpdc.1@1.44, 2006-11-21 06:42:10-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.44 +2 -2 NTP_4_2_3P67_RC - ntpq/ntpq-opts.c@1.48, 2006-11-21 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.48 +2 -2 NTP_4_2_3P67_RC - ntpq/ntpq-opts.h@1.48, 2006-11-21 06:42:11-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.48 +3 -3 NTP_4_2_3P67_RC - ntpq/ntpq-opts.texi@1.45, 2006-11-21 06:42:12-05:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.45 +1 -1 NTP_4_2_3P67_RC - ntpq/ntpq.1@1.44, 2006-11-21 06:42:13-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.44 +2 -2 NTP_4_2_3P67_RC - packageinfo.sh@1.60, 2006-11-21 06:42:13-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.60 +1 -1 NTP_4_2_3P67_RC - sntp/sntp-opts.c@1.45, 2006-11-21 06:42:14-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.45 +2 -2 NTP_4_2_3P67_RC - sntp/sntp-opts.h@1.45, 2006-11-21 06:42:15-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.45 +3 -3 NTP_4_2_3P67_RC - sntp/sntp-opts.texi@1.42, 2006-11-21 06:42:15-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.42 +1 -1 NTP_4_2_3P67_RC - sntp/sntp.1@1.45, 2006-11-21 06:42:16-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.45 +2 -2 NTP_4_2_3P67_RC - util/ntp-keygen-opts.c@1.45, 2006-11-21 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.45 +2 -2 NTP_4_2_3P67_RC - util/ntp-keygen-opts.h@1.45, 2006-11-21 06:42:18-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.45 +3 -3 NTP_4_2_3P67_RC - util/ntp-keygen-opts.texi@1.43, 2006-11-21 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.43 +1 -1 NTP_4_2_3P67_RC - util/ntp-keygen.1@1.43, 2006-11-21 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.43 +2 -2 NTP_4_2_3P67_RC -ChangeSet@1.1418, 2006-11-21 09:35:31+00:00, burnicki@pogo.udel.edu +1 -0 +ChangeSet@1.1418, 2006-11-21 09:35:31+00:00, burnicki@pogo.udel.edu Fixed an uppercase typo. - html/drivers/driver8.html@1.22, 2006-11-21 09:35:24+00:00, burnicki@pogo.udel.edu +1 -1 + html/drivers/driver8.html@1.22 +1 -1 Fixed an uppercase typo. -ChangeSet@1.1417, 2006-11-21 02:43:36-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1417, 2006-11-21 02:43:36-05:00, stenn@whimsy.udel.edu [Bug 717] Make sure sntp/*version.def is up-to-date - bootstrap@1.18, 2006-11-21 02:43:17-05:00, stenn@whimsy.udel.edu +5 -0 + bootstrap@1.18 +5 -0 [Bug 717] Make sure sntp/*version.def is up-to-date -ChangeSet@1.1416, 2006-11-20 23:05:54-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1416, 2006-11-20 23:05:54-05:00, stenn@whimsy.udel.edu [Bug 739] ntpd -x should not take an argument - NEWS@1.76, 2006-11-20 23:04:55-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.76 +1 -0 [Bug 739] ntpd -x should not take an argument - ntpd/ntpdbase-opts.def@1.10, 2006-11-20 23:04:27-05:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntpdbase-opts.def@1.10 +0 -1 [Bug 739] ntpd -x should not take an argument -ChangeSet@1.1415, 2006-11-19 06:45:35-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1415, 2006-11-19 06:45:35-05:00, stenn@whimsy.udel.edu NTP_4_2_3P66_RC TAG: NTP_4_2_3P66_RC - ntpd/ntpd-opts.c@1.45, 2006-11-19 06:45:13-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.45 +2 -2 NTP_4_2_3P66_RC - ntpd/ntpd-opts.h@1.45, 2006-11-19 06:45:14-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.45 +3 -3 NTP_4_2_3P66_RC - ntpd/ntpd-opts.texi@1.44, 2006-11-19 06:45:14-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.texi@1.44 +2 -2 NTP_4_2_3P66_RC - ntpd/ntpd.1@1.43, 2006-11-19 06:45:15-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.43 +2 -2 NTP_4_2_3P66_RC - ntpd/ntpdsim-opts.c@1.45, 2006-11-19 06:45:16-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.45 +2 -2 NTP_4_2_3P66_RC - ntpd/ntpdsim-opts.h@1.45, 2006-11-19 06:45:17-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.45 +3 -3 NTP_4_2_3P66_RC - ntpd/ntpdsim-opts.texi@1.43, 2006-11-19 06:45:17-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.43 +1 -1 NTP_4_2_3P66_RC - ntpd/ntpdsim.1@1.43, 2006-11-19 06:45:18-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.43 +2 -2 NTP_4_2_3P66_RC - ntpdc/ntpdc-opts.c@1.45, 2006-11-19 06:45:19-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.45 +2 -2 NTP_4_2_3P66_RC - ntpdc/ntpdc-opts.h@1.45, 2006-11-19 06:45:19-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.45 +3 -3 NTP_4_2_3P66_RC - ntpdc/ntpdc-opts.texi@1.43, 2006-11-19 06:45:20-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.43 +2 -2 NTP_4_2_3P66_RC - ntpdc/ntpdc.1@1.43, 2006-11-19 06:45:21-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.43 +2 -2 NTP_4_2_3P66_RC - ntpq/ntpq-opts.c@1.47, 2006-11-19 06:45:22-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.47 +2 -2 NTP_4_2_3P66_RC - ntpq/ntpq-opts.h@1.47, 2006-11-19 06:45:23-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.47 +3 -3 NTP_4_2_3P66_RC - ntpq/ntpq-opts.texi@1.44, 2006-11-19 06:45:24-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.texi@1.44 +2 -2 NTP_4_2_3P66_RC - ntpq/ntpq.1@1.43, 2006-11-19 06:45:24-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.43 +2 -2 NTP_4_2_3P66_RC - packageinfo.sh@1.59, 2006-11-19 06:45:25-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.59 +1 -1 NTP_4_2_3P66_RC - sntp/sntp-opts.c@1.44, 2006-11-19 06:45:26-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.44 +2 -2 NTP_4_2_3P66_RC - sntp/sntp-opts.h@1.44, 2006-11-19 06:45:27-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.44 +3 -3 NTP_4_2_3P66_RC - sntp/sntp-opts.texi@1.41, 2006-11-19 06:45:27-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.41 +1 -1 NTP_4_2_3P66_RC - sntp/sntp.1@1.44, 2006-11-19 06:45:28-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.44 +2 -2 NTP_4_2_3P66_RC - util/ntp-keygen-opts.c@1.44, 2006-11-19 06:45:29-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.44 +2 -2 NTP_4_2_3P66_RC - util/ntp-keygen-opts.h@1.44, 2006-11-19 06:45:30-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.44 +3 -3 NTP_4_2_3P66_RC - util/ntp-keygen-opts.texi@1.42, 2006-11-19 06:45:31-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.42 +2 -2 NTP_4_2_3P66_RC - util/ntp-keygen.1@1.42, 2006-11-19 06:45:31-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.42 +2 -2 NTP_4_2_3P66_RC -ChangeSet@1.1412.1.1, 2006-11-18 21:12:41-08:00, harlan@minnie.everett.org +3 -0 +ChangeSet@1.1412.1.1, 2006-11-18 21:12:41-08:00, harlan@minnie.everett.org * [Bug 737] Some systems need help providing struct iovec. - NEWS@1.75, 2006-11-18 21:12:35-08:00, harlan@minnie.everett.org +1 -0 + NEWS@1.75 +1 -0 * [Bug 737] Some systems need help providing struct iovec. - configure.ac@1.400, 2006-11-18 21:12:35-08:00, harlan@minnie.everett.org +44 -0 + configure.ac@1.400 +44 -0 * [Bug 737] Some systems need help providing struct iovec. - ntpd/ntp_io.c@1.244, 2006-11-18 21:12:35-08:00, harlan@minnie.everett.org +3 -0 + ntpd/ntp_io.c@1.244 +3 -0 * [Bug 737] Some systems need help providing struct iovec. -ChangeSet@1.1413, 2006-11-17 08:59:50+00:00, burnicki@pogo.udel.edu +1 -0 +ChangeSet@1.1413, 2006-11-17 08:59:50+00:00, burnicki@pogo.udel.edu [Bug #728] More changes by Paul and Martin. - html/drivers/driver8.html@1.21, 2006-11-17 08:59:48+00:00, burnicki@pogo.udel.edu +93 -44 + html/drivers/driver8.html@1.21 +93 -44 More changes by Paul and Martin. -ChangeSet@1.1412, 2006-11-10 06:41:45-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1412, 2006-11-10 06:41:45-05:00, stenn@whimsy.udel.edu NTP_4_2_3P65_RC TAG: NTP_4_2_3P65_RC - ntpd/ntpd-opts.c@1.44, 2006-11-10 06:41:23-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.44 +2 -2 NTP_4_2_3P65_RC - ntpd/ntpd-opts.h@1.44, 2006-11-10 06:41:24-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.44 +3 -3 NTP_4_2_3P65_RC - ntpd/ntpd-opts.texi@1.43, 2006-11-10 06:41:24-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.43 +1 -1 NTP_4_2_3P65_RC - ntpd/ntpd.1@1.42, 2006-11-10 06:41:25-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.42 +2 -2 NTP_4_2_3P65_RC - ntpd/ntpdsim-opts.c@1.44, 2006-11-10 06:41:26-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.44 +2 -2 NTP_4_2_3P65_RC - ntpd/ntpdsim-opts.h@1.44, 2006-11-10 06:41:27-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.44 +3 -3 NTP_4_2_3P65_RC - ntpd/ntpdsim-opts.texi@1.42, 2006-11-10 06:41:28-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.42 +1 -1 NTP_4_2_3P65_RC - ntpd/ntpdsim.1@1.42, 2006-11-10 06:41:28-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.42 +2 -2 NTP_4_2_3P65_RC - ntpdc/ntpdc-opts.c@1.44, 2006-11-10 06:41:29-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.44 +2 -2 NTP_4_2_3P65_RC - ntpdc/ntpdc-opts.h@1.44, 2006-11-10 06:41:30-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.44 +3 -3 NTP_4_2_3P65_RC - ntpdc/ntpdc-opts.texi@1.42, 2006-11-10 06:41:32-05:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.42 +1 -1 NTP_4_2_3P65_RC - ntpdc/ntpdc.1@1.42, 2006-11-10 06:41:32-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.42 +2 -2 NTP_4_2_3P65_RC - ntpq/ntpq-opts.c@1.46, 2006-11-10 06:41:33-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.46 +2 -2 NTP_4_2_3P65_RC - ntpq/ntpq-opts.h@1.46, 2006-11-10 06:41:33-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.46 +3 -3 NTP_4_2_3P65_RC - ntpq/ntpq-opts.texi@1.43, 2006-11-10 06:41:34-05:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.43 +1 -1 NTP_4_2_3P65_RC - ntpq/ntpq.1@1.42, 2006-11-10 06:41:35-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.42 +2 -2 NTP_4_2_3P65_RC - packageinfo.sh@1.58, 2006-11-10 06:41:35-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.58 +1 -1 NTP_4_2_3P65_RC - sntp/sntp-opts.c@1.43, 2006-11-10 06:41:36-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.43 +2 -2 NTP_4_2_3P65_RC - sntp/sntp-opts.h@1.43, 2006-11-10 06:41:37-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.43 +3 -3 NTP_4_2_3P65_RC - sntp/sntp-opts.texi@1.40, 2006-11-10 06:41:37-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.40 +1 -1 NTP_4_2_3P65_RC - sntp/sntp.1@1.43, 2006-11-10 06:41:38-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.43 +2 -2 NTP_4_2_3P65_RC - util/ntp-keygen-opts.c@1.43, 2006-11-10 06:41:39-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.43 +2 -2 NTP_4_2_3P65_RC - util/ntp-keygen-opts.h@1.43, 2006-11-10 06:41:39-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.43 +3 -3 NTP_4_2_3P65_RC - util/ntp-keygen-opts.texi@1.41, 2006-11-10 06:41:40-05:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.41 +1 -1 NTP_4_2_3P65_RC - util/ntp-keygen.1@1.41, 2006-11-10 06:41:41-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.41 +2 -2 NTP_4_2_3P65_RC -ChangeSet@1.1411, 2006-11-10 00:24:06-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1411, 2006-11-10 00:24:06-05:00, stenn@whimsy.udel.edu [Bug 717] Fix libopts compile problem for some windows versions - NEWS@1.74, 2006-11-10 00:23:54-05:00, stenn@whimsy.udel.edu +1 -1 + NEWS@1.74 +1 -1 [Bug 717] Fix libopts compile problem for some windows versions -ChangeSet@1.1398.1.1, 2006-11-09 22:57:09-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1398.1.1, 2006-11-09 22:57:09-05:00, mayer@pogo.udel.edu Bug #717 Add uintptr_t typedef for VS 6.0 - ports/winnt/include/config.h@1.46, 2006-11-09 22:56:27-05:00, mayer@pogo.udel.edu +7 -0 + ports/winnt/include/config.h@1.46 +7 -0 Bug #717 Add uintptr_t typedef for VS 6.0 -ChangeSet@1.1409, 2006-11-09 06:42:28-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1409, 2006-11-09 06:42:28-05:00, stenn@whimsy.udel.edu NTP_4_2_3P64_RC TAG: NTP_4_2_3P64_RC - ntpd/ntpd-opts.c@1.43, 2006-11-09 06:42:07-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.43 +2 -2 NTP_4_2_3P64_RC - ntpd/ntpd-opts.h@1.43, 2006-11-09 06:42:07-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.43 +3 -3 NTP_4_2_3P64_RC - ntpd/ntpd-opts.texi@1.42, 2006-11-09 06:42:08-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.42 +1 -1 NTP_4_2_3P64_RC - ntpd/ntpd.1@1.41, 2006-11-09 06:42:08-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.41 +2 -2 NTP_4_2_3P64_RC - ntpd/ntpdsim-opts.c@1.43, 2006-11-09 06:42:09-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.43 +2 -2 NTP_4_2_3P64_RC - ntpd/ntpdsim-opts.h@1.43, 2006-11-09 06:42:10-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.43 +3 -3 NTP_4_2_3P64_RC - ntpd/ntpdsim-opts.texi@1.41, 2006-11-09 06:42:10-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.41 +1 -1 NTP_4_2_3P64_RC - ntpd/ntpdsim.1@1.41, 2006-11-09 06:42:11-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.41 +2 -2 NTP_4_2_3P64_RC - ntpdc/ntpdc-opts.c@1.43, 2006-11-09 06:42:12-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.43 +2 -2 NTP_4_2_3P64_RC - ntpdc/ntpdc-opts.h@1.43, 2006-11-09 06:42:13-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.43 +3 -3 NTP_4_2_3P64_RC - ntpdc/ntpdc-opts.texi@1.41, 2006-11-09 06:42:14-05:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.41 +1 -1 NTP_4_2_3P64_RC - ntpdc/ntpdc.1@1.41, 2006-11-09 06:42:14-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.41 +2 -2 NTP_4_2_3P64_RC - ntpq/ntpq-opts.c@1.45, 2006-11-09 06:42:15-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.45 +2 -2 NTP_4_2_3P64_RC - ntpq/ntpq-opts.h@1.45, 2006-11-09 06:42:16-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.45 +3 -3 NTP_4_2_3P64_RC - ntpq/ntpq-opts.texi@1.42, 2006-11-09 06:42:16-05:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.42 +1 -1 NTP_4_2_3P64_RC - ntpq/ntpq.1@1.41, 2006-11-09 06:42:17-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.41 +2 -2 NTP_4_2_3P64_RC - packageinfo.sh@1.57, 2006-11-09 06:42:18-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.57 +1 -1 NTP_4_2_3P64_RC - sntp/sntp-opts.c@1.42, 2006-11-09 06:42:19-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.42 +2 -2 NTP_4_2_3P64_RC - sntp/sntp-opts.h@1.42, 2006-11-09 06:42:19-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.42 +3 -3 NTP_4_2_3P64_RC - sntp/sntp-opts.texi@1.39, 2006-11-09 06:42:20-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.39 +1 -1 NTP_4_2_3P64_RC - sntp/sntp.1@1.42, 2006-11-09 06:42:21-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.42 +2 -2 NTP_4_2_3P64_RC - util/ntp-keygen-opts.c@1.42, 2006-11-09 06:42:21-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.42 +2 -2 NTP_4_2_3P64_RC - util/ntp-keygen-opts.h@1.42, 2006-11-09 06:42:22-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.42 +3 -3 NTP_4_2_3P64_RC - util/ntp-keygen-opts.texi@1.40, 2006-11-09 06:42:23-05:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.40 +1 -1 NTP_4_2_3P64_RC - util/ntp-keygen.1@1.40, 2006-11-09 06:42:23-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.40 +2 -2 NTP_4_2_3P64_RC -ChangeSet@1.1408, 2006-11-09 04:29:07-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1408, 2006-11-09 04:29:07-05:00, stenn@whimsy.udel.edu [Bug 728] parse documentation fixes - NEWS@1.73, 2006-11-09 04:28:53-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.73 +1 -0 [Bug 728] parse documentation fixes -ChangeSet@1.1407, 2006-11-08 18:11:25+00:00, burnicki@pogo.udel.edu +2 -0 +ChangeSet@1.1407, 2006-11-08 18:11:25+00:00, burnicki@pogo.udel.edu [Bug #728] Typo fixes submitted by Paul Croome plus additional updates and fixes for driver8.html and parsedata.html. - html/drivers/driver8.html@1.20, 2006-11-08 18:11:23+00:00, burnicki@pogo.udel.edu +127 -136 + html/drivers/driver8.html@1.20 +127 -136 Typo fixes submitted by Paul Croome. Updated docs and links. - html/parsedata.html@1.12, 2006-11-08 18:11:23+00:00, burnicki@pogo.udel.edu +92 -80 + html/parsedata.html@1.12 +92 -80 Updated docs and fixed some errors. -ChangeSet@1.1406, 2006-11-06 06:47:05-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1406, 2006-11-06 06:47:05-05:00, stenn@whimsy.udel.edu NTP_4_2_3P63_RC TAG: NTP_4_2_3P63_RC - ntpd/ntpd-opts.c@1.42, 2006-11-06 06:46:45-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.42 +2 -2 NTP_4_2_3P63_RC - ntpd/ntpd-opts.h@1.42, 2006-11-06 06:46:46-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.42 +3 -3 NTP_4_2_3P63_RC - ntpd/ntpd-opts.texi@1.41, 2006-11-06 06:46:46-05:00, stenn@whimsy.udel.edu +2 -4 + ntpd/ntpd-opts.texi@1.41 +2 -4 NTP_4_2_3P63_RC - ntpd/ntpd.1@1.40, 2006-11-06 06:46:47-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.40 +2 -2 NTP_4_2_3P63_RC - ntpd/ntpdsim-opts.c@1.42, 2006-11-06 06:46:48-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.42 +2 -2 NTP_4_2_3P63_RC - ntpd/ntpdsim-opts.h@1.42, 2006-11-06 06:46:48-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.42 +3 -3 NTP_4_2_3P63_RC - ntpd/ntpdsim-opts.texi@1.40, 2006-11-06 06:46:49-05:00, stenn@whimsy.udel.edu +2 -73 + ntpd/ntpdsim-opts.texi@1.40 +2 -73 NTP_4_2_3P63_RC - ntpd/ntpdsim.1@1.40, 2006-11-06 06:46:50-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.40 +2 -2 NTP_4_2_3P63_RC - ntpdc/ntpdc-opts.c@1.42, 2006-11-06 06:46:51-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.42 +2 -2 NTP_4_2_3P63_RC - ntpdc/ntpdc-opts.h@1.42, 2006-11-06 06:46:51-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.42 +3 -3 NTP_4_2_3P63_RC - ntpdc/ntpdc-opts.texi@1.40, 2006-11-06 06:46:52-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.40 +2 -2 NTP_4_2_3P63_RC - ntpdc/ntpdc.1@1.40, 2006-11-06 06:46:53-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.40 +2 -2 NTP_4_2_3P63_RC - ntpq/ntpq-opts.c@1.44, 2006-11-06 06:46:54-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.44 +2 -2 NTP_4_2_3P63_RC - ntpq/ntpq-opts.h@1.44, 2006-11-06 06:46:54-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.44 +3 -3 NTP_4_2_3P63_RC - ntpq/ntpq-opts.texi@1.41, 2006-11-06 06:46:55-05:00, stenn@whimsy.udel.edu +4 -244 + ntpq/ntpq-opts.texi@1.41 +4 -244 NTP_4_2_3P63_RC - ntpq/ntpq.1@1.40, 2006-11-06 06:46:56-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.40 +2 -2 NTP_4_2_3P63_RC - packageinfo.sh@1.56, 2006-11-06 06:46:57-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.56 +1 -1 NTP_4_2_3P63_RC - sntp/sntp-opts.c@1.41, 2006-11-06 06:46:57-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.41 +2 -2 NTP_4_2_3P63_RC - sntp/sntp-opts.h@1.41, 2006-11-06 06:46:58-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.41 +3 -3 NTP_4_2_3P63_RC - sntp/sntp-opts.texi@1.38, 2006-11-06 06:46:59-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.38 +1 -1 NTP_4_2_3P63_RC - sntp/sntp.1@1.41, 2006-11-06 06:46:59-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.41 +2 -2 NTP_4_2_3P63_RC - util/ntp-keygen-opts.c@1.41, 2006-11-06 06:47:00-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.41 +2 -2 NTP_4_2_3P63_RC - util/ntp-keygen-opts.h@1.41, 2006-11-06 06:47:01-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.41 +3 -3 NTP_4_2_3P63_RC - util/ntp-keygen-opts.texi@1.39, 2006-11-06 06:47:01-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.39 +2 -2 NTP_4_2_3P63_RC - util/ntp-keygen.1@1.39, 2006-11-06 06:47:02-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.39 +2 -2 NTP_4_2_3P63_RC -ChangeSet@1.1405, 2006-11-06 03:11:36-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1405, 2006-11-06 03:11:36-05:00, stenn@whimsy.udel.edu [Bug 734] setsockopt(..., IP_MULTICAST_IF, ...) fails on 64-bit platforms. - NEWS@1.72, 2006-11-06 03:11:21-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.72 +1 -0 [Bug 734] setsockopt(..., IP_MULTICAST_IF, ...) fails on 64-bit platforms. -ChangeSet@1.1404, 2006-11-06 03:06:37-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1404, 2006-11-06 03:06:37-05:00, stenn@whimsy.udel.edu Build our libopts by default (static, and without installing it - configure.ac@1.399, 2006-11-06 03:06:25-05:00, stenn@whimsy.udel.edu +17 -0 + configure.ac@1.399 +17 -0 Build our libopts by default (static, and without installing it - sntp/configure.ac@1.15, 2006-11-06 03:06:27-05:00, stenn@whimsy.udel.edu +18 -0 + sntp/configure.ac@1.15 +18 -0 Build our libopts by default (static, and without installing it -ChangeSet@1.1400.1.1, 2006-11-06 02:51:53-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1400.1.1, 2006-11-06 02:51:53-05:00, stenn@whimsy.udel.edu [Bug 732] C-DEX JST2000 patch from Hideo Kuramatsu - NEWS@1.71, 2006-11-06 02:51:43-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.71 +1 -0 [Bug 732] C-DEX JST2000 patch from Hideo Kuramatsu - ntpd/refclock_jjy.c@1.13, 2006-11-06 02:51:17-05:00, stenn@whimsy.udel.edu +5 -0 + ntpd/refclock_jjy.c@1.13 +5 -0 [Bug 732] C-DEX JST2000 patch from Hideo Kuramatsu -ChangeSet@1.1402, 2006-11-05 08:28:53+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1402, 2006-11-05 08:28:53+00:00, kardel@pogo.udel.edu ntp_io.c: pass correct address length for setsockopt(..., IP_MULTICAST_IF, ...) (sizeof(struct sockaddr_in*) != sizeof(struct in_addr) on 64-bit platforms) - ntpd/ntp_io.c@1.243, 2006-11-05 08:25:03+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.243 +1 -1 pass correct address length for setsockopt(..., IP_MULTICAST_IF, ...) (sizeof(struct sockaddr_in*) != sizeof(struct in_addr) on 64 bite platforms) -ChangeSet@1.1400, 2006-11-01 06:45:21-05:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1400, 2006-11-01 06:45:21-05:00, stenn@whimsy.udel.edu NTP_4_2_3P62_RC TAG: NTP_4_2_3P62_RC - ntpd/ntpd-opts.c@1.41, 2006-11-01 06:45:00-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.41 +2 -2 NTP_4_2_3P62_RC - ntpd/ntpd-opts.h@1.41, 2006-11-01 06:45:01-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.41 +3 -3 NTP_4_2_3P62_RC - ntpd/ntpd-opts.texi@1.40, 2006-11-01 06:45:02-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.40 +1 -1 NTP_4_2_3P62_RC - ntpd/ntpd.1@1.39, 2006-11-01 06:45:02-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.39 +2 -2 NTP_4_2_3P62_RC - ntpd/ntpdsim-opts.c@1.41, 2006-11-01 06:45:03-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.41 +2 -2 NTP_4_2_3P62_RC - ntpd/ntpdsim-opts.h@1.41, 2006-11-01 06:45:04-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.41 +3 -3 NTP_4_2_3P62_RC - ntpd/ntpdsim-opts.texi@1.39, 2006-11-01 06:45:05-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.39 +1 -1 NTP_4_2_3P62_RC - ntpd/ntpdsim.1@1.39, 2006-11-01 06:45:05-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.39 +2 -2 NTP_4_2_3P62_RC - ntpdc/ntpdc-opts.c@1.41, 2006-11-01 06:45:06-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.41 +2 -2 NTP_4_2_3P62_RC - ntpdc/ntpdc-opts.h@1.41, 2006-11-01 06:45:07-05:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.41 +3 -3 NTP_4_2_3P62_RC - ntpdc/ntpdc-opts.texi@1.39, 2006-11-01 06:45:07-05:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.39 +1 -1 NTP_4_2_3P62_RC - ntpdc/ntpdc.1@1.39, 2006-11-01 06:45:08-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.39 +2 -2 NTP_4_2_3P62_RC - ntpq/ntpq-opts.c@1.43, 2006-11-01 06:45:08-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.43 +2 -2 NTP_4_2_3P62_RC - ntpq/ntpq-opts.h@1.43, 2006-11-01 06:45:10-05:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.43 +3 -3 NTP_4_2_3P62_RC - ntpq/ntpq-opts.texi@1.40, 2006-11-01 06:45:10-05:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.40 +1 -1 NTP_4_2_3P62_RC - ntpq/ntpq.1@1.39, 2006-11-01 06:45:11-05:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.39 +2 -2 NTP_4_2_3P62_RC - packageinfo.sh@1.55, 2006-11-01 06:45:12-05:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.55 +1 -1 NTP_4_2_3P62_RC - sntp/sntp-opts.c@1.40, 2006-11-01 06:45:13-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.40 +2 -2 NTP_4_2_3P62_RC - sntp/sntp-opts.h@1.40, 2006-11-01 06:45:13-05:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.40 +3 -3 NTP_4_2_3P62_RC - sntp/sntp-opts.texi@1.37, 2006-11-01 06:45:14-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.37 +1 -1 NTP_4_2_3P62_RC - sntp/sntp.1@1.40, 2006-11-01 06:45:14-05:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.40 +2 -2 NTP_4_2_3P62_RC - util/ntp-keygen-opts.c@1.40, 2006-11-01 06:45:16-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.40 +2 -2 NTP_4_2_3P62_RC - util/ntp-keygen-opts.h@1.40, 2006-11-01 06:45:16-05:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.40 +3 -3 NTP_4_2_3P62_RC - util/ntp-keygen-opts.texi@1.38, 2006-11-01 06:45:17-05:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.38 +1 -1 NTP_4_2_3P62_RC - util/ntp-keygen.1@1.38, 2006-11-01 06:45:17-05:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.38 +2 -2 NTP_4_2_3P62_RC -ChangeSet@1.1399, 2006-10-31 23:58:45-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1399, 2006-10-31 23:58:45-05:00, stenn@whimsy.udel.edu [Bug 721] check for __ss_family and __ss_len separately - NEWS@1.70, 2006-10-31 23:58:29-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.70 +1 -0 [Bug 721] check for __ss_family and __ss_len separately - configure.ac@1.398, 2006-10-31 23:57:41-05:00, stenn@whimsy.udel.edu +41 -2 + configure.ac@1.398 +41 -2 [Bug 721] check for __ss_family and __ss_len separately -ChangeSet@1.1379.13.1, 2006-10-30 07:24:38-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.13.1, 2006-10-30 07:24:38-05:00, mayer@pogo.udel.edu Bug #695 Fix to turn off Option warnings for VS 2005 - ports/winnt/include/config.h@1.45, 2006-10-30 07:24:03-05:00, mayer@pogo.udel.edu +1 -0 + ports/winnt/include/config.h@1.45 +1 -0 Bug #695 Fix to turn off Option warnings for VS 2005 -ChangeSet@1.1397, 2006-10-23 07:48:24-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1397, 2006-10-23 07:48:24-04:00, stenn@whimsy.udel.edu NTP_4_2_3P61_RC TAG: NTP_4_2_3P61_RC - ntpd/ntpd-opts.c@1.40, 2006-10-23 07:48:04-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.40 +2 -2 NTP_4_2_3P61_RC - ntpd/ntpd-opts.h@1.40, 2006-10-23 07:48:05-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.40 +3 -3 NTP_4_2_3P61_RC - ntpd/ntpd-opts.texi@1.39, 2006-10-23 07:48:05-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.39 +1 -1 NTP_4_2_3P61_RC - ntpd/ntpd.1@1.38, 2006-10-23 07:48:06-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.38 +2 -2 NTP_4_2_3P61_RC - ntpd/ntpdsim-opts.c@1.40, 2006-10-23 07:48:06-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.40 +2 -2 NTP_4_2_3P61_RC - ntpd/ntpdsim-opts.h@1.40, 2006-10-23 07:48:07-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.40 +3 -3 NTP_4_2_3P61_RC - ntpd/ntpdsim-opts.texi@1.38, 2006-10-23 07:48:08-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.38 +1 -1 NTP_4_2_3P61_RC - ntpd/ntpdsim.1@1.38, 2006-10-23 07:48:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.38 +2 -2 NTP_4_2_3P61_RC - ntpdc/ntpdc-opts.c@1.40, 2006-10-23 07:48:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.40 +2 -2 NTP_4_2_3P61_RC - ntpdc/ntpdc-opts.h@1.40, 2006-10-23 07:48:10-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.40 +3 -3 NTP_4_2_3P61_RC - ntpdc/ntpdc-opts.texi@1.38, 2006-10-23 07:48:11-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.38 +1 -1 NTP_4_2_3P61_RC - ntpdc/ntpdc.1@1.38, 2006-10-23 07:48:12-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.38 +2 -2 NTP_4_2_3P61_RC - ntpq/ntpq-opts.c@1.42, 2006-10-23 07:48:12-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.42 +2 -2 NTP_4_2_3P61_RC - ntpq/ntpq-opts.h@1.42, 2006-10-23 07:48:13-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.42 +3 -3 NTP_4_2_3P61_RC - ntpq/ntpq-opts.texi@1.39, 2006-10-23 07:48:14-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.39 +1 -1 NTP_4_2_3P61_RC - ntpq/ntpq.1@1.38, 2006-10-23 07:48:14-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.38 +2 -2 NTP_4_2_3P61_RC - packageinfo.sh@1.54, 2006-10-23 07:48:15-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.54 +1 -1 NTP_4_2_3P61_RC - sntp/sntp-opts.c@1.39, 2006-10-23 07:48:15-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.39 +2 -2 NTP_4_2_3P61_RC - sntp/sntp-opts.h@1.39, 2006-10-23 07:48:16-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.39 +3 -3 NTP_4_2_3P61_RC - sntp/sntp-opts.texi@1.36, 2006-10-23 07:48:17-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.36 +1 -1 NTP_4_2_3P61_RC - sntp/sntp.1@1.39, 2006-10-23 07:48:18-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.39 +2 -2 NTP_4_2_3P61_RC - util/ntp-keygen-opts.c@1.39, 2006-10-23 07:48:18-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.39 +2 -2 NTP_4_2_3P61_RC - util/ntp-keygen-opts.h@1.39, 2006-10-23 07:48:19-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.39 +3 -3 NTP_4_2_3P61_RC - util/ntp-keygen-opts.texi@1.37, 2006-10-23 07:48:20-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.37 +1 -1 NTP_4_2_3P61_RC - util/ntp-keygen.1@1.37, 2006-10-23 07:48:21-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.37 +2 -2 NTP_4_2_3P61_RC -ChangeSet@1.1395, 2006-10-23 00:38:50-04:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1395, 2006-10-23 00:38:50-04:00, stenn@pogo.udel.edu [Bug 666] ntpq opeers displays jitter rather than dispersion - NEWS@1.69, 2006-10-23 00:38:42-04:00, stenn@pogo.udel.edu +1 -0 + NEWS@1.69 +1 -0 [Bug 666] ntpq opeers displays jitter rather than dispersion - ntpq/ntpq-subs.c@1.25, 2006-10-23 00:37:58-04:00, stenn@pogo.udel.edu +3 -2 + ntpq/ntpq-subs.c@1.25 +3 -2 [Bug 666] ntpq opeers displays jitter rather than dispersion -ChangeSet@1.1379.12.3, 2006-10-20 07:45:30-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.12.3, 2006-10-20 07:45:30-04:00, stenn@whimsy.udel.edu NTP_4_2_3P60_RC TAG: NTP_4_2_3P60_RC - ntpd/ntpd-opts.c@1.39, 2006-10-20 07:45:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.39 +2 -2 NTP_4_2_3P60_RC - ntpd/ntpd-opts.h@1.39, 2006-10-20 07:45:09-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.39 +3 -3 NTP_4_2_3P60_RC - ntpd/ntpd-opts.texi@1.38, 2006-10-20 07:45:10-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.38 +1 -1 NTP_4_2_3P60_RC - ntpd/ntpd.1@1.37, 2006-10-20 07:45:10-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.37 +2 -2 NTP_4_2_3P60_RC - ntpd/ntpdsim-opts.c@1.39, 2006-10-20 07:45:12-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.39 +2 -2 NTP_4_2_3P60_RC - ntpd/ntpdsim-opts.h@1.39, 2006-10-20 07:45:13-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.39 +3 -3 NTP_4_2_3P60_RC - ntpd/ntpdsim-opts.texi@1.37, 2006-10-20 07:45:13-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.37 +1 -1 NTP_4_2_3P60_RC - ntpd/ntpdsim.1@1.37, 2006-10-20 07:45:14-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.37 +2 -2 NTP_4_2_3P60_RC - ntpdc/ntpdc-opts.c@1.39, 2006-10-20 07:45:15-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.39 +2 -2 NTP_4_2_3P60_RC - ntpdc/ntpdc-opts.h@1.39, 2006-10-20 07:45:15-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.39 +3 -3 NTP_4_2_3P60_RC - ntpdc/ntpdc-opts.texi@1.37, 2006-10-20 07:45:16-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.37 +1 -1 NTP_4_2_3P60_RC - ntpdc/ntpdc.1@1.37, 2006-10-20 07:45:17-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.37 +2 -2 NTP_4_2_3P60_RC - ntpq/ntpq-opts.c@1.41, 2006-10-20 07:45:17-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.41 +2 -2 NTP_4_2_3P60_RC - ntpq/ntpq-opts.h@1.41, 2006-10-20 07:45:18-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.41 +3 -3 NTP_4_2_3P60_RC - ntpq/ntpq-opts.texi@1.38, 2006-10-20 07:45:19-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.38 +1 -1 NTP_4_2_3P60_RC - ntpq/ntpq.1@1.37, 2006-10-20 07:45:19-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.37 +2 -2 NTP_4_2_3P60_RC - packageinfo.sh@1.53, 2006-10-20 07:45:20-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.53 +1 -1 NTP_4_2_3P60_RC - sntp/sntp-opts.c@1.38, 2006-10-20 07:45:20-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.38 +2 -2 NTP_4_2_3P60_RC - sntp/sntp-opts.h@1.38, 2006-10-20 07:45:22-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.38 +3 -3 NTP_4_2_3P60_RC - sntp/sntp-opts.texi@1.35, 2006-10-20 07:45:23-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.35 +1 -1 NTP_4_2_3P60_RC - sntp/sntp.1@1.38, 2006-10-20 07:45:23-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.38 +2 -2 NTP_4_2_3P60_RC - util/ntp-keygen-opts.c@1.38, 2006-10-20 07:45:24-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.38 +2 -2 NTP_4_2_3P60_RC - util/ntp-keygen-opts.h@1.38, 2006-10-20 07:45:25-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.38 +3 -3 NTP_4_2_3P60_RC - util/ntp-keygen-opts.texi@1.36, 2006-10-20 07:45:26-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.36 +1 -1 NTP_4_2_3P60_RC - util/ntp-keygen.1@1.36, 2006-10-20 07:45:27-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.36 +2 -2 NTP_4_2_3P60_RC -ChangeSet@1.1379.12.2, 2006-10-20 00:49:41-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.12.2, 2006-10-20 00:49:41-04:00, stenn@whimsy.udel.edu 4.2.4 Release Candidate - packageinfo.sh@1.52, 2006-10-20 00:49:29-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.52 +2 -2 4.2.4 Release Candidate -ChangeSet@1.1379.12.1, 2006-10-20 00:44:54-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.12.1, 2006-10-20 00:44:54-04:00, stenn@whimsy.udel.edu refclock_wwv.c fix from Dave Mills - ntpd/refclock_wwv.c@1.66, 2006-10-20 00:44:30-04:00, stenn@whimsy.udel.edu +3 -0 + ntpd/refclock_wwv.c@1.66 +3 -0 refclock_wwv.c fix from Dave Mills -ChangeSet@1.1379.1.53, 2006-10-15 14:25:15+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1379.1.53, 2006-10-15 14:25:15+00:00, kardel@pogo.udel.edu dcfd.c: cope with cases where sa_sigaction and sa_handler are in a union - parseutil/dcfd.c@1.19, 2006-10-15 14:24:55+00:00, kardel@pogo.udel.edu +1 -1 + parseutil/dcfd.c@1.19 +1 -1 cope with cases where sa_sigaction and sa_handler are in a union -ChangeSet@1.1379.1.52, 2006-10-15 07:42:15-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.52, 2006-10-15 07:42:15-04:00, stenn@whimsy.udel.edu NTP_4_2_3P59 TAG: NTP_4_2_3P59 - ntpd/ntpd-opts.c@1.38, 2006-10-15 07:41:54-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.38 +2 -2 NTP_4_2_3P59 - ntpd/ntpd-opts.h@1.38, 2006-10-15 07:41:54-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.38 +3 -3 NTP_4_2_3P59 - ntpd/ntpd-opts.texi@1.37, 2006-10-15 07:41:55-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.37 +1 -1 NTP_4_2_3P59 - ntpd/ntpd.1@1.36, 2006-10-15 07:41:55-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.36 +2 -2 NTP_4_2_3P59 - ntpd/ntpdsim-opts.c@1.38, 2006-10-15 07:41:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.38 +2 -2 NTP_4_2_3P59 - ntpd/ntpdsim-opts.h@1.38, 2006-10-15 07:41:57-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.38 +3 -3 NTP_4_2_3P59 - ntpd/ntpdsim-opts.texi@1.36, 2006-10-15 07:41:57-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.36 +1 -1 NTP_4_2_3P59 - ntpd/ntpdsim.1@1.36, 2006-10-15 07:41:58-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.36 +2 -2 NTP_4_2_3P59 - ntpdc/ntpdc-opts.c@1.38, 2006-10-15 07:41:59-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.38 +2 -2 NTP_4_2_3P59 - ntpdc/ntpdc-opts.h@1.38, 2006-10-15 07:41:59-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.38 +3 -3 NTP_4_2_3P59 - ntpdc/ntpdc-opts.texi@1.36, 2006-10-15 07:42:00-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.36 +1 -1 NTP_4_2_3P59 - ntpdc/ntpdc.1@1.36, 2006-10-15 07:42:01-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.36 +2 -2 NTP_4_2_3P59 - ntpq/ntpq-opts.c@1.40, 2006-10-15 07:42:01-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.40 +2 -2 NTP_4_2_3P59 - ntpq/ntpq-opts.h@1.40, 2006-10-15 07:42:03-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.40 +3 -3 NTP_4_2_3P59 - ntpq/ntpq-opts.texi@1.37, 2006-10-15 07:42:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.37 +1 -1 NTP_4_2_3P59 - ntpq/ntpq.1@1.36, 2006-10-15 07:42:04-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.36 +2 -2 NTP_4_2_3P59 - packageinfo.sh@1.51, 2006-10-15 07:42:05-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.51 +1 -1 NTP_4_2_3P59 - sntp/sntp-opts.c@1.37, 2006-10-15 07:42:05-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.37 +2 -2 NTP_4_2_3P59 - sntp/sntp-opts.h@1.37, 2006-10-15 07:42:06-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.37 +3 -3 NTP_4_2_3P59 - sntp/sntp-opts.texi@1.34, 2006-10-15 07:42:07-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.34 +1 -1 NTP_4_2_3P59 - sntp/sntp.1@1.37, 2006-10-15 07:42:08-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.37 +2 -2 NTP_4_2_3P59 - util/ntp-keygen-opts.c@1.37, 2006-10-15 07:42:09-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.37 +2 -2 NTP_4_2_3P59 - util/ntp-keygen-opts.h@1.37, 2006-10-15 07:42:10-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.37 +3 -3 NTP_4_2_3P59 - util/ntp-keygen-opts.texi@1.35, 2006-10-15 07:42:11-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.35 +1 -1 NTP_4_2_3P59 - util/ntp-keygen.1@1.35, 2006-10-15 07:42:11-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.35 +2 -2 NTP_4_2_3P59 -ChangeSet@1.1251.94.61, 2006-10-15 03:47:49-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.61, 2006-10-15 03:47:49-04:00, stenn@whimsy.udel.edu NTP_4_2_2P4 TAG: NTP_4_2_2P4 - packageinfo.sh@1.27.20.2, 2006-10-15 03:47:45-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.27.20.2 +2 -2 NTP_4_2_2P4 -ChangeSet@1.1251.94.60, 2006-10-15 03:14:15-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.60, 2006-10-15 03:14:15-04:00, stenn@whimsy.udel.edu Release 4.2.2p4 - packageinfo.sh@1.27.20.1, 2006-10-15 03:14:05-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.20.1 +1 -1 Release 4.2.2p4 -ChangeSet@1.1379.1.51, 2006-10-15 06:03:07+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1379.1.51, 2006-10-15 06:03:07+00:00, kardel@pogo.udel.edu ntp_io.c: Bug 715: Fix from Peter Pramberger do not send link scoped multicasts with a glocbal source address (if present on that interface) - ntpd/ntp_io.c@1.234.1.16, 2006-10-15 06:00:32+00:00, kardel@pogo.udel.edu +9 -2 + ntpd/ntp_io.c@1.234.1.16 +9 -2 Bug 715: Fix from Peter Pramberger do not send link scoped multicasts with a glocbal source address (if present on that interface) -ChangeSet@1.1379.1.50, 2006-10-14 07:41:41-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.50, 2006-10-14 07:41:41-04:00, stenn@whimsy.udel.edu NTP_4_2_3P58 TAG: NTP_4_2_3P58 - ntpd/ntpd-opts.c@1.37, 2006-10-14 07:41:22-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.37 +2 -2 NTP_4_2_3P58 - ntpd/ntpd-opts.h@1.37, 2006-10-14 07:41:23-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.37 +3 -3 NTP_4_2_3P58 - ntpd/ntpd-opts.texi@1.36, 2006-10-14 07:41:23-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.36 +1 -1 NTP_4_2_3P58 - ntpd/ntpd.1@1.35, 2006-10-14 07:41:24-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.35 +2 -2 NTP_4_2_3P58 - ntpd/ntpdsim-opts.c@1.37, 2006-10-14 07:41:25-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.37 +2 -2 NTP_4_2_3P58 - ntpd/ntpdsim-opts.h@1.37, 2006-10-14 07:41:25-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.37 +3 -3 NTP_4_2_3P58 - ntpd/ntpdsim-opts.texi@1.35, 2006-10-14 07:41:26-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.35 +1 -1 NTP_4_2_3P58 - ntpd/ntpdsim.1@1.35, 2006-10-14 07:41:26-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.35 +2 -2 NTP_4_2_3P58 - ntpdc/ntpdc-opts.c@1.37, 2006-10-14 07:41:27-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.37 +2 -2 NTP_4_2_3P58 - ntpdc/ntpdc-opts.h@1.37, 2006-10-14 07:41:27-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.37 +3 -3 NTP_4_2_3P58 - ntpdc/ntpdc-opts.texi@1.35, 2006-10-14 07:41:28-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.35 +1 -1 NTP_4_2_3P58 - ntpdc/ntpdc.1@1.35, 2006-10-14 07:41:29-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.35 +2 -2 NTP_4_2_3P58 - ntpq/ntpq-opts.c@1.39, 2006-10-14 07:41:29-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.39 +2 -2 NTP_4_2_3P58 - ntpq/ntpq-opts.h@1.39, 2006-10-14 07:41:30-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.39 +3 -3 NTP_4_2_3P58 - ntpq/ntpq-opts.texi@1.36, 2006-10-14 07:41:31-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.36 +1 -1 NTP_4_2_3P58 - ntpq/ntpq.1@1.35, 2006-10-14 07:41:32-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.35 +2 -2 NTP_4_2_3P58 - packageinfo.sh@1.50, 2006-10-14 07:41:32-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.50 +1 -1 NTP_4_2_3P58 - sntp/sntp-opts.c@1.36, 2006-10-14 07:41:33-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.36 +2 -2 NTP_4_2_3P58 - sntp/sntp-opts.h@1.36, 2006-10-14 07:41:34-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.36 +3 -3 NTP_4_2_3P58 - sntp/sntp-opts.texi@1.33, 2006-10-14 07:41:34-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.33 +1 -1 NTP_4_2_3P58 - sntp/sntp.1@1.36, 2006-10-14 07:41:35-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.36 +2 -2 NTP_4_2_3P58 - util/ntp-keygen-opts.c@1.36, 2006-10-14 07:41:36-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.36 +2 -2 NTP_4_2_3P58 - util/ntp-keygen-opts.h@1.36, 2006-10-14 07:41:36-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.36 +3 -3 NTP_4_2_3P58 - util/ntp-keygen-opts.texi@1.34, 2006-10-14 07:41:37-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.34 +1 -1 NTP_4_2_3P58 - util/ntp-keygen.1@1.34, 2006-10-14 07:41:38-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.34 +2 -2 NTP_4_2_3P58 -ChangeSet@1.1379.1.49, 2006-10-14 08:51:43+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1379.1.49, 2006-10-14 08:51:43+00:00, kardel@pogo.udel.edu ntp_io.c: Bug #715 (& dupe 723): findlocalinterface() in update_interface can be replaced by @@ -7413,7 +188180,7 @@ ChangeSet@1.1379.1.49, 2006-10-14 08:51:43+00:00, kardel@pogo.udel.edu +1 -0 avoid adding duplicate address entries to the address list declare more functions static to reduce name space pollution - ntpd/ntp_io.c@1.234.1.15, 2006-10-14 08:30:08+00:00, kardel@pogo.udel.edu +107 -81 + ntpd/ntp_io.c@1.234.1.15 +107 -81 Bug #715 (& dupe 723): findlocalinterface() in update_interface can be replaced by a simple address to interface lookup. This avoids tripping @@ -7424,1949 +188191,1949 @@ ChangeSet@1.1379.1.49, 2006-10-14 08:51:43+00:00, kardel@pogo.udel.edu +1 -0 avoid adding duplicate address entries to the address list declare more functions static to reduce name space pollution -ChangeSet@1.1379.1.48, 2006-10-13 07:48:30-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.48, 2006-10-13 07:48:30-04:00, stenn@whimsy.udel.edu NTP_4_2_3P57 TAG: NTP_4_2_3P57 - ntpd/ntpd-opts.c@1.36, 2006-10-13 07:48:10-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpd-opts.c@1.36 +4 -4 NTP_4_2_3P57 - ntpd/ntpd-opts.h@1.36, 2006-10-13 07:48:10-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.36 +3 -3 NTP_4_2_3P57 - ntpd/ntpd-opts.texi@1.35, 2006-10-13 07:48:11-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.35 +3 -3 NTP_4_2_3P57 - ntpd/ntpd.1@1.34, 2006-10-13 07:48:12-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.34 +2 -2 NTP_4_2_3P57 - ntpd/ntpdsim-opts.c@1.36, 2006-10-13 07:48:12-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpdsim-opts.c@1.36 +4 -4 NTP_4_2_3P57 - ntpd/ntpdsim-opts.h@1.36, 2006-10-13 07:48:13-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.36 +3 -3 NTP_4_2_3P57 - ntpd/ntpdsim-opts.texi@1.34, 2006-10-13 07:48:14-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.texi@1.34 +3 -3 NTP_4_2_3P57 - ntpd/ntpdsim.1@1.34, 2006-10-13 07:48:14-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.34 +2 -2 NTP_4_2_3P57 - ntpdc/ntpdc-opts.c@1.36, 2006-10-13 07:48:15-04:00, stenn@whimsy.udel.edu +4 -4 + ntpdc/ntpdc-opts.c@1.36 +4 -4 NTP_4_2_3P57 - ntpdc/ntpdc-opts.h@1.36, 2006-10-13 07:48:16-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.36 +3 -3 NTP_4_2_3P57 - ntpdc/ntpdc-opts.texi@1.34, 2006-10-13 07:48:16-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.34 +2 -2 NTP_4_2_3P57 - ntpdc/ntpdc.1@1.34, 2006-10-13 07:48:17-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.34 +2 -2 NTP_4_2_3P57 - ntpq/ntpq-opts.c@1.38, 2006-10-13 07:48:18-04:00, stenn@whimsy.udel.edu +4 -4 + ntpq/ntpq-opts.c@1.38 +4 -4 NTP_4_2_3P57 - ntpq/ntpq-opts.h@1.38, 2006-10-13 07:48:18-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.38 +3 -3 NTP_4_2_3P57 - ntpq/ntpq-opts.texi@1.35, 2006-10-13 07:48:19-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.35 +3 -3 NTP_4_2_3P57 - ntpq/ntpq.1@1.34, 2006-10-13 07:48:19-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.34 +2 -2 NTP_4_2_3P57 - packageinfo.sh@1.49, 2006-10-13 07:48:20-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.49 +1 -1 NTP_4_2_3P57 - sntp/sntp-opts.c@1.35, 2006-10-13 07:48:21-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.35 +2 -2 NTP_4_2_3P57 - sntp/sntp-opts.h@1.35, 2006-10-13 07:48:22-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.35 +3 -3 NTP_4_2_3P57 - sntp/sntp-opts.texi@1.32, 2006-10-13 07:48:22-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.32 +1 -1 NTP_4_2_3P57 - sntp/sntp.1@1.35, 2006-10-13 07:48:23-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.35 +2 -2 NTP_4_2_3P57 - util/ntp-keygen-opts.c@1.35, 2006-10-13 07:48:24-04:00, stenn@whimsy.udel.edu +4 -4 + util/ntp-keygen-opts.c@1.35 +4 -4 NTP_4_2_3P57 - util/ntp-keygen-opts.h@1.35, 2006-10-13 07:48:25-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.35 +3 -3 NTP_4_2_3P57 - util/ntp-keygen-opts.texi@1.33, 2006-10-13 07:48:26-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.33 +2 -2 NTP_4_2_3P57 - util/ntp-keygen.1@1.33, 2006-10-13 07:48:27-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.33 +2 -2 NTP_4_2_3P57 -ChangeSet@1.1379.1.47, 2006-10-12 23:32:07-04:00, stenn@whimsy.udel.edu +24 -0 +ChangeSet@1.1379.1.47, 2006-10-12 23:32:07-04:00, stenn@whimsy.udel.edu Autogen-5.8.7 upgrade - clockstuff/clktest-opts.c@1.9, 2006-10-12 23:31:35-04:00, stenn@whimsy.udel.edu +1 -1 + clockstuff/clktest-opts.c@1.9 +1 -1 Autogen-5.8.7 upgrade - clockstuff/clktest-opts.h@1.9, 2006-10-12 23:31:36-04:00, stenn@whimsy.udel.edu +1 -1 + clockstuff/clktest-opts.h@1.9 +1 -1 Autogen-5.8.7 upgrade - ntpd/ntpd-opts.c@1.35, 2006-10-12 23:31:37-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.c@1.35 +1 -1 Autogen-5.8.7 upgrade - ntpd/ntpd-opts.h@1.35, 2006-10-12 23:31:37-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.h@1.35 +1 -1 Autogen-5.8.7 upgrade - ntpd/ntpd-opts.texi@1.34, 2006-10-12 23:31:38-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.34 +3 -3 Autogen-5.8.7 upgrade - ntpd/ntpd.1@1.33, 2006-10-12 23:31:39-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd.1@1.33 +1 -1 Autogen-5.8.7 upgrade - ntpd/ntpdsim-opts.c@1.35, 2006-10-12 23:31:40-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.c@1.35 +1 -1 Autogen-5.8.7 upgrade - ntpd/ntpdsim-opts.h@1.35, 2006-10-12 23:31:41-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.h@1.35 +1 -1 Autogen-5.8.7 upgrade - ntpd/ntpdsim-opts.texi@1.33, 2006-10-12 23:31:41-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.texi@1.33 +3 -3 Autogen-5.8.7 upgrade - ntpd/ntpdsim.1@1.33, 2006-10-12 23:31:42-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim.1@1.33 +1 -1 Autogen-5.8.7 upgrade - ntpdc/ntpdc-opts.c@1.35, 2006-10-12 23:31:43-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.c@1.35 +1 -1 Autogen-5.8.7 upgrade - ntpdc/ntpdc-opts.h@1.35, 2006-10-12 23:31:44-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.h@1.35 +1 -1 Autogen-5.8.7 upgrade - ntpdc/ntpdc-opts.texi@1.33, 2006-10-12 23:31:44-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.33 +2 -2 Autogen-5.8.7 upgrade - ntpdc/ntpdc.1@1.33, 2006-10-12 23:31:45-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc.1@1.33 +1 -1 Autogen-5.8.7 upgrade - ntpq/ntpq-opts.c@1.37, 2006-10-12 23:31:46-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.c@1.37 +1 -1 Autogen-5.8.7 upgrade - ntpq/ntpq-opts.h@1.37, 2006-10-12 23:31:46-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.h@1.37 +1 -1 Autogen-5.8.7 upgrade - ntpq/ntpq-opts.texi@1.34, 2006-10-12 23:31:48-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.34 +3 -3 Autogen-5.8.7 upgrade - ntpq/ntpq.1@1.33, 2006-10-12 23:31:48-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq.1@1.33 +1 -1 Autogen-5.8.7 upgrade - sntp/sntp-opts.c@1.34, 2006-10-12 23:31:49-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.c@1.34 +1 -1 Autogen-5.8.7 upgrade - sntp/sntp-opts.h@1.34, 2006-10-12 23:31:50-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.h@1.34 +1 -1 Autogen-5.8.7 upgrade - util/ntp-keygen-opts.c@1.34, 2006-10-12 23:31:51-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.c@1.34 +1 -1 Autogen-5.8.7 upgrade - util/ntp-keygen-opts.h@1.34, 2006-10-12 23:31:52-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.h@1.34 +1 -1 Autogen-5.8.7 upgrade - util/ntp-keygen-opts.texi@1.32, 2006-10-12 23:31:53-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.32 +2 -2 Autogen-5.8.7 upgrade - util/ntp-keygen.1@1.32, 2006-10-12 23:31:53-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen.1@1.32 +1 -1 Autogen-5.8.7 upgrade -ChangeSet@1.1379.1.46, 2006-10-12 23:29:11-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.46, 2006-10-12 23:29:11-04:00, stenn@whimsy.udel.edu Require autogen-5.8.7 - include/autogen-version.def@1.3, 2006-10-12 23:28:59-04:00, stenn@whimsy.udel.edu +1 -1 + include/autogen-version.def@1.3 +1 -1 Require autogen-5.8.7 -ChangeSet@1.1379.1.45, 2006-10-12 22:46:49-04:00, stenn@whimsy.udel.edu +14 -0 +ChangeSet@1.1379.1.45, 2006-10-12 22:46:49-04:00, stenn@whimsy.udel.edu Autogen-5.8.7 upgrade - clockstuff/clktest-opts.c@1.8, 2006-10-12 22:46:22-04:00, stenn@whimsy.udel.edu +2 -2 + clockstuff/clktest-opts.c@1.8 +2 -2 Autogen-5.8.7 upgrade - clockstuff/clktest-opts.h@1.8, 2006-10-12 22:46:23-04:00, stenn@whimsy.udel.edu +3 -3 + clockstuff/clktest-opts.h@1.8 +3 -3 Autogen-5.8.7 upgrade - ntpd/ntpd-opts.c@1.34, 2006-10-12 22:46:23-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.c@1.34 +3 -3 Autogen-5.8.7 upgrade - ntpd/ntpd-opts.h@1.34, 2006-10-12 22:46:24-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.h@1.34 +1 -1 Autogen-5.8.7 upgrade - ntpd/ntpdsim-opts.c@1.34, 2006-10-12 22:46:25-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.c@1.34 +3 -3 Autogen-5.8.7 upgrade - ntpd/ntpdsim-opts.h@1.34, 2006-10-12 22:46:26-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.h@1.34 +1 -1 Autogen-5.8.7 upgrade - ntpdc/ntpdc-opts.c@1.34, 2006-10-12 22:46:27-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.c@1.34 +3 -3 Autogen-5.8.7 upgrade - ntpdc/ntpdc-opts.h@1.34, 2006-10-12 22:46:28-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.h@1.34 +1 -1 Autogen-5.8.7 upgrade - ntpq/ntpq-opts.c@1.36, 2006-10-12 22:46:30-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.c@1.36 +3 -3 Autogen-5.8.7 upgrade - ntpq/ntpq-opts.h@1.36, 2006-10-12 22:46:31-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.h@1.36 +1 -1 Autogen-5.8.7 upgrade - sntp/sntp-opts.c@1.33, 2006-10-12 22:46:32-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.c@1.33 +1 -1 Autogen-5.8.7 upgrade - sntp/sntp-opts.h@1.33, 2006-10-12 22:46:33-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.h@1.33 +1 -1 Autogen-5.8.7 upgrade - util/ntp-keygen-opts.c@1.33, 2006-10-12 22:46:34-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.c@1.33 +3 -3 Autogen-5.8.7 upgrade - util/ntp-keygen-opts.h@1.33, 2006-10-12 22:46:35-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.h@1.33 +1 -1 Autogen-5.8.7 upgrade -ChangeSet@1.1379.1.44, 2006-10-12 22:42:48-04:00, stenn@whimsy.udel.edu +62 -0 +ChangeSet@1.1379.1.44, 2006-10-12 22:42:48-04:00, stenn@whimsy.udel.edu autogen-5.8.7 upgrade - libopts/autoopts.c@1.10, 2006-10-12 22:41:36-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts.c@1.10 +1 -1 autogen-5.8.7 upgrade - libopts/autoopts.h@1.9, 2006-10-12 22:41:37-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts.h@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/autoopts/options.h@1.10, 2006-10-12 22:41:33-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/autoopts/options.h@1.10 +2 -2 autogen-5.8.7 upgrade - libopts/autoopts/usage-txt.h@1.9, 2006-10-12 22:41:34-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts/usage-txt.h@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/boolean.c@1.8, 2006-10-12 22:41:39-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/boolean.c@1.8 +1 -1 autogen-5.8.7 upgrade - libopts/compat/compat.h@1.12, 2006-10-12 22:41:39-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/compat/compat.h@1.12 +1 -1 autogen-5.8.7 upgrade - libopts/compat/pathfind.c@1.9, 2006-10-12 22:41:41-04:00, stenn@whimsy.udel.edu +2 -3 + libopts/compat/pathfind.c@1.9 +2 -3 autogen-5.8.7 upgrade - libopts/compat/windows-config.h@1.5, 2006-10-12 22:41:43-04:00, stenn@whimsy.udel.edu +8 -2 + libopts/compat/windows-config.h@1.5 +8 -2 autogen-5.8.7 upgrade - libopts/configfile.c@1.10, 2006-10-12 22:41:44-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/configfile.c@1.10 +1 -1 autogen-5.8.7 upgrade - libopts/cook.c@1.9, 2006-10-12 22:41:46-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/cook.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/enumeration.c@1.9, 2006-10-12 22:41:47-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/enumeration.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/environment.c@1.8, 2006-10-12 22:41:48-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/environment.c@1.8 +1 -1 autogen-5.8.7 upgrade - libopts/genshell.c@1.9, 2006-10-12 22:41:50-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/genshell.h@1.9, 2006-10-12 22:41:51-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.h@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/load.c@1.10, 2006-10-12 22:41:52-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/load.c@1.10 +1 -1 autogen-5.8.7 upgrade - libopts/m4/libopts.m4@1.14, 2006-10-12 22:41:54-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/m4/libopts.m4@1.14 +2 -2 autogen-5.8.7 upgrade - libopts/m4/liboptschk.m4@1.3, 2006-10-12 22:41:55-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/m4/liboptschk.m4@1.3 +1 -1 autogen-5.8.7 upgrade - libopts/makeshell.c@1.11, 2006-10-12 22:41:56-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/makeshell.c@1.11 +1 -1 autogen-5.8.7 upgrade - libopts/nested.c@1.9, 2006-10-12 22:41:58-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/nested.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/numeric.c@1.9, 2006-10-12 22:41:59-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/numeric.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/pgusage.c@1.9, 2006-10-12 22:42:00-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/pgusage.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/proto.h@1.11, 2006-10-12 22:42:01-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/proto.h@1.11 +1 -1 autogen-5.8.7 upgrade - libopts/putshell.c@1.10, 2006-10-12 22:42:01-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/putshell.c@1.10 +1 -1 autogen-5.8.7 upgrade - libopts/restore.c@1.9, 2006-10-12 22:42:03-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/restore.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/save.c@1.10, 2006-10-12 22:42:05-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/save.c@1.10 +1 -1 autogen-5.8.7 upgrade - libopts/sort.c@1.8, 2006-10-12 22:42:07-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/sort.c@1.8 +1 -1 autogen-5.8.7 upgrade - libopts/stack.c@1.10, 2006-10-12 22:42:08-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/stack.c@1.10 +1 -1 autogen-5.8.7 upgrade - libopts/streqvcmp.c@1.9, 2006-10-12 22:42:10-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/streqvcmp.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/text_mmap.c@1.8, 2006-10-12 22:42:11-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/text_mmap.c@1.8 +1 -1 autogen-5.8.7 upgrade - libopts/usage.c@1.9, 2006-10-12 22:42:13-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/usage.c@1.9 +1 -1 autogen-5.8.7 upgrade - libopts/version.c@1.9, 2006-10-12 22:42:15-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/version.c@1.9 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/autoopts.c@1.7, 2006-10-12 22:41:36-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/autoopts.c@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/autoopts.h@1.7, 2006-10-12 22:41:38-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/autoopts.h@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/autoopts/options.h@1.7, 2006-10-12 22:41:33-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/autoopts/options.h@1.7 +2 -2 autogen-5.8.7 upgrade - sntp/libopts/autoopts/usage-txt.h@1.6, 2006-10-12 22:41:35-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/autoopts/usage-txt.h@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/boolean.c@1.5, 2006-10-12 22:41:39-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/boolean.c@1.5 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/compat/compat.h@1.8, 2006-10-12 22:41:40-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/compat/compat.h@1.8 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/compat/pathfind.c@1.6, 2006-10-12 22:41:42-04:00, stenn@whimsy.udel.edu +2 -3 + sntp/libopts/compat/pathfind.c@1.6 +2 -3 autogen-5.8.7 upgrade - sntp/libopts/compat/windows-config.h@1.3, 2006-10-12 22:41:43-04:00, stenn@whimsy.udel.edu +8 -2 + sntp/libopts/compat/windows-config.h@1.3 +8 -2 autogen-5.8.7 upgrade - sntp/libopts/configfile.c@1.7, 2006-10-12 22:41:45-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/configfile.c@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/cook.c@1.6, 2006-10-12 22:41:47-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/cook.c@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/enumeration.c@1.6, 2006-10-12 22:41:48-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/enumeration.c@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/environment.c@1.5, 2006-10-12 22:41:49-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/environment.c@1.5 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/genshell.c@1.6, 2006-10-12 22:41:50-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/genshell.c@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/genshell.h@1.6, 2006-10-12 22:41:52-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/genshell.h@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/load.c@1.7, 2006-10-12 22:41:54-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/load.c@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/m4/libopts.m4@1.11, 2006-10-12 22:41:55-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/m4/libopts.m4@1.11 +2 -2 autogen-5.8.7 upgrade - sntp/libopts/m4/liboptschk.m4@1.3, 2006-10-12 22:41:56-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/m4/liboptschk.m4@1.3 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/makeshell.c@1.8, 2006-10-12 22:41:57-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/makeshell.c@1.8 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/nested.c@1.6, 2006-10-12 22:41:59-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/nested.c@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/numeric.c@1.6, 2006-10-12 22:42:00-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/numeric.c@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/pgusage.c@1.5, 2006-10-12 22:42:00-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/pgusage.c@1.5 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/proto.h@1.8, 2006-10-12 22:42:01-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/proto.h@1.8 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/putshell.c@1.7, 2006-10-12 22:42:02-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/putshell.c@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/restore.c@1.5, 2006-10-12 22:42:04-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/restore.c@1.5 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/save.c@1.7, 2006-10-12 22:42:06-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/save.c@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/sort.c@1.4, 2006-10-12 22:42:07-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/sort.c@1.4 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/stack.c@1.7, 2006-10-12 22:42:09-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/stack.c@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/streqvcmp.c@1.6, 2006-10-12 22:42:10-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/streqvcmp.c@1.6 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/text_mmap.c@1.5, 2006-10-12 22:42:12-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/text_mmap.c@1.5 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/usage.c@1.7, 2006-10-12 22:42:14-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/usage.c@1.7 +1 -1 autogen-5.8.7 upgrade - sntp/libopts/version.c@1.6, 2006-10-12 22:42:15-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/version.c@1.6 +1 -1 autogen-5.8.7 upgrade -ChangeSet@1.1379.1.43, 2006-10-12 19:22:09-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.43, 2006-10-12 19:22:09-04:00, stenn@whimsy.udel.edu Improve the getsockname() arg determination - configure.ac@1.388.1.13, 2006-10-12 19:21:57-04:00, stenn@whimsy.udel.edu +10 -6 + configure.ac@1.388.1.13 +10 -6 Improve the getsockname() arg determination -ChangeSet@1.1379.1.42, 2006-10-12 07:40:55-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.42, 2006-10-12 07:40:55-04:00, stenn@whimsy.udel.edu NTP_4_2_3P56 TAG: NTP_4_2_3P56 - ntpd/ntpd-opts.c@1.33, 2006-10-12 07:40:34-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.33 +2 -2 NTP_4_2_3P56 - ntpd/ntpd-opts.h@1.33, 2006-10-12 07:40:35-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.33 +3 -3 NTP_4_2_3P56 - ntpd/ntpd-opts.texi@1.33, 2006-10-12 07:40:36-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.33 +1 -1 NTP_4_2_3P56 - ntpd/ntpd.1@1.32, 2006-10-12 07:40:36-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.32 +2 -2 NTP_4_2_3P56 - ntpd/ntpdsim-opts.c@1.33, 2006-10-12 07:40:37-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.33 +2 -2 NTP_4_2_3P56 - ntpd/ntpdsim-opts.h@1.33, 2006-10-12 07:40:38-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.33 +3 -3 NTP_4_2_3P56 - ntpd/ntpdsim-opts.texi@1.32, 2006-10-12 07:40:38-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.32 +1 -1 NTP_4_2_3P56 - ntpd/ntpdsim.1@1.32, 2006-10-12 07:40:39-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.32 +2 -2 NTP_4_2_3P56 - ntpdc/ntpdc-opts.c@1.33, 2006-10-12 07:40:39-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.33 +2 -2 NTP_4_2_3P56 - ntpdc/ntpdc-opts.h@1.33, 2006-10-12 07:40:40-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.33 +3 -3 NTP_4_2_3P56 - ntpdc/ntpdc-opts.texi@1.32, 2006-10-12 07:40:40-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.32 +1 -1 NTP_4_2_3P56 - ntpdc/ntpdc.1@1.32, 2006-10-12 07:40:41-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.32 +2 -2 NTP_4_2_3P56 - ntpq/ntpq-opts.c@1.35, 2006-10-12 07:40:42-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.35 +2 -2 NTP_4_2_3P56 - ntpq/ntpq-opts.h@1.35, 2006-10-12 07:40:42-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.35 +3 -3 NTP_4_2_3P56 - ntpq/ntpq-opts.texi@1.33, 2006-10-12 07:40:43-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.33 +1 -1 NTP_4_2_3P56 - ntpq/ntpq.1@1.32, 2006-10-12 07:40:44-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.32 +2 -2 NTP_4_2_3P56 - packageinfo.sh@1.48, 2006-10-12 07:40:45-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.48 +1 -1 NTP_4_2_3P56 - sntp/sntp-opts.c@1.32, 2006-10-12 07:40:45-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.32 +2 -2 NTP_4_2_3P56 - sntp/sntp-opts.h@1.32, 2006-10-12 07:40:47-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.32 +3 -3 NTP_4_2_3P56 - sntp/sntp-opts.texi@1.31, 2006-10-12 07:40:48-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.31 +1 -1 NTP_4_2_3P56 - sntp/sntp.1@1.34, 2006-10-12 07:40:48-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.34 +2 -2 NTP_4_2_3P56 - util/ntp-keygen-opts.c@1.32, 2006-10-12 07:40:50-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.32 +2 -2 NTP_4_2_3P56 - util/ntp-keygen-opts.h@1.32, 2006-10-12 07:40:51-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.32 +3 -3 NTP_4_2_3P56 - util/ntp-keygen-opts.texi@1.31, 2006-10-12 07:40:51-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.31 +1 -1 NTP_4_2_3P56 - util/ntp-keygen.1@1.31, 2006-10-12 07:40:52-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.31 +2 -2 NTP_4_2_3P56 -ChangeSet@1.1379.1.41, 2006-10-12 02:30:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.41, 2006-10-12 02:30:52-04:00, stenn@whimsy.udel.edu Update NEWS file - NEWS@1.68, 2006-10-12 02:30:41-04:00, stenn@whimsy.udel.edu +36 -0 + NEWS@1.68 +36 -0 Update NEWS file -ChangeSet@1.1379.11.2, 2006-10-11 22:40:46-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.11.2, 2006-10-11 22:40:46-04:00, mayer@pogo.udel.edu Bug #690. Purify memory reference error - ports/winnt/libntp/dnslookup.c@1.4.1.4, 2006-10-11 22:40:27-04:00, mayer@pogo.udel.edu +4 -3 + ports/winnt/libntp/dnslookup.c@1.4.1.4 +4 -3 Bug #690. Purify memory reference error -ChangeSet@1.1379.11.1, 2006-10-11 22:39:16-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.11.1, 2006-10-11 22:39:16-04:00, mayer@pogo.udel.edu Bug #718. Update to config.h to deal with socklen_t - ports/winnt/include/config.h@1.44, 2006-10-11 22:38:35-04:00, mayer@pogo.udel.edu +13 -0 + ports/winnt/include/config.h@1.44 +13 -0 Bug #718. Update to config.h to deal with socklen_t -ChangeSet@1.1379.1.39, 2006-10-11 07:44:18-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.39, 2006-10-11 07:44:18-04:00, stenn@whimsy.udel.edu NTP_4_2_3P55 TAG: NTP_4_2_3P55 - ntpd/ntpd-opts.c@1.32, 2006-10-11 07:43:59-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.32 +2 -2 NTP_4_2_3P55 - ntpd/ntpd-opts.h@1.32, 2006-10-11 07:44:00-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.32 +3 -3 NTP_4_2_3P55 - ntpd/ntpd-opts.texi@1.32, 2006-10-11 07:44:00-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.32 +1 -1 NTP_4_2_3P55 - ntpd/ntpd.1@1.31, 2006-10-11 07:44:00-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.31 +2 -2 NTP_4_2_3P55 - ntpd/ntpdsim-opts.c@1.32, 2006-10-11 07:44:01-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.32 +2 -2 NTP_4_2_3P55 - ntpd/ntpdsim-opts.h@1.32, 2006-10-11 07:44:02-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.32 +3 -3 NTP_4_2_3P55 - ntpd/ntpdsim-opts.texi@1.31, 2006-10-11 07:44:03-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.31 +1 -1 NTP_4_2_3P55 - ntpd/ntpdsim.1@1.31, 2006-10-11 07:44:03-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.31 +2 -2 NTP_4_2_3P55 - ntpdc/ntpdc-opts.c@1.32, 2006-10-11 07:44:04-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.32 +2 -2 NTP_4_2_3P55 - ntpdc/ntpdc-opts.h@1.32, 2006-10-11 07:44:04-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.32 +3 -3 NTP_4_2_3P55 - ntpdc/ntpdc-opts.texi@1.31, 2006-10-11 07:44:05-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.31 +1 -1 NTP_4_2_3P55 - ntpdc/ntpdc.1@1.31, 2006-10-11 07:44:06-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.31 +2 -2 NTP_4_2_3P55 - ntpq/ntpq-opts.c@1.34, 2006-10-11 07:44:06-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.34 +2 -2 NTP_4_2_3P55 - ntpq/ntpq-opts.h@1.34, 2006-10-11 07:44:07-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.34 +3 -3 NTP_4_2_3P55 - ntpq/ntpq-opts.texi@1.32, 2006-10-11 07:44:08-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.32 +1 -1 NTP_4_2_3P55 - ntpq/ntpq.1@1.31, 2006-10-11 07:44:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.31 +2 -2 NTP_4_2_3P55 - packageinfo.sh@1.47, 2006-10-11 07:44:09-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.47 +1 -1 NTP_4_2_3P55 - sntp/sntp-opts.c@1.31, 2006-10-11 07:44:10-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.31 +2 -2 NTP_4_2_3P55 - sntp/sntp-opts.h@1.31, 2006-10-11 07:44:11-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.31 +3 -3 NTP_4_2_3P55 - sntp/sntp-opts.texi@1.30, 2006-10-11 07:44:12-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.30 +1 -1 NTP_4_2_3P55 - sntp/sntp.1@1.33, 2006-10-11 07:44:12-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.33 +2 -2 NTP_4_2_3P55 - util/ntp-keygen-opts.c@1.31, 2006-10-11 07:44:13-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.31 +2 -2 NTP_4_2_3P55 - util/ntp-keygen-opts.h@1.31, 2006-10-11 07:44:13-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.31 +3 -3 NTP_4_2_3P55 - util/ntp-keygen-opts.texi@1.30, 2006-10-11 07:44:15-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.30 +1 -1 NTP_4_2_3P55 - util/ntp-keygen.1@1.30, 2006-10-11 07:44:15-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.30 +2 -2 NTP_4_2_3P55 -ChangeSet@1.1379.1.37, 2006-10-10 19:52:42-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1379.1.37, 2006-10-10 19:52:42-04:00, stenn@whimsy.udel.edu [Bug 718] Determine/use the correct type of saddrlen for getsockname() - configure.ac@1.388.1.12, 2006-10-10 19:52:28-04:00, stenn@whimsy.udel.edu +23 -1 + configure.ac@1.388.1.12 +23 -1 [Bug 718] Determine/use the correct type of saddrlen for getsockname() - libisc/net.c@1.8, 2006-10-10 19:52:28-04:00, stenn@whimsy.udel.edu +2 -2 + libisc/net.c@1.8 +2 -2 [Bug 718] Determine/use the correct type of saddrlen for getsockname() - ntpd/ntp_io.c@1.234.1.14, 2006-10-10 19:52:29-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_io.c@1.234.1.14 +1 -1 [Bug 718] Determine/use the correct type of saddrlen for getsockname() -ChangeSet@1.1379.10.1, 2006-10-10 16:15:47+00:00, burnicki@pogo.udel.edu +1 -0 +ChangeSet@1.1379.10.1, 2006-10-10 16:15:47+00:00, burnicki@pogo.udel.edu [Bug 708] nt_clockstuff.c has unintentionally been messed up with the previous changeset. This is the correct version. - ports/winnt/ntpd/nt_clockstuff.c@1.23, 2006-10-10 16:15:44+00:00, burnicki@pogo.udel.edu +574 -249 + ports/winnt/ntpd/nt_clockstuff.c@1.23 +574 -249 Oops, this file has unintentionally been messed up with the previous changeset. This is the correct version. -ChangeSet@1.1379.1.36, 2006-10-10 07:46:00-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.36, 2006-10-10 07:46:00-04:00, stenn@whimsy.udel.edu NTP_4_2_3P54 TAG: NTP_4_2_3P54 - ntpd/ntpd-opts.c@1.31, 2006-10-10 07:45:36-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.31 +2 -2 NTP_4_2_3P54 - ntpd/ntpd-opts.h@1.31, 2006-10-10 07:45:37-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.31 +3 -3 NTP_4_2_3P54 - ntpd/ntpd-opts.texi@1.31, 2006-10-10 07:45:37-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.31 +1 -1 NTP_4_2_3P54 - ntpd/ntpd.1@1.30, 2006-10-10 07:45:38-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.30 +2 -2 NTP_4_2_3P54 - ntpd/ntpdsim-opts.c@1.31, 2006-10-10 07:45:39-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.31 +2 -2 NTP_4_2_3P54 - ntpd/ntpdsim-opts.h@1.31, 2006-10-10 07:45:40-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.31 +3 -3 NTP_4_2_3P54 - ntpd/ntpdsim-opts.texi@1.30, 2006-10-10 07:45:40-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.30 +1 -1 NTP_4_2_3P54 - ntpd/ntpdsim.1@1.30, 2006-10-10 07:45:41-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.30 +2 -2 NTP_4_2_3P54 - ntpdc/ntpdc-opts.c@1.31, 2006-10-10 07:45:41-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.31 +2 -2 NTP_4_2_3P54 - ntpdc/ntpdc-opts.h@1.31, 2006-10-10 07:45:42-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.31 +3 -3 NTP_4_2_3P54 - ntpdc/ntpdc-opts.texi@1.30, 2006-10-10 07:45:43-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.30 +1 -1 NTP_4_2_3P54 - ntpdc/ntpdc.1@1.30, 2006-10-10 07:45:44-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.30 +2 -2 NTP_4_2_3P54 - ntpq/ntpq-opts.c@1.33, 2006-10-10 07:45:44-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.33 +2 -2 NTP_4_2_3P54 - ntpq/ntpq-opts.h@1.33, 2006-10-10 07:45:45-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.33 +3 -3 NTP_4_2_3P54 - ntpq/ntpq-opts.texi@1.31, 2006-10-10 07:45:46-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.31 +1 -1 NTP_4_2_3P54 - ntpq/ntpq.1@1.30, 2006-10-10 07:45:47-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.30 +2 -2 NTP_4_2_3P54 - packageinfo.sh@1.46, 2006-10-10 07:45:47-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.46 +1 -1 NTP_4_2_3P54 - sntp/sntp-opts.c@1.30, 2006-10-10 07:45:48-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.30 +2 -2 NTP_4_2_3P54 - sntp/sntp-opts.h@1.30, 2006-10-10 07:45:49-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.30 +3 -3 NTP_4_2_3P54 - sntp/sntp-opts.texi@1.29, 2006-10-10 07:45:50-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.29 +1 -1 NTP_4_2_3P54 - sntp/sntp.1@1.32, 2006-10-10 07:45:51-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.32 +2 -2 NTP_4_2_3P54 - util/ntp-keygen-opts.c@1.30, 2006-10-10 07:45:52-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.30 +2 -2 NTP_4_2_3P54 - util/ntp-keygen-opts.h@1.30, 2006-10-10 07:45:52-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.30 +3 -3 NTP_4_2_3P54 - util/ntp-keygen-opts.texi@1.29, 2006-10-10 07:45:53-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.29 +1 -1 NTP_4_2_3P54 - util/ntp-keygen.1@1.29, 2006-10-10 07:45:54-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.29 +2 -2 NTP_4_2_3P54 -ChangeSet@1.1379.1.35, 2006-10-10 02:39:26-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1379.1.35, 2006-10-10 02:39:26-04:00, stenn@whimsy.udel.edu [Bug 718] Use the recommended type for the saddrlen arg to getsockname() - NEWS@1.67, 2006-10-10 02:39:13-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.67 +1 -0 [Bug 718] Use the recommended type for the saddrlen arg to getsockname() - ntpd/ntp_io.c@1.234.1.13, 2006-10-10 02:38:43-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_io.c@1.234.1.13 +1 -1 [Bug 718] Use the recommended type for the saddrlen arg to getsockname() -ChangeSet@1.1379.1.34, 2006-10-10 02:27:12-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1379.1.34, 2006-10-10 02:27:12-04:00, stenn@whimsy.udel.edu Use NO_OPTION_NAME_WARNINGS if cc does not support #warning - configure.ac@1.388.1.11, 2006-10-10 02:25:45-04:00, stenn@whimsy.udel.edu +11 -0 + configure.ac@1.388.1.11 +11 -0 Use NO_OPTION_NAME_WARNINGS if cc does not support #warning - sntp/configure.ac@1.14, 2006-10-10 02:26:57-04:00, stenn@whimsy.udel.edu +11 -0 + sntp/configure.ac@1.14 +11 -0 Use NO_OPTION_NAME_WARNINGS if cc does not support #warning -ChangeSet@1.1379.1.33, 2006-10-09 07:41:25-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.33, 2006-10-09 07:41:25-04:00, stenn@whimsy.udel.edu NTP_4_2_3P53 TAG: NTP_4_2_3P53 - ntpd/ntpd-opts.c@1.30, 2006-10-09 07:41:03-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.30 +2 -2 NTP_4_2_3P53 - ntpd/ntpd-opts.h@1.30, 2006-10-09 07:41:04-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.30 +3 -3 NTP_4_2_3P53 - ntpd/ntpd-opts.texi@1.30, 2006-10-09 07:41:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.30 +1 -1 NTP_4_2_3P53 - ntpd/ntpd.1@1.29, 2006-10-09 07:41:05-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.29 +2 -2 NTP_4_2_3P53 - ntpd/ntpdsim-opts.c@1.30, 2006-10-09 07:41:06-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.30 +2 -2 NTP_4_2_3P53 - ntpd/ntpdsim-opts.h@1.30, 2006-10-09 07:41:07-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.30 +3 -3 NTP_4_2_3P53 - ntpd/ntpdsim-opts.texi@1.29, 2006-10-09 07:41:08-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.29 +1 -1 NTP_4_2_3P53 - ntpd/ntpdsim.1@1.29, 2006-10-09 07:41:08-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.29 +2 -2 NTP_4_2_3P53 - ntpdc/ntpdc-opts.c@1.30, 2006-10-09 07:41:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.30 +2 -2 NTP_4_2_3P53 - ntpdc/ntpdc-opts.h@1.30, 2006-10-09 07:41:09-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.30 +3 -3 NTP_4_2_3P53 - ntpdc/ntpdc-opts.texi@1.29, 2006-10-09 07:41:10-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.29 +1 -1 NTP_4_2_3P53 - ntpdc/ntpdc.1@1.29, 2006-10-09 07:41:11-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.29 +2 -2 NTP_4_2_3P53 - ntpq/ntpq-opts.c@1.32, 2006-10-09 07:41:11-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.32 +2 -2 NTP_4_2_3P53 - ntpq/ntpq-opts.h@1.32, 2006-10-09 07:41:12-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.32 +3 -3 NTP_4_2_3P53 - ntpq/ntpq-opts.texi@1.30, 2006-10-09 07:41:13-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.30 +1 -1 NTP_4_2_3P53 - ntpq/ntpq.1@1.29, 2006-10-09 07:41:14-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.29 +2 -2 NTP_4_2_3P53 - packageinfo.sh@1.45, 2006-10-09 07:41:15-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.45 +1 -1 NTP_4_2_3P53 - sntp/sntp-opts.c@1.29, 2006-10-09 07:41:15-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.29 +2 -2 NTP_4_2_3P53 - sntp/sntp-opts.h@1.29, 2006-10-09 07:41:17-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.29 +3 -3 NTP_4_2_3P53 - sntp/sntp-opts.texi@1.28, 2006-10-09 07:41:17-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.28 +1 -1 NTP_4_2_3P53 - sntp/sntp.1@1.31, 2006-10-09 07:41:19-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.31 +2 -2 NTP_4_2_3P53 - util/ntp-keygen-opts.c@1.29, 2006-10-09 07:41:20-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.29 +2 -2 NTP_4_2_3P53 - util/ntp-keygen-opts.h@1.29, 2006-10-09 07:41:20-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.29 +3 -3 NTP_4_2_3P53 - util/ntp-keygen-opts.texi@1.28, 2006-10-09 07:41:21-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.28 +1 -1 NTP_4_2_3P53 - util/ntp-keygen.1@1.28, 2006-10-09 07:41:22-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.28 +2 -2 NTP_4_2_3P53 -ChangeSet@1.1379.1.32, 2006-10-09 06:35:20-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1379.1.32, 2006-10-09 06:35:20-04:00, stenn@whimsy.udel.edu [Bug 715] Fix multicast issues under Linux - NEWS@1.66, 2006-10-09 06:35:05-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.66 +1 -0 [Bug 715] Fix multicast issues under Linux - libisc/ifiter_ioctl.c@1.25, 2006-10-09 06:35:05-04:00, stenn@whimsy.udel.edu +45 -7 + libisc/ifiter_ioctl.c@1.25 +45 -7 [Bug 715] Fix multicast issues under Linux -ChangeSet@1.1379.1.31, 2006-10-08 19:39:10-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.31, 2006-10-08 19:39:10-04:00, stenn@whimsy.udel.edu NTP_4_2_3P52 TAG: NTP_4_2_3P52 - ntpd/ntpd-opts.c@1.29, 2006-10-08 19:38:48-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpd-opts.c@1.29 +4 -4 NTP_4_2_3P52 - ntpd/ntpd-opts.h@1.29, 2006-10-08 19:38:49-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.29 +3 -3 NTP_4_2_3P52 - ntpd/ntpd-opts.texi@1.29, 2006-10-08 19:38:50-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.29 +3 -3 NTP_4_2_3P52 - ntpd/ntpd.1@1.28, 2006-10-08 19:38:50-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.28 +2 -2 NTP_4_2_3P52 - ntpd/ntpdsim-opts.c@1.29, 2006-10-08 19:38:51-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpdsim-opts.c@1.29 +4 -4 NTP_4_2_3P52 - ntpd/ntpdsim-opts.h@1.29, 2006-10-08 19:38:52-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.29 +3 -3 NTP_4_2_3P52 - ntpd/ntpdsim-opts.texi@1.28, 2006-10-08 19:38:52-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.texi@1.28 +3 -3 NTP_4_2_3P52 - ntpd/ntpdsim.1@1.28, 2006-10-08 19:38:53-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.28 +2 -2 NTP_4_2_3P52 - ntpdc/ntpdc-opts.c@1.29, 2006-10-08 19:38:54-04:00, stenn@whimsy.udel.edu +4 -4 + ntpdc/ntpdc-opts.c@1.29 +4 -4 NTP_4_2_3P52 - ntpdc/ntpdc-opts.h@1.29, 2006-10-08 19:38:54-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.29 +3 -3 NTP_4_2_3P52 - ntpdc/ntpdc-opts.texi@1.28, 2006-10-08 19:38:55-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.28 +2 -2 NTP_4_2_3P52 - ntpdc/ntpdc.1@1.28, 2006-10-08 19:38:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.28 +2 -2 NTP_4_2_3P52 - ntpq/ntpq-opts.c@1.31, 2006-10-08 19:38:57-04:00, stenn@whimsy.udel.edu +4 -4 + ntpq/ntpq-opts.c@1.31 +4 -4 NTP_4_2_3P52 - ntpq/ntpq-opts.h@1.31, 2006-10-08 19:38:57-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.31 +3 -3 NTP_4_2_3P52 - ntpq/ntpq-opts.texi@1.29, 2006-10-08 19:38:58-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.29 +3 -3 NTP_4_2_3P52 - ntpq/ntpq.1@1.28, 2006-10-08 19:38:59-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.28 +2 -2 NTP_4_2_3P52 - packageinfo.sh@1.44, 2006-10-08 19:39:00-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.44 +1 -1 NTP_4_2_3P52 - sntp/sntp-opts.c@1.28, 2006-10-08 19:39:01-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.28 +2 -2 NTP_4_2_3P52 - sntp/sntp-opts.h@1.28, 2006-10-08 19:39:01-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.28 +3 -3 NTP_4_2_3P52 - sntp/sntp-opts.texi@1.27, 2006-10-08 19:39:02-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.27 +1 -1 NTP_4_2_3P52 - sntp/sntp.1@1.30, 2006-10-08 19:39:03-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.30 +2 -2 NTP_4_2_3P52 - util/ntp-keygen-opts.c@1.28, 2006-10-08 19:39:03-04:00, stenn@whimsy.udel.edu +4 -4 + util/ntp-keygen-opts.c@1.28 +4 -4 NTP_4_2_3P52 - util/ntp-keygen-opts.h@1.28, 2006-10-08 19:39:04-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.28 +3 -3 NTP_4_2_3P52 - util/ntp-keygen-opts.texi@1.27, 2006-10-08 19:39:04-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.27 +2 -2 NTP_4_2_3P52 - util/ntp-keygen.1@1.27, 2006-10-08 19:39:05-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.27 +2 -2 NTP_4_2_3P52 -ChangeSet@1.1379.1.30, 2006-10-08 04:32:17-04:00, stenn@whimsy.udel.edu +53 -0 +ChangeSet@1.1379.1.30, 2006-10-08 04:32:17-04:00, stenn@whimsy.udel.edu libopts-27.5.3 - clockstuff/clktest-opts.c@1.7, 2006-10-08 04:30:41-04:00, stenn@whimsy.udel.edu +9 -7 + clockstuff/clktest-opts.c@1.7 +9 -7 libopts-27.5.3 - clockstuff/clktest-opts.h@1.7, 2006-10-08 04:30:42-04:00, stenn@whimsy.udel.edu +6 -4 + clockstuff/clktest-opts.h@1.7 +6 -4 libopts-27.5.3 - libopts/Makefile.am@1.6, 2006-10-08 04:30:43-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/Makefile.am@1.6 +1 -1 libopts-27.5.3 - libopts/autoopts.c@1.9, 2006-10-08 04:30:43-04:00, stenn@whimsy.udel.edu +8 -6 + libopts/autoopts.c@1.9 +8 -6 libopts-27.5.3 - libopts/autoopts/options.h@1.9, 2006-10-08 04:30:55-04:00, stenn@whimsy.udel.edu +131 -64 + libopts/autoopts/options.h@1.9 +131 -64 libopts-27.5.3 - libopts/autoopts/usage-txt.h@1.8, 2006-10-08 04:30:56-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts/usage-txt.h@1.8 +1 -1 libopts-27.5.3 - libopts/configfile.c@1.9, 2006-10-08 04:30:44-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/configfile.c@1.9 +1 -1 libopts-27.5.3 - libopts/cook.c@1.8, 2006-10-08 04:30:45-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/cook.c@1.8 +1 -1 libopts-27.5.3 - libopts/enumeration.c@1.8, 2006-10-08 04:30:46-04:00, stenn@whimsy.udel.edu +4 -4 + libopts/enumeration.c@1.8 +4 -4 libopts-27.5.3 - libopts/genshell.c@1.8, 2006-10-08 04:30:47-04:00, stenn@whimsy.udel.edu +3 -1 + libopts/genshell.c@1.8 +3 -1 libopts-27.5.3 - libopts/genshell.h@1.8, 2006-10-08 04:30:48-04:00, stenn@whimsy.udel.edu +5 -3 + libopts/genshell.h@1.8 +5 -3 libopts-27.5.3 - libopts/load.c@1.9, 2006-10-08 04:30:48-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/load.c@1.9 +1 -1 libopts-27.5.3 - libopts/m4/libopts.m4@1.13, 2006-10-08 04:30:56-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/m4/libopts.m4@1.13 +1 -1 libopts-27.5.3 - libopts/makeshell.c@1.10, 2006-10-08 04:30:50-04:00, stenn@whimsy.udel.edu +13 -4 + libopts/makeshell.c@1.10 +13 -4 libopts-27.5.3 - libopts/nested.c@1.8, 2006-10-08 04:30:50-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/nested.c@1.8 +1 -1 libopts-27.5.3 - libopts/numeric.c@1.8, 2006-10-08 04:30:51-04:00, stenn@whimsy.udel.edu +4 -4 + libopts/numeric.c@1.8 +4 -4 libopts-27.5.3 - libopts/proto.h@1.10, 2006-10-08 04:30:51-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/proto.h@1.10 +1 -1 libopts-27.5.3 - libopts/putshell.c@1.9, 2006-10-08 04:30:51-04:00, stenn@whimsy.udel.edu +8 -8 + libopts/putshell.c@1.9 +8 -8 libopts-27.5.3 - libopts/restore.c@1.8, 2006-10-08 04:30:52-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/restore.c@1.8 +2 -2 libopts-27.5.3 - libopts/save.c@1.9, 2006-10-08 04:30:53-04:00, stenn@whimsy.udel.edu +7 -8 + libopts/save.c@1.9 +7 -8 libopts-27.5.3 - libopts/stack.c@1.9, 2006-10-08 04:30:54-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/stack.c@1.9 +3 -3 libopts-27.5.3 - ntpd/ntpd-opts.c@1.28, 2006-10-08 04:30:57-04:00, stenn@whimsy.udel.edu +3 -1 + ntpd/ntpd-opts.c@1.28 +3 -1 libopts-27.5.3 - ntpd/ntpd-opts.h@1.28, 2006-10-08 04:30:58-04:00, stenn@whimsy.udel.edu +6 -4 + ntpd/ntpd-opts.h@1.28 +6 -4 libopts-27.5.3 - ntpd/ntpdsim-opts.c@1.28, 2006-10-08 04:30:59-04:00, stenn@whimsy.udel.edu +3 -1 + ntpd/ntpdsim-opts.c@1.28 +3 -1 libopts-27.5.3 - ntpd/ntpdsim-opts.h@1.28, 2006-10-08 04:31:00-04:00, stenn@whimsy.udel.edu +6 -4 + ntpd/ntpdsim-opts.h@1.28 +6 -4 libopts-27.5.3 - ntpdc/ntpdc-opts.c@1.28, 2006-10-08 04:31:01-04:00, stenn@whimsy.udel.edu +3 -1 + ntpdc/ntpdc-opts.c@1.28 +3 -1 libopts-27.5.3 - ntpdc/ntpdc-opts.h@1.28, 2006-10-08 04:31:02-04:00, stenn@whimsy.udel.edu +6 -4 + ntpdc/ntpdc-opts.h@1.28 +6 -4 libopts-27.5.3 - ntpq/ntpq-opts.c@1.30, 2006-10-08 04:31:03-04:00, stenn@whimsy.udel.edu +3 -1 + ntpq/ntpq-opts.c@1.30 +3 -1 libopts-27.5.3 - ntpq/ntpq-opts.h@1.30, 2006-10-08 04:31:04-04:00, stenn@whimsy.udel.edu +6 -4 + ntpq/ntpq-opts.h@1.30 +6 -4 libopts-27.5.3 - ntpq/ntpq-opts.texi@1.28, 2006-10-08 04:31:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.28 +1 -1 libopts-27.5.3 - sntp/libopts/Makefile.am@1.4, 2006-10-08 04:31:07-04:00, stenn@whimsy.udel.edu +10 -6 + sntp/libopts/Makefile.am@1.4 +10 -6 libopts-27.5.3 - sntp/libopts/autoopts.c@1.6, 2006-10-08 04:31:07-04:00, stenn@whimsy.udel.edu +8 -6 + sntp/libopts/autoopts.c@1.6 +8 -6 libopts-27.5.3 - sntp/libopts/autoopts/options.h@1.6, 2006-10-08 04:31:18-04:00, stenn@whimsy.udel.edu +131 -64 + sntp/libopts/autoopts/options.h@1.6 +131 -64 libopts-27.5.3 - sntp/libopts/autoopts/usage-txt.h@1.5, 2006-10-08 04:31:18-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/autoopts/usage-txt.h@1.5 +1 -1 libopts-27.5.3 - sntp/libopts/configfile.c@1.6, 2006-10-08 04:31:08-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/configfile.c@1.6 +1 -1 libopts-27.5.3 - sntp/libopts/cook.c@1.5, 2006-10-08 04:31:09-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/cook.c@1.5 +1 -1 libopts-27.5.3 - sntp/libopts/enumeration.c@1.5, 2006-10-08 04:31:09-04:00, stenn@whimsy.udel.edu +4 -4 + sntp/libopts/enumeration.c@1.5 +4 -4 libopts-27.5.3 - sntp/libopts/genshell.c@1.5, 2006-10-08 04:31:10-04:00, stenn@whimsy.udel.edu +3 -1 + sntp/libopts/genshell.c@1.5 +3 -1 libopts-27.5.3 - sntp/libopts/genshell.h@1.5, 2006-10-08 04:31:11-04:00, stenn@whimsy.udel.edu +5 -3 + sntp/libopts/genshell.h@1.5 +5 -3 libopts-27.5.3 - sntp/libopts/load.c@1.6, 2006-10-08 04:31:11-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/load.c@1.6 +1 -1 libopts-27.5.3 - sntp/libopts/m4/libopts.m4@1.10, 2006-10-08 04:31:20-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/m4/libopts.m4@1.10 +1 -1 libopts-27.5.3 - sntp/libopts/makeshell.c@1.7, 2006-10-08 04:31:12-04:00, stenn@whimsy.udel.edu +13 -4 + sntp/libopts/makeshell.c@1.7 +13 -4 libopts-27.5.3 - sntp/libopts/nested.c@1.5, 2006-10-08 04:31:13-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/nested.c@1.5 +1 -1 libopts-27.5.3 - sntp/libopts/numeric.c@1.5, 2006-10-08 04:31:14-04:00, stenn@whimsy.udel.edu +4 -4 + sntp/libopts/numeric.c@1.5 +4 -4 libopts-27.5.3 - sntp/libopts/proto.h@1.7, 2006-10-08 04:31:14-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/proto.h@1.7 +1 -1 libopts-27.5.3 - sntp/libopts/putshell.c@1.6, 2006-10-08 04:31:15-04:00, stenn@whimsy.udel.edu +8 -8 + sntp/libopts/putshell.c@1.6 +8 -8 libopts-27.5.3 - sntp/libopts/restore.c@1.4, 2006-10-08 04:31:15-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/restore.c@1.4 +2 -2 libopts-27.5.3 - sntp/libopts/save.c@1.6, 2006-10-08 04:31:16-04:00, stenn@whimsy.udel.edu +7 -8 + sntp/libopts/save.c@1.6 +7 -8 libopts-27.5.3 - sntp/libopts/stack.c@1.6, 2006-10-08 04:31:17-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/libopts/stack.c@1.6 +3 -3 libopts-27.5.3 - sntp/sntp-opts.c@1.27, 2006-10-08 04:31:05-04:00, stenn@whimsy.udel.edu +3 -1 + sntp/sntp-opts.c@1.27 +3 -1 libopts-27.5.3 - sntp/sntp-opts.h@1.27, 2006-10-08 04:31:06-04:00, stenn@whimsy.udel.edu +6 -4 + sntp/sntp-opts.h@1.27 +6 -4 libopts-27.5.3 - util/ntp-keygen-opts.c@1.27, 2006-10-08 04:31:20-04:00, stenn@whimsy.udel.edu +5 -3 + util/ntp-keygen-opts.c@1.27 +5 -3 libopts-27.5.3 - util/ntp-keygen-opts.h@1.27, 2006-10-08 04:31:21-04:00, stenn@whimsy.udel.edu +6 -4 + util/ntp-keygen-opts.h@1.27 +6 -4 libopts-27.5.3 -ChangeSet@1.1379.9.1, 2006-10-07 19:42:28+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1379.9.1, 2006-10-07 19:42:28+00:00, kardel@pogo.udel.edu ntp_io.c: allow asyncio_readers to remove themselves when being run - ntpd/ntp_io.c@1.234.1.12, 2006-10-07 19:41:38+00:00, kardel@pogo.udel.edu +5 -3 + ntpd/ntp_io.c@1.234.1.12 +5 -3 allow asyncio_readers to remove themselves when being run -ChangeSet@1.1379.1.28, 2006-10-05 10:20:42+00:00, burnicki@pogo.udel.edu +2 -0 +ChangeSet@1.1379.1.28, 2006-10-05 10:20:42+00:00, burnicki@pogo.udel.edu [Bug 708] Set the affinity to a specific CPU for the clock interpolation thread only, not for the whole process. - ports/winnt/ntpd/nt_clockstuff.c@1.22, 2006-10-05 10:20:40+00:00, burnicki@pogo.udel.edu +250 -575 + ports/winnt/ntpd/nt_clockstuff.c@1.22 +250 -575 Set the affinity to a specific CPU for the clock interpolation thread only, not for the whole process. - ports/winnt/ntpd/win32_io.c@1.12, 2006-10-05 10:20:40+00:00, burnicki@pogo.udel.edu +0 -22 + ports/winnt/ntpd/win32_io.c@1.12 +0 -22 Set the affinity to a specific CPU for the clock interpolation thread only, not for the whole process. -ChangeSet@1.1379.1.27, 2006-09-26 23:45:08-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.27, 2006-09-26 23:45:08-04:00, stenn@whimsy.udel.edu update NEWS - NEWS@1.65, 2006-09-26 23:44:48-04:00, stenn@whimsy.udel.edu +2 -0 + NEWS@1.65 +2 -0 update -ChangeSet@1.1379.8.3, 2006-09-26 22:17:09-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.8.3, 2006-09-26 22:17:09-04:00, mayer@pogo.udel.edu Unchanged - ntpd/refclock_wwv.c@1.63.1.1, 2006-09-26 22:16:51-04:00, mayer@pogo.udel.edu +4 -7 + ntpd/refclock_wwv.c@1.63.1.1 +4 -7 Unchanged -ChangeSet@1.1379.8.2, 2006-09-26 18:14:39-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.8.2, 2006-09-26 18:14:39-04:00, mayer@pogo.udel.edu Bug #670: Fix for Transfer Aborted messages on Windows on reconfiguring interfaces - ports/winnt/ntpd/ntp_iocompletionport.c@1.21, 2006-09-26 18:14:26-04:00, mayer@pogo.udel.edu +98 -38 + ports/winnt/ntpd/ntp_iocompletionport.c@1.21 +98 -38 Bug #670: Fix for Transfer Aborted messages on Windows on reconfiguring interfaces -ChangeSet@1.1379.8.1, 2006-09-26 18:11:11-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.8.1, 2006-09-26 18:11:11-04:00, mayer@pogo.udel.edu Bug #690: Fix for buffer address issue - ports/winnt/libntp/dnslookup.c@1.4.1.3, 2006-09-26 18:10:40-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/libntp/dnslookup.c@1.4.1.3 +1 -1 Bug #690: Fix for buffer address issue -ChangeSet@1.1379.1.25, 2006-09-26 16:16:30-04:00, stenn@whimsy.udel.edu +26 -0 +ChangeSet@1.1379.1.25, 2006-09-26 16:16:30-04:00, stenn@whimsy.udel.edu autogen update - clockstuff/clktest-opts.c@1.6, 2006-09-25 15:03:08-04:00, stenn@whimsy.udel.edu +2 -2 + clockstuff/clktest-opts.c@1.6 +2 -2 autogen update - clockstuff/clktest-opts.h@1.6, 2006-09-25 15:03:09-04:00, stenn@whimsy.udel.edu +3 -3 + clockstuff/clktest-opts.h@1.6 +3 -3 autogen update - ntpd/ntpd-opts.c@1.27, 2006-09-25 15:03:10-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.c@1.27 +3 -3 autogen update - ntpd/ntpd-opts.h@1.27, 2006-09-25 15:03:11-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.h@1.27 +1 -1 autogen update - ntpd/ntpd-opts.texi@1.28, 2006-09-25 15:03:12-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.28 +3 -3 autogen update - ntpd/ntpd.1@1.27, 2006-09-25 15:03:12-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd.1@1.27 +1 -1 autogen update - ntpd/ntpdsim-opts.c@1.27, 2006-09-25 15:03:13-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.c@1.27 +3 -3 autogen update - ntpd/ntpdsim-opts.h@1.27, 2006-09-25 15:03:14-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.h@1.27 +1 -1 autogen update - ntpd/ntpdsim-opts.texi@1.27, 2006-09-25 15:03:15-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.texi@1.27 +3 -3 autogen update - ntpd/ntpdsim.1@1.27, 2006-09-25 15:03:16-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim.1@1.27 +1 -1 autogen update - ntpdc/ntpdc-opts.c@1.27, 2006-09-25 15:03:16-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.c@1.27 +3 -3 autogen update - ntpdc/ntpdc-opts.h@1.27, 2006-09-25 15:03:17-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.h@1.27 +1 -1 autogen update - ntpdc/ntpdc-opts.texi@1.27, 2006-09-25 15:03:18-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.27 +2 -2 autogen update - ntpdc/ntpdc.1@1.27, 2006-09-25 15:03:19-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc.1@1.27 +1 -1 autogen update - ntpq/ntpq-opts.c@1.29, 2006-09-25 15:03:20-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.c@1.29 +3 -3 autogen update - ntpq/ntpq-opts.h@1.29, 2006-09-25 15:03:21-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.h@1.29 +1 -1 autogen update - ntpq/ntpq-opts.texi@1.27, 2006-09-25 15:03:21-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.27 +3 -3 autogen update - ntpq/ntpq.1@1.27, 2006-09-25 15:03:22-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq.1@1.27 +1 -1 autogen update - sntp/sntp-opts.c@1.26, 2006-09-25 15:03:22-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.c@1.26 +1 -1 autogen update - sntp/sntp-opts.h@1.26, 2006-09-25 15:03:23-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.h@1.26 +1 -1 autogen update - sntp/sntp-opts.texi@1.26, 2006-09-25 15:03:24-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.26 +1 -1 autogen update - sntp/sntp.1@1.29, 2006-09-25 15:03:25-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp.1@1.29 +1 -1 autogen update - util/ntp-keygen-opts.c@1.26, 2006-09-25 15:03:25-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.c@1.26 +3 -3 autogen update - util/ntp-keygen-opts.h@1.26, 2006-09-25 15:03:26-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.h@1.26 +1 -1 autogen update - util/ntp-keygen-opts.texi@1.26, 2006-09-25 15:03:27-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.26 +2 -2 autogen update - util/ntp-keygen.1@1.26, 2006-09-25 15:03:27-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen.1@1.26 +1 -1 autogen update -ChangeSet@1.1379.1.24, 2006-09-25 07:49:15-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.24, 2006-09-25 07:49:15-04:00, stenn@whimsy.udel.edu NTP_4_2_3P51 TAG: NTP_4_2_3P51 - ntpd/ntpd-opts.c@1.26, 2006-09-25 07:48:54-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpd-opts.c@1.26 +4 -4 NTP_4_2_3P51 - ntpd/ntpd-opts.h@1.26, 2006-09-25 07:48:54-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.26 +3 -3 NTP_4_2_3P51 - ntpd/ntpd-opts.texi@1.27, 2006-09-25 07:48:55-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.27 +3 -3 NTP_4_2_3P51 - ntpd/ntpd.1@1.26, 2006-09-25 07:48:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.26 +2 -2 NTP_4_2_3P51 - ntpd/ntpdsim-opts.c@1.26, 2006-09-25 07:48:57-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpdsim-opts.c@1.26 +4 -4 NTP_4_2_3P51 - ntpd/ntpdsim-opts.h@1.26, 2006-09-25 07:48:58-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.26 +3 -3 NTP_4_2_3P51 - ntpd/ntpdsim-opts.texi@1.26, 2006-09-25 07:48:59-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.texi@1.26 +3 -3 NTP_4_2_3P51 - ntpd/ntpdsim.1@1.26, 2006-09-25 07:48:59-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.26 +2 -2 NTP_4_2_3P51 - ntpdc/ntpdc-opts.c@1.26, 2006-09-25 07:49:00-04:00, stenn@whimsy.udel.edu +4 -4 + ntpdc/ntpdc-opts.c@1.26 +4 -4 NTP_4_2_3P51 - ntpdc/ntpdc-opts.h@1.26, 2006-09-25 07:49:01-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.26 +3 -3 NTP_4_2_3P51 - ntpdc/ntpdc-opts.texi@1.26, 2006-09-25 07:49:02-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.26 +2 -2 NTP_4_2_3P51 - ntpdc/ntpdc.1@1.26, 2006-09-25 07:49:02-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.26 +2 -2 NTP_4_2_3P51 - ntpq/ntpq-opts.c@1.28, 2006-09-25 07:49:03-04:00, stenn@whimsy.udel.edu +4 -4 + ntpq/ntpq-opts.c@1.28 +4 -4 NTP_4_2_3P51 - ntpq/ntpq-opts.h@1.28, 2006-09-25 07:49:04-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.28 +3 -3 NTP_4_2_3P51 - ntpq/ntpq-opts.texi@1.26, 2006-09-25 07:49:04-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.26 +3 -3 NTP_4_2_3P51 - ntpq/ntpq.1@1.26, 2006-09-25 07:49:05-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.26 +2 -2 NTP_4_2_3P51 - packageinfo.sh@1.43, 2006-09-25 07:49:06-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.43 +1 -1 NTP_4_2_3P51 - sntp/sntp-opts.c@1.25, 2006-09-25 07:49:06-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.25 +2 -2 NTP_4_2_3P51 - sntp/sntp-opts.h@1.25, 2006-09-25 07:49:07-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.25 +3 -3 NTP_4_2_3P51 - sntp/sntp-opts.texi@1.25, 2006-09-25 07:49:07-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.25 +1 -1 NTP_4_2_3P51 - sntp/sntp.1@1.28, 2006-09-25 07:49:08-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.28 +2 -2 NTP_4_2_3P51 - util/ntp-keygen-opts.c@1.25, 2006-09-25 07:49:09-04:00, stenn@whimsy.udel.edu +4 -4 + util/ntp-keygen-opts.c@1.25 +4 -4 NTP_4_2_3P51 - util/ntp-keygen-opts.h@1.25, 2006-09-25 07:49:09-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.25 +3 -3 NTP_4_2_3P51 - util/ntp-keygen-opts.texi@1.25, 2006-09-25 07:49:10-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.25 +2 -2 NTP_4_2_3P51 - util/ntp-keygen.1@1.25, 2006-09-25 07:49:11-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.25 +2 -2 NTP_4_2_3P51 -ChangeSet@1.1379.1.23, 2006-09-25 01:53:46-04:00, stenn@whimsy.udel.edu +93 -0 +ChangeSet@1.1379.1.23, 2006-09-25 01:53:46-04:00, stenn@whimsy.udel.edu autogen upgrade - NEWS@1.64, 2006-09-25 01:53:32-04:00, stenn@whimsy.udel.edu +6 -5 + NEWS@1.64 +6 -5 updates - clockstuff/clktest-opts.c@1.5, 2006-09-25 01:50:03-04:00, stenn@whimsy.udel.edu +6 -3 + clockstuff/clktest-opts.c@1.5 +6 -3 autogen upgrade - clockstuff/clktest-opts.h@1.5, 2006-09-25 01:50:04-04:00, stenn@whimsy.udel.edu +3 -3 + clockstuff/clktest-opts.h@1.5 +3 -3 autogen upgrade - libopts/autoopts.c@1.8, 2006-09-25 01:50:05-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/autoopts.c@1.8 +1 -2 autogen upgrade - libopts/autoopts.h@1.8, 2006-09-25 01:50:05-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/autoopts.h@1.8 +1 -2 autogen upgrade - libopts/autoopts/options.h@1.8, 2006-09-25 01:50:20-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/autoopts/options.h@1.8 +2 -2 autogen upgrade - libopts/autoopts/usage-txt.h@1.7, 2006-09-25 01:50:22-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/autoopts/usage-txt.h@1.7 +2 -2 autogen upgrade - libopts/boolean.c@1.7, 2006-09-25 01:50:06-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/boolean.c@1.7 +1 -2 autogen upgrade - libopts/compat/compat.h@1.11, 2006-09-25 01:50:22-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/compat/compat.h@1.11 +1 -2 autogen upgrade - libopts/compat/pathfind.c@1.8, 2006-09-25 01:50:23-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/compat/pathfind.c@1.8 +3 -3 autogen upgrade - libopts/compat/strchr.c@1.3, 2006-09-25 01:50:24-04:00, stenn@whimsy.udel.edu +0 -1 + libopts/compat/strchr.c@1.3 +0 -1 autogen upgrade - libopts/compat/windows-config.h@1.4, 2006-09-25 01:50:25-04:00, stenn@whimsy.udel.edu +6 -0 + libopts/compat/windows-config.h@1.4 +6 -0 autogen upgrade - libopts/configfile.c@1.8, 2006-09-25 01:50:06-04:00, stenn@whimsy.udel.edu +34 -35 + libopts/configfile.c@1.8 +34 -35 autogen upgrade - libopts/cook.c@1.7, 2006-09-25 01:50:07-04:00, stenn@whimsy.udel.edu +5 -6 + libopts/cook.c@1.7 +5 -6 autogen upgrade - libopts/enumeration.c@1.7, 2006-09-25 01:50:08-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/enumeration.c@1.7 +1 -2 autogen upgrade - libopts/environment.c@1.7, 2006-09-25 01:50:08-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/environment.c@1.7 +1 -2 autogen upgrade - libopts/genshell.c@1.7, 2006-09-25 01:50:09-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.c@1.7 +1 -1 autogen upgrade - libopts/genshell.h@1.7, 2006-09-25 01:50:10-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.h@1.7 +1 -1 autogen upgrade - libopts/load.c@1.8, 2006-09-25 01:50:10-04:00, stenn@whimsy.udel.edu +10 -11 + libopts/load.c@1.8 +10 -11 autogen upgrade - libopts/m4/libopts.m4@1.12, 2006-09-25 01:50:25-04:00, stenn@whimsy.udel.edu +4 -1 + libopts/m4/libopts.m4@1.12 +4 -1 autogen upgrade - libopts/m4/liboptschk.m4@1.2, 2006-09-25 01:50:27-04:00, stenn@whimsy.udel.edu +4 -1 + libopts/m4/liboptschk.m4@1.2 +4 -1 autogen upgrade - libopts/makeshell.c@1.9, 2006-09-25 01:50:11-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/makeshell.c@1.9 +1 -2 autogen upgrade - libopts/nested.c@1.7, 2006-09-25 01:50:12-04:00, stenn@whimsy.udel.edu +18 -19 + libopts/nested.c@1.7 +18 -19 autogen upgrade - libopts/numeric.c@1.7, 2006-09-25 01:50:12-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/numeric.c@1.7 +1 -2 autogen upgrade - libopts/pgusage.c@1.8, 2006-09-25 01:50:13-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/pgusage.c@1.8 +1 -2 autogen upgrade - libopts/proto.h@1.9, 2006-09-25 01:50:13-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/proto.h@1.9 +1 -1 autogen upgrade - libopts/putshell.c@1.8, 2006-09-25 01:50:13-04:00, stenn@whimsy.udel.edu +3 -4 + libopts/putshell.c@1.8 +3 -4 autogen upgrade - libopts/restore.c@1.7, 2006-09-25 01:50:14-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/restore.c@1.7 +1 -2 autogen upgrade - libopts/save.c@1.8, 2006-09-25 01:50:15-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/save.c@1.8 +1 -2 autogen upgrade - libopts/sort.c@1.7, 2006-09-25 01:50:15-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/sort.c@1.7 +1 -2 autogen upgrade - libopts/stack.c@1.8, 2006-09-25 01:50:16-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/stack.c@1.8 +1 -2 autogen upgrade - libopts/streqvcmp.c@1.8, 2006-09-25 01:50:17-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/streqvcmp.c@1.8 +1 -2 autogen upgrade - libopts/text_mmap.c@1.7, 2006-09-25 01:50:17-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/text_mmap.c@1.7 +1 -2 autogen upgrade - libopts/tokenize.c@1.5, 2006-09-25 01:50:18-04:00, stenn@whimsy.udel.edu +0 -1 + libopts/tokenize.c@1.5 +0 -1 autogen upgrade - libopts/usage.c@1.8, 2006-09-25 01:50:19-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/usage.c@1.8 +1 -2 autogen upgrade - libopts/version.c@1.8, 2006-09-25 01:50:20-04:00, stenn@whimsy.udel.edu +1 -2 + libopts/version.c@1.8 +1 -2 autogen upgrade - ntpd/ntpd-opts.c@1.25, 2006-09-25 01:50:27-04:00, stenn@whimsy.udel.edu +3 -2 + ntpd/ntpd-opts.c@1.25 +3 -2 autogen upgrade - ntpd/ntpd-opts.h@1.25, 2006-09-25 01:50:28-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.h@1.25 +1 -1 autogen upgrade - ntpd/ntpd-opts.texi@1.26, 2006-09-25 01:50:29-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.26 +3 -3 autogen upgrade - ntpd/ntpd.1@1.25, 2006-09-25 01:50:30-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.25 +2 -2 autogen upgrade - ntpd/ntpdsim-opts.c@1.25, 2006-09-25 01:50:31-04:00, stenn@whimsy.udel.edu +3 -2 + ntpd/ntpdsim-opts.c@1.25 +3 -2 autogen upgrade - ntpd/ntpdsim-opts.h@1.25, 2006-09-25 01:50:32-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.h@1.25 +1 -1 autogen upgrade - ntpd/ntpdsim-opts.texi@1.25, 2006-09-25 01:50:32-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.texi@1.25 +3 -3 autogen upgrade - ntpd/ntpdsim.1@1.25, 2006-09-25 01:50:33-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.25 +2 -2 autogen upgrade - ntpdc/ntpdc-opts.c@1.25, 2006-09-25 01:50:34-04:00, stenn@whimsy.udel.edu +3 -2 + ntpdc/ntpdc-opts.c@1.25 +3 -2 autogen upgrade - ntpdc/ntpdc-opts.h@1.25, 2006-09-25 01:50:34-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.h@1.25 +1 -1 autogen upgrade - ntpdc/ntpdc-opts.texi@1.25, 2006-09-25 01:52:36-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.25 +2 -2 autogen upgrade - ntpdc/ntpdc.1@1.25, 2006-09-25 01:52:37-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.25 +2 -2 autogen upgrade - ntpq/ntpq-opts.c@1.27, 2006-09-25 01:50:35-04:00, stenn@whimsy.udel.edu +3 -2 + ntpq/ntpq-opts.c@1.27 +3 -2 autogen upgrade - ntpq/ntpq-opts.h@1.27, 2006-09-25 01:50:36-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.h@1.27 +1 -1 autogen upgrade - ntpq/ntpq-opts.texi@1.25, 2006-09-25 01:52:38-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.25 +3 -3 autogen upgrade - ntpq/ntpq.1@1.25, 2006-09-25 01:52:38-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.25 +2 -2 autogen upgrade - sntp/libopts/autoopts.c@1.5, 2006-09-25 01:50:36-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/autoopts.c@1.5 +1 -2 autogen upgrade - sntp/libopts/autoopts.h@1.6, 2006-09-25 01:50:37-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/autoopts.h@1.6 +1 -2 autogen upgrade - sntp/libopts/autoopts/options.h@1.5, 2006-09-25 01:50:55-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/autoopts/options.h@1.5 +2 -2 autogen upgrade - sntp/libopts/autoopts/usage-txt.h@1.4, 2006-09-25 01:50:55-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/autoopts/usage-txt.h@1.4 +2 -2 autogen upgrade - sntp/libopts/boolean.c@1.4, 2006-09-25 01:50:38-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/boolean.c@1.4 +1 -2 autogen upgrade - sntp/libopts/compat/compat.h@1.7, 2006-09-25 01:50:56-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/compat/compat.h@1.7 +1 -2 autogen upgrade - sntp/libopts/compat/pathfind.c@1.5, 2006-09-25 01:50:57-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/libopts/compat/pathfind.c@1.5 +3 -3 autogen upgrade - sntp/libopts/compat/strchr.c@1.3, 2006-09-25 01:50:57-04:00, stenn@whimsy.udel.edu +0 -1 + sntp/libopts/compat/strchr.c@1.3 +0 -1 autogen upgrade - sntp/libopts/compat/windows-config.h@1.2, 2006-09-25 01:50:58-04:00, stenn@whimsy.udel.edu +16 -10 + sntp/libopts/compat/windows-config.h@1.2 +16 -10 autogen upgrade - sntp/libopts/configfile.c@1.5, 2006-09-25 01:50:38-04:00, stenn@whimsy.udel.edu +34 -35 + sntp/libopts/configfile.c@1.5 +34 -35 autogen upgrade - sntp/libopts/cook.c@1.4, 2006-09-25 01:50:40-04:00, stenn@whimsy.udel.edu +5 -6 + sntp/libopts/cook.c@1.4 +5 -6 autogen upgrade - sntp/libopts/enumeration.c@1.4, 2006-09-25 01:50:41-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/enumeration.c@1.4 +1 -2 autogen upgrade - sntp/libopts/environment.c@1.4, 2006-09-25 01:50:42-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/environment.c@1.4 +1 -2 autogen upgrade - sntp/libopts/genshell.c@1.4, 2006-09-25 01:50:42-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/genshell.c@1.4 +1 -1 autogen upgrade - sntp/libopts/genshell.h@1.4, 2006-09-25 01:50:43-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/genshell.h@1.4 +1 -1 autogen upgrade - sntp/libopts/load.c@1.5, 2006-09-25 01:50:44-04:00, stenn@whimsy.udel.edu +10 -11 + sntp/libopts/load.c@1.5 +10 -11 autogen upgrade - sntp/libopts/m4/libopts.m4@1.9, 2006-09-25 01:50:58-04:00, stenn@whimsy.udel.edu +4 -1 + sntp/libopts/m4/libopts.m4@1.9 +4 -1 autogen upgrade - sntp/libopts/m4/liboptschk.m4@1.2, 2006-09-25 01:50:59-04:00, stenn@whimsy.udel.edu +4 -1 + sntp/libopts/m4/liboptschk.m4@1.2 +4 -1 autogen upgrade - sntp/libopts/makeshell.c@1.6, 2006-09-25 01:50:45-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/makeshell.c@1.6 +1 -2 autogen upgrade - sntp/libopts/nested.c@1.4, 2006-09-25 01:50:45-04:00, stenn@whimsy.udel.edu +18 -19 + sntp/libopts/nested.c@1.4 +18 -19 autogen upgrade - sntp/libopts/numeric.c@1.4, 2006-09-25 01:50:46-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/numeric.c@1.4 +1 -2 autogen upgrade - sntp/libopts/pgusage.c@1.4, 2006-09-25 01:50:46-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/pgusage.c@1.4 +1 -2 autogen upgrade - sntp/libopts/proto.h@1.6, 2006-09-25 01:50:47-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/proto.h@1.6 +1 -1 autogen upgrade - sntp/libopts/putshell.c@1.5, 2006-09-25 01:50:47-04:00, stenn@whimsy.udel.edu +3 -4 + sntp/libopts/putshell.c@1.5 +3 -4 autogen upgrade - sntp/libopts/restore.c@1.3, 2006-09-25 01:50:47-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/restore.c@1.3 +1 -2 autogen upgrade - sntp/libopts/save.c@1.5, 2006-09-25 01:50:49-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/save.c@1.5 +1 -2 autogen upgrade - sntp/libopts/sort.c@1.3, 2006-09-25 01:50:50-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/sort.c@1.3 +1 -2 autogen upgrade - sntp/libopts/stack.c@1.5, 2006-09-25 01:50:50-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/stack.c@1.5 +1 -2 autogen upgrade - sntp/libopts/streqvcmp.c@1.5, 2006-09-25 01:50:51-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/streqvcmp.c@1.5 +1 -2 autogen upgrade - sntp/libopts/text_mmap.c@1.4, 2006-09-25 01:50:52-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/text_mmap.c@1.4 +1 -2 autogen upgrade - sntp/libopts/tokenize.c@1.4, 2006-09-25 01:50:53-04:00, stenn@whimsy.udel.edu +0 -1 + sntp/libopts/tokenize.c@1.4 +0 -1 autogen upgrade - sntp/libopts/usage.c@1.6, 2006-09-25 01:50:53-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/usage.c@1.6 +1 -2 autogen upgrade - sntp/libopts/version.c@1.5, 2006-09-25 01:50:54-04:00, stenn@whimsy.udel.edu +1 -2 + sntp/libopts/version.c@1.5 +1 -2 autogen upgrade - sntp/sntp-opts.c@1.24, 2006-09-25 01:52:39-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.c@1.24 +1 -1 autogen upgrade - sntp/sntp-opts.h@1.24, 2006-09-25 01:52:40-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.h@1.24 +1 -1 autogen upgrade - sntp/sntp-opts.texi@1.24, 2006-09-25 01:52:40-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.24 +1 -1 autogen upgrade - sntp/sntp.1@1.27, 2006-09-25 01:52:42-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.27 +2 -2 autogen upgrade - util/ntp-keygen-opts.c@1.24, 2006-09-25 01:50:59-04:00, stenn@whimsy.udel.edu +3 -2 + util/ntp-keygen-opts.c@1.24 +3 -2 autogen upgrade - util/ntp-keygen-opts.h@1.24, 2006-09-25 01:51:00-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.h@1.24 +1 -1 autogen upgrade - util/ntp-keygen-opts.texi@1.24, 2006-09-25 01:52:42-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.24 +2 -2 autogen upgrade - util/ntp-keygen.1@1.24, 2006-09-25 01:52:43-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.24 +2 -2 autogen upgrade -ChangeSet@1.1379.1.22, 2006-09-24 05:30:52-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.22, 2006-09-24 05:30:52-04:00, stenn@whimsy.udel.edu NTP_4_2_3P50 TAG: NTP_4_2_3P50 - ntpd/ntpd-opts.c@1.24, 2006-09-24 05:30:30-04:00, stenn@whimsy.udel.edu +56 -55 + ntpd/ntpd-opts.c@1.24 +56 -55 NTP_4_2_3P50 - ntpd/ntpd-opts.h@1.24, 2006-09-24 05:30:31-04:00, stenn@whimsy.udel.edu +9 -9 + ntpd/ntpd-opts.h@1.24 +9 -9 NTP_4_2_3P50 - ntpd/ntpd-opts.texi@1.25, 2006-09-24 05:30:32-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.25 +1 -1 NTP_4_2_3P50 - ntpd/ntpd.1@1.24, 2006-09-24 05:30:33-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.24 +2 -2 NTP_4_2_3P50 - ntpd/ntpdsim-opts.c@1.24, 2006-09-24 05:30:34-04:00, stenn@whimsy.udel.edu +74 -73 + ntpd/ntpdsim-opts.c@1.24 +74 -73 NTP_4_2_3P50 - ntpd/ntpdsim-opts.h@1.24, 2006-09-24 05:30:35-04:00, stenn@whimsy.udel.edu +9 -9 + ntpd/ntpdsim-opts.h@1.24 +9 -9 NTP_4_2_3P50 - ntpd/ntpdsim-opts.texi@1.24, 2006-09-24 05:30:35-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.24 +1 -1 NTP_4_2_3P50 - ntpd/ntpdsim.1@1.24, 2006-09-24 05:30:36-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.24 +2 -2 NTP_4_2_3P50 - ntpdc/ntpdc-opts.c@1.24, 2006-09-24 05:30:37-04:00, stenn@whimsy.udel.edu +22 -21 + ntpdc/ntpdc-opts.c@1.24 +22 -21 NTP_4_2_3P50 - ntpdc/ntpdc-opts.h@1.24, 2006-09-24 05:30:38-04:00, stenn@whimsy.udel.edu +7 -7 + ntpdc/ntpdc-opts.h@1.24 +7 -7 NTP_4_2_3P50 - ntpdc/ntpdc-opts.texi@1.24, 2006-09-24 05:30:38-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.24 +1 -1 NTP_4_2_3P50 - ntpdc/ntpdc.1@1.24, 2006-09-24 05:30:39-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.24 +2 -2 NTP_4_2_3P50 - ntpq/ntpq-opts.c@1.26, 2006-09-24 05:30:40-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.c@1.26 +3 -3 NTP_4_2_3P50 - ntpq/ntpq-opts.h@1.26, 2006-09-24 05:30:40-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.26 +3 -3 NTP_4_2_3P50 - ntpq/ntpq-opts.texi@1.24, 2006-09-24 05:30:41-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.24 +3 -3 NTP_4_2_3P50 - ntpq/ntpq.1@1.24, 2006-09-24 05:30:42-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.24 +2 -2 NTP_4_2_3P50 - packageinfo.sh@1.42, 2006-09-24 05:30:43-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.42 +1 -1 NTP_4_2_3P50 - sntp/sntp-opts.c@1.23, 2006-09-24 05:30:43-04:00, stenn@whimsy.udel.edu +17 -16 + sntp/sntp-opts.c@1.23 +17 -16 NTP_4_2_3P50 - sntp/sntp-opts.h@1.23, 2006-09-24 05:30:44-04:00, stenn@whimsy.udel.edu +7 -7 + sntp/sntp-opts.h@1.23 +7 -7 NTP_4_2_3P50 - sntp/sntp-opts.texi@1.23, 2006-09-24 05:30:44-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.23 +1 -1 NTP_4_2_3P50 - sntp/sntp.1@1.26, 2006-09-24 05:30:45-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.26 +2 -2 NTP_4_2_3P50 - util/ntp-keygen-opts.c@1.23, 2006-09-24 05:30:46-04:00, stenn@whimsy.udel.edu +43 -43 + util/ntp-keygen-opts.c@1.23 +43 -43 NTP_4_2_3P50 - util/ntp-keygen-opts.h@1.23, 2006-09-24 05:30:46-04:00, stenn@whimsy.udel.edu +10 -10 + util/ntp-keygen-opts.h@1.23 +10 -10 NTP_4_2_3P50 - util/ntp-keygen-opts.texi@1.23, 2006-09-24 05:30:47-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.23 +1 -1 NTP_4_2_3P50 - util/ntp-keygen.1@1.23, 2006-09-24 05:30:48-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.23 +2 -2 NTP_4_2_3P50 -ChangeSet@1.1379.1.21, 2006-09-24 03:03:52-04:00, stenn@whimsy.udel.edu +67 -0 +ChangeSet@1.1379.1.21, 2006-09-24 03:03:52-04:00, stenn@whimsy.udel.edu autogen upgrade - clockstuff/clktest-opts.c@1.4, 2006-09-24 03:02:44-04:00, stenn@whimsy.udel.edu +1 -1 + clockstuff/clktest-opts.c@1.4 +1 -1 autogen upgrade - clockstuff/clktest-opts.c@1.3, 2006-09-24 00:44:30-04:00, stenn@whimsy.udel.edu +39 -39 + clockstuff/clktest-opts.c@1.3 +39 -39 new autogen - clockstuff/clktest-opts.h@1.4, 2006-09-24 03:02:45-04:00, stenn@whimsy.udel.edu +1 -1 + clockstuff/clktest-opts.h@1.4 +1 -1 autogen upgrade - clockstuff/clktest-opts.h@1.3, 2006-09-24 00:44:31-04:00, stenn@whimsy.udel.edu +10 -10 + clockstuff/clktest-opts.h@1.3 +10 -10 new autogen - libopts/autoopts.c@1.7, 2006-09-24 03:02:46-04:00, stenn@whimsy.udel.edu +7 -7 + libopts/autoopts.c@1.7 +7 -7 autogen upgrade - libopts/autoopts.h@1.7, 2006-09-24 03:02:46-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/autoopts.h@1.7 +3 -3 autogen upgrade - libopts/autoopts/options.h@1.7, 2006-09-24 03:03:01-04:00, stenn@whimsy.udel.edu +51 -42 + libopts/autoopts/options.h@1.7 +51 -42 autogen upgrade - libopts/autoopts/usage-txt.h@1.6, 2006-09-24 03:03:02-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/autoopts/usage-txt.h@1.6 +2 -2 autogen upgrade - libopts/boolean.c@1.6, 2006-09-24 03:02:47-04:00, stenn@whimsy.udel.edu +6 -6 + libopts/boolean.c@1.6 +6 -6 autogen upgrade - libopts/compat/compat.h@1.10, 2006-09-24 03:03:03-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/compat/compat.h@1.10 +1 -1 autogen upgrade - libopts/compat/pathfind.c@1.7, 2006-09-24 03:03:04-04:00, stenn@whimsy.udel.edu +16 -16 + libopts/compat/pathfind.c@1.7 +16 -16 autogen upgrade - libopts/compat/snprintf.c@1.4, 2006-09-24 03:03:05-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/compat/snprintf.c@1.4 +2 -2 autogen upgrade - libopts/compat/strchr.c@1.2, 2006-09-24 03:03:05-04:00, stenn@whimsy.udel.edu +5 -5 + libopts/compat/strchr.c@1.2 +5 -5 autogen upgrade - libopts/compat/strdup.c@1.3, 2006-09-24 03:03:06-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/compat/strdup.c@1.3 +1 -1 autogen upgrade - libopts/configfile.c@1.7, 2006-09-24 03:02:48-04:00, stenn@whimsy.udel.edu +23 -23 + libopts/configfile.c@1.7 +23 -23 autogen upgrade - libopts/cook.c@1.6, 2006-09-24 03:02:48-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/cook.c@1.6 +3 -3 autogen upgrade - libopts/enumeration.c@1.6, 2006-09-24 03:02:49-04:00, stenn@whimsy.udel.edu +23 -23 + libopts/enumeration.c@1.6 +23 -23 autogen upgrade - libopts/environment.c@1.6, 2006-09-24 03:02:50-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/environment.c@1.6 +2 -2 autogen upgrade - libopts/genshell.c@1.6, 2006-09-24 03:02:51-04:00, stenn@whimsy.udel.edu +8 -8 + libopts/genshell.c@1.6 +8 -8 autogen upgrade - libopts/genshell.h@1.6, 2006-09-24 03:02:51-04:00, stenn@whimsy.udel.edu +4 -4 + libopts/genshell.h@1.6 +4 -4 autogen upgrade - libopts/load.c@1.7, 2006-09-24 03:02:52-04:00, stenn@whimsy.udel.edu +4 -4 + libopts/load.c@1.7 +4 -4 autogen upgrade - libopts/m4/libopts.m4@1.11, 2006-09-24 03:03:06-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/m4/libopts.m4@1.11 +3 -3 autogen upgrade - libopts/makeshell.c@1.8, 2006-09-24 03:02:53-04:00, stenn@whimsy.udel.edu +13 -12 + libopts/makeshell.c@1.8 +13 -12 autogen upgrade - libopts/nested.c@1.6, 2006-09-24 03:02:53-04:00, stenn@whimsy.udel.edu +38 -38 + libopts/nested.c@1.6 +38 -38 autogen upgrade - libopts/numeric.c@1.6, 2006-09-24 03:02:54-04:00, stenn@whimsy.udel.edu +7 -7 + libopts/numeric.c@1.6 +7 -7 autogen upgrade - libopts/pgusage.c@1.7, 2006-09-24 03:02:54-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/pgusage.c@1.7 +1 -1 autogen upgrade - libopts/proto.h@1.8, 2006-09-24 03:02:54-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/proto.h@1.8 +2 -2 autogen upgrade - libopts/putshell.c@1.7, 2006-09-24 03:02:54-04:00, stenn@whimsy.udel.edu +12 -12 + libopts/putshell.c@1.7 +12 -12 autogen upgrade - libopts/restore.c@1.6, 2006-09-24 03:02:55-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/restore.c@1.6 +1 -1 autogen upgrade - libopts/save.c@1.7, 2006-09-24 03:02:56-04:00, stenn@whimsy.udel.edu +14 -12 + libopts/save.c@1.7 +14 -12 autogen upgrade - libopts/sort.c@1.6, 2006-09-24 03:02:56-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/sort.c@1.6 +1 -1 autogen upgrade - libopts/stack.c@1.7, 2006-09-24 03:02:57-04:00, stenn@whimsy.udel.edu +6 -6 + libopts/stack.c@1.7 +6 -6 autogen upgrade - libopts/streqvcmp.c@1.7, 2006-09-24 03:02:58-04:00, stenn@whimsy.udel.edu +9 -9 + libopts/streqvcmp.c@1.7 +9 -9 autogen upgrade - libopts/text_mmap.c@1.6, 2006-09-24 03:02:58-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/text_mmap.c@1.6 +3 -3 autogen upgrade - libopts/tokenize.c@1.4, 2006-09-24 03:02:59-04:00, stenn@whimsy.udel.edu +8 -8 + libopts/tokenize.c@1.4 +8 -8 autogen upgrade - libopts/usage.c@1.7, 2006-09-24 03:03:00-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/usage.c@1.7 +2 -2 autogen upgrade - libopts/version.c@1.7, 2006-09-24 03:03:01-04:00, stenn@whimsy.udel.edu +9 -9 + libopts/version.c@1.7 +9 -9 autogen upgrade - ntpq/ntpq-opts.c@1.25, 2006-09-24 03:03:07-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.c@1.25 +1 -1 autogen upgrade - ntpq/ntpq-opts.c@1.24, 2006-09-24 00:45:24-04:00, stenn@whimsy.udel.edu +17 -17 + ntpq/ntpq-opts.c@1.24 +17 -17 new autogen - ntpq/ntpq-opts.h@1.25, 2006-09-24 03:03:07-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.h@1.25 +1 -1 autogen upgrade - ntpq/ntpq-opts.h@1.24, 2006-09-24 00:45:25-04:00, stenn@whimsy.udel.edu +5 -5 + ntpq/ntpq-opts.h@1.24 +5 -5 new autogen - sntp/libopts/autoopts.c@1.4, 2006-09-24 03:03:08-04:00, stenn@whimsy.udel.edu +51 -7 + sntp/libopts/autoopts.c@1.4 +51 -7 autogen upgrade - sntp/libopts/autoopts.h@1.5, 2006-09-24 03:03:09-04:00, stenn@whimsy.udel.edu +10 -9 + sntp/libopts/autoopts.h@1.5 +10 -9 autogen upgrade - sntp/libopts/autoopts/options.h@1.4, 2006-09-24 03:03:23-04:00, stenn@whimsy.udel.edu +60 -51 + sntp/libopts/autoopts/options.h@1.4 +60 -51 autogen upgrade - sntp/libopts/autoopts/usage-txt.h@1.3, 2006-09-24 03:03:24-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/autoopts/usage-txt.h@1.3 +2 -2 autogen upgrade - sntp/libopts/boolean.c@1.3, 2006-09-24 03:03:10-04:00, stenn@whimsy.udel.edu +5 -5 + sntp/libopts/boolean.c@1.3 +5 -5 autogen upgrade - sntp/libopts/compat/compat.h@1.6, 2006-09-24 03:03:25-04:00, stenn@whimsy.udel.edu +7 -7 + sntp/libopts/compat/compat.h@1.6 +7 -7 autogen upgrade - sntp/libopts/compat/pathfind.c@1.4, 2006-09-24 03:03:25-04:00, stenn@whimsy.udel.edu +19 -19 + sntp/libopts/compat/pathfind.c@1.4 +19 -19 autogen upgrade - sntp/libopts/compat/snprintf.c@1.3, 2006-09-24 03:03:26-04:00, stenn@whimsy.udel.edu +4 -4 + sntp/libopts/compat/snprintf.c@1.3 +4 -4 autogen upgrade - sntp/libopts/compat/strchr.c@1.2, 2006-09-24 03:03:26-04:00, stenn@whimsy.udel.edu +5 -5 + sntp/libopts/compat/strchr.c@1.2 +5 -5 autogen upgrade - sntp/libopts/compat/strdup.c@1.2, 2006-09-24 03:03:27-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/libopts/compat/strdup.c@1.2 +3 -3 autogen upgrade - sntp/libopts/configfile.c@1.4, 2006-09-24 03:03:10-04:00, stenn@whimsy.udel.edu +37 -35 + sntp/libopts/configfile.c@1.4 +37 -35 autogen upgrade - sntp/libopts/cook.c@1.3, 2006-09-24 03:03:11-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/libopts/cook.c@1.3 +3 -3 autogen upgrade - sntp/libopts/enumeration.c@1.3, 2006-09-24 03:03:12-04:00, stenn@whimsy.udel.edu +23 -23 + sntp/libopts/enumeration.c@1.3 +23 -23 autogen upgrade - sntp/libopts/environment.c@1.3, 2006-09-24 03:03:12-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/environment.c@1.3 +2 -2 autogen upgrade - sntp/libopts/genshell.c@1.3, 2006-09-24 03:03:13-04:00, stenn@whimsy.udel.edu +11 -10 + sntp/libopts/genshell.c@1.3 +11 -10 autogen upgrade - sntp/libopts/genshell.h@1.3, 2006-09-24 03:03:14-04:00, stenn@whimsy.udel.edu +8 -8 + sntp/libopts/genshell.h@1.3 +8 -8 autogen upgrade - sntp/libopts/load.c@1.4, 2006-09-24 03:03:15-04:00, stenn@whimsy.udel.edu +4 -4 + sntp/libopts/load.c@1.4 +4 -4 autogen upgrade - sntp/libopts/m4/libopts.m4@1.8, 2006-09-24 03:03:27-04:00, stenn@whimsy.udel.edu +8 -3 + sntp/libopts/m4/libopts.m4@1.8 +8 -3 autogen upgrade - sntp/libopts/makeshell.c@1.5, 2006-09-24 03:03:15-04:00, stenn@whimsy.udel.edu +13 -12 + sntp/libopts/makeshell.c@1.5 +13 -12 autogen upgrade - sntp/libopts/nested.c@1.3, 2006-09-24 03:03:16-04:00, stenn@whimsy.udel.edu +40 -40 + sntp/libopts/nested.c@1.3 +40 -40 autogen upgrade - sntp/libopts/numeric.c@1.3, 2006-09-24 03:03:17-04:00, stenn@whimsy.udel.edu +6 -6 + sntp/libopts/numeric.c@1.3 +6 -6 autogen upgrade - sntp/libopts/proto.h@1.5, 2006-09-24 03:03:17-04:00, stenn@whimsy.udel.edu +14 -2 + sntp/libopts/proto.h@1.5 +14 -2 autogen upgrade - sntp/libopts/putshell.c@1.4, 2006-09-24 03:03:18-04:00, stenn@whimsy.udel.edu +11 -11 + sntp/libopts/putshell.c@1.4 +11 -11 autogen upgrade - sntp/libopts/save.c@1.4, 2006-09-24 03:03:18-04:00, stenn@whimsy.udel.edu +14 -12 + sntp/libopts/save.c@1.4 +14 -12 autogen upgrade - sntp/libopts/stack.c@1.4, 2006-09-24 03:03:19-04:00, stenn@whimsy.udel.edu +5 -5 + sntp/libopts/stack.c@1.4 +5 -5 autogen upgrade - sntp/libopts/streqvcmp.c@1.4, 2006-09-24 03:03:20-04:00, stenn@whimsy.udel.edu +9 -9 + sntp/libopts/streqvcmp.c@1.4 +9 -9 autogen upgrade - sntp/libopts/text_mmap.c@1.3, 2006-09-24 03:03:20-04:00, stenn@whimsy.udel.edu +12 -16 + sntp/libopts/text_mmap.c@1.3 +12 -16 autogen upgrade - sntp/libopts/tokenize.c@1.3, 2006-09-24 03:03:21-04:00, stenn@whimsy.udel.edu +16 -16 + sntp/libopts/tokenize.c@1.3 +16 -16 autogen upgrade - sntp/libopts/usage.c@1.5, 2006-09-24 03:03:22-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/libopts/usage.c@1.5 +2 -2 autogen upgrade - sntp/libopts/version.c@1.4, 2006-09-24 03:03:23-04:00, stenn@whimsy.udel.edu +9 -9 + sntp/libopts/version.c@1.4 +9 -9 autogen upgrade -ChangeSet@1.1379.1.20, 2006-09-23 17:23:36+00:00, kardel@pogo.udel.edu +5 -0 +ChangeSet@1.1379.1.20, 2006-09-23 17:23:36+00:00, kardel@pogo.udel.edu ntpd.h, ntpd.c, ntp_timer.c, ntp_io.c, cmd_args.c: disable dynamic update when giving up the root privilege - include/ntpd.h@1.97, 2006-09-23 17:22:51+00:00, kardel@pogo.udel.edu +3 -0 + include/ntpd.h@1.97 +3 -0 disable dynamic update when giving up the root privilege - ntpd/cmd_args.c@1.45, 2006-09-23 17:23:01+00:00, kardel@pogo.udel.edu +0 -1 + ntpd/cmd_args.c@1.45 +0 -1 disable dynamic update when giving up the root privilege - ntpd/ntp_io.c@1.234.1.11, 2006-09-23 17:23:02+00:00, kardel@pogo.udel.edu +22 -5 + ntpd/ntp_io.c@1.234.1.11 +22 -5 disable dynamic update when giving up the root privilege - ntpd/ntp_timer.c@1.33, 2006-09-23 17:23:03+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_timer.c@1.33 +1 -1 disable dynamic update when giving up the root privilege - ntpd/ntpd.c@1.82, 2006-09-23 17:23:04+00:00, kardel@pogo.udel.edu +12 -0 + ntpd/ntpd.c@1.82 +12 -0 disable dynamic update when giving up the root privilege -ChangeSet@1.1379.7.2, 2006-09-22 20:27:38-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1379.7.2, 2006-09-22 20:27:38-04:00, stenn@whimsy.udel.edu [Bug 714] ntpq -p should conflict with -i, not -c. - NEWS@1.63, 2006-09-22 20:27:13-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.63 +1 -0 update - ntpq/ntpq-opts.c@1.23, 2006-09-22 20:26:32-04:00, stenn@whimsy.udel.edu +5 -4 + ntpq/ntpq-opts.c@1.23 +5 -4 [Bug 714] ntpq -p should conflict with -i, not -c. - ntpq/ntpq-opts.def@1.11, 2006-09-22 20:26:33-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.def@1.11 +1 -1 [Bug 714] ntpq -p should conflict with -i, not -c. - ntpq/ntpq-opts.h@1.23, 2006-09-22 20:26:33-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.h@1.23 +1 -1 [Bug 714] ntpq -p should conflict with -i, not -c. - ntpq/ntpq-opts.texi@1.23, 2006-09-22 20:26:34-04:00, stenn@whimsy.udel.edu +4 -4 + ntpq/ntpq-opts.texi@1.23 +4 -4 [Bug 714] ntpq -p should conflict with -i, not -c. - ntpq/ntpq.1@1.23, 2006-09-22 20:26:35-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq.1@1.23 +3 -3 [Bug 714] ntpq -p should conflict with -i, not -c. -ChangeSet@1.1379.7.1, 2006-09-22 19:38:01-04:00, stenn@whimsy.udel.edu +34 -0 +ChangeSet@1.1379.7.1, 2006-09-22 19:38:01-04:00, stenn@whimsy.udel.edu Upgrade to libopts-27.4.3 - libopts/Makefile.am@1.5, 2006-09-22 19:36:54-04:00, stenn@whimsy.udel.edu +10 -6 + libopts/Makefile.am@1.5 +10 -6 Upgrade to libopts-27.4.3 - libopts/autoopts.c@1.6, 2006-09-22 19:36:57-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/autoopts.h@1.6, 2006-09-22 19:36:57-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts.h@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/autoopts/options.h@1.6, 2006-09-22 19:36:55-04:00, stenn@whimsy.udel.edu +5 -5 + libopts/autoopts/options.h@1.6 +5 -5 Upgrade to libopts-27.4.3 - libopts/autoopts/usage-txt.h@1.5, 2006-09-22 19:36:55-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts/usage-txt.h@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/boolean.c@1.5, 2006-09-22 19:36:58-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/boolean.c@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/compat/compat.h@1.9, 2006-09-22 19:36:58-04:00, stenn@whimsy.udel.edu +5 -5 + libopts/compat/compat.h@1.9 +5 -5 Upgrade to libopts-27.4.3 - libopts/compat/pathfind.c@1.6, 2006-09-22 19:37:00-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/compat/pathfind.c@1.6 +2 -2 Upgrade to libopts-27.4.3 - libopts/compat/snprintf.c@1.3, 2006-09-22 19:37:01-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/compat/snprintf.c@1.3 +2 -2 Upgrade to libopts-27.4.3 - libopts/compat/strdup.c@1.2, 2006-09-22 19:37:01-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/compat/strdup.c@1.2 +2 -2 Upgrade to libopts-27.4.3 - libopts/compat/windows-config.h@1.3, 2006-09-22 19:37:01-04:00, stenn@whimsy.udel.edu +6 -6 + libopts/compat/windows-config.h@1.3 +6 -6 Upgrade to libopts-27.4.3 - libopts/configfile.c@1.6, 2006-09-22 19:37:02-04:00, stenn@whimsy.udel.edu +12 -13 + libopts/configfile.c@1.6 +12 -13 Upgrade to libopts-27.4.3 - libopts/cook.c@1.5, 2006-09-22 19:37:03-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/cook.c@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/enumeration.c@1.5, 2006-09-22 19:37:04-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/enumeration.c@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/environment.c@1.5, 2006-09-22 19:37:04-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/environment.c@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/genshell.c@1.5, 2006-09-22 19:37:05-04:00, stenn@whimsy.udel.edu +4 -3 + libopts/genshell.c@1.5 +4 -3 Upgrade to libopts-27.4.3 - libopts/genshell.h@1.5, 2006-09-22 19:37:06-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.h@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/load.c@1.6, 2006-09-22 19:37:06-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/load.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/m4/libopts.m4@1.10, 2006-09-22 19:37:07-04:00, stenn@whimsy.udel.edu +6 -1 + libopts/m4/libopts.m4@1.10 +6 -1 Upgrade to libopts-27.4.3 - libopts/makeshell.c@1.7, 2006-09-22 19:37:07-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/makeshell.c@1.7 +1 -1 Upgrade to libopts-27.4.3 - libopts/nested.c@1.5, 2006-09-22 19:37:08-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/nested.c@1.5 +3 -3 Upgrade to libopts-27.4.3 - libopts/numeric.c@1.5, 2006-09-22 19:37:09-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/numeric.c@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/pgusage.c@1.6, 2006-09-22 19:37:09-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/pgusage.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/proto.h@1.7, 2006-09-22 19:37:10-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/proto.h@1.7 +1 -1 Upgrade to libopts-27.4.3 - libopts/putshell.c@1.6, 2006-09-22 19:37:10-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/putshell.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/restore.c@1.5, 2006-09-22 19:37:11-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/restore.c@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/save.c@1.6, 2006-09-22 19:37:12-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/save.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/sort.c@1.5, 2006-09-22 19:37:12-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/sort.c@1.5 +1 -1 Upgrade to libopts-27.4.3 - libopts/stack.c@1.6, 2006-09-22 19:37:13-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/stack.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/streqvcmp.c@1.6, 2006-09-22 19:37:14-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/streqvcmp.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/text_mmap.c@1.5, 2006-09-22 19:37:14-04:00, stenn@whimsy.udel.edu +3 -2 + libopts/text_mmap.c@1.5 +3 -2 Upgrade to libopts-27.4.3 - libopts/tokenize.c@1.3, 2006-09-22 19:37:15-04:00, stenn@whimsy.udel.edu +14 -14 + libopts/tokenize.c@1.3 +14 -14 Upgrade to libopts-27.4.3 - libopts/usage.c@1.6, 2006-09-22 19:37:16-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/usage.c@1.6 +1 -1 Upgrade to libopts-27.4.3 - libopts/version.c@1.6, 2006-09-22 19:37:17-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/version.c@1.6 +1 -1 Upgrade to libopts-27.4.3 -ChangeSet@1.1379.1.18, 2006-09-22 22:58:27+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1379.1.18, 2006-09-22 22:58:27+00:00, kardel@pogo.udel.edu ntp_io.c: add autoconfig enabled code to temporarily set SO_REUSEADDR on wildcard sockets when @@ -9376,1083 +190143,1083 @@ ChangeSet@1.1379.1.18, 2006-09-22 22:58:27+00:00, kardel@pogo.udel.edu +2 -0 add configtest for REUSEADDR enable on wildcard sockets to allow binding to interface addresses - configure.ac@1.388.1.10, 2006-09-22 22:39:30+00:00, kardel@pogo.udel.edu +13 -0 + configure.ac@1.388.1.10 +13 -0 add configtest for REUSEADDR enable on wildcard sockets to allow binding to interface addresses - ntpd/ntp_io.c@1.234.1.10, 2006-09-22 22:45:16+00:00, kardel@pogo.udel.edu +96 -48 + ntpd/ntp_io.c@1.234.1.10 +96 -48 add autoconfig enabled code to temporarily set SO_REUSEADDR on wildcard sockets when binding interface addresses. So OSes need this -ChangeSet@1.1379.1.17, 2006-09-22 17:12:19-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.17, 2006-09-22 17:12:19-04:00, stenn@whimsy.udel.edu Dave fixed a bug in the pll/kernel control code, from a report by Joe Harvell - ntpd/ntp_loopfilter.c@1.126, 2006-09-22 17:12:08-04:00, stenn@whimsy.udel.edu +2 -1 + ntpd/ntp_loopfilter.c@1.126 +2 -1 Dave fixed a bug in the pll/kernel control code, from a report by Joe Harvell -ChangeSet@1.1379.1.16, 2006-09-21 07:42:50-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.16, 2006-09-21 07:42:50-04:00, stenn@whimsy.udel.edu NTP_4_2_3P49 TAG: NTP_4_2_3P49 - ntpd/ntpd-opts.c@1.23, 2006-09-21 07:42:29-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.23 +2 -2 NTP_4_2_3P49 - ntpd/ntpd-opts.h@1.23, 2006-09-21 07:42:30-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.23 +3 -3 NTP_4_2_3P49 - ntpd/ntpd-opts.texi@1.24, 2006-09-21 07:42:30-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.24 +1 -1 NTP_4_2_3P49 - ntpd/ntpd.1@1.23, 2006-09-21 07:42:31-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.23 +2 -2 NTP_4_2_3P49 - ntpd/ntpdsim-opts.c@1.23, 2006-09-21 07:42:32-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.23 +2 -2 NTP_4_2_3P49 - ntpd/ntpdsim-opts.h@1.23, 2006-09-21 07:42:33-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.23 +3 -3 NTP_4_2_3P49 - ntpd/ntpdsim-opts.texi@1.23, 2006-09-21 07:42:33-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.23 +1 -1 NTP_4_2_3P49 - ntpd/ntpdsim.1@1.23, 2006-09-21 07:42:34-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.23 +2 -2 NTP_4_2_3P49 - ntpdc/ntpdc-opts.c@1.23, 2006-09-21 07:42:35-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.23 +2 -2 NTP_4_2_3P49 - ntpdc/ntpdc-opts.h@1.23, 2006-09-21 07:42:36-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.23 +3 -3 NTP_4_2_3P49 - ntpdc/ntpdc-opts.texi@1.23, 2006-09-21 07:42:36-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.23 +1 -1 NTP_4_2_3P49 - ntpdc/ntpdc.1@1.23, 2006-09-21 07:42:37-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.23 +2 -2 NTP_4_2_3P49 - ntpq/ntpq-opts.c@1.22, 2006-09-21 07:42:38-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.22 +2 -2 NTP_4_2_3P49 - ntpq/ntpq-opts.h@1.22, 2006-09-21 07:42:38-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.22 +3 -3 NTP_4_2_3P49 - ntpq/ntpq-opts.texi@1.22, 2006-09-21 07:42:39-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.22 +1 -1 NTP_4_2_3P49 - ntpq/ntpq.1@1.22, 2006-09-21 07:42:40-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.22 +2 -2 NTP_4_2_3P49 - packageinfo.sh@1.41, 2006-09-21 07:42:41-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.41 +1 -1 NTP_4_2_3P49 - sntp/sntp-opts.c@1.22, 2006-09-21 07:42:42-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.22 +2 -2 NTP_4_2_3P49 - sntp/sntp-opts.h@1.22, 2006-09-21 07:42:42-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.22 +3 -3 NTP_4_2_3P49 - sntp/sntp-opts.texi@1.22, 2006-09-21 07:42:43-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.22 +1 -1 NTP_4_2_3P49 - sntp/sntp.1@1.25, 2006-09-21 07:42:44-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.25 +2 -2 NTP_4_2_3P49 - util/ntp-keygen-opts.c@1.22, 2006-09-21 07:42:44-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.22 +2 -2 NTP_4_2_3P49 - util/ntp-keygen-opts.h@1.22, 2006-09-21 07:42:45-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.22 +3 -3 NTP_4_2_3P49 - util/ntp-keygen-opts.texi@1.22, 2006-09-21 07:42:46-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.22 +1 -1 NTP_4_2_3P49 - util/ntp-keygen.1@1.22, 2006-09-21 07:42:47-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.22 +2 -2 NTP_4_2_3P49 -ChangeSet@1.1379.1.15, 2006-09-20 19:41:43-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1379.1.15, 2006-09-20 19:41:43-04:00, stenn@whimsy.udel.edu refclock_wwv.c improvements from Dave Mills - NEWS@1.62, 2006-09-20 19:41:03-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.62 +1 -0 refclock_wwv.c improvements from Dave Mills - ntpd/refclock_wwv.c@1.64, 2006-09-20 19:41:04-04:00, stenn@whimsy.udel.edu +50 -40 + ntpd/refclock_wwv.c@1.64 +50 -40 refclock_wwv.c improvements from Dave Mills -ChangeSet@1.1379.1.14, 2006-09-20 19:31:10-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1379.1.14, 2006-09-20 19:31:10-04:00, stenn@whimsy.udel.edu [Bug 689] Deprecate HEATH GC-1001 II; the driver never worked. - NEWS@1.61, 2006-09-20 19:30:58-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.61 +1 -0 [Bug 689] Deprecate HEATH GC-1001 II; the driver never worked. - ntpd/refclock_heath.c@1.13, 2006-09-20 19:29:32-04:00, stenn@whimsy.udel.edu +39 -10 + ntpd/refclock_heath.c@1.13 +39 -10 [Bug 689] Deprecate HEATH GC-1001 II; the driver never worked. -ChangeSet@1.1379.1.13, 2006-09-19 07:43:25-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.13, 2006-09-19 07:43:25-04:00, stenn@whimsy.udel.edu NTP_4_2_3P48 TAG: NTP_4_2_3P48 - ntpd/ntpd-opts.c@1.22, 2006-09-19 07:43:04-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.22 +2 -2 NTP_4_2_3P48 - ntpd/ntpd-opts.h@1.22, 2006-09-19 07:43:04-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.22 +3 -3 NTP_4_2_3P48 - ntpd/ntpd-opts.texi@1.23, 2006-09-19 07:43:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.23 +1 -1 NTP_4_2_3P48 - ntpd/ntpd.1@1.22, 2006-09-19 07:43:05-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.22 +2 -2 NTP_4_2_3P48 - ntpd/ntpdsim-opts.c@1.22, 2006-09-19 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.22 +2 -2 NTP_4_2_3P48 - ntpd/ntpdsim-opts.h@1.22, 2006-09-19 07:43:08-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.22 +3 -3 NTP_4_2_3P48 - ntpd/ntpdsim-opts.texi@1.22, 2006-09-19 07:43:08-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.22 +1 -1 NTP_4_2_3P48 - ntpd/ntpdsim.1@1.22, 2006-09-19 07:43:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.22 +2 -2 NTP_4_2_3P48 - ntpdc/ntpdc-opts.c@1.22, 2006-09-19 07:43:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.22 +2 -2 NTP_4_2_3P48 - ntpdc/ntpdc-opts.h@1.22, 2006-09-19 07:43:10-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.22 +3 -3 NTP_4_2_3P48 - ntpdc/ntpdc-opts.texi@1.22, 2006-09-19 07:43:11-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.22 +1 -1 NTP_4_2_3P48 - ntpdc/ntpdc.1@1.22, 2006-09-19 07:43:11-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.22 +2 -2 NTP_4_2_3P48 - ntpq/ntpq-opts.c@1.21, 2006-09-19 07:43:12-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.21 +2 -2 NTP_4_2_3P48 - ntpq/ntpq-opts.h@1.21, 2006-09-19 07:43:12-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.21 +3 -3 NTP_4_2_3P48 - ntpq/ntpq-opts.texi@1.21, 2006-09-19 07:43:13-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.21 +1 -1 NTP_4_2_3P48 - ntpq/ntpq.1@1.21, 2006-09-19 07:43:14-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.21 +2 -2 NTP_4_2_3P48 - packageinfo.sh@1.40, 2006-09-19 07:43:15-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.40 +1 -1 NTP_4_2_3P48 - sntp/sntp-opts.c@1.21, 2006-09-19 07:43:15-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.21 +2 -2 NTP_4_2_3P48 - sntp/sntp-opts.h@1.21, 2006-09-19 07:43:16-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.21 +3 -3 NTP_4_2_3P48 - sntp/sntp-opts.texi@1.21, 2006-09-19 07:43:17-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.21 +1 -1 NTP_4_2_3P48 - sntp/sntp.1@1.24, 2006-09-19 07:43:18-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.24 +2 -2 NTP_4_2_3P48 - util/ntp-keygen-opts.c@1.21, 2006-09-19 07:43:19-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.21 +2 -2 NTP_4_2_3P48 - util/ntp-keygen-opts.h@1.21, 2006-09-19 07:43:19-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.21 +3 -3 NTP_4_2_3P48 - util/ntp-keygen-opts.texi@1.21, 2006-09-19 07:43:20-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.21 +1 -1 NTP_4_2_3P48 - util/ntp-keygen.1@1.21, 2006-09-19 07:43:21-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.21 +2 -2 NTP_4_2_3P48 -ChangeSet@1.1251.94.59, 2006-09-18 23:55:40-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.59, 2006-09-18 23:55:40-04:00, stenn@whimsy.udel.edu NTP_4_2_2P4_RC4 TAG: NTP_4_2_2P4_RC4 - packageinfo.sh@1.27.19.2, 2006-09-18 23:55:36-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.19.2 +1 -1 NTP_4_2_2P4_RC4 -ChangeSet@1.1251.94.58, 2006-09-18 18:06:02-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.58, 2006-09-18 18:06:02-04:00, stenn@whimsy.udel.edu [Bug 710] Backport Danny's latest patch - libntp/ntp_rfc2553.c@1.27.1.6, 2006-09-18 18:05:48-04:00, stenn@whimsy.udel.edu +10 -3 + libntp/ntp_rfc2553.c@1.27.1.6 +10 -3 [Bug 710] Backport Danny's latest patch -ChangeSet@1.1379.1.11, 2006-09-18 16:23:45-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.1.11, 2006-09-18 16:23:45-04:00, mayer@pogo.udel.edu Bug #710 Fix new off-by-one error - libntp/ntp_rfc2553.c@1.35, 2006-09-18 16:23:26-04:00, mayer@pogo.udel.edu +1 -1 + libntp/ntp_rfc2553.c@1.35 +1 -1 Bug #710 Fix new off-by-one error -ChangeSet@1.1379.1.10, 2006-09-18 16:17:26-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.1.10, 2006-09-18 16:17:26-04:00, mayer@pogo.udel.edu Bug #655 Added refid for broadcast mode - ntpd/ntp_io.c@1.234.1.9, 2006-09-18 16:17:03-04:00, mayer@pogo.udel.edu +1 -0 + ntpd/ntp_io.c@1.234.1.9 +1 -0 Bug #655 Added refid for broadcast mode -ChangeSet@1.1379.1.9, 2006-09-18 08:46:18-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1379.1.9, 2006-09-18 08:46:18-04:00, mayer@pogo.udel.edu Bug #710 fix the length being copied in getnameinfo - libntp/ntp_rfc2553.c@1.34, 2006-09-18 08:46:00-04:00, mayer@pogo.udel.edu +10 -3 + libntp/ntp_rfc2553.c@1.34 +10 -3 Bug #710 fix the length being copied in getnameinfo -ChangeSet@1.1379.2.35, 2006-09-16 18:54:38-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.35, 2006-09-16 18:54:38-04:00, stenn@whimsy.udel.edu NTP_4_2_3P47 TAG: NTP_4_2_3P47 - ntpd/ntpd-opts.c@1.21, 2006-09-16 18:54:17-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.21 +2 -2 NTP_4_2_3P47 - ntpd/ntpd-opts.h@1.21, 2006-09-16 18:54:18-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.21 +3 -3 NTP_4_2_3P47 - ntpd/ntpd-opts.texi@1.22, 2006-09-16 18:54:18-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.22 +1 -1 NTP_4_2_3P47 - ntpd/ntpd.1@1.21, 2006-09-16 18:54:19-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.21 +2 -2 NTP_4_2_3P47 - ntpd/ntpdsim-opts.c@1.21, 2006-09-16 18:54:20-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.21 +2 -2 NTP_4_2_3P47 - ntpd/ntpdsim-opts.h@1.21, 2006-09-16 18:54:20-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.21 +3 -3 NTP_4_2_3P47 - ntpd/ntpdsim-opts.texi@1.21, 2006-09-16 18:54:21-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.21 +1 -1 NTP_4_2_3P47 - ntpd/ntpdsim.1@1.21, 2006-09-16 18:54:22-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.21 +2 -2 NTP_4_2_3P47 - ntpdc/ntpdc-opts.c@1.21, 2006-09-16 18:54:23-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.21 +2 -2 NTP_4_2_3P47 - ntpdc/ntpdc-opts.h@1.21, 2006-09-16 18:54:23-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.21 +3 -3 NTP_4_2_3P47 - ntpdc/ntpdc-opts.texi@1.21, 2006-09-16 18:54:24-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.21 +1 -1 NTP_4_2_3P47 - ntpdc/ntpdc.1@1.21, 2006-09-16 18:54:25-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.21 +2 -2 NTP_4_2_3P47 - ntpq/ntpq-opts.c@1.20, 2006-09-16 18:54:26-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.20 +2 -2 NTP_4_2_3P47 - ntpq/ntpq-opts.h@1.20, 2006-09-16 18:54:27-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.20 +3 -3 NTP_4_2_3P47 - ntpq/ntpq-opts.texi@1.20, 2006-09-16 18:54:28-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.20 +1 -1 NTP_4_2_3P47 - ntpq/ntpq.1@1.20, 2006-09-16 18:54:29-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.20 +2 -2 NTP_4_2_3P47 - packageinfo.sh@1.39, 2006-09-16 18:54:29-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.39 +1 -1 NTP_4_2_3P47 - sntp/sntp-opts.c@1.20, 2006-09-16 18:54:29-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.20 +2 -2 NTP_4_2_3P47 - sntp/sntp-opts.h@1.20, 2006-09-16 18:54:30-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.20 +3 -3 NTP_4_2_3P47 - sntp/sntp-opts.texi@1.20, 2006-09-16 18:54:31-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.20 +1 -1 NTP_4_2_3P47 - sntp/sntp.1@1.23, 2006-09-16 18:54:32-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.23 +2 -2 NTP_4_2_3P47 - util/ntp-keygen-opts.c@1.20, 2006-09-16 18:54:33-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.20 +2 -2 NTP_4_2_3P47 - util/ntp-keygen-opts.h@1.20, 2006-09-16 18:54:33-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.20 +3 -3 NTP_4_2_3P47 - util/ntp-keygen-opts.texi@1.20, 2006-09-16 18:54:34-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.20 +1 -1 NTP_4_2_3P47 - util/ntp-keygen.1@1.20, 2006-09-16 18:54:35-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.20 +2 -2 NTP_4_2_3P47 -ChangeSet@1.1251.94.57, 2006-09-16 17:32:32-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.57, 2006-09-16 17:32:32-04:00, stenn@whimsy.udel.edu NTP_4_2_2P4_RC3 TAG: NTP_4_2_2P4_RC3 - packageinfo.sh@1.27.19.1, 2006-09-16 17:32:29-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.19.1 +1 -1 NTP_4_2_2P4_RC3 -ChangeSet@1.1251.94.56, 2006-09-16 16:52:07-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.56, 2006-09-16 16:52:07-04:00, stenn@whimsy.udel.edu updated NEWS - NEWS@1.50.1.6, 2006-09-16 16:51:51-04:00, stenn@whimsy.udel.edu +4 -0 + NEWS@1.50.1.6 +4 -0 updated -ChangeSet@1.1251.94.55, 2006-09-16 15:00:36-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.55, 2006-09-16 15:00:36-04:00, stenn@whimsy.udel.edu [Bug 710] compat getnameinfo() has off-by-one error - libntp/ntp_rfc2553.c@1.27.1.5, 2006-09-16 15:00:26-04:00, stenn@whimsy.udel.edu +1 -1 + libntp/ntp_rfc2553.c@1.27.1.5 +1 -1 [Bug 710] compat getnameinfo() has off-by-one error -ChangeSet@1.1379.2.33, 2006-09-13 07:43:13-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.33, 2006-09-13 07:43:13-04:00, stenn@whimsy.udel.edu NTP_4_2_3P46 TAG: NTP_4_2_3P46 - ntpd/ntpd-opts.c@1.20, 2006-09-13 07:42:51-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.20 +2 -2 NTP_4_2_3P46 - ntpd/ntpd-opts.h@1.20, 2006-09-13 07:42:51-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.20 +3 -3 NTP_4_2_3P46 - ntpd/ntpd-opts.texi@1.21, 2006-09-13 07:42:53-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.21 +1 -1 NTP_4_2_3P46 - ntpd/ntpd.1@1.20, 2006-09-13 07:42:53-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.20 +2 -2 NTP_4_2_3P46 - ntpd/ntpdsim-opts.c@1.20, 2006-09-13 07:42:54-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.20 +2 -2 NTP_4_2_3P46 - ntpd/ntpdsim-opts.h@1.20, 2006-09-13 07:42:55-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.20 +3 -3 NTP_4_2_3P46 - ntpd/ntpdsim-opts.texi@1.20, 2006-09-13 07:42:56-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.20 +1 -1 NTP_4_2_3P46 - ntpd/ntpdsim.1@1.20, 2006-09-13 07:42:57-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.20 +2 -2 NTP_4_2_3P46 - ntpdc/ntpdc-opts.c@1.20, 2006-09-13 07:42:58-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.20 +2 -2 NTP_4_2_3P46 - ntpdc/ntpdc-opts.h@1.20, 2006-09-13 07:42:59-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.20 +3 -3 NTP_4_2_3P46 - ntpdc/ntpdc-opts.texi@1.20, 2006-09-13 07:42:59-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.20 +1 -1 NTP_4_2_3P46 - ntpdc/ntpdc.1@1.20, 2006-09-13 07:43:00-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.20 +2 -2 NTP_4_2_3P46 - ntpq/ntpq-opts.c@1.19, 2006-09-13 07:43:01-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.19 +2 -2 NTP_4_2_3P46 - ntpq/ntpq-opts.h@1.19, 2006-09-13 07:43:02-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.19 +3 -3 NTP_4_2_3P46 - ntpq/ntpq-opts.texi@1.19, 2006-09-13 07:43:02-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.19 +1 -1 NTP_4_2_3P46 - ntpq/ntpq.1@1.19, 2006-09-13 07:43:03-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.19 +2 -2 NTP_4_2_3P46 - packageinfo.sh@1.38, 2006-09-13 07:43:04-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.38 +1 -1 NTP_4_2_3P46 - sntp/sntp-opts.c@1.19, 2006-09-13 07:43:04-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.19 +2 -2 NTP_4_2_3P46 - sntp/sntp-opts.h@1.19, 2006-09-13 07:43:05-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.19 +3 -3 NTP_4_2_3P46 - sntp/sntp-opts.texi@1.19, 2006-09-13 07:43:06-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.19 +1 -1 NTP_4_2_3P46 - sntp/sntp.1@1.22, 2006-09-13 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.22 +2 -2 NTP_4_2_3P46 - util/ntp-keygen-opts.c@1.19, 2006-09-13 07:43:07-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.19 +2 -2 NTP_4_2_3P46 - util/ntp-keygen-opts.h@1.19, 2006-09-13 07:43:08-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.19 +3 -3 NTP_4_2_3P46 - util/ntp-keygen-opts.texi@1.19, 2006-09-13 07:43:09-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.19 +1 -1 NTP_4_2_3P46 - util/ntp-keygen.1@1.19, 2006-09-13 07:43:10-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.19 +2 -2 NTP_4_2_3P46 -ChangeSet@1.1379.2.32, 2006-09-13 04:49:48-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1379.2.32, 2006-09-13 04:49:48-04:00, stenn@whimsy.udel.edu WWV documentation fixes from Dave Mills. - html/drivers/driver36.html@1.28, 2006-09-13 04:49:38-04:00, stenn@whimsy.udel.edu +53 -100 + html/drivers/driver36.html@1.28 +53 -100 WWV documentation fixes from Dave Mills. - html/drivers/driver44.html@1.13, 2006-09-13 04:46:46-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver44.html@1.13 +0 -0 Change mode to -rw-rw-r-- -ChangeSet@1.1379.2.31, 2006-09-13 04:44:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.31, 2006-09-13 04:44:52-04:00, stenn@whimsy.udel.edu [Bug 704] Fix documentation typo - html/authopt.html@1.41, 2006-09-13 04:44:37-04:00, stenn@whimsy.udel.edu +2 -2 + html/authopt.html@1.41 +2 -2 [Bug 704] Fix documentation typo -ChangeSet@1.1379.2.30, 2006-09-12 21:35:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.30, 2006-09-12 21:35:52-04:00, stenn@whimsy.udel.edu [Bug 706] Only 1 instance of ntpd should be running - ntpd/ntp_io.c@1.234.1.8, 2006-09-12 21:35:04-04:00, stenn@whimsy.udel.edu +17 -5 + ntpd/ntp_io.c@1.234.1.8 +17 -5 [Bug 706] Only 1 instance of ntpd should be running -ChangeSet@1.1379.2.29, 2006-09-12 07:42:34-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.29, 2006-09-12 07:42:34-04:00, stenn@whimsy.udel.edu NTP_4_2_3P45 TAG: NTP_4_2_3P45 - ntpd/ntpd-opts.c@1.19, 2006-09-12 07:42:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.19 +2 -2 NTP_4_2_3P45 - ntpd/ntpd-opts.h@1.19, 2006-09-12 07:42:09-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.19 +3 -3 NTP_4_2_3P45 - ntpd/ntpd-opts.texi@1.20, 2006-09-12 07:42:10-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.20 +1 -1 NTP_4_2_3P45 - ntpd/ntpd.1@1.19, 2006-09-12 07:42:12-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.19 +2 -2 NTP_4_2_3P45 - ntpd/ntpdsim-opts.c@1.19, 2006-09-12 07:42:13-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.19 +2 -2 NTP_4_2_3P45 - ntpd/ntpdsim-opts.h@1.19, 2006-09-12 07:42:14-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.19 +3 -3 NTP_4_2_3P45 - ntpd/ntpdsim-opts.texi@1.19, 2006-09-12 07:42:14-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.19 +1 -1 NTP_4_2_3P45 - ntpd/ntpdsim.1@1.19, 2006-09-12 07:42:15-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.19 +2 -2 NTP_4_2_3P45 - ntpdc/ntpdc-opts.c@1.19, 2006-09-12 07:42:16-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.19 +2 -2 NTP_4_2_3P45 - ntpdc/ntpdc-opts.h@1.19, 2006-09-12 07:42:16-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.19 +3 -3 NTP_4_2_3P45 - ntpdc/ntpdc-opts.texi@1.19, 2006-09-12 07:42:17-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.19 +1 -1 NTP_4_2_3P45 - ntpdc/ntpdc.1@1.19, 2006-09-12 07:42:18-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.19 +2 -2 NTP_4_2_3P45 - ntpq/ntpq-opts.c@1.18, 2006-09-12 07:42:19-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.18 +2 -2 NTP_4_2_3P45 - ntpq/ntpq-opts.h@1.18, 2006-09-12 07:42:20-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.18 +3 -3 NTP_4_2_3P45 - ntpq/ntpq-opts.texi@1.18, 2006-09-12 07:42:20-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.18 +1 -1 NTP_4_2_3P45 - ntpq/ntpq.1@1.18, 2006-09-12 07:42:21-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.18 +2 -2 NTP_4_2_3P45 - packageinfo.sh@1.37, 2006-09-12 07:42:21-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.37 +1 -1 NTP_4_2_3P45 - sntp/sntp-opts.c@1.18, 2006-09-12 07:42:22-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.18 +2 -2 NTP_4_2_3P45 - sntp/sntp-opts.h@1.18, 2006-09-12 07:42:23-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.18 +3 -3 NTP_4_2_3P45 - sntp/sntp-opts.texi@1.18, 2006-09-12 07:42:23-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.18 +1 -1 NTP_4_2_3P45 - sntp/sntp.1@1.21, 2006-09-12 07:42:24-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.21 +2 -2 NTP_4_2_3P45 - util/ntp-keygen-opts.c@1.18, 2006-09-12 07:42:25-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.18 +2 -2 NTP_4_2_3P45 - util/ntp-keygen-opts.h@1.18, 2006-09-12 07:42:25-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.18 +3 -3 NTP_4_2_3P45 - util/ntp-keygen-opts.texi@1.18, 2006-09-12 07:42:26-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.18 +1 -1 NTP_4_2_3P45 - util/ntp-keygen.1@1.18, 2006-09-12 07:42:27-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.18 +2 -2 NTP_4_2_3P45 -ChangeSet@1.1379.6.1, 2006-09-12 08:25:26+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1379.6.1, 2006-09-12 08:25:26+00:00, kardel@pogo.udel.edu ntp_peer.c: CID 7: avoid calling broadcast/multicast setup with NULL interface - ntpd/ntp_peer.c@1.97, 2006-09-12 08:24:24+00:00, kardel@pogo.udel.edu +13 -11 + ntpd/ntp_peer.c@1.97 +13 -11 CID 7: avoid calling broadcast/multicast setup with NULL interface -ChangeSet@1.1379.2.27, 2006-09-12 04:03:30-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.27, 2006-09-12 04:03:30-04:00, stenn@whimsy.udel.edu WWV refclock fixes from Dave Mills - ntpd/refclock_wwv.c@1.63, 2006-09-12 04:03:17-04:00, stenn@whimsy.udel.edu +7 -4 + ntpd/refclock_wwv.c@1.63 +7 -4 WWV refclock fixes from Dave Mills -ChangeSet@1.1379.2.26, 2006-09-12 06:35:18+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1379.2.26, 2006-09-12 06:35:18+00:00, kardel@pogo.udel.edu ntp_io.c: unify output of "Listening in interface..." message add listing of wildcard interface bindings - ntpd/ntp_io.c@1.234.1.7, 2006-09-12 06:34:04+00:00, kardel@pogo.udel.edu +25 -13 + ntpd/ntp_io.c@1.234.1.7 +25 -13 unify output of "Listening in interface..." message add listing of wildcard interface bindings -ChangeSet@1.1379.2.25, 2006-09-11 07:47:06-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.25, 2006-09-11 07:47:06-04:00, stenn@whimsy.udel.edu NTP_4_2_3P44 TAG: NTP_4_2_3P44 - ntpd/ntpd-opts.c@1.18, 2006-09-11 07:46:45-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.18 +2 -2 NTP_4_2_3P44 - ntpd/ntpd-opts.h@1.18, 2006-09-11 07:46:45-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.18 +3 -3 NTP_4_2_3P44 - ntpd/ntpd-opts.texi@1.19, 2006-09-11 07:46:46-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.19 +1 -1 NTP_4_2_3P44 - ntpd/ntpd.1@1.18, 2006-09-11 07:46:47-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.18 +2 -2 NTP_4_2_3P44 - ntpd/ntpdsim-opts.c@1.18, 2006-09-11 07:46:48-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.18 +2 -2 NTP_4_2_3P44 - ntpd/ntpdsim-opts.h@1.18, 2006-09-11 07:46:49-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.18 +3 -3 NTP_4_2_3P44 - ntpd/ntpdsim-opts.texi@1.18, 2006-09-11 07:46:49-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.18 +1 -1 NTP_4_2_3P44 - ntpd/ntpdsim.1@1.18, 2006-09-11 07:46:50-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.18 +2 -2 NTP_4_2_3P44 - ntpdc/ntpdc-opts.c@1.18, 2006-09-11 07:46:51-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.18 +2 -2 NTP_4_2_3P44 - ntpdc/ntpdc-opts.h@1.18, 2006-09-11 07:46:51-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.18 +3 -3 NTP_4_2_3P44 - ntpdc/ntpdc-opts.texi@1.18, 2006-09-11 07:46:52-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.18 +1 -1 NTP_4_2_3P44 - ntpdc/ntpdc.1@1.18, 2006-09-11 07:46:53-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.18 +2 -2 NTP_4_2_3P44 - ntpq/ntpq-opts.c@1.17, 2006-09-11 07:46:54-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.17 +2 -2 NTP_4_2_3P44 - ntpq/ntpq-opts.h@1.17, 2006-09-11 07:46:55-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.17 +3 -3 NTP_4_2_3P44 - ntpq/ntpq-opts.texi@1.17, 2006-09-11 07:46:56-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.17 +1 -1 NTP_4_2_3P44 - ntpq/ntpq.1@1.17, 2006-09-11 07:46:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.17 +2 -2 NTP_4_2_3P44 - packageinfo.sh@1.36, 2006-09-11 07:46:57-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.36 +1 -1 NTP_4_2_3P44 - sntp/sntp-opts.c@1.17, 2006-09-11 07:46:57-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.17 +2 -2 NTP_4_2_3P44 - sntp/sntp-opts.h@1.17, 2006-09-11 07:46:58-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.17 +3 -3 NTP_4_2_3P44 - sntp/sntp-opts.texi@1.17, 2006-09-11 07:46:59-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.17 +1 -1 NTP_4_2_3P44 - sntp/sntp.1@1.20, 2006-09-11 07:46:59-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.20 +2 -2 NTP_4_2_3P44 - util/ntp-keygen-opts.c@1.17, 2006-09-11 07:47:00-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.17 +2 -2 NTP_4_2_3P44 - util/ntp-keygen-opts.h@1.17, 2006-09-11 07:47:01-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.17 +3 -3 NTP_4_2_3P44 - util/ntp-keygen-opts.texi@1.17, 2006-09-11 07:47:02-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.17 +1 -1 NTP_4_2_3P44 - util/ntp-keygen.1@1.17, 2006-09-11 07:47:03-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.17 +2 -2 NTP_4_2_3P44 -ChangeSet@1.1379.2.24, 2006-09-10 20:47:32-04:00, stenn@whimsy.udel.edu +29 -0 +ChangeSet@1.1379.2.24, 2006-09-10 20:47:32-04:00, stenn@whimsy.udel.edu libopts-27.4.3 updates - libopts/autoopts.c@1.5, 2006-09-10 20:46:57-04:00, stenn@whimsy.udel.edu +46 -2 + libopts/autoopts.c@1.5 +46 -2 libopts-27.4.3 updates - libopts/autoopts.h@1.5, 2006-09-10 20:46:57-04:00, stenn@whimsy.udel.edu +8 -7 + libopts/autoopts.h@1.5 +8 -7 libopts-27.4.3 updates - libopts/autoopts/options.h@1.5, 2006-09-10 20:47:14-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/autoopts/options.h@1.5 +3 -3 libopts-27.4.3 updates - libopts/autoopts/usage-txt.h@1.4, 2006-09-10 20:47:15-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts/usage-txt.h@1.4 +1 -1 libopts-27.4.3 updates - libopts/boolean.c@1.4, 2006-09-10 20:46:58-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/boolean.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/compat/compat.h@1.8, 2006-09-10 20:47:16-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/compat/compat.h@1.8 +1 -1 libopts-27.4.3 updates - libopts/compat/pathfind.c@1.5, 2006-09-10 20:47:17-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/compat/pathfind.c@1.5 +2 -2 libopts-27.4.3 updates - libopts/configfile.c@1.5, 2006-09-10 20:46:59-04:00, stenn@whimsy.udel.edu +5 -2 + libopts/configfile.c@1.5 +5 -2 libopts-27.4.3 updates - libopts/cook.c@1.4, 2006-09-10 20:47:00-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/cook.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/enumeration.c@1.4, 2006-09-10 20:47:00-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/enumeration.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/environment.c@1.4, 2006-09-10 20:47:02-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/environment.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/genshell.c@1.4, 2006-09-10 20:47:03-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/genshell.h@1.4, 2006-09-10 20:47:03-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.h@1.4 +1 -1 libopts-27.4.3 updates - libopts/load.c@1.5, 2006-09-10 20:47:03-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/load.c@1.5 +1 -1 libopts-27.4.3 updates - libopts/m4/libopts.m4@1.9, 2006-09-10 20:47:17-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/m4/libopts.m4@1.9 +1 -1 libopts-27.4.3 updates - libopts/makeshell.c@1.6, 2006-09-10 20:47:05-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/makeshell.c@1.6 +1 -1 libopts-27.4.3 updates - libopts/nested.c@1.4, 2006-09-10 20:47:06-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/nested.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/numeric.c@1.4, 2006-09-10 20:47:06-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/numeric.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/pgusage.c@1.5, 2006-09-10 20:47:06-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/pgusage.c@1.5 +1 -1 libopts-27.4.3 updates - libopts/proto.h@1.6, 2006-09-10 20:47:07-04:00, stenn@whimsy.udel.edu +13 -1 + libopts/proto.h@1.6 +13 -1 libopts-27.4.3 updates - libopts/putshell.c@1.5, 2006-09-10 20:47:07-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/putshell.c@1.5 +1 -1 libopts-27.4.3 updates - libopts/restore.c@1.4, 2006-09-10 20:47:08-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/restore.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/save.c@1.5, 2006-09-10 20:47:09-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/save.c@1.5 +1 -1 libopts-27.4.3 updates - libopts/sort.c@1.4, 2006-09-10 20:47:09-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/sort.c@1.4 +1 -1 libopts-27.4.3 updates - libopts/stack.c@1.5, 2006-09-10 20:47:10-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/stack.c@1.5 +1 -1 libopts-27.4.3 updates - libopts/streqvcmp.c@1.5, 2006-09-10 20:47:11-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/streqvcmp.c@1.5 +1 -1 libopts-27.4.3 updates - libopts/text_mmap.c@1.4, 2006-09-10 20:47:12-04:00, stenn@whimsy.udel.edu +3 -8 + libopts/text_mmap.c@1.4 +3 -8 libopts-27.4.3 updates - libopts/usage.c@1.5, 2006-09-10 20:47:13-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/usage.c@1.5 +1 -1 libopts-27.4.3 updates - libopts/version.c@1.5, 2006-09-10 20:47:14-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/version.c@1.5 +1 -1 libopts-27.4.3 updates -ChangeSet@1.1379.2.23, 2006-09-10 18:03:04-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.23, 2006-09-10 18:03:04-04:00, stenn@whimsy.udel.edu NTP_4_2_3P43 TAG: NTP_4_2_3P43 - ntpd/ntpd-opts.c@1.17, 2006-09-10 18:02:42-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.17 +2 -2 NTP_4_2_3P43 - ntpd/ntpd-opts.h@1.17, 2006-09-10 18:02:43-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.17 +3 -3 NTP_4_2_3P43 - ntpd/ntpd-opts.texi@1.18, 2006-09-10 18:02:44-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.18 +1 -1 NTP_4_2_3P43 - ntpd/ntpd.1@1.17, 2006-09-10 18:02:45-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.17 +2 -2 NTP_4_2_3P43 - ntpd/ntpdsim-opts.c@1.17, 2006-09-10 18:02:45-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.17 +2 -2 NTP_4_2_3P43 - ntpd/ntpdsim-opts.h@1.17, 2006-09-10 18:02:46-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.17 +3 -3 NTP_4_2_3P43 - ntpd/ntpdsim-opts.texi@1.17, 2006-09-10 18:02:47-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.17 +1 -1 NTP_4_2_3P43 - ntpd/ntpdsim.1@1.17, 2006-09-10 18:02:48-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.17 +2 -2 NTP_4_2_3P43 - ntpdc/ntpdc-opts.c@1.17, 2006-09-10 18:02:49-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.17 +2 -2 NTP_4_2_3P43 - ntpdc/ntpdc-opts.h@1.17, 2006-09-10 18:02:49-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.17 +3 -3 NTP_4_2_3P43 - ntpdc/ntpdc-opts.texi@1.17, 2006-09-10 18:02:49-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.17 +1 -1 NTP_4_2_3P43 - ntpdc/ntpdc.1@1.17, 2006-09-10 18:02:50-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.17 +2 -2 NTP_4_2_3P43 - ntpq/ntpq-opts.c@1.16, 2006-09-10 18:02:51-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.16 +2 -2 NTP_4_2_3P43 - ntpq/ntpq-opts.h@1.16, 2006-09-10 18:02:52-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.16 +3 -3 NTP_4_2_3P43 - ntpq/ntpq-opts.texi@1.16, 2006-09-10 18:02:53-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.16 +1 -1 NTP_4_2_3P43 - ntpq/ntpq.1@1.16, 2006-09-10 18:02:54-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.16 +2 -2 NTP_4_2_3P43 - packageinfo.sh@1.35, 2006-09-10 18:02:55-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.35 +1 -1 NTP_4_2_3P43 - sntp/sntp-opts.c@1.16, 2006-09-10 18:02:55-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.16 +2 -2 NTP_4_2_3P43 - sntp/sntp-opts.h@1.16, 2006-09-10 18:02:56-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.16 +3 -3 NTP_4_2_3P43 - sntp/sntp-opts.texi@1.16, 2006-09-10 18:02:57-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.16 +1 -1 NTP_4_2_3P43 - sntp/sntp.1@1.19, 2006-09-10 18:02:58-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.19 +2 -2 NTP_4_2_3P43 - util/ntp-keygen-opts.c@1.16, 2006-09-10 18:02:58-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.16 +2 -2 NTP_4_2_3P43 - util/ntp-keygen-opts.h@1.16, 2006-09-10 18:02:59-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.16 +3 -3 NTP_4_2_3P43 - util/ntp-keygen-opts.texi@1.16, 2006-09-10 18:03:00-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.16 +1 -1 NTP_4_2_3P43 - util/ntp-keygen.1@1.16, 2006-09-10 18:03:01-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.16 +2 -2 NTP_4_2_3P43 -ChangeSet@1.1379.2.22, 2006-09-10 15:58:36-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.22, 2006-09-10 15:58:36-04:00, stenn@whimsy.udel.edu [CID 3] Not a typo. Rename variables so Harlan can read the code easier - libntp/recvbuff.c@1.24, 2006-09-10 15:58:11-04:00, stenn@whimsy.udel.edu +5 -4 + libntp/recvbuff.c@1.24 +5 -4 [CID 3] Not a typo. Rename variables so Harlan can read the code easier -ChangeSet@1.1379.2.21, 2006-09-10 07:48:06-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.21, 2006-09-10 07:48:06-04:00, stenn@whimsy.udel.edu NTP_4_2_3P42 TAG: NTP_4_2_3P42 - ntpd/ntpd-opts.c@1.16, 2006-09-10 07:47:46-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.16 +2 -2 NTP_4_2_3P42 - ntpd/ntpd-opts.h@1.16, 2006-09-10 07:47:46-04:00, stenn@whimsy.udel.edu +142 -171 + ntpd/ntpd-opts.h@1.16 +142 -171 NTP_4_2_3P42 - ntpd/ntpd-opts.texi@1.17, 2006-09-10 07:47:47-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.17 +1 -1 NTP_4_2_3P42 - ntpd/ntpd.1@1.16, 2006-09-10 07:47:48-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.16 +2 -2 NTP_4_2_3P42 - ntpd/ntpdsim-opts.c@1.16, 2006-09-10 07:47:49-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.16 +2 -2 NTP_4_2_3P42 - ntpd/ntpdsim-opts.h@1.16, 2006-09-10 07:47:50-04:00, stenn@whimsy.udel.edu +178 -216 + ntpd/ntpdsim-opts.h@1.16 +178 -216 NTP_4_2_3P42 - ntpd/ntpdsim-opts.texi@1.16, 2006-09-10 07:47:50-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.16 +1 -1 NTP_4_2_3P42 - ntpd/ntpdsim.1@1.16, 2006-09-10 07:47:51-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.16 +2 -2 NTP_4_2_3P42 - ntpdc/ntpdc-opts.c@1.16, 2006-09-10 07:47:52-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.16 +2 -2 NTP_4_2_3P42 - ntpdc/ntpdc-opts.h@1.16, 2006-09-10 07:47:52-04:00, stenn@whimsy.udel.edu +65 -75 + ntpdc/ntpdc-opts.h@1.16 +65 -75 NTP_4_2_3P42 - ntpdc/ntpdc-opts.texi@1.16, 2006-09-10 07:47:53-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.16 +1 -1 NTP_4_2_3P42 - ntpdc/ntpdc.1@1.16, 2006-09-10 07:47:53-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.16 +2 -2 NTP_4_2_3P42 - ntpq/ntpq-opts.c@1.15, 2006-09-10 07:47:54-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.15 +2 -2 NTP_4_2_3P42 - ntpq/ntpq-opts.h@1.15, 2006-09-10 07:47:55-04:00, stenn@whimsy.udel.edu +55 -63 + ntpq/ntpq-opts.h@1.15 +55 -63 NTP_4_2_3P42 - ntpq/ntpq-opts.texi@1.15, 2006-09-10 07:47:55-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.15 +1 -1 NTP_4_2_3P42 - ntpq/ntpq.1@1.15, 2006-09-10 07:47:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.15 +2 -2 NTP_4_2_3P42 - packageinfo.sh@1.34, 2006-09-10 07:47:57-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.34 +1 -1 NTP_4_2_3P42 - sntp/sntp-opts.c@1.15, 2006-09-10 07:47:57-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.15 +2 -2 NTP_4_2_3P42 - sntp/sntp-opts.h@1.15, 2006-09-10 07:47:58-04:00, stenn@whimsy.udel.edu +50 -57 + sntp/sntp-opts.h@1.15 +50 -57 NTP_4_2_3P42 - sntp/sntp-opts.texi@1.15, 2006-09-10 07:47:59-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.15 +1 -1 NTP_4_2_3P42 - sntp/sntp.1@1.18, 2006-09-10 07:47:59-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.18 +2 -2 NTP_4_2_3P42 - util/ntp-keygen-opts.c@1.15, 2006-09-10 07:48:00-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.15 +2 -2 NTP_4_2_3P42 - util/ntp-keygen-opts.h@1.15, 2006-09-10 07:48:01-04:00, stenn@whimsy.udel.edu +102 -121 + util/ntp-keygen-opts.h@1.15 +102 -121 NTP_4_2_3P42 - util/ntp-keygen-opts.texi@1.15, 2006-09-10 07:48:01-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.15 +1 -1 NTP_4_2_3P42 - util/ntp-keygen.1@1.15, 2006-09-10 07:48:02-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.15 +2 -2 NTP_4_2_3P42 -ChangeSet@1.1379.2.20, 2006-09-09 20:11:07-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.20, 2006-09-09 20:11:07-04:00, stenn@whimsy.udel.edu Fix a typo. - libntp/recvbuff.c@1.23, 2006-09-09 20:10:52-04:00, stenn@whimsy.udel.edu +1 -1 + libntp/recvbuff.c@1.23 +1 -1 Fix a typo. -ChangeSet@1.1379.2.19, 2006-09-09 18:29:08-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1379.2.19, 2006-09-09 18:29:08-04:00, stenn@whimsy.udel.edu autogen upgrade - clockstuff/clktest-opts.c@1.2, 2006-09-09 18:28:55-04:00, stenn@whimsy.udel.edu +53 -36 + clockstuff/clktest-opts.c@1.2 +53 -36 autogen upgrade - clockstuff/clktest-opts.h@1.2, 2006-09-09 18:28:55-04:00, stenn@whimsy.udel.edu +72 -14 + clockstuff/clktest-opts.h@1.2 +72 -14 autogen upgrade -ChangeSet@1.1379.2.18, 2006-09-09 18:21:20-04:00, stenn@whimsy.udel.edu +30 -0 +ChangeSet@1.1379.2.18, 2006-09-09 18:21:20-04:00, stenn@whimsy.udel.edu libopts-27.4.3 - libopts/COPYING.lgpl@1.2, 2006-09-09 18:20:42-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/COPYING.lgpl@1.2 +1 -1 libopts-27.4.3 - libopts/Makefile.am@1.4, 2006-09-09 18:20:43-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/Makefile.am@1.4 +1 -1 libopts-27.4.3 - libopts/autoopts.c@1.4, 2006-09-09 18:20:43-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts.c@1.4 +1 -1 libopts-27.4.3 - libopts/autoopts/options.h@1.4, 2006-09-09 18:20:57-04:00, stenn@whimsy.udel.edu +5 -5 + libopts/autoopts/options.h@1.4 +5 -5 libopts-27.4.3 - libopts/autoopts/usage-txt.h@1.3, 2006-09-09 18:20:58-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/autoopts/usage-txt.h@1.3 +1 -1 libopts-27.4.3 - libopts/boolean.c@1.3, 2006-09-09 18:20:44-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/boolean.c@1.3 +1 -1 libopts-27.4.3 - libopts/compat/compat.h@1.7, 2006-09-09 18:20:59-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/compat/compat.h@1.7 +3 -3 libopts-27.4.3 - libopts/compat/pathfind.c@1.4, 2006-09-09 18:21:00-04:00, stenn@whimsy.udel.edu +5 -5 + libopts/compat/pathfind.c@1.4 +5 -5 libopts-27.4.3 - libopts/compat/windows-config.h@1.2, 2006-09-09 18:21:01-04:00, stenn@whimsy.udel.edu +4 -4 + libopts/compat/windows-config.h@1.2 +4 -4 libopts-27.4.3 - libopts/configfile.c@1.4, 2006-09-09 18:20:44-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/configfile.c@1.4 +1 -1 libopts-27.4.3 - libopts/cook.c@1.3, 2006-09-09 18:20:45-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/cook.c@1.3 +1 -1 libopts-27.4.3 - libopts/enumeration.c@1.3, 2006-09-09 18:20:45-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/enumeration.c@1.3 +1 -1 libopts-27.4.3 - libopts/environment.c@1.3, 2006-09-09 18:20:46-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/environment.c@1.3 +1 -1 libopts-27.4.3 - libopts/genshell.c@1.3, 2006-09-09 18:20:47-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/genshell.c@1.3 +1 -1 libopts-27.4.3 - libopts/genshell.h@1.3, 2006-09-09 18:20:48-04:00, stenn@whimsy.udel.edu +6 -6 + libopts/genshell.h@1.3 +6 -6 libopts-27.4.3 - libopts/load.c@1.4, 2006-09-09 18:20:48-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/load.c@1.4 +1 -1 libopts-27.4.3 - libopts/m4/libopts.m4@1.8, 2006-09-09 18:21:01-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/m4/libopts.m4@1.8 +1 -1 libopts-27.4.3 - libopts/makeshell.c@1.5, 2006-09-09 18:20:48-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/makeshell.c@1.5 +1 -1 libopts-27.4.3 - libopts/nested.c@1.3, 2006-09-09 18:20:50-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/nested.c@1.3 +1 -1 libopts-27.4.3 - libopts/numeric.c@1.3, 2006-09-09 18:20:50-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/numeric.c@1.3 +1 -1 libopts-27.4.3 - libopts/pgusage.c@1.4, 2006-09-09 18:20:51-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/pgusage.c@1.4 +1 -1 libopts-27.4.3 - libopts/proto.h@1.5, 2006-09-09 18:20:51-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/proto.h@1.5 +1 -1 libopts-27.4.3 - libopts/putshell.c@1.4, 2006-09-09 18:20:51-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/putshell.c@1.4 +1 -1 libopts-27.4.3 - libopts/restore.c@1.3, 2006-09-09 18:20:52-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/restore.c@1.3 +1 -1 libopts-27.4.3 - libopts/save.c@1.4, 2006-09-09 18:20:53-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/save.c@1.4 +1 -1 libopts-27.4.3 - libopts/sort.c@1.3, 2006-09-09 18:20:54-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/sort.c@1.3 +1 -1 libopts-27.4.3 - libopts/stack.c@1.4, 2006-09-09 18:20:54-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/stack.c@1.4 +1 -1 libopts-27.4.3 - libopts/streqvcmp.c@1.4, 2006-09-09 18:20:55-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/streqvcmp.c@1.4 +1 -1 libopts-27.4.3 - libopts/text_mmap.c@1.3, 2006-09-09 18:20:56-04:00, stenn@whimsy.udel.edu +7 -7 + libopts/text_mmap.c@1.3 +7 -7 libopts-27.4.3 - libopts/version.c@1.4, 2006-09-09 18:20:57-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/version.c@1.4 +1 -1 libopts-27.4.3 -ChangeSet@1.1379.5.1, 2006-09-09 05:19:19-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.5.1, 2006-09-09 05:19:19-04:00, stenn@whimsy.udel.edu NTP_4_2_3P41 TAG: NTP_4_2_3P41 - ntpd/ntpd-opts.c@1.15, 2006-09-09 05:18:58-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.15 +2 -2 NTP_4_2_3P41 - ntpd/ntpd-opts.h@1.15, 2006-09-09 05:18:59-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.15 +3 -3 NTP_4_2_3P41 - ntpd/ntpd-opts.texi@1.16, 2006-09-09 05:19:00-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.16 +1 -1 NTP_4_2_3P41 - ntpd/ntpd.1@1.15, 2006-09-09 05:19:00-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.15 +2 -2 NTP_4_2_3P41 - ntpd/ntpdsim-opts.c@1.15, 2006-09-09 05:19:01-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.15 +2 -2 NTP_4_2_3P41 - ntpd/ntpdsim-opts.h@1.15, 2006-09-09 05:19:02-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.15 +3 -3 NTP_4_2_3P41 - ntpd/ntpdsim-opts.texi@1.15, 2006-09-09 05:19:03-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.15 +1 -1 NTP_4_2_3P41 - ntpd/ntpdsim.1@1.15, 2006-09-09 05:19:03-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.15 +2 -2 NTP_4_2_3P41 - ntpdc/ntpdc-opts.c@1.15, 2006-09-09 05:19:04-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.15 +2 -2 NTP_4_2_3P41 - ntpdc/ntpdc-opts.h@1.15, 2006-09-09 05:19:05-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.15 +3 -3 NTP_4_2_3P41 - ntpdc/ntpdc-opts.texi@1.15, 2006-09-09 05:19:05-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.15 +1 -1 NTP_4_2_3P41 - ntpdc/ntpdc.1@1.15, 2006-09-09 05:19:06-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.15 +2 -2 NTP_4_2_3P41 - ntpq/ntpq-opts.c@1.14, 2006-09-09 05:19:07-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.14 +2 -2 NTP_4_2_3P41 - ntpq/ntpq-opts.h@1.14, 2006-09-09 05:19:07-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.14 +3 -3 NTP_4_2_3P41 - ntpq/ntpq-opts.texi@1.14, 2006-09-09 05:19:08-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.14 +1 -1 NTP_4_2_3P41 - ntpq/ntpq.1@1.14, 2006-09-09 05:19:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.14 +2 -2 NTP_4_2_3P41 - packageinfo.sh@1.33, 2006-09-09 05:19:10-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.33 +1 -1 NTP_4_2_3P41 - sntp/sntp-opts.c@1.14, 2006-09-09 05:19:10-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.14 +2 -2 NTP_4_2_3P41 - sntp/sntp-opts.h@1.14, 2006-09-09 05:19:11-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.14 +3 -3 NTP_4_2_3P41 - sntp/sntp-opts.texi@1.14, 2006-09-09 05:19:12-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.14 +1 -1 NTP_4_2_3P41 - sntp/sntp.1@1.17, 2006-09-09 05:19:12-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.17 +2 -2 NTP_4_2_3P41 - util/ntp-keygen-opts.c@1.14, 2006-09-09 05:19:13-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.14 +2 -2 NTP_4_2_3P41 - util/ntp-keygen-opts.h@1.14, 2006-09-09 05:19:14-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.14 +3 -3 NTP_4_2_3P41 - util/ntp-keygen-opts.texi@1.14, 2006-09-09 05:19:15-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.14 +1 -1 NTP_4_2_3P41 - util/ntp-keygen.1@1.14, 2006-09-09 05:19:16-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.14 +2 -2 NTP_4_2_3P41 -ChangeSet@1.1379.2.16, 2006-09-09 07:16:37+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1379.2.16, 2006-09-09 07:16:37+00:00, kardel@pogo.udel.edu ntp_io.c: remove unnecessary test - ntpd/ntp_io.c@1.234.1.6, 2006-09-09 07:15:44+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.234.1.6 +1 -1 remove unnecessary test -ChangeSet@1.1379.2.15, 2006-09-08 21:33:04-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.15, 2006-09-08 21:33:04-04:00, stenn@whimsy.udel.edu [CID 6] Fix a possible null dereference - ntpd/ntp_io.c@1.234.1.5, 2006-09-08 21:32:51-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntp_io.c@1.234.1.5 +3 -3 [CID 6] Fix a possible null dereference -ChangeSet@1.1379.2.14, 2006-09-08 19:23:32-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1379.2.14, 2006-09-08 19:23:32-04:00, stenn@whimsy.udel.edu [Bug 691] ntp_monitor()/restrictions() interaction fixes - include/ntpd.h@1.96, 2006-09-08 19:22:49-04:00, stenn@whimsy.udel.edu +2 -2 + include/ntpd.h@1.96 +2 -2 [Bug 691] ntp_monitor()/restrictions() interaction fixes - ntpd/ntp_monitor.c@1.18, 2006-09-08 19:23:08-04:00, stenn@whimsy.udel.edu +7 -4 + ntpd/ntp_monitor.c@1.18 +7 -4 [Bug 691] ntp_monitor()/restrictions() interaction fixes - ntpd/ntp_proto.c@1.248, 2006-09-08 19:23:09-04:00, stenn@whimsy.udel.edu +3 -2 + ntpd/ntp_proto.c@1.248 +3 -2 [Bug 691] ntp_monitor()/restrictions() interaction fixes - ntpd/ntp_restrict.c@1.22, 2006-09-08 19:23:11-04:00, stenn@whimsy.udel.edu +3 -2 + ntpd/ntp_restrict.c@1.22 +3 -2 [Bug 691] ntp_monitor()/restrictions() interaction fixes -ChangeSet@1.1379.4.1, 2006-09-08 17:20:34-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.4.1, 2006-09-08 17:20:34-04:00, stenn@whimsy.udel.edu autogen dependency cleanup - ntpdc/Makefile.am@1.33, 2006-09-08 17:20:02-04:00, stenn@whimsy.udel.edu +4 -4 + ntpdc/Makefile.am@1.33 +4 -4 autogen dependency cleanup -ChangeSet@1.1379.2.12, 2006-09-08 20:42:56+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1379.2.12, 2006-09-08 20:42:56+00:00, kardel@pogo.udel.edu configure.ac: add config fragment to conditionally re-bind sockets for OSes that fail to flush cached routes when more @@ -10462,1476 +191229,1476 @@ ChangeSet@1.1379.2.12, 2006-09-08 20:42:56+00:00, kardel@pogo.udel.edu +2 -0 flush cached routes when more specific routes are discovered. - configure.ac@1.388.1.9, 2006-09-08 20:32:42+00:00, kardel@pogo.udel.edu +13 -0 + configure.ac@1.388.1.9 +13 -0 add config fragment to conditionally re-bind sockets for OSes that fail to flush cached routes when more specific route are discovered. - ntpd/ntp_io.c@1.234.1.4, 2006-09-08 20:37:49+00:00, kardel@pogo.udel.edu +10 -3 + ntpd/ntp_io.c@1.234.1.4 +10 -3 re-bind sockets on OSes that fail to flush cached routes when more specific routes are discovered. -ChangeSet@1.1379.2.11, 2006-09-07 21:45:01-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.11, 2006-09-07 21:45:01-04:00, stenn@whimsy.udel.edu NTP_4_2_3P39 TAG: NTP_4_2_3P39 - ntpd/ntpd-opts.c@1.14, 2006-09-07 21:44:44-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.14 +2 -2 NTP_4_2_3P39 - ntpd/ntpd-opts.h@1.14, 2006-09-07 21:44:44-04:00, stenn@whimsy.udel.edu +185 -4 + ntpd/ntpd-opts.h@1.14 +185 -4 NTP_4_2_3P39 - ntpd/ntpd-opts.texi@1.15, 2006-09-07 21:44:45-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.15 +1 -1 NTP_4_2_3P39 - ntpd/ntpd.1@1.14, 2006-09-07 21:44:46-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.14 +2 -2 NTP_4_2_3P39 - ntpd/ntpdsim-opts.c@1.14, 2006-09-07 21:44:46-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.14 +2 -2 NTP_4_2_3P39 - ntpd/ntpdsim-opts.h@1.14, 2006-09-07 21:44:47-04:00, stenn@whimsy.udel.edu +239 -4 + ntpd/ntpdsim-opts.h@1.14 +239 -4 NTP_4_2_3P39 - ntpd/ntpdsim-opts.texi@1.14, 2006-09-07 21:44:48-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.14 +1 -1 NTP_4_2_3P39 - ntpd/ntpdsim.1@1.14, 2006-09-07 21:44:48-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.14 +2 -2 NTP_4_2_3P39 - ntpdc/ntpdc-opts.c@1.14, 2006-09-07 21:44:49-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.14 +2 -2 NTP_4_2_3P39 - ntpdc/ntpdc-opts.h@1.14, 2006-09-07 21:44:49-04:00, stenn@whimsy.udel.edu +71 -4 + ntpdc/ntpdc-opts.h@1.14 +71 -4 NTP_4_2_3P39 - ntpdc/ntpdc-opts.texi@1.14, 2006-09-07 21:44:50-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.14 +1 -1 NTP_4_2_3P39 - ntpdc/ntpdc.1@1.14, 2006-09-07 21:44:51-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.14 +2 -2 NTP_4_2_3P39 - ntpq/ntpq-opts.c@1.13, 2006-09-07 21:44:51-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.13 +2 -2 NTP_4_2_3P39 - ntpq/ntpq-opts.h@1.13, 2006-09-07 21:44:52-04:00, stenn@whimsy.udel.edu +59 -4 + ntpq/ntpq-opts.h@1.13 +59 -4 NTP_4_2_3P39 - ntpq/ntpq-opts.texi@1.13, 2006-09-07 21:44:53-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.13 +1 -1 NTP_4_2_3P39 - ntpq/ntpq.1@1.13, 2006-09-07 21:44:53-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.13 +2 -2 NTP_4_2_3P39 - packageinfo.sh@1.32, 2006-09-07 21:44:54-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.32 +1 -1 NTP_4_2_3P39 - sntp/sntp-opts.c@1.13, 2006-09-07 21:44:55-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.c@1.13 +3 -3 NTP_4_2_3P39 - sntp/sntp-opts.h@1.13, 2006-09-07 21:44:55-04:00, stenn@whimsy.udel.edu +53 -4 + sntp/sntp-opts.h@1.13 +53 -4 NTP_4_2_3P39 - sntp/sntp-opts.texi@1.13, 2006-09-07 21:44:55-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.13 +1 -1 NTP_4_2_3P39 - sntp/sntp.1@1.16, 2006-09-07 21:44:56-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.16 +2 -2 NTP_4_2_3P39 - util/ntp-keygen-opts.c@1.13, 2006-09-07 21:44:57-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.13 +2 -2 NTP_4_2_3P39 - util/ntp-keygen-opts.h@1.13, 2006-09-07 21:44:57-04:00, stenn@whimsy.udel.edu +125 -4 + util/ntp-keygen-opts.h@1.13 +125 -4 NTP_4_2_3P39 - util/ntp-keygen-opts.texi@1.13, 2006-09-07 21:44:58-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.13 +1 -1 NTP_4_2_3P39 - util/ntp-keygen.1@1.13, 2006-09-07 21:44:58-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.13 +2 -2 NTP_4_2_3P39 -ChangeSet@1.1379.2.10, 2006-09-07 19:12:01-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1379.2.10, 2006-09-07 19:12:01-04:00, stenn@whimsy.udel.edu autogen dependency cleanup - ntpd/Makefile.am@1.52, 2006-09-07 19:11:48-04:00, stenn@whimsy.udel.edu +8 -8 + ntpd/Makefile.am@1.52 +8 -8 autogen dependency cleanup - ntpq/Makefile.am@1.25, 2006-09-07 19:11:49-04:00, stenn@whimsy.udel.edu +4 -4 + ntpq/Makefile.am@1.25 +4 -4 autogen dependency cleanup - util/Makefile.am@1.34, 2006-09-07 19:11:50-04:00, stenn@whimsy.udel.edu +4 -4 + util/Makefile.am@1.34 +4 -4 autogen dependency cleanup -ChangeSet@1.1379.2.9, 2006-09-07 19:07:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.9, 2006-09-07 19:07:52-04:00, stenn@whimsy.udel.edu More WWV cleanup/fixes from Dave Mills - ntpd/refclock_wwv.c@1.62, 2006-09-07 19:07:37-04:00, stenn@whimsy.udel.edu +6 -11 + ntpd/refclock_wwv.c@1.62 +6 -11 More WWV cleanup/fixes from Dave Mills -ChangeSet@1.1379.2.8, 2006-09-07 03:22:04-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.8, 2006-09-07 03:22:04-04:00, stenn@whimsy.udel.edu sntp/autogen-version.def should be ignored by bk - BitKeeper/etc/ignore@1.58, 2006-09-07 03:19:09-04:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/etc/ignore@1.58 +1 -0 added sntp/autogen-version.def -ChangeSet@1.1379.2.7, 2006-09-07 02:06:36-04:00, stenn@whimsy.udel.edu +12 -0 +ChangeSet@1.1379.2.7, 2006-09-07 02:06:36-04:00, stenn@whimsy.udel.edu [Bug 695] autogen uprgrade: warn/protect macro collisions - clockstuff/clktest-opts.def@1.4, 2006-09-07 02:06:15-04:00, stenn@whimsy.udel.edu +1 -0 + clockstuff/clktest-opts.def@1.4 +1 -0 [Bug 695] autogen uprgrade: warn/protect macro collisions - include/Makefile.am@1.24, 2006-09-07 02:06:15-04:00, stenn@whimsy.udel.edu +1 -1 + include/Makefile.am@1.24 +1 -1 [Bug 695] autogen uprgrade: warn/protect macro collisions - include/autogen-version.def@1.2, 2006-09-07 02:06:15-04:00, stenn@whimsy.udel.edu +1 -0 + include/autogen-version.def@1.2 +1 -0 [Bug 695] autogen uprgrade: warn/protect macro collisions - ntpd/Makefile.am@1.51, 2006-09-07 02:06:15-04:00, stenn@whimsy.udel.edu +3 -2 + ntpd/Makefile.am@1.51 +3 -2 [Bug 695] autogen uprgrade: warn/protect macro collisions - ntpdc/Makefile.am@1.32, 2006-09-07 02:06:16-04:00, stenn@whimsy.udel.edu +3 -2 + ntpdc/Makefile.am@1.32 +3 -2 [Bug 695] autogen uprgrade: warn/protect macro collisions - ntpdc/ntpdc-opts.def@1.12, 2006-09-07 02:06:17-04:00, stenn@whimsy.udel.edu +1 -0 + ntpdc/ntpdc-opts.def@1.12 +1 -0 [Bug 695] autogen uprgrade: warn/protect macro collisions - ntpq/Makefile.am@1.24, 2006-09-07 02:06:18-04:00, stenn@whimsy.udel.edu +3 -2 + ntpq/Makefile.am@1.24 +3 -2 [Bug 695] autogen uprgrade: warn/protect macro collisions - ntpq/ntpq-opts.def@1.10, 2006-09-07 02:06:18-04:00, stenn@whimsy.udel.edu +1 -0 + ntpq/ntpq-opts.def@1.10 +1 -0 [Bug 695] autogen uprgrade: warn/protect macro collisions - sntp/Makefile.am@1.21, 2006-09-07 02:06:19-04:00, stenn@whimsy.udel.edu +12 -2 + sntp/Makefile.am@1.21 +12 -2 [Bug 695] autogen uprgrade: warn/protect macro collisions - sntp/sntp-opts.def@1.9, 2006-09-07 02:06:19-04:00, stenn@whimsy.udel.edu +2 -0 + sntp/sntp-opts.def@1.9 +2 -0 [Bug 695] autogen uprgrade: warn/protect macro collisions - util/Makefile.am@1.33, 2006-09-07 02:06:20-04:00, stenn@whimsy.udel.edu +3 -2 + util/Makefile.am@1.33 +3 -2 [Bug 695] autogen uprgrade: warn/protect macro collisions - util/ntp-keygen-opts.def@1.6, 2006-09-07 02:06:21-04:00, stenn@whimsy.udel.edu +1 -0 + util/ntp-keygen-opts.def@1.6 +1 -0 [Bug 695] autogen uprgrade: warn/protect macro collisions -ChangeSet@1.1379.2.6, 2006-09-07 01:58:07-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.2.6, 2006-09-07 01:58:07-04:00, stenn@whimsy.udel.edu WWV refclock changes from Dave Mills - ntpd/refclock_wwv.c@1.61, 2006-09-07 01:57:55-04:00, stenn@whimsy.udel.edu +245 -294 + ntpd/refclock_wwv.c@1.61 +245 -294 WWV refclock changes from Dave Mills -ChangeSet@1.1379.2.5, 2006-09-07 00:48:56-05:00, stenn@poog.il.thewrittenword.com +1 -0 +ChangeSet@1.1379.2.5, 2006-09-07 00:48:56-05:00, stenn@poog.il.thewrittenword.com [Bug 693] fix configure when there is __adtimex and no ntp_*time - configure.ac@1.388.1.8, 2006-09-07 00:48:15-05:00, stenn@poog.il.thewrittenword.com +7 -10 + configure.ac@1.388.1.8 +7 -10 [Bug 693] fix configure when there is __adtimex and no ntp_*time -ChangeSet@1.1379.2.4, 2006-08-31 02:06:16-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.2.4, 2006-08-31 02:06:16-04:00, stenn@whimsy.udel.edu NTP_4_2_3P38 TAG: NTP_4_2_3P38 - ntpd/ntpd-opts.c@1.13, 2006-08-31 02:05:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.13 +2 -2 NTP_4_2_3P38 - ntpd/ntpd-opts.h@1.13, 2006-08-31 02:05:57-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.13 +3 -3 NTP_4_2_3P38 - ntpd/ntpd-opts.texi@1.14, 2006-08-31 02:05:57-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.14 +1 -1 NTP_4_2_3P38 - ntpd/ntpd.1@1.13, 2006-08-31 02:05:58-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.13 +2 -2 NTP_4_2_3P38 - ntpd/ntpdsim-opts.c@1.13, 2006-08-31 02:05:59-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.13 +2 -2 NTP_4_2_3P38 - ntpd/ntpdsim-opts.h@1.13, 2006-08-31 02:05:59-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.13 +3 -3 NTP_4_2_3P38 - ntpd/ntpdsim-opts.texi@1.13, 2006-08-31 02:06:00-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.13 +1 -1 NTP_4_2_3P38 - ntpd/ntpdsim.1@1.13, 2006-08-31 02:06:01-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.13 +2 -2 NTP_4_2_3P38 - ntpdc/ntpdc-opts.c@1.13, 2006-08-31 02:06:02-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.13 +2 -2 NTP_4_2_3P38 - ntpdc/ntpdc-opts.h@1.13, 2006-08-31 02:06:03-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.13 +3 -3 NTP_4_2_3P38 - ntpdc/ntpdc-opts.texi@1.13, 2006-08-31 02:06:03-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.13 +1 -1 NTP_4_2_3P38 - ntpdc/ntpdc.1@1.13, 2006-08-31 02:06:04-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.13 +2 -2 NTP_4_2_3P38 - ntpq/ntpq-opts.c@1.12, 2006-08-31 02:06:05-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.12 +2 -2 NTP_4_2_3P38 - ntpq/ntpq-opts.h@1.12, 2006-08-31 02:06:05-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.12 +3 -3 NTP_4_2_3P38 - ntpq/ntpq-opts.texi@1.12, 2006-08-31 02:06:06-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.12 +1 -1 NTP_4_2_3P38 - ntpq/ntpq.1@1.12, 2006-08-31 02:06:07-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.12 +2 -2 NTP_4_2_3P38 - packageinfo.sh@1.31, 2006-08-31 02:06:07-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.31 +1 -1 NTP_4_2_3P38 - sntp/sntp-opts.c@1.12, 2006-08-31 02:06:08-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.12 +2 -2 NTP_4_2_3P38 - sntp/sntp-opts.h@1.12, 2006-08-31 02:06:09-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.12 +3 -3 NTP_4_2_3P38 - sntp/sntp-opts.texi@1.12, 2006-08-31 02:06:09-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.12 +1 -1 NTP_4_2_3P38 - sntp/sntp.1@1.15, 2006-08-31 02:06:10-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.15 +2 -2 NTP_4_2_3P38 - util/ntp-keygen-opts.c@1.12, 2006-08-31 02:06:11-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.12 +2 -2 NTP_4_2_3P38 - util/ntp-keygen-opts.h@1.12, 2006-08-31 02:06:11-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.12 +3 -3 NTP_4_2_3P38 - util/ntp-keygen-opts.texi@1.12, 2006-08-31 02:06:12-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.12 +1 -1 NTP_4_2_3P38 - util/ntp-keygen.1@1.12, 2006-08-31 02:06:13-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.12 +2 -2 NTP_4_2_3P38 -ChangeSet@1.1379.2.3, 2006-08-30 06:28:59-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1379.2.3, 2006-08-30 06:28:59-04:00, stenn@whimsy.udel.edu [Bug 340, 342] Deprecate broken TRAK and MSF EES refclocks - NEWS@1.59, 2006-08-30 06:28:23-04:00, stenn@whimsy.udel.edu +2 -0 + NEWS@1.59 +2 -0 [Bug 340, 342] Deprecate broken TRAK and MSF EES refclocks - configure.ac@1.388.1.7, 2006-08-30 06:28:26-04:00, stenn@whimsy.udel.edu +20 -18 + configure.ac@1.388.1.7 +20 -18 [Bug 340, 342] Deprecate broken TRAK and MSF EES refclocks - ntpd/Makefile.am@1.50, 2006-08-30 06:27:33-04:00, stenn@whimsy.udel.edu +6 -3 + ntpd/Makefile.am@1.50 +6 -3 [Bug 340, 342] Deprecate broken TRAK and MSF EES refclocks - ntpd/ntp_control.c@1.87, 2006-08-30 06:27:35-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntp_control.c@1.87 +3 -3 [Bug 340, 342] Deprecate broken TRAK and MSF EES refclocks - ntpd/refclock_conf.c@1.26, 2006-08-30 06:27:42-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/refclock_conf.c@1.26 +4 -4 [Bug 340, 342] Deprecate broken TRAK and MSF EES refclocks -ChangeSet@1.1379.3.1, 2006-08-29 23:45:21-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.3.1, 2006-08-29 23:45:21-04:00, stenn@whimsy.udel.edu Fix dependency order problem - sntp/Makefile.am@1.20, 2006-08-29 23:45:10-04:00, stenn@whimsy.udel.edu +2 -1 + sntp/Makefile.am@1.20 +2 -1 Fix dependency order problem -ChangeSet@1.1379.2.1, 2006-08-29 16:05:33-04:00, neal@pogo.udel.edu +1 -0 +ChangeSet@1.1379.2.1, 2006-08-29 16:05:33-04:00, neal@pogo.udel.edu refclock_bancomm.c: [BUG 421] add support for bc637PCI - ntpd/refclock_bancomm.c@1.9, 2006-08-29 15:55:13-04:00, neal@pogo.udel.edu +138 -104 + ntpd/refclock_bancomm.c@1.9 +138 -104 [BUG 421] add support for bc637PCI -ChangeSet@1.1353.9.51, 2006-08-29 07:55:52-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1353.9.51, 2006-08-29 07:55:52-04:00, mayer@pogo.udel.edu Bug #656: Multicast address argument copied incorrectly - ntpdate/ntpdate.c@1.59, 2006-08-29 07:55:16-04:00, mayer@pogo.udel.edu +1 -1 + ntpdate/ntpdate.c@1.59 +1 -1 Bug #656: Multicast address argument copied wrongly -ChangeSet@1.1379.1.5, 2006-08-29 06:47:20-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.5, 2006-08-29 06:47:20-04:00, stenn@whimsy.udel.edu loopfilter changes from Dave Mills - ntpd/ntp_loopfilter.c@1.125, 2006-08-29 06:47:08-04:00, stenn@whimsy.udel.edu +12 -15 + ntpd/ntp_loopfilter.c@1.125 +12 -15 loopfilter changes from Dave Mills -ChangeSet@1.1379.1.4, 2006-08-29 08:16:22+00:00, stenn@ntp1.isc.org +1 -0 +ChangeSet@1.1379.1.4, 2006-08-29 08:16:22+00:00, stenn@ntp1.isc.org [Bug 603] Cleanup the configure patch for the libelf fix - configure.ac@1.388.1.6, 2006-08-29 08:16:13+00:00, stenn@ntp1.isc.org +12 -9 + configure.ac@1.388.1.6 +12 -9 [Bug 603] Cleanup the configure patch for the libelf fix -ChangeSet@1.1379.1.3, 2006-08-28 21:48:10-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1379.1.3, 2006-08-28 21:48:10-04:00, stenn@whimsy.udel.edu NTP_4_2_3P37 TAG: NTP_4_2_3P37 - ntpd/ntpd-opts.c@1.12, 2006-08-28 21:47:46-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.12 +2 -2 NTP_4_2_3P37 - ntpd/ntpd-opts.h@1.12, 2006-08-28 21:47:47-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.12 +3 -3 NTP_4_2_3P37 - ntpd/ntpd-opts.texi@1.13, 2006-08-28 21:47:48-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.13 +1 -1 NTP_4_2_3P37 - ntpd/ntpd.1@1.12, 2006-08-28 21:47:48-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.12 +2 -2 NTP_4_2_3P37 - ntpd/ntpdsim-opts.c@1.12, 2006-08-28 21:47:49-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.12 +2 -2 NTP_4_2_3P37 - ntpd/ntpdsim-opts.h@1.12, 2006-08-28 21:47:50-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.12 +3 -3 NTP_4_2_3P37 - ntpd/ntpdsim-opts.texi@1.12, 2006-08-28 21:47:50-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.12 +1 -1 NTP_4_2_3P37 - ntpd/ntpdsim.1@1.12, 2006-08-28 21:47:51-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.12 +2 -2 NTP_4_2_3P37 - ntpdc/ntpdc-opts.c@1.12, 2006-08-28 21:47:52-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.12 +2 -2 NTP_4_2_3P37 - ntpdc/ntpdc-opts.h@1.12, 2006-08-28 21:47:54-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.12 +3 -3 NTP_4_2_3P37 - ntpdc/ntpdc-opts.texi@1.12, 2006-08-28 21:47:54-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.12 +1 -1 NTP_4_2_3P37 - ntpdc/ntpdc.1@1.12, 2006-08-28 21:47:55-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.12 +2 -2 NTP_4_2_3P37 - ntpq/ntpq-opts.c@1.11, 2006-08-28 21:47:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.11 +2 -2 NTP_4_2_3P37 - ntpq/ntpq-opts.h@1.11, 2006-08-28 21:47:57-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.11 +3 -3 NTP_4_2_3P37 - ntpq/ntpq-opts.texi@1.11, 2006-08-28 21:47:58-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.11 +1 -1 NTP_4_2_3P37 - ntpq/ntpq.1@1.11, 2006-08-28 21:47:58-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.11 +2 -2 NTP_4_2_3P37 - packageinfo.sh@1.30, 2006-08-28 21:47:59-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.30 +1 -1 NTP_4_2_3P37 - sntp/sntp-opts.c@1.11, 2006-08-28 21:48:00-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.11 +2 -2 NTP_4_2_3P37 - sntp/sntp-opts.h@1.11, 2006-08-28 21:48:01-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.11 +3 -3 NTP_4_2_3P37 - sntp/sntp-opts.texi@1.11, 2006-08-28 21:48:01-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.11 +1 -1 NTP_4_2_3P37 - sntp/sntp.1@1.14, 2006-08-28 21:48:02-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.14 +2 -2 NTP_4_2_3P37 - util/ntp-keygen-opts.c@1.11, 2006-08-28 21:48:03-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.11 +2 -2 NTP_4_2_3P37 - util/ntp-keygen-opts.h@1.11, 2006-08-28 21:48:03-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.11 +3 -3 NTP_4_2_3P37 - util/ntp-keygen-opts.texi@1.11, 2006-08-28 21:48:04-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.11 +1 -1 NTP_4_2_3P37 - util/ntp-keygen.1@1.11, 2006-08-28 21:48:05-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.11 +2 -2 NTP_4_2_3P37 -ChangeSet@1.1379.1.2, 2006-08-28 05:03:05-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.2, 2006-08-28 05:03:05-04:00, stenn@whimsy.udel.edu [Bug 603] Only link with libelf if we need it. - configure.ac@1.388.1.5, 2006-08-28 05:02:46-04:00, stenn@whimsy.udel.edu +22 -19 + configure.ac@1.388.1.5 +22 -19 [Bug 603] Only link with libelf if we need it. -ChangeSet@1.1379.1.1, 2006-08-27 23:47:09-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1379.1.1, 2006-08-27 23:47:09-04:00, stenn@whimsy.udel.edu [Bug 692] sys_limitrejected is no longer incremented - ntpd/ntp_proto.c@1.247, 2006-08-27 23:46:56-04:00, stenn@whimsy.udel.edu +1 -0 + ntpd/ntp_proto.c@1.247 +1 -0 [Bug 692] sys_limitrejected is no longer incremented -ChangeSet@1.1379, 2006-08-27 20:49:57-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1379, 2006-08-27 20:49:57-04:00, stenn@whimsy.udel.edu [Bug 688] Fix documentation typos - html/clockopt.html@1.19, 2006-08-27 20:49:38-04:00, stenn@whimsy.udel.edu +2 -2 + html/clockopt.html@1.19 +2 -2 [Bug 688] Fix documentation typos - html/notes.html@1.18, 2006-08-27 20:49:42-04:00, stenn@whimsy.udel.edu +10 -10 + html/notes.html@1.18 +10 -10 [Bug 688] Fix documentation typos - html/ntpd.html@1.39, 2006-08-27 20:49:43-04:00, stenn@whimsy.udel.edu +1 -1 + html/ntpd.html@1.39 +1 -1 [Bug 688] Fix documentation typos - html/ntpdate.html@1.18, 2006-08-27 20:49:44-04:00, stenn@whimsy.udel.edu +3 -1 + html/ntpdate.html@1.18 +3 -1 [Bug 688] Fix documentation typos - html/ntpdc.html@1.25, 2006-08-27 20:49:44-04:00, stenn@whimsy.udel.edu +2 -2 + html/ntpdc.html@1.25 +2 -2 [Bug 688] Fix documentation typos -ChangeSet@1.1378, 2006-08-27 23:44:15+00:00, stenn@ntp1.isc.org +1 -0 +ChangeSet@1.1378, 2006-08-27 23:44:15+00:00, stenn@ntp1.isc.org [Bug 153] Avoid DNS lookups of known netmasks or refclocks - ntpd/ntp_config.c@1.141, 2006-08-27 23:44:07+00:00, stenn@ntp1.isc.org +30 -4 + ntpd/ntp_config.c@1.141 +30 -4 [Bug 153] Avoid DNS lookups of known netmasks or refclocks -ChangeSet@1.1353.21.3, 2006-08-26 15:10:29-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1353.21.3, 2006-08-26 15:10:29-04:00, stenn@whimsy.udel.edu NTP_4_2_3P36 TAG: NTP_4_2_3P36 - ntpd/ntpd-opts.c@1.11, 2006-08-26 15:10:05-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.11 +2 -2 NTP_4_2_3P36 - ntpd/ntpd-opts.h@1.11, 2006-08-26 15:10:05-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.11 +3 -3 NTP_4_2_3P36 - ntpd/ntpd-opts.texi@1.12, 2006-08-26 15:10:06-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.12 +1 -1 NTP_4_2_3P36 - ntpd/ntpd.1@1.11, 2006-08-26 15:10:07-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.11 +2 -2 NTP_4_2_3P36 - ntpd/ntpdsim-opts.c@1.11, 2006-08-26 15:10:08-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.11 +2 -2 NTP_4_2_3P36 - ntpd/ntpdsim-opts.h@1.11, 2006-08-26 15:10:09-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.11 +3 -3 NTP_4_2_3P36 - ntpd/ntpdsim-opts.texi@1.11, 2006-08-26 15:10:10-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.11 +1 -1 NTP_4_2_3P36 - ntpd/ntpdsim.1@1.11, 2006-08-26 15:10:10-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.11 +2 -2 NTP_4_2_3P36 - ntpdc/ntpdc-opts.c@1.11, 2006-08-26 15:10:11-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.11 +2 -2 NTP_4_2_3P36 - ntpdc/ntpdc-opts.h@1.11, 2006-08-26 15:10:12-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.11 +3 -3 NTP_4_2_3P36 - ntpdc/ntpdc-opts.texi@1.11, 2006-08-26 15:10:12-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.11 +1 -1 NTP_4_2_3P36 - ntpdc/ntpdc.1@1.11, 2006-08-26 15:10:13-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.11 +2 -2 NTP_4_2_3P36 - ntpq/ntpq-opts.c@1.10, 2006-08-26 15:10:14-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.10 +2 -2 NTP_4_2_3P36 - ntpq/ntpq-opts.h@1.10, 2006-08-26 15:10:14-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.10 +3 -3 NTP_4_2_3P36 - ntpq/ntpq-opts.texi@1.10, 2006-08-26 15:10:15-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.10 +1 -1 NTP_4_2_3P36 - ntpq/ntpq.1@1.10, 2006-08-26 15:10:16-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.10 +2 -2 NTP_4_2_3P36 - packageinfo.sh@1.29, 2006-08-26 15:10:17-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.29 +1 -1 NTP_4_2_3P36 - sntp/sntp-opts.c@1.10, 2006-08-26 15:10:17-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.10 +2 -2 NTP_4_2_3P36 - sntp/sntp-opts.h@1.10, 2006-08-26 15:10:18-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.10 +3 -3 NTP_4_2_3P36 - sntp/sntp-opts.texi@1.10, 2006-08-26 15:10:19-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.10 +1 -1 NTP_4_2_3P36 - sntp/sntp.1@1.13, 2006-08-26 15:10:20-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.13 +2 -2 NTP_4_2_3P36 - util/ntp-keygen-opts.c@1.10, 2006-08-26 15:10:20-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.10 +2 -2 NTP_4_2_3P36 - util/ntp-keygen-opts.h@1.10, 2006-08-26 15:10:21-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.10 +3 -3 NTP_4_2_3P36 - util/ntp-keygen-opts.texi@1.10, 2006-08-26 15:10:22-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.10 +1 -1 NTP_4_2_3P36 - util/ntp-keygen.1@1.10, 2006-08-26 15:10:22-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.10 +2 -2 NTP_4_2_3P36 -ChangeSet@1.1251.94.54, 2006-08-26 05:34:06-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.54, 2006-08-26 05:34:06-04:00, stenn@whimsy.udel.edu NTP_4_2_2P4_RC2 TAG: NTP_4_2_2P4_RC2 - packageinfo.sh@1.27.18.1, 2006-08-26 05:34:03-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.18.1 +1 -1 NTP_4_2_2P4_RC2 -ChangeSet@1.1353.22.1, 2006-08-26 05:05:56-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1353.22.1, 2006-08-26 05:05:56-04:00, stenn@whimsy.udel.edu NTP_4_2_3P35 TAG: NTP_4_2_3P35 - ntpd/ntpd-opts.c@1.10, 2006-08-26 05:05:35-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.10 +2 -2 NTP_4_2_3P35 - ntpd/ntpd-opts.h@1.10, 2006-08-26 05:05:36-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.10 +3 -3 NTP_4_2_3P35 - ntpd/ntpd-opts.texi@1.11, 2006-08-26 05:05:36-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.11 +1 -1 NTP_4_2_3P35 - ntpd/ntpd.1@1.10, 2006-08-26 05:05:37-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.10 +2 -2 NTP_4_2_3P35 - ntpd/ntpdsim-opts.c@1.10, 2006-08-26 05:05:38-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.10 +2 -2 NTP_4_2_3P35 - ntpd/ntpdsim-opts.h@1.10, 2006-08-26 05:05:39-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.10 +3 -3 NTP_4_2_3P35 - ntpd/ntpdsim-opts.texi@1.10, 2006-08-26 05:05:39-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.10 +1 -1 NTP_4_2_3P35 - ntpd/ntpdsim.1@1.10, 2006-08-26 05:05:41-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.10 +2 -2 NTP_4_2_3P35 - ntpdc/ntpdc-opts.c@1.10, 2006-08-26 05:05:41-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.10 +2 -2 NTP_4_2_3P35 - ntpdc/ntpdc-opts.h@1.10, 2006-08-26 05:05:42-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.10 +3 -3 NTP_4_2_3P35 - ntpdc/ntpdc-opts.texi@1.10, 2006-08-26 05:05:43-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.10 +1 -1 NTP_4_2_3P35 - ntpdc/ntpdc.1@1.10, 2006-08-26 05:05:43-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.10 +2 -2 NTP_4_2_3P35 - ntpq/ntpq-opts.c@1.9, 2006-08-26 05:05:44-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.9 +2 -2 NTP_4_2_3P35 - ntpq/ntpq-opts.h@1.9, 2006-08-26 05:05:45-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.9 +3 -3 NTP_4_2_3P35 - ntpq/ntpq-opts.texi@1.9, 2006-08-26 05:05:45-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.9 +1 -1 NTP_4_2_3P35 - ntpq/ntpq.1@1.9, 2006-08-26 05:05:46-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.9 +2 -2 NTP_4_2_3P35 - packageinfo.sh@1.28, 2006-08-26 05:05:47-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.28 +1 -1 NTP_4_2_3P35 - sntp/sntp-opts.c@1.9, 2006-08-26 05:05:47-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.9 +2 -2 NTP_4_2_3P35 - sntp/sntp-opts.h@1.9, 2006-08-26 05:05:48-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.9 +3 -3 NTP_4_2_3P35 - sntp/sntp-opts.texi@1.9, 2006-08-26 05:05:49-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.9 +1 -1 NTP_4_2_3P35 - sntp/sntp.1@1.12, 2006-08-26 05:05:50-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.12 +2 -2 NTP_4_2_3P35 - util/ntp-keygen-opts.c@1.9, 2006-08-26 05:05:51-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.9 +2 -2 NTP_4_2_3P35 - util/ntp-keygen-opts.h@1.9, 2006-08-26 05:05:52-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.9 +3 -3 NTP_4_2_3P35 - util/ntp-keygen-opts.texi@1.9, 2006-08-26 05:05:52-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.9 +1 -1 NTP_4_2_3P35 - util/ntp-keygen.1@1.9, 2006-08-26 05:05:53-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.9 +2 -2 NTP_4_2_3P35 -ChangeSet@1.1251.94.53, 2006-08-25 15:55:51-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.53, 2006-08-25 15:55:51-04:00, stenn@whimsy.udel.edu update README.patches - README.patches@1.3, 2006-08-25 15:55:28-04:00, stenn@whimsy.udel.edu +11 -1 + README.patches@1.3 +11 -1 update -ChangeSet@1.1251.94.52, 2006-08-25 09:00:40-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.94.52, 2006-08-25 09:00:40-04:00, mayer@pogo.udel.edu Bug #690: Fix length returned. Prevents buffer overflow - ports/winnt/libntp/dnslookup.c@1.3.1.1, 2006-08-25 09:00:24-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/libntp/dnslookup.c@1.3.1.1 +1 -1 Bug #690: Fix length returned. Prevents buffer overflow -ChangeSet@1.1353.20.1, 2006-08-25 08:57:39-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1353.20.1, 2006-08-25 08:57:39-04:00, mayer@pogo.udel.edu Bug #690: Cleanup fix. Erroneous #define - libntp/ntp_rfc2553.c@1.32, 2006-08-25 08:57:05-04:00, mayer@pogo.udel.edu +0 -1 + libntp/ntp_rfc2553.c@1.32 +0 -1 Bug #690: Cleanup fix. Erroneous #define -ChangeSet@1.1353.9.48, 2006-08-25 02:26:29-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.48, 2006-08-25 02:26:29-04:00, stenn@whimsy.udel.edu Dependency cleanup - sntp/Makefile.am@1.19, 2006-08-25 02:26:15-04:00, stenn@whimsy.udel.edu +6 -6 + sntp/Makefile.am@1.19 +6 -6 Dependency cleanup -ChangeSet@1.1353.9.47, 2006-08-25 02:24:00-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.47, 2006-08-25 02:24:00-04:00, stenn@whimsy.udel.edu ntp_optind needs a declaration, not a definition - ntpdc/ntpdc.c@1.54, 2006-08-25 02:23:48-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc.c@1.54 +1 -1 ntp_optind needs a declaration, not a definition -ChangeSet@1.1251.94.51, 2006-08-24 19:50:32-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.51, 2006-08-24 19:50:32-04:00, stenn@whimsy.udel.edu br-flock: mort lives - br-flock@1.10, 2006-08-24 19:49:33-04:00, stenn@whimsy.udel.edu +1 -1 + br-flock@1.10 +1 -1 br-flock: mort lives -ChangeSet@1.1353.9.45, 2006-08-24 17:12:32-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1353.9.45, 2006-08-24 17:12:32-04:00, stenn@whimsy.udel.edu Changes from Dave Mills: Rename MAXSIG to MAXAMP to avoid a collision, tweak the code - ntpd/refclock_chu.c@1.38, 2006-08-24 17:10:52-04:00, stenn@whimsy.udel.edu +6 -6 + ntpd/refclock_chu.c@1.38 +6 -6 Rename MAXSIG to MAXAMP to avoid a collision - ntpd/refclock_irig.c@1.23, 2006-08-24 17:10:52-04:00, stenn@whimsy.udel.edu +6 -6 + ntpd/refclock_irig.c@1.23 +6 -6 Rename MAXSIG to MAXAMP to avoid a collision - ntpd/refclock_wwv.c@1.60, 2006-08-24 17:11:27-04:00, stenn@whimsy.udel.edu +124 -119 + ntpd/refclock_wwv.c@1.60 +124 -119 Rename MAXSIG to MAXAMP to avoid a collision, tweak the code -ChangeSet@1.1353.9.44, 2006-08-24 16:04:18-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.44, 2006-08-24 16:04:18-04:00, stenn@whimsy.udel.edu [Bug 638] remove STREAMS_TLI comment from legacy info - include/ntp_machine.h@1.23, 2006-08-24 16:04:02-04:00, stenn@whimsy.udel.edu +0 -2 + include/ntp_machine.h@1.23 +0 -2 [Bug 638] remove STREAMS_TLI comment from legacy info -ChangeSet@1.1353.19.1, 2006-08-24 09:10:50-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1353.19.1, 2006-08-24 09:10:50-04:00, mayer@pogo.udel.edu Bug #690:Proper fix for length issue - libntp/ntp_rfc2553.c@1.31, 2006-08-24 09:10:22-04:00, mayer@pogo.udel.edu +2 -1 + libntp/ntp_rfc2553.c@1.31 +2 -1 Bug #690:Proper fix for length issue - ports/winnt/libntp/dnslookup.c@1.4, 2006-08-24 09:10:22-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/libntp/dnslookup.c@1.4 +1 -1 Bug #690:Proper fix for length issue -ChangeSet@1.1353.9.42, 2006-08-20 20:18:08-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1353.9.42, 2006-08-20 20:18:08-04:00, stenn@whimsy.udel.edu NTP_4_2_3P34 TAG: NTP_4_2_3P34 - ntpd/ntpd-opts.c@1.9, 2006-08-20 20:17:49-04:00, stenn@whimsy.udel.edu +19 -19 + ntpd/ntpd-opts.c@1.9 +19 -19 NTP_4_2_3P34 - ntpd/ntpd-opts.h@1.9, 2006-08-20 20:17:49-04:00, stenn@whimsy.udel.edu +5 -5 + ntpd/ntpd-opts.h@1.9 +5 -5 NTP_4_2_3P34 - ntpd/ntpd-opts.texi@1.10, 2006-08-20 20:17:50-04:00, stenn@whimsy.udel.edu +7 -7 + ntpd/ntpd-opts.texi@1.10 +7 -7 NTP_4_2_3P34 - ntpd/ntpd.1@1.9, 2006-08-20 20:17:51-04:00, stenn@whimsy.udel.edu +5 -5 + ntpd/ntpd.1@1.9 +5 -5 NTP_4_2_3P34 - ntpd/ntpdsim-opts.c@1.9, 2006-08-20 20:17:51-04:00, stenn@whimsy.udel.edu +19 -19 + ntpd/ntpdsim-opts.c@1.9 +19 -19 NTP_4_2_3P34 - ntpd/ntpdsim-opts.h@1.9, 2006-08-20 20:17:52-04:00, stenn@whimsy.udel.edu +5 -5 + ntpd/ntpdsim-opts.h@1.9 +5 -5 NTP_4_2_3P34 - ntpd/ntpdsim-opts.texi@1.9, 2006-08-20 20:17:53-04:00, stenn@whimsy.udel.edu +7 -7 + ntpd/ntpdsim-opts.texi@1.9 +7 -7 NTP_4_2_3P34 - ntpd/ntpdsim.1@1.9, 2006-08-20 20:17:54-04:00, stenn@whimsy.udel.edu +5 -5 + ntpd/ntpdsim.1@1.9 +5 -5 NTP_4_2_3P34 - ntpdc/ntpdc-opts.c@1.9, 2006-08-20 20:17:54-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.9 +2 -2 NTP_4_2_3P34 - ntpdc/ntpdc-opts.h@1.9, 2006-08-20 20:17:55-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.9 +3 -3 NTP_4_2_3P34 - ntpdc/ntpdc-opts.texi@1.9, 2006-08-20 20:17:56-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.9 +1 -1 NTP_4_2_3P34 - ntpdc/ntpdc.1@1.9, 2006-08-20 20:17:57-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.9 +2 -2 NTP_4_2_3P34 - ntpq/ntpq-opts.c@1.8, 2006-08-20 20:17:57-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.8 +2 -2 NTP_4_2_3P34 - ntpq/ntpq-opts.h@1.8, 2006-08-20 20:17:58-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.8 +3 -3 NTP_4_2_3P34 - ntpq/ntpq-opts.texi@1.8, 2006-08-20 20:17:59-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.8 +1 -1 NTP_4_2_3P34 - ntpq/ntpq.1@1.8, 2006-08-20 20:18:00-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.8 +2 -2 NTP_4_2_3P34 - packageinfo.sh@1.27, 2006-08-20 20:18:00-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27 +1 -1 NTP_4_2_3P34 - sntp/sntp-opts.c@1.8, 2006-08-20 20:18:00-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.8 +2 -2 NTP_4_2_3P34 - sntp/sntp-opts.h@1.8, 2006-08-20 20:18:01-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.8 +3 -3 NTP_4_2_3P34 - sntp/sntp-opts.texi@1.8, 2006-08-20 20:18:02-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.8 +1 -1 NTP_4_2_3P34 - sntp/sntp.1@1.11, 2006-08-20 20:18:02-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.11 +2 -2 NTP_4_2_3P34 - util/ntp-keygen-opts.c@1.8, 2006-08-20 20:18:03-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.8 +2 -2 NTP_4_2_3P34 - util/ntp-keygen-opts.h@1.8, 2006-08-20 20:18:03-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.8 +3 -3 NTP_4_2_3P34 - util/ntp-keygen-opts.texi@1.8, 2006-08-20 20:18:04-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.8 +1 -1 NTP_4_2_3P34 - util/ntp-keygen.1@1.8, 2006-08-20 20:18:05-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.8 +2 -2 NTP_4_2_3P34 -ChangeSet@1.1353.9.41, 2006-08-19 23:55:26-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1353.9.41, 2006-08-19 23:55:26-04:00, mayer@pogo.udel.edu Bug #690: don't copy to many bytes when copying the address info - libntp/ntp_rfc2553.c@1.30, 2006-08-19 23:54:56-04:00, mayer@pogo.udel.edu +1 -1 + libntp/ntp_rfc2553.c@1.30 +1 -1 Bug #690: don't copy to many bytes when copying the address info -ChangeSet@1.1353.9.39, 2006-08-19 23:34:01-04:00, stenn@whimsy.udel.edu +25 -0 +ChangeSet@1.1353.9.39, 2006-08-19 23:34:01-04:00, stenn@whimsy.udel.edu NTP_4_2_3P33 TAG: NTP_4_2_3P33 - ntpd/ntpd-opts.c@1.8, 2006-08-19 23:11:54-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.8 +2 -2 NTP_4_2_3P33 - ntpd/ntpd-opts.h@1.8, 2006-08-19 23:11:54-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.8 +3 -3 NTP_4_2_3P33 - ntpd/ntpd-opts.texi@1.9, 2006-08-19 23:11:55-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.texi@1.9 +3 -3 NTP_4_2_3P33 - ntpd/ntpd.1@1.8, 2006-08-19 23:11:55-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.8 +2 -2 NTP_4_2_3P33 - ntpd/ntpdsim-opts.c@1.8, 2006-08-19 23:11:55-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.8 +2 -2 NTP_4_2_3P33 - ntpd/ntpdsim-opts.h@1.8, 2006-08-19 23:11:56-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.8 +3 -3 NTP_4_2_3P33 - ntpd/ntpdsim-opts.texi@1.8, 2006-08-19 23:11:57-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.texi@1.8 +3 -3 NTP_4_2_3P33 - ntpd/ntpdsim.1@1.8, 2006-08-19 23:11:58-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.8 +2 -2 NTP_4_2_3P33 - ntpdc/ntpdc-opts.c@1.8, 2006-08-19 23:11:59-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.8 +2 -2 NTP_4_2_3P33 - ntpdc/ntpdc-opts.h@1.8, 2006-08-19 23:11:59-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.8 +3 -3 NTP_4_2_3P33 - ntpdc/ntpdc-opts.texi@1.8, 2006-08-19 23:12:00-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.texi@1.8 +2 -2 NTP_4_2_3P33 - ntpdc/ntpdc.1@1.8, 2006-08-19 23:12:01-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.8 +2 -2 NTP_4_2_3P33 - ntpq/ntpq-opts.c@1.7, 2006-08-19 23:12:02-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.7 +2 -2 NTP_4_2_3P33 - ntpq/ntpq-opts.h@1.7, 2006-08-19 23:12:02-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.7 +3 -3 NTP_4_2_3P33 - ntpq/ntpq-opts.texi@1.7, 2006-08-19 23:12:03-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.texi@1.7 +3 -3 NTP_4_2_3P33 - ntpq/ntpq.1@1.7, 2006-08-19 23:12:04-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.7 +2 -2 NTP_4_2_3P33 - packageinfo.sh@1.26, 2006-08-19 22:17:12-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.26 +1 -1 NTP_4_2_3P33 - sntp/sntp-opts.c@1.7, 2006-08-19 23:12:04-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.7 +2 -2 NTP_4_2_3P33 - sntp/sntp-opts.h@1.7, 2006-08-19 23:12:05-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.7 +3 -3 NTP_4_2_3P33 - sntp/sntp-opts.texi@1.7, 2006-08-19 23:12:06-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.7 +1 -1 NTP_4_2_3P33 - sntp/sntp.1@1.10, 2006-08-19 23:12:06-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.10 +2 -2 NTP_4_2_3P33 - util/ntp-keygen-opts.c@1.7, 2006-08-19 23:12:08-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.7 +2 -2 NTP_4_2_3P33 - util/ntp-keygen-opts.h@1.7, 2006-08-19 23:12:09-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.7 +3 -3 NTP_4_2_3P33 - util/ntp-keygen-opts.texi@1.7, 2006-08-19 23:12:10-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.texi@1.7 +2 -2 NTP_4_2_3P33 - util/ntp-keygen.1@1.7, 2006-08-19 23:12:11-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.7 +2 -2 NTP_4_2_3P33 -ChangeSet@1.1353.18.1, 2006-08-18 07:58:19-04:00, mayer@pogo.udel.edu +9 -0 +ChangeSet@1.1353.18.1, 2006-08-18 07:58:19-04:00, mayer@pogo.udel.edu Bug #685: Changes for MM timer and code cleanup - include/ntpd.h@1.95, 2006-08-18 07:56:32-04:00, mayer@pogo.udel.edu +0 -3 + include/ntpd.h@1.95 +0 -3 Bug #685: Changes for MM timer and code cleanup - ntpd/cmd_args.c@1.42.1.1, 2006-08-18 07:56:32-04:00, mayer@pogo.udel.edu +0 -8 + ntpd/cmd_args.c@1.42.1.1 +0 -8 Bug #685: Changes for MM timer and code cleanup - ntpd/ntp_timer.c@1.32, 2006-08-18 07:56:32-04:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_timer.c@1.32 +1 -1 Bug #685: Changes for MM timer and code cleanup - ntpd/ntpd.c@1.81, 2006-08-18 07:56:32-04:00, mayer@pogo.udel.edu +15 -7 + ntpd/ntpd.c@1.81 +15 -7 Bug #685: Changes for MM timer and code cleanup - ntpd/ntpdbase-opts.def@1.7.1.1, 2006-08-18 07:56:32-04:00, mayer@pogo.udel.edu +4 -3 + ntpd/ntpdbase-opts.def@1.7.1.1 +4 -3 Bug #685: Changes for MM timer and code cleanup - ports/winnt/include/clockstuff.h@1.7, 2006-08-18 07:57:35-04:00, mayer@pogo.udel.edu +11 -0 + ports/winnt/include/clockstuff.h@1.7 +11 -0 Bug #685: Changes for MM timer and code cleanup - ports/winnt/include/config.h@1.43, 2006-08-18 07:57:35-04:00, mayer@pogo.udel.edu +7 -1 + ports/winnt/include/config.h@1.43 +7 -1 Bug #685: Changes for MM timer and code cleanup - ports/winnt/ntpd/nt_clockstuff.c@1.21, 2006-08-18 07:57:35-04:00, mayer@pogo.udel.edu +4 -4 + ports/winnt/ntpd/nt_clockstuff.c@1.21 +4 -4 Bug #685: Changes for MM timer and code cleanup - ports/winnt/ntpd/ntpd.dsp@1.29, 2006-08-18 07:57:35-04:00, mayer@pogo.udel.edu +102 -2 + ports/winnt/ntpd/ntpd.dsp@1.29 +102 -2 Bug #685: Changes for MM timer and code cleanup -ChangeSet@1.1353.9.38, 2006-08-18 06:37:36-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.38, 2006-08-18 06:37:36-04:00, stenn@whimsy.udel.edu Remove "commented out" items from the bk ignore file - BitKeeper/etc/ignore@1.57, 2006-08-18 06:37:19-04:00, stenn@whimsy.udel.edu +0 -13 + BitKeeper/etc/ignore@1.57 +0 -13 Remove "commented out" items from the bk ignore file -ChangeSet@1.1353.9.37, 2006-08-18 03:33:56-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1353.9.37, 2006-08-18 03:33:56-04:00, stenn@whimsy.udel.edu libopts upgrade - libopts/autoopts.h@1.4, 2006-08-18 03:33:36-04:00, stenn@whimsy.udel.edu +12 -4 + libopts/autoopts.h@1.4 +12 -4 libopts upgrade - libopts/m4/libopts.m4@1.7, 2006-08-18 03:33:37-04:00, stenn@whimsy.udel.edu +4 -4 + libopts/m4/libopts.m4@1.7 +4 -4 libopts upgrade - libopts/usage.c@1.4, 2006-08-18 03:33:37-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/usage.c@1.4 +3 -3 libopts upgrade - sntp/libopts/autoopts.h@1.4, 2006-08-18 03:33:38-04:00, stenn@whimsy.udel.edu +12 -4 + sntp/libopts/autoopts.h@1.4 +12 -4 libopts upgrade - sntp/libopts/m4/libopts.m4@1.7, 2006-08-18 03:33:39-04:00, stenn@whimsy.udel.edu +4 -4 + sntp/libopts/m4/libopts.m4@1.7 +4 -4 libopts upgrade - sntp/libopts/usage.c@1.4, 2006-08-18 03:33:39-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/libopts/usage.c@1.4 +3 -3 libopts upgrade -ChangeSet@1.1353.9.36, 2006-08-17 01:29:37-04:00, stenn@whimsy.udel.edu +8 -0 +ChangeSet@1.1353.9.36, 2006-08-17 01:29:37-04:00, stenn@whimsy.udel.edu [Bug 685] cleanup - ntpd/ntpd-opts.c@1.7, 2006-08-17 01:29:02-04:00, stenn@whimsy.udel.edu +58 -28 + ntpd/ntpd-opts.c@1.7 +58 -28 [Bug 685] use updated autogen-erated files - ntpd/ntpd-opts.h@1.7, 2006-08-17 01:29:03-04:00, stenn@whimsy.udel.edu +24 -20 + ntpd/ntpd-opts.h@1.7 +24 -20 [Bug 685] use updated autogen-erated files - ntpd/ntpd-opts.texi@1.8, 2006-08-17 01:29:04-04:00, stenn@whimsy.udel.edu +16 -1 + ntpd/ntpd-opts.texi@1.8 +16 -1 [Bug 685] use updated autogen-erated files - ntpd/ntpd.1@1.7, 2006-08-17 01:29:05-04:00, stenn@whimsy.udel.edu +7 -2 + ntpd/ntpd.1@1.7 +7 -2 [Bug 685] use updated autogen-erated files - ntpd/ntpdsim-opts.c@1.7, 2006-08-17 01:29:05-04:00, stenn@whimsy.udel.edu +70 -40 + ntpd/ntpdsim-opts.c@1.7 +70 -40 [Bug 685] use updated autogen-erated files - ntpd/ntpdsim-opts.h@1.7, 2006-08-17 01:29:06-04:00, stenn@whimsy.udel.edu +30 -26 + ntpd/ntpdsim-opts.h@1.7 +30 -26 [Bug 685] use updated autogen-erated files - ntpd/ntpdsim-opts.texi@1.7, 2006-08-17 01:29:06-04:00, stenn@whimsy.udel.edu +16 -1 + ntpd/ntpdsim-opts.texi@1.7 +16 -1 [Bug 685] use updated autogen-erated files - ntpd/ntpdsim.1@1.7, 2006-08-17 01:29:07-04:00, stenn@whimsy.udel.edu +7 -2 + ntpd/ntpdsim.1@1.7 +7 -2 [Bug 685] use updated autogen-erated files -ChangeSet@1.1353.9.35, 2006-08-17 01:27:04-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.9.35, 2006-08-17 01:27:04-04:00, stenn@whimsy.udel.edu [Bug 685] cleanup - ntpd/cmd_args.c@1.43, 2006-08-17 01:24:44-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/cmd_args.c@1.43 +1 -1 [Bug 685] Fix a typo - WINNT -> SYS_WINNT - ntpd/ntpdbase-opts.def@1.8, 2006-08-17 01:25:41-04:00, stenn@whimsy.udel.edu +1 -0 + ntpd/ntpdbase-opts.def@1.8 +1 -0 [Bug 685] -M should only accepted if SYS_WINNT is #defined -ChangeSet@1.1353.17.1, 2006-08-17 00:52:10-04:00, stenn@whimsy.udel.edu +24 -0 +ChangeSet@1.1353.17.1, 2006-08-17 00:52:10-04:00, stenn@whimsy.udel.edu run autogen after point release - ntpd/ntpd-opts.c@1.6, 2006-08-17 00:51:23-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.6 +2 -2 run autogen after point release - ntpd/ntpd-opts.h@1.6, 2006-08-17 00:51:23-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.6 +3 -3 run autogen after point release - ntpd/ntpd-opts.texi@1.7, 2006-08-17 00:51:24-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.7 +1 -1 run autogen after point release - ntpd/ntpd.1@1.6, 2006-08-17 00:51:24-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.6 +2 -2 run autogen after point release - ntpd/ntpdsim-opts.c@1.6, 2006-08-17 00:51:25-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.6 +2 -2 run autogen after point release - ntpd/ntpdsim-opts.h@1.6, 2006-08-17 00:51:26-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.6 +3 -3 run autogen after point release - ntpd/ntpdsim-opts.texi@1.6, 2006-08-17 00:51:27-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.6 +1 -1 run autogen after point release - ntpd/ntpdsim.1@1.6, 2006-08-17 00:51:28-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.6 +2 -2 run autogen after point release - ntpdc/ntpdc-opts.c@1.7, 2006-08-17 00:51:29-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.7 +2 -2 run autogen after point release - ntpdc/ntpdc-opts.h@1.7, 2006-08-17 00:51:29-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.7 +3 -3 run autogen after point release - ntpdc/ntpdc-opts.texi@1.7, 2006-08-17 00:51:30-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.7 +1 -1 run autogen after point release - ntpdc/ntpdc.1@1.7, 2006-08-17 00:51:30-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.7 +2 -2 run autogen after point release - ntpq/ntpq-opts.c@1.6, 2006-08-17 00:51:32-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.6 +2 -2 run autogen after point release - ntpq/ntpq-opts.h@1.6, 2006-08-17 00:51:33-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.6 +3 -3 run autogen after point release - ntpq/ntpq-opts.texi@1.6, 2006-08-17 00:51:33-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.6 +1 -1 run autogen after point release - ntpq/ntpq.1@1.6, 2006-08-17 00:51:34-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.6 +2 -2 run autogen after point release - sntp/sntp-opts.c@1.6, 2006-08-17 00:51:35-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.6 +2 -2 run autogen after point release - sntp/sntp-opts.h@1.6, 2006-08-17 00:51:35-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.6 +3 -3 run autogen after point release - sntp/sntp-opts.texi@1.6, 2006-08-17 00:51:36-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.6 +1 -1 run autogen after point release - sntp/sntp.1@1.9, 2006-08-17 00:51:37-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.9 +2 -2 run autogen after point release - util/ntp-keygen-opts.c@1.6, 2006-08-17 00:51:38-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.6 +2 -2 run autogen after point release - util/ntp-keygen-opts.h@1.6, 2006-08-17 00:51:39-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.6 +3 -3 run autogen after point release - util/ntp-keygen-opts.texi@1.6, 2006-08-17 00:51:39-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.6 +1 -1 run autogen after point release - util/ntp-keygen.1@1.6, 2006-08-17 00:51:41-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.6 +2 -2 run autogen after point release -ChangeSet@1.1353.16.2, 2006-08-15 13:14:03-04:00, mayer@pogo.udel.edu +4 -0 +ChangeSet@1.1353.16.2, 2006-08-15 13:14:03-04:00, mayer@pogo.udel.edu Bug #685 and #686: MM timer enhancements and leapsecond fixes - ntpd/cmd_args.c@1.42, 2006-08-15 13:12:21-04:00, mayer@pogo.udel.edu +8 -0 + ntpd/cmd_args.c@1.42 +8 -0 Bug #685: MM timer enhancement for Windows - ntpd/ntpdbase-opts.def@1.5.1.1, 2006-08-15 13:12:23-04:00, mayer@pogo.udel.edu +9 -0 + ntpd/ntpdbase-opts.def@1.5.1.1 +9 -0 Bug #685: MM timer enhancement for Windows - ports/winnt/ntpd/nt_clockstuff.c@1.20, 2006-08-15 13:08:20-04:00, mayer@pogo.udel.edu +199 -38 + ports/winnt/ntpd/nt_clockstuff.c@1.20 +199 -38 Bug #685 and #686: MM timer fixes and leapsecond fixes - ports/winnt/ntpd/ntservice.c@1.6.1.1, 2006-08-15 13:08:20-04:00, mayer@pogo.udel.edu +13 -12 + ports/winnt/ntpd/ntservice.c@1.6.1.1 +13 -12 Bug #685 and #686: MM timer fixes and leapsecond fixes -ChangeSet@1.1353.16.1, 2006-08-15 13:04:10-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1353.16.1, 2006-08-15 13:04:10-04:00, mayer@pogo.udel.edu Bug #523: exit() was being overridden - include/ntpd.h@1.94, 2006-08-15 13:03:42-04:00, mayer@pogo.udel.edu +0 -2 + include/ntpd.h@1.94 +0 -2 Bug #523: exit() was being overridden -ChangeSet@1.1353.9.32, 2006-08-15 08:10:21-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.32, 2006-08-15 08:10:21-04:00, stenn@whimsy.udel.edu NTP_4_2_3P31 TAG: NTP_4_2_3P31 - packageinfo.sh@1.25, 2006-08-15 08:10:19-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.25 +1 -1 NTP_4_2_3P31 -ChangeSet@1.1251.94.50, 2006-08-15 07:02:21-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.50, 2006-08-15 07:02:21-04:00, stenn@whimsy.udel.edu NTP_4_2_2P4_RC1 TAG: NTP_4_2_2P4_RC1 - packageinfo.sh@1.27.17.1, 2006-08-15 07:02:17-04:00, stenn@whimsy.udel.edu +3 -3 + packageinfo.sh@1.27.17.1 +3 -3 NTP_4_2_2P4_RC1 -ChangeSet@1.1251.94.49, 2006-08-15 06:09:54-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.49, 2006-08-15 06:09:54-04:00, stenn@whimsy.udel.edu Save the list of files that change if the point-level is updated - .point-changed-filelist@1.1, 2006-08-15 06:09:46-04:00, stenn@whimsy.udel.edu +1 -0 + .point-changed-filelist@1.1 +1 -0 BitKeeper file /deacon/backroom/ntp-stable/.point-changed-filelist - .point-changed-filelist@1.0, 2006-08-15 06:09:46-04:00, stenn@whimsy.udel.edu +0 -0 + .point-changed-filelist@1.0 +0 -0 -ChangeSet@1.1353.9.30, 2006-08-15 06:08:03-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.30, 2006-08-15 06:08:03-04:00, stenn@whimsy.udel.edu Save the list of files that change if the point-level is updated - .point-changed-filelist@1.1, 2006-08-15 06:04:15-04:00, stenn@whimsy.udel.edu +25 -0 + .point-changed-filelist@1.1 +25 -0 BitKeeper file /deacon/backroom/ntp-dev/.point-changed-filelist - .point-changed-filelist@1.0, 2006-08-15 06:04:15-04:00, stenn@whimsy.udel.edu +0 -0 + .point-changed-filelist@1.0 +0 -0 -ChangeSet@1.1353.9.29, 2006-08-15 05:53:43-04:00, stenn@whimsy.udel.edu +26 -0 +ChangeSet@1.1353.9.29, 2006-08-15 05:53:43-04:00, stenn@whimsy.udel.edu [Bug 684] debug command-line options should not be shown if #undef DEBUG - include/debug-opt.def@1.4, 2006-08-15 05:45:38-04:00, stenn@whimsy.udel.edu +2 -0 + include/debug-opt.def@1.4 +2 -0 [Bug 684] debug command-line options should not be shown if #undef DEBUG - ntpd/ntpd-opts.c@1.5, 2006-08-15 05:52:24-04:00, stenn@whimsy.udel.edu +29 -4 + ntpd/ntpd-opts.c@1.5 +29 -4 regenerate autogen-erated files - ntpd/ntpd-opts.h@1.5, 2006-08-15 05:52:25-04:00, stenn@whimsy.udel.edu +7 -3 + ntpd/ntpd-opts.h@1.5 +7 -3 regenerate autogen-erated files - ntpd/ntpd-opts.texi@1.6, 2006-08-15 05:52:26-04:00, stenn@whimsy.udel.edu +5 -1 + ntpd/ntpd-opts.texi@1.6 +5 -1 regenerate autogen-erated files - ntpd/ntpd.1@1.5, 2006-08-15 05:52:27-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.5 +2 -2 regenerate autogen-erated files - ntpd/ntpdbase-opts.def@1.6, 2006-08-15 05:48:12-04:00, stenn@whimsy.udel.edu +1 -0 + ntpd/ntpdbase-opts.def@1.6 +1 -0 Make sure we are using the right version of autogen - ntpd/ntpdsim-opts.c@1.5, 2006-08-15 05:52:28-04:00, stenn@whimsy.udel.edu +29 -4 + ntpd/ntpdsim-opts.c@1.5 +29 -4 regenerate autogen-erated files - ntpd/ntpdsim-opts.h@1.5, 2006-08-15 05:52:29-04:00, stenn@whimsy.udel.edu +7 -3 + ntpd/ntpdsim-opts.h@1.5 +7 -3 regenerate autogen-erated files - ntpd/ntpdsim-opts.texi@1.5, 2006-08-15 05:52:29-04:00, stenn@whimsy.udel.edu +5 -1 + ntpd/ntpdsim-opts.texi@1.5 +5 -1 regenerate autogen-erated files - ntpd/ntpdsim.1@1.5, 2006-08-15 05:52:30-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.5 +2 -2 regenerate autogen-erated files - ntpdc/ntpdc-opts.c@1.6, 2006-08-15 05:52:31-04:00, stenn@whimsy.udel.edu +29 -4 + ntpdc/ntpdc-opts.c@1.6 +29 -4 regenerate autogen-erated files - ntpdc/ntpdc-opts.h@1.6, 2006-08-15 05:52:31-04:00, stenn@whimsy.udel.edu +7 -3 + ntpdc/ntpdc-opts.h@1.6 +7 -3 regenerate autogen-erated files - ntpdc/ntpdc-opts.texi@1.6, 2006-08-15 05:52:32-04:00, stenn@whimsy.udel.edu +5 -1 + ntpdc/ntpdc-opts.texi@1.6 +5 -1 regenerate autogen-erated files - ntpdc/ntpdc.1@1.6, 2006-08-15 05:52:34-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.6 +2 -2 regenerate autogen-erated files - ntpq/ntpq-opts.c@1.5, 2006-08-15 05:52:34-04:00, stenn@whimsy.udel.edu +29 -4 + ntpq/ntpq-opts.c@1.5 +29 -4 regenerate autogen-erated files - ntpq/ntpq-opts.h@1.5, 2006-08-15 05:52:35-04:00, stenn@whimsy.udel.edu +7 -3 + ntpq/ntpq-opts.h@1.5 +7 -3 regenerate autogen-erated files - ntpq/ntpq-opts.texi@1.5, 2006-08-15 05:52:36-04:00, stenn@whimsy.udel.edu +5 -1 + ntpq/ntpq-opts.texi@1.5 +5 -1 regenerate autogen-erated files - ntpq/ntpq.1@1.5, 2006-08-15 05:52:36-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.5 +2 -2 regenerate autogen-erated files - sntp/sntp-opts.c@1.5, 2006-08-15 05:52:37-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp-opts.c@1.5 +2 -2 regenerate autogen-erated files - sntp/sntp-opts.h@1.5, 2006-08-15 05:52:38-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/sntp-opts.h@1.5 +3 -3 regenerate autogen-erated files - sntp/sntp-opts.texi@1.5, 2006-08-15 05:52:38-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.5 +1 -1 regenerate autogen-erated files - sntp/sntp.1@1.8, 2006-08-15 05:52:39-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/sntp.1@1.8 +2 -2 regenerate autogen-erated files - util/ntp-keygen-opts.c@1.5, 2006-08-15 05:52:40-04:00, stenn@whimsy.udel.edu +29 -4 + util/ntp-keygen-opts.c@1.5 +29 -4 regenerate autogen-erated files - util/ntp-keygen-opts.h@1.5, 2006-08-15 05:52:40-04:00, stenn@whimsy.udel.edu +7 -3 + util/ntp-keygen-opts.h@1.5 +7 -3 regenerate autogen-erated files - util/ntp-keygen-opts.texi@1.5, 2006-08-15 05:52:41-04:00, stenn@whimsy.udel.edu +5 -1 + util/ntp-keygen-opts.texi@1.5 +5 -1 regenerate autogen-erated files - util/ntp-keygen.1@1.5, 2006-08-15 05:52:42-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.5 +2 -2 regenerate autogen-erated files -ChangeSet@1.1353.9.28, 2006-08-15 05:40:34-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.28, 2006-08-15 05:40:34-04:00, stenn@whimsy.udel.edu test -r seems more portable than test -e - sntp/Makefile.am@1.18, 2006-08-15 05:40:22-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/Makefile.am@1.18 +1 -1 test -r seems more portable than test -e -ChangeSet@1.1353.9.27, 2006-08-15 05:08:00-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.27, 2006-08-15 05:08:00-04:00, stenn@whimsy.udel.edu Make sure we use the right version of autogen - include/autogen-version.def@1.1, 2006-08-15 05:07:11-04:00, stenn@whimsy.udel.edu +1 -0 + include/autogen-version.def@1.1 +1 -0 BitKeeper file /deacon/backroom/ntp-dev/include/autogen-version.def - include/autogen-version.def@1.0, 2006-08-15 05:07:11-04:00, stenn@whimsy.udel.edu +0 -0 + include/autogen-version.def@1.0 +0 -0 -ChangeSet@1.1353.9.26, 2006-08-11 07:04:21-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.26, 2006-08-11 07:04:21-04:00, stenn@whimsy.udel.edu NTP_4_2_3P30 TAG: NTP_4_2_3P30 - packageinfo.sh@1.24, 2006-08-11 07:04:18-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.24 +1 -1 NTP_4_2_3P30 -ChangeSet@1.1353.15.9, 2006-08-10 21:41:32-04:00, stenn@whimsy.udel.edu +24 -0 +ChangeSet@1.1353.15.9, 2006-08-10 21:41:32-04:00, stenn@whimsy.udel.edu NTP_4_2_3P29 - ntpd/ntpd-opts.c@1.4, 2006-08-10 21:40:58-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd-opts.c@1.4 +2 -2 NTP_4_2_3P29 - ntpd/ntpd-opts.h@1.4, 2006-08-10 21:40:58-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpd-opts.h@1.4 +3 -3 NTP_4_2_3P29 - ntpd/ntpd-opts.texi@1.5, 2006-08-10 21:40:59-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.5 +1 -1 NTP_4_2_3P29 - ntpd/ntpd.1@1.4, 2006-08-10 21:40:59-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpd.1@1.4 +2 -2 NTP_4_2_3P29 - ntpd/ntpdsim-opts.c@1.4, 2006-08-10 21:41:00-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim-opts.c@1.4 +2 -2 NTP_4_2_3P29 - ntpd/ntpdsim-opts.h@1.4, 2006-08-10 21:41:01-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntpdsim-opts.h@1.4 +3 -3 NTP_4_2_3P29 - ntpd/ntpdsim-opts.texi@1.4, 2006-08-10 21:41:01-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpdsim-opts.texi@1.4 +1 -1 NTP_4_2_3P29 - ntpd/ntpdsim.1@1.4, 2006-08-10 21:41:02-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntpdsim.1@1.4 +2 -2 NTP_4_2_3P29 - ntpdc/ntpdc-opts.c@1.5, 2006-08-10 21:41:02-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc-opts.c@1.5 +2 -2 NTP_4_2_3P29 - ntpdc/ntpdc-opts.h@1.5, 2006-08-10 21:41:03-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.h@1.5 +3 -3 NTP_4_2_3P29 - ntpdc/ntpdc-opts.texi@1.5, 2006-08-10 21:41:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdc/ntpdc-opts.texi@1.5 +1 -1 NTP_4_2_3P29 - ntpdc/ntpdc.1@1.5, 2006-08-10 21:41:05-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.5 +2 -2 NTP_4_2_3P29 - ntpq/ntpq-opts.c@1.4, 2006-08-10 21:41:06-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq-opts.c@1.4 +2 -2 NTP_4_2_3P29 - ntpq/ntpq-opts.h@1.4, 2006-08-10 21:41:07-04:00, stenn@whimsy.udel.edu +3 -3 + ntpq/ntpq-opts.h@1.4 +3 -3 NTP_4_2_3P29 - ntpq/ntpq-opts.texi@1.4, 2006-08-10 21:41:08-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq-opts.texi@1.4 +1 -1 NTP_4_2_3P29 - ntpq/ntpq.1@1.4, 2006-08-10 21:41:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.1@1.4 +2 -2 NTP_4_2_3P29 - sntp/sntp-opts.c@1.4, 2006-08-10 21:41:09-04:00, stenn@whimsy.udel.edu +140 -4 + sntp/sntp-opts.c@1.4 +140 -4 NTP_4_2_3P29 - sntp/sntp-opts.h@1.4, 2006-08-10 21:41:10-04:00, stenn@whimsy.udel.edu +83 -4 + sntp/sntp-opts.h@1.4 +83 -4 NTP_4_2_3P29 - sntp/sntp-opts.texi@1.4, 2006-08-10 21:41:11-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.texi@1.4 +1 -1 NTP_4_2_3P29 - sntp/sntp.1@1.7, 2006-08-10 21:41:11-04:00, stenn@whimsy.udel.edu +82 -3 + sntp/sntp.1@1.7 +82 -3 NTP_4_2_3P29 - util/ntp-keygen-opts.c@1.4, 2006-08-10 21:41:12-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen-opts.c@1.4 +2 -2 NTP_4_2_3P29 - util/ntp-keygen-opts.h@1.4, 2006-08-10 21:41:12-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.h@1.4 +3 -3 NTP_4_2_3P29 - util/ntp-keygen-opts.texi@1.4, 2006-08-10 21:41:13-04:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen-opts.texi@1.4 +1 -1 NTP_4_2_3P29 - util/ntp-keygen.1@1.4, 2006-08-10 21:41:14-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.1@1.4 +2 -2 NTP_4_2_3P29 -ChangeSet@1.1251.94.48, 2006-08-10 20:37:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.48, 2006-08-10 20:37:44-04:00, stenn@whimsy.udel.edu Choose csets-{in,out} based on daemon/client - BitKeeper/triggers/send@1.11.1.1, 2006-08-10 20:37:23-04:00, stenn@whimsy.udel.edu +3 -1 + BitKeeper/triggers/send@1.11.1.1 +3 -1 Choose csets-{in,out} based on daemon/client -ChangeSet@1.1353.15.8, 2006-08-10 20:34:50-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.15.8, 2006-08-10 20:34:50-04:00, stenn@whimsy.udel.edu Choose csets-{in,out} based on daemon/client - BitKeeper/triggers/send@1.12, 2006-08-10 20:34:36-04:00, stenn@whimsy.udel.edu +3 -1 + BitKeeper/triggers/send@1.12 +3 -1 Choose csets-{in,out} based on daemon/client -ChangeSet@1.1353.15.7, 2006-08-10 20:29:08-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.15.7, 2006-08-10 20:29:08-04:00, stenn@whimsy.udel.edu cleanup - sntp/Makefile.am@1.17, 2006-08-10 20:28:24-04:00, stenn@whimsy.udel.edu +2 -1 + sntp/Makefile.am@1.17 +2 -1 use a run-ag that is for the sntp subdir - sntp/sntp-opts.def@1.8, 2006-08-10 20:28:51-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.def@1.8 +1 -1 Fix a typo in sntp-opts.def -ChangeSet@1.1353.15.6, 2006-08-10 20:06:04-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.15.6, 2006-08-10 20:06:04-04:00, stenn@whimsy.udel.edu fix permissions on sntp-opts.menu - sntp/sntp-opts.menu@1.2, 2006-08-10 18:08:02-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.menu@1.2 +0 -0 Change mode to -rw-r--r-- -ChangeSet@1.1353.15.5, 2006-08-10 17:45:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.15.5, 2006-08-10 17:45:44-04:00, stenn@whimsy.udel.edu Maintain sntp/version.def more quietly - sntp/Makefile.am@1.16, 2006-08-10 17:45:32-04:00, stenn@whimsy.udel.edu +2 -1 + sntp/Makefile.am@1.16 +2 -1 Maintain sntp/version.def more quietly -ChangeSet@1.1353.15.4, 2006-08-10 17:24:38-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.15.4, 2006-08-10 17:24:38-04:00, stenn@whimsy.udel.edu Use the new name of the sntp/COPYRIGHT file - sntp/sntp-opts.def@1.7, 2006-08-10 17:24:13-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/sntp-opts.def@1.7 +1 -1 Use the new name of the sntp/COPYRIGHT file -ChangeSet@1.1353.15.3, 2006-08-10 16:53:20-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1353.15.3, 2006-08-10 16:53:20-04:00, stenn@whimsy.udel.edu [Bug 683] fix version number string mismatches - ntpd/Makefile.am@1.49, 2006-08-10 16:52:04-04:00, stenn@whimsy.udel.edu +9 -6 + ntpd/Makefile.am@1.49 +9 -6 [Bug 683] fix version number string mismatches - ntpdc/Makefile.am@1.31, 2006-08-10 16:52:04-04:00, stenn@whimsy.udel.edu +6 -3 + ntpdc/Makefile.am@1.31 +6 -3 [Bug 683] fix version number string mismatches - ntpq/Makefile.am@1.23, 2006-08-10 16:52:05-04:00, stenn@whimsy.udel.edu +6 -3 + ntpq/Makefile.am@1.23 +6 -3 [Bug 683] fix version number string mismatches - sntp/Makefile.am@1.15, 2006-08-10 16:52:05-04:00, stenn@whimsy.udel.edu +15 -4 + sntp/Makefile.am@1.15 +15 -4 [Bug 683] fix version number string mismatches - sntp/sntp-opts.def@1.6, 2006-08-10 16:52:44-04:00, stenn@whimsy.udel.edu +2 -5 + sntp/sntp-opts.def@1.6 +2 -5 [Bug 683] fix version number string mismatches - util/Makefile.am@1.32, 2006-08-10 16:52:06-04:00, stenn@whimsy.udel.edu +6 -3 + util/Makefile.am@1.32 +6 -3 [Bug 683] fix version number string mismatches -ChangeSet@1.1353.15.2, 2006-08-10 16:45:30-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.15.2, 2006-08-10 16:45:30-04:00, stenn@whimsy.udel.edu Rename sntp/Copyright to sntp/COPYRIGHT - sntp/COPYRIGHT@1.2, 2006-08-10 16:29:50-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/COPYRIGHT@1.2 +0 -0 Rename: sntp/Copyright -> sntp/COPYRIGHT -ChangeSet@1.1353.15.1, 2006-08-10 07:03:21-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.15.1, 2006-08-10 07:03:21-04:00, stenn@whimsy.udel.edu NTP_4_2_3P29 TAG: NTP_4_2_3P29 - packageinfo.sh@1.23, 2006-08-10 07:03:19-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.23 +1 -1 NTP_4_2_3P29 -ChangeSet@1.1353.14.1, 2006-08-10 09:40:07+00:00, burnicki@pogo.udel.edu +1 -0 +ChangeSet@1.1353.14.1, 2006-08-10 09:40:07+00:00, burnicki@pogo.udel.edu Changes by Heiko : Fixed point/rcpoint handling which resulted in wrong version strings. - ports/winnt/scripts/mkver.bat@1.9, 2006-08-10 09:40:04+00:00, burnicki@pogo.udel.edu +32 -4 + ports/winnt/scripts/mkver.bat@1.9 +32 -4 Changes by Heiko : Fixed point/rcpoint handling which resulted in wrong version strings. -ChangeSet@1.1353.9.23, 2006-08-10 08:40:06+00:00, burnicki@pogo.udel.edu +2 -0 +ChangeSet@1.1353.9.23, 2006-08-10 08:40:06+00:00, burnicki@pogo.udel.edu Exclude debug features if building without debug. Removed obsolete prototype for ntpd_usage(). - include/ntp_cmdargs.h@1.4, 2006-08-10 08:40:04+00:00, burnicki@pogo.udel.edu +0 -1 + include/ntp_cmdargs.h@1.4 +0 -1 Removed ntpd_usage() prototype which is obsolete. - ports/winnt/ntpd/ntservice.c@1.7, 2006-08-10 08:40:04+00:00, burnicki@pogo.udel.edu +2 -0 + ports/winnt/ntpd/ntservice.c@1.7 +2 -0 Exclude debug features if building without debug. -ChangeSet@1.1353.13.3, 2006-08-10 01:02:20-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.13.3, 2006-08-10 01:02:20-04:00, stenn@whimsy.udel.edu [Bug 659] Get the latest windows patches for libopts - libopts/compat/compat.h@1.6, 2006-08-10 01:02:08-04:00, stenn@whimsy.udel.edu +2 -2 + libopts/compat/compat.h@1.6 +2 -2 [Bug 659] Get the latest windows patches for libopts -ChangeSet@1.1353.13.2, 2006-08-10 00:57:53-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1353.13.2, 2006-08-10 00:57:53-04:00, stenn@whimsy.udel.edu [Bug 659] Get the latest windows patches for libopts - libopts/m4/libopts.m4@1.6, 2006-08-10 00:57:33-04:00, stenn@whimsy.udel.edu +2 -1 + libopts/m4/libopts.m4@1.6 +2 -1 [Bug 659] Get the latest windows patches for liboptslibopts/compat/compat.h - sntp/libopts/compat/compat.h@1.5, 2006-08-10 00:57:34-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/compat/compat.h@1.5 +1 -1 [Bug 659] Get the latest windows patches for liboptslibopts/compat/compat.h - sntp/libopts/m4/libopts.m4@1.6, 2006-08-10 00:57:35-04:00, stenn@whimsy.udel.edu +2 -1 + sntp/libopts/m4/libopts.m4@1.6 +2 -1 [Bug 659] Get the latest windows patches for liboptslibopts/compat/compat.h -ChangeSet@1.1353.13.1, 2006-08-10 00:53:59-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.13.1, 2006-08-10 00:53:59-04:00, stenn@whimsy.udel.edu Replace the #ifdef DEBUG that got undone by Danny's recent patch - ntpd/ntp_io.c@1.234.1.3, 2006-08-10 00:53:37-04:00, stenn@whimsy.udel.edu +5 -1 + ntpd/ntp_io.c@1.234.1.3 +5 -1 Replace the #ifdef DEBUG that got undone by Danny's recent patch -ChangeSet@1.1353.12.1, 2006-08-09 21:57:02-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1353.12.1, 2006-08-09 21:57:02-04:00, mayer@pogo.udel.edu Bug #659: to allow --help through and not start services - ports/winnt/ntpd/ntservice.c@1.6, 2006-08-09 21:56:29-04:00, mayer@pogo.udel.edu +2 -2 + ports/winnt/ntpd/ntservice.c@1.6 +2 -2 Bug #659: to allow --help through and not start services -ChangeSet@1.1353.9.19, 2006-08-09 18:28:43-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.9.19, 2006-08-09 18:28:43-04:00, stenn@whimsy.udel.edu [Bug 682] add --disable-debugging to the test build mix - build@1.23, 2006-08-09 18:28:30-04:00, stenn@whimsy.udel.edu +6 -0 + build@1.23 +6 -0 [Bug 682] add --disable-debugging to the test build mix - flock-build@1.37, 2006-08-09 18:28:31-04:00, stenn@whimsy.udel.edu +1 -0 + flock-build@1.37 +1 -0 [Bug 682] add --disable-debugging to the test build mix -ChangeSet@1.1251.94.47, 2006-08-09 18:24:30-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.47, 2006-08-09 18:24:30-04:00, stenn@whimsy.udel.edu [Bug 682] add --disable-debugging to the test build mix - build@1.21.1.1, 2006-08-09 18:24:18-04:00, stenn@whimsy.udel.edu +6 -0 + build@1.21.1.1 +6 -0 [Bug 682] add --disable-debugging to the test build mix - flock-build@1.35.1.1, 2006-08-09 18:24:19-04:00, stenn@whimsy.udel.edu +1 -0 + flock-build@1.35.1.1 +1 -0 [Bug 682] add --disable-debugging to the test build mix -ChangeSet@1.1353.9.18, 2006-08-09 07:02:54-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.18, 2006-08-09 07:02:54-04:00, stenn@whimsy.udel.edu NTP_4_2_3P28 TAG: NTP_4_2_3P28 - packageinfo.sh@1.22, 2006-08-09 07:02:52-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.22 +1 -1 NTP_4_2_3P28 -ChangeSet@1.1353.9.17, 2006-08-08 22:38:19-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1353.9.17, 2006-08-08 22:38:19-04:00, mayer@pogo.udel.edu bug #671: setsockopt needs macro for Windows - ntpd/ntp_io.c@1.234.1.2, 2006-08-08 22:37:40-04:00, mayer@pogo.udel.edu +11 -6 + ntpd/ntp_io.c@1.234.1.2 +11 -6 bug #671: setsockopt needs macro for Windows - ports/winnt/include/config.h@1.42, 2006-08-08 22:37:40-04:00, mayer@pogo.udel.edu +1 -0 + ports/winnt/include/config.h@1.42 +1 -0 bug #671: setsockopt needs macro for Windows -ChangeSet@1.1353.11.1, 2006-08-08 11:32:15-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1353.11.1, 2006-08-08 11:32:15-04:00, mayer@pogo.udel.edu Bug #659: New include file for windows for handling file stat - ports/winnt/include/isc/stat.h@1.1, 2006-08-08 11:31:23-04:00, mayer@pogo.udel.edu +66 -0 + ports/winnt/include/isc/stat.h@1.1 +66 -0 BitKeeper file /pogo/users/mayer/ntp-dev/ports/winnt/include/isc/stat.h - ports/winnt/include/isc/stat.h@1.0, 2006-08-08 11:31:23-04:00, mayer@pogo.udel.edu +0 -0 + ports/winnt/include/isc/stat.h@1.0 +0 -0 -ChangeSet@1.1353.9.15, 2006-08-08 07:03:46-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.15, 2006-08-08 07:03:46-04:00, stenn@whimsy.udel.edu NTP_4_2_3P27 TAG: NTP_4_2_3P27 - packageinfo.sh@1.21, 2006-08-08 07:03:43-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.21 +1 -1 NTP_4_2_3P27 -ChangeSet@1.1353.9.14, 2006-08-08 04:12:04-04:00, stenn@whimsy.udel.edu +7 -0 +ChangeSet@1.1353.9.14, 2006-08-08 04:12:04-04:00, stenn@whimsy.udel.edu [Bug 675]: Make sure we build even when we --disable-debugging - ntpd/ntp_intres.c@1.48, 2006-08-08 04:11:04-04:00, stenn@whimsy.udel.edu +4 -0 + ntpd/ntp_intres.c@1.48 +4 -0 [Bug 675]: Make sure we build even when we --disable-debugging - ntpd/ntp_io.c@1.234.1.1, 2006-08-08 04:11:05-04:00, stenn@whimsy.udel.edu +5 -1 + ntpd/ntp_io.c@1.234.1.1 +5 -1 [Bug 675]: Make sure we build even when we --disable-debugging - ntpd/refclock_jupiter.c@1.20, 2006-08-08 04:11:07-04:00, stenn@whimsy.udel.edu +2 -0 + ntpd/refclock_jupiter.c@1.20 +2 -0 [Bug 675]: Make sure we build even when we --disable-debugging - ntpd/refclock_leitch.c@1.8, 2006-08-08 04:11:09-04:00, stenn@whimsy.udel.edu +11 -5 + ntpd/refclock_leitch.c@1.8 +11 -5 [Bug 675]: Make sure we build even when we --disable-debugging - ntpd/refclock_msfees.c@1.12, 2006-08-08 04:11:09-04:00, stenn@whimsy.udel.edu +28 -27 + ntpd/refclock_msfees.c@1.12 +28 -27 [Bug 675]: Make sure we build even when we --disable-debugging - ntpd/refclock_mx4200.c@1.22, 2006-08-08 04:11:10-04:00, stenn@whimsy.udel.edu +2 -0 + ntpd/refclock_mx4200.c@1.22 +2 -0 [Bug 675]: Make sure we build even when we --disable-debugging - ntpd/refclock_oncore.c@1.60, 2006-08-08 04:11:11-04:00, stenn@whimsy.udel.edu +34 -10 + ntpd/refclock_oncore.c@1.60 +34 -10 [Bug 675]: Make sure we build even when we --disable-debugging -ChangeSet@1.1353.9.13, 2006-08-07 18:41:58-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.9.13, 2006-08-07 18:41:58-04:00, stenn@whimsy.udel.edu Fix #include breakage - libopts/compat/compat.h@1.5, 2006-08-07 18:41:15-04:00, stenn@whimsy.udel.edu +3 -1 + libopts/compat/compat.h@1.5 +3 -1 Fix sys/mman.h breakage - sntp/libopts/compat/compat.h@1.4, 2006-08-07 18:41:15-04:00, stenn@whimsy.udel.edu +3 -1 + sntp/libopts/compat/compat.h@1.4 +3 -1 Fix sys/mman.h breakage -ChangeSet@1.1353.9.12, 2006-08-07 09:32:49-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1353.9.12, 2006-08-07 09:32:49-04:00, mayer@pogo.udel.edu Bug #659 mman.h not always available - libopts/compat/compat.h@1.4, 2006-08-07 09:32:42-04:00, mayer@pogo.udel.edu +2 -2 + libopts/compat/compat.h@1.4 +2 -2 Bug #659 mman.h not always available -ChangeSet@1.1353.9.11, 2006-08-07 08:51:39-04:00, mayer@pogo.udel.edu +6 -0 +ChangeSet@1.1353.9.11, 2006-08-07 08:51:39-04:00, mayer@pogo.udel.edu bug #659: Changes to support libopts on Windows - ports/winnt/include/config.h@1.41, 2006-08-07 08:42:01-04:00, mayer@pogo.udel.edu +36 -1 + ports/winnt/include/config.h@1.41 +36 -1 bug #659: Changes to support libopts on Windows - ports/winnt/libntp/libntp.dsp@1.30, 2006-08-07 08:42:01-04:00, mayer@pogo.udel.edu +6 -2 + ports/winnt/libntp/libntp.dsp@1.30 +6 -2 bug #659: Changes to support libopts on Windows - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.11, 2006-08-07 08:42:01-04:00, mayer@pogo.udel.edu +8 -4 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.11 +8 -4 bug #659: Changes to support libopts on Windows - ports/winnt/ntpd/ntpd.dsp@1.28, 2006-08-07 08:42:01-04:00, mayer@pogo.udel.edu +6 -2 + ports/winnt/ntpd/ntpd.dsp@1.28 +6 -2 bug #659: Changes to support libopts on Windows - ports/winnt/ntpdc/ntpdc.dsp@1.18, 2006-08-07 08:42:01-04:00, mayer@pogo.udel.edu +6 -2 + ports/winnt/ntpdc/ntpdc.dsp@1.18 +6 -2 bug #659: Changes to support libopts on Windows - ports/winnt/ntpq/ntpq.dsp@1.19, 2006-08-07 08:42:01-04:00, mayer@pogo.udel.edu +8 -4 + ports/winnt/ntpq/ntpq.dsp@1.19 +8 -4 bug #659: Changes to support libopts on Windows -ChangeSet@1.1353.9.10, 2006-08-06 07:03:05-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.10, 2006-08-06 07:03:05-04:00, stenn@whimsy.udel.edu NTP_4_2_3P26 TAG: NTP_4_2_3P26 - packageinfo.sh@1.20, 2006-08-06 07:03:02-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.20 +1 -1 NTP_4_2_3P26 -ChangeSet@1.1353.9.9, 2006-08-05 21:31:02-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.9, 2006-08-05 21:31:02-04:00, stenn@whimsy.udel.edu NEWS: Support separate PPS devices for PARSE refclocks - NEWS@1.58, 2006-08-05 21:30:52-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.58 +1 -0 NEWS: Support separate PPS devices for PARSE refclocks -ChangeSet@1.1251.94.46, 2006-08-05 15:44:40-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.46, 2006-08-05 15:44:40-04:00, stenn@whimsy.udel.edu NTP_4_2_2P3 TAG: NTP_4_2_2P3 - packageinfo.sh@1.27.16.1, 2006-08-05 15:44:38-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.27.16.1 +2 -2 NTP_4_2_2P3 -ChangeSet@1.1353.10.1, 2006-08-05 07:05:02-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.10.1, 2006-08-05 07:05:02-04:00, stenn@whimsy.udel.edu NTP_4_2_3P25 TAG: NTP_4_2_3P25 - packageinfo.sh@1.19, 2006-08-05 07:04:56-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.19 +1 -1 NTP_4_2_3P25 -ChangeSet@1.1353.9.7, 2006-08-05 09:01:42+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1353.9.7, 2006-08-05 09:01:42+00:00, kardel@pogo.udel.edu driver8.html: document additional Meinberg clock mode document optionally separate PPS device (/dev/refclockpps-{0..3}) refclock_parse.c: support optionally separate PPS devices via /dev/refclockpps-{0..3} - html/drivers/driver8.html@1.19, 2006-08-05 08:59:00+00:00, kardel@pogo.udel.edu +12 -9 + html/drivers/driver8.html@1.19 +12 -9 document additional Meinberg clock mode document optionally separate PPS device (/dev/refclockpps-{0..3}) - ntpd/refclock_parse.c@1.46, 2006-08-05 08:58:19+00:00, kardel@pogo.udel.edu +57 -29 + ntpd/refclock_parse.c@1.46 +57 -29 support optionally separate PPS devices via /dev/refclockpps-{0..3} -ChangeSet@1.1353.9.6, 2006-08-05 02:10:36-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.9.6, 2006-08-05 02:10:36-04:00, stenn@whimsy.udel.edu Fixes from Dave. - ntpd/ntp_loopfilter.c@1.124, 2006-08-05 02:10:29-04:00, stenn@whimsy.udel.edu +22 -22 + ntpd/ntp_loopfilter.c@1.124 +22 -22 Dave sez: At cold start (no frequency file) the daemon sets the clock at the @@ -11950,7 +192717,7 @@ ChangeSet@1.1353.9.6, 2006-08-05 02:10:36-04:00, stenn@whimsy.udel.edu +2 -0 first update. The billboards should now be consistent with the Principle of Least Astonishment. - ntpd/ntp_proto.c@1.246, 2006-08-05 02:10:31-04:00, stenn@whimsy.udel.edu +19 -15 + ntpd/ntp_proto.c@1.246 +19 -15 Dave sez: At cold start (no frequency file) the daemon sets the clock at the @@ -11969,205 +192736,205 @@ ChangeSet@1.1353.9.6, 2006-08-05 02:10:36-04:00, stenn@whimsy.udel.edu +2 -0 first update. The billboards should now be consistent with the Principle of Least Astonishment. -ChangeSet@1.1353.9.5, 2006-08-05 01:27:50-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.9.5, 2006-08-05 01:27:50-04:00, stenn@whimsy.udel.edu Added uint_t check to libopts.m4 - libopts/m4/libopts.m4@1.5, 2006-08-05 01:27:37-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/m4/libopts.m4@1.5 +1 -1 Added uint_t check to libopts.m4 - sntp/libopts/m4/libopts.m4@1.5, 2006-08-05 01:27:38-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/m4/libopts.m4@1.5 +1 -1 Added uint_t check to libopts.m4 -ChangeSet@1.1251.94.45, 2006-08-05 00:52:33-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.45, 2006-08-05 00:52:33-04:00, stenn@whimsy.udel.edu Use the new format for the "send" emails - BitKeeper/triggers/send@1.11, 2006-08-05 00:52:03-04:00, stenn@whimsy.udel.edu +1 -4 + BitKeeper/triggers/send@1.11 +1 -4 Use the new format for the "send" emails -ChangeSet@1.1353.9.3, 2006-08-05 00:38:57-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.3, 2006-08-05 00:38:57-04:00, stenn@whimsy.udel.edu copy new packageinfo from -stable - packageinfo.sh@1.18, 2006-08-05 00:38:34-04:00, stenn@whimsy.udel.edu +4 -3 + packageinfo.sh@1.18 +4 -3 copy new packageinfo from -stable -ChangeSet@1.1251.94.44, 2006-08-04 21:46:01-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.44, 2006-08-04 21:46:01-04:00, stenn@whimsy.udel.edu ready for release - packageinfo.sh@1.27.15.2, 2006-08-04 21:45:50-04:00, stenn@whimsy.udel.edu +6 -6 + packageinfo.sh@1.27.15.2 +6 -6 ready for release - scripts/genChangeLog@1.2, 2006-08-04 16:18:47-04:00, stenn@whimsy.udel.edu +0 -0 + scripts/genChangeLog@1.2 +0 -0 Change mode to -rwxrwxr-x -ChangeSet@1.1251.94.43, 2006-08-04 16:00:28-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.94.43, 2006-08-04 16:00:28-04:00, stenn@whimsy.udel.edu Clean up the ChangeLog generation - Makefile.am@1.48.1.7, 2006-08-04 15:59:20-04:00, stenn@whimsy.udel.edu +3 -5 + Makefile.am@1.48.1.7 +3 -5 Clean up the ChangeLog generation - scripts/Makefile.am@1.14, 2006-08-04 15:59:21-04:00, stenn@whimsy.udel.edu +3 -2 + scripts/Makefile.am@1.14 +3 -2 Clean up the ChangeLog generation - scripts/genChangeLog@1.1, 2006-08-04 15:39:21-04:00, stenn@whimsy.udel.edu +7 -0 + scripts/genChangeLog@1.1 +7 -0 BitKeeper file /deacon/backroom/ntp-stable/scripts/genChangeLog - scripts/genChangeLog@1.0, 2006-08-04 15:39:21-04:00, stenn@whimsy.udel.edu +0 -0 + scripts/genChangeLog@1.0 +0 -0 -ChangeSet@1.1353.9.1, 2006-08-03 07:03:51-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.9.1, 2006-08-03 07:03:51-04:00, stenn@whimsy.udel.edu NTP_4_2_3P24 TAG: NTP_4_2_3P24 - packageinfo.sh@1.17, 2006-08-03 07:03:48-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.17 +1 -1 NTP_4_2_3P24 -ChangeSet@1.1353.1.96, 2006-08-02 20:21:23-04:00, stenn@whimsy.udel.edu +24 -0 +ChangeSet@1.1353.1.96, 2006-08-02 20:21:23-04:00, stenn@whimsy.udel.edu autogen upgrade - ntpd/ntpd-opts.c@1.3, 2006-08-02 20:20:38-04:00, stenn@whimsy.udel.edu +37 -15 + ntpd/ntpd-opts.c@1.3 +37 -15 autogen upgrade - ntpd/ntpd-opts.c@1.2, 2006-08-02 19:36:53-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.2 +0 -0 Change mode to -rw-r--r-- - ntpd/ntpd-opts.h@1.3, 2006-08-02 20:20:40-04:00, stenn@whimsy.udel.edu +21 -10 + ntpd/ntpd-opts.h@1.3 +21 -10 autogen upgrade - ntpd/ntpd-opts.h@1.2, 2006-08-02 19:36:54-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.2 +0 -0 Change mode to -rw-r--r-- - ntpd/ntpd-opts.texi@1.4, 2006-08-02 20:20:40-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd-opts.texi@1.4 +1 -1 autogen upgrade - ntpd/ntpd-opts.texi@1.3, 2006-08-02 19:36:56-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.3 +0 -0 Change mode to -rw-r--r-- - ntpd/ntpd.1@1.3, 2006-08-02 20:20:41-04:00, stenn@whimsy.udel.edu +33 -33 + ntpd/ntpd.1@1.3 +33 -33 autogen upgrade - ntpd/ntpd.1@1.2, 2006-08-02 19:36:57-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd.1@1.2 +0 -0 Change mode to -rw-r--r-- - ntpd/ntpdsim-opts.c@1.3, 2006-08-02 20:20:42-04:00, stenn@whimsy.udel.edu +37 -15 + ntpd/ntpdsim-opts.c@1.3 +37 -15 autogen upgrade - ntpd/ntpdsim-opts.c@1.2, 2006-08-02 19:36:58-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.2 +0 -0 Change mode to -rw-r--r-- - ntpd/ntpdsim-opts.h@1.3, 2006-08-02 20:20:43-04:00, stenn@whimsy.udel.edu +21 -10 + ntpd/ntpdsim-opts.h@1.3 +21 -10 autogen upgrade - ntpd/ntpdsim-opts.h@1.2, 2006-08-02 19:37:00-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.h@1.2 +0 -0 Change mode to -rw-r--r-- - ntpd/ntpdsim-opts.texi@1.3, 2006-08-02 20:20:44-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpdsim-opts.texi@1.3 +4 -4 autogen upgrade - ntpd/ntpdsim-opts.texi@1.2, 2006-08-02 19:37:02-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.2 +0 -0 Change mode to -rw-r--r-- - ntpd/ntpdsim.1@1.3, 2006-08-02 20:20:45-04:00, stenn@whimsy.udel.edu +42 -42 + ntpd/ntpdsim.1@1.3 +42 -42 autogen upgrade - ntpd/ntpdsim.1@1.2, 2006-08-02 19:37:04-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim.1@1.2 +0 -0 Change mode to -rw-r--r-- - ntpdc/ntpdc-opts.c@1.4, 2006-08-02 20:20:46-04:00, stenn@whimsy.udel.edu +2 -4 + ntpdc/ntpdc-opts.c@1.4 +2 -4 autogen upgrade - ntpdc/ntpdc-opts.c@1.3, 2006-08-02 19:37:06-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.3 +0 -0 Change mode to -rw-r--r-- - ntpdc/ntpdc-opts.h@1.4, 2006-08-02 20:20:47-04:00, stenn@whimsy.udel.edu +5 -4 + ntpdc/ntpdc-opts.h@1.4 +5 -4 autogen upgrade - ntpdc/ntpdc-opts.h@1.3, 2006-08-02 19:37:07-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.h@1.3 +0 -0 Change mode to -rw-r--r-- - ntpdc/ntpdc-opts.texi@1.4, 2006-08-02 20:20:47-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.texi@1.4 +3 -3 autogen upgrade - ntpdc/ntpdc-opts.texi@1.3, 2006-08-02 19:37:09-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.3 +0 -0 Change mode to -rw-r--r-- - ntpdc/ntpdc.1@1.4, 2006-08-02 20:20:48-04:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.1@1.4 +2 -2 autogen upgrade - ntpdc/ntpdc.1@1.3, 2006-08-02 19:37:10-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc.1@1.3 +0 -0 Change mode to -rw-r--r-- - ntpq/ntpq-opts.c@1.3, 2006-08-02 20:20:48-04:00, stenn@whimsy.udel.edu +38 -250 + ntpq/ntpq-opts.c@1.3 +38 -250 autogen upgrade - ntpq/ntpq-opts.c@1.2, 2006-08-02 19:37:12-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.2 +0 -0 Change mode to -rw-r--r-- - ntpq/ntpq-opts.h@1.3, 2006-08-02 20:20:49-04:00, stenn@whimsy.udel.edu +21 -10 + ntpq/ntpq-opts.h@1.3 +21 -10 autogen upgrade - ntpq/ntpq-opts.h@1.2, 2006-08-02 19:37:13-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.h@1.2 +0 -0 Change mode to -rw-r--r-- - ntpq/ntpq-opts.texi@1.3, 2006-08-02 20:20:49-04:00, stenn@whimsy.udel.edu +5 -244 + ntpq/ntpq-opts.texi@1.3 +5 -244 autogen upgrade - ntpq/ntpq-opts.texi@1.2, 2006-08-02 19:37:14-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.2 +0 -0 Change mode to -rw-r--r-- - ntpq/ntpq.1@1.3, 2006-08-02 20:20:50-04:00, stenn@whimsy.udel.edu +16 -16 + ntpq/ntpq.1@1.3 +16 -16 autogen upgrade - ntpq/ntpq.1@1.2, 2006-08-02 19:37:17-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq.1@1.2 +0 -0 Change mode to -rw-r--r-- - sntp/sntp-opts.c@1.3, 2006-08-02 20:20:51-04:00, stenn@whimsy.udel.edu +40 -260 + sntp/sntp-opts.c@1.3 +40 -260 autogen upgrade - sntp/sntp-opts.c@1.2, 2006-08-02 19:37:19-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.c@1.2 +0 -0 Change mode to -rw-r--r-- - sntp/sntp-opts.h@1.3, 2006-08-02 20:20:52-04:00, stenn@whimsy.udel.edu +21 -10 + sntp/sntp-opts.h@1.3 +21 -10 autogen upgrade - sntp/sntp-opts.h@1.2, 2006-08-02 19:37:22-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.h@1.2 +0 -0 Change mode to -rw-r--r-- - sntp/sntp-opts.texi@1.3, 2006-08-02 20:20:52-04:00, stenn@whimsy.udel.edu +4 -248 + sntp/sntp-opts.texi@1.3 +4 -248 autogen upgrade - sntp/sntp-opts.texi@1.2, 2006-08-02 19:37:24-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.texi@1.2 +0 -0 Change mode to -rw-r--r-- - sntp/sntp.1@1.6, 2006-08-02 20:20:53-04:00, stenn@whimsy.udel.edu +129 -64 + sntp/sntp.1@1.6 +129 -64 autogen upgrade - sntp/sntp.1@1.5, 2006-08-02 19:37:26-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.5 +0 -0 Change mode to -rw-r--r-- - util/ntp-keygen-opts.c@1.3, 2006-08-02 20:20:54-04:00, stenn@whimsy.udel.edu +54 -36 + util/ntp-keygen-opts.c@1.3 +54 -36 autogen upgrade - util/ntp-keygen-opts.c@1.2, 2006-08-02 19:37:29-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.2 +0 -0 Change mode to -rw-r--r-- - util/ntp-keygen-opts.h@1.3, 2006-08-02 20:20:55-04:00, stenn@whimsy.udel.edu +21 -10 + util/ntp-keygen-opts.h@1.3 +21 -10 autogen upgrade - util/ntp-keygen-opts.h@1.2, 2006-08-02 19:37:30-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.2 +0 -0 Change mode to -rw-r--r-- - util/ntp-keygen-opts.texi@1.3, 2006-08-02 20:20:56-04:00, stenn@whimsy.udel.edu +3 -3 + util/ntp-keygen-opts.texi@1.3 +3 -3 autogen upgrade - util/ntp-keygen-opts.texi@1.2, 2006-08-02 19:37:32-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.2 +0 -0 Change mode to -rw-r--r-- - util/ntp-keygen.1@1.3, 2006-08-02 20:20:56-04:00, stenn@whimsy.udel.edu +23 -23 + util/ntp-keygen.1@1.3 +23 -23 autogen upgrade - util/ntp-keygen.1@1.2, 2006-08-02 19:37:33-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen.1@1.2 +0 -0 Change mode to -rw-r--r-- -ChangeSet@1.1353.1.95, 2006-08-01 18:03:38+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1353.1.95, 2006-08-01 18:03:38+00:00, kardel@pogo.udel.edu ntp_io.c: Bug 678: make size of control message buffer configurable if @@ -12177,7 +192944,7 @@ ChangeSet@1.1353.1.95, 2006-08-01 18:03:38+00:00, kardel@pogo.udel.edu +1 -0 qnx limit is around 1900 bytes - qnx analysed by Michael Tatarinov - thanks - ntpd/ntp_io.c@1.234, 2006-08-01 17:59:17+00:00, kardel@pogo.udel.edu +4 -1 + ntpd/ntp_io.c@1.234 +4 -1 Bug 678: make size of control message buffer configurable if needbe. use lower default of 1536 bytes as qnx couldn't @@ -12186,326 +192953,326 @@ ChangeSet@1.1353.1.95, 2006-08-01 18:03:38+00:00, kardel@pogo.udel.edu +1 -0 qnx limit is around 1900 bytes - qnx analysed by Michael Tatarinov - thanks -ChangeSet@1.1353.1.94, 2006-08-01 06:41:31+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1353.1.94, 2006-08-01 06:41:31+00:00, kardel@pogo.udel.edu ntp_io.c: Bug 676: Correct name buffer size calculation. Found by Michael Tatarinov - thanks! - ntpd/ntp_io.c@1.233, 2006-08-01 06:40:29+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.233 +1 -1 Bug 676: Correct name buffer size calculation. Found by Michael Tatarinov - thanks! -ChangeSet@1.1353.1.93, 2006-07-29 07:02:56-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.93, 2006-07-29 07:02:56-04:00, stenn@whimsy.udel.edu NTP_4_2_3P23 TAG: NTP_4_2_3P23 - packageinfo.sh@1.16, 2006-07-29 07:02:54-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.16 +1 -1 NTP_4_2_3P23 -ChangeSet@1.1353.1.92, 2006-07-28 22:30:05-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.1.92, 2006-07-28 22:30:05-04:00, stenn@whimsy.udel.edu [Bug 659] Move large "detail" description to "prog-man-descrip" - ntpq/ntpq-opts.def@1.9, 2006-07-28 22:29:50-04:00, stenn@whimsy.udel.edu +12 -1 + ntpq/ntpq-opts.def@1.9 +12 -1 [Bug 659] Move large "detail" description to "prog-man-descrip" - sntp/sntp-opts.def@1.5, 2006-07-28 22:29:50-04:00, stenn@whimsy.udel.edu +15 -4 + sntp/sntp-opts.def@1.5 +15 -4 [Bug 659] Move large "detail" description to "prog-man-descrip" -ChangeSet@1.1353.1.91, 2006-07-28 07:42:56-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.91, 2006-07-28 07:42:56-04:00, stenn@whimsy.udel.edu NTP_4_2_3P22 TAG: NTP_4_2_3P22 - packageinfo.sh@1.15, 2006-07-28 07:42:53-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.15 +1 -1 NTP_4_2_3P22 -ChangeSet@1.1251.94.42, 2006-07-28 07:02:21-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.42, 2006-07-28 07:02:21-04:00, stenn@whimsy.udel.edu NTP_4_2_2P3 TAG: NTP_4_2_2P3 - packageinfo.sh@1.27.15.1, 2006-07-28 07:02:18-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.15.1 +1 -1 NTP_4_2_2P3 -ChangeSet@1.1251.94.41, 2006-07-28 01:28:32-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.41, 2006-07-28 01:28:32-04:00, stenn@whimsy.udel.edu Ready for release - packageinfo.sh@1.27.14.2, 2006-07-28 01:28:25-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.14.2 +1 -1 Ready for release -ChangeSet@1.1251.94.40, 2006-07-28 01:20:54-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.40, 2006-07-28 01:20:54-04:00, stenn@whimsy.udel.edu Ready for release - NEWS@1.50.1.5, 2006-07-28 01:20:39-04:00, stenn@whimsy.udel.edu +30 -27 + NEWS@1.50.1.5 +30 -27 Ready for release - packageinfo.sh@1.27.14.1, 2006-07-28 01:20:39-04:00, stenn@whimsy.udel.edu +3 -3 + packageinfo.sh@1.27.14.1 +3 -3 Ready for release -ChangeSet@1.1353.1.89, 2006-07-28 00:57:01-04:00, stenn@whimsy.udel.edu +12 -0 +ChangeSet@1.1353.1.89, 2006-07-28 00:57:01-04:00, stenn@whimsy.udel.edu libopts-27.4.2 - libopts/compat/snprintf.c@1.2, 2006-07-28 00:56:19-04:00, stenn@whimsy.udel.edu +28 -4 + libopts/compat/snprintf.c@1.2 +28 -4 libopts-27.4.2 - libopts/m4/libopts.m4@1.4, 2006-07-28 00:52:00-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/m4/libopts.m4@1.4 +1 -1 libopts-27.4.2 - libopts/makeshell.c@1.4, 2006-07-28 00:51:31-04:00, stenn@whimsy.udel.edu +9 -9 + libopts/makeshell.c@1.4 +9 -9 libopts-27.4.2 - libopts/proto.h@1.4, 2006-07-28 00:51:32-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/proto.h@1.4 +1 -1 libopts-27.4.2 - libopts/streqvcmp.c@1.3, 2006-07-28 00:51:34-04:00, stenn@whimsy.udel.edu +3 -5 + libopts/streqvcmp.c@1.3 +3 -5 libopts-27.4.2 - libopts/version.c@1.3, 2006-07-28 00:51:35-04:00, stenn@whimsy.udel.edu +4 -8 + libopts/version.c@1.3 +4 -8 libopts-27.4.2 - sntp/libopts/compat/snprintf.c@1.2, 2006-07-28 00:52:33-04:00, stenn@whimsy.udel.edu +28 -4 + sntp/libopts/compat/snprintf.c@1.2 +28 -4 libopts-27.4.2 - sntp/libopts/m4/libopts.m4@1.4, 2006-07-28 00:55:02-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/m4/libopts.m4@1.4 +1 -1 libopts-27.4.2 - sntp/libopts/makeshell.c@1.4, 2006-07-28 00:52:22-04:00, stenn@whimsy.udel.edu +9 -9 + sntp/libopts/makeshell.c@1.4 +9 -9 libopts-27.4.2 - sntp/libopts/proto.h@1.4, 2006-07-28 00:52:24-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/proto.h@1.4 +1 -1 libopts-27.4.2 - sntp/libopts/streqvcmp.c@1.3, 2006-07-28 00:52:26-04:00, stenn@whimsy.udel.edu +3 -5 + sntp/libopts/streqvcmp.c@1.3 +3 -5 libopts-27.4.2 - sntp/libopts/version.c@1.3, 2006-07-28 00:52:27-04:00, stenn@whimsy.udel.edu +4 -8 + sntp/libopts/version.c@1.3 +4 -8 libopts-27.4.2 -ChangeSet@1.1251.94.39, 2006-07-27 22:13:37-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.39, 2006-07-27 22:13:37-04:00, stenn@whimsy.udel.edu NEWS: updated - NEWS@1.50.1.4, 2006-07-27 22:13:28-04:00, stenn@whimsy.udel.edu +21 -2 + NEWS@1.50.1.4 +21 -2 NEWS: updated -ChangeSet@1.1251.94.38, 2006-07-27 22:07:57-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.38, 2006-07-27 22:07:57-04:00, stenn@whimsy.udel.edu Makefile.am: add a rule to generate the ChangeLog - Makefile.am@1.48.1.6, 2006-07-27 22:07:42-04:00, stenn@whimsy.udel.edu +9 -1 + Makefile.am@1.48.1.6 +9 -1 Makefile.am: add a rule to generate the ChangeLog -ChangeSet@1.1353.1.87, 2006-07-26 08:19:28-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.87, 2006-07-26 08:19:28-04:00, stenn@whimsy.udel.edu NTP_4_2_3P21 TAG: NTP_4_2_3P21 - packageinfo.sh@1.14, 2006-07-26 08:19:23-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.14 +1 -1 NTP_4_2_3P21 -ChangeSet@1.1251.94.37, 2006-07-26 07:02:51-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.37, 2006-07-26 07:02:51-04:00, stenn@whimsy.udel.edu NTP_4_2_2P3_RC2 TAG: NTP_4_2_2P3_RC2 - packageinfo.sh@1.27.13.1, 2006-07-26 07:02:46-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.13.1 +1 -1 NTP_4_2_2P3_RC2 -ChangeSet@1.1353.1.86, 2006-07-26 06:34:06-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.86, 2006-07-26 06:34:06-04:00, stenn@whimsy.udel.edu [Bug 660] Solaris wants _XOPEN_SOURCE, __EXTENSIONS__, and -lxnet -lsocket - configure.ac@1.388.1.4, 2006-07-26 06:33:48-04:00, stenn@whimsy.udel.edu +10 -3 + configure.ac@1.388.1.4 +10 -3 [Bug 660] Solaris wants _XOPEN_SOURCE, __EXTENSIONS__, and -lxnet -lsocket -ChangeSet@1.1353.1.85, 2006-07-26 04:16:13-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.85, 2006-07-26 04:16:13-04:00, stenn@whimsy.udel.edu [Bug 638] STREAMS_TLI is no longer needed - configure.ac@1.388.1.3, 2006-07-26 04:16:02-04:00, stenn@whimsy.udel.edu +0 -20 + configure.ac@1.388.1.3 +0 -20 [Bug 638] STREAMS_TLI is no longer needed -ChangeSet@1.1251.94.36, 2006-07-26 03:53:28-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.36, 2006-07-26 03:53:28-04:00, stenn@whimsy.udel.edu [Bug 601] ntpq's decodeint uses an extra level of indiraction - ntpq/ntpq.c@1.55.1.7, 2006-07-26 03:53:14-04:00, stenn@whimsy.udel.edu +2 -2 + ntpq/ntpq.c@1.55.1.7 +2 -2 [Bug 601] ntpq's decodeint uses an extra level of indiraction -ChangeSet@1.1251.94.35, 2006-07-26 02:56:32-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.35, 2006-07-26 02:56:32-04:00, stenn@whimsy.udel.edu Don't do anything in a RESYNC repo - BitKeeper/triggers/send@1.10, 2006-07-26 02:56:23-04:00, stenn@whimsy.udel.edu +6 -0 + BitKeeper/triggers/send@1.10 +6 -0 Don't do anything in a RESYNC repo -ChangeSet@1.1251.94.34, 2006-07-26 02:34:51-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.34, 2006-07-26 02:34:51-04:00, stenn@whimsy.udel.edu Test the -m option in the send trigger - BitKeeper/triggers/send@1.9, 2006-07-26 02:34:40-04:00, stenn@whimsy.udel.edu +4 -1 + BitKeeper/triggers/send@1.9 +4 -1 Test the -m option in the send trigger -ChangeSet@1.1353.1.81, 2006-07-26 01:04:24-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.81, 2006-07-26 01:04:24-04:00, stenn@whimsy.udel.edu [Bug 479] -P needs to set priority_done=0 - ntpd/ntpd.c@1.80, 2006-07-26 00:16:05-04:00, stenn@whimsy.udel.edu +1 -0 + ntpd/ntpd.c@1.80 +1 -0 [Bug 479] -P needs to set priority_done=0 -ChangeSet@1.1353.1.80, 2006-07-26 00:55:28-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1353.1.80, 2006-07-26 00:55:28-04:00, stenn@whimsy.udel.edu AutoOpts cleanup - common .def entries are already in copyright.def - ntpd/ntpd-opts.def@1.5, 2006-07-26 00:55:23-04:00, stenn@whimsy.udel.edu +0 -3 + ntpd/ntpd-opts.def@1.5 +0 -3 common .def entries are already in copyright.def - ntpd/ntpd-opts.texi@1.2, 2006-07-26 00:55:23-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntpd-opts.texi@1.2 +4 -4 Updated - ntpd/ntpdsim-opts.def@1.5, 2006-07-26 00:55:24-04:00, stenn@whimsy.udel.edu +0 -3 + ntpd/ntpdsim-opts.def@1.5 +0 -3 common .def entries are already in copyright.def - ntpq/ntpq-opts.def@1.8, 2006-07-25 06:08:56-04:00, stenn@whimsy.udel.edu +0 -3 + ntpq/ntpq-opts.def@1.8 +0 -3 common .def entries are already in copyright.def - util/ntp-keygen-opts.def@1.5, 2006-07-25 06:06:53-04:00, stenn@whimsy.udel.edu +0 -3 + util/ntp-keygen-opts.def@1.5 +0 -3 common .def entries are already in copyright.def -ChangeSet@1.1353.1.79, 2006-07-23 07:03:50-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.79, 2006-07-23 07:03:50-04:00, stenn@whimsy.udel.edu NTP_4_2_3P20 TAG: NTP_4_2_3P20 - packageinfo.sh@1.13, 2006-07-23 07:03:48-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.13 +1 -1 NTP_4_2_3P20 -ChangeSet@1.1353.1.78, 2006-07-22 23:35:43-04:00, stenn@whimsy.udel.edu +42 -0 +ChangeSet@1.1353.1.78, 2006-07-22 23:35:43-04:00, stenn@whimsy.udel.edu windows-config.h: BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h Many files: Upgrade to libopts-27.4.2 - libopts/Makefile.am@1.3, 2006-07-22 23:28:42-04:00, stenn@whimsy.udel.edu +14 -14 + libopts/Makefile.am@1.3 +14 -14 Upgrade to libopts-27.4.2 - libopts/autoopts.c@1.3, 2006-07-22 23:28:42-04:00, stenn@whimsy.udel.edu +7 -9 + libopts/autoopts.c@1.3 +7 -9 Upgrade to libopts-27.4.2 - libopts/autoopts.h@1.3, 2006-07-22 23:28:43-04:00, stenn@whimsy.udel.edu +7 -8 + libopts/autoopts.h@1.3 +7 -8 Upgrade to libopts-27.4.2 - libopts/autoopts/options.h@1.3, 2006-07-22 23:33:13-04:00, stenn@whimsy.udel.edu +64 -62 + libopts/autoopts/options.h@1.3 +64 -62 Upgrade to libopts-27.4.2 - libopts/autoopts/usage-txt.h@1.2, 2006-07-22 23:33:14-04:00, stenn@whimsy.udel.edu +271 -395 + libopts/autoopts/usage-txt.h@1.2 +271 -395 Upgrade to libopts-27.4.2 - libopts/compat/compat.h@1.3, 2006-07-22 23:33:15-04:00, stenn@whimsy.udel.edu +25 -9 + libopts/compat/compat.h@1.3 +25 -9 Upgrade to libopts-27.4.2 - libopts/compat/pathfind.c@1.3, 2006-07-22 23:33:15-04:00, stenn@whimsy.udel.edu +12 -3 + libopts/compat/pathfind.c@1.3 +12 -3 Upgrade to libopts-27.4.2 - libopts/compat/windows-config.h@1.1, 2006-07-22 23:27:32-04:00, stenn@whimsy.udel.edu +118 -0 + libopts/compat/windows-config.h@1.1 +118 -0 BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/windows-config.h - libopts/compat/windows-config.h@1.0, 2006-07-22 23:27:32-04:00, stenn@whimsy.udel.edu +0 -0 + libopts/compat/windows-config.h@1.0 +0 -0 - libopts/configfile.c@1.3, 2006-07-22 23:28:44-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/configfile.c@1.3 +1 -1 Upgrade to libopts-27.4.2 - libopts/genshell.c@1.2, 2006-07-22 23:28:46-04:00, stenn@whimsy.udel.edu +50 -10 + libopts/genshell.c@1.2 +50 -10 Upgrade to libopts-27.4.2 - libopts/genshell.h@1.2, 2006-07-22 23:28:46-04:00, stenn@whimsy.udel.edu +21 -10 + libopts/genshell.h@1.2 +21 -10 Upgrade to libopts-27.4.2 - libopts/libopts.c@1.3, 2006-07-22 23:28:47-04:00, stenn@whimsy.udel.edu +0 -1 + libopts/libopts.c@1.3 +0 -1 Upgrade to libopts-27.4.2 - libopts/load.c@1.3, 2006-07-22 23:28:47-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/load.c@1.3 +1 -1 Upgrade to libopts-27.4.2 - libopts/m4/libopts.m4@1.3, 2006-07-22 23:33:17-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/m4/libopts.m4@1.3 +1 -1 Upgrade to libopts-27.4.2 - libopts/makeshell.c@1.3, 2006-07-22 23:28:48-04:00, stenn@whimsy.udel.edu +11 -2 + libopts/makeshell.c@1.3 +11 -2 Upgrade to libopts-27.4.2 - libopts/pgusage.c@1.3, 2006-07-22 23:28:49-04:00, stenn@whimsy.udel.edu +7 -3 + libopts/pgusage.c@1.3 +7 -3 Upgrade to libopts-27.4.2 - libopts/proto.h@1.3, 2006-07-22 23:28:50-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/proto.h@1.3 +1 -1 Upgrade to libopts-27.4.2 - libopts/putshell.c@1.3, 2006-07-22 23:28:50-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/putshell.c@1.3 +3 -3 Upgrade to libopts-27.4.2 - libopts/save.c@1.3, 2006-07-22 23:28:51-04:00, stenn@whimsy.udel.edu +3 -3 + libopts/save.c@1.3 +3 -3 Upgrade to libopts-27.4.2 - libopts/stack.c@1.3, 2006-07-22 23:28:52-04:00, stenn@whimsy.udel.edu +5 -3 + libopts/stack.c@1.3 +5 -3 Upgrade to libopts-27.4.2 - libopts/usage.c@1.3, 2006-07-22 23:28:53-04:00, stenn@whimsy.udel.edu +1 -1 + libopts/usage.c@1.3 +1 -1 Upgrade to libopts-27.4.2 - sntp/libopts/Makefile.am@1.3, 2006-07-22 23:34:06-04:00, stenn@whimsy.udel.edu +14 -14 + sntp/libopts/Makefile.am@1.3 +14 -14 Upgrade to libopts-27.4.2 - sntp/libopts/autoopts.c@1.3, 2006-07-22 23:34:07-04:00, stenn@whimsy.udel.edu +7 -9 + sntp/libopts/autoopts.c@1.3 +7 -9 Upgrade to libopts-27.4.2 - sntp/libopts/autoopts.h@1.3, 2006-07-22 23:34:07-04:00, stenn@whimsy.udel.edu +7 -8 + sntp/libopts/autoopts.h@1.3 +7 -8 Upgrade to libopts-27.4.2 - sntp/libopts/autoopts/options.h@1.3, 2006-07-22 23:34:18-04:00, stenn@whimsy.udel.edu +64 -62 + sntp/libopts/autoopts/options.h@1.3 +64 -62 Upgrade to libopts-27.4.2 - sntp/libopts/autoopts/usage-txt.h@1.2, 2006-07-22 23:34:19-04:00, stenn@whimsy.udel.edu +271 -395 + sntp/libopts/autoopts/usage-txt.h@1.2 +271 -395 Upgrade to libopts-27.4.2 - sntp/libopts/compat/compat.h@1.3, 2006-07-22 23:34:19-04:00, stenn@whimsy.udel.edu +25 -9 + sntp/libopts/compat/compat.h@1.3 +25 -9 Upgrade to libopts-27.4.2 - sntp/libopts/compat/pathfind.c@1.3, 2006-07-22 23:34:20-04:00, stenn@whimsy.udel.edu +12 -3 + sntp/libopts/compat/pathfind.c@1.3 +12 -3 Upgrade to libopts-27.4.2 - sntp/libopts/compat/windows-config.h@1.1, 2006-07-22 23:27:32-04:00, stenn@whimsy.udel.edu +118 -0 + sntp/libopts/compat/windows-config.h@1.1 +118 -0 BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/windows-config.h - sntp/libopts/compat/windows-config.h@1.0, 2006-07-22 23:27:32-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/compat/windows-config.h@1.0 +0 -0 - sntp/libopts/configfile.c@1.3, 2006-07-22 23:34:08-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/configfile.c@1.3 +1 -1 Upgrade to libopts-27.4.2 - sntp/libopts/genshell.c@1.2, 2006-07-22 23:34:10-04:00, stenn@whimsy.udel.edu +50 -10 + sntp/libopts/genshell.c@1.2 +50 -10 Upgrade to libopts-27.4.2 - sntp/libopts/genshell.h@1.2, 2006-07-22 23:34:10-04:00, stenn@whimsy.udel.edu +21 -10 + sntp/libopts/genshell.h@1.2 +21 -10 Upgrade to libopts-27.4.2 - sntp/libopts/libopts.c@1.3, 2006-07-22 23:34:11-04:00, stenn@whimsy.udel.edu +0 -1 + sntp/libopts/libopts.c@1.3 +0 -1 Upgrade to libopts-27.4.2 - sntp/libopts/load.c@1.3, 2006-07-22 23:34:11-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/load.c@1.3 +1 -1 Upgrade to libopts-27.4.2 - sntp/libopts/m4/libopts.m4@1.3, 2006-07-22 23:34:21-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/m4/libopts.m4@1.3 +1 -1 Upgrade to libopts-27.4.2 - sntp/libopts/makeshell.c@1.3, 2006-07-22 23:34:12-04:00, stenn@whimsy.udel.edu +11 -2 + sntp/libopts/makeshell.c@1.3 +11 -2 Upgrade to libopts-27.4.2 - sntp/libopts/pgusage.c@1.3, 2006-07-22 23:34:13-04:00, stenn@whimsy.udel.edu +7 -3 + sntp/libopts/pgusage.c@1.3 +7 -3 Upgrade to libopts-27.4.2 - sntp/libopts/proto.h@1.3, 2006-07-22 23:34:13-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/proto.h@1.3 +1 -1 Upgrade to libopts-27.4.2 - sntp/libopts/putshell.c@1.3, 2006-07-22 23:34:13-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/libopts/putshell.c@1.3 +3 -3 Upgrade to libopts-27.4.2 - sntp/libopts/save.c@1.3, 2006-07-22 23:34:14-04:00, stenn@whimsy.udel.edu +3 -3 + sntp/libopts/save.c@1.3 +3 -3 Upgrade to libopts-27.4.2 - sntp/libopts/stack.c@1.3, 2006-07-22 23:34:15-04:00, stenn@whimsy.udel.edu +5 -3 + sntp/libopts/stack.c@1.3 +5 -3 Upgrade to libopts-27.4.2 - sntp/libopts/usage.c@1.3, 2006-07-22 23:34:16-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/libopts/usage.c@1.3 +1 -1 Upgrade to libopts-27.4.2 -ChangeSet@1.1353.1.77, 2006-07-22 10:12:26+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1353.1.77, 2006-07-22 10:12:26+00:00, kardel@pogo.udel.edu ntp_io.c: move debug level for most interface based activity up to 3 and 4 3 major steps and decisions, 4 for tracing like events. @@ -12515,17 +193282,17 @@ ChangeSet@1.1353.1.77, 2006-07-22 10:12:26+00:00, kardel@pogo.udel.edu +2 -0 move debug level for some interface based activity up to 3 and 4 3 major steps and decisions, 4 for tracing like events. - ntpd/ntp_io.c@1.232, 2006-07-22 10:08:32+00:00, kardel@pogo.udel.edu +98 -105 + ntpd/ntp_io.c@1.232 +98 -105 move debug level for most interface based activity up to 3 and 4 3 major steps and decisions, 4 for tracing like events. remove some #ifdef cruft from sendpkt() - remove SILENT exits that don't make sense. - ntpd/ntp_peer.c@1.96, 2006-07-22 10:11:02+00:00, kardel@pogo.udel.edu +4 -4 + ntpd/ntp_peer.c@1.96 +4 -4 move debug level for some interface based activity up to 3 and 4 3 major steps and decisions, 4 for tracing like events. -ChangeSet@1.1353.1.76, 2006-07-22 10:04:56+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1353.1.76, 2006-07-22 10:04:56+00:00, kardel@pogo.udel.edu ntp_request.h: bug 672: rearrange struct info_if_stats to be compacter and @@ -12535,96 +193302,96 @@ ChangeSet@1.1353.1.76, 2006-07-22 10:04:56+00:00, kardel@pogo.udel.edu +2 -0 bug 672: document changed struct info_if_stats layout - include/ntp_request.h@1.30, 2006-07-22 09:57:38+00:00, kardel@pogo.udel.edu +3 -2 + include/ntp_request.h@1.30 +3 -2 bug 672: rearrange struct info_if_stats to be compacter and pad to a 64 bit size boundary for coexistance with 32 and 64 bit platforms - ntpdc/layout.std@1.7, 2006-07-22 10:00:27+00:00, kardel@pogo.udel.edu +16 -15 + ntpdc/layout.std@1.7 +16 -15 bug 672: document changed struct info_if_stats layout -ChangeSet@1.1353.1.75, 2006-07-21 08:10:58-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.75, 2006-07-21 08:10:58-04:00, stenn@whimsy.udel.edu NTP_4_2_3P19 TAG: NTP_4_2_3P19 - packageinfo.sh@1.12, 2006-07-21 08:10:56-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.12 +1 -1 NTP_4_2_3P19 -ChangeSet@1.1251.94.33, 2006-07-21 07:02:38-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.33, 2006-07-21 07:02:38-04:00, stenn@whimsy.udel.edu NTP_4_2_2P3_RC1 TAG: NTP_4_2_2P3_RC1 - packageinfo.sh@1.27.12.1, 2006-07-21 07:02:33-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.12.1 +1 -1 NTP_4_2_2P3_RC1 -ChangeSet@1.1251.94.32, 2006-07-20 17:22:04-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.32, 2006-07-20 17:22:04-04:00, stenn@whimsy.udel.edu Don't bother trying to mirror a RESYNC repo - BitKeeper/triggers/2mirrors@1.3, 2006-07-20 17:18:06-04:00, stenn@whimsy.udel.edu +6 -0 + BitKeeper/triggers/2mirrors@1.3 +6 -0 Don't bother trying to mirror a RESYNC repo -ChangeSet@1.1251.94.31, 2006-07-20 15:50:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.31, 2006-07-20 15:50:44-04:00, stenn@whimsy.udel.edu [Bug 671] Windows wants TYPEOF_IP_MULTICAST_SPOOL=BOOL - configure.ac@1.359.5.3, 2006-07-20 15:45:10-04:00, stenn@whimsy.udel.edu +4 -1 + configure.ac@1.359.5.3 +4 -1 [Bug 671] Windows wants TYPEOF_IP_MULTICAST_SPOOL=BOOL -ChangeSet@1.1353.1.72, 2006-07-20 13:49:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.72, 2006-07-20 13:49:44-04:00, stenn@whimsy.udel.edu NTP_4_2_3P18 TAG: NTP_4_2_3P18 - packageinfo.sh@1.11, 2006-07-20 13:49:25-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.11 +1 -1 NTP_4_2_3P18 -ChangeSet@1.1251.94.30, 2006-07-20 07:20:34-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.30, 2006-07-20 07:20:34-04:00, stenn@whimsy.udel.edu NTP_4_2_2P3_RC0 TAG: NTP_4_2_2P3_RC0 - packageinfo.sh@1.27.11.1, 2006-07-20 07:20:29-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.11.1 +1 -1 NTP_4_2_2P3_RC0 -ChangeSet@1.1251.94.29, 2006-07-19 22:22:49-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.94.29, 2006-07-19 22:22:49-04:00, stenn@deacon.udel.edu Send the diffs before the patch in the send trigger. - BitKeeper/triggers/send@1.8, 2006-07-19 22:22:42-04:00, stenn@deacon.udel.edu +4 -2 + BitKeeper/triggers/send@1.8 +4 -2 Send the diffs before the patch in the send trigger. -ChangeSet@1.1251.94.28, 2006-07-19 22:19:11-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.94.28, 2006-07-19 22:19:11-04:00, stenn@deacon.udel.edu update the path to the winnt.html file - INSTALL@1.8, 2006-07-19 22:19:03-04:00, stenn@deacon.udel.edu +1 -1 + INSTALL@1.8 +1 -1 update the path to the winnt.html file -ChangeSet@1.1251.94.27, 2006-07-19 21:55:54-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.94.27, 2006-07-19 21:55:54-04:00, stenn@deacon.udel.edu Ignore autom4te.cache directories - BitKeeper/etc/ignore@1.35.1.4, 2006-07-19 21:55:46-04:00, stenn@deacon.udel.edu +2 -1 + BitKeeper/etc/ignore@1.35.1.4 +2 -1 Ignore autom4te.cache directories -ChangeSet@1.1353.1.69, 2006-07-19 21:00:05-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1353.1.69, 2006-07-19 21:00:05-04:00, stenn@deacon.udel.edu Run the licfix script quietly - BitKeeper/triggers/pre-resolve.licfix@1.3, 2006-07-19 20:59:54-04:00, stenn@deacon.udel.edu +1 -1 + BitKeeper/triggers/pre-resolve.licfix@1.3 +1 -1 Run the licfix script quietly -ChangeSet@1.1251.94.26, 2006-07-19 05:24:23-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.94.26, 2006-07-19 05:24:23-04:00, stenn@pogo.udel.edu [Bug 657] netbsd fix for IP_MULTICAST_LOOP test - configure.ac@1.359.5.2, 2006-07-19 05:24:14-04:00, stenn@pogo.udel.edu +1 -1 + configure.ac@1.359.5.2 +1 -1 [Bug 657] netbsd fix for IP_MULTICAST_LOOP test -ChangeSet@1.1251.94.25, 2006-07-19 03:10:22-04:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1251.94.25, 2006-07-19 03:10:22-04:00, stenn@pogo.udel.edu [Bug 657] Different OSes need different sized args for IP_MULTICAST_LOOP - configure.ac@1.359.5.1, 2006-07-19 03:10:08-04:00, stenn@pogo.udel.edu +15 -1 + configure.ac@1.359.5.1 +15 -1 [Bug 657] Different OSes need different sized args for IP_MULTICAST_LOOP - ntpd/ntp_io.c@1.187.1.19, 2006-07-19 03:10:09-04:00, stenn@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.187.1.19 +1 -1 [Bug 657] Different OSes need different sized args for IP_MULTICAST_LOOP -ChangeSet@1.1353.1.67, 2006-07-15 09:35:45+00:00, kardel@pogo.udel.edu +3 -0 +ChangeSet@1.1353.1.67, 2006-07-15 09:35:45+00:00, kardel@pogo.udel.edu ntp_io.c: cleanup debug messages add RTM_REDIRECT, RTM_CHANGE as additional interface list scan @@ -12637,166 +193404,166 @@ ChangeSet@1.1353.1.67, 2006-07-15 09:35:45+00:00, kardel@pogo.udel.edu +3 -0 - only bind to non wildcard interfaces even if the OS would offer to send via such an interface - include/ntpd.h@1.93, 2006-07-15 09:06:47+00:00, kardel@pogo.udel.edu +0 -1 + include/ntpd.h@1.93 +0 -1 select_peerinterface() is comletely private to ntp_peer.c - ntpd/ntp_io.c@1.230, 2006-07-15 08:59:23+00:00, kardel@pogo.udel.edu +9 -3 + ntpd/ntp_io.c@1.230 +9 -3 cleanup debug messages add RTM_REDIRECT, RTM_CHANGE as additional interface list scan routing message triggers - ntpd/ntp_peer.c@1.95, 2006-07-15 09:04:48+00:00, kardel@pogo.udel.edu +43 -31 + ntpd/ntp_peer.c@1.95 +43 -31 - clear crypto when leaving a bound interface - re-arrange initialization for more usable debug output - only bind to non wildcard interfaces even if the OS would offer to send via such an interface -ChangeSet@1.1353.1.66, 2006-07-10 18:08:35+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1353.1.66, 2006-07-10 18:08:35+00:00, kardel@pogo.udel.edu ntp_io.c: fix prototype argument type to match implementation - ntpd/ntp_io.c@1.229, 2006-07-10 18:07:50+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.229 +1 -1 fix prototype argument type to match implementation -ChangeSet@1.1353.1.65, 2006-07-10 07:42:31-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.65, 2006-07-10 07:42:31-04:00, stenn@whimsy.udel.edu NTP_4_2_3P17 TAG: NTP_4_2_3P17 - packageinfo.sh@1.10, 2006-07-10 07:42:26-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.10 +1 -1 NTP_4_2_3P17 -ChangeSet@1.1251.97.31, 2006-07-10 07:02:26-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.31, 2006-07-10 07:02:26-04:00, stenn@whimsy.udel.edu NTP_4_2_2P3_RC TAG: NTP_4_2_2P3_RC - packageinfo.sh@1.27.9.1, 2006-07-10 07:02:23-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.27.9.1 +2 -2 NTP_4_2_2P3_RC -ChangeSet@1.1251.97.30, 2006-07-10 03:27:15-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.30, 2006-07-10 03:27:15-04:00, stenn@whimsy.udel.edu cleanup - NEWS@1.50.1.3, 2006-07-10 03:27:07-04:00, stenn@whimsy.udel.edu +1 -1 + NEWS@1.50.1.3 +1 -1 cleanup -ChangeSet@1.1251.97.29, 2006-07-10 03:14:23-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.29, 2006-07-10 03:14:23-04:00, stenn@whimsy.udel.edu Start an RC cycle with the new changes - packageinfo.sh@1.27.8.1, 2006-07-10 03:14:13-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.27.8.1 +2 -2 Start an RC cycle with the new changes -ChangeSet@1.1251.97.28, 2006-07-10 03:07:33-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.28, 2006-07-10 03:07:33-04:00, stenn@whimsy.udel.edu Use a decent Subject: line for the new send trigger - BitKeeper/triggers/send@1.7, 2006-07-10 03:07:21-04:00, stenn@whimsy.udel.edu +2 -1 + BitKeeper/triggers/send@1.7 +2 -1 Use a decent Subject: line for the new send trigger -ChangeSet@1.1251.97.27, 2006-07-10 01:54:26-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.27, 2006-07-10 01:54:26-04:00, stenn@whimsy.udel.edu Also use the new "bk changes" command for the "send" emails - BitKeeper/triggers/send@1.6, 2006-07-10 01:54:10-04:00, stenn@whimsy.udel.edu +15 -0 + BitKeeper/triggers/send@1.6 +15 -0 Also use the new "bk changes" command for the "send" emails -ChangeSet@1.1251.97.26, 2006-07-10 01:40:48-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.26, 2006-07-10 01:40:48-04:00, stenn@whimsy.udel.edu update - README@1.22, 2006-07-10 01:40:24-04:00, stenn@whimsy.udel.edu +3 -3 + README@1.22 +3 -3 update -ChangeSet@1.1251.97.25, 2006-07-10 01:32:25-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.25, 2006-07-10 01:32:25-04:00, stenn@whimsy.udel.edu update - WHERE-TO-START@1.6, 2006-07-10 01:32:11-04:00, stenn@whimsy.udel.edu +5 -5 + WHERE-TO-START@1.6 +5 -5 update -ChangeSet@1.1251.97.24, 2006-07-10 01:20:12-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.24, 2006-07-10 01:20:12-04:00, stenn@whimsy.udel.edu Note that sntp now builds under AIX 5 - NEWS@1.50.1.2, 2006-07-10 01:19:55-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.50.1.2 +1 -0 Note that sntp now builds under AIX 5 -ChangeSet@1.1251.97.23, 2006-07-10 00:21:34-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.23, 2006-07-10 00:21:34-04:00, stenn@whimsy.udel.edu Have sntp build config.h, and cleanup some quoting - sntp/configure.ac@1.8.1.1, 2006-07-10 00:21:23-04:00, stenn@whimsy.udel.edu +3 -2 + sntp/configure.ac@1.8.1.1 +3 -2 Have sntp build config.h, and cleanup some quoting -ChangeSet@1.1353.1.62, 2006-07-09 07:25:54-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.62, 2006-07-09 07:25:54-04:00, stenn@whimsy.udel.edu NTP_4_2_3P16 TAG: NTP_4_2_3P16 - packageinfo.sh@1.9, 2006-07-09 07:25:52-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.9 +1 -1 NTP_4_2_3P16 -ChangeSet@1.1251.97.22, 2006-07-09 07:02:21-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.22, 2006-07-09 07:02:21-04:00, stenn@whimsy.udel.edu NTP_4_2_2P2 TAG: NTP_4_2_2P2 - packageinfo.sh@1.27.7.1, 2006-07-09 07:02:18-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.7.1 +1 -1 NTP_4_2_2P2 -ChangeSet@1.1353.1.60, 2006-07-09 00:41:37-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.60, 2006-07-09 00:41:37-04:00, stenn@whimsy.udel.edu socket.c needs stuff from config.h - sntp/socket.c@1.6, 2006-07-09 00:35:36-04:00, stenn@whimsy.udel.edu +2 -0 + sntp/socket.c@1.6 +2 -0 socket.c needs stuff from config.h -ChangeSet@1.1251.97.21, 2006-07-09 00:39:26-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.21, 2006-07-09 00:39:26-04:00, stenn@whimsy.udel.edu socket.c needs stuff from config.h - sntp/socket.c@1.5.1.1, 2006-07-09 00:39:11-04:00, stenn@whimsy.udel.edu +2 -0 + sntp/socket.c@1.5.1.1 +2 -0 socket.c needs stuff from config.h -ChangeSet@1.1353.6.1, 2006-07-08 07:26:18-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.6.1, 2006-07-08 07:26:18-04:00, stenn@whimsy.udel.edu NTP_4_2_3P15 TAG: NTP_4_2_3P15 - packageinfo.sh@1.8, 2006-07-08 07:26:13-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.8 +1 -1 NTP_4_2_3P15 -ChangeSet@1.1251.97.20, 2006-07-08 07:02:36-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.20, 2006-07-08 07:02:36-04:00, stenn@whimsy.udel.edu NTP_4_2_2P1 TAG: NTP_4_2_2P1 - packageinfo.sh@1.27.6.1, 2006-07-08 07:02:33-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.6.1 +1 -1 NTP_4_2_2P1 -ChangeSet@1.1353.1.56, 2006-07-08 06:36:29-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1353.1.56, 2006-07-08 06:36:29-04:00, stenn@whimsy.udel.edu [Bug 667] Fix ntpdc's option processing - ntpdc/ntpdc-opts.c@1.2, 2006-07-08 06:36:04-04:00, stenn@whimsy.udel.edu +38 -13 + ntpdc/ntpdc-opts.c@1.2 +38 -13 [Bug 667] Fix ntpdc's option processing - ntpdc/ntpdc-opts.h@1.2, 2006-07-08 06:36:05-04:00, stenn@whimsy.udel.edu +20 -10 + ntpdc/ntpdc-opts.h@1.2 +20 -10 [Bug 667] Fix ntpdc's option processing - ntpdc/ntpdc-opts.texi@1.2, 2006-07-08 06:36:05-04:00, stenn@whimsy.udel.edu +3 -3 + ntpdc/ntpdc-opts.texi@1.2 +3 -3 [Bug 667] Fix ntpdc's option processing - ntpdc/ntpdc.1@1.2, 2006-07-08 06:36:06-04:00, stenn@whimsy.udel.edu +17 -16 + ntpdc/ntpdc.1@1.2 +17 -16 [Bug 667] Fix ntpdc's option processing -ChangeSet@1.1251.97.19, 2006-07-08 06:19:53-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.19, 2006-07-08 06:19:53-04:00, stenn@whimsy.udel.edu Time for the point release - packageinfo.sh@1.27.5.2, 2006-07-08 06:19:45-04:00, stenn@whimsy.udel.edu +3 -3 + packageinfo.sh@1.27.5.2 +3 -3 Time for the point release -ChangeSet@1.1251.97.18, 2006-07-08 06:16:07-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.18, 2006-07-08 06:16:07-04:00, stenn@whimsy.udel.edu cleanup the bk ignore file - BitKeeper/etc/ignore@1.35.1.3, 2006-07-08 06:15:30-04:00, stenn@whimsy.udel.edu +34 -34 + BitKeeper/etc/ignore@1.35.1.3 +34 -34 cleanup the bk ignore file -ChangeSet@1.1353.1.55, 2006-07-08 06:06:02-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.1.55, 2006-07-08 06:06:02-04:00, stenn@whimsy.udel.edu [Bug 667] Fix ntpdc's option processing - ntpdc/ntpdc-opts.def@1.11, 2006-07-08 06:05:51-04:00, stenn@whimsy.udel.edu +1 -0 + ntpdc/ntpdc-opts.def@1.11 +1 -0 [Bug 667] Fix ntpdc's option processing - ntpdc/ntpdc.c@1.53, 2006-07-08 06:05:51-04:00, stenn@whimsy.udel.edu +15 -0 + ntpdc/ntpdc.c@1.53 +15 -0 [Bug 667] Fix ntpdc's option processing -ChangeSet@1.1353.5.1, 2006-07-08 08:22:35+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1353.5.1, 2006-07-08 08:22:35+00:00, kardel@pogo.udel.edu ntp_io.c: simplify move_fd() refactor socket level udp paket time stamping by creating fetch_timestamp() for the @@ -12805,7 +193572,7 @@ ChangeSet@1.1353.5.1, 2006-07-08 08:22:35+00:00, kardel@pogo.udel.edu +1 -0 only enable socket time stamping when CMSG_* macros are defined cleanup minor signedness issues with pointer target types for length arguments - ntpd/ntp_io.c@1.228, 2006-07-08 08:17:45+00:00, kardel@pogo.udel.edu +93 -75 + ntpd/ntp_io.c@1.228 +93 -75 simplify move_fd() refactor socket level udp paket time stamping by creating fetch_timestamp() for the interfaces we will implement @@ -12813,1051 +193580,1051 @@ ChangeSet@1.1353.5.1, 2006-07-08 08:22:35+00:00, kardel@pogo.udel.edu +1 -0 only enable socket time stamping when CMSG_* macros are defined cleanup minor signedness issues with pointer target types for length arguments -ChangeSet@1.1353.1.54, 2006-07-08 03:04:02-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.1.54, 2006-07-08 03:04:02-04:00, stenn@whimsy.udel.edu Fix the hppa2.0-hp-hpux10.20 -H case - configure.ac@1.388, 2006-07-08 03:03:30-04:00, stenn@whimsy.udel.edu +4 -3 + configure.ac@1.388 +4 -3 Fix the hppa2.0-hp-hpux10.20 -H case - sntp/configure.ac@1.12, 2006-07-08 03:03:31-04:00, stenn@whimsy.udel.edu +4 -3 + sntp/configure.ac@1.12 +4 -3 Fix the hppa2.0-hp-hpux10.20 -H case -ChangeSet@1.1353.1.53, 2006-07-07 18:34:28-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.53, 2006-07-07 18:34:28-04:00, stenn@whimsy.udel.edu NTP_4_2_3P14 TAG: NTP_4_2_3P14 - packageinfo.sh@1.7, 2006-07-07 18:34:19-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.7 +1 -1 NTP_4_2_3P14 -ChangeSet@1.1353.1.52, 2006-07-07 15:20:47-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.52, 2006-07-07 15:20:47-04:00, stenn@whimsy.udel.edu Add the -H stuff for cc under HP-UX to sntp's configure.ac - sntp/configure.ac@1.11, 2006-07-07 15:20:21-04:00, stenn@whimsy.udel.edu +7 -0 + sntp/configure.ac@1.11 +7 -0 Add the -H stuff for cc under HP-UX to sntp's configure.ac -ChangeSet@1.1353.1.51, 2006-07-07 06:57:09-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.51, 2006-07-07 06:57:09-04:00, stenn@whimsy.udel.edu we want ltmain.sh now - BitKeeper/etc/ignore@1.53, 2006-07-07 06:56:13-04:00, stenn@whimsy.udel.edu +1 -1 + BitKeeper/etc/ignore@1.53 +1 -1 we want ltmain.sh now -ChangeSet@1.1353.1.50, 2006-07-07 05:53:15-04:00, stenn@whimsy.udel.edu +11 -0 +ChangeSet@1.1353.1.50, 2006-07-07 05:53:15-04:00, stenn@whimsy.udel.edu Make sure .def files are readable, distribute libtool.m4 and ltmain.sh to solve bootstrap problem - libopts/m4/libtool.m4@1.1, 2006-07-07 05:51:53-04:00, stenn@whimsy.udel.edu +6397 -0 + libopts/m4/libtool.m4@1.1 +6397 -0 BitKeeper file /deacon/backroom/ntp-dev/libopts/m4/libtool.m4 - libopts/m4/libtool.m4@1.0, 2006-07-07 05:51:53-04:00, stenn@whimsy.udel.edu +0 -0 + libopts/m4/libtool.m4@1.0 +0 -0 - ltmain.sh@1.1, 2006-07-07 05:51:57-04:00, stenn@whimsy.udel.edu +6863 -0 + ltmain.sh@1.1 +6863 -0 BitKeeper file /deacon/backroom/ntp-dev/ltmain.sh - ltmain.sh@1.0, 2006-07-07 05:51:57-04:00, stenn@whimsy.udel.edu +0 -0 + ltmain.sh@1.0 +0 -0 - ntpd/ntpd-opts.def@1.4, 2006-07-07 05:49:42-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpd-opts.def@1.4 +0 -0 Change mode to -rw-rw-r-- - ntpd/ntpdbase-opts.def@1.5, 2006-07-07 05:49:43-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdbase-opts.def@1.5 +0 -0 Change mode to -rw-rw-r-- - ntpd/ntpdsim-opts.def@1.4, 2006-07-07 05:49:44-04:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ntpdsim-opts.def@1.4 +0 -0 Change mode to -rw-rw-r-- - ntpdc/ntpdc-opts.def@1.10, 2006-07-07 05:49:45-04:00, stenn@whimsy.udel.edu +0 -0 + ntpdc/ntpdc-opts.def@1.10 +0 -0 Change mode to -rw-rw-r-- - ntpq/ntpq-opts.def@1.7, 2006-07-07 05:49:45-04:00, stenn@whimsy.udel.edu +0 -0 + ntpq/ntpq-opts.def@1.7 +0 -0 Change mode to -rw-rw-r-- - sntp/libopts/m4/libtool.m4@1.1, 2006-07-07 05:51:56-04:00, stenn@whimsy.udel.edu +6397 -0 + sntp/libopts/m4/libtool.m4@1.1 +6397 -0 BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/m4/libtool.m4 - sntp/libopts/m4/libtool.m4@1.0, 2006-07-07 05:51:56-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/libopts/m4/libtool.m4@1.0 +0 -0 - sntp/ltmain.sh@1.1, 2006-07-07 05:51:55-04:00, stenn@whimsy.udel.edu +6863 -0 + sntp/ltmain.sh@1.1 +6863 -0 BitKeeper file /deacon/backroom/ntp-dev/sntp/ltmain.sh - sntp/ltmain.sh@1.0, 2006-07-07 05:51:55-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/ltmain.sh@1.0 +0 -0 - sntp/sntp-opts.def@1.4, 2006-07-07 05:49:46-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp-opts.def@1.4 +0 -0 Change mode to -rw-rw-r-- - util/ntp-keygen-opts.def@1.4, 2006-07-07 05:49:47-04:00, stenn@whimsy.udel.edu +0 -0 + util/ntp-keygen-opts.def@1.4 +0 -0 Change mode to -rw-rw-r-- -ChangeSet@1.1353.1.49, 2006-07-03 21:51:08-04:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1353.1.49, 2006-07-03 21:51:08-04:00, stenn@deacon.udel.edu Make prototype agree with decl - libopts/autoopts/options.h@1.2, 2006-07-03 21:50:59-04:00, stenn@deacon.udel.edu +1 -1 + libopts/autoopts/options.h@1.2 +1 -1 Make prototype agree with decl - sntp/libopts/autoopts/options.h@1.2, 2006-07-03 21:50:59-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/autoopts/options.h@1.2 +1 -1 Make prototype agree with decl -ChangeSet@1.1353.1.48, 2006-07-03 19:05:18-04:00, stenn@deacon.udel.edu +58 -0 +ChangeSet@1.1353.1.48, 2006-07-03 19:05:18-04:00, stenn@deacon.udel.edu Upgrade to libopts-27.3.2 - libopts/Makefile.am@1.2, 2006-07-03 18:57:04-04:00, stenn@deacon.udel.edu +10 -10 + libopts/Makefile.am@1.2 +10 -10 Upgrade to libopts-27.3.2 - libopts/autoopts.c@1.2, 2006-07-03 18:57:04-04:00, stenn@deacon.udel.edu +9 -5 + libopts/autoopts.c@1.2 +9 -5 Upgrade to libopts-27.3.2 - libopts/autoopts.h@1.2, 2006-07-03 18:57:04-04:00, stenn@deacon.udel.edu +15 -7 + libopts/autoopts.h@1.2 +15 -7 Upgrade to libopts-27.3.2 - libopts/boolean.c@1.2, 2006-07-03 18:57:04-04:00, stenn@deacon.udel.edu +1 -1 + libopts/boolean.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - libopts/compat/compat.h@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +5 -2 + libopts/compat/compat.h@1.2 +5 -2 Upgrade to libopts-27.3.2 - libopts/compat/pathfind.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +2 -2 + libopts/compat/pathfind.c@1.2 +2 -2 Upgrade to libopts-27.3.2 - libopts/compat/strchr.c@1.1, 2006-07-03 18:55:11-04:00, stenn@deacon.udel.edu +61 -0 + libopts/compat/strchr.c@1.1 +61 -0 - libopts/compat/strchr.c@1.0, 2006-07-03 18:55:11-04:00, stenn@deacon.udel.edu +0 -0 + libopts/compat/strchr.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/libopts/compat/strchr.c - libopts/configfile.c@1.2, 2006-07-03 18:57:04-04:00, stenn@deacon.udel.edu +6 -6 + libopts/configfile.c@1.2 +6 -6 Upgrade to libopts-27.3.2 - libopts/cook.c@1.2, 2006-07-03 18:57:04-04:00, stenn@deacon.udel.edu +6 -6 + libopts/cook.c@1.2 +6 -6 Upgrade to libopts-27.3.2 - libopts/enumeration.c@1.2, 2006-07-03 18:57:04-04:00, stenn@deacon.udel.edu +8 -8 + libopts/enumeration.c@1.2 +8 -8 Upgrade to libopts-27.3.2 - libopts/environment.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +1 -1 + libopts/environment.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - libopts/libopts.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +1 -0 + libopts/libopts.c@1.2 +1 -0 Upgrade to libopts-27.3.2 - libopts/load.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +7 -7 + libopts/load.c@1.2 +7 -7 Upgrade to libopts-27.3.2 - libopts/m4/libopts.m4@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +6 -13 + libopts/m4/libopts.m4@1.2 +6 -13 Upgrade to libopts-27.3.2 - libopts/makeshell.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +10 -10 + libopts/makeshell.c@1.2 +10 -10 Upgrade to libopts-27.3.2 - libopts/nested.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +1 -1 + libopts/nested.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - libopts/numeric.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +1 -1 + libopts/numeric.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - libopts/pgusage.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +3 -3 + libopts/pgusage.c@1.2 +3 -3 Upgrade to libopts-27.3.2 - libopts/proto.h@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +2 -2 + libopts/proto.h@1.2 +2 -2 Upgrade to libopts-27.3.2 - libopts/putshell.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +8 -8 + libopts/putshell.c@1.2 +8 -8 Upgrade to libopts-27.3.2 - libopts/restore.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +1 -1 + libopts/restore.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - libopts/save.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +7 -7 + libopts/save.c@1.2 +7 -7 Upgrade to libopts-27.3.2 - libopts/sort.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +4 -4 + libopts/sort.c@1.2 +4 -4 Upgrade to libopts-27.3.2 - libopts/stack.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +41 -2 + libopts/stack.c@1.2 +41 -2 Upgrade to libopts-27.3.2 - libopts/streqvcmp.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +1 -1 + libopts/streqvcmp.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - libopts/text_mmap.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +3 -3 + libopts/text_mmap.c@1.2 +3 -3 Upgrade to libopts-27.3.2 - libopts/tokenize.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +3 -3 + libopts/tokenize.c@1.2 +3 -3 Upgrade to libopts-27.3.2 - libopts/usage.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +11 -11 + libopts/usage.c@1.2 +11 -11 Upgrade to libopts-27.3.2 - libopts/version.c@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +1 -1 + libopts/version.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - sntp/libopts/Makefile.am@1.2, 2006-07-03 18:57:05-04:00, stenn@deacon.udel.edu +10 -10 + sntp/libopts/Makefile.am@1.2 +10 -10 Upgrade to libopts-27.3.2 - sntp/libopts/autoopts.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +9 -5 + sntp/libopts/autoopts.c@1.2 +9 -5 Upgrade to libopts-27.3.2 - sntp/libopts/autoopts.h@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +15 -7 + sntp/libopts/autoopts.h@1.2 +15 -7 Upgrade to libopts-27.3.2 - sntp/libopts/boolean.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/boolean.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - sntp/libopts/compat/compat.h@1.2, 2006-07-03 18:57:07-04:00, stenn@deacon.udel.edu +5 -2 + sntp/libopts/compat/compat.h@1.2 +5 -2 Upgrade to libopts-27.3.2 - sntp/libopts/compat/pathfind.c@1.2, 2006-07-03 18:57:07-04:00, stenn@deacon.udel.edu +2 -2 + sntp/libopts/compat/pathfind.c@1.2 +2 -2 Upgrade to libopts-27.3.2 - sntp/libopts/compat/strchr.c@1.1, 2006-07-03 18:55:11-04:00, stenn@deacon.udel.edu +61 -0 + sntp/libopts/compat/strchr.c@1.1 +61 -0 - sntp/libopts/compat/strchr.c@1.0, 2006-07-03 18:55:11-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/compat/strchr.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/sntp/libopts/compat/strchr.c - sntp/libopts/configfile.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +6 -6 + sntp/libopts/configfile.c@1.2 +6 -6 Upgrade to libopts-27.3.2 - sntp/libopts/cook.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +6 -6 + sntp/libopts/cook.c@1.2 +6 -6 Upgrade to libopts-27.3.2 - sntp/libopts/enumeration.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +8 -8 + sntp/libopts/enumeration.c@1.2 +8 -8 Upgrade to libopts-27.3.2 - sntp/libopts/environment.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/environment.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - sntp/libopts/libopts.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +1 -0 + sntp/libopts/libopts.c@1.2 +1 -0 Upgrade to libopts-27.3.2 - sntp/libopts/load.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +7 -7 + sntp/libopts/load.c@1.2 +7 -7 Upgrade to libopts-27.3.2 - sntp/libopts/m4/libopts.m4@1.2, 2006-07-03 18:57:07-04:00, stenn@deacon.udel.edu +6 -13 + sntp/libopts/m4/libopts.m4@1.2 +6 -13 Upgrade to libopts-27.3.2 - sntp/libopts/makeshell.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +10 -10 + sntp/libopts/makeshell.c@1.2 +10 -10 Upgrade to libopts-27.3.2 - sntp/libopts/nested.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/nested.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - sntp/libopts/numeric.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/numeric.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - sntp/libopts/pgusage.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +3 -3 + sntp/libopts/pgusage.c@1.2 +3 -3 Upgrade to libopts-27.3.2 - sntp/libopts/proto.h@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +2 -2 + sntp/libopts/proto.h@1.2 +2 -2 Upgrade to libopts-27.3.2 - sntp/libopts/putshell.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +8 -8 + sntp/libopts/putshell.c@1.2 +8 -8 Upgrade to libopts-27.3.2 - sntp/libopts/restore.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/restore.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - sntp/libopts/save.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +7 -7 + sntp/libopts/save.c@1.2 +7 -7 Upgrade to libopts-27.3.2 - sntp/libopts/sort.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +4 -4 + sntp/libopts/sort.c@1.2 +4 -4 Upgrade to libopts-27.3.2 - sntp/libopts/stack.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +41 -2 + sntp/libopts/stack.c@1.2 +41 -2 Upgrade to libopts-27.3.2 - sntp/libopts/streqvcmp.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/streqvcmp.c@1.2 +1 -1 Upgrade to libopts-27.3.2 - sntp/libopts/text_mmap.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +3 -3 + sntp/libopts/text_mmap.c@1.2 +3 -3 Upgrade to libopts-27.3.2 - sntp/libopts/tokenize.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +3 -3 + sntp/libopts/tokenize.c@1.2 +3 -3 Upgrade to libopts-27.3.2 - sntp/libopts/usage.c@1.2, 2006-07-03 18:57:06-04:00, stenn@deacon.udel.edu +11 -11 + sntp/libopts/usage.c@1.2 +11 -11 Upgrade to libopts-27.3.2 - sntp/libopts/version.c@1.2, 2006-07-03 18:57:07-04:00, stenn@deacon.udel.edu +1 -1 + sntp/libopts/version.c@1.2 +1 -1 Upgrade to libopts-27.3.2 -ChangeSet@1.1353.1.47, 2006-07-03 00:18:29-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1353.1.47, 2006-07-03 00:18:29-04:00, stenn@deacon.udel.edu typo - bootstrap@1.15, 2006-07-03 00:16:31-04:00, stenn@whimsy.udel.edu +1 -1 + bootstrap@1.15, stenn@whimsy.udel.edu +1 -1 typo -ChangeSet@1.1353.1.46, 2006-07-03 00:13:59-04:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1353.1.46, 2006-07-03 00:13:59-04:00, stenn@deacon.udel.edu touch the files generated by autogen to keep them from needing to be rebuilt. - bootstrap@1.14, 2006-07-03 00:13:47-04:00, stenn@deacon.udel.edu +38 -14 + bootstrap@1.14 +38 -14 touch the files generated by autogen to keep them from needing to be rebuilt. - ntpd/ntp_proto.c@1.245, 2006-07-03 00:13:02-04:00, stenn@deacon.udel.edu +2 -2 + ntpd/ntp_proto.c@1.245 +2 -2 Dave reformatted a line -ChangeSet@1.1353.1.45, 2006-06-30 01:03:52-04:00, stenn@deacon.udel.edu +111 -0 +ChangeSet@1.1353.1.45, 2006-06-30 01:03:52-04:00, stenn@deacon.udel.edu Check in libopts and autgen-generated files - BitKeeper/etc/ignore@1.52, 2006-06-30 01:03:43-04:00, stenn@deacon.udel.edu +12 -12 + BitKeeper/etc/ignore@1.52 +12 -12 Check in libopts and autgen-generated files - bootstrap@1.13, 2006-06-30 01:03:43-04:00, stenn@deacon.udel.edu +19 -18 + bootstrap@1.13 +19 -18 Check in libopts and autgen-generated files - clockstuff/clktest-opts.c@1.1, 2006-06-30 00:58:06-04:00, stenn@deacon.udel.edu +825 -0 + clockstuff/clktest-opts.c@1.1 +825 -0 - clockstuff/clktest-opts.c@1.0, 2006-06-30 00:58:06-04:00, stenn@deacon.udel.edu +0 -0 + clockstuff/clktest-opts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/clockstuff/clktest-opts.c - clockstuff/clktest-opts.h@1.1, 2006-06-30 00:58:06-04:00, stenn@deacon.udel.edu +192 -0 + clockstuff/clktest-opts.h@1.1 +192 -0 - clockstuff/clktest-opts.h@1.0, 2006-06-30 00:58:06-04:00, stenn@deacon.udel.edu +0 -0 + clockstuff/clktest-opts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/clockstuff/clktest-opts.h - libopts/COPYING.lgpl@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +502 -0 + libopts/COPYING.lgpl@1.1 +502 -0 - libopts/COPYING.lgpl@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/COPYING.lgpl@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/COPYING.lgpl - libopts/COPYING.mbsd@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +26 -0 + libopts/COPYING.mbsd@1.1 +26 -0 - libopts/COPYING.mbsd@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/COPYING.mbsd@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/COPYING.mbsd - libopts/MakeDefs.inc@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/MakeDefs.inc@1.1 +0 -0 - libopts/MakeDefs.inc@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/MakeDefs.inc@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/MakeDefs.inc - libopts/Makefile.am@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +20 -0 + libopts/Makefile.am@1.1 +20 -0 - libopts/Makefile.am@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/Makefile.am@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/Makefile.am - libopts/README@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +93 -0 + libopts/README@1.1 +93 -0 - libopts/README@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/README@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/README - libopts/autoopts.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +1043 -0 + libopts/autoopts.c@1.1 +1043 -0 - libopts/autoopts.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/autoopts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/autoopts.c - libopts/autoopts.h@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +321 -0 + libopts/autoopts.h@1.1 +321 -0 - libopts/autoopts.h@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/autoopts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/autoopts.h - libopts/autoopts/options.h@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +908 -0 + libopts/autoopts/options.h@1.1 +908 -0 - libopts/autoopts/options.h@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/autoopts/options.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/autoopts/options.h - libopts/autoopts/usage-txt.h@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +479 -0 + libopts/autoopts/usage-txt.h@1.1 +479 -0 - libopts/autoopts/usage-txt.h@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/autoopts/usage-txt.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/autoopts/usage-txt.h - libopts/boolean.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +102 -0 + libopts/boolean.c@1.1 +102 -0 - libopts/boolean.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/boolean.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/boolean.c - libopts/compat/compat.h@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +292 -0 + libopts/compat/compat.h@1.1 +292 -0 - libopts/compat/compat.h@1.0, 2006-06-30 00:55:13-04:00, stenn@deacon.udel.edu +0 -0 + libopts/compat/compat.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/compat/compat.h - libopts/compat/pathfind.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +330 -0 + libopts/compat/pathfind.c@1.1 +330 -0 - libopts/compat/pathfind.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/compat/pathfind.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/compat/pathfind.c - libopts/compat/snprintf.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +36 -0 + libopts/compat/snprintf.c@1.1 +36 -0 - libopts/compat/snprintf.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/compat/snprintf.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/compat/snprintf.c - libopts/compat/strdup.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +19 -0 + libopts/compat/strdup.c@1.1 +19 -0 - libopts/compat/strdup.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/compat/strdup.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/compat/strdup.c - libopts/configfile.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +1277 -0 + libopts/configfile.c@1.1 +1277 -0 - libopts/configfile.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/configfile.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/configfile.c - libopts/cook.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +355 -0 + libopts/cook.c@1.1 +355 -0 - libopts/cook.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/cook.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/cook.c - libopts/enumeration.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +485 -0 + libopts/enumeration.c@1.1 +485 -0 - libopts/enumeration.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/enumeration.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/enumeration.c - libopts/environment.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +261 -0 + libopts/environment.c@1.1 +261 -0 - libopts/environment.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/environment.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/environment.c - libopts/genshell.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +301 -0 + libopts/genshell.c@1.1 +301 -0 - libopts/genshell.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/genshell.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/genshell.c - libopts/genshell.h@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +142 -0 + libopts/genshell.h@1.1 +142 -0 - libopts/genshell.h@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/genshell.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/genshell.h - libopts/libopts.c@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +30 -0 + libopts/libopts.c@1.1 +30 -0 - libopts/libopts.c@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/libopts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/libopts.c - libopts/load.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +520 -0 + libopts/load.c@1.1 +520 -0 - libopts/load.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/load.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/load.c - libopts/m4/libopts.m4@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +487 -0 + libopts/m4/libopts.m4@1.1 +487 -0 - libopts/m4/libopts.m4@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/m4/libopts.m4@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/m4/libopts.m4 - libopts/m4/liboptschk.m4@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +39 -0 + libopts/m4/liboptschk.m4@1.1 +39 -0 - libopts/m4/liboptschk.m4@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/m4/liboptschk.m4@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/m4/liboptschk.m4 - libopts/makeshell.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +1100 -0 + libopts/makeshell.c@1.1 +1100 -0 - libopts/makeshell.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/makeshell.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/makeshell.c - libopts/nested.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +705 -0 + libopts/nested.c@1.1 +705 -0 - libopts/nested.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/nested.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/nested.c - libopts/numeric.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +89 -0 + libopts/numeric.c@1.1 +89 -0 - libopts/numeric.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/numeric.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/numeric.c - libopts/pgusage.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +154 -0 + libopts/pgusage.c@1.1 +154 -0 - libopts/pgusage.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/pgusage.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/pgusage.c - libopts/proto.h@1.1, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +88 -0 + libopts/proto.h@1.1 +88 -0 - libopts/proto.h@1.0, 2006-06-30 00:55:14-04:00, stenn@deacon.udel.edu +0 -0 + libopts/proto.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/proto.h - libopts/putshell.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +333 -0 + libopts/putshell.c@1.1 +333 -0 - libopts/putshell.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/putshell.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/putshell.c - libopts/restore.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +207 -0 + libopts/restore.c@1.1 +207 -0 - libopts/restore.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/restore.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/restore.c - libopts/save.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +499 -0 + libopts/save.c@1.1 +499 -0 - libopts/save.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/save.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/save.c - libopts/sort.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +369 -0 + libopts/sort.c@1.1 +369 -0 - libopts/sort.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/sort.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/sort.c - libopts/stack.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +224 -0 + libopts/stack.c@1.1 +224 -0 - libopts/stack.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/stack.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/stack.c - libopts/streqvcmp.c@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +292 -0 + libopts/streqvcmp.c@1.1 +292 -0 - libopts/streqvcmp.c@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/streqvcmp.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/streqvcmp.c - libopts/text_mmap.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +367 -0 + libopts/text_mmap.c@1.1 +367 -0 - libopts/text_mmap.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/text_mmap.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/text_mmap.c - libopts/tokenize.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +322 -0 + libopts/tokenize.c@1.1 +322 -0 - libopts/tokenize.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/tokenize.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/tokenize.c - libopts/usage.c@1.1, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +732 -0 + libopts/usage.c@1.1 +732 -0 - libopts/usage.c@1.0, 2006-06-30 00:55:15-04:00, stenn@deacon.udel.edu +0 -0 + libopts/usage.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/usage.c - libopts/version.c@1.1, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +181 -0 + libopts/version.c@1.1 +181 -0 - libopts/version.c@1.0, 2006-06-30 00:55:16-04:00, stenn@deacon.udel.edu +0 -0 + libopts/version.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/libopts/version.c - ntpd/ntpd-opts.c@1.1, 2006-06-30 00:56:22-04:00, stenn@deacon.udel.edu +975 -0 + ntpd/ntpd-opts.c@1.1 +975 -0 - ntpd/ntpd-opts.c@1.0, 2006-06-30 00:56:22-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpd-opts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpd-opts.c - ntpd/ntpd-opts.h@1.1, 2006-06-30 00:56:22-04:00, stenn@deacon.udel.edu +193 -0 + ntpd/ntpd-opts.h@1.1 +193 -0 - ntpd/ntpd-opts.h@1.0, 2006-06-30 00:56:22-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpd-opts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpd-opts.h - ntpd/ntpd-opts.menu@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +1 -0 + ntpd/ntpd-opts.menu@1.1 +1 -0 - ntpd/ntpd-opts.menu@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpd-opts.menu@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpd-opts.menu - ntpd/ntpd-opts.texi@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +481 -0 + ntpd/ntpd-opts.texi@1.1 +481 -0 - ntpd/ntpd-opts.texi@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpd-opts.texi@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpd-opts.texi - ntpd/ntpd.1@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +307 -0 + ntpd/ntpd.1@1.1 +307 -0 - ntpd/ntpd.1@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpd.1@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpd.1 - ntpd/ntpdsim-opts.c@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +1173 -0 + ntpd/ntpdsim-opts.c@1.1 +1173 -0 - ntpd/ntpdsim-opts.c@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpdsim-opts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpdsim-opts.c - ntpd/ntpdsim-opts.h@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +211 -0 + ntpd/ntpdsim-opts.h@1.1 +211 -0 - ntpd/ntpdsim-opts.h@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpdsim-opts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpdsim-opts.h - ntpd/ntpdsim-opts.menu@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +1 -0 + ntpd/ntpdsim-opts.menu@1.1 +1 -0 - ntpd/ntpdsim-opts.menu@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpdsim-opts.menu@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpdsim-opts.menu - ntpd/ntpdsim-opts.texi@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +562 -0 + ntpd/ntpdsim-opts.texi@1.1 +562 -0 - ntpd/ntpdsim-opts.texi@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpdsim-opts.texi@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpdsim-opts.texi - ntpd/ntpdsim.1@1.1, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +352 -0 + ntpd/ntpdsim.1@1.1 +352 -0 - ntpd/ntpdsim.1@1.0, 2006-06-30 00:56:23-04:00, stenn@deacon.udel.edu +0 -0 + ntpd/ntpdsim.1@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpd/ntpdsim.1 - ntpdc/ntpdc-opts.c@1.1, 2006-06-30 00:56:35-04:00, stenn@deacon.udel.edu +606 -0 + ntpdc/ntpdc-opts.c@1.1 +606 -0 - ntpdc/ntpdc-opts.c@1.0, 2006-06-30 00:56:35-04:00, stenn@deacon.udel.edu +0 -0 + ntpdc/ntpdc-opts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpdc/ntpdc-opts.c - ntpdc/ntpdc-opts.h@1.1, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +155 -0 + ntpdc/ntpdc-opts.h@1.1 +155 -0 - ntpdc/ntpdc-opts.h@1.0, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +0 -0 + ntpdc/ntpdc-opts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpdc/ntpdc-opts.h - ntpdc/ntpdc-opts.menu@1.1, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +1 -0 + ntpdc/ntpdc-opts.menu@1.1 +1 -0 - ntpdc/ntpdc-opts.menu@1.0, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +0 -0 + ntpdc/ntpdc-opts.menu@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpdc/ntpdc-opts.menu - ntpdc/ntpdc-opts.texi@1.1, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +272 -0 + ntpdc/ntpdc-opts.texi@1.1 +272 -0 - ntpdc/ntpdc-opts.texi@1.0, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +0 -0 + ntpdc/ntpdc-opts.texi@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpdc/ntpdc-opts.texi - ntpdc/ntpdc.1@1.1, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +157 -0 + ntpdc/ntpdc.1@1.1 +157 -0 - ntpdc/ntpdc.1@1.0, 2006-06-30 00:56:36-04:00, stenn@deacon.udel.edu +0 -0 + ntpdc/ntpdc.1@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpdc/ntpdc.1 - ntpq/ntpq-opts.c@1.1, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +781 -0 + ntpq/ntpq-opts.c@1.1 +781 -0 - ntpq/ntpq-opts.c@1.0, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +0 -0 + ntpq/ntpq-opts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpq/ntpq-opts.c - ntpq/ntpq-opts.h@1.1, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +151 -0 + ntpq/ntpq-opts.h@1.1 +151 -0 - ntpq/ntpq-opts.h@1.0, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +0 -0 + ntpq/ntpq-opts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpq/ntpq-opts.h - ntpq/ntpq-opts.menu@1.1, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +1 -0 + ntpq/ntpq-opts.menu@1.1 +1 -0 - ntpq/ntpq-opts.menu@1.0, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +0 -0 + ntpq/ntpq-opts.menu@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpq/ntpq-opts.menu - ntpq/ntpq-opts.texi@1.1, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +691 -0 + ntpq/ntpq-opts.texi@1.1 +691 -0 - ntpq/ntpq-opts.texi@1.0, 2006-06-30 00:56:42-04:00, stenn@deacon.udel.edu +0 -0 + ntpq/ntpq-opts.texi@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpq/ntpq-opts.texi - ntpq/ntpq.1@1.1, 2006-06-30 00:56:43-04:00, stenn@deacon.udel.edu +385 -0 + ntpq/ntpq.1@1.1 +385 -0 - ntpq/ntpq.1@1.0, 2006-06-30 00:56:43-04:00, stenn@deacon.udel.edu +0 -0 + ntpq/ntpq.1@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/ntpq/ntpq.1 - sntp/libopts/COPYING.lgpl@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +502 -0 + sntp/libopts/COPYING.lgpl@1.1 +502 -0 - sntp/libopts/COPYING.lgpl@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/COPYING.lgpl@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/COPYING.lgpl - sntp/libopts/COPYING.mbsd@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +26 -0 + sntp/libopts/COPYING.mbsd@1.1 +26 -0 - sntp/libopts/COPYING.mbsd@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/COPYING.mbsd@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/COPYING.mbsd - sntp/libopts/MakeDefs.inc@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/MakeDefs.inc@1.1 +0 -0 - sntp/libopts/MakeDefs.inc@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/MakeDefs.inc@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/MakeDefs.inc - sntp/libopts/Makefile.am@1.1, 2006-06-30 01:00:05-04:00, stenn@deacon.udel.edu +20 -0 + sntp/libopts/Makefile.am@1.1 +20 -0 - sntp/libopts/Makefile.am@1.0, 2006-06-30 01:00:05-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/Makefile.am@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/Makefile.am - sntp/libopts/README@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +93 -0 + sntp/libopts/README@1.1 +93 -0 - sntp/libopts/README@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/README@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/README - sntp/libopts/autoopts.c@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +1043 -0 + sntp/libopts/autoopts.c@1.1 +1043 -0 - sntp/libopts/autoopts.c@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/autoopts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/autoopts.c - sntp/libopts/autoopts.h@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +321 -0 + sntp/libopts/autoopts.h@1.1 +321 -0 - sntp/libopts/autoopts.h@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/autoopts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/autoopts.h - sntp/libopts/autoopts/options.h@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +908 -0 + sntp/libopts/autoopts/options.h@1.1 +908 -0 - sntp/libopts/autoopts/options.h@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/autoopts/options.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/autoopts/options.h - sntp/libopts/autoopts/usage-txt.h@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +479 -0 + sntp/libopts/autoopts/usage-txt.h@1.1 +479 -0 - sntp/libopts/autoopts/usage-txt.h@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/autoopts/usage-txt.h - sntp/libopts/boolean.c@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +102 -0 + sntp/libopts/boolean.c@1.1 +102 -0 - sntp/libopts/boolean.c@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/boolean.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/boolean.c - sntp/libopts/compat/compat.h@1.1, 2006-06-30 01:00:01-04:00, stenn@deacon.udel.edu +292 -0 + sntp/libopts/compat/compat.h@1.1 +292 -0 - sntp/libopts/compat/compat.h@1.0, 2006-06-30 01:00:01-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/compat/compat.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/compat/compat.h - sntp/libopts/compat/pathfind.c@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +330 -0 + sntp/libopts/compat/pathfind.c@1.1 +330 -0 - sntp/libopts/compat/pathfind.c@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/compat/pathfind.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/compat/pathfind.c - sntp/libopts/compat/snprintf.c@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +36 -0 + sntp/libopts/compat/snprintf.c@1.1 +36 -0 - sntp/libopts/compat/snprintf.c@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/compat/snprintf.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/compat/snprintf.c - sntp/libopts/compat/strdup.c@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +19 -0 + sntp/libopts/compat/strdup.c@1.1 +19 -0 - sntp/libopts/compat/strdup.c@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/compat/strdup.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/compat/strdup.c - sntp/libopts/configfile.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +1277 -0 + sntp/libopts/configfile.c@1.1 +1277 -0 - sntp/libopts/configfile.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/configfile.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/configfile.c - sntp/libopts/cook.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +355 -0 + sntp/libopts/cook.c@1.1 +355 -0 - sntp/libopts/cook.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/cook.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/cook.c - sntp/libopts/enumeration.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +485 -0 + sntp/libopts/enumeration.c@1.1 +485 -0 - sntp/libopts/enumeration.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/enumeration.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/enumeration.c - sntp/libopts/environment.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +261 -0 + sntp/libopts/environment.c@1.1 +261 -0 - sntp/libopts/environment.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/environment.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/environment.c - sntp/libopts/genshell.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +301 -0 + sntp/libopts/genshell.c@1.1 +301 -0 - sntp/libopts/genshell.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/genshell.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/genshell.c - sntp/libopts/genshell.h@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +142 -0 + sntp/libopts/genshell.h@1.1 +142 -0 - sntp/libopts/genshell.h@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/genshell.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/genshell.h - sntp/libopts/libopts.c@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +30 -0 + sntp/libopts/libopts.c@1.1 +30 -0 - sntp/libopts/libopts.c@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/libopts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/libopts.c - sntp/libopts/load.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +520 -0 + sntp/libopts/load.c@1.1 +520 -0 - sntp/libopts/load.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/load.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/load.c - sntp/libopts/m4/libopts.m4@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +487 -0 + sntp/libopts/m4/libopts.m4@1.1 +487 -0 - sntp/libopts/m4/libopts.m4@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/m4/libopts.m4@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/m4/libopts.m4 - sntp/libopts/m4/liboptschk.m4@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +39 -0 + sntp/libopts/m4/liboptschk.m4@1.1 +39 -0 - sntp/libopts/m4/liboptschk.m4@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/m4/liboptschk.m4@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/m4/liboptschk.m4 - sntp/libopts/makeshell.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +1100 -0 + sntp/libopts/makeshell.c@1.1 +1100 -0 - sntp/libopts/makeshell.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/makeshell.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/makeshell.c - sntp/libopts/nested.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +705 -0 + sntp/libopts/nested.c@1.1 +705 -0 - sntp/libopts/nested.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/nested.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/nested.c - sntp/libopts/numeric.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +89 -0 + sntp/libopts/numeric.c@1.1 +89 -0 - sntp/libopts/numeric.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/numeric.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/numeric.c - sntp/libopts/pgusage.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +154 -0 + sntp/libopts/pgusage.c@1.1 +154 -0 - sntp/libopts/pgusage.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/pgusage.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/pgusage.c - sntp/libopts/proto.h@1.1, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +88 -0 + sntp/libopts/proto.h@1.1 +88 -0 - sntp/libopts/proto.h@1.0, 2006-06-30 01:00:02-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/proto.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/proto.h - sntp/libopts/putshell.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +333 -0 + sntp/libopts/putshell.c@1.1 +333 -0 - sntp/libopts/putshell.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/putshell.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/putshell.c - sntp/libopts/restore.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +207 -0 + sntp/libopts/restore.c@1.1 +207 -0 - sntp/libopts/restore.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/restore.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/restore.c - sntp/libopts/save.c@1.1, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +499 -0 + sntp/libopts/save.c@1.1 +499 -0 - sntp/libopts/save.c@1.0, 2006-06-30 01:00:03-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/save.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/save.c - sntp/libopts/sort.c@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +369 -0 + sntp/libopts/sort.c@1.1 +369 -0 - sntp/libopts/sort.c@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/sort.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/sort.c - sntp/libopts/stack.c@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +224 -0 + sntp/libopts/stack.c@1.1 +224 -0 - sntp/libopts/stack.c@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/stack.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/stack.c - sntp/libopts/streqvcmp.c@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +292 -0 + sntp/libopts/streqvcmp.c@1.1 +292 -0 - sntp/libopts/streqvcmp.c@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/streqvcmp.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/streqvcmp.c - sntp/libopts/text_mmap.c@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +367 -0 + sntp/libopts/text_mmap.c@1.1 +367 -0 - sntp/libopts/text_mmap.c@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/text_mmap.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/text_mmap.c - sntp/libopts/tokenize.c@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +322 -0 + sntp/libopts/tokenize.c@1.1 +322 -0 - sntp/libopts/tokenize.c@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/tokenize.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/tokenize.c - sntp/libopts/usage.c@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +732 -0 + sntp/libopts/usage.c@1.1 +732 -0 - sntp/libopts/usage.c@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/usage.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/usage.c - sntp/libopts/version.c@1.1, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +181 -0 + sntp/libopts/version.c@1.1 +181 -0 - sntp/libopts/version.c@1.0, 2006-06-30 01:00:04-04:00, stenn@deacon.udel.edu +0 -0 + sntp/libopts/version.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/libopts/version.c - sntp/sntp-opts.c@1.1, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +742 -0 + sntp/sntp-opts.c@1.1 +742 -0 - sntp/sntp-opts.c@1.0, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +0 -0 + sntp/sntp-opts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/sntp-opts.c - sntp/sntp-opts.h@1.1, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +149 -0 + sntp/sntp-opts.h@1.1 +149 -0 - sntp/sntp-opts.h@1.0, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +0 -0 + sntp/sntp-opts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/sntp-opts.h - sntp/sntp-opts.menu@1.1, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +1 -0 + sntp/sntp-opts.menu@1.1 +1 -0 - sntp/sntp-opts.menu@1.0, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +0 -0 + sntp/sntp-opts.menu@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/sntp-opts.menu - sntp/sntp-opts.texi@1.1, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +410 -0 + sntp/sntp-opts.texi@1.1 +410 -0 - sntp/sntp-opts.texi@1.0, 2006-06-30 01:02:22-04:00, stenn@deacon.udel.edu +0 -0 + sntp/sntp-opts.texi@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/sntp/sntp-opts.texi - util/ntp-keygen-opts.c@1.1, 2006-06-30 00:51:39-04:00, stenn@deacon.udel.edu +989 -0 + util/ntp-keygen-opts.c@1.1 +989 -0 - util/ntp-keygen-opts.c@1.0, 2006-06-30 00:51:39-04:00, stenn@deacon.udel.edu +0 -0 + util/ntp-keygen-opts.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/util/ntp-keygen-opts.c - util/ntp-keygen-opts.h@1.1, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +206 -0 + util/ntp-keygen-opts.h@1.1 +206 -0 - util/ntp-keygen-opts.h@1.0, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +0 -0 + util/ntp-keygen-opts.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/util/ntp-keygen-opts.h - util/ntp-keygen-opts.menu@1.1, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +1 -0 + util/ntp-keygen-opts.menu@1.1 +1 -0 - util/ntp-keygen-opts.menu@1.0, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +0 -0 + util/ntp-keygen-opts.menu@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/util/ntp-keygen-opts.menu - util/ntp-keygen-opts.texi@1.1, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +362 -0 + util/ntp-keygen-opts.texi@1.1 +362 -0 - util/ntp-keygen-opts.texi@1.0, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +0 -0 + util/ntp-keygen-opts.texi@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/util/ntp-keygen-opts.texi - util/ntp-keygen.1@1.1, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +176 -0 + util/ntp-keygen.1@1.1 +176 -0 - util/ntp-keygen.1@1.0, 2006-06-30 00:51:40-04:00, stenn@deacon.udel.edu +0 -0 + util/ntp-keygen.1@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/util/ntp-keygen.1 -ChangeSet@1.1353.1.44, 2006-06-28 07:26:01-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.44, 2006-06-28 07:26:01-04:00, stenn@whimsy.udel.edu NTP_4_2_3P13 TAG: NTP_4_2_3P13 - packageinfo.sh@1.6, 2006-06-28 07:25:51-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.6 +1 -1 NTP_4_2_3P13 -ChangeSet@1.1251.97.17, 2006-06-28 07:03:07-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.17, 2006-06-28 07:03:07-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC8 TAG: NTP_4_2_2P0_RC8 - packageinfo.sh@1.27.5.1, 2006-06-28 07:02:59-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.5.1 +1 -1 NTP_4_2_2P0_RC8 -ChangeSet@1.1251.97.16, 2006-06-27 21:20:21+00:00, burnicki@pogo.udel.edu +8 -0 +ChangeSet@1.1251.97.16, 2006-06-27 21:20:21+00:00, burnicki@pogo.udel.edu [BUG 661] Use environment variable to specify the base path to openssl. Updated hints/winnt.html accordingly. - html/build/hints/winnt.html@1.16, 2006-06-27 21:20:17+00:00, burnicki@pogo.udel.edu +42 -20 + html/build/hints/winnt.html@1.16 +42 -20 Added a hint to the build instructions to set up the OPENSSL environment variable. Added the Meinberg link to download the GUI installer. Wrapped some lines. - ports/winnt/libntp/libntp.dsp@1.29, 2006-06-27 21:20:17+00:00, burnicki@pogo.udel.edu +2 -2 + ports/winnt/libntp/libntp.dsp@1.29 +2 -2 Use environment variable to specify the base path to openssl. - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.10, 2006-06-27 21:20:17+00:00, burnicki@pogo.udel.edu +4 -4 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.10 +4 -4 Use environment variable to specify the base path to openssl. - ports/winnt/ntpd/ntpd.dsp@1.27, 2006-06-27 21:20:17+00:00, burnicki@pogo.udel.edu +4 -4 + ports/winnt/ntpd/ntpd.dsp@1.27 +4 -4 Use environment variable to specify the base path to openssl. - ports/winnt/ntpdate/ntpdate.dsp@1.15, 2006-06-27 21:20:18+00:00, burnicki@pogo.udel.edu +2 -2 + ports/winnt/ntpdate/ntpdate.dsp@1.15 +2 -2 Use environment variable to specify the base path to openssl. - ports/winnt/ntpdc/ntpdc.dsp@1.17, 2006-06-27 21:20:18+00:00, burnicki@pogo.udel.edu +2 -2 + ports/winnt/ntpdc/ntpdc.dsp@1.17 +2 -2 Use environment variable to specify the base path to openssl. - ports/winnt/ntpq/ntpq.dsp@1.18, 2006-06-27 21:20:18+00:00, burnicki@pogo.udel.edu +2 -2 + ports/winnt/ntpq/ntpq.dsp@1.18 +2 -2 Use environment variable to specify the base path to openssl. - ports/winnt/ntptrace/ntptrace.dsp@1.10, 2006-06-27 21:20:18+00:00, burnicki@pogo.udel.edu +2 -2 + ports/winnt/ntptrace/ntptrace.dsp@1.10 +2 -2 Use environment variable to specify the base path to openssl. -ChangeSet@1.1353.1.42, 2006-06-27 07:48:03-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.42, 2006-06-27 07:48:03-04:00, stenn@whimsy.udel.edu NTP_4_2_3P12 TAG: NTP_4_2_3P12 - packageinfo.sh@1.5, 2006-06-27 07:47:53-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.5 +1 -1 NTP_4_2_3P12 -ChangeSet@1.1251.97.15, 2006-06-27 07:02:41-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.15, 2006-06-27 07:02:41-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC7 TAG: NTP_4_2_2P0_RC7 - packageinfo.sh@1.27.4.1, 2006-06-27 07:02:33-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.4.1 +1 -1 NTP_4_2_2P0_RC7 -ChangeSet@1.1251.97.14, 2006-06-27 04:19:41-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.97.14, 2006-06-27 04:19:41-04:00, stenn@whimsy.udel.edu Resolve the ambiguity in the copyright file - NEWS@1.50.1.1, 2006-06-27 04:19:13-04:00, stenn@whimsy.udel.edu +2 -0 + NEWS@1.50.1.1 +2 -0 Resolve the ambiguity in the copyright file - html/copyright.html@1.33.1.1, 2006-06-27 04:19:12-04:00, stenn@whimsy.udel.edu +4 -4 + html/copyright.html@1.33.1.1 +4 -4 Resolve the ambiguity in the copyright file -ChangeSet@1.1353.1.40, 2006-06-26 07:50:16-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.40, 2006-06-26 07:50:16-04:00, stenn@whimsy.udel.edu NTP_4_2_3P11 TAG: NTP_4_2_3P11 - packageinfo.sh@1.4, 2006-06-26 07:50:07-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.4 +1 -1 NTP_4_2_3P11 -ChangeSet@1.1251.97.13, 2006-06-26 07:03:11-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.13, 2006-06-26 07:03:11-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC6 TAG: NTP_4_2_2P0_RC6 - packageinfo.sh@1.27.3.1, 2006-06-26 07:03:02-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.3.1 +1 -1 NTP_4_2_2P0_RC6 -ChangeSet@1.1251.97.12, 2006-06-26 03:23:59-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.97.12, 2006-06-26 03:23:59-04:00, stenn@whimsy.udel.edu Documentation updated from Dave Mills - html/ntpdsim.html@1.5, 2006-06-26 03:23:33-04:00, stenn@whimsy.udel.edu +3 -3 + html/ntpdsim.html@1.5 +3 -3 Documentation updated from Dave Mills - html/scripts/links7.txt@1.2, 2006-06-26 03:23:34-04:00, stenn@whimsy.udel.edu +1 -0 + html/scripts/links7.txt@1.2 +1 -0 Documentation updated from Dave Mills - html/scripts/links9.txt@1.3, 2006-06-26 03:23:34-04:00, stenn@whimsy.udel.edu +1 -0 + html/scripts/links9.txt@1.3 +1 -0 Documentation updated from Dave Mills -ChangeSet@1.1251.97.11, 2006-06-26 03:06:50-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.97.11, 2006-06-26 03:06:50-04:00, stenn@whimsy.udel.edu New documentation files from Dave Mills - html/groups.html@1.1, 2006-06-26 03:06:10-04:00, stenn@whimsy.udel.edu +47 -0 + html/groups.html@1.1 +47 -0 - html/groups.html@1.0, 2006-06-26 03:06:10-04:00, stenn@whimsy.udel.edu +0 -0 + html/groups.html@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-stable/html/groups.html - html/ntp_conf.html@1.1, 2006-06-26 03:06:11-04:00, stenn@whimsy.udel.edu +173 -0 + html/ntp_conf.html@1.1 +173 -0 - html/ntp_conf.html@1.0, 2006-06-26 03:06:11-04:00, stenn@whimsy.udel.edu +0 -0 + html/ntp_conf.html@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-stable/html/ntp_conf.html - html/ntpdsim_new.html@1.1, 2006-06-26 03:06:11-04:00, stenn@whimsy.udel.edu +102 -0 + html/ntpdsim_new.html@1.1 +102 -0 - html/ntpdsim_new.html@1.0, 2006-06-26 03:06:11-04:00, stenn@whimsy.udel.edu +0 -0 + html/ntpdsim_new.html@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-stable/html/ntpdsim_new.html -ChangeSet@1.1251.97.10, 2006-06-26 02:52:54-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.10, 2006-06-26 02:52:54-04:00, stenn@whimsy.udel.edu Fix the ntp-keygen URL (Dave Mills) in authopt.html - html/authopt.html@1.40, 2006-06-26 02:52:07-04:00, stenn@whimsy.udel.edu +2 -2 + html/authopt.html@1.40 +2 -2 Fix the ntp-keygen URL (Dave Mills) in authopt.html -ChangeSet@1.1353.1.36, 2006-06-26 01:10:19-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.36, 2006-06-26 01:10:19-04:00, stenn@whimsy.udel.edu setsockopt() notes - ntpd/ntp_io.c@1.227, 2006-06-26 01:09:11-04:00, stenn@whimsy.udel.edu +3 -2 + ntpd/ntp_io.c@1.227 +3 -2 setsockopt() notes -ChangeSet@1.1353.1.35, 2006-06-26 00:51:09-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.35, 2006-06-26 00:51:09-04:00, stenn@whimsy.udel.edu [Bug 658] hppa2.0-hp-hpux10.20 cc needs a bigger -H for cpp - configure.ac@1.387, 2006-06-26 00:49:24-04:00, stenn@whimsy.udel.edu +8 -0 + configure.ac@1.387 +8 -0 [Bug 658] hppa2.0-hp-hpux10.20 cc needs a bigger -H for cpp -ChangeSet@1.1353.1.34, 2006-06-25 19:52:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.34, 2006-06-25 19:52:52-04:00, stenn@whimsy.udel.edu cleanup - sntp/Makefile.am@1.14, 2006-06-25 19:52:28-04:00, stenn@whimsy.udel.edu +2 -3 + sntp/Makefile.am@1.14 +2 -3 cleanup -ChangeSet@1.1251.97.9, 2006-06-25 19:10:06-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.9, 2006-06-25 19:10:06-04:00, stenn@whimsy.udel.edu [Bug 657]: IP_MULTICAST_LOOP uses a u_char value/size - ntpd/ntp_io.c@1.187.1.18, 2006-06-25 19:09:44-04:00, stenn@whimsy.udel.edu +5 -5 + ntpd/ntp_io.c@1.187.1.18 +5 -5 [Bug 657]: IP_MULTICAST_LOOP uses a u_char value/size -ChangeSet@1.1251.97.8, 2006-06-25 17:00:47-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.97.8, 2006-06-25 17:00:47-04:00, stenn@whimsy.udel.edu distcheck fixes - BitKeeper/etc/ignore@1.35.1.2, 2006-06-25 16:56:53-04:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/etc/ignore@1.35.1.2 +1 -0 added sntp/bincheck.mf - Makefile.am@1.48.1.5, 2006-06-25 16:58:56-04:00, stenn@whimsy.udel.edu +1 -0 + Makefile.am@1.48.1.5 +1 -0 cleanup; distcheck now works from sntp - bootstrap@1.4.3.1, 2006-06-25 16:59:01-04:00, stenn@whimsy.udel.edu +2 -0 + bootstrap@1.4.3.1 +2 -0 cleanup; distcheck now works from sntp - sntp/Makefile.am@1.6.1.1, 2006-06-25 16:58:07-04:00, stenn@whimsy.udel.edu +5 -23 + sntp/Makefile.am@1.6.1.1 +5 -23 cleanup; distcheck now works from sntp -ChangeSet@1.1353.1.31, 2006-06-25 07:51:20-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.31, 2006-06-25 07:51:20-04:00, stenn@whimsy.udel.edu NTP_4_2_3P10 TAG: NTP_4_2_3P10 - packageinfo.sh@1.3, 2006-06-25 07:51:10-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.3 +1 -1 NTP_4_2_3P10 -ChangeSet@1.1251.97.7, 2006-06-25 07:03:22-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.7, 2006-06-25 07:03:22-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC5 TAG: NTP_4_2_2P0_RC5 - packageinfo.sh@1.27.2.1, 2006-06-25 07:03:11-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.2.1 +1 -1 NTP_4_2_2P0_RC5 -ChangeSet@1.1353.1.30, 2006-06-25 04:50:29-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.30, 2006-06-25 04:50:29-04:00, stenn@whimsy.udel.edu Bail on an autogen error - bootstrap@1.11, 2006-06-25 04:50:01-04:00, stenn@whimsy.udel.edu +2 -1 + bootstrap@1.11 +2 -1 Bail on an autogen error -ChangeSet@1.1353.1.28, 2006-06-24 18:12:20-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1353.1.28, 2006-06-24 18:12:20-04:00, stenn@deacon.udel.edu fix quoting - BitKeeper/triggers/pre-resolve.licfix@1.2, 2006-06-24 18:11:52-04:00, stenn@deacon.udel.edu +1 -1 + BitKeeper/triggers/pre-resolve.licfix@1.2 +1 -1 fix quoting -ChangeSet@1.1251.98.4, 2006-06-24 18:45:02+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.98.4, 2006-06-24 18:45:02+00:00, kardel@pogo.udel.edu ntpq_ops.c: fix a type punned pointer issue reported by gcc 4 - ntpq/ntpq_ops.c@1.20.3.1, 2006-06-24 18:44:18+00:00, kardel@pogo.udel.edu +6 -6 + ntpq/ntpq_ops.c@1.20.3.1 +6 -6 fix a type punned pointer issue reported by gcc 4 -ChangeSet@1.1251.98.3, 2006-06-24 18:31:47+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.98.3, 2006-06-24 18:31:47+00:00, kardel@pogo.udel.edu refclock_shm.c: fix gcc 4 uninitialized warning - ntpd/refclock_shm.c@1.17, 2006-06-24 18:31:01+00:00, kardel@pogo.udel.edu +4 -0 + ntpd/refclock_shm.c@1.17 +4 -0 fix gcc 4 uninitialized warning -ChangeSet@1.1251.98.2, 2006-06-24 18:24:35+00:00, kardel@pogo.udel.edu +4 -0 +ChangeSet@1.1251.98.2, 2006-06-24 18:24:35+00:00, kardel@pogo.udel.edu data_mbg.c, refclock_parse.c, mbg_gps166.h, clk_rawdcf.c: fix gcc 4 signedness complaints - include/mbg_gps166.h@1.5.1.2, 2006-06-24 18:24:02+00:00, kardel@pogo.udel.edu +7 -4 + include/mbg_gps166.h@1.5.1.2 +7 -4 fix gcc 4 signedness complaints - libparse/clk_rawdcf.c@1.14, 2006-06-24 18:24:08+00:00, kardel@pogo.udel.edu +10 -4 + libparse/clk_rawdcf.c@1.14 +10 -4 fix gcc 4 signedness complaints - libparse/data_mbg.c@1.5.1.2, 2006-06-24 18:24:08+00:00, kardel@pogo.udel.edu +17 -14 + libparse/data_mbg.c@1.5.1.2 +17 -14 fix gcc 4 signedness complaints - ntpd/refclock_parse.c@1.35.1.14, 2006-06-24 18:24:11+00:00, kardel@pogo.udel.edu +14 -7 + ntpd/refclock_parse.c@1.35.1.14 +14 -7 fix gcc 4 signedness complaints -ChangeSet@1.1251.98.1, 2006-06-24 17:39:54+00:00, kardel@pogo.udel.edu +4 -0 +ChangeSet@1.1251.98.1, 2006-06-24 17:39:54+00:00, kardel@pogo.udel.edu refclock_acts.c: NetBSD Coverity CID 3797: bad return code check for open(2) fixed (!fd replaced with fd < 0) @@ -13868,314 +194635,314 @@ ChangeSet@1.1251.98.1, 2006-06-24 17:39:54+00:00, kardel@pogo.udel.edu +4 -0 ntpq.c: NetBSD Coverity CID 3799: overrun static array (off by one) fixed - ntpd/ntp_util.c@1.36.2.2, 2006-06-24 17:23:41+00:00, kardel@pogo.udel.edu +1 -0 + ntpd/ntp_util.c@1.36.2.2 +1 -0 NetBSD Coverity CID 3804: avoid file pointer leak - ntpd/refclock_acts.c@1.25.1.2, 2006-06-24 17:29:57+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/refclock_acts.c@1.25.1.2 +1 -1 NetBSD Coverity CID 3797: bad return code check for open(2) fixed (!fd replaced with fd < 0) - ntpd/refclock_parse.c@1.35.1.13, 2006-06-24 17:38:43+00:00, kardel@pogo.udel.edu +5 -1 + ntpd/refclock_parse.c@1.35.1.13 +5 -1 NetBSD Coverity CID 3796: possible NULL deref - ntpq/ntpq.c@1.55.1.6, 2006-06-24 17:26:57+00:00, kardel@pogo.udel.edu +1 -1 + ntpq/ntpq.c@1.55.1.6 +1 -1 NetBSD Coverity CID 3799: overrun static array (off by one) fixed -ChangeSet@1.1353.1.26, 2006-06-24 16:50:45+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1353.1.26, 2006-06-24 16:50:45+00:00, kardel@pogo.udel.edu ntp_io.c: implement fix for bug 614 socket fds will be moved out of the stdio reserved area if at all possible - ntpd/ntp_io.c@1.224, 2006-06-24 16:48:27+00:00, kardel@pogo.udel.edu +106 -27 + ntpd/ntp_io.c@1.224 +106 -27 implement fix for bug 614 socket fds will be moved out of the stdio reserved area if at all possible -ChangeSet@1.1251.97.5, 2006-06-24 16:46:25+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.97.5, 2006-06-24 16:46:25+00:00, kardel@pogo.udel.edu ntp_io.c: implement fix for bug 614 socket fds will be moved out of the stdio reserved space if at all possible - ntpd/ntp_io.c@1.187.1.17, 2006-06-24 16:44:08+00:00, kardel@pogo.udel.edu +107 -27 + ntpd/ntp_io.c@1.187.1.17 +107 -27 implement fix for bug 614 socket fds will be moved out of the stdio reserved space if at all possible -ChangeSet@1.1353.1.25, 2006-06-23 07:48:33-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.25, 2006-06-23 07:48:33-04:00, stenn@whimsy.udel.edu NTP_4_2_3P9 TAG: NTP_4_2_3P9 - packageinfo.sh@1.2, 2006-06-23 07:48:22-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.2 +1 -1 NTP_4_2_3P9 -ChangeSet@1.1251.97.4, 2006-06-23 07:02:47-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.4, 2006-06-23 07:02:47-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC4 TAG: NTP_4_2_2P0_RC4 - packageinfo.sh@1.27.1.9, 2006-06-23 07:02:37-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.1.9 +1 -1 NTP_4_2_2P0_RC4 -ChangeSet@1.1251.97.3, 2006-06-22 17:07:33-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.3, 2006-06-22 17:07:33-04:00, stenn@whimsy.udel.edu Remove the license: key from etc/config to make the bk4 upgrade easier. - BitKeeper/etc/config@1.7.1.1, 2006-06-22 17:07:13-04:00, stenn@whimsy.udel.edu +2 -1 + BitKeeper/etc/config@1.7.1.1 +2 -1 Remove the license: key from etc/config to make the bk4 upgrade easier. -ChangeSet@1.1353.1.23, 2006-06-22 16:17:02-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.1.23, 2006-06-22 16:17:02-04:00, stenn@whimsy.udel.edu break the link between -stable and -dev copies of packageinfo.sh - BitKeeper/deleted/.del-packageinfo.sh~7f44215e99c0cd03@1.47, 2006-06-22 16:15:09-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-packageinfo.sh~7f44215e99c0cd03@1.47 +0 -0 Delete: packageinfo.sh - packageinfo.sh@1.1, 2006-06-22 16:15:29-04:00, stenn@whimsy.udel.edu +26 -0 + packageinfo.sh@1.1 +26 -0 - packageinfo.sh@1.0, 2006-06-22 16:15:29-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-632/packageinfo.sh -ChangeSet@1.1251.97.2, 2006-06-22 19:28:28+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.97.2, 2006-06-22 19:28:28+00:00, kardel@pogo.udel.edu refclock_parse.c: bug 632: update kernel PPS offsets when PPS offset is re-configured - ntpd/refclock_parse.c@1.35.1.12, 2006-06-22 19:26:08+00:00, kardel@pogo.udel.edu +10 -4 + ntpd/refclock_parse.c@1.35.1.12 +10 -4 bug 632: update kernel PPS offsets when PPS offset is re-configured -ChangeSet@1.1353.1.22, 2006-06-22 07:03:29-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.22, 2006-06-22 07:03:29-04:00, stenn@whimsy.udel.edu NTP_4_2_3P8 TAG: NTP_4_2_3P8 - packageinfo.sh@1.46, 2006-06-22 07:03:18-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.46 +1 -1 NTP_4_2_3P8 -ChangeSet@1.1353.1.21, 2006-06-22 00:29:56-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.21, 2006-06-22 00:29:56-04:00, stenn@whimsy.udel.edu cmd_args.c cleanup - ntpd/cmd_args.c@1.41, 2006-06-22 00:29:20-04:00, stenn@whimsy.udel.edu +3 -153 + ntpd/cmd_args.c@1.41 +3 -153 cleanup -ChangeSet@1.1353.1.20, 2006-06-21 07:03:02-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.20, 2006-06-21 07:03:02-04:00, stenn@whimsy.udel.edu NTP_4_2_3P7 TAG: NTP_4_2_3P7 - packageinfo.sh@1.45, 2006-06-21 07:02:55-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.45 +1 -1 NTP_4_2_3P7 -ChangeSet@1.1353.1.19, 2006-06-21 06:17:57-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.19, 2006-06-21 06:17:57-04:00, stenn@whimsy.udel.edu OSF4 does not have RTM_{NEW,DEL}ADDR - ntpd/ntp_io.c@1.223, 2006-06-21 06:17:28-04:00, stenn@whimsy.udel.edu +4 -0 + ntpd/ntp_io.c@1.223 +4 -0 OSF4 does not have RTM_{NEW,DEL}ADDR -ChangeSet@1.1353.1.18, 2006-06-21 03:52:10-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.18, 2006-06-21 03:52:10-04:00, stenn@whimsy.udel.edu Use a pointer to feed the options to optionUsage() to avoid a struct copy - ntpd/cmd_args.c@1.40, 2006-06-21 03:51:43-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/cmd_args.c@1.40 +4 -4 Use a pointer to feed the options to optionUsage() to avoid a struct copy -ChangeSet@1.1353.1.17, 2006-06-20 17:42:13-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1353.1.17, 2006-06-20 17:42:13-04:00, stenn@whimsy.udel.edu Protect COMMAND since we use it as an autogen keyword - ntpdc/ntpdc.c@1.52, 2006-06-20 17:40:31-04:00, stenn@whimsy.udel.edu +9 -4 + ntpdc/ntpdc.c@1.52 +9 -4 Protect COMMAND since we use it as an autogen keyword - ntpq/ntpq.c@1.63, 2006-06-20 17:40:30-04:00, stenn@whimsy.udel.edu +10 -5 + ntpq/ntpq.c@1.63 +10 -5 Protect COMMAND since we use it as an autogen keyword -ChangeSet@1.1353.1.16, 2006-06-20 07:03:15-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.16, 2006-06-20 07:03:15-04:00, stenn@whimsy.udel.edu NTP_4_2_3P6 TAG: NTP_4_2_3P6 - packageinfo.sh@1.44, 2006-06-20 07:03:04-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.44 +1 -1 NTP_4_2_3P6 -ChangeSet@1.1353.1.14, 2006-06-20 03:15:38-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.14, 2006-06-20 03:15:38-04:00, stenn@whimsy.udel.edu Fix the configure.ac check for rt_msghdr - configure.ac@1.386, 2006-06-20 03:15:13-04:00, stenn@whimsy.udel.edu +2 -3 + configure.ac@1.386 +2 -3 Fix the configure.ac check for rt_msghdr -ChangeSet@1.1353.1.13, 2006-06-19 07:24:31-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.13, 2006-06-19 07:24:31-04:00, stenn@whimsy.udel.edu NTP_4_2_3P5 TAG: NTP_4_2_3P5 - packageinfo.sh@1.42, 2006-06-19 07:24:21-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.42 +1 -1 NTP_4_2_3P5 -ChangeSet@1.1251.97.1, 2006-06-19 07:02:56-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.97.1, 2006-06-19 07:02:56-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC3 TAG: NTP_4_2_2P0_RC3 - packageinfo.sh@1.27.1.8, 2006-06-19 07:02:45-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.1.8 +1 -1 NTP_4_2_2P0_RC3 -ChangeSet@1.1353.1.12, 2006-06-19 04:16:30-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.12, 2006-06-19 04:16:30-04:00, stenn@whimsy.udel.edu Update the NEWS file for the dynamic interface scan fix - NEWS@1.52, 2006-06-19 04:15:56-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.52 +1 -0 Update the NEWS file for the dynamic interface scan fix -ChangeSet@1.1251.96.1, 2006-06-19 02:31:54-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.96.1, 2006-06-19 02:31:54-04:00, stenn@pogo.udel.edu Avoid hardcoded path to bash for the bootstrap script - bootstrap@1.4.2.1, 2006-06-19 02:31:43-04:00, stenn@pogo.udel.edu +1 -1 + bootstrap@1.4.2.1 +1 -1 Avoid hardcoded path to bash for the bootstrap script -ChangeSet@1.1353.3.8, 2006-06-18 20:14:55-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1353.3.8, 2006-06-18 20:14:55-04:00, stenn@deacon.udel.edu Bash might not be in /bin/bash (for bootstrap) - bootstrap@1.9, 2006-06-18 20:14:47-04:00, stenn@deacon.udel.edu +9 -6 + bootstrap@1.9 +9 -6 Bash might not be in /bin/bash (for bootstrap) -ChangeSet@1.1353.3.7, 2006-06-18 20:12:51-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1353.3.7, 2006-06-18 20:12:51-04:00, stenn@deacon.udel.edu ignore: added libopts/* - BitKeeper/etc/ignore@1.50, 2006-06-18 20:12:06-04:00, stenn@deacon.udel.edu +1 -0 + BitKeeper/etc/ignore@1.50 +1 -0 added libopts/* -ChangeSet@1.1251.94.19, 2006-06-18 20:09:27-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.94.19, 2006-06-18 20:09:27-04:00, stenn@deacon.udel.edu bash (for the bootstrap script) might not be /bin/bash - bootstrap@1.4.1.1, 2006-06-18 20:09:18-04:00, stenn@deacon.udel.edu +1 -1 + bootstrap@1.4.1.1 +1 -1 bash (for the bootstrap script) might not be /bin/bash -ChangeSet@1.1353.1.9, 2006-06-18 22:18:50+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1353.1.9, 2006-06-18 22:18:50+00:00, kardel@pogo.udel.edu ntp_io.c: import fix for bug 637 - ntpd/ntp_io.c@1.221, 2006-06-18 22:18:19+00:00, kardel@pogo.udel.edu +22 -9 + ntpd/ntp_io.c@1.221 +22 -9 import fix for bug 637 -ChangeSet@1.1353.3.6, 2006-06-18 07:24:11-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.3.6, 2006-06-18 07:24:11-04:00, stenn@whimsy.udel.edu NTP_4_2_3P4 TAG: NTP_4_2_3P4 - packageinfo.sh@1.40, 2006-06-18 07:24:01-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.40 +1 -1 NTP_4_2_3P4 -ChangeSet@1.1251.94.18, 2006-06-18 07:03:14-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.18, 2006-06-18 07:03:14-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC2 TAG: NTP_4_2_2P0_RC2 - packageinfo.sh@1.27.1.7, 2006-06-18 07:03:05-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.1.7 +1 -1 NTP_4_2_2P0_RC2 -ChangeSet@1.1353.3.5, 2006-06-18 02:18:46-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.3.5, 2006-06-18 02:18:46-04:00, stenn@whimsy.udel.edu The fix for bug 637 needs work for ntp-dev - ntpd/ntp_io.c@1.218.1.1, 2006-06-18 02:18:15-04:00, stenn@whimsy.udel.edu +2 -0 + ntpd/ntp_io.c@1.218.1.1 +2 -0 The fix for bug 637 needs work for ntp-dev -ChangeSet@1.1353.3.4, 2006-06-18 02:14:55-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.3.4, 2006-06-18 02:14:55-04:00, stenn@whimsy.udel.edu ntp-dev uses repotype=dev - packageinfo.sh@1.39, 2006-06-18 02:14:34-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.39 +2 -2 ntp-dev uses repotype=dev -ChangeSet@1.1251.94.17, 2006-06-18 02:05:42-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.17, 2006-06-18 02:05:42-04:00, stenn@whimsy.udel.edu Make the license check triggers work with bk3 and bk4 - BitKeeper/triggers/post-incoming.license-warn@1.6, 2006-06-18 02:05:11-04:00, stenn@whimsy.udel.edu +9 -3 + BitKeeper/triggers/post-incoming.license-warn@1.6 +9 -3 Make the license check triggers work with bk3 and bk4 - BitKeeper/triggers/pre-resolve.license-chk@1.5.1.2, 2006-06-18 02:05:12-04:00, stenn@whimsy.udel.edu +10 -4 + BitKeeper/triggers/pre-resolve.license-chk@1.5.1.2 +10 -4 Make the license check triggers work with bk3 and bk4 -ChangeSet@1.1251.94.15, 2006-06-17 22:47:38-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.15, 2006-06-17 22:47:38-04:00, stenn@whimsy.udel.edu debug - BitKeeper/triggers/post-incoming.license-warn@1.5, 2006-06-17 22:47:19-04:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/triggers/post-incoming.license-warn@1.5 +1 -0 debug - BitKeeper/triggers/pre-resolve.license-chk@1.5.1.1, 2006-06-17 22:47:19-04:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/triggers/pre-resolve.license-chk@1.5.1.1 +1 -0 debug -ChangeSet@1.1353.3.1, 2006-06-17 22:32:24-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.3.1, 2006-06-17 22:32:24-04:00, stenn@whimsy.udel.edu typo - BitKeeper/triggers/pre-resolve.license-chk@1.3.1.1, 2006-06-17 22:31:40-04:00, stenn@whimsy.udel.edu +0 -1 + BitKeeper/triggers/pre-resolve.license-chk@1.3.1.1 +0 -1 typo -ChangeSet@1.1251.94.14, 2006-06-17 22:05:18-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.14, 2006-06-17 22:05:18-04:00, stenn@whimsy.udel.edu typo - BitKeeper/triggers/pre-resolve.license-chk@1.5, 2006-06-17 22:04:50-04:00, stenn@whimsy.udel.edu +0 -1 + BitKeeper/triggers/pre-resolve.license-chk@1.5 +0 -1 typo -ChangeSet@1.1353.1.7, 2006-06-18 00:01:22+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1353.1.7, 2006-06-18 00:01:22+00:00, kardel@pogo.udel.edu ntp_io.c: skip interfaces that cannot be bound to - ntpd/ntp_io.c@1.219, 2006-06-17 23:59:09+00:00, kardel@pogo.udel.edu +1 -0 + ntpd/ntp_io.c@1.219 +1 -0 skip interfaces that cannot be bound to -ChangeSet@1.1251.94.13, 2006-06-17 19:57:47-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.13, 2006-06-17 19:57:47-04:00, stenn@whimsy.udel.edu More bk-4 license check trigger cleanup - BitKeeper/triggers/post-incoming.license-warn@1.4, 2006-06-17 19:57:29-04:00, stenn@whimsy.udel.edu +2 -0 + BitKeeper/triggers/post-incoming.license-warn@1.4 +2 -0 More bk-4 license check trigger cleanup - BitKeeper/triggers/pre-resolve.license-chk@1.4, 2006-06-17 19:57:29-04:00, stenn@whimsy.udel.edu +2 -0 + BitKeeper/triggers/pre-resolve.license-chk@1.4 +2 -0 More bk-4 license check trigger cleanup -ChangeSet@1.1251.95.1, 2006-06-17 23:09:55+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.95.1, 2006-06-17 23:09:55+00:00, kardel@pogo.udel.edu ntp_io.c: move decision into seperate function and insure compilability on non IPv6 platforms - ntpd/ntp_io.c@1.187.1.16, 2006-06-17 23:08:26+00:00, kardel@pogo.udel.edu +24 -8 + ntpd/ntp_io.c@1.187.1.16 +24 -8 move decision into seperate function and insure compilability on non IPv6 platforms -ChangeSet@1.1251.94.12, 2006-06-17 18:42:11-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.12, 2006-06-17 18:42:11-04:00, stenn@whimsy.udel.edu More bk-4 license check trigger cleanup - BitKeeper/triggers/post-incoming.license-warn@1.3, 2006-06-17 18:41:50-04:00, stenn@whimsy.udel.edu +11 -4 + BitKeeper/triggers/post-incoming.license-warn@1.3 +11 -4 More bk-4 license check trigger cleanup - BitKeeper/triggers/pre-resolve.license-chk@1.3, 2006-06-17 18:41:50-04:00, stenn@whimsy.udel.edu +12 -4 + BitKeeper/triggers/pre-resolve.license-chk@1.3 +12 -4 More bk-4 license check trigger cleanup -ChangeSet@1.1251.94.11, 2006-06-17 13:53:20-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.11, 2006-06-17 13:53:20-04:00, stenn@whimsy.udel.edu [Bug 637] Ignore UP in*addr_any interfaces - ntpd/ntp_io.c@1.187.1.15, 2006-06-17 13:53:00-04:00, stenn@whimsy.udel.edu +15 -0 + ntpd/ntp_io.c@1.187.1.15 +15 -0 [Bug 637] Ignore UP in*addr_any interfaces -ChangeSet@1.1251.94.10, 2006-06-17 13:47:07-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.10, 2006-06-17 13:47:07-04:00, stenn@whimsy.udel.edu Deal with -stable rcpoint - packageinfo.sh@1.27.1.6, 2006-06-17 13:46:47-04:00, stenn@whimsy.udel.edu +1 -0 + packageinfo.sh@1.27.1.6 +1 -0 Deal with -stable rcpoint - scripts/VersionName@1.4, 2006-06-17 13:46:48-04:00, stenn@whimsy.udel.edu +10 -0 + scripts/VersionName@1.4 +10 -0 Deal with -stable rcpoint -ChangeSet@1.1251.94.9, 2006-06-17 12:37:23-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.9, 2006-06-17 12:37:23-04:00, stenn@whimsy.udel.edu bk-3 uses sccscat, bk-4 uses annotate - BitKeeper/triggers/post-incoming.license-warn@1.2, 2006-06-17 12:37:04-04:00, stenn@whimsy.udel.edu +10 -1 + BitKeeper/triggers/post-incoming.license-warn@1.2 +10 -1 bk-3 uses sccscat, bk-4 uses annotate - BitKeeper/triggers/pre-resolve.license-chk@1.2, 2006-06-17 12:37:04-04:00, stenn@whimsy.udel.edu +9 -1 + BitKeeper/triggers/pre-resolve.license-chk@1.2 +9 -1 bk-3 uses sccscat, bk-4 uses annotate -ChangeSet@1.1353.1.4, 2006-06-17 07:21:46-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353.1.4, 2006-06-17 07:21:46-04:00, stenn@whimsy.udel.edu NTP_4_2_3P3 TAG: NTP_4_2_3P3 - packageinfo.sh@1.37, 2006-06-17 07:21:37-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.37 +1 -1 NTP_4_2_3P3 -ChangeSet@1.1251.94.8, 2006-06-17 07:02:53-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.8, 2006-06-17 07:02:53-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC TAG: NTP_4_2_2P0_RC - packageinfo.sh@1.27.1.5, 2006-06-17 07:02:44-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.1.5 +1 -1 NTP_4_2_2P0_RC -ChangeSet@1.1353.1.2, 2006-06-16 18:33:41-04:00, stenn@pogo.udel.edu +4 -0 +ChangeSet@1.1353.1.2, 2006-06-16 18:33:41-04:00, stenn@pogo.udel.edu Makefile.am: "make distcheck" is now happy with the libopts/ stuff configure.ac, Makefile.am: @@ -14186,118 +194953,118 @@ ChangeSet@1.1353.1.2, 2006-06-16 18:33:41-04:00, stenn@pogo.udel.edu +4 -0 debug-opt.def: Change mode to -rw-rw-rw- - Makefile.am@1.66, 2006-06-16 18:33:23-04:00, stenn@pogo.udel.edu +61 -57 + Makefile.am@1.66 +61 -57 "make distcheck" is now happy with the libopts/ stuff - Makefile.am@1.65, 2006-06-16 15:49:25-04:00, stenn@pogo.udel.edu +1 -1 + Makefile.am@1.65 +1 -1 [Bug 635] get libopts/ properly distributed - Makefile.am@1.64, 2006-06-16 03:49:12-04:00, stenn@pogo.udel.edu +6 -3 + Makefile.am@1.64 +6 -3 [Bug 635] Properly distribute libopts/ . - configure.ac@1.385, 2006-06-16 15:49:26-04:00, stenn@pogo.udel.edu +1 -2 + configure.ac@1.385 +1 -2 [Bug 635] get libopts/ properly distributed - configure.ac@1.384, 2006-06-16 03:49:13-04:00, stenn@pogo.udel.edu +1 -0 + configure.ac@1.384 +1 -0 [Bug 635] Properly distribute libopts/ . - include/Makefile.am@1.23, 2006-06-16 03:47:49-04:00, stenn@pogo.udel.edu +1 -1 + include/Makefile.am@1.23 +1 -1 Distribute copyright.def and debug-opt.def - include/debug-opt.def@1.3, 2006-06-16 03:46:23-04:00, stenn@pogo.udel.edu +0 -0 + include/debug-opt.def@1.3 +0 -0 Change mode to -rw-rw-rw- -ChangeSet@1.1251.94.7, 2006-06-16 18:02:54-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.7, 2006-06-16 18:02:54-04:00, stenn@whimsy.udel.edu [Bug 633] Avoid writing files in srcdir - scripts/genver@1.4, 2006-06-16 17:58:49-04:00, stenn@whimsy.udel.edu +8 -8 + scripts/genver@1.4 +8 -8 [Bug 633] Avoid writing files in srcdir -ChangeSet@1.1351.1.1, 2006-06-16 02:54:50-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1351.1.1, 2006-06-16 02:54:50-04:00, stenn@pogo.udel.edu Use separate copies of libopts for ntp and sntp - bootstrap@1.6.1.1, 2006-06-16 02:54:38-04:00, stenn@pogo.udel.edu +7 -0 + bootstrap@1.6.1.1 +7 -0 Use separate copies of libopts for ntp and sntp -ChangeSet@1.1353, 2006-06-15 07:12:32-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1353, 2006-06-15 07:12:32-04:00, stenn@whimsy.udel.edu NTP_4_2_3P2 TAG: NTP_4_2_3P2 - packageinfo.sh@1.35, 2006-06-15 07:12:20-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.35 +1 -1 NTP_4_2_3P2 -ChangeSet@1.1352, 2006-06-15 04:46:11-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1352, 2006-06-15 04:46:11-04:00, stenn@whimsy.udel.edu Try harder to get sntp/libopts/Makefile.in to get the correct srcdir path - bootstrap@1.7, 2006-06-15 04:45:42-04:00, stenn@whimsy.udel.edu +4 -0 + bootstrap@1.7 +4 -0 Try harder to get sntp/libopts/Makefile.in to get the correct srcdir path -ChangeSet@1.1347.2.3, 2006-06-13 07:27:18-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1347.2.3, 2006-06-13 07:27:18-04:00, stenn@whimsy.udel.edu NTP_4_2_3P1 TAG: NTP_4_2_3P1 - packageinfo.sh@1.34, 2006-06-13 07:27:10-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.34 +1 -1 NTP_4_2_3P1 -ChangeSet@1.1251.94.6, 2006-06-13 07:02:41-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.6, 2006-06-13 07:02:41-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC TAG: NTP_4_2_2P0_RC - packageinfo.sh@1.27.1.4, 2006-06-13 07:02:31-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.1.4 +1 -1 NTP_4_2_2P0_RC -ChangeSet@1.1251.94.5, 2006-06-13 04:43:41-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.5, 2006-06-13 04:43:41-04:00, stenn@whimsy.udel.edu Distribute the bootstrap script - Makefile.am@1.48.1.4, 2006-06-13 04:43:22-04:00, stenn@whimsy.udel.edu +1 -0 + Makefile.am@1.48.1.4 +1 -0 Distribute the bootstrap script -ChangeSet@1.1347.2.1, 2006-06-12 07:47:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1347.2.1, 2006-06-12 07:47:44-04:00, stenn@whimsy.udel.edu NTP_4_2_3P0 TAG: NTP_4_2_3P0 - packageinfo.sh@1.32, 2006-06-12 07:47:36-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.32 +1 -1 NTP_4_2_3P0 -ChangeSet@1.1251.94.4, 2006-06-12 07:03:05-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.4, 2006-06-12 07:03:05-04:00, stenn@whimsy.udel.edu NTP_4_2_2P0_RC TAG: NTP_4_2_2P0_RC - packageinfo.sh@1.27.1.3, 2006-06-12 07:02:55-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.27.1.3 +2 -2 NTP_4_2_2P0_RC -ChangeSet@1.1347.1.10, 2006-06-12 01:42:27-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1347.1.10, 2006-06-12 01:42:27-04:00, stenn@whimsy.udel.edu Explain how to disable the trigger stuff - BitKeeper/triggers/trigger.README@1.4, 2006-06-12 01:41:47-04:00, stenn@whimsy.udel.edu +6 -0 + BitKeeper/triggers/trigger.README@1.4 +6 -0 Explain how to disable the trigger stuff -ChangeSet@1.1347.1.9, 2006-06-12 01:37:08-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1347.1.9, 2006-06-12 01:37:08-04:00, stenn@whimsy.udel.edu cleanup - packageinfo.sh@1.31, 2006-06-12 01:36:39-04:00, stenn@whimsy.udel.edu +2 -2 + packageinfo.sh@1.31 +2 -2 cleanup -ChangeSet@1.1251.94.3, 2006-06-11 18:38:11-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.94.3, 2006-06-11 18:38:11-04:00, stenn@whimsy.udel.edu Install license check triggers. - BitKeeper/triggers/post-incoming.license-warn@1.1, 2006-06-11 18:35:50-04:00, stenn@whimsy.udel.edu +14 -0 + BitKeeper/triggers/post-incoming.license-warn@1.1 +14 -0 - BitKeeper/triggers/post-incoming.license-warn@1.0, 2006-06-11 18:35:50-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/triggers/post-incoming.license-warn@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-stable/BitKeeper/triggers/post-incoming.license-warn - BitKeeper/triggers/pre-resolve.license-chk@1.1, 2006-06-11 18:35:51-04:00, stenn@whimsy.udel.edu +21 -0 + BitKeeper/triggers/pre-resolve.license-chk@1.1 +21 -0 - BitKeeper/triggers/pre-resolve.license-chk@1.0, 2006-06-11 18:35:51-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/triggers/pre-resolve.license-chk@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-stable/BitKeeper/triggers/pre-resolve.license-chk -ChangeSet@1.1251.94.2, 2006-06-11 17:49:08-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.2, 2006-06-11 17:49:08-04:00, stenn@whimsy.udel.edu Add some internal distribution checks - packageinfo.sh@1.27.1.2, 2006-06-11 17:48:43-04:00, stenn@whimsy.udel.edu +3 -3 + packageinfo.sh@1.27.1.2 +3 -3 Add some internal distribution checks -ChangeSet@1.1347.1.7, 2006-06-11 01:34:07+00:00, rick@pogo.udel.edu +1 -0 +ChangeSet@1.1347.1.7, 2006-06-11 01:34:07+00:00, rick@pogo.udel.edu pre-resolve.fixlic: Block bad repos from being pulled into this repo, or if this repo is bad, stops it from being used. @@ -14307,146 +195074,146 @@ ChangeSet@1.1347.1.7, 2006-06-11 01:34:07+00:00, rick@pogo.udel.edu +1 -0 Then bk new them and bk commit. Thanks. -- Rick Smith - BitKeeper/triggers/pre-resolve.licfix@1.1, 2006-06-11 01:33:05+00:00, rick@pogo.udel.edu +32 -0 + BitKeeper/triggers/pre-resolve.licfix@1.1 +32 -0 - BitKeeper/triggers/pre-resolve.licfix@1.0, 2006-06-11 01:33:05+00:00, rick@pogo.udel.edu +0 -0 + BitKeeper/triggers/pre-resolve.licfix@1.0 +0 -0 BitKeeper file /pogo/users/lm/ntp-fixed.license/BitKeeper/triggers/pre-resolve.licfix -ChangeSet@1.1347.1.6, 2006-06-10 01:37:28-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1347.1.6, 2006-06-10 01:37:28-04:00, stenn@whimsy.udel.edu bootstrap: there was a libopts dependency name problem with the old autoreconf sequence - change it to something slower that works. flock-build: lose --with-sntp as it is no longer needed - bootstrap@1.6, 2006-06-10 01:36:09-04:00, stenn@whimsy.udel.edu +2 -2 + bootstrap@1.6 +2 -2 there was a libopts dependency name problem with the old autoreconf sequence - change it to something slower that works. - flock-build@1.36, 2006-06-10 01:34:40-04:00, stenn@whimsy.udel.edu +1 -1 + flock-build@1.36 +1 -1 lose --with-sntp as it is no longer needed -ChangeSet@1.1347.1.5, 2006-06-09 19:30:12-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1347.1.5, 2006-06-09 19:30:12-04:00, stenn@whimsy.udel.edu NTP_4_2_3 TAG: NTP_4_2_3 - packageinfo.sh@1.29, 2006-06-09 19:29:55-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.29 +1 -1 NTP_4_2_3 -ChangeSet@1.1251.94.1, 2006-06-06 16:19:55-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.94.1, 2006-06-06 16:19:55-04:00, stenn@whimsy.udel.edu NTP_4_2_2 TAG: NTP_4_2_2 - packageinfo.sh@1.27.1.1, 2006-06-06 16:19:45-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.27.1.1 +1 -1 NTP_4_2_2 -ChangeSet@1.1347.1.4, 2006-06-06 05:05:56-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1347.1.4, 2006-06-06 05:05:56-04:00, stenn@whimsy.udel.edu [Bug 500] sntp is now part of the team - Makefile.am@1.62, 2006-06-06 05:04:23-04:00, stenn@whimsy.udel.edu +1 -1 + Makefile.am@1.62 +1 -1 [Bug 500] sntp is now part of the team - configure.ac@1.381.1.1, 2006-06-06 05:04:28-04:00, stenn@whimsy.udel.edu +1 -20 + configure.ac@1.381.1.1 +1 -20 [Bug 500] sntp is now part of the team -ChangeSet@1.1350, 2006-06-06 08:47:18+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1350, 2006-06-06 08:47:18+00:00, kardel@pogo.udel.edu ntpdbase-opts.def: add U option for update interval for interface scan cmd_args.c: adjust argument processing to a number - ntpd/cmd_args.c@1.39, 2006-06-06 08:45:49+00:00, kardel@pogo.udel.edu +5 -5 + ntpd/cmd_args.c@1.39 +5 -5 adjust argument processing to a number - ntpd/ntpdbase-opts.def@1.2.1.1, 2006-06-06 08:46:25+00:00, kardel@pogo.udel.edu +13 -0 + ntpd/ntpdbase-opts.def@1.2.1.1 +13 -0 add U option for update interval for interface scan -ChangeSet@1.1347.1.3, 2006-06-06 04:44:33-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1347.1.3, 2006-06-06 04:44:33-04:00, stenn@deacon.udel.edu Mention autogen in NEWS - NEWS@1.51, 2006-06-06 04:44:26-04:00, stenn@deacon.udel.edu +2 -0 + NEWS@1.51 +2 -0 Mention autogen in NEWS -ChangeSet@1.1347.1.2, 2006-06-06 04:21:52-04:00, stenn@deacon.udel.edu +14 -0 +ChangeSet@1.1347.1.2, 2006-06-06 04:21:52-04:00, stenn@deacon.udel.edu Copyright cleanup - clockstuff/Makefile.am@1.5, 2006-06-06 04:14:26-04:00, stenn@deacon.udel.edu +2 -0 + clockstuff/Makefile.am@1.5 +2 -0 Copyright cleanup - clockstuff/clktest-opts.def@1.3, 2006-06-06 04:14:26-04:00, stenn@deacon.udel.edu +0 -22 + clockstuff/clktest-opts.def@1.3 +0 -22 Copyright cleanup - include/copyright.def@1.3, 2006-06-06 04:14:33-04:00, stenn@deacon.udel.edu +3 -2 + include/copyright.def@1.3 +3 -2 Copyright cleanup - ntpd/Makefile.am@1.48, 2006-06-06 04:14:58-04:00, stenn@deacon.udel.edu +6 -6 + ntpd/Makefile.am@1.48 +6 -6 Copyright cleanup - ntpd/ntpd-opts.def@1.3, 2006-06-06 04:14:58-04:00, stenn@deacon.udel.edu +1 -28 + ntpd/ntpd-opts.def@1.3 +1 -28 Copyright cleanup - ntpd/ntpdbase-opts.def@1.3, 2006-06-06 04:14:58-04:00, stenn@deacon.udel.edu +0 -13 + ntpd/ntpdbase-opts.def@1.3 +0 -13 Copyright cleanup - ntpd/ntpdsim-opts.def@1.3, 2006-06-06 04:14:58-04:00, stenn@deacon.udel.edu +1 -28 + ntpd/ntpdsim-opts.def@1.3 +1 -28 Copyright cleanup - ntpdc/Makefile.am@1.30, 2006-06-06 04:15:06-04:00, stenn@deacon.udel.edu +3 -3 + ntpdc/Makefile.am@1.30 +3 -3 Copyright cleanup - ntpdc/ntpdc-opts.def@1.9, 2006-06-06 04:15:06-04:00, stenn@deacon.udel.edu +0 -22 + ntpdc/ntpdc-opts.def@1.9 +0 -22 Copyright cleanup - ntpq/Makefile.am@1.22, 2006-06-06 04:15:10-04:00, stenn@deacon.udel.edu +3 -3 + ntpq/Makefile.am@1.22 +3 -3 Copyright cleanup - ntpq/ntpq-opts.def@1.6, 2006-06-06 04:15:10-04:00, stenn@deacon.udel.edu +1 -42 + ntpq/ntpq-opts.def@1.6 +1 -42 Copyright cleanup - sntp/sntp-opts.def@1.3, 2006-06-06 04:15:29-04:00, stenn@deacon.udel.edu +3 -24 + sntp/sntp-opts.def@1.3 +3 -24 Copyright cleanup - util/Makefile.am@1.31, 2006-06-06 04:15:34-04:00, stenn@deacon.udel.edu +3 -3 + util/Makefile.am@1.31 +3 -3 Copyright cleanup - util/ntp-keygen-opts.def@1.3, 2006-06-06 04:15:34-04:00, stenn@deacon.udel.edu +3 -32 + util/ntp-keygen-opts.def@1.3 +3 -32 Copyright cleanup -ChangeSet@1.1347.1.1, 2006-06-06 03:06:10-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1347.1.1, 2006-06-06 03:06:10-04:00, stenn@whimsy.udel.edu re-enable auto-gen - bootstrap@1.5, 2006-06-06 03:05:34-04:00, stenn@whimsy.udel.edu +14 -14 + bootstrap@1.5 +14 -14 Re-enable autogen now that we need it. - ntpd/ntpd.c@1.77.1.1, 2006-06-06 03:03:16-04:00, stenn@whimsy.udel.edu +0 -2 + ntpd/ntpd.c@1.77.1.1 +0 -2 lose some old debug output -ChangeSet@1.1251.80.72, 2006-06-05 21:31:04-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.72, 2006-06-05 21:31:04-04:00, stenn@whimsy.udel.edu ntp-4.2.3 - packageinfo.sh@1.28, 2006-06-05 21:30:39-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.28 +1 -1 ntp-4.2.3 -ChangeSet@1.1251.80.71, 2006-06-05 19:53:12-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.80.71, 2006-06-05 19:53:12-04:00, stenn@whimsy.udel.edu ntp-4.2.2 - NEWS@1.50, 2006-06-05 19:21:53-04:00, stenn@whimsy.udel.edu +6 -1 + NEWS@1.50 +6 -1 Release ntp-4.2.2 - packageinfo.sh@1.27, 2006-06-05 19:22:00-04:00, stenn@whimsy.udel.edu +4 -4 + packageinfo.sh@1.27 +4 -4 Release ntp-4.2.2 - scripts/VersionName@1.3, 2006-06-05 19:51:58-04:00, stenn@whimsy.udel.edu +1 -0 + scripts/VersionName@1.3 +1 -0 clean up a corner case -ChangeSet@1.1251.80.70, 2006-05-29 07:02:40-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.70, 2006-05-29 07:02:40-04:00, stenn@whimsy.udel.edu NTP_4_2_1P257_RC TAG: NTP_4_2_1P257_RC - packageinfo.sh@1.26, 2006-05-29 07:02:30-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.26 +1 -1 NTP_4_2_1P257_RC -ChangeSet@1.1251.72.45, 2006-05-27 11:04:43+00:00, kardel@pogo.udel.edu +6 -0 +ChangeSet@1.1251.72.45, 2006-05-27 11:04:43+00:00, kardel@pogo.udel.edu monopt.html: document conditional nature of process timing debugging ntpd.c: @@ -14459,33 +195226,33 @@ ChangeSet@1.1251.72.45, 2006-05-27 11:04:43+00:00, kardel@pogo.udel.edu +6 -0 configure.ac: make process timing debug code conditional (default off) - configure.ac@1.359.1.30, 2006-05-27 10:59:02+00:00, kardel@pogo.udel.edu +9 -0 + configure.ac@1.359.1.30 +9 -0 make process timing debug code conditional (default off) - html/monopt.html@1.22, 2006-05-27 11:02:54+00:00, kardel@pogo.udel.edu +1 -1 + html/monopt.html@1.22 +1 -1 document conditional nature of process timing debugging - include/ntpd.h@1.82.1.16, 2006-05-27 10:59:44+00:00, kardel@pogo.udel.edu +5 -0 + include/ntpd.h@1.82.1.16 +5 -0 cleanup conditional compile cruft in ntpd.c by defining a macro - ntpd/ntp_io.c@1.217, 2006-05-27 11:00:51+00:00, kardel@pogo.udel.edu +9 -7 + ntpd/ntp_io.c@1.217 +9 -7 make process timing debug conditional - ntpd/ntp_util.c@1.41, 2006-05-27 11:01:08+00:00, kardel@pogo.udel.edu +3 -3 + ntpd/ntp_util.c@1.41 +3 -3 make process timing debug conditional - ntpd/ntpd.c@1.61.1.26, 2006-05-27 11:01:15+00:00, kardel@pogo.udel.edu +11 -21 + ntpd/ntpd.c@1.61.1.26 +11 -21 make process timing debug conditional cleanup conditional compilation -ChangeSet@1.1251.80.68, 2006-05-27 07:02:40-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.68, 2006-05-27 07:02:40-04:00, stenn@whimsy.udel.edu NTP_4_2_1P256_RC TAG: NTP_4_2_1P256_RC - packageinfo.sh@1.25, 2006-05-27 07:02:32-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.25 +1 -1 NTP_4_2_1P256_RC -ChangeSet@1.1251.93.1, 2006-05-26 17:08:21+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1251.93.1, 2006-05-26 17:08:21+00:00, kardel@pogo.udel.edu ntpdc.h: bug 621 change arg_v to struct, add type field @@ -14495,44 +195262,44 @@ ChangeSet@1.1251.93.1, 2006-05-26 17:08:21+00:00, kardel@pogo.udel.edu +2 -0 always as the 'new' parsing code seems to make that previously unfounded assumption. - ntpdc/ntpdc.c@1.40.2.6, 2006-05-26 17:05:10+00:00, kardel@pogo.udel.edu +9 -2 + ntpdc/ntpdc.c@1.40.2.6 +9 -2 bug 621 change arg_v to struct, add type field, initialize string member always as the 'new' parsing code seems to make that previously unfounded assumption. - ntpdc/ntpdc.h@1.7, 2006-05-26 17:07:45+00:00, kardel@pogo.udel.edu +4 -2 + ntpdc/ntpdc.h@1.7 +4 -2 bug 621 change arg_v to struct, add type field -ChangeSet@1.1251.80.67, 2006-05-26 14:40:03+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.67, 2006-05-26 14:40:03+00:00, kardel@pogo.udel.edu refclock_parse.c: bug 619 delay io_addclock() even further as suggested by Ronan Flood - ntpd/refclock_parse.c@1.35.1.11, 2006-05-26 14:38:20+00:00, kardel@pogo.udel.edu +25 -19 + ntpd/refclock_parse.c@1.35.1.11 +25 -19 bug 619 delay io_addclock() even further as suggested by Ronan Flood -ChangeSet@1.1251.80.66, 2006-05-26 07:02:46-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.66, 2006-05-26 07:02:46-04:00, stenn@whimsy.udel.edu NTP_4_2_1P255_RC TAG: NTP_4_2_1P255_RC - packageinfo.sh@1.24, 2006-05-26 07:02:38-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.24 +1 -1 NTP_4_2_1P255_RC -ChangeSet@1.1251.92.3, 2006-05-25 18:25:23+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.92.3, 2006-05-25 18:25:23+00:00, kardel@pogo.udel.edu refclock_parse.c: bug #619 terminate parse io engine after de-registering from refclock io engine - ntpd/refclock_parse.c@1.35.3.3, 2006-05-25 18:24:49+00:00, kardel@pogo.udel.edu +12 -7 + ntpd/refclock_parse.c@1.35.3.3 +12 -7 bug #619 terminate parse io engine after de-registering from refclock io engine -ChangeSet@1.1251.92.2, 2006-05-25 18:08:49+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1251.92.2, 2006-05-25 18:08:49+00:00, kardel@pogo.udel.edu ntp_io.c: add missing BLOCKIO()/UNBLOCKIO() calls in refclock io handling found during analysis for bug #619 @@ -14541,23 +195308,23 @@ ChangeSet@1.1251.92.2, 2006-05-25 18:08:49+00:00, kardel@pogo.udel.edu +2 -0 complete refclock io structure initialization *before* inserting it into the refclock input machine (avoids null pointer deref) - ntpd/ntp_io.c@1.187.1.14, 2006-05-25 17:47:54+00:00, kardel@pogo.udel.edu +4 -0 + ntpd/ntp_io.c@1.187.1.14 +4 -0 add missing BLOCKIO()/UNBLOCKIO() calls in refclock io handling found during analysis for bug #619 - ntpd/refclock_parse.c@1.35.3.2, 2006-05-25 17:44:26+00:00, kardel@pogo.udel.edu +19 -12 + ntpd/refclock_parse.c@1.35.3.2 +19 -12 bug #619 complete refclock io structure initialization *before* inserting it into the refclock input machine (avoids null pointer deref) -ChangeSet@1.1251.92.1, 2006-05-25 07:02:50-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.92.1, 2006-05-25 07:02:50-04:00, stenn@whimsy.udel.edu NTP_4_2_1P254_RC TAG: NTP_4_2_1P254_RC - packageinfo.sh@1.23, 2006-05-25 07:02:41-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.23 +1 -1 NTP_4_2_1P254_RC -ChangeSet@1.1251.72.42, 2006-05-25 07:55:42+00:00, kardel@pogo.udel.edu +6 -0 +ChangeSet@1.1251.72.42, 2006-05-25 07:55:42+00:00, kardel@pogo.udel.edu monopt.html: document timingstats (only available when daemon is compiled with DEBUG) ntpd.h, ntpd.c, ntp_util.c: @@ -14569,318 +195336,318 @@ ChangeSet@1.1251.72.42, 2006-05-25 07:55:42+00:00, kardel@pogo.udel.edu +6 -0 ntp_crypto.c: return OK when interface is not bound - html/monopt.html@1.21, 2006-05-25 07:36:35+00:00, kardel@pogo.udel.edu +5 -1 + html/monopt.html@1.21 +5 -1 document timingstats (only available when daemon is compiled with DEBUG) - include/ntpd.h@1.82.1.15, 2006-05-25 06:55:55+00:00, kardel@pogo.udel.edu +6 -0 + include/ntpd.h@1.82.1.15 +6 -0 support collection of timing data - ntpd/ntp_crypto.c@1.107, 2006-05-25 06:52:30+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_crypto.c@1.107 +1 -1 return OK when interface is not bound - ntpd/ntp_io.c@1.215, 2006-05-25 06:53:01+00:00, kardel@pogo.udel.edu +119 -12 + ntpd/ntp_io.c@1.215 +119 -12 implement SO_TIMESTAMP for systems that have it support collection of timing data fix io signal blocking in refclock io handling functions - ntpd/ntp_util.c@1.40, 2006-05-25 06:54:36+00:00, kardel@pogo.udel.edu +39 -0 + ntpd/ntp_util.c@1.40 +39 -0 support collection of timing data - ntpd/ntpd.c@1.61.1.25, 2006-05-25 06:54:47+00:00, kardel@pogo.udel.edu +43 -17 + ntpd/ntpd.c@1.61.1.25 +43 -17 support collection of timing data -ChangeSet@1.1251.80.62, 2006-05-24 22:01:55-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.62, 2006-05-24 22:01:55-04:00, mayer@pogo.udel.edu Bug #504 Allow forced DNS retry even on failure only if macro FORCE_DNSRETRY is defined - ntpd/ntp_intres.c@1.47, 2006-05-24 22:01:00-04:00, mayer@pogo.udel.edu +13 -0 + ntpd/ntp_intres.c@1.47 +13 -0 Bug #504 Allow forced DNS retry even on failure only if macro FORCE_DNSRETRY is defined -ChangeSet@1.1251.80.61, 2006-05-21 14:57:46-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.61, 2006-05-21 14:57:46-04:00, mayer@pogo.udel.edu Bug #614 Remove errno manipulation from move_fd() - ntpd/ntp_io.c@1.187.1.13, 2006-05-21 14:57:23-04:00, mayer@pogo.udel.edu +1 -3 + ntpd/ntp_io.c@1.187.1.13 +1 -3 Bug #614 Remove errno manipulation from move_fd() -ChangeSet@1.1251.91.1, 2006-05-21 12:10:13-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.91.1, 2006-05-21 12:10:13-04:00, mayer@pogo.udel.edu Bug #614 Changed dup_fd to move_fd and remove for Windows - ntpd/ntp_io.c@1.187.1.12, 2006-05-21 12:09:34-04:00, mayer@pogo.udel.edu +5 -5 + ntpd/ntp_io.c@1.187.1.12 +5 -5 Bug #614 Changed dup_fd to move_fd and remove for Windows -ChangeSet@1.1251.80.59, 2006-05-21 07:03:00-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.59, 2006-05-21 07:03:00-04:00, stenn@whimsy.udel.edu NTP_4_2_1P253_RC TAG: NTP_4_2_1P253_RC - packageinfo.sh@1.22, 2006-05-21 07:02:52-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.22 +1 -1 NTP_4_2_1P253_RC -ChangeSet@1.1251.80.57, 2006-05-20 19:15:50-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.80.57, 2006-05-20 19:15:50-04:00, mayer@pogo.udel.edu Fix Bug #612: Erroneous FAR macro - libntp/ntp_rfc2553.c@1.27.1.4, 2006-05-20 19:14:58-04:00, mayer@pogo.udel.edu +2 -5 + libntp/ntp_rfc2553.c@1.27.1.4 +2 -5 Fix Bug #612: Erroneous FAR macro - ports/winnt/libntp/dnslookup.c@1.3, 2006-05-20 19:15:27-04:00, mayer@pogo.udel.edu +3 -3 + ports/winnt/libntp/dnslookup.c@1.3 +3 -3 Fix Bug #612: Erroneous FAR macro -ChangeSet@1.1251.90.5, 2006-05-20 18:16:07-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.90.5, 2006-05-20 18:16:07-04:00, stenn@whimsy.udel.edu Update the UDel host lists and handle the PWD better - br-flock@1.9, 2006-05-20 18:15:44-04:00, stenn@whimsy.udel.edu +1 -1 + br-flock@1.9 +1 -1 Update the UDel host lists and handle the PWD better - flock-build@1.35, 2006-05-20 18:15:45-04:00, stenn@whimsy.udel.edu +2 -3 + flock-build@1.35 +2 -3 Update the UDel host lists and handle the PWD better -ChangeSet@1.1251.80.56, 2006-05-20 17:01:51-04:00, mayer@pogo.udel.edu +3 -0 +ChangeSet@1.1251.80.56, 2006-05-20 17:01:51-04:00, mayer@pogo.udel.edu Bug fixes for #611, 612, 614 and 530 - libntp/ntp_rfc2553.c@1.27.1.3, 2006-05-20 16:59:38-04:00, mayer@pogo.udel.edu +4 -2 + libntp/ntp_rfc2553.c@1.27.1.3 +4 -2 Bug #612 Added include for netent structure - ntpd/ntp_intres.c@1.46, 2006-05-20 17:01:06-04:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_intres.c@1.46 +1 -1 Bug #611 Check for various EAI_* macros - ntpd/ntp_io.c@1.187.1.11, 2006-05-20 16:58:11-04:00, mayer@pogo.udel.edu +6 -4 + ntpd/ntp_io.c@1.187.1.11 +6 -4 Bug #530 and #614 fixes to add comments -ChangeSet@1.1251.80.55, 2006-05-16 07:58:39-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.55, 2006-05-16 07:58:39-04:00, mayer@pogo.udel.edu Bug #614 Add FOPEN_MAX as a parameter for dup_fd() usage. Also this is the fix for Bug #530 - ntpd/ntp_io.c@1.187.1.10, 2006-05-16 07:58:06-04:00, mayer@pogo.udel.edu +5 -2 + ntpd/ntp_io.c@1.187.1.10 +5 -2 Bug #614 Add FOPEN_MAX as a parameter for dup_fd() usage. Also this is the fix for Bug #530 -ChangeSet@1.1251.80.54, 2006-05-15 19:45:34-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.54, 2006-05-15 19:45:34-04:00, mayer@pogo.udel.edu Bug #611. Refix to add additional condition for Win32 - ntpd/ntp_intres.c@1.45, 2006-05-15 19:44:22-04:00, mayer@pogo.udel.edu +2 -0 + ntpd/ntp_intres.c@1.45 +2 -0 Bug #611. Refix to add additional condition for Win32 -ChangeSet@1.1251.80.53, 2006-05-15 19:30:22-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.53, 2006-05-15 19:30:22-04:00, mayer@pogo.udel.edu Bug #614 Fix duplicate descriptor code and properly handle error conditions - ntpd/ntp_io.c@1.187.1.9, 2006-05-15 19:29:52-04:00, mayer@pogo.udel.edu +6 -1 + ntpd/ntp_io.c@1.187.1.9 +6 -1 Bug #614 Fix duplicate descriptor code and properly handle error conditions -ChangeSet@1.1251.90.4, 2006-05-13 07:02:51-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.90.4, 2006-05-13 07:02:51-04:00, stenn@whimsy.udel.edu NTP_4_2_1P252_RC TAG: NTP_4_2_1P252_RC - packageinfo.sh@1.21, 2006-05-13 07:02:38-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.21 +1 -1 NTP_4_2_1P252_RC -ChangeSet@1.1251.90.3, 2006-05-12 14:57:38-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.90.3, 2006-05-12 14:57:38-04:00, stenn@whimsy.udel.edu [Bug 611] Fix based on Danny's comment - ntpd/ntp_intres.c@1.44, 2006-05-12 14:57:20-04:00, stenn@whimsy.udel.edu +2 -0 + ntpd/ntp_intres.c@1.44 +2 -0 [Bug 611] Fix based on Danny's comment -ChangeSet@1.1251.90.2, 2006-05-12 16:29:02+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.90.2, 2006-05-12 16:29:02+00:00, kardel@pogo.udel.edu refclock_parse.c: Bug 613: fix spelling - ntpd/refclock_parse.c@1.35.3.1, 2006-05-12 16:28:09+00:00, kardel@pogo.udel.edu +2 -2 + ntpd/refclock_parse.c@1.35.3.1 +2 -2 Bug 613: fix spelling -ChangeSet@1.1251.90.1, 2006-05-11 13:45:28-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.90.1, 2006-05-11 13:45:28-04:00, stenn@whimsy.udel.edu NTP_4_2_1P251_RC TAG: NTP_4_2_1P251_RC - packageinfo.sh@1.20, 2006-05-11 13:45:21-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.20 +1 -1 NTP_4_2_1P251_RC -ChangeSet@1.1251.89.1, 2006-05-11 15:07:05+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.89.1, 2006-05-11 15:07:05+00:00, kardel@pogo.udel.edu refclock_parse.c: fix spelling - ntpd/refclock_parse.c@1.35.1.8, 2006-05-11 15:05:06+00:00, kardel@pogo.udel.edu +2 -2 + ntpd/refclock_parse.c@1.35.1.8 +2 -2 fix spelling -ChangeSet@1.1251.80.51, 2006-05-10 23:55:45-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.51, 2006-05-10 23:55:45-04:00, mayer@pogo.udel.edu Bug #611 Fix for EAI_* codes and netent definitions - libntp/ntp_rfc2553.c@1.27.1.2, 2006-05-10 23:55:08-04:00, mayer@pogo.udel.edu +3 -0 + libntp/ntp_rfc2553.c@1.27.1.2 +3 -0 Bug #612 Fix for EAI_* codes and netent definitions - add netdb.h include -ChangeSet@1.1251.80.50, 2006-05-10 15:05:24-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.50, 2006-05-10 15:05:24-04:00, stenn@whimsy.udel.edu allow the AUTORECONF envariable to supply the name of autoreconf - bootstrap@1.4, 2006-05-10 15:04:31-04:00, stenn@whimsy.udel.edu +4 -2 + bootstrap@1.4 +4 -2 allow the AUTORECONF envariable to supply the name of autoreconf -ChangeSet@1.1251.80.49, 2006-05-09 06:44:15-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.49, 2006-05-09 06:44:15-04:00, stenn@whimsy.udel.edu NTP_4_2_1P250_RC TAG: NTP_4_2_1P250_RC - packageinfo.sh@1.19, 2006-05-09 06:44:03-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.19 +1 -1 NTP_4_2_1P250_RC -ChangeSet@1.1251.80.48, 2006-05-09 09:56:16+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.48, 2006-05-09 09:56:16+00:00, kardel@pogo.udel.edu ntpd.c: keep block/unblock calls balanced - ntpd/ntpd.c@1.61.1.24, 2006-05-09 09:55:06+00:00, kardel@pogo.udel.edu +4 -4 + ntpd/ntpd.c@1.61.1.24 +4 -4 keep block/unblock calls balanced -ChangeSet@1.1251.88.1, 2006-05-09 09:30:28+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.88.1, 2006-05-09 09:30:28+00:00, kardel@pogo.udel.edu ntpd.c: refill of current buffer missing - ntpd/ntpd.c@1.61.1.23, 2006-05-09 09:29:43+00:00, kardel@pogo.udel.edu +1 -0 + ntpd/ntpd.c@1.61.1.23 +1 -0 refill of current buffer missing -ChangeSet@1.1251.87.1, 2006-05-09 03:22:02-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.87.1, 2006-05-09 03:22:02-04:00, stenn@whimsy.udel.edu prepare for RCs for -stable point releases - packageinfo.sh@1.18, 2006-05-09 03:21:41-04:00, stenn@whimsy.udel.edu +6 -0 + packageinfo.sh@1.18 +6 -0 prepare for RCs for -stable point releases -ChangeSet@1.1251.80.45, 2006-05-09 07:12:14+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.45, 2006-05-09 07:12:14+00:00, kardel@pogo.udel.edu ntpd.c: move freerecvbuf() into block io section test receiver instead of just the rbuf pointer - ntpd/ntpd.c@1.61.1.22, 2006-05-09 07:11:09+00:00, kardel@pogo.udel.edu +2 -2 + ntpd/ntpd.c@1.61.1.22 +2 -2 move freerecvbuf() into block io section test receiver instead of just the rbuf pointer -ChangeSet@1.1251.80.44, 2006-05-08 18:21:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.44, 2006-05-08 18:21:44-04:00, stenn@whimsy.udel.edu NTP_4_2_1P249_RC TAG: NTP_4_2_1P249_RC - packageinfo.sh@1.17, 2006-05-08 18:21:33-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.17 +1 -1 NTP_4_2_1P249_RC -ChangeSet@1.1251.80.43, 2006-05-08 10:52:36+00:00, burnicki@pogo.udel.edu +2 -0 +ChangeSet@1.1251.80.43, 2006-05-08 10:52:36+00:00, burnicki@pogo.udel.edu Retrieve version info from packageinfo.sh also under Windows. - BitKeeper/etc/logging_ok@1.57.3.3, 2006-05-08 10:52:36+00:00, burnicki@pogo.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.57.3.3 +1 -0 Logging to repologs@ntp.isc.org accepted - ports/winnt/scripts/mkver.bat@1.8, 2006-05-08 10:51:53+00:00, burnicki@pogo.udel.edu +45 -18 + ports/winnt/scripts/mkver.bat@1.8 +45 -18 Retrieve version info from packageinfo.sh. -ChangeSet@1.1251.80.42, 2006-05-08 05:34:00-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.42, 2006-05-08 05:34:00-04:00, stenn@whimsy.udel.edu NTP_4_2_1P248_RC TAG: NTP_4_2_1P248_RC - packageinfo.sh@1.16, 2006-05-08 05:33:50-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.16 +1 -1 NTP_4_2_1P248_RC -ChangeSet@1.1251.80.41, 2006-05-08 04:59:17-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.41, 2006-05-08 04:59:17-04:00, stenn@whimsy.udel.edu handle the initial case where no version files exist - scripts/genver@1.3, 2006-05-08 04:58:58-04:00, stenn@whimsy.udel.edu +8 -8 + scripts/genver@1.3 +8 -8 handle the initial case where no version files exist -ChangeSet@1.1251.80.40, 2006-05-05 16:40:34-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.40, 2006-05-05 16:40:34-04:00, mayer@pogo.udel.edu Bug #596/527 updates to remove [UN]BLOCKIO() and keep initialization for Windows - libntp/recvbuff.c@1.22, 2006-05-05 16:39:46-04:00, mayer@pogo.udel.edu +0 -10 + libntp/recvbuff.c@1.22 +0 -10 Bug #596/527 updates to remove [UN]BLOCKIO() and keep initialization for Windows -ChangeSet@1.1251.80.39, 2006-05-05 08:48:59-04:00, mayer@pogo.udel.edu +4 -0 +ChangeSet@1.1251.80.39, 2006-05-05 08:48:59-04:00, mayer@pogo.udel.edu Bug #504 Collection of changes to retry DNS in case unable to get definitive answer - libntp/ntp_rfc2553.c@1.27.1.1, 2006-05-05 08:42:45-04:00, mayer@pogo.udel.edu +43 -5 + libntp/ntp_rfc2553.c@1.27.1.1 +43 -5 Bug #504 Move lookup call to dnslookup() function - ntpd/ntp_intres.c@1.43, 2006-05-05 08:45:32-04:00, mayer@pogo.udel.edu +22 -8 + ntpd/ntp_intres.c@1.43 +22 -8 Bug Retry DNS lookups if DNS unable to give a definitive answer or is unreachable - ports/winnt/libntp/dnslookup.c@1.2, 2006-05-05 08:47:26-04:00, mayer@pogo.udel.edu +0 -1 + ports/winnt/libntp/dnslookup.c@1.2 +0 -1 Bug #504 Windows only special lookup to fix return error codes - ports/winnt/libntp/dnslookup.c@1.1, 2006-05-05 08:36:40-04:00, mayer@pogo.udel.edu +197 -0 + ports/winnt/libntp/dnslookup.c@1.1 +197 -0 - ports/winnt/libntp/dnslookup.c@1.0, 2006-05-05 08:36:40-04:00, mayer@pogo.udel.edu +0 -0 + ports/winnt/libntp/dnslookup.c@1.0 +0 -0 BitKeeper file /pogo/users/mayer/ntp-dev/ports/winnt/libntp/dnslookup.c - ports/winnt/libntp/libntp.dsp@1.28, 2006-05-05 08:44:04-04:00, mayer@pogo.udel.edu +4 -0 + ports/winnt/libntp/libntp.dsp@1.28 +4 -0 Bug #504 add Windows only dnslookup to dsp file -ChangeSet@1.1251.85.14, 2006-05-05 00:52:13-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.14, 2006-05-05 00:52:13-04:00, stenn@whimsy.udel.edu NTP_4_2_1P247_RC TAG: NTP_4_2_1P247_RC - packageinfo.sh@1.15, 2006-05-05 00:52:03-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.15 +1 -1 NTP_4_2_1P247_RC -ChangeSet@1.1251.85.13, 2006-05-05 00:47:24-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.13, 2006-05-05 00:47:24-04:00, stenn@whimsy.udel.edu NTP_4_2_1P246_RC TAG: NTP_4_2_1P246_RC - packageinfo.sh@1.14, 2006-05-05 00:47:15-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.14 +1 -1 NTP_4_2_1P246_RC -ChangeSet@1.1251.85.12, 2006-05-05 00:42:27-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.12, 2006-05-05 00:42:27-04:00, stenn@whimsy.udel.edu NTP_4_2_1P245_RC TAG: NTP_4_2_1P245_RC - packageinfo.sh@1.13, 2006-05-05 00:42:21-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.13 +1 -1 NTP_4_2_1P245_RC -ChangeSet@1.1251.85.11, 2006-05-05 00:37:38-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.11, 2006-05-05 00:37:38-04:00, stenn@whimsy.udel.edu NTP_4_2_1P244_RC TAG: NTP_4_2_1P244_RC - packageinfo.sh@1.12, 2006-05-05 00:37:32-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.12 +1 -1 NTP_4_2_1P244_RC -ChangeSet@1.1251.85.10, 2006-05-04 22:28:16-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.10, 2006-05-04 22:28:16-04:00, stenn@whimsy.udel.edu Clean up/fix the force code - scripts/genver@1.2, 2006-05-04 22:27:40-04:00, stenn@whimsy.udel.edu +20 -12 + scripts/genver@1.2 +20 -12 Clean up/fix the force code -ChangeSet@1.1251.85.9, 2006-05-04 19:50:54-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.9, 2006-05-04 19:50:54-04:00, stenn@whimsy.udel.edu NTP_4_2_1P243_RC TAG: NTP_4_2_1P243_RC - packageinfo.sh@1.11, 2006-05-04 19:50:46-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.11 +1 -1 NTP_4_2_1P243_RC -ChangeSet@1.1251.85.8, 2006-05-04 07:03:18-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.8, 2006-05-04 07:03:18-04:00, stenn@whimsy.udel.edu NTP_4_2_1P242_RC TAG: NTP_4_2_1P242_RC - packageinfo.sh@1.10, 2006-05-04 07:03:08-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.10 +1 -1 NTP_4_2_1P242_RC -ChangeSet@1.1251.85.7, 2006-05-04 05:54:17-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.85.7, 2006-05-04 05:54:17-04:00, stenn@deacon.udel.edu Re-enable signaled I/O - configure.ac@1.359.1.29, 2006-05-04 05:54:10-04:00, stenn@deacon.udel.edu +2 -6 + configure.ac@1.359.1.29 +2 -6 Re-enable signaled I/O -ChangeSet@1.1251.86.1, 2006-05-04 05:38:51-04:00, stenn@deacon.udel.edu +5 -0 +ChangeSet@1.1251.86.1, 2006-05-04 05:38:51-04:00, stenn@deacon.udel.edu clean up the version generation stuff. - Makefile.am@1.48.1.3, 2006-05-04 05:34:46-04:00, stenn@deacon.udel.edu +12 -2 + Makefile.am@1.48.1.3 +12 -2 Deal with packageinfo.sh, version.m4, and include/version.def - bootstrap@1.3, 2006-05-04 05:35:44-04:00, stenn@deacon.udel.edu +2 -6 + bootstrap@1.3 +2 -6 Use the new scripts/genver to generate the version files - include/Makefile.am@1.19.1.2, 2006-05-04 05:36:21-04:00, stenn@deacon.udel.edu +1 -1 + include/Makefile.am@1.19.1.2 +1 -1 distribute inclue/version.def - scripts/Makefile.am@1.13, 2006-05-04 05:36:55-04:00, stenn@deacon.udel.edu +2 -2 + scripts/Makefile.am@1.13 +2 -2 Distribute VersionName and genver. - scripts/genver@1.1, 2006-05-04 05:33:24-04:00, stenn@deacon.udel.edu +59 -0 + scripts/genver@1.1 +59 -0 - scripts/genver@1.0, 2006-05-04 05:33:24-04:00, stenn@deacon.udel.edu +0 -0 + scripts/genver@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/scripts/genver -ChangeSet@1.1251.85.5, 2006-05-02 09:13:40+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.85.5, 2006-05-02 09:13:40+00:00, kardel@pogo.udel.edu ntp_crypto.c: handle NULL return from d2i_X509() - NetBSD Run 21 Coverity CID 2979 - ntpd/ntp_crypto.c@1.98.1.13, 2006-05-02 09:12:16+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_crypto.c@1.98.1.13 +1 -1 handle NULL return from d2i_X509() - NetBSD Run 21 Coverity CID 2979 -ChangeSet@1.1251.85.4, 2006-05-01 18:27:54+00:00, kardel@pogo.udel.edu +3 -0 +ChangeSet@1.1251.85.4, 2006-05-01 18:27:54+00:00, kardel@pogo.udel.edu refclock_parse.c: If an input buffer parses into more than one message do insert the parsed message in a new input buffer instead of processing it @@ -14894,496 +195661,496 @@ ChangeSet@1.1251.85.4, 2006-05-01 18:27:54+00:00, kardel@pogo.udel.edu +3 -0 cleanup get_full_recvbuffer() to decide only the full queue head and simplify code (remove multiple tests) - libntp/recvbuff.c@1.19.1.1, 2006-05-01 18:18:25+00:00, kardel@pogo.udel.edu +4 -11 + libntp/recvbuff.c@1.19.1.1 +4 -11 cleanup get_full_recvbuffer() to decide only the full queue head and simplify code (remove multiple tests) - ntpd/ntpd.c@1.61.5.1, 2006-05-01 18:21:28+00:00, kardel@pogo.udel.edu +25 -12 + ntpd/ntpd.c@1.61.5.1 +25 -12 re-instate vital io blocking protocol to insure that receive buffer queue is only manipulated when io is blocked - ntpd/refclock_parse.c@1.35.1.7, 2006-05-01 18:22:34+00:00, kardel@pogo.udel.edu +33 -18 + ntpd/refclock_parse.c@1.35.1.7 +33 -18 If an input buffer parses into more than one message do insert the parsed message in a new input buffer instead of processing it directly. This avoids deed complicated processing in signal handling. -ChangeSet@1.1251.85.3, 2006-04-21 00:09:43-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.3, 2006-04-21 00:09:43-04:00, stenn@whimsy.udel.edu NTP_4_2_1P241_RC TAG: NTP_4_2_1P241_RC - packageinfo.sh@1.9, 2006-04-21 00:09:32-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.9 +1 -1 NTP_4_2_1P241_RC -ChangeSet@1.1251.85.2, 2006-04-20 23:59:56-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.2, 2006-04-20 23:59:56-04:00, stenn@whimsy.udel.edu [Bug 527] Lose signalled IO. - configure.ac@1.359.1.28, 2006-04-20 23:58:47-04:00, stenn@whimsy.udel.edu +7 -2 - [Bug 527] Lose signalled IO. + configure.ac@1.359.1.28 +7 -2 + [Bug 527] Losed signalled IO. -ChangeSet@1.1251.85.1, 2006-04-18 05:58:13-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.85.1, 2006-04-18 05:58:13-04:00, stenn@whimsy.udel.edu there are 240 ntp-dev patch releases so far - packageinfo.sh@1.8, 2006-04-18 05:57:50-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.8 +1 -1 there are 240 ntp-dev patch releases so far -ChangeSet@1.1251.80.37, 2006-04-15 18:33:29-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.37, 2006-04-15 18:33:29-04:00, mayer@pogo.udel.edu Fix Bug #596 and #572 to deal with polling restrictions - libntp/recvbuff.c@1.20, 2006-04-15 18:33:18-04:00, mayer@pogo.udel.edu +20 -18 + libntp/recvbuff.c@1.20 +20 -18 Fix Bug #596 and #572 to deal with polling restrictions -ChangeSet@1.1251.80.36, 2006-04-15 18:32:57-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.36, 2006-04-15 18:32:57-04:00, mayer@pogo.udel.edu Fix Bug #596 and #572 to deal with polling restrictions - ntpd/ntpd.c@1.61.1.20, 2006-04-15 18:32:25-04:00, mayer@pogo.udel.edu +3 -1 + ntpd/ntpd.c@1.61.1.20 +3 -1 Fix Bug #596 and #572 to deal with polling restrictions -ChangeSet@1.1251.80.35, 2006-04-13 04:14:26-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.80.35, 2006-04-13 04:14:26-04:00, stenn@whimsy.udel.edu Use ./packageinfo.sh as . may not be in the PATH. Reported by Frank Kardel. - bootstrap@1.2, 2006-04-13 04:14:03-04:00, stenn@whimsy.udel.edu +1 -1 + bootstrap@1.2 +1 -1 Use ./packageinfo.sh as . may not be in the PATH. Reported by Frank Kardel. - scripts/VersionName@1.2, 2006-04-13 04:14:03-04:00, stenn@whimsy.udel.edu +2 -1 + scripts/VersionName@1.2 +2 -1 Use ./packageinfo.sh as . may not be in the PATH. Reported by Frank Kardel. -ChangeSet@1.1251.80.34, 2006-04-12 06:43:08-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.34, 2006-04-12 06:43:08-04:00, stenn@whimsy.udel.edu fix a typo - README.versions@1.4, 2006-04-12 06:42:47-04:00, stenn@whimsy.udel.edu +1 -1 + README.versions@1.4 +1 -1 fix a typo -ChangeSet@1.1251.80.33, 2006-04-12 05:57:14-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.33, 2006-04-12 05:57:14-04:00, stenn@whimsy.udel.edu NTP_4_2_1P12_RC TAG: NTP_4_2_1P12_RC - packageinfo.sh@1.7, 2006-04-12 05:57:06-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.7 +1 -1 NTP_4_2_1P12_RC -ChangeSet@1.1251.80.32, 2006-04-12 05:27:53-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.32, 2006-04-12 05:27:53-04:00, stenn@whimsy.udel.edu NTP_4_2_1P11_RC TAG: NTP_4_2_1P11_RC - packageinfo.sh@1.6, 2006-04-12 05:27:46-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.6 +1 -1 NTP_4_2_1P11_RC -ChangeSet@1.1251.80.31, 2006-04-12 05:22:34-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.31, 2006-04-12 05:22:34-04:00, stenn@whimsy.udel.edu Update the NEWS file - NEWS@1.49, 2006-04-12 05:22:12-04:00, stenn@whimsy.udel.edu +2 -1 + NEWS@1.49 +2 -1 Update the NEWS file -ChangeSet@1.1251.80.30, 2006-04-12 05:14:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.30, 2006-04-12 05:14:52-04:00, stenn@whimsy.udel.edu cleanup - packageinfo.sh@1.5, 2006-04-12 05:14:33-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.5 +1 -1 cleanup -ChangeSet@1.1251.80.29, 2006-04-12 04:51:30-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.29, 2006-04-12 04:51:30-04:00, stenn@whimsy.udel.edu NTP_4_2_1P10_RC TAG: NTP_4_2_1P10_RC - packageinfo.sh@1.4, 2006-04-12 04:51:23-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.4 +1 -1 NTP_4_2_1P10_RC -ChangeSet@1.1251.80.28, 2006-04-12 04:44:14-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.28, 2006-04-12 04:44:14-04:00, stenn@whimsy.udel.edu use a reasonable value for "point". - packageinfo.sh@1.3, 2006-04-12 04:43:58-04:00, stenn@whimsy.udel.edu +1 -1 + packageinfo.sh@1.3 +1 -1 use a reasonable value for "point". -ChangeSet@1.1251.80.27, 2006-04-12 04:39:22-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.80.27, 2006-04-12 04:39:22-04:00, stenn@whimsy.udel.edu update - packageinfo.sh@1.2, 2006-04-12 04:39:00-04:00, stenn@whimsy.udel.edu +3 -3 + packageinfo.sh@1.2 +3 -3 update -ChangeSet@1.1342, 2006-04-11 18:05:00-07:00, bkorb@bach.veritas.com +5 -0 +ChangeSet@1.1342, 2006-04-11 18:05:00-07:00, bkorb@bach.veritas.com AutoOpt the clktest program. Move copyright, version and config file stuff into a common file. - BitKeeper/etc/config@1.8, 2006-04-11 18:04:59-07:00, bkorb@bach.veritas.com +4 -0 + BitKeeper/etc/config@1.8 +4 -0 New license - clockstuff/clktest-opts.def@1.2, 2006-04-11 18:00:39-07:00, bkorb@bach.veritas.com +228 -0 + clockstuff/clktest-opts.def@1.2 +228 -0 clktest option definition file. - clockstuff/clktest-opts.def@1.1, 2006-04-11 17:51:41-07:00, bkorb@bach.veritas.com +0 -0 + clockstuff/clktest-opts.def@1.1 +0 -0 - clockstuff/clktest-opts.def@1.0, 2006-04-11 17:51:41-07:00, bkorb@bach.veritas.com +0 -0 + clockstuff/clktest-opts.def@1.0 +0 -0 BitKeeper file /home/bkorb/tools/ntp/ntp-dev-ag/clockstuff/clktest-opts.def - clockstuff/clktest.c@1.3, 2006-04-11 18:00:39-07:00, bkorb@bach.veritas.com +31 -148 + clockstuff/clktest.c@1.3 +31 -148 Move includes to option definition file so the option code can use them, too. Move option processing to option definition file. Use AutoOpts to parse. - include/copyright.def@1.2, 2006-04-11 18:00:39-07:00, bkorb@bach.veritas.com +24 -0 + include/copyright.def@1.2 +24 -0 version, copyright and rc file stuff for all commands. - include/copyright.def@1.1, 2006-04-11 17:51:41-07:00, bkorb@bach.veritas.com +0 -0 + include/copyright.def@1.1 +0 -0 - include/copyright.def@1.0, 2006-04-11 17:51:41-07:00, bkorb@bach.veritas.com +0 -0 + include/copyright.def@1.0 +0 -0 BitKeeper file /home/bkorb/tools/ntp/ntp-dev-ag/include/copyright.def - ntpdc/ntpdc-opts.def@1.8, 2006-04-11 18:00:39-07:00, bkorb@bach.veritas.com +1 -24 + ntpdc/ntpdc-opts.def@1.8 +1 -24 Move common copyright and ini file stuff to a common "copyright.def" file. -ChangeSet@1.1251.84.1, 2006-04-11 04:49:33-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.84.1, 2006-04-11 04:49:33-04:00, stenn@whimsy.udel.edu release prep - bootstrap@1.1, 2006-04-11 04:47:55-04:00, stenn@whimsy.udel.edu +59 -0 + bootstrap@1.1 +59 -0 - bootstrap@1.0, 2006-04-11 04:47:55-04:00, stenn@whimsy.udel.edu +0 -0 + bootstrap@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/bootstrap - packageinfo.sh@1.1, 2006-04-11 04:47:12-04:00, stenn@whimsy.udel.edu +19 -0 + packageinfo.sh@1.1 +19 -0 - packageinfo.sh@1.0, 2006-04-11 04:47:12-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/packageinfo.sh -ChangeSet@1.1251.80.25, 2006-04-09 05:25:08-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.80.25, 2006-04-09 05:25:08-04:00, stenn@whimsy.udel.edu README* updates - README@1.21, 2006-04-09 05:24:50-04:00, stenn@whimsy.udel.edu +1 -1 + README@1.21 +1 -1 README* updates - README.bk@1.18, 2006-04-09 05:24:50-04:00, stenn@whimsy.udel.edu +3 -51 + README.bk@1.18 +3 -51 README* updates - README.versions@1.3, 2006-04-09 05:24:51-04:00, stenn@whimsy.udel.edu +10 -18 + README.versions@1.3 +10 -18 README* updates -ChangeSet@1.1251.80.24, 2006-04-09 05:00:52-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1251.80.24, 2006-04-09 05:00:52-04:00, stenn@whimsy.udel.edu New release numbering style support - BitKeeper/deleted/.del-version.m4~4ef47e5fd0c38ddb@1.3.2.1, 2006-04-09 04:57:32-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-version.m4~4ef47e5fd0c38ddb@1.3.2.1 +0 -0 Delete: version.m4 - BitKeeper/etc/ignore@1.35.1.1, 2006-04-09 04:57:51-04:00, stenn@whimsy.udel.edu +2 -0 + BitKeeper/etc/ignore@1.35.1.1 +2 -0 added include/version.def version.m4 - bootstrap@1.2, 2006-04-09 04:58:41-04:00, stenn@whimsy.udel.edu +13 -11 + bootstrap@1.2 +13 -11 cleanup - bootstrap@1.1, 2006-04-09 04:07:34-04:00, stenn@whimsy.udel.edu +57 -0 + bootstrap@1.1 +57 -0 - bootstrap@1.0, 2006-04-09 04:07:34-04:00, stenn@whimsy.udel.edu +0 -0 + bootstrap@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/bootstrap - packageinfo.sh@1.1, 2006-04-09 04:05:25-04:00, stenn@whimsy.udel.edu +17 -0 + packageinfo.sh@1.1 +17 -0 - packageinfo.sh@1.0, 2006-04-09 04:05:25-04:00, stenn@whimsy.udel.edu +0 -0 + packageinfo.sh@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/packageinfo.sh - scripts/VersionName@1.1, 2006-04-09 04:51:47-04:00, stenn@whimsy.udel.edu +29 -0 + scripts/VersionName@1.1 +29 -0 - scripts/VersionName@1.0, 2006-04-09 04:51:47-04:00, stenn@whimsy.udel.edu +0 -0 + scripts/VersionName@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/scripts/VersionName -ChangeSet@1.1341, 2006-04-09 00:16:18-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1341, 2006-04-09 00:16:18-04:00, stenn@pogo.udel.edu update - packageinfo.sh@1.4, 2006-04-09 00:16:12-04:00, stenn@pogo.udel.edu +4 -1 + packageinfo.sh@1.4 +4 -1 update -ChangeSet@1.1340, 2006-04-08 22:13:54-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1340, 2006-04-08 22:13:54-04:00, stenn@pogo.udel.edu update - packageinfo.sh@1.3, 2006-04-08 22:13:44-04:00, stenn@pogo.udel.edu +11 -1 + packageinfo.sh@1.3 +11 -1 update -ChangeSet@1.1339, 2006-04-08 22:11:27-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1339, 2006-04-08 22:11:27-04:00, stenn@pogo.udel.edu update - bootstrap@1.9, 2006-04-08 22:11:08-04:00, stenn@pogo.udel.edu +1 -1 + bootstrap@1.9 +1 -1 update -ChangeSet@1.1338, 2006-04-08 00:50:08-04:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1338, 2006-04-08 00:50:08-04:00, stenn@pogo.udel.edu Test new release numbering and snapshot method - BitKeeper/etc/ignore@1.48, 2006-04-08 00:49:18-04:00, stenn@pogo.udel.edu +2 -0 + BitKeeper/etc/ignore@1.48 +2 -0 added version.m4 include/version.def - packageinfo.sh@1.2, 2006-04-08 00:49:59-04:00, stenn@pogo.udel.edu +4 -1 + packageinfo.sh@1.2 +4 -1 Test new release numbering and snapshot method -ChangeSet@1.1251.80.23, 2006-04-04 03:16:32-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.80.23, 2006-04-04 03:16:32-04:00, stenn@deacon.udel.edu [Bug 588] logfile documentation problems - html/miscopt.html@1.35, 2006-04-04 03:16:00-04:00, stenn@deacon.udel.edu +5 -5 + html/miscopt.html@1.35 +5 -5 [Bug 588] logfile documentation problems -ChangeSet@1.1251.80.22, 2006-04-01 05:14:27-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.80.22, 2006-04-01 05:14:27-05:00, stenn@deacon.udel.edu Ignore control characters - ntpd/refclock_acts.c@1.25.1.1, 2006-04-01 05:13:53-05:00, stenn@deacon.udel.edu +1 -1 + ntpd/refclock_acts.c@1.25.1.1 +1 -1 Ignore control characters -ChangeSet@1.1251.80.21, 2006-03-30 01:43:28-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.80.21, 2006-03-30 01:43:28-05:00, stenn@deacon.udel.edu [Bug 584] quiet a coverity buffer overrun - ntpd/refclock_chu.c@1.37, 2006-03-30 01:42:56-05:00, stenn@deacon.udel.edu +1 -1 + ntpd/refclock_chu.c@1.37 +1 -1 [Bug 584] quiet a coverity buffer overrun -ChangeSet@1.1336, 2006-03-26 06:02:05-05:00, stenn@pogo.udel.edu +7 -0 +ChangeSet@1.1336, 2006-03-26 06:02:05-05:00, stenn@pogo.udel.edu debug-opts.def cleanup Allow optional hostnames on the command line for ntpq and ntpdc. - BitKeeper/etc/ignore@1.47, 2006-03-26 06:02:00-05:00, stenn@pogo.udel.edu +1 -1 + BitKeeper/etc/ignore@1.47 +1 -1 Fix the ignore for sntp/libopts/ - BitKeeper/etc/ignore@1.46, 2006-03-26 05:52:13-05:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/ignore@1.46 +1 -0 added sntp/libopts - ntpd/Makefile.am@1.47, 2006-03-26 06:01:59-05:00, stenn@pogo.udel.edu +7 -7 + ntpd/Makefile.am@1.47 +7 -7 debug-opt.def cleanup - ntpdc/Makefile.am@1.29, 2006-03-26 06:02:00-05:00, stenn@pogo.udel.edu +4 -4 + ntpdc/Makefile.am@1.29 +4 -4 debug-opts.def cleanup - ntpdc/ntpdc-opts.def@1.7, 2006-03-26 06:02:00-05:00, stenn@pogo.udel.edu +1 -0 + ntpdc/ntpdc-opts.def@1.7 +1 -0 Allow hostnames on the command-line. - ntpq/Makefile.am@1.21, 2006-03-26 06:02:00-05:00, stenn@pogo.udel.edu +4 -4 + ntpq/Makefile.am@1.21 +4 -4 debug-opts.def cleanup - ntpq/ntpq-opts.def@1.5, 2006-03-26 06:02:00-05:00, stenn@pogo.udel.edu +3 -25 + ntpq/ntpq-opts.def@1.5 +3 -25 Allow hostnames on the command-line. - util/Makefile.am@1.30, 2006-03-26 06:02:00-05:00, stenn@pogo.udel.edu +4 -4 + util/Makefile.am@1.30 +4 -4 debug-opts.def cleanup -ChangeSet@1.1251.80.20, 2006-03-24 00:27:03-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.80.20, 2006-03-24 00:27:03-05:00, stenn@deacon.udel.edu [Bug 571] fix a typo that prevents ntpdate from working - ntpdate/ntpdate.c@1.58, 2006-03-24 00:26:29-05:00, stenn@deacon.udel.edu +1 -1 + ntpdate/ntpdate.c@1.58 +1 -1 [Bug 571] fix a typo that prevents ntpdate from working -ChangeSet@1.1251.80.18, 2006-03-21 10:43:26+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.18, 2006-03-21 10:43:26+00:00, kardel@pogo.udel.edu ntp_restrict.c: null deref: fix another case of incomplete list handling (Coverity NetBSD Scan 8: CID 986) - ntpd/ntp_restrict.c@1.17.1.4, 2006-03-21 10:38:33+00:00, kardel@pogo.udel.edu +12 -3 + ntpd/ntp_restrict.c@1.17.1.4 +12 -3 null deref: fix another case of incomplete list handling (Coverity NetBSD Scan 8: CID 986) -ChangeSet@1.1251.83.1, 2006-03-21 05:41:41-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.83.1, 2006-03-21 05:41:41-05:00, stenn@deacon.udel.edu [Bug 584] Fix potential buffer overrun - ntpd/refclock_chu.c@1.36, 2006-03-21 05:41:07-05:00, stenn@deacon.udel.edu +2 -2 + ntpd/refclock_chu.c@1.36 +2 -2 [Bug 584] Fix potential buffer overrun -ChangeSet@1.1251.82.1, 2006-03-20 05:56:32+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1251.82.1, 2006-03-20 05:56:32+00:00, kardel@pogo.udel.edu refclock_oncore.c, ntp_restrict.c: standardize pointer checks - ntpd/ntp_restrict.c@1.17.2.1, 2006-03-20 05:52:19+00:00, kardel@pogo.udel.edu +3 -3 + ntpd/ntp_restrict.c@1.17.2.1 +3 -3 standardize pointer checks - ntpd/refclock_oncore.c@1.59, 2006-03-20 05:54:36+00:00, kardel@pogo.udel.edu +2 -2 + ntpd/refclock_oncore.c@1.59 +2 -2 standardize pointer checks -ChangeSet@1.1251.80.16, 2006-03-19 22:14:48-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.80.16, 2006-03-19 22:14:48-05:00, mayer@pogo.udel.edu Additional fixes for Coverity items - ntpd/ntp_restrict.c@1.17.1.2, 2006-03-19 22:14:26-05:00, mayer@pogo.udel.edu +2 -2 + ntpd/ntp_restrict.c@1.17.1.2 +2 -2 Additional fixes for Coverity items - ntpdc/ntpdc.c@1.40.2.5, 2006-03-19 22:14:25-05:00, mayer@pogo.udel.edu +4 -1 + ntpdc/ntpdc.c@1.40.2.5 +4 -1 Additional fixes for Coverity items -ChangeSet@1.1251.80.15, 2006-03-19 07:23:01+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.15, 2006-03-19 07:23:01+00:00, kardel@pogo.udel.edu refclock_datum.c: error handling: check success of open(2) - bail out early (Coverity CID 1282 NetBSD Scan 5) - ntpd/refclock_datum.c@1.9, 2006-03-19 07:18:17+00:00, kardel@pogo.udel.edu +13 -5 + ntpd/refclock_datum.c@1.9 +13 -5 error handling: check success of open(2) - bail out early (Coverity CID 1282 NetBSD Scan 5) -ChangeSet@1.1251.80.14, 2006-03-19 07:04:21+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.14, 2006-03-19 07:04:21+00:00, kardel@pogo.udel.edu ntp_restrict.c: null deref: complete linked list handling beginng condition (Coverity CID 986 NetBSD Scan 5) - ntpd/ntp_restrict.c@1.17.1.1, 2006-03-19 06:59:30+00:00, kardel@pogo.udel.edu +12 -3 + ntpd/ntp_restrict.c@1.17.1.1 +12 -3 null deref: complete linked list handling beginng condition (Coverity CID 986 NetBSD Scan 5) -ChangeSet@1.1251.80.13, 2006-03-18 15:25:00+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.13, 2006-03-18 15:25:00+00:00, kardel@pogo.udel.edu ntpdc.c: mem leak: unreachable code prevented freeing of allocated memory (Coverity CID 612 NetBSD Scan 5) - ntpdc/ntpdc.c@1.40.2.4, 2006-03-18 15:22:52+00:00, kardel@pogo.udel.edu +1 -2 + ntpdc/ntpdc.c@1.40.2.4 +1 -2 mem leak: unreachable code prevented freeing of allocated memory (Coverity CID 612 NetBSD Scan 5) -ChangeSet@1.1251.80.12, 2006-03-18 14:33:59+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.12, 2006-03-18 14:33:59+00:00, kardel@pogo.udel.edu refclock_oncore.c: null deref: avoid 0 deref (Coverity CID 987 NetBSD Scan 5) - ntpd/refclock_oncore.c@1.58, 2006-03-18 14:33:30+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/refclock_oncore.c@1.58 +1 -1 null deref: avoid 0 deref (Coverity CID 987 NetBSD Scan 5) -ChangeSet@1.1251.80.11, 2006-03-18 14:20:27+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.11, 2006-03-18 14:20:27+00:00, kardel@pogo.udel.edu refclock_arc.c: buffer bounds: buffer full condition wrong for bounds check (Coverity CID 1508 NetBSD Scan 5) - ntpd/refclock_arc.c@1.18, 2006-03-18 14:19:55+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/refclock_arc.c@1.18 +1 -1 buffer bounds: buffer full condition wrong for bounds check (Coverity CID 1508 NetBSD Scan 5) -ChangeSet@1.1251.80.10, 2006-03-18 14:09:32+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.10, 2006-03-18 14:09:32+00:00, kardel@pogo.udel.edu refclock_leitch.c: buffer bounds: correct > - >= error for bounds check (Coverity CID 1511 NetBSD Scan 5) - ntpd/refclock_leitch.c@1.7, 2006-03-18 14:09:11+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/refclock_leitch.c@1.7 +1 -1 buffer bounds: correct > - >= error for bounds check (Coverity CID 1511 NetBSD Scan 5) -ChangeSet@1.1251.80.9, 2006-03-18 14:08:59+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.9, 2006-03-18 14:08:59+00:00, kardel@pogo.udel.edu refclock_oncore.c: mem leakage: free old malloced buffer on errors (Coverity CID 2056 NetBSD Scan 5) - ntpd/refclock_oncore.c@1.57, 2006-03-18 13:43:21+00:00, kardel@pogo.udel.edu +6 -0 + ntpd/refclock_oncore.c@1.57 +6 -0 mem leakage: free old malloced buffer on errors (Coverity CID 2056 NetBSD Scan 5) -ChangeSet@1.1251.80.8, 2006-03-18 09:24:46+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.8, 2006-03-18 09:24:46+00:00, kardel@pogo.udel.edu ntp_crypto.c: resource leak (fd/mem): fclose() streams on error (Coverity NetBSD scan CID 2055) - ntpd/ntp_crypto.c@1.98.1.12, 2006-03-18 09:11:14+00:00, kardel@pogo.udel.edu +6 -0 + ntpd/ntp_crypto.c@1.98.1.12 +6 -0 resource leak (fd/mem): fclose() streams on error (Coverity NetBSD scan CID 2055) -ChangeSet@1.1251.80.7, 2006-03-18 08:53:22+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.7, 2006-03-18 08:53:22+00:00, kardel@pogo.udel.edu ntp_crypto.c: close stream when error occur (Coverity NetBSD Scan CID 2054) - ntpd/ntp_crypto.c@1.98.1.11, 2006-03-18 08:52:18+00:00, kardel@pogo.udel.edu +3 -0 + ntpd/ntp_crypto.c@1.98.1.11 +3 -0 close stream when error occur (Coverity NetBSD Scan CID 2054) -ChangeSet@1.1251.80.6, 2006-03-18 08:01:26+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.6, 2006-03-18 08:01:26+00:00, kardel@pogo.udel.edu ntptime.c: resolve potential but not occurring 1-pointer deref (Coverity NetBSD scan, CID 808) - util/ntptime.c@1.19, 2006-03-18 07:57:43+00:00, kardel@pogo.udel.edu +1 -1 + util/ntptime.c@1.19 +1 -1 resolve potential but not occurring 1-pointer deref (Coverity NetBSD scan, CID 808) -ChangeSet@1.1251.80.5, 2006-03-18 07:55:03+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.5, 2006-03-18 07:55:03+00:00, kardel@pogo.udel.edu ntptime.c: resolve bounds issue (Coverity CID 1466, NetBSD scan) - util/ntptime.c@1.18, 2006-03-18 07:53:50+00:00, kardel@pogo.udel.edu +1 -1 + util/ntptime.c@1.18 +1 -1 resolve bounds issue (Coverity CID 1466, NetBSD scan) -ChangeSet@1.1251.80.4, 2006-03-18 01:11:42+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.4, 2006-03-18 01:11:42+00:00, kardel@pogo.udel.edu refclock_parse.c: coverity fixes found in NetBSD coverity scan - ntpd/refclock_parse.c@1.35.1.6, 2006-03-18 01:11:00+00:00, kardel@pogo.udel.edu +14 -7 + ntpd/refclock_parse.c@1.35.1.6 +14 -7 coverity fixes found in NetBSD coverity scan -ChangeSet@1.1251.81.1, 2006-03-17 04:22:39-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.81.1, 2006-03-17 04:22:39-05:00, stenn@deacon.udel.edu Set c_iflag=0 for RAW mode - ntpd/ntp_refclock.c@1.75, 2006-03-17 04:22:20-05:00, stenn@deacon.udel.edu +2 -0 + ntpd/ntp_refclock.c@1.75 +2 -0 Set c_iflag=0 for RAW mode -ChangeSet@1.1251.80.2, 2006-03-16 17:55:20-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.80.2, 2006-03-16 17:55:20-05:00, mayer@pogo.udel.edu [Bug 479] Fix Memory Leak - ntpd/ntp_io.c@1.187.1.8, 2006-03-16 17:55:03-05:00, mayer@pogo.udel.edu +14 -12 + ntpd/ntp_io.c@1.187.1.8 +14 -12 Fix Bug #479 Memory Leak -ChangeSet@1.1251.80.1, 2006-03-15 02:29:27-05:00, stenn@deacon.udel.edu +6 -0 +ChangeSet@1.1251.80.1, 2006-03-15 02:29:27-05:00, stenn@deacon.udel.edu [Bug 472] configurable driftfile write frequency - html/miscopt.html@1.34, 2006-03-15 02:28:44-05:00, stenn@deacon.udel.edu +15 -3 + html/miscopt.html@1.34 +15 -3 [Bug 472] configurable driftfile write frequency - include/ntpd.h@1.82.4.5, 2006-03-15 02:28:44-05:00, stenn@deacon.udel.edu +3 -1 + include/ntpd.h@1.82.4.5 +3 -1 [Bug 472] configurable driftfile write frequency - ntpd/ntp_config.c@1.129.6.1, 2006-03-15 02:28:44-05:00, stenn@deacon.udel.edu +10 -0 + ntpd/ntp_config.c@1.129.6.1 +10 -0 [Bug 472] configurable driftfile write frequency - ntpd/ntp_timer.c@1.28.1.1, 2006-03-15 02:28:44-05:00, stenn@deacon.udel.edu +7 -6 + ntpd/ntp_timer.c@1.28.1.1 +7 -6 [Bug 472] configurable driftfile write frequency - ntpd/ntp_util.c@1.36.2.1, 2006-03-15 02:28:44-05:00, stenn@deacon.udel.edu +10 -1 + ntpd/ntp_util.c@1.36.2.1 +10 -1 [Bug 472] configurable driftfile write frequency - ntpd/ntpd.c@1.61.1.19, 2006-03-15 02:28:45-05:00, stenn@deacon.udel.edu +1 -0 + ntpd/ntpd.c@1.61.1.19 +1 -0 [Bug 472] configurable driftfile write frequency -ChangeSet@1.1251.72.34, 2006-03-15 06:37:26+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1251.72.34, 2006-03-15 06:37:26+00:00, kardel@pogo.udel.edu ntp_peer.c: speling fix copyright.html: obfuscate eMail address document dynamic interface handling - html/copyright.html@1.34, 2006-03-15 06:35:31+00:00, kardel@pogo.udel.edu +2 -2 + html/copyright.html@1.34 +2 -2 obfuscate eMail address document dynamic interface handling - ntpd/ntp_peer.c@1.94, 2006-03-15 06:36:56+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_peer.c@1.94 +1 -1 speling fix -ChangeSet@1.1251.72.33, 2006-03-14 23:09:12+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.72.33, 2006-03-14 23:09:12+00:00, kardel@pogo.udel.edu ntp_proto.c: peer.{first,last} gone - ntpd/ntp_proto.c@1.244, 2006-03-14 08:46:44+00:00, kardel@pogo.udel.edu +0 -3 + ntpd/ntp_proto.c@1.244 +0 -3 peer.{first,last} gone -ChangeSet@1.1333, 2006-03-14 00:51:12-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1333, 2006-03-14 00:51:12-05:00, stenn@pogo.udel.edu cleanup - Makefile.am@1.60, 2006-03-14 00:51:04-05:00, stenn@pogo.udel.edu +1 -1 + Makefile.am@1.60 +1 -1 cleanup -ChangeSet@1.1251.79.2, 2006-03-05 16:34:07-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.79.2, 2006-03-05 16:34:07-05:00, stenn@deacon.udel.edu [Bug 553] QNX does not want adjtime.h - ntpdate/ntpdate.c@1.57, 2006-03-05 16:33:57-05:00, stenn@deacon.udel.edu +0 -4 + ntpdate/ntpdate.c@1.57 +0 -4 [Bug 553] QNX does not want adjtime.h -ChangeSet@1.1251.79.1, 2006-03-05 16:26:53-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.79.1, 2006-03-05 16:26:53-05:00, stenn@deacon.udel.edu [Bug 576] Use __adjtimex if we have it and not ntp_adjtime - include/ntp_machine.h@1.22, 2006-03-05 16:26:44-05:00, stenn@deacon.udel.edu +4 -0 + include/ntp_machine.h@1.22 +4 -0 [Bug 576] Use __adjtimex if we have it and not ntp_adjtime -ChangeSet@1.1251.72.30, 2006-03-02 15:03:35-05:00, clemens@pogo.udel.edu +1 -0 +ChangeSet@1.1251.72.30, 2006-03-02 15:03:35-05:00, clemens@pogo.udel.edu Clean up on exit. - ntpd/refclock_oncore.c@1.56, 2006-03-02 15:03:32-05:00, clemens@pogo.udel.edu +6 -1 + ntpd/refclock_oncore.c@1.56 +6 -1 Clean up on exit. -ChangeSet@1.1251.72.29, 2006-03-01 04:20:05-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.29, 2006-03-01 04:20:05-05:00, stenn@deacon.udel.edu AUTOMAKE_OPTIONS: We require automake 1.8 or later. - Makefile.am@1.48.1.2, 2006-03-01 04:19:58-05:00, stenn@deacon.udel.edu +1 -1 + Makefile.am@1.48.1.2 +1 -1 AUTOMAKE_OPTIONS: We require automake 1.8 or later. -ChangeSet@1.1251.72.28, 2006-02-28 23:43:36-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.28, 2006-02-28 23:43:36-05:00, stenn@deacon.udel.edu RC1 for 4.2.1 TAG: ntp-dev TAG: NTP_4_2_0B_RC1 - version.m4@1.3.1.1, 2006-02-28 23:41:38-05:00, stenn@deacon.udel.edu +1 -1 + version.m4@1.3.1.1 +1 -1 RC1 for 4.2.1 -ChangeSet@1.1251.78.1, 2006-02-28 09:38:25-05:00, hilbrecht@pogo.udel.edu +2 -0 +ChangeSet@1.1251.78.1, 2006-02-28 09:38:25-05:00, hilbrecht@pogo.udel.edu refclock_neoclock4x.c: update driver to version 1.15 fix bug #499 and #574 - BitKeeper/etc/logging_ok@1.57.5.1, 2006-02-28 09:38:24-05:00, hilbrecht@pogo.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.57.5.1 +1 -0 Logging to repologs@ntp.isc.org accepted - ntpd/refclock_neoclock4x.c@1.13.1.1, 2006-02-28 09:36:19-05:00, hilbrecht@pogo.udel.edu +16 -30 + ntpd/refclock_neoclock4x.c@1.13.1.1 +16 -30 update driver to version 1.15 fix bug #499 and #574 -ChangeSet@1.1251.77.3, 2006-02-25 19:18:31-05:00, clemens@pogo.udel.edu +2 -0 +ChangeSet@1.1251.77.3, 2006-02-25 19:18:31-05:00, clemens@pogo.udel.edu The following 5 changes were made. (1) Fixes for warnings from the curreng gcc compiler. (2) Fix for a possible segfault if restarting with a damaged shmem file. @@ -15397,10 +196164,10 @@ ChangeSet@1.1251.77.3, 2006-02-25 19:18:31-05:00, clemens@pogo.udel.edu +2 -0 Ulrich Windl implementation, or the new one, depending on the timepps.h seen. - BitKeeper/etc/logging_ok@1.57.4.1, 2006-02-25 19:18:30-05:00, clemens@pogo.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.57.4.1 +1 -0 Logging to repologs@ntp.isc.org accepted - ntpd/refclock_oncore.c@1.55, 2006-02-25 19:17:10-05:00, clemens@pogo.udel.edu +214 -99 + ntpd/refclock_oncore.c@1.55 +214 -99 The following 5 changes were made. (1) Fixes for warnings from the curreng gcc compiler. (2) Fix for a possible segfault if restarting with a damaged shmem file. @@ -15414,204 +196181,204 @@ ChangeSet@1.1251.77.3, 2006-02-25 19:18:31-05:00, clemens@pogo.udel.edu +2 -0 Ulrich Windl implementation, or the new one, depending on the timepps.h seen. -ChangeSet@1.1178.5.9, 2006-02-24 04:24:12-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1178.5.9, 2006-02-24 04:24:12-05:00, stenn@deacon.udel.edu mort is gone, replaced by macabre - br-flock@1.4.1.2, 2006-02-24 04:24:01-05:00, stenn@deacon.udel.edu +1 -1 + br-flock@1.4.1.2 +1 -1 mort is gone, replaced by macabre -ChangeSet@1.1251.77.1, 2006-02-24 04:20:07-05:00, stenn@deacon.udel.edu +4 -0 +ChangeSet@1.1251.77.1, 2006-02-24 04:20:07-05:00, stenn@deacon.udel.edu Let there be fuzz. Make sure sys_precision is visible and present. - libntp/systime.c@1.38, 2006-02-24 04:19:02-05:00, stenn@deacon.udel.edu +9 -7 + libntp/systime.c@1.38 +9 -7 Let there be fuzz. Make sure sys_precision is visible and present. - ntpdate/ntpdate.c@1.56, 2006-02-24 04:19:02-05:00, stenn@deacon.udel.edu +5 -0 + ntpdate/ntpdate.c@1.56 +5 -0 Let there be fuzz. Make sure sys_precision is visible and present. - ntpdc/ntpdc.c@1.40.3.1, 2006-02-24 04:19:02-05:00, stenn@deacon.udel.edu +5 -0 + ntpdc/ntpdc.c@1.40.3.1 +5 -0 Let there be fuzz. Make sure sys_precision is visible and present. - ntpq/ntpq.c@1.55.1.5, 2006-02-24 04:19:02-05:00, stenn@deacon.udel.edu +5 -0 + ntpq/ntpq.c@1.55.1.5 +5 -0 Let there be fuzz. Make sure sys_precision is visible and present. -ChangeSet@1.1251.72.25, 2006-02-24 02:10:29+00:00, rayvt@pogo.udel.edu +3 -0 +ChangeSet@1.1251.72.25, 2006-02-24 02:10:29+00:00, rayvt@pogo.udel.edu ntcdc options update - ntpd/ntp_request.c@1.58.1.2, 2006-02-24 02:10:25+00:00, rayvt@pogo.udel.edu +18 -3 + ntpd/ntp_request.c@1.58.1.2 +18 -3 ntcdc options update - ntpdc/ntpdc.h@1.6, 2006-02-24 02:10:25+00:00, rayvt@pogo.udel.edu +2 -1 + ntpdc/ntpdc.h@1.6 +2 -1 ntcdc options update - ntpdc/ntpdc_ops.c@1.38.1.2, 2006-02-24 02:10:25+00:00, rayvt@pogo.udel.edu +132 -87 + ntpdc/ntpdc_ops.c@1.38.1.2 +132 -87 ntcdc options update -ChangeSet@1.1251.72.24, 2006-02-24 02:08:52+00:00, rayvt@pogo.udel.edu +7 -0 +ChangeSet@1.1251.72.24, 2006-02-24 02:08:52+00:00, rayvt@pogo.udel.edu ntpdc options update - BitKeeper/etc/logging_ok@1.57.3.1, 2006-02-24 02:08:51+00:00, rayvt@pogo.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.57.3.1 +1 -0 Logging to repologs@ntp.isc.org accepted - html/ntpdc.html@1.20.1.3, 2006-02-24 02:08:16+00:00, rayvt@pogo.udel.edu +42 -11 + html/ntpdc.html@1.20.1.3 +42 -11 ntcdc options update - include/ntp.h@1.120.1.7, 2006-02-24 02:08:16+00:00, rayvt@pogo.udel.edu +1 -0 + include/ntp.h@1.120.1.7 +1 -0 ntcdc options update - include/ntp_request.h@1.23.1.1, 2006-02-24 02:08:16+00:00, rayvt@pogo.udel.edu +1 -0 + include/ntp_request.h@1.23.1.1 +1 -0 ntcdc options update - ntpd/ntp_loopfilter.c@1.123, 2006-02-24 02:08:16+00:00, rayvt@pogo.udel.edu +18 -0 + ntpd/ntp_loopfilter.c@1.123 +18 -0 ntcdc options update - ntpd/ntp_peer.c@1.84.1.2, 2006-02-24 02:08:16+00:00, rayvt@pogo.udel.edu +6 -1 + ntpd/ntp_peer.c@1.84.1.2 +6 -1 ntcdc options update - ntpdc/ntpdc.c@1.40.2.2, 2006-02-24 02:08:17+00:00, rayvt@pogo.udel.edu +8 -4 + ntpdc/ntpdc.c@1.40.2.2 +8 -4 ntcdc options update -ChangeSet@1.1251.72.23, 2006-02-22 20:01:03-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.23, 2006-02-22 20:01:03-05:00, stenn@deacon.udel.edu Fix a typo. - libntp/systime.c@1.37, 2006-02-22 20:00:33-05:00, stenn@deacon.udel.edu +1 -1 + libntp/systime.c@1.37 +1 -1 Fix a typo. -ChangeSet@1.1251.72.22, 2006-02-22 19:58:12-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.22, 2006-02-22 19:58:12-05:00, stenn@deacon.udel.edu Copyright updates from Dave Mills - html/copyright.html@1.33, 2006-02-22 19:57:52-05:00, stenn@deacon.udel.edu +2 -2 + html/copyright.html@1.33 +2 -2 Updates from Dave Mills -ChangeSet@1.1251.72.21, 2006-02-17 23:50:33-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.21, 2006-02-17 23:50:33-05:00, stenn@deacon.udel.edu Only fuzz the time after we know sys_precision (gettimeofday only) - libntp/systime.c@1.36, 2006-02-17 23:50:24-05:00, stenn@deacon.udel.edu +10 -2 + libntp/systime.c@1.36 +10 -2 Only fuzz the time after we know sys_precision (gettimeofday only) -ChangeSet@1.1251.72.20, 2006-02-15 23:21:06-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.72.20, 2006-02-15 23:21:06-05:00, mayer@pogo.udel.edu Fix next references for recvbuf - ntpd/ntpsim.c@1.11.1.1, 2006-02-15 23:20:23-05:00, mayer@pogo.udel.edu +4 -10 + ntpd/ntpsim.c@1.11.1.1 +4 -10 Fix next references for recvbuf -ChangeSet@1.1251.72.18, 2006-01-31 21:40:26-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.18, 2006-01-31 21:40:26-05:00, stenn@deacon.udel.edu Added the new RFC4330 spec (SNTP) - sntp/RFC4330.TXT@1.1, 2006-01-31 21:39:46-05:00, stenn@deacon.udel.edu +1515 -0 + sntp/RFC4330.TXT@1.1 +1515 -0 - sntp/RFC4330.TXT@1.0, 2006-01-31 21:39:46-05:00, stenn@deacon.udel.edu +0 -0 + sntp/RFC4330.TXT@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/sntp/RFC4330.TXT -ChangeSet@1.1178.5.8, 2006-01-26 22:18:41-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1178.5.8, 2006-01-26 22:18:41-05:00, stenn@deacon.udel.edu Make --enable-simulator part of the flock build - br-flock@1.4.1.1, 2006-01-26 22:18:24-05:00, stenn@deacon.udel.edu +1 -1 + br-flock@1.4.1.1 +1 -1 Make --enable-simulator part of the flock build - flock-build@1.30.2.1, 2006-01-26 22:18:24-05:00, stenn@deacon.udel.edu +7 -7 + flock-build@1.30.2.1 +7 -7 Make --enable-simulator part of the flock build -ChangeSet@1.1251.72.16, 2006-01-26 06:07:05+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.72.16, 2006-01-26 06:07:05+00:00, kardel@pogo.udel.edu refclock_parse.c: output errno on PPS setup failure - ntpd/refclock_parse.c@1.35.1.5, 2006-01-26 06:06:37+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/refclock_parse.c@1.35.1.5 +1 -1 output errno on PPS setup failure -ChangeSet@1.1251.72.15, 2006-01-23 01:55:53-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.72.15, 2006-01-23 01:55:53-05:00, stenn@deacon.udel.edu configure.ac: Cleanup from Ralf Wildenhues authopt.html: typo - configure.ac@1.359.1.27, 2006-01-23 01:55:36-05:00, stenn@deacon.udel.edu +4 -0 + configure.ac@1.359.1.27 +4 -0 Cleanup from Ralf Wildenhues - html/authopt.html@1.39, 2006-01-23 01:54:55-05:00, stenn@deacon.udel.edu +2 -2 + html/authopt.html@1.39 +2 -2 typo -ChangeSet@1.1328, 2006-01-23 01:20:16-05:00, stenn@pogo.udel.edu +12 -0 +ChangeSet@1.1328, 2006-01-23 01:20:16-05:00, stenn@pogo.udel.edu Cleanup from Ralf Wildenhues - include/ntp_stdlib.h@1.24, 2006-01-23 01:14:40-05:00, stenn@pogo.udel.edu +1 -1 + include/ntp_stdlib.h@1.24 +1 -1 const cleanup from Ralf Wildenhues - include/ntpd.h@1.90, 2006-01-23 01:14:40-05:00, stenn@pogo.udel.edu +2 -2 + include/ntpd.h@1.90 +2 -2 const cleanup from Ralf Wildenhues - libntp/ntp_rfc2553.c@1.28, 2006-01-23 01:15:49-05:00, stenn@pogo.udel.edu +1 -1 + libntp/ntp_rfc2553.c@1.28 +1 -1 lint cleanup from Ralf Wildenhues - ntpd/cmd_args.c@1.37, 2006-01-23 01:17:41-05:00, stenn@pogo.udel.edu +15 -15 + ntpd/cmd_args.c@1.37 +15 -15 const and lint cleanup from Ralf Wildenhues - ntpd/ntp_control.c@1.79.1.8, 2006-01-23 01:17:41-05:00, stenn@pogo.udel.edu +5 -1 + ntpd/ntp_control.c@1.79.1.8 +5 -1 const and lint cleanup from Ralf Wildenhues - ntpd/ntp_util.c@1.36.1.3, 2006-01-23 01:17:42-05:00, stenn@pogo.udel.edu +3 -3 + ntpd/ntp_util.c@1.36.1.3 +3 -3 const and lint cleanup from Ralf Wildenhues - ntpd/ntpd.c@1.74, 2006-01-23 01:17:43-05:00, stenn@pogo.udel.edu +8 -8 + ntpd/ntpd.c@1.74 +8 -8 const and lint cleanup from Ralf Wildenhues - ntpd/refclock_acts.c@1.26, 2006-01-23 01:17:43-05:00, stenn@pogo.udel.edu +1 -1 + ntpd/refclock_acts.c@1.26 +1 -1 const and lint cleanup from Ralf Wildenhues - ntpd/refclock_neoclock4x.c@1.14, 2006-01-23 01:17:44-05:00, stenn@pogo.udel.edu +1 -1 + ntpd/refclock_neoclock4x.c@1.14 +1 -1 const and lint cleanup from Ralf Wildenhues - ntpdc/ntpdc.c@1.46, 2006-01-23 01:18:43-05:00, stenn@pogo.udel.edu +2 -2 + ntpdc/ntpdc.c@1.46 +2 -2 const cleanup from Ralf Wildenhues - ntpq/ntpq.c@1.61, 2006-01-23 01:18:54-05:00, stenn@pogo.udel.edu +2 -2 + ntpq/ntpq.c@1.61 +2 -2 const cleanup from Ralf Wildenhues - util/ntp-keygen.c@1.37, 2006-01-23 01:19:17-05:00, stenn@pogo.udel.edu +1 -1 + util/ntp-keygen.c@1.37 +1 -1 lint cleanup from Ralf Wildenhues -ChangeSet@1.1251.72.13, 2006-01-23 00:47:20-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.13, 2006-01-23 00:47:20-05:00, stenn@deacon.udel.edu Fix from Dave Mills: etemp gets min(), not max() - ntpd/ntp_loopfilter.c@1.122, 2006-01-23 00:47:11-05:00, stenn@deacon.udel.edu +1 -1 + ntpd/ntp_loopfilter.c@1.122 +1 -1 Fix from Dave Mills: etemp gets min(), not max() -ChangeSet@1.1251.72.12, 2006-01-23 00:09:50-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.72.12, 2006-01-23 00:09:50-05:00, stenn@pogo.udel.edu Recover eaten patches - ntpd/ntpd.c@1.61.1.18, 2006-01-23 00:09:40-05:00, stenn@pogo.udel.edu +21 -0 + ntpd/ntpd.c@1.61.1.18 +21 -0 Recover eaten patches -ChangeSet@1.1251.74.11, 2006-01-22 15:58:25+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.74.11, 2006-01-22 15:58:25+00:00, kardel@pogo.udel.edu clk_rawdcf.c: update version information - libparse/clk_rawdcf.c@1.13, 2006-01-22 15:56:43+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_rawdcf.c@1.13 +6 -3 update version information -ChangeSet@1.1251.74.10, 2006-01-22 15:49:38+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.74.10, 2006-01-22 15:49:38+00:00, kardel@pogo.udel.edu clk_rawdcf.c: generate reasonable time code output on invalid input - libparse/clk_rawdcf.c@1.12, 2006-01-22 15:48:19+00:00, kardel@pogo.udel.edu +2 -2 + libparse/clk_rawdcf.c@1.12 +2 -2 generate reasonable time code output on invalid input -ChangeSet@1.1251.74.9, 2006-01-14 17:42:21-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.74.9, 2006-01-14 17:42:21-05:00, stenn@deacon.udel.edu Fixes from Dave Mills - ntpd/refclock_wwv.c@1.59, 2006-01-14 17:42:08-05:00, stenn@deacon.udel.edu +7 -4 + ntpd/refclock_wwv.c@1.59 +7 -4 Fixes from Dave Mills -ChangeSet@1.1325, 2006-01-12 18:52:24-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1325, 2006-01-12 18:52:24-05:00, stenn@pogo.udel.edu get libopts.m4 from libopts/m4 - Makefile.am@1.58, 2006-01-12 18:52:12-05:00, stenn@pogo.udel.edu +1 -1 + Makefile.am@1.58 +1 -1 get libopts.m4 from libopts/m4 - sntp/Makefile.am@1.12, 2006-01-12 18:52:13-05:00, stenn@pogo.udel.edu +1 -1 + sntp/Makefile.am@1.12 +1 -1 get libopts.m4 from libopts/m4 -ChangeSet@1.1324, 2006-01-12 18:23:36-05:00, stenn@pogo.udel.edu +3 -0 +ChangeSet@1.1324, 2006-01-12 18:23:36-05:00, stenn@pogo.udel.edu .del-libopts.m4~ebff9cfbfbe104c8: Delete: sntp/m4/libopts.m4 bootstrap: @@ -15619,954 +196386,954 @@ ChangeSet@1.1324, 2006-01-12 18:23:36-05:00, stenn@pogo.udel.edu +3 -0 Makefile.am: Get libopts.m4 from the sntp/m4 subdir - BitKeeper/deleted/.del-libopts.m4~ebff9cfbfbe104c8@1.7, 2006-01-12 18:22:02-05:00, stenn@pogo.udel.edu +97 -88 + BitKeeper/deleted/.del-libopts.m4~ebff9cfbfbe104c8@1.7 +97 -88 Delete: sntp/m4/libopts.m4 - Makefile.am@1.57, 2006-01-12 18:21:25-05:00, stenn@pogo.udel.edu +1 -1 + Makefile.am@1.57 +1 -1 Get libopts.m4 from the sntp/m4 subdir - bootstrap@1.8, 2006-01-12 18:21:48-05:00, stenn@pogo.udel.edu +0 -1 + bootstrap@1.8 +0 -1 Leave libopts.m4 in sntp/ -ChangeSet@1.1323, 2006-01-12 06:00:55-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1323, 2006-01-12 06:00:55-05:00, stenn@pogo.udel.edu libopts.m4 is in m4/ now - bootstrap@1.7, 2006-01-12 06:00:45-05:00, stenn@pogo.udel.edu +1 -1 + bootstrap@1.7 +1 -1 libopts.m4 is in m4/ now -ChangeSet@1.1319.1.1, 2006-01-12 04:36:58-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1319.1.1, 2006-01-12 04:36:58-05:00, stenn@pogo.udel.edu bootstrap wiggles - bootstrap@1.4.1.1, 2006-01-12 04:36:40-05:00, stenn@pogo.udel.edu +3 -1 + bootstrap@1.4.1.1 +3 -1 autoreconf in sntp first, and avoid -f -ChangeSet@1.1251.74.8, 2006-01-10 00:43:36-05:00, stenn@deacon.udel.edu +3 -0 +ChangeSet@1.1251.74.8, 2006-01-10 00:43:36-05:00, stenn@deacon.udel.edu doc changes from Dave Mills - html/authopt.html@1.38, 2006-01-10 00:43:14-05:00, stenn@deacon.udel.edu +4 -4 + html/authopt.html@1.38 +4 -4 doc changes from Dave Mills - html/copyright.html@1.32, 2006-01-10 00:43:14-05:00, stenn@deacon.udel.edu +1 -1 + html/copyright.html@1.32 +1 -1 doc changes from Dave Mills - html/miscopt.html@1.33, 2006-01-10 00:43:14-05:00, stenn@deacon.udel.edu +2 -3 + html/miscopt.html@1.33 +2 -3 doc changes from Dave Mills -ChangeSet@1.1251.74.7, 2006-01-10 00:34:58-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.74.7, 2006-01-10 00:34:58-05:00, stenn@deacon.udel.edu Fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.121, 2006-01-10 00:34:48-05:00, stenn@deacon.udel.edu +72 -48 + ntpd/ntp_loopfilter.c@1.121 +72 -48 Fixes from Dave Mills - ntpd/ntp_proto.c@1.232.1.16, 2006-01-10 00:34:48-05:00, stenn@deacon.udel.edu +0 -1 + ntpd/ntp_proto.c@1.232.1.16 +0 -1 Fixes from Dave Mills -ChangeSet@1.1251.76.3, 2006-01-09 17:55:37-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.76.3, 2006-01-09 17:55:37-05:00, mayer@pogo.udel.edu Set multicast interface to ignore packets from self - ntpd/ntp_io.c@1.187.1.7, 2006-01-09 17:54:50-05:00, mayer@pogo.udel.edu +24 -0 + ntpd/ntp_io.c@1.187.1.7 +24 -0 Set multicast interface to ignore packets from self -ChangeSet@1.1251.76.1, 2006-01-06 16:49:43-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.76.1, 2006-01-06 16:49:43-05:00, mayer@pogo.udel.edu Fix to have completion ports behave properly - ports/winnt/include/ntp_iocompletionport.h@1.12, 2006-01-06 16:47:39-05:00, mayer@pogo.udel.edu +0 -19 + ports/winnt/include/ntp_iocompletionport.h@1.12 +0 -19 - ports/winnt/ntpd/ntp_iocompletionport.c@1.20, 2006-01-06 16:48:00-05:00, mayer@pogo.udel.edu +150 -115 + ports/winnt/ntpd/ntp_iocompletionport.c@1.20 +150 -115 -ChangeSet@1.1320, 2005-12-30 16:09:52-08:00, bkorb@bach.veritas.com +8 -0 +ChangeSet@1.1320, 2005-12-30 16:09:52-08:00, bkorb@bach.veritas.com Warning patrol, mostly. Also ensure that $(top_srcdir)/version is built in those subdirectories that need it. - bootstrap@1.5, 2005-12-30 16:09:50-08:00, bkorb@bach.veritas.com +1 -1 + bootstrap@1.5 +1 -1 Correct the directory where the libopts.m4 file is found - include/debug-opt.def@1.2, 2005-12-30 16:09:51-08:00, bkorb@bach.veritas.com +8 -0 + include/debug-opt.def@1.2 +8 -0 The -D option requires "atoi(3C)". Ensure it is declared. Don't know if ``#ifdef __windows'' is the right guard. Someone needs to correct it.... - ntpd/Makefile.am@1.46, 2005-12-30 16:09:51-08:00, bkorb@bach.veritas.com +3 -0 + ntpd/Makefile.am@1.46 +3 -0 The various subdirectories seem to need a rule for making ../version. Provide it by invoking ``$(MAKE) version'' in that directory. - ntpd/cmd_args.c@1.36, 2005-12-30 16:09:51-08:00, bkorb@bach.veritas.com +1 -0 + ntpd/cmd_args.c@1.36 +1 -0 Declare global variable - ntpd/ntpd.c@1.72, 2005-12-30 16:09:51-08:00, bkorb@bach.veritas.com +11 -11 + ntpd/ntpd.c@1.72 +11 -11 Correct "const char" usage. Also, disambiguate local "ntp_optarg" from a global - ntpdate/Makefile.am@1.14, 2005-12-30 16:09:51-08:00, bkorb@bach.veritas.com +3 -0 + ntpdate/Makefile.am@1.14 +3 -0 The various subdirectories seem to need a rule for making ../version. Provide it by invoking ``$(MAKE) version'' in that directory. - ntpdc/Makefile.am@1.28, 2005-12-30 16:09:51-08:00, bkorb@bach.veritas.com +3 -0 + ntpdc/Makefile.am@1.28 +3 -0 The various subdirectories seem to need a rule for making ../version. Provide it by invoking ``$(MAKE) version'' in that directory. - ntpq/Makefile.am@1.20, 2005-12-30 16:09:51-08:00, bkorb@bach.veritas.com +3 -0 + ntpq/Makefile.am@1.20 +3 -0 The various subdirectories seem to need a rule for making ../version. Provide it by invoking ``$(MAKE) version'' in that directory. -ChangeSet@1.1251.74.6, 2005-12-30 14:50:03-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.74.6, 2005-12-30 14:50:03-05:00, stenn@pogo.udel.edu [Bug 545] Provide needed headers to test for sys/timepps.h - configure.ac@1.359.1.26, 2005-12-30 14:49:50-05:00, stenn@pogo.udel.edu +16 -2 + configure.ac@1.359.1.26 +16 -2 [Bug 545] Provide needed headers to test for sys/timepps.h -ChangeSet@1.1319, 2005-12-30 14:07:38-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1319, 2005-12-30 14:07:38-05:00, stenn@pogo.udel.edu verbose bootstrap, lose m4/libopts.m4 - BitKeeper/deleted/.del-libopts.m4~9f04cbceeedbd0cf@1.10, 2005-12-30 14:06:59-05:00, stenn@pogo.udel.edu +97 -88 + BitKeeper/deleted/.del-libopts.m4~9f04cbceeedbd0cf@1.10 +97 -88 Delete: m4/libopts.m4 - bootstrap@1.4, 2005-12-30 14:07:15-05:00, stenn@pogo.udel.edu +3 -2 + bootstrap@1.4 +3 -2 be verbose -ChangeSet@1.1318, 2005-12-29 01:38:14-05:00, stenn@pogo.udel.edu +4 -0 +ChangeSet@1.1318, 2005-12-29 01:38:14-05:00, stenn@pogo.udel.edu wiggles - BitKeeper/deleted/.del-version.m4~4ef47e5fd0c38ddb@1.4, 2005-12-29 01:36:03-05:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-version.m4~4ef47e5fd0c38ddb@1.4 +0 -0 Delete: version.m4 - Makefile.am@1.56, 2005-12-29 01:37:08-05:00, stenn@pogo.udel.edu +16 -1 + Makefile.am@1.56 +16 -1 wiggles - bootstrap@1.3, 2005-12-29 01:37:08-05:00, stenn@pogo.udel.edu +2 -20 + bootstrap@1.3 +2 -20 wiggles - packageinfo.sh@1.1, 2005-12-29 01:35:53-05:00, stenn@pogo.udel.edu +1 -0 + packageinfo.sh@1.1 +1 -0 - packageinfo.sh@1.0, 2005-12-29 01:35:53-05:00, stenn@pogo.udel.edu +0 -0 + packageinfo.sh@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/packageinfo.sh -ChangeSet@1.1251.74.5, 2005-12-27 19:50:58-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.74.5, 2005-12-27 19:50:58-05:00, stenn@deacon.udel.edu [Bug 543] Leap second warning in ONCORE driver, from Luis Batanero Guerrero - ntpd/refclock_oncore.c@1.54, 2005-12-27 19:50:08-05:00, stenn@deacon.udel.edu +12 -12 + ntpd/refclock_oncore.c@1.54 +12 -12 [Bug 543] Leap second warning in ONCORE driver, from Luis Batanero Guerrero -ChangeSet@1.1251.74.4, 2005-12-25 00:24:24-05:00, stenn@pogo.udel.edu +3 -0 +ChangeSet@1.1251.74.4, 2005-12-25 00:24:24-05:00, stenn@pogo.udel.edu [Bug 536] more filegen cleanup - include/ntp_filegen.h@1.3, 2005-12-25 00:23:31-05:00, stenn@pogo.udel.edu +1 -1 + include/ntp_filegen.h@1.3 +1 -1 [Bug 536] more filegen cleanup - ntpd/ntp_filegen.c@1.11, 2005-12-25 00:23:38-05:00, stenn@pogo.udel.edu +24 -1 + ntpd/ntp_filegen.c@1.11 +24 -1 [Bug 536] more filegen cleanup - ntpd/ntp_util.c@1.36.1.2, 2005-12-25 00:23:39-05:00, stenn@pogo.udel.edu +6 -30 + ntpd/ntp_util.c@1.36.1.2 +6 -30 [Bug 536] more filegen cleanup -ChangeSet@1.1316, 2005-12-23 13:56:31-08:00, bkorb@bach.veritas.com +51 -0 +ChangeSet@1.1316, 2005-12-23 13:56:31-08:00, bkorb@bach.veritas.com Extract the debug options into a separate file included by all the option files. Place the file in the "include" directory. Modify the makefiles so autogen adds that directory to its search list. - BitKeeper/deleted/.del-COPYING.lgpl~a697cd34fe132e8a@1.2, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-COPYING.lgpl~a697cd34fe132e8a@1.2 +0 -0 Delete: sntp/libopts/COPYING.lgpl - BitKeeper/deleted/.del-COPYING.mbsd~bfae58672feaeb37@1.2, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-COPYING.mbsd~bfae58672feaeb37@1.2 +0 -0 Delete: sntp/libopts/COPYING.mbsd - BitKeeper/deleted/.del-MakeDefs.inc~5e2e772dad68df1a@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-MakeDefs.inc~5e2e772dad68df1a@1.3 +0 -0 Delete: sntp/libopts/MakeDefs.inc - BitKeeper/deleted/.del-Makefile.am~6d6a227df4a598ae@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-Makefile.am~6d6a227df4a598ae@1.3 +0 -0 Delete: sntp/libopts/Makefile.am - BitKeeper/deleted/.del-README~e3d36052eb50258b@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-README~e3d36052eb50258b@1.3 +0 -0 Delete: sntp/libopts/README - BitKeeper/deleted/.del-autoopts.c~85fbb1bcfe1504ac@1.4, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-autoopts.c~85fbb1bcfe1504ac@1.4 +0 -0 Delete: sntp/libopts/autoopts.c - BitKeeper/deleted/.del-autoopts.h~4c10cd8f919f6342@1.5, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-autoopts.h~4c10cd8f919f6342@1.5 +0 -0 Delete: sntp/libopts/autoopts.h - BitKeeper/deleted/.del-boolean.c~2a088bf49e080afe@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-boolean.c~2a088bf49e080afe@1.3 +0 -0 Delete: sntp/libopts/boolean.c - BitKeeper/deleted/.del-compat.h~1cf561c3e113254d@1.7, 2005-12-23 12:11:25-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-compat.h~1cf561c3e113254d@1.7 +0 -0 Delete: sntp/libopts/compat/compat.h - BitKeeper/deleted/.del-configfile.c~bd820799c8dfa50e@1.2, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-configfile.c~bd820799c8dfa50e@1.2 +0 -0 Delete: sntp/libopts/configfile.c - BitKeeper/deleted/.del-cook.c~3fdbc751394ee14d@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-cook.c~3fdbc751394ee14d@1.3 +0 -0 Delete: sntp/libopts/cook.c - BitKeeper/deleted/.del-enumeration.c~e0416dead0d88f06@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-enumeration.c~e0416dead0d88f06@1.3 +0 -0 Delete: sntp/libopts/enumeration.c - BitKeeper/deleted/.del-environment.c~abe99889ca57817e@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-environment.c~abe99889ca57817e@1.3 +0 -0 Delete: sntp/libopts/environment.c - BitKeeper/deleted/.del-genshell.c~9d621c66b4bd754@1.5, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-genshell.c~9d621c66b4bd754@1.5 +0 -0 Delete: sntp/libopts/genshell.c - BitKeeper/deleted/.del-genshell.h~f5d1af5bffb3ba@1.5, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-genshell.h~f5d1af5bffb3ba@1.5 +0 -0 Delete: sntp/libopts/genshell.h - BitKeeper/deleted/.del-libopts.c~f2125365b6c69db9@1.4, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-libopts.c~f2125365b6c69db9@1.4 +0 -0 Delete: sntp/libopts/libopts.c - BitKeeper/deleted/.del-libopts.m4~11b56b285499781a@1.5, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-libopts.m4~11b56b285499781a@1.5 +0 -0 Delete: sntp/libopts/libopts.m4 - BitKeeper/deleted/.del-load.c~c55b985b7f4e79cc@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-load.c~c55b985b7f4e79cc@1.3 +0 -0 Delete: sntp/libopts/load.c - BitKeeper/deleted/.del-makeshell.c~4e0d2f7e41c164dc@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-makeshell.c~4e0d2f7e41c164dc@1.3 +0 -0 Delete: sntp/libopts/makeshell.c - BitKeeper/deleted/.del-nested.c~2ab62bdc3ff6240d@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-nested.c~2ab62bdc3ff6240d@1.3 +0 -0 Delete: sntp/libopts/nested.c - BitKeeper/deleted/.del-numeric.c~6f61173230495e21@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-numeric.c~6f61173230495e21@1.3 +0 -0 Delete: sntp/libopts/numeric.c - BitKeeper/deleted/.del-options.h~4ef9db18f2de6a59@1.4, 2005-12-23 12:11:19-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-options.h~4ef9db18f2de6a59@1.4 +0 -0 Delete: sntp/libopts/autoopts/options.h - BitKeeper/deleted/.del-pathfind.c~4d249636f5082615@1.2, 2005-12-23 12:11:25-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-pathfind.c~4d249636f5082615@1.2 +0 -0 Delete: sntp/libopts/compat/pathfind.c - BitKeeper/deleted/.del-pgusage.c~7d50638aa3ccd579@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-pgusage.c~7d50638aa3ccd579@1.3 +0 -0 Delete: sntp/libopts/pgusage.c - BitKeeper/deleted/.del-proto.h~93d0676a173a4b6e@1.5, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-proto.h~93d0676a173a4b6e@1.5 +0 -0 Delete: sntp/libopts/proto.h - BitKeeper/deleted/.del-putshell.c~8fdade676545e0ad@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-putshell.c~8fdade676545e0ad@1.3 +0 -0 Delete: sntp/libopts/putshell.c - BitKeeper/deleted/.del-restore.c~2d36a183c65e46b2@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-restore.c~2d36a183c65e46b2@1.3 +0 -0 Delete: sntp/libopts/restore.c - BitKeeper/deleted/.del-save.c~1e35dba6263bdb0@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-save.c~1e35dba6263bdb0@1.3 +0 -0 Delete: sntp/libopts/save.c - BitKeeper/deleted/.del-snprintf.c~34bb5dbb6f424fa4@1.2, 2005-12-23 12:11:25-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-snprintf.c~34bb5dbb6f424fa4@1.2 +0 -0 Delete: sntp/libopts/compat/snprintf.c - BitKeeper/deleted/.del-sort.c~f2dbbab8aecd13de@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-sort.c~f2dbbab8aecd13de@1.3 +0 -0 Delete: sntp/libopts/sort.c - BitKeeper/deleted/.del-stack.c~66471a39d92bf493@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-stack.c~66471a39d92bf493@1.3 +0 -0 Delete: sntp/libopts/stack.c - BitKeeper/deleted/.del-strdup.c~1ff3ed47354b9cab@1.2, 2005-12-23 12:11:25-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-strdup.c~1ff3ed47354b9cab@1.2 +0 -0 Delete: sntp/libopts/compat/strdup.c - BitKeeper/deleted/.del-streqvcmp.c~7d82b266e654e41f@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-streqvcmp.c~7d82b266e654e41f@1.3 +0 -0 Delete: sntp/libopts/streqvcmp.c - BitKeeper/deleted/.del-text_mmap.c~75102303341e937b@1.4, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-text_mmap.c~75102303341e937b@1.4 +0 -0 Delete: sntp/libopts/text_mmap.c - BitKeeper/deleted/.del-tokenize.c~f26cbe6a73d13566@1.2, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-tokenize.c~f26cbe6a73d13566@1.2 +0 -0 Delete: sntp/libopts/tokenize.c - BitKeeper/deleted/.del-usage-txt.h~e22bfd18a5765c49@1.5, 2005-12-23 12:11:19-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-usage-txt.h~e22bfd18a5765c49@1.5 +0 -0 Delete: sntp/libopts/autoopts/usage-txt.h - BitKeeper/deleted/.del-usage.c~ce3b6af7dd1009cc@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-usage.c~ce3b6af7dd1009cc@1.3 +0 -0 Delete: sntp/libopts/usage.c - BitKeeper/deleted/.del-version.c~bf32cf48f59dabf1@1.3, 2005-12-23 12:11:02-08:00, bkorb@bach.veritas.com +0 -0 + BitKeeper/deleted/.del-version.c~bf32cf48f59dabf1@1.3 +0 -0 Delete: sntp/libopts/version.c - BitKeeper/etc/logging_ok@1.57.2.1, 2005-12-23 13:56:31-08:00, bkorb@bach.veritas.com +1 -0 + BitKeeper/etc/logging_ok@1.57.2.1 +1 -0 Logging to repologs@ntp.isc.org accepted - Makefile.am@1.55, 2005-12-23 12:17:32-08:00, bkorb@bach.veritas.com +1 -16 + Makefile.am@1.55 +1 -16 Move some commands out into the bootstrap script - bootstrap@1.2, 2005-12-23 12:17:54-08:00, bkorb@bach.veritas.com +12 -0 + bootstrap@1.2 +12 -0 Add in the commands that were part of Makefile.am - bootstrap@1.1, 2005-12-23 10:56:19-08:00, bkorb@bach.veritas.com +61 -0 + bootstrap@1.1 +61 -0 - bootstrap@1.0, 2005-12-23 10:56:19-08:00, bkorb@bach.veritas.com +0 -0 + bootstrap@1.0 +0 -0 BitKeeper file /home/bkorb/tools/ntp/ntp-dev-ag/bootstrap - include/debug-opt.def@1.1, 2005-12-23 10:56:50-08:00, bkorb@bach.veritas.com +24 -0 + include/debug-opt.def@1.1 +24 -0 - include/debug-opt.def@1.0, 2005-12-23 10:56:50-08:00, bkorb@bach.veritas.com +0 -0 + include/debug-opt.def@1.0 +0 -0 BitKeeper file /home/bkorb/tools/ntp/ntp-dev-ag/include/debug-opt.def - ntpd/Makefile.am@1.45, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +7 -8 + ntpd/Makefile.am@1.45 +7 -8 Option def files must include from the ntp/include directory. - ntpd/ntpdbase-opts.def@1.2, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +1 -24 + ntpd/ntpdbase-opts.def@1.2 +1 -24 Move debug options to common file. - ntpdc/Makefile.am@1.27, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +4 -5 + ntpdc/Makefile.am@1.27 +4 -5 Option def files must include from the ntp/include directory. - ntpdc/ntpdc-opts.def@1.6, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +1 -24 + ntpdc/ntpdc-opts.def@1.6 +1 -24 Move debug options to a common file. - ntpq/Makefile.am@1.19, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +4 -5 + ntpq/Makefile.am@1.19 +4 -5 Option def files must include from the ntp/include directory. - sntp/Makefile.am@1.11, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +4 -4 + sntp/Makefile.am@1.11 +4 -4 Option def files must include from the ntp/include directory. - util/Makefile.am@1.29, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +4 -4 + util/Makefile.am@1.29 +4 -4 When building option source, be sure to look in the include file for the debug option file. - util/ntp-keygen-opts.def@1.2, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +3 -27 + util/ntp-keygen-opts.def@1.2 +3 -27 Move debug options to a common file. - util/ntp-keygen.c@1.36, 2005-12-23 13:55:50-08:00, bkorb@bach.veritas.com +8 -39 + util/ntp-keygen.c@1.36 +8 -39 Remove some confusing #ifdef's and replace "iffsw" with "HAVE_OPT(ID_KEY)". -ChangeSet@1.1251.71.10, 2005-12-20 23:14:56-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.71.10, 2005-12-20 23:14:56-05:00, stenn@pogo.udel.edu bail early from get_full_recv_buffer() if there is nothing to do. - libntp/recvbuff.c@1.18, 2005-12-20 23:14:18-05:00, stenn@pogo.udel.edu +3 -0 + libntp/recvbuff.c@1.18 +3 -0 bail early from get_full_recv_buffer() if there is nothing to do. -ChangeSet@1.1251.72.5, 2005-12-20 22:09:09-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.72.5, 2005-12-20 22:09:09-05:00, mayer@pogo.udel.edu Fix recvbuff code with missing refetch when needing more buffers - libntp/recvbuff.c@1.13.1.2, 2005-12-20 22:08:49-05:00, mayer@pogo.udel.edu +10 -5 + libntp/recvbuff.c@1.13.1.2 +10 -5 Fix recvbuff code with missing refetch when needing more buffers -ChangeSet@1.1178.5.7, 2005-12-20 22:05:18-05:00, stenn@deacon.udel.edu +6 -0 +ChangeSet@1.1178.5.7, 2005-12-20 22:05:18-05:00, stenn@deacon.udel.edu Send email to ntp.isc.org now - BitKeeper/triggers/changelog@1.3, 2005-12-20 22:04:44-05:00, stenn@deacon.udel.edu +1 -1 + BitKeeper/triggers/changelog@1.3 +1 -1 Send email to ntp.isc.org now - BitKeeper/triggers/commitlogs@1.5, 2005-12-20 22:04:45-05:00, stenn@deacon.udel.edu +2 -1 + BitKeeper/triggers/commitlogs@1.5 +2 -1 Send email to ntp.isc.org now - BitKeeper/triggers/delta-changelog@1.7, 2005-12-20 22:04:45-05:00, stenn@deacon.udel.edu +2 -2 + BitKeeper/triggers/delta-changelog@1.7 +2 -2 Send email to ntp.isc.org now - BitKeeper/triggers/notify@1.3, 2005-12-20 22:04:46-05:00, stenn@deacon.udel.edu +2 -1 + BitKeeper/triggers/notify@1.3 +2 -1 Send email to ntp.isc.org now - BitKeeper/triggers/paranoid@1.3, 2005-12-20 22:04:46-05:00, stenn@deacon.udel.edu +1 -1 + BitKeeper/triggers/paranoid@1.3 +1 -1 Send email to ntp.isc.org now - BitKeeper/triggers/send@1.5, 2005-12-20 22:04:46-05:00, stenn@deacon.udel.edu +1 -1 + BitKeeper/triggers/send@1.5 +1 -1 Send email to ntp.isc.org now -ChangeSet@1.1251.74.2, 2005-12-20 21:46:45-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1251.74.2, 2005-12-20 21:46:45-05:00, stenn@pogo.udel.edu [Bug 536] Clean up the filegen initialization - ntpd/ntp_filegen.c@1.10, 2005-12-20 21:33:19-05:00, stenn@pogo.udel.edu +2 -1 + ntpd/ntp_filegen.c@1.10 +2 -1 reformat comment - ntpd/ntp_util.c@1.36.1.1, 2005-12-20 21:46:11-05:00, stenn@pogo.udel.edu +36 -71 + ntpd/ntp_util.c@1.36.1.1 +36 -71 [Bug 536] Clean up the filegen initialization -ChangeSet@1.1251.74.1, 2005-12-20 18:30:52-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.74.1, 2005-12-20 18:30:52-05:00, stenn@pogo.udel.edu Tolerate leap second notifications in sntp - sntp/main.c@1.6, 2005-12-20 18:30:44-05:00, stenn@pogo.udel.edu +4 -3 + sntp/main.c@1.6 +4 -3 Tolerate leap second notifications in sntp -ChangeSet@1.1251.73.4, 2005-12-20 09:26:06-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.73.4, 2005-12-20 09:26:06-05:00, mayer@pogo.udel.edu Update the way packets are processed - ntpd/ntpd.c@1.61.4.1, 2005-12-20 09:25:53-05:00, mayer@pogo.udel.edu +8 -5 + ntpd/ntpd.c@1.61.4.1 +8 -5 Update the way packets are processed -ChangeSet@1.1251.73.3, 2005-12-20 09:25:05-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.73.3, 2005-12-20 09:25:05-05:00, mayer@pogo.udel.edu Bug #527 - Fix buffer problems when under load - ports/winnt/include/ntp_iocompletionport.h@1.11, 2005-12-20 09:23:36-05:00, mayer@pogo.udel.edu +1 -6 + ports/winnt/include/ntp_iocompletionport.h@1.11 +1 -6 Bug #527 - Fix buffer problems when under load - ports/winnt/ntpd/ntp_iocompletionport.c@1.19, 2005-12-20 09:23:36-05:00, mayer@pogo.udel.edu +150 -83 + ports/winnt/ntpd/ntp_iocompletionport.c@1.19 +150 -83 Bug #527 - Fix buffer problems when under load -ChangeSet@1.1251.72.3, 2005-12-19 18:12:59-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.72.3, 2005-12-19 18:12:59-05:00, stenn@deacon.udel.edu leap change notification cleanup from Dave Mills - ntpd/ntp_loopfilter.c@1.120, 2005-12-19 18:11:24-05:00, stenn@deacon.udel.edu +0 -8 + ntpd/ntp_loopfilter.c@1.120 +0 -8 leap change notification cleanup from Dave Mills -ChangeSet@1.1315, 2005-12-16 03:37:46-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1315, 2005-12-16 03:37:46-05:00, stenn@pogo.udel.edu Use AutoOpts - util/ntp-keygen.c@1.35, 2005-12-16 03:37:32-05:00, stenn@pogo.udel.edu +46 -172 + util/ntp-keygen.c@1.35 +46 -172 Use AutoOpts -ChangeSet@1.1314, 2005-12-15 06:34:59-05:00, stenn@pogo.udel.edu +9 -0 +ChangeSet@1.1314, 2005-12-15 06:34:59-05:00, stenn@pogo.udel.edu AutoGen stuff - m4/libopts.m4@1.9, 2005-12-15 06:33:50-05:00, stenn@pogo.udel.edu +15 -17 + m4/libopts.m4@1.9 +15 -17 AutoGen stuff - ntpd/Makefile.am@1.44, 2005-12-15 06:33:50-05:00, stenn@pogo.udel.edu +10 -10 + ntpd/Makefile.am@1.44 +10 -10 AutoGen stuff - ntpdc/Makefile.am@1.26, 2005-12-15 06:33:50-05:00, stenn@pogo.udel.edu +5 -5 + ntpdc/Makefile.am@1.26 +5 -5 AutoGen stuff - ntpq/Makefile.am@1.18, 2005-12-15 06:33:51-05:00, stenn@pogo.udel.edu +4 -4 + ntpq/Makefile.am@1.18 +4 -4 AutoGen stuff - sntp/Makefile.am@1.10, 2005-12-15 06:33:51-05:00, stenn@pogo.udel.edu +4 -4 + sntp/Makefile.am@1.10 +4 -4 AutoGen stuff - sntp/libopts/compat/compat.h@1.6, 2005-12-15 06:33:51-05:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/compat/compat.h@1.6 +1 -1 AutoGen stuff - sntp/libopts/compat/snprintf.c@1.1, 2005-12-15 06:32:56-05:00, stenn@pogo.udel.edu +36 -0 + sntp/libopts/compat/snprintf.c@1.1 +36 -0 - sntp/libopts/compat/snprintf.c@1.0, 2005-12-15 06:32:56-05:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/compat/snprintf.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/compat/snprintf.c - sntp/libopts/compat/strdup.c@1.1, 2005-12-15 06:32:56-05:00, stenn@pogo.udel.edu +19 -0 + sntp/libopts/compat/strdup.c@1.1 +19 -0 - sntp/libopts/compat/strdup.c@1.0, 2005-12-15 06:32:56-05:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/compat/strdup.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/compat/strdup.c - sntp/m4/libopts.m4@1.6, 2005-12-15 06:33:51-05:00, stenn@pogo.udel.edu +15 -17 + sntp/m4/libopts.m4@1.6 +15 -17 AutoGen stuff -ChangeSet@1.1312, 2005-12-15 06:27:57-05:00, stenn@pogo.udel.edu +3 -0 +ChangeSet@1.1312, 2005-12-15 06:27:57-05:00, stenn@pogo.udel.edu ntp-keygen conversion from Bruce Korb - BitKeeper/etc/ignore@1.45, 2005-12-15 06:25:25-05:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/ignore@1.45 +1 -0 added util/ntp-keygen.1 - util/Makefile.am@1.26.1.1, 2005-12-15 06:27:29-05:00, stenn@pogo.udel.edu +21 -4 + util/Makefile.am@1.26.1.1 +21 -4 ntp-keygen conversion from Bruce Korb - util/ntp-keygen-opts.def@1.1, 2005-12-15 06:23:17-05:00, stenn@pogo.udel.edu +263 -0 + util/ntp-keygen-opts.def@1.1 +263 -0 - util/ntp-keygen-opts.def@1.0, 2005-12-15 06:23:17-05:00, stenn@pogo.udel.edu +0 -0 + util/ntp-keygen-opts.def@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/util/ntp-keygen-opts.def -ChangeSet@1.1251.71.9, 2005-12-13 05:22:27-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1251.71.9, 2005-12-13 05:22:27-05:00, stenn@pogo.udel.edu more full_recvbuf cleanup - libntp/recvbuff.c@1.17, 2005-12-13 05:22:14-05:00, stenn@pogo.udel.edu +2 -0 + libntp/recvbuff.c@1.17 +2 -0 more full_recvbuf cleanup - ntpd/ntpd.c@1.61.1.16, 2005-12-13 05:22:03-05:00, stenn@pogo.udel.edu +2 -3 + ntpd/ntpd.c@1.61.1.16 +2 -3 more full_recvbuf cleanup -ChangeSet@1.1251.71.8, 2005-12-13 04:01:10-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.71.8, 2005-12-13 04:01:10-05:00, stenn@pogo.udel.edu Only call get_full_recv_buffer() if we have something - ntpd/ntpd.c@1.61.1.15, 2005-12-13 04:00:42-05:00, stenn@pogo.udel.edu +12 -8 + ntpd/ntpd.c@1.61.1.15 +12 -8 Only call get_full_recv_buffer() if we have something -ChangeSet@1.1251.73.2, 2005-12-12 23:35:01-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.73.2, 2005-12-12 23:35:01-05:00, mayer@pogo.udel.edu Fixes for buffer loss and DOS attacks - ports/winnt/include/ntp_iocompletionport.h@1.10, 2005-12-12 23:34:36-05:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/include/ntp_iocompletionport.h@1.10 +1 -1 Fixes for buffer loss and DOS attacks - ports/winnt/ntpd/ntp_iocompletionport.c@1.18, 2005-12-12 23:34:36-05:00, mayer@pogo.udel.edu +5 -1 + ports/winnt/ntpd/ntp_iocompletionport.c@1.18 +5 -1 Fixes for buffer loss and DOS attacks -ChangeSet@1.1251.73.1, 2005-12-12 23:32:47-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.73.1, 2005-12-12 23:32:47-05:00, mayer@pogo.udel.edu Make recvbuf unlimited and add check for full buffers - include/recvbuff.h@1.11, 2005-12-12 23:31:40-05:00, mayer@pogo.udel.edu +6 -0 + include/recvbuff.h@1.11 +6 -0 Make recvbuf unlimited and add check for full buffers - libntp/recvbuff.c@1.13.1.1, 2005-12-12 23:31:40-05:00, mayer@pogo.udel.edu +24 -15 + libntp/recvbuff.c@1.13.1.1 +24 -15 Make recvbuf unlimited and add check for full buffers -ChangeSet@1.1251.72.2, 2005-12-11 18:54:45-05:00, stenn@deacon.udel.edu +5 -0 +ChangeSet@1.1251.72.2, 2005-12-11 18:54:45-05:00, stenn@deacon.udel.edu [Bug 531]: ntpdc limitations on addserver & addpeer (Ray Van Tassle) - html/ntpdc.html@1.20.1.2, 2005-12-11 18:51:32-05:00, stenn@deacon.udel.edu +27 -5 + html/ntpdc.html@1.20.1.2 +27 -5 [Bug 531]: ntpdc limitations on addserver & addpeer (Ray Van Tassle) - ntpd/ntp_request.c@1.58.1.1, 2005-12-11 18:53:37-05:00, stenn@deacon.udel.edu +23 -5 + ntpd/ntp_request.c@1.58.1.1 +23 -5 [Bug 531]: ntpdc limitations on addserver & addpeer (Ray Van Tassle) - ntpdc/ntpdc.c@1.40.2.1, 2005-12-11 18:51:45-05:00, stenn@deacon.udel.edu +15 -0 + ntpdc/ntpdc.c@1.40.2.1 +15 -0 [Bug 531]: ntpdc limitations on addserver & addpeer (Ray Van Tassle) - ntpdc/ntpdc.h@1.5, 2005-12-11 18:51:46-05:00, stenn@deacon.udel.edu +2 -2 + ntpdc/ntpdc.h@1.5 +2 -2 [Bug 531]: ntpdc limitations on addserver & addpeer (Ray Van Tassle) - ntpdc/ntpdc_ops.c@1.38.1.1, 2005-12-11 18:51:47-05:00, stenn@deacon.udel.edu +4 -2 + ntpdc/ntpdc_ops.c@1.38.1.1 +4 -2 [Bug 531]: ntpdc limitations on addserver & addpeer (Ray Van Tassle) -ChangeSet@1.1251.71.6, 2005-12-11 17:16:25-05:00, stenn@maccarony.ntp.org +1 -0 +ChangeSet@1.1251.71.6, 2005-12-11 17:16:25-05:00, stenn@maccarony.ntp.org diagnostic cleanup - libntp/recvbuff.c@1.15, 2005-12-11 17:16:16-05:00, stenn@maccarony.ntp.org +2 -3 + libntp/recvbuff.c@1.15 +2 -3 diagnostic cleanup -ChangeSet@1.1251.71.5, 2005-12-11 17:04:21-05:00, stenn@maccarony.ntp.org +3 -0 +ChangeSet@1.1251.71.5, 2005-12-11 17:04:21-05:00, stenn@maccarony.ntp.org recvbuf typo fix and diagnostics - BitKeeper/etc/logging_ok@1.55.1.2, 2005-12-11 17:04:20-05:00, stenn@maccarony.ntp.org +1 -0 + BitKeeper/etc/logging_ok@1.55.1.2 +1 -0 Logging to repologs@ntp.isc.org accepted - libntp/recvbuff.c@1.14, 2005-12-11 17:02:36-05:00, stenn@maccarony.ntp.org +10 -2 + libntp/recvbuff.c@1.14 +10 -2 full_recvbuf diagnostics - ntpd/ntpd.c@1.61.1.14, 2005-12-11 17:03:33-05:00, stenn@maccarony.ntp.org +1 -1 + ntpd/ntpd.c@1.61.1.14 +1 -1 Danny's typo fix for checking tot_full_recvbufs -ChangeSet@1.1251.71.4, 2005-12-10 23:49:14-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.71.4, 2005-12-10 23:49:14-05:00, mayer@pogo.udel.edu revbuf rewrite - libntp/recvbuff.c@1.13, 2005-12-10 23:48:53-05:00, mayer@pogo.udel.edu +26 -11 + libntp/recvbuff.c@1.13 +26 -11 revbuf rewrite - ntpd/ntp_io.c@1.187.1.6, 2005-12-10 23:48:53-05:00, mayer@pogo.udel.edu +48 -8 + ntpd/ntp_io.c@1.187.1.6 +48 -8 revbuf rewrite -ChangeSet@1.1251.72.1, 2005-12-07 23:23:03-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.72.1, 2005-12-07 23:23:03-05:00, stenn@deacon.udel.edu cleanup from Dave Mills - ntpd/refclock_irig.c@1.22, 2005-12-07 23:21:50-05:00, stenn@deacon.udel.edu +3 -4 + ntpd/refclock_irig.c@1.22 +3 -4 cleanup from Dave Mills - ntpd/refclock_wwv.c@1.58, 2005-12-07 23:22:01-05:00, stenn@deacon.udel.edu +11 -0 + ntpd/refclock_wwv.c@1.58 +11 -0 cleanup from Dave Mills -ChangeSet@1.1251.1.178, 2005-12-05 18:36:24-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.178, 2005-12-05 18:36:24-05:00, stenn@pogo.udel.edu tg cleanup - util/tg.c@1.3, 2005-12-05 18:35:58-05:00, stenn@pogo.udel.edu +1 -0 + util/tg.c@1.3 +1 -0 tg cleanup -ChangeSet@1.1251.67.29, 2005-12-05 17:37:57-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.67.29, 2005-12-05 17:37:57-05:00, stenn@deacon.udel.edu Added 'tg' - util/Makefile.am@1.27, 2005-12-05 17:37:21-05:00, stenn@deacon.udel.edu +1 -1 + util/Makefile.am@1.27 +1 -1 Added 'tg' - util/tg.c@1.2, 2005-12-05 17:35:32-05:00, stenn@deacon.udel.edu +5 -4 + util/tg.c@1.2 +5 -4 cleanup - util/tg.c@1.1, 2005-12-05 16:03:46-05:00, stenn@deacon.udel.edu +650 -0 + util/tg.c@1.1 +650 -0 - util/tg.c@1.0, 2005-12-05 16:03:46-05:00, stenn@deacon.udel.edu +0 -0 + util/tg.c@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/util/tg.c -ChangeSet@1.1251.67.28, 2005-12-05 04:55:50-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.67.28, 2005-12-05 04:55:50-05:00, stenn@deacon.udel.edu leap second stuff from Dave Mills - ntpd/ntp_loopfilter.c@1.119, 2005-12-05 03:43:10-05:00, stenn@deacon.udel.edu +11 -11 + ntpd/ntp_loopfilter.c@1.119 +11 -11 leap second stuff from Dave Mills - ntpd/refclock_wwv.c@1.57, 2005-12-05 03:43:34-05:00, stenn@deacon.udel.edu +8 -6 + ntpd/refclock_wwv.c@1.57 +8 -6 leap second stuff from Dave Mills -ChangeSet@1.1251.67.27, 2005-11-28 20:54:35-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.27, 2005-11-28 20:54:35-05:00, stenn@deacon.udel.edu WWV doc updates from Dave Mills - html/drivers/driver36.html@1.27, 2005-11-28 20:54:02-05:00, stenn@deacon.udel.edu +14 -22 + html/drivers/driver36.html@1.27 +14 -22 WWV doc updates from Dave Mills -ChangeSet@1.1251.71.3, 2005-11-27 18:35:43-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.71.3, 2005-11-27 18:35:43-05:00, mayer@pogo.udel.edu Name the timer event - ports/winnt/ntpd/nt_clockstuff.c@1.19, 2005-11-27 18:35:26-05:00, mayer@pogo.udel.edu +2 -2 + ports/winnt/ntpd/nt_clockstuff.c@1.19 +2 -2 Name the timer event -ChangeSet@1.1251.71.2, 2005-11-27 18:33:06-05:00, mayer@pogo.udel.edu +9 -0 +ChangeSet@1.1251.71.2, 2005-11-27 18:33:06-05:00, mayer@pogo.udel.edu Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - include/recvbuff.h@1.10, 2005-11-27 18:32:24-05:00, mayer@pogo.udel.edu +6 -4 + include/recvbuff.h@1.10 +6 -4 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - libntp/recvbuff.c@1.12, 2005-11-27 18:32:24-05:00, mayer@pogo.udel.edu +48 -137 + libntp/recvbuff.c@1.12 +48 -137 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - ntpd/ntpd.c@1.61.1.13, 2005-11-27 18:32:24-05:00, mayer@pogo.udel.edu +8 -35 + ntpd/ntpd.c@1.61.1.13 +8 -35 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - ntpd/refclock_parse.c@1.35.1.4, 2005-11-27 18:32:24-05:00, mayer@pogo.udel.edu +0 -1 + ntpd/refclock_parse.c@1.35.1.4 +0 -1 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - ntpdate/ntpdate.c@1.55, 2005-11-27 18:32:25-05:00, mayer@pogo.udel.edu +8 -8 + ntpdate/ntpdate.c@1.55 +8 -8 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - ntpdate/ntptimeset.c@1.13, 2005-11-27 18:32:25-05:00, mayer@pogo.udel.edu +7 -13 + ntpdate/ntptimeset.c@1.13 +7 -13 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - ports/winnt/include/transmitbuff.h@1.5, 2005-11-27 18:32:25-05:00, mayer@pogo.udel.edu +7 -4 + ports/winnt/include/transmitbuff.h@1.5 +7 -4 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - ports/winnt/libntp/transmitbuff.c@1.6, 2005-11-27 18:32:25-05:00, mayer@pogo.udel.edu +56 -129 + ports/winnt/libntp/transmitbuff.c@1.6 +56 -129 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists - ports/winnt/ntpd/ntp_iocompletionport.c@1.17, 2005-11-27 18:32:25-05:00, mayer@pogo.udel.edu +45 -21 + ports/winnt/ntpd/ntp_iocompletionport.c@1.17 +45 -21 Upgrade recvbuf and transmitbuf to use ISC_LIST_* lists -ChangeSet@1.1251.70.1, 2005-11-27 18:23:40-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.70.1, 2005-11-27 18:23:40-05:00, mayer@pogo.udel.edu Removed setting next variable in recvbuff - ntpd/refclock_parse.c@1.35.2.1, 2005-11-27 18:22:58-05:00, mayer@pogo.udel.edu +185 -222 + ntpd/refclock_parse.c@1.35.2.1 +185 -222 Removed setting next variable in recvbuff -ChangeSet@1.1251.67.26, 2005-11-27 17:38:02-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.26, 2005-11-27 17:38:02-05:00, stenn@deacon.udel.edu WWV updates from Dave Mills - ntpd/refclock_wwv.c@1.56, 2005-11-27 17:37:30-05:00, stenn@deacon.udel.edu +329 -479 + ntpd/refclock_wwv.c@1.56 +329 -479 WWV updates from Dave Mills -ChangeSet@1.1251.67.25, 2005-11-15 04:55:14-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.25, 2005-11-15 04:55:14-05:00, stenn@deacon.udel.edu more tm_mon fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.118, 2005-11-15 04:55:02-05:00, stenn@deacon.udel.edu +3 -2 + ntpd/ntp_loopfilter.c@1.118 +3 -2 more tm_mon fixes from Dave Mills -ChangeSet@1.1251.69.1, 2005-11-09 22:13:13+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.69.1, 2005-11-09 22:13:13+00:00, kardel@pogo.udel.edu refclock_parse.c: utilize full PPS timestamp resolution from PPS API - ntpd/refclock_parse.c@1.35.1.2, 2005-11-09 21:00:26+00:00, kardel@pogo.udel.edu +23 -13 + ntpd/refclock_parse.c@1.35.1.2 +23 -13 utilize full PPS timestamp resolution from PPS API -ChangeSet@1.1251.67.22, 2005-11-09 00:32:54-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.67.22, 2005-11-09 00:32:54-05:00, stenn@deacon.udel.edu Documentation fixes from Dave Mills - html/authopt.html@1.37, 2005-11-09 00:32:40-05:00, stenn@deacon.udel.edu +10 -10 + html/authopt.html@1.37 +10 -10 Documentation fixes from Dave Mills - html/keygen.html@1.8, 2005-11-09 00:32:40-05:00, stenn@deacon.udel.edu +5 -5 + html/keygen.html@1.8 +5 -5 Documentation fixes from Dave Mills -ChangeSet@1.1251.68.1, 2005-11-08 09:15:35-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.68.1, 2005-11-08 09:15:35-05:00, mayer@pogo.udel.edu bug 495 - fix for multicasting and reuseaddr got lost - ntpd/ntp_io.c@1.187.1.5, 2005-11-08 09:15:02-05:00, mayer@pogo.udel.edu +6 -2 + ntpd/ntp_io.c@1.187.1.5 +6 -2 bug 495 - fix for multicasting and reuseaddr got lost -ChangeSet@1.1251.67.21, 2005-11-07 22:11:10-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.21, 2005-11-07 22:11:10-05:00, stenn@deacon.udel.edu [Bug 481] do not check $build paths for openssl if cross-compiling. Other $build/$host cleanup, too. - configure.ac@1.359.1.25, 2005-11-07 22:11:02-05:00, stenn@deacon.udel.edu +35 -20 + configure.ac@1.359.1.25 +35 -20 [Bug 481] do not check $build paths for openssl if cross-compiling. Other $build/$host cleanup, too. -ChangeSet@1.1251.67.20, 2005-11-07 03:15:55-05:00, stenn@deacon.udel.edu +10 -0 +ChangeSet@1.1251.67.20, 2005-11-07 03:15:55-05:00, stenn@deacon.udel.edu Fixes from Dave Mills - html/authopt.html@1.36, 2005-11-07 03:15:21-05:00, stenn@deacon.udel.edu +3 -4 + html/authopt.html@1.36 +3 -4 Fixes from Dave Mills - ntpd/ntp_config.c@1.129.4.2, 2005-11-07 03:13:23-05:00, stenn@deacon.udel.edu +4 -4 + ntpd/ntp_config.c@1.129.4.2 +4 -4 Fixes from Dave Mills - ntpd/ntp_control.c@1.79.1.7, 2005-11-07 03:13:23-05:00, stenn@deacon.udel.edu +2 -7 + ntpd/ntp_control.c@1.79.1.7 +2 -7 Fixes from Dave Mills - ntpd/ntp_crypto.c@1.98.1.10, 2005-11-07 03:13:23-05:00, stenn@deacon.udel.edu +12 -23 + ntpd/ntp_crypto.c@1.98.1.10 +12 -23 Fixes from Dave Mills - ntpd/ntp_refclock.c@1.74, 2005-11-07 03:13:24-05:00, stenn@deacon.udel.edu +2 -9 + ntpd/ntp_refclock.c@1.74 +2 -9 Fixes from Dave Mills - ntpd/refclock_atom.c@1.54, 2005-11-07 03:13:24-05:00, stenn@deacon.udel.edu +0 -5 + ntpd/refclock_atom.c@1.54 +0 -5 Fixes from Dave Mills - ntpd/refclock_fg.c@1.10, 2005-11-07 03:13:24-05:00, stenn@deacon.udel.edu +0 -3 + ntpd/refclock_fg.c@1.10 +0 -3 Fixes from Dave Mills - ntpd/refclock_local.c@1.15, 2005-11-07 03:13:24-05:00, stenn@deacon.udel.edu +1 -1 + ntpd/refclock_local.c@1.15 +1 -1 Fixes from Dave Mills - ntpd/refclock_wwv.c@1.55, 2005-11-07 03:13:24-05:00, stenn@deacon.udel.edu +36 -20 + ntpd/refclock_wwv.c@1.55 +36 -20 Fixes from Dave Mills - util/ntp-keygen.c@1.34, 2005-11-07 03:12:02-05:00, stenn@deacon.udel.edu +2 -2 + util/ntp-keygen.c@1.34 +2 -2 Fixes from Dave Mills -ChangeSet@1.1251.67.19, 2005-11-06 17:15:15-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.67.19, 2005-11-06 17:15:15-05:00, mayer@pogo.udel.edu Fixes from Heiko and Martin for ntpdate on Windows - ntpdate/ntpdate.c@1.54, 2005-11-06 17:14:04-05:00, mayer@pogo.udel.edu +47 -6 + ntpdate/ntpdate.c@1.54 +47 -6 Fixes from Heiko and Martin for ntpdate on Windows -ChangeSet@1.1251.67.17, 2005-11-02 06:54:06-05:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.17, 2005-11-02 06:54:06-05:00, stenn@deacon.udel.edu Updates from Dave Mills - html/authopt.html@1.35, 2005-11-02 06:53:56-05:00, stenn@deacon.udel.edu +5 -5 + html/authopt.html@1.35 +5 -5 Updates from Dave Mills -ChangeSet@1.1251.64.4, 2005-11-01 23:40:29-05:00, mayer@pogo.udel.edu +8 -0 +ChangeSet@1.1251.64.4, 2005-11-01 23:40:29-05:00, mayer@pogo.udel.edu Bug fixes to support IPv6 changes for non-IPv6 capable systems - include/isc/ipv6.h@1.7, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +2 -2 + include/isc/ipv6.h@1.7 +2 -2 Bug fixes to support IPv6 changes for non-IPv6 capable systems - include/isc/net.h@1.8, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +2 -2 + include/isc/net.h@1.8 +2 -2 Bug fixes to support IPv6 changes for non-IPv6 capable systems - include/ntp_machine.h@1.21, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +1 -0 + include/ntp_machine.h@1.21 +1 -0 Bug fixes to support IPv6 changes for non-IPv6 capable systems - include/ntp_rfc2553.h@1.28, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +21 -16 + include/ntp_rfc2553.h@1.28 +21 -16 Bug fixes to support IPv6 changes for non-IPv6 capable systems - libisc/net.c@1.7, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +0 -1 + libisc/net.c@1.7 +0 -1 Bug fixes to support IPv6 changes for non-IPv6 capable systems - libisc/sockaddr.c@1.5, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +2 -2 + libisc/sockaddr.c@1.5 +2 -2 Bug fixes to support IPv6 changes for non-IPv6 capable systems - libntp/ntp_rfc2553.c@1.27, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +7 -1 + libntp/ntp_rfc2553.c@1.27 +7 -1 Bug fixes to support IPv6 changes for non-IPv6 capable systems - ntpdate/ntpdate.c@1.53, 2005-11-01 23:40:06-05:00, mayer@pogo.udel.edu +41 -18 + ntpdate/ntpdate.c@1.53 +41 -18 Bug fixes to support IPv6 changes for non-IPv6 capable systems -ChangeSet@1.1251.67.16, 2005-10-31 05:26:54-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.67.16, 2005-10-31 05:26:54-05:00, stenn@deacon.udel.edu fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.117, 2005-10-31 05:25:49-05:00, stenn@deacon.udel.edu +10 -5 + ntpd/ntp_loopfilter.c@1.117 +10 -5 MOD_NANO fixes from Dave Mills - ntpd/refclock_wwv.c@1.54, 2005-10-31 05:26:37-05:00, stenn@deacon.udel.edu +1 -1 + ntpd/refclock_wwv.c@1.54 +1 -1 Bump MAXFREQ from 125 to 187 PPM, from Dave Mills -ChangeSet@1.1251.67.15, 2005-10-28 19:05:28-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.15, 2005-10-28 19:05:28-04:00, stenn@deacon.udel.edu Weed-whack NANO stuff from Dave Mills - ntpd/ntp_loopfilter.c@1.116, 2005-10-28 19:05:08-04:00, stenn@deacon.udel.edu +29 -22 + ntpd/ntp_loopfilter.c@1.116 +29 -22 Weed-whack NANO stuff from Dave Mills -ChangeSet@1.1251.67.14, 2005-10-27 22:12:21-04:00, stenn@deacon.udel.edu +4 -0 +ChangeSet@1.1251.67.14, 2005-10-27 22:12:21-04:00, stenn@deacon.udel.edu [Bug 521] calleapwhen.c is obsolete - BitKeeper/deleted/.del-calleapwhen.c~3e480692@1.3, 2005-10-27 22:07:30-04:00, stenn@deacon.udel.edu +0 -0 + BitKeeper/deleted/.del-calleapwhen.c~3e480692@1.3 +0 -0 Delete: libntp/calleapwhen.c - include/ntp_stdlib.h@1.23, 2005-10-27 22:11:51-04:00, stenn@deacon.udel.edu +0 -1 + include/ntp_stdlib.h@1.23 +0 -1 [Bug 521] calleapwhen.c is obsolete - libntp/Makefile.am@1.37, 2005-10-27 22:11:51-04:00, stenn@deacon.udel.edu +1 -1 + libntp/Makefile.am@1.37 +1 -1 [Bug 521] calleapwhen.c is obsolete - ports/winnt/libntp/libntp.dsp@1.27, 2005-10-27 22:11:51-04:00, stenn@deacon.udel.edu +0 -4 + ports/winnt/libntp/libntp.dsp@1.27 +0 -4 [Bug 521] calleapwhen.c is obsolete -ChangeSet@1.1251.67.13, 2005-10-27 21:59:11-04:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.67.13, 2005-10-27 21:59:11-04:00, stenn@deacon.udel.edu More updates from Dave Mills - include/ntp.h@1.120.1.6, 2005-10-27 21:57:49-04:00, stenn@deacon.udel.edu +0 -4 + include/ntp.h@1.120.1.6 +0 -4 More updates from Dave Mills - ntpd/ntp_crypto.c@1.98.1.9, 2005-10-27 21:57:52-04:00, stenn@deacon.udel.edu +64 -23 + ntpd/ntp_crypto.c@1.98.1.9 +64 -23 More updates from Dave Mills -ChangeSet@1.1251.67.12, 2005-10-27 21:38:04-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.12, 2005-10-27 21:38:04-04:00, stenn@deacon.udel.edu [Bug 516] unprotected crypto_update() call fix from Dave Mills - ntpd/ntp_proto.c@1.232.1.14, 2005-10-27 21:37:53-04:00, stenn@deacon.udel.edu +5 -7 + ntpd/ntp_proto.c@1.232.1.14 +5 -7 [Bug 516] unprotected crypto_update() call fix from Dave Mills -ChangeSet@1.1251.67.11, 2005-10-25 20:15:47-04:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.67.11, 2005-10-25 20:15:47-04:00, stenn@deacon.udel.edu [Bug 517] Allow dynamic SSL libraries - configure.ac@1.359.1.24, 2005-10-25 20:15:34-04:00, stenn@deacon.udel.edu +3 -2 - [Bug 517] Allow dynamic SSL libraries: also check /usr/sfw/{lib,include} + configure.ac@1.359.1.24 +3 -2 + [Bug 519] Allow dynamic SSL libraries: also check /usr/sfw/{lib,include} - ntpd/ntpd.c@1.61.1.12, 2005-10-25 20:14:38-04:00, stenn@deacon.udel.edu +9 -0 - [Bug 517] Allow dynamic SSL libraries: check SSLeay() for version info + ntpd/ntpd.c@1.61.1.12 +9 -0 + [Bug 519] Allow dynamic SSL libraries: check SSLeay() for version info -ChangeSet@1.1251.67.10, 2005-10-24 04:35:24-04:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.67.10, 2005-10-24 04:35:24-04:00, stenn@deacon.udel.edu Fixes from Dave Mills - ntpd/ntp_control.c@1.79.1.6, 2005-10-24 04:35:10-04:00, stenn@deacon.udel.edu +2 -2 + ntpd/ntp_control.c@1.79.1.6 +2 -2 More 0-11 -> 1-12 month stuff - ntpd/ntp_crypto.c@1.98.1.8, 2005-10-24 04:34:41-04:00, stenn@deacon.udel.edu +0 -5 + ntpd/ntp_crypto.c@1.98.1.8 +0 -5 Lose the coredumping cinfo-> tests -ChangeSet@1.1251.67.9, 2005-10-23 16:43:06-04:00, stenn@deacon.udel.edu +3 -0 +ChangeSet@1.1251.67.9, 2005-10-23 16:43:06-04:00, stenn@deacon.udel.edu Crypto cleanup from Dave Mills - include/ntp.h@1.120.1.5, 2005-10-23 16:41:51-04:00, stenn@deacon.udel.edu +1 -1 + include/ntp.h@1.120.1.5 +1 -1 member reorder from Dave Mills - ntpd/ntp_crypto.c@1.98.1.7, 2005-10-23 16:42:49-04:00, stenn@deacon.udel.edu +143 -157 + ntpd/ntp_crypto.c@1.98.1.7 +143 -157 Crypto cleanup from Dave Mills - ntpd/ntp_proto.c@1.232.1.13, 2005-10-23 16:42:49-04:00, stenn@deacon.udel.edu +0 -1 + ntpd/ntp_proto.c@1.232.1.13 +0 -1 Crypto cleanup from Dave Mills -ChangeSet@1.1251.64.3, 2005-10-22 23:43:31-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.64.3, 2005-10-22 23:43:31-04:00, mayer@pogo.udel.edu Bug #411 fix from Marc - ntpd/ntp_intres.c@1.40.1.2, 2005-10-22 23:43:02-04:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_intres.c@1.40.1.2 +1 -1 Bug #411 fix from Marc -ChangeSet@1.1251.67.8, 2005-10-22 00:26:41-04:00, stenn@deacon.udel.edu +3 -0 +ChangeSet@1.1251.67.8, 2005-10-22 00:26:41-04:00, stenn@deacon.udel.edu Crypto cleanup/changes from Dave Mills - include/ntp_crypto.h@1.38, 2005-10-22 00:22:40-04:00, stenn@deacon.udel.edu +0 -1 + include/ntp_crypto.h@1.38 +0 -1 Lose CRYPTO_FLAG_INVLD. From Dave Mills - ntpd/ntp_crypto.c@1.98.1.6, 2005-10-22 00:26:03-04:00, stenn@deacon.udel.edu +72 -58 + ntpd/ntp_crypto.c@1.98.1.6 +72 -58 Crypto cleanup/changes from Dave Mills - ntpd/ntp_proto.c@1.232.1.12, 2005-10-22 00:26:03-04:00, stenn@deacon.udel.edu +15 -7 + ntpd/ntp_proto.c@1.232.1.12 +15 -7 Crypto cleanup/changes from Dave Mills -ChangeSet@1.1251.67.7, 2005-10-21 23:39:36-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.7, 2005-10-21 23:39:36-04:00, stenn@deacon.udel.edu [Bug 515] ntp_set_tod() displays stale errno - libntp/machines.c@1.18, 2005-10-21 23:39:28-04:00, stenn@deacon.udel.edu +2 -0 + libntp/machines.c@1.18 +2 -0 [Bug 515] ntp_set_tod() displays stale errno -ChangeSet@1.1251.67.6, 2005-10-21 23:23:52-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.6, 2005-10-21 23:23:52-04:00, stenn@deacon.udel.edu [Bug 512] Reintroduce -m to ntptrace. From Frederic Planchon - scripts/ntptrace.in@1.5, 2005-10-21 23:23:45-04:00, stenn@deacon.udel.edu +8 -2 + scripts/ntptrace.in@1.5 +8 -2 [Bug 512] Reintroduce -m to ntptrace. From Frederic Planchon -ChangeSet@1.1251.67.5, 2005-10-20 20:22:12-04:00, stenn@deacon.udel.edu +7 -0 +ChangeSet@1.1251.67.5, 2005-10-20 20:22:12-04:00, stenn@deacon.udel.edu Fixes from Dave Mills - include/ntp.h@1.120.1.4, 2005-10-20 20:14:25-04:00, stenn@deacon.udel.edu +4 -2 + include/ntp.h@1.120.1.4 +4 -2 cleanup from Dave Mills - include/ntp_crypto.h@1.37, 2005-10-20 20:14:26-04:00, stenn@deacon.udel.edu +3 -1 + include/ntp_crypto.h@1.37 +3 -1 cleanup from Dave Mills - include/ntpd.h@1.82.4.4, 2005-10-20 20:14:26-04:00, stenn@deacon.udel.edu +1 -1 + include/ntpd.h@1.82.4.4 +1 -1 cleanup from Dave Mills - libntp/statestr.c@1.10, 2005-10-20 20:15:27-04:00, stenn@deacon.udel.edu +2 -1 + libntp/statestr.c@1.10 +2 -1 Dave Mills added "server certificate expired". - ntpd/ntp_crypto.c@1.98.1.5, 2005-10-20 20:21:17-04:00, stenn@deacon.udel.edu +71 -7 + ntpd/ntp_crypto.c@1.98.1.5 +71 -7 host and server certificate changes from Dave Mills - ntpd/ntp_loopfilter.c@1.115, 2005-10-20 20:19:28-04:00, stenn@deacon.udel.edu +13 -5 + ntpd/ntp_loopfilter.c@1.115 +13 -5 leap second fix plus 0-11 -> 1-12 month fix from Dave Mills - ntpd/ntp_proto.c@1.232.1.11, 2005-10-20 20:20:59-04:00, stenn@deacon.udel.edu +3 -3 + ntpd/ntp_proto.c@1.232.1.11 +3 -3 test reorder from Dave Mills -ChangeSet@1.1251.64.2, 2005-10-16 18:43:40-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.64.2, 2005-10-16 18:43:40-04:00, mayer@pogo.udel.edu Fixes from bug #411 Marc de la Gueronniere - ntpd/ntp_intres.c@1.40.1.1, 2005-10-16 18:43:09-04:00, mayer@pogo.udel.edu +44 -34 + ntpd/ntp_intres.c@1.40.1.1 +44 -34 Fixes from bug #411 Marc de la Gueronniere -ChangeSet@1.1251.67.4, 2005-10-16 03:18:13-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.4, 2005-10-16 03:18:13-04:00, stenn@deacon.udel.edu Fix (unused) reversed tests - ntpd/ntp_intres.c@1.41, 2005-10-16 03:18:05-04:00, stenn@deacon.udel.edu +2 -2 + ntpd/ntp_intres.c@1.41 +2 -2 Fix (unused) reversed tests -ChangeSet@1.1251.67.3, 2005-10-16 02:30:43-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.3, 2005-10-16 02:30:43-04:00, stenn@deacon.udel.edu fix quoting in ISC_PLATFORM_NEEDIN6ADDRANY test - configure.ac@1.359.1.23, 2005-10-16 02:30:33-04:00, stenn@deacon.udel.edu +1 -1 + configure.ac@1.359.1.23 +1 -1 fix quoting in ISC_PLATFORM_NEEDIN6ADDRANY test -ChangeSet@1.1251.67.2, 2005-10-15 23:35:54-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.67.2, 2005-10-15 23:35:54-04:00, stenn@deacon.udel.edu leap and orphan fixes from Dave Mills - ntpd/ntp_proto.c@1.232.1.10, 2005-10-15 23:35:37-04:00, stenn@deacon.udel.edu +86 -36 + ntpd/ntp_proto.c@1.232.1.10 +86 -36 leap and orphan fixes from Dave Mills -ChangeSet@1.1251.67.1, 2005-10-15 20:39:31-04:00, stenn@deacon.udel.edu +4 -0 +ChangeSet@1.1251.67.1, 2005-10-15 20:39:31-04:00, stenn@deacon.udel.edu Fixes from Dave Mills - ntpd/ntp_control.c@1.79.1.5, 2005-10-15 20:34:40-04:00, stenn@deacon.udel.edu +4 -4 + ntpd/ntp_control.c@1.79.1.5 +4 -4 hostkey->update and ctl_putfs() fixes from Dave Mills - ntpd/ntp_crypto.c@1.98.1.4, 2005-10-15 20:35:24-04:00, stenn@deacon.udel.edu +2 -3 + ntpd/ntp_crypto.c@1.98.1.4 +2 -3 Cleanup - ntpd/ntp_loopfilter.c@1.114, 2005-10-15 20:37:17-04:00, stenn@deacon.udel.edu +31 -11 + ntpd/ntp_loopfilter.c@1.114 +31 -11 leap second and pll_control/kern_enable fixes from Dave Mills - ntpd/ntp_proto.c@1.232.1.9, 2005-10-15 20:39:03-04:00, stenn@deacon.udel.edu +90 -41 + ntpd/ntp_proto.c@1.232.1.9 +90 -41 Comment, crypto_update(), orphan, and leap second fixes from Dave Mills -ChangeSet@1.1251.59.9, 2005-10-14 16:08:06-04:00, stenn@deacon.udel.edu +3 -0 +ChangeSet@1.1251.59.9, 2005-10-14 16:08:06-04:00, stenn@deacon.udel.edu Updates from Dave Mills - ntpd/ntp_loopfilter.c@1.113, 2005-10-14 16:05:18-04:00, stenn@deacon.udel.edu +13 -8 + ntpd/ntp_loopfilter.c@1.113 +13 -8 S_SPIK and kern_enable fixes from Dave Mills - ntpd/ntp_refclock.c@1.73, 2005-10-14 16:06:08-04:00, stenn@deacon.udel.edu +2 -2 + ntpd/ntp_refclock.c@1.73 +2 -2 cleanup from Dave Mills - ntpd/refclock_arbiter.c@1.13, 2005-10-14 16:06:41-04:00, stenn@deacon.udel.edu +4 -5 + ntpd/refclock_arbiter.c@1.13 +4 -5 cleanup from Dave Mills -ChangeSet@1.1251.59.8, 2005-10-14 15:52:35-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.59.8, 2005-10-14 15:52:35-04:00, stenn@deacon.udel.edu finish Frank's [] conversion to a block of code - configure.ac@1.359.1.22, 2005-10-14 15:52:20-04:00, stenn@deacon.udel.edu +1 -1 + configure.ac@1.359.1.22 +1 -1 finish Frank's [] conversion to a block of code -ChangeSet@1.1251.61.10, 2005-10-13 00:33:46-04:00, stenn@deacon.udel.edu +5 -0 +ChangeSet@1.1251.61.10, 2005-10-13 00:33:46-04:00, stenn@deacon.udel.edu documentation updates from Dave Mills - html/confopt.html@1.31.1.3, 2005-10-13 00:32:58-04:00, stenn@deacon.udel.edu +25 -35 + html/confopt.html@1.31.1.3 +25 -35 documentation updates from Dave Mills - html/gadget.html@1.1, 2005-10-12 23:35:51-04:00, stenn@deacon.udel.edu +33 -0 + html/gadget.html@1.1 +33 -0 - html/gadget.html@1.0, 2005-10-12 23:35:50-04:00, stenn@deacon.udel.edu +0 -0 + html/gadget.html@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/gadget.html - html/manyopt.html@1.13, 2005-10-13 00:32:58-04:00, stenn@deacon.udel.edu +33 -26 + html/manyopt.html@1.13 +33 -26 documentation updates from Dave Mills - html/release.html@1.31, 2005-10-13 00:32:59-04:00, stenn@deacon.udel.edu +20 -9 + html/release.html@1.31 +20 -9 documentation updates from Dave Mills - html/scripts/links11.txt@1.2, 2005-10-13 00:33:14-04:00, stenn@deacon.udel.edu +2 -0 + html/scripts/links11.txt@1.2 +2 -0 documentation updates from Dave Mills -ChangeSet@1.1251.61.9, 2005-10-09 23:38:00-04:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.61.9, 2005-10-09 23:38:00-04:00, stenn@deacon.udel.edu Fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.112, 2005-10-09 23:37:32-04:00, stenn@deacon.udel.edu +1 -1 + ntpd/ntp_loopfilter.c@1.112 +1 -1 calleapwhen() change from Dave Mills - ntpd/ntp_proto.c@1.232.1.8, 2005-10-09 23:37:48-04:00, stenn@deacon.udel.edu +11 -3 + ntpd/ntp_proto.c@1.232.1.8 +11 -3 crypto fixes from Dave Mills -ChangeSet@1.1251.59.6, 2005-10-08 10:04:12+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.59.6, 2005-10-08 10:04:12+00:00, kardel@pogo.udel.edu dolfptoa.c: safeguard against sign extensions and other mishaps on 64 bit platforms - libntp/dolfptoa.c@1.6, 2005-10-08 10:03:31+00:00, kardel@pogo.udel.edu +11 -0 + libntp/dolfptoa.c@1.6 +11 -0 safeguard against sign extensions and other mishaps on 64 bit platforms -ChangeSet@1.1251.66.2, 2005-10-08 02:28:24-04:00, stenn@deacon.udel.edu +6 -0 +ChangeSet@1.1251.66.2, 2005-10-08 02:28:24-04:00, stenn@deacon.udel.edu documentation fixes from Dave Mills - html/authopt.html@1.34, 2005-10-08 02:28:12-04:00, stenn@deacon.udel.edu +24 -14 + html/authopt.html@1.34 +24 -14 documentation fixes from Dave Mills - html/confopt.html@1.31.1.2, 2005-10-08 02:28:12-04:00, stenn@deacon.udel.edu +2 -2 + html/confopt.html@1.31.1.2 +2 -2 documentation fixes from Dave Mills - html/keygen.html@1.7, 2005-10-08 02:28:12-04:00, stenn@deacon.udel.edu +1 -1 + html/keygen.html@1.7 +1 -1 documentation fixes from Dave Mills - html/manyopt.html@1.12, 2005-10-08 02:28:12-04:00, stenn@deacon.udel.edu +4 -3 + html/manyopt.html@1.12 +4 -3 documentation fixes from Dave Mills - html/miscopt.html@1.32, 2005-10-08 02:28:12-04:00, stenn@deacon.udel.edu +22 -5 + html/miscopt.html@1.32 +22 -5 documentation fixes from Dave Mills - html/msyslog.html@1.5, 2005-10-08 02:28:12-04:00, stenn@deacon.udel.edu +49 -54 + html/msyslog.html@1.5 +49 -54 documentation fixes from Dave Mills -ChangeSet@1.1251.59.4, 2005-10-08 06:06:03+00:00, kardel@pogo.udel.edu +4 -0 +ChangeSet@1.1251.59.4, 2005-10-08 06:06:03+00:00, kardel@pogo.udel.edu refclock_parse.c: avoid unexpected buffer overflows due to sprintf("%f") on strange floats: replace almost all str* and *printf functions by their buffer bounded @@ -16576,135 +197343,135 @@ ChangeSet@1.1251.59.4, 2005-10-08 06:06:03+00:00, kardel@pogo.udel.edu +4 -0 dcfd.c: make dcfd.c compile on NetBSD 3.99.9 again (configure/sigvec compatibility fix) - include/mbg_gps166.h@1.5.1.1, 2005-10-07 23:02:16+00:00, kardel@pogo.udel.edu +10 -4 + include/mbg_gps166.h@1.5.1.1 +10 -4 bounded buffer implementation - libparse/data_mbg.c@1.5.1.1, 2005-10-07 23:03:25+00:00, kardel@pogo.udel.edu +61 -49 + libparse/data_mbg.c@1.5.1.1 +61 -49 bounded buffer implementation - ntpd/refclock_parse.c@1.35.1.1, 2005-10-07 23:03:44+00:00, kardel@pogo.udel.edu +221 -185 + ntpd/refclock_parse.c@1.35.1.1 +221 -185 avoid unexpected buffer overflows due to sprintf("%f") on strange floats: replace almost all str* and *printf functions be their buffer bounded counterparts - parseutil/dcfd.c@1.18, 2005-10-07 23:02:47+00:00, kardel@pogo.udel.edu +25 -18 + parseutil/dcfd.c@1.18 +25 -18 make dcfd.c compile on NetBSD 3.99.9 again (configure/sigvec compatibility fix) -ChangeSet@1.1251.66.1, 2005-10-08 00:29:29-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.66.1, 2005-10-08 00:29:29-04:00, stenn@deacon.udel.edu orphan fixes from Dave Mills - ntpd/ntp_proto.c@1.232.1.7, 2005-10-08 00:29:21-04:00, stenn@deacon.udel.edu +11 -4 + ntpd/ntp_proto.c@1.232.1.7 +11 -4 orphan fixes from Dave Mills -ChangeSet@1.1251.65.1, 2005-10-05 01:38:06-07:00, murray@glypnod.example.com +5 -0 +ChangeSet@1.1251.65.1, 2005-10-05 01:38:06-07:00, murray@glypnod.example.com Add support for the HP Z3801 GPS clock. Needs 19200 buad, 7 bits, odd parity. - BitKeeper/etc/logging_ok@1.54.2.1, 2005-10-05 01:38:06-07:00, murray@glypnod.example.com +1 -0 + BitKeeper/etc/logging_ok@1.54.2.1 +1 -0 Logging to repologs@ntp.isc.org accepted - html/drivers/driver26.html@1.10, 2005-10-05 01:37:37-07:00, murray@glypnod.example.com +12 -9 + html/drivers/driver26.html@1.10 +12 -9 Add description of HP Z3801A - include/ntp_refclock.h@1.20, 2005-10-05 01:37:37-07:00, murray@glypnod.example.com +2 -1 + include/ntp_refclock.h@1.20 +2 -1 Add LDISC_7O1 flag for 7 bit, odd parity - ntpd/ntp_refclock.c@1.72, 2005-10-05 01:37:37-07:00, murray@glypnod.example.com +4 -0 + ntpd/ntp_refclock.c@1.72 +4 -0 Add support for LDISC_7O1 flag - 7 bit, odd parity. - ntpd/refclock_hpgps.c@1.7, 2005-10-05 01:37:37-07:00, murray@glypnod.example.com +18 -3 + ntpd/refclock_hpgps.c@1.7 +18 -3 Add support for HP Z3810A - 19200, 7bits, odd parity -ChangeSet@1.1251.61.6, 2005-10-05 03:02:11-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.61.6, 2005-10-05 03:02:11-04:00, stenn@deacon.udel.edu orphan fixes from Dave Mills - ntpd/ntp_proto.c@1.232.1.6, 2005-10-05 03:01:54-04:00, stenn@deacon.udel.edu +18 -16 + ntpd/ntp_proto.c@1.232.1.6 +18 -16 orphan fixes from Dave Mills -ChangeSet@1.1251.64.1, 2005-10-04 12:22:54-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.64.1, 2005-10-04 12:22:54-04:00, mayer@pogo.udel.edu Fix extra y at beginning of file - ntpd/ntp_proto.c@1.232.2.1, 2005-10-04 12:22:23-04:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_proto.c@1.232.2.1 +1 -1 Fix extra y at beginning of file -ChangeSet@1.1251.61.5, 2005-10-04 02:52:27-04:00, stenn@deacon.udel.edu +5 -0 +ChangeSet@1.1251.61.5, 2005-10-04 02:52:27-04:00, stenn@deacon.udel.edu fixes from Dave Mills - include/ntp.h@1.120.1.3, 2005-10-04 02:50:55-04:00, stenn@deacon.udel.edu +3 -1 + include/ntp.h@1.120.1.3 +3 -1 fixes from Dave Mills - include/ntpd.h@1.82.4.3, 2005-10-04 02:50:55-04:00, stenn@deacon.udel.edu +0 -1 + include/ntpd.h@1.82.4.3 +0 -1 fixes from Dave Mills - ntpd/ntp_control.c@1.79.1.4, 2005-10-04 02:51:46-04:00, stenn@deacon.udel.edu +1 -1 + ntpd/ntp_control.c@1.79.1.4 +1 -1 fixes from Dave Mills - ntpd/ntp_proto.c@1.232.1.5, 2005-10-04 02:51:47-04:00, stenn@deacon.udel.edu +49 -29 + ntpd/ntp_proto.c@1.232.1.5 +49 -29 fixes from Dave Mills - ntpd/refclock_local.c@1.14, 2005-10-04 02:51:47-04:00, stenn@deacon.udel.edu +2 -8 + ntpd/refclock_local.c@1.14 +2 -8 fixes from Dave Mills -ChangeSet@1.1251.63.1, 2005-10-02 04:12:05-04:00, stenn@deacon.udel.edu +10 -0 +ChangeSet@1.1251.63.1, 2005-10-02 04:12:05-04:00, stenn@deacon.udel.edu NEWS update; orphan/revoke/expire stuff from Dave Mills - NEWS@1.48, 2005-10-02 04:11:28-04:00, stenn@deacon.udel.edu +2 -0 + NEWS@1.48 +2 -0 updated - include/ntp.h@1.120.1.2, 2005-10-02 03:57:42-04:00, stenn@deacon.udel.edu +3 -2 + include/ntp.h@1.120.1.2 +3 -2 orphan and revoke stuff from Dave Mills - include/ntp_config.h@1.37.1.2, 2005-10-02 03:57:42-04:00, stenn@deacon.udel.edu +1 -0 + include/ntp_config.h@1.37.1.2 +1 -0 orphan and revoke stuff from Dave Mills - include/ntp_control.h@1.29, 2005-10-02 03:57:42-04:00, stenn@deacon.udel.edu +2 -1 + include/ntp_control.h@1.29 +2 -1 orphan and revoke stuff from Dave Mills - ntpd/ntp_config.c@1.129.4.1, 2005-10-02 04:08:11-04:00, stenn@deacon.udel.edu +5 -0 + ntpd/ntp_config.c@1.129.4.1 +5 -0 fixes, and orphan and expire stuff from Dave Mills - ntpd/ntp_control.c@1.79.1.3, 2005-10-02 04:08:11-04:00, stenn@deacon.udel.edu +50 -20 + ntpd/ntp_control.c@1.79.1.3 +50 -20 fixes, and orphan and expire stuff from Dave Mills - ntpd/ntp_crypto.c@1.98.1.3, 2005-10-02 04:08:11-04:00, stenn@deacon.udel.edu +114 -94 + ntpd/ntp_crypto.c@1.98.1.3 +114 -94 fixes, and orphan and expire stuff from Dave Mills - ntpd/ntp_loopfilter.c@1.111, 2005-10-02 04:08:12-04:00, stenn@deacon.udel.edu +1 -1 + ntpd/ntp_loopfilter.c@1.111 +1 -1 fixes, and orphan and expire stuff from Dave Mills - ntpd/ntp_peer.c@1.84.1.1, 2005-10-02 04:08:12-04:00, stenn@deacon.udel.edu +0 -1 + ntpd/ntp_peer.c@1.84.1.1 +0 -1 fixes, and orphan and expire stuff from Dave Mills - ntpd/ntp_proto.c@1.232.1.4, 2005-10-02 04:08:12-04:00, stenn@deacon.udel.edu +200 -124 + ntpd/ntp_proto.c@1.232.1.4 +200 -124 fixes, and orphan and expire stuff from Dave Mills -ChangeSet@1.1251.61.3, 2005-10-01 01:02:12-04:00, mayer@pogo.udel.edu +5 -0 +ChangeSet@1.1251.61.3, 2005-10-01 01:02:12-04:00, mayer@pogo.udel.edu Fixes for handling IPv6 issues and getaddrinfo() - include/isc/net.h@1.7, 2005-10-01 01:00:52-04:00, mayer@pogo.udel.edu +2 -2 + include/isc/net.h@1.7 +2 -2 Fixes for handling IPv6 issues and getaddrinfo)_ - libisc/net.c@1.6, 2005-10-01 01:00:52-04:00, mayer@pogo.udel.edu +1 -0 + libisc/net.c@1.6 +1 -0 Fixes for handling IPv6 issues and getaddrinfo)_ - libntp/ntp_rfc2553.c@1.26, 2005-10-01 01:00:52-04:00, mayer@pogo.udel.edu +124 -21 + libntp/ntp_rfc2553.c@1.26 +124 -21 Fixes for handling IPv6 issues and getaddrinfo)_ - ports/winnt/include/isc/net.h@1.6, 2005-10-01 01:00:52-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/include/isc/net.h@1.6 +1 -1 Fixes for handling IPv6 issues and getaddrinfo)_ - ports/winnt/libisc/net.c@1.7, 2005-10-01 01:00:52-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/libisc/net.c@1.7 +1 -1 Fixes for handling IPv6 issues and getaddrinfo)_ -ChangeSet@1.1251.61.2, 2005-09-26 02:19:59-04:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1251.61.2, 2005-09-26 02:19:59-04:00, stenn@deacon.udel.edu sntp is now built by default. - configure.ac@1.359.4.1, 2005-09-26 02:19:47-04:00, stenn@deacon.udel.edu +2 -2 + configure.ac@1.359.4.1 +2 -2 sntp is now built by default. - flock-build@1.33, 2005-09-26 02:19:47-04:00, stenn@deacon.udel.edu +6 -7 + flock-build@1.33 +6 -7 sntp is now built by default. -ChangeSet@1.1251.60.4, 2005-09-25 12:21:08+00:00, kardel@pogo.udel.edu +3 -0 +ChangeSet@1.1251.60.4, 2005-09-25 12:21:08+00:00, kardel@pogo.udel.edu ntpdc_ops.c: output broadcast address information when broadcast flag is set ntp_peer.c: @@ -16712,16 +197479,16 @@ ChangeSet@1.1251.60.4, 2005-09-25 12:21:08+00:00, kardel@pogo.udel.edu +3 -0 ntp_io.c: re-bind interfaces on re-scans - ntpd/ntp_io.c@1.211, 2005-09-25 12:10:52+00:00, kardel@pogo.udel.edu +90 -43 + ntpd/ntp_io.c@1.211 +90 -43 re-bind interfaces on re-scans - ntpd/ntp_peer.c@1.91, 2005-09-25 12:11:28+00:00, kardel@pogo.udel.edu +18 -1 + ntpd/ntp_peer.c@1.91 +18 -1 re-bind broad and multi cast on re-fresh - ntpdc/ntpdc_ops.c@1.45, 2005-09-25 12:12:38+00:00, kardel@pogo.udel.edu +10 -9 + ntpdc/ntpdc_ops.c@1.45 +10 -9 output broadcast address information when broadcast flag is set -ChangeSet@1.1251.60.3, 2005-09-25 12:10:35+00:00, kardel@pogo.udel.edu +4 -0 +ChangeSet@1.1251.60.3, 2005-09-25 12:10:35+00:00, kardel@pogo.udel.edu refclock_parse.c: avoid unexpected buffer overflows due to sprintf("%f") on strange floats: replace almost all str* and *printf functions be their buffer bounded @@ -16734,581 +197501,581 @@ ChangeSet@1.1251.60.3, 2005-09-25 12:10:35+00:00, kardel@pogo.udel.edu +4 -0 mbg_gps166.h support fully bounded buffers - include/mbg_gps166.h@1.6, 2005-09-25 12:06:41+00:00, kardel@pogo.udel.edu +7 -4 + include/mbg_gps166.h@1.6 +7 -4 - libparse/clk_meinberg.c@1.9, 2005-09-25 12:07:49+00:00, kardel@pogo.udel.edu +7 -4 + libparse/clk_meinberg.c@1.9 +7 -4 cleanup buffer bounds - libparse/data_mbg.c@1.6, 2005-09-25 12:08:11+00:00, kardel@pogo.udel.edu +58 -49 + libparse/data_mbg.c@1.6 +58 -49 support fully bounded buffers - ntpd/refclock_parse.c@1.36, 2005-09-25 12:08:50+00:00, kardel@pogo.udel.edu +204 -185 + ntpd/refclock_parse.c@1.36 +204 -185 avoid unexpected buffer overflows due to sprintf("%f") on strange floats: replace almost all str* and *printf functions be their buffer bounded counterparts limit re-set rate of trimble clocks -ChangeSet@1.1251.61.1, 2005-09-25 04:17:34-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.61.1, 2005-09-25 04:17:34-04:00, stenn@deacon.udel.edu Add missing ISC_PLATFORM_HAVESCOPEID checks. - ntpd/ntp_io.c@1.187.1.4, 2005-09-25 04:17:25-04:00, stenn@deacon.udel.edu +12 -1 + ntpd/ntp_io.c@1.187.1.4 +12 -1 Add missing ISC_PLATFORM_HAVESCOPEID checks. -ChangeSet@1.1251.58.1, 2005-09-25 05:54:32+00:00, stenn@ntp1.isc.org +2 -0 +ChangeSet@1.1251.58.1, 2005-09-25 05:54:32+00:00, stenn@ntp1.isc.org [Bug 467] Reorder #include order to avoid linux collision - BitKeeper/etc/logging_ok@1.54.1.1, 2005-09-25 05:54:32+00:00, stenn@ntp1.isc.org +1 -0 + BitKeeper/etc/logging_ok@1.54.1.1 +1 -0 Logging to repologs@ntp.isc.org accepted - ntpd/ntp_config.c@1.129.3.4, 2005-09-25 05:54:11+00:00, stenn@ntp1.isc.org +8 -2 + ntpd/ntp_config.c@1.129.3.4 +8 -2 [Bug 467] Reorder #include order to avoid linux collision -ChangeSet@1.1251.1.153, 2005-09-24 23:18:13-04:00, stenn@deacon.udel.edu +6 -0 +ChangeSet@1.1251.1.153, 2005-09-24 23:18:13-04:00, stenn@deacon.udel.edu [Bug 498] Patches from Miroslaw Pabich - include/adjtime.h@1.4, 2005-09-24 23:17:22-04:00, stenn@deacon.udel.edu +0 -6 + include/adjtime.h@1.4 +0 -6 [Bug 498] Patches from Miroslaw Pabich - libntp/iosignal.c@1.13, 2005-09-24 23:17:32-04:00, stenn@deacon.udel.edu +6 -6 + libntp/iosignal.c@1.13 +6 -6 [Bug 498] Patches from Miroslaw Pabich - ntpd/refclock_hopfser.c@1.9, 2005-09-24 23:17:43-04:00, stenn@deacon.udel.edu +5 -3 + ntpd/refclock_hopfser.c@1.9 +5 -3 [Bug 498] Patches from Miroslaw Pabich - ntpd/refclock_neoclock4x.c@1.13, 2005-09-24 23:17:43-04:00, stenn@deacon.udel.edu +5 -3 + ntpd/refclock_neoclock4x.c@1.13 +5 -3 [Bug 498] Patches from Miroslaw Pabich - ntpd/refclock_palisade.h@1.8, 2005-09-24 23:17:43-04:00, stenn@deacon.udel.edu +2 -0 + ntpd/refclock_palisade.h@1.8 +2 -0 [Bug 498] Patches from Miroslaw Pabich - ntpdate/ntpdate.c@1.52, 2005-09-24 23:17:53-04:00, stenn@deacon.udel.edu +0 -4 + ntpdate/ntpdate.c@1.52 +0 -4 [Bug 498] Patches from Miroslaw Pabich -ChangeSet@1.1251.53.6, 2005-09-24 17:39:29-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.53.6, 2005-09-24 17:39:29-04:00, mayer@pogo.udel.edu Revamped the code in getaddrinfo - libntp/ntp_rfc2553.c@1.25, 2005-09-24 17:39:04-04:00, mayer@pogo.udel.edu +31 -37 + libntp/ntp_rfc2553.c@1.25 +31 -37 Revamped the code in getaddrinfo -ChangeSet@1.1251.56.1, 2005-09-23 19:27:51-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.56.1, 2005-09-23 19:27:51-04:00, mayer@pogo.udel.edu Refix for memory leak. Some checks were incorrect - libntp/ntp_rfc2553.c@1.24, 2005-09-23 19:26:56-04:00, mayer@pogo.udel.edu +19 -15 + libntp/ntp_rfc2553.c@1.24 +19 -15 Refix for memory leak. Some checks were incorrect -ChangeSet@1.1251.53.4, 2005-09-22 22:07:15-04:00, stenn@deacon.udel.edu +1 -0 +ChangeSet@1.1251.53.4, 2005-09-22 22:07:15-04:00, stenn@deacon.udel.edu [Bug 496]: Updated adjtime for QNX from Miroslaw Pabich - libntp/adjtime.c@1.7, 2005-09-22 22:07:07-04:00, stenn@deacon.udel.edu +80 -17 + libntp/adjtime.c@1.7 +80 -17 [Bug 496]: Updated adjtime for QNX from Miroslaw Pabich -ChangeSet@1.1251.55.1, 2005-09-21 23:23:47-04:00, gunturu@pogo.udel.edu +2 -0 +ChangeSet@1.1251.55.1, 2005-09-21 23:23:47-04:00, gunturu@pogo.udel.edu timing.c: unable settimeofday and adjtime as temporary fix until we port utmp. - BitKeeper/etc/logging_ok@1.55, 2005-09-21 23:23:47-04:00, gunturu@pogo.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.55 +1 -0 Logging to repologs@ntp.isc.org accepted - sntp/timing.c@1.3, 2005-09-21 23:21:58-04:00, gunturu@pogo.udel.edu +4 -4 + sntp/timing.c@1.3 +4 -4 unable settimeofday and adjtime as temporary fix until we port utmp. -ChangeSet@1.1305, 2005-09-21 00:31:27-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1305, 2005-09-21 00:31:27-04:00, stenn@pogo.udel.edu autoopts cleanup - ntpd/ntpd.c@1.70, 2005-09-21 00:31:17-04:00, stenn@pogo.udel.edu +2 -0 + ntpd/ntpd.c@1.70 +2 -0 autoopts cleanup -ChangeSet@1.1304, 2005-09-21 00:30:39-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1304, 2005-09-21 00:30:39-04:00, stenn@pogo.udel.edu libopts update - sntp/libopts/compat/compat.h@1.5, 2005-09-21 00:30:27-04:00, stenn@pogo.udel.edu +5 -4 + sntp/libopts/compat/compat.h@1.5 +5 -4 libopts update -ChangeSet@1.1303, 2005-09-21 00:28:47-04:00, stenn@pogo.udel.edu +10 -0 +ChangeSet@1.1303, 2005-09-21 00:28:47-04:00, stenn@pogo.udel.edu libopts upgrade - sntp/libopts/autoopts.c@1.3, 2005-09-21 00:26:36-04:00, stenn@pogo.udel.edu +9 -1 + sntp/libopts/autoopts.c@1.3 +9 -1 libopts upgrade - sntp/libopts/autoopts.h@1.4, 2005-09-21 00:26:36-04:00, stenn@pogo.udel.edu +1 -8 + sntp/libopts/autoopts.h@1.4 +1 -8 libopts upgrade - sntp/libopts/autoopts/options.h@1.3, 2005-09-17 03:23:25-04:00, stenn@pogo.udel.edu +30 -5 + sntp/libopts/autoopts/options.h@1.3 +30 -5 libopts upgrade - sntp/libopts/autoopts/usage-txt.h@1.4, 2005-09-17 03:23:25-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/autoopts/usage-txt.h@1.4 +1 -1 libopts upgrade - sntp/libopts/compat/compat.h@1.4, 2005-09-17 03:23:25-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/compat/compat.h@1.4 +1 -1 libopts upgrade - sntp/libopts/genshell.c@1.4, 2005-09-17 03:23:25-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/genshell.c@1.4 +1 -1 libopts upgrade - sntp/libopts/genshell.h@1.4, 2005-09-17 03:23:25-04:00, stenn@pogo.udel.edu +2 -2 + sntp/libopts/genshell.h@1.4 +2 -2 libopts upgrade - sntp/libopts/libopts.c@1.3, 2005-09-21 00:26:37-04:00, stenn@pogo.udel.edu +0 -1 + sntp/libopts/libopts.c@1.3 +0 -1 libopts upgrade - sntp/libopts/libopts.m4@1.4, 2005-09-21 00:26:37-04:00, stenn@pogo.udel.edu +15 -17 + sntp/libopts/libopts.m4@1.4 +15 -17 libopts upgrade - sntp/libopts/proto.h@1.4, 2005-09-21 00:26:37-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/proto.h@1.4 +1 -1 libopts upgrade -ChangeSet@1.1251.53.3, 2005-09-20 23:35:55-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.53.3, 2005-09-20 23:35:55-04:00, mayer@pogo.udel.edu bug #486 and Fix memory leak and add heiko's change for hints - libntp/ntp_rfc2553.c@1.23, 2005-09-20 23:35:18-04:00, mayer@pogo.udel.edu +15 -5 + libntp/ntp_rfc2553.c@1.23 +15 -5 bug #486 and Fix memory leak and add heiko's change for hints -ChangeSet@1.1251.54.1, 2005-09-19 18:05:35-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.54.1, 2005-09-19 18:05:35-04:00, mayer@pogo.udel.edu Frank Kardel's fixes for the flags and broadcast address - libisc/ifiter_getifaddrs.c@1.5, 2005-09-19 18:04:58-04:00, mayer@pogo.udel.edu +2 -2 + libisc/ifiter_getifaddrs.c@1.5 +2 -2 Frank Kardel's fixes for the flags and broadcast address - libisc/ifiter_sysctl.c@1.12, 2005-09-19 18:04:58-04:00, mayer@pogo.udel.edu +1 -1 + libisc/ifiter_sysctl.c@1.12 +1 -1 Frank Kardel's fixes for the flags and broadcast address -ChangeSet@1.1251.52.2, 2005-09-17 10:11:26+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.52.2, 2005-09-17 10:11:26+00:00, kardel@pogo.udel.edu ntp_io.c: cleanup merge fallout - ntpd/ntp_io.c@1.209, 2005-09-17 10:10:39+00:00, kardel@pogo.udel.edu +6 -5 + ntpd/ntp_io.c@1.209 +6 -5 cleanup merge fallout -ChangeSet@1.1301, 2005-09-17 00:45:06-04:00, stenn@pogo.udel.edu +14 -0 +ChangeSet@1.1301, 2005-09-17 00:45:06-04:00, stenn@pogo.udel.edu libopts upgrade - m4/libopts.m4@1.8, 2005-09-17 00:39:38-04:00, stenn@pogo.udel.edu +36 -1 + m4/libopts.m4@1.8 +36 -1 libopts upgrade - sntp/Makefile.am@1.9, 2005-09-17 00:39:46-04:00, stenn@pogo.udel.edu +1 -1 + sntp/Makefile.am@1.9 +1 -1 libopts upgrade - sntp/libopts/Makefile.am@1.2, 2005-09-17 00:40:04-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/Makefile.am@1.2 +1 -1 libopts upgrade - sntp/libopts/autoopts.h@1.3, 2005-09-17 00:40:04-04:00, stenn@pogo.udel.edu +1 -21 + sntp/libopts/autoopts.h@1.3 +1 -21 libopts upgrade - sntp/libopts/autoopts/usage-txt.h@1.3, 2005-09-11 23:12:25-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/autoopts/usage-txt.h@1.3 +0 -0 Change mode to -rw-r--r-- - sntp/libopts/autoopts/usage-txt.h@1.2, 2005-09-11 23:09:56-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/autoopts/usage-txt.h@1.2 +1 -1 libopts updates - sntp/libopts/compat/compat.h@1.3, 2005-09-17 00:41:18-04:00, stenn@pogo.udel.edu +5 -4 + sntp/libopts/compat/compat.h@1.3 +5 -4 libopts upgrade - sntp/libopts/genshell.c@1.3, 2005-09-11 23:12:24-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/genshell.c@1.3 +0 -0 Change mode to -rw-r--r-- - sntp/libopts/genshell.c@1.2, 2005-09-11 23:09:38-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/genshell.c@1.2 +1 -1 libopts updates - sntp/libopts/genshell.h@1.3, 2005-09-11 23:12:25-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/genshell.h@1.3 +0 -0 Change mode to -rw-r--r-- - sntp/libopts/genshell.h@1.2, 2005-09-11 23:09:38-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/genshell.h@1.2 +1 -1 libopts updates - sntp/libopts/libopts.c@1.2, 2005-09-17 00:40:05-04:00, stenn@pogo.udel.edu +1 -0 + sntp/libopts/libopts.c@1.2 +1 -0 libopts upgrade - sntp/libopts/libopts.m4@1.3, 2005-09-17 00:40:05-04:00, stenn@pogo.udel.edu +36 -1 + sntp/libopts/libopts.m4@1.3 +36 -1 libopts upgrade - sntp/libopts/proto.h@1.3, 2005-09-17 00:40:05-04:00, stenn@pogo.udel.edu +1 -10 + sntp/libopts/proto.h@1.3 +1 -10 libopts upgrade - sntp/libopts/text_mmap.c@1.3, 2005-09-17 00:40:05-04:00, stenn@pogo.udel.edu +74 -33 + sntp/libopts/text_mmap.c@1.3 +74 -33 libopts upgrade - sntp/m4/libopts.m4@1.5, 2005-09-17 00:39:52-04:00, stenn@pogo.udel.edu +36 -1 + sntp/m4/libopts.m4@1.5 +36 -1 libopts upgrade - sntp/m4/libopts.m4@1.4, 2005-09-12 17:12:47-04:00, stenn@pogo.udel.edu +0 -0 + sntp/m4/libopts.m4@1.4 +0 -0 Rename: sntp/libopts.m4 -> sntp/m4/libopts.m4 - sntp/sntp-opts.def@1.2, 2005-09-17 00:39:47-04:00, stenn@pogo.udel.edu +2 -0 + sntp/sntp-opts.def@1.2 +2 -0 libopts upgrade -ChangeSet@1.1251.51.6, 2005-09-17 00:34:07-04:00, stenn@deacon.udel.edu +5 -0 +ChangeSet@1.1251.51.6, 2005-09-17 00:34:07-04:00, stenn@deacon.udel.edu more leap stuff from Dave Mills - include/ntpd.h@1.82.4.2, 2005-09-17 00:33:27-04:00, stenn@deacon.udel.edu +1 -0 + include/ntpd.h@1.82.4.2 +1 -0 more leap stuff from Dave Mills - ntpd/ntp_control.c@1.79.1.2, 2005-09-17 00:33:17-04:00, stenn@deacon.udel.edu +1 -1 + ntpd/ntp_control.c@1.79.1.2 +1 -1 more leap stuff from Dave Mills - ntpd/ntp_crypto.c@1.98.1.2, 2005-09-17 00:33:17-04:00, stenn@deacon.udel.edu +2 -5 + ntpd/ntp_crypto.c@1.98.1.2 +2 -5 more leap stuff from Dave Mills - ntpd/ntp_loopfilter.c@1.110, 2005-09-17 00:33:17-04:00, stenn@deacon.udel.edu +11 -13 + ntpd/ntp_loopfilter.c@1.110 +11 -13 more leap stuff from Dave Mills - ntpd/ntp_proto.c@1.232.1.3, 2005-09-17 00:33:17-04:00, stenn@deacon.udel.edu +4 -2 + ntpd/ntp_proto.c@1.232.1.3 +4 -2 more leap stuff from Dave Mills -ChangeSet@1.1251.51.5, 2005-09-16 22:47:54-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.51.5, 2005-09-16 22:47:54-04:00, mayer@pogo.udel.edu Fix wildcards to return valid socket interface structure addresses - for Heiko's fix bug #450 - ntpd/ntp_io.c@1.187.1.3, 2005-09-16 22:47:16-04:00, mayer@pogo.udel.edu +10 -18 + ntpd/ntp_io.c@1.187.1.3 +10 -18 Fix wildcards to return valid socket interface structure addresses - for Heiko's fix bug #450 -ChangeSet@1.1251.51.4, 2005-09-15 02:37:45-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.51.4, 2005-09-15 02:37:45-04:00, stenn@whimsy.udel.edu strip quotes from filenames in the config file. From Heiko Gerstung - ntpd/ntp_config.c@1.129.3.3, 2005-09-15 02:37:30-04:00, stenn@whimsy.udel.edu +18 -0 + ntpd/ntp_config.c@1.129.3.3 +18 -0 strip quotes from filenames in the config file. From Heiko Gerstung -ChangeSet@1.1251.51.3, 2005-09-15 02:26:33-04:00, stenn@whimsy.udel.edu +64 -0 +ChangeSet@1.1251.51.3, 2005-09-15 02:26:33-04:00, stenn@whimsy.udel.edu Documentation changes from Dave Mills - html/accopt.html@1.24, 2005-09-15 02:22:25-04:00, stenn@whimsy.udel.edu +66 -61 + html/accopt.html@1.24 +66 -61 Documentation changes from Dave Mills - html/assoc.html@1.21, 2005-09-15 02:22:25-04:00, stenn@whimsy.udel.edu +52 -51 + html/assoc.html@1.21 +52 -51 Documentation changes from Dave Mills - html/audio.html@1.17, 2005-09-15 02:22:26-04:00, stenn@whimsy.udel.edu +48 -47 + html/audio.html@1.17 +48 -47 Documentation changes from Dave Mills - html/authopt.html@1.33, 2005-09-15 02:22:26-04:00, stenn@whimsy.udel.edu +139 -137 + html/authopt.html@1.33 +139 -137 Documentation changes from Dave Mills - html/clockopt.html@1.18, 2005-09-15 02:22:26-04:00, stenn@whimsy.udel.edu +61 -60 + html/clockopt.html@1.18 +61 -60 Documentation changes from Dave Mills - html/confopt.html@1.31.1.1, 2005-09-15 02:22:27-04:00, stenn@whimsy.udel.edu +18 -15 + html/confopt.html@1.31.1.1 +18 -15 Documentation changes from Dave Mills - html/copyright.html@1.31, 2005-09-15 02:22:27-04:00, stenn@whimsy.udel.edu +72 -71 + html/copyright.html@1.31 +72 -71 Documentation changes from Dave Mills - html/debug.html@1.23, 2005-09-15 02:22:28-04:00, stenn@whimsy.udel.edu +119 -118 + html/debug.html@1.23 +119 -118 Documentation changes from Dave Mills - html/drivers/driver1.html@1.15, 2005-09-15 02:22:47-04:00, stenn@whimsy.udel.edu +59 -58 + html/drivers/driver1.html@1.15 +59 -58 Documentation changes from Dave Mills - html/drivers/driver18.html@1.15, 2005-09-15 02:22:48-04:00, stenn@whimsy.udel.edu +56 -55 + html/drivers/driver18.html@1.15 +56 -55 Documentation changes from Dave Mills - html/drivers/driver20.html@1.14, 2005-09-15 02:22:49-04:00, stenn@whimsy.udel.edu +59 -65 + html/drivers/driver20.html@1.14 +59 -65 Documentation changes from Dave Mills - html/drivers/driver22.html@1.17, 2005-09-15 02:22:49-04:00, stenn@whimsy.udel.edu +47 -46 + html/drivers/driver22.html@1.17 +47 -46 Documentation changes from Dave Mills - html/drivers/driver27.html@1.14, 2005-09-15 02:22:50-04:00, stenn@whimsy.udel.edu +198 -200 + html/drivers/driver27.html@1.14 +198 -200 Documentation changes from Dave Mills - html/drivers/driver29.html@1.14, 2005-09-15 02:22:50-04:00, stenn@whimsy.udel.edu +769 -790 + html/drivers/driver29.html@1.14 +769 -790 Documentation changes from Dave Mills - html/drivers/driver3.html@1.11, 2005-09-15 02:22:50-04:00, stenn@whimsy.udel.edu +47 -47 + html/drivers/driver3.html@1.11 +47 -47 Documentation changes from Dave Mills - html/drivers/driver30.html@1.19, 2005-09-15 02:22:51-04:00, stenn@whimsy.udel.edu +77 -78 + html/drivers/driver30.html@1.19 +77 -78 Documentation changes from Dave Mills - html/drivers/driver31.html@1.2, 2005-09-15 02:22:51-04:00, stenn@whimsy.udel.edu +52 -50 + html/drivers/driver31.html@1.2 +52 -50 Documentation changes from Dave Mills - html/drivers/driver32.html@1.12, 2005-09-15 02:22:51-04:00, stenn@whimsy.udel.edu +23 -23 + html/drivers/driver32.html@1.12 +23 -23 Documentation changes from Dave Mills - html/drivers/driver33.html@1.12, 2005-09-15 02:22:52-04:00, stenn@whimsy.udel.edu +23 -23 + html/drivers/driver33.html@1.12 +23 -23 Documentation changes from Dave Mills - html/drivers/driver34.html@1.11, 2005-09-15 02:22:52-04:00, stenn@whimsy.udel.edu +44 -50 + html/drivers/driver34.html@1.11 +44 -50 Documentation changes from Dave Mills - html/drivers/driver35.html@1.14, 2005-09-15 02:22:52-04:00, stenn@whimsy.udel.edu +41 -40 + html/drivers/driver35.html@1.14 +41 -40 Documentation changes from Dave Mills - html/drivers/driver36.html@1.26, 2005-09-15 02:22:53-04:00, stenn@whimsy.udel.edu +162 -151 + html/drivers/driver36.html@1.26 +162 -151 Documentation changes from Dave Mills - html/drivers/driver37.html@1.12, 2005-09-15 02:22:53-04:00, stenn@whimsy.udel.edu +44 -43 + html/drivers/driver37.html@1.12 +44 -43 Documentation changes from Dave Mills - html/drivers/driver38.html@1.13, 2005-09-15 02:22:53-04:00, stenn@whimsy.udel.edu +124 -131 + html/drivers/driver38.html@1.13 +124 -131 Documentation changes from Dave Mills - html/drivers/driver39.html@1.13, 2005-09-15 02:22:54-04:00, stenn@whimsy.udel.edu +106 -109 + html/drivers/driver39.html@1.13 +106 -109 Documentation changes from Dave Mills - html/drivers/driver4.html@1.12, 2005-09-15 02:22:54-04:00, stenn@whimsy.udel.edu +59 -58 + html/drivers/driver4.html@1.12 +59 -58 Documentation changes from Dave Mills - html/drivers/driver40.html@1.13, 2005-09-15 02:22:54-04:00, stenn@whimsy.udel.edu +129 -138 + html/drivers/driver40.html@1.13 +129 -138 Documentation changes from Dave Mills - html/drivers/driver42.html@1.12, 2005-09-15 02:22:55-04:00, stenn@whimsy.udel.edu +23 -22 + html/drivers/driver42.html@1.12 +23 -22 Documentation changes from Dave Mills - html/drivers/driver43.html@1.10, 2005-09-15 02:22:55-04:00, stenn@whimsy.udel.edu +35 -34 + html/drivers/driver43.html@1.10 +35 -34 Documentation changes from Dave Mills - html/drivers/driver44.html@1.12, 2005-09-15 02:22:55-04:00, stenn@whimsy.udel.edu +81 -82 + html/drivers/driver44.html@1.12 +81 -82 Documentation changes from Dave Mills - html/drivers/driver6.html@1.20, 2005-09-15 02:22:56-04:00, stenn@whimsy.udel.edu +73 -72 + html/drivers/driver6.html@1.20 +73 -72 Documentation changes from Dave Mills - html/drivers/driver7.html@1.22, 2005-09-15 02:22:56-04:00, stenn@whimsy.udel.edu +207 -206 + html/drivers/driver7.html@1.22 +207 -206 Documentation changes from Dave Mills - html/drivers/driver8.html@1.18, 2005-09-15 02:22:57-04:00, stenn@whimsy.udel.edu +230 -419 + html/drivers/driver8.html@1.18 +230 -419 Documentation changes from Dave Mills - html/drivers/oncore-shmem.html@1.12, 2005-09-15 02:22:57-04:00, stenn@whimsy.udel.edu +58 -55 + html/drivers/oncore-shmem.html@1.12 +58 -55 Documentation changes from Dave Mills - html/drivers/tf582_4.html@1.2, 2005-09-15 02:22:58-04:00, stenn@whimsy.udel.edu +57 -58 + html/drivers/tf582_4.html@1.2 +57 -58 Documentation changes from Dave Mills - html/extern.html@1.14, 2005-09-15 02:22:28-04:00, stenn@whimsy.udel.edu +26 -25 + html/extern.html@1.14 +26 -25 Documentation changes from Dave Mills - html/howto.html@1.18, 2005-09-15 02:22:28-04:00, stenn@whimsy.udel.edu +89 -88 + html/howto.html@1.18 +89 -88 Documentation changes from Dave Mills - html/index.html@1.32, 2005-09-15 02:22:29-04:00, stenn@whimsy.udel.edu +1 -1 + html/index.html@1.32 +1 -1 Documentation changes from Dave Mills - html/kern.html@1.14, 2005-09-15 02:22:29-04:00, stenn@whimsy.udel.edu +27 -26 + html/kern.html@1.14 +27 -26 Documentation changes from Dave Mills - html/keygen.html@1.6, 2005-09-15 02:22:29-04:00, stenn@whimsy.udel.edu +109 -105 + html/keygen.html@1.6 +109 -105 Documentation changes from Dave Mills - html/ldisc.html@1.12, 2005-09-15 02:22:30-04:00, stenn@whimsy.udel.edu +35 -34 + html/ldisc.html@1.12 +35 -34 Documentation changes from Dave Mills - html/manyopt.html@1.11, 2005-09-15 02:22:30-04:00, stenn@whimsy.udel.edu +51 -50 + html/manyopt.html@1.11 +51 -50 Documentation changes from Dave Mills - html/measure.html@1.11, 2005-09-15 02:22:30-04:00, stenn@whimsy.udel.edu +16 -15 + html/measure.html@1.11 +16 -15 Documentation changes from Dave Mills - html/miscopt.html@1.31, 2005-09-15 02:22:31-04:00, stenn@whimsy.udel.edu +87 -83 + html/miscopt.html@1.31 +87 -83 Documentation changes from Dave Mills - html/monopt.html@1.20, 2005-09-15 02:22:31-04:00, stenn@whimsy.udel.edu +122 -117 + html/monopt.html@1.20 +122 -117 Documentation changes from Dave Mills - html/msyslog.html@1.4, 2005-09-15 02:22:31-04:00, stenn@whimsy.udel.edu +120 -118 + html/msyslog.html@1.4 +120 -118 Documentation changes from Dave Mills - html/mx4200data.html@1.11, 2005-09-15 02:22:32-04:00, stenn@whimsy.udel.edu +1069 -1068 + html/mx4200data.html@1.11 +1069 -1068 Documentation changes from Dave Mills - html/notes.html@1.17, 2005-09-15 02:22:32-04:00, stenn@whimsy.udel.edu +150 -149 + html/notes.html@1.17 +150 -149 Documentation changes from Dave Mills - html/ntpd.html@1.36.1.1, 2005-09-15 02:22:33-04:00, stenn@whimsy.udel.edu +167 -169 + html/ntpd.html@1.36.1.1 +167 -169 Documentation changes from Dave Mills - html/ntpdate.html@1.17, 2005-09-15 02:22:33-04:00, stenn@whimsy.udel.edu +63 -62 + html/ntpdate.html@1.17 +63 -62 Documentation changes from Dave Mills - html/ntpdc.html@1.20.1.1, 2005-09-15 02:22:33-04:00, stenn@whimsy.udel.edu +153 -152 + html/ntpdc.html@1.20.1.1 +153 -152 Documentation changes from Dave Mills - html/ntpdsim.html@1.4, 2005-09-15 02:22:34-04:00, stenn@whimsy.udel.edu +58 -57 + html/ntpdsim.html@1.4 +58 -57 Documentation changes from Dave Mills - html/ntpq.html@1.27, 2005-09-15 02:22:34-04:00, stenn@whimsy.udel.edu +1 -1 + html/ntpq.html@1.27 +1 -1 Documentation changes from Dave Mills - html/ntptime.html@1.15, 2005-09-15 02:22:34-04:00, stenn@whimsy.udel.edu +41 -40 + html/ntptime.html@1.15 +41 -40 Documentation changes from Dave Mills - html/ntptrace.html@1.13, 2005-09-15 02:22:35-04:00, stenn@whimsy.udel.edu +37 -36 + html/ntptrace.html@1.13 +37 -36 Documentation changes from Dave Mills - html/parsedata.html@1.11, 2005-09-15 02:22:35-04:00, stenn@whimsy.udel.edu +77 -76 + html/parsedata.html@1.11 +77 -76 Documentation changes from Dave Mills - html/parsenew.html@1.10, 2005-09-15 02:22:35-04:00, stenn@whimsy.udel.edu +50 -47 + html/parsenew.html@1.10 +50 -47 Documentation changes from Dave Mills - html/pps.html@1.18, 2005-09-15 02:22:36-04:00, stenn@whimsy.udel.edu +34 -33 + html/pps.html@1.18 +34 -33 Documentation changes from Dave Mills - html/prefer.html@1.15, 2005-09-15 02:22:36-04:00, stenn@whimsy.udel.edu +65 -64 + html/prefer.html@1.15 +65 -64 Documentation changes from Dave Mills - html/rdebug.html@1.15, 2005-09-15 02:22:36-04:00, stenn@whimsy.udel.edu +26 -25 + html/rdebug.html@1.15 +26 -25 Documentation changes from Dave Mills - html/refclock.html@1.32, 2005-09-15 02:22:37-04:00, stenn@whimsy.udel.edu +89 -89 + html/refclock.html@1.32 +89 -89 Documentation changes from Dave Mills - html/release.html@1.30, 2005-09-15 02:22:37-04:00, stenn@whimsy.udel.edu +52 -50 + html/release.html@1.30 +52 -50 Documentation changes from Dave Mills - html/sntp.html@1.4, 2005-09-15 02:22:37-04:00, stenn@whimsy.udel.edu +50 -49 + html/sntp.html@1.4 +50 -49 Documentation changes from Dave Mills - html/tickadj.html@1.14, 2005-09-15 02:22:38-04:00, stenn@whimsy.udel.edu +36 -35 + html/tickadj.html@1.14 +36 -35 Documentation changes from Dave Mills -ChangeSet@1.1251.51.2, 2005-09-15 01:59:15-04:00, stenn@whimsy.udel.edu +10 -0 +ChangeSet@1.1251.51.2, 2005-09-15 01:59:15-04:00, stenn@whimsy.udel.edu "ident" changes from Dave Mills - include/ntp_config.h@1.37.1.1, 2005-09-15 01:57:52-04:00, stenn@whimsy.udel.edu +5 -4 + include/ntp_config.h@1.37.1.1 +5 -4 "ident" changes from Dave Mills - include/ntp_control.h@1.28, 2005-09-15 01:57:53-04:00, stenn@whimsy.udel.edu +2 -1 + include/ntp_control.h@1.28 +2 -1 "ident" changes from Dave Mills - include/ntp_crypto.h@1.36, 2005-09-15 01:57:53-04:00, stenn@whimsy.udel.edu +6 -4 + include/ntp_crypto.h@1.36 +6 -4 "ident" changes from Dave Mills - include/ntpd.h@1.82.4.1, 2005-09-15 01:57:58-04:00, stenn@whimsy.udel.edu +8 -0 + include/ntpd.h@1.82.4.1 +8 -0 "ident" changes from Dave Mills - ntpd/ntp_config.c@1.129.3.2, 2005-09-15 01:58:05-04:00, stenn@whimsy.udel.edu +6 -0 + ntpd/ntp_config.c@1.129.3.2 +6 -0 "ident" changes from Dave Mills - ntpd/ntp_control.c@1.79.1.1, 2005-09-15 01:58:05-04:00, stenn@whimsy.udel.edu +21 -4 + ntpd/ntp_control.c@1.79.1.1 +21 -4 "ident" changes from Dave Mills - ntpd/ntp_crypto.c@1.98.1.1, 2005-09-15 01:58:06-04:00, stenn@whimsy.udel.edu +57 -63 + ntpd/ntp_crypto.c@1.98.1.1 +57 -63 "ident" changes from Dave Mills - ntpd/ntp_loopfilter.c@1.109, 2005-09-15 01:58:07-04:00, stenn@whimsy.udel.edu +41 -8 + ntpd/ntp_loopfilter.c@1.109 +41 -8 "ident" changes from Dave Mills - ntpd/ntp_proto.c@1.232.1.2, 2005-09-15 01:58:08-04:00, stenn@whimsy.udel.edu +4 -8 + ntpd/ntp_proto.c@1.232.1.2 +4 -8 "ident" changes from Dave Mills - ntpd/refclock_wwvb.c@1.16, 2005-09-15 01:58:20-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_wwvb.c@1.16 +1 -1 "ident" changes from Dave Mills -ChangeSet@1.1298, 2005-09-11 22:43:01-04:00, stenn@pogo.udel.edu +35 -0 +ChangeSet@1.1298, 2005-09-11 22:43:01-04:00, stenn@pogo.udel.edu libopts updates - build@1.22, 2005-09-11 22:40:14-04:00, stenn@pogo.udel.edu +6 -0 + build@1.22 +6 -0 libopts updates - m4/libopts.m4@1.7, 2005-09-11 22:41:00-04:00, stenn@pogo.udel.edu +79 -55 + m4/libopts.m4@1.7 +79 -55 libopts updates - ntpd/Makefile.am@1.43, 2005-09-11 22:41:01-04:00, stenn@pogo.udel.edu +1 -1 + ntpd/Makefile.am@1.43 +1 -1 libopts updates - ntpd/ntpd-opts.def@1.2, 2005-09-11 22:41:03-04:00, stenn@pogo.udel.edu +1 -0 + ntpd/ntpd-opts.def@1.2 +1 -0 libopts updates - ntpd/ntpdsim-opts.def@1.2, 2005-09-11 22:41:03-04:00, stenn@pogo.udel.edu +1 -0 + ntpd/ntpdsim-opts.def@1.2 +1 -0 libopts updates - ntpdc/ntpdc-opts.def@1.5, 2005-09-11 22:41:07-04:00, stenn@pogo.udel.edu +1 -0 + ntpdc/ntpdc-opts.def@1.5 +1 -0 libopts updates - ntpq/ntpq-opts.def@1.4, 2005-09-11 22:41:08-04:00, stenn@pogo.udel.edu +1 -0 + ntpq/ntpq-opts.def@1.4 +1 -0 libopts updates - sntp/configure.ac@1.10, 2005-09-11 22:41:15-04:00, stenn@pogo.udel.edu +3 -2 + sntp/configure.ac@1.10 +3 -2 libopts updates - sntp/libopts.m4@1.3, 2005-09-11 22:41:15-04:00, stenn@pogo.udel.edu +79 -55 + sntp/libopts.m4@1.3 +79 -55 libopts updates - sntp/libopts/MakeDefs.inc@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +0 -5 + sntp/libopts/MakeDefs.inc@1.2 +0 -5 libopts updates - sntp/libopts/README@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +9 -7 + sntp/libopts/README@1.2 +9 -7 libopts updates - sntp/libopts/autoopts.c@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/autoopts.c@1.2 +1 -1 libopts updates - sntp/libopts/autoopts.h@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +3 -5 + sntp/libopts/autoopts.h@1.2 +3 -5 libopts updates - sntp/libopts/autoopts/options.h@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +4 -4 + sntp/libopts/autoopts/options.h@1.2 +4 -4 libopts updates - sntp/libopts/boolean.c@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/boolean.c@1.2 +1 -1 libopts updates - sntp/libopts/compat/compat.h@1.2, 2005-09-11 22:41:19-04:00, stenn@pogo.udel.edu +51 -10 + sntp/libopts/compat/compat.h@1.2 +51 -10 libopts updates - sntp/libopts/cook.c@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/cook.c@1.2 +1 -1 libopts updates - sntp/libopts/enumeration.c@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/enumeration.c@1.2 +1 -1 libopts updates - sntp/libopts/environment.c@1.2, 2005-09-11 22:41:16-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/environment.c@1.2 +1 -1 libopts updates - sntp/libopts/libopts.m4@1.2, 2005-09-11 22:41:17-04:00, stenn@pogo.udel.edu +83 -56 + sntp/libopts/libopts.m4@1.2 +83 -56 libopts updates - sntp/libopts/load.c@1.2, 2005-09-11 22:41:17-04:00, stenn@pogo.udel.edu +14 -10 + sntp/libopts/load.c@1.2 +14 -10 libopts updates - sntp/libopts/makeshell.c@1.2, 2005-09-11 22:41:17-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/makeshell.c@1.2 +1 -1 libopts updates - sntp/libopts/nested.c@1.2, 2005-09-11 22:41:17-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/nested.c@1.2 +1 -1 libopts updates - sntp/libopts/numeric.c@1.2, 2005-09-11 22:41:17-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/numeric.c@1.2 +1 -1 libopts updates - sntp/libopts/pgusage.c@1.2, 2005-09-11 22:41:17-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/pgusage.c@1.2 +1 -1 libopts updates - sntp/libopts/proto.h@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -28 + sntp/libopts/proto.h@1.2 +1 -28 libopts updates - sntp/libopts/putshell.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/putshell.c@1.2 +1 -1 libopts updates - sntp/libopts/restore.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/restore.c@1.2 +1 -1 libopts updates - sntp/libopts/save.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/save.c@1.2 +1 -1 libopts updates - sntp/libopts/sort.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/sort.c@1.2 +1 -1 libopts updates - sntp/libopts/stack.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/stack.c@1.2 +1 -1 libopts updates - sntp/libopts/streqvcmp.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/streqvcmp.c@1.2 +1 -1 libopts updates - sntp/libopts/text_mmap.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/text_mmap.c@1.2 +1 -1 libopts updates - sntp/libopts/usage.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/usage.c@1.2 +1 -1 libopts updates - sntp/libopts/version.c@1.2, 2005-09-11 22:41:18-04:00, stenn@pogo.udel.edu +1 -1 + sntp/libopts/version.c@1.2 +1 -1 libopts updates -ChangeSet@1.1251.50.1, 2005-09-06 22:16:23-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.50.1, 2005-09-06 22:16:23-04:00, mayer@pogo.udel.edu Revamped the input_handler code to separate the reading of packets from the selection process and logic - ntpd/ntp_io.c@1.187.2.1, 2005-09-06 22:15:55-04:00, mayer@pogo.udel.edu +250 -283 + ntpd/ntp_io.c@1.187.2.1 +250 -283 Revamped the input_handler code to separate the reading of packets from the selection process and logic -ChangeSet@1.1251.38.40, 2005-09-06 19:34:59+00:00, kardel@pogo.udel.edu +3 -0 +ChangeSet@1.1251.38.40, 2005-09-06 19:34:59+00:00, kardel@pogo.udel.edu ntp_io.c: remove address family agnostic port assignment ntp_proto.c: @@ -17316,41 +198083,41 @@ ChangeSet@1.1251.38.40, 2005-09-06 19:34:59+00:00, kardel@pogo.udel.edu +3 -0 ntp_peer.c: only call peer_crypto_clear() when disconnecting the interface - ntpd/ntp_io.c@1.207, 2005-09-06 19:33:08+00:00, kardel@pogo.udel.edu +0 -1 + ntpd/ntp_io.c@1.207 +0 -1 remove address family agnostic port assignment - ntpd/ntp_peer.c@1.90, 2005-09-04 10:28:53+00:00, kardel@pogo.udel.edu +15 -6 + ntpd/ntp_peer.c@1.90 +15 -6 only call peer_crypto_clear() when disconnecting the interface - ntpd/ntp_proto.c@1.238, 2005-09-04 10:29:51+00:00, kardel@pogo.udel.edu +6 -5 + ntpd/ntp_proto.c@1.238 +6 -5 minor debug code cleanup -ChangeSet@1.1251.1.142, 2005-09-04 15:32:05-05:00, stenn@poog.il.thewrittenword.com +1 -0 +ChangeSet@1.1251.1.142, 2005-09-04 15:32:05-05:00, stenn@poog.il.thewrittenword.com scopeid and WANT_IPV6 cleanup - ntpd/ntp_io.c@1.187.1.1, 2005-09-04 15:31:35-05:00, stenn@poog.il.thewrittenword.com +18 -6 + ntpd/ntp_io.c@1.187.1.1 +18 -6 scopeid and WANT_IPV6 cleanup -ChangeSet@1.1251.49.1, 2005-09-04 06:44:18+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.49.1, 2005-09-04 06:44:18+00:00, kardel@pogo.udel.edu configure.ac: with NetBSD 3.99.8 the CTTY requirement has been lifted - configure.ac@1.359.3.1, 2005-09-04 06:42:31+00:00, kardel@pogo.udel.edu +3 -3 + configure.ac@1.359.3.1 +3 -3 with NetBSD 3.99.8 the CTTY requirement has been lifted -ChangeSet@1.1251.47.6, 2005-09-01 21:52:27-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.47.6, 2005-09-01 21:52:27-04:00, stenn@pogo.udel.edu net/route.h fixups - configure.ac@1.359.1.19, 2005-09-01 21:52:04-04:00, stenn@pogo.udel.edu +5 -1 + configure.ac@1.359.1.19 +5 -1 net/route.h fixups -ChangeSet@1.1251.47.5, 2005-09-01 05:11:00-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.47.5, 2005-09-01 05:11:00-04:00, stenn@pogo.udel.edu look for net/route.h and struct rt_msghdr - configure.ac@1.359.1.18, 2005-09-01 05:10:49-04:00, stenn@pogo.udel.edu +16 -0 + configure.ac@1.359.1.18 +16 -0 look for net/route.h and struct rt_msghdr -ChangeSet@1.1251.38.37, 2005-09-01 08:01:32+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1251.38.37, 2005-09-01 08:01:32+00:00, kardel@pogo.udel.edu ntp_proto.c: avoid double free by cleaning up peer_crypto_clear() as the clear_to_zero trick didn't work any more here and @@ -17358,692 +198125,692 @@ ChangeSet@1.1251.38.37, 2005-09-01 08:01:32+00:00, kardel@pogo.udel.edu +2 -0 ntp_crypto.c: mark possible memleak - MUST be verified - ntpd/ntp_crypto.c@1.100, 2005-09-01 07:59:08+00:00, kardel@pogo.udel.edu +3 -0 + ntpd/ntp_crypto.c@1.100 +3 -0 mark possible memleak - MUST be verified - ntpd/ntp_proto.c@1.237, 2005-09-01 07:59:43+00:00, kardel@pogo.udel.edu +35 -7 + ntpd/ntp_proto.c@1.237 +35 -7 avoid double free by cleaning up peer_crypto_clear() as the clear_to_zero trick didn't work any more here and also covered up some memory leaks. -ChangeSet@1.1178.6.1, 2005-08-31 18:35:44-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1178.6.1, 2005-08-31 18:35:44-04:00, stenn@pogo.udel.edu lose snavely - flock-build@1.30.1.1, 2005-08-31 18:35:34-04:00, stenn@pogo.udel.edu +2 -2 + flock-build@1.30.1.1 +2 -2 lose snavely -ChangeSet@1.1251.38.36, 2005-08-31 08:05:42+00:00, kardel@pogo.udel.edu +6 -0 +ChangeSet@1.1251.38.36, 2005-08-31 08:05:42+00:00, kardel@pogo.udel.edu ntpdc_ops.c, layout.std, ntp_request.c, ntp_io.c, ntp_request.h, ntp.h: output interface life time in log and via ntpdc - include/ntp.h@1.125, 2005-08-31 08:04:57+00:00, kardel@pogo.udel.edu +1 -0 + include/ntp.h@1.125 +1 -0 output interface life time in log and via ntpdc - include/ntp_request.h@1.28, 2005-08-31 08:04:58+00:00, kardel@pogo.udel.edu +1 -0 + include/ntp_request.h@1.28 +1 -0 output interface life time in log and via ntpdc - ntpd/ntp_io.c@1.206, 2005-08-31 08:05:09+00:00, kardel@pogo.udel.edu +7 -2 + ntpd/ntp_io.c@1.206 +7 -2 output interface life time in log and via ntpdc - ntpd/ntp_request.c@1.64, 2005-08-31 08:05:10+00:00, kardel@pogo.udel.edu +1 -0 + ntpd/ntp_request.c@1.64 +1 -0 output interface life time in log and via ntpdc - ntpdc/layout.std@1.6, 2005-08-31 08:05:14+00:00, kardel@pogo.udel.edu +8 -7 + ntpdc/layout.std@1.6 +8 -7 output interface life time in log and via ntpdc - ntpdc/ntpdc_ops.c@1.44, 2005-08-31 08:05:15+00:00, kardel@pogo.udel.edu +6 -5 + ntpdc/ntpdc_ops.c@1.44 +6 -5 output interface life time in log and via ntpdc -ChangeSet@1.1251.38.35, 2005-08-29 20:50:15+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1251.38.35, 2005-08-29 20:50:15+00:00, kardel@pogo.udel.edu ntp_peer.c: just disconnect from interface when no interface can be found ntp_io.c: rename HAS_BSD_ROUTING_SOCKET to HAS_ROUTING_SOCKET - ntpd/ntp_io.c@1.205, 2005-08-29 20:48:09+00:00, kardel@pogo.udel.edu +9 -9 + ntpd/ntp_io.c@1.205 +9 -9 rename HAS_BSD_ROUTING_SOCKET to HAS_ROUTING_SOCKET - ntpd/ntp_peer.c@1.89, 2005-08-29 20:49:02+00:00, kardel@pogo.udel.edu +1 -15 + ntpd/ntp_peer.c@1.89 +1 -15 just disconnect from interface when no interface can be found -ChangeSet@1.1251.38.34, 2005-08-29 11:36:25+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.34, 2005-08-29 11:36:25+00:00, kardel@pogo.udel.edu ntp_io.c: fix compile conditional for asyncio_readers make RTM_IFINFO also optional make RTM_IFANNOUNCE optional to compile on platforms that that have that message (Solaris) - ntpd/ntp_io.c@1.204, 2005-08-29 11:24:27+00:00, kardel@pogo.udel.edu +5 -5 + ntpd/ntp_io.c@1.204 +5 -5 fix compile conditional for asyncio_readers - ntpd/ntp_io.c@1.203, 2005-08-29 11:15:04+00:00, kardel@pogo.udel.edu +2 -0 + ntpd/ntp_io.c@1.203 +2 -0 make RTM_IFINFO also optional - ntpd/ntp_io.c@1.202, 2005-08-29 11:05:23+00:00, kardel@pogo.udel.edu +2 -0 + ntpd/ntp_io.c@1.202 +2 -0 make RTM_IFANNOUNCE optional to compile on platforms that that have that message (Solaris) -ChangeSet@1.1251.38.33, 2005-08-29 10:23:15+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.33, 2005-08-29 10:23:15+00:00, kardel@pogo.udel.edu ntp_io.c: cleanup compilation for HAS_BSD_ROUTING_SOCKET in undefined case move on variable into corresponding conditional block - ntpd/ntp_io.c@1.201, 2005-08-29 10:19:59+00:00, kardel@pogo.udel.edu +18 -9 + ntpd/ntp_io.c@1.201 +18 -9 cleanup compilation for HAS_BSD_ROUTING_SOCKET in undefined case move on variable into corresponding conditional block -ChangeSet@1.1251.38.31, 2005-08-28 15:49:21-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.31, 2005-08-28 15:49:21-04:00, mayer@pogo.udel.edu Remove O/S Specific macro and add conditions for SUPPORT_ASYNCIO_READER that replaced it - ntpd/ntp_io.c@1.197.1.1, 2005-08-28 15:48:45-04:00, mayer@pogo.udel.edu +6 -3 + ntpd/ntp_io.c@1.197.1.1 +6 -3 Remove O/S Specific macro and add conditions for SUPPORT_ASYNCIO_READER that replaced it -ChangeSet@1.1295, 2005-08-28 04:51:03-04:00, stenn@pogo.udel.edu +5 -0 +ChangeSet@1.1295, 2005-08-28 04:51:03-04:00, stenn@pogo.udel.edu libopts cleanup - Makefile.am@1.54, 2005-08-28 04:48:59-04:00, stenn@pogo.udel.edu +0 -2 + Makefile.am@1.54 +0 -2 libopts cleanup - configure.ac@1.374, 2005-08-28 04:49:00-04:00, stenn@pogo.udel.edu +1 -1 + configure.ac@1.374 +1 -1 libopts cleanup - m4/libopts.m4@1.6, 2005-08-28 04:49:38-04:00, stenn@pogo.udel.edu +8 -5 + m4/libopts.m4@1.6 +8 -5 libopts cleanup - sntp/Makefile.am@1.8, 2005-08-28 04:49:50-04:00, stenn@pogo.udel.edu +0 -1 + sntp/Makefile.am@1.8 +0 -1 libopts cleanup - sntp/libopts.m4@1.2, 2005-08-28 04:49:51-04:00, stenn@pogo.udel.edu +8 -5 + sntp/libopts.m4@1.2 +8 -5 libopts cleanup -ChangeSet@1.1251.48.3, 2005-08-28 08:37:28+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.48.3, 2005-08-28 08:37:28+00:00, kardel@pogo.udel.edu ntp_io.c: more enum cleanup - ntpd/ntp_io.c@1.199, 2005-08-28 08:36:06+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.199 +1 -1 more enum cleanup -ChangeSet@1.1251.48.2, 2005-08-28 07:37:24+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.48.2, 2005-08-28 07:37:24+00:00, kardel@pogo.udel.edu ntp_io.c: add FreeBSD for routing socket notification - ntpd/ntp_io.c@1.198, 2005-08-28 07:36:29+00:00, kardel@pogo.udel.edu +3 -1 + ntpd/ntp_io.c@1.198 +3 -1 add FreeBSD for routing socket notification -ChangeSet@1.1251.48.1, 2005-08-28 06:43:17+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.48.1, 2005-08-28 06:43:17+00:00, kardel@pogo.udel.edu ntpd.h: typoe - include/ntpd.h@1.82.1.9, 2005-08-27 23:20:18+00:00, kardel@pogo.udel.edu +1 -1 + include/ntpd.h@1.82.1.9 +1 -1 typoe -ChangeSet@1.1251.38.30, 2005-08-27 22:03:00-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.30, 2005-08-27 22:03:00-04:00, mayer@pogo.udel.edu Fixed mispelled function - include/ntpd.h@1.82.3.1, 2005-08-27 22:02:43-04:00, mayer@pogo.udel.edu +1 -1 + include/ntpd.h@1.82.3.1 +1 -1 Fixed mispelled function -ChangeSet@1.1251.38.29, 2005-08-27 23:08:36+00:00, kardel@pogo.udel.edu +3 -0 +ChangeSet@1.1251.38.29, 2005-08-27 23:08:36+00:00, kardel@pogo.udel.edu add async io readers (non-refclock, non-socket input) re-factor (simplify) descriptor handling add routing socket listening for quick interface updates - include/ntpd.h@1.82.1.8, 2005-08-27 23:02:32+00:00, kardel@pogo.udel.edu +2 -0 + include/ntpd.h@1.82.1.8 +2 -0 - ntpd/ntp_io.c@1.197, 2005-08-27 23:02:42+00:00, kardel@pogo.udel.edu +354 -249 + ntpd/ntp_io.c@1.197 +354 -249 - ntpd/ntp_timer.c@1.30, 2005-08-27 23:02:44+00:00, kardel@pogo.udel.edu +7 -1 + ntpd/ntp_timer.c@1.30 +7 -1 -ChangeSet@1.1251.47.2, 2005-08-26 17:47:52-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.47.2, 2005-08-26 17:47:52-04:00, mayer@pogo.udel.edu add ntp_random.h to include list - libntp/systime.c@1.35, 2005-08-26 17:47:29-04:00, mayer@pogo.udel.edu +1 -0 + libntp/systime.c@1.35 +1 -0 add ntp_random.h to include list -ChangeSet@1.1251.47.1, 2005-08-26 17:12:27-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.47.1, 2005-08-26 17:12:27-04:00, mayer@pogo.udel.edu Additional changes to support ntp_random - include/Makefile.am@1.19.1.1, 2005-08-26 17:12:02-04:00, mayer@pogo.udel.edu +1 -0 + include/Makefile.am@1.19.1.1 +1 -0 Additional changes to support ntp_random - util/ntp-keygen.c@1.33, 2005-08-26 17:12:02-04:00, mayer@pogo.udel.edu +1 -0 + util/ntp-keygen.c@1.33 +1 -0 Additional changes to support ntp_random -ChangeSet@1.1251.38.26, 2005-08-26 09:17:19-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.26, 2005-08-26 09:17:19-04:00, mayer@pogo.udel.edu Added ntp_debug.h - include/Makefile.am@1.20, 2005-08-26 09:17:04-04:00, mayer@pogo.udel.edu +2 -0 + include/Makefile.am@1.20 +2 -0 Added ntp_debug.h -ChangeSet@1.1293, 2005-08-26 04:40:05-04:00, stenn@pogo.udel.edu +9 -0 +ChangeSet@1.1293, 2005-08-26 04:40:05-04:00, stenn@pogo.udel.edu autogen stuff - BitKeeper/etc/ignore@1.44, 2005-08-26 04:39:02-04:00, stenn@pogo.udel.edu +40 -48 + BitKeeper/etc/ignore@1.44 +40 -48 Update the ignore list - BitKeeper/etc/ignore@1.43, 2005-08-26 04:26:21-04:00, stenn@pogo.udel.edu +3 -0 + BitKeeper/etc/ignore@1.43 +3 -0 added ntpd/ntpd.1 ntpd/ntpdsim.1 sntp/sntp.1 - BitKeeper/etc/ignore@1.42, 2005-08-26 04:25:08-04:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/ignore@1.42 +1 -0 added *-opts.texi - BitKeeper/etc/ignore@1.41, 2005-08-26 04:25:02-04:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/ignore@1.41 +1 -0 added *-opts.menu - BitKeeper/etc/ignore@1.40, 2005-08-26 04:24:24-04:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/ignore@1.40 +1 -0 added *-opts.h - BitKeeper/etc/ignore@1.39, 2005-08-26 04:24:21-04:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/ignore@1.39 +1 -0 added *-opts.c - Makefile.am@1.53, 2005-08-26 04:20:12-04:00, stenn@pogo.udel.edu +3 -3 + Makefile.am@1.53 +3 -3 new libopts stuff - configure.ac@1.373, 2005-08-26 04:20:13-04:00, stenn@pogo.udel.edu +0 -1 + configure.ac@1.373 +0 -1 new libopts stuff - m4/libopts.m4@1.5, 2005-08-26 04:38:44-04:00, stenn@pogo.udel.edu +1 -1 + m4/libopts.m4@1.5 +1 -1 changes for 1 copy of libopts - m4/libopts.m4@1.4, 2005-08-26 04:20:13-04:00, stenn@pogo.udel.edu +147 -94 + m4/libopts.m4@1.4 +147 -94 new libopts stuff - ntpd/ntpd-opts.def@1.1, 2005-08-26 04:18:41-04:00, stenn@pogo.udel.edu +42 -0 + ntpd/ntpd-opts.def@1.1 +42 -0 - ntpd/ntpd-opts.def@1.0, 2005-08-26 04:18:41-04:00, stenn@pogo.udel.edu +0 -0 + ntpd/ntpd-opts.def@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/ntpd/ntpd-opts.def - ntpd/ntpdbase-opts.def@1.1, 2005-08-26 04:18:41-04:00, stenn@pogo.udel.edu +472 -0 + ntpd/ntpdbase-opts.def@1.1 +472 -0 - ntpd/ntpdbase-opts.def@1.0, 2005-08-26 04:18:41-04:00, stenn@pogo.udel.edu +0 -0 + ntpd/ntpdbase-opts.def@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/ntpd/ntpdbase-opts.def - ntpd/ntpdsim-opts.def@1.1, 2005-08-26 04:18:41-04:00, stenn@pogo.udel.edu +43 -0 + ntpd/ntpdsim-opts.def@1.1 +43 -0 - ntpd/ntpdsim-opts.def@1.0, 2005-08-26 04:18:41-04:00, stenn@pogo.udel.edu +0 -0 + ntpd/ntpdsim-opts.def@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/ntpd/ntpdsim-opts.def - sntp/libopts.m4@1.1, 2005-08-26 04:20:29-04:00, stenn@pogo.udel.edu +418 -0 + sntp/libopts.m4@1.1 +418 -0 - sntp/libopts.m4@1.0, 2005-08-26 04:20:29-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts.m4@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts.m4 - sntp/sntp-opts.def@1.1, 2005-08-26 04:18:42-04:00, stenn@pogo.udel.edu +388 -0 + sntp/sntp-opts.def@1.1 +388 -0 - sntp/sntp-opts.def@1.0, 2005-08-26 04:18:42-04:00, stenn@pogo.udel.edu +0 -0 + sntp/sntp-opts.def@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/sntp-opts.def -ChangeSet@1.1292, 2005-08-26 04:17:32-04:00, stenn@pogo.udel.edu +36 -0 +ChangeSet@1.1292, 2005-08-26 04:17:32-04:00, stenn@pogo.udel.edu New sntp/libopts/ - sntp/libopts/COPYING.lgpl@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +502 -0 + sntp/libopts/COPYING.lgpl@1.1 +502 -0 - sntp/libopts/COPYING.lgpl@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/COPYING.lgpl@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/COPYING.lgpl - sntp/libopts/COPYING.mbsd@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +26 -0 + sntp/libopts/COPYING.mbsd@1.1 +26 -0 - sntp/libopts/COPYING.mbsd@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/COPYING.mbsd@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/COPYING.mbsd - sntp/libopts/MakeDefs.inc@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +5 -0 + sntp/libopts/MakeDefs.inc@1.1 +5 -0 - sntp/libopts/MakeDefs.inc@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/MakeDefs.inc@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/MakeDefs.inc - sntp/libopts/Makefile.am@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +19 -0 + sntp/libopts/Makefile.am@1.1 +19 -0 - sntp/libopts/Makefile.am@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/Makefile.am@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/Makefile.am - sntp/libopts/README@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +89 -0 + sntp/libopts/README@1.1 +89 -0 - sntp/libopts/README@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/README@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/README - sntp/libopts/autoopts.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +1033 -0 + sntp/libopts/autoopts.c@1.1 +1033 -0 - sntp/libopts/autoopts.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/autoopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/autoopts.c - sntp/libopts/autoopts.h@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +350 -0 + sntp/libopts/autoopts.h@1.1 +350 -0 - sntp/libopts/autoopts.h@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/autoopts.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/autoopts.h - sntp/libopts/autoopts/options.h@1.1, 2005-08-26 04:16:29-04:00, stenn@pogo.udel.edu +864 -0 + sntp/libopts/autoopts/options.h@1.1 +864 -0 - sntp/libopts/autoopts/options.h@1.0, 2005-08-26 04:16:29-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/autoopts/options.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/autoopts/options.h - sntp/libopts/autoopts/usage-txt.h@1.1, 2005-08-26 04:16:29-04:00, stenn@pogo.udel.edu +479 -0 + sntp/libopts/autoopts/usage-txt.h@1.1 +479 -0 - sntp/libopts/autoopts/usage-txt.h@1.0, 2005-08-26 04:16:29-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/autoopts/usage-txt.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/autoopts/usage-txt.h - sntp/libopts/boolean.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +102 -0 + sntp/libopts/boolean.c@1.1 +102 -0 - sntp/libopts/boolean.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/boolean.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/boolean.c - sntp/libopts/compat/compat.h@1.1, 2005-08-26 04:16:36-04:00, stenn@pogo.udel.edu +249 -0 + sntp/libopts/compat/compat.h@1.1 +249 -0 - sntp/libopts/compat/compat.h@1.0, 2005-08-26 04:16:36-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/compat/compat.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/compat/compat.h - sntp/libopts/compat/pathfind.c@1.1, 2005-08-26 04:16:36-04:00, stenn@pogo.udel.edu +330 -0 + sntp/libopts/compat/pathfind.c@1.1 +330 -0 - sntp/libopts/compat/pathfind.c@1.0, 2005-08-26 04:16:36-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/compat/pathfind.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/compat/pathfind.c - sntp/libopts/configfile.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +1277 -0 + sntp/libopts/configfile.c@1.1 +1277 -0 - sntp/libopts/configfile.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/configfile.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/configfile.c - sntp/libopts/cook.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +355 -0 + sntp/libopts/cook.c@1.1 +355 -0 - sntp/libopts/cook.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/cook.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/cook.c - sntp/libopts/enumeration.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +449 -0 + sntp/libopts/enumeration.c@1.1 +449 -0 - sntp/libopts/enumeration.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/enumeration.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/enumeration.c - sntp/libopts/environment.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +261 -0 + sntp/libopts/environment.c@1.1 +261 -0 - sntp/libopts/environment.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/environment.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/environment.c - sntp/libopts/genshell.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +300 -0 + sntp/libopts/genshell.c@1.1 +300 -0 - sntp/libopts/genshell.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/genshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/genshell.c - sntp/libopts/genshell.h@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +143 -0 + sntp/libopts/genshell.h@1.1 +143 -0 - sntp/libopts/genshell.h@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/genshell.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/genshell.h - sntp/libopts/libopts.c@1.1, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +29 -0 + sntp/libopts/libopts.c@1.1 +29 -0 - sntp/libopts/libopts.c@1.0, 2005-08-26 04:16:19-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/libopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/libopts.c - sntp/libopts/libopts.m4@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +418 -0 + sntp/libopts/libopts.m4@1.1 +418 -0 - sntp/libopts/libopts.m4@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/libopts.m4@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/libopts.m4 - sntp/libopts/load.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +516 -0 + sntp/libopts/load.c@1.1 +516 -0 - sntp/libopts/load.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/load.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/load.c - sntp/libopts/makeshell.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +1100 -0 + sntp/libopts/makeshell.c@1.1 +1100 -0 - sntp/libopts/makeshell.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/makeshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/makeshell.c - sntp/libopts/nested.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +705 -0 + sntp/libopts/nested.c@1.1 +705 -0 - sntp/libopts/nested.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/nested.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/nested.c - sntp/libopts/numeric.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +89 -0 + sntp/libopts/numeric.c@1.1 +89 -0 - sntp/libopts/numeric.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/numeric.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/numeric.c - sntp/libopts/pgusage.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +154 -0 + sntp/libopts/pgusage.c@1.1 +154 -0 - sntp/libopts/pgusage.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/pgusage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/pgusage.c - sntp/libopts/proto.h@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +124 -0 + sntp/libopts/proto.h@1.1 +124 -0 - sntp/libopts/proto.h@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/proto.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/proto.h - sntp/libopts/putshell.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +333 -0 + sntp/libopts/putshell.c@1.1 +333 -0 - sntp/libopts/putshell.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/putshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/putshell.c - sntp/libopts/restore.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +207 -0 + sntp/libopts/restore.c@1.1 +207 -0 - sntp/libopts/restore.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/restore.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/restore.c - sntp/libopts/save.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +499 -0 + sntp/libopts/save.c@1.1 +499 -0 - sntp/libopts/save.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/save.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/save.c - sntp/libopts/sort.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +369 -0 + sntp/libopts/sort.c@1.1 +369 -0 - sntp/libopts/sort.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/sort.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/sort.c - sntp/libopts/stack.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +224 -0 + sntp/libopts/stack.c@1.1 +224 -0 - sntp/libopts/stack.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/stack.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/stack.c - sntp/libopts/streqvcmp.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +292 -0 + sntp/libopts/streqvcmp.c@1.1 +292 -0 - sntp/libopts/streqvcmp.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/streqvcmp.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/streqvcmp.c - sntp/libopts/text_mmap.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +312 -0 + sntp/libopts/text_mmap.c@1.1 +312 -0 - sntp/libopts/text_mmap.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/text_mmap.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/text_mmap.c - sntp/libopts/tokenize.c@1.1, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +322 -0 + sntp/libopts/tokenize.c@1.1 +322 -0 - sntp/libopts/tokenize.c@1.0, 2005-08-26 04:16:20-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/tokenize.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/tokenize.c - sntp/libopts/usage.c@1.1, 2005-08-26 04:16:21-04:00, stenn@pogo.udel.edu +651 -0 + sntp/libopts/usage.c@1.1 +651 -0 - sntp/libopts/usage.c@1.0, 2005-08-26 04:16:21-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/usage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/usage.c - sntp/libopts/version.c@1.1, 2005-08-26 04:16:21-04:00, stenn@pogo.udel.edu +177 -0 + sntp/libopts/version.c@1.1 +177 -0 - sntp/libopts/version.c@1.0, 2005-08-26 04:16:21-04:00, stenn@pogo.udel.edu +0 -0 + sntp/libopts/version.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/sntp/libopts/version.c -ChangeSet@1.1291, 2005-08-26 04:14:47-04:00, stenn@pogo.udel.edu +82 -0 +ChangeSet@1.1291, 2005-08-26 04:14:47-04:00, stenn@pogo.udel.edu Remove old libopts/ - BitKeeper/deleted/.del-AUTHORS~919220bd6931acb6@1.2, 2005-08-26 04:10:25-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-AUTHORS~919220bd6931acb6@1.2 +0 -0 Delete: libopts/AUTHORS - BitKeeper/deleted/.del-COPYING.lgpl~853519b5bad8e831@1.2, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-COPYING.lgpl~853519b5bad8e831@1.2 +0 -0 Delete: libopts/COPYING.lgpl - BitKeeper/deleted/.del-COPYING.mbsd~aff4e32ff033d919@1.2, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-COPYING.mbsd~aff4e32ff033d919@1.2 +0 -0 Delete: libopts/COPYING.mbsd - BitKeeper/deleted/.del-COPYING~8c2b7b26f1103860@1.2, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-COPYING~8c2b7b26f1103860@1.2 +0 -0 Delete: libopts/COPYING - BitKeeper/deleted/.del-ChangeLog~c979333e966b22d9@1.2, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-ChangeLog~c979333e966b22d9@1.2 +0 -0 Delete: libopts/ChangeLog - BitKeeper/deleted/.del-INSTALL~ca12b1677cba0915@1.3, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-INSTALL~ca12b1677cba0915@1.3 +0 -0 Delete: libopts/INSTALL - BitKeeper/deleted/.del-MakeDefs.inc~c24ab9f3f0dafc84@1.2, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-MakeDefs.inc~c24ab9f3f0dafc84@1.2 +0 -0 Delete: libopts/MakeDefs.inc - BitKeeper/deleted/.del-Makefile.am~11c11bf4e04c9fef@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-Makefile.am~11c11bf4e04c9fef@1.2 +0 -0 Delete: libopts/libopts/Makefile.am - BitKeeper/deleted/.del-Makefile.am~b09ab3b23945dc7d@1.2, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-Makefile.am~b09ab3b23945dc7d@1.2 +0 -0 Delete: libopts/Makefile.am - BitKeeper/deleted/.del-NEWS~e38f345aacec5424@1.2, 2005-08-26 04:10:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-NEWS~e38f345aacec5424@1.2 +0 -0 Delete: libopts/NEWS - BitKeeper/deleted/.del-README~3d9dfae6a0b32f8f@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-README~3d9dfae6a0b32f8f@1.2 +0 -0 Delete: libopts/README - BitKeeper/deleted/.del-aclocal.m4~a95cc6b1d68ce121@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-aclocal.m4~a95cc6b1d68ce121@1.2 +0 -0 Delete: libopts/aclocal.m4 - BitKeeper/deleted/.del-autoopts.c~4dc696de338cb6ff@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-autoopts.c~4dc696de338cb6ff@1.2 +0 -0 Delete: libopts/autoopts.c - BitKeeper/deleted/.del-autoopts.c~7c82dc5b2088549a@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-autoopts.c~7c82dc5b2088549a@1.2 +0 -0 Delete: libopts/libopts/autoopts.c - BitKeeper/deleted/.del-autoopts.h~173454953926d863@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-autoopts.h~173454953926d863@1.2 +0 -0 Delete: libopts/libopts/autoopts.h - BitKeeper/deleted/.del-autoopts.h~fd482d3a2757e6af@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-autoopts.h~fd482d3a2757e6af@1.2 +0 -0 Delete: libopts/autoopts.h - BitKeeper/deleted/.del-boolean.c~2652efe8d27b68e9@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-boolean.c~2652efe8d27b68e9@1.2 +0 -0 Delete: libopts/libopts/boolean.c - BitKeeper/deleted/.del-boolean.c~9803ac347fdb027d@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-boolean.c~9803ac347fdb027d@1.2 +0 -0 Delete: libopts/boolean.c - BitKeeper/deleted/.del-bootstrap~9952937cb65f4e1f@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-bootstrap~9952937cb65f4e1f@1.2 +0 -0 Delete: libopts/bootstrap - BitKeeper/deleted/.del-compat.h~cd9fa19720e0fe1c@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-compat.h~cd9fa19720e0fe1c@1.2 +0 -0 Delete: libopts/compat/compat.h - BitKeeper/deleted/.del-compile~f47b1af5aede22b6@1.3, 2005-08-26 04:10:35-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-compile~f47b1af5aede22b6@1.3 +0 -0 Delete: libopts/m4/compile - BitKeeper/deleted/.del-config-h.in~8d2fefd4275dba47@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-config-h.in~8d2fefd4275dba47@1.2 +0 -0 Delete: libopts/config-h.in - BitKeeper/deleted/.del-config-h.in~~fc94cec5e99b4813@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-config-h.in~~fc94cec5e99b4813@1.2 +0 -0 Delete: libopts/config-h.in~ - BitKeeper/deleted/.del-config.guess~8473c3316e92525f@1.3, 2005-08-26 04:10:35-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-config.guess~8473c3316e92525f@1.3 +0 -0 Delete: libopts/m4/config.guess - BitKeeper/deleted/.del-config.sub~bf4f78cdfb8642b@1.3, 2005-08-26 04:10:35-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-config.sub~bf4f78cdfb8642b@1.3 +0 -0 Delete: libopts/m4/config.sub - BitKeeper/deleted/.del-configfile.c~87486f85c5694535@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-configfile.c~87486f85c5694535@1.2 +0 -0 Delete: libopts/libopts/configfile.c - BitKeeper/deleted/.del-configfile.c~922a8f1381d4425f@1.2, 2005-08-26 04:10:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-configfile.c~922a8f1381d4425f@1.2 +0 -0 Delete: libopts/configfile.c - BitKeeper/deleted/.del-configure.ac~1f0f0eec3e2cb683@1.2, 2005-08-26 04:10:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-configure.ac~1f0f0eec3e2cb683@1.2 +0 -0 Delete: libopts/configure.ac - BitKeeper/deleted/.del-configure~76f3b0b55a913ee5@1.2, 2005-08-26 04:10:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-configure~76f3b0b55a913ee5@1.2 +0 -0 Delete: libopts/configure - BitKeeper/deleted/.del-cook.c~288d493179287c2@1.2, 2005-08-26 04:10:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-cook.c~288d493179287c2@1.2 +0 -0 Delete: libopts/cook.c - BitKeeper/deleted/.del-cook.c~513ed79970fc81b@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-cook.c~513ed79970fc81b@1.2 +0 -0 Delete: libopts/libopts/cook.c - BitKeeper/deleted/.del-depcomp~40528c8625c2eb1f@1.3, 2005-08-26 04:10:35-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-depcomp~40528c8625c2eb1f@1.3 +0 -0 Delete: libopts/m4/depcomp - BitKeeper/deleted/.del-enumeration.c~680ef3a6fda2472@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-enumeration.c~680ef3a6fda2472@1.2 +0 -0 Delete: libopts/libopts/enumeration.c - BitKeeper/deleted/.del-enumeration.c~741b004a8edc0491@1.2, 2005-08-26 04:10:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-enumeration.c~741b004a8edc0491@1.2 +0 -0 Delete: libopts/enumeration.c - BitKeeper/deleted/.del-environment.c~886b51f1289ec004@1.2, 2005-08-26 04:10:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-environment.c~886b51f1289ec004@1.2 +0 -0 Delete: libopts/environment.c - BitKeeper/deleted/.del-environment.c~cbea5891d018489b@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-environment.c~cbea5891d018489b@1.2 +0 -0 Delete: libopts/libopts/environment.c - BitKeeper/deleted/.del-genshell.c~4665114445e930eb@1.2, 2005-08-26 04:10:32-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-genshell.c~4665114445e930eb@1.2 +0 -0 Delete: libopts/libopts/genshell.c - BitKeeper/deleted/.del-genshell.c~d3404cb6e62977d2@1.2, 2005-08-26 04:10:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-genshell.c~d3404cb6e62977d2@1.2 +0 -0 Delete: libopts/genshell.c - BitKeeper/deleted/.del-genshell.h~4cbba4ca99e1ce0d@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-genshell.h~4cbba4ca99e1ce0d@1.2 +0 -0 Delete: libopts/libopts/genshell.h - BitKeeper/deleted/.del-genshell.h~9fcd6a369b750dc@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-genshell.h~9fcd6a369b750dc@1.2 +0 -0 Delete: libopts/genshell.h - BitKeeper/deleted/.del-install-sh~5350b467a9780ac5@1.3, 2005-08-26 04:10:35-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-install-sh~5350b467a9780ac5@1.3 +0 -0 Delete: libopts/m4/install-sh - BitKeeper/deleted/.del-libopts.c~322a932038fac5bb@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-libopts.c~322a932038fac5bb@1.2 +0 -0 Delete: libopts/libopts.c - BitKeeper/deleted/.del-libopts.c~a3b1fda2ee8709ec@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-libopts.c~a3b1fda2ee8709ec@1.2 +0 -0 Delete: libopts/libopts/libopts.c - BitKeeper/deleted/.del-libopts.m4~71eb82c61ddaa00e@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-libopts.m4~71eb82c61ddaa00e@1.2 +0 -0 Delete: libopts/libopts.m4 - BitKeeper/deleted/.del-libopts.m4~dba275de2f39a7f7@1.2, 2005-08-26 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-libopts.m4~dba275de2f39a7f7@1.2 +0 -0 Delete: libopts/m4/libopts.m4 - BitKeeper/deleted/.del-load.c~7f48d00d8b58104a@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-load.c~7f48d00d8b58104a@1.2 +0 -0 Delete: libopts/libopts/load.c - BitKeeper/deleted/.del-load.c~b61a8aee9ce882d5@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-load.c~b61a8aee9ce882d5@1.2 +0 -0 Delete: libopts/load.c - BitKeeper/deleted/.del-ltmain.sh~1c7887b5d1c077fc@1.3, 2005-08-26 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-ltmain.sh~1c7887b5d1c077fc@1.3 +0 -0 Delete: libopts/m4/ltmain.sh - BitKeeper/deleted/.del-makeshell.c~a1d60647811b3095@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-makeshell.c~a1d60647811b3095@1.2 +0 -0 Delete: libopts/libopts/makeshell.c - BitKeeper/deleted/.del-makeshell.c~f8b9cf5964d39db3@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-makeshell.c~f8b9cf5964d39db3@1.2 +0 -0 Delete: libopts/makeshell.c - BitKeeper/deleted/.del-missing~f915814376b31ab6@1.3, 2005-08-26 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-missing~f915814376b31ab6@1.3 +0 -0 Delete: libopts/m4/missing - BitKeeper/deleted/.del-nested.c~86ef6834b872d57@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-nested.c~86ef6834b872d57@1.2 +0 -0 Delete: libopts/libopts/nested.c - BitKeeper/deleted/.del-nested.c~96ea01864b196d05@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-nested.c~96ea01864b196d05@1.2 +0 -0 Delete: libopts/nested.c - BitKeeper/deleted/.del-numeric.c~e2c152233ded2202@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-numeric.c~e2c152233ded2202@1.2 +0 -0 Delete: libopts/numeric.c - BitKeeper/deleted/.del-numeric.c~f02f2a6d69035d0c@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-numeric.c~f02f2a6d69035d0c@1.2 +0 -0 Delete: libopts/libopts/numeric.c - BitKeeper/deleted/.del-options.h~7de16fb1feb01fb9@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-options.h~7de16fb1feb01fb9@1.2 +0 -0 Delete: libopts/autoopts/options.h - BitKeeper/deleted/.del-pathfind.c~4df984bf91869e5@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-pathfind.c~4df984bf91869e5@1.2 +0 -0 Delete: libopts/compat/pathfind.c - BitKeeper/deleted/.del-pgusage.c~c9ca334462225a7a@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-pgusage.c~c9ca334462225a7a@1.2 +0 -0 Delete: libopts/libopts/pgusage.c - BitKeeper/deleted/.del-pgusage.c~ca33905e5c7aa1df@1.2, 2005-08-26 04:10:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-pgusage.c~ca33905e5c7aa1df@1.2 +0 -0 Delete: libopts/pgusage.c - BitKeeper/deleted/.del-proto.h~452f423c89ac200e@1.2, 2005-08-26 04:10:33-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-proto.h~452f423c89ac200e@1.2 +0 -0 Delete: libopts/libopts/proto.h - BitKeeper/deleted/.del-proto.h~e8c7a2af94986c41@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-proto.h~e8c7a2af94986c41@1.2 +0 -0 Delete: libopts/proto.h - BitKeeper/deleted/.del-putshell.c~229e9255825c2699@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-putshell.c~229e9255825c2699@1.2 +0 -0 Delete: libopts/libopts/putshell.c - BitKeeper/deleted/.del-putshell.c~3f90a9637c1cb3f8@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-putshell.c~3f90a9637c1cb3f8@1.2 +0 -0 Delete: libopts/putshell.c - BitKeeper/deleted/.del-restore.c~786e9e008c497959@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-restore.c~786e9e008c497959@1.2 +0 -0 Delete: libopts/libopts/restore.c - BitKeeper/deleted/.del-restore.c~c5d1d1e9dde10cf6@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-restore.c~c5d1d1e9dde10cf6@1.2 +0 -0 Delete: libopts/restore.c - BitKeeper/deleted/.del-save.c~16cdb7b3a7320c91@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-save.c~16cdb7b3a7320c91@1.2 +0 -0 Delete: libopts/save.c - BitKeeper/deleted/.del-save.c~9ac698c63285dcdf@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-save.c~9ac698c63285dcdf@1.2 +0 -0 Delete: libopts/libopts/save.c - BitKeeper/deleted/.del-sort.c~437339de5156edc@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sort.c~437339de5156edc@1.2 +0 -0 Delete: libopts/libopts/sort.c - BitKeeper/deleted/.del-sort.c~b07de2fbf0002b9e@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sort.c~b07de2fbf0002b9e@1.2 +0 -0 Delete: libopts/sort.c - BitKeeper/deleted/.del-stack.c~23d824507da8a741@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-stack.c~23d824507da8a741@1.2 +0 -0 Delete: libopts/stack.c - BitKeeper/deleted/.del-stack.c~c65d211fa8d2c6d9@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-stack.c~c65d211fa8d2c6d9@1.2 +0 -0 Delete: libopts/libopts/stack.c - BitKeeper/deleted/.del-streqvcmp.c~2b01ea402455a9d5@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-streqvcmp.c~2b01ea402455a9d5@1.2 +0 -0 Delete: libopts/libopts/streqvcmp.c - BitKeeper/deleted/.del-streqvcmp.c~ecb35a72608d3d8c@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-streqvcmp.c~ecb35a72608d3d8c@1.2 +0 -0 Delete: libopts/streqvcmp.c - BitKeeper/deleted/.del-text_mmap.c~7e8b2fb878ad6465@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-text_mmap.c~7e8b2fb878ad6465@1.2 +0 -0 Delete: libopts/libopts/text_mmap.c - BitKeeper/deleted/.del-text_mmap.c~8276cd532e35d7d@1.2, 2005-08-26 04:10:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-text_mmap.c~8276cd532e35d7d@1.2 +0 -0 Delete: libopts/text_mmap.c - BitKeeper/deleted/.del-tokenize.c~994b2aafabe0643a@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-tokenize.c~994b2aafabe0643a@1.2 +0 -0 Delete: libopts/tokenize.c - BitKeeper/deleted/.del-tokenize.c~e1d05f5d9da9f103@1.2, 2005-08-26 04:10:34-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-tokenize.c~e1d05f5d9da9f103@1.2 +0 -0 Delete: libopts/libopts/tokenize.c - BitKeeper/deleted/.del-usage-txt.h~3f152e2762854446@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-usage-txt.h~3f152e2762854446@1.2 +0 -0 Delete: libopts/autoopts/usage-txt.h - BitKeeper/deleted/.del-usage.c~35ccdb8f15358479@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-usage.c~35ccdb8f15358479@1.2 +0 -0 Delete: libopts/usage.c - BitKeeper/deleted/.del-usage.c~7218cbdb39fe114@1.2, 2005-08-26 04:10:35-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-usage.c~7218cbdb39fe114@1.2 +0 -0 Delete: libopts/libopts/usage.c - BitKeeper/deleted/.del-version.c~51a770ed71ec2abe@1.2, 2005-08-26 04:10:35-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-version.c~51a770ed71ec2abe@1.2 +0 -0 Delete: libopts/libopts/version.c - BitKeeper/deleted/.del-version.c~f7d51067e17b5364@1.2, 2005-08-26 04:10:31-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-version.c~f7d51067e17b5364@1.2 +0 -0 Delete: libopts/version.c -ChangeSet@1.1251.45.17, 2005-08-25 21:01:42+00:00, kardel@pogo.udel.edu +5 -0 +ChangeSet@1.1251.45.17, 2005-08-25 21:01:42+00:00, kardel@pogo.udel.edu ntpdc_ops.c, ntp_request.c, ntp_peer.c, ntpd.h, ntp_request.h: remove reset pollinterval feature - include/ntp_request.h@1.27, 2005-08-25 20:59:02+00:00, kardel@pogo.udel.edu +0 -1 + include/ntp_request.h@1.27 +0 -1 remove reset pollinterval feature - include/ntpd.h@1.82.2.6, 2005-08-25 20:59:37+00:00, kardel@pogo.udel.edu +0 -1 + include/ntpd.h@1.82.2.6 +0 -1 remove reset pollinterval feature - ntpd/ntp_peer.c@1.82.1.6, 2005-08-25 21:00:06+00:00, kardel@pogo.udel.edu +0 -41 + ntpd/ntp_peer.c@1.82.1.6 +0 -41 remove reset pollinterval feature - ntpd/ntp_request.c@1.63, 2005-08-25 21:00:30+00:00, kardel@pogo.udel.edu +0 -107 + ntpd/ntp_request.c@1.63 +0 -107 remove reset pollinterval feature - ntpdc/ntpdc_ops.c@1.43, 2005-08-25 21:00:51+00:00, kardel@pogo.udel.edu +0 -60 + ntpdc/ntpdc_ops.c@1.43 +0 -60 remove reset pollinterval feature -ChangeSet@1.1251.45.16, 2005-08-24 21:42:33+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.45.16, 2005-08-24 21:42:33+00:00, kardel@pogo.udel.edu ntp_io.c: fix interface number log output - ntpd/ntp_io.c@1.196, 2005-08-24 21:35:29+00:00, kardel@pogo.udel.edu +6 -5 + ntpd/ntp_io.c@1.196 +6 -5 fix interface number log output -ChangeSet@1.1251.45.15, 2005-08-24 13:30:29+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.45.15, 2005-08-24 13:30:29+00:00, kardel@pogo.udel.edu ntp_io.c: keep others out while rebuilding the environment - ntpd/ntp_io.c@1.195, 2005-08-24 13:29:28+00:00, kardel@pogo.udel.edu +2 -2 + ntpd/ntp_io.c@1.195 +2 -2 keep others out while rebuilding the environment -ChangeSet@1.1251.45.14, 2005-08-24 13:09:54+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.45.14, 2005-08-24 13:09:54+00:00, kardel@pogo.udel.edu ntp_io.c: paren missing - ntpd/ntp_io.c@1.194, 2005-08-24 13:09:07+00:00, kardel@pogo.udel.edu +1 -0 + ntpd/ntp_io.c@1.194 +1 -0 paren missing -ChangeSet@1.1251.45.13, 2005-08-24 09:28:44+00:00, kardel@pogo.udel.edu +8 -0 +ChangeSet@1.1251.45.13, 2005-08-24 09:28:44+00:00, kardel@pogo.udel.edu layout.std: ifnum introduced ntpdc_ops.c: @@ -18067,17 +198834,17 @@ ChangeSet@1.1251.45.13, 2005-08-24 09:28:44+00:00, kardel@pogo.udel.edu +8 -0 change interface_t to struct interface as _t typedef pollute POSIX system namespace add ifnum as interface instance generation number - include/ntp.h@1.118.1.6, 2005-08-24 08:38:28+00:00, kardel@pogo.udel.edu +2 -3 + include/ntp.h@1.118.1.6 +2 -3 change interface_t to struct interface as _t typedef pollute POSIX system namespace add ifnum as interface instance generation number - include/ntp_request.h@1.26, 2005-08-24 08:39:48+00:00, kardel@pogo.udel.edu +2 -1 + include/ntp_request.h@1.26 +2 -1 add ifnum as interface instance generation number - include/ntpd.h@1.82.2.5, 2005-08-24 08:39:56+00:00, kardel@pogo.udel.edu +7 -7 + include/ntpd.h@1.82.2.5 +7 -7 change interface_t to struct interface as _t typdef pollute POSIX system name space - ntpd/ntp_io.c@1.193, 2005-08-24 08:41:23+00:00, kardel@pogo.udel.edu +172 -179 + ntpd/ntp_io.c@1.193 +172 -179 change interface_t to struct interface ad _t typedef pollute POSIX system name space use ifnum for interface numbers (ifindex seems often to be 0 on NetBSD) re-arrange intialization @@ -18085,22 +198852,22 @@ ChangeSet@1.1251.45.13, 2005-08-24 09:28:44+00:00, kardel@pogo.udel.edu +8 -0 interface structure into the lists make ifindex be the original - ntpd/ntp_peer.c@1.82.1.5, 2005-08-24 08:43:26+00:00, kardel@pogo.udel.edu +1 -1 + ntpd/ntp_peer.c@1.82.1.5 +1 -1 re-name interface_t to struct interface - _t collides with POSIX system namespaces - ntpd/ntp_request.c@1.62, 2005-08-24 08:43:36+00:00, kardel@pogo.udel.edu +2 -1 + ntpd/ntp_request.c@1.62 +2 -1 re-name interface_t to struct interface - _t collides with POSIX system namespaces - ntpdc/layout.std@1.5, 2005-08-24 09:14:07+00:00, kardel@pogo.udel.edu +1 -0 + ntpdc/layout.std@1.5 +1 -0 ifnum introduced - ntpdc/layout.std@1.4, 2005-08-24 08:44:08+00:00, kardel@pogo.udel.edu +4 -4 + ntpdc/layout.std@1.4 +4 -4 ifnum added - ntpdc/ntpdc_ops.c@1.42, 2005-08-24 08:44:19+00:00, kardel@pogo.udel.edu +6 -5 + ntpdc/ntpdc_ops.c@1.42 +6 -5 list ifnum and ifindex -ChangeSet@1.1251.45.12, 2005-08-24 06:24:42+00:00, kardel@pogo.udel.edu +11 -0 +ChangeSet@1.1251.45.12, 2005-08-24 06:24:42+00:00, kardel@pogo.udel.edu ntpdc_ops.c, ntp_request.c: support dynamic modifier support pollreset request @@ -18116,72 +198883,72 @@ ChangeSet@1.1251.45.12, 2005-08-24 06:24:42+00:00, kardel@pogo.udel.edu +11 -0 ntpdc.html, confopt.html: document "dynamic" modifier keyword for peer/server configuration - html/confopt.html@1.32, 2005-08-23 21:57:40+00:00, kardel@pogo.udel.edu +4 -2 + html/confopt.html@1.32 +4 -2 document "dynamic" modifier keyword for peer/server configuration - html/ntpdc.html@1.22, 2005-08-23 21:58:22+00:00, kardel@pogo.udel.edu +4 -4 + html/ntpdc.html@1.22 +4 -4 document "dynamic" modifier keyword for peer/server configuration - include/ntp.h@1.118.1.5, 2005-08-23 21:58:53+00:00, kardel@pogo.udel.edu +1 -0 + include/ntp.h@1.118.1.5 +1 -0 support dynamic modifier - include/ntp_config.h@1.38, 2005-08-23 21:59:22+00:00, kardel@pogo.udel.edu +1 -0 + include/ntp_config.h@1.38 +1 -0 support dynamic modifier - include/ntp_request.h@1.25, 2005-08-23 21:59:35+00:00, kardel@pogo.udel.edu +2 -0 + include/ntp_request.h@1.25 +2 -0 support dynamic modifier add pollreset mode 7 request - include/ntpd.h@1.82.2.4, 2005-08-23 22:00:13+00:00, kardel@pogo.udel.edu +2 -0 + include/ntpd.h@1.82.2.4 +2 -0 support resetting of poll interval on interface changes and manually - ntpd/ntp_config.c@1.129.2.4, 2005-08-23 22:01:04+00:00, kardel@pogo.udel.edu +6 -0 + ntpd/ntp_config.c@1.129.2.4 +6 -0 support dynamic modifier - ntpd/ntp_peer.c@1.82.1.4, 2005-08-23 22:01:20+00:00, kardel@pogo.udel.edu +96 -53 + ntpd/ntp_peer.c@1.82.1.4 +96 -53 support dynamic modifier - ntpd/ntp_request.c@1.61, 2005-08-23 22:01:31+00:00, kardel@pogo.udel.edu +116 -5 + ntpd/ntp_request.c@1.61 +116 -5 support dynamic modifier support pollreset request - ntpdc/ntpdc.c@1.40.1.3, 2005-08-23 22:02:13+00:00, kardel@pogo.udel.edu +1 -1 + ntpdc/ntpdc.c@1.40.1.3 +1 -1 allow first argument to be optional - ntpdc/ntpdc_ops.c@1.41, 2005-08-23 22:02:29+00:00, kardel@pogo.udel.edu +62 -1 + ntpdc/ntpdc_ops.c@1.41 +62 -1 support dynamic modifier support pollreset request -ChangeSet@1.1251.45.11, 2005-08-23 06:45:17+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.45.11, 2005-08-23 06:45:17+00:00, kardel@pogo.udel.edu ntp_io.c: cleanup debug output handling - ntpd/ntp_io.c@1.192, 2005-08-23 06:44:45+00:00, kardel@pogo.udel.edu +10 -5 + ntpd/ntp_io.c@1.192 +10 -5 cleanup debug output handling -ChangeSet@1.1251.45.10, 2005-08-23 06:26:45+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.45.10, 2005-08-23 06:26:45+00:00, kardel@pogo.udel.edu ntp_io.c: fixed crash in debug error message - ntpd/ntp_io.c@1.191, 2005-08-23 06:25:35+00:00, kardel@pogo.udel.edu +10 -5 + ntpd/ntp_io.c@1.191 +10 -5 fixed crash in debug error message -ChangeSet@1.1251.46.1, 2005-08-22 19:45:14-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.46.1, 2005-08-22 19:45:14-04:00, stenn@whimsy.udel.edu beacon stuff from Dave Mills - include/ntp.h@1.118.2.1, 2005-08-22 19:44:08-04:00, stenn@whimsy.udel.edu +2 -1 + include/ntp.h@1.118.2.1 +2 -1 beacon stuff from Dave Mills - include/ntp_config.h@1.37, 2005-08-22 19:44:09-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntp_config.h@1.37 +1 -0 beacon stuff from Dave Mills - ntpd/ntp_config.c@1.129.2.3, 2005-08-22 19:44:35-04:00, stenn@whimsy.udel.edu +9 -0 + ntpd/ntp_config.c@1.129.2.3 +9 -0 beacon stuff from Dave Mills - ntpd/ntp_proto.c@1.232.1.1, 2005-08-22 19:44:37-04:00, stenn@whimsy.udel.edu +26 -9 + ntpd/ntp_proto.c@1.232.1.1 +26 -9 beacon stuff from Dave Mills -ChangeSet@1.1251.45.8, 2005-08-22 22:43:21+00:00, kardel@pogo.udel.edu +3 -0 +ChangeSet@1.1251.45.8, 2005-08-22 22:43:21+00:00, kardel@pogo.udel.edu ntp_request.c: return clean 0.0.0.0 addresses while a peer has no interface ntp_control.c: @@ -18189,23 +198956,23 @@ ChangeSet@1.1251.45.8, 2005-08-22 22:43:21+00:00, kardel@pogo.udel.edu +3 -0 ntpd.h: cleanup declarations - include/ntpd.h@1.82.2.3, 2005-08-22 22:41:56+00:00, kardel@pogo.udel.edu +1 -1 + include/ntpd.h@1.82.2.3 +1 -1 cleanup declarations - ntpd/ntp_control.c@1.81, 2005-08-22 22:42:21+00:00, kardel@pogo.udel.edu +3 -0 + ntpd/ntp_control.c@1.81 +3 -0 return clean 0.0.0.0 addresses while a peer has no interface - ntpd/ntp_request.c@1.60, 2005-08-22 22:42:49+00:00, kardel@pogo.udel.edu +2 -2 + ntpd/ntp_request.c@1.60 +2 -2 return clean 0.0.0.0 addresses while a peer has no interface -ChangeSet@1.1251.45.7, 2005-08-22 21:57:08+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.45.7, 2005-08-22 21:57:08+00:00, kardel@pogo.udel.edu ntp_proto.c: don't attempt to transmit on peers that currently have not interface - ntpd/ntp_proto.c@1.235, 2005-08-22 21:56:14+00:00, kardel@pogo.udel.edu +3 -0 + ntpd/ntp_proto.c@1.235 +3 -0 don't attempt to transmit on peers that currently have not interface -ChangeSet@1.1251.45.6, 2005-08-22 16:19:29+00:00, kardel@pogo.udel.edu +4 -0 +ChangeSet@1.1251.45.6, 2005-08-22 16:19:29+00:00, kardel@pogo.udel.edu ntpdc_ops.c: cleanup output format add enable/disable output @@ -18219,32 +198986,32 @@ ChangeSet@1.1251.45.6, 2005-08-22 16:19:29+00:00, kardel@pogo.udel.edu +4 -0 ntp_io.c: re-bind all interfaces when the interface list changes - ntpd/ntp_io.c@1.190, 2005-08-22 16:16:16+00:00, kardel@pogo.udel.edu +12 -6 + ntpd/ntp_io.c@1.190 +12 -6 re-bind all interfaces when the interface list changes - ntpd/ntp_peer.c@1.82.1.3, 2005-08-22 16:16:37+00:00, kardel@pogo.udel.edu +42 -21 + ntpd/ntp_peer.c@1.82.1.3 +42 -21 re-bind all interfaces when the interface list changes unbind interface when refclock configuration fails correct setting of a new interface for a peer - ntpd/ntp_proto.c@1.234, 2005-08-22 16:17:21+00:00, kardel@pogo.udel.edu +0 -14 + ntpd/ntp_proto.c@1.234 +0 -14 as we are re-binding all interfaces on interface list changes a refresh on transmit is not needed - ntpdc/ntpdc_ops.c@1.40, 2005-08-22 16:18:50+00:00, kardel@pogo.udel.edu +4 -3 + ntpdc/ntpdc_ops.c@1.40 +4 -3 cleanup output format add enable/disable output -ChangeSet@1.1251.45.5, 2005-08-22 12:05:51+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.45.5, 2005-08-22 12:05:51+00:00, kardel@pogo.udel.edu ntp_io.c: fix list initialization for interface->peer correct initizalization of loopback_interface global - ntpd/ntp_io.c@1.189, 2005-08-22 12:03:15+00:00, kardel@pogo.udel.edu +8 -0 + ntpd/ntp_io.c@1.189 +8 -0 fix list initialization for interface->peer correct initizalization of loopback_interface global -ChangeSet@1.1251.45.4, 2005-08-21 19:22:34+00:00, kardel@pogo.udel.edu +19 -0 +ChangeSet@1.1251.45.4, 2005-08-21 19:22:34+00:00, kardel@pogo.udel.edu ntpdc_ops.c: add ifstats and ifreload commands layout.std: @@ -18284,288 +199051,288 @@ ChangeSet@1.1251.45.4, 2005-08-21 19:22:34+00:00, kardel@pogo.udel.edu +19 -0 ntpd.html: document dynamic interface update interval option (-U ) - html/ntpd.html@1.37, 2005-08-21 18:58:34+00:00, kardel@pogo.udel.edu +3 -1 + html/ntpd.html@1.37 +3 -1 document dynamic interface update interval option (-U ) - html/ntpdc.html@1.21, 2005-08-21 19:00:12+00:00, kardel@pogo.udel.edu +4 -0 + html/ntpdc.html@1.21 +4 -0 document ifstats and ifreload commands - include/ntp.h@1.118.1.3, 2005-08-21 19:08:54+00:00, kardel@pogo.udel.edu +19 -10 + include/ntp.h@1.118.1.3 +19 -10 integrate dynamic interface update support - include/ntp_debug.h@1.1, 2005-08-21 19:13:08+00:00, kardel@pogo.udel.edu +26 -0 + include/ntp_debug.h@1.1 +26 -0 - include/ntp_debug.h@1.0, 2005-08-21 19:13:08+00:00, kardel@pogo.udel.edu +0 -0 + include/ntp_debug.h@1.0 +0 -0 BitKeeper file /pogo/users/kardel/ntp-dev/include/ntp_debug.h - include/ntp_request.h@1.24, 2005-08-21 19:09:23+00:00, kardel@pogo.udel.edu +38 -0 + include/ntp_request.h@1.24 +38 -0 define data structure needed for ntpdc's ifstats and ifreload command - include/ntpd.h@1.82.2.2, 2005-08-21 19:09:58+00:00, kardel@pogo.udel.edu +21 -7 + include/ntpd.h@1.82.2.2 +21 -7 add support for dynamic interface updates - ntpd/cmd_args.c@1.34.1.1, 2005-08-21 19:01:02+00:00, kardel@pogo.udel.edu +21 -2 + ntpd/cmd_args.c@1.34.1.1 +21 -2 add "-U interface_update_interval" option - ntpd/ntp_control.c@1.80, 2005-08-21 19:01:42+00:00, kardel@pogo.udel.edu +4 -2 + ntpd/ntp_control.c@1.80 +4 -2 cope with peers having no current interface - ntpd/ntp_crypto.c@1.97.1.1, 2005-08-21 19:02:16+00:00, kardel@pogo.udel.edu +6 -0 + ntpd/ntp_crypto.c@1.97.1.1 +6 -0 cope with peers having no current interface - ntpd/ntp_io.c@1.188, 2005-08-21 19:02:25+00:00, kardel@pogo.udel.edu +885 -557 + ntpd/ntp_io.c@1.188 +885 -557 rework to support dynamic interface updating array inter_list[] is gone reduce #ifdef DEBUG section with DPRINTF macro - ntpd/ntp_monitor.c@1.15.1.1, 2005-08-21 19:03:40+00:00, kardel@pogo.udel.edu +18 -0 + ntpd/ntp_monitor.c@1.15.1.1 +18 -0 remove monitor information when an interface is removed - ntpd/ntp_peer.c@1.82.1.2, 2005-08-21 19:04:10+00:00, kardel@pogo.udel.edu +159 -40 + ntpd/ntp_peer.c@1.82.1.2 +159 -40 rework peer management to cope with dynamic interface list updates - ntpd/ntp_proto.c@1.233, 2005-08-21 19:05:07+00:00, kardel@pogo.udel.edu +117 -92 + ntpd/ntp_proto.c@1.233 +117 -92 cope with peeers that have no interface - ntpd/ntp_request.c@1.59, 2005-08-21 19:06:16+00:00, kardel@pogo.udel.edu +145 -32 + ntpd/ntp_request.c@1.59 +145 -32 add ifstats and ifreload backend implementation - ntpd/ntp_restrict.c@1.18, 2005-08-21 19:06:45+00:00, kardel@pogo.udel.edu +4 -2 + ntpd/ntp_restrict.c@1.18 +4 -2 support forcefully removing an interface entry (dynamic interface update support) - ntpd/ntp_timer.c@1.29, 2005-08-21 19:07:17+00:00, kardel@pogo.udel.edu +16 -0 + ntpd/ntp_timer.c@1.29 +16 -0 add timeout routine to periodically update ntpd's interface list - ntpd/ntp_util.c@1.37, 2005-08-21 19:08:06+00:00, kardel@pogo.udel.edu +15 -3 + ntpd/ntp_util.c@1.37 +15 -3 prepare for exit logging - not active yet - ntpdc/layout.std@1.3, 2005-08-21 19:13:42+00:00, kardel@pogo.udel.edu +19 -0 + ntpdc/layout.std@1.3 +19 -0 update with data structure used with ntpdc's ifstats and ifreload commands - ntpdc/ntpdc_ops.c@1.39, 2005-08-21 19:14:33+00:00, kardel@pogo.udel.edu +125 -0 + ntpdc/ntpdc_ops.c@1.39 +125 -0 add ifstats and ifreload commands -ChangeSet@1.1251.45.3, 2005-08-16 20:49:01-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.45.3, 2005-08-16 20:49:01-04:00, stenn@whimsy.udel.edu preempt stuff from Dave Mills - include/ntp.h@1.118.1.2, 2005-08-16 20:47:23-04:00, stenn@whimsy.udel.edu +1 -2 + include/ntp.h@1.118.1.2 +1 -2 preempt stuff from Dave Mills - ntpd/ntp_proto.c@1.232, 2005-08-16 20:48:26-04:00, stenn@whimsy.udel.edu +34 -45 + ntpd/ntp_proto.c@1.232 +34 -45 preempt stuff from Dave Mills -ChangeSet@1.1251.45.2, 2005-08-16 05:34:28-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.45.2, 2005-08-16 05:34:28-04:00, stenn@whimsy.udel.edu [Bug 478] use "end" keyword to stop config file processing - include/ntp_config.h@1.36, 2005-08-16 05:34:09-04:00, stenn@whimsy.udel.edu +2 -1 + include/ntp_config.h@1.36 +2 -1 [Bug 478] use "end" keyword to stop config file processing - ntpd/ntp_config.c@1.129.2.2, 2005-08-16 05:34:10-04:00, stenn@whimsy.udel.edu +9 -0 + ntpd/ntp_config.c@1.129.2.2 +9 -0 [Bug 478] use "end" keyword to stop config file processing -ChangeSet@1.1251.45.1, 2005-08-16 02:49:46-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1251.45.1, 2005-08-16 02:49:46-04:00, stenn@whimsy.udel.edu preempt stuff from Dave Mills - include/ntp.h@1.118.1.1, 2005-08-16 02:49:21-04:00, stenn@whimsy.udel.edu +6 -5 + include/ntp.h@1.118.1.1 +6 -5 preempt stuff from Dave Mills - include/ntp_config.h@1.35, 2005-08-16 02:49:22-04:00, stenn@whimsy.udel.edu +1 -1 + include/ntp_config.h@1.35 +1 -1 preempt stuff from Dave Mills - include/ntpd.h@1.82.2.1, 2005-08-16 02:49:27-04:00, stenn@whimsy.udel.edu +0 -1 + include/ntpd.h@1.82.2.1 +0 -1 preempt stuff from Dave Mills - ntpd/ntp_config.c@1.129.2.1, 2005-08-16 02:48:22-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntp_config.c@1.129.2.1 +3 -3 preempt stuff from Dave Mills - ntpd/ntp_peer.c@1.82.1.1, 2005-08-16 02:48:24-04:00, stenn@whimsy.udel.edu +5 -32 + ntpd/ntp_peer.c@1.82.1.1 +5 -32 preempt stuff from Dave Mills - ntpd/ntp_proto.c@1.231, 2005-08-16 02:48:25-04:00, stenn@whimsy.udel.edu +69 -70 + ntpd/ntp_proto.c@1.231 +69 -70 preempt stuff from Dave Mills -ChangeSet@1.1251.44.1, 2005-08-15 19:41:00-04:00, mayer@pogo.udel.edu +14 -0 +ChangeSet@1.1251.44.1, 2005-08-15 19:41:00-04:00, mayer@pogo.udel.edu Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - include/ntp.h@1.119, 2005-08-15 17:50:32-04:00, mayer@pogo.udel.edu +1 -0 + include/ntp.h@1.119 +1 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - include/ntp_random.h@1.1, 2005-08-15 17:59:37-04:00, mayer@pogo.udel.edu +14 -0 + include/ntp_random.h@1.1 +14 -0 - include/ntp_random.h@1.0, 2005-08-15 17:59:37-04:00, mayer@pogo.udel.edu +0 -0 + include/ntp_random.h@1.0 +0 -0 BitKeeper file /pogo/users/mayer/ntp-dev/include/ntp_random.h - include/ntpd.h@1.82.1.2, 2005-08-15 17:50:34-04:00, mayer@pogo.udel.edu +0 -7 + include/ntpd.h@1.82.1.2 +0 -7 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - libntp/Makefile.am@1.36, 2005-08-15 17:50:35-04:00, mayer@pogo.udel.edu +1 -1 + libntp/Makefile.am@1.36 +1 -1 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - libntp/ntp_random.c@1.5, 2005-08-15 17:50:37-04:00, mayer@pogo.udel.edu +5 -2 + libntp/ntp_random.c@1.5 +5 -2 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - libntp/ntp_random.c@1.4, 2005-08-14 15:51:54-04:00, mayer@pogo.udel.edu +0 -0 + libntp/ntp_random.c@1.4 +0 -0 Rename: libntp/random.c -> libntp/ntp_random.c - ntpd/ntp_config.c@1.129.1.2, 2005-08-15 17:50:39-04:00, mayer@pogo.udel.edu +1 -0 + ntpd/ntp_config.c@1.129.1.2 +1 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ntpd/ntp_crypto.c@1.98, 2005-08-15 17:50:40-04:00, mayer@pogo.udel.edu +1 -0 + ntpd/ntp_crypto.c@1.98 +1 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ntpd/ntp_monitor.c@1.16, 2005-08-15 17:50:40-04:00, mayer@pogo.udel.edu +1 -0 + ntpd/ntp_monitor.c@1.16 +1 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ntpd/ntp_peer.c@1.83, 2005-08-15 17:50:41-04:00, mayer@pogo.udel.edu +1 -0 + ntpd/ntp_peer.c@1.83 +1 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ntpd/ntpd.c@1.61.3.1, 2005-08-15 17:50:41-04:00, mayer@pogo.udel.edu +1 -0 + ntpd/ntpd.c@1.61.3.1 +1 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ports/winnt/include/config.h@1.40, 2005-08-15 17:52:01-04:00, mayer@pogo.udel.edu +1 -0 + ports/winnt/include/config.h@1.40 +1 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ports/winnt/libntp/libntp.dsp@1.26, 2005-08-15 17:52:52-04:00, mayer@pogo.udel.edu +8 -20 + ports/winnt/libntp/libntp.dsp@1.26 +8 -20 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.9, 2005-08-15 17:53:57-04:00, mayer@pogo.udel.edu +4 -0 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.9 +4 -0 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place - ports/winnt/ntpd/ntpd.dsp@1.26, 2005-08-15 17:53:22-04:00, mayer@pogo.udel.edu +5 -1 + ports/winnt/ntpd/ntpd.dsp@1.26 +5 -1 Fixes to support ntp_random on Windows and miscellaneous fixes for all platforms to get everything in the right place -ChangeSet@1.1178.5.6, 2005-08-15 04:01:26-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.5.6, 2005-08-15 04:01:26-04:00, stenn@whimsy.udel.edu [Bug 477] Linux needs larger RLIM_MEMLOCK, from Cristoph Gysin - ntpd/ntpd.c@1.54.1.1, 2005-08-15 04:01:12-04:00, stenn@whimsy.udel.edu +12 -0 + ntpd/ntpd.c@1.54.1.1 +12 -0 [Bug 477] Linux needs larger RLIM_MEMLOCK, from Cristoph Gysin -ChangeSet@1.1288, 2005-08-15 01:27:24-04:00, stenn@pogo.udel.edu +0 -0 +ChangeSet@1.1288, 2005-08-15 01:27:24-04:00, stenn@pogo.udel.edu Merge pogo.udel.edu:/pogo/users/stenn/ntp-dev-ag into pogo.udel.edu:/pogo/users/stenn/ntp-dev-ag+ [no longer a merge: surgery done] -ChangeSet@1.1287, 2005-08-13 22:08:44-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1287, 2005-08-13 22:08:44-04:00, stenn@pogo.udel.edu add to gone file - BitKeeper/etc/gone@1.7, 2005-08-13 22:07:17-04:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/gone@1.7 +1 -0 -ChangeSet@1.1251.38.16, 2005-08-12 04:45:21-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.38.16, 2005-08-12 04:45:21-04:00, stenn@whimsy.udel.edu preempt stuff from Dave Mills - include/ntpd.h@1.82.1.1, 2005-08-12 04:45:04-04:00, stenn@whimsy.udel.edu +2 -2 + include/ntpd.h@1.82.1.1 +2 -2 preempt stuff from Dave Mills - ntpd/ntp_peer.c@1.82, 2005-08-12 04:44:31-04:00, stenn@whimsy.udel.edu +10 -6 + ntpd/ntp_peer.c@1.82 +10 -6 preempt stuff from Dave Mills - ntpd/ntp_proto.c@1.230, 2005-08-12 04:44:31-04:00, stenn@whimsy.udel.edu +18 -17 + ntpd/ntp_proto.c@1.230 +18 -17 preempt stuff from Dave Mills -ChangeSet@1.1251.38.15, 2005-08-12 04:39:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.38.15, 2005-08-12 04:39:52-04:00, stenn@whimsy.udel.edu typo - ntpdate/Makefile.am@1.13, 2005-08-12 04:39:32-04:00, stenn@whimsy.udel.edu +1 -1 + ntpdate/Makefile.am@1.13 +1 -1 typo -ChangeSet@1.1251.38.14, 2005-08-10 10:13:26+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.14, 2005-08-10 10:13:26+00:00, kardel@pogo.udel.edu dcfd.c: output revision information - parseutil/dcfd.c@1.17, 2005-08-10 10:12:31+00:00, kardel@pogo.udel.edu +8 -3 + parseutil/dcfd.c@1.17 +8 -3 output revision information -ChangeSet@1.1251.38.12, 2005-08-10 06:50:23+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.12, 2005-08-10 06:50:23+00:00, kardel@pogo.udel.edu dcfd.c: cleanup warnings fix setting of baud rate - parseutil/dcfd.c@1.16, 2005-08-10 06:49:50+00:00, kardel@pogo.udel.edu +14 -4 + parseutil/dcfd.c@1.16 +14 -4 cleanup warnings fix setting of baud rate -ChangeSet@1.1251.42.9, 2005-08-09 17:02:19-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1251.42.9, 2005-08-09 17:02:19-04:00, stenn@whimsy.udel.edu cleanup, added "preempt" and "maxclock". From Dave Mills. - include/ntp.h@1.118, 2005-08-09 16:59:29-04:00, stenn@whimsy.udel.edu +19 -16 + include/ntp.h@1.118 +19 -16 cleanup, added "preempt". From Dave Mills. - include/ntp_config.h@1.34, 2005-08-09 16:59:30-04:00, stenn@whimsy.udel.edu +9 -7 + include/ntp_config.h@1.34 +9 -7 cleanup, added "preempt". From Dave Mills. - ntpd/ntp_config.c@1.129.1.1, 2005-08-09 17:01:40-04:00, stenn@whimsy.udel.edu +11 -0 + ntpd/ntp_config.c@1.129.1.1 +11 -0 cleanup, added "preempt" and "maxclock". From Dave Mills. - ntpd/ntp_peer.c@1.81, 2005-08-09 17:01:42-04:00, stenn@whimsy.udel.edu +6 -8 + ntpd/ntp_peer.c@1.81 +6 -8 cleanup, added "preempt" and "maxclock". From Dave Mills. - ntpd/ntp_proto.c@1.229, 2005-08-09 17:01:42-04:00, stenn@whimsy.udel.edu +102 -130 + ntpd/ntp_proto.c@1.229 +102 -130 cleanup, added "preempt" and "maxclock". From Dave Mills. -ChangeSet@1.1285, 2005-08-08 02:53:55-04:00, stenn@pogo.udel.edu +18 -0 +ChangeSet@1.1285, 2005-08-08 02:53:55-04:00, stenn@pogo.udel.edu autogen update and more conversion - include/ntpd.h@1.78.2.1, 2005-08-08 02:52:58-04:00, stenn@pogo.udel.edu +0 -1 + include/ntpd.h@1.78.2.1 +0 -1 autogen update and more conversion - libopts/INSTALL@1.2, 2005-08-08 02:53:06-04:00, stenn@pogo.udel.edu +8 -3 + libopts/INSTALL@1.2 +8 -3 autogen update and more conversion - libopts/m4/compile@1.2, 2005-08-08 02:53:11-04:00, stenn@pogo.udel.edu +4 -4 + libopts/m4/compile@1.2 +4 -4 autogen update and more conversion - libopts/m4/config.guess@1.2, 2005-08-08 02:53:11-04:00, stenn@pogo.udel.edu +234 -270 + libopts/m4/config.guess@1.2 +234 -270 autogen update and more conversion - libopts/m4/config.sub@1.2, 2005-08-08 02:53:11-04:00, stenn@pogo.udel.edu +13 -17 + libopts/m4/config.sub@1.2 +13 -17 autogen update and more conversion - libopts/m4/depcomp@1.2, 2005-08-08 02:53:11-04:00, stenn@pogo.udel.edu +30 -23 + libopts/m4/depcomp@1.2 +30 -23 autogen update and more conversion - libopts/m4/install-sh@1.2, 2005-08-08 02:53:11-04:00, stenn@pogo.udel.edu +3 -3 + libopts/m4/install-sh@1.2 +3 -3 autogen update and more conversion - libopts/m4/ltmain.sh@1.2, 2005-08-08 02:53:12-04:00, stenn@pogo.udel.edu +124 -222 + libopts/m4/ltmain.sh@1.2 +124 -222 autogen update and more conversion - libopts/m4/missing@1.2, 2005-08-08 02:53:12-04:00, stenn@pogo.udel.edu +10 -6 + libopts/m4/missing@1.2 +10 -6 autogen update and more conversion - ntpd/Makefile.am@1.42, 2005-08-08 02:53:13-04:00, stenn@pogo.udel.edu +37 -6 + ntpd/Makefile.am@1.42 +37 -6 autogen update and more conversion - ntpd/cmd_args.c@1.35, 2005-08-08 02:53:13-04:00, stenn@pogo.udel.edu +169 -216 + ntpd/cmd_args.c@1.35 +169 -216 autogen update and more conversion - ntpd/ntp_config.c@1.128.1.1, 2005-08-08 02:53:14-04:00, stenn@pogo.udel.edu +1 -3 + ntpd/ntp_config.c@1.128.1.1 +1 -3 autogen update and more conversion - ntpd/ntpd.c@1.66, 2005-08-08 02:53:16-04:00, stenn@pogo.udel.edu +129 -31 + ntpd/ntpd.c@1.66 +129 -31 autogen update and more conversion - ntpd/ntpsim.c@1.9.1.1, 2005-08-08 02:53:16-04:00, stenn@pogo.udel.edu +9 -0 + ntpd/ntpsim.c@1.9.1.1 +9 -0 autogen update and more conversion - ntpdc/ntpdc-opts.def@1.4, 2005-08-08 02:53:20-04:00, stenn@pogo.udel.edu +3 -3 + ntpdc/ntpdc-opts.def@1.4 +3 -3 autogen update and more conversion - ntpq/ntpq-opts.def@1.3, 2005-08-08 02:53:20-04:00, stenn@pogo.udel.edu +25 -21 + ntpq/ntpq-opts.def@1.3 +25 -21 autogen update and more conversion - sntp/Makefile.am@1.7, 2005-08-08 02:53:27-04:00, stenn@pogo.udel.edu +28 -0 + sntp/Makefile.am@1.7 +28 -0 autogen update and more conversion - sntp/configure.ac@1.9, 2005-08-08 02:53:27-04:00, stenn@pogo.udel.edu +13 -6 + sntp/configure.ac@1.9 +13 -6 autogen update and more conversion -ChangeSet@1.1251.42.8, 2005-08-07 18:12:45-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.42.8, 2005-08-07 18:12:45-04:00, mayer@pogo.udel.edu Fix check for errors when recvfrom() is used - ntpd/ntp_io.c@1.187, 2005-08-07 18:12:07-04:00, mayer@pogo.udel.edu +4 -5 + ntpd/ntp_io.c@1.187 +4 -5 Fix check for errors when recvfrom() is used -ChangeSet@1.1251.38.11, 2005-08-07 15:10:14+00:00, kardel@pogo.udel.edu +4 -0 +ChangeSet@1.1251.38.11, 2005-08-07 15:10:14+00:00, kardel@pogo.udel.edu testdcf.c: cleanup warnings document revision on startup @@ -18576,213 +199343,213 @@ ChangeSet@1.1251.38.11, 2005-08-07 15:10:14+00:00, kardel@pogo.udel.edu +4 -0 clean log output cleanup size handling wrt/ to buffer boundaries - libparse/clk_rawdcf.c@1.11, 2005-08-07 15:05:50+00:00, kardel@pogo.udel.edu +44 -36 + libparse/clk_rawdcf.c@1.11 +44 -36 clean log output cleanup size handling wrt/ to buffer boundaries - libparse/parse.c@1.11, 2005-08-07 15:06:09+00:00, kardel@pogo.udel.edu +8 -5 + libparse/parse.c@1.11 +8 -5 cleanup size handling wrt/ to buffer boundaries - ntpd/refclock_parse.c@1.35, 2005-08-07 15:06:49+00:00, kardel@pogo.udel.edu +7 -4 + ntpd/refclock_parse.c@1.35 +7 -4 cleanup size handling wrt/ to buffer boundaries - parseutil/testdcf.c@1.7, 2005-08-07 15:07:56+00:00, kardel@pogo.udel.edu +24 -7 + parseutil/testdcf.c@1.7 +24 -7 cleanup warnings document revision on startup fix setting of baud rate -ChangeSet@1.1251.42.7, 2005-08-05 19:29:48-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.42.7, 2005-08-05 19:29:48-04:00, mayer@pogo.udel.edu Fix for systems that do not support MCAST - ntpd/ntp_io.c@1.186, 2005-08-05 19:29:28-04:00, mayer@pogo.udel.edu +2 -34 + ntpd/ntp_io.c@1.186 +2 -34 Fix for systems that do not support MCAST -ChangeSet@1.1251.42.6, 2005-08-02 23:04:57-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.42.6, 2005-08-02 23:04:57-04:00, stenn@whimsy.udel.edu Lose UDP_WILDCARD_DELIVERY - TODO@1.8, 2005-08-02 23:04:37-04:00, stenn@whimsy.udel.edu +0 -2 + TODO@1.8 +0 -2 Lose UDP_WILDCARD_DELIVERY - configure.ac@1.359.1.17, 2005-08-02 23:04:38-04:00, stenn@whimsy.udel.edu +0 -60 + configure.ac@1.359.1.17 +0 -60 Lose UDP_WILDCARD_DELIVERY - include/ntp_machine.h@1.20, 2005-08-02 23:04:38-04:00, stenn@whimsy.udel.edu +0 -5 + include/ntp_machine.h@1.20 +0 -5 Lose UDP_WILDCARD_DELIVERY - ports/winnt/include/config.h@1.39, 2005-08-02 23:04:39-04:00, stenn@whimsy.udel.edu +0 -1 + ports/winnt/include/config.h@1.39 +0 -1 Lose UDP_WILDCARD_DELIVERY -ChangeSet@1.1251.42.5, 2005-08-02 21:48:09-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.42.5, 2005-08-02 21:48:09-04:00, stenn@whimsy.udel.edu Another RANDOM -> ntp_random() - libntp/systime.c@1.34, 2005-08-02 21:47:51-04:00, stenn@whimsy.udel.edu +2 -1 + libntp/systime.c@1.34 +2 -1 Another RANDOM -> ntp_random() -ChangeSet@1.1251.42.4, 2005-08-02 20:19:27-04:00, stenn@whimsy.udel.edu +17 -0 +ChangeSet@1.1251.42.4, 2005-08-02 20:19:27-04:00, stenn@whimsy.udel.edu libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - BitKeeper/deleted/.del-ranny.c~3e480692@1.4, 2005-08-02 19:36:07-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-ranny.c~3e480692@1.4 +0 -0 Delete: libntp/ranny.c - configure.ac@1.359.1.16, 2005-08-02 20:18:13-04:00, stenn@whimsy.udel.edu +1 -11 + configure.ac@1.359.1.16 +1 -11 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - include/l_stdlib.h@1.15, 2005-08-02 20:18:14-04:00, stenn@whimsy.udel.edu +0 -13 + include/l_stdlib.h@1.15 +0 -13 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - include/ntp.h@1.117, 2005-08-02 20:18:14-04:00, stenn@whimsy.udel.edu +1 -9 + include/ntp.h@1.117 +1 -9 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - include/ntp_machine.h@1.19, 2005-08-02 20:18:15-04:00, stenn@whimsy.udel.edu +0 -2 + include/ntp_machine.h@1.19 +0 -2 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - include/ntpd.h@1.82, 2005-08-02 20:18:15-04:00, stenn@whimsy.udel.edu +3 -0 + include/ntpd.h@1.82 +3 -0 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - libntp/Makefile.am@1.35, 2005-08-02 20:18:16-04:00, stenn@whimsy.udel.edu +2 -2 + libntp/Makefile.am@1.35 +2 -2 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - libntp/random.c@1.3, 2005-08-02 20:18:16-04:00, stenn@whimsy.udel.edu +9 -9 + libntp/random.c@1.3 +9 -9 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - ntpd/ntp_config.c@1.129, 2005-08-02 20:18:17-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_config.c@1.129 +1 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - ntpd/ntp_crypto.c@1.97, 2005-08-02 20:18:17-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_crypto.c@1.97 +1 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - ntpd/ntp_monitor.c@1.15, 2005-08-02 20:18:18-04:00, stenn@whimsy.udel.edu +2 -1 + ntpd/ntp_monitor.c@1.15 +2 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - ntpd/ntp_peer.c@1.80, 2005-08-02 20:18:19-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_peer.c@1.80 +1 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - ntpd/ntp_proto.c@1.228, 2005-08-02 20:18:19-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.228 +1 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - ntpd/ntpd.c@1.61.1.9, 2005-08-02 20:18:20-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd.c@1.61.1.9 +1 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - ntpd/ntpsim.c@1.11, 2005-08-02 20:18:21-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpsim.c@1.11 +1 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - util/Makefile.am@1.26, 2005-08-02 20:18:21-04:00, stenn@whimsy.udel.edu +1 -1 + util/Makefile.am@1.26 +1 -1 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. - util/ntp-keygen.c@1.32, 2005-08-02 20:18:21-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.c@1.32 +2 -2 libntp/random.c now always provides ntp_[s]random(). Use them instead of RANDOM and SRANDOM. -ChangeSet@1.1251.43.3, 2005-08-02 03:45:25-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.43.3, 2005-08-02 03:45:25-04:00, stenn@whimsy.udel.edu Make it easy to distinguish -stable and -dev snapshots - version.m4@1.3, 2005-08-02 03:45:00-04:00, stenn@whimsy.udel.edu +1 -1 + version.m4@1.3 +1 -1 Make it easy to distinguish -stable and -dev snapshots -ChangeSet@1.1251.43.2, 2005-08-02 03:25:30-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1251.43.2, 2005-08-02 03:25:30-04:00, stenn@whimsy.udel.edu Lose libntp/ranny.c - include/ntp_stdlib.h@1.22, 2005-08-02 03:22:43-04:00, stenn@whimsy.udel.edu +0 -1 + include/ntp_stdlib.h@1.22 +0 -1 Lose libntp/ranny.c - libntp/Makefile.am@1.34, 2005-08-02 03:23:01-04:00, stenn@whimsy.udel.edu +1 -1 + libntp/Makefile.am@1.34 +1 -1 Lose libntp/ranny.c - libntp/systime.c@1.33, 2005-08-02 03:23:15-04:00, stenn@whimsy.udel.edu +3 -1 + libntp/systime.c@1.33 +3 -1 Lose libntp/ranny.c - ntpd/ntp_peer.c@1.76.1.2, 2005-08-02 03:23:26-04:00, stenn@whimsy.udel.edu +1 -3 + ntpd/ntp_peer.c@1.76.1.2 +1 -3 Lose libntp/ranny.c - ntpd/ntpd.c@1.61.1.8, 2005-08-02 03:23:28-04:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntpd.c@1.61.1.8 +0 -1 Lose libntp/ranny.c - ntpd/ntpsim.c@1.10, 2005-08-02 03:23:29-04:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntpsim.c@1.10 +0 -1 Lose libntp/ranny.c -ChangeSet@1.1251.43.1, 2005-08-01 19:40:14-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.43.1, 2005-08-01 19:40:14-04:00, stenn@whimsy.udel.edu Dave Mills: change findpeer(), other cleanup - include/ntpd.h@1.79.1.1, 2005-08-01 19:36:40-04:00, stenn@whimsy.udel.edu +1 -1 + include/ntpd.h@1.79.1.1 +1 -1 Dave Mills: change findpeer() - ntpd/ntp_peer.c@1.76.1.1, 2005-08-01 19:37:38-04:00, stenn@whimsy.udel.edu +0 -4 + ntpd/ntp_peer.c@1.76.1.1 +0 -4 Dave Mills: change findpeer() - ntpd/ntp_proto.c@1.227, 2005-08-01 19:37:50-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntp_proto.c@1.227 +4 -4 Dave Mills: change findpeer(), other cleanup -ChangeSet@1.1251.41.2, 2005-08-01 12:36:38-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.41.2, 2005-08-01 12:36:38-04:00, mayer@pogo.udel.edu Missing break in switch selection - ports/winnt/ntpd/ntp_iocompletionport.c@1.16, 2005-08-01 12:36:22-04:00, mayer@pogo.udel.edu +1 -48 + ports/winnt/ntpd/ntp_iocompletionport.c@1.16 +1 -48 Missing break in switch selection -ChangeSet@1.1251.41.1, 2005-08-01 12:34:24-04:00, mayer@pogo.udel.edu +3 -0 +ChangeSet@1.1251.41.1, 2005-08-01 12:34:24-04:00, mayer@pogo.udel.edu Enable IPv6 multicast interface - include/ntpd.h@1.78.1.1, 2005-08-01 12:34:07-04:00, mayer@pogo.udel.edu +1 -0 + include/ntpd.h@1.78.1.1 +1 -0 Enable IPv6 multicast interface - ntpd/ntp_io.c@1.185, 2005-08-01 12:34:07-04:00, mayer@pogo.udel.edu +61 -2 + ntpd/ntp_io.c@1.185 +61 -2 Enable IPv6 multicast interface - ntpd/ntp_peer.c@1.77, 2005-08-01 12:34:08-04:00, mayer@pogo.udel.edu +14 -3 + ntpd/ntp_peer.c@1.77 +14 -3 Enable IPv6 multicast interface -ChangeSet@1.1251.40.1, 2005-07-27 21:25:59+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.40.1, 2005-07-27 21:25:59+00:00, kardel@pogo.udel.edu refclock_parse.c: fix a long (> 11 years) misconfiguration wrt/ Meinberg cflag factory default setup. CSTOPB was missing for the 7E2 default data format of the DCF77 clocks. - ntpd/refclock_parse.c@1.34, 2005-07-27 21:24:36+00:00, kardel@pogo.udel.edu +9 -4 + ntpd/refclock_parse.c@1.34 +9 -4 fix a long (> 11 years) misconfiguration wrt/ Meinberg cflag factory default setup. CSTOPB was missing for the 7E2 default data format of the DCF77 clocks. -ChangeSet@1.1251.38.7, 2005-07-25 12:46:00-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.7, 2005-07-25 12:46:00-04:00, mayer@pogo.udel.edu Always provide the addr_ismulticast function - ntpd/ntp_io.c@1.184, 2005-07-25 12:45:27-04:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.184 +1 -1 Always provide the addr_ismulticast function -ChangeSet@1.1251.38.6, 2005-07-24 16:41:43-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.6, 2005-07-24 16:41:43-04:00, mayer@pogo.udel.edu Fix isaddr_multicast to not be dependent on whether or not MCAST is supported - ntpd/ntp_io.c@1.183, 2005-07-24 16:41:20-04:00, mayer@pogo.udel.edu +5 -5 + ntpd/ntp_io.c@1.183 +5 -5 Fix isaddr_multicast to not be dependent on whether or not MCAST is supported -ChangeSet@1.1251.38.5, 2005-07-24 15:50:24-04:00, mayer@pogo.udel.edu +7 -0 +ChangeSet@1.1251.38.5, 2005-07-24 15:50:24-04:00, mayer@pogo.udel.edu Revamp of I/O Completion ports for Windows - include/recvbuff.h@1.9, 2005-07-24 15:48:34-04:00, mayer@pogo.udel.edu +0 -2 + include/recvbuff.h@1.9 +0 -2 Revamp of I/O Completion ports for Windows - libntp/recvbuff.c@1.11, 2005-07-24 15:48:34-04:00, mayer@pogo.udel.edu +22 -17 + libntp/recvbuff.c@1.11 +22 -17 Revamp of I/O Completion ports for Windows - ports/winnt/include/ntp_iocompletionport.h@1.9, 2005-07-24 15:48:34-04:00, mayer@pogo.udel.edu +16 -3 + ports/winnt/include/ntp_iocompletionport.h@1.9 +16 -3 Revamp of I/O Completion ports for Windows - ports/winnt/include/transmitbuff.h@1.4, 2005-07-24 15:48:34-04:00, mayer@pogo.udel.edu +4 -14 + ports/winnt/include/transmitbuff.h@1.4 +4 -14 Revamp of I/O Completion ports for Windows - ports/winnt/libntp/transmitbuff.c@1.5, 2005-07-24 15:48:34-04:00, mayer@pogo.udel.edu +113 -43 + ports/winnt/libntp/transmitbuff.c@1.5 +113 -43 Revamp of I/O Completion ports for Windows - ports/winnt/ntpd/nt_clockstuff.c@1.18, 2005-07-24 15:48:34-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/ntpd/nt_clockstuff.c@1.18 +1 -1 Revamp of I/O Completion ports for Windows - ports/winnt/ntpd/ntp_iocompletionport.c@1.15, 2005-07-24 15:48:34-04:00, mayer@pogo.udel.edu +182 -61 + ports/winnt/ntpd/ntp_iocompletionport.c@1.15 +182 -61 Revamp of I/O Completion ports for Windows -ChangeSet@1.1251.39.4, 2005-07-22 20:32:47-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.39.4, 2005-07-22 20:32:47-04:00, stenn@pogo.udel.edu Remove binio.c,gpstolfp.c,ieee754io.c,mfp_mul.c from libntp.a - libntp/Makefile.am@1.33, 2005-07-22 20:32:35-04:00, stenn@pogo.udel.edu +4 -4 + libntp/Makefile.am@1.33 +4 -4 Remove binio.c,gpstolfp.c,ieee754io.c,mfp_mul.c from libntp.a -ChangeSet@1.1251.39.3, 2005-07-21 19:43:37+00:00, kardel@pogo.udel.edu +30 -0 +ChangeSet@1.1251.39.3, 2005-07-21 19:43:37+00:00, kardel@pogo.udel.edu Makefile.am: support is gone - overaged files .del-sun4.sun4m~3e480692: @@ -18851,94 +199618,94 @@ ChangeSet@1.1251.39.3, 2005-07-21 19:43:37+00:00, kardel@pogo.udel.edu +30 -0 mfp_mul.c: Rename: libntp/mfp_mul.c -> libparse/mfp_mul.c - BitKeeper/deleted/.del-README~3e480692@1.3, 2005-07-17 20:54:05+00:00, kardel@pogo.udel.edu +0 -73 + BitKeeper/deleted/.del-README~3e480692@1.3 +0 -73 Delete: scripts/support/README - BitKeeper/deleted/.del-crontab~3e480692@1.3, 2005-07-17 20:54:50+00:00, kardel@pogo.udel.edu +0 -8 + BitKeeper/deleted/.del-crontab~3e480692@1.3 +0 -8 Delete: scripts/support/etc/crontab - BitKeeper/deleted/.del-cron~3e480692@1.3, 2005-07-17 20:54:44+00:00, kardel@pogo.udel.edu +0 -18 + BitKeeper/deleted/.del-cron~3e480692@1.3 +0 -18 Delete: scripts/support/etc/cron - BitKeeper/deleted/.del-hp300.hp300~3e480692@1.3, 2005-07-21 13:55:24+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-hp300.hp300~3e480692@1.3 +0 -0 Delete: scripts/support/conf/hp300.hp300 - BitKeeper/deleted/.del-hp700.hp700.faui47~3e480692@1.3, 2005-07-21 13:55:24+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-hp700.hp700.faui47~3e480692@1.3 +0 -0 Delete: scripts/support/conf/hp700.hp700.faui47 - BitKeeper/deleted/.del-hp700.hp700~3e480692@1.3, 2005-07-21 13:55:24+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-hp700.hp700~3e480692@1.3 +0 -0 Delete: scripts/support/conf/hp700.hp700 - BitKeeper/deleted/.del-hp800.hp800~3e480692@1.3, 2005-07-21 13:55:24+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-hp800.hp800~3e480692@1.3 +0 -0 Delete: scripts/support/conf/hp800.hp800 - BitKeeper/deleted/.del-install~3e480692@1.3, 2005-07-17 20:54:58+00:00, kardel@pogo.udel.edu +0 -67 + BitKeeper/deleted/.del-install~3e480692@1.3 +0 -67 Delete: scripts/support/etc/install - BitKeeper/deleted/.del-monl~3e480692@1.3, 2005-07-17 20:54:13+00:00, kardel@pogo.udel.edu +0 -213 + BitKeeper/deleted/.del-monl~3e480692@1.3 +0 -213 Delete: scripts/support/bin/monl - BitKeeper/deleted/.del-mvstats~3e480692@1.3, 2005-07-17 20:54:20+00:00, kardel@pogo.udel.edu +0 -23 + BitKeeper/deleted/.del-mvstats~3e480692@1.3 +0 -23 Delete: scripts/support/bin/mvstats - BitKeeper/deleted/.del-ntp.conf~3e480692@1.3, 2005-07-17 20:54:28+00:00, kardel@pogo.udel.edu +0 -3 + BitKeeper/deleted/.del-ntp.conf~3e480692@1.3 +0 -3 Delete: scripts/support/conf/ntp.conf - BitKeeper/deleted/.del-rc~3e480692@1.3, 2005-07-17 20:55:05+00:00, kardel@pogo.udel.edu +0 -198 + BitKeeper/deleted/.del-rc~3e480692@1.3 +0 -198 Delete: scripts/support/etc/rc - BitKeeper/deleted/.del-setup~3e480692@1.3, 2005-07-17 20:55:11+00:00, kardel@pogo.udel.edu +0 -72 + BitKeeper/deleted/.del-setup~3e480692@1.3 +0 -72 Delete: scripts/support/etc/setup - BitKeeper/deleted/.del-sun3.sun3~3e480692@1.3, 2005-07-21 13:55:24+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun3.sun3~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun3.sun3 - BitKeeper/deleted/.del-sun4.sun4.faui01~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4.faui01~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4.faui01 - BitKeeper/deleted/.del-sun4.sun4.faui10~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4.faui10~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4.faui10 - BitKeeper/deleted/.del-sun4.sun4.faui45~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4.faui45~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4.faui45 - BitKeeper/deleted/.del-sun4.sun4c.Lucifer~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4c.Lucifer~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4c.Lucifer - BitKeeper/deleted/.del-sun4.sun4c~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4c~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4c - BitKeeper/deleted/.del-sun4.sun4m.faui42~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4m.faui42~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4m.faui42 - BitKeeper/deleted/.del-sun4.sun4m.faui45m~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4m.faui45m~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4m.faui45m - BitKeeper/deleted/.del-sun4.sun4m~3e480692@1.3, 2005-07-21 13:55:25+00:00, kardel@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sun4.sun4m~3e480692@1.3 +0 -0 Delete: scripts/support/conf/sun4.sun4m - BitKeeper/deleted/.del-tickconf~3e480692@1.3, 2005-07-17 20:54:36+00:00, kardel@pogo.udel.edu +0 -19 + BitKeeper/deleted/.del-tickconf~3e480692@1.3 +0 -19 Delete: scripts/support/conf/tickconf - libparse/Makefile.am@1.8, 2005-07-21 13:50:56+00:00, kardel@pogo.udel.edu +23 -2 + libparse/Makefile.am@1.8 +23 -2 move binio.c, ieee754io.c into libparse - libparse/binio.c@1.6, 2005-07-17 20:51:59+00:00, kardel@pogo.udel.edu +0 -0 + libparse/binio.c@1.6 +0 -0 Rename: libntp/binio.c -> libparse/binio.c - libparse/gpstolfp.c@1.8, 2005-07-17 20:51:38+00:00, kardel@pogo.udel.edu +0 -0 + libparse/gpstolfp.c@1.8 +0 -0 Rename: libntp/gpstolfp.c -> libparse/gpstolfp.c - libparse/ieee754io.c@1.8, 2005-07-17 20:52:13+00:00, kardel@pogo.udel.edu +0 -0 + libparse/ieee754io.c@1.8 +0 -0 Rename: libntp/ieee754io.c -> libparse/ieee754io.c - libparse/mfp_mul.c@1.7, 2005-07-21 13:51:45+00:00, kardel@pogo.udel.edu +42 -11 + libparse/mfp_mul.c@1.7 +42 -11 correct carry propagation implementation - libparse/mfp_mul.c@1.6, 2005-07-17 20:51:19+00:00, kardel@pogo.udel.edu +0 -0 + libparse/mfp_mul.c@1.6 +0 -0 Rename: libntp/mfp_mul.c -> libparse/mfp_mul.c - ntpd/refclock_parse.c@1.33, 2005-07-21 13:53:00+00:00, kardel@pogo.udel.edu +41 -33 + ntpd/refclock_parse.c@1.33 +41 -33 fix bug 455: tripping over NULL pointer on cleanup fix shadow storage logic for ppsphaseadjust and trustime wrt/ time2 fix compiler warnings for some platforms wrt/ printf formatstrings and @@ -18946,643 +199713,643 @@ ChangeSet@1.1251.39.3, 2005-07-21 19:43:37+00:00, kardel@pogo.udel.edu +30 -0 reorder assignment in binding to avoid tripping over NULL pointers change contents of version string to include the RCS/CVS Id - scripts/Makefile.am@1.12, 2005-07-21 19:40:00+00:00, kardel@pogo.udel.edu +1 -1 + scripts/Makefile.am@1.12 +1 -1 support is gone - overaged files -ChangeSet@1.1178.5.5, 2005-07-19 21:21:45-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1178.5.5, 2005-07-19 21:21:45-04:00, stenn@whimsy.udel.edu FreeBSD porting issues - Makefile.am@1.46.1.1, 2005-07-19 21:21:29-04:00, stenn@whimsy.udel.edu +5 -5 + Makefile.am@1.46.1.1 +5 -5 FreeBSD porting issues - ntpdc/ntpdc.c@1.33.2.1, 2005-07-19 21:21:29-04:00, stenn@whimsy.udel.edu +5 -1 + ntpdc/ntpdc.c@1.33.2.1 +5 -1 FreeBSD porting issues - ntpq/ntpq.c@1.48.2.1, 2005-07-19 21:21:29-04:00, stenn@whimsy.udel.edu +5 -1 + ntpq/ntpq.c@1.48.2.1 +5 -1 FreeBSD porting issues -ChangeSet@1.1178.5.4, 2005-07-19 21:20:36-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1178.5.4, 2005-07-19 21:20:36-04:00, stenn@whimsy.udel.edu [Bug 466] Fix compilation under gcc4 - include/ntp_control.h@1.25.1.1, 2005-07-19 21:20:00-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntp_control.h@1.25.1.1 +1 -0 [Bug 466] Fix compilation under gcc4 - include/ntp_refclock.h@1.15.1.1, 2005-07-19 21:20:01-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntp_refclock.h@1.15.1.1 +1 -0 [Bug 466] Fix compilation under gcc4 - include/ntp_stdlib.h@1.21, 2005-07-19 21:20:01-04:00, stenn@whimsy.udel.edu +0 -4 + include/ntp_stdlib.h@1.21 +0 -4 [Bug 466] Fix compilation under gcc4 - include/ntpd.h@1.66.1.1, 2005-07-19 21:20:02-04:00, stenn@whimsy.udel.edu +0 -2 + include/ntpd.h@1.66.1.1 +0 -2 [Bug 466] Fix compilation under gcc4 -ChangeSet@1.1178.5.3, 2005-07-19 20:13:43-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.5.3, 2005-07-19 20:13:43-04:00, stenn@whimsy.udel.edu [Bug 464] building ntp with debugging disabled fails - ntpd/ntp_proto.c@1.179.1.1, 2005-07-19 20:12:20-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.179.1.1 +1 -1 [Bug 464] building ntp with debugging disabled fails -ChangeSet@1.1251.38.4, 2005-07-16 17:30:55-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.4, 2005-07-16 17:30:55-04:00, mayer@pogo.udel.edu Add debug code to print the broadcast interface used - ntpd/ntp_peer.c@1.76, 2005-07-16 17:30:35-04:00, mayer@pogo.udel.edu +5 -0 + ntpd/ntp_peer.c@1.76 +5 -0 Add debug code to print the broadcast interface used -ChangeSet@1.1251.38.3, 2005-07-16 17:29:55-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.38.3, 2005-07-16 17:29:55-04:00, mayer@pogo.udel.edu Fix read loop to skip out if nothing to do and not complain about it - ntpd/ntp_io.c@1.182, 2005-07-16 17:29:39-04:00, mayer@pogo.udel.edu +143 -146 + ntpd/ntp_io.c@1.182 +143 -146 Fix read loop to skip out if nothing to do and not complain about it -ChangeSet@1.1283, 2005-07-04 04:15:16-04:00, stenn@pogo.udel.edu +86 -0 +ChangeSet@1.1283, 2005-07-04 04:15:16-04:00, stenn@pogo.udel.edu New libopts - Makefile.am@1.51, 2005-07-04 04:09:28-04:00, stenn@pogo.udel.edu +2 -2 + Makefile.am@1.51 +2 -2 Cleanup - configure.ac@1.371, 2005-07-04 04:09:29-04:00, stenn@pogo.udel.edu +2 -0 + configure.ac@1.371 +2 -0 Cleanup - libopts/AUTHORS@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +2 -0 + libopts/AUTHORS@1.1 +2 -0 - libopts/AUTHORS@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/AUTHORS@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/AUTHORS - libopts/COPYING@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +502 -0 + libopts/COPYING@1.1 +502 -0 - libopts/COPYING@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/COPYING@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/COPYING - libopts/COPYING.lgpl@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +502 -0 + libopts/COPYING.lgpl@1.1 +502 -0 - libopts/COPYING.lgpl@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/COPYING.lgpl@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/COPYING.lgpl - libopts/COPYING.mbsd@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +26 -0 + libopts/COPYING.mbsd@1.1 +26 -0 - libopts/COPYING.mbsd@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/COPYING.mbsd@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/COPYING.mbsd - libopts/ChangeLog@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +4 -0 + libopts/ChangeLog@1.1 +4 -0 - libopts/ChangeLog@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/ChangeLog@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/ChangeLog - libopts/INSTALL@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +231 -0 + libopts/INSTALL@1.1 +231 -0 - libopts/INSTALL@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/INSTALL@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/INSTALL - libopts/MakeDefs.inc@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +5 -0 + libopts/MakeDefs.inc@1.1 +5 -0 - libopts/MakeDefs.inc@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/MakeDefs.inc@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/MakeDefs.inc - libopts/Makefile.am@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +4 -0 + libopts/Makefile.am@1.1 +4 -0 - libopts/Makefile.am@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/Makefile.am@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/Makefile.am - libopts/NEWS@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +6 -0 + libopts/NEWS@1.1 +6 -0 - libopts/NEWS@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/NEWS@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/NEWS - libopts/README@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +2 -0 + libopts/README@1.1 +2 -0 - libopts/README@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/README@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/README - libopts/aclocal.m4@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +6827 -0 + libopts/aclocal.m4@1.1 +6827 -0 - libopts/aclocal.m4@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/aclocal.m4@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/aclocal.m4 - libopts/autoopts.c@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +1033 -0 + libopts/autoopts.c@1.1 +1033 -0 - libopts/autoopts.c@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/autoopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/autoopts.c - libopts/autoopts.h@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +337 -0 + libopts/autoopts.h@1.1 +337 -0 - libopts/autoopts.h@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/autoopts.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/autoopts.h - libopts/autoopts/options.h@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +864 -0 + libopts/autoopts/options.h@1.1 +864 -0 - libopts/autoopts/options.h@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/autoopts/options.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/autoopts/options.h - libopts/autoopts/usage-txt.h@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +479 -0 + libopts/autoopts/usage-txt.h@1.1 +479 -0 - libopts/autoopts/usage-txt.h@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/autoopts/usage-txt.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/autoopts/usage-txt.h - libopts/boolean.c@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +102 -0 + libopts/boolean.c@1.1 +102 -0 - libopts/boolean.c@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/boolean.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/boolean.c - libopts/bootstrap@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +34 -0 + libopts/bootstrap@1.1 +34 -0 - libopts/bootstrap@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/bootstrap@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/bootstrap - libopts/compat/compat.h@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +249 -0 + libopts/compat/compat.h@1.1 +249 -0 - libopts/compat/compat.h@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/compat/compat.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/compat/compat.h - libopts/compat/pathfind.c@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +332 -0 + libopts/compat/pathfind.c@1.1 +332 -0 - libopts/compat/pathfind.c@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/compat/pathfind.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/compat/pathfind.c - libopts/config-h.in@1.1, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +140 -0 + libopts/config-h.in@1.1 +140 -0 - libopts/config-h.in@1.0, 2005-07-04 04:10:36-04:00, stenn@pogo.udel.edu +0 -0 + libopts/config-h.in@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/config-h.in - libopts/config-h.in~@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +236 -0 + libopts/config-h.in~@1.1 +236 -0 - libopts/config-h.in~@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/config-h.in~@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/config-h.in~ - libopts/configfile.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +1282 -0 + libopts/configfile.c@1.1 +1282 -0 - libopts/configfile.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/configfile.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/configfile.c - libopts/configure@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +23905 -0 + libopts/configure@1.1 +23905 -0 - libopts/configure@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/configure@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/configure - libopts/configure.ac@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +54 -0 + libopts/configure.ac@1.1 +54 -0 - libopts/configure.ac@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/configure.ac@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/configure.ac - libopts/cook.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +355 -0 + libopts/cook.c@1.1 +355 -0 - libopts/cook.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/cook.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/cook.c - libopts/enumeration.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +449 -0 + libopts/enumeration.c@1.1 +449 -0 - libopts/enumeration.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/enumeration.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/enumeration.c - libopts/environment.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +261 -0 + libopts/environment.c@1.1 +261 -0 - libopts/environment.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/environment.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/environment.c - libopts/genshell.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +300 -0 + libopts/genshell.c@1.1 +300 -0 - libopts/genshell.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/genshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/genshell.c - libopts/genshell.h@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +143 -0 + libopts/genshell.h@1.1 +143 -0 - libopts/genshell.h@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/genshell.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/genshell.h - libopts/libopts.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +29 -0 + libopts/libopts.c@1.1 +29 -0 - libopts/libopts.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts.c - libopts/libopts.m4@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +387 -0 + libopts/libopts.m4@1.1 +387 -0 - libopts/libopts.m4@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts.m4@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts.m4 - libopts/libopts/Makefile.am@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +12 -0 + libopts/libopts/Makefile.am@1.1 +12 -0 - libopts/libopts/Makefile.am@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/Makefile.am@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/Makefile.am - libopts/libopts/autoopts.c@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +1033 -0 + libopts/libopts/autoopts.c@1.1 +1033 -0 - libopts/libopts/autoopts.c@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/autoopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/autoopts.c - libopts/libopts/autoopts.h@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +337 -0 + libopts/libopts/autoopts.h@1.1 +337 -0 - libopts/libopts/autoopts.h@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/autoopts.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/autoopts.h - libopts/libopts/boolean.c@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +102 -0 + libopts/libopts/boolean.c@1.1 +102 -0 - libopts/libopts/boolean.c@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/boolean.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/boolean.c - libopts/libopts/configfile.c@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +1282 -0 + libopts/libopts/configfile.c@1.1 +1282 -0 - libopts/libopts/configfile.c@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/configfile.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/configfile.c - libopts/libopts/cook.c@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +355 -0 + libopts/libopts/cook.c@1.1 +355 -0 - libopts/libopts/cook.c@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/cook.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/cook.c - libopts/libopts/enumeration.c@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +449 -0 + libopts/libopts/enumeration.c@1.1 +449 -0 - libopts/libopts/enumeration.c@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/enumeration.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/enumeration.c - libopts/libopts/environment.c@1.1, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +261 -0 + libopts/libopts/environment.c@1.1 +261 -0 - libopts/libopts/environment.c@1.0, 2005-07-04 04:12:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/environment.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/environment.c - libopts/libopts/genshell.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +300 -0 + libopts/libopts/genshell.c@1.1 +300 -0 - libopts/libopts/genshell.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/genshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/genshell.c - libopts/libopts/genshell.h@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +143 -0 + libopts/libopts/genshell.h@1.1 +143 -0 - libopts/libopts/genshell.h@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/genshell.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/genshell.h - libopts/libopts/libopts.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +29 -0 + libopts/libopts/libopts.c@1.1 +29 -0 - libopts/libopts/libopts.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/libopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/libopts.c - libopts/libopts/load.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +470 -0 + libopts/libopts/load.c@1.1 +470 -0 - libopts/libopts/load.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/load.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/load.c - libopts/libopts/makeshell.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +1100 -0 + libopts/libopts/makeshell.c@1.1 +1100 -0 - libopts/libopts/makeshell.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/makeshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/makeshell.c - libopts/libopts/nested.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +707 -0 + libopts/libopts/nested.c@1.1 +707 -0 - libopts/libopts/nested.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/nested.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/nested.c - libopts/libopts/numeric.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +89 -0 + libopts/libopts/numeric.c@1.1 +89 -0 - libopts/libopts/numeric.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/numeric.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/numeric.c - libopts/libopts/pgusage.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +154 -0 + libopts/libopts/pgusage.c@1.1 +154 -0 - libopts/libopts/pgusage.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/pgusage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/pgusage.c - libopts/libopts/proto.h@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +124 -0 + libopts/libopts/proto.h@1.1 +124 -0 - libopts/libopts/proto.h@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/proto.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/proto.h - libopts/libopts/putshell.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +333 -0 + libopts/libopts/putshell.c@1.1 +333 -0 - libopts/libopts/putshell.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/putshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/putshell.c - libopts/libopts/restore.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +207 -0 + libopts/libopts/restore.c@1.1 +207 -0 - libopts/libopts/restore.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/restore.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/restore.c - libopts/libopts/save.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +499 -0 + libopts/libopts/save.c@1.1 +499 -0 - libopts/libopts/save.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/save.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/save.c - libopts/libopts/sort.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +369 -0 + libopts/libopts/sort.c@1.1 +369 -0 - libopts/libopts/sort.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/sort.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/sort.c - libopts/libopts/stack.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +224 -0 + libopts/libopts/stack.c@1.1 +224 -0 - libopts/libopts/stack.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/stack.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/stack.c - libopts/libopts/streqvcmp.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +292 -0 + libopts/libopts/streqvcmp.c@1.1 +292 -0 - libopts/libopts/streqvcmp.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/streqvcmp.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/streqvcmp.c - libopts/libopts/text_mmap.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +312 -0 + libopts/libopts/text_mmap.c@1.1 +312 -0 - libopts/libopts/text_mmap.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/text_mmap.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/text_mmap.c - libopts/libopts/tokenize.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +322 -0 + libopts/libopts/tokenize.c@1.1 +322 -0 - libopts/libopts/tokenize.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/tokenize.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/tokenize.c - libopts/libopts/usage.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +651 -0 + libopts/libopts/usage.c@1.1 +651 -0 - libopts/libopts/usage.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/usage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/usage.c - libopts/libopts/version.c@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +177 -0 + libopts/libopts/version.c@1.1 +177 -0 - libopts/libopts/version.c@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts/version.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts/version.c - libopts/load.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +470 -0 + libopts/load.c@1.1 +470 -0 - libopts/load.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/load.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/load.c - libopts/m4/compile@1.1, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +142 -0 + libopts/m4/compile@1.1 +142 -0 - libopts/m4/compile@1.0, 2005-07-04 04:12:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/compile@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/compile - libopts/m4/config.guess@1.1, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +1495 -0 + libopts/m4/config.guess@1.1 +1495 -0 - libopts/m4/config.guess@1.0, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/config.guess@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/config.guess - libopts/m4/config.sub@1.1, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +1570 -0 + libopts/m4/config.sub@1.1 +1570 -0 - libopts/m4/config.sub@1.0, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/config.sub@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/config.sub - libopts/m4/depcomp@1.1, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +522 -0 + libopts/m4/depcomp@1.1 +522 -0 - libopts/m4/depcomp@1.0, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/depcomp@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/depcomp - libopts/m4/install-sh@1.1, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +323 -0 + libopts/m4/install-sh@1.1 +323 -0 - libopts/m4/install-sh@1.0, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/install-sh@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/install-sh - libopts/m4/libopts.m4@1.1, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +331 -0 + libopts/m4/libopts.m4@1.1 +331 -0 - libopts/m4/libopts.m4@1.0, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/libopts.m4@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/libopts.m4 - libopts/m4/ltmain.sh@1.1, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +6500 -0 + libopts/m4/ltmain.sh@1.1 +6500 -0 - libopts/m4/ltmain.sh@1.0, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/ltmain.sh@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/ltmain.sh - libopts/m4/missing@1.1, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +353 -0 + libopts/m4/missing@1.1 +353 -0 - libopts/m4/missing@1.0, 2005-07-04 04:12:39-04:00, stenn@pogo.udel.edu +0 -0 + libopts/m4/missing@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/m4/missing - libopts/makeshell.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +1100 -0 + libopts/makeshell.c@1.1 +1100 -0 - libopts/makeshell.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/makeshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/makeshell.c - libopts/nested.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +707 -0 + libopts/nested.c@1.1 +707 -0 - libopts/nested.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/nested.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/nested.c - libopts/numeric.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +89 -0 + libopts/numeric.c@1.1 +89 -0 - libopts/numeric.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/numeric.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/numeric.c - libopts/pgusage.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +154 -0 + libopts/pgusage.c@1.1 +154 -0 - libopts/pgusage.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/pgusage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/pgusage.c - libopts/proto.h@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +124 -0 + libopts/proto.h@1.1 +124 -0 - libopts/proto.h@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/proto.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/proto.h - libopts/putshell.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +333 -0 + libopts/putshell.c@1.1 +333 -0 - libopts/putshell.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/putshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/putshell.c - libopts/restore.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +207 -0 + libopts/restore.c@1.1 +207 -0 - libopts/restore.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/restore.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/restore.c - libopts/save.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +499 -0 + libopts/save.c@1.1 +499 -0 - libopts/save.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/save.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/save.c - libopts/sort.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +369 -0 + libopts/sort.c@1.1 +369 -0 - libopts/sort.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/sort.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/sort.c - libopts/stack.c@1.1, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +224 -0 + libopts/stack.c@1.1 +224 -0 - libopts/stack.c@1.0, 2005-07-04 04:10:37-04:00, stenn@pogo.udel.edu +0 -0 + libopts/stack.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/stack.c - libopts/streqvcmp.c@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +292 -0 + libopts/streqvcmp.c@1.1 +292 -0 - libopts/streqvcmp.c@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/streqvcmp.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/streqvcmp.c - libopts/text_mmap.c@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +312 -0 + libopts/text_mmap.c@1.1 +312 -0 - libopts/text_mmap.c@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/text_mmap.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/text_mmap.c - libopts/tokenize.c@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +322 -0 + libopts/tokenize.c@1.1 +322 -0 - libopts/tokenize.c@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/tokenize.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/tokenize.c - libopts/usage.c@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +651 -0 + libopts/usage.c@1.1 +651 -0 - libopts/usage.c@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/usage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/usage.c - libopts/version.c@1.1, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +177 -0 + libopts/version.c@1.1 +177 -0 - libopts/version.c@1.0, 2005-07-04 04:10:38-04:00, stenn@pogo.udel.edu +0 -0 + libopts/version.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/version.c - ntpdc/ntpdc-opts.def@1.3, 2005-07-04 04:09:16-04:00, stenn@pogo.udel.edu +22 -7 + ntpdc/ntpdc-opts.def@1.3 +22 -7 Cleanup - ntpq/ntpq-opts.def@1.2, 2005-07-04 04:09:17-04:00, stenn@pogo.udel.edu +242 -5 + ntpq/ntpq-opts.def@1.2 +242 -5 Cleanup -ChangeSet@1.1282, 2005-07-04 02:40:36-04:00, stenn@pogo.udel.edu +33 -0 +ChangeSet@1.1282, 2005-07-04 02:40:36-04:00, stenn@pogo.udel.edu Remove old libopts/ - BitKeeper/deleted/.del-COPYING.lgpl~446c1c486f21fd2e@1.2, 2005-07-04 02:37:24-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-COPYING.lgpl~446c1c486f21fd2e@1.2 +0 -0 Delete: libopts/COPYING.lgpl - BitKeeper/deleted/.del-COPYING.mbsd~7a99797cacd53056@1.2, 2005-07-04 02:37:25-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-COPYING.mbsd~7a99797cacd53056@1.2 +0 -0 Delete: libopts/COPYING.mbsd - BitKeeper/deleted/.del-MakeDefs.inc~159b003e2ec363b5@1.2, 2005-07-04 02:37:25-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-MakeDefs.inc~159b003e2ec363b5@1.2 +0 -0 Delete: libopts/MakeDefs.inc - BitKeeper/deleted/.del-Makefile.am~fbc0c90887a6abe1@1.3, 2005-07-04 02:37:25-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-Makefile.am~fbc0c90887a6abe1@1.3 +0 -0 Delete: libopts/Makefile.am - BitKeeper/deleted/.del-README~863ded79da7cd04e@1.2, 2005-07-04 02:37:25-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-README~863ded79da7cd04e@1.2 +0 -0 Delete: libopts/README - BitKeeper/deleted/.del-autoopts.c~8d508a4c6d6337a8@1.3, 2005-07-04 02:37:25-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-autoopts.c~8d508a4c6d6337a8@1.3 +0 -0 Delete: libopts/autoopts.c - BitKeeper/deleted/.del-autoopts.h~24ccfda237b1a4e4@1.3, 2005-07-04 02:37:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-autoopts.h~24ccfda237b1a4e4@1.3 +0 -0 Delete: libopts/autoopts.h - BitKeeper/deleted/.del-boolean.c~76d65cce6791b639@1.3, 2005-07-04 02:37:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-boolean.c~76d65cce6791b639@1.3 +0 -0 Delete: libopts/boolean.c - BitKeeper/deleted/.del-compat.h~b5311be51765bbc8@1.3, 2005-07-04 02:37:50-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-compat.h~b5311be51765bbc8@1.3 +0 -0 Delete: libopts/compat/compat.h - BitKeeper/deleted/.del-enumeration.c~406a20f27bb1e70b@1.3, 2005-07-04 02:37:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-enumeration.c~406a20f27bb1e70b@1.3 +0 -0 Delete: libopts/enumeration.c - BitKeeper/deleted/.del-environment.c~cb6a850da6dc34bd@1.3, 2005-07-04 02:37:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-environment.c~cb6a850da6dc34bd@1.3 +0 -0 Delete: libopts/environment.c - BitKeeper/deleted/.del-genshell.c~f2627aa3ed9ec273@1.3, 2005-07-04 02:37:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-genshell.c~f2627aa3ed9ec273@1.3 +0 -0 Delete: libopts/genshell.c - BitKeeper/deleted/.del-genshell.h~e70a6981bf25d8d7@1.3, 2005-07-04 02:37:26-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-genshell.h~e70a6981bf25d8d7@1.3 +0 -0 Delete: libopts/genshell.h - BitKeeper/deleted/.del-libopts.c~48986232bbeb4a0@1.2, 2005-07-04 02:37:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-libopts.c~48986232bbeb4a0@1.2 +0 -0 Delete: libopts/libopts.c - BitKeeper/deleted/.del-libopts.m4~b877c4d87dcb4b42@1.3, 2005-07-04 02:37:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-libopts.m4~b877c4d87dcb4b42@1.3 +0 -0 Delete: libopts/libopts.m4 - BitKeeper/deleted/.del-load.c~ac03722a64c7070c@1.3, 2005-07-04 02:37:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-load.c~ac03722a64c7070c@1.3 +0 -0 Delete: libopts/load.c - BitKeeper/deleted/.del-makeshell.c~83bda01ad08e7d2@1.3, 2005-07-04 02:37:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-makeshell.c~83bda01ad08e7d2@1.3 +0 -0 Delete: libopts/makeshell.c - BitKeeper/deleted/.del-numeric.c~fb3a05758eeebb76@1.3, 2005-07-04 02:37:27-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-numeric.c~fb3a05758eeebb76@1.3 +0 -0 Delete: libopts/numeric.c - BitKeeper/deleted/.del-options.h~21d498cf4fa940d7@1.3, 2005-07-04 02:37:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-options.h~21d498cf4fa940d7@1.3 +0 -0 Delete: libopts/options.h - BitKeeper/deleted/.del-pathfind.c~f2717c337308e580@1.3, 2005-07-04 02:37:50-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-pathfind.c~f2717c337308e580@1.3 +0 -0 Delete: libopts/compat/pathfind.c - BitKeeper/deleted/.del-pgusage.c~a02c107578a438f@1.3, 2005-07-04 02:37:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-pgusage.c~a02c107578a438f@1.3 +0 -0 Delete: libopts/pgusage.c - BitKeeper/deleted/.del-putshell.c~cc1d047a2bea9716@1.3, 2005-07-04 02:37:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-putshell.c~cc1d047a2bea9716@1.3 +0 -0 Delete: libopts/putshell.c - BitKeeper/deleted/.del-restore.c~9b4b04133eb12966@1.3, 2005-07-04 02:37:28-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-restore.c~9b4b04133eb12966@1.3 +0 -0 Delete: libopts/restore.c - BitKeeper/deleted/.del-save.c~d8aaf91115194b06@1.3, 2005-07-04 02:37:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-save.c~d8aaf91115194b06@1.3 +0 -0 Delete: libopts/save.c - BitKeeper/deleted/.del-sort.c~a3a8ea89587b8a4@1.3, 2005-07-04 02:37:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-sort.c~a3a8ea89587b8a4@1.3 +0 -0 Delete: libopts/sort.c - BitKeeper/deleted/.del-stack.c~b43aa38ab8b08c0d@1.3, 2005-07-04 02:37:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-stack.c~b43aa38ab8b08c0d@1.3 +0 -0 Delete: libopts/stack.c - BitKeeper/deleted/.del-streqv.h~961ec0971a342cd6@1.3, 2005-07-04 02:37:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-streqv.h~961ec0971a342cd6@1.3 +0 -0 Delete: libopts/streqv.h - BitKeeper/deleted/.del-streqvcmp.c~7ef8826c4cd9bd3f@1.3, 2005-07-04 02:37:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-streqvcmp.c~7ef8826c4cd9bd3f@1.3 +0 -0 Delete: libopts/streqvcmp.c - BitKeeper/deleted/.del-tokenize.c~7729f53ebb45f578@1.2, 2005-07-04 02:37:29-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-tokenize.c~7729f53ebb45f578@1.2 +0 -0 Delete: libopts/tokenize.c - BitKeeper/deleted/.del-tokenize.h~cabedf7f2026e66@1.2, 2005-07-04 02:37:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-tokenize.h~cabedf7f2026e66@1.2 +0 -0 Delete: libopts/tokenize.h - BitKeeper/deleted/.del-usage-txt.h~53df7a61187840e9@1.3, 2005-07-04 02:37:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-usage-txt.h~53df7a61187840e9@1.3 +0 -0 Delete: libopts/usage-txt.h - BitKeeper/deleted/.del-usage.c~d5db6221d54a6f45@1.3, 2005-07-04 02:37:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-usage.c~d5db6221d54a6f45@1.3 +0 -0 Delete: libopts/usage.c - BitKeeper/deleted/.del-version.c~39f34e94894b40d2@1.3, 2005-07-04 02:37:30-04:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-version.c~39f34e94894b40d2@1.3 +0 -0 Delete: libopts/version.c -ChangeSet@1.1251.38.2, 2005-07-03 08:30:38-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.38.2, 2005-07-03 08:30:38-04:00, mayer@pogo.udel.edu Additional IPv6 multicasting fixes and fix for size of default_ai_family - ntpd/ntp_config.c@1.128, 2005-07-02 15:27:13-04:00, mayer@pogo.udel.edu +3 -7 + ntpd/ntp_config.c@1.128 +3 -7 Fix the size of default_ai_family which should have been short - ntpd/ntp_io.c@1.181, 2005-07-02 15:25:25-04:00, mayer@pogo.udel.edu +32 -10 + ntpd/ntp_io.c@1.181 +32 -10 Additional fixes for IPv6 multicasting -ChangeSet@1.1178.5.2, 2005-07-03 01:54:05-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.5.2, 2005-07-03 01:54:05-04:00, stenn@whimsy.udel.edu Change from openlogging to a list at ntp.isc.org - BitKeeper/etc/config@1.7, 2005-07-03 01:53:43-04:00, stenn@whimsy.udel.edu +2 -1 + BitKeeper/etc/config@1.7 +2 -1 Change from openlogging to a list at ntp.isc.org -ChangeSet@1.1251.36.5, 2005-07-01 10:42:55+02:00, claas@nixfix.(none) +1 -0 +ChangeSet@1.1251.36.5, 2005-07-01 10:42:55+02:00, claas@nixfix.(none) refclock_neoclock4x.c: solve AIX problems - ntpd/refclock_neoclock4x.c@1.12, 2005-07-01 10:41:47+02:00, claas@nixfix.(none) +65 -6 + ntpd/refclock_neoclock4x.c@1.12 +65 -6 solve AIX problems -ChangeSet@1.1251.36.4, 2005-06-29 04:31:59-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.36.4, 2005-06-29 04:31:59-04:00, stenn@whimsy.udel.edu VxWorks cleanup - ntpq/ntpq.c@1.55.1.3, 2005-06-29 04:31:37-04:00, stenn@whimsy.udel.edu +4 -3 + ntpq/ntpq.c@1.55.1.3 +4 -3 VxWorks cleanup -ChangeSet@1.1251.37.1, 2005-06-28 20:30:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.37.1, 2005-06-28 20:30:44-04:00, stenn@whimsy.udel.edu Cleanup from Dave Mills - ntpd/ntp_proto.c@1.225, 2005-06-28 20:30:25-04:00, stenn@whimsy.udel.edu +4 -2 + ntpd/ntp_proto.c@1.225 +4 -2 Cleanup from Dave Mills -ChangeSet@1.1251.36.1, 2005-06-28 04:28:30-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.36.1, 2005-06-28 04:28:30-04:00, stenn@whimsy.udel.edu Only look for sys/sched.h if sched.h is not found - configure.ac@1.359.1.15, 2005-06-28 04:28:06-04:00, stenn@whimsy.udel.edu +5 -1 + configure.ac@1.359.1.15 +5 -1 Only look for sys/sched.h if sched.h is not found -ChangeSet@1.1251.35.1, 2005-06-27 03:23:38-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.35.1, 2005-06-27 03:23:38-04:00, stenn@whimsy.udel.edu Fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.108, 2005-06-27 03:23:15-04:00, stenn@whimsy.udel.edu +2 -3 + ntpd/ntp_loopfilter.c@1.108 +2 -3 Fixes from Dave Mills - ntpd/ntp_proto.c@1.224, 2005-06-27 03:23:13-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.224 +1 -1 Fixes from Dave Mills -ChangeSet@1.1251.1.129, 2005-06-26 12:34:11-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.129, 2005-06-26 12:34:11-04:00, mayer@pogo.udel.edu Added MULTICAST_NONEWSOCKET to configuration, Windows doesn't allow separate socket for multicast - ports/winnt/include/config.h@1.38, 2005-06-26 12:33:08-04:00, mayer@pogo.udel.edu +5 -3 + ports/winnt/include/config.h@1.38 +5 -3 Added MULTICAST_NONEWSOCKET to configuration, Windows doesn't allow separate socket for multicast -ChangeSet@1.1251.1.127, 2005-06-25 22:13:01-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.127, 2005-06-25 22:13:01-04:00, mayer@pogo.udel.edu Fixes for IPv6 multicast at least for FreeBSD - ntpd/ntp_io.c@1.180, 2005-06-25 22:12:38-04:00, mayer@pogo.udel.edu +162 -34 + ntpd/ntp_io.c@1.180 +162 -34 Fixes for IPv6 multicast at least for FreeBSD -ChangeSet@1.1251.33.8, 2005-06-25 21:28:14+00:00, kardel@pogo.udel.edu +7 -0 +ChangeSet@1.1251.33.8, 2005-06-25 21:28:14+00:00, kardel@pogo.udel.edu refclock_parse.c: fix acceptance of clocks unsync clocks right at start change status reporting to use fixed refclock_report() @@ -19602,27 +200369,27 @@ ChangeSet@1.1251.33.8, 2005-06-25 21:28:14+00:00, kardel@pogo.udel.edu +7 -0 driver8.html: anonymize version number in sample output - html/drivers/driver8.html@1.17, 2005-06-25 21:21:23+00:00, kardel@pogo.udel.edu +1 -1 + html/drivers/driver8.html@1.17 +1 -1 anonymize version number in sample output - include/mbg_gps166.h@1.5, 2005-06-25 21:22:33+00:00, kardel@pogo.udel.edu +7 -2 + include/mbg_gps166.h@1.5 +7 -2 add missing log keywords - include/parse.h@1.7, 2005-06-25 21:22:45+00:00, kardel@pogo.udel.edu +6 -3 + include/parse.h@1.7 +6 -3 add missing log keywords - include/parse_conf.h@1.5, 2005-06-25 21:22:49+00:00, kardel@pogo.udel.edu +12 -3 + include/parse_conf.h@1.5 +12 -3 add missing log keywords - kernel/sys/parsestreams.h@1.7, 2005-06-25 21:23:23+00:00, kardel@pogo.udel.edu +33 -9 + kernel/sys/parsestreams.h@1.7 +33 -9 update copyright - ntpd/ntp_refclock.c@1.71, 2005-06-25 21:24:13+00:00, kardel@pogo.udel.edu +36 -8 + ntpd/ntp_refclock.c@1.71 +36 -8 complete event to statistic mapping make refclock_report to follow RFC1305 rules for clock.status and event reporting - ntpd/refclock_parse.c@1.32, 2005-06-25 21:25:42+00:00, kardel@pogo.udel.edu +152 -103 + ntpd/refclock_parse.c@1.32 +152 -103 fix acceptance of clocks unsync clocks right at start change status reporting to use fixed refclock_report() clarify trust logic @@ -19631,58 +200398,58 @@ ChangeSet@1.1251.33.8, 2005-06-25 21:28:14+00:00, kardel@pogo.udel.edu +7 -0 en- and dis-able HARDPPS in correlation to receiver sync state sort out log output sequence -ChangeSet@1.1251.33.7, 2005-06-23 21:24:16-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.33.7, 2005-06-23 21:24:16-04:00, stenn@whimsy.udel.edu Fixes from Dave Mills - ntpd/ntp_refclock.c@1.70, 2005-06-23 21:23:55-04:00, stenn@whimsy.udel.edu +8 -2 + ntpd/ntp_refclock.c@1.70 +8 -2 Fixes from Dave Mills -ChangeSet@1.1251.33.6, 2005-06-23 21:20:53-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.33.6, 2005-06-23 21:20:53-04:00, stenn@whimsy.udel.edu Bump NBUF to 80k. From Dave Mills - util/jitter.c@1.8, 2005-06-23 21:20:32-04:00, stenn@whimsy.udel.edu +1 -1 + util/jitter.c@1.8 +1 -1 Bump NBUF to 80k. From Dave Mills -ChangeSet@1.1251.33.5, 2005-06-14 00:56:12-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.33.5, 2005-06-14 00:56:12-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_refclock.c@1.69, 2005-06-14 00:55:52-04:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntp_refclock.c@1.69 +0 -1 Changes from Dave Mills -ChangeSet@1.1251.33.4, 2005-06-11 02:35:12-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.33.4, 2005-06-11 02:35:12-04:00, stenn@whimsy.udel.edu [Bug 448] want_getifaddrs typo fix (from Enrique Perez-Terron) - configure.ac@1.359.1.14, 2005-06-11 02:34:44-04:00, stenn@whimsy.udel.edu +1 -1 + configure.ac@1.359.1.14 +1 -1 [Bug 448] want_getifaddrs typo fix (from Enrique Perez-Terron) -ChangeSet@1.1251.34.1, 2005-06-09 21:42:42-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.34.1, 2005-06-09 21:42:42-04:00, stenn@whimsy.udel.edu [Bug 447] typo in ntpq.html - html/ntpq.html@1.26, 2005-06-09 21:42:23-04:00, stenn@whimsy.udel.edu +2 -2 + html/ntpq.html@1.26 +2 -2 [Bug 447] typo in ntpq.html -ChangeSet@1.1251.33.2, 2005-05-30 13:17:56+02:00, martin@pc-martin4. +2 -0 +ChangeSet@1.1251.33.2, 2005-05-30 13:17:56+02:00, martin@pc-martin4. Added SIZEOF_TIME_T for Windows. - BitKeeper/etc/logging_ok@1.54, 2005-05-30 13:17:55+02:00, martin@pc-martin4. +1 -0 + BitKeeper/etc/logging_ok@1.54 +1 -0 Logging to logging@openlogging.org accepted - ports/winnt/include/config.h@1.37, 2005-05-30 13:17:51+02:00, martin@pc-martin4. +1 -0 + ports/winnt/include/config.h@1.37 +1 -0 Added SIZEOF_TIME_T for Windows. -ChangeSet@1.1251.33.1, 2005-05-30 01:02:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.33.1, 2005-05-30 01:02:52-04:00, stenn@whimsy.udel.edu [Bug 434] Fix from Dave Mills - ntpd/ntp_refclock.c@1.68, 2005-05-30 01:02:23-04:00, stenn@whimsy.udel.edu +0 -3 + ntpd/ntp_refclock.c@1.68 +0 -3 [Bug 434] Fix from Dave Mills -ChangeSet@1.1251.26.19, 2005-05-28 06:27:19-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.26.19, 2005-05-28 06:27:19-04:00, stenn@pogo.udel.edu Cleanup building of parse clocks - configure.ac@1.359.1.12, 2005-05-28 06:27:07-04:00, stenn@pogo.udel.edu +3 -2 + configure.ac@1.359.1.12 +3 -2 Cleanup building of parse clocks -ChangeSet@1.1251.26.18, 2005-05-28 10:13:03+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.26.18, 2005-05-28 10:13:03+00:00, kardel@pogo.udel.edu ntp_refclock.c: We know that peer_leap can be LEAPNOTINSYNC from startup (peer_clear when FLAG_REFCLOCK is not set yet) or when copied from pp->leap. @@ -19691,53 +200458,53 @@ ChangeSet@1.1251.26.18, 2005-05-28 10:13:03+00:00, kardel@pogo.udel.edu +1 -0 (pp->leap) and will be the current information from then on. See Bug 434 - ntpd/ntp_refclock.c@1.67, 2005-05-28 10:07:44+00:00, kardel@pogo.udel.edu +1 -2 + ntpd/ntp_refclock.c@1.67 +1 -2 We know that peer_leap can be LEAPNOTINSYNC from startup (peer_clear when FLAG_REFCLOCK is not set yet) or when copied from pp->leap. Thus interrogating peer->leap only gives a a false reclock_report from initialization. False in that respect that new knowledge is available (pp->leap) and will be the current information from then on. -ChangeSet@1.1251.32.1, 2005-05-28 04:45:19-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.32.1, 2005-05-28 04:45:19-04:00, stenn@whimsy.udel.edu sys_clocktime defn/decl cleanup - include/ntpd.h@1.78, 2005-05-28 04:44:42-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntpd.h@1.78 +1 -0 sys_clocktime defn/decl cleanup - ntpd/ntp_proto.c@1.223, 2005-05-28 04:44:42-04:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntp_proto.c@1.223 +0 -1 sys_clocktime defn/decl cleanup -ChangeSet@1.1251.29.14, 2005-05-28 04:36:31-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.29.14, 2005-05-28 04:36:31-04:00, stenn@pogo.udel.edu [Bug 443] Remove duplicate LDISC_ #defines (from Brian Utterback) - include/ntp_tty.h@1.3, 2005-05-28 04:36:11-04:00, stenn@pogo.udel.edu +0 -13 + include/ntp_tty.h@1.3 +0 -13 [Bug 443] Remove duplicate LDISC_ #defines (from Brian Utterback) -ChangeSet@1.1251.29.13, 2005-05-28 04:22:37-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.29.13, 2005-05-28 04:22:37-04:00, stenn@pogo.udel.edu [Bug 442] some constants should be UL - ntpd/ntp_control.c@1.79, 2005-05-28 04:22:21-04:00, stenn@pogo.udel.edu +3 -2 + ntpd/ntp_control.c@1.79 +3 -2 [Bug 442] some constants should be UL -ChangeSet@1.1251.29.12, 2005-05-28 04:10:30-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.29.12, 2005-05-28 04:10:30-04:00, stenn@pogo.udel.edu [Bug 441] Treat *-*-solaris2* the same WRT AM_C_PROTOTYPES - configure.ac@1.359.2.2, 2005-05-28 04:10:16-04:00, stenn@pogo.udel.edu +6 -2 + configure.ac@1.359.2.2 +6 -2 [Bug 441] Treat *-*-solaris2* the same WRT AM_C_PROTOTYPES -ChangeSet@1.1251.29.11, 2005-05-27 05:39:09-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.29.11, 2005-05-27 05:39:09-04:00, stenn@whimsy.udel.edu [Bug 437] Trailing comma in enumeration (fix from Brian Utterback) - ntpd/ntp_config.c@1.126, 2005-05-27 05:38:47-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_config.c@1.126 +1 -1 [Bug 437] Trailing comma in enumeration (fix from Brian Utterback) -ChangeSet@1.1251.31.3, 2005-05-26 20:51:10-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.31.3, 2005-05-26 20:51:10-04:00, stenn@pogo.udel.edu [Bug 432] More in6addr_any cleanup - libisc/ifiter_ioctl.c@1.22.1.2, 2005-05-26 20:50:37-04:00, stenn@pogo.udel.edu +2 -0 + libisc/ifiter_ioctl.c@1.22.1.2 +2 -0 [Bug 432] More in6addr_any cleanup -ChangeSet@1.1251.26.15, 2005-05-26 22:05:19+00:00, kardel@pogo.udel.edu +2 -0 +ChangeSet@1.1251.26.15, 2005-05-26 22:05:19+00:00, kardel@pogo.udel.edu refclock_parse.c: cleanup status reporting ntp_refclock.c: @@ -19745,106 +200512,106 @@ ChangeSet@1.1251.26.15, 2005-05-26 22:05:19+00:00, kardel@pogo.udel.edu +2 -0 clk_fault report at first successful reception from a refclock driver - ntpd/ntp_refclock.c@1.66, 2005-05-26 22:03:15+00:00, kardel@pogo.udel.edu +3 -1 + ntpd/ntp_refclock.c@1.66 +3 -1 initialize currentstatus to CEVNT_FAULT to avoid misleading clk_fault report at first successful reception from a refclock driver - ntpd/refclock_parse.c@1.31, 2005-05-26 22:04:31+00:00, kardel@pogo.udel.edu +17 -14 + ntpd/refclock_parse.c@1.31 +17 -14 cleanup status reporting -ChangeSet@1.1251.26.14, 2005-05-26 19:36:08+00:00, kardel@pogo.udel.edu +1 -0 +ChangeSet@1.1251.26.14, 2005-05-26 19:36:08+00:00, kardel@pogo.udel.edu refclock_parse.c: implement fast refclock startup - ntpd/refclock_parse.c@1.30, 2005-05-26 19:35:31+00:00, kardel@pogo.udel.edu +9 -5 + ntpd/refclock_parse.c@1.30 +9 -5 implement fast refclock startup -ChangeSet@1.1251.31.2, 2005-05-26 06:28:54-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.31.2, 2005-05-26 06:28:54-04:00, stenn@pogo.udel.edu [Bug 432] More in6addr_any cleanup - libisc/ifiter_ioctl.c@1.22.1.1, 2005-05-26 06:28:40-04:00, stenn@pogo.udel.edu +1 -0 + libisc/ifiter_ioctl.c@1.22.1.1 +1 -0 [Bug 432] More in6addr_any cleanup -ChangeSet@1.1251.29.9, 2005-05-26 06:27:24-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.29.9, 2005-05-26 06:27:24-04:00, stenn@pogo.udel.edu [Bug 432] More in6addr_any cleanup - libisc/ifiter_ioctl.c@1.23, 2005-05-26 06:27:16-04:00, stenn@pogo.udel.edu +1 -0 + libisc/ifiter_ioctl.c@1.23 +1 -0 [Bug 432] More in6addr_any cleanup -ChangeSet@1.1251.31.1, 2005-05-26 06:23:51-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.31.1, 2005-05-26 06:23:51-04:00, stenn@pogo.udel.edu [Bug 432] More in6addr_any cleanup - libisc/ifiter_ioctl.c@1.22, 2005-05-26 06:23:34-04:00, stenn@pogo.udel.edu +1 -0 + libisc/ifiter_ioctl.c@1.22 +1 -0 [Bug 432] More in6addr_any cleanup -ChangeSet@1.1251.29.7, 2005-05-26 05:20:13-04:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1251.29.7, 2005-05-26 05:20:13-04:00, stenn@pogo.udel.edu [Bug 432] More in6addr_any cleanup - libisc/netaddr.c@1.4, 2005-05-26 05:18:57-04:00, stenn@pogo.udel.edu +2 -0 + libisc/netaddr.c@1.4 +2 -0 [Bug 432] More in6addr_any cleanup - libisc/sockaddr.c@1.4, 2005-05-26 05:18:57-04:00, stenn@pogo.udel.edu +2 -0 + libisc/sockaddr.c@1.4 +2 -0 [Bug 432] More in6addr_any cleanup -ChangeSet@1.1251.29.6, 2005-05-25 05:43:34-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.29.6, 2005-05-25 05:43:34-04:00, stenn@pogo.udel.edu [Bug 432] in6addr_any cleanup - libisc/sockaddr.c@1.3, 2005-05-25 05:43:19-04:00, stenn@pogo.udel.edu +2 -0 + libisc/sockaddr.c@1.3 +2 -0 [Bug 432] in6addr_any cleanup -ChangeSet@1.1251.29.4, 2005-05-25 05:01:29-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.29.4, 2005-05-25 05:01:29-04:00, stenn@whimsy.udel.edu [Bug 433] Avoid epoch overflow on 32 bit systems - libntp/prettydate.c@1.5, 2005-05-25 05:01:11-04:00, stenn@whimsy.udel.edu +9 -0 + libntp/prettydate.c@1.5 +9 -0 [Bug 433] Avoid epoch overflow on 32 bit systems -ChangeSet@1.1251.29.3, 2005-05-25 04:57:45-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.29.3, 2005-05-25 04:57:45-04:00, stenn@whimsy.udel.edu Try adding mort back in to the br-flock - br-flock@1.6, 2005-05-25 04:57:30-04:00, stenn@whimsy.udel.edu +1 -1 + br-flock@1.6 +1 -1 Try adding mort back in to the br-flock -ChangeSet@1.1251.29.2, 2005-05-24 04:37:05-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.29.2, 2005-05-24 04:37:05-04:00, stenn@whimsy.udel.edu [Bug 433] get SIZEOF_TIME_T - configure.ac@1.359.2.1, 2005-05-24 04:36:44-04:00, stenn@whimsy.udel.edu +1 -0 + configure.ac@1.359.2.1 +1 -0 [Bug 433] get SIZEOF_TIME_T -ChangeSet@1.1251.28.2, 2005-05-24 03:36:59-04:00, stenn@pogo.udel.edu +3 -0 +ChangeSet@1.1251.28.2, 2005-05-24 03:36:59-04:00, stenn@pogo.udel.edu [Bug 432] clean up in6addrany usage - libisc/netaddr.c@1.3, 2005-05-24 03:36:39-04:00, stenn@pogo.udel.edu +2 -0 + libisc/netaddr.c@1.3 +2 -0 [Bug 432] clean up in6addrany usage - libntp/ntp_rfc2553.c@1.22, 2005-05-24 03:36:39-04:00, stenn@pogo.udel.edu +0 -12 + libntp/ntp_rfc2553.c@1.22 +0 -12 [Bug 432] clean up in6addrany usage - ntpd/ntp_intres.c@1.40, 2005-05-24 03:36:39-04:00, stenn@pogo.udel.edu +2 -0 + ntpd/ntp_intres.c@1.40 +2 -0 [Bug 432] clean up in6addrany usage -ChangeSet@1.1251.28.1, 2005-05-24 03:11:09-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.28.1, 2005-05-24 03:11:09-04:00, stenn@pogo.udel.edu Added barnstable to the flock list - flock-build@1.31, 2005-05-24 03:10:56-04:00, stenn@pogo.udel.edu +1 -1 + flock-build@1.31 +1 -1 Added barnstable to the flock list -ChangeSet@1.1251.27.2, 2005-05-24 01:06:58-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.27.2, 2005-05-24 01:06:58-04:00, stenn@whimsy.udel.edu [Bug 431] More fixes from Dave Mills - ntpd/ntp_proto.c@1.222, 2005-05-24 01:06:32-04:00, stenn@whimsy.udel.edu +4 -3 + ntpd/ntp_proto.c@1.222 +4 -3 [Bug 431] More fixes from Dave Mills -ChangeSet@1.1251.27.1, 2005-05-22 04:21:05-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.27.1, 2005-05-22 04:21:05-04:00, stenn@whimsy.udel.edu [Bug 431]: FLAG_AUTHENABLE/FLAG_AUTHENTIC fixes from Dave Mills - ntpd/ntp_config.c@1.125, 2005-05-22 04:20:45-04:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntp_config.c@1.125 +0 -1 FLAG_AUTHENABLE/FLAG_AUTHENTIC fixes from Dave Mills - ntpd/ntp_proto.c@1.221, 2005-05-22 04:20:45-04:00, stenn@whimsy.udel.edu +2 -0 + ntpd/ntp_proto.c@1.221 +2 -0 FLAG_AUTHENABLE/FLAG_AUTHENTIC fixes from Dave Mills -ChangeSet@1.1251.26.12, 2005-05-21 10:53:09+00:00, kardel@pogo.udel.edu +39 -0 +ChangeSet@1.1251.26.12, 2005-05-21 10:53:09+00:00, kardel@pogo.udel.edu refclock_parse.c: add simple timstamp reading Meinberg clock (type 18) for the sake of cooperation in a multi client environment @@ -19860,956 +200627,956 @@ ChangeSet@1.1251.26.12, 2005-05-21 10:53:09+00:00, kardel@pogo.udel.edu +39 -0 ChangeLog-4.1.0: obfuscate email addresses - BitKeeper/etc/logging_ok@1.53, 2005-05-21 10:53:09+00:00, kardel@pogo.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.53 +1 -0 Logging to logging@openlogging.org accepted - ChangeLog-4.1.0@1.591, 2005-05-21 10:19:07+00:00, kardel@pogo.udel.edu +14 -14 + ChangeLog-4.1.0@1.591 +14 -14 obfuscate email addresses - configure.ac@1.359.1.10, 2005-05-21 10:19:24+00:00, kardel@pogo.udel.edu +4 -4 + configure.ac@1.359.1.10 +4 -4 NetBSD supports parse fully - html/copyright.html@1.30, 2005-05-21 10:24:49+00:00, kardel@pogo.udel.edu +1 -1 + html/copyright.html@1.30 +1 -1 update eMail address - html/drivers/driver8.html@1.16, 2005-05-21 10:26:00+00:00, kardel@pogo.udel.edu +414 -302 + html/drivers/driver8.html@1.16 +414 -302 document new clock type (Meinberg only time reading) - include/ascii.h@1.4, 2005-05-21 10:27:17+00:00, kardel@pogo.udel.edu +6 -3 + include/ascii.h@1.4 +6 -3 copyright maintenance - include/binio.h@1.4, 2005-05-21 10:27:17+00:00, kardel@pogo.udel.edu +6 -3 + include/binio.h@1.4 +6 -3 copyright maintenance - include/ieee754io.h@1.4, 2005-05-21 10:27:18+00:00, kardel@pogo.udel.edu +6 -3 + include/ieee754io.h@1.4 +6 -3 copyright maintenance - include/mbg_gps166.h@1.4, 2005-05-21 10:27:18+00:00, kardel@pogo.udel.edu +3 -3 + include/mbg_gps166.h@1.4 +3 -3 copyright maintenance - include/parse.h@1.6, 2005-05-21 10:27:19+00:00, kardel@pogo.udel.edu +4 -4 + include/parse.h@1.6 +4 -4 copyright maintenance - include/parse_conf.h@1.4, 2005-05-21 10:27:19+00:00, kardel@pogo.udel.edu +4 -4 + include/parse_conf.h@1.4 +4 -4 copyright maintenance - include/trimble.h@1.4, 2005-05-21 10:27:19+00:00, kardel@pogo.udel.edu +6 -3 + include/trimble.h@1.4 +6 -3 copyright maintenance - kernel/sys/parsestreams.h@1.6, 2005-05-21 10:28:50+00:00, kardel@pogo.udel.edu +1 -1 + kernel/sys/parsestreams.h@1.6 +1 -1 copyright maintenance - libntp/binio.c@1.5, 2005-05-21 10:29:41+00:00, kardel@pogo.udel.edu +3 -3 + libntp/binio.c@1.5 +3 -3 copyright maintenance - libntp/gpstolfp.c@1.7, 2005-05-21 10:29:41+00:00, kardel@pogo.udel.edu +6 -3 + libntp/gpstolfp.c@1.7 +6 -3 copyright maintenance - libntp/ieee754io.c@1.7, 2005-05-21 10:29:42+00:00, kardel@pogo.udel.edu +6 -3 + libntp/ieee754io.c@1.7 +6 -3 copyright maintenance - libntp/mfp_mul.c@1.5, 2005-05-21 10:29:42+00:00, kardel@pogo.udel.edu +6 -3 + libntp/mfp_mul.c@1.5 +6 -3 copyright maintenance - libparse/clk_computime.c@1.8, 2005-05-21 10:22:58+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_computime.c@1.8 +6 -3 copyright maintenance - libparse/clk_dcf7000.c@1.8, 2005-05-21 10:22:58+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_dcf7000.c@1.8 +6 -3 copyright maintenance - libparse/clk_hopf6021.c@1.8, 2005-05-21 10:22:58+00:00, kardel@pogo.udel.edu +2 -2 + libparse/clk_hopf6021.c@1.8 +2 -2 copyright maintenance - libparse/clk_meinberg.c@1.8, 2005-05-21 10:22:58+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_meinberg.c@1.8 +6 -3 copyright maintenance - libparse/clk_rawdcf.c@1.10, 2005-05-21 10:22:58+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_rawdcf.c@1.10 +6 -3 copyright maintenance - libparse/clk_rcc8000.c@1.8, 2005-05-21 10:22:58+00:00, kardel@pogo.udel.edu +2 -2 + libparse/clk_rcc8000.c@1.8 +2 -2 copyright maintenance - libparse/clk_schmid.c@1.8, 2005-05-21 10:22:58+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_schmid.c@1.8 +6 -3 copyright maintenance - libparse/clk_trimtaip.c@1.8, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_trimtaip.c@1.8 +6 -3 copyright maintenance - libparse/clk_trimtsip.c@1.8, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_trimtsip.c@1.8 +6 -3 copyright maintenance - libparse/clk_varitext.c@1.7, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +6 -3 + libparse/clk_varitext.c@1.7 +6 -3 copyright maintenance - libparse/clk_wharton.c@1.6, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +2 -2 + libparse/clk_wharton.c@1.6 +2 -2 copyright maintenance - libparse/data_mbg.c@1.5, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +6 -3 + libparse/data_mbg.c@1.5 +6 -3 copyright maintenance - libparse/info_trimble.c@1.4, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +6 -4 + libparse/info_trimble.c@1.4 +6 -4 copyright maintenance - libparse/parse.c@1.10, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +7 -4 + libparse/parse.c@1.10 +7 -4 copyright maintenance - libparse/parse_conf.c@1.9, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +6 -3 + libparse/parse_conf.c@1.9 +6 -3 copyright maintenance - libparse/parsesolaris.c@1.6, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +8 -5 + libparse/parsesolaris.c@1.6 +8 -5 copyright maintenance - libparse/parsestreams.c@1.6, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +9 -6 + libparse/parsestreams.c@1.6 +9 -6 copyright maintenance - libparse/trim_info.c@1.4, 2005-05-21 10:22:59+00:00, kardel@pogo.udel.edu +6 -3 + libparse/trim_info.c@1.4 +6 -3 copyright maintenance - ntpd/refclock_parse.c@1.29, 2005-05-21 10:31:59+00:00, kardel@pogo.udel.edu +71 -23 + ntpd/refclock_parse.c@1.29 +71 -23 add simple timstamp reading Meinberg clock (type 18) for the sake of cooperation in a multi client environment adjust to new pps setup - parseutil/dcfd.c@1.15, 2005-05-21 10:30:39+00:00, kardel@pogo.udel.edu +6 -3 + parseutil/dcfd.c@1.15 +6 -3 copyright maintenance - parseutil/testdcf.c@1.6, 2005-05-21 10:30:39+00:00, kardel@pogo.udel.edu +7 -4 + parseutil/testdcf.c@1.6 +7 -4 copyright maintenance - scripts/monitoring/ntploopwatch@1.4, 2005-05-21 10:31:06+00:00, kardel@pogo.udel.edu +1 -1 + scripts/monitoring/ntploopwatch@1.4 +1 -1 copyright maintenance -ChangeSet@1.1251.26.11, 2005-05-18 05:36:08-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.26.11, 2005-05-18 05:36:08-04:00, stenn@whimsy.udel.edu [Bug 408] fix based on proposed patch from cipo - ntpq/ntpq.c@1.55.1.2, 2005-05-18 05:35:39-04:00, stenn@whimsy.udel.edu +10 -4 + ntpq/ntpq.c@1.55.1.2 +10 -4 [Bug 408] fix based on proposed patch from cipo - ntpq/ntpq.h@1.5, 2005-05-18 05:35:39-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq.h@1.5 +1 -1 [Bug 408] fix based on proposed patch from cipo - ntpq/ntpq_ops.c@1.20.2.1, 2005-05-18 05:35:39-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq_ops.c@1.20.2.1 +1 -1 [Bug 408] fix based on proposed patch from cipo -ChangeSet@1.1251.26.10, 2005-05-17 01:17:18-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1251.26.10, 2005-05-17 01:17:18-04:00, stenn@whimsy.udel.edu Stuff from Dave Mills - ntpd/ntp_loopfilter.c@1.107, 2005-05-17 01:10:34-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntp_loopfilter.c@1.107 +4 -4 Fixes from Dave Mills - ntpd/ntp_proto.c@1.220, 2005-05-17 01:07:54-04:00, stenn@whimsy.udel.edu +26 -3 + ntpd/ntp_proto.c@1.220 +26 -3 Stratum checks from Dave Mills - ntpd/refclock_arbiter.c@1.12, 2005-05-17 01:16:28-04:00, stenn@whimsy.udel.edu +6 -4 + ntpd/refclock_arbiter.c@1.12 +6 -4 Dave Mills: Call refclock_receive() once a second for the first few seconds - ntpd/refclock_atom.c@1.53, 2005-05-17 01:09:52-04:00, stenn@whimsy.udel.edu +8 -0 + ntpd/refclock_atom.c@1.53 +8 -0 Dave Mills: flag4 in atom driver records offset to clockstats - ntpd/refclock_pst.c@1.8, 2005-05-17 01:16:27-04:00, stenn@whimsy.udel.edu +2 -1 + ntpd/refclock_pst.c@1.8 +2 -1 Dave Mills: Call refclock_receive() once a second for the first few seconds - ntpd/refclock_wwvb.c@1.15, 2005-05-17 01:16:27-04:00, stenn@whimsy.udel.edu +2 -0 + ntpd/refclock_wwvb.c@1.15 +2 -0 Dave Mills: Call refclock_receive() once a second for the first few seconds -ChangeSet@1.1251.26.9, 2005-05-06 00:23:53-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.26.9, 2005-05-06 00:23:53-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - BitKeeper/deleted/.del-driver23.html~3aed0663@1.13, 2005-05-06 00:11:21-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-driver23.html~3aed0663@1.13 +0 -0 Delete: html/drivers/driver23.html - BitKeeper/deleted/.del-driver24.html~3e480692@1.10, 2005-05-06 00:11:21-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-driver24.html~3e480692@1.10 +0 -0 Delete: html/drivers/driver24.html - BitKeeper/deleted/.del-footer.txt~29fb3ec8f08446d2@1.2, 2005-05-06 00:10:07-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-footer.txt~29fb3ec8f08446d2@1.2 +0 -0 Delete: html/drivers/footer.txt - html/index.html@1.31, 2005-05-06 00:23:32-04:00, stenn@whimsy.udel.edu +94 -94 + html/index.html@1.31 +94 -94 Changes from Dave Mills -ChangeSet@1.1251.26.8, 2005-05-05 23:55:29-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1251.26.8, 2005-05-05 23:55:29-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntp_refclock.h@1.18, 2005-05-05 23:55:12-04:00, stenn@whimsy.udel.edu +6 -5 + include/ntp_refclock.h@1.18 +6 -5 Changes from Dave Mills - ntpd/ntp_loopfilter.c@1.106, 2005-05-05 23:54:57-04:00, stenn@whimsy.udel.edu +2 -1 + ntpd/ntp_loopfilter.c@1.106 +2 -1 Changes from Dave Mills - ntpd/ntp_refclock.c@1.65, 2005-05-05 23:54:57-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_refclock.c@1.65 +1 -1 Changes from Dave Mills - ntpd/refclock_acts.c@1.25, 2005-05-05 23:54:57-04:00, stenn@whimsy.udel.edu +30 -18 + ntpd/refclock_acts.c@1.25 +30 -18 Changes from Dave Mills - ntpd/refclock_heath.c@1.12, 2005-05-05 23:54:58-04:00, stenn@whimsy.udel.edu +4 -3 + ntpd/refclock_heath.c@1.12 +4 -3 Changes from Dave Mills -ChangeSet@1.1251.26.7, 2005-04-27 05:53:39-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.26.7, 2005-04-27 05:53:39-04:00, stenn@whimsy.udel.edu [Bug 401] ntpdc: only ask for keyid once, from Jason Fountain - ntpdc/ntpdc.c@1.40.1.1, 2005-04-27 05:53:22-04:00, stenn@whimsy.udel.edu +10 -6 + ntpdc/ntpdc.c@1.40.1.1 +10 -6 [Bug 401] ntpdc: only ask for keyid once, from Jason Fountain -ChangeSet@1.1251.26.6, 2005-04-27 04:09:54-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.26.6, 2005-04-27 04:09:54-04:00, stenn@whimsy.udel.edu [Bug 409] Add DNS-SD/Rendezvous to ntpd, from Andre Masella - configure.ac@1.359.1.9, 2005-04-27 04:09:12-04:00, stenn@whimsy.udel.edu +11 -1 + configure.ac@1.359.1.9 +11 -1 [Bug 409] Add DNS-SD/Rendezvous to ntpd, from Andre Masella - ntpd/ntpd.c@1.61.2.1, 2005-04-27 04:09:12-04:00, stenn@whimsy.udel.edu +16 -0 + ntpd/ntpd.c@1.61.2.1 +16 -0 [Bug 409] Add DNS-SD/Rendezvous to ntpd, from Andre Masella -ChangeSet@1.1251.1.126, 2005-04-23 16:24:51-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.1.126, 2005-04-23 16:24:51-04:00, mayer@pogo.udel.edu Added support for -4 and -6 command line options - ntpd/cmd_args.c@1.34, 2005-04-23 16:24:18-04:00, mayer@pogo.udel.edu +9 -2 + ntpd/cmd_args.c@1.34 +9 -2 Added support for -4 and -6 command line options - ntpd/ntp_config.c@1.123.1.1, 2005-04-23 16:24:18-04:00, mayer@pogo.udel.edu +6 -21 + ntpd/ntp_config.c@1.123.1.1 +6 -21 Added support for -4 and -6 command line options -ChangeSet@1.1251.26.5, 2005-04-21 00:27:25-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.26.5, 2005-04-21 00:27:25-04:00, stenn@whimsy.udel.edu Documentation changes from Dave Mills - html/drivers/driver18.html@1.14, 2005-04-21 00:27:12-04:00, stenn@whimsy.udel.edu +10 -11 + html/drivers/driver18.html@1.14 +10 -11 Documentation changes from Dave Mills - html/drivers/driver36.html@1.25, 2005-04-21 00:27:11-04:00, stenn@whimsy.udel.edu +4 -88 + html/drivers/driver36.html@1.25 +4 -88 Documentation changes from Dave Mills - html/drivers/driver6.html@1.19, 2005-04-21 00:27:12-04:00, stenn@whimsy.udel.edu +6 -2 + html/drivers/driver6.html@1.19 +6 -2 Documentation changes from Dave Mills -ChangeSet@1.1251.26.4, 2005-04-21 00:23:40-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.26.4, 2005-04-21 00:23:40-04:00, stenn@whimsy.udel.edu Documentation changes from Dave Mills - html/audio.html@1.16, 2005-04-21 00:23:03-04:00, stenn@whimsy.udel.edu +95 -3 + html/audio.html@1.16 +95 -3 Documentation changes from Dave Mills - html/confopt.html@1.31, 2005-04-21 00:23:06-04:00, stenn@whimsy.udel.edu +1 -1 + html/confopt.html@1.31 +1 -1 Documentation changes from Dave Mills - html/ntpd.html@1.36, 2005-04-21 00:23:06-04:00, stenn@whimsy.udel.edu +4 -4 + html/ntpd.html@1.36 +4 -4 Documentation changes from Dave Mills - html/ntpq.html@1.25, 2005-04-21 00:23:06-04:00, stenn@whimsy.udel.edu +258 -255 + html/ntpq.html@1.25 +258 -255 Documentation changes from Dave Mills -ChangeSet@1.1251.26.3, 2005-04-21 00:08:47-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.26.3, 2005-04-21 00:08:47-04:00, stenn@whimsy.udel.edu anti-clockhop changes from Dave Mills - include/ntp.h@1.116, 2005-04-21 00:07:57-04:00, stenn@whimsy.udel.edu +6 -6 + include/ntp.h@1.116 +6 -6 anti-clockhop changes from Dave Mills - include/ntp_config.h@1.33, 2005-04-21 00:07:57-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntp_config.h@1.33 +1 -0 anti-clockhop changes from Dave Mills - ntpd/ntp_config.c@1.124, 2005-04-21 00:08:24-04:00, stenn@whimsy.udel.edu +5 -0 + ntpd/ntp_config.c@1.124 +5 -0 anti-clockhop changes from Dave Mills - ntpd/ntp_proto.c@1.219, 2005-04-21 00:08:25-04:00, stenn@whimsy.udel.edu +17 -7 + ntpd/ntp_proto.c@1.219 +17 -7 anti-clockhop changes from Dave Mills -ChangeSet@1.1251.1.124, 2005-04-20 23:55:08-04:00, mayer@pogo.udel.edu +3 -0 +ChangeSet@1.1251.1.124, 2005-04-20 23:55:08-04:00, mayer@pogo.udel.edu Remove log.* from make files - BitKeeper/deleted/.del-log.c~3e480692@1.7, 2005-04-20 23:29:37-04:00, mayer@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-log.c~3e480692@1.7 +0 -0 Delete: libntp/log.c - BitKeeper/deleted/.del-log.h~3e480692@1.5, 2005-04-20 23:29:43-04:00, mayer@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-log.h~3e480692@1.5 +0 -0 Delete: libntp/log.h - libntp/Makefile.am@1.32, 2005-04-20 23:54:14-04:00, mayer@pogo.udel.edu +2 -2 + libntp/Makefile.am@1.32 +2 -2 Remove log.* from make files -ChangeSet@1.1251.1.123, 2005-04-20 23:25:01-04:00, mayer@pogo.udel.edu +3 -0 +ChangeSet@1.1251.1.123, 2005-04-20 23:25:01-04:00, mayer@pogo.udel.edu Changes for multicasting - libntp/log.c@1.6, 2005-04-17 18:22:24-04:00, mayer@pogo.udel.edu +0 -0 + libntp/log.c@1.6 +0 -0 Rename: BitKeeper/deleted/.del-log.c~3e480692 -> libntp/log.c - BitKeeper/deleted/.del-log.c~3e480692@1.5, 2005-04-17 18:18:17-04:00, mayer@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-log.c~3e480692@1.5 +0 -0 Delete: libntp/log.c - libntp/log.h@1.4, 2005-04-17 18:22:49-04:00, mayer@pogo.udel.edu +0 -0 + libntp/log.h@1.4 +0 -0 Rename: BitKeeper/deleted/.del-log.h~3e480692 -> libntp/log.h - BitKeeper/deleted/.del-log.h~3e480692@1.3, 2005-04-17 18:18:20-04:00, mayer@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-log.h~3e480692@1.3 +0 -0 Delete: libntp/log.h - ntpd/ntp_io.c@1.179, 2005-04-20 23:24:43-04:00, mayer@pogo.udel.edu +35 -11 + ntpd/ntp_io.c@1.179 +35 -11 Changes for multicasting -ChangeSet@1.1251.26.2, 2005-04-18 22:29:49-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.26.2, 2005-04-18 22:29:49-04:00, stenn@whimsy.udel.edu anti-clockhop changes from Dave Mills - include/ntp.h@1.115, 2005-04-18 22:29:19-04:00, stenn@whimsy.udel.edu +1 -3 + include/ntp.h@1.115 +1 -3 anti-clockhop changes from Dave Mills - ntpd/ntp_proto.c@1.218, 2005-04-18 22:29:27-04:00, stenn@whimsy.udel.edu +21 -25 + ntpd/ntp_proto.c@1.218 +21 -25 anti-clockhop changes from Dave Mills -ChangeSet@1.1251.26.1, 2005-04-18 01:01:32-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1251.26.1, 2005-04-18 01:01:32-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntp.h@1.114, 2005-04-18 01:01:12-04:00, stenn@whimsy.udel.edu +2 -2 + include/ntp.h@1.114 +2 -2 Changes from Dave Mills - include/ntp_control.h@1.26, 2005-04-18 01:01:13-04:00, stenn@whimsy.udel.edu +9 -10 + include/ntp_control.h@1.26 +9 -10 Changes from Dave Mills - ntpd/ntp_control.c@1.78, 2005-04-18 01:01:02-04:00, stenn@whimsy.udel.edu +10 -15 + ntpd/ntp_control.c@1.78 +10 -15 Changes from Dave Mills - ntpd/ntp_peer.c@1.75, 2005-04-18 01:01:04-04:00, stenn@whimsy.udel.edu +0 -2 + ntpd/ntp_peer.c@1.75 +0 -2 Changes from Dave Mills - ntpd/ntp_proto.c@1.217, 2005-04-18 01:01:03-04:00, stenn@whimsy.udel.edu +37 -43 + ntpd/ntp_proto.c@1.217 +37 -43 Changes from Dave Mills -ChangeSet@1.1251.18.2, 2005-04-16 23:26:04-04:00, mayer@tecotoo. +10 -0 +ChangeSet@1.1251.18.2, 2005-04-16 23:26:04-04:00, mayer@tecotoo. Martin Burnicki's cleanup of command line options and setting the registry for NTP - BitKeeper/deleted/.del-log.c~87fe33f8@1.3, 2005-04-16 23:11:57-04:00, mayer@tecotoo. +0 -0 + BitKeeper/deleted/.del-log.c~87fe33f8@1.3 +0 -0 Delete: ports/winnt/libntp/log.c - BitKeeper/deleted/.del-log.h~29080509@1.5, 2005-04-16 23:12:02-04:00, mayer@tecotoo. +0 -0 + BitKeeper/deleted/.del-log.h~29080509@1.5 +0 -0 Delete: ports/winnt/libntp/log.h - include/ntp_cmdargs.h@1.3, 2005-04-16 23:15:27-04:00, mayer@tecotoo. +1 -0 + include/ntp_cmdargs.h@1.3 +1 -0 Martin Burnicki's changes to fix ntpd usage message - libntp/msyslog.c@1.19, 2005-04-16 23:21:23-04:00, mayer@tecotoo. +0 -1 + libntp/msyslog.c@1.19 +0 -1 Martin Burnicki's changes to remove unnecessary log.h include - ntpd/cmd_args.c@1.33, 2005-04-16 23:15:35-04:00, mayer@tecotoo. +38 -42 + ntpd/cmd_args.c@1.33 +38 -42 Martin Burnicki's changes to fix ntpd usage message - ntpd/ntpd.c@1.61.1.6, 2005-04-16 23:22:57-04:00, mayer@tecotoo. +0 -1 + ntpd/ntpd.c@1.61.1.6 +0 -1 Martin Burnicki's changes to remove unnecessary log.h include - ports/winnt/instsrv/Instsrv.dsp@1.6, 2005-04-16 23:25:00-04:00, mayer@tecotoo. +1 -1 + ports/winnt/instsrv/Instsrv.dsp@1.6 +1 -1 Miscellaneous cleanup - ports/winnt/libntp/libntp.dsp@1.25, 2005-04-16 23:24:18-04:00, mayer@tecotoo. +0 -8 + ports/winnt/libntp/libntp.dsp@1.25 +0 -8 Remove references to log.c and log.h - ports/winnt/ntpd/nt_clockstuff.c@1.17, 2005-04-16 23:20:47-04:00, mayer@tecotoo. +0 -2 + ports/winnt/ntpd/nt_clockstuff.c@1.17 +0 -2 Martin Burnicki's changes to remove unnecessary registry call - ports/winnt/ntpd/ntservice.c@1.5, 2005-04-16 23:19:51-04:00, mayer@tecotoo. +11 -5 + ports/winnt/ntpd/ntservice.c@1.5 +11 -5 Martin Burnicki's changes to fix ntpd usage message -ChangeSet@1.1251.1.121, 2005-04-12 17:43:36-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.1.121, 2005-04-12 17:43:36-04:00, stenn@whimsy.udel.edu Documentation changes from Dave Mills (including [Bug 412]) - html/accopt.html@1.23, 2005-04-12 17:43:00-04:00, stenn@whimsy.udel.edu +3 -5 + html/accopt.html@1.23 +3 -5 Documentation changes from Dave Mills - html/confopt.html@1.30, 2005-04-12 17:42:45-04:00, stenn@whimsy.udel.edu +2 -2 + html/confopt.html@1.30 +2 -2 [Bug 412] multicastclient requires an address (Dave Mills) - html/ntpq.html@1.24, 2005-04-12 17:43:03-04:00, stenn@whimsy.udel.edu +2 -3 + html/ntpq.html@1.24 +2 -3 Documentation changes from Dave Mills - html/refclock.html@1.31, 2005-04-12 17:43:01-04:00, stenn@whimsy.udel.edu +8 -10 + html/refclock.html@1.31 +8 -10 Documentation changes from Dave Mills -ChangeSet@1.1251.1.120, 2005-04-12 00:52:34-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.1.120, 2005-04-12 00:52:34-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_loopfilter.c@1.105, 2005-04-12 00:52:23-04:00, stenn@whimsy.udel.edu +3 -4 + ntpd/ntp_loopfilter.c@1.105 +3 -4 Changes from Dave Mills - ntpd/ntp_proto.c@1.216, 2005-04-12 00:52:21-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.216 +1 -1 Changes from Dave Mills -ChangeSet@1.1251.1.119, 2005-04-07 20:36:24-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.1.119, 2005-04-07 20:36:24-04:00, stenn@whimsy.udel.edu [Bug 405] and other fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.104, 2005-04-07 20:35:24-04:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntp_loopfilter.c@1.104 +0 -1 Fixes from Dave Mills - ntpd/ntp_peer.c@1.74, 2005-04-07 20:35:04-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_peer.c@1.74 +1 -1 [Bug 405] Fix from Dave Mills - ntpd/ntp_proto.c@1.215, 2005-04-07 20:35:22-04:00, stenn@whimsy.udel.edu +37 -44 + ntpd/ntp_proto.c@1.215 +37 -44 Fixes from Dave Mills -ChangeSet@1.1251.1.118, 2005-04-06 23:54:32-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.118, 2005-04-06 23:54:32-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_proto.c@1.214, 2005-04-06 23:54:11-04:00, stenn@whimsy.udel.edu +1 -2 + ntpd/ntp_proto.c@1.214 +1 -2 Changes from Dave Mills -ChangeSet@1.1251.1.117, 2005-04-06 01:09:48-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.1.117, 2005-04-06 01:09:48-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_peer.c@1.73, 2005-04-06 01:08:29-04:00, stenn@whimsy.udel.edu +2 -3 + ntpd/ntp_peer.c@1.73 +2 -3 Changes from Dave Mills - ntpd/ntp_proto.c@1.213, 2005-04-06 01:08:28-04:00, stenn@whimsy.udel.edu +25 -24 + ntpd/ntp_proto.c@1.213 +25 -24 Changes from Dave Mills -ChangeSet@1.1251.1.116, 2005-04-04 18:15:45-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.1.116, 2005-04-04 18:15:45-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntp.h@1.113, 2005-04-04 18:15:12-04:00, stenn@whimsy.udel.edu +4 -7 + include/ntp.h@1.113 +4 -7 Changes from Dave Mills - ntpd/ntp_loopfilter.c@1.103, 2005-04-04 18:15:05-04:00, stenn@whimsy.udel.edu +4 -1 + ntpd/ntp_loopfilter.c@1.103 +4 -1 Changes from Dave Mills - ntpd/ntp_proto.c@1.212, 2005-04-04 18:15:04-04:00, stenn@whimsy.udel.edu +1 -0 + ntpd/ntp_proto.c@1.212 +1 -0 Changes from Dave Mills -ChangeSet@1.1251.1.115, 2005-04-04 00:22:10-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.115, 2005-04-04 00:22:10-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_proto.c@1.211, 2005-04-04 00:21:25-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntp_proto.c@1.211 +3 -3 Changes from Dave Mills -ChangeSet@1.1251.1.114, 2005-04-03 20:41:23-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.1.114, 2005-04-03 20:41:23-04:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntp.h@1.112, 2005-04-03 20:40:55-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntp.h@1.112 +1 -0 Changes from Dave Mills - ntpd/ntp_peer.c@1.72, 2005-04-03 20:40:27-04:00, stenn@whimsy.udel.edu +4 -3 + ntpd/ntp_peer.c@1.72 +4 -3 Changes from Dave Mills - ntpd/ntp_proto.c@1.210, 2005-04-03 20:40:26-04:00, stenn@whimsy.udel.edu +98 -93 + ntpd/ntp_proto.c@1.210 +98 -93 Changes from Dave Mills -ChangeSet@1.1251.25.1, 2005-04-02 19:05:57-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.25.1, 2005-04-02 19:05:57-05:00, mayer@pogo.udel.edu Use any for the IPv4 join interface for mcast - ntpd/ntp_io.c@1.178, 2005-04-02 19:05:32-05:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.178 +1 -1 Use any for the IPv4 join interface for mcast -ChangeSet@1.1251.24.1, 2005-04-02 18:47:52-05:00, stenn@whimsy.udel.edu +7 -0 +ChangeSet@1.1251.24.1, 2005-04-02 18:47:52-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntp.h@1.111, 2005-04-02 18:47:06-05:00, stenn@whimsy.udel.edu +6 -7 + include/ntp.h@1.111 +6 -7 Changes from Dave Mills - include/ntp_crypto.h@1.35, 2005-04-02 18:47:09-05:00, stenn@whimsy.udel.edu +3 -2 + include/ntp_crypto.h@1.35 +3 -2 Changes from Dave Mills - include/ntpd.h@1.77, 2005-04-02 18:47:06-05:00, stenn@whimsy.udel.edu +1 -1 + include/ntpd.h@1.77 +1 -1 Changes from Dave Mills - libntp/statestr.c@1.9, 2005-04-02 18:47:18-05:00, stenn@whimsy.udel.edu +4 -3 + libntp/statestr.c@1.9 +4 -3 Changes from Dave Mills - ntpd/ntp_crypto.c@1.96, 2005-04-02 18:47:26-05:00, stenn@whimsy.udel.edu +47 -38 + ntpd/ntp_crypto.c@1.96 +47 -38 Changes from Dave Mills - ntpd/ntp_peer.c@1.71, 2005-04-02 18:47:25-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_peer.c@1.71 +2 -2 Changes from Dave Mills - ntpd/ntp_proto.c@1.209, 2005-04-02 18:47:25-05:00, stenn@whimsy.udel.edu +49 -81 + ntpd/ntp_proto.c@1.209 +49 -81 Changes from Dave Mills -ChangeSet@1.1251.1.111, 2005-04-02 18:36:32-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.111, 2005-04-02 18:36:32-05:00, mayer@pogo.udel.edu If unable to create a separate socket for multicast, find a local interface and use that instead of the wildcard sockets - ntpd/ntp_io.c@1.177, 2005-04-02 18:35:59-05:00, mayer@pogo.udel.edu +46 -25 + ntpd/ntp_io.c@1.177 +46 -25 If unable to create a separate socket for multicast, find a local interface and use that instead of the wildcard sockets -ChangeSet@1.1251.1.110, 2005-04-02 03:28:33-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.110, 2005-04-02 03:28:33-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_proto.c@1.208, 2005-04-02 03:28:12-05:00, stenn@whimsy.udel.edu +48 -44 + ntpd/ntp_proto.c@1.208 +48 -44 Changes from Dave Mills -ChangeSet@1.1251.1.109, 2005-03-31 23:03:22-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.1.109, 2005-03-31 23:03:22-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntpd.h@1.76, 2005-03-31 23:02:22-05:00, stenn@whimsy.udel.edu +1 -1 + include/ntpd.h@1.76 +1 -1 Changes from Dave Mills - ntpd/ntp_peer.c@1.70, 2005-03-31 23:02:53-05:00, stenn@whimsy.udel.edu +7 -5 + ntpd/ntp_peer.c@1.70 +7 -5 Changes from Dave Mills - ntpd/ntp_proto.c@1.207, 2005-03-31 23:02:52-05:00, stenn@whimsy.udel.edu +140 -135 + ntpd/ntp_proto.c@1.207 +140 -135 Changes from Dave Mills -ChangeSet@1.1251.23.1, 2005-03-31 21:57:56-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.23.1, 2005-03-31 21:57:56-05:00, mayer@pogo.udel.edu Change ignore packet message to only print if debug > 3 - ntpd/ntp_io.c@1.176, 2005-03-31 21:56:44-05:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.176 +1 -1 Change ignore packet message to only print if debug > 3 -ChangeSet@1.1251.1.107, 2005-03-31 11:15:14+02:00, root@sonne. +1 -0 +ChangeSet@1.1251.1.107, 2005-03-31 11:15:14+02:00, root@sonne. Remove quotes from tokens to handle paths with spaces correctly. - ntpd/ntp_config.c@1.123, 2005-03-31 11:15:07+02:00, root@sonne. +21 -0 + ntpd/ntp_config.c@1.123 +21 -0 Remove quotes from tokens to handle paths with spaces correctly. -ChangeSet@1.1251.1.106, 2005-03-31 11:11:43+02:00, root@sonne. +2 -0 +ChangeSet@1.1251.1.106, 2005-03-31 11:11:43+02:00, root@sonne. Fixed braces in conditional for OPENSSL. - BitKeeper/etc/logging_ok@1.52, 2005-03-31 11:11:43+02:00, root@sonne. +1 -0 + BitKeeper/etc/logging_ok@1.52 +1 -0 Logging to logging@openlogging.org accepted - ntpd/ntp_proto.c@1.206, 2005-03-31 11:11:33+02:00, root@sonne. +2 -1 + ntpd/ntp_proto.c@1.206 +2 -1 Fixed braces in conditional for OPENSSL. -ChangeSet@1.1251.22.2, 2005-03-30 23:41:14-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.22.2, 2005-03-30 23:41:14-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntp.h@1.108.1.1, 2005-03-30 23:40:58-05:00, stenn@whimsy.udel.edu +18 -8 + include/ntp.h@1.108.1.1 +18 -8 Changes from Dave Mills - ntpd/ntp_peer.c@1.69, 2005-03-30 23:40:46-05:00, stenn@whimsy.udel.edu +9 -8 + ntpd/ntp_peer.c@1.69 +9 -8 Changes from Dave Mills - ntpd/ntp_proto.c@1.203.1.2, 2005-03-30 23:40:46-05:00, stenn@whimsy.udel.edu +205 -205 + ntpd/ntp_proto.c@1.203.1.2 +205 -205 Changes from Dave Mills -ChangeSet@1.1251.1.104, 2005-03-30 23:07:59-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.104, 2005-03-30 23:07:59-05:00, mayer@pogo.udel.edu Bug #396 Windows-only fix to ignore incoming packets if flag on socket is set - ports/winnt/ntpd/ntp_iocompletionport.c@1.14, 2005-03-30 23:07:23-05:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/ntpd/ntp_iocompletionport.c@1.14 +1 -1 Bug #396 Windows-only fix to ignore incoming packets if flag on socket is set -ChangeSet@1.1251.22.1, 2005-03-27 18:39:02-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.22.1, 2005-03-27 18:39:02-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_proto.c@1.203.1.1, 2005-03-27 18:38:48-05:00, stenn@whimsy.udel.edu +6 -6 + ntpd/ntp_proto.c@1.203.1.1 +6 -6 Changes from Dave Mills -ChangeSet@1.1251.21.3, 2005-03-27 16:29:59-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.21.3, 2005-03-27 16:29:59-05:00, mayer@pogo.udel.edu Change in configuration setup prevented multicast packets from being accepted - ntpd/ntp_proto.c@1.201.1.1, 2005-03-27 16:29:44-05:00, mayer@pogo.udel.edu +17 -16 + ntpd/ntp_proto.c@1.201.1.1 +17 -16 Change in configuration setup prevented multicast packets from being accepted -ChangeSet@1.1251.21.2, 2005-03-27 16:28:44-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.21.2, 2005-03-27 16:28:44-05:00, mayer@pogo.udel.edu Bug #396: Don't accept broadcast packets if they are not enabled. wildcard socket was accepting them. Bind all sockets but drop any packet arriving on socket not specifically enabled - ntpd/ntp_io.c@1.175, 2005-03-27 16:28:25-05:00, mayer@pogo.udel.edu +81 -50 + ntpd/ntp_io.c@1.175 +81 -50 Bug #396: Don't accept broadcast packets if they are not enabled. wildcard socket was accepting them. Bind all sockets but drop any packet arriving on socket not specifically enabled -ChangeSet@1.1251.21.1, 2005-03-27 16:25:17-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.21.1, 2005-03-27 16:25:17-05:00, mayer@pogo.udel.edu Added ignore_packets to interface for sockets which will drop all requests - include/ntp.h@1.109, 2005-03-27 16:24:55-05:00, mayer@pogo.udel.edu +3 -0 + include/ntp.h@1.109 +3 -0 Added ignore_packets to interface for sockets which will drop all requests -ChangeSet@1.1251.1.102, 2005-03-24 00:54:17-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.1.102, 2005-03-24 00:54:17-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - ntpd/ntp_loopfilter.c@1.102, 2005-03-24 00:54:02-05:00, stenn@whimsy.udel.edu +1 -2 + ntpd/ntp_loopfilter.c@1.102 +1 -2 Changes from Dave Mills - ntpd/ntp_proto.c@1.203, 2005-03-24 00:54:01-05:00, stenn@whimsy.udel.edu +6 -11 + ntpd/ntp_proto.c@1.203 +6 -11 Changes from Dave Mills -ChangeSet@1.1251.20.1, 2005-03-18 00:43:24-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.20.1, 2005-03-18 00:43:24-05:00, stenn@whimsy.udel.edu Updates from Dave Mills - ntpd/ntp_proto.c@1.202, 2005-03-18 00:43:10-05:00, stenn@whimsy.udel.edu +15 -15 + ntpd/ntp_proto.c@1.202 +15 -15 Updates from Dave Mills -ChangeSet@1.1251.1.100, 2005-03-17 15:35:36-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.100, 2005-03-17 15:35:36-05:00, mayer@pogo.udel.edu Bug #396 - Disable wildcards for now to prevent this happening - ntpd/ntp_io.c@1.174, 2005-03-17 15:35:07-05:00, mayer@pogo.udel.edu +8 -1 + ntpd/ntp_io.c@1.174 +8 -1 Bug #396 - Disable wildcards for now to prevent this happening -ChangeSet@1.1251.1.99, 2005-03-15 23:31:42-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.99, 2005-03-15 23:31:42-05:00, stenn@whimsy.udel.edu ntp_proto.c fixes from Dave Mills - ntpd/ntp_proto.c@1.201, 2005-03-15 23:31:28-05:00, stenn@whimsy.udel.edu +111 -116 + ntpd/ntp_proto.c@1.201 +111 -116 ntp_proto.c fixes from Dave Mills -ChangeSet@1.1251.1.98, 2005-03-15 22:52:55-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.98, 2005-03-15 22:52:55-05:00, stenn@whimsy.udel.edu Only check OpenSSL Major/Minor/Fix/Status, not Patch - util/ntp-keygen.c@1.31, 2005-03-15 22:52:41-05:00, stenn@whimsy.udel.edu +5 -1 + util/ntp-keygen.c@1.31 +5 -1 Only check OpenSSL Major/Minor/Fix/Status, not Patch -ChangeSet@1.1251.19.1, 2005-03-14 19:11:49-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.19.1, 2005-03-14 19:11:49-05:00, stenn@whimsy.udel.edu Comment fixes from Dave Mills - ntpd/ntp_proto.c@1.200, 2005-03-14 19:08:56-05:00, stenn@whimsy.udel.edu +7 -2 + ntpd/ntp_proto.c@1.200 +7 -2 Comment fixes from Dave Mills -ChangeSet@1.1251.1.96, 2005-03-14 18:30:20-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.96, 2005-03-14 18:30:20-05:00, mayer@pogo.udel.edu Wrong Macro used should have been PROTO_MULTICAST_ADD instead of PROTO_BROADCLIENT - ntpd/ntp_config.c@1.122, 2005-03-14 18:30:00-05:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_config.c@1.122 +1 -1 Wrong Macro used should have been PROTO_MULTICAST_ADD instead of PROTO_BROADCLIENT -ChangeSet@1.1251.1.95, 2005-03-13 17:02:41-05:00, stenn@whimsy.udel.edu +7 -0 +ChangeSet@1.1251.1.95, 2005-03-13 17:02:41-05:00, stenn@whimsy.udel.edu Changes from Dave Mills (flash TEST bits changed!) - include/ntp.h@1.108, 2005-03-13 17:01:30-05:00, stenn@whimsy.udel.edu +35 -24 + include/ntp.h@1.108 +35 -24 Changes from Dave Mills (flashh TEST bits changed!) - include/ntpd.h@1.75, 2005-03-13 17:01:30-05:00, stenn@whimsy.udel.edu +1 -0 + include/ntpd.h@1.75 +1 -0 Changes from Dave Mills (flashh TEST bits changed!) - ntpd/ntp_control.c@1.77, 2005-03-13 17:01:47-05:00, stenn@whimsy.udel.edu +3 -1 + ntpd/ntp_control.c@1.77 +3 -1 Changes from Dave Mills (flash TEST bits changed!) - ntpd/ntp_crypto.c@1.95, 2005-03-13 17:01:49-05:00, stenn@whimsy.udel.edu +11 -11 + ntpd/ntp_crypto.c@1.95 +11 -11 Changes from Dave Mills (flash TEST bits changed!) - ntpd/ntp_peer.c@1.68, 2005-03-13 17:01:48-05:00, stenn@whimsy.udel.edu +6 -18 + ntpd/ntp_peer.c@1.68 +6 -18 Changes from Dave Mills (flash TEST bits changed!) - ntpd/ntp_proto.c@1.199, 2005-03-13 17:01:48-05:00, stenn@whimsy.udel.edu +233 -293 + ntpd/ntp_proto.c@1.199 +233 -293 Changes from Dave Mills (flash TEST bits changed!) - ntpq/ntpq.c@1.55.1.1, 2005-03-13 17:02:04-05:00, stenn@whimsy.udel.edu +14 -12 + ntpq/ntpq.c@1.55.1.1 +14 -12 Changes from Dave Mills (flash TEST bits changed!) -ChangeSet@1.1251.18.1, 2005-03-09 22:23:03-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.18.1, 2005-03-09 22:23:03-05:00, mayer@tecotoo. Update for UTC information version string - from Heiko Gerstung - ports/winnt/scripts/mkver.bat@1.7, 2005-03-09 22:22:30-05:00, mayer@tecotoo. +99 -23 + ports/winnt/scripts/mkver.bat@1.7 +99 -23 Update for UTC information version string - from Heiko Gerstung -ChangeSet@1.1251.1.93, 2005-03-09 01:04:51-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.93, 2005-03-09 01:04:51-05:00, stenn@whimsy.udel.edu Lose arbiter debug line. From Dave Mills. - ntpd/refclock_arbiter.c@1.11, 2005-03-09 01:04:29-05:00, stenn@whimsy.udel.edu +0 -2 + ntpd/refclock_arbiter.c@1.11 +0 -2 Lose debug line. From Dave Mills. -ChangeSet@1.1251.1.90, 2005-03-08 22:14:49-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.90, 2005-03-08 22:14:49-05:00, mayer@tecotoo. Fix to correctly create version string - from Heiko Gerstung - ports/winnt/scripts/mkver.bat@1.6, 2005-03-08 22:13:54-05:00, mayer@tecotoo. +265 -50 + ports/winnt/scripts/mkver.bat@1.6 +265 -50 Fix to correctly create version string - from Heiko Gerstung -ChangeSet@1.1251.17.1, 2005-03-07 23:18:40-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.17.1, 2005-03-07 23:18:40-05:00, mayer@pogo.udel.edu Check for max value of skips before adding - ntpd/ntp_io.c@1.169.1.6, 2005-03-07 23:18:23-05:00, mayer@pogo.udel.edu +7 -4 + ntpd/ntp_io.c@1.169.1.6 +7 -4 Check for max value of skips before adding -ChangeSet@1.1271, 2005-03-05 02:03:58-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1271, 2005-03-05 02:03:58-05:00, stenn@pogo.udel.edu cleanup - configure.ac@1.366, 2005-03-05 02:03:38-05:00, stenn@pogo.udel.edu +0 -33 + configure.ac@1.366 +0 -33 -ChangeSet@1.1251.15.11, 2005-03-05 01:40:18-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.15.11, 2005-03-05 01:40:18-05:00, stenn@whimsy.udel.edu [Bug 390] Do not run check-layout if cross-compiling - configure.ac@1.359.1.8, 2005-03-05 01:39:53-05:00, stenn@whimsy.udel.edu +46 -33 + configure.ac@1.359.1.8 +46 -33 [Bug 390] Do not run check-layout if cross-compiling - ntpdc/Makefile.am@1.23.1.1, 2005-03-05 01:39:53-05:00, stenn@whimsy.udel.edu +1 -6 + ntpdc/Makefile.am@1.23.1.1 +1 -6 [Bug 390] Do not run check-layout if cross-compiling -ChangeSet@1.1251.1.88, 2005-03-02 20:52:53-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.88, 2005-03-02 20:52:53-05:00, mayer@tecotoo. Test code - ntpd/ntp_io.c@1.171, 2005-03-02 20:51:46-05:00, mayer@tecotoo. +1 -1 + ntpd/ntp_io.c@1.171 +1 -1 Test code -ChangeSet@1.1178.5.1, 2005-03-02 16:18:07-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.5.1, 2005-03-02 16:18:07-05:00, stenn@whimsy.udel.edu [Bug 389] Fix from Remi Demis-Courmont, via Loic Minier (http://bugs.debian.org/293793 - ntpdate/ntpdate.c@1.47.1.1, 2005-03-02 16:17:50-05:00, stenn@whimsy.udel.edu +46 -16 + ntpdate/ntpdate.c@1.47.1.1 +46 -16 [Bug 389] Fix from Remi Demis-Courmont, via Loic Minier (http://bugs.debian.org/293793 -ChangeSet@1.1251.15.9, 2005-03-02 15:50:06-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.15.9, 2005-03-02 15:50:06-05:00, stenn@whimsy.udel.edu Clock filter bugfix from Dave Mills - ntpd/ntp_proto.c@1.198, 2005-03-02 15:49:47-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntp_proto.c@1.198 +3 -3 Clock filter bugfix from Dave Mills -ChangeSet@1.1251.15.8, 2005-03-02 14:53:27-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.15.8, 2005-03-02 14:53:27-05:00, mayer@pogo.udel.edu Bug #392 fix group number - ntpd/ntpd.c@1.61.1.5, 2005-03-02 14:53:15-05:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntpd.c@1.61.1.5 +1 -1 Bug #392 fix group number -ChangeSet@1.1251.16.1, 2005-03-02 14:37:49-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.16.1, 2005-03-02 14:37:49-05:00, mayer@pogo.udel.edu Fix to ignore 0 or less readlengths after the first one - ntpd/ntp_io.c@1.169.1.5, 2005-03-02 14:37:18-05:00, mayer@pogo.udel.edu +50 -6 + ntpd/ntp_io.c@1.169.1.5 +50 -6 Fix to ignore 0 or less readlengths after the first one -ChangeSet@1.1251.15.6, 2005-03-01 22:32:42-05:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1251.15.6, 2005-03-01 22:32:42-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntpd.h@1.74, 2005-03-01 22:30:11-05:00, stenn@whimsy.udel.edu +1 -0 + include/ntpd.h@1.74 +1 -0 Changes from Dave Mills - ntpd/ntp_crypto.c@1.94, 2005-03-01 22:32:16-05:00, stenn@whimsy.udel.edu +2 -1 + ntpd/ntp_crypto.c@1.94 +2 -1 Changes from Dave Mills - ntpd/ntp_proto.c@1.197, 2005-03-01 22:32:16-05:00, stenn@whimsy.udel.edu +3 -1 + ntpd/ntp_proto.c@1.197 +3 -1 Changes from Dave Mills - ntpd/ntp_util.c@1.36, 2005-03-01 22:32:18-05:00, stenn@whimsy.udel.edu +7 -5 + ntpd/ntp_util.c@1.36 +7 -5 Changes from Dave Mills - ntpd/ntpd.c@1.61.1.4, 2005-03-01 22:32:15-05:00, stenn@whimsy.udel.edu +2 -1 + ntpd/ntpd.c@1.61.1.4 +2 -1 Changes from Dave Mills - ntpd/ntpsim.c@1.9, 2005-03-01 22:32:19-05:00, stenn@whimsy.udel.edu +1 -0 + ntpd/ntpsim.c@1.9 +1 -0 Changes from Dave Mills -ChangeSet@1.1251.15.5, 2005-02-28 20:17:40-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.15.5, 2005-02-28 20:17:40-05:00, mayer@pogo.udel.edu Fixed input_handler loops - ntpd/ntp_io.c@1.169.1.4, 2005-02-28 20:17:10-05:00, mayer@pogo.udel.edu +29 -38 + ntpd/ntp_io.c@1.169.1.4 +29 -38 Fixed input_handler loops -ChangeSet@1.1251.15.3, 2005-02-28 13:23:19-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.15.3, 2005-02-28 13:23:19-05:00, mayer@pogo.udel.edu fixes in input_handler - additional changes required - ntpd/ntp_io.c@1.169.1.2, 2005-02-28 13:22:50-05:00, mayer@pogo.udel.edu +16 -3 + ntpd/ntp_io.c@1.169.1.2 +16 -3 fixes in input_handler - additional changes required -ChangeSet@1.1251.15.2, 2005-02-28 13:21:47-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.15.2, 2005-02-28 13:21:47-05:00, mayer@pogo.udel.edu Bug #392 - using wrong group id for account - ntpd/ntpd.c@1.61.1.3, 2005-02-28 13:21:29-05:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntpd.c@1.61.1.3 +1 -1 Bug #392 - using wrong group id for account -ChangeSet@1.1251.13.3, 2005-02-28 12:52:33-05:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1251.13.3, 2005-02-28 12:52:33-05:00, stenn@whimsy.udel.edu Changes from Dave Mills - include/ntp.h@1.107, 2005-02-28 12:51:30-05:00, stenn@whimsy.udel.edu +1 -1 + include/ntp.h@1.107 +1 -1 Changes from Dave Mills - ntpd/ntp_config.c@1.121, 2005-02-28 12:51:04-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_config.c@1.121 +1 -1 Changes from Dave Mills - ntpd/ntp_io.c@1.167.1.1, 2005-02-28 12:51:05-05:00, stenn@whimsy.udel.edu +1 -8 + ntpd/ntp_io.c@1.167.1.1 +1 -8 Changes from Dave Mills - ntpd/ntp_proto.c@1.196, 2005-02-28 12:51:05-05:00, stenn@whimsy.udel.edu +18 -34 + ntpd/ntp_proto.c@1.196 +18 -34 Changes from Dave Mills - ntpd/refclock_acts.c@1.21.1.3, 2005-02-28 12:51:06-05:00, stenn@whimsy.udel.edu +218 -207 + ntpd/refclock_acts.c@1.21.1.3 +218 -207 Changes from Dave Mills -ChangeSet@1.1251.15.1, 2005-02-22 18:10:26-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.15.1, 2005-02-22 18:10:26-05:00, mayer@pogo.udel.edu Fix loop limits - ntpd/ntp_io.c@1.169.1.1, 2005-02-22 18:10:10-05:00, mayer@pogo.udel.edu +3 -3 + ntpd/ntp_io.c@1.169.1.1 +3 -3 Fix loop limits -ChangeSet@1.1251.14.1, 2005-02-21 00:34:25-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.14.1, 2005-02-21 00:34:25-05:00, mayer@tecotoo. ntp_io.c: Make MAXZEROREADS 1 - ntpd/ntp_io.c@1.168.1.1, 2005-02-21 00:33:05-05:00, mayer@tecotoo. +4 -4 + ntpd/ntp_io.c@1.168.1.1 +4 -4 Make MAXZEROREADS 1 -ChangeSet@1.1251.1.86, 2005-02-21 00:26:12-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.86, 2005-02-21 00:26:12-05:00, mayer@pogo.udel.edu Additional changes to input_handler() to correctly break in refclock read loop - ntpd/ntp_io.c@1.169, 2005-02-21 00:25:37-05:00, mayer@pogo.udel.edu +8 -7 + ntpd/ntp_io.c@1.169 +8 -7 Additional changes to input_handler() to correctly break in refclock read loop -ChangeSet@1.1251.13.2, 2005-02-18 23:00:34-05:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.13.2, 2005-02-18 23:00:34-05:00, stenn@whimsy.udel.edu changes from Dave Mills - libntp/clocktypes.c@1.17, 2005-02-18 22:55:49-05:00, stenn@whimsy.udel.edu +8 -8 + libntp/clocktypes.c@1.17 +8 -8 changes from Dave Mills - ntpd/ntp_control.c@1.76, 2005-02-18 22:55:58-05:00, stenn@whimsy.udel.edu +6 -6 + ntpd/ntp_control.c@1.76 +6 -6 changes from Dave Mills - ntpd/refclock_acts.c@1.21.1.2, 2005-02-18 22:55:59-05:00, stenn@whimsy.udel.edu +14 -32 + ntpd/refclock_acts.c@1.21.1.2 +14 -32 changes from Dave Mills - ntpd/refclock_conf.c@1.25, 2005-02-18 22:56:02-05:00, stenn@whimsy.udel.edu +4 -4 + ntpd/refclock_conf.c@1.25 +4 -4 changes from Dave Mills -ChangeSet@1.1251.13.1, 2005-02-16 00:37:44-05:00, stenn@whimsy.udel.edu +8 -0 +ChangeSet@1.1251.13.1, 2005-02-16 00:37:44-05:00, stenn@whimsy.udel.edu Updates from Dave Mills - include/ntp.h@1.106, 2005-02-16 00:37:11-05:00, stenn@whimsy.udel.edu +6 -3 + include/ntp.h@1.106 +6 -3 Updates from Dave Mills - include/ntp_config.h@1.32, 2005-02-16 00:37:12-05:00, stenn@whimsy.udel.edu +3 -1 + include/ntp_config.h@1.32 +3 -1 Updates from Dave Mills - ntpd/ntp_config.c@1.120, 2005-02-16 00:37:19-05:00, stenn@whimsy.udel.edu +9 -0 + ntpd/ntp_config.c@1.120 +9 -0 Updates from Dave Mills - ntpd/ntp_proto.c@1.195, 2005-02-16 00:37:20-05:00, stenn@whimsy.udel.edu +64 -59 + ntpd/ntp_proto.c@1.195 +64 -59 Updates from Dave Mills - ntpd/ntp_refclock.c@1.64, 2005-02-16 00:37:21-05:00, stenn@whimsy.udel.edu +2 -6 + ntpd/ntp_refclock.c@1.64 +2 -6 Updates from Dave Mills - ntpd/refclock_acts.c@1.21.1.1, 2005-02-16 00:37:21-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_acts.c@1.21.1.1 +1 -1 Updates from Dave Mills - ntpd/refclock_arbiter.c@1.10, 2005-02-16 00:37:24-05:00, stenn@whimsy.udel.edu +35 -26 + ntpd/refclock_arbiter.c@1.10 +35 -26 Updates from Dave Mills - ntpd/refclock_atom.c@1.52, 2005-02-16 00:37:21-05:00, stenn@whimsy.udel.edu +12 -23 + ntpd/refclock_atom.c@1.52 +12 -23 Updates from Dave Mills -ChangeSet@1.1251.1.84, 2005-02-15 22:56:40-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.84, 2005-02-15 22:56:40-05:00, mayer@tecotoo. Make MAXZEROREADS 1 so that the first zero-length read causes code to break and go to next socket - ntpd/ntp_io.c@1.168, 2005-02-15 22:54:30-05:00, mayer@tecotoo. +1 -1 + ntpd/ntp_io.c@1.168 +1 -1 Make MAXZEROREADS 1 so that the first zero-length read causes code to break and go to next socket -ChangeSet@1.1251.12.1, 2005-02-15 19:40:54-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.12.1, 2005-02-15 19:40:54-05:00, mayer@tecotoo. Refix SMAX to 256 and fix &C0/1 comment - per Greg Dowd's messages - ntpd/refclock_acts.c@1.22, 2005-02-15 19:40:21-05:00, mayer@tecotoo. +2 -2 + ntpd/refclock_acts.c@1.22 +2 -2 Refix SMAX to 256 and fix &C0/1 comment - per Greg Dowd's messages -ChangeSet@1.1251.1.82, 2005-02-15 19:31:10-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.1.82, 2005-02-15 19:31:10-05:00, stenn@whimsy.udel.edu Updates from Dave Mills - html/confopt.html@1.29, 2005-02-15 19:30:57-05:00, stenn@whimsy.udel.edu +3 -2 + html/confopt.html@1.29 +3 -2 Updates from Dave Mills - html/manyopt.html@1.10, 2005-02-15 19:30:55-05:00, stenn@whimsy.udel.edu +22 -17 + html/manyopt.html@1.10 +22 -17 Updates from Dave Mills - html/miscopt.html@1.30, 2005-02-15 19:30:56-05:00, stenn@whimsy.udel.edu +5 -8 + html/miscopt.html@1.30 +5 -8 Updates from Dave Mills -ChangeSet@1.1251.1.81, 2005-02-15 18:09:42-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.81, 2005-02-15 18:09:42-05:00, mayer@pogo.udel.edu Added while look to read the clock until error or number of consecutive 0 len reads exceeds MAXZEROREADS - ntpd/ntp_io.c@1.167, 2005-02-15 18:09:22-05:00, mayer@pogo.udel.edu +76 -52 + ntpd/ntp_io.c@1.167 +76 -52 Added while look to read the clock until error or number of consecutive 0 len reads exceeds MAXZEROREADS -ChangeSet@1.1251.1.80, 2005-02-15 00:18:50-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1251.1.80, 2005-02-15 00:18:50-05:00, mayer@tecotoo. Martin Burnicki's fixes to allow Windows to pass command line arguments to a system service - ntpd/ntpd.c@1.61.1.2, 2005-02-15 00:18:06-05:00, mayer@tecotoo. +3 -1 + ntpd/ntpd.c@1.61.1.2 +3 -1 Martin Burnicki's fixes to allow Windows to pass command line arguments to a system service - ports/winnt/ntpd/ntservice.c@1.4, 2005-02-15 00:18:08-05:00, mayer@tecotoo. +21 -64 + ports/winnt/ntpd/ntservice.c@1.4 +21 -64 Martin Burnicki's fixes to allow Windows to pass command line arguments to a system service -ChangeSet@1.1251.1.79, 2005-02-14 01:15:09-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.79, 2005-02-14 01:15:09-05:00, mayer@tecotoo. Bug #214: Return ISC_FALSE on not equal - ntpd/ntp_io.c@1.166, 2005-02-14 01:14:42-05:00, mayer@tecotoo. +2 -0 + ntpd/ntp_io.c@1.166 +2 -0 Bug #214: Return ISC_FALSE on not equal -ChangeSet@1.1251.1.78, 2005-02-14 00:38:25-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1251.1.78, 2005-02-14 00:38:25-05:00, mayer@tecotoo. Bug #214: Use strcasecmp and not stricmp - ntpd/ntp_io.c@1.165, 2005-02-14 00:36:35-05:00, mayer@tecotoo. +1 -1 + ntpd/ntp_io.c@1.165 +1 -1 Bug #214: Use strcasecmp and not stricmp - ports/winnt/include/config.h@1.36, 2005-02-14 00:36:37-05:00, mayer@tecotoo. +1 -0 + ports/winnt/include/config.h@1.36 +1 -0 Bug #214: Use strcasecmp and not stricmp -ChangeSet@1.1251.1.77, 2005-02-14 00:26:43-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1251.1.77, 2005-02-14 00:26:43-05:00, mayer@tecotoo. Bug #214: Allow option on command line to specify specific interface only to be used - ntpd/cmd_args.c@1.32, 2005-02-14 00:26:24-05:00, mayer@tecotoo. +6 -1 + ntpd/cmd_args.c@1.32 +6 -1 Bug #214: Allow option on command line to specify specific interface only to be used - ntpd/ntp_io.c@1.164, 2005-02-14 00:26:24-05:00, mayer@tecotoo. +22 -4 + ntpd/ntp_io.c@1.164 +22 -4 Bug #214: Allow option on command line to specify specific interface only to be used -ChangeSet@1.1251.1.76, 2005-02-14 00:24:26-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.76, 2005-02-14 00:24:26-05:00, mayer@tecotoo. add stricmp to mapped functions for win32 - ports/winnt/include/config.h@1.35, 2005-02-14 00:23:20-05:00, mayer@tecotoo. +1 -0 + ports/winnt/include/config.h@1.35 +1 -0 add stricmp to mapped functions -ChangeSet@1.1251.1.75, 2005-02-13 00:53:55-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.75, 2005-02-13 00:53:55-05:00, mayer@tecotoo. Clean up code and reorganize input_handler() - ntpd/ntp_io.c@1.163, 2005-02-13 00:53:15-05:00, mayer@tecotoo. +224 -251 + ntpd/ntp_io.c@1.163 +224 -251 Clean up code and reorganize input_handler() -ChangeSet@1.1251.1.74, 2005-02-12 13:29:10-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.74, 2005-02-12 13:29:10-05:00, mayer@pogo.udel.edu Change from &C1 to &C0 for the modem setup - ntpd/refclock_acts.c@1.21, 2005-02-12 13:28:52-05:00, mayer@pogo.udel.edu +2 -2 + ntpd/refclock_acts.c@1.21 +2 -2 Change from &C1 to &C0 for the modem setup -ChangeSet@1.1251.1.73, 2005-02-12 13:27:15-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.73, 2005-02-12 13:27:15-05:00, mayer@pogo.udel.edu Remove double loop and continue reading sockets rather than skipping out - ntpd/ntp_io.c@1.162, 2005-02-12 13:26:36-05:00, mayer@pogo.udel.edu +6 -4 + ntpd/ntp_io.c@1.162 +6 -4 Remove double loop and continue reading sockets rather than skipping out -ChangeSet@1.1251.1.72, 2005-02-10 23:28:14-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.72, 2005-02-10 23:28:14-05:00, mayer@tecotoo. Group ID was being obtained incorrectly. See message from Martin Pitt - Debian development - ntpd/ntpd.c@1.61.1.1, 2005-02-10 23:27:54-05:00, mayer@tecotoo. +1 -1 + ntpd/ntpd.c@1.61.1.1 +1 -1 Group ID was being obtained incorrectly. See message from Martin Pitt - Debian development -ChangeSet@1.1251.1.71, 2005-02-10 23:26:16-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.71, 2005-02-10 23:26:16-05:00, mayer@tecotoo. Fix input_handler code to not select again until other I/O read and free buffer if nothing read. (see Bug #341 and messages from cipo) - ntpd/ntp_io.c@1.161, 2005-02-10 23:25:01-05:00, mayer@tecotoo. +6 -6 + ntpd/ntp_io.c@1.161 +6 -6 Fix input_handler code to not select again until other I/O read and free buffer if nothing read. (see Bug #341 and messages from cipo) -ChangeSet@1.1251.1.70, 2005-02-09 00:59:19-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.1.70, 2005-02-09 00:59:19-05:00, stenn@whimsy.udel.edu Cleanup from Dave Mills - ntpd/ntp_config.c@1.119, 2005-02-09 00:59:00-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_config.c@1.119 +1 -1 Cleanup from Dave Mills - ntpd/ntp_proto.c@1.194, 2005-02-09 00:59:01-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.194 +1 -1 Cleanup from Dave Mills - ntpd/refclock_acts.c@1.20, 2005-02-09 00:59:02-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_acts.c@1.20 +1 -1 Cleanup from Dave Mills -ChangeSet@1.1268, 2005-02-06 01:41:55-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1268, 2005-02-06 01:41:55-05:00, stenn@pogo.udel.edu ntpdc lint - ntpdc/ntpdc.c@1.42, 2005-02-06 01:41:42-05:00, stenn@pogo.udel.edu +0 -8 + ntpdc/ntpdc.c@1.42 +0 -8 lint -ChangeSet@1.1267, 2005-02-06 01:31:47-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1267, 2005-02-06 01:31:47-05:00, stenn@pogo.udel.edu start hacking the ntpdc docs... - ntpdc/ntpdc-opts.def@1.2, 2005-02-06 01:31:39-05:00, stenn@pogo.udel.edu +2 -5 + ntpdc/ntpdc-opts.def@1.2 +2 -5 start hacking the ntpdc docs... -ChangeSet@1.1266, 2005-02-06 01:22:40-05:00, stenn@pogo.udel.edu +5 -0 +ChangeSet@1.1266, 2005-02-06 01:22:40-05:00, stenn@pogo.udel.edu Convert ntpdc to autogen; some cleanup in ntpq - BitKeeper/etc/ignore@1.38, 2005-02-06 01:19:27-05:00, stenn@pogo.udel.edu +5 -0 + BitKeeper/etc/ignore@1.38 +5 -0 added ntpdc-opts.c ntpdc-opts.h ntpdc-opts.menu ntpdc-opts.texi ntpdc.1 - ntpdc/Makefile.am@1.24, 2005-02-06 01:21:32-05:00, stenn@pogo.udel.edu +20 -4 + ntpdc/Makefile.am@1.24 +20 -4 Convert ntpdc to autogen; some cleanup in ntpq - ntpdc/ntpdc-opts.def@1.1, 2005-02-06 01:20:12-05:00, stenn@pogo.udel.edu +178 -0 + ntpdc/ntpdc-opts.def@1.1 +178 -0 - ntpdc/ntpdc-opts.def@1.0, 2005-02-06 01:20:12-05:00, stenn@pogo.udel.edu +0 -0 + ntpdc/ntpdc-opts.def@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/ntpdc/ntpdc-opts.def - ntpdc/ntpdc.c@1.41, 2005-02-06 01:21:32-05:00, stenn@pogo.udel.edu +54 -0 + ntpdc/ntpdc.c@1.41 +54 -0 Convert ntpdc to autogen; some cleanup in ntpq - ntpq/Makefile.am@1.17, 2005-02-06 01:21:36-05:00, stenn@pogo.udel.edu +1 -1 + ntpq/Makefile.am@1.17 +1 -1 Convert ntpdc to autogen; some cleanup in ntpq -ChangeSet@1.1251.1.69, 2005-02-05 22:47:46-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.69, 2005-02-05 22:47:46-05:00, stenn@whimsy.udel.edu [Bug 388] Update URLs - html/drivers/driver43.html@1.9, 2005-02-05 22:47:32-05:00, stenn@whimsy.udel.edu +1 -1 + html/drivers/driver43.html@1.9 +1 -1 [Bug 388] Update URLs -ChangeSet@1.1251.1.68, 2005-02-05 22:44:47-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.68, 2005-02-05 22:44:47-05:00, stenn@whimsy.udel.edu Poll updates from Dave Mills. - ntpd/ntp_proto.c@1.193, 2005-02-05 22:44:32-05:00, stenn@whimsy.udel.edu +11 -8 + ntpd/ntp_proto.c@1.193 +11 -8 Poll updates from Dave Mills. -ChangeSet@1.1251.1.67, 2005-02-03 01:18:23-05:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1251.1.67, 2005-02-03 01:18:23-05:00, stenn@whimsy.udel.edu ntp_config.h, ntp.h, ntp_proto.c, ntp_config.c: Fixes from Dave Mills. In particular, Dave writes: @@ -20831,2812 +201598,2811 @@ ChangeSet@1.1251.1.67, 2005-02-03 01:18:23-05:00, stenn@whimsy.udel.edu +4 -0 threshold, normally 1. Set N to 16 and the clock will be set upon first receiving a response from any server. Y'know, like SNTP. - include/ntp.h@1.105, 2005-02-03 01:16:38-05:00, stenn@whimsy.udel.edu +2 -1 + include/ntp.h@1.105 +2 -1 Fixes from Dave Mills - include/ntp_config.h@1.31, 2005-02-03 01:16:38-05:00, stenn@whimsy.udel.edu +1 -0 + include/ntp_config.h@1.31 +1 -0 Fixes from Dave Mills - ntpd/ntp_config.c@1.118, 2005-02-03 01:16:26-05:00, stenn@whimsy.udel.edu +5 -0 + ntpd/ntp_config.c@1.118 +5 -0 Fixes from Dave Mills - ntpd/ntp_proto.c@1.192, 2005-02-03 01:16:28-05:00, stenn@whimsy.udel.edu +85 -67 + ntpd/ntp_proto.c@1.192 +85 -67 Fixes from Dave Mills -ChangeSet@1.1251.1.66, 2005-01-23 18:54:35-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.66, 2005-01-23 18:54:35-05:00, mayer@tecotoo. Need reference to address for scope - ntpd/ntp_io.c@1.160, 2005-01-23 18:54:04-05:00, mayer@tecotoo. +2 -2 + ntpd/ntp_io.c@1.160 +2 -2 Need reference to address for scope -ChangeSet@1.1251.1.65, 2005-01-23 14:37:56-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.65, 2005-01-23 14:37:56-05:00, mayer@tecotoo. Wasn't setting scopeid for IPv6 addresses - ntpd/ntp_io.c@1.159, 2005-01-23 14:36:52-05:00, mayer@tecotoo. +7 -9 + ntpd/ntp_io.c@1.159 +7 -9 Wasn't setting scopeid for IPv6 addresses -ChangeSet@1.1251.1.64, 2005-01-18 00:48:54-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1251.1.64, 2005-01-18 00:48:54-05:00, mayer@tecotoo. Fix missing parenthesis and remove duplicate CONFIG_CDELAY - include/ntp_config.h@1.30, 2005-01-18 00:47:56-05:00, mayer@tecotoo. +1 -2 + include/ntp_config.h@1.30 +1 -2 Remove duplicate CONFIG_CDELAY - ports/winnt/include/isc/ipv6.h@1.6, 2005-01-18 00:47:10-05:00, mayer@tecotoo. +1 -1 + ports/winnt/include/isc/ipv6.h@1.6 +1 -1 Missing parenthesis in Macro -ChangeSet@1.1251.11.1, 2005-01-16 19:29:57-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.11.1, 2005-01-16 19:29:57-05:00, mayer@tecotoo. Added debug code findinterface to see if the connect() fails - ntpd/ntp_io.c@1.158, 2005-01-16 19:28:39-05:00, mayer@tecotoo. +6 -0 + ntpd/ntp_io.c@1.158 +6 -0 -ChangeSet@1.1251.1.62, 2005-01-11 16:15:03-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.62, 2005-01-11 16:15:03-05:00, mayer@pogo.udel.edu Added isc/region.h - include/isc/Makefile.am@1.4, 2005-01-11 16:14:48-05:00, mayer@pogo.udel.edu +1 -0 + include/isc/Makefile.am@1.4 +1 -0 Added isc/region.h -ChangeSet@1.1251.1.61, 2005-01-11 16:02:59-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.61, 2005-01-11 16:02:59-05:00, mayer@pogo.udel.edu Added isc/buffer.h and isc/netscope.h - include/isc/Makefile.am@1.3, 2005-01-11 16:00:10-05:00, mayer@pogo.udel.edu +2 -0 + include/isc/Makefile.am@1.3 +2 -0 Added isc/buffer.h and isc/netscope.h -ChangeSet@1.1261, 2005-01-10 04:19:21-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1261, 2005-01-10 04:19:21-05:00, stenn@pogo.udel.edu fixes - configure.ac@1.364, 2005-01-10 04:19:11-05:00, stenn@pogo.udel.edu +7 -0 + configure.ac@1.364 +7 -0 disable shared libraries on OSF4.0 - m4/libopts.m4@1.3, 2005-01-10 04:18:45-05:00, stenn@pogo.udel.edu +2 -5 + m4/libopts.m4@1.3 +2 -5 fix from bkorb -ChangeSet@1.1260, 2005-01-09 06:23:02-05:00, stenn@pogo.udel.edu +27 -0 +ChangeSet@1.1260, 2005-01-09 06:23:02-05:00, stenn@pogo.udel.edu autogen-5.6.5 - libopts/Makefile.am@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/Makefile.am@1.2 +1 -1 autogen-5.6.5 - libopts/autoopts.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +36 -20 + libopts/autoopts.c@1.2 +36 -20 autogen-5.6.5 - libopts/autoopts.h@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/autoopts.h@1.2 +1 -1 autogen-5.6.5 - libopts/boolean.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/boolean.c@1.2 +1 -1 autogen-5.6.5 - libopts/compat/compat.h@1.2, 2005-01-09 06:19:27-05:00, stenn@pogo.udel.edu +1 -1 + libopts/compat/compat.h@1.2 +1 -1 autogen-5.6.5 - libopts/compat/pathfind.c@1.2, 2005-01-09 06:19:27-05:00, stenn@pogo.udel.edu +2 -2 + libopts/compat/pathfind.c@1.2 +2 -2 autogen-5.6.5 - libopts/enumeration.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/enumeration.c@1.2 +1 -1 autogen-5.6.5 - libopts/environment.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/environment.c@1.2 +1 -1 autogen-5.6.5 - libopts/genshell.c@1.2, 2005-01-09 06:22:16-05:00, stenn@pogo.udel.edu +1 -1 + libopts/genshell.c@1.2 +1 -1 autogen-5.6.5 - libopts/genshell.h@1.2, 2005-01-09 06:22:16-05:00, stenn@pogo.udel.edu +1 -1 + libopts/genshell.h@1.2 +1 -1 autogen-5.6.5 - libopts/libopts.m4@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +2 -29 + libopts/libopts.m4@1.2 +2 -29 autogen-5.6.5 - libopts/load.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +2 -2 + libopts/load.c@1.2 +2 -2 autogen-5.6.5 - libopts/makeshell.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/makeshell.c@1.2 +1 -1 autogen-5.6.5 - libopts/numeric.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/numeric.c@1.2 +1 -1 autogen-5.6.5 - libopts/options.h@1.2, 2005-01-09 06:22:17-05:00, stenn@pogo.udel.edu +3 -3 + libopts/options.h@1.2 +3 -3 autogen-5.6.5 - libopts/pgusage.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/pgusage.c@1.2 +1 -1 autogen-5.6.5 - libopts/putshell.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/putshell.c@1.2 +1 -1 autogen-5.6.5 - libopts/restore.c@1.2, 2005-01-09 06:18:14-05:00, stenn@pogo.udel.edu +1 -1 + libopts/restore.c@1.2 +1 -1 autogen-5.6.5 - libopts/save.c@1.2, 2005-01-09 06:18:15-05:00, stenn@pogo.udel.edu +4 -3 + libopts/save.c@1.2 +4 -3 autogen-5.6.5 - libopts/sort.c@1.2, 2005-01-09 06:18:15-05:00, stenn@pogo.udel.edu +1 -1 + libopts/sort.c@1.2 +1 -1 autogen-5.6.5 - libopts/stack.c@1.2, 2005-01-09 06:18:15-05:00, stenn@pogo.udel.edu +1 -7 + libopts/stack.c@1.2 +1 -7 autogen-5.6.5 - libopts/streqv.h@1.2, 2005-01-09 06:18:15-05:00, stenn@pogo.udel.edu +1 -1 + libopts/streqv.h@1.2 +1 -1 autogen-5.6.5 - libopts/streqvcmp.c@1.2, 2005-01-09 06:18:15-05:00, stenn@pogo.udel.edu +1 -1 + libopts/streqvcmp.c@1.2 +1 -1 autogen-5.6.5 - libopts/usage-txt.h@1.2, 2005-01-09 06:22:17-05:00, stenn@pogo.udel.edu +1 -1 + libopts/usage-txt.h@1.2 +1 -1 autogen-5.6.5 - libopts/usage.c@1.2, 2005-01-09 06:18:15-05:00, stenn@pogo.udel.edu +1 -1 + libopts/usage.c@1.2 +1 -1 autogen-5.6.5 - libopts/version.c@1.2, 2005-01-09 06:18:15-05:00, stenn@pogo.udel.edu +1 -1 + libopts/version.c@1.2 +1 -1 autogen-5.6.5 - m4/libopts.m4@1.2, 2005-01-09 06:18:07-05:00, stenn@pogo.udel.edu +2 -29 + m4/libopts.m4@1.2 +2 -29 autogen-5.6.5 -ChangeSet@1.1251.7.31, 2005-01-09 02:05:42-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.31, 2005-01-09 02:05:42-05:00, stenn@whimsy.udel.edu Happy New Year - html/copyright.html@1.29, 2005-01-09 02:05:28-05:00, stenn@whimsy.udel.edu +2 -2 + html/copyright.html@1.29 +2 -2 Happy New Year -ChangeSet@1.1251.8.12, 2005-01-08 02:23:27-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.12, 2005-01-08 02:23:27-05:00, stenn@whimsy.udel.edu Show more stability data. - ntpd/ntp_util.c@1.35, 2005-01-08 02:23:13-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_util.c@1.35 +1 -1 Show more stability data. -ChangeSet@1.1251.8.11, 2005-01-08 01:13:32-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.11, 2005-01-08 01:13:32-05:00, stenn@whimsy.udel.edu fencepost error - libntp/systime.c@1.32, 2005-01-08 01:13:15-05:00, stenn@whimsy.udel.edu +1 -1 + libntp/systime.c@1.32 +1 -1 fencepost error -ChangeSet@1.1259, 2005-01-05 16:47:10-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1259, 2005-01-05 16:47:10-05:00, stenn@pogo.udel.edu cleanup - configure.ac@1.363, 2005-01-05 16:46:01-05:00, stenn@pogo.udel.edu +44 -33 + configure.ac@1.363 +44 -33 Reorder AC_ARG_WITH to avoid an apparent quoting/redirect problem - ntpq/Makefile.am@1.16, 2005-01-05 16:45:18-05:00, stenn@pogo.udel.edu +1 -1 + ntpq/Makefile.am@1.16 +1 -1 Library reorder -ChangeSet@1.1251.8.10, 2005-01-05 01:16:04-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.10, 2005-01-05 01:16:04-05:00, stenn@whimsy.udel.edu Don't log 'refclockio structure not found'. From Dave Mills - ntpd/ntp_io.c@1.148.1.1, 2005-01-05 01:15:49-05:00, stenn@whimsy.udel.edu +0 -7 + ntpd/ntp_io.c@1.148.1.1 +0 -7 Don't log 'refclockio structure not found'. From Dave Mills -ChangeSet@1.1251.1.58, 2005-01-05 00:12:51-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.58, 2005-01-05 00:12:51-05:00, mayer@tecotoo. Rename index to idx - ntpd/ntp_io.c@1.156, 2005-01-05 00:12:07-05:00, mayer@tecotoo. +4 -4 + ntpd/ntp_io.c@1.156 +4 -4 Rename index to idx -ChangeSet@1.1251.1.57, 2005-01-04 21:38:58-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.57, 2005-01-04 21:38:58-05:00, mayer@tecotoo. Remove unnecessary includes - ntpd/ntp_io.c@1.155, 2005-01-04 21:36:25-05:00, mayer@tecotoo. +7 -17 + ntpd/ntp_io.c@1.155 +7 -17 Remove unnecessary includes -ChangeSet@1.1251.1.56, 2005-01-02 21:13:48-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.56, 2005-01-02 21:13:48-05:00, mayer@tecotoo. Remove unnecessary include ntp_if.h - ntpd/ntp_io.c@1.154, 2005-01-02 21:13:21-05:00, mayer@tecotoo. +0 -1 + ntpd/ntp_io.c@1.154 +0 -1 Remove unnecessary include ntp_if.h -ChangeSet@1.1251.1.55, 2005-01-02 18:28:21-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.55, 2005-01-02 18:28:21-05:00, mayer@tecotoo. remove include net/if.h. Some O/S's don't prevent double inclusions. It is already included in isc/net.h - libisc/interfaceiter.c@1.15, 2005-01-02 18:27:51-05:00, mayer@tecotoo. +0 -1 + libisc/interfaceiter.c@1.15 +0 -1 remove include net/if.h. Some O/S's don't prevent double inclusions. It is already included in isc/net.h -ChangeSet@1.1251.1.54, 2005-01-01 22:14:34-05:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1251.1.54, 2005-01-01 22:14:34-05:00, mayer@tecotoo. Remove reference to interface index. Remove isc_log_write references - libisc/ifiter_getifaddrs.c@1.4, 2005-01-01 22:14:04-05:00, mayer@tecotoo. +0 -1 + libisc/ifiter_getifaddrs.c@1.4 +0 -1 Remove reference to interface index. Remove isc_log_write references - libisc/ifiter_ioctl.c@1.21, 2005-01-01 22:14:04-05:00, mayer@tecotoo. +4 -20 + libisc/ifiter_ioctl.c@1.21 +4 -20 Remove reference to interface index. Remove isc_log_write references - libisc/ifiter_sysctl.c@1.11, 2005-01-01 22:14:03-05:00, mayer@tecotoo. +0 -1 + libisc/ifiter_sysctl.c@1.11 +0 -1 Remove reference to interface index. Remove isc_log_write references -ChangeSet@1.1251.1.53, 2005-01-01 18:10:09-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.53, 2005-01-01 18:10:09-05:00, mayer@tecotoo. Updated msg macros - include/isc/msgs.h@1.3, 2005-01-01 18:09:48-05:00, mayer@tecotoo. +12 -10 + include/isc/msgs.h@1.3 +12 -10 Updated msg macros -ChangeSet@1.1251.8.9, 2005-01-01 06:17:25-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.8.9, 2005-01-01 06:17:25-05:00, stenn@pogo.udel.edu Library reorder - ntpd/Makefile.am@1.41, 2005-01-01 06:17:15-05:00, stenn@pogo.udel.edu +1 -2 + ntpd/Makefile.am@1.41 +1 -2 Library reorder -ChangeSet@1.1251.10.2, 2005-01-01 00:49:42-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.10.2, 2005-01-01 00:49:42-05:00, mayer@pogo.udel.edu Use macros in buffer routines - include/isc/buffer.h@1.2, 2005-01-01 00:49:28-05:00, mayer@pogo.udel.edu +1 -1 + include/isc/buffer.h@1.2 +1 -1 Use macros in buffer routines -ChangeSet@1.1251.10.1, 2005-01-01 00:48:50-05:00, mayer@pogo.udel.edu +4 -0 +ChangeSet@1.1251.10.1, 2005-01-01 00:48:50-05:00, mayer@pogo.udel.edu First upgrade of interfaceiter routines - libisc/ifiter_getifaddrs.c@1.1.1.1, 2005-01-01 00:48:14-05:00, mayer@pogo.udel.edu +15 -1 + libisc/ifiter_getifaddrs.c@1.1.1.1 +15 -1 First upgrade of interfaceiter routines - libisc/ifiter_ioctl.c@1.18.1.1, 2005-01-01 00:48:13-05:00, mayer@pogo.udel.edu +393 -157 + libisc/ifiter_ioctl.c@1.18.1.1 +393 -157 First upgrade of interfaceiter routines - libisc/ifiter_sysctl.c@1.8.1.1, 2005-01-01 00:48:13-05:00, mayer@pogo.udel.edu +24 -16 + libisc/ifiter_sysctl.c@1.8.1.1 +24 -16 First upgrade of interfaceiter routines - libisc/interfaceiter.c@1.12.1.1, 2005-01-01 00:48:13-05:00, mayer@pogo.udel.edu +79 -73 + libisc/interfaceiter.c@1.12.1.1 +79 -73 First upgrade of interfaceiter routines -ChangeSet@1.1251.9.1, 2004-12-30 22:52:08-05:00, mayer@tecotoo. +4 -0 +ChangeSet@1.1251.9.1, 2004-12-30 22:52:08-05:00, mayer@tecotoo. First upgrade of interfaceiter routines - libisc/ifiter_getifaddrs.c@1.2, 2004-12-30 22:51:28-05:00, mayer@tecotoo. +15 -1 + libisc/ifiter_getifaddrs.c@1.2 +15 -1 First upgrade of interfaceiter routines - libisc/ifiter_ioctl.c@1.19, 2004-12-30 22:51:27-05:00, mayer@tecotoo. +393 -157 + libisc/ifiter_ioctl.c@1.19 +393 -157 First upgrade of interfaceiter routines - libisc/ifiter_sysctl.c@1.9, 2004-12-30 22:51:27-05:00, mayer@tecotoo. +24 -16 + libisc/ifiter_sysctl.c@1.9 +24 -16 First upgrade of interfaceiter routines - libisc/interfaceiter.c@1.13, 2004-12-30 22:51:26-05:00, mayer@tecotoo. +79 -73 + libisc/interfaceiter.c@1.13 +79 -73 First upgrade of interfaceiter routines -ChangeSet@1.1256, 2004-12-30 20:06:10-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1256, 2004-12-30 20:06:10-05:00, stenn@pogo.udel.edu Cleanup - Makefile.am@1.50, 2004-12-30 20:05:27-05:00, stenn@pogo.udel.edu +3 -3 + Makefile.am@1.50 +3 -3 Fix typos - ntpq/Makefile.am@1.15, 2004-12-30 20:05:57-05:00, stenn@pogo.udel.edu +1 -1 + ntpq/Makefile.am@1.15 +1 -1 Missed AM_CPPFLAGS in the merge -ChangeSet@1.1255, 2004-12-30 19:47:48-05:00, stenn@pogo.udel.edu +4 -0 +ChangeSet@1.1255, 2004-12-30 19:47:48-05:00, stenn@pogo.udel.edu cleanup - BitKeeper/deleted/.del-Makefile.in~783ae447256d94af@1.2, 2004-12-30 19:45:00-05:00, stenn@pogo.udel.edu +0 -0 + BitKeeper/deleted/.del-Makefile.in~783ae447256d94af@1.2 +0 -0 Delete: libopts/Makefile.in - BitKeeper/etc/ignore@1.37, 2004-12-30 19:46:58-05:00, stenn@pogo.udel.edu +1 -0 + BitKeeper/etc/ignore@1.37 +1 -0 added ntpq/ntpq.1 - BitKeeper/etc/ignore@1.36, 2004-12-30 19:46:28-05:00, stenn@pogo.udel.edu +5 -0 + BitKeeper/etc/ignore@1.36 +5 -0 added ltmain.sh ntpq/ntpq-opts.c ntpq/ntpq-opts.h ntpq/ntpq-opts.menu ntpq/ntpq-opts.texi - configure.ac@1.362, 2004-12-30 19:44:17-05:00, stenn@pogo.udel.edu +0 -1 + configure.ac@1.362 +0 -1 Lint removal - ntpq/Makefile.am@1.14, 2004-12-30 19:44:01-05:00, stenn@pogo.udel.edu +0 -1 + ntpq/Makefile.am@1.14 +0 -1 Cleanup -ChangeSet@1.1253, 2004-12-30 17:53:32-05:00, stenn@pogo.udel.edu +39 -0 +ChangeSet@1.1253, 2004-12-30 17:53:32-05:00, stenn@pogo.udel.edu AutoOpts conversion - starting with ntpq - Makefile.am@1.49, 2004-12-30 17:50:45-05:00, stenn@pogo.udel.edu +8 -1 + Makefile.am@1.49 +8 -1 AutoOpts conversion - libopts/COPYING.lgpl@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +504 -0 + libopts/COPYING.lgpl@1.1 +504 -0 - libopts/COPYING.lgpl@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/COPYING.lgpl@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/COPYING.lgpl - libopts/COPYING.mbsd@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +26 -0 + libopts/COPYING.mbsd@1.1 +26 -0 - libopts/COPYING.mbsd@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/COPYING.mbsd@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/COPYING.mbsd - libopts/MakeDefs.inc@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +5 -0 + libopts/MakeDefs.inc@1.1 +5 -0 - libopts/MakeDefs.inc@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/MakeDefs.inc@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/MakeDefs.inc - libopts/Makefile.am@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +11 -0 + libopts/Makefile.am@1.1 +11 -0 - libopts/Makefile.am@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/Makefile.am@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/Makefile.am - libopts/Makefile.in@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +496 -0 + libopts/Makefile.in@1.1 +496 -0 - libopts/Makefile.in@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/Makefile.in@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/Makefile.in - libopts/README@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +89 -0 + libopts/README@1.1 +89 -0 - libopts/README@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/README@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/README - libopts/autoopts.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +1136 -0 + libopts/autoopts.c@1.1 +1136 -0 - libopts/autoopts.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/autoopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/autoopts.c - libopts/autoopts.h@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +322 -0 + libopts/autoopts.h@1.1 +322 -0 - libopts/autoopts.h@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/autoopts.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/autoopts.h - libopts/boolean.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +104 -0 + libopts/boolean.c@1.1 +104 -0 - libopts/boolean.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/boolean.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/boolean.c - libopts/compat/compat.h@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +265 -0 + libopts/compat/compat.h@1.1 +265 -0 - libopts/compat/compat.h@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/compat/compat.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/compat/compat.h - libopts/compat/pathfind.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +278 -0 + libopts/compat/pathfind.c@1.1 +278 -0 - libopts/compat/pathfind.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/compat/pathfind.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/compat/pathfind.c - libopts/enumeration.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +448 -0 + libopts/enumeration.c@1.1 +448 -0 - libopts/enumeration.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/enumeration.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/enumeration.c - libopts/environment.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +264 -0 + libopts/environment.c@1.1 +264 -0 - libopts/environment.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/environment.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/environment.c - libopts/genshell.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +295 -0 + libopts/genshell.c@1.1 +295 -0 - libopts/genshell.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/genshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/genshell.c - libopts/genshell.h@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +122 -0 + libopts/genshell.h@1.1 +122 -0 - libopts/genshell.h@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/genshell.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/genshell.h - libopts/libopts.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +25 -0 + libopts/libopts.c@1.1 +25 -0 - libopts/libopts.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts.c - libopts/libopts.m4@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +395 -0 + libopts/libopts.m4@1.1 +395 -0 - libopts/libopts.m4@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/libopts.m4@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/libopts.m4 - libopts/load.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +553 -0 + libopts/load.c@1.1 +553 -0 - libopts/load.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/load.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/load.c - libopts/makeshell.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +1096 -0 + libopts/makeshell.c@1.1 +1096 -0 - libopts/makeshell.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/makeshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/makeshell.c - libopts/numeric.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +96 -0 + libopts/numeric.c@1.1 +96 -0 - libopts/numeric.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/numeric.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/numeric.c - libopts/options.h@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +436 -0 + libopts/options.h@1.1 +436 -0 - libopts/options.h@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/options.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/options.h - libopts/pgusage.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +156 -0 + libopts/pgusage.c@1.1 +156 -0 - libopts/pgusage.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/pgusage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/pgusage.c - libopts/putshell.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +326 -0 + libopts/putshell.c@1.1 +326 -0 - libopts/putshell.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/putshell.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/putshell.c - libopts/restore.c@1.1, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +173 -0 + libopts/restore.c@1.1 +173 -0 - libopts/restore.c@1.0, 2004-12-30 17:52:50-05:00, stenn@pogo.udel.edu +0 -0 + libopts/restore.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/restore.c - libopts/save.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +478 -0 + libopts/save.c@1.1 +478 -0 - libopts/save.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/save.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/save.c - libopts/sort.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +357 -0 + libopts/sort.c@1.1 +357 -0 - libopts/sort.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/sort.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/sort.c - libopts/stack.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +238 -0 + libopts/stack.c@1.1 +238 -0 - libopts/stack.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/stack.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/stack.c - libopts/streqv.h@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +115 -0 + libopts/streqv.h@1.1 +115 -0 - libopts/streqv.h@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/streqv.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/streqv.h - libopts/streqvcmp.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +196 -0 + libopts/streqvcmp.c@1.1 +196 -0 - libopts/streqvcmp.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/streqvcmp.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/streqvcmp.c - libopts/tokenize.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +313 -0 + libopts/tokenize.c@1.1 +313 -0 - libopts/tokenize.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/tokenize.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/tokenize.c - libopts/tokenize.h@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +40 -0 + libopts/tokenize.h@1.1 +40 -0 - libopts/tokenize.h@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/tokenize.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/tokenize.h - libopts/usage-txt.h@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +503 -0 + libopts/usage-txt.h@1.1 +503 -0 - libopts/usage-txt.h@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/usage-txt.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/usage-txt.h - libopts/usage.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +646 -0 + libopts/usage.c@1.1 +646 -0 - libopts/usage.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/usage.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/usage.c - libopts/version.c@1.1, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +176 -0 + libopts/version.c@1.1 +176 -0 - libopts/version.c@1.0, 2004-12-30 17:52:51-05:00, stenn@pogo.udel.edu +0 -0 + libopts/version.c@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/libopts/version.c - m4/libopts.m4@1.1, 2004-12-30 17:51:53-05:00, stenn@pogo.udel.edu +395 -0 + m4/libopts.m4@1.1 +395 -0 - m4/libopts.m4@1.0, 2004-12-30 17:51:53-05:00, stenn@pogo.udel.edu +0 -0 + m4/libopts.m4@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/m4/libopts.m4 - ntpq/Makefile.am@1.11.1.1, 2004-12-30 17:51:34-05:00, stenn@pogo.udel.edu +18 -4 + ntpq/Makefile.am@1.11.1.1 +18 -4 AutoOpts conversion - ntpq/ntpq-opts.def@1.1, 2004-12-30 17:51:53-05:00, stenn@pogo.udel.edu +156 -0 + ntpq/ntpq-opts.def@1.1 +156 -0 - ntpq/ntpq-opts.def@1.0, 2004-12-30 17:51:53-05:00, stenn@pogo.udel.edu +0 -0 + ntpq/ntpq-opts.def@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev-ag/ntpq/ntpq-opts.def - ntpq/ntpq.c@1.49.1.1, 2004-12-30 17:51:34-05:00, stenn@pogo.udel.edu +48 -8 + ntpq/ntpq.c@1.49.1.1 +48 -8 AutoOpts conversion -ChangeSet@1.1251.8.8, 2004-12-28 00:46:27-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.8.8, 2004-12-28 00:46:27-05:00, stenn@whimsy.udel.edu cleanup from Dave Mills - ntpd/refclock_acts.c@1.19, 2004-12-28 00:41:00-05:00, stenn@whimsy.udel.edu +3 -1 + ntpd/refclock_acts.c@1.19 +3 -1 file descriptor close cleanup from Dave Mills - ntpd/refclock_atom.c@1.51, 2004-12-28 00:45:10-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/refclock_atom.c@1.51 +2 -2 corner case cleanup from Dave Mills - ntpd/refclock_wwv.c@1.53, 2004-12-28 00:42:08-05:00, stenn@whimsy.udel.edu +9 -25 + ntpd/refclock_wwv.c@1.53 +9 -25 wwv cleanup from Dave Mills -ChangeSet@1.1251.8.7, 2004-12-27 06:15:13-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.7, 2004-12-27 06:15:13-05:00, stenn@whimsy.udel.edu Added ISC_PLATFORM_{NEEDPORTT,FIXIN6ISADDR} for Danny - configure.ac@1.359.1.7, 2004-12-27 06:15:00-05:00, stenn@whimsy.udel.edu +36 -2 + configure.ac@1.359.1.7 +36 -2 Added ISC_PLATFORM_{NEEDPORTT,FIXIN6ISADDR} for Danny -ChangeSet@1.1251.1.49, 2004-12-24 18:25:12-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1251.1.49, 2004-12-24 18:25:12-05:00, mayer@tecotoo. IPv6 changes - libisc/netaddr.c@1.2, 2004-12-24 18:25:00-05:00, mayer@tecotoo. +2 -0 + libisc/netaddr.c@1.2 +2 -0 IPv6 changes - libisc/sockaddr.c@1.2, 2004-12-24 18:25:01-05:00, mayer@tecotoo. +2 -0 + libisc/sockaddr.c@1.2 +2 -0 IPv6 changes -ChangeSet@1.1251.1.48, 2004-12-24 18:21:09-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.48, 2004-12-24 18:21:09-05:00, mayer@tecotoo. IPv6 changes - libisc/interfaceiter.c@1.12, 2004-12-24 18:20:51-05:00, mayer@tecotoo. +2 -0 + libisc/interfaceiter.c@1.12 +2 -0 IPv6 changes -ChangeSet@1.1251.1.47, 2004-12-24 18:16:16-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.47, 2004-12-24 18:16:16-05:00, mayer@tecotoo. IPv6 changes again - include/isc/ipv6.h@1.6, 2004-12-24 18:15:54-05:00, mayer@tecotoo. +2 -2 + include/isc/ipv6.h@1.6 +2 -2 IPv6 changes again -ChangeSet@1.1251.1.46, 2004-12-24 18:10:50-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.46, 2004-12-24 18:10:50-05:00, mayer@tecotoo. IPv6 changes - include/isc/ipv6.h@1.5, 2004-12-24 18:10:22-05:00, mayer@tecotoo. +12 -12 + include/isc/ipv6.h@1.5 +12 -12 IPv6 changes -ChangeSet@1.1251.1.45, 2004-12-23 22:59:14-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.45, 2004-12-23 22:59:14-05:00, mayer@tecotoo. Alternate method of getting interface addresses - libisc/ifiter_getifaddrs.c@1.1, 2004-12-23 22:58:38-05:00, mayer@tecotoo. +178 -0 + libisc/ifiter_getifaddrs.c@1.1 +178 -0 Alternate method of getting interface addresses - libisc/ifiter_getifaddrs.c@1.0, 2004-12-23 22:58:38-05:00, mayer@tecotoo. +0 -0 + libisc/ifiter_getifaddrs.c@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/libisc/ifiter_getifaddrs.c -ChangeSet@1.1251.1.44, 2004-12-23 22:41:22-05:00, mayer@tecotoo. +4 -0 +ChangeSet@1.1251.1.44, 2004-12-23 22:41:22-05:00, mayer@tecotoo. Added new files to build and moved some macros - include/ntp_machine.h@1.18, 2004-12-23 22:40:38-05:00, mayer@tecotoo. +0 -2 + include/ntp_machine.h@1.18 +0 -2 Moved function defines for Win32 from ntp_machine.h to winnt/config.h - libntp/Makefile.am@1.31, 2004-12-23 22:38:13-05:00, mayer@tecotoo. +2 -1 + libntp/Makefile.am@1.31 +2 -1 Added new files to build - ports/winnt/include/config.h@1.34, 2004-12-23 22:40:38-05:00, mayer@tecotoo. +8 -2 + ports/winnt/include/config.h@1.34 +8 -2 Moved function defines for Win32 from ntp_machine.h to winnt/config.h - ports/winnt/libntp/libntp.dsp@1.24, 2004-12-23 22:38:34-05:00, mayer@tecotoo. +20 -0 + ports/winnt/libntp/libntp.dsp@1.24 +20 -0 Added new files to build -ChangeSet@1.1251.1.43, 2004-12-23 15:24:48-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1251.1.43, 2004-12-23 15:24:48-05:00, mayer@pogo.udel.edu Miscellaneous compiler errors from port of BIND 9 code - include/isc/net.h@1.6, 2004-12-23 15:23:28-05:00, mayer@pogo.udel.edu +2 -3 + include/isc/net.h@1.6 +2 -3 missing #endifs - libisc/net.c@1.5, 2004-12-23 15:24:12-05:00, mayer@pogo.udel.edu +4 -16 + libisc/net.c@1.5 +4 -16 Don't use the catalog like BIND 9 -ChangeSet@1.1251.1.41, 2004-12-23 00:16:06-05:00, mayer@tecotoo. +14 -0 +ChangeSet@1.1251.1.41, 2004-12-23 00:16:06-05:00, mayer@tecotoo. ports from BIND 9.3.0 and reintegrated into ntp libisc xode - include/isc/buffer.h@1.1, 2004-12-22 23:55:44-05:00, mayer@tecotoo. +800 -0 + include/isc/buffer.h@1.1 +800 -0 isc_buffer header file - include/isc/buffer.h@1.0, 2004-12-22 23:55:44-05:00, mayer@tecotoo. +0 -0 + include/isc/buffer.h@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/include/isc/buffer.h - include/isc/net.h@1.5, 2004-12-23 00:15:11-05:00, mayer@tecotoo. +56 -10 + include/isc/net.h@1.5 +56 -10 ports from BIND 9.3.0 and reintegrated into ntp libisc code - include/isc/netaddr.h@1.4, 2004-12-23 00:15:11-05:00, mayer@tecotoo. +22 -12 + include/isc/netaddr.h@1.4 +22 -12 ports from BIND 9.3.0 and reintegrated into ntp libisc code - include/isc/netscope.h@1.1, 2004-12-22 23:56:31-05:00, mayer@tecotoo. +40 -0 + include/isc/netscope.h@1.1 +40 -0 isc_netscope header file - include/isc/netscope.h@1.0, 2004-12-22 23:56:31-05:00, mayer@tecotoo. +0 -0 + include/isc/netscope.h@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/include/isc/netscope.h - include/isc/region.h@1.1, 2004-12-22 23:57:06-05:00, mayer@tecotoo. +95 -0 + include/isc/region.h@1.1 +95 -0 isc_region header file - include/isc/region.h@1.0, 2004-12-22 23:57:06-05:00, mayer@tecotoo. +0 -0 + include/isc/region.h@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/include/isc/region.h - include/isc/result.h@1.3, 2004-12-23 00:15:12-05:00, mayer@tecotoo. +14 -11 + include/isc/result.h@1.3 +14 -11 ports from BIND 9.3.0 and reintegrated into ntp libisc code - include/isc/sockaddr.h@1.3, 2004-12-23 00:15:12-05:00, mayer@tecotoo. +6 -0 + include/isc/sockaddr.h@1.3 +6 -0 ports from BIND 9.3.0 and reintegrated into ntp libisc code - libisc/net.c@1.4, 2004-12-23 00:15:13-05:00, mayer@tecotoo. +210 -10 + libisc/net.c@1.4 +210 -10 ports from BIND 9.3.0 and reintegrated into ntp libisc code - libisc/netaddr.c@1.1, 2004-12-22 23:58:40-05:00, mayer@tecotoo. +357 -0 + libisc/netaddr.c@1.1 +357 -0 isc_netaddr functions - libisc/netaddr.c@1.0, 2004-12-22 23:58:40-05:00, mayer@tecotoo. +0 -0 + libisc/netaddr.c@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/libisc/netaddr.c - libisc/netscope.c@1.1, 2004-12-22 23:59:18-05:00, mayer@tecotoo. +74 -0 + libisc/netscope.c@1.1 +74 -0 - libisc/netscope.c@1.0, 2004-12-22 23:59:18-05:00, mayer@tecotoo. +0 -0 + libisc/netscope.c@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/libisc/netscope.c - libisc/sockaddr.c@1.1, 2004-12-23 00:00:01-05:00, mayer@tecotoo. +474 -0 + libisc/sockaddr.c@1.1 +474 -0 isc_sockaddr functions - libisc/sockaddr.c@1.0, 2004-12-23 00:00:01-05:00, mayer@tecotoo. +0 -0 + libisc/sockaddr.c@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/libisc/sockaddr.c - ports/winnt/include/isc/ipv6.h@1.5, 2004-12-23 00:15:13-05:00, mayer@tecotoo. +16 -12 + ports/winnt/include/isc/ipv6.h@1.5 +16 -12 ports from BIND 9.3.0 and reintegrated into ntp libisc code - ports/winnt/include/isc/net.h@1.5, 2004-12-23 00:15:14-05:00, mayer@tecotoo. +60 -12 + ports/winnt/include/isc/net.h@1.5 +60 -12 ports from BIND 9.3.0 and reintegrated into ntp libisc code - ports/winnt/libisc/net.c@1.6, 2004-12-23 00:15:14-05:00, mayer@tecotoo. +206 -10 + ports/winnt/libisc/net.c@1.6 +206 -10 ports from BIND 9.3.0 and reintegrated into ntp libisc code -ChangeSet@1.1251.8.6, 2004-12-22 00:35:41-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.6, 2004-12-22 00:35:41-05:00, stenn@whimsy.udel.edu unused variable cleanup - ntpd/cmd_args.c@1.31, 2004-12-22 00:35:24-05:00, stenn@whimsy.udel.edu +0 -1 + ntpd/cmd_args.c@1.31 +0 -1 unused variable cleanup -ChangeSet@1.1251.8.5, 2004-12-20 21:34:16-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.5, 2004-12-20 21:34:16-05:00, stenn@whimsy.udel.edu wwv cleanup from Dave Mills - ntpd/refclock_wwv.c@1.52, 2004-12-20 21:34:03-05:00, stenn@whimsy.udel.edu +6 -5 + ntpd/refclock_wwv.c@1.52 +6 -5 wwv cleanup from Dave Mills -ChangeSet@1.1251.8.4, 2004-12-20 21:01:08-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.4, 2004-12-20 21:01:08-05:00, stenn@whimsy.udel.edu If "prefer" is set, only huffpuff to the preferred peer. From Dave Mills. - ntpd/ntp_loopfilter.c@1.101, 2004-12-20 21:00:54-05:00, stenn@whimsy.udel.edu +5 -1 + ntpd/ntp_loopfilter.c@1.101 +5 -1 If "prefer" is set, only huffpuff to the preferred peer. From Dave Mills. -ChangeSet@1.1251.8.3, 2004-12-20 20:54:34-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.3, 2004-12-20 20:54:34-05:00, stenn@whimsy.udel.edu Lose -m from ntpd.html - html/ntpd.html@1.35, 2004-12-20 20:54:24-05:00, stenn@whimsy.udel.edu +6 -6 + html/ntpd.html@1.35 +6 -6 Lose -m from ntpd.html -ChangeSet@1.1251.8.2, 2004-12-20 20:41:57-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.2, 2004-12-20 20:41:57-05:00, stenn@whimsy.udel.edu [Bug 374] Always declare atom_shutdown(). - ntpd/refclock_atom.c@1.50, 2004-12-20 20:41:44-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_atom.c@1.50 +1 -1 [Bug 374] Always declare atom_shutdown(). -ChangeSet@1.1251.8.1, 2004-12-20 20:36:18-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.8.1, 2004-12-20 20:36:18-05:00, stenn@whimsy.udel.edu [Bug 378]: Added macros for Danny - configure.ac@1.359.1.6, 2004-12-20 20:36:06-05:00, stenn@whimsy.udel.edu +84 -1 + configure.ac@1.359.1.6 +84 -1 [Bug 378]: Added macros for Danny -ChangeSet@1.1251.7.26, 2004-12-18 04:55:09+00:00, abe@pogo.udel.edu +3 -0 +ChangeSet@1.1251.7.26, 2004-12-18 04:55:09+00:00, abe@pogo.udel.edu - BitKeeper/etc/logging_ok@1.51, 2004-12-18 04:55:08+00:00, abe@pogo.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.51 +1 -0 Logging to logging@openlogging.org accepted - html/drivers/driver40.html@1.12, 2004-12-18 04:43:20+00:00, abe@pogo.udel.edu +46 -4 + html/drivers/driver40.html@1.12 +46 -4 - ntpd/refclock_jjy.c@1.12, 2004-12-18 04:42:11+00:00, abe@pogo.udel.edu +275 -21 + ntpd/refclock_jjy.c@1.12 +275 -21 -ChangeSet@1.1251.7.25, 2004-12-17 04:49:29-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.25, 2004-12-17 04:49:29-05:00, stenn@whimsy.udel.edu atom cleanup from Dave Mills - ntpd/refclock_atom.c@1.49, 2004-12-17 04:49:09-05:00, stenn@whimsy.udel.edu +52 -18 + ntpd/refclock_atom.c@1.49 +52 -18 atom cleanup from Dave Mills -ChangeSet@1.1251.7.24, 2004-12-17 04:28:23-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.7.24, 2004-12-17 04:28:23-05:00, stenn@whimsy.udel.edu cleanup - ntpdc/ntpdc.c@1.40, 2004-12-17 04:28:05-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.c@1.40 +2 -2 cleanup - ntpq/ntpq.c@1.55, 2004-12-17 04:28:06-05:00, stenn@whimsy.udel.edu +2 -4 + ntpq/ntpq.c@1.55 +2 -4 cleanup -ChangeSet@1.1178.4.1, 2004-12-17 03:49:20-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1178.4.1, 2004-12-17 03:49:20-05:00, stenn@whimsy.udel.edu [Bug 373] ntpq and ntpdv help menu improvement, from Charles Maier - ntpdc/ntpdc.c@1.33.1.1, 2004-12-17 03:48:58-05:00, stenn@whimsy.udel.edu +33 -37 + ntpdc/ntpdc.c@1.33.1.1 +33 -37 [Bug 373] ntpq and ntpdv help menu improvement - ntpq/ntpq.c@1.48.1.1, 2004-12-17 03:48:58-05:00, stenn@whimsy.udel.edu +33 -33 + ntpq/ntpq.c@1.48.1.1 +33 -33 [Bug 373] ntpq and ntpdv help menu improvement -ChangeSet@1.1251.7.22, 2004-12-17 03:28:27-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.22, 2004-12-17 03:28:27-05:00, stenn@whimsy.udel.edu [Bug 368] Use config.h for jitter.c - util/jitter.c@1.7, 2004-12-17 03:28:08-05:00, stenn@whimsy.udel.edu +4 -0 + util/jitter.c@1.7 +4 -0 [Bug 368] Use config.h -ChangeSet@1.1251.7.21, 2004-12-17 00:15:55-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.21, 2004-12-17 00:15:55-05:00, stenn@whimsy.udel.edu Lose -m - ntpd/cmd_args.c@1.30, 2004-12-17 00:15:38-05:00, stenn@whimsy.udel.edu +3 -11 + ntpd/cmd_args.c@1.30 +3 -11 Lose -m -ChangeSet@1.1251.7.20, 2004-12-16 00:38:18-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.20, 2004-12-16 00:38:18-05:00, stenn@whimsy.udel.edu [Bug 367]: Bump CONNECT to 20, fix typo accessing sys_phone[]. - ntpd/refclock_acts.c@1.18, 2004-12-16 00:38:03-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/refclock_acts.c@1.18 +2 -2 [Bug 367]: Bump CONNECT to 20, fix typo accessing sys_phone[]. -ChangeSet@1.1251.7.19, 2004-12-14 00:09:04-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.19, 2004-12-14 00:09:04-05:00, stenn@whimsy.udel.edu netdb.h isnow handled by ntp_rcf2553.h - libntp/ntp_rfc2553.c@1.21, 2004-12-14 00:08:51-05:00, stenn@whimsy.udel.edu +0 -1 + libntp/ntp_rfc2553.c@1.21 +0 -1 netdb.h isnow handled by ntp_rcf2553.h -ChangeSet@1.1251.7.18, 2004-12-13 13:53:13-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.18, 2004-12-13 13:53:13-05:00, stenn@whimsy.udel.edu refclock_atom fixes. - ntpd/refclock_atom.c@1.48, 2004-12-13 13:53:10-05:00, stenn@whimsy.udel.edu +28 -25 + ntpd/refclock_atom.c@1.48 +28 -25 Call atom_shutdown at shutdown time (Dave Mills). Isolate HAVE_PPSAPI-specific code in atom_shutdown (Dave Mills). [Bug 366] Fix uninitialized pointer (Dave Mills, Martin Burnicki). -ChangeSet@1.1251.7.17, 2004-12-13 02:11:09-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.17, 2004-12-13 02:11:09-05:00, stenn@whimsy.udel.edu more wwv cleanup from Dave Mills. - ntpd/refclock_wwv.c@1.51, 2004-12-13 02:10:59-05:00, stenn@whimsy.udel.edu +11 -17 + ntpd/refclock_wwv.c@1.51 +11 -17 more wwv cleanup from Dave Mills. -ChangeSet@1.1251.7.16, 2004-12-11 22:42:45-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.7.16, 2004-12-11 22:42:45-05:00, stenn@whimsy.udel.edu New pps features from Dave Mills. - html/drivers/driver22.html@1.16, 2004-12-11 22:42:41-05:00, stenn@whimsy.udel.edu +10 -7 + html/drivers/driver22.html@1.16 +10 -7 documentation updates - ntpd/refclock_atom.c@1.47, 2004-12-11 22:42:41-05:00, stenn@whimsy.udel.edu +42 -35 + ntpd/refclock_atom.c@1.47 +42 -35 flag2 controls the on-time edge (assert/clear). flag3 enables or disables kernel PPS support. ppsapi-timepps header cleanup. -ChangeSet@1.1251.7.15, 2004-12-11 22:28:49-05:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1251.7.15, 2004-12-11 22:28:49-05:00, stenn@whimsy.udel.edu ppsapi header cleanup - ntpd/refclock_jupiter.c@1.19, 2004-12-11 22:28:43-05:00, stenn@whimsy.udel.edu +3 -1 + ntpd/refclock_jupiter.c@1.19 +3 -1 ppsapi header cleanup - ntpd/refclock_mx4200.c@1.21, 2004-12-11 22:28:44-05:00, stenn@whimsy.udel.edu +3 -7 + ntpd/refclock_mx4200.c@1.21 +3 -7 ppsapi header cleanup - ntpd/refclock_nmea.c@1.25, 2004-12-11 22:28:44-05:00, stenn@whimsy.udel.edu +1 -7 + ntpd/refclock_nmea.c@1.25 +1 -7 ppsapi header cleanup - ntpd/refclock_oncore.c@1.53, 2004-12-11 22:28:44-05:00, stenn@whimsy.udel.edu +3 -1 + ntpd/refclock_oncore.c@1.53 +3 -1 ppsapi header cleanup - ntpd/refclock_parse.c@1.28, 2004-12-11 22:28:44-05:00, stenn@whimsy.udel.edu +3 -1 + ntpd/refclock_parse.c@1.28 +3 -1 ppsapi header cleanup - ntpd/refclock_ripencc.c@1.6, 2004-12-11 22:28:45-05:00, stenn@whimsy.udel.edu +3 -1 + ntpd/refclock_ripencc.c@1.6 +3 -1 ppsapi header cleanup -ChangeSet@1.1251.7.14, 2004-12-11 22:22:10-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.7.14, 2004-12-11 22:22:10-05:00, stenn@whimsy.udel.edu Lose the "pps" stuff from ntp.conf. From Dave Mills. - include/ntp_config.h@1.29, 2004-12-11 22:22:06-05:00, stenn@whimsy.udel.edu +1 -8 + include/ntp_config.h@1.29 +1 -8 Lose the PPS config stuff. - ntpd/ntp_config.c@1.117, 2004-12-11 22:22:06-05:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntp_config.c@1.117 +0 -1 Lose the "pps" configuration stuff. -ChangeSet@1.1251.7.13, 2004-12-10 23:33:03-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.13, 2004-12-10 23:33:03-05:00, stenn@whimsy.udel.edu More WWV cleanup from Dave Mills. - ntpd/refclock_wwv.c@1.50, 2004-12-10 23:32:59-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/refclock_wwv.c@1.50 +2 -2 More wwv cleanup from Dave Mills. -ChangeSet@1.1251.7.12, 2004-12-10 18:03:43-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.12, 2004-12-10 18:03:43-05:00, stenn@whimsy.udel.edu refclock_wwv.c fixes from Dave Mills - ntpd/refclock_wwv.c@1.49, 2004-12-10 18:03:28-05:00, stenn@whimsy.udel.edu +85 -129 + ntpd/refclock_wwv.c@1.49 +85 -129 refclock_wwv.c fixes from Dave Mills -ChangeSet@1.1251.7.11, 2004-12-10 18:00:32-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.11, 2004-12-10 18:00:32-05:00, stenn@whimsy.udel.edu FIXPOLL fix from Dave Mills - ntpd/ntp_proto.c@1.191, 2004-12-10 18:00:19-05:00, stenn@whimsy.udel.edu +4 -3 + ntpd/ntp_proto.c@1.191 +4 -3 FIXPOLL fix from Dave Mills -ChangeSet@1.1251.7.10, 2004-12-09 14:36:18-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.10, 2004-12-09 14:36:18-05:00, stenn@whimsy.udel.edu cleanup - configure.ac@1.359.1.5, 2004-12-09 14:35:49-05:00, stenn@whimsy.udel.edu +2 -2 + configure.ac@1.359.1.5 +2 -2 cleanup -ChangeSet@1.1251.7.9, 2004-12-08 22:09:06-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.9, 2004-12-08 22:09:06-05:00, stenn@whimsy.udel.edu [Bug 368] net/if.h needs sys/socket.h - configure.ac@1.359.1.4, 2004-12-08 22:08:52-05:00, stenn@whimsy.udel.edu +2 -0 + configure.ac@1.359.1.4 +2 -0 [Bug 368] net/if.h needs sys/socket.h -ChangeSet@1.1251.7.8, 2004-12-08 21:49:05-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.7.8, 2004-12-08 21:49:05-05:00, stenn@whimsy.udel.edu [Bug 368]: Distribute jitter.h, provide missing stdlib.h, fix LDADD - util/Makefile.am@1.25, 2004-12-08 21:48:52-05:00, stenn@whimsy.udel.edu +3 -0 + util/Makefile.am@1.25 +3 -0 [Bug 368]: Distribute jitter.h, provide missing stdlib.h, fix LDADD - util/jitter.c@1.6, 2004-12-08 21:48:52-05:00, stenn@whimsy.udel.edu +5 -4 + util/jitter.c@1.6 +5 -4 [Bug 368]: Distribute jitter.h, provide missing stdlib.h, fix LDADD -ChangeSet@1.1251.1.39, 2004-12-07 20:31:52-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.39, 2004-12-07 20:31:52-05:00, mayer@tecotoo. Renable wildcard for testing - ntpd/ntp_io.c@1.153, 2004-12-07 20:31:36-05:00, mayer@tecotoo. +2 -1 + ntpd/ntp_io.c@1.153 +2 -1 Renable wildcard for testing -ChangeSet@1.1251.1.38, 2004-12-07 19:44:54-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.38, 2004-12-07 19:44:54-05:00, mayer@tecotoo. Add debugging detail for adding mcast group membership- error fix - ntpd/ntp_io.c@1.152, 2004-12-07 19:44:30-05:00, mayer@tecotoo. +0 -1 + ntpd/ntp_io.c@1.152 +0 -1 Add debugging detail for adding mcast group membership- error fix -ChangeSet@1.1251.1.37, 2004-12-07 19:40:34-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.37, 2004-12-07 19:40:34-05:00, mayer@tecotoo. Add debugging detail for adding mcast group membership - ntpd/ntp_io.c@1.151, 2004-12-07 19:39:51-05:00, mayer@tecotoo. +11 -6 + ntpd/ntp_io.c@1.151 +11 -6 Add debugging detail for adding mcast group membership -ChangeSet@1.1251.7.7, 2004-12-06 14:07:32-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.7, 2004-12-06 14:07:32-05:00, stenn@whimsy.udel.edu [Bug 366] Distribute the ppsapi_timepps.h header - ntpd/Makefile.am@1.40, 2004-12-06 14:07:10-05:00, stenn@whimsy.udel.edu +1 -0 + ntpd/Makefile.am@1.40 +1 -0 [Bug 366] Distribute the ppsapi_timepps.h header -ChangeSet@1.1251.7.6, 2004-12-06 03:51:05-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.6, 2004-12-06 03:51:05-05:00, stenn@whimsy.udel.edu timepps.h header cleanup - configure.ac@1.359.1.3, 2004-12-06 03:50:52-05:00, stenn@whimsy.udel.edu +1 -0 + configure.ac@1.359.1.3 +1 -0 timepps.h header cleanup -ChangeSet@1.1251.7.5, 2004-12-06 03:41:48-05:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1251.7.5, 2004-12-06 03:41:48-05:00, stenn@whimsy.udel.edu timepps.h header cleanup - configure.ac@1.359.1.2, 2004-12-06 03:41:00-05:00, stenn@whimsy.udel.edu +12 -6 + configure.ac@1.359.1.2 +12 -6 timepps.h header cleanup - ntpd/ppsapi_timepps.h@1.1, 2004-12-06 03:40:00-05:00, stenn@whimsy.udel.edu +26 -0 + ntpd/ppsapi_timepps.h@1.1 +26 -0 - ntpd/ppsapi_timepps.h@1.0, 2004-12-06 03:40:00-05:00, stenn@whimsy.udel.edu +0 -0 + ntpd/ppsapi_timepps.h@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/ntpd/ppsapi_timepps.h - ntpd/refclock_jupiter.c@1.18, 2004-12-06 03:41:00-05:00, stenn@whimsy.udel.edu +1 -9 + ntpd/refclock_jupiter.c@1.18 +1 -9 timepps.h header cleanup - ntpd/refclock_oncore.c@1.52, 2004-12-06 03:41:00-05:00, stenn@whimsy.udel.edu +1 -30 + ntpd/refclock_oncore.c@1.52 +1 -30 timepps.h header cleanup - ntpd/refclock_parse.c@1.27, 2004-12-06 03:41:01-05:00, stenn@whimsy.udel.edu +1 -30 + ntpd/refclock_parse.c@1.27 +1 -30 timepps.h header cleanup - ntpd/refclock_ripencc.c@1.5, 2004-12-06 03:41:01-05:00, stenn@whimsy.udel.edu +1 -7 + ntpd/refclock_ripencc.c@1.5 +1 -7 timepps.h header cleanup -ChangeSet@1.1251.7.4, 2004-12-05 23:38:24-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.7.4, 2004-12-05 23:38:24-05:00, stenn@whimsy.udel.edu WWV improvements from Dave Mills. - html/drivers/driver36.html@1.24, 2004-12-05 23:38:05-05:00, stenn@whimsy.udel.edu +80 -67 + html/drivers/driver36.html@1.24 +80 -67 WWV improvements from Dave Mills. - ntpd/refclock_wwv.c@1.48, 2004-12-05 23:38:06-05:00, stenn@whimsy.udel.edu +155 -103 + ntpd/refclock_wwv.c@1.48 +155 -103 WWV improvements from Dave Mills. -ChangeSet@1.1251.7.3, 2004-12-05 23:33:36-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.3, 2004-12-05 23:33:36-05:00, stenn@whimsy.udel.edu [Bug 357] Fixed and additional improvements from Dave Mills - html/drivers/driver18.html@1.13, 2004-12-05 23:33:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver18.html@1.13 +2 -2 [Bug 357] Fixed and additional improvements from Dave Mills -ChangeSet@1.1251.7.2, 2004-12-05 21:12:40-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.7.2, 2004-12-05 21:12:40-05:00, stenn@whimsy.udel.edu [Bug 357] Fixed and additional improvements from Dave Mills - html/miscopt.html@1.29, 2004-12-05 21:12:25-05:00, stenn@whimsy.udel.edu +3 -2 + html/miscopt.html@1.29 +3 -2 [Bug 357] Fixed and additional improvements from Dave Mills -ChangeSet@1.1251.7.1, 2004-12-05 21:06:26-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.7.1, 2004-12-05 21:06:26-05:00, stenn@whimsy.udel.edu [Bug 357] Fixed and additional improvements from Dave Mills - include/ntpd.h@1.73, 2004-12-05 21:05:57-05:00, stenn@whimsy.udel.edu +1 -1 + include/ntpd.h@1.73 +1 -1 [Bug 357] Fixed and additional improvements from Dave Mills - ntpd/ntp_config.c@1.116, 2004-12-05 21:05:57-05:00, stenn@whimsy.udel.edu +7 -7 + ntpd/ntp_config.c@1.116 +7 -7 [Bug 357] Fixed and additional improvements from Dave Mills - ntpd/refclock_acts.c@1.17, 2004-12-05 21:05:57-05:00, stenn@whimsy.udel.edu +11 -9 + ntpd/refclock_acts.c@1.17 +11 -9 [Bug 357] Fixed and additional improvements from Dave Mills -ChangeSet@1.1251.1.36, 2004-12-03 22:36:37-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.36, 2004-12-03 22:36:37-05:00, mayer@tecotoo. Undefine UDP_WILDCARD_DELIVERY for testing - ntpd/ntp_io.c@1.150, 2004-12-03 22:36:23-05:00, mayer@tecotoo. +5 -5 + ntpd/ntp_io.c@1.150 +5 -5 Undefine UDP_WILDCARD_DELIVERY for testing -ChangeSet@1.1251.1.35, 2004-12-03 22:29:34-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.35, 2004-12-03 22:29:34-05:00, mayer@tecotoo. Undefine UDP_WILDCARD_DELIVERY for testing - ntpd/ntp_io.c@1.149, 2004-12-03 22:29:08-05:00, mayer@tecotoo. +5 -0 + ntpd/ntp_io.c@1.149 +5 -0 Undefine UDP_WILDCARD_DELIVERY for testing -ChangeSet@1.1251.1.34, 2004-12-02 20:58:35-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.34, 2004-12-02 20:58:35-05:00, mayer@tecotoo. Add info on cast_flags in newpeer - ntpd/ntp_peer.c@1.67, 2004-12-02 20:58:08-05:00, mayer@tecotoo. +5 -0 + ntpd/ntp_peer.c@1.67 +5 -0 Add info on cast_flags in newpeer -ChangeSet@1.1251.1.33, 2004-11-30 05:20:17-05:00, stenn@pogo.udel.edu +16 -0 +ChangeSet@1.1251.1.33, 2004-11-30 05:20:17-05:00, stenn@pogo.udel.edu netdb.h cleanup - include/ntp_fp.h@1.12, 2004-11-30 05:18:39-05:00, stenn@pogo.udel.edu +1 -0 + include/ntp_fp.h@1.12 +1 -0 netdb.h cleanup - include/ntp_rfc2553.h@1.27, 2004-11-30 05:18:39-05:00, stenn@pogo.udel.edu +2 -0 + include/ntp_rfc2553.h@1.27 +2 -0 netdb.h cleanup - libntp/decodenetnum.c@1.6, 2004-11-30 05:18:43-05:00, stenn@pogo.udel.edu +0 -1 + libntp/decodenetnum.c@1.6 +0 -1 netdb.h cleanup - libntp/numtohost.c@1.3, 2004-11-30 05:18:44-05:00, stenn@pogo.udel.edu +0 -1 + libntp/numtohost.c@1.3 +0 -1 netdb.h cleanup - libntp/socktoa.c@1.8, 2004-11-30 05:18:44-05:00, stenn@pogo.udel.edu +0 -1 + libntp/socktoa.c@1.8 +0 -1 netdb.h cleanup - libntp/socktohost.c@1.5, 2004-11-30 05:18:44-05:00, stenn@pogo.udel.edu +0 -1 + libntp/socktohost.c@1.5 +0 -1 netdb.h cleanup - ntpd/ntp_config.c@1.115, 2004-11-30 05:18:46-05:00, stenn@pogo.udel.edu +0 -2 + ntpd/ntp_config.c@1.115 +0 -2 netdb.h cleanup - ntpd/ntp_intres.c@1.39, 2004-11-30 05:18:46-05:00, stenn@pogo.udel.edu +0 -2 + ntpd/ntp_intres.c@1.39 +0 -2 netdb.h cleanup - ntpd/ntp_resolver.c@1.18, 2004-11-30 05:18:47-05:00, stenn@pogo.udel.edu +0 -1 + ntpd/ntp_resolver.c@1.18 +0 -1 netdb.h cleanup - ntpd/refclock_nmea.c@1.24, 2004-11-30 05:18:49-05:00, stenn@pogo.udel.edu +0 -2 + ntpd/refclock_nmea.c@1.24 +0 -2 netdb.h cleanup - ntpdate/ntpdate.c@1.50, 2004-11-30 05:18:50-05:00, stenn@pogo.udel.edu +0 -1 + ntpdate/ntpdate.c@1.50 +0 -1 netdb.h cleanup - ntpdate/ntptimeset.c@1.12, 2004-11-30 05:18:50-05:00, stenn@pogo.udel.edu +0 -1 + ntpdate/ntptimeset.c@1.12 +0 -1 netdb.h cleanup - ntpdc/ntpdc.c@1.38, 2004-11-30 05:18:50-05:00, stenn@pogo.udel.edu +0 -1 + ntpdc/ntpdc.c@1.38 +0 -1 netdb.h cleanup - ntpdc/ntpdc_ops.c@1.38, 2004-11-30 05:18:53-05:00, stenn@pogo.udel.edu +0 -1 + ntpdc/ntpdc_ops.c@1.38 +0 -1 netdb.h cleanup - ntpq/ntpq.c@1.53, 2004-11-30 05:18:54-05:00, stenn@pogo.udel.edu +0 -1 + ntpq/ntpq.c@1.53 +0 -1 netdb.h cleanup - ntpq/ntpq_ops.c@1.20.1.2, 2004-11-30 05:18:54-05:00, stenn@pogo.udel.edu +0 -1 + ntpq/ntpq_ops.c@1.20.1.2 +0 -1 netdb.h cleanup -ChangeSet@1.1251.6.1, 2004-11-29 22:45:56-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.6.1, 2004-11-29 22:45:56-05:00, stenn@pogo.udel.edu findinterface() and findbcastinterf() should ignore wildcard sockets. From Danny Mayer. - ntpd/ntp_io.c@1.148, 2004-11-29 22:45:45-05:00, stenn@pogo.udel.edu +2 -2 + ntpd/ntp_io.c@1.148 +2 -2 findinterface() and findbcastinterf() should ignore wildcard sockets. From Danny Mayer. -ChangeSet@1.1251.5.1, 2004-11-29 22:27:18-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.5.1, 2004-11-29 22:27:18-05:00, mayer@tecotoo. Fix winioctl warning messages - ports/winnt/ntpd/hopf_PCI_io.c@1.6, 2004-11-29 22:26:45-05:00, mayer@tecotoo. +5 -4 + ports/winnt/ntpd/hopf_PCI_io.c@1.6 +5 -4 Fix winioctl warning messages -ChangeSet@1.1251.1.30, 2004-11-29 01:09:27-05:00, stenn@whimsy.udel.edu +9 -0 +ChangeSet@1.1251.1.30, 2004-11-29 01:09:27-05:00, stenn@whimsy.udel.edu FIXPOLL changes and cleanup from Dave Mills - include/ntp.h@1.104, 2004-11-29 01:06:29-05:00, stenn@whimsy.udel.edu +1 -0 + include/ntp.h@1.104 +1 -0 FIXPOLL changes and cleanup from Dave Mills - ntpd/ntp_peer.c@1.66, 2004-11-29 01:06:45-05:00, stenn@whimsy.udel.edu +1 -2 + ntpd/ntp_peer.c@1.66 +1 -2 FIXPOLL changes and cleanup from Dave Mills - ntpd/ntp_proto.c@1.190, 2004-11-29 01:06:45-05:00, stenn@whimsy.udel.edu +2 -6 + ntpd/ntp_proto.c@1.190 +2 -6 FIXPOLL changes and cleanup from Dave Mills - ntpd/ntp_refclock.c@1.63, 2004-11-29 01:06:45-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_refclock.c@1.63 +1 -1 FIXPOLL changes and cleanup from Dave Mills - ntpd/refclock_acts.c@1.16, 2004-11-29 01:06:46-05:00, stenn@whimsy.udel.edu +1 -0 + ntpd/refclock_acts.c@1.16 +1 -0 FIXPOLL changes and cleanup from Dave Mills - ntpd/refclock_arbiter.c@1.9, 2004-11-29 01:06:46-05:00, stenn@whimsy.udel.edu +48 -33 + ntpd/refclock_arbiter.c@1.9 +48 -33 FIXPOLL changes and cleanup from Dave Mills - ntpd/refclock_atom.c@1.46, 2004-11-29 01:06:47-05:00, stenn@whimsy.udel.edu +36 -58 + ntpd/refclock_atom.c@1.46 +36 -58 FIXPOLL changes and cleanup from Dave Mills - ntpd/refclock_wwv.c@1.47, 2004-11-29 01:06:50-05:00, stenn@whimsy.udel.edu +145 -139 + ntpd/refclock_wwv.c@1.47 +145 -139 FIXPOLL changes and cleanup from Dave Mills - ntpd/refclock_wwvb.c@1.14, 2004-11-29 01:06:50-05:00, stenn@whimsy.udel.edu +50 -28 + ntpd/refclock_wwvb.c@1.14 +50 -28 FIXPOLL changes and cleanup from Dave Mills -ChangeSet@1.1251.1.29, 2004-11-29 00:45:58-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.29, 2004-11-29 00:45:58-05:00, stenn@whimsy.udel.edu [Bug 363] ntpdate: use -1 to represent an invalid fd (from Rainer Weikusat) - ntpdate/ntpdate.c@1.49, 2004-11-29 00:45:43-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdate/ntpdate.c@1.49 +2 -2 [Bug 363] ntpdate: use -1 to represent an invalid fd (from Rainer Weikusat) -ChangeSet@1.1251.1.28, 2004-11-28 03:35:01-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.28, 2004-11-28 03:35:01-05:00, stenn@whimsy.udel.edu [Bug 363] ntpdate: use -1 to represent an invalid fd. Fix from Rainer Weikusat. - ntpdate/ntpdate.c@1.48, 2004-11-28 03:34:45-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdate/ntpdate.c@1.48 +2 -2 [Bug 363] ntpdate: use -1 to represent an invalid fd - Fix from Rainer Weikusat. -ChangeSet@1.1251.1.27, 2004-11-21 21:33:09-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.1.27, 2004-11-21 21:33:09-05:00, stenn@whimsy.udel.edu [Bug 349] Patches from Takao Abe - html/drivers/driver40.html@1.11, 2004-11-21 21:32:56-05:00, stenn@whimsy.udel.edu +6 -4 + html/drivers/driver40.html@1.11 +6 -4 [Bug 349] Patches from Takao Abe - ntpd/refclock_jjy.c@1.11, 2004-11-21 21:32:56-05:00, stenn@whimsy.udel.edu +57 -15 + ntpd/refclock_jjy.c@1.11 +57 -15 [Bug 349] Patches from Takao Abe -ChangeSet@1.1251.1.26, 2004-11-21 05:31:43-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.26, 2004-11-21 05:31:43-05:00, stenn@pogo.udel.edu lint - ntpd/refclock_parse.c@1.26, 2004-11-21 05:31:32-05:00, stenn@pogo.udel.edu +2 -2 + ntpd/refclock_parse.c@1.26 +2 -2 lint -ChangeSet@1.1251.1.25, 2004-11-21 05:23:35-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1251.1.25, 2004-11-21 05:23:35-05:00, stenn@whimsy.udel.edu Stuff from Dave Mills - libntp/icom.c@1.9, 2004-11-21 05:07:05-05:00, stenn@whimsy.udel.edu +1 -0 + libntp/icom.c@1.9 +1 -0 cleanup - ntpd/refclock_wwv.c@1.46, 2004-11-21 05:10:47-05:00, stenn@whimsy.udel.edu +159 -148 + ntpd/refclock_wwv.c@1.46 +159 -148 Fixes from Dave Mills - ntpd/refclock_wwv.c@1.45, 2004-11-20 02:38:44-05:00, stenn@whimsy.udel.edu +90 -93 + ntpd/refclock_wwv.c@1.45 +90 -93 lint -ChangeSet@1.1251.1.24, 2004-11-21 04:26:47-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1251.1.24, 2004-11-21 04:26:47-05:00, stenn@whimsy.udel.edu [Bug 359] Fix qsort first-arg casting - ntpd/ntp_refclock.c@1.62, 2004-11-20 02:38:41-05:00, stenn@whimsy.udel.edu +7 -2 + ntpd/ntp_refclock.c@1.62 +7 -2 [Bug 359] Fix qsort first-arg casting - ntpd/refclock_msfees.c@1.11, 2004-11-20 02:38:43-05:00, stenn@whimsy.udel.edu +7 -1 + ntpd/refclock_msfees.c@1.11 +7 -1 [Bug 359] Fix qsort first-arg casting - util/hist.c@1.6, 2004-11-21 04:26:44-05:00, stenn@whimsy.udel.edu +7 -1 + util/hist.c@1.6 +7 -1 [Bug 359] Fix qsort first-arg casting -ChangeSet@1.1251.1.23, 2004-11-21 03:55:29-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.23, 2004-11-21 03:55:29-05:00, stenn@whimsy.udel.edu Lint. - ntpd/refclock_mx4200.c@1.20, 2004-11-20 02:38:35-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/refclock_mx4200.c@1.20 +3 -3 lint -ChangeSet@1.1251.1.22, 2004-11-19 21:44:19-05:00, stenn@www.ntp.org +2 -0 +ChangeSet@1.1251.1.22, 2004-11-19 21:44:19-05:00, stenn@www.ntp.org qsort cast cleanup - ntpdc/ntpdc.c@1.37, 2004-11-19 21:44:09-05:00, stenn@www.ntp.org +4 -6 + ntpdc/ntpdc.c@1.37 +4 -6 qsort cast cleanup - ntpq/ntpq.c@1.52, 2004-11-19 21:44:09-05:00, stenn@www.ntp.org +4 -6 + ntpq/ntpq.c@1.52 +4 -6 qsort cast cleanup -ChangeSet@1.1251.1.21, 2004-11-19 04:21:49-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.21, 2004-11-19 04:21:49-05:00, stenn@whimsy.udel.edu refclock_parse.c needs ntp_string.h now. - ntpd/refclock_parse.c@1.25, 2004-11-19 04:21:31-05:00, stenn@whimsy.udel.edu +1 -0 + ntpd/refclock_parse.c@1.25 +1 -0 refclock_parse.c needs ntp_string.h now. -ChangeSet@1.1251.4.1, 2004-11-19 03:04:35-05:00, stenn@whimsy.udel.edu +46 -0 +ChangeSet@1.1251.4.1, 2004-11-19 03:04:35-05:00, stenn@whimsy.udel.edu [Bug 341] Patches from Frank Kardel - html/build/hints/parse@1.4, 2004-11-19 03:02:44-05:00, stenn@whimsy.udel.edu +1 -1 + html/build/hints/parse@1.4 +1 -1 [Bug 341] Patches from Frank Kardel - html/drivers/driver8.html@1.15, 2004-11-19 03:02:48-05:00, stenn@whimsy.udel.edu +306 -133 + html/drivers/driver8.html@1.15 +306 -133 [Bug 341] Patches from Frank Kardel - html/parsenew.html@1.9, 2004-11-19 03:02:42-05:00, stenn@whimsy.udel.edu +1 -1 + html/parsenew.html@1.9 +1 -1 [Bug 341] Patches from Frank Kardel - include/ascii.h@1.3, 2004-11-19 03:02:53-05:00, stenn@whimsy.udel.edu +34 -2 + include/ascii.h@1.3 +34 -2 [Bug 341] Patches from Frank Kardel - include/binio.h@1.3, 2004-11-19 03:02:54-05:00, stenn@whimsy.udel.edu +34 -2 + include/binio.h@1.3 +34 -2 [Bug 341] Patches from Frank Kardel - include/ieee754io.h@1.3, 2004-11-19 03:02:54-05:00, stenn@whimsy.udel.edu +34 -2 + include/ieee754io.h@1.3 +34 -2 [Bug 341] Patches from Frank Kardel - include/mbg_gps166.h@1.3, 2004-11-19 03:02:54-05:00, stenn@whimsy.udel.edu +33 -3 + include/mbg_gps166.h@1.3 +33 -3 [Bug 341] Patches from Frank Kardel - include/parse.h@1.5, 2004-11-19 03:02:56-05:00, stenn@whimsy.udel.edu +34 -11 + include/parse.h@1.5 +34 -11 [Bug 341] Patches from Frank Kardel - include/parse_conf.h@1.3, 2004-11-19 03:02:57-05:00, stenn@whimsy.udel.edu +29 -9 + include/parse_conf.h@1.3 +29 -9 [Bug 341] Patches from Frank Kardel - include/trimble.h@1.3, 2004-11-19 03:02:57-05:00, stenn@whimsy.udel.edu +34 -2 + include/trimble.h@1.3 +34 -2 [Bug 341] Patches from Frank Kardel - kernel/chuinit.c@1.3, 2004-11-19 03:02:59-05:00, stenn@whimsy.udel.edu +0 -2 + kernel/chuinit.c@1.3 +0 -2 [Bug 341] Patches from Frank Kardel - kernel/clkinit.c@1.3, 2004-11-19 03:03:00-05:00, stenn@whimsy.udel.edu +0 -2 + kernel/clkinit.c@1.3 +0 -2 [Bug 341] Patches from Frank Kardel - kernel/sys/parsestreams.h@1.5, 2004-11-19 03:03:00-05:00, stenn@whimsy.udel.edu +1 -1 + kernel/sys/parsestreams.h@1.5 +1 -1 [Bug 341] Patches from Frank Kardel - libntp/binio.c@1.4, 2004-11-19 03:03:02-05:00, stenn@whimsy.udel.edu +29 -2 + libntp/binio.c@1.4 +29 -2 [Bug 341] Patches from Frank Kardel - libntp/buftvtots.c@1.4, 2004-11-19 03:03:02-05:00, stenn@whimsy.udel.edu +12 -83 + libntp/buftvtots.c@1.4 +12 -83 [Bug 341] Patches from Frank Kardel - libntp/gpstolfp.c@1.6, 2004-11-19 03:03:04-05:00, stenn@whimsy.udel.edu +34 -2 + libntp/gpstolfp.c@1.6 +34 -2 [Bug 341] Patches from Frank Kardel - libntp/ieee754io.c@1.6, 2004-11-19 03:03:04-05:00, stenn@whimsy.udel.edu +34 -2 + libntp/ieee754io.c@1.6 +34 -2 [Bug 341] Patches from Frank Kardel - libntp/mfp_mul.c@1.4, 2004-11-19 03:03:05-05:00, stenn@whimsy.udel.edu +34 -2 + libntp/mfp_mul.c@1.4 +34 -2 [Bug 341] Patches from Frank Kardel - libntp/mktime.c@1.8, 2004-11-19 03:03:05-05:00, stenn@whimsy.udel.edu +0 -1 + libntp/mktime.c@1.8 +0 -1 [Bug 341] Patches from Frank Kardel - libparse/README@1.3, 2004-11-19 03:03:08-05:00, stenn@whimsy.udel.edu +2 -2 + libparse/README@1.3 +2 -2 [Bug 341] Patches from Frank Kardel - libparse/clk_computime.c@1.7, 2004-11-19 03:03:08-05:00, stenn@whimsy.udel.edu +32 -9 + libparse/clk_computime.c@1.7 +32 -9 [Bug 341] Patches from Frank Kardel - libparse/clk_dcf7000.c@1.7, 2004-11-19 03:03:08-05:00, stenn@whimsy.udel.edu +31 -8 + libparse/clk_dcf7000.c@1.7 +31 -8 [Bug 341] Patches from Frank Kardel - libparse/clk_hopf6021.c@1.7, 2004-11-19 03:03:08-05:00, stenn@whimsy.udel.edu +5 -2 + libparse/clk_hopf6021.c@1.7 +5 -2 [Bug 341] Patches from Frank Kardel - libparse/clk_meinberg.c@1.7, 2004-11-19 03:03:08-05:00, stenn@whimsy.udel.edu +31 -8 + libparse/clk_meinberg.c@1.7 +31 -8 [Bug 341] Patches from Frank Kardel - libparse/clk_rawdcf.c@1.9, 2004-11-19 03:03:08-05:00, stenn@whimsy.udel.edu +31 -8 + libparse/clk_rawdcf.c@1.9 +31 -8 [Bug 341] Patches from Frank Kardel - libparse/clk_rcc8000.c@1.7, 2004-11-19 03:03:09-05:00, stenn@whimsy.udel.edu +5 -2 + libparse/clk_rcc8000.c@1.7 +5 -2 [Bug 341] Patches from Frank Kardel - libparse/clk_schmid.c@1.7, 2004-11-19 03:03:09-05:00, stenn@whimsy.udel.edu +32 -8 + libparse/clk_schmid.c@1.7 +32 -8 [Bug 341] Patches from Frank Kardel - libparse/clk_trimtaip.c@1.7, 2004-11-19 03:03:09-05:00, stenn@whimsy.udel.edu +33 -2 + libparse/clk_trimtaip.c@1.7 +33 -2 [Bug 341] Patches from Frank Kardel - libparse/clk_trimtsip.c@1.7, 2004-11-19 03:03:09-05:00, stenn@whimsy.udel.edu +35 -3 + libparse/clk_trimtsip.c@1.7 +35 -3 [Bug 341] Patches from Frank Kardel - libparse/clk_varitext.c@1.6, 2004-11-19 03:03:10-05:00, stenn@whimsy.udel.edu +40 -8 + libparse/clk_varitext.c@1.6 +40 -8 [Bug 341] Patches from Frank Kardel - libparse/clk_wharton.c@1.5, 2004-11-19 03:03:10-05:00, stenn@whimsy.udel.edu +2 -2 + libparse/clk_wharton.c@1.5 +2 -2 [Bug 341] Patches from Frank Kardel - libparse/data_mbg.c@1.4, 2004-11-19 03:03:10-05:00, stenn@whimsy.udel.edu +32 -2 + libparse/data_mbg.c@1.4 +32 -2 [Bug 341] Patches from Frank Kardel - libparse/info_trimble.c@1.3, 2004-11-19 03:03:10-05:00, stenn@whimsy.udel.edu +0 -2 + libparse/info_trimble.c@1.3 +0 -2 [Bug 341] Patches from Frank Kardel - libparse/parse.c@1.9, 2004-11-19 03:03:10-05:00, stenn@whimsy.udel.edu +35 -9 + libparse/parse.c@1.9 +35 -9 [Bug 341] Patches from Frank Kardel - libparse/parse_conf.c@1.8, 2004-11-19 03:03:10-05:00, stenn@whimsy.udel.edu +31 -8 + libparse/parse_conf.c@1.8 +31 -8 [Bug 341] Patches from Frank Kardel - libparse/parsesolaris.c@1.5, 2004-11-19 03:03:10-05:00, stenn@whimsy.udel.edu +36 -12 + libparse/parsesolaris.c@1.5 +36 -12 [Bug 341] Patches from Frank Kardel - libparse/parsestreams.c@1.5, 2004-11-19 03:03:11-05:00, stenn@whimsy.udel.edu +37 -11 + libparse/parsestreams.c@1.5 +37 -11 [Bug 341] Patches from Frank Kardel - libparse/trim_info.c@1.3, 2004-11-19 03:03:11-05:00, stenn@whimsy.udel.edu +33 -2 + libparse/trim_info.c@1.3 +33 -2 [Bug 341] Patches from Frank Kardel - ntpd/ntp_config.c@1.114, 2004-11-19 03:03:11-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_config.c@1.114 +1 -1 [Bug 341] Patches from Frank Kardel - ntpd/ntp_refclock.c@1.61, 2004-11-19 03:03:13-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_refclock.c@1.61 +1 -1 [Bug 341] Patches from Frank Kardel - ntpd/refclock_atom.c@1.45, 2004-11-19 03:03:14-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_atom.c@1.45 +1 -1 [Bug 341] Patches from Frank Kardel - ntpd/refclock_parse.c@1.24, 2004-11-19 03:03:16-05:00, stenn@whimsy.udel.edu +513 -121 + ntpd/refclock_parse.c@1.24 +513 -121 [Bug 341] Patches from Frank Kardel - parseutil/dcfd.c@1.14, 2004-11-19 03:03:18-05:00, stenn@whimsy.udel.edu +37 -11 + parseutil/dcfd.c@1.14 +37 -11 [Bug 341] Patches from Frank Kardel - parseutil/testdcf.c@1.5, 2004-11-19 03:03:18-05:00, stenn@whimsy.udel.edu +38 -11 + parseutil/testdcf.c@1.5 +38 -11 [Bug 341] Patches from Frank Kardel - scripts/monitoring/lr.pl@1.4, 2004-11-19 03:03:25-05:00, stenn@whimsy.udel.edu +12 -12 + scripts/monitoring/lr.pl@1.4 +12 -12 [Bug 341] Patches from Frank Kardel - scripts/monitoring/ntploopwatch@1.3, 2004-11-19 03:03:25-05:00, stenn@whimsy.udel.edu +31 -31 + scripts/monitoring/ntploopwatch@1.3 +31 -31 [Bug 341] Patches from Frank Kardel -ChangeSet@1.1251.1.19, 2004-11-18 23:20:44-05:00, mayer@tecotoo. +4 -0 +ChangeSet@1.1251.1.19, 2004-11-18 23:20:44-05:00, mayer@tecotoo. Miscellaneous Win32 fixes - ntpdc/ntpdc.c@1.36, 2004-11-18 23:15:41-05:00, mayer@tecotoo. +4 -1 + ntpdc/ntpdc.c@1.36 +4 -1 Win32 uses a slightly different prototype for qsort - ntpq/ntpq.c@1.51, 2004-11-18 23:15:40-05:00, mayer@tecotoo. +4 -1 + ntpq/ntpq.c@1.51 +4 -1 Win32 uses a slightly different prototype for qsort - ports/winnt/include/config.h@1.33, 2004-11-18 23:13:26-05:00, mayer@tecotoo. +12 -18 + ports/winnt/include/config.h@1.33 +12 -18 Code cleanup - eliminate duplicate entries - ports/winnt/ntpd/ntservice.c@1.3, 2004-11-18 23:14:20-05:00, mayer@tecotoo. +3 -3 + ports/winnt/ntpd/ntservice.c@1.3 +3 -3 Use main instead of ntpmain for entry -ChangeSet@1.1251.3.3, 2004-11-16 22:16:52-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.3.3, 2004-11-16 22:16:52-05:00, mayer@tecotoo. Recommit fix - ntpd/cmd_args.c@1.28, 2004-11-16 22:16:34-05:00, mayer@tecotoo. +1 -1 + ntpd/cmd_args.c@1.28 +1 -1 Recommit fix - ntpd/cmd_args.c@1.27, 2004-11-16 00:16:58-05:00, mayer@tecotoo. +0 -1 + ntpd/cmd_args.c@1.27 +0 -1 Remove obsolete windows specific code -ChangeSet@1.1251.3.2, 2004-11-16 00:13:54-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.3.2, 2004-11-16 00:13:54-05:00, mayer@tecotoo. cmd_args.c, cmd_Args.c: Remove obsolete windows specific code - ntpd/cmd_args.c@1.26, 2004-11-06 21:38:12-05:00, mayer@tecotoo. +0 -0 + ntpd/cmd_args.c@1.26 +0 -0 Remove obsolete windows specific code - ntpd/cmd_Args.c@1.25, 2004-11-06 21:36:28-05:00, mayer@tecotoo. +0 -0 + ntpd/cmd_Args.c@1.25 +0 -0 Remove obsolete windows specific code - ntpd/cmd_args.c@1.24, 2004-11-06 21:34:23-05:00, mayer@tecotoo. +0 -7 + ntpd/cmd_args.c@1.24 +0 -7 Remove obsolete windows specific code -ChangeSet@1.1251.1.17, 2004-11-15 23:32:18-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.17, 2004-11-15 23:32:18-05:00, mayer@pogo.udel.edu John Hays burst mode fix for multicast - ntpd/ntp_proto.c@1.187.1.1, 2004-11-15 23:32:00-05:00, mayer@pogo.udel.edu +2 -0 + ntpd/ntp_proto.c@1.187.1.1 +2 -0 John Hays burst mode fix for multicast -ChangeSet@1.1251.3.1, 2004-11-15 23:24:51-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.3.1, 2004-11-15 23:24:51-05:00, mayer@tecotoo. John Hays burst mode fix for multicast - ntpd/ntp_proto.c@1.188, 2004-11-15 23:24:20-05:00, mayer@tecotoo. +2 -0 + ntpd/ntp_proto.c@1.188 +2 -0 John Hays burst mode fix for multicast -ChangeSet@1.1251.1.16, 2004-11-15 23:14:53-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1251.1.16, 2004-11-15 23:14:53-05:00, mayer@pogo.udel.edu Force the update. Refuses on Windows. Remove NoWinService code - ntpd/cmd_args.c@1.23.1.1, 2004-11-15 23:14:24-05:00, mayer@pogo.udel.edu +0 -8 + ntpd/cmd_args.c@1.23.1.1 +0 -8 Force the update. Refuses on Windows. Remove NoWinService code -ChangeSet@1.1251.1.15, 2004-11-15 20:45:45-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.15, 2004-11-15 20:45:45-05:00, mayer@tecotoo. findbcastinter should be using INT_BCASTOPEN flag - ntpd/ntp_io.c@1.147, 2004-11-15 20:45:12-05:00, mayer@tecotoo. +2 -2 + ntpd/ntp_io.c@1.147 +2 -2 findbcastinter should be using INT_BCASTOPEN flag -ChangeSet@1.1251.1.14, 2004-11-14 22:42:23-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1251.1.14, 2004-11-14 22:42:23-05:00, mayer@tecotoo. Added debugging code to track multicast issues - ntpd/ntp_io.c@1.146, 2004-11-14 22:41:46-05:00, mayer@tecotoo. +15 -1 + ntpd/ntp_io.c@1.146 +15 -1 Added debugging code to track multicast issues - ntpd/ntp_peer.c@1.65, 2004-11-14 22:41:48-05:00, mayer@tecotoo. +6 -0 + ntpd/ntp_peer.c@1.65 +6 -0 Added debugging code to track multicast issues -ChangeSet@1.1251.1.13, 2004-11-12 20:39:57-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.13, 2004-11-12 20:39:57-05:00, mayer@tecotoo. Add debugging information - ntpd/ntp_proto.c@1.187, 2004-11-12 20:39:35-05:00, mayer@tecotoo. +3 -0 + ntpd/ntp_proto.c@1.187 +3 -0 Add debugging information -ChangeSet@1.1251.1.12, 2004-11-12 20:39:10-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.12, 2004-11-12 20:39:10-05:00, mayer@tecotoo. Only enable broadcast for servers - ntpd/ntp_peer.c@1.64, 2004-11-12 20:38:48-05:00, mayer@tecotoo. +1 -1 + ntpd/ntp_peer.c@1.64 +1 -1 Only enable broadcast for servers -ChangeSet@1.1251.1.11, 2004-11-12 20:34:52-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1251.1.11, 2004-11-12 20:34:52-05:00, mayer@tecotoo. Need both windows.h and winsock2.h for VC 6.0 - ports/winnt/include/config.h@1.32, 2004-11-12 20:34:18-05:00, mayer@tecotoo. +1 -1 + ports/winnt/include/config.h@1.32 +1 -1 Need both windows.h and winsock2.h for VC 6.0 -ChangeSet@1.1251.2.2, 2004-11-09 22:05:28-05:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1251.2.2, 2004-11-09 22:05:28-05:00, mayer@tecotoo. Move code to windows specific files - ntpd/ntpd.c@1.59.1.1, 2004-11-09 22:02:06-05:00, mayer@tecotoo. +3 -56 + ntpd/ntpd.c@1.59.1.1 +3 -56 Remove Windows code from ntpd.c into nt_clockstuff.c - ports/winnt/ntpd/nt_clockstuff.c@1.16, 2004-11-09 22:02:16-05:00, mayer@tecotoo. +15 -0 + ports/winnt/ntpd/nt_clockstuff.c@1.16 +15 -0 Remove Windows code from ntpd.c into nt_clockstuff.c - ports/winnt/ntpd/ntpd.dsp@1.25, 2004-11-09 22:01:05-05:00, mayer@tecotoo. +0 -5 + ports/winnt/ntpd/ntpd.dsp@1.25 +0 -5 Remove ntp_iopackets.c from compile list. Not ready -ChangeSet@1.1251.1.9, 2004-11-09 04:38:42-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.9, 2004-11-09 04:38:42-05:00, stenn@whimsy.udel.edu re-enable the first call to getstartup() - ntpd/ntpd.c@1.60, 2004-11-09 04:38:29-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd.c@1.60 +1 -1 re-enable the first call to getstartup() -ChangeSet@1.1250.1.4, 2004-11-08 23:08:38-05:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1250.1.4, 2004-11-08 23:08:38-05:00, mayer@tecotoo. Fixes forInclude paths and extraneous windows code - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.8, 2004-11-08 23:07:36-05:00, mayer@tecotoo. +1 -1 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.8 +1 -1 Fix include paths - ports/winnt/ntpdate/ntpdate.dsp@1.14, 2004-11-08 23:07:36-05:00, mayer@tecotoo. +2 -2 + ports/winnt/ntpdate/ntpdate.dsp@1.14 +2 -2 Fix include paths - ports/winnt/ntpq/ntpq.dsp@1.17, 2004-11-08 23:07:37-05:00, mayer@tecotoo. +1 -1 + ports/winnt/ntpq/ntpq.dsp@1.17 +1 -1 Fix include paths -ChangeSet@1.1251.1.7, 2004-11-08 01:02:59-05:00, stenn@pogo.udel.edu +3 -0 +ChangeSet@1.1251.1.7, 2004-11-08 01:02:59-05:00, stenn@pogo.udel.edu [sntp] Lint removal - sntp/internet.c@1.4, 2004-11-08 01:02:36-05:00, stenn@pogo.udel.edu +10 -22 + sntp/internet.c@1.4 +10 -22 Lint removal - sntp/internet.h@1.3, 2004-11-08 01:02:36-05:00, stenn@pogo.udel.edu +2 -2 + sntp/internet.h@1.3 +2 -2 Lint removal - sntp/socket.c@1.5, 2004-11-08 01:02:36-05:00, stenn@pogo.udel.edu +4 -8 + sntp/socket.c@1.5 +4 -8 Lint removal -ChangeSet@1.1251.1.5, 2004-11-07 17:14:12-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.5, 2004-11-07 17:14:12-05:00, stenn@whimsy.udel.edu [Bug 344] Handle some corner cases better - bincheck.mf@1.2, 2004-11-07 17:14:00-05:00, stenn@whimsy.udel.edu +3 -2 + bincheck.mf@1.2 +3 -2 [Bug 344] Handle some corner cases better -ChangeSet@1.1251.1.4, 2004-11-07 04:13:44-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1251.1.4, 2004-11-07 04:13:44-05:00, stenn@whimsy.udel.edu AM_CPPFLAGS needed for nl.c - ntpdc/Makefile.am@1.23, 2004-11-07 04:13:14-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/Makefile.am@1.23 +2 -2 AM_CPPFLAGS needed for nl.c -ChangeSet@1.1251.1.3, 2004-11-07 03:01:26-05:00, stenn@pogo.udel.edu +9 -0 +ChangeSet@1.1251.1.3, 2004-11-07 03:01:26-05:00, stenn@pogo.udel.edu [Bug 344] Allow daemons to be installed in sbin - adjtimed/Makefile.am@1.3, 2004-11-07 03:00:37-05:00, stenn@pogo.udel.edu +10 -8 + adjtimed/Makefile.am@1.3 +10 -8 [Bug 344] Allow daemons to be installed in sbin - bincheck.mf@1.1, 2004-11-07 02:56:30-05:00, stenn@pogo.udel.edu +14 -0 + bincheck.mf@1.1 +14 -0 - bincheck.mf@1.0, 2004-11-07 02:56:30-05:00, stenn@pogo.udel.edu +0 -0 + bincheck.mf@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev/bincheck.mf - configure.ac@1.359.1.1, 2004-11-07 03:00:02-05:00, stenn@pogo.udel.edu +21 -2 + configure.ac@1.359.1.1 +21 -2 [Bug 344] Allow daemons to be installed in sbin - ntpd/Makefile.am@1.39, 2004-11-07 03:00:02-05:00, stenn@pogo.udel.edu +17 -9 + ntpd/Makefile.am@1.39 +17 -9 [Bug 344] Allow daemons to be installed in sbin - ntpdate/Makefile.am@1.12, 2004-11-07 03:00:02-05:00, stenn@pogo.udel.edu +15 -12 + ntpdate/Makefile.am@1.12 +15 -12 [Bug 344] Allow daemons to be installed in sbin - ntpdc/Makefile.am@1.22, 2004-11-07 03:00:02-05:00, stenn@pogo.udel.edu +6 -3 + ntpdc/Makefile.am@1.22 +6 -3 [Bug 344] Allow daemons to be installed in sbin - ntpq/Makefile.am@1.12, 2004-11-07 03:00:37-05:00, stenn@pogo.udel.edu +10 -10 + ntpq/Makefile.am@1.12 +10 -10 [Bug 344] Allow daemons to be installed in sbin - sntp/Makefile.am@1.6, 2004-11-07 03:00:02-05:00, stenn@pogo.udel.edu +4 -1 + sntp/Makefile.am@1.6 +4 -1 [Bug 344] Allow daemons to be installed in sbin - sntp/configure.ac@1.8, 2004-11-07 03:00:02-05:00, stenn@pogo.udel.edu +18 -0 + sntp/configure.ac@1.8 +18 -0 [Bug 344] Allow daemons to be installed in sbin -ChangeSet@1.1249.1.11, 2004-11-06 21:43:44-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1249.1.11, 2004-11-06 21:43:44-05:00, mayer@tecotoo. Miscellaneous - include/recvbuff.h@1.8, 2004-11-06 21:42:39-05:00, mayer@tecotoo. +1 -0 + include/recvbuff.h@1.8 +1 -0 Add flags about the received packet - ports/winnt/libntp/syslog.c@1.3, 2004-11-06 21:43:16-05:00, mayer@tecotoo. +2 -1 + ports/winnt/libntp/syslog.c@1.3 +2 -1 modifed variable definition -ChangeSet@1.1249.1.10, 2004-11-06 21:36:41-05:00, mayer@tecotoo. +8 -0 +ChangeSet@1.1249.1.10, 2004-11-06 21:36:41-05:00, mayer@tecotoo. Updates to move windows-specific code into the windows-specific files - ntpd/ntp_config.c@1.113, 2004-11-06 21:35:04-05:00, mayer@tecotoo. +1 -1 + ntpd/ntp_config.c@1.113 +1 -1 Remove obsolete windows specific code - ntpd/ntpd.c@1.57.1.1, 2004-11-06 21:26:26-05:00, mayer@tecotoo. +16 -155 + ntpd/ntpd.c@1.57.1.1 +16 -155 Remove Windows specific code. Put in other files - ports/winnt/include/clockstuff.h@1.6, 2004-11-06 21:32:48-05:00, mayer@tecotoo. +1 -0 + ports/winnt/include/clockstuff.h@1.6 +1 -0 Move Console setup and service setup to nt_clockstuff.c - ports/winnt/include/ntp_iocompletionport.h@1.8, 2004-11-06 21:28:49-05:00, mayer@tecotoo. +2 -0 + ports/winnt/include/ntp_iocompletionport.h@1.8 +2 -0 Move completion events from ntpd.c to ntp_iocompletionport.c - ports/winnt/include/ntservice.h@1.2, 2004-11-06 21:30:09-05:00, mayer@tecotoo. +1 -0 + ports/winnt/include/ntservice.h@1.2 +1 -0 Move Console setup to ntservice - ports/winnt/ntpd/nt_clockstuff.c@1.15, 2004-11-06 21:32:49-05:00, mayer@tecotoo. +35 -15 + ports/winnt/ntpd/nt_clockstuff.c@1.15 +35 -15 Move Console setup and service setup to nt_clockstuff.c - ports/winnt/ntpd/ntp_iocompletionport.c@1.13, 2004-11-06 21:28:49-05:00, mayer@tecotoo. +46 -0 + ports/winnt/ntpd/ntp_iocompletionport.c@1.13 +46 -0 Move completion events from ntpd.c to ntp_iocompletionport.c - ports/winnt/ntpd/ntservice.c@1.2, 2004-11-06 21:30:09-05:00, mayer@tecotoo. +70 -17 + ports/winnt/ntpd/ntservice.c@1.2 +70 -17 Move Console setup to ntservice -ChangeSet@1.1250.1.2, 2004-11-06 04:13:33-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1250.1.2, 2004-11-06 04:13:33-05:00, stenn@whimsy.udel.edu lint - ntpd/ntpd.c@1.58, 2004-11-06 04:13:21-05:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntpd.c@1.58 +0 -1 lint -ChangeSet@1.1249.1.9, 2004-11-04 00:03:35-05:00, mayer@tecotoo. +6 -0 +ChangeSet@1.1249.1.9, 2004-11-04 00:03:35-05:00, mayer@tecotoo. Prefix constants with NTP_ to avoid collisions with VS.NET - ntpdc/ntpdc.c@1.35, 2004-11-04 00:02:40-05:00, mayer@tecotoo. +9 -8 + ntpdc/ntpdc.c@1.35 +9 -8 Prefix constants with NTP_ to avoid collisions with VS.NET - ntpdc/ntpdc.h@1.4, 2004-11-04 00:02:41-05:00, mayer@tecotoo. +7 -7 + ntpdc/ntpdc.h@1.4 +7 -7 Prefix constants with NTP_ to avoid collisions with VS.NET - ntpdc/ntpdc_ops.c@1.37, 2004-11-04 00:02:42-05:00, mayer@tecotoo. +21 -21 + ntpdc/ntpdc_ops.c@1.37 +21 -21 Prefix constants with NTP_ to avoid collisions with VS.NET - ntpq/ntpq.c@1.50, 2004-11-04 00:03:08-05:00, mayer@tecotoo. +18 -17 + ntpq/ntpq.c@1.50 +18 -17 Prefix constants with NTP_ to avoid collisions with VS.NET - ntpq/ntpq.h@1.4, 2004-11-04 00:03:08-05:00, mayer@tecotoo. +10 -7 + ntpq/ntpq.h@1.4 +10 -7 Prefix constants with NTP_ to avoid collisions with VS.NET - ntpq/ntpq_ops.c@1.20.1.1, 2004-11-04 00:03:09-05:00, mayer@tecotoo. +17 -17 + ntpq/ntpq_ops.c@1.20.1.1 +17 -17 Prefix constants with NTP_ to avoid collisions with VS.NET -ChangeSet@1.1202.1.47, 2004-11-03 02:43:58-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1202.1.47, 2004-11-03 02:43:58-05:00, stenn@pogo.udel.edu autogen - configure.ac@1.351.1.10, 2004-11-03 02:40:39-05:00, stenn@pogo.udel.edu +2 -0 + configure.ac@1.351.1.10 +2 -0 autogen - ntpq/ntpq-subs.c@1.21, 2004-10-30 17:25:09-04:00, stenn@pogo.udel.edu +0 -0 + ntpq/ntpq-subs.c@1.21 +0 -0 Rename: ntpq/ntpq_ops.c -> ntpq/ntpq-subs.c -ChangeSet@1.1251, 2004-11-03 01:51:42-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1251, 2004-11-03 01:51:42-05:00, stenn@pogo.udel.edu Disable mlockall() under linux for now - resolver problems. - configure.ac@1.359, 2004-11-03 01:51:29-05:00, stenn@pogo.udel.edu +3 -0 + configure.ac@1.359 +3 -0 Disable mlockall() under linux for now - resolver problems. -ChangeSet@1.1249.1.8, 2004-11-02 23:25:17-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1249.1.8, 2004-11-02 23:25:17-05:00, mayer@tecotoo. Moved NT Services to it's own file - ntpd/ntpd.c@1.57, 2004-11-02 23:24:59-05:00, mayer@tecotoo. +56 -151 + ntpd/ntpd.c@1.57 +56 -151 Moved NT Services to it's own file -ChangeSet@1.1249.1.7, 2004-11-02 23:23:49-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1249.1.7, 2004-11-02 23:23:49-05:00, mayer@tecotoo. Changes to support VS.NET - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.7, 2004-11-02 23:23:25-05:00, mayer@tecotoo. +4 -4 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.7 +4 -4 Changes to support VS.NET -ChangeSet@1.1249.1.6, 2004-11-02 23:22:53-05:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1249.1.6, 2004-11-02 23:22:53-05:00, mayer@tecotoo. Changes to support VS.NET - ports/winnt/include/isc/ipv6.h@1.4, 2004-11-02 23:22:24-05:00, mayer@tecotoo. +15 -3 + ports/winnt/include/isc/ipv6.h@1.4 +15 -3 Changes to support VS.NET - ports/winnt/include/isc/net.h@1.4, 2004-11-02 23:18:10-05:00, mayer@tecotoo. +4 -2 + ports/winnt/include/isc/net.h@1.4 +4 -2 Changes to support VS.NET - ports/winnt/libisc/net.c@1.5, 2004-11-02 23:18:10-05:00, mayer@tecotoo. +2 -0 + ports/winnt/libisc/net.c@1.5 +2 -0 Changes to support VS.NET -ChangeSet@1.1249.1.5, 2004-11-02 23:15:30-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1249.1.5, 2004-11-02 23:15:30-05:00, mayer@tecotoo. Changes to support VS.NET - ports/winnt/include/config.h@1.31, 2004-11-02 23:15:16-05:00, mayer@tecotoo. +44 -6 + ports/winnt/include/config.h@1.31 +44 -6 Changes to support VS.NET -ChangeSet@1.1249.1.4, 2004-11-02 23:14:21-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1249.1.4, 2004-11-02 23:14:21-05:00, mayer@tecotoo. NT Services for NTP - ports/winnt/include/ntservice.h@1.1, 2004-11-02 23:13:56-05:00, mayer@tecotoo. +34 -0 + ports/winnt/include/ntservice.h@1.1 +34 -0 NT Services for NTP - ports/winnt/include/ntservice.h@1.0, 2004-11-02 23:13:56-05:00, mayer@tecotoo. +0 -0 + ports/winnt/include/ntservice.h@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/ports/winnt/include/ntservice.h - ports/winnt/ntpd/ntservice.c@1.1, 2004-11-02 23:13:56-05:00, mayer@tecotoo. +241 -0 + ports/winnt/ntpd/ntservice.c@1.1 +241 -0 NT Services for NTP - ports/winnt/ntpd/ntservice.c@1.0, 2004-11-02 23:13:56-05:00, mayer@tecotoo. +0 -0 + ports/winnt/ntpd/ntservice.c@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/ports/winnt/ntpd/ntservice.c -ChangeSet@1.1249.1.3, 2004-11-02 23:07:27-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1249.1.3, 2004-11-02 23:07:27-05:00, mayer@tecotoo. Redefine various error functions for win32 - ports/winnt/libisc/isc_strerror.c@1.4, 2004-11-02 23:07:08-05:00, mayer@tecotoo. +8 -8 + ports/winnt/libisc/isc_strerror.c@1.4 +8 -8 Redefine various error functions for win32 -ChangeSet@1.1249.1.2, 2004-11-02 23:05:22-05:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1249.1.2, 2004-11-02 23:05:22-05:00, mayer@tecotoo. Remove unnecessary time variable references - libntp/mktime.c@1.7, 2004-11-02 23:04:56-05:00, mayer@tecotoo. +3 -5 + libntp/mktime.c@1.7 +3 -5 Remove unnecessary time variable references - libntp/ranny.c@1.3, 2004-11-02 23:04:56-05:00, mayer@tecotoo. +0 -2 + libntp/ranny.c@1.3 +0 -2 Remove unnecessary time variable references - ports/winnt/ntpd/nt_clockstuff.c@1.14, 2004-11-02 23:04:57-05:00, mayer@tecotoo. +25 -27 + ports/winnt/ntpd/nt_clockstuff.c@1.14 +25 -27 Remove unnecessary time variable references -ChangeSet@1.1249.1.1, 2004-11-02 23:02:31-05:00, mayer@tecotoo. +5 -0 +ChangeSet@1.1249.1.1, 2004-11-02 23:02:31-05:00, mayer@tecotoo. Updates to support changes required for VS.NET - ports/winnt/libntp/libntp.dsp@1.23, 2004-11-02 23:01:14-05:00, mayer@tecotoo. +4 -7 + ports/winnt/libntp/libntp.dsp@1.23 +4 -7 Updates to support changes required for VS.NET - ports/winnt/ntpd/ntpd.dsp@1.24, 2004-11-02 23:01:25-05:00, mayer@tecotoo. +40 -4 + ports/winnt/ntpd/ntpd.dsp@1.24 +40 -4 Updates to support changes required for VS.NET - ports/winnt/ntpdate/ntpdate.dsp@1.13, 2004-11-02 23:01:44-05:00, mayer@tecotoo. +2 -2 + ports/winnt/ntpdate/ntpdate.dsp@1.13 +2 -2 Updates to support changes required for VS.NET - ports/winnt/ntpdc/ntpdc.dsp@1.16, 2004-11-02 23:01:33-05:00, mayer@tecotoo. +2 -2 + ports/winnt/ntpdc/ntpdc.dsp@1.16 +2 -2 Updates to support changes required for VS.NET - ports/winnt/ntpq/ntpq.dsp@1.16, 2004-11-02 23:01:54-05:00, mayer@tecotoo. +2 -2 + ports/winnt/ntpq/ntpq.dsp@1.16 +2 -2 Updates to support changes required for VS.NET -ChangeSet@1.1249, 2004-11-01 23:46:20-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1249, 2004-11-01 23:46:20-05:00, mayer@tecotoo. Mulitcast IPv6 check - ntpd/ntp_io.c@1.145, 2004-11-01 23:46:00-05:00, mayer@tecotoo. +2 -3 + ntpd/ntp_io.c@1.145 +2 -3 Mulitcast IPv6 check -ChangeSet@1.1247, 2004-11-01 23:03:40-05:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1247, 2004-11-01 23:03:40-05:00, mayer@tecotoo. IPv6 fixes and Added dump of interface function - include/ntpd.h@1.71, 2004-11-01 23:01:45-05:00, mayer@tecotoo. +1 -0 + include/ntpd.h@1.71 +1 -0 Added dump of interface function - ntpd/ntp_config.c@1.109.1.1, 2004-11-01 22:59:30-05:00, mayer@tecotoo. +41 -20 + ntpd/ntp_config.c@1.109.1.1 +41 -20 Fix for IPv6 - ntpd/ntp_intres.c@1.35.1.1, 2004-11-01 22:59:29-05:00, mayer@tecotoo. +22 -2 + ntpd/ntp_intres.c@1.35.1.1 +22 -2 Fix for IPv6 -ChangeSet@1.1246, 2004-11-01 22:55:10-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1246, 2004-11-01 22:55:10-05:00, mayer@tecotoo. Fix multicast to open it's own socket. Fall back on wildcard if it fails - ntpd/ntp_io.c@1.143, 2004-11-01 22:54:41-05:00, mayer@tecotoo. +287 -494 + ntpd/ntp_io.c@1.143 +287 -494 Fix multicast to open it's own socket. Fall back on wildcard if it fails -ChangeSet@1.1202.5.10, 2004-10-31 16:23:23-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.5.10, 2004-10-31 16:23:23-05:00, stenn@whimsy.udel.edu PTB responses are 78 bytes long, not 40. - ntpd/refclock_acts.c@1.15, 2004-10-31 16:23:09-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_acts.c@1.15 +1 -1 PTB responses are 78 bytes long, not 40. -ChangeSet@1.1202.5.8, 2004-10-29 22:56:12-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1202.5.8, 2004-10-29 22:56:12-04:00, mayer@pogo.udel.edu Should have used ISC_R_SUCCESS and not ISC_TRUE for return from isc_net_probeipv6(). Don't allow IPv6 addreses when no IPv6 available - ntpd/ntp_config.c@1.111, 2004-10-29 22:55:08-04:00, mayer@pogo.udel.edu +36 -22 + ntpd/ntp_config.c@1.111 +36 -22 Should have used ISC_R_SUCCESS and not ISC_TRUE for return from isc_net_probeipv6(). Don't allow IPv6 addreses when no IPv6 available - ntpd/ntp_intres.c@1.37, 2004-10-29 22:54:13-04:00, mayer@pogo.udel.edu +4 -4 + ntpd/ntp_intres.c@1.37 +4 -4 Should have used ISC_R_SUCCESS and not ISC_TRUE for return from isc_net_probeipv6() -ChangeSet@1.1202.7.1, 2004-10-29 05:52:47-04:00, stenn@whimsy.udel.edu +10 -0 +ChangeSet@1.1202.7.1, 2004-10-29 05:52:47-04:00, stenn@whimsy.udel.edu Updates from Dave Mills - html/build/hints.html@1.15, 2004-10-29 05:51:12-04:00, stenn@whimsy.udel.edu +1 -1 + html/build/hints.html@1.15 +1 -1 Updates from Dave Mills - html/build/hints/solaris-dosynctodr.html@1.5, 2004-10-29 05:51:13-04:00, stenn@whimsy.udel.edu +11 -11 + html/build/hints/solaris-dosynctodr.html@1.5 +11 -11 Updates from Dave Mills - html/drivers/driver18.html@1.12, 2004-10-29 05:51:15-04:00, stenn@whimsy.udel.edu +44 -49 + html/drivers/driver18.html@1.12 +44 -49 Updates from Dave Mills - html/drivers/driver29.html@1.13, 2004-10-29 05:51:15-04:00, stenn@whimsy.udel.edu +1 -1 + html/drivers/driver29.html@1.13 +1 -1 Updates from Dave Mills - html/drivers/driver38.html@1.12, 2004-10-29 05:51:16-04:00, stenn@whimsy.udel.edu +3 -3 + html/drivers/driver38.html@1.12 +3 -3 Updates from Dave Mills - html/drivers/driver39.html@1.12, 2004-10-29 05:51:16-04:00, stenn@whimsy.udel.edu +3 -3 + html/drivers/driver39.html@1.12 +3 -3 Updates from Dave Mills - html/drivers/driver44.html@1.11, 2004-10-29 05:51:17-04:00, stenn@whimsy.udel.edu +3 -6 + html/drivers/driver44.html@1.11 +3 -6 Updates from Dave Mills - html/drivers/driver5.html@1.12, 2004-10-29 05:51:17-04:00, stenn@whimsy.udel.edu +1 -1 + html/drivers/driver5.html@1.12 +1 -1 Updates from Dave Mills - html/drivers/driver8.html@1.14, 2004-10-29 05:51:17-04:00, stenn@whimsy.udel.edu +1 -1 + html/drivers/driver8.html@1.14 +1 -1 Updates from Dave Mills - html/ntpd.html@1.34, 2004-10-29 05:51:10-04:00, stenn@whimsy.udel.edu +5 -8 + html/ntpd.html@1.34 +5 -8 Updates from Dave Mills -ChangeSet@1.1202.6.1, 2004-10-28 20:49:19-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1202.6.1, 2004-10-28 20:49:19-04:00, mayer@pogo.udel.edu Ensure that DNS lookups on IPv6-absent systems only look up IPv4 addresses - ntpd/ntp_config.c@1.110, 2004-10-28 20:48:42-04:00, mayer@pogo.udel.edu +7 -0 + ntpd/ntp_config.c@1.110 +7 -0 Ensure that DNS lookups on IPv6-absent systems only look up IPv4 addresses - ntpd/ntp_intres.c@1.36, 2004-10-28 20:48:43-04:00, mayer@pogo.udel.edu +21 -1 + ntpd/ntp_intres.c@1.36 +21 -1 Ensure that DNS lookups on IPv6-absent systems only look up IPv4 addresses -ChangeSet@1.1202.5.6, 2004-10-27 19:52:51-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1202.5.6, 2004-10-27 19:52:51-04:00, stenn@whimsy.udel.edu Updates from Dave Mills - html/copyright.html@1.28, 2004-10-27 19:52:28-04:00, stenn@whimsy.udel.edu +2 -2 + html/copyright.html@1.28 +2 -2 Updates from Dave Mills - html/drivers/footer.txt@1.1, 2004-10-27 19:50:59-04:00, stenn@whimsy.udel.edu +7 -0 + html/drivers/footer.txt@1.1 +7 -0 - html/drivers/footer.txt@1.0, 2004-10-27 19:50:59-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/footer.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/drivers/footer.txt - html/drivers/tf582_4.html@1.1, 2004-10-27 19:50:59-04:00, stenn@whimsy.udel.edu +72 -0 + html/drivers/tf582_4.html@1.1 +72 -0 - html/drivers/tf582_4.html@1.0, 2004-10-27 19:50:59-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/tf582_4.html@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/drivers/tf582_4.html - html/keygen.html@1.5, 2004-10-27 19:52:28-04:00, stenn@whimsy.udel.edu +1 -1 + html/keygen.html@1.5 +1 -1 Updates from Dave Mills - html/ntpd.html@1.33, 2004-10-27 19:52:30-04:00, stenn@whimsy.udel.edu +1 -1 + html/ntpd.html@1.33 +1 -1 Updates from Dave Mills - html/refclock.html@1.30, 2004-10-27 19:52:28-04:00, stenn@whimsy.udel.edu +8 -6 + html/refclock.html@1.30 +8 -6 Updates from Dave Mills -ChangeSet@1.1202.5.5, 2004-10-26 20:25:31-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.5.5, 2004-10-26 20:25:31-04:00, stenn@whimsy.udel.edu Remove mort from the backroom auto-build list - br-flock@1.5, 2004-10-26 20:25:19-04:00, stenn@whimsy.udel.edu +1 -1 + br-flock@1.5 +1 -1 Remove mort from the backroom auto-build list -ChangeSet@1.1202.4.5, 2004-10-24 22:46:38-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.4.5, 2004-10-24 22:46:38-04:00, mayer@pogo.udel.edu Add interface_dump functionality - include/ntpd.h@1.69.1.1, 2004-10-24 22:46:22-04:00, mayer@pogo.udel.edu +1 -0 + include/ntpd.h@1.69.1.1 +1 -0 Add interface_dump functionality -ChangeSet@1.1202.4.4, 2004-10-24 22:45:54-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.4.4, 2004-10-24 22:45:54-04:00, mayer@pogo.udel.edu Add interface_dump functionality - ntpd/ntp_io.c@1.119.1.5, 2004-10-24 22:45:35-04:00, mayer@pogo.udel.edu +58 -0 + ntpd/ntp_io.c@1.119.1.5 +58 -0 Add interface_dump functionality -ChangeSet@1.1202.4.3, 2004-10-24 22:44:25-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.4.3, 2004-10-24 22:44:25-04:00, mayer@pogo.udel.edu Remove interface_dump - ntpd/ntp_control.c@1.70.1.4, 2004-10-24 22:43:43-04:00, mayer@pogo.udel.edu +0 -1 + ntpd/ntp_control.c@1.70.1.4 +0 -1 Remove interface_dump -ChangeSet@1.1202.4.2, 2004-10-24 22:42:51-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.4.2, 2004-10-24 22:42:51-04:00, mayer@pogo.udel.edu Don't allow null interfaces - ntpd/ntp_peer.c@1.60.1.1, 2004-10-24 22:42:12-04:00, mayer@pogo.udel.edu +8 -0 + ntpd/ntp_peer.c@1.60.1.1 +8 -0 Don't allow null interfaces -ChangeSet@1.1245, 2004-10-24 22:37:46-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1245, 2004-10-24 22:37:46-04:00, mayer@tecotoo. Don't allow null interfaces - ntpd/ntp_peer.c@1.62, 2004-10-24 22:37:27-04:00, mayer@tecotoo. +8 -0 + ntpd/ntp_peer.c@1.62 +8 -0 Don't allow null interfaces -ChangeSet@1.1202.5.3, 2004-10-23 03:25:29-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.5.3, 2004-10-23 03:25:29-04:00, stenn@whimsy.udel.edu sntp can be installed in sbin - sntp/Makefile.am@1.5, 2004-10-23 03:25:14-04:00, stenn@whimsy.udel.edu +1 -1 + sntp/Makefile.am@1.5 +1 -1 sntp can be installed in sbin -ChangeSet@1.1202.5.2, 2004-10-23 03:09:05-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1202.5.2, 2004-10-23 03:09:05-04:00, stenn@whimsy.udel.edu Lose broadcast and server modes from sntp. - sntp/README@1.2, 2004-10-23 03:07:46-04:00, stenn@whimsy.udel.edu +28 -27 + sntp/README@1.2 +28 -27 Lose broadcast and server modes. - sntp/draft-mills-sntp-v4-00.txt@1.1, 2004-10-23 00:12:58-04:00, stenn@whimsy.udel.edu +1514 -0 + sntp/draft-mills-sntp-v4-00.txt@1.1 +1514 -0 - sntp/draft-mills-sntp-v4-00.txt@1.0, 2004-10-23 00:12:58-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/draft-mills-sntp-v4-00.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/sntp/draft-mills-sntp-v4-00.txt - sntp/header.h@1.6, 2004-10-23 03:07:45-04:00, stenn@whimsy.udel.edu +1 -3 + sntp/header.h@1.6 +1 -3 Lose broadcast and server modes. - sntp/main.c@1.5, 2004-10-23 03:07:45-04:00, stenn@whimsy.udel.edu +19 -115 + sntp/main.c@1.5 +19 -115 Lose broadcast and server modes. - sntp/sntp.1@1.4, 2004-10-23 03:07:46-04:00, stenn@whimsy.udel.edu +0 -23 + sntp/sntp.1@1.4 +0 -23 Lose broadcast and server modes. - sntp/socket.c@1.4, 2004-10-23 03:07:45-04:00, stenn@whimsy.udel.edu +6 -22 + sntp/socket.c@1.4 +6 -22 Lose broadcast and server modes. -ChangeSet@1.1202.5.1, 2004-10-23 00:09:11-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1202.5.1, 2004-10-23 00:09:11-04:00, stenn@whimsy.udel.edu Fixes from Dave Mills - ntpd/ntp_util.c@1.34, 2004-10-23 00:07:18-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_util.c@1.34 +1 -1 loopstats output cleanup - ntpd/refclock_atom.c@1.44, 2004-10-23 00:08:19-04:00, stenn@whimsy.udel.edu +1 -0 + ntpd/refclock_atom.c@1.44 +1 -0 Specify PPS_API_VERS_1 -ChangeSet@1.1202.1.42, 2004-10-19 21:26:34-04:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1202.1.42, 2004-10-19 21:26:34-04:00, stenn@pogo.udel.edu select() EINTR and mlockall() under linux problem avoidance. - configure.ac@1.351.1.9, 2004-10-19 21:25:15-04:00, stenn@pogo.udel.edu +3 -0 + configure.ac@1.351.1.9 +3 -0 Stop using mlockall() under linux - ntpd/ntpd.c@1.55.1.1, 2004-10-19 21:23:14-04:00, stenn@pogo.udel.edu +1 -1 + ntpd/ntpd.c@1.55.1.1 +1 -1 Only show the select() EINTR reports at debug >5 -ChangeSet@1.1202.1.41, 2004-10-18 00:37:02-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.41, 2004-10-18 00:37:02-04:00, stenn@whimsy.udel.edu lint fixes for refclock_mx4200.c - ntpd/refclock_mx4200.c@1.19, 2004-10-18 00:36:35-04:00, stenn@whimsy.udel.edu +3 -3 + ntpd/refclock_mx4200.c@1.19 +3 -3 lint -ChangeSet@1.1202.1.40, 2004-10-16 07:30:33-04:00, stenn@www.ntp.org +3 -0 +ChangeSet@1.1202.1.40, 2004-10-16 07:30:33-04:00, stenn@www.ntp.org Rename html2man.pl to html2man.in so we can use PATH_PERL. - configure.ac@1.351.1.8, 2004-10-16 07:28:54-04:00, stenn@www.ntp.org +1 -0 + configure.ac@1.351.1.8 +1 -0 Rename html2man.pl to html2man.in so we can use PATH_PERL. - scripts/Makefile.am@1.11, 2004-10-16 07:28:38-04:00, stenn@www.ntp.org +2 -2 + scripts/Makefile.am@1.11 +2 -2 Rename html2man.pl to html2man.in so we can use PATH_PERL. - scripts/html2man.in@1.5, 2004-10-16 07:28:39-04:00, stenn@www.ntp.org +4 -6 + scripts/html2man.in@1.5 +4 -6 Rename html2man.pl to html2man.in so we can use PATH_PERL. - scripts/html2man.in@1.4, 2004-10-16 06:50:52-04:00, stenn@www.ntp.org +0 -0 + scripts/html2man.in@1.4 +0 -0 Rename: scripts/html2man.pl -> scripts/html2man.in -ChangeSet@1.1202.1.39, 2004-10-16 06:19:50-04:00, stenn@www.ntp.org +1 -0 +ChangeSet@1.1202.1.39, 2004-10-16 06:19:50-04:00, stenn@www.ntp.org [Bug 348] genkeys -> keygen, and .htm -> .html - scripts/html2man.pl@1.3, 2004-10-16 06:19:02-04:00, stenn@www.ntp.org +2 -2 + scripts/html2man.pl@1.3 +2 -2 [Bug 348] genkeys -> keygen, and .htm -> .html -ChangeSet@1.1202.3.1, 2004-10-14 00:35:10-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.3.1, 2004-10-14 00:35:10-04:00, mayer@pogo.udel.edu Fix to broadcast. broadcast address socket was not being opened - ntpd/ntp_io.c@1.119.1.4, 2004-10-14 00:34:40-04:00, mayer@pogo.udel.edu +27 -9 + ntpd/ntp_io.c@1.119.1.4 +27 -9 Fix to broadcast. broadcast address socket was not being opened -ChangeSet@1.1202.1.37, 2004-10-12 21:08:44-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1202.1.37, 2004-10-12 21:08:44-04:00, stenn@whimsy.udel.edu Fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.100, 2004-10-12 21:08:25-04:00, stenn@whimsy.udel.edu +9 -15 + ntpd/ntp_loopfilter.c@1.100 +9 -15 Dave Mills: kernel cleanup - ntpd/ntp_proto.c@1.181.1.5, 2004-10-12 21:07:56-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.181.1.5 +1 -1 Dave Mills: If MCAST, turn off BURST as well. -ChangeSet@1.1244, 2004-10-10 19:46:59-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1244, 2004-10-10 19:46:59-04:00, mayer@tecotoo. Fix for refclock_open for Windows due to signature change (Again) - ports/winnt/include/win32_io.h@1.7, 2004-10-10 19:46:39-04:00, mayer@tecotoo. +1 -2 + ports/winnt/include/win32_io.h@1.7 +1 -2 Fix for refclock_open for Windows due to signature change (Again) -ChangeSet@1.1243, 2004-10-10 19:46:22-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1243, 2004-10-10 19:46:22-04:00, mayer@tecotoo. Add support for enable_broadcast() call for servers (Again) - ntpd/ntp_io.c@1.142, 2004-10-10 19:45:28-04:00, mayer@tecotoo. +2 -1 + ntpd/ntp_io.c@1.142 +2 -1 Add support for enable_broadcast() call for servers (Again) -ChangeSet@1.1241, 2004-10-10 19:10:18-04:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1241, 2004-10-10 19:10:18-04:00, mayer@tecotoo. Fix for refclock_open for Windows due to signature change - ports/winnt/include/win32_io.h@1.4.1.1, 2004-10-10 19:09:56-04:00, mayer@tecotoo. +1 -1 + ports/winnt/include/win32_io.h@1.4.1.1 +1 -1 Fix for refclock_open for Windows due to signature change - ports/winnt/ntpd/win32_io.c@1.9.1.1, 2004-10-10 19:09:56-04:00, mayer@tecotoo. +2 -2 + ports/winnt/ntpd/win32_io.c@1.9.1.1 +2 -2 Fix for refclock_open for Windows due to signature change -ChangeSet@1.1240, 2004-10-10 19:08:19-04:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1240, 2004-10-10 19:08:19-04:00, mayer@tecotoo. Add support for enable_broadcast() call for servers - include/ntpd.h@1.68.1.1, 2004-10-10 19:06:55-04:00, mayer@tecotoo. +4 -4 + include/ntpd.h@1.68.1.1 +4 -4 Add support for enable_broadcast() call for servers - ntpd/ntp_io.c@1.139.1.1, 2004-10-10 19:06:53-04:00, mayer@tecotoo. +21 -3 + ntpd/ntp_io.c@1.139.1.1 +21 -3 Add support for enable_broadcast() call for servers - ntpd/ntp_peer.c@1.59.1.1, 2004-10-10 19:06:54-04:00, mayer@tecotoo. +8 -0 + ntpd/ntp_peer.c@1.59.1.1 +8 -0 Add support for enable_broadcast() call for servers -ChangeSet@1.1202.1.36, 2004-10-08 22:24:44-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1202.1.36, 2004-10-08 22:24:44-04:00, stenn@whimsy.udel.edu Changes/cleanup from Dave Mills - ntpd/ntp_control.c@1.70.1.3, 2004-10-08 22:24:26-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_control.c@1.70.1.3 +1 -1 Changes/cleanup from Dave Mills - ntpd/ntp_loopfilter.c@1.99, 2004-10-08 22:24:27-04:00, stenn@whimsy.udel.edu +9 -12 + ntpd/ntp_loopfilter.c@1.99 +9 -12 Changes/cleanup from Dave Mills - ntpd/ntp_util.c@1.33, 2004-10-08 22:24:28-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_util.c@1.33 +2 -2 Changes/cleanup from Dave Mills -ChangeSet@1.1202.1.35, 2004-10-08 19:43:05-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.35, 2004-10-08 19:43:05-04:00, stenn@whimsy.udel.edu Dave Mills: No autokey over the wildcard interface - ntpd/ntp_proto.c@1.181.1.4, 2004-10-08 19:42:51-04:00, stenn@whimsy.udel.edu +17 -15 + ntpd/ntp_proto.c@1.181.1.4 +17 -15 Dave Mills: No autokey over the wildcard interface -ChangeSet@1.1202.1.34, 2004-10-07 22:49:19-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1202.1.34, 2004-10-07 22:49:19-04:00, mayer@pogo.udel.edu Win32 fix for refclock_open() signature change - ports/winnt/include/win32_io.h@1.5, 2004-10-07 22:48:58-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/include/win32_io.h@1.5 +1 -1 Win32 fix for refclock_open() signature change - ports/winnt/ntpd/win32_io.c@1.7.1.2, 2004-10-07 22:48:59-04:00, mayer@pogo.udel.edu +2 -2 + ports/winnt/ntpd/win32_io.c@1.7.1.2 +2 -2 Win32 fix for refclock_open() signature change -ChangeSet@1.1202.1.33, 2004-10-07 22:43:33-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.1.33, 2004-10-07 22:43:33-04:00, mayer@pogo.udel.edu Modification to have broadcast servers enable the socket for broadcast (missing argument) - ntpd/ntp_io.c@1.119.1.3, 2004-10-07 22:42:40-04:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_io.c@1.119.1.3 +1 -1 Modification to have broadcast servers enable the socket for broadcast (missing argument) -ChangeSet@1.1202.1.32, 2004-10-07 22:40:57-04:00, mayer@pogo.udel.edu +3 -0 +ChangeSet@1.1202.1.32, 2004-10-07 22:40:57-04:00, mayer@pogo.udel.edu Modification to have broadcast servers enable the socket for broadcast - include/ntpd.h@1.69, 2004-10-07 22:40:33-04:00, mayer@pogo.udel.edu +4 -4 + include/ntpd.h@1.69 +4 -4 Modification to have broadcast servers enable the socket for broadcast - ntpd/ntp_io.c@1.119.1.2, 2004-10-07 22:40:33-04:00, mayer@pogo.udel.edu +18 -0 + ntpd/ntp_io.c@1.119.1.2 +18 -0 Modification to have broadcast servers enable the socket for broadcast - ntpd/ntp_peer.c@1.60, 2004-10-07 22:40:33-04:00, mayer@pogo.udel.edu +8 -0 + ntpd/ntp_peer.c@1.60 +8 -0 Modification to have broadcast servers enable the socket for broadcast -ChangeSet@1.1202.1.31, 2004-10-06 22:21:10-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1202.1.31, 2004-10-06 22:21:10-04:00, stenn@whimsy.udel.edu Remove PTB and USNO lint - README.refclocks@1.3, 2004-10-06 22:20:56-04:00, stenn@whimsy.udel.edu +2 -2 + README.refclocks@1.3 +2 -2 Remove PTB and USNO lint - configure.ac@1.351.1.7, 2004-10-06 22:20:56-04:00, stenn@whimsy.udel.edu +0 -40 + configure.ac@1.351.1.7 +0 -40 Remove PTB and USNO lint -ChangeSet@1.1202.1.30, 2004-10-05 18:27:54-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1202.1.30, 2004-10-05 18:27:54-04:00, stenn@whimsy.udel.edu Cleanup from Dave Mills - ntpd/ntp_control.c@1.70.1.2, 2004-10-05 18:27:37-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_control.c@1.70.1.2 +2 -2 Cleanup from Dave Mills - ntpd/ntp_loopfilter.c@1.98, 2004-10-05 18:27:37-04:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntp_loopfilter.c@1.98 +4 -4 Cleanup from Dave Mills - ntpd/ntp_request.c@1.58, 2004-10-05 18:27:41-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_request.c@1.58 +1 -1 Cleanup from Dave Mills - ntpd/ntp_util.c@1.32, 2004-10-05 18:27:39-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_util.c@1.32 +2 -2 Cleanup from Dave Mills -ChangeSet@1.1202.1.29, 2004-10-02 03:56:39-04:00, stenn@whimsy.udel.edu +9 -0 +ChangeSet@1.1202.1.29, 2004-10-02 03:56:39-04:00, stenn@whimsy.udel.edu Cleanup from Dave Mills - include/ntp_refclock.h@1.17, 2004-10-02 03:54:54-04:00, stenn@whimsy.udel.edu +6 -4 + include/ntp_refclock.h@1.17 +6 -4 Cleanup from Dave Mills - include/ntpd.h@1.68, 2004-10-02 03:54:55-04:00, stenn@whimsy.udel.edu +0 -1 + include/ntpd.h@1.68 +0 -1 Cleanup from Dave Mills - ntpd/ntp_config.c@1.109, 2004-10-02 03:55:07-04:00, stenn@whimsy.udel.edu +4 -1 + ntpd/ntp_config.c@1.109 +4 -1 Cleanup from Dave Mills - ntpd/ntp_loopfilter.c@1.97, 2004-10-02 03:55:08-04:00, stenn@whimsy.udel.edu +37 -31 + ntpd/ntp_loopfilter.c@1.97 +37 -31 Cleanup from Dave Mills - ntpd/ntp_proto.c@1.181.1.3, 2004-10-02 03:55:09-04:00, stenn@whimsy.udel.edu +2 -5 + ntpd/ntp_proto.c@1.181.1.3 +2 -5 Cleanup from Dave Mills - ntpd/ntp_refclock.c@1.60, 2004-10-02 03:55:09-04:00, stenn@whimsy.udel.edu +205 -180 + ntpd/ntp_refclock.c@1.60 +205 -180 Cleanup from Dave Mills - ntpd/ntp_request.c@1.57, 2004-10-02 03:55:09-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_request.c@1.57 +2 -2 Cleanup from Dave Mills - ntpd/refclock_acts.c@1.14, 2004-10-02 03:55:10-04:00, stenn@whimsy.udel.edu +134 -72 + ntpd/refclock_acts.c@1.14 +134 -72 Cleanup from Dave Mills - ntpd/refclock_wwvb.c@1.13, 2004-10-02 03:55:13-04:00, stenn@whimsy.udel.edu +4 -11 + ntpd/refclock_wwvb.c@1.13 +4 -11 Cleanup from Dave Mills -ChangeSet@1.1202.1.28, 2004-09-22 23:23:06-04:00, mayer@pogo.udel.edu +5 -0 +ChangeSet@1.1202.1.28, 2004-09-22 23:23:06-04:00, mayer@pogo.udel.edu Fix the precompiled header issue - ports/winnt/libntp/libntp.dsp@1.18.1.1, 2004-09-22 23:22:41-04:00, mayer@pogo.udel.edu +13 -1 + ports/winnt/libntp/libntp.dsp@1.18.1.1 +13 -1 Fix the precompiled header issue - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.4.1.1, 2004-09-22 23:22:42-04:00, mayer@pogo.udel.edu +2 -2 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.4.1.1 +2 -2 Fix the precompiled header issue - ports/winnt/ntpd/ntpd.dsp@1.21.1.1, 2004-09-22 23:22:41-04:00, mayer@pogo.udel.edu +6 -2 + ports/winnt/ntpd/ntpd.dsp@1.21.1.1 +6 -2 Fix the precompiled header issue - ports/winnt/ntpdc/ntpdc.dsp@1.13.1.1, 2004-09-22 23:22:42-04:00, mayer@pogo.udel.edu +2 -2 + ports/winnt/ntpdc/ntpdc.dsp@1.13.1.1 +2 -2 Fix the precompiled header issue - ports/winnt/ntpq/ntpq.dsp@1.13.1.1, 2004-09-22 23:22:42-04:00, mayer@pogo.udel.edu +2 -2 + ports/winnt/ntpq/ntpq.dsp@1.13.1.1 +2 -2 Fix the precompiled header issue -ChangeSet@1.1202.1.27, 2004-09-22 23:21:56-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.1.27, 2004-09-22 23:21:56-04:00, mayer@pogo.udel.edu Add support for VS.NET (aka V7) and finally fix the RPC Async header issues - ports/winnt/include/config.h@1.26.1.1, 2004-09-22 23:21:29-04:00, mayer@pogo.udel.edu +9 -6 + ports/winnt/include/config.h@1.26.1.1 +9 -6 Add support for VS.NET (aka V7) and finally fix the RPC Async header issues -ChangeSet@1.1202.1.26, 2004-09-22 23:20:39-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.1.26, 2004-09-22 23:20:39-04:00, mayer@pogo.udel.edu total_buffs() and full_buffs() were returning the wrong value - libntp/recvbuff.c@1.8.1.1, 2004-09-22 23:20:07-04:00, mayer@pogo.udel.edu +2 -2 + libntp/recvbuff.c@1.8.1.1 +2 -2 total_buffs() and full_buffs() were returning the wrong value -ChangeSet@1.1238, 2004-09-22 23:19:14-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1238, 2004-09-22 23:19:14-04:00, mayer@tecotoo. total_buffs() and full_buffs() were returning the wrong value - libntp/recvbuff.c@1.9, 2004-09-22 23:18:57-04:00, mayer@tecotoo. +2 -2 + libntp/recvbuff.c@1.9 +2 -2 total_buffs() and full_buffs() were returning the wrong value -ChangeSet@1.1237, 2004-09-22 23:09:51-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1237, 2004-09-22 23:09:51-04:00, mayer@tecotoo. Add support for VS.NET (aka V7) and finally fix the RPC Async header issues - ports/winnt/include/config.h@1.29, 2004-09-22 23:09:16-04:00, mayer@tecotoo. +7 -6 + ports/winnt/include/config.h@1.29 +7 -6 Add support for VS.NET (aka V7) and finally fix the RPC Async header issues -ChangeSet@1.1236, 2004-09-22 00:40:32-04:00, mayer@tecotoo. +5 -0 +ChangeSet@1.1236, 2004-09-22 00:40:32-04:00, mayer@tecotoo. Fix the precompiled header issue - ports/winnt/libntp/libntp.dsp@1.21, 2004-09-22 00:40:02-04:00, mayer@tecotoo. +1 -1 + ports/winnt/libntp/libntp.dsp@1.21 +1 -1 Fix the precompiled header issue - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.5, 2004-09-22 00:40:03-04:00, mayer@tecotoo. +2 -2 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.5 +2 -2 Fix the precompiled header issue - ports/winnt/ntpd/ntpd.dsp@1.22, 2004-09-22 00:40:02-04:00, mayer@tecotoo. +6 -2 + ports/winnt/ntpd/ntpd.dsp@1.22 +6 -2 Fix the precompiled header issue - ports/winnt/ntpdc/ntpdc.dsp@1.14, 2004-09-22 00:40:03-04:00, mayer@tecotoo. +2 -2 + ports/winnt/ntpdc/ntpdc.dsp@1.14 +2 -2 Fix the precompiled header issue - ports/winnt/ntpq/ntpq.dsp@1.14, 2004-09-22 00:40:03-04:00, mayer@tecotoo. +2 -2 + ports/winnt/ntpq/ntpq.dsp@1.14 +2 -2 Fix the precompiled header issue -ChangeSet@1.1202.1.25, 2004-09-16 22:45:42-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.25, 2004-09-16 22:45:42-04:00, stenn@whimsy.udel.edu look for recvmsg() - configure.ac@1.351.1.6, 2004-09-16 22:45:32-04:00, stenn@whimsy.udel.edu +1 -1 + configure.ac@1.351.1.6 +1 -1 look for recvmsg() -ChangeSet@1.1202.1.24, 2004-09-13 22:31:34-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.24, 2004-09-13 22:31:34-04:00, stenn@whimsy.udel.edu Remove #undef UDP_WILDCARD_DELIVERY per Danny Mayer - ntpd/ntp_io.c@1.119.1.1, 2004-09-13 22:31:16-04:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntp_io.c@1.119.1.1 +0 -1 Remove #undef UDP_WILDCARD_DELIVERY per Danny Mayer -ChangeSet@1.1202.1.23, 2004-09-13 04:09:52-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.23, 2004-09-13 04:09:52-04:00, stenn@whimsy.udel.edu Dave Mills: flag3 chooses 1200 or 9600 baud. - ntpd/refclock_acts.c@1.13, 2004-09-13 04:09:38-04:00, stenn@whimsy.udel.edu +9 -4 + ntpd/refclock_acts.c@1.13 +9 -4 Dave Mills: flag3 chooses 1200 or 9600 baud. -ChangeSet@1.1202.1.22, 2004-09-12 16:53:03-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1202.1.22, 2004-09-12 16:53:03-04:00, stenn@whimsy.udel.edu more modem cleanup stuff - BitKeeper/deleted/.del-refclock_ptbacts.c~3e480692@1.3, 2004-09-12 16:44:28-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-refclock_ptbacts.c~3e480692@1.3 +0 -0 Delete: ntpd/refclock_ptbacts.c - BitKeeper/deleted/.del-refclock_usno.c~3aed0663@1.9, 2004-09-12 16:44:28-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-refclock_usno.c~3aed0663@1.9 +0 -0 Delete: ntpd/refclock_usno.c - ntpd/Makefile.am@1.38, 2004-09-12 16:47:56-04:00, stenn@whimsy.udel.edu +2 -2 + ntpd/Makefile.am@1.38 +2 -2 Remove the old ptbs and usno drivers - ntpd/refclock_acts.c@1.12, 2004-09-12 16:46:44-04:00, stenn@whimsy.udel.edu +23 -34 + ntpd/refclock_acts.c@1.12 +23 -34 cleanup and fixes from Dave Mills - ports/winnt/ntpd/ntpd.dsp@1.21, 2004-09-12 16:47:57-04:00, stenn@whimsy.udel.edu +0 -10 + ports/winnt/ntpd/ntpd.dsp@1.21 +0 -10 Remove the old ptbs and usno drivers -ChangeSet@1.1202.2.3, 2004-09-12 01:00:57-04:00, stenn@whimsy.udel.edu +10 -0 +ChangeSet@1.1202.2.3, 2004-09-12 01:00:57-04:00, stenn@whimsy.udel.edu Changes from Dave Mills. Combine/simplify the modem driver to handle ACTS, NIST, PTB, and USNO. - include/ntp.h@1.101.1.2, 2004-09-12 01:00:50-04:00, stenn@whimsy.udel.edu +5 -11 + include/ntp.h@1.101.1.2 +5 -11 Combine the modem refclocks into a single driver. Update the poll randomization stuff. - include/ntp_refclock.h@1.16, 2004-09-12 01:00:50-04:00, stenn@whimsy.udel.edu +2 -1 + include/ntp_refclock.h@1.16 +2 -1 Added refclock_timer(). - include/ntpd.h@1.67, 2004-09-12 01:00:50-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntpd.h@1.67 +1 -0 added refclock_timeout(). - libntp/clocktypes.c@1.16, 2004-09-12 01:00:51-04:00, stenn@whimsy.udel.edu +6 -6 + libntp/clocktypes.c@1.16 +6 -6 Use the new refclock_acts for NIST, PTB, USNO - ntpd/ntp_config.c@1.108, 2004-09-12 01:00:51-04:00, stenn@whimsy.udel.edu +2 -1 + ntpd/ntp_config.c@1.108 +2 -1 phone numbers now need a \r appended. - ntpd/ntp_proto.c@1.181.2.1, 2004-09-12 01:00:51-04:00, stenn@whimsy.udel.edu +92 -99 + ntpd/ntp_proto.c@1.181.2.1 +92 -99 Cleanup and fixes. - ntpd/ntp_refclock.c@1.59, 2004-09-12 01:00:52-04:00, stenn@whimsy.udel.edu +18 -0 + ntpd/ntp_refclock.c@1.59 +18 -0 Added refclock_timer(). - ntpd/ntp_timer.c@1.28, 2004-09-12 01:00:52-04:00, stenn@whimsy.udel.edu +9 -0 + ntpd/ntp_timer.c@1.28 +9 -0 Call refclock_timer(). - ntpd/refclock_acts.c@1.11, 2004-09-12 01:00:52-04:00, stenn@whimsy.udel.edu +586 -705 + ntpd/refclock_acts.c@1.11 +586 -705 Handle NIST/USNO/PTB/NPL over a modem. - ntpd/refclock_conf.c@1.24, 2004-09-12 01:00:52-04:00, stenn@whimsy.udel.edu +3 -15 + ntpd/refclock_conf.c@1.24 +3 -15 PTB and USNO now use the common ACTS code. -ChangeSet@1.1202.2.2, 2004-09-07 06:41:51-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.2.2, 2004-09-07 06:41:51-04:00, stenn@whimsy.udel.edu Use SNDCTL_DSP_SETFRAGMENT if available. From Tim Shoppa. - libntp/audio.c@1.23, 2004-09-07 06:41:36-04:00, stenn@whimsy.udel.edu +9 -0 + libntp/audio.c@1.23 +9 -0 Use SNDCTL_DSP_SETFRAGMENT if available. From Tim Shoppa. -ChangeSet@1.1202.2.1, 2004-09-03 22:34:20-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.2.1, 2004-09-03 22:34:20-04:00, stenn@whimsy.udel.edu Comment improvement from Dave Mills - include/ntp.h@1.101.1.1, 2004-09-03 22:33:10-04:00, stenn@whimsy.udel.edu +1 -1 + include/ntp.h@1.101.1.1 +1 -1 Comment improvement from Dave Mills -ChangeSet@1.1202.1.20, 2004-09-03 22:04:08-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1202.1.20, 2004-09-03 22:04:08-04:00, mayer@pogo.udel.edu INT_MULTICAST now INT_MCASTOPEN - ntpd/ntp_monitor.c@1.12.1.1, 2004-09-03 22:03:45-04:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_monitor.c@1.12.1.1 +1 -1 INT_MULTICAST now INT_MCASTOPEN - ntpd/ntp_proto.c@1.181.1.1, 2004-09-03 22:03:44-04:00, mayer@pogo.udel.edu +2 -2 + ntpd/ntp_proto.c@1.181.1.1 +2 -2 INT_MULTICAST now INT_MCASTOPEN -ChangeSet@1.1233, 2004-09-03 21:56:58-04:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1233, 2004-09-03 21:56:58-04:00, mayer@tecotoo. INT_MULTICAST now INT_MCASTOPEN - ntpd/ntp_monitor.c@1.13, 2004-09-03 21:56:28-04:00, mayer@tecotoo. +1 -1 + ntpd/ntp_monitor.c@1.13 +1 -1 INT_MULTICAST now INT_MCASTOPEN - ntpd/ntp_proto.c@1.182, 2004-09-03 21:56:27-04:00, mayer@tecotoo. +2 -2 + ntpd/ntp_proto.c@1.182 +2 -2 INT_MULTICAST now INT_MCASTOPEN -ChangeSet@1.1202.1.19, 2004-09-02 21:41:05-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.19, 2004-09-02 21:41:05-04:00, stenn@whimsy.udel.edu Dave Mills: RSTR kiss+iburst retried too often - ntpd/ntp_proto.c@1.181, 2004-09-02 21:40:49-04:00, stenn@whimsy.udel.edu +24 -33 + ntpd/ntp_proto.c@1.181 +24 -33 Dave Mills: RSTR kiss+iburst retried too often -ChangeSet@1.1202.1.18, 2004-08-30 04:27:54-04:00, stenn@www.ntp.org +1 -0 +ChangeSet@1.1202.1.18, 2004-08-30 04:27:54-04:00, stenn@www.ntp.org [Bug 153] Initial pass at framework to fix bug - ntpd/ntp_config.c@1.107, 2004-08-30 04:27:40-04:00, stenn@www.ntp.org +19 -9 + ntpd/ntp_config.c@1.107 +19 -9 [Bug 153] Initial pass at framework to fix bug -ChangeSet@1.1202.1.17, 2004-08-25 21:27:18-04:00, stenn@www.ntp.org +1 -0 +ChangeSet@1.1202.1.17, 2004-08-25 21:27:18-04:00, stenn@www.ntp.org avoid overwriting self - util/ntp-keygen.c@1.30, 2004-08-25 21:27:06-04:00, stenn@www.ntp.org +5 -1 + util/ntp-keygen.c@1.30 +5 -1 avoid overwriting self -ChangeSet@1.1202.1.16, 2004-08-25 01:16:52-04:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1202.1.16, 2004-08-25 01:16:52-04:00, stenn@whimsy.udel.edu added sntp.1 and did a little cleanup - sntp/Makefile.am@1.4, 2004-08-25 01:16:12-04:00, stenn@whimsy.udel.edu +5 -1 + sntp/Makefile.am@1.4 +5 -1 added sntp.1 and did a little cleanup - sntp/header.h@1.5, 2004-08-25 01:16:12-04:00, stenn@whimsy.udel.edu +2 -2 + sntp/header.h@1.5 +2 -2 added sntp.1 and did a little cleanup - sntp/main.c@1.4, 2004-08-25 01:16:11-04:00, stenn@whimsy.udel.edu +8 -8 + sntp/main.c@1.4 +8 -8 added sntp.1 and did a little cleanup - sntp/sntp.1@1.3, 2004-08-25 01:16:12-04:00, stenn@whimsy.udel.edu +25 -15 + sntp/sntp.1@1.3 +25 -15 added sntp.1 and did a little cleanup - sntp/sntp.1@1.2, 2004-08-25 00:51:55-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/sntp.1@1.2 +0 -0 Rename: sntp/msntp.1 -> sntp/sntp.1 - sntp/msntp.1@1.1, 2004-08-25 00:46:59-04:00, stenn@whimsy.udel.edu +325 -0 + sntp/msntp.1@1.1 +325 -0 - sntp/msntp.1@1.0, 2004-08-25 00:46:59-04:00, stenn@whimsy.udel.edu +0 -0 + sntp/msntp.1@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/sntp/msntp.1 -ChangeSet@1.1202.1.15, 2004-08-23 22:08:55-04:00, stenn@www.ntp.org +2 -0 +ChangeSet@1.1202.1.15, 2004-08-23 22:08:55-04:00, stenn@www.ntp.org make propdelay compile/link - clockstuff/Makefile.am@1.4, 2004-08-23 22:08:44-04:00, stenn@www.ntp.org +1 -1 + clockstuff/Makefile.am@1.4 +1 -1 make propdelay compile/link - clockstuff/propdelay.c@1.4, 2004-08-23 22:08:44-04:00, stenn@www.ntp.org +6 -6 + clockstuff/propdelay.c@1.4 +6 -6 make propdelay compile/link -ChangeSet@1.1202.1.14, 2004-08-19 23:22:20-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.14, 2004-08-19 23:22:20-04:00, stenn@whimsy.udel.edu [Bug 300] Properly report V3 reslist bits - ntpdc/ntpdc_ops.c@1.34.1.1, 2004-08-19 23:22:06-04:00, stenn@whimsy.udel.edu +25 -7 + ntpdc/ntpdc_ops.c@1.34.1.1 +25 -7 [Bug 300] Properly report V3 reslist bits -ChangeSet@1.1202.1.13, 2004-08-19 23:15:44-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.13, 2004-08-19 23:15:44-04:00, stenn@whimsy.udel.edu typo fix - ntpd/ntp_loopfilter.c@1.96, 2004-08-19 23:15:26-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_loopfilter.c@1.96 +1 -1 typo fix -ChangeSet@1.1229, 2004-08-19 18:34:48-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1229, 2004-08-19 18:34:48-04:00, mayer@pogo.udel.edu Change debug level of interrupted select to 5 - ntpd/ntpd.c@1.56, 2004-08-19 18:34:22-04:00, mayer@pogo.udel.edu +3 -3 + ntpd/ntpd.c@1.56 +3 -3 Change debug level of interrupted select to 5 -ChangeSet@1.1228, 2004-08-19 18:33:09-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1228, 2004-08-19 18:33:09-04:00, mayer@pogo.udel.edu Fixed IPv6 multicast to use correct scope for interface - ntpd/ntp_io.c@1.138, 2004-08-19 18:32:26-04:00, mayer@pogo.udel.edu +24 -12 + ntpd/ntp_io.c@1.138 +24 -12 Fixed IPv6 multicast to use correct scope for interface -ChangeSet@1.1227, 2004-08-16 19:31:28-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1227, 2004-08-16 19:31:28-04:00, mayer@pogo.udel.edu Miscellaneous fixes for sitelocal and linklocal IPv6 addresses - ntpd/ntp_io.c@1.137, 2004-08-16 19:30:48-04:00, mayer@pogo.udel.edu +23 -6 + ntpd/ntp_io.c@1.137 +23 -6 Miscellaneous fixes for sitelocal and linklocal IPv6 addresses -ChangeSet@1.1226, 2004-08-15 23:32:21-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1226, 2004-08-15 23:32:21-04:00, mayer@tecotoo. Typo, should have checked for INT_MULTICAST instead of INT_BROADCAST - ntpd/ntp_io.c@1.136, 2004-08-15 23:31:48-04:00, mayer@tecotoo. +1 -1 + ntpd/ntp_io.c@1.136 +1 -1 Typo should have checked for INT_MULTICAST instead of INT_BROADCAST -ChangeSet@1.1225, 2004-08-15 23:16:22-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1225, 2004-08-15 23:16:22-04:00, mayer@tecotoo. In IPv6 when looking for a multicast address check if the remote address is multicast - ntpd/ntp_io.c@1.135, 2004-08-15 23:15:56-04:00, mayer@tecotoo. +21 -2 + ntpd/ntp_io.c@1.135 +21 -2 In IPv6 when looking for a multicast address check if the remote address is multicast -ChangeSet@1.1224, 2004-08-15 21:45:50-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1224, 2004-08-15 21:45:50-04:00, mayer@tecotoo. Added more detailed debug print statements - ntpd/ntp_io.c@1.134, 2004-08-15 21:45:25-04:00, mayer@tecotoo. +18 -18 + ntpd/ntp_io.c@1.134 +18 -18 Added more detailed debug print statements -ChangeSet@1.1223, 2004-08-15 12:14:57-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1223, 2004-08-15 12:14:57-04:00, mayer@tecotoo. rewrote adding multicast client and added find_interface_index - ntpd/ntp_io.c@1.133, 2004-08-15 12:14:33-04:00, mayer@tecotoo. +44 -54 + ntpd/ntp_io.c@1.133 +44 -54 rewrote adding multicast client and added find_interface_index -ChangeSet@1.1222, 2004-08-15 01:34:53-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1222, 2004-08-15 01:34:53-04:00, mayer@tecotoo. Use Id of the interface when printing join multicast group failures - ntpd/ntp_io.c@1.132, 2004-08-15 01:34:33-04:00, mayer@tecotoo. +3 -3 + ntpd/ntp_io.c@1.132 +3 -3 Use Id of the interface when printing join multicast group failures -ChangeSet@1.1221, 2004-08-15 01:20:41-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1221, 2004-08-15 01:20:41-04:00, mayer@tecotoo. Added debug print statements - ntpd/ntp_io.c@1.131, 2004-08-15 01:20:19-04:00, mayer@tecotoo. +12 -6 + ntpd/ntp_io.c@1.131 +12 -6 Added debug print statements -ChangeSet@1.1220, 2004-08-14 23:33:00-04:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1220, 2004-08-14 23:33:00-04:00, mayer@tecotoo. Redid findinterface and findbcastinter to properly find appropriate interface and use the family member from the interface struct - include/ntp.h@1.102, 2004-08-14 23:30:57-04:00, mayer@tecotoo. +14 -13 + include/ntp.h@1.102 +14 -13 Added family to interface struct - ntpd/ntp_io.c@1.130, 2004-08-14 23:32:23-04:00, mayer@tecotoo. +86 -97 + ntpd/ntp_io.c@1.130 +86 -97 Redid findinterface and findbcastinter to properly find appropriate interface and use the family member from the interface struct -ChangeSet@1.1202.1.12, 2004-08-13 05:48:21-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1202.1.12, 2004-08-13 05:48:21-04:00, stenn@pogo.udel.edu [Bug 301] ntp-keygen has no usage statement - util/ntp-keygen.c@1.29, 2004-08-13 05:47:54-04:00, stenn@pogo.udel.edu +44 -4 + util/ntp-keygen.c@1.29 +44 -4 [Bug 301] ntp-keygen has no usage statement -ChangeSet@1.1218, 2004-08-12 16:54:31-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1218, 2004-08-12 16:54:31-04:00, mayer@pogo.udel.edu findbcastinter needs to find a proper broadcast interface - ntpd/ntp_io.c@1.129, 2004-08-12 16:52:29-04:00, mayer@pogo.udel.edu +236 -5 + ntpd/ntp_io.c@1.129 +236 -5 findbcastinter needs to find a proper broadcast interface -ChangeSet@1.1202.1.11, 2004-08-12 05:12:15-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.11, 2004-08-12 05:12:15-04:00, stenn@whimsy.udel.edu Use AC_HELP_STRING in configure.ac - configure.ac@1.351.1.5, 2004-08-12 05:12:06-04:00, stenn@whimsy.udel.edu +35 -20 + configure.ac@1.351.1.5 +35 -20 Use AC_HELP_STRING in configure.ac -ChangeSet@1.1217, 2004-08-11 23:06:43-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1217, 2004-08-11 23:06:43-04:00, mayer@tecotoo. Added files for inet_*ton functions - ports/winnt/libntp/libntp.dsp@1.20, 2004-08-11 23:06:27-04:00, mayer@tecotoo. +4 -0 + ports/winnt/libntp/libntp.dsp@1.20 +4 -0 Added files for inet_*ton functions -ChangeSet@1.1202.1.10, 2004-08-11 22:28:30-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1202.1.10, 2004-08-11 22:28:30-04:00, stenn@whimsy.udel.edu FreeBSD lint - Makefile.am@1.48, 2004-08-11 22:28:10-04:00, stenn@whimsy.udel.edu +5 -5 + Makefile.am@1.48 +5 -5 FreeBSD lint - ntpdc/ntpdc.c@1.34, 2004-08-11 22:28:11-04:00, stenn@whimsy.udel.edu +5 -1 + ntpdc/ntpdc.c@1.34 +5 -1 FreeBSD lint - ntpq/ntpq.c@1.49, 2004-08-11 22:28:11-04:00, stenn@whimsy.udel.edu +5 -1 + ntpq/ntpq.c@1.49 +5 -1 FreeBSD lint -ChangeSet@1.1216, 2004-08-11 18:04:11-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1216, 2004-08-11 18:04:11-04:00, mayer@pogo.udel.edu interfaces are not TCP-specific - ports/winnt/libisc/interfaceiter.c@1.4.1.1, 2004-08-11 18:03:09-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/libisc/interfaceiter.c@1.4.1.1 +1 -1 interfaces are not TCP-specific -ChangeSet@1.1202.1.9, 2004-08-11 18:00:52-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.1.9, 2004-08-11 18:00:52-04:00, mayer@pogo.udel.edu interfaces are not TCP-specific - ports/winnt/libisc/interfaceiter.c@1.5, 2004-08-11 18:00:16-04:00, mayer@pogo.udel.edu +1 -1 + ports/winnt/libisc/interfaceiter.c@1.5 +1 -1 interfaces are not TCP-specific -ChangeSet@1.1202.1.8, 2004-08-10 19:36:31-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202.1.8, 2004-08-10 19:36:31-04:00, mayer@pogo.udel.edu Fix to emit error strings when getting errors from system - ports/winnt/ntpd/win32_io.c@1.7.1.1, 2004-08-10 19:36:17-04:00, mayer@pogo.udel.edu +8 -8 + ports/winnt/ntpd/win32_io.c@1.7.1.1 +8 -8 Fix to emit error strings when getting errors from system -ChangeSet@1.1214, 2004-08-10 19:25:24-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1214, 2004-08-10 19:25:24-04:00, mayer@pogo.udel.edu Fix to emit error strings when getting errors from system - ports/winnt/ntpd/win32_io.c@1.8, 2004-08-10 19:24:38-04:00, mayer@pogo.udel.edu +8 -8 + ports/winnt/ntpd/win32_io.c@1.8 +8 -8 Fix to emit error strings when getting errors from system -ChangeSet@1.1202.1.7, 2004-08-10 01:24:58-04:00, stenn@www.ntp.org +1 -0 +ChangeSet@1.1202.1.7, 2004-08-10 01:24:58-04:00, stenn@www.ntp.org [Bug 208] Use -R in LDFLAGS when needed. (some other cleanup, too) - configure.ac@1.351.1.4, 2004-08-10 01:24:48-04:00, stenn@www.ntp.org +34 -12 + configure.ac@1.351.1.4 +34 -12 [Bug 208] Use -R in LDFLAGS when needed. (some other cleanup, too) -ChangeSet@1.1202.1.6, 2004-08-09 05:39:43-05:00, stenn@poog.il.thewrittenword.com +1 -0 +ChangeSet@1.1202.1.6, 2004-08-09 05:39:43-05:00, stenn@poog.il.thewrittenword.com OSF needs sys/time.h to test for sys/timex.h - configure.ac@1.351.1.3, 2004-08-09 05:39:22-05:00, stenn@poog.il.thewrittenword.com +7 -1 + configure.ac@1.351.1.3 +7 -1 OSF needs sys/time.h to test for sys/timex.h -ChangeSet@1.1202.1.5, 2004-08-09 05:38:32-05:00, stenn@poog.il.thewrittenword.com +2 -0 +ChangeSet@1.1202.1.5, 2004-08-09 05:38:32-05:00, stenn@poog.il.thewrittenword.com OSF cflags cleanup - BitKeeper/etc/logging_ok@1.50, 2004-08-09 05:38:31-05:00, stenn@poog.il.thewrittenword.com +1 -0 + BitKeeper/etc/logging_ok@1.50 +1 -0 Logging to logging@openlogging.org accepted - m4/os_cflags.m4@1.2, 2004-08-09 05:38:03-05:00, stenn@poog.il.thewrittenword.com +23 -22 + m4/os_cflags.m4@1.2 +23 -22 OSF cflags cleanup -ChangeSet@1.1202.1.4, 2004-08-07 07:22:03-04:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1202.1.4, 2004-08-07 07:22:03-04:00, stenn@whimsy.udel.edu [Bug 166] Clean up Irix compile/link flags for 32/64 bits - BitKeeper/deleted/.del-acinclude.m4~457f12ef@1.13, 2004-08-07 06:27:18-04:00, stenn@whimsy.udel.edu +0 -0 + BitKeeper/deleted/.del-acinclude.m4~457f12ef@1.13 +0 -0 Delete: acinclude.m4 - Makefile.am@1.47, 2004-08-07 07:20:57-04:00, stenn@whimsy.udel.edu +5 -2 + Makefile.am@1.47 +5 -2 [Bug 166] Clean up Irix compile/link flags for 32/64 bits - configure.ac@1.351.1.2, 2004-08-07 07:20:58-04:00, stenn@whimsy.udel.edu +1 -19 + configure.ac@1.351.1.2 +1 -19 [Bug 166] Clean up Irix compile/link flags for 32/64 bits - configure.ac@1.351.1.1, 2004-08-07 05:41:16-04:00, stenn@whimsy.udel.edu +0 -0 + configure.ac@1.351.1.1 +0 -0 Rename: configure.in -> configure.ac - m4/define_dir.m4@1.1, 2004-08-07 06:28:00-04:00, stenn@whimsy.udel.edu +26 -0 + m4/define_dir.m4@1.1 +26 -0 - m4/define_dir.m4@1.0, 2004-08-07 06:28:00-04:00, stenn@whimsy.udel.edu +0 -0 + m4/define_dir.m4@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/m4/define_dir.m4 - m4/hs_ulong_const.m4@1.1, 2004-08-07 06:28:00-04:00, stenn@whimsy.udel.edu +11 -0 + m4/hs_ulong_const.m4@1.1 +11 -0 - m4/hs_ulong_const.m4@1.0, 2004-08-07 06:28:00-04:00, stenn@whimsy.udel.edu +0 -0 + m4/hs_ulong_const.m4@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/m4/hs_ulong_const.m4 - m4/os_cflags.m4@1.1, 2004-08-07 06:28:00-04:00, stenn@whimsy.udel.edu +86 -0 + m4/os_cflags.m4@1.1 +86 -0 - m4/os_cflags.m4@1.0, 2004-08-07 06:28:00-04:00, stenn@whimsy.udel.edu +0 -0 + m4/os_cflags.m4@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev-hms/m4/os_cflags.m4 -ChangeSet@1.1202.1.3, 2004-08-06 03:42:21-04:00, stenn@www.ntp.org +2 -0 +ChangeSet@1.1202.1.3, 2004-08-06 03:42:21-04:00, stenn@www.ntp.org [Bug 321] Fix some alpha alignment issues and avoid a possibile DOS - BitKeeper/etc/logging_ok@1.49, 2004-08-06 03:42:20-04:00, stenn@www.ntp.org +1 -0 + BitKeeper/etc/logging_ok@1.49 +1 -0 Logging to logging@openlogging.org accepted - ntpd/ntp_control.c@1.70.1.1, 2004-08-06 03:42:03-04:00, stenn@www.ntp.org +7 -4 + ntpd/ntp_control.c@1.70.1.1 +7 -4 [Bug 321] Fix some alpha alignment issues and avoid a possibile DOS -ChangeSet@1.1202.1.2, 2004-08-05 23:40:16-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.2, 2004-08-05 23:40:16-04:00, stenn@whimsy.udel.edu No more autokey/rsa for mkver, just openssl now. - scripts/mkver.in@1.11, 2004-08-05 23:40:02-04:00, stenn@whimsy.udel.edu +5 -8 + scripts/mkver.in@1.11 +5 -8 No more autokey/rsa for mkver, just openssl now. -ChangeSet@1.1202.1.1, 2004-08-05 23:33:23-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1202.1.1, 2004-08-05 23:33:23-04:00, stenn@whimsy.udel.edu [Bug 326] handle MAXTOKEN overflow better. - ntpd/ntp_config.c@1.106, 2004-08-05 23:33:09-04:00, stenn@whimsy.udel.edu +27 -10 + ntpd/ntp_config.c@1.106 +27 -10 [Bug 326] handle MAXTOKEN overflow better. -ChangeSet@1.1212, 2004-08-05 00:14:18-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1212, 2004-08-05 00:14:18-04:00, mayer@tecotoo. Look for PPP for interface to the outside - ntpd/ntp_io.c@1.128, 2004-08-05 00:13:51-04:00, mayer@tecotoo. +18 -0 + ntpd/ntp_io.c@1.128 +18 -0 Look for PPP for interface to the outside -ChangeSet@1.1211, 2004-08-04 18:41:17-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1211, 2004-08-04 18:41:17-04:00, mayer@pogo.udel.edu Fix cast in ntohl - ntpdc/ntpdc_ops.c@1.35, 2004-08-04 18:35:01-04:00, mayer@pogo.udel.edu +23 -23 + ntpdc/ntpdc_ops.c@1.35 +23 -23 Fix cast in ntohl -ChangeSet@1.1210, 2004-08-04 18:10:22-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1210, 2004-08-04 18:10:22-04:00, mayer@pogo.udel.edu Fixes for scope ID - libisc/interfaceiter.c@1.11, 2004-08-04 18:09:36-04:00, mayer@pogo.udel.edu +6 -1 + libisc/interfaceiter.c@1.11 +6 -1 Fixes for scope ID - ntpd/ntp_io.c@1.127, 2004-08-04 18:09:36-04:00, mayer@pogo.udel.edu +3 -2 + ntpd/ntp_io.c@1.127 +3 -2 Fixes for scope ID -ChangeSet@1.1209, 2004-08-04 02:28:09-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1209, 2004-08-04 02:28:09-04:00, mayer@tecotoo. Fix setting of only interface code - ntpd/ntp_io.c@1.126, 2004-08-04 02:27:41-04:00, mayer@tecotoo. +2 -2 + ntpd/ntp_io.c@1.126 +2 -2 Fix setting of only interface code -ChangeSet@1.1208, 2004-08-03 18:39:54-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1208, 2004-08-03 18:39:54-04:00, mayer@pogo.udel.edu Linklocal and sitelocal IPv6 changes - include/ntp_rfc2553.h@1.26, 2004-08-03 18:38:57-04:00, mayer@pogo.udel.edu +14 -0 + include/ntp_rfc2553.h@1.26 +14 -0 Add link-local and site-local IPv6 macros - ntpd/ntp_io.c@1.125, 2004-08-03 18:38:07-04:00, mayer@pogo.udel.edu +18 -0 + ntpd/ntp_io.c@1.125 +18 -0 Add check for link-local and site-local for IPv6 addresses when looking for interfaces -ChangeSet@1.1207, 2004-08-02 22:36:39-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1207, 2004-08-02 22:36:39-04:00, mayer@tecotoo. findbcastinter should look for INT_BROADCAST flag - ntpd/ntp_io.c@1.124, 2004-08-02 22:36:20-04:00, mayer@tecotoo. +1 -1 + ntpd/ntp_io.c@1.124 +1 -1 findbcastinter should look for INT_BROADCAST flag -ChangeSet@1.1206, 2004-08-02 22:19:13-04:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1206, 2004-08-02 22:19:13-04:00, mayer@tecotoo. findinterface cleanup and IPv4/IPv6 fixes - configure.in@1.352, 2004-08-02 22:15:55-04:00, mayer@tecotoo. +2 -0 + configure.in@1.352 +2 -0 Add check for inet_pton and inet_aton - libntp/ntp_rfc2553.c@1.20, 2004-08-02 22:16:44-04:00, mayer@tecotoo. +8 -2 + libntp/ntp_rfc2553.c@1.20 +8 -2 fix port assignment - ntpd/ntp_io.c@1.123, 2004-08-02 22:18:20-04:00, mayer@tecotoo. +1 -2 + ntpd/ntp_io.c@1.123 +1 -2 Ongoing findinterface cleanup -ChangeSet@1.1205, 2004-08-02 20:44:31-04:00, mayer@pogo.udel.edu +5 -0 +ChangeSet@1.1205, 2004-08-02 20:44:31-04:00, mayer@pogo.udel.edu Changes for proper IPv4 and IPv6 support - libisc/inet_aton.c@1.2, 2004-08-02 17:25:20-04:00, mayer@pogo.udel.edu +0 -3 + libisc/inet_aton.c@1.2 +0 -3 Remove temporary changes to support Winnt - libntp/Makefile.am@1.30, 2004-08-02 18:27:20-04:00, mayer@pogo.udel.edu +3 -1 + libntp/Makefile.am@1.30 +3 -1 Added inet_pton and inet_aton to libisc - libntp/ntp_rfc2553.c@1.19, 2004-08-02 17:58:55-04:00, mayer@pogo.udel.edu +2 -2 + libntp/ntp_rfc2553.c@1.19 +2 -2 Reorder the includes to prevent warnings - libntp/ntp_rfc2553.c@1.18, 2004-08-02 17:28:33-04:00, mayer@pogo.udel.edu +20 -15 + libntp/ntp_rfc2553.c@1.18 +20 -15 Change to use inet_pton and cleanly support at least IPv6 addresses - ntpd/ntp_io.c@1.122, 2004-08-02 17:29:31-04:00, mayer@pogo.udel.edu +2 -15 + ntpd/ntp_io.c@1.122 +2 -15 changes to find the right local interface for outgoing packets - ports/winnt/include/config.h@1.28, 2004-08-02 17:23:51-04:00, mayer@pogo.udel.edu +1 -0 + ports/winnt/include/config.h@1.28 +1 -0 Added isascii, required for inet_aton -ChangeSet@1.1204, 2004-08-02 00:35:56-04:00, mayer@tecotoo. +7 -0 +ChangeSet@1.1204, 2004-08-02 00:35:56-04:00, mayer@tecotoo. Updates to support finding interfaces and address lookups - libisc/inet_aton.c@1.1, 2004-08-02 00:35:48-04:00, mayer@tecotoo. +198 -0 + libisc/inet_aton.c@1.1 +198 -0 - libisc/inet_aton.c@1.0, 2004-08-02 00:35:48-04:00, mayer@tecotoo. +0 -0 + libisc/inet_aton.c@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/libisc/inet_aton.c - libisc/inet_pton.c@1.1, 2004-08-02 00:35:49-04:00, mayer@tecotoo. +211 -0 + libisc/inet_pton.c@1.1 +211 -0 - libisc/inet_pton.c@1.0, 2004-08-02 00:35:49-04:00, mayer@tecotoo. +0 -0 + libisc/inet_pton.c@1.0 +0 -0 BitKeeper file H:/ntpbk/ntp-dev/libisc/inet_pton.c - libntp/ntp_rfc2553.c@1.17, 2004-08-02 00:35:44-04:00, mayer@tecotoo. +15 -74 + libntp/ntp_rfc2553.c@1.17 +15 -74 fix the code to properly handle addresses. - ntpd/ntp_control.c@1.71, 2004-08-02 00:35:45-04:00, mayer@tecotoo. +0 -1 + ntpd/ntp_control.c@1.71 +0 -1 no change - ntpd/ntp_io.c@1.121, 2004-08-02 00:35:46-04:00, mayer@tecotoo. +82 -3 + ntpd/ntp_io.c@1.121 +82 -3 changes to properly find outgoing interfaces - ports/winnt/include/config.h@1.27, 2004-08-02 00:35:47-04:00, mayer@tecotoo. +1 -0 + ports/winnt/include/config.h@1.27 +1 -0 Need inet_pton - ports/winnt/libntp/libntp.dsp@1.19, 2004-08-02 00:35:47-04:00, mayer@tecotoo. +8 -0 + ports/winnt/libntp/libntp.dsp@1.19 +8 -0 Add inet_pton and inet_aton -ChangeSet@1.1203, 2004-07-28 23:44:06-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1203, 2004-07-28 23:44:06-04:00, mayer@tecotoo. clean up finding addresses and interfaces - ntpd/ntp_io.c@1.120, 2004-07-28 23:43:44-04:00, mayer@tecotoo. +37 -50 + ntpd/ntp_io.c@1.120 +37 -50 clean up finding addresses and interfaces -ChangeSet@1.1202, 2004-07-27 19:24:53-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1202, 2004-07-27 19:24:53-04:00, mayer@pogo.udel.edu Changes for conditional support of broadcast and multicast on some platforms - ntpd/ntp_io.c@1.119, 2004-07-27 19:24:10-04:00, mayer@pogo.udel.edu +3 -2 + ntpd/ntp_io.c@1.119 +3 -2 Changes for conditional support of broadcast and multicast on some platforms -ChangeSet@1.1201, 2004-07-26 23:12:26-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1201, 2004-07-26 23:12:26-04:00, mayer@tecotoo. Code cleanup and simplification - ntpd/ntp_io.c@1.118, 2004-07-26 23:11:58-04:00, mayer@tecotoo. +104 -101 + ntpd/ntp_io.c@1.118 +104 -101 Code cleanup and simplification -ChangeSet@1.1200, 2004-07-26 10:18:16-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1200, 2004-07-26 10:18:16-04:00, mayer@pogo.udel.edu Not all O/S's support broadcast. Conditionally build the socket_broadcast_* code - ntpd/ntp_io.c@1.117, 2004-07-26 10:17:29-04:00, mayer@pogo.udel.edu +6 -4 + ntpd/ntp_io.c@1.117 +6 -4 Not all O/S's support broadcast. Conditionally build the socket_broadcast_* code -ChangeSet@1.1199, 2004-07-25 23:28:14-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1199, 2004-07-25 23:28:14-04:00, mayer@tecotoo. Not all platforms support Multicast - ntpd/ntp_io.c@1.116, 2004-07-25 23:27:58-04:00, mayer@tecotoo. +6 -0 + ntpd/ntp_io.c@1.116 +6 -0 Not all platforms support Multicast -ChangeSet@1.1198, 2004-07-25 23:07:04-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1198, 2004-07-25 23:07:04-04:00, mayer@tecotoo. Minor bugs in IPv6 codes. Remove unused variables - ntpd/ntp_io.c@1.115, 2004-07-25 23:06:44-04:00, mayer@tecotoo. +3 -6 + ntpd/ntp_io.c@1.115 +3 -6 Minor bugs in IPv6 codes. Remove unused variables -ChangeSet@1.1197, 2004-07-25 22:44:57-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1197, 2004-07-25 22:44:57-04:00, mayer@tecotoo. Rewrite multicast and broadcast routines to remove wildcard requirements, improve flexibility and general code improvements - ntpd/ntp_io.c@1.114, 2004-07-25 22:44:21-04:00, mayer@tecotoo. +328 -245 + ntpd/ntp_io.c@1.114 +328 -245 Rewrite multicast and broadcast routines to remove wildcard requirements, improve flexibility and general code improvements -ChangeSet@1.1192.1.2, 2004-07-22 00:20:36-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1192.1.2, 2004-07-22 00:20:36-04:00, mayer@tecotoo. If we can't figure out the address type assume it's IPv4 - libntp/socktoa.c@1.7, 2004-07-22 00:20:18-04:00, mayer@tecotoo. +3 -0 + libntp/socktoa.c@1.7 +3 -0 If we can't figure out the address type assume it's IPv4 -ChangeSet@1.1189.1.2, 2004-07-22 00:11:05-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1189.1.2, 2004-07-22 00:11:05-04:00, mayer@tecotoo. For Multicast make sure socket can handle multicast - ntpd/ntp_io.c@1.113, 2004-07-22 00:10:36-04:00, mayer@tecotoo. +16 -10 + ntpd/ntp_io.c@1.113 +16 -10 For Multicast make sure socket can handle multicast -ChangeSet@1.1195, 2004-07-20 02:42:59-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1195, 2004-07-20 02:42:59-04:00, stenn@whimsy.udel.edu [Bug 307] Typo fix from Volkmar Grote - html/monopt.html@1.19, 2004-07-20 02:42:38-04:00, stenn@whimsy.udel.edu +2 -2 + html/monopt.html@1.19 +2 -2 [Bug 307] Typo fix from Volkmar Grote -ChangeSet@1.1194, 2004-07-20 02:26:12-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1194, 2004-07-20 02:26:12-04:00, stenn@whimsy.udel.edu [Bug 233] Apply rest of patch from Matthias Drochner - ntpd/refclock_shm.c@1.16, 2004-07-20 02:25:58-04:00, stenn@whimsy.udel.edu +4 -1 + ntpd/refclock_shm.c@1.16 +4 -1 [Bug 233] Apply rest of patch from Matthias Drochner - ntpdc/ntpdc_ops.c@1.34, 2004-07-20 02:25:58-04:00, stenn@whimsy.udel.edu +5 -5 + ntpdc/ntpdc_ops.c@1.34 +5 -5 [Bug 233] Apply rest of patch from Matthias Drochner -ChangeSet@1.1193, 2004-07-16 01:20:38-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1193, 2004-07-16 01:20:38-04:00, stenn@whimsy.udel.edu [Bug 315] Provide prereq headers for configure.in - configure.in@1.351, 2004-07-16 01:20:22-04:00, stenn@whimsy.udel.edu +28 -2 + configure.in@1.351 +28 -2 [Bug 315] Provide prereq headers for configure.in -ChangeSet@1.1189.1.1, 2004-07-12 21:57:57-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1189.1.1, 2004-07-12 21:57:57-04:00, mayer@tecotoo. IPv6 addresses caused the resultant refid to get it's values swapped on some machines - libntp/a_md5encrypt.c@1.18, 2004-07-12 21:57:30-04:00, mayer@tecotoo. +1 -1 + libntp/a_md5encrypt.c@1.18 +1 -1 IPv6 addresses caused the resultant refid to get it's values swapped on some machines -ChangeSet@1.1191, 2004-07-12 19:36:51-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1191, 2004-07-12 19:36:51-04:00, stenn@whimsy.udel.edu Use UTC for the date in the version string for mkver.in - scripts/mkver.in@1.10, 2004-07-12 19:36:32-04:00, stenn@whimsy.udel.edu +1 -1 + scripts/mkver.in@1.10 +1 -1 Use UTC for the date in the version string -ChangeSet@1.1178.1.13, 2004-07-07 00:52:39-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.1.13, 2004-07-07 00:52:39-04:00, stenn@whimsy.udel.edu Fix from Dave Mills - libntp/systime.c@1.31, 2004-07-07 00:52:22-04:00, stenn@whimsy.udel.edu +2 -7 + libntp/systime.c@1.31 +2 -7 Fix from Dave Mills -ChangeSet@1.1189, 2004-07-05 23:36:39-04:00, mayer@tecotoo. +3 -0 +ChangeSet@1.1189, 2004-07-05 23:36:39-04:00, mayer@tecotoo. Multicast modifications and extraneous macro definition removal - include/ntp.h@1.101, 2004-07-05 23:36:31-04:00, mayer@tecotoo. +2 -1 + include/ntp.h@1.101 +2 -1 Flags change to differentiate between mulitcast capable and multicast in use - ntpd/ntp_io.c@1.112, 2004-07-05 23:36:32-04:00, mayer@tecotoo. +8 -6 + ntpd/ntp_io.c@1.112 +8 -6 Add multicast capable flags when available. Change multicast flag to show socket is being used for multicast - ntpd/ntpd.c@1.55, 2004-07-05 23:36:33-04:00, mayer@tecotoo. +2 -4 + ntpd/ntpd.c@1.55 +2 -4 Remove unnecessary macro condition -ChangeSet@1.1188, 2004-07-03 18:30:24-04:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1188, 2004-07-03 18:30:24-04:00, mayer@tecotoo. include updates for winnt - ports/winnt/libntp/libntp.dsp@1.18, 2004-07-03 18:08:42-04:00, mayer@tecotoo. +4 -0 + ports/winnt/libntp/libntp.dsp@1.18 +4 -0 Added ntp_rfc2553.h to list of includes - ports/winnt/ntpd/ntpd.dsp@1.20, 2004-07-03 18:08:42-04:00, mayer@tecotoo. +0 -4 + ports/winnt/ntpd/ntpd.dsp@1.20 +0 -4 map_vme.c not used. -ChangeSet@1.1187, 2004-07-03 17:54:02-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1187, 2004-07-03 17:54:02-04:00, mayer@tecotoo. Removed unreachable code - ports/winnt/ntpd/ntp_iocompletionport.c@1.12, 2004-07-03 17:53:47-04:00, mayer@tecotoo. +0 -1 + ports/winnt/ntpd/ntp_iocompletionport.c@1.12 +0 -1 Removed unreachable code -ChangeSet@1.1186, 2004-07-03 17:52:50-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1186, 2004-07-03 17:52:50-04:00, mayer@tecotoo. #endif was in wrong place - ntpd/ntp_proto.c@1.180, 2004-07-03 17:52:29-04:00, mayer@tecotoo. +1 -1 + ntpd/ntp_proto.c@1.180 +1 -1 #endif was in wrong place -ChangeSet@1.1183, 2004-07-03 16:56:20-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1183, 2004-07-03 16:56:20-04:00, mayer@tecotoo. handle empty sockets and unknown address family - libntp/socktoa.c@1.6, 2004-07-03 16:55:09-04:00, mayer@tecotoo. +8 -2 + libntp/socktoa.c@1.6 +8 -2 handle empty sockets and unknown address family -ChangeSet@1.1178.1.12, 2004-05-06 01:39:49-04:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1178.1.12, 2004-05-06 01:39:49-04:00, stenn@whimsy.udel.edu Cleanup from Dave Mills - html/drivers/driver36.html@1.23, 2004-05-06 01:39:06-04:00, stenn@whimsy.udel.edu +0 -2 + html/drivers/driver36.html@1.23 +0 -2 Cleanup from Dave Mills - html/drivers/driver6.html@1.18, 2004-05-06 01:39:06-04:00, stenn@whimsy.udel.edu +0 -2 + html/drivers/driver6.html@1.18 +0 -2 Cleanup from Dave Mills - html/drivers/driver7.html@1.21, 2004-05-06 01:39:07-04:00, stenn@whimsy.udel.edu +0 -2 + html/drivers/driver7.html@1.21 +0 -2 Cleanup from Dave Mills - html/drivers/scripts/footer.txt@1.1, 2004-05-06 01:37:41-04:00, stenn@whimsy.udel.edu +7 -0 + html/drivers/scripts/footer.txt@1.1 +7 -0 - html/drivers/scripts/footer.txt@1.0, 2004-05-06 01:37:41-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/scripts/footer.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/drivers/scripts/footer.txt - html/drivers/scripts/style.css@1.1, 2004-05-06 01:37:41-04:00, stenn@whimsy.udel.edu +64 -0 + html/drivers/scripts/style.css@1.1 +64 -0 - html/drivers/scripts/style.css@1.0, 2004-05-06 01:37:41-04:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/scripts/style.css@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/drivers/scripts/style.css -ChangeSet@1.1178.1.11, 2004-05-04 03:43:00-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.1.11, 2004-05-04 03:43:00-04:00, stenn@whimsy.udel.edu [Bug 305] More lint - ntpd/ntp_refclock.c@1.58, 2004-05-04 03:42:37-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_refclock.c@1.58 +1 -1 [Bug 305] More lint -ChangeSet@1.1178.3.1, 2004-05-04 01:01:59-04:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1178.3.1, 2004-05-04 01:01:59-04:00, stenn@whimsy.udel.edu Cleanup/fixes from Dave Mills. - include/ntpd.h@1.66, 2004-05-04 01:01:25-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntpd.h@1.66 +1 -0 Cleanup/fixes from Dave Mills. - ntpd/ntp_filegen.c@1.9, 2004-05-04 01:01:25-04:00, stenn@whimsy.udel.edu +5 -0 + ntpd/ntp_filegen.c@1.9 +5 -0 Cleanup/fixes from Dave Mills. - ntpd/ntp_loopfilter.c@1.95, 2004-05-04 01:01:32-04:00, stenn@whimsy.udel.edu +5 -3 + ntpd/ntp_loopfilter.c@1.95 +5 -3 Cleanup/fixes from Dave Mills. -ChangeSet@1.1181, 2004-04-25 10:35:51-04:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1181, 2004-04-25 10:35:51-04:00, mayer@tecotoo. Bug fix - ports/winnt/include/config.h@1.24.1.1, 2004-04-25 10:35:16-04:00, mayer@tecotoo. +1 -1 + ports/winnt/include/config.h@1.24.1.1 +1 -1 -ChangeSet@1.1178.1.8, 2004-04-23 19:23:39-04:00, mayer@pogo.udel.edu +3 -0 +ChangeSet@1.1178.1.8, 2004-04-23 19:23:39-04:00, mayer@pogo.udel.edu Modification to correct for type errors - include/ntp_rfc2553.h@1.25, 2004-04-23 19:21:15-04:00, mayer@pogo.udel.edu +16 -16 + include/ntp_rfc2553.h@1.25 +16 -16 Move u_int*_t types to ntp_* to avoid conflicts - include/ntp_types.h@1.8, 2004-04-23 19:21:15-04:00, mayer@pogo.udel.edu +3 -5 + include/ntp_types.h@1.8 +3 -5 Move u_int*_t types to ntp_* to avoid conflicts - ntpd/ntp_io.c@1.110, 2004-04-23 19:22:36-04:00, mayer@pogo.udel.edu +4 -0 + ntpd/ntp_io.c@1.110 +4 -0 Modified to add hex value of network address to output for Multicast errors -ChangeSet@1.1178.2.3, 2004-04-19 20:20:20-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.2.3, 2004-04-19 20:20:20-04:00, stenn@whimsy.udel.edu manycast poll bugfix from Dave Mills. - ntpd/ntp_proto.c@1.178, 2004-04-19 20:19:55-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.178 +1 -1 manycast poll bugfix from Dave Mills. -ChangeSet@1.1178.2.2, 2004-04-17 17:33:32-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1178.2.2, 2004-04-17 17:33:32-04:00, stenn@pogo.udel.edu Always see if we need in6addr_any - configure.in@1.350, 2004-04-17 17:33:17-04:00, stenn@pogo.udel.edu +6 -5 + configure.in@1.350 +6 -5 Always see if we need in6addr_any -ChangeSet@1.1178.2.1, 2004-04-17 17:32:38-04:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1178.2.1, 2004-04-17 17:32:38-04:00, stenn@pogo.udel.edu Added cowbird to the flock-build - flock-build@1.30, 2004-04-17 17:32:22-04:00, stenn@pogo.udel.edu +1 -1 + flock-build@1.30 +1 -1 Added cowbird to the flock-build -ChangeSet@1.1178.1.5, 2004-04-16 20:42:21-04:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1178.1.5, 2004-04-16 20:42:21-04:00, mayer@pogo.udel.edu Fix for AIX to initialize in6addr_any - libntp/ntp_rfc2553.c@1.16, 2004-04-16 20:40:05-04:00, mayer@pogo.udel.edu +4 -1 + libntp/ntp_rfc2553.c@1.16 +4 -1 Fix for AIX to initialize in6addr_any - ports/winnt/include/config.h@1.25, 2004-04-16 20:41:27-04:00, mayer@pogo.udel.edu +2 -0 + ports/winnt/include/config.h@1.25 +2 -0 Fix for AIX to initialize in6addr_any -ChangeSet@1.1152.34.1, 2004-04-11 18:53:56+01:00, mbrett@rgs16.fordson.demon.co.uk +7 -0 +ChangeSet@1.1152.34.1, 2004-04-11 18:53:56+01:00, mbrett@rgs16.fordson.demon.co.uk Many files: Changes for type-paranoid MIPSpro compiler. - ntpd/ntp_config.c@1.100.1.1, 2004-04-11 18:52:24+01:00, mbrett@rgs16.fordson.demon.co.uk +1 -1 + ntpd/ntp_config.c@1.100.1.1 +1 -1 Changes for type-paranoid MIPSpro compiler. - ntpd/ntp_intres.c@1.32.1.1, 2004-04-11 18:52:33+01:00, mbrett@rgs16.fordson.demon.co.uk +1 -1 + ntpd/ntp_intres.c@1.32.1.1 +1 -1 Changes for type-paranoid MIPSpro compiler. - ntpd/ntp_io.c@1.105.2.1, 2004-04-11 18:52:36+01:00, mbrett@rgs16.fordson.demon.co.uk +4 -4 + ntpd/ntp_io.c@1.105.2.1 +4 -4 Changes for type-paranoid MIPSpro compiler. - ntpd/ntp_proto.c@1.172.1.1, 2004-04-11 18:52:40+01:00, mbrett@rgs16.fordson.demon.co.uk +3 -3 + ntpd/ntp_proto.c@1.172.1.1 +3 -3 Changes for type-paranoid MIPSpro compiler. - ntpdc/ntpdc_ops.c@1.29.1.1, 2004-04-11 18:51:44+01:00, mbrett@rgs16.fordson.demon.co.uk +17 -17 + ntpdc/ntpdc_ops.c@1.29.1.1 +17 -17 Changes for type-paranoid MIPSpro compiler. - ntpq/ntpq.c@1.45.1.1, 2004-04-11 18:52:43+01:00, mbrett@rgs16.fordson.demon.co.uk +2 -2 + ntpq/ntpq.c@1.45.1.1 +2 -2 Changes for type-paranoid MIPSpro compiler. - ntpq/ntpq_ops.c@1.20, 2004-04-11 18:52:47+01:00, mbrett@rgs16.fordson.demon.co.uk +1 -1 + ntpq/ntpq_ops.c@1.20 +1 -1 Changes for type-paranoid MIPSpro compiler. -ChangeSet@1.1178.1.4, 2004-04-07 20:45:38-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1178.1.4, 2004-04-07 20:45:38-04:00, stenn@whimsy.udel.edu refclock_oncore.c cleanup from Reg Clemens - ntpd/refclock_oncore.c@1.51, 2004-04-07 20:45:29-04:00, stenn@whimsy.udel.edu +0 -11 + ntpd/refclock_oncore.c@1.51 +0 -11 refclock_oncore.c cleanup from Reg Clemens -ChangeSet@1.1177.1.5, 2004-04-07 20:38:47-04:00, stenn@whimsy.udel.edu +8 -0 +ChangeSet@1.1177.1.5, 2004-04-07 20:38:47-04:00, stenn@whimsy.udel.edu Cleanup from Dave Mills - include/ntp.h@1.100, 2004-04-07 20:38:35-04:00, stenn@whimsy.udel.edu +2 -0 + include/ntp.h@1.100 +2 -0 Cleanup from Dave Mills - include/ntp_control.h@1.25, 2004-04-07 20:38:36-04:00, stenn@whimsy.udel.edu +7 -6 + include/ntp_control.h@1.25 +7 -6 Cleanup from Dave Mills - include/ntp_crypto.h@1.34, 2004-04-07 20:38:36-04:00, stenn@whimsy.udel.edu +2 -3 + include/ntp_crypto.h@1.34 +2 -3 Cleanup from Dave Mills - ntpd/ntp_control.c@1.70, 2004-04-07 20:38:36-04:00, stenn@whimsy.udel.edu +20 -10 + ntpd/ntp_control.c@1.70 +20 -10 Cleanup from Dave Mills - ntpd/ntp_crypto.c@1.93, 2004-04-07 20:38:36-04:00, stenn@whimsy.udel.edu +21 -18 + ntpd/ntp_crypto.c@1.93 +21 -18 Cleanup from Dave Mills - ntpd/ntp_proto.c@1.177, 2004-04-07 20:38:37-04:00, stenn@whimsy.udel.edu +9 -5 + ntpd/ntp_proto.c@1.177 +9 -5 Cleanup from Dave Mills - ntpd/refclock_chu.c@1.35, 2004-04-07 20:38:37-04:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_chu.c@1.35 +1 -1 Cleanup from Dave Mills - ntpq/ntpq.c@1.47, 2004-04-07 20:38:37-04:00, stenn@whimsy.udel.edu +1 -1 + ntpq/ntpq.c@1.47 +1 -1 Cleanup from Dave Mills -ChangeSet@1.1178.1.1, 2004-04-07 16:48:52-04:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1178.1.1, 2004-04-07 16:48:52-04:00, mayer@pogo.udel.edu Fix for Windows select timeout - ntpdate/ntpdate.c@1.47, 2004-04-07 16:48:07-04:00, mayer@pogo.udel.edu +17 -0 + ntpdate/ntpdate.c@1.47 +17 -0 Fix for Windows select timeout -ChangeSet@1.1177.1.4, 2004-04-07 15:48:32-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1177.1.4, 2004-04-07 15:48:32-04:00, stenn@whimsy.udel.edu [Bug 275] Expose needed glue in ntp-keygen - util/ntp-keygen.c@1.28, 2004-04-07 15:48:18-04:00, stenn@whimsy.udel.edu +2 -2 + util/ntp-keygen.c@1.28 +2 -2 [Bug 275] Expose needed glue in ntp-keygen -ChangeSet@1.1177.1.3, 2004-04-06 00:56:17-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1177.1.3, 2004-04-06 00:56:17-04:00, stenn@whimsy.udel.edu cleanup - include/timepps-Solaris.h@1.4, 2004-04-06 00:55:43-04:00, stenn@whimsy.udel.edu +0 -1 + include/timepps-Solaris.h@1.4 +0 -1 cleanup -ChangeSet@1.1177.2.1, 2004-04-06 00:36:24-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1177.2.1, 2004-04-06 00:36:24-04:00, stenn@whimsy.udel.edu Cleanup from Reg Clemens - include/timepps-Solaris.h@1.3, 2004-04-06 00:36:03-04:00, stenn@whimsy.udel.edu +5 -0 + include/timepps-Solaris.h@1.3 +5 -0 Cleanup from Reg Clemens - include/timepps-SunOS.h@1.3, 2004-04-06 00:36:03-04:00, stenn@whimsy.udel.edu +1 -4 + include/timepps-SunOS.h@1.3 +1 -4 Cleanup from Reg Clemens -ChangeSet@1.1177.1.1, 2004-04-05 14:11:34-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1177.1.1, 2004-04-05 14:11:34-04:00, stenn@whimsy.udel.edu [Bug 299] Distribute timepps-*.h - include/Makefile.am@1.19, 2004-04-05 14:11:11-04:00, stenn@whimsy.udel.edu +3 -0 + include/Makefile.am@1.19 +3 -0 [Bug 299] Distribute timepps-*.h -ChangeSet@1.1177, 2004-04-04 23:00:44-04:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1177, 2004-04-04 23:00:44-04:00, stenn@whimsy.udel.edu Cleanup from Dave Mills - include/ntp_crypto.h@1.33, 2004-04-04 23:00:29-04:00, stenn@whimsy.udel.edu +1 -0 + include/ntp_crypto.h@1.33 +1 -0 Cleanup from Dave Mills - ntpd/ntp_crypto.c@1.92, 2004-04-04 23:00:29-04:00, stenn@whimsy.udel.edu +65 -42 + ntpd/ntp_crypto.c@1.92 +65 -42 Cleanup from Dave Mills -ChangeSet@1.1176, 2004-04-04 22:44:03-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1176, 2004-04-04 22:44:03-04:00, stenn@whimsy.udel.edu [Bug 241] Dave agrees the patch is correct. - ntpd/ntp_config.c@1.102.1.2, 2004-04-04 22:43:48-04:00, stenn@whimsy.udel.edu +0 -5 + ntpd/ntp_config.c@1.102.1.2 +0 -5 [Bug 241] Dave agrees the patch is correct. -ChangeSet@1.1175, 2004-04-03 21:18:24-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1175, 2004-04-03 21:18:24-05:00, stenn@whimsy.udel.edu [Bug 275] Build ntp-keygen even if no OPENSSL. - configure.in@1.349, 2004-04-03 21:18:09-05:00, stenn@whimsy.udel.edu +0 -3 + configure.in@1.349 +0 -3 [Bug 275] Build ntp-keygen even if no OPENSSL. - util/Makefile.am@1.24, 2004-04-03 21:18:09-05:00, stenn@whimsy.udel.edu +2 -2 + util/Makefile.am@1.24 +2 -2 [Bug 275] Build ntp-keygen even if no OPENSSL. - util/ntp-keygen.c@1.27, 2004-04-03 21:18:09-05:00, stenn@whimsy.udel.edu +49 -5 + util/ntp-keygen.c@1.27 +49 -5 [Bug 275] Build ntp-keygen even if no OPENSSL. -ChangeSet@1.1174, 2004-04-03 02:48:23-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1174, 2004-04-03 02:48:23-05:00, stenn@whimsy.udel.edu [Bug 241] Fix from Matthias Drochner - ntpd/ntp_config.c@1.102.1.1, 2004-04-03 02:48:10-05:00, stenn@whimsy.udel.edu +2 -1 + ntpd/ntp_config.c@1.102.1.1 +2 -1 [Bug 241] Fix from Matthias Drochner -ChangeSet@1.1152.33.2, 2004-04-03 02:17:22-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.33.2, 2004-04-03 02:17:22-05:00, stenn@whimsy.udel.edu [Bug 277] Ultralink 325 support from Frank Migge - ntpd/refclock_ulink.c@1.13, 2004-04-03 02:17:05-05:00, stenn@whimsy.udel.edu +161 -69 + ntpd/refclock_ulink.c@1.13 +161 -69 [Bug 277] Ultralink 325 support from Frank Migge -ChangeSet@1.1152.33.1, 2004-04-03 01:56:25-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.33.1, 2004-04-03 01:56:25-05:00, stenn@whimsy.udel.edu [Bug 217] Typo in ntptrace - scripts/ntptrace.in@1.4, 2004-04-03 01:56:06-05:00, stenn@whimsy.udel.edu +1 -1 + scripts/ntptrace.in@1.4 +1 -1 [Bug 217] Typo in ntptrace -ChangeSet@1.1152.1.98, 2004-04-02 16:07:14-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.1.98, 2004-04-02 16:07:14-05:00, mayer@pogo.udel.edu remove pps_device[] array that crept back in - ntpd/ntp_config.c@1.103, 2004-04-02 16:06:37-05:00, mayer@pogo.udel.edu +0 -1 + ntpd/ntp_config.c@1.103 +0 -1 remove pps_device[] array that crept back in -ChangeSet@1.1152.1.97, 2004-04-02 15:20:54-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.97, 2004-04-02 15:20:54-05:00, stenn@whimsy.udel.edu [Bug 298] Fix typos in configure.in - configure.in@1.348, 2004-04-02 15:20:37-05:00, stenn@whimsy.udel.edu +2 -2 + configure.in@1.348 +2 -2 [Bug 298] Fix typos in configure.in -ChangeSet@1.1152.32.5, 2004-04-01 15:23:22-05:00, mayer@pogo.udel.edu +8 -0 +ChangeSet@1.1152.32.5, 2004-04-01 15:23:22-05:00, mayer@pogo.udel.edu ntpdc_ops.c: undo all of the changes to the header include order as some systems in the flock had trouble with the reordering ntpdc_ops.c, ntp_intres.c: @@ -23646,752 +204412,752 @@ ChangeSet@1.1152.32.5, 2004-04-01 15:23:22-05:00, mayer@pogo.udel.edu +8 -0 ntp_fp.h: change inclusion order of netinet/in.h and ntp_rfc2553.h - include/ntp_fp.h@1.11, 2004-03-30 18:09:26-05:00, mayer@pogo.udel.edu +1 -1 + include/ntp_fp.h@1.11 +1 -1 change inclusion order of netinet/in.h and ntp_rfc2553.h - ntpd/ntp_config.c@1.102, 2004-03-30 18:41:19-05:00, mayer@pogo.udel.edu +3 -2 + ntpd/ntp_config.c@1.102 +3 -2 reorder includes to make sure that the AI_* macros don't get defined before the system has a chance to define them - ntpd/ntp_intres.c@1.34, 2004-03-30 20:12:11-05:00, mayer@pogo.udel.edu +9 -8 + ntpd/ntp_intres.c@1.34 +9 -8 Undo some of the reordering of includes - ntpd/ntp_intres.c@1.33, 2004-03-30 18:41:20-05:00, mayer@pogo.udel.edu +7 -7 + ntpd/ntp_intres.c@1.33 +7 -7 reorder includes to make sure that the AI_* macros don't get defined before the system has a chance to define them - ntpd/ntp_resolver.c@1.17, 2004-03-30 18:41:20-05:00, mayer@pogo.udel.edu +7 -7 + ntpd/ntp_resolver.c@1.17 +7 -7 reorder includes to make sure that the AI_* macros don't get defined before the system has a chance to define them - ntpd/refclock_nmea.c@1.23, 2004-03-30 18:42:44-05:00, mayer@pogo.udel.edu +5 -5 + ntpd/refclock_nmea.c@1.23 +5 -5 reorder includes to make sure that the AI_* macros don't get defined before the system has a chance to define them - ntpdc/ntpdc.c@1.33, 2004-03-30 18:26:37-05:00, mayer@pogo.udel.edu +5 -5 + ntpdc/ntpdc.c@1.33 +5 -5 reorder includes to make sure that the AI_* macros don't get defined before the system has a chance to define them - ntpdc/ntpdc_ops.c@1.32, 2004-04-01 15:02:55-05:00, mayer@pogo.udel.edu +6 -7 + ntpdc/ntpdc_ops.c@1.32 +6 -7 undo all of the changes to the header include order as some systems in the flock had trouble with the reordering - ntpdc/ntpdc_ops.c@1.31, 2004-03-30 20:12:11-05:00, mayer@pogo.udel.edu +5 -4 + ntpdc/ntpdc_ops.c@1.31 +5 -4 Undo some of the reordering of includes - ntpdc/ntpdc_ops.c@1.30, 2004-03-30 18:43:04-05:00, mayer@pogo.udel.edu +8 -8 + ntpdc/ntpdc_ops.c@1.30 +8 -8 reorder includes to make sure that the AI_* macros don't get defined before the system has a chance to define them - ntpq/ntpq.c@1.46, 2004-03-30 18:26:45-05:00, mayer@pogo.udel.edu +7 -6 + ntpq/ntpq.c@1.46 +7 -6 reorder includes to make sure that the AI_* macros don't get defined before the system has a chance to define them -ChangeSet@1.1152.1.95, 2004-03-29 21:57:51-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.95, 2004-03-29 21:57:51-05:00, stenn@whimsy.udel.edu New irig notes from Dave Mills - ntpd/refclock_irig.c@1.21, 2004-03-29 21:57:12-05:00, stenn@whimsy.udel.edu +14 -14 + ntpd/refclock_irig.c@1.21 +14 -14 New notes from Dave Mills -ChangeSet@1.1152.32.4, 2004-03-26 20:10:51-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.32.4, 2004-03-26 20:10:51-05:00, mayer@pogo.udel.edu remove reference to include netdb.h. porkypine doesn't protect itself against multiple includes - include/ntp_rfc2553.h@1.24, 2004-03-26 20:09:03-05:00, mayer@pogo.udel.edu +0 -1 + include/ntp_rfc2553.h@1.24 +0 -1 remove reference to include netdb.h. porkypine doesn't protect itself against multiple includes -ChangeSet@1.1152.32.3, 2004-03-26 19:39:33-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.32.3, 2004-03-26 19:39:33-05:00, mayer@pogo.udel.edu Remove some includes as porkypine complained - include/ntp_rfc2553.h@1.23, 2004-03-26 19:38:13-05:00, mayer@pogo.udel.edu +1 -13 + include/ntp_rfc2553.h@1.23 +1 -13 Remove some includes as porkypine complained -ChangeSet@1.1152.32.2, 2004-03-26 17:53:26-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1152.32.2, 2004-03-26 17:53:26-05:00, mayer@pogo.udel.edu Fix the macros in ntp_rfc2553.h by including network headers and make ntp_io.c conditionally allow IPv6 multicast only if the macros are defined - include/ntp_rfc2553.h@1.22, 2004-03-26 17:49:45-05:00, mayer@pogo.udel.edu +13 -0 + include/ntp_rfc2553.h@1.22 +13 -0 add includes to ntp_rfc2553.h to ensure that macros are defined in case they don't need to be defined - ntpd/ntp_io.c@1.109, 2004-03-26 17:50:53-05:00, mayer@pogo.udel.edu +2 -2 + ntpd/ntp_io.c@1.109 +2 -2 Make IPV6 multicast conditional on the inclusion of the IPV6_JOIN_GROUP and IPV6_LEAVE_GROUP -ChangeSet@1.1152.32.1, 2004-03-26 09:46:49-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.32.1, 2004-03-26 09:46:49-05:00, mayer@pogo.udel.edu #endif for DEBUG was one line too far down, causing problems with release builds - ntpd/ntp_proto.c@1.176, 2004-03-26 09:44:50-05:00, mayer@pogo.udel.edu +1 -1 + ntpd/ntp_proto.c@1.176 +1 -1 #endif for DEBUG was one line too far down, causing problems with release builds -ChangeSet@1.1152.31.6, 2004-03-25 21:20:54-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.31.6, 2004-03-25 21:20:54-05:00, stenn@whimsy.udel.edu Fixed from Dave Mills. - ntpd/ntp_loopfilter.c@1.94, 2004-03-25 21:20:41-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/ntp_loopfilter.c@1.94 +3 -3 Fixed from Dave Mills. -ChangeSet@1.1152.31.5, 2004-03-25 21:17:21-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.31.5, 2004-03-25 21:17:21-05:00, stenn@whimsy.udel.edu jitter.c fixes from Dave Mills. - util/jitter.c@1.5, 2004-03-25 21:17:03-05:00, stenn@whimsy.udel.edu +67 -5 + util/jitter.c@1.5 +67 -5 fixes from Dave Mills. -ChangeSet@1.1152.31.4, 2004-03-25 21:13:54-05:00, stenn@whimsy.udel.edu +46 -0 +ChangeSet@1.1152.31.4, 2004-03-25 21:13:54-05:00, stenn@whimsy.udel.edu Documentation cleanup/resync with Dave. - html/build/build.html@1.20, 2004-03-25 21:12:17-05:00, stenn@whimsy.udel.edu +12 -12 + html/build/build.html@1.20 +12 -12 Documentation cleanup/resync with Dave. - html/build/config.html@1.18, 2004-03-25 21:12:17-05:00, stenn@whimsy.udel.edu +2 -2 + html/build/config.html@1.18 +2 -2 Documentation cleanup/resync with Dave. - html/build/hints.html@1.14, 2004-03-25 21:12:17-05:00, stenn@whimsy.udel.edu +2 -2 + html/build/hints.html@1.14 +2 -2 Documentation cleanup/resync with Dave. - html/build/hints/solaris.html@1.8, 2004-03-25 21:12:18-05:00, stenn@whimsy.udel.edu +1 -1 + html/build/hints/solaris.html@1.8 +1 -1 Documentation cleanup/resync with Dave. - html/build/hints/vxworks.html@1.7, 2004-03-25 21:12:19-05:00, stenn@whimsy.udel.edu +5 -5 + html/build/hints/vxworks.html@1.7 +5 -5 Documentation cleanup/resync with Dave. - html/build/hints/winnt.html@1.15, 2004-03-25 21:12:19-05:00, stenn@whimsy.udel.edu +4 -4 + html/build/hints/winnt.html@1.15 +4 -4 Documentation cleanup/resync with Dave. - html/build/patches.html@1.17, 2004-03-25 21:12:17-05:00, stenn@whimsy.udel.edu +3 -3 + html/build/patches.html@1.17 +3 -3 Documentation cleanup/resync with Dave. - html/build/porting.html@1.13, 2004-03-25 21:12:17-05:00, stenn@whimsy.udel.edu +2 -2 + html/build/porting.html@1.13 +2 -2 Documentation cleanup/resync with Dave. - html/build/quick.html@1.16, 2004-03-25 21:12:17-05:00, stenn@whimsy.udel.edu +6 -6 + html/build/quick.html@1.16 +6 -6 Documentation cleanup/resync with Dave. - html/drivers/driver1.html@1.14, 2004-03-25 21:12:20-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver1.html@1.14 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver10.html@1.11, 2004-03-25 21:12:20-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver10.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver11.html@1.11, 2004-03-25 21:12:20-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver11.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver12.html@1.11, 2004-03-25 21:12:20-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver12.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver16.html@1.10, 2004-03-25 21:12:20-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver16.html@1.10 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver18.html@1.11, 2004-03-25 21:12:21-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver18.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver19.html@1.10, 2004-03-25 21:12:21-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver19.html@1.10 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver2.html@1.11, 2004-03-25 21:12:21-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver2.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver20.html@1.13, 2004-03-25 21:12:21-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver20.html@1.13 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver22.html@1.15, 2004-03-25 21:12:21-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver22.html@1.15 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver23.html@1.12, 2004-03-25 21:12:21-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver23.html@1.12 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver24.html@1.9, 2004-03-25 21:12:21-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver24.html@1.9 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver26.html@1.9, 2004-03-25 21:12:22-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver26.html@1.9 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver27.html@1.13, 2004-03-25 21:12:22-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver27.html@1.13 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver28.html@1.10, 2004-03-25 21:12:22-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver28.html@1.10 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver29.html@1.12, 2004-03-25 21:12:22-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver29.html@1.12 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver3.html@1.10, 2004-03-25 21:12:22-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver3.html@1.10 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver30.html@1.18, 2004-03-25 21:12:22-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver30.html@1.18 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver32.html@1.11, 2004-03-25 21:12:23-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver32.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver33.html@1.11, 2004-03-25 21:12:23-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver33.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver34.html@1.10, 2004-03-25 21:12:23-05:00, stenn@whimsy.udel.edu +80 -45 + html/drivers/driver34.html@1.10 +80 -45 Documentation cleanup/resync with Dave. - html/drivers/driver35.html@1.13, 2004-03-25 21:12:23-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver35.html@1.13 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver36.html@1.22, 2004-03-25 21:12:23-05:00, stenn@whimsy.udel.edu +3 -3 + html/drivers/driver36.html@1.22 +3 -3 Documentation cleanup/resync with Dave. - html/drivers/driver37.html@1.11, 2004-03-25 21:12:23-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver37.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver38.html@1.11, 2004-03-25 21:12:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver38.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver39.html@1.11, 2004-03-25 21:12:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver39.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver4.html@1.11, 2004-03-25 21:12:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver4.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver40.html@1.10, 2004-03-25 21:12:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver40.html@1.10 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver42.html@1.11, 2004-03-25 21:12:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver42.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver43.html@1.8, 2004-03-25 21:12:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver43.html@1.8 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver44.html@1.10, 2004-03-25 21:12:24-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver44.html@1.10 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver5.html@1.11, 2004-03-25 21:12:25-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver5.html@1.11 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver6.html@1.17, 2004-03-25 21:12:25-05:00, stenn@whimsy.udel.edu +3 -3 + html/drivers/driver6.html@1.17 +3 -3 Documentation cleanup/resync with Dave. - html/drivers/driver7.html@1.20, 2004-03-25 21:12:25-05:00, stenn@whimsy.udel.edu +3 -3 + html/drivers/driver7.html@1.20 +3 -3 Documentation cleanup/resync with Dave. - html/drivers/driver8.html@1.13, 2004-03-25 21:12:25-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver8.html@1.13 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/driver9.html@1.13, 2004-03-25 21:12:25-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver9.html@1.13 +2 -2 Documentation cleanup/resync with Dave. - html/drivers/oncore-shmem.html@1.11, 2004-03-25 21:12:25-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/oncore-shmem.html@1.11 +2 -2 Documentation cleanup/resync with Dave. -ChangeSet@1.1152.1.90, 2004-03-25 20:04:11-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1152.1.90, 2004-03-25 20:04:11-05:00, mayer@pogo.udel.edu Added conditional macro for scope_id - libisc/interfaceiter.c@1.10, 2004-03-25 20:03:21-05:00, mayer@pogo.udel.edu +5 -1 + libisc/interfaceiter.c@1.10 +5 -1 Added conditional macro for scope_id - ntpd/ntp_io.c@1.108, 2004-03-25 20:03:21-05:00, mayer@pogo.udel.edu +4 -0 + ntpd/ntp_io.c@1.108 +4 -0 Added conditional macro for scope_id -ChangeSet@1.1152.31.3, 2004-03-24 23:31:23-05:00, stenn@whimsy.udel.edu +49 -0 +ChangeSet@1.1152.31.3, 2004-03-24 23:31:23-05:00, stenn@whimsy.udel.edu Resync html/ with the master copy from Dave. - html/authopt.html@1.32, 2004-03-24 23:25:13-05:00, stenn@whimsy.udel.edu +5 -5 + html/authopt.html@1.32 +5 -5 Resync html/ with the master copy from Dave. - html/build/build.html@1.19, 2004-03-24 23:19:36-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/build.html@1.19 +0 -0 Rename: html/build.html -> html/build/build.html - html/build/config.html@1.17, 2004-03-24 23:19:36-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/config.html@1.17 +0 -0 Rename: html/config.html -> html/build/config.html - html/build/hints.html@1.13, 2004-03-24 23:19:36-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints.html@1.13 +0 -0 Rename: html/hints.html -> html/build/hints.html - html/build/hints/a-ux@1.3, 2004-03-24 23:10:45-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/a-ux@1.3 +0 -0 mvdir - html/build/hints/aix@1.3, 2004-03-24 23:10:45-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/aix@1.3 +0 -0 mvdir - html/build/hints/bsdi@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/bsdi@1.3 +0 -0 mvdir - html/build/hints/changes@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/changes@1.3 +0 -0 mvdir - html/build/hints/decosf1@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/decosf1@1.3 +0 -0 mvdir - html/build/hints/decosf2@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/decosf2@1.3 +0 -0 mvdir - html/build/hints/freebsd@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/freebsd@1.3 +0 -0 mvdir - html/build/hints/hpux@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/hpux@1.3 +0 -0 mvdir - html/build/hints/linux@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/linux@1.3 +0 -0 mvdir - html/build/hints/mpeix@1.3, 2004-03-24 23:10:46-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/mpeix@1.3 +0 -0 mvdir - html/build/hints/netbsd@1.2, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/netbsd@1.2 +0 -0 mvdir - html/build/hints/notes-xntp-v3@1.3, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/notes-xntp-v3@1.3 +0 -0 mvdir - html/build/hints/parse@1.3, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/parse@1.3 +0 -0 mvdir - html/build/hints/refclocks@1.3, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/refclocks@1.3 +0 -0 mvdir - html/build/hints/rs6000@1.3, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/rs6000@1.3 +0 -0 mvdir - html/build/hints/sco.html@1.7, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/sco.html@1.7 +0 -0 mvdir - html/build/hints/sgi@1.3, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/sgi@1.3 +0 -0 mvdir - html/build/hints/solaris-dosynctodr.html@1.4, 2004-03-24 23:10:47-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/solaris-dosynctodr.html@1.4 +0 -0 mvdir - html/build/hints/solaris.html@1.7, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/solaris.html@1.7 +0 -0 mvdir - html/build/hints/solaris.xtra.4023118@1.3, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/solaris.xtra.4023118@1.3 +0 -0 mvdir - html/build/hints/solaris.xtra.4095849@1.3, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/solaris.xtra.4095849@1.3 +0 -0 mvdir - html/build/hints/solaris.xtra.S99ntpd@1.4, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/solaris.xtra.S99ntpd@1.4 +0 -0 mvdir - html/build/hints/solaris.xtra.patchfreq@1.3, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/solaris.xtra.patchfreq@1.3 +0 -0 mvdir - html/build/hints/sun4@1.3, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/sun4@1.3 +0 -0 mvdir - html/build/hints/svr4-dell@1.3, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/svr4-dell@1.3 +0 -0 mvdir - html/build/hints/svr4_package@1.3, 2004-03-24 23:10:48-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/svr4_package@1.3 +0 -0 mvdir - html/build/hints/todo@1.3, 2004-03-24 23:10:49-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/todo@1.3 +0 -0 mvdir - html/build/hints/vxworks.html@1.6, 2004-03-24 23:10:49-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/vxworks.html@1.6 +0 -0 mvdir - html/build/hints/winnt.html@1.14, 2004-03-24 23:10:49-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/hints/winnt.html@1.14 +0 -0 mvdir - html/build/patches.html@1.16, 2004-03-24 23:19:37-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/patches.html@1.16 +0 -0 Rename: html/patches.html -> html/build/patches.html - html/build/porting.html@1.12, 2004-03-24 23:19:37-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/porting.html@1.12 +0 -0 Rename: html/porting.html -> html/build/porting.html - html/build/quick.html@1.15, 2004-03-24 23:22:11-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/quick.html@1.15 +0 -0 Rename: html/quick.html -> html/build/quick.html - html/build/scripts/footer.txt@1.1, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +7 -0 + html/build/scripts/footer.txt@1.1 +7 -0 - html/build/scripts/footer.txt@1.0, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/footer.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/footer.txt - html/build/scripts/links10.txt@1.1, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +5 -0 + html/build/scripts/links10.txt@1.1 +5 -0 - html/build/scripts/links10.txt@1.0, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/links10.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/links10.txt - html/build/scripts/links11.txt@1.1, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +5 -0 + html/build/scripts/links11.txt@1.1 +5 -0 - html/build/scripts/links11.txt@1.0, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/links11.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/links11.txt - html/build/scripts/links12.txt@1.1, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +5 -0 + html/build/scripts/links12.txt@1.1 +5 -0 - html/build/scripts/links12.txt@1.0, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/links12.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/links12.txt - html/build/scripts/links7.txt@1.1, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +5 -0 + html/build/scripts/links7.txt@1.1 +5 -0 - html/build/scripts/links7.txt@1.0, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/links7.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/links7.txt - html/build/scripts/links8.txt@1.1, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +6 -0 + html/build/scripts/links8.txt@1.1 +6 -0 - html/build/scripts/links8.txt@1.0, 2004-03-24 23:29:11-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/links8.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/links8.txt - html/build/scripts/links9.txt@1.1, 2004-03-24 23:29:12-05:00, stenn@whimsy.udel.edu +7 -0 + html/build/scripts/links9.txt@1.1 +7 -0 - html/build/scripts/links9.txt@1.0, 2004-03-24 23:29:12-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/links9.txt@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/links9.txt - html/build/scripts/style.css@1.1, 2004-03-24 23:29:12-05:00, stenn@whimsy.udel.edu +64 -0 + html/build/scripts/style.css@1.1 +64 -0 - html/build/scripts/style.css@1.0, 2004-03-24 23:29:12-05:00, stenn@whimsy.udel.edu +0 -0 + html/build/scripts/style.css@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/build/scripts/style.css - html/drivers/driver31.html@1.1, 2004-03-24 23:28:57-05:00, stenn@whimsy.udel.edu +56 -0 + html/drivers/driver31.html@1.1 +56 -0 - html/drivers/driver31.html@1.0, 2004-03-24 23:28:57-05:00, stenn@whimsy.udel.edu +0 -0 + html/drivers/driver31.html@1.0 +0 -0 BitKeeper file /deacon/backroom/ntp-dev/html/drivers/driver31.html - html/howto.html@1.17, 2004-03-24 23:25:14-05:00, stenn@whimsy.udel.edu +2 -2 + html/howto.html@1.17 +2 -2 Resync html/ with the master copy from Dave. - html/index.html@1.30, 2004-03-24 23:25:14-05:00, stenn@whimsy.udel.edu +9 -9 + html/index.html@1.30 +9 -9 Resync html/ with the master copy from Dave. - html/notes.html@1.16, 2004-03-24 23:25:15-05:00, stenn@whimsy.udel.edu +2 -2 + html/notes.html@1.16 +2 -2 Resync html/ with the master copy from Dave. - html/release.html@1.29, 2004-03-24 23:25:16-05:00, stenn@whimsy.udel.edu +1 -1 + html/release.html@1.29 +1 -1 Resync html/ with the master copy from Dave. -ChangeSet@1.1152.31.2, 2004-03-24 22:04:57-05:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1152.31.2, 2004-03-24 22:04:57-05:00, stenn@whimsy.udel.edu PPS cleanup from Dave Mills. - include/ntpd.h@1.65, 2004-03-24 22:04:41-05:00, stenn@whimsy.udel.edu +1 -2 + include/ntpd.h@1.65 +1 -2 PPS cleanup from Dave Mills. - ntpd/ntp_config.c@1.101, 2004-03-24 22:04:41-05:00, stenn@whimsy.udel.edu +0 -1 + ntpd/ntp_config.c@1.101 +0 -1 PPS cleanup from Dave Mills. - ntpd/ntp_loopfilter.c@1.93, 2004-03-24 22:04:41-05:00, stenn@whimsy.udel.edu +8 -1 + ntpd/ntp_loopfilter.c@1.93 +8 -1 PPS cleanup from Dave Mills. - ntpd/ntp_refclock.c@1.57, 2004-03-24 22:04:42-05:00, stenn@whimsy.udel.edu +7 -15 + ntpd/ntp_refclock.c@1.57 +7 -15 PPS cleanup from Dave Mills. - ntpd/refclock_atom.c@1.43, 2004-03-24 22:04:42-05:00, stenn@whimsy.udel.edu +11 -13 + ntpd/refclock_atom.c@1.43 +11 -13 PPS cleanup from Dave Mills. -ChangeSet@1.1152.31.1, 2004-03-24 21:55:36-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.31.1, 2004-03-24 21:55:36-05:00, stenn@whimsy.udel.edu Have configure look for struct sockaddr_in6.sin6_scope_id - configure.in@1.347, 2004-03-24 21:55:23-05:00, stenn@whimsy.udel.edu +9 -0 + configure.in@1.347 +9 -0 Have configure look for struct sockaddr_in6.sin6_scope_id -ChangeSet@1.1152.29.3, 2004-03-24 17:27:43-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1152.29.3, 2004-03-24 17:27:43-05:00, mayer@pogo.udel.edu Change u_int64_t to ntp_int64_t to avoid O/S problems - include/ntp_rfc2553.h@1.21, 2004-03-24 17:26:57-05:00, mayer@pogo.udel.edu +2 -2 + include/ntp_rfc2553.h@1.21 +2 -2 Change u_int64_t to ntp_int64_t to avoid O/S problems - include/ntp_types.h@1.7, 2004-03-24 17:26:57-05:00, mayer@pogo.udel.edu +1 -3 + include/ntp_types.h@1.7 +1 -3 Change u_int64_t to ntp_int64_t to avoid O/S problems -ChangeSet@1.1152.1.88, 2004-03-24 00:57:20-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1152.1.88, 2004-03-24 00:57:20-05:00, stenn@pogo.udel.edu No parse clocks if we disable all clocks - flock-build@1.29, 2004-03-24 00:57:07-05:00, stenn@pogo.udel.edu +2 -1 + flock-build@1.29 +2 -1 No parse clocks if we disable all clocks -ChangeSet@1.1152.1.87, 2004-03-23 00:26:24-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.1.87, 2004-03-23 00:26:24-05:00, stenn@whimsy.udel.edu Do --disable-all-clocks in flock-build, too. - build@1.21, 2004-03-23 00:26:15-05:00, stenn@whimsy.udel.edu +6 -0 + build@1.21 +6 -0 Do --disable-all-clocks in flock-build, too. - flock-build@1.28, 2004-03-23 00:26:15-05:00, stenn@whimsy.udel.edu +3 -1 + flock-build@1.28 +3 -1 Do --disable-all-clocks in flock-build, too. -ChangeSet@1.1152.1.86, 2004-03-23 00:07:02-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.1.86, 2004-03-23 00:07:02-05:00, stenn@whimsy.udel.edu no refclock fixes from Dave Mills - ntpd/ntp_control.c@1.69, 2004-03-23 00:06:49-05:00, stenn@whimsy.udel.edu +2 -0 + ntpd/ntp_control.c@1.69 +2 -0 no refclock fixes from Dave Mills - ntpd/ntp_proto.c@1.175, 2004-03-23 00:06:50-05:00, stenn@whimsy.udel.edu +4 -1 + ntpd/ntp_proto.c@1.175 +4 -1 no refclock fixes from Dave Mills -ChangeSet@1.1152.1.85, 2004-03-22 23:59:43-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.85, 2004-03-22 23:59:43-05:00, stenn@whimsy.udel.edu From Dave Mills: remove legacy local_refclock/prefer wrinkle. - ntpd/ntp_loopfilter.c@1.92, 2004-03-22 23:59:30-05:00, stenn@whimsy.udel.edu +0 -13 + ntpd/ntp_loopfilter.c@1.92 +0 -13 From Dave Mills: remove legacy local_refclock/prefer wrinkle. -ChangeSet@1.1152.1.84, 2004-03-20 01:20:11-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.84, 2004-03-20 01:20:11-05:00, stenn@whimsy.udel.edu [Bug 293] - out of bounds array write: Nathan Hintz - util/ntp-keygen.c@1.26, 2004-03-20 01:19:59-05:00, stenn@whimsy.udel.edu +1 -1 + util/ntp-keygen.c@1.26 +1 -1 [Bug 293] - out of bounds array write: Nathan Hintz -ChangeSet@1.1152.29.2, 2004-03-19 19:11:17-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.29.2, 2004-03-19 19:11:17-05:00, mayer@pogo.udel.edu Move AI_NUMERICHOST outside of the ISC_PLATFORM_HAVEIPV6 macro to conditionally include it if it's not defined - include/ntp_rfc2553.h@1.20, 2004-03-19 19:10:40-05:00, mayer@pogo.udel.edu +14 -14 + include/ntp_rfc2553.h@1.20 +14 -14 Move AI_NUMERICHOST outside of the ISC_PLATFORM_HAVEIPV6 macro to conditionally include it if it's not defined -ChangeSet@1.1152.1.82, 2004-03-19 01:48:58-05:00, stenn@deacon.udel.edu +2 -0 +ChangeSet@1.1152.1.82, 2004-03-19 01:48:58-05:00, stenn@deacon.udel.edu Oncore: Remove obsolete checks - BitKeeper/etc/logging_ok@1.48, 2004-03-19 01:48:57-05:00, stenn@deacon.udel.edu +1 -0 + BitKeeper/etc/logging_ok@1.48 +1 -0 Logging to logging@openlogging.org accepted - ntpd/refclock_oncore.c@1.50, 2004-03-19 01:48:32-05:00, stenn@deacon.udel.edu +0 -4 + ntpd/refclock_oncore.c@1.50 +0 -4 Remove obsolete checks -ChangeSet@1.1152.1.81, 2004-03-18 23:54:58-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1152.1.81, 2004-03-18 23:54:58-05:00, stenn@whimsy.udel.edu Use "inline" instead of "__inline" so configure can DTRT. - include/timepps-SCO.h@1.2, 2004-03-18 23:54:40-05:00, stenn@whimsy.udel.edu +7 -7 + include/timepps-SCO.h@1.2 +7 -7 Use "inline" instead of "__inline" so configure can DTRT. - include/timepps-Solaris.h@1.2, 2004-03-18 23:54:40-05:00, stenn@whimsy.udel.edu +7 -7 + include/timepps-Solaris.h@1.2 +7 -7 Use "inline" instead of "__inline" so configure can DTRT. - include/timepps-SunOS.h@1.2, 2004-03-18 23:54:40-05:00, stenn@whimsy.udel.edu +7 -7 + include/timepps-SunOS.h@1.2 +7 -7 Use "inline" instead of "__inline" so configure can DTRT. -ChangeSet@1.1152.1.80, 2004-03-18 23:38:17-05:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1152.1.80, 2004-03-18 23:38:17-05:00, stenn@whimsy.udel.edu Documentation updates from Dave Mills - html/authopt.html@1.31, 2004-03-18 23:37:51-05:00, stenn@whimsy.udel.edu +3 -3 + html/authopt.html@1.31 +3 -3 Updates from Dave Mills - html/howto.html@1.16, 2004-03-18 23:37:52-05:00, stenn@whimsy.udel.edu +1 -1 + html/howto.html@1.16 +1 -1 Updates from Dave Mills - html/index.html@1.29, 2004-03-18 23:37:52-05:00, stenn@whimsy.udel.edu +3 -3 + html/index.html@1.29 +3 -3 Updates from Dave Mills - html/monopt.html@1.18, 2004-03-18 23:37:52-05:00, stenn@whimsy.udel.edu +2 -2 + html/monopt.html@1.18 +2 -2 Updates from Dave Mills - html/refclock.html@1.29, 2004-03-18 23:37:52-05:00, stenn@whimsy.udel.edu +2 -2 + html/refclock.html@1.29 +2 -2 Updates from Dave Mills -ChangeSet@1.1152.1.79, 2004-03-18 23:24:57-05:00, stenn@whimsy.udel.edu +10 -0 +ChangeSet@1.1152.1.79, 2004-03-18 23:24:57-05:00, stenn@whimsy.udel.edu Cleanup and fixed from Dave Mills - include/ntp.h@1.99, 2004-03-18 23:24:41-05:00, stenn@whimsy.udel.edu +2 -2 + include/ntp.h@1.99 +2 -2 Cleanup and fixed from Dave Mills - include/ntpd.h@1.64, 2004-03-18 23:24:41-05:00, stenn@whimsy.udel.edu +2 -1 + include/ntpd.h@1.64 +2 -1 Cleanup and fixed from Dave Mills - libntp/systime.c@1.30, 2004-03-18 23:24:41-05:00, stenn@whimsy.udel.edu +7 -4 + libntp/systime.c@1.30 +7 -4 Cleanup and fixed from Dave Mills - ntpd/ntp_control.c@1.68, 2004-03-18 23:24:42-05:00, stenn@whimsy.udel.edu +3 -4 + ntpd/ntp_control.c@1.68 +3 -4 Cleanup and fixed from Dave Mills - ntpd/ntp_loopfilter.c@1.91, 2004-03-18 23:24:42-05:00, stenn@whimsy.udel.edu +26 -43 + ntpd/ntp_loopfilter.c@1.91 +26 -43 Cleanup and fixed from Dave Mills - ntpd/ntp_proto.c@1.174, 2004-03-18 23:24:42-05:00, stenn@whimsy.udel.edu +128 -126 + ntpd/ntp_proto.c@1.174 +128 -126 Cleanup and fixed from Dave Mills - ntpd/ntp_refclock.c@1.56, 2004-03-18 23:24:43-05:00, stenn@whimsy.udel.edu +72 -36 + ntpd/ntp_refclock.c@1.56 +72 -36 Cleanup and fixed from Dave Mills - ntpd/ntp_request.c@1.56, 2004-03-18 23:24:43-05:00, stenn@whimsy.udel.edu +0 -18 + ntpd/ntp_request.c@1.56 +0 -18 Cleanup and fixed from Dave Mills - ntpd/refclock_arbiter.c@1.8, 2004-03-18 23:24:43-05:00, stenn@whimsy.udel.edu +20 -20 + ntpd/refclock_arbiter.c@1.8 +20 -20 Cleanup and fixed from Dave Mills - ntpd/refclock_wwvb.c@1.12, 2004-03-18 23:24:43-05:00, stenn@whimsy.udel.edu +4 -3 + ntpd/refclock_wwvb.c@1.12 +4 -3 Cleanup and fixed from Dave Mills -ChangeSet@1.1152.1.78, 2004-03-18 23:15:06-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.1.78, 2004-03-18 23:15:06-05:00, stenn@whimsy.udel.edu Driver36 cleanup from Dave Mills - html/drivers/driver36.html@1.21, 2004-03-18 23:14:38-05:00, stenn@whimsy.udel.edu +4 -3 + html/drivers/driver36.html@1.21 +4 -3 Cleanup from Dave Mills - html/scripts/links8.txt@1.2, 2004-03-18 23:14:38-05:00, stenn@whimsy.udel.edu +3 -3 + html/scripts/links8.txt@1.2 +3 -3 Cleanup from Dave Mills -ChangeSet@1.1152.1.77, 2004-03-17 17:11:42-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1152.1.77, 2004-03-17 17:11:42-05:00, stenn@pogo.udel.edu Pedantic compiler lint - sntp/header.h@1.4, 2004-03-17 17:11:29-05:00, stenn@pogo.udel.edu +2 -2 + sntp/header.h@1.4 +2 -2 Pedantic compiler lint -ChangeSet@1.1152.1.76, 2004-03-17 17:10:30-05:00, stenn@pogo.udel.edu +4 -0 +ChangeSet@1.1152.1.76, 2004-03-17 17:10:30-05:00, stenn@pogo.udel.edu oncore fixes from Reg Clemens - include/timepps-SCO.h@1.1, 2004-03-17 17:03:57-05:00, stenn@pogo.udel.edu +503 -0 + include/timepps-SCO.h@1.1 +503 -0 - include/timepps-SCO.h@1.0, 2004-03-17 17:03:57-05:00, stenn@pogo.udel.edu +0 -0 + include/timepps-SCO.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev/include/timepps-SCO.h - include/timepps-Solaris.h@1.1, 2004-03-17 17:03:58-05:00, stenn@pogo.udel.edu +497 -0 + include/timepps-Solaris.h@1.1 +497 -0 - include/timepps-Solaris.h@1.0, 2004-03-17 17:03:58-05:00, stenn@pogo.udel.edu +0 -0 + include/timepps-Solaris.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev/include/timepps-Solaris.h - include/timepps-SunOS.h@1.1, 2004-03-17 17:03:58-05:00, stenn@pogo.udel.edu +507 -0 + include/timepps-SunOS.h@1.1 +507 -0 - include/timepps-SunOS.h@1.0, 2004-03-17 17:03:58-05:00, stenn@pogo.udel.edu +0 -0 + include/timepps-SunOS.h@1.0 +0 -0 BitKeeper file /pogo/users/stenn/ntp-dev/include/timepps-SunOS.h - ntpd/refclock_oncore.c@1.49, 2004-03-17 17:09:39-05:00, stenn@pogo.udel.edu +85 -132 + ntpd/refclock_oncore.c@1.49 +85 -132 Patches/cleanup from Reg Clemens. Header realignment from Harlan. -ChangeSet@1.1152.29.1, 2004-03-15 21:04:56-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1152.29.1, 2004-03-15 21:04:56-05:00, mayer@tecotoo. Update to ensure the I/O Completion Ports code checks the various error states and sets the return status correctly - ports/winnt/ntpd/ntp_iocompletionport.c@1.11, 2004-03-15 21:04:28-05:00, mayer@tecotoo. +20 -6 + ports/winnt/ntpd/ntp_iocompletionport.c@1.11 +20 -6 Update to ensure the I/O Completion Ports code checks the various error states and sets the return status correctly -ChangeSet@1.1152.1.72, 2004-03-14 22:04:31-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1152.1.72, 2004-03-14 22:04:31-05:00, mayer@tecotoo. LIB_GETBUF only has space for 20 entries and does not zero out the contents. Change the limit to 200 and zero out the contents before returning it - libntp/lib_strbuf.h@1.3, 2004-03-14 22:04:03-05:00, mayer@tecotoo. +2 -1 + libntp/lib_strbuf.h@1.3 +2 -1 LIB_GETBUF only has space for 20 entries and does not zero out the contents. Change the limit to 200 and zero out the contents before returning it -ChangeSet@1.1152.1.71, 2004-03-13 22:06:42-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1152.1.71, 2004-03-13 22:06:42-05:00, mayer@tecotoo. ntp_types.h needs to include sys/types.h - include/ntp_rfc2553.h@1.19, 2004-03-13 22:06:13-05:00, mayer@tecotoo. +0 -1 + include/ntp_rfc2553.h@1.19 +0 -1 ntp_types.h needs to include sys/types.h - include/ntp_types.h@1.6, 2004-03-13 22:06:14-05:00, mayer@tecotoo. +1 -0 + include/ntp_types.h@1.6 +1 -0 ntp_types.h needs to include sys/types.h -ChangeSet@1.1152.28.1, 2004-03-12 22:17:41-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.28.1, 2004-03-12 22:17:41-05:00, stenn@whimsy.udel.edu [Bug 283] fix (md5.h header check) - configure.in@1.346, 2004-03-12 22:17:29-05:00, stenn@whimsy.udel.edu +5 -1 + configure.in@1.346 +5 -1 [Bug 283] fix (md5.h header check) -ChangeSet@1.1152.1.70, 2004-03-11 23:47:33-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1152.1.70, 2004-03-11 23:47:33-05:00, mayer@tecotoo. move some conditionals back inside ISC_PLATFORM_HAVEIPV6 to reduce warnings if already defined elsewhere - include/ntp_rfc2553.h@1.18, 2004-03-11 23:47:05-05:00, mayer@tecotoo. +2 -2 + include/ntp_rfc2553.h@1.18 +2 -2 move some conditionals back inside ISC_PLATFORM_HAVEIPV6 to reduce warnings if already defined elsewhere -ChangeSet@1.1152.1.69, 2004-03-11 22:55:24-05:00, mayer@tecotoo. +2 -0 +ChangeSet@1.1152.1.69, 2004-03-11 22:55:24-05:00, mayer@tecotoo. move integer type definitions from ntp_rfc2553.h into ntp_types.h where they belong - include/ntp_rfc2553.h@1.17, 2004-03-11 22:54:56-05:00, mayer@tecotoo. +0 -10 + include/ntp_rfc2553.h@1.17 +0 -10 move integer type definitions from ntp_rfc2553.h into ntp_types.h where they belong - include/ntp_types.h@1.5, 2004-03-11 22:54:56-05:00, mayer@tecotoo. +10 -0 + include/ntp_types.h@1.5 +10 -0 move integer type definitions from ntp_rfc2553.h into ntp_types.h where they belong -ChangeSet@1.1152.1.68, 2004-03-10 17:51:29-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.1.68, 2004-03-10 17:51:29-05:00, mayer@pogo.udel.edu Move some macros outside of ISC_PLATFORM_HAVEIPV6 conditional macro and check for inclusion - include/ntp_rfc2553.h@1.16, 2004-03-10 17:50:19-05:00, mayer@pogo.udel.edu +16 -8 + include/ntp_rfc2553.h@1.16 +16 -8 Move some macros outside of ISC_PLATFORM_HAVEIPV6 conditional macro and check for inclusion -ChangeSet@1.1152.1.67, 2004-03-09 22:24:49-05:00, mayer@tecotoo. +1 -0 +ChangeSet@1.1152.1.67, 2004-03-09 22:24:49-05:00, mayer@tecotoo. Fix order of variable declarations to ensure required types are declared first for the following structures - include/ntp_rfc2553.h@1.15, 2004-03-09 22:24:24-05:00, mayer@tecotoo. +15 -15 + include/ntp_rfc2553.h@1.15 +15 -15 Fix order of variable declarations to ensure required types are declared first for the following structures -ChangeSet@1.1172, 2004-03-05 12:45:00-08:00, gnu@ring.wraith.sf.ca.us +1 -0 +ChangeSet@1.1172, 2004-03-05 12:45:00-08:00, gnu@ring.wraith.sf.ca.us add Ross Alexander's fixes for /etc/ntp.audioX - libntp/audio.c@1.22, 2004-03-05 12:45:00-08:00, gnu@ring.wraith.sf.ca.us +15 -9 + libntp/audio.c@1.22 +15 -9 add Ross Alexander's fixes for /etc/ntp.audioX -ChangeSet@1.1152.1.64, 2004-03-03 00:57:05-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.1.64, 2004-03-03 00:57:05-05:00, stenn@whimsy.udel.edu More cleanup/fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.90, 2004-03-03 00:56:51-05:00, stenn@whimsy.udel.edu +139 -141 + ntpd/ntp_loopfilter.c@1.90 +139 -141 More cleanup/fixes from Dave Mills - ntpd/ntp_proto.c@1.173, 2004-03-03 00:56:52-05:00, stenn@whimsy.udel.edu +27 -11 + ntpd/ntp_proto.c@1.173 +27 -11 More cleanup/fixes from Dave Mills -ChangeSet@1.1152.1.63, 2004-03-03 00:49:55-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.63, 2004-03-03 00:49:55-05:00, stenn@whimsy.udel.edu Fix the sockaddr_storage check - configure.in@1.345, 2004-03-03 00:49:41-05:00, stenn@whimsy.udel.edu +1 -2 + configure.in@1.345 +1 -2 Fix the sockaddr_storage check -ChangeSet@1.1152.1.62, 2004-03-02 22:21:11-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.62, 2004-03-02 22:21:11-05:00, stenn@whimsy.udel.edu Re-enable support for Reliant & SCO - libntp/systime.c@1.29, 2004-03-02 22:20:46-05:00, stenn@whimsy.udel.edu +5 -1 + libntp/systime.c@1.29 +5 -1 Re-enable support for Reliant & SCO -ChangeSet@1.1152.1.61, 2004-02-18 19:56:01-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1152.1.61, 2004-02-18 19:56:01-05:00, stenn@whimsy.udel.edu More cleanup from Dave Mills - include/ntpd.h@1.63, 2004-02-18 19:55:47-05:00, stenn@whimsy.udel.edu +1 -1 + include/ntpd.h@1.63 +1 -1 More cleanup from Dave Mills - ntpd/ntp_proto.c@1.172, 2004-02-18 19:55:47-05:00, stenn@whimsy.udel.edu +40 -37 + ntpd/ntp_proto.c@1.172 +40 -37 More cleanup from Dave Mills - ntpd/ntp_refclock.c@1.55, 2004-02-18 19:55:48-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_refclock.c@1.55 +1 -1 More cleanup from Dave Mills -ChangeSet@1.1152.1.60, 2004-02-18 00:56:22-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.1.60, 2004-02-18 00:56:22-05:00, stenn@whimsy.udel.edu Revert the change that required Recent auto*, to fix bug 230. I will still roll tarballs with these recent releases so folks who get tarballs won't see that bug. Only folks otherwise affected by bug 230 will need the latest auto*. - Makefile.am@1.46, 2004-02-18 00:56:17-05:00, stenn@whimsy.udel.edu +1 -1 + Makefile.am@1.46 +1 -1 Revert the change that required Recent auto*, to fix bug 230. I will still roll tarballs with these recent releases so folks who get tarballs won't see that bug. Only folks otherwise affected by bug 230 will need the latest auto*. - configure.in@1.344, 2004-02-18 00:56:18-05:00, stenn@whimsy.udel.edu +1 -1 + configure.in@1.344 +1 -1 Revert the change that required Recent auto*, to fix bug 230. I will still roll tarballs with these recent releases so folks who get tarballs won't see that bug. Only folks otherwise affected by bug 230 will need the latest auto*. -ChangeSet@1.1152.26.1, 2004-02-17 01:43:41-05:00, stenn@whimsy.udel.edu +8 -0 +ChangeSet@1.1152.26.1, 2004-02-17 01:43:41-05:00, stenn@whimsy.udel.edu Cleanup from Dave Mills. - include/ntp.h@1.98, 2004-02-17 01:43:25-05:00, stenn@whimsy.udel.edu +0 -1 + include/ntp.h@1.98 +0 -1 Cleanup from Dave Mills. - include/ntpd.h@1.62, 2004-02-17 01:43:25-05:00, stenn@whimsy.udel.edu +1 -1 + include/ntpd.h@1.62 +1 -1 Cleanup from Dave Mills. - ntpd/ntp_crypto.c@1.91, 2004-02-17 01:43:25-05:00, stenn@whimsy.udel.edu +9 -9 + ntpd/ntp_crypto.c@1.91 +9 -9 Cleanup from Dave Mills. - ntpd/ntp_loopfilter.c@1.89, 2004-02-17 01:43:26-05:00, stenn@whimsy.udel.edu +0 -4 + ntpd/ntp_loopfilter.c@1.89 +0 -4 Cleanup from Dave Mills. - ntpd/ntp_peer.c@1.59, 2004-02-17 01:43:26-05:00, stenn@whimsy.udel.edu +1 -2 + ntpd/ntp_peer.c@1.59 +1 -2 Cleanup from Dave Mills. - ntpd/ntp_proto.c@1.171, 2004-02-17 01:43:27-05:00, stenn@whimsy.udel.edu +98 -84 + ntpd/ntp_proto.c@1.171 +98 -84 Cleanup from Dave Mills. - ntpd/ntp_refclock.c@1.54, 2004-02-17 01:43:27-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_refclock.c@1.54 +1 -1 Cleanup from Dave Mills. - ntpd/refclock_arbiter.c@1.7, 2004-02-17 01:43:28-05:00, stenn@whimsy.udel.edu +2 -1 + ntpd/refclock_arbiter.c@1.7 +2 -1 Cleanup from Dave Mills. -ChangeSet@1.1152.25.6, 2004-02-16 22:35:20-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1152.25.6, 2004-02-16 22:35:20-05:00, stenn@whimsy.udel.edu Let the ONCORE refclock build without PPS. From Reg Clemens. - html/drivers/driver30.html@1.17, 2004-02-16 22:34:32-05:00, stenn@whimsy.udel.edu +2 -2 + html/drivers/driver30.html@1.17 +2 -2 Let the ONCORE refclock build without PPS. From Reg Clemens. - ntpd/refclock_conf.c@1.23, 2004-02-16 22:34:33-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_conf.c@1.23 +1 -1 Let the ONCORE refclock build without PPS. From Reg Clemens. - ntpd/refclock_oncore.c@1.48, 2004-02-16 22:34:33-05:00, stenn@whimsy.udel.edu +89 -53 + ntpd/refclock_oncore.c@1.48 +89 -53 Let the ONCORE refclock build without PPS. From Reg Clemens. -ChangeSet@1.1152.25.5, 2004-02-14 22:05:42-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.25.5, 2004-02-14 22:05:42-05:00, stenn@whimsy.udel.edu Disable check_y2k for now (34 year bug?) - configure.in@1.343, 2004-02-14 22:05:29-05:00, stenn@whimsy.udel.edu +2 -1 + configure.in@1.343 +2 -1 Disable check_y2k for now (34 year bug?) -ChangeSet@1.1152.25.4, 2004-02-13 23:54:07-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.25.4, 2004-02-13 23:54:07-05:00, stenn@whimsy.udel.edu Dave's recent patch assumed we had OPENSSL. Handle the other case. - ntpd/ntp_proto.c@1.170, 2004-02-13 23:53:52-05:00, stenn@whimsy.udel.edu +2 -0 + ntpd/ntp_proto.c@1.170 +2 -0 Dave's recent patch assumed we had OPENSSL. Handle the other case. -ChangeSet@1.1152.25.3, 2004-02-12 04:27:25-05:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1152.25.3, 2004-02-12 04:27:25-05:00, stenn@whimsy.udel.edu Changes from Dave Mills: 1. Servers presented with key IDs they don't have (a common mistake) @@ -24435,146 +205201,146 @@ ChangeSet@1.1152.25.3, 2004-02-12 04:27:25-05:00, stenn@whimsy.udel.edu +4 -0 assuming, that is, PGP mail is used to get the keys and the server certificates are properly signed. - include/ntp.h@1.97, 2004-02-12 04:22:55-05:00, stenn@whimsy.udel.edu +7 -5 + include/ntp.h@1.97 +7 -5 Changes from Dave Mills - ntpd/ntp_crypto.c@1.90, 2004-02-12 04:22:56-05:00, stenn@whimsy.udel.edu +16 -17 + ntpd/ntp_crypto.c@1.90 +16 -17 Changes from Dave Mills - ntpd/ntp_proto.c@1.169, 2004-02-12 04:22:56-05:00, stenn@whimsy.udel.edu +200 -199 + ntpd/ntp_proto.c@1.169 +200 -199 Changes from Dave Mills - ntpd/ntp_refclock.c@1.53, 2004-02-12 04:22:57-05:00, stenn@whimsy.udel.edu +1 -2 + ntpd/ntp_refclock.c@1.53 +1 -2 Changes from Dave Mills -ChangeSet@1.1152.14.12, 2004-02-11 20:02:55-05:00, stenn@whimsy.udel.edu +7 -0 +ChangeSet@1.1152.14.12, 2004-02-11 20:02:55-05:00, stenn@whimsy.udel.edu Prepare for move from whimsy to deacon. - BitKeeper/triggers/2mirrors@1.2, 2004-02-11 20:01:56-05:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/triggers/2mirrors@1.2 +1 -0 Prepare for move from whimsy to deacon. - BitKeeper/triggers/changelog@1.2, 2004-02-11 20:01:56-05:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/triggers/changelog@1.2 +1 -0 Prepare for move from whimsy to deacon. - BitKeeper/triggers/commitlogs@1.4, 2004-02-11 20:01:57-05:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/triggers/commitlogs@1.4 +1 -0 Prepare for move from whimsy to deacon. - BitKeeper/triggers/delta-changelog@1.6, 2004-02-11 20:01:57-05:00, stenn@whimsy.udel.edu +2 -1 + BitKeeper/triggers/delta-changelog@1.6 +2 -1 Prepare for move from whimsy to deacon. - BitKeeper/triggers/notify@1.2, 2004-02-11 20:01:57-05:00, stenn@whimsy.udel.edu +2 -1 + BitKeeper/triggers/notify@1.2 +2 -1 Prepare for move from whimsy to deacon. - BitKeeper/triggers/paranoid@1.2, 2004-02-11 20:01:57-05:00, stenn@whimsy.udel.edu +4 -1 + BitKeeper/triggers/paranoid@1.2 +4 -1 Prepare for move from whimsy to deacon. - BitKeeper/triggers/send@1.4, 2004-02-11 20:01:58-05:00, stenn@whimsy.udel.edu +1 -0 + BitKeeper/triggers/send@1.4 +1 -0 Prepare for move from whimsy to deacon. -ChangeSet@1.1152.14.11, 2004-02-10 20:05:16-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.14.11, 2004-02-10 20:05:16-05:00, stenn@whimsy.udel.edu Cleanup - README.bk@1.17, 2004-02-10 20:05:04-05:00, stenn@whimsy.udel.edu +3 -11 + README.bk@1.17 +3 -11 Cleanup -ChangeSet@1.1152.22.10, 2004-02-10 16:42:03-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.22.10, 2004-02-10 16:42:03-05:00, mayer@pogo.udel.edu Move NT specific add to completion ports inside of the open_socket code - ntpd/ntp_io.c@1.105.1.1, 2004-02-10 16:41:39-05:00, mayer@pogo.udel.edu +18 -20 + ntpd/ntp_io.c@1.105.1.1 +18 -20 Move NT specific add to completion ports inside of the open_socket code -ChangeSet@1.1152.24.3, 2004-02-07 17:53:39+00:00, mbrett@rgs16.fordson.demon.co.uk +4 -0 +ChangeSet@1.1152.24.3, 2004-02-07 17:53:39+00:00, mbrett@rgs16.fordson.demon.co.uk humandate.c, caljulian.c, ntp_fp.h: Syntax changes to allow K&R compilers - BitKeeper/etc/logging_ok@1.42.1.2, 2004-02-07 17:53:38+00:00, mbrett@rgs16.fordson.demon.co.uk +1 -0 + BitKeeper/etc/logging_ok@1.42.1.2 +1 -0 Logging to logging@openlogging.org accepted - include/ntp_fp.h@1.7.1.1, 2004-02-07 17:46:59+00:00, mbrett@rgs16.fordson.demon.co.uk +2 -0 + include/ntp_fp.h@1.7.1.1 +2 -0 Syntax changes to allow K&R compilers - libntp/caljulian.c@1.6, 2004-02-07 17:47:52+00:00, mbrett@rgs16.fordson.demon.co.uk +2 -3 + libntp/caljulian.c@1.6 +2 -3 Syntax changes to allow K&R compilers - libntp/humandate.c@1.6, 2004-02-07 17:48:04+00:00, mbrett@rgs16.fordson.demon.co.uk +0 -2 + libntp/humandate.c@1.6 +0 -2 Syntax changes to allow K&R compilers -ChangeSet@1.1152.22.8, 2004-02-05 19:46:43-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.22.8, 2004-02-05 19:46:43-05:00, mayer@pogo.udel.edu Fix for sockaddr_storage includes - include/ntp_rfc2553.h@1.12.1.1, 2004-02-05 19:46:02-05:00, mayer@pogo.udel.edu +45 -31 + include/ntp_rfc2553.h@1.12.1.1 +45 -31 Fix for sockaddr_storage includes -ChangeSet@1.1152.24.2, 2004-01-26 21:43:00-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.24.2, 2004-01-26 21:43:00-05:00, stenn@whimsy.udel.edu struct sockaddr_storage progress - configure.in@1.342, 2004-01-26 21:42:46-05:00, stenn@whimsy.udel.edu +0 -2 + configure.in@1.342 +0 -2 struct sockaddr_storage progress - include/ntp_rfc2553.h@1.13, 2004-01-26 21:42:47-05:00, stenn@whimsy.udel.edu +0 -2 + include/ntp_rfc2553.h@1.13 +0 -2 struct sockaddr_storage progress -ChangeSet@1.1152.24.1, 2004-01-25 22:14:09-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.24.1, 2004-01-25 22:14:09-05:00, stenn@whimsy.udel.edu Don't use IPv6 on AIX4. - configure.in@1.341, 2004-01-25 22:13:57-05:00, stenn@whimsy.udel.edu +10 -5 + configure.in@1.341 +10 -5 Don't use IPv6 on AIX4. -ChangeSet@1.1152.22.6, 2004-01-22 20:59:27-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.22.6, 2004-01-22 20:59:27-05:00, stenn@whimsy.udel.edu Postpone the stuct sockaddr_storage test for now. - configure.in@1.340, 2004-01-22 20:59:18-05:00, stenn@whimsy.udel.edu +2 -0 + configure.in@1.340 +2 -0 Postpone the stuct sockaddr_storage test for now. -ChangeSet@1.1152.22.5, 2004-01-22 17:49:57-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.22.5, 2004-01-22 17:49:57-05:00, stenn@whimsy.udel.edu Use doubles instead of NTP timestamps to work around the 34 year problem. From Dave Mills. - ntpd/ntp_proto.c@1.168, 2004-01-22 17:49:28-05:00, stenn@whimsy.udel.edu +32 -21 + ntpd/ntp_proto.c@1.168 +32 -21 Use doubles instead of NTP timestamps to work around the 34 year problem. From Dave Mills. -ChangeSet@1.1152.22.4, 2004-01-22 17:45:13-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.22.4, 2004-01-22 17:45:13-05:00, stenn@whimsy.udel.edu jitter utility fixes from Dave Mills. - util/jitter.c@1.4, 2004-01-22 17:42:39-05:00, stenn@whimsy.udel.edu +15 -16 + util/jitter.c@1.4 +15 -16 Fixes from Dave Mills. - util/jitter.h@1.1, 2004-01-22 17:42:50-05:00, stenn@whimsy.udel.edu +412 -0 + util/jitter.h@1.1 +412 -0 - util/jitter.h@1.0, 2004-01-22 17:42:50-05:00, stenn@whimsy.udel.edu +0 -0 + util/jitter.h@1.0 +0 -0 BitKeeper file /backroom/ntp-dev/util/jitter.h -ChangeSet@1.1152.23.2, 2004-01-22 17:35:01-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.23.2, 2004-01-22 17:35:01-05:00, mayer@pogo.udel.edu L_RSHIFTU was mapped to M_RSHIFT instead of M_RSHIFTU - include/ntp_fp.h@1.8, 2004-01-22 17:34:04-05:00, mayer@pogo.udel.edu +1 -1 + include/ntp_fp.h@1.8 +1 -1 L_RSHIFTU was mapped to M_RSHIFT instead of M_RSHIFTU -ChangeSet@1.1152.22.3, 2004-01-22 04:07:41+01:00, blk@frobozz.local +2 -0 +ChangeSet@1.1152.22.3, 2004-01-22 04:07:41+01:00, blk@frobozz.local nl.pl.in: Better accounting for possible whitespace at the end of C routines (Bug 210). - BitKeeper/etc/logging_ok@1.42.1.1, 2004-01-22 04:07:34+01:00, blk@frobozz.local +1 -0 + BitKeeper/etc/logging_ok@1.42.1.1 +1 -0 Logging to logging@openlogging.org accepted - ntpdc/nl.pl.in@1.8, 2004-01-22 04:05:55+01:00, blk@frobozz.local +1 -1 + ntpdc/nl.pl.in@1.8 +1 -1 Better accounting for possible whitespace at the end of C routines (Bug 210). -ChangeSet@1.1152.23.1, 2004-01-21 19:35:11-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.23.1, 2004-01-21 19:35:11-05:00, mayer@pogo.udel.edu eliminate no error select reporting - ntpdate/ntpdate.c@1.46, 2004-01-21 19:34:29-05:00, mayer@pogo.udel.edu +4 -7 + ntpdate/ntpdate.c@1.46 +4 -7 eliminate no error select reporting -ChangeSet@1.1152.22.2, 2004-01-10 21:10:11-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.22.2, 2004-01-10 21:10:11-05:00, stenn@whimsy.udel.edu initial attempt at more rfc2553 cleanup - configure.in@1.339, 2004-01-10 21:09:59-05:00, stenn@whimsy.udel.edu +87 -1 + configure.in@1.339 +87 -1 initial attempt at more rfc2553 cleanup - include/ntp_rfc2553.h@1.12, 2004-01-10 21:10:00-05:00, stenn@whimsy.udel.edu +2 -0 + include/ntp_rfc2553.h@1.12 +2 -0 initial attempt at more rfc2553 cleanup -ChangeSet@1.1152.14.10, 2004-01-10 02:27:07-05:00, stenn@pogo.udel.edu +2 -0 +ChangeSet@1.1152.14.10, 2004-01-10 02:27:07-05:00, stenn@pogo.udel.edu Fixes from Reg Clemens: Cleanup. @@ -24582,13 +205348,13 @@ ChangeSet@1.1152.14.10, 2004-01-10 02:27:07-05:00, stenn@pogo.udel.edu +2 -0 [Bug 246] [Bug 260] - html/drivers/driver30.html@1.16, 2004-01-10 02:27:01-05:00, stenn@pogo.udel.edu +8 -8 + html/drivers/driver30.html@1.16 +8 -8 Fixes from Reg Clemens: I have changed the documentation page for the ONCORE so it no longer references Flag2/Flag3. - ntpd/refclock_oncore.c@1.47, 2004-01-10 02:27:01-05:00, stenn@pogo.udel.edu +104 -137 + ntpd/refclock_oncore.c@1.47 +104 -137 Fixes from Reg Clemens: some (minor) changes: @@ -24646,657 +205412,657 @@ ChangeSet@1.1152.14.10, 2004-01-10 02:27:07-05:00, stenn@pogo.udel.edu +2 -0 Rather than his #ifdef, I have corrected the code. -ChangeSet@1.1152.19.3, 2004-01-08 18:21:43-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.19.3, 2004-01-08 18:21:43-05:00, mayer@pogo.udel.edu Make call to get_scopeid conditional - libisc/ifiter_ioctl.c@1.18, 2004-01-08 18:20:39-05:00, mayer@pogo.udel.edu +2 -1 + libisc/ifiter_ioctl.c@1.18 +2 -1 Make call to get_scopeid conditional -ChangeSet@1.1152.19.2, 2004-01-08 16:07:57-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.19.2, 2004-01-08 16:07:57-05:00, mayer@pogo.udel.edu Make fetch of broadcast address conditional on existence of macro - libisc/ifiter_ioctl.c@1.17, 2004-01-08 16:07:23-05:00, mayer@pogo.udel.edu +2 -1 + libisc/ifiter_ioctl.c@1.17 +2 -1 Make fetch of broadcast address conditional on existence of macro -ChangeSet@1.1152.1.56, 2004-01-08 17:55:23+00:00, mbrett@rgs16.fordson.demon.co.uk +1 -0 +ChangeSet@1.1152.1.56, 2004-01-08 17:55:23+00:00, mbrett@rgs16.fordson.demon.co.uk Makefile.am: Remove $(NULL). It has no effect. - util/Makefile.am@1.23, 2004-01-08 17:54:24+00:00, mbrett@rgs16.fordson.demon.co.uk +1 -2 + util/Makefile.am@1.23 +1 -2 Remove $(NULL). It has no effect. -ChangeSet@1.1152.1.55, 2004-01-08 13:36:54+00:00, mbrett@rgs16.fordson.demon.co.uk +2 -0 +ChangeSet@1.1152.1.55, 2004-01-08 13:36:54+00:00, mbrett@rgs16.fordson.demon.co.uk refclock_arc.c: gcc lint for isdigit() - BitKeeper/etc/logging_ok@1.43, 2004-01-08 13:36:52+00:00, mbrett@rgs16.fordson.demon.co.uk +1 -0 + BitKeeper/etc/logging_ok@1.43 +1 -0 Logging to logging@openlogging.org accepted - ntpd/refclock_arc.c@1.17, 2004-01-08 13:34:44+00:00, mbrett@rgs16.fordson.demon.co.uk +1 -1 + ntpd/refclock_arc.c@1.17 +1 -1 gcc lint for isdigit() -ChangeSet@1.1152.19.1, 2004-01-06 20:55:01-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.19.1, 2004-01-06 20:55:01-05:00, mayer@pogo.udel.edu Broadcast addresses were not being set for systems with IPv6 capability - libisc/ifiter_ioctl.c@1.16, 2004-01-06 20:54:15-05:00, mayer@pogo.udel.edu +21 -0 + libisc/ifiter_ioctl.c@1.16 +21 -0 Broadcast addresses were not being set for systems with IPv6 capability -ChangeSet@1.1152.18.1, 2004-01-06 21:19:51+01:00, a115350@y3111429.nh.ad.hydro.com +4 -0 +ChangeSet@1.1152.18.1, 2004-01-06 21:19:51+01:00, a115350@y3111429.nh.ad.hydro.com Fix for NTP Epoch rollover - BitKeeper/etc/logging_ok@1.42, 2004-01-06 21:19:51+01:00, a115350@y3111429.nh.ad.hydro.com +1 -0 + BitKeeper/etc/logging_ok@1.42 +1 -0 Logging to logging@openlogging.org accepted - libntp/caljulian.c@1.5, 2004-01-06 21:14:58+01:00, a115350@y3111429.nh.ad.hydro.com +32 -0 + libntp/caljulian.c@1.5 +32 -0 Fix for NTP epoch rollover: Uses time_t and localtime/gmtime for conversion - libntp/humandate.c@1.5, 2004-01-06 21:14:58+01:00, a115350@y3111429.nh.ad.hydro.com +5 -4 + libntp/humandate.c@1.5 +5 -4 Fix for NTP epoch rollover: Uses time_t and localtime/gmtime for conversion - libntp/prettydate.c@1.4, 2004-01-06 21:14:58+01:00, a115350@y3111429.nh.ad.hydro.com +64 -9 + libntp/prettydate.c@1.4 +64 -9 Use common helper function -ChangeSet@1.1152.1.51, 2004-01-02 16:01:53-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.51, 2004-01-02 16:01:53-05:00, stenn@whimsy.udel.edu manycast fix from Dave Mills. - ntpd/ntp_proto.c@1.167, 2004-01-02 16:01:41-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_proto.c@1.167 +1 -1 manycast fix from Dave Mills. -ChangeSet@1.1152.15.6, 2003-12-31 18:04:38-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.15.6, 2003-12-31 18:04:38-05:00, mayer@tecotoo.myibg.com Test Changes - ntpd/ntp_io.c@1.101.1.4, 2003-12-31 17:58:04-05:00, mayer@tecotoo.myibg.com +8 -4 + ntpd/ntp_io.c@1.101.1.4 +8 -4 Test Changes -ChangeSet@1.1152.17.1, 2003-12-31 13:44:43-05:00, mayer@pogo.udel.edu +2 -0 +ChangeSet@1.1152.17.1, 2003-12-31 13:44:43-05:00, mayer@pogo.udel.edu Fix Broadcast support for those systems that support IPv6 - libisc/ifiter_ioctl.c@1.15, 2003-12-31 13:43:31-05:00, mayer@pogo.udel.edu +3 -4 + libisc/ifiter_ioctl.c@1.15 +3 -4 Fix Broadcast support for IPv6 capable queries to ioctl - ntpd/ntp_io.c@1.105, 2003-12-31 13:41:54-05:00, mayer@pogo.udel.edu +11 -10 + ntpd/ntp_io.c@1.105 +11 -10 Fix io_setbclient to properly use MACROS and add proper error information -ChangeSet@1.1152.1.50, 2003-12-26 19:00:43-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.50, 2003-12-26 19:00:43-05:00, stenn@whimsy.udel.edu Dave Mills: Update EOV offset comment. - ntpd/ntp_control.c@1.65.1.1, 2003-12-26 19:00:31-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_control.c@1.65.1.1 +1 -1 Dave Mills: Update EOV offset comment. -ChangeSet@1.1152.15.5, 2003-12-25 18:46:06-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.15.5, 2003-12-25 18:46:06-05:00, mayer@tecotoo.myibg.com EOV value was not updated when error was added - ntpd/ntp_control.c@1.66, 2003-12-25 18:44:52-05:00, mayer@tecotoo.myibg.com +1 -1 + ntpd/ntp_control.c@1.66 +1 -1 EOV value was not updated when error was added -ChangeSet@1.1152.14.9, 2003-12-24 00:41:50-05:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1152.14.9, 2003-12-24 00:41:50-05:00, stenn@whimsy.udel.edu Cleanups, fix [Bug 320] - Makefile.am@1.45, 2003-12-24 00:38:57-05:00, stenn@whimsy.udel.edu +1 -1 + Makefile.am@1.45 +1 -1 [Bug 230] Require automake-1.8. - acinclude.m4@1.12, 2003-12-24 00:39:20-05:00, stenn@whimsy.udel.edu +2 -2 + acinclude.m4@1.12 +2 -2 Quote auto* stuff properly. - configure.in@1.336.1.1, 2003-12-24 00:40:35-05:00, stenn@whimsy.udel.edu +5 -4 + configure.in@1.336.1.1 +5 -4 Require autoconf-2.58. Use version.m4. Cleanup. - version.m4@1.2, 2003-12-24 00:40:05-05:00, stenn@whimsy.udel.edu +1 -1 + version.m4@1.2 +1 -1 4.2.0a - version.m4@1.1, 2003-12-24 00:10:17-05:00, stenn@whimsy.udel.edu +1 -0 + version.m4@1.1 +1 -0 - version.m4@1.0, 2003-12-24 00:10:17-05:00, stenn@whimsy.udel.edu +0 -0 + version.m4@1.0 +0 -0 BitKeeper file /backroom/ntp-stable/version.m4 -ChangeSet@1.1152.14.8, 2003-12-20 20:28:35-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.14.8, 2003-12-20 20:28:35-05:00, stenn@whimsy.udel.edu [Bug 259] Marc Brett: lint - ntpd/refclock_arc.c@1.16, 2003-12-20 20:28:24-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/refclock_arc.c@1.16 +2 -2 [Bug 259] Marc Brett: lint - ntpd/refclock_neoclock4x.c@1.11, 2003-12-20 20:28:24-05:00, stenn@whimsy.udel.edu +3 -3 + ntpd/refclock_neoclock4x.c@1.11 +3 -3 [Bug 259] Marc Brett: lint -ChangeSet@1.1152.14.7, 2003-12-20 20:18:51-05:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1152.14.7, 2003-12-20 20:18:51-05:00, stenn@whimsy.udel.edu [Bug 258] sntp cleanup - sntp/internet.c@1.3, 2003-12-20 20:15:55-05:00, stenn@whimsy.udel.edu +0 -2 + sntp/internet.c@1.3 +0 -2 [Bug 258] Matthias Drochner: sntp lint cleanup (plus IPv6 patch from HMS) - sntp/main.c@1.3, 2003-12-20 20:15:55-05:00, stenn@whimsy.udel.edu +18 -1 + sntp/main.c@1.3 +18 -1 [Bug 258] Matthias Drochner: sntp lint cleanup (plus IPv6 patch from HMS) - sntp/socket.c@1.3, 2003-12-20 20:15:56-05:00, stenn@whimsy.udel.edu +7 -1 + sntp/socket.c@1.3 +7 -1 [Bug 258] Matthias Drochner: sntp lint cleanup (plus IPv6 patch from HMS) - sntp/timing.c@1.2, 2003-12-20 20:17:33-05:00, stenn@whimsy.udel.edu +2 -0 + sntp/timing.c@1.2 +2 -0 [Bug 258] Marc Brett: more sntp lint cleanup. -ChangeSet@1.1152.14.6, 2003-12-20 18:44:12-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.14.6, 2003-12-20 18:44:12-05:00, stenn@whimsy.udel.edu [Bug 262] Petter Reinholdtsen: Fix gcc3/Mac OS X output regexp for ntpdc/nl.pl - ntpdc/nl.pl.in@1.7, 2003-12-20 18:44:00-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/nl.pl.in@1.7 +2 -2 [Bug 262] Petter Reinholdtsen: Fix gcc3/Mac OS X output regexp for ntpdc/nl.pl -ChangeSet@1.1152.14.5, 2003-12-20 01:03:29-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.14.5, 2003-12-20 01:03:29-05:00, stenn@whimsy.udel.edu [Bug 263] (NetBSD PR bin/23707) - ntpdate/ntpdate.c@1.45, 2003-12-20 01:02:39-05:00, stenn@whimsy.udel.edu +82 -78 + ntpdate/ntpdate.c@1.45 +82 -78 Use #ifdef DEBUG where appropriate. - ntpdate/ntpdate.c@1.44, 2003-12-20 00:49:05-05:00, stenn@whimsy.udel.edu +69 -68 + ntpdate/ntpdate.c@1.44 +69 -68 [Bug 263] Mattias Karlsson: ntpdate -s is not silent. From NetBSD PR bin/23707 -ChangeSet@1.1152.16.1, 2003-12-19 15:44:14-05:00, stenn@whimsy.udel.edu +5 -0 +ChangeSet@1.1152.16.1, 2003-12-19 15:44:14-05:00, stenn@whimsy.udel.edu [Bug 251] Timo Felbinger: Drop root under Linux - configure.in@1.337, 2003-12-19 15:43:27-05:00, stenn@whimsy.udel.edu +20 -2 + configure.in@1.337 +20 -2 [Bug 251] Timo Felbinger: Drop root under Linux - html/ntpd.html@1.32, 2003-12-19 15:43:27-05:00, stenn@whimsy.udel.edu +5 -1 + html/ntpd.html@1.32 +5 -1 [Bug 251] Timo Felbinger: Drop root under Linux - include/ntpd.h@1.61, 2003-12-19 15:43:27-05:00, stenn@whimsy.udel.edu +2 -1 + include/ntpd.h@1.61 +2 -1 [Bug 251] Timo Felbinger: Drop root under Linux - ntpd/cmd_args.c@1.23, 2003-12-19 15:43:28-05:00, stenn@whimsy.udel.edu +18 -10 + ntpd/cmd_args.c@1.23 +18 -10 [Bug 251] Timo Felbinger: Drop root under Linux - ntpd/ntpd.c@1.54, 2003-12-19 15:43:28-05:00, stenn@whimsy.udel.edu +106 -59 + ntpd/ntpd.c@1.54 +106 -59 [Bug 251] Timo Felbinger: Drop root under Linux -ChangeSet@1.1152.1.43, 2003-12-18 02:50:14-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.43, 2003-12-18 02:50:14-05:00, stenn@whimsy.udel.edu [Bug 256] Fix misleading diagnostic message. - ntpd/ntp_config.c@1.100, 2003-12-18 02:49:58-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_config.c@1.100 +2 -2 [Bug 256] Fix misleading diagnostic message. -ChangeSet@1.1152.1.42, 2003-12-18 00:36:05-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.42, 2003-12-18 00:36:05-05:00, stenn@whimsy.udel.edu [Bug 158] Alter header inclusion to avoid linux header braindamage. - libntp/iosignal.c@1.12, 2003-12-18 00:35:52-05:00, stenn@whimsy.udel.edu +19 -6 + libntp/iosignal.c@1.12 +19 -6 [Bug 158] Alter header inclusion to avoid linux header braindamage. -ChangeSet@1.1152.1.41, 2003-12-17 23:35:26-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.1.41, 2003-12-17 23:35:26-05:00, stenn@whimsy.udel.edu Updates from Dave Mills. - html/confopt.html@1.28, 2003-12-17 23:35:12-05:00, stenn@whimsy.udel.edu +5 -6 + html/confopt.html@1.28 +5 -6 Updates from Dave Mills. - html/ntpdc.html@1.20, 2003-12-17 23:35:12-05:00, stenn@whimsy.udel.edu +2 -2 + html/ntpdc.html@1.20 +2 -2 Updates from Dave Mills. -ChangeSet@1.1152.1.40, 2003-12-17 23:24:17-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.1.40, 2003-12-17 23:24:17-05:00, stenn@whimsy.udel.edu Dave Mills: novolley subcommand to the broadcast command. - ntpd/ntp_config.c@1.99, 2003-12-17 23:24:02-05:00, stenn@whimsy.udel.edu +8 -4 + ntpd/ntp_config.c@1.99 +8 -4 Dave Mills: novolley subcommand to the broadcast command. - ntpd/ntp_proto.c@1.166, 2003-12-17 23:24:02-05:00, stenn@whimsy.udel.edu +15 -18 + ntpd/ntp_proto.c@1.166 +15 -18 Dave Mills: novolley subcommand to the broadcast command. -ChangeSet@1.1152.1.39, 2003-12-16 16:22:11-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.39, 2003-12-16 16:22:11-05:00, stenn@whimsy.udel.edu Typo fix from Marc Brett - ntpd/ntp_io.c@1.104, 2003-12-16 16:21:57-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_io.c@1.104 +1 -1 Typo fix from Marc Brett -ChangeSet@1.1152.15.4, 2003-12-14 21:45:10-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.15.4, 2003-12-14 21:45:10-05:00, mayer@tecotoo.myibg.com Unix didn't recognize BOOL in create_wildcard, use isc_boolean_t instead - ntpd/ntp_io.c@1.101.1.3, 2003-12-14 21:44:05-05:00, mayer@tecotoo.myibg.com +4 -3 + ntpd/ntp_io.c@1.101.1.3 +4 -3 Unix didn't recognize BOOL in create_wildcar, use isc_boolean_t instead -ChangeSet@1.1152.15.3, 2003-12-14 11:50:12-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.15.3, 2003-12-14 11:50:12-05:00, mayer@tecotoo.myibg.com Print no interfaces message if debug is on - ntpd/ntp_io.c@1.101.1.2, 2003-12-14 11:49:13-05:00, mayer@tecotoo.myibg.com +7 -3 + ntpd/ntp_io.c@1.101.1.2 +7 -3 Print no interfaces message if debug is on -ChangeSet@1.1152.15.2, 2003-12-13 22:02:59-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.15.2, 2003-12-13 22:02:59-05:00, mayer@tecotoo.myibg.com Clean up the open_socket code - ntpd/ntp_io.c@1.101.1.1, 2003-12-13 22:01:55-05:00, mayer@tecotoo.myibg.com +13 -8 + ntpd/ntp_io.c@1.101.1.1 +13 -8 Clean up the open_socket code -ChangeSet@1.1152.15.1, 2003-12-13 21:38:39-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.15.1, 2003-12-13 21:38:39-05:00, mayer@tecotoo.myibg.com define lifr_index if platform uses if_laddrreq - libisc/ifiter_ioctl.c@1.14, 2003-12-13 20:28:38-05:00, mayer@tecotoo.myibg.com +1 -0 + libisc/ifiter_ioctl.c@1.14 +1 -0 define lifr_index if platform uses if_laddrreq -ChangeSet@1.1152.1.37, 2003-12-10 01:52:46-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.37, 2003-12-10 01:52:46-05:00, stenn@whimsy.udel.edu *ix doesn't do BOOL. - ntpd/ntp_io.c@1.102, 2003-12-10 01:52:27-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_io.c@1.102 +1 -1 *ix doesn't do BOOL. -ChangeSet@1.1152.1.36, 2003-12-09 09:59:50-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.1.36, 2003-12-09 09:59:50-05:00, mayer@tecotoo.myibg.com IPV6_V6ONLY not dependent on IPTOS_LOWDELAY, etc - ntpd/ntp_io.c@1.101, 2003-12-09 09:58:45-05:00, mayer@tecotoo.myibg.com +1 -2 + ntpd/ntp_io.c@1.101 +1 -2 IPV6_V6ONLY not dependent on IPTOS_LOWDELAY, etc -ChangeSet@1.1152.1.35, 2003-12-08 17:49:41-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.1.35, 2003-12-08 17:49:41-05:00, mayer@tecotoo.myibg.com Fix to only conditionally create a wildcard socket for IPv4 if IPV6_V6ONLY defined and no IPv4 stack - ntpd/ntp_io.c@1.100, 2003-12-08 15:00:51-05:00, mayer@tecotoo.myibg.com +25 -18 + ntpd/ntp_io.c@1.100 +25 -18 Fix to only conditionally create a wildcard socket for IPv4 if IPV6_V6ONLY defined -ChangeSet@1.1152.1.34, 2003-12-07 19:09:45-05:00, mayer@tecotoo.myibg.com +2 -0 +ChangeSet@1.1152.1.34, 2003-12-07 19:09:45-05:00, mayer@tecotoo.myibg.com Fix to only get scope and zero address if Link-local Multicast address. Add scope information for interfaces - libisc/interfaceiter.c@1.9, 2003-12-07 19:04:48-05:00, mayer@tecotoo.myibg.com +7 -4 + libisc/interfaceiter.c@1.9 +7 -4 Fix to only get scope and zero address if Link-local Multicast address - ntpd/ntp_io.c@1.99, 2003-12-07 19:07:55-05:00, mayer@tecotoo.myibg.com +3 -2 + ntpd/ntp_io.c@1.99 +3 -2 Print scope information so we see it for interfaces we are handling -ChangeSet@1.1152.1.33, 2003-12-03 23:33:46-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.1.33, 2003-12-03 23:33:46-05:00, mayer@tecotoo.myibg.com For KAME we need to fix the zeroing out of a couple of bytes. Fix to do it properly - libisc/interfaceiter.c@1.8, 2003-12-03 23:32:30-05:00, mayer@tecotoo.myibg.com +9 -2 + libisc/interfaceiter.c@1.8 +9 -2 For KAME we need to fix the zeroing out of a couple of bytes. Fix to do it properly -ChangeSet@1.1152.1.32, 2003-12-03 22:24:47-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.1.32, 2003-12-03 22:24:47-05:00, mayer@tecotoo.myibg.com For KAME we need to fix the zeroing out of a couple of bytes. The wrong variable name got used - libisc/interfaceiter.c@1.7, 2003-12-03 22:23:28-05:00, mayer@tecotoo.myibg.com +2 -2 + libisc/interfaceiter.c@1.7 +2 -2 For KAME we need to fix the zeroing out of a couple of bytes. The wrong variable got used -ChangeSet@1.1152.12.7, 2003-12-02 23:46:54-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.12.7, 2003-12-02 23:46:54-05:00, mayer@tecotoo.myibg.com if_index should have been ifindex - libisc/ifiter_sysctl.c@1.8, 2003-12-02 23:45:32-05:00, mayer@tecotoo.myibg.com +1 -1 + libisc/ifiter_sysctl.c@1.8 +1 -1 if_index should have been ifindex -ChangeSet@1.1152.1.29, 2003-12-01 04:09:21-05:00, stenn@whimsy.udel.edu +6 -0 +ChangeSet@1.1152.1.29, 2003-12-01 04:09:21-05:00, stenn@whimsy.udel.edu Improvements from Dave Mills. - include/ntp_control.h@1.24, 2003-12-01 04:09:02-05:00, stenn@whimsy.udel.edu +15 -14 + include/ntp_control.h@1.24 +15 -14 Improvements from Dave Mills. - include/ntpd.h@1.60, 2003-12-01 04:09:02-05:00, stenn@whimsy.udel.edu +3 -3 + include/ntpd.h@1.60 +3 -3 Improvements from Dave Mills. - ntpd/ntp_control.c@1.65, 2003-12-01 04:09:03-05:00, stenn@whimsy.udel.edu +20 -14 + ntpd/ntp_control.c@1.65 +20 -14 Improvements from Dave Mills. - ntpd/ntp_loopfilter.c@1.88, 2003-12-01 04:09:03-05:00, stenn@whimsy.udel.edu +24 -30 + ntpd/ntp_loopfilter.c@1.88 +24 -30 Improvements from Dave Mills. - ntpd/ntp_proto.c@1.165, 2003-12-01 04:09:03-05:00, stenn@whimsy.udel.edu +6 -6 + ntpd/ntp_proto.c@1.165 +6 -6 Improvements from Dave Mills. - ntpd/ntp_refclock.c@1.52, 2003-12-01 04:09:04-05:00, stenn@whimsy.udel.edu +2 -3 + ntpd/ntp_refclock.c@1.52 +2 -3 Improvements from Dave Mills. -ChangeSet@1.1152.12.6, 2003-11-30 22:23:45-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.12.6, 2003-11-30 22:23:45-05:00, mayer@tecotoo.myibg.com For KAME we need to zero out a couple of bytes in the address - libisc/interfaceiter.c@1.6, 2003-11-30 22:22:34-05:00, mayer@tecotoo.myibg.com +2 -0 + libisc/interfaceiter.c@1.6 +2 -0 For KAME we need to zero out a couple of bytes in the address -ChangeSet@1.1152.12.5, 2003-11-29 21:24:54-05:00, mayer@tecotoo.myibg.com +2 -0 +ChangeSet@1.1152.12.5, 2003-11-29 21:24:54-05:00, mayer@tecotoo.myibg.com Fixes for older platforms not returning the interface index and not supporting IPv6 - libisc/ifiter_ioctl.c@1.13, 2003-11-29 21:21:54-05:00, mayer@tecotoo.myibg.com +9 -0 + libisc/ifiter_ioctl.c@1.13 +9 -0 Fix complaints about not finding ifr_index on older platforms - libisc/interfaceiter.c@1.5, 2003-11-29 21:23:06-05:00, mayer@tecotoo.myibg.com +2 -0 + libisc/interfaceiter.c@1.5 +2 -0 Fix warning on machines not supporting IPv6 to ignore the get_scopeid() function -ChangeSet@1.1152.12.4, 2003-11-29 20:52:42-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.12.4, 2003-11-29 20:52:42-05:00, mayer@tecotoo.myibg.com Use scope id when address is link-local for IPv6 multicast IPV6_JOIN_GROUP - ntpd/ntp_io.c@1.98, 2003-11-29 20:51:08-05:00, mayer@tecotoo.myibg.com +9 -2 + ntpd/ntp_io.c@1.98 +9 -2 Use scope id when address is link-local for IPv6 multicast IPV6_JOIN_GROUP -ChangeSet@1.1152.14.4, 2003-11-29 20:22:38-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.14.4, 2003-11-29 20:22:38-05:00, stenn@whimsy.udel.edu [Bug 255] Lint cleanup - ntpd/ntp_loopfilter.c@1.87, 2003-11-29 20:22:22-05:00, stenn@whimsy.udel.edu +5 -1 + ntpd/ntp_loopfilter.c@1.87 +5 -1 [Bug 255] Lint cleanup -ChangeSet@1.1152.14.3, 2003-11-29 19:18:51-05:00, stenn@whimsy.udel.edu +4 -0 +ChangeSet@1.1152.14.3, 2003-11-29 19:18:51-05:00, stenn@whimsy.udel.edu [Bug 255] Lint cleanup - ntpd/refclock_hopfpci.c@1.10, 2003-11-29 19:09:20-05:00, stenn@whimsy.udel.edu +0 -8 + ntpd/refclock_hopfpci.c@1.10 +0 -8 [Bug 255] Lint clenaup in hopfpci.c - ntpd/refclock_neoclock4x.c@1.10, 2003-11-29 19:10:42-05:00, stenn@whimsy.udel.edu +0 -2 + ntpd/refclock_neoclock4x.c@1.10 +0 -2 [Bug 255] Lint cleanup in neoclock4x - ntpdc/ntpdc.c@1.32, 2003-11-29 19:14:57-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc.c@1.32 +2 -2 [Bug 255] Lint cleanup in ntpdc.c - ntpq/ntpq.c@1.45, 2003-11-29 19:16:56-05:00, stenn@whimsy.udel.edu +2 -3 + ntpq/ntpq.c@1.45 +2 -3 [Bug 255] Lint cleanup in ntpq.c -ChangeSet@1.1152.14.2, 2003-11-29 18:53:20-05:00, stenn@whimsy.udel.edu +8 -0 +ChangeSet@1.1152.14.2, 2003-11-29 18:53:20-05:00, stenn@whimsy.udel.edu [Bug 255] Lint cleanup (avoid HASH_* name collision) - include/ntp.h@1.95, 2003-11-29 18:52:38-05:00, stenn@whimsy.udel.edu +3 -3 + include/ntp.h@1.95 +3 -3 [Bug 255] Lint cleanup (avoid HASH_* name collision) - include/ntp_request.h@1.23, 2003-11-29 18:52:42-05:00, stenn@whimsy.udel.edu +1 -1 + include/ntp_request.h@1.23 +1 -1 [Bug 255] Lint cleanup (avoid HASH_* name collision) - ntpd/ntp_control.c@1.64, 2003-11-29 18:52:54-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_control.c@1.64 +2 -2 [Bug 255] Lint cleanup (avoid HASH_* name collision) - ntpd/ntp_peer.c@1.58, 2003-11-29 18:52:56-05:00, stenn@whimsy.udel.edu +17 -17 + ntpd/ntp_peer.c@1.58 +17 -17 [Bug 255] Lint cleanup (avoid HASH_* name collision) - ntpd/ntp_proto.c@1.162.1.1, 2003-11-29 18:52:55-05:00, stenn@whimsy.udel.edu +2 -2 + ntpd/ntp_proto.c@1.162.1.1 +2 -2 [Bug 255] Lint cleanup (avoid HASH_* name collision) - ntpd/ntp_request.c@1.55, 2003-11-29 18:52:56-05:00, stenn@whimsy.udel.edu +4 -4 + ntpd/ntp_request.c@1.55 +4 -4 [Bug 255] Lint cleanup (avoid HASH_* name collision) - ntpd/ntp_timer.c@1.27, 2003-11-29 18:52:57-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_timer.c@1.27 +1 -1 [Bug 255] Lint cleanup (avoid HASH_* name collision) - ntpdc/ntpdc_ops.c@1.29, 2003-11-29 18:52:50-05:00, stenn@whimsy.udel.edu +2 -2 + ntpdc/ntpdc_ops.c@1.29 +2 -2 [Bug 255] Lint cleanup (avoid HASH_* name collision) -ChangeSet@1.1152.14.1, 2003-11-29 18:07:18-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.14.1, 2003-11-29 18:07:18-05:00, stenn@whimsy.udel.edu [Bug 254] Frederick Bruckman: Avoid the OSS emulation layer on NetBSD. - configure.in@1.336, 2003-11-29 18:07:00-05:00, stenn@whimsy.udel.edu +5 -1 + configure.in@1.336 +5 -1 [Bug 254] Frederick Bruckman: Avoid the OSS emulation layer on NetBSD. -ChangeSet@1.1152.1.25, 2003-11-29 03:43:39-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.25, 2003-11-29 03:43:39-05:00, stenn@whimsy.udel.edu [Bug 241] Dave Mills: Do not respond to multicast if not a manycast server. - ntpd/ntp_proto.c@1.163, 2003-11-29 03:43:26-05:00, stenn@whimsy.udel.edu +9 -3 + ntpd/ntp_proto.c@1.163 +9 -3 [Bug 241] Dave Mills: Do not respond to multicast if not a manycast server. -ChangeSet@1.1152.1.24, 2003-11-29 03:28:17-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.24, 2003-11-29 03:28:17-05:00, stenn@whimsy.udel.edu [Bug 200] Apparently, variance data is stored squared, so we want to SQRT() it when we report it. - ntpd/ntp_request.c@1.54, 2003-11-29 03:27:53-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntp_request.c@1.54 +1 -1 [Bug 200] Apparently, variance data is stored squared, so we want to SQRT() it when we report it. -ChangeSet@1.1152.1.23, 2003-11-29 03:17:47-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.23, 2003-11-29 03:17:47-05:00, stenn@whimsy.udel.edu [Bug 252] Matthias Drochner: uninitialized memory in ntp-keygen can lead to crashes. - util/ntp-keygen.c@1.25, 2003-11-29 03:17:22-05:00, stenn@whimsy.udel.edu +8 -7 + util/ntp-keygen.c@1.25 +8 -7 [Bug 252] Matthias Drochner: uninitialized memory in ntp-keygen can lead to crashes. -ChangeSet@1.1152.1.22, 2003-11-29 03:03:13-05:00, stenn@pogo.udel.edu +1 -0 +ChangeSet@1.1152.1.22, 2003-11-29 03:03:13-05:00, stenn@pogo.udel.edu Use our portable way of getting socklen - ntpd/refclock_nmea.c@1.22, 2003-11-29 03:03:01-05:00, stenn@pogo.udel.edu +1 -2 + ntpd/refclock_nmea.c@1.22 +1 -2 Use our portable way of getting socklen -ChangeSet@1.1152.12.3, 2003-11-27 22:34:47-05:00, mayer@tecotoo.myibg.com +7 -0 +ChangeSet@1.1152.12.3, 2003-11-27 22:34:47-05:00, mayer@tecotoo.myibg.com Added support for scopeid and interface index in support of IPV6 multicasting. - include/isc/interfaceiter.h@1.3, 2003-11-27 22:33:40-05:00, mayer@tecotoo.myibg.com +2 -0 + include/isc/interfaceiter.h@1.3 +2 -0 Added interface index and scope id to interface structure - include/ntp.h@1.92.1.2, 2003-11-27 22:33:44-05:00, mayer@tecotoo.myibg.com +2 -0 + include/ntp.h@1.92.1.2 +2 -0 Added interface index and scope id to interface structure - libisc/ifiter_ioctl.c@1.12, 2003-11-27 22:33:46-05:00, mayer@tecotoo.myibg.com +4 -0 + libisc/ifiter_ioctl.c@1.12 +4 -0 Added interface index and scope id to interface structure - libisc/ifiter_sysctl.c@1.7, 2003-11-27 22:33:49-05:00, mayer@tecotoo.myibg.com +3 -0 + libisc/ifiter_sysctl.c@1.7 +3 -0 Added interface index and scope id to interface structure - libisc/interfaceiter.c@1.4, 2003-11-27 22:33:52-05:00, mayer@tecotoo.myibg.com +31 -0 + libisc/interfaceiter.c@1.4 +31 -0 Added get_scopeid function to fetch the scope and take care of KAME issues. - ntpd/ntp_io.c@1.97, 2003-11-27 22:33:58-05:00, mayer@tecotoo.myibg.com +6 -1 + ntpd/ntp_io.c@1.97 +6 -1 Copy the interface index and scope id into the interface structure. Use the scope d to specify the scope and te interface index to join the group. - ports/winnt/libisc/interfaceiter.c@1.4, 2003-11-27 22:34:02-05:00, mayer@tecotoo.myibg.com +5 -0 + ports/winnt/libisc/interfaceiter.c@1.4 +5 -0 Added interface index and scope id to interface. Zero for now. -ChangeSet@1.1152.1.21, 2003-11-26 19:52:29-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.21, 2003-11-26 19:52:29-05:00, stenn@whimsy.udel.edu Document nmead support - html/drivers/driver20.html@1.12, 2003-11-26 19:52:15-05:00, stenn@whimsy.udel.edu +1 -0 + html/drivers/driver20.html@1.12 +1 -0 Document nmead support -ChangeSet@1.1152.13.5, 2003-11-26 19:21:41-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.13.5, 2003-11-26 19:21:41-05:00, stenn@whimsy.udel.edu [Bug 202] From Jon Miner: nmead support - ntpd/refclock_nmea.c@1.21, 2003-11-26 19:21:26-05:00, stenn@whimsy.udel.edu +50 -2 + ntpd/refclock_nmea.c@1.21 +50 -2 [Bug 202] From Jon Miner: nmead support -ChangeSet@1.1152.13.4, 2003-11-26 19:06:31-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.13.4, 2003-11-26 19:06:31-05:00, stenn@whimsy.udel.edu [Bug 248] From Nigel Roles: Fix use of tcsetattr() and parsing. - ntpd/refclock_arc.c@1.15, 2003-11-26 19:06:18-05:00, stenn@whimsy.udel.edu +45 -5 + ntpd/refclock_arc.c@1.15 +45 -5 [Bug 248] From Nigel Roles: Fix use of tcsetattr() and parsing. -ChangeSet@1.1152.13.2, 2003-11-25 04:26:12-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.13.2, 2003-11-25 04:26:12-05:00, stenn@whimsy.udel.edu [Bug 250] msec->nsec conversion bug to refclock_palisade.c (From Neil Burn) - ntpd/refclock_palisade.c@1.16.1.1, 2003-11-25 04:25:55-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/refclock_palisade.c@1.16.1.1 +1 -1 [Bug 250] msec->nsec conversion bug to refclock_palisade.c (From Neil Burn) -ChangeSet@1.1152.13.1, 2003-11-25 04:17:29-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.13.1, 2003-11-25 04:17:29-05:00, stenn@whimsy.udel.edu [Bug 243] error handling bug in ntpdc (from Matthias Drochner) - ntpdc/ntpdc_ops.c@1.28, 2003-11-25 04:17:14-05:00, stenn@whimsy.udel.edu +18 -18 + ntpdc/ntpdc_ops.c@1.28 +18 -18 [Bug 243] error handling bug in ntpdc (from Matthias Drochner) -ChangeSet@1.1152.12.2, 2003-11-24 09:24:33-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.12.2, 2003-11-24 09:24:33-05:00, mayer@tecotoo.myibg.com Time is in nsecs and not usecs. Multiplier was incorrect - ntpd/refclock_palisade.c@1.17, 2003-11-24 09:23:34-05:00, mayer@tecotoo.myibg.com +1 -1 + ntpd/refclock_palisade.c@1.17 +1 -1 Time is in nsecs and not usecs. Multiplier was incorrect -ChangeSet@1.1152.12.1, 2003-11-24 09:18:06-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.12.1, 2003-11-24 09:18:06-05:00, mayer@tecotoo.myibg.com Fix structure name to use the generic name - include/ntp.h@1.92.1.1, 2003-11-24 09:16:55-05:00, mayer@tecotoo.myibg.com +1 -1 + include/ntp.h@1.92.1.1 +1 -1 Fix structure name to use the generic name -ChangeSet@1.1152.11.2, 2003-11-20 04:41:32-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.11.2, 2003-11-20 04:41:32-05:00, stenn@whimsy.udel.edu [Bug 238] check for vsnprintf - configure.in@1.335, 2003-11-20 04:41:18-05:00, stenn@whimsy.udel.edu +1 -1 + configure.in@1.335 +1 -1 [Bug 238] check for vsnprintf -ChangeSet@1.1152.9.13, 2003-11-20 03:58:27-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.9.13, 2003-11-20 03:58:27-05:00, stenn@whimsy.udel.edu [Bug 220] (Frederick Bruckman) The linux resolver needs more stack space. - ntpd/ntpd.c@1.53, 2003-11-20 03:58:05-05:00, stenn@whimsy.udel.edu +1 -1 + ntpd/ntpd.c@1.53 +1 -1 [Bug 220] (Frederick Bruckman) The linux resolver needs more stack space. -ChangeSet@1.1152.9.12, 2003-11-20 03:44:29-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.9.12, 2003-11-20 03:44:29-05:00, stenn@whimsy.udel.edu [Bug 217] ntptrace should show sync distance, not rootdelay. - scripts/ntptrace.in@1.3, 2003-11-20 03:44:11-05:00, stenn@whimsy.udel.edu +6 -3 + scripts/ntptrace.in@1.3 +6 -3 [Bug 217] ntptrace should show sync distance, not rootdelay. -ChangeSet@1.1152.9.11, 2003-11-20 03:28:03-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.9.11, 2003-11-20 03:28:03-05:00, stenn@whimsy.udel.edu [Bug 215] Stop looking when we hit a refclock. - scripts/ntptrace.in@1.2, 2003-11-20 03:27:44-05:00, stenn@whimsy.udel.edu +1 -0 + scripts/ntptrace.in@1.2 +1 -0 [Bug 215] Stop looking when we hit a refclock. -ChangeSet@1.1152.9.10, 2003-11-19 21:12:51-05:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.9.10, 2003-11-19 21:12:51-05:00, stenn@whimsy.udel.edu Sledgehammer bug 230 - util/Makefile.am@1.22, 2003-11-19 21:12:35-05:00, stenn@whimsy.udel.edu +4 -1 + util/Makefile.am@1.22 +4 -1 Sledgehammer bug 230 -ChangeSet@1.1152.9.9, 2003-11-19 10:07:45+00:00, harlanst@time.usno.navy.mil +4 -0 +ChangeSet@1.1152.9.9, 2003-11-19 10:07:45+00:00, harlanst@time.usno.navy.mil gpsvme updates from USNO - BitKeeper/deleted/.del-map_vme.c~3aed0663@1.5, 2003-11-19 10:04:09+00:00, harlanst@time.usno.navy.mil +0 -133 + BitKeeper/deleted/.del-map_vme.c~3aed0663@1.5 +0 -133 Delete: ntpd/map_vme.c - BitKeeper/etc/logging_ok@1.41, 2003-11-19 10:07:39+00:00, harlanst@time.usno.navy.mil +1 -0 + BitKeeper/etc/logging_ok@1.41 +1 -0 Logging to logging@openlogging.org accepted - ntpd/Makefile.am@1.37, 2003-11-19 10:04:45+00:00, harlanst@time.usno.navy.mil +1 -1 + ntpd/Makefile.am@1.37 +1 -1 map_vme.c is no more... - ntpd/refclock_gpsvme.c@1.7, 2003-11-19 10:06:43+00:00, harlanst@time.usno.navy.mil +244 -612 + ntpd/refclock_gpsvme.c@1.7 +244 -612 updated version from the USNO folks -ChangeSet@1.1152.9.8, 2003-11-18 22:58:33-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.9.8, 2003-11-18 22:58:33-05:00, stenn@whimsy.udel.edu autoconf cleanup - configure.in@1.334, 2003-11-18 22:58:17-05:00, stenn@whimsy.udel.edu +2 -2 + configure.in@1.334 +2 -2 autoconf cleanup - sntp/configure.ac@1.7, 2003-11-18 22:58:18-05:00, stenn@whimsy.udel.edu +1 -1 + sntp/configure.ac@1.7 +1 -1 autoconf cleanup -ChangeSet@1.1152.10.2, 2003-11-11 02:55:22-05:00, stenn@whimsy.udel.edu +3 -0 +ChangeSet@1.1152.10.2, 2003-11-11 02:55:22-05:00, stenn@whimsy.udel.edu [Bug 177] Fixes from Dave Mills. - libntp/systime.c@1.28, 2003-11-11 02:35:43-05:00, stenn@whimsy.udel.edu +6 -1 + libntp/systime.c@1.28 +6 -1 [Bug 177] Fixes from Dave Mills - ntpd/ntp_loopfilter.c@1.86, 2003-11-11 02:54:11-05:00, stenn@whimsy.udel.edu +20 -26 + ntpd/ntp_loopfilter.c@1.86 +20 -26 [Bug 177] Fixes from Dave Mills: state machine improvements. - ntpd/ntp_proto.c@1.162, 2003-11-11 02:52:25-05:00, stenn@whimsy.udel.edu +15 -7 + ntpd/ntp_proto.c@1.162 +15 -7 [Bug 177] Fixes from Dave Mills: freq mgt and poll interval fixes. -ChangeSet@1.1152.10.1, 2003-11-10 23:53:42-05:00, stenn@whimsy.udel.edu +2 -0 +ChangeSet@1.1152.10.1, 2003-11-10 23:53:42-05:00, stenn@whimsy.udel.edu Stuff from Dave Mills - NEWS@1.47, 2003-11-10 01:08:47-05:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.47 +1 -0 Separate -dev news from -stable news. - include/ntp.h@1.93, 2003-11-10 01:28:10-05:00, stenn@whimsy.udel.edu +5 -5 + include/ntp.h@1.93 +5 -5 Cleanup from Dave Mills -ChangeSet@1.1152.9.6, 2003-11-08 20:32:39-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.9.6, 2003-11-08 20:32:39-05:00, mayer@tecotoo.myibg.com Ensure config.h is included in ntp_rfx2553.h before testing macros - include/ntp_rfc2553.h@1.11, 2003-11-08 20:30:05-05:00, mayer@tecotoo.myibg.com +6 -0 + include/ntp_rfc2553.h@1.11 +6 -0 Ensure config.h is included before testing macros -ChangeSet@1.1152.9.5, 2003-11-08 16:49:43-05:00, mayer@tecotoo.myibg.com +5 -0 +ChangeSet@1.1152.9.5, 2003-11-08 16:49:43-05:00, mayer@tecotoo.myibg.com Fixes to properly support platforms that do not have IPv6 support. - include/isc/ipv6.h@1.4, 2003-11-08 16:48:51-05:00, mayer@tecotoo.myibg.com +4 -2 + include/isc/ipv6.h@1.4 +4 -2 Make IPv6 Macro definitions only if not previously defined. - include/ntp_rfc2553.h@1.10, 2003-11-08 16:48:56-05:00, mayer@tecotoo.myibg.com +2 -4 + include/ntp_rfc2553.h@1.10 +2 -4 Change to only use the definitions if IPv6 not defined on the platform. This uses the Macros defined during the config process which defines the Macro ISC_PLATFORM_HAVEIPV6 if the platform properly supports IPv6 - libntp/ntp_rfc2553.c@1.15, 2003-11-08 16:49:00-05:00, mayer@tecotoo.myibg.com +2 -2 + libntp/ntp_rfc2553.c@1.15 +2 -2 Use ISC_PLATFORM_HAVEIPV6 instead of HAVE_IPV6 which was previously defined in the ntp_rfc2553.h file based on the erroneously assumption about a macro. - ports/winnt/include/isc/ipv6.h@1.3, 2003-11-08 16:49:04-05:00, mayer@tecotoo.myibg.com +4 -2 + ports/winnt/include/isc/ipv6.h@1.3 +4 -2 Make IPv6 Macro definitions only if not previously defined. - ports/winnt/include/isc/platform.h@1.3, 2003-11-08 16:49:06-05:00, mayer@tecotoo.myibg.com +5 -0 + ports/winnt/include/isc/platform.h@1.3 +5 -0 The ISC_PLATFORM_HAVEIPV6 macro should not have been defined here. This was a vestige of the work being done to scan for IPv6 interfaces on Windows platforms. -ChangeSet@1.1152.9.4, 2003-11-07 21:27:53-05:00, mayer@pogo.udel.edu +1 -0 +ChangeSet@1.1152.9.4, 2003-11-07 21:27:53-05:00, mayer@pogo.udel.edu Change HAVE_IPV6 macro to ISC_PLATFORM_HAVEIPV6 since BIND 9 does a better job of figuring out what's needed for IPv6 - ntpd/ntp_io.c@1.96, 2003-11-07 21:25:26-05:00, mayer@pogo.udel.edu +26 -26 + ntpd/ntp_io.c@1.96 +26 -26 Change HAVE_IPV6 macro to ISC_PLATFORM_HAVEIPV6 since BIND 9 does a better job of figuring out what's needed for IPv6 -ChangeSet@1.1152.9.3, 2003-11-02 23:18:29-05:00, mayer@tecotoo.myibg.com +1 -0 +ChangeSet@1.1152.9.3, 2003-11-02 23:18:29-05:00, mayer@tecotoo.myibg.com Fix setsockopt arguments to conform to standard declarations for various arguments - ntpd/ntp_io.c@1.95, 2003-11-02 23:17:43-05:00, mayer@tecotoo.myibg.com +4 -2 + ntpd/ntp_io.c@1.95 +4 -2 Fix setsockopt arguments to conform to standard declarations for various arguments -ChangeSet@1.1152.9.2, 2003-10-31 23:23:43-05:00, mayer@tecotoo.myibg.com +2 -0 +ChangeSet@1.1152.9.2, 2003-10-31 23:23:43-05:00, mayer@tecotoo.myibg.com Fix for number of bytes and error message fixes (see Bugs #226 and 227) - ntpd/ntp_intres.c@1.32, 2003-10-31 23:22:50-05:00, mayer@tecotoo.myibg.com +13 -3 + ntpd/ntp_intres.c@1.32 +13 -3 Need to use GetOverlapped result to get the number of bytes. - ports/winnt/ntpd/ntp_iocompletionport.c@1.10, 2003-10-31 23:22:56-05:00, mayer@tecotoo.myibg.com +9 -3 + ports/winnt/ntpd/ntp_iocompletionport.c@1.10 +9 -3 Error message fixes. -ChangeSet@1.1152.9.1, 2003-10-26 10:20:36-05:00, mayer@tecotoo.myibg.com +7 -0 +ChangeSet@1.1152.9.1, 2003-10-26 10:20:36-05:00, mayer@tecotoo.myibg.com Update to OpenSSL 0.9.7c - BitKeeper/etc/ignore@1.35, 2003-10-26 10:19:50-05:00, mayer@tecotoo.myibg.com +7 -0 + BitKeeper/etc/ignore@1.35 +7 -0 Added {ntpd/ntp_io.c.$$$} {ports/winnt/libntp/libntp.dsp.$$$} {ports/winnt/ntp-keygen/ntpkeygen.dsp.$$$} {ports/winnt/ntpd/ntpd.dsp.$$$} {ports/winnt/ntpdate/ntpdate.dsp.$$$} {ports/winnt/ntpdc/ntpdc.dsp.$$$} {ports/winnt/ntpq/ntpq.dsp.$$$} to the ignore list - ports/winnt/libntp/libntp.dsp@1.17, 2003-10-26 10:19:32-05:00, mayer@tecotoo.myibg.com +2 -2 + ports/winnt/libntp/libntp.dsp@1.17 +2 -2 Update to OpenSSL 0.9.7c - ports/winnt/ntp-keygen/ntpkeygen.dsp@1.4, 2003-10-26 10:19:35-05:00, mayer@tecotoo.myibg.com +4 -4 + ports/winnt/ntp-keygen/ntpkeygen.dsp@1.4 +4 -4 Update to OpenSSL 0.9.7c - ports/winnt/ntpd/ntpd.dsp@1.19, 2003-10-26 10:19:38-05:00, mayer@tecotoo.myibg.com +4 -4 + ports/winnt/ntpd/ntpd.dsp@1.19 +4 -4 Update to OpenSSL 0.9.7c - ports/winnt/ntpdate/ntpdate.dsp@1.12, 2003-10-26 10:19:40-05:00, mayer@tecotoo.myibg.com +2 -2 + ports/winnt/ntpdate/ntpdate.dsp@1.12 +2 -2 Update to OpenSSL 0.9.7c - ports/winnt/ntpdc/ntpdc.dsp@1.13, 2003-10-26 10:19:43-05:00, mayer@tecotoo.myibg.com +2 -2 + ports/winnt/ntpdc/ntpdc.dsp@1.13 +2 -2 Update to OpenSSL 0.9.7c - ports/winnt/ntpq/ntpq.dsp@1.13, 2003-10-26 10:19:46-05:00, mayer@tecotoo.myibg.com +2 -2 + ports/winnt/ntpq/ntpq.dsp@1.13 +2 -2 Update to OpenSSL 0.9.7c -ChangeSet@1.1152.8.1, 2003-10-22 11:13:33-04:00, blu@corwin. +2 -0 +ChangeSet@1.1152.8.1, 2003-10-22 11:13:33-04:00, blu@corwin. ntpq_ops.c, ntpq.c: Change formatting for multiple servers and add assID for multiple association output. - ntpq/ntpq.c@1.44, 2003-10-22 11:12:09-04:00, blu@corwin. +2 -0 + ntpq/ntpq.c@1.44 +2 -0 Change formatting for multiple servers and add assID for multiple association output. - ntpq/ntpq_ops.c@1.19, 2003-10-22 11:12:55-04:00, blu@corwin. +38 -4 + ntpq/ntpq_ops.c@1.19 +38 -4 Change formatting for multiple servers and add assID for multiple association output. -ChangeSet@1.1152.1.13, 2003-10-22 13:16:39+02:00, peda@sectra.se +1 -0 +ChangeSet@1.1152.1.13, 2003-10-22 13:16:39+02:00, peda@sectra.se Fixes the bug for big endian machines, instead of killing the warning. - ntpd/refclock_jupiter.c@1.17, 2003-10-22 13:16:36+02:00, peda@sectra.se +5 -5 + ntpd/refclock_jupiter.c@1.17 +5 -5 Fixes the bug for big endian machines, instead of killing the warning. -ChangeSet@1.1152.1.12, 2003-10-22 13:12:10+02:00, peda@sectra.se +1 -0 +ChangeSet@1.1152.1.12, 2003-10-22 13:12:10+02:00, peda@sectra.se Clean up PPS handling in jupiter driver. Easier to modify source to get hardpps. - ntpd/refclock_jupiter.c@1.16, 2003-10-22 13:12:08+02:00, peda@sectra.se +13 -12 + ntpd/refclock_jupiter.c@1.16 +13 -12 Clean up PPS handling. Easier to modify source to get hardpps. -ChangeSet@1.1152.1.11, 2003-10-22 13:08:28+02:00, peda@sectra.se +1 -0 +ChangeSet@1.1152.1.11, 2003-10-22 13:08:28+02:00, peda@sectra.se Remove annying newline from syslog in the jupiter refclock. - ntpd/refclock_jupiter.c@1.15, 2003-10-22 13:08:26+02:00, peda@sectra.se +1 -1 + ntpd/refclock_jupiter.c@1.15 +1 -1 Remove annying newline from syslog. -ChangeSet@1.1152.1.10, 2003-10-20 15:10:02-04:00, stenn@whimsy.udel.edu +1 -0 +ChangeSet@1.1152.1.10, 2003-10-20 15:10:02-04:00, stenn@whimsy.udel.edu Added IPv6 to NEWS file. - NEWS@1.46, 2003-10-20 15:08:18-04:00, stenn@whimsy.udel.edu +1 -0 + NEWS@1.46 +1 -0 Added IPv6 -ChangeSet@1.1140.1.4, 2003-08-13 10:00:10-07:00, gnu@ring.wraith.sf.ca.us +1 -0 +ChangeSet@1.1140.1.4, 2003-08-13 10:00:10-07:00, gnu@ring.wraith.sf.ca.us dot-in-path fix - ntpdc/Makefile.am@1.16.1.1, 2003-08-11 14:44:20-07:00, gnu@ring.wraith.sf.ca.us +1 -1 + ntpdc/Makefile.am@1.16.1.1 +1 -1 no-dot-in-path fix for ntpdc-layout -ChangeSet@1.1140.1.1, 2003-08-10 00:13:06-07:00, gnu@ring.wraith.sf.ca.us +1 -0 +ChangeSet@1.1140.1.1, 2003-08-10 00:13:06-07:00, gnu@ring.wraith.sf.ca.us Merge bk://ntp.bkbits.net/ntp-dev into ring.wraith.sf.ca.us:/home/gnu/src/ntp/ntp-dev - BitKeeper/etc/gone@1.6, 2003-08-10 00:07:52-07:00, gnu@ring.wraith.sf.ca.us +1 -0 + BitKeeper/etc/gone@1.6 +1 -0 - BitKeeper/etc/gone@1.5, 2003-08-10 00:06:29-07:00, gnu@ring.wraith.sf.ca.us +1 -0 + BitKeeper/etc/gone@1.5 +1 -0 diff --git a/contrib/ntp/Makefile.am b/contrib/ntp/Makefile.am index 4db3a096d..43f45edbf 100644 --- a/contrib/ntp/Makefile.am +++ b/contrib/ntp/Makefile.am @@ -1,132 +1,75 @@ -#AUTOMAKE_OPTIONS = util/ansi2knr foreign dist-tarZ no-dependencies -AUTOMAKE_OPTIONS = util/ansi2knr foreign 1.8 -ACLOCAL_AMFLAGS= -I m4 -I libopts/m4 - -NULL= - -SUBDIRS= -if NEED_LIBOPTS -SUBDIRS+= libopts -endif -SUBDIRS+= \ - scripts \ - include \ - ElectricFence \ - @ARLIB_DIR@ \ - libntp \ - libparse \ - ntpd \ - ntpdate \ - ntpdc \ - ntpq \ - parseutil \ - adjtimed \ - clockstuff \ - kernel \ - sntp \ - util \ - $(NULL) +ACLOCAL_AMFLAGS = -I sntp/m4 -I sntp/libevent/m4 -I sntp/libopts/m4 + +NULL = + +# moved sntp first to get libtool and libevent built. -DIST_SUBDIRS= \ +SUBDIRS = \ + sntp \ scripts \ include \ - ElectricFence \ - arlib \ libntp \ - libopts \ libparse \ ntpd \ ntpdate \ ntpdc \ ntpq \ + ntpsnmpd \ parseutil \ adjtimed \ clockstuff \ kernel \ - sntp \ util \ + tests \ $(NULL) -DISTCHECK_CONFIGURE_FLAGS= --with-arlib --enable-local-libopts - -EXTRA_DIST = \ - COPYRIGHT \ - ChangeLog \ - CommitLog \ - CommitLog-4.1.0 \ - NEWS \ - NOTES.y2kfixes \ - README.bk \ - README.hackers \ - README.patches \ - README.refclocks \ - README.versions \ - TODO \ - WHERE-TO-START \ - bootstrap \ - build \ - config.guess \ - config.h.in \ - config.sub \ - dot.emacs \ - excludes \ - flock-build \ - install-sh \ - packageinfo.sh \ - readme.y2kfixes \ +DISTCHECK_CONFIGURE_FLAGS = -C --with-sntp --enable-local-libevent $(NTP_DCF) + +EXTRA_DIST = \ + $(srcdir)/COPYRIGHT \ + ChangeLog \ + CommitLog \ + CommitLog-4.1.0 \ + NEWS \ + NOTES.y2kfixes \ + README.bk \ + README.hackers \ + README.leapsmear \ + README.patches \ + README.refclocks \ + README.versions \ + TODO \ + WHERE-TO-START \ + bootstrap \ + build \ + config.h.in \ + dot.emacs \ + flock-build \ + packageinfo.sh \ + readme.y2kfixes \ results.y2kfixes \ \ - conf \ - html \ - libisc \ - ports \ + conf \ + html \ + lib/isc \ + libjsmn \ + ports \ \ - bincheck.mf \ - version \ - version.m4 \ + deps-ver \ \ $(NULL) +CLEANFILES = DISTCLEANFILES = .gcc-warning -#ETAGS_ARGS = $(srcdir)/Makefile.am $(srcdir)/configure.ac -ETAGS_ARGS = Makefile.am configure.ac - -# HMS: make ports be the last directory... -# DIST_HOOK_DIRS = conf html scripts ports - # HMS: Keep .gcc-warning first, as that way it gets printed first. -BUILT_SOURCES = .gcc-warning $(srcdir)/COPYRIGHT $(srcdir)/version $(srcdir)/version.m4 $(srcdir)/include/version.def - -$(srcdir)/COPYRIGHT: $(srcdir)/html/copyright.html - ( echo "This file is automatically generated from html/copyright.html" ; lynx -dump $(srcdir)/html/copyright.html ) > $(srcdir)/COPYRIGHT.new && mv $(srcdir)/COPYRIGHT.new $(srcdir)/COPYRIGHT - -# HMS: The next bit is still suboptimal. If bk is present but this NTP -# repo is not a bk repo, we'll get an error message from the prs command. -# Unfortunately, I haven't found the necessary magic to redirect this error -# output to /dev/null under ancient/unique shells like the one Ultrix uses. -# We'll also get an error if srcdir or version is unwritable. -$(srcdir)/version: FRC.version - -(bk version) >/dev/null 2>&1 && \ - cd $(srcdir) && \ - x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ - y=`cat version 2>/dev/null` || true && \ - case "$$x" in ''|$$y) ;; *) echo $$x > version ;; esac - -$(srcdir)/version.m4: $(srcdir)/packageinfo.sh - cd $(srcdir) && \ - ./scripts/genver version.m4 - -$(srcdir)/include/version.def: $(srcdir)/packageinfo.sh - cd $(srcdir) && \ - ./scripts/genver include/version.def - -dist-hook: - @find $(distdir) -type d -name CVS -print | xargs rm -rf - @find $(distdir) -type d -name SCCS -print | xargs rm -rf - @chmod u+w $(distdir)/ports/winnt - @for i in `find $(distdir)/ports/winnt -type f -name '*.ds*' -print`; \ - do chmod u+w $$i ; unix2dos $$i $$i; done +BUILT_SOURCES = \ + .gcc-warning \ + libtool \ + html/.datecheck \ + $(srcdir)/COPYRIGHT \ + $(srcdir)/.checkChangeLog \ + $(NULL) .gcc-warning: @echo "Compiling with GCC now generates lots of new warnings." @@ -140,15 +83,57 @@ dist-hook: @sleep 1 @touch $@ +html/.datecheck: FRC.html + cd $(srcdir)/html && \ + ../scripts/build/checkHtmlFileDates + +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + +sntp/built-sources-only: FRC.sntp + @cd sntp && $(MAKE) $(AM_MAKEFLAGS) built-sources-only + +$(srcdir)/COPYRIGHT: $(srcdir)/html/copyright.html + { echo "This file is automatically generated from html/copyright.html" ; \ + lynx -dump $(srcdir)/html/copyright.html ;} > COPYRIGHT.new \ + && mv -f COPYRIGHT.new $(srcdir)/COPYRIGHT + +COPYRIGHT-please: $(srcdir)/COPYRIGHT + @: do-nothing action to prevent default \ + This target is needed by sntp/Makefile.am on decrepit \ + FreeBSD 6.x make which fails with "make COPYRIGHT" \ + configured in $(srcdir) but "make ./COPYRIGHT" succeeds. \ + Rather than determine our $(srcdir) from sntp/Makefile.am \ + COPYRIGHT-please serves as a fixed target. + +$(srcdir)/.checkChangeLog: $(srcdir)/ChangeLog $(srcdir)/scripts/build/checkChangeLog + cd $(srcdir) && \ + ./scripts/build/checkChangeLog + +dist-hook: + @find $(distdir) -type d -name SCCS -print | xargs rm -rf + +install-data-local: + @echo "Installing stand-alone HTML documentation" + @( cd $(srcdir) && \ + for i in `find html -type d | grep -v SCCS` ; \ + do $(INSTALL) -d $(DESTDIR)$(htmldir)/$$i ; done ) + @( cd $(srcdir) && \ + for i in `find html -type f | grep -v SCCS` ; \ + do $(INSTALL_DATA) $$i $(DESTDIR)$(htmldir)/$$i ; done ) + +uninstall-local: + rm -rf $(DESTDIR)$(htmldir)/html + CommitLog: FRC.CommitLog cd $(srcdir) \ - && /bin/test -e CommitLog \ + && $(PATH_TEST) -e CommitLog \ -a SCCS/s.ChangeSet -ot CommitLog \ - || scripts/genCommitLog + || scripts/build/genCommitLog # HMS: The following seems to be a work-in-progress... -CVO=`$(srcdir)/config.guess` +CVO=`$(srcdir)/sntp/libevent/build-aux/config.guess` .buildcvo: echo "$(CVO)" > .buildcvo @@ -171,7 +156,8 @@ BHOST=`(hostname || uname -n)` echo " "; \ fi -FRC.CommitLog FRC.distwarn FRC.checkcvo FRC.checkhost FRC.version: +FRC.CommitLog FRC.checkcvo FRC.checkhost FRC.distwarn FRC.html FRC.sntp: + @: do-nothing action prevents any default # HMS: what was I trying to do with this? #dot.emacs: FRC.distwarn diff --git a/contrib/ntp/Makefile.in b/contrib/ntp/Makefile.in index 42b2e2e79..bc2327ff7 100644 --- a/contrib/ntp/Makefile.in +++ b/contrib/ntp/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -15,6 +14,61 @@ @SET_MAKE@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -33,49 +87,141 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -@NEED_LIBOPTS_TRUE@am__append_1 = libopts subdir = . -DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in $(srcdir)/config.h.in \ - $(top_srcdir)/configure ChangeLog INSTALL NEWS TODO compile \ - config.guess config.sub depcomp install-sh ltmain.sh missing ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ + $(am__configure_deps) $(am__DIST_COMMON) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(install_sh) -d CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = SOURCES = DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ - html-recursive info-recursive install-data-recursive \ - install-dvi-recursive install-exec-recursive \ - install-html-recursive install-info-recursive \ - install-pdf-recursive install-ps-recursive install-recursive \ - installcheck-recursive installdirs-recursive pdf-recursive \ - ps-recursive uninstall-recursive +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive -AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ - $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \ - distdir dist dist-all distcheck +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + cscope distdir dist dist-all distcheck +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ + $(LISP)config.h.in +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +CSCOPE = cscope +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \ + $(top_srcdir)/sntp/libevent/build-aux/ar-lib \ + $(top_srcdir)/sntp/libevent/build-aux/compile \ + $(top_srcdir)/sntp/libevent/build-aux/config.guess \ + $(top_srcdir)/sntp/libevent/build-aux/config.sub \ + $(top_srcdir)/sntp/libevent/build-aux/install-sh \ + $(top_srcdir)/sntp/libevent/build-aux/ltmain.sh \ + $(top_srcdir)/sntp/libevent/build-aux/missing ChangeLog \ + INSTALL NEWS README TODO compile config.guess config.sub \ + depcomp install-sh ltmain.sh missing \ + sntp/libevent/build-aux/ar-lib sntp/libevent/build-aux/compile \ + sntp/libevent/build-aux/config.guess \ + sntp/libevent/build-aux/config.sub \ + sntp/libevent/build-aux/depcomp \ + sntp/libevent/build-aux/install-sh \ + sntp/libevent/build-aux/ltmain.sh \ + sntp/libevent/build-aux/missing sntp/libevent/build-aux/ylwrap \ + ylwrap DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ - { test ! -d "$(distdir)" \ - || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -fr "$(distdir)"; }; } + if test -d "$(distdir)"; then \ + find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ + && rm -rf "$(distdir)" \ + || { sleep 5 && rm -rf "$(distdir)"; }; \ + else :; fi +am__post_remove_distdir = $(am__remove_distdir) am__relativize = \ dir0=`pwd`; \ sed_first='s,^\([^/]*\)/.*$$,\1,'; \ @@ -103,45 +249,80 @@ am__relativize = \ reldir="$$dir2" DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best +DIST_TARGETS = dist-gzip distuninstallcheck_listfiles = find . -type f -print +am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ + | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -149,8 +330,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -160,15 +344,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -176,23 +421,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -239,92 +520,85 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = util/ansi2knr foreign dist-tarZ no-dependencies -AUTOMAKE_OPTIONS = util/ansi2knr foreign 1.8 -ACLOCAL_AMFLAGS = -I m4 -I libopts/m4 +ACLOCAL_AMFLAGS = -I sntp/m4 -I sntp/libevent/m4 -I sntp/libopts/m4 NULL = -SUBDIRS = $(am__append_1) scripts include ElectricFence @ARLIB_DIR@ \ - libntp libparse ntpd ntpdate ntpdc ntpq parseutil adjtimed \ - clockstuff kernel sntp util $(NULL) -DIST_SUBDIRS = \ + +# moved sntp first to get libtool and libevent built. +SUBDIRS = \ + sntp \ scripts \ include \ - ElectricFence \ - arlib \ libntp \ - libopts \ libparse \ ntpd \ ntpdate \ ntpdc \ ntpq \ + ntpsnmpd \ parseutil \ adjtimed \ clockstuff \ kernel \ - sntp \ util \ + tests \ $(NULL) -DISTCHECK_CONFIGURE_FLAGS = --with-arlib --enable-local-libopts +DISTCHECK_CONFIGURE_FLAGS = -C --with-sntp --enable-local-libevent $(NTP_DCF) EXTRA_DIST = \ - COPYRIGHT \ - ChangeLog \ - CommitLog \ - CommitLog-4.1.0 \ - NEWS \ - NOTES.y2kfixes \ - README.bk \ - README.hackers \ - README.patches \ - README.refclocks \ - README.versions \ - TODO \ - WHERE-TO-START \ - bootstrap \ - build \ - config.guess \ - config.h.in \ - config.sub \ - dot.emacs \ - excludes \ - flock-build \ - install-sh \ - packageinfo.sh \ - readme.y2kfixes \ + $(srcdir)/COPYRIGHT \ + ChangeLog \ + CommitLog \ + CommitLog-4.1.0 \ + NEWS \ + NOTES.y2kfixes \ + README.bk \ + README.hackers \ + README.leapsmear \ + README.patches \ + README.refclocks \ + README.versions \ + TODO \ + WHERE-TO-START \ + bootstrap \ + build \ + config.h.in \ + dot.emacs \ + flock-build \ + packageinfo.sh \ + readme.y2kfixes \ results.y2kfixes \ \ - conf \ - html \ - libisc \ - ports \ + conf \ + html \ + lib/isc \ + libjsmn \ + ports \ \ - bincheck.mf \ - version \ - version.m4 \ + deps-ver \ \ $(NULL) +CLEANFILES = DISTCLEANFILES = .gcc-warning -#ETAGS_ARGS = $(srcdir)/Makefile.am $(srcdir)/configure.ac -ETAGS_ARGS = Makefile.am configure.ac - -# HMS: make ports be the last directory... -# DIST_HOOK_DIRS = conf html scripts ports - # HMS: Keep .gcc-warning first, as that way it gets printed first. -BUILT_SOURCES = .gcc-warning $(srcdir)/COPYRIGHT $(srcdir)/version $(srcdir)/version.m4 $(srcdir)/include/version.def +BUILT_SOURCES = \ + .gcc-warning \ + libtool \ + html/.datecheck \ + $(srcdir)/COPYRIGHT \ + $(srcdir)/.checkChangeLog \ + $(NULL) + # HMS: The following seems to be a work-in-progress... -CVO = `$(srcdir)/config.guess` +CVO = `$(srcdir)/sntp/libevent/build-aux/config.guess` BHOST = `(hostname || uname -n)` all: $(BUILT_SOURCES) config.h $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: -am--refresh: +am--refresh: Makefile @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ @@ -339,7 +613,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -360,10 +633,8 @@ $(ACLOCAL_M4): $(am__aclocal_m4_deps) $(am__aclocal_m4_deps): config.h: stamp-h1 - @if test ! -f $@; then \ - rm -f stamp-h1; \ - $(MAKE) $(AM_MAKEFLAGS) stamp-h1; \ - else :; fi + @test -f $@ || rm -f stamp-h1 + @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 @@ -386,22 +657,25 @@ distclean-libtool: -rm -f libtool config.lt # This directory's subdirectories are mostly independent; you can cd -# into them and run `make' without going through this Makefile. -# To change the values of `make' variables: instead of editing Makefiles, -# (1) if the variable is set in `config.status', edit `config.status' -# (which will cause the Makefiles to be regenerated when you run `make'); -# (2) otherwise, pass the desired values on the `make' command line. -$(RECURSIVE_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ @@ -416,57 +690,12 @@ $(RECURSIVE_TARGETS): $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" -$(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - rev=''; for subdir in $$list; do \ - if test "$$subdir" = "."; then :; else \ - rev="$$subdir $$rev"; \ - fi; \ - done; \ - rev="$$rev ."; \ - target=`echo $@ | sed s/-recursive//`; \ - for subdir in $$rev; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done && test -z "$$fail" -tags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ - done -ctags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ - done +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ @@ -482,12 +711,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ - list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -499,15 +723,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -516,9 +736,31 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscope: cscope.files + test ! -s cscope.files \ + || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) +clean-cscope: + -rm -f cscope.files +cscope.files: clean-cscope cscopelist +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + -rm -f cscope.out cscope.in.out cscope.po.out cscope.files distdir: $(DISTFILES) $(am__remove_distdir) @@ -554,13 +796,10 @@ distdir: $(DISTFILES) done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ - test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ @@ -584,43 +823,50 @@ distdir: $(DISTFILES) top_distdir="$(top_distdir)" distdir="$(distdir)" \ dist-hook -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ + || find "$(distdir)" -type d ! -perm -755 \ + -exec chmod u+rwx,go+rx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r "$(distdir)" dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) + $(am__post_remove_distdir) dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 - $(am__remove_distdir) + tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 + $(am__post_remove_distdir) -dist-lzma: distdir - tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma - $(am__remove_distdir) +dist-lzip: distdir + tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz + $(am__post_remove_distdir) dist-xz: distdir - tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz - $(am__remove_distdir) + tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz + $(am__post_remove_distdir) dist-tarZ: distdir + @echo WARNING: "Support for distribution archives compressed with" \ + "legacy program 'compress' is deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__remove_distdir) + $(am__post_remove_distdir) dist-shar: distdir + @echo WARNING: "Support for shar distribution archives is" \ + "deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz - $(am__remove_distdir) + $(am__post_remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) - $(am__remove_distdir) + $(am__post_remove_distdir) -dist dist-all: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) +dist dist-all: + $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' + $(am__post_remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another @@ -628,31 +874,33 @@ dist dist-all: distdir distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ - bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lzma*) \ - unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ + bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.lz*) \ + lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ *.tar.xz*) \ xz -dc $(distdir).tar.xz | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac - chmod -R a-w $(distdir); chmod a+w $(distdir) - mkdir $(distdir)/_build - mkdir $(distdir)/_inst + chmod -R a-w $(distdir) + chmod u+w $(distdir) + mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst chmod a-w $(distdir) test -d $(distdir)/_build || exit 0; \ dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && am__cwd=`pwd` \ - && $(am__cd) $(distdir)/_build \ - && ../configure --srcdir=.. --prefix="$$dc_install_base" \ + && $(am__cd) $(distdir)/_build/sub \ + && ../../configure \ + $(AM_DISTCHECK_CONFIGURE_FLAGS) \ $(DISTCHECK_CONFIGURE_FLAGS) \ + --srcdir=../.. --prefix="$$dc_install_base" \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ @@ -675,13 +923,21 @@ distcheck: dist && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ && cd "$$am__cwd" \ || exit 1 - $(am__remove_distdir) + $(am__post_remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' distuninstallcheck: - @$(am__cd) '$(distuninstallcheck_dir)' \ - && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ + @test -n '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: trying to run $@ with an empty' \ + '$$(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + $(am__cd) '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ @@ -714,13 +970,19 @@ install-am: all-am installcheck: installcheck-recursive install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -753,7 +1015,7 @@ info: info-recursive info-am: -install-data-am: +install-data-am: install-data-local install-dvi: install-dvi-recursive @@ -799,58 +1061,30 @@ ps: ps-recursive ps-am: -uninstall-am: +uninstall-am: uninstall-local -.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) all check \ - ctags-recursive install install-am install-strip \ - tags-recursive +.MAKE: $(am__recursive_targets) all check install install-am \ + install-strip -.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ - all all-am am--refresh check check-am clean clean-generic \ - clean-libtool ctags ctags-recursive dist dist-all dist-bzip2 \ - dist-gzip dist-hook dist-lzma dist-shar dist-tarZ dist-xz \ - dist-zip distcheck distclean distclean-generic distclean-hdr \ - distclean-libtool distclean-tags distcleancheck distdir \ - distuninstallcheck dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ + am--refresh check check-am clean clean-cscope clean-generic \ + clean-libtool cscope cscopelist-am ctags ctags-am dist \ + dist-all dist-bzip2 dist-gzip dist-hook dist-lzip dist-shar \ + dist-tarZ dist-xz dist-zip distcheck distclean \ + distclean-generic distclean-hdr distclean-libtool \ + distclean-tags distcleancheck distdir distuninstallcheck dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-data-local install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ installdirs-am maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ - ps ps-am tags tags-recursive uninstall uninstall-am - - -$(srcdir)/COPYRIGHT: $(srcdir)/html/copyright.html - ( echo "This file is automatically generated from html/copyright.html" ; lynx -dump $(srcdir)/html/copyright.html ) > $(srcdir)/COPYRIGHT.new && mv $(srcdir)/COPYRIGHT.new $(srcdir)/COPYRIGHT - -# HMS: The next bit is still suboptimal. If bk is present but this NTP -# repo is not a bk repo, we'll get an error message from the prs command. -# Unfortunately, I haven't found the necessary magic to redirect this error -# output to /dev/null under ancient/unique shells like the one Ultrix uses. -# We'll also get an error if srcdir or version is unwritable. -$(srcdir)/version: FRC.version - -(bk version) >/dev/null 2>&1 && \ - cd $(srcdir) && \ - x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ - y=`cat version 2>/dev/null` || true && \ - case "$$x" in ''|$$y) ;; *) echo $$x > version ;; esac - -$(srcdir)/version.m4: $(srcdir)/packageinfo.sh - cd $(srcdir) && \ - ./scripts/genver version.m4 + ps ps-am tags tags-am uninstall uninstall-am uninstall-local -$(srcdir)/include/version.def: $(srcdir)/packageinfo.sh - cd $(srcdir) && \ - ./scripts/genver include/version.def +.PRECIOUS: Makefile -dist-hook: - @find $(distdir) -type d -name CVS -print | xargs rm -rf - @find $(distdir) -type d -name SCCS -print | xargs rm -rf - @chmod u+w $(distdir)/ports/winnt - @for i in `find $(distdir)/ports/winnt -type f -name '*.ds*' -print`; \ - do chmod u+w $$i ; unix2dos $$i $$i; done .gcc-warning: @echo "Compiling with GCC now generates lots of new warnings." @@ -864,11 +1098,53 @@ dist-hook: @sleep 1 @touch $@ +html/.datecheck: FRC.html + cd $(srcdir)/html && \ + ../scripts/build/checkHtmlFileDates + +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + +sntp/built-sources-only: FRC.sntp + @cd sntp && $(MAKE) $(AM_MAKEFLAGS) built-sources-only + +$(srcdir)/COPYRIGHT: $(srcdir)/html/copyright.html + { echo "This file is automatically generated from html/copyright.html" ; \ + lynx -dump $(srcdir)/html/copyright.html ;} > COPYRIGHT.new \ + && mv -f COPYRIGHT.new $(srcdir)/COPYRIGHT + +COPYRIGHT-please: $(srcdir)/COPYRIGHT + @: do-nothing action to prevent default \ + This target is needed by sntp/Makefile.am on decrepit \ + FreeBSD 6.x make which fails with "make COPYRIGHT" \ + configured in $(srcdir) but "make ./COPYRIGHT" succeeds. \ + Rather than determine our $(srcdir) from sntp/Makefile.am \ + COPYRIGHT-please serves as a fixed target. + +$(srcdir)/.checkChangeLog: $(srcdir)/ChangeLog $(srcdir)/scripts/build/checkChangeLog + cd $(srcdir) && \ + ./scripts/build/checkChangeLog + +dist-hook: + @find $(distdir) -type d -name SCCS -print | xargs rm -rf + +install-data-local: + @echo "Installing stand-alone HTML documentation" + @( cd $(srcdir) && \ + for i in `find html -type d | grep -v SCCS` ; \ + do $(INSTALL) -d $(DESTDIR)$(htmldir)/$$i ; done ) + @( cd $(srcdir) && \ + for i in `find html -type f | grep -v SCCS` ; \ + do $(INSTALL_DATA) $$i $(DESTDIR)$(htmldir)/$$i ; done ) + +uninstall-local: + rm -rf $(DESTDIR)$(htmldir)/html + CommitLog: FRC.CommitLog cd $(srcdir) \ - && /bin/test -e CommitLog \ + && $(PATH_TEST) -e CommitLog \ -a SCCS/s.ChangeSet -ot CommitLog \ - || scripts/genCommitLog + || scripts/build/genCommitLog .buildcvo: echo "$(CVO)" > .buildcvo @@ -889,7 +1165,8 @@ CommitLog: FRC.CommitLog echo " "; \ fi -FRC.CommitLog FRC.distwarn FRC.checkcvo FRC.checkhost FRC.version: +FRC.CommitLog FRC.checkcvo FRC.checkhost FRC.distwarn FRC.html FRC.sntp: + @: do-nothing action prevents any default # HMS: what was I trying to do with this? #dot.emacs: FRC.distwarn diff --git a/contrib/ntp/NEWS b/contrib/ntp/NEWS index 729a91f0f..e16d93700 100644 --- a/contrib/ntp/NEWS +++ b/contrib/ntp/NEWS @@ -1,3 +1,1292 @@ +--- +NTP 4.2.8p4 + +Focus: Security, Bug fies, enhancements. + +Severity: MEDIUM + +In addition to bug fixes and enhancements, this release fixes the +following 13 low- and medium-severity vulnerabilities: + +* Incomplete vallen (value length) checks in ntp_crypto.c, leading + to potential crashes or potential code injection/information leakage. + + References: Sec 2899, Sec 2671, CVE-2015-7691, CVE-2015-7692, CVE-2015-7702 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, + and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:N/A:C) Base Score: 4.6 + Summary: The fix for CVE-2014-9750 was incomplete in that there were + certain code paths where a packet with particular autokey operations + that contained malicious data was not always being completely + validated. Receipt of these packets can cause ntpd to crash. + Mitigation: + Don't use autokey. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page + Monitor your ntpd instances. + Credit: This weakness was discovered by Tenable Network Security. + +* Clients that receive a KoD should validate the origin timestamp field. + + References: Sec 2901 / CVE-2015-7704, CVE-2015-7705 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, + and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:M/Au:N/C:N/I:N/A:P) Base Score: 4.3-5.0 at worst + Summary: An ntpd client that honors Kiss-of-Death responses will honor + KoD messages that have been forged by an attacker, causing it to + delay or stop querying its servers for time updates. Also, an + attacker can forge packets that claim to be from the target and + send them to servers often enough that a server that implements + KoD rate limiting will send the target machine a KoD response to + attempt to reduce the rate of incoming packets, or it may also + trigger a firewall block at the server for packets from the target + machine. For either of these attacks to succeed, the attacker must + know what servers the target is communicating with. An attacker + can be anywhere on the Internet and can frequently learn the + identity of the target's time source by sending the target a + time query. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download Page + or the NTP Public Services Project Download Page + If you can't upgrade, restrict who can query ntpd to learn who + its servers are, and what IPs are allowed to ask your system + for the time. This mitigation is heavy-handed. + Monitor your ntpd instances. + Note: + 4.2.8p4 protects against the first attack. For the second attack, + all we can do is warn when it is happening, which we do in 4.2.8p4. + Credit: This weakness was discovered by Aanchal Malhotra, + Issac E. Cohen, and Sharon Goldberg of Boston University. + +* configuration directives to change "pidfile" and "driftfile" should + only be allowed locally. + + References: Sec 2902 / CVE-2015-5196 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, + and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:C/A:C) Base Score: 6.2 worst case + Summary: If ntpd is configured to allow for remote configuration, + and if the (possibly spoofed) source IP address is allowed to + send remote configuration requests, and if the attacker knows + the remote configuration password, it's possible for an attacker + to use the "pidfile" or "driftfile" directives to potentially + overwrite other files. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page + If you cannot upgrade, don't enable remote configuration. + If you must enable remote configuration and cannot upgrade, + remote configuration of NTF's ntpd requires: + - an explicitly configured trustedkey, and you should also + configure a controlkey. + - access from a permitted IP. You choose the IPs. + - authentication. Don't disable it. Practice secure key safety. + Monitor your ntpd instances. + Credit: This weakness was discovered by Miroslav Lichvar of Red Hat. + +* Slow memory leak in CRYPTO_ASSOC + + References: Sec 2909 / CVE-2015-7701 + Affects: All ntp-4 releases that use autokey up to, but not + including 4.2.8p4, and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:N/A:C) Base Score: 0.0 best/usual case, + 4.6 otherwise + Summary: If ntpd is configured to use autokey, then an attacker can + send packets to ntpd that will, after several days of ongoing + attack, cause it to run out of memory. + Mitigation: + Don't use autokey. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page + Monitor your ntpd instances. + Credit: This weakness was discovered by Tenable Network Security. + +* mode 7 loop counter underrun + + References: Sec 2913 / CVE-2015-7848 / TALOS-CAN-0052 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, + and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:N/A:C) Base Score: 4.6 + Summary: If ntpd is configured to enable mode 7 packets, and if the + use of mode 7 packets is not properly protected thru the use of + the available mode 7 authentication and restriction mechanisms, + and if the (possibly spoofed) source IP address is allowed to + send mode 7 queries, then an attacker can send a crafted packet + to ntpd that will cause it to crash. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade: + In ntp-4.2.8, mode 7 is disabled by default. Don't enable it. + If you must enable mode 7: + configure the use of a requestkey to control who can issue + mode 7 requests. + configure restrict noquery to further limit mode 7 requests + to trusted sources. + Monitor your ntpd instances. +Credit: This weakness was discovered by Aleksandar Nikolic of Cisco Talos. + +* memory corruption in password store + + References: Sec 2916 / CVE-2015-7849 / TALOS-CAN-0054 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:C/A:C) Base Score: 6.8, worst case + Summary: If ntpd is configured to allow remote configuration, and if + the (possibly spoofed) source IP address is allowed to send + remote configuration requests, and if the attacker knows the + remote configuration password or if ntpd was configured to + disable authentication, then an attacker can send a set of + packets to ntpd that may cause a crash or theoretically + perform a code injection attack. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade, remote configuration of NTF's + ntpd requires: + an explicitly configured "trusted" key. Only configure + this if you need it. + access from a permitted IP address. You choose the IPs. + authentication. Don't disable it. Practice secure key safety. + Monitor your ntpd instances. + Credit: This weakness was discovered by Yves Younan of Cisco Talos. + +* Infinite loop if extended logging enabled and the logfile and + keyfile are the same. + + References: Sec 2917 / CVE-2015-7850 / TALOS-CAN-0055 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, + and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:N/A:C) Base Score: 4.6, worst case + Summary: If ntpd is configured to allow remote configuration, and if + the (possibly spoofed) source IP address is allowed to send + remote configuration requests, and if the attacker knows the + remote configuration password or if ntpd was configured to + disable authentication, then an attacker can send a set of + packets to ntpd that will cause it to crash and/or create a + potentially huge log file. Specifically, the attacker could + enable extended logging, point the key file at the log file, + and cause what amounts to an infinite loop. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade, remote configuration of NTF's ntpd + requires: + an explicitly configured "trusted" key. Only configure this + if you need it. + access from a permitted IP address. You choose the IPs. + authentication. Don't disable it. Practice secure key safety. + Monitor your ntpd instances. + Credit: This weakness was discovered by Yves Younan of Cisco Talos. + +* Potential path traversal vulnerability in the config file saving of + ntpd on VMS. + + References: Sec 2918 / CVE-2015-7851 / TALOS-CAN-0062 + Affects: All ntp-4 releases running under VMS up to, but not + including 4.2.8p4, and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:P/A:C) Base Score: 5.2, worst case + Summary: If ntpd is configured to allow remote configuration, and if + the (possibly spoofed) IP address is allowed to send remote + configuration requests, and if the attacker knows the remote + configuration password or if ntpd was configured to disable + authentication, then an attacker can send a set of packets to + ntpd that may cause ntpd to overwrite files. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade, remote configuration of NTF's ntpd + requires: + an explicitly configured "trusted" key. Only configure + this if you need it. + access from permitted IP addresses. You choose the IPs. + authentication. Don't disable it. Practice key security safety. + Monitor your ntpd instances. + Credit: This weakness was discovered by Yves Younan of Cisco Talos. + +* ntpq atoascii() potential memory corruption + + References: Sec 2919 / CVE-2015-7852 / TALOS-CAN-0063 + Affects: All ntp-4 releases running up to, but not including 4.2.8p4, + and 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:N/C:N/I:P/A:P) Base Score: 4.0, worst case + Summary: If an attacker can figure out the precise moment that ntpq + is listening for data and the port number it is listening on or + if the attacker can provide a malicious instance ntpd that + victims will connect to then an attacker can send a set of + crafted mode 6 response packets that, if received by ntpq, + can cause ntpq to crash. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade and you run ntpq against a server + and ntpq crashes, try again using raw mode. Build or get a + patched ntpq and see if that fixes the problem. Report new + bugs in ntpq or abusive servers appropriately. + If you use ntpq in scripts, make sure ntpq does what you expect + in your scripts. + Credit: This weakness was discovered by Yves Younan and + Aleksander Nikolich of Cisco Talos. + +* Invalid length data provided by a custom refclock driver could cause + a buffer overflow. + + References: Sec 2920 / CVE-2015-7853 / TALOS-CAN-0064 + Affects: Potentially all ntp-4 releases running up to, but not + including 4.2.8p4, and 4.3.0 up to, but not including 4.3.77 + that have custom refclocks + CVSS: (AV:L/AC:H/Au:M/C:C/I:C/A:C) Base Score: 0.0 usual case, + 5.9 unusual worst case + Summary: A negative value for the datalen parameter will overflow a + data buffer. NTF's ntpd driver implementations always set this + value to 0 and are therefore not vulnerable to this weakness. + If you are running a custom refclock driver in ntpd and that + driver supplies a negative value for datalen (no custom driver + of even minimal competence would do this) then ntpd would + overflow a data buffer. It is even hypothetically possible + in this case that instead of simply crashing ntpd the attacker + could effect a code injection attack. + Mitigation: + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade: + If you are running custom refclock drivers, make sure + the signed datalen value is either zero or positive. + Monitor your ntpd instances. + Credit: This weakness was discovered by Yves Younan of Cisco Talos. + +* Password Length Memory Corruption Vulnerability + + References: Sec 2921 / CVE-2015-7854 / TALOS-CAN-0065 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, and + 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:C/I:C/A:C) Base Score: 0.0 best case, + 1.7 usual case, 6.8, worst case + Summary: If ntpd is configured to allow remote configuration, and if + the (possibly spoofed) source IP address is allowed to send + remote configuration requests, and if the attacker knows the + remote configuration password or if ntpd was (foolishly) + configured to disable authentication, then an attacker can + send a set of packets to ntpd that may cause it to crash, + with the hypothetical possibility of a small code injection. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade, remote configuration of NTF's + ntpd requires: + an explicitly configured "trusted" key. Only configure + this if you need it. + access from a permitted IP address. You choose the IPs. + authentication. Don't disable it. Practice secure key safety. + Monitor your ntpd instances. + Credit: This weakness was discovered by Yves Younan and + Aleksander Nikolich of Cisco Talos. + +* decodenetnum() will ASSERT botch instead of returning FAIL on some + bogus values. + + References: Sec 2922 / CVE-2015-7855 + Affects: All ntp-4 releases up to, but not including 4.2.8p4, and + 4.3.0 up to, but not including 4.3.77 + CVSS: (AV:N/AC:H/Au:M/C:N/I:N/A:C) Base Score: 4.6, worst case + Summary: If ntpd is fed a crafted mode 6 or mode 7 packet containing + an unusually long data value where a network address is expected, + the decodenetnum() function will abort with an assertion failure + instead of simply returning a failure condition. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade: + mode 7 is disabled by default. Don't enable it. + Use restrict noquery to limit who can send mode 6 + and mode 7 requests. + Configure and use the controlkey and requestkey + authentication directives to limit who can + send mode 6 and mode 7 requests. + Monitor your ntpd instances. + Credit: This weakness was discovered by John D "Doug" Birdwell of IDA.org. + +* NAK to the Future: Symmetric association authentication bypass via + crypto-NAK. + + References: Sec 2941 / CVE-2015-7871 + Affects: All ntp-4 releases between 4.2.5p186 up to but not including + 4.2.8p4, and 4.3.0 up to but not including 4.3.77 + CVSS: (AV:N/AC:L/Au:N/C:N/I:P/A:P) Base Score: 6.4 + Summary: Crypto-NAK packets can be used to cause ntpd to accept time + from unauthenticated ephemeral symmetric peers by bypassing the + authentication required to mobilize peer associations. This + vulnerability appears to have been introduced in ntp-4.2.5p186 + when the code handling mobilization of new passive symmetric + associations (lines 1103-1165) was refactored. + Mitigation: + Implement BCP-38. + Upgrade to 4.2.8p4, or later, from the NTP Project Download + Page or the NTP Public Services Project Download Page. + If you are unable to upgrade: + Apply the patch to the bottom of the "authentic" check + block around line 1136 of ntp_proto.c. + Monitor your ntpd instances. + Credit: This weakness was discovered by Stephen Gray . + +Backward-Incompatible changes: +* [Bug 2817] Default on Linux is now "rlimit memlock -1". +While the general default of 32M is still the case, under Linux +the default value has been changed to -1 (do not lock ntpd into + memory). A value of 0 means "lock ntpd into memory with whatever + memory it needs." If your ntp.conf file has an explicit "rlimit memlock" + value in it, that value will continue to be used. + +* [Bug 2886] Misspelling: "outlyer" should be "outlier". + If you've written a script that looks for this case in, say, the + output of ntpq, you probably want to change your regex matches + from 'outlyer' to 'outl[iy]er'. + +New features in this release: +* 'rlimit memlock' now has finer-grained control. A value of -1 means + "don't lock ntpd into memore". This is the default for Linux boxes. + A value of 0 means "lock ntpd into memory" with no limits. Otherwise + the value is the number of megabytes of memory to lock. The default + is 32 megabytes. + +* The old Google Test framework has been replaced with a new framework, + based on http://www.throwtheswitch.org/unity/ . + +Bug Fixes and Improvements: +* [Bug 2332] (reopened) Exercise thread cancellation once before dropping + privileges and limiting resources in NTPD removes the need to link + forcefully against 'libgcc_s' which does not always work. J.Perlinger +* [Bug 2595] ntpdate man page quirks. Hal Murray, Harlan Stenn. +* [Bug 2625] Deprecate flag1 in local refclock. Hal Murray, Harlan Stenn. +* [Bug 2817] Stop locking ntpd into memory by default under Linux. H.Stenn. +* [Bug 2821] minor build issues: fixed refclock_gpsdjson.c. perlinger@ntp.org +* [Bug 2823] ntpsweep with recursive peers option doesn't work. H.Stenn. +* [Bug 2849] Systems with more than one default route may never + synchronize. Brian Utterback. Note that this patch might need to + be reverted once Bug 2043 has been fixed. +* [Bug 2864] 4.2.8p3 fails to compile on Windows. Juergen Perlinger +* [Bug 2866] segmentation fault at initgroups(). Harlan Stenn. +* [Bug 2867] ntpd with autokey active crashed by 'ntpq -crv'. J.Perlinger +* [Bug 2873] libevent should not include .deps/ in the tarball. H.Stenn +* [Bug 2874] Don't distribute generated sntp/tests/fileHandlingTest.h. H.Stenn +* [Bug 2875] sntp/Makefile.am: Get rid of DIST_SUBDIRS. libevent must + be configured for the distribution targets. Harlan Stenn. +* [Bug 2883] ntpd crashes on exit with empty driftfile. Miroslav Lichvar. +* [Bug 2886] Mis-spelling: "outlyer" should be "outlier". dave@horsfall.org +* [Bug 2888] streamline calendar functions. perlinger@ntp.org +* [Bug 2889] ntp-dev-4.3.67 does not build on Windows. perlinger@ntp.org +* [Bug 2890] Ignore ENOBUFS on routing netlink socket. Konstantin Khlebnikov. +* [Bug 2906] make check needs better support for pthreads. Harlan Stenn. +* [Bug 2907] dist* build targets require our libevent/ to be enabled. HStenn. +* [Bug 2912] no munlockall() under Windows. David Taylor, Harlan Stenn. +* libntp/emalloc.c: Remove explicit include of stdint.h. Harlan Stenn. +* Put Unity CPPFLAGS items in unity_config.h. Harlan Stenn. +* tests/ntpd/g_leapsec.cpp typo fix. Harlan Stenn. +* Phase 1 deprecation of google test in sntp/tests/. Harlan Stenn. +* On some versions of HP-UX, inttypes.h does not include stdint.h. H.Stenn. +* top_srcdir can change based on ntp v. sntp. Harlan Stenn. +* sntp/tests/ function parameter list cleanup. Damir Tomić. +* tests/libntp/ function parameter list cleanup. Damir Tomić. +* tests/ntpd/ function parameter list cleanup. Damir Tomić. +* sntp/unity/unity_config.h: handle stdint.h. Harlan Stenn. +* sntp/unity/unity_internals.h: handle *INTPTR_MAX on old Solaris. H.Stenn. +* tests/libntp/timevalops.c and timespecops.c fixed error printing. D.Tomić. +* tests/libntp/ improvements in code and fixed error printing. Damir Tomić. +* tests/libntp: a_md5encrypt.c, authkeys.c, buftvtots.c, calendar.c, caljulian.c, + caltontp.c, clocktime.c, humandate.c, hextolfp.c, decodenetnum.c - fixed + formatting; first declaration, then code (C90); deleted unnecessary comments; + changed from sprintf to snprintf; fixed order of includes. Tomasz Flendrich +* tests/libntp/lfpfunc.c remove unnecessary include, remove old comments, + fix formatting, cleanup. Tomasz Flendrich +* tests/libntp/lfptostr.c remove unnecessary include, add consts, fix formatting. + Tomasz Flendrich +* tests/libntp/statestr.c remove empty functions, remove unnecessary include, + fix formatting. Tomasz Flendrich +* tests/libntp/modetoa.c fixed formatting. Tomasz Flendrich +* tests/libntp/msyslog.c fixed formatting. Tomasz Flendrich +* tests/libntp/numtoa.c deleted unnecessary empty functions, fixed formatting. + Tomasz Flendrich +* tests/libntp/numtohost.c added const, fixed formatting. Tomasz Flendrich +* tests/libntp/refnumtoa.c fixed formatting. Tomasz Flendrich +* tests/libntp/ssl_init.c fixed formatting. Tomasz Flendrich +* tests/libntp/tvtots.c fixed a bug, fixed formatting. Tomasz Flendrich +* tests/libntp/uglydate.c removed an unnecessary include. Tomasz Flendrich +* tests/libntp/vi64ops.c removed an unnecessary comment, fixed formatting. +* tests/libntp/ymd3yd.c removed an empty function and an unnecessary include, +fixed formatting. Tomasz Flendrich +* tests/libntp/timespecops.c fixed formatting, fixed the order of includes, + removed unnecessary comments, cleanup. Tomasz Flendrich +* tests/libntp/timevalops.c fixed the order of includes, deleted unnecessary + comments, cleanup. Tomasz Flendrich +* tests/libntp/sockaddrtest.h making it agree to NTP's conventions of formatting. + Tomasz Flendrich +* tests/libntp/lfptest.h cleanup. Tomasz Flendrich +* tests/libntp/test-libntp.c fix formatting. Tomasz Flendrich +* sntp/tests/crypto.c is now using proper Unity's assertions, fixed formatting. + Tomasz Flendrich +* sntp/tests/kodDatabase.c added consts, deleted empty function, + fixed formatting. Tomasz Flendrich +* sntp/tests/kodFile.c cleanup, fixed formatting. Tomasz Flendrich +* sntp/tests/packetHandling.c is now using proper Unity's assertions, + fixed formatting, deleted unused variable. Tomasz Flendrich +* sntp/tests/keyFile.c is now using proper Unity's assertions, fixed formatting. + Tomasz Flendrich +* sntp/tests/packetProcessing.c changed from sprintf to snprintf, + fixed formatting. Tomasz Flendrich +* sntp/tests/utilities.c is now using proper Unity's assertions, changed + the order of includes, fixed formatting, removed unnecessary comments. + Tomasz Flendrich +* sntp/tests/sntptest.h fixed formatting. Tomasz Flendrich +* sntp/tests/fileHandlingTest.h.in fixed a possible buffer overflow problem, + made one function do its job, deleted unnecessary prints, fixed formatting. + Tomasz Flendrich +* sntp/unity/Makefile.am added a missing header. Tomasz Flendrich +* sntp/unity/unity_config.h: Distribute it. Harlan Stenn. +* sntp/libevent/evconfig-private.h: remove generated filefrom SCM. H.Stenn. +* sntp/unity/Makefile.am: fix some broken paths. Harlan Stenn. +* sntp/unity/unity.c: Clean up a printf(). Harlan Stenn. +* Phase 1 deprecation of google test in tests/libntp/. Harlan Stenn. +* Don't build sntp/libevent/sample/. Harlan Stenn. +* tests/libntp/test_caltontp needs -lpthread. Harlan Stenn. +* br-flock: --enable-local-libevent. Harlan Stenn. +* Wrote tests for ntpd/ntp_prio_q.c. Tomasz Flendrich +* scripts/lib/NTP/Util.pm: stratum output is version-dependent. Harlan Stenn. +* Get rid of the NTP_ prefix on our assertion macros. Harlan Stenn. +* Code cleanup. Harlan Stenn. +* libntp/icom.c: Typo fix. Harlan Stenn. +* util/ntptime.c: initialization nit. Harlan Stenn. +* ntpd/ntp_peer.c:newpeer(): added a DEBUG_REQUIRE(srcadr). Harlan Stenn. +* Add std_unity_tests to various Makefile.am files. Harlan Stenn. +* ntpd/ntp_restrict.c: added a few assertions, created tests for this file. + Tomasz Flendrich +* Changed progname to be const in many files - now it's consistent. Tomasz + Flendrich +* Typo fix for GCC warning suppression. Harlan Stenn. +* Added tests/ntpd/ntp_scanner.c test. Damir Tomić. +* Added declarations to all Unity tests, and did minor fixes to them. + Reduced the number of warnings by half. Damir Tomić. +* Updated generate_test_runner.rb and updated the sntp/unity/auto directory + with the latest Unity updates from Mark. Damir Tomić. +* Retire google test - phase I. Harlan Stenn. +* Unity test cleanup: move declaration of 'initializing'. Harlan Stenn. +* Update the NEWS file. Harlan Stenn. +* Autoconf cleanup. Harlan Stenn. +* Unit test dist cleanup. Harlan Stenn. +* Cleanup various test Makefile.am files. Harlan Stenn. +* Pthread autoconf macro cleanup. Harlan Stenn. +* Fix progname definition in unity runner scripts. Harlan Stenn. +* Clean trailing whitespace in tests/ntpd/Makefile.am. Harlan Stenn. +* Update the patch for bug 2817. Harlan Stenn. +* More updates for bug 2817. Harlan Stenn. +* Fix bugs in tests/ntpd/ntp_prio_q.c. Harlan Stenn. +* gcc on older HPUX may need +allowdups. Harlan Stenn. +* Adding missing MCAST protection. Harlan Stenn. +* Disable certain test programs on certain platforms. Harlan Stenn. +* Implement --enable-problem-tests (on by default). Harlan Stenn. +* build system tweaks. Harlan Stenn. + +--- +NTP 4.2.8p3 (Harlan Stenn , 2015/06/29) + +Focus: 1 Security fix. Bug fixes and enhancements. Leap-second improvements. + +Severity: MEDIUM + +Security Fix: + +* [Sec 2853] Crafted remote config packet can crash some versions of + ntpd. Aleksis Kauppinen, Juergen Perlinger, Harlan Stenn. + +Under specific circumstances an attacker can send a crafted packet to +cause a vulnerable ntpd instance to crash. This requires each of the +following to be true: + +1) ntpd set up to allow remote configuration (not allowed by default), and +2) knowledge of the configuration password, and +3) access to a computer entrusted to perform remote configuration. + +This vulnerability is considered low-risk. + +New features in this release: + +Optional (disabled by default) support to have ntpd provide smeared +leap second time. A specially built and configured ntpd will only +offer smeared time in response to client packets. These response +packets will also contain a "refid" of 254.a.b.c, where the 24 bits +of a, b, and c encode the amount of smear in a 2:22 integer:fraction +format. See README.leapsmear and http://bugs.ntp.org/2855 for more +information. + + *IF YOU CHOOSE TO CONFIGURE NTPD TO PROVIDE LEAP SMEAR TIME* + *BE SURE YOU DO NOT OFFER THAT TIME ON PUBLIC TIMESERVERS.* + +We've imported the Unity test framework, and have begun converting +the existing google-test items to this new framework. If you want +to write new tests or change old ones, you'll need to have ruby +installed. You don't need ruby to run the test suite. + +Bug Fixes and Improvements: + +* CID 739725: Fix a rare resource leak in libevent/listener.c. +* CID 1295478: Quiet a pedantic potential error from the fix for Bug 2776. +* CID 1296235: Fix refclock_jjy.c and correcting type of the driver40-ja.html +* CID 1269537: Clean up a line of dead code in getShmTime(). +* [Bug 1060] Buffer overruns in libparse/clk_rawdcf.c. Helge Oldach. +* [Bug 2590] autogen-5.18.5. +* [Bug 2612] restrict: Warn when 'monitor' can't be disabled because + of 'limited'. +* [Bug 2650] fix includefile processing. +* [Bug 2745] ntpd -x steps clock on leap second + Fixed an initial-value problem that caused misbehaviour in absence of + any leapsecond information. + Do leap second stepping only of the step adjustment is beyond the + proper jump distance limit and step correction is allowed at all. +* [Bug 2750] build for Win64 + Building for 32bit of loopback ppsapi needs def file +* [Bug 2776] Improve ntpq's 'help keytype'. +* [Bug 2778] Implement "apeers" ntpq command to include associd. +* [Bug 2782] Refactor refclock_shm.c, add memory barrier protection. +* [Bug 2792] If the IFF_RUNNING interface flag is supported then an + interface is ignored as long as this flag is not set since the + interface is not usable (e.g., no link). +* [Bug 2794] Clean up kernel clock status reports. +* [Bug 2800] refclock_true.c true_debug() can't open debug log because + of incompatible open/fdopen parameters. +* [Bug 2804] install-local-data assumes GNU 'find' semantics. +* [Bug 2805] ntpd fails to join multicast group. +* [Bug 2806] refclock_jjy.c supports the Telephone JJY. +* [Bug 2808] GPSD_JSON driver enhancements, step 1. + Fix crash during cleanup if GPS device not present and char device. + Increase internal token buffer to parse all JSON data, even SKY. + Defer logging of errors during driver init until the first unit is + started, so the syslog is not cluttered when the driver is not used. + Various improvements, see http://bugs.ntp.org/2808 for details. + Changed libjsmn to a more recent version. +* [Bug 2810] refclock_shm.c memory barrier code needs tweaks for QNX. +* [Bug 2813] HP-UX needs -D__STDC_VERSION__=199901L and limits.h. +* [Bug 2815] net-snmp before v5.4 has circular library dependencies. +* [Bug 2821] Add a missing NTP_PRINTF and a missing const. +* [Bug 2822] New leap column in sntp broke NTP::Util.pm. +* [Bug 2824] Convert update-leap to perl. (also see 2769) +* [Bug 2825] Quiet file installation in html/ . +* [Bug 2830] ntpd doesn't always transfer the correct TAI offset via autokey + NTPD transfers the current TAI (instead of an announcement) now. + This might still needed improvement. + Update autokey data ASAP when 'sys_tai' changes. + Fix unit test that was broken by changes for autokey update. + Avoid potential signature length issue and use DPRINTF where possible + in ntp_crypto.c. +* [Bug 2832] refclock_jjy.c supports the TDC-300. +* [Bug 2834] Correct a broken html tag in html/refclock.html +* [Bug 2836] DFC77 patches from Frank Kardel to make decoding more + robust, and require 2 consecutive timestamps to be consistent. +* [Bug 2837] Allow a configurable DSCP value. +* [Bug 2837] add test for DSCP to ntpd/complete.conf.in +* [Bug 2842] Glitch in ntp.conf.def documentation stanza. +* [Bug 2842] Bug in mdoc2man. +* [Bug 2843] make check fails on 4.3.36 + Fixed compiler warnings about numeric range overflow + (The original topic was fixed in a byplay to bug#2830) +* [Bug 2845] Harden memory allocation in ntpd. +* [Bug 2852] 'make check' can't find unity.h. Hal Murray. +* [Bug 2854] Missing brace in libntp/strdup.c. Masanari Iida. +* [Bug 2855] Parser fix for conditional leap smear code. Harlan Stenn. +* [Bug 2855] Report leap smear in the REFID. Harlan Stenn. +* [Bug 2855] Implement conditional leap smear code. Martin Burnicki. +* [Bug 2856] ntpd should wait() on terminated child processes. Paul Green. +* [Bug 2857] Stratus VOS does not support SIGIO. Paul Green. +* [Bug 2859] Improve raw DCF77 robustness deconding. Frank Kardel. +* [Bug 2860] ntpq ifstats sanity check is too stringent. Frank Kardel. +* html/drivers/driver22.html: typo fix. Harlan Stenn. +* refidsmear test cleanup. Tomasz Flendrich. +* refidsmear function support and tests. Harlan Stenn. +* sntp/tests/Makefile.am: remove g_nameresolution.cpp as it tested + something that was only in the 4.2.6 sntp. Harlan Stenn. +* Modified tests/bug-2803/Makefile.am so it builds Unity framework tests. + Damir Tomić +* Modified tests/libtnp/Makefile.am so it builds Unity framework tests. + Damir Tomić +* Modified sntp/tests/Makefile.am so it builds Unity framework tests. + Damir Tomić +* tests/sandbox/smeartest.c: Harlan Stenn, Damir Tomic, Juergen Perlinger. +* Converted from gtest to Unity: tests/bug-2803/. Damir Tomić +* Converted from gtest to Unity: tests/libntp/ a_md5encrypt, atoint.c, + atouint.c, authkeys.c, buftvtots.c, calendar.c, caljulian.c, + calyearstart.c, clocktime.c, hextoint.c, lfpfunc.c, modetoa.c, + numtoa.c, numtohost.c, refnumtoa.c, ssl_init.c, statestr.c, + timespecops.c, timevalops.c, uglydate.c, vi64ops.c, ymd2yd.c. + Damir Tomić +* Converted from gtest to Unity: sntp/tests/ kodDatabase.c, kodFile.c, + networking.c, keyFile.c, utilities.cpp, sntptest.h, + fileHandlingTest.h. Damir Tomić +* Initial support for experimental leap smear code. Harlan Stenn. +* Fixes to sntp/tests/fileHandlingTest.h.in. Harlan Stenn. +* Report select() debug messages at debug level 3 now. +* sntp/scripts/genLocInfo: treat raspbian as debian. +* Unity test framework fixes. + ** Requires ruby for changes to tests. +* Initial support for PACKAGE_VERSION tests. +* sntp/libpkgver belongs in EXTRA_DIST, not DIST_SUBDIRS. +* tests/bug-2803/Makefile.am must distribute bug-2803.h. +* Add an assert to the ntpq ifstats code. +* Clean up the RLIMIT_STACK code. +* Improve the ntpq documentation around the controlkey keyid. +* ntpq.c cleanup. +* Windows port build cleanup. + +--- +NTP 4.2.8p2 (Harlan Stenn , 2015/04/07) + +Focus: Security and Bug fixes, enhancements. + +Severity: MEDIUM + +In addition to bug fixes and enhancements, this release fixes the +following medium-severity vulnerabilities involving private key +authentication: + +* [Sec 2779] ntpd accepts unauthenticated packets with symmetric key crypto. + + References: Sec 2779 / CVE-2015-1798 / VU#374268 + Affects: All NTP4 releases starting with ntp-4.2.5p99 up to but not + including ntp-4.2.8p2 where the installation uses symmetric keys + to authenticate remote associations. + CVSS: (AV:A/AC:M/Au:N/C:P/I:P/A:P) Base Score: 5.4 + Date Resolved: Stable (4.2.8p2) 07 Apr 2015 + Summary: When ntpd is configured to use a symmetric key to authenticate + a remote NTP server/peer, it checks if the NTP message + authentication code (MAC) in received packets is valid, but not if + there actually is any MAC included. Packets without a MAC are + accepted as if they had a valid MAC. This allows a MITM attacker to + send false packets that are accepted by the client/peer without + having to know the symmetric key. The attacker needs to know the + transmit timestamp of the client to match it in the forged reply + and the false reply needs to reach the client before the genuine + reply from the server. The attacker doesn't necessarily need to be + relaying the packets between the client and the server. + + Authentication using autokey doesn't have this problem as there is + a check that requires the key ID to be larger than NTP_MAXKEY, + which fails for packets without a MAC. + Mitigation: + Upgrade to 4.2.8p2, or later, from the NTP Project Download Page + or the NTP Public Services Project Download Page + Configure ntpd with enough time sources and monitor it properly. + Credit: This issue was discovered by Miroslav Lichvar, of Red Hat. + +* [Sec 2781] Authentication doesn't protect symmetric associations against + DoS attacks. + + References: Sec 2781 / CVE-2015-1799 / VU#374268 + Affects: All NTP releases starting with at least xntp3.3wy up to but + not including ntp-4.2.8p2 where the installation uses symmetric + key authentication. + CVSS: (AV:A/AC:M/Au:N/C:P/I:P/A:P) Base Score: 5.4 + Note: the CVSS base Score for this issue could be 4.3 or lower, and + it could be higher than 5.4. + Date Resolved: Stable (4.2.8p2) 07 Apr 2015 + Summary: An attacker knowing that NTP hosts A and B are peering with + each other (symmetric association) can send a packet to host A + with source address of B which will set the NTP state variables + on A to the values sent by the attacker. Host A will then send + on its next poll to B a packet with originate timestamp that + doesn't match the transmit timestamp of B and the packet will + be dropped. If the attacker does this periodically for both + hosts, they won't be able to synchronize to each other. This is + a known denial-of-service attack, described at + https://www.eecis.udel.edu/~mills/onwire.html . + + According to the document the NTP authentication is supposed to + protect symmetric associations against this attack, but that + doesn't seem to be the case. The state variables are updated even + when authentication fails and the peers are sending packets with + originate timestamps that don't match the transmit timestamps on + the receiving side. + + This seems to be a very old problem, dating back to at least + xntp3.3wy. It's also in the NTPv3 (RFC 1305) and NTPv4 (RFC 5905) + specifications, so other NTP implementations with support for + symmetric associations and authentication may be vulnerable too. + An update to the NTP RFC to correct this error is in-process. + Mitigation: + Upgrade to 4.2.8p2, or later, from the NTP Project Download Page + or the NTP Public Services Project Download Page + Note that for users of autokey, this specific style of MITM attack + is simply a long-known potential problem. + Configure ntpd with appropriate time sources and monitor ntpd. + Alert your staff if problems are detected. + Credit: This issue was discovered by Miroslav Lichvar, of Red Hat. + +* New script: update-leap +The update-leap script will verify and if necessary, update the +leap-second definition file. +It requires the following commands in order to work: + + wget logger tr sed shasum + +Some may choose to run this from cron. It needs more portability testing. + +Bug Fixes and Improvements: + +* [Bug 1787] DCF77's formerly "antenna" bit is "call bit" since 2003. +* [Bug 1960] setsockopt IPV6_MULTICAST_IF: Invalid argument. +* [Bug 2346] "graceful termination" signals do not do peer cleanup. +* [Bug 2728] See if C99-style structure initialization works. +* [Bug 2747] Upgrade libevent to 2.1.5-beta. +* [Bug 2749] ntp/lib/NTP/Util.pm needs update for ntpq -w, IPv6, .POOL. . +* [Bug 2751] jitter.h has stale copies of l_fp macros. +* [Bug 2756] ntpd hangs in startup with gcc 3.3.5 on ARM. +* [Bug 2757] Quiet compiler warnings. +* [Bug 2759] Expose nonvolatile/clk_wander_threshold to ntpq. +* [Bug 2763] Allow different thresholds for forward and backward steps. +* [Bug 2766] ntp-keygen output files should not be world-readable. +* [Bug 2767] ntp-keygen -M should symlink to ntp.keys. +* [Bug 2771] nonvolatile value is documented in wrong units. +* [Bug 2773] Early leap announcement from Palisade/Thunderbolt +* [Bug 2774] Unreasonably verbose printout - leap pending/warning +* [Bug 2775] ntp-keygen.c fails to compile under Windows. +* [Bug 2777] Fixed loops and decoding of Meinberg GPS satellite info. + Removed non-ASCII characters from some copyright comments. + Removed trailing whitespace. + Updated definitions for Meinberg clocks from current Meinberg header files. + Now use C99 fixed-width types and avoid non-ASCII characters in comments. + Account for updated definitions pulled from Meinberg header files. + Updated comments on Meinberg GPS receivers which are not only called GPS16x. + Replaced some constant numbers by defines from ntp_calendar.h + Modified creation of parse-specific variables for Meinberg devices + in gps16x_message(). + Reworked mk_utcinfo() to avoid printing of ambiguous leap second dates. + Modified mbg_tm_str() which now expexts an additional parameter controlling + if the time status shall be printed. +* [Sec 2779] ntpd accepts unauthenticated packets with symmetric key crypto. +* [Sec 2781] Authentication doesn't protect symmetric associations against + DoS attacks. +* [Bug 2783] Quiet autoconf warnings about missing AC_LANG_SOURCE. +* [Bug 2789] Quiet compiler warnings from libevent. +* [Bug 2790] If ntpd sets the Windows MM timer highest resolution + pause briefly before measuring system clock precision to yield + correct results. +* Comment from Juergen Perlinger in ntp_calendar.c to make the code clearer. +* Use predefined function types for parse driver functions + used to set up function pointers. + Account for changed prototype of parse_inp_fnc_t functions. + Cast parse conversion results to appropriate types to avoid + compiler warnings. + Let ioctl() for Windows accept a (void *) to avoid compiler warnings + when called with pointers to different types. + +--- +NTP 4.2.8p1 (Harlan Stenn , 2015/02/04) + +Focus: Security and Bug fixes, enhancements. + +Severity: HIGH + +In addition to bug fixes and enhancements, this release fixes the +following high-severity vulnerabilities: + +* vallen is not validated in several places in ntp_crypto.c, leading + to a potential information leak or possibly a crash + + References: Sec 2671 / CVE-2014-9297 / VU#852879 + Affects: All NTP4 releases before 4.2.8p1 that are running autokey. + CVSS: (AV:N/AC:L/Au:N/C:P/I:P/A:P) Base Score: 7.5 + Date Resolved: Stable (4.2.8p1) 04 Feb 2015 + Summary: The vallen packet value is not validated in several code + paths in ntp_crypto.c which can lead to information leakage + or perhaps a crash of the ntpd process. + Mitigation - any of: + Upgrade to 4.2.8p1, or later, from the NTP Project Download Page + or the NTP Public Services Project Download Page. + Disable Autokey Authentication by removing, or commenting out, + all configuration directives beginning with the "crypto" + keyword in your ntp.conf file. + Credit: This vulnerability was discovered by Stephen Roettger of the + Google Security Team, with additional cases found by Sebastian + Krahmer of the SUSE Security Team and Harlan Stenn of Network + Time Foundation. + +* ::1 can be spoofed on some OSes, so ACLs based on IPv6 ::1 addresses + can be bypassed. + + References: Sec 2672 / CVE-2014-9298 / VU#852879 + Affects: All NTP4 releases before 4.2.8p1, under at least some + versions of MacOS and Linux. *BSD has not been seen to be vulnerable. + CVSS: (AV:N/AC:L/Au:N/C:P/I:P/A:C) Base Score: 9 + Date Resolved: Stable (4.2.8p1) 04 Feb 2014 + Summary: While available kernels will prevent 127.0.0.1 addresses + from "appearing" on non-localhost IPv4 interfaces, some kernels + do not offer the same protection for ::1 source addresses on + IPv6 interfaces. Since NTP's access control is based on source + address and localhost addresses generally have no restrictions, + an attacker can send malicious control and configuration packets + by spoofing ::1 addresses from the outside. Note Well: This is + not really a bug in NTP, it's a problem with some OSes. If you + have one of these OSes where ::1 can be spoofed, ALL ::1 -based + ACL restrictions on any application can be bypassed! + Mitigation: + Upgrade to 4.2.8p1, or later, from the NTP Project Download Page + or the NTP Public Services Project Download Page + Install firewall rules to block packets claiming to come from + ::1 from inappropriate network interfaces. + Credit: This vulnerability was discovered by Stephen Roettger of + the Google Security Team. + +Additionally, over 30 bugfixes and improvements were made to the codebase. +See the ChangeLog for more information. + +--- +NTP 4.2.8 (Harlan Stenn , 2014/12/18) + +Focus: Security and Bug fixes, enhancements. + +Severity: HIGH + +In addition to bug fixes and enhancements, this release fixes the +following high-severity vulnerabilities: + +************************** vv NOTE WELL vv ***************************** + +The vulnerabilities listed below can be significantly mitigated by +following the BCP of putting + + restrict default ... noquery + +in the ntp.conf file. With the exception of: + + receive(): missing return on error + References: Sec 2670 / CVE-2014-9296 / VU#852879 + +below (which is a limited-risk vulnerability), none of the recent +vulnerabilities listed below can be exploited if the source IP is +restricted from sending a 'query'-class packet by your ntp.conf file. + +************************** ^^ NOTE WELL ^^ ***************************** + +* Weak default key in config_auth(). + + References: [Sec 2665] / CVE-2014-9293 / VU#852879 + CVSS: (AV:N/AC:L/Au:M/C:P/I:P/A:C) Base Score: 7.3 + Vulnerable Versions: all releases prior to 4.2.7p11 + Date Resolved: 28 Jan 2010 + + Summary: If no 'auth' key is set in the configuration file, ntpd + would generate a random key on the fly. There were two + problems with this: 1) the generated key was 31 bits in size, + and 2) it used the (now weak) ntp_random() function, which was + seeded with a 32-bit value and could only provide 32 bits of + entropy. This was sufficient back in the late 1990s when the + code was written. Not today. + + Mitigation - any of: + - Upgrade to 4.2.7p11 or later. + - Follow BCP and put 'restrict ... noquery' in your ntp.conf file. + + Credit: This vulnerability was noticed in ntp-4.2.6 by Neel Mehta + of the Google Security Team. + +* Non-cryptographic random number generator with weak seed used by + ntp-keygen to generate symmetric keys. + + References: [Sec 2666] / CVE-2014-9294 / VU#852879 + CVSS: (AV:N/AC:L/Au:M/C:P/I:P/A:C) Base Score: 7.3 + Vulnerable Versions: All NTP4 releases before 4.2.7p230 + Date Resolved: Dev (4.2.7p230) 01 Nov 2011 + + Summary: Prior to ntp-4.2.7p230 ntp-keygen used a weak seed to + prepare a random number generator that was of good quality back + in the late 1990s. The random numbers produced was then used to + generate symmetric keys. In ntp-4.2.8 we use a current-technology + cryptographic random number generator, either RAND_bytes from + OpenSSL, or arc4random(). + + Mitigation - any of: + - Upgrade to 4.2.7p230 or later. + - Follow BCP and put 'restrict ... noquery' in your ntp.conf file. + + Credit: This vulnerability was discovered in ntp-4.2.6 by + Stephen Roettger of the Google Security Team. + +* Buffer overflow in crypto_recv() + + References: Sec 2667 / CVE-2014-9295 / VU#852879 + CVSS: (AV:N/AC:L/Au:N/C:P/I:P/A:P) Base Score: 7.5 + Versions: All releases before 4.2.8 + Date Resolved: Stable (4.2.8) 18 Dec 2014 + + Summary: When Autokey Authentication is enabled (i.e. the ntp.conf + file contains a 'crypto pw ...' directive) a remote attacker + can send a carefully crafted packet that can overflow a stack + buffer and potentially allow malicious code to be executed + with the privilege level of the ntpd process. + + Mitigation - any of: + - Upgrade to 4.2.8, or later, or + - Disable Autokey Authentication by removing, or commenting out, + all configuration directives beginning with the crypto keyword + in your ntp.conf file. + + Credit: This vulnerability was discovered by Stephen Roettger of the + Google Security Team. + +* Buffer overflow in ctl_putdata() + + References: Sec 2668 / CVE-2014-9295 / VU#852879 + CVSS: (AV:N/AC:L/Au:N/C:P/I:P/A:P) Base Score: 7.5 + Versions: All NTP4 releases before 4.2.8 + Date Resolved: Stable (4.2.8) 18 Dec 2014 + + Summary: A remote attacker can send a carefully crafted packet that + can overflow a stack buffer and potentially allow malicious + code to be executed with the privilege level of the ntpd process. + + Mitigation - any of: + - Upgrade to 4.2.8, or later. + - Follow BCP and put 'restrict ... noquery' in your ntp.conf file. + + Credit: This vulnerability was discovered by Stephen Roettger of the + Google Security Team. + +* Buffer overflow in configure() + + References: Sec 2669 / CVE-2014-9295 / VU#852879 + CVSS: (AV:N/AC:L/Au:N/C:P/I:P/A:P) Base Score: 7.5 + Versions: All NTP4 releases before 4.2.8 + Date Resolved: Stable (4.2.8) 18 Dec 2014 + + Summary: A remote attacker can send a carefully crafted packet that + can overflow a stack buffer and potentially allow malicious + code to be executed with the privilege level of the ntpd process. + + Mitigation - any of: + - Upgrade to 4.2.8, or later. + - Follow BCP and put 'restrict ... noquery' in your ntp.conf file. + + Credit: This vulnerability was discovered by Stephen Roettger of the + Google Security Team. + +* receive(): missing return on error + + References: Sec 2670 / CVE-2014-9296 / VU#852879 + CVSS: (AV:N/AC:L/Au:N/C:N/I:N/A:P) Base Score: 5.0 + Versions: All NTP4 releases before 4.2.8 + Date Resolved: Stable (4.2.8) 18 Dec 2014 + + Summary: Code in ntp_proto.c:receive() was missing a 'return;' in + the code path where an error was detected, which meant + processing did not stop when a specific rare error occurred. + We haven't found a way for this bug to affect system integrity. + If there is no way to affect system integrity the base CVSS + score for this bug is 0. If there is one avenue through which + system integrity can be partially affected, the base score + becomes a 5. If system integrity can be partially affected + via all three integrity metrics, the CVSS base score become 7.5. + + Mitigation - any of: + - Upgrade to 4.2.8, or later, + - Remove or comment out all configuration directives + beginning with the crypto keyword in your ntp.conf file. + + Credit: This vulnerability was discovered by Stephen Roettger of the + Google Security Team. + +See http://support.ntp.org/security for more information. + +New features / changes in this release: + +Important Changes + +* Internal NTP Era counters + +The internal counters that track the "era" (range of years) we are in +rolls over every 136 years'. The current "era" started at the stroke of +midnight on 1 Jan 1900, and ends just before the stroke of midnight on +1 Jan 2036. +In the past, we have used the "midpoint" of the range to decide which +era we were in. Given the longevity of some products, it became clear +that it would be more functional to "look back" less, and "look forward" +more. We now compile a timestamp into the ntpd executable and when we +get a timestamp we us the "built-on" to tell us what era we are in. +This check "looks back" 10 years, and "looks forward" 126 years. + +* ntpdc responses disabled by default + +Dave Hart writes: + +For a long time, ntpq and its mostly text-based mode 6 (control) +protocol have been preferred over ntpdc and its mode 7 (private +request) protocol for runtime queries and configuration. There has +been a goal of deprecating ntpdc, previously held back by numerous +capabilities exposed by ntpdc with no ntpq equivalent. I have been +adding commands to ntpq to cover these cases, and I believe I've +covered them all, though I've not compared command-by-command +recently. + +As I've said previously, the binary mode 7 protocol involves a lot of +hand-rolled structure layout and byte-swapping code in both ntpd and +ntpdc which is hard to get right. As ntpd grows and changes, the +changes are difficult to expose via ntpdc while maintaining forward +and backward compatibility between ntpdc and ntpd. In contrast, +ntpq's text-based, label=value approach involves more code reuse and +allows compatible changes without extra work in most cases. + +Mode 7 has always been defined as vendor/implementation-specific while +mode 6 is described in RFC 1305 and intended to be open to interoperate +with other implementations. There is an early draft of an updated +mode 6 description that likely will join the other NTPv4 RFCs +eventually. (http://tools.ietf.org/html/draft-odonoghue-ntpv4-control-01) + +For these reasons, ntpd 4.2.7p230 by default disables processing of +ntpdc queries, reducing ntpd's attack surface and functionally +deprecating ntpdc. If you are in the habit of using ntpdc for certain +operations, please try the ntpq equivalent. If there's no equivalent, +please open a bug report at http://bugs.ntp.org./ + +In addition to the above, over 1100 issues have been resolved between +the 4.2.6 branch and 4.2.8. The ChangeLog file in the distribution +lists these. + +--- +NTP 4.2.6p5 (Harlan Stenn , 2011/12/24) + +Focus: Bug fixes + +Severity: Medium + +This is a recommended upgrade. + +This release updates sys_rootdisp and sys_jitter calculations to match the +RFC specification, fixes a potential IPv6 address matching error for the +"nic" and "interface" configuration directives, suppresses the creation of +extraneous ephemeral associations for certain broadcastclient and +multicastclient configurations, cleans up some ntpq display issues, and +includes improvements to orphan mode, minor bugs fixes and code clean-ups. + +New features / changes in this release: + +ntpd + + * Updated "nic" and "interface" IPv6 address handling to prevent + mismatches with localhost [::1] and wildcard [::] which resulted from + using the address/prefix format (e.g. fe80::/64) + * Fix orphan mode stratum incorrectly counting to infinity + * Orphan parent selection metric updated to includes missing ntohl() + * Non-printable stratum 16 refid no longer sent to ntp + * Duplicate ephemeral associations suppressed for broadcastclient and + multicastclient without broadcastdelay + * Exclude undetermined sys_refid from use in loopback TEST12 + * Exclude MODE_SERVER responses from KoD rate limiting + * Include root delay in clock_update() sys_rootdisp calculations + * get_systime() updated to exclude sys_residual offset (which only + affected bits "below" sys_tick, the precision threshold) + * sys.peer jitter weighting corrected in sys_jitter calculation + +ntpq + + * -n option extended to include the billboard "server" column + * IPv6 addresses in the local column truncated to prevent overruns + +--- +NTP 4.2.6p4 (Harlan Stenn , 2011/09/22) + +Focus: Bug fixes and portability improvements + +Severity: Medium + +This is a recommended upgrade. + +This release includes build infrastructure updates, code +clean-ups, minor bug fixes, fixes for a number of minor +ref-clock issues, and documentation revisions. + +Portability improvements affect AIX, HP-UX, Linux, OS X and 64-bit time_t. + +New features / changes in this release: + +Build system + +* Fix checking for struct rtattr +* Update config.guess and config.sub for AIX +* Upgrade required version of autogen and libopts for building + from our source code repository + +ntpd + +* Back-ported several fixes for Coverity warnings from ntp-dev +* Fix a rare boundary condition in UNLINK_EXPR_SLIST() +* Allow "logconfig =allall" configuration directive +* Bind tentative IPv6 addresses on Linux +* Correct WWVB/Spectracom driver to timestamp CR instead of LF +* Improved tally bit handling to prevent incorrect ntpq peer status reports +* Exclude the Undisciplined Local Clock and ACTS drivers from the initial + candidate list unless they are designated a "prefer peer" +* Prevent the consideration of Undisciplined Local Clock or ACTS drivers for + selection during the 'tos orphanwait' period +* Prefer an Orphan Mode Parent over the Undisciplined Local Clock or ACTS + drivers +* Improved support of the Parse Refclock trusttime flag in Meinberg mode +* Back-port utility routines from ntp-dev: mprintf(), emalloc_zero() +* Added the NTPD_TICKADJ_PPM environment variable for specifying baseline + clock slew on Microsoft Windows +* Code cleanup in libntpq + +ntpdc + +* Fix timerstats reporting + +ntpdate + +* Reduce time required to set clock +* Allow a timeout greater than 2 seconds + +sntp + +* Backward incompatible command-line option change: + -l/--filelog changed -l/--logfile (to be consistent with ntpd) + +Documentation + +* Update html2man. Fix some tags in the .html files +* Distribute ntp-wait.html + +--- +NTP 4.2.6p3 (Harlan Stenn , 2011/01/03) + +Focus: Bug fixes and portability improvements + +Severity: Medium + +This is a recommended upgrade. + +This release includes build infrastructure updates, code +clean-ups, minor bug fixes, fixes for a number of minor +ref-clock issues, and documentation revisions. + +Portability improvements in this release affect AIX, Atari FreeMiNT, +FreeBSD4, Linux and Microsoft Windows. + +New features / changes in this release: + +Build system +* Use lsb_release to get information about Linux distributions. +* 'test' is in /usr/bin (instead of /bin) on some systems. +* Basic sanity checks for the ChangeLog file. +* Source certain build files with ./filename for systems without . in PATH. +* IRIX portability fix. +* Use a single copy of the "libopts" code. +* autogen/libopts upgrade. +* configure.ac m4 quoting cleanup. + +ntpd +* Do not bind to IN6_IFF_ANYCAST addresses. +* Log the reason for exiting under Windows. +* Multicast fixes for Windows. +* Interpolation fixes for Windows. +* IPv4 and IPv6 Multicast fixes. +* Manycast solicitation fixes and general repairs. +* JJY refclock cleanup. +* NMEA refclock improvements. +* Oncore debug message cleanup. +* Palisade refclock now builds under Linux. +* Give RAWDCF more baud rates. +* Support Truetime Satellite clocks under Windows. +* Support Arbiter 1093C Satellite clocks under Windows. +* Make sure that the "filegen" configuration command defaults to "enable". +* Range-check the status codes (plus other cleanup) in the RIPE-NCC driver. +* Prohibit 'includefile' directive in remote configuration command. +* Fix 'nic' interface bindings. +* Fix the way we link with openssl if openssl is installed in the base + system. + +ntp-keygen +* Fix -V coredump. +* OpenSSL version display cleanup. + +ntpdc +* Many counters should be treated as unsigned. + +ntpdate +* Do not ignore replies with equal receive and transmit timestamps. + +ntpq +* libntpq warning cleanup. + +ntpsnmpd +* Correct SNMP type for "precision" and "resolution". +* Update the MIB from the draft version to RFC-5907. + +sntp +* Display timezone offset when showing time for sntp in the local + timezone. +* Pay proper attention to RATE KoD packets. +* Fix a miscalculation of the offset. +* Properly parse empty lines in the key file. +* Logging cleanup. +* Use tv_usec correctly in set_time(). +* Documentation cleanup. + +--- +NTP 4.2.6p2 (Harlan Stenn , 2010/07/08) + +Focus: Bug fixes and portability improvements + +Severity: Medium + +This is a recommended upgrade. + +This release includes build infrastructure updates, code +clean-ups, minor bug fixes, fixes for a number of minor +ref-clock issues, improved KOD handling, OpenSSL related +updates and documentation revisions. + +Portability improvements in this release affect Irix, Linux, +Mac OS, Microsoft Windows, OpenBSD and QNX6 + +New features / changes in this release: + +ntpd +* Range syntax for the trustedkey configuration directive +* Unified IPv4 and IPv6 restrict lists + +ntpdate +* Rate limiting and KOD handling + +ntpsnmpd +* default connection to net-snmpd via a unix-domain socket +* command-line 'socket name' option + +ntpq / ntpdc +* support for the "passwd ..." syntax +* key-type specific password prompts + +sntp +* MD5 authentication of an ntpd +* Broadcast and crypto +* OpenSSL support + +--- +NTP 4.2.6p1 (Harlan Stenn , 2010/04/09) + +Focus: Bug fixes, portability fixes, and documentation improvements + +Severity: Medium + +This is a recommended upgrade. + +--- +NTP 4.2.6 (Harlan Stenn , 2009/12/08) + +Focus: enhancements and bug fixes. + +--- NTP 4.2.4p8 (Harlan Stenn , 2009/12/08) Focus: Security Fixes @@ -31,6 +1320,14 @@ This release fixes the following high-severity vulnerability: THIS IS A STRONGLY RECOMMENDED UPGRADE. +--- +ntpd now syncs to refclocks right away. + +Backward-Incompatible changes: + +ntpd no longer accepts '-v name' or '-V name' to define internal variables. +Use '--var name' or '--dvar name' instead. (Bug 817) + --- NTP 4.2.4p7 (Harlan Stenn , 2009/05/04) diff --git a/contrib/ntp/README.hackers b/contrib/ntp/README.hackers index a33b004e5..dce44821c 100644 --- a/contrib/ntp/README.hackers +++ b/contrib/ntp/README.hackers @@ -9,19 +9,6 @@ The file "dot.emacs" has the emacs C-mode indentation style that Dave likes. --- -NTP4 uses ANSI C. Some folks are blessed with a pre-ansi C compiler. We -support them by using "ansi2knr" in the Makefiles, which is automatically -detected and selected by the configure process. - -For ansi2knr to work, we MUST define functions as follows: - -type stuff -function_name ( actual parameters ) - -While the whitespace is optional, the function name MUST start at column 0. - ---- - We'd like to see *all* system function declarations live in include/l_stdlib.h and NEVER appear in the .c files. diff --git a/contrib/ntp/README.leapsmear b/contrib/ntp/README.leapsmear new file mode 100644 index 000000000..37f1c73a7 --- /dev/null +++ b/contrib/ntp/README.leapsmear @@ -0,0 +1,272 @@ +Leap Second Smearing with NTP +----------------------------- + +By Martin Burnicki +with some edits by Harlan Stenn + +The NTP software protocol and its reference implementation, ntpd, were +originally designed to distribute UTC time over a network as accurately as +possible. + +Unfortunately, leap seconds are scheduled to be inserted into or deleted +from the UTC time scale in irregular intervals to keep the UTC time scale +synchronized with the Earth rotation. Deletions haven't happened, yet, but +insertions have happened over 30 times. + +The problem is that POSIX requires 86400 seconds in a day, and there is no +prescribed way to handle leap seconds in POSIX. + +Whenever a leap second is to be handled ntpd either: + +- passes the leap second announcement down to the OS kernel (if the OS +supports this) and the kernel handles the leap second automatically, or + +- applies the leap second correction itself. + +NTP servers also pass a leap second warning flag down to their clients via +the normal NTP packet exchange, so clients also become aware of an +approaching leap second, and can handle the leap second appropriately. + + +The Problem on Unix-like Systems +-------------------------------- +If a leap second is to be inserted then in most Unix-like systems the OS +kernel just steps the time back by 1 second at the beginning of the leap +second, so the last second of the UTC day is repeated and thus duplicate +timestamps can occur. + +Unfortunately there are lots of applications which get confused it the +system time is stepped back, e.g. due to a leap second insertion. Thus, +many users have been looking for ways to avoid this, and tried to introduce +workarounds which may work properly, or not. + +So even though these Unix kernels normally can handle leap seconds, the way +they do this is not optimal for applications. + +One good way to handle the leap second is to use ntp_gettime() instead of +the usual calls, because ntp_gettime() includes a "clock state" variable +that will actually tell you if the time you are receiving is OK or not, and +if it is OK, if the current second is an in-progress leap second. But even +though this mechanism has been available for about 20 years' time, almost +nobody uses it. + + +NTP Client for Windows Contains a Workaround +-------------------------------------------- +The Windows system time knows nothing about leap seconds, so for many years +the Windows port of ntpd provides a workaround where the system time is +slewed by the client to compensate the leap second. + +Thus it is not required to use a smearing NTP server for Windows clients, +but of course the smearing server approach also works. + + +The Leap Smear Approach +----------------------- +Due to the reasons mentioned above some support for leap smearing has +recently been implemented in ntpd. This means that to insert a leap second +an NTP server adds a certain increasing "smear" offset to the real UTC time +sent to its clients, so that after some predefined interval the leap second +offset is compensated. The smear interval should be long enough, +e.g. several hours, so that NTP clients can easily follow the clock drift +caused by the smeared time. + +During the period while the leap smear is being performed, ntpd will include +a specially-formatted 'refid' in time packets that contain "smeared" time. +This refid is of the form 254.x.y.z, where x.y.z are 24 encoded bits of the +smear value. + +With this approach the time an NTP server sends to its clients still matches +UTC before the leap second, up to the beginning of the smear interval, and +again corresponds to UTC after the insertion of the leap second has +finished, at the end of the smear interval. By examining the first byte of +the refid, one can also determine if the server is offering smeared time or +not. + +Of course, clients which receive the "smeared" time from an NTP server don't +have to (and even must not) care about the leap second anymore. Smearing is +just transparent to the clients, and the clients don't even notice there's a +leap second. + + +Pros and Cons of the Smearing Approach +-------------------------------------- +The disadvantages of this approach are: + +- During the smear interval the time provided by smearing NTP servers +differs significantly from UTC, and thus from the time provided by normal, +non-smearing NTP servers. The difference can be up to 1 second, depending +on the smear algorithm. + +- Since smeared time differs from true UTC, and many applications require +correct legal time (UTC), there may be legal consequences to using smeared +time. Make sure you check to see if this requirement affects you. + +However, for applications where it's only important that all computers have +the same time and a temporary offset of up to 1 s to UTC is acceptable, a +better approach may be to slew the time in a well defined way, over a +certain interval, which is what we call smearing the leap second. + + +The Motivation to Implement Leap Smearing +----------------------------------------- +Here is some historical background for ntpd, related to smearing/slewing +time. + +Up to ntpd 4.2.4, if kernel support for leap seconds was either not +available or was not enabled, ntpd didn't care about the leap second at all. +So if ntpd was run with -x and thus kernel support wasn't used, ntpd saw a +sudden 1 s offset after the leap second and normally would have stepped the +time by -1 s a few minutes later. However, 'ntpd -x' does not step the time +but "slews" the 1-second correction, which takes 33 minutes and 20 seconds +to complete. This could be considered a bug, but certainly this was only an +accidental behavior. + +However, as we learned in the discussion in http://bugs.ntp.org/2745, this +behavior was very much appreciated since indeed the time was never stepped +back, and even though the start of the slewing was somewhat undefined and +depended on the poll interval. The system time was off by 1 second for +several minutes before slewing even started. + +In ntpd 4.2.6 some code was added which let ntpd step the time at UTC +midnight to insert a leap second, if kernel support was not used. +Unfortunately this also happened if ntpd was started with -x, so the folks +who expected that the time was never stepped when ntpd was run with -x found +this wasn't true anymore, and again from the discussion in NTP bug 2745 we +learn that there were even some folks who patched ntpd to get the 4.2.4 +behavior back. + +In 4.2.8 the leap second code was rewritten and some enhancements were +introduced, but the resulting code still showed the behavior of 4.2.6, +i.e. ntpd with -x would still step the time. This has only recently been +fixed in the current ntpd stable code, but this fix is only available with a +certain patch level of ntpd 4.2.8. + +So a possible solution for users who were looking for a way to come over the +leap second without the time being stepped could have been to check the +version of ntpd installed on each of their systems. If it's still 4.2.4 be +sure to start the client ntpd with -x. If it's 4.2.6 or 4.2.8 it won't work +anyway except if you had a patched ntpd version instead of the original +version. So you'd need to upgrade to the current -stable code to be able to +run ntpd with -x and get the desired result, so you'd still have the +requirement to check/update/configure every single machine in your network +that runs ntpd. + +Google's leap smear approach is a very efficient solution for this, for +sites that do not require correct timestamps for legal purposes. You just +have to take care that your NTP servers support leap smearing and configure +those few servers accordingly. If the smear interval is long enough so that +NTP clients can follow the smeared time it doesn't matter at all which +version of ntpd is installed on a client machine, it just works, and it even +works around kernel bugs due to the leap second. + +Since all clients follow the same smeared time the time difference between +the clients during the smear interval is as small as possible, compared to +the -x approach. The current leap second code in ntpd determines the point +in system time when the leap second is to be inserted, and given a +particular smear interval it's easy to determine the start point of the +smearing, and the smearing is finished when the leap second ends, i.e. the +next UTC day begins. + +The maximum error doesn't exceed what you'd get with the old smearing caused +by -x in ntpd 4.2.4, so if users could accept the old behavior they would +even accept the smearing at the server side. + +In order to affect the local timekeeping as little as possible the leap +smear support currently implemented in ntpd does not affect the internal +system time at all. Only the timestamps and refid in outgoing reply packets +*to clients* are modified by the smear offset, so this makes sure the basic +functionality of ntpd is not accidentally broken. Also peer packets +exchanged with other NTP servers are based on the real UTC system time and +the normal refid, as usual. + +The leap smear implementation is optionally available in ntp-4.2.8p3 and +later, and the changes can be tracked via http://bugs.ntp.org/2855. + + +Using NTP's Leap Second Smearing +-------------------------------- +- Leap Second Smearing MUST NOT be used for public servers, e.g. servers +provided by metrology institutes, or servers participating in the NTP pool +project. There would be a high risk that NTP clients get the time from a +mixture of smearing and non-smearing NTP servers which could result in +undefined client behavior. Instead, leap second smearing should only be +configured on time servers providing dedicated clients with time, if all +those clients can accept smeared time. + +- Leap Second Smearing is NOT configured by default. The only way to get +this behavior is to invoke the ./configure script from the NTP source code +package with the --enable-leap-smear parameter before the executables are +built. + +- Even if ntpd has been compiled to enable leap smearing support, leap +smearing is only done if explicitly configured. + +- The leap smear interval should be at least several hours' long, and up to +1 day (86400s). If the interval is too short then the applied smear offset +is applied too quickly for clients to follow. 86400s (1 day) is a good +choice. + +- If several NTP servers are set up for leap smearing then the *same* smear +interval should be configured on each server. + +- Smearing NTP servers DO NOT send a leap second warning flag to client time +requests. Since the leap second is applied gradually the clients don't even +notice there's a leap second being inserted, and thus there will be no log +message or similar related to the leap second be visible on the clients. + +- Since clients don't (and must not) become aware of the leap second at all, +clients getting the time from a smearing NTP server MUST NOT be configured +to use a leap second file. If they had a leap second file they would apply +the leap second twice: the smeared one from the server, plus another one +inserted by themselves due to the leap second file. As a result, the +additional correction would soon be detected and corrected/adjusted. + +- Clients MUST NOT be configured to poll both smearing and non-smearing NTP +servers at the same time. During the smear interval they would get +different times from different servers and wouldn't know which server(s) to +accept. + + +Setting Up A Smearing NTP Server +-------------------------------- +If an NTP server should perform leap smearing then the leap smear interval +(in seconds) needs to be specified in the NTP configuration file ntp.conf, +e.g.: + + leapsmearinterval 86400 + +Please keep in mind the leap smear interval should be between several and 24 +hours' long. With shorter values clients may not be able to follow the +drift caused by the smeared time, and with longer values the discrepancy +between system time and UTC will cause more problems when reconciling +timestamp differences. + +When ntpd starts and a smear interval has been specified then a log message +is generated, e.g.: + + ntpd[31120]: config: leap smear interval 86400 s + +While ntpd is running with a leap smear interval specified the command: + + ntpq -c rv + +reports the smear status, e.g.: + +# ntpq -c rv +associd=0 status=4419 leap_add_sec, sync_uhf_radio, 1 event, leap_armed, +version="ntpd 4.2.8p3-RC1@1.3349-o Mon Jun 22 14:24:09 UTC 2015 (26)", +processor="i586", system="Linux/3.7.1", leap=01, stratum=1, +precision=-18, rootdelay=0.000, rootdisp=1.075, refid=MRS, +reftime=d93dab96.09666671 Tue, Jun 30 2015 23:58:14.036, +clock=d93dab9b.3386a8d5 Tue, Jun 30 2015 23:58:19.201, peer=2335, +tc=3, mintc=3, offset=-0.097015, frequency=44.627, sys_jitter=0.003815, +clk_jitter=0.451, clk_wander=0.035, tai=35, leapsec=201507010000, +expire=201512280000, leapsmearinterval=86400, leapsmearoffset=-932.087 + +In the example above 'leapsmearinterval' reports the configured leap smear +interval all the time, while the 'leapsmearoffset' value is 0 outside the +interval and increases from 0 to -1000 ms over the interval. So this can be +used to monitor if and how the time sent to clients is smeared. With a +leapsmearoffset of -.932087, the refid reported in smeared packets would be +254.196.88.176. diff --git a/contrib/ntp/WHERE-TO-START b/contrib/ntp/WHERE-TO-START index fb96137b0..74d376e43 100644 --- a/contrib/ntp/WHERE-TO-START +++ b/contrib/ntp/WHERE-TO-START @@ -15,7 +15,7 @@ bugfixes and drivers for new and exotic radios, telephones and sundials. This distribution is normally available by anonymous ftp as the compressed tar archive ntp-.tar.gz in the pub/ntp directory on huey.udel.edu and is the version number. The current stable -and development version numbers can be found at . +and development version numbers can be found at . A considerable amount of documentation, including build instructions, configuration advice, program usage and miscellaneous information is @@ -35,7 +35,8 @@ files in the base directory of this distribution is in the README file. A list of "significant" changes for the release is in the NEWS file. If you're interested in helping us test pre-release versions of ntpd, -please look in . +please visit http://support.ntp.org/downloads and look for RC and/or +Development tarballs. David L. Mills (mills@udel.edu) 21 June 1998 diff --git a/contrib/ntp/aclocal.m4 b/contrib/ntp/aclocal.m4 index 69c28495d..0c81f4370 100644 --- a/contrib/ntp/aclocal.m4 +++ b/contrib/ntp/aclocal.m4 @@ -1,6189 +1,145 @@ -# generated automatically by aclocal 1.11 -*- Autoconf -*- +# generated automatically by aclocal 1.15 -*- Autoconf -*- -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],, -[m4_warning([this file was generated for autoconf 2.65. -You have another version of autoconf. It may work, but is not guaranteed to. -If you have problems, you may need to regenerate the build system entirely. -To do so, use the procedure documented by the package, typically `autoreconf'.])]) - -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- - -# serial 47 AC_PROG_LIBTOOL - - -# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) -# ----------------------------------------------------------- -# If this macro is not defined by Autoconf, define it here. -m4_ifdef([AC_PROVIDE_IFELSE], - [], - [m4_define([AC_PROVIDE_IFELSE], - [m4_ifdef([AC_PROVIDE_$1], - [$2], [$3])])]) - - -# AC_PROG_LIBTOOL -# --------------- -AC_DEFUN([AC_PROG_LIBTOOL], -[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl -dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX -dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. - AC_PROVIDE_IFELSE([AC_PROG_CXX], - [AC_LIBTOOL_CXX], - [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX - ])]) -dnl And a similar setup for Fortran 77 support - AC_PROVIDE_IFELSE([AC_PROG_F77], - [AC_LIBTOOL_F77], - [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 -])]) - -dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. -dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run -dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. - AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [ifdef([AC_PROG_GCJ], - [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([A][M_PROG_GCJ], - [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([LT_AC_PROG_GCJ], - [define([LT_AC_PROG_GCJ], - defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) -])])# AC_PROG_LIBTOOL - - -# _AC_PROG_LIBTOOL -# ---------------- -AC_DEFUN([_AC_PROG_LIBTOOL], -[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl -AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl -AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl -AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl - -# Prevent multiple expansion -define([AC_PROG_LIBTOOL], []) -])# _AC_PROG_LIBTOOL - - -# AC_LIBTOOL_SETUP -# ---------------- -AC_DEFUN([AC_LIBTOOL_SETUP], -[AC_PREREQ(2.50)dnl -AC_REQUIRE([AC_ENABLE_SHARED])dnl -AC_REQUIRE([AC_ENABLE_STATIC])dnl -AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_PROG_LD])dnl -AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl -AC_REQUIRE([AC_PROG_NM])dnl - -AC_REQUIRE([AC_PROG_LN_S])dnl -AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl -# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! -AC_REQUIRE([AC_OBJEXT])dnl -AC_REQUIRE([AC_EXEEXT])dnl -dnl - -AC_LIBTOOL_SYS_MAX_CMD_LEN -AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -AC_LIBTOOL_OBJDIR - -AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -_LT_AC_PROG_ECHO_BACKSLASH - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e 1s/^X//' -[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] - -# Same as above, but do not quote variable references. -[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -# Constants: -rm="rm -f" - -# Global variables: -default_ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a -ltmain="$ac_aux_dir/ltmain.sh" -ofile="$default_ofile" -with_gnu_ld="$lt_cv_prog_gnu_ld" - -AC_CHECK_TOOL(AR, ar, false) -AC_CHECK_TOOL(RANLIB, ranlib, :) -AC_CHECK_TOOL(STRIP, strip, :) - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru -test -z "$AS" && AS=as -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$LD" && LD=ld -test -z "$LN_S" && LN_S="ln -s" -test -z "$MAGIC_CMD" && MAGIC_CMD=file -test -z "$NM" && NM=nm -test -z "$SED" && SED=sed -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$RANLIB" && RANLIB=: -test -z "$STRIP" && STRIP=: -test -z "$ac_objext" && ac_objext=o - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" - ;; - *) - old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" -fi - -_LT_CC_BASENAME([$compiler]) - -# Only perform the check for file, if the check method requires it -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - AC_PATH_MAGIC - fi - ;; -esac - -AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) -AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], -enable_win32_dll=yes, enable_win32_dll=no) - -AC_ARG_ENABLE([libtool-lock], - [AC_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -AC_ARG_WITH([pic], - [AC_HELP_STRING([--with-pic], - [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], - [pic_mode="$withval"], - [pic_mode=default]) -test -z "$pic_mode" && pic_mode=default - -# Use C for the default configuration in the libtool script -tagname= -AC_LIBTOOL_LANG_C_CONFIG -_LT_AC_TAGCONFIG -])# AC_LIBTOOL_SETUP - - -# _LT_AC_SYS_COMPILER -# ------------------- -AC_DEFUN([_LT_AC_SYS_COMPILER], -[AC_REQUIRE([AC_PROG_CC])dnl - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_AC_SYS_COMPILER - - -# _LT_CC_BASENAME(CC) -# ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -AC_DEFUN([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -]) - - -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -AC_DEFUN([_LT_COMPILER_BOILERPLATE], -[ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* -])# _LT_COMPILER_BOILERPLATE - - -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -AC_DEFUN([_LT_LINKER_BOILERPLATE], -[ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* -])# _LT_LINKER_BOILERPLATE - - -# _LT_AC_SYS_LIBPATH_AIX -# ---------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], -[AC_LINK_IFELSE(AC_LANG_PROGRAM,[ -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi],[]) -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -])# _LT_AC_SYS_LIBPATH_AIX - - -# _LT_AC_SHELL_INIT(ARG) -# ---------------------- -AC_DEFUN([_LT_AC_SHELL_INIT], -[ifdef([AC_DIVERSION_NOTICE], - [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], - [AC_DIVERT_PUSH(NOTICE)]) -$1 -AC_DIVERT_POP -])# _LT_AC_SHELL_INIT - - -# _LT_AC_PROG_ECHO_BACKSLASH -# -------------------------- -# Add some code to the start of the generated configure script which -# will find an echo command which doesn't interpret backslashes. -AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], -[_LT_AC_SHELL_INIT([ -# Check that we are running under the correct shell. -SHELL=${CONFIG_SHELL-/bin/sh} - -case X$ECHO in -X*--fallback-echo) - # Remove one level of quotation (which was required for Make). - ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` - ;; -esac - -echo=${ECHO-echo} -if test "X[$]1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X[$]1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then - # Yippee, $echo works! - : -else - # Restart under the correct shell. - exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} -fi - -if test "X[$]1" = X--fallback-echo; then - # used as fallback echo - shift - cat </dev/null 2>&1 && unset CDPATH - -if test -z "$ECHO"; then -if test "X${echo_test_string+set}" != Xset; then -# find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if (echo_test_string=`eval $cmd`) 2>/dev/null && - echo_test_string=`eval $cmd` && - (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null - then - break - fi - done -fi - -if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : -else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. - - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for dir in $PATH /usr/ucb; do - IFS="$lt_save_ifs" - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$dir/echo" - break - fi - done - IFS="$lt_save_ifs" - - if test "X$echo" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - echo='print -r' - elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running configure again with it. - ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} - else - # Try using printf. - echo='printf %s\n' - if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # Cool, printf works - : - elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - echo="$CONFIG_SHELL [$]0 --fallback-echo" - elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$CONFIG_SHELL [$]0 --fallback-echo" - else - # maybe with a smaller string... - prev=: - - for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do - if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null - then - break - fi - prev="$cmd" - done - - if test "$prev" != 'sed 50q "[$]0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} - else - # Oops. We lost completely, so just stick with echo. - echo=echo - fi - fi - fi - fi -fi -fi - -# Copy echo and quote the copy suitably for passing to libtool from -# the Makefile, instead of quoting the original, which is used later. -ECHO=$echo -if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then - ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" -fi - -AC_SUBST(ECHO) -])])# _LT_AC_PROG_ECHO_BACKSLASH - - -# _LT_AC_LOCK -# ----------- -AC_DEFUN([_LT_AC_LOCK], -[AC_ARG_ENABLE([libtool-lock], - [AC_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '[#]line __oline__ "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], -[*-*-cygwin* | *-*-mingw* | *-*-pw32*) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; - ]) -esac - -need_locks="$enable_libtool_lock" - -])# _LT_AC_LOCK - - -# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], -[AC_REQUIRE([LT_AC_PROG_SED]) -AC_CACHE_CHECK([$1], [$2], - [$2=no - ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $rm conftest* -]) - -if test x"[$]$2" = xyes; then - ifelse([$5], , :, [$5]) -else - ifelse([$6], , :, [$6]) -fi -])# AC_LIBTOOL_COMPILER_OPTION - - -# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ------------------------------------------------------------ -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], -[AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $3" - printf "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $rm conftest* - LDFLAGS="$save_LDFLAGS" -]) - -if test x"[$]$2" = xyes; then - ifelse([$4], , :, [$4]) -else - ifelse([$5], , :, [$5]) -fi -])# AC_LIBTOOL_LINKER_OPTION - - -# AC_LIBTOOL_SYS_MAX_CMD_LEN -# -------------------------- -AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], -[# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - *) - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ - = "XX$teststring") >/dev/null 2>&1 && - new_result=`expr "X$teststring" : ".*" 2>&1` && - lt_cv_sys_max_cmd_len=$new_result && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - teststring= - # Add a significant safety factor because C++ compilers can tack on massive - # amounts of additional arguments before passing them to the linker. - # It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - ;; - esac -]) -if test -n $lt_cv_sys_max_cmd_len ; then - AC_MSG_RESULT($lt_cv_sys_max_cmd_len) -else - AC_MSG_RESULT(none) -fi -])# AC_LIBTOOL_SYS_MAX_CMD_LEN - - -# _LT_AC_CHECK_DLFCN -# -------------------- -AC_DEFUN([_LT_AC_CHECK_DLFCN], -[AC_CHECK_HEADERS(dlfcn.h)dnl -])# _LT_AC_CHECK_DLFCN - - -# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, -# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) -# ------------------------------------------------------------------ -AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], -[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl -if test "$cross_compiling" = yes; then : - [$4] -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -#ifdef __cplusplus -extern "C" void exit (int); -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - - exit (status); -}] -EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_unknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi -fi -rm -fr conftest* -])# _LT_AC_TRY_DLOPEN_SELF - - -# AC_LIBTOOL_DLOPEN_SELF -# ------------------- -AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], -[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ]) - ;; - - *) - AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], - [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"], - [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], - [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], - [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], - [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"]) - ]) - ]) - ]) - ]) - ]) - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - AC_CACHE_CHECK([whether a program can dlopen itself], - lt_cv_dlopen_self, [dnl - _LT_AC_TRY_DLOPEN_SELF( - lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, - lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) - ]) - - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_AC_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi -])# AC_LIBTOOL_DLOPEN_SELF - - -# AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) -# --------------------------------- -# Check to see if options -c and -o are simultaneously supported by compiler -AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], -[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . 2>&AS_MESSAGE_LOG_FD - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* -]) -])# AC_LIBTOOL_PROG_CC_C_O - - -# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) -# ----------------------------------------- -# Check to see if we can do hard links to lock some files if needed -AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], -[AC_REQUIRE([_LT_AC_LOCK])dnl - -hard_links="nottested" -if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - AC_MSG_CHECKING([if we can lock with hard links]) - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) - need_locks=warn - fi -else - need_locks=no -fi -])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS - - -# AC_LIBTOOL_OBJDIR -# ----------------- -AC_DEFUN([AC_LIBTOOL_OBJDIR], -[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], -[rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null]) -objdir=$lt_cv_objdir -])# AC_LIBTOOL_OBJDIR - - -# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) -# ---------------------------------------------- -# Check hardcoding attributes. -AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], -[AC_MSG_CHECKING([how to hardcode library paths into programs]) -_LT_AC_TAGVAR(hardcode_action, $1)= -if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ - test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \ - test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then - - # We can hardcode non-existant directories. - if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then - # Linking always hardcodes the temporary library directory. - _LT_AC_TAGVAR(hardcode_action, $1)=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - _LT_AC_TAGVAR(hardcode_action, $1)=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - _LT_AC_TAGVAR(hardcode_action, $1)=unsupported -fi -AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) - -if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi -])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH - - -# AC_LIBTOOL_SYS_LIB_STRIP -# ------------------------ -AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], -[striplib= -old_striplib= -AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) -fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac -fi -])# AC_LIBTOOL_SYS_LIB_STRIP - - -# AC_LIBTOOL_SYS_DYNAMIC_LINKER -# ----------------------------- -# PORTME Fill in your ld.so characteristics -AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], -[AC_MSG_CHECKING([dynamic linker characteristics]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[[45]]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; - - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd1*) - dynamic_linker=no - ;; - -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[[123]]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[[01]]* | freebsdelf3.[[01]]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - esac - ;; - -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; - -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no -])# AC_LIBTOOL_SYS_DYNAMIC_LINKER - - -# _LT_AC_TAGCONFIG -# ---------------- -AC_DEFUN([_LT_AC_TAGCONFIG], -[AC_ARG_WITH([tags], - [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], - [include additional configurations @<:@automatic@:>@])], - [tagnames="$withval"]) - -if test -f "$ltmain" && test -n "$tagnames"; then - if test ! -f "${ofile}"; then - AC_MSG_WARN([output file `$ofile' does not exist]) - fi - - if test -z "$LTCC"; then - eval "`$SHELL ${ofile} --config | grep '^LTCC='`" - if test -z "$LTCC"; then - AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) - else - AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) - fi - fi - - # Extract list of available tagged configurations in $ofile. - # Note that this assumes the entire list is on one line. - available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` - - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for tagname in $tagnames; do - IFS="$lt_save_ifs" - # Check whether tagname contains only valid characters - case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in - "") ;; - *) AC_MSG_ERROR([invalid tag name: $tagname]) - ;; - esac - - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null - then - AC_MSG_ERROR([tag name \"$tagname\" already exists]) - fi - - # Update the list of available tags. - if test -n "$tagname"; then - echo appending configuration tag \"$tagname\" to $ofile - - case $tagname in - CXX) - if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_LIBTOOL_LANG_CXX_CONFIG - else - tagname="" - fi - ;; - - F77) - if test -n "$F77" && test "X$F77" != "Xno"; then - AC_LIBTOOL_LANG_F77_CONFIG - else - tagname="" - fi - ;; - - GCJ) - if test -n "$GCJ" && test "X$GCJ" != "Xno"; then - AC_LIBTOOL_LANG_GCJ_CONFIG - else - tagname="" - fi - ;; - - RC) - AC_LIBTOOL_LANG_RC_CONFIG - ;; - - *) - AC_MSG_ERROR([Unsupported tag name: $tagname]) - ;; - esac - - # Append the new tag name to the list of available tags. - if test -n "$tagname" ; then - available_tags="$available_tags $tagname" - fi - fi - done - IFS="$lt_save_ifs" - - # Now substitute the updated list of available tags. - if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then - mv "${ofile}T" "$ofile" - chmod +x "$ofile" - else - rm -f "${ofile}T" - AC_MSG_ERROR([unable to update list of available tagged configurations.]) - fi -fi -])# _LT_AC_TAGCONFIG - - -# AC_LIBTOOL_DLOPEN -# ----------------- -# enable checks for dlopen support -AC_DEFUN([AC_LIBTOOL_DLOPEN], - [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) -])# AC_LIBTOOL_DLOPEN - - -# AC_LIBTOOL_WIN32_DLL -# -------------------- -# declare package support for building win32 DLLs -AC_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) -])# AC_LIBTOOL_WIN32_DLL - - -# AC_ENABLE_SHARED([DEFAULT]) -# --------------------------- -# implement the --enable-shared flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_SHARED], -[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([shared], - [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_shared=]AC_ENABLE_SHARED_DEFAULT) -])# AC_ENABLE_SHARED - - -# AC_DISABLE_SHARED -# ----------------- -#- set the default shared flag to --disable-shared -AC_DEFUN([AC_DISABLE_SHARED], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_SHARED(no) -])# AC_DISABLE_SHARED - - -# AC_ENABLE_STATIC([DEFAULT]) -# --------------------------- -# implement the --enable-static flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_STATIC], -[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([static], - [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@], - [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_static=]AC_ENABLE_STATIC_DEFAULT) -])# AC_ENABLE_STATIC - - -# AC_DISABLE_STATIC -# ----------------- -# set the default static flag to --disable-static -AC_DEFUN([AC_DISABLE_STATIC], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_STATIC(no) -])# AC_DISABLE_STATIC - - -# AC_ENABLE_FAST_INSTALL([DEFAULT]) -# --------------------------------- -# implement the --enable-fast-install flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_FAST_INSTALL], -[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([fast-install], - [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], - [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) -])# AC_ENABLE_FAST_INSTALL - - -# AC_DISABLE_FAST_INSTALL -# ----------------------- -# set the default to --disable-fast-install -AC_DEFUN([AC_DISABLE_FAST_INSTALL], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_FAST_INSTALL(no) -])# AC_DISABLE_FAST_INSTALL - - -# AC_LIBTOOL_PICMODE([MODE]) -# -------------------------- -# implement the --with-pic flag -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. -AC_DEFUN([AC_LIBTOOL_PICMODE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -pic_mode=ifelse($#,1,$1,default) -])# AC_LIBTOOL_PICMODE - - -# AC_PROG_EGREP -# ------------- -# This is predefined starting with Autoconf 2.54, so this conditional -# definition can be removed once we require Autoconf 2.54 or later. -m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], -[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], - [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 - then ac_cv_prog_egrep='grep -E' - else ac_cv_prog_egrep='egrep' - fi]) - EGREP=$ac_cv_prog_egrep - AC_SUBST([EGREP]) -])]) - - -# AC_PATH_TOOL_PREFIX -# ------------------- -# find a file program which can recognise shared library -AC_DEFUN([AC_PATH_TOOL_PREFIX], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, -[case $MAGIC_CMD in -[[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR -dnl $ac_dummy forces splitting on constant user-supplied paths. -dnl POSIX.2 word splitting is done only on the output of word expansions, -dnl not every word. This closes a longstanding sh security hole. - ac_dummy="ifelse([$2], , $PATH, [$2])" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - AC_MSG_RESULT($MAGIC_CMD) -else - AC_MSG_RESULT(no) -fi -])# AC_PATH_TOOL_PREFIX - - -# AC_PATH_MAGIC -# ------------- -# find a file program which can recognise a shared library -AC_DEFUN([AC_PATH_MAGIC], -[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi -fi -])# AC_PATH_MAGIC - - -# AC_PROG_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([AC_PROG_LD], -[AC_ARG_WITH([gnu-ld], - [AC_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], - [with_gnu_ld=no]) -AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - AC_MSG_CHECKING([for GNU ld]) -else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &1 /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be Linux ELF. -linux*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -nto-qnx*) - lt_cv_deplibs_check_method=unknown - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -sco3.2v5*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown -])# AC_DEPLIBS_CHECK_METHOD - - -# AC_PROG_NM -# ---------- -# find the pathname to a BSD-compatible name lister -AC_DEFUN([AC_PROG_NM], -[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/${ac_tool_prefix}nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - esac - fi - done - IFS="$lt_save_ifs" - test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm -fi]) -NM="$lt_cv_path_NM" -])# AC_PROG_NM - - -# AC_CHECK_LIBM -# ------------- -# check for math library -AC_DEFUN([AC_CHECK_LIBM], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -LIBM= -case $host in -*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) - # These system don't have libm, or don't need it - ;; -*-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") - AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") - ;; -*) - AC_CHECK_LIB(m, cos, LIBM="-lm") - ;; -esac -])# AC_CHECK_LIBM - - -# AC_LIBLTDL_CONVENIENCE([DIRECTORY]) -# ----------------------------------- -# sets LIBLTDL to the link flags for the libltdl convenience library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-convenience to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, -# it is assumed to be `libltdl'. LIBLTDL will be prefixed with -# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/' -# (note the single quotes!). If your package is not flat and you're not -# using automake, define top_builddir and top_srcdir appropriately in -# the Makefiles. -AC_DEFUN([AC_LIBLTDL_CONVENIENCE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - case $enable_ltdl_convenience in - no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; - "") enable_ltdl_convenience=yes - ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; - esac - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_CONVENIENCE - - -# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) -# ----------------------------------- -# sets LIBLTDL to the link flags for the libltdl installable library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-install to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, -# and an installed libltdl is not found, it is assumed to be `libltdl'. -# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with -# '${top_srcdir}/' (note the single quotes!). If your package is not -# flat and you're not using automake, define top_builddir and top_srcdir -# appropriately in the Makefiles. -# In the future, this macro may have to be called after AC_PROG_LIBTOOL. -AC_DEFUN([AC_LIBLTDL_INSTALLABLE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - AC_CHECK_LIB(ltdl, lt_dlinit, - [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], - [if test x"$enable_ltdl_install" = xno; then - AC_MSG_WARN([libltdl not installed, but installation disabled]) - else - enable_ltdl_install=yes - fi - ]) - if test x"$enable_ltdl_install" = x"yes"; then - ac_configure_args="$ac_configure_args --enable-ltdl-install" - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - else - ac_configure_args="$ac_configure_args --enable-ltdl-install=no" - LIBLTDL="-lltdl" - LTDLINCL= - fi - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_INSTALLABLE - - -# AC_LIBTOOL_CXX -# -------------- -# enable support for C++ libraries -AC_DEFUN([AC_LIBTOOL_CXX], -[AC_REQUIRE([_LT_AC_LANG_CXX]) -])# AC_LIBTOOL_CXX - - -# _LT_AC_LANG_CXX -# --------------- -AC_DEFUN([_LT_AC_LANG_CXX], -[AC_REQUIRE([AC_PROG_CXX]) -AC_REQUIRE([_LT_AC_PROG_CXXCPP]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) -])# _LT_AC_LANG_CXX - -# _LT_AC_PROG_CXXCPP -# --------------- -AC_DEFUN([_LT_AC_PROG_CXXCPP], -[ -AC_REQUIRE([AC_PROG_CXX]) -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_PROG_CXXCPP -fi -])# _LT_AC_PROG_CXXCPP - -# AC_LIBTOOL_F77 -# -------------- -# enable support for Fortran 77 libraries -AC_DEFUN([AC_LIBTOOL_F77], -[AC_REQUIRE([_LT_AC_LANG_F77]) -])# AC_LIBTOOL_F77 - - -# _LT_AC_LANG_F77 -# --------------- -AC_DEFUN([_LT_AC_LANG_F77], -[AC_REQUIRE([AC_PROG_F77]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77]) -])# _LT_AC_LANG_F77 - - -# AC_LIBTOOL_GCJ -# -------------- -# enable support for GCJ libraries -AC_DEFUN([AC_LIBTOOL_GCJ], -[AC_REQUIRE([_LT_AC_LANG_GCJ]) -])# AC_LIBTOOL_GCJ - - -# _LT_AC_LANG_GCJ -# --------------- -AC_DEFUN([_LT_AC_LANG_GCJ], -[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], - [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], - [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], - [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], - [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ]) -])# _LT_AC_LANG_GCJ - - -# AC_LIBTOOL_RC -# -------------- -# enable support for Windows resource files -AC_DEFUN([AC_LIBTOOL_RC], -[AC_REQUIRE([LT_AC_PROG_RC]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC]) -])# AC_LIBTOOL_RC - - -# AC_LIBTOOL_LANG_C_CONFIG -# ------------------------ -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) -AC_DEFUN([_LT_AC_LANG_C_CONFIG], -[lt_save_CC="$CC" -AC_LANG_PUSH(C) - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}\n' - -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# -# Check for any special shared library compilation flags. -# -_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)= -if test "$GCC" = no; then - case $host_os in - sco3.2v5*) - _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf' - ;; - esac -fi -if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then - AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries]) - if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ ]]" >/dev/null; then : - else - AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure]) - _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no - fi -fi - - -# -# Check to make sure the static flag actually works. -# -AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works], - _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1), - $_LT_AC_TAGVAR(lt_prog_compiler_static, $1), - [], - [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) - - -AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF($1) - -# Report which librarie types wil actually be built -AC_MSG_CHECKING([if libtool supports shared libraries]) -AC_MSG_RESULT([$can_build_shared]) - -AC_MSG_CHECKING([whether to build shared libraries]) -test "$can_build_shared" = "no" && enable_shared=no - -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case $host_os in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - -aix4* | aix5*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -AC_MSG_RESULT([$enable_shared]) - -AC_MSG_CHECKING([whether to build static libraries]) -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -AC_MSG_RESULT([$enable_static]) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_C_CONFIG - - -# AC_LIBTOOL_LANG_CXX_CONFIG -# -------------------------- -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) -AC_DEFUN([_LT_AC_LANG_CXX_CONFIG], -[AC_LANG_PUSH(C++) -AC_REQUIRE([AC_PROG_CXX]) -AC_REQUIRE([_LT_AC_PROG_CXXCPP]) - -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_AC_TAGVAR(allow_undefined_flag, $1)= -_LT_AC_TAGVAR(always_export_symbols, $1)=no -_LT_AC_TAGVAR(archive_expsym_cmds, $1)= -_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_direct, $1)=no -_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= -_LT_AC_TAGVAR(hardcode_minus_L, $1)=no -_LT_AC_TAGVAR(hardcode_automatic, $1)=no -_LT_AC_TAGVAR(module_cmds, $1)= -_LT_AC_TAGVAR(module_expsym_cmds, $1)= -_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_AC_TAGVAR(no_undefined_flag, $1)= -_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= -_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Dependencies to place before and after the object being linked: -_LT_AC_TAGVAR(predep_objects, $1)= -_LT_AC_TAGVAR(postdep_objects, $1)= -_LT_AC_TAGVAR(predeps, $1)= -_LT_AC_TAGVAR(postdeps, $1)= -_LT_AC_TAGVAR(compiler_lib_search_path, $1)= - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_LD=$LD -lt_save_GCC=$GCC -GCC=$GXX -lt_save_with_gnu_ld=$with_gnu_ld -lt_save_path_LD=$lt_cv_path_LD -if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx -else - unset lt_cv_prog_gnu_ld -fi -if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX -else - unset lt_cv_path_LD -fi -test -z "${LDCXX+set}" || LD=$LDCXX -CC=${CXX-"c++"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -# We don't want -fno-exception wen compiling C++ code, so set the -# no_builtin_flag separately -if test "$GXX" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' -else - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= -fi - -if test "$GXX" = yes; then - # Set up default GNU C++ configuration - - AC_PROG_LD - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='${wl}' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ - grep 'no-whole-archive' > /dev/null; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - -else - GXX=no - with_gnu_ld=no - wlarc= -fi - -# PORTME: fill in a description of your system's C++ link characteristics -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -_LT_AC_TAGVAR(ld_shlibs, $1)=yes -case $host_os in - aix3*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_AC_TAGVAR(archive_cmds, $1)='' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GXX" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GXX" = yes ; then - lt_int_apple_cc_single_mod=no - output_verbose_link_cmd='echo' - if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then - lt_int_apple_cc_single_mod=yes - fi - if test "X$lt_int_apple_cc_single_mod" = Xyes ; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - fi - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - if test "X$lt_int_apple_cc_single_mod" = Xyes ; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - freebsd[[12]]*) - # C++ shared libraries reported to be fairly broken before switch to ELF - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - freebsd-elf*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - freebsd* | kfreebsd*-gnu | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - ;; - gnu*) - ;; - hpux9*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - ;; - *) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - esac - fi - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - *) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case $host_cpu in - ia64*|hppa*64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' - fi - fi - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - linux*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc*) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC*) - # Portland Group C++ compiler - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - ;; - cxx*) - # Compaq C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' - - runpath_var=LD_RUN_PATH - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - esac - ;; - lynxos*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - m88k*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - openbsd2*) - # C++ shared libraries are fairly broken - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - openbsd*) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd='echo' - ;; - osf3*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ - $rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - psos*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - sco*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The C++ compiler is used as linker so we must use $wl - # flag to pass the commands to the underlying system - # linker. We must also pass each convience library through - # to the system linker between allextract/defaultextract. - # The C++ compiler will combine linker options so we - # cannot just pass the convience library names through - # without $wl. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' - ;; - esac - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - output_verbose_link_cmd='echo' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' - if $CC --version | grep -v '^2\.7' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" - else - # g++ 2.7 appears to require `-G' NOT `-shared' on this - # platform. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" - fi - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' - fi - ;; - esac - ;; - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - vxworks*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; -esac -AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -_LT_AC_TAGVAR(GCC, $1)="$GXX" -_LT_AC_TAGVAR(LD, $1)="$LD" - -AC_LIBTOOL_POSTDEP_PREDEP($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF($1) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC=$lt_save_CC -LDCXX=$LD -LD=$lt_save_LD -GCC=$lt_save_GCC -with_gnu_ldcxx=$with_gnu_ld -with_gnu_ld=$lt_save_with_gnu_ld -lt_cv_path_LDCXX=$lt_cv_path_LD -lt_cv_path_LD=$lt_save_path_LD -lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld -lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -])# AC_LIBTOOL_LANG_CXX_CONFIG - -# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) -# ------------------------ -# Figure out "hidden" library dependencies from verbose -# compiler output when linking a shared library. -# Parse the compiler output and extract the necessary -# objects, libraries and library flags. -AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[ -dnl we can't use the lt_simple_compile_test_code here, -dnl because it contains code intended for an executable, -dnl not a library. It's possible we should let each -dnl tag define a new lt_????_link_test_code variable, -dnl but it's only used here... -ifelse([$1],[],[cat > conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext <> "$cfgfile" -ifelse([$1], [], -[#! $SHELL - -# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -# Free Software Foundation, Inc. -# -# This file is part of GNU Libtool: -# Originally by Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="$SED -e 1s/^X//" - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# The names of the tagged configurations supported by this script. -available_tags= - -# ### BEGIN LIBTOOL CONFIG], -[# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) - -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) - -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# An echo program that does not interpret backslashes. -echo=$lt_echo - -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS - -# A C compiler. -LTCC=$lt_LTCC - -# A language-specific compiler. -CC=$lt_[]_LT_AC_TAGVAR(compiler, $1) - -# Is the compiler the GNU C compiler? -with_gcc=$_LT_AC_TAGVAR(GCC, $1) - -# An ERE matcher. -EGREP=$lt_EGREP - -# The linker used to build libraries. -LD=$lt_[]_LT_AC_TAGVAR(LD, $1) - -# Whether we need hard or soft links. -LN_S=$lt_LN_S - -# A BSD-compatible nm program. -NM=$lt_NM - -# A symbol stripping program -STRIP=$lt_STRIP - -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD - -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" - -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" - -# Used on cygwin: assembler. -AS="$AS" - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds - -# How to pass a linker flag through the compiler. -wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) - -# Object file suffix (normally "o"). -objext="$ac_objext" - -# Old archive suffix (normally "a"). -libext="$libext" - -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' - -# Executable file suffix (normally ""). -exeext="$exeext" - -# Additional compiler flags for building library objects. -pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) -pic_mode=$pic_mode - -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) - -# Must we lock files when doing compilation? -need_locks=$lt_need_locks - -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Whether dlopen is supported. -dlopen_support=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) - -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) - -# Library versioning type. -version_type=$version_type - -# Format of library name prefix. -libname_spec=$lt_libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec - -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) - -# Commands used to build and install a shared archive. -archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) -archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds - -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) -module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) - -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib - -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) - -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) - -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) - -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) - -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method - -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) - -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds - -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl - -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - -# This is the shared library runtime path variable. -runpath_var=$runpath_var - -# This is the shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# How to hardcode a shared library path into an executable. -hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) - -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) - -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) - -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) - -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) - -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) - -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) - -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) - -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)" - -# Set to yes if exported symbols are required. -always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) - -# The commands to list exported symbols. -export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) - -# Symbols that must always be exported. -include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) - -ifelse([$1],[], -[# ### END LIBTOOL CONFIG], -[# ### END LIBTOOL TAG CONFIG: $tagname]) - -__EOF__ - -ifelse([$1],[], [ - case $host_os in - aix3*) - cat <<\EOF >> "$cfgfile" - -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -EOF - ;; - esac - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || \ - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" -]) -else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi -])# AC_LIBTOOL_CONFIG - - -# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) -# ------------------------------------------- -AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], -[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl - -_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - -if test "$GCC" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' - - AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], - lt_cv_prog_compiler_rtti_exceptions, - [-fno-rtti -fno-exceptions], [], - [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) -fi -])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI - - -# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -# --------------------------------- -AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], -[AC_REQUIRE([AC_CANONICAL_HOST]) -AC_REQUIRE([AC_PROG_NM]) -AC_REQUIRE([AC_OBJEXT]) -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[[BCDEGRST]]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' - -# Transform an extracted symbol line into a proper C declaration -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[[BCDT]]' - ;; -cygwin* | mingw* | pw32*) - symcode='[[ABCDGISTW]]' - ;; -hpux*) # Its linker distinguishes data from code symbols - if test "$host_cpu" = ia64; then - symcode='[[ABCDEGRST]]' - fi - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - ;; -linux*) - if test "$host_cpu" = ia64; then - symcode='[[ABCDGIRSTW]]' - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris* | sysv5*) - symcode='[[BDRT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext < $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if grep ' nm_test_var$' "$nlist" >/dev/null; then - if grep ' nm_test_func$' "$nlist" >/dev/null; then - cat < conftest.$ac_ext -#ifdef __cplusplus -extern "C" { -#endif - -EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' - - cat <> conftest.$ac_ext -#if defined (__STDC__) && __STDC__ -# define lt_ptr_t void * -#else -# define lt_ptr_t char * -# define const -#endif - -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - lt_ptr_t address; -} -lt_preloaded_symbols[[]] = -{ -EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext - cat <<\EOF >> conftest.$ac_ext - {0, (lt_ptr_t) 0} -}; - -#ifdef __cplusplus -} -#endif -EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" - else - echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.$ac_ext >&5 - fi - rm -f conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done -]) -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - AC_MSG_RESULT(failed) -else - AC_MSG_RESULT(ok) -fi -]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE - - -# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) -# --------------------------------------- -AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], -[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= -_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= -_LT_AC_TAGVAR(lt_prog_compiler_static, $1)= - -AC_MSG_CHECKING([for $compiler option to produce PIC]) - ifelse([$1],[CXX],[ - # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | os2* | pw32*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - case $host_os in - aix4* | aix5*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" - ;; - esac - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | kfreebsd*-gnu | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - icpc* | ecpc*) - # Intel C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC*) - # Portland Group C++ compiler. - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd*) - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - sco*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - *) - ;; - esac - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - unixware*) - ;; - vxworks*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - if test "$GCC" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - enable_shared=no - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - - hpux9* | hpux10* | hpux11*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC (with -KPIC) is the default. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - newsos6) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - linux*) - case $cc_basename in - icc* | ecc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - ccc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - esac - ;; - - osf3* | osf4* | osf5*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All OSF/1 code is PIC. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - sco3.2v5*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn' - ;; - - solaris*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; - - sunos4*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - unicos*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - - uts4*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *) - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -]) -AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then - AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], - _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1), - [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" - ;; -esac -]) - - -# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) -# ------------------------------------ -# See if the linker supports building shared libraries. -AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], -[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -ifelse([$1],[CXX],[ - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - case $host_os in - aix4* | aix5*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - ;; - pw32*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" - ;; - cygwin* | mingw*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' - ;; - *) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac -],[ - runpath_var= - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)= - _LT_AC_TAGVAR(archive_expsym_cmds, $1)= - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_minus_L, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown - _LT_AC_TAGVAR(hardcode_automatic, $1)=no - _LT_AC_TAGVAR(module_cmds, $1)= - _LT_AC_TAGVAR(module_expsym_cmds, $1)= - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_AC_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - _LT_CC_BASENAME([$compiler]) - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac - - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <&2 - -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. - -EOF - fi - ;; - - amigaos*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test $supports_anon_versioning = yes; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - sunos4*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - - if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then - runpath_var= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; - - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_AC_TAGVAR(archive_cmds, $1)='' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GCC" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - amigaos*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - # see comment about different semantics on the GNU ld section - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - bsdi[[45]]*) - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic - ;; - - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' - # FIXME: Should let the user specify the lib program. - _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs' - _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - ;; - - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - dgux*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - freebsd1*) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - hpux9*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - ;; - *) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - newsos6) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - openbsd*) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac - fi - ;; +# Copyright (C) 1996-2014 Free Software Foundation, Inc. - os2*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - else - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' - - # Both c and cxx compiler support -rpath directly - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - fi - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - sco3.2v5*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; - - solaris*) - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; - *) - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4) - case $host_vendor in - sni) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' - _LT_AC_TAGVAR(hardcode_direct, $1)=no - ;; - motorola) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4.3*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - fi - ;; +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. - sysv4.2uw2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) - _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text' - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, +[m4_warning([this file was generated for autoconf 2.69. +You have another version of autoconf. It may work, but is not guaranteed to. +If you have problems, you may need to regenerate the build system entirely. +To do so, use the procedure documented by the package, typically 'autoreconf'.])]) - sysv5*) - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - ;; +# serial 9 -*- Autoconf -*- +# Enable extensions on systems that normally disable them. - uts4*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +# Copyright (C) 2003, 2006-2010 Free Software Foundation, Inc. +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac +# This definition of AC_USE_SYSTEM_EXTENSIONS is stolen from CVS +# Autoconf. Perhaps we can remove this once we can assume Autoconf +# 2.62 or later everywhere, but since CVS Autoconf mutates rapidly +# enough in this area it's likely we'll need to redefine +# AC_USE_SYSTEM_EXTENSIONS for quite some time. + +# If autoconf reports a warning +# warning: AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS +# or warning: AC_RUN_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS +# the fix is +# 1) to ensure that AC_USE_SYSTEM_EXTENSIONS is never directly invoked +# but always AC_REQUIREd, +# 2) to ensure that for each occurrence of +# AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS]) +# or +# AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) +# the corresponding gnulib module description has 'extensions' among +# its dependencies. This will ensure that the gl_USE_SYSTEM_EXTENSIONS +# invocation occurs in gl_EARLY, not in gl_INIT. + +# AC_USE_SYSTEM_EXTENSIONS +# ------------------------ +# Enable extensions on systems that normally disable them, +# typically due to standards-conformance issues. +# Remember that #undef in AH_VERBATIM gets replaced with #define by +# AC_DEFINE. The goal here is to define all known feature-enabling +# macros, then, if reports of conflicts are made, disable macros that +# cause problems on some platforms (such as __EXTENSIONS__). +AC_DEFUN_ONCE([AC_USE_SYSTEM_EXTENSIONS], +[AC_BEFORE([$0], [AC_COMPILE_IFELSE])dnl +AC_BEFORE([$0], [AC_RUN_IFELSE])dnl + + AC_REQUIRE([AC_CANONICAL_HOST]) + + AC_CHECK_HEADER([minix/config.h], [MINIX=yes], [MINIX=]) + if test "$MINIX" = yes; then + AC_DEFINE([_POSIX_SOURCE], [1], + [Define to 1 if you need to in order for `stat' and other + things to work.]) + AC_DEFINE([_POSIX_1_SOURCE], [2], + [Define to 2 if the system does not provide POSIX.1 features + except with this defined.]) + AC_DEFINE([_MINIX], [1], + [Define to 1 if on MINIX.]) fi -]) -AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -# -# Do we need to explicitly link libc? -# -case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in -x|xyes) - # Assume -lc should be added - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $_LT_AC_TAGVAR(archive_cmds, $1) in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - AC_MSG_CHECKING([whether -lc should be explicitly linked in]) - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) - then - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - else - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) + dnl HP-UX 11.11 defines mbstate_t only if _XOPEN_SOURCE is defined to 500, + dnl regardless of whether the flags -Ae or _D_HPUX_SOURCE=1 are already + dnl provided. + case "$host_os" in + hpux*) + AC_DEFINE([_XOPEN_SOURCE], [500], + [Define to 500 only on HP-UX.]) ;; - esac - fi - ;; -esac -])# AC_LIBTOOL_PROG_LD_SHLIBS - - -# _LT_AC_FILE_LTDLL_C -# ------------------- -# Be careful that the start marker always follows a newline. -AC_DEFUN([_LT_AC_FILE_LTDLL_C], [ -# /* ltdll.c starts here */ -# #define WIN32_LEAN_AND_MEAN -# #include -# #undef WIN32_LEAN_AND_MEAN -# #include -# -# #ifndef __CYGWIN__ -# # ifdef __CYGWIN32__ -# # define __CYGWIN__ __CYGWIN32__ -# # endif -# #endif -# -# #ifdef __cplusplus -# extern "C" { -# #endif -# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); -# #ifdef __cplusplus -# } -# #endif -# -# #ifdef __CYGWIN__ -# #include -# DECLARE_CYGWIN_DLL( DllMain ); -# #endif -# HINSTANCE __hDllInstance_base; -# -# BOOL APIENTRY -# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) -# { -# __hDllInstance_base = hInst; -# return TRUE; -# } -# /* ltdll.c ends here */ -])# _LT_AC_FILE_LTDLL_C - - -# _LT_AC_TAGVAR(VARNAME, [TAGNAME]) -# --------------------------------- -AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) - - -# old names -AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) -AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) -AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) -AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) -AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) -AC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) -AC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) - -# This is just to silence aclocal about the macro not being used -ifelse([AC_DISABLE_FAST_INSTALL]) - -AC_DEFUN([LT_AC_PROG_GCJ], -[AC_CHECK_TOOL(GCJ, gcj, no) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" - AC_SUBST(GCJFLAGS) -]) - -AC_DEFUN([LT_AC_PROG_RC], -[AC_CHECK_TOOL(RC, windres, no) -]) + esac -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -# LT_AC_PROG_SED -# -------------- -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -AC_DEFUN([LT_AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done + AH_VERBATIM([__EXTENSIONS__], +[/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# undef _GNU_SOURCE +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# undef _POSIX_PTHREAD_SEMANTICS +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# undef _TANDEM_SOURCE +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# undef __EXTENSIONS__ +#endif ]) -SED=$lt_cv_path_SED -AC_MSG_RESULT([$SED]) + AC_CACHE_CHECK([whether it is safe to define __EXTENSIONS__], + [ac_cv_safe_to_define___extensions__], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[ +# define __EXTENSIONS__ 1 + ]AC_INCLUDES_DEFAULT])], + [ac_cv_safe_to_define___extensions__=yes], + [ac_cv_safe_to_define___extensions__=no])]) + test $ac_cv_safe_to_define___extensions__ = yes && + AC_DEFINE([__EXTENSIONS__]) + AC_DEFINE([_ALL_SOURCE]) + AC_DEFINE([_GNU_SOURCE]) + AC_DEFINE([_POSIX_PTHREAD_SEMANTICS]) + AC_DEFINE([_TANDEM_SOURCE]) +])# AC_USE_SYSTEM_EXTENSIONS + +# gl_USE_SYSTEM_EXTENSIONS +# ------------------------ +# Enable extensions on systems that normally disable them, +# typically due to standards-conformance issues. +AC_DEFUN_ONCE([gl_USE_SYSTEM_EXTENSIONS], +[ + dnl Require this macro before AC_USE_SYSTEM_EXTENSIONS. + dnl gnulib does not need it. But if it gets required by third-party macros + dnl after AC_USE_SYSTEM_EXTENSIONS is required, autoconf 2.62..2.63 emit a + dnl warning: "AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS". + dnl Note: We can do this only for one of the macros AC_AIX, AC_GNU_SOURCE, + dnl AC_MINIX. If people still use AC_AIX or AC_MINIX, they are out of luck. + AC_REQUIRE([AC_GNU_SOURCE]) + + AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS]) ]) -# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +# Copyright (C) 2002-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -6195,10 +151,10 @@ AC_MSG_RESULT([$SED]) # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.11' +[am__api_version='1.15' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.11], [], +m4_if([$1], [1.15], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -6214,22 +170,82 @@ m4_define([_AM_AUTOCONF_VERSION], []) # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.11])dnl +[AM_AUTOMAKE_VERSION([1.15])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) +# Copyright (C) 2011-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_AR([ACT-IF-FAIL]) +# ------------------------- +# Try to determine the archiver interface, and trigger the ar-lib wrapper +# if it is needed. If the detection of archiver interface fails, run +# ACT-IF-FAIL (default is to abort configure with a proper error message). +AC_DEFUN([AM_PROG_AR], +[AC_BEFORE([$0], [LT_INIT])dnl +AC_BEFORE([$0], [AC_PROG_LIBTOOL])dnl +AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([ar-lib])dnl +AC_CHECK_TOOLS([AR], [ar lib "link -lib"], [false]) +: ${AR=ar} + +AC_CACHE_CHECK([the archiver ($AR) interface], [am_cv_ar_interface], + [AC_LANG_PUSH([C]) + am_cv_ar_interface=ar + AC_COMPILE_IFELSE([AC_LANG_SOURCE([[int some_variable = 0;]])], + [am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([am_ar_try]) + if test "$ac_status" -eq 0; then + am_cv_ar_interface=ar + else + am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([am_ar_try]) + if test "$ac_status" -eq 0; then + am_cv_ar_interface=lib + else + am_cv_ar_interface=unknown + fi + fi + rm -f conftest.lib libconftest.a + ]) + AC_LANG_POP([C])]) + +case $am_cv_ar_interface in +ar) + ;; +lib) + # Microsoft lib, so override with the ar-lib wrapper script. + # FIXME: It is wrong to rewrite AR. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__AR in this case, + # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something + # similar. + AR="$am_aux_dir/ar-lib $AR" + ;; +unknown) + m4_default([$1], + [AC_MSG_ERROR([could not determine $AR interface])]) + ;; +esac +AC_SUBST([AR])dnl +]) + # AM_AUX_DIR_EXPAND -*- Autoconf -*- -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets -# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to -# `$srcdir', `$srcdir/..', or `$srcdir/../..'. +# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to +# '$srcdir', '$srcdir/..', or '$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and @@ -6248,7 +264,7 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually -# harmless because $srcdir is `.', but things will broke when you +# harmless because $srcdir is '.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, @@ -6266,30 +282,26 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], -[dnl Rely on autoconf to set up CDPATH properly. -AC_PREREQ([2.50])dnl -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` +[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- -# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 9 - # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], -[AC_PREREQ(2.52)dnl - ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], - [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl +[AC_PREREQ([2.52])dnl + m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE])dnl AC_SUBST([$1_FALSE])dnl _AM_SUBST_NOTMAKE([$1_TRUE])dnl @@ -6308,16 +320,14 @@ AC_CONFIG_COMMANDS_PRE( Usually this means the macro was only invoked conditionally.]]) fi])]) -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 -# Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 10 -# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be +# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing @@ -6327,7 +337,7 @@ fi])]) # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. -# NAME is "CC", "CXX", "GCJ", or "OBJC". +# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was @@ -6340,12 +350,13 @@ AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl -ifelse([$1], CC, [depcc="$CC" am_compiler_list=], - [$1], CXX, [depcc="$CXX" am_compiler_list=], - [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], - [$1], UPC, [depcc="$UPC" am_compiler_list=], - [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], - [depcc="$$1" am_compiler_list=]) +m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], + [$1], [CXX], [depcc="$CXX" am_compiler_list=], + [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], + [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], + [$1], [UPC], [depcc="$UPC" am_compiler_list=], + [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], + [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], @@ -6353,8 +364,9 @@ AC_CACHE_CHECK([dependency style of $depcc], # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -6393,16 +405,16 @@ AC_CACHE_CHECK([dependency style of $depcc], : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with `-c' and `-o' for the sake of the "dashmstdout" + # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in @@ -6411,16 +423,16 @@ AC_CACHE_CHECK([dependency style of $depcc], test "$am__universal" = false || continue ;; nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} @@ -6468,7 +480,7 @@ AM_CONDITIONAL([am__fastdep$1], [ # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. -# This macro is AC_REQUIREd in _AM_DEPENDENCIES +# This macro is AC_REQUIREd in _AM_DEPENDENCIES. AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl @@ -6478,34 +490,39 @@ AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], -[AC_ARG_ENABLE(dependency-tracking, -[ --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors]) +[AC_ARG_ENABLE([dependency-tracking], [dnl +AS_HELP_STRING( + [--enable-dependency-tracking], + [do not reject slow dependency extractors]) +AS_HELP_STRING( + [--disable-dependency-tracking], + [speeds up one-time build])]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' + am__nodep='_no' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl +AC_SUBST([am__nodep])dnl +_AM_SUBST_NOTMAKE([am__nodep])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -#serial 5 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [{ - # Autoconf 2.62 quotes --file arguments for eval, but not when files + # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. case $CONFIG_FILES in @@ -6518,7 +535,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but + # We used to match only the files named 'Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. @@ -6530,21 +547,19 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], continue fi # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. + # from the Makefile without running 'make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue + test -z "$am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` @@ -6562,7 +577,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking -# is enabled. FIXME. This creates each `.P' file that we will +# is enabled. FIXME. This creates each '.P' file that we will # need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], @@ -6570,32 +585,23 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 8 - -# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. -AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) - # Do all the work for Automake. -*- Autoconf -*- -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 16 - # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. +dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. +m4_define([AC_PROG_CC], +m4_defn([AC_PROG_CC]) +[_AM_PROG_CC_C_O +]) + # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- @@ -6608,7 +614,7 @@ AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], -[AC_PREREQ([2.62])dnl +[AC_PREREQ([2.65])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl @@ -6637,33 +643,42 @@ AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], -[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl +[AC_DIAGNOSE([obsolete], + [$0: two- and three-arguments forms are deprecated.]) +m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. -m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, +m4_if( + m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), + [ok:ok],, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, -[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) - AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl +[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) + AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl -AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) -AM_MISSING_PROG(AUTOCONF, autoconf) -AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) -AM_MISSING_PROG(AUTOHEADER, autoheader) -AM_MISSING_PROG(MAKEINFO, makeinfo) +AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) +AM_MISSING_PROG([AUTOCONF], [autoconf]) +AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) +AM_MISSING_PROG([AUTOHEADER], [autoheader]) +AM_MISSING_PROG([MAKEINFO], [makeinfo]) AC_REQUIRE([AM_PROG_INSTALL_SH])dnl AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl -AC_REQUIRE([AM_PROG_MKDIR_P])dnl -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. +AC_REQUIRE([AC_PROG_MKDIR_P])dnl +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +AC_SUBST([mkdir_p], ['$(MKDIR_P)']) +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl @@ -6672,34 +687,82 @@ _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], - [_AM_DEPENDENCIES(CC)], - [define([AC_PROG_CC], - defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl + [_AM_DEPENDENCIES([CC])], + [m4_define([AC_PROG_CC], + m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], - [_AM_DEPENDENCIES(CXX)], - [define([AC_PROG_CXX], - defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl + [_AM_DEPENDENCIES([CXX])], + [m4_define([AC_PROG_CXX], + m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], - [_AM_DEPENDENCIES(OBJC)], - [define([AC_PROG_OBJC], - defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl + [_AM_DEPENDENCIES([OBJC])], + [m4_define([AC_PROG_OBJC], + m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], + [_AM_DEPENDENCIES([OBJCXX])], + [m4_define([AC_PROG_OBJCXX], + m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl ]) -_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl -dnl The `parallel-tests' driver may need to know about EXEEXT, so add the -dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro -dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. +AC_REQUIRE([AM_SILENT_RULES])dnl +dnl The testsuite driver may need to know about EXEEXT, so add the +dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This +dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. AC_CONFIG_COMMANDS_PRE(dnl [m4_provide_if([_AM_COMPILER_EXEEXT], [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) + fi +fi +dnl The trailing newline in this macro's definition is deliberate, for +dnl backward compatibility and to allow trailing 'dnl'-style comments +dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. ]) -dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not +dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further dnl mangled by Autoconf and run in a shell conditional statement. m4_define([_AC_COMPILER_EXEEXT], m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) - # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. @@ -6721,7 +784,7 @@ for _am_header in $config_headers :; do done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) -# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -6732,7 +795,7 @@ echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_co # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -if test x"${install_sh}" != xset; then +if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; @@ -6740,16 +803,14 @@ if test x"${install_sh}" != xset; then install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi -AC_SUBST(install_sh)]) +AC_SUBST([install_sh])]) -# Copyright (C) 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2003-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], @@ -6765,14 +826,12 @@ AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- -# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 4 - # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. @@ -6790,7 +849,7 @@ am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. +# Ignore all kinds of additional output from 'make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include @@ -6815,52 +874,14 @@ AC_MSG_RESULT([$_am_result]) rm -f confinc confmf ]) -# Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 6 - -# AM_PROG_CC_C_O -# -------------- -# Like AC_PROG_CC_C_O, but changed for automake. -AC_DEFUN([AM_PROG_CC_C_O], -[AC_REQUIRE([AC_PROG_CC_C_O])dnl -AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -AC_REQUIRE_AUX_FILE([compile])dnl -# FIXME: we rely on the cache variable name because -# there is no other way. -set dummy $CC -am_cc=`echo $[2] | sed ['s/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/']` -eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o -if test "$am_t" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" -fi -dnl Make sure AC_PROG_CC is never called again, or it will override our -dnl setting of CC. -m4_define([AC_PROG_CC], - [m4_fatal([AC_PROG_CC cannot be called after AM_PROG_CC_C_O])]) -]) - # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- -# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 6 - # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], @@ -6868,11 +889,10 @@ AC_DEFUN([AM_MISSING_PROG], $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) - # AM_MISSING_HAS_RUN # ------------------ -# Define MISSING if not defined so far and test if it supports --run. -# If it does, set am_missing_run to use it, otherwise, to nothing. +# Define MISSING if not defined so far and test if it is modern enough. +# If it is, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl @@ -6885,63 +905,35 @@ if test x"${MISSING+set}" != xset; then esac fi # Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " else am_missing_run= - AC_MSG_WARN([`missing' script is too old or missing]) + AC_MSG_WARN(['missing' script is too old or missing]) fi ]) -# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_MKDIR_P -# --------------- -# Check for `mkdir -p'. -AC_DEFUN([AM_PROG_MKDIR_P], -[AC_PREREQ([2.60])dnl -AC_REQUIRE([AC_PROG_MKDIR_P])dnl -dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, -dnl while keeping a definition of mkdir_p for backward compatibility. -dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. -dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of -dnl Makefile.ins that do not define MKDIR_P, so we do our own -dnl adjustment using top_builddir (which is defined more often than -dnl MKDIR_P). -AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl -case $mkdir_p in - [[\\/$]]* | ?:[[\\/]]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac -]) - # Helper functions for option handling. -*- Autoconf -*- -# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 4 - # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) -# ------------------------------ +# -------------------- # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], -[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) +[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) # _AM_SET_OPTIONS(OPTIONS) -# ---------------------------------- +# ------------------------ # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) @@ -6952,50 +944,82 @@ AC_DEFUN([_AM_SET_OPTIONS], AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002, 2003, 2005, 2006 -# Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 5 - -AC_DEFUN([AM_C_PROTOTYPES], -[AC_REQUIRE([AC_C_PROTOTYPES]) -if test "$ac_cv_prog_cc_stdc" != no; then - U= ANSI2KNR= -else - U=_ ANSI2KNR=./ansi2knr +# _AM_PROG_CC_C_O +# --------------- +# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC +# to automatically call this. +AC_DEFUN([_AM_PROG_CC_C_O], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([compile])dnl +AC_LANG_PUSH([C])dnl +AC_CACHE_CHECK( + [whether $CC understands -c and -o together], + [am_cv_prog_cc_c_o], + [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i]) +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" fi -# Ensure some checks needed by ansi2knr itself. -AC_REQUIRE([AC_HEADER_STDC]) -AC_CHECK_HEADERS([string.h]) -AC_SUBST([U])dnl -AC_SUBST([ANSI2KNR])dnl -_AM_SUBST_NOTMAKE([ANSI2KNR])dnl -]) +AC_LANG_POP([C])]) + +# For backward compatibility. +AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. -AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES]) +# AM_RUN_LOG(COMMAND) +# ------------------- +# Run COMMAND, save the exit status in ac_status, and log it. +# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) +AC_DEFUN([AM_RUN_LOG], +[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD + ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + (exit $ac_status); }]) # Check to make sure that the build environment is sane. -*- Autoconf -*- -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 5 - # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) -# Just in case -sleep 1 -echo timestamp > conftest.file # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' @@ -7006,32 +1030,40 @@ case `pwd` in esac case $srcdir in *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) - AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; + AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; esac -# Do `set' in a subshell so we don't clobber the current shell's +# Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$[*]" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$[*]" != "X $srcdir/configure conftest.file" \ - && test "$[*]" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken -alias in your environment]) - fi - + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[*]" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$[*]" != "X $srcdir/configure conftest.file" \ + && test "$[*]" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken + alias in your environment]) + fi + if test "$[2]" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done test "$[2]" = conftest.file ) then @@ -7041,9 +1073,85 @@ else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi -AC_MSG_RESULT(yes)]) +AC_MSG_RESULT([yes]) +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi +AC_CONFIG_COMMANDS_PRE( + [AC_MSG_CHECKING([that generated files are newer than configure]) + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + AC_MSG_RESULT([done])]) +rm -f conftest.file +]) + +# Copyright (C) 2009-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Enable less verbose build rules; with the default set to DEFAULT +# ("yes" being less verbose, "no" or empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_ARG_ENABLE([silent-rules], [dnl +AS_HELP_STRING( + [--enable-silent-rules], + [less verbose build output (undo: "make V=1")]) +AS_HELP_STRING( + [--disable-silent-rules], + [verbose build output (undo: "make V=0")])dnl +]) +case $enable_silent_rules in @%:@ ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; +esac +dnl +dnl A few 'make' implementations (e.g., NonStop OS and NextStep) +dnl do not support nested variable expansions. +dnl See automake bug#9928 and bug#10237. +am_make=${MAKE-make} +AC_CACHE_CHECK([whether $am_make supports nested variables], + [am_cv_make_support_nested_variables], + [if AS_ECHO([['TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi]) +if test $am_cv_make_support_nested_variables = yes; then + dnl Using '$V' instead of '$(V)' breaks IRIX make. + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AC_SUBST([AM_V])dnl +AM_SUBST_NOTMAKE([AM_V])dnl +AC_SUBST([AM_DEFAULT_V])dnl +AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl +AC_SUBST([AM_DEFAULT_VERBOSITY])dnl +AM_BACKSLASH='\' +AC_SUBST([AM_BACKSLASH])dnl +_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +]) -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -7051,34 +1159,32 @@ AC_MSG_RESULT(yes)]) # AM_PROG_INSTALL_STRIP # --------------------- -# One issue with vendor `install' (even GNU) is that you can't +# One issue with vendor 'install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we -# always use install-sh in `make install-strip', and initialize +# always use install-sh in "make install-strip", and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. -dnl Don't test for $cross_compiling = yes, because it might be `maybe'. +# will honor the 'STRIP' environment variable to overrule this program. +dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) -# Copyright (C) 2006, 2008 Free Software Foundation, Inc. +# Copyright (C) 2006-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # _AM_SUBST_NOTMAKE(VARIABLE) # --------------------------- # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. @@ -7086,24 +1192,22 @@ AC_SUBST([INSTALL_STRIP_PROGRAM])]) AC_DEFUN([_AM_SUBST_NOTMAKE]) # AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- +# -------------------------- # Public sister of _AM_SUBST_NOTMAKE. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- -# Copyright (C) 2004, 2005 Free Software Foundation, Inc. +# Copyright (C) 2004-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. -# FORMAT should be one of `v7', `ustar', or `pax'. +# FORMAT should be one of 'v7', 'ustar', or 'pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory @@ -7113,80 +1217,152 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar +# AC_DEFUN([_AM_PROG_TAR], -[# Always define AMTAR for backward compatibility. -AM_MISSING_PROG([AMTAR], [tar]) -m4_if([$1], [v7], - [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], - [m4_case([$1], [ustar],, [pax],, - [m4_fatal([Unknown tar format])]) -AC_MSG_CHECKING([how to create a $1 tar archive]) -# Loop over all known methods to create a tar archive until one works. +[# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AC_SUBST([AMTAR], ['$${TAR-tar}']) + +# We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' -_am_tools=${am_cv_prog_tar_$1-$_am_tools} -# Do not fold the above two line into one, because Tru64 sh and -# Solaris sh will not grok spaces in the rhs of `-'. -for _am_tool in $_am_tools -do - case $_am_tool in - gnutar) - for _am_tar in tar gnutar gtar; - do - AM_RUN_LOG([$_am_tar --version]) && break - done - am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' - am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' - am__untar="$_am_tar -xf -" - ;; - plaintar) - # Must skip GNU tar: if it does not support --format= it doesn't create - # ustar tarball either. - (tar --version) >/dev/null 2>&1 && continue - am__tar='tar chf - "$$tardir"' - am__tar_='tar chf - "$tardir"' - am__untar='tar xf -' - ;; - pax) - am__tar='pax -L -x $1 -w "$$tardir"' - am__tar_='pax -L -x $1 -w "$tardir"' - am__untar='pax -r' - ;; - cpio) - am__tar='find "$$tardir" -print | cpio -o -H $1 -L' - am__tar_='find "$tardir" -print | cpio -o -H $1 -L' - am__untar='cpio -i -H $1 -d' - ;; - none) - am__tar=false - am__tar_=false - am__untar=false - ;; - esac - # If the value was cached, stop now. We just wanted to have am__tar - # and am__untar set. - test -n "${am_cv_prog_tar_$1}" && break +m4_if([$1], [v7], + [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], + + [m4_case([$1], + [ustar], + [# The POSIX 1988 'ustar' format is defined with fixed-size fields. + # There is notably a 21 bits limit for the UID and the GID. In fact, + # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 + # and bug#13588). + am_max_uid=2097151 # 2^21 - 1 + am_max_gid=$am_max_uid + # The $UID and $GID variables are not portable, so we need to resort + # to the POSIX-mandated id(1) utility. Errors in the 'id' calls + # below are definitely unexpected, so allow the users to see them + # (that is, avoid stderr redirection). + am_uid=`id -u || echo unknown` + am_gid=`id -g || echo unknown` + AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) + if test $am_uid -le $am_max_uid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi + AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) + if test $am_gid -le $am_max_gid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi], + + [pax], + [], - # tar/untar a dummy directory, and stop if the command works - rm -rf conftest.dir - mkdir conftest.dir - echo GrepMe > conftest.dir/file - AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + [m4_fatal([Unknown tar format])]) + + AC_MSG_CHECKING([how to create a $1 tar archive]) + + # Go ahead even if we have the value already cached. We do so because we + # need to set the values for the 'am__tar' and 'am__untar' variables. + _am_tools=${am_cv_prog_tar_$1-$_am_tools} + + for _am_tool in $_am_tools; do + case $_am_tool in + gnutar) + for _am_tar in tar gnutar gtar; do + AM_RUN_LOG([$_am_tar --version]) && break + done + am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' + am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' + am__untar="$_am_tar -xf -" + ;; + plaintar) + # Must skip GNU tar: if it does not support --format= it doesn't create + # ustar tarball either. + (tar --version) >/dev/null 2>&1 && continue + am__tar='tar chf - "$$tardir"' + am__tar_='tar chf - "$tardir"' + am__untar='tar xf -' + ;; + pax) + am__tar='pax -L -x $1 -w "$$tardir"' + am__tar_='pax -L -x $1 -w "$tardir"' + am__untar='pax -r' + ;; + cpio) + am__tar='find "$$tardir" -print | cpio -o -H $1 -L' + am__tar_='find "$tardir" -print | cpio -o -H $1 -L' + am__untar='cpio -i -H $1 -d' + ;; + none) + am__tar=false + am__tar_=false + am__untar=false + ;; + esac + + # If the value was cached, stop now. We just wanted to have am__tar + # and am__untar set. + test -n "${am_cv_prog_tar_$1}" && break + + # tar/untar a dummy directory, and stop if the command works. + rm -rf conftest.dir + mkdir conftest.dir + echo GrepMe > conftest.dir/file + AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + rm -rf conftest.dir + if test -s conftest.tar; then + AM_RUN_LOG([$am__untar /dev/null 2>&1 && break + fi + done rm -rf conftest.dir - if test -s conftest.tar; then - AM_RUN_LOG([$am__untar /dev/null 2>&1 && break - fi -done -rm -rf conftest.dir -AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) -AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) + AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR -m4_include([libopts/m4/libopts.m4]) -m4_include([m4/define_dir.m4]) -m4_include([m4/hs_ulong_const.m4]) -m4_include([m4/os_cflags.m4]) +m4_include([sntp/libopts/m4/libopts.m4]) +m4_include([sntp/libopts/m4/stdnoreturn.m4]) +m4_include([sntp/m4/ax_c99_struct_init.m4]) +m4_include([sntp/m4/define_dir.m4]) +m4_include([sntp/m4/hms_search_lib.m4]) +m4_include([sntp/m4/libtool.m4]) +m4_include([sntp/m4/ltoptions.m4]) +m4_include([sntp/m4/ltsugar.m4]) +m4_include([sntp/m4/ltversion.m4]) +m4_include([sntp/m4/lt~obsolete.m4]) +m4_include([sntp/m4/ntp_cacheversion.m4]) +m4_include([sntp/m4/ntp_compiler.m4]) +m4_include([sntp/m4/ntp_crosscompile.m4]) +m4_include([sntp/m4/ntp_crypto_rand.m4]) +m4_include([sntp/m4/ntp_debug.m4]) +m4_include([sntp/m4/ntp_dir_sep.m4]) +m4_include([sntp/m4/ntp_facilitynames.m4]) +m4_include([sntp/m4/ntp_googletest.m4]) +m4_include([sntp/m4/ntp_ipv6.m4]) +m4_include([sntp/m4/ntp_lib_m.m4]) +m4_include([sntp/m4/ntp_libevent.m4]) +m4_include([sntp/m4/ntp_libntp.m4]) +m4_include([sntp/m4/ntp_lineeditlibs.m4]) +m4_include([sntp/m4/ntp_locinfo.m4]) +m4_include([sntp/m4/ntp_openssl.m4]) +m4_include([sntp/m4/ntp_pkg_config.m4]) +m4_include([sntp/m4/ntp_problemtests.m4]) +m4_include([sntp/m4/ntp_prog_cc.m4]) +m4_include([sntp/m4/ntp_rlimit.m4]) +m4_include([sntp/m4/ntp_sntp.m4]) +m4_include([sntp/m4/ntp_unitytest.m4]) +m4_include([sntp/m4/ntp_ver_suffix.m4]) +m4_include([sntp/m4/ntp_vpathhack.m4]) +m4_include([sntp/m4/openldap-thread-check.m4]) +m4_include([sntp/m4/openldap.m4]) +m4_include([sntp/m4/os_cflags.m4]) +m4_include([sntp/m4/snprintf.m4]) diff --git a/contrib/ntp/adjtimed/Makefile.am b/contrib/ntp/adjtimed/Makefile.am index 9605d1f44..b603fed92 100644 --- a/contrib/ntp/adjtimed/Makefile.am +++ b/contrib/ntp/adjtimed/Makefile.am @@ -1,10 +1,21 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr +## adjtimed Makefile.am -bindir= ${exec_prefix}/${BINSUBDIR} -bin_PROGRAMS= @MAKE_ADJTIMED@ -EXTRA_PROGRAMS= adjtimed -AM_CPPFLAGS= -I$(top_srcdir)/include -LDADD= ../libntp/libntp.a -ETAGS_ARGS= Makefile.am +bin_PROGRAMS = $(ADJTIMED_DB) +libexec_PROGRAMS = $(ADJTIMED_DL) +sbin_PROGRAMS = $(ADJTIMED_DS) -include ../bincheck.mf +BUILT_SOURCES = +CLEANFILES = +EXTRA_PROGRAMS = adjtimed + +AM_CFLAGS = $(CFLAGS_NTP) + +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) + +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/adjtimed/Makefile.in b/contrib/ntp/adjtimed/Makefile.in index 2fde4c6d8..7a546ef2f 100644 --- a/contrib/ntp/adjtimed/Makefile.in +++ b/contrib/ntp/adjtimed/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -20,6 +19,61 @@ # subdir to warn folks if there is another version there. VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -38,84 +92,204 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr +bin_PROGRAMS = +libexec_PROGRAMS = +sbin_PROGRAMS = EXTRA_PROGRAMS = adjtimed$(EXEEXT) -DIST_COMMON = README $(srcdir)/../bincheck.mf $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in subdir = adjtimed ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" +PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(sbin_PROGRAMS) adjtimed_SOURCES = adjtimed.c -adjtimed_OBJECTS = adjtimed$U.$(OBJEXT) +adjtimed_OBJECTS = adjtimed.$(OBJEXT) adjtimed_LDADD = $(LDADD) -adjtimed_DEPENDENCIES = ../libntp/libntp.a +am__DEPENDENCIES_1 = +adjtimed_DEPENDENCIES = ../libntp/libntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = SOURCES = adjtimed.c DIST_SOURCES = adjtimed.c +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/bincheck.mf \ + $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf \ + $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -123,8 +297,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -134,15 +311,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -150,29 +388,65 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -213,16 +487,20 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr -bin_PROGRAMS = @MAKE_ADJTIMED@ -AM_CPPFLAGS = -I$(top_srcdir)/include -LDADD = ../libntp/libntp.a -ETAGS_ARGS = Makefile.am -all: all-am +BUILT_SOURCES = check-libntp .deps-ver +CLEANFILES = check-libntp .deps-ver +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(CPPFLAGS_NTP) +LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -234,7 +512,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__con echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign adjtimed/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign adjtimed/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -243,6 +520,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/bincheck.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -254,14 +532,19 @@ $(ACLOCAL_M4): $(am__aclocal_m4_deps) $(am__aclocal_m4_deps): install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p || test -f $$p1; \ - then echo "$$p"; echo "$$p"; else :; fi; \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ - sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ @@ -282,7 +565,8 @@ uninstall-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' `; \ + -e 's/$$/$(EXEEXT)/' \ + `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files @@ -295,46 +579,137 @@ clean-binPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -adjtimed$(EXEEXT): $(adjtimed_OBJECTS) $(adjtimed_DEPENDENCIES) +install-libexecPROGRAMS: $(libexec_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(libexecdir)" && rm -f $$files + +clean-libexecPROGRAMS: + @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +adjtimed$(EXEEXT): $(adjtimed_OBJECTS) $(adjtimed_DEPENDENCIES) $(EXTRA_adjtimed_DEPENDENCIES) @rm -f adjtimed$(EXEEXT) - $(LINK) $(adjtimed_OBJECTS) $(adjtimed_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(adjtimed_OBJECTS) $(adjtimed_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimed$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimed.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -adjtimed_.c: adjtimed.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/adjtimed.c; then echo $(srcdir)/adjtimed.c; else echo adjtimed.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -adjtimed_.$(OBJEXT) adjtimed_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo @@ -342,26 +717,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -373,15 +737,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -390,6 +750,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -425,13 +800,15 @@ distdir: $(DISTFILES) fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -441,13 +818,19 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -456,9 +839,11 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -484,7 +869,8 @@ install-dvi: install-dvi-am install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-libexecPROGRAMS \ + install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -514,7 +900,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -525,35 +911,106 @@ ps: ps-am ps-am: -uninstall-am: uninstall-binPROGRAMS +uninstall-am: uninstall-binPROGRAMS uninstall-libexecPROGRAMS \ + uninstall-sbinPROGRAMS + +.MAKE: all check install install-am install-exec-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ + clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS cscopelist-am ctags ctags-am \ + distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-binPROGRAMS \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-exec-hook install-html \ + install-html-am install-info install-info-am \ + install-libexecPROGRAMS install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-sbinPROGRAMS install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-libexecPROGRAMS uninstall-sbinPROGRAMS -.MAKE: ../util/ansi2knr install-am install-exec-am install-strip - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-kr mostlyclean-libtool pdf pdf-am ps ps-am tags \ - uninstall uninstall-am uninstall-binPROGRAMS +.PRECIOUS: Makefile install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ - || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ - test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ + done + +# +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. # # Tell versions [3.59,3.63) of GNU make to not export all variables. diff --git a/contrib/ntp/adjtimed/adjtimed.c b/contrib/ntp/adjtimed/adjtimed.c index f38e66dd0..fd28dfb1b 100644 --- a/contrib/ntp/adjtimed/adjtimed.c +++ b/contrib/ntp/adjtimed/adjtimed.c @@ -58,7 +58,7 @@ void Exit (int); /* emacs cc-mode goes nuts if we split the next line... */ #define tvtod(tv) ((double)tv.tv_sec + ((double)tv.tv_usec / (double)MILLION)) -char *progname = NULL; +char const *progname = NULL; int verbose = 0; int sysdebug = 0; static int mqid; diff --git a/contrib/ntp/arlib/COPYING b/contrib/ntp/arlib/COPYING deleted file mode 100644 index 57e5c2a68..000000000 --- a/contrib/ntp/arlib/COPYING +++ /dev/null @@ -1,46 +0,0 @@ -Replied: Fri, 16 Feb 2001 14:12:54 -0500 -Replied: "Darren Reed " -Received: from [139.134.6.79] by whimsy.udel.edu id aa15476; - 16 Feb 2001 04:21 EST -Received: from CPE-61-9-164-106.vic.bigpond.net.au - ([139.134.4.52]) by mailin6.bigpond.com (Netscape Messaging - Server 4.15) with SMTP id G8UFIB00.4QI for - ; Fri, 16 Feb 2001 19:25:23 +1000 -Received: from CPE-61-9-164-110.vic.bigpond.net.au ([61.9.164.110]) by mail5.bigpond.com (Claudes-Retiring-MailRouter V2.9c 9/11963672); 16 Feb 2001 19:20:45 -Received: (from root@localhost) - by CPE-61-9-164-106.vic.bigpond.net.au (8.11.0/8.11.0) id f1G92GC29158 - for ; Fri, 16 Feb 2001 20:02:16 +1100 -From: Darren Reed -Message-Id: <200102160901.UAA23657@avalon.reed.wattle.id.au> -Subject: Re: arlib? -In-Reply-To: <901.982219274@whimsy.udel.edu> from Harlan Stenn at "Feb 15, 1 01:41:14 am" -To: Harlan Stenn -Date: Fri, 16 Feb 2001 20:01:46 +1100 -X-Mailer: ELM [version 2.4ME+ PL37 (25)] -MIME-Version: 1.0 -Content-Type: text/plain; charset=US-ASCII -Content-Transfer-Encoding: 7bit - -In some email I received from Harlan Stenn, sie wrote: -> Darren, -> -> I'm looking for an async resolver library that I can use with NTP. -> -> I noticed your code in the contrib/ subdir of later bind8 distribution -> and I noticed the Copyright notice in arlib.c: -> -> * arlib.c (C)opyright 1993 Darren Reed. All rights reserved. -> * This file may not be distributed without the author's permission in any -> * shape or form. The author takes no responsibility for any damage or loss -> * of property which results from the use of this software. -> -> so I thought I'd ask your permission to distribute your files if I can -> figure out how to make it all work with ntpd. - -http://coombs.anu.edu.au/~avalon/arlib.tar.gz - -a few bug fixes (inc. buffer overflow :) and stuff in there. - -But otherwise, go for it. - -Darren diff --git a/contrib/ntp/arlib/INSTALL b/contrib/ntp/arlib/INSTALL deleted file mode 100644 index b42a17ac4..000000000 --- a/contrib/ntp/arlib/INSTALL +++ /dev/null @@ -1,182 +0,0 @@ -Basic Installation -================== - - These are generic installation instructions. - - The `configure' shell script attempts to guess correct values for -various system-dependent variables used during compilation. It uses -those values to create a `Makefile' in each directory of the package. -It may also create one or more `.h' files containing system-dependent -definitions. Finally, it creates a shell script `config.status' that -you can run in the future to recreate the current configuration, a file -`config.cache' that saves the results of its tests to speed up -reconfiguring, and a file `config.log' containing compiler output -(useful mainly for debugging `configure'). - - If you need to do unusual things to compile the package, please try -to figure out how `configure' could check whether to do them, and mail -diffs or instructions to the address given in the `README' so they can -be considered for the next release. If at some point `config.cache' -contains results you don't want to keep, you may remove or edit it. - - The file `configure.in' is used to create `configure' by a program -called `autoconf'. You only need `configure.in' if you want to change -it or regenerate `configure' using a newer version of `autoconf'. - -The simplest way to compile this package is: - - 1. `cd' to the directory containing the package's source code and type - `./configure' to configure the package for your system. If you're - using `csh' on an old version of System V, you might need to type - `sh ./configure' instead to prevent `csh' from trying to execute - `configure' itself. - - Running `configure' takes awhile. While running, it prints some - messages telling which features it is checking for. - - 2. Type `make' to compile the package. - - 3. Optionally, type `make check' to run any self-tests that come with - the package. - - 4. Type `make install' to install the programs and any data files and - documentation. - - 5. You can remove the program binaries and object files from the - source code directory by typing `make clean'. To also remove the - files that `configure' created (so you can compile the package for - a different kind of computer), type `make distclean'. There is - also a `make maintainer-clean' target, but that is intended mainly - for the package's developers. If you use it, you may have to get - all sorts of other programs in order to regenerate files that came - with the distribution. - -Compilers and Options -===================== - - Some systems require unusual options for compilation or linking that -the `configure' script does not know about. You can give `configure' -initial values for variables by setting them in the environment. Using -a Bourne-compatible shell, you can do that on the command line like -this: - CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure - -Or on systems that have the `env' program, you can do it like this: - env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure - -Compiling For Multiple Architectures -==================================== - - You can compile the package for more than one kind of computer at the -same time, by placing the object files for each architecture in their -own directory. To do this, you must use a version of `make' that -supports the `VPATH' variable, such as GNU `make'. `cd' to the -directory where you want the object files and executables to go and run -the `configure' script. `configure' automatically checks for the -source code in the directory that `configure' is in and in `..'. - - If you have to use a `make' that does not supports the `VPATH' -variable, you have to compile the package for one architecture at a time -in the source code directory. After you have installed the package for -one architecture, use `make distclean' before reconfiguring for another -architecture. - -Installation Names -================== - - By default, `make install' will install the package's files in -`/usr/local/bin', `/usr/local/man', etc. You can specify an -installation prefix other than `/usr/local' by giving `configure' the -option `--prefix=PATH'. - - You can specify separate installation prefixes for -architecture-specific files and architecture-independent files. If you -give `configure' the option `--exec-prefix=PATH', the package will use -PATH as the prefix for installing programs and libraries. -Documentation and other data files will still use the regular prefix. - - In addition, if you use an unusual directory layout you can give -options like `--bindir=PATH' to specify different values for particular -kinds of files. Run `configure --help' for a list of the directories -you can set and what kinds of files go in them. - - If the package supports it, you can cause programs to be installed -with an extra prefix or suffix on their names by giving `configure' the -option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. - -Optional Features -================= - - Some packages pay attention to `--enable-FEATURE' options to -`configure', where FEATURE indicates an optional part of the package. -They may also pay attention to `--with-PACKAGE' options, where PACKAGE -is something like `gnu-as' or `x' (for the X Window System). The -`README' should mention any `--enable-' and `--with-' options that the -package recognizes. - - For packages that use the X Window System, `configure' can usually -find the X include and library files automatically, but if it doesn't, -you can use the `configure' options `--x-includes=DIR' and -`--x-libraries=DIR' to specify their locations. - -Specifying the System Type -========================== - - There may be some features `configure' can not figure out -automatically, but needs to determine by the type of host the package -will run on. Usually `configure' can figure that out, but if it prints -a message saying it can not guess the host type, give it the -`--host=TYPE' option. TYPE can either be a short name for the system -type, such as `sun4', or a canonical name with three fields: - CPU-COMPANY-SYSTEM - -See the file `config.sub' for the possible values of each field. If -`config.sub' isn't included in this package, then this package doesn't -need to know the host type. - - If you are building compiler tools for cross-compiling, you can also -use the `--target=TYPE' option to select the type of system they will -produce code for and the `--build=TYPE' option to select the type of -system on which you are compiling the package. - -Sharing Defaults -================ - - If you want to set default values for `configure' scripts to share, -you can create a site shell script called `config.site' that gives -default values for variables like `CC', `cache_file', and `prefix'. -`configure' looks for `PREFIX/share/config.site' if it exists, then -`PREFIX/etc/config.site' if it exists. Or, you can set the -`CONFIG_SITE' environment variable to the location of the site script. -A warning: not all `configure' scripts look for a site script. - -Operation Controls -================== - - `configure' recognizes the following options to control how it -operates. - -`--cache-file=FILE' - Use and save the results of the tests in FILE instead of - `./config.cache'. Set FILE to `/dev/null' to disable caching, for - debugging `configure'. - -`--help' - Print a summary of the options to `configure', and exit. - -`--quiet' -`--silent' -`-q' - Do not print messages saying which checks are being made. To - suppress all normal output, redirect it to `/dev/null' (any error - messages will still be shown). - -`--srcdir=DIR' - Look for the package's source code in directory DIR. Usually - `configure' can determine that directory automatically. - -`--version' - Print the version of Autoconf used to generate the `configure' - script, and exit. - -`configure' also accepts some other, not widely useful, options. diff --git a/contrib/ntp/arlib/Makefile.am b/contrib/ntp/arlib/Makefile.am deleted file mode 100644 index c0b40942a..000000000 --- a/contrib/ntp/arlib/Makefile.am +++ /dev/null @@ -1,15 +0,0 @@ -AUTOMAKE_OPTIONS = foreign # ansi2knr - -#lib_LIBRARIES = libares.a -noinst_LIBRARIES = libares.a -libares_a_SOURCES = arlib.c arplib.h -#include_HEADERS = arlib.h -noinst_HEADERS = arlib.h - -noinst_PROGRAMS = example -example_SOURCES = sample.c -example_LDADD = libares.a -#man_MANS = arlib.3 -#EXTRA_DIST = $(man_MANS) UNSHAR.HDR -noinst_MANS = arlib.3 -EXTRA_DIST = $(noinst_MANS) UNSHAR.HDR diff --git a/contrib/ntp/arlib/Makefile.in b/contrib/ntp/arlib/Makefile.in deleted file mode 100644 index b4f665cd5..000000000 --- a/contrib/ntp/arlib/Makefile.in +++ /dev/null @@ -1,580 +0,0 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - - - -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -noinst_PROGRAMS = example$(EXEEXT) -subdir = . -DIST_COMMON = README $(am__configure_deps) $(noinst_HEADERS) \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(top_srcdir)/configure COPYING INSTALL depcomp install-sh \ - missing -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/configure.in -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ - configure.lineno config.status.lineno -mkinstalldirs = $(install_sh) -d -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -LIBRARIES = $(noinst_LIBRARIES) -AR = @AR@ -ARFLAGS = @ARFLAGS@ -libares_a_AR = $(AR) $(ARFLAGS) -libares_a_LIBADD = -am_libares_a_OBJECTS = arlib.$(OBJEXT) -libares_a_OBJECTS = $(am_libares_a_OBJECTS) -PROGRAMS = $(noinst_PROGRAMS) -am_example_OBJECTS = sample.$(OBJEXT) -example_OBJECTS = $(am_example_OBJECTS) -example_DEPENDENCIES = libares.a -DEFAULT_INCLUDES = -I.@am__isrc@ -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -CCLD = $(CC) -LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -SOURCES = $(libares_a_SOURCES) $(example_SOURCES) -DIST_SOURCES = $(libares_a_SOURCES) $(example_SOURCES) -HEADERS = $(noinst_HEADERS) -ETAGS = etags -CTAGS = ctags -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -distdir = $(PACKAGE)-$(VERSION) -top_distdir = $(distdir) -am__remove_distdir = \ - { test ! -d "$(distdir)" \ - || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -fr "$(distdir)"; }; } -DIST_ARCHIVES = $(distdir).tar.gz -GZIP_ENV = --best -distuninstallcheck_listfiles = find . -type f -print -distcleancheck_listfiles = find . -type f -print -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EXEEXT = @EXEEXT@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MKDIR_P = @MKDIR_P@ -OBJEXT = @OBJEXT@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -RANLIB = @RANLIB@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_CC = @ac_ct_CC@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build_alias = @build_alias@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host_alias = @host_alias@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = foreign # ansi2knr - -#lib_LIBRARIES = libares.a -noinst_LIBRARIES = libares.a -libares_a_SOURCES = arlib.c arplib.h -#include_HEADERS = arlib.h -noinst_HEADERS = arlib.h -example_SOURCES = sample.c -example_LDADD = libares.a -#man_MANS = arlib.3 -#EXTRA_DIST = $(man_MANS) UNSHAR.HDR -noinst_MANS = arlib.3 -EXTRA_DIST = $(noinst_MANS) UNSHAR.HDR -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .o .obj -am--refresh: - @: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ - $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - echo ' $(SHELL) ./config.status'; \ - $(SHELL) ./config.status;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - $(SHELL) ./config.status --recheck - -$(top_srcdir)/configure: $(am__configure_deps) - $(am__cd) $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) -$(am__aclocal_m4_deps): - -clean-noinstLIBRARIES: - -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) -libares.a: $(libares_a_OBJECTS) $(libares_a_DEPENDENCIES) - -rm -f libares.a - $(libares_a_AR) libares.a $(libares_a_OBJECTS) $(libares_a_LIBADD) - $(RANLIB) libares.a - -clean-noinstPROGRAMS: - -test -z "$(noinst_PROGRAMS)" || rm -f $(noinst_PROGRAMS) -example$(EXEEXT): $(example_OBJECTS) $(example_DEPENDENCIES) - @rm -f example$(EXEEXT) - $(LINK) $(example_OBJECTS) $(example_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/arlib.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sample.Po@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< - -.c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - set x; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - $(am__remove_distdir) - test -d "$(distdir)" || mkdir "$(distdir)" - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ - ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ - || chmod -R a+r "$(distdir)" -dist-gzip: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) - -dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 - $(am__remove_distdir) - -dist-lzma: distdir - tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma - $(am__remove_distdir) - -dist-xz: distdir - tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz - $(am__remove_distdir) - -dist-tarZ: distdir - tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__remove_distdir) - -dist-shar: distdir - shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz - $(am__remove_distdir) - -dist-zip: distdir - -rm -f $(distdir).zip - zip -rq $(distdir).zip $(distdir) - $(am__remove_distdir) - -dist dist-all: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) - -# This target untars the dist file and tries a VPATH configuration. Then -# it guarantees that the distribution is self-contained by making another -# tarfile. -distcheck: dist - case '$(DIST_ARCHIVES)' in \ - *.tar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ - *.tar.bz2*) \ - bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lzma*) \ - unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ - *.tar.xz*) \ - xz -dc $(distdir).tar.xz | $(am__untar) ;;\ - *.tar.Z*) \ - uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ - *.shar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ - *.zip*) \ - unzip $(distdir).zip ;;\ - esac - chmod -R a-w $(distdir); chmod a+w $(distdir) - mkdir $(distdir)/_build - mkdir $(distdir)/_inst - chmod a-w $(distdir) - test -d $(distdir)/_build || exit 0; \ - dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ - && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ - && am__cwd=`pwd` \ - && $(am__cd) $(distdir)/_build \ - && ../configure --srcdir=.. --prefix="$$dc_install_base" \ - $(DISTCHECK_CONFIGURE_FLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) dvi \ - && $(MAKE) $(AM_MAKEFLAGS) check \ - && $(MAKE) $(AM_MAKEFLAGS) install \ - && $(MAKE) $(AM_MAKEFLAGS) installcheck \ - && $(MAKE) $(AM_MAKEFLAGS) uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ - distuninstallcheck \ - && chmod -R a-w "$$dc_install_base" \ - && ({ \ - (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ - distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ - } || { rm -rf "$$dc_destdir"; exit 1; }) \ - && rm -rf "$$dc_destdir" \ - && $(MAKE) $(AM_MAKEFLAGS) dist \ - && rm -rf $(DIST_ARCHIVES) \ - && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ - && cd "$$am__cwd" \ - || exit 1 - $(am__remove_distdir) - @(echo "$(distdir) archives ready for distribution: "; \ - list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ - sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' -distuninstallcheck: - @$(am__cd) '$(distuninstallcheck_dir)' \ - && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ - || { echo "ERROR: files left after uninstall:" ; \ - if test -n "$(DESTDIR)"; then \ - echo " (check DESTDIR support)"; \ - fi ; \ - $(distuninstallcheck_listfiles) ; \ - exit 1; } >&2 -distcleancheck: distclean - @if test '$(srcdir)' = . ; then \ - echo "ERROR: distcleancheck can only run from a VPATH build" ; \ - exit 1 ; \ - fi - @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left in build directory after distclean:" ; \ - $(distcleancheck_listfiles) ; \ - exit 1; } >&2 -check-am: all-am -check: check-am -all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(HEADERS) -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-noinstLIBRARIES clean-noinstPROGRAMS \ - mostlyclean-am - -distclean: distclean-am - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf $(top_srcdir)/autom4te.cache - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS all all-am am--refresh check check-am clean \ - clean-generic clean-noinstLIBRARIES clean-noinstPROGRAMS ctags \ - dist dist-all dist-bzip2 dist-gzip dist-lzma dist-shar \ - dist-tarZ dist-xz dist-zip distcheck distclean \ - distclean-compile distclean-generic distclean-tags \ - distcleancheck distdir distuninstallcheck dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \ - uninstall-am - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/contrib/ntp/arlib/README b/contrib/ntp/arlib/README deleted file mode 100644 index 1d2e787b5..000000000 --- a/contrib/ntp/arlib/README +++ /dev/null @@ -1,49 +0,0 @@ - - Asynchronous DNS - ---------------- - - Intro. - -For those who write real time network applications that have to handle -multiple TCP or UDP connections, the problem of effectively doing DNS -lookups is quite real. Generally, this means the program waits while -the query finishes, holding everything else up. This small library of -routines aims to solve that problem by performing the DNS query and -then returning the program to its normal flow. - - Whats included ? - -The library routines, arlib.c, a header file for it, arlib.h, a man -page, arlib.3 and an example of how this sort of code is used, -sample.c. - - - Compilation & Installation. - -Edit the Makefile and do "make install" to install things where you -wish them to go. You should check it makes and works before doing -this :) - -If the compilation is successful, you'll have an executeable called -"example" and libares.a. "example" is a simple program which will -do hostname->IP# or IP#->hostnae lookups by entering either the -hostname or IP# on the line with "Host-->". You dont have to wait -for a query to fail or succeed before typing in the next line. - - Portability. - -I'm not sure how portable this is, it was written under SunOS 4.1.2 -on a Sparc 1+ and hasn't been tested very widely. If you find any -problems when compiling/execution, plase send me a patch (using -diff -c) to avalon@coombs.anu.edu.au. If it goes well enough, I'll -send it to comp.unix.sources or comp.sources.misc for further testing. - - Future additions. - -Adding a working cache would be nice but I'm not sure if that really -is needed (?). I guess it depends on how often your program is -required to do a DNS lookup and whether caching would help. - - -Cheers, -Darren. diff --git a/contrib/ntp/arlib/UNSHAR.HDR b/contrib/ntp/arlib/UNSHAR.HDR deleted file mode 100644 index c92d475fe..000000000 --- a/contrib/ntp/arlib/UNSHAR.HDR +++ /dev/null @@ -1,32 +0,0 @@ -Replied: Sun, 19 Dec 93 09:58:30 PST -Replied: "Darren Reed " -Return-Path: avalon@coombs.anu.edu.au -Received: by gw.home.vix.com id AA12017; Sun, 19 Dec 93 07:04:44 -0800 -Message-Id: <9312191504.AA12017@gw.home.vix.com> -Received: by coombs.anu.edu.au - (1.37.109.8/16.2) id AA10850; Mon, 20 Dec 1993 02:07:21 +1100 -From: Darren Reed -Subject: Addition for 4.9 "contrib" directory -To: paul@vix.com -Date: Mon, 20 Dec 1993 02:07:20 +1000 (EDT) -X-Mailer: ELM [version 2.4 PL21] -Mime-Version: 1.0 -Content-Type: text/plain; charset=US-ASCII -Content-Transfer-Encoding: 7bit -Content-Length: 67950 - - -Well, I just sent one letter off to dec.com, being from the 4.9 README I had. - -So, to sum up what I said, I've included below, some code I've written to -perform async. DNS lookups - `replacements' for gethostbyname and -gethostbyaddr. I've written and tested it mainly on a HP-UX machine, so -I'm not sure how it will port to others, but I've tried to keep the amount -of OS specific code to a minimum. - -The Makefile is setup to work best from "contrib/arlib", which is how I -checked to make sure it worked and ran well. There's a man page included -also. - -Cheers, -Darren diff --git a/contrib/ntp/arlib/arlib.3 b/contrib/ntp/arlib/arlib.3 deleted file mode 100644 index afdc02f4d..000000000 --- a/contrib/ntp/arlib/arlib.3 +++ /dev/null @@ -1,230 +0,0 @@ -.TH arlib 3 -.SH NAME -ar_answer, ar_close, ar_delete, ar_gethostbyname, ar_gethostbyaddr, -ar_init, ar_open, ar_timeout - Asynchronous DNS library routines -.SH SYNOPSIS -.nf -.B #include "arlib.h" - -.B struct hostent *ar_answer(dataptr, size) -.B char *dataptr; -.B int size; - -.B void ar_close(); - -.B int ar_delete(dataptr, size) -.B char *dataptr; -.B int size; - -.B int ar_gethostbyname(name, dataptr, size) -.B char *name; -.B char *dataptr; -.B int size; - -.B int ar_gethostbyaddr(name, dataptr, size) -.B char *name; -.B char *dataptr; -.B int size; - -.B int ar_init(flags) -.B int flags; - -.B int ar_open(); - -.B long ar_timeout(time, dataptr, size) -.B long time; -.B char *dataptr; -.B int size; -.fi -.SH DESCRIPTION - -.PP - This small library of DNS routines is intended to provide an -asynchronous interface to performing hostname and IP number lookups. -Only lookups of Internet domain are handled as yet. To use this -set of routines properly, the presence of the -.B "BIND 4.8" -resolve -libraries is required (or any library derived from it). -.PP - This library should be used in conjunction with -.B select(2) -to wait for -the name server's reply to arrive or the lookup to timeout. -.PP - To open a fd for talking to the name server, either -.B ar_open() -or -ar_init() -must be used. -.B ar_open() - will open either a datagram socket -or a virtual circuit with the name server, depending on the flags -set in the _res structure (see -.B resolv(5) -). In both cases, if the socket - -> i -.B ar_init() -is -used to both open the socket (as in -.B ar_open() -) and initialize the -queues used by this library. The values recognized as parameters to -.B ar_init() -are: - -.RS -#define ARES_INITLIST 1 -.RE -.RS -#define ARES_CALLINIT 2 -.RE -.RS -#define ARES_INITSOCK 4 -.RE -.RS -#define ARES_INITDEBG 8 -.RE - - ARES_INITLIST initializes the list of queries waiting for replies. -ARES_CALLINIT is a flag which when set causes -.B res_init() -to be called. -ARES_INITSOCK will close the current socket if it is open and call -.B ar_open() -to open a new one, returning the fd for that socket. -ARES_INITDEBG sets the RES_DEBUG flag of the -.B _res -structure. -ARES_INITCACH is as yet, unused and is for future use where the library -keeps its own cache of replies. - - To send a query about either a hostname or an IP number, -.B ar_gethostbyname() -and -.B ar_gethostbyaddr() -must be used. Each takes -either a pointer to the hostname or the IP number respectively for use -when making the query. In addition to this, both (optionally) can be -passed a pointer to data, dataptr, with the size also passed which can -be used for identifying individual queries. A copy of the area pointed -to is made if dataptr is non NULL and size is non zero. These functions -will always return NULL unless the answer to the query is found in -internal caches. A new flag, RES_CHECKPTR is checked during the -processing of answers for -.B ar_gethostbyname() -which will automatically -cause a reverse lookup to be queued, causing a failure if that reply -differs from the original. - - To check for a query, -.B ar_answer() -is called with a pointer to an area -of memory which is sufficient to hold what was originally passed via -.B ar_gethostbyname() -or -.B ar_gethostbyaddr() -through dataptr. If an answer -is found, a pointer to the host information is returned and the data -segment copied if dataptr is non NULL and it was originally passed. The -size of the copied data is the smaller of the passed size and that of -original data stored. - - To expire old queries, -.B ar_timeout() -is called with the 'current' time -(or the time for which you want to do timeouts for). If a queue entry -is too old, it will be expired when it has exhausted all available avenues -for lookups and the data segment for the expired query copied into -dataptr. The size of the copied data is the smaller of the passed size -and that of the original stored data. Only 1 entry is thus expired with -each call, requiring that it be called immediately after an expiration -to check for others. In addition to expiring lookups, -.B ar_timeout() -also -triggers resends of queries and the searching of the domain tree for the -host, the latter works from the -.B _res -structure of -.B resolv(5). - - To delete entries from the queue, -.B ar_delete() -can be used and by -passing the pointer and size of the data segment, all queries have their -data segments checked (if present) for an exact match, being deleted if -and only if there is a match. A NULL pointer passed to ar_deleted() -matches all queries which were called with a NULL dataptr parameter. -The amount of data compared is the smaller of the size passed and that -of the data stored for the queue entry being compared. - - To close a socket opened by -.B ar_open() -, -.B ar_close() -should be used so -that it is closed and also marked closed within this library. - - -.SH DIAGNOSIS - -.B ar_open() -returns -1 if a socket isn't open and could not be opened; -otherwise returns the current fd open or the fd it opened. - -.B ar_init() -returns -1 for any errors, the value returned by -.B res_init() -if -.B res_init() -was called, the return value for -.B ar_open() -if that was -called or the current socket open if 0 is passed and a socket is open. -If neither -.B res_init() -or -.B ar_open() -are called and the flags are non-zero, -2 is returned. - -.B ar_gethostbyaddr() -and -.B ar_gethostbyname() -will always return NULL in this version but may return a pointer to a hostent -structure if a cache is being used and the answer is found in the cache. - -.B ar_answer() -returns NULL if the answer is either not found or the -query returned an error and another attempt at a lookup is attempted. -If an answer was found, it returned a pointer to this structure and -the contents of the data segment copied over. - -.B ar_timeout() -returns the time when it should be called next or 0 if -there are no queries in the queue to be checked later. If any queries -are expired, the data segment is copied over if dataptr is non NULL. - -.B ar_delete() -returns the number of entries that were found to match -and consequently deleted. - -.SH SEE ALSO - -gethostbyaddr(3), gethostbyname(3), resolv(5) - -.SH FILES -.nf -arlib.h -/usr/include/resolv.h -/usr/include/arpa/nameser.h -/etc/resolv.conf - -.SH BUGS - -The results of a successful call to ar_answer() destroy the structure -for any previous calls. - -.SH AUTHOR - -Darren Reed. Email address: avalon@coombs.anu.edu.au diff --git a/contrib/ntp/arlib/arlib.c b/contrib/ntp/arlib/arlib.c deleted file mode 100644 index 3d76e5749..000000000 --- a/contrib/ntp/arlib/arlib.c +++ /dev/null @@ -1,1056 +0,0 @@ -/* - * arlib.c (C)opyright 1993 Darren Reed. All rights reserved. - * This file may not be distributed without the author's permission in any - * shape or form. The author takes no responsibility for any damage or loss - * of property which results from the use of this software. - */ -#ifndef lint -static char sccsid[] = "@(#)arlib.c 1.9 6/5/93 (C)opyright 1992 Darren \ -Reed. ASYNC DNS"; -#endif - -#include -#include -#include -#include -#include -#include -#include -#include "netdb.h" -#include "arpa/nameser.h" -#include -#include "arlib.h" -#include "arplib.h" - -extern int errno, h_errno; -static char ar_hostbuf[65], ar_domainname[65]; -static char ar_dot[] = "."; -static int ar_resfd = -1, ar_vc = 0; -static struct reslist *ar_last, *ar_first; - -/* - * Statistics structure. - */ -static struct resstats { - int re_errors; - int re_nu_look; - int re_na_look; - int re_replies; - int re_requests; - int re_resends; - int re_sent; - int re_timeouts; -} ar_reinfo; - -static int do_query_name(/* struct resinfo *, char *, struct reslist * */); -static int do_query_number(/* struct resinfo *, char *, struct reslist * */); -static int ar_resend_query(/* struct reslist * */); - -/* - * ar_init - * - * Initializes the various ARLIB internal varilables and related DNS - * options for res_init(). - * - * Returns 0 or the socket opened for use with talking to name servers - * if 0 is passed or ARES_INITSOCK is set. - */ -int ar_init(op) -int op; -{ - int ret = 0; - - if (op & ARES_INITLIST) - { - bzero(&ar_reinfo, sizeof(ar_reinfo)); - ar_first = ar_last = NULL; - } - - if (op & ARES_CALLINIT && !(_res.options & RES_INIT)) - { - ret = res_init(); - (void)strcpy(ar_domainname, ar_dot); - (void)strncat(ar_domainname, _res.defdname, - sizeof(ar_domainname)-2); - } - - if (op & ARES_INITSOCK) - ret = ar_resfd = ar_open(); - - if (op & ARES_INITDEBG) - _res.options |= RES_DEBUG; - - if (op == 0) - ret = ar_resfd; - - return ret; -} - - -/* - * ar_open - * - * Open a socket to talk to a name server with. - * Check _res.options to see if we use a TCP or UDP socket. - */ -int ar_open() -{ - if (ar_resfd == -1) - { - if (_res.options & RES_USEVC) - { - struct sockaddr_in *sip; - int i; - - sip = _res.NS_ADDR_LIST; /* was _res.nsaddr_list */ - ar_vc = 1; - ar_resfd = socket(AF_INET, SOCK_STREAM, 0); - - /* - * Try each name server listed in sequence until we - * succeed or run out. - */ - while (connect(ar_resfd, (struct sockaddr *)sip++, - sizeof(struct sockaddr))) - { - (void)close(ar_resfd); - ar_resfd = -1; - if (i >= _res.nscount) - break; - ar_resfd = socket(AF_INET, SOCK_STREAM, 0); - } - } - else - ar_resfd = socket(AF_INET, SOCK_DGRAM, 0); - } - if (ar_resfd >= 0) - { /* Need one of these two here - and it MUST work!! */ - int flags; - - if ((flags = fcntl(ar_resfd, F_GETFL, 0)) != -1) -#ifdef O_NONBLOCK - if (fcntl(ar_resfd, F_SETFL, flags|O_NONBLOCK) == -1) -#else -# ifdef O_NDELAY - if (fcntl(ar_resfd, F_SETFL, flags|O_NDELAY) == -1) -# else -# ifdef FNDELAY - if (fcntl(ar_resfd, F_SETFL, flags|FNDELAY) == -1) -# endif -# endif -#endif - { - (void)close(ar_resfd); - ar_resfd = -1; - } - } - return ar_resfd; -} - - -/* - * ar_close - * - * Closes and flags the ARLIB socket as closed. - */ -void ar_close() -{ - (void)close(ar_resfd); - ar_resfd = -1; - return; -} - - -/* - * ar_add_request - * - * Add a new DNS query to the end of the query list. - */ -static int ar_add_request(new) -struct reslist *new; -{ - if (!new) - return -1; - if (!ar_first) - ar_first = ar_last = new; - else { - ar_last->re_next = new; - ar_last = new; - } - new->re_next = NULL; - ar_reinfo.re_requests++; - return 0; -} - - -/* - * ar_remrequest - * - * Remove a request from the list. This must also free any memory that has - * been allocated for temporary storage of DNS results. - * - * Returns -1 if there are anyy problems removing the requested structure - * or 0 if the remove is successful. - */ -static int ar_remrequest(old) -struct reslist *old; -{ - register struct reslist *rptr, *r2ptr; - register char **s; - - if (!old) - return -1; - for (rptr = ar_first, r2ptr = NULL; rptr; rptr = rptr->re_next) - { - if (rptr == old) - break; - r2ptr = rptr; - } - - if (!rptr) - return -1; - if (rptr == ar_first) - ar_first = ar_first->re_next; - else if (rptr == ar_last) - { - if (ar_last = r2ptr) - ar_last->re_next = NULL; - } - else - r2ptr->re_next = rptr->re_next; - - if (!ar_first) - ar_last = ar_first; - -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_remrequest:", rptr->re_he); -#endif - - if (rptr->re_he.h_name) - (void)free(rptr->re_he.h_name); - if (s = rptr->re_he.h_aliases) - for (; *s; s++) - (void)free(*s); - if (rptr->re_rinfo.ri_ptr) - (void)free(rptr->re_rinfo.ri_ptr); - (void)free(rptr); - - return 0; -} - - -/* - * ar_make_request - * - * Create a DNS query recorded for the request being made and place it on the - * current list awaiting replies. Initialization of the record with set - * values should also be done. - */ -static struct reslist *ar_make_request(resi) -register struct resinfo *resi; -{ - register struct reslist *rptr; - register struct resinfo *rp; - - rptr = (struct reslist *)calloc(1, sizeof(struct reslist)); - rp = &rptr->re_rinfo; - - rptr->re_next = NULL; /* where NULL is non-zero ;) */ - rptr->re_sentat = time(NULL); - rptr->re_retries = _res.retry; - rptr->re_sends = 1; - rptr->re_resend = 1; - rptr->re_timeout = rptr->re_sentat + _res.retrans; - rptr->re_he.h_name = NULL; - rptr->re_he.h_addrtype = AF_INET; - rptr->re_he.h_aliases[0] = NULL; - rp->ri_ptr = resi->ri_ptr; - rp->ri_size = resi->ri_size; - - (void)ar_add_request(rptr); - - return rptr; -} - - -/* - * ar_timeout - * - * Remove queries from the list which have been there too long without - * being resolved. - */ -long ar_timeout(now, info, size) -time_t now; -char *info; -int size; -{ - register struct reslist *rptr, *r2ptr; - register long next = 0; - - for (rptr = ar_first, r2ptr = NULL; rptr; rptr = r2ptr) - { - r2ptr = rptr->re_next; - if (now >= rptr->re_timeout) - { - /* - * If the timeout for the query has been exceeded, - * then resend the query if we still have some - * 'retry credit' and reset the timeout. If we have - * used it all up, then remove the request. - */ - if (--rptr->re_retries <= 0) - { - ar_reinfo.re_timeouts++; - if (info && rptr->re_rinfo.ri_ptr) - bcopy(rptr->re_rinfo.ri_ptr, info, - MIN(rptr->re_rinfo.ri_size, - size)); - (void)ar_remrequest(rptr); - return now; - } - else - { - rptr->re_sends++; - rptr->re_sentat = now; - rptr->re_timeout = now + _res.retrans; - (void)ar_resend_query(rptr); - } - } - if (!next || rptr->re_timeout < next) - next = rptr->re_timeout; - } - return next; -} - - -/* - * ar_send_res_msg - * - * When sending queries to nameservers listed in the resolv.conf file, - * don't send a query to every one, but increase the number sent linearly - * to match the number of resends. This increase only occurs if there are - * multiple nameserver entries in the resolv.conf file. - * The return value is the number of messages successfully sent to - * nameservers or -1 if no successful sends. - */ -static int ar_send_res_msg(msg, len, rcount) -char *msg; -int len, rcount; -{ - register int i; - int sent = 0; - - if (!msg) - return -1; - - rcount = (_res.nscount > rcount) ? rcount : _res.nscount; - if (_res.options & RES_PRIMARY) - rcount = 1; - - if (ar_vc) - { - ar_reinfo.re_sent++; - sent++; - if (write(ar_resfd, msg, len) == -1) - { - int errtmp = errno; - (void)close(ar_resfd); - errno = errtmp; - ar_resfd = -1; - } - } - else - for (i = 0; i < rcount; i++) - { - if (sendto(ar_resfd, msg, len, 0, - (struct sockaddr *)&(_res.NS_ADDR_LIST[i]), - sizeof(struct sockaddr_in)) == len) - { - ar_reinfo.re_sent++; - sent++; - } - } - return (sent) ? sent : -1; -} - - -/* - * ar_find_id - * - * find a dns query record by the id (id is determined by dn_mkquery) - */ -static struct reslist *ar_find_id(id) -int id; -{ - register struct reslist *rptr; - - for (rptr = ar_first; rptr; rptr = rptr->re_next) - if (rptr->re_id == id) - return rptr; - return NULL; -} - - -/* - * ar_delete - * - * Delete a request from the waiting list if it has a data pointer which - * matches the one passed. - */ -int ar_delete(ptr, size) -char *ptr; -int size; -{ - register struct reslist *rptr; - register struct reslist *r2ptr; - int removed = 0; - - for (rptr = ar_first; rptr; rptr = r2ptr) - { - r2ptr = rptr->re_next; - if (rptr->re_rinfo.ri_ptr && ptr && size && - bcmp(rptr->re_rinfo.ri_ptr, ptr, size) == 0) - { - (void)ar_remrequest(rptr); - removed++; - } - } - return removed; -} - - -/* - * ar_query_name - * - * generate a query based on class, type and name. - */ -static int ar_query_name(name, class, type, rptr) -char *name; -int class, type; -struct reslist *rptr; -{ - static char buf[MAXPACKET]; - int r,s,a; - HEADER *hptr; - - bzero(buf, sizeof(buf)); - r = res_mkquery(QUERY, name, class, type, NULL, 0, NULL, - buf, sizeof(buf)); - if (r <= 0) - { - h_errno = NO_RECOVERY; - return r; - } - hptr = (HEADER *)buf; - rptr->re_id = ntohs(hptr->id); - - s = ar_send_res_msg(buf, r, rptr->re_sends); - - if (s == -1) - { - h_errno = TRY_AGAIN; - return -1; - } - else - rptr->re_sent += s; - return 0; -} - - -/* - * ar_gethostbyname - * - * Replacement library function call to gethostbyname(). This one, however, - * doesn't return the record being looked up but just places the query in the - * queue to await answers. - */ -int ar_gethostbyname(name, info, size) -char *name; -char *info; -int size; -{ - char host[65]; - struct resinfo resi; - register struct resinfo *rp = &resi; - - if (size && info) - { - rp->ri_ptr = (char *)malloc(size); - bcopy(info, rp->ri_ptr, size); - rp->ri_size = size; - } - else - bzero((char *)rp, sizeof(resi)); - ar_reinfo.re_na_look++; - (void)strncpy(host, name, 64); - host[64] = '\0'; - - return (do_query_name(rp, host, NULL)); -} - - -static int do_query_name(resi, name, rptr) -struct resinfo *resi; -char *name; -register struct reslist *rptr; -{ - char hname[65]; - int len; - - len = strlen((char *)strncpy(hname, name, sizeof(hname)-1)); - - if (rptr && (hname[len-1] != '.')) - { - (void)strncat(hname, ar_dot, sizeof(hname)-len-1); - /* - * NOTE: The logical relationship between DNSRCH and DEFNAMES - * is implies. ie no DEFNAES, no DNSRCH. - */ - if (_res.options & (RES_DEFNAMES|RES_DNSRCH) == - (RES_DEFNAMES|RES_DNSRCH)) - { - if (_res.dnsrch[rptr->re_srch]) - (void)strncat(hname, _res.dnsrch[rptr->re_srch], - sizeof(hname) - ++len -1); - } - else if (_res.options & RES_DEFNAMES) - (void)strncat(hname, ar_domainname, sizeof(hname) - len -1); - } - - /* - * Store the name passed as the one to lookup and generate other host - * names to pass onto the nameserver(s) for lookups. - */ - if (!rptr) - { - rptr = ar_make_request(resi); - rptr->re_type = T_A; - (void)strncpy(rptr->re_name, name, sizeof(rptr->re_name)-1); - } - return (ar_query_name(hname, C_IN, T_A, rptr)); -} - - -/* - * ar_gethostbyaddr - * - * Generates a query for a given IP address. - */ -int ar_gethostbyaddr(addr, info, size) -char *addr; -char *info; -int size; -{ - struct resinfo resi; - register struct resinfo *rp = &resi; - - if (size && info) - { - rp->ri_ptr = (char *)malloc(size); - bcopy(info, rp->ri_ptr, size); - rp->ri_size = size; - } - else - bzero((char *)rp, sizeof(resi)); - ar_reinfo.re_nu_look++; - return (do_query_number(rp, addr, NULL)); -} - - -/* - * do_query_number - * - * Use this to do reverse IP# lookups. - */ -static int do_query_number(resi, numb, rptr) -struct resinfo *resi; -char *numb; -register struct reslist *rptr; -{ - register unsigned char *cp; - static char ipbuf[32]; - - /* - * Generate name in the "in-addr.arpa" domain. No addings bits to this - * name to get more names to query!. - */ - cp = (unsigned char *)numb; - (void)sprintf(ipbuf,"%u.%u.%u.%u.in-addr.arpa.", - (unsigned int)(cp[3]), (unsigned int)(cp[2]), - (unsigned int)(cp[1]), (unsigned int)(cp[0])); - - if (!rptr) - { - rptr = ar_make_request(resi); - rptr->re_type = T_PTR; - rptr->re_he.h_length = sizeof(struct in_addr); - bcopy(numb, (char *)&rptr->re_addr, rptr->re_he.h_length); - bcopy(numb, (char *)&rptr->re_he.h_addr_list[0].s_addr, - rptr->re_he.h_length); - } - return (ar_query_name(ipbuf, C_IN, T_PTR, rptr)); -} - - -/* - * ar_resent_query - * - * resends a query. - */ -static int ar_resend_query(rptr) -struct reslist *rptr; -{ - if (!rptr->re_resend) - return -1; - - switch(rptr->re_type) - { - case T_PTR: - ar_reinfo.re_resends++; - return do_query_number(NULL, &rptr->re_addr, rptr); - case T_A: - ar_reinfo.re_resends++; - return do_query_name(NULL, rptr->re_name, rptr); - default: - break; - } - - return -1; -} - - -/* - * ar_procanswer - * - * process an answer received from a nameserver. - */ -static int ar_procanswer(rptr, hptr, buf, eob) -struct reslist *rptr; -char *buf, *eob; -HEADER *hptr; -{ - char *cp, **alias, *s; - int class, type, dlen, len, ans = 0, n, i; - u_int32_t ttl, dr, *adr; - struct hent *hp; - - cp = buf + sizeof(HEADER); - adr = (u_int32_t *)rptr->re_he.h_addr_list; - - while (*adr) - adr++; - - alias = rptr->re_he.h_aliases; - while (*alias) - alias++; - - hp = &rptr->re_he; - - - /* - * Skip over the original question. - */ - while (hptr->qdcount-- > 0) - cp += dn_skipname(cp, eob) + QFIXEDSZ; - /* - * proccess each answer sent to us. blech. - */ - while (hptr->ancount-- > 0 && cp < eob) { - n = dn_expand(buf, eob, cp, ar_hostbuf, sizeof(ar_hostbuf)); - cp += n; - if (n <= 0) - return ans; - - ans++; - /* - * 'skip' past the general dns crap (ttl, class, etc) to get - * the pointer to the right spot. Some of thse are actually - * useful so its not a good idea to skip past in one big jump. - */ - type = (int)_getshort(cp); - cp += sizeof(short); - class = (int)_getshort(cp); - cp += sizeof(short); - ttl = (u_int32_t)_getlong(cp); - cp += sizeof(u_int32_t); - dlen = (int)_getshort(cp); - cp += sizeof(short); - rptr->re_type = type; - - switch(type) - { - case T_A : - rptr->re_he.h_length = dlen; - if (ans == 1) - rptr->re_he.h_addrtype=(class == C_IN) ? - AF_INET : AF_UNSPEC; - if (dlen != sizeof(dr)) - { - h_errno = TRY_AGAIN; - continue; - } - bcopy(cp, &dr, dlen); - *adr++ = dr; - *adr = 0; - cp += dlen; - len = strlen(ar_hostbuf); - if (!rptr->re_he.h_name) - { - rptr->re_he.h_name = (char *)malloc(len+1); - if (!rptr->re_he.h_name) - break; - (void)strcpy(rptr->re_he.h_name, ar_hostbuf); - } - break; - case T_PTR : - if ((n = dn_expand(buf, eob, cp, ar_hostbuf, - sizeof(ar_hostbuf) )) < 0) - { - cp += n; - continue; - } - cp += n; - len = strlen(ar_hostbuf)+1; - /* - * copy the returned hostname into the host name - * or alias field if there is a known hostname - * already. - */ - if (!rptr->re_he.h_name) - { - rptr->re_he.h_name = (char *)malloc(len); - if (!rptr->re_he.h_name) - break; - (void)strcpy(rptr->re_he.h_name, ar_hostbuf); - } - else - { - *alias = (char *)malloc(len); - if (!*alias) - return -1; - (void)strcpy(*alias++, ar_hostbuf); - *alias = NULL; - } - break; - case T_CNAME : - cp += dlen; - if (alias >= &(rptr->re_he.h_aliases[MAXALIASES-1])) - continue; - n = strlen(ar_hostbuf)+1; - *alias = (char *)malloc(n); - if (!*alias) - return -1; - (void)strcpy(*alias++, ar_hostbuf); - *alias = NULL; - break; - default : - break; - } - } - - return ans; -} - - -/* - * ar_answer - * - * Get an answer from a DNS server and process it. If a query is found to - * which no answer has been given to yet, copy its 'info' structure back - * to where "reip" points and return a pointer to the hostent structure. - */ -struct hostent *ar_answer(reip, size) -char *reip; -int size; -{ - static char ar_rcvbuf[sizeof(HEADER) + MAXPACKET]; - static struct hostent ar_host; - - register HEADER *hptr; - register struct reslist *rptr = NULL; - register struct hostent *hp; - register char **s; - unsigned long *adr; - int rc, i, n, a; - - rc = recv(ar_resfd, ar_rcvbuf, sizeof(ar_rcvbuf), 0); - if (rc <= 0) - goto getres_err; - - ar_reinfo.re_replies++; - hptr = (HEADER *)ar_rcvbuf; - /* - * convert things to be in the right order. - */ - hptr->id = ntohs(hptr->id); - hptr->ancount = ntohs(hptr->ancount); - hptr->arcount = ntohs(hptr->arcount); - hptr->nscount = ntohs(hptr->nscount); - hptr->qdcount = ntohs(hptr->qdcount); - /* - * response for an id which we have already received an answer for - * just ignore this response. - */ - rptr = ar_find_id(hptr->id); - if (!rptr) - goto getres_err; - - if ((hptr->rcode != NOERROR) || (hptr->ancount == 0)) - { - switch (hptr->rcode) - { - case NXDOMAIN: - h_errno = HOST_NOT_FOUND; - break; - case SERVFAIL: - h_errno = TRY_AGAIN; - break; - case NOERROR: - h_errno = NO_DATA; - break; - case FORMERR: - case NOTIMP: - case REFUSED: - default: - h_errno = NO_RECOVERY; - break; - } - ar_reinfo.re_errors++; - /* - ** If a bad error was returned, we stop here and dont send - ** send any more (no retries granted). - */ - if (h_errno != TRY_AGAIN) - { - rptr->re_resend = 0; - rptr->re_retries = 0; - } - goto getres_err; - } - - a = ar_procanswer(rptr, hptr, ar_rcvbuf, ar_rcvbuf+rc); - - if ((rptr->re_type == T_PTR) && (_res.options & RES_CHECKPTR)) - { - /* - * For reverse lookups on IP#'s, lookup the name that is given - * for the ip# and return with that as the official result. - * -avalon - */ - rptr->re_type = T_A; - /* - * Clean out the list of addresses already set, even though - * there should only be one :) - */ - adr = (unsigned long *)rptr->re_he.h_addr_list; - while (*adr) - *adr++ = 0L; - /* - * Lookup the name that we were given for the ip# - */ - ar_reinfo.re_na_look++; - (void)strncpy(rptr->re_name, rptr->re_he.h_name, - sizeof(rptr->re_name)-1); - rptr->re_he.h_name = NULL; - rptr->re_retries = _res.retry; - rptr->re_sends = 1; - rptr->re_resend = 1; - rptr->re_he.h_name = NULL; - ar_reinfo.re_na_look++; - (void)ar_query_name(rptr->re_name, C_IN, T_A, rptr); - return NULL; - } - - if (reip && rptr->re_rinfo.ri_ptr && size) - bcopy(rptr->re_rinfo.ri_ptr, reip, - MIN(rptr->re_rinfo.ri_size, size)); - /* - * Clean up structure from previous usage. - */ - hp = &ar_host; -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: previous usage", hp); -#endif - - if (hp->h_name) - (void)free(hp->h_name); - if (s = hp->h_aliases) - { - while (*s) - (void)free(*s++); - (void)free(hp->h_aliases); - } - if (s = hp->h_addr_list) - { - /* - * Only free once since we allocated space for - * address in one big chunk. - */ - (void)free(*s); - (void)free(hp->h_addr_list); - } - bzero((char *)hp, sizeof(*hp)); - - /* - * Setup and copy details for the structure we return a pointer to. - */ - hp->h_addrtype = AF_INET; - hp->h_length = sizeof(struct in_addr); - if(rptr->re_he.h_name) - { - hp->h_name = (char *)malloc(strlen(rptr->re_he.h_name)+1); - if(!hp->h_name) - { -#ifdef ARLIB_DEBUG - fprintf(stderr, "no memory for hostname\n"); -#endif - h_errno = TRY_AGAIN; - goto getres_err; - } - (void)strcpy(hp->h_name, rptr->re_he.h_name); - } -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: (snap) store name", hp); -#endif - - /* - * Count IP#'s. - */ - for (i = 0, n = 0; i < MAXADDRS; i++, n++) - if (!rptr->re_he.h_addr_list[i].s_addr) - break; - s = hp->h_addr_list = (char **)malloc((n + 1) * sizeof(char *)); - if (n) - { - *s = (char *)malloc(n * sizeof(struct in_addr)); - if(!*s) - { -#ifdef ARLIB_DEBUG - fprintf(stderr, "no memory for IP#'s (%d)\n", n); -#endif - h_errno = TRY_AGAIN; - goto getres_err; - } - bcopy((char *)&rptr->re_he.h_addr_list[0].s_addr, *s, - sizeof(struct in_addr)); - s++; - for (i = 1; i < n; i++, s++) - { - *s = hp->h_addr + i * sizeof(struct in_addr); - bcopy((char *)&rptr->re_he.h_addr_list[i].s_addr, *s, - sizeof(struct in_addr)); - } - } - *s = NULL; -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: (snap) store IP#'s", hp); -#endif - - /* - * Count CNAMEs - */ - for (i = 0, n = 0; i < MAXADDRS; i++, n++) - if (!rptr->re_he.h_aliases[i]) - break; - s = hp->h_aliases = (char **)malloc((n + 1) * sizeof(char *)); - if (!s) - { -#ifdef ARLIB_DEBUG - fprintf(stderr, "no memory for aliases (%d)\n", n); -#endif - h_errno = TRY_AGAIN; - goto getres_err; - } - for (i = 0; i < n; i++) - { - *s++ = rptr->re_he.h_aliases[i]; - rptr->re_he.h_aliases[i] = NULL; - } - *s = NULL; -#ifdef ARLIB_DEBUG - ar_dump_hostent("ar_answer: (snap) store CNAMEs", hp); - ar_dump_hostent("ar_answer: new one", hp); -#endif - - if (a > 0) - (void)ar_remrequest(rptr); - else - if (!rptr->re_sent) - (void)ar_remrequest(rptr); - return hp; - -getres_err: - if (rptr) - { - if (reip && rptr->re_rinfo.ri_ptr && size) - bcopy(rptr->re_rinfo.ri_ptr, reip, - MIN(rptr->re_rinfo.ri_size, size)); - if ((h_errno != TRY_AGAIN) && - (_res.options & (RES_DNSRCH|RES_DEFNAMES) == - (RES_DNSRCH|RES_DEFNAMES) )) - if (_res.dnsrch[rptr->re_srch]) - { - rptr->re_retries = _res.retry; - rptr->re_sends = 1; - rptr->re_resend = 1; - (void)ar_resend_query(rptr); - rptr->re_srch++; - } - return NULL; - } - return NULL; -} - - -#ifdef ARLIB_DEBUG -void ar_dump_hostent(prefix, hp) -char *prefix; -struct hostent *hp; -{ - register char **s; - - fflush(stdout); - - fprintf(stderr, "%s\n", prefix); - fprintf(stderr, " hp %p\n", hp); - fprintf(stderr, " h_name %p '%s'\n", - hp->h_name, hp->h_name); - if (s = hp->h_aliases) - { - fprintf(stderr, " h_aliases %p\n", - hp->h_aliases); - while (*s) - { - fprintf(stderr, " element %p\n", *s); - s++; - } - } - if (s = hp->h_addr_list) - { - fprintf(stderr, " h_addr_list %p\n", - hp->h_addr_list); - while (*s) - { - fprintf(stderr, " element %p\n", *s); - s++; - } - } - - fflush(stderr); -} - - -void ar_dump_reslist(FILE* fp) -{ - register struct reslist *rptr; - int c; - - c = 0; - for (rptr = ar_first; rptr; rptr = rptr->re_next) - { - fprintf(fp, "%4d [%p] %4d [%p]: %s\n", rptr->re_id, rptr, - *(rptr->re_rinfo.ri_ptr), rptr->re_rinfo.ri_ptr, - rptr->re_name); - } -} -#endif diff --git a/contrib/ntp/arlib/arlib.h b/contrib/ntp/arlib/arlib.h deleted file mode 100644 index a295b8862..000000000 --- a/contrib/ntp/arlib/arlib.h +++ /dev/null @@ -1,29 +0,0 @@ -/* - * arlib.h (C)opyright 1992 Darren Reed. - */ - -#define ARES_INITLIST 1 -#define ARES_CALLINIT 2 -#define ARES_INITSOCK 4 -#define ARES_INITDEBG 8 -#define ARES_INITCACH 16 - -#ifdef __STDC__ -extern struct hostent *ar_answer(char *, int); -extern void ar_close(); -extern int ar_delete(char *, int); -extern int ar_gethostbyname(char *, char *, int); -extern int ar_gethostbyaddr(char *, char *, int); -extern int ar_init(int); -extern int ar_open(); -extern long ar_timeout(time_t, char *, int); -#else -extern struct hostent *ar_answer(); -extern void ar_close(); -extern int ar_delete(); -extern int ar_gethostbyname(); -extern int ar_gethostbyaddr(); -extern int ar_init(); -extern int ar_open(); -extern long ar_timeout(); -#endif diff --git a/contrib/ntp/arlib/arplib.h b/contrib/ntp/arlib/arplib.h deleted file mode 100644 index 8f905d104..000000000 --- a/contrib/ntp/arlib/arplib.h +++ /dev/null @@ -1,45 +0,0 @@ -/* - * arplib.h (C)opyright 1992 Darren Reed. - */ - -#define MAXPACKET 1024 -#define MAXALIASES 35 -#define MAXADDRS 35 - -#define RES_CHECKPTR 0x0400 - -struct hent { - char *h_name; /* official name of host */ - char *h_aliases[MAXALIASES]; /* alias list */ - int h_addrtype; /* host address type */ - int h_length; /* length of address */ - /* list of addresses from name server */ - struct in_addr h_addr_list[MAXADDRS]; -#define h_addr h_addr_list[0] /* address, for backward compatiblity */ -}; - -struct resinfo { - char *ri_ptr; - int ri_size; -}; - -struct reslist { - int re_id; - char re_type; - char re_retries; - char re_resend; /* send flag. 0 == dont resend */ - char re_sends; - char re_srch; - int re_sent; - u_long re_sentat; - u_long re_timeout; - struct in_addr re_addr; - struct resinfo re_rinfo; - struct hent re_he; - struct reslist *re_next, *re_prev; - char re_name[65]; -}; - -#ifndef MIN -#define MIN(a,b) ((a) > (b) ? (b) : (a)) -#endif diff --git a/contrib/ntp/arlib/configure b/contrib/ntp/arlib/configure deleted file mode 100755 index 95e8a849e..000000000 --- a/contrib/ntp/arlib/configure +++ /dev/null @@ -1,5008 +0,0 @@ -#! /bin/sh -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.65. -# -# -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# -# -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi -" - as_required="as_fn_return () { (exit \$1); } -as_fn_success () { as_fn_return 0; } -as_fn_failure () { as_fn_return 1; } -as_fn_ret_success () { return 0; } -as_fn_ret_failure () { return 1; } - -exitcode=0 -as_fn_success || { exitcode=1; echo as_fn_success failed.; } -as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } -as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } -as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : - -else - exitcode=1; echo positional parameters were not saved. -fi -test x\$exitcode = x0 || exit 1" - as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO - as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO - eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && - test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1" - if (eval "$as_required") 2>/dev/null; then : - as_have_required=yes -else - as_have_required=no -fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : - -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - as_found=: - case $as_dir in #( - /*) - for as_base in sh bash ksh sh5; do - # Try only shells that exist, to save several forks. - as_shell=$as_dir/$as_base - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : - CONFIG_SHELL=$as_shell as_have_required=yes - if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : - break 2 -fi -fi - done;; - esac - as_found=false -done -$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi; } -IFS=$as_save_IFS - - - if test "x$CONFIG_SHELL" != x; then : - # We cannot yet assume a decent shell, so we have to provide a - # neutralization value for shells without unset; and this also - # works around shells that cannot unset nonexistent variables. - BASH_ENV=/dev/null - ENV=/dev/null - (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV - export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} -fi - - if test x$as_have_required = xno; then : - $as_echo "$0: This script requires a shell more modern than all" - $as_echo "$0: the shells that I found on your system." - if test x${ZSH_VERSION+set} = xset ; then - $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" - $as_echo "$0: be upgraded to zsh 4.3.4 or later." - else - $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, -$0: including any error possibly output before this -$0: message. Then install a modern shell, or manually run -$0: the script under such a shell if you do have one." - fi - exit 1 -fi -fi -fi -SHELL=${CONFIG_SHELL-/bin/sh} -export SHELL -# Unset more variables known to interfere with behavior of common tools. -CLICOLOR_FORCE= GREP_OPTIONS= -unset CLICOLOR_FORCE GREP_OPTIONS - -## --------------------- ## -## M4sh Shell Functions. ## -## --------------------- ## -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. -as_fn_error () -{ - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 - fi - $as_echo "$as_me: error: $1" >&2 - as_fn_exit $as_status -} # as_fn_error - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - - as_lineno_1=$LINENO as_lineno_1a=$LINENO - as_lineno_2=$LINENO as_lineno_2a=$LINENO - eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && - test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { - # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } - - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -p' - fi -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -test -n "$DJDIR" || exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= - -# Identity of this package. -PACKAGE_NAME= -PACKAGE_TARNAME= -PACKAGE_VERSION= -PACKAGE_STRING= -PACKAGE_BUGREPORT= -PACKAGE_URL= - -ac_unique_file="arlib.c" -ac_subst_vars='am__EXEEXT_FALSE -am__EXEEXT_TRUE -LTLIBOBJS -LIBOBJS -RANLIB -am__fastdepCC_FALSE -am__fastdepCC_TRUE -CCDEPMODE -AMDEPBACKSLASH -AMDEP_FALSE -AMDEP_TRUE -am__quote -am__include -DEPDIR -OBJEXT -EXEEXT -ac_ct_CC -CPPFLAGS -LDFLAGS -CFLAGS -CC -am__untar -am__tar -AMTAR -am__leading_dot -SET_MAKE -AWK -mkdir_p -MKDIR_P -INSTALL_STRIP_PROGRAM -STRIP -install_sh -MAKEINFO -AUTOHEADER -AUTOMAKE -AUTOCONF -ACLOCAL -VERSION -PACKAGE -CYGPATH_W -am__isrc -INSTALL_DATA -INSTALL_SCRIPT -INSTALL_PROGRAM -target_alias -host_alias -build_alias -LIBS -ECHO_T -ECHO_N -ECHO_C -DEFS -mandir -localedir -libdir -psdir -pdfdir -dvidir -htmldir -infodir -docdir -oldincludedir -includedir -localstatedir -sharedstatedir -sysconfdir -datadir -datarootdir -libexecdir -sbindir -bindir -program_transform_name -prefix -exec_prefix -PACKAGE_URL -PACKAGE_BUGREPORT -PACKAGE_STRING -PACKAGE_VERSION -PACKAGE_TARNAME -PACKAGE_NAME -PATH_SEPARATOR -SHELL' -ac_subst_files='' -ac_user_opts=' -enable_option_checking -enable_dependency_tracking -' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS' - - -# Initialize some variables set by options. -ac_init_help= -ac_init_version=false -ac_unrecognized_opts= -ac_unrecognized_sep= -# The variables have the same names as the options, with -# dashes changed to underlines. -cache_file=/dev/null -exec_prefix=NONE -no_create= -no_recursion= -prefix=NONE -program_prefix=NONE -program_suffix=NONE -program_transform_name=s,x,x, -silent= -site= -srcdir= -verbose= -x_includes=NONE -x_libraries=NONE - -# Installation directory options. -# These are left unexpanded so users can "make install exec_prefix=/foo" -# and all the variables that are supposed to be based on exec_prefix -# by default will actually change. -# Use braces instead of parens because sh, perl, etc. also accept them. -# (The list follows the same order as the GNU Coding Standards.) -bindir='${exec_prefix}/bin' -sbindir='${exec_prefix}/sbin' -libexecdir='${exec_prefix}/libexec' -datarootdir='${prefix}/share' -datadir='${datarootdir}' -sysconfdir='${prefix}/etc' -sharedstatedir='${prefix}/com' -localstatedir='${prefix}/var' -includedir='${prefix}/include' -oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE}' -infodir='${datarootdir}/info' -htmldir='${docdir}' -dvidir='${docdir}' -pdfdir='${docdir}' -psdir='${docdir}' -libdir='${exec_prefix}/lib' -localedir='${datarootdir}/locale' -mandir='${datarootdir}/man' - -ac_prev= -ac_dashdash= -for ac_option -do - # If the previous option needs an argument, assign it. - if test -n "$ac_prev"; then - eval $ac_prev=\$ac_option - ac_prev= - continue - fi - - case $ac_option in - *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *) ac_optarg=yes ;; - esac - - # Accept the important Cygnus configure options, so we can diagnose typos. - - case $ac_dashdash$ac_option in - --) - ac_dashdash=yes ;; - - -bindir | --bindir | --bindi | --bind | --bin | --bi) - ac_prev=bindir ;; - -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir=$ac_optarg ;; - - -build | --build | --buil | --bui | --bu) - ac_prev=build_alias ;; - -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build_alias=$ac_optarg ;; - - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file=$ac_optarg ;; - - --config-cache | -C) - cache_file=config.cache ;; - - -datadir | --datadir | --datadi | --datad) - ac_prev=datadir ;; - -datadir=* | --datadir=* | --datadi=* | --datad=*) - datadir=$ac_optarg ;; - - -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ - | --dataroo | --dataro | --datar) - ac_prev=datarootdir ;; - -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ - | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) - datarootdir=$ac_optarg ;; - - -disable-* | --disable-*) - ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=no ;; - - -docdir | --docdir | --docdi | --doc | --do) - ac_prev=docdir ;; - -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) - docdir=$ac_optarg ;; - - -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) - ac_prev=dvidir ;; - -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) - dvidir=$ac_optarg ;; - - -enable-* | --enable-*) - ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=\$ac_optarg ;; - - -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ - | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ - | --exec | --exe | --ex) - ac_prev=exec_prefix ;; - -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ - | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ - | --exec=* | --exe=* | --ex=*) - exec_prefix=$ac_optarg ;; - - -gas | --gas | --ga | --g) - # Obsolete; use --with-gas. - with_gas=yes ;; - - -help | --help | --hel | --he | -h) - ac_init_help=long ;; - -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) - ac_init_help=recursive ;; - -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) - ac_init_help=short ;; - - -host | --host | --hos | --ho) - ac_prev=host_alias ;; - -host=* | --host=* | --hos=* | --ho=*) - host_alias=$ac_optarg ;; - - -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) - ac_prev=htmldir ;; - -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ - | --ht=*) - htmldir=$ac_optarg ;; - - -includedir | --includedir | --includedi | --included | --include \ - | --includ | --inclu | --incl | --inc) - ac_prev=includedir ;; - -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ - | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir=$ac_optarg ;; - - -infodir | --infodir | --infodi | --infod | --info | --inf) - ac_prev=infodir ;; - -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir=$ac_optarg ;; - - -libdir | --libdir | --libdi | --libd) - ac_prev=libdir ;; - -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir=$ac_optarg ;; - - -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ - | --libexe | --libex | --libe) - ac_prev=libexecdir ;; - -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ - | --libexe=* | --libex=* | --libe=*) - libexecdir=$ac_optarg ;; - - -localedir | --localedir | --localedi | --localed | --locale) - ac_prev=localedir ;; - -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) - localedir=$ac_optarg ;; - - -localstatedir | --localstatedir | --localstatedi | --localstated \ - | --localstate | --localstat | --localsta | --localst | --locals) - ac_prev=localstatedir ;; - -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ - | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) - localstatedir=$ac_optarg ;; - - -mandir | --mandir | --mandi | --mand | --man | --ma | --m) - ac_prev=mandir ;; - -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir=$ac_optarg ;; - - -nfp | --nfp | --nf) - # Obsolete; use --without-fp. - with_fp=no ;; - - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c | -n) - no_create=yes ;; - - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) - no_recursion=yes ;; - - -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ - | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ - | --oldin | --oldi | --old | --ol | --o) - ac_prev=oldincludedir ;; - -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ - | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ - | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir=$ac_optarg ;; - - -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) - ac_prev=prefix ;; - -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix=$ac_optarg ;; - - -program-prefix | --program-prefix | --program-prefi | --program-pref \ - | --program-pre | --program-pr | --program-p) - ac_prev=program_prefix ;; - -program-prefix=* | --program-prefix=* | --program-prefi=* \ - | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix=$ac_optarg ;; - - -program-suffix | --program-suffix | --program-suffi | --program-suff \ - | --program-suf | --program-su | --program-s) - ac_prev=program_suffix ;; - -program-suffix=* | --program-suffix=* | --program-suffi=* \ - | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix=$ac_optarg ;; - - -program-transform-name | --program-transform-name \ - | --program-transform-nam | --program-transform-na \ - | --program-transform-n | --program-transform- \ - | --program-transform | --program-transfor \ - | --program-transfo | --program-transf \ - | --program-trans | --program-tran \ - | --progr-tra | --program-tr | --program-t) - ac_prev=program_transform_name ;; - -program-transform-name=* | --program-transform-name=* \ - | --program-transform-nam=* | --program-transform-na=* \ - | --program-transform-n=* | --program-transform-=* \ - | --program-transform=* | --program-transfor=* \ - | --program-transfo=* | --program-transf=* \ - | --program-trans=* | --program-tran=* \ - | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name=$ac_optarg ;; - - -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) - ac_prev=pdfdir ;; - -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) - pdfdir=$ac_optarg ;; - - -psdir | --psdir | --psdi | --psd | --ps) - ac_prev=psdir ;; - -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) - psdir=$ac_optarg ;; - - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - silent=yes ;; - - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) - ac_prev=sbindir ;; - -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ - | --sbi=* | --sb=*) - sbindir=$ac_optarg ;; - - -sharedstatedir | --sharedstatedir | --sharedstatedi \ - | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ - | --sharedst | --shareds | --shared | --share | --shar \ - | --sha | --sh) - ac_prev=sharedstatedir ;; - -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ - | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ - | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ - | --sha=* | --sh=*) - sharedstatedir=$ac_optarg ;; - - -site | --site | --sit) - ac_prev=site ;; - -site=* | --site=* | --sit=*) - site=$ac_optarg ;; - - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir=$ac_optarg ;; - - -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ - | --syscon | --sysco | --sysc | --sys | --sy) - ac_prev=sysconfdir ;; - -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ - | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir=$ac_optarg ;; - - -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target_alias ;; - -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target_alias=$ac_optarg ;; - - -v | -verbose | --verbose | --verbos | --verbo | --verb) - verbose=yes ;; - - -version | --version | --versio | --versi | --vers | -V) - ac_init_version=: ;; - - -with-* | --with-*) - ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=\$ac_optarg ;; - - -without-* | --without-*) - ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" - ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=no ;; - - --x) - # Obsolete; use --with-x. - with_x=yes ;; - - -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ - | --x-incl | --x-inc | --x-in | --x-i) - ac_prev=x_includes ;; - -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ - | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes=$ac_optarg ;; - - -x-libraries | --x-libraries | --x-librarie | --x-librari \ - | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) - ac_prev=x_libraries ;; - -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ - | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries=$ac_optarg ;; - - -*) as_fn_error "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information." - ;; - - *=*) - ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` - # Reject names that are not valid shell variable names. - case $ac_envvar in #( - '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error "invalid variable name: \`$ac_envvar'" ;; - esac - eval $ac_envvar=\$ac_optarg - export $ac_envvar ;; - - *) - # FIXME: should be removed in autoconf 3.0. - $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 - expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} - ;; - - esac -done - -if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error "missing argument to $ac_option" -fi - -if test -n "$ac_unrecognized_opts"; then - case $enable_option_checking in - no) ;; - fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; - *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; - esac -fi - -# Check all directory arguments for consistency. -for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ - datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir -do - eval ac_val=\$$ac_var - # Remove trailing slashes. - case $ac_val in - */ ) - ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` - eval $ac_var=\$ac_val;; - esac - # Be sure to have absolute directory names. - case $ac_val in - [\\/$]* | ?:[\\/]* ) continue;; - NONE | '' ) case $ac_var in *prefix ) continue;; esac;; - esac - as_fn_error "expected an absolute directory name for --$ac_var: $ac_val" -done - -# There might be people who depend on the old broken behavior: `$host' -# used to hold the argument of --host etc. -# FIXME: To remove some day. -build=$build_alias -host=$host_alias -target=$target_alias - -# FIXME: To remove some day. -if test "x$host_alias" != x; then - if test "x$build_alias" = x; then - cross_compiling=maybe - $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. - If a cross compiler is detected then cross compile mode will be used." >&2 - elif test "x$build_alias" != "x$host_alias"; then - cross_compiling=yes - fi -fi - -ac_tool_prefix= -test -n "$host_alias" && ac_tool_prefix=$host_alias- - -test "$silent" = yes && exec 6>/dev/null - - -ac_pwd=`pwd` && test -n "$ac_pwd" && -ac_ls_di=`ls -di .` && -ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error "working directory cannot be determined" -test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error "pwd does not report name of working directory" - - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$as_myself" || -$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_myself" : 'X\(//\)[^/]' \| \ - X"$as_myself" : 'X\(//\)$' \| \ - X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_myself" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - srcdir=$ac_confdir - if test ! -r "$srcdir/$ac_unique_file"; then - srcdir=.. - fi -else - ac_srcdir_defaulted=no -fi -if test ! -r "$srcdir/$ac_unique_file"; then - test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" -fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" -ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg" - pwd)` -# When building in place, set srcdir=. -if test "$ac_abs_confdir" = "$ac_pwd"; then - srcdir=. -fi -# Remove unnecessary trailing slashes from srcdir. -# Double slashes in file names in object file debugging info -# mess up M-x gdb in Emacs. -case $srcdir in -*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; -esac -for ac_var in $ac_precious_vars; do - eval ac_env_${ac_var}_set=\${${ac_var}+set} - eval ac_env_${ac_var}_value=\$${ac_var} - eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} - eval ac_cv_env_${ac_var}_value=\$${ac_var} -done - -# -# Report the --help message. -# -if test "$ac_init_help" = "long"; then - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat <<_ACEOF -\`configure' configures this package to adapt to many kinds of systems. - -Usage: $0 [OPTION]... [VAR=VALUE]... - -To assign environment variables (e.g., CC, CFLAGS...), specify them as -VAR=VALUE. See below for descriptions of some of the useful variables. - -Defaults for the options are specified in brackets. - -Configuration: - -h, --help display this help and exit - --help=short display options specific to this package - --help=recursive display the short help of all the included packages - -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking...' messages - --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' - -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] - -Installation directories: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] - -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. - -For better control, use the options below. - -Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] -_ACEOF - - cat <<\_ACEOF - -Program names: - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM run sed PROGRAM on installed program names -_ACEOF -fi - -if test -n "$ac_init_help"; then - - cat <<\_ACEOF - -Optional Features: - --disable-option-checking ignore unrecognized --enable/--with options - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors - -Some influential environment variables: - CC C compiler command - CFLAGS C compiler flags - LDFLAGS linker flags, e.g. -L if you have libraries in a - nonstandard directory - LIBS libraries to pass to the linker, e.g. -l - CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if - you have headers in a nonstandard directory - -Use these variables to override the choices made by `configure' or to help -it to find libraries and programs with nonstandard names/locations. - -Report bugs to the package provider. -_ACEOF -ac_status=$? -fi - -if test "$ac_init_help" = "recursive"; then - # If there are subdirs, report their specific --help. - for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || - { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || - continue - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - cd "$ac_dir" || { ac_status=$?; continue; } - # Check for guested configure. - if test -f "$ac_srcdir/configure.gnu"; then - echo && - $SHELL "$ac_srcdir/configure.gnu" --help=recursive - elif test -f "$ac_srcdir/configure"; then - echo && - $SHELL "$ac_srcdir/configure" --help=recursive - else - $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 - fi || ac_status=$? - cd "$ac_pwd" || { ac_status=$?; break; } - done -fi - -test -n "$ac_init_help" && exit $ac_status -if $ac_init_version; then - cat <<\_ACEOF -configure -generated by GNU Autoconf 2.65 - -Copyright (C) 2009 Free Software Foundation, Inc. -This configure script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it. -_ACEOF - exit -fi - -## ------------------------ ## -## Autoconf initialization. ## -## ------------------------ ## - -# ac_fn_c_try_compile LINENO -# -------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - as_fn_set_status $ac_retval - -} # ac_fn_c_try_compile - -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me -#endif - -int -main () -{ -return $2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - -} # ac_fn_c_check_func - -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - -} # ac_fn_c_check_type -cat >config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. - -It was created by $as_me, which was -generated by GNU Autoconf 2.65. Invocation command line was - - $ $0 $@ - -_ACEOF -exec 5>>config.log -{ -cat <<_ASUNAME -## --------- ## -## Platform. ## -## --------- ## - -hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` - -/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` -/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` -/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` -/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` - -_ASUNAME - -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - $as_echo "PATH: $as_dir" - done -IFS=$as_save_IFS - -} >&5 - -cat >&5 <<_ACEOF - - -## ----------- ## -## Core tests. ## -## ----------- ## - -_ACEOF - - -# Keep a trace of the command line. -# Strip out --no-create and --no-recursion so they do not pile up. -# Strip out --silent because we don't want to record it for future runs. -# Also quote any args containing shell meta-characters. -# Make two passes to allow for proper duplicate-argument suppression. -ac_configure_args= -ac_configure_args0= -ac_configure_args1= -ac_must_keep_next=false -for ac_pass in 1 2 -do - for ac_arg - do - case $ac_arg in - -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - continue ;; - *\'*) - ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - case $ac_pass in - 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; - 2) - as_fn_append ac_configure_args1 " '$ac_arg'" - if test $ac_must_keep_next = true; then - ac_must_keep_next=false # Got value, back to normal. - else - case $ac_arg in - *=* | --config-cache | -C | -disable-* | --disable-* \ - | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ - | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ - | -with-* | --with-* | -without-* | --without-* | --x) - case "$ac_configure_args0 " in - "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; - esac - ;; - -* ) ac_must_keep_next=true ;; - esac - fi - as_fn_append ac_configure_args " '$ac_arg'" - ;; - esac - done -done -{ ac_configure_args0=; unset ac_configure_args0;} -{ ac_configure_args1=; unset ac_configure_args1;} - -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# WARNING: Use '\'' to represent an apostrophe within the trap. -# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. -trap 'exit_status=$? - # Save into config.log some information that might help in debugging. - { - echo - - cat <<\_ASBOX -## ---------------- ## -## Cache variables. ## -## ---------------- ## -_ASBOX - echo - # The following way of writing the cache mishandles newlines in values, -( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - sed -n \ - "s/'\''/'\''\\\\'\'''\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" - ;; #( - *) - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) - echo - - cat <<\_ASBOX -## ----------------- ## -## Output variables. ## -## ----------------- ## -_ASBOX - echo - for ac_var in $ac_subst_vars - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - - if test -n "$ac_subst_files"; then - cat <<\_ASBOX -## ------------------- ## -## File substitutions. ## -## ------------------- ## -_ASBOX - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - cat <<\_ASBOX -## ----------- ## -## confdefs.h. ## -## ----------- ## -_ASBOX - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - $as_echo "$as_me: caught signal $ac_signal" - $as_echo "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && - rm -f -r conftest* confdefs* conf$$* $ac_clean_files && - exit $exit_status -' 0 -for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal -done -ac_signal=0 - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -f -r conftest* confdefs.h - -$as_echo "/* confdefs.h */" > confdefs.h - -# Predefined preprocessor variables. - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_NAME "$PACKAGE_NAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_TARNAME "$PACKAGE_TARNAME" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION "$PACKAGE_VERSION" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_STRING "$PACKAGE_STRING" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" -_ACEOF - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_URL "$PACKAGE_URL" -_ACEOF - - -# Let the site file select an alternate cache file if it wants to. -# Prefer an explicitly selected file to automatically selected ones. -ac_site_file1=NONE -ac_site_file2=NONE -if test -n "$CONFIG_SITE"; then - ac_site_file1=$CONFIG_SITE -elif test "x$prefix" != xNONE; then - ac_site_file1=$prefix/share/config.site - ac_site_file2=$prefix/etc/config.site -else - ac_site_file1=$ac_default_prefix/share/config.site - ac_site_file2=$ac_default_prefix/etc/config.site -fi -for ac_site_file in "$ac_site_file1" "$ac_site_file2" -do - test "x$ac_site_file" = xNONE && continue - if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 -$as_echo "$as_me: loading site script $ac_site_file" >&6;} - sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" - fi -done - -if test -r "$cache_file"; then - # Some versions of bash will fail to source /dev/null (special files - # actually), so we avoid doing that. DJGPP emulates it as a regular file. - if test /dev/null != "$cache_file" && test -f "$cache_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 -$as_echo "$as_me: loading cache $cache_file" >&6;} - case $cache_file in - [\\/]* | ?:[\\/]* ) . "$cache_file";; - *) . "./$cache_file";; - esac - fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 -$as_echo "$as_me: creating cache $cache_file" >&6;} - >$cache_file -fi - -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - # differences in whitespace do not lead to failure. - ac_old_val_w=`echo x $ac_old_val` - ac_new_val_w=`echo x $ac_new_val` - if test "$ac_old_val_w" != "$ac_new_val_w"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 -$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - ac_cache_corrupted=: - else - { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 -$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} - eval $ac_var=\$ac_old_val - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 -$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 -$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} - fi;; - esac - # Pass precious variables to config.status. - if test "$ac_new_set" = set; then - case $ac_new_val in - *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; - *) ac_arg=$ac_var=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) as_fn_append ac_configure_args " '$ac_arg'" ;; - esac - fi -done -if $ac_cache_corrupted; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 -$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 -fi -## -------------------- ## -## Main body of script. ## -## -------------------- ## - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -am__api_version='1.11' - -ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do - for ac_t in install-sh install.sh shtool; do - if test -f "$ac_dir/$ac_t"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/$ac_t -c" - break 2 - fi - done -done -if test -z "$ac_aux_dir"; then - as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 -fi - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. - - -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -# Reject install programs that cannot install multiple files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 -$as_echo_n "checking for a BSD-compatible install... " >&6; } -if test -z "$INSTALL"; then -if test "${ac_cv_path_install+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in #(( - ./ | .// | /[cC]/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then - if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - rm -rf conftest.one conftest.two conftest.dir - echo one > conftest.one - echo two > conftest.two - mkdir conftest.dir - if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && - test -s conftest.one && test -s conftest.two && - test -s conftest.dir/conftest.one && - test -s conftest.dir/conftest.two - then - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - fi - done - done - ;; -esac - - done -IFS=$as_save_IFS - -rm -rf conftest.one conftest.two conftest.dir - -fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 -$as_echo "$INSTALL" >&6; } - -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' - -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' - -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 -$as_echo_n "checking whether build environment is sane... " >&6; } -# Just in case -sleep 1 -echo timestamp > conftest.file -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[\\\"\#\$\&\'\`$am_lf]*) - as_fn_error "unsafe absolute working directory name" "$LINENO" 5;; -esac -case $srcdir in - *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; -esac - -# Do `set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error "ls -t appears to fail. Make sure there is not a broken -alias in your environment" "$LINENO" 5 - fi - - test "$2" = conftest.file - ) -then - # Ok. - : -else - as_fn_error "newly created file is older than distributed files! -Check your system clock" "$LINENO" 5 -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -test "$program_prefix" != NONE && - program_transform_name="s&^&$program_prefix&;$program_transform_name" -# Use a double $ so make ignores it. -test "$program_suffix" != NONE && - program_transform_name="s&\$&$program_suffix&;$program_transform_name" -# Double any \ or $. -# By default was `s,x,x', remove it if useless. -ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' -program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` - -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` - -if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac -fi -# Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " -else - am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} -fi - -if test x"${install_sh}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi - -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. -if test "$cross_compiling" != no; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 -$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } -if test -z "$MKDIR_P"; then - if test "${ac_cv_path_mkdir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in mkdir gmkdir; do - for ac_exec_ext in '' $ac_executable_extensions; do - { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue - case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( - 'mkdir (GNU coreutils) '* | \ - 'mkdir (coreutils) '* | \ - 'mkdir (fileutils) '4.1*) - ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext - break 3;; - esac - done - done - done -IFS=$as_save_IFS - -fi - - test -d ./--version && rmdir ./--version - if test "${ac_cv_path_mkdir+set}" = set; then - MKDIR_P="$ac_cv_path_mkdir -p" - else - # As a last resort, use the slow shell script. Don't cache a - # value for MKDIR_P within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - MKDIR_P="$ac_install_sh -d" - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 -$as_echo "$MKDIR_P" >&6; } - -mkdir_p="$MKDIR_P" -case $mkdir_p in - [\\/$]* | ?:[\\/]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac - -for ac_prog in gawk mawk nawk awk -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AWK+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AWK"; then - ac_cv_prog_AWK="$AWK" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AWK="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AWK=$ac_cv_prog_AWK -if test -n "$AWK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -$as_echo "$AWK" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$AWK" && break -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } -set x ${MAKE-make} -ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - cat >conftest.make <<\_ACEOF -SHELL = /bin/sh -all: - @echo '@@@%%%=$(MAKE)=@@@%%%' -_ACEOF -# GNU make sometimes prints "make[1]: Entering...", which would confuse us. -case `${MAKE-make} -f conftest.make 2>/dev/null` in - *@@@%%%=?*=@@@%%%*) - eval ac_cv_prog_make_${ac_make}_set=yes;; - *) - eval ac_cv_prog_make_${ac_make}_set=no;; -esac -rm -f conftest.make -fi -if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - SET_MAKE= -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - SET_MAKE="MAKE=${MAKE-make}" -fi - -rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null - -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - am__isrc=' -I$(srcdir)' - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 - fi -fi - -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' - else - CYGPATH_W=echo - fi -fi - - -# Define the identity of the package. - PACKAGE=arlib - VERSION=1.0 - - -cat >>confdefs.h <<_ACEOF -#define PACKAGE "$PACKAGE" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define VERSION "$VERSION" -_ACEOF - -# Some tools Automake needs. - -ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} - - -AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} - - -AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} - - -AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} - - -MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} - -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -# Always define AMTAR for backward compatibility. - -AMTAR=${AMTAR-"${am_missing_run}tar"} - -am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' - - - - - - -#AM_CONFIG_HEADER([config.h]) - -# Checks for programs. -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_CC="gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi - - -test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "no acceptable C compiler found in \$PATH -See \`config.log' for more details." "$LINENO" 5; } - -# Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" -# Try to create an executable without -o first, disregard a.out. -# It will help us diagnose broken compilers, and finding out an intuition -# of exeext. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 -$as_echo_n "checking whether the C compiler works... " >&6; } -ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` - -# The possible output files: -ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" - -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { { ac_try="$ac_link_default" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link_default") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' -# in a Makefile. We should not override ac_cv_exeext if it was cached, -# so that the user can short-circuit this test for compilers unknown to -# Autoconf. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; - then :; else - ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - fi - # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' - # argument, so we may need to know it at that point already. - # Even if this section looks crufty: it has the advantage of - # actually working. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else - ac_file='' -fi -if test -z "$ac_file"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "C compiler cannot create executables -See \`config.log' for more details." "$LINENO" 5; }; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 -$as_echo_n "checking for C compiler default output file name... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 -$as_echo "$ac_file" >&6; } -ac_exeext=$ac_cv_exeext - -rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 -$as_echo_n "checking for suffix of executables... " >&6; } -if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) break;; - esac -done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details." "$LINENO" 5; } -fi -rm -f conftest conftest$ac_cv_exeext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 -$as_echo "$ac_cv_exeext" >&6; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -FILE *f = fopen ("conftest.out", "w"); - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -ac_clean_files="$ac_clean_files conftest.out" -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 -$as_echo_n "checking whether we are cross compiling... " >&6; } -if test "$cross_compiling" != yes; then - { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if { ac_try='./conftest$ac_cv_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - cross_compiling=no - else - if test "$cross_compiling" = maybe; then - cross_compiling=yes - else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details." "$LINENO" 5; } - fi - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -$as_echo "$cross_compiling" >&6; } - -rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out -ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 -$as_echo_n "checking for suffix of object files... " >&6; } -if test "${ac_cv_objext+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - for ac_file in conftest.o conftest.obj conftest.*; do - test -f "$ac_file" || continue; - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac -done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of object files: cannot compile -See \`config.log' for more details." "$LINENO" 5; } -fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -$as_echo "$ac_cv_objext" >&6; } -OBJEXT=$ac_cv_objext -ac_objext=$OBJEXT -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_compiler_gnu=yes -else - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -else - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -DEPDIR="${am__leading_dot}deps" - -ac_config_commands="$ac_config_commands depfiles" - - -am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo this is the am__doit target -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 -$as_echo_n "checking for style of include used by $am_make... " >&6; } -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 -$as_echo "$_am_result" >&6; } -rm -f confinc confmf - -# Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then : - enableval=$enable_dependency_tracking; -fi - -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' -fi - if test "x$enable_dependency_tracking" != xno; then - AMDEP_TRUE= - AMDEP_FALSE='#' -else - AMDEP_TRUE='#' - AMDEP_FALSE= -fi - - - -depcc="$CC" am_compiler_list= - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with `-c' and `-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } -CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then - am__fastdepCC_TRUE= - am__fastdepCC_FALSE='#' -else - am__fastdepCC_TRUE='#' - am__fastdepCC_FALSE= -fi - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi - - -# Checks for libraries. -ac_fn_c_check_func "$LINENO" "gethostent" "ac_cv_func_gethostent" -if test "x$ac_cv_func_gethostent" = x""yes; then : - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostent in -lnsl" >&5 -$as_echo_n "checking for gethostent in -lnsl... " >&6; } -if test "${ac_cv_lib_nsl_gethostent+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lnsl -lsocket $LIBS" - - -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char gethostent (); -int -main () -{ -return gethostent (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_nsl_gethostent=yes -else - ac_cv_lib_nsl_gethostent=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostent" >&5 -$as_echo "$ac_cv_lib_nsl_gethostent" >&6; } -if test "x$ac_cv_lib_nsl_gethostent" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBNSL 1 -_ACEOF - - LIBS="-lnsl $LIBS" - -fi - -fi - -ac_fn_c_check_func "$LINENO" "setsockopt" "ac_cv_func_setsockopt" -if test "x$ac_cv_func_setsockopt" = x""yes; then : - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setsockopt in -lsocket" >&5 -$as_echo_n "checking for setsockopt in -lsocket... " >&6; } -if test "${ac_cv_lib_socket_setsockopt+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsocket $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char setsockopt (); -int -main () -{ -return setsockopt (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_socket_setsockopt=yes -else - ac_cv_lib_socket_setsockopt=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_setsockopt" >&5 -$as_echo "$ac_cv_lib_socket_setsockopt" >&6; } -if test "x$ac_cv_lib_socket_setsockopt" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBSOCKET 1 -_ACEOF - - LIBS="-lsocket $LIBS" - -fi - -fi - -ac_fn_c_check_func "$LINENO" "res_init" "ac_cv_func_res_init" -if test "x$ac_cv_func_res_init" = x""yes; then : - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init in -lresolv" >&5 -$as_echo_n "checking for res_init in -lresolv... " >&6; } -if test "${ac_cv_lib_resolv_res_init+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lresolv $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char res_init (); -int -main () -{ -return res_init (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_resolv_res_init=yes -else - ac_cv_lib_resolv_res_init=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_init" >&5 -$as_echo "$ac_cv_lib_resolv_res_init" >&6; } -if test "x$ac_cv_lib_resolv_res_init" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBRESOLV 1 -_ACEOF - - LIBS="-lresolv $LIBS" - -fi - -fi - - -# Checks for header files. - -# Checks for typedefs, structures, and compiler characteristics. - -ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" " -#include -#include -" -if test "x$ac_cv_type_u_int32_t" = x""yes; then : - -else - -$as_echo "#define u_int32_t unsigned int" >>confdefs.h - -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for name of NS address list" >&5 -$as_echo_n "checking for name of NS address list... " >&6; } -if test "${ac_cv_var_ns_addr_list+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans='' -# Normal -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include -#include -#include -#include -int -main () -{ - return sizeof(_res.nsaddr_list); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ans=nsaddr_list -else - # Ultrix -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include -#include -#include -#include -int -main () -{ - return sizeof(_res.ns_list); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ans=ns_list -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - case "$ans" in - '') { $as_echo "$as_me:${as_lineno-$LINENO}: result: ???" >&5 -$as_echo "???" >&6; } - as_fn_error "Can't find nameserver address list in _res" "$LINENO" 5 - ;; - esac - ac_cv_var_ns_addr_list=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_ns_addr_list" >&5 -$as_echo "$ac_cv_var_ns_addr_list" >&6; } - -cat >>confdefs.h <<_ACEOF -#define NS_ADDR_LIST $ans -_ACEOF - - -# Checks for library functions. - -ac_config_files="$ac_config_files Makefile" - -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - test "x$cache_file" != "x/dev/null" && - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' - -# Transform confdefs.h into DEFS. -# Protect against shell expansion while executing Makefile rules. -# Protect against Makefile macro expansion. -# -# If the first sed substitution is executed (which looks for macros that -# take arguments), then branch to the quote section. Otherwise, -# look for a macro that doesn't take arguments. -ac_script=' -:mline -/\\$/{ - N - s,\\\n,, - b mline -} -t clear -:clear -s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g -t quote -s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g -t quote -b any -:quote -s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g -s/\[/\\&/g -s/\]/\\&/g -s/\$/$$/g -H -:any -${ - g - s/^\n// - s/\n/ /g - p -} -' -DEFS=`sed -n "$ac_script" confdefs.h` - - -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs - -LTLIBOBJS=$ac_ltlibobjs - - - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi - -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - as_fn_error "conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi - -: ${CONFIG_STATUS=./config.status} -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. - -debug=false -ac_cs_recheck=false -ac_cs_silent=false - -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi - -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - -# Find who we are. Look in the path if we contain no directory separator. -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - - -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. -as_fn_error () -{ - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 - fi - $as_echo "$as_me: error: $1" >&2 - as_fn_exit $as_status -} # as_fn_error - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -p' - fi -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by $as_me, which was -generated by GNU Autoconf 2.65. Invocation command line was - - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ - -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" - -_ACEOF - -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac - - - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_commands="$ac_config_commands" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. - -Usage: $0 [OPTION]... [TAG]... - - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - -Configuration files: -$config_files - -Configuration commands: -$config_commands - -Report bugs to the package provider." - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" -ac_cs_version="\\ -config.status -configured by $0, generated by GNU Autoconf 2.65, - with options \\"\$ac_cs_config\\" - -Copyright (C) 2009 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." - -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h | --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - - # This is an error. - -*) as_fn_error "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; - - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; - - esac - shift -done - -ac_configure_extra_args= - -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - - *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done - - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands -fi - -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= - trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. - -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -n "$tmp" && test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 - -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then - - -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\r' -else - ac_cs_awk_cr=$ac_cr -fi - -echo 'BEGIN {' >"$tmp/subs1.awk" && -_ACEOF - - -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 - - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" - -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } - - print line -} - -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ - || as_fn_error "could not setup config files machinery" "$LINENO" 5 -_ACEOF - -# VPATH may cause trouble with some makes, so we remove $(srcdir), -# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=/{ -s/:*\$(srcdir):*/:/ -s/:*\${srcdir}:*/:/ -s/:*@srcdir@:*/:/ -s/^\([^=]*=[ ]*\):*/\1/ -s/:*$// -s/^[^=]*=[ ]*$// -}' -fi - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" - - -eval set X " :F $CONFIG_FILES :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done - - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac - - case $ac_tag in - *:-:* | *:-) cat >"$tmp/stdin" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; - esac - - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&2;} - - rm -f "$tmp/stdin" - case $ac_file in - -) cat "$tmp/out" && rm -f "$tmp/out";; - *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; - esac \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - ;; - - - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac - - - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Autoconf 2.62 quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir=$dirpart/$fdir; as_fn_mkdir_p - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} - ;; - - esac -done # for ac_tag - - -as_fn_exit 0 -_ACEOF -ac_clean_files=$ac_clean_files_save - -test $ac_write_fail = 0 || - as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 - - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit $? -fi -if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 -$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} -fi - diff --git a/contrib/ntp/arlib/configure.in b/contrib/ntp/arlib/configure.in deleted file mode 100644 index 509e23ddb..000000000 --- a/contrib/ntp/arlib/configure.in +++ /dev/null @@ -1,57 +0,0 @@ -# Process this file with autoconf to produce a configure script. -AC_INIT -AM_INIT_AUTOMAKE(arlib, 1.0) -AC_CONFIG_SRCDIR([arlib.c]) -#AM_CONFIG_HEADER([config.h]) - -# Checks for programs. -AC_PROG_CC -AC_PROG_RANLIB - -# Checks for libraries. -AC_CHECK_FUNC(gethostent, , AC_CHECK_LIB(nsl, gethostent, , , -lsocket)) -AC_CHECK_FUNC(setsockopt, , AC_CHECK_LIB(socket, setsockopt)) -AC_CHECK_FUNC(res_init, , AC_CHECK_LIB(resolv, res_init)) - -# Checks for header files. -dnl AC_CHECK_HEADERS([errno.h fcntl.h netdb.h netinet/in.h strings.h sys/socket.h sys/time.h]) - -# Checks for typedefs, structures, and compiler characteristics. -dnl AC_HEADER_TIME - -AC_CHECK_TYPE(u_int32_t, , - [AC_DEFINE(u_int32_t, [unsigned int], [Unsigned 32-bit type])],[ -#include -#include ]) - -AC_CACHE_CHECK([for name of NS address list], [ac_cv_var_ns_addr_list], - [ans='' -# Normal -AC_TRY_COMPILE([ -#include -#include -#include -#include ], [ return sizeof(_res.nsaddr_list);], -[ans=nsaddr_list], -[# Ultrix -AC_TRY_COMPILE([ -#include -#include -#include -#include ], [ return sizeof(_res.ns_list);], -[ans=ns_list])]) - case "$ans" in - '') AC_MSG_RESULT([???]) - AC_MSG_ERROR([Can't find nameserver address list in _res]) - ;; - esac - ac_cv_var_ns_addr_list=$ans]) -AC_DEFINE_UNQUOTED(NS_ADDR_LIST, $ans, [The name of the NS address list in _res]) - -# Checks for library functions. -dnl AC_HEADER_STDC -dnl AC_FUNC_MALLOC -dnl AC_CHECK_FUNCS([bzero inet_ntoa select socket]) - -AC_CONFIG_FILES([Makefile]) -AC_OUTPUT diff --git a/contrib/ntp/arlib/install-sh b/contrib/ntp/arlib/install-sh deleted file mode 100755 index 4d4a9519e..000000000 --- a/contrib/ntp/arlib/install-sh +++ /dev/null @@ -1,323 +0,0 @@ -#!/bin/sh -# install - install a program, script, or datafile - -scriptversion=2005-05-14.22 - -# This originates from X11R5 (mit/util/scripts/install.sh), which was -# later released in X11R6 (xc/config/util/install.sh) with the -# following copyright and license. -# -# Copyright (C) 1994 X Consortium -# -# Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the "Software"), to -# deal in the Software without restriction, including without limitation the -# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -# sell copies of the Software, and to permit persons to whom the Software is -# furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in -# all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- -# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# -# Except as contained in this notice, the name of the X Consortium shall not -# be used in advertising or otherwise to promote the sale, use or other deal- -# ings in this Software without prior written authorization from the X Consor- -# tium. -# -# -# FSF changes to this file are in the public domain. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# `make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. It can only install one file at a time, a restriction -# shared with many OS's install programs. - -# set DOITPROG to echo to test this script - -# Don't use :- since 4.3BSD and earlier shells don't like it. -doit="${DOITPROG-}" - -# put in absolute paths if you don't have them in your path; or use env. vars. - -mvprog="${MVPROG-mv}" -cpprog="${CPPROG-cp}" -chmodprog="${CHMODPROG-chmod}" -chownprog="${CHOWNPROG-chown}" -chgrpprog="${CHGRPPROG-chgrp}" -stripprog="${STRIPPROG-strip}" -rmprog="${RMPROG-rm}" -mkdirprog="${MKDIRPROG-mkdir}" - -chmodcmd="$chmodprog 0755" -chowncmd= -chgrpcmd= -stripcmd= -rmcmd="$rmprog -f" -mvcmd="$mvprog" -src= -dst= -dir_arg= -dstarg= -no_target_directory= - -usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE - or: $0 [OPTION]... SRCFILES... DIRECTORY - or: $0 [OPTION]... -t DIRECTORY SRCFILES... - or: $0 [OPTION]... -d DIRECTORIES... - -In the 1st form, copy SRCFILE to DSTFILE. -In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. -In the 4th, create DIRECTORIES. - -Options: --c (ignored) --d create directories instead of installing files. --g GROUP $chgrpprog installed files to GROUP. --m MODE $chmodprog installed files to MODE. --o USER $chownprog installed files to USER. --s $stripprog installed files. --t DIRECTORY install into DIRECTORY. --T report an error if DSTFILE is a directory. ---help display this help and exit. ---version display version info and exit. - -Environment variables override the default commands: - CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG -" - -while test -n "$1"; do - case $1 in - -c) shift - continue;; - - -d) dir_arg=true - shift - continue;; - - -g) chgrpcmd="$chgrpprog $2" - shift - shift - continue;; - - --help) echo "$usage"; exit $?;; - - -m) chmodcmd="$chmodprog $2" - shift - shift - continue;; - - -o) chowncmd="$chownprog $2" - shift - shift - continue;; - - -s) stripcmd=$stripprog - shift - continue;; - - -t) dstarg=$2 - shift - shift - continue;; - - -T) no_target_directory=true - shift - continue;; - - --version) echo "$0 $scriptversion"; exit $?;; - - *) # When -d is used, all remaining arguments are directories to create. - # When -t is used, the destination is already specified. - test -n "$dir_arg$dstarg" && break - # Otherwise, the last argument is the destination. Remove it from $@. - for arg - do - if test -n "$dstarg"; then - # $@ is not empty: it contains at least $arg. - set fnord "$@" "$dstarg" - shift # fnord - fi - shift # arg - dstarg=$arg - done - break;; - esac -done - -if test -z "$1"; then - if test -z "$dir_arg"; then - echo "$0: no input file specified." >&2 - exit 1 - fi - # It's OK to call `install-sh -d' without argument. - # This can happen when creating conditional directories. - exit 0 -fi - -for src -do - # Protect names starting with `-'. - case $src in - -*) src=./$src ;; - esac - - if test -n "$dir_arg"; then - dst=$src - src= - - if test -d "$dst"; then - mkdircmd=: - chmodcmd= - else - mkdircmd=$mkdirprog - fi - else - # Waiting for this to be detected by the "$cpprog $src $dsttmp" command - # might cause directories to be created, which would be especially bad - # if $src (and thus $dsttmp) contains '*'. - if test ! -f "$src" && test ! -d "$src"; then - echo "$0: $src does not exist." >&2 - exit 1 - fi - - if test -z "$dstarg"; then - echo "$0: no destination specified." >&2 - exit 1 - fi - - dst=$dstarg - # Protect names starting with `-'. - case $dst in - -*) dst=./$dst ;; - esac - - # If destination is a directory, append the input filename; won't work - # if double slashes aren't ignored. - if test -d "$dst"; then - if test -n "$no_target_directory"; then - echo "$0: $dstarg: Is a directory" >&2 - exit 1 - fi - dst=$dst/`basename "$src"` - fi - fi - - # This sed command emulates the dirname command. - dstdir=`echo "$dst" | sed -e 's,/*$,,;s,[^/]*$,,;s,/*$,,;s,^$,.,'` - - # Make sure that the destination directory exists. - - # Skip lots of stat calls in the usual case. - if test ! -d "$dstdir"; then - defaultIFS=' - ' - IFS="${IFS-$defaultIFS}" - - oIFS=$IFS - # Some sh's can't handle IFS=/ for some reason. - IFS='%' - set x `echo "$dstdir" | sed -e 's@/@%@g' -e 's@^%@/@'` - shift - IFS=$oIFS - - pathcomp= - - while test $# -ne 0 ; do - pathcomp=$pathcomp$1 - shift - if test ! -d "$pathcomp"; then - $mkdirprog "$pathcomp" - # mkdir can fail with a `File exist' error in case several - # install-sh are creating the directory concurrently. This - # is OK. - test -d "$pathcomp" || exit - fi - pathcomp=$pathcomp/ - done - fi - - if test -n "$dir_arg"; then - $doit $mkdircmd "$dst" \ - && { test -z "$chowncmd" || $doit $chowncmd "$dst"; } \ - && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } \ - && { test -z "$stripcmd" || $doit $stripcmd "$dst"; } \ - && { test -z "$chmodcmd" || $doit $chmodcmd "$dst"; } - - else - dstfile=`basename "$dst"` - - # Make a couple of temp file names in the proper directory. - dsttmp=$dstdir/_inst.$$_ - rmtmp=$dstdir/_rm.$$_ - - # Trap to clean up those temp files at exit. - trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 - trap '(exit $?); exit' 1 2 13 15 - - # Copy the file name to the temp name. - $doit $cpprog "$src" "$dsttmp" && - - # and set any options; do chmod last to preserve setuid bits. - # - # If any of these fail, we abort the whole thing. If we want to - # ignore errors from any of these, just make sure not to ignore - # errors from the above "$doit $cpprog $src $dsttmp" command. - # - { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \ - && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \ - && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \ - && { test -z "$chmodcmd" || $doit $chmodcmd "$dsttmp"; } && - - # Now rename the file to the real destination. - { $doit $mvcmd -f "$dsttmp" "$dstdir/$dstfile" 2>/dev/null \ - || { - # The rename failed, perhaps because mv can't rename something else - # to itself, or perhaps because mv is so ancient that it does not - # support -f. - - # Now remove or move aside any old file at destination location. - # We try this two ways since rm can't unlink itself on some - # systems and the destination file might be busy for other - # reasons. In this case, the final cleanup might fail but the new - # file should still install successfully. - { - if test -f "$dstdir/$dstfile"; then - $doit $rmcmd -f "$dstdir/$dstfile" 2>/dev/null \ - || $doit $mvcmd -f "$dstdir/$dstfile" "$rmtmp" 2>/dev/null \ - || { - echo "$0: cannot unlink or rename $dstdir/$dstfile" >&2 - (exit 1); exit 1 - } - else - : - fi - } && - - # Now rename the file to the real destination. - $doit $mvcmd "$dsttmp" "$dstdir/$dstfile" - } - } - fi || { (exit 1); exit 1; } -done - -# The final little trick to "correctly" pass the exit status to the exit trap. -{ - (exit 0); exit 0 -} - -# Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-end: "$" -# End: diff --git a/contrib/ntp/arlib/sample.c b/contrib/ntp/arlib/sample.c deleted file mode 100644 index 83db6a842..000000000 --- a/contrib/ntp/arlib/sample.c +++ /dev/null @@ -1,143 +0,0 @@ -#include -#include -#include -#include -#include -#include -#include -#include "arlib.h" - -#ifndef lint -static char sccsid[] = "@(#)sample.c 1.1 12/21/92 (C)1992 Darren Reed. ASYNC DNS"; -#endif - -char line[512]; - -int lookup = 0, seq = 0; -long expire = 0; - -main() -{ - struct in_addr adr; - struct timeval tv2; - fd_set rd; - long now; - char *s; - int afd, nfd, pid = getpid(), del; - - afd = ar_init(ARES_INITLIST|ARES_CALLINIT|ARES_INITSOCK); - - (void)printf("afd = %d pid = %d\n",afd, pid); - - while (1) - { - (void)printf("Host =>"); - (void)fflush(stdout); - *line = '\0'; - FD_ZERO(&rd); - FD_SET(0,&rd); - FD_SET(afd,&rd); - now = time(NULL); - if (expire >= now) - { - tv2.tv_usec = 0; - tv2.tv_sec = expire - now; - nfd = select(FD_SETSIZE, &rd, NULL, NULL, &tv2); - } - else - nfd = select(FD_SETSIZE, &rd, NULL, NULL, NULL); - - if (FD_ISSET(0, &rd)) - { - if (!fgets(line, sizeof(line) - 1, stdin)) - exit(0); - if (s = index(line, '\n')) - *s = '\0'; - } - - if (isalpha(*line)) - { - (void)printf("Asking about [%s] #%d.\n",line, ++seq); - (void)ar_gethostbyname(line, (char *)&seq, - sizeof(seq)); - lookup++; - } - else if (isdigit(*line)) - { - (void)printf("Asking about IP#[%s] #%d.\n", - line, ++seq); - adr.s_addr = inet_addr(line); - (void)ar_gethostbyaddr(&adr, (char *)&seq, - sizeof(seq)); - lookup++; - } - if (lookup) - (void)printf("Waiting for answer:\n"); - if (FD_ISSET(afd, &rd)) - (void)waitonlookup(afd); - del = 0; - expire = ar_timeout(time(NULL), &del, sizeof(del)); - if (del) - { - (void)fprintf(stderr,"#%d failed\n", del); - lookup--; - } - } -} - -printhostent(hp) -struct hostent *hp; -{ - struct in_addr ip; - int i; - - (void)printf("hname = %s\n", hp->h_name); - for (i = 0; hp->h_aliases[i]; i++) - (void)printf("alias %d = %s\n", i+1, hp->h_aliases[i]); - for (i = 0; hp->h_addr_list[i]; i++) - { - bcopy(hp->h_addr_list[i], (char *)&ip, sizeof(ip)); - (void)printf("IP# %d = %s\n", i+1, inet_ntoa(ip)); - } -} - -int waitonlookup(afd) -int afd; -{ - struct timeval delay; - struct hostent *hp; - fd_set rd; - long now; - int nfd, del; - -waitloop: - FD_ZERO(&rd); - now = time(NULL); - if (expire >= now) - delay.tv_sec = expire - now; - else - delay.tv_sec = 1; - delay.tv_usec = 0; - FD_SET(afd, &rd); - FD_SET(0, &rd); - - nfd = select(FD_SETSIZE, &rd, 0, 0, &delay); - if (nfd == 0) - return 0; - else if (FD_ISSET(afd, &rd)) - { - del = 0; - hp = ar_answer(&del, sizeof(del)); - - (void)printf("hp=%x seq=%d\n",hp,del); - if (hp) - { - (void)printhostent(hp); - if (!--lookup) - return 1; - } - } - if (FD_ISSET(0, &rd)) - return 2; - return 0; -} diff --git a/contrib/ntp/bincheck.mf b/contrib/ntp/bincheck.mf index c67827dde..67f461f8c 100644 --- a/contrib/ntp/bincheck.mf +++ b/contrib/ntp/bincheck.mf @@ -3,13 +3,15 @@ # subdir to warn folks if there is another version there. install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ - || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ - test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ + done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ done # diff --git a/contrib/ntp/bootstrap b/contrib/ntp/bootstrap index 1a5aff06d..dcba5c7fa 100755 --- a/contrib/ntp/bootstrap +++ b/contrib/ntp/bootstrap @@ -3,6 +3,8 @@ # This "bootstrap" script performs various pre-autoreconf actions # that are required after pulling fresh sources from the repository. # +# --force is supported and will be passed to autoreconf +# # NOTE: THE NTP VERSION NUMBER COMES FROM packageinfo.sh # # all other instances of it anywhere in the source base have propagated @@ -27,7 +29,8 @@ set -e -scripts/genver +(cd sntp && ../scripts/build/genver) || { + echo scripts/build/genver failed ; exit 1; } # autoreconf says: # The environment variables AUTOCONF, AUTOHEADER, AUTOMAKE, ACLOCAL, @@ -35,18 +38,19 @@ scripts/genver AUTORECONF=${AUTORECONF:-autoreconf} -case `hostname` in - pogo.udel.edu) - if fgrep -q 4.2.4 version.m4; then - AUTOCONF=autoconf-2.59 - AUTOHEADER=autoheader-2.59 - AUTOMAKE=automake-1.9 - ACLOCAL=aclocal-1.9 - export AUTOCONF AUTOHEADER AUTOMAKE ACLOCAL - fi - ;; -esac - +# case `hostname` in +# pogo.udel.edu) +# if fgrep -q 4.2.4 sntp/m4/version.m4; then +# AUTOCONF=autoconf-2.59 +# AUTOHEADER=autoheader-2.59 +# AUTOMAKE=automake-1.9 +# ACLOCAL=aclocal-1.9 +# export AUTOCONF AUTOHEADER AUTOMAKE ACLOCAL +# fi +# ;; +# esac + +## Old way # 20060629: HMS: Let's try checking in libopts and the autogen-generated files ## The copy for ntp... #rm -rf libopts* @@ -61,55 +65,119 @@ esac # tar -xvf - # mv libopts-*.*.* libopts ) -def_files=`find [B-Za-z]* -type f -name '*.def' -print | fgrep -v /SCCS/` -prog_opt_files=`grep -l '^prog.name' $def_files` +## EOOld way -## AutoGen stuff +## Unity test runners +# the ruby generator must be older than the test files. +# the test files must be older than the runner files. -#incdir=${PWD}/include +runner_files=`find [B-Za-z]* -type f -name 'run-*' -print | fgrep -v /SCCS/` +l= +lt= +lr= +for f in ${runner_files} +do + fb=`echo $f | sed -e 's/run-//'` + lt="$lt $fb" + lr="$lr $f" # Yes, lr and runner_files are eventually the same +done +touch $lt +echo "Touching <$lt>" +sleep 1 +touch $lr +echo "Touching <$lr>" -#for f in ${prog_opt_files} -#do -# ( cd $(dirname ${f}) -# echo "Running autogen on $f..." -# autogen -L${incdir} $(basename ${f}) -# ) || exit 1 -#done +## EOUnity test runners -## Non-AutoGen stuff +## AutoGen stuff -for i in autogen-version.def version.def -do - cmp -s include/$i sntp/$i || cp -p include/$i sntp/$i -done +def_files=`find [B-Za-z]* -type f -name '*.def' -print | fgrep -v /SCCS/` +prog_opt_files=`grep -l '^prog.name' $def_files` # touch the stuff generated by the opt files +l= +lh= +li= for f in ${prog_opt_files} do - f=`echo $f | sed -e 's/-opts.def//'` - l= - for i in `ls -1 $f*` + f=`echo $f | sed -e 's/-opts.def//' -e 's/.def//'` + dfi=`dirname $f` + dfi=`echo $dfi | sed -e 's:$:/invoke-*:'` + for i in `ls -1 $f* $dfi` do case "$i" in - *.c|*.h|*.1|*.texi|*.menu) + *invoke-*) + li="$li $i" + ;; + *.c|*.h|*.[1-9]*man|*.[1-9]*mdoc|*.man.in|*.mdoc.in|*-opts|*.texi|*.menu) l="$l $i" ;; + *.html) + lh="$lh $i" + ;; esac done - case "$l" in - '') ;; - *) touch $l - ;; - esac done +case "$l" in + '') ;; + *) touch $l + echo "Touching <$l>" + sleep 1 + ;; +esac +case "$li" in + '') ;; + *) touch $li + echo "Touching <$li>" + sleep 1 + ;; +esac +case "$lh" in + '') ;; + *) touch $lh + echo "Touching <$lh>" + ;; +esac ## EOAutoGen stuff +## Yacc/bison files + +# Yacc/bison files ntp_parser.[ch] so we don't require the tool if +# ntp_parser.y hasn't been updated. At the same time, keyword-gen-utd +# and ntp_keyword.h which are derived from ntp_parser.h and +# keyword-gen.c. + +touch ntpd/ntp_parser.[ch] ntpd/keyword-gen-utd ntpd/ntp_keyword.h + +## EOYacc/bison files + cp bincheck.mf sntp/ +cp depsver.mf sntp/ -${AUTORECONF} -i -v +${AUTORECONF} -i -v "$@" +# Because some systems do not support 'test a -nt b' +case `ls -1tr config.h.in aclocal.m4 | tail -1` in + aclocal.m4) touch config.h.in ;; +esac +case `ls -1tr sntp/config.h.in sntp/aclocal.m4 | tail -1` in + sntp/aclocal.m4) touch sntp/config.h.in ;; +esac +case `ls -1tr sntp/libevent/config.h.in sntp/libevent/aclocal.m4 | tail -1` in + sntp/libevent/aclocal.m4) touch sntp/libevent/config.h.in ;; +esac + +# DH: 20110118: Due to our workaround for the AM_COND_IF bug that was +# triggering the buggy recursive autoreconf, we can once again use a +# single autoreconf invocation. See +# http://debbugs.gnu.org/cgi/bugreport.cgi?bug=7860 +# DH: 20101120: We are back to a single copy of libopts, and +# once again it seems we need to run autoreconf in sntp after +# the top-level run to get a correct sntp/libopts/Makefile.in. +# To reduce redundancy, the top-level autoreconf uses --no-recursive. +# # HMS: 20060618: Now that we use separate copies of libopts # we should only need the previous line. # @@ -117,4 +185,4 @@ ${AUTORECONF} -i -v ## we get the correct srcdir path in sntp/libopts/Makefile.in #rm -rf sntp/autom4te.cache # -#(cd sntp && ${AUTORECONF} -i -v) +# (cd sntp && ${AUTORECONF} -i -v "$@") diff --git a/contrib/ntp/build b/contrib/ntp/build index 2a65d8678..15fe39afa 100755 --- a/contrib/ntp/build +++ b/contrib/ntp/build @@ -18,8 +18,8 @@ case "$1" in echo "This is <`pwd`>" echo "SIG is <$SIG>" echo "KEY is <$KEY>" - exit 1 - ;; + exit 1 + ;; esac ;; *) @@ -30,26 +30,58 @@ esac #set -e #set -x -CVO=`./config.guess` +if [ ! -r sntp/libevent/build-aux/config.guess ] ; then + echo "Error: bootstrap required." 1>&2 && exit 1 +fi + +# sntp/scripts/cvo.sh invokes config.guess, and we want it to use the copy +# in the build-aux directory if there's not another config.guess earlier +# on the path, so we invoke it using env to append to the PATH. + +CVO=`env PATH="$PATH:./sntp/libevent/build-aux" sntp/scripts/cvo.sh @cvo@` case "$CVO" in + *-*-*-*) echo "sntp/scripts/cvo.sh returned <$CVO>, which makes no sense to me." + exit 1 + ;; *-*-*) ;; - *) echo "config.guess returned <$CVO>, which makes no sense to me." + *) echo "sntp/scripts/cvo.sh returned <$CVO>, which makes no sense to me." exit 1 ;; esac -case "$IAM" in - *.udel.edu) - BDIR=A.$MYNAME - CONFIG_ARGS="$CONFIG_ARGS --enable-local-libopts" - case "$CVO" in - *-*-ultrix*) - CONFIG_ARGS="$CONFIG_ARGS --with-libregex=/usr/local" +case "$NTP_BDIR" in + '') + case "$IAM" in + *.ntp.org) + NTP_BDIR=host ;; - esac + *.udel.edu) + NTP_BDIR=host + # HMS: --enable-local-libopts is the default now... + #CONFIG_ARGS="$CONFIG_ARGS --enable-local-libopts" + case "$CVO" in + *-*-ultrix*) + CONFIG_ARGS="$CONFIG_ARGS --with-libregex=/usr/local" + ;; + esac + ;; + *) + NTP_BDIR=cvo + ;; + esac + ;; +esac + +case "$NTP_BDIR" in + host) + BASEDIR=A.$MYNAME + ;; + cvo) + BASEDIR=A.$CVO ;; *) - BDIR=A.$CVO + echo "build: NTP_BDIR must be either 'cvo' or 'host'!" 1>&2 + exit 1 ;; esac @@ -76,15 +108,16 @@ case "$CONFIG_ARGS" in ;; esac -CCSUF="" - case "$CC" in - '') ;; - *) CCSUF="-$CC" + '') + CCSUF="" + ;; + *) + CCSUF="-`echo $CC | sed -e 's: :_:g' -e's:/:+:g'`" ;; esac -BDIR="$BDIR$KEYSUF$CCSUF" +BDIR="$BASEDIR$KEYSUF$CCSUF" [ -d "$BDIR" ] || mkdir $BDIR [ -f "$BDIR/.buildcvo" ] || echo $CVO > $BDIR/.buildcvo @@ -94,29 +127,78 @@ BDIR="$BDIR$KEYSUF$CCSUF" cd $BDIR # -# make sure we have a nice that works, +# Make sure we have a nice that works. +# To disable use of nice, setenv NO_NICE_BUILD=1 # -nice true && NICEB=nice -nice true || NICEB=./.nicebuild-$MYNAME-$SIG && ( - cat > .nicebuild-$MYNAME-$SIG < $NICEB <<-HEREDOC + #! /bin/sh + shift + \$* +HEREDOC + chmod +x $NICEB +} -( -[ -f config.status ] || $NICEB -7 ../configure --config-cache \ - $CONFIG_ARGS +# +# Find a test which supports -nt, unlike Solaris /bin/sh builtin. +# +TEST="${TEST-}" +if [ -z "$TEST" ] ; then + for try in test /bin/test /usr/bin/test ; do + case `$try config.status -nt ../configure 2>&1` in + '') + TEST="$try" + # echo "Using $TEST" + break + ;; + esac + done + if [ -z "$TEST" ] ; then + echo "build: need help finding test binary" 1>&2 + exit 1 + fi +fi + +CONFIGURE="../configure" +# We need KEYSUF because of RAND_ and others, and -noopenssl" +#CONFIGURE="$CONFIGURE --cache-file=../config.cache-$IAM$KEYSUF$CCSUF" +CONFIGURE="$CONFIGURE $CONFIG_ARGS" + + +( # This sequence of commands is logged to make.log. + # If config.status is newer than ../configure, and the same + # is true for sntp, we do not need to re-run configure. + # For libevent, the twist is we may not be configuring the + # tearoff, so only act if its config.status exists. + # Solaris /bin/sh doesn't grok -nt. + + ( "$TEST" config.status -nt ../configure && + "$TEST" sntp/config.status -nt ../sntp/configure && + ( "$TEST" '!' -f sntp/libevent/config.status || + "$TEST" sntp/libevent/config.status -nt ../sntp/libevent/configure ) ) || + "$NICEB" -7 $CONFIGURE + "$TEST" Makefile -nt config.status || + "$NICEB" -5 ./config.status + "$TEST" sntp/Makefile -nt sntp/config.status || + ( cd sntp && "$NICEB" -5 ./config.status ) + "$TEST" '!' -f sntp/libevent/Makefile || + "$TEST" sntp/libevent/Makefile -nt sntp/libevent/config.status || + ( cd sntp/libevent && "$NICEB" -5 ./config.status ) + "$NICEB" -14 ${MAKE-make} && "$NICEB" -11 ${MAKE-make} check +) > $LOGF 2>&1 -$NICEB -5 ./config.status +EXITCODE=$? -case "$MAKE" in - '') $NICEB -14 make && $NICEB -10 make check - ;; - *) $NICEB -14 $MAKE && $NICEB -10 $MAKE check - ;; +# clean up if we made a dummy nice script +case "$NICEB" in + nice) + ;; + *) + rm "$NICEB" + ;; esac -) > $LOGF 2>&1 + +exit $EXITCODE diff --git a/contrib/ntp/check-libopts.mf b/contrib/ntp/check-libopts.mf new file mode 100644 index 000000000..9f9b9e075 --- /dev/null +++ b/contrib/ntp/check-libopts.mf @@ -0,0 +1,14 @@ +## check-libopts.mf - automake fragment +## +## If we are not using the tearoff libopts, we won't be +## building its libopts.la, so the submake is allowed +## to fail. + +BUILT_SOURCES += check-libopts +CLEANFILES += check-libopts + +check-libopts: ../sntp/libopts/libopts.la + @echo stamp > $@ + +../sntp/libopts/libopts.la: + -cd ../sntp/libopts && $(MAKE) $(AM_MAKEFLAGS) libopts.la diff --git a/contrib/ntp/clockstuff/Makefile.am b/contrib/ntp/clockstuff/Makefile.am index 2a2ec4e33..d909fbf61 100644 --- a/contrib/ntp/clockstuff/Makefile.am +++ b/contrib/ntp/clockstuff/Makefile.am @@ -1,18 +1,17 @@ -#AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr -noinst_PROGRAMS = @PROPDELAY@ @CHUTEST@ @CLKTEST@ -EXTRA_PROGRAMS = propdelay chutest clktest +noinst_PROGRAMS = @PROPDELAY@ @CHUTEST@ +EXTRA_PROGRAMS = propdelay chutest -INCLUDES = -I$(top_srcdir)/include -# We need -lm (and perhaps $(COMPAT) for propdelay, -lntp for {chu,clk}test -propdelay_LDADD = -lm ../libntp/libntp.a -chutest_LDADD = ../libntp/libntp.a -clktest_LDADD = ../libntp/libntp.a -ETAGS_ARGS = Makefile.am -#EXTRA_DIST = TAGS +AM_CFLAGS = $(CFLAGS_NTP) -# clktest-opts.def wants ../include/copyright.def ../include/homerc.def +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) -chutest$(EXEEXT): ../libntp/libntp.a +LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) +propdelay_LDADD = $(LDADD) -clktest$(EXEEXT): ../libntp/libntp.a +BUILT_SOURCES = +CLEANFILES = + +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/clockstuff/Makefile.in b/contrib/ntp/clockstuff/Makefile.in index ba4e4cdd6..e75f4c047 100644 --- a/contrib/ntp/clockstuff/Makefile.in +++ b/contrib/ntp/clockstuff/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -16,6 +15,61 @@ @SET_MAKE@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -34,87 +88,203 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr -EXTRA_PROGRAMS = propdelay$(EXEEXT) chutest$(EXEEXT) clktest$(EXEEXT) +EXTRA_PROGRAMS = propdelay$(EXEEXT) chutest$(EXEEXT) subdir = clockstuff -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = PROGRAMS = $(noinst_PROGRAMS) chutest_SOURCES = chutest.c -chutest_OBJECTS = chutest$U.$(OBJEXT) -chutest_DEPENDENCIES = ../libntp/libntp.a -clktest_SOURCES = clktest.c -clktest_OBJECTS = clktest$U.$(OBJEXT) -clktest_DEPENDENCIES = ../libntp/libntp.a +chutest_OBJECTS = chutest.$(OBJEXT) +chutest_LDADD = $(LDADD) +am__DEPENDENCIES_1 = +chutest_DEPENDENCIES = ../libntp/libntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = propdelay_SOURCES = propdelay.c -propdelay_OBJECTS = propdelay$U.$(OBJEXT) -propdelay_DEPENDENCIES = ../libntp/libntp.a +propdelay_OBJECTS = propdelay.$(OBJEXT) +am__DEPENDENCIES_2 = ../libntp/libntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +propdelay_DEPENDENCIES = $(am__DEPENDENCIES_2) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ -SOURCES = chutest.c clktest.c propdelay.c -DIST_SOURCES = chutest.c clktest.c propdelay.c +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = chutest.c propdelay.c +DIST_SOURCES = chutest.c propdelay.c +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depsver.mf \ + $(top_srcdir)/includes.mf $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -122,8 +292,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -133,15 +306,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -149,23 +383,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -212,21 +482,22 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr -noinst_PROGRAMS = @PROPDELAY@ @CHUTEST@ @CLKTEST@ -INCLUDES = -I$(top_srcdir)/include -# We need -lm (and perhaps $(COMPAT) for propdelay, -lntp for {chu,clk}test -propdelay_LDADD = -lm ../libntp/libntp.a -chutest_LDADD = ../libntp/libntp.a -clktest_LDADD = ../libntp/libntp.a -ETAGS_ARGS = Makefile.am -all: all-am +noinst_PROGRAMS = @PROPDELAY@ @CHUTEST@ +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(CPPFLAGS_NTP) +LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) +propdelay_LDADD = $(LDADD) +BUILT_SOURCES = check-libntp .deps-ver +CLEANFILES = check-libntp .deps-ver +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -238,7 +509,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign clockstuff/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign clockstuff/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -247,6 +517,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -265,53 +536,44 @@ clean-noinstPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -propdelay$(EXEEXT): $(propdelay_OBJECTS) $(propdelay_DEPENDENCIES) + +chutest$(EXEEXT): $(chutest_OBJECTS) $(chutest_DEPENDENCIES) $(EXTRA_chutest_DEPENDENCIES) + @rm -f chutest$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(chutest_OBJECTS) $(chutest_LDADD) $(LIBS) + +propdelay$(EXEEXT): $(propdelay_OBJECTS) $(propdelay_DEPENDENCIES) $(EXTRA_propdelay_DEPENDENCIES) @rm -f propdelay$(EXEEXT) - $(LINK) $(propdelay_OBJECTS) $(propdelay_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(propdelay_OBJECTS) $(propdelay_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/chutest$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clktest$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/propdelay$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/chutest.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/propdelay.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -chutest_.c: chutest.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/chutest.c; then echo $(srcdir)/chutest.c; else echo chutest.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clktest_.c: clktest.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clktest.c; then echo $(srcdir)/clktest.c; else echo clktest.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -propdelay_.c: propdelay.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/propdelay.c; then echo $(srcdir)/propdelay.c; else echo propdelay.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -chutest_.$(OBJEXT) chutest_.lo clktest_.$(OBJEXT) clktest_.lo \ -propdelay_.$(OBJEXT) propdelay_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo @@ -319,26 +581,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -350,15 +601,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -367,6 +614,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -402,10 +664,12 @@ distdir: $(DISTFILES) fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -415,13 +679,19 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -430,6 +700,7 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \ @@ -488,7 +759,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -501,29 +772,87 @@ ps-am: uninstall-am: -.MAKE: ../util/ansi2knr install-am install-strip - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-libtool clean-noinstPROGRAMS ctags distclean \ - distclean-compile distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-kr \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am +.MAKE: all check install install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstPROGRAMS cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am -#EXTRA_DIST = TAGS - -# clktest-opts.def wants ../include/copyright.def ../include/homerc.def +.PRECIOUS: Makefile -chutest$(EXEEXT): ../libntp/libntp.a -clktest$(EXEEXT): ../libntp/libntp.a +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/contrib/ntp/clockstuff/README b/contrib/ntp/clockstuff/README index c7f972773..14089a9bb 100644 --- a/contrib/ntp/clockstuff/README +++ b/contrib/ntp/clockstuff/README @@ -1,19 +1,14 @@ README file for directory ./clockstuff of the NTP Version 4 distribution This directory contains the sources for utility programs designed to -support radio clocks. The chutest.c and clktest.c are desgined to -test the chu_clk and tty_clk line disciplines and STREAMS modules in -the ../kernel directory. +support radio clocks. chutest.c is desgined to test the depredated +chu_clk line discipline or STREAMS module and can also test a CHU +modem in raw mode. -These files have been modified to work with either the line disciplines -or the STREAMS modules. Be sure to define -DSTREAM if appropriate. - -These are random bits of things written to help with clocks. You can -make things in here by typing one or more of: +You can make things in here by typing one or more of: make propdelay (or `make') make chutest - make clktest Propdelay computes high frequency propagation delays, given the longitude and latitude of the transmitter and receiver. Use @@ -24,8 +19,3 @@ Chutest can be used to input and process data from a CHU modem attached to a serial port. It will use the CHU line discipline (if installed), or raw mode otherwise. This was used to test out the initial reduction algorithms, and may not be up to date. - -Clktest can be used to test the clock line discipline (CLKLDISC, -it must be available), and to take a look at radio clocks attached to a -serial port. - diff --git a/contrib/ntp/clockstuff/chutest.c b/contrib/ntp/clockstuff/chutest.c index 785c253ed..78f6c5fe9 100644 --- a/contrib/ntp/clockstuff/chutest.c +++ b/contrib/ntp/clockstuff/chutest.c @@ -2,36 +2,48 @@ * chutest - test the CHU clock */ +#ifdef HAVE_CONFIG_H +# include +#endif #include +#include +#ifdef HAVE_UNISTD_H +# include +#endif +#ifdef HAVE_STROPTS_H +# include +#else +# ifdef HAVE_SYS_STROPTS_H +# include +# endif +#endif #include #include #include #include #include #include -#include +#ifdef HAVE_TERMIOS_H +# include +#else +# ifdef HAVE_SGTTY_H +# include +# endif +#endif -#include "../include/ntp_fp.h" -#include "../include/ntp.h" -#include "../include/ntp_unixtime.h" +#include "ntp_fp.h" +#include "ntp.h" +#include "ntp_unixtime.h" +#include "ntp_calendar.h" #ifdef CHULDISC -#ifdef STREAM # ifdef HAVE_SYS_CHUDEFS_H -#include -#endif -#include -#endif +# include +# endif #endif -#ifdef CHULDISC -# ifdef HAVE_SYS_CHUDEFS_H -#include -#endif -#endif #ifndef CHULDISC -#ifndef STREAM #define NCHUCHARS (10) struct chucode { @@ -41,12 +53,10 @@ struct chucode { struct timeval codetimes[NCHUCHARS]; /* arrival times */ }; #endif -#endif #define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) -char *progname; -int debug; +char const *progname; int dofilter = 0; /* set to 1 when we should run filter algorithm */ int showtimes = 0; /* set to 1 when we should show char arrival times */ @@ -61,9 +71,14 @@ int usechuldisc = 0; /* set to 1 when CHU line discipline should be used */ struct timeval lasttv; struct chucode chudata; -extern u_long ustotslo[]; -extern u_long ustotsmid[]; -extern u_long ustotshi[]; +void error(char *fmt, char *s1, char *s2); +void init_chu(void); +int openterm(char *dev); +int process_raw(int s); +int process_ldisc(int s); +void raw_filter(unsigned int c, struct timeval *tv); +void chufilter(struct chucode *chuc, l_fp *rtime); + /* * main - parse arguments and handle options @@ -77,8 +92,6 @@ main( int c; int errflg = 0; extern int ntp_optind; - extern char *ntp_optarg; - void init_chu(); progname = argv[0]; while ((c = ntp_getopt(argc, argv, "cdfpt")) != EOF) @@ -261,21 +274,20 @@ process_raw( /* * raw_filter - run the line discipline filter over raw data */ -int +void raw_filter( unsigned int c, struct timeval *tv ) { - static struct timeval diffs[10] = { 0 }; + static struct timeval diffs[10]; struct timeval diff; l_fp ts; - void chufilter(); if ((c & 0xf) > 9 || ((c>>4)&0xf) > 9) { if (debug) (void) fprintf(stderr, - "character %02x failed BCD test\n"); + "character %02x failed BCD test\n", c); chudata.ncodechars = 0; return; } @@ -496,14 +508,6 @@ static u_long yearstart; extern u_long current_time; extern struct event timerqueue[]; -/* - * Time conversion tables imported from the library - */ -extern u_long ustotslo[]; -extern u_long ustotsmid[]; -extern u_long ustotshi[]; - - /* * init_chu - initialize internal chu driver data */ @@ -543,10 +547,6 @@ chufilter( l_fp ts; int day, hour, minute, second; static u_char lastcode[NCHUCHARS]; - extern u_long calyearstart(); - extern char *mfptoa(); - void chu_process(); - extern char *prettydate(); /* * We'll skip the checks made in the kernel, but assume they've @@ -632,6 +632,7 @@ chufilter( * work most of the time. */ date_ui = tmp + yearstart; +#define CLOCK_WAYTOOBIG 1000 /* revived from ancient sources */ if (date_ui < (rtime->l_ui + CLOCK_WAYTOOBIG) && date_ui > (rtime->l_ui - CLOCK_WAYTOOBIG)) goto codeokay; /* looks good */ @@ -640,7 +641,7 @@ chufilter( * Trouble. Next check is to see if the year rolled over and, if * so, try again with the new year's start. */ - date_ui = calyearstart(rtime->l_ui); + date_ui = calyearstart(rtime->l_ui, NULL); if (date_ui != yearstart) { yearstart = date_ui; date_ui += tmp; @@ -666,7 +667,9 @@ chufilter( * than CLOCK_WAYTOOBIG seconds into the new year. */ if ((rtime->l_ui - yearstart) < CLOCK_WAYTOOBIG) { - date_ui = tmp + calyearstart(yearstart - CLOCK_WAYTOOBIG); + date_ui = tmp; + date_ui += calyearstart(yearstart - CLOCK_WAYTOOBIG, + NULL); if ((rtime->l_ui - date_ui) < CLOCK_WAYTOOBIG) goto codeokay; } @@ -676,7 +679,9 @@ chufilter( * following the year the system is in. Try this one before * giving up. */ - date_ui = tmp + calyearstart(yearstart + (400*24*60*60)); /* 400 days */ + date_ui = tmp; + date_ui += calyearstart(yearstart + (400 * SECSPERDAY), + NULL); if ((date_ui - rtime->l_ui) >= CLOCK_WAYTOOBIG) { printf("Date hopelessly off\n"); return; /* hopeless, let it sync to other peers */ diff --git a/contrib/ntp/clockstuff/clktest.c b/contrib/ntp/clockstuff/clktest.c deleted file mode 100644 index 04df4b9bb..000000000 --- a/contrib/ntp/clockstuff/clktest.c +++ /dev/null @@ -1,412 +0,0 @@ -/* clktest.c,v 3.1 1993/07/06 01:05:23 jbj Exp - * clktest - test the clock line discipline - * - * usage: clktest -b bps -f -t timeo -s cmd -c char1 -a char2 /dev/whatever - */ - -#include "clktest-opts.h" - -#define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) - -#if defined(ULT_2_0_SUCKS) -#ifndef sigmask -#define sigmask(m) (1<<(m)) -#endif -#endif - -#ifndef STREAM -# ifndef CLKLDISC - CLOCK_LINE_DISCIPLINE_NEEDED_BY_THIS_PROGRAM; -# endif -#else -# ifdef CLKLDISC - ONLY_ONE_CLOCK_LINE_DISCIPLINE_FOR_THIS_PROGRAM; -# endif -#endif - -/* - * Mask for blocking SIGIO and SIGALRM - */ -#define BLOCKSIGMASK (sigmask(SIGIO)|sigmask(SIGALRM)) - -#define progname clktestOptions.pzProgName - -struct timeval timeout = { 0 }; -char *cmd = NULL; -int cmdlen; - -#ifdef CLKLDISC -u_long magic1 = DEFMAGIC; -u_long magic2 = DEFMAGIC; -#endif - -int speed = B9600; -int ttflags = RAW|EVENP|ODDP; - -volatile int wasalarmed; -volatile int iosig; - -struct timeval lasttv; - -extern u_long ustotslo[]; -extern u_long ustotsmid[]; -extern u_long ustotshi[]; - -int alarming(); -int ioready(); - -/* - * main - parse arguments and handle options - */ -int -main( - int argc, - char *argv[] - ) -{ - int fd; - struct sgttyb ttyb; - struct itimerval itimer; - -#ifdef STREAM - magic[0] = 0; -#endif - - { - int ct = optionProcess( &clktestOptions, argc, argv ); - if (HAVE_OPT(COMMAND) && (strlen(OPT_ARG(COMMAND)) == 0)) { - fputs( "The command option string must not be empty\n", stderr ); - USAGE( EXIT_FAILURE ); - } - - if ((argc -= ct) != 1) { - fputs( "Missing tty device name\n", stderr ); - USAGE( EXIT_FAILURE ); - } - argv += ct; - } -#ifdef STREAM - if (!strlen(magic)) - strcpy(magic,DEFMAGIC); -#endif - - fd = open(*argv, HAVE_OPT(TIMEOUT) ? O_RDWR : O_RDONLY, 0777); - if (fd == -1) { - fprintf(stderr, "%s: open(%s): ", progname, *argv); - perror(""); - exit(1); - } - - if (ioctl(fd, TIOCEXCL, (char *)0) < 0) { - (void) fprintf(stderr, "%s: ioctl(TIOCEXCL): ", progname); - perror(""); - exit(1); - } - - /* - * If we have the clock discipline, set the port to raw. Otherwise - * we run cooked. - */ - ttyb.sg_ispeed = ttyb.sg_ospeed = speed; -#ifdef CLKLDISC - ttyb.sg_erase = (char)magic1; - ttyb.sg_kill = (char)magic2; -#endif - ttyb.sg_flags = (short)ttflags; - if (ioctl(fd, TIOCSETP, (char *)&ttyb) < 0) { - (void) fprintf(stderr, "%s: ioctl(TIOCSETP): ", progname); - perror(""); - exit(1); - } - - if (fcntl(fd, F_SETOWN, getpid()) == -1) { - (void) fprintf(stderr, "%s: fcntl(F_SETOWN): ", progname); - perror(""); - exit(1); - } - -#ifdef CLKLDISC - { - int ldisc; - ldisc = CLKLDISC; - if (ioctl(fd, TIOCSETD, (char *)&ldisc) < 0) { - (void) fprintf(stderr, "%s: ioctl(TIOCSETD): ", progname); - perror(""); - exit(1); - } - } -#endif -#ifdef STREAM - if (ioctl(fd, I_POP, 0) >=0 ) ; - if (ioctl(fd, I_PUSH, "clk") < 0) { - (void) fprintf(stderr, "%s: ioctl(I_PUSH): ", progname); - perror(""); - exit(1); - } - if (ioctl(fd, CLK_SETSTR, magic) < 0) { - (void) fprintf(stderr, "%s: ioctl(CLK_SETSTR): ", progname); - perror(""); - exit(1); - } -#endif - - - (void) gettimeofday(&lasttv, (struct timezone *)0); - if (HAVE_OPT(TIMEOUT)) { - /* - * set non-blocking, async I/O on the descriptor - */ - iosig = 0; - (void) signal(SIGIO, ioready); - if (fcntl(fd, F_SETFL, FNDELAY|FASYNC) < 0) { - (void) fprintf(stderr, "%s: fcntl(F_SETFL): ", - progname); - perror(""); - exit(1); - } - - /* - * Set up the alarm interrupt. - */ - wasalarmed = 0; - (void) signal(SIGALRM, alarming); - timeout.tv_sec = OPT_VALUE_TIMEOUT; - itimer.it_interval = itimer.it_value = timeout; - setitimer(ITIMER_REAL, &itimer, (struct itimerval *)0); - doboth(fd); - } - doioonly(fd); -} - - -/* - * doboth - handle both I/O and alarms via SIGIO - */ -int -doboth( - int fd - ) -{ - int n; - int sawalarm; - int sawiosig; - int omask; - fd_set fds; - struct timeval tvzero; - - sawalarm = 0; - sawiosig = 0; - FD_ZERO(&fds); - for (;;) { - omask = sigblock(BLOCKSIGMASK); - if (wasalarmed) { /* alarmed? */ - sawalarm = 1; - wasalarmed = 0; - } - if (iosig) { - sawiosig = 1; - iosig = 0; - } - - if (!sawalarm && !sawiosig) { - /* - * Nothing to do. Wait for something. - */ - sigpause(omask); - if (wasalarmed) { /* alarmed? */ - sawalarm = 1; - wasalarmed = 0; - } - if (iosig) { - sawiosig = 1; - iosig = 0; - } - } - (void)sigsetmask(omask); - - if (sawiosig) { - - do { - tvzero.tv_sec = tvzero.tv_usec = 0; - FD_SET(fd, &fds); - n = select(fd+1, &fds, (fd_set *)0, - (fd_set *)0, &tvzero); - if (n > 0) - doio(fd); - } while (n > 0); - - if (n == -1) { - (void) fprintf(stderr, "%s: select: ", - progname); - perror(""); - exit(1); - } - sawiosig = 0; - } - if (sawalarm) { - doalarm(fd); - sawalarm = 0; - } - } -} - - -/* - * doioonly - do I/O. This avoids the use of signals - */ -int -doioonly( - int fd - ) -{ - int n; - fd_set fds; - - FD_ZERO(&fds); - for (;;) { - FD_SET(fd, &fds); - n = select(fd+1, &fds, (fd_set *)0, (fd_set *)0, - (struct timeval *)0); - if (n > 0) - doio(fd); - } -} - - -/* - * doio - read a buffer full of stuff and print it out - */ -int -doio( - int fd - ) -{ - register char *rp, *rpend; - register char *cp; - register int i; - char raw[512]; - struct timeval tv, tvd; - int rlen; - int ind; - char cooked[2049]; - static char *digits = "0123456789abcdef"; - - rlen = read(fd, raw, sizeof(raw)); - if (rlen < 0) { - (void) fprintf(stderr, "%s: read(): ", progname); - perror(""); - return; - } - if (rlen == 0) { - (void) printf("Zero length read\n"); - return; - } - - cp = cooked; - rp = raw; - rpend = &raw[rlen]; - ind = 0; - - while (rp < rpend) { - ind = 1; - if (isprint(*rp)) - *cp++ = *rp; - else { - *cp++ = '<'; - *cp++ = digits[((*rp)>>4) & 0xf]; - *cp++ = digits[*rp & 0xf]; - *cp++ = '>'; - } - if ( -#ifdef CLKLDISC - (*rp == (char)magic1 || *rp == (char)magic2) -#else - ( strchr( magic, *rp) != NULL ) -#endif - ) { - rp++; - ind = 0; - *cp = '\0'; - if ((rpend - rp) < sizeof(struct timeval)) { - (void)printf( - "Too little data (%d): %s\n", - rpend-rp, cooked); - return; - } - - tv.tv_sec = 0; - for (i = 0; i < 4; i++) { - tv.tv_sec <<= 8; - tv.tv_sec |= ((long)*rp++) & 0xff; - } - tv.tv_usec = 0; - for (i = 0; i < 4; i++) { - tv.tv_usec <<= 8; - tv.tv_usec |= ((long)*rp++) & 0xff; - } - - tvd.tv_sec = tv.tv_sec - lasttv.tv_sec; - tvd.tv_usec = tv.tv_usec - lasttv.tv_usec; - if (tvd.tv_usec < 0) { - tvd.tv_usec += 1000000; - tvd.tv_sec--; - } - - (void)printf("%lu.%06lu %lu.%06lu %s\n", - tv.tv_sec, tv.tv_usec, tvd.tv_sec, tvd.tv_usec, - cooked); - lasttv = tv; - } else { - rp++; - } - } - - if (ind) { - *cp = '\0'; - (void)printf("Incomplete data: %s\n", cooked); - } -} - - -/* - * doalarm - send a string out the port, if we have one. - */ -int -doalarm( - int fd - ) -{ - int n; - - if (! HAVE_OPT(COMMAND)) - return; - - n = write(fd, cmd, cmdlen); - - if (n < 0) { - (void) fprintf(stderr, "%s: write(): ", progname); - perror(""); - } else if (n < cmdlen) { - (void) printf("Short write (%d bytes, should be %d)\n", - n, cmdlen); - } -} - - -/* - * alarming - receive alarm interupt - */ -void -alarming(void) -{ - wasalarmed = 1; -} - -/* - * ioready - handle SIGIO interrupt - */ -void -ioready(void) -{ - iosig = 1; -} diff --git a/contrib/ntp/clockstuff/propdelay.c b/contrib/ntp/clockstuff/propdelay.c index c8df6866b..a3b9fc0b2 100644 --- a/contrib/ntp/clockstuff/propdelay.c +++ b/contrib/ntp/clockstuff/propdelay.c @@ -47,6 +47,9 @@ * to find delays to GOES via each of the three satellites. */ +#ifdef HAVE_CONFIG_H +# include +#endif #include #include @@ -114,8 +117,7 @@ int Cflag = 0; int Gflag = 0; int height; -char *progname; -volatile int debug; +char const *progname; static void doit (double, double, double, double, double, char *); static double latlong (char *, int); @@ -142,6 +144,8 @@ main( double lat2, long2; double lat3, long3; + init_lib(); + progname = argv[0]; while ((c = ntp_getopt(argc, argv, "dh:CWG")) != EOF) switch (c) { diff --git a/contrib/ntp/conf/beauregard.conf b/contrib/ntp/conf/beauregard.conf index 72f735b17..ea80c02a6 100644 --- a/contrib/ntp/conf/beauregard.conf +++ b/contrib/ntp/conf/beauregard.conf @@ -1,6 +1,6 @@ # # NTP configuration file (ntp.conf) -# bearegard.udel.edu +# beauregard.udel.edu # server 127.127.18.1 # NIST ACTS modem driver fudge 127.127.18.1 time1 .0035 diff --git a/contrib/ntp/config.guess b/contrib/ntp/config.guess index 917bbc50f..b02565c7b 100755 --- a/contrib/ntp/config.guess +++ b/contrib/ntp/config.guess @@ -1,9 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011 Free Software Foundation, Inc. -timestamp='2005-07-08' +timestamp='2011-06-03' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -26,16 +27,16 @@ timestamp='2005-07-08' # the same distribution terms that you use for the rest of that program. -# Originally written by Per Bothner . -# Please send patches to . Submit a context -# diff and a properly formatted ChangeLog entry. +# Originally written by Per Bothner. Please send patches (context +# diff format) to and include a ChangeLog +# entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # -# The plan is that this can be called by configure scripts if you -# don't specify an explicit build system type. +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD me=`echo "$0" | sed -e 's,.*/,,'` @@ -55,8 +56,9 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free +Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -106,7 +108,7 @@ set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; - { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; @@ -160,6 +162,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; + sh5el) machine=sh5le-unknown ;; *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched @@ -168,7 +171,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep __ELF__ >/dev/null + | grep -q __ELF__ then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? @@ -178,7 +181,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in fi ;; *) - os=netbsd + os=netbsd ;; esac # The OS release @@ -206,8 +209,11 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; + *:SolidBSD:*:*) + echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} + exit ;; macppc:MirBSD:*:*) - echo powerppc-unknown-mirbsd${UNAME_RELEASE} + echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} @@ -218,7 +224,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on @@ -264,7 +270,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - exit ;; + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + exitcode=$? + trap '' 0 + exit $exitcode ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead @@ -290,7 +299,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in echo s390-ibm-zvmoe exit ;; *:OS400:*:*) - echo powerpc-ibm-os400 + echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} @@ -319,14 +328,33 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; + s390x:SunOS:*:*) + echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; - i86pc:SunOS:5.*:*) - echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) + echo i386-pc-auroraux${UNAME_RELEASE} + exit ;; + i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) + eval $set_cc_for_build + SUN_ARCH="i386" + # If there is a compiler, see if it is configured for 64-bit objects. + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. + # This test works for both compilers. + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + SUN_ARCH="x86_64" + fi + fi + echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize @@ -370,23 +398,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} - exit ;; + exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint${UNAME_RELEASE} - exit ;; + echo m68k-milan-mint${UNAME_RELEASE} + exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint${UNAME_RELEASE} - exit ;; + echo m68k-hades-mint${UNAME_RELEASE} + exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint${UNAME_RELEASE} - exit ;; + echo m68k-unknown-mint${UNAME_RELEASE} + exit ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit ;; @@ -456,8 +484,8 @@ EOF echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` + # DG/UX returns AViiON for all architectures + UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ @@ -470,7 +498,7 @@ EOF else echo i586-dg-dgux${UNAME_RELEASE} fi - exit ;; + exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; @@ -527,7 +555,7 @@ EOF echo rs6000-ibm-aix3.2 fi exit ;; - *:AIX:*:[45]) + *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 @@ -570,52 +598,52 @@ EOF 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "${sc_cpu_version}" in - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in - 32) HP_ARCH="hppa2.0n" ;; - 64) HP_ARCH="hppa2.0w" ;; + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` + case "${sc_cpu_version}" in + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 + 532) # CPU_PA_RISC2_0 + case "${sc_kernel_bits}" in + 32) HP_ARCH="hppa2.0n" ;; + 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 - esac ;; - esac + esac ;; + esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + sed 's/^ //' << EOF >$dummy.c - #define _HPUX_SOURCE - #include - #include + #define _HPUX_SOURCE + #include + #include - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa @@ -635,7 +663,7 @@ EOF # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | - grep __LP64__ >/dev/null + grep -q __LP64__ then HP_ARCH="hppa2.0w" else @@ -706,22 +734,22 @@ EOF exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd - exit ;; + exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi - exit ;; + exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd - exit ;; + exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd - exit ;; + exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd - exit ;; + exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; @@ -745,14 +773,14 @@ EOF exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} @@ -764,27 +792,46 @@ EOF echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) - echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + case ${UNAME_MACHINE} in + pc98) + echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + amd64) + echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + *) + echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; - i*:MINGW*:*) + *:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; i*:windows32*:*) - # uname -m includes "-pc" on this system. - echo ${UNAME_MACHINE}-mingw32 + # uname -m includes "-pc" on this system. + echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; - x86:Interix*:[34]*) - echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//' - exit ;; + *:Interix*:*) + case ${UNAME_MACHINE} in + x86) + echo i586-pc-interix${UNAME_RELEASE} + exit ;; + authenticamd | genuineintel | EM64T) + echo x86_64-unknown-interix${UNAME_RELEASE} + exit ;; + IA64) + echo ia64-unknown-interix${UNAME_RELEASE} + exit ;; + esac ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; + 8664:Windows_NT:*) + echo x86_64-pc-mks + exit ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we @@ -794,7 +841,7 @@ EOF i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit ;; - amd64:CYGWIN*:*:*) + amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; p*:CYGWIN*:*) @@ -814,7 +861,37 @@ EOF i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; + alpha:Linux:*:*) + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in + EV5) UNAME_MACHINE=alphaev5 ;; + EV56) UNAME_MACHINE=alphaev56 ;; + PCA56) UNAME_MACHINE=alphapca56 ;; + PCA57) UNAME_MACHINE=alphapca56 ;; + EV6) UNAME_MACHINE=alphaev6 ;; + EV67) UNAME_MACHINE=alphaev67 ;; + EV68*) UNAME_MACHINE=alphaev68 ;; + esac + objdump --private-headers /bin/sh | grep -q ld.so.1 + if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi + echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} + exit ;; arm*:Linux:*:*) + eval $set_cc_for_build + if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_EABI__ + then + echo ${UNAME_MACHINE}-unknown-linux-gnu + else + if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_PCS_VFP + then + echo ${UNAME_MACHINE}-unknown-linux-gnueabi + else + echo ${UNAME_MACHINE}-unknown-linux-gnueabihf + fi + fi + exit ;; + avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) @@ -824,7 +901,18 @@ EOF echo crisv32-axis-linux-gnu exit ;; frv:Linux:*:*) - echo frv-unknown-linux-gnu + echo frv-unknown-linux-gnu + exit ;; + i*86:Linux:*:*) + LIBC=gnu + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #ifdef __dietlibc__ + LIBC=dietlibc + #endif +EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` + echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -835,63 +923,33 @@ EOF m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; - mips:Linux:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #undef CPU - #undef mips - #undef mipsel - #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=mipsel - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=mips - #else - CPU= - #endif - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } - ;; - mips64:Linux:*:*) + mips:Linux:*:* | mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU - #undef mips64 - #undef mips64el + #undef ${UNAME_MACHINE} + #undef ${UNAME_MACHINE}el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=mips64el + CPU=${UNAME_MACHINE}el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=mips64 + CPU=${UNAME_MACHINE} #else CPU= #endif #endif EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-gnu + or32:Linux:*:*) + echo or32-unknown-linux-gnu exit ;; - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-gnu + padre:Linux:*:*) + echo sparc-unknown-linux-gnu exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; - esac - objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null - if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi - echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} + parisc64:Linux:*:* | hppa64:Linux:*:*) + echo hppa64-unknown-linux-gnu exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level @@ -901,14 +959,17 @@ EOF *) echo hppa-unknown-linux-gnu ;; esac exit ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-gnu + ppc64:Linux:*:*) + echo powerpc64-unknown-linux-gnu + exit ;; + ppc:Linux:*:*) + echo powerpc-unknown-linux-gnu exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit ;; sh64*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -916,68 +977,18 @@ EOF sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; + tile*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + vax:Linux:*:*) + echo ${UNAME_MACHINE}-dec-linux-gnu + exit ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; - i*86:Linux:*:*) - # The BFD linker knows what the default object file format is, so - # first see if it will tell us. cd to the root directory to prevent - # problems with other programs or directories called `ld' in the path. - # Set LC_ALL=C to ensure ld outputs messages in English. - ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ - | sed -ne '/supported targets:/!d - s/[ ][ ]*/ /g - s/.*supported targets: *// - s/ .*// - p'` - case "$ld_supported_targets" in - elf32-i386) - TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" - ;; - a.out-i386-linux) - echo "${UNAME_MACHINE}-pc-linux-gnuaout" - exit ;; - coff-i386) - echo "${UNAME_MACHINE}-pc-linux-gnucoff" - exit ;; - "") - # Either a pre-BFD a.out linker (linux-gnuoldld) or - # one that does not give us useful --help. - echo "${UNAME_MACHINE}-pc-linux-gnuoldld" - exit ;; - esac - # Determine whether the default compiler is a.out or elf - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - #ifdef __ELF__ - # ifdef __GLIBC__ - # if __GLIBC__ >= 2 - LIBC=gnu - # else - LIBC=gnulibc1 - # endif - # else - LIBC=gnulibc1 - # endif - #else - #ifdef __INTEL_COMPILER - LIBC=gnu - #else - LIBC=gnuaout - #endif - #endif - #ifdef __dietlibc__ - LIBC=dietlibc - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` - test x"${LIBC}" != x && { - echo "${UNAME_MACHINE}-pc-linux-${LIBC}" - exit - } - test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } - ;; + xtensa*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both @@ -985,11 +996,11 @@ EOF echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) - # Unixware is an offshoot of SVR4, but it has its own version - # number series starting with 2... - # I am not positive that other SVR4 systems won't match this, + # Unixware is an offshoot of SVR4, but it has its own version + # number series starting with 2... + # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. - # Use sysv4.2uw... so that sysv4* matches it. + # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) @@ -1006,7 +1017,7 @@ EOF i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) @@ -1021,7 +1032,7 @@ EOF fi exit ;; i*86:*:5:[678]*) - # UnixWare 7.x, OpenUNIX and OpenServer 6. + # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; @@ -1049,10 +1060,13 @@ EOF exit ;; pc:*:*:*) # Left here for compatibility: - # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i386. - echo i386-pc-msdosdjgpp - exit ;; + # uname -m prints for DJGPP always 'pc', but it prints nothing about + # the processor, so we play safe by assuming i586. + # Note: whatever this is, it MUST be the same as what config.sub + # prints for the "djgpp" host, or else GDB configury will decide that + # this is a cross-build. + echo i586-pc-msdosdjgpp + exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; @@ -1087,8 +1101,18 @@ EOF /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4; exit; } ;; + NCR*:*:4.2:* | MPRAS*:*:4.2:*) + OS_REL='.3' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; @@ -1101,7 +1125,7 @@ EOF rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) + PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) @@ -1121,10 +1145,10 @@ EOF echo ns32k-sni-sysv fi exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says - echo i586-unisys-sysv4 - exit ;; + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says + echo i586-unisys-sysv4 + exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm @@ -1150,11 +1174,11 @@ EOF exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} + echo mips-nec-sysv${UNAME_RELEASE} else - echo mips-unknown-sysv${UNAME_RELEASE} + echo mips-unknown-sysv${UNAME_RELEASE} fi - exit ;; + exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; @@ -1164,6 +1188,9 @@ EOF BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; + BePC:Haiku:*:*) # Haiku running on Intel PC compatible. + echo i586-pc-haiku + exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; @@ -1173,6 +1200,15 @@ EOF SX-6:SUPER-UX:*:*) echo sx6-nec-superux${UNAME_RELEASE} exit ;; + SX-7:SUPER-UX:*:*) + echo sx7-nec-superux${UNAME_RELEASE} + exit ;; + SX-8:SUPER-UX:*:*) + echo sx8-nec-superux${UNAME_RELEASE} + exit ;; + SX-8R:SUPER-UX:*:*) + echo sx8r-nec-superux${UNAME_RELEASE} + exit ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit ;; @@ -1182,7 +1218,16 @@ EOF *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in - *86) UNAME_PROCESSOR=i686 ;; + i386) + eval $set_cc_for_build + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + UNAME_PROCESSOR="x86_64" + fi + fi ;; unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} @@ -1198,6 +1243,9 @@ EOF *:QNX:*:4*) echo i386-pc-qnx exit ;; + NEO-?:NONSTOP_KERNEL:*:*) + echo neo-tandem-nsk${UNAME_RELEASE} + exit ;; NSE-?:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; @@ -1243,13 +1291,13 @@ EOF echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) - echo mips-sei-seiux${UNAME_RELEASE} + echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` + UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; @@ -1261,6 +1309,12 @@ EOF i*86:skyos:*:*) echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' exit ;; + i*86:rdos:*:*) + echo ${UNAME_MACHINE}-pc-rdos + exit ;; + i*86:AROS:*:*) + echo ${UNAME_MACHINE}-pc-aros + exit ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 @@ -1283,11 +1337,11 @@ main () #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 - "4" + "4" #else - "" + "" #endif - ); exit (0); + ); exit (0); #endif #endif @@ -1421,9 +1475,9 @@ This script, last modified $timestamp, has failed to recognize the operating system you are using. It is advised that you download the most up to date version of the config scripts from - http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.guess + http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD and - http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.sub + http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD If the version you run ($0) is already up to date, please send the following data and any information you think might be diff --git a/contrib/ntp/config.h.in b/contrib/ntp/config.h.in index 84e57fd8e..81867c7b0 100644 --- a/contrib/ntp/config.h.in +++ b/contrib/ntp/config.h.in @@ -6,11 +6,11 @@ /* Is adjtime() accurate? */ #undef ADJTIME_IS_ACCURATE -/* CHU audio/decoder? */ -#undef AUDIO_CHU +/* Support NTP Autokey protocol? */ +#undef AUTOKEY -/* Declare char *sys_errlist array */ -#undef CHAR_SYS_ERRLIST +/* why not HAVE_P_S? */ +#undef CALL_PTHREAD_SETCONCURRENCY /* ACTS modem service */ #undef CLOCK_ACTS @@ -51,6 +51,9 @@ /* Forum Graphic GPS datating station driver? */ #undef CLOCK_FG +/* GPSD JSON receiver */ +#undef CLOCK_GPSDJSON + /* TrueTime GPS receiver/VME interface? */ #undef CLOCK_GPSVME @@ -126,6 +129,9 @@ /* Schmid DCF77 clock */ #undef CLOCK_SCHMID +/* SEL240X protocol */ +#undef CLOCK_SEL240X + /* clock thru shared memory */ #undef CLOCK_SHM @@ -144,16 +150,19 @@ /* Kinemetrics/TrueTime receivers */ #undef CLOCK_TRUETIME +/* Spectracom TSYNC timing board */ +#undef CLOCK_TSYNCPCI + /* TrueTime 560 IRIG-B decoder? */ #undef CLOCK_TT560 /* Ultralink M320 WWVB receiver? */ #undef CLOCK_ULINK -/* VARITEXT protocol */ +/* VARITEXT clock */ #undef CLOCK_VARITEXT -/* WHARTON 400A Series protocol */ +/* WHARTON 400A Series clock */ #undef CLOCK_WHARTON_400A /* WWV audio driver */ @@ -162,7 +171,15 @@ /* Zyfer GPStarplus */ #undef CLOCK_ZYFER -/* Enable debugging? */ +/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP + systems. This function is required for `alloca.c' support on those systems. + */ +#undef CRAY_STACKSEG_END + +/* Define to 1 if using `alloca.c'. */ +#undef C_ALLOCA + +/* Enable debugging code? */ #undef DEBUG /* Enable processing time debugging? */ @@ -267,17 +284,29 @@ /* What is the fallback value for HZ? */ #undef DEFAULT_HZ +/* Default number of megabytes for RLIMIT_MEMLOCK */ +#undef DFLT_RLIMIT_MEMLOCK + +/* Default number of 4k pages for RLIMIT_STACK */ +#undef DFLT_RLIMIT_STACK + +/* Directory separator character, usually / or \\ */ +#undef DIR_SEP + +/* use old autokey session key behavior? */ +#undef DISABLE_BUG1243_FIX + /* synch TODR hourly? */ #undef DOSYNCTODR /* The number of minutes in a DST adjustment */ #undef DSTMINUTES -/* fopen(3) accepts a 'b' in the mode flag */ -#undef FOPEN_BINARY_FLAG +/* number of args to el_init() */ +#undef EL_INIT_ARGS -/* fopen(3) accepts a 't' in the mode flag */ -#undef FOPEN_TEXT_FLAG +/* nls support in libopts */ +#undef ENABLE_NLS /* force ntpdate to step the clock if !defined(STEP_SLEW) ? */ #undef FORCE_NTPDATE_STEP @@ -285,12 +314,28 @@ /* What is getsockname()'s socklen type? */ #undef GETSOCKNAME_SOCKLEN_TYPE -/* Do we have a routing socket (struct rt_msghdr)? */ +/* Do we have a routing socket (rt_msghdr or rtattr)? */ #undef HAS_ROUTING_SOCKET +/* via __adjtimex */ +#undef HAVE_ADJTIMEX + +/* Define to 1 if you have `alloca', as a function or macro. */ +#undef HAVE_ALLOCA + +/* Define to 1 if you have and it should be used (not on Ultrix). + */ +#undef HAVE_ALLOCA_H + +/* Define to 1 if you have the `arc4random_buf' function. */ +#undef HAVE_ARC4RANDOM_BUF + /* Define to 1 if you have the header file. */ #undef HAVE_ARPA_NAMESER_H +/* Define to 1 if you have the `atomic_thread_fence' function. */ +#undef HAVE_ATOMIC_THREAD_FENCE + /* Do we have audio support? */ #undef HAVE_AUDIO @@ -300,20 +345,30 @@ /* Define to 1 if you have the `canonicalize_file_name' function. */ #undef HAVE_CANONICALIZE_FILE_NAME +/* Define to 1 if you have the `chmod' function. */ +#undef HAVE_CHMOD + /* Do we have the CIOGETEV ioctl (SunOS, Linux)? */ #undef HAVE_CIOGETEV +/* Define to 1 if you have the `clock_getres' function. */ +#undef HAVE_CLOCK_GETRES + /* Define to 1 if you have the `clock_gettime' function. */ #undef HAVE_CLOCK_GETTIME /* Define to 1 if you have the `clock_settime' function. */ #undef HAVE_CLOCK_SETTIME +/* Define to 1 if you have the header file. */ +#undef HAVE_CTHREADS_H + /* Define to 1 if you have the `daemon' function. */ #undef HAVE_DAEMON -/* Define this if /dev/zero is readable device */ -#undef HAVE_DEV_ZERO +/* Define to 1 if you have the declaration of `strerror_r', and to 0 if you + don't. */ +#undef HAVE_DECL_STRERROR_R /* Define to 1 if you have the header file, and it defines `DIR'. */ @@ -328,17 +383,17 @@ /* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */ #undef HAVE_DOPRNT -/* [Can we drop root privileges?] */ +/* Can we drop root privileges? */ #undef HAVE_DROPROOT /* Define to 1 if you have the header file. */ #undef HAVE_ERRNO_H -/* Define to 1 if you have the `EVP_md2' function. */ -#undef HAVE_EVP_MD2 +/* Define to 1 if you have the `EVP_MD_do_all_sorted' function. */ +#undef HAVE_EVP_MD_DO_ALL_SORTED -/* Define to 1 if you have the `EVP_mdc2' function. */ -#undef HAVE_EVP_MDC2 +/* Define to 1 if you have the `fchmod' function. */ +#undef HAVE_FCHMOD /* Define to 1 if you have the header file. */ #undef HAVE_FCNTL_H @@ -346,6 +401,18 @@ /* Define to 1 if you have the `finite' function. */ #undef HAVE_FINITE +/* Define to 1 if you have the `fnmatch' function. */ +#undef HAVE_FNMATCH + +/* Define to 1 if you have the header file. */ +#undef HAVE_FNMATCH_H + +/* Define to 1 if you have the `fork' function. */ +#undef HAVE_FORK + +/* Define to 1 if you have the `fstat' function. */ +#undef HAVE_FSTAT + /* Define to 1 if you have the `getbootfile' function. */ #undef HAVE_GETBOOTFILE @@ -358,16 +425,25 @@ /* Define to 1 if you have the `getifaddrs' function. */ #undef HAVE_GETIFADDRS +/* Define to 1 if you have the `getpassphrase' function. */ +#undef HAVE_GETPASSPHRASE + /* Define to 1 if you have the `getrusage' function. */ #undef HAVE_GETRUSAGE /* Define to 1 if you have the `getuid' function. */ #undef HAVE_GETUID -/* Define to 1 if you have the `hstrerror' function. */ -#undef HAVE_HSTRERROR +/* if you have GNU Pth */ +#undef HAVE_GNU_PTH + +/* Define to 1 if you have the header file. */ +#undef HAVE_HISTEDIT_H -/* Obvious... */ +/* Define to 1 if you have the header file. */ +#undef HAVE_HISTORY_H + +/* Obvious */ #undef HAVE_HZ_IN_STRUCT_CLOCKINFO /* Define to 1 if you have the header file. */ @@ -376,71 +452,56 @@ /* have iflist_sysctl? */ #undef HAVE_IFLIST_SYSCTL +/* Define to 1 if you have the `if_nametoindex' function. */ +#undef HAVE_IF_NAMETOINDEX + /* inline keyword or macro available */ #undef HAVE_INLINE /* Define to 1 if the system has the type `int16_t'. */ #undef HAVE_INT16_T +/* Define to 1 if the system has the type `int32'. */ +#undef HAVE_INT32 + +/* int32 type in DNS headers, not others. */ +#undef HAVE_INT32_ONLY_WITH_DNS + /* Define to 1 if the system has the type `int32_t'. */ #undef HAVE_INT32_T /* Define to 1 if the system has the type `int8_t'. */ #undef HAVE_INT8_T +/* Define to 1 if the system has the type `intmax_t'. */ +#undef HAVE_INTMAX_T + /* Define to 1 if the system has the type `intptr_t'. */ #undef HAVE_INTPTR_T /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H -/* Do we have IPTOS support? */ -#undef HAVE_IPTOS_SUPPORT - /* Define to 1 if you have the `isfinite' function. */ #undef HAVE_ISFINITE +/* Define to 1 if you have the header file. */ +#undef HAVE_KVM_H + /* Define to 1 if you have the `kvm_open' function. */ #undef HAVE_KVM_OPEN -/* Define to 1 if you have the `K_open' function. */ -#undef HAVE_K_OPEN - -/* Define to 1 if you have the `advapi32' library (-ladvapi32). */ -#undef HAVE_LIBADVAPI32 - -/* Do we have the curses library? */ -#undef HAVE_LIBCURSES - -/* Do we have the edit library? */ -#undef HAVE_LIBEDIT - -/* Define to 1 if you have the `elf' library (-lelf). */ -#undef HAVE_LIBELF - /* Define to 1 if you have the `gen' library (-lgen). */ #undef HAVE_LIBGEN /* Define to 1 if you have the header file. */ #undef HAVE_LIBGEN_H -/* Define to 1 if you have the `kvm' library (-lkvm). */ -#undef HAVE_LIBKVM - -/* Define to 1 if you have the `ld' library (-lld). */ -#undef HAVE_LIBLD +/* Define to 1 if you have the `intl' library (-lintl). */ +#undef HAVE_LIBINTL -/* Define to 1 if you have the `mld' library (-lmld). */ -#undef HAVE_LIBMLD - -/* Define to 1 if you have the `posix4' library (-lposix4). */ -#undef HAVE_LIBPOSIX4 - -/* Define to 1 if you have the `readline' library (-lreadline). */ -#undef HAVE_LIBREADLINE - -/* Define to 1 if you have the `rt' library (-lrt). */ -#undef HAVE_LIBRT +/* Define to 1 if you have the header file. */ +#undef HAVE_LIBINTL_H /* Define to 1 if you have the header file. */ #undef HAVE_LIBSCF_H @@ -448,15 +509,51 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LIMITS_H -/* [Do we have Linux capabilities?] */ +/* using Linux pthread? */ +#undef HAVE_LINUXTHREADS + +/* Do we have Linux capabilities? */ #undef HAVE_LINUX_CAPABILITIES +/* Define to 1 if you have the header file. */ +#undef HAVE_LINUX_IF_ADDR_H + +/* if you have LinuxThreads */ +#undef HAVE_LINUX_THREADS + +/* Define to 1 if you have the `localeconv' function. */ +#undef HAVE_LOCALECONV + +/* Define to 1 if you have the header file. */ +#undef HAVE_LOCALE_H + +/* Define to 1 if the system has the type `long double'. */ +#undef HAVE_LONG_DOUBLE + +/* Define to 1 if the system has the type `long long'. */ +#undef HAVE_LONG_LONG + +/* Define to 1 if the system has the type `long long int'. */ +#undef HAVE_LONG_LONG_INT + +/* if you have SunOS LWP package */ +#undef HAVE_LWP + +/* Define to 1 if you have the header file. */ +#undef HAVE_LWP_LWP_H + /* Define to 1 if you have the header file. */ #undef HAVE_MACHINE_INLINE_H /* Define to 1 if you have the header file. */ #undef HAVE_MACHINE_SOUNDCARD_H +/* define if you have Mach Cthreads */ +#undef HAVE_MACH_CTHREADS + +/* Define to 1 if you have the header file. */ +#undef HAVE_MACH_CTHREADS_H + /* Define to 1 if you have the header file. */ #undef HAVE_MATH_H @@ -466,21 +563,12 @@ /* Define to 1 if you have the header file. */ #undef HAVE_MD5_H -/* Define to 1 if you have the `memcpy' function. */ -#undef HAVE_MEMCPY - /* Define to 1 if you have the `memlk' function. */ #undef HAVE_MEMLK -/* Define to 1 if you have the `memmove' function. */ -#undef HAVE_MEMMOVE - /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H -/* Define to 1 if you have the `memset' function. */ -#undef HAVE_MEMSET - /* Define to 1 if you have the `mkstemp' function. */ #undef HAVE_MKSTEMP @@ -493,6 +581,9 @@ /* Define to 1 if you have the `mmap' function. */ #undef HAVE_MMAP +/* Define to 1 if you have the `nanosleep' function. */ +#undef HAVE_NANOSLEEP + /* Define to 1 if you have the header file, and it defines `DIR'. */ #undef HAVE_NDIR_H @@ -508,6 +599,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_NETINET_IN_SYSTM_H +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IN_VAR_H + /* Define to 1 if you have the header file. */ #undef HAVE_NETINET_IP_H @@ -523,26 +617,38 @@ /* Define to 1 if you have the header file. */ #undef HAVE_NET_IF_H +/* Define to 1 if you have the header file. */ +#undef HAVE_NET_IF_VAR_H + /* Define to 1 if you have the header file. */ #undef HAVE_NET_ROUTE_H /* Define to 1 if you have the `nice' function. */ #undef HAVE_NICE -/* Define to 1 if you have the `nlist' function. */ -#undef HAVE_NLIST +/* Define to 1 if you have the header file. */ +#undef HAVE_NLIST_H -/* Define to 1 if you have the `ntp_adjtime' function. */ +/* via __adjtimex */ #undef HAVE_NTP_ADJTIME -/* Define to 1 if you have the `ntp_gettime' function. */ +/* via __ntp_gettime */ #undef HAVE_NTP_GETTIME /* Do we want support for Samba's signing daemon? */ #undef HAVE_NTP_SIGND -/* Define this if pathfind(3) works */ -#undef HAVE_PATHFIND +/* if you have NT Event Log */ +#undef HAVE_NT_EVENT_LOG + +/* if you have NT Service Manager */ +#undef HAVE_NT_SERVICE_MANAGER + +/* if you have NT Threads */ +#undef HAVE_NT_THREADS + +/* Define to 1 if the system has the type `pid_t'. */ +#undef HAVE_PID_T /* Define to 1 if you have the `plock' function. */ #undef HAVE_PLOCK @@ -553,8 +659,50 @@ /* Do we have the PPS API per the Draft RFC? */ #undef HAVE_PPSAPI -/* Are function prototypes OK? */ -#undef HAVE_PROTOTYPES +/* Define to 1 if you have the header file. */ +#undef HAVE_PRIV_H + +/* Define if you have POSIX threads libraries and header files. */ +#undef HAVE_PTHREAD + +/* define to pthreads API spec revision */ +#undef HAVE_PTHREADS + +/* Define to 1 if you have the `pthread_attr_getstacksize' function. */ +#undef HAVE_PTHREAD_ATTR_GETSTACKSIZE + +/* Define to 1 if you have the `pthread_attr_setstacksize' function. */ +#undef HAVE_PTHREAD_ATTR_SETSTACKSIZE + +/* define if you have pthread_detach function */ +#undef HAVE_PTHREAD_DETACH + +/* Define to 1 if you have the `pthread_getconcurrency' function. */ +#undef HAVE_PTHREAD_GETCONCURRENCY + +/* Define to 1 if you have the header file. */ +#undef HAVE_PTHREAD_H + +/* Define to 1 if you have the `pthread_kill' function. */ +#undef HAVE_PTHREAD_KILL + +/* Define to 1 if you have the `pthread_kill_other_threads_np' function. */ +#undef HAVE_PTHREAD_KILL_OTHER_THREADS_NP + +/* define if you have pthread_rwlock_destroy function */ +#undef HAVE_PTHREAD_RWLOCK_DESTROY + +/* Define to 1 if you have the `pthread_setconcurrency' function. */ +#undef HAVE_PTHREAD_SETCONCURRENCY + +/* Define to 1 if you have the `pthread_yield' function. */ +#undef HAVE_PTHREAD_YIELD + +/* Define to 1 if you have the header file. */ +#undef HAVE_PTH_H + +/* Define to 1 if the system has the type `ptrdiff_t'. */ +#undef HAVE_PTRDIFF_T /* Define to 1 if you have the `pututline' function. */ #undef HAVE_PUTUTLINE @@ -562,6 +710,18 @@ /* Define to 1 if you have the `pututxline' function. */ #undef HAVE_PUTUTXLINE +/* Define to 1 if you have the `RAND_bytes' function. */ +#undef HAVE_RAND_BYTES + +/* Define to 1 if you have the `RAND_poll' function. */ +#undef HAVE_RAND_POLL + +/* Define to 1 if you have the header file. */ +#undef HAVE_READLINE_H + +/* Define if your readline library has \`add_history' */ +#undef HAVE_READLINE_HISTORY + /* Define to 1 if you have the header file. */ #undef HAVE_READLINE_HISTORY_H @@ -571,22 +731,25 @@ /* Define to 1 if you have the `readlink' function. */ #undef HAVE_READLINK -/* Define this if we have a functional realpath(3C) */ -#undef HAVE_REALPATH - /* Define to 1 if you have the `recvmsg' function. */ #undef HAVE_RECVMSG /* Define to 1 if you have the header file. */ #undef HAVE_RESOLV_H +/* Define to 1 if you have the `res_init' function. */ +#undef HAVE_RES_INIT + +/* Do we have Linux routing socket? */ +#undef HAVE_RTNETLINK + /* Define to 1 if you have the `rtprio' function. */ #undef HAVE_RTPRIO -/* Should be obvious... */ -#undef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +/* Define to 1 if you have the header file. */ +#undef HAVE_RUNETYPE_H -/* Obvious... */ +/* Obvious */ #undef HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION /* Define to 1 if you have the header file. */ @@ -595,6 +758,15 @@ /* Define to 1 if you have the `sched_setscheduler' function. */ #undef HAVE_SCHED_SETSCHEDULER +/* Define to 1 if you have the `sched_yield' function. */ +#undef HAVE_SCHED_YIELD + +/* Define to 1 if you have the header file. */ +#undef HAVE_SEMAPHORE_H + +/* Define to 1 if you have the `sem_timedwait' function. */ +#undef HAVE_SEM_TIMEDWAIT + /* Define to 1 if you have the header file. */ #undef HAVE_SETJMP_H @@ -634,27 +806,36 @@ /* Define to 1 if you have the `sigset' function. */ #undef HAVE_SIGSET -/* Define to 1 if you have the `sigsuspend' function. */ -#undef HAVE_SIGSUSPEND - /* Define to 1 if you have the `sigvec' function. */ #undef HAVE_SIGVEC -/* Define to 1 if you have the `snprintf' function. */ -#undef HAVE_SNPRINTF +/* sigwait() available? */ +#undef HAVE_SIGWAIT -/* [Are Solaris privileges available?] */ -#undef HAVE_SOLARIS_PRIVS +/* Define to 1 if the system has the type `size_t'. */ +#undef HAVE_SIZE_T + +/* Define if C99-compliant `snprintf' is available. */ +#undef HAVE_SNPRINTF -/* Does struct sockaddr_storage have ss_family? */ -#undef HAVE_SS_FAMILY_IN_SS +/* Define to 1 if you have the `socketpair' function. */ +#undef HAVE_SOCKETPAIR -/* Does struct sockaddr_storage have ss_len? */ -#undef HAVE_SS_LEN_IN_SS +/* Are Solaris privileges available? */ +#undef HAVE_SOLARIS_PRIVS /* Define to 1 if you have the header file. */ #undef HAVE_STDARG_H +/* Define to 1 if you have the header file. */ +#undef HAVE_STDATOMIC_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDBOOL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDDEF_H + /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H @@ -673,8 +854,8 @@ /* Define to 1 if you have the `strerror' function. */ #undef HAVE_STRERROR -/* Define this if strftime() works */ -#undef HAVE_STRFTIME +/* Define to 1 if you have the `strerror_r' function. */ +#undef HAVE_STRERROR_R /* Define to 1 if you have the header file. */ #undef HAVE_STRINGS_H @@ -682,11 +863,29 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H +/* Define to 1 if you have the `strlcat' function. */ +#undef HAVE_STRLCAT + +/* Define to 1 if you have the `strlcpy' function. */ +#undef HAVE_STRLCPY + +/* Define to 1 if you have the header file. */ +#undef HAVE_STROPTS_H + /* Define to 1 if you have the `strrchr' function. */ #undef HAVE_STRRCHR -/* Define to 1 if you have the `strstr' function. */ -#undef HAVE_STRSTR +/* Define to 1 if you have the `strsignal' function. */ +#undef HAVE_STRSIGNAL + +/* Define to 1 if you have the `strtoll' function. */ +#undef HAVE_STRTOLL + +/* Define to 1 if `decimal_point' is a member of `struct lconv'. */ +#undef HAVE_STRUCT_LCONV_DECIMAL_POINT + +/* Define to 1 if `thousands_sep' is a member of `struct lconv'. */ +#undef HAVE_STRUCT_LCONV_THOUSANDS_SEP /* Do we have struct ntptimeval? */ #undef HAVE_STRUCT_NTPTIMEVAL @@ -703,30 +902,30 @@ /* Does a system header define struct sockaddr_storage? */ #undef HAVE_STRUCT_SOCKADDR_STORAGE -/* Do we have struct timespec? */ +/* struct timespec declared? */ #undef HAVE_STRUCT_TIMESPEC /* Define to 1 if you have the header file. */ #undef HAVE_SUN_AUDIOIO_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYNCH_H + /* Define to 1 if you have the `sysconf' function. */ #undef HAVE_SYSCONF -/* Define to 1 if you have the `sysctl' function. */ -#undef HAVE_SYSCTL - /* Define to 1 if you have the header file. */ #undef HAVE_SYSEXITS_H +/* */ +#undef HAVE_SYSLOG_FACILITYNAMES + /* Define to 1 if you have the header file. */ #undef HAVE_SYS_AUDIOIO_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_CAPABILITY_H -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_CLKDEFS_H - /* Define to 1 if you have the header file. */ #undef HAVE_SYS_CLOCKCTL_H @@ -801,9 +1000,6 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SYS_SIGNAL_H -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_SIO_H - /* Define to 1 if you have the header file. */ #undef HAVE_SYS_SOCKET_H @@ -858,6 +1054,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SYS_UN_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_VAR_H + /* Define to 1 if you have the header file. */ #undef HAVE_SYS_WAIT_H @@ -870,7 +1069,22 @@ /* Define to 1 if you have the header file. */ #undef HAVE_TERMIO_H -/* Obvious... */ +/* if you have Solaris LWP (thr) package */ +#undef HAVE_THR + +/* Define to 1 if you have the header file. */ +#undef HAVE_THREAD_H + +/* Define to 1 if you have the `thr_getconcurrency' function. */ +#undef HAVE_THR_GETCONCURRENCY + +/* Define to 1 if you have the `thr_setconcurrency' function. */ +#undef HAVE_THR_SETCONCURRENCY + +/* Define to 1 if you have the `thr_yield' function. */ +#undef HAVE_THR_YIELD + +/* Obvious */ #undef HAVE_TICKADJ_IN_STRUCT_CLOCKINFO /* Define to 1 if you have the `timegm' function. */ @@ -882,12 +1096,12 @@ /* Define to 1 if you have the `timer_create' function. */ #undef HAVE_TIMER_CREATE -/* Define to 1 if you have the `timer_settime' function. */ -#undef HAVE_TIMER_SETTIME - /* Define to 1 if you have the header file. */ #undef HAVE_TIMEX_H +/* Define to 1 if you have the header file. */ +#undef HAVE_TIME_H + /* Do we have the TIOCGPPSEV ioctl (Solaris)? */ #undef HAVE_TIOCGPPSEV @@ -897,12 +1111,6 @@ /* Do we have the TIO serial stuff? */ #undef HAVE_TIO_SERIAL_STUFF -/* Does u_int64_t exist? */ -#undef HAVE_TYPE_U_INT64_T - -/* Does u_int8_t exist? */ -#undef HAVE_TYPE_U_INT8_T - /* Define to 1 if the system has the type `uint16_t'. */ #undef HAVE_UINT16_T @@ -912,6 +1120,9 @@ /* Define to 1 if the system has the type `uint8_t'. */ #undef HAVE_UINT8_T +/* Define to 1 if the system has the type `uintmax_t'. */ +#undef HAVE_UINTMAX_T + /* Define to 1 if the system has the type `uintptr_t'. */ #undef HAVE_UINTPTR_T @@ -927,6 +1138,12 @@ /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H +/* deviant sigwait? */ +#undef HAVE_UNIXWARE_SIGWAIT + +/* Define to 1 if the system has the type `unsigned long long int'. */ +#undef HAVE_UNSIGNED_LONG_LONG_INT + /* Define to 1 if you have the `updwtmp' function. */ #undef HAVE_UPDWTMP @@ -942,20 +1159,50 @@ /* Define to 1 if you have the header file. */ #undef HAVE_UTMP_H +/* Define to 1 if the system has the type `u_int32'. */ +#undef HAVE_U_INT32 + +/* u_int32 type in DNS headers, not others. */ +#undef HAVE_U_INT32_ONLY_WITH_DNS + /* Define to 1 if you have the header file. */ #undef HAVE_VALUES_H /* Define to 1 if you have the header file. */ #undef HAVE_VARARGS_H +/* Define to 1 if you have the `vfork' function. */ +#undef HAVE_VFORK + +/* Define to 1 if you have the header file. */ +#undef HAVE_VFORK_H + /* Define to 1 if you have the `vprintf' function. */ #undef HAVE_VPRINTF -/* Define to 1 if you have the `vsnprintf' function. */ +/* Define if C99-compliant `vsnprintf' is available. */ #undef HAVE_VSNPRINTF -/* Define to 1 if you have the `vsprintf' function. */ -#undef HAVE_VSPRINTF +/* Define to 1 if you have the header file. */ +#undef HAVE_WCHAR_H + +/* Define to 1 if the system has the type `wchar_t'. */ +#undef HAVE_WCHAR_T + +/* Define to 1 if the system has the type `wint_t'. */ +#undef HAVE_WINT_T + +/* Define to 1 if `fork' works. */ +#undef HAVE_WORKING_FORK + +/* Define to 1 if `vfork' works. */ +#undef HAVE_WORKING_VFORK + +/* define if select implicitly yields */ +#undef HAVE_YIELDING_SELECT + +/* Define to 1 if you have the `_exit' function. */ +#undef HAVE__EXIT /* Define to 1 if you have the header file. */ #undef HAVE__SYS_SYNC_QUEUE_H @@ -966,21 +1213,51 @@ /* Define to 1 if you have the `__adjtimex' function. */ #undef HAVE___ADJTIMEX +/* defined if C compiler supports __attribute__((...)) */ +#undef HAVE___ATTRIBUTE__ + + + /* define away __attribute__() if unsupported */ + #ifndef HAVE___ATTRIBUTE__ + # define __attribute__(x) /* empty */ + #endif + #define ISC_PLATFORM_NORETURN_PRE + #define ISC_PLATFORM_NORETURN_POST __attribute__((__noreturn__)) + + + /* Define to 1 if you have the `__ntp_gettime' function. */ #undef HAVE___NTP_GETTIME +/* Define to 1 if you have the `__res_init' function. */ +#undef HAVE___RES_INIT + /* Does struct sockaddr_storage have __ss_family? */ #undef HAVE___SS_FAMILY_IN_SS -/* Does struct sockaddr_storage have __ss_len? */ -#undef HAVE___SS_LEN_IN_SS -/* [Retry queries on _any_ DNS error?] */ + /* Handle sockaddr_storage.__ss_family */ + #ifdef HAVE___SS_FAMILY_IN_SS + # define ss_family __ss_family + #endif /* HAVE___SS_FAMILY_IN_SS */ + + + +/* Define to provide `rpl_snprintf' function. */ +#undef HW_WANT_RPL_SNPRINTF + +/* Define to provide `rpl_vsnprintf' function. */ +#undef HW_WANT_RPL_VSNPRINTF + +/* Retry queries on _any_ DNS error? */ #undef IGNORE_DNS_ERRORS /* Should we use the IRIG sawtooth filter? */ #undef IRIG_SUCKS +/* Enclose PTHREAD_ONCE_INIT in extra braces? */ +#undef ISC_PLATFORM_BRACEPTHREADONCEINIT + /* Do we need to fix in6isaddr? */ #undef ISC_PLATFORM_FIXIN6ISADDR @@ -999,15 +1276,12 @@ /* have IPv6? */ #undef ISC_PLATFORM_HAVEIPV6 -/* ISC: struct sockaddr as sa_len? */ +/* struct sockaddr has sa_len? */ #undef ISC_PLATFORM_HAVESALEN -/* have sin6_scope_id? */ +/* sin6_scope_id? */ #undef ISC_PLATFORM_HAVESCOPEID -/* ISC: provide inet_aton() */ -#undef ISC_PLATFORM_NEEDATON - /* missing in6addr_any? */ #undef ISC_PLATFORM_NEEDIN6ADDRANY @@ -1017,18 +1291,24 @@ /* ISC: provide inet_ntop() */ #undef ISC_PLATFORM_NEEDNTOP -/* Do we need our own in_port_t? */ +/* Declare in_port_t? */ #undef ISC_PLATFORM_NEEDPORTT /* ISC: provide inet_pton() */ #undef ISC_PLATFORM_NEEDPTON +/* enable libisc thread support? */ +#undef ISC_PLATFORM_USETHREADS + /* Does the kernel have an FLL bug? */ #undef KERNEL_FLL_BUG /* Does the kernel support precision time discipline? */ #undef KERNEL_PLL +/* Define to use libseccomp system call filtering. */ +#undef KERN_SECCOMP + /* What is (probably) the name of DOSYNCTODR in the kernel? */ #undef K_DOSYNCTODR_NAME @@ -1041,25 +1321,51 @@ /* What is the name of TICK in the kernel? */ #undef K_TICK_NAME +/* define to 1 if library is thread safe */ +#undef LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE + +/* leap smear mechanism */ +#undef LEAP_SMEAR + +/* Define to any value to include libseccomp sandboxing. */ +#undef LIBSECCOMP + /* Should we align with the NIST lockclock scheme? */ #undef LOCKCLOCK -/* Does the kernel support multicasting IP? */ +/* Define to the sub-directory in which libtool stores uninstalled libraries. + */ +#undef LT_OBJDIR + +/* Does the target support multicast IP? */ #undef MCAST /* Should we recommend a minimum value for tickadj? */ #undef MIN_REC_TICKADJ +/* Define to 1 if the compiler does not support C99's structure + initialization. */ +#undef MISSING_C99_STRUCT_INIT + /* Do we need HPUX adjtime() library support? */ #undef NEED_HPUX_ADJTIME /* Do we want the HPUX FindConfig()? */ #undef NEED_HPUX_FINDCONFIG +/* We need to provide netsnmp_daemonize() */ +#undef NEED_NETSNMP_DAEMONIZE + +/* pthread_init() required? */ +#undef NEED_PTHREAD_INIT + +/* use PTHREAD_SCOPE_SYSTEM? */ +#undef NEED_PTHREAD_SCOPE_SYSTEM + /* Do we need the qnx adjtime call? */ #undef NEED_QNX_ADJTIME -/* Do we need extra room for SO_RCVBUF? (HPUX <8) */ +/* Do we need extra room for SO_RCVBUF? (HPUX < 8) */ #undef NEED_RCVBUF_SLOP /* Do we need an s_char typedef? */ @@ -1080,15 +1386,15 @@ /* Define to 1 if your C compiler doesn't accept -c and -o together. */ #undef NO_MINUS_C_MINUS_O -/* Define this if optional arguments are disallowed */ -#undef NO_OPTIONAL_OPT_ARGS - /* Should we avoid #warning on option name collisions? */ #undef NO_OPTION_NAME_WARNINGS -/* Is there a problem using PARENB and IGNPAR (IRIX)? */ +/* Is there a problem using PARENB and IGNPAR? */ #undef NO_PARENB_IGNPAR +/* define if you have (or want) no threads */ +#undef NO_THREADS + /* Default location of crypto key info */ #undef NTP_KEYSDIR @@ -1113,8 +1419,7 @@ /* need to recreate sockets on changed routing? */ #undef OS_MISSES_SPECIFIC_ROUTE_UPDATES -/* wildcard socket needs to set REUSEADDR when binding to interface addresses - */ +/* wildcard socket needs REUSEADDR to bind interface addresses */ #undef OS_NEEDS_REUSEADDR_FOR_IFADDRBIND /* Do we need to override the system's idea of HZ? */ @@ -1141,11 +1446,11 @@ /* Define to the version of this package. */ #undef PACKAGE_VERSION -/* Do we have the ppsclock streams module? */ -#undef PPS +/* data dir */ +#undef PERLLIBDIR -/* PPS auxiliary interface for ATOM? */ -#undef PPS_SAMPLE +/* define to a working POSIX compliant shell */ +#undef POSIX_SHELL /* PARSE kernel PLL PPS support */ #undef PPS_SYNC @@ -1156,32 +1461,32 @@ /* Preset a value for 'tickadj'? */ #undef PRESET_TICKADJ -/* Define to 1 if the C compiler supports function prototypes. */ -#undef PROTOTYPES - -/* Does qsort expect to work on "void *" stuff? */ -#undef QSORT_USES_VOID_P - /* Should we not IGNPAR (Linux)? */ #undef RAWDCF_NO_IGNPAR +/* enable thread safety */ +#undef REENTRANT + /* Basic refclock support? */ #undef REFCLOCK -/* name of regex header file */ -#undef REGEX_HEADER - /* Do we want the ReliantUNIX clock hacks? */ #undef RELIANTUNIX_CLOCK +/* define if sched_yield yields the entire process */ +#undef REPLACE_BROKEN_YIELD + /* Define as the return type of signal handlers (`int' or `void'). */ #undef RETSIGTYPE +/* saveconfig mechanism */ +#undef SAVECONFIG + /* Do we want the SCO clock hacks? */ #undef SCO5_CLOCK -/* The size of `char*', as computed by sizeof. */ -#undef SIZEOF_CHARP +/* The size of `char *', as computed by sizeof. */ +#undef SIZEOF_CHAR_P /* The size of `int', as computed by sizeof. */ #undef SIZEOF_INT @@ -1189,6 +1494,12 @@ /* The size of `long', as computed by sizeof. */ #undef SIZEOF_LONG +/* The size of `long long', as computed by sizeof. */ +#undef SIZEOF_LONG_LONG + +/* The size of `pthread_t', as computed by sizeof. */ +#undef SIZEOF_PTHREAD_T + /* The size of `short', as computed by sizeof. */ #undef SIZEOF_SHORT @@ -1204,8 +1515,13 @@ /* Slew always? */ #undef SLEWALWAYS -/* *s*printf() functions are char* */ -#undef SPRINTF_CHAR +/* If using the C implementation of alloca, define if you know the + direction of stack growth for your system; otherwise it will be + automatically deduced at runtime. + STACK_DIRECTION > 0 => grows toward higher addresses + STACK_DIRECTION < 0 => grows toward lower addresses + STACK_DIRECTION = 0 => direction of growth unknown */ +#undef STACK_DIRECTION /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS @@ -1213,18 +1529,24 @@ /* Step, then slew the clock? */ #undef STEP_SLEW +/* Define to 1 if strerror_r returns char *. */ +#undef STRERROR_R_CHAR_P + /* canonical system (cpu-vendor-os) of where we should run */ #undef STR_SYSTEM -/* Buggy syscall() (Solaris2.4)? */ -#undef SYSCALL_BUG - /* Does Xettimeofday take 1 arg? */ #undef SYSV_TIMEOFDAY /* Do we need to #define _SVID3 when we #include ? */ #undef TERMIOS_NEEDS__SVID3 +/* enable thread safety */ +#undef THREADSAFE + +/* enable thread safety */ +#undef THREAD_SAFE + /* Is K_TICKADJ_NAME in nanoseconds? */ #undef TICKADJ_NANO @@ -1237,9 +1559,6 @@ /* Define to 1 if your declares `struct tm'. */ #undef TM_IN_SYS_TIME -/* Do we have the tty_clk line discipline/streams module? */ -#undef TTYCLK - /* Provide a typedef for uintptr_t? */ #ifndef HAVE_UINTPTR_T typedef unsigned int uintptr_t; @@ -1252,33 +1571,14 @@ typedef unsigned int uintptr_t; /* Do we set process groups with -pid? */ #undef UDP_BACKWARDS_SETOWN -/* How do we create unsigned long constants? */ -#undef ULONG_CONST - /* Must we have a CTTY for fsetown? */ #undef USE_FSETOWNCTTY -/* Enable extensions on AIX 3, Interix. */ -#ifndef _ALL_SOURCE -# undef _ALL_SOURCE -#endif -/* Enable GNU extensions on systems that have them. */ -#ifndef _GNU_SOURCE -# undef _GNU_SOURCE -#endif -/* Enable threading extensions on Solaris. */ -#ifndef _POSIX_PTHREAD_SEMANTICS -# undef _POSIX_PTHREAD_SEMANTICS -#endif -/* Enable extensions on HP NonStop. */ -#ifndef _TANDEM_SOURCE -# undef _TANDEM_SOURCE -#endif -/* Enable general extensions on Solaris. */ -#ifndef __EXTENSIONS__ -# undef __EXTENSIONS__ -#endif +/* Use OpenSSL's crypto random functions */ +#undef USE_OPENSSL_CRYPTO_RAND +/* OK to use snprintb()? */ +#undef USE_SNPRINTB /* Can we use SIGPOLL for tty IO? */ #undef USE_TTY_SIGPOLL @@ -1289,15 +1589,12 @@ typedef unsigned int uintptr_t; /* Version number of package */ #undef VERSION +/* vsnprintf expands "%m" to strerror(errno) */ +#undef VSNPRINTF_PERCENT_M + /* configure --enable-ipv6 */ #undef WANT_IPV6 -/* Do we want the windows symmetric client hack? */ -#undef WINTIME - -/* Define this if a working libregex can be found */ -#undef WITH_LIBREGEX - /* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most significant byte first (like Motorola and SPARC, unlike Intel). */ #if defined AC_APPLE_UNIVERSAL_BUILD @@ -1310,15 +1607,8 @@ typedef unsigned int uintptr_t; # endif #endif -/* Handle ss_family */ -#if !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE___SS_FAMILY_IN_SS) -# define ss_family __ss_family -#endif /* !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE_SA_FAMILY_IN_SS) */ - -/* Handle ss_len */ -#if !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE___SS_LEN_IN_SS) -# define ss_len __ss_len -#endif /* !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE_SA_LEN_IN_SS) */ +/* routine worker child proc uses to exit. */ +#undef WORKER_CHILD_EXIT /* Define to 1 if on MINIX. */ #undef _MINIX @@ -1330,13 +1620,53 @@ typedef unsigned int uintptr_t; /* Define to 1 if you need to in order for `stat' and other things to work. */ #undef _POSIX_SOURCE +/* enable thread safety */ +#undef _REENTRANT + +/* enable thread safety */ +#undef _SGI_MP_SOURCE + +/* enable thread safety */ +#undef _THREADSAFE + +/* enable thread safety */ +#undef _THREAD_SAFE + +/* Define to 500 only on HP-UX. */ +#undef _XOPEN_SOURCE + +/* Are we _special_? */ +#undef __APPLE_USE_RFC_3542 + /* Define to 1 if type `char' is unsigned and you are not using gcc. */ #ifndef __CHAR_UNSIGNED__ # undef __CHAR_UNSIGNED__ #endif -/* Define like PROTOTYPES; this can be used by system headers. */ -#undef __PROTOTYPES +/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# undef _GNU_SOURCE +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# undef _POSIX_PTHREAD_SEMANTICS +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# undef _TANDEM_SOURCE +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# undef __EXTENSIONS__ +#endif + + +/* deviant */ +#undef adjtimex /* Define to empty if `const' does not conform to ANSI C. */ #undef const @@ -1350,20 +1680,89 @@ typedef unsigned int uintptr_t; #undef inline #endif +/* Define to the widest signed integer type if and do + not define. */ +#undef intmax_t + +/* deviant */ +#undef ntp_adjtime + +/* deviant */ +#undef ntp_gettime + /* Define to `long int' if does not define. */ #undef off_t +/* Define to `int' if does not define. */ +#undef pid_t + /* Define to `unsigned int' if does not define. */ #undef size_t -/* Define to `long' if does not define. */ -#undef time_t + + #if !defined(_KERNEL) && !defined(PARSESTREAM) + /* + * stdio.h must be included after _GNU_SOURCE is defined + * but before #define snprintf rpl_snprintf + */ + # include + #endif + + +/* Define to rpl_snprintf if the replacement function should be used. */ +#undef snprintf /* Define to `int' if doesn't define. */ #undef uid_t -/* Alternate uintptr_t for systems without it. */ +/* Define to the widest unsigned integer type if and + do not define. */ +#undef uintmax_t + +/* Define to the type of an unsigned integer type wide enough to hold a + pointer, if such a type exists, and if the system does not define it. */ #undef uintptr_t -/* Does the compiler like "volatile"? */ +/* Define as `fork' if `vfork' does not work. */ +#undef vfork + +/* Define to empty if the keyword `volatile' does not work. Warning: valid + code using `volatile' can become incorrect without. Disable with care. */ #undef volatile + +/* Define to rpl_vsnprintf if the replacement function should be used. */ +#undef vsnprintf + + +#ifndef MPINFOU_PREDECLARED +# define MPINFOU_PREDECLARED +typedef union mpinfou { + struct pdk_mpinfo *pdkptr; + struct mpinfo *pikptr; +} mpinfou_t; +#endif + + + + #if !defined(_KERNEL) && !defined(PARSESTREAM) + # if defined(HW_WANT_RPL_VSNPRINTF) + # if defined(__cplusplus) + extern "C" { + # endif + # include + int rpl_vsnprintf(char *, size_t, const char *, va_list); + # if defined(__cplusplus) + } + # endif + # endif + # if defined(HW_WANT_RPL_SNPRINTF) + # if defined(__cplusplus) + extern "C" { + # endif + int rpl_snprintf(char *, size_t, const char *, ...); + # if defined(__cplusplus) + } + # endif + # endif + #endif /* !defined(_KERNEL) && !defined(PARSESTREAM) */ + diff --git a/contrib/ntp/config.sub b/contrib/ntp/config.sub index 1c366dfde..f9fcdc879 100755 --- a/contrib/ntp/config.sub +++ b/contrib/ntp/config.sub @@ -1,9 +1,10 @@ #! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011 Free Software Foundation, Inc. -timestamp='2005-07-08' +timestamp='2011-06-03' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -31,13 +32,16 @@ timestamp='2005-07-08' # Please send patches to . Submit a context -# diff and a properly formatted ChangeLog entry. +# diff and a properly formatted GNU ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD + # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. @@ -71,8 +75,9 @@ Report bugs and patches to ." version="\ GNU config.sub ($timestamp) -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free +Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -119,8 +124,11 @@ esac # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in - nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \ - kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) + nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ + linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ + knetbsd*-gnu* | netbsd*-gnu* | \ + kopensolaris*-gnu* | \ + storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; @@ -146,10 +154,13 @@ case $os in -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ - -apple | -axis | -knuth | -cray) + -apple | -axis | -knuth | -cray | -microblaze) os= basic_machine=$1 ;; + -bluegene*) + os=-cnk + ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 @@ -164,13 +175,17 @@ case $os in os=-chorusos basic_machine=$1 ;; - -chorusrdb) - os=-chorusrdb + -chorusrdb) + os=-chorusrdb basic_machine=$1 - ;; + ;; -hiux*) os=-hiuxwe2 ;; + -sco6) + os=-sco5v6 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` @@ -187,6 +202,10 @@ case $os in # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; + -sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` @@ -231,20 +250,24 @@ case $basic_machine in | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ - | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \ + | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ - | fr30 | frv \ + | fido | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ - | m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \ + | lm32 \ + | m32c | m32r | m32rle | m68000 | m68k | m88k \ + | maxq | mb | microblaze | mcore | mep | metag \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ - | mips64vr | mips64vrel \ + | mips64octeon | mips64octeonel \ | mips64orion | mips64orionel \ + | mips64r5900 | mips64r5900el \ + | mips64vr | mips64vrel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ @@ -257,35 +280,63 @@ case $basic_machine in | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ - | ms1 \ + | moxie \ + | mt \ | msp430 \ + | nds32 | nds32le | nds32be \ + | nios | nios2 \ | ns16k | ns32k \ + | open8 \ | or32 \ | pdp10 | pdp11 | pj | pjl \ - | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ + | powerpc | powerpc64 | powerpc64le | powerpcle \ | pyramid \ - | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \ + | rx \ + | score \ + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc86x | sparclet | sparclite \ - | sparcv8 | sparcv9 | sparcv9b \ - | strongarm \ - | tahoe | thumb | tic4x | tic80 | tron \ - | v850 | v850e \ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ + | spu \ + | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ + | ubicom32 \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ | we32k \ - | x86 | xscale | xscalee[bl] | xstormy16 | xtensa \ - | z8k) + | x86 | xc16x | xstormy16 | xtensa \ + | z8k | z80) basic_machine=$basic_machine-unknown ;; - m32c) - basic_machine=$basic_machine-unknown + c54x) + basic_machine=tic54x-unknown ;; - m6811 | m68hc11 | m6812 | m68hc12) + c55x) + basic_machine=tic55x-unknown + ;; + c6x) + basic_machine=tic6x-unknown + ;; + m6811 | m68hc11 | m6812 | m68hc12 | picochip) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; + ms1) + basic_machine=mt-unknown + ;; + + strongarm | thumb | xscale) + basic_machine=arm-unknown + ;; + + xscaleeb) + basic_machine=armeb-unknown + ;; + + xscaleel) + basic_machine=armel-unknown + ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and @@ -305,25 +356,28 @@ case $basic_machine in | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ - | avr-* \ + | avr-* | avr32-* \ | bfin-* | bs2000-* \ - | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ + | c[123]* | c30-* | [cjt]90-* | c4x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ - | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \ + | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ - | m32r-* | m32rle-* \ + | lm32-* \ + | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ - | m88110-* | m88k-* | maxq-* | mcore-* \ + | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ - | mips64vr-* | mips64vrel-* \ + | mips64octeon-* | mips64octeonel-* \ | mips64orion-* | mips64orionel-* \ + | mips64r5900-* | mips64r5900el-* \ + | mips64vr-* | mips64vrel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ @@ -336,30 +390,38 @@ case $basic_machine in | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ - | ms1-* \ + | mt-* \ | msp430-* \ + | nds32-* | nds32le-* | nds32be-* \ + | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ + | open8-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ - | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ | pyramid-* \ - | romp-* | rs6000-* \ - | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | shbe-* \ + | romp-* | rs6000-* | rx-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ - | sparc-* | sparc64-* | sparc64b-* | sparc86x-* | sparclet-* \ + | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ - | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ - | tahoe-* | thumb-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ + | tahoe-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tile*-* \ | tron-* \ - | v850-* | v850e-* | vax-* \ + | ubicom32-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ | we32k-* \ - | x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \ - | xstormy16-* | xtensa-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* \ + | xstormy16-* | xtensa*-* \ | ymp-* \ - | z8k-*) + | z8k-* | z80-*) ;; - m32c-*) + # Recognize the basic CPU types without company name, with glob match. + xtensa*) + basic_machine=$basic_machine-unknown ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. @@ -377,7 +439,7 @@ case $basic_machine in basic_machine=a29k-amd os=-udi ;; - abacus) + abacus) basic_machine=abacus-unknown ;; adobe68k) @@ -423,6 +485,10 @@ case $basic_machine in basic_machine=m68k-apollo os=-bsd ;; + aros) + basic_machine=i386-pc + os=-aros + ;; aux) basic_machine=m68k-apple os=-aux @@ -431,10 +497,35 @@ case $basic_machine in basic_machine=ns32k-sequent os=-dynix ;; + blackfin) + basic_machine=bfin-unknown + os=-linux + ;; + blackfin-*) + basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + bluegene*) + basic_machine=powerpc-ibm + os=-cnk + ;; + c54x-*) + basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c55x-*) + basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c6x-*) + basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; c90) basic_machine=c90-cray os=-unicos ;; + cegcc) + basic_machine=arm-unknown + os=-cegcc + ;; convex-c1) basic_machine=c1-convex os=-bsd @@ -463,8 +554,8 @@ case $basic_machine in basic_machine=craynv-cray os=-unicosmp ;; - cr16c) - basic_machine=cr16c-unknown + cr16 | cr16-*) + basic_machine=cr16-unknown os=-elf ;; crds | unos) @@ -502,6 +593,10 @@ case $basic_machine in basic_machine=m88k-motorola os=-sysv3 ;; + dicos) + basic_machine=i686-pc + os=-dicos + ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp @@ -656,6 +751,14 @@ case $basic_machine in basic_machine=m68k-isi os=-sysv ;; + m68knommu) + basic_machine=m68k-unknown + os=-linux + ;; + m68knommu-*) + basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; m88k-omron*) basic_machine=m88k-omron ;; @@ -667,10 +770,17 @@ case $basic_machine in basic_machine=ns32k-utek os=-sysv ;; + microblaze) + basic_machine=microblaze-xilinx + ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; + mingw32ce) + basic_machine=arm-unknown + os=-mingw32ce + ;; miniframe) basic_machine=m68000-convergent ;; @@ -696,6 +806,9 @@ case $basic_machine in basic_machine=i386-pc os=-msdos ;; + ms1-*) + basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` + ;; mvs) basic_machine=i370-ibm os=-mvs @@ -764,6 +877,12 @@ case $basic_machine in np1) basic_machine=np1-gould ;; + neo-tandem) + basic_machine=neo-tandem + ;; + nse-tandem) + basic_machine=nse-tandem + ;; nsr-tandem) basic_machine=nsr-tandem ;; @@ -794,6 +913,14 @@ case $basic_machine in basic_machine=i860-intel os=-osf ;; + parisc) + basic_machine=hppa-unknown + os=-linux + ;; + parisc-*) + basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; pbd) basic_machine=sparc-tti ;; @@ -803,6 +930,12 @@ case $basic_machine in pc532 | pc532-*) basic_machine=ns32k-pc532 ;; + pc98) + basic_machine=i386-pc + ;; + pc98-*) + basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; @@ -832,9 +965,10 @@ case $basic_machine in ;; power) basic_machine=power-ibm ;; - ppc) basic_machine=powerpc-unknown + ppc | ppcbe) basic_machine=powerpc-unknown ;; - ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + ppc-* | ppcbe-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown @@ -859,6 +993,10 @@ case $basic_machine in basic_machine=i586-unknown os=-pw32 ;; + rdos) + basic_machine=i386-pc + os=-rdos + ;; rom68k) basic_machine=m68k-rom68k os=-coff @@ -885,6 +1023,10 @@ case $basic_machine in sb1el) basic_machine=mipsisa64sb1el-unknown ;; + sde) + basic_machine=mipsisa32-sde + os=-elf + ;; sei) basic_machine=mips-sei os=-seiux @@ -896,6 +1038,9 @@ case $basic_machine in basic_machine=sh-hitachi os=-hms ;; + sh5el) + basic_machine=sh5le-unknown + ;; sh64) basic_machine=sh64-unknown ;; @@ -917,6 +1062,9 @@ case $basic_machine in basic_machine=i860-stratus os=-sysv4 ;; + strongarm-* | thumb-*) + basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; sun2) basic_machine=m68000-sun ;; @@ -973,17 +1121,9 @@ case $basic_machine in basic_machine=t90-cray os=-unicos ;; - tic54x | c54x*) - basic_machine=tic54x-unknown - os=-coff - ;; - tic55x | c55x*) - basic_machine=tic55x-unknown - os=-coff - ;; - tic6x | c6x*) - basic_machine=tic6x-unknown - os=-coff + tile*) + basic_machine=$basic_machine-unknown + os=-linux-gnu ;; tx39) basic_machine=mipstx39-unknown @@ -1052,6 +1192,9 @@ case $basic_machine in xps | xps100) basic_machine=xps100-honeywell ;; + xscale-* | xscalee[bl]-*) + basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + ;; ymp) basic_machine=ymp-cray os=-unicos @@ -1060,6 +1203,10 @@ case $basic_machine in basic_machine=z8k-unknown os=-sim ;; + z80-*-coff) + basic_machine=z80-unknown + os=-sim + ;; none) basic_machine=none-none os=-none @@ -1098,10 +1245,10 @@ case $basic_machine in we32k) basic_machine=we32k-att ;; - sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) + sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; - sparc | sparcv8 | sparcv9 | sparcv9b) + sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) basic_machine=sparc-sun ;; cydra) @@ -1145,9 +1292,12 @@ esac if [ x"$os" != x"" ] then case $os in - # First match some system type aliases - # that might get confused with valid system types. + # First match some system type aliases + # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. + -auroraux) + os=-auroraux + ;; -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; @@ -1168,27 +1318,31 @@ case $os in # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ - | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ - | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ - | -aos* \ + | -aos* | -aros* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \ + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -chorusos* | -chorusrdb* \ + | -chorusos* | -chorusrdb* | -cegcc* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \ + | -mingw32* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-uclibc* \ + | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ - | -skyos* | -haiku*) + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) @@ -1227,7 +1381,7 @@ case $os in -opened*) os=-openedition ;; - -os400*) + -os400*) os=-os400 ;; -wince*) @@ -1276,7 +1430,7 @@ case $os in -sinix*) os=-sysv4 ;; - -tpf*) + -tpf*) os=-tpf ;; -triton*) @@ -1318,6 +1472,11 @@ case $os in -zvmoe) os=-zvmoe ;; + -dicos*) + os=-dicos + ;; + -nacl*) + ;; -none) ;; *) @@ -1340,6 +1499,12 @@ else # system, and we'll never get to this point. case $basic_machine in + score-*) + os=-elf + ;; + spu-*) + os=-elf + ;; *-acorn) os=-riscix1.2 ;; @@ -1349,9 +1514,18 @@ case $basic_machine in arm*-semi) os=-aout ;; - c4x-* | tic4x-*) - os=-coff - ;; + c4x-* | tic4x-*) + os=-coff + ;; + tic54x-*) + os=-coff + ;; + tic55x-*) + os=-coff + ;; + tic6x-*) + os=-coff + ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 @@ -1377,6 +1551,9 @@ case $basic_machine in m68*-cisco) os=-aout ;; + mep-*) + os=-elf + ;; mips*-cisco) os=-elf ;; @@ -1401,7 +1578,7 @@ case $basic_machine in *-ibm) os=-aix ;; - *-knuth) + *-knuth) os=-mmixware ;; *-wec) @@ -1506,7 +1683,7 @@ case $basic_machine in -sunos*) vendor=sun ;; - -aix*) + -cnk*|-aix*) vendor=ibm ;; -beos*) diff --git a/contrib/ntp/configure b/contrib/ntp/configure index fa7716da5..04813a8d5 100755 --- a/contrib/ntp/configure +++ b/contrib/ntp/configure @@ -1,11 +1,11 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.65 for ntp 4.2.4p8. +# Generated by GNU Autoconf 2.69 for ntp 4.2.8p4. # +# Report bugs to . # -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# +# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. # # # This configure script is free software; the Free Software Foundation @@ -89,6 +89,7 @@ fi IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. +as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -133,6 +134,31 @@ export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# Use a proper internal environment variable to ensure we don't fall + # into an infinite loop, continuously re-executing ourselves. + if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then + _as_can_reexec=no; export _as_can_reexec; + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +as_fn_exit 255 + fi + # We don't want this to propagate to other subprocesses. + { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh @@ -166,12 +192,21 @@ if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi -test x\$exitcode = x0 || exit 1" +test x\$exitcode = x0 || exit 1 +test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 -test \$(( 1 + 1 )) = 2 || exit 1" +test \$(( 1 + 1 )) = 2 || exit 1 + + test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ + || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else @@ -211,14 +246,25 @@ IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : - # We cannot yet assume a decent shell, so we have to provide a - # neutralization value for shells without unset; and this also - # works around shells that cannot unset nonexistent variables. - BASH_ENV=/dev/null - ENV=/dev/null - (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV - export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} + export CONFIG_SHELL + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 fi if test x$as_have_required = xno; then : @@ -228,10 +274,11 @@ fi $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else - $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, -$0: including any error possibly output before this -$0: message. Then install a modern shell, or manually run -$0: the script under such a shell if you do have one." + $as_echo "$0: Please tell bug-autoconf@gnu.org and +$0: http://bugs.ntp.org./ about your system, including any +$0: error possibly output before this message. Then install +$0: a modern shell, or manually run the script under such a +$0: shell if you do have one." fi exit 1 fi @@ -316,10 +363,18 @@ $as_echo X"$as_dir" | test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take @@ -356,19 +411,19 @@ else fi # as_fn_arith -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. +# script with STATUS, using 1 if that was 0. as_fn_error () { - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi - $as_echo "$as_me: error: $1" >&2 + $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error @@ -441,6 +496,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + # If we had to re-execute with $CONFIG_SHELL, we're ensured to have + # already done that, so ensure we don't try to do so again and fall + # in an infinite loop. This has already happened in practice. + _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). @@ -475,16 +534,16 @@ if (echo >conf$$.file) 2>/dev/null; then # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. + # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' + as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null @@ -496,28 +555,8 @@ else as_mkdir_p=false fi -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x +as_test_x='test -x' +as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" @@ -525,162 +564,14 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -# Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} -case X$ECHO in -X*--fallback-echo) - # Remove one level of quotation (which was required for Make). - ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','` - ;; -esac - -echo=${ECHO-echo} -if test "X$1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X$1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then - # Yippee, $echo works! - : -else - # Restart under the correct shell. - exec $SHELL "$0" --no-reexec ${1+"$@"} -fi - -if test "X$1" = X--fallback-echo; then - # used as fallback echo - shift - cat </dev/null 2>&1 && unset CDPATH - -if test -z "$ECHO"; then -if test "X${echo_test_string+set}" != Xset; then -# find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if (echo_test_string=`eval $cmd`) 2>/dev/null && - echo_test_string=`eval $cmd` && - (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null - then - break - fi - done -fi - -if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : -else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. - - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for dir in $PATH /usr/ucb; do - IFS="$lt_save_ifs" - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$dir/echo" - break - fi - done - IFS="$lt_save_ifs" - - if test "X$echo" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - echo='print -r' - elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running configure again with it. - ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"} - else - # Try using printf. - echo='printf %s\n' - if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # Cool, printf works - : - elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - echo="$CONFIG_SHELL $0 --fallback-echo" - elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$CONFIG_SHELL $0 --fallback-echo" - else - # maybe with a smaller string... - prev=: - - for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do - if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null - then - break - fi - prev="$cmd" - done - - if test "$prev" != 'sed 50q "$0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"} - else - # Oops. We lost completely, so just stick with echo. - echo=echo - fi - fi - fi - fi -fi -fi - -# Copy echo and quote the copy suitably for passing to libtool from -# the Makefile, instead of quoting the original, which is used later. -ECHO=$echo -if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then - ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo" -fi - - - test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. -# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, +# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` @@ -699,10 +590,10 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='ntp' PACKAGE_TARNAME='ntp' -PACKAGE_VERSION='4.2.4p8' -PACKAGE_STRING='ntp 4.2.4p8' -PACKAGE_BUGREPORT='' -PACKAGE_URL='' +PACKAGE_VERSION='4.2.8p4' +PACKAGE_STRING='ntp 4.2.8p4' +PACKAGE_BUGREPORT='http://bugs.ntp.org./' +PACKAGE_URL='http://www.ntp.org./' # Factoring default headers for most tests. ac_includes_default="\ @@ -740,62 +631,226 @@ ac_includes_default="\ # include #endif" +ac_header_list= enable_option_checking=no ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS -LIBOBJS +subdirs +PERLLIBDIR +NTP_KEYSDIR +BUILD_TEST_NTP_SIGND_FALSE +BUILD_TEST_NTP_SIGND_TRUE +BUILD_TEST_NTP_SCANNER_FALSE +BUILD_TEST_NTP_SCANNER_TRUE +BUILD_TEST_NTP_RESTRICT_FALSE +BUILD_TEST_NTP_RESTRICT_TRUE +GTEST_AVAILABLE_FALSE +GTEST_AVAILABLE_TRUE +GTEST_CPPFLAGS +GTEST_CXXFLAGS +GTEST_LIBS +GTEST_LDFLAGS +GTEST_CONFIG +UNITYBUILD_AVAILABLE_FALSE +UNITYBUILD_AVAILABLE_TRUE +PATH_RUBY +HAVE_LEAPSMEARINTERVAL +SAVECONFIG_ENABLED_FALSE +SAVECONFIG_ENABLED_TRUE LSCF +MAKE_NTPSNMPD +SNMP_CFLAGS +SNMP_CPPFLAGS +SNMP_LIBS +BUILD_SNTP_FALSE +BUILD_SNTP_TRUE +SNTP MAKE_NTPDSIM MAKE_LIBNTPSIM MAKE_TIMETRIM MAKE_TICKADJ MAKE_NTPTIME MAKE_ADJTIMED -CLKTEST CHUTEST PROPDELAY MAKE_PARSEKMODULE DCFD TESTDCF MAKE_CHECK_LAYOUT -EF_LIBS -EF_PROGS -LCRYPTO -OPENSSL_LIB -OPENSSL_INC -OPENSSL +VER_SUFFIX MAKE_CHECK_Y2K MAKE_LIBPARSE_KERNEL MAKE_LIBPARSE LIBPARSE -HAVE_INLINE -ANSI2KNR -U -READLINE_LIBS +HAVE_RLIMIT_STACK +HAVE_RLIMIT_MEMLOCK +LDADD_NLIST +PATH_NET_SNMP_CONFIG +CONFIG_SHELL +PATH_TEST PATH_PERL -PATH_SH -LIBTOOL -RANLIB -AR -ECHO -LN_S -ARLIB_DIR -subdirs -BINSUBDIR +LIBOBJS +PTHREADS_FALSE +PTHREADS_TRUE +LIBISC_PTHREADS_NOTHREADS +PTHREAD_LIBS +LTHREAD_LIBS +BUILD_THREAD +HAVE_INLINE +LDADD_LIBUTIL +ALLOCA +LIBM +EDITLINE_LIBS +LDADD_LIBNTP +NTP_CROSSCOMPILE_FALSE +NTP_CROSSCOMPILE_TRUE +BUILD_LIBEVENT_FALSE +BUILD_LIBEVENT_TRUE +LDADD_LIBEVENT +CPPFLAGS_LIBEVENT +CFLAGS_LIBEVENT +PKG_CONFIG +LIBOPTS_DIR LIBOPTS_CFLAGS LIBOPTS_LDADD NEED_LIBOPTS_FALSE NEED_LIBOPTS_TRUE INSTALL_LIBOPTS_FALSE INSTALL_LIBOPTS_TRUE -LIBOPTS_DIR +POSIX_SHELL +GL_GENERATE_STDNORETURN_H_FALSE +GL_GENERATE_STDNORETURN_H_TRUE +STDNORETURN_H +LIBTOOL_DEPS +CXXCPP +OTOOL64 +OTOOL +LIPO +NMEDIT +DSYMUTIL +MANIFEST_TOOL +RANLIB +DLLTOOL +OBJDUMP +LN_S +NM +ac_ct_DUMPBIN +DUMPBIN +LD +FGREP +SED +LIBTOOL +ac_ct_AR +AR +INSTALL_UPDATE_LEAP_FALSE +INSTALL_UPDATE_LEAP_TRUE +UPDATE_LEAP_NI +UPDATE_LEAP_MS +UPDATE_LEAP_DS +UPDATE_LEAP_DL +UPDATE_LEAP_DB +TIMETRIM_NI +TIMETRIM_MS +TIMETRIM_DS +TIMETRIM_DL +TIMETRIM_DB +TICKADJ_NI +TICKADJ_MS +TICKADJ_DS +TICKADJ_DL +TICKADJ_DB +SNTP_NI +SNTP_MS +SNTP_DS +SNTP_DL +SNTP_DB +NTP_WAIT_NI +NTP_WAIT_MS +NTP_WAIT_DS +NTP_WAIT_DL +NTP_WAIT_DB +NTP_KEYGEN_NI +NTP_KEYGEN_MS +NTP_KEYGEN_DS +NTP_KEYGEN_DL +NTP_KEYGEN_DB +NTPTRACE_NI +NTPTRACE_MS +NTPTRACE_DS +NTPTRACE_DL +NTPTRACE_DB +NTPTIME_NI +NTPTIME_MS +NTPTIME_DS +NTPTIME_DL +NTPTIME_DB +INSTALL_NTPSWEEP_FALSE +INSTALL_NTPSWEEP_TRUE +NTPSWEEP_NI +NTPSWEEP_MS +NTPSWEEP_DS +NTPSWEEP_DL +NTPSWEEP_DB +NTPSNMPD_NI +NTPSNMPD_MS +NTPSNMPD_DS +NTPSNMPD_DL +NTPSNMPD_DB +NTPQ_NI +NTPQ_MS +NTPQ_DS +NTPQ_DL +NTPQ_DB +NTPD_NI +NTPD_MS +NTPD_DS +NTPD_DL +NTPD_DB +NTPDSIM_NI +NTPDSIM_MS +NTPDSIM_DS +NTPDSIM_DL +NTPDSIM_DB +NTPDC_NI +NTPDC_MS +NTPDC_DS +NTPDC_DL +NTPDC_DB +NTPDATE_NI +NTPDATE_MS +NTPDATE_DS +NTPDATE_DL +NTPDATE_DB +MANTAGFMT +CALC_TICKADJ_NI +CALC_TICKADJ_MS +CALC_TICKADJ_DS +CALC_TICKADJ_DL +CALC_TICKADJ_DB +WANT_CALC_TICKADJ_MS_FALSE +WANT_CALC_TICKADJ_MS_TRUE +VPATH_HACK_FALSE +VPATH_HACK_TRUE +YFLAGS +YACC +am__fastdepCXX_FALSE +am__fastdepCXX_TRUE +CXXDEPMODE +ac_ct_CXX +CXXFLAGS +CXX +LDFLAGS_NTP +LDADD_NTP +CPPFLAGS_NTP +CFLAGS_NTP EGREP GREP CPP am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE +am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE @@ -817,6 +872,10 @@ build_os build_vendor build_cpu build +AM_BACKSLASH +AM_DEFAULT_VERBOSITY +AM_DEFAULT_V +AM_V am__untar am__tar AMTAR @@ -878,30 +937,43 @@ PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL' -ac_subst_files='' +ac_subst_files='calc_tickadj_opts +ntp_wait_opts +ntpsweep_opts +ntptrace_opts +summary_opts +plot_summary_opts' ac_user_opts=' enable_option_checking +enable_silent_rules enable_dependency_tracking +with_locfile enable_shared -enable_local_libopts -enable_libopts_install -with_autoopts_config -with_regex_header -with_libregex -with_libregex_cflags -with_libregex_libs -enable_optional_args -with_binsubdir -with_arlib -with_rpath enable_static +with_pic enable_fast_install with_gnu_ld +with_sysroot enable_libtool_lock -with_pic -with_tags -enable_getifaddrs +enable_nls +enable_local_libopts +enable_libopts_install +with_autoopts_config +enable_local_libevent +with_lineeditlibs enable_debugging +enable_thread_support +with_threads +with_yielding_select +enable_c99_snprintf +enable_clockctl +enable_linuxcaps +enable_solarisprivs +with_arlib +with_net_snmp_config +enable_libseccomp +with_stack_limit +with_memlock enable_debug_timing enable_dst_minutes enable_ignore_dns_errors @@ -931,6 +1003,7 @@ enable_LOCAL_CLOCK enable_MX4200 enable_NEOCLOCK4X enable_NMEA +enable_GPSD enable_ONCORE enable_PALISADE enable_PCF @@ -942,6 +1015,7 @@ enable_TPRO enable_TRUETIME enable_TT560 enable_ULINK +enable_TSYNCPCI enable_WWV enable_ZYFER enable_parse_clocks @@ -956,28 +1030,36 @@ enable_TRIMTAIP enable_TRIMTSIP enable_WHARTON enable_VARITEXT +enable_SEL240X +with_crypto with_openssl_libdir with_openssl_incdir -with_crypto -with_electricfence +with_rpath +enable_openssl_random +enable_autokey enable_kmem enable_accurate_adjtime enable_tick enable_tickadj enable_simulator +with_sntp +with_ntpsnmpd enable_slew_always enable_step_slew enable_ntpdate_step enable_hourly_todr_sync enable_kernel_fll_bug +enable_bug1243_fix enable_irig_sawtooth enable_nist enable_ntp_signd -enable_wintime -enable_clockctl -enable_linuxcaps enable_ipv6 with_kame +enable_getifaddrs +enable_saveconfig +enable_leap_smear +with_gtest +enable_problem_tests ' ac_precious_vars='build_alias host_alias @@ -987,9 +1069,14 @@ CFLAGS LDFLAGS LIBS CPPFLAGS -CPP' -ac_subdirs_all='arlib -sntp' +CPP +CXX +CXXFLAGS +CCC +YACC +YFLAGS +CXXCPP' +ac_subdirs_all='sntp' # Initialize some variables set by options. ac_init_help= @@ -1051,8 +1138,9 @@ do fi case $ac_option in - *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *) ac_optarg=yes ;; + *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; + *=) ac_optarg= ;; + *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. @@ -1097,7 +1185,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" + as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1123,7 +1211,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" + as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1327,7 +1415,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" + as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1343,7 +1431,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" + as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1373,8 +1461,8 @@ do | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; - -*) as_fn_error "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information." + -*) as_fn_error $? "unrecognized option: \`$ac_option' +Try \`$0 --help' for more information" ;; *=*) @@ -1382,7 +1470,7 @@ Try \`$0 --help' for more information." # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error "invalid variable name: \`$ac_envvar'" ;; + as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; @@ -1392,7 +1480,7 @@ Try \`$0 --help' for more information." $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac @@ -1400,13 +1488,13 @@ done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error "missing argument to $ac_option" + as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; - fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; + fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi @@ -1429,7 +1517,7 @@ do [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac - as_fn_error "expected an absolute directory name for --$ac_var: $ac_val" + as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' @@ -1443,8 +1531,6 @@ target=$target_alias if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe - $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. - If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi @@ -1459,9 +1545,9 @@ test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error "working directory cannot be determined" + as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error "pwd does not report name of working directory" + as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. @@ -1500,11 +1586,11 @@ else fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" + as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg" + cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then @@ -1530,7 +1616,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures ntp 4.2.4p8 to adapt to many kinds of systems. +\`configure' configures ntp 4.2.8p4 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1544,7 +1630,7 @@ Configuration: --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking...' messages + -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files @@ -1600,32 +1686,58 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of ntp 4.2.4p8:";; + short | recursive ) echo "Configuration of ntp 4.2.8p4:";; esac cat <<\_ACEOF -Optional Features: +Optional Features and Packages: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --enable-silent-rules less verbose build output (undo: "make V=1") + --disable-silent-rules verbose build output (undo: "make V=0") + --enable-dependency-tracking + do not reject slow dependency extractors + --disable-dependency-tracking + speeds up one-time build + --with-locfile=XXX os-specific or "legacy" --enable-shared[=PKGS] build shared libraries [default=no] - --enable-local-libopts Force using the supplied libopts tearoff code - --disable-libopts-install - Do not install libopts with client installation - --disable-optional-args not wanting optional option args --enable-static[=PKGS] build static libraries [default=yes] + --with-pic try to use only PIC/non-PIC objects [default=use + both] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] + --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-sysroot=DIR Search for dependent libraries within DIR + (or the compiler's sysroot if not specified). --disable-libtool-lock avoid locking (might break parallel builds) - --enable-getifaddrs s Enable the use of getifaddrs() [[yes|no|glibc]]. - glibc: Use getifaddrs() in glibc if you know it - supports IPv6. - --enable-debugging + include debugging code + --disable-nls disable nls support in libopts + --enable-local-libopts Use the supplied libopts tearoff code + --enable-libopts-install + Install libopts with client installation + --with-autoopts-config specify the config-info script + --enable-local-libevent Force using the supplied libevent tearoff code + --with-lineeditlibs edit,editline (readline may be specified if desired) + defaults: + yes, - no, s system-specific + --enable-debugging + include ntpd debugging code + --enable-thread-support s use threads (+ if available) + --with-threads with threads [auto] + --with-yielding-select with yielding select [auto] + --enable-c99-snprintf s force replacement + --enable-clockctl s Use /dev/clockctl for non-root clock control + --enable-linuxcaps + Use Linux capabilities for non-root clock control + --enable-solarisprivs + Use Solaris privileges for non-root clock control + --with-arlib - deprecated, arlib not distributed + --with-net-snmp-config + =net-snmp-config + --enable-libseccomp EXPERIMENTAL: enable support for libseccomp + sandboxing (default is no) + --with-stack-limit ? =50 (200 for openbsd) 4k pages + --with-memlock ? =32 (-1 on linux) megabytes --enable-debug-timing - include processing time debugging code (costs performance) - --enable-dst-minutes n minutes per DST adjustment [60] + --enable-dst-minutes =60 minutes per DST adjustment --enable-ignore-dns-errors - retry DNS queries on any error --enable-BANCOMM - Datum/Bancomm bc635/VME interface @@ -1654,6 +1766,7 @@ Optional Features: --enable-MX4200 s Magnavox MX4200 GPS receiver --enable-NEOCLOCK4X + NeoClock4X DCF77 / TDF receiver --enable-NMEA + NMEA GPS receiver + --enable-GPSD + GPSD JSON receiver --enable-ONCORE s Motorola VP/UT Oncore GPS receiver --enable-PALISADE s Palisade clock --enable-PCF + Conrad parallel port radio clock @@ -1665,6 +1778,7 @@ Optional Features: --enable-TRUETIME s Kinemetrics/TrueTime receivers --enable-TT560 - TrueTime 560 IRIG-B decoder --enable-ULINK + Ultralink WWVB receiver + --enable-TSYNCPCI s Spectracom TSYNC timing board --enable-WWV s WWV Audio receiver --enable-ZYFER + Zyfer GPStarplus receiver --enable-parse-clocks - include all suitable PARSE clocks: @@ -1679,47 +1793,45 @@ Optional Features: --enable-TRIMTSIP s Trimble GPS receiver/TSIP protocol --enable-WHARTON s WHARTON 400A Series clock --enable-VARITEXT s VARITEXT clock + --enable-SEL240X s SEL240X clock + --with-crypto + =openssl,libcrypto + + --with-openssl-libdir + =/something/reasonable + + --with-openssl-incdir + =/something/reasonable + + --without-rpath s Disable auto-added -R linker paths + + --enable-openssl-random Use OpenSSL's crypto random number functions, if + available (default is yes) + --enable-autokey + support NTP Autokey protocol --enable-kmem s read /dev/kmem for tick and/or tickadj --enable-accurate-adjtime s the adjtime() call is accurate --enable-tick=VALUE s force a value for 'tick' --enable-tickadj=VALUE s force a value for 'tickadj' --enable-simulator - build/install the NTPD simulator? + --without-sntp - disable building sntp and sntp/tests + --with-ntpsnmpd s Build ntpsnmpd MIB agent? --enable-slew-always s always slew the time --enable-step-slew s step and slew the time --enable-ntpdate-step s if ntpdate should step the time --enable-hourly-todr-sync s if we should sync TODR hourly --enable-kernel-fll-bug s if we should avoid a kernel FLL bug + --enable-bug1243-fix + use unmodified autokey session keys --enable-irig-sawtooth s if we should enable the IRIG sawtooth filter --enable-nist - if we should enable the NIST lockclock scheme --enable-ntp-signd - Provide support for Samba's signing daemon, =/var/run/ntp_signd - --enable-wintime - Provide the windows symmetric client hack - --enable-clockctl s Use /dev/clockctl for non-root clock control - --enable-linuxcaps + Use Linux capabilities for non-root clock control --enable-ipv6 s use IPv6? -Optional Packages: - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-autoopts-config specify the config-info script - --with-regex-header a reg expr header is specified - --with-libregex libregex installation prefix - --with-libregex-cflags libregex compile flags - --with-libregex-libs libregex link command arguments - --with-binsubdir bin ={bin,sbin} - --with-arlib - Compile the async resolver library? - --without-rpath s Disable auto-added -R linker paths - --with-gnu-ld assume the C compiler uses GNU ld [default=no] - --with-pic try to use only PIC/non-PIC objects [default=use - both] - --with-tags[=TAGS] include additional configurations [automatic] - --with-openssl-libdir + =/something/reasonable - --with-openssl-incdir + =/something/reasonable - --with-crypto + =openssl - --with-electricfence - compile with ElectricFence malloc debugger --with-kame - =/usr/local/v6 + --enable-getifaddrs + Enable the use of getifaddrs() [[yes|no]]. + --enable-saveconfig + saveconfig mechanism + --enable-leap-smear - experimental leap smear code + --with-gtest Use the gtest framework (Default: if it's available) + --enable-problem-tests + enable tests with undiagnosed problems Some influential environment variables: CC C compiler command @@ -1730,11 +1842,21 @@ Some influential environment variables: CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor + CXX C++ compiler command + CXXFLAGS C++ compiler flags + YACC The `Yet Another Compiler Compiler' implementation to use. + Defaults to the first program found out of: `bison -y', `byacc', + `yacc'. + YFLAGS The list of arguments that will be passed by default to $YACC. + This script will default YFLAGS to the empty string to avoid a + default value of `-d' given by some make applications. + CXXCPP C++ preprocessor Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. -Report bugs to the package provider. +Report bugs to . +ntp home page: . _ACEOF ac_status=$? fi @@ -1797,10 +1919,10 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -ntp configure 4.2.4p8 -generated by GNU Autoconf 2.65 +ntp configure 4.2.8p4 +generated by GNU Autoconf 2.69 -Copyright (C) 2009 Free Software Foundation, Inc. +Copyright (C) 2012 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF @@ -1844,7 +1966,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile @@ -1870,7 +1992,7 @@ $as_echo "$ac_try_echo"; } >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } >/dev/null && { + test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : @@ -1881,7 +2003,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp @@ -1894,10 +2016,10 @@ fi ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : + if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 @@ -1933,7 +2055,7 @@ if ac_fn_c_try_cpp "$LINENO"; then : else ac_header_preproc=no fi -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } @@ -1956,11 +2078,15 @@ $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} +( $as_echo "## ------------------------------------ ## +## Report this to http://bugs.ntp.org./ ## +## ------------------------------------ ##" + ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" @@ -1969,7 +2095,7 @@ eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel @@ -2010,7 +2136,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run @@ -2024,7 +2150,7 @@ ac_fn_c_check_header_compile () as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -2042,7 +2168,7 @@ fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile @@ -2073,7 +2199,7 @@ $as_echo "$ac_try_echo"; } >&5 test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext + test -x conftest$ac_exeext }; then : ac_retval=0 else @@ -2087,90 +2213,279 @@ fi # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () +# ac_fn_cxx_try_compile LINENO +# ---------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_compile + +# ac_fn_c_check_func LINENO FUNC VAR +# ---------------------------------- +# Tests whether FUNC exists, setting the cache variable VAR accordingly +ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$4 +/* Define $2 to an innocuous variant, in case declares $2. + For example, HP-UX 11i declares gettimeofday. */ +#define $2 innocuous_$2 + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $2 (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $2 + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $2 (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$2 || defined __stub___$2 +choke me +#endif + int main () { -if (sizeof (($2))) - return 0; +return $2 (); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else +if ac_fn_c_try_link "$LINENO"; then : eval "$3=yes" +else + eval "$3=no" fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno -} # ac_fn_c_check_type +} # ac_fn_c_check_func -# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES -# -------------------------------------------- -# Tries to find the compile-time value of EXPR in a program that includes -# INCLUDES, setting VAR accordingly. Returns whether the value could be -# computed -ac_fn_c_compute_int () +# ac_fn_cxx_try_cpp LINENO +# ------------------------ +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -static int test_array [1 - 2 * !(($2) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_lo=0 ac_mid=0 + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_cpp + +# ac_fn_cxx_try_link LINENO +# ------------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_link + +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type + +# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES +# -------------------------------------------- +# Tries to find the compile-time value of EXPR in a program that includes +# INCLUDES, setting VAR accordingly. Returns whether the value could be +# computed +ac_fn_c_compute_int () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if test "$cross_compiling" = yes; then + # Depending upon the size, compute the lo and hi bounds. +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) >= 0)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_lo=0 ac_mid=0 while :; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -2179,7 +2494,8 @@ int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2205,7 +2521,8 @@ int main () { static int test_array [1 - 2 * !(($2) < 0)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2221,7 +2538,8 @@ int main () { static int test_array [1 - 2 * !(($2) >= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2255,7 +2573,8 @@ int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2319,77 +2638,56 @@ rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ rm -f conftest.val fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_compute_int -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () +# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES +# --------------------------------------------- +# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR +# accordingly. +ac_fn_c_check_decl () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : + as_decl_name=`echo $2|sed 's/ *(.*//'` + as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 +$as_echo_n "checking whether $as_decl_name is declared... " >&6; } +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ +$4 +int +main () +{ +#ifndef $as_decl_name #ifdef __cplusplus -extern "C" + (void) $as_decl_use; +#else + (void) $as_decl_name; #endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me #endif -int -main () -{ -return $2 (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno -} # ac_fn_c_check_func +} # ac_fn_c_check_decl # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES # ---------------------------------------------------- @@ -2400,7 +2698,7 @@ ac_fn_c_check_member () as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 $as_echo_n "checking for $2.$3... " >&6; } -if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$4+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -2444,15 +2742,15 @@ fi eval ac_res=\$$4 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_member cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by ntp $as_me 4.2.4p8, which was -generated by GNU Autoconf 2.65. Invocation command line was +It was created by ntp $as_me 4.2.8p4, which was +generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -2562,11 +2860,9 @@ trap 'exit_status=$? { echo - cat <<\_ASBOX -## ---------------- ## + $as_echo "## ---------------- ## ## Cache variables. ## -## ---------------- ## -_ASBOX +## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( @@ -2600,11 +2896,9 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; ) echo - cat <<\_ASBOX -## ----------------- ## + $as_echo "## ----------------- ## ## Output variables. ## -## ----------------- ## -_ASBOX +## ----------------- ##" echo for ac_var in $ac_subst_vars do @@ -2617,11 +2911,9 @@ _ASBOX echo if test -n "$ac_subst_files"; then - cat <<\_ASBOX -## ------------------- ## + $as_echo "## ------------------- ## ## File substitutions. ## -## ------------------- ## -_ASBOX +## ------------------- ##" echo for ac_var in $ac_subst_files do @@ -2635,11 +2927,9 @@ _ASBOX fi if test -s confdefs.h; then - cat <<\_ASBOX -## ----------- ## + $as_echo "## ----------- ## ## confdefs.h. ## -## ----------- ## -_ASBOX +## ----------- ##" echo cat confdefs.h echo @@ -2694,7 +2984,12 @@ _ACEOF ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then - ac_site_file1=$CONFIG_SITE + # We do not want a PATH search for config.site. + case $CONFIG_SITE in #(( + -*) ac_site_file1=./$CONFIG_SITE;; + */*) ac_site_file1=$CONFIG_SITE;; + *) ac_site_file1=./$CONFIG_SITE;; + esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site @@ -2709,7 +3004,11 @@ do { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" + . "$ac_site_file" \ + || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "failed to load site script $ac_site_file +See \`config.log' for more details" "$LINENO" 5; } fi done @@ -2730,6 +3029,7 @@ $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi +as_fn_append ac_header_list " stdarg.h" # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false @@ -2785,7 +3085,7 @@ if $ac_cache_corrupted; then $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 + as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## @@ -2798,20 +3098,25 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $ ac_compiler_gnu=$ac_cv_c_compiler_gnu -am__api_version='1.11' ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do - for ac_t in install-sh install.sh shtool; do - if test -f "$ac_dir/$ac_t"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/$ac_t -c" - break 2 - fi - done +for ac_dir in sntp/libevent/build-aux "$srcdir"/sntp/libevent/build-aux; do + if test -f "$ac_dir/install-sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f "$ac_dir/install.sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + elif test -f "$ac_dir/shtool"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break + fi done if test -z "$ac_aux_dir"; then - as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 + as_fn_error $? "cannot find install-sh, install.sh, or shtool in sntp/libevent/build-aux \"$srcdir\"/sntp/libevent/build-aux" "$LINENO" 5 fi # These three variables are undocumented and unsupported, @@ -2823,6 +3128,144 @@ ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + +# Bump ntp_configure_cache_version for each change to configure.ac or +# .m4 files which invalidates cached values from previous configure +# runs. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of each. If you are not sure, the +# safe choice is to bump all on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +ntp_configure_cache_version=20120806 + +# When the cache version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + + + + ntp_cache_flush=1 + + case "$ntp_cv_main_cache_version" in + $ntp_configure_cache_version) + # same version, good + ntp_cache_flush=0 + ;; + '') + # No cache, predates ntp_cv_main_cache_version, or is empty. + case "$cache_file" in + /dev/null) + ntp_cache_flush=0 + ;; + *) + case "$NTP_CACHEVERSION_PARENT" in + '') + # Do not clear the cache immediately after it is created + # empty as it is noisy. Differentiate a newly-created + # config.cache from one predating the cache version + # mechanism by looking for the first cached variable set + # by Autoconf + case "$ac_cv_path_install" in + '') + # empty config.cache file + ntp_cache_flush=0 + esac + ;; + *) + # Parent configure just created cache from empty, + # flushing would be counterproductive. + ntp_cache_flush=0; + ;; + esac + esac + ;; + *) + # configure cache version mismatches config.cache version + ;; + esac + + case "$ntp_cache_flush" in + 1) + c_version="${ntp_cv_main_cache_version:-(no version found)}" + + # Do we flush all variables or exclude others' version stamps? + + case "$NTP_CACHEVERSION_PARENT" in + '') + # Clear all *_cv_* variables including our child subdirs' + # ntp_cv_*_cache_version variables. This prevents subdir + # configure scripts from noticing a version mismatch just + # after the top configure in the invocation cleared and + # recreated the cache. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/_cv_/p' + ` + ;; + *) + # This is not the top configure this particular invocation. + # Clear all *_cv_* variables sparing the version stamps + # of other configure scripts, so we don't trigger + # useless repeated clearings. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/ntp_cv_.*_cache_version/d' \ + -e '/_cv_/p' + ` + esac + + for c_varname in $c_varname_list + do + { eval $c_varname=; unset $c_varname; } + done + + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file saved by another version, ignored." >&5 +$as_echo "$as_me: $cache_file saved by another version, ignored." >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: configure script cache version: $ntp_configure_cache_version" >&5 +$as_echo "$as_me: configure script cache version: $ntp_configure_cache_version" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file version: $c_version" >&5 +$as_echo "$as_me: $cache_file version: $c_version" >&6;} + { c_varname=; unset c_varname;} + { c_varname_list=; unset c_varname_list;} + { c_version=; unset c_version;} + esac + + { ntp_cache_flush=; unset ntp_cache_flush;} + + # save configure version in config.cache for next time + ntp_cv_main_cache_version="$ntp_configure_cache_version" + + # let any subdir configure.ac NTP_CACHEVERSION invocations + # know they are not the top level. + NTP_CACHEVERSION_PARENT='main' ; export NTP_CACHEVERSION_PARENT + + +am__api_version='1.15' + # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: @@ -2840,7 +3283,7 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then -if test "${ac_cv_path_install+set}" = set; then : +if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -2860,7 +3303,7 @@ case $as_dir/ in #(( # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. @@ -2918,56 +3361,71 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } -# Just in case -sleep 1 -echo timestamp > conftest.file # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[\\\"\#\$\&\'\`$am_lf]*) - as_fn_error "unsafe absolute working directory name" "$LINENO" 5;; + as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; + as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; esac -# Do `set' in a subshell so we don't clobber the current shell's +# Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error "ls -t appears to fail. Make sure there is not a broken -alias in your environment" "$LINENO" 5 - fi - + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$*" != "X $srcdir/configure conftest.file" \ + && test "$*" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken + alias in your environment" "$LINENO" 5 + fi + if test "$2" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done test "$2" = conftest.file ) then # Ok. : else - as_fn_error "newly created file is older than distributed files! + as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi + +rm -f conftest.file + test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. @@ -2978,8 +3436,8 @@ test "$program_suffix" != NONE && ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` if test x"${MISSING+set}" != xset; then case $am_aux_dir in @@ -2990,15 +3448,15 @@ if test x"${MISSING+set}" != xset; then esac fi # Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " else am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} fi -if test x"${install_sh}" != xset; then +if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; @@ -3007,17 +3465,17 @@ if test x"${install_sh}" != xset; then esac fi -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. +# will honor the 'STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then : +if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then @@ -3029,7 +3487,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3057,7 +3515,7 @@ if test -z "$ac_cv_prog_STRIP"; then set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then @@ -3069,7 +3527,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3110,7 +3568,7 @@ INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } if test -z "$MKDIR_P"; then - if test "${ac_cv_path_mkdir+set}" = set; then : + if ${ac_cv_path_mkdir+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -3120,7 +3578,7 @@ do test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do - { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue + as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ @@ -3149,19 +3607,13 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } -mkdir_p="$MKDIR_P" -case $mkdir_p in - [\\/$]* | ?:[\\/]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac - for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AWK+set}" = set; then : +if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then @@ -3173,7 +3625,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3201,7 +3653,7 @@ done $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF @@ -3209,7 +3661,7 @@ SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF -# GNU make sometimes prints "make[1]: Entering...", which would confuse us. +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; @@ -3237,13 +3689,52 @@ else fi rmdir .tst 2>/dev/null +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=1;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then - as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 + as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi fi @@ -3259,7 +3750,7 @@ fi # Define the identity of the package. PACKAGE='ntp' - VERSION='4.2.4p8' + VERSION='4.2.8p4' cat >>confdefs.h <<_ACEOF @@ -3287,41 +3778,135 @@ AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -# Always define AMTAR for backward compatibility. +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +mkdir_p='$(MKDIR_P)' + +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AMTAR='$${TAR-tar}' + + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar pax cpio none' + +am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' + + + + -AMTAR=${AMTAR-"${am_missing_run}tar"} -am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 + fi +fi + + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=0;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 + as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } -if test "${ac_cv_build+set}" = set; then : +if ${ac_cv_build+:} false; then : $as_echo_n "(cached) " >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && - as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5 + as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 $as_echo "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; -*) as_fn_error "invalid value of canonical build" "$LINENO" 5;; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' @@ -3339,14 +3924,14 @@ case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } -if test "${ac_cv_host+set}" = set; then : +if ${ac_cv_host+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 fi fi @@ -3354,7 +3939,7 @@ fi $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; -*) as_fn_error "invalid value of canonical host" "$LINENO" 5;; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' @@ -3378,14 +3963,11 @@ _ACEOF ac_config_headers="$ac_config_headers config.h" - -ac_cv_var_atom_ok=no -ac_cv_var_oncore_ok=no -ac_cv_var_parse_ok=no -ac_cv_var_ripe_ncc_ok=no -ac_cv_var_jupiter_ok=no - -iCFLAGS="$CFLAGS" +ntp_atom_ok=${ntp_atom_ok=no} +ntp_oncore_ok=${ntp_oncore_ok=no} +ntp_parse_ok=${ntp_parse_ok=no} +ntp_ripe_ncc_ok=${ntp_parse_ok=no} +ntp_jupiter_ok=${ntp_jupiter_ok=no} DEPDIR="${am__leading_dot}deps" @@ -3406,7 +3988,7 @@ am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. +# Ignore all kinds of additional output from 'make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include @@ -3439,6 +4021,7 @@ fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' + am__nodep='_no' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= @@ -3459,7 +4042,7 @@ if test -n "$ac_tool_prefix"; then set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3471,7 +4054,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3499,7 +4082,7 @@ if test -z "$ac_cv_prog_CC"; then set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -3511,7 +4094,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3552,7 +4135,7 @@ if test -z "$CC"; then set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3564,7 +4147,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3592,7 +4175,7 @@ if test -z "$CC"; then set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3605,7 +4188,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue @@ -3651,7 +4234,7 @@ if test -z "$CC"; then set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3663,7 +4246,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3695,7 +4278,7 @@ do set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -3707,7 +4290,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3749,8 +4332,8 @@ fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "no acceptable C compiler found in \$PATH -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 @@ -3864,9 +4447,8 @@ sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "C compiler cannot create executables -See \`config.log' for more details." "$LINENO" 5; }; } +as_fn_error 77 "C compiler cannot create executables +See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } @@ -3908,8 +4490,8 @@ done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "cannot compute suffix of executables: cannot compile and link +See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 @@ -3966,9 +4548,9 @@ $as_echo "$ac_try_echo"; } >&5 else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot run C compiled programs. +as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. -See \`config.log' for more details." "$LINENO" 5; } +See \`config.log' for more details" "$LINENO" 5; } fi fi fi @@ -3979,7 +4561,7 @@ rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } -if test "${ac_cv_objext+set}" = set; then : +if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -4019,8 +4601,8 @@ sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of object files: cannot compile -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "cannot compute suffix of object files: cannot compile +See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi @@ -4030,7 +4612,7 @@ OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then : +if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -4067,7 +4649,7 @@ ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then : +if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag @@ -4145,7 +4727,7 @@ else fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : +if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no @@ -4154,8 +4736,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include -#include -#include +struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); @@ -4240,19 +4821,79 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } -if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then : +if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -4286,16 +4927,16 @@ else : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with `-c' and `-o' for the sake of the "dashmstdout" + # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in @@ -4304,16 +4945,16 @@ else test "$am__universal" = false || continue ;; nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} @@ -4380,7 +5021,7 @@ if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then : + if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded @@ -4410,7 +5051,7 @@ else # Broken: fails on valid input. continue fi -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. @@ -4426,11 +5067,11 @@ else ac_preproc_ok=: break fi -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext +rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi @@ -4469,7 +5110,7 @@ else # Broken: fails on valid input. continue fi -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. @@ -4485,18 +5126,18 @@ else ac_preproc_ok=: break fi -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext +rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c @@ -4508,7 +5149,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then : +if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then @@ -4522,7 +5163,7 @@ do for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue + as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in @@ -4557,7 +5198,7 @@ esac done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then - as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP @@ -4571,7 +5212,7 @@ $as_echo "$ac_cv_path_GREP" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then : +if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 @@ -4588,7 +5229,7 @@ do for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue + as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in @@ -4623,7 +5264,7 @@ esac done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then - as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP @@ -4638,7 +5279,7 @@ $as_echo "$ac_cv_path_EGREP" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : +if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -4755,8 +5396,7 @@ do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default " -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -4767,8 +5407,10 @@ done + + ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" -if test "x$ac_cv_header_minix_config_h" = x""yes; then : +if test "x$ac_cv_header_minix_config_h" = xyes; then : MINIX=yes else MINIX= @@ -4787,17 +5429,25 @@ $as_echo "#define _MINIX 1" >>confdefs.h fi + case "$host_os" in + hpux*) + +$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h + + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } -if test "${ac_cv_safe_to_define___extensions__+set}" = set; then : +if ${ac_cv_safe_to_define___extensions__+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -# define __EXTENSIONS__ 1 - $ac_includes_default +# define __EXTENSIONS__ 1 + $ac_includes_default int main () { @@ -4828,99 +5478,341 @@ $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } - - -# So far, the only shared library we might use is libopts. -# It's a small library - we might as well use a static version of it. -# Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then : - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if ${ac_cv_prog_cc_c89+:} false; then : + $as_echo_n "(cached) " >&6 else - enable_shared=no -fi - + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +struct stat; +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break done - done -IFS=$as_save_IFS +rm -f conftest.$ac_ext +CC=$ac_save_CC fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c89" != xno; then : + fi -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5 +$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } +if ${ac_cv_prog_cc_c99+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS + ac_cv_prog_cc_c99=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include +#include + +// Check varargs macros. These examples are taken from C99 6.10.3.5. +#define debug(...) fprintf (stderr, __VA_ARGS__) +#define showlist(...) puts (#__VA_ARGS__) +#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) +static void +test_varargs_macros (void) +{ + int x = 1234; + int y = 5678; + debug ("Flag"); + debug ("X = %d\n", x); + showlist (The first, second, and third items.); + report (x>y, "x is %d but y is %d", x, y); +} + +// Check long long types. +#define BIG64 18446744073709551615ull +#define BIG32 4294967295ul +#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) +#if !BIG_OK + your preprocessor is broken; +#endif +#if BIG_OK +#else + your preprocessor is broken; +#endif +static long long int bignum = -9223372036854775807LL; +static unsigned long long int ubignum = BIG64; + +struct incomplete_array +{ + int datasize; + double data[]; +}; + +struct named_init { + int number; + const wchar_t *name; + double average; +}; + +typedef const char *ccp; + +static inline int +test_restrict (ccp restrict text) +{ + // See if C++-style comments work. + // Iterate through items via the restricted pointer. + // Also check for declarations in for loops. + for (unsigned int i = 0; *(text+i) != '\0'; ++i) + continue; + return 0; +} + +// Check varargs and va_copy. +static void +test_varargs (const char *format, ...) +{ + va_list args; + va_start (args, format); + va_list args_copy; + va_copy (args_copy, args); + + const char *str; + int number; + float fnumber; + + while (*format) + { + switch (*format++) + { + case 's': // string + str = va_arg (args_copy, const char *); + break; + case 'd': // int + number = va_arg (args_copy, int); + break; + case 'f': // float + fnumber = va_arg (args_copy, double); + break; + default: + break; + } + } + va_end (args_copy); + va_end (args); +} + +int +main () +{ + + // Check bool. + _Bool success = false; + + // Check restrict. + if (test_restrict ("String literal") == 0) + success = true; + char *restrict newvar = "Another string"; + + // Check varargs. + test_varargs ("s, d' f .", "string", 65, 34.234); + test_varargs_macros (); + + // Check flexible array members. + struct incomplete_array *ia = + malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); + ia->datasize = 10; + for (int i = 0; i < ia->datasize; ++i) + ia->data[i] = i * 1.234; + + // Check named initializers. + struct named_init ni = { + .number = 34, + .name = L"Test wide string", + .average = 543.34343, + }; + + ni.number = 58; + + int dynamic_array[ni.number]; + dynamic_array[ni.number - 1] = 543; + + // work around unused variable warnings + return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' + || dynamic_array[ni.number - 1] != 543); + + ; + return 0; +} +_ACEOF +for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99 +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c99=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c99" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC + +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c99" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c99" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 +$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c99" != xno; then : + +fi + + + + + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -4961,7 +5853,7 @@ if test -z "$CC"; then set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -4973,7 +5865,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -5001,7 +5893,7 @@ if test -z "$CC"; then set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -5014,7 +5906,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue @@ -5060,7 +5952,7 @@ if test -z "$CC"; then set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -5072,7 +5964,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -5104,7 +5996,7 @@ do set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -5116,7 +6008,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -5158,8 +6050,8 @@ fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "no acceptable C compiler found in \$PATH -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 @@ -5188,7 +6080,7 @@ done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then : +if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -5225,7 +6117,7 @@ ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then : +if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag @@ -5303,7 +6195,7 @@ else fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : +if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no @@ -5312,8 +6204,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include -#include -#include +struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); @@ -5398,29 +6289,89 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu -depcc="$CC" am_compiler_list= - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then : +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : $as_echo_n "(cached) " >&6 else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +depcc="$CC" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CC_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object # directory. mkdir sub @@ -5444,16 +6395,16 @@ else : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with `-c' and `-o' for the sake of the "dashmstdout" + # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in @@ -5462,16 +6413,16 @@ else test "$am__universal" = false || continue ;; nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} @@ -5527,16 +6478,74 @@ fi # Ralf Wildenhues: With per-target flags we need CC_C_O # AM_PROG_CC_C_O supersets AC_PROG_CC_C_O -if test "x$CC" != xcc; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5 -$as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; } + +if test $ac_cv_c_compiler_gnu = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 +$as_echo_n "checking whether $CC needs -traditional... " >&6; } +if ${ac_cv_prog_gcc_traditional+:} false; then : + $as_echo_n "(cached) " >&6 else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5 -$as_echo_n "checking whether cc understands -c and -o together... " >&6; } + ac_pattern="Autoconf.*'x'" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TIOCGETP +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes +else + ac_cv_prog_gcc_traditional=no fi -set dummy $CC; ac_cc=`$as_echo "$2" | - sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` -if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then : +rm -f conftest* + + + if test $ac_cv_prog_gcc_traditional = no; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TCGETA +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes +fi +rm -f conftest* + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 +$as_echo "$ac_cv_prog_gcc_traditional" >&6; } + if test $ac_cv_prog_gcc_traditional = yes; then + CC="$CC -traditional" + fi +fi + + + + + +CFLAGS_NTP= +CPPFLAGS_NTP= +LDADD_NTP= +LDFLAGS_NTP= + + + + + +case "$ac_cv_prog_cc_c89" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP + version 4.2.5 and higher." >&5 +$as_echo "$as_me: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP + version 4.2.5 and higher." >&2;} + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5 +$as_echo_n "checking if $CC can handle #warning... " >&6; } +if ${ntp_cv_cpp_warning+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -5545,2935 +6554,2774 @@ else int main () { - +#warning foo ; return 0; } _ACEOF -# Make sure it works both with $CC and with simple cc. -# We do the test twice because some compilers refuse to overwrite an -# existing .o file with -o, though they will create one. -ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' -rm -f conftest2.* -if { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && - test -f conftest2.$ac_objext && { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; -then - eval ac_cv_prog_cc_${ac_cc}_c_o=yes - if test "x$CC" != xcc; then - # Test first that cc exists at all. - if { ac_try='cc -c conftest.$ac_ext >&5' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5' - rm -f conftest2.* - if { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && - test -f conftest2.$ac_objext && { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; - then - # cc works too. - : - else - # cc exists but doesn't like -o. - eval ac_cv_prog_cc_${ac_cc}_c_o=no - fi - fi - fi +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_cpp_warning=yes else - eval ac_cv_prog_cc_${ac_cc}_c_o=no + ntp_cv_cpp_warning=no + fi -rm -f core conftest* +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cpp_warning" >&5 +$as_echo "$ntp_cv_cpp_warning" >&6; } +case "$ntp_cv_cpp_warning" in + no) + +$as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports __attribute__((...))" >&5 +$as_echo_n "checking if $CC supports __attribute__((...))... " >&6; } +if ${ntp_cv_cc_attribute+:} false; then : + $as_echo_n "(cached) " >&6 else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h +int +main () +{ +void foo(void) __attribute__((__noreturn__)); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_cc_attribute=yes +else + ntp_cv_cc_attribute=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# FIXME: we rely on the cache variable name because -# there is no other way. -set dummy $CC -am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` -eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o -if test "$am_t" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cc_attribute" >&5 +$as_echo "$ntp_cv_cc_attribute" >&6; } +case "$ntp_cv_cc_attribute" in + yes) +$as_echo "#define HAVE___ATTRIBUTE__ /**/" >>confdefs.h - case $ac_cv_prog_cc_stdc in #( - no) : - ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #( - *) : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5 -$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } -if test "${ac_cv_prog_cc_c99+set}" = set; then : +esac + + +case "$GCC" in + yes) + SAVED_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Wstrict-overflow" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Wstrict-overflow" >&5 +$as_echo_n "checking if $CC can handle -Wstrict-overflow... " >&6; } +if ${ntp_cv_gcc_Wstrict_overflow+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_prog_cc_c99=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include -#include -#include -// Check varargs macros. These examples are taken from C99 6.10.3.5. -#define debug(...) fprintf (stderr, __VA_ARGS__) -#define showlist(...) puts (#__VA_ARGS__) -#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) -static void -test_varargs_macros (void) +int +main () { - int x = 1234; - int y = 5678; - debug ("Flag"); - debug ("X = %d\n", x); - showlist (The first, second, and third items.); - report (x>y, "x is %d but y is %d", x, y); -} - -// Check long long types. -#define BIG64 18446744073709551615ull -#define BIG32 4294967295ul -#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) -#if !BIG_OK - your preprocessor is broken; -#endif -#if BIG_OK -#else - your preprocessor is broken; -#endif -static long long int bignum = -9223372036854775807LL; -static unsigned long long int ubignum = BIG64; - -struct incomplete_array -{ - int datasize; - double data[]; -}; - -struct named_init { - int number; - const wchar_t *name; - double average; -}; - -typedef const char *ccp; -static inline int -test_restrict (ccp restrict text) -{ - // See if C++-style comments work. - // Iterate through items via the restricted pointer. - // Also check for declarations in for loops. - for (unsigned int i = 0; *(text+i) != '\0'; ++i) - continue; + ; return 0; } +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_gcc_Wstrict_overflow=yes +else + ntp_cv_gcc_Wstrict_overflow=no -// Check varargs and va_copy. -static void -test_varargs (const char *format, ...) -{ - va_list args; - va_start (args, format); - va_list args_copy; - va_copy (args_copy, args); +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - const char *str; - int number; - float fnumber; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Wstrict_overflow" >&5 +$as_echo "$ntp_cv_gcc_Wstrict_overflow" >&6; } + # + # $ntp_cv_gcc_Wstrict_overflow is tested later to add the + # flag to CFLAGS. + # + CFLAGS="$SAVED_CFLAGS -Winit-self" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Winit-self" >&5 +$as_echo_n "checking if $CC can handle -Winit-self... " >&6; } +if ${ntp_cv_gcc_Winit_self+:} false; then : + $as_echo_n "(cached) " >&6 +else - while (*format) - { - switch (*format++) - { - case 's': // string - str = va_arg (args_copy, const char *); - break; - case 'd': // int - number = va_arg (args_copy, int); - break; - case 'f': // float - fnumber = va_arg (args_copy, double); - break; - default: - break; - } - } - va_end (args_copy); - va_end (args); -} + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ int main () { - // Check bool. - _Bool success = false; - - // Check restrict. - if (test_restrict ("String literal") == 0) - success = true; - char *restrict newvar = "Another string"; - - // Check varargs. - test_varargs ("s, d' f .", "string", 65, 34.234); - test_varargs_macros (); - - // Check flexible array members. - struct incomplete_array *ia = - malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); - ia->datasize = 10; - for (int i = 0; i < ia->datasize; ++i) - ia->data[i] = i * 1.234; - - // Check named initializers. - struct named_init ni = { - .number = 34, - .name = L"Test wide string", - .average = 543.34343, - }; - - ni.number = 58; - - int dynamic_array[ni.number]; - dynamic_array[ni.number - 1] = 543; - - // work around unused variable warnings - return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' - || dynamic_array[ni.number - 1] != 543); - ; return 0; } _ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99 -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c99=$ac_arg +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_gcc_Winit_self=yes +else + ntp_cv_gcc_Winit_self=no + fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c99" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c99" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c99" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 -$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c99" != xno; then : - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Winit_self" >&5 +$as_echo "$ntp_cv_gcc_Winit_self" >&6; } + CFLAGS="$SAVED_CFLAGS" + { SAVED_CFLAGS=; unset SAVED_CFLAGS;} + # + # $ntp_cv_gcc_Winit_self is tested later to add the + # flag to CFLAGS_NTP. + # + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports omitting unused code and data" >&5 +$as_echo_n "checking if linker supports omitting unused code and data... " >&6; } +if ${ntp_cv_gc_sections_runs+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + origCFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Wl,--gc-sections" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + #include + #include -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; int main () { -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + + FILE * fpC; + char buf[32]; + size_t cch; + int read_success_once; + + fpC = fopen("conftest.c", "r"); + if (NULL == fpC) + exit(1); + do { + cch = fread(buf, sizeof(buf), 1, fpC); + read_success_once |= (0 != cch); + } while (0 != cch); + if (!read_success_once) + exit(2); + if (!feof(fpC)) + exit(3); + if (0 != fclose(fpC)) + exit(4); + + exit(EXIT_SUCCESS); + + ; return 0; } _ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC +if ac_fn_c_try_link "$LINENO"; then : + + if test "X$cross_compiling" = "Xyes" || grep gc-sections conftest.err ; then + ntp_cv_gc_sections_runs=no + else + ntp_cv_gc_sections_runs=no + ./conftest >/dev/null 2>&1 && ntp_cv_gc_sections_runs=yes + fi -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 else - ac_cv_prog_cc_stdc=no + ntp_cv_gc_sections_runs=no + fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS="$origCFLAGS" + { origCFLAGS=; unset origCFLAGS;} + fi - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gc_sections_runs" >&5 +$as_echo "$ntp_cv_gc_sections_runs" >&6; } + case "$ntp_cv_gc_sections_runs" in + yes) + LDADD_LIBNTP="-Wl,--gc-sections" + CFLAGS_NTP="$CFLAGS_NTP -ffunction-sections -fdata-sections" + ;; + no) + LDADD_LIBNTP= + ;; + esac + CFLAGS_NTP="$CFLAGS_NTP -Wall" + CFLAGS_NTP="$CFLAGS_NTP -Wcast-align" + CFLAGS_NTP="$CFLAGS_NTP -Wcast-qual" + # CFLAGS_NTP="$CFLAGS_NTP -Wconversion" + # CFLAGS_NTP="$CFLAGS_NTP -Werror" + # CFLAGS_NTP="$CFLAGS_NTP -Wextra" + # CFLAGS_NTP="$CFLAGS_NTP -Wfloat-equal" + CFLAGS_NTP="$CFLAGS_NTP -Wmissing-prototypes" + CFLAGS_NTP="$CFLAGS_NTP -Wpointer-arith" + CFLAGS_NTP="$CFLAGS_NTP -Wshadow" + # CFLAGS_NTP="$CFLAGS_NTP -Wtraditional" + # CFLAGS_NTP="$CFLAGS_NTP -Wwrite-strings" + case "$ntp_cv_gcc_Winit_self" in + yes) + CFLAGS_NTP="$CFLAGS_NTP -Winit-self" + esac + case "$ntp_cv_gcc_Wstrict_overflow" in + yes) + CFLAGS_NTP="$CFLAGS_NTP -Wstrict-overflow" + esac + # -W[no-]strict-prototypes might be added by NTP_OPENSSL esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5 -$as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; } - if test "${ac_cv_prog_cc_stdc+set}" = set; then : - $as_echo_n "(cached) " >&6 -fi - case $ac_cv_prog_cc_stdc in #( - no) : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; #( - '') : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; #( - *) : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5 -$as_echo "$ac_cv_prog_cc_stdc" >&6; } ;; -esac -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5 +$as_echo_n "checking additional compiler flags... " >&6; } + # allow ntp_os_cflags to be preset to skip this stuff + case "${ntp_os_cflags+set}" in + set) + ;; + *) + ntp_os_cflags= + case "$host_os" in + aix[1-3]*) + ;; + aix4.[0-2]*) + # turn on additional headers + ntp_os_cflags="-D_XOPEN_EXTENDED_SOURCE" + ;; + aix5.3*) + # avoid circular dependencies in yp headers, and more + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS -D_MSGQSUPPORT" + ;; + aix*) + # XXX Only verified thru AIX6. + # aix7 seems to need a different XOPEN_SOURCE_EXTENDED thing. + # avoid circular dependencies in yp headers + # _XOPEN_SOURCE=500 = X/Open 5: POSIX 1995 + # _XOPEN_SOURCE=600 = X/Open 6: POSIX 2004 + # _XOPEN_SOURCE=700 = X/Open 7: POSIX 2008 + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_SOURCE=600" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS" + ;; + amigaos) + ntp_os_cflags="-DSYS_AMIGA" + ;; + darwin*|macosx*|rhapsody*) + ntp_os_cflags="-D_P1003_1B_VISIBLE" + ;; + hpux10.*) # at least for hppa2.0-hp-hpux10.20 + case "$GCC" in + yes) + ;; + *) + # use Ansi compiler on HPUX, and some -Wp magic + ntp_os_cflags="-Ae -Wp,-H18816" + ;; + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L" + ;; + hpux*) + case "$GCC" in + yes) + ;; + *) + # use Ansi compiler on HPUX + ntp_os_cflags="-Ae" + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L" + ;; + irix6*) + case "$CC" in + cc) + # do not use 64-bit compiler + ntp_os_cflags="-n32 -mips3 -Wl,-woff,84" + esac + ;; + nextstep3) + ntp_os_cflags="-posix" + ;; + solaris1*|solaris2.[0-5]|solaris2.5.*) + ;; + sunos[34]*|sunos5.[0-5]|sunos5.5.*) + ;; + solaris2*|sunos5*) + # turn on 64-bit file offset interface + ntp_os_cflags="-D_LARGEFILE64_SOURCE" + ;; + vxworks*) + case "$build" in + $host) + ;; + *) + # Quick and dirty sanity check + case "$VX_KERNEL" in + '') + as_fn_error $? "See html/build/hints/vxworks.html" "$LINENO" 5 + esac + ntp_os_cflags="-DSYS_VXWORKS" + esac + ;; + esac + esac + case "$ntp_os_cflags" in + '') + ntp_os_cflags_msg="none needed" + ;; + *) + ntp_os_cflags_msg="$ntp_os_cflags" + esac + CFLAGS_NTP="$CFLAGS_NTP $ntp_os_cflags" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_cflags_msg" >&5 +$as_echo "$ntp_os_cflags_msg" >&6; } + { ntp_os_cflags_msg=; unset ntp_os_cflags_msg;} + ### + { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional linker flags" >&5 +$as_echo_n "checking additional linker flags... " >&6; } + # HMS: The following might still need tweaking + # allow ntp_os_ldflags to be preset to skip this stuff + case "${ntp_os_ldflags+set}" in + set) + ;; + *) + ntp_os_ldflags= + case "$host_os" in + hpux*) + case "$GCC" in + yes) + ntp_os_ldflags="-Wl,+allowdups" + ;; + esac + ;; + esac + ;; + esac + case "$ntp_os_ldflags" in + '') + ntp_os_ldflags_msg="none needed" + ;; + *) + ntp_os_ldflags_msg="$ntp_os_ldflags" + esac + LDFLAGS_NTP="$LDFLAGS_NTP $ntp_os_ldflags" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_ldflags_msg" >&5 +$as_echo "$ntp_os_ldflags_msg" >&6; } + { ntp_os_ldflags_msg=; unset ntp_os_ldflags_msg;} + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 +$as_echo_n "checking whether byte ordering is bigendian... " >&6; } +if ${ac_cv_c_bigendian+:} false; then : $as_echo_n "(cached) " >&6 else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_cv_c_bigendian=unknown + # See if we're dealing with a universal compiler. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error +#ifndef __APPLE_CC__ + not a universal capable compiler + #endif + typedef int dummy; + _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO"; then : -else - # Broken: fails on valid input. -continue + # Check for potential -arch flags. It is not universal unless + # there are at least two -arch flags with different values. + ac_arch= + ac_prev= + for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do + if test -n "$ac_prev"; then + case $ac_word in + i?86 | x86_64 | ppc | ppc64) + if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then + ac_arch=$ac_word + else + ac_cv_c_bigendian=universal + break + fi + ;; + esac + ac_prev= + elif test "x$ac_word" = "x-arch"; then + ac_prev=arch + fi + done fi -rm -f conftest.err conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if test $ac_cv_c_bigendian = unknown; then + # See if sys/param.h defines the BYTE_ORDER macro. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +int +main () +{ +#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ + && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ + && LITTLE_ENDIAN) + bogus endian macros + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include +#include + #include + +int +main () +{ +#if BYTE_ORDER != BIG_ENDIAN + not big endian + #endif + + ; + return 0; +} _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes else - # Passes both tests. -ac_preproc_ok=: -break + ac_cv_c_bigendian=no fi -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include - done - ac_cv_prog_CPP=$CPP +int +main () +{ +#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) + bogus endian macros + #endif -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error + ; + return 0; +} _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to _BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.$ac_ext +int +main () +{ +#ifndef _BIG_ENDIAN + not big endian + #endif - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include + ; + return 0; +} _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes else - # Passes both tests. -ac_preproc_ok=: -break + ac_cv_c_bigendian=no fi -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." "$LINENO" 5; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -# HMS: These need to be moved to AM_CPPFLAGS and/or AM_CFLAGS -case "$host" in - *-*-amigaos) - CFLAGS="$CFLAGS -Dfork=vfork -DSYS_AMIGA" - ;; - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in - yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; - esac - ;; - *-pc-cygwin*) - CFLAGS="$CFLAGS -DSYS_CYGWIN32" - ;; - i386-sequent-sysv4) - case "$CC" in - cc) - CFLAGS="$CFLAGS -Wc,+abi-socket" - ;; - esac - ;; - *-*-mpeix*) - CPPFLAGS="$CPPFLAGS -DMPE -D_POSIX_SOURCE -D_SOCKET_SOURCE -I/SYSLOG/PUB" - LDFLAGS="$LDFLAGS -L/SYSLOG/PUB" - LIBS="$LIBS -lcurses" - ;; - *-*-solaris*) - # see "man standards". - # -D_XOPEN_SOURCE=500 is probably OK for c89 and before - # -D_XOPEN_SOURCE=600 seems OK for c99 - #CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=500 -D__EXTENSIONS__" - CPPFLAGS="$CPPFLAGS -D__EXTENSIONS__" - libxnet=-lxnet - ;; -esac - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5 -$as_echo_n "checking additional compiler flags... " >&6; } -if test "${ac_cv_os_cflags+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - -case "${host_os}" in - irix6* ) - case "${CC}" in - cc ) - # do not use 64-bit compiler - ac_cv_os_cflags="-n32 -mips3 -Wl,-woff,84" - ;; - esac - ;; -# HMS: am-utils needed this but we don't (apparently) -# osf[[1-3]]* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# esac -# ;; -# osf* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN" -# ;; -# esac -# ;; - aix[1-3]* ) - ac_cv_os_cflags="" ;; - aix4.[0-2]* ) - # turn on additional headers - ac_cv_os_cflags="-D_XOPEN_EXTENDED_SOURCE" - ;; - aix* ) - # avoid circular dependencies in yp headers - ac_cv_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" - ;; - OFF-sunos4* ) - # make sure passing whole structures is handled in gcc - case "${CC}" in - gcc ) - ac_cv_os_cflags="-fpcc-struct-return" - ;; - esac - ;; - sunos[34]* | solaris1* | solaris2.[0-5]* | sunos5.[0-5]* ) - ac_cv_os_cflags="" ;; - solaris* | sunos* ) - # turn on 64-bit file offset interface - case "${CC}" in - * ) - ac_cv_os_cflags="-D_LARGEFILE64_SOURCE" - ;; - esac - ;; - hpux* ) - # use Ansi compiler on HPUX - case "${CC}" in - cc ) - ac_cv_os_cflags="-Ae" - ;; - esac - ;; - darwin* | rhapsody* ) - ac_cv_os_cflags="-D_P1003_1B_VISIBLE" - ;; - * ) - ac_cv_os_cflags="" - ;; -esac - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cflags" >&5 -$as_echo "$ac_cv_os_cflags" >&6; } -CFLAGS="$CFLAGS $ac_cv_os_cflags" - - -# NTP has (so far) been relying on leading-edge autogen. -# Therefore, by default: -# - use the version we ship with -# - do not install it -# - build a static copy (AC_DISABLE_SHARED - done earlier) -case "${enable_local_libopts+set}" in - set) ;; - *) enable_local_libopts=yes ;; -esac -case "${enable_libopts_install+set}" in - set) ;; - *) enable_libopts_install=no ;; -esac - - NEED_LIBOPTS_DIR='' - - LIBOPTS_DIR=libopts - - # Check whether --enable-local-libopts was given. -if test "${enable_local_libopts+set}" = set; then : - enableval=$enable_local_libopts; - if test x$enableval = xyes ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5 -$as_echo "$as_me: Using supplied libopts tearoff" >&6;} - LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' - NEED_LIBOPTS_DIR=true +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -fi - + if test $ac_cv_c_bigendian = unknown; then + # Compile a test program. + if test "$cross_compiling" = yes; then : + # Try to guess by grepping values from an object file. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +short int ascii_mm[] = + { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; + short int ascii_ii[] = + { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; + int use_ascii (int i) { + return ascii_mm[i] + ascii_ii[i]; + } + short int ebcdic_ii[] = + { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; + short int ebcdic_mm[] = + { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; + int use_ebcdic (int i) { + return ebcdic_mm[i] + ebcdic_ii[i]; + } + extern int foo; - # Check whether --enable-libopts-install was given. -if test "${enable_libopts_install+set}" = set; then : - enableval=$enable_libopts_install; +int +main () +{ +return use_ascii (foo) == use_ebcdic (foo); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then + ac_cv_c_bigendian=yes + fi + if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then + if test "$ac_cv_c_bigendian" = unknown; then + ac_cv_c_bigendian=no + else + # finding both strings is unlikely to happen, but who knows? + ac_cv_c_bigendian=unknown + fi + fi fi - - if test "X${enable_libopts_install}" != Xno; then - INSTALL_LIBOPTS_TRUE= - INSTALL_LIBOPTS_FALSE='#' +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext else - INSTALL_LIBOPTS_TRUE='#' - INSTALL_LIBOPTS_FALSE= -fi - + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ - if test -z "${NEED_LIBOPTS_DIR}" ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5 -$as_echo_n "checking whether autoopts-config can be found... " >&6; } + /* Are we little or big endian? From Harbison&Steele. */ + union + { + long int l; + char c[sizeof (long int)]; + } u; + u.l = 1; + return u.c[sizeof (long int) - 1] == 1; -# Check whether --with-autoopts-config was given. -if test "${with_autoopts_config+set}" = set; then : - withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5 -$as_echo_n "checking whether autoopts-config is specified... " >&6; } -if test "${lo_cv_with_autoopts_config+set}" = set; then : - $as_echo_n "(cached) " >&6 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_bigendian=no else - if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=no ; fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5 -$as_echo "$lo_cv_with_autoopts_config" >&6; } - + ac_cv_c_bigendian=yes fi - # end of AC_ARG_WITH - - if test "${lo_cv_test_autoopts+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - - if test -z "${lo_cv_with_autoopts_config}" \ - -o X"${lo_cv_with_autoopts_config}" = Xno - then - if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=false ; fi - fi - lo_cv_test_autoopts=` - ${lo_cv_with_autoopts_config} --libs` 2> /dev/null - if test $? -ne 0 -o -z "${lo_cv_test_autoopts}" - then lo_cv_test_autoopts=no ; fi - +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - # end of CACHE_VAL - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5 -$as_echo "${lo_cv_test_autoopts}" >&6; } - - if test "X${lo_cv_test_autoopts}" != Xno - then - LIBOPTS_LDADD="${lo_cv_test_autoopts}" - LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`" - else - LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' - NEED_LIBOPTS_DIR=true - fi - fi # end of if test -z "${NEED_LIBOPTS_DIR}" - if test -n "${NEED_LIBOPTS_DIR}"; then - NEED_LIBOPTS_TRUE= - NEED_LIBOPTS_FALSE='#' -else - NEED_LIBOPTS_TRUE='#' - NEED_LIBOPTS_FALSE= + fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 +$as_echo "$ac_cv_c_bigendian" >&6; } + case $ac_cv_c_bigendian in #( + yes) + $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h +;; #( + no) + ;; #( + universal) +$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h + ;; #( + *) + as_fn_error $? "unknown endianness + presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; + esac - LIBOPTS_DIR=libopts - - ac_config_files="$ac_config_files libopts/Makefile" - - - - if test -n "${NEED_LIBOPTS_DIR}" ; then - - -if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 +$as_echo_n "checking for working volatile... " >&6; } +if ${ac_cv_c_volatile+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include -#include int main () { +volatile int x; +int * volatile y = (int *) 0; +return !x && !y; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes + ac_cv_c_volatile=yes else - ac_cv_header_stdc=no + ac_cv_c_volatile=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no fi -rm -f conftest* +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 +$as_echo "$ac_cv_c_volatile" >&6; } +if test $ac_cv_c_volatile = no; then + +$as_echo "#define volatile /**/" >>confdefs.h fi -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include - +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : +if ac_fn_c_try_cpp "$LINENO"; then : else - ac_cv_header_stdc=no + # Broken: fails on valid input. +continue fi -rm -f conftest* +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break fi -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#ifdef __STDC__ +# include #else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +# include #endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} + Syntax error _ACEOF -if ac_fn_c_try_run "$LINENO"; then : +if ac_fn_c_try_cpp "$LINENO"; then : else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + # Broken: fails on valid input. +continue fi +rm -f conftest.err conftest.i conftest.$ac_ext + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then +rm -f conftest.err conftest.i conftest.$ac_ext -$as_echo "#define STDC_HEADERS 1" >>confdefs.h +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } fi - # ================= - # AC_HEADER_DIRENT - # ================= - ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include <$ac_hdr> - -int -main () -{ -if ((DIR *) 0) -return 0; - ; - return 0; -} +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_ac_Header=yes" +if ac_fn_c_try_cpp "$LINENO"; then : + else - eval "$as_ac_Header=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + # Broken: fails on valid input. +continue fi -eval ac_res=\$$as_ac_Header - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 -_ACEOF +rm -f conftest.err conftest.i conftest.$ac_ext -ac_header_dirent=$ac_hdr; break + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break fi +rm -f conftest.err conftest.i conftest.$ac_ext done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : - $as_echo_n "(cached) " >&6 +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +#ifdef __STDC__ +# include +#else +# include #endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} + Syntax error _ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break fi +rm -f conftest.err conftest.i conftest.$ac_ext + done -if test "${ac_cv_search_opendir+set}" = set; then : +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : +# Do we need CXX for anything besides google test? +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +if test -z "$CXX"; then + if test -n "$CCC"; then + CXX=$CCC + else + if test -n "$ac_tool_prefix"; then + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CXX+:} false; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" + if test -n "$CXX"; then + ac_cv_prog_CXX="$CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break -fi done -if test "${ac_cv_search_opendir+set}" = set; then : + done +IFS=$as_save_IFS -else - ac_cv_search_opendir=no fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - fi - +CXX=$ac_cv_prog_CXX +if test -n "$CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 +$as_echo "$CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - # ================= - # AC_CHECK_HEADERS - # ================= - for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ - setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ - sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ - utime.h sysexits.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - + test -n "$CXX" && break + done fi - +if test -z "$CXX"; then + ac_ct_CXX=$CXX + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CXX"; then + ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CXX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done - - - # -------------------------------------------- - # Verify certain entries from AC_CHECK_HEADERS - # -------------------------------------------- - for f in sys_types sys_mman sys_param sys_stat sys_wait \ - string errno stdlib memory setjmp - do eval as_ac_var=\${ac_cv_header_${f}_h+set} - test "${as_ac_var}" = set || \ - as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 done +IFS=$as_save_IFS - # ================================================ - # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise - # if varargs.h is present define HAVE_VARARGS_H. - # ================================================ - for ac_header in stdarg.h varargs.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break fi +fi +ac_ct_CXX=$ac_cv_prog_ac_ct_CXX +if test -n "$ac_ct_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 +$as_echo "$ac_ct_CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + test -n "$ac_ct_CXX" && break done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 + if test "x$ac_ct_CXX" = x; then + CXX="g++" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CXX=$ac_ct_CXX fi - - # ================================================ - # Similarly for the string.h and strings.h headers - # ================================================ - for ac_header in string.h strings.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break fi -done - - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 fi - - # ===================== - # ...and limits headers - # ===================== - for ac_header in limits.h sys/limits.h values.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break fi - +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 +$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } +if ${ac_cv_cxx_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - # ======================== - # ...and int types headers - # ======================== - for ac_header in stdint.h inttypes.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} _ACEOF - break +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no fi - -done - - ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" -if test "x$ac_cv_type_int8_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_INT8_T 1 -_ACEOF - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_cxx_compiler_gnu=$ac_compiler_gnu fi -ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" -if test "x$ac_cv_type_uint8_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT8_T 1 -_ACEOF - - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 +$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GXX=yes +else + GXX= fi -ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" -if test "x$ac_cv_type_int16_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_INT16_T 1 -_ACEOF - +ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_save_CXXFLAGS=$CXXFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 +$as_echo_n "checking whether $CXX accepts -g... " >&6; } +if ${ac_cv_prog_cxx_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_cxx_werror_flag=$ac_cxx_werror_flag + ac_cxx_werror_flag=yes + ac_cv_prog_cxx_g=no + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" -if test "x$ac_cv_type_uint16_t" = x""yes; then : +int +main () +{ -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT16_T 1 + ; + return 0; +} _ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +else + CXXFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int +main () +{ -fi -ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" -if test "x$ac_cv_type_int32_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_INT32_T 1 + ; + return 0; +} _ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : +else + ac_cxx_werror_flag=$ac_save_cxx_werror_flag + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" -if test "x$ac_cv_type_uint32_t" = x""yes; then : +int +main () +{ -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT32_T 1 + ; + return 0; +} _ACEOF - - +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes fi -ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" -if test "x$ac_cv_type_intptr_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_INTPTR_T 1 -_ACEOF - - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" -if test "x$ac_cv_type_uint_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT_T 1 -_ACEOF - - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 +$as_echo "$ac_cv_prog_cxx_g" >&6; } +if test "$ac_test_CXXFLAGS" = set; then + CXXFLAGS=$ac_save_CXXFLAGS +elif test $ac_cv_prog_cxx_g = yes; then + if test "$GXX" = yes; then + CXXFLAGS="-g -O2" + else + CXXFLAGS="-g" + fi +else + if test "$GXX" = yes; then + CXXFLAGS="-O2" + else + CXXFLAGS= + fi +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +depcc="$CXX" am_compiler_list= - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 -_ACEOF - - +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CXX_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub -$as_echo "#define uintptr_t unsigned long" >>confdefs.h + am_cv_CXX_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac -fi + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 -$as_echo_n "checking size of char*... " >&6; } -if test "${ac_cv_sizeof_charp+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CXX_dependencies_compiler_type=$depmode + break + fi + fi + done + cd .. + rm -rf conftest.dir else - if test "$ac_cv_type_charp" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (char*) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_charp=0 - fi + am_cv_CXX_dependencies_compiler_type=none fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 -$as_echo "$ac_cv_sizeof_charp" >&6; } - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } +CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_CHARP $ac_cv_sizeof_charp -_ACEOF + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then + am__fastdepCXX_TRUE= + am__fastdepCXX_FALSE='#' +else + am__fastdepCXX_TRUE='#' + am__fastdepCXX_FALSE= +fi - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then : +for ac_prog in 'bison -y' byacc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_YACC+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : - + if test -n "$YACC"; then + ac_cv_prog_YACC="$YACC" # Let the user override the test. else - if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (int) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_int=0 - fi -fi +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_YACC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } - - +fi +YACC=$ac_cv_prog_YACC +if test -n "$YACC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5 +$as_echo "$YACC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int -_ACEOF + test -n "$YACC" && break +done +test -n "$YACC" || YACC="yacc" - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then : +if test "x$CC" != xcc; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5 +$as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5 +$as_echo_n "checking whether cc understands -c and -o together... " >&6; } +fi +set dummy $CC; ac_cc=`$as_echo "$2" | + sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` +if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + ; + return 0; +} +_ACEOF +# Make sure it works both with $CC and with simple cc. +# We do the test twice because some compilers refuse to overwrite an +# existing .o file with -o, though they will create one. +ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' +rm -f conftest2.* +if { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && + test -f conftest2.$ac_objext && { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; +then + eval ac_cv_prog_cc_${ac_cc}_c_o=yes + if test "x$CC" != xcc; then + # Test first that cc exists at all. + if { ac_try='cc -c conftest.$ac_ext >&5' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5' + rm -f conftest2.* + if { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && + test -f conftest2.$ac_objext && { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; + then + # cc works too. + : + else + # cc exists but doesn't like -o. + eval ac_cv_prog_cc_${ac_cc}_c_o=no + fi + fi + fi else - if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (long) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_long=0 - fi + eval ac_cv_prog_cc_${ac_cc}_c_o=no fi +rm -f core conftest* fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF - - - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 -$as_echo_n "checking size of short... " >&6; } -if test "${ac_cv_sizeof_short+set}" = set; then : - $as_echo_n "(cached) " >&6 +if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } -else - if test "$ac_cv_type_short" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (short) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_short=0 - fi -fi +$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 -$as_echo "$ac_cv_sizeof_short" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports C99 structure initialization" >&5 +$as_echo_n "checking whether the compiler supports C99 structure initialization... " >&6; } -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SHORT $ac_cv_sizeof_short -_ACEOF + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu - # ---------------------------------------------------------------------- - # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. - # ---------------------------------------------------------------------- - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 -$as_echo_n "checking for pathfind in -lgen... " >&6; } -if test "${ac_cv_lib_gen_pathfind+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lgen $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char pathfind (); -int -main () -{ -return pathfind (); - ; - return 0; -} + struct foo_s {int i1; int i2;}; + int main() { struct foo_s foo[] = { { .i1 = 1, .i2 = 1 }, { .i1 = 2, .i2 = 2 }, { .i1 = 0, .i2 = 0 } }; } + _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_gen_pathfind=yes +if ac_fn_c_try_compile "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } else - ac_cv_lib_gen_pathfind=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 -$as_echo "$ac_cv_lib_gen_pathfind" >&6; } -if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBGEN 1 -_ACEOF + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } - LIBS="-lgen $LIBS" +$as_echo "#define MISSING_C99_STRUCT_INIT 1" >>confdefs.h fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - for ac_func in vprintf -do : - ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" -if test "x$ac_cv_func_vprintf" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_VPRINTF 1 -_ACEOF + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" -if test "x$ac_cv_func__doprnt" = x""yes; then : -$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if we need ylwrap VPATH hack" >&5 +$as_echo_n "checking to see if we need ylwrap VPATH hack... " >&6; } +ntp_vpath_hack="no" +case "$srcdir::${force_ntp_vpath_hack-no}" in + .::*) + ;; # VPATH_HACK path is for VPATH builds only. + *::yes) + ntp_vpath_hack="yes" + ;; + *::*) + case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in + '') + ntp_vpath_hack="yes" + esac +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_vpath_hack" >&5 +$as_echo "$ntp_vpath_hack" >&6; } + if test x$ntp_vpath_hack = xyes; then + VPATH_HACK_TRUE= + VPATH_HACK_FALSE='#' +else + VPATH_HACK_TRUE='#' + VPATH_HACK_FALSE= fi -done - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF -fi -done - INVOKE_LIBOPTS_MACROS_FIRST_done=yes -fi - # Check to see if a reg expr header is specified. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for install dir and man conventions" >&5 +$as_echo_n "checking for install dir and man conventions... " >&6; } -# Check whether --with-regex-header was given. -if test "${with_regex_header+set}" = set; then : - withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header} +# Check whether --with-locfile was given. +if test "${with_locfile+set}" = set; then : + withval=$with_locfile; else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5 -$as_echo_n "checking whether a reg expr header is specified... " >&6; } -if test "${libopts_cv_with_regex_header+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_regex_header=no + with_locfile=no + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5 -$as_echo "$libopts_cv_with_regex_header" >&6; } + +( \ + SENTINEL_DIR="$PWD" && \ + cd $srcdir/sntp && \ + case "$with_locfile" in \ + yes|no|'') \ + scripts/genLocInfo -d "$SENTINEL_DIR" \ + ;; \ + *) \ + scripts/genLocInfo -d "$SENTINEL_DIR" -f "$with_locfile" \ + ;; \ + esac \ +) > genLocInfo.i 2> genLocInfo.err +. ./genLocInfo.i + +case "$GENLOCINFO" in + OK) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: in file $GENLOCINFOFILE" >&5 +$as_echo "in file $GENLOCINFOFILE" >&6; } + rm genLocInfo.err genLocInfo.i + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed." >&5 +$as_echo "failed." >&6; } + as_fn_error $? "Problem with genLocInfo!" "$LINENO" 5 + ;; +esac + + if test "$CALC_TICKADJ_MS" ; then + WANT_CALC_TICKADJ_MS_TRUE= + WANT_CALC_TICKADJ_MS_FALSE='#' +else + WANT_CALC_TICKADJ_MS_TRUE='#' + WANT_CALC_TICKADJ_MS_FALSE= fi - # end of AC_ARG_WITH - if test "X${libopts_cv_with_regex_header}" != Xno - then - cat >>confdefs.h <<_ACEOF -#define REGEX_HEADER <${libopts_cv_with_regex_header}> -_ACEOF - else -$as_echo "#define REGEX_HEADER " >>confdefs.h - fi - # Check to see if a working libregex can be found. -# Check whether --with-libregex was given. -if test "${with_libregex+set}" = set; then : - withval=$with_libregex; libopts_cv_with_libregex_root=${with_libregex} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex was specified" >&5 -$as_echo_n "checking whether with-libregex was specified... " >&6; } -if test "${libopts_cv_with_libregex_root+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_root=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_root" >&5 -$as_echo "$libopts_cv_with_libregex_root" >&6; } -fi - # end of AC_ARG_WITH libregex - if test "${with_libguile+set}" = set && \ - test "${withval}" = no - then ## disabled by request - libopts_cv_with_libregex_root=no - libopts_cv_with_libregex_cflags=no - libopts_cv_with_libregex_libs=no - else -# Check whether --with-libregex-cflags was given. -if test "${with_libregex_cflags+set}" = set; then : - withval=$with_libregex_cflags; libopts_cv_with_libregex_cflags=${with_regex_cflags} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-cflags was specified" >&5 -$as_echo_n "checking whether with-libregex-cflags was specified... " >&6; } -if test "${libopts_cv_with_libregex_cflags+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_cflags=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_cflags" >&5 -$as_echo "$libopts_cv_with_libregex_cflags" >&6; } -fi - # end of AC_ARG_WITH libregex-cflags -# Check whether --with-libregex-libs was given. -if test "${with_libregex_libs+set}" = set; then : - withval=$with_libregex_libs; libopts_cv_with_libregex_libs=${with_regex_libs} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-libs was specified" >&5 -$as_echo_n "checking whether with-libregex-libs was specified... " >&6; } -if test "${libopts_cv_with_libregex_libs+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_libs=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_libs" >&5 -$as_echo "$libopts_cv_with_libregex_libs" >&6; } -fi - # end of AC_ARG_WITH libregex-libs - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;; - * ) libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;; - esac - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;; - * ) libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex";; - esac - esac - libopts_save_CPPFLAGS="${CPPFLAGS}" - libopts_save_LIBS="${LIBS}" - fi ## disabled by request - - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_cflags="" ;; - * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;; - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_libs="" ;; - * ) - LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;; - esac - LIBREGEX_CFLAGS="" - LIBREGEX_LIBS="" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libregex functions properly" >&5 -$as_echo_n "checking whether libregex functions properly... " >&6; } - if test "${libopts_cv_with_libregex+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - libopts_cv_with_libregex=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include REGEX_HEADER -static regex_t re; -void comp_re( char const* pzPat ) { - int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE ); - if (res == 0) return; - exit( res ); } -int main() { - regmatch_t m[2]; - comp_re( "^.*\$" ); - comp_re( "()|no.*" ); - comp_re( "." ); - if (regexec( &re, "X", 2, m, 0 ) != 0) return 1; - if ((m[0].rm_so != 0) || (m[0].rm_eo != 1)) { - fputs( "error: regex -->.<-- did not match\n", stderr ); - return 1; - } - return 0; } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_with_libregex=yes -else - libopts_cv_with_libregex=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of AC_TRY_RUN - -fi - # end of AC_CACHE_VAL for libopts_cv_with_libregex - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_with_libregex}" >&5 -$as_echo "${libopts_cv_with_libregex}" >&6; } - - if test "X${libopts_cv_with_libregex}" != Xno - then - -$as_echo "#define WITH_LIBREGEX 1" >>confdefs.h - else - CPPFLAGS="${libopts_save_CPPFLAGS}" - LIBS="${libopts_save_LIBS}" - fi - # Check to see if pathfind(3) works. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pathfind(3) works" >&5 -$as_echo_n "checking whether pathfind(3) works... " >&6; } - if test "${libopts_cv_run_pathfind+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - libopts_cv_run_pathfind=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -int main (int argc, char** argv) { - char* pz = pathfind( getenv( "PATH" ), "sh", "x" ); - return (pz == 0) ? 1 : 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_pathfind=yes -else - libopts_cv_run_pathfind=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN -fi - # end of AC_CACHE_VAL for libopts_cv_run_pathfind - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_pathfind}" >&5 -$as_echo "${libopts_cv_run_pathfind}" >&6; } - if test "X${libopts_cv_run_pathfind}" != Xno - then -$as_echo "#define HAVE_PATHFIND 1" >>confdefs.h - fi - # Check to see if /dev/zero is readable device. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/zero is readable device" >&5 -$as_echo_n "checking whether /dev/zero is readable device... " >&6; } - if test "${libopts_cv_test_dev_zero+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_test_dev_zero=`exec 2> /dev/null -dzero=\`ls -lL /dev/zero | egrep ^c......r\` -test -z "${dzero}" && exit 1 -echo ${dzero}` - if test $? -ne 0 - then libopts_cv_test_dev_zero=no - elif test -z "$libopts_cv_test_dev_zero" - then libopts_cv_test_dev_zero=no - fi -fi - # end of CACHE_VAL of libopts_cv_test_dev_zero - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_test_dev_zero}" >&5 -$as_echo "${libopts_cv_test_dev_zero}" >&6; } - if test "X${libopts_cv_test_dev_zero}" != Xno - then -$as_echo "#define HAVE_DEV_ZERO 1" >>confdefs.h - fi - # Check to see if we have a functional realpath(3C). - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have a functional realpath(3C)" >&5 -$as_echo_n "checking whether we have a functional realpath(3C)... " >&6; } - if test "${libopts_cv_run_realpath+set}" = set; then : - $as_echo_n "(cached) " >&6 + if test -z "$NTPSWEEP_NI" ; then + INSTALL_NTPSWEEP_TRUE= + INSTALL_NTPSWEEP_FALSE='#' else + INSTALL_NTPSWEEP_TRUE='#' + INSTALL_NTPSWEEP_FALSE= +fi - if test "$cross_compiling" = yes; then : - libopts_cv_run_realpath=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -int main (int argc, char** argv) { -#ifndef PATH_MAX -choke me!! -#else - char zPath[PATH_MAX+1]; -#endif - char *pz = realpath(argv[0], zPath); - return (pz == zPath) ? 0 : 1; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_realpath=yes -else - libopts_cv_run_realpath=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN -fi - # end of AC_CACHE_VAL for libopts_cv_run_realpath - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_realpath}" >&5 -$as_echo "${libopts_cv_run_realpath}" >&6; } - if test "X${libopts_cv_run_realpath}" != Xno - then -$as_echo "#define HAVE_REALPATH 1" >>confdefs.h - fi - # Check to see if strftime() works. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strftime() works" >&5 -$as_echo_n "checking whether strftime() works... " >&6; } - if test "${libopts_cv_run_strftime+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - libopts_cv_run_strftime=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -char t_buf[ 64 ]; -int main() { - static char const z[] = "Thursday Aug 28 240"; - struct tm tm; - tm.tm_sec = 36; /* seconds after the minute [0, 61] */ - tm.tm_min = 44; /* minutes after the hour [0, 59] */ - tm.tm_hour = 12; /* hour since midnight [0, 23] */ - tm.tm_mday = 28; /* day of the month [1, 31] */ - tm.tm_mon = 7; /* months since January [0, 11] */ - tm.tm_year = 86; /* years since 1900 */ - tm.tm_wday = 4; /* days since Sunday [0, 6] */ - tm.tm_yday = 239; /* days since January 1 [0, 365] */ - tm.tm_isdst = 1; /* flag for daylight savings time */ - strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm ); - return (strcmp( t_buf, z ) != 0); } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_strftime=yes -else - libopts_cv_run_strftime=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN -fi - # end of AC_CACHE_VAL for libopts_cv_run_strftime - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_strftime}" >&5 -$as_echo "${libopts_cv_run_strftime}" >&6; } - if test "X${libopts_cv_run_strftime}" != Xno - then -$as_echo "#define HAVE_STRFTIME 1" >>confdefs.h - fi - # Check to see if fopen accepts "b" mode. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"b\" mode" >&5 -$as_echo_n "checking whether fopen accepts \"b\" mode... " >&6; } - if test "${libopts_cv_run_fopen_binary+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - libopts_cv_run_fopen_binary=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.$ac_ext", "rb"); -return (fp == NULL) ? 1 : fclose(fp); } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_fopen_binary=yes -else - libopts_cv_run_fopen_binary=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN -fi - # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_binary}" >&5 -$as_echo "${libopts_cv_run_fopen_binary}" >&6; } - if test "X${libopts_cv_run_fopen_binary}" != Xno - then -$as_echo "#define FOPEN_BINARY_FLAG \"b\"" >>confdefs.h - else -$as_echo "#define FOPEN_BINARY_FLAG \"\"" >>confdefs.h - fi - # Check to see if fopen accepts "t" mode. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"t\" mode" >&5 -$as_echo_n "checking whether fopen accepts \"t\" mode... " >&6; } - if test "${libopts_cv_run_fopen_text+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - libopts_cv_run_fopen_text=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.$ac_ext", "rt"); -return (fp == NULL) ? 1 : fclose(fp); } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_fopen_text=yes -else - libopts_cv_run_fopen_text=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN -fi - # end of AC_CACHE_VAL for libopts_cv_run_fopen_text - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_text}" >&5 -$as_echo "${libopts_cv_run_fopen_text}" >&6; } - if test "X${libopts_cv_run_fopen_text}" != Xno - then -$as_echo "#define FOPEN_TEXT_FLAG \"t\"" >>confdefs.h - else -$as_echo "#define FOPEN_TEXT_FLAG \"\"" >>confdefs.h - fi + if test -z "$UPDATE_LEAP_NI" ; then + INSTALL_UPDATE_LEAP_TRUE= + INSTALL_UPDATE_LEAP_FALSE='#' +else + INSTALL_UPDATE_LEAP_TRUE='#' + INSTALL_UPDATE_LEAP_FALSE= +fi - # Check to see if not wanting optional option args. - # Check whether --enable-optional-args was given. -if test "${enable_optional_args+set}" = set; then : - enableval=$enable_optional_args; libopts_cv_enable_optional_args=${enable_optional_args} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether not wanting optional option args" >&5 -$as_echo_n "checking whether not wanting optional option args... " >&6; } -if test "${libopts_cv_enable_optional_args+set}" = set; then : +if test -n "$ac_tool_prefix"; then + for ac_prog in ar lib "link -lib" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : $as_echo_n "(cached) " >&6 else - libopts_cv_enable_optional_args=yes -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_enable_optional_args" >&5 -$as_echo "$libopts_cv_enable_optional_args" >&6; } + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS fi - # end of AC_ARG_ENABLE - - if test "X${libopts_cv_enable_optional_args}" = Xno - then +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -$as_echo "#define NO_OPTIONAL_OPT_ARGS 1" >>confdefs.h + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar lib "link -lib" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi +done + done +IFS=$as_save_IFS +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + test -n "$ac_ct_AR" && break +done + if test "x$ac_ct_AR" = x; then + AR="false" else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi -if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : +: ${AR=ar} + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5 +$as_echo_n "checking the archiver ($AR) interface... " >&6; } +if ${am_cv_ar_interface+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu - ; - return 0; -} + am_cv_ar_interface=ar + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int some_variable = 0; _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no + am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 + (eval $am_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + am_cv_ar_interface=ar + else + am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 + (eval $am_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + am_cv_ar_interface=lib + else + am_cv_ar_interface=unknown + fi + fi + rm -f conftest.lib libconftest.a + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5 +$as_echo "$am_cv_ar_interface" >&6; } -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : +case $am_cv_ar_interface in +ar) + ;; +lib) + # Microsoft lib, so override with the ar-lib wrapper script. + # FIXME: It is wrong to rewrite AR. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__AR in this case, + # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something + # similar. + AR="$am_aux_dir/ar-lib $AR" + ;; +unknown) + as_fn_error $? "could not determine $AR interface" "$LINENO" 5 + ;; +esac -else - ac_cv_header_stdc=no -fi -rm -f conftest* -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : +# So far, the only shared library we might use is libopts. +# It's a small library - we might as well use a static version of it. +# Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then : + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac else - ac_cv_header_stdc=no + enable_shared=no fi -rm -f conftest* -fi -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then -$as_echo "#define STDC_HEADERS 1" >>confdefs.h -fi - # ================= - # AC_HEADER_DIRENT - # ================= - ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include <$ac_hdr> -int -main () -{ -if ((DIR *) 0) -return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_ac_Header=yes" -else - eval "$as_ac_Header=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$as_ac_Header - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 -_ACEOF +case `pwd` in + *\ * | *\ *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 +$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; +esac -ac_header_dirent=$ac_hdr; break -fi -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then : +macro_version='2.4.2' +macro_revision='1.3337' -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi -fi - # ================= - # AC_CHECK_HEADERS - # ================= - for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ - setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ - sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ - utime.h sysexits.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF -fi -done - # -------------------------------------------- - # Verify certain entries from AC_CHECK_HEADERS - # -------------------------------------------- - for f in sys_types sys_mman sys_param sys_stat sys_wait \ - string errno stdlib memory setjmp - do eval as_ac_var=\${ac_cv_header_${f}_h+set} - test "${as_ac_var}" = set || \ - as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 - done +ltmain="$ac_aux_dir/ltmain.sh" - # ================================================ - # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise - # if varargs.h is present define HAVE_VARARGS_H. - # ================================================ - for ac_header in stdarg.h varargs.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\(["`$\\]\)/\\\1/g' -done +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 - fi +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - # ================================================ - # Similarly for the string.h and strings.h headers - # ================================================ - for ac_header in string.h strings.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' -done - - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 - fi - - # ===================== - # ...and limits headers - # ===================== - for ac_header in limits.h sys/limits.h values.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi - -done - - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 - fi +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' - # ======================== - # ...and int types headers - # ======================== - for ac_header in stdint.h inttypes.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break +ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +$as_echo_n "checking how to print strings... " >&6; } +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' fi -done +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "" +} - ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" -if test "x$ac_cv_type_int8_t" = x""yes; then : +case "$ECHO" in + printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +$as_echo "printf" >&6; } ;; + print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +$as_echo "print -r" >&6; } ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +$as_echo "cat" >&6; } ;; +esac -cat >>confdefs.h <<_ACEOF -#define HAVE_INT8_T 1 -_ACEOF -fi -ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" -if test "x$ac_cv_type_uint8_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT8_T 1 -_ACEOF -fi -ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" -if test "x$ac_cv_type_int16_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_INT16_T 1 -_ACEOF -fi -ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" -if test "x$ac_cv_type_uint16_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT16_T 1 -_ACEOF -fi -ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" -if test "x$ac_cv_type_int32_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_INT32_T 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED fi -ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" -if test "x$ac_cv_type_uint32_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT32_T 1 -_ACEOF - fi -ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" -if test "x$ac_cv_type_intptr_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_INTPTR_T 1 -_ACEOF - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed -fi -ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" -if test "x$ac_cv_type_uint_t" = x""yes; then : +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT_T 1 -_ACEOF -fi - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 -_ACEOF -else -$as_echo "#define uintptr_t unsigned long" >>confdefs.h -fi - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 -$as_echo_n "checking size of char*... " >&6; } -if test "${ac_cv_sizeof_charp+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +$as_echo_n "checking for fgrep... " >&6; } +if ${ac_cv_path_FGREP+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : - -else - if test "$ac_cv_type_charp" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (char*) -See \`config.log' for more details." "$LINENO" 5; }; } + if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 + then ac_cv_path_FGREP="$GREP -F" else - ac_cv_sizeof_charp=0 - fi -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 -$as_echo "$ac_cv_sizeof_charp" >&6; } - - - -cat >>confdefs.h <<_ACEOF -#define SIZEOF_CHARP $ac_cv_sizeof_charp -_ACEOF - + if test -z "$FGREP"; then + ac_path_FGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in fgrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_FGREP" || continue +# Check for GNU ac_path_FGREP and select it if it is found. + # Check for GNU $ac_path_FGREP +case `"$ac_path_FGREP" --version 2>&1` in +*GNU*) + ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'FGREP' >> "conftest.nl" + "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_FGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_FGREP="$ac_path_FGREP" + ac_path_FGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then : - $as_echo_n "(cached) " >&6 + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + ac_cv_path_FGREP=$FGREP +fi -else - if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (int) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_int=0 fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +$as_echo "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } +test -z "$GREP" && GREP=grep -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int -_ACEOF - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : -else - if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (long) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_long=0 - fi -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 -$as_echo_n "checking size of short... " >&6; } -if test "${ac_cv_sizeof_short+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : -else - if test "$ac_cv_type_short" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (short) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_short=0 - fi -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 -$as_echo "$ac_cv_sizeof_short" >&6; } -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SHORT $ac_cv_sizeof_short -_ACEOF - # ---------------------------------------------------------------------- - # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. - # ---------------------------------------------------------------------- - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 -$as_echo_n "checking for pathfind in -lgen... " >&6; } -if test "${ac_cv_lib_gen_pathfind+set}" = set; then : - $as_echo_n "(cached) " >&6 +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lgen $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + with_gnu_ld=no +fi -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char pathfind (); -int -main () -{ -return pathfind (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_gen_pathfind=yes +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } else - ac_cv_lib_gen_pathfind=no + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 -$as_echo "$ac_cv_lib_gen_pathfind" >&6; } -if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBGEN 1 -_ACEOF - - LIBS="-lgen $LIBS" +LD="$lt_cv_path_LD" +if test -n "$LD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld - for ac_func in vprintf -do : - ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" -if test "x$ac_cv_func_vprintf" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_VPRINTF 1 -_ACEOF -ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" -if test "x$ac_cv_func__doprnt" = x""yes; then : -$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h -fi -fi -done - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 +$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } +if ${lt_cv_path_NM+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS="$lt_save_ifs" + done + : ${lt_cv_path_NM=no} +fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +$as_echo "$lt_cv_path_NM" >&6; } +if test "$lt_cv_path_NM" != "no"; then + NM="$lt_cv_path_NM" +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + if test -n "$ac_tool_prefix"; then + for ac_prog in dumpbin "link -dump" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DUMPBIN"; then + ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done +IFS=$as_save_IFS - INVOKE_LIBOPTS_MACROS_FIRST_done=yes fi - fi -# end of AC_DEFUN of LIBOPTS_CHECK +fi +DUMPBIN=$ac_cv_prog_DUMPBIN +if test -n "$DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +$as_echo "$DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5 -$as_echo_n "checking if $CC can handle #warning... " >&6; } -if test "${ac_cv_cpp_warning+set}" = set; then : + test -n "$DUMPBIN" && break + done +fi +if test -z "$DUMPBIN"; then + ac_ct_DUMPBIN=$DUMPBIN + for ac_prog in dumpbin "link -dump" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : $as_echo_n "(cached) " >&6 else + if test -n "$ac_ct_DUMPBIN"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -#warning foo - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_cpp_warning=yes +fi +fi +ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN +if test -n "$ac_ct_DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +$as_echo "$ac_ct_DUMPBIN" >&6; } else - ac_cv_cpp_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test -n "$ac_ct_DUMPBIN" && break +done + + if test "x$ac_ct_DUMPBIN" = x; then + DUMPBIN=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DUMPBIN=$ac_ct_DUMPBIN + fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cpp_warning" >&5 -$as_echo "$ac_cv_cpp_warning" >&6; } -case "$ac_cv_cpp_warning" in - no) + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi -$as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h + if test "$DUMPBIN" != ":"; then + NM="$DUMPBIN" + fi +fi +test -z "$NM" && NM=nm -esac -case "$GCC" in - yes) - SAVED_CFLAGS_AC="$CFLAGS" - CFLAGS="$CFLAGS -Wstrict-overflow" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Wstrict-overflow" >&5 -$as_echo_n "checking if $CC can handle -Wstrict-overflow... " >&6; } -if test "${ac_cv_gcc_Wstrict_overflow+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int -main () -{ - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_gcc_Wstrict_overflow=yes -else - ac_cv_gcc_Wstrict_overflow=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +$as_echo_n "checking the name lister ($NM) interface... " >&6; } +if ${lt_cv_nm_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: output\"" >&5) + cat conftest.out >&5 + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest* fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc_Wstrict_overflow" >&5 -$as_echo "$ac_cv_gcc_Wstrict_overflow" >&6; } - CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC - # - # $ac_cv_gcc_Wstrict_overflow is tested later to add the - # flag to CFLAGS. - # -esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +$as_echo "$lt_cv_nm_interface" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi -case "$GCC" in - yes) - SAVED_CFLAGS_AC="$CFLAGS" - CFLAGS="$CFLAGS -Winit-self" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Winit-self" >&5 -$as_echo_n "checking if $CC can handle -Winit-self... " >&6; } -if test "${ac_cv_gcc_Winit_self+set}" = set; then : +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if ${lt_cv_sys_max_cmd_len+:} false; then : $as_echo_n "(cached) " >&6 else + i=0 + teststring="ABCD" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; -int -main () -{ + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_gcc_Winit_self=yes -else - ac_cv_gcc_Winit_self=no + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc_Winit_self" >&5 -$as_echo "$ac_cv_gcc_Winit_self" >&6; } - CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC - # - # $ac_cv_gcc_Winit_self is tested later to add the - # flag to CFLAGS. - # -esac + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8 ; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for bin subdirectory" >&5 -$as_echo_n "checking for bin subdirectory... " >&6; } +fi -# Check whether --with-binsubdir was given. -if test "${with_binsubdir+set}" = set; then : - withval=$with_binsubdir; use_binsubdir="$withval" +if test -n $lt_cv_sys_max_cmd_len ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } else - use_binsubdir="bin" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } fi +max_cmd_len=$lt_cv_sys_max_cmd_len -case "$use_binsubdir" in - bin) - ;; - sbin) - ;; - *) - as_fn_error "<$use_binsubdir> is illegal - must be \"bin\" or \"sbin\"" "$LINENO" 5 - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_binsubdir" >&5 -$as_echo "$use_binsubdir" >&6; } -BINSUBDIR=$use_binsubdir -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use arlib" >&5 -$as_echo_n "checking if we want to use arlib... " >&6; } -# Check whether --with-arlib was given. -if test "${with_arlib+set}" = set; then : - withval=$with_arlib; ans=$withval -else - ans=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} -if test -d $srcdir/arlib -then - case "$ans" in - yes) - ARLIB_DIR=arlib +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 +$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } +# Try some XSI features +xsi_shell=no +( _lt_dummy="a/b/c" + test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ + = c,a/b,b/c, \ + && eval 'test $(( 1 + 1 )) -eq 2 \ + && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ + && xsi_shell=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 +$as_echo "$xsi_shell" >&6; } -subdirs="$subdirs arlib" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 +$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } +lt_shell_append=no +( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ + >/dev/null 2>&1 \ + && lt_shell_append=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 +$as_echo "$lt_shell_append" >&6; } - ;; - esac + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false fi -# Check whether --with-rpath was given. -if test "${with_rpath+set}" = set; then : - withval=$with_rpath; ans=$withval -else - ans=x -fi -case "$ans" in - no) - need_dash_r= - ;; - yes) - need_dash_r=1 - ;; + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; esac -# HMS: Why isn't this $build? -# Well, that depends on if we need this for the build toolchain or -# for info in the host executable... -# I still have no idea which way this should go, but nobody has complained. -case "$host" in - *-*-netbsd*) - case "$need_dash_r" in - no) ;; - *) need_dash_r=1 - ;; + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; } +if ${lt_cv_to_host_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; esac ;; - *-*-solaris*) - case "$need_dash_r" in - no) ;; - *) need_dash_r=1 - ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; esac ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; esac +fi -case "$build" in - $host) - ;; - *) case "$host" in - *-*-vxworks*) - # Quick and dirty sanity check - case "$VX_KERNEL" in - '') as_fn_error "Please follow the directions in html/build/hints/vxworks.html!" "$LINENO" 5 - ;; - esac - CFLAGS="$CFLAGS -DSYS_VXWORKS" +to_host_file_cmd=$lt_cv_to_host_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +$as_echo "$lt_cv_to_host_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } +if ${lt_cv_to_tool_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + #assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac -for ac_prog in gawk mawk nawk awk -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 +fi + +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +$as_echo "$lt_cv_to_tool_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if ${lt_cv_ld_reload_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; + darwin*) + if test "$GCC" = yes; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AWK+set}" = set; then : +if ${ac_cv_prog_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$AWK"; then - ac_cv_prog_AWK="$AWK" # Let the user override the test. + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -8481,8 +9329,8 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AWK="$ac_prog" + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -8492,506 +9340,190 @@ IFS=$as_save_IFS fi fi -AWK=$ac_cv_prog_AWK -if test -n "$AWK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -$as_echo "$AWK" >&6; } +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$AWK" && break -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } -set x ${MAKE-make} -ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else - cat >conftest.make <<\_ACEOF -SHELL = /bin/sh -all: - @echo '@@@%%%=$(MAKE)=@@@%%%' -_ACEOF -# GNU make sometimes prints "make[1]: Entering...", which would confuse us. -case `${MAKE-make} -f conftest.make 2>/dev/null` in - *@@@%%%=?*=@@@%%%*) - eval ac_cv_prog_make_${ac_make}_set=yes;; - *) - eval ac_cv_prog_make_${ac_make}_set=no;; -esac -rm -f conftest.make + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + fi -if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - SET_MAKE= +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } - SET_MAKE="MAKE=${MAKE-make}" fi - -rm -f conftest* - -case "$GCC" in - yes) - CFLAGS="$CFLAGS -Wall" - # CFLAGS="$CFLAGS -Wcast-align" - CFLAGS="$CFLAGS -Wcast-qual" - # CFLAGS="$CFLAGS -Wconversion" - # CFLAGS="$CFLAGS -Werror" - # CFLAGS="$CFLAGS -Wextra" - # CFLAGS="$CFLAGS -Wfloat-equal" - CFLAGS="$CFLAGS -Wmissing-prototypes" - CFLAGS="$CFLAGS -Wpointer-arith" - CFLAGS="$CFLAGS -Wshadow" - # - # OpenSSL has a number of callback prototypes - # inside other function prototypes which trigger - # warnings with -Wstrict-prototypes, such as: - # - # int i2d_RSA_NET(const RSA *a, unsigned char **pp, - # int (*cb)(), int sgckey); - # ^^^^^^^^^^^ - # - CFLAGS="$CFLAGS -Wno-strict-prototypes" - # CFLAGS="$CFLAGS -Wtraditional" - # CFLAGS="$CFLAGS -Wwrite-strings" - case "$ac_cv_gcc_Winit_self" in - yes) - CFLAGS="$CFLAGS -Winit-self" - esac - case "$ac_cv_gcc_Wstrict_overflow" in - yes) - #not yet: CFLAGS="$CFLAGS -Wstrict-overflow" - esac - ;; + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi -case "$host" in - *-next-nextstep3) - CFLAGS="$CFLAGS -posix" - ;; -esac +test -z "$OBJDUMP" && OBJDUMP=objdump -ac_busted_vpath_in_make=no -case "$build" in - *-*-irix6.1*) # 64 bit only - # busted vpath? - ;; - *-*-irix6*) # 6.2 (and later?) - ac_busted_vpath_in_make=yes - ;; - *-*-solaris2.5.1) - ac_busted_vpath_in_make=yes - ;; - *-*-unicosmp*) - ac_busted_vpath_in_make=yes - ;; -esac -case "$ac_busted_vpath_in_make$srcdir" in - no*) ;; - yes.) ;; - *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | sed -e 's/GNU Make version \(1-9.]*\).*/\1/' -e q`" in - '') - as_fn_error "building outside of the main directory requires GNU make" "$LINENO" 5 - ;; - *) ;; - esac - ;; -esac -# Check whether --enable-static was given. -if test "${enable_static+set}" = set; then : - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if ${lt_cv_deplibs_check_method+:} false; then : + $as_echo_n "(cached) " >&6 else - enable_static=yes -fi + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# `unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# which responds to the $file_magic_cmd with a given extended regex. +# If you have `file' or equivalent on your system and you're not sure +# whether `pass_all' will *always* work, you probably want this one. +case $host_os in +aix[4-9]*) + lt_cv_deplibs_check_method=pass_all + ;; -# Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then : - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_fast_install=yes -fi +beos*) + lt_cv_deplibs_check_method=pass_all + ;; +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if test "${lt_cv_path_SED+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - # Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. + if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done + ;; -fi +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; -SED=$lt_cv_path_SED -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 -$as_echo "$SED" >&6; } +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes -else - with_gnu_ld=no -fi +gnu*) + lt_cv_deplibs_check_method=pass_all + ;; -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac -elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } -fi -if test "${lt_cv_path_LD+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &5 -$as_echo "$LD" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if test "${lt_cv_prog_gnu_ld+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if test "${lt_cv_ld_reload_flag+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_reload_flag='-r' -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - darwin*) - if test "$GCC" = yes; then - reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD-compatible nm" >&5 -$as_echo_n "checking for BSD-compatible nm... " >&6; } -if test "${lt_cv_path_NM+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/${ac_tool_prefix}nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - esac - fi - done - IFS="$lt_save_ifs" - test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -$as_echo "$lt_cv_path_NM" >&6; } -NM="$lt_cv_path_NM" - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognise dependent libraries" >&5 -$as_echo_n "checking how to recognise dependent libraries... " >&6; } -if test "${lt_cv_deplibs_check_method+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. - -case $host_os in -aix4* | aix5*) - lt_cv_deplibs_check_method=pass_all - ;; - -beos*) - lt_cv_deplibs_check_method=pass_all - ;; - -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; - -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; - -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump'. - lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | kfreebsd*-gnu | dragonfly*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -gnu*) - lt_cv_deplibs_check_method=pass_all ;; -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac +interix[3-9]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) @@ -9005,12 +9537,12 @@ irix5* | irix6* | nonstopux*) ;; # This must be Linux ELF. -linux*) +linux* | k*bsd*-gnu | kopensolaris*-gnu) lt_cv_deplibs_check_method=pass_all ;; netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' @@ -9023,12 +9555,12 @@ newos6*) lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; -nto-qnx*) - lt_cv_deplibs_check_method=unknown +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all ;; openbsd*) - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' @@ -9039,7 +9571,7 @@ osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; -sco3.2v5*) +rdos*) lt_cv_deplibs_check_method=pass_all ;; @@ -9047,7 +9579,11 @@ solaris*) lt_cv_deplibs_check_method=pass_all ;; -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' @@ -9068,10 +9604,13 @@ sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) siemens) lt_cv_deplibs_check_method=pass_all ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; esac ;; -sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*) +tpf*) lt_cv_deplibs_check_method=pass_all ;; esac @@ -9079,6 +9618,21 @@ esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 $as_echo "$lt_cv_deplibs_check_method" >&6; } + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` + fi + ;; + esac +fi + file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown @@ -9086,569 +9640,173 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} -# Allow CC to be a program name with arguments. -compiler=$CC -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; -fi -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '#line 9126 "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; -x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if test "${lt_cv_cc_needs_belf+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int -main () -{ - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_cc_needs_belf=yes -else - lt_cv_cc_needs_belf=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -esac -need_locks="$enable_libtool_lock" -for ac_header in dlfcn.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default" -if test "x$ac_cv_header_dlfcn_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DLFCN_H 1 -_ACEOF -fi -done -# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! -# find the maximum length of command line arguments -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if test "${lt_cv_sys_max_cmd_len+set}" = set; then : +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - cygwin* | mingw*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - *) - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \ - = "XX$teststring") >/dev/null 2>&1 && - new_result=`expr "X$teststring" : ".*" 2>&1` && - lt_cv_sys_max_cmd_len=$new_result && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - teststring= - # Add a significant safety factor because C++ compilers can tack on massive - # amounts of additional arguments before passing them to the linker. - # It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - ;; - esac +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -if test -n $lt_cv_sys_max_cmd_len ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 -$as_echo "none" >&6; } + DLLTOOL="$ac_cv_prog_DLLTOOL" fi +test -z "$DLLTOOL" && DLLTOOL=dlltool -# Check for command to grab the raw symbol name followed by C symbol from nm. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } -if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then : - $as_echo_n "(cached) " >&6 -else -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' -# Transform an extracted symbol line into a proper C declaration -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" -# Define system-specific variables. + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; } +if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_sharedlib_from_linklib_cmd='unknown' + case $host_os in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw* | pw32*) - symcode='[ABCDGISTW]' - ;; -hpux*) # Its linker distinguishes data from code symbols - if test "$host_cpu" = ia64; then - symcode='[ABCDEGRST]' - fi - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - ;; -linux*) - if test "$host_cpu" = ia64; then - symcode='[ABCDGIRSTW]' - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - fi - ;; -irix* | nonstopux*) - symcode='[BCDEGRST]' - ;; -osf*) - symcode='[BCDEGQRST]' - ;; -solaris* | sysv5*) - symcode='[BDRT]' +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac ;; -sysv4) - symcode='[DFNSTU]' +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd="$ECHO" ;; esac -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; -esac -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - # Write the raw and C identifiers. - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - # Check to see that the pipe works correctly. - pipe_works=no - rm -f conftest* - cat > conftest.$ac_ext <&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Now try to grab the symbols. - nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if grep ' nm_test_var$' "$nlist" >/dev/null; then - if grep ' nm_test_func$' "$nlist" >/dev/null; then - cat < conftest.$ac_ext -#ifdef __cplusplus -extern "C" { -#endif - -EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' - - cat <> conftest.$ac_ext -#if defined (__STDC__) && __STDC__ -# define lt_ptr_t void * -#else -# define lt_ptr_t char * -# define const -#endif - -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - lt_ptr_t address; -} -lt_preloaded_symbols[] = -{ -EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext - cat <<\EOF >> conftest.$ac_ext - {0, (lt_ptr_t) 0} -}; - -#ifdef __cplusplus -} -#endif -EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - fi - rm -f conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done - -fi - -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -$as_echo "ok" >&6; } -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if test "${lt_cv_objdir+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir - - - - - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e 1s/^X//' -sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -# Constants: -rm="rm -f" - -# Global variables: -default_ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a -ltmain="$ac_aux_dir/ltmain.sh" -ofile="$default_ofile" -with_gnu_ld="$lt_cv_prog_gnu_ld" if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. -set dummy ${ac_tool_prefix}ar; ac_word=$2 + for ac_prog in ar + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AR+set}" = set; then : +if ${ac_cv_prog_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AR"; then @@ -9660,8 +9818,8 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AR="${ac_tool_prefix}ar" + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -9681,14 +9839,18 @@ $as_echo "no" >&6; } fi + test -n "$AR" && break + done fi -if test -z "$ac_cv_prog_AR"; then +if test -z "$AR"; then ac_ct_AR=$AR - # Extract the first word of "ar", so it can be a program name with args. -set dummy ar; ac_word=$2 + for ac_prog in ar +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_AR+set}" = set; then : +if ${ac_cv_prog_ac_ct_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_AR"; then @@ -9700,8 +9862,8 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_AR="ar" + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -9720,6 +9882,10 @@ else $as_echo "no" >&6; } fi + + test -n "$ac_ct_AR" && break +done + if test "x$ac_ct_AR" = x; then AR="false" else @@ -9731,108 +9897,85 @@ ac_tool_warned=yes ;; esac AR=$ac_ct_AR fi -else - AR="$ac_cv_prog_AR" fi -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS +: ${AR=ar} +: ${AR_FLAGS=cru} -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +$as_echo_n "checking for archiver @FILE support... " >&6; } +if ${lt_cv_ar_at_file+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + lt_cv_ar_at_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +$as_echo "$lt_cv_ar_at_file" >&6; } - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= else - RANLIB="$ac_cv_prog_RANLIB" + archiver_list_spec=$lt_cv_ar_at_file fi + + + + + + if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then : +if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then @@ -9844,7 +9987,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -9872,7 +10015,7 @@ if test -z "$ac_cv_prog_STRIP"; then set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then @@ -9884,7 +10027,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -9919,761 +10062,5622 @@ else STRIP="$ac_cv_prog_STRIP" fi +test -z "$STRIP" && STRIP=: -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru -test -z "$AS" && AS=as -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$LD" && LD=ld -test -z "$LN_S" && LN_S="ln -s" -test -z "$MAGIC_CMD" && MAGIC_CMD=file -test -z "$NM" && NM=nm -test -z "$SED" && SED=sed -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$RANLIB" && RANLIB=: -test -z "$STRIP" && STRIP=: -test -z "$ac_objext" && ac_objext=o -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" - ;; - *) - old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" -fi -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -# Only perform the check for file, if the check method requires it -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/${ac_tool_prefix}file; then - lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -EOF - fi ;; - esac - fi - break - fi + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi +IFS=$as_save_IFS -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } +fi +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : + +fi +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/file; then - lt_cv_path_MAGIC_CMD="$ac_dir/file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -EOF - fi ;; - esac - fi - break - fi + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi +IFS=$as_save_IFS -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } +fi +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" else - MAGIC_CMD=: + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB fi +else + RANLIB="$ac_cv_prog_RANLIB" fi - fi - ;; -esac +test -z "$RANLIB" && RANLIB=: -enable_dlopen=no -enable_win32_dll=no -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; -fi -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then : - withval=$with_pic; pic_mode="$withval" -else - pic_mode=default + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi -test -z "$pic_mode" && pic_mode=default +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac -# Use C for the default configuration in the libtool script -tagname= -lt_save_CC="$CC" -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -# Source file extension for C test sources. -ac_ext=c -# Object file extension for compiled C test sources. -objext=o -objext=$objext -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}\n' -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} -# Allow CC to be a program name with arguments. -compiler=$CC -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* -# -# Check for any special shared library compilation flags. -# -lt_prog_cc_shlib= -if test "$GCC" = no; then - case $host_os in - sco3.2v5*) - lt_prog_cc_shlib='-belf' - ;; - esac -fi -if test -n "$lt_prog_cc_shlib"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5 -$as_echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;} - if echo "$old_CC $old_CFLAGS " | grep "[ ]$lt_prog_cc_shlib[ ]" >/dev/null; then : - else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5 -$as_echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;} - lt_cv_prog_cc_can_build_shared=no - fi -fi -# -# Check to make sure the static flag actually works. -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_prog_compiler_static works" >&5 -$as_echo_n "checking if $compiler static flag $lt_prog_compiler_static works... " >&6; } -if test "${lt_prog_compiler_static_works+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_prog_compiler_static_works=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_prog_compiler_static" - printf "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_static_works=yes - fi - else - lt_prog_compiler_static_works=yes - fi - fi - $rm conftest* - LDFLAGS="$save_LDFLAGS" -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_static_works" >&5 -$as_echo "$lt_prog_compiler_static_works" >&6; } -if test x"$lt_prog_compiler_static_works" = xyes; then - : -else - lt_prog_compiler_static= -fi -lt_prog_compiler_no_builtin_flag= -if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag=' -fno-builtin' -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:10261: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:10265: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $rm conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" -else - : -fi -fi -lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } - if test "$GCC" = yes; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - ;; - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - ;; - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no - ;; - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - ;; +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - lt_prog_compiler_pic='-qnocommon' - lt_prog_compiler_wl='-Wl,' - ;; - esac - ;; +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; +# Allow CC to be a program name with arguments. +compiler=$CC - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='${wl}-a ${wl}archive' - ;; - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' - ;; +# Check for command to grab the raw symbol name followed by C symbol from nm. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } +if ${lt_cv_sys_global_symbol_pipe+:} false; then : + $as_echo_n "(cached) " >&6 +else - newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] - linux*) - case $cc_basename in - icc* | ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - esac - ;; +# Character class describing NM global symbol codes. +symcode='[BCDEGRST]' - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' - ;; +# Regexp to match symbols that can be accessed directly from C. +sympat='\([_A-Za-z][_A-Za-z0-9]*\)' - sco3.2v5*) - lt_prog_compiler_pic='-Kpic' - lt_prog_compiler_static='-dn' - ;; +# Define system-specific variables. +case $host_os in +aix*) + symcode='[BCDT]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[ABCDGISTW]' + ;; +hpux*) + if test "$host_cpu" = ia64; then + symcode='[ABCDEGRST]' + fi + ;; +irix* | nonstopux*) + symcode='[BCDEGRST]' + ;; +osf*) + symcode='[BCDEGQRST]' + ;; +solaris*) + symcode='[BDRT]' + ;; +sco3.2v5*) + symcode='[DT]' + ;; +sysv4.2uw2*) + symcode='[DT]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[ABDT]' + ;; +sysv4) + symcode='[DFNSTU]' + ;; +esac - solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - lt_prog_compiler_wl='-Qoption ld ';; - *) - lt_prog_compiler_wl='-Wl,';; - esac - ;; +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac - sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' - fi - ;; +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no - ;; +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do - uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' - ;; + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" - *) - lt_prog_compiler_can_build_shared=no - ;; - esac + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function + # and D for any global variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK '"\ +" {last_section=section; section=\$ 3};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ +" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ +" s[1]~/^[@?]/{print s[1], s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5 -$as_echo "$lt_prog_compiler_pic" >&6; } + # Check to see that the pipe works correctly. + pipe_works=no -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic"; then + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if test "${lt_prog_compiler_pic_works+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:10523: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:10527: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_pic_works=yes - fi - fi - $rm conftest* + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Now try to grab the symbols. + nlist=conftest.nm + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 + (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&5 + fi + else + echo "cannot find nm_test_var in $nlist" >&5 + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "$progname: failed program was:" >&5 + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works" >&5 -$as_echo "$lt_prog_compiler_pic_works" >&6; } -if test x"$lt_prog_compiler_pic_works" = xyes; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +$as_echo "failed" >&6; } else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; } fi +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then + nm_file_list_spec='@' fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o+set}" = set; then : - $as_echo_n "(cached) " >&6 + + + + + + + + + + + + + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +$as_echo_n "checking for sysroot... " >&6; } + +# Check whether --with-sysroot was given. +if test "${with_sysroot+set}" = set; then : + withval=$with_sysroot; else - lt_cv_prog_compiler_c_o=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext + with_sysroot=no +fi - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:10585: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:10589: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi + +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi - chmod u+w . 2>&5 - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 +$as_echo "${with_sysroot}" >&6; } + as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 + ;; +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +$as_echo "${lt_sysroot:-no}" >&6; } -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no + + + +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - runpath_var= - allow_undefined_flag= - enable_shared_with_static_runtimes=no +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out which ABI we are using. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_i386" + ;; + ppc64-*linux*|powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + ppc*-*linux*|powerpc*-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if ${lt_cv_cc_needs_belf+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_cc_needs_belf=yes +else + lt_cv_cc_needs_belf=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +sparc*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) LD="${LD-ld} -m elf64_sparc" ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks="$enable_libtool_lock" + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. +set dummy ${ac_tool_prefix}mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$MANIFEST_TOOL"; then + ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL +if test -n "$MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +$as_echo "$MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_MANIFEST_TOOL"; then + ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_MANIFEST_TOOL"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL +if test -n "$ac_ct_MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_MANIFEST_TOOL" = x; then + MANIFEST_TOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL + fi +else + MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" +fi + +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if ${lt_cv_path_mainfest_tool+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&5 + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 +$as_echo "$lt_cv_path_mainfest_tool" >&6; } +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi + + + + + + + case $host_os in + rhapsody* | darwin*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. +set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DSYMUTIL"; then + ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DSYMUTIL"; then + ac_ct_DSYMUTIL=$DSYMUTIL + # Extract the first word of "dsymutil", so it can be a program name with args. +set dummy dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DSYMUTIL"; then + ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL +if test -n "$ac_ct_DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DSYMUTIL" = x; then + DSYMUTIL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DSYMUTIL=$ac_ct_DSYMUTIL + fi +else + DSYMUTIL="$ac_cv_prog_DSYMUTIL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. +set dummy ${ac_tool_prefix}nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NMEDIT"; then + ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +NMEDIT=$ac_cv_prog_NMEDIT +if test -n "$NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_NMEDIT"; then + ac_ct_NMEDIT=$NMEDIT + # Extract the first word of "nmedit", so it can be a program name with args. +set dummy nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_NMEDIT"; then + ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_NMEDIT="nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT +if test -n "$ac_ct_NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 +$as_echo "$ac_ct_NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_NMEDIT" = x; then + NMEDIT=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + NMEDIT=$ac_ct_NMEDIT + fi +else + NMEDIT="$ac_cv_prog_NMEDIT" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. +set dummy ${ac_tool_prefix}lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$LIPO"; then + ac_cv_prog_LIPO="$LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_LIPO="${ac_tool_prefix}lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +LIPO=$ac_cv_prog_LIPO +if test -n "$LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 +$as_echo "$LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_LIPO"; then + ac_ct_LIPO=$LIPO + # Extract the first word of "lipo", so it can be a program name with args. +set dummy lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_LIPO"; then + ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_LIPO="lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO +if test -n "$ac_ct_LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 +$as_echo "$ac_ct_LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_LIPO" = x; then + LIPO=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + LIPO=$ac_ct_LIPO + fi +else + LIPO="$ac_cv_prog_LIPO" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL"; then + ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL="${ac_tool_prefix}otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL=$ac_cv_prog_OTOOL +if test -n "$OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 +$as_echo "$OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL"; then + ac_ct_OTOOL=$OTOOL + # Extract the first word of "otool", so it can be a program name with args. +set dummy otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL"; then + ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL="otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL +if test -n "$ac_ct_OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 +$as_echo "$ac_ct_OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL" = x; then + OTOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL=$ac_ct_OTOOL + fi +else + OTOOL="$ac_cv_prog_OTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL64"; then + ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL64=$ac_cv_prog_OTOOL64 +if test -n "$OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 +$as_echo "$OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL64"; then + ac_ct_OTOOL64=$OTOOL64 + # Extract the first word of "otool64", so it can be a program name with args. +set dummy otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL64"; then + ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL64="otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 +if test -n "$ac_ct_OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 +$as_echo "$ac_ct_OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL64" = x; then + OTOOL64=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL64=$ac_ct_OTOOL64 + fi +else + OTOOL64="$ac_cv_prog_OTOOL64" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 +$as_echo_n "checking for -single_module linker flag... " >&6; } +if ${lt_cv_apple_cc_single_mod+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_apple_cc_single_mod=no + if test -z "${LT_MULTI_MODULE}"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&5 + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 +$as_echo "$lt_cv_apple_cc_single_mod" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 +$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } +if ${lt_cv_ld_exported_symbols_list+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_ld_exported_symbols_list=yes +else + lt_cv_ld_exported_symbols_list=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 +$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +$as_echo_n "checking for -force_load linker flag... " >&6; } +if ${lt_cv_ld_force_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 + echo "$AR cru libconftest.a conftest.o" >&5 + $AR cru libconftest.a conftest.o 2>&5 + echo "$RANLIB libconftest.a" >&5 + $RANLIB libconftest.a 2>&5 + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&5 + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +$as_echo "$lt_cv_ld_force_load" >&6; } + case $host_os in + rhapsody* | darwin1.[012]) + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[91]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[012]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test "$lt_cv_apple_cc_single_mod" = "yes"; then + _lt_dar_single_mod='$single_module' + fi + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + fi + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac + +for ac_header in dlfcn.h +do : + ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +" +if test "x$ac_cv_header_dlfcn_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DLFCN_H 1 +_ACEOF + +fi + +done + + + + +func_stripname_cnf () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname_cnf + + + + + +# Set options + + + + enable_dlopen=no + + + enable_win32_dll=no + + + + # Check whether --enable-static was given. +if test "${enable_static+set}" = set; then : + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_static=yes +fi + + + + + + + + + + +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then : + withval=$with_pic; pic_mode="$withval" +else + pic_mode=default +fi + + +test -z "$pic_mode" && pic_mode=default + + + + + + + + # Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then : + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_fast_install=yes +fi + + + + + + + + + + + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ltmain" + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' + + + + + + + + + + + + + + + + + + + + + + + + + + +test -z "$LN_S" && LN_S="ln -s" + + + + + + + + + + + + + + +if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if ${lt_cv_objdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir + + + + + +cat >>confdefs.h <<_ACEOF +#define LT_OBJDIR "$lt_cv_objdir/" +_ACEOF + + + + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld="$lt_cv_prog_gnu_ld" + +old_CC="$CC" +old_CFLAGS="$CFLAGS" + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` + + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/${ac_tool_prefix}file; then + lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + + +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/file; then + lt_cv_path_MAGIC_CMD="$ac_dir/file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + else + MAGIC_CMD=: + fi +fi + + fi + ;; +esac + +# Use C for the default configuration in the libtool script + +lt_save_CC="$CC" +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +objext=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + +lt_prog_compiler_no_builtin_flag= + +if test "$GCC" = yes; then + case $cc_basename in + nvcc*) + lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; + *) + lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" +else + : +fi + +fi + + + + + + + lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= + + + if test "$GCC" = yes; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + lt_prog_compiler_pic='-Xcompiler -fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='${wl}-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + # old Intel for x86_64 which still supported -KPIC. + ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='--shared' + lt_prog_compiler_static='--static' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-qpic' + lt_prog_compiler_static='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ F* | *Sun*Fortran*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + esac + ;; + esac + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi + +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +$as_echo "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if ${lt_cv_prog_compiler_pic_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } + +if test x"$lt_cv_prog_compiler_pic_works" = xyes; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi + +fi + + + + + + + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +$as_echo "$lt_cv_prog_compiler_static_works" >&6; } + +if test x"$lt_cv_prog_compiler_static_works" = xyes; then + : +else + lt_prog_compiler_static= +fi + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + runpath_var= + allow_undefined_flag= + always_export_symbols=no archive_cmds= archive_expsym_cmds= - old_archive_From_new_cmds= - old_archive_from_expsyms_cmds= + compiler_needs_object=no + enable_shared_with_static_runtimes=no export_dynamic_flag_spec= - whole_archive_flag_spec= - thread_safe_flag_spec= + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + hardcode_automatic=no + hardcode_direct=no + hardcode_direct_absolute=no hardcode_libdir_flag_spec= hardcode_libdir_flag_spec_ld= hardcode_libdir_separator= + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + inherit_rpath=no + link_all_deplibs=unknown + module_cmds= + module_expsym_cmds= + old_archive_from_new_cmds= + old_archive_from_expsyms_cmds= + thread_safe_flag_spec= + whole_archive_flag_spec= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac + + ld_shlibs=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; + *\ \(GNU\ Binutils\)\ [3-9]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + export_dynamic_flag_spec='${wl}--export-all-symbols' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs=no + fi + ;; + + haiku*) + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs=yes + ;; + + interix[3-9]*) + hardcode_direct=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test "$host_os" = linux-dietlibc; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test "$tmp_diet" = no + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + whole_archive_flag_spec= + tmp_sharedflag='--shared' ;; + xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' + hardcode_libdir_flag_spec= + hardcode_libdir_flag_spec_ld='-rpath $libdir' + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + ld_shlibs=no + fi + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + ;; + + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + + if test "$ld_shlibs" = no; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; + + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds='' + hardcode_direct=yes + hardcode_direct_absolute=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + file_list_spec='${wl}-f,' + + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + export_dynamic_flag_spec='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' ${wl}-bernotok' + allow_undefined_flag=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + fi + archive_cmds_need_lc=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + always_export_symbols=yes + file_list_spec='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, )='true' + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + old_postinstall_cmds='chmod 644 $oldlib' + postlink_cmds='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_from_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' + enable_shared_with_static_runtimes=yes + ;; + esac + ;; + + darwin* | rhapsody*) + + + archive_cmds_need_lc=no hardcode_direct=no - hardcode_minus_L=no + hardcode_automatic=yes hardcode_shlibpath_var=unsupported - link_all_deplibs=unknown - hardcode_automatic=no - module_cmds= - module_expsym_cmds= - always_export_symbols=no - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + whole_archive_flag_spec='' + fi + link_all_deplibs=yes + allow_undefined_flag="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + + else + ld_shlibs=no + fi + + ;; + + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + freebsd1*) + ld_shlibs=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + hpux9*) + if test "$GCC" = yes; then + archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='${wl}-E' + ;; + + hpux10*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_flag_spec_ld='+b $libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + fi + ;; + + hpux11*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +$as_echo_n "checking if $CC understands -b... " >&6; } +if ${lt_cv_prog_compiler__b+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler__b=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -b" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler__b=yes + fi + else + lt_cv_prog_compiler__b=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +$as_echo "$lt_cv_prog_compiler__b" >&6; } + +if test x"$lt_cv_prog_compiler__b" = xyes; then + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' +else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' +fi + + ;; + esac + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + *) + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if ${lt_cv_irix_exported_symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int foo (void) { return 0; } +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_irix_exported_symbol=yes +else + lt_cv_irix_exported_symbol=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +$as_echo "$lt_cv_irix_exported_symbol" >&6; } + if test "$lt_cv_irix_exported_symbol" = yes; then + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi + else + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + inherit_rpath=yes + link_all_deplibs=yes + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + newsos6) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + *nto* | *qnx*) + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct=yes + hardcode_shlibpath_var=no + hardcode_direct_absolute=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-R$libdir' + ;; + *) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + ;; + esac + fi + else + ld_shlibs=no + fi + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + archive_cmds_need_lc='no' + hardcode_libdir_separator=: + ;; + + solaris*) + no_undefined_flag=' -z defs' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='${wl}' + archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs=yes + ;; + + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag='${wl}-z,text' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag='${wl}-z,text' + allow_undefined_flag='${wl}-z,nodefs' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-R,$libdir' + hardcode_libdir_separator=':' + link_all_deplibs=yes + export_dynamic_flag_spec='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + *) + ld_shlibs=no + ;; + esac + + if test x$host_vendor = xsni; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + export_dynamic_flag_spec='${wl}-Blargedynsym' + ;; + esac + fi + fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test "$ld_shlibs" = no && can_build_shared=no + +with_gnu_ld=$with_gnu_ld + + + + + + + + + + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + pic_flag=$lt_prog_compiler_pic + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc=no + else + lt_cv_archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } + archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[lt_foo]++; } + if (lt_freq[lt_foo] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([A-Za-z]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd1*) + dynamic_linker=no + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; + +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || + test -n "$runpath_var" || + test "X$hardcode_automatic" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$hardcode_direct" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && + test "$hardcode_minus_L" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test "$hardcode_action" = relink || + test "$inherit_rpath" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if ${ac_cv_lib_dld_shl_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if ${ac_cv_lib_svld_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if ${ac_cv_lib_dld_dld_link+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = xyes; then : + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" +fi + + +fi + + +fi + + +fi + + +fi + + +fi + + ;; + esac + + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } + + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self_static+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi + + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi + + + + + + + + + + + + + + + + + +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + + + + + + + + + + + + + # Report which library types will actually be built + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[4-9]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } + + + + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +CC="$lt_save_CC" + + if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 +$as_echo_n "checking how to run the C++ preprocessor... " >&6; } +if test -z "$CXXCPP"; then + if ${ac_cv_prog_CXXCPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CXXCPP needs to be expanded + for CXXCPP in "$CXX -E" "/lib/cpp" + do + ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CXXCPP=$CXXCPP + +fi + CXXCPP=$ac_cv_prog_CXXCPP +else + ac_cv_prog_CXXCPP=$CXXCPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 +$as_echo "$CXXCPP" >&6; } +ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +else + _lt_caught_CXX_error=yes +fi + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +archive_cmds_need_lc_CXX=no +allow_undefined_flag_CXX= +always_export_symbols_CXX=no +archive_expsym_cmds_CXX= +compiler_needs_object_CXX=no +export_dynamic_flag_spec_CXX= +hardcode_direct_CXX=no +hardcode_direct_absolute_CXX=no +hardcode_libdir_flag_spec_CXX= +hardcode_libdir_flag_spec_ld_CXX= +hardcode_libdir_separator_CXX= +hardcode_minus_L_CXX=no +hardcode_shlibpath_var_CXX=unsupported +hardcode_automatic_CXX=no +inherit_rpath_CXX=no +module_cmds_CXX= +module_expsym_cmds_CXX= +link_all_deplibs_CXX=unknown +old_archive_cmds_CXX=$old_archive_cmds +reload_flag_CXX=$reload_flag +reload_cmds_CXX=$reload_cmds +no_undefined_flag_CXX= +whole_archive_flag_spec_CXX= +enable_shared_with_static_runtimes_CXX=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +objext_CXX=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_caught_CXX_error" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + + # save warnings/boilerplate of simple test code + ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + + ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + compiler_CXX=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; @@ -10682,4694 +15686,11327 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie *) break;; esac done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` + + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test "$GXX" = yes; then + lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' + else + lt_prog_compiler_no_builtin_flag_CXX= + fi + + if test "$GXX" = yes; then + # Set up default GNU C++ configuration + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test "$with_gnu_ld" = yes; then + archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='${wl}' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec_CXX= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + ld_shlibs_CXX=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds_CXX='' + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + file_list_spec_CXX='${wl}-f,' + + if test "$GXX" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_CXX=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_CXX=yes + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_libdir_separator_CXX= + fi + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + export_dynamic_flag_spec_CXX='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + always_export_symbols_CXX=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag_CXX='-berok' + # Determine the default libpath from the value encoded in an empty + # executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" + + archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag_CXX="-z nodefs" + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_CXX=' ${wl}-bernotok' + allow_undefined_flag_CXX=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_CXX='$convenience' + fi + archive_cmds_need_lc_CXX=yes + # This is similar to how AIX traditionally builds its shared + # libraries. + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_CXX=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs_CXX=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_CXX=' ' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=yes + file_list_spec_CXX='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' + enable_shared_with_static_runtimes_CXX=yes + # Don't use ranlib + old_postinstall_cmds_CXX='chmod 644 $oldlib' + postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_CXX='-L$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-all-symbols' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=no + enable_shared_with_static_runtimes_CXX=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_CXX=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + + + archive_cmds_need_lc_CXX=no + hardcode_direct_CXX=no + hardcode_automatic_CXX=yes + hardcode_shlibpath_var_CXX=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + whole_archive_flag_spec_CXX='' + fi + link_all_deplibs_CXX=yes + allow_undefined_flag_CXX="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + if test "$lt_cv_apple_cc_single_mod" != "yes"; then + archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" + fi + + else + ld_shlibs_CXX=no + fi + + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + freebsd[12]*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + ld_shlibs_CXX=no + ;; + + freebsd-elf*) + archive_cmds_need_lc_CXX=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + ld_shlibs_CXX=yes + ;; + + gnu*) + ;; + + haiku*) + archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs_CXX=yes + ;; + + hpux9*) + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: + export_dynamic_flag_spec_CXX='${wl}-E' + hardcode_direct_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test $with_gnu_ld = no; then + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + export_dynamic_flag_spec_CXX='${wl}-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + ;; + *) + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + if test $with_gnu_ld = no; then + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + interix[3-9]*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test "$GXX" = yes; then + if test "$with_gnu_ld" = no; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' + fi + fi + link_all_deplibs_CXX=yes + ;; + esac + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + inherit_rpath_CXX=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + archive_cmds_need_lc_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [1-5].* | *pgcpp\ [1-5].*) + prelink_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + old_archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + archive_expsym_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + ;; + cxx*) + # Compaq C++ + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + hardcode_libdir_flag_spec_CXX='-R$libdir' + whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object_CXX=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + ld_shlibs_CXX=yes + ;; + + openbsd2*) + # C++ shared libraries are fairly broken + ld_shlibs_CXX=no + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + hardcode_direct_absolute_CXX=yes + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' + export_dynamic_flag_spec_CXX='${wl}-E' + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + ld_shlibs_CXX=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + hardcode_libdir_separator_CXX=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + cxx*) + case $host in + osf3*) + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + ;; + *) + allow_undefined_flag_CXX=' -expect_unresolved \*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ + $RM $lib.exp' + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + ;; + esac + + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + case $host in + osf3*) + archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + *) + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + archive_cmds_need_lc_CXX=yes + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_shlibpath_var_CXX=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' + ;; + esac + link_all_deplibs_CXX=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + no_undefined_flag_CXX=' ${wl}-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require `-G' NOT `-shared' on this + # platform. + archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_CXX='${wl}-z,text' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag_CXX='${wl}-z,text' + allow_undefined_flag_CXX='${wl}-z,nodefs' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir' + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + export_dynamic_flag_spec_CXX='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ + '"$old_archive_cmds_CXX" + reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ + '"$reload_cmds_CXX" + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } + test "$ld_shlibs_CXX" = no && can_build_shared=no + + GCC_CXX="$GXX" + LD_CXX="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + # Dependencies to place before and after the object being linked: +predep_objects_CXX= +postdep_objects_CXX= +predeps_CXX= +postdeps_CXX= +compiler_lib_search_path_CXX= + +cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF + + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +esac + +if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case ${prev}${p} in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test $p = "-L" || + test $p = "-R"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test "$pre_test_object_deps_done" = no; then + case ${prev} in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$compiler_lib_search_path_CXX"; then + compiler_lib_search_path_CXX="${prev}${p}" + else + compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$postdeps_CXX"; then + postdeps_CXX="${prev}${p}" + else + postdeps_CXX="${postdeps_CXX} ${prev}${p}" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test "$pre_test_object_deps_done" = no; then + if test -z "$predep_objects_CXX"; then + predep_objects_CXX="$p" + else + predep_objects_CXX="$predep_objects_CXX $p" + fi + else + if test -z "$postdep_objects_CXX"; then + postdep_objects_CXX="$p" + else + postdep_objects_CXX="$postdep_objects_CXX $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling CXX test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +case $host_os in +interix[3-9]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + predep_objects_CXX= + postdep_objects_CXX= + postdeps_CXX= + ;; + +linux*) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; + +solaris*) + case $cc_basename in + CC* | sunCC*) + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + # Adding this requires a known-good setup of shared libraries for + # Sun compiler versions before 5.6, else PIC objects from an old + # archive will be linked into the output, leading to subtle bugs. + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; +esac + + +case " $postdeps_CXX " in +*" -lc "*) archive_cmds_need_lc_CXX=no ;; +esac + compiler_lib_search_dirs_CXX= +if test -n "${compiler_lib_search_path_CXX}"; then + compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + lt_prog_compiler_wl_CXX= +lt_prog_compiler_pic_CXX= +lt_prog_compiler_static_CXX= + + + # C++ specific cases for pic, static, wl, etc. + if test "$GXX" = yes; then + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic_CXX='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_CXX='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + lt_prog_compiler_pic_CXX= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static_CXX= + ;; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_CXX=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + else + case $host_os in + aix[4-9]*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + else + lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + dgux*) + case $cc_basename in + ec++*) + lt_prog_compiler_pic_CXX='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + if test "$host_cpu" != ia64; then + lt_prog_compiler_pic_CXX='+Z' + fi + ;; + aCC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_CXX='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + KCC*) + # KAI C++ Compiler + lt_prog_compiler_wl_CXX='--backend -Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64 which still supported -KPIC. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + lt_prog_compiler_static_CXX='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fpic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-qpic' + lt_prog_compiler_static_CXX='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + lt_prog_compiler_pic_CXX='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd*) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + lt_prog_compiler_wl_CXX='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + lt_prog_compiler_pic_CXX='-pic' + ;; + cxx*) + # Digital/Compaq C++ + lt_prog_compiler_wl_CXX='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + lt_prog_compiler_pic_CXX='-pic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + lcc*) + # Lucid + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + lt_prog_compiler_pic_CXX='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + lt_prog_compiler_can_build_shared_CXX=no + ;; + esac + fi + +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_CXX= + ;; + *) + lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } +lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } +if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works_CXX=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_CXX=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } + +if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then + case $lt_prog_compiler_pic_CXX in + "" | " "*) ;; + *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; + esac +else + lt_prog_compiler_pic_CXX= + lt_prog_compiler_can_build_shared_CXX=no +fi + +fi + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works_CXX=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_CXX=yes + fi + else + lt_cv_prog_compiler_static_works_CXX=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } + +if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then + : +else + lt_prog_compiler_static_CXX= +fi + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + case $host_os in + aix[4-9]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global defined + # symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + export_symbols_cmds_CXX="$ltdll_cmds" + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + ;; + esac + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } +test "$ld_shlibs_CXX" = no && can_build_shared=no + +with_gnu_ld_CXX=$with_gnu_ld + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_CXX" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_CXX=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds_CXX in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_CXX + pic_flag=$lt_prog_compiler_pic_CXX + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_CXX + allow_undefined_flag_CXX= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc_CXX=no + else + lt_cv_archive_cmds_need_lc_CXX=yes + fi + allow_undefined_flag_CXX=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } + archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd1*) + dynamic_linker=no + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; + +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_CXX= +if test -n "$hardcode_libdir_flag_spec_CXX" || + test -n "$runpath_var_CXX" || + test "X$hardcode_automatic_CXX" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$hardcode_direct_CXX" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no && + test "$hardcode_minus_L_CXX" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action_CXX=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_CXX=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_CXX=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 +$as_echo "$hardcode_action_CXX" >&6; } + +if test "$hardcode_action_CXX" = relink || + test "$inherit_rpath_CXX" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test "$_lt_caught_CXX_error" != yes + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + + + + + + + + + ac_config_commands="$ac_config_commands libtool" + + + + +# Only expand once: + + + + +# NTP has (so far) been relying on leading-edge autogen, which +# means we need the appropriate corresponding libopts as well. +# Therefore, by default: +# - use the version of libopts we ship with +# - do not install it +# - build a static copy (AC_DISABLE_SHARED - done earlier) +case "${enable_local_libopts+set}" in + set) ;; + *) enable_local_libopts=yes ;; +esac +case "${enable_libopts_install+set}" in + set) ;; + *) enable_libopts_install=no ;; +esac +enable_nls=no +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define pid_t int +_ACEOF + +fi + + + + ac_header_dirent=no +for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do + as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 +$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } +if eval \${$as_ac_Header+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include <$ac_hdr> + +int +main () +{ +if ((DIR *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_ac_Header=yes" +else + eval "$as_ac_Header=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$as_ac_Header + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 +_ACEOF + +ac_header_dirent=$ac_hdr; break +fi + +done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' dir; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break +fi +done +if ${ac_cv_search_opendir+:} false; then : + +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' x; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break +fi +done +if ${ac_cv_search_opendir+:} false; then : + +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +fi + + + # ================= + # AC_CHECK_HEADERS + # ================= + for ac_header in \ + sys/mman.h sys/param.h sys/poll.h sys/procset.h \ + sys/select.h sys/socket.h sys/stropts.h sys/time.h \ + sys/un.h sys/wait.h dlfcn.h errno.h \ + fcntl.h libgen.h libintl.h memory.h \ + netinet/in.h setjmp.h stdbool.h sysexits.h \ + unistd.h utime.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + for ac_header in stdarg.h varargs.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_arg_hdr=true;break +else + lo_have_arg_hdr=false +fi + +done + + + for ac_header in string.h strings.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_str_hdr=true;break +else + lo_have_str_hdr=false +fi + +done + + + for ac_header in limits.h sys/limits.h values.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_lim_hdr=true;break +else + lo_have_lim_hdr=false +fi + +done + + + for ac_header in inttypes.h stdint.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_typ_hdr=true;break +else + lo_have_typ_hdr=false +fi + +done + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdnoreturn.h" >&5 +$as_echo_n "checking for working stdnoreturn.h... " >&6; } +if ${gl_cv_header_working_stdnoreturn_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include + /* Do not check for 'noreturn' after the return type. + C11 allows it, but it's rarely done that way + and circa-2012 bleeding-edge GCC rejects it when given + -Werror=old-style-declaration. */ + noreturn void foo1 (void) { exit (0); } + _Noreturn void foo2 (void) { exit (0); } + int testit (int argc, char **argv) { + if (argc & 1) + return 0; + (argv[0][0] ? foo1 : foo2) (); + } + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_header_working_stdnoreturn_h=yes +else + gl_cv_header_working_stdnoreturn_h=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdnoreturn_h" >&5 +$as_echo "$gl_cv_header_working_stdnoreturn_h" >&6; } + + if test $gl_cv_header_working_stdnoreturn_h = yes; then + STDNORETURN_H='' + else + STDNORETURN_H='stdnoreturn.h' + fi + + + if test -n "$STDNORETURN_H"; then + GL_GENERATE_STDNORETURN_H_TRUE= + GL_GENERATE_STDNORETURN_H_FALSE='#' +else + GL_GENERATE_STDNORETURN_H_TRUE='#' + GL_GENERATE_STDNORETURN_H_FALSE= +fi + + + + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + for ac_header in runetype.h wchar.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + # Check whether --enable-nls was given. +if test "${enable_nls+set}" = set; then : + enableval=$enable_nls; +fi + + if test "x$enable_nls" != "xno" && \ + test "X${ac_cv_header_libintl_h}" = Xyes; then : + + +$as_echo "#define ENABLE_NLS 1" >>confdefs.h + +fi + + # -------------------------------------------- + # Verify certain entries from AC_CHECK_HEADERS + # -------------------------------------------- + ${lo_have_arg_hdr} || \ + as_fn_error $? "you must have stdarg.h or varargs.h on your system" "$LINENO" 5 + + ${lo_have_str_hdr} || \ + as_fn_error $? "you must have string.h or strings.h on your system" "$LINENO" 5 + + ${lo_have_lim_hdr} || \ + as_fn_error $? "you must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 + + ${lo_have_typ_hdr} || \ + as_fn_error $? "you must have inttypes.h or stdint.h on your system" "$LINENO" 5 + + for f in sys_types sys_param sys_stat string errno stdlib memory setjmp + do eval as_ac_var=\${ac_cv_header_${f}_h} + test "X${as_ac_var}" = Xyes || { + as_fn_error $? "you must have ${f}.h on your system" "$LINENO" 5 + } + done + test "X${ac_cv_header_inttypes_h-no}" = Xyes || \ + echo '#include ' > inttypes.h + + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default" +if test "x$ac_cv_type_wchar_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WCHAR_T 1 +_ACEOF + + +fi + + ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif + +" +if test "x$ac_cv_type_wint_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WINT_T 1 +_ACEOF + + +fi + + ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" +if test "x$ac_cv_type_int8_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT8_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" +if test "x$ac_cv_type_uint8_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT8_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" +if test "x$ac_cv_type_int16_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT16_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" +if test "x$ac_cv_type_uint16_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT16_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" +if test "x$ac_cv_type_int32_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT32_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" +if test "x$ac_cv_type_uint32_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT32_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" +if test "x$ac_cv_type_intptr_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INTPTR_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" +if test "x$ac_cv_type_uint_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PID_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SIZE_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" +if test "x$ac_cv_type_ptrdiff_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PTRDIFF_T 1 +_ACEOF + + +fi + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5 +$as_echo_n "checking size of char *... " >&6; } +if ${ac_cv_sizeof_char_p+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_char_p" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (char *) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_char_p=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5 +$as_echo "$ac_cv_sizeof_char_p" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_CHAR_P $ac_cv_sizeof_char_p +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if ${ac_cv_sizeof_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (int) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_int=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if ${ac_cv_sizeof_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 +$as_echo_n "checking size of short... " >&6; } +if ${ac_cv_sizeof_short+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_short" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (short) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_short=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 +$as_echo "$ac_cv_sizeof_short" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +_ACEOF + + + + # ------------ + # AC_CHECK_LIB + # ------------ + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 +$as_echo_n "checking for pathfind in -lgen... " >&6; } +if ${ac_cv_lib_gen_pathfind+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lgen $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pathfind (); +int +main () +{ +return pathfind (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_gen_pathfind=yes +else + ac_cv_lib_gen_pathfind=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 +$as_echo "$ac_cv_lib_gen_pathfind" >&6; } +if test "x$ac_cv_lib_gen_pathfind" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBGEN 1 +_ACEOF + + LIBS="-lgen $LIBS" + +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettext in -lintl" >&5 +$as_echo_n "checking for gettext in -lintl... " >&6; } +if ${ac_cv_lib_intl_gettext+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lintl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char gettext (); +int +main () +{ +return gettext (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_intl_gettext=yes +else + ac_cv_lib_intl_gettext=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_gettext" >&5 +$as_echo "$ac_cv_lib_intl_gettext" >&6; } +if test "x$ac_cv_lib_intl_gettext" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBINTL 1 +_ACEOF + + LIBS="-lintl $LIBS" + +fi + + for ac_func in vprintf +do : + ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" +if test "x$ac_cv_func_vprintf" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VPRINTF 1 +_ACEOF + +ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" +if test "x$ac_cv_func__doprnt" = xyes; then : + +$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h + +fi + +fi +done + + + for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if ${ac_cv_func_fork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if ${ac_cv_func_vfork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } + +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi + +if test "x$ac_cv_func_vfork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h + +fi +if test "x$ac_cv_func_fork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h + +fi + + for ac_func in mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal fchmod fstat chmod +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + + while : + do + POSIX_SHELL=`which bash` + test -x "$POSIX_SHELL" && break + POSIX_SHELL=`which dash` + test -x "$POSIX_SHELL" && break + POSIX_SHELL=/usr/xpg4/bin/sh + test -x "$POSIX_SHELL" && break + POSIX_SHELL=`/bin/sh -c ' + exec 2>/dev/null + if ! true ; then exit 1 ; fi + echo /bin/sh'` + test -x "$POSIX_SHELL" && break + as_fn_error $? "cannot locate a working POSIX shell" "$LINENO" 5 + done + +cat >>confdefs.h <<_ACEOF +#define POSIX_SHELL "${POSIX_SHELL}" +_ACEOF + + + + + + LIBOPTS_BUILD_BLOCKED=true + + + NEED_LIBOPTS_DIR='' + + # Check whether --enable-local-libopts was given. +if test "${enable_local_libopts+set}" = set; then : + enableval=$enable_local_libopts; + if test x$enableval = xyes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5 +$as_echo "$as_me: Using supplied libopts tearoff" >&6;} + LIBOPTS_CFLAGS='-I$(top_srcdir)/sntp/libopts' + NEED_LIBOPTS_DIR=true + LIBOPTS_LDADD='$(top_builddir)/sntp/libopts/libopts.la' + fi +fi + + + # Check whether --enable-libopts-install was given. +if test "${enable_libopts_install+set}" = set; then : + enableval=$enable_libopts_install; +fi + + if test "X${enable_libopts_install}" = Xyes; then + INSTALL_LIBOPTS_TRUE= + INSTALL_LIBOPTS_FALSE='#' +else + INSTALL_LIBOPTS_TRUE='#' + INSTALL_LIBOPTS_FALSE= +fi + + + if test -z "${NEED_LIBOPTS_DIR}" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5 +$as_echo_n "checking whether autoopts-config can be found... " >&6; } + +# Check whether --with-autoopts-config was given. +if test "${with_autoopts_config+set}" = set; then : + withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5 +$as_echo_n "checking whether autoopts-config is specified... " >&6; } +if ${lo_cv_with_autoopts_config+:} false; then : + $as_echo_n "(cached) " >&6 +else + if autoopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=autoopts-config + elif libopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=libopts-config + else lo_cv_with_autoopts_config=no ; fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5 +$as_echo "$lo_cv_with_autoopts_config" >&6; } + +fi + # end of AC_ARG_WITH + + if ${lo_cv_test_autoopts+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test -z "${lo_cv_with_autoopts_config}" \ + -o X"${lo_cv_with_autoopts_config}" = Xno + then + if autoopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=autoopts-config + elif libopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=libopts-config + else lo_cv_with_autoopts_config=false ; fi + fi + lo_cv_test_autoopts=` + ${lo_cv_with_autoopts_config} --libs` 2> /dev/null + if test $? -ne 0 -o -z "${lo_cv_test_autoopts}" + then lo_cv_test_autoopts=no ; fi + +fi + # end of CACHE_VAL + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5 +$as_echo "${lo_cv_test_autoopts}" >&6; } + + if test "X${lo_cv_test_autoopts}" != Xno + then + LIBOPTS_LDADD="${lo_cv_test_autoopts}" + LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`" + else + LIBOPTS_LDADD='$(top_builddir)/sntp/libopts/libopts.la' + LIBOPTS_CFLAGS='-I$(top_srcdir)/sntp/libopts' + NEED_LIBOPTS_DIR=true + fi + fi # end of if test -z "${NEED_LIBOPTS_DIR}" + if test -n "${LIBOPTS_BUILD_BLOCKED}" ; then + NEED_LIBOPTS_DIR='' + fi + if test -n "${NEED_LIBOPTS_DIR}"; then + NEED_LIBOPTS_TRUE= + NEED_LIBOPTS_FALSE='#' +else + NEED_LIBOPTS_TRUE='#' + NEED_LIBOPTS_FALSE= +fi + + + + LIBOPTS_DIR=sntp/libopts + + +# end of AC_DEFUN of LIBOPTS_CHECK_COMMON + + # end of AC_DEFUN of LIBOPTS_CHECK_NOBUILD + + + + +ntp_pkgconfig_min_version='0.15.0' +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PKG_CONFIG=$ac_cv_path_PKG_CONFIG +if test -n "$PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 +$as_echo "$PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_path_PKG_CONFIG"; then + ac_pt_PKG_CONFIG=$PKG_CONFIG + # Extract the first word of "pkg-config", so it can be a program name with args. +set dummy pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG +if test -n "$ac_pt_PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 +$as_echo "$ac_pt_PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_PKG_CONFIG" = x; then + PKG_CONFIG="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + PKG_CONFIG=$ac_pt_PKG_CONFIG + fi +else + PKG_CONFIG="$ac_cv_path_PKG_CONFIG" +fi + +{ ac_cv_path_PKG_CONFIG=; unset ac_cv_path_PKG_CONFIG;} +{ ac_cv_path_ac_pt_PKG_CONFIG=; unset ac_cv_path_ac_pt_PKG_CONFIG;} + +case "$PKG_CONFIG" in + /*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pkg-config is at least version $ntp_pkgconfig_min_version" >&5 +$as_echo_n "checking if pkg-config is at least version $ntp_pkgconfig_min_version... " >&6; } + if $PKG_CONFIG --atleast-pkgconfig-version $ntp_pkgconfig_min_version; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + PKG_CONFIG="" + fi + ;; +esac + + + + +# Check whether --enable-local-libevent was given. +if test "${enable_local_libevent+set}" = set; then : + enableval=$enable_local_libevent; ntp_use_local_libevent=$enableval +else + ntp_use_local_libevent=${ntp_use_local_libevent-detect} + +fi + + + + + +ntp_libevent_min_version=2 +ntp_libevent_tearoff=sntp/libevent + + + + + +case "$ntp_use_local_libevent" in + yes) + ;; + *) # If we have (a good enough) pkg-config, see if it can find libevent + case "$PKG_CONFIG" in + /*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libevent $ntp_libevent_min_version or later is installed" >&5 +$as_echo_n "checking if libevent $ntp_libevent_min_version or later is installed... " >&6; } + if $PKG_CONFIG --atleast-version=$ntp_libevent_min_version libevent + then + ntp_use_local_libevent=no + { $as_echo "$as_me:${as_lineno-$LINENO}: Using the installed libevent" >&5 +$as_echo "$as_me: Using the installed libevent" >&6;} + CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads` + CPPFLAGS_LIBEVENT=`$PKG_CONFIG --cflags-only-I libevent` + # HMS: I hope the following is accurate. + # We don't need -levent, we only need -levent_core. + # While we could grab only the -L stuff, there *might* be + # other flags there we want. Originally we just removed -levent + # but then somebody decided to install -levent-2.0 + # LDADD_LIBEVENT=`$PKG_CONFIG --libs libevent | sed 's:-levent::'` + # So now we dance... + LDADD_LIBEVENT= + for i in `$PKG_CONFIG --libs libevent` + do + case "$i" in + -levent*) ;; + *) case "$LDADD_LIBEVENT" in + '') LDADD_LIBEVENT="$i" ;; + *) LDADD_LIBEVENT="$LDADD_LIBEVENT $i" ;; + esac + ;; + esac + done + case "$LIBISC_PTHREADS_NOTHREADS" in + pthreads) + LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_pthreads" + esac + LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_core" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + ntp_use_local_libevent=yes + # HMS: do we only need to do this if LIBISC_PTHREADS_NOTHREADS + # is "pthreads"? + CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + ntp_use_local_libevent=yes + ;; + esac + ;; +esac + +case "$ntp_use_local_libevent" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: Using libevent tearoff" >&5 +$as_echo "$as_me: Using libevent tearoff" >&6;} + CPPFLAGS_LIBEVENT="-I\$(top_builddir)/$ntp_libevent_tearoff/include -I\$(top_srcdir)/$ntp_libevent_tearoff/include" + case "$LIBISC_PTHREADS_NOTHREADS" in + pthreads) + LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_pthreads.la \$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la" + ;; + *) + LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la" + esac +esac + + + if test "x$ntp_use_local_libevent" = "xyes"; then + BUILD_LIBEVENT_TRUE= + BUILD_LIBEVENT_FALSE='#' +else + BUILD_LIBEVENT_TRUE='#' + BUILD_LIBEVENT_FALSE= +fi + + + + + + +# Expose a cross-compilation indicator to makefiles + if test $build != $host; then + NTP_CROSSCOMPILE_TRUE= + NTP_CROSSCOMPILE_FALSE='#' +else + NTP_CROSSCOMPILE_TRUE='#' + NTP_CROSSCOMPILE_FALSE= +fi + + + +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + +fi + + + # Check whether --enable-c99-snprintf was given. +if test "${enable_c99_snprintf+set}" = set; then : + enableval=$enable_c99_snprintf; force_c99_snprintf=$enableval +else + force_c99_snprintf=no + +fi + + case "$force_c99_snprintf" in + yes) + hw_force_rpl_snprintf=yes + hw_force_rpl_vsnprintf=yes + esac + + + + + + + for ac_header in $ac_header_list +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5 +$as_echo_n "checking for unsigned long long int... " >&6; } +if ${ac_cv_type_unsigned_long_long_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_type_unsigned_long_long_int=yes + if test "x${ac_cv_prog_cc_c99-no}" = xno; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + /* For now, do not test the preprocessor; as of 2007 there are too many + implementations with broken preprocessors. Perhaps this can + be revisited in 2012. In the meantime, code should not expect + #if to work with literals wider than 32 bits. */ + /* Test literals. */ + long long int ll = 9223372036854775807ll; + long long int nll = -9223372036854775807LL; + unsigned long long int ull = 18446744073709551615ULL; + /* Test constant expressions. */ + typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll) + ? 1 : -1)]; + typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1 + ? 1 : -1)]; + int i = 63; +int +main () +{ +/* Test availability of runtime routines for shift and division. */ + long long int llmax = 9223372036854775807ll; + unsigned long long int ullmax = 18446744073709551615ull; + return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i) + | (llmax / ll) | (llmax % ll) + | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i) + | (ullmax / ull) | (ullmax % ull)); + ; + return 0; +} + +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + +else + ac_cv_type_unsigned_long_long_int=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5 +$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; } + if test $ac_cv_type_unsigned_long_long_int = yes; then + +$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h + + fi + + + ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf" +if test "x$ac_cv_func_vsnprintf" = xyes; then : + hw_cv_func_vsnprintf=yes +else + hw_cv_func_vsnprintf=no +fi + + if test "$hw_cv_func_vsnprintf" = yes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether vsnprintf is C99 compliant" >&5 +$as_echo_n "checking whether vsnprintf is C99 compliant... " >&6; } +if ${hw_cv_func_vsnprintf_c99+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + hw_cv_func_vsnprintf_c99=no +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#if HAVE_STDARG_H + #include + #endif + #include + static int testprintf(char *buf, size_t size, const char *format, ...) + { + int result; + va_list ap; + va_start(ap, format); + result = vsnprintf(buf, size, format, ap); + va_end(ap); + return result; + } +int +main () +{ +char buf[43]; + if (testprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 || + testprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 || + buf[0] != 'T' || buf[3] != '\0') + return 1; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + hw_cv_func_vsnprintf_c99=yes +else + hw_cv_func_vsnprintf_c99=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_vsnprintf_c99" >&5 +$as_echo "$hw_cv_func_vsnprintf_c99" >&6; } +else + hw_cv_func_vsnprintf_c99=no +fi + +$as_echo "#define HAVE_VSNPRINTF 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement vsnprintf will be used" >&5 +$as_echo_n "checking if C99-snprintf replacement vsnprintf will be used... " >&6; } + if test "${hw_force_rpl_vsnprintf=no}" = yes -o "$hw_cv_func_vsnprintf_c99" = no; then : + hw_use_rpl_vsnprintf=yes +else + hw_use_rpl_vsnprintf=no +fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_vsnprintf" >&5 +$as_echo "$hw_use_rpl_vsnprintf" >&6; } + if test "$hw_use_rpl_vsnprintf" = yes; then : + +$as_echo "#define HW_WANT_RPL_VSNPRINTF 1" >>confdefs.h + + if test ${hw_nodef_vsnprintf=no} = no; then : + +$as_echo "#define vsnprintf rpl_vsnprintf" >>confdefs.h + +fi + for ac_header in inttypes.h locale.h stddef.h stdint.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include +" +if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_LCONV_DECIMAL_POINT 1 +_ACEOF + + +fi +ac_fn_c_check_member "$LINENO" "struct lconv" "thousands_sep" "ac_cv_member_struct_lconv_thousands_sep" "#include +" +if test "x$ac_cv_member_struct_lconv_thousands_sep" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_LCONV_THOUSANDS_SEP 1 +_ACEOF + + +fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double" >&5 +$as_echo_n "checking for long double... " >&6; } +if ${ac_cv_type_long_double+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$GCC" = yes; then + ac_cv_type_long_double=yes + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* The Stardent Vistra knows sizeof (long double), but does + not support it. */ + long double foo = 0.0L; +int +main () +{ +static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8. */ + sizeof (double) <= sizeof (long double))]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_type_long_double=yes +else + ac_cv_type_long_double=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5 +$as_echo "$ac_cv_type_long_double" >&6; } + if test $ac_cv_type_long_double = yes; then + +$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h + + fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5 +$as_echo_n "checking for long long int... " >&6; } +if ${ac_cv_type_long_long_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_type_long_long_int=yes + if test "x${ac_cv_prog_cc_c99-no}" = xno; then + ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int + if test $ac_cv_type_long_long_int = yes; then + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #ifndef LLONG_MAX + # define HALF \ + (1LL << (sizeof (long long int) * CHAR_BIT - 2)) + # define LLONG_MAX (HALF - 1 + HALF) + #endif +int +main () +{ +long long int n = 1; + int i; + for (i = 0; ; i++) + { + long long int m = n << i; + if (m >> i != n) + return 1; + if (LLONG_MAX / 2 < m) + break; + } + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + +else + ac_cv_type_long_long_int=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + fi + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5 +$as_echo "$ac_cv_type_long_long_int" >&6; } + if test $ac_cv_type_long_long_int = yes; then + +$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h + + fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5 +$as_echo_n "checking for unsigned long long int... " >&6; } +if ${ac_cv_type_unsigned_long_long_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_type_unsigned_long_long_int=yes + if test "x${ac_cv_prog_cc_c99-no}" = xno; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + /* For now, do not test the preprocessor; as of 2007 there are too many + implementations with broken preprocessors. Perhaps this can + be revisited in 2012. In the meantime, code should not expect + #if to work with literals wider than 32 bits. */ + /* Test literals. */ + long long int ll = 9223372036854775807ll; + long long int nll = -9223372036854775807LL; + unsigned long long int ull = 18446744073709551615ULL; + /* Test constant expressions. */ + typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll) + ? 1 : -1)]; + typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1 + ? 1 : -1)]; + int i = 63; +int +main () +{ +/* Test availability of runtime routines for shift and division. */ + long long int llmax = 9223372036854775807ll; + unsigned long long int ullmax = 18446744073709551615ull; + return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i) + | (llmax / ll) | (llmax % ll) + | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i) + | (ullmax / ull) | (ullmax % ull)); + ; + return 0; +} + +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + +else + ac_cv_type_unsigned_long_long_int=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5 +$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; } + if test $ac_cv_type_unsigned_long_long_int = yes; then + +$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h + + fi + + ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + +fi + + + + ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" "$ac_includes_default" +if test "x$ac_cv_type_intmax_t" = xyes; then : + +$as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h + +else + test $ac_cv_type_long_long_int = yes \ + && ac_type='long long int' \ + || ac_type='long int' + +cat >>confdefs.h <<_ACEOF +#define intmax_t $ac_type +_ACEOF + +fi + + + + + ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" "$ac_includes_default" +if test "x$ac_cv_type_uintmax_t" = xyes; then : + +$as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h + +else + test $ac_cv_type_unsigned_long_long_int = yes \ + && ac_type='unsigned long long int' \ + || ac_type='unsigned long int' + +cat >>confdefs.h <<_ACEOF +#define uintmax_t $ac_type +_ACEOF + +fi + + + + ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = xyes; then : + +$as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h + +else + for ac_type in 'unsigned int' 'unsigned long int' \ + 'unsigned long long int'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +cat >>confdefs.h <<_ACEOF +#define uintptr_t $ac_type +_ACEOF + + ac_type= +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test -z "$ac_type" && break + done +fi + + + ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" +if test "x$ac_cv_type_ptrdiff_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PTRDIFF_T 1 +_ACEOF + + +fi + + for ac_func in localeconv +do : + ac_fn_c_check_func "$LINENO" "localeconv" "ac_cv_func_localeconv" +if test "x$ac_cv_func_localeconv" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LOCALECONV 1 +_ACEOF + +fi +done + + + if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 +$as_echo_n "checking for an ANSI C-conforming const... " >&6; } +if ${ac_cv_c_const+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#ifndef __cplusplus + /* Ultrix mips cc rejects this sort of thing. */ + typedef int charset[2]; + const charset cs = { 0, 0 }; + /* SunOS 4.1.1 cc rejects this. */ + char const *const *pcpcc; + char **ppc; + /* NEC SVR4.0.2 mips cc rejects this. */ + struct point {int x, y;}; + static struct point const zero = {0,0}; + /* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in + an arm of an if-expression whose if-part is not a constant + expression */ + const char *g = "string"; + pcpcc = &g + (g ? g-g : 0); + /* HPUX 7.0 cc rejects these. */ + ++pcpcc; + ppc = (char**) pcpcc; + pcpcc = (char const *const *) ppc; + { /* SCO 3.2v4 cc rejects this sort of thing. */ + char tx; + char *t = &tx; + char const *s = 0 ? (char *) 0 : (char const *) 0; + + *t++ = 0; + if (s) return 0; + } + { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; + } + { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; + } + { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; } bx; + struct s *b = &bx; b->j = 5; + } + { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; + if (!foo) return 0; + } + return !cs[0] && !zero.x; +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_const=yes +else + ac_cv_c_const=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 +$as_echo "$ac_cv_c_const" >&6; } +if test $ac_cv_c_const = no; then + +$as_echo "#define const /**/" >>confdefs.h + +fi + + + + + case " $LIBOBJS " in + *" snprintf.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" + ;; +esac + + _hw_cv_func_xprintf_replace_done=yes +fi + +fi + + + ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf" +if test "x$ac_cv_func_snprintf" = xyes; then : + hw_cv_func_snprintf=yes +else + hw_cv_func_snprintf=no +fi + + if test "$hw_cv_func_snprintf" = yes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf is C99 compliant" >&5 +$as_echo_n "checking whether snprintf is C99 compliant... " >&6; } +if ${hw_cv_func_snprintf_c99+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + hw_cv_func_snprintf_c99=no +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +char buf[43]; + if (snprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 || + snprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 || + buf[0] != 'T' || buf[3] != '\0') + return 1; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + hw_cv_func_snprintf_c99=yes +else + hw_cv_func_snprintf_c99=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_snprintf_c99" >&5 +$as_echo "$hw_cv_func_snprintf_c99" >&6; } +else + hw_cv_func_snprintf_c99=no +fi + +$as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement snprintf will be used" >&5 +$as_echo_n "checking if C99-snprintf replacement snprintf will be used... " >&6; } + if test "${hw_force_rpl_snprintf=no}" = yes -o "$hw_cv_func_snprintf_c99" = no; then : + hw_use_rpl_snprintf=yes +else + hw_use_rpl_snprintf=no +fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_snprintf" >&5 +$as_echo "$hw_use_rpl_snprintf" >&6; } + if test "$hw_use_rpl_snprintf" = yes; then : + +$as_echo "#define HW_WANT_RPL_SNPRINTF 1" >>confdefs.h + + if test ${hw_nodef_snprintf=no} = no; then : + +$as_echo "#define snprintf rpl_snprintf" >>confdefs.h + +fi + + if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 +$as_echo_n "checking for an ANSI C-conforming const... " >&6; } +if ${ac_cv_c_const+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#ifndef __cplusplus + /* Ultrix mips cc rejects this sort of thing. */ + typedef int charset[2]; + const charset cs = { 0, 0 }; + /* SunOS 4.1.1 cc rejects this. */ + char const *const *pcpcc; + char **ppc; + /* NEC SVR4.0.2 mips cc rejects this. */ + struct point {int x, y;}; + static struct point const zero = {0,0}; + /* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in + an arm of an if-expression whose if-part is not a constant + expression */ + const char *g = "string"; + pcpcc = &g + (g ? g-g : 0); + /* HPUX 7.0 cc rejects these. */ + ++pcpcc; + ppc = (char**) pcpcc; + pcpcc = (char const *const *) ppc; + { /* SCO 3.2v4 cc rejects this sort of thing. */ + char tx; + char *t = &tx; + char const *s = 0 ? (char *) 0 : (char const *) 0; + + *t++ = 0; + if (s) return 0; + } + { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; + } + { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; + } + { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; } bx; + struct s *b = &bx; b->j = 5; + } + { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; + if (!foo) return 0; + } + return !cs[0] && !zero.x; +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_const=yes +else + ac_cv_c_const=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 +$as_echo "$ac_cv_c_const" >&6; } +if test $ac_cv_c_const = no; then + +$as_echo "#define const /**/" >>confdefs.h + +fi + + + + + case " $LIBOBJS " in + *" snprintf.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" + ;; +esac + + _hw_cv_func_xprintf_replace_done=yes +fi + +fi + + + + + +# HMS: Save $LIBS and empty it. +# any LIBS we add here should go in to LDADD_LIBNTP + +__LIBS=$LIBS +LIBS= + + + +# [Bug 2332] because we need to know if we are using GNU ld... + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for directory path separator" >&5 +$as_echo_n "checking for directory path separator... " >&6; } +if ${ntp_cv_dir_sep+:} false; then : + $as_echo_n "(cached) " >&6 +else + + case "$ntp_cv_dir_sep" in + '') + case "$host_os" in + *djgpp | *mingw32* | *emx*) + ntp_cv_dir_sep="'\\'" + ;; + *) + ntp_cv_dir_sep="'/'" + ;; + esac + esac + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_dir_sep" >&5 +$as_echo "$ntp_cv_dir_sep" >&6; } + +cat >>confdefs.h <<_ACEOF +#define DIR_SEP $ntp_cv_dir_sep +_ACEOF + + + + NTP_ORIG_LIBS="$LIBS" + +# Check whether --with-lineeditlibs was given. +if test "${with_lineeditlibs+set}" = set; then : + withval=$with_lineeditlibs; use_lineeditlibs="$withval" +else + use_lineeditlibs="edit,editline" + +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking line editing libraries" >&5 +$as_echo_n "checking line editing libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_lineeditlibs" >&5 +$as_echo "$use_lineeditlibs" >&6; } + case "$use_lineeditlibs" in + no) + ntp_lib_lineedit=no + ;; + *) + for lineedit_lib in `echo $use_lineeditlibs | sed -e 's/,/ /'`; do + for term_lib in "" termcap curses ncurses; do + case "$term_lib" in + '') + TRY_LIB="-l$lineedit_lib" + ;; + *) + TRY_LIB="-l$lineedit_lib -l$term_lib" + ;; + esac + LIBS="$NTP_ORIG_LIBS $TRY_LIB" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline() with $TRY_LIB" >&5 +$as_echo_n "checking for readline() with $TRY_LIB... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char readline (); +int +main () +{ +return readline (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_lib_lineedit="$TRY_LIB" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + case "$ntp_lib_lineedit" in + '') + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) + # Use readline() + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + esac + case "$term_lib" in + '') + # do not try el_gets without a terminal library + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for el_gets() with $TRY_LIB" >&5 +$as_echo_n "checking for el_gets() with $TRY_LIB... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char el_gets (); +int +main () +{ +return el_gets (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_lib_lineedit="$TRY_LIB" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + case "$ntp_lib_lineedit" in + '') + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) # Use el_gets() + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + ;; + esac # $ntp_lib_lineedit + esac # $term_lib + done + case "$ntp_lib_lineedit" in + '') + ;; + *) + break + ;; + esac + done + LIBS="$NTP_ORIG_LIBS" + ;; + esac # $use_lineeditlibs + + case "$ntp_lib_lineedit" in + '') + ntp_lib_lineedit="no" + ;; + no) + ;; + *) + EDITLINE_LIBS="$ntp_lib_lineedit" + + ;; + esac # $ntp_lib_lineedit + + case "$ntp_lib_lineedit" in + no) + ;; + *) + for ac_header in readline.h readline/readline.h histedit.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + for ac_header in history.h readline/history.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + case "$ac_cv_header_histedit_h" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to el_init()" >&5 +$as_echo_n "checking number of arguments to el_init()... " >&6; } +if ${ntp_cv_el_init_args+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + el_init("conftest", stdin, stdout, stderr); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_el_init_args=4 +else + ntp_cv_el_init_args=3 + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_el_init_args" >&5 +$as_echo "$ntp_cv_el_init_args" >&6; } + +cat >>confdefs.h <<_ACEOF +#define EL_INIT_ARGS $ntp_cv_el_init_args +_ACEOF + + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5 +$as_echo_n "checking whether readline supports history... " >&6; } + + ntp_lib_lineedit_history="no" + ORIG_LIBS="$LIBS" + LIBS="$ORIG_LIBS $ntp_lib_lineedit" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char add_history (); +int +main () +{ +return add_history (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_lib_lineedit_history="yes" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$ORIG_LIBS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_lib_lineedit_history" >&5 +$as_echo "$ntp_lib_lineedit_history" >&6; } + + case "$ntp_lib_lineedit_history" in + yes) + +$as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h + + esac + esac # $ntp_lib_lineedit + { NTP_ORIG_LIBS=; unset NTP_ORIG_LIBS;} + { ORIG_LIBS=; unset ORIG_LIBS;} + { TRY_LIB=; unset TRY_LIB;} + { use_lineeditlibs=; unset use_lineeditlibs;} + + +LIBM= +case "$host" in + *-*-darwin*) + ;; + *) + _libs=$LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing cos" >&5 +$as_echo_n "checking for library containing cos... " >&6; } +if ${ac_cv_search_cos+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char cos (); +int +main () +{ +return cos (); + ; + return 0; +} +_ACEOF +for ac_lib in '' m; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_cos=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_cos+:} false; then : + break +fi +done +if ${ac_cv_search_cos+:} false; then : + +else + ac_cv_search_cos=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_cos" >&5 +$as_echo "$ac_cv_search_cos" >&6; } +ac_res=$ac_cv_search_cos +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + LIBM="-lm" +fi + + LIBS=$_libs + ;; +esac + +{ _libs=; unset _libs;} + + +for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if ${ac_cv_func_fork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if ${ac_cv_func_vfork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } + +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi + +if test "x$ac_cv_func_vfork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h + +fi +if test "x$ac_cv_func_fork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h + +fi + +# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works +# for constant arguments. Useless! +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 +$as_echo_n "checking for working alloca.h... " >&6; } +if ${ac_cv_working_alloca_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +char *p = (char *) alloca (2 * sizeof (int)); + if (p) return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_working_alloca_h=yes +else + ac_cv_working_alloca_h=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 +$as_echo "$ac_cv_working_alloca_h" >&6; } +if test $ac_cv_working_alloca_h = yes; then + +$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 +$as_echo_n "checking for alloca... " >&6; } +if ${ac_cv_func_alloca_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __GNUC__ +# define alloca __builtin_alloca +#else +# ifdef _MSC_VER +# include +# define alloca _alloca +# else +# ifdef HAVE_ALLOCA_H +# include +# else +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ +void *alloca (size_t); +# endif +# endif +# endif +# endif +#endif + +int +main () +{ +char *p = (char *) alloca (1); + if (p) return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_func_alloca_works=yes +else + ac_cv_func_alloca_works=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 +$as_echo "$ac_cv_func_alloca_works" >&6; } + +if test $ac_cv_func_alloca_works = yes; then + +$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h + +else + # The SVR3 libPW and SVR4 libucb both contain incompatible functions +# that cause trouble. Some versions do not even contain alloca or +# contain a buggy version. If you still want to use their alloca, +# use ar to extract alloca.o from them instead of compiling alloca.c. + +ALLOCA=\${LIBOBJDIR}alloca.$ac_objext + +$as_echo "#define C_ALLOCA 1" >>confdefs.h + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 +$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } +if ${ac_cv_os_cray+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#if defined CRAY && ! defined CRAY2 +webecray +#else +wenotbecray +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "webecray" >/dev/null 2>&1; then : + ac_cv_os_cray=yes +else + ac_cv_os_cray=no +fi +rm -f conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 +$as_echo "$ac_cv_os_cray" >&6; } +if test $ac_cv_os_cray = yes; then + for ac_func in _getb67 GETB67 getb67; do + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + +cat >>confdefs.h <<_ACEOF +#define CRAY_STACKSEG_END $ac_func +_ACEOF + + break +fi + + done +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 +$as_echo_n "checking stack direction for C alloca... " >&6; } +if ${ac_cv_c_stack_direction+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_c_stack_direction=0 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +find_stack_direction (int *addr, int depth) +{ + int dir, dummy = 0; + if (! addr) + addr = &dummy; + *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; + dir = depth ? find_stack_direction (addr, depth - 1) : 0; + return dir + dummy; +} + +int +main (int argc, char **argv) +{ + return find_stack_direction (0, argc + !argv + 20) < 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_stack_direction=1 +else + ac_cv_c_stack_direction=-1 +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 +$as_echo "$ac_cv_c_stack_direction" >&6; } +cat >>confdefs.h <<_ACEOF +#define STACK_DIRECTION $ac_cv_c_stack_direction +_ACEOF + + +fi + +ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default" +if test "x$ac_cv_have_decl_strerror_r" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi + +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_STRERROR_R $ac_have_decl +_ACEOF + +for ac_func in strerror_r +do : + ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r" +if test "x$ac_cv_func_strerror_r" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STRERROR_R 1 +_ACEOF + +fi +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5 +$as_echo_n "checking whether strerror_r returns char *... " >&6; } +if ${ac_cv_func_strerror_r_char_p+:} false; then : + $as_echo_n "(cached) " >&6 +else + + ac_cv_func_strerror_r_char_p=no + if test $ac_cv_have_decl_strerror_r = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + char buf[100]; + char x = *strerror_r (0, buf, sizeof buf); + char *p = strerror_r (0, buf, sizeof buf); + return !p || x; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_func_strerror_r_char_p=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + else + # strerror_r is not declared. Choose between + # systems that have relatively inaccessible declarations for the + # function. BeOS and DEC UNIX 4.0 fall in this category, but the + # former has a strerror_r that returns char*, while the latter + # has a strerror_r that returns `int'. + # This test should segfault on the DEC system. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default + extern char *strerror_r (); +int +main () +{ +char buf[100]; + char x = *strerror_r (0, buf, sizeof buf); + return ! isalpha (x); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_strerror_r_char_p=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5 +$as_echo "$ac_cv_func_strerror_r_char_p" >&6; } +if test $ac_cv_func_strerror_r_char_p = yes; then + +$as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h + +fi + + +ac_busted_vpath_in_make=no +case "$build" in + *-*-irix6.1*) # 64 bit only + # busted vpath? + ;; + *-*-irix6*) # 6.2 (and later?) + ac_busted_vpath_in_make=yes + ;; + *-*-solaris2.5.1) + ac_busted_vpath_in_make=yes + ;; + *-*-unicosmp*) + ac_busted_vpath_in_make=yes + ;; +esac + +case "$ac_busted_vpath_in_make$srcdir" in + yes.|no*) + ;; + *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in + '') + as_fn_error $? "building outside of the main directory requires GNU make" "$LINENO" 5 + esac + ;; +esac + +case "$host" in + *-*-aix4*) + # Bug 2516: + # Was *-*-aix[[4-9]]* + # XXX only verified thru AIX6. But... + # Ken Link says this is fine for AIX 5.3 and 7.1, and sees no reason + # that this support would be in 5.3, removed in 6, and added back. + # + # (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub + # (returning ENOSYS). I didn't check 4.2. If, in the future, + # IBM pulls its thumbs out long enough to implement clock_settime, + # this conditional will need to change. Maybe use AC_TRY_RUN + # instead to try to set the time to itself and check errno. + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 +$as_echo_n "checking for library containing clock_gettime... " >&6; } +if ${ac_cv_search_clock_gettime+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char clock_gettime (); +int +main () +{ +return clock_gettime (); + ; + return 0; +} +_ACEOF +for ac_lib in '' rt; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_clock_gettime=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_clock_gettime+:} false; then : + break +fi +done +if ${ac_cv_search_clock_gettime+:} false; then : + +else + ac_cv_search_clock_gettime=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 +$as_echo "$ac_cv_search_clock_gettime" >&6; } +ac_res=$ac_cv_search_clock_gettime +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_clock_gettime" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_clock_gettime $LDADD_LIBNTP" ;; + esac + +fi + + for ac_func in clock_getres clock_gettime clock_settime +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + ;; +esac + +for ac_func in getclock stime timegm strlcpy strlcat +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + +# Bug 2713 +LDADD_LIBUTIL= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing snprintb" >&5 +$as_echo_n "checking for library containing snprintb... " >&6; } +if ${ac_cv_search_snprintb+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char snprintb (); +int +main () +{ +return snprintb (); + ; + return 0; +} +_ACEOF +for ac_lib in '' util; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_snprintb=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_snprintb+:} false; then : + break +fi +done +if ${ac_cv_search_snprintb+:} false; then : + +else + ac_cv_search_snprintb=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_snprintb" >&5 +$as_echo "$ac_cv_search_snprintb" >&6; } +ac_res=$ac_cv_search_snprintb +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_snprintb" in + 'none required') ;; + no) ;; + *) LDADD_LIBUTIL="$ac_cv_search_snprintb $LDADD_LIBUTIL" ;; + esac + +$as_echo "#define USE_SNPRINTB 1" >>confdefs.h + +fi + + +# +for ac_header in errno.h sys/socket.h sys/types.h time.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + +for ac_header in net/if.h +do : + ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" " + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + +" +if test "x$ac_cv_header_net_if_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_NET_IF_H 1 +_ACEOF + +fi + +done + +case "$host" in + *-hp-hpux*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if net/if.h requires mpinfou predeclaration" >&5 +$as_echo_n "checking if net/if.h requires mpinfou predeclaration... " >&6; } +if ${ntp_cv_predecl_mpinfou+:} false; then : + $as_echo_n "(cached) " >&6 +else + + np_cv_predecl_mpinfou=no + case "$ac_cv_header_net_if_h" in + no) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + typedef union mpinfou { + struct pdk_mpinfo *pdkptr; + struct mpinfo *pikptr; + } mpinfou_t; + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #include + +int +main () +{ + + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + + ntp_cv_predecl_mpinfou=yes + ac_cv_header_net_if_h=yes + + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + esac + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_predecl_mpinfou" >&5 +$as_echo "$ntp_cv_predecl_mpinfou" >&6; } + case "$ntp_cv_predecl_mpinfou" in + yes) + cat >>confdefs.h <<_ACEOF +#ifndef MPINFOU_PREDECLARED +# define MPINFOU_PREDECLARED +typedef union mpinfou { + struct pdk_mpinfo *pdkptr; + struct mpinfo *pikptr; +} mpinfou_t; +#endif +_ACEOF + + esac +esac + +case "$host" in + *-linux*) + for ac_header in linux/if_addr.h +do : + ac_fn_c_check_header_compile "$LINENO" "linux/if_addr.h" "ac_cv_header_linux_if_addr_h" " + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + +" +if test "x$ac_cv_header_linux_if_addr_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LINUX_IF_ADDR_H 1 +_ACEOF + +fi + +done + +esac + +for ac_header in arpa/nameser.h sys/param.h sys/time.h sys/timers.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + +# sys/sysctl.h depends on sys/param.h on OpenBSD - Bug 1576 +for ac_header in sys/sysctl.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" " + #if defined HAVE_SYS_PARAM_H + # include + #endif + +" +if test "x$ac_cv_header_sys_sysctl_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_SYSCTL_H 1 +_ACEOF + +fi + +done + +for ac_header in netinet/in_system.h netinet/in_systm.h netinet/in.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +for ac_header in resolv.h +do : + ac_fn_c_check_header_compile "$LINENO" "resolv.h" "ac_cv_header_resolv_h" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif + +" +if test "x$ac_cv_header_resolv_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_RESOLV_H 1 +_ACEOF + +fi + +done + + +for ac_header in net/if_var.h +do : + ac_fn_c_check_header_compile "$LINENO" "net/if_var.h" "ac_cv_header_net_if_var_h" " + #if HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_NET_IF_H + # include + #endif + +" +if test "x$ac_cv_header_net_if_var_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_NET_IF_VAR_H 1 +_ACEOF + +fi + +done + + +for ac_header in netinet/ip.h netinet/in_var.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NET_IF_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_NET_IF_VAR_H + # include + #endif + #ifdef HAVE_NETINET_IN_SYSTM_H + # include + #endif + +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +# HMS: Do we need to check for -lsocket before or after these tests? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5 +$as_echo_n "checking for library containing inet_pton... " >&6; } +if ${ac_cv_search_inet_pton+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_pton (); +int +main () +{ +return inet_pton (); + ; + return 0; +} +_ACEOF +for ac_lib in '' nsl; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_pton=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inet_pton+:} false; then : + break +fi +done +if ${ac_cv_search_inet_pton+:} false; then : + +else + ac_cv_search_inet_pton=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5 +$as_echo "$ac_cv_search_inet_pton" >&6; } +ac_res=$ac_cv_search_inet_pton +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_inet_pton" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_inet_pton $LDADD_LIBNTP" ;; + esac + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5 +$as_echo_n "checking for library containing inet_ntop... " >&6; } +if ${ac_cv_search_inet_ntop+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_ntop (); +int +main () +{ +return inet_ntop (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib -lnsl $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_ntop=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inet_ntop+:} false; then : + break +fi +done +if ${ac_cv_search_inet_ntop+:} false; then : + +else + ac_cv_search_inet_ntop=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5 +$as_echo "$ac_cv_search_inet_ntop" >&6; } +ac_res=$ac_cv_search_inet_ntop +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_inet_ntop" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_inet_ntop $LDADD_LIBNTP" ;; + esac + +fi + + +# [Bug 1628] On Solaris, we need -lxnet -lsocket. Generalize this to +# avoid keying on the OS name: If we find socket functions in +# libsocket, next try for them in libxnet without libsocket, if found, +# list both. If we simply tested libxnet first, we would find the +# functions there and never add libsocket. See also [Bug 660] +# http://bugs.ntp.org/show_bug.cgi?id=660#c9 +saved_LIBS=$LIBS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5 +$as_echo_n "checking for library containing setsockopt... " >&6; } +if ${ac_cv_search_setsockopt+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char setsockopt (); +int +main () +{ +return setsockopt (); + ; + return 0; +} +_ACEOF +for ac_lib in '' socket; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_setsockopt=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_setsockopt+:} false; then : + break +fi +done +if ${ac_cv_search_setsockopt+:} false; then : + +else + ac_cv_search_setsockopt=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5 +$as_echo "$ac_cv_search_setsockopt" >&6; } +ac_res=$ac_cv_search_setsockopt +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_setsockopt" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_setsockopt $LDADD_LIBNTP" ;; + esac + +fi + +case "$ac_cv_search_setsockopt" in + -lsocket) + LIBS="$saved_LIBS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getsockopt" >&5 +$as_echo_n "checking for library containing getsockopt... " >&6; } +if ${ac_cv_search_getsockopt+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char getsockopt (); +int +main () +{ +return getsockopt (); + ; + return 0; +} +_ACEOF +for ac_lib in '' xnet; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_getsockopt=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_getsockopt+:} false; then : + break +fi +done +if ${ac_cv_search_getsockopt+:} false; then : + +else + ac_cv_search_getsockopt=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getsockopt" >&5 +$as_echo "$ac_cv_search_getsockopt" >&6; } +ac_res=$ac_cv_search_getsockopt +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_getsockopt" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_getsockopt $LDADD_LIBNTP" ;; + esac + +fi + + # XXX Possible trouble here - reading the comments above and looking at the + # code below I wonder if we'll add -lxnet when we don't need it. + # Also, do we need to add -lxnet to LDADD_LIBNTP, or perhaps see if it's + # there when it is not needed? + case "$ac_cv_search_getsockopt" in + -lxnet) + LIBS="-lxnet -lsocket $saved_LIBS" + ;; + *) LIBS="-lsocket $saved_LIBS" + ;; + esac + ;; +esac +{ saved_LIBS=; unset saved_LIBS;} + +# Bug 2427 - look for recvmsg here. +for ac_func in recvmsg +do : + ac_fn_c_check_func "$LINENO" "recvmsg" "ac_cv_func_recvmsg" +if test "x$ac_cv_func_recvmsg" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_RECVMSG 1 +_ACEOF + +fi +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +$as_echo_n "checking for inline... " >&6; } +if ${ac_cv_c_inline+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __cplusplus +typedef int foo_t; +static $ac_kw foo_t static_foo () {return 0; } +$ac_kw foo_t foo () {return 0; } +#endif + +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_inline=$ac_kw +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test "$ac_cv_c_inline" != no && break +done + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +$as_echo "$ac_cv_c_inline" >&6; } + +case $ac_cv_c_inline in + inline | yes) ;; + *) + case $ac_cv_c_inline in + no) ac_val=;; + *) ac_val=$ac_cv_c_inline;; + esac + cat >>confdefs.h <<_ACEOF +#ifndef __cplusplus +#define inline $ac_val +#endif +_ACEOF + ;; +esac + + +case "$ac_cv_c_inline" in + '') + ;; + *) + +$as_echo "#define HAVE_INLINE 1" >>confdefs.h + + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 +$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } +if ${ac_cv_header_time+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include + +int +main () +{ +if ((struct tm *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_time=yes +else + ac_cv_header_time=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 +$as_echo "$ac_cv_header_time" >&6; } +if test $ac_cv_header_time = yes; then + +$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h + +fi + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 +$as_echo_n "checking size of time_t... " >&6; } +if ${ac_cv_sizeof_time_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_time_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (time_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_time_t=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 +$as_echo "$ac_cv_sizeof_time_t" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_TIME_T $ac_cv_sizeof_time_t +_ACEOF + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 +$as_echo_n "checking whether char is unsigned... " >&6; } +if ${ac_cv_c_char_unsigned+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((char) -1) < 0)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_char_unsigned=no +else + ac_cv_c_char_unsigned=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 +$as_echo "$ac_cv_c_char_unsigned" >&6; } +if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then + $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h + +fi + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of signed char" >&5 +$as_echo_n "checking size of signed char... " >&6; } +if ${ac_cv_sizeof_signed_char+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (signed char))" "ac_cv_sizeof_signed_char" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_signed_char" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (signed char) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_signed_char=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_signed_char" >&5 +$as_echo "$ac_cv_sizeof_signed_char" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char +_ACEOF + + +ac_fn_c_check_type "$LINENO" "s_char" "ac_cv_type_s_char" "$ac_includes_default" +if test "x$ac_cv_type_s_char" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_S_CHAR 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default" +if test "x$ac_cv_type_long_long" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_LONG_LONG 1 +_ACEOF + + +fi + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 +$as_echo_n "checking size of short... " >&6; } +if ${ac_cv_sizeof_short+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_short" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (short) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_short=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 +$as_echo "$ac_cv_sizeof_short" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if ${ac_cv_sizeof_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (int) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_int=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if ${ac_cv_sizeof_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + + +case "$ac_cv_type_long_long" in + no) + ;; + *) + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 +$as_echo_n "checking size of long long... " >&6; } +if ${ac_cv_sizeof_long_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 +$as_echo "$ac_cv_sizeof_long_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long +_ACEOF + + + ;; +esac + +case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in + *yes) + # We have a typedef for s_char. Might as well believe it... + ;; + no0no) + # We have signed chars, can't say 'signed char', no s_char typedef. + +$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h + + ;; + no1no) + # We have signed chars, can say 'signed char', no s_char typedef. + +$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h + + ;; + yes0no) + # We have unsigned chars, can't say 'signed char', no s_char typedef. + as_fn_error $? "No way to specify a signed character!" "$LINENO" 5 + ;; + yes1no) + # We have unsigned chars, can say 'signed char', no s_char typedef. + +$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h + + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 +$as_echo_n "checking for uid_t in sys/types.h... " >&6; } +if ${ac_cv_type_uid_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "uid_t" >/dev/null 2>&1; then : + ac_cv_type_uid_t=yes +else + ac_cv_type_uid_t=no +fi +rm -f conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 +$as_echo "$ac_cv_type_uid_t" >&6; } +if test $ac_cv_type_uid_t = no; then + +$as_echo "#define uid_t int" >>confdefs.h + + +$as_echo "#define gid_t int" >>confdefs.h + +fi + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including debugging code" >&5 +$as_echo_n "checking if we're including debugging code... " >&6; } +# Check whether --enable-debugging was given. +if test "${enable_debugging+set}" = set; then : + enableval=$enable_debugging; ntp_ok=$enableval +else + ntp_ok=yes + +fi + +case "$ntp_ok" in + yes) + +$as_echo "#define DEBUG 1" >>confdefs.h + +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } + + + +# check if we can compile with pthreads +for ac_header in semaphore.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "semaphore.h" "ac_cv_header_semaphore_h" "$ac_includes_default" +if test "x$ac_cv_header_semaphore_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SEMAPHORE_H 1 +_ACEOF + +fi + +done + +for ac_func in socketpair +do : + ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair" +if test "x$ac_cv_func_socketpair" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SOCKETPAIR 1 +_ACEOF + +fi +done - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac +# Check whether --enable-thread-support was given. +if test "${enable_thread_support+set}" = set; then : + enableval=$enable_thread_support; +else + enable_thread_support=yes - ld_shlibs=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' +fi - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac +have_pthreads=no +case "$enable_thread_support" in + no) ;; + *) + ol_found_pthreads=no - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs=no - cat <&2 -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. -EOF - fi - ;; +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu - amigaos*) - archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes +# OpenLDAP --with-threads - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - ld_shlibs=no - ;; +# Check whether --with-threads was given. +if test "${with_threads+set}" = set; then : + withval=$with_threads; + ol_arg=invalid + for ol_val in auto nt posix mach pth lwp yes no manual ; do + if test "$withval" = "$ol_val" ; then + ol_arg="$ol_val" + fi + done + if test "$ol_arg" = "invalid" ; then + as_fn_error $? "bad value $withval for --with-threads" "$LINENO" 5 + fi + ol_with_threads="$ol_arg" - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; +else + ol_with_threads="auto" +fi +# end --with-threads - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - ld_shlibs=no - fi - ;; +case "$ol_with_threads$host" in + auto*-*-solaris2.[0-6]) + ol_with_threads=no + ;; +esac - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; + +ol_aix_threads=no +case "$host" in +*-*-aix*) if test -z "$CC" ; then + case "$ol_with_threads" in + auto | yes | posix) ol_aix_threads=yes ;; + esac + fi +;; +esac + +if test $ol_aix_threads = yes ; then + if test -z "${CC}" ; then + for ac_prog in cc_r xlc_r cc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CC" && break +done + + + if test "$CC" = cc ; then + if test $ol_with_threads != auto ; then + as_fn_error $? "--with-threads requires cc_r (or other suitable compiler) on AIX" "$LINENO" 5 + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling threads, no cc_r on AIX" >&5 +$as_echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;} + fi + ol_with_threads=no + fi + fi + + case ${CC} in cc_r | xlc_r) + ol_with_threads=posix + ol_cv_pthread_create=yes + ;; esac - archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' +fi - if test $supports_anon_versioning = yes; then - archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' +ol_link_threads=no +# OpenLDAP --with-yielding_select + +# Check whether --with-yielding_select was given. +if test "${with_yielding_select+set}" = set; then : + withval=$with_yielding_select; + ol_arg=invalid + for ol_val in auto yes no manual ; do + if test "$withval" = "$ol_val" ; then + ol_arg="$ol_val" + fi + done + if test "$ol_arg" = "invalid" ; then + as_fn_error $? "bad value $withval for --with-yielding_select" "$LINENO" 5 fi - else - ld_shlibs=no - fi - ;; + ol_with_yielding_select="$ol_arg" - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; +else + ol_with_yielding_select="auto" +fi +# end --with-yielding_select + + +case $ol_with_threads in auto | yes | nt) + + + ac_fn_c_check_func "$LINENO" "_beginthread" "ac_cv_func__beginthread" +if test "x$ac_cv_func__beginthread" = xyes; then : + +fi + + + if test $ac_cv_func__beginthread = yes ; then + +$as_echo "#define HAVE_NT_THREADS 1" >>confdefs.h + + ol_cv_nt_threads=yes + fi + + + if test "$ol_cv_nt_threads" = yes ; then + ol_link_threads=nt + ol_with_threads=found + ol_with_yielding_select=yes + + +$as_echo "#define HAVE_NT_SERVICE_MANAGER 1" >>confdefs.h + + +$as_echo "#define HAVE_NT_EVENT_LOG 1" >>confdefs.h + + fi + + if test $ol_with_threads = nt ; then + as_fn_error $? "could not locate NT Threads" "$LINENO" 5 + fi + ;; +esac + +case $ol_with_threads in auto | yes | posix) + + for ac_header in pthread.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default" +if test "x$ac_cv_header_pthread_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_H 1 +_ACEOF + +fi + +done + + + if test $ac_cv_header_pthread_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking POSIX thread version" >&5 +$as_echo_n "checking POSIX thread version... " >&6; } +if ${ol_cv_pthread_version+:} false; then : + $as_echo_n "(cached) " >&6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +# include + +int +main () +{ + + int i = PTHREAD_CREATE_JOINABLE; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_detach" >/dev/null 2>&1; then : + ol_cv_pthread_version=10 +else + ol_cv_pthread_version=8 +fi +rm -f conftest* + +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +# include +# ifdef PTHREAD_CREATE_UNDETACHED + draft7 +# endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "draft7" >/dev/null 2>&1; then : + ol_cv_pthread_version=7 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_attr_init" >/dev/null 2>&1; then : + ol_cv_pthread_version=6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +# include +#ifdef PTHREAD_MUTEX_INITIALIZER + draft5 +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "draft5" >/dev/null 2>&1; then : + ol_cv_pthread_version=5 +else + ol_cv_pthread_version=4 +fi +rm -f conftest* + +fi +rm -f conftest* + +fi +rm -f conftest* - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <&2 +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_version" >&5 +$as_echo "$ol_cv_pthread_version" >&6; } -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; + if test $ol_cv_pthread_version != 0 ; then - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac +cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREADS $ol_cv_pthread_version +_ACEOF - if test "$ld_shlibs" = no; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; + else + as_fn_error $? "unknown pthread version" "$LINENO" 5 + fi - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no + # consider threads found + ol_with_threads=found - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5 +$as_echo_n "checking for LinuxThreads pthread.h... " >&6; } +if ${ol_cv_header_linux_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then : + ol_cv_header_linux_threads=yes +else + ol_cv_header_linux_threads=no +fi +rm -f conftest* - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - archive_cmds='' - hardcode_direct=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5 +$as_echo "$ol_cv_header_linux_threads" >&6; } + if test $ol_cv_header_linux_threads = yes; then + +$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - hardcode_direct=yes - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi fi - fi - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU Pth pthread.h" >&5 +$as_echo_n "checking for GNU Pth pthread.h... " >&6; } +if ${ol_cv_header_gnu_pth_pthread_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +#ifdef _POSIX_THREAD_IS_GNU_PTH + __gnu_pth__; +#endif -int -main () -{ +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "__gnu_pth__" >/dev/null 2>&1; then : + ol_cv_header_gnu_pth_pthread_h=yes +else + ol_cv_header_gnu_pth_pthread_h=no +fi +rm -f conftest* - ; - return 0; -} + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_gnu_pth_pthread_h" >&5 +$as_echo "$ol_cv_header_gnu_pth_pthread_h" >&6; } + + + if test $ol_cv_header_gnu_pth_pthread_h = no ; then + for ac_header in sched.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sched.h" "ac_cv_header_sched_h" "$ac_includes_default" +if test "x$ac_cv_header_sched_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SCHED_H 1 _ACEOF -if ac_fn_c_try_link "$LINENO"; then : -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +done + + fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in default libraries" >&5 +$as_echo_n "checking for pthread_create in default libraries... " >&6; } +if ${ol_cv_pthread_create+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + int main () { + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi + ol_cv_pthread_create=yes +else + ol_cv_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' ${wl}-bernotok' - allow_undefined_flag=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - always_export_symbols=yes - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec=' ' - archive_cmds_need_lc=yes - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - amigaos*) - archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - # see comment about different semantics on the GNU ld section - ld_shlibs=no - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_From_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs' - fix_srcfile_path='`cygpath -w "$srcfile"`' - enable_shared_with_static_runtimes=yes - ;; - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[012]) - allow_undefined_flag='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[012]) - allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - whole_archive_flag_spec='' - link_all_deplibs=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - ld_shlibs=no - ;; - esac - fi - ;; +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + +} + +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_create=yes +else + ol_cv_pthread_create=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create" >&5 +$as_echo "$ol_cv_pthread_create" >&6; } - freebsd1*) - ld_shlibs=no - ;; + if test $ol_cv_pthread_create != no ; then + ol_link_threads=posix + ol_link_pthreads="" + fi - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; + # Pthread try link: -kthread (ol_cv_pthread_kthread) +if test "$ol_link_threads" = no ; then + # try -kthread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -kthread" >&5 +$as_echo_n "checking for pthread link with -kthread... " >&6; } +if ${ol_cv_pthread_kthread+:} false; then : + $as_echo_n "(cached) " >&6 +else - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; + # save the flags + ol_LIBS="$LIBS" + LIBS="-kthread $LIBS" - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - hpux9*) - if test "$GCC" = yes; then - archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='${wl}-E' - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*|ia64*) - archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_flag_spec_ld='+b $libdir' - hardcode_libdir_separator=: - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - ia64*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=no - hardcode_shlibpath_var=no +int +main () +{ - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - *) - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - export_dynamic_flag_spec='${wl}-E' + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_ld='-rpath $libdir' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - link_all_deplibs=yes - ;; + status = pthread_attr_init(&attr); + if( status ) return status; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - openbsd*) - hardcode_direct=yes - hardcode_shlibpath_var=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-R$libdir' - ;; - *) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - ;; - esac - fi - ;; + status = pthread_detach( &t ); + if( status ) return errno; +#endif - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; + return 0; - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_kthread=yes +else + ol_cv_pthread_kthread=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - hardcode_libdir_separator=: - ;; - sco3.2v5*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - solaris*) - no_undefined_flag=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;; - *) - whole_archive_flag_spec='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - link_all_deplibs=yes - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; +int main(argc, argv) + int argc; + char **argv; +{ - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - sysv4.2uw2*) - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=no - hardcode_shlibpath_var=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) - no_undefined_flag='${wl}-z ${wl}text' - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - sysv5*) - no_undefined_flag=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - hardcode_libdir_flag_spec= - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - ;; + status = pthread_detach( &t ); + if( status ) return errno; +#endif - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - *) - ld_shlibs=no - ;; - esac - fi + return 0; -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } -test "$ld_shlibs" = no && can_build_shared=no +} -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_kthread=yes +else + ol_cv_pthread_kthread=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext + # restore the LIBS + LIBS="$ol_LIBS" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - archive_cmds_need_lc=no - else - archive_cmds_need_lc=yes - fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc" >&5 -$as_echo "$archive_cmds_need_lc" >&6; } - ;; - esac - fi - ;; -esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_kthread" >&5 +$as_echo "$ol_cv_pthread_kthread" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + if test $ol_cv_pthread_kthread = yes ; then + ol_link_pthreads="-kthread" + ol_link_threads=posix + fi fi -need_lib_prefix=unknown -hardcode_into_libs=no -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown + # Pthread try link: -pthread (ol_cv_pthread_pthread) +if test "$ol_link_threads" = no ; then + # try -pthread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthread" >&5 +$as_echo_n "checking for pthread link with -pthread... " >&6; } +if ${ol_cv_pthread_pthread+:} false; then : + $as_echo_n "(cached) " >&6 +else -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH + # save the flags + ol_LIBS="$LIBS" + LIBS="-pthread $LIBS" - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; +int +main () +{ -bsdi[45]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes + status = pthread_attr_init(&attr); + if( status ) return status; - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_pthread=yes +else + ol_cv_pthread_pthread=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -freebsd1*) - dynamic_linker=no - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[123]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - esac - ;; +int main(argc, argv) + int argc; + char **argv; +{ -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; + status = pthread_attr_init(&attr); + if( status ) return status; -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi + status = pthread_detach( &t ); + if( status ) return errno; +#endif - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; + return 0; -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; +} -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_pthread=yes +else + ol_cv_pthread_pthread=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; + # restore the LIBS + LIBS="$ol_LIBS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthread" >&5 +$as_echo "$ol_cv_pthread_pthread" >&6; } + + if test $ol_cv_pthread_pthread = yes ; then + ol_link_pthreads="-pthread" + ol_link_threads=posix + fi +fi + + # Pthread try link: -pthreads (ol_cv_pthread_pthreads) +if test "$ol_link_threads" = no ; then + # try -pthreads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthreads" >&5 +$as_echo_n "checking for pthread link with -pthreads... " >&6; } +if ${ol_cv_pthread_pthreads+:} false; then : + $as_echo_n "(cached) " >&6 +else + + # save the flags + ol_LIBS="$LIBS" + LIBS="-pthreads $LIBS" -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; +int +main () +{ -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; + status = pthread_attr_init(&attr); + if( status ) return status; -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || \ - test -n "$runpath_var" || \ - test "X$hardcode_automatic" = "Xyes" ; then + status = pthread_detach( &t ); + if( status ) return errno; +#endif - # We can hardcode non-existant directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_pthreads=yes else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported + ol_cv_pthread_pthreads=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -if test "$hardcode_action" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + + +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + +} + +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_pthreads=yes else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + ol_cv_pthread_pthreads=no fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; + # restore the LIBS + LIBS="$ol_LIBS" - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthreads" >&5 +$as_echo "$ol_cv_pthread_pthreads" >&6; } - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; + if test $ol_cv_pthread_pthreads = yes ; then + ol_link_pthreads="-pthreads" + ol_link_threads=posix + fi +fi - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + # Pthread try link: -mthreads (ol_cv_pthread_mthreads) +if test "$ol_link_threads" = no ; then + # try -mthreads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -mthreads" >&5 +$as_echo_n "checking for pthread link with -mthreads... " >&6; } +if ${ol_cv_pthread_mthreads+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + # save the flags + ol_LIBS="$LIBS" + LIBS="-mthreads $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + +int +main () +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); #endif -char dlopen (); -int -main () -{ -return dlopen (); + + return 0; + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes + ol_cv_pthread_mthreads=yes else - ac_cv_lib_dl_dlopen=no + ol_cv_pthread_mthreads=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes -fi +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () +int main(argc, argv) + int argc; + char **argv; { -return shl_load (); - ; - return 0; + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + } + _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_mthreads=yes else - ac_cv_lib_dld_shl_load=no + ol_cv_pthread_mthreads=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + + + # restore the LIBS + LIBS="$ol_LIBS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_mthreads" >&5 +$as_echo "$ol_cv_pthread_mthreads" >&6; } + + if test $ol_cv_pthread_mthreads = yes ; then + ol_link_pthreads="-mthreads" + ol_link_threads=posix + fi +fi + + # Pthread try link: -thread (ol_cv_pthread_thread) +if test "$ol_link_threads" = no ; then + # try -thread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -thread" >&5 +$as_echo_n "checking for pthread link with -thread... " >&6; } +if ${ol_cv_pthread_thread+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + # save the flags + ol_LIBS="$LIBS" + LIBS="-thread $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include #endif -char dlopen (); +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + int main () { -return dlopen (); + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes + ol_cv_pthread_thread=yes else - ac_cv_lib_dl_dlopen=no + ol_cv_pthread_thread=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if test "${ac_cv_lib_svld_dlopen+set}" = set; then : - $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include #endif -char dlopen (); -int -main () +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; { -return dlopen (); - ; - return 0; + return (void *) (p == NULL); +} + + +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + } + _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_thread=yes else - ac_cv_lib_svld_dlopen=no + ol_cv_pthread_thread=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if test "${ac_cv_lib_dld_dld_link+set}" = set; then : + + + # restore the LIBS + LIBS="$ol_LIBS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_thread" >&5 +$as_echo "$ol_cv_pthread_thread" >&6; } + + if test $ol_cv_pthread_thread = yes ; then + ol_link_pthreads="-thread" + ol_link_threads=posix + fi +fi + + + # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r) +if test "$ol_link_threads" = no ; then + # try -lpthread -lmach -lexc -lc_r + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5 +$as_echo_n "checking for pthread link with -lpthread -lmach -lexc -lc_r... " >&6; } +if ${ol_cv_pthread_lpthread_lmach_lexc_lc_r+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread -lmach -lexc -lc_r $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include #endif -char dld_link (); +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + int main () { -return dld_link (); + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes + ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes else - ac_cv_lib_dld_dld_link=no + ol_cv_pthread_lpthread_lmach_lexc_lc_r=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" -fi +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + +int main(argc, argv) + int argc; + char **argv; +{ -fi + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -fi + status = pthread_attr_init(&attr); + if( status ) return status; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -fi + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + status = pthread_detach( &t ); + if( status ) return errno; +#endif -fi +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; -fi +} - ;; - esac +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes +else + ol_cv_pthread_lpthread_lmach_lexc_lc_r=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + # restore the LIBS + LIBS="$ol_LIBS" - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5 +$as_echo "$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6; } - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" + if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then + ol_link_pthreads="-lpthread -lmach -lexc -lc_r" + ol_link_threads=posix + fi +fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self+set}" = set; then : + # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc) +if test "$ol_link_threads" = no ; then + # try -lpthread -lmach -lexc + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc" >&5 +$as_echo_n "checking for pthread link with -lpthread -lmach -lexc... " >&6; } +if ${ol_cv_pthread_lpthread_lmach_lexc+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread -lmach -lexc $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 #endif -#include +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif +int +main () +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 #endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); #endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -#ifdef __cplusplus -extern "C" void exit (int); + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; #endif -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } + return 0; - exit (status); + ; + return 0; } -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthread_lmach_lexc=yes +else + ol_cv_pthread_lpthread_lmach_lexc=no fi -rm -fr conftest* +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self_static+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < + +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 #endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -#include +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; #else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif + status = pthread_attr_setdetachstate(&attr, detach); #endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; #endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -#ifdef __cplusplus -extern "C" void exit (int); + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; #endif -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } + return 0; - exit (status); } -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi -fi -rm -fr conftest* - +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthread_lmach_lexc=yes +else + ol_cv_pthread_lpthread_lmach_lexc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac + # restore the LIBS + LIBS="$ol_LIBS" - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5 +$as_echo "$ol_cv_pthread_lpthread_lmach_lexc" >&6; } + + if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then + ol_link_pthreads="-lpthread -lmach -lexc" + ol_link_threads=posix + fi fi -# Report which librarie types wil actually be built -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } + # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff) +if test "$ol_link_threads" = no ; then + # try -lpthread -Wl,-woff,85 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -Wl,-woff,85" >&5 +$as_echo_n "checking for pthread link with -lpthread -Wl,-woff,85... " >&6; } +if ${ol_cv_pthread_lib_lpthread_woff+:} false; then : + $as_echo_n "(cached) " >&6 +else -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } -test "$can_build_shared" = "no" && enable_shared=no + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread -Wl,-woff,85 $LIBS" -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case $host_os in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -aix4* | aix5*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } +int +main () +{ -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler \ - CC \ - LD \ - lt_prog_compiler_wl \ - lt_prog_compiler_pic \ - lt_prog_compiler_static \ - lt_prog_compiler_no_builtin_flag \ - export_dynamic_flag_spec \ - thread_safe_flag_spec \ - whole_archive_flag_spec \ - enable_shared_with_static_runtimes \ - old_archive_cmds \ - old_archive_from_new_cmds \ - predep_objects \ - postdep_objects \ - predeps \ - postdeps \ - compiler_lib_search_path \ - archive_cmds \ - archive_expsym_cmds \ - postinstall_cmds \ - postuninstall_cmds \ - old_archive_from_expsyms_cmds \ - allow_undefined_flag \ - no_undefined_flag \ - export_symbols_cmds \ - hardcode_libdir_flag_spec \ - hardcode_libdir_flag_spec_ld \ - hardcode_libdir_separator \ - hardcode_automatic \ - module_cmds \ - module_expsym_cmds \ - lt_cv_prog_compiler_c_o \ - exclude_expsyms \ - include_expsyms; do - - case $var in - old_archive_cmds | \ - old_archive_from_new_cmds | \ - archive_cmds | \ - archive_expsym_cmds | \ - module_cmds | \ - module_expsym_cmds | \ - old_archive_from_expsyms_cmds | \ - export_symbols_cmds | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -cfgfile="${ofile}T" - trap "$rm \"$cfgfile\"; exit 1" 1 2 15 - $rm -f "$cfgfile" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ofile" >&5 -$as_echo "$as_me: creating $ofile" >&6;} + status = pthread_attr_init(&attr); + if( status ) return status; - cat <<__EOF__ >> "$cfgfile" -#! $SHELL +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -# Free Software Foundation, Inc. -# -# This file is part of GNU Libtool: -# Originally by Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# A sed program that does not truncate output. -SED=$lt_SED + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="$SED -e 1s/^X//" +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + return 0; -# The names of the tagged configurations supported by this script. -available_tags= + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lib_lpthread_woff=yes +else + ol_cv_pthread_lib_lpthread_woff=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# ### BEGIN LIBTOOL CONFIG -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared -# Whether or not to build static libraries. -build_old_libs=$enable_static +int main(argc, argv) + int argc; + char **argv; +{ -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install + status = pthread_attr_init(&attr); + if( status ) return status; -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# An echo program that does not interpret backslashes. -echo=$lt_echo + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# A C compiler. -LTCC=$lt_LTCC + return 0; -# A language-specific compiler. -CC=$lt_compiler +} -# Is the compiler the GNU C compiler? -with_gcc=$GCC +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lib_lpthread_woff=yes +else + ol_cv_pthread_lib_lpthread_woff=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# An ERE matcher. -EGREP=$lt_EGREP -# The linker used to build libraries. -LD=$lt_LD + # restore the LIBS + LIBS="$ol_LIBS" -# Whether we need hard or soft links. -LN_S=$lt_LN_S +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthread_woff" >&5 +$as_echo "$ol_cv_pthread_lib_lpthread_woff" >&6; } -# A BSD-compatible nm program. -NM=$lt_NM + if test $ol_cv_pthread_lib_lpthread_woff = yes ; then + ol_link_pthreads="-lpthread -Wl,-woff,85" + ol_link_threads=posix + fi +fi -# A symbol stripping program -STRIP=$lt_STRIP -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD + # Pthread try link: -lpthread (ol_cv_pthread_lpthread) +if test "$ol_link_threads" = no ; then + # try -lpthread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread" >&5 +$as_echo_n "checking for pthread link with -lpthread... " >&6; } +if ${ol_cv_pthread_lpthread+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread $LIBS" -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Used on cygwin: assembler. -AS="$AS" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# The name of the directory that contains temporary libtool files. -objdir=$objdir +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds +int +main () +{ -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Object file suffix (normally "o"). -objext="$ac_objext" +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Old archive suffix (normally "a"). -libext="$libext" + status = pthread_attr_init(&attr); + if( status ) return status; -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Executable file suffix (normally ""). -exeext="$exeext" + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic -pic_mode=$pic_mode + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o + return 0; -# Must we lock files when doing compilation? -need_locks=$lt_need_locks + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthread=yes +else + ol_cv_pthread_lpthread=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix -# Do we need a version for libraries? -need_version=$need_version +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Whether dlopen is supported. -dlopen_support=$enable_dlopen +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static +int main(argc, argv) + int argc; + char **argv; +{ -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec + status = pthread_attr_init(&attr); + if( status ) return status; -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Library versioning type. -version_type=$version_type + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Format of library name prefix. -libname_spec=$lt_libname_spec +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec + return 0; -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +} -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthread=yes +else + ol_cv_pthread_lpthread=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds + # restore the LIBS + LIBS="$ol_LIBS" -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread" >&5 +$as_echo "$ol_cv_pthread_lpthread" >&6; } -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds + if test $ol_cv_pthread_lpthread = yes ; then + ol_link_pthreads="-lpthread" + ol_link_threads=posix + fi +fi -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib + # Pthread try link: -lc_r (ol_cv_pthread_lc_r) +if test "$ol_link_threads" = no ; then + # try -lc_r + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lc_r" >&5 +$as_echo_n "checking for pthread link with -lc_r... " >&6; } +if ${ol_cv_pthread_lc_r+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects + # save the flags + ol_LIBS="$LIBS" + LIBS="-lc_r $LIBS" -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path +int +main () +{ -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag + status = pthread_attr_init(&attr); + if( status ) return status; -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + return 0; -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lc_r=yes +else + ol_cv_pthread_lc_r=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# This is the shared library runtime path variable. -runpath_var=$runpath_var -# This is the shared library path variable. -shlibpath_var=$shlibpath_var +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs +int main(argc, argv) + int argc; + char **argv; +{ -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator + status = pthread_attr_init(&attr); + if( status ) return status; -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" + return 0; -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs +} -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lc_r=yes +else + ol_cv_pthread_lc_r=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path" + # restore the LIBS + LIBS="$ol_LIBS" -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lc_r" >&5 +$as_echo "$ol_cv_pthread_lc_r" >&6; } -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds + if test $ol_cv_pthread_lc_r = yes ; then + ol_link_pthreads="-lc_r" + ol_link_threads=posix + fi +fi -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms + # Pthread try link: -threads (ol_cv_pthread_threads) +if test "$ol_link_threads" = no ; then + # try -threads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -threads" >&5 +$as_echo_n "checking for pthread link with -threads... " >&6; } +if ${ol_cv_pthread_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms + # save the flags + ol_LIBS="$LIBS" + LIBS="-threads $LIBS" -# ### END LIBTOOL CONFIG + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -__EOF__ +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - case $host_os in - aix3*) - cat <<\EOF >> "$cfgfile" +int +main () +{ -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -EOF - ;; - esac + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - mv -f "$cfgfile" "$ofile" || \ - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" + status = pthread_attr_init(&attr); + if( status ) return status; -else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu + status = pthread_detach( &t ); + if( status ) return errno; +#endif -CC="$lt_save_CC" +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; -# Check whether --with-tags was given. -if test "${with_tags+set}" = set; then : - withval=$with_tags; tagnames="$withval" + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_threads=yes +else + ol_cv_pthread_threads=no fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -if test -f "$ltmain" && test -n "$tagnames"; then - if test ! -f "${ofile}"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not exist" >&5 -$as_echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;} - fi +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - if test -z "$LTCC"; then - eval "`$SHELL ${ofile} --config | grep '^LTCC='`" - if test -z "$LTCC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not look like a libtool script" >&5 -$as_echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} - else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 -$as_echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} - fi - fi +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - # Extract list of available tagged configurations in $ofile. - # Note that this assumes the entire list is on one line. - available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for tagname in $tagnames; do - IFS="$lt_save_ifs" - # Check whether tagname contains only valid characters - case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in - "") ;; - *) as_fn_error "invalid tag name: $tagname" "$LINENO" 5 - ;; - esac +int main(argc, argv) + int argc; + char **argv; +{ - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null - then - as_fn_error "tag name \"$tagname\" already exists" "$LINENO" 5 - fi + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - # Update the list of available tags. - if test -n "$tagname"; then - echo appending configuration tag \"$tagname\" to $ofile +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - case $tagname in - CXX) - if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - : - else - tagname="" - fi - ;; + status = pthread_attr_init(&attr); + if( status ) return status; - F77) - if test -n "$F77" && test "X$F77" != "Xno"; then - : - else - tagname="" - fi - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - GCJ) - if test -n "$GCJ" && test "X$GCJ" != "Xno"; then + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Source file extension for Java test sources. -ac_ext=java +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Object file extension for compiled Java test sources. -objext=o -objext_GCJ=$objext + return 0; -# Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}\n" +} -# Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n' +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_threads=yes +else + ol_cv_pthread_threads=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} + # restore the LIBS + LIBS="$ol_LIBS" -# Allow CC to be a program name with arguments. -compiler=$CC +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_threads" >&5 +$as_echo "$ol_cv_pthread_threads" >&6; } + if test $ol_cv_pthread_threads = yes ; then + ol_link_pthreads="-threads" + ol_link_threads=posix + fi +fi -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* + # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r) +if test "$ol_link_threads" = no ; then + # try -lpthreads -lmach -lexc -lc_r + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5 +$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc -lc_r... " >&6; } +if ${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+:} false; then : + $as_echo_n "(cached) " >&6 +else + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads -lmach -lexc -lc_r $LIBS" -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${GCJ-"gcj"} -compiler=$CC -compiler_GCJ=$CC -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# GCJ did not exist at the time GCC didn't implicitly link libc in. -archive_cmds_need_lc_GCJ=no +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -old_archive_cmds_GCJ=$old_archive_cmds +int +main () +{ + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -lt_prog_compiler_no_builtin_flag_GCJ= +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' + status = pthread_attr_init(&attr); + if( status ) return status; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13334: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:13338: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $rm conftest* + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + status = pthread_detach( &t ); + if( status ) return errno; +#endif -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions" +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes else - : + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -lt_prog_compiler_wl_GCJ= -lt_prog_compiler_pic_GCJ= -lt_prog_compiler_static_GCJ= +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - if test "$GCC" = yes; then - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_static_GCJ='-static' - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_GCJ='-Bstatic' - fi - ;; +int main(argc, argv) + int argc; + char **argv; +{ - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4' - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' - ;; + status = pthread_attr_init(&attr); + if( status ) return status; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic_GCJ='-fno-common' - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared_GCJ=no - enable_shared=no - ;; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic_GCJ=-Kconform_pic - fi - ;; + status = pthread_detach( &t ); + if( status ) return errno; +#endif - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_GCJ='-fPIC' - ;; - esac - ;; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - *) - lt_prog_compiler_pic_GCJ='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl_GCJ='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_GCJ='-Bstatic' - else - lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - lt_prog_compiler_pic_GCJ='-qnocommon' - lt_prog_compiler_wl_GCJ='-Wl,' - ;; - esac - ;; + return 0; - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' - ;; +} - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl_GCJ='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_GCJ='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive' - ;; +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes +else + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl_GCJ='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static_GCJ='-non_shared' - ;; - newsos6) - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; + # restore the LIBS + LIBS="$ol_LIBS" - linux*) - case $cc_basename in - icc* | ecc*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-fpic' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl_GCJ='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static_GCJ='-non_shared' - ;; - esac - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5 +$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6; } - osf3* | osf4* | osf5*) - lt_prog_compiler_wl_GCJ='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static_GCJ='-non_shared' - ;; + if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then + ol_link_pthreads="-lpthreads -lmach -lexc -lc_r" + ol_link_threads=posix + fi +fi - sco3.2v5*) - lt_prog_compiler_pic_GCJ='-Kpic' - lt_prog_compiler_static_GCJ='-dn' - ;; + # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc) +if test "$ol_link_threads" = no ; then + # try -lpthreads -lmach -lexc + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc" >&5 +$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc... " >&6; } +if ${ol_cv_pthread_lpthreads_lmach_lexc+:} false; then : + $as_echo_n "(cached) " >&6 +else - solaris*) - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - lt_prog_compiler_wl_GCJ='-Qoption ld ';; - *) - lt_prog_compiler_wl_GCJ='-Wl,';; - esac - ;; + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads -lmach -lexc $LIBS" - sunos4*) - lt_prog_compiler_wl_GCJ='-Qoption ld ' - lt_prog_compiler_pic_GCJ='-PIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic_GCJ='-Kconform_pic' - lt_prog_compiler_static_GCJ='-Bstatic' - fi - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - unicos*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_can_build_shared_GCJ=no - ;; +int +main () +{ - uts4*) - lt_prog_compiler_pic_GCJ='-pic' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - *) - lt_prog_compiler_can_build_shared_GCJ=no - ;; - esac - fi +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_GCJ" >&5 -$as_echo "$lt_prog_compiler_pic_GCJ" >&6; } + status = pthread_attr_init(&attr); + if( status ) return status; -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic_GCJ"; then +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... " >&6; } -if test "${lt_prog_compiler_pic_works_GCJ+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_prog_compiler_pic_works_GCJ=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic_GCJ" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13596: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:13600: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_pic_works_GCJ=yes - fi - fi - $rm conftest* + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works_GCJ" >&5 -$as_echo "$lt_prog_compiler_pic_works_GCJ" >&6; } + status = pthread_detach( &t ); + if( status ) return errno; +#endif -if test x"$lt_prog_compiler_pic_works_GCJ" = xyes; then - case $lt_prog_compiler_pic_GCJ in - "" | " "*) ;; - *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;; - esac +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc=yes else - lt_prog_compiler_pic_GCJ= - lt_prog_compiler_can_build_shared_GCJ=no + ol_cv_pthread_lpthreads_lmach_lexc=no fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic_GCJ= - ;; - *) - lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ" - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o_GCJ=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13658: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:13662: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o_GCJ=yes - fi - fi - chmod u+w . 2>&5 - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + + +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 -$as_echo "$lt_cv_prog_compiler_c_o_GCJ" >&6; } +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi +} + +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc=yes else - need_locks=no + ol_cv_pthread_lpthreads_lmach_lexc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - runpath_var= - allow_undefined_flag_GCJ= - enable_shared_with_static_runtimes_GCJ=no - archive_cmds_GCJ= - archive_expsym_cmds_GCJ= - old_archive_From_new_cmds_GCJ= - old_archive_from_expsyms_cmds_GCJ= - export_dynamic_flag_spec_GCJ= - whole_archive_flag_spec_GCJ= - thread_safe_flag_spec_GCJ= - hardcode_libdir_flag_spec_GCJ= - hardcode_libdir_flag_spec_ld_GCJ= - hardcode_libdir_separator_GCJ= - hardcode_direct_GCJ=no - hardcode_minus_L_GCJ=no - hardcode_shlibpath_var_GCJ=unsupported - link_all_deplibs_GCJ=unknown - hardcode_automatic_GCJ=no - module_cmds_GCJ= - module_expsym_cmds_GCJ= - always_export_symbols_GCJ=no - export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms_GCJ= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms_GCJ="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + # restore the LIBS + LIBS="$ol_LIBS" - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5 +$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc" >&6; } - ld_shlibs_GCJ=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' + if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then + ol_link_pthreads="-lpthreads -lmach -lexc" + ol_link_threads=posix + fi +fi - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec_GCJ='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec_GCJ= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac + # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc) +if test "$ol_link_threads" = no ; then + # try -lpthreads -lexc + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lexc" >&5 +$as_echo_n "checking for pthread link with -lpthreads -lexc... " >&6; } +if ${ol_cv_pthread_lpthreads_lexc+:} false; then : + $as_echo_n "(cached) " >&6 +else - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs_GCJ=no - cat <&2 + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads -lexc $LIBS" -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -EOF - fi - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - amigaos*) - archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - ld_shlibs_GCJ=no - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag_GCJ=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs_GCJ=no - fi - ;; +int +main () +{ - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec_GCJ='-L$libdir' - allow_undefined_flag_GCJ=unsupported - always_export_symbols_GCJ=no - enable_shared_with_static_runtimes_GCJ=yes - export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - ld_shlibs_GCJ=no - fi - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - archive_cmds_GCJ='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - if test $supports_anon_versioning = yes; then - archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - ld_shlibs_GCJ=no - fi - ;; + status = pthread_attr_init(&attr); + if( status ) return status; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - ld_shlibs_GCJ=no - cat <&2 + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. + status = pthread_detach( &t ); + if( status ) return errno; +#endif -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs_GCJ=no - fi - ;; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - sunos4*) - archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; + return 0; - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs_GCJ=no - fi - ;; - esac + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthreads_lexc=yes +else + ol_cv_pthread_lpthreads_lexc=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - if test "$ld_shlibs_GCJ" = no; then - runpath_var= - hardcode_libdir_flag_spec_GCJ= - export_dynamic_flag_spec_GCJ= - whole_archive_flag_spec_GCJ= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag_GCJ=unsupported - always_export_symbols_GCJ=yes - archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L_GCJ=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct_GCJ=unsupported - fi - ;; - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. +int main(argc, argv) + int argc; + char **argv; +{ - archive_cmds_GCJ='' - hardcode_direct_GCJ=yes - hardcode_libdir_separator_GCJ=':' - link_all_deplibs_GCJ=yes + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - hardcode_direct_GCJ=yes - else - # We have old collect2 - hardcode_direct_GCJ=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L_GCJ=yes - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_libdir_separator_GCJ= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols_GCJ=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag_GCJ='-berok' - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif -int -main () -{ +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; - ; - return 0; } + _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthreads_lexc=yes +else + ol_cv_pthread_lpthreads_lexc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + + # restore the LIBS + LIBS="$ol_LIBS" -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lexc" >&5 +$as_echo "$ol_cv_pthread_lpthreads_lexc" >&6; } - hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag_GCJ="-z nodefs" - archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test $ol_cv_pthread_lpthreads_lexc = yes ; then + ol_link_pthreads="-lpthreads -lexc" + ol_link_threads=posix + fi +fi + + + # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads) +if test "$ol_link_threads" = no ; then + # try -lpthreads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads" >&5 +$as_echo_n "checking for pthread link with -lpthreads... " >&6; } +if ${ol_cv_pthread_lib_lpthreads+:} false; then : + $as_echo_n "(cached) " >&6 +else + + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + int main () { + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi + ol_cv_pthread_lib_lpthreads=yes +else + ol_cv_pthread_lib_lpthreads=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - - hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag_GCJ=' ${wl}-bernotok' - allow_undefined_flag_GCJ=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - always_export_symbols_GCJ=yes - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec_GCJ=' ' - archive_cmds_need_lc_GCJ=yes - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - amigaos*) - archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - # see comment about different semantics on the GNU ld section - ld_shlibs_GCJ=no - ;; - - bsdi[45]*) - export_dynamic_flag_spec_GCJ=-rdynamic - ;; - - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec_GCJ=' ' - allow_undefined_flag_GCJ=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_From_new_cmds_GCJ='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds_GCJ='lib /OUT:$oldlib$oldobjs$old_deplibs' - fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`' - enable_shared_with_static_runtimes_GCJ=yes - ;; +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[012]) - allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[012]) - allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - archive_cmds_need_lc_GCJ=no - hardcode_direct_GCJ=no - hardcode_automatic_GCJ=yes - hardcode_shlibpath_var_GCJ=unsupported - whole_archive_flag_spec_GCJ='' - link_all_deplibs_GCJ=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - archive_cmds_GCJ='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - ld_shlibs_GCJ=no - ;; - esac - fi - ;; - dgux*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_shlibpath_var_GCJ=no - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - freebsd1*) - ld_shlibs_GCJ=no - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; +int main(argc, argv) + int argc; + char **argv; +{ - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - hpux9*) - if test "$GCC" = yes; then - archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=yes +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - export_dynamic_flag_spec_GCJ='${wl}-E' - ;; + status = pthread_attr_init(&attr); + if( status ) return status; - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*|ia64*) - archive_cmds_GCJ='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=no - hardcode_shlibpath_var_GCJ=no - ;; - ia64*) - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_direct_GCJ=no - hardcode_shlibpath_var_GCJ=no +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - ;; - *) - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=yes - export_dynamic_flag_spec_GCJ='${wl}-E' + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - ;; - esac - fi - ;; + status = pthread_detach( &t ); + if( status ) return errno; +#endif - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir' - fi - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - link_all_deplibs_GCJ=yes - ;; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; + return 0; - newsos6) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_shlibpath_var_GCJ=no - ;; +} - openbsd*) - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' - export_dynamic_flag_spec_GCJ='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - ;; - *) - archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' - ;; - esac - fi - ;; +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lib_lpthreads=yes +else + ol_cv_pthread_lib_lpthreads=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - os2*) - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - allow_undefined_flag_GCJ=unsupported - archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - allow_undefined_flag_GCJ=' -expect_unresolved \*' - archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - ;; + # restore the LIBS + LIBS="$ol_LIBS" - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag_GCJ=' -expect_unresolved \*' - archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthreads" >&5 +$as_echo "$ol_cv_pthread_lib_lpthreads" >&6; } - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec_GCJ='-rpath $libdir' - fi - hardcode_libdir_separator_GCJ=: - ;; + if test $ol_cv_pthread_lib_lpthreads = yes ; then + ol_link_pthreads="-lpthreads" + ol_link_threads=posix + fi +fi - sco3.2v5*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - export_dynamic_flag_spec_GCJ='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; - solaris*) - no_undefined_flag_GCJ=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_shlibpath_var_GCJ=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' ;; - *) - whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - link_all_deplibs_GCJ=yes - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&5 +$as_echo "$as_me: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&6;} - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; + if test $ol_link_threads != no ; then + LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads" - sysv4) - case $host_vendor in - sni) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds_GCJ='$CC -r -o $output$reload_objs' - hardcode_direct_GCJ=no - ;; - motorola) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var_GCJ=no - ;; + save_CPPFLAGS="$CPPFLAGS" + save_LIBS="$LIBS" + LIBS="$LTHREAD_LIBS $LIBS" - sysv4.3*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - export_dynamic_flag_spec_GCJ='-Bexport' - ;; + for ac_func in sched_yield pthread_yield thr_yield +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs_GCJ=yes - fi - ;; +fi +done - sysv4.2uw2*) - archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=no - hardcode_shlibpath_var_GCJ=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) - no_undefined_flag_GCJ='${wl}-z ${wl}text' - if test "$GCC" = yes; then - archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds_GCJ='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var_GCJ=no - ;; + if test $ac_cv_func_sched_yield = no && + test $ac_cv_func_pthread_yield = no && + test $ac_cv_func_thr_yield = no ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5 +$as_echo_n "checking for sched_yield in -lrt... " >&6; } +if ${ac_cv_lib_rt_sched_yield+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lrt $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - sysv5*) - no_undefined_flag_GCJ=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - hardcode_libdir_flag_spec_GCJ= - hardcode_shlibpath_var_GCJ=no - runpath_var='LD_RUN_PATH' - ;; +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sched_yield (); +int +main () +{ +return sched_yield (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_rt_sched_yield=yes +else + ac_cv_lib_rt_sched_yield=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5 +$as_echo "$ac_cv_lib_rt_sched_yield" >&6; } +if test "x$ac_cv_lib_rt_sched_yield" = xyes; then : + LTHREAD_LIBS="$LTHREAD_LIBS -lrt" - uts4*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_shlibpath_var_GCJ=no - ;; +$as_echo "#define HAVE_SCHED_YIELD 1" >>confdefs.h - *) - ld_shlibs_GCJ=no - ;; - esac - fi + ac_cv_func_sched_yield=yes +else + ac_cv_func_sched_yield=no +fi + + fi + if test $ac_cv_func_sched_yield = no && + test $ac_cv_func_pthread_yield = no && + test "$ac_cv_func_thr_yield" = no ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not locate sched_yield() or pthread_yield()" >&5 +$as_echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;} + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_GCJ" >&5 -$as_echo "$ld_shlibs_GCJ" >&6; } -test "$ld_shlibs_GCJ" = no && can_build_shared=no + for ac_func in pthread_kill +do : + ac_fn_c_check_func "$LINENO" "pthread_kill" "ac_cv_func_pthread_kill" +if test "x$ac_cv_func_pthread_kill" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_KILL 1 +_ACEOF -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi +done -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc_GCJ" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc_GCJ=yes - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds_GCJ in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_rwlock_destroy with " >&5 +$as_echo_n "checking for pthread_rwlock_destroy with ... " >&6; } +if ${ol_cv_func_pthread_rwlock_destroy+:} false; then : + $as_echo_n "(cached) " >&6 +else - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl_GCJ - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ - allow_undefined_flag_GCJ= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - archive_cmds_need_lc_GCJ=no - else - archive_cmds_need_lc_GCJ=yes - fi - allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc_GCJ" >&5 -$as_echo "$archive_cmds_need_lc_GCJ" >&6; } - ;; - esac - fi - ;; -esac + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi +#include +pthread_rwlock_t rwlock; + +int +main () +{ +pthread_rwlock_destroy(&rwlock); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_func_pthread_rwlock_destroy=yes else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + ol_cv_func_pthread_rwlock_destroy=no fi -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_rwlock_destroy" >&5 +$as_echo "$ol_cv_func_pthread_rwlock_destroy" >&6; } + if test $ol_cv_func_pthread_rwlock_destroy = yes ; then -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; +$as_echo "#define HAVE_PTHREAD_RWLOCK_DESTROY 1" >>confdefs.h -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; + fi -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_detach with " >&5 +$as_echo_n "checking for pthread_detach with ... " >&6; } +if ${ol_cv_func_pthread_detach+:} false; then : + $as_echo_n "(cached) " >&6 +else -bsdi[45]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no +#include +#ifndef NULL +#define NULL (void*)0 +#endif - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes +int +main () +{ +pthread_detach(NULL); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_func_pthread_detach=yes +else + ol_cv_func_pthread_detach=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_detach" >&5 +$as_echo "$ol_cv_func_pthread_detach" >&6; } - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; + if test $ol_cv_func_pthread_detach = no ; then + as_fn_error $? "could not locate pthread_detach()" "$LINENO" 5 + fi -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +$as_echo "#define HAVE_PTHREAD_DETACH 1" >>confdefs.h -freebsd1*) - dynamic_linker=no - ;; -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; + for ac_func in \ + pthread_setconcurrency \ + pthread_getconcurrency \ + thr_setconcurrency \ + thr_getconcurrency \ -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[123]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - esac - ;; +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; +fi +done -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; + for ac_func in pthread_kill_other_threads_np +do : + ac_fn_c_check_func "$LINENO" "pthread_kill_other_threads_np" "ac_cv_func_pthread_kill_other_threads_np" +if test "x$ac_cv_func_pthread_kill_other_threads_np" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_KILL_OTHER_THREADS_NP 1 +_ACEOF -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes +fi +done - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads implementation" >&5 +$as_echo_n "checking for LinuxThreads implementation... " >&6; } +if ${ol_cv_sys_linux_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else + ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_sys_linux_threads" >&5 +$as_echo "$ol_cv_sys_linux_threads" >&6; } - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads consistency" >&5 +$as_echo_n "checking for LinuxThreads consistency... " >&6; } +if ${ol_cv_linux_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; + if test $ol_cv_header_linux_threads = yes && + test $ol_cv_sys_linux_threads = yes; then + ol_cv_linux_threads=yes + elif test $ol_cv_header_linux_threads = no && + test $ol_cv_sys_linux_threads = no; then + ol_cv_linux_threads=no + else + ol_cv_linux_threads=error + fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_linux_threads" >&5 +$as_echo "$ol_cv_linux_threads" >&6; } + + + if test $ol_cv_linux_threads = error; then + as_fn_error $? "LinuxThreads header/library mismatch" "$LINENO" 5; + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pthread_create() works" >&5 +$as_echo_n "checking if pthread_create() works... " >&6; } +if ${ol_cv_pthread_create_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + ol_cv_pthread_create_works=yes +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; +int main(argc, argv) + int argc; + char **argv; +{ -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; + status = pthread_attr_init(&attr); + if( status ) return status; -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action_GCJ= -if test -n "$hardcode_libdir_flag_spec_GCJ" || \ - test -n "$runpath_var_GCJ" || \ - test "X$hardcode_automatic_GCJ" = "Xyes" ; then + status = pthread_detach( &t ); + if( status ) return errno; +#endif - # We can hardcode non-existant directories. - if test "$hardcode_direct_GCJ" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no && - test "$hardcode_minus_L_GCJ" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action_GCJ=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action_GCJ=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action_GCJ=unsupported -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_GCJ" >&5 -$as_echo "$hardcode_action_GCJ" >&6; } +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -if test "$hardcode_action_GCJ" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi + return 0; -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +} + +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_create_works=yes else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + ol_cv_pthread_create_works=no fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create_works" >&5 +$as_echo "$ol_cv_pthread_create_works" >&6; } - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; + if test $ol_cv_pthread_create_works = no ; then + as_fn_error $? "pthread_create is not usable, check environment settings" "$LINENO" 5 + fi - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; + ol_replace_broken_yield=no - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; + if test $ol_replace_broken_yield = yes ; then - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : +$as_echo "#define REPLACE_BROKEN_YIELD 1" >>confdefs.h + + fi + + if test x$ol_with_yielding_select = xauto ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if select yields when using pthreads" >&5 +$as_echo_n "checking if select yields when using pthreads... " >&6; } +if ${ol_cv_pthread_select_yields+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + if test "$cross_compiling" = yes; then : + ol_cv_pthread_select_yields=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +#include +#include +#include +#include +#ifndef NULL +#define NULL (void*) 0 #endif -char dlopen (); -int -main () + +static int fildes[2]; + +static void *task(p) + void *p; { -return dlopen (); - ; - return 0; + int i; + struct timeval tv; + + fd_set rfds; + + tv.tv_sec=10; + tv.tv_usec=0; + + FD_ZERO(&rfds); + FD_SET(fildes[0], &rfds); + + /* we're not interested in any fds */ + i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv); + + if(i < 0) { + perror("select"); + exit(10); + } + + exit(0); /* if we exit here, the select blocked the whole process */ +} + +int main(argc, argv) + int argc; + char **argv; +{ + pthread_t t; + + /* create a pipe to select */ + if(pipe(&fildes[0])) { + perror("select"); + exit(1); + } + +#ifdef HAVE_PTHREAD_SETCONCURRENCY + (void) pthread_setconcurrency(2); +#else +#ifdef HAVE_THR_SETCONCURRENCY + /* Set Solaris LWP concurrency to 2 */ + thr_setconcurrency(2); +#endif +#endif + +#if HAVE_PTHREADS < 6 + pthread_create(&t, pthread_attr_default, task, NULL); +#else + pthread_create(&t, NULL, task, NULL); +#endif + + /* make sure task runs first */ +#ifdef HAVE_THR_YIELD + thr_yield(); +#elif defined( HAVE_SCHED_YIELD ) + sched_yield(); +#elif defined( HAVE_PTHREAD_YIELD ) + pthread_yield(); +#endif + + exit(2); } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_select_yields=no else - ac_cv_lib_dl_dlopen=no + ol_cv_pthread_select_yields=yes fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_select_yields" >&5 +$as_echo "$ol_cv_pthread_select_yields" >&6; } + + if test $ol_cv_pthread_select_yields = cross ; then + as_fn_error $? "crossing compiling: use --with-yielding-select=yes|no|manual" "$LINENO" 5 + fi + + if test $ol_cv_pthread_select_yields = yes ; then + ol_with_yielding_select=yes + fi + fi + + CPPFLAGS="$save_CPPFLAGS" + LIBS="$save_LIBS" + else + as_fn_error $? "could not locate usable POSIX Threads" "$LINENO" 5 + fi + fi + + if test $ol_with_threads = posix ; then + as_fn_error $? "could not locate POSIX Threads" "$LINENO" 5 + fi + ;; +esac + +case $ol_with_threads in auto | yes | mach) + + for ac_header in mach/cthreads.h cthreads.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + if test $ac_cv_header_mach_cthreads_h = yes ; then + ol_with_threads=found + ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork" +if test "x$ac_cv_func_cthread_fork" = xyes; then : + ol_link_threads=yes fi - ;; - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then : + if test $ol_link_threads = no ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cthread_fork with -all_load" >&5 +$as_echo_n "checking for cthread_fork with -all_load... " >&6; } +if ${ol_cv_cthread_all_load+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); + save_LIBS="$LIBS" + LIBS="-all_load $LIBS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include int main () { -return shl_load (); + + cthread_fork((void *)0, (void *)0); + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes + ol_cv_cthread_all_load=yes else - ac_cv_lib_dld_shl_load=no + ol_cv_cthread_all_load=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + LIBS="$save_LIBS" + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_cthread_all_load" >&5 +$as_echo "$ol_cv_cthread_all_load" >&6; } + + if test $ol_cv_cthread_all_load = yes ; then + LTHREAD_LIBS="$LTHREAD_LIBS -all_load" + ol_link_threads=mach + ol_with_threads=found + fi + fi + + elif test $ac_cv_header_cthreads_h = yes ; then + + ol_with_threads=found + + save_LIBS="$LIBS" + LIBS="$LIBS -lthreads" + ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork" +if test "x$ac_cv_func_cthread_fork" = xyes; then : + ol_link_threads=yes +fi + + LIBS="$save_LIBS" + + if test $ol_link_threads = yes ; then + LTHREAD_LIBS="-lthreads" + ol_link_threads=mach + ol_with_threads=found + else + as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5 + fi + + elif test $ol_with_threads = mach ; then + as_fn_error $? "could not locate Mach CThreads" "$LINENO" 5 + fi + + if test $ol_link_threads = mach ; then + +$as_echo "#define HAVE_MACH_CTHREADS 1" >>confdefs.h + + elif test $ol_with_threads = found ; then + as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5 + fi + ;; +esac + +case $ol_with_threads in auto | yes | pth) + + for ac_header in pth.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "pth.h" "ac_cv_header_pth_h" "$ac_includes_default" +if test "x$ac_cv_header_pth_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTH_H 1 +_ACEOF + +fi + +done + + + if test $ac_cv_header_pth_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pth_version in -lpth" >&5 +$as_echo_n "checking for pth_version in -lpth... " >&6; } +if ${ac_cv_lib_pth_pth_version+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" +LIBS="-lpth $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -15379,36 +27016,73 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char dlopen (); +char pth_version (); int main () { -return dlopen (); +return pth_version (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes + ac_cv_lib_pth_pth_version=yes else - ac_cv_lib_dl_dlopen=no + ac_cv_lib_pth_pth_version=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pth_pth_version" >&5 +$as_echo "$ac_cv_lib_pth_pth_version" >&6; } +if test "x$ac_cv_lib_pth_pth_version" = xyes; then : + have_pth=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if test "${ac_cv_lib_svld_dlopen+set}" = set; then : + have_pth=no +fi + + + if test $have_pth = yes ; then + +$as_echo "#define HAVE_GNU_PTH 1" >>confdefs.h + + LTHREAD_LIBS="$LTHREAD_LIBS -lpth" + ol_link_threads=pth + ol_with_threads=found + + if test x$ol_with_yielding_select = xauto ; then + ol_with_yielding_select=yes + fi + fi + fi + ;; +esac + +case $ol_with_threads in auto | yes | lwp) + + for ac_header in thread.h synch.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + if test $ac_cv_header_thread_h = yes && + test $ac_cv_header_synch_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 +$as_echo_n "checking for thr_create in -lthread... " >&6; } +if ${ac_cv_lib_thread_thr_create+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" +LIBS="-lthread $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -15418,36 +27092,82 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char dlopen (); +char thr_create (); int main () { -return dlopen (); +return thr_create (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes + ac_cv_lib_thread_thr_create=yes else - ac_cv_lib_svld_dlopen=no + ac_cv_lib_thread_thr_create=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 +$as_echo "$ac_cv_lib_thread_thr_create" >&6; } +if test "x$ac_cv_lib_thread_thr_create" = xyes; then : + have_thr=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if test "${ac_cv_lib_dld_dld_link+set}" = set; then : + have_thr=no +fi + + + if test $have_thr = yes ; then + +$as_echo "#define HAVE_THR 1" >>confdefs.h + + LTHREAD_LIBS="$LTHREAD_LIBS -lthread" + ol_link_threads=thr + + if test x$ol_with_yielding_select = xauto ; then + ol_with_yielding_select=yes + fi + + for ac_func in \ + thr_setconcurrency \ + thr_getconcurrency \ + +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + fi + fi + + for ac_header in lwp/lwp.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default" +if test "x$ac_cv_header_lwp_lwp_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LWP_LWP_H 1 +_ACEOF + +fi + +done + + if test $ac_cv_header_lwp_lwp_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwp_create in -llwp" >&5 +$as_echo_n "checking for lwp_create in -llwp... " >&6; } +if ${ac_cv_lib_lwp_lwp_create+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" +LIBS="-llwp $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -15457,1299 +27177,1365 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char dld_link (); +char lwp_create (); int main () { -return dld_link (); +return lwp_create (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes + ac_cv_lib_lwp_lwp_create=yes else - ac_cv_lib_dld_dld_link=no + ac_cv_lib_lwp_lwp_create=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" -fi - - -fi - - -fi - - -fi - - -fi - - -fi - - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lwp_lwp_create" >&5 +$as_echo "$ac_cv_lib_lwp_lwp_create" >&6; } +if test "x$ac_cv_lib_lwp_lwp_create" = xyes; then : + have_lwp=yes else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -#ifdef __cplusplus -extern "C" void exit (int); -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - - exit (status); -} -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi + have_lwp=no fi -rm -fr conftest* + if test $have_lwp = yes ; then + +$as_echo "#define HAVE_LWP 1" >>confdefs.h + + LTHREAD_LIBS="$LTHREAD_LIBS -llwp" + ol_link_threads=lwp + + if test x$ol_with_yielding_select = xauto ; then + ol_with_yielding_select=no + fi + fi + fi + ;; +esac + +if test $ol_with_yielding_select = yes ; then + +$as_echo "#define HAVE_YIELDING_SELECT 1" >>confdefs.h + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self_static+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: thread defines and link options must be set manually" >&5 +$as_echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;} -#include + for ac_header in pthread.h sched.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif +fi -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif +done -#ifdef __cplusplus -extern "C" void exit (int); -#endif + for ac_func in sched_yield pthread_yield +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +fi +done - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - exit (status); -} -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5 +$as_echo_n "checking for LinuxThreads pthread.h... " >&6; } +if ${ol_cv_header_linux_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then : + ol_cv_header_linux_threads=yes +else + ol_cv_header_linux_threads=no fi -rm -fr conftest* +rm -f conftest* fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5 +$as_echo "$ol_cv_header_linux_threads" >&6; } + if test $ol_cv_header_linux_threads = yes; then - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac +$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac + fi + + + for ac_header in mach/cthreads.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default" +if test "x$ac_cv_header_mach_cthreads_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MACH_CTHREADS_H 1 +_ACEOF - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac fi +done -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler_GCJ \ - CC_GCJ \ - LD_GCJ \ - lt_prog_compiler_wl_GCJ \ - lt_prog_compiler_pic_GCJ \ - lt_prog_compiler_static_GCJ \ - lt_prog_compiler_no_builtin_flag_GCJ \ - export_dynamic_flag_spec_GCJ \ - thread_safe_flag_spec_GCJ \ - whole_archive_flag_spec_GCJ \ - enable_shared_with_static_runtimes_GCJ \ - old_archive_cmds_GCJ \ - old_archive_from_new_cmds_GCJ \ - predep_objects_GCJ \ - postdep_objects_GCJ \ - predeps_GCJ \ - postdeps_GCJ \ - compiler_lib_search_path_GCJ \ - archive_cmds_GCJ \ - archive_expsym_cmds_GCJ \ - postinstall_cmds_GCJ \ - postuninstall_cmds_GCJ \ - old_archive_from_expsyms_cmds_GCJ \ - allow_undefined_flag_GCJ \ - no_undefined_flag_GCJ \ - export_symbols_cmds_GCJ \ - hardcode_libdir_flag_spec_GCJ \ - hardcode_libdir_flag_spec_ld_GCJ \ - hardcode_libdir_separator_GCJ \ - hardcode_automatic_GCJ \ - module_cmds_GCJ \ - module_expsym_cmds_GCJ \ - lt_cv_prog_compiler_c_o_GCJ \ - exclude_expsyms_GCJ \ - include_expsyms_GCJ; do - - case $var in - old_archive_cmds_GCJ | \ - old_archive_from_new_cmds_GCJ | \ - archive_cmds_GCJ | \ - archive_expsym_cmds_GCJ | \ - module_cmds_GCJ | \ - module_expsym_cmds_GCJ | \ - old_archive_from_expsyms_cmds_GCJ | \ - export_symbols_cmds_GCJ | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done + for ac_header in lwp/lwp.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default" +if test "x$ac_cv_header_lwp_lwp_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LWP_LWP_H 1 +_ACEOF - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac +fi -cfgfile="$ofile" +done - cat <<__EOF__ >> "$cfgfile" -# ### BEGIN LIBTOOL TAG CONFIG: $tagname + for ac_header in thread.h synch.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +fi -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL +done -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared +fi -# Whether or not to build static libraries. -build_old_libs=$enable_static +if test $ol_link_threads != no && test $ol_link_threads != nt ; then -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_GCJ +$as_echo "#define REENTRANT 1" >>confdefs.h -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install +$as_echo "#define _REENTRANT 1" >>confdefs.h -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os +$as_echo "#define THREAD_SAFE 1" >>confdefs.h -# An echo program that does not interpret backslashes. -echo=$lt_echo -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS +$as_echo "#define _THREAD_SAFE 1" >>confdefs.h -# A C compiler. -LTCC=$lt_LTCC -# A language-specific compiler. -CC=$lt_compiler_GCJ +$as_echo "#define THREADSAFE 1" >>confdefs.h -# Is the compiler the GNU C compiler? -with_gcc=$GCC_GCJ -# An ERE matcher. -EGREP=$lt_EGREP +$as_echo "#define _THREADSAFE 1" >>confdefs.h -# The linker used to build libraries. -LD=$lt_LD_GCJ -# Whether we need hard or soft links. -LN_S=$lt_LN_S +$as_echo "#define _SGI_MP_SOURCE 1" >>confdefs.h -# A BSD-compatible nm program. -NM=$lt_NM -# A symbol stripping program -STRIP=$lt_STRIP + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific errno" >&5 +$as_echo_n "checking for thread specific errno... " >&6; } +if ${ol_cv_errno_thread_specific+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +errno = 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_errno_thread_specific=yes +else + ol_cv_errno_thread_specific=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_errno_thread_specific" >&5 +$as_echo "$ol_cv_errno_thread_specific" >&6; } -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific h_errno" >&5 +$as_echo_n "checking for thread specific h_errno... " >&6; } +if ${ol_cv_h_errno_thread_specific+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Used on cygwin: assembler. -AS="$AS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +h_errno = 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_h_errno_thread_specific=yes +else + ol_cv_h_errno_thread_specific=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext -# The name of the directory that contains temporary libtool files. -objdir=$objdir +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_h_errno_thread_specific" >&5 +$as_echo "$ol_cv_h_errno_thread_specific" >&6; } -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds + if test $ol_cv_errno_thread_specific != yes || + test $ol_cv_h_errno_thread_specific != yes ; then + LIBS="$LTHREAD_LIBS $LIBS" + LTHREAD_LIBS="" + fi -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_GCJ +fi -# Object file suffix (normally "o"). -objext="$ac_objext" +if test $ol_link_threads = no ; then + if test $ol_with_threads = yes ; then + as_fn_error $? "no suitable thread support" "$LINENO" 5 + fi -# Old archive suffix (normally "a"). -libext="$libext" + if test $ol_with_threads = auto ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no suitable thread support, disabling threads" >&5 +$as_echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;} + ol_with_threads=no + fi -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' -# Executable file suffix (normally ""). -exeext="$exeext" +$as_echo "#define NO_THREADS 1" >>confdefs.h -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_GCJ -pic_mode=$pic_mode + LTHREAD_LIBS="" + BUILD_THREAD=no +else + BUILD_THREAD=yes +fi -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len +if test $ol_link_threads != no ; then -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ +$as_echo "#define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1" >>confdefs.h -# Must we lock files when doing compilation? -need_locks=$lt_need_locks +fi + +# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND: +case "$ol_with_threads" in + no) + ol_pthread_ok=no + + ;; + *) + ol_found_pthreads=yes + ;; +esac + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix -# Do we need a version for libraries? -need_version=$need_version -# Whether dlopen is supported. -dlopen_support=$enable_dlopen -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_GCJ + case "$ol_found_pthreads" in + yes) + saved_LIBS="$LIBS" + LIBS="$LTHREAD_LIBS $LIBS" + saved_CFLAGS="$CFLAGS" + CFLAGS="$PTHREAD_CFLAGS $CFLAGS" + for ac_func in sem_timedwait +do : + ac_fn_c_check_func "$LINENO" "sem_timedwait" "ac_cv_func_sem_timedwait" +if test "x$ac_cv_func_sem_timedwait" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SEM_TIMEDWAIT 1 +_ACEOF -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ +fi +done -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ + LIBS="$saved_LIBS" + { saved_LIBS=; unset saved_LIBS;} + CFLAGS="$saved_CFLAGS" + { saved_CFLAGS=; unset saved_CFLAGS;} + case "$ac_cv_func_sem_timedwait" in + yes) + PTHREAD_LIBS="$LTHREAD_LIBS" + have_pthreads=yes + esac + esac +esac -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ +case "$have_pthreads" in + yes) + CFLAGS_NTP="$CFLAGS_NTP $PTHREAD_CFLAGS" + saved_LIBS="$LIBS" + LIBS="$LTHREAD_LIBS $LIBS" + saved_CFLAGS="$CFLAGS" + CFLAGS="$PTHREAD_CFLAGS $CFLAGS" + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 +$as_echo_n "checking size of pthread_t... " >&6; } +if ${ac_cv_sizeof_pthread_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t" " + $ac_includes_default + #include -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ -# Library versioning type. -version_type=$version_type +"; then : -# Format of library name prefix. -libname_spec=$lt_libname_spec +else + if test "$ac_cv_type_pthread_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (pthread_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_pthread_t=0 + fi +fi -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 +$as_echo "$ac_cv_sizeof_pthread_t" >&6; } -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds_GCJ -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ +cat >>confdefs.h <<_ACEOF +#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t +_ACEOF -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds_GCJ -archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds + LIBISC_PTHREADS_NOTHREADS=pthreads -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds_GCJ -module_expsym_cmds=$lt_module_expsym_cmds_GCJ +$as_echo "#define ISC_PLATFORM_USETHREADS 1" >>confdefs.h -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib + # + # We'd like to use sigwait() too + # + ac_fn_c_check_func "$LINENO" "sigwait" "ac_cv_func_sigwait" +if test "x$ac_cv_func_sigwait" = xyes; then : + have_sigwait=yes +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc" >&5 +$as_echo_n "checking for sigwait in -lc... " >&6; } +if ${ac_cv_lib_c_sigwait+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lc $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects_GCJ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sigwait (); +int +main () +{ +return sigwait (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_c_sigwait=yes +else + ac_cv_lib_c_sigwait=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_sigwait" >&5 +$as_echo "$ac_cv_lib_c_sigwait" >&6; } +if test "x$ac_cv_lib_c_sigwait" = xyes; then : + have_sigwait=yes +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lpthread" >&5 +$as_echo_n "checking for sigwait in -lpthread... " >&6; } +if ${ac_cv_lib_pthread_sigwait+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lpthread $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects_GCJ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sigwait (); +int +main () +{ +return sigwait (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_pthread_sigwait=yes +else + ac_cv_lib_pthread_sigwait=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_sigwait" >&5 +$as_echo "$ac_cv_lib_pthread_sigwait" >&6; } +if test "x$ac_cv_lib_pthread_sigwait" = xyes; then : + have_sigwait=yes +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Psigwait in -lpthread" >&5 +$as_echo_n "checking for _Psigwait in -lpthread... " >&6; } +if ${ac_cv_lib_pthread__Psigwait+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lpthread $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps_GCJ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char _Psigwait (); +int +main () +{ +return _Psigwait (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_pthread__Psigwait=yes +else + ac_cv_lib_pthread__Psigwait=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread__Psigwait" >&5 +$as_echo "$ac_cv_lib_pthread__Psigwait" >&6; } +if test "x$ac_cv_lib_pthread__Psigwait" = xyes; then : + have_sigwait=yes +else + have_sigwait=no -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps_GCJ +fi -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method +fi -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_GCJ +fi -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_GCJ -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds +fi -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval + case "$host:$have_sigwait" in + *-freebsd*:no) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc_r" >&5 +$as_echo_n "checking for sigwait in -lc_r... " >&6; } +if ${ac_cv_lib_c_r_sigwait+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lc_r $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sigwait (); +int +main () +{ +return sigwait (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_c_r_sigwait=yes +else + ac_cv_lib_c_r_sigwait=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_sigwait" >&5 +$as_echo "$ac_cv_lib_c_r_sigwait" >&6; } +if test "x$ac_cv_lib_c_r_sigwait" = xyes; then : + have_sigwait=yes -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +fi -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + esac + case "$have_sigwait" in + yes) + ac_cv_func_sigwait=yes -# This is the shared library runtime path variable. -runpath_var=$runpath_var +$as_echo "#define HAVE_SIGWAIT 1" >>confdefs.h -# This is the shared library path variable. -shlibpath_var=$shlibpath_var + esac -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath + for ac_func in pthread_attr_getstacksize +do : + ac_fn_c_check_func "$LINENO" "pthread_attr_getstacksize" "ac_cv_func_pthread_attr_getstacksize" +if test "x$ac_cv_func_pthread_attr_getstacksize" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_ATTR_GETSTACKSIZE 1 +_ACEOF -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_GCJ +fi +done -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs + for ac_func in pthread_attr_setstacksize sysconf +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ +fi +done -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ + case "$host" in + *-freebsd5.[012]|*-freebsd5.[012].*) + ;; + *-freebsd5.[3456789]|*-freebsd5.[3456789].*|*-freebsd6.*) -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct_GCJ +$as_echo "#define NEED_PTHREAD_SCOPE_SYSTEM 1" >>confdefs.h -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L_GCJ + ;; + *-bsdi3.*|*-bsdi4.0*) -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ +$as_echo "#define NEED_PTHREAD_INIT 1" >>confdefs.h -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic_GCJ + ;; + *-linux*) -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" +$as_echo "#define HAVE_LINUXTHREADS 1" >>confdefs.h -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_GCJ + ;; + *-solaris*) + $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec + for ac_func in pthread_setconcurrency +do : + ac_fn_c_check_func "$LINENO" "pthread_setconcurrency" "ac_cv_func_pthread_setconcurrency" +if test "x$ac_cv_func_pthread_setconcurrency" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_SETCONCURRENCY 1 +_ACEOF -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +fi +done -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path_GCJ" + case "$ac_cv_func_pthread_setconcurrency" in + yes) -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols_GCJ +$as_echo "#define CALL_PTHREAD_SETCONCURRENCY 1" >>confdefs.h -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_GCJ + esac + ;; + *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds +$as_echo "#define HAVE_UNIXWARE_SIGWAIT 1" >>confdefs.h -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_GCJ + ;; + esac + hack_shutup_pthreadonceinit=no + case "$host" in + *-aix5.[123].*) + hack_shutup_pthreadonceinit=yes + ;; + *-solaris2.[89]) + hack_shutup_pthreadonceinit=yes + ;; + *-solaris2.1[0-9]) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if extra braces are needed for PTHREAD_ONCE_INIT" >&5 +$as_echo_n "checking if extra braces are needed for PTHREAD_ONCE_INIT... " >&6; } +if ${ntp_cv_braces_around_pthread_once_init+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_GCJ + #include -# ### END LIBTOOL TAG CONFIG: $tagname +int +main () +{ -__EOF__ + static pthread_once_t once_test = + PTHREAD_ONCE_INIT; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_braces_around_pthread_once_init=no else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi + ntp_cv_braces_around_pthread_once_init=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_braces_around_pthread_once_init" >&5 +$as_echo "$ntp_cv_braces_around_pthread_once_init" >&6; } + case "$ntp_cv_braces_around_pthread_once_init" in + yes) + hack_shutup_pthreadonceinit=yes + esac + ;; + esac + case "$hack_shutup_pthreadonceinit" in + yes) -CC="$lt_save_CC" +$as_echo "#define ISC_PLATFORM_BRACEPTHREADONCEINIT 1" >>confdefs.h - else - tagname="" - fi - ;; + esac + LIBS="$saved_LIBS" + { saved_LIBS=; unset saved_LIBS;} + CFLAGS="$saved_CFLAGS" + { saved_CFLAGS=; unset saved_CFLAGS;} + ;; + *) + LIBISC_PTHREADS_NOTHREADS=nothreads + ;; +esac - RC) + if test "$have_pthreads" != "no"; then + PTHREADS_TRUE= + PTHREADS_FALSE='#' +else + PTHREADS_TRUE='#' + PTHREADS_FALSE= +fi -# Source file extension for RC test sources. -ac_ext=rc -# Object file extension for compiled RC test sources. -objext=o -objext_RC=$objext -# Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n' -# Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} +case "$hw_use_rpl_vsnprintf:$hw_cv_func_vsnprintf" in + no:yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if vsnprintf expands \"%m\" to strerror(errno)" >&5 +$as_echo_n "checking if vsnprintf expands \"%m\" to strerror(errno)... " >&6; } +if ${ntp_cv_vsnprintf_percent_m+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ntp_cv_vsnprintf_percent_m=no -# Allow CC to be a program name with arguments. -compiler=$CC +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + #include + #include + #include + #include + + int call_vsnprintf( + char * dst, + size_t sz, + const char *fmt, + ... + ); + + int call_vsnprintf( + char * dst, + size_t sz, + const char *fmt, + ... + ) + { + va_list ap; + int rc; + + va_start(ap, fmt); + rc = vsnprintf(dst, sz, fmt, ap); + va_end(ap); + + return rc; + } -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* +int +main () +{ -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* + char sbuf[512]; + char pbuf[512]; + int slen; + strcpy(sbuf, strerror(ENOENT)); + errno = ENOENT; + slen = call_vsnprintf(pbuf, sizeof(pbuf), "%m", + "wrong"); + return strcmp(sbuf, pbuf); -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${RC-"windres"} -compiler=$CC -compiler_RC=$CC -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` - -lt_cv_prog_compiler_c_o_RC=yes - -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler_RC \ - CC_RC \ - LD_RC \ - lt_prog_compiler_wl_RC \ - lt_prog_compiler_pic_RC \ - lt_prog_compiler_static_RC \ - lt_prog_compiler_no_builtin_flag_RC \ - export_dynamic_flag_spec_RC \ - thread_safe_flag_spec_RC \ - whole_archive_flag_spec_RC \ - enable_shared_with_static_runtimes_RC \ - old_archive_cmds_RC \ - old_archive_from_new_cmds_RC \ - predep_objects_RC \ - postdep_objects_RC \ - predeps_RC \ - postdeps_RC \ - compiler_lib_search_path_RC \ - archive_cmds_RC \ - archive_expsym_cmds_RC \ - postinstall_cmds_RC \ - postuninstall_cmds_RC \ - old_archive_from_expsyms_cmds_RC \ - allow_undefined_flag_RC \ - no_undefined_flag_RC \ - export_symbols_cmds_RC \ - hardcode_libdir_flag_spec_RC \ - hardcode_libdir_flag_spec_ld_RC \ - hardcode_libdir_separator_RC \ - hardcode_automatic_RC \ - module_cmds_RC \ - module_expsym_cmds_RC \ - lt_cv_prog_compiler_c_o_RC \ - exclude_expsyms_RC \ - include_expsyms_RC; do - - case $var in - old_archive_cmds_RC | \ - old_archive_from_new_cmds_RC | \ - archive_cmds_RC | \ - archive_expsym_cmds_RC | \ - module_cmds_RC | \ - module_expsym_cmds_RC | \ - old_archive_from_expsyms_cmds_RC | \ - export_symbols_cmds_RC | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ntp_cv_vsnprintf_percent_m=yes +else + ntp_cv_vsnprintf_percent_m=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -cfgfile="$ofile" - cat <<__EOF__ >> "$cfgfile" -# ### BEGIN LIBTOOL TAG CONFIG: $tagname +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_vsnprintf_percent_m" >&5 +$as_echo "$ntp_cv_vsnprintf_percent_m" >&6; } + case "$ntp_cv_vsnprintf_percent_m" in + yes) -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +$as_echo "#define VSNPRINTF_PERCENT_M 1" >>confdefs.h -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL + esac +esac -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared +for ac_header in sys/clockctl.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sys/clockctl.h" "ac_cv_header_sys_clockctl_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_clockctl_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_CLOCKCTL_H 1 +_ACEOF -# Whether or not to build static libraries. -build_old_libs=$enable_static +fi -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_RC +done -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install +# Check whether --enable-clockctl was given. +if test "${enable_clockctl+set}" = set; then : + enableval=$enable_clockctl; ntp_use_dev_clockctl=$enableval +else + ntp_use_dev_clockctl=$ac_cv_header_sys_clockctl_h -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os +fi -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os -# An echo program that does not interpret backslashes. -echo=$lt_echo +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use /dev/clockctl" >&5 +$as_echo_n "checking if we should use /dev/clockctl... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_dev_clockctl" >&5 +$as_echo "$ntp_use_dev_clockctl" >&6; } -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS -# A C compiler. -LTCC=$lt_LTCC +for ac_header in sys/capability.h sys/prctl.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -# A language-specific compiler. -CC=$lt_compiler_RC +fi -# Is the compiler the GNU C compiler? -with_gcc=$GCC_RC +done -# An ERE matcher. -EGREP=$lt_EGREP -# The linker used to build libraries. -LD=$lt_LD_RC +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have linux capabilities (libcap)" >&5 +$as_echo_n "checking if we have linux capabilities (libcap)... " >&6; } -# Whether we need hard or soft links. -LN_S=$lt_LN_S +case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in + yesyes) + case "$host" in + mips-sgi-irix*) + ntp_have_linuxcaps=no + ;; + *) ntp_have_linuxcaps=yes + ;; + esac + ;; + *) + ntp_have_linuxcaps=no + ;; +esac -# A BSD-compatible nm program. -NM=$lt_NM +# Check whether --enable-linuxcaps was given. +if test "${enable_linuxcaps+set}" = set; then : + enableval=$enable_linuxcaps; ntp_have_linuxcaps=$enableval -# A symbol stripping program -STRIP=$lt_STRIP +fi -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5 +$as_echo "$ntp_have_linuxcaps" >&6; } -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" +case "$ntp_have_linuxcaps" in + yes) -# Used on cygwin: assembler. -AS="$AS" +$as_echo "#define HAVE_LINUX_CAPABILITIES 1" >>confdefs.h -# The name of the directory that contains temporary libtool files. -objdir=$objdir + LIBS="$LIBS -lcap" + ;; +esac -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_RC +for ac_header in priv.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "priv.h" "ac_cv_header_priv_h" "$ac_includes_default" +if test "x$ac_cv_header_priv_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PRIV_H 1 +_ACEOF -# Object file suffix (normally "o"). -objext="$ac_objext" +fi -# Old archive suffix (normally "a"). -libext="$libext" +done -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' -# Executable file suffix (normally ""). -exeext="$exeext" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have solaris privileges" >&5 +$as_echo_n "checking if we have solaris privileges... " >&6; } -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_RC -pic_mode=$pic_mode +case "$ac_cv_header_priv_h" in + yes) + case "$host" in + *-solaris*) + ac_fn_c_check_func "$LINENO" "setppriv" "ac_cv_func_setppriv" +if test "x$ac_cv_func_setppriv" = xyes; then : + ntp_have_solarisprivs=yes +else + ntp_have_solarisprivs=no -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len +fi -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC + ;; + esac +esac -# Must we lock files when doing compilation? -need_locks=$lt_need_locks +# Check whether --enable-solarisprivs was given. +if test "${enable_solarisprivs+set}" = set; then : + enableval=$enable_solarisprivs; ntp_have_solarisprivs=$enableval -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix +fi -# Do we need a version for libraries? -need_version=$need_version -# Whether dlopen is supported. -dlopen_support=$enable_dlopen -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self +case "$ntp_have_solarisprivs" in + yes) -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static +$as_echo "#define HAVE_SOLARIS_PRIVS 1" >>confdefs.h -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_RC +esac -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_solarisprivs" >&5 +$as_echo "$ntp_have_solarisprivs" >&6; } -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC +case "$ntp_use_dev_clockctl$ntp_have_linuxcaps$ntp_have_solarisprivs" in + *yes*) -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC +$as_echo "#define HAVE_DROPROOT 1" >>confdefs.h -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC +esac -# Library versioning type. -version_type=$version_type +case "$host" in + *-*-darwin*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_init" >&5 +$as_echo_n "checking for library containing res_9_init... " >&6; } +if ${ac_cv_search_res_9_init+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Format of library name prefix. -libname_spec=$lt_libname_spec +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char res_9_init (); +int +main () +{ +return res_9_init (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_res_9_init=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_res_9_init+:} false; then : + break +fi +done +if ${ac_cv_search_res_9_init+:} false; then : -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec +else + ac_cv_search_res_9_init=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_init" >&5 +$as_echo "$ac_cv_search_res_9_init" >&6; } +ac_res=$ac_cv_search_res_9_init +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +fi -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds_RC -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds + ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_init" >&5 +$as_echo_n "checking for library containing res_init... " >&6; } +if ${ac_cv_search_res_init+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char res_init (); +int +main () +{ +return res_init (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_res_init=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_res_init+:} false; then : + break +fi +done +if ${ac_cv_search_res_init+:} false; then : -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC +else + ac_cv_search_res_init=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_init" >&5 +$as_echo "$ac_cv_search_res_init" >&6; } +ac_res=$ac_cv_search_res_init +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds_RC -archive_expsym_cmds=$lt_archive_expsym_cmds_RC -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds +fi -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds_RC -module_expsym_cmds=$lt_module_expsym_cmds_RC + ;; +esac +for ac_header in sys/types.h netinet/in.h arpa/nameser.h netdb.h resolv.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_NETINET_IN_H +# include /* inet_ functions / structs */ +#endif +#ifdef HAVE_ARPA_NAMESER_H +# include /* DNS HEADER struct */ +#endif +#ifdef HAVE_NETDB_H +# include +#endif +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib +fi -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects_RC +done -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects_RC -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps_RC +#HMS: Why do we do this check so "early"? +for ac_func in res_init +do : + ac_fn_c_check_func "$LINENO" "res_init" "ac_cv_func_res_init" +if test "x$ac_cv_func_res_init" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_RES_INIT 1 +_ACEOF -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps_RC +else + for ac_func in __res_init +do : + ac_fn_c_check_func "$LINENO" "__res_init" "ac_cv_func___res_init" +if test "x$ac_cv_func___res_init" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE___RES_INIT 1 +_ACEOF -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_RC +fi +done -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method +fi +done -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_RC +# We also need -lsocket, but we have tested for that already. +ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" +if test "x$ac_cv_func_inet_ntop" = xyes; then : -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_RC +else -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds +$as_echo "#define ISC_PLATFORM_NEEDNTOP 1" >>confdefs.h -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval +fi -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe +ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton" +if test "x$ac_cv_func_inet_pton" = xyes; then : -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +else -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address +$as_echo "#define ISC_PLATFORM_NEEDPTON 1" >>confdefs.h -# This is the shared library runtime path variable. -runpath_var=$runpath_var +fi -# This is the shared library path variable. -shlibpath_var=$shlibpath_var -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = xyes; then : -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_RC +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC +fi +ac_fn_c_check_type "$LINENO" "int32" "ac_cv_type_int32" "$ac_includes_default" +if test "x$ac_cv_type_int32" = xyes; then : -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC +cat >>confdefs.h <<_ACEOF +#define HAVE_INT32 1 +_ACEOF -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct_RC +fi +ac_fn_c_check_type "$LINENO" "u_int32" "ac_cv_type_u_int32" "$ac_includes_default" +if test "x$ac_cv_type_u_int32" = xyes; then : -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L_RC +cat >>confdefs.h <<_ACEOF +#define HAVE_U_INT32 1 +_ACEOF -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_RC -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic_RC +fi -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_RC -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +case "$ac_cv_type_int32::$ac_cv_header_resolv_h" in + no::yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int32 with DNS headers included" >&5 +$as_echo_n "checking for int32 with DNS headers included... " >&6; } +if ${ntp_cv_type_int32_with_dns+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path_RC" + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif + #include -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols_RC +int +main () +{ -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_RC + size_t cb = sizeof(int32); -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_RC + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_type_int32_with_dns=yes +else + ntp_cv_type_int32_with_dns=no -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_RC +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# ### END LIBTOOL TAG CONFIG: $tagname +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_int32_with_dns" >&5 +$as_echo "$ntp_cv_type_int32_with_dns" >&6; } + case "$ntp_cv_type_int32_with_dns" in + yes) -__EOF__ +$as_echo "#define HAVE_INT32_ONLY_WITH_DNS 1" >>confdefs.h + esac +esac +case "$ac_cv_type_u_int32::$ac_cv_header_resolv_h" in + no::yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int32 with DNS headers included" >&5 +$as_echo_n "checking for u_int32 with DNS headers included... " >&6; } +if ${ntp_cv_type_u_int32_with_dns+:} false; then : + $as_echo_n "(cached) " >&6 else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi - + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif + #include -CC="$lt_save_CC" +int +main () +{ - ;; + size_t cb = sizeof(u_int32); - *) - as_fn_error "Unsupported tag name: $tagname" "$LINENO" 5 - ;; - esac - # Append the new tag name to the list of available tags. - if test -n "$tagname" ; then - available_tags="$available_tags $tagname" - fi - fi - done - IFS="$lt_save_ifs" + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_type_u_int32_with_dns=yes +else + ntp_cv_type_u_int32_with_dns=no - # Now substitute the updated list of available tags. - if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then - mv "${ofile}T" "$ofile" - chmod +x "$ofile" - else - rm -f "${ofile}T" - as_fn_error "unable to update list of available tagged configurations." "$LINENO" 5 - fi fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_u_int32_with_dns" >&5 +$as_echo "$ntp_cv_type_u_int32_with_dns" >&6; } + case "$ntp_cv_type_u_int32_with_dns" in + yes) +$as_echo "#define HAVE_U_INT32_ONLY_WITH_DNS 1" >>confdefs.h -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' + esac +esac -# Prevent multiple expansion +for ac_header in sys/timepps.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/timepps.h" "ac_cv_header_sys_timepps_h" " + #ifdef HAVE_SYS_TIME_H + # include + #endif + #ifdef HAVE_ERRNO_H + # include + #endif +" +if test "x$ac_cv_header_sys_timepps_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_TIMEPPS_H 1 +_ACEOF +fi +done +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec" >&5 +$as_echo_n "checking for struct timespec... " >&6; } +if ${ntp_cv_struct_timespec+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + #include + /* Under SunOS, timespec is in sys/timepps.h, + which needs errno.h and FRAC */ + #ifdef HAVE_ERRNO_H + # include + #endif + #ifdef HAVE_SYS_TIMEPPS_H + # define FRAC 4294967296 + # include + #endif +int +main () +{ + struct timespec n; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } -fi -if test $ac_cv_c_compiler_gnu = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 -$as_echo_n "checking whether $CC needs -traditional... " >&6; } -if test "${ac_cv_prog_gcc_traditional+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_pattern="Autoconf.*'x'" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -Autoconf TIOCGETP + ; + return 0; +} _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "$ac_pattern" >/dev/null 2>&1; then : - ac_cv_prog_gcc_traditional=yes +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_struct_timespec=yes else - ac_cv_prog_gcc_traditional=no -fi -rm -f conftest* + ntp_cv_struct_timespec=no - - if test $ac_cv_prog_gcc_traditional = no; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -Autoconf TCGETA -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "$ac_pattern" >/dev/null 2>&1; then : - ac_cv_prog_gcc_traditional=yes fi -rm -f conftest* +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 -$as_echo "$ac_cv_prog_gcc_traditional" >&6; } - if test $ac_cv_prog_gcc_traditional = yes; then - CC="$CC -traditional" - fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_timespec" >&5 +$as_echo "$ntp_cv_struct_timespec" >&6; } +case "$ntp_cv_struct_timespec" in + yes) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 -$as_echo_n "checking for working volatile... " >&6; } -if test "${ac_cv_c_volatile+set}" = set; then : +$as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ntptimeval" >&5 +$as_echo_n "checking for struct ntptimeval... " >&6; } +if ${ntp_cv_struct_ntptimeval+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + #include + #include + int main () { -volatile int x; -int * volatile y = (int *) 0; -return !x && !y; + struct ntptimeval n; + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_volatile=yes + ntp_cv_struct_ntptimeval=yes else - ac_cv_c_volatile=no + ntp_cv_struct_ntptimeval=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 -$as_echo "$ac_cv_c_volatile" >&6; } -if test $ac_cv_c_volatile = no; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_ntptimeval" >&5 +$as_echo "$ntp_cv_struct_ntptimeval" >&6; } +case "$ntp_cv_struct_ntptimeval" in + yes) -$as_echo "#define volatile /**/" >>confdefs.h +$as_echo "#define HAVE_STRUCT_NTPTIMEVAL 1" >>confdefs.h + +esac + +for ac_header in md5.h +do : + ac_fn_c_check_header_compile "$LINENO" "md5.h" "ac_cv_header_md5_h" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + + +" +if test "x$ac_cv_header_md5_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MD5_H 1 +_ACEOF fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5 -$as_echo_n "checking for library containing strerror... " >&6; } -if test "${ac_cv_search_strerror+set}" = set; then : +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing MD5Init" >&5 +$as_echo_n "checking for library containing MD5Init... " >&6; } +if ${ac_cv_search_MD5Init+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS @@ -16762,16 +28548,16 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char strerror (); +char MD5Init (); int main () { -return strerror (); +return MD5Init (); ; return 0; } _ACEOF -for ac_lib in '' cposix; do +for ac_lib in '' md5 md; do if test -z "$ac_lib"; then ac_res="none required" else @@ -16779,378 +28565,495 @@ for ac_lib in '' cposix; do LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_strerror=$ac_res + ac_cv_search_MD5Init=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext - if test "${ac_cv_search_strerror+set}" = set; then : + if ${ac_cv_search_MD5Init+:} false; then : break fi done -if test "${ac_cv_search_strerror+set}" = set; then : +if ${ac_cv_search_MD5Init+:} false; then : else - ac_cv_search_strerror=no + ac_cv_search_MD5Init=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5 -$as_echo "$ac_cv_search_strerror" >&6; } -ac_res=$ac_cv_search_strerror +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_MD5Init" >&5 +$as_echo "$ac_cv_search_MD5Init" >&6; } +ac_res=$ac_cv_search_MD5Init if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi -# Extract the first word of "sh", so it can be a program name with args. -set dummy sh; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PATH_SH+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case $PATH_SH in - [\\/]* | ?:[\\/]*) - ac_cv_path_PATH_SH="$PATH_SH" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_path_PATH_SH="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS +for ac_func in MD5Init sysconf getdtablesize sigaction sigset sigvec +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF - ;; -esac -fi -PATH_SH=$ac_cv_path_PATH_SH -if test -n "$PATH_SH"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_SH" >&5 -$as_echo "$PATH_SH" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } fi +done -# Extract the first word of "perl", so it can be a program name with args. -set dummy perl; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PATH_PERL+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGIO" >&5 +$as_echo_n "checking for SIGIO... " >&6; } +if ${ntp_cv_hdr_def_sigio+:} false; then : $as_echo_n "(cached) " >&6 else - case $PATH_PERL in - [\\/]* | ?:[\\/]*) - ac_cv_path_PATH_PERL="$PATH_PERL" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_path_PATH_PERL="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - ;; -esac -fi -PATH_PERL=$ac_cv_path_PATH_PERL -if test -n "$PATH_PERL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_PERL" >&5 -$as_echo "$PATH_PERL" >&6; } + #include + + #ifndef SIGIO + # error + #endif + +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_cv_hdr_def_sigio=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi + ntp_cv_hdr_def_sigio=no +fi +rm -f conftest.err conftest.i conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigio" >&5 +$as_echo "$ntp_cv_hdr_def_sigio" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use SIGIO" >&5 +$as_echo_n "checking if we want to use SIGIO... " >&6; } +ans=no +case "$ntp_cv_hdr_def_sigio" in + yes) + ans=yes + case "$host" in + alpha*-dec-osf4*|alpha*-dec-osf5*) + ans=no + ;; + *-convex-*) + ans=no + ;; + *-dec-*) + ans=no + ;; + *-pc-cygwin*) + ans=no + ;; + *-sni-sysv*) + ans=no + ;; + *-stratus-vos) + ans=no + ;; + *-univel-sysv*) + ans=no + ;; + *-*-irix6*) + ans=no + ;; + *-*-freebsd*) + ans=no + ;; + *-*-*linux*) + ans=no + ;; + *-*-unicosmp*) + ans=no + ;; + *-*-kfreebsd*) + ans=no + ;; + m68k-*-mint*) + ans=no + ;; + esac + ;; +esac +case "$ans" in + yes) -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#define ACAT(a,b)a ## b -ACAT(Cir,cus) +$as_echo "#define HAVE_SIGNALED_IO 1" >>confdefs.h -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Circus" >/dev/null 2>&1; then : - $as_echo "#define ULONG_CONST(a) a ## UL" >>confdefs.h +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGPOLL" >&5 +$as_echo_n "checking for SIGPOLL... " >&6; } +if ${ntp_cv_hdr_def_sigpoll+:} false; then : + $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#define RCAT(a,b)a/**/b -RCAT(Rei,ser) -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Reiser" >/dev/null 2>&1; then : - $as_echo "#define ULONG_CONST(a) a/**/L" >>confdefs.h + #include + #ifndef SIGPOLL + # error + #endif + +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_cv_hdr_def_sigpoll=yes else - as_fn_error "How do we create an unsigned long constant?" "$LINENO" 5 + ntp_cv_hdr_def_sigpoll=no + fi -rm -f conftest* +rm -f conftest.err conftest.i conftest.$ac_ext fi -rm -f conftest* - # remove for 4.2.5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigpoll" >&5 +$as_echo "$ntp_cv_hdr_def_sigpoll" >&6; } -case "$host" in - *-*-vxworks*) - ac_link="$ac_link $VX_KERNEL" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for UDP I/O" >&5 +$as_echo_n "checking if we can use SIGPOLL for UDP I/O... " >&6; } +ans=no +case "$ntp_cv_hdr_def_sigpoll" in + yes) + case "$host" in + mips-sgi-irix*) + ans=no + ;; + vax-dec-bsd) + ans=no + ;; + *-pc-cygwin*) + ans=no + ;; + *-sni-sysv*) + ans=no + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix[4-9]*) + # XXX Only verified thru AIX6 + ans=no + ;; + *-*-hpux*) + ans=no + ;; + *-*-*linux*) + ans=no + ;; + *-*-osf*) + ans=no + ;; + *-*-qnx*) + ans=no + ;; + *-*-sunos*) + ans=no + ;; + *-*-solaris*) + ans=no + ;; + *-*-ultrix*) + ans=no + ;; + *-*-unicosmp*) + ans=no + ;; + *-*-kfreebsd*) + ans=no + ;; + *) ans=yes + ;; + esac + ;; +esac +case "$ans" in + yes) + +$as_echo "#define USE_UDP_SIGPOLL 1" >>confdefs.h + +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for TTY I/O" >&5 +$as_echo_n "checking if we can use SIGPOLL for TTY I/O... " >&6; } +ans=no +case "$ntp_cv_hdr_def_sigpoll" in + yes) + case "$host" in + mips-sgi-irix*) + ans=no + ;; + vax-dec-bsd) + ans=no + ;; + *-pc-cygwin*) + ans=no + ;; + *-sni-sysv*) + ans=no + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix[4-9]*) + # XXX Only verified thru AIX6 + ans=no + ;; + *-*-hpux*) + ans=no + ;; + *-*-*linux*) + ans=no + ;; + *-*-osf*) + ans=no + ;; + *-*-sunos*) + ans=no + ;; + *-*-ultrix*) + ans=no + ;; + *-*-qnx*) + ans=no + ;; + *-*-unicosmp*) + ans=no + ;; + *-*-kfreebsd*) + ans=no + ;; + *) ans=yes + ;; + esac ;; esac +case "$ans" in + yes) +$as_echo "#define USE_TTY_SIGPOLL 1" >>confdefs.h +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -case "$host" in - *-pc-cygwin*) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ladvapi32" >&5 -$as_echo_n "checking for main in -ladvapi32... " >&6; } -if test "${ac_cv_lib_advapi32_main+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to gettimeofday()" >&5 +$as_echo_n "checking number of arguments to gettimeofday()... " >&6; } +if ${ntp_cv_func_Xettimeofday_nargs+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ladvapi32 $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + #include int main () { -return main (); + + gettimeofday(0, 0); + settimeofday(0, 0); + + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_advapi32_main=yes +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_func_Xettimeofday_nargs=2 else - ac_cv_lib_advapi32_main=no + ntp_cv_func_Xettimeofday_nargs=1 + fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_advapi32_main" >&5 -$as_echo "$ac_cv_lib_advapi32_main" >&6; } -if test "x$ac_cv_lib_advapi32_main" = x""yes; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_Xettimeofday_nargs" >&5 +$as_echo "$ntp_cv_func_Xettimeofday_nargs" >&6; } +case "$ntp_cv_func_Xettimeofday_nargs" in + 1) + +$as_echo "#define SYSV_TIMEOFDAY 1" >>confdefs.h + +esac + +for ac_func in settimeofday +do : + ac_fn_c_check_func "$LINENO" "settimeofday" "ac_cv_func_settimeofday" +if test "x$ac_cv_func_settimeofday" = xyes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_LIBADVAPI32 1 +#define HAVE_SETTIMEOFDAY 1 _ACEOF - LIBS="-ladvapi32 $LIBS" +else + + case "$host" in + *-*-mpeix*) ac_cv_func_settimeofday=yes + esac fi +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we'll use clock_settime or settimeofday or stime" >&5 +$as_echo_n "checking if we'll use clock_settime or settimeofday or stime... " >&6; } +ntp_warning='GRONK' +ans=none +case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in + yes*) + ntp_warning='' + ans='clock_settime()' + ;; + noyes*) + ntp_warning='But clock_settime() would be better (if we had it)' + ans='settimeofday()' + ;; + nonoyes) + ntp_warning='Which is the worst of the three' + ans='stime()' + ;; + *) + case "$build" in + $host) + ntp_warning='Which leaves us with nothing to use!' + esac +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } +case "$ntp_warning" in + '') + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** $ntp_warning ***" >&5 +$as_echo "$as_me: WARNING: *** $ntp_warning ***" >&2;} ;; esac -ac_fn_c_check_func "$LINENO" "gethostent" "ac_cv_func_gethostent" -if test "x$ac_cv_func_gethostent" = x""yes; then : -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostent" >&5 -$as_echo_n "checking for library containing gethostent... " >&6; } -if test "${ac_cv_search_gethostent+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +LDADD_LIBNTP="$LDADD_LIBNTP $LIBS" +LIBS=$__LIBS +{ __LIBS=; unset __LIBS;} -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char gethostent (); -int -main () -{ -return gethostent (); - ; - return 0; -} -_ACEOF -for ac_lib in '' nsl; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $libxnet -lsocket $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_gethostent=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_gethostent+set}" = set; then : - break -fi -done -if test "${ac_cv_search_gethostent+set}" = set; then : -else - ac_cv_search_gethostent=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostent" >&5 -$as_echo "$ac_cv_search_gethostent" >&6; } -ac_res=$ac_cv_search_gethostent -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for deprecated --with-arlib" >&5 +$as_echo_n "checking for deprecated --with-arlib... " >&6; } +# Check whether --with-arlib was given. +if test "${with_arlib+set}" = set; then : + withval=$with_arlib; ans=$withval +else + ans=no fi -ac_fn_c_check_func "$LINENO" "openlog" "ac_cv_func_openlog" -if test "x$ac_cv_func_openlog" = x""yes; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5 -$as_echo_n "checking for library containing openlog... " >&6; } -if test "${ac_cv_search_openlog+set}" = set; then : +case "$ans" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please do not use --with-arlib, arlib is no longer included. In the future, --with-arlib will not be recognized." >&5 +$as_echo "$as_me: WARNING: Please do not use --with-arlib, arlib is no longer included. In the future, --with-arlib will not be recognized." >&2;} + ;; +esac + +for ac_prog in gawk mawk nawk awk +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char openlog (); -int -main () -{ -return openlog (); - ; - return 0; -} -_ACEOF -for ac_lib in '' gen; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" + if test -n "$AWK"; then + ac_cv_prog_AWK="$AWK" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AWK="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_openlog=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_openlog+set}" = set; then : - break -fi done -if test "${ac_cv_search_openlog+set}" = set; then : + done +IFS=$as_save_IFS -else - ac_cv_search_openlog=no fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5 -$as_echo "$ac_cv_search_openlog" >&6; } -ac_res=$ac_cv_search_openlog -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5 -$as_echo_n "checking for library containing openlog... " >&6; } -if test "${ac_cv_search_openlog+set}" = set; then : - $as_echo_n "(cached) " >&6 +AWK=$ac_cv_prog_AWK +if test -n "$AWK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +$as_echo "$AWK" >&6; } else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char openlog (); -int -main () -{ -return openlog (); - ; - return 0; -} -_ACEOF -for ac_lib in '' syslog; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $libxnet -lsocket $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_openlog=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_openlog+set}" = set; then : - break + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi + + + test -n "$AWK" && break done -if test "${ac_cv_search_openlog+set}" = set; then : +{ ac_cv_prog_AWK=; unset ac_cv_prog_AWK;} + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +set x ${MAKE-make} +ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : + $as_echo_n "(cached) " >&6 else - ac_cv_search_openlog=no + cat >conftest.make <<\_ACEOF +SHELL = /bin/sh +all: + @echo '@@@%%%=$(MAKE)=@@@%%%' +_ACEOF +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. +case `${MAKE-make} -f conftest.make 2>/dev/null` in + *@@@%%%=?*=@@@%%%*) + eval ac_cv_prog_make_${ac_make}_set=yes;; + *) + eval ac_cv_prog_make_${ac_make}_set=no;; +esac +rm -f conftest.make fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS +if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + SET_MAKE= +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + SET_MAKE="MAKE=${MAKE-make}" fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5 -$as_echo "$ac_cv_search_openlog" >&6; } -ac_res=$ac_cv_search_openlog -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi -fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing MD5Init" >&5 -$as_echo_n "checking for library containing MD5Init... " >&6; } -if test "${ac_cv_search_MD5Init+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5 +$as_echo_n "checking for library containing strerror... " >&6; } +if ${ac_cv_search_strerror+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS @@ -17163,16 +29066,16 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char MD5Init (); +char strerror (); int main () { -return MD5Init (); +return strerror (); ; return 0; } _ACEOF -for ac_lib in '' md5 md; do +for ac_lib in '' cposix; do if test -z "$ac_lib"; then ac_res="none required" else @@ -17180,223 +29083,221 @@ for ac_lib in '' md5 md; do LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_MD5Init=$ac_res + ac_cv_search_strerror=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext - if test "${ac_cv_search_MD5Init+set}" = set; then : + if ${ac_cv_search_strerror+:} false; then : break fi done -if test "${ac_cv_search_MD5Init+set}" = set; then : +if ${ac_cv_search_strerror+:} false; then : else - ac_cv_search_MD5Init=no + ac_cv_search_strerror=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_MD5Init" >&5 -$as_echo "$ac_cv_search_MD5Init" >&6; } -ac_res=$ac_cv_search_MD5Init +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5 +$as_echo "$ac_cv_search_strerror" >&6; } +ac_res=$ac_cv_search_strerror if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi -for ac_func in MD5Init -do : - ac_fn_c_check_func "$LINENO" "MD5Init" "ac_cv_func_MD5Init" -if test "x$ac_cv_func_MD5Init" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_MD5INIT 1 -_ACEOF - -fi -done - - -# following block becomes on 4.2.5: NTP_LINEEDITLIBS -for ac_header in readline/history.h readline/readline.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi -done -case "$ac_cv_header_readline_history_h$ac_cv_header_readline_readline_h" in - *no*) ;; - *) save_LIBS=$LIBS - LIBS= - # Ralf Wildenhues: either unset ... or cache READLINE_LIBS - unset ac_cv_lib_readline_readline - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -lreadline" >&5 -$as_echo_n "checking for readline in -lreadline... " >&6; } -if test "${ac_cv_lib_readline_readline+set}" = set; then : +# Extract the first word of "perl", so it can be a program name with args. +set dummy perl; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PATH_PERL+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lreadline $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + case $PATH_PERL in + [\\/]* | ?:[\\/]*) + ac_cv_path_PATH_PERL="$PATH_PERL" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PATH_PERL="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char readline (); -int -main () -{ -return readline (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_readline_readline=yes -else - ac_cv_lib_readline_readline=no + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +PATH_PERL=$ac_cv_path_PATH_PERL +if test -n "$PATH_PERL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_PERL" >&5 +$as_echo "$PATH_PERL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_readline" >&5 -$as_echo "$ac_cv_lib_readline_readline" >&6; } -if test "x$ac_cv_lib_readline_readline" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBREADLINE 1 -_ACEOF - LIBS="-lreadline $LIBS" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: Trying again with -lcurses" >&5 -$as_echo "$as_me: Trying again with -lcurses" >&6;} - unset ac_cv_lib_readline_readline - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -lreadline" >&5 -$as_echo_n "checking for readline in -lreadline... " >&6; } -if test "${ac_cv_lib_readline_readline+set}" = set; then : +{ ac_cv_path_PATH_PERL=; unset ac_cv_path_PATH_PERL;} +# Extract the first word of "test", so it can be a program name with args. +set dummy test; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PATH_TEST+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lreadline -lcurses $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + case $PATH_TEST in + [\\/]* | ?:[\\/]*) + ac_cv_path_PATH_TEST="$PATH_TEST" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PATH_TEST="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char readline (); -int -main () -{ -return readline (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_readline_readline=yes -else - ac_cv_lib_readline_readline=no + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +PATH_TEST=$ac_cv_path_PATH_TEST +if test -n "$PATH_TEST"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_TEST" >&5 +$as_echo "$PATH_TEST" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_readline" >&5 -$as_echo "$ac_cv_lib_readline_readline" >&6; } -if test "x$ac_cv_lib_readline_readline" = x""yes; then : - LIBS="-lreadline -lcurses $LIBS" - $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h -$as_echo "#define HAVE_LIBCURSES /**/" >>confdefs.h +{ ac_cv_path_PATH_TEST=; unset ac_cv_path_PATH_TEST;} +test -z "$CONFIG_SHELL" && CONFIG_SHELL=/bin/sh + +# Check whether --with-net-snmp-config was given. +if test "${with_net_snmp_config+set}" = set; then : + withval=$with_net_snmp_config; ans=$withval else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -ledit" >&5 -$as_echo_n "checking for readline in -ledit... " >&6; } -if test "${ac_cv_lib_edit_readline+set}" = set; then : + ans=yes + +fi + +case "$ans" in + no) + ;; + yes) + ans=net-snmp-config + ;; + /*) + ;; + */*) + as_fn_error $? "--with-net-snmp-config takes either a name or an absolute path" "$LINENO" 5 + ;; + *) + ;; +esac +PROG_NET_SNMP_CONFIG=$ans +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for net-snmp-config path" >&5 +$as_echo_n "checking for net-snmp-config path... " >&6; } +case "$PROG_NET_SNMP_CONFIG" in + no) ;; + /*) + PATH_NET_SNMP_CONFIG=$PROG_NET_SNMP_CONFIG + ;; + *) + # Extract the first word of "$PROG_NET_SNMP_CONFIG", so it can be a program name with args. +set dummy $PROG_NET_SNMP_CONFIG; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PATH_NET_SNMP_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ledit -lcurses $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + case $PATH_NET_SNMP_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_PATH_NET_SNMP_CONFIG="$PATH_NET_SNMP_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PATH_NET_SNMP_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char readline (); -int -main () -{ -return readline (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_edit_readline=yes -else - ac_cv_lib_edit_readline=no + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +PATH_NET_SNMP_CONFIG=$ac_cv_path_PATH_NET_SNMP_CONFIG +if test -n "$PATH_NET_SNMP_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_NET_SNMP_CONFIG" >&5 +$as_echo "$PATH_NET_SNMP_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_readline" >&5 -$as_echo "$ac_cv_lib_edit_readline" >&6; } -if test "x$ac_cv_lib_edit_readline" = x""yes; then : - LIBS="-ledit -lcurses" -$as_echo "#define HAVE_LIBEDIT /**/" >>confdefs.h - - -$as_echo "#define HAVE_LIBCURSES /**/" >>confdefs.h - - -fi + { ac_cv_path_PATH_NET_SNMP_CONFIG=; unset ac_cv_path_PATH_NET_SNMP_CONFIG;} +;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_NET_SNMP_CONFIG" >&5 +$as_echo "$PATH_NET_SNMP_CONFIG" >&6; } -fi +case "$PATH_NET_SNMP_CONFIG" in + /*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for net-snmp version" >&5 +$as_echo_n "checking for net-snmp version... " >&6; } +if ${ntp_cv_net_snmp_version+:} false; then : + $as_echo_n "(cached) " >&6 +else + ntp_cv_net_snmp_version=`$PATH_NET_SNMP_CONFIG --version` fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_net_snmp_version" >&5 +$as_echo "$ntp_cv_net_snmp_version" >&6; } + ;; +esac - READLINE_LIBS=$LIBS - - LIBS=$save_LIBS +case "$host" in + *-*-vxworks*) + ac_link="$ac_link $VX_KERNEL" ;; esac - -case "$host" in - *-*-*linux*) ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_setscheduler in -lrt" >&5 -$as_echo_n "checking for sched_setscheduler in -lrt... " >&6; } -if test "${ac_cv_lib_rt_sched_setscheduler+set}" = set; then : +# HMS: a check for -lnsl used to be here - now being done in NTP_LIBNTP +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5 +$as_echo_n "checking for library containing openlog... " >&6; } +if ${ac_cv_search_openlog+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lrt $LIBS" + ac_func_search_save_LIBS=$LIBS cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17406,91 +29307,68 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char sched_setscheduler (); +char openlog (); int main () { -return sched_setscheduler (); +return openlog (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_rt_sched_setscheduler=yes -else - ac_cv_lib_rt_sched_setscheduler=no +for ac_lib in '' gen syslog; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_openlog=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + conftest$ac_exeext + if ${ac_cv_search_openlog+:} false; then : + break fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_setscheduler" >&5 -$as_echo "$ac_cv_lib_rt_sched_setscheduler" >&6; } -if test "x$ac_cv_lib_rt_sched_setscheduler" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBRT 1 -_ACEOF - - LIBS="-lrt $LIBS" - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_setscheduler in -lposix4" >&5 -$as_echo_n "checking for sched_setscheduler in -lposix4... " >&6; } -if test "${ac_cv_lib_posix4_sched_setscheduler+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lposix4 $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +done +if ${ac_cv_search_openlog+:} false; then : -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char sched_setscheduler (); -int -main () -{ -return sched_setscheduler (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_posix4_sched_setscheduler=yes else - ac_cv_lib_posix4_sched_setscheduler=no + ac_cv_search_openlog=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix4_sched_setscheduler" >&5 -$as_echo "$ac_cv_lib_posix4_sched_setscheduler" >&6; } -if test "x$ac_cv_lib_posix4_sched_setscheduler" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBPOSIX4 1 -_ACEOF - - LIBS="-lposix4 $LIBS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5 +$as_echo "$ac_cv_search_openlog" >&6; } +ac_res=$ac_cv_search_openlog +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi -fi +# XXX library list will be in ac_cv_search_openlog - ;; -esac +# LIBSECCOMP is off by default -- needs testing with all the features +# Please send bug reports to loganaden@gmail.com +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use libseccomp sandboxing (EXPERIMENTAL)" >&5 +$as_echo_n "checking if we want to use libseccomp sandboxing (EXPERIMENTAL)... " >&6; } +# Check whether --enable-libseccomp was given. +if test "${enable_libseccomp+set}" = set; then : + enableval=$enable_libseccomp; ntp_ok=$enableval +else + ntp_ok=no -ac_fn_c_check_func "$LINENO" "setsockopt" "ac_cv_func_setsockopt" -if test "x$ac_cv_func_setsockopt" = x""yes; then : +fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5 -$as_echo_n "checking for library containing setsockopt... " >&6; } -if test "${ac_cv_search_setsockopt+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing seccomp_init" >&5 +$as_echo_n "checking for library containing seccomp_init... " >&6; } +if ${ac_cv_search_seccomp_init+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS @@ -17503,16 +29381,16 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char setsockopt (); +char seccomp_init (); int main () { -return setsockopt (); +return seccomp_init (); ; return 0; } _ACEOF -for ac_lib in '' socket xnet; do +for ac_lib in '' seccomp; do if test -z "$ac_lib"; then ac_res="none required" else @@ -17520,149 +29398,213 @@ for ac_lib in '' socket xnet; do LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_setsockopt=$ac_res + ac_cv_search_seccomp_init=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext - if test "${ac_cv_search_setsockopt+set}" = set; then : + if ${ac_cv_search_seccomp_init+:} false; then : break fi done -if test "${ac_cv_search_setsockopt+set}" = set; then : +if ${ac_cv_search_seccomp_init+:} false; then : else - ac_cv_search_setsockopt=no + ac_cv_search_seccomp_init=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5 -$as_echo "$ac_cv_search_setsockopt" >&6; } -ac_res=$ac_cv_search_setsockopt +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_seccomp_init" >&5 +$as_echo "$ac_cv_search_seccomp_init" >&6; } +ac_res=$ac_cv_search_seccomp_init if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +$as_echo "#define LIBSECCOMP 1" >>confdefs.h + + fi + if test "$cross_compiling" = yes; then : + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot run test program while cross compiling +See \`config.log' for more details" "$LINENO" 5; } +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + #include + #include + #include + + int main(void) + { + int ret; + ret = prctl(PR_GET_SECCOMP, 0, 0, 0, 0); + if (ret < 0) { + switch (errno) { + case ENOSYS: + return 1; + case EINVAL: + return 1; + default: + return 1; + } + } + ret = + prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, NULL, 0, 0); + if (ret < 0) { + switch (errno) { + case EINVAL: + return 1; + case EFAULT: + return 0; + default: + return 1; + } + } +return 1; +} + + +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + +$as_echo "#define KERN_SECCOMP 1" >>confdefs.h + + +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi + ;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for facilitynames in syslog.h" >&5 +$as_echo_n "checking for facilitynames in syslog.h... " >&6; } +if ${ac_cv_HAVE_SYSLOG_FACILITYNAMES+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + +#define SYSLOG_NAMES #include -#include -#include -#include +#include int main () { - + void *fnames; fnames = facilitynames; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes + ac_cv_HAVE_SYSLOG_FACILITYNAMES=yes else - ac_cv_header_stdc=no + ac_cv_HAVE_SYSLOG_FACILITYNAMES=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&5 +$as_echo "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&6; } +case "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" in + yes) -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include +$as_echo "#define HAVE_SYSLOG_FACILITYNAMES 1" >>confdefs.h -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : + ;; + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No facilitynames in " >&5 +$as_echo "$as_me: WARNING: No facilitynames in " >&2;} + ;; + cross) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: facilitynames in - cross-compiling" >&5 +$as_echo "$as_me: WARNING: facilitynames in - cross-compiling" >&2;} + ;; +esac -else - ac_cv_header_stdc=no -fi -rm -f conftest* -fi -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : +case "$host" in + *-*-*linux*) ;; + *-*-osf4*) ;; + *-*-osf5*) ;; + *) + # HMS: Make sure we check for -lrt for clock_* before this... + case "$ac_cv_search_clock_gettime" in + '') as_fn_error $? "Internal Error: Haven't looked for clock_gettime() yet!" "$LINENO" 5 ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sched_setscheduler" >&5 +$as_echo_n "checking for library containing sched_setscheduler... " >&6; } +if ${ac_cv_search_sched_setscheduler+:} false; then : + $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sched_setscheduler (); int main () { - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; +return sched_setscheduler (); + ; return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no +for ac_lib in '' rt posix4; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_sched_setscheduler=$ac_res fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_sched_setscheduler+:} false; then : + break fi +done +if ${ac_cv_search_sched_setscheduler+:} false; then : +else + ac_cv_search_sched_setscheduler=no fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sched_setscheduler" >&5 +$as_echo "$ac_cv_search_sched_setscheduler" >&6; } +ac_res=$ac_cv_search_sched_setscheduler +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi + ;; +esac + for ac_header in bstring.h do : ac_fn_c_check_header_mongrel "$LINENO" "bstring.h" "ac_cv_header_bstring_h" "$ac_includes_default" -if test "x$ac_cv_header_bstring_h" = x""yes; then : +if test "x$ac_cv_header_bstring_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_BSTRING_H 1 _ACEOF @@ -17672,14 +29614,13 @@ fi done ac_fn_c_check_header_mongrel "$LINENO" "dns_sd.h" "ac_cv_header_dns_sd_h" "$ac_includes_default" -if test "x$ac_cv_header_dns_sd_h" = x""yes; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DNSServiceRegister in -ldns_sd" >&5 -$as_echo_n "checking for DNSServiceRegister in -ldns_sd... " >&6; } -if test "${ac_cv_lib_dns_sd_DNSServiceRegister+set}" = set; then : +if test "x$ac_cv_header_dns_sd_h" = xyes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing DNSServiceRegister" >&5 +$as_echo_n "checking for library containing DNSServiceRegister... " >&6; } +if ${ac_cv_search_DNSServiceRegister+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldns_sd $LIBS" + ac_func_search_save_LIBS=$LIBS cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17698,35 +29639,50 @@ return DNSServiceRegister (); return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dns_sd_DNSServiceRegister=yes -else - ac_cv_lib_dns_sd_DNSServiceRegister=no +for ac_lib in '' dns_sd; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_DNSServiceRegister=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + conftest$ac_exeext + if ${ac_cv_search_DNSServiceRegister+:} false; then : + break +fi +done +if ${ac_cv_search_DNSServiceRegister+:} false; then : + +else + ac_cv_search_DNSServiceRegister=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dns_sd_DNSServiceRegister" >&5 -$as_echo "$ac_cv_lib_dns_sd_DNSServiceRegister" >&6; } -if test "x$ac_cv_lib_dns_sd_DNSServiceRegister" = x""yes; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_DNSServiceRegister" >&5 +$as_echo "$ac_cv_search_DNSServiceRegister" >&6; } +ac_res=$ac_cv_search_DNSServiceRegister +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" $as_echo "#define HAVE_DNSREGISTRATION 1" >>confdefs.h + fi + fi -case "$ac_cv_lib_dns_sd_DNSServiceRegister" in - yes) LIBS="-ldns_sd $LIBS" ;; -esac -for ac_header in errno.h fcntl.h ieeefp.h math.h +for ac_header in fcntl.h fnmatch.h ieeefp.h inttypes.h kvm.h math.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -17736,34 +29692,11 @@ fi done -# HMS: Lame, but fast. -if test -f /etc/redhat-release -then - : -else - for ac_header in md5.h -do : - ac_fn_c_check_header_compile "$LINENO" "md5.h" "ac_cv_header_md5_h" "#if HAVE_SYS_TYPES_H -#include -#endif - -" -if test "x$ac_cv_header_md5_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_MD5_H 1 -_ACEOF - -fi - -done - -fi for ac_header in memory.h netdb.h poll.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -17772,12 +29705,11 @@ fi done -for ac_header in sched.h sgtty.h stdlib.h string.h termio.h +for ac_header in sgtty.h stdatomic.h stdlib.h string.h termio.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -17790,8 +29722,7 @@ for ac_header in termios.h timepps.h timex.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -17800,12 +29731,13 @@ fi done + case "$host" in *-*-aix*) for ac_header in utmpx.h do : ac_fn_c_check_header_mongrel "$LINENO" "utmpx.h" "ac_cv_header_utmpx_h" "$ac_includes_default" -if test "x$ac_cv_header_utmpx_h" = x""yes; then : +if test "x$ac_cv_header_utmpx_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_UTMPX_H 1 _ACEOF @@ -17815,11 +29747,13 @@ fi done case "$ac_cv_header_utmpx_h" in - yes) ;; - *) for ac_header in utmp.h + yes) + ;; + *) + for ac_header in utmp.h do : ac_fn_c_check_header_mongrel "$LINENO" "utmp.h" "ac_cv_header_utmp_h" "$ac_includes_default" -if test "x$ac_cv_header_utmp_h" = x""yes; then : +if test "x$ac_cv_header_utmp_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_UTMP_H 1 _ACEOF @@ -17827,15 +29761,16 @@ _ACEOF fi done - ;; + + ;; esac ;; - *) for ac_header in utmp.h utmpx.h + *) + for ac_header in utmp.h utmpx.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -17843,52 +29778,38 @@ _ACEOF fi done - ;; -esac -for ac_header in arpa/nameser.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "arpa/nameser.h" "ac_cv_header_arpa_nameser_h" "$ac_includes_default" -if test "x$ac_cv_header_arpa_nameser_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ARPA_NAMESER_H 1 -_ACEOF - -fi -done + ;; +esac -for ac_header in sys/socket.h +# +# On Suns only (so far) getpass() truncates the typed password to 8 +# characters, but getpassphrase() allows up to 257. Most systems' +# getpass() does not truncate, at least not so as to affect ntpq and +# ntpdc password prompts. +# +# So check for getpassphrase(), but only on Sun operating systems. +# +case "$host" in + *-*-sunos*|*-*-solaris*) + for ac_func in getpassphrase do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_socket_h" = x""yes; then : + ac_fn_c_check_func "$LINENO" "getpassphrase" "ac_cv_func_getpassphrase" +if test "x$ac_cv_func_getpassphrase" = xyes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_SOCKET_H 1 +#define HAVE_GETPASSPHRASE 1 _ACEOF fi - done -for ac_header in net/if.h -do : - ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "#if HAVE_SYS_SOCKET_H -#include -#endif - -" -if test "x$ac_cv_header_net_if_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_NET_IF_H 1 -_ACEOF - -fi +esac -done for ac_header in net/if6.h do : ac_fn_c_check_header_mongrel "$LINENO" "net/if6.h" "ac_cv_header_net_if6_h" "$ac_includes_default" -if test "x$ac_cv_header_net_if6_h" = x""yes; then : +if test "x$ac_cv_header_net_if6_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_NET_IF6_H 1 _ACEOF @@ -17900,12 +29821,12 @@ done for ac_header in net/route.h do : ac_fn_c_check_header_compile "$LINENO" "net/route.h" "ac_cv_header_net_route_h" " -#include -#include -#include + #include + #include + #include " -if test "x$ac_cv_header_net_route_h" = x""yes; then : +if test "x$ac_cv_header_net_route_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_NET_ROUTE_H 1 _ACEOF @@ -17914,133 +29835,30 @@ fi done -for ac_header in netinet/in_system.h netinet/in_systm.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - -for ac_header in netinet/in.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default" -if test "x$ac_cv_header_netinet_in_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_NETINET_IN_H 1 -_ACEOF - -fi - -done - -for ac_header in netinet/ip.h -do : - ac_fn_c_check_header_compile "$LINENO" "netinet/ip.h" "ac_cv_header_netinet_ip_h" "#if HAVE_SYS_TYPES_H -#include -#endif -#if HAVE_NETINET_IN_H -#include -#endif -#if HAVE_NETINET_IN_SYSTM_H -#include -#endif - -" -if test "x$ac_cv_header_netinet_ip_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_NETINET_IP_H 1 -_ACEOF - -fi - -done - - -# Check for IPTOS_PREC -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking IPPROTO_IP IP_TOS IPTOS_LOWDELAY" >&5 -$as_echo_n "checking IPPROTO_IP IP_TOS IPTOS_LOWDELAY... " >&6; } -if test "${ac_cv_ip_tos+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - - #if HAVE_SYS_TYPES_H - #include - #endif - #if HAVE_NETINET_IP_H - #include - #include - #endif - #if defined(IPPROTO_IP) && defined(IP_TOS) && defined(IPTOS_LOWDELAY) - yes - #endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_ip_tos=yes -else - ac_cv_ip_tos=no - -fi -rm -f conftest* - - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ip_tos" >&5 -$as_echo "$ac_cv_ip_tos" >&6; } - -case "$ac_cv_ip_tos" in - yes) - -$as_echo "#define HAVE_IPTOS_SUPPORT 1" >>confdefs.h - -esac for ac_header in netinfo/ni.h do : ac_fn_c_check_header_mongrel "$LINENO" "netinfo/ni.h" "ac_cv_header_netinfo_ni_h" "$ac_includes_default" -if test "x$ac_cv_header_netinfo_ni_h" = x""yes; then : +if test "x$ac_cv_header_netinfo_ni_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_NETINFO_NI_H 1 _ACEOF -$as_echo "#define HAVE_NETINFO 1" >>confdefs.h - fi done -for ac_header in sun/audioio.h sys/audioio.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi +case "$ac_cv_header_netinfo_ni_h" in + yes) -done +$as_echo "#define HAVE_NETINFO 1" >>confdefs.h -for ac_header in sys/clkdefs.h sys/file.h +esac +for ac_header in sun/audioio.h sys/audioio.h sys/file.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -18050,11 +29868,13 @@ fi done case "$host" in - *-*-sunos4*) ;; - *) for ac_header in sys/ioctl.h + *-*-sunos4*) + ;; + *) + for ac_header in sys/ioctl.h do : ac_fn_c_check_header_mongrel "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_ioctl_h" = x""yes; then : +if test "x$ac_cv_header_sys_ioctl_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_IOCTL_H 1 _ACEOF @@ -18065,24 +29885,11 @@ done ;; esac -for ac_header in sys/ipc.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/ipc.h" "ac_cv_header_sys_ipc_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_ipc_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_IPC_H 1 -_ACEOF - -fi - -done - -for ac_header in sys/lock.h sys/mman.h sys/modem.h sys/param.h sys/ppsclock.h +for ac_header in sys/ipc.h sys/lock.h sys/mman.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -18092,12 +29899,13 @@ fi done # HMS: Check sys/proc.h and sys/resource.h after some others -for ac_header in sys/ppstime.h +for ac_header in sys/modem.h sys/ppsclock.h sys/ppstime.h sched.h do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/ppstime.h" "ac_cv_header_sys_ppstime_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_ppstime_h" = x""yes; then : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_PPSTIME_H 1 +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi @@ -18105,32 +29913,19 @@ fi done case "$ac_cv_header_sched_h" in - yes) ;; - *) for ac_header in sys/sched.h + yes) + ;; + *) + for ac_header in sys/sched.h do : ac_fn_c_check_header_mongrel "$LINENO" "sys/sched.h" "ac_cv_header_sys_sched_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_sched_h" = x""yes; then : +if test "x$ac_cv_header_sys_sched_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_SCHED_H 1 _ACEOF fi -done - ;; -esac -case "$host" in - *-*-sco*) - for ac_header in sys/sio.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/sio.h" "ac_cv_header_sys_sio_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_sio_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_SIO_H 1 -_ACEOF - -fi - done ;; @@ -18140,8 +29935,7 @@ for ac_header in sys/select.h sys/signal.h sys/sockio.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -18152,13 +29946,14 @@ done # HMS: Checked sys/socket.h earlier case "$host" in - *-*-netbsd*) ;; - *) for ac_header in machine/soundcard.h sys/soundcard.h + *-*-netbsd*) + ;; + *) + for ac_header in machine/soundcard.h sys/soundcard.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -18169,144 +29964,39 @@ done ;; esac -for ac_header in sys/stat.h sys/stream.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - -for ac_header in sys/stropts.h sys/sysctl.h sys/syssgi.h sys/systune.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - -for ac_header in sys/termios.h sys/time.h sys/signal.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#if HAVE_SYS_TIME_H -# include -#endif -#if HAVE_ERRNO_H -# include -#endif -#include -#ifdef PPS_API_VERS_1 -yes -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - for ac_header in sys/timepps.h -do : - ac_fn_c_check_header_compile "$LINENO" "sys/timepps.h" "ac_cv_header_sys_timepps_h" "#if HAVE_SYS_TIME_H -# include -#endif -#if HAVE_ERRNO_H -# include -#endif - -" -if test "x$ac_cv_header_sys_timepps_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_TIMEPPS_H 1 -_ACEOF - -fi - -done - - -fi -rm -f conftest* - -for ac_header in sys/timers.h sys/tpro.h sys/types.h sys/wait.h +for ac_header in sys/stat.h sys/stream.h stropts.h sys/stropts.h sys/syssgi.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 -$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } -if test "${ac_cv_header_time+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include - -int -main () -{ -if ((struct tm *) 0) -return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_time=yes -else - ac_cv_header_time=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 -$as_echo "$ac_cv_header_time" >&6; } -if test $ac_cv_header_time = yes; then -$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h +done + +for ac_header in sys/systune.h sys/termios.h sys/tpro.h sys/wait.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF fi +done + case "$host" in *-convex-*) - for ac_header in /sys/sync/queue.h /sys/sync/sema.h + for ac_header in /sys/sync/queue.h /sys/sync/sema.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -18315,14 +30005,13 @@ fi done - ;; + ;; *-*-bsdi*) - for ac_header in machine/inline.h sys/pcl720.h sys/i8253.h + for ac_header in machine/inline.h sys/pcl720.h sys/i8253.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -18331,118 +30020,167 @@ fi done - ;; + ;; esac -case "$host" in - *-*-*linux*) - for ac_func in __adjtimex __ntp_gettime +case "$ac_cv_header_stdatomic_h" in + yes) + for ac_func in atomic_thread_fence do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : + ac_fn_c_check_func "$LINENO" "atomic_thread_fence" "ac_cv_func_atomic_thread_fence" +if test "x$ac_cv_func_atomic_thread_fence" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ATOMIC_THREAD_FENCE 1 _ACEOF fi done - ;; -esac -case "$ac_cv_func___adjtimex" in - yes) ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nlist in -lelf" >&5 -$as_echo_n "checking for nlist in -lelf... " >&6; } -if test "${ac_cv_lib_elf_nlist+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for atomic_thread_fence()" >&5 +$as_echo_n "checking for atomic_thread_fence()... " >&6; } +if ${ntp_cv_func_atomic_thread_fence+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lelf $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char nlist (); + #include + int main () { -return nlist (); + + atomic_thread_fence(memory_order_seq_cst); + + ; return 0; } + ntp_cv_func_atomic_thread_fence=yes _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_elf_nlist=yes -else - ac_cv_lib_elf_nlist=no +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_func_atomic_thread_fence=no + fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_nlist" >&5 -$as_echo "$ac_cv_lib_elf_nlist" >&6; } -if test "x$ac_cv_lib_elf_nlist" = x""yes; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_atomic_thread_fence" >&5 +$as_echo "$ntp_cv_func_atomic_thread_fence" >&6; } + ;; +esac + +case "$host" in + *-*-solaris2.6) + # Broken... + ;; + *) + for ac_func in ntp_adjtime ntp_gettime +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF -#define HAVE_LIBELF 1 +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF - LIBS="-lelf $LIBS" - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lkvm" >&5 -$as_echo_n "checking for main in -lkvm... " >&6; } -if test "${ac_cv_lib_kvm_main+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lkvm $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +done + ;; +esac -int -main () -{ -return main (); - ; - return 0; -} +case "$host" in + *-*-*linux*) + case "$ac_cv_func_ntp_gettime" in + yes) + ;; + *) + for ac_func in __ntp_gettime +do : + ac_fn_c_check_func "$LINENO" "__ntp_gettime" "ac_cv_func___ntp_gettime" +if test "x$ac_cv_func___ntp_gettime" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE___NTP_GETTIME 1 _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_kvm_main=yes -else - ac_cv_lib_kvm_main=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_main" >&5 -$as_echo "$ac_cv_lib_kvm_main" >&6; } -if test "x$ac_cv_lib_kvm_main" = x""yes; then : +done + + case "$ac_cv_func___ntp_gettime" in + yes) + +$as_echo "#define ntp_gettime __ntp_gettime" >>confdefs.h + + +$as_echo "#define HAVE_NTP_GETTIME 1" >>confdefs.h + + esac + ;; + esac + for ac_func in adjtimex +do : + ac_fn_c_check_func "$LINENO" "adjtimex" "ac_cv_func_adjtimex" +if test "x$ac_cv_func_adjtimex" = xyes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_LIBKVM 1 +#define HAVE_ADJTIMEX 1 _ACEOF - LIBS="-lkvm $LIBS" +fi +done + + case "$ac_cv_func_adjtimex" in + yes) + +$as_echo "#define ntp_adjtime adjtimex" >>confdefs.h + + +$as_echo "#define HAVE_NTP_ADJTIME 1" >>confdefs.h + + have_adjtimex=1 + ;; + *) + for ac_func in __adjtimex +do : + ac_fn_c_check_func "$LINENO" "__adjtimex" "ac_cv_func___adjtimex" +if test "x$ac_cv_func___adjtimex" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE___ADJTIMEX 1 +_ACEOF fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nlist in -lld" >&5 -$as_echo_n "checking for nlist in -lld... " >&6; } -if test "${ac_cv_lib_ld_nlist+set}" = set; then : +done + + case "$ac_cv_func___adjtimex" in + yes) + +$as_echo "#define ntp_adjtime __adjtimex" >>confdefs.h + + +$as_echo "#define HAVE_NTP_ADJTIME 1" >>confdefs.h + + +$as_echo "#define adjtimex __adjtimex" >>confdefs.h + + +$as_echo "#define HAVE_ADJTIMEX 1" >>confdefs.h + + have_adjtimex=1 + esac + ;; + esac +esac +case "$have_adjtimex" in + '') + # nlist stuff is only needed for tickadj. + saved_LIBS="$LIBS" + LIBS= + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing nlist" >&5 +$as_echo_n "checking for library containing nlist... " >&6; } +if ${ac_cv_search_nlist+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lld $LIBS" + ac_func_search_save_LIBS=$LIBS cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -18461,33 +30199,45 @@ return nlist (); return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_ld_nlist=yes -else - ac_cv_lib_ld_nlist=no +for ac_lib in '' elf ld mld; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_nlist=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + conftest$ac_exeext + if ${ac_cv_search_nlist+:} false; then : + break fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ld_nlist" >&5 -$as_echo "$ac_cv_lib_ld_nlist" >&6; } -if test "x$ac_cv_lib_ld_nlist" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBLD 1 -_ACEOF +done +if ${ac_cv_search_nlist+:} false; then : - LIBS="-lld $LIBS" +else + ac_cv_search_nlist=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_nlist" >&5 +$as_echo "$ac_cv_search_nlist" >&6; } +ac_res=$ac_cv_search_nlist +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nlist in -lmld" >&5 -$as_echo_n "checking for nlist in -lmld... " >&6; } -if test "${ac_cv_lib_mld_nlist+set}" = set; then : + # XXX ac_cv_search_nlist will be 'none required', 'no', or '-l...' + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing kvm_open" >&5 +$as_echo_n "checking for library containing kvm_open... " >&6; } +if ${ac_cv_search_kvm_open+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lmld $LIBS" + ac_func_search_save_LIBS=$LIBS cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -18497,88 +30247,122 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char nlist (); +char kvm_open (); int main () { -return nlist (); +return kvm_open (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_mld_nlist=yes -else - ac_cv_lib_mld_nlist=no +for ac_lib in '' kvm; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_kvm_open=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + conftest$ac_exeext + if ${ac_cv_search_kvm_open+:} false; then : + break +fi +done +if ${ac_cv_search_kvm_open+:} false; then : + +else + ac_cv_search_kvm_open=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mld_nlist" >&5 -$as_echo "$ac_cv_lib_mld_nlist" >&6; } -if test "x$ac_cv_lib_mld_nlist" = x""yes; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_kvm_open" >&5 +$as_echo "$ac_cv_search_kvm_open" >&6; } +ac_res=$ac_cv_search_kvm_open +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + # XXX ac_cv_search_kvm_open will be 'none required', 'no', or '-l...' + for ac_header in nlist.h sys/var.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF -#define HAVE_LIBMLD 1 +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF - LIBS="-lmld $LIBS" - fi - ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default" -if test "x$ac_cv_header_nlist_h" = x""yes; then : +done + + case "$ac_cv_header_nlist_h" in + yes) $as_echo "#define NLIST_STRUCT 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for n_un in struct nlist" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for n_un in struct nlist" >&5 $as_echo_n "checking for n_un in struct nlist... " >&6; } -if test "${ac_cv_struct_nlist_n_un+set}" = set; then : +if ${ntp_cv_struct_nlist_n_un+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + + #include + int main () { -struct nlist n; n.n_un.n_name = 0; + + struct nlist n; + n.n_un.n_name = 0; + + ; return 0; } + ntp_cv_struct_nlist_n_un=yes _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_nlist_n_un=yes -else - ac_cv_struct_nlist_n_un=no + ntp_cv_struct_nlist_n_un=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_nlist_n_un" >&5 -$as_echo "$ac_cv_struct_nlist_n_un" >&6; } - if test $ac_cv_struct_nlist_n_un = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_nlist_n_un" >&5 +$as_echo "$ntp_cv_struct_nlist_n_un" >&6; } + case "$ntp_cv_struct_nlist_n_un" in + yes) $as_echo "#define NLIST_NAME_UNION 1" >>confdefs.h - fi - -fi + esac + esac - ;; + LDADD_NLIST="$LIBS" + LIBS="$saved_LIBS" + { saved_LIBS=; unset saved_LIBS;} esac - for ac_header in sys/proc.h do : - ac_fn_c_check_header_compile "$LINENO" "sys/proc.h" "ac_cv_header_sys_proc_h" "#if HAVE_SYS_TYPES_H -# include -#endif -#if HAVE_SYS_TIME_H -# include -#endif + ac_fn_c_check_header_compile "$LINENO" "sys/proc.h" "ac_cv_header_sys_proc_h" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_TIME_H + # include + #endif " -if test "x$ac_cv_header_sys_proc_h" = x""yes; then : +if test "x$ac_cv_header_sys_proc_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_PROC_H 1 _ACEOF @@ -18590,12 +30374,13 @@ done for ac_header in sys/resource.h do : - ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" "#if HAVE_SYS_TIME_H -# include -#endif + ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" " + #ifdef HAVE_SYS_TIME_H + # include + #endif " -if test "x$ac_cv_header_sys_resource_h" = x""yes; then : +if test "x$ac_cv_header_sys_resource_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_RESOURCE_H 1 _ACEOF @@ -18607,15 +30392,16 @@ done for ac_header in sys/shm.h do : - ac_fn_c_check_header_compile "$LINENO" "sys/shm.h" "ac_cv_header_sys_shm_h" "#if HAVE_SYS_TYPES_H -# include -#endif -#if HAVE_SYS_IPC_H -# include -#endif + ac_fn_c_check_header_compile "$LINENO" "sys/shm.h" "ac_cv_header_sys_shm_h" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_IPC_H + # include + #endif " -if test "x$ac_cv_header_sys_shm_h" = x""yes; then : +if test "x$ac_cv_header_sys_shm_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_SHM_H 1 _ACEOF @@ -18627,8592 +30413,9587 @@ done for ac_header in sys/timex.h do : - ac_fn_c_check_header_compile "$LINENO" "sys/timex.h" "ac_cv_header_sys_timex_h" "#if HAVE_SYS_TIME_H -# include -#endif + ac_fn_c_check_header_compile "$LINENO" "sys/timex.h" "ac_cv_header_sys_timex_h" " + #ifdef HAVE_SYS_TIME_H + # include + #endif + +" +if test "x$ac_cv_header_sys_timex_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_TIMEX_H 1 +_ACEOF + +fi + +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 +$as_echo_n "checking return type of signal handlers... " >&6; } +if ${ac_cv_type_signal+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include + +int +main () +{ +return *(signal (0, 0)) (0) == 1; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_type_signal=int +else + ac_cv_type_signal=void +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 +$as_echo "$ac_cv_type_signal" >&6; } -" -if test "x$ac_cv_header_sys_timex_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_TIMEX_H 1 +cat >>confdefs.h <<_ACEOF +#define RETSIGTYPE $ac_cv_type_signal _ACEOF -fi - -done +ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" +if test "x$ac_cv_type_off_t" = xyes; then : -for ac_header in resolv.h -do : - ac_fn_c_check_header_compile "$LINENO" "resolv.h" "ac_cv_header_resolv_h" "#if HAVE_SYS_TYPES_H -#include -#endif -#if HAVE_NETINET_IN_H -#include -#endif -#if HAVE_ARPA_NAMESER_H -#include -#endif +else -" -if test "x$ac_cv_header_resolv_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_RESOLV_H 1 +cat >>confdefs.h <<_ACEOF +#define off_t long int _ACEOF fi -done - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for basic volatile support" >&5 -$as_echo_n "checking for basic volatile support... " >&6; } -if test "${ac_cv_c_volatile+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 +$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } +if ${ac_cv_struct_tm+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +#include int main () { - -volatile int x; +struct tm tm; + int *p = &tm.tm_sec; + return !p; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_volatile=yes + ac_cv_struct_tm=time.h else - ac_cv_c_volatile=no + ac_cv_struct_tm=sys/time.h fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 -$as_echo "$ac_cv_c_volatile" >&6; } -case "$ac_cv_c_volatile" in - yes) - ;; - *) -$as_echo "#define volatile /**/" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 +$as_echo "$ac_cv_struct_tm" >&6; } +if test $ac_cv_struct_tm = sys/time.h; then - ;; -esac +$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h -# -# following block goes away in 4.2.5 -# -# AM_C_PROTOTYPES gives us ansi2knr -case "$build" in - *-*-solaris2*) - # Assume that solaris2 is Ansi C... - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5 -$as_echo_n "checking for function prototypes... " >&6; } -if test "$ac_cv_prog_cc_c89" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +fi -$as_echo "#define PROTOTYPES 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a fallback value for HZ" >&5 +$as_echo_n "checking for a fallback value for HZ... " >&6; } +if ${ntp_cv_default_hz+:} false; then : + $as_echo_n "(cached) " >&6 +else + ntp_cv_default_hz=100 + case "$host" in + alpha*-dec-osf4*|alpha*-dec-osf5*) + ntp_cv_default_hz=1024 + ;; + mips-dec-ultrix4*) + ntp_cv_default_hz=256 + ;; + esac -$as_echo "#define __PROTOTYPES 1" >>confdefs.h -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_default_hz" >&5 +$as_echo "$ntp_cv_default_hz" >&6; } + +cat >>confdefs.h <<_ACEOF +#define DEFAULT_HZ $ntp_cv_default_hz +_ACEOF -if test "$ac_cv_prog_cc_stdc" != no; then - U= ANSI2KNR= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to override the system's value for HZ" >&5 +$as_echo_n "checking if we need to override the system's value for HZ... " >&6; } +if ${ntp_cv_override_hz+:} false; then : + $as_echo_n "(cached) " >&6 else - U=_ ANSI2KNR=./ansi2knr -fi -# Ensure some checks needed by ansi2knr itself. -for ac_header in string.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "string.h" "ac_cv_header_string_h" "$ac_includes_default" -if test "x$ac_cv_header_string_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_STRING_H 1 -_ACEOF + ntp_cv_override_hz=no + case "$host" in + alpha*-dec-osf4*|alpha*-dec-osf5*) + ntp_cv_override_hz=yes + ;; + mips-dec-ultrix4*) + ntp_cv_override_hz=yes + ;; + *-*-freebsd*) + ntp_cv_override_hz=yes + ;; + *-*-sunos4*) + ntp_cv_override_hz=yes + ;; + *-*-kfreebsd*) + ntp_cv_override_hz=yes + ;; + esac -fi -done +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_override_hz" >&5 +$as_echo "$ntp_cv_override_hz" >&6; } +case "$ntp_cv_override_hz" in + yes) +$as_echo "#define OVERRIDE_HZ 1" >>confdefs.h - ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if C compiler permits function prototypes" >&5 -$as_echo_n "checking if C compiler permits function prototypes... " >&6; } -if test "${ac_cv_have_prototypes+set}" = set; then : + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct rt_msghdr" >&5 +$as_echo_n "checking for struct rt_msghdr... " >&6; } +if ${ntp_cv_struct_rt_msghdr+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -extern int foo (short); -int foo(short i) { return i; } + #include + #include + #include + #include + int main () { -int i; + struct rt_msghdr p; + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_prototypes=yes + ntp_cv_struct_rt_msghdr=yes else - ac_cv_have_prototypes=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ntp_cv_struct_rt_msghdr=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_prototypes" >&5 -$as_echo "$ac_cv_have_prototypes" >&6; } -if test "$ac_cv_have_prototypes" = yes; then - -$as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -# -# end block -# +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_rt_msghdr" >&5 +$as_echo "$ntp_cv_struct_rt_msghdr" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 -$as_echo_n "checking for an ANSI C-conforming const... " >&6; } -if test "${ac_cv_c_const+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct rtattr" >&5 +$as_echo_n "checking for struct rtattr... " >&6; } +if ${ntp_cv_rtattr+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + #include + #include + #include + int main () { -/* FIXME: Include the comments suggested by Paul. */ -#ifndef __cplusplus - /* Ultrix mips cc rejects this. */ - typedef int charset[2]; - const charset cs; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this. */ - char *t; - char const *s = 0 ? (char *) 0 : (char const *) 0; - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; }; - struct s *b; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif + struct rtattr p; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_const=yes + ntp_cv_rtattr=yes else - ac_cv_c_const=no + ntp_cv_rtattr=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 -$as_echo "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rtattr" >&5 +$as_echo "$ntp_cv_rtattr" >&6; } -$as_echo "#define const /**/" >>confdefs.h +case "$ntp_cv_struct_rt_msghdr$ntp_cv_rtattr" in + *yes*) -fi +$as_echo "#define HAS_ROUTING_SOCKET 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 -$as_echo_n "checking whether byte ordering is bigendian... " >&6; } -if test "${ac_cv_c_bigendian+set}" = set; then : + case "$ntp_cv_rtattr" in + yes) + +$as_echo "#define HAVE_RTNETLINK 1" >>confdefs.h + + esac +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sigaction for sa_sigaction" >&5 +$as_echo_n "checking struct sigaction for sa_sigaction... " >&6; } +if ${ntp_cv_struct_sigaction_has_sa_sigaction+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_c_bigendian=unknown - # See if we're dealing with a universal compiler. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifndef __APPLE_CC__ - not a universal capable compiler - #endif - typedef int dummy; -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - - # Check for potential -arch flags. It is not universal unless - # there are at least two -arch flags with different values. - ac_arch= - ac_prev= - for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do - if test -n "$ac_prev"; then - case $ac_word in - i?86 | x86_64 | ppc | ppc64) - if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then - ac_arch=$ac_word - else - ac_cv_c_bigendian=universal - break - fi - ;; - esac - ac_prev= - elif test "x$ac_word" = "x-arch"; then - ac_prev=arch - fi - done -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - if test $ac_cv_c_bigendian = unknown; then - # See if sys/param.h defines the BYTE_ORDER macro. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - #include + #include int main () { -#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ - && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ - && LITTLE_ENDIAN) - bogus endian macros - #endif - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - # It does; now see whether it defined to BIG_ENDIAN or not. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - #include + struct sigaction act; + act.sa_sigaction = 0; -int -main () -{ -#if BYTE_ORDER != BIG_ENDIAN - not big endian - #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_bigendian=yes + ntp_cv_struct_sigaction_has_sa_sigaction=yes else - ac_cv_c_bigendian=no + ntp_cv_struct_sigaction_has_sa_sigaction=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi - if test $ac_cv_c_bigendian = unknown; then - # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_sigaction_has_sa_sigaction" >&5 +$as_echo "$ntp_cv_struct_sigaction_has_sa_sigaction" >&6; } +case "$ntp_cv_struct_sigaction_has_sa_sigaction" in + yes) + +$as_echo "#define HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ppsclockev" >&5 +$as_echo_n "checking for struct ppsclockev... " >&6; } +if ${ntp_cv_struct_ppsclockev+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_TERMIOS_H + # include + #endif + #ifdef HAVE_SYS_TIME_H + # include + #endif + #ifdef HAVE_SYS_PPSCLOCK_H + # include + #endif int main () { -#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) - bogus endian macros - #endif + + extern struct ppsclockev *pce; + return pce->serial; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - # It does; now see whether it defined to _BIG_ENDIAN or not. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ntp_cv_struct_ppsclockev=yes +else + ntp_cv_struct_ppsclockev=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_ppsclockev" >&5 +$as_echo "$ntp_cv_struct_ppsclockev" >&6; } +case "$ntp_cv_struct_ppsclockev" in + yes) + +$as_echo "#define HAVE_STRUCT_PPSCLOCKEV 1" >>confdefs.h + +esac + +case "$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in + *yes*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct snd_size" >&5 +$as_echo_n "checking for struct snd_size... " >&6; } +if ${ntp_cv_struct_snd_size+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + + #ifdef HAVE_MACHINE_SOUNDCARD_H + # include + #endif + #ifdef HAVE_SYS_SOUNDCARD_H + # include + #endif int main () { -#ifndef _BIG_ENDIAN - not big endian - #endif + + extern struct snd_size *ss; + return ss->rec_size; + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_bigendian=yes + ntp_cv_struct_snd_size=yes else - ac_cv_c_bigendian=no + ntp_cv_struct_snd_size=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi - if test $ac_cv_c_bigendian = unknown; then - # Compile a test program. - if test "$cross_compiling" = yes; then : - # Try to guess by grepping values from an object file. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_snd_size" >&5 +$as_echo "$ntp_cv_struct_snd_size" >&6; } + case "$ntp_cv_struct_snd_size" in + yes) + +$as_echo "#define HAVE_STRUCT_SND_SIZE 1" >>confdefs.h + + esac +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct clockinfo for hz" >&5 +$as_echo_n "checking struct clockinfo for hz... " >&6; } +if ${ntp_cv_struct_clockinfo_has_hz+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -short int ascii_mm[] = - { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; - short int ascii_ii[] = - { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; - int use_ascii (int i) { - return ascii_mm[i] + ascii_ii[i]; - } - short int ebcdic_ii[] = - { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; - short int ebcdic_mm[] = - { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; - int use_ebcdic (int i) { - return ebcdic_mm[i] + ebcdic_ii[i]; - } - extern int foo; + + #include int main () { -return use_ascii (foo) == use_ebcdic (foo); + + extern struct clockinfo *pc; + return pc->hz; + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then - ac_cv_c_bigendian=yes - fi - if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then - if test "$ac_cv_c_bigendian" = unknown; then - ac_cv_c_bigendian=no - else - # finding both strings is unlikely to happen, but who knows? - ac_cv_c_bigendian=unknown - fi - fi + ntp_cv_struct_clockinfo_has_hz=yes +else + ntp_cv_struct_clockinfo_has_hz=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_clockinfo_has_hz" >&5 +$as_echo "$ntp_cv_struct_clockinfo_has_hz" >&6; } +case "$ntp_cv_struct_clockinfo_has_hz" in + yes) + +$as_echo "#define HAVE_HZ_IN_STRUCT_CLOCKINFO 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct clockinfo for tickadj" >&5 +$as_echo_n "checking struct clockinfo for tickadj... " >&6; } +if ${ntp_cv_struct_clockinfo_has_hz+:} false; then : + $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default + + #include + int main () { - /* Are we little or big endian? From Harbison&Steele. */ - union - { - long int l; - char c[sizeof (long int)]; - } u; - u.l = 1; - return u.c[sizeof (long int) - 1] == 1; + extern struct clockinfo *pc; + return pc->tickadj; + ; return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - ac_cv_c_bigendian=no +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_struct_clockinfo_has_hz=yes else - ac_cv_c_bigendian=yes + ntp_cv_struct_clockinfo_has_hz=no + fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_clockinfo_has_hz" >&5 +$as_echo "$ntp_cv_struct_clockinfo_has_hz" >&6; } +case "$ntp_cv_struct_clockinfo_has_hz" in + yes) + +$as_echo "#define HAVE_TICKADJ_IN_STRUCT_CLOCKINFO 1" >>confdefs.h + +esac + +case "$ntp_cv_struct_ntptimeval" in + yes) + ac_fn_c_check_member "$LINENO" "struct ntptimeval" "time.tv_nsec" "ac_cv_member_struct_ntptimeval_time_tv_nsec" " + #ifdef HAVE_SYS_TIME_H + # include + #else + # ifdef HAVE_TIME_H + # include + # endif + #endif + #ifdef HAVE_SYS_TIMEX_H + # include + #else + # ifdef HAVE_TIMEX_H + # include + # endif + #endif + + +" +if test "x$ac_cv_member_struct_ntptimeval_time_tv_nsec" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_NTPTIMEVAL_TIME_TV_NSEC 1 +_ACEOF + - fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 -$as_echo "$ac_cv_c_bigendian" >&6; } - case $ac_cv_c_bigendian in #( - yes) - $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h -;; #( - no) - ;; #( - universal) -$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h +esac - ;; #( - *) - as_fn_error "unknown endianness - presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; - esac +#### + +for ac_func in arc4random_buf +do : + ac_fn_c_check_func "$LINENO" "arc4random_buf" "ac_cv_func_arc4random_buf" +if test "x$ac_cv_func_arc4random_buf" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ARC4RANDOM_BUF 1 +_ACEOF + +fi +done + + +#### + +saved_LIBS="$LIBS" +LIBS="$LIBS $LDADD_LIBNTP" +for ac_func in daemon +do : + ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon" +if test "x$ac_cv_func_daemon" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DAEMON 1 +_ACEOF + +fi +done + +# XXX if we keep everything in LIBS and also keep separate lists, this simplifies. +LIBS="$saved_LIBS" +{ saved_LIBS=; unset saved_LIBS;} + +for ac_func in finite +do : + ac_fn_c_check_func "$LINENO" "finite" "ac_cv_func_finite" +if test "x$ac_cv_func_finite" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_FINITE 1 +_ACEOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 -$as_echo_n "checking return type of signal handlers... " >&6; } -if test "${ac_cv_type_signal+set}" = set; then : - $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + for ac_func in isfinite +do : + ac_fn_c_check_func "$LINENO" "isfinite" "ac_cv_func_isfinite" +if test "x$ac_cv_func_isfinite" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ISFINITE 1 +_ACEOF + +else + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isfinite with " >&5 +$as_echo_n "checking for isfinite with ... " >&6; } + _libs=$LIBS + # XXX + LIBS="$LIBS -lm" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + + #include int main () { -return *(signal (0, 0)) (0) == 1; + + float f = 0.0; + isfinite(f); + + ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_type_signal=int +if ac_fn_c_try_link "$LINENO"; then : + ans=yes else - ac_cv_type_signal=void + ans=no + fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS=$_libs + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + case "$ans" in + yes) + $as_echo "#define HAVE_ISFINITE 1" >>confdefs.h + + esac + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 -$as_echo "$ac_cv_type_signal" >&6; } +done -cat >>confdefs.h <<_ACEOF -#define RETSIGTYPE $ac_cv_type_signal + +fi +done + + +for ac_func in fnmatch getbootfile getuid getrusage nanosleep strsignal +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF +fi +done -ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" -if test "x$ac_cv_type_off_t" = x""yes; then : -else +# kvm_open() is only used by tickadj. Also see above. +case "$ac_cv_header_kvm_h" in + yes) + for ac_func in kvm_open +do : + ac_fn_c_check_func "$LINENO" "kvm_open" "ac_cv_func_kvm_open" +if test "x$ac_cv_func_kvm_open" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_KVM_OPEN 1 +_ACEOF -cat >>confdefs.h <<_ACEOF -#define off_t long int +fi +done + + ;; +esac + +case "$host" in + *-*-sco3.2v5.0.*) + # Just stubs. Sigh. + ;; + *) for ac_func in mkstemp +do : + ac_fn_c_check_func "$LINENO" "mkstemp" "ac_cv_func_mkstemp" +if test "x$ac_cv_func_mkstemp" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MKSTEMP 1 _ACEOF fi +done -ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" -if test "x$ac_cv_type_size_t" = x""yes; then : + ;; +esac +for ac_func in mktime +do : + ac_fn_c_check_func "$LINENO" "mktime" "ac_cv_func_mktime" +if test "x$ac_cv_func_mktime" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MKTIME 1 +_ACEOF -else +fi +done -cat >>confdefs.h <<_ACEOF -#define size_t unsigned int +case "$host" in + *-*-aix[4-9]*) + # XXX only verified thru AIX6. + # Just a stub. Sigh. + ;; + *-*-irix[45]*) + # Just a stub in "old" Irix. Sigh. + ;; +# In the belief that the fix for bug 1223 fixes mlockall() under linux... +# *-*-*linux*) +# # there, but more trouble than it is worth for now (resolver problems) +# ;; + *-*-qnx*) + # Apparently there but not working in QNX. Sigh? + ;; + *-*-sco3.2v5.0.*) + # Just a stub. Sigh. + ;; + alpha*-dec-osf4*|alpha*-dec-osf5*) + # mlockall is there, as a #define calling memlk via + # Not easy to test for - cheat. + for ac_func in memlk +do : + ac_fn_c_check_func "$LINENO" "memlk" "ac_cv_func_memlk" +if test "x$ac_cv_func_memlk" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MEMLK 1 _ACEOF - + ac_cv_func_mlockall=yes fi +done -ac_fn_c_check_type "$LINENO" "time_t" "ac_cv_type_time_t" "$ac_includes_default" -if test "x$ac_cv_type_time_t" = x""yes; then : + for ac_func in mlockall +do : + ac_fn_c_check_func "$LINENO" "mlockall" "ac_cv_func_mlockall" +if test "x$ac_cv_func_mlockall" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MLOCKALL 1 +_ACEOF -else +fi +done -cat >>confdefs.h <<_ACEOF -#define time_t long + ;; + *) for ac_func in mlockall +do : + ac_fn_c_check_func "$LINENO" "mlockall" "ac_cv_func_mlockall" +if test "x$ac_cv_func_mlockall" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MLOCKALL 1 _ACEOF fi +done -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 -$as_echo_n "checking size of time_t... " >&6; } -if test "${ac_cv_sizeof_time_t+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "$ac_includes_default"; then : + ;; +esac +for ac_func in nice plock pututline pututxline readlink rtprio +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF -else - if test "$ac_cv_type_time_t" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (time_t) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_time_t=0 - fi fi +done + +case "$host" in + *-*-aix[4-9]*) + # XXX only verified thru AIX6. + # Just a stub in AIX 4. Sigh. + ;; + *-*-solaris2.5*) + # Just stubs in solaris2.5. Sigh. + ;; + *) for ac_func in sched_setscheduler +do : + ac_fn_c_check_func "$LINENO" "sched_setscheduler" "ac_cv_func_sched_setscheduler" +if test "x$ac_cv_func_sched_setscheduler" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SCHED_SETSCHEDULER 1 +_ACEOF fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 -$as_echo "$ac_cv_sizeof_time_t" >&6; } +done + ;; +esac +for ac_func in setlinebuf setpgid setpriority setsid setvbuf +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF +fi +done -cat >>confdefs.h <<_ACEOF -#define SIZEOF_TIME_T $ac_cv_sizeof_time_t +for ac_func in strdup strerror setrlimit strchr +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF +fi +done -ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 +case "$host" in + *-*-aix[4-9]*) + # XXX only verified thru AIX6. + # Just stubs. Sigh. + ;; + *-*-netbsd1*) + # Just stubs. Sigh. + ;; + *-*-netbsdelf1*) + # Just stubs. Sigh. + ;; + *-*-openbsd*) + # Just stubs. Sigh. + ;; + *) + for ac_func in timer_create +do : + ac_fn_c_check_func "$LINENO" "timer_create" "ac_cv_func_timer_create" +if test "x$ac_cv_func_timer_create" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_TIMER_CREATE 1 _ACEOF - fi +done + ;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 -$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } -if test "${ac_cv_struct_tm+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for RLIMIT_MEMLOCK" >&5 +$as_echo_n "checking for RLIMIT_MEMLOCK... " >&6; } +if ${ntp_cv_rlimit_memlock+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_TIME_H + # include + #endif + #ifdef HAVE_SYS_RESOURCE_H + # include + #endif int main () { -struct tm tm; - int *p = &tm.tm_sec; - return !p; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_tm=time.h -else - ac_cv_struct_tm=sys/time.h -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 -$as_echo "$ac_cv_struct_tm" >&6; } -if test $ac_cv_struct_tm = sys/time.h; then -$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h - -fi + getrlimit(RLIMIT_MEMLOCK, 0); -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int8_t" >&5 -$as_echo_n "checking for u_int8_t... " >&6; } -if test "${ac_cv_type_u_int8_t+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -u_int8_t len = 42; return 0; ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_type_u_int8_t=yes + ntp_cv_rlimit_memlock=yes else - ac_cv_type_u_int8_t=no + ntp_cv_rlimit_memlock=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_u_int8_t" >&5 -$as_echo "$ac_cv_type_u_int8_t" >&6; } -if test $ac_cv_type_u_int8_t = yes; then - -$as_echo "#define HAVE_TYPE_U_INT8_T 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rlimit_memlock" >&5 +$as_echo "$ntp_cv_rlimit_memlock" >&6; } +case "$host" in + *-*-*linux*) + ntp_dflt_rlimit_memlock="-1" ;; + *) ntp_dflt_rlimit_memlock="32" ;; +esac +case "$ntp_cv_rlimit_memlock" in + yes) -fi + HAVE_RLIMIT_MEMLOCK=" memlock $ntp_dflt_rlimit_memlock" ;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int64_t" >&5 -$as_echo_n "checking for u_int64_t... " >&6; } -if test "${ac_cv_type_u_int64_t+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for RLIMIT_STACK" >&5 +$as_echo_n "checking for RLIMIT_STACK... " >&6; } +if ${ntp_cv_rlimit_stack+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_TIME_H + # include + #endif + #ifdef HAVE_SYS_RESOURCE_H + # include + #endif + int main () { -u_int64_t len = 42; return 0; + + getrlimit(RLIMIT_STACK, 0); + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_type_u_int64_t=yes + ntp_cv_rlimit_stack=yes else - ac_cv_type_u_int64_t=no + ntp_cv_rlimit_stack=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_u_int64_t" >&5 -$as_echo "$ac_cv_type_u_int64_t" >&6; } -if test $ac_cv_type_u_int64_t = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rlimit_stack" >&5 +$as_echo "$ntp_cv_rlimit_stack" >&6; } +case "$ntp_cv_rlimit_stack" in + yes) + + HAVE_RLIMIT_STACK=" stacksize 50" +esac -$as_echo "#define HAVE_TYPE_U_INT64_T 1" >>confdefs.h +# HMS: Only if we are doing the MLOCKALL stuff... +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the default number of 4k stack pages" >&5 +$as_echo_n "checking for the default number of 4k stack pages... " >&6; } + +# Check whether --with-stack-limit was given. +if test "${with_stack_limit+set}" = set; then : + withval=$with_stack_limit; ans=$withval +else + ans=yes fi -# -# Look for in_port_t. -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5 -$as_echo_n "checking for in_port_t... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +case "$ans" in + yes | no) + case "$host" in + *-*-openbsd*) + ans=200 + ;; + *) ans=50 + ;; + esac + ;; + [1-9][0-9]*) + ;; + *) as_fn_error $? "\"--with-stack-limit requires an integer argument.\"" "$LINENO" 5 + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -#include -#include -int -main () -{ -in_port_t port = 25; return (0); - ; - return 0; -} +cat >>confdefs.h <<_ACEOF +#define DFLT_RLIMIT_STACK $ans _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h +# HMS: only if we have RLIMIT_MEMLOCK +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the default number of megabytes to MEMLOCK" >&5 +$as_echo_n "checking for the default number of megabytes to MEMLOCK... " >&6; } +# Check whether --with-memlock was given. +if test "${with_memlock+set}" = set; then : + withval=$with_memlock; ans=$withval +else + ans=yes fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a fallback value for HZ" >&5 -$as_echo_n "checking for a fallback value for HZ... " >&6; } -if test "${ac_cv_var_default_hz+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_var_default_hz=100 -case "$host" in - alpha*-dec-osf4*|alpha*-dec-osf5*) - ac_cv_var_default_hz=1024 - ;; - mips-dec-ultrix4*) - ac_cv_var_default_hz=256 +case "$ans" in + yes | no) + ans=$ntp_dflt_rlimit_memlock ;; + [1-9][0-9]*) ;; + *) as_fn_error $? "\"--with-memlock requires an integer argument.\"" "$LINENO" 5 + ;; esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_default_hz" >&5 -$as_echo "$ac_cv_var_default_hz" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } cat >>confdefs.h <<_ACEOF -#define DEFAULT_HZ $ac_cv_var_default_hz +#define DFLT_RLIMIT_MEMLOCK $ans _ACEOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to override the system's value for HZ" >&5 -$as_echo_n "checking if we need to override the system's value for HZ... " >&6; } -if test "${ac_cv_var_override_hz+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_var_override_hz=no -case "$host" in - alpha*-dec-osf4*|alpha*-dec-osf5*) - ac_cv_var_override_hz=yes - ;; - mips-dec-ultrix4*) - ac_cv_var_override_hz=yes - ;; - *-*-freebsd*) - ac_cv_var_override_hz=yes + + +# some OSes prefer _exit() in forked children to exit() +for ac_func in _exit +do : + ac_fn_c_check_func "$LINENO" "_exit" "ac_cv_func__exit" +if test "x$ac_cv_func__exit" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE__EXIT 1 +_ACEOF + +fi +done + +ntp_worker_child_exit=exit +case "$ac_cv_func__exit::$host_os" in + yes::netbsd*) + ntp_worker_child_exit=_exit ;; - *-*-sunos4*) - ac_cv_var_override_hz=yes + yes::openbsd*) + ntp_worker_child_exit=_exit ;; esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_override_hz" >&5 -$as_echo "$ac_cv_var_override_hz" >&6; } -case "$ac_cv_var_override_hz" in - yes) -$as_echo "#define OVERRIDE_HZ 1" >>confdefs.h +cat >>confdefs.h <<_ACEOF +#define WORKER_CHILD_EXIT $ntp_worker_child_exit +_ACEOF - ;; -esac + +for ac_func in umask uname updwtmp updwtmpx +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done +### -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct rt_msghdr" >&5 -$as_echo_n "checking for struct rt_msghdr... " >&6; } -if test "${ac_cv_struct_rt_msghdr+set}" = set; then : +# http://bugs.ntp.org/737 +case "$ac_cv_func_recvmsg" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need extra help to define struct iovec" >&5 +$as_echo_n "checking if we need extra help to define struct iovec... " >&6; } +if ${ntp_cv_struct_iovec_help+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + compiled=no + for ntp_cv_struct_iovec_help in '0' '1'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #if $ntp_cv_struct_iovec_help + # include + #endif + int main () { -struct rt_msghdr p; + + void foo(void) { + ssize_t x; + int s = 0; + struct iovec iov; + struct msghdr mh; + int flags = 0; + + mh.msg_iov = &iov; + x = recvmsg(s, &mh, flags); + } + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_rt_msghdr=yes -else - ac_cv_struct_rt_msghdr=no + compiled=yes ; break 1 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done + case "$compiled" in + no) + ntp_cv_struct_iovec_help=0 + esac + { compiled=; unset compiled;} -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_rt_msghdr" >&5 -$as_echo "$ac_cv_struct_rt_msghdr" >&6; } -if test $ac_cv_struct_rt_msghdr = yes; then +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_iovec_help" >&5 +$as_echo "$ntp_cv_struct_iovec_help" >&6; } + case "$ntp_cv_struct_iovec_help" in + 1) -$as_echo "#define HAS_ROUTING_SOCKET 1" >>confdefs.h +$as_echo "#define HAVE_SYS_UIO_H 1" >>confdefs.h -fi + esac +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sigaction for sa_sigaction" >&5 -$as_echo_n "checking struct sigaction for sa_sigaction... " >&6; } -if test "${ac_cv_struct_sigaction_has_sa_sigaction+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments taken by setpgrp()" >&5 +$as_echo_n "checking number of arguments taken by setpgrp()... " >&6; } +if ${ntp_cv_func_setpgrp_nargs+:} false; then : $as_echo_n "(cached) " >&6 else - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_UNISTD_H + # include + #endif + int main () { -struct sigaction act; act.sa_sigaction = 0; + + setpgrp(0, 0); + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_sigaction_has_sa_sigaction=yes + ntp_cv_func_setpgrp_nargs=2 else - ac_cv_struct_sigaction_has_sa_sigaction=no + ntp_cv_func_setpgrp_nargs=0 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sigaction_has_sa_sigaction" >&5 -$as_echo "$ac_cv_struct_sigaction_has_sa_sigaction" >&6; } -if test $ac_cv_struct_sigaction_has_sa_sigaction = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_setpgrp_nargs" >&5 +$as_echo "$ntp_cv_func_setpgrp_nargs" >&6; } +case "$ntp_cv_func_setpgrp_nargs" in + 0) -$as_echo "#define HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION 1" >>confdefs.h +$as_echo "#define HAVE_SETPGRP_0 1" >>confdefs.h -fi +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ppsclockev" >&5 -$as_echo_n "checking for struct ppsclockev... " >&6; } -if test "${ac_cv_struct_ppsclockev+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to declare 'errno'" >&5 +$as_echo_n "checking if we need to declare 'errno'... " >&6; } +if ${ntp_cv_decl_errno+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#ifdef HAVE_SYS_TERMIOS_H -# include -#endif -#ifdef HAVE_SYS_TIME_H -# include -#endif -#ifdef HAVE_SYS_PPSCLOCK_H -# include -#endif + #ifdef HAVE_ERRNO_H + # include + #endif + int main () { -extern struct ppsclockev *pce; -return pce->serial; + errno = 0; + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_ppsclockev=yes + ntp_cv_decl_errno=no else - ac_cv_struct_ppsclockev=no + ntp_cv_decl_errno=yes + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_ppsclockev" >&5 -$as_echo "$ac_cv_struct_ppsclockev" >&6; } -if test $ac_cv_struct_ppsclockev = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_decl_errno" >&5 +$as_echo "$ntp_cv_decl_errno" >&6; } +case "$ntp_cv_decl_errno" in + yes) -$as_echo "#define HAVE_STRUCT_PPSCLOCKEV 1" >>confdefs.h +$as_echo "#define DECL_ERRNO 1" >>confdefs.h -fi +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5 -$as_echo_n "checking struct sockaddr for sa_len... " >&6; } -if test "${ac_cv_struct_sockaddr_has_sa_len+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we may declare 'h_errno'" >&5 +$as_echo_n "checking if we may declare 'h_errno'... " >&6; } +if ${ntp_cv_decl_h_errno+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include + #include + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif + #ifdef HAVE_NETDB_H + # include + #endif + #ifdef HAVE_RESOLV_H + # include + #endif + int main () { -extern struct sockaddr *ps; -return ps->sa_len; + extern int h_errno; + + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_sockaddr_has_sa_len=yes + ntp_cv_decl_h_errno=yes else - ac_cv_struct_sockaddr_has_sa_len=no + ntp_cv_decl_h_errno=no + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_has_sa_len" >&5 -$as_echo "$ac_cv_struct_sockaddr_has_sa_len" >&6; } -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_decl_h_errno" >&5 +$as_echo "$ntp_cv_decl_h_errno" >&6; } +case "$ntp_cv_decl_h_errno" in + yes) -$as_echo "#define HAVE_SA_LEN_IN_STRUCT_SOCKADDR 1" >>confdefs.h +$as_echo "#define DECL_H_ERRNO 1" >>confdefs.h -fi +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5 -$as_echo_n "checking for struct sockaddr_storage... " >&6; } -if test "${ac_cv_struct_sockaddr_storage+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if declaring 'syscall()' is ok" >&5 +$as_echo_n "checking if declaring 'syscall()' is ok... " >&6; } +if ${ntp_cv_decl_syscall+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_UNISTD_H + # include + #endif int main () { -struct sockaddr_storage n; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_sockaddr_storage=yes -else - ac_cv_struct_sockaddr_storage=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + extern int syscall (int, ...); + + + ; + return 0; +} + ntp_cv_decl_syscall=yes +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_decl_syscall=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_decl_syscall" >&5 +$as_echo "$ntp_cv_decl_syscall" >&6; } +case "$ntp_cv_decl_syscall" in + yes) + +$as_echo "#define DECL_SYSCALL 1" >>confdefs.h + +esac + +case "$host" in + *-*-aix4.3.*) + +$as_echo "#define DECL_HSTRERROR_0 1" >>confdefs.h + # Needed for XLC under AIX 4.3.2 + ;; + *-*-mpeix*) + +$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h + + +$as_echo "#define DECL_INET_NTOA_0 1" >>confdefs.h + + +$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h + + +$as_echo "#define DECL_SELECT_0 1" >>confdefs.h + + +$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h + + +$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h + + +$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h + + ;; + *-*-osf[45]*) + +$as_echo "#define DECL_PLOCK_0 1" >>confdefs.h + + +$as_echo "#define DECL_STIME_1 1" >>confdefs.h + + ;; + *-*-qnx*) + +$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h + + ;; + *-*-riscos4*) + +$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h + + +$as_echo "#define DECL_BZERO_0 1" >>confdefs.h + + +$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h + + +$as_echo "#define DECL_IPC_0 1" >>confdefs.h + + +$as_echo "#define DECL_MEMMOVE_0 1" >>confdefs.h + + +$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h + + +$as_echo "#define DECL_RENAME_0 1" >>confdefs.h + + +$as_echo "#define DECL_SELECT_0 1" >>confdefs.h + + +$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h + + +$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h + + +$as_echo "#define DECL_STDIO_0 1" >>confdefs.h + + +$as_echo "#define DECL_STRTOL_0 1" >>confdefs.h + + +$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h + + +$as_echo "#define DECL_TIME_0 1" >>confdefs.h + + +$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h + + +$as_echo "#define DECL_TOLOWER_0 1" >>confdefs.h + + ;; + *-*-solaris2*) + +$as_echo "#define DECL_MKSTEMP_0 1" >>confdefs.h + + +$as_echo "#define DECL_SETPRIORITY_1 1" >>confdefs.h + + case "$host" in + *-*-solaris2.4) + +$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h + + ;; + esac + ;; + *-*-sunos4*) + +$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h + + +$as_echo "#define DECL_BCOPY_0 1" >>confdefs.h + + +$as_echo "#define DECL_BZERO_0 1" >>confdefs.h + + +$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h + + +$as_echo "#define DECL_IPC_0 1" >>confdefs.h + + +$as_echo "#define DECL_MEMMOVE_0 1" >>confdefs.h + + +$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h + + +$as_echo "#define DECL_MKSTEMP_0 1" >>confdefs.h + + +$as_echo "#define DECL_RENAME_0 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 -$as_echo "$ac_cv_struct_sockaddr_storage" >&6; } -if test $ac_cv_struct_sockaddr_storage = yes; then -$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h +$as_echo "#define DECL_SELECT_0 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have_ss_family_in_struct_ss+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include +$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h -int -main () -{ - struct sockaddr_storage s; s.ss_family = 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_ss_family_in_struct_ss="yes" -else - ac_cv_have_ss_family_in_struct_ss="no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have_ss_family_in_struct_ss" >&6; } -if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then +$as_echo "#define DECL_SIGVEC_0 1" >>confdefs.h -$as_echo "#define HAVE_SS_FAMILY_IN_SS 1" >>confdefs.h + case "`basename $ac_cv_prog_CC`" in + acc*) ;; + *) +$as_echo "#define DECL_STDIO_0 1" >>confdefs.h -else - # Hack around a problem... - # HMS: This is $host because we need the -D if we are building *for* it. - # HMS: 061029: Now that we separate the ss_* checks this is causing - # a problem - disable it until we get to the bottom of it. - case "$host" in - XXX*-*-hpux11.11) CPPFLAGS="$CPPFLAGS -D_NETINET_IN6_H" ;; esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for __ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have___ss_family_in_struct_ss+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +$as_echo "#define DECL_STRTOL_0 1" >>confdefs.h - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include +$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h -int -main () -{ - struct sockaddr_storage s; s.__ss_family = 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have___ss_family_in_struct_ss="yes" -else - ac_cv_have___ss_family_in_struct_ss="no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +$as_echo "#define DECL_TIME_0 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have___ss_family_in_struct_ss" >&6; } -if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then -$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h +$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h -fi +$as_echo "#define DECL_TOLOWER_0 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ss_len field in struct sockaddr_storage" >&5 -$as_echo_n "checking for ss_len field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have_ss_len_in_struct_ss+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +$as_echo "#define DECL_TOUPPER_0 1" >>confdefs.h - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include +$as_echo "#define DECL_STRERROR_0 1" >>confdefs.h -int -main () -{ - struct sockaddr_storage s; s.ss_len = 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_ss_len_in_struct_ss="yes" -else - ac_cv_have_ss_len_in_struct_ss="no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ;; + *-*-ultrix4*) -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_len_in_struct_ss" >&5 -$as_echo "$ac_cv_have_ss_len_in_struct_ss" >&6; } -if test "x$ac_cv_have_ss_len_in_struct_ss" = "xyes" ; then +$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h -$as_echo "#define HAVE_SS_LEN_IN_SS 1" >>confdefs.h -fi +$as_echo "#define DECL_BZERO_0 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __ss_len field in struct sockaddr_storage" >&5 -$as_echo_n "checking for __ss_len field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have___ss_len_in_struct_ss+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +$as_echo "#define DECL_CFSETISPEED_0 1" >>confdefs.h -#include -#include -int -main () -{ - struct sockaddr_storage s; s.__ss_len = 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have___ss_len_in_struct_ss="yes" -else - ac_cv_have___ss_len_in_struct_ss="no" +$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_len_in_struct_ss" >&5 -$as_echo "$ac_cv_have___ss_len_in_struct_ss" >&6; } -if test "x$ac_cv_have___ss_len_in_struct_ss" = "xyes" ; then +$as_echo "#define DECL_IPC_0 1" >>confdefs.h -$as_echo "#define HAVE___SS_LEN_IN_SS 1" >>confdefs.h -fi +$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h +$as_echo "#define DECL_NLIST_0 1" >>confdefs.h -case "$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in - *yes*) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct snd_size" >&5 -$as_echo_n "checking for struct snd_size... " >&6; } -if test "${ac_cv_struct_snd_size+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef HAVE_MACHINE_SOUNDCARD_H -# include -#endif -#ifdef HAVE_SYS_SOUNDCARD_H -# include -#endif -int -main () -{ +$as_echo "#define DECL_PLOCK_0 1" >>confdefs.h -extern struct snd_size *ss; -return ss->rec_size; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_snd_size=yes -else - ac_cv_struct_snd_size=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_snd_size" >&5 -$as_echo "$ac_cv_struct_snd_size" >&6; } - case "$ac_cv_struct_snd_size" in - yes) -$as_echo "#define HAVE_STRUCT_SND_SIZE 1" >>confdefs.h - ;; - esac - ;; -esac +$as_echo "#define DECL_SELECT_0 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct clockinfo for hz" >&5 -$as_echo_n "checking struct clockinfo for hz... " >&6; } -if test "${ac_cv_struct_clockinfo_has_hz+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ +$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h -extern struct clockinfo *pc; -return pc->hz; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_clockinfo_has_hz=yes -else - ac_cv_struct_clockinfo_has_hz=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_clockinfo_has_hz" >&5 -$as_echo "$ac_cv_struct_clockinfo_has_hz" >&6; } -if test $ac_cv_struct_clockinfo_has_hz = yes; then +$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h -$as_echo "#define HAVE_HZ_IN_STRUCT_CLOCKINFO 1" >>confdefs.h -fi +$as_echo "#define DECL_STIME_0 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct clockinfo for tickadj" >&5 -$as_echo_n "checking struct clockinfo for tickadj... " >&6; } -if test "${ac_cv_struct_clockinfo_has_tickadj+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ +$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h -extern struct clockinfo *pc; -return pc->tickadj; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_clockinfo_has_tickadj=yes -else - ac_cv_struct_clockinfo_has_tickadj=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_clockinfo_has_tickadj" >&5 -$as_echo "$ac_cv_struct_clockinfo_has_tickadj" >&6; } -if test $ac_cv_struct_clockinfo_has_tickadj = yes; then +$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h -$as_echo "#define HAVE_TICKADJ_IN_STRUCT_CLOCKINFO 1" >>confdefs.h + ;; +esac -fi +case "$host" in + *-*-sco3.2*) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec" >&5 -$as_echo_n "checking for struct timespec... " >&6; } -if test "${ac_cv_struct_timespec+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +$as_echo "#define TERMIOS_NEEDS__SVID3 1" >>confdefs.h -#include -/* Under SunOS, timespec is in sys/timepps.h, which needs errno.h and FRAC */ -#ifdef HAVE_ERRNO_H -# include -#endif -#ifdef HAVE_SYS_TIMEPPS_H -# define FRAC 4294967296 -# include -#endif -int -main () -{ -struct timespec n; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_timespec=yes -else - ac_cv_struct_timespec=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_timespec" >&5 -$as_echo "$ac_cv_struct_timespec" >&6; } -if test $ac_cv_struct_timespec = yes; then + ;; +esac -$as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h +case "$host" in + *-*-hpux[567]*) -fi +$as_echo "#define NEED_RCVBUF_SLOP 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ntptimeval" >&5 -$as_echo_n "checking for struct ntptimeval... " >&6; } -if test "${ac_cv_struct_ntptimeval+set}" = set; then : +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will open the broadcast socket" >&5 +$as_echo_n "checking if we will open the broadcast socket... " >&6; } +if ${ntp_cv_var_open_bcast_socket+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -int -main () -{ -struct ntptimeval n; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_ntptimeval=yes -else - ac_cv_struct_ntptimeval=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_ntptimeval" >&5 -$as_echo "$ac_cv_struct_ntptimeval" >&6; } -if test $ac_cv_struct_ntptimeval = yes; then + ans=yes + case "$host" in + *-*-domainos) + ans=no + esac + ntp_cv_var_open_bcast_socket=$ans -$as_echo "#define HAVE_STRUCT_NTPTIMEVAL 1" >>confdefs.h fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_open_bcast_socket" >&5 +$as_echo "$ntp_cv_var_open_bcast_socket" >&6; } +case "$ntp_cv_var_open_bcast_socket" in + yes) -ac_fn_c_check_member "$LINENO" "struct ntptimeval" "time.tv_nsec" "ac_cv_member_struct_ntptimeval_time_tv_nsec" "#ifdef HAVE_SYS_TIME_H -#include -#else -# ifdef HAVE_TIME_H -# include -# endif -#endif -#ifdef HAVE_SYS_TIMEX_H -#include -#else -# ifdef HAVE_TIMEX_H -# include -# endif -#endif -" -if test "x$ac_cv_member_struct_ntptimeval_time_tv_nsec" = x""yes; then : +$as_echo "#define OPEN_BCAST_SOCKET 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_NTPTIMEVAL_TIME_TV_NSEC 1 -_ACEOF +esac +case "$host" in + *-*-hpux*) -fi +$as_echo "#define NEED_HPUX_FINDCONFIG 1" >>confdefs.h +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 -$as_echo_n "checking for inline... " >&6; } -if test "${ac_cv_c_inline+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if process groups are set with -pid" >&5 +$as_echo_n "checking if process groups are set with -pid... " >&6; } +if ${ntp_cv_arg_setpgrp_negpid+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_c_inline=no -for ac_kw in inline __inline__ __inline; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifndef __cplusplus -typedef int foo_t; -static $ac_kw foo_t static_foo () {return 0; } -$ac_kw foo_t foo () {return 0; } -#endif -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_inline=$ac_kw -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - test "$ac_cv_c_inline" != no && break -done + case "$host" in + *-*-hpux[567]*) + ans=no + ;; + *-*-hpux*) + ans=yes + ;; + *-*-*linux*) + ans=yes + ;; + *-*-sunos3*) + ans=yes + ;; + *-*-ultrix2*) + ans=yes + ;; + *) + ans=no + ;; + esac + ntp_cv_arg_setpgrp_negpid=$ans + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 -$as_echo "$ac_cv_c_inline" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_arg_setpgrp_negpid" >&5 +$as_echo "$ntp_cv_arg_setpgrp_negpid" >&6; } +case "$ntp_cv_arg_setpgrp_negpid" in + yes) + +$as_echo "#define UDP_BACKWARDS_SETOWN 1" >>confdefs.h -case $ac_cv_c_inline in - inline | yes) ;; - *) - case $ac_cv_c_inline in - no) ac_val=;; - *) ac_val=$ac_cv_c_inline;; - esac - cat >>confdefs.h <<_ACEOF -#ifndef __cplusplus -#define inline $ac_val -#endif -_ACEOF - ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need a ctty for F_SETOWN" >&5 +$as_echo_n "checking if we need a ctty for F_SETOWN... " >&6; } +if ${ntp_cv_func_ctty_for_f_setown+:} false; then : + $as_echo_n "(cached) " >&6 +else -case "$ac_cv_c_inline" in - '') - ;; - *) + case "$host" in + *-*-bsdi[23]*) + ans=yes + ;; + *-*-freebsd*) + ans=yes + ;; + # NetBSD versions prior to 3.99.8 require a CTTY for F_SETOWN, + # while later versions will fail a ioctl(TIOCSCTTY, 0) call in + # some cases and so should not have USE_FSETOWNCTTY. "netbsd" + # in $host may be followed by "aout", "ecoff", or "elf". + *-*-netbsd*[a-z]3.[0-8]*|*-*-netbsd*[a-z][0-2].*|*-*-netbsd*[a-z]3.99.[0-7]) + ans=yes + ;; + *-*-netbsd3.[0-8]*|*-*-netbsd[0-2].*|*-*-netbsd3.99.[0-7]) + ans=yes + ;; + *-*-openbsd*) + ans=yes + ;; + *-*-osf*) + ans=yes + ;; + *-*-darwin*) + ans=yes + ;; + *) + ans=no + ;; + esac + ntp_cv_func_ctty_for_f_setown=$ans -$as_echo "#define HAVE_INLINE 1" >>confdefs.h +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_ctty_for_f_setown" >&5 +$as_echo "$ntp_cv_func_ctty_for_f_setown" >&6; } +case "$ntp_cv_func_ctty_for_f_setown" in + yes) + +$as_echo "#define USE_FSETOWNCTTY 1" >>confdefs.h esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 -$as_echo_n "checking whether char is unsigned... " >&6; } -if test "${ac_cv_c_char_unsigned+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the OS clears cached routes when more specifics become available" >&5 +$as_echo_n "checking if the OS clears cached routes when more specifics become available... " >&6; } +if ${ntp_cv_os_routeupdates+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((char) -1) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_char_unsigned=no -else - ac_cv_c_char_unsigned=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 -$as_echo "$ac_cv_c_char_unsigned" >&6; } -if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then - $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h + case "$host" in + *-*-netbsd*) + ans=yes + ;; + *) + ans=no + ;; + esac + ntp_cv_os_routeupdates=$ans + fi - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of signed char" >&5 -$as_echo_n "checking size of signed char... " >&6; } -if test "${ac_cv_sizeof_signed_char+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_os_routeupdates" >&5 +$as_echo "$ntp_cv_os_routeupdates" >&6; } +case "$ntp_cv_os_routeupdates" in + yes) + +$as_echo "#define OS_MISSES_SPECIFIC_ROUTE_UPDATES 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the wildcard socket needs REUSEADDR to bind other addresses" >&5 +$as_echo_n "checking if the wildcard socket needs REUSEADDR to bind other addresses... " >&6; } +if ${ntp_cv_os_wildcardreuse+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (signed char))" "ac_cv_sizeof_signed_char" "$ac_includes_default"; then : -else - if test "$ac_cv_type_signed_char" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (signed char) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_signed_char=0 - fi -fi + case "$host" in + *-*-*linux*) + ans=yes + ;; + *) ans=no + ;; + esac + ntp_cv_os_wildcardreuse=$ans + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_signed_char" >&5 -$as_echo "$ac_cv_sizeof_signed_char" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_os_wildcardreuse" >&5 +$as_echo "$ntp_cv_os_wildcardreuse" >&6; } +case "$ntp_cv_os_wildcardreuse" in + yes) + +$as_echo "#define OS_NEEDS_REUSEADDR_FOR_IFADDRBIND 1" >>confdefs.h +esac +case "$host" in + *-*-aix*) -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char -_ACEOF +$as_echo "#define NLIST_EXTRA_INDIRECTION 1" >>confdefs.h +esac -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a minimum recommended value of tickadj" >&5 +$as_echo_n "checking for a minimum recommended value of tickadj... " >&6; } +if ${ntp_cv_var_min_rec_tickadj+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : - -else - if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (int) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_int=0 - fi -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } + ans=no + case "$host" in + *-*-aix*) + ans=40 + ;; + esac + ntp_cv_var_min_rec_tickadj=$ans +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_min_rec_tickadj" >&5 +$as_echo "$ntp_cv_var_min_rec_tickadj" >&6; } +case "$ntp_cv_var_min_rec_tickadj" in + ''|no) + ;; + *) cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int +#define MIN_REC_TICKADJ $ntp_cv_var_min_rec_tickadj _ACEOF +esac -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the TTY code permits PARENB and IGNPAR" >&5 +$as_echo_n "checking if the TTY code permits PARENB and IGNPAR... " >&6; } +if ${ntp_cv_no_parenb_ignpar+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : -else - if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (long) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_long=0 - fi + ans=no + case "$host" in + i?86-*-*linux*) + ans=yes + ;; + mips-sgi-irix*) + ans=yes + ;; + i?86-*-freebsd[123].*) + ;; + i?86-*-freebsd*) + ans=yes + ;; + *-*-unicosmp*) + ans=yes + ;; + esac + ntp_cv_no_parenb_ignpar=$ans + + fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_no_parenb_ignpar" >&5 +$as_echo "$ntp_cv_no_parenb_ignpar" >&6; } +case "$ntp_cv_no_parenb_ignpar" in + yes) + +$as_echo "#define NO_PARENB_IGNPAR 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including processing time debugging code" >&5 +$as_echo_n "checking if we're including processing time debugging code... " >&6; } +# Check whether --enable-debug-timing was given. +if test "${enable_debug_timing+set}" = set; then : + enableval=$enable_debug_timing; ntp_ok=$enableval +else + ntp_ok=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } +case "$ntp_ok" in + yes) +$as_echo "#define DEBUG_TIMING 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a the number of minutes in a DST adjustment" >&5 +$as_echo_n "checking for a the number of minutes in a DST adjustment... " >&6; } +# Check whether --enable-dst-minutes was given. +if test "${enable_dst_minutes+set}" = set; then : + enableval=$enable_dst_minutes; ans=$enableval +else + ans=60 +fi -ac_fn_c_check_type "$LINENO" "s_char" "ac_cv_type_s_char" "$ac_includes_default" -if test "x$ac_cv_type_s_char" = x""yes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_S_CHAR 1 +#define DSTMINUTES $ans _ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -fi - -case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in - *yes) - # We have a typedef for s_char. Might as well believe it... - ;; - no0no) - # We have signed chars, can't say 'signed char', no s_char typedef. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpd will retry permanent DNS failures" >&5 +$as_echo_n "checking if ntpd will retry permanent DNS failures... " >&6; } +# Check whether --enable-ignore-dns-errors was given. +if test "${enable_ignore_dns_errors+set}" = set; then : + enableval=$enable_ignore_dns_errors; ans=$enableval +else + ans=no -$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h +fi - ;; - no1no) - # We have signed chars, can say 'signed char', no s_char typedef. - $as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h +case "$ans" in + yes) - ;; - yes0no) - # We have unsigned chars, can't say 'signed char', no s_char typedef. - as_fn_error "No way to specify a signed character!" "$LINENO" 5 - ;; - yes1no) - # We have unsigned chars, can say 'signed char', no s_char typedef. - $as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h +$as_echo "#define IGNORE_DNS_ERRORS 1" >>confdefs.h - ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 -$as_echo_n "checking for uid_t in sys/types.h... " >&6; } -if test "${ac_cv_type_uid_t+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking availability of ntp_{adj,get}time()" >&5 +$as_echo_n "checking availability of ntp_{adj,get}time()... " >&6; } +if ${ntp_cv_var_ntp_syscalls+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + ntp_cv_var_ntp_syscalls=no + case "$ac_cv_func_ntp_adjtime$ac_cv_func_ntp_gettime$ac_cv_func___adjtimex" in + yesyes*) + ntp_cv_var_ntp_syscalls=libc + ;; + *yes) + ntp_cv_var_ntp_syscalls=inline + ;; + *) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + + #include + #if !defined(SYS_ntp_gettime) || !defined(SYS_ntp_adjtime) + # error + #endif _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "uid_t" >/dev/null 2>&1; then : - ac_cv_type_uid_t=yes -else - ac_cv_type_uid_t=no -fi -rm -f conftest* +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_cv_var_ntp_syscalls=kernel fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 -$as_echo "$ac_cv_type_uid_t" >&6; } -if test $ac_cv_type_uid_t = no; then - -$as_echo "#define uid_t int" >>confdefs.h - +rm -f conftest.err conftest.i conftest.$ac_ext + ;; + esac -$as_echo "#define gid_t int" >>confdefs.h fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_ntp_syscalls" >&5 +$as_echo "$ntp_cv_var_ntp_syscalls" >&6; } +case "$ntp_cv_var_ntp_syscalls" in + libc) +$as_echo "#define NTP_SYSCALLS_LIBC 1" >>confdefs.h -case "$host" in - *-*-aix[456]*) - # (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub - # (returning ENOSYS). I didn't check 4.2. If, in the future, - # IBM pulls its thumbs out long enough to implement clock_settime, - # this conditional will need to change. Maybe use AC_TRY_RUN - # instead to try to set the time to itself and check errno. ;; - *) for ac_func in clock_gettime clock_settime -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF + kernel) -fi -done +$as_echo "#define NTP_SYSCALLS_STD 1" >>confdefs.h ;; esac -for ac_func in daemon -do : - ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon" -if test "x$ac_cv_func_daemon" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DAEMON 1 -_ACEOF -fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sys/timex.h has STA_FLL" >&5 +$as_echo_n "checking if sys/timex.h has STA_FLL... " >&6; } +if ${ntp_cv_var_sta_fll+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -for ac_func in finite -do : - ac_fn_c_check_func "$LINENO" "finite" "ac_cv_func_finite" -if test "x$ac_cv_func_finite" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_FINITE 1 -_ACEOF + #include + #ifndef STA_FLL + # error + #endif -else - for ac_func in isfinite -do : - ac_fn_c_check_func "$LINENO" "isfinite" "ac_cv_func_isfinite" -if test "x$ac_cv_func_isfinite" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ISFINITE 1 _ACEOF - +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_cv_var_sta_fll=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isfinite with " >&5 -$as_echo_n "checking for isfinite with ... " >&6; } - _libs=$LIBS - LIBS="$LIBS -lm" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -float f = 0.0; isfinite(f) - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - $as_echo "#define HAVE_ISFINITE 1" >>confdefs.h + ntp_cv_var_sta_fll=no -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - LIBS=$_libs fi -done +rm -f conftest.err conftest.i conftest.$ac_ext fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_sta_fll" >&5 +$as_echo "$ntp_cv_var_sta_fll" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have kernel PLL support" >&5 +$as_echo_n "checking if we have kernel PLL support... " >&6; } +if ${ntp_cv_var_kernel_pll+:} false; then : + $as_echo_n "(cached) " >&6 +else + case "$ac_cv_header_sys_timex_h$ntp_cv_struct_ntptimeval$ntp_cv_var_sta_fll$ntp_cv_var_ntp_syscalls" in + *no*) + ntp_cv_var_kernel_pll=no + ;; + *) ntp_cv_var_kernel_pll=yes + ;; + esac -for ac_func in getbootfile getclock getdtablesize -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_var_kernel_pll" >&5 +$as_echo "$ntp_cv_var_kernel_pll" >&6; } +case "$ntp_cv_var_kernel_pll" in + yes) + +$as_echo "#define KERNEL_PLL 1" >>confdefs.h +esac -# Check whether --enable-getifaddrs was given. -if test "${enable_getifaddrs+set}" = set; then : - enableval=$enable_getifaddrs; want_getifaddrs="$enableval" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if SIOCGIFCONF returns buffer size in the buffer" >&5 +$as_echo_n "checking if SIOCGIFCONF returns buffer size in the buffer... " >&6; } +if ${ntp_cv_size_returned_in_buffer+:} false; then : + $as_echo_n "(cached) " >&6 else - want_getifaddrs="yes" -fi + ans=no + case "$host" in + *-fujitsu-uxp*) + ans=yes + ;; + *-ncr-sysv4*) + ans=yes + ;; + *-univel-sysv*) + ans=yes + ;; + esac + ntp_cv_size_returned_in_buffer=$ans -case $want_getifaddrs in -yes|glibc) -# -# Do we have getifaddrs() ? -# -case $host in -*-*linux*) - # Some recent versions of glibc support getifaddrs() which does not - # provide AF_INET6 addresses while the function provided by the USAGI - # project handles the AF_INET6 case correctly. We need to avoid - # using the former but prefer the latter unless overridden by - # --enable-getifaddrs=glibc. - if test $want_getifaddrs = glibc - then - for ac_func in getifaddrs -do : - ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs" -if test "x$ac_cv_func_getifaddrs" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETIFADDRS 1 -_ACEOF fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_size_returned_in_buffer" >&5 +$as_echo "$ntp_cv_size_returned_in_buffer" >&6; } +case "$ntp_cv_size_returned_in_buffer" in + yes) - else - save_LIBS="$LIBS" - LIBS="-L/usr/local/v6/lib $LIBS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getifaddrs in -linet6" >&5 -$as_echo_n "checking for getifaddrs in -linet6... " >&6; } -if test "${ac_cv_lib_inet6_getifaddrs+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-linet6 $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext +$as_echo "#define SIZE_RETURNED_IN_BUFFER 1" >>confdefs.h + +esac + +# Check for ioctls TIOCGPPSEV +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TTY PPS ioctl TIOCGPPSEV" >&5 +$as_echo_n "checking for TTY PPS ioctl TIOCGPPSEV... " >&6; } +case "$ac_cv_header_termios_h" in + yes) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char getifaddrs (); -int -main () -{ -return getifaddrs (); - ; - return 0; -} + #include + #ifndef TIOCGPPSEV + # error + #endif + _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_inet6_getifaddrs=yes +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_ok=yes else - ac_cv_lib_inet6_getifaddrs=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_inet6_getifaddrs" >&5 -$as_echo "$ac_cv_lib_inet6_getifaddrs" >&6; } -if test "x$ac_cv_lib_inet6_getifaddrs" = x""yes; then : - LIBS="$LIBS -linet6" - $as_echo "#define HAVE_GETIFADDRS 1" >>confdefs.h + ntp_ok=no -else - LIBS=${save_LIBS} fi +rm -f conftest.err conftest.i conftest.$ac_ext + ;; + *) + ntp_ok=no + ;; +esac +case "$ntp_ok" in + yes) + +$as_echo "#define HAVE_TIOCGPPSEV 1" >>confdefs.h + +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } + +# Check for ioctls TIOCSPPS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TTY PPS ioctl TIOCSPPS" >&5 +$as_echo_n "checking for TTY PPS ioctl TIOCSPPS... " >&6; } +case "$ac_cv_header_termios_h" in + yes) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #ifndef TIOCSPPS + # error + #endif - fi - ;; -*) - for ac_func in getifaddrs -do : - ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs" -if test "x$ac_cv_func_getifaddrs" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETIFADDRS 1 _ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_ok=yes +else + ntp_ok=no fi -done - - ;; +rm -f conftest.err conftest.i conftest.$ac_ext + ;; + *) + ntp_ok=no + ;; esac -;; -no) -;; +case "$ntp_ok" in + yes) + +$as_echo "#define HAVE_TIOCSPPS 1" >>confdefs.h + esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking type of socklen arg for getsockname()" >&5 -$as_echo_n "checking type of socklen arg for getsockname()... " >&6; } -if test "${ac_cv_func_getsockname_arg2+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "${ac_cv_func_getsockname_socklen_type+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - for ac_cv_func_getsockname_arg2 in 'struct sockaddr *' 'void *'; do - for ac_cv_func_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +# Check for ioctls CIOGETEV +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for TTY PPS ioctl CIOGETEV" >&5 +$as_echo_n "checking for TTY PPS ioctl CIOGETEV... " >&6; } +case "$ac_cv_header_sys_ppsclock_h" in + yes) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *); -int -main () -{ - ; - return 0; -} + #include + #ifndef CIOGETEV + # error + #endif + _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_not_found=no ; break 2 +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_ok=yes else - ac_not_found=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done - done + ntp_ok=no fi +rm -f conftest.err conftest.i conftest.$ac_ext + ;; + *) + ntp_ok=no + ;; +esac +case "$ntp_ok" in + yes) -fi -if test "$ac_not_found" = yes; then - ac_cv_func_getsockname_socklen_type='socklen_t' -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getsockname_socklen_type" >&5 -$as_echo "$ac_cv_func_getsockname_socklen_type" >&6; } +$as_echo "#define HAVE_CIOGETEV 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define GETSOCKNAME_SOCKLEN_TYPE $ac_cv_func_getsockname_socklen_type -_ACEOF +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +# ATOM/PPSAPI stuff. -for ac_func in getrusage -do : - ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage" -if test "x$ac_cv_func_getrusage" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETRUSAGE 1 -_ACEOF +ntp_atom_ok=yes -fi -done +# Check for header timepps.h, if found then we have PPS API (Draft RFC) stuff. -ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" -if test "x$ac_cv_func_gettimeofday" = x""yes; then : +# The PPSAPI headers need "inline" ($ac_cv_c_inline='inline') +# The PPSAPI needs struct timespec. +# The PPSAPI also needs a timepps header. -else +case "$ac_cv_c_inline$ntp_cv_struct_timespec" in + inlineyes) + case "$ac_cv_header_timepps_h$ac_cv_header_sys_timepps_h$host_os" in + *yes* | *sunos* | *solaris* | *sco* | *netbsd* ) -case "$host" in - *-*-mpeix*) ac_cv_func_gettimeofday=yes +$as_echo "#define HAVE_PPSAPI 1" >>confdefs.h + + ntp_jupiter_ok=yes + ntp_oncore_ok=yes + ntp_parse_ok=yes + ntp_ripe_ncc_ok=yes + ;; + esac ;; esac -fi -case "$host" in - *-pc-cygwin*) - ;; - *) for ac_func in getuid -do : - ac_fn_c_check_func "$LINENO" "getuid" "ac_cv_func_getuid" -if test "x$ac_cv_func_getuid" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETUID 1 -_ACEOF +# Check for ioctls TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG +ac_fn_c_check_header_mongrel "$LINENO" "linux/serial.h" "ac_cv_header_linux_serial_h" "$ac_includes_default" +if test "x$ac_cv_header_linux_serial_h" = xyes; then : fi -done - ;; -esac -for ac_func in hstrerror -do : - ac_fn_c_check_func "$LINENO" "hstrerror" "ac_cv_func_hstrerror" -if test "x$ac_cv_func_hstrerror" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_HSTRERROR 1 -_ACEOF - -fi -done +case "$ac_cv_header_sys_ppsclock_h$ac_cv_header_linux_serial_h" in + yesyes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG" >&5 +$as_echo_n "checking ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# -# Check for if_nametoindex() for IPv6 scoped addresses support -# -ac_fn_c_check_func "$LINENO" "if_nametoindex" "ac_cv_func_if_nametoindex" -if test "x$ac_cv_func_if_nametoindex" = x""yes; then : - ac_cv_have_if_nametoindex=yes -else - ac_cv_have_if_nametoindex=no -fi + #include + typedef int u_int; + #include + #include -case $ac_cv_have_if_nametoindex in - no) - case "$host" in - *-hp-hpux*) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for if_nametoindex in -lipv6" >&5 -$as_echo_n "checking for if_nametoindex in -lipv6... " >&6; } -if test "${ac_cv_lib_ipv6_if_nametoindex+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lipv6 $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + #ifndef TIOCGSERIAL + # error + #endif + #ifndef TIOCSSERIAL + # error + #endif + #ifndef ASYNC_PPS_CD_POS + # error + #endif + #ifndef ASYNC_PPS_CD_NEG + # error + #endif + #ifndef CIOGETEV + # error + #endif -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char if_nametoindex (); -int -main () -{ -return if_nametoindex (); - ; - return 0; -} _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_ipv6_if_nametoindex=yes +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_ok=yes else - ac_cv_lib_ipv6_if_nametoindex=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipv6_if_nametoindex" >&5 -$as_echo "$ac_cv_lib_ipv6_if_nametoindex" >&6; } -if test "x$ac_cv_lib_ipv6_if_nametoindex" = x""yes; then : - ac_cv_have_if_nametoindex=yes - LIBS="-lipv6 $LIBS" + ntp_ok=no + fi +rm -f conftest.err conftest.i conftest.$ac_ext + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } + ;; + *) + ntp_ok=no + ;; +esac +case "$ntp_ok" in + yes) + +$as_echo "#define HAVE_TIO_SERIAL_STUFF 1" >>confdefs.h - ;; - esac esac -case $ac_cv_have_if_nametoindex in + +# Check for SHMEM_STATUS support +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SHMEM_STATUS support" >&5 +$as_echo_n "checking SHMEM_STATUS support... " >&6; } +case "$ac_cv_header_sys_mman_h" in + yes) + ntp_ok=yes + ;; + *) + ntp_ok=no + ;; +esac +case "$ntp_ok" in yes) -$as_echo "#define ISC_PLATFORM_HAVEIFNAMETOINDEX 1" >>confdefs.h +$as_echo "#define ONCORE_SHMEM_STATUS 1" >>confdefs.h - ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" -if test "x$ac_cv_func_inet_ntop" = x""yes; then : +ntp_refclock=no +# HPUX only, and by explicit request +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Datum/Bancomm bc635/VME interface" >&5 +$as_echo_n "checking Datum/Bancomm bc635/VME interface... " >&6; } +# Check whether --enable-BANCOMM was given. +if test "${enable_BANCOMM+set}" = set; then : + enableval=$enable_BANCOMM; ntp_ok=$enableval else - -$as_echo "#define ISC_PLATFORM_NEEDNTOP 1" >>confdefs.h + ntp_ok=no fi -ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton" -if test "x$ac_cv_func_inet_pton" = x""yes; then : +case "$ntp_ok" in + yes) + ntp_refclock=yes -else +$as_echo "#define CLOCK_BANC 1" >>confdefs.h -$as_echo "#define ISC_PLATFORM_NEEDPTON 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$host" in + yes*-*-hpux*) ;; + yes*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; +esac -fi +#HPUX only, and only by explicit request +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking TrueTime GPS receiver/VME interface" >&5 +$as_echo_n "checking TrueTime GPS receiver/VME interface... " >&6; } +# Check whether --enable-GPSVME was given. +if test "${enable_GPSVME+set}" = set; then : + enableval=$enable_GPSVME; ntp_ok=$enableval +else + ntp_ok=no -ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton" -if test "x$ac_cv_func_inet_aton" = x""yes; then : +fi -else +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define ISC_PLATFORM_NEEDATON 1" >>confdefs.h +$as_echo "#define CLOCK_GPSVME 1" >>confdefs.h -fi + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$host" in + yes*-*-hpux*) ;; + yes*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; +esac -for ac_func in K_open kvm_open memcpy memmove memset -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PCL720 clock support" >&5 +$as_echo_n "checking for PCL720 clock support... " >&6; } +case "$ac_cv_header_machine_inline_h$ac_cv_header_sys_pcl720_h$ac_cv_header_sys_i8253_h" in + yesyesyes) -fi -done +$as_echo "#define CLOCK_PPS720 1" >>confdefs.h -case "$host" in - *-*-sco3.2v5.0.*) - # Just stubs. Idiots. + ans=yes ;; - *) for ac_func in mkstemp -do : - ac_fn_c_check_func "$LINENO" "mkstemp" "ac_cv_func_mkstemp" -if test "x$ac_cv_func_mkstemp" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_MKSTEMP 1 -_ACEOF + *) + ans=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default inclusion of all suitable non-PARSE clocks" >&5 +$as_echo_n "checking for default inclusion of all suitable non-PARSE clocks... " >&6; } +# Check whether --enable-all-clocks was given. +if test "${enable_all_clocks+set}" = set; then : + enableval=$enable_all_clocks; ntp_eac=$enableval +else + ntp_eac=yes fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_eac" >&5 +$as_echo "$ntp_eac" >&6; } + +# HMS: Should we also require ntp_parse_ok? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for PARSE clocks" >&5 +$as_echo_n "checking if we have support for PARSE clocks... " >&6; } +case "$ntp_atom_ok$ac_cv_header_termio_h$ac_cv_header_termios_h" in + yes*yes*) + ntp_canparse=yes + ;; + *) ntp_canparse=no ;; esac -for ac_func in mktime -do : - ac_fn_c_check_func "$LINENO" "mktime" "ac_cv_func_mktime" -if test "x$ac_cv_func_mktime" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_MKTIME 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canparse" >&5 +$as_echo "$ntp_canparse" >&6; } -fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for audio clocks" >&5 +$as_echo_n "checking if we have support for audio clocks... " >&6; } +case "$ac_cv_header_sun_audioio_h$ac_cv_header_sys_audioio_h$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in + *yes*) + ntp_canaudio=yes + +$as_echo "#define HAVE_AUDIO /**/" >>confdefs.h -case "$host" in - *-*-aix[456]*) - # Just a stub. Idiots. - ;; - *-*-irix[45]*) - # Just a stub in "old" Irix. Idiots. - ;; - *-*-*linux*) - # there, but more trouble than it is worth for now (resolver problems) - ;; - *-*-qnx*) - # Apparently there but not working in QNX. Idiots? ;; - *-*-sco3.2v5.0.*) - # Just a stub. Idiots. + *) ntp_canaudio=no ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canaudio" >&5 +$as_echo "$ntp_canaudio" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for the SHM refclock interface" >&5 +$as_echo_n "checking if we have support for the SHM refclock interface... " >&6; } +case "$ac_cv_header_sys_ipc_h$ac_cv_header_sys_shm_h" in + yesyes) + ntp_canshm=yes ;; - alpha*-dec-osf4*|alpha*-dec-osf5*) - # mlockall is there, as a #define calling memlk via - # Not easy to test for - cheat. - for ac_func in memlk -do : - ac_fn_c_check_func "$LINENO" "memlk" "ac_cv_func_memlk" -if test "x$ac_cv_func_memlk" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_MEMLK 1 -_ACEOF - ac_cv_func_mlockall='yes' -fi -done + *) ntp_canshm=no ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canshm" >&5 +$as_echo "$ntp_canshm" >&6; } - for ac_func in mlockall -do : - ac_fn_c_check_func "$LINENO" "mlockall" "ac_cv_func_mlockall" -if test "x$ac_cv_func_mlockall" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_MLOCKALL 1 -_ACEOF +# Test for termios TIOCMBIS modem control (ACTS, Heath, Palisade) +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for termios modem control" >&5 +$as_echo_n "checking for termios modem control... " >&6; } +if ${ntp_cv_modem_control+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -done + #ifdef HAVE_UNISTD_H + # include + #endif + #ifdef HAVE_TERMIOS_H + # include + #endif + #ifdef HAVE_SYS_IOCTL_H + # include + #endif - ;; - *) for ac_func in mlockall -do : - ac_fn_c_check_func "$LINENO" "mlockall" "ac_cv_func_mlockall" -if test "x$ac_cv_func_mlockall" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_MLOCKALL 1 -_ACEOF +int +main () +{ -fi -done + int dtr = TIOCM_DTR; - ;; -esac -for ac_func in nice nlist -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF + ioctl(1, TIOCMBIS, (char *)&dtr); -fi -done -case "$host" in - *-*-solaris2.6) - # Broken... - ;; - *) for ac_func in ntp_adjtime ntp_gettime -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 + ; + return 0; +} _ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_modem_control=yes +else + ntp_cv_modem_control=no fi -done +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_modem_control" >&5 +$as_echo "$ntp_cv_modem_control" >&6; } +case "$ntp_eac::$ntp_cv_modem_control" in + yes::yes) + ntp_enable_all_modem_control_clocks=yes + ;; + *) + ntp_enable_all_modem_control_clocks=no ;; esac -for ac_func in plock pututline pututxline readlink recvmsg rtprio -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF + +# Requires modem control +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ACTS modem service" >&5 +$as_echo_n "checking ACTS modem service... " >&6; } +# Check whether --enable-ACTS was given. +if test "${enable_ACTS+set}" = set; then : + enableval=$enable_ACTS; ntp_ok=$enableval +else + ntp_ok=$ntp_enable_all_modem_control_clocks fi -done -case "$host" in - *-*-aix[456]*) - # Just a stub in AIX 4. Idiots. - ;; - *-*-solaris2.5*) - # Just stubs in solaris2.5. Idiots. - ;; - *) for ac_func in sched_setscheduler -do : - ac_fn_c_check_func "$LINENO" "sched_setscheduler" "ac_cv_func_sched_setscheduler" -if test "x$ac_cv_func_sched_setscheduler" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SCHED_SETSCHEDULER 1 -_ACEOF +case "$ntp_ok" in + yes) + ntp_refclock=yes -fi -done +$as_echo "#define CLOCK_ACTS 1" >>confdefs.h ;; esac -for ac_func in setlinebuf setpgid setpriority setsid -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -for ac_func in setrlimit -do : - ac_fn_c_check_func "$LINENO" "setrlimit" "ac_cv_func_setrlimit" -if test "x$ac_cv_func_setrlimit" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SETRLIMIT 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Arbiter 1088A/B GPS receiver" >&5 +$as_echo_n "checking Arbiter 1088A/B GPS receiver... " >&6; } +# Check whether --enable-ARBITER was given. +if test "${enable_ARBITER+set}" = set; then : + enableval=$enable_ARBITER; ntp_ok=$enableval +else + ntp_ok=$ntp_eac fi -done -for ac_func in settimeofday -do : - ac_fn_c_check_func "$LINENO" "settimeofday" "ac_cv_func_settimeofday" -if test "x$ac_cv_func_settimeofday" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SETTIMEOFDAY 1 -_ACEOF +case "$ntp_ok" in + yes) + ntp_refclock=yes -else +$as_echo "#define CLOCK_ARBITER 1" >>confdefs.h -case "$host" in - *-*-mpeix*) ac_cv_func_settimeofday=yes ;; esac -fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -for ac_func in setvbuf sigaction -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Arcron MSF receiver" >&5 +$as_echo_n "checking Arcron MSF receiver... " >&6; } +# Check whether --enable-ARCRON_MSF was given. +if test "${enable_ARCRON_MSF+set}" = set; then : + enableval=$enable_ARCRON_MSF; ntp_ok=$enableval +else + ntp_ok=$ntp_eac fi -done - -for ac_func in sigvec sigset sigsuspend stime strchr sysconf sysctl -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF -fi -done +case "$ntp_ok" in + yes) + ntp_refclock=yes -for ac_func in snprintf strdup strerror strstr -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +$as_echo "#define CLOCK_ARCRON_MSF 1" >>confdefs.h -fi -done + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -for ac_func in timegm -do : - ac_fn_c_check_func "$LINENO" "timegm" "ac_cv_func_timegm" -if test "x$ac_cv_func_timegm" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_TIMEGM 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Austron 2200A/2201A GPS receiver" >&5 +$as_echo_n "checking Austron 2200A/2201A GPS receiver... " >&6; } +# Check whether --enable-AS2201 was given. +if test "${enable_AS2201+set}" = set; then : + enableval=$enable_AS2201; ntp_ok=$enableval +else + ntp_ok=$ntp_eac fi -done -case "$host" in - *-*-aix[456]*) - # Just stubs. Idiots. - ;; - *-*-netbsd1*) - # Just stubs. Idiots. - ;; - *-*-netbsdelf1*) - # Just stubs. Idiots. - ;; - *-*-openbsd*) - # Just stubs. Idiots. - ;; - *) for ac_func in timer_create timer_settime -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +case "$ntp_ok" in + yes) + ntp_refclock=yes -fi -done +$as_echo "#define CLOCK_AS2201 1" >>confdefs.h ;; esac -case "$host" in - *-pc-cygwin*) - # I have no idea... - ;; - *) for ac_func in umask -do : - ac_fn_c_check_func "$LINENO" "umask" "ac_cv_func_umask" -if test "x$ac_cv_func_umask" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_UMASK 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ATOM PPS interface" >&5 +$as_echo_n "checking ATOM PPS interface... " >&6; } +# Check whether --enable-ATOM was given. +if test "${enable_ATOM+set}" = set; then : + enableval=$enable_ATOM; ntp_ok=$enableval +else + ntp_ok=$ntp_eac fi -done - ;; +case "$ntp_atom_ok" in + no) ntp_ok=no ;; esac -for ac_func in uname updwtmp updwtmpx vsnprintf vsprintf -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - -### - -# http://bugs.ntp.org/737 -case "$ac_cv_func_recvmsg" in +case "$ntp_ok" in yes) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need extra help to define struct iovec" >&5 -$as_echo_n "checking if we need extra help to define struct iovec... " >&6; } - if test "${ac_cv_struct_iovec_help+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - for ac_cv_struct_iovec_help in '0' '1'; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#if $ac_cv_struct_iovec_help -#include -#endif + ntp_refclock=yes -void foo(); -void foo() { - ssize_t x; - int s = 0; - struct iovec iov; - struct msghdr mh; - int flags = 0; +$as_echo "#define CLOCK_ATOM 1" >>confdefs.h - mh.msg_iov = &iov; - x = recvmsg(s, &mh, flags); -} -int -main () -{ + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_worked=yes ; break 1 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Chrono-log K-series WWVB receiver" >&5 +$as_echo_n "checking Chrono-log K-series WWVB receiver... " >&6; } +# Check whether --enable-CHRONOLOG was given. +if test "${enable_CHRONOLOG+set}" = set; then : + enableval=$enable_CHRONOLOG; ntp_ok=$enableval else - ac_worked=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done + ntp_ok=$ntp_eac fi - case "$ac_worked$ac_cv_struct_iovec_help" in - yes1) -$as_echo "#define HAVE_SYS_UIO_H 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes + +$as_echo "#define CLOCK_CHRONOLOG 1" >>confdefs.h - ans=yes - ;; - *) ans=no - esac - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -case "$host" in - *-*-sunos4*) +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CHU modem/decoder" >&5 +$as_echo_n "checking CHU modem/decoder... " >&6; } +# Check whether --enable-CHU was given. +if test "${enable_CHU+set}" = set; then : + enableval=$enable_CHU; ntp_ok=$enableval +else + ntp_ok=$ntp_eac -$as_echo "#define SPRINTF_CHAR 1" >>confdefs.h +fi + +case "$ntp_ok" in + yes) + ntp_refclock=yes + +$as_echo "#define CLOCK_CHU 1" >>confdefs.h ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +ntp_refclock_chu=$ntp_ok -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to gettimeofday()" >&5 -$as_echo_n "checking number of arguments to gettimeofday()... " >&6; } -if test "${ac_cv_func_Xettimeofday_nargs+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CHU audio/decoder" >&5 +$as_echo_n "checking CHU audio/decoder... " >&6; } +# Check whether --enable-AUDIO-CHU was given. +if test "${enable_AUDIO_CHU+set}" = set; then : + enableval=$enable_AUDIO_CHU; ntp_ok=$enableval else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -gettimeofday((struct timeval*)0,(struct timezone*)0); -settimeofday((struct timeval*)0,(struct timezone*)0); + case "$ntp_eac$ntp_refclock_chu$ntp_canaudio" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_func_Xettimeofday_nargs=2 -else - ac_cv_func_Xettimeofday_nargs=1 -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_Xettimeofday_nargs" >&5 -$as_echo "$ac_cv_func_Xettimeofday_nargs" >&6; } -if test $ac_cv_func_Xettimeofday_nargs = 1; then - -$as_echo "#define SYSV_TIMEOFDAY 1" >>confdefs.h -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +# We used to check for sunos/solaris target... +case "$ntp_ok$ntp_refclock_chu$ntp_canaudio" in + yes*no*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is...no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is...no ***" >&2;} +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments taken by setpgrp()" >&5 -$as_echo_n "checking number of arguments taken by setpgrp()... " >&6; } -if test "${ac_cv_func_setpgrp_nargs+set}" = set; then : - $as_echo_n "(cached) " >&6 +# Not under HP-UX +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Datum Programmable Time System" >&5 +$as_echo_n "checking Datum Programmable Time System... " >&6; } +# Check whether --enable-DATUM was given. +if test "${enable_DATUM+set}" = set; then : + enableval=$enable_DATUM; ntp_ok=$enableval else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif + case "$ac_cv_header_termios_h" in + yes) + ntp_ok=$ntp_eac + ;; + *) ntp_ok=no + ;; + esac -int -main () -{ -setpgrp(0,0); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_func_setpgrp_nargs=2 -else - ac_cv_func_setpgrp_nargs=0 -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_nargs" >&5 -$as_echo "$ac_cv_func_setpgrp_nargs" >&6; } -if test $ac_cv_func_setpgrp_nargs = 0; then -$as_echo "#define HAVE_SETPGRP_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes -fi +$as_echo "#define CLOCK_DATUM 1" >>confdefs.h -save_CFLAGS=$CFLAGS -CFLAGS="$CFLAGS -I$srcdir/include" + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking argument pointer type of qsort()'s compare function and base" >&5 -$as_echo_n "checking argument pointer type of qsort()'s compare function and base... " >&6; } -if test "${ac_cv_func_qsort_argtype+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Dumb generic hh:mm:ss local clock" >&5 +$as_echo_n "checking Dumb generic hh:mm:ss local clock... " >&6; } +# Check whether --enable-DUMBCLOCK was given. +if test "${enable_DUMBCLOCK+set}" = set; then : + enableval=$enable_DUMBCLOCK; ntp_ok=$enableval else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -#include "l_stdlib.h" + ntp_ok=$ntp_eac -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif +fi -extern void *base; -extern sortfunc P((const void *, const void *)); -int sortfunc(a, b) - const void *a; - const void *b; { return 0; } +case "$ntp_ok" in + yes) + ntp_refclock=yes -int -main () -{ +$as_echo "#define CLOCK_DUMBCLOCK 1" >>confdefs.h -qsort(base, 2, sizeof(char *), sortfunc); + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_func_qsort_argtype=void +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Forum Graphic GPS" >&5 +$as_echo_n "checking Forum Graphic GPS... " >&6; } +# Check whether --enable-FG was given. +if test "${enable_FG+set}" = set; then : + enableval=$enable_FG; ntp_ok=$enableval else - ac_cv_func_qsort_argtype=char -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ntp_ok=$ntp_eac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_qsort_argtype" >&5 -$as_echo "$ac_cv_func_qsort_argtype" >&6; } -case "$ac_cv_func_qsort_argtype" in - void) -$as_echo "#define QSORT_USES_VOID_P 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes + +$as_echo "#define CLOCK_FG 1" >>confdefs.h ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -CFLAGS=$save_CFLAGS - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to declare 'errno'" >&5 -$as_echo_n "checking if we need to declare 'errno'... " >&6; } -if test "${ac_cv_decl_errno+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef HAVE_ERRNO_H -#include -#endif -int -main () -{ -errno = 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_decl_errno=no +# Requires modem control +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Heath GC-1000 WWV/WWVH receiver" >&5 +$as_echo_n "checking Heath GC-1000 WWV/WWVH receiver... " >&6; } +# Check whether --enable-HEATH was given. +if test "${enable_HEATH+set}" = set; then : + enableval=$enable_HEATH; ntp_ok=$enableval else - ac_cv_decl_errno=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ntp_ok=$ntp_enable_all_modem_control_clocks + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_decl_errno" >&5 -$as_echo "$ac_cv_decl_errno" >&6; } -case "$ac_cv_decl_errno" in + +case "$ntp_ok" in yes) -$as_echo "#define DECL_ERRNO 1" >>confdefs.h - ;; + ntp_refclock=yes + +$as_echo "#define CLOCK_HEATH 1" >>confdefs.h + + ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we may declare 'h_errno'" >&5 -$as_echo_n "checking if we may declare 'h_errno'... " >&6; } -if test "${ac_cv_decl_h_errno+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef HAVE_NETINET_IN_H -#include -#endif -#ifdef HAVE_ARPA_NAMESER_H -#include -#endif -#ifdef HAVE_NETDB_H -#include -#endif -#ifdef HAVE_RESOLV_H -#include -#endif -int -main () -{ -extern int h_errno; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_decl_h_errno=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hopf serial clock device" >&5 +$as_echo_n "checking for hopf serial clock device... " >&6; } +# Check whether --enable-HOPFSERIAL was given. +if test "${enable_HOPFSERIAL+set}" = set; then : + enableval=$enable_HOPFSERIAL; ntp_ok=$enableval else - ac_cv_decl_h_errno=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ntp_ok=$ntp_eac + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_decl_h_errno" >&5 -$as_echo "$ac_cv_decl_h_errno" >&6; } -case "$ac_cv_decl_h_errno" in + +case "$ntp_ok" in yes) -$as_echo "#define DECL_H_ERRNO 1" >>confdefs.h - ;; + ntp_refclock=yes + +$as_echo "#define CLOCK_HOPF_SERIAL 1" >>confdefs.h + + ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if declaring 'char *sys_errlist[]' is ok" >&5 -$as_echo_n "checking if declaring 'char *sys_errlist[]' is ok... " >&6; } -if test "${ac_cv_decl_sys_errlist+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hopf PCI clock 6039" >&5 +$as_echo_n "checking for hopf PCI clock 6039... " >&6; } +# Check whether --enable-HOPFPCI was given. +if test "${enable_HOPFPCI+set}" = set; then : + enableval=$enable_HOPFPCI; ntp_ok=$enableval else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef HAVE_ERRNO_H -#include -#endif -int -main () -{ -extern char *sys_errlist[]; + ntp_ok=$ntp_eac - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_decl_sys_errlist=yes -else - ac_cv_decl_sys_errlist=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_decl_sys_errlist" >&5 -$as_echo "$ac_cv_decl_sys_errlist" >&6; } -case "$ac_cv_decl_sys_errlist" in + +case "$ntp_ok" in yes) -$as_echo "#define CHAR_SYS_ERRLIST 1" >>confdefs.h - ;; + ntp_refclock=yes + +$as_echo "#define CLOCK_HOPF_PCI 1" >>confdefs.h + + ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if declaring 'syscall()' is ok" >&5 -$as_echo_n "checking if declaring 'syscall()' is ok... " >&6; } -if test "${ac_cv_decl_syscall+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking HP 58503A GPS receiver" >&5 +$as_echo_n "checking HP 58503A GPS receiver... " >&6; } +# Check whether --enable-HPGPS was given. +if test "${enable_HPGPS+set}" = set; then : + enableval=$enable_HPGPS; ntp_ok=$enableval else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + ntp_ok=$ntp_eac -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif +fi -int -main () -{ -extern int syscall P((int, ...)); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_decl_syscall=yes +case "$ntp_ok" in + yes) + ntp_refclock=yes + +$as_echo "#define CLOCK_HPGPS 1" >>confdefs.h + + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking IRIG audio decoder" >&5 +$as_echo_n "checking IRIG audio decoder... " >&6; } +# Check whether --enable-IRIG was given. +if test "${enable_IRIG+set}" = set; then : + enableval=$enable_IRIG; ntp_ok=$enableval else - ac_cv_decl_syscall=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + case "$ntp_eac$ntp_canaudio" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_decl_syscall" >&5 -$as_echo "$ac_cv_decl_syscall" >&6; } -case "$ac_cv_decl_syscall" in + +case "$ntp_ok" in yes) -$as_echo "#define DECL_SYSCALL 1" >>confdefs.h - ;; -esac + ntp_refclock=yes -case "$host" in - *-*-aix4.3.*) +$as_echo "#define CLOCK_IRIG 1" >>confdefs.h -$as_echo "#define DECL_HSTRERROR_0 1" >>confdefs.h - # Needed for XLC under AIX 4.3.2 ;; - *-*-mpeix*) +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canaudio" in + yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} +esac -$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for JJY receiver" >&5 +$as_echo_n "checking for JJY receiver... " >&6; } +# Check whether --enable-JJY was given. +if test "${enable_JJY+set}" = set; then : + enableval=$enable_JJY; ntp_ok=$enableval +else + ntp_ok=$ntp_eac +fi -$as_echo "#define DECL_INET_NTOA_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_JJY 1" >>confdefs.h -$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Rockwell Jupiter GPS receiver" >&5 +$as_echo_n "checking Rockwell Jupiter GPS receiver... " >&6; } +# Check whether --enable-JUPITER was given. +if test "${enable_JUPITER+set}" = set; then : + enableval=$enable_JUPITER; ntp_ok=$enableval +else + ntp_ok=$ntp_eac +fi -$as_echo "#define DECL_SELECT_0 1" >>confdefs.h +case "$ntp_jupiter_ok" in + no) ntp_ok=no ;; +esac +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_JUPITER 1" >>confdefs.h -$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Leitch CSD 5300 Master Clock System Driver" >&5 +$as_echo_n "checking Leitch CSD 5300 Master Clock System Driver... " >&6; } +# Check whether --enable-LEITCH was given. +if test "${enable_LEITCH+set}" = set; then : + enableval=$enable_LEITCH; ntp_ok=$enableval +else + ntp_ok=$ntp_eac -$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h +$as_echo "#define CLOCK_LEITCH 1" >>confdefs.h ;; - *-*-osf[45]*) +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -$as_echo "#define DECL_PLOCK_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking local clock reference" >&5 +$as_echo_n "checking local clock reference... " >&6; } +# Check whether --enable-LOCAL-CLOCK was given. +if test "${enable_LOCAL_CLOCK+set}" = set; then : + enableval=$enable_LOCAL_CLOCK; ntp_ok=$enableval +else + ntp_ok=$ntp_eac +fi -$as_echo "#define DECL_STIME_1 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes + +$as_echo "#define CLOCK_LOCAL 1" >>confdefs.h ;; - *-*-qnx*) +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h - ;; - *-*-riscos4*) +# Not Ultrix +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Magnavox MX4200 GPS receiver" >&5 +$as_echo_n "checking Magnavox MX4200 GPS receiver... " >&6; } +# Check whether --enable-MX4200 was given. +if test "${enable_MX4200+set}" = set; then : + enableval=$enable_MX4200; ntp_ok=$enableval +else -$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h + case "$ac_cv_var_ppsclock" in + yes) + ntp_ok=$ntp_eac + ;; + *) + ntp_ok=no + ;; + esac -$as_echo "#define DECL_BZERO_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h +$as_echo "#define CLOCK_MX4200 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$host" in + yes*-*-ultrix*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} +esac -$as_echo "#define DECL_IPC_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for NeoClock4X receiver" >&5 +$as_echo_n "checking for NeoClock4X receiver... " >&6; } +# Check whether --enable-NEOCLOCK4X was given. +if test "${enable_NEOCLOCK4X+set}" = set; then : + enableval=$enable_NEOCLOCK4X; ntp_ok=$enableval +else + ntp_ok=$ntp_eac +fi -$as_echo "#define DECL_MEMMOVE_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_NEOCLOCK4X 1" >>confdefs.h -$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking NMEA GPS receiver" >&5 +$as_echo_n "checking NMEA GPS receiver... " >&6; } +# Check whether --enable-NMEA was given. +if test "${enable_NMEA+set}" = set; then : + enableval=$enable_NMEA; ntp_ok=$enableval +else + ntp_ok=$ntp_eac -$as_echo "#define DECL_RENAME_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_SELECT_0 1" >>confdefs.h +$as_echo "#define CLOCK_NMEA 1" >>confdefs.h + + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +for ac_func in strtoll +do : + ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll" +if test "x$ac_cv_func_strtoll" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STRTOLL 1 +_ACEOF -$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h +fi +done +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GPSD JSON receiver" >&5 +$as_echo_n "checking for GPSD JSON receiver... " >&6; } +# Check whether --enable-GPSD was given. +if test "${enable_GPSD+set}" = set; then : + enableval=$enable_GPSD; ntp_ok=$enableval +else + case "$ac_cv_func_strtoll" in + yes) ntp_ok=$ntp_eac ;; + *) ntp_ok="no" ;; + esac -$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_STDIO_0 1" >>confdefs.h +$as_echo "#define CLOCK_GPSDJSON 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -$as_echo "#define DECL_STRTOL_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ONCORE Motorola VP/UT Oncore GPS" >&5 +$as_echo_n "checking for ONCORE Motorola VP/UT Oncore GPS... " >&6; } +# Check whether --enable-ONCORE was given. +if test "${enable_ONCORE+set}" = set; then : + enableval=$enable_ONCORE; ntp_ok=$enableval +else + ntp_ok=$ntp_eac +fi -$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h +case "$ntp_oncore_ok" in + no) ntp_ok=no ;; +esac +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_ONCORE 1" >>confdefs.h -$as_echo "#define DECL_TIME_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +# Requires modem control +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Palisade clock" >&5 +$as_echo_n "checking for Palisade clock... " >&6; } +# Check whether --enable-PALISADE was given. +if test "${enable_PALISADE+set}" = set; then : + enableval=$enable_PALISADE; ntp_ok=$enableval +else + ntp_ok=$ntp_enable_all_modem_control_clocks -$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_TOLOWER_0 1" >>confdefs.h +$as_echo "#define CLOCK_PALISADE 1" >>confdefs.h ;; - *-*-solaris2*) - -$as_echo "#define DECL_MKSTEMP_0 1" >>confdefs.h +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Conrad parallel port radio clock" >&5 +$as_echo_n "checking Conrad parallel port radio clock... " >&6; } +# Check whether --enable-PCF was given. +if test "${enable_PCF+set}" = set; then : + enableval=$enable_PCF; ntp_ok=$enableval +else + ntp_ok=$ntp_eac -$as_echo "#define DECL_SETPRIORITY_1 1" >>confdefs.h +fi - case "$host" in - *-*-solaris2.4) +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h +$as_echo "#define CLOCK_PCF 1" >>confdefs.h - ;; - esac ;; - *-*-sunos4*) +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking PST/Traconex 1020 WWV/WWVH receiver" >&5 +$as_echo_n "checking PST/Traconex 1020 WWV/WWVH receiver... " >&6; } +# Check whether --enable-PST was given. +if test "${enable_PST+set}" = set; then : + enableval=$enable_PST; ntp_ok=$enableval +else + ntp_ok=$ntp_eac +fi -$as_echo "#define DECL_BCOPY_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_PST 1" >>confdefs.h -$as_echo "#define DECL_BZERO_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking RIPENCC specific Trimble driver" >&5 +$as_echo_n "checking RIPENCC specific Trimble driver... " >&6; } +# Check whether --enable-RIPENCC was given. +if test "${enable_RIPENCC+set}" = set; then : + enableval=$enable_RIPENCC; ntp_ok=$enableval +else + ntp_ok=no -$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h +fi +# 020629: HMS: s/$ntp_eac -> -/no because of ptr += sprintf(ptr, ...) usage +case "$ntp_ripe_ncc_ok" in + no) ntp_ok=no ;; +esac +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_IPC_0 1" >>confdefs.h +$as_echo "#define CLOCK_RIPENCC /**/" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -$as_echo "#define DECL_MEMMOVE_0 1" >>confdefs.h +# Danny Meyer says SHM compiles (with a few warnings) under Win32. +# For *IX, we need sys/ipc.h and sys/shm.h. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHM clock attached thru shared memory" >&5 +$as_echo_n "checking for SHM clock attached thru shared memory... " >&6; } +# Check whether --enable-SHM was given. +if test "${enable_SHM+set}" = set; then : + enableval=$enable_SHM; ntp_ok=$enableval +else + case "$ntp_eac$ntp_canshm" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac -$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h +fi -$as_echo "#define DECL_MKSTEMP_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_SHM 1" >>confdefs.h -$as_echo "#define DECL_RENAME_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Spectracom 8170/Netclock/2 WWVB receiver" >&5 +$as_echo_n "checking Spectracom 8170/Netclock/2 WWVB receiver... " >&6; } +# Check whether --enable-SPECTRACOM was given. +if test "${enable_SPECTRACOM+set}" = set; then : + enableval=$enable_SPECTRACOM; ntp_ok=$enableval +else + ntp_ok=$ntp_eac -$as_echo "#define DECL_SELECT_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h +$as_echo "#define CLOCK_SPECTRACOM 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking KSI/Odetics TPRO/S GPS receiver/IRIG interface" >&5 +$as_echo_n "checking KSI/Odetics TPRO/S GPS receiver/IRIG interface... " >&6; } +# Check whether --enable-TPRO was given. +if test "${enable_TPRO+set}" = set; then : + enableval=$enable_TPRO; ntp_ok=$enableval +else + case "$ac_cv_header_sys_tpro_h" in + yes) + ntp_ok=$ntp_eac + ;; + *) + ntp_ok=no + ;; + esac -$as_echo "#define DECL_SIGVEC_0 1" >>confdefs.h - case "`basename $ac_cv_prog_CC`" in - acc*) ;; - *) -$as_echo "#define DECL_STDIO_0 1" >>confdefs.h +fi - ;; - esac +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_STRTOL_0 1" >>confdefs.h +$as_echo "#define CLOCK_TPRO 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ac_cv_header_sys_tpro" in + yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} +esac -$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h +# Not on a vax-dec-bsd +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Kinemetrics/TrueTime receivers" >&5 +$as_echo_n "checking Kinemetrics/TrueTime receivers... " >&6; } +# Check whether --enable-TRUETIME was given. +if test "${enable_TRUETIME+set}" = set; then : + enableval=$enable_TRUETIME; ntp_ok=$enableval +else + case "$host" in + vax-dec-bsd) + ntp_ok=no + ;; + *) + ntp_ok=$ntp_eac + ;; + esac -$as_echo "#define DECL_TIME_0 1" >>confdefs.h +fi -$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_TRUETIME 1" >>confdefs.h -$as_echo "#define DECL_TOLOWER_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$host" in + yesvax-dec-bsd) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking TrueTime 560 IRIG-B decoder" >&5 +$as_echo_n "checking TrueTime 560 IRIG-B decoder... " >&6; } +# Check whether --enable-TT560 was given. +if test "${enable_TT560+set}" = set; then : + enableval=$enable_TT560; ntp_ok=$enableval +else + ntp_ok=no -$as_echo "#define DECL_TOUPPER_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_STRERROR_0 1" >>confdefs.h +$as_echo "#define CLOCK_TT560 /**/" >>confdefs.h ;; - *-*-ultrix4*) - -$as_echo "#define DECL_ADJTIME_0 1" >>confdefs.h +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Ultralink M320 WWVB receiver" >&5 +$as_echo_n "checking Ultralink M320 WWVB receiver... " >&6; } +# Check whether --enable-ULINK was given. +if test "${enable_ULINK+set}" = set; then : + enableval=$enable_ULINK; ntp_ok=$enableval +else + ntp_ok=$ntp_eac -$as_echo "#define DECL_BZERO_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_CFSETISPEED_0 1" >>confdefs.h +$as_echo "#define CLOCK_ULINK 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -$as_echo "#define DECL_IOCTL_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Spectracom TSYNC PCI timing board" >&5 +$as_echo_n "checking Spectracom TSYNC PCI timing board... " >&6; } +# Check whether --enable-TSYNCPCI was given. +if test "${enable_TSYNCPCI+set}" = set; then : + enableval=$enable_TSYNCPCI; ntp_ok=$enableval +else + case "$host" in + *-*-*linux*) + ntp_ok=$ntp_eac + ;; + *) + ntp_ok=no + esac -$as_echo "#define DECL_IPC_0 1" >>confdefs.h +fi -$as_echo "#define DECL_MKTEMP_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_TSYNCPCI 1" >>confdefs.h -$as_echo "#define DECL_NLIST_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking WWV receiver" >&5 +$as_echo_n "checking WWV receiver... " >&6; } +# Check whether --enable-WWV was given. +if test "${enable_WWV+set}" = set; then : + enableval=$enable_WWV; ntp_ok=$enableval +else -$as_echo "#define DECL_PLOCK_0 1" >>confdefs.h + case "$ntp_eac$ntp_canaudio" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac -$as_echo "#define DECL_SELECT_0 1" >>confdefs.h +fi +case "$ntp_ok" in + yes) + ntp_refclock=yes -$as_echo "#define DECL_SETITIMER_0 1" >>confdefs.h +$as_echo "#define CLOCK_WWV 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canaudio" in + yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 +$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} +esac -$as_echo "#define DECL_SETPRIORITY_0 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Zyfer receiver" >&5 +$as_echo_n "checking for Zyfer receiver... " >&6; } +# Check whether --enable-ZYFER was given. +if test "${enable_ZYFER+set}" = set; then : + enableval=$enable_ZYFER; ntp_ok=$enableval +else + ntp_ok=$ntp_eac +fi -$as_echo "#define DECL_STIME_0 1" >>confdefs.h +case "$ntp_ok" in + yes) + ntp_refclock=yes +$as_echo "#define CLOCK_ZYFER 1" >>confdefs.h -$as_echo "#define DECL_SYSLOG_0 1" >>confdefs.h + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default inclusion of all suitable PARSE clocks" >&5 +$as_echo_n "checking for default inclusion of all suitable PARSE clocks... " >&6; } +# Check whether --enable-parse-clocks was given. +if test "${enable_parse_clocks+set}" = set; then : + enableval=$enable_parse_clocks; ntp_eapc=$enableval +else -$as_echo "#define DECL_TIMEOFDAY_0 1" >>confdefs.h + case "$ntp_eac" in + yes) ntp_eapc=$ntp_canparse ;; + *) ntp_eapc=no ;; + esac + # Delete the next line one of these days + ntp_eapc=no - ;; -esac -case "$host" in - *-*-sco3.2*) +fi -$as_echo "#define TERMIOS_NEEDS__SVID3 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_eapc" >&5 +$as_echo "$ntp_eapc" >&6; } +case "$ntp_eac$ntp_eapc$ntp_canparse" in + noyes*) + as_fn_error $? "\"--enable-parse-clocks\" requires \"--enable-all-clocks\"." "$LINENO" 5 + ;; + yesyesno) + as_fn_error $? "You said \"--enable-parse-clocks\" but PARSE isn't supported on this platform!" "$LINENO" 5 ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need extra room for SO_RCVBUF" >&5 -$as_echo_n "checking if we need extra room for SO_RCVBUF... " >&6; } -if test "${ac_cv_var_rcvbuf_slop+set}" = set; then : - $as_echo_n "(cached) " >&6 +ntp_libparse=no +ntp_parseutil=no +ntp_rawdcf=no + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Diem Computime Radio Clock" >&5 +$as_echo_n "checking Diem Computime Radio Clock... " >&6; } +# Check whether --enable-COMPUTIME was given. +if test "${enable_COMPUTIME+set}" = set; then : + enableval=$enable_COMPUTIME; ntp_ok=$enableval else - ans=no -case "$host" in - *-*-hpux[567]*) - ans=yes - ;; -esac -ac_cv_var_rcvbuf_slop=$ans + ntp_ok=$ntp_eapc + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_rcvbuf_slop" >&5 -$as_echo "$ac_cv_var_rcvbuf_slop" >&6; } -case "$ac_cv_var_rcvbuf_slop" in + +case "$ntp_ok" in yes) -$as_echo "#define NEED_RCVBUF_SLOP 1" >>confdefs.h - ;; -esac + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_COMPUTIME 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will open the broadcast socket" >&5 -$as_echo_n "checking if we will open the broadcast socket... " >&6; } -if test "${ac_cv_var_open_bcast_socket+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans=yes -case "$host" in - *-*-domainos) - ans=no ;; esac -ac_cv_var_open_bcast_socket=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_open_bcast_socket" >&5 -$as_echo "$ac_cv_var_open_bcast_socket" >&6; } -case "$ac_cv_var_open_bcast_socket" in - yes) -$as_echo "#define OPEN_BCAST_SOCKET 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the HPUX version of FindConfig()" >&5 -$as_echo_n "checking if we want the HPUX version of FindConfig()... " >&6; } -if test "${ac_cv_var_hpux_findconfig+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ELV/DCF7000 clock" >&5 +$as_echo_n "checking ELV/DCF7000 clock... " >&6; } +# Check whether --enable-DCF7000 was given. +if test "${enable_DCF7000+set}" = set; then : + enableval=$enable_DCF7000; ntp_ok=$enableval else - ans=no -case "$host" in - *-*-hpux*) - ans=yes - ;; -esac -ac_cv_var_hpux_findconfig=$ans + ntp_ok=$ntp_eapc + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_hpux_findconfig" >&5 -$as_echo "$ac_cv_var_hpux_findconfig" >&6; } -case "$ac_cv_var_hpux_findconfig" in + +case "$ntp_ok" in yes) -$as_echo "#define NEED_HPUX_FINDCONFIG 1" >>confdefs.h - ;; -esac + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_DCF7000 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if process groups are set with -pid" >&5 -$as_echo_n "checking if process groups are set with -pid... " >&6; } -if test "${ac_cv_arg_setpgrp_negpid+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case "$host" in - *-*-hpux[567]*) - ans=no - ;; - *-*-hpux*) - ans=yes - ;; - *-*-*linux*) - ans=yes - ;; - *-*-sunos3*) - ans=yes - ;; - *-*-ultrix2*) - ans=yes - ;; - *) - ans=no ;; esac -ac_cv_arg_setpgrp_negpid=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_arg_setpgrp_negpid" >&5 -$as_echo "$ac_cv_arg_setpgrp_negpid" >&6; } -case "$ac_cv_arg_setpgrp_negpid" in - yes) -$as_echo "#define UDP_BACKWARDS_SETOWN 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need a ctty for F_SETOWN" >&5 -$as_echo_n "checking if we need a ctty for F_SETOWN... " >&6; } -if test "${ac_cv_func_ctty_for_f_setown+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking HOPF 6021 clock" >&5 +$as_echo_n "checking HOPF 6021 clock... " >&6; } +# Check whether --enable-HOPF6021 was given. +if test "${enable_HOPF6021+set}" = set; then : + enableval=$enable_HOPF6021; ntp_ok=$enableval else - case "$host" in - *-*-bsdi[23]*) - ans=yes - ;; - *-*-freebsd*) - ans=yes - ;; - *-*-netbsd*3.[0-8]*|*-*-netbsd*[0-2].*|*-*-netbsd*3.99.[0-7]) - ans=yes - ;; - *-*-openbsd*) - ans=yes - ;; - *-*-osf*) - ans=yes - ;; - *-*-darwin*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_func_ctty_for_f_setown=$ans + ntp_ok=$ntp_eapc + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_ctty_for_f_setown" >&5 -$as_echo "$ac_cv_func_ctty_for_f_setown" >&6; } -case "$ac_cv_func_ctty_for_f_setown" in + +case "$ntp_ok" in yes) -$as_echo "#define USE_FSETOWNCTTY 1" >>confdefs.h - ;; -esac + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_HOPF6021 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the OS fails to clear cached routes when more specific routes become available" >&5 -$as_echo_n "checking if the OS fails to clear cached routes when more specific routes become available... " >&6; } -if test "${ac_cv_os_routeupdates+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case "$host" in - *-*-netbsd*) - ans=yes - ;; - *) ans=no ;; esac -ac_cv_os_routeupdates=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_routeupdates" >&5 -$as_echo "$ac_cv_os_routeupdates" >&6; } -case "$ac_cv_os_routeupdates" in - yes) -$as_echo "#define OS_MISSES_SPECIFIC_ROUTE_UPDATES 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the OS needs the wildcard socket set to REUSEADDR for binding interface addresses" >&5 -$as_echo_n "checking if the OS needs the wildcard socket set to REUSEADDR for binding interface addresses... " >&6; } -if test "${ac_cv_os_wildcardreuse+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Meinberg clocks" >&5 +$as_echo_n "checking Meinberg clocks... " >&6; } +# Check whether --enable-MEINBERG was given. +if test "${enable_MEINBERG+set}" = set; then : + enableval=$enable_MEINBERG; ntp_ok=$enableval else - case "$host" in - *-*-*linux*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_os_wildcardreuse=$ans + ntp_ok=$ntp_eapc + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_wildcardreuse" >&5 -$as_echo "$ac_cv_os_wildcardreuse" >&6; } -case "$ac_cv_os_wildcardreuse" in - yes) -$as_echo "#define OS_NEEDS_REUSEADDR_FOR_IFADDRBIND 1" >>confdefs.h - ;; -esac -ntp_warning='GRONK' -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we'll use clock_settime or settimeofday or stime" >&5 -$as_echo_n "checking if we'll use clock_settime or settimeofday or stime... " >&6; } -case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in - yes*) - ntp_warning='' - ans='clock_settime()' - ;; - noyes*) - ntp_warning='But clock_settime() would be better (if we had it)' - ans='settimeofday()' - ;; - nonoyes) - ntp_warning='Which is the worst of the three' - ans='stime()' - ;; - *) - case "$build" in - $host) ntp_warning='Which leaves us with nothing to use!' - ans=none - ;; -esac -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } -case "$ntp_warning" in - '') ;; - *) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** $ntp_warning ***" >&5 -$as_echo "$as_me: WARNING: *** $ntp_warning ***" >&2;} - ;; -esac +case "$ntp_ok" in + yes) + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_MEINBERG 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have a losing syscall()" >&5 -$as_echo_n "checking if we have a losing syscall()... " >&6; } -if test "${ac_cv_var_syscall_bug+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case "$host" in - *-*-solaris2.4*) - ans=yes - ;; - *) ans=no ;; esac -ac_cv_var_syscall_bug=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_syscall_bug" >&5 -$as_echo "$ac_cv_var_syscall_bug" >&6; } -case "$ac_cv_var_syscall_bug" in - yes) -$as_echo "#define SYSCALL_BUG 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGIO" >&5 -$as_echo_n "checking for SIGIO... " >&6; } -if test "${ac_cv_hdr_def_sigio+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef SIGIO - yes -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_hdr_def_sigio=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking DCF77 raw time code" >&5 +$as_echo_n "checking DCF77 raw time code... " >&6; } +# Check whether --enable-RAWDCF was given. +if test "${enable_RAWDCF+set}" = set; then : + enableval=$enable_RAWDCF; ntp_ok=$enableval else - ac_cv_hdr_def_sigio=no -fi -rm -f conftest* + ntp_ok=$ntp_eapc fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_hdr_def_sigio" >&5 -$as_echo "$ac_cv_hdr_def_sigio" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use signalled IO" >&5 -$as_echo_n "checking if we want to use signalled IO... " >&6; } -if test "${ac_cv_var_signalled_io+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans=no -case "$ac_cv_hdr_def_sigio" in +case "$ntp_ok" in yes) - ans=yes - case "$host" in - alpha*-dec-osf4*|alpha*-dec-osf5*) - ans=no - ;; - *-convex-*) - ans=no - ;; - *-dec-*) - ans=no - ;; - *-pc-cygwin*) - ans=no - ;; - *-sni-sysv*) - ans=no - ;; - *-univel-sysv*) - ans=no - ;; - *-*-irix6*) - ans=no - ;; - *-*-freebsd*) - ans=no - ;; - *-*-*linux*) - ans=no - ;; - *-*-unicosmp*) - ans=no - ;; - esac + ntp_libparse=yes + ntp_parseutil=yes + ntp_refclock=yes + ntp_rawdcf=yes + +$as_echo "#define CLOCK_RAWDCF 1" >>confdefs.h + ;; esac -ac_cv_var_signalled_io=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_signalled_io" >&5 -$as_echo "$ac_cv_var_signalled_io" >&6; } -case "$ac_cv_var_signalled_io" in - yes) -$as_echo "#define HAVE_SIGNALED_IO 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGPOLL" >&5 -$as_echo_n "checking for SIGPOLL... " >&6; } -if test "${ac_cv_hdr_def_sigpoll+set}" = set; then : +case "$ntp_rawdcf" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we must enable parity for RAWDCF" >&5 +$as_echo_n "checking if we must enable parity for RAWDCF... " >&6; } +if ${ntp_cv_rawdcf_parity+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef SIGPOLL - yes -#endif -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_hdr_def_sigpoll=yes -else - ac_cv_hdr_def_sigpoll=no -fi -rm -f conftest* + ans=no + case "$host" in + *-*-*linux*) + ans=yes + ;; + esac + ntp_cv_rawdcf_parity=$ans + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_hdr_def_sigpoll" >&5 -$as_echo "$ac_cv_hdr_def_sigpoll" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_rawdcf_parity" >&5 +$as_echo "$ntp_cv_rawdcf_parity" >&6; } + case "$ntp_cv_rawdcf_parity" in + yes) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGSYS" >&5 -$as_echo_n "checking for SIGSYS... " >&6; } -if test "${ac_cv_hdr_def_sigsys+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef SIGSYS - yes -#endif +$as_echo "#define RAWDCF_NO_IGNPAR 1" >>confdefs.h + ;; + esac +esac -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_hdr_def_sigsys=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking RCC 8000 clock" >&5 +$as_echo_n "checking RCC 8000 clock... " >&6; } +# Check whether --enable-RCC8000 was given. +if test "${enable_RCC8000+set}" = set; then : + enableval=$enable_RCC8000; ntp_ok=$enableval else - ac_cv_hdr_def_sigsys=no -fi -rm -f conftest* + ntp_ok=$ntp_eapc fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_hdr_def_sigsys" >&5 -$as_echo "$ac_cv_hdr_def_sigsys" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for UDP I/O" >&5 -$as_echo_n "checking if we can use SIGPOLL for UDP I/O... " >&6; } -if test "${ac_cv_var_use_udp_sigpoll+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans=no -case "$ac_cv_hdr_def_sigpoll" in +case "$ntp_ok" in yes) - case "$host" in - mips-sgi-irix*) - ans=no - ;; - vax-dec-bsd) - ans=no - ;; - *-pc-cygwin*) - ans=no - ;; - *-sni-sysv*) - ans=no - ;; - *-*-aix[456]*) - ans=no - ;; - *-*-hpux*) - ans=no - ;; - *-*-*linux*) - ans=no - ;; - *-*-osf*) - ans=no - ;; - *-*-qnx*) - ans=no - ;; - *-*-sunos*) - ans=no - ;; - *-*-solaris*) - ans=no - ;; - *-*-ultrix*) - ans=no - ;; - *-*-unicosmp*) - ans=no - ;; - *) ans=yes - ;; - esac + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_RCC8000 1" >>confdefs.h + ;; esac -ac_cv_var_use_udp_sigpoll=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_use_udp_sigpoll" >&5 -$as_echo "$ac_cv_var_use_udp_sigpoll" >&6; } -case "$ac_cv_var_use_udp_sigpoll" in - yes) -$as_echo "#define USE_UDP_SIGPOLL 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for TTY I/O" >&5 -$as_echo_n "checking if we can use SIGPOLL for TTY I/O... " >&6; } -if test "${ac_cv_var_use_tty_sigpoll+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Schmid DCF77 clock" >&5 +$as_echo_n "checking Schmid DCF77 clock... " >&6; } +# Check whether --enable-SCHMID was given. +if test "${enable_SCHMID+set}" = set; then : + enableval=$enable_SCHMID; ntp_ok=$enableval else - ans=no -case "$ac_cv_hdr_def_sigpoll" in + ntp_ok=$ntp_eapc + +fi + +case "$ntp_ok" in yes) - case "$host" in - mips-sgi-irix*) - ans=no - ;; - vax-dec-bsd) - ans=no - ;; - *-pc-cygwin*) - ans=no - ;; - *-sni-sysv*) - ans=no - ;; - *-*-aix[456]*) - ans=no - ;; - *-*-hpux*) - ans=no - ;; - *-*-*linux*) - ans=no - ;; - *-*-osf*) - ans=no - ;; - *-*-sunos*) - ans=no - ;; - *-*-ultrix*) - ans=no - ;; - *-*-qnx*) - ans=no - ;; - *-*-unicosmp*) - ans=no - ;; - *) ans=yes - ;; - esac + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_SCHMID 1" >>confdefs.h + ;; esac -ac_cv_var_use_tty_sigpoll=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_use_tty_sigpoll" >&5 -$as_echo "$ac_cv_var_use_tty_sigpoll" >&6; } -case "$ac_cv_var_use_tty_sigpoll" in - yes) -$as_echo "#define USE_TTY_SIGPOLL 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -case "$ac_cv_header_sys_sio_h" in - yes) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/sio.h for TIOCDCDTIMESTAMP" >&5 -$as_echo_n "checking sys/sio.h for TIOCDCDTIMESTAMP... " >&6; } -if test "${ac_cv_hdr_def_tiocdcdtimestamp+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Trimble GPS receiver/TAIP protocol" >&5 +$as_echo_n "checking Trimble GPS receiver/TAIP protocol... " >&6; } +# Check whether --enable-TRIMTAIP was given. +if test "${enable_TRIMTAIP+set}" = set; then : + enableval=$enable_TRIMTAIP; ntp_ok=$enableval else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef TIOCDCDTIMESTAMP - yes -#endif + ntp_ok=$ntp_eapc -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_hdr_def_tiocdcdtimestamp=yes +fi + +case "$ntp_ok" in + yes) + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_TRIMTAIP 1" >>confdefs.h + + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Trimble GPS receiver/TSIP protocol" >&5 +$as_echo_n "checking Trimble GPS receiver/TSIP protocol... " >&6; } +# Check whether --enable-TRIMTSIP was given. +if test "${enable_TRIMTSIP+set}" = set; then : + enableval=$enable_TRIMTSIP; ntp_ok=$enableval else - ac_cv_hdr_def_tiocdcdtimestamp=no -fi -rm -f conftest* + ntp_ok=$ntp_eapc fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_hdr_def_tiocdcdtimestamp" >&5 -$as_echo "$ac_cv_hdr_def_tiocdcdtimestamp" >&6; } - ;; -esac -case "$ac_cv_hdr_def_tiocdcdtimestamp" in +case "$ntp_ok" in yes) - ac_cv_var_oncore_ok=yes - ;; -esac + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_TRIMTSIP 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if nlist() values might require extra indirection" >&5 -$as_echo_n "checking if nlist() values might require extra indirection... " >&6; } -if test "${ac_cv_var_nlist_extra_indirection+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans=no -case "$host" in - *-*-aix*) - ans=yes ;; esac -ac_cv_var_nlist_extra_indirection=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_nlist_extra_indirection" >&5 -$as_echo "$ac_cv_var_nlist_extra_indirection" >&6; } -case "$ac_cv_var_nlist_extra_indirection" in - yes) -$as_echo "#define NLIST_EXTRA_INDIRECTION 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a minimum recommended value of tickadj" >&5 -$as_echo_n "checking for a minimum recommended value of tickadj... " >&6; } -if test "${ac_cv_var_min_rec_tickadj+set}" = set; then : - $as_echo_n "(cached) " >&6 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking WHARTON 400A Series clock" >&5 +$as_echo_n "checking WHARTON 400A Series clock... " >&6; } +# Check whether --enable-WHARTON was given. +if test "${enable_WHARTON+set}" = set; then : + enableval=$enable_WHARTON; ntp_ok=$enableval else - ans=no -case "$host" in - *-*-aix*) - ans=40 - ;; -esac -ac_cv_var_min_rec_tickadj=$ans + ntp_ok=$ntp_eapc + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_min_rec_tickadj" >&5 -$as_echo "$ac_cv_var_min_rec_tickadj" >&6; } -case "$ac_cv_var_min_rec_tickadj" in - ''|no) ;; - *) -cat >>confdefs.h <<_ACEOF -#define MIN_REC_TICKADJ $ac_cv_var_min_rec_tickadj -_ACEOF - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the TTY code permits PARENB and IGNPAR" >&5 -$as_echo_n "checking if the TTY code permits PARENB and IGNPAR... " >&6; } -if test "${ac_cv_var_no_parenb_ignpar+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans=no -case "$host" in - i?86-*-*linux*) - ans=yes - ;; - mips-sgi-irix*) - ans=yes - ;; - i?86-*-freebsd[123].*) - ;; - i?86-*-freebsd*) - ans=yes - ;; - *-*-unicosmp*) - ans=yes +case "$ntp_ok" in + yes) + ntp_libparse=yes + ntp_refclock=yes + +$as_echo "#define CLOCK_WHARTON_400A 1" >>confdefs.h + ;; esac -ac_cv_var_no_parenb_ignpar=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_no_parenb_ignpar" >&5 -$as_echo "$ac_cv_var_no_parenb_ignpar" >&6; } -case "$ac_cv_var_no_parenb_ignpar" in - yes) -$as_echo "#define NO_PARENB_IGNPAR 1" >>confdefs.h - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including debugging code" >&5 -$as_echo_n "checking if we're including debugging code... " >&6; } -# Check whether --enable-debugging was given. -if test "${enable_debugging+set}" = set; then : - enableval=$enable_debugging; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking VARITEXT clock" >&5 +$as_echo_n "checking VARITEXT clock... " >&6; } +# Check whether --enable-VARITEXT was given. +if test "${enable_VARITEXT+set}" = set; then : + enableval=$enable_VARITEXT; ntp_ok=$enableval else - ntp_ok=yes + ntp_ok=$ntp_eapc + fi -if test "$ntp_ok" = "yes"; then +case "$ntp_ok" in + yes) + ntp_libparse=yes + ntp_refclock=yes -$as_echo "#define DEBUG 1" >>confdefs.h +$as_echo "#define CLOCK_VARITEXT 1" >>confdefs.h -fi + ;; +esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 $as_echo "$ntp_ok" >&6; } +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we including processing time debugging code" >&5 -$as_echo_n "checking if we including processing time debugging code... " >&6; } -# Check whether --enable-debug-timing was given. -if test "${enable_debug_timing+set}" = set; then : - enableval=$enable_debug_timing; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SEL240X clock" >&5 +$as_echo_n "checking SEL240X clock... " >&6; } +# Check whether --enable-SEL240X was given. +if test "${enable_SEL240X+set}" = set; then : + enableval=$enable_SEL240X; ntp_ok=$enableval else - ntp_ok=no + ntp_ok=$ntp_eapc fi if test "$ntp_ok" = "yes"; then + ntp_libparse=yes + ntp_refclock=yes -$as_echo "#define DEBUG_TIMING 1" >>confdefs.h +$as_echo "#define CLOCK_SEL240X 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 $as_echo "$ntp_ok" >&6; } - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a the number of minutes in a DST adjustment" >&5 -$as_echo_n "checking for a the number of minutes in a DST adjustment... " >&6; } -# Check whether --enable-dst_minutes was given. -if test "${enable_dst_minutes+set}" = set; then : - enableval=$enable_dst_minutes; ans=$enableval -else - ans=60 - -fi +case "$ntp_ok$ntp_canparse" in + yesno) + as_fn_error $? "That's a parse clock and this system doesn't support it!" "$LINENO" 5 + ;; +esac -cat >>confdefs.h <<_ACEOF -#define DSTMINUTES $ans -_ACEOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpd will retry on permanent DNS errors" >&5 -$as_echo_n "checking if ntpd will retry on permanent DNS errors... " >&6; } -# Check whether --enable-ignore-dns-errors was given. -if test "${enable_ignore_dns_errors+set}" = set; then : - enableval=$enable_ignore_dns_errors; ans=$enableval -else - ans=no -fi -case "$ans" in +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to make and use the parse libraries" >&5 +$as_echo_n "checking if we need to make and use the parse libraries... " >&6; } +ans=no +case "$ntp_libparse" in yes) + ans=yes -$as_echo "#define IGNORE_DNS_ERRORS 1" >>confdefs.h +$as_echo "#define CLOCK_PARSE 1" >>confdefs.h + LIBPARSE=../libparse/libparse.a + MAKE_LIBPARSE=libparse.a + # HMS: check_y2k trips the 34 year problem now... + false && MAKE_CHECK_Y2K=check_y2k esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 $as_echo "$ans" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have the tty_clk line discipline/streams module" >&5 -$as_echo_n "checking if we have the tty_clk line discipline/streams module... " >&6; } -if test "${ac_cv_var_tty_clk+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case "$ac_cv_header_sys_clkdefs_h$ac_cv_hdr_def_tiocdcdtimestamp" in - *yes*) ac_cv_var_tty_clk=yes ;; - *) ac_cv_var_tty_clk=no ;; - esac + + + +VER_SUFFIX= + + + + +# Check whether --with-crypto was given. +if test "${with_crypto+set}" = set; then : + withval=$with_crypto; fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tty_clk" >&5 -$as_echo "$ac_cv_var_tty_clk" >&6; } -case "$ac_cv_var_tty_clk" in - yes) -$as_echo "#define TTYCLK 1" >>confdefs.h - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the ppsclock streams module" >&5 -$as_echo_n "checking for the ppsclock streams module... " >&6; } -if test "${ac_cv_var_ppsclock+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_var_ppsclock=$ac_cv_struct_ppsclockev + +# Check whether --with-openssl-libdir was given. +if test "${with_openssl_libdir+set}" = set; then : + withval=$with_openssl_libdir; fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_ppsclock" >&5 -$as_echo "$ac_cv_var_ppsclock" >&6; } -case "$ac_cv_var_ppsclock" in - yes) -$as_echo "#define PPS 1" >>confdefs.h - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for kernel multicast support" >&5 -$as_echo_n "checking for kernel multicast support... " >&6; } -if test "${ac_cv_var_mcast+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_var_mcast=no - case "$host" in - i386-sequent-sysv4) ;; - *) cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef IP_ADD_MEMBERSHIP - yes -#endif -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_var_mcast=yes +# Check whether --with-openssl-incdir was given. +if test "${with_openssl_incdir+set}" = set; then : + withval=$with_openssl_incdir; fi -rm -f conftest* - ;; - esac + + +# Check whether --with-rpath was given. +if test "${with_rpath+set}" = set; then : + withval=$with_rpath; fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_mcast" >&5 -$as_echo "$ac_cv_var_mcast" >&6; } -case "$ac_cv_var_mcast" in - yes) -$as_echo "#define MCAST 1" >>confdefs.h +ntp_openssl=no +ntp_openssl_from_pkg_config=no +with_crypto=${with_crypto:-openssl,libcrypto} +case "$with_crypto" in + yes) + with_crypto=openssl,libcrypto +esac +case "$with_crypto:${PKG_CONFIG:+notempty}:${with_openssl_libdir-notgiven}:${with_openssl_incdir-notgiven}" in + no:*) ;; + *:notempty:notgiven:notgiven) + for pkg in `echo $with_crypto | sed -e 's/,/ /'`; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config for $pkg" >&5 +$as_echo_n "checking pkg-config for $pkg... " >&6; } + if $PKG_CONFIG --exists $pkg ; then + CPPFLAGS_NTP="$CPPFLAGS_NTP `$PKG_CONFIG --cflags-only-I $pkg`" + CFLAGS_NTP="$CFLAGS_NTP `$PKG_CONFIG --cflags-only-other $pkg`" + LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-L $pkg`" + LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-l $pkg`" + LDFLAGS_NTP="$LDFLAGS_NTP `$PKG_CONFIG --libs-only-other $pkg`" + VER_SUFFIX=o + ntp_openssl=yes + ntp_openssl_from_pkg_config=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for IP*_MULTICAST_LOOP for setsockopt()" >&5 -$as_echo_n "checking arg type needed for IP*_MULTICAST_LOOP for setsockopt()... " >&6; } -if test "${ac_cv_var_typeof_ip_multicast_loop+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case "$host" in - *-*-netbsd*|*-*-*linux*) - ac_cv_var_typeof_ip_multicast_loop=u_int + break + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + done +esac +case "$with_crypto:$ntp_openssl" in + no:*) ;; + *:no) + need_dash_r= + need_dash_Wlrpath= + case "${with_rpath-notgiven}" in + yes) + # Lame - what to do if we need -Wl... but not -R? + need_dash_r=1 + ;; + notgiven) + case "$host" in + *-*-linux*) + # This may really only be true for gcc + need_dash_Wlrpath=1 ;; - *-*-winnt*) - ac_cv_var_typeof_ip_multicast_loop=BOOL + *-*-netbsd*) + need_dash_r=1 ;; - *) ac_cv_var_typeof_ip_multicast_loop=u_char + *-*-solaris*) + need_dash_r=1 ;; esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_typeof_ip_multicast_loop" >&5 -$as_echo "$ac_cv_var_typeof_ip_multicast_loop" >&6; } - -cat >>confdefs.h <<_ACEOF -#define TYPEOF_IP_MULTICAST_LOOP $ac_cv_var_typeof_ip_multicast_loop -_ACEOF - - ;; -esac - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking availability of ntp_{adj,get}time()" >&5 -$as_echo_n "checking availability of ntp_{adj,get}time()... " >&6; } -if test "${ac_cv_var_ntp_syscalls+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_var_ntp_syscalls=no - case "$ac_cv_func_ntp_adjtime$ac_cv_func_ntp_gettime$ac_cv_func___adjtimex" in - yesyes*) - ac_cv_var_ntp_syscalls=libc - ;; - *yes) - ac_cv_var_ntp_syscalls=inline - ;; - *) cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#if defined(SYS_ntp_gettime) && defined(SYS_ntp_adjtime) - yes -#endif + ;; + esac -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_var_ntp_syscalls=kernel -fi -rm -f conftest* + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5 +$as_echo_n "checking for openssl library directory... " >&6; } + with_openssl_libdir=${with_openssl_libdir-notgiven} + case "$with_openssl_libdir" in + notgiven) + case "$build" in + $host) + with_openssl_libdir=default + ;; + *) + with_openssl_libdir=no + ;; + esac + esac + case "$with_openssl_libdir" in + default) + # Look in: + with_openssl_libdir="/usr/lib /usr/lib/openssl /usr/sfw/lib" + with_openssl_libdir="$with_openssl_libdir /usr/local/lib" + with_openssl_libdir="$with_openssl_libdir /usr/local/ssl/lib /lib" + esac + case "$with_openssl_libdir" in + no) + ;; + *) # Look for libcrypto.a and libssl.a: + for i in $with_openssl_libdir no + do + case "$host" in + *-*-darwin*) + test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break + ;; + *) + test -f $i/libcrypto.so -a -f $i/libssl.so && break + test -f $i/libcrypto.a -a -f $i/libssl.a && break + ;; + esac + done + openssl_libdir=$i + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_libdir" >&5 +$as_echo "$openssl_libdir" >&6; } + case "$openssl_libdir" in + no) + openssl_libdir= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&5 +$as_echo "$as_me: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&2;} + esac - ;; - esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_ntp_syscalls" >&5 -$as_echo "$ac_cv_var_ntp_syscalls" >&6; } -case "$ac_cv_var_ntp_syscalls" in - libc) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl include directory" >&5 +$as_echo_n "checking for openssl include directory... " >&6; } + with_openssl_incdir=${with_openssl_incdir-notgiven} + case "$with_openssl_incdir" in + notgiven) + # Look in: + with_openssl_incdir="/usr/include /usr/sfw/include" + with_openssl_incdir="$with_openssl_incdir /usr/local/include" + with_openssl_incdir="$with_openssl_incdir /usr/local/ssl/include" + esac + case "$with_openssl_incdir" in + no) + ;; + *) # look for openssl/evp.h: + for i in $with_openssl_incdir no + do + test -f $i/openssl/evp.h && break + done + openssl_incdir=$i + ;; + esac + { i=; unset i;} + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_incdir" >&5 +$as_echo "$openssl_incdir" >&6; } + case "$openssl_incdir" in + no) + openssl_incdir= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&5 +$as_echo "$as_me: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&2;} + esac + if test -z "$openssl_libdir" -o -z "$openssl_incdir" + then + ntp_openssl=no + else + ntp_openssl=yes + VER_SUFFIX=o + fi + case "$ntp_openssl" in + yes) + # We have OpenSSL inc/lib dirs - use them. + case "$openssl_incdir" in + /usr/include) + ;; + *) + CPPFLAGS_NTP="$CPPFLAGS_NTP -I$openssl_incdir" + ;; + esac + case "$openssl_libdir" in + /usr/lib) + ;; + *) + LDADD_NTP="$LDADD_NTP -L$openssl_libdir" + case "$need_dash_r" in + 1) + LDFLAGS_NTP="$LDFLAGS_NTP -R$openssl_libdir" + esac + case "$need_dash_Wlrpath" in + 1) + LDFLAGS_NTP="$LDFLAGS_NTP -Wl,-rpath,$openssl_libdir" + esac + ;; + esac + LDADD_NTP="$LDADD_NTP -lcrypto" + esac +esac -$as_echo "#define NTP_SYSCALLS_LIBC 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will use crypto" >&5 +$as_echo_n "checking if we will use crypto... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_openssl" >&5 +$as_echo "$ntp_openssl" >&6; } - ;; - kernel) +case "$ntp_openssl" in + yes) -$as_echo "#define NTP_SYSCALLS_STD 1" >>confdefs.h +$as_echo "#define OPENSSL /**/" >>confdefs.h - ;; - *) + case "$VER_SUFFIX" in + *o*) ;; + *) as_fn_error $? "OPENSSL set but no 'o' in VER_SUFFIX!" "$LINENO" 5 ;; + esac ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sys/timex.h has STA_FLL" >&5 -$as_echo_n "checking if sys/timex.h has STA_FLL... " >&6; } -if test "${ac_cv_var_sta_fll+set}" = set; then : +NTPO_SAVED_CPPFLAGS="$CPPFLAGS" +CPPFLAGS="$CPPFLAGS $CPPFLAGS_NTP" +NTPO_SAVED_LIBS="$LIBS" + +# +# check for linking with -lcrypto failure, and try -lcrypto -lz. +# Helps m68k-atari-mint +# +case "$ntp_openssl:$ntp_openssl_from_pkg_config" in + yes:no) + LIBS="$NTPO_SAVED_LIBS $LDADD_NTP" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto alone works" >&5 +$as_echo_n "checking if linking with -lcrypto alone works... " >&6; } +if ${ntp_cv_bare_lcrypto+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#ifdef STA_FLL - yes -#endif + #include "openssl/err.h" + #include "openssl/evp.h" + +int +main () +{ + + ERR_load_crypto_strings(); + OpenSSL_add_all_algorithms(); + + + ; + return 0; +} _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ac_cv_var_sta_fll=yes +if ac_fn_c_try_link "$LINENO"; then : + ntp_cv_bare_lcrypto=yes else - ac_cv_var_sta_fll=no -fi -rm -f conftest* + ntp_cv_bare_lcrypto=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_sta_fll" >&5 -$as_echo "$ac_cv_var_sta_fll" >&6; } +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have kernel PLL support" >&5 -$as_echo_n "checking if we have kernel PLL support... " >&6; } -if test "${ac_cv_var_kernel_pll+set}" = set; then : +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_bare_lcrypto" >&5 +$as_echo "$ntp_cv_bare_lcrypto" >&6; } + case "$ntp_cv_bare_lcrypto" in + no) + LIBS="$NTPO_SAVED_LIBS $LDADD_NTP -lz" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto -lz works" >&5 +$as_echo_n "checking if linking with -lcrypto -lz works... " >&6; } +if ${ntp_cv_lcrypto_lz+:} false; then : $as_echo_n "(cached) " >&6 else - case "$ac_cv_header_sys_timex_h$ac_cv_struct_ntptimeval$ac_cv_var_sta_fll$ac_cv_var_ntp_syscalls" in - *no*) - ac_cv_var_kernel_pll=no - ;; - *) ac_cv_var_kernel_pll=yes - ;; -esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_kernel_pll" >&5 -$as_echo "$ac_cv_var_kernel_pll" >&6; } -case "$ac_cv_var_kernel_pll" in - yes) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -$as_echo "#define KERNEL_PLL 1" >>confdefs.h + #include "openssl/err.h" + #include "openssl/evp.h" - ;; -esac +int +main () +{ -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if SIOCGIFCONF returns buffer size in the buffer" >&5 -$as_echo_n "checking if SIOCGIFCONF returns buffer size in the buffer... " >&6; } -if test "${ac_cv_var_size_returned_in_buffer+set}" = set; then : - $as_echo_n "(cached) " >&6 + ERR_load_crypto_strings(); + OpenSSL_add_all_algorithms(); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_cv_lcrypto_lz=yes else - ans=no - case "$host" in - *-fujitsu-uxp*) - ans=yes - ;; - *-ncr-sysv4*) - ans=yes - ;; - *-univel-sysv*) - ans=yes - ;; - esac - ac_cv_var_size_returned_in_buffer=$ans + ntp_cv_lcrypto_lz=no + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_size_returned_in_buffer" >&5 -$as_echo "$ac_cv_var_size_returned_in_buffer" >&6; } -case "$ac_cv_var_size_returned_in_buffer" in - yes) -$as_echo "#define SIZE_RETURNED_IN_BUFFER 1" >>confdefs.h - ;; +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_lcrypto_lz" >&5 +$as_echo "$ntp_cv_lcrypto_lz" >&6; } + case "$ntp_cv_lcrypto_lz" in + yes) + LDADD_NTP="$LDADD_NTP -lz" + esac + esac esac +# +# Older OpenSSL headers have a number of callback prototypes inside +# other function prototypes which trigger copious warnings with gcc's +# -Wstrict-prototypes, which is included in -Wall. +# +# An example: +# +# int i2d_RSA_NET(const RSA *a, unsigned char **pp, +# int (*cb)(), int sgckey); +# ^^^^^^^^^^^ +# +# +# +openssl_triggers_warnings=unknown +NTPO_SAVED_CFLAGS="$CFLAGS" -# Check for ioctls TIOCGPPSEV -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ioctl TIOCGPPSEV" >&5 -$as_echo_n "checking ioctl TIOCGPPSEV... " >&6; } -if test "$ac_cv_header_termios_h" = "yes"; then +case "$ntp_openssl:$GCC" in + yes:yes) + CFLAGS="$CFLAGS -Werror" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#ifdef TIOCGPPSEV - yes -#endif + +int +main () +{ + + /* see if -Werror breaks gcc */ + + + ; + return 0; +} _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ntp_ok=yes +if ac_fn_c_try_compile "$LINENO"; then : + gcc_handles_Werror=yes else - ntp_ok=no -fi -rm -f conftest* + gcc_handles_Werror=no -else -ntp_ok=no fi -if test "$ntp_ok" = "yes"; then +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + case "$gcc_handles_Werror" in + no) + # if this gcc doesn't do -Werror go ahead and use + # -Wstrict-prototypes. + openssl_triggers_warnings=yes + ;; + yes) + CFLAGS="$CFLAGS -Wstrict-prototypes" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -$as_echo "#define HAVE_TIOCGPPSEV 1" >>confdefs.h + #include "openssl/asn1_mac.h" + #include "openssl/bn.h" + #include "openssl/err.h" + #include "openssl/evp.h" + #include "openssl/pem.h" + #include "openssl/rand.h" + #include "openssl/x509v3.h" - ac_cv_var_oncore_ok=yes -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +int +main () +{ -# Check for ioctls TIOCSPPS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ioctl TIOCSPPS" >&5 -$as_echo_n "checking ioctl TIOCSPPS... " >&6; } -if test "$ac_cv_header_termios_h" = "yes"; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef TIOCSPPS - yes -#endif + /* empty body */ + + ; + return 0; +} _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ntp_ok=yes +if ac_fn_c_try_compile "$LINENO"; then : + openssl_triggers_warnings=no else - ntp_ok=no + openssl_triggers_warnings=yes + fi -rm -f conftest* +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + esac + case "$openssl_triggers_warnings" in + yes) + CFLAGS_NTP="$CFLAGS_NTP -Wno-strict-prototypes" + ;; + *) + CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes" + esac + ;; + no:yes) + # gcc without OpenSSL + CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes" +esac + +# Because we don't want -Werror for the EVP_MD_do_all_sorted check +CFLAGS="$NTPO_SAVED_CFLAGS" + +case "$ntp_openssl" in + yes) + LIBS="$NTPO_SAVED_LIBS $LDADD_NTP" + for ac_func in EVP_MD_do_all_sorted +do : + ac_fn_c_check_func "$LINENO" "EVP_MD_do_all_sorted" "ac_cv_func_EVP_MD_do_all_sorted" +if test "x$ac_cv_func_EVP_MD_do_all_sorted" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_EVP_MD_DO_ALL_SORTED 1 +_ACEOF -else - ntp_ok=no fi +done -if test "$ntp_ok" = "yes"; then + ;; +esac + +CPPFLAGS="$NTPO_SAVED_CPPFLAGS" +LIBS="$NTPO_SAVED_LIBS" +{ NTPO_SAVED_CFLAGS=; unset NTPO_SAVED_CFLAGS;} +{ NTPO_SAVED_CPPFLAGS=; unset NTPO_SAVED_CPPFLAGS;} +{ NTPO_SAVED_LIBS=; unset NTPO_SAVED_LIBS;} +{ openssl_triggers_warnings=; unset openssl_triggers_warnings;} +{ ntp_openssl_from_pkg_config=; unset ntp_openssl_from_pkg_config;} -$as_echo "#define HAVE_TIOCSPPS 1" >>confdefs.h + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use OpenSSL's crypto random (if available)" >&5 +$as_echo_n "checking if we want to use OpenSSL's crypto random (if available)... " >&6; } +# Check whether --enable-openssl-random was given. +if test "${enable_openssl_random+set}" = set; then : + enableval=$enable_openssl_random; ntp_use_openssl_random=$enableval +else + ntp_use_openssl_random=yes fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -# Check for ioctls CIOGETEV -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ioctl CIOGETEV" >&5 -$as_echo_n "checking ioctl CIOGETEV... " >&6; } -if test "$ac_cv_header_sys_ppsclock_h" = "yes"; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef CIOGETEV - yes -#endif +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_openssl_random" >&5 +$as_echo "$ntp_use_openssl_random" >&6; } +# The following might need extra libraries +NTPO_SAVED_LIBS="$LIBS" +LIBS="$NTPO_SAVED_LIBS $LDADD_NTP" +for ac_func in RAND_bytes RAND_poll +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ntp_ok=yes -else - ntp_ok=no + fi -rm -f conftest* +done + +LIBS="$NTPO_SAVED_LIBS" +case "$ntp_use_openssl_random$ac_cv_func_RAND_bytes$ac_cv_func_RAND_poll" in + yesyesyes) + +$as_echo "#define USE_OPENSSL_CRYPTO_RAND 1" >>confdefs.h + + ;; + *) ntp_use_openssl_random=no ;; +esac + + +# if we are using OpenSSL (--with-crypto), by default Autokey is enabled +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to include NTP Autokey protocol support" >&5 +$as_echo_n "checking if we want to include NTP Autokey protocol support... " >&6; } +# Check whether --enable-autokey was given. +if test "${enable_autokey+set}" = set; then : + enableval=$enable_autokey; ntp_autokey=$enableval else -ntp_ok=no + ntp_autokey=$ntp_openssl + fi -if test "$ntp_ok" = "yes"; then - ac_cv_var_oncore_ok=yes -$as_echo "#define HAVE_CIOGETEV 1" >>confdefs.h +case "$ntp_autokey" in + no) + ;; + *) + case "$ntp_openssl" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Disabling Autokey, --enable-autokey requires --with-crypto." >&5 +$as_echo "$as_me: WARNING: Disabling Autokey, --enable-autokey requires --with-crypto." >&2;} + ntp_autokey=no + ;; + *) -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +$as_echo "#define AUTOKEY 1" >>confdefs.h + ntp_autokey=yes + ;; + esac + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_autokey" >&5 +$as_echo "$ntp_autokey" >&6; } -# ATOM/PPSAPI stuff. -# ATOM used to require struct timespec, but that's been fixed now. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to run check-layout" >&5 +$as_echo_n "checking if we want to run check-layout... " >&6; } +case "$cross_compiling$PATH_PERL" in + no/*) + MAKE_CHECK_LAYOUT=check-layout + ans=yes + ;; + *) + ans=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -# case "$ac_cv_struct_timespec" in -# 'yes') -# ac_cv_var_atom_ok=yes -# ;; -# esac -ac_cv_var_atom_ok=yes -# Check for header timepps.h, if found then we have PPS API (Draft RFC) stuff. -# The PPSAPI headers need "inline" ($ac_cv_c_inline='inline') +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can make dcf parse utilities" >&5 +$as_echo_n "checking if we can make dcf parse utilities... " >&6; } +ans=no +case "$ntp_parseutil" in + yes) + case "$host" in + *-*-sunos4*|*-*-solaris2*|*-*-*linux*|*-*-netbsd*) + ans="dcfd testdcf" + DCFD=dcfd + TESTDCF=testdcf + esac + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -# The PPSAPI needs struct timespec. -# The PPSAPI also needs a timepps header. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can build kernel streams modules for parse" >&5 +$as_echo_n "checking if we can build kernel streams modules for parse... " >&6; } +ans=no +case "$ntp_parseutil$ac_cv_header_sys_stropts_h" in + yesyes) + case "$host" in + sparc-*-sunos4*) + case "$ntp_cv_var_kernel_pll" in + yes) + +$as_echo "#define PPS_SYNC 1" >>confdefs.h + + ;; + esac + ans=parsestreams + MAKE_PARSEKMODULE=parsestreams.loadable_module.o + ;; + sparc-*-solaris2*) + ans=parsesolaris + MAKE_PARSEKMODULE=parse + for ac_header in strings.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "strings.h" "ac_cv_header_strings_h" "$ac_includes_default" +if test "x$ac_cv_header_strings_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STRINGS_H 1 +_ACEOF -case "$ac_cv_c_inline$ac_cv_struct_timespec" in - inlineyes) - case "$ac_cv_header_timepps_h$ac_cv_header_sys_timepps_h$host_os" in - *yes* | *sunos* | *solaris* | *sco* | *netbsd* ) +fi -$as_echo "#define HAVE_PPSAPI 1" >>confdefs.h +done - ac_cv_var_jupiter_ok=yes - ac_cv_var_oncore_ok=yes - ac_cv_var_parse_ok=yes - ac_cv_var_ripe_ncc_ok=yes ;; esac ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -# Check for ioctls TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG -ac_fn_c_check_header_mongrel "$LINENO" "linux/serial.h" "ac_cv_header_linux_serial_h" "$ac_includes_default" -if test "x$ac_cv_header_linux_serial_h" = x""yes; then : - -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need basic refclock support" >&5 +$as_echo_n "checking if we need basic refclock support... " >&6; } +case "$ntp_refclock" in + yes) +$as_echo "#define REFCLOCK 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG" >&5 -$as_echo_n "checking ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG... " >&6; } -case "$ac_cv_header_sys_ppsclock_h$ac_cv_header_linux_serial_h" in - yesyes) - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -typedef int u_int; + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_refclock" >&5 +$as_echo "$ntp_refclock" >&6; } -#include -#include +PROPDELAY=propdelay -#ifdef TIOCGSERIAL -#ifdef TIOCSSERIAL -#ifdef ASYNC_PPS_CD_POS -#ifdef ASYNC_PPS_CD_NEG -#ifdef CIOGETEV - yes -#endif -#endif -#endif -#endif -#endif -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ntp_ok=yes -fi -rm -f conftest* - ;; - *) - ntp_ok=no - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want HP-UX adjtimed support" >&5 +$as_echo_n "checking if we want HP-UX adjtimed support... " >&6; } +case "$host" in + *-*-hpux[56789]*) + ans=yes + ;; + *) ans=no + ;; esac -if test "$ntp_ok" = "yes"; then +case "$ans" in + yes) + MAKE_ADJTIMED=adjtimed -$as_echo "#define HAVE_TIO_SERIAL_STUFF 1" >>confdefs.h +$as_echo "#define NEED_HPUX_ADJTIME 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } + ;; + *) ADJTIMED_DB= + ADJTIMED_DL= + ADJTIMED_DS= + ADJTIMED_MS= + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -# Check for SHMEM_STATUS support -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SHMEM_STATUS support" >&5 -$as_echo_n "checking SHMEM_STATUS support... " >&6; } -case "$ac_cv_header_sys_mman_h" in - yes) ntp_ok=yes ;; - *) ntp_ok=no ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want QNX adjtime support" >&5 +$as_echo_n "checking if we want QNX adjtime support... " >&6; } +case "$host" in + *-*-qnx*) + ans=yes + ;; + *) ans=no + ;; esac -if test "$ntp_ok" = "yes"; then +case "$ans" in + yes) -$as_echo "#define ONCORE_SHMEM_STATUS 1" >>confdefs.h +$as_echo "#define NEED_QNX_ADJTIME 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can read kmem" >&5 +$as_echo_n "checking if we can read kmem... " >&6; } -ntp_refclock=no +# the default is to enable it if the system has the capability -# HPUX only, and by explicit request -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Datum/Bancomm bc635/VME interface" >&5 -$as_echo_n "checking Datum/Bancomm bc635/VME interface... " >&6; } -# Check whether --enable-BANCOMM was given. -if test "${enable_BANCOMM+set}" = set; then : - enableval=$enable_BANCOMM; ntp_ok=$enableval -else - ntp_ok=no -fi +case "$ac_cv_func_nlist$ac_cv_func_K_open$ac_cv_func_kvm_open" in + *yes*) + ans=yes + ;; + *) ans=no + ;; +esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +case "$host" in + *-*-domainos) # Won't be found... + ans=no + ;; + *-*-hpux*) + #ans=no + ;; + *-*-irix[456]*) + ans=no + ;; + *-*-*linux*) + ans=no + ;; + *-*-winnt3.5) + ans=no + ;; + *-*-unicosmp*) + ans=no + ;; +esac -$as_echo "#define CLOCK_BANC 1" >>confdefs.h +# --enable-kmem / --disable-kmem controls if present +# Check whether --enable-kmem was given. +if test "${enable_kmem+set}" = set; then : + enableval=$enable_kmem; ans=$enableval fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$host" in - yes*-*-hpux*) ;; - yes*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; -esac -#HPUX only, and only by explicit request -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking TrueTime GPS receiver/VME interface" >&5 -$as_echo_n "checking TrueTime GPS receiver/VME interface... " >&6; } -# Check whether --enable-GPSVME was given. -if test "${enable_GPSVME+set}" = set; then : - enableval=$enable_GPSVME; ntp_ok=$enableval -else - ntp_ok=no -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -$as_echo "#define CLOCK_GPSVME 1" >>confdefs.h +case "$ans" in + yes) + can_kmem=yes + ;; + *) + can_kmem=no + +$as_echo "#define NOKMEM 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$host" in - yes*-*-hpux*) ;; - yes*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PCL720 clock support" >&5 -$as_echo_n "checking for PCL720 clock support... " >&6; } -case "$ac_cv_header_machine_inline_h$ac_cv_header_sys_pcl720_h$ac_cv_header_sys_i8253_h" in - yesyesyes) -$as_echo "#define CLOCK_PPS720 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if adjtime is accurate" >&5 +$as_echo_n "checking if adjtime is accurate... " >&6; } + +# target-dependent defaults +case "$host" in + i386-sequent-ptx*) + ans=no + ;; + i386-unknown-osf1*) ans=yes ;; - *) + mips-sgi-irix[456]*) + ans=yes + ;; + *-fujitsu-uxp*) + ans=yes + ;; + *-ibm-aix[4-9]*) + # XXX only verified thru AIX6. + ans=yes + ;; + *-*-*linux*) + ans=yes + ;; + *-*-solaris2.[01]) ans=no ;; + *-*-solaris2*) + ans=yes + ;; + *-*-unicosmp*) + ans=yes + ;; + *) ans=no + ;; esac + +# --enable-accurate-adjtime / --disable-accurate-adjtime +# override the default +# Check whether --enable-accurate-adjtime was given. +if test "${enable_accurate_adjtime+set}" = set; then : + enableval=$enable_accurate_adjtime; ans=$enableval + +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 $as_echo "$ans" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default inclusion of all suitable non-PARSE clocks" >&5 -$as_echo_n "checking for default inclusion of all suitable non-PARSE clocks... " >&6; } -# Check whether --enable-all-clocks was given. -if test "${enable_all_clocks+set}" = set; then : - enableval=$enable_all_clocks; ntp_eac=$enableval +case "$ans" in + yes) + +$as_echo "#define ADJTIME_IS_ACCURATE 1" >>confdefs.h + + adjtime_is_accurate=yes + ;; + *) + adjtime_is_accurate=no + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name of 'tick' in the kernel" >&5 +$as_echo_n "checking the name of 'tick' in the kernel... " >&6; } +if ${ntp_cv_nlist_tick+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_eac=yes + + ans=_tick + case "$host" in + m68*-hp-hpux*) # HP9000/300? + ans=_old_tick + ;; + *-apple-aux[23]*) + ans=tick + ;; + *-hp-hpux*) + ans=old_tick + ;; + *-ibm-aix[3-9]*) + # XXX only verified thru AIX6. + ans=no + ;; + *-*-mpeix*) + ans=no + ;; + *-*-ptx*) + ans=tick + ;; + *-*-sco3.2v[45]*) + ans=no + ;; + *-*-solaris2*) + ans=nsec_per_tick + ;; + *-*-sysv4*) + ans=tick + ;; + esac + ntp_cv_nlist_tick=$ans + + fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_tick" >&5 +$as_echo "$ntp_cv_nlist_tick" >&6; } +case "$ntp_cv_nlist_tick" in + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_eac" >&5 -$as_echo "$ntp_eac" >&6; } +cat >>confdefs.h <<_ACEOF +#define K_TICK_NAME "$ntp_cv_nlist_tick" +_ACEOF -# HMS: Should we also require ac_cv_var_parse_ok? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for PARSE clocks" >&5 -$as_echo_n "checking if we have support for PARSE clocks... " >&6; } -case "$ac_cv_var_atom_ok$ac_cv_header_termio_h$ac_cv_header_termios_h" in - yes*yes*) - ntp_canparse=yes - ;; - *) ntp_canparse=no - ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canparse" >&5 -$as_echo "$ntp_canparse" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for audio clocks" >&5 -$as_echo_n "checking if we have support for audio clocks... " >&6; } -case "$ac_cv_header_sun_audioio_h$ac_cv_header_sys_audioio_h$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in - *yes*) - ntp_canaudio=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the units of 'tick'" >&5 +$as_echo_n "checking for the units of 'tick'... " >&6; } +if ${ntp_cv_tick_nano+:} false; then : + $as_echo_n "(cached) " >&6 +else -$as_echo "#define HAVE_AUDIO /**/" >>confdefs.h + ans=usec + case "$host" in + *-*-solaris2*) + ans=nsec + ;; + esac + ntp_cv_tick_nano=$ans - ;; - *) ntp_canaudio=no ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canaudio" >&5 -$as_echo "$ntp_canaudio" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have support for the SHM refclock interface" >&5 -$as_echo_n "checking if we have support for the SHM refclock interface... " >&6; } -case "$ac_cv_header_sys_ipc_h$ac_cv_header_sys_shm_h" in - yesyes) - ntp_canshm=yes - ;; - *) ntp_canshm=no ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_tick_nano" >&5 +$as_echo "$ntp_cv_tick_nano" >&6; } +case "$ntp_cv_tick_nano" in + nsec) + +$as_echo "#define TICK_NANO 1" >>confdefs.h + esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_canshm" >&5 -$as_echo "$ntp_canshm" >&6; } -# Requires modem control -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ACTS modem service" >&5 -$as_echo_n "checking ACTS modem service... " >&6; } -# Check whether --enable-ACTS was given. -if test "${enable_ACTS+set}" = set; then : - enableval=$enable_ACTS; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name of 'tickadj' in the kernel" >&5 +$as_echo_n "checking the name of 'tickadj' in the kernel... " >&6; } +if ${ntp_cv_nlist_tickadj+:} false; then : + $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef HAVE_SYS_IOCTL_H -#include -#endif -#ifdef TIOCMBIS - yes -#endif -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ntp_ok=$ntp_eac -else - ntp_ok=no -fi -rm -f conftest* + ans=_tickadj + case "$host" in + m68*-hp-hpux*) # HP9000/300? + ans=_tickadj + ;; + *-apple-aux[23]*) + ans=tickadj + ;; + *-hp-hpux10*) + ans=no + ;; + *-hp-hpux9*) + ans=no + ;; + *-hp-hpux*) + ans=tickadj + ;; + *-*-aix*) + ans=tickadj + ;; + *-*-mpeix*) + ans=no + ;; + *-*-ptx*) + ans=tickadj + ;; + *-*-sco3.2v4*) + ans=no + ;; + *-*-sco3.2v5.0*) + ans=clock_drift + ;; + *-*-solaris2*) + ans=no # hrestime_adj + ;; + *-*-sysv4*) + ans=tickadj + ;; + esac + ntp_cv_nlist_tickadj=$ans -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_tickadj" >&5 +$as_echo "$ntp_cv_nlist_tickadj" >&6; } +case "$ntp_cv_nlist_tickadj" in + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) -$as_echo "#define CLOCK_ACTS 1" >>confdefs.h +cat >>confdefs.h <<_ACEOF +#define K_TICKADJ_NAME "$ntp_cv_nlist_tickadj" +_ACEOF -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Arbiter 1088A/B GPS receiver" >&5 -$as_echo_n "checking Arbiter 1088A/B GPS receiver... " >&6; } -# Check whether --enable-ARBITER was given. -if test "${enable_ARBITER+set}" = set; then : - enableval=$enable_ARBITER; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the units of 'tickadj'" >&5 +$as_echo_n "checking for the units of 'tickadj'... " >&6; } +if ${ntp_cv_tickadj_nano+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes + ans=usec + case "$host" in + *-*-solaris2*) + ans=nsec + ;; + esac + ntp_cv_tickadj_nano=$ans -$as_echo "#define CLOCK_ARBITER 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_tickadj_nano" >&5 +$as_echo "$ntp_cv_tickadj_nano" >&6; } +case "$ntp_cv_tickadj_nano" in + nsec) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Arcron MSF receiver" >&5 -$as_echo_n "checking Arcron MSF receiver... " >&6; } -# Check whether --enable-ARCRON_MSF was given. -if test "${enable_ARCRON_MSF+set}" = set; then : - enableval=$enable_ARCRON_MSF; ntp_ok=$enableval +$as_echo "#define TICKADJ_NANO 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking half-heartedly for 'dosynctodr' in the kernel" >&5 +$as_echo_n "checking half-heartedly for 'dosynctodr' in the kernel... " >&6; } +if ${ntp_cv_nlist_dosynctodr+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes + case "$host" in + *-apple-aux[23]*) + ans=no + ;; + *-sni-sysv*) + ans=dosynctodr + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix*) + ans=dosynctodr + ;; + *-*-hpux*) + ans=no + ;; + *-*-mpeix*) + ans=no + ;; + *-*-nextstep*) + ans=_dosynctodr + ;; + *-*-ptx*) + ans=doresettodr + ;; + *-*-sco3.2v4*) + ans=no + ;; + *-*-sco3.2v5*) + ans=track_rtc + ;; + *-*-solaris2*) + ans=dosynctodr + ;; + *-*-sysv4*) + ans=doresettodr + ;; + *) + ans=_dosynctodr + ;; + esac + ntp_cv_nlist_dosynctodr=$ans -$as_echo "#define CLOCK_ARCRON_MSF 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_dosynctodr" >&5 +$as_echo "$ntp_cv_nlist_dosynctodr" >&6; } +case "$ntp_cv_nlist_dosynctodr" in + no) + ;; + *) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Austron 2200A/2201A GPS receiver" >&5 -$as_echo_n "checking Austron 2200A/2201A GPS receiver... " >&6; } -# Check whether --enable-AS2201 was given. -if test "${enable_AS2201+set}" = set; then : - enableval=$enable_AS2201; ntp_ok=$enableval +cat >>confdefs.h <<_ACEOF +#define K_DOSYNCTODR_NAME "$ntp_cv_nlist_dosynctodr" +_ACEOF + + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking half-heartedly for 'noprintf' in the kernel" >&5 +$as_echo_n "checking half-heartedly for 'noprintf' in the kernel... " >&6; } +if ${ntp_cv_nlist_noprintf+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes + case "$host" in + *-apple-aux[23]*) + ans=no + ;; + *-sni-sysv*) + ans=noprintf + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix*) + ans=noprintf + ;; + *-*-hpux*) + ans=no + ;; + *-*-mpeix*) + ans=no + ;; + *-*-ptx*) + ans=noprintf + ;; + *-*-nextstep*) + ans=_noprintf + ;; + *-*-solaris2*) + ans=noprintf + ;; + *-*-sysv4*) + ans=noprintf + ;; + *) + ans=_noprintf + ;; + esac + ntp_cv_nlist_noprintf=$ans -$as_echo "#define CLOCK_AS2201 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_nlist_noprintf" >&5 +$as_echo "$ntp_cv_nlist_noprintf" >&6; } +case "$ntp_cv_nlist_noprintf" in + no) + ;; + *) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ATOM PPS interface" >&5 -$as_echo_n "checking ATOM PPS interface... " >&6; } -# Check whether --enable-ATOM was given. -if test "${enable_ATOM+set}" = set; then : - enableval=$enable_ATOM; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi +cat >>confdefs.h <<_ACEOF +#define K_NOPRINTF_NAME "$ntp_cv_nlist_noprintf" +_ACEOF -case "$ac_cv_var_atom_ok" in - no) ntp_ok=no ;; + ;; esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_ATOM 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Chrono-log K-series WWVB receiver" >&5 -$as_echo_n "checking Chrono-log K-series WWVB receiver... " >&6; } -# Check whether --enable-CHRONOLOG was given. -if test "${enable_CHRONOLOG+set}" = set; then : - enableval=$enable_CHRONOLOG; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a default value for 'tick'" >&5 +$as_echo_n "checking for a default value for 'tick'... " >&6; } + +# target-dependent default for tick + +case "$host" in + *-*-pc-cygwin*) + as_fn_error $? "tick needs work for cygwin" "$LINENO" 5 + ;; + *-univel-sysv*) + ans=10000 + ;; + *-*-irix*) + ans=10000 + ;; + *-*-*linux*) + ans=txc.tick + ;; + *-*-mpeix*) + ans=no + ;; + *-*-winnt3.5) + ans='(every / 10)' + ;; + *-*-unicosmp*) + ans=10000 + ;; + *) + ans='1000000L/hz' + ;; +esac -$as_echo "#define CLOCK_CHRONOLOG 1" >>confdefs.h +# Check whether --enable-tick was given. +if test "${enable_tick+set}" = set; then : + enableval=$enable_tick; ans=$enableval fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CHU modem/decoder" >&5 -$as_echo_n "checking CHU modem/decoder... " >&6; } -# Check whether --enable-CHU was given. -if test "${enable_CHU+set}" = set; then : - enableval=$enable_CHU; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -$as_echo "#define CLOCK_CHU 1" >>confdefs.h +case "$ans" in + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -ac_refclock_chu=$ntp_ok +cat >>confdefs.h <<_ACEOF +#define PRESET_TICK $ans +_ACEOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CHU audio/decoder" >&5 -$as_echo_n "checking CHU audio/decoder... " >&6; } -# Check whether --enable-AUDIO-CHU was given. -if test "${enable_AUDIO_CHU+set}" = set; then : - enableval=$enable_AUDIO_CHU; ntp_ok=$enableval -else - case "$ntp_eac$ac_refclock_chu$ntp_canaudio" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; esac -fi -if test "$ntp_ok" = "yes"; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a default value for 'tickadj'" >&5 +$as_echo_n "checking for a default value for 'tickadj'... " >&6; } + +# target-specific default +ans='500/hz' +case "$host" in + *-fujitsu-uxp*) + case "$adjtime_is_accurate" in + yes) + ans='tick/16' + esac + ;; + *-univel-sysv*) + ans=80 + ;; + *-*-aix*) + case "$can_kmem" in + no) + ans=1000 + ;; + esac + ;; + *-*-domainos) # Skippy: won't be found... + case "$can_kmem" in + no) + ans=668 + ;; + esac + ;; + *-*-hpux*) + case "$adjtime_is_accurate" in + yes) + ans='tick/16' + ;; + esac + ;; + *-*-irix*) + ans=150 + ;; + *-*-mpeix*) + ans=no + ;; + *-*-sco3.2v5.0*) + ans=10000L/hz + ;; + *-*-winnt3.5) + ans=50 + ;; + *-*-unicosmp*) + ans=150 + ;; +esac -$as_echo "#define AUDIO_CHU 1" >>confdefs.h +# Check whether --enable-tickadj was given. +if test "${enable_tickadj+set}" = set; then : + enableval=$enable_tickadj; ans=$enableval fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -# We used to check for sunos/solaris target... -case "$ntp_ok$ac_refclock_chu$ntp_canaudio" in - yes*no*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is...no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is...no ***" >&2;} ;; + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +default_tickadj=$ans + +case "$default_tickadj" in + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) + +cat >>confdefs.h <<_ACEOF +#define PRESET_TICKADJ $default_tickadj +_ACEOF + ;; esac -# Not under HP-UX -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Datum Programmable Time System" >&5 -$as_echo_n "checking Datum Programmable Time System... " >&6; } -# Check whether --enable-DATUM was given. -if test "${enable_DATUM+set}" = set; then : - enableval=$enable_DATUM; ntp_ok=$enableval -else - case "$ac_cv_header_termios_h" in - yes) - ntp_ok=$ntp_eac - ;; - *) ntp_ok=no - ;; - esac -fi +# Newer versions of ReliantUNIX round adjtime() values down to +# 1/100s (system tick). Sigh ... +# Unfortunately, there is no easy way to know if particular release +# has this "feature" or any obvious way to test for it. +case "$host" in + mips-sni-sysv4*) -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +$as_echo "#define RELIANTUNIX_CLOCK 1" >>confdefs.h -$as_echo "#define CLOCK_DATUM 1" >>confdefs.h +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +case "$host" in + *-*-sco3.2v5*) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Dumb generic hh:mm:ss local clock" >&5 -$as_echo_n "checking Dumb generic hh:mm:ss local clock... " >&6; } -# Check whether --enable-DUMBCLOCK was given. -if test "${enable_DUMBCLOCK+set}" = set; then : - enableval=$enable_DUMBCLOCK; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi +$as_echo "#define SCO5_CLOCK 1" >>confdefs.h -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +esac -$as_echo "#define CLOCK_DUMBCLOCK 1" >>confdefs.h +ntp_cv_make_tickadj=yes +case "$can_kmem$ac_cv_var_tick$default_tickadj" in + nonono) # Don't read KMEM, no presets. Bogus. + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem, no PRESET_TICK or PRESET_TICKADJ. No tickadj." >&5 +$as_echo "$as_me: WARNING: Can't read kmem, no PRESET_TICK or PRESET_TICKADJ. No tickadj." >&2;} + ntp_cv_make_tickadj=no + ;; + nono*) # Don't read KMEM, no PRESET_TICK but PRESET_TICKADJ. Bogus. + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem but no PRESET_TICK. No tickadj." >&5 +$as_echo "$as_me: WARNING: Can't read kmem but no PRESET_TICK. No tickadj." >&2;} + ntp_cv_make_tickadj=no + ;; + no*no) # Don't read KMEM, PRESET_TICK but no PRESET_TICKADJ. Bogus. + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem but no PRESET_TICKADJ. No tickadj." >&5 +$as_echo "$as_me: WARNING: Can't read kmem but no PRESET_TICKADJ. No tickadj." >&2;} + ntp_cv_make_tickadj=no + ;; + no*) # Don't read KMEM, PRESET_TICK and PRESET_TICKADJ. Cool. + ;; + yesnono) # Read KMEM, no presets. Cool. + ;; + yesno*) # Read KMEM, no PRESET_TICK but PRESET_TICKADJ. Bogus. + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PRESET_TICKADJ is defined but not PRESET_TICK. Please report this." >&5 +$as_echo "$as_me: WARNING: PRESET_TICKADJ is defined but not PRESET_TICK. Please report this." >&2;} + ;; + yes*no) # Read KMEM, PRESET_TICK but no PRESET_TICKADJ. Cool. + ;; + yes*) # READ KMEM, PRESET_TICK and PRESET_TICKADJ. + ;; + *) # Generally bogus. + as_fn_error $? "This shouldn't happen." "$LINENO" 5 + ;; +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Forum Graphic GPS" >&5 -$as_echo_n "checking Forum Graphic GPS... " >&6; } -# Check whether --enable-FG was given. -if test "${enable_FG+set}" = set; then : - enableval=$enable_FG; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the ntptime utility" >&5 +$as_echo_n "checking if we want and can make the ntptime utility... " >&6; } +if ${ac_cv_make_ntptime+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=$ntp_eac + case "$host" in + *) case "$ntp_cv_struct_ntptimeval$ntp_cv_var_kernel_pll" in + yesyes) + ans=yes + ;; + *) + ans=no + ;; + esac + ;; +esac +ac_cv_make_ntptime=$ans fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_make_ntptime" >&5 +$as_echo "$ac_cv_make_ntptime" >&6; } +case "$ac_cv_make_ntptime" in + yes) + MAKE_NTPTIME=ntptime + ;; + *) + NTPTIME_DB= + NTPTIME_DL= + NTPTIME_DS= + NTPTIME_MS= + ;; +esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes - -$as_echo "#define CLOCK_FG 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +case "$host" in + mips-sni-sysv4*) + # tickadj is pretty useless on newer versions of ReliantUNIX + # Do not bother + ntp_cv_make_tickadj=no + ;; + *-*-irix*) + ntp_cv_make_tickadj=no + ;; + *-*-solaris2*) + # DLM says tickadj is a no-no starting with solaris2.5 + case "$host" in + *-*-solaris2.1[0-9]*) + ntp_cv_make_tickadj=no + ;; + *-*-solaris2.[0-4]*) ;; + *) ntp_cv_make_tickadj=no ;; + esac + ;; + *-*-unicosmp*) + ntp_cv_make_tickadj=no + ;; +esac -# Requires modem control -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Heath GC-1000 WWV/WWVH receiver" >&5 -$as_echo_n "checking Heath GC-1000 WWV/WWVH receiver... " >&6; } -# Check whether --enable-HEATH was given. -if test "${enable_HEATH+set}" = set; then : - enableval=$enable_HEATH; ntp_ok=$enableval -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#ifdef HAVE_SYS_IOCTL_H -#include -#endif -#ifdef TIOCMBIS - yes -#endif +# +# Despite all the above, we always make tickadj. Setting +# ntp_cv_make_tickadj before AC_CACHE_CHECK will cause a false +# report that the configuration variable was cached. It may +# be better to simply remove the hunk above, I did not want +# to remove it if there is hope it will be used again. +# +{ ntp_cv_make_tickadj=; unset ntp_cv_make_tickadj;} -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then : - ntp_ok=$ntp_eac +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the tickadj utility" >&5 +$as_echo_n "checking if we want and can make the tickadj utility... " >&6; } +if ${ntp_cv_make_tickadj+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=no -fi -rm -f conftest* + ntp_cv_make_tickadj=yes fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_make_tickadj" >&5 +$as_echo "$ntp_cv_make_tickadj" >&6; } +case "$ntp_cv_make_tickadj" in + yes) + MAKE_TICKADJ=tickadj + ;; + *) + CALC_TICKADJ_DB= + CALC_TICKADJ_DL= + CALC_TICKADJ_DS= + CALC_TICKADJ_MS= + TICKADJ_DB= + TICKADJ_DL= + TICKADJ_DS= + TICKADJ_MS= + ;; +esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_HEATH 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the timetrim utility" >&5 +$as_echo_n "checking if we want and can make the timetrim utility... " >&6; } +if ${ntp_cv_make_timetrim+:} false; then : + $as_echo_n "(cached) " >&6 +else + + case "$host" in + *-*-irix*) + ntp_cv_make_timetrim=yes + ;; + *-*-unicosmp*) + ntp_cv_make_timetrim=yes + ;; + *) + ntp_cv_make_timetrim=no + ;; + esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hopf serial clock device" >&5 -$as_echo_n "checking for hopf serial clock device... " >&6; } -# Check whether --enable-HOPFSERIAL was given. -if test "${enable_HOPFSERIAL+set}" = set; then : - enableval=$enable_HOPFSERIAL; ntp_ok=$enableval -else - ntp_ok=$ntp_eac fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_make_timetrim" >&5 +$as_echo "$ntp_cv_make_timetrim" >&6; } +case "$ntp_cv_make_timetrim" in + yes) + MAKE_TIMETRIM=timetrim + ;; + *) TIMETRIM_DB= + TIMETRIM_DL= + TIMETRIM_DS= + TIMETRIM_MS= + ;; +esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_HOPF_SERIAL 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hopf PCI clock 6039" >&5 -$as_echo_n "checking for hopf PCI clock 6039... " >&6; } -# Check whether --enable-HOPFPCI was given. -if test "${enable_HOPFPCI+set}" = set; then : - enableval=$enable_HOPFPCI; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to build the NTPD simulator" >&5 +$as_echo_n "checking if we want to build the NTPD simulator... " >&6; } +# Check whether --enable-simulator was given. +if test "${enable_simulator+set}" = set; then : + enableval=$enable_simulator; ans=$enableval else - ntp_ok=$ntp_eac + ans=no + fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } +case "$ans" in + yes) + MAKE_NTPDSIM=ntpdsim + MAKE_LIBNTPSIM=libntpsim.a + ;; + *) + NTPDSIM_DB= + NTPDSIM_DL= + NTPDSIM_DS= + NTPDSIM_MS= + ;; +esac -$as_echo "#define CLOCK_HOPF_PCI 1" >>confdefs.h +case "$build" in + $host) + ;; + *) case "$host" in + *-*-vxworks*) + LDFLAGS="$LDFLAGS -r" + ;; + esac + ;; +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking HP 58503A GPS receiver" >&5 -$as_echo_n "checking HP 58503A GPS receiver... " >&6; } -# Check whether --enable-HPGPS was given. -if test "${enable_HPGPS+set}" = set; then : - enableval=$enable_HPGPS; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sntp will be built" >&5 +$as_echo_n "checking if sntp will be built... " >&6; } -$as_echo "#define CLOCK_HPGPS 1" >>confdefs.h +# Check whether --with-sntp was given. +if test "${with_sntp+set}" = set; then : + withval=$with_sntp; +else + with_sntp="${withsntp=yes}" fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking IRIG audio decoder" >&5 -$as_echo_n "checking IRIG audio decoder... " >&6; } -# Check whether --enable-IRIG was given. -if test "${enable_IRIG+set}" = set; then : - enableval=$enable_IRIG; ntp_ok=$enableval +case "$with_sntp" in + no) + SNTP= + ;; + *) + SNTP=sntp + ;; +esac + + if test -n "$SNTP"; then + BUILD_SNTP_TRUE= + BUILD_SNTP_FALSE='#' else - case "$ntp_eac$ntp_canaudio" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; - esac + BUILD_SNTP_TRUE='#' + BUILD_SNTP_FALSE= fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sntp" >&5 +$as_echo "$with_sntp" >&6; } -$as_echo "#define CLOCK_IRIG 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canaudio" in - yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for JJY receiver" >&5 -$as_echo_n "checking for JJY receiver... " >&6; } -# Check whether --enable-JJY was given. -if test "${enable_JJY+set}" = set; then : - enableval=$enable_JJY; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to build ntpsnmpd" >&5 +$as_echo_n "checking if we want to build ntpsnmpd... " >&6; } + +# Check whether --with-ntpsnmpd was given. +if test "${with_ntpsnmpd+set}" = set; then : + withval=$with_ntpsnmpd; ans=$withval else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes + case "$PATH_NET_SNMP_CONFIG" in + /*) ans=yes ;; + *) ans=no ;; + esac -$as_echo "#define CLOCK_JJY 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Rockwell Jupiter GPS receiver" >&5 -$as_echo_n "checking Rockwell Jupiter GPS receiver... " >&6; } -# Check whether --enable-JUPITER was given. -if test "${enable_JUPITER+set}" = set; then : - enableval=$enable_JUPITER; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } +case "$ans" in + yes) + case "$PATH_NET_SNMP_CONFIG" in + /*) + SNMP_LIBS=`$PATH_NET_SNMP_CONFIG --agent-libs` + # Bug 2815. This is a bit of a hack, but it works... + case "$ntp_cv_net_snmp_version" in + 5.3*) SNMP_LIBS=`echo $SNMP_LIBS | $SED -e 's/-lnetsnmpagent/-lnetsnmpagent -lnetsnmpmibs/'` + ;; + esac -case "$ac_cv_var_jupiter_ok" in - no) ntp_ok=no ;; -esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes + # HMS: we really want to separate CPPFLAGS and CFLAGS + foo=`$PATH_NET_SNMP_CONFIG --cflags` + SNMP_CPPFLAGS= + SNMP_CFLAGS= + for i in $foo; do + case "$i" in + -D*|-U*|-I*) + SNMP_CPPFLAGS="$SNMP_CPPFLAGS $i" + ;; + *) SNMP_CFLAGS="$SNMP_CFLAGS $i" + ;; + esac + done -$as_echo "#define CLOCK_JUPITER 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Leitch CSD 5300 Master Clock System Driver" >&5 -$as_echo_n "checking Leitch CSD 5300 Master Clock System Driver... " >&6; } -# Check whether --enable-LEITCH was given. -if test "${enable_LEITCH+set}" = set; then : - enableval=$enable_LEITCH; ntp_ok=$enableval + save_CFLAGS=$CFLAGS + save_CPPFLAGS=$CPPFLAGS + save_LIBS=$LIBS + CFLAGS=$SNMP_CFLAGS + CPPFLAGS=$SNMP_CPPFLAGS + + ac_fn_c_check_header_mongrel "$LINENO" "net-snmp/net-snmp-config.h" "ac_cv_header_net_snmp_net_snmp_config_h" "$ac_includes_default" +if test "x$ac_cv_header_net_snmp_net_snmp_config_h" = xyes; then : + MAKE_NTPSNMPD=ntpsnmpd else - ntp_ok=$ntp_eac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: net-snmp-config present but net-snmp headers are not available!" >&5 +$as_echo "$as_me: WARNING: net-snmp-config present but net-snmp headers are not available!" >&2;} + fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_LEITCH 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } + # Do this last, as we're messing up LIBS. + # check -lnetsnmp for netsnmp_daemonize + LIBS=`$PATH_NET_SNMP_CONFIG --libs` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for netsnmp_daemonize in -lnetsnmp" >&5 +$as_echo_n "checking for netsnmp_daemonize in -lnetsnmp... " >&6; } +if ${ac_cv_lib_netsnmp_netsnmp_daemonize+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lnetsnmp $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking local clock reference" >&5 -$as_echo_n "checking local clock reference... " >&6; } -# Check whether --enable-LOCAL-CLOCK was given. -if test "${enable_LOCAL_CLOCK+set}" = set; then : - enableval=$enable_LOCAL_CLOCK; ntp_ok=$enableval +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char netsnmp_daemonize (); +int +main () +{ +return netsnmp_daemonize (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_netsnmp_netsnmp_daemonize=yes else - ntp_ok=$ntp_eac + ac_cv_lib_netsnmp_netsnmp_daemonize=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_netsnmp_netsnmp_daemonize" >&5 +$as_echo "$ac_cv_lib_netsnmp_netsnmp_daemonize" >&6; } +if test "x$ac_cv_lib_netsnmp_netsnmp_daemonize" = xyes; then : + ans=yes +else + ans=no -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +fi -$as_echo "#define CLOCK_LOCAL 1" >>confdefs.h + case "$ans" in + no) -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +$as_echo "#define NEED_NETSNMP_DAEMONIZE 1" >>confdefs.h + esac -# Not Ultrix -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Magnavox MX4200 GPS receiver" >&5 -$as_echo_n "checking Magnavox MX4200 GPS receiver... " >&6; } -# Check whether --enable-MX4200 was given. -if test "${enable_MX4200+set}" = set; then : - enableval=$enable_MX4200; ntp_ok=$enableval -else - case "$ac_cv_var_ppsclock" in - yes) ntp_ok=$ntp_eac - ;; - *) ntp_ok=no - ;; + CFLAGS=$save_CFLAGS + { save_CFLAGS=; unset save_CFLAGS;} + CPPFLAGS=$save_CPPFLAGS + { save_CPPFLAGS=; unset save_CPPFLAGS;} + LIBS=$save_LIBS + { save_LIBS=; unset save_LIBS;} + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot build ntpsnmpd - net-snmp-config cannot be found" >&5 +$as_echo "$as_me: WARNING: Cannot build ntpsnmpd - net-snmp-config cannot be found" >&2;} + ;; esac -fi + ;; +esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_MX4200 1" >>confdefs.h +case "$MAKE_NTPSNMPD" in + '') + NTPSNMPD_DB= + NTPSNMPD_DL= + NTPSNMPD_DS= + NTPSNMPD_MS= + ;; +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$host" in - yes*-*-ultrix*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should always slew the time" >&5 +$as_echo_n "checking if we should always slew the time... " >&6; } + +# target-specific defaults + +case "$host" in + *-apple-aux[23]*) + ans=yes + ;; + *-*-bsdi[012]*) + ans=no + ;; + *-*-bsdi*) + ans=yes + ;; + *-*-openvms*) # HMS: won't be found + ans=yes + ;; + *) ans=no + ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for NeoClock4X receiver" >&5 -$as_echo_n "checking for NeoClock4X receiver... " >&6; } -# Check whether --enable-NEOCLOCK4X was given. -if test "${enable_NEOCLOCK4X+set}" = set; then : - enableval=$enable_NEOCLOCK4X; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi - -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes - -$as_echo "#define CLOCK_NEOCLOCK4X 1" >>confdefs.h +# --enable-slew-always / --disable-slew-always overrides default -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +# Check whether --enable-slew-always was given. +if test "${enable_slew_always+set}" = set; then : + enableval=$enable_slew_always; ans=$enableval -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking NMEA GPS receiver" >&5 -$as_echo_n "checking NMEA GPS receiver... " >&6; } -# Check whether --enable-NMEA was given. -if test "${enable_NMEA+set}" = set; then : - enableval=$enable_NMEA; ntp_ok=$enableval -else - ntp_ok=$ntp_eac fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_NMEA 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +case "$ans" in + yes) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ONCORE Motorola VP/UT Oncore GPS" >&5 -$as_echo_n "checking for ONCORE Motorola VP/UT Oncore GPS... " >&6; } -# Check whether --enable-ONCORE was given. -if test "${enable_ONCORE+set}" = set; then : - enableval=$enable_ONCORE; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi +$as_echo "#define SLEWALWAYS 1" >>confdefs.h -case "$ac_cv_var_oncore_ok" in - no) ntp_ok=no ;; esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_ONCORE 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should step and slew the time" >&5 +$as_echo_n "checking if we should step and slew the time... " >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +case "$host" in + *-sni-sysv*) + ans=yes + ;; + *-stratus-vos) + ans=no + ;; + *-univel-sysv*) + ans=no + ;; + *-*-ptx*) + ans=yes + ;; + *-*-solaris2.1[0-9]*) + ans=no + ;; + *-*-solaris2.[012]*) + ans=yes + ;; + *-*-sysv4*) # HMS: Does this catch Fujitsu UXP? + ans=yes + ;; + *) ans=no + ;; +esac + +# Check whether --enable-step-slew was given. +if test "${enable_step_slew+set}" = set; then : + enableval=$enable_step_slew; ans=$enableval -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Palisade clock" >&5 -$as_echo_n "checking for Palisade clock... " >&6; } -# Check whether --enable-PALISADE was given. -if test "${enable_PALISADE+set}" = set; then : - enableval=$enable_PALISADE; ntp_ok=$enableval -else - case "$ac_cv_header_termios_h" in - yes) - ntp_ok=$ntp_eac - ;; - *) ntp_ok=no - ;; - esac fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -$as_echo "#define CLOCK_PALISADE 1" >>confdefs.h +case "$ans" in + yes) -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +$as_echo "#define STEP_SLEW 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Conrad parallel port radio clock" >&5 -$as_echo_n "checking Conrad parallel port radio clock... " >&6; } -# Check whether --enable-PCF was given. -if test "${enable_PCF+set}" = set; then : - enableval=$enable_PCF; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi +esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpdate should step the time" >&5 +$as_echo_n "checking if ntpdate should step the time... " >&6; } -$as_echo "#define CLOCK_PCF 1" >>confdefs.h +case "$host" in + *-apple-aux[23]*) + ans=yes + ;; + *) ans=no + ;; +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +# Check whether --enable-ntpdate-step was given. +if test "${enable_ntpdate_step+set}" = set; then : + enableval=$enable_ntpdate_step; ans=$enableval -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking PST/Traconex 1020 WWV/WWVH receiver" >&5 -$as_echo_n "checking PST/Traconex 1020 WWV/WWVH receiver... " >&6; } -# Check whether --enable-PST was given. -if test "${enable_PST+set}" = set; then : - enableval=$enable_PST; ntp_ok=$enableval -else - ntp_ok=$ntp_eac fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_PST 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +case "$ans" in + yes) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking RIPENCC specific Trimble driver" >&5 -$as_echo_n "checking RIPENCC specific Trimble driver... " >&6; } -# Check whether --enable-RIPENCC was given. -if test "${enable_RIPENCC+set}" = set; then : - enableval=$enable_RIPENCC; ntp_ok=$enableval -else - ntp_ok=no -fi +$as_echo "#define FORCE_NTPDATE_STEP 1" >>confdefs.h -# 020629: HMS: s/$ntp_eac -> -/no because of ptr += sprintf(ptr, ...) usage -case "$ac_cv_var_ripe_ncc_ok" in - no) ntp_ok=no ;; esac -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_RIPENCC /**/" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should sync TODR clock every hour" >&5 +$as_echo_n "checking if we should sync TODR clock every hour... " >&6; } -# Danny Meyer says SHM compiles (with a few warnings) under Win32. -# For *IX, we need sys/ipc.h and sys/shm.h. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHM clock attached thru shared memory" >&5 -$as_echo_n "checking for SHM clock attached thru shared memory... " >&6; } -# Check whether --enable-SHM was given. -if test "${enable_SHM+set}" = set; then : - enableval=$enable_SHM; ntp_ok=$enableval -else - case "$ntp_eac$ntp_canshm" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; +case "$host" in + *-*-nextstep*) + ans=yes + ;; + *-*-openvms*) # HMS: won't be found + ans=yes + ;; + *) + ans=no + ;; esac -fi - -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_SHM 1" >>confdefs.h +# Check whether --enable-hourly-todr-sync was given. +if test "${enable_hourly_todr_sync+set}" = set; then : + enableval=$enable_hourly_todr_sync; ans=$enableval fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Spectracom 8170/Netclock/2 WWVB receiver" >&5 -$as_echo_n "checking Spectracom 8170/Netclock/2 WWVB receiver... " >&6; } -# Check whether --enable-SPECTRACOM was given. -if test "${enable_SPECTRACOM+set}" = set; then : - enableval=$enable_SPECTRACOM; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -$as_echo "#define CLOCK_SPECTRACOM 1" >>confdefs.h +case "$ac_cv_var_sync_todr" in + yes) -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +$as_echo "#define DOSYNCTODR 1" >>confdefs.h + ;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking KSI/Odetics TPRO/S GPS receiver/IRIG interface" >&5 -$as_echo_n "checking KSI/Odetics TPRO/S GPS receiver/IRIG interface... " >&6; } -# Check whether --enable-TPRO was given. -if test "${enable_TPRO+set}" = set; then : - enableval=$enable_TPRO; ntp_ok=$enableval -else - case "$ac_cv_header_sys_tpro_h" in - yes) - ntp_ok=$ntp_eac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should avoid kernel FLL bug" >&5 +$as_echo_n "checking if we should avoid kernel FLL bug... " >&6; } + +case "$host" in + *-*-solaris2.6) + unamev=`uname -v` + case "$unamev" in + Generic_105181-*) + old_IFS="$IFS" + IFS="-" + set $unamev + IFS="$old_IFS" + if test "$2" -ge 17 + then + # Generic_105181-17 and higher + ans=no + else + ans=yes + fi + ;; + *) + ans=yes + ;; + esac + ;; + *-*-solaris2.7) + unamev=`uname -v` + case "$unamev" in + Generic_106541-*) + old_IFS="$IFS" + IFS="-" + set $unamev + IFS="$old_IFS" + if test "$2" -ge 07 + then + # Generic_106541-07 and higher + ans=no + else + ans=yes + fi ;; - *) ntp_ok=no + *) + ans=yes ;; esac -fi - -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes - -$as_echo "#define CLOCK_TPRO 1" >>confdefs.h - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ac_cv_header_sys_tpro" in - yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; + ;; + *) + ans=no + ;; esac +# Check whether --enable-kernel-fll-bug was given. +if test "${enable_kernel_fll_bug+set}" = set; then : + enableval=$enable_kernel_fll_bug; ans=$enableval -# Not on a vax-dec-bsd -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Kinemetrics/TrueTime receivers" >&5 -$as_echo_n "checking Kinemetrics/TrueTime receivers... " >&6; } -# Check whether --enable-TRUETIME was given. -if test "${enable_TRUETIME+set}" = set; then : - enableval=$enable_TRUETIME; ntp_ok=$enableval -else - case "$host" in - vax-dec-bsd) - ntp_ok=no - ;; - *) - ntp_ok=$ntp_eac - ;; - esac fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -$as_echo "#define CLOCK_TRUETIME 1" >>confdefs.h +case "$ans" in + yes) + +$as_echo "#define KERNEL_FLL_BUG 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$host" in - yesvax-dec-bsd) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking TrueTime 560 IRIG-B decoder" >&5 -$as_echo_n "checking TrueTime 560 IRIG-B decoder... " >&6; } -# Check whether --enable-TT560 was given. -if test "${enable_TT560+set}" = set; then : - enableval=$enable_TT560; ntp_ok=$enableval + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want new session key behavior" >&5 +$as_echo_n "checking if we want new session key behavior... " >&6; } +# Check whether --enable-bug1243-fix was given. +if test "${enable_bug1243_fix+set}" = set; then : + enableval=$enable_bug1243_fix; ans=$enableval else - ntp_ok=no + ans=yes + fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } +case "$ans" in + no) -$as_echo "#define CLOCK_TT560 /**/" >>confdefs.h +$as_echo "#define DISABLE_BUG1243_FIX 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Ultralink M320 WWVB receiver" >&5 -$as_echo_n "checking Ultralink M320 WWVB receiver... " >&6; } -# Check whether --enable-ULINK was given. -if test "${enable_ULINK+set}" = set; then : - enableval=$enable_ULINK; ntp_ok=$enableval -else - ntp_ok=$ntp_eac -fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use the IRIG sawtooth filter" >&5 +$as_echo_n "checking if we should use the IRIG sawtooth filter... " >&6; } -$as_echo "#define CLOCK_ULINK 1" >>confdefs.h +case "$host" in + *-*-solaris2.[89]) + ans=yes + ;; + *-*-solaris2.1[0-9]*) + ans=yes + ;; + *) ans=no + ;; +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +# Check whether --enable-irig-sawtooth was given. +if test "${enable_irig_sawtooth+set}" = set; then : + enableval=$enable_irig_sawtooth; ans=$enableval -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking WWV receiver" >&5 -$as_echo_n "checking WWV receiver... " >&6; } -# Check whether --enable-WWV was given. -if test "${enable_WWV+set}" = set; then : - enableval=$enable_WWV; ntp_ok=$enableval -else - case "$ntp_eac$ntp_canaudio" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; - esac fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_WWV 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +case "$ans" in + yes) + +$as_echo "#define IRIG_SUCKS 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canaudio" in - yesno) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** But the expected answer is... no ***" >&5 -$as_echo "$as_me: WARNING: *** But the expected answer is... no ***" >&2;} ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Zyfer receiver" >&5 -$as_echo_n "checking for Zyfer receiver... " >&6; } -# Check whether --enable-ZYFER was given. -if test "${enable_ZYFER+set}" = set; then : - enableval=$enable_ZYFER; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should enable NIST lockclock scheme" >&5 +$as_echo_n "checking if we should enable NIST lockclock scheme... " >&6; } +# Check whether --enable-nist was given. +if test "${enable_nist+set}" = set; then : + enableval=$enable_nist; ans=$enableval else - ntp_ok=$ntp_eac + ans=no + fi -if test "$ntp_ok" = "yes"; then - ntp_refclock=yes -$as_echo "#define CLOCK_ZYFER 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } +case "$ans" in + yes) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default inclusion of all suitable PARSE clocks" >&5 -$as_echo_n "checking for default inclusion of all suitable PARSE clocks... " >&6; } -# Check whether --enable-parse-clocks was given. -if test "${enable_parse_clocks+set}" = set; then : - enableval=$enable_parse_clocks; ntp_eapc=$enableval +$as_echo "#define LOCKCLOCK 1" >>confdefs.h + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want support for Samba's signing daemon" >&5 +$as_echo_n "checking if we want support for Samba's signing daemon... " >&6; } +# Check whether --enable-ntp-signd was given. +if test "${enable_ntp_signd+set}" = set; then : + enableval=$enable_ntp_signd; ans=$enableval else - case "$ntp_eac" in - yes) ntp_eapc=$ntp_canparse ;; - *) ntp_eapc=no ;; - esac - # Delete the next line one of these days - ntp_eapc=no + ans=no + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_eapc" >&5 -$as_echo "$ntp_eapc" >&6; } -case "$ntp_eac$ntp_eapc$ntp_canparse" in - noyes*) - as_fn_error "\"--enable-parse-clocks\" requires \"--enable-all-clocks\"." "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +case "$ans" in + no) + ntp_signd_path= ;; - yesyesno) - as_fn_error "You said \"--enable-parse-clocks\" but PARSE isn't supported on this platform!" "$LINENO" 5 + yes) + ntp_signd_path=/var/run/ntp_signd ;; - *) ;; + *) + ntp_signd_path="$ans" esac -ntp_libparse=no -ntp_parseutil=no -ntp_rawdcf=no +case "$ntp_signd_path" in + '') + ;; + *) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Diem Computime Radio Clock" >&5 -$as_echo_n "checking Diem Computime Radio Clock... " >&6; } -# Check whether --enable-COMPUTIME was given. -if test "${enable_COMPUTIME+set}" = set; then : - enableval=$enable_COMPUTIME; ntp_ok=$enableval -else - ntp_ok=$ntp_eapc -fi +$as_echo "#define HAVE_NTP_SIGND 1" >>confdefs.h -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes -$as_echo "#define CLOCK_COMPUTIME 1" >>confdefs.h +cat >>confdefs.h <<_ACEOF +#define NTP_SIGND_PATH "$ntp_signd_path" +_ACEOF -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ELV/DCF7000 clock" >&5 -$as_echo_n "checking ELV/DCF7000 clock... " >&6; } -# Check whether --enable-DCF7000 was given. -if test "${enable_DCF7000+set}" = set; then : - enableval=$enable_DCF7000; ntp_ok=$enableval -else - ntp_ok=$ntp_eapc +for ac_header in libscf.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "libscf.h" "ac_cv_header_libscf_h" "$ac_includes_default" +if test "x$ac_cv_header_libscf_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBSCF_H 1 +_ACEOF + fi -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes +done + +LSCF= +case "$ac_cv_header_libscf_h" in + yes) + LSCF='-lscf' +esac + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5 +$as_echo_n "checking for struct sockaddr_storage... " >&6; } +if ${ntp_cv_sockaddr_storage+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + +int +main () +{ -$as_echo "#define CLOCK_DCF7000 1" >>confdefs.h + struct sockaddr_storage n; -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking HOPF 6021 clock" >&5 -$as_echo_n "checking HOPF 6021 clock... " >&6; } -# Check whether --enable-HOPF6021 was given. -if test "${enable_HOPF6021+set}" = set; then : - enableval=$enable_HOPF6021; ntp_ok=$enableval + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_sockaddr_storage=yes else - ntp_ok=$ntp_eapc -fi - -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes - -$as_echo "#define CLOCK_HOPF6021 1" >>confdefs.h + ntp_cv_sockaddr_storage=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; -esac +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Meinberg clocks" >&5 -$as_echo_n "checking Meinberg clocks... " >&6; } -# Check whether --enable-MEINBERG was given. -if test "${enable_MEINBERG+set}" = set; then : - enableval=$enable_MEINBERG; ntp_ok=$enableval -else - ntp_ok=$ntp_eapc fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_sockaddr_storage" >&5 +$as_echo "$ntp_cv_sockaddr_storage" >&6; } +case "$ntp_cv_sockaddr_storage" in + yes) -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes +$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h -$as_echo "#define CLOCK_MEINBERG 1" >>confdefs.h + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_family" >&5 +$as_echo_n "checking for sockaddr_storage.__ss_family... " >&6; } +if ${ntp_cv_have___ss_family+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; -esac + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking DCF77 raw time code" >&5 -$as_echo_n "checking DCF77 raw time code... " >&6; } -# Check whether --enable-RAWDCF was given. -if test "${enable_RAWDCF+set}" = set; then : - enableval=$enable_RAWDCF; ntp_ok=$enableval -else - ntp_ok=$ntp_eapc -fi +int +main () +{ -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_parseutil=yes - ntp_refclock=yes - ntp_rawdcf=yes + struct sockaddr_storage s; + s.__ss_family = 1; -$as_echo "#define CLOCK_RAWDCF 1" >>confdefs.h + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_have___ss_family=yes +else + ntp_cv_have___ss_family=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; -esac +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -case "$ntp_rawdcf" in - yes) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we must enable parity for RAWDCF" >&5 -$as_echo_n "checking if we must enable parity for RAWDCF... " >&6; } -if test "${ac_cv_var_rawdcf_parity+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ans=no - case "$host" in - *-*-*linux*) - ans=yes - ;; - esac - ac_cv_var_rawdcf_parity=$ans fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_rawdcf_parity" >&5 -$as_echo "$ac_cv_var_rawdcf_parity" >&6; } - case "$ac_cv_var_rawdcf_parity" in +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_family" >&5 +$as_echo "$ntp_cv_have___ss_family" >&6; } + case "$ntp_cv_have___ss_family" in yes) -$as_echo "#define RAWDCF_NO_IGNPAR 1" >>confdefs.h - ;; + +$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h + esac - ;; - *) # HMS: Is this a good idea? - ac_cv_var_rawdcf_parity=no - ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking RCC 8000 clock" >&5 -$as_echo_n "checking RCC 8000 clock... " >&6; } -# Check whether --enable-RCC8000 was given. -if test "${enable_RCC8000+set}" = set; then : - enableval=$enable_RCC8000; ntp_ok=$enableval + +# +# Look for in_port_t. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5 +$as_echo_n "checking for in_port_t... " >&6; } +if ${isc_cv_have_in_port_t+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=$ntp_eapc -fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes + #include + #include -$as_echo "#define CLOCK_RCC8000 1" >>confdefs.h +int +main () +{ -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; -esac + in_port_t port = 25; + return (0); -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Schmid DCF77 clock" >&5 -$as_echo_n "checking Schmid DCF77 clock... " >&6; } -# Check whether --enable-SCHMID was given. -if test "${enable_SCHMID+set}" = set; then : - enableval=$enable_SCHMID; ntp_ok=$enableval + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_have_in_port_t=yes else - ntp_ok=$ntp_eapc + isc_cv_have_in_port_t=no + fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in_port_t" >&5 +$as_echo "$isc_cv_have_in_port_t" >&6; } +case "$isc_cv_have_in_port_t" in + no) -$as_echo "#define CLOCK_SCHMID 1" >>confdefs.h +$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Trimble GPS receiver/TAIP protocol" >&5 -$as_echo_n "checking Trimble GPS receiver/TAIP protocol... " >&6; } -# Check whether --enable-TRIMTAIP was given. -if test "${enable_TRIMTAIP+set}" = set; then : - enableval=$enable_TRIMTAIP; ntp_ok=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking type of socklen arg for getsockname()" >&5 +$as_echo_n "checking type of socklen arg for getsockname()... " >&6; } +if ${ntp_cv_getsockname_socklen_type+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=$ntp_eapc -fi -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes + getsockname_socklen_type_found=no + for getsockname_arg2 in 'struct sockaddr *' 'void *'; do + for ntp_cv_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -$as_echo "#define CLOCK_TRIMTAIP 1" >>confdefs.h + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; -esac +int +main () +{ -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking Trimble GPS receiver/TSIP protocol" >&5 -$as_echo_n "checking Trimble GPS receiver/TSIP protocol... " >&6; } -# Check whether --enable-TRIMTSIP was given. -if test "${enable_TRIMTSIP+set}" = set; then : - enableval=$enable_TRIMTSIP; ntp_ok=$enableval -else - ntp_ok=$ntp_eapc -fi + extern + getsockname(int, $getsockname_arg2, + $ntp_cv_getsockname_socklen_type *); -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes -$as_echo "#define CLOCK_TRIMTSIP 1" >>confdefs.h + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + getsockname_socklen_type_found=yes ; break 2 +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done + done + case "$getsockname_socklen_type_found" in + no) + ntp_cv_getsockname_socklen_type='socklen_t' + esac + { getsockname_arg2=; unset getsockname_arg2;} + { getsockname_socklen_type_found=; unset getsockname_socklen_type_found;} + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; -esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_getsockname_socklen_type" >&5 +$as_echo "$ntp_cv_getsockname_socklen_type" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking WHARTON 400A Series clock" >&5 -$as_echo_n "checking WHARTON 400A Series clock... " >&6; } -# Check whether --enable-WHARTON was given. -if test "${enable_WHARTON+set}" = set; then : - enableval=$enable_WHARTON; ntp_ok=$enableval +cat >>confdefs.h <<_ACEOF +#define GETSOCKNAME_SOCKLEN_TYPE $ntp_cv_getsockname_socklen_type +_ACEOF + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5 +$as_echo_n "checking struct sockaddr for sa_len... " >&6; } +if ${isc_cv_platform_havesalen+:} false; then : + $as_echo_n "(cached) " >&6 else - ntp_ok=$ntp_eapc -fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes + #include + #include -$as_echo "#define CLOCK_WHARTON_400A 1" >>confdefs.h +int +main () +{ + + extern struct sockaddr *ps; + return ps->sa_len; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_platform_havesalen=yes +else + isc_cv_platform_havesalen=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_platform_havesalen" >&5 +$as_echo "$isc_cv_platform_havesalen" >&6; } +case "$isc_cv_platform_havesalen" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVESALEN 1" >>confdefs.h + esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking VARITEXT clock" >&5 -$as_echo_n "checking VARITEXT clock... " >&6; } -# Check whether --enable-VARITEXT was given. -if test "${enable_VARITEXT+set}" = set; then : - enableval=$enable_VARITEXT; ntp_ok=$enableval -else - ntp_ok=$ntp_eapc +# Check whether --enable-ipv6 was given. +if test "${enable_ipv6+set}" = set; then : + enableval=$enable_ipv6; fi -if test "$ntp_ok" = "yes"; then - ntp_libparse=yes - ntp_refclock=yes -$as_echo "#define CLOCK_VARITEXT 1" >>confdefs.h +case "$enable_ipv6" in + yes|''|autodetect) + case "$host" in + powerpc-ibm-aix4*) + ;; + *) -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 -$as_echo "$ntp_ok" >&6; } -case "$ntp_ok$ntp_canparse" in - yesno) - as_fn_error "That's a parse clock and this system doesn't support it!" "$LINENO" 5 +$as_echo "#define WANT_IPV6 1" >>confdefs.h + + ;; + esac + ;; + no) ;; esac +case "$host" in + *-*-darwin*) +$as_echo "#define __APPLE_USE_RFC_3542 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to make and use the parse libraries" >&5 -$as_echo_n "checking if we need to make and use the parse libraries... " >&6; } -ans=no -case "$ntp_libparse" in - yes) - ans=yes - -$as_echo "#define CLOCK_PARSE 1" >>confdefs.h +esac - LIBPARSE=../libparse/libparse.a - MAKE_LIBPARSE=libparse.a - # HMS: check_y2k trips the 34 year problem now... - false && MAKE_CHECK_Y2K=check_y2k -$as_echo "#define PPS_SAMPLE 1" >>confdefs.h +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 structures" >&5 +$as_echo_n "checking for IPv6 structures... " >&6; } +if ${isc_cv_found_ipv6+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - $as_echo "#define CLOCK_ATOM 1" >>confdefs.h + #include + #include + #include - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +int +main () +{ -# AC_SUBST(RSAOBJS) -# AC_SUBST(RSASRCS) -# AC_SUBST(RSADIR) -# AC_SUBST(RSAREF) -# AC_SUBST(LIBRSAREF) -# AC_SUBST(MAKE_LIBRSAREF) + struct sockaddr_in6 sin6; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_found_ipv6=yes +else + isc_cv_found_ipv6=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_found_ipv6" >&5 +$as_echo "$isc_cv_found_ipv6" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5 -$as_echo_n "checking for openssl library directory... " >&6; } +# +# See whether IPv6 support is provided via a Kame add-on. +# This is done before other IPv6 linking tests so LIBS is properly set. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kame IPv6 support" >&5 +$as_echo_n "checking for Kame IPv6 support... " >&6; } -# Check whether --with-openssl-libdir was given. -if test "${with_openssl_libdir+set}" = set; then : - withval=$with_openssl_libdir; ans=$withval +# Check whether --with-kame was given. +if test "${with_kame+set}" = set; then : + withval=$with_kame; use_kame="$withval" else - case "$build" in - $host) ans=yes ;; - *) ans=no ;; -esac + use_kame="no" + fi -case "$ans" in - no) ;; - yes) # Look in: - ans="/usr/lib /usr/lib/openssl /usr/sfw/lib /usr/local/lib /usr/local/ssl/lib" +case "$use_kame" in + no) ;; - *) # Look where they said + yes) + kame_path=/usr/local/v6 ;; -esac -case "$ans" in - no) ;; - *) # Look for libcrypto.a and libssl.a: - for i in $ans no - do - case "$host" in - *-*-darwin*) - test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break - ;; - *) - test -f $i/libcrypto.so -a -f $i/libssl.so && break - test -f $i/libcrypto.a -a -f $i/libssl.a && break - ;; - esac - done - case "$i" in - no) - ans=no - OPENSSL_LIB= - ;; - *) ans=$i - OPENSSL_LIB=$ans - ;; - esac + *) + kame_path="$use_kame" ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +case "$use_kame" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) + if test -f $kame_path/lib/libinet6.a; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $kame_path/lib/libinet6.a" >&5 +$as_echo "$kame_path/lib/libinet6.a" >&6; } + LIBS="-L$kame_path/lib -linet6 $LIBS" + else + as_fn_error $? "$kame_path/lib/libinet6.a not found. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl include directory" >&5 -$as_echo_n "checking for openssl include directory... " >&6; } +Please choose the proper path with the following command: -# Check whether --with-openssl-incdir was given. -if test "${with_openssl_incdir+set}" = set; then : - withval=$with_openssl_incdir; ans=$withval -else - case "$build" in - $host) ans=yes ;; - *) ans=no ;; + configure --with-kame=PATH +" "$LINENO" 5 + fi + ;; esac -fi -case "$ans" in - no) ;; - yes) # look in: - ans="/usr/include /usr/sfw/include /usr/local/include /usr/local/ssl/include" +# +# Whether netinet6/in6.h is needed has to be defined in isc/platform.h. +# Including it on Kame-using platforms is very bad, though, because +# Kame uses #error against direct inclusion. So include it on only +# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1. +# This is done before the in6_pktinfo check because that's what +# netinet6/in6.h is needed for. +# +case "$host" in + *-bsdi4.[01]*) + +$as_echo "#define ISC_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h + + isc_netinet6in6_hack="#include " ;; - *) # Look where they said + *) + isc_netinet6in6_hack="" ;; esac -case "$ans" in - no) ;; - *) # look for openssl/opensslconf.h: - for i in $ans no - do - test -f $i/openssl/opensslconf.h && break - done - case "$i" in - no) - ans=no - OPENSSL_INC= - ;; - *) ans=$i - OPENSSL_INC=$ans - ;; - esac + +# +# This is similar to the netinet6/in6.h issue. +# +case "$host" in + *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) + +$as_echo "#define ISC_PLATFORM_FIXIN6ISADDR 1" >>confdefs.h + + isc_netinetin6_hack="#include " + ;; + *) + isc_netinetin6_hack="" ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } - -# Check whether --with-crypto was given. -if test "${with_crypto+set}" = set; then : - withval=$with_crypto; ans=$withval -else - ans=yes -fi -case "$ans" in - no) ;; - yes|openssl) - if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INC" - then - ans=no - else - # We have OpenSSL inc/lib - use them. - ans=openssl - CPPFLAGS="$CPPFLAGS -I$OPENSSL_INC" - LDFLAGS="$LDFLAGS -L$OPENSSL_LIB" - case "$need_dash_r" in - 1) LDFLAGS="$LDFLAGS -R$OPENSSL_LIB" - ;; - esac - LCRYPTO=-lcrypto +case "$isc_cv_found_ipv6" in + yes) +$as_echo "#define ISC_PLATFORM_HAVEIPV6 1" >>confdefs.h -$as_echo "#define OPENSSL /**/" >>confdefs.h + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6_pktinfo" >&5 +$as_echo_n "checking for in6_pktinfo... " >&6; } +if ${isc_cv_have_in6_pktinfo+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - for ac_func in EVP_md2 EVP_mdc2 -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack -fi -done +int +main () +{ - fi - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the level of crypto support" >&5 -$as_echo_n "checking for the level of crypto support... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } + struct in6_pktinfo xyzzy; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to compile with ElectricFence" >&5 -$as_echo_n "checking if we want to compile with ElectricFence... " >&6; } -# Check whether --with-electricfence was given. -if test "${with_electricfence+set}" = set; then : - withval=$with_electricfence; ans=$withval + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_have_in6_pktinfo=yes else - ans=no + isc_cv_have_in6_pktinfo=no + fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -case "$ans" in - no) ;; - *) - LIBS="$LIBS \${top_builddir}/ElectricFence/libefence.a" - EF_PROGS="eftest tstheap" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in6_pktinfo" >&5 +$as_echo "$isc_cv_have_in6_pktinfo" >&6; } + case "$isc_cv_have_in6_pktinfo" in + yes) - EF_LIBS=libefence.a +$as_echo "#define ISC_PLATFORM_HAVEIN6PKTINFO 1" >>confdefs.h - ans=yes - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } + esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to run check-layout" >&5 -$as_echo_n "checking if we want to run check-layout... " >&6; } -case "$cross_compiling$PATH_PERL" in - no/*) - MAKE_CHECK_LAYOUT=check-layout - ans=yes - ;; - *) - ans=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } + # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead? + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_in6.sin6_scope_id" >&5 +$as_echo_n "checking for sockaddr_in6.sin6_scope_id... " >&6; } +if ${isc_cv_have_sin6_scope_id+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack +int +main () +{ + struct sockaddr_in6 xyzzy; + xyzzy.sin6_scope_id = 0; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_have_sin6_scope_id=yes +else + isc_cv_have_sin6_scope_id=no -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can make dcf parse utilities" >&5 -$as_echo_n "checking if we can make dcf parse utilities... " >&6; } -ans=no -if test "$ntp_parseutil" = "yes"; then - case "$host" in - *-*-sunos4*|*-*-solaris2*|*-*-*linux*|*-*-netbsd*) - ans="dcfd testdcf" - DCFD=dcfd - TESTDCF=testdcf - ;; - esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_sin6_scope_id" >&5 +$as_echo "$isc_cv_have_sin6_scope_id" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can build kernel streams modules for parse" >&5 -$as_echo_n "checking if we can build kernel streams modules for parse... " >&6; } -ans=no -case "$ntp_parseutil$ac_cv_header_sys_stropts_h" in - yesyes) - case "$host" in - sparc-*-sunos4*) - case "$ac_cv_var_kernel_pll" in - yes) + case "$isc_cv_have_sin6_scope_id" in + yes) -$as_echo "#define PPS_SYNC 1" >>confdefs.h +$as_echo "#define ISC_PLATFORM_HAVESCOPEID 1" >>confdefs.h - ;; - esac - ans=parsestreams - MAKE_PARSEKMODULE=parsestreams.loadable_module.o - ;; - sparc-*-solaris2*) - ans=parsesolaris - MAKE_PARSEKMODULE=parse - ;; esac - ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need basic refclock support" >&5 -$as_echo_n "checking if we need basic refclock support... " >&6; } -if test "$ntp_refclock" = "yes"; then -$as_echo "#define REFCLOCK 1" >>confdefs.h +# We need this check run even without isc_cv_found_ipv6=yes -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_refclock" >&5 -$as_echo "$ntp_refclock" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5 +$as_echo_n "checking for in6addr_any... " >&6; } +if ${isc_cv_in6addr_any_links+:} false; then : + $as_echo_n "(cached) " >&6 +else + SAVED_LIBS="$LIBS" + LIBS="$LDADD_LIBNTP $LIBS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack +int +main () +{ -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want HP-UX adjtimed support" >&5 -$as_echo_n "checking if we want HP-UX adjtimed support... " >&6; } -case "$host" in - *-*-hpux[56789]*) - ans=yes - ;; - *) ans=no - ;; -esac -if test "$ans" = "yes"; then - MAKE_ADJTIMED=adjtimed + printf("%x", in6addr_any.s6_addr[15]); -$as_echo "#define NEED_HPUX_ADJTIME 1" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + isc_cv_in6addr_any_links=yes +else + isc_cv_in6addr_any_links=no -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want QNX adjtime support" >&5 -$as_echo_n "checking if we want QNX adjtime support... " >&6; } -case "$host" in - *-*-qnx*) - ans=yes - ;; - *) ans=no - ;; -esac -if test "$ans" = "yes"; then +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$SAVED_LIBS" + { SAVED_LIBS=; unset SAVED_LIBS;} -$as_echo "#define NEED_QNX_ADJTIME 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_in6addr_any_links" >&5 +$as_echo "$isc_cv_in6addr_any_links" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can read kmem" >&5 -$as_echo_n "checking if we can read kmem... " >&6; } +case "$isc_cv_in6addr_any_links" in + no) -# the default is to enable it if the system has the capability +$as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY 1" >>confdefs.h -case "$ac_cv_func_nlist$ac_cv_func_K_open$ac_cv_func_kvm_open" in - *yes*) - ans=yes - ;; - *) ans=no esac -case "$host" in - *-*-domainos) # Won't be found... - ans=no - ;; - *-*-hpux*) - #ans=no - ;; - *-*-irix[456]*) - ans=no - ;; - *-*-*linux*) - ans=no - ;; - *-*-winnt3.5) - ans=no - ;; - *-*-unicosmp*) - ans=no - ;; -esac -# --enable-kmem / --disable-kmem controls if present -# Check whether --enable-kmem was given. -if test "${enable_kmem+set}" = set; then : - enableval=$enable_kmem; ans=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrconf" >&5 +$as_echo_n "checking for struct if_laddrconf... " >&6; } +if ${isc_cv_struct_if_laddrconf+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi + #include + #include +int +main () +{ -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } + struct if_laddrconf a; -case "$ans" in - yes) - can_kmem=yes - ;; - *) - can_kmem=no -$as_echo "#define NOKMEM 1" >>confdefs.h + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_struct_if_laddrconf=yes +else + isc_cv_struct_if_laddrconf=no -esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrconf" >&5 +$as_echo "$isc_cv_struct_if_laddrconf" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if adjtime is accurate" >&5 -$as_echo_n "checking if adjtime is accurate... " >&6; } +case "$isc_cv_struct_if_laddrconf" in + yes) -# target-dependent defaults +$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRCONF 1" >>confdefs.h -case "$host" in - i386-sequent-ptx*) - ans=no - ;; - i386-unknown-osf1*) - ans=yes - ;; - mips-sgi-irix[456]*) - ans=yes - ;; - *-fujitsu-uxp*) - ans=yes - ;; - *-ibm-aix[456]*) - ans=yes - ;; - *-*-*linux*) - ans=yes - ;; - *-*-solaris2.[01]) - ans=no - ;; - *-*-solaris2*) - ans=yes - ;; - *-*-unicosmp*) - ans=yes - ;; - *) ans=no esac -# --enable-accurate-adjtime / --disable-accurate-adjtime -# override the default -# Check whether --enable-accurate-adjtime was given. -if test "${enable_accurate_adjtime+set}" = set; then : - enableval=$enable_accurate_adjtime; ans=$enableval -fi - +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrreq" >&5 +$as_echo_n "checking for struct if_laddrreq... " >&6; } +if ${isc_cv_struct_if_laddrreq+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } + #include + #include -case "$ans" in - yes) +int +main () +{ -$as_echo "#define ADJTIME_IS_ACCURATE 1" >>confdefs.h + struct if_laddrreq a; - adjtime_is_accurate=yes - ;; - *) - adjtime_is_accurate=no -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name of 'tick' in the kernel" >&5 -$as_echo_n "checking the name of 'tick' in the kernel... " >&6; } -if test "${ac_cv_var_nlist_tick+set}" = set; then : - $as_echo_n "(cached) " >&6 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_struct_if_laddrreq=yes else - ans=_tick -case "$host" in - m68*-hp-hpux*) # HP9000/300? - ans=_old_tick - ;; - *-apple-aux[23]*) - ans=tick - ;; - *-hp-hpux*) - ans=old_tick - ;; - *-ibm-aix[3456]*) - ans=no - ;; - *-*-mpeix*) - ans=no - ;; - *-*-ptx*) - ans=tick - ;; - *-*-sco3.2v[45]*) - ans=no - ;; - *-*-solaris2*) - ans=nsec_per_tick - ;; - *-*-sysv4*) - ans=tick - ;; -esac -ac_cv_var_nlist_tick=$ans + isc_cv_struct_if_laddrreq=no + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_nlist_tick" >&5 -$as_echo "$ac_cv_var_nlist_tick" >&6; } -case "$ac_cv_var_nlist_tick" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) -cat >>confdefs.h <<_ACEOF -#define K_TICK_NAME "$ac_cv_var_nlist_tick" -_ACEOF - ;; +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrreq" >&5 +$as_echo "$isc_cv_struct_if_laddrreq" >&6; } + +case "$isc_cv_struct_if_laddrreq" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRREQ 1" >>confdefs.h + esac -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the units of 'tick'" >&5 -$as_echo_n "checking for the units of 'tick'... " >&6; } -if test "${ac_cv_var_tick_nano+set}" = set; then : + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multicast IP support" >&5 +$as_echo_n "checking for multicast IP support... " >&6; } +if ${ntp_cv_multicast+:} false; then : $as_echo_n "(cached) " >&6 else - ans=usec -case "$host" in - *-*-solaris2*) - ans=nsec - ;; -esac -ac_cv_var_tick_nano=$ans + + ntp_cv_multicast=no + case "$host" in + i386-sequent-sysv4) + ;; + *) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_NETINET_IN_H + # include + #endif + +int +main () +{ + + struct ip_mreq ipmr; + ipmr.imr_interface.s_addr = 0; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_multicast=yes fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tick_nano" >&5 -$as_echo "$ac_cv_var_tick_nano" >&6; } -case "$ac_cv_var_tick_nano" in - nsec) +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ;; + esac -$as_echo "#define TICK_NANO 1" >>confdefs.h - ;; -esac -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name of 'tickadj' in the kernel" >&5 -$as_echo_n "checking the name of 'tickadj' in the kernel... " >&6; } -if test "${ac_cv_var_nlist_tickadj+set}" = set; then : +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_multicast" >&5 +$as_echo "$ntp_cv_multicast" >&6; } +case "$ntp_cv_multicast" in + yes) + +$as_echo "#define MCAST 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for setsockopt() IP*_MULTICAST_LOOP" >&5 +$as_echo_n "checking arg type needed for setsockopt() IP*_MULTICAST_LOOP... " >&6; } +if ${ntp_cv_typeof_ip_multicast_loop+:} false; then : $as_echo_n "(cached) " >&6 else - ans=_tickadj -case "$host" in - m68*-hp-hpux*) # HP9000/300? - ans=_tickadj - ;; - *-apple-aux[23]*) - ans=tickadj - ;; - *-hp-hpux10*) - ans=no - ;; - *-hp-hpux9*) - ans=no - ;; - *-hp-hpux*) - ans=tickadj - ;; - *-*-aix*) - ans=tickadj - ;; - *-*-mpeix*) - ans=no - ;; - *-*-ptx*) - ans=tickadj - ;; - *-*-sco3.2v4*) - ans=no - ;; - *-*-sco3.2v5.0*) - ans=clock_drift - ;; - *-*-solaris2*) - ans=no # hrestime_adj - ;; - *-*-sysv4*) - ans=tickadj - ;; -esac -ac_cv_var_nlist_tickadj=$ans + + case "$host" in + *-*-netbsd*|*-*-*linux*) + ntp_cv_typeof_ip_multicast_loop=u_int + ;; + *) + ntp_cv_typeof_ip_multicast_loop=u_char + ;; + esac + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_nlist_tickadj" >&5 -$as_echo "$ac_cv_var_nlist_tickadj" >&6; } -case "$ac_cv_var_nlist_tickadj" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_typeof_ip_multicast_loop" >&5 +$as_echo "$ntp_cv_typeof_ip_multicast_loop" >&6; } + cat >>confdefs.h <<_ACEOF -#define K_TICKADJ_NAME "$ac_cv_var_nlist_tickadj" +#define TYPEOF_IP_MULTICAST_LOOP $ntp_cv_typeof_ip_multicast_loop _ACEOF - ;; + esac -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the units of 'tickadj'" >&5 -$as_echo_n "checking for the units of 'tickadj'... " >&6; } -if test "${ac_cv_var_tickadj_nano+set}" = set; then : - $as_echo_n "(cached) " >&6 + +# Check whether --enable-getifaddrs was given. +if test "${enable_getifaddrs+set}" = set; then : + enableval=$enable_getifaddrs; want_getifaddrs="$enableval" else - ans=usec -case "$host" in - *-*-solaris2*) - ans=nsec - ;; -esac -ac_cv_var_tickadj_nano=$ans + want_getifaddrs="yes" + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tickadj_nano" >&5 -$as_echo "$ac_cv_var_tickadj_nano" >&6; } -case "$ac_cv_var_tickadj_nano" in - nsec) -$as_echo "#define TICKADJ_NANO 1" >>confdefs.h - ;; +case $want_getifaddrs in + glibc) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-getifaddrs=glibc is no longer required" >&5 +$as_echo "$as_me: WARNING: --enable-getifaddrs=glibc is no longer required" >&2;} esac -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking half-heartedly for 'dosynctodr' in the kernel" >&5 -$as_echo_n "checking half-heartedly for 'dosynctodr' in the kernel... " >&6; } -if test "${ac_cv_var_nlist_dosynctodr+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case "$host" in - *-apple-aux[23]*) - ans=no - ;; - *-sni-sysv*) - ans=dosynctodr - ;; - *-*-aix*) - ans=dosynctodr - ;; - *-*-hpux*) - ans=no - ;; - *-*-mpeix*) - ans=no - ;; - *-*-nextstep*) - ans=_dosynctodr - ;; - *-*-ptx*) - ans=doresettodr - ;; - *-*-sco3.2v4*) - ans=no - ;; - *-*-sco3.2v5*) - ans=track_rtc - ;; - *-*-solaris2*) - ans=dosynctodr - ;; - *-*-sysv4*) - ans=doresettodr - ;; - *) - ans=_dosynctodr +case $want_getifaddrs in + no) ;; -esac -ac_cv_var_nlist_dosynctodr=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_nlist_dosynctodr" >&5 -$as_echo "$ac_cv_var_nlist_dosynctodr" >&6; } -case "$ac_cv_var_nlist_dosynctodr" in - no) ;; *) -cat >>confdefs.h <<_ACEOF -#define K_DOSYNCTODR_NAME "$ac_cv_var_nlist_dosynctodr" + SAVED_LIBS="$LIBS" + LIBS="$LDADD_LIBNTP $LIBS" + for ac_func in getifaddrs +do : + ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs" +if test "x$ac_cv_func_getifaddrs" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_GETIFADDRS 1 _ACEOF - ;; +fi +done + + LIBS="$SAVED_LIBS" + { SAVED_LIBS=; unset SAVED_LIBS;} + ;; esac + # -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking half-heartedly for 'noprintf' in the kernel" >&5 -$as_echo_n "checking half-heartedly for 'noprintf' in the kernel... " >&6; } -if test "${ac_cv_var_nlist_noprintf+set}" = set; then : +# Check for if_nametoindex() for IPv6 scoped addresses support +# +case "$host" in + *-hp-hpux*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing if_nametoindex" >&5 +$as_echo_n "checking for library containing if_nametoindex... " >&6; } +if ${ac_cv_search_if_nametoindex+:} false; then : $as_echo_n "(cached) " >&6 else - case "$host" in - *-apple-aux[23]*) - ans=no - ;; - *-sni-sysv*) - ans=noprintf - ;; - *-*-aix*) - ans=noprintf - ;; - *-*-hpux*) - ans=no - ;; - *-*-mpeix*) - ans=no - ;; - *-*-ptx*) - ans=noprintf - ;; - *-*-nextstep*) - ans=_noprintf - ;; - *-*-solaris2*) - ans=noprintf - ;; - *-*-sysv4*) - ans=noprintf - ;; - *) - ans=_noprintf - ;; -esac -ac_cv_var_nlist_noprintf=$ans -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_nlist_noprintf" >&5 -$as_echo "$ac_cv_var_nlist_noprintf" >&6; } -case "$ac_cv_var_nlist_noprintf" in - no) ;; - *) -cat >>confdefs.h <<_ACEOF -#define K_NOPRINTF_NAME "$ac_cv_var_nlist_noprintf" + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char if_nametoindex (); +int +main () +{ +return if_nametoindex (); + ; + return 0; +} _ACEOF +for ac_lib in '' ipv6; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_if_nametoindex=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_if_nametoindex+:} false; then : + break +fi +done +if ${ac_cv_search_if_nametoindex+:} false; then : - ;; -esac +else + ac_cv_search_if_nametoindex=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_if_nametoindex" >&5 +$as_echo "$ac_cv_search_if_nametoindex" >&6; } +ac_res=$ac_cv_search_if_nametoindex +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +fi +esac +SAVED_LIBS="$LIBS" +LIBS="$LDADD_LIBNTP $LIBS" +for ac_func in if_nametoindex +do : + ac_fn_c_check_func "$LINENO" "if_nametoindex" "ac_cv_func_if_nametoindex" +if test "x$ac_cv_func_if_nametoindex" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_IF_NAMETOINDEX 1 +_ACEOF +fi +done -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a default value for 'tick'" >&5 -$as_echo_n "checking for a default value for 'tick'... " >&6; } +LIBS="$SAVED_LIBS" +{ SAVED_LIBS=; unset SAVED_LIBS;} +case "$ac_cv_func_if_nametoindex" in + yes) -# target-dependent default for tick +$as_echo "#define ISC_PLATFORM_HAVEIFNAMETOINDEX 1" >>confdefs.h -case "$host" in - *-*-pc-cygwin*) - as_fn_error "tick needs work for cygwin" "$LINENO" 5 - ;; - *-univel-sysv*) - ans=10000 - ;; - *-*-irix*) - ans=10000 - ;; - *-*-*linux*) - ans=txc.tick - ;; - *-*-mpeix*) - ans=no - ;; - *-*-winnt3.5) - ans='(every / 10)' - ;; - *-*-unicosmp*) - ans=10000 - ;; - *) - ans='1000000L/hz' - ;; esac -# Check whether --enable-tick was given. -if test "${enable_tick+set}" = set; then : - enableval=$enable_tick; ans=$enableval -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +# +# Look for a sysctl call to get the list of network interfaces. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for interface list sysctl" >&5 +$as_echo_n "checking for interface list sysctl... " >&6; } +if ${ntp_cv_iflist_sysctl+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + #include + #ifndef NET_RT_IFLIST + # error + #endif -case "$ans" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) -cat >>confdefs.h <<_ACEOF -#define PRESET_TICK $ans _ACEOF - ;; +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_cv_iflist_sysctl=yes +else + ntp_cv_iflist_sysctl=no + +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_iflist_sysctl" >&5 +$as_echo "$ntp_cv_iflist_sysctl" >&6; } +case "$ntp_cv_iflist_sysctl" in + yes) + +$as_echo "#define HAVE_IFLIST_SYSCTL 1" >>confdefs.h + esac +### -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a default value for 'tickadj'" >&5 -$as_echo_n "checking for a default value for 'tickadj'... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the saveconfig mechanism" >&5 +$as_echo_n "checking if we want the saveconfig mechanism... " >&6; } +# Check whether --enable-saveconfig was given. +if test "${enable_saveconfig+set}" = set; then : + enableval=$enable_saveconfig; ntp_ok=$enableval +else + ntp_ok=yes -# target-specific default +fi -ans='500/hz' +ntp_saveconfig_enabled=0 +case "$ntp_ok" in + yes) + ntp_saveconfig_enabled=1 + +$as_echo "#define SAVECONFIG 1" >>confdefs.h -case "$host" in - *-fujitsu-uxp*) - case "$adjtime_is_accurate" in - yes) - ans='tick/16' - esac - ;; - XXX-*-pc-cygwin*) - ans=no - ;; - *-univel-sysv*) - ans=80 - ;; - *-*-aix*) - case "$can_kmem" in - no) - ans=1000 - esac - ;; - *-*-domainos) # Skippy: won't be found... - case "$can_kmem" in - no) - ans=668 - esac - ;; - *-*-hpux*) - case "$adjtime_is_accurate" in - yes) - ans='tick/16' - esac - ;; - *-*-irix*) - ans=150 - ;; - *-*-mpeix*) - ans=no - ;; - *-*-sco3.2v5.0*) - ans=10000L/hz - ;; - *-*-winnt3.5) - ans=50 ;; - *-*-unicosmp*) - ans=150 esac + if test x$ntp_saveconfig_enabled = x1; then + SAVECONFIG_ENABLED_TRUE= + SAVECONFIG_ENABLED_FALSE='#' +else + SAVECONFIG_ENABLED_TRUE='#' + SAVECONFIG_ENABLED_FALSE= +fi -# Check whether --enable-tickadj was given. -if test "${enable_tickadj+set}" = set; then : - enableval=$enable_tickadj; ans=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } + +### + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the experimental leap smear code" >&5 +$as_echo_n "checking if we want the experimental leap smear code... " >&6; } +# Check whether --enable-leap-smear was given. +if test "${enable_leap_smear+set}" = set; then : + enableval=$enable_leap_smear; ntp_ok=$enableval +else + ntp_ok=no fi +ntp_leap_smear_enabled=0 +case "$ntp_ok" in + yes) + ntp_leap_smear_enabled=1 -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +$as_echo "#define LEAP_SMEAR 1" >>confdefs.h -default_tickadj=$ans -case "$default_tickadj" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) -cat >>confdefs.h <<_ACEOF -#define PRESET_TICKADJ $default_tickadj -_ACEOF - ;; + HAVE_LEAPSMEARINTERVAL="leapsmearinterval 0" + ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -# Newer versions of ReliantUNIX round adjtime() values down to -# 1/100s (system tick). Sigh ... -# Unfortunately, there is no easy way to know if particular release -# has this "feature" or any obvious way to test for it. -case "$host" in - mips-sni-sysv4*) -$as_echo "#define RELIANTUNIX_CLOCK 1" >>confdefs.h - ;; -esac -case "$host" in - *-*-sco3.2v5*) -$as_echo "#define SCO5_CLOCK 1" >>confdefs.h - ;; +# We may not need have_unity +have_unity=false +# Extract the first word of "ruby", so it can be a program name with args. +set dummy ruby; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PATH_RUBY+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PATH_RUBY in + [\\/]* | ?:[\\/]*) + ac_cv_path_PATH_RUBY="$PATH_RUBY" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PATH_RUBY="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; esac +fi +PATH_RUBY=$ac_cv_path_PATH_RUBY +if test -n "$PATH_RUBY"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_RUBY" >&5 +$as_echo "$PATH_RUBY" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -ac_cv_make_tickadj=yes -case "$can_kmem$ac_cv_var_tick$default_tickadj" in - nonono) # Don't read KMEM, no presets. Bogus. - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem, no PRESET_TICK or PRESET_TICKADJ. No tickadj." >&5 -$as_echo "$as_me: WARNING: Can't read kmem, no PRESET_TICK or PRESET_TICKADJ. No tickadj." >&2;} - ac_cv_make_tickadj=no - ;; - nono*) # Don't read KMEM, no PRESET_TICK but PRESET_TICKADJ. Bogus. - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem but no PRESET_TICK. No tickadj." >&5 -$as_echo "$as_me: WARNING: Can't read kmem but no PRESET_TICK. No tickadj." >&2;} - ac_cv_make_tickadj=no - ;; - no*no) # Don't read KMEM, PRESET_TICK but no PRESET_TICKADJ. Bogus. - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't read kmem but no PRESET_TICKADJ. No tickadj." >&5 -$as_echo "$as_me: WARNING: Can't read kmem but no PRESET_TICKADJ. No tickadj." >&2;} - ac_cv_make_tickadj=no - ;; - no*) # Don't read KMEM, PRESET_TICK and PRESET_TICKADJ. Cool. - ;; - yesnono) # Read KMEM, no presets. Cool. - ;; - yesno*) # Read KMEM, no PRESET_TICK but PRESET_TICKADJ. Bogus. - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PRESET_TICKADJ is defined but not PRESET_TICK. Please report this." >&5 -$as_echo "$as_me: WARNING: PRESET_TICKADJ is defined but not PRESET_TICK. Please report this." >&2;} - ;; - yes*no) # Read KMEM, PRESET_TICK but no PRESET_TICKADJ. Cool. - ;; - yes*) # READ KMEM, PRESET_TICK and PRESET_TICKADJ. + +case "$PATH_RUBY" in + /*) + have_unity=true ;; - *) # Generally bogus. - as_fn_error "This shouldn't happen." "$LINENO" 5 + *) PATH_RUBY="false" ;; esac +# We may not need UNITYBUILD_AVAILABLE + if $have_unity; then + UNITYBUILD_AVAILABLE_TRUE= + UNITYBUILD_AVAILABLE_FALSE='#' +else + UNITYBUILD_AVAILABLE_TRUE='#' + UNITYBUILD_AVAILABLE_FALSE= +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the ntptime utility" >&5 -$as_echo_n "checking if we want and can make the ntptime utility... " >&6; } -if test "${ac_cv_make_ntptime+set}" = set; then : - $as_echo_n "(cached) " >&6 + + + +gta=false + +# Check whether --with-gtest was given. +if test "${with_gtest+set}" = set; then : + withval=$with_gtest; try_gtest=$withval else - case "$host" in - *) case "$ac_cv_struct_ntptimeval$ac_cv_var_kernel_pll" in - yesyes) - ans=yes - ;; - *) - ans=no - ;; - esac - ;; -esac -ac_cv_make_ntptime=$ans + try_gtest=yes + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_make_ntptime" >&5 -$as_echo "$ac_cv_make_ntptime" >&6; } -case "$ac_cv_make_ntptime" in + +case "$try_gtest" in yes) - MAKE_NTPTIME=ntptime - ;; + # Extract the first word of "gtest-config", so it can be a program name with args. +set dummy gtest-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GTEST_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GTEST_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_GTEST_CONFIG="$GTEST_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_GTEST_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; esac +fi +GTEST_CONFIG=$ac_cv_path_GTEST_CONFIG +if test -n "$GTEST_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTEST_CONFIG" >&5 +$as_echo "$GTEST_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -case "$host" in - mips-sni-sysv4*) - # tickadj is pretty useless on newer versions of ReliantUNIX - # Do not bother - ac_cv_make_tickadj=no - ;; - *-*-irix*) - ac_cv_make_tickadj=no - ;; - *-*-solaris2*) - # DLM says tickadj is a no-no starting with solaris2.5 - case "$host" in - *-*-solaris2.1[0-9]*) - ac_cv_make_tickadj=no - ;; - *-*-solaris2.[0-4]*) ;; - *) ac_cv_make_tickadj=no ;; - esac - ;; - *-*-unicosmp*) - ac_cv_make_tickadj=no - ;; -esac + { ac_cv_path_GTEST_CONFIG=; unset ac_cv_path_GTEST_CONFIG;} + case x${GTEST_CONFIG} in + x) ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking gtest version" >&5 +$as_echo_n "checking gtest version... " >&6; } + gtest_version_test=`$GTEST_CONFIG --min-version=1.5 || echo toolow` + case "$gtest_version_test" in + toolow*) + ;; + *) + GTEST_LDFLAGS=`$GTEST_CONFIG --ldflags` + GTEST_LIBS=`$GTEST_CONFIG --libs` + GTEST_CXXFLAGS=`$GTEST_CONFIG --cxxflags` + GTEST_CPPFLAGS=`$GTEST_CONFIG --cppflags` -# -# Despite all the above, we always make tickadj. Setting -# ac_cv_make_tickadj before AC_CACHE_CHECK will cause a false -# report that the configuration variable was cached. It may -# be better to simply remove the hunk above, I did not want -# to remove it if there is hope it will be used again. -# -unset ac_cv_make_tickadj -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the tickadj utility" >&5 -$as_echo_n "checking if we want and can make the tickadj utility... " >&6; } -if test "${ac_cv_make_tickadj+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_make_tickadj=yes -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_make_tickadj" >&5 -$as_echo "$ac_cv_make_tickadj" >&6; } -case "$ac_cv_make_tickadj" in - yes) - MAKE_TICKADJ=tickadj - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want and can make the timetrim utility" >&5 -$as_echo_n "checking if we want and can make the timetrim utility... " >&6; } -if test "${ac_cv_make_timetrim+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - case "$host" in - *-*-irix*) - ac_cv_make_timetrim=yes - ;; - *-*-unicosmp*) - ac_cv_make_timetrim=yes - ;; - *) - ac_cv_make_timetrim=no - ;; + gta=true + ;; + esac + gtest_version=`$GTEST_CONFIG --version` + case "$gta" in + true) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) ok" >&5 +$as_echo "($gtest_version) ok" >&6; } + ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) not ok" >&5 +$as_echo "($gtest_version) not ok" >&6; } + ;; + esac + { gtest_version_test=; unset gtest_version_test;} + { gtest_version=; unset gtest_version;} + esac esac + if $gta; then + GTEST_AVAILABLE_TRUE= + GTEST_AVAILABLE_FALSE='#' +else + GTEST_AVAILABLE_TRUE='#' + GTEST_AVAILABLE_FALSE= fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_make_timetrim" >&5 -$as_echo "$ac_cv_make_timetrim" >&6; } -case "$ac_cv_make_timetrim" in - yes) - MAKE_TIMETRIM=timetrim - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to build the NTPD simulator" >&5 -$as_echo_n "checking if we want to build the NTPD simulator... " >&6; } -# Check whether --enable-simulator was given. -if test "${enable_simulator+set}" = set; then : - enableval=$enable_simulator; ans=$enableval +case "$build" in + $host) cross=0 ;; + *) cross=1 ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to enable tests with undiagnosed problems" >&5 +$as_echo_n "checking if we want to enable tests with undiagnosed problems... " >&6; } +# Check whether --enable-problem-tests was given. +if test "${enable_problem_tests+set}" = set; then : + enableval=$enable_problem_tests; ntp_ept=$enableval else - ans=no + ntp_ept=yes fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ept" >&5 +$as_echo "$ntp_ept" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-ntp_restrict" >&5 +$as_echo_n "checking if we can run test-ntp_restrict... " >&6; } +ntp_test_ntp_restrict="no" +case "$ntp_ept:$cross:$host" in + no:0:*-*-solaris*) ;; + no:0:*-*-hpux-11.23*) ;; + *) ntp_test_ntp_restrict="yes" ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_test_ntp_restrict" >&5 +$as_echo "$ntp_test_ntp_restrict" >&6; } + if test x$ntp_test_ntp_restrict = xyes; then + BUILD_TEST_NTP_RESTRICT_TRUE= + BUILD_TEST_NTP_RESTRICT_FALSE='#' +else + BUILD_TEST_NTP_RESTRICT_TRUE='#' + BUILD_TEST_NTP_RESTRICT_FALSE= +fi -case "$ans" in - yes) - MAKE_NTPDSIM=ntpdsim - MAKE_LIBNTPSIM=libntpsim.a - ;; + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-ntp_scanner" >&5 +$as_echo_n "checking if we can run test-ntp_scanner... " >&6; } +ntp_test_ntp_scanner="no" +case "$ntp_ept:$cross:$host" in + no:0:*-*-solaris*) ;; + *) ntp_test_ntp_scanner="yes" ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_test_ntp_scanner" >&5 +$as_echo "$ntp_test_ntp_scanner" >&6; } + if test x$ntp_test_ntp_scanner = xyes; then + BUILD_TEST_NTP_SCANNER_TRUE= + BUILD_TEST_NTP_SCANNER_FALSE='#' +else + BUILD_TEST_NTP_SCANNER_TRUE='#' + BUILD_TEST_NTP_SCANNER_FALSE= +fi -case "$build" in - $host) - ;; - *) case "$host" in - *-*-vxworks*) - LDFLAGS="$LDFLAGS -r" - ;; - esac - ;; + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can run test-ntp_signd" >&5 +$as_echo_n "checking if we can run test-ntp_signd... " >&6; } +ntp_test_ntp_signd="no" +case "$ntp_ept:$cross:$host" in + no:0:*-*-solaris*) ;; + *) ntp_test_ntp_signd="yes" ;; esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_test_ntp_signd" >&5 +$as_echo "$ntp_test_ntp_signd" >&6; } + if test x$ntp_test_ntp_signd = xyes; then + BUILD_TEST_NTP_SIGND_TRUE= + BUILD_TEST_NTP_SIGND_FALSE='#' +else + BUILD_TEST_NTP_SIGND_TRUE='#' + BUILD_TEST_NTP_SIGND_FALSE= +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should always slew the time" >&5 -$as_echo_n "checking if we should always slew the time... " >&6; } -# target-specific defaults +### -case "$host" in - *-apple-aux[23]*) - ans=yes - ;; - *-*-bsdi[012]*) - ans=no - ;; - *-*-bsdi*) - ans=yes - ;; - *-*-openvms*) # HMS: won't be found - ans=yes - ;; - *) ans=no - ;; -esac -# --enable-slew-always / --disable-slew-always overrides default + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$sysconfdir\"" + eval ac_define_dir="\"$ac_define_dir\"" + NTP_KEYSDIR="$ac_define_dir" -# Check whether --enable-slew-always was given. -if test "${enable_slew_always+set}" = set; then : - enableval=$enable_slew_always; ans=$enableval -fi +cat >>confdefs.h <<_ACEOF +#define NTP_KEYSDIR "$ac_define_dir" +_ACEOF + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } -case "$ans" in - yes) -$as_echo "#define SLEWALWAYS 1" >>confdefs.h - ;; -esac +ac_config_files="$ac_config_files Makefile" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should step and slew the time" >&5 -$as_echo_n "checking if we should step and slew the time... " >&6; } +ac_config_files="$ac_config_files adjtimed/Makefile" -case "$host" in - *-sni-sysv*) - ans=yes - ;; - *-univel-sysv*) - ans=no - ;; - *-*-ptx*) - ans=yes - ;; - *-*-solaris2.1[0-9]*) - ans=no - ;; - *-*-solaris2.[012]*) - ans=yes - ;; - *-*-sysv4*) # HMS: Does this catch Fujitsu UXP? - ans=yes - ;; - *) ans=no - ;; -esac +ac_config_files="$ac_config_files clockstuff/Makefile" +ac_config_files="$ac_config_files include/Makefile" -# Check whether --enable-step-slew was given. -if test "${enable_step_slew+set}" = set; then : - enableval=$enable_step_slew; ans=$enableval +ac_config_files="$ac_config_files include/isc/Makefile" -fi +ac_config_files="$ac_config_files kernel/Makefile" +ac_config_files="$ac_config_files kernel/sys/Makefile" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +ac_config_files="$ac_config_files libntp/Makefile" -case "$ans" in - yes) -$as_echo "#define STEP_SLEW 1" >>confdefs.h - ;; -esac +ac_config_files="$ac_config_files libparse/Makefile" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if ntpdate should step the time" >&5 -$as_echo_n "checking if ntpdate should step the time... " >&6; } +ac_config_files="$ac_config_files ntpd/Makefile" -case "$host" in - *-apple-aux[23]*) - ans=yes - ;; - *) ans=no -esac +ac_config_files="$ac_config_files ntpd/complete.conf" -# Check whether --enable-ntpdate-step was given. -if test "${enable_ntpdate_step+set}" = set; then : - enableval=$enable_ntpdate_step; ans=$enableval +ac_config_files="$ac_config_files ntpdate/Makefile" -fi +ac_config_files="$ac_config_files ntpdc/Makefile" +ac_config_files="$ac_config_files ntpdc/nl.pl" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +ac_config_files="$ac_config_files ntpq/Makefile" -case "$ans" in - yes) -$as_echo "#define FORCE_NTPDATE_STEP 1" >>confdefs.h - ;; -esac +ac_config_files="$ac_config_files ntpsnmpd/Makefile" +ac_config_files="$ac_config_files parseutil/Makefile" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should sync TODR clock every hour" >&5 -$as_echo_n "checking if we should sync TODR clock every hour... " >&6; } +ac_config_files="$ac_config_files scripts/Makefile" -case "$host" in - *-*-nextstep*) - ans=yes - ;; - *-*-openvms*) # HMS: won't be found - ans=yes - ;; - *) - ans=no -esac +ac_config_files="$ac_config_files scripts/build/Makefile" -# Check whether --enable-hourly-todr-sync was given. -if test "${enable_hourly_todr_sync+set}" = set; then : - enableval=$enable_hourly_todr_sync; ans=$enableval +ac_config_files="$ac_config_files scripts/build/mkver" -fi +ac_config_files="$ac_config_files scripts/calc_tickadj/Makefile" +ac_config_files="$ac_config_files scripts/calc_tickadj/calc_tickadj" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +ac_config_files="$ac_config_files scripts/lib/Makefile" -case "$ac_cv_var_sync_todr" in - yes) -$as_echo "#define DOSYNCTODR 1" >>confdefs.h - ;; -esac +ac_config_files="$ac_config_files scripts/ntp-wait/Makefile" +ac_config_files="$ac_config_files scripts/ntp-wait/ntp-wait" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should avoid kernel FLL bug" >&5 -$as_echo_n "checking if we should avoid kernel FLL bug... " >&6; } +ac_config_files="$ac_config_files scripts/ntpsweep/Makefile" -case "$host" in - *-*-solaris2.6) - unamev=`uname -v` - case "$unamev" in - Generic_105181-*) - old_IFS="$IFS" - IFS="-" - set $unamev - IFS="$old_IFS" - if test "$2" -ge 17 - then - # Generic_105181-17 and higher - ans=no - else - ans=yes - fi - ;; - *) - ans=yes - esac - ;; - *-*-solaris2.7) - unamev=`uname -v` - case "$unamev" in - Generic_106541-*) - old_IFS="$IFS" - IFS="-" - set $unamev - IFS="$old_IFS" - if test "$2" -ge 07 - then - # Generic_106541-07 and higher - ans=no - else - ans=yes - fi - ;; - *) - ans=yes - esac - ;; - *) - ans=no -esac +ac_config_files="$ac_config_files scripts/ntpsweep/ntpsweep" -# Check whether --enable-kernel-fll-bug was given. -if test "${enable_kernel_fll_bug+set}" = set; then : - enableval=$enable_kernel_fll_bug; ans=$enableval +ac_config_files="$ac_config_files scripts/ntptrace/Makefile" -fi +ac_config_files="$ac_config_files scripts/ntptrace/ntptrace" +ac_config_files="$ac_config_files scripts/ntpver" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +ac_config_files="$ac_config_files scripts/plot_summary" -case "$ans" in - yes) -$as_echo "#define KERNEL_FLL_BUG 1" >>confdefs.h - ;; -esac +ac_config_files="$ac_config_files scripts/summary" + +ac_config_files="$ac_config_files scripts/update-leap/Makefile" + +ac_config_files="$ac_config_files scripts/update-leap/update-leap" + +ac_config_files="$ac_config_files tests/Makefile" + +ac_config_files="$ac_config_files tests/bug-2803/Makefile" +ac_config_files="$ac_config_files tests/libntp/Makefile" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use the IRIG sawtooth filter" >&5 -$as_echo_n "checking if we should use the IRIG sawtooth filter... " >&6; } +ac_config_files="$ac_config_files tests/ntpd/Makefile" -case "$host" in - *-*-solaris2.[89]) - ans=yes - ;; - *-*-solaris2.1[0-9]*) - ans=yes - ;; - *) ans=no -esac +ac_config_files="$ac_config_files tests/ntpq/Makefile" -# Check whether --enable-irig-sawtooth was given. -if test "${enable_irig_sawtooth+set}" = set; then : - enableval=$enable_irig_sawtooth; ans=$enableval +ac_config_files="$ac_config_files tests/sandbox/Makefile" -fi +ac_config_files="$ac_config_files tests/sec-2853/Makefile" +ac_config_files="$ac_config_files util/Makefile" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } -case "$ans" in - yes) -$as_echo "#define IRIG_SUCKS 1" >>confdefs.h - ;; -esac +perllibdir="${datadir}/ntp/lib" + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$perllibdir\"" + eval ac_define_dir="\"$ac_define_dir\"" + PERLLIBDIR="$ac_define_dir" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should enable NIST lockclock scheme" >&5 -$as_echo_n "checking if we should enable NIST lockclock scheme... " >&6; } -# Check whether --enable-nist was given. -if test "${enable_nist+set}" = set; then : - enableval=$enable_nist; ans=$enableval -else - ans=no +cat >>confdefs.h <<_ACEOF +#define PERLLIBDIR "$ac_define_dir" +_ACEOF -fi + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +calc_tickadj_opts="$srcdir/scripts/calc_tickadj/calc_tickadj-opts" -case "$ans" in - yes) -$as_echo "#define LOCKCLOCK 1" >>confdefs.h - ;; -esac +ntp_wait_opts="$srcdir/scripts/ntp-wait/ntp-wait-opts" +ntpsweep_opts="$srcdir/scripts/ntpsweep/ntpsweep-opts" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want support for Samba's signing daemon" >&5 -$as_echo_n "checking if we want support for Samba's signing daemon... " >&6; } +ntptrace_opts="$srcdir/scripts/ntptrace/ntptrace-opts" -# Check whether --enable-ntp-signd was given. -if test "${enable_ntp_signd+set}" = set; then : - enableval=$enable_ntp_signd; ans=$enableval -else - ans=no +summary_opts="$srcdir/scripts/summary-opts" -fi +plot_summary_opts="$srcdir/scripts/plot_summary-opts" -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } -case "$ans" in - no) - ntp_signd_path= - ;; - yes) - ntp_signd_path=/var/run/ntp_signd - ;; - *) - ntp_signd_path="$ans" -esac -case "$ntp_signd_path" in - '') - wintime_default=no - ;; - *) - wintime_default=yes +subdirs="$subdirs sntp" -$as_echo "#define HAVE_NTP_SIGND /**/" >>confdefs.h +cat >confcache <<\_ACEOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. +# +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. +# +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. -cat >>confdefs.h <<_ACEOF -#define NTP_SIGND_PATH "$ntp_signd_path" _ACEOF -esac +# The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +( + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + + (set) 2>&1 | + case $as_nl`(ac_space=' '; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + # `set' does not quote correctly, so add quotes: double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \. + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; #( + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) | + sed ' + /^ac_cv_env_/b end + t clear + :clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + :end' >>confcache +if diff "$cache_file" confcache >/dev/null 2>&1; then :; else + if test -w "$cache_file"; then + if test "x$cache_file" != "x/dev/null"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 +$as_echo "$as_me: updating cache $cache_file" >&6;} + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 +$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + fi +fi +rm -f confcache + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +DEFS=-DHAVE_CONFIG_H +ac_libobjs= +ac_ltlibobjs= +U= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' + ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR + # will be set to the directory where LIBOBJS objects are built. + as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" + as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want the windows symmetric client hack" >&5 -$as_echo_n "checking if we want the windows symmetric client hack... " >&6; } +LTLIBOBJS=$ac_ltlibobjs -# default is no, unless --enable-ntp-signd was given -ans=$wintime_default -unset wintime_default -# Check whether --enable-wintime was given. -if test "${enable_wintime+set}" = set; then : - enableval=$enable_wintime; ans=$enableval +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +$as_echo_n "checking that generated files are newer than configure... " >&6; } + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 +$as_echo "done" >&6; } + if test -n "$EXEEXT"; then + am__EXEEXT_TRUE= + am__EXEEXT_FALSE='#' +else + am__EXEEXT_TRUE='#' + am__EXEEXT_FALSE= fi +if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then + as_fn_error $? "conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 -$as_echo "$ans" >&6; } +if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${VPATH_HACK_TRUE}" && test -z "${VPATH_HACK_FALSE}"; then + as_fn_error $? "conditional \"VPATH_HACK\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${WANT_CALC_TICKADJ_MS_TRUE}" && test -z "${WANT_CALC_TICKADJ_MS_FALSE}"; then + as_fn_error $? "conditional \"WANT_CALC_TICKADJ_MS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${INSTALL_NTPSWEEP_TRUE}" && test -z "${INSTALL_NTPSWEEP_FALSE}"; then + as_fn_error $? "conditional \"INSTALL_NTPSWEEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${INSTALL_UPDATE_LEAP_TRUE}" && test -z "${INSTALL_UPDATE_LEAP_FALSE}"; then + as_fn_error $? "conditional \"INSTALL_UPDATE_LEAP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${GL_GENERATE_STDNORETURN_H_TRUE}" && test -z "${GL_GENERATE_STDNORETURN_H_FALSE}"; then + as_fn_error $? "conditional \"GL_GENERATE_STDNORETURN_H\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then + as_fn_error $? "conditional \"INSTALL_LIBOPTS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${NEED_LIBOPTS_TRUE}" && test -z "${NEED_LIBOPTS_FALSE}"; then + as_fn_error $? "conditional \"NEED_LIBOPTS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_LIBEVENT_TRUE}" && test -z "${BUILD_LIBEVENT_FALSE}"; then + as_fn_error $? "conditional \"BUILD_LIBEVENT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${NTP_CROSSCOMPILE_TRUE}" && test -z "${NTP_CROSSCOMPILE_FALSE}"; then + as_fn_error $? "conditional \"NTP_CROSSCOMPILE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${PTHREADS_TRUE}" && test -z "${PTHREADS_FALSE}"; then + as_fn_error $? "conditional \"PTHREADS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_SNTP_TRUE}" && test -z "${BUILD_SNTP_FALSE}"; then + as_fn_error $? "conditional \"BUILD_SNTP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${SAVECONFIG_ENABLED_TRUE}" && test -z "${SAVECONFIG_ENABLED_FALSE}"; then + as_fn_error $? "conditional \"SAVECONFIG_ENABLED\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${UNITYBUILD_AVAILABLE_TRUE}" && test -z "${UNITYBUILD_AVAILABLE_FALSE}"; then + as_fn_error $? "conditional \"UNITYBUILD_AVAILABLE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${GTEST_AVAILABLE_TRUE}" && test -z "${GTEST_AVAILABLE_FALSE}"; then + as_fn_error $? "conditional \"GTEST_AVAILABLE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_TEST_NTP_RESTRICT_TRUE}" && test -z "${BUILD_TEST_NTP_RESTRICT_FALSE}"; then + as_fn_error $? "conditional \"BUILD_TEST_NTP_RESTRICT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_TEST_NTP_SCANNER_TRUE}" && test -z "${BUILD_TEST_NTP_SCANNER_FALSE}"; then + as_fn_error $? "conditional \"BUILD_TEST_NTP_SCANNER\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_TEST_NTP_SIGND_TRUE}" && test -z "${BUILD_TEST_NTP_SIGND_FALSE}"; then + as_fn_error $? "conditional \"BUILD_TEST_NTP_SIGND\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi -case "$ans" in - yes) +: "${CONFIG_STATUS=./config.status}" +ac_write_fail=0 +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files $CONFIG_STATUS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 +$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +as_write_fail=0 +cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 +#! $SHELL +# Generated by $as_me. +# Run this file to recreate the current configuration. +# Compiler output produced by configure, useful for debugging +# configure, is in config.log if it exists. + +debug=false +ac_cs_recheck=false +ac_cs_silent=false -$as_echo "#define WINTIME /**/" >>confdefs.h +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; esac - - -for ac_header in sys/clockctl.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/clockctl.h" "ac_cv_header_sys_clockctl_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_clockctl_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_CLOCKCTL_H 1 -_ACEOF - fi -done - - -case "$host" in - *-*-netbsd*) - ans=yes - ;; - *) ans=no - ;; -esac -# Check whether --enable-clockctl was given. -if test "${enable_clockctl+set}" = set; then : - enableval=$enable_clockctl; ntp_use_dev_clockctl=$enableval +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' else - ntp_use_dev_clockctl=$ac_cv_header_sys_clockctl_h - + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' fi +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use /dev/clockctl" >&5 -$as_echo_n "checking if we should use /dev/clockctl... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_dev_clockctl" >&5 -$as_echo "$ntp_use_dev_clockctl" >&6; } +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" -for ac_header in sys/capability.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/capability.h" "ac_cv_header_sys_capability_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_capability_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_CAPABILITY_H 1 -_ACEOF +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 fi - -done - -for ac_header in sys/prctl.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "sys/prctl.h" "ac_cv_header_sys_prctl_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_prctl_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SYS_PRCTL_H 1 -_ACEOF - +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 fi +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done +PS1='$ ' +PS2='> ' +PS4='+ ' +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have linux capabilities (libcap)" >&5 -$as_echo_n "checking if we have linux capabilities (libcap)... " >&6; } +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH -case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in - yesyes) - ntp_have_linuxcaps=yes - ;; - *) - ntp_have_linuxcaps=no -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5 -$as_echo "$ntp_have_linuxcaps" >&6; } +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error -# Check whether --enable-linuxcaps was given. -if test "${enable_linuxcaps+set}" = set; then : - enableval=$enable_linuxcaps; ntp_have_linuxcaps=$enableval +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status -fi +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith -case "$ntp_have_linuxcaps" in - yes) -$as_echo "#define HAVE_LINUX_CAPABILITIES /**/" >>confdefs.h +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi - LIBS="$LIBS -lcap" -esac +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi -case "$ntp_use_dev_clockctl$ntp_have_linuxcaps" in - *yes*) +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` -$as_echo "#define HAVE_DROPROOT /**/" >>confdefs.h +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; esac - -for ac_header in libscf.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "libscf.h" "ac_cv_header_libscf_h" "$ac_includes_default" -if test "x$ac_cv_header_libscf_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBSCF_H 1 -_ACEOF - +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null -done - - -case "$ac_cv_header_libscf_h" in - yes) - LSCF=-lscf - -esac -ac_fn_c_check_func "$LINENO" "setppriv" "ac_cv_func_setppriv" -if test "x$ac_cv_func_setppriv" = x""yes; then : +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ -$as_echo "#define HAVE_SOLARIS_PRIVS /**/" >>confdefs.h + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" +} # as_fn_mkdir_p +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false fi +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +as_test_x='test -x' +as_executable_p=as_fn_executable_p -# -# ISC stuff -# +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" -$as_echo "#define ISC_PLATFORM_HAVESALEN /**/" >>confdefs.h -fi +exec 6>&1 +## ----------------------------------- ## +## Main body of $CONFIG_STATUS script. ## +## ----------------------------------- ## +_ASEOF +test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 -# Check whether --enable-ipv6 was given. -if test "${enable_ipv6+set}" = set; then : - enableval=$enable_ipv6; -fi +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Save the log message, to keep $0 and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. +ac_log=" +This file was extended by ntp $as_me 4.2.8p4, which was +generated by GNU Autoconf 2.69. Invocation command line was + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ -case "$enable_ipv6" in - yes|''|autodetect) - case "$host" in - powerpc-ibm-aix4*) ;; - *) +on `(hostname || uname -n) 2>/dev/null | sed 1q` +" -$as_echo "#define WANT_IPV6 /**/" >>confdefs.h +_ACEOF - ;; - esac - ;; - no) - ;; +case $ac_config_files in *" +"*) set x $ac_config_files; shift; ac_config_files=$*;; esac +case $ac_config_headers in *" +"*) set x $ac_config_headers; shift; ac_config_headers=$*;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 structures" >&5 -$as_echo_n "checking for IPv6 structures... " >&6; } -if test "${ac_cv_isc_found_ipv6+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# Files that config.status was made for. +config_files="$ac_config_files" +config_headers="$ac_config_headers" +config_commands="$ac_config_commands" +_ACEOF - #include - #include - #include +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +ac_cs_usage="\ +\`$as_me' instantiates files and other configuration actions +from templates according to the current configuration. Unless the files +and actions are specified as TAGs, all are instantiated by default. -int -main () -{ +Usage: $0 [OPTION]... [TAG]... - struct sockaddr_in6 sin6; + -h, --help print this help, then exit + -V, --version print version number and configuration settings, then exit + --config print configuration, then exit + -q, --quiet, --silent + do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + --header=FILE[:TEMPLATE] + instantiate the configuration header FILE +Configuration files: +$config_files - ; - return 0; -} +Configuration headers: +$config_headers -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_isc_found_ipv6=yes -else - ac_cv_isc_found_ipv6=no +Configuration commands: +$config_commands -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +Report bugs to . +ntp home page: ." +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +ac_cs_version="\\ +ntp config.status 4.2.8p4 +configured by $0, generated by GNU Autoconf 2.69, + with options \\"\$ac_cs_config\\" -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_isc_found_ipv6" >&5 -$as_echo "$ac_cv_isc_found_ipv6" >&6; } +Copyright (C) 2012 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." -# -# See whether IPv6 support is provided via a Kame add-on. -# This is done before other IPv6 linking tests so LIBS is properly set. -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kame IPv6 support" >&5 -$as_echo_n "checking for Kame IPv6 support... " >&6; } +ac_pwd='$ac_pwd' +srcdir='$srcdir' +INSTALL='$INSTALL' +MKDIR_P='$MKDIR_P' +AWK='$AWK' +test -n "\$AWK" || AWK=awk +_ACEOF -# Check whether --with-kame was given. -if test "${with_kame+set}" = set; then : - withval=$with_kame; use_kame="$withval" -else - use_kame="no" -fi +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# The default lists apply if the user does not specify any file. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=?*) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` + ac_shift=: + ;; + --*=) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg= + ac_shift=: + ;; + *) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + esac + case $ac_option in + # Handling of the options. + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) + $as_echo "$ac_cs_version"; exit ;; + --config | --confi | --conf | --con | --co | --c ) + $as_echo "$ac_cs_config"; exit ;; + --debug | --debu | --deb | --de | --d | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + '') as_fn_error $? "missing file argument" ;; + esac + as_fn_append CONFIG_FILES " '$ac_optarg'" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append CONFIG_HEADERS " '$ac_optarg'" + ac_need_defaults=false;; + --he | --h) + # Conflict between --help and --header + as_fn_error $? "ambiguous option: \`$1' +Try \`$0 --help' for more information.";; + --help | --hel | -h ) + $as_echo "$ac_cs_usage"; exit ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; -case "$use_kame" in - no) - ;; - yes) - kame_path=/usr/local/v6 - ;; - *) - kame_path="$use_kame" - ;; -esac + # This is an error. + -*) as_fn_error $? "unrecognized option: \`$1' +Try \`$0 --help' for more information." ;; -case "$use_kame" in - no) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - *) - if test -f $kame_path/lib/libinet6.a; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $kame_path/lib/libinet6.a" >&5 -$as_echo "$kame_path/lib/libinet6.a" >&6; } - LIBS="-L$kame_path/lib -linet6 $LIBS" - else - as_fn_error "$kame_path/lib/libinet6.a not found. + *) as_fn_append ac_config_targets " $1" + ac_need_defaults=false ;; -Please choose the proper path with the following command: + esac + shift +done - configure --with-kame=PATH -" "$LINENO" 5 - fi - ;; -esac +ac_configure_extra_args= -# -# Whether netinet6/in6.h is needed has to be defined in isc/platform.h. -# Including it on Kame-using platforms is very bad, though, because -# Kame uses #error against direct inclusion. So include it on only -# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1. -# This is done before the in6_pktinfo check because that's what -# netinet6/in6.h is needed for. -# -case "$host" in - *-bsdi4.[01]*) +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" +fi -$as_echo "#define ISC_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +if \$ac_cs_recheck; then + set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + shift + \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + CONFIG_SHELL='$SHELL' + export CONFIG_SHELL + exec "\$@" +fi - isc_netinet6in6_hack="#include " - ;; - *) - isc_netinet6in6_hack="" -esac +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX + $as_echo "$ac_log" +} >&5 +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # -# This is similar to the netinet6/in6.h issue. +# INIT-COMMANDS # -case "$host" in - *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" -$as_echo "#define ISC_PLATFORM_FIXIN6ISADDR 1" >>confdefs.h - isc_netinetin6_hack="#include " - ;; - *) - isc_netinetin6_hack="" -esac +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' +macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' +macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' +enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' +pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' +enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' +SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' +ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' +host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' +host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' +host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' +build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' +build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' +build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' +SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' +Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' +GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' +EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' +FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' +LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' +NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' +LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' +max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' +ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' +exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' +lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' +lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' +lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' +lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' +lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' +reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' +reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' +deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' +file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' +file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' +want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' +DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' +sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' +AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' +archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' +STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' +RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' +old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' +old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' +lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' +CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' +CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' +compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' +GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' +nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' +lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' +objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' +MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' +need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' +MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' +DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' +NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' +LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' +OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' +OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' +libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' +shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' +extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' +compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' +module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' +with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' +no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' +hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' +hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' +inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' +link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' +always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' +exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' +include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' +prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' +postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' +file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' +variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' +need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' +need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' +version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' +runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' +libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' +library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' +soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' +install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' +postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' +postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' +finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' +hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' +sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' +sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' +hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' +enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' +old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' +striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' +predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' +postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' +predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' +postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' +LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' +reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' +reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' +GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_ld_CXX='`$ECHO "$hardcode_libdir_flag_spec_ld_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' +inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' +link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' +always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' +exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' +predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' +postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' +predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' +postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' + +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} -case "$ac_cv_isc_found_ipv6" in - yes) +# Quote evaled strings. +for var in SHELL \ +ECHO \ +SED \ +GREP \ +EGREP \ +FGREP \ +LD \ +NM \ +LN_S \ +lt_SP2NL \ +lt_NL2SP \ +reload_flag \ +OBJDUMP \ +deplibs_check_method \ +file_magic_cmd \ +file_magic_glob \ +want_nocaseglob \ +DLLTOOL \ +sharedlib_from_linklib_cmd \ +AR \ +AR_FLAGS \ +archiver_list_spec \ +STRIP \ +RANLIB \ +CC \ +CFLAGS \ +compiler \ +lt_cv_sys_global_symbol_pipe \ +lt_cv_sys_global_symbol_to_cdecl \ +lt_cv_sys_global_symbol_to_c_name_address \ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ +nm_file_list_spec \ +lt_prog_compiler_no_builtin_flag \ +lt_prog_compiler_pic \ +lt_prog_compiler_wl \ +lt_prog_compiler_static \ +lt_cv_prog_compiler_c_o \ +need_locks \ +MANIFEST_TOOL \ +DSYMUTIL \ +NMEDIT \ +LIPO \ +OTOOL \ +OTOOL64 \ +shrext_cmds \ +export_dynamic_flag_spec \ +whole_archive_flag_spec \ +compiler_needs_object \ +with_gnu_ld \ +allow_undefined_flag \ +no_undefined_flag \ +hardcode_libdir_flag_spec \ +hardcode_libdir_flag_spec_ld \ +hardcode_libdir_separator \ +exclude_expsyms \ +include_expsyms \ +file_list_spec \ +variables_saved_for_relink \ +libname_spec \ +library_names_spec \ +soname_spec \ +install_override_mode \ +finish_eval \ +old_striplib \ +striplib \ +compiler_lib_search_dirs \ +predep_objects \ +postdep_objects \ +predeps \ +postdeps \ +compiler_lib_search_path \ +LD_CXX \ +reload_flag_CXX \ +compiler_CXX \ +lt_prog_compiler_no_builtin_flag_CXX \ +lt_prog_compiler_pic_CXX \ +lt_prog_compiler_wl_CXX \ +lt_prog_compiler_static_CXX \ +lt_cv_prog_compiler_c_o_CXX \ +export_dynamic_flag_spec_CXX \ +whole_archive_flag_spec_CXX \ +compiler_needs_object_CXX \ +with_gnu_ld_CXX \ +allow_undefined_flag_CXX \ +no_undefined_flag_CXX \ +hardcode_libdir_flag_spec_CXX \ +hardcode_libdir_flag_spec_ld_CXX \ +hardcode_libdir_separator_CXX \ +exclude_expsyms_CXX \ +include_expsyms_CXX \ +file_list_spec_CXX \ +compiler_lib_search_dirs_CXX \ +predep_objects_CXX \ +postdep_objects_CXX \ +predeps_CXX \ +postdeps_CXX \ +compiler_lib_search_path_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done -$as_echo "#define ISC_PLATFORM_HAVEIPV6 /**/" >>confdefs.h +# Double-quote double-evaled strings. +for var in reload_cmds \ +old_postinstall_cmds \ +old_postuninstall_cmds \ +old_archive_cmds \ +extract_expsyms_cmds \ +old_archive_from_new_cmds \ +old_archive_from_expsyms_cmds \ +archive_cmds \ +archive_expsym_cmds \ +module_cmds \ +module_expsym_cmds \ +export_symbols_cmds \ +prelink_cmds \ +postlink_cmds \ +postinstall_cmds \ +postuninstall_cmds \ +finish_cmds \ +sys_lib_search_path_spec \ +sys_lib_dlsearch_path_spec \ +reload_cmds_CXX \ +old_archive_cmds_CXX \ +old_archive_from_new_cmds_CXX \ +old_archive_from_expsyms_cmds_CXX \ +archive_cmds_CXX \ +archive_expsym_cmds_CXX \ +module_cmds_CXX \ +module_expsym_cmds_CXX \ +export_symbols_cmds_CXX \ +prelink_cmds_CXX \ +postlink_cmds_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done +ac_aux_dir='$ac_aux_dir' +xsi_shell='$xsi_shell' +lt_shell_append='$lt_shell_append' - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6_pktinfo" >&5 -$as_echo_n "checking for in6_pktinfo... " >&6; } -if test "${ac_cv_have_in6_pktinfo+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# See if we are running on zsh, and set the options which allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + PACKAGE='$PACKAGE' + VERSION='$VERSION' + TIMESTAMP='$TIMESTAMP' + RM='$RM' + ofile='$ofile' - #include - #include - #include - $isc_netinetin6_hack - $isc_netinet6in6_hack -int -main () -{ - struct in6_pktinfo xyzzy; - ; - return 0; -} _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_in6_pktinfo=yes -else - ac_cv_have_in6_pktinfo=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + +# Handling of arguments. +for ac_config_target in $ac_config_targets +do + case $ac_config_target in + "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; + "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; + "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "adjtimed/Makefile") CONFIG_FILES="$CONFIG_FILES adjtimed/Makefile" ;; + "clockstuff/Makefile") CONFIG_FILES="$CONFIG_FILES clockstuff/Makefile" ;; + "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; + "include/isc/Makefile") CONFIG_FILES="$CONFIG_FILES include/isc/Makefile" ;; + "kernel/Makefile") CONFIG_FILES="$CONFIG_FILES kernel/Makefile" ;; + "kernel/sys/Makefile") CONFIG_FILES="$CONFIG_FILES kernel/sys/Makefile" ;; + "libntp/Makefile") CONFIG_FILES="$CONFIG_FILES libntp/Makefile" ;; + "libparse/Makefile") CONFIG_FILES="$CONFIG_FILES libparse/Makefile" ;; + "ntpd/Makefile") CONFIG_FILES="$CONFIG_FILES ntpd/Makefile" ;; + "ntpd/complete.conf") CONFIG_FILES="$CONFIG_FILES ntpd/complete.conf" ;; + "ntpdate/Makefile") CONFIG_FILES="$CONFIG_FILES ntpdate/Makefile" ;; + "ntpdc/Makefile") CONFIG_FILES="$CONFIG_FILES ntpdc/Makefile" ;; + "ntpdc/nl.pl") CONFIG_FILES="$CONFIG_FILES ntpdc/nl.pl" ;; + "ntpq/Makefile") CONFIG_FILES="$CONFIG_FILES ntpq/Makefile" ;; + "ntpsnmpd/Makefile") CONFIG_FILES="$CONFIG_FILES ntpsnmpd/Makefile" ;; + "parseutil/Makefile") CONFIG_FILES="$CONFIG_FILES parseutil/Makefile" ;; + "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;; + "scripts/build/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/build/Makefile" ;; + "scripts/build/mkver") CONFIG_FILES="$CONFIG_FILES scripts/build/mkver" ;; + "scripts/calc_tickadj/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/calc_tickadj/Makefile" ;; + "scripts/calc_tickadj/calc_tickadj") CONFIG_FILES="$CONFIG_FILES scripts/calc_tickadj/calc_tickadj" ;; + "scripts/lib/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/lib/Makefile" ;; + "scripts/ntp-wait/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/ntp-wait/Makefile" ;; + "scripts/ntp-wait/ntp-wait") CONFIG_FILES="$CONFIG_FILES scripts/ntp-wait/ntp-wait" ;; + "scripts/ntpsweep/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/ntpsweep/Makefile" ;; + "scripts/ntpsweep/ntpsweep") CONFIG_FILES="$CONFIG_FILES scripts/ntpsweep/ntpsweep" ;; + "scripts/ntptrace/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/ntptrace/Makefile" ;; + "scripts/ntptrace/ntptrace") CONFIG_FILES="$CONFIG_FILES scripts/ntptrace/ntptrace" ;; + "scripts/ntpver") CONFIG_FILES="$CONFIG_FILES scripts/ntpver" ;; + "scripts/plot_summary") CONFIG_FILES="$CONFIG_FILES scripts/plot_summary" ;; + "scripts/summary") CONFIG_FILES="$CONFIG_FILES scripts/summary" ;; + "scripts/update-leap/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/update-leap/Makefile" ;; + "scripts/update-leap/update-leap") CONFIG_FILES="$CONFIG_FILES scripts/update-leap/update-leap" ;; + "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;; + "tests/bug-2803/Makefile") CONFIG_FILES="$CONFIG_FILES tests/bug-2803/Makefile" ;; + "tests/libntp/Makefile") CONFIG_FILES="$CONFIG_FILES tests/libntp/Makefile" ;; + "tests/ntpd/Makefile") CONFIG_FILES="$CONFIG_FILES tests/ntpd/Makefile" ;; + "tests/ntpq/Makefile") CONFIG_FILES="$CONFIG_FILES tests/ntpq/Makefile" ;; + "tests/sandbox/Makefile") CONFIG_FILES="$CONFIG_FILES tests/sandbox/Makefile" ;; + "tests/sec-2853/Makefile") CONFIG_FILES="$CONFIG_FILES tests/sec-2853/Makefile" ;; + "util/Makefile") CONFIG_FILES="$CONFIG_FILES util/Makefile" ;; + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + esac +done -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_in6_pktinfo" >&5 -$as_echo "$ac_cv_have_in6_pktinfo" >&6; } - case "$ac_cv_have_in6_pktinfo" in - yes) +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files + test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers + test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands +fi -$as_echo "#define ISC_PLATFORM_HAVEIN6PKTINFO /**/" >>confdefs.h +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason against having it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Hook for its removal unless debugging. +# Note that there is a small window in which the directory will not be cleaned: +# after its creation but before its name has been assigned to `$tmp'. +$debug || +{ + tmp= ac_tmp= + trap 'exit_status=$? + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status +' 0 + trap 'as_fn_exit 1' 1 2 13 15 +} +# Create a (secure) tmp directory for tmp files. - esac +{ + tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && + test -d "$tmp" +} || +{ + tmp=./conf$$-$RANDOM + (umask 077 && mkdir "$tmp") +} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp +# Set up the scripts for CONFIG_FILES section. +# No need to generate them if there are no CONFIG_FILES. +# This happens for instance with `./config.status config.h'. +if test -n "$CONFIG_FILES"; then - # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead? - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_in6.sin6_scope_id" >&5 -$as_echo_n "checking for sockaddr_in6.sin6_scope_id... " >&6; } -if test "${ac_cv_have_sin6_scope_id+set}" = set; then : - $as_echo_n "(cached) " >&6 +if $AWK 'BEGIN { getline <"/dev/null" }' /dev/null; then + ac_cs_awk_getline=: + ac_cs_awk_pipe_init= + ac_cs_awk_read_file=' + while ((getline aline < (F[key])) > 0) + print(aline) + close(F[key])' + ac_cs_awk_pipe_fini= +else + ac_cs_awk_getline=false + ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\"" + ac_cs_awk_read_file=' + print "|#_!!_#|" + print "cat " F[key] " &&" + '$ac_cs_awk_pipe_init + # The final `:' finishes the AND list. + ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }' +fi +ac_cr=`echo X | tr X '\015'` +# On cygwin, bash can eat \r inside `` if the user requested igncr. +# But we know of no other shell where ac_cr would be empty at this +# point, so we can use a bashism as a fallback. +if test "x$ac_cr" = x; then + eval ac_cr=\$\'\\r\' +fi +ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` +if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then + ac_cs_awk_cr='\\r' else + ac_cs_awk_cr=$ac_cr +fi - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && +_ACEOF +# Create commands to substitute file output variables. +{ + echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" && + echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' && + echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' && + echo "_ACAWK" && + echo "_ACEOF" +} >conf$$files.sh && +. ./conf$$files.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +rm -f conf$$files.sh - #include - #include - #include - $isc_netinetin6_hack - $isc_netinet6in6_hack +{ + echo "cat >conf$$subs.awk <<_ACEOF" && + echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && + echo "_ACEOF" +} >conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` +ac_delim='%!_!# ' +for ac_last_try in false false false false false :; do + . ./conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 -int -main () + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + if test $ac_delim_n = $ac_delim_num; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done +rm -f conf$$subs.sh + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && +_ACEOF +sed -n ' +h +s/^/S["/; s/!.*/"]=/ +p +g +s/^[^!]*!// +:repl +t repl +s/'"$ac_delim"'$// +t delim +:nl +h +s/\(.\{148\}\)..*/\1/ +t more1 +s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ +p +n +b repl +:more1 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t nl +:delim +h +s/\(.\{148\}\)..*/\1/ +t more2 +s/["\\]/\\&/g; s/^/"/; s/$/"/ +p +b +:more2 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t delim +' >$CONFIG_STATUS || ac_write_fail=1 +rm -f conf$$subs.awk +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +_ACAWK +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && + for (key in S) S_is_set[key] = 1 + FS = "" + \$ac_cs_awk_pipe_init +} { - - struct sockaddr_in6 xyzzy; - xyzzy.sin6_scope_id = 0; - - - ; - return 0; + line = $ 0 + nfields = split(line, field, "@") + substed = 0 + len = length(field[1]) + for (i = 2; i < nfields; i++) { + key = field[i] + keylen = length(key) + if (S_is_set[key]) { + value = S[key] + line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) + len += length(value) + length(field[++i]) + substed = 1 + } else + len += 1 + keylen + } + if (nfields == 3 && !substed) { + key = field[2] + if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) { + \$ac_cs_awk_read_file + next + } + } + print line } - +\$ac_cs_awk_pipe_fini +_ACAWK _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_sin6_scope_id=yes +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then + sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else - ac_cv_have_sin6_scope_id=no - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - + cat +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ + || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 +_ACEOF +# VPATH may cause trouble with some makes, so we remove sole $(srcdir), +# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ +h +s/// +s/^/:/ +s/[ ]*$/:/ +s/:\$(srcdir):/:/g +s/:\${srcdir}:/:/g +s/:@srcdir@:/:/g +s/^:*// +s/:*$// +x +s/\(=[ ]*\).*/\1/ +G +s/\n// +s/^[^=]*=[ ]*$// +}' fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sin6_scope_id" >&5 -$as_echo "$ac_cv_have_sin6_scope_id" >&6; } - case "$ac_cv_have_sin6_scope_id" in - yes) - -$as_echo "#define ISC_PLATFORM_HAVESCOPEID /**/" >>confdefs.h - - esac -esac - - -# We need this check run even without ac_cv_isc_found_ipv6=yes - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5 -$as_echo_n "checking for in6addr_any... " >&6; } -if test "${ac_cv_have_in6addr_any+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +fi # test -n "$CONFIG_FILES" +# Set up the scripts for CONFIG_HEADERS section. +# No need to generate them if there are no CONFIG_HEADERS. +# This happens for instance with `./config.status Makefile'. +if test -n "$CONFIG_HEADERS"; then +cat >"$ac_tmp/defines.awk" <<\_ACAWK || +BEGIN { +_ACEOF - #include - #include - #include - $isc_netinetin6_hack - $isc_netinet6in6_hack +# Transform confdefs.h into an awk script `defines.awk', embedded as +# here-document in config.status, that substitutes the proper values into +# config.h.in to produce config.h. -int -main () -{ +# Create a delimiter string that does not exist in confdefs.h, to ease +# handling of long lines. +ac_delim='%!_!# ' +for ac_last_try in false false :; do + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done - struct in6_addr in6; - in6 = in6addr_any; +# For the awk script, D is an array of macro values keyed by name, +# likewise P contains macro parameters if any. Preserve backslash +# newline sequences. +ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* +sed -n ' +s/.\{148\}/&'"$ac_delim"'/g +t rset +:rset +s/^[ ]*#[ ]*define[ ][ ]*/ / +t def +d +:def +s/\\$// +t bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3"/p +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p +d +:bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3\\\\\\n"\\/p +t cont +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p +t cont +d +:cont +n +s/.\{148\}/&'"$ac_delim"'/g +t clear +:clear +s/\\$// +t bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/"/p +d +:bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p +b cont +' >$CONFIG_STATUS || ac_write_fail=1 - ; - return 0; +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + for (key in D) D_is_set[key] = 1 + FS = "" } - +/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { + line = \$ 0 + split(line, arg, " ") + if (arg[1] == "#") { + defundef = arg[2] + mac1 = arg[3] + } else { + defundef = substr(arg[1], 2) + mac1 = arg[2] + } + split(mac1, mac2, "(") #) + macro = mac2[1] + prefix = substr(line, 1, index(line, defundef) - 1) + if (D_is_set[macro]) { + # Preserve the white space surrounding the "#". + print prefix "define", macro P[macro] D[macro] + next + } else { + # Replace #undef with comments. This is necessary, for example, + # in the case of _POSIX_SOURCE, which is predefined and required + # on some systems where configure will not decide to define it. + if (defundef == "undef") { + print "/*", prefix defundef, macro, "*/" + next + } + } +} +{ print } +_ACAWK _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_in6addr_any=yes -else - ac_cv_have_in6addr_any=no - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_in6addr_any" >&5 -$as_echo "$ac_cv_have_in6addr_any" >&6; } +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 +fi # test -n "$CONFIG_HEADERS" -case "$ac_cv_have_in6addr_any" in - no) -$as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY /**/" >>confdefs.h +eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" +shift +for ac_tag +do + case $ac_tag in + :[FHLC]) ac_mode=$ac_tag; continue;; + esac + case $ac_mode$ac_tag in + :[FHL]*:*);; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; + :[FH]-) ac_tag=-:-;; + :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; + esac + ac_save_IFS=$IFS + IFS=: + set x $ac_tag + IFS=$ac_save_IFS + shift + ac_file=$1 + shift -esac + case $ac_mode in + :L) ac_source=$1;; + :[FH]) + ac_file_inputs= + for ac_f + do + case $ac_f in + -) ac_f="$ac_tmp/stdin";; + *) # Look for the file first in the build tree, then in the source tree + # (if the path is not absolute). The absolute path cannot be DOS-style, + # because $ac_f cannot contain `:'. + test -f "$ac_f" || + case $ac_f in + [\\/$]*) false;; + *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; + esac || + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; + esac + case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + as_fn_append ac_file_inputs " '$ac_f'" + done + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + configure_input='Generated from '` + $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + `' by configure.' + if test x"$ac_file" != x-; then + configure_input="$ac_file. $configure_input" + { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 +$as_echo "$as_me: creating $ac_file" >&6;} + fi + # Neutralize special characters interpreted by sed in replacement strings. + case $configure_input in #( + *\&* | *\|* | *\\* ) + ac_sed_conf_input=`$as_echo "$configure_input" | + sed 's/[\\\\&|]/\\\\&/g'`;; #( + *) ac_sed_conf_input=$configure_input;; + esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrconf" >&5 -$as_echo_n "checking for struct if_laddrconf... " >&6; } -if test "${ac_cv_isc_struct_if_laddrconf+set}" = set; then : - $as_echo_n "(cached) " >&6 -else + case $ac_tag in + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; + esac + ;; + esac - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + ac_dir=`$as_dirname -- "$ac_file" || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix - #include - #include +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix -int -main () -{ - struct if_laddrconf a; + case $ac_mode in + :F) + # + # CONFIG_FILE + # + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; + esac + ac_MKDIR_P=$MKDIR_P + case $MKDIR_P in + [\\/$]* | ?:[\\/]* ) ;; + */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; + esac +_ACEOF - ; - return 0; +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# If the template does not know about datarootdir, expand it. +# FIXME: This hack should be removed a few years after 2.60. +ac_datarootdir_hack=; ac_datarootdir_seen= +ac_sed_dataroot=' +/datarootdir/ { + p + q } - +/@datadir@/p +/@docdir@/p +/@infodir@/p +/@localedir@/p +/@mandir@/p' +case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in +*datarootdir*) ac_datarootdir_seen=yes;; +*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_isc_struct_if_laddrconf=yes -else - ac_cv_isc_struct_if_laddrconf=no - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_isc_struct_if_laddrconf" >&5 -$as_echo "$ac_cv_isc_struct_if_laddrconf" >&6; } - -case "$ac_cv_isc_struct_if_laddrconf" in - yes) - -$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRCONF /**/" >>confdefs.h - +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + ac_datarootdir_hack=' + s&@datadir@&$datadir&g + s&@docdir@&$docdir&g + s&@infodir@&$infodir&g + s&@localedir@&$localedir&g + s&@mandir@&$mandir&g + s&\\\${datarootdir}&$datarootdir&g' ;; esac +_ACEOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrreq" >&5 -$as_echo_n "checking for struct if_laddrreq... " >&6; } -if test "${ac_cv_isc_struct_if_laddrreq+set}" = set; then : - $as_echo_n "(cached) " >&6 +# Neutralize VPATH when `$srcdir' = `.'. +# Shell code in configure.ac might set extrasub. +# FIXME: do we really want to maintain this feature? +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_sed_extra="$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s|@configure_input@|$ac_sed_conf_input|;t t +s&@top_builddir@&$ac_top_builddir_sub&;t t +s&@top_build_prefix@&$ac_top_build_prefix&;t t +s&@srcdir@&$ac_srcdir&;t t +s&@abs_srcdir@&$ac_abs_srcdir&;t t +s&@top_srcdir@&$ac_top_srcdir&;t t +s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t +s&@builddir@&$ac_builddir&;t t +s&@abs_builddir@&$ac_abs_builddir&;t t +s&@abs_top_builddir@&$ac_abs_top_builddir&;t t +s&@INSTALL@&$ac_INSTALL&;t t +s&@MKDIR_P@&$ac_MKDIR_P&;t t +$ac_datarootdir_hack +" +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | +if $ac_cs_awk_getline; then + $AWK -f "$ac_tmp/subs.awk" else + $AWK -f "$ac_tmp/subs.awk" | $SHELL +fi \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - - - #include - #include +test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&5 +$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&2;} -int -main () -{ + rm -f "$ac_tmp/stdin" + case $ac_file in + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; + esac \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + ;; + :H) + # + # CONFIG_HEADER + # + if test x"$ac_file" != x-; then + { + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 +$as_echo "$as_me: $ac_file is unchanged" >&6;} + else + rm -f "$ac_file" + mv "$ac_tmp/config.h" "$ac_file" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + fi + else + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ + || as_fn_error $? "could not create -" "$LINENO" 5 + fi +# Compute "$ac_file"'s index in $config_headers. +_am_arg="$ac_file" +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || +$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$_am_arg" : 'X\(//\)[^/]' \| \ + X"$_am_arg" : 'X\(//\)$' \| \ + X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$_am_arg" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'`/stamp-h$_am_stamp_count + ;; - struct if_laddrreq a; + :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 +$as_echo "$as_me: executing $ac_file commands" >&6;} + ;; + esac - ; - return 0; + case $ac_file$ac_mode in + "depfiles":C) test x"$AMDEP_TRUE" != x"" || { + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir=$dirpart/$fdir; as_fn_mkdir_p + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done } + ;; + "libtool":C) -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_isc_struct_if_laddrreq=yes -else - ac_cv_isc_struct_if_laddrreq=no - -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_isc_struct_if_laddrreq" >&5 -$as_echo "$ac_cv_isc_struct_if_laddrreq" >&6; } - -case "$ac_cv_isc_struct_if_laddrreq" in - yes) + # See if we are running on zsh, and set the options which allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi -$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRREQ /**/" >>confdefs.h + cfgfile="${ofile}T" + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" -esac + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL +# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. # -# Look for a sysctl call to get the list of network interfaces. +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. +# Written by Gordon Matzigkeit, 1996 # -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for interface list sysctl" >&5 -$as_echo_n "checking for interface list sysctl... " >&6; } -if test "${ac_cv_iflist_sysctl+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - - #include - #include - #include - #ifdef NET_RT_IFLIST - found_rt_iflist - #endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "found_rt_iflist" >/dev/null 2>&1; then : - ac_cv_iflist_sysctl=yes -else - ac_cv_iflist_sysctl=no - -fi -rm -f conftest* - - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_iflist_sysctl" >&5 -$as_echo "$ac_cv_iflist_sysctl" >&6; } - -case "$ac_cv_iflist_sysctl" in - yes) - -$as_echo "#define HAVE_IFLIST_SYSCTL 1" >>confdefs.h - -esac - - -### - - - ac_expanded=`( - test "x$prefix" = xNONE && prefix="$ac_default_prefix" - test "x$exec_prefix" = xNONE && exec_prefix="${prefix}" - eval echo \""$sysconfdir"\" - )` - -cat >>confdefs.h <<_ACEOF -#define NTP_KEYSDIR "$ac_expanded" -_ACEOF - - - -ac_config_files="$ac_config_files Makefile" - -ac_config_files="$ac_config_files ElectricFence/Makefile" - -ac_config_files="$ac_config_files adjtimed/Makefile" +# This file is part of GNU Libtool. +# +# GNU Libtool is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or +# obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -ac_config_files="$ac_config_files clockstuff/Makefile" -ac_config_files="$ac_config_files include/Makefile" +# The names of the tagged configurations supported by this script. +available_tags="CXX " -ac_config_files="$ac_config_files include/isc/Makefile" +# ### BEGIN LIBTOOL CONFIG -ac_config_files="$ac_config_files kernel/Makefile" +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared -ac_config_files="$ac_config_files kernel/sys/Makefile" +# Which release of libtool.m4 was used? +macro_version=$macro_version +macro_revision=$macro_revision -ac_config_files="$ac_config_files libntp/Makefile" +# Whether or not to build static libraries. +build_old_libs=$enable_static -ac_config_files="$ac_config_files libparse/Makefile" +# What type of objects to build. +pic_mode=$pic_mode -ac_config_files="$ac_config_files ntpd/Makefile" +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install -ac_config_files="$ac_config_files ntpdate/Makefile" +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL -ac_config_files="$ac_config_files ntpdc/Makefile" +# An echo program that protects backslashes. +ECHO=$lt_ECHO -ac_config_files="$ac_config_files ntpdc/nl.pl" +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os -ac_config_files="$ac_config_files ntpq/Makefile" +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os -ac_config_files="$ac_config_files parseutil/Makefile" +# A sed program that does not truncate output. +SED=$lt_SED -ac_config_files="$ac_config_files scripts/Makefile" +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="\$SED -e 1s/^X//" -ac_config_files="$ac_config_files scripts/calc_tickadj" +# A grep program that handles long lines. +GREP=$lt_GREP -ac_config_files="$ac_config_files scripts/checktime" +# An ERE matcher. +EGREP=$lt_EGREP -ac_config_files="$ac_config_files scripts/freq_adj" +# A literal string matcher. +FGREP=$lt_FGREP -ac_config_files="$ac_config_files scripts/html2man" +# A BSD- or MS-compatible name lister. +NM=$lt_NM -ac_config_files="$ac_config_files scripts/mkver" +# Whether we need soft or hard links. +LN_S=$lt_LN_S -ac_config_files="$ac_config_files scripts/ntp-wait" +# What is the maximum length of a command? +max_cmd_len=$max_cmd_len -ac_config_files="$ac_config_files scripts/ntpsweep" +# Object file suffix (normally "o"). +objext=$ac_objext -ac_config_files="$ac_config_files scripts/ntptrace" +# Executable file suffix (normally ""). +exeext=$exeext -ac_config_files="$ac_config_files scripts/ntpver" +# whether the shell understands "unset". +lt_unset=$lt_unset -ac_config_files="$ac_config_files scripts/plot_summary" +# turn spaces into newlines. +SP2NL=$lt_lt_SP2NL -ac_config_files="$ac_config_files scripts/summary" +# turn newlines into spaces. +NL2SP=$lt_lt_NL2SP -ac_config_files="$ac_config_files util/Makefile" +# convert \$build file names to \$host format. +to_host_file_cmd=$lt_cv_to_host_file_cmd +# convert \$build files to toolchain format. +to_tool_file_cmd=$lt_cv_to_tool_file_cmd -subdirs="$subdirs sntp" +# An object symbol dumper. +OBJDUMP=$lt_OBJDUMP +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. +# Command to use when deplibs_check_method = "file_magic". +file_magic_cmd=$lt_file_magic_cmd -_ACEOF +# How to find potential files when deplibs_check_method = "file_magic". +file_magic_glob=$lt_file_magic_glob -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done +# Find potential files using nocaseglob when deplibs_check_method = "file_magic". +want_nocaseglob=$lt_want_nocaseglob - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - test "x$cache_file" != "x/dev/null" && - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache +# DLL creation program. +DLLTOOL=$lt_DLLTOOL -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' +# Command to associate shared and link libraries. +sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd -DEFS=-DHAVE_CONFIG_H +# The archiver. +AR=$lt_AR -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs +# Flags to create an archive. +AR_FLAGS=$lt_AR_FLAGS -LTLIBOBJS=$ac_ltlibobjs +# How to feed a file listing to the archiver. +archiver_list_spec=$lt_archiver_list_spec +# A symbol stripping program. +STRIP=$lt_STRIP - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi +# Commands used to install an old-style archive. +RANLIB=$lt_RANLIB +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - as_fn_error "conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then - as_fn_error "conditional \"INSTALL_LIBOPTS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${NEED_LIBOPTS_TRUE}" && test -z "${NEED_LIBOPTS_FALSE}"; then - as_fn_error "conditional \"NEED_LIBOPTS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi +# Whether to use a lock for old archive extraction. +lock_old_archive_extraction=$lock_old_archive_extraction +# A C compiler. +LTCC=$lt_CC -: ${CONFIG_STATUS=./config.status} -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. +# LTCC compiler flags. +LTCFLAGS=$lt_CFLAGS -debug=false -ac_cs_recheck=false -ac_cs_silent=false +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## +# Transform the output of nm in a proper C declaration. +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi +# Transform the output of nm in a C name address pair. +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address +# Transform the output of nm in a C name address pair when lib prefix is needed. +global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi +# Specify filename containing input files for \$NM. +nm_file_list_spec=$lt_nm_file_list_spec -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi +# The root where to search for dependent libraries,and in which our libraries should be installed. +lt_sysroot=$lt_sysroot +# The name of the directory that contains temporary libtool files. +objdir=$objdir -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" +# Used to examine libraries when file_magic_cmd begins with "file". +MAGIC_CMD=$MAGIC_CMD -# Find who we are. Look in the path if we contain no directory separator. -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS +# Must we lock files when doing compilation? +need_locks=$lt_need_locks - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi +# Manifest tool. +MANIFEST_TOOL=$lt_MANIFEST_TOOL -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' +# Tool to manipulate archived DWARF debug symbol files on Mac OS X. +DSYMUTIL=$lt_DSYMUTIL -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE +# Tool to change global to local symbols on Mac OS X. +NMEDIT=$lt_NMEDIT -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# Tool to manipulate fat objects and archives on Mac OS X. +LIPO=$lt_LIPO +# ldd/readelf like tool for Mach-O binaries on Mac OS X. +OTOOL=$lt_OTOOL -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. -as_fn_error () -{ - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 - fi - $as_echo "$as_me: error: $1" >&2 - as_fn_exit $as_status -} # as_fn_error +# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. +OTOOL64=$lt_OTOOL64 +# Old archive suffix (normally "a"). +libext=$libext -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status +# Shared library suffix (normally ".so"). +shrext_cmds=$lt_shrext_cmds -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append +# Variables whose values should be saved in libtool wrapper scripts and +# restored at link time. +variables_saved_for_relink=$lt_variables_saved_for_relink -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith +# Do we need the "lib" prefix for modules? +need_lib_prefix=$need_lib_prefix +# Do we need a version for libraries? +need_version=$need_version -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi +# Library versioning type. +version_type=$version_type -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi +# Shared library runtime path variable. +runpath_var=$runpath_var -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi +# Shared library path variable. +shlibpath_var=$shlibpath_var + +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath + +# Format of library name prefix. +libname_spec=$lt_libname_spec + +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME +library_names_spec=$lt_library_names_spec -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits +# Permission mode override for installation of shared libraries. +install_override_mode=$lt_install_override_mode -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac +# Command to use after installation of a shared archive. +postinstall_cmds=$lt_postinstall_cmds -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -p' - fi -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null +# Command to use after uninstallation of a shared archive. +postuninstall_cmds=$lt_postuninstall_cmds +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ +# As "finish_cmds", except a single script fragment to be evaled but +# not shown. +finish_eval=$lt_finish_eval - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs +# Compile-time system search path for libraries. +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi +# Run-time system search path for libraries. +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x +# Whether dlopen is supported. +dlopen_support=$enable_dlopen -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by ntp $as_me 4.2.4p8, which was -generated by GNU Autoconf 2.65. Invocation command line was +# The linker used to build libraries. +LD=$lt_LD - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds -_ACEOF +# A language specific compiler. +CC=$lt_compiler -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac +# Is the compiler the GNU compiler? +with_gcc=$GCC -case $ac_config_headers in *" -"*) set x $ac_config_headers; shift; ac_config_headers=$*;; -esac +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_headers="$ac_config_headers" -config_commands="$ac_config_commands" +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl -_ACEOF +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o -Usage: $0 [OPTION]... [TAG]... +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - --header=FILE[:TEMPLATE] - instantiate the configuration header FILE +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes -Configuration files: -$config_files +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec -Configuration headers: -$config_headers +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec -Configuration commands: -$config_commands +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object -Report bugs to the package provider." +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" -ac_cs_version="\\ -ntp config.status 4.2.4p8 -configured by $0, generated by GNU Autoconf 2.65, - with options \\"\$ac_cs_config\\" +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds -Copyright (C) 2009 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --header | --heade | --head | --hea ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_HEADERS " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h) - # Conflict between --help and --header - as_fn_error "ambiguous option: \`$1' -Try \`$0 --help' for more information.";; - --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag - # This is an error. - -*) as_fn_error "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; +# If ld is used when linking, flag to hardcode \$libdir into a binary +# during linking. This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld - esac - shift -done +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator -ac_configure_extra_args= +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \${shlibpath_var} if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic -_ACEOF +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "libopts/Makefile") CONFIG_FILES="$CONFIG_FILES libopts/Makefile" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - "ElectricFence/Makefile") CONFIG_FILES="$CONFIG_FILES ElectricFence/Makefile" ;; - "adjtimed/Makefile") CONFIG_FILES="$CONFIG_FILES adjtimed/Makefile" ;; - "clockstuff/Makefile") CONFIG_FILES="$CONFIG_FILES clockstuff/Makefile" ;; - "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; - "include/isc/Makefile") CONFIG_FILES="$CONFIG_FILES include/isc/Makefile" ;; - "kernel/Makefile") CONFIG_FILES="$CONFIG_FILES kernel/Makefile" ;; - "kernel/sys/Makefile") CONFIG_FILES="$CONFIG_FILES kernel/sys/Makefile" ;; - "libntp/Makefile") CONFIG_FILES="$CONFIG_FILES libntp/Makefile" ;; - "libparse/Makefile") CONFIG_FILES="$CONFIG_FILES libparse/Makefile" ;; - "ntpd/Makefile") CONFIG_FILES="$CONFIG_FILES ntpd/Makefile" ;; - "ntpdate/Makefile") CONFIG_FILES="$CONFIG_FILES ntpdate/Makefile" ;; - "ntpdc/Makefile") CONFIG_FILES="$CONFIG_FILES ntpdc/Makefile" ;; - "ntpdc/nl.pl") CONFIG_FILES="$CONFIG_FILES ntpdc/nl.pl" ;; - "ntpq/Makefile") CONFIG_FILES="$CONFIG_FILES ntpq/Makefile" ;; - "parseutil/Makefile") CONFIG_FILES="$CONFIG_FILES parseutil/Makefile" ;; - "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;; - "scripts/calc_tickadj") CONFIG_FILES="$CONFIG_FILES scripts/calc_tickadj" ;; - "scripts/checktime") CONFIG_FILES="$CONFIG_FILES scripts/checktime" ;; - "scripts/freq_adj") CONFIG_FILES="$CONFIG_FILES scripts/freq_adj" ;; - "scripts/html2man") CONFIG_FILES="$CONFIG_FILES scripts/html2man" ;; - "scripts/mkver") CONFIG_FILES="$CONFIG_FILES scripts/mkver" ;; - "scripts/ntp-wait") CONFIG_FILES="$CONFIG_FILES scripts/ntp-wait" ;; - "scripts/ntpsweep") CONFIG_FILES="$CONFIG_FILES scripts/ntpsweep" ;; - "scripts/ntptrace") CONFIG_FILES="$CONFIG_FILES scripts/ntptrace" ;; - "scripts/ntpver") CONFIG_FILES="$CONFIG_FILES scripts/ntpver" ;; - "scripts/plot_summary") CONFIG_FILES="$CONFIG_FILES scripts/plot_summary" ;; - "scripts/summary") CONFIG_FILES="$CONFIG_FILES scripts/summary" ;; - "util/Makefile") CONFIG_FILES="$CONFIG_FILES util/Makefile" ;; +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols - *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands -fi +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= - trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -n "$tmp" && test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\r' -else - ac_cs_awk_cr=$ac_cr -fi +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs -echo 'BEGIN {' >"$tmp/subs1.awk" && -_ACEOF +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects +postdep_objects=$lt_postdep_objects +predeps=$lt_predeps +postdeps=$lt_postdeps +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 +# ### END LIBTOOL CONFIG - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + +ltmain="$ac_aux_dir/ltmain.sh" -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + if test x"$xsi_shell" = xyes; then + sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ +func_dirname ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_basename ()$/,/^} # func_basename /c\ +func_basename ()\ +{\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ +func_dirname_and_basename ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ +func_stripname ()\ +{\ +\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ +\ # positional parameters, so assign one to ordinary parameter first.\ +\ func_stripname_result=${3}\ +\ func_stripname_result=${func_stripname_result#"${1}"}\ +\ func_stripname_result=${func_stripname_result%"${2}"}\ +} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ +func_split_long_opt ()\ +{\ +\ func_split_long_opt_name=${1%%=*}\ +\ func_split_long_opt_arg=${1#*=}\ +} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ +func_split_short_opt ()\ +{\ +\ func_split_short_opt_arg=${1#??}\ +\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ +} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ +func_lo2o ()\ +{\ +\ case ${1} in\ +\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ +\ *) func_lo2o_result=${1} ;;\ +\ esac\ +} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_xform ()$/,/^} # func_xform /c\ +func_xform ()\ +{\ + func_xform_result=${1%.*}.lo\ +} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_arith ()$/,/^} # func_arith /c\ +func_arith ()\ +{\ + func_arith_result=$(( $* ))\ +} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_len ()$/,/^} # func_len /c\ +func_len ()\ +{\ + func_len_result=${#1}\ +} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + +fi + +if test x"$lt_shell_append" = xyes; then + sed -e '/^func_append ()$/,/^} # func_append /c\ +func_append ()\ +{\ + eval "${1}+=\\${2}"\ +} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ +func_append_quoted ()\ +{\ +\ func_quote_for_eval "${2}"\ +\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ +} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi + +if test x"$_lt_function_replace_fail" = x":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} +fi + + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" - print line -} -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ - || as_fn_error "could not setup config files machinery" "$LINENO" 5 -_ACEOF + cat <<_LT_EOF >> "$ofile" -# VPATH may cause trouble with some makes, so we remove $(srcdir), -# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=/{ -s/:*\$(srcdir):*/:/ -s/:*\${srcdir}:*/:/ -s/:*@srcdir@:*/:/ -s/^\([^=]*=[ ]*\):*/\1/ -s/:*$// -s/^[^=]*=[ ]*$// -}' -fi +# ### BEGIN LIBTOOL TAG CONFIG: CXX -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" +# The linker used to build libraries. +LD=$lt_LD_CXX -# Set up the scripts for CONFIG_HEADERS section. -# No need to generate them if there are no CONFIG_HEADERS. -# This happens for instance with `./config.status Makefile'. -if test -n "$CONFIG_HEADERS"; then -cat >"$tmp/defines.awk" <<\_ACAWK || -BEGIN { -_ACEOF +# How to create reloadable object files. +reload_flag=$lt_reload_flag_CXX +reload_cmds=$lt_reload_cmds_CXX -# Transform confdefs.h into an awk script `defines.awk', embedded as -# here-document in config.status, that substitutes the proper values into -# config.h.in to produce config.h. +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds_CXX -# Create a delimiter string that does not exist in confdefs.h, to ease -# handling of long lines. -ac_delim='%!_!# ' -for ac_last_try in false false :; do - ac_t=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_t"; then - break - elif $ac_last_try; then - as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done +# A language specific compiler. +CC=$lt_compiler_CXX -# For the awk script, D is an array of macro values keyed by name, -# likewise P contains macro parameters if any. Preserve backslash -# newline sequences. +# Is the compiler the GNU compiler? +with_gcc=$GCC_CXX -ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* -sed -n ' -s/.\{148\}/&'"$ac_delim"'/g -t rset -:rset -s/^[ ]*#[ ]*define[ ][ ]*/ / -t def -d -:def -s/\\$// -t bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3"/p -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p -d -:bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3\\\\\\n"\\/p -t cont -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p -t cont -d -:cont -n -s/.\{148\}/&'"$ac_delim"'/g -t clear -:clear -s/\\$// -t bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/"/p -d -:bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p -b cont -' >$CONFIG_STATUS || ac_write_fail=1 +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - for (key in D) D_is_set[key] = 1 - FS = "" -} -/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { - line = \$ 0 - split(line, arg, " ") - if (arg[1] == "#") { - defundef = arg[2] - mac1 = arg[3] - } else { - defundef = substr(arg[1], 2) - mac1 = arg[2] - } - split(mac1, mac2, "(") #) - macro = mac2[1] - prefix = substr(line, 1, index(line, defundef) - 1) - if (D_is_set[macro]) { - # Preserve the white space surrounding the "#". - print prefix "define", macro P[macro] D[macro] - next - } else { - # Replace #undef with comments. This is necessary, for example, - # in the case of _POSIX_SOURCE, which is predefined and required - # on some systems where configure will not decide to define it. - if (defundef == "undef") { - print "/*", prefix defundef, macro, "*/" - next - } - } -} -{ print } -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - as_fn_error "could not setup config headers machinery" "$LINENO" 5 -fi # test -n "$CONFIG_HEADERS" +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_CXX +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_CXX -eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_CXX - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_CXX - case $ac_tag in - *:-:* | *:-) cat >"$tmp/stdin" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; - esac +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object_CXX + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds_CXX +archive_expsym_cmds=$lt_archive_expsym_cmds_CXX + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds_CXX +module_expsym_cmds=$lt_module_expsym_cmds_CXX + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld_CXX + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_CXX + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_CXX + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX + +# If ld is used when linking, flag to hardcode \$libdir into a binary +# during linking. This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct_CXX + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \${shlibpath_var} if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute_CXX + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L_CXX + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic_CXX + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath_CXX -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_CXX -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols_CXX +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_CXX - case $ac_mode in - :F) - # - # CONFIG_FILE - # +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_CXX - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac -_ACEOF +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_CXX -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds_CXX -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds_CXX -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&2;} +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec_CXX - rm -f "$tmp/stdin" - case $ac_file in - -) cat "$tmp/out" && rm -f "$tmp/out";; - *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; - esac \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - ;; - :H) - # - # CONFIG_HEADER - # - if test x"$ac_file" != x-; then - { - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" - } >"$tmp/config.h" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then - { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 -$as_echo "$as_me: $ac_file is unchanged" >&6;} - else - rm -f "$ac_file" - mv "$tmp/config.h" "$ac_file" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - fi - else - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ - || as_fn_error "could not create -" "$LINENO" 5 - fi -# Compute "$ac_file"'s index in $config_headers. -_am_arg="$ac_file" -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || -$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$_am_arg" : 'X\(//\)[^/]' \| \ - X"$_am_arg" : 'X\(//\)$' \| \ - X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$_am_arg" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'`/stamp-h$_am_stamp_count - ;; +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_CXX - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects_CXX +postdep_objects=$lt_postdep_objects_CXX +predeps=$lt_predeps_CXX +postdeps=$lt_postdeps_CXX + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_CXX + +# ### END LIBTOOL TAG CONFIG: CXX +_LT_EOF - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Autoconf 2.62 quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir=$dirpart/$fdir; as_fn_mkdir_p - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} ;; + "ntpd/complete.conf":F) sed -e '/^rlimit$/d' -e '/^$/d' < ntpd/complete.conf > ntpd/complete.conf.new && mv ntpd/complete.conf.new ntpd/complete.conf ;; "ntpdc/nl.pl":F) chmod +x ntpdc/nl.pl ;; - "scripts/calc_tickadj":F) chmod +x scripts/calc_tickadj ;; - "scripts/checktime":F) chmod +x scripts/checktime ;; - "scripts/freq_adj":F) chmod +x scripts/freq_adj ;; - "scripts/html2man":F) chmod +x scripts/html2man ;; - "scripts/mkver":F) chmod +x scripts/mkver ;; - "scripts/ntp-wait":F) chmod +x scripts/ntp-wait ;; - "scripts/ntpsweep":F) chmod +x scripts/ntpsweep ;; - "scripts/ntptrace":F) chmod +x scripts/ntptrace ;; + "scripts/build/mkver":F) chmod +x scripts/build/mkver ;; + "scripts/calc_tickadj/calc_tickadj":F) chmod +x scripts/calc_tickadj/calc_tickadj ;; + "scripts/ntp-wait/ntp-wait":F) chmod +x scripts/ntp-wait/ntp-wait ;; + "scripts/ntpsweep/ntpsweep":F) chmod +x scripts/ntpsweep/ntpsweep ;; + "scripts/ntptrace/ntptrace":F) chmod +x scripts/ntptrace/ntptrace ;; "scripts/ntpver":F) chmod +x scripts/ntpver ;; "scripts/plot_summary":F) chmod +x scripts/plot_summary ;; "scripts/summary":F) chmod +x scripts/summary ;; + "scripts/update-leap/update-leap":F) chmod +x scripts/update-leap/update-leap ;; esac done # for ac_tag @@ -27223,7 +40004,7 @@ _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || - as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 + as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. @@ -27244,7 +40025,7 @@ if test "$no_create" != yes; then exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit $? + $ac_cs_success || as_fn_exit 1 fi # @@ -27385,7 +40166,7 @@ $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cach # The eval makes quoting arguments work. eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \ --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" || - as_fn_error "$ac_sub_configure failed for $ac_dir" "$LINENO" 5 + as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5 fi cd "$ac_popdir" diff --git a/contrib/ntp/configure.ac b/contrib/ntp/configure.ac index 49cc9ae8d..42e18a49f 100644 --- a/contrib/ntp/configure.ac +++ b/contrib/ntp/configure.ac @@ -1,84 +1,97 @@ -dnl -*-fundamental-*- -dnl Process this file with autoconf to produce a configure script. -m4_include([version.m4]) -AC_INIT(ntp, VERSION_NUMBER) -AM_INIT_AUTOMAKE +dnl NTP top-level configure.ac -*- Autoconf -*- +dnl +m4_include([sntp/m4/version.m4]) +AC_PREREQ([2.61]) +AC_INIT( + [ntp], + [VERSION_NUMBER], + [http://bugs.ntp.org./], + [], + [http://www.ntp.org./]dnl +) +AC_CONFIG_MACRO_DIR([sntp/m4]) +AC_CONFIG_AUX_DIR([sntp/libevent/build-aux]) +AC_LANG([C]) + +AC_PRESERVE_HELP_ORDER + +# Bump ntp_configure_cache_version for each change to configure.ac or +# .m4 files which invalidates cached values from previous configure +# runs. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of each. If you are not sure, the +# safe choice is to bump all on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +ntp_configure_cache_version=20120806 + +# When the cache version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + +NTP_CACHEVERSION([main], [$ntp_configure_cache_version]) + +AM_INIT_AUTOMAKE([1.10 foreign -Wall -Wno-gnu]) + +dnl AM_SILENT_RULES req. automake 1.11. [yes] defaults V=0 +m4_ifdef( + [AM_SILENT_RULES], + [AM_SILENT_RULES([yes])] +) +AC_CANONICAL_BUILD AC_CANONICAL_HOST dnl the 'build' machine is where we run configure and compile dnl the 'host' machine is where the resulting stuff runs. -AC_DEFINE_UNQUOTED(STR_SYSTEM, "$host", [canonical system (cpu-vendor-os) of where we should run]) -AM_CONFIG_HEADER([config.h]) +AC_DEFINE_UNQUOTED([STR_SYSTEM], ["$host"], + [canonical system (cpu-vendor-os) of where we should run]) +AC_CONFIG_HEADERS([config.h]) dnl AC_ARG_PROGRAM -AC_PREREQ(2.53) -ac_cv_var_atom_ok=no -ac_cv_var_oncore_ok=no -ac_cv_var_parse_ok=no -ac_cv_var_ripe_ncc_ok=no -ac_cv_var_jupiter_ok=no +ntp_atom_ok=${ntp_atom_ok=no} +ntp_oncore_ok=${ntp_oncore_ok=no} +ntp_parse_ok=${ntp_parse_ok=no} +ntp_ripe_ncc_ok=${ntp_parse_ok=no} +ntp_jupiter_ok=${ntp_jupiter_ok=no} + +NTP_PROG_CC +AC_PROG_CPP +# Do we need CXX for anything besides google test? +AC_PROG_CXX +AC_PROG_YACC +AC_PROG_CC_C_O +AX_C99_STRUCT_INIT + +NTP_VPATH_HACK dnl used only by ntpd/Makefile.am -dnl Grab any initial CFLAGS so we can pick better defaults. -iCFLAGS="$CFLAGS" +NTP_LOCINFO([sntp]) dnl takes over from NTP_BINDIR, in NTP_LIBNTP -dnl check these early to avoid autoconf warnings -AC_AIX -AC_MINIX +dnl AM_PROG_AR req. automake 1.12 +m4_ifdef( + [AM_PROG_AR], + [AM_PROG_AR] +) # So far, the only shared library we might use is libopts. # It's a small library - we might as well use a static version of it. AC_DISABLE_SHARED +AC_PROG_LIBTOOL +AC_SUBST([LIBTOOL_DEPS]) -dnl we need to check for cross compile tools for vxWorks here -AC_PROG_CC -# Ralf Wildenhues: With per-target flags we need CC_C_O -# AM_PROG_CC_C_O supersets AC_PROG_CC_C_O -AM_PROG_CC_C_O -AC_PROG_CC_STDC -AC_PROG_CPP - -# HMS: These need to be moved to AM_CPPFLAGS and/or AM_CFLAGS -case "$host" in - *-*-amigaos) - CFLAGS="$CFLAGS -Dfork=vfork -DSYS_AMIGA" - ;; - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in - yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; - esac - ;; - *-pc-cygwin*) - CFLAGS="$CFLAGS -DSYS_CYGWIN32" - ;; - i386-sequent-sysv4) - case "$CC" in - cc) - CFLAGS="$CFLAGS -Wc,+abi-socket" - ;; - esac - ;; - *-*-mpeix*) - CPPFLAGS="$CPPFLAGS -DMPE -D_POSIX_SOURCE -D_SOCKET_SOURCE -I/SYSLOG/PUB" - LDFLAGS="$LDFLAGS -L/SYSLOG/PUB" - LIBS="$LIBS -lcurses" - ;; - *-*-solaris*) - # see "man standards". - # -D_XOPEN_SOURCE=500 is probably OK for c89 and before - # -D_XOPEN_SOURCE=600 seems OK for c99 - #CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=500 -D__EXTENSIONS__" - CPPFLAGS="$CPPFLAGS -D__EXTENSIONS__" - libxnet=-lxnet - ;; -esac - -AMU_OS_CFLAGS - -# NTP has (so far) been relying on leading-edge autogen. +# NTP has (so far) been relying on leading-edge autogen, which +# means we need the appropriate corresponding libopts as well. # Therefore, by default: -# - use the version we ship with +# - use the version of libopts we ship with # - do not install it # - build a static copy (AC_DISABLE_SHARED - done earlier) case "${enable_local_libopts+set}" in @@ -89,263 +102,94 @@ case "${enable_libopts_install+set}" in set) ;; *) enable_libopts_install=no ;; esac -LIBOPTS_CHECK(libopts) - -AC_CACHE_CHECK( - [if $CC can handle @%:@warning], - ac_cv_cpp_warning, - [ - AC_COMPILE_IFELSE( - AC_LANG_PROGRAM([], [#warning foo]), - [ac_cv_cpp_warning=yes], - [ac_cv_cpp_warning=no], - ) - ] -) - -case "$ac_cv_cpp_warning" in - no) - AC_DEFINE([NO_OPTION_NAME_WARNINGS], [1], [Should we avoid @%:@warning on option name collisions?]) -esac - -case "$GCC" in - yes) - SAVED_CFLAGS_AC="$CFLAGS" - CFLAGS="$CFLAGS -Wstrict-overflow" - AC_CACHE_CHECK( - [if $CC can handle -Wstrict-overflow], - ac_cv_gcc_Wstrict_overflow, - [ - AC_COMPILE_IFELSE( - [AC_LANG_PROGRAM([], [])], - [ac_cv_gcc_Wstrict_overflow=yes], - [ac_cv_gcc_Wstrict_overflow=no] - ) - ] - ) - CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC - # - # $ac_cv_gcc_Wstrict_overflow is tested later to add the - # flag to CFLAGS. - # -esac - - -case "$GCC" in - yes) - SAVED_CFLAGS_AC="$CFLAGS" - CFLAGS="$CFLAGS -Winit-self" - AC_CACHE_CHECK( - [if $CC can handle -Winit-self], - ac_cv_gcc_Winit_self, - [ - AC_COMPILE_IFELSE( - [AC_LANG_PROGRAM([], [])], - [ac_cv_gcc_Winit_self=yes], - [ac_cv_gcc_Winit_self=no] - ) - ] - ) - CFLAGS="$SAVED_CFLAGS_AC" - unset SAVED_CFLAGS_AC - # - # $ac_cv_gcc_Winit_self is tested later to add the - # flag to CFLAGS. - # -esac +enable_nls=no +LIBOPTS_CHECK_NOBUILD([sntp/libopts]) +NTP_LIBEVENT_CHECK_NOBUILD([2], [sntp/libevent]) +NTP_LIBNTP -AC_MSG_CHECKING([for bin subdirectory]) -AC_ARG_WITH(binsubdir, - AC_HELP_STRING([--with-binsubdir], [bin ={bin,sbin}]), - use_binsubdir="$withval", use_binsubdir="bin") - -case "$use_binsubdir" in - bin) - ;; - sbin) - ;; - *) - AC_MSG_ERROR([<$use_binsubdir> is illegal - must be "bin" or "sbin"]) - ;; -esac -AC_MSG_RESULT($use_binsubdir) -BINSUBDIR=$use_binsubdir -AC_SUBST(BINSUBDIR) - -AC_MSG_CHECKING([if we want to use arlib]) -AC_ARG_WITH(arlib, - AC_HELP_STRING([--with-arlib], [- Compile the async resolver library?]), +AC_MSG_CHECKING([for deprecated --with-arlib]) +AC_ARG_WITH([arlib], + AS_HELP_STRING([--with-arlib], [- deprecated, arlib not distributed]), [ans=$withval], [ans=no]) AC_MSG_RESULT([$ans]) -if test -d $srcdir/arlib -then - case "$ans" in - yes) - ARLIB_DIR=arlib - AC_CONFIG_SUBDIRS(arlib) - ;; - esac -fi -AC_SUBST(ARLIB_DIR) - -AC_ARG_WITH(rpath, - AC_HELP_STRING([--without-rpath], [s Disable auto-added -R linker paths]), -[ans=$withval], [ans=x]) case "$ans" in - no) - need_dash_r= - ;; yes) - need_dash_r=1 - ;; -esac -# HMS: Why isn't this $build? -# Well, that depends on if we need this for the build toolchain or -# for info in the host executable... -# I still have no idea which way this should go, but nobody has complained. -case "$host" in - *-*-netbsd*) - case "$need_dash_r" in - no) ;; - *) need_dash_r=1 - ;; - esac - ;; - *-*-solaris*) - case "$need_dash_r" in - no) ;; - *) need_dash_r=1 - ;; - esac - ;; -esac - - -case "$build" in - $host) - ;; - *) case "$host" in - *-*-vxworks*) - # Quick and dirty sanity check - case "$VX_KERNEL" in - '') AC_MSG_ERROR(Please follow the directions in html/build/hints/vxworks.html!) - ;; - esac - CFLAGS="$CFLAGS -DSYS_VXWORKS" - ;; - esac + AC_MSG_WARN([Please do not use --with-arlib, arlib is no longer included. In the future, --with-arlib will not be recognized.]) ;; esac dnl we need to check for cross compile tools for vxWorks here AC_PROG_AWK +AS_UNSET([ac_cv_prog_AWK]) +AC_SUBST([AWK]) dnl scripts/ntpver.in AC_PROG_MAKE_SET -rm -f conftest* +AC_SUBST([CFLAGS]) +AC_SUBST([LDFLAGS]) -case "$GCC" in - yes) - CFLAGS="$CFLAGS -Wall" - # CFLAGS="$CFLAGS -Wcast-align" - CFLAGS="$CFLAGS -Wcast-qual" - # CFLAGS="$CFLAGS -Wconversion" - # CFLAGS="$CFLAGS -Werror" - # CFLAGS="$CFLAGS -Wextra" - # CFLAGS="$CFLAGS -Wfloat-equal" - CFLAGS="$CFLAGS -Wmissing-prototypes" - CFLAGS="$CFLAGS -Wpointer-arith" - CFLAGS="$CFLAGS -Wshadow" - # - # OpenSSL has a number of callback prototypes - # inside other function prototypes which trigger - # warnings with -Wstrict-prototypes, such as: - # - # int i2d_RSA_NET(const RSA *a, unsigned char **pp, - # int (*cb)(), int sgckey); - # ^^^^^^^^^^^ - # - CFLAGS="$CFLAGS -Wno-strict-prototypes" - # CFLAGS="$CFLAGS -Wtraditional" - # CFLAGS="$CFLAGS -Wwrite-strings" - case "$ac_cv_gcc_Winit_self" in - yes) - CFLAGS="$CFLAGS -Winit-self" - esac - case "$ac_cv_gcc_Wstrict_overflow" in - yes) - #not yet: CFLAGS="$CFLAGS -Wstrict-overflow" - esac - ;; -esac +AC_PROG_LN_S +AC_ISC_POSIX -case "$host" in - *-next-nextstep3) - CFLAGS="$CFLAGS -posix" - ;; -dnl This is currently commented out by bor. -dnl The new versions of ReliantUNIX round adjtime() interval down -dnl to 1/100s (system tick). This makes tickadj actually useless. -dnl So, I'd better not use additional flags. -dnl I leave it here just in case anybody has better idea -dnl mips-sni-sysv4* ) -dnl # -dnl # Add flags for 64 bit file access to enable tickadj to access /dev/kmem -dnl # -dnl if getconf _LFS_CFLAGS > /dev/null 2>&1 ; then -dnl CFLAGS="$CFLAGS `getconf _LFS_CFLAGS`" -dnl fi -dnl ;; -esac - -ac_busted_vpath_in_make=no -case "$build" in - *-*-irix6.1*) # 64 bit only - # busted vpath? +AC_PATH_PROG([PATH_PERL], [perl]) +dnl Saving cached hardcoded paths rather than searching $PATH during a +dnl cached configure run is an optimization not worth the the cost of +dnl preventing newly-installed tools from being found. Short-circuit +dnl the caching after the tests so preset overrides still work. +AS_UNSET([ac_cv_path_PATH_PERL]) +AC_PATH_PROG([PATH_TEST], [test]) +AS_UNSET([ac_cv_path_PATH_TEST]) +test -z "$CONFIG_SHELL" && CONFIG_SHELL=/bin/sh +AC_SUBST([CONFIG_SHELL]) dnl for scripts #!/path/to/sh + +AC_ARG_WITH( + [net-snmp-config], + [AS_HELP_STRING( + [--with-net-snmp-config], + [+ =net-snmp-config] + )], + [ans=$withval], + [ans=yes] +) +case "$ans" in + no) + ;; + yes) + ans=net-snmp-config ;; - *-*-irix6*) # 6.2 (and later?) - ac_busted_vpath_in_make=yes + /*) ;; - *-*-solaris2.5.1) - ac_busted_vpath_in_make=yes + */*) + AC_MSG_ERROR([--with-net-snmp-config takes either a name or an absolute path]) ;; - *-*-unicosmp*) - ac_busted_vpath_in_make=yes + *) ;; esac - -case "$ac_busted_vpath_in_make$srcdir" in - no*) ;; - yes.) ;; - *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | sed -e 's/GNU Make version \(1-9.]*\).*/\1/' -e q`" in - '') - AC_MSG_ERROR([building outside of the main directory requires GNU make]) - ;; - *) ;; - esac +PROG_NET_SNMP_CONFIG=$ans +AC_MSG_CHECKING([for net-snmp-config path]) +case "$PROG_NET_SNMP_CONFIG" in + no) ;; + /*) + PATH_NET_SNMP_CONFIG=$PROG_NET_SNMP_CONFIG ;; + *) + AC_PATH_PROG([PATH_NET_SNMP_CONFIG], [$PROG_NET_SNMP_CONFIG]) + AS_UNSET([ac_cv_path_PATH_NET_SNMP_CONFIG]) +;; esac +AC_MSG_RESULT([$PATH_NET_SNMP_CONFIG]) -AC_SUBST(CFLAGS)dnl -AC_SUBST(LDFLAGS)dnl - -m4_defun([_LT_AC_LANG_CXX_CONFIG], [:]) -m4_defun([_LT_AC_LANG_F77_CONFIG], [:]) - -AC_PROG_LIBTOOL - -AC_PROG_LN_S -AC_PROG_GCC_TRADITIONAL -AC_C_VOLATILE -AC_ISC_POSIX -AC_PATH_PROG(PATH_SH, sh) -AC_PATH_PROG(PATH_PERL, perl) - -hs_ULONG_CONST # remove for 4.2.5 +case "$PATH_NET_SNMP_CONFIG" in + /*) AC_CACHE_CHECK( + [for net-snmp version], + [ntp_cv_net_snmp_version], + [ntp_cv_net_snmp_version=`$PATH_NET_SNMP_CONFIG --version`] + ) + ;; +esac case "$host" in *-*-vxworks*) @@ -353,423 +197,382 @@ case "$host" in ;; esac -AC_PROG_INSTALL +# HMS: a check for -lnsl used to be here - now being done in NTP_LIBNTP +AC_SEARCH_LIBS([openlog], [gen syslog]) +# XXX library list will be in ac_cv_search_openlog -case "$host" in - *-pc-cygwin*) - AC_CHECK_LIB(advapi32, main) +# LIBSECCOMP is off by default -- needs testing with all the features +# Please send bug reports to loganaden@gmail.com +AC_MSG_CHECKING([if we want to use libseccomp sandboxing (EXPERIMENTAL)]) +AC_ARG_ENABLE( + [libseccomp], + [AS_HELP_STRING( + [--enable-libseccomp], + [EXPERIMENTAL: enable support for libseccomp sandboxing (default is no) ] + )], + [ntp_ok=$enableval], + [ntp_ok=no] +) +AC_MSG_RESULT([$ntp_ok]) +case "$ntp_ok" in + yes) + AC_SEARCH_LIBS( + [seccomp_init], + [seccomp], + [AC_DEFINE([LIBSECCOMP], [1], + [Define to any value to include libseccomp sandboxing.])] + ) + AC_TRY_RUN([ + #include + #include + #include + #include + #include + + int main(void) + { + int ret; + ret = prctl(PR_GET_SECCOMP, 0, 0, 0, 0); + if (ret < 0) { + switch (errno) { + case ENOSYS: + return 1; + case EINVAL: + return 1; + default: + return 1; + } + } + ret = + prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, NULL, 0, 0); + if (ret < 0) { + switch (errno) { + case EINVAL: + return 1; + case EFAULT: + return 0; + default: + return 1; + } + } +return 1; +} +] +, AC_DEFINE([KERN_SECCOMP], 1, +[Define to use libseccomp system call filtering.]) +, [] +) ;; esac -AC_CHECK_FUNC([gethostent], , - AC_SEARCH_LIBS([gethostent], [nsl], , , [$libxnet -lsocket])) -AC_CHECK_FUNC([openlog], , - AC_SEARCH_LIBS([openlog], [gen], , - AC_SEARCH_LIBS([openlog], [syslog], , , [$libxnet -lsocket]))) -AC_SEARCH_LIBS([MD5Init], [md5 md]) -AC_CHECK_FUNCS(MD5Init) - -# following block becomes on 4.2.5: NTP_LINEEDITLIBS -dnl HMS: What a hack... -AC_CHECK_HEADERS(readline/history.h readline/readline.h) -case "$ac_cv_header_readline_history_h$ac_cv_header_readline_readline_h" in - *no*) ;; - *) save_LIBS=$LIBS - LIBS= - # Ralf Wildenhues: either unset ... or cache READLINE_LIBS - unset ac_cv_lib_readline_readline - AC_CHECK_LIB(readline, readline, , - AC_MSG_NOTICE([Trying again with -lcurses]) - unset ac_cv_lib_readline_readline - AC_CHECK_LIB(readline, readline, - LIBS="-lreadline -lcurses $LIBS" - AC_DEFINE(HAVE_LIBREADLINE) - AC_DEFINE(HAVE_LIBCURSES, , [Do we have the curses library?]), - AC_CHECK_LIB(edit, readline, - LIBS="-ledit -lcurses" - AC_DEFINE(HAVE_LIBEDIT, , [Do we have the edit library?]) - AC_DEFINE(HAVE_LIBCURSES, , [Do we have the curses library?]) - , , -lcurses) - , -lcurses)) - READLINE_LIBS=$LIBS - AC_SUBST(READLINE_LIBS) - LIBS=$save_LIBS - ;; -esac +NTP_FACILITYNAMES dnl Digital UNIX V4.0 and Solaris 7 have POSIX.1c functions in -lrt dnl Solaris 2.6 only has -lposix4; in Solaris 7, this is a symlink to -lrt, dnl so only use one of them. Linux (glibc-2.1.2 and -2.2.2, at least) dnl does Strange Things with extra processes using the Posix-compatibility dnl real-time library, so we don't want to use it. +dnl +dnl 081118 Harlan got tired of looking for a way to get the sched*() +dnl functions to link OK with either cc or gcc. case "$host" in *-*-*linux*) ;; + *-*-osf4*) ;; + *-*-osf5*) ;; *) - AC_CHECK_LIB(rt, sched_setscheduler, , - AC_CHECK_LIB(posix4, sched_setscheduler)) - ;; -esac - -AC_CHECK_FUNC(setsockopt, , - [AC_SEARCH_LIBS([setsockopt], [socket xnet])]) - -AC_HEADER_STDC -AC_CHECK_HEADERS(bstring.h) -AC_CHECK_HEADER(dns_sd.h, - [AC_CHECK_LIB(dns_sd, - DNSServiceRegister, - [AC_DEFINE(HAVE_DNSREGISTRATION, 1, - [Use Rendezvous/DNS-SD registration])])]) -case "$ac_cv_lib_dns_sd_DNSServiceRegister" in - yes) LIBS="-ldns_sd $LIBS" ;; -esac -AC_CHECK_HEADERS(errno.h fcntl.h ieeefp.h math.h) - -# HMS: Lame, but fast. -if test -f /etc/redhat-release -then - : -else - AC_CHECK_HEADERS(md5.h, [], [], -[#if HAVE_SYS_TYPES_H -#include -#endif -]) -fi -AC_CHECK_HEADERS(memory.h netdb.h poll.h) -AC_CHECK_HEADERS(sched.h sgtty.h stdlib.h string.h termio.h) -AC_CHECK_HEADERS(termios.h timepps.h timex.h unistd.h) + # HMS: Make sure we check for -lrt for clock_* before this... + case "$ac_cv_search_clock_gettime" in + '') AC_MSG_ERROR([Internal Error: Haven't looked for clock_gettime() yet!]) ;; + esac + AC_SEARCH_LIBS([sched_setscheduler], [rt posix4]) + ;; +esac + +AC_CHECK_HEADERS([bstring.h]) +AC_CHECK_HEADER( + [dns_sd.h], + [AC_SEARCH_LIBS( + [DNSServiceRegister], + [dns_sd], + [AC_DEFINE([HAVE_DNSREGISTRATION], [1], + [Use Rendezvous/DNS-SD registration])] + )] +) +AC_CHECK_HEADERS([fcntl.h fnmatch.h ieeefp.h inttypes.h kvm.h math.h]) + +AC_CHECK_HEADERS([memory.h netdb.h poll.h]) +AC_CHECK_HEADERS([sgtty.h stdatomic.h stdlib.h string.h termio.h]) +AC_CHECK_HEADERS([termios.h timepps.h timex.h unistd.h]) + case "$host" in *-*-aix*) - AC_CHECK_HEADERS(utmpx.h) + AC_CHECK_HEADERS([utmpx.h]) case "$ac_cv_header_utmpx_h" in - yes) ;; - *) AC_CHECK_HEADERS(utmp.h) ;; + yes) + ;; + *) + AC_CHECK_HEADERS([utmp.h]) + ;; esac ;; - *) AC_CHECK_HEADERS(utmp.h utmpx.h) ;; + *) + AC_CHECK_HEADERS([utmp.h utmpx.h]) + ;; esac -AC_CHECK_HEADERS(arpa/nameser.h) -AC_CHECK_HEADERS(sys/socket.h) -AC_CHECK_HEADERS(net/if.h, [], [], -[#if HAVE_SYS_SOCKET_H -#include -#endif -]) -AC_CHECK_HEADERS(net/if6.h) -AC_CHECK_HEADERS(net/route.h, [], [], [ -#include -#include -#include -]) -AC_CHECK_HEADERS(netinet/in_system.h netinet/in_systm.h) -AC_CHECK_HEADERS(netinet/in.h) -AC_CHECK_HEADERS(netinet/ip.h, [], [], -[#if HAVE_SYS_TYPES_H -#include -#endif -#if HAVE_NETINET_IN_H -#include -#endif -#if HAVE_NETINET_IN_SYSTM_H -#include -#endif -]) -# Check for IPTOS_PREC -AC_CACHE_CHECK( - [IPPROTO_IP IP_TOS IPTOS_LOWDELAY], - ac_cv_ip_tos, - [ - AC_EGREP_CPP( - [yes], - [ - #if HAVE_SYS_TYPES_H - #include - #endif - #if HAVE_NETINET_IP_H - #include - #include - #endif - #if defined(IPPROTO_IP) && defined(IP_TOS) && defined(IPTOS_LOWDELAY) - yes - #endif - ], - [ac_cv_ip_tos=yes], - [ac_cv_ip_tos=no] - ) - ] -) +# +# On Suns only (so far) getpass() truncates the typed password to 8 +# characters, but getpassphrase() allows up to 257. Most systems' +# getpass() does not truncate, at least not so as to affect ntpq and +# ntpdc password prompts. +# +# So check for getpassphrase(), but only on Sun operating systems. +# +case "$host" in + *-*-sunos*|*-*-solaris*) + AC_CHECK_FUNCS([getpassphrase]) +esac -case "$ac_cv_ip_tos" in + +AC_CHECK_HEADERS([net/if6.h]) +AC_CHECK_HEADERS([net/route.h], [], [], [ + #include + #include + #include +]) + +AC_CHECK_HEADERS([netinfo/ni.h]) +case "$ac_cv_header_netinfo_ni_h" in yes) - AC_DEFINE(HAVE_IPTOS_SUPPORT, 1, [Do we have IPTOS support?]) + AC_DEFINE([HAVE_NETINFO], [1], [NetInfo support?]) esac - -AC_CHECK_HEADERS(netinfo/ni.h, [AC_DEFINE(HAVE_NETINFO, 1, [NetInfo support?])]) -AC_CHECK_HEADERS(sun/audioio.h sys/audioio.h) -dnl AC_CHECK_HEADERS(sys/chudefs.h) -AC_CHECK_HEADERS(sys/clkdefs.h sys/file.h) +AC_CHECK_HEADERS([sun/audioio.h sys/audioio.h sys/file.h]) case "$host" in - *-*-sunos4*) ;; - *) AC_CHECK_HEADERS(sys/ioctl.h) + *-*-sunos4*) + ;; + *) + AC_CHECK_HEADERS([sys/ioctl.h]) ;; esac -AC_CHECK_HEADERS(sys/ipc.h) -AC_CHECK_HEADERS(sys/lock.h sys/mman.h sys/modem.h sys/param.h sys/ppsclock.h) +AC_CHECK_HEADERS([sys/ipc.h sys/lock.h sys/mman.h]) # HMS: Check sys/proc.h and sys/resource.h after some others -AC_CHECK_HEADERS(sys/ppstime.h) +AC_CHECK_HEADERS([sys/modem.h sys/ppsclock.h sys/ppstime.h sched.h]) case "$ac_cv_header_sched_h" in - yes) ;; - *) AC_CHECK_HEADERS(sys/sched.h) ;; -esac -case "$host" in - *-*-sco*) - AC_CHECK_HEADERS(sys/sio.h) + yes) + ;; + *) + AC_CHECK_HEADERS([sys/sched.h]) ;; esac # HMS: Check sys/shm.h after some others -AC_CHECK_HEADERS(sys/select.h sys/signal.h sys/sockio.h) +AC_CHECK_HEADERS([sys/select.h sys/signal.h sys/sockio.h]) # HMS: Checked sys/socket.h earlier case "$host" in - *-*-netbsd*) ;; - *) AC_CHECK_HEADERS(machine/soundcard.h sys/soundcard.h) - ;; -esac -AC_CHECK_HEADERS(sys/stat.h sys/stream.h) -AC_CHECK_HEADERS(sys/stropts.h sys/sysctl.h sys/syssgi.h sys/systune.h) -AC_CHECK_HEADERS(sys/termios.h sys/time.h sys/signal.h) -AC_EGREP_CPP(yes, -[#if HAVE_SYS_TIME_H -# include -#endif -#if HAVE_ERRNO_H -# include -#endif -#include -#ifdef PPS_API_VERS_1 -yes -#endif -], [AC_CHECK_HEADERS(sys/timepps.h, [], [], -[#if HAVE_SYS_TIME_H -# include -#endif -#if HAVE_ERRNO_H -# include -#endif -]) -]) -AC_CHECK_HEADERS(sys/timers.h sys/tpro.h sys/types.h sys/wait.h) -AC_HEADER_TIME + *-*-netbsd*) + ;; + *) + AC_CHECK_HEADERS([machine/soundcard.h sys/soundcard.h]) + ;; +esac +AC_CHECK_HEADERS([sys/stat.h sys/stream.h stropts.h sys/stropts.h sys/syssgi.h]) +AC_CHECK_HEADERS([sys/systune.h sys/termios.h sys/tpro.h sys/wait.h]) case "$host" in *-convex-*) - AC_CHECK_HEADERS(/sys/sync/queue.h /sys/sync/sema.h) - ;; + AC_CHECK_HEADERS([/sys/sync/queue.h /sys/sync/sema.h]) + ;; *-*-bsdi*) - AC_CHECK_HEADERS(machine/inline.h sys/pcl720.h sys/i8253.h) - ;; -esac - -case "$host" in - *-*-*linux*) - AC_CHECK_FUNCS(__adjtimex __ntp_gettime) + AC_CHECK_HEADERS([machine/inline.h sys/pcl720.h sys/i8253.h]) ;; esac -case "$ac_cv_func___adjtimex" in - yes) ;; - *) - AC_CHECK_LIB(elf, nlist) dnl Only needed for tickadj... - dnl AC_CHECK_LIB(kvm, main, , , -lelf) - AC_CHECK_LIB(kvm, main) dnl We already know about -lelf here... - AC_CHECK_LIB(ld, nlist) - AC_CHECK_LIB(mld, nlist) - AC_CHECK_HEADER(nlist.h, - [AC_DEFINE(NLIST_STRUCT, 1, [nlist stuff]) - AC_CACHE_CHECK([for n_un in struct nlist], ac_cv_struct_nlist_n_un, - [AC_TRY_COMPILE([#include ], - [struct nlist n; n.n_un.n_name = 0;], - ac_cv_struct_nlist_n_un=yes, ac_cv_struct_nlist_n_un=no)]) - if test $ac_cv_struct_nlist_n_un = yes; then - AC_DEFINE(NLIST_NAME_UNION, 1, [does struct nlist use a name union?]) - fi - ])dnl - ;; -esac - -dnl AC_CHECK_HEADERS(net/if.h, [], [], -dnl [#if HAVE_SYS_TYPES_H -dnl # include -dnl #endif -dnl #if HAVE_SYS_SOCKET_H -dnl # include -dnl #endif -dnl ]) - -AC_CHECK_HEADERS(sys/proc.h, [], [], -[#if HAVE_SYS_TYPES_H -# include -#endif -#if HAVE_SYS_TIME_H -# include -#endif -]) - -AC_CHECK_HEADERS(sys/resource.h, [], [], -[#if HAVE_SYS_TIME_H -# include -#endif -]) - -AC_CHECK_HEADERS(sys/shm.h, [], [], -[#if HAVE_SYS_TYPES_H -# include -#endif -#if HAVE_SYS_IPC_H -# include -#endif -]) -AC_CHECK_HEADERS(sys/timex.h, [], [], -[#if HAVE_SYS_TIME_H -# include -#endif -]) - -AC_CHECK_HEADERS(resolv.h, [], [], -[#if HAVE_SYS_TYPES_H -#include -#endif -#if HAVE_NETINET_IN_H -#include -#endif -#if HAVE_ARPA_NAMESER_H -#include -#endif -]) - -AC_CACHE_CHECK([for basic volatile support], ac_cv_c_volatile, -[AC_TRY_COMPILE([],[ -volatile int x;], - ac_cv_c_volatile=yes, - ac_cv_c_volatile=no) -]) -case "$ac_cv_c_volatile" in +case "$ac_cv_header_stdatomic_h" in yes) - ;; - *) AC_DEFINE(volatile, , [Does the compiler like "volatile"?]) + AC_CHECK_FUNCS([atomic_thread_fence]) + AC_CACHE_CHECK( + [for atomic_thread_fence()], + [ntp_cv_func_atomic_thread_fence], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + ]], + [[ + atomic_thread_fence(memory_order_seq_cst); + ]] + )] + [ntp_cv_func_atomic_thread_fence=yes], + [ntp_cv_func_atomic_thread_fence=no] + )] + ) ;; esac -# -# following block goes away in 4.2.5 -# -# AM_C_PROTOTYPES gives us ansi2knr -case "$build" in - *-*-solaris2*) - # Assume that solaris2 is Ansi C... +case "$host" in + *-*-solaris2.6) + # Broken... ;; *) - AM_C_PROTOTYPES + AC_CHECK_FUNCS([ntp_adjtime ntp_gettime]) ;; esac -AC_CACHE_CHECK(if C compiler permits function prototypes, ac_cv_have_prototypes, -[AC_TRY_COMPILE([ -extern int foo (short); -int foo(short i) { return i; }],[ -int i;], ac_cv_have_prototypes=yes, ac_cv_have_prototypes=no) + +case "$host" in + *-*-*linux*) + case "$ac_cv_func_ntp_gettime" in + yes) + ;; + *) + AC_CHECK_FUNCS([__ntp_gettime]) + case "$ac_cv_func___ntp_gettime" in + yes) + AC_DEFINE([ntp_gettime], [__ntp_gettime], [deviant]) + AC_DEFINE([HAVE_NTP_GETTIME], [1], [via __ntp_gettime]) + esac + ;; + esac + AC_CHECK_FUNCS([adjtimex]) + case "$ac_cv_func_adjtimex" in + yes) + AC_DEFINE([ntp_adjtime], [adjtimex], [deviant]) + AC_DEFINE([HAVE_NTP_ADJTIME], [1], [via adjtimex]) + have_adjtimex=1 + ;; + *) + AC_CHECK_FUNCS([__adjtimex]) + case "$ac_cv_func___adjtimex" in + yes) + AC_DEFINE([ntp_adjtime], [__adjtimex], [deviant]) + AC_DEFINE([HAVE_NTP_ADJTIME], [1], [via __adjtimex]) + AC_DEFINE([adjtimex], [__adjtimex], [deviant]) + AC_DEFINE([HAVE_ADJTIMEX], [1], [via __adjtimex]) + have_adjtimex=1 + esac + ;; + esac +esac +case "$have_adjtimex" in + '') + # nlist stuff is only needed for tickadj. + saved_LIBS="$LIBS" + LIBS= + AC_SEARCH_LIBS([nlist], [elf ld mld]) + # XXX ac_cv_search_nlist will be 'none required', 'no', or '-l...' + AC_SEARCH_LIBS([kvm_open], [kvm]) dnl We already know about -lelf here... + # XXX ac_cv_search_kvm_open will be 'none required', 'no', or '-l...' + AC_CHECK_HEADERS([nlist.h sys/var.h]) + case "$ac_cv_header_nlist_h" in + yes) + AC_DEFINE([NLIST_STRUCT], [1], [nlist stuff]) + AC_CACHE_CHECK( + [for n_un in struct nlist], + [ntp_cv_struct_nlist_n_un], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + ]], + [[ + struct nlist n; + n.n_un.n_name = 0; + ]] + )] + [ntp_cv_struct_nlist_n_un=yes], + [ntp_cv_struct_nlist_n_un=no] + )] + ) + case "$ntp_cv_struct_nlist_n_un" in + yes) + AC_DEFINE([NLIST_NAME_UNION], [1], + [does struct nlist use a name union?]) + esac + esac + AC_SUBST([LDADD_NLIST]) + LDADD_NLIST="$LIBS" + LIBS="$saved_LIBS" + AS_UNSET([saved_LIBS]) +esac + +AC_CHECK_HEADERS([sys/proc.h], [], [], [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_TIME_H + # include + #endif ]) -if test "$ac_cv_have_prototypes" = yes; then - AC_DEFINE(HAVE_PROTOTYPES, 1, [Are function prototypes OK?]) -fi -# -# end block -# -AC_C_CONST -AC_C_BIGENDIAN -AC_TYPE_SIGNAL -AC_TYPE_OFF_T -AC_TYPE_SIZE_T -AC_CHECK_TYPE(time_t, long) -AC_CHECK_SIZEOF(time_t) -AC_CHECK_TYPES(uintptr_t) - -AH_VERBATIM([TYPEDEF_UINTPTR_T], -[/* Provide a typedef for uintptr_t? */ -#ifndef HAVE_UINTPTR_T -typedef unsigned int uintptr_t; -#define HAVE_UINTPTR_T 1 -#endif]) - -AC_STRUCT_TM - -AC_CACHE_CHECK([for u_int8_t], ac_cv_type_u_int8_t, -[AC_TRY_COMPILE([#include ], - [u_int8_t len = 42; return 0;], - ac_cv_type_u_int8_t=yes, - ac_cv_type_u_int8_t=no) +AC_CHECK_HEADERS([sys/resource.h], [], [], [ + #ifdef HAVE_SYS_TIME_H + # include + #endif ]) -if test $ac_cv_type_u_int8_t = yes; then - AC_DEFINE(HAVE_TYPE_U_INT8_T, 1, [Does u_int8_t exist?]) -fi -AC_CACHE_CHECK([for u_int64_t], ac_cv_type_u_int64_t, -[AC_TRY_COMPILE([#include ], - [u_int64_t len = 42; return 0;], - ac_cv_type_u_int64_t=yes, - ac_cv_type_u_int64_t=no) +AC_CHECK_HEADERS([sys/shm.h], [], [], [ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_IPC_H + # include + #endif ]) -if test $ac_cv_type_u_int64_t = yes; then - AC_DEFINE(HAVE_TYPE_U_INT64_T, 1, [Does u_int64_t exist?]) -fi -# -# Look for in_port_t. -# -AC_MSG_CHECKING([for in_port_t]) -AC_TRY_COMPILE([ -#include -#include ], -[in_port_t port = 25; return (0);], - [AC_MSG_RESULT(yes) - ], - [AC_MSG_RESULT(no) - AC_DEFINE(ISC_PLATFORM_NEEDPORTT, 1, [Do we need our own in_port_t?]) - ]) - -AC_CACHE_CHECK([for a fallback value for HZ], ac_cv_var_default_hz, -[ac_cv_var_default_hz=100 -case "$host" in - alpha*-dec-osf4*|alpha*-dec-osf5*) - ac_cv_var_default_hz=1024 - ;; - mips-dec-ultrix4*) - ac_cv_var_default_hz=256 - ;; -esac]) -AC_DEFINE_UNQUOTED(DEFAULT_HZ, $ac_cv_var_default_hz, [What is the fallback value for HZ?]) +AC_CHECK_HEADERS([sys/timex.h], [], [], [ + #ifdef HAVE_SYS_TIME_H + # include + #endif +]) -AC_CACHE_CHECK([if we need to override the system's value for HZ], ac_cv_var_override_hz, -[ac_cv_var_override_hz=no -case "$host" in - alpha*-dec-osf4*|alpha*-dec-osf5*) - ac_cv_var_override_hz=yes - ;; - mips-dec-ultrix4*) - ac_cv_var_override_hz=yes - ;; - *-*-freebsd*) - ac_cv_var_override_hz=yes - ;; - *-*-sunos4*) - ac_cv_var_override_hz=yes - ;; -esac]) -case "$ac_cv_var_override_hz" in +AC_TYPE_SIGNAL +AC_TYPE_OFF_T +AC_STRUCT_TM dnl defines TM_IN_SYS_TIME used by refclock_parse.c + +AC_CACHE_CHECK( + [for a fallback value for HZ], + [ntp_cv_default_hz], + [ + ntp_cv_default_hz=100 + case "$host" in + alpha*-dec-osf4*|alpha*-dec-osf5*) + ntp_cv_default_hz=1024 + ;; + mips-dec-ultrix4*) + ntp_cv_default_hz=256 + ;; + esac + ] +) +AC_DEFINE_UNQUOTED([DEFAULT_HZ], [$ntp_cv_default_hz], + [What is the fallback value for HZ?]) + +AC_CACHE_CHECK( + [if we need to override the system's value for HZ], + [ntp_cv_override_hz], + [ + ntp_cv_override_hz=no + case "$host" in + alpha*-dec-osf4*|alpha*-dec-osf5*) + ntp_cv_override_hz=yes + ;; + mips-dec-ultrix4*) + ntp_cv_override_hz=yes + ;; + *-*-freebsd*) + ntp_cv_override_hz=yes + ;; + *-*-sunos4*) + ntp_cv_override_hz=yes + ;; + *-*-kfreebsd*) + ntp_cv_override_hz=yes + ;; + esac + ] +) +case "$ntp_cv_override_hz" in yes) - AC_DEFINE(OVERRIDE_HZ, 1, [Do we need to override the system's idea of HZ?]) - ;; + AC_DEFINE([OVERRIDE_HZ], [1], + [Do we need to override the system's idea of HZ?]) esac dnl AC_CACHE_CHECK(ut_host in struct utmp, ac_cv_func_ut_host_in_utmp, @@ -794,1523 +597,1154 @@ dnl #endif dnl ], su_cv_have_boot_time=yes, su_cv_have_boot_time=no)]) dnl AC_MSG_RESULT($su_cv_have_boot_time) -AC_CACHE_CHECK([for struct rt_msghdr], ac_cv_struct_rt_msghdr, -[AC_TRY_COMPILE([ -#include -#include -#include -#include ], -[struct rt_msghdr p;], - ac_cv_struct_rt_msghdr=yes, - ac_cv_struct_rt_msghdr=no) -]) - -if test $ac_cv_struct_rt_msghdr = yes; then - AC_DEFINE(HAS_ROUTING_SOCKET, 1, [Do we have a routing socket (struct rt_msghdr)?]) -fi - AC_CACHE_CHECK( - [struct sigaction for sa_sigaction], - ac_cv_struct_sigaction_has_sa_sigaction, - [ - AC_TRY_COMPILE( - [#include ], - [struct sigaction act; act.sa_sigaction = 0;], - ac_cv_struct_sigaction_has_sa_sigaction=yes, - ac_cv_struct_sigaction_has_sa_sigaction=no - ) - ] + [for struct rt_msghdr], + [ntp_cv_struct_rt_msghdr], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + #include + #include + #include + ]], + [[ + struct rt_msghdr p; + ]] + )], + [ntp_cv_struct_rt_msghdr=yes], + [ntp_cv_struct_rt_msghdr=no] + )] ) -if test $ac_cv_struct_sigaction_has_sa_sigaction = yes; then - AC_DEFINE(HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION, 1, [Obvious...]) -fi -AC_CACHE_CHECK([for struct ppsclockev], ac_cv_struct_ppsclockev, -[AC_TRY_COMPILE([ -#include -#ifdef HAVE_SYS_TERMIOS_H -# include -#endif -#ifdef HAVE_SYS_TIME_H -# include -#endif -#ifdef HAVE_SYS_PPSCLOCK_H -# include -#endif],[ -extern struct ppsclockev *pce; -return pce->serial;], - ac_cv_struct_ppsclockev=yes, - ac_cv_struct_ppsclockev=no) -]) -if test $ac_cv_struct_ppsclockev = yes; then - AC_DEFINE(HAVE_STRUCT_PPSCLOCKEV, 1, [Does a system header define struct ppsclockev?]) -fi - -AC_CACHE_CHECK([struct sockaddr for sa_len], ac_cv_struct_sockaddr_has_sa_len, -[AC_TRY_COMPILE([ -#include -#include ],[ -extern struct sockaddr *ps; -return ps->sa_len;], - ac_cv_struct_sockaddr_has_sa_len=yes, - ac_cv_struct_sockaddr_has_sa_len=no) -]) -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then - AC_DEFINE(HAVE_SA_LEN_IN_STRUCT_SOCKADDR, 1, [Should be obvious...]) -fi - -AC_CACHE_CHECK([for struct sockaddr_storage], ac_cv_struct_sockaddr_storage, -[AC_TRY_COMPILE([ -#include -#include -#include -],[ -struct sockaddr_storage n;], - ac_cv_struct_sockaddr_storage=yes, - ac_cv_struct_sockaddr_storage=no) -]) -if test $ac_cv_struct_sockaddr_storage = yes; then - AC_DEFINE(HAVE_STRUCT_SOCKADDR_STORAGE, 1, [Does a system header define struct sockaddr_storage?]) -fi +AC_CACHE_CHECK( + [for struct rtattr], + [ntp_cv_rtattr], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + #include + #include + ]], + [[ + struct rtattr p; + ]] + )], + [ntp_cv_rtattr=yes], + [ntp_cv_rtattr=no] + )] +) -AC_CACHE_CHECK([for ss_family field in struct sockaddr_storage], - ac_cv_have_ss_family_in_struct_ss, [ - AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.ss_family = 1; ], - [ ac_cv_have_ss_family_in_struct_ss="yes" ], - [ ac_cv_have_ss_family_in_struct_ss="no" ], - ) -]) -if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then - AC_DEFINE(HAVE_SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have ss_family?]) -else - # Hack around a problem... - # HMS: This is $host because we need the -D if we are building *for* it. - # HMS: 061029: Now that we separate the ss_* checks this is causing - # a problem - disable it until we get to the bottom of it. - case "$host" in - XXX*-*-hpux11.11) CPPFLAGS="$CPPFLAGS -D_NETINET_IN6_H" - ;; +case "$ntp_cv_struct_rt_msghdr$ntp_cv_rtattr" in + *yes*) + AC_DEFINE([HAS_ROUTING_SOCKET], [1], + [Do we have a routing socket (rt_msghdr or rtattr)?]) + case "$ntp_cv_rtattr" in + yes) + AC_DEFINE([HAVE_RTNETLINK], [1], + [Do we have Linux routing socket?]) esac -fi - -AC_CACHE_CHECK([for __ss_family field in struct sockaddr_storage], - ac_cv_have___ss_family_in_struct_ss, [ - AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.__ss_family = 1; ], - [ ac_cv_have___ss_family_in_struct_ss="yes" ], - [ ac_cv_have___ss_family_in_struct_ss="no" ] - ) -]) -if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then - AC_DEFINE(HAVE___SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have __ss_family?]) -fi - -AH_VERBATIM([X_HAVE_SS_FAMILY_IN_SS], -[/* Handle ss_family */ -#if !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE___SS_FAMILY_IN_SS) -# define ss_family __ss_family -#endif /* !defined(HAVE_SS_FAMILY_IN_SS) && defined(HAVE_SA_FAMILY_IN_SS) */]) - -AC_CACHE_CHECK([for ss_len field in struct sockaddr_storage], - ac_cv_have_ss_len_in_struct_ss, [ - AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.ss_len = 1; ], - [ ac_cv_have_ss_len_in_struct_ss="yes" ], - [ ac_cv_have_ss_len_in_struct_ss="no" ], - ) -]) -if test "x$ac_cv_have_ss_len_in_struct_ss" = "xyes" ; then - AC_DEFINE(HAVE_SS_LEN_IN_SS, 1, [Does struct sockaddr_storage have ss_len?]) -fi +esac -AC_CACHE_CHECK([for __ss_len field in struct sockaddr_storage], - ac_cv_have___ss_len_in_struct_ss, [ - AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.__ss_len = 1; ], - [ ac_cv_have___ss_len_in_struct_ss="yes" ], - [ ac_cv_have___ss_len_in_struct_ss="no" ] - ) -]) -if test "x$ac_cv_have___ss_len_in_struct_ss" = "xyes" ; then - AC_DEFINE(HAVE___SS_LEN_IN_SS, 1, [Does struct sockaddr_storage have __ss_len?]) -fi +AC_CACHE_CHECK( + [struct sigaction for sa_sigaction], + [ntp_cv_struct_sigaction_has_sa_sigaction], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + ]], + [[ + struct sigaction act; + act.sa_sigaction = 0; + ]] + )], + [ntp_cv_struct_sigaction_has_sa_sigaction=yes], + [ntp_cv_struct_sigaction_has_sa_sigaction=no] + )] +) +case "$ntp_cv_struct_sigaction_has_sa_sigaction" in + yes) + AC_DEFINE([HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION], [1], [Obvious]) +esac -AH_VERBATIM([X_HAVE_SS_LEN_IN_SS], -[/* Handle ss_len */ -#if !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE___SS_LEN_IN_SS) -# define ss_len __ss_len -#endif /* !defined(HAVE_SS_LEN_IN_SS) && defined(HAVE_SA_LEN_IN_SS) */]) +AC_CACHE_CHECK( + [for struct ppsclockev], + [ntp_cv_struct_ppsclockev], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_TERMIOS_H + # include + #endif + #ifdef HAVE_SYS_TIME_H + # include + #endif + #ifdef HAVE_SYS_PPSCLOCK_H + # include + #endif + ]], + [[ + extern struct ppsclockev *pce; + return pce->serial; + ]] + )], + [ntp_cv_struct_ppsclockev=yes], + [ntp_cv_struct_ppsclockev=no] + )] +) +case "$ntp_cv_struct_ppsclockev" in + yes) + AC_DEFINE([HAVE_STRUCT_PPSCLOCKEV], [1], + [Does a system header define struct ppsclockev?]) +esac case "$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in *yes*) - AC_CACHE_CHECK([for struct snd_size], ac_cv_struct_snd_size, -[AC_TRY_COMPILE([ -#ifdef HAVE_MACHINE_SOUNDCARD_H -# include -#endif -#ifdef HAVE_SYS_SOUNDCARD_H -# include -#endif],[ -extern struct snd_size *ss; -return ss->rec_size;], - ac_cv_struct_snd_size=yes, - ac_cv_struct_snd_size=no) -]) - case "$ac_cv_struct_snd_size" in - yes) AC_DEFINE(HAVE_STRUCT_SND_SIZE, 1,[Do we have struct snd_size?]) ;; + AC_CACHE_CHECK( + [for struct snd_size], + [ntp_cv_struct_snd_size], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_MACHINE_SOUNDCARD_H + # include + #endif + #ifdef HAVE_SYS_SOUNDCARD_H + # include + #endif + ]], + [[ + extern struct snd_size *ss; + return ss->rec_size; + ]] + )], + [ntp_cv_struct_snd_size=yes], + [ntp_cv_struct_snd_size=no] + )] + ) + case "$ntp_cv_struct_snd_size" in + yes) + AC_DEFINE([HAVE_STRUCT_SND_SIZE], [1], + [Do we have struct snd_size?]) esac - ;; esac -AC_CACHE_CHECK([struct clockinfo for hz], ac_cv_struct_clockinfo_has_hz, -[AC_TRY_COMPILE([ -#include ],[ -extern struct clockinfo *pc; -return pc->hz;], - ac_cv_struct_clockinfo_has_hz=yes, - ac_cv_struct_clockinfo_has_hz=no) -]) -if test $ac_cv_struct_clockinfo_has_hz = yes; then - AC_DEFINE(HAVE_HZ_IN_STRUCT_CLOCKINFO, 1, [Obvious...]) -fi - -AC_CACHE_CHECK([struct clockinfo for tickadj], ac_cv_struct_clockinfo_has_tickadj, -[AC_TRY_COMPILE([ -#include ],[ -extern struct clockinfo *pc; -return pc->tickadj;], - ac_cv_struct_clockinfo_has_tickadj=yes, - ac_cv_struct_clockinfo_has_tickadj=no) -]) -if test $ac_cv_struct_clockinfo_has_tickadj = yes; then - AC_DEFINE(HAVE_TICKADJ_IN_STRUCT_CLOCKINFO, 1, [Obvious...]) -fi - -AC_CACHE_CHECK([for struct timespec], ac_cv_struct_timespec, -[AC_TRY_COMPILE([ -#include -/* Under SunOS, timespec is in sys/timepps.h, which needs errno.h and FRAC */ -#ifdef HAVE_ERRNO_H -# include -#endif -#ifdef HAVE_SYS_TIMEPPS_H -# define FRAC 4294967296 -# include -#endif], -[struct timespec n;], -ac_cv_struct_timespec=yes, ac_cv_struct_timespec=no)]) -if test $ac_cv_struct_timespec = yes; then - AC_DEFINE(HAVE_STRUCT_TIMESPEC, 1, [Do we have struct timespec?]) -fi +AC_CACHE_CHECK( + [struct clockinfo for hz], + [ntp_cv_struct_clockinfo_has_hz], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + ]], + [[ + extern struct clockinfo *pc; + return pc->hz; + ]] + )], + [ntp_cv_struct_clockinfo_has_hz=yes], + [ntp_cv_struct_clockinfo_has_hz=no] + )] +) +case "$ntp_cv_struct_clockinfo_has_hz" in + yes) + AC_DEFINE([HAVE_HZ_IN_STRUCT_CLOCKINFO], [1], [Obvious]) +esac -AC_CACHE_CHECK([for struct ntptimeval], ac_cv_struct_ntptimeval, -[AC_TRY_COMPILE([ -#include -#include ], -[struct ntptimeval n;], -ac_cv_struct_ntptimeval=yes, ac_cv_struct_ntptimeval=no)]) -if test $ac_cv_struct_ntptimeval = yes; then - AC_DEFINE(HAVE_STRUCT_NTPTIMEVAL, 1, [Do we have struct ntptimeval?]) -fi +AC_CACHE_CHECK( + [struct clockinfo for tickadj], + [ntp_cv_struct_clockinfo_has_hz], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + ]], + [[ + extern struct clockinfo *pc; + return pc->tickadj; + ]] + )], + [ntp_cv_struct_clockinfo_has_hz=yes], + [ntp_cv_struct_clockinfo_has_hz=no] + )] +) +case "$ntp_cv_struct_clockinfo_has_hz" in + yes) + AC_DEFINE([HAVE_TICKADJ_IN_STRUCT_CLOCKINFO], [1], [Obvious]) +esac -AC_CHECK_MEMBERS([struct ntptimeval.time.tv_nsec], , , -[#ifdef HAVE_SYS_TIME_H -#include -#else -# ifdef HAVE_TIME_H -# include -# endif -#endif -#ifdef HAVE_SYS_TIMEX_H -#include -#else -# ifdef HAVE_TIMEX_H -# include -# endif -#endif]) - -AC_C_INLINE - -case "$ac_cv_c_inline" in - '') - ;; - *) - AC_DEFINE(HAVE_INLINE,1,[inline keyword or macro available]) - AC_SUBST(HAVE_INLINE) +case "$ntp_cv_struct_ntptimeval" in + yes) + AC_CHECK_MEMBERS( + [struct ntptimeval.time.tv_nsec], + [], + [], + [ + #ifdef HAVE_SYS_TIME_H + # include + #else + # ifdef HAVE_TIME_H + # include + # endif + #endif + #ifdef HAVE_SYS_TIMEX_H + # include + #else + # ifdef HAVE_TIMEX_H + # include + # endif + #endif + ] + ) esac -AC_C_CHAR_UNSIGNED dnl CROSS_COMPILE? -AC_CHECK_SIZEOF(signed char) -AC_CHECK_SIZEOF(int) -AC_CHECK_SIZEOF(long) +#### -AC_CHECK_TYPES([s_char]) -case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in - *yes) - # We have a typedef for s_char. Might as well believe it... - ;; - no0no) - # We have signed chars, can't say 'signed char', no s_char typedef. - AC_DEFINE(NEED_S_CHAR_TYPEDEF, 1, [Do we need an s_char typedef?]) - ;; - no1no) - # We have signed chars, can say 'signed char', no s_char typedef. - AC_DEFINE(NEED_S_CHAR_TYPEDEF) - ;; - yes0no) - # We have unsigned chars, can't say 'signed char', no s_char typedef. - AC_MSG_ERROR(No way to specify a signed character!) - ;; - yes1no) - # We have unsigned chars, can say 'signed char', no s_char typedef. - AC_DEFINE(NEED_S_CHAR_TYPEDEF) - ;; -esac -AC_TYPE_UID_T +AC_CHECK_FUNCS([arc4random_buf]) -case "$host" in - *-*-aix[[456]]*) - # (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub - # (returning ENOSYS). I didn't check 4.2. If, in the future, - # IBM pulls its thumbs out long enough to implement clock_settime, - # this conditional will need to change. Maybe use AC_TRY_RUN - # instead to try to set the time to itself and check errno. - ;; - *) AC_CHECK_FUNCS(clock_gettime clock_settime) - ;; -esac -AC_CHECK_FUNCS(daemon) -AC_CHECK_FUNCS(finite, , - [AC_CHECK_FUNCS(isfinite, , - [AC_MSG_CHECKING([for isfinite with ]) - _libs=$LIBS - LIBS="$LIBS -lm" - AC_TRY_LINK([#include ], [float f = 0.0; isfinite(f)], - [AC_MSG_RESULT(yes) - AC_DEFINE(HAVE_ISFINITE)], - AC_MSG_RESULT(no)) - LIBS=$_libs])]) -AC_CHECK_FUNCS(getbootfile getclock getdtablesize) - -AC_ARG_ENABLE(getifaddrs, - AC_HELP_STRING([--enable-getifaddrs], - [s Enable the use of getifaddrs() [[yes|no|glibc]]. -glibc: Use getifaddrs() in glibc if you know it supports IPv6.]), - want_getifaddrs="$enableval", want_getifaddrs="yes") - -case $want_getifaddrs in -yes|glibc) -# -# Do we have getifaddrs() ? -# -case $host in -*-*linux*) - # Some recent versions of glibc support getifaddrs() which does not - # provide AF_INET6 addresses while the function provided by the USAGI - # project handles the AF_INET6 case correctly. We need to avoid - # using the former but prefer the latter unless overridden by - # --enable-getifaddrs=glibc. - if test $want_getifaddrs = glibc - then - AC_CHECK_FUNCS(getifaddrs) - else - save_LIBS="$LIBS" - LIBS="-L/usr/local/v6/lib $LIBS" - AC_CHECK_LIB(inet6, getifaddrs, - LIBS="$LIBS -linet6" - AC_DEFINE(HAVE_GETIFADDRS), - LIBS=${save_LIBS}) - fi - ;; -*) - AC_CHECK_FUNCS(getifaddrs) - ;; -esac -;; -no) -;; -esac +#### -AC_MSG_CHECKING([type of socklen arg for getsockname()]) -AC_CACHE_VAL(ac_cv_func_getsockname_arg2,dnl -[AC_CACHE_VAL(ac_cv_func_getsockname_socklen_type,dnl - [for ac_cv_func_getsockname_arg2 in 'struct sockaddr *' 'void *'; do - for ac_cv_func_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do - AC_TRY_COMPILE(dnl -[#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -extern getsockname (int, $ac_cv_func_getsockname_arg2, $ac_cv_func_getsockname_socklen_type *);],,dnl - [ac_not_found=no ; break 2], ac_not_found=yes) - done - done - ])dnl AC_CACHE_VAL -])dnl AC_CACHE_VAL -if test "$ac_not_found" = yes; then - ac_cv_func_getsockname_socklen_type='socklen_t' -fi -AC_MSG_RESULT([$ac_cv_func_getsockname_socklen_type]) -AC_DEFINE_UNQUOTED([GETSOCKNAME_SOCKLEN_TYPE], - $ac_cv_func_getsockname_socklen_type, - [What is getsockname()'s socklen type?]) +saved_LIBS="$LIBS" +LIBS="$LIBS $LDADD_LIBNTP" +AC_CHECK_FUNCS([daemon]) +# XXX if we keep everything in LIBS and also keep separate lists, this simplifies. +LIBS="$saved_LIBS" +AS_UNSET([saved_LIBS]) -AC_CHECK_FUNCS(getrusage) -AC_CHECK_FUNC(gettimeofday, ,[ -case "$host" in - *-*-mpeix*) ac_cv_func_gettimeofday=yes - ;; -esac]) -case "$host" in - *-pc-cygwin*) - ;; - *) AC_CHECK_FUNCS(getuid) - ;; -esac -AC_CHECK_FUNCS(hstrerror) +AC_CHECK_FUNCS( + [finite], + [], + [AC_CHECK_FUNCS( + [isfinite], + [], + [ + AC_MSG_CHECKING([for isfinite with ]) + _libs=$LIBS + # XXX + LIBS="$LIBS -lm" + AC_LINK_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + ]], + [[ + float f = 0.0; + isfinite(f); + ]] + )], + [ans=yes], + [ans=no] + ) + LIBS=$_libs + AC_MSG_RESULT([$ans]) + case "$ans" in + yes) + AC_DEFINE([HAVE_ISFINITE], [1]) + esac + ] + )] +) -# -# Check for if_nametoindex() for IPv6 scoped addresses support -# -AC_CHECK_FUNC(if_nametoindex, ac_cv_have_if_nametoindex=yes, - ac_cv_have_if_nametoindex=no) -case $ac_cv_have_if_nametoindex in - no) - case "$host" in - *-hp-hpux*) - AC_CHECK_LIB(ipv6, if_nametoindex, - ac_cv_have_if_nametoindex=yes - LIBS="-lipv6 $LIBS",) - ;; - esac -esac -case $ac_cv_have_if_nametoindex in +AC_CHECK_FUNCS([fnmatch getbootfile getuid getrusage nanosleep strsignal]) + +# kvm_open() is only used by tickadj. Also see above. +case "$ac_cv_header_kvm_h" in yes) - AC_DEFINE(ISC_PLATFORM_HAVEIFNAMETOINDEX, 1, [ISC: do we have if_nametoindex()?]) - ;; + AC_CHECK_FUNCS([kvm_open]) + ;; esac -AC_CHECK_FUNC(inet_ntop, [], [AC_DEFINE(ISC_PLATFORM_NEEDNTOP, 1, [ISC: provide inet_ntop()])]) -AC_CHECK_FUNC(inet_pton, [], [AC_DEFINE(ISC_PLATFORM_NEEDPTON, 1, [ISC: provide inet_pton()])]) -AC_CHECK_FUNC(inet_aton, [], [AC_DEFINE(ISC_PLATFORM_NEEDATON, 1, [ISC: provide inet_aton()])]) -AC_CHECK_FUNCS(K_open kvm_open memcpy memmove memset) case "$host" in *-*-sco3.2v5.0.*) - # Just stubs. Idiots. + # Just stubs. Sigh. ;; - *) AC_CHECK_FUNCS(mkstemp) + *) AC_CHECK_FUNCS([mkstemp]) ;; esac -AC_CHECK_FUNCS(mktime) +AC_CHECK_FUNCS([mktime]) case "$host" in - *-*-aix[[456]]*) - # Just a stub. Idiots. + *-*-aix[[4-9]]*) + # XXX only verified thru AIX6. + # Just a stub. Sigh. ;; *-*-irix[[45]]*) - # Just a stub in "old" Irix. Idiots. - ;; - *-*-*linux*) - # there, but more trouble than it is worth for now (resolver problems) + # Just a stub in "old" Irix. Sigh. ;; +# In the belief that the fix for bug 1223 fixes mlockall() under linux... +# *-*-*linux*) +# # there, but more trouble than it is worth for now (resolver problems) +# ;; *-*-qnx*) - # Apparently there but not working in QNX. Idiots? + # Apparently there but not working in QNX. Sigh? ;; *-*-sco3.2v5.0.*) - # Just a stub. Idiots. + # Just a stub. Sigh. ;; alpha*-dec-osf4*|alpha*-dec-osf5*) # mlockall is there, as a #define calling memlk via # Not easy to test for - cheat. - AC_CHECK_FUNCS(memlk, [ac_cv_func_mlockall='yes']) - AC_CHECK_FUNCS(mlockall) - ;; - *) AC_CHECK_FUNCS(mlockall) + AC_CHECK_FUNCS([memlk], [ac_cv_func_mlockall=yes]) + AC_CHECK_FUNCS([mlockall]) ;; -esac -AC_CHECK_FUNCS(nice nlist) -case "$host" in - *-*-solaris2.6) - # Broken... - ;; - *) AC_CHECK_FUNCS(ntp_adjtime ntp_gettime) + *) AC_CHECK_FUNCS([mlockall]) ;; esac -AC_CHECK_FUNCS(plock pututline pututxline readlink recvmsg rtprio) +AC_CHECK_FUNCS([nice plock pututline pututxline readlink rtprio]) case "$host" in - *-*-aix[[456]]*) - # Just a stub in AIX 4. Idiots. + *-*-aix[[4-9]]*) + # XXX only verified thru AIX6. + # Just a stub in AIX 4. Sigh. ;; *-*-solaris2.5*) - # Just stubs in solaris2.5. Idiots. + # Just stubs in solaris2.5. Sigh. ;; - *) AC_CHECK_FUNCS(sched_setscheduler) + *) AC_CHECK_FUNCS([sched_setscheduler]) ;; esac -AC_CHECK_FUNCS(setlinebuf setpgid setpriority setsid) -AC_CHECK_FUNCS(setrlimit) -AC_CHECK_FUNCS(settimeofday, ,[ -case "$host" in - *-*-mpeix*) ac_cv_func_settimeofday=yes - ;; -esac]) -AC_CHECK_FUNCS(setvbuf sigaction) -AC_CHECK_FUNCS(sigvec sigset sigsuspend stime strchr sysconf sysctl) -AC_CHECK_FUNCS(snprintf strdup strerror strstr) -AC_CHECK_FUNCS(timegm) +AC_CHECK_FUNCS([setlinebuf setpgid setpriority setsid setvbuf]) +AC_CHECK_FUNCS([strdup strerror setrlimit strchr]) case "$host" in - *-*-aix[[456]]*) - # Just stubs. Idiots. + *-*-aix[[4-9]]*) + # XXX only verified thru AIX6. + # Just stubs. Sigh. ;; *-*-netbsd1*) - # Just stubs. Idiots. + # Just stubs. Sigh. ;; *-*-netbsdelf1*) - # Just stubs. Idiots. + # Just stubs. Sigh. ;; *-*-openbsd*) - # Just stubs. Idiots. + # Just stubs. Sigh. ;; - *) AC_CHECK_FUNCS(timer_create timer_settime) + *) + AC_CHECK_FUNCS([timer_create]) ;; esac -case "$host" in - *-pc-cygwin*) - # I have no idea... + +NTP_RLIMIT_ITEMS + +# some OSes prefer _exit() in forked children to exit() +AC_CHECK_FUNCS([_exit]) +ntp_worker_child_exit=exit +case "$ac_cv_func__exit::$host_os" in + yes::netbsd*) + ntp_worker_child_exit=_exit ;; - *) AC_CHECK_FUNCS(umask) + yes::openbsd*) + ntp_worker_child_exit=_exit ;; esac -AC_CHECK_FUNCS(uname updwtmp updwtmpx vsnprintf vsprintf) +AC_DEFINE_UNQUOTED([WORKER_CHILD_EXIT], [$ntp_worker_child_exit], + [routine worker child proc uses to exit.]) + +AC_CHECK_FUNCS([umask uname updwtmp updwtmpx]) ### # http://bugs.ntp.org/737 case "$ac_cv_func_recvmsg" in yes) - AC_MSG_CHECKING([if we need extra help to define struct iovec]) - AC_CACHE_VAL(ac_cv_struct_iovec_help,dnl - [for ac_cv_struct_iovec_help in '0' '1'; do - AC_TRY_COMPILE(dnl -[#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#if $ac_cv_struct_iovec_help -#include -#endif - -void foo(); -void foo() { - ssize_t x; - int s = 0; - struct iovec iov; - struct msghdr mh; - int flags = 0; - - mh.msg_iov = &iov; - x = recvmsg(s, &mh, flags); -}],,dnl - [ac_worked=yes ; break 1], ac_worked=no) - done -])dnl AC_CACHE_VAL - case "$ac_worked$ac_cv_struct_iovec_help" in - yes1) - AC_DEFINE(HAVE_SYS_UIO_H, 1, [Use sys/uio.h for struct iovec help]) - ans=yes - ;; - *) ans=no + AC_CACHE_CHECK( + [if we need extra help to define struct iovec], + [ntp_cv_struct_iovec_help], + [ + compiled=no + for ntp_cv_struct_iovec_help in '0' '1'; do + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #if $ntp_cv_struct_iovec_help + # include + #endif + ]], + [[ + void foo(void) { + ssize_t x; + int s = 0; + struct iovec iov; + struct msghdr mh; + int flags = 0; + + mh.msg_iov = &iov; + x = recvmsg(s, &mh, flags); + } + ]] + )], + [compiled=yes ; break 1], + [] + ) + done + case "$compiled" in + no) + ntp_cv_struct_iovec_help=0 + esac + AS_UNSET([compiled]) + ] + ) + case "$ntp_cv_struct_iovec_help" in + 1) + AC_DEFINE([HAVE_SYS_UIO_H], [1], + [Use sys/uio.h for struct iovec help]) esac - AC_MSG_RESULT([$ans]) - ;; -esac - -case "$host" in - *-*-sunos4*) - AC_DEFINE(SPRINTF_CHAR, 1, [*s*printf() functions are char*]) - ;; esac -AC_CACHE_CHECK([number of arguments to gettimeofday()], ac_cv_func_Xettimeofday_nargs, -[AC_TRY_COMPILE([#include ],[ -gettimeofday((struct timeval*)0,(struct timezone*)0); -settimeofday((struct timeval*)0,(struct timezone*)0); -], - ac_cv_func_Xettimeofday_nargs=2, ac_cv_func_Xettimeofday_nargs=1) -]) -if test $ac_cv_func_Xettimeofday_nargs = 1; then - AC_DEFINE(SYSV_TIMEOFDAY, 1, [Does Xettimeofday take 1 arg?]) -fi - -AC_CACHE_CHECK([number of arguments taken by setpgrp()], ac_cv_func_setpgrp_nargs, -[AC_TRY_COMPILE([ -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif -],[setpgrp(0,0);], - ac_cv_func_setpgrp_nargs=2, ac_cv_func_setpgrp_nargs=0) -]) -if test $ac_cv_func_setpgrp_nargs = 0; then - AC_DEFINE(HAVE_SETPGRP_0, 1, [define if setpgrp takes 0 arguments]) -fi - -save_CFLAGS=$CFLAGS -CFLAGS="$CFLAGS -I$srcdir/include" - -AC_CACHE_CHECK([argument pointer type of qsort()'s compare function and base], -ac_cv_func_qsort_argtype, -[AC_TRY_COMPILE([ -#include "l_stdlib.h" - -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif - -extern void *base; -extern sortfunc P((const void *, const void *)); -int sortfunc(a, b) - const void *a; - const void *b; { return 0; } -],[ -qsort(base, 2, sizeof(char *), sortfunc); -], - ac_cv_func_qsort_argtype=void, ac_cv_func_qsort_argtype=char) -]) -case "$ac_cv_func_qsort_argtype" in - void) - AC_DEFINE(QSORT_USES_VOID_P, 1, [Does qsort expect to work on "void *" stuff?]) - ;; +AC_CACHE_CHECK( + [number of arguments taken by setpgrp()], + [ntp_cv_func_setpgrp_nargs], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_UNISTD_H + # include + #endif + ]], + [[ + setpgrp(0, 0); + ]] + )], + [ntp_cv_func_setpgrp_nargs=2], + [ntp_cv_func_setpgrp_nargs=0] + )] +) +case "$ntp_cv_func_setpgrp_nargs" in + 0) + AC_DEFINE([HAVE_SETPGRP_0], [1], + [define if setpgrp takes 0 arguments]) esac -CFLAGS=$save_CFLAGS - -AC_CACHE_CHECK([if we need to declare 'errno'], ac_cv_decl_errno, -[AC_TRY_COMPILE([#ifdef HAVE_ERRNO_H -#include -#endif], - [errno = 0;], - ac_cv_decl_errno=no, ac_cv_decl_errno=yes)]) -case "$ac_cv_decl_errno" in - yes) AC_DEFINE(DECL_ERRNO, 1, [Declare errno?]) ;; +AC_CACHE_CHECK( + [if we need to declare 'errno'], + [ntp_cv_decl_errno], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_ERRNO_H + # include + #endif + ]], + [[ + errno = 0; + ]] + )], + [ntp_cv_decl_errno=no], + [ntp_cv_decl_errno=yes] + )] +) +case "$ntp_cv_decl_errno" in + yes) + AC_DEFINE([DECL_ERRNO], [1], [Declare errno?]) esac -dnl FIXME: from ntpd/ntp_intres.c, but there's no info which header produces -dnl the clash. isn't currently used. -dnl dnl (prr) aix 4.3 defines h_errno as (*(int *)h_errno_which()) for dnl MT purposes. This makes the line "extern int h_errno" choke dnl the compiler. Hopefully adding !defined(h_errno) fixes this dnl without breaking any other platforms. dnl -AC_CACHE_CHECK([if we may declare 'h_errno'], ac_cv_decl_h_errno, -[AC_TRY_COMPILE([#include -#ifdef HAVE_NETINET_IN_H -#include -#endif -#ifdef HAVE_ARPA_NAMESER_H -#include -#endif -#ifdef HAVE_NETDB_H -#include -#endif -#ifdef HAVE_RESOLV_H -#include -#endif], - [extern int h_errno;], - ac_cv_decl_h_errno=yes, ac_cv_decl_h_errno=no)]) -case "$ac_cv_decl_h_errno" in - yes) AC_DEFINE(DECL_H_ERRNO, 1, [Declare h_errno?]) ;; -esac - -dnl See if char *sys_errlist[] is OK. -AC_CACHE_CHECK([[if declaring 'char *sys_errlist[]' is ok]], ac_cv_decl_sys_errlist, -[AC_TRY_COMPILE([#include -#ifdef HAVE_ERRNO_H -#include -#endif], - [extern char *sys_errlist[]; -], - ac_cv_decl_sys_errlist=yes, ac_cv_decl_sys_errlist=no)]) -case "$ac_cv_decl_sys_errlist" in - yes) AC_DEFINE(CHAR_SYS_ERRLIST, 1, [Declare char *sys_errlist array]) ;; -esac - -AC_CACHE_CHECK([if declaring 'syscall()' is ok], ac_cv_decl_syscall, -[AC_TRY_COMPILE([ -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif -#ifdef HAVE_PROTOTYPES -#define P(x) x -#else -#define P(x) () -#endif -], - [extern int syscall P((int, ...));], - ac_cv_decl_syscall=yes, ac_cv_decl_syscall=no)]) -case "$ac_cv_decl_syscall" in - yes) AC_DEFINE(DECL_SYSCALL, 1, [Declare syscall()?]) ;; +AC_CACHE_CHECK( + [if we may declare 'h_errno'], + [ntp_cv_decl_h_errno], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif + #ifdef HAVE_NETDB_H + # include + #endif + #ifdef HAVE_RESOLV_H + # include + #endif + ]], + [[ + extern int h_errno; + ]] + )], + [ntp_cv_decl_h_errno=yes], + [ntp_cv_decl_h_errno=no] + )] +) +case "$ntp_cv_decl_h_errno" in + yes) + AC_DEFINE([DECL_H_ERRNO], [1], [Declare h_errno?]) +esac + +AC_CACHE_CHECK( + [if declaring 'syscall()' is ok], + [ntp_cv_decl_syscall], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_UNISTD_H + # include + #endif + ]], + [[ + extern int syscall (int, ...); + ]] + )] + [ntp_cv_decl_syscall=yes], + [ntp_cv_decl_syscall=no] + )] +) +case "$ntp_cv_decl_syscall" in + yes) + AC_DEFINE([DECL_SYSCALL], [1], [Declare syscall()?]) esac case "$host" in *-*-aix4.3.*) - AC_DEFINE(DECL_HSTRERROR_0, 1, [Declaration style]) # Needed for XLC under AIX 4.3.2 + AC_DEFINE([DECL_HSTRERROR_0], [1], [Declaration style]) # Needed for XLC under AIX 4.3.2 ;; *-*-mpeix*) - AC_DEFINE(DECL_ADJTIME_0, 1, [Declaration style]) - AC_DEFINE(DECL_INET_NTOA_0, 1, [Declaration style]) - AC_DEFINE(DECL_MKTEMP_0, 1, [Declaration style]) - AC_DEFINE(DECL_SELECT_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETITIMER_0, 1, [Declaration style]) - AC_DEFINE(DECL_SYSLOG_0, 1, [Declaration style]) - AC_DEFINE(DECL_TIMEOFDAY_0, 1, [Declaration style]) + AC_DEFINE([DECL_ADJTIME_0], [1], [Declaration style]) + AC_DEFINE([DECL_INET_NTOA_0], [1], [Declaration style]) + AC_DEFINE([DECL_MKTEMP_0], [1], [Declaration style]) + AC_DEFINE([DECL_SELECT_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETITIMER_0], [1], [Declaration style]) + AC_DEFINE([DECL_SYSLOG_0], [1], [Declaration style]) + AC_DEFINE([DECL_TIMEOFDAY_0], [1], [Declaration style]) ;; *-*-osf[[45]]*) - AC_DEFINE(DECL_PLOCK_0, 1, [Declaration style]) - AC_DEFINE(DECL_STIME_1, 1, [Declaration style]) + AC_DEFINE([DECL_PLOCK_0], [1], [Declaration style]) + AC_DEFINE([DECL_STIME_1], [1], [Declaration style]) ;; *-*-qnx*) - AC_DEFINE(DECL_ADJTIME_0, 1, [Declaration style]) + AC_DEFINE([DECL_ADJTIME_0], [1], [Declaration style]) ;; *-*-riscos4*) - AC_DEFINE(DECL_ADJTIME_0, 1, [Declaration style]) - AC_DEFINE(DECL_BZERO_0, 1, [Declaration style]) - AC_DEFINE(DECL_IOCTL_0, 1, [Declaration style]) - AC_DEFINE(DECL_IPC_0, 1, [Declaration style]) - AC_DEFINE(DECL_MEMMOVE_0, 1, [Declaration style]) - AC_DEFINE(DECL_MKTEMP_0, 1, [Declaration style]) - AC_DEFINE(DECL_RENAME_0, 1, [Declaration style]) - AC_DEFINE(DECL_SELECT_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETITIMER_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETPRIORITY_0, 1, [Declaration style]) - AC_DEFINE(DECL_STDIO_0, 1, [Declaration style]) - AC_DEFINE(DECL_STRTOL_0, 1, [Declaration style]) - AC_DEFINE(DECL_SYSLOG_0, 1, [Declaration style]) - AC_DEFINE(DECL_TIME_0, 1, [Declaration style]) - AC_DEFINE(DECL_TIMEOFDAY_0, 1, [Declaration style]) - AC_DEFINE(DECL_TOLOWER_0, 1, [Declaration style]) + AC_DEFINE([DECL_ADJTIME_0], [1], [Declaration style]) + AC_DEFINE([DECL_BZERO_0], [1], [Declaration style]) + AC_DEFINE([DECL_IOCTL_0], [1], [Declaration style]) + AC_DEFINE([DECL_IPC_0], [1], [Declaration style]) + AC_DEFINE([DECL_MEMMOVE_0], [1], [Declaration style]) + AC_DEFINE([DECL_MKTEMP_0], [1], [Declaration style]) + AC_DEFINE([DECL_RENAME_0], [1], [Declaration style]) + AC_DEFINE([DECL_SELECT_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETITIMER_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETPRIORITY_0], [1], [Declaration style]) + AC_DEFINE([DECL_STDIO_0], [1], [Declaration style]) + AC_DEFINE([DECL_STRTOL_0], [1], [Declaration style]) + AC_DEFINE([DECL_SYSLOG_0], [1], [Declaration style]) + AC_DEFINE([DECL_TIME_0], [1], [Declaration style]) + AC_DEFINE([DECL_TIMEOFDAY_0], [1], [Declaration style]) + AC_DEFINE([DECL_TOLOWER_0], [1], [Declaration style]) ;; *-*-solaris2*) - AC_DEFINE(DECL_MKSTEMP_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETPRIORITY_1, 1, [Declaration style]) + AC_DEFINE([DECL_MKSTEMP_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETPRIORITY_1], [1], [Declaration style]) case "$host" in *-*-solaris2.4) - AC_DEFINE(DECL_TIMEOFDAY_0, 1, [Declaration style]) + AC_DEFINE([DECL_TIMEOFDAY_0], [1], [Declaration style]) ;; esac ;; *-*-sunos4*) - AC_DEFINE(DECL_ADJTIME_0, 1, [Declaration style]) - AC_DEFINE(DECL_BCOPY_0, 1, [Declaration style]) - AC_DEFINE(DECL_BZERO_0, 1, [Declaration style]) - AC_DEFINE(DECL_IOCTL_0, 1, [Declaration style]) - AC_DEFINE(DECL_IPC_0, 1, [Declaration style]) - AC_DEFINE(DECL_MEMMOVE_0, 1, [Declaration style]) - AC_DEFINE(DECL_MKTEMP_0, 1, [Declaration style]) - AC_DEFINE(DECL_MKSTEMP_0, 1, [Declaration style]) - AC_DEFINE(DECL_RENAME_0, 1, [Declaration style]) - AC_DEFINE(DECL_SELECT_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETITIMER_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETPRIORITY_0, 1, [Declaration style]) - AC_DEFINE(DECL_SIGVEC_0, 1, [Declaration style]) + AC_DEFINE([DECL_ADJTIME_0], [1], [Declaration style]) + AC_DEFINE([DECL_BCOPY_0], [1], [Declaration style]) + AC_DEFINE([DECL_BZERO_0], [1], [Declaration style]) + AC_DEFINE([DECL_IOCTL_0], [1], [Declaration style]) + AC_DEFINE([DECL_IPC_0], [1], [Declaration style]) + AC_DEFINE([DECL_MEMMOVE_0], [1], [Declaration style]) + AC_DEFINE([DECL_MKTEMP_0], [1], [Declaration style]) + AC_DEFINE([DECL_MKSTEMP_0], [1], [Declaration style]) + AC_DEFINE([DECL_RENAME_0], [1], [Declaration style]) + AC_DEFINE([DECL_SELECT_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETITIMER_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETPRIORITY_0], [1], [Declaration style]) + AC_DEFINE([DECL_SIGVEC_0], [1], [Declaration style]) case "`basename $ac_cv_prog_CC`" in acc*) ;; - *) AC_DEFINE(DECL_STDIO_0, 1, [Declaration style]) + *) AC_DEFINE([DECL_STDIO_0], [1], [Declaration style]) ;; esac - AC_DEFINE(DECL_STRTOL_0, 1, [Declaration style]) - AC_DEFINE(DECL_SYSLOG_0, 1, [Declaration style]) - AC_DEFINE(DECL_TIME_0, 1, [Declaration style]) - AC_DEFINE(DECL_TIMEOFDAY_0, 1, [Declaration style]) - AC_DEFINE(DECL_TOLOWER_0, 1, [Declaration style]) - AC_DEFINE(DECL_TOUPPER_0, 1, [Declaration style]) - AC_DEFINE(DECL_STRERROR_0, 1, [Declaration style]) + AC_DEFINE([DECL_STRTOL_0], [1], [Declaration style]) + AC_DEFINE([DECL_SYSLOG_0], [1], [Declaration style]) + AC_DEFINE([DECL_TIME_0], [1], [Declaration style]) + AC_DEFINE([DECL_TIMEOFDAY_0], [1], [Declaration style]) + AC_DEFINE([DECL_TOLOWER_0], [1], [Declaration style]) + AC_DEFINE([DECL_TOUPPER_0], [1], [Declaration style]) + AC_DEFINE([DECL_STRERROR_0], [1], [Declaration style]) ;; *-*-ultrix4*) - AC_DEFINE(DECL_ADJTIME_0, 1, [Declaration style]) - AC_DEFINE(DECL_BZERO_0, 1, [Declaration style]) - AC_DEFINE(DECL_CFSETISPEED_0, 1, [Declaration style]) - AC_DEFINE(DECL_IOCTL_0, 1, [Declaration style]) - AC_DEFINE(DECL_IPC_0, 1, [Declaration style]) - AC_DEFINE(DECL_MKTEMP_0, 1, [Declaration style]) - AC_DEFINE(DECL_NLIST_0, 1, [Declaration style]) - AC_DEFINE(DECL_PLOCK_0, 1, [Declaration style]) - AC_DEFINE(DECL_SELECT_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETITIMER_0, 1, [Declaration style]) - AC_DEFINE(DECL_SETPRIORITY_0, 1, [Declaration style]) - AC_DEFINE(DECL_STIME_0, 1, [Declaration style]) - AC_DEFINE(DECL_SYSLOG_0, 1, [Declaration style]) - AC_DEFINE(DECL_TIMEOFDAY_0, 1, [Declaration style]) + AC_DEFINE([DECL_ADJTIME_0], [1], [Declaration style]) + AC_DEFINE([DECL_BZERO_0], [1], [Declaration style]) + AC_DEFINE([DECL_CFSETISPEED_0], [1], [Declaration style]) + AC_DEFINE([DECL_IOCTL_0], [1], [Declaration style]) + AC_DEFINE([DECL_IPC_0], [1], [Declaration style]) + AC_DEFINE([DECL_MKTEMP_0], [1], [Declaration style]) + AC_DEFINE([DECL_NLIST_0], [1], [Declaration style]) + AC_DEFINE([DECL_PLOCK_0], [1], [Declaration style]) + AC_DEFINE([DECL_SELECT_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETITIMER_0], [1], [Declaration style]) + AC_DEFINE([DECL_SETPRIORITY_0], [1], [Declaration style]) + AC_DEFINE([DECL_STIME_0], [1], [Declaration style]) + AC_DEFINE([DECL_SYSLOG_0], [1], [Declaration style]) + AC_DEFINE([DECL_TIMEOFDAY_0], [1], [Declaration style]) ;; esac case "$host" in *-*-sco3.2*) - AC_DEFINE(TERMIOS_NEEDS__SVID3, 1, [Do we need to #define _SVID3 when we #include ?]) + AC_DEFINE([TERMIOS_NEEDS__SVID3], [1], + [Do we need to #define _SVID3 when we #include ?]) ;; esac -AC_CACHE_CHECK([if we need extra room for SO_RCVBUF], ac_cv_var_rcvbuf_slop, -[ans=no case "$host" in *-*-hpux[[567]]*) - ans=yes - ;; -esac -ac_cv_var_rcvbuf_slop=$ans]) -case "$ac_cv_var_rcvbuf_slop" in - yes) AC_DEFINE(NEED_RCVBUF_SLOP, 1, [Do we need extra room for SO_RCVBUF? (HPUX <8)]) ;; + AC_DEFINE([NEED_RCVBUF_SLOP], [1], + [Do we need extra room for SO_RCVBUF? (HPUX < 8)]) esac -AC_CACHE_CHECK([if we will open the broadcast socket], ac_cv_var_open_bcast_socket, -[ans=yes -case "$host" in - *-*-domainos) - ans=no - ;; -esac -ac_cv_var_open_bcast_socket=$ans]) -case "$ac_cv_var_open_bcast_socket" in - yes) AC_DEFINE(OPEN_BCAST_SOCKET, 1, [Should we open the broadcast socket?]) ;; +dnl Using AC_CACHE_CHECK to honor preset ntp_cv_var_open_bcast_socket +AC_CACHE_CHECK( + [if we will open the broadcast socket], + [ntp_cv_var_open_bcast_socket], + [ + ans=yes + case "$host" in + *-*-domainos) + ans=no + esac + ntp_cv_var_open_bcast_socket=$ans + ] +) +case "$ntp_cv_var_open_bcast_socket" in + yes) + AC_DEFINE([OPEN_BCAST_SOCKET], [1], + [Should we open the broadcast socket?]) esac -AC_CACHE_CHECK([if we want the HPUX version of FindConfig()], ac_cv_var_hpux_findconfig, -[ans=no case "$host" in *-*-hpux*) - ans=yes - ;; + AC_DEFINE([NEED_HPUX_FINDCONFIG], [1], + [Do we want the HPUX FindConfig()?]) esac -ac_cv_var_hpux_findconfig=$ans]) -case "$ac_cv_var_hpux_findconfig" in - yes) AC_DEFINE(NEED_HPUX_FINDCONFIG, 1, [Do we want the HPUX FindConfig()?]) ;; + +dnl using AC_CACHE_CHECK to honor preset $ntp_cv_arg_setpgrp_negpid +AC_CACHE_CHECK( + [if process groups are set with -pid], + [ntp_cv_arg_setpgrp_negpid], + [ + case "$host" in + *-*-hpux[[567]]*) + ans=no + ;; + *-*-hpux*) + ans=yes + ;; + *-*-*linux*) + ans=yes + ;; + *-*-sunos3*) + ans=yes + ;; + *-*-ultrix2*) + ans=yes + ;; + *) + ans=no + ;; + esac + ntp_cv_arg_setpgrp_negpid=$ans + ] +) +case "$ntp_cv_arg_setpgrp_negpid" in + yes) + AC_DEFINE([UDP_BACKWARDS_SETOWN], [1], + [Do we set process groups with -pid?]) esac -AC_CACHE_CHECK([if process groups are set with -pid], ac_cv_arg_setpgrp_negpid, -[case "$host" in - *-*-hpux[[567]]*) - ans=no - ;; - *-*-hpux*) - ans=yes - ;; - *-*-*linux*) - ans=yes - ;; - *-*-sunos3*) - ans=yes - ;; - *-*-ultrix2*) - ans=yes - ;; - *) - ans=no - ;; -esac -ac_cv_arg_setpgrp_negpid=$ans]) -case "$ac_cv_arg_setpgrp_negpid" in - yes) AC_DEFINE(UDP_BACKWARDS_SETOWN, 1, [Do we set process groups with -pid?]) ;; -esac - -AC_CACHE_CHECK([if we need a ctty for F_SETOWN], ac_cv_func_ctty_for_f_setown, -[[case "$host" in - *-*-bsdi[23]*) - ans=yes - ;; - *-*-freebsd*) - ans=yes - ;; - *-*-netbsd*3.[0-8]*|*-*-netbsd*[0-2].*|*-*-netbsd*3.99.[0-7]) - ans=yes - ;; - *-*-openbsd*) - ans=yes - ;; - *-*-osf*) - ans=yes - ;; - *-*-darwin*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_func_ctty_for_f_setown=$ans]]) -case "$ac_cv_func_ctty_for_f_setown" in - yes) AC_DEFINE(USE_FSETOWNCTTY, 1, [Must we have a CTTY for fsetown?]) ;; -esac - -AC_CACHE_CHECK([if the OS fails to clear cached routes when more specific routes become available], ac_cv_os_routeupdates, -[[case "$host" in - *-*-netbsd*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_os_routeupdates=$ans]]) -case "$ac_cv_os_routeupdates" in - yes) AC_DEFINE(OS_MISSES_SPECIFIC_ROUTE_UPDATES, 1, [need to recreate sockets on changed routing?]) ;; -esac - -AC_CACHE_CHECK([if the OS needs the wildcard socket set to REUSEADDR for binding interface addresses], ac_cv_os_wildcardreuse, -[[case "$host" in - *-*-*linux*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_os_wildcardreuse=$ans]]) -case "$ac_cv_os_wildcardreuse" in - yes) AC_DEFINE(OS_NEEDS_REUSEADDR_FOR_IFADDRBIND, 1, [wildcard socket needs to set REUSEADDR when binding to interface addresses]) ;; -esac - -ntp_warning='GRONK' -AC_MSG_CHECKING([if we'll use clock_settime or settimeofday or stime]) -case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in - yes*) - ntp_warning='' - ans='clock_settime()' - ;; - noyes*) - ntp_warning='But clock_settime() would be better (if we had it)' - ans='settimeofday()' - ;; - nonoyes) - ntp_warning='Which is the worst of the three' - ans='stime()' - ;; - *) - case "$build" in - $host) ntp_warning='Which leaves us with nothing to use!' - ans=none - ;; -esac -esac -AC_MSG_RESULT([$ans]) -case "$ntp_warning" in - '') ;; - *) AC_MSG_WARN([*** $ntp_warning ***]) - ;; -esac - -AC_CACHE_CHECK([if we have a losing syscall()], ac_cv_var_syscall_bug, -[case "$host" in - *-*-solaris2.4*) - ans=yes - ;; - *) ans=no - ;; -esac -ac_cv_var_syscall_bug=$ans]) -case "$ac_cv_var_syscall_bug" in - yes) AC_DEFINE(SYSCALL_BUG, 1, [Buggy syscall() (Solaris2.4)?]) ;; -esac - -AC_CACHE_CHECK([for SIGIO], ac_cv_hdr_def_sigio, - AC_EGREP_CPP(yes, - [#include -#ifdef SIGIO - yes -#endif - ], ac_cv_hdr_def_sigio=yes, ac_cv_hdr_def_sigio=no)) - -dnl Override those system that have a losing SIGIO -AC_CACHE_CHECK([if we want to use signalled IO], ac_cv_var_signalled_io, -[ans=no -case "$ac_cv_hdr_def_sigio" in - yes) - ans=yes - case "$host" in - alpha*-dec-osf4*|alpha*-dec-osf5*) - ans=no - ;; - *-convex-*) - ans=no - ;; - *-dec-*) - ans=no - ;; - *-pc-cygwin*) - ans=no - ;; - *-sni-sysv*) - ans=no - ;; - *-univel-sysv*) - ans=no - ;; - *-*-irix6*) - ans=no - ;; - *-*-freebsd*) - ans=no - ;; - *-*-*linux*) - ans=no - ;; - *-*-unicosmp*) - ans=no - ;; - esac - ;; -esac -ac_cv_var_signalled_io=$ans]) -case "$ac_cv_var_signalled_io" in - yes) AC_DEFINE(HAVE_SIGNALED_IO, 1, [Can we use SIGIO for tcp and udp IO?]) ;; -esac - -AC_CACHE_CHECK([for SIGPOLL], ac_cv_hdr_def_sigpoll, - AC_EGREP_CPP(yes, - [#include -#ifdef SIGPOLL - yes -#endif - ], ac_cv_hdr_def_sigpoll=yes, ac_cv_hdr_def_sigpoll=no)) - -AC_CACHE_CHECK([for SIGSYS], ac_cv_hdr_def_sigsys, - AC_EGREP_CPP(yes, - [#include -#ifdef SIGSYS - yes -#endif - ], ac_cv_hdr_def_sigsys=yes, ac_cv_hdr_def_sigsys=no)) - -AC_CACHE_CHECK([if we can use SIGPOLL for UDP I/O], ac_cv_var_use_udp_sigpoll, -[ans=no -case "$ac_cv_hdr_def_sigpoll" in - yes) - case "$host" in - mips-sgi-irix*) - ans=no - ;; - vax-dec-bsd) - ans=no - ;; - *-pc-cygwin*) - ans=no - ;; - *-sni-sysv*) - ans=no - ;; - *-*-aix[[456]]*) - ans=no - ;; - *-*-hpux*) - ans=no - ;; - *-*-*linux*) - ans=no - ;; - *-*-osf*) - ans=no - ;; - *-*-qnx*) - ans=no - ;; - *-*-sunos*) - ans=no - ;; - *-*-solaris*) - ans=no - ;; - *-*-ultrix*) - ans=no - ;; - *-*-unicosmp*) - ans=no - ;; - *) ans=yes - ;; - esac - ;; -esac -ac_cv_var_use_udp_sigpoll=$ans]) -case "$ac_cv_var_use_udp_sigpoll" in - yes) AC_DEFINE(USE_UDP_SIGPOLL, 1, [Can we use SIGPOLL for UDP?]) ;; -esac - -AC_CACHE_CHECK([if we can use SIGPOLL for TTY I/O], ac_cv_var_use_tty_sigpoll, -[ans=no -case "$ac_cv_hdr_def_sigpoll" in +AC_CACHE_CHECK( + [if we need a ctty for F_SETOWN], + [ntp_cv_func_ctty_for_f_setown], + [ + case "$host" in + *-*-bsdi[[23]]*) + ans=yes + ;; + *-*-freebsd*) + ans=yes + ;; + # NetBSD versions prior to 3.99.8 require a CTTY for F_SETOWN, + # while later versions will fail a ioctl(TIOCSCTTY, 0) call in + # some cases and so should not have USE_FSETOWNCTTY. "netbsd" + # in $host may be followed by "aout", "ecoff", or "elf". + *-*-netbsd*[[a-z]]3.[[0-8]]*|*-*-netbsd*[[a-z]][[0-2]].*|*-*-netbsd*[[a-z]]3.99.[[0-7]]) + ans=yes + ;; + *-*-netbsd3.[[0-8]]*|*-*-netbsd[[0-2]].*|*-*-netbsd3.99.[[0-7]]) + ans=yes + ;; + *-*-openbsd*) + ans=yes + ;; + *-*-osf*) + ans=yes + ;; + *-*-darwin*) + ans=yes + ;; + *) + ans=no + ;; + esac + ntp_cv_func_ctty_for_f_setown=$ans + ] +) +case "$ntp_cv_func_ctty_for_f_setown" in yes) - case "$host" in - mips-sgi-irix*) - ans=no - ;; - vax-dec-bsd) - ans=no - ;; - *-pc-cygwin*) - ans=no - ;; - *-sni-sysv*) - ans=no - ;; - *-*-aix[[456]]*) - ans=no - ;; - *-*-hpux*) - ans=no - ;; - *-*-*linux*) - ans=no - ;; - *-*-osf*) - ans=no - ;; - *-*-sunos*) - ans=no - ;; - *-*-ultrix*) - ans=no - ;; - *-*-qnx*) - ans=no - ;; - *-*-unicosmp*) - ans=no - ;; - *) ans=yes - ;; - esac - ;; -esac -ac_cv_var_use_tty_sigpoll=$ans]) -case "$ac_cv_var_use_tty_sigpoll" in - yes) AC_DEFINE(USE_TTY_SIGPOLL, 1, [Can we use SIGPOLL for tty IO?]) ;; + AC_DEFINE([USE_FSETOWNCTTY], [1], [Must we have a CTTY for fsetown?]) esac -case "$ac_cv_header_sys_sio_h" in +AC_CACHE_CHECK( + [if the OS clears cached routes when more specifics become available], + [ntp_cv_os_routeupdates], + [ + case "$host" in + *-*-netbsd*) + ans=yes + ;; + *) + ans=no + ;; + esac + ntp_cv_os_routeupdates=$ans + ] +) +case "$ntp_cv_os_routeupdates" in yes) - AC_CACHE_CHECK([sys/sio.h for TIOCDCDTIMESTAMP], ac_cv_hdr_def_tiocdcdtimestamp, - AC_EGREP_CPP(yes, -[#include -#ifdef TIOCDCDTIMESTAMP - yes -#endif - ], ac_cv_hdr_def_tiocdcdtimestamp=yes, ac_cv_hdr_def_tiocdcdtimestamp=no)) - ;; + AC_DEFINE([OS_MISSES_SPECIFIC_ROUTE_UPDATES], [1], + [need to recreate sockets on changed routing?]) esac -case "$ac_cv_hdr_def_tiocdcdtimestamp" in +AC_CACHE_CHECK( + [if the wildcard socket needs REUSEADDR to bind other addresses], + [ntp_cv_os_wildcardreuse], + [ + case "$host" in + *-*-*linux*) + ans=yes + ;; + *) ans=no + ;; + esac + ntp_cv_os_wildcardreuse=$ans + ] +) +case "$ntp_cv_os_wildcardreuse" in yes) - ac_cv_var_oncore_ok=yes - ;; + AC_DEFINE([OS_NEEDS_REUSEADDR_FOR_IFADDRBIND], [1], + [wildcard socket needs REUSEADDR to bind interface addresses]) esac -AC_CACHE_CHECK([if nlist() values might require extra indirection], -ac_cv_var_nlist_extra_indirection, -[ans=no case "$host" in *-*-aix*) - ans=yes - ;; -esac -ac_cv_var_nlist_extra_indirection=$ans]) -case "$ac_cv_var_nlist_extra_indirection" in - yes) AC_DEFINE(NLIST_EXTRA_INDIRECTION, 1, [Might nlist() values require an extra level of indirection (AIX)?]) ;; + AC_DEFINE([NLIST_EXTRA_INDIRECTION], [1], + [Might nlist() values require an extra level of indirection (AIX)?]) esac -AC_CACHE_CHECK([for a minimum recommended value of tickadj], -ac_cv_var_min_rec_tickadj, -[ans=no -case "$host" in - *-*-aix*) - ans=40 +AC_CACHE_CHECK( + [for a minimum recommended value of tickadj], + [ntp_cv_var_min_rec_tickadj], + [ + ans=no + case "$host" in + *-*-aix*) + ans=40 + ;; + esac + ntp_cv_var_min_rec_tickadj=$ans + ] +) +case "$ntp_cv_var_min_rec_tickadj" in + ''|no) ;; -esac -ac_cv_var_min_rec_tickadj=$ans]) -case "$ac_cv_var_min_rec_tickadj" in - ''|no) ;; - *) AC_DEFINE_UNQUOTED(MIN_REC_TICKADJ, $ac_cv_var_min_rec_tickadj, [Should we recommend a minimum value for tickadj?]) ;; + *) + AC_DEFINE_UNQUOTED([MIN_REC_TICKADJ], [$ntp_cv_var_min_rec_tickadj], + [Should we recommend a minimum value for tickadj?]) esac -AC_CACHE_CHECK([if the TTY code permits PARENB and IGNPAR], -ac_cv_var_no_parenb_ignpar, -[ans=no -case "$host" in - i?86-*-*linux*) - ans=yes - ;; - mips-sgi-irix*) - ans=yes - ;; - i?86-*-freebsd[[123]].*) - ;; - i?86-*-freebsd*) - ans=yes - ;; - *-*-unicosmp*) - ans=yes - ;; -esac -ac_cv_var_no_parenb_ignpar=$ans]) -case "$ac_cv_var_no_parenb_ignpar" in - yes) AC_DEFINE(NO_PARENB_IGNPAR, 1, [Is there a problem using PARENB and IGNPAR (IRIX)?]) ;; +AC_CACHE_CHECK( + [if the TTY code permits PARENB and IGNPAR], + [ntp_cv_no_parenb_ignpar], + [ + ans=no + case "$host" in + i?86-*-*linux*) + ans=yes + ;; + mips-sgi-irix*) + ans=yes + ;; + i?86-*-freebsd[[123]].*) + ;; + i?86-*-freebsd*) + ans=yes + ;; + *-*-unicosmp*) + ans=yes + ;; + esac + ntp_cv_no_parenb_ignpar=$ans + ] +) +case "$ntp_cv_no_parenb_ignpar" in + yes) + AC_DEFINE([NO_PARENB_IGNPAR], [1], + [Is there a problem using PARENB and IGNPAR?]) esac -AC_MSG_CHECKING([if we're including debugging code]) -AC_ARG_ENABLE(debugging, - AC_HELP_STRING([--enable-debugging], [+ include debugging code]), - [ntp_ok=$enableval], [ntp_ok=yes]) -if test "$ntp_ok" = "yes"; then - AC_DEFINE(DEBUG, 1, [Enable debugging?]) -fi -AC_MSG_RESULT($ntp_ok) - -AC_MSG_CHECKING([if we including processing time debugging code]) -AC_ARG_ENABLE(debug-timing, - AC_HELP_STRING([--enable-debug-timing], [- include processing time debugging code (costs performance)]), - [ntp_ok=$enableval], [ntp_ok=no]) -if test "$ntp_ok" = "yes"; then - AC_DEFINE(DEBUG_TIMING, 1, [Enable processing time debugging?]) -fi -AC_MSG_RESULT($ntp_ok) +AC_MSG_CHECKING([if we're including processing time debugging code]) +AC_ARG_ENABLE( + [debug-timing], + [AS_HELP_STRING( + [--enable-debug-timing], + [- include processing time debugging code (costs performance)] + )], + [ntp_ok=$enableval], + [ntp_ok=no] +) +case "$ntp_ok" in + yes) + AC_DEFINE([DEBUG_TIMING], [1], [Enable processing time debugging?]) +esac +AC_MSG_RESULT([$ntp_ok]) -AC_MSG_CHECKING([[for a the number of minutes in a DST adjustment]]) +AC_MSG_CHECKING([for a the number of minutes in a DST adjustment]) AC_ARG_ENABLE( - [dst_minutes], - AS_HELP_STRING( + [dst-minutes], + [AS_HELP_STRING( [--enable-dst-minutes], - [n minutes per DST adjustment @<:@60@:>@] dnl @<:@ is [ - ), + [=60 minutes per DST adjustment]) dnl @<:@ is [, @:>@ is ] + ], [ans=$enableval], [ans=60] ) -AC_DEFINE_UNQUOTED(DSTMINUTES, $ans, [The number of minutes in a DST adjustment]) +AC_DEFINE_UNQUOTED([DSTMINUTES], [$ans], + [The number of minutes in a DST adjustment]) AC_MSG_RESULT([$ans]) -AC_MSG_CHECKING([[if ntpd will retry on permanent DNS errors]]) +AC_MSG_CHECKING([if ntpd will retry permanent DNS failures]) AC_ARG_ENABLE( [ignore-dns-errors], - AS_HELP_STRING( - [--enable-ignore-dns-errors], + [AS_HELP_STRING( + [--enable-ignore-dns-errors], [- retry DNS queries on any error] - ), + )], [ans=$enableval], [ans=no] ) case "$ans" in yes) - AC_DEFINE(IGNORE_DNS_ERRORS, 1, [[Retry queries on _any_ DNS error?]]) + AC_DEFINE([IGNORE_DNS_ERRORS], [1], + [Retry queries on _any_ DNS error?]) esac AC_MSG_RESULT([$ans]) -AC_CACHE_CHECK([if we have the tty_clk line discipline/streams module], - ac_cv_var_tty_clk, - [case "$ac_cv_header_sys_clkdefs_h$ac_cv_hdr_def_tiocdcdtimestamp" in - *yes*) ac_cv_var_tty_clk=yes ;; - *) ac_cv_var_tty_clk=no ;; - esac]) -case "$ac_cv_var_tty_clk" in - yes) AC_DEFINE(TTYCLK, 1, [Do we have the tty_clk line discipline/streams module?]) ;; -esac - -AC_CACHE_CHECK([for the ppsclock streams module], - ac_cv_var_ppsclock, - ac_cv_var_ppsclock=$ac_cv_struct_ppsclockev) -case "$ac_cv_var_ppsclock" in - yes) AC_DEFINE(PPS, 1, [Do we have the ppsclock streams module?]) ;; -esac - -AC_CACHE_CHECK([for kernel multicast support], ac_cv_var_mcast, - [ac_cv_var_mcast=no - case "$host" in - i386-sequent-sysv4) ;; - *) AC_EGREP_CPP(yes, - [#include -#ifdef IP_ADD_MEMBERSHIP - yes -#endif - ], ac_cv_var_mcast=yes) ;; - esac]) -case "$ac_cv_var_mcast" in - yes) - AC_DEFINE(MCAST, 1, [Does the kernel support multicasting IP?]) - AC_CACHE_CHECK([[arg type needed for IP*_MULTICAST_LOOP for setsockopt()]], - ac_cv_var_typeof_ip_multicast_loop, - [case "$host" in - *-*-netbsd*|*-*-*linux*) - ac_cv_var_typeof_ip_multicast_loop=u_int +AC_CACHE_CHECK( + [availability of ntp_{adj,get}time()], + [ntp_cv_var_ntp_syscalls], + [ + ntp_cv_var_ntp_syscalls=no + case "$ac_cv_func_ntp_adjtime$ac_cv_func_ntp_gettime$ac_cv_func___adjtimex" in + yesyes*) + ntp_cv_var_ntp_syscalls=libc ;; - *-*-winnt*) - ac_cv_var_typeof_ip_multicast_loop=BOOL + *yes) + ntp_cv_var_ntp_syscalls=inline ;; - *) ac_cv_var_typeof_ip_multicast_loop=u_char + *) + AC_PREPROC_IFELSE( + [AC_LANG_SOURCE( + [ + #include + #if !defined(SYS_ntp_gettime) || !defined(SYS_ntp_adjtime) + # error + #endif + ])], + [ntp_cv_var_ntp_syscalls=kernel] + ) ;; - esac]) - AC_DEFINE_UNQUOTED(TYPEOF_IP_MULTICAST_LOOP, - $ac_cv_var_typeof_ip_multicast_loop, - [What type to use for setsockopt]) - ;; -esac - -AC_CACHE_CHECK([[availability of ntp_{adj,get}time()]], ac_cv_var_ntp_syscalls, - [ac_cv_var_ntp_syscalls=no - case "$ac_cv_func_ntp_adjtime$ac_cv_func_ntp_gettime$ac_cv_func___adjtimex" in - yesyes*) - ac_cv_var_ntp_syscalls=libc - ;; - *yes) - ac_cv_var_ntp_syscalls=inline - ;; - *) AC_EGREP_CPP(yes, - [#include -#if defined(SYS_ntp_gettime) && defined(SYS_ntp_adjtime) - yes -#endif - ], ac_cv_var_ntp_syscalls=kernel) - ;; - esac]) -case "$ac_cv_var_ntp_syscalls" in + esac + ] +) +case "$ntp_cv_var_ntp_syscalls" in libc) - AC_DEFINE(NTP_SYSCALLS_LIBC, 1, [Do we have ntp_{adj,get}time in libc?]) + AC_DEFINE([NTP_SYSCALLS_LIBC], [1], + [Do we have ntp_{adj,get}time in libc?]) ;; kernel) - AC_DEFINE(NTP_SYSCALLS_STD, 1, [Do we have ntp_{adj,get}time in the kernel?]) - ;; - *) + AC_DEFINE([NTP_SYSCALLS_STD], [1], + [Do we have ntp_{adj,get}time in the kernel?]) ;; esac -AC_CACHE_CHECK(if sys/timex.h has STA_FLL, ac_cv_var_sta_fll, -[AC_EGREP_CPP(yes, - [#include -#ifdef STA_FLL - yes -#endif - ], ac_cv_var_sta_fll=yes, ac_cv_var_sta_fll=no)]) +AC_CACHE_CHECK( + [if sys/timex.h has STA_FLL], + [ntp_cv_var_sta_fll], + [AC_PREPROC_IFELSE( + [AC_LANG_SOURCE( + [ + #include + #ifndef STA_FLL + # error + #endif + ])], + [ntp_cv_var_sta_fll=yes], + [ntp_cv_var_sta_fll=no] + )] +) -AC_CACHE_CHECK(if we have kernel PLL support, ac_cv_var_kernel_pll, -[dnl ac_cv_var_ntp_syscalls is {no,libc,kernel} -case "$ac_cv_header_sys_timex_h$ac_cv_struct_ntptimeval$ac_cv_var_sta_fll$ac_cv_var_ntp_syscalls" in - *no*) - ac_cv_var_kernel_pll=no - ;; - *) ac_cv_var_kernel_pll=yes - ;; -esac]) -case "$ac_cv_var_kernel_pll" in +AC_CACHE_CHECK( + [if we have kernel PLL support], + [ntp_cv_var_kernel_pll], + [dnl ntp_cv_var_ntp_syscalls is {no,libc,kernel} + case "$ac_cv_header_sys_timex_h$ntp_cv_struct_ntptimeval$ntp_cv_var_sta_fll$ntp_cv_var_ntp_syscalls" in + *no*) + ntp_cv_var_kernel_pll=no + ;; + *) ntp_cv_var_kernel_pll=yes + ;; + esac + ] +) +case "$ntp_cv_var_kernel_pll" in yes) - AC_DEFINE(KERNEL_PLL, 1, [Does the kernel support precision time discipline?]) - ;; -esac - -AC_CACHE_CHECK(if SIOCGIFCONF returns buffer size in the buffer, ac_cv_var_size_returned_in_buffer, - [ans=no - case "$host" in - *-fujitsu-uxp*) - ans=yes - ;; - *-ncr-sysv4*) - ans=yes - ;; - *-univel-sysv*) - ans=yes - ;; - esac - ac_cv_var_size_returned_in_buffer=$ans]) -case "$ac_cv_var_size_returned_in_buffer" in - yes) AC_DEFINE(SIZE_RETURNED_IN_BUFFER, 1, [Does SIOCGIFCONF return size in the buffer?]) ;; -esac - -dnl vvvvv-- this is wrong, if you re-enable the switch do not cache the result -dnl AC_CACHE_CHECK(if we want GDT surveying code, ac_cv_var_gdt_surveying, -dnl [AC_ARG_ENABLE(gdt-surveying, [ --enable-gdt-surveying - include GDT survey code], -dnl [ans=$enableval], [ans=no]) -dnl ac_cv_var_gdt_surveying=$ans]) -dnl case "$ac_cv_var_gdt_surveying" in -dnl yes) AC_DEFINE(GDT_SURVEYING, 1, [Include the GDT Surveying code?]) ;; -dnl esac + AC_DEFINE([KERNEL_PLL], [1], + [Does the kernel support precision time discipline?]) +esac + +AC_CACHE_CHECK( + [if SIOCGIFCONF returns buffer size in the buffer], + [ntp_cv_size_returned_in_buffer], + [ + ans=no + case "$host" in + *-fujitsu-uxp*) + ans=yes + ;; + *-ncr-sysv4*) + ans=yes + ;; + *-univel-sysv*) + ans=yes + ;; + esac + ntp_cv_size_returned_in_buffer=$ans + ] +) +case "$ntp_cv_size_returned_in_buffer" in + yes) + AC_DEFINE([SIZE_RETURNED_IN_BUFFER], [1], + [Does SIOCGIFCONF return size in the buffer?]) +esac # Check for ioctls TIOCGPPSEV -AC_MSG_CHECKING(ioctl TIOCGPPSEV) -if test "$ac_cv_header_termios_h" = "yes"; then - AC_EGREP_CPP(yes, - [#include -#ifdef TIOCGPPSEV - yes -#endif - ], ntp_ok=yes, ntp_ok=no) -else -ntp_ok=no -fi -if test "$ntp_ok" = "yes"; then - AC_DEFINE(HAVE_TIOCGPPSEV, 1, [Do we have the TIOCGPPSEV ioctl (Solaris)?]) - ac_cv_var_oncore_ok=yes -fi -AC_MSG_RESULT($ntp_ok) +AC_MSG_CHECKING([for TTY PPS ioctl TIOCGPPSEV]) +case "$ac_cv_header_termios_h" in + yes) + AC_PREPROC_IFELSE( + [AC_LANG_SOURCE([ + #include + #ifndef TIOCGPPSEV + # error + #endif + ])], + [ntp_ok=yes], + [ntp_ok=no] + ) + ;; + *) + ntp_ok=no + ;; +esac +case "$ntp_ok" in + yes) + AC_DEFINE([HAVE_TIOCGPPSEV], [1], + [Do we have the TIOCGPPSEV ioctl (Solaris)?]) +esac +AC_MSG_RESULT([$ntp_ok]) # Check for ioctls TIOCSPPS -AC_MSG_CHECKING(ioctl TIOCSPPS) -if test "$ac_cv_header_termios_h" = "yes"; then - AC_EGREP_CPP(yes, - [#include -#ifdef TIOCSPPS - yes -#endif - ], ntp_ok=yes, ntp_ok=no) -else +AC_MSG_CHECKING([for TTY PPS ioctl TIOCSPPS]) +case "$ac_cv_header_termios_h" in + yes) + AC_PREPROC_IFELSE( + [AC_LANG_SOURCE([ + #include + #ifndef TIOCSPPS + # error + #endif + ])], + [ntp_ok=yes], + [ntp_ok=no] + ) + ;; + *) ntp_ok=no -fi - -if test "$ntp_ok" = "yes"; then - AC_DEFINE(HAVE_TIOCSPPS, 1, [Do we have the TIOCSPPS ioctl (Solaris)?]) -fi -AC_MSG_RESULT($ntp_ok) + ;; +esac +case "$ntp_ok" in + yes) + AC_DEFINE([HAVE_TIOCSPPS], [1], + [Do we have the TIOCSPPS ioctl (Solaris)?]) +esac +AC_MSG_RESULT([$ntp_ok]) # Check for ioctls CIOGETEV -AC_MSG_CHECKING([ioctl CIOGETEV]) -if test "$ac_cv_header_sys_ppsclock_h" = "yes"; then - AC_EGREP_CPP(yes, - [#include -#ifdef CIOGETEV - yes -#endif - ], ntp_ok=yes, ntp_ok=no) -else -ntp_ok=no -fi -if test "$ntp_ok" = "yes"; then - ac_cv_var_oncore_ok=yes - AC_DEFINE(HAVE_CIOGETEV, 1, [Do we have the CIOGETEV ioctl (SunOS, Linux)?]) -fi -AC_MSG_RESULT($ntp_ok) - +AC_MSG_CHECKING([for TTY PPS ioctl CIOGETEV]) +case "$ac_cv_header_sys_ppsclock_h" in + yes) + AC_PREPROC_IFELSE( + [AC_LANG_SOURCE([ + #include + #ifndef CIOGETEV + # error + #endif + ])], + [ntp_ok=yes], + [ntp_ok=no] + ) + ;; + *) + ntp_ok=no + ;; +esac +case "$ntp_ok" in + yes) + AC_DEFINE([HAVE_CIOGETEV], [1], + [Do we have the CIOGETEV ioctl (SunOS, Linux)?]) +esac +AC_MSG_RESULT([$ntp_ok]) # ATOM/PPSAPI stuff. -# ATOM used to require struct timespec, but that's been fixed now. - -# case "$ac_cv_struct_timespec" in -# 'yes') -# ac_cv_var_atom_ok=yes -# ;; -# esac -ac_cv_var_atom_ok=yes +ntp_atom_ok=yes # Check for header timepps.h, if found then we have PPS API (Draft RFC) stuff. # The PPSAPI headers need "inline" ($ac_cv_c_inline='inline') - # The PPSAPI needs struct timespec. - # The PPSAPI also needs a timepps header. -case "$ac_cv_c_inline$ac_cv_struct_timespec" in +case "$ac_cv_c_inline$ntp_cv_struct_timespec" in inlineyes) case "$ac_cv_header_timepps_h$ac_cv_header_sys_timepps_h$host_os" in *yes* | *sunos* | *solaris* | *sco* | *netbsd* ) AC_DEFINE(HAVE_PPSAPI, 1, [Do we have the PPS API per the Draft RFC?]) - ac_cv_var_jupiter_ok=yes - ac_cv_var_oncore_ok=yes - ac_cv_var_parse_ok=yes - ac_cv_var_ripe_ncc_ok=yes + ntp_jupiter_ok=yes + ntp_oncore_ok=yes + ntp_parse_ok=yes + ntp_ripe_ncc_ok=yes ;; esac ;; esac # Check for ioctls TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG -AC_CHECK_HEADER(linux/serial.h) -AC_MSG_CHECKING([ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG]) +AC_CHECK_HEADER([linux/serial.h]) case "$ac_cv_header_sys_ppsclock_h$ac_cv_header_linux_serial_h" in yesyes) - AC_EGREP_CPP(yes, - [#include -typedef int u_int; - -#include -#include - -#ifdef TIOCGSERIAL -#ifdef TIOCSSERIAL -#ifdef ASYNC_PPS_CD_POS -#ifdef ASYNC_PPS_CD_NEG -#ifdef CIOGETEV - yes -#endif -#endif -#endif -#endif -#endif - ], ntp_ok=yes) - ;; + AC_MSG_CHECKING([ioctl TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG]) + AC_PREPROC_IFELSE( + [AC_LANG_SOURCE([ + #include + typedef int u_int; + #include + #include + + #ifndef TIOCGSERIAL + # error + #endif + #ifndef TIOCSSERIAL + # error + #endif + #ifndef ASYNC_PPS_CD_POS + # error + #endif + #ifndef ASYNC_PPS_CD_NEG + # error + #endif + #ifndef CIOGETEV + # error + #endif + ])], + [ntp_ok=yes], + [ntp_ok=no] + ) + AC_MSG_RESULT([$ntp_ok]) + ;; *) - ntp_ok=no - ;; + ntp_ok=no + ;; +esac +case "$ntp_ok" in + yes) + AC_DEFINE([HAVE_TIO_SERIAL_STUFF], 1, + [Do we have the TIO serial stuff?]) esac -if test "$ntp_ok" = "yes"; then - AC_DEFINE(HAVE_TIO_SERIAL_STUFF, 1, [Do we have the TIO serial stuff?]) -fi -AC_MSG_RESULT($ntp_ok) # Check for SHMEM_STATUS support AC_MSG_CHECKING([SHMEM_STATUS support]) case "$ac_cv_header_sys_mman_h" in - yes) ntp_ok=yes ;; - *) ntp_ok=no ;; + yes) + ntp_ok=yes + ;; + *) + ntp_ok=no + ;; esac -if test "$ntp_ok" = "yes"; then - AC_DEFINE(ONCORE_SHMEM_STATUS, 1, [Do we have support for SHMEM_STATUS?]) -fi -AC_MSG_RESULT($ntp_ok) - -dnl dnl These are for OPT_PROGRAMS in authstuff/ -dnl AC_SUBST(AUTHCERT) -dnl AC_SUBST(AUTHSPEED) -dnl AC_SUBST(MD5DRIVER) -dnl AC_SUBST(KEYPARITY) -dnl AC_SUBST(MAKEIPFP) -dnl AC_SUBST(MAKEPC1) -dnl AC_SUBST(MAKEPC2) -dnl AC_SUBST(MAKESP) -dnl AC_SUBST(MKRANDKEYS) -dnl AC_SUBST(OMAKEIPFP) -dnl AC_SUBST(UNIXCERT) +case "$ntp_ok" in + yes) + AC_DEFINE([ONCORE_SHMEM_STATUS], [1], + [Do we have support for SHMEM_STATUS?]) +esac +AC_MSG_RESULT([$ntp_ok]) ntp_refclock=no # HPUX only, and by explicit request AC_MSG_CHECKING([Datum/Bancomm bc635/VME interface]) -AC_ARG_ENABLE(BANCOMM, - AC_HELP_STRING([--enable-BANCOMM], [- Datum/Bancomm bc635/VME interface]), - [ntp_ok=$enableval], [ntp_ok=no]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [BANCOMM], + [AS_HELP_STRING( + [--enable-BANCOMM], + [- Datum/Bancomm bc635/VME interface] + )], + [ntp_ok=$enableval], + [ntp_ok=no] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_BANC, 1, [Datum/Bancomm bc635/VME interface?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_BANC], [1], [Datum/Bancomm bc635/VME interface?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$host" in yes*-*-hpux*) ;; yes*) AC_MSG_WARN([*** But the expected answer is... no ***]) ;; @@ -2318,14 +1752,22 @@ esac #HPUX only, and only by explicit request AC_MSG_CHECKING([TrueTime GPS receiver/VME interface]) -AC_ARG_ENABLE(GPSVME, - AC_HELP_STRING([--enable-GPSVME], [- TrueTime GPS receiver/VME interface]), - [ntp_ok=$enableval], [ntp_ok=no]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [GPSVME], + [AS_HELP_STRING( + [--enable-GPSVME], + [- TrueTime GPS receiver/VME interface] + )], + [ntp_ok=$enableval], + [ntp_ok=no] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_GPSVME, 1, [TrueTime GPS receiver/VME interface?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_GPSVME], 1, [TrueTime GPS receiver/VME interface?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$host" in yes*-*-hpux*) ;; yes*) AC_MSG_WARN([*** But the expected answer is... no ***]) ;; @@ -2334,7 +1776,7 @@ esac AC_MSG_CHECKING([for PCL720 clock support]) case "$ac_cv_header_machine_inline_h$ac_cv_header_sys_pcl720_h$ac_cv_header_sys_i8253_h" in yesyesyes) - AC_DEFINE(CLOCK_PPS720, 1, [PCL 720 clock support]) + AC_DEFINE([CLOCK_PPS720], 1, [PCL 720 clock support]) ans=yes ;; *) @@ -2344,31 +1786,37 @@ esac AC_MSG_RESULT([$ans]) AC_MSG_CHECKING([for default inclusion of all suitable non-PARSE clocks]) -AC_ARG_ENABLE(all-clocks, - AC_HELP_STRING([--enable-all-clocks], [+ include all suitable non-PARSE clocks:]), - [ntp_eac=$enableval], [ntp_eac=yes]) -AC_MSG_RESULT($ntp_eac) +AC_ARG_ENABLE( + [all-clocks], + [AS_HELP_STRING( + [--enable-all-clocks], + [+ include all suitable non-PARSE clocks:] + )], + [ntp_eac=$enableval], + [ntp_eac=yes] +) +AC_MSG_RESULT([$ntp_eac]) -# HMS: Should we also require ac_cv_var_parse_ok? +# HMS: Should we also require ntp_parse_ok? AC_MSG_CHECKING([if we have support for PARSE clocks]) -case "$ac_cv_var_atom_ok$ac_cv_header_termio_h$ac_cv_header_termios_h" in +case "$ntp_atom_ok$ac_cv_header_termio_h$ac_cv_header_termios_h" in yes*yes*) ntp_canparse=yes ;; *) ntp_canparse=no ;; esac -AC_MSG_RESULT($ntp_canparse) +AC_MSG_RESULT([$ntp_canparse]) AC_MSG_CHECKING([if we have support for audio clocks]) case "$ac_cv_header_sun_audioio_h$ac_cv_header_sys_audioio_h$ac_cv_header_machine_soundcard_h$ac_cv_header_sys_soundcard_h" in *yes*) ntp_canaudio=yes - AC_DEFINE(HAVE_AUDIO, , [Do we have audio support?]) + AC_DEFINE([HAVE_AUDIO], [], [Do we have audio support?]) ;; *) ntp_canaudio=no ;; esac -AC_MSG_RESULT($ntp_canaudio) +AC_MSG_RESULT([$ntp_canaudio]) AC_MSG_CHECKING([if we have support for the SHM refclock interface]) case "$ac_cv_header_sys_ipc_h$ac_cv_header_sys_shm_h" in @@ -2377,510 +1825,859 @@ case "$ac_cv_header_sys_ipc_h$ac_cv_header_sys_shm_h" in ;; *) ntp_canshm=no ;; esac -AC_MSG_RESULT($ntp_canshm) +AC_MSG_RESULT([$ntp_canshm]) + +# Test for termios TIOCMBIS modem control (ACTS, Heath, Palisade) +AC_CACHE_CHECK( + [for termios modem control], + [ntp_cv_modem_control], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_UNISTD_H + # include + #endif + #ifdef HAVE_TERMIOS_H + # include + #endif + #ifdef HAVE_SYS_IOCTL_H + # include + #endif + ]], + [[ + int dtr = TIOCM_DTR; + + ioctl(1, TIOCMBIS, (char *)&dtr); + ]] + )], + [ntp_cv_modem_control=yes], + [ntp_cv_modem_control=no] + )] +) +case "$ntp_eac::$ntp_cv_modem_control" in + yes::yes) + ntp_enable_all_modem_control_clocks=yes + ;; + *) + ntp_enable_all_modem_control_clocks=no + ;; +esac # Requires modem control AC_MSG_CHECKING([ACTS modem service]) -AC_ARG_ENABLE(ACTS, - AC_HELP_STRING([--enable-ACTS], [s ACTS modem service]), +AC_ARG_ENABLE( + [ACTS], + [AS_HELP_STRING( + [--enable-ACTS], + [s ACTS modem service] + )], [ntp_ok=$enableval], - [AC_EGREP_CPP(yes, - [#include -#ifdef HAVE_SYS_IOCTL_H -#include -#endif -#ifdef TIOCMBIS - yes -#endif - ], ntp_ok=$ntp_eac, ntp_ok=no)]) -if test "$ntp_ok" = "yes"; then + [ntp_ok=$ntp_enable_all_modem_control_clocks] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_ACTS, 1, [ACTS modem service]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_ACTS], [1], [ACTS modem service]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Arbiter 1088A/B GPS receiver]) -AC_ARG_ENABLE(ARBITER, - AC_HELP_STRING([--enable-ARBITER], [+ Arbiter 1088A/B GPS receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [ARBITER], + [AS_HELP_STRING( + [--enable-ARBITER], + [+ Arbiter 1088A/B GPS receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_ARBITER, 1, [Arbiter 1088A/B GPS receiver]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_ARBITER], [1], [Arbiter 1088A/B GPS receiver]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Arcron MSF receiver]) -AC_ARG_ENABLE(ARCRON_MSF, - AC_HELP_STRING([--enable-ARCRON-MSF], [+ Arcron MSF receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [ARCRON_MSF], + [AS_HELP_STRING( + [--enable-ARCRON-MSF], + [+ Arcron MSF receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_ARCRON_MSF, 1, [ARCRON support?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_ARCRON_MSF], [1], [ARCRON support?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Austron 2200A/2201A GPS receiver]) -AC_ARG_ENABLE(AS2201, - AC_HELP_STRING([--enable-AS2201], [+ Austron 2200A/2201A GPS receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [AS2201], + [AS_HELP_STRING( + [--enable-AS2201], + [+ Austron 2200A/2201A GPS receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_AS2201, 1, [Austron 2200A/2201A GPS receiver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_AS2201], [1], [Austron 2200A/2201A GPS receiver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([ATOM PPS interface]) -AC_ARG_ENABLE(ATOM, - AC_HELP_STRING([--enable-ATOM], [s ATOM PPS interface]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -case "$ac_cv_var_atom_ok" in +AC_ARG_ENABLE( + [ATOM], + [AS_HELP_STRING( + [--enable-ATOM], + [s ATOM PPS interface] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_atom_ok" in no) ntp_ok=no ;; esac -if test "$ntp_ok" = "yes"; then +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_ATOM, 1, [PPS interface?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_ATOM], [1], [PPS interface?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Chrono-log K-series WWVB receiver]) -AC_ARG_ENABLE(CHRONOLOG, - AC_HELP_STRING([--enable-CHRONOLOG], [+ Chrono-log K-series WWVB receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [CHRONOLOG], + [AS_HELP_STRING( + [--enable-CHRONOLOG], + [+ Chrono-log K-series WWVB receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_CHRONOLOG, 1, [Chronolog K-series WWVB receiver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_CHRONOLOG], [1], [Chronolog K-series WWVB receiver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([CHU modem/decoder]) -AC_ARG_ENABLE(CHU, - AC_HELP_STRING([--enable-CHU], [+ CHU modem/decoder]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [CHU], + [AS_HELP_STRING( + [--enable-CHU], + [+ CHU modem/decoder] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_CHU, 1, [CHU modem/decoder]) -fi -AC_MSG_RESULT($ntp_ok) -ac_refclock_chu=$ntp_ok + AC_DEFINE([CLOCK_CHU], [1], [CHU modem/decoder]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) +ntp_refclock_chu=$ntp_ok AC_MSG_CHECKING([CHU audio/decoder]) -AC_ARG_ENABLE(AUDIO-CHU, - AC_HELP_STRING([--enable-AUDIO-CHU], [s CHU audio/decoder]), +AC_ARG_ENABLE( + [AUDIO-CHU], + [AS_HELP_STRING( + [--enable-AUDIO-CHU], + [s CHU audio/decoder] + )], [ntp_ok=$enableval], - [case "$ntp_eac$ac_refclock_chu$ntp_canaudio" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; -esac]) -if test "$ntp_ok" = "yes"; then - AC_DEFINE(AUDIO_CHU, 1, [CHU audio/decoder?]) -fi -AC_MSG_RESULT($ntp_ok) + [ + case "$ntp_eac$ntp_refclock_chu$ntp_canaudio" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac + ] +) +AC_MSG_RESULT([$ntp_ok]) # We used to check for sunos/solaris target... -case "$ntp_ok$ac_refclock_chu$ntp_canaudio" in - yes*no*) AC_MSG_WARN([*** But the expected answer is...no ***]) ;; +case "$ntp_ok$ntp_refclock_chu$ntp_canaudio" in + yes*no*) AC_MSG_WARN([*** But the expected answer is...no ***]) esac # Not under HP-UX AC_MSG_CHECKING([Datum Programmable Time System]) -AC_ARG_ENABLE(DATUM, - AC_HELP_STRING([--enable-DATUM], [s Datum Programmable Time System]), +AC_ARG_ENABLE( + [DATUM], + [AS_HELP_STRING( + [--enable-DATUM], + [s Datum Programmable Time System] + )], [ntp_ok=$enableval], - [case "$ac_cv_header_termios_h" in - yes) - ntp_ok=$ntp_eac - ;; - *) ntp_ok=no - ;; - esac]) -if test "$ntp_ok" = "yes"; then + [ + case "$ac_cv_header_termios_h" in + yes) + ntp_ok=$ntp_eac + ;; + *) ntp_ok=no + ;; + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_DATUM, 1, [Datum Programmable Time System?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_DATUM], [1], [Datum Programmable Time System?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Dumb generic hh:mm:ss local clock]) -AC_ARG_ENABLE(DUMBCLOCK, - AC_HELP_STRING([--enable-DUMBCLOCK], [+ Dumb generic hh:mm:ss local clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [DUMBCLOCK], + [AS_HELP_STRING( + [--enable-DUMBCLOCK], + [+ Dumb generic hh:mm:ss local clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_DUMBCLOCK, 1, [Dumb generic hh:mm:ss local clock?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_DUMBCLOCK], [1], [Dumb generic hh:mm:ss local clock?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Forum Graphic GPS]) -AC_ARG_ENABLE(FG, - AC_HELP_STRING([--enable-FG], [+ Forum Graphic GPS]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [FG], + [AS_HELP_STRING( + [--enable-FG], + [+ Forum Graphic GPS] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_FG, 1, [Forum Graphic GPS datating station driver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_FG], [1], [Forum Graphic GPS datating station driver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) # Requires modem control AC_MSG_CHECKING([Heath GC-1000 WWV/WWVH receiver]) -AC_ARG_ENABLE(HEATH, - AC_HELP_STRING([--enable-HEATH], [s Heath GC-1000 WWV/WWVH receiver]), +AC_ARG_ENABLE( + [HEATH], + [AS_HELP_STRING( + [--enable-HEATH], + [s Heath GC-1000 WWV/WWVH receiver] + )], [ntp_ok=$enableval], - [AC_EGREP_CPP(yes, - [#include -#ifdef HAVE_SYS_IOCTL_H -#include -#endif -#ifdef TIOCMBIS - yes -#endif - ], ntp_ok=$ntp_eac, ntp_ok=no)]) -if test "$ntp_ok" = "yes"; then + [ntp_ok=$ntp_enable_all_modem_control_clocks] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_HEATH, 1, [Heath GC-1000 WWV/WWVH receiver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_HEATH], [1], [Heath GC-1000 WWV/WWVH receiver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([for hopf serial clock device]) -AC_ARG_ENABLE(HOPFSERIAL, - AC_HELP_STRING([--enable-HOPFSERIAL], [+ hopf serial clock device]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [HOPFSERIAL], + [AS_HELP_STRING( + [--enable-HOPFSERIAL], + [+ hopf serial clock device] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_HOPF_SERIAL, 1, [HOPF serial clock device?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_HOPF_SERIAL], [1], [HOPF serial clock device?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([for hopf PCI clock 6039]) -AC_ARG_ENABLE(HOPFPCI, - AC_HELP_STRING([--enable-HOPFPCI], [+ hopf 6039 PCI board]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [HOPFPCI], + [AS_HELP_STRING( + [--enable-HOPFPCI], + [+ hopf 6039 PCI board] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_HOPF_PCI, 1, [HOPF PCI clock device?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_HOPF_PCI], [1], [HOPF PCI clock device?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([HP 58503A GPS receiver]) -AC_ARG_ENABLE(HPGPS, - AC_HELP_STRING([--enable-HPGPS], [+ HP 58503A GPS receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [HPGPS], + [AS_HELP_STRING( + [--enable-HPGPS], + [+ HP 58503A GPS receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_HPGPS, 1, [HP 58503A GPS receiver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_HPGPS], 1, [HP 58503A GPS receiver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([IRIG audio decoder]) -AC_ARG_ENABLE(IRIG, - AC_HELP_STRING([--enable-IRIG], [s IRIG audio decoder]), +AC_ARG_ENABLE( + [IRIG], + [AS_HELP_STRING( + [--enable-IRIG], + [s IRIG audio decoder] + )], [ntp_ok=$enableval], - [case "$ntp_eac$ntp_canaudio" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; - esac]) -if test "$ntp_ok" = "yes"; then + [ + case "$ntp_eac$ntp_canaudio" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_IRIG, 1, [IRIG audio decoder?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_IRIG], [1], [IRIG audio decoder?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canaudio" in - yesno) AC_MSG_WARN([*** But the expected answer is... no ***]) ;; + yesno) AC_MSG_WARN([*** But the expected answer is... no ***]) esac AC_MSG_CHECKING([for JJY receiver]) -AC_ARG_ENABLE(JJY, - AC_HELP_STRING([--enable-JJY], [+ JJY receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [JJY], + [AS_HELP_STRING( + [--enable-JJY], + [+ JJY receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_JJY, 1, [JJY receiver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_JJY], [1], [JJY receiver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Rockwell Jupiter GPS receiver]) -AC_ARG_ENABLE(JUPITER, - AC_HELP_STRING([--enable-JUPITER], [s Rockwell Jupiter GPS receiver]), +AC_ARG_ENABLE( + [JUPITER], + [AS_HELP_STRING( + [--enable-JUPITER], + [s Rockwell Jupiter GPS receiver] + )], [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -case "$ac_cv_var_jupiter_ok" in +case "$ntp_jupiter_ok" in no) ntp_ok=no ;; esac -if test "$ntp_ok" = "yes"; then +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_JUPITER, 1, [Rockwell Jupiter GPS clock?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_JUPITER], [1], [Rockwell Jupiter GPS clock?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Leitch CSD 5300 Master Clock System Driver]) -AC_ARG_ENABLE(LEITCH, - AC_HELP_STRING([--enable-LEITCH], [+ Leitch CSD 5300 Master Clock System Driver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [LEITCH], + [AS_HELP_STRING( + [--enable-LEITCH], + [+ Leitch CSD 5300 Master Clock System Driver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_LEITCH, 1, [Leitch CSD 5300 Master Clock System Driver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_LEITCH], [1], + [Leitch CSD 5300 Master Clock System Driver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([local clock reference]) -AC_ARG_ENABLE(LOCAL-CLOCK, - AC_HELP_STRING([--enable-LOCAL-CLOCK], [+ local clock reference]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [LOCAL-CLOCK], + [AS_HELP_STRING( + [--enable-LOCAL-CLOCK], + [+ local clock reference] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_LOCAL, 1, [local clock reference?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_LOCAL], [1], [local clock reference?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) dnl Bug 340: longstanding unfixed bugs -dnl AC_MSG_CHECKING(EES M201 MSF receiver) -dnl AC_ARG_ENABLE(MSFEES, -dnl AC_HELP_STRING([--enable-MSFEES], [+ EES M201 MSF receiver]), +dnl AC_MSG_CHECKING([EES M201 MSF receiver]) +dnl AC_ARG_ENABLE([MSFEES], +dnl [AS_HELP_STRING([--enable-MSFEES], [+ EES M201 MSF receiver])], dnl [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) dnl if test "$ntp_ok" = "yes"; then dnl ntp_refclock=yes -dnl AC_DEFINE(CLOCK_MSFEES, 1, [EES M201 MSF receiver]) +dnl AC_DEFINE([CLOCK_MSFEES], [1], [EES M201 MSF receiver]) dnl fi -dnl AC_MSG_RESULT($ntp_ok) +dnl AC_MSG_RESULT([$ntp_ok]) # Not Ultrix AC_MSG_CHECKING([Magnavox MX4200 GPS receiver]) -AC_ARG_ENABLE(MX4200, - AC_HELP_STRING([--enable-MX4200 ], [s Magnavox MX4200 GPS receiver]), +AC_ARG_ENABLE( + [MX4200], + [AS_HELP_STRING( + [--enable-MX4200 ], + [s Magnavox MX4200 GPS receiver] + )], [ntp_ok=$enableval], - [case "$ac_cv_var_ppsclock" in - yes) ntp_ok=$ntp_eac - ;; - *) ntp_ok=no - ;; - esac]) -if test "$ntp_ok" = "yes"; then + [ + case "$ac_cv_var_ppsclock" in + yes) + ntp_ok=$ntp_eac + ;; + *) + ntp_ok=no + ;; + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_MX4200, 1, [Magnavox MX4200 GPS receiver]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_MX4200], [1], [Magnavox MX4200 GPS receiver]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$host" in - yes*-*-ultrix*) AC_MSG_WARN(*** But the expected answer is... no ***) ;; + yes*-*-ultrix*) AC_MSG_WARN([*** But the expected answer is... no ***]) esac AC_MSG_CHECKING([for NeoClock4X receiver]) -AC_ARG_ENABLE(NEOCLOCK4X, - AC_HELP_STRING([--enable-NEOCLOCK4X], [+ NeoClock4X DCF77 / TDF receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [NEOCLOCK4X], + [AS_HELP_STRING( + [--enable-NEOCLOCK4X], + [+ NeoClock4X DCF77 / TDF receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_NEOCLOCK4X, 1, [NeoClock4X]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_NEOCLOCK4X], [1], [NeoClock4X]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([NMEA GPS receiver]) -AC_ARG_ENABLE(NMEA, - AC_HELP_STRING([--enable-NMEA], [+ NMEA GPS receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [NMEA], + [AS_HELP_STRING( + [--enable-NMEA], + [+ NMEA GPS receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_NMEA, 1, [NMEA GPS receiver]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_NMEA], [1], [NMEA GPS receiver]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) + +AC_CHECK_FUNCS([strtoll]) +AC_MSG_CHECKING([for GPSD JSON receiver]) +AC_ARG_ENABLE( + [GPSD], + [AS_HELP_STRING( + [--enable-GPSD], + [+ GPSD JSON receiver] + )], + [ntp_ok=$enableval], + [case "$ac_cv_func_strtoll" in + yes) ntp_ok=$ntp_eac ;; + *) ntp_ok="no" ;; + esac] +) +case "$ntp_ok" in + yes) + ntp_refclock=yes + AC_DEFINE([CLOCK_GPSDJSON], [1], [GPSD JSON receiver]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([for ONCORE Motorola VP/UT Oncore GPS]) -AC_ARG_ENABLE(ONCORE, - AC_HELP_STRING([--enable-ONCORE], [s Motorola VP/UT Oncore GPS receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -case "$ac_cv_var_oncore_ok" in +AC_ARG_ENABLE( + [ONCORE], + [AS_HELP_STRING( + [--enable-ONCORE], + [s Motorola VP/UT Oncore GPS receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_oncore_ok" in no) ntp_ok=no ;; esac -if test "$ntp_ok" = "yes"; then +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_ONCORE, 1, [Motorola UT Oncore GPS]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_ONCORE], 1, [Motorola UT Oncore GPS]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) +# Requires modem control AC_MSG_CHECKING([for Palisade clock]) -AC_ARG_ENABLE(PALISADE, - AC_HELP_STRING([--enable-PALISADE], [s Palisade clock]), +AC_ARG_ENABLE( + [PALISADE], + [AS_HELP_STRING( + [--enable-PALISADE], + [s Palisade clock] + )], [ntp_ok=$enableval], - [case "$ac_cv_header_termios_h" in - yes) - ntp_ok=$ntp_eac - ;; - *) ntp_ok=no - ;; - esac]) - -if test "$ntp_ok" = "yes"; then + [ntp_ok=$ntp_enable_all_modem_control_clocks] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_PALISADE, 1, [Palisade clock]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_PALISADE], [1], [Palisade clock]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Conrad parallel port radio clock]) -AC_ARG_ENABLE(PCF, - AC_HELP_STRING([--enable-PCF ], [+ Conrad parallel port radio clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [PCF], + [AS_HELP_STRING( + [--enable-PCF ], + [+ Conrad parallel port radio clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_PCF, 1, [Conrad parallel port radio clock]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_PCF], [1], [Conrad parallel port radio clock]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([PST/Traconex 1020 WWV/WWVH receiver]) -AC_ARG_ENABLE(PST, - AC_HELP_STRING([--enable-PST], [+ PST/Traconex 1020 WWV/WWVH receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [PST], + [AS_HELP_STRING( + [--enable-PST], + [+ PST/Traconex 1020 WWV/WWVH receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_PST, 1, [PST/Traconex 1020 WWV/WWVH receiver]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_PST], [1], [PST/Traconex 1020 WWV/WWVH receiver]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([RIPENCC specific Trimble driver]) -AC_ARG_ENABLE(RIPENCC, - AC_HELP_STRING([--enable-RIPENCC], [- RIPENCC specific Trimble driver]), - [ntp_ok=$enableval], [ntp_ok=no]) +AC_ARG_ENABLE( + [RIPENCC], + [AS_HELP_STRING( + [--enable-RIPENCC], + [- RIPENCC specific Trimble driver] + )], + [ntp_ok=$enableval], + [ntp_ok=no] +) # 020629: HMS: s/$ntp_eac -> -/no because of ptr += sprintf(ptr, ...) usage -case "$ac_cv_var_ripe_ncc_ok" in +case "$ntp_ripe_ncc_ok" in no) ntp_ok=no ;; esac -if test "$ntp_ok" = "yes"; then +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_RIPENCC, ,[RIPE NCC Trimble clock]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_RIPENCC], [],[RIPE NCC Trimble clock]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) # Danny Meyer says SHM compiles (with a few warnings) under Win32. # For *IX, we need sys/ipc.h and sys/shm.h. AC_MSG_CHECKING([for SHM clock attached thru shared memory]) -AC_ARG_ENABLE(SHM, - AC_HELP_STRING([--enable-SHM], [s SHM clock attached thru shared memory]), +AC_ARG_ENABLE( + [SHM], + [AS_HELP_STRING( + [--enable-SHM], + [s SHM clock attached thru shared memory] + )], [ntp_ok=$enableval], - [case "$ntp_eac$ntp_canshm" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; -esac]) -if test "$ntp_ok" = "yes"; then + [ + case "$ntp_eac$ntp_canshm" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_SHM, 1, [clock thru shared memory]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_SHM], [1], [clock thru shared memory]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Spectracom 8170/Netclock/2 WWVB receiver]) -AC_ARG_ENABLE(SPECTRACOM, - AC_HELP_STRING([--enable-SPECTRACOM], [+ Spectracom 8170/Netclock/2 WWVB receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [SPECTRACOM], + [AS_HELP_STRING( + [--enable-SPECTRACOM], + [+ Spectracom 8170/Netclock/2 WWVB receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_SPECTRACOM, 1, [Spectracom 8170/Netclock/2 WWVB receiver]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_SPECTRACOM], [1], + [Spectracom 8170/Netclock/2 WWVB receiver]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([KSI/Odetics TPRO/S GPS receiver/IRIG interface]) -AC_ARG_ENABLE(TPRO, - AC_HELP_STRING([--enable-TPRO], [s KSI/Odetics TPRO/S GPS receiver/IRIG interface]), +AC_ARG_ENABLE( + [TPRO], + [AS_HELP_STRING( + [--enable-TPRO], + [s KSI/Odetics TPRO/S GPS receiver/IRIG interface] + )], [ntp_ok=$enableval], - [case "$ac_cv_header_sys_tpro_h" in - yes) - ntp_ok=$ntp_eac - ;; - *) ntp_ok=no - ;; - esac]) -if test "$ntp_ok" = "yes"; then + [ + case "$ac_cv_header_sys_tpro_h" in + yes) + ntp_ok=$ntp_eac + ;; + *) + ntp_ok=no + ;; + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_TPRO, 1, [KSI/Odetics TPRO/S GPS receiver/IRIG interface]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_TPRO], [1], + [KSI/Odetics TPRO/S GPS receiver/IRIG interface]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ac_cv_header_sys_tpro" in - yesno) AC_MSG_WARN([*** But the expected answer is... no ***]) ;; + yesno) AC_MSG_WARN([*** But the expected answer is... no ***]) esac -dnl Bug 342: longstanding unfixed bugs -dnl AC_MSG_CHECKING(TRAK 8810 GPS receiver) -dnl AC_ARG_ENABLE(TRAK, -dnl AC_HELP_STRING([--enable-TRAK], [+ TRAK 8810 GPS receiver]), -dnl [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -dnl if test "$ntp_ok" = "yes"; then -dnl ntp_refclock=yes -dnl AC_DEFINE(CLOCK_TRAK, 1, [TRAK 8810 GPS receiver]) -dnl fi -dnl AC_MSG_RESULT($ntp_ok) - # Not on a vax-dec-bsd AC_MSG_CHECKING([Kinemetrics/TrueTime receivers]) -AC_ARG_ENABLE(TRUETIME, - AC_HELP_STRING([--enable-TRUETIME], [s Kinemetrics/TrueTime receivers]), +AC_ARG_ENABLE( + [TRUETIME], + [AS_HELP_STRING( + [--enable-TRUETIME], + [s Kinemetrics/TrueTime receivers] + )], [ntp_ok=$enableval], - [case "$host" in - vax-dec-bsd) - ntp_ok=no - ;; - *) - ntp_ok=$ntp_eac - ;; - esac]) - -if test "$ntp_ok" = "yes"; then + [ + case "$host" in + vax-dec-bsd) + ntp_ok=no + ;; + *) + ntp_ok=$ntp_eac + ;; + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_TRUETIME, 1, [Kinemetrics/TrueTime receivers]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_TRUETIME], [1], [Kinemetrics/TrueTime receivers]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$host" in - yesvax-dec-bsd) AC_MSG_WARN([*** But the expected answer is... no ***]) ;; + yesvax-dec-bsd) AC_MSG_WARN([*** But the expected answer is... no ***]) esac AC_MSG_CHECKING([TrueTime 560 IRIG-B decoder]) -AC_ARG_ENABLE(TT560, - AC_HELP_STRING([--enable-TT560], [- TrueTime 560 IRIG-B decoder]), - [ntp_ok=$enableval], [ntp_ok=no]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [TT560], + [AS_HELP_STRING( + [--enable-TT560], + [- TrueTime 560 IRIG-B decoder] + )], + [ntp_ok=$enableval], + [ntp_ok=no] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_TT560, , [TrueTime 560 IRIG-B decoder?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_TT560], [], [TrueTime 560 IRIG-B decoder?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([Ultralink M320 WWVB receiver]) -AC_ARG_ENABLE(ULINK, - AC_HELP_STRING([--enable-ULINK], [+ Ultralink WWVB receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [ULINK], + [AS_HELP_STRING( + [--enable-ULINK], + [+ Ultralink WWVB receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) + ntp_refclock=yes + AC_DEFINE([CLOCK_ULINK], [1], [Ultralink M320 WWVB receiver?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) + +AC_MSG_CHECKING([Spectracom TSYNC PCI timing board]) +AC_ARG_ENABLE( + [TSYNCPCI], + [AS_HELP_STRING( + [--enable-TSYNCPCI], + [s Spectracom TSYNC timing board] + )], + [ntp_ok=$enableval], + [ + case "$host" in + *-*-*linux*) + ntp_ok=$ntp_eac + ;; + *) + ntp_ok=no + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_ULINK, 1, [Ultralink M320 WWVB receiver?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_TSYNCPCI], [1], [Spectracom TSYNC timing board]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([WWV receiver]) -AC_ARG_ENABLE(WWV, - AC_HELP_STRING([--enable-WWV], [s WWV Audio receiver]), +AC_ARG_ENABLE( + [WWV], + [AS_HELP_STRING( + [--enable-WWV], + [s WWV Audio receiver] + )], [ntp_ok=$enableval], - [case "$ntp_eac$ntp_canaudio" in - *no*) ntp_ok=no ;; - *) ntp_ok=yes ;; - esac]) -if test "$ntp_ok" = "yes"; then + [ + case "$ntp_eac$ntp_canaudio" in + *no*) ntp_ok=no ;; + *) ntp_ok=yes ;; + esac + ] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_WWV, 1, [WWV audio driver]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_WWV], [1], [WWV audio driver]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canaudio" in - yesno) AC_MSG_WARN(*** But the expected answer is... no ***) ;; + yesno) AC_MSG_WARN([*** But the expected answer is... no ***]) esac AC_MSG_CHECKING([for Zyfer receiver]) -AC_ARG_ENABLE(ZYFER, - AC_HELP_STRING([--enable-ZYFER], [+ Zyfer GPStarplus receiver]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eac]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [ZYFER], + [AS_HELP_STRING( + [--enable-ZYFER], + [+ Zyfer GPStarplus receiver] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eac] +) +case "$ntp_ok" in + yes) ntp_refclock=yes - AC_DEFINE(CLOCK_ZYFER, 1, [Zyfer GPStarplus]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_ZYFER], [1], [Zyfer GPStarplus]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) AC_MSG_CHECKING([for default inclusion of all suitable PARSE clocks]) -AC_ARG_ENABLE(parse-clocks, - AC_HELP_STRING([--enable-parse-clocks], [- include all suitable PARSE clocks:]), +AC_ARG_ENABLE( + [parse-clocks], + [AS_HELP_STRING( + [--enable-parse-clocks], + [- include all suitable PARSE clocks:] + )], [ntp_eapc=$enableval], - [case "$ntp_eac" in - yes) ntp_eapc=$ntp_canparse ;; - *) ntp_eapc=no ;; - esac - # Delete the next line one of these days - ntp_eapc=no]) + [ + case "$ntp_eac" in + yes) ntp_eapc=$ntp_canparse ;; + *) ntp_eapc=no ;; + esac + # Delete the next line one of these days + ntp_eapc=no + ] +) AC_MSG_RESULT($ntp_eapc) case "$ntp_eac$ntp_eapc$ntp_canparse" in @@ -2890,7 +2687,6 @@ case "$ntp_eac$ntp_eapc$ntp_canparse" in yesyesno) AC_MSG_ERROR([You said "--enable-parse-clocks" but PARSE isn't supported on this platform!]) ;; - *) ;; esac ntp_libparse=no @@ -2898,359 +2694,351 @@ ntp_parseutil=no ntp_rawdcf=no AC_MSG_CHECKING([Diem Computime Radio Clock]) -AC_ARG_ENABLE(COMPUTIME, - AC_HELP_STRING([--enable-COMPUTIME], [s Diem Computime Radio Clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [COMPUTIME], + [AS_HELP_STRING( + [--enable-COMPUTIME], + [s Diem Computime Radio Clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_COMPUTIME, 1, [Diems Computime Radio Clock?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_COMPUTIME], [1], [Diems Computime Radio Clock?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) - ;; esac AC_MSG_CHECKING([ELV/DCF7000 clock]) -AC_ARG_ENABLE(DCF7000, - AC_HELP_STRING([--enable-DCF7000], [s ELV/DCF7000 clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [DCF7000], + [AS_HELP_STRING( + [--enable-DCF7000], + [s ELV/DCF7000 clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_DCF7000, 1, [ELV/DCF7000 clock?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_DCF7000], [1], [ELV/DCF7000 clock?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) - ;; esac AC_MSG_CHECKING([HOPF 6021 clock]) -AC_ARG_ENABLE(HOPF6021, - AC_HELP_STRING([--enable-HOPF6021 ], [s HOPF 6021 clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [HOPF6021], + [AS_HELP_STRING( + [--enable-HOPF6021], + [s HOPF 6021 clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_HOPF6021, 1, [HOPF 6021 clock?]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_HOPF6021], [1], [HOPF 6021 clock?]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) - ;; esac AC_MSG_CHECKING([Meinberg clocks]) -AC_ARG_ENABLE(MEINBERG, - AC_HELP_STRING([--enable-MEINBERG], [s Meinberg clocks]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [MEINBERG], + [AS_HELP_STRING( + [--enable-MEINBERG], + [s Meinberg clocks] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_MEINBERG, 1, [Meinberg clocks]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_MEINBERG], [1], [Meinberg clocks]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) - ;; esac AC_MSG_CHECKING([DCF77 raw time code]) -AC_ARG_ENABLE(RAWDCF, - AC_HELP_STRING([--enable-RAWDCF], [s DCF77 raw time code]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [RAWDCF], + [AS_HELP_STRING( + [--enable-RAWDCF], + [s DCF77 raw time code] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_parseutil=yes ntp_refclock=yes ntp_rawdcf=yes - AC_DEFINE(CLOCK_RAWDCF, 1, [DCF77 raw time code]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_RAWDCF], [1], [DCF77 raw time code]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) - AC_MSG_ERROR(That's a parse clock and this system doesn't support it!) - ;; + AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) esac case "$ntp_rawdcf" in yes) AC_CACHE_CHECK([if we must enable parity for RAWDCF], - ac_cv_var_rawdcf_parity, - [ans=no - case "$host" in - *-*-*linux*) - ans=yes - ;; - esac - ac_cv_var_rawdcf_parity=$ans]) - case "$ac_cv_var_rawdcf_parity" in - yes) AC_DEFINE(RAWDCF_NO_IGNPAR, 1, [Should we not IGNPAR (Linux)?]) ;; + [ntp_cv_rawdcf_parity], + [ + ans=no + case "$host" in + *-*-*linux*) + ans=yes + ;; + esac + ntp_cv_rawdcf_parity=$ans + ] + ) + case "$ntp_cv_rawdcf_parity" in + yes) + AC_DEFINE([RAWDCF_NO_IGNPAR], [1], + [Should we not IGNPAR (Linux)?]) ;; esac - ;; - - *) # HMS: Is this a good idea? - ac_cv_var_rawdcf_parity=no - ;; esac AC_MSG_CHECKING([RCC 8000 clock]) -AC_ARG_ENABLE(RCC8000, - AC_HELP_STRING([--enable-RCC8000], [s RCC 8000 clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [RCC8000], + [AS_HELP_STRING( + [--enable-RCC8000], + [s RCC 8000 clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_RCC8000, 1, [RCC 8000 clock]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_RCC8000], [1], [RCC 8000 clock]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) - AC_MSG_ERROR(That's a parse clock and this system doesn't support it!) - ;; + AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) esac AC_MSG_CHECKING([Schmid DCF77 clock]) -AC_ARG_ENABLE(SCHMID, - AC_HELP_STRING([--enable-SCHMID ], [s Schmid DCF77 clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [SCHMID], + [AS_HELP_STRING( + [--enable-SCHMID ], + [s Schmid DCF77 clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_SCHMID, 1, [Schmid DCF77 clock]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_SCHMID], [1], [Schmid DCF77 clock]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) - AC_MSG_ERROR(That's a parse clock and this system doesn't support it!) - ;; + AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) esac AC_MSG_CHECKING([Trimble GPS receiver/TAIP protocol]) -AC_ARG_ENABLE(TRIMTAIP, - AC_HELP_STRING([--enable-TRIMTAIP], [s Trimble GPS receiver/TAIP protocol]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [TRIMTAIP], + [AS_HELP_STRING( + [--enable-TRIMTAIP], + [s Trimble GPS receiver/TAIP protocol] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_TRIMTAIP, 1, [Trimble GPS receiver/TAIP protocol]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_TRIMTAIP], [1], + [Trimble GPS receiver/TAIP protocol]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) - AC_MSG_ERROR(That's a parse clock and this system doesn't support it!) - ;; + AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) esac AC_MSG_CHECKING([Trimble GPS receiver/TSIP protocol]) -AC_ARG_ENABLE(TRIMTSIP, - AC_HELP_STRING([--enable-TRIMTSIP], [s Trimble GPS receiver/TSIP protocol]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [TRIMTSIP], + [AS_HELP_STRING( + [--enable-TRIMTSIP], + [s Trimble GPS receiver/TSIP protocol] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_TRIMTSIP, 1, [Trimble GPS receiver/TSIP protocol]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_TRIMTSIP], [1], + [Trimble GPS receiver/TSIP protocol]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) - AC_MSG_ERROR(That's a parse clock and this system doesn't support it!) - ;; + AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) esac AC_MSG_CHECKING([WHARTON 400A Series clock]) -AC_ARG_ENABLE(WHARTON, - AC_HELP_STRING([--enable-WHARTON], [s WHARTON 400A Series clock]), - [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) -if test "$ntp_ok" = "yes"; then +AC_ARG_ENABLE( + [WHARTON], + [AS_HELP_STRING( + [--enable-WHARTON], + [s WHARTON 400A Series clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_WHARTON_400A, 1, [WHARTON 400A Series protocol]) -fi -AC_MSG_RESULT($ntp_ok) + AC_DEFINE([CLOCK_WHARTON_400A], [1], [WHARTON 400A Series clock]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) case "$ntp_ok$ntp_canparse" in yesno) - AC_MSG_ERROR(That's a parse clock and this system doesn't support it!) - ;; + AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) esac AC_MSG_CHECKING([VARITEXT clock]) -AC_ARG_ENABLE(VARITEXT, - AC_HELP_STRING([--enable-VARITEXT], [s VARITEXT clock]), +AC_ARG_ENABLE( + [VARITEXT], + [AS_HELP_STRING( + [--enable-VARITEXT], + [s VARITEXT clock] + )], + [ntp_ok=$enableval], + [ntp_ok=$ntp_eapc] +) +case "$ntp_ok" in + yes) + ntp_libparse=yes + ntp_refclock=yes + AC_DEFINE([CLOCK_VARITEXT], [1], [VARITEXT clock]) + ;; +esac +AC_MSG_RESULT([$ntp_ok]) +case "$ntp_ok$ntp_canparse" in + yesno) + AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) +esac + +AC_MSG_CHECKING(SEL240X clock) +AC_ARG_ENABLE(SEL240X, + AC_HELP_STRING([--enable-SEL240X], [s SEL240X clock]), [ntp_ok=$enableval], [ntp_ok=$ntp_eapc]) if test "$ntp_ok" = "yes"; then ntp_libparse=yes ntp_refclock=yes - AC_DEFINE(CLOCK_VARITEXT, 1, [VARITEXT protocol]) + AC_DEFINE(CLOCK_SEL240X, 1, [SEL240X protocol]) fi AC_MSG_RESULT($ntp_ok) case "$ntp_ok$ntp_canparse" in yesno) - AC_MSG_ERROR([That's a parse clock and this system doesn't support it!]) + AC_MSG_ERROR(That's a parse clock and this system doesn't support it!) ;; esac -AC_SUBST(LIBPARSE) -AC_SUBST(MAKE_LIBPARSE) -AC_SUBST(MAKE_LIBPARSE_KERNEL) -AC_SUBST(MAKE_CHECK_Y2K) + +AC_SUBST([LIBPARSE]) +AC_SUBST([MAKE_LIBPARSE]) +AC_SUBST([MAKE_LIBPARSE_KERNEL]) +AC_SUBST([MAKE_CHECK_Y2K]) + AC_MSG_CHECKING([if we need to make and use the parse libraries]) ans=no case "$ntp_libparse" in yes) ans=yes - AC_DEFINE(CLOCK_PARSE, 1, [PARSE driver interface]) + AC_DEFINE([CLOCK_PARSE], [1], [PARSE driver interface]) LIBPARSE=../libparse/libparse.a MAKE_LIBPARSE=libparse.a # HMS: check_y2k trips the 34 year problem now... false && MAKE_CHECK_Y2K=check_y2k - AC_DEFINE(PPS_SAMPLE, 1, [PPS auxiliary interface for ATOM?]) - AC_DEFINE(CLOCK_ATOM) - ;; esac AC_MSG_RESULT([$ans]) -# AC_SUBST(RSAOBJS) -# AC_SUBST(RSASRCS) -# AC_SUBST(RSADIR) -# AC_SUBST(RSAREF) -# AC_SUBST(LIBRSAREF) -# AC_SUBST(MAKE_LIBRSAREF) - -AC_SUBST(OPENSSL) -AC_SUBST(OPENSSL_INC) -AC_SUBST(OPENSSL_LIB) - -AC_MSG_CHECKING([for openssl library directory]) -AC_ARG_WITH(openssl-libdir, - AC_HELP_STRING([--with-openssl-libdir], [+ =/something/reasonable]), -[ans=$withval], -[case "$build" in - $host) ans=yes ;; - *) ans=no ;; -esac]) -case "$ans" in - no) ;; - yes) # Look in: - ans="/usr/lib /usr/lib/openssl /usr/sfw/lib /usr/local/lib /usr/local/ssl/lib" - ;; - *) # Look where they said - ;; -esac -case "$ans" in - no) ;; - *) # Look for libcrypto.a and libssl.a: - for i in $ans no - do - case "$host" in - *-*-darwin*) - test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break - ;; - *) - test -f $i/libcrypto.so -a -f $i/libssl.so && break - test -f $i/libcrypto.a -a -f $i/libssl.a && break - ;; - esac - done - case "$i" in - no) - ans=no - OPENSSL_LIB= - ;; - *) ans=$i - OPENSSL_LIB=$ans - ;; - esac - ;; -esac -AC_MSG_RESULT([$ans]) +NTP_OPENSSL -AC_MSG_CHECKING([for openssl include directory]) -AC_ARG_WITH(openssl-incdir, - AC_HELP_STRING([--with-openssl-incdir], [+ =/something/reasonable]), -[ans=$withval], -[case "$build" in - $host) ans=yes ;; - *) ans=no ;; -esac]) -case "$ans" in - no) ;; - yes) # look in: - ans="/usr/include /usr/sfw/include /usr/local/include /usr/local/ssl/include" - ;; - *) # Look where they said +NTP_CRYPTO_RAND + +# if we are using OpenSSL (--with-crypto), by default Autokey is enabled +AC_MSG_CHECKING([if we want to include NTP Autokey protocol support]) +AC_ARG_ENABLE( + [autokey], + AS_HELP_STRING( + [--enable-autokey], + [+ support NTP Autokey protocol] + ), + [ntp_autokey=$enableval], + [ntp_autokey=$ntp_openssl] +) +case "$ntp_autokey" in + no) ;; -esac -case "$ans" in - no) ;; - *) # look for openssl/opensslconf.h: - for i in $ans no - do - test -f $i/openssl/opensslconf.h && break - done - case "$i" in + *) + case "$ntp_openssl" in no) - ans=no - OPENSSL_INC= + AC_MSG_WARN([Disabling Autokey, --enable-autokey requires --with-crypto.]) + ntp_autokey=no ;; - *) ans=$i - OPENSSL_INC=$ans + *) + AC_DEFINE([AUTOKEY], [1], [Support NTP Autokey protocol?]) + ntp_autokey=yes ;; esac ;; esac -AC_MSG_RESULT([$ans]) - -AC_ARG_WITH(crypto, - AC_HELP_STRING([--with-crypto], [+ =openssl]), -[ans=$withval], [ans=yes]) -case "$ans" in - no) ;; - yes|openssl) - if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INC" - then - ans=no - else - # We have OpenSSL inc/lib - use them. - ans=openssl - CPPFLAGS="$CPPFLAGS -I$OPENSSL_INC" - LDFLAGS="$LDFLAGS -L$OPENSSL_LIB" - case "$need_dash_r" in - 1) LDFLAGS="$LDFLAGS -R$OPENSSL_LIB" - ;; - esac - AC_SUBST(LCRYPTO, [-lcrypto]) - AC_DEFINE(OPENSSL, , [Use OpenSSL?]) - AC_CHECK_FUNCS(EVP_md2 EVP_mdc2) - fi - ;; -esac -AC_MSG_CHECKING(for the level of crypto support) -AC_MSG_RESULT([$ans]) - -AC_MSG_CHECKING([if we want to compile with ElectricFence]) -AC_ARG_WITH(electricfence, - AC_HELP_STRING([--with-electricfence], [- compile with ElectricFence malloc debugger]), -[ans=$withval], [ans=no]) -case "$ans" in - no) ;; - *) - LIBS="$LIBS \${top_builddir}/ElectricFence/libefence.a" - EF_PROGS="eftest tstheap" - AC_SUBST(EF_PROGS) - EF_LIBS=libefence.a - AC_SUBST(EF_LIBS) - ans=yes - ;; -esac -AC_MSG_RESULT([$ans]) +AC_MSG_RESULT([$ntp_autokey]) -AC_SUBST(MAKE_CHECK_LAYOUT) +AC_SUBST([MAKE_CHECK_LAYOUT]) AC_MSG_CHECKING([if we want to run check-layout]) case "$cross_compiling$PATH_PERL" in no/*) @@ -3263,32 +3051,32 @@ case "$cross_compiling$PATH_PERL" in esac AC_MSG_RESULT([$ans]) -AC_SUBST(TESTDCF) -AC_SUBST(DCFD) - +AC_SUBST([TESTDCF]) +AC_SUBST([DCFD]) AC_MSG_CHECKING([if we can make dcf parse utilities]) ans=no -if test "$ntp_parseutil" = "yes"; then +case "$ntp_parseutil" in + yes) case "$host" in *-*-sunos4*|*-*-solaris2*|*-*-*linux*|*-*-netbsd*) ans="dcfd testdcf" DCFD=dcfd - TESTDCF=testdcf - ;; + TESTDCF=testdcf esac -fi + ;; +esac AC_MSG_RESULT([$ans]) -AC_SUBST(MAKE_PARSEKMODULE) +AC_SUBST([MAKE_PARSEKMODULE]) AC_MSG_CHECKING([if we can build kernel streams modules for parse]) ans=no case "$ntp_parseutil$ac_cv_header_sys_stropts_h" in yesyes) case "$host" in sparc-*-sunos4*) - case "$ac_cv_var_kernel_pll" in + case "$ntp_cv_var_kernel_pll" in yes) - AC_DEFINE(PPS_SYNC, 1, [PARSE kernel PLL PPS support]) + AC_DEFINE([PPS_SYNC], [1], [PARSE kernel PLL PPS support]) ;; esac ans=parsestreams @@ -3297,6 +3085,7 @@ case "$ntp_parseutil$ac_cv_header_sys_stropts_h" in sparc-*-solaris2*) ans=parsesolaris MAKE_PARSEKMODULE=parse + AC_CHECK_HEADERS([strings.h]) ;; esac ;; @@ -3304,18 +3093,19 @@ esac AC_MSG_RESULT([$ans]) AC_MSG_CHECKING([if we need basic refclock support]) -if test "$ntp_refclock" = "yes"; then - AC_DEFINE(REFCLOCK, 1, [Basic refclock support?]) -fi +case "$ntp_refclock" in + yes) + AC_DEFINE([REFCLOCK], [1], [Basic refclock support?]) + ;; +esac AC_MSG_RESULT($ntp_refclock) -dnl Things that can be made in clockstuff/ -AC_SUBST(PROPDELAY) dnl Set to "propdelay" -AC_SUBST(CHUTEST) dnl Set to "chutest" -AC_SUBST(CLKTEST) dnl Set to "clktest" +dnl Things that can be made in clockstuff +AC_SUBST([PROPDELAY], [propdelay]) +AC_SUBST([CHUTEST]) dnl needs work to compile -AC_SUBST(MAKE_ADJTIMED) -AC_MSG_CHECKING(if we want HP-UX adjtimed support) +AC_SUBST([MAKE_ADJTIMED]) +AC_MSG_CHECKING([if we want HP-UX adjtimed support]) case "$host" in *-*-hpux[[56789]]*) ans=yes @@ -3323,10 +3113,18 @@ case "$host" in *) ans=no ;; esac -if test "$ans" = "yes"; then +case "$ans" in + yes) MAKE_ADJTIMED=adjtimed - AC_DEFINE(NEED_HPUX_ADJTIME, 1, [Do we need HPUX adjtime() library support?]) -fi + AC_DEFINE([NEED_HPUX_ADJTIME], [1], + [Do we need HPUX adjtime() library support?]) + ;; + *) ADJTIMED_DB= + ADJTIMED_DL= + ADJTIMED_DS= + ADJTIMED_MS= + ;; +esac AC_MSG_RESULT([$ans]) AC_MSG_CHECKING([if we want QNX adjtime support]) @@ -3337,9 +3135,12 @@ case "$host" in *) ans=no ;; esac -if test "$ans" = "yes"; then - AC_DEFINE(NEED_QNX_ADJTIME, 1, [Do we need the qnx adjtime call?]) -fi +case "$ans" in + yes) + AC_DEFINE([NEED_QNX_ADJTIME], [1], + [Do we need the qnx adjtime call?]) + ;; +esac AC_MSG_RESULT([$ans]) AC_MSG_CHECKING([if we can read kmem]) @@ -3351,6 +3152,7 @@ case "$ac_cv_func_nlist$ac_cv_func_K_open$ac_cv_func_kvm_open" in ans=yes ;; *) ans=no + ;; esac case "$host" in @@ -3377,10 +3179,10 @@ esac # --enable-kmem / --disable-kmem controls if present AC_ARG_ENABLE( [kmem], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-kmem], [s read /dev/kmem for tick and/or tickadj] - ), + )], [ans=$enableval] ) @@ -3390,9 +3192,9 @@ case "$ans" in yes) can_kmem=yes ;; - *) + *) can_kmem=no - AC_DEFINE(NOKMEM, 1, [Should we NOT read /dev/kmem?]) + AC_DEFINE([NOKMEM], [1], [Should we NOT read /dev/kmem?]) esac @@ -3413,7 +3215,8 @@ case "$host" in *-fujitsu-uxp*) ans=yes ;; - *-ibm-aix[[456]]*) + *-ibm-aix[[4-9]]*) + # XXX only verified thru AIX6. ans=yes ;; *-*-*linux*) @@ -3429,236 +3232,280 @@ case "$host" in ans=yes ;; *) ans=no + ;; esac # --enable-accurate-adjtime / --disable-accurate-adjtime # override the default -AC_ARG_ENABLE([accurate-adjtime], - AC_HELP_STRING( - [--enable-accurate-adjtime], - [s the adjtime() call is accurate] - ), - [ans=$enableval], +AC_ARG_ENABLE( + [accurate-adjtime], + [AS_HELP_STRING( + [--enable-accurate-adjtime], + [s the adjtime() call is accurate] + )], + [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ans" in - yes) - AC_DEFINE(ADJTIME_IS_ACCURATE, 1, [Is adjtime() accurate?]) + yes) + AC_DEFINE([ADJTIME_IS_ACCURATE], [1], [Is adjtime() accurate?]) adjtime_is_accurate=yes ;; *) adjtime_is_accurate=no -esac - -AC_CACHE_CHECK([the name of 'tick' in the kernel], -ac_cv_var_nlist_tick, -[ans=_tick -case "$host" in - m68*-hp-hpux*) # HP9000/300? - ans=_old_tick - ;; - *-apple-aux[[23]]*) - ans=tick - ;; - *-hp-hpux*) - ans=old_tick - ;; - *-ibm-aix[[3456]]*) - ans=no - ;; - *-*-mpeix*) - ans=no - ;; - *-*-ptx*) - ans=tick - ;; - *-*-sco3.2v[[45]]*) - ans=no ;; - *-*-solaris2*) - ans=nsec_per_tick - ;; - *-*-sysv4*) - ans=tick - ;; -esac -ac_cv_var_nlist_tick=$ans]) -case "$ac_cv_var_nlist_tick" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) AC_DEFINE_UNQUOTED(K_TICK_NAME, "$ac_cv_var_nlist_tick", [What is the name of TICK in the kernel?]) ;; esac -# -AC_CACHE_CHECK([for the units of 'tick'], -ac_cv_var_tick_nano, -[ans=usec -case "$host" in - *-*-solaris2*) - ans=nsec - ;; + +AC_CACHE_CHECK( + [the name of 'tick' in the kernel], + [ntp_cv_nlist_tick], + [ + ans=_tick + case "$host" in + m68*-hp-hpux*) # HP9000/300? + ans=_old_tick + ;; + *-apple-aux[[23]]*) + ans=tick + ;; + *-hp-hpux*) + ans=old_tick + ;; + *-ibm-aix[[3-9]]*) + # XXX only verified thru AIX6. + ans=no + ;; + *-*-mpeix*) + ans=no + ;; + *-*-ptx*) + ans=tick + ;; + *-*-sco3.2v[[45]]*) + ans=no + ;; + *-*-solaris2*) + ans=nsec_per_tick + ;; + *-*-sysv4*) + ans=tick + ;; + esac + ntp_cv_nlist_tick=$ans + ] +) +case "$ntp_cv_nlist_tick" in + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) + AC_DEFINE_UNQUOTED([K_TICK_NAME], ["$ntp_cv_nlist_tick"], + [What is the name of TICK in the kernel?]) esac -ac_cv_var_tick_nano=$ans]) -case "$ac_cv_var_tick_nano" in + +AC_CACHE_CHECK( + [for the units of 'tick'], + [ntp_cv_tick_nano], + [ + ans=usec + case "$host" in + *-*-solaris2*) + ans=nsec + ;; + esac + ntp_cv_tick_nano=$ans + ] +) +case "$ntp_cv_tick_nano" in nsec) - AC_DEFINE(TICK_NANO, 1, [Is K_TICK_NAME in nanoseconds?]) - ;; -esac -# -AC_CACHE_CHECK([the name of 'tickadj' in the kernel], -ac_cv_var_nlist_tickadj, -[ans=_tickadj -case "$host" in - m68*-hp-hpux*) # HP9000/300? - ans=_tickadj - ;; - *-apple-aux[[23]]*) - ans=tickadj - ;; - *-hp-hpux10*) - ans=no - ;; - *-hp-hpux9*) - ans=no - ;; - *-hp-hpux*) - ans=tickadj - ;; - *-*-aix*) - ans=tickadj - ;; - *-*-mpeix*) - ans=no - ;; - *-*-ptx*) - ans=tickadj - ;; - *-*-sco3.2v4*) - ans=no - ;; - *-*-sco3.2v5.0*) - ans=clock_drift - ;; - *-*-solaris2*) - ans=no # hrestime_adj - ;; - *-*-sysv4*) - ans=tickadj - ;; + AC_DEFINE([TICK_NANO], [1], [Is K_TICK_NAME in nanoseconds?]) esac -ac_cv_var_nlist_tickadj=$ans]) -case "$ac_cv_var_nlist_tickadj" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) AC_DEFINE_UNQUOTED(K_TICKADJ_NAME, "$ac_cv_var_nlist_tickadj", [What is the name of TICKADJ in the kernel?]) ;; -esac -# -AC_CACHE_CHECK([for the units of 'tickadj'], -ac_cv_var_tickadj_nano, -[ans=usec -case "$host" in - *-*-solaris2*) - ans=nsec - ;; + +AC_CACHE_CHECK( + [the name of 'tickadj' in the kernel], + [ntp_cv_nlist_tickadj], + [ + ans=_tickadj + case "$host" in + m68*-hp-hpux*) # HP9000/300? + ans=_tickadj + ;; + *-apple-aux[[23]]*) + ans=tickadj + ;; + *-hp-hpux10*) + ans=no + ;; + *-hp-hpux9*) + ans=no + ;; + *-hp-hpux*) + ans=tickadj + ;; + *-*-aix*) + ans=tickadj + ;; + *-*-mpeix*) + ans=no + ;; + *-*-ptx*) + ans=tickadj + ;; + *-*-sco3.2v4*) + ans=no + ;; + *-*-sco3.2v5.0*) + ans=clock_drift + ;; + *-*-solaris2*) + ans=no # hrestime_adj + ;; + *-*-sysv4*) + ans=tickadj + ;; + esac + ntp_cv_nlist_tickadj=$ans + ] +) +case "$ntp_cv_nlist_tickadj" in + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) + AC_DEFINE_UNQUOTED([K_TICKADJ_NAME], ["$ntp_cv_nlist_tickadj"], + [What is the name of TICKADJ in the kernel?]) esac -ac_cv_var_tickadj_nano=$ans]) -case "$ac_cv_var_tickadj_nano" in + +AC_CACHE_CHECK( + [for the units of 'tickadj'], + [ntp_cv_tickadj_nano], + [ + ans=usec + case "$host" in + *-*-solaris2*) + ans=nsec + ;; + esac + ntp_cv_tickadj_nano=$ans + ] +) +case "$ntp_cv_tickadj_nano" in nsec) - AC_DEFINE(TICKADJ_NANO, 1, [Is K_TICKADJ_NAME in nanoseconds?]) - ;; + AC_DEFINE([TICKADJ_NANO], [1], [Is K_TICKADJ_NAME in nanoseconds?]) esac -# -AC_CACHE_CHECK([half-heartedly for 'dosynctodr' in the kernel], -ac_cv_var_nlist_dosynctodr, -[case "$host" in - *-apple-aux[[23]]*) - ans=no - ;; - *-sni-sysv*) - ans=dosynctodr - ;; - *-*-aix*) - ans=dosynctodr - ;; - *-*-hpux*) - ans=no - ;; - *-*-mpeix*) - ans=no - ;; - *-*-nextstep*) - ans=_dosynctodr - ;; - *-*-ptx*) - ans=doresettodr - ;; - *-*-sco3.2v4*) - ans=no - ;; - *-*-sco3.2v5*) - ans=track_rtc - ;; - *-*-solaris2*) - ans=dosynctodr - ;; - *-*-sysv4*) - ans=doresettodr + +AC_CACHE_CHECK( + [half-heartedly for 'dosynctodr' in the kernel], + [ntp_cv_nlist_dosynctodr], + [ + case "$host" in + *-apple-aux[[23]]*) + ans=no + ;; + *-sni-sysv*) + ans=dosynctodr + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix*) + ans=dosynctodr + ;; + *-*-hpux*) + ans=no + ;; + *-*-mpeix*) + ans=no + ;; + *-*-nextstep*) + ans=_dosynctodr + ;; + *-*-ptx*) + ans=doresettodr + ;; + *-*-sco3.2v4*) + ans=no + ;; + *-*-sco3.2v5*) + ans=track_rtc + ;; + *-*-solaris2*) + ans=dosynctodr + ;; + *-*-sysv4*) + ans=doresettodr + ;; + *) + ans=_dosynctodr + ;; + esac + ntp_cv_nlist_dosynctodr=$ans + ] +) +case "$ntp_cv_nlist_dosynctodr" in + no) ;; *) - ans=_dosynctodr + AC_DEFINE_UNQUOTED([K_DOSYNCTODR_NAME], ["$ntp_cv_nlist_dosynctodr"], + [What is (probably) the name of DOSYNCTODR in the kernel?]) ;; esac -ac_cv_var_nlist_dosynctodr=$ans]) -case "$ac_cv_var_nlist_dosynctodr" in - no) ;; - *) AC_DEFINE_UNQUOTED(K_DOSYNCTODR_NAME, "$ac_cv_var_nlist_dosynctodr", [What is (probably) the name of DOSYNCTODR in the kernel?]) - ;; -esac -# -AC_CACHE_CHECK([half-heartedly for 'noprintf' in the kernel], -ac_cv_var_nlist_noprintf, -[case "$host" in - *-apple-aux[[23]]*) - ans=no - ;; - *-sni-sysv*) - ans=noprintf - ;; - *-*-aix*) - ans=noprintf - ;; - *-*-hpux*) - ans=no - ;; - *-*-mpeix*) - ans=no - ;; - *-*-ptx*) - ans=noprintf - ;; - *-*-nextstep*) - ans=_noprintf - ;; - *-*-solaris2*) - ans=noprintf - ;; - *-*-sysv4*) - ans=noprintf + +AC_CACHE_CHECK( + [half-heartedly for 'noprintf' in the kernel], + [ntp_cv_nlist_noprintf], + [ + case "$host" in + *-apple-aux[[23]]*) + ans=no + ;; + *-sni-sysv*) + ans=noprintf + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix*) + ans=noprintf + ;; + *-*-hpux*) + ans=no + ;; + *-*-mpeix*) + ans=no + ;; + *-*-ptx*) + ans=noprintf + ;; + *-*-nextstep*) + ans=_noprintf + ;; + *-*-solaris2*) + ans=noprintf + ;; + *-*-sysv4*) + ans=noprintf + ;; + *) + ans=_noprintf + ;; + esac + ntp_cv_nlist_noprintf=$ans + ] +) +case "$ntp_cv_nlist_noprintf" in + no) ;; *) - ans=_noprintf + AC_DEFINE_UNQUOTED([K_NOPRINTF_NAME], ["$ntp_cv_nlist_noprintf"], + [What is (probably) the name of NOPRINTF in the kernel?]) ;; esac -ac_cv_var_nlist_noprintf=$ans]) -case "$ac_cv_var_nlist_noprintf" in - no) ;; - *) AC_DEFINE_UNQUOTED(K_NOPRINTF_NAME, "$ac_cv_var_nlist_noprintf", [What is (probably) the name of NOPRINTF in the kernel?]) - ;; -esac dnl The tick/tickadj sections were written by Skippy, who never learned dnl that it's impolite (horridly gross) to show your guts in public. -dnl tick tickadj +dnl tick tickadj dnl 10000 80 Unixware dnl 1000000L/hz tick/16 (Solaris,UXPV,HPUX) && ADJTIME_IS_ACCURATE dnl 10000 150 sgi IRIX @@ -3705,37 +3552,34 @@ esac AC_ARG_ENABLE( [tick], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-tick=VALUE], [s force a value for 'tick'] - ), + )], [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ans" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) AC_DEFINE_UNQUOTED(PRESET_TICK, [$ans], [Preset a value for 'tick'?]) ;; + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) + AC_DEFINE_UNQUOTED([PRESET_TICK], [$ans], + [Preset a value for 'tick'?]) esac - AC_MSG_CHECKING([for a default value for 'tickadj']) # target-specific default - ans='500/hz' - case "$host" in *-fujitsu-uxp*) case "$adjtime_is_accurate" in yes) - ans='tick/16' + ans='tick/16' esac ;; - XXX-*-pc-cygwin*) - ans=no - ;; *-univel-sysv*) ans=80 ;; @@ -3743,18 +3587,21 @@ case "$host" in case "$can_kmem" in no) ans=1000 + ;; esac ;; *-*-domainos) # Skippy: won't be found... case "$can_kmem" in no) ans=668 + ;; esac ;; *-*-hpux*) case "$adjtime_is_accurate" in yes) ans='tick/16' + ;; esac ;; *-*-irix*) @@ -3771,14 +3618,15 @@ case "$host" in ;; *-*-unicosmp*) ans=150 + ;; esac AC_ARG_ENABLE( [tickadj], - AC_HELP_STRING( - [--enable-tickadj=VALUE], - [s force a value for 'tickadj'] - ), + [AS_HELP_STRING( + [--enable-tickadj=VALUE], + [s force a value for 'tickadj'] + )], [ans=$enableval] ) @@ -3787,8 +3635,11 @@ AC_MSG_RESULT([$ans]) default_tickadj=$ans case "$default_tickadj" in - ''|no) ;; # HMS: I think we can only get 'no' here... - *) AC_DEFINE_UNQUOTED(PRESET_TICKADJ, $default_tickadj, [Preset a value for 'tickadj'?]) ;; + ''|no) + ;; # HMS: I think we can only get 'no' here... + *) + AC_DEFINE_UNQUOTED([PRESET_TICKADJ], [$default_tickadj], + [Preset a value for 'tickadj'?]) ;; esac # Newer versions of ReliantUNIX round adjtime() values down to @@ -3796,26 +3647,29 @@ esac # Unfortunately, there is no easy way to know if particular release # has this "feature" or any obvious way to test for it. case "$host" in - mips-sni-sysv4*) AC_DEFINE(RELIANTUNIX_CLOCK, 1, [Do we want the ReliantUNIX clock hacks?]) ;; + mips-sni-sysv4*) + AC_DEFINE([RELIANTUNIX_CLOCK], [1], + [Do we want the ReliantUNIX clock hacks?]) esac case "$host" in - *-*-sco3.2v5*) AC_DEFINE(SCO5_CLOCK, 1, [Do we want the SCO clock hacks?]) ;; + *-*-sco3.2v5*) + AC_DEFINE([SCO5_CLOCK], [1], [Do we want the SCO clock hacks?]) esac -ac_cv_make_tickadj=yes +ntp_cv_make_tickadj=yes case "$can_kmem$ac_cv_var_tick$default_tickadj" in nonono) # Don't read KMEM, no presets. Bogus. AC_MSG_WARN([Can't read kmem, no PRESET_TICK or PRESET_TICKADJ. No tickadj.]) - ac_cv_make_tickadj=no + ntp_cv_make_tickadj=no ;; nono*) # Don't read KMEM, no PRESET_TICK but PRESET_TICKADJ. Bogus. AC_MSG_WARN([Can't read kmem but no PRESET_TICK. No tickadj.]) - ac_cv_make_tickadj=no + ntp_cv_make_tickadj=no ;; no*no) # Don't read KMEM, PRESET_TICK but no PRESET_TICKADJ. Bogus. AC_MSG_WARN([Can't read kmem but no PRESET_TICKADJ. No tickadj.]) - ac_cv_make_tickadj=no + ntp_cv_make_tickadj=no ;; no*) # Don't read KMEM, PRESET_TICK and PRESET_TICKADJ. Cool. ;; @@ -3836,7 +3690,7 @@ esac AC_SUBST(MAKE_NTPTIME) AC_CACHE_CHECK([if we want and can make the ntptime utility], ac_cv_make_ntptime, [case "$host" in - *) case "$ac_cv_struct_ntptimeval$ac_cv_var_kernel_pll" in + *) case "$ntp_cv_struct_ntptimeval$ntp_cv_var_kernel_pll" in yesyes) ans=yes ;; @@ -3851,91 +3705,123 @@ case "$ac_cv_make_ntptime" in yes) MAKE_NTPTIME=ntptime ;; + *) + NTPTIME_DB= + NTPTIME_DL= + NTPTIME_DS= + NTPTIME_MS= + ;; esac -AC_SUBST(MAKE_TICKADJ) +AC_SUBST([MAKE_TICKADJ]) case "$host" in mips-sni-sysv4*) # tickadj is pretty useless on newer versions of ReliantUNIX # Do not bother - ac_cv_make_tickadj=no + ntp_cv_make_tickadj=no ;; *-*-irix*) - ac_cv_make_tickadj=no + ntp_cv_make_tickadj=no ;; *-*-solaris2*) # DLM says tickadj is a no-no starting with solaris2.5 case "$host" in *-*-solaris2.1[[0-9]]*) - ac_cv_make_tickadj=no + ntp_cv_make_tickadj=no ;; *-*-solaris2.[[0-4]]*) ;; - *) ac_cv_make_tickadj=no ;; + *) ntp_cv_make_tickadj=no ;; esac ;; *-*-unicosmp*) - ac_cv_make_tickadj=no + ntp_cv_make_tickadj=no ;; esac # # Despite all the above, we always make tickadj. Setting -# ac_cv_make_tickadj before AC_CACHE_CHECK will cause a false +# ntp_cv_make_tickadj before AC_CACHE_CHECK will cause a false # report that the configuration variable was cached. It may # be better to simply remove the hunk above, I did not want # to remove it if there is hope it will be used again. # -unset ac_cv_make_tickadj +AS_UNSET([ntp_cv_make_tickadj]) -AC_CACHE_CHECK([if we want and can make the tickadj utility], ac_cv_make_tickadj, -ac_cv_make_tickadj=yes) -case "$ac_cv_make_tickadj" in +AC_CACHE_CHECK( + [if we want and can make the tickadj utility], + [ntp_cv_make_tickadj], + [ntp_cv_make_tickadj=yes] +) +case "$ntp_cv_make_tickadj" in yes) MAKE_TICKADJ=tickadj ;; -esac - -AC_SUBST(MAKE_TIMETRIM) -AC_CACHE_CHECK([if we want and can make the timetrim utility], ac_cv_make_timetrim, -[case "$host" in - *-*-irix*) - ac_cv_make_timetrim=yes - ;; - *-*-unicosmp*) - ac_cv_make_timetrim=yes - ;; *) - ac_cv_make_timetrim=no + CALC_TICKADJ_DB= + CALC_TICKADJ_DL= + CALC_TICKADJ_DS= + CALC_TICKADJ_MS= + TICKADJ_DB= + TICKADJ_DL= + TICKADJ_DS= + TICKADJ_MS= ;; -esac]) -case "$ac_cv_make_timetrim" in +esac + +AC_SUBST([MAKE_TIMETRIM]) +AC_CACHE_CHECK( + [if we want and can make the timetrim utility], + [ntp_cv_make_timetrim], + [ + case "$host" in + *-*-irix*) + ntp_cv_make_timetrim=yes + ;; + *-*-unicosmp*) + ntp_cv_make_timetrim=yes + ;; + *) + ntp_cv_make_timetrim=no + ;; + esac + ] +) +case "$ntp_cv_make_timetrim" in yes) MAKE_TIMETRIM=timetrim ;; + *) TIMETRIM_DB= + TIMETRIM_DL= + TIMETRIM_DS= + TIMETRIM_MS= + ;; esac -AC_SUBST(MAKE_LIBNTPSIM) -AC_SUBST(MAKE_NTPDSIM) +AC_SUBST([MAKE_LIBNTPSIM]) +AC_SUBST([MAKE_NTPDSIM]) AC_MSG_CHECKING([if we want to build the NTPD simulator]) - AC_ARG_ENABLE( [simulator], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-simulator], [- build/install the NTPD simulator?] - ), - [ans=$enableval], + )], + [ans=$enableval], [ans=no] ) - AC_MSG_RESULT([$ans]) - case "$ans" in yes) MAKE_NTPDSIM=ntpdsim MAKE_LIBNTPSIM=libntpsim.a ;; + *) + NTPDSIM_DB= + NTPDSIM_DL= + NTPDSIM_DS= + NTPDSIM_MS= + ;; esac case "$build" in @@ -3949,6 +3835,101 @@ case "$build" in ;; esac +NTP_WITHSNTP + +AC_MSG_CHECKING([if we want to build ntpsnmpd]) +AC_ARG_WITH( + [ntpsnmpd], + [AS_HELP_STRING( + [--with-ntpsnmpd], + [s Build ntpsnmpd MIB agent?] + )], + [ans=$withval], + [ + case "$PATH_NET_SNMP_CONFIG" in + /*) ans=yes ;; + *) ans=no ;; + esac + ] +) +AC_MSG_RESULT([$ans]) +case "$ans" in + yes) + case "$PATH_NET_SNMP_CONFIG" in + /*) + SNMP_LIBS=`$PATH_NET_SNMP_CONFIG --agent-libs` + # Bug 2815. This is a bit of a hack, but it works... + case "$ntp_cv_net_snmp_version" in + 5.3*) SNMP_LIBS=`echo $SNMP_LIBS | $SED -e 's/-lnetsnmpagent/-lnetsnmpagent -lnetsnmpmibs/'` + ;; + esac + AC_SUBST([SNMP_LIBS]) + # HMS: we really want to separate CPPFLAGS and CFLAGS + foo=`$PATH_NET_SNMP_CONFIG --cflags` + SNMP_CPPFLAGS= + SNMP_CFLAGS= + for i in $foo; do + case "$i" in + -D*|-U*|-I*) + SNMP_CPPFLAGS="$SNMP_CPPFLAGS $i" + ;; + *) SNMP_CFLAGS="$SNMP_CFLAGS $i" + ;; + esac + done + AC_SUBST([SNMP_CPPFLAGS]) + AC_SUBST([SNMP_CFLAGS]) + + save_CFLAGS=$CFLAGS + save_CPPFLAGS=$CPPFLAGS + save_LIBS=$LIBS + CFLAGS=$SNMP_CFLAGS + CPPFLAGS=$SNMP_CPPFLAGS + + AC_CHECK_HEADER( + [net-snmp/net-snmp-config.h], + [MAKE_NTPSNMPD=ntpsnmpd], + [AC_MSG_WARN([net-snmp-config present but net-snmp headers are not available!])] + ) + + # Do this last, as we're messing up LIBS. + # check -lnetsnmp for netsnmp_daemonize + LIBS=`$PATH_NET_SNMP_CONFIG --libs` + AC_CHECK_LIB( + [netsnmp], + [netsnmp_daemonize], + [ans=yes], + [ans=no] + ) + case "$ans" in + no) + AC_DEFINE([NEED_NETSNMP_DAEMONIZE], [1], + [We need to provide netsnmp_daemonize()]) + esac + + CFLAGS=$save_CFLAGS + AS_UNSET([save_CFLAGS]) + CPPFLAGS=$save_CPPFLAGS + AS_UNSET([save_CPPFLAGS]) + LIBS=$save_LIBS + AS_UNSET([save_LIBS]) + ;; + *) + AC_MSG_WARN([Cannot build ntpsnmpd - net-snmp-config cannot be found]) + ;; + esac + ;; +esac +AC_SUBST([MAKE_NTPSNMPD]) + +case "$MAKE_NTPSNMPD" in + '') + NTPSNMPD_DB= + NTPSNMPD_DL= + NTPSNMPD_DS= + NTPSNMPD_MS= + ;; +esac AC_MSG_CHECKING([if we should always slew the time]) @@ -3975,17 +3956,18 @@ esac AC_ARG_ENABLE( [slew-always], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-slew-always], [s always slew the time] - ), + )], [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ans" in - yes) AC_DEFINE(SLEWALWAYS, 1, [Slew always?]) ;; + yes) + AC_DEFINE([SLEWALWAYS], [1], [Slew always?]) esac AC_MSG_CHECKING([if we should step and slew the time]) @@ -3994,6 +3976,9 @@ case "$host" in *-sni-sysv*) ans=yes ;; + *-stratus-vos) + ans=no + ;; *-univel-sysv*) ans=no ;; @@ -4013,20 +3998,20 @@ case "$host" in ;; esac - AC_ARG_ENABLE( [step-slew], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-step-slew], [s step and slew the time] - ), + )], [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ans" in - yes) AC_DEFINE(STEP_SLEW, 1, [Step, then slew the clock?]) ;; + yes) + AC_DEFINE([STEP_SLEW], [1], [Step, then slew the clock?]) esac AC_MSG_CHECKING([if ntpdate should step the time]) @@ -4036,21 +4021,24 @@ case "$host" in ans=yes ;; *) ans=no + ;; esac AC_ARG_ENABLE( [ntpdate-step], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-ntpdate-step], [s if ntpdate should step the time] - ), + )], [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ans" in - yes) AC_DEFINE(FORCE_NTPDATE_STEP, 1, [force ntpdate to step the clock if !defined(STEP_SLEW) ?]) ;; + yes) + AC_DEFINE([FORCE_NTPDATE_STEP], [1], + [force ntpdate to step the clock if !defined(STEP_SLEW) ?]) esac @@ -4065,21 +4053,23 @@ case "$host" in ;; *) ans=no + ;; esac AC_ARG_ENABLE( [hourly-todr-sync], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-hourly-todr-sync], [s if we should sync TODR hourly] - ), + )], [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ac_cv_var_sync_todr" in - yes) AC_DEFINE(DOSYNCTODR, 1, [synch TODR hourly?]) ;; + yes) + AC_DEFINE([DOSYNCTODR], [1], [synch TODR hourly?]) ;; esac @@ -4102,8 +4092,9 @@ case "$host" in ans=yes fi ;; - *) + *) ans=yes + ;; esac ;; *-*-solaris2.7) @@ -4124,25 +4115,46 @@ case "$host" in ;; *) ans=yes + ;; esac ;; *) ans=no + ;; esac AC_ARG_ENABLE( [kernel-fll-bug], - AC_HELP_STRING( + [AS_HELP_STRING( [--enable-kernel-fll-bug], [s if we should avoid a kernel FLL bug] - ), + )], [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ans" in - yes) AC_DEFINE(KERNEL_FLL_BUG, 1, [Does the kernel have an FLL bug?]) ;; + yes) + AC_DEFINE([KERNEL_FLL_BUG], [1], [Does the kernel have an FLL bug?]) +esac + + +AC_MSG_CHECKING([if we want new session key behavior]) +AC_ARG_ENABLE( + [bug1243-fix], + [AS_HELP_STRING( + [--enable-bug1243-fix], + [+ use unmodified autokey session keys] + )], + [ans=$enableval], + [ans=yes] +) +AC_MSG_RESULT([$ans]) +case "$ans" in + no) + AC_DEFINE([DISABLE_BUG1243_FIX], [1], + [use old autokey session key behavior?]) esac @@ -4156,32 +4168,33 @@ case "$host" in ans=yes ;; *) ans=no + ;; esac AC_ARG_ENABLE( - [irig-sawtooth], - AC_HELP_STRING( + [irig-sawtooth], + [AS_HELP_STRING( [--enable-irig-sawtooth], [s if we should enable the IRIG sawtooth filter] - ), + )], [ans=$enableval] ) AC_MSG_RESULT([$ans]) case "$ans" in - yes) AC_DEFINE(IRIG_SUCKS, 1, [Should we use the IRIG sawtooth filter?]) ;; + yes) + AC_DEFINE([IRIG_SUCKS], [1], + [Should we use the IRIG sawtooth filter?]) esac - AC_MSG_CHECKING([if we should enable NIST lockclock scheme]) - AC_ARG_ENABLE( - [nist], - AC_HELP_STRING( + [nist], + [AS_HELP_STRING( [--enable-nist], [- if we should enable the NIST lockclock scheme] - ), + )], [ans=$enableval], [ans=no] ) @@ -4189,18 +4202,18 @@ AC_ARG_ENABLE( AC_MSG_RESULT([$ans]) case "$ans" in - yes) AC_DEFINE(LOCKCLOCK, 1, [Should we align with the NIST lockclock scheme?]) ;; + yes) + AC_DEFINE([LOCKCLOCK], [1], + [Should we align with the NIST lockclock scheme?]) ;; esac - AC_MSG_CHECKING([if we want support for Samba's signing daemon]) - AC_ARG_ENABLE( [ntp-signd], - AC_HELP_STRING( - [--enable-ntp-signd], - [- Provide support for Samba's signing daemon, =/var/run/ntp_signd] - ), + [AS_HELP_STRING( + [--enable-ntp-signd], + [- Provide support for Samba's signing daemon, =/var/run/ntp_signd] + )], [ans=$enableval], [ans=no] ) @@ -4220,448 +4233,168 @@ esac case "$ntp_signd_path" in '') - wintime_default=no ;; *) - wintime_default=yes - AC_DEFINE(HAVE_NTP_SIGND, ,[Do we want support for Samba's signing daemon?]) - AC_DEFINE_UNQUOTED(NTP_SIGND_PATH, "$ntp_signd_path", [Path to sign daemon rendezvous socket]) -esac - - -AC_MSG_CHECKING([if we want the windows symmetric client hack]) - -# default is no, unless --enable-ntp-signd was given -ans=$wintime_default -unset wintime_default - -AC_ARG_ENABLE( - [wintime], - AC_HELP_STRING( - [--enable-wintime], - [- Provide the windows symmetric client hack] - ), - [ans=$enableval], -) - -AC_MSG_RESULT([$ans]) - -case "$ans" in - yes) - AC_DEFINE(WINTIME, ,[Do we want the windows symmetric client hack?]) -esac - - -AC_CHECK_HEADERS(sys/clockctl.h) - -case "$host" in - *-*-netbsd*) - ans=yes - ;; - *) ans=no - ;; -esac - -AC_ARG_ENABLE( - [clockctl], - AC_HELP_STRING( - [--enable-clockctl], - [s Use /dev/clockctl for non-root clock control] - ), - [ntp_use_dev_clockctl=$enableval], - [ntp_use_dev_clockctl=$ac_cv_header_sys_clockctl_h] -) - -AC_MSG_CHECKING([[if we should use /dev/clockctl]]) -AC_MSG_RESULT([$ntp_use_dev_clockctl]) - - -AC_CHECK_HEADERS([sys/capability.h]) -AC_CHECK_HEADERS([sys/prctl.h]) - -AC_MSG_CHECKING([[if we have linux capabilities (libcap)]]) - -case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in - yesyes) - ntp_have_linuxcaps=yes + AC_DEFINE([HAVE_NTP_SIGND], [1], + [Do we want support for Samba's signing daemon?]) + AC_DEFINE_UNQUOTED([NTP_SIGND_PATH], ["$ntp_signd_path"], + [Path to sign daemon rendezvous socket]) ;; - *) - ntp_have_linuxcaps=no -esac - -AC_MSG_RESULT([$ntp_have_linuxcaps]) - - -AC_ARG_ENABLE( - [linuxcaps], - AC_HELP_STRING( - [--enable-linuxcaps], - [+ Use Linux capabilities for non-root clock control] - ), - [ntp_have_linuxcaps=$enableval] -) - - -case "$ntp_have_linuxcaps" in - yes) - AC_DEFINE(HAVE_LINUX_CAPABILITIES, ,[[Do we have Linux capabilities?]]) - LIBS="$LIBS -lcap" -esac - - -case "$ntp_use_dev_clockctl$ntp_have_linuxcaps" in - *yes*) - AC_DEFINE(HAVE_DROPROOT, ,[[Can we drop root privileges?]]) esac - AC_CHECK_HEADERS([libscf.h]) - +LSCF= case "$ac_cv_header_libscf_h" in yes) - AC_SUBST(LSCF, [-lscf]) + LSCF='-lscf' esac +AC_SUBST([LSCF]) -AC_CHECK_FUNC( - [setppriv], - AC_DEFINE(HAVE_SOLARIS_PRIVS, ,[[Are Solaris privileges available?]]) -) +NTP_IPV6 # -# ISC stuff +# Look for a sysctl call to get the list of network interfaces. # - -if test $ac_cv_struct_sockaddr_has_sa_len = yes; then - AC_DEFINE(ISC_PLATFORM_HAVESALEN, ,[ISC: struct sockaddr as sa_len?]) -fi - -AC_ARG_ENABLE(ipv6, AC_HELP_STRING([--enable-ipv6], [s use IPv6?])) - -case "$enable_ipv6" in - yes|''|autodetect) - case "$host" in - powerpc-ibm-aix4*) ;; - *) - AC_DEFINE(WANT_IPV6, ,[configure --enable-ipv6]) - ;; - esac - ;; - no) - ;; -esac - - AC_CACHE_CHECK( - [for IPv6 structures], - ac_cv_isc_found_ipv6, - [ - AC_COMPILE_IFELSE( - [ - AC_LANG_PROGRAM( - [ - #include - #include - #include - ], - [ - struct sockaddr_in6 sin6; - ] - ) - ], - [ac_cv_isc_found_ipv6=yes], - [ac_cv_isc_found_ipv6=no] - ) - ] + [for interface list sysctl], + [ntp_cv_iflist_sysctl], + [AC_PREPROC_IFELSE( + [AC_LANG_SOURCE([ + #include + #include + #include + #ifndef NET_RT_IFLIST + # error + #endif + ])], + [ntp_cv_iflist_sysctl=yes], + [ntp_cv_iflist_sysctl=no] + )] ) - -# -# See whether IPv6 support is provided via a Kame add-on. -# This is done before other IPv6 linking tests so LIBS is properly set. -# -AC_MSG_CHECKING([for Kame IPv6 support]) -AC_ARG_WITH(kame, - [AC_HELP_STRING([--with-kame], [- =/usr/local/v6])], - use_kame="$withval", use_kame="no") - -case "$use_kame" in - no) - ;; - yes) - kame_path=/usr/local/v6 - ;; - *) - kame_path="$use_kame" - ;; -esac - -case "$use_kame" in - no) - AC_MSG_RESULT(no) - ;; - *) - if test -f $kame_path/lib/libinet6.a; then - AC_MSG_RESULT($kame_path/lib/libinet6.a) - LIBS="-L$kame_path/lib -linet6 $LIBS" - else - AC_MSG_ERROR([$kame_path/lib/libinet6.a not found. - -Please choose the proper path with the following command: - - configure --with-kame=PATH -]) - fi - ;; -esac - -# -# Whether netinet6/in6.h is needed has to be defined in isc/platform.h. -# Including it on Kame-using platforms is very bad, though, because -# Kame uses #error against direct inclusion. So include it on only -# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1. -# This is done before the in6_pktinfo check because that's what -# netinet6/in6.h is needed for. -# -case "$host" in - *-bsdi4.[[01]]*) - AC_DEFINE(ISC_PLATFORM_NEEDNETINET6IN6H, 1, [Do we need netinet6/in6.h?]) - isc_netinet6in6_hack="#include " - ;; - *) - isc_netinet6in6_hack="" -esac - -# -# This is similar to the netinet6/in6.h issue. -# -case "$host" in - *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) - AC_DEFINE(ISC_PLATFORM_FIXIN6ISADDR, 1,[Do we need to fix in6isaddr?]) - isc_netinetin6_hack="#include " - ;; - *) - isc_netinetin6_hack="" -esac - - -case "$ac_cv_isc_found_ipv6" in +case "$ntp_cv_iflist_sysctl" in yes) - AC_DEFINE(ISC_PLATFORM_HAVEIPV6, ,[have IPv6?]) - - AC_CACHE_CHECK( - [for in6_pktinfo], - ac_cv_have_in6_pktinfo, - [ - AC_COMPILE_IFELSE( - [ - AC_LANG_PROGRAM( - [ - #include - #include - #include - $isc_netinetin6_hack - $isc_netinet6in6_hack - ], - [ - struct in6_pktinfo xyzzy; - ] - ) - ], - [ac_cv_have_in6_pktinfo=yes], - [ac_cv_have_in6_pktinfo=no] - ) - ] - ) - - case "$ac_cv_have_in6_pktinfo" in - yes) - AC_DEFINE(ISC_PLATFORM_HAVEIN6PKTINFO, , [have struct in6_pktinfo?]) - esac - - - # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead? - AC_CACHE_CHECK( - [for sockaddr_in6.sin6_scope_id], - ac_cv_have_sin6_scope_id, - [ - AC_COMPILE_IFELSE( - [ - AC_LANG_PROGRAM( - [ - #include - #include - #include - $isc_netinetin6_hack - $isc_netinet6in6_hack - ], - [ - struct sockaddr_in6 xyzzy; - xyzzy.sin6_scope_id = 0; - ] - ) - ], - [ac_cv_have_sin6_scope_id=yes], - [ac_cv_have_sin6_scope_id=no] - ) - ] - ) - - case "$ac_cv_have_sin6_scope_id" in - yes) - AC_DEFINE(ISC_PLATFORM_HAVESCOPEID, , [have sin6_scope_id?]) - esac -esac - - -# We need this check run even without ac_cv_isc_found_ipv6=yes - -AC_CACHE_CHECK( - [for in6addr_any], - ac_cv_have_in6addr_any, - [ - AC_COMPILE_IFELSE( - [ - AC_LANG_PROGRAM( - [ - #include - #include - #include - $isc_netinetin6_hack - $isc_netinet6in6_hack - ], - [ - struct in6_addr in6; - in6 = in6addr_any; - ] - ) - ], - [ac_cv_have_in6addr_any=yes], - [ac_cv_have_in6addr_any=no] - ) - ] -) - -case "$ac_cv_have_in6addr_any" in - no) - AC_DEFINE(ISC_PLATFORM_NEEDIN6ADDRANY, , [missing in6addr_any?]) + AC_DEFINE([HAVE_IFLIST_SYSCTL], [1], [have iflist_sysctl?]) esac +### -AC_CACHE_CHECK( - [for struct if_laddrconf], - ac_cv_isc_struct_if_laddrconf, - [ - AC_COMPILE_IFELSE( - [ - AC_LANG_PROGRAM( - [ - #include - #include - ], - [ - struct if_laddrconf a; - ] - ) - ], - [ac_cv_isc_struct_if_laddrconf=yes], - [ac_cv_isc_struct_if_laddrconf=no] - ) - ] +AC_MSG_CHECKING([if we want the saveconfig mechanism]) +AC_ARG_ENABLE( + [saveconfig], + [AS_HELP_STRING( + [--enable-saveconfig], + [+ saveconfig mechanism] + )], + [ntp_ok=$enableval], + [ntp_ok=yes] ) - -case "$ac_cv_isc_struct_if_laddrconf" in +ntp_saveconfig_enabled=0 +case "$ntp_ok" in yes) - AC_DEFINE(ISC_PLATFORM_HAVEIF_LADDRCONF, , [have struct if_laddrconf?]) + ntp_saveconfig_enabled=1 + AC_DEFINE([SAVECONFIG], [1], [saveconfig mechanism]) + ;; esac +AM_CONDITIONAL([SAVECONFIG_ENABLED], [test x$ntp_saveconfig_enabled = x1]) +AC_MSG_RESULT([$ntp_ok]) -AC_CACHE_CHECK( - [for struct if_laddrreq], - ac_cv_isc_struct_if_laddrreq, - [ - AC_COMPILE_IFELSE( - [ - AC_LANG_PROGRAM( - [ - #include - #include - ], - [ - struct if_laddrreq a; - ] - ) - ], - [ac_cv_isc_struct_if_laddrreq=yes], - [ac_cv_isc_struct_if_laddrreq=no] - ) - ] -) +### -case "$ac_cv_isc_struct_if_laddrreq" in +AC_MSG_CHECKING([if we want the experimental leap smear code]) +AC_ARG_ENABLE( + [leap-smear], + [AS_HELP_STRING( + [--enable-leap-smear], + [- experimental leap smear code] + )], + [ntp_ok=$enableval], + [ntp_ok=no] +) +ntp_leap_smear_enabled=0 +case "$ntp_ok" in yes) - AC_DEFINE(ISC_PLATFORM_HAVEIF_LADDRREQ, , [have struct if_laddrreq?]) + ntp_leap_smear_enabled=1 + AC_DEFINE([LEAP_SMEAR], [1], [leap smear mechanism]) + AC_SUBST([HAVE_LEAPSMEARINTERVAL]) + HAVE_LEAPSMEARINTERVAL="leapsmearinterval 0" + ;; esac +AC_MSG_RESULT([$ntp_ok]) -# -# Look for a sysctl call to get the list of network interfaces. -# -AC_CACHE_CHECK( - [for interface list sysctl], - ac_cv_iflist_sysctl, - AC_EGREP_CPP( - [found_rt_iflist], - [ - #include - #include - #include - #ifdef NET_RT_IFLIST - found_rt_iflist - #endif - ], - [ac_cv_iflist_sysctl=yes], - [ac_cv_iflist_sysctl=no] - ) -) +NTP_UNITYBUILD -case "$ac_cv_iflist_sysctl" in - yes) - AC_DEFINE(HAVE_IFLIST_SYSCTL,1,[have iflist_sysctl?]) -esac +dnl gtest is needed for our tests subdirs. It would be nice if we could +dnl require a C++ compiler only if we will use gtest, but AC_PROG_CXX +dnl can't be conditionalized. +NTP_GOOGLETEST +NTP_PROBLEM_TESTS ### -AC_DEFINE_DIR(NTP_KEYSDIR, sysconfdir, [Default location of crypto key info]) - -AC_CONFIG_FILES(Makefile) -AC_CONFIG_FILES(ElectricFence/Makefile) -AC_CONFIG_FILES(adjtimed/Makefile) -AC_CONFIG_FILES(clockstuff/Makefile) -AC_CONFIG_FILES(include/Makefile) -AC_CONFIG_FILES(include/isc/Makefile) -AC_CONFIG_FILES(kernel/Makefile) -AC_CONFIG_FILES(kernel/sys/Makefile) -AC_CONFIG_FILES(libntp/Makefile) -AC_CONFIG_FILES(libparse/Makefile) -AC_CONFIG_FILES(ntpd/Makefile) -AC_CONFIG_FILES(ntpdate/Makefile) -AC_CONFIG_FILES(ntpdc/Makefile) -AC_CONFIG_FILES(ntpdc/nl.pl, [chmod +x ntpdc/nl.pl]) -AC_CONFIG_FILES(ntpq/Makefile) -AC_CONFIG_FILES(parseutil/Makefile) -AC_CONFIG_FILES(scripts/Makefile) -AC_CONFIG_FILES(scripts/calc_tickadj, [chmod +x scripts/calc_tickadj]) -AC_CONFIG_FILES(scripts/checktime, [chmod +x scripts/checktime]) -AC_CONFIG_FILES(scripts/freq_adj, [chmod +x scripts/freq_adj]) -AC_CONFIG_FILES(scripts/html2man, [chmod +x scripts/html2man]) -AC_CONFIG_FILES(scripts/mkver, [chmod +x scripts/mkver]) -AC_CONFIG_FILES(scripts/ntp-wait, [chmod +x scripts/ntp-wait]) -AC_CONFIG_FILES(scripts/ntpsweep, [chmod +x scripts/ntpsweep]) -AC_CONFIG_FILES(scripts/ntptrace, [chmod +x scripts/ntptrace]) -AC_CONFIG_FILES(scripts/ntpver, [chmod +x scripts/ntpver]) -AC_CONFIG_FILES(scripts/plot_summary, [chmod +x scripts/plot_summary]) -AC_CONFIG_FILES(scripts/summary, [chmod +x scripts/summary]) -AC_CONFIG_FILES(util/Makefile) - -AC_CONFIG_SUBDIRS(sntp) +AC_DEFINE_DIR([NTP_KEYSDIR], [sysconfdir], + [Default location of crypto key info]) + +AC_CONFIG_FILES([Makefile]) +AC_CONFIG_FILES([adjtimed/Makefile]) +AC_CONFIG_FILES([clockstuff/Makefile]) +AC_CONFIG_FILES([include/Makefile]) +AC_CONFIG_FILES([include/isc/Makefile]) +AC_CONFIG_FILES([kernel/Makefile]) +AC_CONFIG_FILES([kernel/sys/Makefile]) +AC_CONFIG_FILES([libntp/Makefile]) +AC_CONFIG_FILES([libparse/Makefile]) +AC_CONFIG_FILES([ntpd/Makefile]) +AC_CONFIG_FILES([ntpd/complete.conf], [sed -e '/^rlimit$/d' -e '/^$/d' < ntpd/complete.conf > ntpd/complete.conf.new && mv ntpd/complete.conf.new ntpd/complete.conf]) +AC_CONFIG_FILES([ntpdate/Makefile]) +AC_CONFIG_FILES([ntpdc/Makefile]) +AC_CONFIG_FILES([ntpdc/nl.pl], [chmod +x ntpdc/nl.pl]) +AC_CONFIG_FILES([ntpq/Makefile]) +AC_CONFIG_FILES([ntpsnmpd/Makefile]) +AC_CONFIG_FILES([parseutil/Makefile]) +AC_CONFIG_FILES([scripts/Makefile]) +AC_CONFIG_FILES([scripts/build/Makefile]) +AC_CONFIG_FILES([scripts/build/mkver], [chmod +x scripts/build/mkver]) +AC_CONFIG_FILES([scripts/calc_tickadj/Makefile]) +AC_CONFIG_FILES([scripts/calc_tickadj/calc_tickadj], [chmod +x scripts/calc_tickadj/calc_tickadj]) +AC_CONFIG_FILES([scripts/lib/Makefile]) +AC_CONFIG_FILES([scripts/ntp-wait/Makefile]) +AC_CONFIG_FILES([scripts/ntp-wait/ntp-wait], [chmod +x scripts/ntp-wait/ntp-wait]) +AC_CONFIG_FILES([scripts/ntpsweep/Makefile]) +AC_CONFIG_FILES([scripts/ntpsweep/ntpsweep], [chmod +x scripts/ntpsweep/ntpsweep]) +AC_CONFIG_FILES([scripts/ntptrace/Makefile]) +AC_CONFIG_FILES([scripts/ntptrace/ntptrace], [chmod +x scripts/ntptrace/ntptrace]) +AC_CONFIG_FILES([scripts/ntpver], [chmod +x scripts/ntpver]) +AC_CONFIG_FILES([scripts/plot_summary], [chmod +x scripts/plot_summary]) +AC_CONFIG_FILES([scripts/summary], [chmod +x scripts/summary]) +AC_CONFIG_FILES([scripts/update-leap/Makefile]) +AC_CONFIG_FILES([scripts/update-leap/update-leap], [chmod +x scripts/update-leap/update-leap]) +AC_CONFIG_FILES([tests/Makefile]) +AC_CONFIG_FILES([tests/bug-2803/Makefile]) +AC_CONFIG_FILES([tests/libntp/Makefile]) +AC_CONFIG_FILES([tests/ntpd/Makefile]) +AC_CONFIG_FILES([tests/ntpq/Makefile]) +AC_CONFIG_FILES([tests/sandbox/Makefile]) +AC_CONFIG_FILES([tests/sec-2853/Makefile]) +AC_CONFIG_FILES([util/Makefile]) + +perllibdir="${datadir}/ntp/lib" +AC_DEFINE_DIR([PERLLIBDIR], [perllibdir], [data dir]) + +calc_tickadj_opts="$srcdir/scripts/calc_tickadj/calc_tickadj-opts" +AC_SUBST_FILE([calc_tickadj_opts]) +ntp_wait_opts="$srcdir/scripts/ntp-wait/ntp-wait-opts" +AC_SUBST_FILE([ntp_wait_opts]) +ntpsweep_opts="$srcdir/scripts/ntpsweep/ntpsweep-opts" +AC_SUBST_FILE([ntpsweep_opts]) +ntptrace_opts="$srcdir/scripts/ntptrace/ntptrace-opts" +AC_SUBST_FILE([ntptrace_opts]) +summary_opts="$srcdir/scripts/summary-opts" +AC_SUBST_FILE([summary_opts]) +plot_summary_opts="$srcdir/scripts/plot_summary-opts" +AC_SUBST_FILE([plot_summary_opts]) + +AC_CONFIG_SUBDIRS([sntp]) AC_OUTPUT diff --git a/contrib/ntp/deps-ver b/contrib/ntp/deps-ver new file mode 100644 index 000000000..16d66a8bd --- /dev/null +++ b/contrib/ntp/deps-ver @@ -0,0 +1 @@ +Fri Dec 30 11:24:57 UTC 2011 diff --git a/contrib/ntp/depsver.mf b/contrib/ntp/depsver.mf new file mode 100644 index 000000000..695f7303c --- /dev/null +++ b/contrib/ntp/depsver.mf @@ -0,0 +1,60 @@ +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +BUILT_SOURCES += .deps-ver +CLEANFILES += .deps-ver + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# diff --git a/contrib/ntp/dot.emacs b/contrib/ntp/dot.emacs index 04241e7f7..941ecbe88 100644 --- a/contrib/ntp/dot.emacs +++ b/contrib/ntp/dot.emacs @@ -1,13 +1,14 @@ -;; This is how Dave Mills likes to see the code formatted. +;; This is how Dave Mills likes to see the NTP code formatted. (defconst ntp-c-style - '((c-basic-offset . 8) + '((c-basic-offset . 8) + (fill-column . 72) (c-offsets-alist . ((arglist-intro . +) (case-label . *) (statement-case-intro . *) (statement-cont . *) (substatement-open . 0)))) - "Dave L. Mills; programming style for use with ntp") + "David L. Mills; NTP code indentation style") (defun ntp-c-mode-common-hook () ;; add ntp c style diff --git a/contrib/ntp/excludes b/contrib/ntp/excludes deleted file mode 100644 index 36cb351e9..000000000 --- a/contrib/ntp/excludes +++ /dev/null @@ -1 +0,0 @@ -*.obj *.pch *.bsc *.pdb *.sbr nt*.zip *.tar *.gz *.ilk beta*.zip diff --git a/contrib/ntp/flock-build b/contrib/ntp/flock-build index d80fc6d3d..b537ac349 100755 --- a/contrib/ntp/flock-build +++ b/contrib/ntp/flock-build @@ -1,14 +1,32 @@ #! /bin/sh +IAM=`hostname || uname -n` +MYNAME=`IFS=. ; set $IAM ; echo $1` + +case "$1" in + '--one'|'-1') + shift + FB_FIRSTONLY=1 + LIST=$MYNAME + ;; + *) + FB_FIRSTONLY=0 +esac + BUILD_ARGS="$@" PARSE="--enable-parse-clocks" #PARSE= STD="--enable-simulator" -case "$SIMUL" in - '') PARALLEL_BUILDS=1 - ;; - *) PARALLEL_BUILDS=$SIMUL +case "$SIMUL::$FB_FIRSTONLY" in + ::*) + PARALLEL_BUILDS=1 + ;; + *::0) + PARALLEL_BUILDS=$SIMUL + ;; + *) + PARALLEL_BUILDS=1 esac case "$PARALLEL_BUILDS" in @@ -30,11 +48,14 @@ esac # Campus: # * baldwin sparc-sun-solaris2.10 # * bridgeport sparc-sun-solaris2.10 -# * cowbird freebsd-6.1 # * malarky sparc-sun-solaris2.10 # * pogo sparc-sun-solaris2.10 # * rackety freebsd-6.1 +if [ ! -r sntp/libevent/build-aux/config.guess ] ; then + echo "Error: bootstrap required." 1>&2 && exit 1 +fi + # HMS: we need $PWD because solaris produces /deacon/backroom when # we are in /backroom and in general there is no /deacon/backroom. c_d=${PWD:-`pwd`} @@ -42,7 +63,7 @@ c_d=${PWD:-`pwd`} SIG=`perl -e 'print rand'` case "$LIST" in - '') LIST="baldwin bridgeport cowbird malarky pogo rackety" ;; + '') LIST="pogo" ;; esac for i in $LIST @@ -51,56 +72,62 @@ do [ -f .buildkey-$i ] && SKIPTHIS=1 case "$SKIPTHIS" in 1) - echo flock-build running on $i? check LIST, skipping - ;; - 0) - echo $i - echo $SIG > .buildkey-$i - case "1" in - 0) - ssh $i "cd $c_d ; ./build $SIG $PARSE $STD $BUILD_ARGS" & - ssh $i "cd $c_d ; ./build $SIG $PARSE $STD --without-crypto $BUILD_ARGS" & - ssh $i "cd $c_d ; ./build $SIG $STD --disable-all-clocks $BUILD_ARGS" & - ;; - 1) - cat > .flockbuild-$i-$SIG < .buildkey-$i + case "1" in + 0) + ssh $i "cd $c_d ; ./build $SIG $PARSE $STD $BUILD_ARGS" & + ssh $i "cd $c_d ; ./build $SIG $PARSE $STD --disable-debugging $BUILD_ARGS" & + ssh $i "cd $c_d ; ./build $SIG $PARSE $STD --without-crypto --enable-c99-snprintf $BUILD_ARGS" & + ssh $i "cd $c_d ; ./build $SIG $STD --disable-all-clocks --disable-autokey --without-sntp --disable-thread-support $BUILD_ARGS" & + ;; + 1) + cat > .flockbuild-$i-$SIG <<-ENDQUOT + #!/bin/sh + + # script uses job control and expects to be invoked + # in a ssh session started with the -tt option, + # which forces a pseudo-tty to be used. + + cd $c_d + COUNT=0 + + ./build $SIG $PARSE $STD $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + [ 0 -lt \`expr \$COUNT % $PARALLEL_BUILDS\` ] || wait + + case $FB_FIRSTONLY in + '0') + ./build $SIG $PARSE $STD --disable-debugging $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + [ 0 -lt \`expr \$COUNT % $PARALLEL_BUILDS\` ] || wait + + ./build $SIG $PARSE $STD --without-crypto --enable-c99-snprintf $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + [ 0 -lt \`expr \$COUNT % $PARALLEL_BUILDS\` ] || wait + + ./build $SIG $STD --disable-all-clocks --disable-autokey --without-sntp --disable-thread-support $BUILD_ARGS & + + COUNT=\`expr \$COUNT + 1\` + echo \`date -u '+%H:%M:%S'\` $i started build \$COUNT of 4 + wait + esac + echo \`date -u '+%H:%M:%S'\` $i flock-build $c_d done. + rm .buildkey-$i ENDQUOT - chmod +x .flockbuild-$i-$SIG - ssh -tt $i "$c_d/.flockbuild-$i-$SIG ; \ - rm $c_d/.flockbuild-$i-$SIG" 2>/dev/null & - esac + chmod +x .flockbuild-$i-$SIG + ssh -tt $i "$c_d/.flockbuild-$i-$SIG ; \ + rm $c_d/.flockbuild-$i-$SIG" 2>/dev/null & + esac esac done echo `date -u '+%H:%M:%S'` flock-build launched diff --git a/contrib/ntp/html/access.html b/contrib/ntp/html/access.html new file mode 100644 index 000000000..3489f8fbd --- /dev/null +++ b/contrib/ntp/html/access.html @@ -0,0 +1,50 @@ + + + + + +Access Control Support + + + + +

Access Control Support

+

giffrom Pogo, Walt Kelly

+

The skunk watches for intruders and sprays.

+

Last update: + 11-Sep-2010 05:53 + UTC

+
+

Related Links

+ + + +
+

Access Control Support

+

The ntpd daemon implements a general purpose access control list (ACL) containing address/match entries sorted first by increasing address values and then by increasing mask values. A match occurs when the bitwise AND of the mask and the packet source address is equal to the bitwise AND of the mask and address in the list. The list is searched in order with the last match found defining the restriction flags associated with the entry.

+

The ACL is specified as a list of restrict commands in the following format:

+

restrict address [mask mask] [flag][...]

+

The address argument expressed in dotted-quad form is the address of a host or network. Alternatively, the address argument can be a valid host DNS name. The mask argument expressed in IPv4 or IPv6 numeric address form defaults to all mask bits on, meaning that the address is treated as the address of an individual host. A default entry (address 0.0.0.0, mask 0.0.0.0 for IPv4 and address :: mask :: for IPv6) is always the first entry in the list. restrict default, with no mask option, modifies both IPv4 and IPv6 default entries. restrict source configures a template restriction automatically added at runtime for each association, whether configured, ephemeral, or preemptable, and removed when the association is demobilized.

+

Some flags have the effect to deny service, some have the effect to enable service and some are conditioned by other flags. The flags. are not orthogonal, in that more restrictive flags will often make less restrictive ones redundant. The flags that deny service are classed in two categories, those that restrict time service and those that restrict informational queries and attempts to do run-time reconfiguration of the server.

+

An example may clarify how it works. Our campus has two class-B networks, 128.4 for the ECE and CIS departments and 128.175 for the rest of campus. Let's assume (not true!) that subnet 128.4.1 homes critical services like class rosters and spread sheets. A suitable ACL might look like this:

+
+restrict default nopeer					# deny new associations
+restrict 128.175.0.0 mask 255.255.0.0 		# allow campus access
+restrict 128.4.0.0 mask 255.255.0.0 none	# allow ECE and CIS access
+restrict 128.4.1.0 mask 255.255.255.0 notrust # require authentication on subnet 1
+restrict time.nist.gov						# allow access
+
+

While this facility may be useful for keeping unwanted, broken or malicious clients from congesting innocent servers, it should not be considered an alternative to the NTP authentication facilities. Source address based restrictions are easily circumvented by a determined cracker.

+

Default restriction list entries with the flags ignore, ntpport, for each of the local host's interface addresses are inserted into the table at startup to prevent the server from attempting to synchronize to its own time. A default entry is also always present, though if it is otherwise unconfigured; no flags are associated with the default entry (i.e., everything besides your own NTP server is unrestricted).

+
+ + + + diff --git a/contrib/ntp/html/accopt.html b/contrib/ntp/html/accopt.html index be8a5bb4b..6caff48c3 100644 --- a/contrib/ntp/html/accopt.html +++ b/contrib/ntp/html/accopt.html @@ -1,73 +1,91 @@ - - - - - - Access Control Options - - - - -

Access Control Options

- giffrom Pogo, Walt Kelly -

The skunk watches for intruders and sprays.

-

Last update: 18:35 UTC Thursday, July 28, 2005

-
-

Related Links

- -

Table of Contents

- -
-

Access Control Support

- The ntpd daemon implements a general purpose address/mask based restriction list. The list contains address/match entries sorted first by increasing address values and and then by increasing mask values. A match occurs when the bitwise AND of the mask and the packet source address is equal to the bitwise AND of the mask and address in the list. The list is searched in order with the last match found defining the restriction flags associated with the entry. Additional information and examples can be found in the Notes on Configuring NTP and Setting up a NTP Subnet page. -

The restriction facility was implemented in conformance with the access policies for the original NSFnet backbone time servers. Later the facility was expanded to deflect cryptographic and clogging attacks. While this facility may be useful for keeping unwanted or broken or malicious clients from congesting innocent servers, it should not be considered an alternative to the NTP authentication facilities. Source address based restrictions are easily circumvented by a determined cracker.

-

Clients can be denied service because they are explicitly included in the restrict list created by the restrict command or implicitly as the result of cryptographic or rate limit violations. Cryptographic violations include certificate or identity verification failure; rate limit violations generally result from defective NTP implementations that send packets at abusive rates. Some violations cause denied service only for the offending packet, others cause denied service for a timed period and others cause the denied service for an indefinate period. When a client or network is denied access for an indefinate period, the only way at present to remove the restrictions is by restarting the server.

-

The Kiss-of-Death Packet

-

Ordinarily, packets denied service are simply dropped with no further action except incrementing statistics counters. Sometimes a more proactive response is needed, such as a server message that explicitly requests the client to stop sending and leave a message for the system operator. A special packet format has been created for this purpose called the "kiss-o'-death" (KoD) packet. KoD packets have the leap bits set unsynchronized and stratum set to zero and the reference identifier field set to a four-byte ASCII code. If the noserve or notrust flag of the matching restrict list entry is set, the code is "DENY"; if the limited flag is set and the rate limit is exceeded, the code is "RATE". Finally, if a cryptographic violation occurs, the code is "CRYP".

-

A client receiving a KoD performs a set of sanity checks to minimize security exposure, then updates the stratum and reference identifier peer variables, sets the access denied (TEST4) bit in the peer flash variable and sends a message to the log. As long as the TEST4 bit is set, the client will send no further packets to the server. The only way at present to recover from this condition is to restart the protocol at both the client and server. This happens automatically at the client when the association times out. It will happen at the server only if the server operator cooperates.

-

Access Control Commands

-
-
discard [ average avg ][ minimum min ] [ monitor prob ] -
Set the parameters of the limited facility which protects the server from client abuse. The average subcommand specifies the minimum average packet spacing, while the minimum subcommand specifies the minimum packet spacing. Packets that violate these minima are discarded and a kiss-o'-death packet returned if enabled. The default minimum average and minimum are 5 and 2, respectively. The monitor subcommand specifies the probability of discard for packets that overflow the rate-control window. -
restrict address [mask mask] [flag][...] -
The address argument expressed in dotted-quad form is the address of a host or network. Alternatively, the address argument can be a valid host DNS name. The mask argument expressed in dotted-quad form defaults to 255.255.255.255, meaning that the address is treated as the address of an individual host. A default entry (address 0.0.0.0, mask 0.0.0.0) is always included and is always the first entry in the list. Note that text string default, with no mask option, may be used to indicate the default entry. -
In the current implementation, flag always restricts access, i.e., an entry with no flags indicates that free access to the server is to be given. The flags are not orthogonal, in that more restrictive flags will often make less restrictive ones redundant. The flags can generally be classed into two catagories, those which restrict time service and those which restrict informational queries and attempts to do run-time reconfiguration of the server. One or more of the following flags may be specified: -
-
ignore -
Deny packets of all kinds, including ntpq and ntpdc queries. -
kod -
If this flag is set when an access violation occurs, a kiss-o'-death (KoD) packet is sent. KoD packets are rate limited to no more than one per second. If another KoD packet occurs within one second after the last one, the packet is dropped -
limited -
Deny service if the packet spacing violates the lower limits specified in the discard command. A history of clients is kept using the monitoring capability of ntpd. Thus, monitoring is always active as long as there is a restriction entry with the limited flag. -
lowpriotrap -
Declare traps set by matching hosts to be low priority. The number of traps a server can maintain is limited (the current limit is 3). Traps are usually assigned on a first come, first served basis, with later trap requestors being denied service. This flag modifies the assignment algorithm by allowing low priority traps to be overridden by later requests for normal priority traps. -
nomodify -
Deny ntpq and ntpdc queries which attempt to modify the state of the server (i.e., run time reconfiguration). Queries which return information are permitted. -
noquery -
Deny ntpq and ntpdc queries. Time service is not affected. -
nopeer -
Deny packets which would result in mobilizing a new association.  This includes broadcast, symmetric-active and manycast client packets when a configured association does not exist. -
noserve -
Deny all packets except ntpq and ntpdc queries. -
notrap -
Decline to provide mode 6 control message trap service to matching hosts. The trap service is a subsystem of the ntpdq control message protocol which is intended for use by remote event logging programs. -
notrust -
Deny packets unless the packet is cryptographically authenticated. -
ntpport -
This is actually a match algorithm modifier, rather than a restriction flag. Its presence causes the restriction entry to be matched only if the source port in the packet is the standard NTP UDP port (123). Both ntpport and non-ntpport may be specified. The ntpport is considered more specific and is sorted later in the list. -
version -
Deny packets that do not match the current NTP version. -
-
Default restriction list entries with the flags ignore, interface, ntpport, for each of the local host's interface addresses are inserted into the table at startup to prevent the server from attempting to synchronize to its own time. A default entry is also always present, though if it is otherwise unconfigured; no flags are associated with the default entry (i.e., everything besides your own NTP server is unrestricted). -
-
- - - - \ No newline at end of file + + + +Access Control Commands and Options + + + + + +

Access Control Commands and Options

+giffrom Pogo, Walt Kelly +

The skunk watches for intruders and sprays.

+

Last update: + 13-Nov-2014 03:00 + UTC

+
+

Related Links

+ + +
+

Commands and Options

+

Unless noted otherwise, further information about these ccommands is on the Access Control Support page.

+
+
discard [ average avg ][ minimum min ] [ monitor prob ]
+
Set the parameters of the rate control facility which protects the server from client abuse. If the limited flag is present in the ACL, packets that violate these limits are discarded. If, in addition, the kod flag is present, a kiss-o'-death packet is returned. See the Rate Management page for further information. The options are: +
+
average avg
+
Specify the minimum average interpacket spacing (minimum average headway + time) in log2 s with default 3.
+
minimum min
+
Specify the minimum interpacket spacing (guard time) in seconds with default 2.
+
monitor
+
Specify the probability of being recorded for packets that overflow the MRU list size limit set by mru maxmem or mru maxdepth. This is a performance optimization for servers with aggregate arrivals of 1000 packets per second or more.
+
+
+
restrict default [flag][...]
+ restrict source [flag][...]
+ restrict address [mask mask] [flag][...]
+
The address argument expressed in dotted-quad form is the address of a host or network. Alternatively, the address argument can be a valid host DNS name. The mask argument expressed in IPv4 or IPv6 numeric address form defaults to all mask bits on, meaning that the address is treated as the address of an individual host. A default entry (address 0.0.0.0, mask 0.0.0.0 for IPv4 and address :: mask :: for IPv6) is always the first entry in the list. restrict default, with no mask option, modifies both IPv4 and IPv6 default entries. restrict source configures a template restriction automatically added at runtime for each association, whether configured, ephemeral, or preemptible, and removed when the association is demobilized.
+
Some flags have the effect to deny service, some have the effect to enable service and some are conditioned by other flags. The flags. are not orthogonal, in that more restrictive flags will often make less restrictive ones redundant. The flags that deny service are classed in two categories, those that restrict time service and those that restrict informational queries and attempts to do run-time reconfiguration of the server. One or more of the following flags may be specified:
+
+
+
flake
+
Discard received NTP packets with probability 0.1; that is, on average drop one packet in ten. This is for testing and amusement. The name comes from Bob Braden's flakeway, which once did a similar thing for early Internet testing.
+
ignore
+
Deny packets of all kinds, including ntpq and ntpdc queries.
+
kod
+
Send a kiss-o'-death (KoD) packet if the limited flag is present and a packet violates the rate limits established by the discard command. KoD packets are themselves rate limited for each source address separately. If the kod flag is used in a restriction which does not have the limited flag, no KoD responses will result.
+
limited
+
Deny time service if the packet violates the rate limits established by the discard command. This does not apply to ntpq and ntpdc queries.
+
lowpriotrap
+
Declare traps set by matching hosts to be low priority. The number of traps a server can maintain is limited (the current limit is 3). Traps are usually assigned on a first come, first served basis, with later trap requestors being denied service. This flag modifies the assignment algorithm by allowing low priority traps to be overridden by later requests for normal priority traps.
+
mssntp
+
Enable Microsoft Windows MS-SNTP authentication using Active Directory services. Note: Potential users should be aware that these services involve a TCP connection to another process that could potentially block, denying services to other users. Therefore, this flag should be used only for a dedicated server with no clients other than MS-SNTP.
+
nomodify
+
Deny ntpq and ntpdc queries which attempt to modify the state of the server (i.e., run time reconfiguration). Queries which return information are permitted.
+
noquery
+
Deny ntpq and ntpdc queries. Time service is not affected.
+
nopeer
+
Deny packets that might mobilize an association unless authenticated. This includes broadcast, symmetric-active and manycast server packets when a configured association does not exist. It also includes pool associations, so if you want to use servers from a pool directive and also want to use nopeer by default, you'll want a "restrict source ..." line as well that does not include the nopeer directive. Note that this flag does not apply to packets that do not attempt to mobilize an association.
+
noserve
+
Deny all packets except ntpq and ntpdc queries.
+
notrap
+
Decline to provide mode 6 control message trap service to matching hosts. The trap service is a subsystem of the ntpdc control message protocol which is intended for use by remote event logging programs.
+
notrust
+
Deny packets that are not cryptographically authenticated. Note carefully how this flag interacts with the auth option of the enable and disable commands. If auth is enabled, which is the default, authentication is required for all packets that might mobilize an association. If auth is disabled, but the notrust flag is not present, an association can be mobilized whether or not authenticated. If auth is disabled, but the notrust flag is present, authentication is required only for the specified address/mask range.
+
ntpport
+
This is actually a match algorithm modifier, rather than a restriction + flag. Its presence causes the restriction entry to be matched only if the + source port in the packet is the standard NTP UDP port (123). A restrict line + containing ntpport is considered more specific than one with the + same address and mask, but lacking ntpport.
+
version
+
Deny packets that do not match the current NTP version.
+
+
+
Default restriction list entries with the flags ignore, ntpport, for each of the local host's interface addresses are inserted into the table at startup to prevent the server from attempting to synchronize to its own time. A default entry is also always present, though if it is otherwise unconfigured; no flags are associated with the default entry (i.e., everything besides your own NTP server is unrestricted).
+
+
+ + + diff --git a/contrib/ntp/html/assoc.html b/contrib/ntp/html/assoc.html index 0ca142650..8dc0b1bf9 100644 --- a/contrib/ntp/html/assoc.html +++ b/contrib/ntp/html/assoc.html @@ -1,59 +1,81 @@ - - - - - - Association Management - - - - -

Association Management

- giffrom Alice's Adventures in Wonderland, Lewis Carroll -

Make sure who your friends are.

-

Last update: 18:35 UTC Thursday, July 28, 2005

-
-

Related Links

- -

Table of Contents

- -
-

Association Modes

-

NTP Version 4 (NTPv4) incorporates new features and refinements to the NTP Version 3 (NTPv3) algorithms; however, it continues the tradition of backwards compatibility with older versions. A number of new operating modes for automatic server discovery and improved accuracy in occasionally connected networks are provided. Following is an overview of the new features; additional information is available on the Configuration Options and Authentication Options pages and in the papers, reports, memoranda and briefings at www.ntp.org.

-

There are two types of associations: persistent associations, which result from configuration file commands, and ephemeral associations, which result from protocol operations described below. A persistent association is never demobilized, although it may become dormant when the associated server becomes unreachable. An ephemeral association is mobilized when a message arrives from a server; for instance, a symmetric passive association is mobilized upon arrival of a symmetric active message. A broadcast client association is mobilized upon arrival of a broadcast server message, while a Manycast client association is mobilized upon arrival of a Manycast server message.

-

Ordinarily, successful mobilization of an ephemeral association requires the server to be cryptographically authenticated to the dependent client. This can be done using either symmetric-key or public-key cryptography, as described in the Authentication Options page. The cryptographic means insure an unbroken chain of trust between the dependent client and the primary servers at the root of the synchronization subnet. We call this chain the provenance of the client and define new vocabulary as to proventicate a client or provide proventic credentials. Once mobilized, ephemeral associations are demobilized when either (a) the server becomes unreachable or (b) the server refreshes the key media without notifying the client.

-

There are three principal modes of operation: client/server, symmetric active/passive and broadcast. In addition, there are two modes using IP multicast support: multicast and manycast. These modes are selected based on the scope of service, intended flow of time and proventic values and means of configuration. Following is a summary of the operations in each mode.

-

Client/Server Mode

-

Client/server mode is probably the most common configuration in the Internet today. It operates in the classic remote-procedure-call (RPC) paradigm with stateless servers. In this mode a client sends a request to the server and expects a reply at some future time. In some contexts this would be described as a "pull" operation, in that the client pulls the time and proventic values from the server. A client is configured in client mode using the server (sic) command and specifying the server IPv4 or IPv6 DNS name or address; the server requires no prior configuration. The original NTPv3 authentication scheme is applicable in this mode, as well as the new NTPv4 Autokey proventication scheme. In addition, two burst modes described below can be used in appropriate cases.

-

Symmetric Active/Passive Mode

-

Symmetric active/passive mode is intended for configurations were a clique of low-stratum peers operate as mutual backups for each other. Each peer operates with one or more primary reference sources, such as a radio clock, or a subset of secondary servers known to be reliable and proventicated. Should one of the peers lose all reference sources or simply cease operation, the other peers will automatically reconfigure so that time and proventication values can flow from the surviving peers to all the others in the clique. In some contexts this would be described as a "push-pull" operation, in that the peer either pulls or pushes the time and proventic values depending on the particular configuration.

-

Symmetric peers operate with their sources in some NTP mode and with each other in symmetric mode. A peer is configured in symmetric active mode using the peer command and specifying the other peer IPv4 or IPv6 DNS name or address. The other peer can also be configured in symmetric active mode in a similar way. However, if the other peer is not specifically configured in this way, a symmetric passive association is mobilized upon arrival of a symmetric active message. Since an intruder can impersonate a symmetric active peer and inject false time values, symmetric mode should always be cryptographically validated. The original NTPv3 authentication scheme is applicable in this mode, as well as the new NTPv4 Autokey proventication scheme.

-

Broadcast/Multicast Modes

-

IPv4 broadcast mode in both NTPv3 and NTPv4 is limited to directly connected subnets such as Ethernets which support broadcast technology. Ordinarily, this technology does not operate beyond the first hop router or gateway. In IPv6 and where service is intended beyond the local subnet, IP multicasting can be used where supported by the operating system and the routers support the Internet Group Management Protocol (IGMP). Most current kernels and available routers do support IP multicast technology, although service providers are sometimes reluctant to deploy it.

-

IPv4 broadcast mode is intended for configurations involving one or a few servers and a possibly very large client population on the same subnet. A broadcast server is configured using the broadcast command and a IPv4 local subnet broadcast address. A broadcast client is configured using the broadcastclient command, in which case it responds to broadcast messages received on any interface. Since an intruder can impersonate a broadcast server and inject false time values, this mode should always be cryptographically validated. The original NTPv3 authentication scheme is applicable in this mode, as well as the new NTPv4 Autokey proventication scheme.

-

The server generates broadcast messages continuously at intervals specified by the minpoll keyword and with a time-to-live span specified by the ttl keyword. A broadcast client responds to the first message received by waiting a short interval to avoid implosion at the server. Then, the client polls the server in burst mode in order to quickly set the host clock and validate the source. This normally results in a volley of eight client/server cycles at 2-s intervals during which both the synchronization and cryptographic protocols run concurrently. Following the volley, the client computes the offset between the apparent broadcast time and the (unicast) client time. This offset is used to compensate for the propagation time between the broadcast server and client. Once the offset is computed, the server continues as before and the client sends no further messages. If for some reason the broadcast server does not respond to client messages, the client will time out the volley and continue in listen-only mode with a default propagation delay.

-

Multicasting

-

Multicasting can be used to extend the scope of a timekeeping subnet in two ways: multicasting and manycasting. A general discussion of IP multicast technology is beyond the scope of this page. In simple terms a host or router sending to a IPv4 or IPv6 multicast group address expects all hosts or routers listening on this address to receive the message. There is no intrinsic limit on the number of senders or receivers and senders can be receivers and vice versa. The IANA has assigned multicast group address IPv4 224.0.1.1 and IPv6 FF05::101 (site local) to NTP, but these addresses should be used only where the multicast span can be reliably constrained to protect neighbor networks. In general, administratively scoped IPv4 group addresses should be used, as described in RFC-2365, or GLOP group addresses, as described in RFC-2770.

-

A multicast server is configured using the broadcast command, but with a multicast group address instead of a broadcast address. A multicast client is configured using the multicastclient command with a multicast group address. However, there is a subtle difference between IPv4 broadcasting and multicasting. IPv4 broadcasting is specific to each interface and local subnet address. If more than one interface is attached to a machine, a separate broadcast command applies to each one separately. This provides a way to limit exposure in a firewall, for example. For IPv6 the same distinction can be made using link-local prefix FF02 for each interface and site-local FF05 for all interfacesl.

-

IP multicasting is a different paradigm. By design, multicast messages travel from the sender via a shortest-path or shared tree to the receivers, which may require these messages emit from one or all interfaces, but carry a common source address. However, it is possible to configure multiple multicast group addresses using multiple broadcast or multicastclient commands. Other than these particulars, multicast messages are processed just like broadcast messages. Note that the calibration feature in broadcast mode is extremely important, since IP multicast messages can travel far different paths through the IP routing fabric than ordinary IP unicast messages.

-

Manycasting

-

Manycasting is a automatic discovery and configuration paradigm new to NTPv4. It is intended as a means for a multicast client to troll the nearby network neighborhood to find cooperating manycast servers, validate them using cryptographic means and evaluate their time values with respect to other servers that might be lurking in the vicinity. The intended result is that each manycast client mobilizes client associations with some number of the "best" of the nearby anycast servers, yet automatically reconfigures to sustain this number of servers should one or another fail. Additional information is on the Automatic NTP Configuration Options page.

-

Burst Modes

-

There are two burst modes where a single poll event triggers a burst of eight packets at 2-s intervals instead of the usual one. The burst mode sends a burst when the server is reachable, while the iburst mode sends a burst when the server is unreachable. Each mode is independently of the other and both can be used if necessary. The calldelay command can be used to increase the interval between the first and second packets in the burst in order to allow a modem to complete a call. Received server packets update the clock filter, which selects the best (most accurate) time values. When the last packet in the burst is sent, the next received packet updates the system variables and sets the system clock in the usual manner, as if only a single client/server cycle had occurred. The result is not only a rapid and reliable setting of the system clock, but a considerable reduction in network jitter.

-

The iburst keyword is used where it is important to set the clock quickly when an association is first mobilized or first becomes reachable or when the network attachment requires an initial calling or training procedure. The burst is initiated only when the server first becomes reachable and results in good accuracy with intermittent connections typical of PPP and ISDN services. Outlyers due to initial dial-up delays, etc., are avoided and the client sets the clock within a few seconds after the first message.

-

The burst keyword can be configured in cases of excessive network jitter or when the network attachment requires an initial calling or training procedure. The burst is initiated at each poll interval when the server is reachable. The burst does produce additional network overhead and can cause trouble if used indiscriminately. It should only be used where the poll interval is expected to settle to values at or above 1024 s.

-
- - - - \ No newline at end of file + + + +Association Management + + + +

Association Management

+giffrom Alice's Adventures in Wonderland, Lewis Carroll +

Make sure who your friends are.

+

Last update: + 31-Jan-2014 06:54 + UTC

+
+

Related Links

+ + +

Table of Contents

+ +
+

Association Modes

+

This page describes the various modes of operation provided in NTPv4. There are three types of associations in NTP: persistent, preemptable and ephemeral. Persistent associations are mobilized by a configuration command and never demobilized. Preemptable associations, which are new to NTPv4, are mobilized by a configuration command which includes the preempt option or upon arrival of an automatic server discovery packet. They are are demobilized by timeout or when preempted by a "better" server, as described on the Automatic Server Discovery Schemes page. Ephemeral associations are mobilized upon arrival of broadcast or multicast server packets and demobilized by timeout.

+

Ordinarily, successful mobilization of ephemeral associations requires the server to be cryptographically authenticated to the client. This can be done using either symmetric key or Autokey public key cryptography, as described on the Authentication Support page.

+

There are three principal modes of operation in NTP: client/server, symmetric active/passive and broadcast/multicast. There are three automatic server discovery schemes in NTP: broadcast/multicast, manycast and pool described on the Automatic Server Discovery Schemes page. In addition, the burst options and orphan mode can be used in appropriate cases.

+

Following is a summary of the operations in each mode. Note that reference to option applies to the commands described on the Server Commands and Options page. See that page for applicability and defaults.

+

Client/Server Mode

+

Client/server mode is the most common configuration in the Internet today. It operates in the classic remote-procedure-call (RPC) paradigm with stateless servers and stateful clients. In this mode a host sends a client (mode 3) request to the specified server and expects a server (mode 4) reply at some future time. In some contexts this would be described as a "pull" operation, in that the host pulls the time and related values from the server.

+

A host is configured in client mode using the server (sic) command and specifying the server DNS name or IPv4 or IPv6 address; the server requires no prior configuration. The iburst option described later on this page is recommended for clients, as this speeds up initial synchronization from several minutes to several seconds. The burst option described later on this page can be useful to reduce jitter on very noisy dial-up or ISDN network links.

+

Ordinarily, the program automatically manages the poll interval between the default minimum and maximum values. The minpoll and maxpoll options can be used to bracket the range. Unless noted otherwise, these options should not be used with reference clock drivers.

+

Symmetric Active/Passive Mode

+

Symmetric active/passive mode is intended for configurations where a clique + of low-stratum peers operate as mutual backups for each other. Each peer operates + with one or more primary reference sources, such as a reference clock, or a set + of secondary (stratum, 2) servers known to be reliable and authentic. Should + one of the peers lose all reference sources or simply cease operation, the + other peers will automatically reconfigure so that time and related values + can flow from the surviving peers to all hosts in the subnet. In some contexts + this would be described as a "push-pull" operation, in that the + peer either pulls or pushes the time and related values depending on the particular + configuration.

+

A symmetric active peer sends a symmetric active (mode 1) message to a designated peer. If a matching configured symmetric active association is found, the designated peer returns a symmetric active message. If no matching association is found, the designated peer mobilizes a ephemeral symmetric passive association and returns a symmetric passive (mode 2) message. Since an intruder can impersonate a symmetric active peer and cause a spurious symmetric passive association to be mobilized, symmetric passive mode should always be cryptographically validated.

+

A peer is configured in symmetric active mode using the peer command and specifying the other peer DNS name or IPv4 or IPv6 address. The burst and iburst options should not be used in symmetric modes, as this can upset the intended symmetry of the protocol and result in spurious duplicate or dropped messages.

+

As symmetric modes are most often used as root servers for moderate to large subnets where rapid response is required, it is generally best to set the minimum and maximum poll intervals of each root server to the same value using the minpoll and maxpoll options.

+

Broadcast/Multicast Modes

+

NTP broadcast and multicast modes are intended for configurations involving one or a few servers and a possibly very large client population. Broadcast mode can be used with Ethernet, FDDI and WiFi spans interconnected by hubs or switches. Ordinarily, broadcast packets do not extend beyond a level-3 router. Where service is intended beyond a level-3 router, multicast mode can be used. Additional information is on the Automatic NTP Configuration Options page.

+

A server is configured to send broadcast or multicast messages using the broadcast command and specifying the subnet address for broadcast or the multicast group address for multicast. A broadcast client is enabled using the broadcastclient command, while a multicast client is enabled using the multicastclient command and specifying the multicast group address. Multiple commands of either type can be used. However, the association is not mobilized until the first broadcast or multicast message is actually received.

+

Manycast and Pool Modes

+

Manycast and pool modes are automatic discovery and configuration paradigms new to NTPv4. They are intended as a means for a client to troll the nearby network neighborhood to find cooperating willing servers, validate them using cryptographic means and evaluate their time values with respect to other servers that might be lurking in the vicinity. The intended result is that each client mobilizes ephemeral client associations with some number of the "best" of the nearby servers, yet automatically reconfigures to sustain this number of servers should one or another fail. Additional information is on the Automatic Server Discovery Schemes page.

+

Poll Interval Management

+

NTP uses an intricate heuristic algorithm to automatically control the poll interval for maximum accuracy consistent with minimum network overhead. The algorithm measures the incidental offset and jitter to determine the best poll interval. When ntpd starts, the interval is the default minimum 64 s. Under normal conditions when the clock discipline has stabilized, the interval increases in steps to the default maximum 1024 s. In addition, should a server become unreachable after some time, the interval increases in steps to the maximum in order to reduce network overhead. Additional information about the algorithm is on the Poll Program page.

+

The default poll interval range is suitable for most conditions, but can be changed using options on the Server Commands and Options and Miscellaneous Options pages. However, when using maximum intervals much larger than the default, the residual clock frequency error must be small enough for the discipline loop to capture and correct. The capture range is 500 PPM with a 64-s interval decreasing by a factor of two for each interval doubling. At a 36-hr interval, for example, the capture range is only 0.24 PPM.

+

In the NTPv4 specification and reference implementation, the poll interval is expressed in log2 units, properly called the poll exponent. It is constrained by the lower limit minpoll and upper limit maxpoll options of the server command. The limits default to 6 (64 s) and 10 (1024 s), respectively, which are appropriate for the vast majority of cases.

+

As a rule of thumb, the expected errors increase by a factor of two as the poll interval increases by a factor of four. The poll interval algorithm slowly increases the poll interval when jitter dominates the error budget, but quickly reduces the interval when wander dominates it. More information about this algorithm is on the How NTP Works page.

+

There is normally no need to change the poll limits, as the poll interval is managed automatically as a function of prevailing jitter and wander. The most common exceptions are the following.

+
    +
  • With fast, lightly loaded LANs and modern processors, the nominal Allan intercept is about 500 s. In these cases the expected errors can be further reduced using a poll exponent of 4 (16 s). In the case of the pulse-per-second (PPS) driver, this is the recommended value.
  • +
  • With symmetric modes the most stable behavior results when both peers are configured in symmetric active mode with matching poll intervals of 6 (64 s).
  • +
  • The poll interval should not be modified for reference clocks, with the single exception the ACTS telephone modem driver. In this case the recommended minimum and maximum intervals are 12 (1.1 hr) and 17 (36 hr), respectively.
  • +
+

Burst Options

+

Occasionally it is necessary to send packets temporarily at intervals less than the poll interval. For instance, with the burst and iburst options of the server command, the poll program sends a burst of several packets at 2-s intervals. In either case the poll program avoids sending needless packets if the server is not responding. The client begins a burst with a single packet. When the first packet is received from the server, the client continues with the remaining packets in the burst. If the first packet is not received within 64 s, it will be sent again for two additional retries before beginning backoff. The result is to minimize network load if the server is not responding. Additional details are on the Poll Program page.

+

There are two burst options where a single poll event triggers a burst. They should be used only with the server and pool commands, but not with reference clock drivers nor symmetric mode peers. In both modes, received server packets update the clock filter, which selects the best (most accurate) time values. When the last packet in the burst is sent, the next received packet updates the system variables and adjusts the system clock as if only a single packet exchange had occurred.

+

The iburst option is useful where the system clock must be set quickly or when the network attachment requires an initial calling or training sequence, as in PPP or ISDN services. In general, this option is recommended for server and pool commands. A burst is sent only when the server is unreachable; in particular, when first starting up. Ordinarily, the clock is set within a few seconds after the first received packet. See the Clock State Machine page for further details about the startup behavior.

+

The burst option is useful in cases of severe network + jitter or when the network attachment requires an initial calling or training + sequence. This option is recommended when the minimum poll exponent is larger than 10 (1024 s). A burst is sent only when the server is reachable. The number of packets in the burst is determined by the poll interval + so that the average interval between packets (headway) is no less than the minimum poll interval for the association.

+
+ + + diff --git a/contrib/ntp/html/audio.html b/contrib/ntp/html/audio.html index 9cea27361..908cac824 100644 --- a/contrib/ntp/html/audio.html +++ b/contrib/ntp/html/audio.html @@ -1,148 +1,180 @@ - - - - - - Reference Clock Audio Drivers - - - - -

Reference Clock Audio Drivers

- jpgICOM R-72 shortwave receiver and Sure audio mixer -

Last update: 18:36 UTC Thursday, July 28, 2005

-
-

Related Links

- -

Table of Contents

- -
-

Sound Card Drivers

-

There are some applications in which the computer time can be disciplined to an audio signal, rather than a serial timecode and communications port or special purpose bus peripheral. This is useful in such cases where the audio signal is sent over a telephone circuit, for example, or received directly from a shortwave receiver. In such cases the audio signal can be connected via an ordinary sound card or baseboard audio codec. The suite of NTP reference clock drivers currently includes three drivers suitable for these applications. They include a driver for the Inter Range Instrumentation Group (IRIG) signals produced by many radio clocks and timing devices, another for the Canadian time/frequency radio station CHU and a third for the NIST time/frequency radio stations WWV and WWVH. The radio drivers are designed to work with ordinary inexpensive shortwave radios and may be one of the least expensive ways to build a good primary time server.

-

All three drivers make ample use of sophisticated digital signal processing algorithms designed to efficiently extract timing signals from noise and interference. The radio station drivers in particular implement optimum linear demodulation and decoding techniques, including maximum likelihood and soft-decision methods. The documentation page for each driver contains an in-depth discussion on the algorithms and performance expectations. In some cases the algorithms are further analyzed, modelled and evaluated in a technical report.

-

Currently, the audio drivers work with with Sun operating systems and audio codecs, including SunOS 4.1.3 and Solaris from 2.6 and probably all others in between. They also work with FreeBSD from 4.1 with compatible sound card. In fact, the interface is quite generic and support for other systems, in particular the various Unix generics, should not be difficult. Volunteers are solicited.

-

The audio drivers include a number of common features designed to groom input signals, suppress spikes and normalize signal levels. An automatic gain control (AGC) feature provides protection against overdriven or underdriven input signals. It is designed to maintain adequate demodulator signal amplitude while avoiding occasional noise spikes. In order to assure reliable operation, the signal level must be in the range where the audio gain control is effective. In general, this means the input signal level must be such as to cause the AGC to set the gain somewhere in the middle of the range from 0 to 255, as indicated in the timecode displayed by the ntpq program.

-

The drivers operate by disciplining a logical clock based on the codec sample clock to the audio signal as received. This is done by stuffing or slipping samples as required to maintain exact frequency to the order of 0.1 PPM. In order for the driver to reliably lock on the audio signal, the sample clock frequency tolerance must be less than 250 PPM (.025 percent) for the IRIG driver and half that for the radio drivers. The largest error observed so far is about 60 PPM, but it is possible some sound cards or codecs may exceed that value.

-

The drivers include provisions to select the input port and to monitor the input signal. The fudge flag 2 selects the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port. The fudge flag 3 enables the input signal monitor using the previously selected output port and output gain. Both of these flags can be set in the configuration file or remotely using the ntpdc utility program.

-

Shortwave Radio Drivers

-

The WWV/H and CHU audio drivers require an external shortwave radio with the radio output - speaker or headphone jack - connected to either the microphone or line-in port on the computer. There is some degree of art in setting up the radio and antenna and getting the setup to work. While the drivers are highly sophisticated and efficient in extracting timing signals from noise and interference, it always helps to have as clear a signal as possible.

-

The most important factor affecting the radio signal is the antenna. It need not be long - even 15 feet is enough if it is located outside of a metal frame building, preferably on the roof, and away from metallic objects. An ordinary CB whip mounted on a PVC pipe and wooden X-frame on the roof should work well with most portable radios, as they are optimized for small antennas.

-

The radio need not be located near the computer; in fact, it generally works better if the radio is outside the near field of computers and other electromagnetic noisemakers. It can be in the elevator penthouse connected by house wiring, which can also be used to power the radio. A couple of center-tapped audio transformers will minimize noise pickup and provide phantom power to the radio with return via the building ground.

-

The WWV/H and CHU transmitters operate on several frequencies simultaneously, so that in most parts of North America at least one frequency supports propagation to the receiver location at any given hour. While both drivers support the ICOM CI-V radio interface and can tune the radio automatically, computer-tunable radios are expensive and probably not cost effective compared to a GPS receiver. So, the radio frequency must usually be fixed and chosen by compromise.

-

Shortwave (3-30 MHz) radio propagation phenomena are well known to shortwave enthusiasts. The phenomena generally obey the following rules:

-
    -
  • The optimum frequency is higher in daytime than nighttime, stays high longer on summer days and low longer on winter nights. -
  • Transitions between daytime and nightime conditions generally occur somewhat after sunrise and sunset at the midpoint of the path from transmitter to receiver. -
  • Ambient noise (static) on the lower frequencies follows the thunderstorm season, so is higher on summer afternoons and evenings. -
  • The lower frequency bands are best for shorter distances, while the higher bands are best for longer distances. -
  • The optimum frequencies are higher at the peak of the 11-year sunspot cycle and lower at the trough. The current sunspot cycle should peak in the first couple of years beginning the century. -
-

The best way to choose a frequency is to listen at various times over the day and determine the best highest (daytime) and lowest (nighttime) frequencies. Then, assuming one is available, choose the highest frequency between these frequencies. This strategy assumes that the high frequency is more problematic than the low, that the low frequency probably comes with severe multipath and static, and insures that probably twice a day the chosen frequency will work. For instance, on the east coast the best compromise CHU frequency is probably 7335 kHz and the best WWV frequency is probably 15 MHz.

-

Autotune Modes

-

The shortwave drivers include support for an optional autotune function compatible with ICOM receivers and transceivers. The mode keyword of the server configuration command specifies the ICOM ID select code in decimal. A missing or zero argument disables the CI-V interface. Since all ICOM select codes are less than 128, the high order bit of the code is used by the driver to specify the baud rate. If this bit is not set, the rate is 9600 bps for the newer radios; if set, the rate is 1200 bps for the older radios. Following are the ID select codes for the known radios.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
RadioHexDecimalRadioHexDecimal
7060x4e787750x4670
706MKIIG0x58887810x2638
7250x28409700x2e46
7260x3048R710x1A26
7350x044R720x3250
7460x66102R750x5a90
7510x1c28R70000x088
756PROII0x64100R71000x3452
7610x1e30R85000x4a74
7650x2c44R90000x2a42
-

Setup and Debugging Aids

-

The audio drivers include extensive setup and debugging support to help hook up the audio signals and monitor the driver operations. The documentation page for each driver describes the various messages that can be produced either in real time or written to the clockstats file for later analysis. Of particular help in verifying signal connections and compatibility is a provision to monitor the signal via headphones or speaker.

-

Connecting radios and IRIG devices to the computer and verifying correct configuration is somewhat of a black art. The signals have to be connected to the correct ports and the signal level maintained within tolerances. Some radios have recorder outputs which produce a line level signal not affected by the volume control. These signals can be connected to the line-in port on the computer. If the level is too low, connect to the microphone-in port instead. If the radio does not have a recorder output, connect the headphone or speaker output to the line-in port and adjust the volume control so the driver indicates comfortably above the minimum specified and the AGC level somewhere in the middle of the range 0-255. IRIG signals are usually much larger than radio outputs, usually in the range to several volts and may even overload the line-in port. In such cases an attenuator must be used to reduce the signal level below the overload point.

-

It is very easy to underdrive or overdrive the audio codec, in which case the drivers will not synchronize to the signal. The drivers use fudge flag2 to enable audio monitoring of the input signal. This is useful during setup to confirm the signal is actually reaching the audio codec and generally free of hum and interference. This feature is not intended for regular use, since it does increase the processor load on the system. Note that the speaker volume must be set before the driver is started.

-

The drivers write a synthesized timecode to the clockstats file each time the clock is set or verified and at other times if verbose monitoring is enabled. The format includes several fixed-length fields defining the UTC time to the millisecond, together with additional variable-length fields specific to each driver. The data include the intervals since the clock was last set or verified, the audio gain and various state variables and counters specific to each driver.

-
- - - - \ No newline at end of file + + + +Reference Clock Audio Drivers + + + +

Reference Clock Audio Drivers

+jpgICOM R-72 shortwave receiver and Sure audio mixer +

Last update: + 11-Sep-2010 05:55 + UTC

+
+

Related Links

+ + +

Table of Contents

+ +
+

Sound Card Drivers

+

There are some applications in which the computer time can be disciplined to an audio signal, rather than a serial timecode and communications port or special purpose bus peripheral. This is useful in such cases where the audio signal is sent over a telephone circuit, for example, or received directly from a shortwave receiver. In such cases the audio signal can be connected via an ordinary sound card or baseboard audio codec. The suite of NTP reference clock drivers currently includes three drivers suitable for these applications. They include a driver for the Inter Range Instrumentation Group (IRIG) signals produced by many radio clocks and timing devices, another for the Canadian time/frequency radio station CHU and a third for the NIST time/frequency radio stations WWV and WWVH. The radio drivers are designed to work with ordinary inexpensive shortwave radios and may be one of the least expensive ways to build a good primary time server.

+

All three drivers make ample use of sophisticated digital signal processing + algorithms designed to efficiently extract timing signals from noise and interference. + The radio station drivers in particular implement optimum linear demodulation + and decoding techniques, including maximum-likelihood and soft-decision methods. + The documentation page for each driver contains an in-depth discussion on + the algorithms and performance expectations. In some cases the algorithms + are further analyzed, modeled and evaluated in a technical report.

+

Currently, the audio drivers work with with Sun operating systems and audio codecs, including SunOS 4.1.3 and Solaris from 2.6 and probably all others in between. They also work with FreeBSD from 4.1 with compatible sound card. In fact, the interface is quite generic and support for other systems, in particular the various Unix generics, should not be difficult. Volunteers are solicited.

+

The audio drivers include a number of common features designed to groom input signals, suppress spikes and normalize signal levels. An automatic gain control (AGC) feature provides protection against overdriven or underdriven input signals. It is designed to maintain adequate demodulator signal amplitude while avoiding occasional noise spikes. In order to assure reliable operation, the signal level must be in the range where the audio gain control is effective. In general, this means the input signal level must be such as to cause the AGC to set the gain somewhere in the middle of the range from 0 to 255, as indicated in the timecode displayed by the ntpq program.

+

The IRIG and WWV drivers operate by disciplining a logical clock based on the codec sample clock to the audio signal as received. This is done by stuffing or slipping samples as required to maintain exact frequency to the order of 0.1 PPM. In order for the driver to reliably lock on the audio signal, the sample clock frequency tolerance must be less than 250 PPM (.025 percent) for the IRIG driver and half that for the WWV driver. The largest error observed so far is about 60 PPM, but it is possible some sound cards or codecs may exceed that value. In any case, the configuration file command tinker codec command can be used to change the systematic offset in units of 125 PPM.

+

The drivers include provisions to select the input port and to monitor the input signal. The fudge flag 2 command selects the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port. The fudge flag 3 command enables the input signal monitor using the previously selected output port and output gain. Both of these flags can be set in the configuration file or remotely using the ntpdc utility program.

+

Shortwave Radio Drivers

+

The WWV/H and CHU audio drivers require an external shortwave radio with the radio output - speaker or headphone jack - connected to either the microphone or line-in port on the computer. There is some degree of art in setting up the radio and antenna and getting the setup to work. While the drivers are highly sophisticated and efficient in extracting timing signals from noise and interference, it always helps to have as clear a signal as possible.

+

The most important factor affecting the radio signal is the antenna. It need not be long - even 15 feet is enough if it is located outside of a metal frame building, preferably on the roof, and away from metallic objects. An ordinary CB whip mounted on a PVC pipe and wooden X-frame on the roof should work well with most portable radios, as they are optimized for small antennas.

+

The radio need not be located near the computer; in fact, it generally works better if the radio is outside the near field of computers and other electromagnetic noisemakers. It can be in the elevator penthouse connected by house wiring, which can also be used to power the radio. A couple of center-tapped audio transformers will minimize noise pickup and provide phantom power to the radio with return via the building ground.

+

The WWV/H and CHU transmitters operate on several frequencies simultaneously, so that in most parts of North America at least one frequency supports propagation to the receiver location at any given hour. While both drivers support the ICOM CI-V radio interface and can tune the radio automatically, computer-tunable radios are expensive and probably not cost effective compared to a GPS receiver. So, the radio frequency must usually be fixed and chosen by compromise.

+

Shortwave (3-30 MHz) radio propagation phenomena are well known to shortwave enthusiasts. The phenomena generally obey the following rules:

+
    +
  • The optimum frequency is higher in daytime than nighttime, stays high longer on summer days and low longer on winter nights.
  • +
  • Transitions between daytime and nighttime conditions generally occur somewhat + after sunrise and sunset at the midpoint of the path from transmitter to + receiver.
  • +
  • Ambient noise (static) on the lower frequencies follows the thunderstorm season, so is higher on summer afternoons and evenings.
  • +
  • The lower frequency bands are best for shorter distances, while the higher bands are best for longer distances.
  • +
  • The optimum frequencies are higher at the peak of the 11-year sunspot cycle and lower at the trough. The current sunspot cycle began at the minimum in late 2006 and should reach its peak in 2012.
  • +
+

The best way to choose a frequency is to listen at various times over the day and determine the highest (daytime) and lowest (nighttime) frequencies that work well. Choose the frequency that works for the most number of hours in the day, usually the highest frequency. For instance, on the east coast the best compromise CHU frequency is 7335 kHz and the best WWV frequency is 15 MHz.

+

Autotune Modes

+

The shortwave drivers include support for an optional autotune function compatible with ICOM receivers and transceivers. The mode keyword of the server configuration command specifies the ICOM ID select code in decimal. A missing or zero argument disables the CI-V interface. Since all ICOM select codes are less than 128, the high order bit of the code is used by the driver to specify the baud rate. If this bit is not set, the rate is 9600 bps for the newer radios; if set, the rate is 1200 bps for the older radios. Following are the ID select codes for the known radios.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
RadioHexDecimalRadioHexDecimal
7060x4e787750x4670
706MKIIG0x58887810x2638
7250x28409700x2e46
7260x304870000x70113
7350x044R710x1A26
7460x66102R720x3250
7510x1c28R750x5a90
756PROII0x64100R70000x088
7610x1e30R71000x3452
7650x2c44R85000x4a74
R90000x2a42
+

Setup and Debugging Aids

+

The audio drivers include extensive setup and debugging support to help hook up the audio signals and monitor the driver operations. The documentation page for each driver describes the various messages that can be produced either in real time or written to the clockstats file for later analysis. Of particular help in verifying signal connections and compatibility is a provision to monitor the signal via headphones or speaker.

+

Connecting radios and IRIG devices to the computer and verifying correct + configuration is somewhat of a black art. The signals have to be connected + to the correct ports and the signal level maintained within tolerances. Some + radios have recorder outputs which produce a microphone-level signal not affected + by the volume control. These signals can be connected to the microphone port + on the computer. If the radio does not have a recorder output, connect the + headphone or speaker output to the line-in port and adjust the volume control + so the driver indicates comfortably above the minimum specified and the AGC + level somewhere in the middle of the range 0-255. IRIG signals are usually + much larger than radio outputs, usually in the range to several volts and + may even overload the line-in port. In such cases the signal is designed to + drive a cable terminated with a 50-ohm resistor, which results in a level + the line-in port can handle..

+

It is very easy to underdriven or overdrive the audio codec, in which case + the drivers will not synchronize to the signal. The drivers use fudge + flag2 to enable audio monitoring of the input signal. This is useful + during setup to confirm the signal is actually reaching the audio + codec and generally free of noise and interference. Note that the monitor + volume must be set before the driver is started.

+

The drivers write a synthesized timecode to the clockstats file each time the clock is set or verified and at other times if verbose monitoring is enabled. The format includes several fixed-length fields defining the UTC time to the millisecond, together with additional variable-length fields specific to each driver. The data include the intervals since the clock was last set or verified, the audio gain and various state variables and counters specific to each driver.

+
+ + + diff --git a/contrib/ntp/html/authentic.html b/contrib/ntp/html/authentic.html new file mode 100644 index 000000000..ecfb466af --- /dev/null +++ b/contrib/ntp/html/authentic.html @@ -0,0 +1,65 @@ + + + + + +Authentication Support + + + + +

Authentication Support

+giffrom Alice's Adventures in Wonderland, Lewis Carroll +

Our resident cryptographer; now you see him, now you don't.

+

Last update: + 1-Dec-2012 04:44 + UTC

+
+

Related Links

+ + +

Table of Contents

+ +
+

Introduction

+

This page describes the various cryptographic authentication provisions in NTPv4. Authentication support allows the NTP client to verify that servers are in fact known and trusted and not intruders intending accidentally or intentionally to masquerade as a legitimate server. A detailed discussion of the NTP multi-layer security model and vulnerability analysis is in the white paper NTP Security Analysis.

+

The NTPv3 specification (RFC-1305) defined an authentication scheme properly described as symmetric key cryptography. It used the Data Encryption Standard (DES) algorithm operating in cipher-block chaining (CBC) mode. Subsequently, this algorithm was replaced by the RSA Message Digest 5 (MD5) algorithm commonly called keyed-MD5. Either algorithm computes a message digest or one-way hash which can be used to verify the client has the same message digest as the server. The MD5 message digest algorithm is included in the distribution, so without further cryptographic support, the distribution can be freely exported.

+

If the OpenSSL cryptographic library is installed prior to building the distribution, all message digest algorithms included in the library may be used, including SHA and SHA1. However, if conformance to FIPS 140-2 is required, only a limited subset of these algorithms can be used. This library is available from http://www.openssl.org and can be installed using the procedures outlined in the Building and Installing the Distribution page. Once installed, the configure and build process automatically detects the library and links the library routines +required.

+

In addition to the symmetric key algorithms, this distribution includes support for the Autokey public key algorithms and protocol specified in RFC-5906 "Network Time Protocol Version 4: Autokey Specification". This support is available only if the OpenSSL library has been installed and the --enable-autokey option is used when the distribution is built.

+

Public key cryptography is generally considered more secure than symmetric key cryptography, since the security is based on private and public values which are generated by each participant and where the private value is never revealed. Autokey uses X.509 public certificates, which can be produced by commercial services, the OpenSSL application program, or the ntp-keygen utility program in the NTP software distribution.

+

Note that according to US law, NTP binaries including OpenSSL library components, including the OpenSSL library itself, cannot be exported outside the US without license from the US Department of Commerce. Builders outside the US are advised to obtain the OpenSSL library directly from OpenSSL, which is outside the US, and build outside the US.

+

Authentication is configured separately for each association using the key or autokey option of the server configuration command, as described in the Server Options page. The ntp-keygen page describes the files required for the various authentication schemes. Further details are in the briefings, papers and reports at the NTP project page linked from www.ntp.org.

+

By default, the client sends non-authenticated packets and the server responds with non-authenticated packets. If the client sends authenticated packets, the server responds with authenticated packets if correct, or a crypto-NAK packet if not.. In the case of unsolicited packets which might consume significant resources, such as broadcast or symmetric mode packets, , authentication is required, unless overridden by a disable auth command. In the current climate of targeted broadcast or "letterbomb" attacks, defeating this requirement would be decidedly dangerous. In any case, the notrust flag, described on the Access Control Options page, can be used to disable access to all but correctly authenticated clients..

+

Symmetric Key Cryptography

+

The original NTPv3 specification (RFC-1305), as well as the current NTPv4 specification (RFC-5905), allows any one of possibly 65,534 message digest keys (excluding zero), each distinguished by a 32-bit key ID, to authenticate an association. The servers and clients involved must agree on the key ID, key type and key to authenticate NTP packets.

+

The message digest is a cryptographic hash computed by an algorithm such as MD5 or SHA. When authentication is specified, a message authentication code (MAC) is appended to the NTP packet header. The MAC consists of a 32-bit key identifier (key ID) followed by a 128- or 160-bit message digest. The algorithm computes the digest as the hash of a 128- or 160- bit message digest key concatenated with the NTP packet header fields with the exception of the MAC. On transmit, the message digest is computed and inserted in the MAC. On receive, the message digest is computed and compared with the MAC. The packet is accepted only if the two MACs are identical. If a discrepancy is found by the client, the client ignores the packet, but raises an alarm. If this happens at the server, the server returns a special message called a crypto-NAK. Since the crypto-NAK is protected by the loopback test, an intruder cannot disrupt the protocol by sending a bogus crypto-NAK.

+

Keys and related information are specified in a keys file, which must be distributed and stored using secure means beyond the scope of the NTP protocol itself. Besides the keys used for ordinary NTP associations, additional keys can be used as passwords for the ntpq and ntpdc utility programs. Ordinarily, the ntp.keys file is generated by the ntp-keygen program, but it can be constructed and edited using an ordinary text editor.

+

Each line of the keys file consists of three fields: a key ID in the range 1 to 65,534, inclusive, a key type, and a message digest key consisting of a printable ASCII string less than 40 characters, or a 40-character hex digit string. If the OpenSSL library is installed, the key type can be any message digest algorithm supported by the library. If the OpenSSL library is not installed, the only permitted key type is MD5.

+
+

gif

+

Figure 1. Typical Symmetric Key File

+
+

Figure 1 shows a typical keys file used by the reference implementation when the OpenSSL library is installed. In this figure, for key IDs in he range 1-10, the key is interpreted as a printable ASCII string. For key IDs in the range 11-20, the key is a 40-character hex digit string. The key is truncated or zero-filled internally to either 128 or 160 bits, depending on the key type. The line can be edited later or new lines can be added to change any field. The key can be change to a password, such as 2late4Me for key ID 10. Note that two or more keys files can be combined in any order as long as the key IDs are distinct.

+

When ntpd is started, it reads the keys file specified by the keys command and installs the keys in the key cache. However, individual keys must be activated with the trustedkey configuration command before use. This allows, for instance, the installation of possibly several batches of keys and then activating a key remotely using ntpq or ntpdc. The requestkey command selects the key ID used as the password for the ntpdc utility, while the controlkey command selects the key ID used as the password for the ntpq utility.

+

Microsoft Windows Authentication

+

In addition to the above means, ntpd now supports Microsoft Windows MS-SNTP authentication using Active Directory services. This support was contributed by the Samba Team and is still in development. It is enabled using the mssntp flag of the restrict command described on the Access Control Options page. Note: Potential users should be aware that these services involve a TCP connection to another process that could potentially block, denying services to other users. Therefore, this flag should be used only for a dedicated server with no clients other than MS-SNTP.

+

Public Key Cryptography

+

See the Autokey Public-Key Authentication page.

+
+ + + diff --git a/contrib/ntp/html/authopt.html b/contrib/ntp/html/authopt.html index 5f67b3c99..9504deb8a 100644 --- a/contrib/ntp/html/authopt.html +++ b/contrib/ntp/html/authopt.html @@ -1,155 +1,95 @@ - - - - - - Authentication Options - - - - -

Authentication Options

- giffrom Alice's Adventures in Wonderland, Lewis Carroll -

Our resident cryptographer; now you see him, now you don't.

-

Last update: 01:29 UTC Wednesday, September 13, 2006

-
-

Related Links

- -

Table of Contents

- -
-

Authentication Support

-

Authentication support allows the NTP client to verify that the server is in fact known and trusted and not an intruder intending accidentally or on purpose to masquerade as that server. The NTPv3 specification RFC-1305 defines a scheme which provides cryptographic authentication of received NTP packets. Originally, this was done using the Data Encryption Standard (DES) algorithm operating in Cipher Block Chaining (CBC) mode, commonly called DES-CBC. Subsequently, this was replaced by the RSA Message Digest 5 (MD5) algorithm using a private key, commonly called keyed-MD5. Either algorithm computes a message digest, or one-way hash, which can be used to verify the server has the correct private key and key identifier.

-

NTPv4 retains the NTPv3 scheme, properly described as symmetric key cryptography, and, in addition, provides a new Autokey scheme based on public key cryptography. Public key cryptography is generally considered more secure than symmetric key cryptography, since the security is based on a private value which is generated by each host and never revealed. With the exception of the group key described later, all key distribution and management functions involve only public values, which considerably simplifies key distribution and storage. Public key management is based on X.509 certificates, which can be provided by commercial services or produced by utility programs in the OpenSSL software library or the NTPv4 distribution.

-

While the algorithms for symmetric key cryptography are included in the NTPv4 distribution, public key cryptography requires the OpenSSL software library to be installed before building the NTP distribution. This library is available from http://www.openssl.org and can be installed using the procedures outlined in the Building and Installing the Distribution page. Once installed, the configure and build process automatically detects the library and links the library routines required.

-

Authentication is configured separately for each association using the key or autokey subcommand on the peer, server, broadcast and manycastclient configuration commands as described in the Configuration Options page. The authentication options described below specify the locations of the key files, if other than default, which symmetric keys are trusted and the interval between various operations, if other than default.

-

Authentication is always enabled, although ineffective if not configured as described below. If a NTP packet arrives including a message authentication code (MAC), it is accepted only if it passes all cryptographic checks. The checks require correct key ID, key value and message digest. If the packet has been modified in any way or replayed by an intruder, it will fail one or more of these checks and be discarded. Furthermore, the Autokey scheme requires a preliminary protocol exchange to obtain the server certificate, verify its credentials and initialize the protocol

-

The auth flag controls whether new associations or remote configuration commands require cryptographic authentication. This flag can be set or reset by the enable and disable commands and also by remote configuration commands sent by a ntpdc program running on another machine. If this flag is enabled, which is the default case, new broadcast/manycast client and symmetric passive associations and remote configuration commands must be cryptographically authenticated using either symmetric key or public key cryptography. If this flag is disabled, these operations are effective even if not cryptographic authenticated. It should be understood that operating with the auth flag disabled invites a significant vulnerability where a rogue hacker can masquerade as a truechimer and seriously disrupt system timekeeping. It is important to note that this flag has no purpose other than to allow or disallow a new association in response to new broadcast and symmetric active messages and remote configuration commands and, in particular, the flag has no effect on the authentication process itself.

-

The security model and protocol schemes for both symmetric key and public key cryptography are summarized below; further details are in the briefings, papers and reports at the NTP project page linked from www.ntp.org.

-

Symmetric Key Cryptography

- - The original RFC-1305 specification allows any one of possibly 65,534 keys, each distinguished by a 32-bit key identifier, to authenticate an association. The servers and clients involved must agree on the key and key identifier to authenticate NTP packets. Keys and related information are specified in a key file, usually called ntp.keys, which must be distributed and stored using secure means beyond the scope of the NTP protocol itself. Besides the keys used for ordinary NTP associations, additional keys can be used as passwords for the ntpq and ntpdc utility programs. Ordinarily, the ntp.keys file is generated by the ntp-keygen program. -

When ntpd is first started, it reads the key file specified in the keys configuration command and installs the keys in the key cache. However, individual keys must be activated with the trustedkey command before use. This allows, for instance, the installation of possibly several batches of keys and then activating or deactivating each batch remotely using ntpdc. This also provides a revocation capability that can be used if a key becomes compromised. The requestkey command selects the key used as the password for the ntpdc utility, while the controlkey command selects the key used as the password for the ntpq utility.

-

Public Key Cryptography

-

NTPv4 supports the original NTPv3 symmetric key scheme described in RFC-1305 and in addition the Autokey protocol, which is based on public key cryptography. The Autokey Version 2 protocol described on the Autokey Protocol page verifies packet integrity using MD5 message digests and verifies the source with digital signatures and any of several digest/signature schemes. Optional identity schemes described on the Identity Schemes page and based on cryptographic challenge/response algorithms are also available. Using these schemes provides strong security against replay with or without modification, spoofing, masquerade and most forms of clogging attacks.

-

The Autokey protocol has several modes of operation corresponding to the various NTP modes supported. Most modes use a special cookie which can be computed independently by the client and server, but encrypted in transmission. All modes use in addition a variant of the S-KEY scheme, in which a pseudo-random key list is generated and used in reverse order. These schemes are described along with an executive summary, current status, briefing slides and reading list on the Autonomous Authentication page.

-

The specific cryptographic environment used by Autokey servers and clients is determined by a set of files and soft links generated by the ntp-keygen program. This includes a required host key file, required host certificate file and optional sign key file, leapsecond file and identity scheme files. The digest/signature scheme is specified in the X.509 certificate along with the matching sign key. There are several schemes available in the OpenSSL software library, each identified by a specific string such as md5WithRSAEncryption, which stands for the MD5 message digest with RSA encryption scheme. The current NTP distribution supports all the schemes in the OpenSSL library, including those based on RSA and DSA digital signatures.

-

NTP secure groups can be used to define cryptographic compartments and security hierarchies. It is important that every host in the group be able to construct a certificate trail to one or more trusted hosts in the same group. Each group host runs the Autokey protocol to obtain the certificates for all hosts along the trail to one or more trusted hosts. This requires the configuration file in all hosts to be engineered so that, even under anticipated failure conditions, the NTP subnet will form such that every group host can find a trail to at least one trusted host.

-

Naming and Addressing

-

It is important to note that Autokey does not use DNS to resolve addresses, since DNS can't be completely trusted until the name servers have synchronized clocks. The cryptographic name used by Autokey to bind the host identity credentials and cryptographic values must be independent of interface, network and any other naming convention. The name appears in the host certificate in either or both the subject and issuer fields, so protection against DNS compromise is essential.

-

By convention, the name of an Autokey host is the name returned by the Unix gethostname() system call or equivalent in other systems. By the system design model, there are no provisions to allow alternate names or aliases. However, this is not to say that DNS aliases, different names for each interface, etc., are constrained in any way.

-

It is also important to note that Autokey verifies authenticity using the host name, network address and public keys, all of which are bound together by the protocol specifically to deflect masquerade attacks. For this reason Autokey includes the source and destinatino IP addresses in message digest computations and so the same addresses must be available at both the server and client. For this reason operation with network address translation schemes is not possible. This reflects the intended robust security model where government and corporate NTP servers are operated outside firewall perimeters.

-

Configuration

-

Autokey has an intimidating number of options, most of which are not necessary in typical scenarios. The simplest configuration consists of a subnet with one or more servers at the same low stratum acting as trusted hosts and with dependent clients at higher strata and sharing a single secure group and identity scheme. Each trusted host generates a host key, trusted certificate and group key. Each client generates a host key, normal certificate and installs the group key of each trusted host using secure means and renames it as the name of the trusted host.

-

For example, trusted host Alice generates keys using

-

ntp-keygen -H -T -I -p xyz

-

where H specifies a new host key, T the trusted certificate, I the IFF identity scheme and p the password used to encrypt the private key files. The group key file is ntpkey_IFFpar_alice.filestamp, where filestamp represents the NTP time in seconds when the file was generated.

-

Host Bob generate keys using

-

ntp-keygen -H -p abc

-

where abc is different for each group host. The trusted host generates a password-protected group key using

-

ntp-keygen -q xyz -p abc -e >temp

-

where xyz is the trusted host password, abc is the password supplied by the client and temp is a temporary file. This file is transmitted to Bob using secure means and renamed to the fully qualified host name for Alice preceded by the string ntpkey_iff_.

-

Operation

-

A specific combination of authentication scheme (none, symmetric key, public key) and identity scheme is called a cryptotype, although not all combinations are compatible. There may be management configurations where the clients, servers and peers may not all support the same cryptotypes. A secure NTPv4 subnet can be configured in many ways while keeping in mind the principles explained above and in this section. Note however that some cryptotype combinations may successfully interoperate with each other, but may not represent good security practice.

-

The cryptotype of an association is determined at the time of mobilization, either at configuration time or some time later when a message of appropriate cryptotype arrives. When mobilized by a server or peer configuration command and no key or autokey subcommands are present, the association is not authenticated; if the key subcommand is present, the association is authenticated using the symmetric key ID specified; if the autokey subcommand is present, the association is authenticated using Autokey.

-

Key Management

-

The cryptographic values used by the Autokey protocol are incorporated as a set of files generated by the ntp-keygen utility program, including symmetric key, host key and public certificate files, as well as sign key, identity parameters and leapseconds files. Alternatively, host and sign keys and certificate files can be generated by the OpenSSL utilities and certificates can be imported from public certificate authorities. Note that symmetric keys are necessary for the ntpq and ntpdc utility programs. The remaining files are necessary only for the Autokey protocol.

-

Certificates imported from OpenSSL or public certificate authorities have certian limitations. The certificate should be in ASN.1 syntax, X.509 Version 3 format and encoded in PEM, which is the same format used by OpenSSL. The overall length of the certificate encoded in ASN.1 must not exceed 1024 bytes. The subject distinguished name field (CN) is the fully qualified name of the host on which it is used; the remaining subject fields are ignored. The certificate extension fields must not contain either a subject key identifier or a issuer key identifier field; however, an extended key usage field for a trusted host must contain the value trustRoot;. Other extension fields are ignored.

-

Authentication Commands

-
-
autokey [logsec] -
Specifies the interval between regenerations of the session key list used with the Autokey protocol. Note that the size of the key list for each association depends on this interval and the current poll interval. The default value is 12 (4096 s or about 1.1 hours). For poll intervals above the specified interval, a session key list with a single entry will be regenerated for every message sent. -
controlkey key -
Specifies the key identifier to use with the ntpq utility, which uses the standard protocol defined in RFC-1305. The key argument is the key identifier for a trusted key, where the value can be in the range 1 to 65,534, inclusive. -
crypto [cert file] [leap file] [randfile file] [host file] [sign file] [ident scheme] [iffpar file] [gqpar file] [mvpar file] [pw password] -
This command requires the OpenSSL library. It activates public key cryptography, selects the message digest and signature encryption scheme and loads the required private and public values described above. If one or more files are left unspecified, the default names are used as described above. Unless the complete path and name of the file are specified, the location of a file is relative to the keys directory specified in the keysdir command or default /usr/local/etc. Following are the subcommands: -
-
cert file -
Specifies the location of the required host public certificate file. This overrides the link ntpkey_cert_hostname in the keys directory. - -
gqpar file -
Specifies the location of the client GQ parameters file. This overrides the link ntpkey_gq_hostname in the keys directory. - -
host file -
Specifies the location of the required host key file. This overrides the link ntpkey_key_hostname in the keys directory. -
ident scheme -
Requests the server identity scheme, which can be IFF, GQ or MV. This is used when the host will not be a server for a dependent client.
iffpar file -
Specifies the location of the optional IFF parameters file.This overrides the link ntpkey_iff_hostname in the keys directory. -
leap file -
Specifies the location of the client leapsecond file. This overrides the link ntpkey_leap in the keys directory. -
mv -
Requests the MV server identity scheme. -
mvpar file -
Specifies the location of the client MV parameters file. This overrides the link ntpkey_mv_hostname in the keys directory. -
pw password -
Specifies the password to decrypt files containing private keys and identity parameters. This is required only if these files have been encrypted. -
randfile file -
Specifies the location of the random seed file used by the OpenSSL library. The defaults are described in the main text above. -
sign file -
Specifies the location of the optional sign key file. This overrides the link ntpkey_sign_hostname in the keys directory. If this file is not found, the host key is also the sign key. -
-
keys keyfile -
Specifies the complete path and location of the MD5 key file containing the keys and key identifiers used by ntpd, ntpq and ntpdc when operating with symmetric key cryptography. This is the same operation as the -k command line option. -
keysdir path -
This command specifies the default directory path for cryptographic keys, parameters and certificates. The default is /usr/local/etc/. -
requestkey key -
Specifies the key identifier to use with the ntpdc utility program, which uses a proprietary protocol specific to this implementation of ntpd. The key argument is a key identifier for the trusted key, where the value can be in the range 1 to 65,534, inclusive. -
revoke [logsec] -
Specifies the interval between re-randomization of certain cryptographic values used by the Autokey scheme, as a power of 2 in seconds. These values need to be updated frequently in order to deflect brute-force attacks on the algorithms of the scheme; however, updating some values is a relatively expensive operation. The default interval is 16 (65,536 s or about 18 hours). For poll intervals above the specified interval, the values will be updated for every message sent. -
trustedkey key [...] -
Specifies the key identifiers which are trusted for the purposes of authenticating peers with symmetric key cryptography, as well as keys used by the ntpq and ntpdc programs. The authentication procedures require that both the local and remote servers share the same key and key identifier for this purpose, although different keys can be used with different servers. The key arguments are 32-bit unsigned integers with values from 1 to 65,534. -
-

Error Codes

-

Errors can occur due to mismatched configurations, unexpected restarts, expired certificates and unfriendly people. In most cases the protocol state machine recovers automatically by retransmission, timeout and restart, where necessary. Some errors are due to mismatched keys, digest schemes or identity schemes and must be corrected by installing the correct media and/or correcting the configuration file. One of the most common errors is expired certificates, which must be regenerated and signed at least once per year using the ntp-keygen program.

-

The following error codes are reported via the NTP control and monitoring protocol trap mechanism.

-
-
101 (bad field format or length) -
The packet has invalid version, length or format. -
102 (bad timestamp) -
The packet timestamp is the same or older than the most recent received. This could be due to a replay or a server clock time step. -
103 (bad filestamp) -
The packet filestamp is the same or older than the most recent received. This could be due to a replay or a key file generation error. -
104 (bad or missing public key) -
The public key is missing, has incorrect format or is an unsupported type. -
105 (unsupported digest type) -
The server requires an unsupported digest/signature scheme. -
106 (unsupported identity type)
The client or server has requested an identity scheme the other does not support.
107 (bad signature length) -
The signature length does not match the current public key. -
108 (signature not verified) -
The message fails the signature check. It could be bogus or signed by a different private key. -
109 (certificate not verified) -
The certificate is invalid or signed with the wrong key.
110 (host certificate expired)
The old server certificate has expired.
111 (bad or missing cookie) -
The cookie is missing, corrupted or bogus. -
112 (bad or missing leapseconds table) -
The leapseconds table is missing, corrupted or bogus. -
113 (bad or missing certificate) -
The certificate is missing, corrupted or bogus. -
114 (bad or missing group key)
The identity key is missing, corrupt or bogus. - -
115 (protocol error) -
The protocol state machine has wedged due to unexpected restart -
116 (server certificate expired) -
The old server certificate has expired. -
-

Files

-

See the ntp-keygen page.

-

Leapseconds Table

-

The NIST provides a file documenting the epoch for all historic occasions of leap second insertion since 1972. The leapsecond table shows each epoch of insertion along with the offset of International Atomic Time (TAI) with respect to Coordinated Universal Time (UTC), as disseminated by NTP. The table can be obtained directly from NIST national time servers using ftp as the ASCII file pub/leap-seconds.

-

While not strictly a security function, the Autokey protocol provides means to securely retrieve the leapsecond table from a server or peer. Servers load the leapsecond table directly from the file specified in the crypto command, with default ntpkey_leap, while clients can obtain the table indirectly from the servers using the Autokey protocol. Once loaded, the table can be provided on request to other clients and servers.

-
- - - - \ No newline at end of file + + + +Authentication Commands and Options + + + + +

Authentication Commands and Options

+giffrom Alice's Adventures in Wonderland, Lewis Carroll +

Our resident cryptographer; now you see him, now you don't.

+

Last update: + 15-Oct-2011 01:00 + UTC

+
+

Related Links

+ + +
+

Commands and Options

+

Unless noted otherwise, further information about these commands is on the Authentication Support page.

+
+
automax [logsec]
+
Specifies the interval between regenerations of the session key list used with the Autokey protocol, as a power of 2 in seconds. Note that the size of the key list for each association depends on this interval and the current poll interval. The default interval is 12 (about 1.1 hr). For poll intervals above the specified interval, a session key list with a single entry will be regenerated for every message sent. See the Autokey Public Key Authentication page for further information.
+
controlkey keyid
+
Specifies the key ID for the ntpq utility, which uses the + standard protocol defined in RFC-1305. The keyid argument is the key ID for a trusted + key, where the value can be in the range 1 to 65534, + inclusive.
+
crypto [digest digest] [host name] [ident name] [pw password] [randfile file]
+
This command activates the Autokey public key cryptography + and loads the required host keys and certificate. If one or more files + are unspecified, the default names are used. Unless + the complete path and name of the file are specified, the location of a file + is relative to the keys directory specified in the keysdir configuration + command with default /usr/local/etc. See the Autokey Public Key Authentication page for further information. Following are the options.
+
+
+
digest digest
+
 
+
Specify the message digest algorithm, with default MD5. If the OpenSSL library + is installed, digest can be be any message digest algorithm supported + by the library. The current selections are: MD2, MD4, MD5, MDC2, RIPEMD160, SHA and SHA1. All + participants in an Autokey subnet must use the same algorithm. The Autokey message digest algorithm is separate and distinct from the symmetric + key message digest algorithm. Note: If compliance with FIPS 140-2 is required, + the algorithm must be ether SHA or SHA1.
+
host name
+
Specify the cryptographic media names for the host, sign and certificate files. If this option is not specified, the default name is the string returned by the Unix gethostname() routine.
+
Note: In the latest Autokey version, this option has no effect other than to change the cryptographic media file names.
+
ident group
+
Specify the cryptographic media names for the identity scheme files. If this option is not specified, the default name is the string returned by the Unix gethostname() routine.
+
Note: In the latest Autokey version, this option has no effect other than to change the cryptographic media file names.
+
pw password
+
Specifies the password to decrypt files previously encrypted by the ntp-keygen program with the -p option. If this option is not specified, the default password is the string returned by the Unix gethostname() routine.
+
randfile file
+
Specifies the location of the random seed file used by the OpenSSL library. The defaults are described on the ntp-keygen page.
+
+
+
ident group
+
Specifies the group name for ephemeral associations mobilized by broadcast and symmetric passive modes. See the Autokey Public-Key Authentication page for further information.
+
keys path
+
Specifies the complete directory path for the key file containing the key IDs, key types and keys used by ntpd, ntpq and ntpdc when operating with symmetric key cryptography. The format of the keyfile is described on the ntp-keygen page. This is the same operation as the -k command line option. Note that the directory path for Autokey cryptographic media is specified by the keysdir command.
+
keysdir path
+
Specifies the complete directory path for the Autokey cryptographic keys, parameters and certificates. The default is /usr/local/etc/. Note that the path for the symmetric keys file is specified by the keys command.
+
requestkey keyid
+
Specifies the key ID for the ntpdc utility program, which + uses a proprietary protocol specific to this implementation of ntpd. The keyid argument is a key ID + for a trusted key, in the range 1 to + 65534, inclusive.
+
revoke [logsec]
+
Specifies the interval between re-randomization of certain cryptographic values used by the Autokey scheme, as a power of 2 in seconds, with default 17 (36 hr). See the Autokey Public-Key Authentication page for further information.
+
trustedkey [keyid | (lowid ... highid)] [...]
+
Specifies the key ID(s) which are trusted for the purposes of + authenticating peers with symmetric key cryptography. Key IDs + used to authenticate ntpq and ntpdc operations + must be listed here and additionally be enabled with controlkey and/or requestkey. The authentication + procedure for time transfer requires that both the local and + remote NTP servers employ the same key ID and secret for this + purpose, although different keys IDs may be used with different + servers. Ranges of trusted key IDs may be specified: trustedkey (1 ... 19) 1000 (100 ... 199) enables the + lowest 120 key IDs which start with the digit 1. The spaces + surrounding the ellipsis are required when specifying a range.
+
+
+ + + diff --git a/contrib/ntp/html/autokey.html b/contrib/ntp/html/autokey.html new file mode 100644 index 000000000..ba220e656 --- /dev/null +++ b/contrib/ntp/html/autokey.html @@ -0,0 +1,215 @@ + + + + + +Autokey Public-Key Authentication + + + + +

Autokey Public-Key Authentication

+

Last update: + 3-Oct-2011 21:51 + UTC

+
+

Table of Contents

+ +
+

Introduction

+

This distribution includes support for the Autokey public key algorithms and protocol specified in RFC-5906 "Network Time Protocol Version 4: Autokey Specification". This support is available only if the OpenSSL library has been installed and the --enable-autokey option is specified when the distribution is built.

+

Public key cryptography is generally considered more secure than symmetric key cryptography. Symmetric key cryptography is based on a shared secret key which must be distributed by secure means to all participants. Public key cryptography is based on a private secret key known only to the originator and a public key known to all participants. A recipient can verify the originator has the correct private key using the public key and any of several digital signature algorithms.

+

The Autokey Version 2 protocol described on the Autokey Protocol page verifies packet integrity using message digest algorithms, such as MD5 or SHA, and verifies the source using digital signature schemes, such as RSA or DSA. As used in Autokey, message digests are exceptionally difficult to cryptanalyze, as the keys are used only once.

+

Optional identity schemes described on the Autokey Identity Schemes page are based on cryptographic challenge/response exchanges. Optional identity schemes provide strong security against masquerade and most forms of clogging attacks. These schemes are exceptionally difficult to cryptanalyze, as the challenge/response exchange data are used only once. They are described along with an executive summary, current status, briefing slides and reading list on the Autonomous Authentication page.

+

Autokey authenticates individual packets using cookies bound to the IP source and destination addresses. The cookies must have the same IP addresses at both the server and client. For this reason operation with network address translation schemes is not possible. This reflects the intended robust security model where government and corporate NTP servers and clients are operated outside firewall perimeters.

+

Autokey is designed to authenticate servers to clients, not the other way around as in SSH. An Autokey server can support an authentication scheme such as the Trusted Certificate (TC) scheme described in RFC 5906, while a client is free to choose between the various options. It is important to understand that these provisions are optional and that selection of which option is at the discretion of the client. If the client does not require authentication, it is free to ignore it, even if some other client of the same server elects to participate in either symmetric key or public key cryptography.

+

Autokey uses industry standard X.509 public certificates, which can be produced by commercial services, utility programs in the OpenSSL software library, and the ntp-keygen utility program in the NTP software distribution. A certificate includes the subject name of the client, the issuer name of the server, the public key of the client and the time period over which the the public and private keys are valid. All Autokey hosts have a self-signed certificate with the Autokey name as both the subject and issuer. During the protocol, additional certificates are produced with the Autokey host name as subject and the host that signs the certificate as issuer.

+

There are two timeouts associated with the Autokey scheme. The key list timeout is set by the automax command, which specifies the interval between generating new key lists by the client or server. The default timeout of about 1.1 hr is appropriate for the majority of configurations and ordinarily should not be changed. The revoke timeout is set by the revoke command, which specifies the interval between generating new server private values. It is intended to reduce the vulnerability to cryptanalysis; however, new values require the server to encrypt each client cookie separately. The default timeout of about 36 hr is appropriate for most servers, but might be too short for national time servers.

+

Autokey Subnets

+

An Autokey subnet consists of a collection of hosts configured as an acyclic, directed tree with roots one or more trusted hosts (THs) operating at the lowest stratum of the subnet. Note that the requirement that the NTP subnet be acyclic means that, if two hosts are configured with each other in symmetric modes, each must be a TH. The THs are synchronized directly or indirectly to national time services via trusted means, such as radio, satellite or telephone modem, or one or more trusted agents (TAs) of a parent subnet. NTP subnets can be nested, with the THs of a child subnet configured for one or more TAs of a parent subnet. The TAs can serve one or more child subnets, each with its own security policy and set of THs.

+

A certificate trail is a sequence of certificates, each signed by a host one step closer to the THs and terminating at the self-signed certificate of a TH. The requirement that the subnet be acyclic means certificate trails can never loop. NTP servers operate as certificate authorities (CAs) to sign certificates provided by their clients. The CAs include the TAs of the parent subnet and those subnet servers with dependent clients.

+

In order for the signature to succeed, the client certificate valid period must begin within the valid period of the server certificate. If the server period begins later than the client period, the client certificate has expired; if the client period begins later than the server period, the server certificate has expired.

+

The Autokey protocol runs for each association separately, During the protocol, the client recursively obtains the certificates on the trail to a TH, saving each in a cache ordered from most recent to oldest. If an expired certificate is found, it is invalidated and marked for later replacement. As the client certificate itself is not involved in the certificate trail, it can only be declared valid or expired when the server signs it.

+

The certificates derived from each association are combined in the cache with duplicates suppressed. If it happens that two different associations contribute certificates to the cache, a certificate on the trail from one association could expire before any on another trail. In this case the remaining trails will survive until the expired certificate is replaced. Once saved in the cache, a certificate remains valid until it expires or is replaced by a new one.

+

It is important to note that the certificate trail is validated only at startup when an association is mobilized. Once validated in this way, the server remains valid until it is demobilized, even if certificates on the trail to the THs expire. While the certificate trail authenticates each host on the trail to the THs, it does not validate the time values themselves. Ultimately, this is determined by the NTP on-wire protocol.

+

Example

+
gif +

Figure 1. Example Configuration

+
+

Figure 1 shows an example configuration with three NTP subnets, Alice, Helen and Carol. Alice and Helen are parent groups for Carol with TA C belonging to Alice and TA S belonging to Helen. Hosts A and B are THs of Alice, host R is the TH of Helen and host X is the TH of Carol. Assume that all associations are client/server, child subnet TH X has two mobilized associations, one to Alice TA host C and the other to Carol TA host S. While not shown in the figure, Alice hosts A and B could configure symmetric mode associations between them for redundancy and backup.

+

Note that host D certificate trail is D→C→A or D→C→B, depending on the particular order the trails are built. Host Y certificate trail is only Y→X, since X is a TH. Host X has two certificate trails X→C→A or X→C→B, and X→S→R.

+

Subnet Group Names

+

In some configurations where more than one subnet shares an Ethernet or when multiple subnets exist in a manycast or pool configuration, it is useful to isolate one subnet from another. In Autokey this can be done using group names. An Autokey host name is specified by the -s host@group option of the ntp-keygen program, where host is the host name and group is the group name. If host is omitted, the name defaults to the string returned by the Unix gethostname() routine, ordinarily the DNS name of the host. Thus, for host beauregard.udel.edu the option -s @red specifies the Autokey host name beauegard.udel.edu@red.

+

A subnet host with a given group name will discard ASSOC packets from all subnets with a different group name. This effectively disables the Autokey protocol without additional packet overhead. For instance, one or more manycast or pool servers will not respond to ASSOC packets from subnets with difference group names. Groups sharing an Ethernet will be filtered in the same way.

+

However, as shown in Figure 1, there are configurations where a TH of one group needs to listen to a TA of a different group. This is accomplished using the ident group option of the crypto command and/or the ident group option of the server command. The former case applies to all hosts sharing a common broadcast, manycast or symmetric passive modes, while the latter case applies to each individual client/server or symmetric active mode association. In either case the host listens to the specified group name in addition to the group name specified in the -s option of the ntp-keygen program.

+

Secure Groups

+

NTP security groups are an extension of the NTP subnets described in the previous section. They include in addition to certificate trails one or another identity schemes described on the Autokey Identity Schemes page. NTP secure groups are used to define cryptographic compartments and security + hierarchies. The identity scheme insures that the server is authentic and not victim of masquerade by an intruder acting as a middleman.

+

An NTP secure group is an NTP subnet configured as an acyclic tree rooted on the THs. The THs are at the lowest stratum of the secure group. They run an identity exchange with the TAs of parent subnets All group hosts construct an unbroken certificate trail from each host, possibly via intermediate hosts, and ending at a TH of that group. The TH verifies authenticity with the TA of the parent subnet using an identity exchange.

+
gif +

Figure 2. Identify Scheme

+
+

The identity exchange is run between a TA acting as a server and a TH acting as a client. As shown in Figure 2, the identity exchange involves a challenge-response protocol where a client generates a nonce and sends it to the server. The server performs a mathematical operation involving a second nonce and the secret group key, and sends the result along with a hash to the client. The client performs a another mathematical operation and verifies the result with the hash.

+

Since each exchange involves two nonces, even after repeated observations of many exchanges, an intruder cannot learn the secret group key. It is this quality that allows the secret group key to persist long after the longest period of certificate validity. In the Schnorr (Identify Friend or Foe - IFF) scheme, the secret group key is not divulged to the clients, so they cannot conspire to prove identity to other hosts.

+

As described on the Autokey Identity Schemes page, there are five identity schemes, three of which - IFF, GQ and MV - require identity files specific to each scheme. There are two types of files for each scheme, an encrypted server keys file and a nonencrypted client keys file, also called the parameters file, which usually contains a subset of the keys file.

+

Figure 2 shows how keys and parameters are distributed to servers and clients. A TA constructs the encrypted keys file and the nonencrypted parameters file. Hosts with no dependent clients can retrieve client parameter files from an + archive or web page. The ntp-keygen program can export parameter files using the -e option. By convention, the file name is the name of the secure group and must match the ident option of the crypto command or the ident option of the server command.

+

When more than one TH Is involved in the secure group, it is convenient for the TAs and THs to use the same encrypted key files. To do this, one of the parent TAs includes the -i group option on the ntp-keygen command line, where group is the name of the child secure group. The ntp-keygen program can export server keys files using the -q option and a chosen remote password. The files are installed on the TAs and then renamed using the name given as the first line in the file, but without the filestamp. The secure group name must match the ident option for all TAs.

+
+
In the latest Autokey version, the host name and group name are independent of each other and the host option of the crypto command is deprecated. When compatibility with older versions is required, specify the same name for both the -s and -i options.
+
+

In special circumstances the Autokey message digest algorithm can be changed using the digest option of the crypto command. The digest algorithm is separate and distinct from the symmetric + key message digest algorithm. If compliance with FIPS 140-2 is required, + the algorithm must be ether SHA or SHA1. The Autokey message digest algorithm must be the same for all participants in the NTP subnet.

+

Example

+

Returning to the example of Figure 1, Alice, Helen and Carol run run the Trusted Certificate (TC) scheme, internally, as the environment is secure and without threat from external attack, in particular a middleman masquerade. However, TH X of Carol is vulnerable to masquerade on the links between X and C and between X and S. Therefore, both parent subnet TAs C and S run an identity exchange with child subnet TH X. Both have the same encrypted keys file and X the common parameters file.

+

Configuration - Authentication Schemes

+

Autokey has an intimidating number of options, most of which are not necessary in typical scenarios. However, the Trusted Certificate (TC) scheme is recommended for national NTP time services, such as those operated by NIST and USNO. Configuration for TC is very simple.

+

Referring to Figure 1, for each TH, A, B, R and X, as root:

+

# cd /usr/local/etc
+ # ntp-keygen -T

+

and for the other hosts the same commands without the -T option. This generates an RSA private/public host key file and a self-signed certificate file for the RSA digital signature algorithm with the MD5 message digest algorithm. For the THs a trusted certificate is generated; for the others a nontreusted certificate is generated. Include in the ntp.conf configuration file for all hosts other than the primary servers, A, B and R, something like

+

# server host autokey
+ # crypto
+ # driftfile /etc/ntp.drift

+

where host is the selected server name as shown in the figure. Servers A, B and R are configured for local reference clocks or trusted remoter servers as required.

+

In the above configuration examples, the default host name is the string returned by the Unix gethostname() routine, ordinarily the DNS name of the host. This name is used as the subject and issuer names on the certificate, as well as the default password for the encrypted keys file. The host name can be changed using the -s option of the ntp-keygen program. The default password can be changed using the -p option of the ntp-keygen program and the pw option of the crypto configuration command.

+

Group names can be added to this configuration by including the -s host@group option with the ntp-keygen program. For the purpose of illustration, the host string is empty, signifying the default host name. For example, @yellow can be used for the Alice group, @orange for the Helen group and @blue for the Carol group. In addition, for TH X the ident yellow option should be added to the server command for the Alice group and the ident orange option should be added to the server command for the Helen group.

+

Configuration - Identity Schemes

+

The example in this section uses the IFF identity scheme, but others, including GQ and MV, can be used as well. It's best to start with a functioning TC configuration and add commands as necessary. We start with the subnets of Figure 1 configured as in the previous section. Recall that the parent subnet TA for Alice is C and for Helen is S. Each of the TAs generates an encrypted server keys file and nonencrypted client parameters file for the IFF identity scheme using the -I option of the ntp-keygen program. Note the TAs are not necessarily trusted hosts, so may not need the -T option.

+

The nonencrypted client parameters can be exported using the command

+

ntp-keygen -e >file,

+

where the -e option redirects the client parameters to file via the standard output stream for a mail application or stored locally for later distribution to one or more THs. In a similar fashion the encrypted keys file can be exported using the command

+

ntp-keygen -q passw2 >file,

+

where passwd2 is the read password for another TA. We won't need this file here.

+

While the file names used for the exported files are arbitrary, it is common practice to use the name given as the first line in the file with the filestamp suppressed. Thus, the nonencryted parameters file from each TA is copied to X with this name.

+

To complete the configuration, the TH includes the client parameters file name in the ident option of the the server command for the TA association

+

server 1.2.3.4 ident group,

+

where group is the file name given above.

+

Identity Schemes and Cryptotypes

+

A specific combination of authentication and identity schemes is called a cryptotype, which applies to clients and servers separately. A group can be configured using more than one cryptotype combination, although not all combinations are interoperable. Note however that some cryptotype combinations may successfully intemperate with each other, but may not represent good security practice. The server and client cryptotypes are defined by the the following codes.

+
+
NONE
+
A client or server is type NONE if authentication is not available or not configured. Packets exchanged between client and server have no MAC.
+
AUTH
+
A client or server is type AUTH if the key option is specified with the server configuration command and the client and server keys are compatible. Packets exchanged between clients and servers have a MAC.
+
PC
+
A client or server is type PC if the autokey option is specified with the server configuration command and compatible host key and private certificate files are present. Packets exchanged between clients and servers have a MAC.
+
TC
+
A client or server is type TC if the autokey option is specified with the server configuration command and compatible host key and public certificate files are present. Packets exchanged between clients and servers have a MAC.
+
IDENT
+
A client or server is type IDENT if the autokey option is specified with the server configuration command and compatible host key, public certificate and identity scheme files are present. Packets exchanged between clients and servers have a MAC.
+
+

The compatible cryptotypes for clients and servers are listed in the following table.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ClientServer
NONEAUTHPCTCIDENT
NONEyesyes*yes*yes*yes*
AUTHnoyesnonono
PCnonoyesnono
TCnononoyesyes
IDENTnonononoyes
+

* These combinations are not valid if the restriction list includes the notrust option.

+

Error Codes

+

Errors can occur due to mismatched configurations, unexpected protocol restarts, expired certificates and unfriendly people. In most cases the protocol state machine recovers automatically by retransmission, timeout and restart, where necessary. Some errors are due to mismatched keys, digest schemes or identity schemes and must be corrected by installing the correct media and/or correcting the configuration file. One of the most common errors is expired certificates, which must be regenerated and signed at least once per year using the ntp-keygen - generate public and private keys program.

+

The following error codes are reported via the NTP control and monitoring protocol trap mechanism and to the cryptostats monitoring file if configured.

+
+
101 bad field format or length
+
The packet has invalid version, length or format.
+
102 bad timestamp
+
The packet timestamp is the same or older than the most recent received. This could be due to a replay or a server clock time step.
+
103 bad filestamp
+
The packet filestamp is the same or older than the most recent received. This could be due to a replay or a key file generation error.
+
104 bad or missing public key
+
The public key is missing, has incorrect format or is an unsupported type.
+
105 unsupported digest type
+
The server requires an unsupported digest/signature scheme.
+
106 unsupported identity type
+
The client or server has requested an identity scheme the other does not support.
+
107 bad signature length
+
The signature length does not match the current public key.
+
108 signature not verified
+
The message fails the signature check. It could be bogus or signed by a different private key.
+
109 certificate not verified
+
The certificate is invalid or signed with the wrong key.
+
110 host certificate expired
+
The old server certificate has expired.
+
111 bad or missing cookie
+
The cookie is missing, corrupted or bogus.
+
112 bad or missing leapseconds table
+
The leapseconds table is missing, corrupted or bogus.
+
113 bad or missing certificate
+
The certificate is missing, corrupted or bogus.
+
114 bad or missing group key
+
The identity key is missing, corrupt or bogus.
+
115 protocol error
+
The protocol state machine has wedged due to unexpected restart.
+
+

Files

+

See the ntp-keygen page. Note that provisions to load leap second values from the NIST files have been removed. These provisions are now available whether or not the OpenSSL library is available. However, the functions that can download these values from servers remains available.

+
+

+ +

+ + diff --git a/contrib/ntp/html/bugs.html b/contrib/ntp/html/bugs.html new file mode 100644 index 000000000..7be6a4c11 --- /dev/null +++ b/contrib/ntp/html/bugs.html @@ -0,0 +1,27 @@ + + + + + +NTP Bug Reporting Procedures + + + + +

NTP Bug Reporting Procedures

+giffrom Alice's Adventures in Wonderland, Lewis Carroll +

The rabbit toots to make sure you read this.

+

Last update: + 23-Aug-2014 05:32 +UTC

+.
+
+

Security Bug Reporting Procedures

+

If you find or suspect a security related program bug in this distribution, please send a report to security@ntp.org. Please do not contact developers directly.

+

Non-Security Bug Reporting Procedures

+

If you find or suspect a non-security related program or documentation bug in this distribution, please send a report to the NTP Public Service Project Bug Tracking System (Bugzilla) at http://bugs.ntp.org/. Bugs reported this way are immediately forwarded to the developers. Please do not contact the developers directly.

+

If you wish to send a report via electronic mail, please remember that your report will be held until one of our volunteers enters it in Bugzilla. The email address for these reports is bugs@ntp.org. You will need to register at http://bugs.ntp.org/ to participate directly in any e-mail discussion regarding your report. If you don't register and we have questions for you we won't be able to make progress on fixing your problem. Please directly register on and use our Bugzilla instance to report issues.

+
+ + + diff --git a/contrib/ntp/html/build.html b/contrib/ntp/html/build.html new file mode 100644 index 000000000..5e3c2d811 --- /dev/null +++ b/contrib/ntp/html/build.html @@ -0,0 +1,57 @@ + + + + + +Building and Installing the Distribution + + + +

Building and Installing the Distribution

+giffrom Pogo, Walt Kelly +

For putting out compiler fires.

+

Last update: + 1-Apr-2015 02:57 +

+
+

Related Links

+ +

Table of Contents

+ +
+

Building and Installing the Distribution

+

It is not possible in a software distribution such as this to support every individual computer and operating system with a common executable, even with the same system but different versions and options. Therefore, it is necessary to configure, build and install for each system and version. In almost all cases, these procedures are completely automatic, The user types ./configure, and make install in that order and the autoconfigure system does the rest. There are some exceptions, as noted below and on the Hints and Kinks pages.

+

If available, the OpenSSL library from http://www.openssl.org is used to support public key cryptography. The library must be built and installed prior to building NTP. The procedures for doing that are included in the OpenSSL documentation. The library is found during the normal NTP configure phase and the interface routines compiled automatically. Only the libcrypto.a library file and openssl header files are needed. If the library is not available or disabled, this step is not required.

+

The Build Options page describes a number of options that determine whether debug support is included, whether and which reference clock drivers are included and the locations of the executables and library files, if not the default. By default debugging options and all reference clock drivers are included.

+

Building and Installing for Unix

+

This distribution uses common compilers and tools that come with most Unix distributions. Not all of these tools exist in the standard distribution of modern Unix versions (compilers are likely to be an add-on product). If this is the case, consider using the GNU tools and gcc compiler included as freeware in some systems. For a successful build, all of these tools should be accessible via the current path.

+

The first thing to do is uncompress the distribution and extract the source tree. In the distribution base directory use the ./configure command to perform an automatic configuration procedure. This command inspects the hardware and software environment and configures the build process accordingly. Use the make command to compile and link the distribution and the install command to install the executables by default in /usr/local/bin.

+

If your site supports multiple architectures and uses NFS to share files, you can use a single source tree to build executables for multiple architectures. While running on a particular architecture, change to the base directory and create a subdirectory using a command like mkdir A.machine, which will create an architecture-specific directory, then change to this directory and mumble ../configure. The remaining steps are the same whether building in the base directory or in the subdirectory.

+

Building and Installing for Windows

+

NTP supports Windows 2000 and later. See the NTP 4.x for Windows NT page for directions to compile the sources and install the executables. A precompiled executable is available.

+

Configuration

+

You are now ready to configure the daemon. You will need to create a NTP configuration file by default in /etc/ntp.conf. Newbies should see the Quick Start page for orientation. Seasoned veterans can start with the ntpd - Network Time Protocol (NTP) daemon page and move on to the specific configuration option pages from there.

+

If You Have Problems

+

If you have problems with your hardware and software environment (e.g. operating system-specific issues), browse the Hints and Kinks pages. For other problems a tutorial on debugging technique is in the NTP Debugging Technique page. A list of important system log messages is on the ntpd System Log Messages page.

+

The first line of general assistance is the NTP web site www.ntp.org and the helpful documents resident there. Requests for assistance of a general nature and of interest to other timekeepers should be sent to the NTP newsgroup comp.protocols.time.ntp.

+

Users are invited to report bugs and offer suggestions via the NTP Bug Reporting Procedures page.

+

Additional make commands

+
+
make clean
+
Cleans out object files, programs and temporary files.
+
make distclean
+
Does the work of clean, but cleans out all directories in preparation for a new distribution release.
+
make dist
+
Does the work of make distclean, but constructs compressed tar files for distribution. You must have GNU automake to perform this function.
+
+
+ + + diff --git a/contrib/ntp/html/build/build.html b/contrib/ntp/html/build/build.html deleted file mode 100644 index 0bb49afda..000000000 --- a/contrib/ntp/html/build/build.html +++ /dev/null @@ -1,83 +0,0 @@ - - - - - - - Building and Installing the Distribution - - - - -

Building and Installing the Distribution

- giffrom Pogo, Walt Kelly -

For putting out compiler fires.

-

Last update: 03:06 AM UTC Monday, October 13, 2003

-
-

Related Links

- -

Table of Contents

- -
-

Building and Installing the Distribution

-

As a practical matter, every computer architecture and operating system version seems to be different than any other. The device drivers may be different, the input/output system may be idiosyncratic and the libraries may have different semantics. It is not possible in a software distribution such as this one to support every individual system with a common set of binaries, even with the same system but different versions. Therefore, it is necessary to individually configure the software build for each system and version, both at compile time and at run time. In almost all cases, these procedures are completely automatic and all the newbie user need do is type "configure", "make" and "install" in that order and the autoconfigure system does the rest. There are some exceptions, as noted below and on the Hints and Kinks page.

-

If available, the OpenSSL library from http://www.openssl.org is used to support public key cryptography. The library must be built and installed prior to building NTPv4. The procedures for doing that are included in the OpenSSL documentation. The library is found during the normal NTPv4 configure phase and the interface routines compiled automatically. Only the libcrypto.a library and associated header files are used. If the library is not available or disabled, this step is not required.

-

Building and Installing under Unix

-

Make sure that you have all necessary tools for building executables. These tools include cc/gcc, make, awk, sed, tr, sh, grep, egrep and a few others. Not all of these tools exist in the standard distribution of modern Unix versions (compilers are likely to be an add-on product). If this is the case, consider using the GNU tools and gcc compiler. For a successful build, all of these tools should be accessible via the current path.

-

The first thing to do is uncompress the distribution and extract the source tree. In the distribution base directory use the ./configure command to perform an automatic configuration procedure. This command inspects the hardware and software environment and tests for the presence of system header files and the contents of these files to determine if certain features are present. When one or more of these features are present, the code is compiled to use them; if not, no special code is compiled. However, even if the code is compiled to use these features, the code does a special test at run time to see if one or more are actually present and avoids using them if not present. In such cases a warning message is sent to the system log, but the daemon should still work properly.

-

The default build normally includes the debugging code, which can be useful in diagnosing problems found in initial test, and all reference clock drivers known to work with each machine and operating system. Unless memory space is at a premium, this is a sensible strategy and greatly simplifies debugging and support. If you need to delete either the debugging code or one or all reference clock drivers to save space, see the Configuration Options page.

-

If your site supports multiple architectures and uses NFS to share files, you can use a single source tree to compile executables for all architectures. While running on a target architecture machine and in the distribution base directory create a subdirectory using a command like mkdir A.`config.guess`, which will create an architecture-specific directory with name peculiar to the architecture and operating system. Then change to this directory and emit a ../configure command. The remaining steps are the same whether building in the base directory or in the subdirectory.

-

Compilation

-

Use the make command to compile all source modules, construct the libraries and link the distribution. Expect few or no warnings using cc and a moderate level of warnings using gcc. Note: On some Unix platforms gcc may show quite a few complaints about system header files and type inconsistencies, especially with pointer variables. This is usually the case when the system header files are not up to ANSI standards or gcc expectations, when gcc is not installed properly, or when operating system updates and patches are applied and gcc is not reinstalled. While the autoconfigure process is quite thorough, the Unix programming cultures of the various workstation makers still remain idiosyncratic.

-

Installation

-

As root, use the make install command to install the binaries in the destination directory. Most commonly, these programs are installed in /usr/local/bin, but this can be overridden during configuration. You must of course have write permission on the install in the destination directory. This includes the following programs:

- -

If the precision time kernel modifications are present, the following program is installed:

- -

If the public key authentication functions are present, the following program is installed:

- -

In some systems that include the capability to edit kernel variables, the following program is installed:

- -

Cryptographic support, both symmetric and public key, requires one or more key files, commonly installed in /usr/local/etc. Public key cryptography requires a random seed file, usually called .rnd, installed in a dark place such as the root directory or /etc. Directions for generating keys is on the Authentication Options page.

-

Configuration

-

You are now ready to configure the daemon and start it. You will need to create a NTP configuration file ntp.conf and a cryptographic key file ntp.keys. The latter file is necessary only for remote configuration support, if needed. Newbies should see the Quick Start page for orientation. Seasoned veterans can start with the ntpd - Network Time Protocol (NTP) daemon page and move on to the specific configuration option pages from there. A tutorial on NTP subnet design and configuration options is in the Notes on Configuring NTP and Setting up a NTP Subnet page.

-

If You Have Problems

-

If you have problems peculiar to the particular hardware and software environment (e.g. operating system-specific issues), browse the Hints and Kinks page. For other problems a tutorial on debugging technique is in the NTP Debugging Technique page. As always, the first line of general assistance is the NTP web site www.ntp.org and the FAQ resident there. Requests for assistance of a general nature and of interest to other timekeepers should be sent to the NTP newsgroup comp.protocols.time.ntp. Bug reports of a specific nature should be sent to bugs@ntp.org. Bug reports of a specific nature on features implemented by the programmer corps mentioned in the Copyright page should be sent directly to the implementor listed in that page, with copy to bugs@ntp.org.

-

Please include the version of the source distribution (e.g., ntp-4.0.70a) in your bug report, as well as billboards from the relevant utility programs and debug trace, if available. Please include the output of config.guess in your bug report. It will look something like:

-

pdp11-dec-fuzzos3.4

-

Additional make commands

-
-
make clean -
Cleans out object files, programs and temporary files. -
make distclean -
Does the work of clean, but cleans out all directories in preparation for a new distribution release. -
make dist -
Does the work of make distclean, but constructs compressed tar files for distribution. You must have GNU automake to perform this function. -
-

Building and Installing under Windows NT

-

See hints/winnt.htm for directions to compile the sources and install the executables.

-
- - - - \ No newline at end of file diff --git a/contrib/ntp/html/build/config.html b/contrib/ntp/html/build/config.html deleted file mode 100644 index 961779de6..000000000 --- a/contrib/ntp/html/build/config.html +++ /dev/null @@ -1,168 +0,0 @@ - - - - - - - Configuration Options - - - - -

Configuration Options

- giffrom Pogo, Walt Kelly -

Gnu autoconfigure tools are in the backpack.

-

Last update: 12:56 AM UTC Saturday, March 20, 2004

-
-

Table of Contents

- -
-

Basic Configuration Options - the configure utility

-

The following options are for compiling and installing a working version of the NTP distribution. In most cases, the build process is completely automatic. In some cases where memory space is at a premium, or the binaries are to be installed in a different place, it is possible to tailor the configuration to remove such features as reference clock driver support, debugging support, and so forth.

-

Configuration options are specified as arguments to the configure script. Following is a summary of the current options, as of the 4.0.99m version:

-

Usage: configure [options] [host]
-

-

Options

-

[defaults in brackets after descriptions] Configuration:

-
- --cache-file=FILE      cache test results in FILE
- --help                 print this message
- --no-create            do not create output files
- --quiet, --silent      do not print `checking...' messages
- --version              print the version of autoconf that created
-configure
-
-

Directory and File Names

-
- --prefix=PREFIX        install architecture-independent files in PREFIX [/usr/local]
- --exec-prefix=EPREFIX  install architecture-dependent files in EPREFIX [same as prefix]
- --bindir=DIR           user executables in DIR [EPREFIX/bin]
- --sbindir=DIR          system admin executables in DIR [EPREFIX/sbin]
- --libexecdir=DIR       program executables in DIR [EPREFIX/libexec]
- --datadir=DIR          read-only architecture-independent data in DIR [PREFIX/share]
- --sysconfdir=DIR       read-only single-machine data in DIR [PREFIX/etc]
- --sharedstatedir=DIR   modifiable architecture-independent data in DIR [PREFIX/com]
- --localstatedir=DIR    modifiable single-machine data in DIR [PREFIX/var]
- --libdir=DIR           object code libraries in DIR [EPREFIX/lib]
- --includedir=DIR       C header files in DIR [PREFIX/include]
- --oldincludedir=DIR    C header files for non-gcc in DIR [/usr/include]
- --infodir=DIR          info documentation in DIR [PREFIX/info]
- --mandir=DIR           man documentation in DIR [PREFIX/man]
- --srcdir=DIR           find the sources in DIR [configure dir or ..]
- --x-includes=DIR       X include files are in DIR
- --x-libraries=DIR      X library files are in DIR
- --program-prefix=PREFIX           prepend PREFIX to installed program names
- --program-suffix=SUFFIX           append SUFFIX to installed program names
- --program-transform-name=PROGRAM  run sed PROGRAM on installed program names
-
-

Host Type

-
- --build=BUILD          configure for building on BUILD [BUILD=HOST]
- --host=HOST            configure for HOST [guessed]
- --target=TARGET        configure for TARGET [TARGET=HOST]
-
-

Optional Packages

-
- --with-PACKAGE[=ARG]   use PACKAGE [ARG=yes]
- --without-PACKAGE      do not use PACKAGE (same as --with-PACKAGE=no)
-
- openssl-libdir=DIR     OpenSSL object code libraries in DIR [/usr/lib/usr/local/lib/usr/local/ssl/lib]
- openssl-incdir=DIR     OpenSSL header files in DIR [/usr/include/usr/local/include/usr/local/ssl/include]
- crypto=autokey         Use autokey cryptography
- crypto=rsaref          Use the RSAREF library
- electricfence          Compile with ElectricFence malloc debugger
-
-

Optional Features

-
- --disable-FEATURE      do not include FEATURE (same as
- --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
-
- accurate-adjtime       The adjtime() call is accurate
- clockctl               use /dev/clockctl (non root control of system clock)
- debugging              Include debugging code [enable]
- des                    Include support for DES keys [enable]
- dst-minutes=VALUE      Minutes per DST adjustment [60]
- gdt-surveying          Include GDT survey code [disable]
- hourly-todr-sync       If we should sync TODR hourly
- kernel-fll-bug         If we should avoid a (Solaris) kernel FLL bug
- kmem                   Read /dev/kmem for 'tick' and/or 'tickadj'
- md5                    Include support for MD5 keys [enable]
- ntpdate-step           If ntpdate should step the time
- slew-always            Always slew the time
- step-slew              Step and slew the time
- tick=VALUE             Force a value for 'tick'
- tickadj=VALUE          Force a value for 'tickadj'
- udp-wildcard           Use UDP wildcard delivery
-
-

Radio Clocks

-

(these are ordinarily enabled, if supported by the machine and operating system):

-
- all-clocks             Include drivers for all suitable non-PARSE clocks [enable]
- ACTS                   NIST dialup clock
- ARBITER                Arbiter 1088A/B GPS receiver
- ARCRON_MSF             Arcron MSF receiver
- AS2201                 Austron 2200A or 2201A GPS receiver
- ATOM                   ATOM PPS interface
- AUDIO-CHU              CHU audio decoder
- BANCOMM                Datum/Bancomm BC635/VME interface (requires an explicit --enable-BANCOMM request)
- CHRONOLOG              Chrono-log K-series WWVB receiver
- CHU                    CHU modem decoder
- DATUM                  Datum Programmable Time System
- DUMBCLOCK              Dumb generic hh:mm:ss local clock
- FG                     Forum Graphic GPS
- GPSVME                 TrueTime GPS receiver with VME interface (requires an explicit --enable-GPSVME request)
- HEATH                  HeathKit GC-1000 Most Accurate Clock
- HOPFPCI                HOPF 6039 PCI board
- HOPFSERIAL             HOPF serial clock device
- HPGPS                  HP 58503A GPS Time & Frequency receiver
- IRIG                   IRIG (Audio) Clock
- JUPITER                Rockwell Jupiter GPS receiver
- LEITCH                 Leitch CSD 5300 Master Clock System Driver
- LOCAL-CLOCK            Local clock driver
- MSFEES                 EES M201 MSF receiver
- MX4200                 Magnavox MX4200 GPS receiver
- NMEA                   NMEA GPS receiver
- ONCORE                 Motorola VP/UT Oncore GPS receiver
- PALISADE               Palisade clock
- PCF                    Conrad parallel port radio clock
- PST                    PST/Traconex 1020 WWV/H receiver
- PTBACTS                PTB dialup clock support
- SHM                    Clock attached through shared memory (requires an explicit --enable-SHM request)
- SPECTRACOM             Spectracom 8170/Netclock/2 WWVB receiver
- TRAK                   TRAK 8810 GPS station clock
- TPRO                   KSI/Odetics TPRO/S IRIG Interface
- TRUETIME               Kinemetrics/TrueTime (generic) receiver
- ULINK                  Ultralink WWVB receiver
- USNO                   US Naval Observatory dialup clock
- WWV                    WWV audio receiver
-
-

PARSE Clocks

-
- parse-clocks           Include drivers for all suitable PARSE clocks [enable]
- COMPUTIME              Diem Computime Radio Clock
- DCF7000                ELV/DCF7000 Clock
- HOPF6021               HOPF 6021 Radio Clock support
- MEINBERG               Meinberg clocks
- RAWDCF                 DCF77 raw time code
- RCC8000                RCC 8000 Radio Clock support
- SCHMID                 SCHMID DCF77 clock support
- TRIMTAIP               Trimble GPS/TAIP Protocol
- TRIMTSIP               Trimble GPS/TSIP Protocol
- VARITEXT               VARITEXT clock
- WHARTON                Wharton 400A Series clock
-
-
- - - - \ No newline at end of file diff --git a/contrib/ntp/html/build/hints.html b/contrib/ntp/html/build/hints.html deleted file mode 100644 index b9e230ba2..000000000 --- a/contrib/ntp/html/build/hints.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - Hints and Kinks - - - - -

Hints and Kinks

- gif from Alice's Adventures in Wonderland, Lewis Carroll -

Mother in law has all the answers.

-

Last update: 12:56 AM UTC Saturday, March 20, 2004

-
-
-

This is an index for a set of troubleshooting notes contained in individual text files in the ./hints directory. They were supplied by various volunteers in the form of mail messages, patches or just plain word of mouth. Each note applies to a specific computer and operating system and gives information found useful in setting up the NTP distribution or site configuration. The notes are very informal and subject to errors; no attempt has been made to verify the accuracy of the information contained in them.

-

Additions or corrections to this list or the information contained in the notes is solicited. The most useful submissions include the name of the computer manufacturer (and model numbers where appropriate), operating system (specific version(s) where appropriate), problem description, problem solution and submitter's name and electric address. If the submitter is willing to continue debate on the problem, please so advise. See the directory listing.

-
- - - - \ No newline at end of file diff --git a/contrib/ntp/html/build/hints/netbsd b/contrib/ntp/html/build/hints/netbsd deleted file mode 100644 index f5f628db4..000000000 --- a/contrib/ntp/html/build/hints/netbsd +++ /dev/null @@ -1,37 +0,0 @@ -Starting with NetBSD-1.6, it is possible to delegate the system clock -control to a non root user. This enable running ntpd in a chroot -jail under a non privilegied UID/GID, using ntpd -i and -u flags. - -The delegation is done through the clockctl(4) pseudodevice driver. -This driver makes privilegied system calls such as ntp_adjtime(2) -available through ioctl(2) on the /dev/clockctl device. If a user -is able to write to /dev/clockctl, then (s)he can control the system -clock. - -In order to use this feature, make sure that: - -1) Your kernel is compiled with the following option: -pseudo-device clockctl -This is true for GENERIC kernels on most ports. Please check -http://wwW.netbsd.org/Documentation/kernel/ -if you need information about building a kernel. - -2) You have a ntpd user on your system. Here is the /etc/master.passwd -entry for ntpd user on NetBSD-1.6: -ntpd:*:15:15::0:0:& pseudo-user:/var/chroot/ntpd:/sbin/nologin -And here is the /etc/group entry for group 15: -ntpd:*:15: - -3) /dev/clockctl exists and is writtable by user ntpd. Default -NetBSD-1.6 setting is: -crw-rw---- 1 root ntpd 61, 0 Apr 1 2002 /dev/clockctl -Major device number and date is likely to be different on your system. -If you need to create the device, issue the following command: -cd /dev && ./MAKEDEV clockctl - -Here is an example of how to run ntpd chrooted in /var/chroot/ntpd, -running with ntpd UID and ntpd GID: -ntpd -i /var/chroot/ntpd -u ntpd:ntpd -Note that -i and -u options are enabled at configure time if your -system supports system clock control by an unprivilegied user. If this -is not the case, then the -i and -u options will not be available. diff --git a/contrib/ntp/html/build/hints/solaris.html b/contrib/ntp/html/build/hints/solaris.html deleted file mode 100644 index 9dc2ab15d..000000000 --- a/contrib/ntp/html/build/hints/solaris.html +++ /dev/null @@ -1,144 +0,0 @@ - - -Solaris hints and kinks - - - -Information on compiling and executing ntpd under Solaris. -
-Last Updated: Sun Jun 21 01:32:18 EDT 1998, -John Hawkinson, - <jhawk@MIT.EDU> -

-If you're not running Solaris 2.5.1 or later, it is likely -that you will have problems; upgrading would be a really good plan. -

-

All Solaris versions

-

- We have a report that says starting with Solaris 2.6 we should leave - dosynctodr alone. - Here is the report. -

-Proper operation of ntp under Solaris may require setting the kernel -variable dosynctodr to zero (meaning "do not synchronize the clock -to the hardware time-of-day clock"). This can be done with the -tickadj utility: -

-tickadj -s -
-If you prefer, it can also be done with the native Solaris kernel debugger: -
-echo dosynctodr/W0 | adb -k -w /dev/ksyms /dev/mem -
-

-Or, it can also be set by adding a line to /etc/system: -

-set dosynctodr = 0 -
-

-Instead of the tick kernel variable, which many operating -systems use to control microseconds added to the system time every -clock tick (c.f. Dealing -with Frequency Tolerance Violations), Solaris has the variables -nsec_per_tick and usec_per_tick. -

-nsec_per_tick and usec_per_tick control the number of -nanoseconds and microseconds, respectively, added to the system clock -each clock interrupt. Enterprising souls may set these based on -information collected by ntpd in the /etc/ntp.drift file -to correct for individual hardware variations. -

-On UltraSPARC systems, nsec_per_tick and usec_per_tick -are ignored in favor of the cpu_tick_freq variable, which -should be automatically be determined by the PROM in an accurate -fashion. -

-In general, the same ntp binaries should not be used across multiple -operating system releases. There is enough variation in the core operating -system support for timekeeping that a rebuild of ntpd for the idiosyncracies -of your specific operating system version is advisable. -

-It is recommended that ntp be started via a script like this one, installed in -/etc/init.d/ntpd with a symbol link from -/etc/rc2.d/S99ntpd. - -

Solaris 2.6

-

-Solaris 2.6 adds support for kernel PLL timekeeping, but breaks this -support in such a fashion that using it worse than not. This is SUN Bug ID 4095849, and it is not yet -fixed as of June 1998. -

-

Solaris 2.5 and 2.5.1

-

-On UltraSPARC systems, calculation of cpu_tick_freq is broken -such that values that are off by significant amounts may be used -instead. This unfortunately means that ntpd may have severe problems -keeping synchronization. This is SUN Bug ID -4023118. Bryan Cantrill of Sun -posted patchfreq, a workaround script, -to comp.protocols.time.ntp in March of 1997. -

-


-

OLD DATA

-I can't vouch for the accuracy the information below this -rule. It may be significantly dated or incorrect. -

-

-

Solaris 2.2

-

-Solaris 2.2 and later contain completely re-written clock code to -provide high resolution microsecond timers. A benefit of the -re-written clock code is that adjtime does not round off its -adjustments, so ntp does not have to compensate for this -rounding. Under Solaris 2.2 and later, ntp #define's -ADJTIME_IS_ACCURATE, and does not look for the tickadj -kernel variable. -

-

Solaris 2.1

-(This originally written by William L. Jones <jones@chpc.utexas.edu>) -

-Solaris 2.1 contains fairly traditional clock code, with tick -and tickadj. -

-Since settimeofday under Solaris 2.1 only sets the seconds part of timeval -care must be used in starting xntpd. I suggest the following start -up script: -

-tickadj -s -a 1000 -
ntpdate -v server1 server2 -
sleep 20 -
ntpdate -v server1 server2 -
sleep 20 -
tickadj -a 200 -
xntpd -
- -The first tickadj turns of the time of day clock and sets the tick -adjust value to 1 millisecond. This will insure that an adjtime value -of at most 2 seconds will complete in 20 seconds. -

-The first ntpdate will set the time to within two seconds -using settimeofday or it will adjust time using adjtime. -

-The first sleep insures the adjtime has completed for the first ntpdate. -

-The second ntpdate will use adjtime to set the time of day since the -clock should be within 2 seconds of the correct time. -

-The second tickadj set the tick adjust system value to 5 microseconds. -

-The second sleeps insure that adjtime will complete before starting -the next xntpd. -

-I tried running with a tickadj of 5 microseconds with out much success. -200 microseconds seems to work well. -

-


-Prior versions of this file had major text contributed by: - -
  • Denny Gentry <denny@eng.sun.com> -
  • - - diff --git a/contrib/ntp/html/build/hints/vxworks.html b/contrib/ntp/html/build/hints/vxworks.html deleted file mode 100644 index 95ad22224..000000000 --- a/contrib/ntp/html/build/hints/vxworks.html +++ /dev/null @@ -1,82 +0,0 @@ - - - - - - vxWorks Port of NTP - - - - -

    VxWorks port of NTP

    -

    Creating a port for vxWorks posed some problems. This port may help as a starting point for similar ports to real-time OS's and other embeddable kernels, particularly where main() is not allowed, and where the configure scripts need to be altered.

    -

    Configuration issues

    -

    I decided to do as little invasive surgery as possible on the NTP code, so I brought the vxWorks header tree in line with the standard unix tree. The following changes were needed, as a side effect these changes will allow for easy porting of other autoconfigure enabled code.

    -

    Where I have 386 you will need to put in your target type. The vxWorks tree entry point is /usr/wind. If these are the same for your system, you should be able to cut and paste the changes.

    -

    WARNING: Check you are not overwriting files, before entering the following: there should be no conflict, but check first...

    -

    export CC="cc386 -nostdlib -m486 -DCPU=I80486 -I/usr/wind/target/h"
    - export RANLIB=ranlib386
    - export AR=ar386
    - export VX_KERNEL=/usr/wind/target/config/ims_std_bsp/vxWorks
    - cd /usr/wind/target/sys
    - ln -s ../signal.h
    - ln -s ../time.h
    - ln -s socket.h sockio.h
    - ln -s ../selectLib.h select.h
    - ln -s ../timers.h
    - touch file.h param.h resource.h utsname.h var.h ../netdb.h ../a.out.h ../termios.h
    - echo " ******ADD #include \"sys/times.h\" to sys/time.h "

    -

    The configure script must be changed in the following way to get the linking tests to work, once in the correct directory issue the following commands:
    - sed -e 's%main.*()%vxmain()%' configure > configure.vxnew
    - mv configure.vxnew configure
    - chmod 755 configure

    -

    The new version 4 of NTP requires some maths functions so it links in the maths library (-lm) in the ntpd Makefile.am change the line "ntpd_LDADD = $(LDADD) -lm" by removing the "-lm".
    - You are now ready to compile

    -


    - The configure.in file needed to be altered to allow for a host-target configuration to take place.

    -
      -
    • The define SYS_VXWORKS was added to the compilation flags. -
    • Little endianess is set if the target is of type iX86. -
    • The size of char, integer, long values are all set. If Wind River ever changes these values they will need to be updated. -
    • clock_settime() is defined to be used for setting the clock. -
    • The Linking flags have -r added to allow for relinking into the vxWorks kernel -
    -

    Unfortunately I have had to make use of the ntp_machine.h file to add in the checks that would have been checked at linking stage by autoconf, a better method should be devised.

    -
      -
    • There is now a NO_MAIN_ALLOWED define that simulates command line args, this allows the use of the normal startup sysntax. -
    • POSIX timers have been added. -
    • Structures normally found in netdb.h have been added with, the corresponding code is in machines.c . Where possible the defines for these have been kept non-vxWorks specific. -
    -

    Unfortunately there are still quite a few SYS_VXWORKS type defines in the source, but I have eliminated as many as possible. You have the choice of using the usrtime.a library avaliable from the vxworks archives or forgoing adjtime() and using the clock_[get|set]time().The ntp_machine.h file clearly marks how to do this.

    -

    Compilation issues

    -

    You will need autoconf and automake ... available free from the gnu archives worldwide.

    -

    The variable arch is the target architecture (e.g. i486)

    -

    mkdir A.vxworks (or whatever....)
    - cd A.vxworks
    - ../configure --target=arch-wrs-vxworks [any other options]
    - make

    -

    Options I normally use are the --disable-all-clocks --enable-LOCAL-CLOCK flags. The program should proceed to compile without problem. The daemon ntpd, ntpdate, ntptrace, ntpdc, ntpq programs and of course the libraries are all fully ported. The other utilities are not, but they should be easy to port.

    -

    Running the software

    -

    Load in the various files, call them in the normal vxWorks function type manner. Here are some examples. Refer to the man pages for further information.

    -

    ld < ntpdate/ntpdate
    - ld < ntpd/ntpd
    - ld < ntptrace/ntptrace
    - ld < ntpq/ntpq
    - ld < ntpdc/ntpdc
    - ntpdate ("-b", "192.168.0.245")
    - sp(ntpd, "-c", "/export/home/casey/ntp/ntp.conf")
    - ntpdc("-c", "monlist", "192.168.0.244")
    - ntpq("-c", "peers", "192.168.0.244")
    - ntptrace("192.168.0.244")
    -

    -

    Bugs and such

    -

    Should you happen across any bugs, please let me know, or better yet fix them and submit a patch. Remember to make you patch general for Vxworks, not just for your particular architecture. CCII Systems (Pty) Ltd, my ex employers, sponsored the time to this port. Please let me know how it goes, I would be most interested in offsets and configurations.

    -


    -

    -

    Casey Crellin
    - casey@csc.co.za

    -


    -

    - - - \ No newline at end of file diff --git a/contrib/ntp/html/build/hints/winnt.html b/contrib/ntp/html/build/hints/winnt.html deleted file mode 100644 index 78de15d4e..000000000 --- a/contrib/ntp/html/build/hints/winnt.html +++ /dev/null @@ -1,281 +0,0 @@ - - - - - - - NTP on Windows NT - - - - -

    NTP 4.x for Windows NT

    - -

    Introduction

    - The NTP 4 distribution runs as service on Windows NT 4.0, Windows 2000, Windows XP, - Windows .NET Server 2003. It will NOT run on Windows 95, 98, ME, etc. - The binaries work on multi-processor systems. This port has not been tested - on the Alpha platform. This release now uses OpenSSL for authentication. - IPv6 is not implemented yet for Win32 platforms. -

    Authentication Keys

    - With this release ntp-keygen is supported. See the - ntp keygen documentation for details on how to use ntp-keygen. -

    - ntpd can now use the generated keys in the same way as on Unix platforms. Please - refer to the Authentication Options for details - on how to use these. -

    NOTE: ntpd and ntp-keygen both use OpenSSL which requires a random - character file called .rnd by default. Both of these programs will automatically - generate this file if they are not found. The programs will look for an - environmental variable called RANDFILE and use that for the name of the - random character file if the variable exists. If it does not exist it will look for an environmental - variable called HOME and use that directory to search for a filed called .rnd - in that directory. Finally, if neither RANDFILE nor HOME exists it will look - in C:\ for a .rnd file. In each case it will search for and create the file - if the environmental variable exists or in the C:\ directory if it doesn't. - Note that ntpd normally runs as a service so that the only way that it will - have either RANDFILE or HOME defined is if it is a System environmental - variable or if the service is run under a specific account name and that - account has one of those variables defined. Otherwise it will use the file - "c:\.rnd". This was done so that OpenSSL will work normally on Win32 systems. - This obviates the need to ship the OpenSSL.exe file and explain how to - generate the .rnd file. A future version may change this behavior. - -

    Refer to Compiling Requirements and Instructions for how to compile the program.

    -

    Reference Clocks

    - Reference clock support under Windows NT is tricky because the IO functions are - so much different. Some of the clock types have been built into the ntpd executable - and should work but have not been tested by the ntp project. If you have a clock - that runs on Win32 and the driver is there but not implemented on Win32 you will have - make the required configuration changes in config.h and then build ntpd from source - and test it. The following reference clocks are known to work and are supported - by Windows NT: -

    Type 1 Undisciplined Local Clock (LOCAL)
    - Type 29 Trimble Navigation Palisade GPS (GPS_PALISADE)

    -

    Functions Supported

    - All NTP functions are supported with some constraints. See the TODO list below. - Note that the ntptrace executable is not supported and you should use the PERL script - version instead. -

    Accuracy

    - Greg Brackley has implemented a fantastic interpolation scheme that improves the precision of the NTP clock - using a realtime thread (is that poetic or what!) which captures a tick count from the 8253 counter after each - OS tick. The count is used to interpolate the time between operating system ticks. -

    On a typical 200+ MHz system NTP achieves a precision of about 5 microseconds and synchronizes the clock - to +/-500 microseconds using the Trimble Palisade as UTC reference. - This allows distributed applications to use the 10 milliseconds ticks available to them with high confidence.

    -

    Binaries

    - Recent InstallShield based executable versions of NTP for Windows NT (intel) are available from: - -

    ToDo

    - These tasks are in no particular order of priority. -
      -
    • Create a proper install/uninstall program -
    • Add sntp to the list of supported programs -
    • Add support for Visual C++ 7.0 or later (.NET) -
    • Add IPv6 support -
    • See if precision can be improved by using CPU cycle counter for tick interpolation. -
    • Make precision time available to applications using NTP_GETTIME API -
    -

    Compiling Requirements

    -
      -
    • Windows NT 4.0 Windows 2000, Windows XP, or Windows.NET Server 2003 -
    • Microsoft Visual C++ 6.0. NOTE: VC++ 7.0 (aka .NET) is not yet supported - but will probably work fine. -
    • Some way of uncompressing and untarring the gzipped tar file. -
    • OpenSSL must be built on the box before building NTP. Additional steps would - be required to not use OpenSSL. -
    -

    Compiling Instructions

    -
      -
    1. Unpack and build OpenSSL according to the OpenSSL instructions for building on - Windows. An environment variable named OPENSSL must be set up to specify the base path - of the OpenSSL directory to be used to build the NTP package - (e.g. OPENSSL=C:\openssl-0.9.8b). -
    2. Unpack the ntp-*.tar.gz archive using utilities such as WinZip. -
    3. Open the .\ports\winnt\ntp.dsw Visual C workspace -
    4. Batch build all projects -
    5. The built binaries can be found in the port\winnt\bin\Release subdirectory -
    6. In addition you will need to install the OpenSSL libeay32.dll -
    7. If you are shipping binaries in a kit it is strongly recommended that you - ship this file (winnt.html) along with the binaries. -
    -

    Configuration File

    - The default NTP configuration file path is %SystemRoot%\system32\drivers\etc\. (%SystemRoot% - is an environmental variable that can be determined by typing "set" at the "Command Prompt" - or from the "System" icon in the "Control Panel").
    - Refer to your system environment and create your ntp.conf file in the directory - corresponding to your system  installation.
    - The older <WINDIR>\ntp.conf is still supported but you will get a log entry reporting that - the first file wasn't found. -

    Installation Instructions

    - The instsrv program in the instsrv subdirectory of the distribution can be used to install 'ntpd' as - a service and start automatically at boot time. Instsrv is automatically compiled with the rest of the distribution - if you followed the steps above. -
      -
    1. Start a command prompt and enter "instsrv.exe <pathname_for_ntpd.exe>" -
    2. Clicking on the "Services" icon in the "Control Panel" will display the list of - currently installed services in a dialog box. The NetworkTimeProtocol service should show up in this list. - Select it in the list and hit the "Start" button in the dialog box. The NTP service should start. -
    3. You can also stop and start the service by typing net start|stop NetworkTimeProtocol at the DOS prompt. -
    4. View the event log by clicking on the "Event Viewer" icon in the "Administrative Tools" - group, there should be several successful startup messages from NTP. NTP will keep running and restart - automatically when the machine is rebooted. -
    - You can change the start mode (automatic/manual) and other startup parameters corresponding to the NTP service - in the "Services" dialog box if you wish. -

    Removing NTP

    - You can also use instsrv to delete the NTP service by entering: "instsrv.exe remove" -

    Command Line Parameters and Registry Entries

    - Unlike the Unix environment, there is no clean way to run 'ntpdate' and reset the clock before starting 'ntpd' at boot time.
    - NTP will step the clock up to 1000 seconds by default. While there is no reason that the system clock should be that much off - during bootup if 'ntpd' was running before, you may wish to override this default and/or pass other command line directives. -

    Use the registry editor to edit the value for the ntpd executable under LocalMachine\System\CurrentControlSet\Services\NTP.

    -

    Add the -g option to the ImagePath key, behind "%INSTALLDIR>\ntpd.exe". This will force NTP to accept - large time errors (including 1.1.1980 00:00)

    -

    Bug Reports

    - Send questions to news://comp.protocols.time.ntp - and bug reports should be entered in Bugzilla on the - NTP Web site. -

    Change Log

    -

    Last revision 2 July 2003  Version 4.2.0

    - by Danny Mayer (mayer@ntp.org>) -

    Significant Changes:

    - This latest release of NTP constitutes a major upgrade to its ability to build and - run on Windows platforms and should now build and run cleanly. More importantly it - is now able to support all authentication in the same way as Unix boxes. This does - require the usage of OpenSSL which is now a prerequisite for build on Windows. - ntp-keygen is now supported and builds on Win32 platforms. - -

    Last revision 16 February 1999  Version 4.0.99e.

    - by Sven Dietrich (sven_dietrich@trimble.com) -

    Significant Changes:

    -
      -
    • Perl 5 is no longer needed to compile NTP. The configuration script which creates version.c - with the current date and time was modified by Frederick Czajka [w2k@austin.rr.com] so that Perl - is no longer required. -
    -

    Last revision 15 November 1999  Version 4.0.98f.

    - by Sven Dietrich (sven_dietrich@trimble.com) -

    Significant Changes:

    -
      -
    • Fixed I/O problem delaying packet responses which resulted in no-replys to NTPQ and others. -
    • The default configuration file path is <WINDIR>\system32\drivers\etc\ntp.conf. - The old <WINDIR>\ntp.conf is still supported but you will get a log entry reporting - that the first file wasn't found. The NTP 3.x legacy ntp.ini file is no longer supported. -
    - Known Problems / TODO: -
      -
    • MD5 and name resolution do not yet get along. If you define MD5, you cannot use DNS names, only IP numbers. -
    -

    Last revision 27 July 1999  Version 4.0.95.

    - This version compiles under WINNT with Visual C 6.0. -

    Greg Brackley and Sven Dietrich

    -

    Significant changes:
    - -Visual Studio v6.0 support
    - -Winsock 2.0 support
    - -Use of I/O completion ports for sockets and comm port I/O
    - -Removed the use of multimedia timers (from ntpd, others need removing)
    - -Use of waitable timers (with user mode APC) and performance counters to fake getting a better time
    - -Trimble Palisade NTP Reference Clock support
    - -General cleanup, prototyping of functions
    - -Moved receiver buffer code to a separate module (removed unused members from the recvbuff struct)
    - -Moved io signal code to a separate module

    -

    Last revision:  20-Oct-1996

    - This version corrects problems with building the XNTP
    - version 3.5-86 distribution under Windows NT. -

    The following files were modified:
    -  blddbg.bat
    -  bldrel.bat
    -  include\ntp_machine.h
    -  xntpd\ntp_unixclock.c
    -  xntpd\ntp_refclock.c
    -  scripts\wininstall\build.bat
    -  scripts\wininstall\setup.rul
    -  scripts\wininstall\readme.nt
    -  scripts\wininstall\distrib\ntpog.wri
    -  html\hints\winnt (this file)

    -

    In order to build the entire Windows NT distribution you
    - need to modify the file scripts\wininstall\build.bat
    - with the installation directory of the InstallShield
    - software.  Then, simply type "bldrel" for non-debug
    - or "blddbg" for debug executables.

    -

    Greg Schueman
    -     <schueman@acm.org>

    -

    Last revision:  07-May-1996

    - This set of changes fixes all known bugs, and it includes
    - several major enhancements. -

    Many changes have been made both to the build environment as
    - well as the code.  There is no longer an ntp.mak file, instead
    - there is a buildntall.bat file that will build the entire
    - release in one shot.  The batch file requires Perl.  Perl
    - is easily available from the NT Resource Kit or on the Net.

    -

    The multiple interface support was adapted from Larry Kahn's
    - work on the BIND NT port.  I have not been able to test it
    - adequately as I only have NT servers with one network
    - interfaces on which to test.

    -

    Enhancements:
    - * Event Logging now works correctly.
    - * Version numbers now work (requires Perl during build)
    - * Support for multiple network interface cards (untested)
    - * NTP.CONF now default, but supports ntp.ini if not found
    - * Installation procedure automated.
    - * All paths now allow environment variables such as %windir%

    -

    Bug fixes:
    - * INSTSRV replaced, works correctly
    - * Cleaned up many warnings
    - * Corrected use of an uninitialized variable in XNTPD
    - * Fixed ntpdate -b option
    - * Fixed ntpdate to accept names as well as IP addresses
    -         (Winsock WSAStartup was called after a gethostbyname())
    - * Fixed problem with "longjmp" in xntpdc/ntpdc.c that
    -         caused a software exception on doing a Control-C in xntpdc.
    -  A Cntrl-C now terminates the program.

    -

    See below for more detail:

    -

          Note: SIGINT is not supported for any Win32 application including
    -       Windows NT and Windows 95. When a CTRL+C interrupt occurs, Win32
    -       operating systems generate a new thread to specifically handle that
    -       interrupt. This can cause a single-thread application such as UNIX,
    -       to become multithreaded, resulting in unexpected behavior.
    -  

    -

    Possible enhancements and things left to do:
    - * Reference clock drivers for NT (at least Local Clock support)
    - * Control Panel Applet
    - * InstallShield based installation, like NT BIND has
    - * Integration with NT Performance Monitor
    - * SNMP integration
    - * Fully test multiple interface support
    -  

    -

    Known problems:
    - *       bug in ntptrace - if no Stratum 1 servers are available,
    -                 such as on an - IntraNet, the application crashes.

    -

    Last revision:  12-Apr-1995

    - This NTPv3 distribution includes a sample configuration file and the project
    - makefiles for WindowsNT 3.5 platform using Microsoft Visual C++ 2.0 compiler.
    - Also included is a small routine to install the NTP daemon as a "service"
    - on a WindowsNT box. Besides xntpd, the utilities that have been ported are
    - ntpdate and xntpdc. The port to WindowsNT 3.5 has been tested using a Bancomm
    - TimeServe2000 GPS receiver clock that acts as a strata 1 NTP server with no
    - authentication (it has not been tested with any refclock drivers compiled in).
    - Following are the known flaws in this port:
    - 1) currently, I do not know of a way in NT to get information about multiple
    -    network interface cards. The current port uses just one socket bound to
    -    INADDR_ANY address. Therefore when dealing with a multihomed NT time server,
    -    clients should point to the default address on the server (otherwise the
    -    reply is not guaranteed to come from the same interface to which the
    -    request was sent). Working with Microsoft to get this resolved.
    - 2) There is some problem with "longjmp" in xntpdc/ntpdc.c that causes a
    -    software exception on doing a Control-C in xntpdc. Be patient!
    - 3) The error messages logged by xntpd currently contain only the numerical
    -    error code. Corresponding error message string has to be looked up in
    -    "Books Online" on Visual C++ 2.0 under the topic "Numerical List of Error
    -    Codes". -

    Last HTML Update: November 17, 1999
    - Sven_Dietrich@Trimble.COM

    - - - diff --git a/contrib/ntp/html/build/patches.html b/contrib/ntp/html/build/patches.html deleted file mode 100644 index 00b292335..000000000 --- a/contrib/ntp/html/build/patches.html +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - Patching Procedures - - - - -

    Patching Procedures

    - gif rom Alice's Adventures in Wonderland, Lewis Carroll -

    The Mad Hatter needs patches.

    -

    Last update: 12:56 AM UTC Saturday, March 20, 2004

    -
    -
    -

    A distribution so widely used as this one eventually develops numerous barnacles as the result of porting to new systems, idiosyncratic new features and just plain bugs. In order to help keep order and make maintenance bearable, we ask that proposed changes to the distribution be submitted in the following form.

    -
      -
    1. Please submit patches to bugs@mail.ntp.org in the form of either unified-diffs (diff -u) or context-diffs (diff -c). -
    2. Please include the output from config.guess in the description of your patch. If config.guess does not produce any output for your machine, please fix that, too! -
    3. Please base the patch on the root directory of the distribution. The preferred procedure here is to copy your patch to the root directory and mumble -

      patch -p <your_patch>

      -
    4. Please avoid patching the RCS subdirectories; better yet, clean them out before submitting patches. -
    5. If you have whole new files, as well as patches, wrap the files and patches in a shell script. If you need to compress it, use either GNU gzip or the stock Unix compress utility. -
    6. Don't forget the documentation that may be affected by the patch. Send us patches for the ./htm files as well. -
    7. We would be glad to include your name, electric address and descriptive phrase in the Copyright page, if you wish. -
    -

    Prior to ntp3-5.83 (releases up to and including ntp3.5f) a complete patch history back to the dark ages was kept in the ./patches directory, which might have been helpful to see if the same problem occurred in another port, etc. Patches were saved in that directory with file name in the form patch.nnn, where nnn was approaching 200. All patches in that directory have been made; so, if yours was there, it was in the distribution.

    -

    Since we have been getting multple patches for some bugs, plus many changes are implemented locally, no two maintainers here use the same tools, and since we're not using any bug-tracking software or even source code control, there is currently no tracking of specific changes.

    -

    The best way to see what's changed between two distributions is to run a diff against them.

    -

    Thanks for your contribution and happy chime.

    -
    - - - - diff --git a/contrib/ntp/html/build/porting.html b/contrib/ntp/html/build/porting.html deleted file mode 100644 index 976cc6670..000000000 --- a/contrib/ntp/html/build/porting.html +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - Porting Hints - - - - -

    Porting Hints

    - giffrom The Wizard of Oz, L. Frank Baum -

    Porting Dorothy in Oz -

    -

    Last update: 12:56 AM UTC Saturday, March 20, 2004

    -
    -
    -

    NOTE: The following procedures have been replaced by GNU automake and autoconfigure. This page is to be updated in the next release.

    -

    Porting to a new machine or operating system ordinarily requires updating the ./machines directory and the ./compilers directories in order to define the build environment and autoconfigure means. You will probably have to modify the ntp_machines.h file and "l_stdlib.h" files as well. The two most famous trouble spots are the I/O code in ./ntpd/ntp_io.c and the clock adjustment code in ./ntpd/ntp_unixclock.c.

    -

    These are the rules so that older bsd systems and the POSIX standard system can coexist together.

    -
      -
    1. If you use select then include "ntp_select.h". select is not standard, since it is very system dependent as to where it is defined. The logic to include the right system dependent include file is in "ntp_select.h". -
    2. Always use POSIX definition of strings. Include "ntp_string.h" instead of <string.h>. -
    3. Always include "ntp_malloc.h" if you use malloc. -
    4. Always include "ntp_io.h" instead of <sys/file.h> or <fnctl.h> to get O_* flags. -
    5. Always include "ntp_if.h" instead of <net/if.h>. -
    6. Always include "ntp_stdlib.h" instead of <stdlib.h>. -
    7. Define any special defines needed for a system in ./include/ntp_machine.h based on system identifier. This file is included by the "ntp_types.h" file and should always be placed first after the <> defines. -
    8. Define any special library prototypes left over from the system library and include files in the "l_stdlib.h" file. This file is included by the "ntp_stdlib.h" file and should ordinarily be placed last in the includes list. -
    9. Don't define a include file by the same name as a system include file. -
    -

    "l_stdlib.h" can contain any extra definitions that are needed so that gcc will shut up. They should be controlled by a system identifier and there should be a separate section for each system. Really this will make it easier to maintain.

    -

    See include/ntp_machines.h for the various compile time options.

    -

    When you are satisfied the port works and that other ports are not adversely affected, please send patches for the system files you have changed, as well as any documentation that should be updated, including the advice herein.

    -

    Good luck.

    -
    - - - - \ No newline at end of file diff --git a/contrib/ntp/html/build/quick.html b/contrib/ntp/html/build/quick.html deleted file mode 100644 index 1693b5d7a..000000000 --- a/contrib/ntp/html/build/quick.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - Quick Start - - - - -

    Quick Start

    - gifFAX test image for SATNET (1979). -

    The baby panda was scanned at University College London and used as a FAX test image for a demonstration of the DARPA Atlantic SATNET Program and the first transatlantic Internet connection in 1978. The computing system used for that demonstration was called the Fuzzball . As it happened, this was also the first Internet multimedia presentation and the first to use NTP in regular operation. The image was widely copied and used for testing purpose throughout much of the 1980s.

    -

    Last update: 01:01 AM UTC Saturday, March 20, 2004

    -
    -
    -

    For the rank amateur the sheer volume of the documentation collection must be intimidating. However, it doesn't take much to fly the ntpd daemon with a simple configuration where a workstation needs to synchronize to some server elsewhere in the Internet. The first thing that needs to be done is to build the distribution for the particular workstation and install in the usual place. The Building and Installing the Distribution page describes how to do this.

    -

    While it is possible that certain configurations do not need a configuration file, most do require one. The file, called by default /etc/ntp.conf, need only contain one line specifying a remote server, for instance

    -

    server foo.bar.com

    -

    Choosing an appropriate remote server is somewhat of a black art, but a suboptimal choice is seldom a problem. There are about two dozen public time servers operated by National Institutes of Science and Technology (NIST), US Naval Observatory (USNO), Canadian Metrology Centre (CMC) and many others available on the Internet. Lists of public primary and secondary NTP servers maintained on the Public NTP TIme Servers page, which is updated frequently.The lists are sorted by country and, in the case of the US, by state. Usually, the best choice is the nearest in geographical terms, but the terms of engagement specified in each list entry should be carefully respected.

    -

    During operation ntpd measures and corrects for incidental clock frequency error and writes the current value to a file called by default /etc/ntp.drift. If ntpd is stopped and restarted, it initializes the frequency from this file. In this way the potentially lengthy interval to relearn the frequency error is avoided.

    -

    That's all there is to it, unless some problem in network connectivity or local operating system configuration occurs. The most common problem is some firewall between the workstation and server. System administrators should understand NTP uses UDP port 123 as both the source and destination port and that NTP does not involve any operating system interaction other than to set the system clock. While almost all modern Unix systems have included NTP and UDP port 123 defined in the services file, this should be checked if ntpd fails to come up at all.

    -

    The best way to confirm NTP is working is using the ntpq utility, although the ntpdc utility may be useful in extreme cases. See the documentation pages for further information. In the most extreme cases the -d option on the ntpd command line results in a blow-by-blow trace of the daemon operations. While the trace output can be cryptic, to say the least, it gives a general idea of what the program is doing and, in particular, details the arriving and departing packets and detected errors, if present.

    -

    Sometimes the ntpd. behavior may seem to violate the Principle of Least Astonishment, but there are good reasons for this. See the Network Time Protocol (NTP) daemon page for revealing insights. See this page and its dependencies for additional configuration and control options. The Notes on Configuring NTP and Setting up a NTP Subnet page contains an extended discussion of these options.

    -
    - - - - \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/footer.txt b/contrib/ntp/html/build/scripts/footer.txt deleted file mode 100644 index 89216ce97..000000000 --- a/contrib/ntp/html/build/scripts/footer.txt +++ /dev/null @@ -1,7 +0,0 @@ -document.write("\ -\ -\ -\ -
    gif\ -Home Pagegif\ -Contacts
    ") \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/links10.txt b/contrib/ntp/html/build/scripts/links10.txt deleted file mode 100644 index 7bf9d06e7..000000000 --- a/contrib/ntp/html/build/scripts/links10.txt +++ /dev/null @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/links11.txt b/contrib/ntp/html/build/scripts/links11.txt deleted file mode 100644 index 1fce362a6..000000000 --- a/contrib/ntp/html/build/scripts/links11.txt +++ /dev/null @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/links12.txt b/contrib/ntp/html/build/scripts/links12.txt deleted file mode 100644 index 512cbcf4a..000000000 --- a/contrib/ntp/html/build/scripts/links12.txt +++ /dev/null @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/links7.txt b/contrib/ntp/html/build/scripts/links7.txt deleted file mode 100644 index 4a6f186a2..000000000 --- a/contrib/ntp/html/build/scripts/links7.txt +++ /dev/null @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/links8.txt b/contrib/ntp/html/build/scripts/links8.txt deleted file mode 100644 index af33dca1c..000000000 --- a/contrib/ntp/html/build/scripts/links8.txt +++ /dev/null @@ -1,6 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/links9.txt b/contrib/ntp/html/build/scripts/links9.txt deleted file mode 100644 index 38ffe90a7..000000000 --- a/contrib/ntp/html/build/scripts/links9.txt +++ /dev/null @@ -1,7 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/build/scripts/style.css b/contrib/ntp/html/build/scripts/style.css deleted file mode 100644 index 096b18a6a..000000000 --- a/contrib/ntp/html/build/scripts/style.css +++ /dev/null @@ -1,64 +0,0 @@ -body {background: #FDF1E1; - color: #006600; - font-family: "verdana", sans-serif; - text-align: justify; - margin-left: 5px;} - -p, h4, hr, li {margin-top: .6em; margin-bottom: .6em} -li.inline {text-align: left; margin-top: 0; margin-bottom: 0} - -ul, dl, ol, {margin-top: .6em; margin-bottom: .6em; margin-left 5em} - -dt {margin-top: .6em} -dd {margin-bottom: .6em} - -div.header {text-align: center; - font-style: italic;} - -div.footer {text-align: center; - font-size: 60%;} - -img.cell {align: left;} - -td.sidebar {width: 40px; align: center; valign: top;} -img.sidebar {align: center; margin-top: 5px;} -h4.sidebar {align: center;} - -p.top {background: #FDF1E1; - color: #006600; - position: absolute; - margin-left: -90px; - text-align: center;} - -a:link.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:visited.sidebar {background: transparent; - color: #990033; - font-weight: bold;} - -a:hover.sidebar {background: #FDF1E1; - color: #006600;} - -img {margin: 5px;} - -div {text-align: center;} - -h1 {text-align: center; - font-size: 250%;} - -caption {background: #EEEEEE; - color: #339999;} - -tx {text-align: center;} - -th {background: #FFFFCC; - color: #006600; - text-align: center; - text-decoration: underline; - padding-top: 5px;} - -th.caption {background: #EEEEEE; - color: #006600; - text-align: center;} \ No newline at end of file diff --git a/contrib/ntp/html/clock.html b/contrib/ntp/html/clock.html new file mode 100644 index 000000000..32f3ed8c3 --- /dev/null +++ b/contrib/ntp/html/clock.html @@ -0,0 +1,65 @@ + + + + + +Clock State Machine + + + +

    Clock State Machine

    +

    Last update: + 4-Aug-2011 23:40 + UTC

    +

    Table of Contents

    + +
    +

    General Overview

    +

    In the NTPv4 specification and reference implementation a state machine is used to manage the system clock under exceptional conditions, as when the daemon is first started or when encountering severe network congestion. This page describes the design and operation of the state machine in detail.

    +

    The state machine is activated upon receipt of an update by the clock discipline algorithm. its primary purpose is to determines whether the clock is slewed or stepped and how the initial time and frequency are determined using three thresholds: panic, step and stepout, and one timer: hold.

    +

    Panic Threshold

    +

    Most computers today incorporate a time-of-year (TOY) chip to maintain the time when the power is off. When the computer is restarted, the chip is used to initialize the operating system time. In case there is no TOY chip or the TOY time is different from NTP time by more than the panic threshold, the daemon assumes something must be terribly wrong, so exits with a message to the system operator to set the time manually. With the -g option on the command line, the daemon sets the clock to NTP time at the first update, but exits if the offset exceeds the panic threshold at subsequent updates. The panic threshold default is 1000 s, but it can be changed with the panic option of the tinker command.

    +

    Step and Stepout Thresholds

    +

    Under ordinary conditions, the clock discipline gradually slews the clock to the correct time, so that the time is effectively continuous and never stepped forward or backward. If, due to extreme network congestion, an offset spike exceeds the step threshold, by default 128 ms, the spike is discarded. However, if offset spikes greater than the step threshold persist for an interval more than the stepout threshold, by default 300 s, the system clock is stepped to the correct time.

    +

    In practice, the need for a step has been extremely rare and almost always the result of a hardware failure or operator error. The step threshold and stepout threshold can be changed using the step and stepout options of the tinker command, respectively. If the step threshold is set to zero, the step function is entirely disabled and the clock is always slewed. The daemon sets the step threshold to 600 s using the -x option on the command line. If the -g option is used or the step threshold is set greater than 0.5 s, the precision time kernel support is disabled.

    +

    Historically, the most important application of the step function was when a leap second was inserted in the Coordinated Universal Time (UTC) timescale and the kernel precision time support was not available. This also happened with older reference clocks that indicated an impending leap second, but the radio itself did not respond until it resynchronized some minutes later. Further details are on the Leap Second Processing page.

    +

    In some applications the clock can never be set backward, even it accidentally set forward a week by some evil means. The issues should be carefully considered before using these options. The slew rate is fixed at 500 parts-per-million (PPM) by the Unix kernel. As a result, the clock can take 33 minutes to amortize each second the clock is outside the acceptable range. During this interval the clock will not be consistent with any other network clock and the system cannot be used for distributed applications that require correctly synchronized network time.

    +

    Hold Timer

    +

    When the daemon is started after a considerable downtime, it could be the TOY chip clock has drifted significantly from NTP time. This can cause a transient at system startup. In the past, this has produced a phase transient and resulted in a frequency surge that could take some time, even hours, to subside. When the highest accuracy is required, some means is necessary to manage the startup process so that the the clock is quickly set correctly and the frequency is undisturbed. The hold timer is used to suppress frequency adjustments during the training and startup intervals described below. At the beginning of the interval the hold timer is set to the stepout threshold and decrements at one second intervals until reaching zero. However, the hold timer is forced to zero if the residual clock offset is less than 0.5 ms. When nonzero, the discipline algorithm uses a small time constant (equivalent to a poll exponent of 2), but does not adjust the frequency. Assuming that the frequency has been set to within 1 PPM, either from the frequency file or by the training interval described later, the clock is set to within 0.5 ms in less than 300 s.

    +

    Operating Intervals

    +

    The state machine operates in one of four nonoverlapping intervals.

    +
    +
    Training interval
    +
    This interval is used at startup when the frequency file is nor present at startup. It begins when the first update is received by the discipline algorithm and ends when an update is received following the stepout threshold. The clock phase is steered to the offset presented at the beginning of the interval, but without affecting the frequency. During the interval further updates are ignored. At the end of the interval the frequency is calculated as the phase change during the interval divided by the length of the interval. This generally results in a frequency error less than 0.5 PPM. Note that, if the intrinsic oscillator frequency error is large, the offset will in general have significant error. This is corrected during the subsequent startup interval.
    +
    Startup interval
    +
    This interval is used at startup to amortize the residual offset while not affecting the frequency. If the frequency file is present, it begins when the first update is received by the discipline. If not, it begins after the training interval. It ends when the hold timer decrements to zero or when the residual offset falls below 0.5 ms.
    +
    Step interval
    +
    This interval is used as a spike blanker during periods when the offsets exceed the step threshold. The interval continues as long as offsets are received that are greater than the step threshold, but ends when either an offset is received less than the step threshold or until the time since the last valid update exceeds the stepout threshold.
    +
    Sync Interval
    +
    This interval is implicit; that is, it is used when none of the above intervals are used.
    +
    +

    State Transition Function

    +

    The state machine consists of five states. An event is created when an update is received by the discipline algorithm. Depending on the state and the the offset magnitude, the machine performs some actions and transitions to the same or another state. Following is a short description of the states.

    +
    +
    FSET - The frequency file is present
    +
    Load the frequency file, initialize the hold timer and continue in SYNC state.
    +
    NSET - The frequency file is not present
    +
    Initialize the hold timer and continue in FREQ state.
    +
    FREQ - Frequency training state
    +
    Disable the clock discipline until the time since the last update exceeds the stepout threshold. When this happens, calculate the frequency, initialize the hold counter and transition to SYNC state.
    +
    SPIK - Spike state
    +
    A update greater than the step threshold has occurred. Ignore the update and continue in this state as long as updates greater than the step threshold occur. If a valid update is received, continue in SYNC state. When the time since the last valid update was received exceeds the stepout threshold, step the system clock and continue in SYNC state.
    +
    SYNC - Ordinary clock discipline state
    +
    Discipline the system clock time and frequency using the hybrid phase/frequency feedback loop. However, do not discipline the frequency if the hold timer is nonzero.
    +
    +
    + + + diff --git a/contrib/ntp/html/clockopt.html b/contrib/ntp/html/clockopt.html index c4690a368..0fe4c2467 100644 --- a/contrib/ntp/html/clockopt.html +++ b/contrib/ntp/html/clockopt.html @@ -1,68 +1,59 @@ - - - - - - Reference Clock Options - - - - -

    Reference Clock Options

    - gif -

    See the radios, all in a row.

    -

    Last update: 18:37 UTC Thursday, July 28, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Reference Clock Support

    -

    The NTP Version 4 daemon supports some three dozen different radio, satellite and modem reference clocks plus a special pseudo-clock used for backup or when no other clock source is available. Detailed descriptions of individual device drivers and options can be found in the Reference Clock Drivers page. Additional information can be found in the pages linked there, including the Debugging Hints for Reference Clock Drivers and How To Write a Reference Clock Driver pages. In addition, support for a PPS signal is available as described in Pulse-per-second (PPS) Signal Interfacing page. Many drivers support special line discipline/streams modules which can significantly improve the accuracy using the driver. These are described in the Line Disciplines and Streams Drivers page.

    -

    A reference clock will generally (though not always) be a radio timecode receiver which is synchronized to a source of standard time such as the services offered by the NRC in Canada and NIST and USNO in the US. The interface between the computer and the timecode receiver is device dependent, but is usually a serial port. A device driver specific to each reference clock must be selected and compiled in the distribution; however, most common radio, satellite and modem clocks are included by default. Note that an attempt to configure a reference clock when the driver has not been compiled or the hardware port has not been appropriately configured results in a scalding remark to the system log file, but is otherwise non hazardous.

    -

    For the purposes of configuration, ntpd treats reference clocks in a manner analogous to normal NTP peers as much as possible. Reference clocks are identified by a syntactically correct but invalid IP address, in order to distinguish them from normal NTP peers. Reference clock addresses are of the form 127.127.t.u, where t is an integer denoting the clock type and u indicates the unit number in the range 0-3. While it may seem overkill, it is in fact sometimes useful to configure multiple reference clocks of the same type, in which case the unit numbers must be unique.

    -

    The server command is used to configure a reference clock, where the address argument in that command is the clock address. The key, version and ttl options are not used for reference clock support. The mode option is added for reference clock support, as described below. The prefer option can be useful to persuade the server to cherish a reference clock with somewhat more enthusiasm than other reference clocks or peers. Further information on this option can be found in the Mitigation Rules and the prefer Keyword page. The minpoll and maxpoll options have meaning only for selected clock drivers. See the individual clock driver document pages for additional information.

    -

    The fudge command is used to provide additional information for individual clock drivers and normally follows immediately after the server command. The address argument specifies the clock address. The refid and stratum options control can be used to override the defaults for the device. There are two optional device-dependent time offsets and four flags that can be included in the fudge command as well.

    -

    The stratum number of a reference clock is by default zero. Since the ntpd daemon adds one to the stratum of each peer, a primary server ordinarily displays an external stratum of one. In order to provide engineered backups, it is often useful to specify the reference clock stratum as greater than zero. The stratum option is used for this purpose. Also, in cases involving both a reference clock and a pulse-per-second (PPS) discipline signal, it is useful to specify the reference clock identifier as other than the default, depending on the driver. The refid option is used for this purpose. Except where noted, these options apply to all clock drivers.

    -

    Reference Clock Commands

    -
    -
    server 127.127.t.u [prefer] [mode int] [minpoll int] [maxpoll int] -
    This command can be used to configure reference clocks in special ways. The options are interpreted as follows: -
    -
    prefer -
    Marks the reference clock as preferred. All other things being equal, this host will be chosen for synchronization among a set of correctly operating hosts. See the Mitigation Rules and the prefer Keyword page for further information. -
    mode int -
    Specifies a mode number which is interpreted in a device-specific fashion. For instance, it selects a dialing protocol in the ACTS driver and a device subtype in the parse drivers. -
    minpoll int -
    maxpoll int -
    These options specify the minimum and maximum polling interval for reference clock messages in seconds, interpreted as dual logarithms (2 ^ x). For most directly connected reference clocks, both minpoll and maxpoll default to 6 (2^16 = 64 s). For modem reference clocks, minpoll defaults to 10 (2^10 = 1024 s = 17.1 m) and maxpoll defaults to 14 (2^14 = 16384 s = 4.5 h). The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. -
    -
    fudge 127.127.t.u [time1 sec] [time2 sec] [stratum int] [refid string] [mode int] [flag1 0|1] [flag2 0|1] [flag3 0|1] [flag4 0|1] -
    This command can be used to configure reference clocks in special ways. It must immediately follow the server command which configures the driver. Note that the same capability is possible at run time using the ntpdc program. The options are interpreted as follows: -
    -
    time1 sec -
    Specifies a constant to be added to the time offset produced by the driver, a fixed-point decimal number in seconds. This is used as a calibration constant to adjust the nominal time offset of a particular clock to agree with an external standard, such as a precision PPS signal. It also provides a way to correct a systematic error or bias due to serial port or operating system latencies, different cable lengths or receiver internal delay. The specified offset is in addition to the propagation delay provided by other means, such as internal DIPswitches. Where a calibration for an individual system and driver is available, an approximate correction is noted in the driver documentation pages. -
    Note: in order to facilitate calibration when more than one radio clock or PPS signal is supported, a special calibration feature is available. It takes the form of an argument to the enable command described in the Miscellaneous Options page and operates as described in the Reference Clock Drivers page. -
    time2 secs -
    Specifies a fixed-point decimal number in seconds, which is interpreted in a driver-dependent way. See the descriptions of specific drivers in the reference clock drivers page. -
    stratum int -
    Specifies the stratum number assigned to the driver, an integer between 0 and 15. This number overrides the default stratum number ordinarily assigned by the driver itself, usually zero. -
    refid string -
    Specifies an ASCII string of from one to four characters which defines the reference identifier used by the driver. This string overrides the default identifier ordinarily assigned by the driver itself. -
    mode int -
    Specifies a mode number which is interpreted in a device-specific fashion. For instance, it selects a dialing protocol in the ACTS driver and a device subtype in the parse drivers. -
    flag1 flag2 flag3 flag4 -
    These four flags are used for customizing the clock driver. The interpretation of these values, and whether they are used at all, is a function of the particular clock driver. However, by convention flag4 is used to enable recording monitoring data to the clockstats file configured with the filegen command. Further information on the filegen command can be found in the Monitoring Options page. -
    -
    -
    - - - + + + +Reference Clock Commands and Options + + + +

    Reference Clock Commands and Options

    +gifMaster Time Facility at the UDel Internet Research Laboratory +

    Last update: + 11-Sep-2010 05:55 + UTC

    +
    +

    Related Links

    + + + +
    +

    Reference Clock Adddresses

    +

    Unless noted otherwise, further information about these ccommands is on the Reference Clock Support page.

    Reference clocks are identified by a syntactically correct but invalid IP address, in order to distinguish them from ordinary NTP peers. These addresses are of the form 127.127.t.u, where t is an integer denoting the clock type and u indicates the unit number in the range 0-3. While it may seem overkill, it is in fact sometimes useful to configure multiple reference clocks of the same type, in which case the unit numbers must be unique.

    +

    Commands and Options

    +
    +
    server 127.127.t.u [prefer] [mode int] [minpoll int] [maxpoll int]
    +
    This command can be used to configure reference clocks in special ways. The options are interpreted as follows: +
    +
    prefer
    +
    Marks the reference clock as preferred. All other things being equal, this host will be chosen for synchronization among a set of correctly operating hosts. See the Mitigation Rules and the prefer Keyword page for further information.
    +
    mode int
    +
    Specifies a mode number which is interpreted in a device-specific fashion. For instance, it selects a dialing protocol in the ACTS driver and a device subtype in the parse drivers.
    +
    minpoll int
    + maxpoll int
    +
    These options specify the minimum and maximum polling interval for reference clock messages in log2 seconds. For most directly connected reference clocks, both minpoll and maxpoll default to 6 (64 s). For modem reference clocks, minpoll is ordinarily set to 10 (about 17 m) and maxpoll to 15 (about 9 h). The allowable range is 4 (16 s) to 17 (36 h) inclusive.
    +
    +
    +
    fudge 127.127.t.u [time1 sec] [time2 sec] + [stratum int] [refid string] [flag1 0|1] + [flag2 0|1] [flag3 0|1] [flag4 0|1]
    +
    This command can be used to configure reference clocks in special ways. It must immediately follow the server command which configures the driver. Note that the same capability is possible at run time using the ntpdc program. The options are interpreted as follows: +
    +
    time1 sec
    +
    Specifies a constant to be added to the time offset produced by the driver, a fixed-point decimal number in seconds. This is used as a calibration constant to adjust the nominal time offset of a particular clock to agree with an external standard, such as a precision PPS signal. It also provides a way to correct a systematic error or bias due to serial port or operating system latencies, different cable lengths or receiver internal delay. The specified offset is in addition to the propagation delay provided by other means, such as internal DIPswitches. Where a calibration for an individual system and driver is available, an approximate correction is noted in the driver documentation pages.
    +
    Note: in order to facilitate calibration when more than one radio clock or PPS signal is supported, a special calibration feature is available. It takes the form of an argument to the enable command described in the Miscellaneous Options page and operates as described in the Reference Clock Support page.
    +
    time2 secs
    +
    Specifies a fixed-point decimal number in seconds, which is interpreted in a driver-dependent way. See the descriptions of specific drivers in the Reference Clock Support page.
    +
    stratum int
    +
    Specifies the stratum number assigned to the driver in the range 0 to 15, inclusive. This number overrides the default stratum number ordinarily assigned by the driver itself, usually zero.
    +
    refid string
    +
    Specifies an ASCII string of from one to four characters which defines the reference identifier used by the driver. This string overrides the default identifier ordinarily assigned by the driver itself.
    +
    flag1 flag2 flag3 flag4
    +
    These four flags are used for customizing the clock driver. The interpretation of these values, and whether they are used at all, is a function of the particular driver. However, by convention flag4 is used to enable recording monitoring data to the clockstats file configured with the filegen command. Additional information on the filegen command is on the Monitoring Options page.
    +
    +
    +
    +
    + + diff --git a/contrib/ntp/html/cluster.html b/contrib/ntp/html/cluster.html new file mode 100644 index 000000000..3132a46a5 --- /dev/null +++ b/contrib/ntp/html/cluster.html @@ -0,0 +1,32 @@ + + + + + +Clock Cluster Algorithm + + + + +

    Clock Cluster Algorithm

    +

    Last update: + 15-Nov-2012 06:02 + UTC

    +
    +

    The clock cluster algorithm processes the truechimers produced by the clock select algorithm to produce a list of survivors. These survivors are used by the mitigation algorithms to discipline the system clock. The cluster algorithm operates in a series of rounds, where at each round the truechimer furthest from the offset centroid is pruned from the population. The rounds are continued until a specified termination condition is met. This page discusses the algorithm in detail.

    +

    First, the truechimer associations are saved on an unordered list with each candidate entry identified with index i (i = 1, ..., n), where n is the number of candidates. Let θ(i), be the offset and λ(i) be the root distance of the ith entry. Recall that the root distance is equal to the root dispersion plus half the root delay. For the ith candidate on the list, a statistic called the select jitter relative to the ith candidate is calculated as follows. Let

    +
    +

    di(j) = |θ(j) − θ(i)| λ(i),

    +
    +

    where θ(i) is the peer offset of the ith entry and θ(j) is the peer offset of the jth entry, both produced by the clock filter algorithm. The metric used by the cluster algorithm is the select jitter φS(i) computed as the root mean square (RMS) of the di(j) as j ranges from 1 to n. For the purpose of notation in the example to follow, let φR(i) be the peer jitter computed by the clock filter algorithm for the ith candidate.

    +

    The object at each round is to prune the entry with the largest metric until the termination condition is met. Note that the select jitter must be recomputed at each round, but the peer jitter does not change. At each round the remaining entries on the list represent the survivors of that round. If the candidate to be pruned is preemptable and the number of candidates is greater than the maxclock threshold, the association is demobilized. This is useful in the schemes described on the Automatic Server Discovery Schemes page. The maxclock threshold default is 10, but it can be changed using the maxclock option of the tos command. Further pruning is subject to the following termination conditions, but no associations will be automatically demobilized.

    +

    The termination condition has two parts. First, if the number of survivors is not greater than the minclock threshold set by the minclock option of the tos command, the pruning process terminates. The minclock default is 3, but can be changed to fit special conditions, as described on the Mitigation Rules and the prefer Keyword page.

    +
    gif +

    Figure 1. Cluster Algorithm

    +
    +

    The second termination condition is more intricate. Figure 1 shows a round where a candidate of (a) is pruned to yield the candidates of (b). Let φmax be the maximum select jitter and φmin be the minimum peer jitter over all candidates on the list. In (a), candidate 1 has the highest select jitter, so φmax = φS(1). Candidate 4 has the lowest peer jitter, so φmin = φR(4). Since φmax > φmin, select jitter dominates peer jitter,the algorithm prunes candidate 1. In (b), φmax = φS(3) and φmin R(4). Since φmax < φmin, pruning additional candidates does not reduce select jitter, the algorithm terminates with candidates 2, 3 and 4 as survivors.

    +

    The survivor list is passed on to the the mitigation algorithms, which combine the survivors, select a system peer, and compute the system statistics passed on to dependent clients. Note the use of root distance λ as a weight factor at each round in the clock cluster algorithm. This is to favor the survivors with the lowest root distance and thus the smallest maximum error.

    +
    + + + diff --git a/contrib/ntp/html/comdex.html b/contrib/ntp/html/comdex.html new file mode 100644 index 000000000..0d632f16f --- /dev/null +++ b/contrib/ntp/html/comdex.html @@ -0,0 +1,29 @@ + + + + + +Command Index + + + +

    Command Index

    +giffrom Alice's Adventures in Wonderland, Lewis Carrol +

    The Mad Hatter says "Bring it on".

    +

    Last update: + 31-Jan-2014 06:54 + UTC

    +
    +

    Related Links

    + + + + + + +
    + + + + + diff --git a/contrib/ntp/html/config.html b/contrib/ntp/html/config.html new file mode 100644 index 000000000..ae68c8956 --- /dev/null +++ b/contrib/ntp/html/config.html @@ -0,0 +1,40 @@ + + + + + + + + Build Options + + + + +

    Build Options

    + giffrom Pogo, Walt Kelly +

    Gnu autoconfigure tools are in the backpack.

    +

    Last update: + 10-Mar-2014 04:59 + UTC

    +
    +
    +

    Most modern software distributions include an autoconfigure utility which + customizes the build and install configuration according to the specific + hardware, operating system and file system conventions. For NTP this + utility is called configure, which is run before building and installing + the program components. For most installations no additional actions + are required other than running configure with no options. + However, it is possible to customize the build and install configuration + through the use of configure options.

    +

    The available options, together with + a concise description, can be displayed by running configure with + the --help option. Various options can be used to reduce the memory + footprint, adjust the scheduling priority, enable or disable debugging + support or reference clock driver support. The options can be used + to specify where to install the program components or where to find + various libraries if they are not in the default place.

    +
    + + + + diff --git a/contrib/ntp/html/confopt.html b/contrib/ntp/html/confopt.html index e2a04c47c..b964d245b 100644 --- a/contrib/ntp/html/confopt.html +++ b/contrib/ntp/html/confopt.html @@ -1,82 +1,105 @@ - - - - - - Server Options - - - - -

    Server Options

    - giffrom Pogo, Walt Kelly -

    The chicken is getting configuration advice.

    -

    Last update: 20:57 UTC Monday, October 10, 2005

    -
    -

    Related Links

    - -

    Table of Contents

    - -
    -

    Following is a description of the configuration commands in NTPv4. There are two classes of commands, configuration commands that configure an association with a remote server, peer or reference clock, and auxilliary commands that specify environmental variables that control various related operations.

    -

    Configuration Commands

    -

    The various modes are determined by the command keyword and the required IP address. Addresses are classed by type as (s) a remote server or peer (IPv4 class A, B and C), (b) the broadcast address of a local interface, (m) a multicast address (IPv4 class D), or (r) a reference clock address (127.127.x.x). The options that can be used with these commands are listed below.

    -

    If the Basic Socket Interface Extensions for IPv6 (RFC-2553) is detected, support for the IPv6 address family is generated in addition to the default support of the IPv4 address family. IPv6 addresses can be identified by the presence of colons ":" in the address field. IPv6 addresses can be used almost everywhere where IPv4 addresses can be used, with the exception of reference clock addresses, which are always IPv4. Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

    -

    There are three types of associations: persistent, preemptable and ephemeral. Persistent associations are mobilized by a configuration command and never demobilized. Preemptable associations, which are new to NTPv4, are mobilized by a configuration command which includes the prempt flag and are demobilized by timeout or error. Ephemeral associations are mobilized upon arrival of designated messages and demobilized by timeout or error.

    + + + +Server Commands and Options + + + + +

    Server Commands and Options

    +giffrom Pogo, +Walt Kelly +

    The chicken is getting configuration advice.

    +

    Last update: + 10-Mar-2014 05:01 + UTC

    +
    +

    Related Links

    + + +

    Table of Contents

    + +
    +

    Server and Peer Addresses

    +

    Following is a description of the server configuration commands in NTPv4. There are two classes of commands, configuration commands that configure an association with a remote server, peer or reference clock, and auxiliary commands that specify environment variables that control various related operations.

    +

    The various modes described on the Association Management page are determined by the command keyword and the DNS name or IP address. Addresses are classed by type as (s) a remote server or peer (IPv4 class A, B and C or IPv6), (b) the IPv4 broadcast address of a local interface, (m) a multicast address (IPv4 class D or IPv6), or (r) a reference clock address (127.127.x.x). For type m addresses the IANA has assigned the multicast group address IPv4 224.0.1.1 and IPv6 ff05::101 (site local) exclusively to NTP, but other nonconflicting addresses can be used.

    +

    If the Basic Socket Interface Extensions for IPv6 (RFC-2553) is detected, + support for the IPv6 address family is generated in addition to the default IPv4 address family. IPv6 addresses can be identified by the presence of colons ":" in the address field. IPv6 addresses can be used almost everywhere where IPv4 addresses can be used, with the exception of reference clock addresses, which are always IPv4. Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

    +

    Server Commands

    +

    Unless noted otherwise, further information about these commands is on the Association Management page.

    +
    server address [options ...]
    + peer address [options ...]
    + broadcast address [options ...]
    + manycastclient address [options ...]
    + pool address [options ...]
    + unpeer [address | associd]
    +
    These commands specify the remote server name or address to be used and the mode in which to operate. The address can be either a DNS name or a IPv4 or IPv6 address in standard notation. In general, multiple commands of each type can be used for different server and peer addresses or multicast groups.
    -
    server address [options ...]
    - peer address [options ...]
    - broadcast address [options ...]

    - manycastclient address [options ...] -
    These four commands specify the time server name or address to be used and the mode in which to operate. The address can be either a DNS name or a IP address in dotted-quad notation. Additional information on association behavior can be found in the Association Management page. -
    -
    server -
    For type s and r addresses (only), this command normally mobilizes a persistent client mode association with the specified remote server or local reference clock. If the preempt flag is specified, a preemptable association is mobilized instead. In client mode the client clock can synchronize to the remote server or local reference clock, but the remote server can never be synchronized to the client clock. This command should NOT be used for type b or m addresses.
    peer -
    For type s addresses (only), this command mobilizes a persistent symmetric-active mode association with the specified remote peer. In this mode the local clock can be synchronized to the remote peer or the remote peer can be synchronized to the local clock. This is useful in a network of servers where, depending on various failure scenarios, either the local or remote peer may be the better source of time. This command should NOT be used for type b, m or r addresses. -
    broadcast -
    For type b and m addresses (only), this command mobilizes a persistent broadcast mode association. Multiple commands can be used to specify multiple local broadcast interfaces (subnets) and/or multiple multicast groups. Note that local broadcast messages go only to the interface associated with the subnet specified, but multicast messages go to all interfaces. -
    In broadcast mode the local server sends periodic broadcast messages to a client population at the address specified, which is usually the broadcast address on (one of) the local network(s) or a multicast address assigned to NTP. The IANA has assigned the multicast group address IPv4 224.0.1.1 and IPv6 ff05::101 (site local) exclusively to NTP, but other nonconflicting addresses can be used to contain the messages within administrative boundaries. Ordinarily, this specification applies only to the local server operating as a sender; for operation as a broadcast client, see the broadcastclient or multicastclient commands below. -
    manycastclient -
    For type m addresses (only), this command mobilizes a preemptable manycast client mode association for the multicast group address specified. In this mode a specific address must be supplied which matches the address used on the manycastserver command for the designated manycast servers. The NTP multicast address 224.0.1.1 assigned by the IANA should NOT be used, unless specific means are taken to avoid spraying large areas of the Internet with these messages and causing a possibly massive implosion of replies at the sender. -
    The manycastclient command specifies that the host is to operate in client mode with the remote servers that are discovered as the result of broadcast/multicast messages. The client broadcasts a request message to the group address associated with the specified address and specifically enabled servers respond to these messages. The client selects the servers providing the best time and continues as with the server command. The remaining servers are discarded as if never heard. -
    -
    -

    Command Options

    -
    -
    autokey -
    All packets sent to and received from the server or peer are to include authentication fields encrypted using the autokey scheme described in the Authentication Options page. This option is valid with all commands.
    burst -
    When the server is reachable, send a burst of eight packets instead of the usual one. The packet spacing is normally 2 s; however, the spacing between the first and second packets can be changed with the calldelay command to allow additional time for a modem or ISDN call to complete. This option is valid with only the server command and is a recommended option with this command when the maxpoll option is 11 or greater.
    iburst -
    When the server is unreachable, send a burst of eight packets instead of the usual one. The packet spacing is normally 2 s; however, the spacing between the first and second packets can be changed with the calldelay command to allow additional time for a modem or ISDN call to complete. This option is valid with only the server command and is a recommended option with this command.
    key key -
    All packets sent to and received from the server or peer are to include authentication fields encrypted using the specified key identifier with values from 1 to 65534, inclusive. The default is to include no encryption field. This option is valid with all commands.
    minpoll minpoll
    - maxpoll maxpoll -
    These options specify the minimum and maximum poll intervals for NTP messages, in seconds as a power of two. The maximum poll interval defaults to 10 (1,024 s), but can be increased by the maxpoll option to an upper limit of 17 (36.4 h). The minimum poll interval defaults to 6 (64 s), but can be decreased by the minpoll option to a lower limit of 4 (16 s). These option are valid only with the server and peer commands.
    noselect -
    Marks the server as unused, except for display purposes. The server is discarded by the selection algorithm. This option is valid only with the server and peer commands.
    preempt -
    Specifies the association as preemptable rather than the default persistent. This option is valied only with the server command.
    prefer -
    Marks the server as preferred. All other things being equal, this host will be chosen for synchronization among a set of correctly operating hosts. See the Mitigation Rules and the prefer Keyword page for further information. This option is valid only with the server and peer commands.
    true -
    Force the association to assume truechimer status; that is, always survive the selection and clustering algorithms. This option can be used with any association, but is most useful for reference clocks with large jitter on the serial port and precision pulse-per-second (PPS) signals. Caution: this option defeats the algorithms designed to cast out falsetickers and can allow these sources to set the system clock. This option is valid only with the server and peer commands.
    ttl ttl -
    This option is used only with broadcast server and manycast client modes. It specifies the time-to-live ttl to use on broadcast server and multicast server and the maximum ttl for the expanding ring search with manycast client packets. Selection of the proper value, which defaults to 127, is something of a black art and should be coordinated with the network administrator. -
    version version -
    Specifies the version number to be used for outgoing NTP packets. Versions 1-4 are the choices, with version 4 the default. This option is valid only with the server, peer and broadcast commands. -
    -

    Auxilliary Commands

    -
    -
    broadcastclient [novolley] -
    This command enables reception of broadcast server messages to any local interface (type b) address. Ordinarily, upon receiving a message for the first time, the broadcast client measures the nominal server propagation delay using a brief client/server exchange with the server, after which it continues in listen-only mode. If the novolley keyword is present, the exchange is not used and the value specified in the broadcastdelay command is used or, if the broadcastdelay command is not used, the default 4.0 ms. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page. Note that the novolley keyword is incompatible with public key authentication.
    manycastserver address [...] -
    This command enables reception of manycast client messages to the multicast group address(es) (type m) specified. At least one address is required. The NTP multicast address 224.0.1.1 assigned by the IANA should NOT be used, unless specific means are taken to limit the span of the reply and avoid a possibly massive implosion at the original sender. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page. -
    multicastclient address [...] -
    This command enables reception of multicast server messages to the multicast group address(es) (type m) specified. Upon receiving a message for the first time, the multicast client measures the nominal server propagation delay using a brief client/server exchange with the server, then enters the broadcast client mode, in which it synchronizes to succeeding multicast messages. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page. -
    -

    Bugs

    -

    The syntax checking is not picky; some combinations of ridiculous and even hilarious options and modes may not be detected.

    -
    - - - +
    server
    +
    For type s and r addresses (only), this command mobilizes a persistent client mode association with the specified remote server or local reference clock. If the preempt flag is specified, a preemptable client mode association is mobilized instead.
    +
    peer
    +
    For type s addresses (only), this command mobilizes a persistent symmetric-active mode association with the specified remote peer.
    +
    broadcast
    +
    For type b and m addressees (only), this command mobilizes a broadcast or multicast server mode association. Note that type b messages go only to the interface specified, but type m messages go to all interfaces.
    +
    manycastclient
    +
    For type m addresses (only), this command mobilizes a preemptable manycast client mode association for the multicast group address specified. In this mode the address must match the address specified on the manycastserver command of one or more designated manycast servers. Additional information about this command is on the Automatic Server Discovery page.
    +
    pool
    +
    For type s addresses (only) this command mobilizes a preemptable pool client mode association for the DNS name specified. The DNS name must resolve to one or more IPv4 or IPv6 addresses. Additional information about this command is on the Automatic Server Discovery page. The www.pool.ntp.org page describes a compatible pool of public NTP servers.
    +
    unpeer
    +
    This command removes a previously configured association. An address or association ID can be used to identify the association. Either an IP address or DNS name can be used. This command is most useful when supplied via ntpq runtime configuration commands :config and config-from-file.
    +
    + +

    Server Command Options

    +
    +
    autokey
    +
    Send and receive packets authenticated by the Autokey scheme described + on the Autokey Public Key Authentication page. This option is mutually exclusive with the key option.
    +
    burst
    +
    When the server is reachable, send a burst of packets instead of the usual one. This option is valid only with the server command and type s addresses. It is a recommended option when the maxpoll option is greater than 10 (1024 s). Additional information about this option is on the Poll Program page.
    +
    iburst
    +
    When the server is unreachable, send a burst of packets instead of the usual one. This option is valid only with the server command and type s addresses. It is a recommended option with this command. Additional information about this option is on the Poll Program page.
    +
    ident group
    +
    Specify the group name for the association. See the Autokey Public-Key Authentication page for further information.
    +
    key key
    +
    Send and receive packets authenticated by the symmetric key scheme described in the Authentication Support page. The key specifies the key identifier with values from 1 to 65534, inclusive. This option is mutually exclusive with the autokey option.
    minpoll minpoll
    +
    maxpoll maxpoll
    +
    These options specify the minimum and maximum poll intervals for NTP messages, in seconds as a power of two. The maximum poll interval defaults to 10 (1024 s), but can be increased by the maxpoll option to an upper limit of 17 (36 hr). The minimum poll interval defaults to 6 (64 s), but can be decreased by the minpoll option to a lower limit of 3 (8 s). Additional information about this option is on the Poll Program page.
    +
    mode option
    +
    Pass the option to a reference clock driver, where option is an integer in the range from 0 to 255, inclusive. This option is valid only with type r addresses.
    +
    noselect
    +
    Marks the server or peer to be ignored by the selection algorithm as unreachable, but visible to the monitoring program. This option is valid only with the server and peer commands.
    +
    preempt
    +
    Specifies the association as preemptable rather than the default persistent. This option is ignored with the broadcast command and is most useful with the manycastclient and pool commands.
    +
    prefer
    +
    Mark the server as preferred. All other things being equal, this host will be chosen for synchronization among a set of correctly operating hosts. See the Mitigation Rules and the prefer Keyword page for further information. This option is valid only with the server and peer commands.
    +
    true
    +
    Mark the association to assume truechimer status; that is, always survive the selection and clustering algorithms. This option can be used with any association, but is most useful for reference clocks with large jitter on the serial port and precision pulse-per-second (PPS) signals. Caution: this option defeats the algorithms designed to cast out falsetickers and can allow these sources to set the system clock. This option is valid only with the server and peer commands.
    +
    ttl ttl
    +
    This option specifies the time-to-live ttl for the broadcast command and the maximum ttl for the expanding ring search used by the manycastclient command. Selection of the proper value, which defaults to 127, is something of a black art and should be coordinated with the network administrator. This option is invalid with type r addresses.
    +
    version version
    +
    Specifies the version number to be used for +outgoing NTP packets. Versions 1-4 are the choices, with version 4 the default.
    +
    xleave
    +
    Operate in interleaved mode (symmetric and broadcast modes only). Further information is on the NTP Interleaved Modes page.
    +
    +

    Auxiliary Commands

    +
    +
    broadcastclient
    +
    Enable reception of broadcast server messages to any local interface (type b address). Ordinarily, upon receiving a broadcast message for the first time, the broadcast client measures the nominal server propagation delay using a brief client/server exchange, after which it continues in listen-only mode. If a nonzero value is specified in the broadcastdelay command, the value becomes the delay and the volley is not executed. Note: the novolley option has been deprecated for future enhancements. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page. Note that the volley is required with public key authentication in order to run the Autokey protocol.
    +
    manycastserver address [...]
    +
    Enable reception of manycast client messages (type m) to the multicasts group address(es) (type m) specified. At least one address is required. Note that, in order to avoid accidental or malicious disruption, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page.
    +
    multicastclient address [...]
    +
    Enable reception of multicast server messages to the multicast group address(es) (type m) specified. Upon receiving a message for the first time, the multicast client measures the nominal server propagation delay using a brief client/server exchange with the server, then enters the broadcast client mode, in which it synchronizes to succeeding multicast messages. Note that, in order to avoid accidental or malicious disruption in this mode, both the server and client should operate using symmetric key or public key authentication as described in the Authentication Options page.
    +
    mdnstries number
    +
    If we are participating in mDNS, after we have synched for the first time we attempt to register with the mDNS system. If that registration attempt fails, we try again at one minute intervals for up to mdnstries times. After all, ntpd may be starting before mDNS. The default value for mdnstries is 5.
    +
    +
    + + diff --git a/contrib/ntp/html/copyright.html b/contrib/ntp/html/copyright.html index cf3497906..94fffc4d3 100644 --- a/contrib/ntp/html/copyright.html +++ b/contrib/ntp/html/copyright.html @@ -1,25 +1,25 @@ - - - - - Copyright Notice - - - - -

    Copyright Notice

    - jpg "Clone me," says Dolly sheepishly -

    Last update: 20:31 UTC Saturday, January 06, 2007

    -
    -
    -

    The following copyright notice applies to all files collectively called the Network Time Protocol Version 4 Distribution. Unless specifically declared otherwise in an individual file, this notice applies as if the text was explicitly included in the file.
    -

    -
    +
    +
    +Copyright Notice
    +
    +
    +
    +
    +

    Copyright Notice

    +jpg "Clone me," says Dolly sheepishly. +

    Last update: + 17-Jan-2015 00:16 + UTC

    +
    +

    +
    +

    The following copyright notice applies to all files collectively called the Network Time Protocol Version 4 Distribution. Unless specifically declared otherwise in an individual file, this entire notice applies as if the text was explicitly included in the file.

    +
     ***********************************************************************
     *                                                                     *
    -* Copyright (c) David L. Mills 1992-2009                              *
    +* Copyright (c) University of Delaware 1992-2015                      *
     *                                                                     *
     * Permission to use, copy, modify, and distribute this software and   *
     * its documentation for any purpose with or without fee is hereby     *
    @@ -35,62 +35,100 @@
     *                                                                     *
     ***********************************************************************
     
    -

    The following individuals contributed in part to the Network Time Protocol Distribution Version 4 and are acknowledged as authors of this work.

    -
      -
    1. Mark Andrews <mark_andrews@isc.org> Leitch atomic clock controller -
    2. Bernd Altmeier <altmeier@atlsoft.de> hopf Elektronik serial line and PCI-bus devices -
    3. Viraj Bais <vbais@mailman1.intel.com> and Clayton Kirkwood <kirkwood@striderfm.intel.com> port to WindowsNT 3.5 -
    4. Michael Barone <michael,barone@lmco.com> GPSVME fixes -
    5. Jean-Francois Boudreault <Jean-Francois.Boudreault@viagenie.qc.ca>IPv6 support -
    6. Karl Berry <karl@owl.HQ.ileaf.com> syslog to file option -
    7. Greg Brackley <greg.brackley@bigfoot.com> Major rework of WINNT port. Clean up recvbuf and iosignal code into separate modules. -
    8. Marc Brett <Marc.Brett@westgeo.com> Magnavox GPS clock driver -
    9. Piete Brooks <Piete.Brooks@cl.cam.ac.uk> MSF clock driver, Trimble PARSE support -
    10. Reg Clemens <reg@dwf.com> Oncore driver (Current maintainer) -
    11. Steve Clift <clift@ml.csiro.au> OMEGA clock driver -
    12. Casey Crellin <casey@csc.co.za> vxWorks (Tornado) port and help with target configuration -
    13. Sven Dietrich <sven_dietrich@trimble.com> Palisade reference clock driver, NT adj. residuals, integrated Greg's Winnt port. -
    14. John A. Dundas III <dundas@salt.jpl.nasa.gov> Apple A/UX port -
    15. Torsten Duwe <duwe@immd4.informatik.uni-erlangen.de> Linux port -
    16. Dennis Ferguson <dennis@mrbill.canet.ca> foundation code for NTP Version 2 as specified in RFC-1119 -
    17. John Hay <jhay@@icomtek.csir.co.za> IPv6 support and testing -
    18. Glenn Hollinger <glenn@herald.usask.ca> GOES clock driver -
    19. Mike Iglesias <iglesias@uci.edu> DEC Alpha port -
    20. Jim Jagielski <jim@jagubox.gsfc.nasa.gov> A/UX port -
    21. Jeff Johnson <jbj@chatham.usdesign.com> massive prototyping overhaul -
    22. Hans Lambermont <Hans.Lambermont@nl.origin-it.com> or <H.Lambermont@chello.nl> ntpsweep -
    23. Poul-Henning Kamp <phk@FreeBSD.ORG> Oncore driver (Original author) -
    24. Frank Kardel <kardel (at) ntp (dot) org> PARSE <GENERIC> driver (>14 reference clocks), STREAMS modules for PARSE, support scripts, syslog cleanup, dynamic interface handling -
    25. William L. Jones <jones@hermes.chpc.utexas.edu> RS/6000 AIX modifications, HPUX modifications -
    26. Dave Katz <dkatz@cisco.com> RS/6000 AIX port -
    27. Craig Leres <leres@ee.lbl.gov> 4.4BSD port, ppsclock, Magnavox GPS clock driver -
    28. George Lindholm <lindholm@ucs.ubc.ca> SunOS 5.1 port -
    29. Louis A. Mamakos <louie@ni.umd.edu> MD5-based authentication -
    30. Lars H. Mathiesen <thorinn@diku.dk> adaptation of foundation code for Version 3 as specified in RFC-1305 -
    31. Danny Mayer <mayer@ntp.org>Network I/O, Windows Port, Code Maintenance -
    32. David L. Mills <mills@udel.edu> Version 4 foundation: clock discipline, authentication, precision kernel; clock drivers: Spectracom, Austron, Arbiter, Heath, ATOM, ACTS, KSI/Odetics; audio clock drivers: CHU, WWV/H, IRIG -
    33. Wolfgang Moeller <moeller@gwdgv1.dnet.gwdg.de> VMS port -
    34. Jeffrey Mogul <mogul@pa.dec.com> ntptrace utility -
    35. Tom Moore <tmoore@fievel.daytonoh.ncr.com> i386 svr4 port -
    36. Kamal A Mostafa <kamal@whence.com> SCO OpenServer port -
    37. Derek Mulcahy <derek@toybox.demon.co.uk> and Damon Hart-Davis <d@hd.org> ARCRON MSF clock driver -
    38. Rainer Pruy <Rainer.Pruy@informatik.uni-erlangen.de> monitoring/trap scripts, statistics file handling -
    39. Dirce Richards <dirce@zk3.dec.com> Digital UNIX V4.0 port -
    40. Wilfredo Sánchez <wsanchez@apple.com> added support for NetInfo -
    41. Nick Sayer <mrapple@quack.kfu.com> SunOS streams modules -
    42. Jack Sasportas <jack@innovativeinternet.com> Saved a Lot of space on the stuff in the html/pic/ subdirectory -
    43. Ray Schnitzler <schnitz@unipress.com> Unixware1 port -
    44. Michael Shields <shields@tembel.org> USNO clock driver -
    45. Jeff Steinman <jss@pebbles.jpl.nasa.gov> Datum PTS clock driver -
    46. Harlan Stenn <harlan@pfcs.com> GNU automake/autoconfigure makeover, various other bits (see the ChangeLog) -
    47. Kenneth Stone <ken@sdd.hp.com> HP-UX port -
    48. Ajit Thyagarajan <ajit@ee.udel.edu>IP multicast/anycast support -
    49. Tomoaki TSURUOKA <tsuruoka@nc.fukuoka-u.ac.jp>TRAK clock driver -
    50. Paul A Vixie <vixie@vix.com> TrueTime GPS driver, generic TrueTime clock driver -
    51. Ulrich Windl <Ulrich.Windl@rz.uni-regensburg.de> corrected and validated HTML documents according to the HTML DTD -
    -
    - - - +

    Content starting in 2011 from Harlan Stenn, Danny Mayer, and Martin Burnicki is:

    +
    +***********************************************************************
    +*                                                                     *
    +* Copyright (c) Network Time Foundation 2011-2015                     *
    +*                                                                     *
    +* All Rights Reserved                                                 *
    +*                                                                     *
    +* Redistribution and use in source and binary forms, with or without  *
    +* modification, are permitted provided that the following conditions  *
    +* are met:                                                            *
    +* 1. Redistributions of source code must retain the above copyright   *
    +*    notice, this list of conditions and the following disclaimer.    *
    +* 2. Redistributions in binary form must reproduce the above          *
    +*    copyright notice, this list of conditions and the following      *
    +*    disclaimer in the documentation and/or other materials provided  *
    +*    with the distribution.                                           *
    +*                                                                     *
    +* THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS  *
    +* OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED   *
    +* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE  *
    +* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE    *
    +* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR *
    +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT   *
    +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR  *
    +* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF          *
    +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT           *
    +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE   *
    +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH    *
    +* DAMAGE.                                                             *
    +***********************************************************************
    +
    +

    The following individuals contributed in part to the Network Time Protocol Distribution Version 4 and are acknowledged as authors of this work.

    +
      +
    1. Takao Abe <takao_abe@xurb.jp> Clock driver for JJY receivers
    2. +
    3. Mark Andrews <mark_andrews@isc.org> Leitch atomic clock controller
    4. +
    5. Bernd Altmeier <altmeier@atlsoft.de> hopf Elektronik serial line and PCI-bus devices
    6. +
    7. Viraj Bais <vbais@mailman1.intel.com> and Clayton Kirkwood <kirkwood@striderfm.intel.com> port to WindowsNT 3.5
    8. +
    9. Michael Barone <michael,barone@lmco.com> GPSVME fixes
    10. +
    11. Karl Berry <karl@owl.HQ.ileaf.com> syslog to file option
    12. +
    13. Greg Brackley <greg.brackley@bigfoot.com> Major rework of WINNT port. Clean up recvbuf and iosignal code into separate modules.
    14. +
    15. Marc Brett <Marc.Brett@westgeo.com> Magnavox GPS clock driver
    16. +
    17. Piete Brooks <Piete.Brooks@cl.cam.ac.uk> MSF clock driver, Trimble PARSE support
    18. +
    19. Nelson B Bolyard <nelson@bolyard.me> update and complete broadcast and crypto features in sntp
    20. +
    21. Jean-Francois Boudreault <Jean-Francois.Boudreault@viagenie.qc.ca> IPv6 support
    22. +
    23. Reg Clemens <reg@dwf.com> Oncore driver (Current maintainer)
    24. +
    25. Steve Clift <clift@ml.csiro.au> OMEGA clock driver
    26. +
    27. Casey Crellin <casey@csc.co.za> vxWorks (Tornado) port and help with target configuration
    28. +
    29. Sven Dietrich <sven_dietrich@trimble.com> Palisade reference clock driver, NT adj. residuals, integrated Greg's Winnt port.
    30. +
    31. John A. Dundas III <dundas@salt.jpl.nasa.gov> Apple A/UX port
    32. +
    33. Torsten Duwe <duwe@immd4.informatik.uni-erlangen.de> Linux port
    34. +
    35. Dennis Ferguson <dennis@mrbill.canet.ca> foundation code for NTP Version 2 as specified in RFC-1119
    36. +
    37. John Hay <jhay@icomtek.csir.co.za> IPv6 support and testing
    38. +
    39. Dave Hart <davehart@davehart.com> General maintenance, Windows port interpolation rewrite
    40. +
    41. Claas Hilbrecht <neoclock4x@linum.com> NeoClock4X clock driver
    42. +
    43. Glenn Hollinger <glenn@herald.usask.ca> GOES clock driver
    44. +
    45. Mike Iglesias <iglesias@uci.edu> DEC Alpha port
    46. +
    47. Jim Jagielski <jim@jagubox.gsfc.nasa.gov> A/UX port
    48. +
    49. Jeff Johnson <jbj@chatham.usdesign.com> massive prototyping overhaul
    50. +
    51. Hans Lambermont <Hans.Lambermont@nl.origin-it.com> or <H.Lambermont@chello.nl> ntpsweep
    52. +
    53. Poul-Henning Kamp <phk@FreeBSD.ORG> Oncore driver (Original author)
    54. +
    55. Frank Kardel <kardel (at) ntp (dot) org> PARSE <GENERIC> (driver 14 reference clocks), STREAMS modules for PARSE, support scripts, syslog cleanup, dynamic interface handling
    56. +
    57. Johannes Maximilian Kuehn <kuehn@ntp.org> Rewrote sntp to comply with NTPv4 specification, ntpq saveconfig
    58. +
    59. William L. Jones <jones@hermes.chpc.utexas.edu> RS/6000 AIX modifications, HPUX modifications
    60. +
    61. Dave Katz <dkatz@cisco.com> RS/6000 AIX port
    62. +
    63. Craig Leres <leres@ee.lbl.gov> 4.4BSD port, ppsclock, Magnavox GPS clock driver
    64. +
    65. George Lindholm <lindholm@ucs.ubc.ca> SunOS 5.1 port
    66. +
    67. Louis A. Mamakos <louie@ni.umd.edu> MD5-based authentication
    68. +
    69. Lars H. Mathiesen <thorinn@diku.dk> adaptation of foundation code for Version 3 as specified in RFC-1305
    70. +
    71. Danny Mayer <mayer@ntp.org>Network I/O, Windows Port, Code Maintenance
    72. +
    73. David L. Mills <mills@udel.edu> Version 4 foundation, precision kernel; clock drivers: 1, 3, 4, 6, 7, 11, 13, 18, 19, 22, 36
    74. +
    75. Wolfgang Moeller <moeller@gwdgv1.dnet.gwdg.de> VMS port
    76. +
    77. Jeffrey Mogul <mogul@pa.dec.com> ntptrace utility
    78. +
    79. Tom Moore <tmoore@fievel.daytonoh.ncr.com> i386 svr4 port
    80. +
    81. Kamal A Mostafa <kamal@whence.com> SCO OpenServer port
    82. +
    83. Derek Mulcahy <derek@toybox.demon.co.uk> and Damon Hart-Davis <d@hd.org> ARCRON MSF clock driver
    84. +
    85. Rob Neal <neal@ntp.org> Bancomm refclock and config/parse code maintenance
    86. +
    87. Rainer Pruy <Rainer.Pruy@informatik.uni-erlangen.de> monitoring/trap scripts, statistics file handling
    88. +
    89. Dirce Richards <dirce@zk3.dec.com> Digital UNIX V4.0 port
    90. +
    91. Wilfredo Sánchez <wsanchez@apple.com> added support for NetInfo
    92. +
    93. Nick Sayer <mrapple@quack.kfu.com> SunOS streams modules
    94. +
    95. Jack Sasportas <jack@innovativeinternet.com> Saved a Lot of space on the stuff in the html/pic/ subdirectory
    96. +
    97. Ray Schnitzler <schnitz@unipress.com> Unixware1 port
    98. +
    99. Michael Shields <shields@tembel.org> USNO clock driver
    100. +
    101. Jeff Steinman <jss@pebbles.jpl.nasa.gov> Datum PTS clock driver
    102. +
    103. Harlan Stenn <harlan@pfcs.com> GNU automake/autoconfigure makeover, various other bits (see the ChangeLog)
    104. +
    105. Kenneth Stone <ken@sdd.hp.com> HP-UX port
    106. +
    107. Ajit Thyagarajan <ajit@ee.udel.edu>IP multicast/anycast support
    108. +
    109. Tomoaki TSURUOKA <tsuruoka@nc.fukuoka-u.ac.jp>TRAK clock driver
    110. +
    111. Brian Utterback <brian.utterback@oracle.com> General codebase, Solaris issues
    112. +
    113. Loganaden Velvindron <loganaden@gmail.com> Sandboxing (libseccomp) support
    114. +
    115. Paul A Vixie <vixie@vix.com> TrueTime GPS driver, generic TrueTime clock driver
    116. +
    117. Ulrich Windl <Ulrich.Windl@rz.uni-regensburg.de> corrected and validated HTML documents according to the HTML DTD
    118. +
    +
    + diff --git a/contrib/ntp/html/debug.html b/contrib/ntp/html/debug.html index c732c42ce..1a4981acd 100644 --- a/contrib/ntp/html/debug.html +++ b/contrib/ntp/html/debug.html @@ -1,172 +1,93 @@ - - - - - - NTP Debugging Techniques - - - - -

    NTP Debugging Techniques

    - giffrom Pogo, Walt Kelly -

    We make house calls and bring our own bugs.

    -

    Last update: 18:38 UTC Thursday, July 28, 2005

    -
    -

    More Help

    - -
    -

    Once the NTP software distribution has been compiled and installed and the configuration file constructed, the next step is to verify correct operation and fix any bugs that may result. Usually, the command line that starts the daemon is included in the system startup file, so it is executed only at system boot time; however, the daemon can be stopped and restarted from root at any time. Usually, no command-line arguments are required, unless special actions described in the ntpd - Network Time Protocol (NTP) daemon page are required. Once started, the daemon will begin sending and receiving messages, as specified in the configuration file.

    -

    Initial Startup

    -

    When started for the first time, the frequency file, usually called ntp.drift, has not yet been created. The daemon switches to a special training routine designed to quickly determine the system clock frequency offset of the particular machine. The routine first measures the current clock offset and sets the clock, then continues for up to twenty minutes before measuring the clock offset, which might involve setting the clock again. The two measurements are used to compute the initial frequency offset and the daemon continues in regular operation, during which the frequency offset is continuously updated. Once each hour the daemon writes the current frequency offset to the ntp.drift file. When restarted after that, the daemon reads the frequency offset from the ntp.drift file and avoids the training routine.

    -

    Note that the daemon requires at least four packet exchanges when first started in any case. This is required in order for the mitigation algorithms to insure valid and accurate measurements and defend against network delay spikes and accidental or malicious errors induced by the servers selected in the configuration file. It normally takes less than four minutes to set the clock when first started, but this can be reduced to less than ten seconds with the iburst configuration option.

    -

    The best way to verify correct operation is using the ntpq - standard NTP query program and ntpdc - special NTP query program utility programs, either on the server itself or from another machine elsewhere in the network. The ntpq program implements the management functions specified in the NTP specification RFC-1305, Appendix A. The ntpdc program implements additional functions not provided in the standard. Both programs can be used to inspect the state variables defined in the specification and, in the case of ntpdc, additional ones intended for serious debugging. In addition, the ntpdc program can be used to selectively reconfigure and enable or disable some functions while the daemon is running.

    -

    In extreme cases with elusive bugs, the daemon can operate in two modes, depending on the presence of the -d command-line debug switch. If not present, the daemon detaches from the controlling terminal and proceeds autonomously. If one or more -d switches are present, the daemon does not detach and generates special output useful for debugging. In general, interpretation of this output requires reference to the sources. However, a single -d does produce only mildly cryptic output and can be very useful in finding problems with configuration and network troubles. With a little experience, the volume of output can be reduced by piping the output to grep and specifying the keyword of the trace you want to see.

    -

    Some problems are immediately apparent when the daemon first starts running. The most common of these are the lack of a UDP port for NTP (123) in the Unix /etc/services file (or equivalent in some systems). Note that NTP does not use TCP in any form. Also note that NTP requires 123 for both source and destination ports. These facts should be pointed out to firewall administrators.

    -

    Other problems are apparent in the system log, which ordinarily shows the startup banner, some cryptic initialization data and the computed precision value. Error messages at startup and during regular operation are sent to the system log. In real emergencies the daemon will sent a terminal error message to the system log and then cease operation.

    -

    The next most common problem is incorrect DNS names. Check that each DNS name used in the configuration file exists and that the address responds to the Unix ping command. The Unix traceroute or Windows tracert utility can be used to verify a partial or complete path exists. Most problems reported to the NTP newsgroup are not NTP problems, but problems with the network or firewall configuration.

    -

    When first started, the daemon polls the servers listed in the configuration file at 64-s intervals. In order to allow a sufficient number of samples for the NTP algorithms to reliably discriminate between truechimer servers and possible falsetickers, at least four valid messages from at least one server or peer listed in the configuration file is required before the daemon can set the clock. However, if the difference between the client time and server time is greater than the panic threshold, which defaults to 1000 s, the daemon sends a message to the system log and shuts down without setting the clock. It is necessary to set the local clock to within the panic threshold first, either manually by eyeball and wristwatch and the Unix date command, or by the ntpdate or ntpd -q commands. The panic threshold can be changed by the tinker panic command discribed on the Miscellaneous Options page. The panic threshold can be disabled for the first measurement by the -g command line option described on the ntpd - Network Time Protocol (NTP) daemon page.

    -

    If the difference between local time and server time is less than the panic threshold but greater than the step threshold, which defaults to 128 ms, the daemon will perform a step adjustment; otherwise, it will gradually slew the clock to the nominal time. Step adjustments are extremely rare in ordinary operation, usually as the result of reboot or hardware failure. The step threshold can be changed to 300 s using the -x command line option described on the ntpd page. This is usually sufficient to avoid a step after reboot or when the operator has set the system clock to within five minutes by eyeball-and-wristwatch. In extreme cases the step threshold can be changed by the tinker step command discribed on the Miscellaneous Options page. If set to zero, the clock will never be stepped; however, users should understand the implications for doing this in a distributed data network where all processing must be tightly synchronized. See the NTP Timescale and Leap Seconds page for further information. If a step adjustment is made, the clock discipline algorithm will start all over again, requiring another round of at least four messages as before. This is necessary so that all servers and peers operate on the same set of time values.

    -

    The clock discipline algorithm is designed to avoid large noise spikes that might occur on a congested network or access line. If an offset sample exceeds the step threshold, it is ignored and a timer started. If a later sample is below the step threshold, the counter is reset and operation continues normally. However, if the counter is greater than the stepout interval, which defaults to 900 s, the next sample will step the time as directed. The stepout threshold can be changed by the tinker stepout command discribed on the Miscellaneous Options page.

    -

    If for some reason the hardware clock oscillator frequency error is very large, say over 400 PPM, the time offset when the daemon is started for the first time may increase over time until exceeding the step threshold, which requires a frequency adjustment and another step correction. However, due to provisions that reduce vulnerability to noise spikes, the second correction will not be done until after the stepout threshold. When the frequency error is very large, it may take a number of cycles like this until converging to the nominal frequency correction and writing the ntp.drift file. If the frequency error is over 500 PPM, convergence will never occur and occasional step adjustments will occur indefinitely.

    -

    Verifying Correct Operation

    -

    After starting the daemon, run the ntpq program using the -n switch, which will avoid possible distractions due to name resolution problems. Use the pe command to display a billboard showing the status of configured peers and possibly other clients poking the daemon. After operating for a few minutes, the display should be something like:

    -
    -ntpq> pe
    -     remote      refid       st t when poll reach delay offset jitter
    -=====================================================================
    --isipc6.cairn.ne .GPS1.        1 u  18  64  377  65.592 -5.891  0.044
    -+saicpc-isiepc2. pogo.udel.edu 2 u 241 128  370  10.477 -0.117  0.067
    -+uclpc.cairn.net pogo.udel.edu 2 u  37  64  177 212.111 -0.551  0.187
    -*pogo.udel.edu   .GPS1.        1 u  95 128  377   0.607  0.123  0.027
    -
    -

    The host names or addresses shown in the remote column correspond to the server and peer entries listed in the configuration file; however, the DNS names might not agree if the names listed are not the canonical DNS names. IPv4 addresses are shown in dotted quad notation, while IPv6 addresses are shown alarmingly. The refid column shows the current source of synchronization, while the st column reveals the stratum, t the type (u = unicast, m = multicast, l = local, - = don't know), and poll the poll interval in seconds. The when column shows the time since the peer was last heard in seconds, while the reach column shows the status of the reachability register (see RFC-1305) in octal. The remaining entries show the latest delay, offset and jitter in milliseconds. Note that in NTP Version 4 what used to be the dispersion column has been replaced by the jitter column.

    -

    As per the NTP specification RFC-1305, when the stratum is between 0 and 15 for a NTP server, the refid field shows the server DNS name or, if not found, the IP address in dotted-quad. When the stratum is any value for a reference clock, this field shows the identification string assigned to the clock. However, until the client has synchronized to a server, or when the stratum for a NTP server is 0 (appears as 16 in the billboards), the status cannot be determined. As a help in debugging, the refid field is set to a four-character string called the kiss code. The current kiss codes are as as follows.

    -

    Peer Kiss Codes

    -

    ACST

    -
    -
    The association belongs to a anycast server. -
    AUTH -
    Server authentication failed. Please wait while the association is restarted. -
    AUTO -
    Autokey sequence failed. Please wait while the association is restarted. -
    BCST -
    The association belongs to a broadcast server. -
    CRYP -
    Cryptographic authentication or identification failed. The details should be in the system log file or the cryptostats statistics file, if configured. No further messages will be sent to the server. -
    DENY -
    Access denied by remote server. No further messages will be sent to the server. -
    DROP -
    Lost peer in symmetric mode. Please wait while the association is restarted. -
    RSTR -
    Access denied due to local policy. No further messages will be sent to the server. -
    INIT -
    The association has not yet synchronized for the first time. -
    MCST -
    The association belongs to a manycast server. -
    NKEY -
    No key found. Either the key was never installed or is not trusted. -
    RATE -
    Rate exceeded. The server has temporarily denied access because the client exceeded the rate threshold. -
    RMOT -
    Somebody is tinkering with the association from a remote host running ntpdc. Not to worry unless some rascal has stolen your keys. -
    STEP -
    A step change in system time has occurred, but the association has not yet resynchronized. -
    -

    System Kiss Codes

    -
    -
    INIT -
    The system clock has not yet synchronized for the first time. -
    STEP -
    A step change in system time has occurred, but the system clock has not yet resynchronized. -
    -

    The tattletale symbol at the left margin displays the synchronization status of each peer. The currently selected peer is marked *, while additional peers designated acceptable for synchronization are marked +. Peers marked * and + are included in the weighted average computation to set the local clock; the data produced by peers marked with other symbols are discarded. See the ntpq page for the meaning of these symbols.

    -

    Additional details for each peer separately can be determined by the following procedure. First, use the as command to display an index of association identifiers, such as

    -
    -ntpq> as
    -ind assID status  conf reach auth condition  last_event cnt
    -===========================================================
    -  1 50252  f314   yes   yes   ok    outlyer   reachable  1
    -  2 50253  f414   yes   yes   ok   candidat   reachable  1
    -  3 50254  f414   yes   yes   ok   candidat   reachable  1
    -  4 50255  f614   yes   yes   ok   sys.peer   reachable  1
    -
    -

    Each line in this billboard is associated with the corresponding line in the pe billboard above. The assID shows the unique identifier for each mobilized association, while the status column shows the peer status word in hex, as defined in the NTP specification. Next, use the rv command and the respective assID identifier to display a detailed synopsis for the selected peer, such as

    -
    -ntpq> rv 50253
    -status=f414 reach, conf, auth, sel_candidat, 1 event, event_reach,
    -srcadr=saicpc-isiepc2.cairn.net, srcport=123, dstadr=140.173.1.46,
    -dstport=123, keyid=3816249004, stratum=2, precision=-27,
    -rootdelay=10.925, rootdispersion=12.848, refid=pogo.udel.edu,
    -reftime=bd11b225.133e1437  Sat, Jul  8 2000 13:59:01.075, delay=10.550,
    -offset=-1.357, jitter=0.074, dispersion=1.444, reach=377, valid=7,
    -hmode=1, pmode=1, hpoll=6, ppoll=7, leap=00, flash=00 ok,
    -org=bd11b23c.01385836  Sat, Jul  8 2000 13:59:24.004,
    -rec=bd11b23c.02dc8fb8  Sat, Jul  8 2000 13:59:24.011,
    -xmt=bd11b21a.ac34c1a8  Sat, Jul  8 2000 13:58:50.672,
    -filtdelay=   10.45  10.50  10.63  10.40  10.48  10.43  10.49  11.26,
    -filtoffset=  -1.18  -1.26  -1.26  -1.35  -1.35  -1.42  -1.54  -1.81,
    -filtdisp=     0.51   1.47   2.46   3.45   4.40   5.34   6.33   7.28,
    -hostname="miro.time.saic.com", signature=md5WithRSAEncryption, flags=0x83f01, initsequence=61, initkey=0x287b649c,
    -timestamp=3172053041
    -
    -

    A detailed explanation of the fields in this billboard are beyond the scope of this discussion; however, most variables defined in the NTP Version 3 specification RFC-1305 are available along with others defined for NTPv4 on the ntpq page. This particular example was chosen to illustrate probably the most complex configuration involving symmetric modes and public-key cryptography. As the result of debugging experience, the names and values of these variables may change from time to time.

    -

    A useful indicator of miscellaneous problems is the flash value, which reveals the state of the various sanity tests on incoming packets. There are currently 12 bits, one for each test, numbered from the right, which is for test 1. If the test fails, the corresponding bit is set to one and zero otherwise. If any bit is set following each processing step, the packet is discarded. The meaning of each test is described on the ntpq page.

    -

    The three lines identified as filtdelay, filtoffset and filtdisp reveal the roundtrip delay, clock offset and dispersion for each of the last eight measurement rounds, all in milliseconds. Note that the dispersion, which is an estimate of the error, increases as the age of the sample increases. From these data, it is usually possible to determine the incidence of severe packet loss, network congestion, and unstable local clock oscillators. There are no hard and fast rules here, since every case is unique; however, if one or more of the rounds show large values or change radically from one round to another, the network is probably congested or lossy.

    -

    Once the daemon has set the local clock, it will continuously track the discrepancy between local time and NTP time and adjust the local clock accordingly. There are two components of this adjustment, time and frequency. These adjustments are automatically determined by the clock discipline algorithm, which functions as a hybrid phase/frequency feedback loop. The behavior of this algorithm is carefully controlled to minimize residual errors due to network jitter and frequency variations of the local clock hardware oscillator that normally occur in practice. However, when started for the first time, the algorithm may take some time to converge on the intrinsic frequency error of the host machine.

    -

    The state of the local clock itself can be determined using the rv command (without the argument), such as

    -
    -ntpq> rv
    -status=0644 leap_none, sync_ntp, 4 events, event_peer/strat_chg,
    -version="ntpd 4.0.99j4-r Fri Jul  7 23:38:17 GMT 2000 (1)",
    -processor="i386", system="FreeBSD3.4-RELEASE", leap=00, stratum=2,
    -precision=-27, rootdelay=0.552, rootdispersion=12.532, peer=50255,
    -refid=pogo.udel.edu,
    -reftime=bd11b220.ac89f40a  Sat, Jul  8 2000 13:58:56.673, poll=6,
    -clock=bd11b225.ee201472  Sat, Jul  8 2000 13:59:01.930, state=4,
    -phase=0.179, frequency=44.298, jitter=0.022, stability=0.001,
    -hostname="barnstable.udel.edu", signature=md5WithRSAEncryption,
    -flags=0x80011, hostkey=3171372095, refresh=3172016539
    -cert="grundoon.udel.edu grundoon.udel.edu 0x3 3233600829"
    -cert="whimsy.udel.edu whimsy.udel.edu 0x5 3233682156"
    -
    -

    An explanation about most of these variables is in the RFC-1305 specification. The most useful ones include clock, which shows when the clock was last adjusted, and reftime, which shows when the server clock of refid was last adjusted. The version, processor and system values are very helpful when included in bug reports. The mean millisecond time offset (phase) and deviation (jitter) monitor the clock quality, while the mean PPM frequency offset (frequency) and deviation (stability) monitor the clock stability and serve as a useful diagnostic tool. It has been the experience of NTP operators over the years that these data represent useful environment and hardware alarms. If the motherboard fan freezes up or some hardware bit sticks, the system clock is usually the first to notice it.

    -

    Among the new variables added for NTP Version 4 are the hostname, signature, flags, hostkey, refresh and cert, which are used for the Autokey public-key cryptography described on the Authentication Options page. The numeric values show the filestamps, in NTP seconds, that the associated media files were created. These are useful in diagnosing problems with cryptographic key consistency and ordering principles.

    -

    When nothing seems to happen in the pe billboard after some minutes, there may be a network problem. One common network problem is an access controlled router on the path to the selected peer or an access controlled server using methods described on the Access Control Options page. Another common problem is that the server is down or running in unsynchronized mode due to a local problem. Use the ntpq program to spy on the server variables in the same way you can spy on your own.

    -

    Normally, the daemon will adjust the local clock in small steps in such a way that system and user programs are unaware of its operation. The adjustment process operates continuously unless the apparent clock error exceeds the step threshold for a period longer than the stepout threshold, which for most Internet paths is a very rare event. If the event is simply an outlyer due to an occasional network delay spike, the correction is simply discarded; however, if the apparent time error persists for longer than the stepout threshold of about 17 minutes, the local clock is stepped or slewed to the new value as directed. This behavior is designed to resist errors due to severely congested network paths, as well as errors due to confused radio clocks upon the epoch of a leap second.

    -

    Large Frequency Errors

    -

    The frequency tolerance of computer clock oscillators can vary widely, which can put a strain on the daemon's ability to compensate for the intrinsic frequency error. While the daemon can handle frequency errors up to 500 parts-per-million (PPM), or 43 seconds per day, values much above 100 PPM reduce the headroom and increase the time to learn the particular value and record it in the ntp.drift file. In extreme cases before the particular oscillator frequency error has been determined, the residual system time offsets can sweep from one extreme to the other of the 128-ms tracking window only for the behavior to repeat at 900-s intervals until the measurements have converged.

    -

    In order to determine if excessive frequency error is a problem, observe the nominal filtoffset values for a number of rounds and divide by the poll interval. If the result is something approaching 500 PPM, there is a good chance that NTP will not work properly until the frequency error is reduced by some means. A common cause is the hardware time-of-year (TOY) clock chip, which must be disabled when NTP disciplines the software clock. For some systems this can be done using the tickadj utility and the -s command line argument. For other systems this can be done using a command in the system startup file.

    -

    If the TOY chip is not the cause, the problem may be that the hardware clock frequency may simply be too slow or two fast. In some systems this might require tweaking a trimmer capacitor on the motherboard. For other systems the clock frequency can be adjusted in increments of 100 PPM using the tickadj utility and the -t command line argument. Note that the tickadj alters certain kernel variables and, while the utility attempts to figure out an acceptable way to do this, there are many cases where tickadj is incompatible with a running kernel.

    -

    Access Controls

    -

    Provisions are included in ntpd for access controls which deflect unwanted traffic from selected hosts or networks. The controls described on the Access Control Options include detailed packet filter operations based on source address and address mask. Normally, filtered packets are dropped without notice other than to increment tally counters. However, the server can be configured to send a "kiss-o'-death" (KOD) packet to the client either when explicitly configured or when cryptographic authentication fails for some reason. The client association is permanently disabled, the access denied bit (TEST4) is set in the flash variable and a message is sent to the system log.

    -

    The access control provisions include a limit on the packet rate from a host or network. If an incoming packet exceeds the limit, it is dropped and a KOD sent to the source. If this occurs after the client association has synchronized, the association is not disabled, but a message is sent to the system log. See the Access Control Options page for further informatin.

    -

    Large Delay Variations

    -

    In some reported scenarios an access line may show low to moderate network delays during some period of the day and moderate to high delays during other periods. Often the delay on one direction of transmission dominates, which can result in large time offset errors, sometimes in the range up to a few seconds. It is not usually convenient to run ntpd throughout the day in such scenarios, since this could result in several time steps, especially if the condition persists for greater than the stepout threshold.

    -

    Specific provisions have been built into ntpd to cope with these problems. The scheme is called "huff-'n-puff and is described on the Miscellaneous Options page. An alternative approach in such scenarios is first to calibrate the local clock frequency error by running ntpd in continuous mode during the quiet interval and let it write the frequency to the ntp.drift file. Then, run ntpd -q from a cron job each day at some time in the quiet interval. In systems with the nanokernel or microkernel performance enhancements, including Solaris, Tru64, Linux and FreeBSD, the kernel continuously disciplines the frequency so that the residual correction produced by ntpd is usually less than a few milliseconds.

    -

    Cryptographic Authentication

    -

    Reliable source authentication requires the use of symmetric key or public key cryptography, as described on the Authentication Options page. In symmetric key cryptography servers and clients share session keys contained in a secret key file In public key cryptography, which requires the OpenSSL software library, the server has a private key, never shared, and a public key with unrestricted distribution. The cryptographic media required are produced by the ntp-keygen program.

    -

    Problems with symmetric key authentication are usually due to mismatched keys or improper use of the trustedkey command. A simple way to check for problems is to use the trace facility, which is enabled using the ntpd -d command line. As each packet is received a trace line is displayed which shows the authentication status in the auth field. A status of 1 indicates the packet was successful authenticated; otherwise it has failed.

    -

    A common misconception is the implication of the auth bit in the enable and disable commands. This bit does not affect authentication in any way other than to enable or disable mobilization of a new persistent association in broadcast/multicast client, manycast client or symmetric passive modes. If enabled, which is the default, these associations require authentication; if not, an association is mobilized even if not authenticated. Users are cautioned that running with authentication disabled is very dangerous, since an intruder can easily strike up an association and inject false time values.

    -

    Public key cryptography is supported in NTPv4 using the Autokey protocol, which is described in briefings on the NTP Project page linked from www.ntp.org. Development of this protocol is mature and the ntpd implementation is basically complete. Autokey version 2, which is the latest and current version, includes provisions to hike certificate trails, operate as certificate authorities and verify identity using challenge/response identification schemes. Further details of the protocol are on the Authentication Options page. Common problems with configuration and key generation are mismatched key files, broken links and missing or broken random seed file.

    -

    As in the symmetric key cryptography case, the trace facility is a good way to verify correct operation. A statistics file cryptostats records protocol transactions and error messages. The daemon requires a random seed file, public/private key file and a valid certificate file; otherwise it exits immediately with a message to the system log. As each file is loaded a trace message appears with its filestamp. There are a number of checks to insure that only consistent data are used and that the certificate is valid. When the protocol is in operation a number of checks are done to verify the server has the expected credentials and its filestamps and timestamps are consistent. Errors found are reported using NTP control and monitoring protocol traps with extended trap codes shown in the Authentication Options page.

    -

    To assist debugging every NTP extension field is displayed in the trace along with the Autokey operation code. Every extension field carrying a verified signature is identified and displayed along with filestamp and timestamp where meaningful. In all except broadcast/multicast client mode, correct operation of the protocol is confirmed by the absence of extension fields and an auth value of one. It is normal in broadcast/multicast client mode that the broadcast server use one extension field to show the host name, status word and association ID.

    -

    Debugging Checklist

    -

    If the ntpq or ntpdc programs do not show that messages are being received by the daemon or that received messages do not result in correct synchronization, verify the following:

    -
      -
    1. Verify the /etc/services file host machine is configured to accept UDP packets on the NTP port 123. NTP is specifically designed to use UDP and does not respond to TCP. -
    2. Check the system log for ntpd messages about configuration errors, name-lookup failures or initialization problems. Common system log messages are summarized on the ntpd System Log Messages page. Check to be sure that only one copy of ntpd is running. -
    3. Verify using ping or other utility that packets actually do make the round trip between the client and server. Verify using nslookup or other utility that the DNS server names do exist and resolve to valid Internet addresses. -
    4. Check that the remote NTP server is up and running. The usual evidence that it is not is a Connection refused message. -
    5. Using the ntpdc program, verify that the packets received and packets sent counters are incrementing. If the sent counter does not increment and the configuration file includes configured servers, something may be wrong in the host network or interface configuration. If this counter does increment, but the received counter does not increment, something may be wrong in the network or the server NTP daemon may not be running or the server itself may be down or not responding. -
    6. If both the sent and received counters do increment, but the reach values in the pe billboard with ntpq continues to show zero, received packets are probably being discarded for some reason. If this is the case, the cause should be evident from the flash variable as discussed above and on the ntpq page. It could be that the server has disabled access for the client address, in which case the refid field in the ntpq pe billboard will show a kiss code. See earlier on this page for a list of kiss codes and their meaning. -
    7. If the reach values in the pe billboard show the servers are alive and responding, note the tattletale symbols at the left margin, which indicate the status of each server resulting from the various grooming and mitigation algorithms. The interpretation of these symbols is discussed on the ntpq page. After a few minutes of operation, one or another of the reachable server candidates should show a * tattletale symbol. If this doesn't happen, the intersection algorithm, which classifies the servers as truechimers or falsetickers, may be unable to find a majority of truechimers among the server population. -
    8. If all else fails, see the FAQ and/or the discussion and briefings at the NTP Project page. -
    -
    - - - - \ No newline at end of file + + + +NTP Debugging Techniques + + + +

    NTP Debugging Techniques

    +giffrom Pogo, Walt Kelly +

    We make house calls and bring our own bugs.

    +

    Last update: + 16-Jul-2014 08:38 + UTC

    +
    +

    More Help

    + +
    +

    Initial Startup

    +

    This page discusses ntpd program monitoring and debugging techniques using the ntpq - standard NTP query program, either on the local server or from a remote machine. In special circumstances the ntpdc - special NTP query program, can be useful, but its use is not covered here. The ntpq program implements the management functions specified in the NTP specification RFC-1305, Appendix A. It is used to read and write the variables defined in the NTP Version 4 specification now navigating the standards process. In addition, the program can be used to send remote configuration commands to the server.

    +

    The ntpd daemon can operate in two modes, depending on the presence of the -d command-line option. Without the option the daemon detaches from the controlling terminal and proceeds autonomously. With one or more -d options the daemon does not detach and generates special trace output useful for debugging. In general, interpretation of this output requires reference to the sources. However, a single -d does produce only mildly cryptic output and can be very useful in finding problems with configuration and network troubles.

    +

    Some problems are immediately apparent when the daemon first starts running. The most common of these are the lack of a UDP port for NTP (123) in the Unix /etc/services file (or equivalent in some systems). Note that NTP does not use TCP in any form. Also note that NTP requires port 123 for both source and destination ports. These facts should be pointed out to firewall administrators.

    +

    Other problems are apparent in the system log, which ordinarily shows the startup banner, some cryptic initialization data and the computed precision value. Event messages at startup and during regular operation are sent to the optional protostats monitor file, as described on the Event Messages and Status Words page. These and other error messages are sent to the system log, as described on the ntpd System Log Messages page. In real emergencies the daemon will sent a terminal error message to the system log and then cease operation.

    +

    The next most common problem is incorrect DNS names. Check that each DNS name used in the configuration file exists and that the address responds to the Unix ping command. The Unix traceroute or Windows tracert utility can be used to verify a partial or complete path exists. Most problems reported to the NTP newsgroup are not NTP problems, but problems with the network or firewall configuration.

    +

    Verifying Correct Operation

    +

    Unless using the iburst option, the client normally takes a few + minutes to synchronize to a server. If the client time at startup happens + to be more than 1000 s distant from NTP time, the daemon exits with a message + to the system log directing the operator to manually set the time within 1000 + s and restart. If the time is less than 1000 s but more than 128 s distant, + a step correction occurs and the daemon restarts automatically.

    +

    When started for the first time and a frequency file is not present, the + daemon enters a special mode in order to calibrate the frequency. This takes + 900 s during which the time is not disciplined. When calibration is complete, + the daemon creates the frequency file and enters normal mode to amortize whatever + residual offset remains.

    +

    The ntpq commands pe, as and rv are + normally sufficient to verify correct operation and assess nominal performance. + The pe command displays a list showing + the DNS name or IP address for each association along with selected status + and statistics variables. The first character in each line is the tally code, + which shows which associations are candidates to set the system clock and + of these which one is the system peer. The encoding is shown in the select field of the peer status word.

    +

    The as command displays a list of associations and association identifiers. Note the condition column, which reflects the tally code. The rv command displays the system variables billboard, including the system status word. The rv assocID command, where assocID is the association ID, displays the peer variables billboard, including the peer status word. Note that, except for explicit calendar dates, times are in milliseconds and frequencies are in parts-per-million (PPM).

    +

    A detailed explanation of the system, peer and clock variables in the billboards is beyond the scope of this page; however, a comprehensive explanation for each one is in the NTPv4 protocol specification. The following observations will be useful in debugging and monitoring.

    +
      +
    1. The server has successfully synchronized to its sources if the leap peer + variable has value other than 3 (11b) The client has successfully synchronized + to the server when the leap system variable has value other than + 3.
    2. +
    3. The reach peer variable is an 8-bit shift register displayed in octal format. When a valid packet is received, the rightmost bit is lit. When a packet is sent, the register is shifted left one bit with 0 replacing the rightmost bit. If the reach value is nonzero, the server is reachable; otherwise, it is unreachable. Note that, even if all servers become unreachable, the system continues to show valid time to dependent applications.
    4. +
    5. A useful indicator of miscellaneous problems is the flash peer variable, which shows the result of 13 sanity tests. It contains the flash status word bits, commonly called flashers, which displays the current errors for the association. These bits should all be zero for a valid server.
    6. +
    7. The three peer variables filtdelay, filtoffset and filtdisp show the delay, offset and jitter statistics for each of the last eight measurement rounds. These statistics and their trends are valuable performance indicators for the server, client and the network. For instance, large fluctuations in delay and jitter suggest network congestion. Missing clock filter stages suggest packet losses in the network.
    8. +
    9. The synchronization distance, defined as one-half the delay plus the dispersion, represents the maximum error statistic. The jitter represents the expected error statistic. The maximum error and expected error calculated from the peer variables represents the quality metric for the server. The maximum error and expected error calculated from the system variables represents the quality metric for the client. If the root synchronization distance for any server exceeds 1.5 s, called the select threshold, the server is considered invalid.
    10. +
    +

    Large Frequency Errors

    +

    The frequency tolerance of computer clock oscillators varies widely, sometimes above 500 PPM. While the daemon can handle frequency errors up to 500 PPM, or 43 seconds per day, values much above 100 PPM reduce the headroom, especially at the lowest poll intervals. To determine the particular oscillator frequency, start ntpd using the noselect option with the server configuration command.

    +

    Record the time of day and offset displayed by the ntpq pe command. Wait for an hour or so and record the time of day and offset. Calculate the frequency as the offset difference divided by the time difference. If the frequency is much above 100 PPM, the tickadj program might be useful to adjust the kernel clock frequency below that value. For systems that do not support this program, this might be one using a command in the system startup file.

    +

    Access Controls

    +

    Provisions are included in ntpd for access controls which deflect unwanted traffic from selected hosts or networks. The controls described on the Access Control Options include detailed packet filter operations based on source address and address mask. Normally, filtered packets are dropped without notice other than to increment tally counters. However, the server can be configured to send a "kiss-o'-death" (KoD) packet to the client either when explicitly configured or when cryptographic authentication fails for some reason. The client association is permanently disabled, the access denied bit (TEST4) is set in the flash variable and a message is sent to the system log.

    +

    The access control provisions include a limit on the packet rate from a + host or network. If an incoming packet exceeds the limit, it is dropped and + a KoD sent to the source. If this occurs after the client association has + synchronized, the association is not disabled, but a message is sent to the + system log. See the Access Control Options page + for further information.

    +

    Large Delay Variations

    +

    In some reported scenarios an access line may show low to moderate network delays during some period of the day and moderate to high delays during other periods. Often the delay on one direction of transmission dominates, which can result in large time offset errors, sometimes in the range up to a few seconds. It is not usually convenient to run ntpd throughout the day in such scenarios, since this could result in several time steps, especially if the condition persists for greater than the stepout threshold.

    +

    Specific provisions have been built into ntpd to cope with these problems. The scheme is called "huff-'n-puff and is described on the Miscellaneous Options page. An alternative approach in such scenarios is first to calibrate the local clock frequency error by running ntpd in continuous mode during the quiet interval and let it write the frequency to the ntp.drift file. Then, run ntpd -q from a cron job each day at some time in the quiet interval. In systems with the nanokernel or microkernel performance enhancements, including Solaris, Tru64, Linux and FreeBSD, the kernel continuously disciplines the frequency so that the residual correction produced by ntpd is usually less than a few milliseconds.

    +

    Cryptographic Authentication

    +

    Reliable source authentication requires the use of symmetric key or public key cryptography, as described on the Authentication Options page. In symmetric key cryptography servers and clients share session keys contained in a secret key file In public key cryptography, which requires the OpenSSL software library, the server has a private key, never shared, and a public key with unrestricted distribution. The cryptographic media required are produced by the ntp-keygen program.

    +

    Problems with symmetric key authentication are usually due to mismatched keys or improper use of the trustedkey command. A simple way to check for problems is to use the trace facility, which is enabled using the ntpd -d command line. As each packet is received a trace line is displayed which shows the authentication status in the auth field. A status of 1 indicates the packet was successful authenticated; otherwise it has failed.

    +

    A common misconception is the implication of the auth bit in the enable and disable commands. This bit does not affect authentication in any way other than to enable or disable mobilization of a new persistent association in broadcast/multicast client, manycast client or symmetric passive modes. If enabled, which is the default, these associations require authentication; if not, an association is mobilized even if not authenticated. Users are cautioned that running with authentication disabled is very dangerous, since an intruder can easily strike up an association and inject false time values.

    +

    Public key cryptography is supported in NTPv4 using the Autokey protocol, which is described in briefings on the NTP Project page linked from www.ntp.org. Development of this protocol is mature and the ntpd implementation is basically complete. Autokey version 2, which is the latest and current version, includes provisions to hike certificate trails, operate as certificate authorities and verify identity using challenge/response identification schemes. Further details of the protocol are on the Authentication Options page. Common problems with configuration and key generation are mismatched key files, broken links and missing or broken random seed file.

    +

    As in the symmetric key cryptography case, the trace facility is a good way to verify correct operation. A statistics file cryptostats records protocol transactions and error messages. The daemon requires a random seed file, public/private key file and a valid certificate file; otherwise it exits immediately with a message to the system log. As each file is loaded a trace message appears with its filestamp. There are a number of checks to insure that only consistent data are used and that the certificate is valid. When the protocol is in operation a number of checks are done to verify the server has the expected credentials and its filestamps and timestamps are consistent. Errors found are reported using NTP control and monitoring protocol traps with extended trap codes shown in the Authentication Options page.

    +

    To assist debugging every NTP extension field is displayed in the trace along with the Autokey operation code. Every extension field carrying a verified signature is identified and displayed along with filestamp and timestamp where meaningful. In all except broadcast/multicast client mode, correct operation of the protocol is confirmed by the absence of extension fields and an auth value of one. It is normal in broadcast/multicast client mode that the broadcast server use one extension field to show the host name, status word and association ID.

    +

    Debugging Checklist

    +

    If the ntpq or ntpdc programs do not show that messages are being received by the daemon or that received messages do not result in correct synchronization, verify the following:

    +
      +
    1. Verify the /etc/services file host machine is configured to accept UDP packets on the NTP port 123. NTP is specifically designed to use UDP and does not respond to TCP.
    2. +
    3. Check the system log for ntpd messages about configuration errors, name-lookup failures or initialization problems. Common system log messages are summarized on the ntpd System Log Messages page. Check to be sure that only one copy of ntpd is running.
    4. +
    5. Verify using ping or other utility that packets actually do make the round trip between the client and server. Verify using nslookup or other utility that the DNS server names do exist and resolve to valid Internet addresses.
    6. +
    7. Check that the remote NTP server is up and running. The usual evidence that it is not is a Connection refused message.
    8. +
    9. Using the ntpdc program, verify that the packets received and packets sent counters are incrementing. If the sent counter does not increment and the configuration file includes configured servers, something may be wrong in the host network or interface configuration. If this counter does increment, but the received counter does not increment, something may be wrong in the network or the server NTP daemon may not be running or the server itself may be down or not responding.
    10. +
    11. If both the sent and received counters do increment, but the reach values in the pe billboard with ntpq continues to show zero, received packets are probably being discarded for some reason. If this is the case, the cause should be evident from the flash variable as discussed above and on the ntpq page. It could be that the server has disabled access for the client address, in which case the refid field in the ntpq pe billboard will show a kiss code. See earlier on this page for a list of kiss codes and their meaning.
    12. +
    13. If the reach values in the pe billboard show the servers are alive and responding, note the tattletale symbols at the left margin, which indicate the status of each server resulting from the various grooming and mitigation algorithms. The interpretation of these symbols is discussed on the ntpq page. After a few minutes of operation, one or another of the reachable server candidates should show a * tattletale symbol. If this doesn't happen, the intersection algorithm, which classifies the servers as truechimers or falsetickers, may be unable to find a majority of truechimers among the server population.
    14. +
    15. If all else fails, see the FAQ and/or the discussion and briefings at the NTP Project page.
    16. +
    +
    + + + diff --git a/contrib/ntp/html/decode.html b/contrib/ntp/html/decode.html new file mode 100644 index 000000000..a15046f3f --- /dev/null +++ b/contrib/ntp/html/decode.html @@ -0,0 +1,692 @@ + + + + + +Event Messages and Status Words + + + +

    Event Messages and Status Words

    +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

    Caterpillar knows all the error codes, which is more than most of us do.

    +

    Last update: + 26-Jul-2015 06:26 + UTC

    +

    +
    +

    Related Links

    +

    + +

    +

    Table of Contents

    + +
    +

    Introduction

    +

    This page lists the status words, event messages and error codes used for ntpd reporting and monitoring. Status words are used to display the current status of the running program. There is one system status word and a peer status word for each association. There is a clock status word for each association that supports a reference clock. There is a flash code for each association which shows errors found in the last packet received (pkt) and during protocol processing (peer). These are commonly viewed using the ntpq program.

    +

    Significant changes in program state are reported as events. There is one + set of system events and a set of peer events for each association. In addition, + there is a set of clock events for each association that supports a reference + clock. Events are normally reported to the protostats monitoring file + and optionally to the system log. In addition, if the trap facility is configured, + events can be reported to a remote program that can page an administrator.

    +

    This page also includes a description of the error messages produced by the Autokey protocol. These messages are normally sent to the cryptostats monitoring file.

    +

    In the following tables the Event Field is the status or event code assigned and the Message Field a short string used for display and event reporting. The Description field contains a longer explanation of the status or event. Some messages include additional information useful for error diagnosis and performance assessment.

    +

    System Status Word

    +

    The system status word consists of four fields LI (0-1), Source (2-7), Count (8-11) and Event (12-15). It is reported in the first line of the rv display produced by the ntpq program.

    + + + + + + + +
    Leap
    Source
    Count
    Event
    +

    The Leap Field displays the system leap indicator bits coded as follows:

    + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageDescription
    0leap_nonenormal synchronized state
    1leap_add_secinsert second after 23:59:59 of the current day
    2leap_del_secdelete second 23:59:59 of the current day
    3leap_alarmnever synchronized
    +

    The Source Field displays the current synchronization source coded as follows:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageDescription
    0sync_unspecnot yet synchronized
    1sync_ppspulse-per-second signal (Cs, Ru, GPS, etc.)
    2sync_lf_radioVLF/LF radio (WWVB, DCF77, etc.)
    3sync_hf_radioMF/HF radio (WWV, etc.)
    4sync_uhf_radioVHF/UHF radio/satellite (GPS, Galileo, etc.)
    5sync_locallocal timecode (IRIG, LOCAL driver, etc.)
    6sync_ntpNTP
    7sync_otherother (IEEE 1588, openntp, crony, etc.)
    8sync_wristwatcheyeball and wristwatch
    9sync_telephonetelephone modem (ACTS, PTB, etc.)
    +

    The Count Field displays the number of events since the last time the code changed. Upon reaching 15, subsequent events with the same code are ignored.

    +

    The Event Field displays the most recent event message coded as follows:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageDescription
    00unspecifiedunspecified
    01freq_not_setfrequency file not available
    02freq_setfrequency set from frequency file
    03spike_detectspike detected
    04freq_modeinitial frequency training mode
    05clock_syncclock synchronized
    06restartprogram restart
    07panic_stopclock error more than 600 s
    08no_system_peerno system peer
    09leap_armedleap second armed from file or Autokey
    0aleap_disarmedleap second disarmed
    0bleap_eventleap event
    0cclock_stepclock stepped
    0dkernkernel information message
    0eTAI...leapsecond values update from file
    0fstale leapsecond valuesnew NIST leapseconds file needed
    +

    Peer Status Word

    +

    The peer status word consists of four fields: Status (0-4), Select (5-7), Count (8-11) and Code (12-15). It is reported in the first line of the rv associd display produced by the ntpq program.

    + + + + + + + +
    Status
    Select
    Count
    Code
    +

    The Status Field displays the peer status code bits in hexadecimal; each bit is an independent flag. (Note this field is 5 bits wide, and combines with the the 3-bit-wide Select Field to create the first full byte of the peer status word.) The meaning of each bit in the Status Field is listed in the following table:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageDescription
    08bcstbroadcast association
    10reachhost reachable
    20authauthentication ok
    40authenbauthentication enabled
    80configpersistent association
    +

    The Select Field displays the current selection status. (The T Field in the following table gives the corresponding tally codes used in the ntpq peers display.) The values are coded as follows:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageTDescription
    0sel_reject discarded as not valid (TEST10-TEST13)
    1sel_falsetickxdiscarded by intersection algorithm
    2sel_excess.discarded by table overflow (not used)
    3sel_outlier-discarded by the cluster algorithm
    4sel_candidate+included by the combine algorithm
    5sel_backup#backup (more than tos maxclock sources)
    6sel_sys.peer*system peer
    7sel_pps.peeroPPS peer (when the prefer peer is valid)
    +

    The Count Field displays the number of events since the last time the code changed. Upon reaching 15, subsequent events with the same code are ignored.

    +

    The Event Field displays the most recent event message coded as follows:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageDescription
    01mobilizeassociation mobilized
    02demobilizeassociation demobilized
    03unreachableserver unreachable
    04reachableserver reachable
    05restartassociation restart
    06no_replyno server found (ntpdate mode)
    07rate_exceededrate exceeded (kiss code RATE)
    08access_deniedaccess denied (kiss code DENY)
    09leap_armedleap armed from server LI code
    0asys_peerbecome system peer
    0bclock_eventsee clock status word
    0cbad_authauthentication failure
    0dpopcornpopcorn spike suppressor
    0einterleave_modeentering interleave mode
    0finterleave_errorinterleave error (recovered)
    +

    Clock Status Word

    +

    The clock status word consists of four fields: Unused (0-7), Count (8-11) and Code (12-15). It is reported in the first line of the clockvar associd display produced by the ntpq program.

    + + + + + + +
    Unused
    Count
    Code
    +

    The Count Field displays the number of events since the last lockvar command, while the Event Field displays the most recent event message coded as follows:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageDescription
    00clk_unspenominal
    01clk_noreplyno reply to poll
    02clk_badformatbad timecode format
    03clk_faulthardware or software fault
    04clk_bad_signalsignal loss
    05clk_bad_datebad date format
    06clk_bad_timebad time format
    +

    When the clock driver sets the code to a new value, a clock_alarm (11) peer event is reported.

    +

    Flash Status Word

    +

    The flash status word is displayed by the ntpq program rv command. It consists of a number of bits coded in hexadecimal as follows:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeTagMessageDescription
    0001TEST1pkt_dupduplicate packet
    0002TEST2pkt_bogusbogus packet
    0004TEST3pkt_unsyncserver not synchronized
    0008TEST4pkt_deniedaccess denied
    0010TEST5pkt_auth authentication failure
    0020TEST6pkt_stratuminvalid leap or stratum
    0040TEST7pkt_header header distance exceeded
    0080TEST8pkt_autokeyAutokey sequence error
    0100TEST9pkt_cryptoAutokey protocol error
    0200TEST10peer_stratum invalid header or stratum
    0400TEST11peer_dist distance threshold exceeded
    0800TEST12peer_loop synchronization loop
    1000TEST13peer_unreach unreachable or nonselect
    +

    Kiss Codes

    +

    Kiss codes are used in kiss-o'-death (KoD) packets, billboard displays and log messages. They consist of a string of four zero-padded ASCII charactes. In practice they are informal and tend to change with time and implementation. Some of these codes can appear in the reference identifier field in ntpq billboards. Following is the current list:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeDescription
    ACSTmanycast server
    AUTHauthentication error
    AUTOAutokey sequence error
    BCSTbroadcast server
    CRYPTAutokey protocol error
    DENYaccess denied by server
    INITassociation initialized
    MCSTmulticast server
    RATErate exceeded
    TIMEassociation timeout
    STEPstep time change
    +

    Crypto Messages

    +

    These messages are sent to the cryptostats file when an error is detected in the Autokey protocol.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    CodeMessageDescription
    01bad_formatbad extension field format or length
    02bad_timestampbad timestamp
    03bad_filestampbad filestamp
    04bad_public_keybad or missing public key
    05bad_digestunsupported digest type
    06bad_identityunsupported identity type
    07bad_siglengthbad signature length
    08bad signatureextension field signature not verified
    09cert_not_verifiedcertificate signature not verified
    0acert_expiredhost certificate expired
    0bbad_cookiebad or missing cookie
    0cbad_leapsecondsbad or missing leapseconds values
    0dcert_missingbad or missing certificate
    0ebad_group_keybad or missing group key
    0fproto_errorprotocol error
    +
    + + + diff --git a/contrib/ntp/html/discipline.html b/contrib/ntp/html/discipline.html new file mode 100644 index 000000000..53b60ccf8 --- /dev/null +++ b/contrib/ntp/html/discipline.html @@ -0,0 +1,49 @@ + + + + + +Clock Discipline Algorithm + + + +

    Clock Discipline Algorithm

    +

    Last update: + 10-Mar-2014 05:03 + UTC

    +

    Table of Contents

    + +
    +

    General Overview

    +

    At the heart of the NTP specification and reference implementation is the clock discipline algorithm, which is best described as an adaptive parameter, hybrid phase/frequency-lock feedback loop. It is an intricately crafted algorithm that automatically adapts for optimum performance while minimizing network overhead. Operation is in two modes, phase-lock loop (PLL), which is used at poll intervals below the Allan intercept, by default 2048 s, and frequency-lock loop (FLL), which is used above that.

    +
    gif +

    Figure 1. Clock Discipline Algorithm

    +
    +

    Clock Discipline Operations

    +

    A block diagram of the clock discipline is shown in Figure 1. The timestamp of a reference clock or remote server is compared with the timestamp of the system clock, represented as a variable frequency oscillator (VFO), to produce a raw offset sample Vd. Offset samples are processed by the clock filter to produce a filtered update Vs. The loop filter implements a type-2 proportional-integrator controller (PIC). The PIC can minimize errors in both time and frequency using predictors x and y, respectively. The clock adjust process samples these predictors once each second for the daemon discipline or once each tick interrupt for the kernel discipline to produce the system clock update Vc.

    +

    In PLL mode the frequency predictor is an integral of the offset over past updates, while the phase predictor is the offset amortized over time in order to avoid setting the clock backward. In FLL mode the phase predictor is not used, while the frequency predictor is similar to the NIST lockclock algorithm. In this algorithm, the frequency predictor is computed as a fraction of the current offset divided by the time since the last update in order to minimize the offset at the next update.

    +

    The discipline response in PLL mode is determined by the time constant, which results in a "stiffness" depending on the jitter of the available sources and the wander of the system clock oscillator. The scaled time constant is also used as the poll interval described on the Poll Program page. However, in NTP symmetric mode, each peer manages its own poll interval and the two might not be the same. In such cases either peer uses the minimum of its own poll interval and that of the other peer, which is included in the NTP packet header.

    +

    Loop Dynamics

    +

    It is necessary to verify that the clock discipline algorithm is stable and satisfies the Nyquist criterion, which requires that the sampling rate be at least twice the bandwidth. In this case the bandwidth can be approximated by the reciprocal of the time constant. In the NTP specification and reference implementation, time constants and poll intervals are expressed as exponents of 2. By construction, the time constant exponent is five times the poll interval exponent. Thus, the default poll exponent of 6 corresponds to a poll interval of 64 s and a time constant of 2048 s. A change in the poll interval changes the time constant by a corresponding amount.. The Nyquist criterion requires the sample interval to be not more than half the time constant or 1024 s. The clock filter guarantees at least one sample in eight poll intervals, so the sample interval is not more than 512 s. This would be described as oversampling by a factor of two. Finally, the PLL parameters have been chosen for a damping factor of 2, which results in a much faster risetime than with critical damping, but results in modest overshoot of 6 percent.

    +

    It is important to understand how the dynamics of the PLL are affected by the time constant and poll interval. At the default poll interval of 64 s and a step offset change of 100 ms, the time response crosses zero in about 50 min and overshoots about 6 ms, as per design. Ordinarily, a step correction would causes a temporary frequency surge of about 5 PPM, which along with the overshoot slowly dissipates over a few hours.

    +

    However, the clock state machine used with the discipline algorithm avoids this transient at startup. It does this using a previously saved frequency file, if present, or by measuring the oscillator frequency, if not. It then quickly amortizes the residual offset at startup without affecting the oscillator frequency. In this way the offset error is less than 0.5 ms within 5 min, if the file is present, and within 10 min if not. See the Clock State Machine page for further details.

    +

    Since the PLL is linear, the response with different offset step amplitudes and poll intervals has the same characteristic shape, but scaled differently in amplitude and time. The response scales exactly with step amplitude, so that the response to a 10-ms step has the same shape as at 64 s, but with amplitude compressed by one-tenth. The response scales exactly with poll interval, so that response at a poll interval of 8 s has the same shape as at 64 s, but with time compressed by one-eighth.

    +

    The optimum time constant, and thus the poll interval, depends on the network time jitter and the oscillator frequency wander. Errors due to jitter decrease as the time constant increases, while errors due to wander decrease as the time constant decreases. For typical Internet paths, the two error characteristics intersect at a point called the Allan intercept, which represents the optimum time constant. With a compromise Allan intercept of 2048 s, the optimum poll interval is about 64 s, which corresponds to a compromise poll exponent of 6. For fast LANs with modern computers, the Allan intercept is somewhat lower at around 512 s, so a compromise poll exponent of 4 (16 s) is appropriate. An intricate, heuristic algorithm is used to manage the actual poll interval within a specified range. Details are on the Poll Program page.

    +

    In the NTPv4 specification and reference implementation a state machine is used to manage the system clock under exceptional conditions, as when the daemon is first started or when encountering severe network congestion. In extreme cases not likely to be encountered in normal operation, the system time can be stepped forward or backward more than 128 ms. Further details are on the Clock State Machine page.

    +

    Clock Initialization and Management

    +

    If left running continuously, an NTP client on a fast LAN in a home or office environment can maintain synchronization nominally within one millisecond. When the ambient temperature variations are less than a degree Celsius, the clock oscillator frequency is disciplined to within one part per million (PPM), even when the clock oscillator native frequency offset is 100 PPM or more.

    +

    For laptops and portable devices when the power is turned off, the battery backup clock offset error can increase as much as one second per day. When power is restored after several hours or days, the clock offset and oscillator frequency errors must be resolved by the clock discipline algorithm, but this can take several hours without specific provisions.

    +

    The provisions described in this section insure that, in all but pathological situations, the startup transient is suppressed to within nominal levels in no more than five minutes after a warm start or ten minutes after a cold start. Following is a summary of these provisions. A detailed discussion of these provisions is on the Clock State Machine page.

    +

    The reference implementation measures the clock oscillator frequency and updates a frequency file at intervals of one hour or more, depending on the measured frequency wander. This design is intended to minimize write cycles in NVRAM that might be used in a laptop or portable device. In a warm start, the frequency is initialized from this file, which avoids a possibly lengthy convergence time. In a cold start when no frequency file is available, the reference implementation first measures the oscillator frequency over a five-min interval. This generally results in a residual frequency error less than 1 PPM. The measurement interval can be changed using the stepout option of the tinker command.

    +

    In order to reduce the clock offset error at restart, the reference implementation mext disables oscillator frequency discipline and enables clock offset discipline with a small time constant. This is designed to quickly reduce the clock offset error without causing a frequency surge. This configuration is continued for an interval of five-min, after which the clock offset error is usually no more than a millisecond. The measurement interval can be changed using the stepout option of the tinker command.

    +

    Another concern at restart is the time necessary for the select and cluster algorithms to refine and validate the initial clock offset estimate. Normally, this takes several updates before setting the system clock. As the default minimum poll interval in most configurations is about one minute, it can take several minutes before setting the system clock. The iburst option of the server command changes the behavior at restart and is recommended for client/server configurations. When this option is enabled, the client sends a volley of six requests at intervals of two seconds. This usually insures a reliable estimate is available in about ten seconds before setting the clock. Once this initial volley is complete, the procedures described above are executed.

    +

    As a result of the above considerations, when a backup source, such as the local clock driver, ACTS modem driver or orphan mode is included in the system configuration, it may happen that one or more of them are selectable before one or more of the regular sources are selectable. When backup sources are included in the configuration, the reference implementation waits an interval of several minutes without regular sources before switching to backup sources. This is generally enough to avoid startup transients due to premature switching to backup sources. The interval can be changed using the orphanwait option of the tos command.

    +
    + + + diff --git a/contrib/ntp/html/discover.html b/contrib/ntp/html/discover.html new file mode 100644 index 000000000..b35359c3d --- /dev/null +++ b/contrib/ntp/html/discover.html @@ -0,0 +1,75 @@ + + + + + +Automatic Server Discoveryschemes + + + +

    Automatic Server Discovery Schemes

    +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

    Make sure who your friends are.

    +

    Last update: + 10-Mar-2014 05:04 + UTC

    +
    +

    Related Links

    + + +

    Table of Contents

    + +
    +

    Introduction

    +

    This page describes the automatic server discovery schemes provided in NTPv4. There are three automatic server discovery schemes: broadcast/multicast, many cast, and server pool, which are described on this page. The broadcast/multicast and many cast schemes utilize the ubiquitous broadcast or one-to-many paradigm native to IPv4 and IPv6. The server pool scheme uses DNS to resolve addresses of multiple volunteer servers scattered throughout the world.

    +

    All three schemes work in much the same way and might be described as grab-n'-prune. Through one means or another they grab a number of associations either directly or indirectly from the configuration file, order them from best to worst according to the NTP mitigation algorithms, and prune the surplus associations.

    +

    Association Management

    +

    All schemes use an iterated process to discover new preemptable client associations as long as the total number of client associations is less than the maxclock option of the tos command. The maxclock default is 10, but it should be changed in typical configuration to some lower number, usually two greater than the minclock option of the same command.

    +

    All schemes use a stratum filter to select just those servers with stratum considered useful. This can avoid large numbers of clients ganging up on a small number of low-stratum servers and avoid servers below or above specified stratum levels. By default, servers of all strata are acceptable; however, the tos command can be used to restrict the acceptable range from the floor option, inclusive, to the ceiling option, exclusive. Potential servers operating at the same stratum as the client will be avoided, unless the cohort option is present. Additional filters can be supplied using the methods described on the Authentication Support page.

    +

    The pruning process uses a set of unreach counters, one for each association created by the configuration or discovery processes. At each poll interval, the counter is increased by one. If an acceptable packet arrives for a persistent (configured) or ephemeral (broadcast/multicast) association, the counter is set to zero. If an acceptable packet arrives for a preemptable (manycast, pool) association and survives the selection and clustering algorithms, the counter is set to zero. If the the counter reaches an arbitrary threshold of 10, the association becomes a candidate for pruning.

    +

    The pruning algorithm is very simple. If an ephemeral or preemptable association becomes a candidate for pruning, it is immediately demobilized. If a persistent association becomes a candidate for pruning, it is not demobilized, but its poll interval is set at the maximum. The pruning algorithm design avoids needless discovery/prune cycles for associations that wander in and out of the survivor list, but otherwise have similar characteristics.

    +

    Following is a summary of each scheme. Note that reference to option applies to the commands described on the Configuration Options page. See that page for applicability and defaults.

    +

    Broadcast/Multicast Scheme

    +

    A broadcast server generates messages continuously at intervals by default 64 s and time-to-live by default 127. These defaults can be overridden by the minpoll and ttl options, respectively. Not all kernels support the ttl option. A broadcast client responds to the first message received by waiting a randomized interval to avoid implosion at the server. It then polls the server in client/server mode using the iburst option in order to quickly authenticate the server, calibrate the propagation delay and set the client clock. This normally results in a volley of six client/server exchanges at 2-s intervals during which both the synchronization and cryptographic protocols run concurrently.

    +

    Following the volley, the server continues in listen-only mode and sends no further messages. If for some reason the broadcast server does not respond to these messages, the client will cease transmission and continue in listen-only mode with a default propagation delay. The volley can be avoided by using the broadcastdelay command with nonzero argument.

    +

    A server is configured in broadcast mode using the broadcast command and specifying the broadcast address of a local interface. If two or more local interfaces are installed with different broadcast addresses, a broadcast command is needed for each address. This provides a way to limit exposure in a firewall, for example. A broadcast client is configured using the broadcastclient command.

    +

    NTP multicast mode can be used to extend the scope using IPv4 multicast or IPv6 broadcast with defined span. The IANA has assigned IPv4 multicast address 224.0.1.1 and IPv6 address FF05::101 (site local) to NTP, but these addresses should be used only where the multicast span can be reliably constrained to protect neighbor networks. In general, administratively scoped IPv4 group addresses should be used, as described in RFC-2365, or GLOP group addresses, as described in RFC-2770.

    +

    A multicast server is configured using the broadcast command, but specifying a multicast address instead of a broadcast address. A multicast client is configured using the multicastclient command specifying a list of one or more multicast addresses. Note that there is a subtle distinction between the IPv4 and IPv6 address families. The IPv4 broadcast or mulitcast mode is determined by the IPv4 class. For IPv6 the same distinction can be made using the link-local prefix FF02 for each interface and site-local prefix FF05 for all interfaces.

    +

    It is possible and frequently useful to configure a host as both broadcast client and broadcast server. A number of hosts configured this way and sharing a common broadcast address will automatically organize themselves in an optimum configuration based on stratum and synchronization distance.

    +

    Since an intruder can impersonate a broadcast server and inject false time values, broadcast mode should always be cryptographically authenticated. By default, a broadcast association will not be mobilized unless cryptographically authenticated. If necessary, the auth option of the disable command will disable this feature. The feature can be selectively enabled using the notrust option of the restrict command.

    +

    With symmetric key cryptography each broadcast server can use the same or different keys. In one scenario on a broadcast LAN, a set of broadcast clients and servers share the same key along with another set that share a different key. Only the clients with matching key will respond to a server broadcast. Further information is on the Authentication Support page.

    +

    Public key cryptography can be used with some restrictions. If multiple servers belonging to different secure groups share the same broadcast LAN, the clients on that LAN must have the client keys for all of them. This scenario is illustrated in the example on the Autokey Public Key Authentication page.

    +

    Manycast Scheme

    +

    Manycast is an automatic server discovery and configuration paradigm new to NTPv4. It is intended as a means for a client to troll the nearby network neighborhood to find cooperating servers, validate them using cryptographic means and evaluate their time values with respect to other servers that might be lurking in the vicinity. It uses the grab-n'-drop paradigm with the additional feature that active means are used to grab additional servers should the number of associations fall below the maxclock option of the tos command.

    +

    The manycast paradigm is not the anycast paradigm described in RFC-1546, which is designed to find a single server from a clique of servers providing the same service. The manycast paradigm is designed to find a plurality of redundant servers satisfying defined optimality criteria.

    +

    A manycast client is configured using the manycastclient configuration command, which is similar to the server configuration command. It sends ordinary client mode messages, but with a broadcast address rather than a unicast address and sends only if less than maxclock associations remain and then only at the minimum feasible rate and minimum feasible time-to-live (TTL) hops. The polling strategy is designed to reduce as much as possible the volume of broadcast messages and the effects of implosion due to near-simultaneous arrival of manycast server messages. There can be as many manycast client associations as different addresses, each one serving as a template for future unicast client/server associations.

    +

    A manycast server is configured using the manycastserver command, which listens on the specified broadcast address for manycast client messages. If a manycast server is in scope of the current TTL and is itself synchronized to a valid source and operating at a stratum level equal to or lower than the manycast client, it replies with an ordinary unicast server message.

    +

    The manycast client receiving this message mobilizes a preemptable client association according to the matching manycast client template. This requires the server to be cryptographically authenticated and the server stratum to be less than or equal to the client stratum.

    +

    It is possible and frequently useful to configure a host as both manycast client and manycast server. A number of hosts configured this way and sharing a common multicast group address will automatically organize themselves in an optimum configuration based on stratum and synchronization distance.

    +

    The use of cryptograpic authentication is always a good idea in any server discovery scheme. Both symmetric key and public key cryptography can be used in the same scenarios as described above for the broadast/multicast scheme.

    +

    Server Pool Scheme

    +

    The idea of targeting servers on a random basis to distribute and balance the load is not a new one; however, the NTP pool scheme puts this on steroids. At present, several thousand operators around the globe have volunteered their servers for public access. In general, NTP is a lightweight service and servers used for other purposes don't mind an additional small load. The trick is to randomize over the population and minimize the load on any one server while retaining the advantages of multiple servers using the NTP mitigation algorithms.

    +

    To support this service, custom DNS software is used by pool.ntp.org and its subdomains + to discover a random selection of participating servers in response to a DNS query. + The client receiving this list mobilizes some or all of them, similar to the + manycast discovery scheme, and prunes the excess. Unlike manycastclient, + cryptographic authentication is not required. The pool scheme solicits a single + server at a time, compared to manycastclient which solicits all servers + within a multicast TTL range simultaneously. Otherwise, the pool server discovery + scheme operates as manycast does.

    +

    The pool scheme is configured using one or more pool commands with DNS names + indicating the pool from which to draw. The pool command can be used more + than once; duplicate servers are detected and discarded. In principle, it is + possible to use a configuration file containing a single line pool + pool.ntp.org. The NTP Pool + Project offers instructions on using the pool with the server command, which is suboptimal but works with older versions of ntpd predating the pool command. With recent ntpd, consider replacing the + multiple server commands in their example with a single pool command.

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver1.html b/contrib/ntp/html/drivers/driver1.html index afd85d211..4518b72d3 100644 --- a/contrib/ntp/html/drivers/driver1.html +++ b/contrib/ntp/html/drivers/driver1.html @@ -1,65 +1,50 @@ - - - - - - Undisciplined Local Clock - - - - -

    Undisciplined Local Clock

    -
    -

    Synopsis

    -

    Address: 127.127.1.u
    - Reference ID: LCL
    - Driver ID: LOCAL

    -

    Description

    -

    This driver is intended for use in an isolated network where no external source of synchronization such as a radio clock or modem is available. It allows a designated time server to act as a primary server to provide synchronization to other clients on the network. Pick a machine that has a good clock oscillator (Digital machines are good, Sun machines are not) and configure it with this driver. Set the clock using the best means available, like eyeball-and-wristwatch. Then, point all the other machines at this one or use broadcast (not multicast) mode to distribute time.

    -

    Another application for this driver is if a particular server clock is to be used as the clock of last resort when all other normal synchronization sources have gone away. This is especially useful if that server has an ovenized oscillator. For this you would configure this driver at a stratum greater than any other likely sources of time (say 3 or 4) to prevent the server taking over when legitimate sources are still available.

    -

    A third application for this driver is when an external discipline source is available, such as the NIST lockclock program, which synchronizes the local clock via a telephone modem and the NIST Automated Computer Time Service (ACTS), or the Digital Time Synchronization Service (DTSS), which runs on DCE machines. In this case the stratum should be set at zero, indicating a bona fide stratum-1 source. In the case of DTSS, the local clock can have a rather large jitter, depending on the interval between corrections and the intrinsic frequency error of the clock oscillator. In extreme cases, this can cause clients to exceed the 128-ms slew window and drop off the NTP subnet.

    -

    In the case where a NTP time server is synchronized to some device or protocol that is not external to the NTP daemon itself, some means should be provided to pass such things as error and health values to the NTP daemon for dissemination to its clients. If this is not done, there is a very real danger that the device or protocol could fail and with no means to tell NTP clients of the mishap. When ordinary Unix system calls like adjtime() are used to discipline the kernel clock, there is no obvious way this can be done without modifying the code for each case. However, when a modified kernel with the ntp_adjtime() system call  is available, that routine can be used for the same purpose as the adjtime() routine and in addition provided with the estimated error, maximum error, and leap-indicator values. This is the preferred way to synchronize the kernel clock and pass information to the NTP clients.

    -

    In the default mode the behavior of the clock selection algorithm is modified when this driver is in use. The algorithm is designed so that this driver will never be selected unless no other discipline source is available. This can be overridden with the prefer keyword of the server configuration command, in which case only this driver will be selected for synchronization and all other discipline sources will be ignored. This behavior is intended for use when an external discipline source controls the system clock. See the Mitigation Rules and the prefer Keyword page for a detailed description of the exact behavior.

    -

    The stratum for this driver is set at 5 by default, but can be changed by the fudge configuration command and/or the ntpdc utility. The reference ID is LCL by default, but can be changed using the same mechanisms. *NEVER* configure this driver to operate at a stratum which might possibly disrupt a client with access to a bona fide primary server, unless the local clock oscillator is reliably disciplined by another source. *NEVER NEVER* configure a server which might devolve to an undisciplined local clock to use multicast mode.

    -

    This driver provides a mechanism to trim the local clock in both time and frequency, as well as a way to manipulate the leap bits. The fudge time1 parameter adjusts the time (in seconds) and the fudge time2 parameter adjusts the frequency (in parts per million). Both parameters are additive and operate only once; that is, each command (as from ntpdc) adds signed increments in time or frequency to the nominal local clock time and frequency.

    -

    Operation with an External Reference Source

    -

    There are special provisions for this driver to operate in conjunction with an external reference source, such as the LOCKCLOCK scheme used by the NIST time servers. In such schemes the system clock is disciplined by a source external to NTP, in the LOCKCLOCK case an ACTS telephone modem. To support LOCKCLOCK the NTP distribution should be built with the --enable-nist parameter in the configuration phase of the build procedure. This changes the system behavior as follows:

    -
      -
    1. The system clock is not disciplined in any way other than to call the ntp_adjtime() system call to obtain the kernel leap code, which becomes the driver leap code and. If the kernel leap code is 11 (not synchronized), the driver stratum is infinity; otherwise the stratum is set by the stratum subcommand on the fudge command applying to the driver. -
    2. The NTP algorithms operate in the normal fashion with this driver and possibly other drivers and servers; however, the local clock driver as the prefer peer will always be selected, even if declared falseticker by the selection algorithm or fails to survive the clustering algorithm. -
    3. If the driver leap code is 11, the system leap code is 11, system stratum infinity and system reference identifier DOWN. This provides a definitive status condition to dependent clients. -
    -

    The local clock driver should be configured something like this:

    -

    server 127.127.1.1 prefer

    -

    fudge 127.127.1.1 stratum 0 refid NIST

    -

    The prefer keyword forces the driver to discipline the clock, even if other servers are configured and running correctly. This is convenient when a number of servers watch each other for monitoring and statistics gathering. In particular, the peerstats data and sysstats data can be collected at each server, aggregated for daily or weekly reports and sent by electric mail to a monitoring site. In addition, the full suite of cryptographic authentication algorithms is avialable to other servers and dependent clients.

    -

    Monitor Data

    -

    No filegen clockstats monitor data are produced by this driver.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Specifies the frequency offset calibration factor, in parts per million, with default 0.0. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 3. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default LCL. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file + + + +Undisciplined Local Clock + + + +

    Undisciplined Local Clock

    +

    Author: David L. Mills (mills@udel.edu)
    +Last update: + 9-May-2014 08:34 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.1.u
    + Reference ID: LOCL
    + Driver ID: LOCAL

    +

    Description

    +

    Note: We recommend against using this driver. A much more flexible replacement is described on the Orphan Mode page.

    +

    This driver was intended for use in an isolated network where no external source of synchronization such as a radio clock or modem is available. It allows a designated time server to act as a primary server to provide synchronization to other clients on the network. Pick a machine that has a good clock oscillator and configure it with this driver. Set the clock using the best means available, like eyeball-and-wristwatch. Then, point all the other machines at this one or use broadcast mode to distribute time.

    +

    Another application for this driver is if a particular server clock is to be used as the clock of last resort when all other normal synchronization sources have gone away. This is especially useful if that server has an ovenized oscillator. For this you would usually, but not necessarily, configure this driver at a stratum greater than any other likely sources of time, such as the default 5 for this driver, to prevent this driver taking over when legitimate sources elsewhere in the network are available. To further protect the Internet infrastructure from accidental or malicious exposure to this driver, the driver is disabled if another source is available and operating.

    +

    Monitor Data

    +

    No filegen clockstats monitor data are produced by this driver.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Specifies the frequency offset calibration factor, in parts per million, with default 0.0.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 5.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default LOCL.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Not used by this driver.
    +
    flag3 0 | 1
    +
    Not used by this driver.
    +
    flag4 0 | 1
    +
    Not used by this driver.
    +
    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver10.html b/contrib/ntp/html/drivers/driver10.html index 97b0495d5..1dd56c102 100644 --- a/contrib/ntp/html/drivers/driver10.html +++ b/contrib/ntp/html/drivers/driver10.html @@ -1,53 +1,53 @@ - - - - - - Austron 2200A/2201A GPS Receivers - - - - -

    Austron 2200A/2201A GPS Receivers

    -
    -

    Synopsis

    -

    Address: 127.127.10.u
    - Reference ID: GPS
    - Driver ID: GPS_AS2201
    - Serial Port: /dev/gpsu; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    Description

    -

    This driver supports the Austron 2200A/2201A GPS/LORAN Synchronized Clock and Timing Receiver connected via a serial port. It supports several special features of the clock, including the Input Buffer Module, Output Buffer Module, IRIG-B Interface Module and LORAN Assist Module. It requires the RS232 Buffered Serial Interface module for communication with the driver. For operation with multiple computers, it requires the ppsclock streams module described in the Line Disciplines and Streams Modules page. The streams module requires a gadget box and 1-PPS level converter, such as described in the Pulse-per-second (PPS) Signal Interfacing page.

    -

    For use with a single computer, the receiver can be connected directly to the receiver. For use with multiple computers, one of them is connected directly to the receiver and generates the polling messages. The other computers just listen to the receiver output directly or through a buffer amplifier. For computers that just listen, fudge flag2 must be set and the ppsclock streams module configured on each of them.

    -

    This receiver is capable of a comprehensive and large volume of statistics and operational data. The specific data collection commands and attributes are embedded in the driver source code; however, the collection process can be enabled or disabled using the flag4 flag. If set, collection is enabled; if not, which is the default, it is disabled. A comprehensive suite of data reduction and summary scripts is in the ./scripts/stats directory

    - of the ntp3 distribution. -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Set for computers that listen-only. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file + + + +Austron 2200A/2201A GPS Receivers + + + +

    Austron 2200A/2201A GPS Receivers

    +

    Author: David L. Mills (mills@udel.edu)
    + Last update: + 11-Sep-2010 05:56 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.10.u
    + Reference ID: GPS
    + Driver ID: GPS_AS2201
    + Serial Port: /dev/gpsu; 9600 baud, 8-bits, no parity
    + Features: tty_clk

    +

    Description

    +

    This driver supports the Austron 2200A/2201A GPS/LORAN Synchronized Clock and Timing Receiver connected via a serial port. It supports several special features of the clock, including the Input Buffer Module, Output Buffer Module, IRIG-B Interface Module and LORAN Assist Module. It requires the RS232 Buffered Serial Interface module for communication with the driver.

    +

    For use with a single computer, the receiver can be connected directly to the receiver. For use with multiple computers, one of them is connected directly to the receiver and generates the polling messages. The other computers just listen to the receiver output directly or through a buffer amplifier. For computers that just listen, fudge flag2 must be set and the ppsclock streams module configured on each of them.

    +

    This receiver is capable of a comprehensive and large volume of statistics and operational data. The specific data collection commands and attributes are embedded in the driver source code; however, the collection process can be enabled or disabled using the flag4 flag. If set, collection is enabled; if not, which is the default, it is disabled. A comprehensive suite of data reduction and summary scripts is in the ./scripts/stats directory

    +of the ntp3 distribution. +

    Monitor Data

    +

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Set for computers that listen-only.
    +
    flag3 0 | 1
    +
    Not used by this driver.
    +
    flag4 0 | 1
    +
    Enable verbose clockstats recording if set.
    +
    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver11.html b/contrib/ntp/html/drivers/driver11.html index b36f7f353..f3c9a81e8 100644 --- a/contrib/ntp/html/drivers/driver11.html +++ b/contrib/ntp/html/drivers/driver11.html @@ -1,31 +1,30 @@ - - - - - - Arbiter 1088A/B GPS Receiver - - - - -

    Arbiter 1088A/B GPS Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.11.u
    - Reference ID: GPS
    - Driver ID: GPS_ARBITER
    - Serial Port: /dev/gpsu; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    -

    Description

    -

    -

    This driver supports the Arbiter 1088A/B Satellite Controlled Clock. The claimed accuracy of this clock is 100 ns relative to the PPS output when receiving four or more satellites.

    -

    The receiver should be configured before starting the NTP daemon, in order to establish reliable position and operating conditions. It does not initiate surveying or hold mode. For use with NTP, the daylight savings time feature should be disables (D0 command) and the broadcast mode set to operate in UTC (BU command).

    -

    The timecode format supported by this driver is selected by the poll sequence B5, which initiates a line in the following format to be repeated once per second until turned off by the B0 command.

    -

    Format B5 (24 ASCII printing characters):

    -
    <cr><lf>i yy ddd hh:mm:ss.000bbb
    +
    +
    +
    +Arbiter 1088A/B GPS Receiver
    +
    +
    +
    +

    Arbiter 1088A/B GPS Receiver

    +

    Author: David L. Mills (mills@udel.edu)
    + Last update: + 11-Sep-2010 05:56 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.11.u
    + Reference ID: GPS
    + Driver ID: GPS_ARBITER
    + Serial Port: /dev/gpsu; 9600 baud, 8-bits, no parity
    + Features: tty_clk

    +

    Description

    +

    This driver supports the Arbiter 1088A/B Satellite Controlled Clock. The claimed accuracy of this clock is 100 ns relative to the PPS output when receiving four or more satellites.

    +

    The receiver should be configured before starting the NTP daemon, in order to establish reliable position and operating conditions. It does not initiate surveying or hold mode. For use with NTP, the daylight savings time feature should be disables (D0 command) and the broadcast mode set to operate in UTC (BU command).

    +

    The timecode format supported by this driver is selected by the poll sequence B5, which initiates a line in the following format to be repeated once per second until turned off by the B0 command.

    +

    Format B5 (24 ASCII printing characters):

    +
    <cr><lf>i yy ddd hh:mm:ss.000bbb
     
     on-time = <cr>
     i = synchronization flag (' ' = locked, '?' = unlocked)
    @@ -34,10 +33,10 @@ ddd = day of year
     hh:mm:ss = hours, minutes, seconds
     .000 = fraction of second (not used)
     bbb = tailing spaces for fill
    -

    The alarm condition is indicated by a '?' at i, which indicates the receiver is not synchronized. In normal operation, a line consisting of the timecode followed by the time quality character (TQ) followed by the receiver status string (SR) is written to the clockstats file.

    -

    The time quality character is encoded in IEEE P1344 standard:

    -

    Format TQ (IEEE P1344 estimated worst-case time quality)

    -
    0       clock locked, maximum accuracy
    +

    The alarm condition is indicated by a '?' at i, which indicates the receiver is not synchronized. In normal operation, a line consisting of the timecode followed by the time quality character (TQ) followed by the receiver status string (SR) is written to the clockstats file.

    +

    The time quality character is encoded in IEEE P1344 standard:

    +

    Format TQ (IEEE P1344 estimated worst-case time quality)

    +
    0       clock locked, maximum accuracy
     F       clock failure, time not reliable
     4       clock unlocked, accuracy < 1 us
     5       clock unlocked, accuracy < 10 us
    @@ -47,41 +46,40 @@ F       clock failure, time not reliable
     9       clock unlocked, accuracy < 100 ms
     A       clock unlocked, accuracy < 1 s
     B       clock unlocked, accuracy < 10 s
    -

    The status string is encoded as follows:

    -

    Format SR (25 ASCII printing characters)

    -
    V=vv S=ss T=t P=pdop E=ee
    +

    The status string is encoded as follows:

    +

    Format SR (25 ASCII printing characters)

    +
    V=vv S=ss T=t P=pdop E=ee
     
     vv = satellites visible
     ss = relative signal strength
     t = satellites tracked
     pdop = position dilution of precision (meters)
     ee = hardware errors
    -

    A three-stage median filter is used to reduce jitter and provide a dispersion measure. The driver makes no attempt to correct for the intrinsic jitter of the radio itself.

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, an additional line containing the latitude, longitude, elevation and optional deviation data is written to the clockstats file. The deviation data operates with an external pulse-per-second (PPS) input, such as a cesium oscillator or another radio clock. The PPS input should be connected to the B event channel and the radio initialized for deviation data on that channel. The deviation data consists of the mean offset and standard deviation of the external PPS signal relative the GPS signal, both in microseconds over the last 16 seconds.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file +

    A three-stage median filter is used to reduce jitter and provide a dispersion measure. The driver makes no attempt to correct for the intrinsic jitter of the radio itself.

    +

    Monitor Data

    +

    When enabled by the flag4 fudge flag, an additional line containing the latitude, longitude, elevation and optional deviation data is written to the clockstats file. The deviation data operates with an external pulse-per-second (PPS) input, such as a cesium oscillator or another radio clock. The PPS input should be connected to the B event channel and the radio initialized for deviation data on that channel. The deviation data consists of the mean offset and standard deviation of the external PPS signal relative the GPS signal, both in microseconds over the last 16 seconds.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Not used by this driver.
    +
    flag3 0 | 1
    +
    Not used by this driver.
    +
    flag4 0 | 1
    +
    Enable verbose clockstats recording if set.
    +
    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver12.html b/contrib/ntp/html/drivers/driver12.html index 6d0b38ab7..3b6fc1565 100644 --- a/contrib/ntp/html/drivers/driver12.html +++ b/contrib/ntp/html/drivers/driver12.html @@ -1,49 +1,49 @@ - - - - - - KSI/Odetics TPRO/S IRIG Interface - - - - -

    KSI/Odetics TPRO/S IRIG Interface

    -
    -

    Synopsis

    -

    Address: 127.127.12.u
    - Reference ID: IRIG
    - Driver ID: IRIG_TPRO
    - TPRO Device: /dev/tprou
    - Requires: KSI/Odetics device driver, /usr/include/sys/tpro.h header file

    -

    Description

    -

    This driver supports the KSI/Odetics TPRO and TPRO-SAT IRIG-B Decoder, which is a module connected directly to the SBus of a Sun workstation. The module works with the IRIG-B signal generated by several radio clocks, including those made by Arbiter, Austron, Odetics, Spectracom and TrueTime, among others, although it is generally an add- on option. In the case of the TPRO-SAT, the module is an integral part of a GPS receiver, which serves as the primary timing source.

    -

    Using the TPRO interface as a NTP reference clock provides precision time only to ntpd and its clients. With suitable kernel modifications, it is possible to use the TPRO as the CPU system clock, avoiding errors introduced by the CPU clock oscillator wander. See the A Kernel Model for Precision Timekeeping page for further details.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default IRIG. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file + + + +KSI/Odetics TPRO/S IRIG Interface + + + +

    KSI/Odetics TPRO/S IRIG Interface

    +

    Author: David L. Mills (mills@udel.edu)
    + Last update: + 11-Sep-2010 05:56 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.12.u
    + Reference ID: IRIG
    + Driver ID: IRIG_TPRO
    + TPRO Device: /dev/tprou
    + Requires: KSI/Odetics device driver, /usr/include/sys/tpro.h header file

    +

    Description

    +

    This driver supports the KSI/Odetics TPRO and TPRO-SAT IRIG-B Decoder, which is a module connected directly to the SBus of a Sun workstation. The module works with the IRIG-B signal generated by several radio clocks, including those made by Arbiter, Austron, Odetics, Spectracom and TrueTime, among others, although it is generally an add- on option. In the case of the TPRO-SAT, the module is an integral part of a GPS receiver, which serves as the primary timing source.

    +

    Using the TPRO interface as a NTP reference clock provides precision time only to ntpd and its clients. With suitable kernel modifications, it is possible to use the TPRO as the CPU system clock, avoiding errors introduced by the CPU clock oscillator wander. See the A Kernel Model for Precision Timekeeping page for further details.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default IRIG.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Not used by this driver.
    +
    flag3 0 | 1
    +
    Not used by this driver.
    +
    flag4 0 | 1
    +
    Not used by this driver.
    +
    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver16.html b/contrib/ntp/html/drivers/driver16.html index 95308ba16..74a3bd640 100644 --- a/contrib/ntp/html/drivers/driver16.html +++ b/contrib/ntp/html/drivers/driver16.html @@ -2,30 +2,33 @@ - - - - - Bancomm bc635VME Time and Frequency Processor - - + + + + + Bancomm bc635VME Time and Frequency Processor + + - -

    bc635VME/bc350VXI Time and Frequency Processor

    -
    -

    Synopsis

    -

    Address: 127.127.16.u
    - Reference ID: BTFP
    - Driver ID: GPS_BANCOMM
    - Bancomm Device /dev/btfp0
    - Requires: Bancomm bc635 TFP device module driver for SunOS 4.x/SunOS 5.x

    -

    Description

    -

    This is the clock driver for the Bancomm bc635VME Time and Frequency Processor. It requires the BANCOMM bc635VME bc350VXI Time and Frequency Processor Module Driver for SunOS 4.x/SunOS 5.x UNIX Systems.

    -

    Most of this code is originally from refclock_bancomm.c with thanks. It has been modified and tested on an UltraSparc IIi-cEngine running Solaris 2.6. A port for HPUX is not available henceforth.

    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - + +

    bc635VME/bc350VXI Time and Frequency Processor

    +

    Last update: + 21-Oct-2010 23:44 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.16.u
    + Reference ID: BTFP
    + Driver ID: GPS_BANCOMM
    + Bancomm Device /dev/btfp0
    + Requires: Bancomm bc635 TFP device module driver for SunOS 4.x/SunOS 5.x

    +

    Description

    +

    This is the clock driver for the Bancomm bc635VME Time and Frequency Processor. It requires the BANCOMM bc635VME bc350VXI Time and Frequency Processor Module Driver for SunOS 4.x/SunOS 5.x UNIX Systems.

    +

    Most of this code is originally from refclock_bancomm.c with thanks. It has been modified and tested on an UltraSparc IIi-cEngine running Solaris 2.6. A port for HPUX is not available henceforth.

    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver18.html b/contrib/ntp/html/drivers/driver18.html index 6acf5f22a..02fb5d2d8 100644 --- a/contrib/ntp/html/drivers/driver18.html +++ b/contrib/ntp/html/drivers/driver18.html @@ -1,82 +1,82 @@ - - - - - - NIST Modem Time Service - - - - -

    Automated Computer Time Service (ACTS)

    -
    -

    Synopsis

    -

    Address: 127.127.18.u
    - Reference ID: NIST | USNO | PTB | WWVB
    - Driver ID: ACTS_MODEM
    - Serial Port: /dev/actsu; 9600 baud, 8-bits, no parity
    - Features: tty_clk
    - Requires: /usr/include/sys/termios.h header file with modem control and a dial-out (cua) device.

    -

    Description

    -

    This driver supports the US (NIST and USNO) and European (PTB (Germany), NPL (UK), etc.) modem time services, as well as Spectracom GPS and WWVB receivers connected via a modem. The driver periodically dials a number from a telephone list, receives the timecode data and calculates the local clock correction. It is designed primarily for backup when neither a radio clock nor connectivity to Internet time servers are available. It can also be configured to operate full period.

    -

    For best results the indicated time must be corrected for the modem and telephone circuit propagation delays, which can reach 200 ms or more. For the NIST service, corrections are determined automatically by measuring the roundtrip delay of echoed characters. With this service the absolute accuracy is typically a millisecond or two. Corrections for the other services must be determined by other means. With these services variations from call to call and between messages during a call are typically a few milliseconds, occasionally higher.

    -

    This driver requires a 9600-bps modem with a Hayes-compatible command set and control over the modem data terminal ready (DTR) control line. The actual line speed ranges from 1200 bps with USNO to 14,400 bps with NIST. The modem setup string is hard-coded in the driver and may require changes for nonstandard modems or special circumstances.

    -

    There are three modes of operation selected by the mode keyword in the server configuration command. In manual mode (2) the calling program is initiated by setting fudge flag1. This can be done manually using ntpdc, or by a cron job. In auto mode (0) flag1 is set at each poll event. In backup mode (1) flag1 is set at each poll event, but only if no other synchronization sources are available.

    -

    When flag1 is set, the calling program dials the first number in the list specified by the phone command. If the call fails for any reason, the program dials the second number and so on. The phone number is specified by the Hayes ATDT prefix followed by the number itself, including the prefix and long-distance digits and delay code, if necessary. The flag1 is reset and the calling program terminated if (a) valid clock update has been determined, (b) no more numbers remain in the list, (c) a device fault or timeout occurs or (d) fudge flag1 is reset manually using ntpdc.

    -

    The driver automatically recognizes the message format of each modem time service. It selects the parsing algorithm depending on the message length. There is some hazard should the message be corrupted. However, the data format is checked carefully and only if all checks succeed is the message accepted. Corrupted lines are discarded without complaint. Once the service is known, the reference identifier for the driver is set to NIST, USNO, PTB or WWVB as appropriate.

    -

    Ordinarily, the serial port is connected to a modem; however, if fudge flag3 is set, it can be connected directly to a Spectracom WWV or GPS radio for testing or calibration. The Spectracom radio can be connected via a modem if the radio is connfigured to send time codes continuoulsly at 1-s intervals. In principle, fudge flag2 enables port locking, allowing the modem to be shared when not in use by this driver. At least on Solaris with the current NTP I/O routines, this results in lots of ugly error messages.

    -

    The minpoll and maxpoll keywords of the server configuration command can be used to limit the intervals between calls. The recommended settings are 12 (1.1 hours) for minpoll and 17 (36 hours) for maxpoll. Ordinarily, the poll interval will start at minpoll and ramp up to maxpoll in a day or two.

    -

    US Phone Numbers and Formats

    -

    Note: Phone numbers include the entire Hayes modem command, including the ATDT and other control codes as may be necessary. For most cases only the ATDT may be necessary.

    -

    National Institute of Science and Technology (NIST)

    -

    Phone: (303) 494-4774 (Boulder, CO); (808) 335-4721 (Hawaii)

    -

    Data Format

    -

    National Institute of Standards and Technology
    - Telephone Time Service, Generator 3B
    - Enter question mark "?" for HELP
    - MJD YR MO DA H M S ST S UT1 msADV <OTM>
    - 47999 90-04-18 21:39:15 50 0 +.1 045.0 UTC(NIST) *
    - 47999 90-04-18 21:39:16 50 0 +.1 045.0 UTC(NIST) #
    - ...

    -

    MJD, YR, ST, UT1 and UTC(NIST) are not used by this driver. The <OTM> on-time character "*" changes to "#" when the delay correction is valid.

    -

    US Naval Observatory (USNO)

    -

    Phone: (202) 762-1594 (Washington, DC); (719) 567-6742 (Boulder, CO)

    -

    Data Format (two lines, repeating at one-second intervals)

    -

    jjjjj nnn hhmmss UTC

    -

    * on-time character for previous timecode message
    - jjjjj modified Julian day number (not used)
    - nnn day of year
    - hhmmss second of day

    -

    European Phone Numbers and Formats

    -

    Spectracom GPS and WWVB Receivers

    -

    If a modem is connected to a Spectracom receiver, this driver will call it and retrieve the time in one of two formats, 0 and 2. Ordinarily, the receiver requires a T in order to return the timecode. As this driver does not send data via the modem, it must either be configured in continuous mode or be polled by another local driver.

    -

    Monitor Data

    -

    The received timecode is written as-is to the clockstats file along with the Hayes connection and hangup commands and result codes.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Set by the driver to (one of) NIST, USNO, PTB or WWVB. -
    flag1 0 | 1 -
    Initiate a call if 1. Automatically reset by program. -
    flag2 0 | 1 -
    Enables port locking if 1, disables if 0 (default). -
    flag3 0 | 1 -
    Enables direct connection if 1, or modem if 0 (default). If set, the driver will send a single character 'T' at every poll event. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers 

    -
    - - - - \ No newline at end of file + + + +NIST/USNO/PTB Modem Time Services + + + +

    NIST/USNO/PTB Modem Time Services

    +

    Author: David L. Mills (mills@udel.edu)
    + Last update: + 1-Dec-2012 10:44 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.18.u
    + Reference ID: NIST | USNO | PTB | WWVB
    + Driver ID: ACTS_MODEM
    + Serial Port: /dev/actsu; 9600 baud, 8-bits, no parity
    + Features: tty_clk
    + Requires: /usr/include/sys/termios.h header file with modem control and a dial-out (cua) device.

    +

    Description

    +

    This driver supports the US (NIST and USNO) and European (PTB (Germany), NPL (UK), etc.) modem time services, as well as Spectracom GPS and WWVB receivers connected via a modem. The driver periodically dials a number from a telephone list, receives the timecode data and calculates the local clock correction. It is designed primarily for backup when neither a radio clock nor connectivity to Internet time servers are available. It can also be configured to operate full period.

    +

    For best results the indicated time must be corrected for the modem and telephone circuit propagation delays, which can reach 200 ms or more. For the NIST service, corrections are determined automatically by measuring the roundtrip delay of echoed characters. With this service the absolute accuracy is typically a millisecond or two. Corrections for the other services must be determined by other means. With these services variations from call to call and between messages during a call are typically a few milliseconds, occasionally higher.

    +

    This driver requires a 9600-bps modem with a Hayes-compatible command set and control over the modem data terminal ready (DTR) control line. The actual line speed ranges from 1200 bps with USNO to 14,400 bps with NIST. The modem setup string is hard-coded in the driver and may require changes for nonstandard modems or special circumstances.

    +

    There are three modes of operation selected by the mode keyword in the server configuration command. In manual mode (2) the calling program is initiated by setting fudge flag1. This can be done manually using ntpq, or by a cron job. In auto mode (0) flag1 is set at each poll event. In backup mode (1) flag1 is set at each poll event, but only if no other synchronization sources are available.

    +

    When flag1 is set, the calling program dials the first number in the list specified by the phone command. If the call fails for any reason, the program dials the second number and so on. The phone number is specified by the Hayes ATDT prefix followed by the number itself, including the prefix and long-distance digits and delay code, if necessary. The flag1 is reset and the calling program terminated if (a) valid clock update has been determined, (b) no more numbers remain in the list, (c) a device fault or timeout occurs or (d) fudge flag1 is reset manually using ntpq.

    +

    The driver automatically recognizes the message format of each modem time service. It selects the parsing algorithm depending on the message length. There is some hazard should the message be corrupted. However, the data format is checked carefully and only if all checks succeed is the message accepted. Corrupted lines are discarded without complaint. Once the service is known, the reference identifier for the driver is set to NIST, USNO, PTB or WWVB as appropriate.

    +

    The Spectracom radio can be connected via a modem if the radio is configured to send time codes continuously at 1-s intervals. In principle, fudge flag2 enables port locking, allowing the modem to be shared when not in use by this driver. At least on Solaris with the current NTP I/O routines, this results in lots of ugly error messages.

    +

    The minpoll and maxpoll keywords of the server configuration command can be used to limit the intervals between calls. The recommended settings are 12 (1.1 hours) for minpoll and 17 (36 hours) for maxpoll. Ordinarily, the poll interval will start at minpoll and ramp up to maxpoll in a day or two.

    +

    US Phone Numbers and Formats

    +

    Note: Phone numbers include the entire Hayes modem command, including the ATDT and other control codes as may be necessary. For most cases only the ATDT may be necessary.

    +

    National Institute of Science and Technology (NIST)

    +

    Phone: (303) 494-4774 (Boulder, CO); (808) 335-4721 (Hawaii)

    +

    Data Format

    +

    National Institute of Standards and Technology
    + Telephone Time Service, Generator 3B
    + Enter question mark "?" for HELP
    + MJD YR MO DA H M S ST S UT1 msADV <OTM>
    + 47999 90-04-18 21:39:15 50 0 +.1 045.0 UTC(NIST) *
    + 47999 90-04-18 21:39:16 50 0 +.1 045.0 UTC(NIST) #
    + ...

    +

    MJD, YR, ST, UT1 and UTC(NIST) are not used by this driver. The <OTM> on-time character "*" changes to "#" when the delay correction is valid.

    +

    US Naval Observatory (USNO)

    +

    Phone: (202) 762-1594 (Washington, DC); (719) 567-6742 (Boulder, CO)

    +

    Data Format (two lines, repeating at one-second intervals)

    +

    jjjjj nnn hhmmss UTC

    +

    * on-time character for previous timecode message
    + jjjjj modified Julian day number (not used)
    + nnn day of year
    + hhmmss second of day

    +

    European Phone Numbers and Formats

    +

    Spectracom GPS and WWVB Receivers

    +

    If a modem is connected to a Spectracom receiver, this driver will call it and retrieve the time in one of two formats, 0 and 2. Ordinarily, the receiver requires a T in order to return the timecode. As this driver does not send data via the modem, it must either be configured in continuous mode or be polled by another local driver.

    +

    Monitor Data

    +

    The received timecode is written as-is to the clockstats file along with the Hayes connection and hang-up commands and result codes.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Set by the driver to (one of) NIST, USNO, PTB or WWVB.
    +
    flag1 0 | 1
    +
    Initiate a call if 1. Automatically reset by program.
    +
    flag2 0 | 1
    +
    Enables port locking if 1, disables if 0 (default).
    +
    flag3 0 | 1
    +
    Not used by this driver.
    +
    flag4 0 | 1
    +
    Not used by this driver.
    +
    +

    Additional Information

    +

    Reference Clock Drivers 

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver19.html b/contrib/ntp/html/drivers/driver19.html index 961ca09b9..2c8278fb0 100644 --- a/contrib/ntp/html/drivers/driver19.html +++ b/contrib/ntp/html/drivers/driver19.html @@ -1,59 +1,59 @@ - - - - - - Heath WWV/WWVH Receiver - - - - -

    Heath WWV/WWVH Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.19.u
    - Reference ID: WWV
    - Driver ID: WWV_HEATH
    - Serial Port: /dev/heathu; 1200 baud, 8-bits, no parity
    - Features: tty_clk
    - Requires: /usr/include/sys/termios.h header file with modem control

    -

    Description

    -

    This driver supports the Heath GC-1000 Most Accurate Clock, with RS232C Output Accessory. This is a WWV/WWVH receiver somewhat less robust than other supported receivers. Its claimed accuracy is 100 ms when actually synchronized to the broadcast signal, but this doesn't happen even most of the time, due to propagation conditions, ambient noise sources, etc. When not synchronized, the accuracy is at the whim of the internal clock oscillator, which can wander into the sunset without warning. Since the indicated precision is 100 ms, expect a host synchronized only to this thing to wander to and fro, occasionally being rudely stepped when the offset exceeds the default CLOCK_MAX of 128 ms.

    -

    The internal DIPswitches should be set to operate at 1200 baud in MANUAL mode and the current year. The external DIPswitches should be set to GMT and 24-hour format. It is very important that the year be set correctly in the DIPswitches; otherwise, the day of year will be incorrect after 28 April of a normal or leap year.

    -

    In MANUAL mode the clock responds to a rising edge of the request to send (RTS) modem control line by sending the timecode. Therefore, it is necessary that the operating system implement the TIOCMBIC and TIOCMBIS ioctl system calls and TIOCM_RTS control bit. Present restrictions require the use of a POSIX-compatible programming interface, although other interfaces may work as well.

    -

    The clock message consists of 23 ASCII printing characters in the following format:

    -
    hh:mm:ss.f     dd/mm/yr<cr>
    +
    +
    +
    +Heath WWV/WWVH Receiver
    +
    +
    +
    +

    Heath WWV/WWVH Receiver

    +

    Author: David L. Mills (mills@udel.edu)
    + Last update: + 11-Sep-2010 05:56 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.19.u
    + Reference ID: WWV
    + Driver ID: WWV_HEATH
    + Serial Port: /dev/heathu; 1200 baud, 8-bits, no parity
    + Features: tty_clk
    + Requires: /usr/include/sys/termios.h header file with modem control

    +

    Description

    +

    This driver supports the Heath GC-1000 Most Accurate Clock, with RS232C Output Accessory. This is a WWV/WWVH receiver somewhat less robust than other supported receivers. It's claimed accuracy is 100 ms when actually synchronized to the broadcast signal, but this doesn't happen even most of the time, due to propagation conditions, ambient noise sources, etc. When not synchronized, the accuracy is at the whim of the internal clock oscillator, which can wander into the sunset without warning. Since the indicated precision is 100 ms, expect a host synchronized only to this thing to wander to and fro, occasionally being rudely stepped when the offset exceeds the default CLOCK_MAX of 128 ms.

    +

    The internal DIPswitches should be set to operate at 1200 baud in MANUAL mode and the current year. The external DIPswitches should be set to GMT and 24-hour format. It is very important that the year be set correctly in the DIPswitches; otherwise, the day of year will be incorrect after 28 April of a normal or leap year.

    +

    In MANUAL mode the clock responds to a rising edge of the request to send (RTS) modem control line by sending the timecode. Therefore, it is necessary that the operating system implement the TIOCMBIC and TIOCMBIS ioctl system calls and TIOCM_RTS control bit. Present restrictions require the use of a POSIX-compatible programming interface, although other interfaces may work as well.

    +

    The clock message consists of 23 ASCII printing characters in the following format:

    +
    hh:mm:ss.f     dd/mm/yr<cr>
     
     hh:mm:ss.f = hours, minutes, seconds
     f = deciseconds ('?' when out of spec)
     dd/mm/yr = day, month, year
    -

    The alarm condition is indicated by '?', rather than a digit, at A. Note that 0?:??:??.? is displayed before synchronization is first established and hh:mm:ss.? once synchronization is established and then lost again for about a day.

    -

    A fudge time1 value of .07 s appears to center the clock offset residuals.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWV. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver -
    - Additional Information -

    Reference Clock Drivers 

    -
    - - - - \ No newline at end of file +

    The alarm condition is indicated by '?', rather than a digit, at A. Note that 0?:??:??.? is displayed before synchronization is first established and hh:mm:ss.? once synchronization is established and then lost again for about a day.

    +

    A fudge time1 value of .07 s appears to center the clock offset residuals.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWV.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Not used by this driver.
    +
    flag3 0 | 1
    +
    Not used by this driver.
    +
    flag4 0 | 1
    +
    Not used by this driver
    +
    +Additional Information +

    Reference Clock Drivers 

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver2.html b/contrib/ntp/html/drivers/driver2.html deleted file mode 100644 index 20bad64a2..000000000 --- a/contrib/ntp/html/drivers/driver2.html +++ /dev/null @@ -1,67 +0,0 @@ - - - - - - - - Trak 8820 GPS Receiver - - - - -

    Trak 8820 GPS Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.2.u
    - Reference ID: GPS
    - Driver ID: GPS_TRAK
    - Serial Port: /dev/traku; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    Description

    -

    This driver supports the Trak 8820 GPS Station Clock. The claimed accuracy at the 1-PPS output is 200-300 ns relative to the broadcast signal; however, in most cases the actual accuracy is limited by the precision of the timecode and the latencies of the serial interface and operating system.

    -

    For best accuracy, this radio requires the tty_clk line discipline, which captures a timestamp at the * on-time character of the timecode. Using this discipline the jitter is in the order of 1 ms and systematic error about 0.5 ms. If unavailable, the buffer timestamp is used, which is captured at the \r ending the timecode message. This introduces a systematic error of 23 character times, or about 24 ms at 9600 bps, together with a jitter well over 8 ms on Sun IPC-class machines.

    -

    Using the menus, the radio should be set for 9600 bps, one stop bit and no parity. It should be set to operate in computer (no echo) mode. The timecode format includes neither the year nor leap-second warning.

    -

    In operation, this driver sends a RQTS\r request to the radio at initialization in order to put it in continuous time output mode. The radio then sends the following message once each second:

    -
    *RQTS U,ddd:hh:mm:ss.0,q<cr><lf>
    -on-time = '*'
    -ddd = day of year
    -hh:mm:ss = hours, minutes, seconds
    -q = quality indicator (phase error), 0-6:
    -     0 > 20 us
    -     6 > 10 us
    -     5 > 1 us
    -     4 > 100 ns
    -     3 > 10 ns
    -     2 < 10 ns
    - The alarm condition is indicated by 0 at Q, which means the radio has a phase error greater than 20 us relative to the broadcast time. The absence of year, DST and leap-second warning in this format is also alarmed. -

    The continuous time mode is disabled using the RQTX\r request, following which the radio sends a RQTX DONE<cr><lf> response. In the normal mode, other control and status requests are effective, including the leap-second status request RQLS<cr>. The radio responds with RQLS yy,mm,dd<cr><lf>, where yy,mm,dd are the year, month and day. Presumably, this gives the epoch of the next leap second, RQLS 00,00,00 if none is specified in the GPS message. Specified in this form, the information is generally useless and is ignored by the driver.

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -

    Additional Information

    -

    Reference Clock Drivers

    -
    -
    - - - - \ No newline at end of file diff --git a/contrib/ntp/html/drivers/driver20.html b/contrib/ntp/html/drivers/driver20.html index 17be32cc4..6391e8693 100644 --- a/contrib/ntp/html/drivers/driver20.html +++ b/contrib/ntp/html/drivers/driver20.html @@ -1,91 +1,432 @@ + + Generic NMEA GPS Receiver + + + - - - - - - Generic NMEA GPS Receiver - - - - -

    Generic NMEA GPS Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.20.u
    - Reference ID: GPS
    - Driver ID: GPS_NMEA
    - Serial Port: /dev/gpsu; 4800 baud, 8-bits, no parity
    - Serial Port: /dev/gpsu; symlink to server:port (for nmead) Features: tty_clk

    -

    Description

    -

    This driver supports GPS receivers with the $GPRMC NMEA output string by default.  Alternately the $GPGGA or $GPGLL may be selected.

    -

    The driver expects the receiver to be set up to transmit a $GPRMC message every second.

    -

    The accuracy depend on the receiver used. Inexpesive GPS models are available with a claimed PPS signal accuracy of 1 ms or better relative to the broadcast signal. However, in most cases the actual accuracy is limited by the precision of the timecode and the latencies of the serial interface and operating system.

    -

    If the Operating System supports the PPSAPI, RFC-2783, it will be used.
     

    -

    The various GPS sentences that this driver recognises look like this:
    - (others quietly ignored)

    -
    $GPRMC,POS_UTC,POS_STAT,LAT,LAT_REF,LON,LON_REF,SPD,HDG,DATE,MAG_VAR,MAG_REF*CC<cr><lf>
    -$GPGLL,LAT,LAT_REF,LONG,LONG_REF,POS_UTC,POS_STAT*CC<cr><lf>
    -$GPGGA,POS_UTC,LAT,LAT_REF,LONG,LONG_REF,FIX_MODE,SAT_USED,HDOP,ALT,ALT_UNIT,GEO,G_UNIT,D_AGE,D_REF*CC<cr><lf>
    -
    -  POS_UTC  - UTC of position. Hours, minutes and seconds [fraction (opt.)]. (hhmmss[.fff])
    -  POS_STAT - Position status. (A = Data valid, V = Data invalid)
    -  LAT      - Latitude (llll.ll)
    -  LAT_REF  - Latitude direction. (N = North, S = South)
    -  LON      - Longitude (yyyyy.yy)
    -  LON_REF  - Longitude direction (E = East, W = West)
    -  SPD      - Speed over ground. (knots) (x.x)
    -  HDG      - Heading/track made good (degrees True) (x.x)
    -  DATE     - Date (ddmmyy)
    -  MAG_VAR  - Magnetic variation (degrees) (x.x)
    -  MAG_REF  - Magnetic variation (E = East, W = West)
    -  FIX_MODE - Position Fix Mode ( 0 = Invalid, >0 = Valid)
    -  SAT_USED - Number Satellites used in solution
    -  HDOP     - Horizontal Dilution of Precision
    -  ALT      - Antenna Altitude
    -  ALT_UNIT - Altitude Units (Metres/Feet)
    -  GEO      - Geoid/Elipsoid separation
    -  G_UNIT   - Geoid units (M/F)
    -  D_AGE    - Age of last DGPS Fix
    -  D_REF    - Reference ID of DGPS station
    -  CC       - Checksum (optional)
    -  <cr><lf> - Sentence terminator.
    - Alternate GPS sentences (other than $GPRMC - the default) may be enabled by setting the relevent bits of 'mode' in the server configuration line
     * server 127.127.20.x mode X
        bit 0 - enables RMC    ( value = 1)
        bit 1 - enables GGA    ( value = 2)
        bit 2 - enables GLL      ( value = 4)
    - multiple sentences may be selected
    -

    The driver will send a $PMOTG,RMC,0000*1D<cr><lf> message each time a $GPRMC string is needed. This is not needed on most GPS receivers because they automatically send the $GPRMC string every second and will only work on GPS receivers that understand the $PMOTG string. Others will just ignore it.

    -

    Setting up the Garmin GPS-25XL

    - Switch off all output with by sending it the following string. -
    "$PGRMO,,2<cr><lf>"
    -

    Now switch only $GPRMC on by sending it the following string.

    -
    "$PGRMO,GPRMC,1<cr><lf>"
    -

    On some systems the PPS signal isn't switched on by default. It can be switched on by sending the following string.

    -
    "$PGRMC,,,,,,,,,,,,2<cr><lf>"
    -

    Monitor Data

    -

    The GPS sentence(s) that is used is written to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the PPS signal on-time edge: 0 for assert (default), 1 for clear. -
    flag3 0 | 1 -
    Controls the kernel PPS discipline: 0 for disable (default), 1 for enable. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file + + + +

    Generic NMEA GPS Receiver

    +

    Last update: + 31-Mar-2014 03:55 + UTC

    +
    +

    Synopsis

    + +

    + Address: 127.127.20.u
    + Reference ID: GPS
    + Driver ID: GPS_NMEA
    + Serial Port: /dev/gpsu; 4800 - 115200 bps, 8-bits, no parity
    + Serial Port: /dev/gpsppsu; for just the PPS signal (this + is tried first for PPS, before /dev/gpsu)
    + Serial Port: /dev/gpsu; symlink to server:port (for nmead)
    + Features: tty_clk +

    + +

    Description

    + +

    + This driver supports GPS receivers with + the $GPRMC, $GPGLL, $GPGGA, $GPZDA + and $GPZDG NMEA sentences by default.  Note that Accord's + custom NMEA sentence $GPZDG reports using the GPS timescale, + while the rest of the sentences report UTC.  The difference between + the two is a whole number of seconds which increases with each leap + second insertion in UTC.  To avoid problems mixing UTC and GPS + timescales, the driver disables processing of UTC sentences + once $GPZDG is received. +

    +

    + The driver expects the receiver to be set up to transmit at least one + supported sentence every second. +

    +

    + The accuracy depends on the receiver used. Inexpensive GPS models are + available with a claimed PPS signal accuracy of + 1 μs or better relative to the broadcast + signal. However, in most cases the actual accuracy is limited by the + precision of the timecode and the latencies of the serial interface and + operating system. +

    +

    + If the Operating System supports PPSAPI + (RFC 2783), fudge flag1 + 1 enables its use. +

    +

    + The various GPS sentences that this driver recognises look like this:
    + (others quietly ignored) +

    + +

    + + + + + + + + + + + + + + + + +
    Accepted NMEA sentences
    SentenceVendor
    $GPRMC,UTC,POS_STAT,LAT,LAT_REF,LON,LON_REF,SPD,HDG,DATE,MAG_VAR,MAG_REF*CS<cr><lf>
    $GPGLL,LAT,LAT_REF,LON,LON_REF,UTC,POS_STAT*CS<cr><lf>
    $GPGGA,UTC,LAT,LAT_REF,LON,LON_REF,FIX_MODE,SAT_USED,HDOP,ALT,ALT_UNIT,GEO,G_UNIT,D_AGE,D_REF*CS<cr><lf>
    $GPZDA,UTC,DD,MM,YYYY,TH,TM,*CS<cr><lf>
    $GPZDG,GPSTIME,DD,MM,YYYY,AA.BB,V*CS<cr><lf>Accord

    + +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    NMEA data items
    SymbolMeaning and Format
    UTCTime of day on UTC timescale. Hours, minutes and seconds [fraction (opt.)]. (hhmmss[.fff])
    POS_STATPosition status. (A = Data valid, V = Data invalid)
    LATLatitude (llll.ll)
    LAT_REFLatitude direction. (N = North, S = South)
    LONLongitude (yyyyy.yy)
    LON_REFLongitude direction (E = East, W = West)
    SPDSpeed over ground. (knots) (x.x)
    HDGHeading/track made good (degrees True) (x.x)
    DATEDate (ddmmyy)
    MAG_VARMagnetic variation (degrees) (x.x)
    MAG_REFMagnetic variation (E = East, W = West)
    FIX_MODEPosition Fix Mode (0 = Invalid, >0 = Valid)
    SAT_USEDNumber of Satellites used in solution
    HDOPHorizontal Dilution of Precision
    ALTAntenna Altitude
    ALT_UNITAltitude Units (Metres/Feet)
    GEOGeoid/Elipsoid separation
    G_UNITGeoid units (M/F)
    D_AGEAge of last DGPS Fix
    D_REFReference ID of DGPS station
    GPSTIMETime of day on GPS timescale. Hours, minutes and seconds [fraction (opt.)]. (hhmmss[.f])
    DDDay of the month (1-31)
    MMMonth of the year (1-12)
    YYYYYear
    AA.BBDenotes the signal strength (should be < 05.00)
    VGPS sync status
    +    '0' => INVALID time,
    +    '1' => accuracy of +/- 20ms,
    +    '2' => accuracy of +/- 100ns
    CS Checksum
    <cr><lf>Sentence terminator.

    + + +

    The 'mode' byte

    + +

    + Specific GPS sentences and bitrates may be selected by setting bits of + the 'mode' in the server configuration line:
      server + 127.127.20.x mode X +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    mode byte bits and bit groups
    BitDecimalHexMeaning
    011process $GPMRC
    122process $GPGGA
    244process $GPGLL
    388process $GPZDA or $GPZDG
    4-600linespeed 4800 bps
    160x10linespeed 9600 bps
    320x20linespeed 19200 bps
    480x30linespeed 38400 bps
    640x40linespeed 57600 bps
    800x50linespeed 115200 bps
    71280x80Write the sub-second fraction of the receive time stamp to the + clockstat file for all recognised NMEA sentences. This can be used to + get a useful value for fudge time2.
    Caveat: This + will fill your clockstat file rather fast. Use it only temporarily to + get the numbers for the NMEA sentence of your choice.
    82560x100process $PGRMF
    9-150xFE00reserved - leave 0
    16655360x10000Append extra statistics to the clockstats line. + Details below.
    + + +

    + The default (mode 0) is to process all supported sentences at a linespeed + of 4800 bps, which results in the first one received and recognised in + each cycle being used.  If only specific sentences should be + recognised, then the mode byte must be chosen to enable only the selected + ones.  Multiple sentences may be selected by adding their mode bit + values, but of those enabled still only the first received sentence in a + cycle will be used.  Using more than one sentence per cycle is + impossible, because +

      +
    • there is only fudge time2 available to + compensate for transmission delays but every sentence would need a + different one and +
    • using more than one sentence per cycle overstuffs the internal data + filters. +
    + The driver uses 4800 bits per second by default, but faster bitrates can + be selected using bits 4 to 6 of the mode field. +

    + +

    + Caveat: Using higher line speeds does not necessarily + increase the precision of the timing device.  Higher line speeds are + not necessarily helpful for the NMEA driver, either.  They can be + used to accomodate for an amount of data that does not fit into a + 1-second cycle at 4800 bps, but high-speed high-volume NMEA data is likely + to cause trouble with the serial line driver since NMEA supports no + protocol handshake.  Any device that is exclusively used for time + synchronisation purposes should be configured to transmit the relevant + data only, e.g. one $GPRMC or $GPZDA per second, at a + linespeed of 4800 bps or 9600 bps. +

    + +

    Monitor Data

    + +

    The last GPS sentence that is accepted or rejected is written to the + clockstats file and available with ntpq -c clockvar. + (Logging the rejected sentences lets you see/debug why they were rejected.) + Filtered sentences are not logged.

    + +

    + If the 0x10000 mode bit is on and clockstats is enabled, several extra + counters will be appended to the NMEA sentence that gets logged. + For example: +

    +56299 76876.691 127.127.20.20 $GPGGA,212116.000,3726.0785,N,12212.2605,W,1,05,2.0,17.0,M,-25.7,M,,0000*5C  228 64 0 0 64 0
    +
    +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Clockstats
    ColumnSampleMeaning
    156299MJD
    276876.691Time of day in seconds
    3127.127.20.20IP Address from server config line
    4$GPGGA,...0*5CNMEA Sentence
    5228Number of sentences received
    664Number of sentences accepted and used for timekeeping
    70Number of sentences rejected because they were marked invalid (poor signal)
    80Number of sentences rejected because of bad checksum or invalid date/time
    964Number of sentences filtered by mode bits or same second
    100Number of PPS pulses used, overrides NMEA sentences
    + + Sentences like $GPGSV that don't contain the time will get + counted in the total but otherwise ignored. + +

    + Configuring + NMEA Refclocks might give further useful hints for specific hardware + devices that exhibit strange or curious behaviour. +

    + +

    + To make a specific setting, select the corresponding decimal values from + the mode byte table, add them all together and enter the resulting + decimal value into the clock configuration line. +

    + +

    Setting up the Garmin GPS-25XL

    + + Switch off all output with by sending it the following string. +
    "$PGRMO,,2<cr><lf>"
    +

    Now switch only $GPRMC on by sending it the following string.

    +
    "$PGRMO,GPRMC,1<cr><lf>"
    + +

    On some systems the PPS signal isn't switched on by default. It can be + switched on by sending the following string.

    +
    "$PGRMC,,,,,,,,,,,,2<cr><lf>"
    + +

    Fudge Factors

    + +
    +
    time1 time
    +
    Specifies the PPS time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Specifies the serial end of line time offset calibration factor, in seconds and fraction, with default + 0.0.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with + default GPS.
    +
    flag1 0 | 1
    +
    Disable PPS signal processing if 0 (default); enable PPS signal processing if 1.
    +
    flag2 0 | 1
    +
    If PPS signal processing is enabled, capture the pulse on the rising edge if 0 (default); capture on the + falling edge if 1.
    +
    flag3 0 | 1
    +
    If PPS signal processing is enabled, use the ntpd clock discipline if 0 (default); use the kernel + discipline if 1.
    +
    flag4 0 | 1
    +
    Obscures location in timecode: 0 for disable (default), 1 for enable.
    +
    + +

    Additional Information

    +

    flag1, flag2, and flag3 are ignored under Windows.

    +

    Reference Clock Drivers

    +
    + + diff --git a/contrib/ntp/html/drivers/driver22.html b/contrib/ntp/html/drivers/driver22.html index e1ed132b6..acae265d2 100644 --- a/contrib/ntp/html/drivers/driver22.html +++ b/contrib/ntp/html/drivers/driver22.html @@ -1,60 +1,98 @@ - - - - - - PPS Clock Discipline - - - - -

    PPS Clock Discipline

    -
    -

    Synopsis

    -

    Address: 127.127.22.u
    - Reference ID: PPS
    - Driver ID: PPS
    - Serial or Parallel Port: /dev/ppsu
    - Requires: PPSAPI interface

    -

    Note: This driver supersedes an older one of the same name. The older driver operated with several somewhat archaic signal interface devices, required intricate configuration and was poorly documented. This driver operates only with the PPSAPI interface proposed as an IETF standard. Note also that the pps configuration command has been obsoleted by this driver.

    -

    Description

    -

    This driver furnishes an interface for the pulse-per-second (PPS) signal produced by a cesium clock, radio clock or related devices. It can be used to augment the serial timecode generated by a GPS receiver, for example. It can be used to remove accumulated jitter and re-time a secondary server when synchronized to a primary server over a congested, wide-area network and before redistributing the time to local clients. The driver includes extensive signal sanity checks and grooming algorithms. A range gate and frequency discriminator reject noise and signals with incorrect frequency. A multiple-stage median filter rejects jitter due to hardware interrupt and operating system latencies. A trimmed-mean algorithm determines the best time samples. With typical workstations and processing loads, the incidental jitter can be reduced to a few microseconds.

    -

    While this driver can discipline the time and frequency relative to the PPS source, it cannot number the seconds. For this purpose an auxiliary source is required, ordinarily a radio clock operated as a primary reference (stratum 1) source; however, another NTP time server can be used as well. For this purpose, the auxiliary source should be specified as the prefer peer, as described in the Mitigation Rules and the prefer Keyword page.

    -

    The driver requires the PPSAPI interface1, which is a proposed IETF standard. The interface consists of the timepps.h header file and associated kernel support. Support for this interface is included in current versions of Solaris, FreeBSD and Linux and proprietary versions of Tru64 (Alpha) and SunOS. See the Pulse-per-second (PPS) Signal Interfacing page for further information.

    -

    The PPS source can be connected via a serial or parallel port, depending on the hardware and operating system. A serial port can be dedicated to the PPS source or shared with another device; however, if dedicated the data leads should not be connected, as noise or unexpected signals can cause ntpd to exit.

    -

    A radio clock is usually connected via a serial port and the PPS source connected via a level converter to the data carrier detect (DCD) pin (DB-9 pin 1, DB-25 pin 8) of the same connector. In some systems where a parallel port and driver are available, the PPS signal can be connected directly to the ACK pin (pin 10) of the connector. Whether the PPS signal is connected via a dedicated port or shared with another device, the driver opens the device /dev/pps%d, where %d is the unit number. As with other drivers, links can be used to redirect the logical name to the actual physical device.

    -

    The driver normally operates like any other driver and uses the same mitigation algorithms and PLL/FLL clock discipline incorporated in the daemon. If kernel PLL/FLL support is available, the kernel PLL/FLL clock discipline can be used instead. The default behavior is not to use the kernel PPS clock discipline, even if present. This driver incorporates a good deal of signal processing to reduce jitter using the median filter and trimmed average algorithms in the driver interface. As the result, performance with minpoll and maxpoll configured at the minimum 4 (16s) is generally better than the kernel PPS discipline. However, fudge flag 3 can be used to enable the kernel PPS discipline if necessary.

    -

    Note that the PPS source is considered valid only if the auxiliary source is the prefer peer, is reachable and is selectable to discipline the system clock. By default the stratum assigned to the PPS source is automatically determined. If the auxiliary source is unreachable or inoperative, the stratum is set to 16. Otherwise it is set to the stratum specified by the fudge stratum command, if present, or the auxiliary source stratum if not present. Please note the temptation to masquerade as a primary server by forcing the stratum to zero is decidedly dangerous, as it invites timing loops.

    -

    The mode keyword of the server command can be used to set the PPSAPI mode bits which determine the capture edge and echo options. See the /usr/include/sys/timepps.h header file for the bit definitions, which must be converted to their decimal equivalents. This overrides the fudge flag2 option.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default PPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the PPS signal on-time edge: 0 for assert (default), 1 for clear. -
    flag3 0 | 1 -
    Controls the kernel PPS discipline: 0 for disable (default), 1 for enable. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -

    Reference

    -
      -
    1. Mogul, J., D. Mills, J. Brittenson, J. Stone and U. Windl. Pulse-per-second API for Unix-like operating systems, version 1. Request for Comments RFC-2783, Internet Engineering Task Force, March 2000, 31 pp. -
    -
    - - - - \ No newline at end of file + + + +PPS Clock Discipline + + + + +

    PPS Clock Discipline

    +

    Author: David L. Mills (mills@udel.edu)
    + Last change: + 31-Mar-2014 07:46 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.22.u
    + Reference ID: PPS
    + Driver ID: PPS
    + Serial or Parallel Port: /dev/ppsu
    + Requires: PPSAPI signal interface for PPS signal processing.

    +

    Note: This driver supersedes an older one of the same name. The older driver operated with several somewhat archaic signal interface devices, required intricate configuration and was poorly documented. This driver requires the Pulse per Second API (PPSAPI)1. Note also that the pps configuration command has been obsoleted by this driver.

    +

    Description

    +

    This driver furnishes an interface for the pulse-per-second (PPS) signal produced by a cesium clock, radio clock or related devices. It can be used to augment the serial timecode generated by a GPS receiver, for example. It can be used to remove accumulated jitter and re-time a secondary server when synchronized to a primary server over a congested, wide-area network and before redistributing the time to local clients. The driver includes extensive signal sanity checks and grooming algorithms. A range gate and frequency discriminator reject noise and signals with incorrect frequency. A multiple-stage median filter rejects jitter due to hardware interrupt and operating system latencies. A trimmed-mean algorithm determines the best time samples. With typical workstations and processing loads, the incidental jitter can be reduced to a few microseconds.

    +

    While this driver can discipline the time and frequency relative to the PPS source, it cannot number the seconds. For this purpose an auxiliary source is required, ordinarily a radio clock operated as a primary reference (stratum 1) source; however, another NTP time server can be used as well. For this purpose, the auxiliary source should be specified as the prefer peer, as described in the Mitigation Rules and the prefer Keyword page.

    +

    The driver requires the PPSAPI interface1, which is a proposed IETF standard. The interface consists of the timepps.h header file and associated kernel support. Support for this interface is included in current versions of Solaris, FreeBSD and Linux and proprietary versions of Tru64 (Alpha) and SunOS. See the Pulse-per-second (PPS) Signal Interfacing page for further information.

    +

    The PPS source can be connected via a serial or parallel port, depending on the hardware and operating system. A serial port can be dedicated to the PPS source or shared with another device; however, if dedicated the data leads should not be connected, as noise or unexpected signals can cause ntpd to exit.

    +

    A radio clock is usually connected via a serial port and the PPS source + connected via a level converter to the data carrier detect (DCD) + pin (DB-9 pin 1, DB-25 pin 8) of the same connector. In some systems + where a parallel port and driver are available, the PPS signal can + be connected directly to the ACK pin (DB25 pin 10) of the connector. + Whether the PPS signal is connected via a dedicated port or shared with another + device, the driver opens the device /dev/pps%d, + where %d is the unit number. As with other drivers, links can be + used to redirect the logical name to the actual physical device.

    +

    The driver normally operates like any other driver and uses the same mitigation + algorithms and PLL/FLL clock discipline incorporated in the daemon. + If kernel PLL/FLL support is available, the kernel PLL/FLL clock + discipline can be used instead. The default behavior is not to use + the kernel PPS clock discipline, even if present. This driver incorporates + a good deal of signal processing to reduce jitter using the median + filter algorithm in the driver. As the result, performance + with minpoll configured at 4 (16s) is generally + better than the kernel PPS discipline. However, fudge flag 3 can + be used to enable the kernel PPS discipline if necessary.

    +

    This driver + is enabled only under one of two conditions (a) a prefer peer other than + this driver is among the survivors of the mitigation algorithms or (b) + there are no survivors and the minsane option + of the tos command is 0. The prefer peer designates another source + that can reliably number the seconds when available . However, if no + sources are available, the system clock continues to be disciplined by + the PPS driver on an indefinite basis.

    +

    A scenario where the latter behavior can be most useful is a planetary orbiter + fleet, for instance in the vicinity of Mars, where contact between orbiters + and Earth only one or two times per Sol (Mars day). These orbiters have a + precise timing reference based on an Ultra Stable Oscillator (USO) with accuracy + in the order of a Cesium oscillator. A PPS signal is derived from the USO + and can be disciplined from Earth on rare occasion or from another orbiter + via NTP. In the above scenario the PPS signal disciplines the spacecraft clock + between NTP updates.

    +

    In a similar scenario a PPS signal can be used to discipline the clock between + updates produced by the modem driver. This would provide precise synchronization + without needing the Internet at all.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default PPS.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Specifies PPS capture on the rising (assert) pulse edge if 0 (default) or falling + (clear) pulse edge if 1. Not used under Windows - if the special serialpps.sys serial port driver is installed then the leading edge will always be used.
    +
    flag3 0 | 1
    +
    Controls the kernel PPS discipline: 0 for disable (default), 1 for enable. Not used under Windows - if the special serialpps.sys serial port driver is used then kernel PPS will be available and used.
    +
    flag4 0 | 1
    +
    Record a timestamp once for each second if 1. Useful for constructing + Allan deviation plots.
    + . +
    +

    Additional Information

    +

    Reference Clock Drivers

    +

    Reference

    +
      +
    1. Mogul, J., D. Mills, J. Brittenson, J. Stone and U. Windl. Pulse-per-second API for Unix-like operating systems, version 1. Request for Comments RFC-2783, Internet Engineering Task Force, March 2000, 31 pp.
    2. +
    +
    + + + diff --git a/contrib/ntp/html/drivers/driver26.html b/contrib/ntp/html/drivers/driver26.html index f840a03cf..dc84cc154 100644 --- a/contrib/ntp/html/drivers/driver26.html +++ b/contrib/ntp/html/drivers/driver26.html @@ -11,6 +11,9 @@

    Hewlett Packard 58503A GPS Receiver and HP Z3801A

    +

    Last update: + 5-Oct-2005 04:37 + UTC


    Synopsis

    Address: 127.127.26.u
    diff --git a/contrib/ntp/html/drivers/driver27.html b/contrib/ntp/html/drivers/driver27.html index 8c2633c50..91534ad05 100644 --- a/contrib/ntp/html/drivers/driver27.html +++ b/contrib/ntp/html/drivers/driver27.html @@ -11,6 +11,9 @@

    Arcron MSF Receiver

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.27.u
    @@ -46,7 +49,6 @@

    g CR
    Request for signal quality. Answer only valid during (late part of) resync to MSF signal. The response consists of two characters as follows: -
      bit 7
      parity @@ -79,7 +81,6 @@
      bit 2--0
      reception signal quality in the range 0--5 (very poor to very good); if in the range 0--2 no successful reception is to be expected. The reported value drops to zero when not resyncing, ie when first returned byte is not `3'.
      -
    h CR
    Request to resync to signal. Can take up from about 30s to 360s. Drains batteries so should not be used excessively. After this the clock time and date should be correct and the phase within 20ms of time as transmitted from the source signal (remember to allow for propagation time). By default the clock resyncs once per day in the late evening/early morning (presumably to catch transitions to/from daylight saving time quickly). This driver code, by default, resyncs at least once per hour to minimise clock wander.
    o CR @@ -244,4 +245,4 @@ May 10 12:41:34 oolong ntpd[615]: ARCRON: sync finished, signal quality 3: OK, w - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver28.html b/contrib/ntp/html/drivers/driver28.html index 244de1a33..efa862f5f 100644 --- a/contrib/ntp/html/drivers/driver28.html +++ b/contrib/ntp/html/drivers/driver28.html @@ -5,72 +5,249 @@ - Shared memoy Driver + Shared Memory Driver +

    Shared Memory Driver

    +

    Last update: + 8-Aug-2014 19:17 + UTC


    Synopsis

    Address: 127.127.28.u
    Reference ID: SHM
    Driver ID: SHM

    +

    Description

    -

    This driver receives its reference clock info from a shared memory-segment. The shared memory-segment is created with owner-only access for unit 0 and 1, and world access for unit 2 and 3

    +

    This driver receives its reference clock info from a shared + memory-segment. The shared memory-segment is created with owner-only + access by default, unless otherwise requested by the mode word for units + ≥2. Units 0 and 1 are always created with owner-only access for + backward compatibility. +

    + +

    Structure of shared memory-segment

    struct shmTime {
    -  int    mode; /* 0 - if valid set
    -                *       use values, 
    -                *       clear valid
    -                * 1 - if valid set 
    -                *       if count before and after read of 
    -                *       values is equal,
    -                *         use values 
    -                *       clear valid
    -                */
    -  int    count;
    -  time_t clockTimeStampSec;      /* external clock */
    -  int    clockTimeStampUSec;     /* external clock */
    -  time_t receiveTimeStampSec;    /* internal clock, when external value was received */
    -  int    receiveTimeStampUSec;   /* internal clock, when external value was received */
    -  int    leap;
    -  int    precision;
    -  int    nsamples;
    -  int    valid;
    -  int    dummy[10]; 
    +        int    mode; /* 0 - if valid is set:
    +                      *       use values,
    +                      *       clear valid
    +                      * 1 - if valid is set:
    +                      *       if count before and after read of data is equal:
    +                      *         use values
    +                      *       clear valid
    +                      */
    +        volatile int    count;
    +        time_t          clockTimeStampSec;
    +        int             clockTimeStampUSec;
    +        time_t          receiveTimeStampSec;
    +        int             receiveTimeStampUSec;
    +        int             leap;
    +        int             precision;
    +        int             nsamples;
    +        volatile int    valid;
    +        unsigned        clockTimeStampNSec;     /* Unsigned ns timestamps */
    +        unsigned        receiveTimeStampNSec;   /* Unsigned ns timestamps */
    +        int             dummy[8];
     };
    +

    Operation mode=0

    -

    When the poll-method of the driver is called, the valid-flag of the shared memory-segment is checked:

    -

    If set, the values in the record (clockTimeStampSec, clockTimeStampUSec, receiveTimeStampSec, receiveTimeStampUSec, leap, precision) are passed to ntp, and the valid-flag is cleared.

    -

    If not set, a timeout is reported to ntp, nothing else happend

    +

    Each second, the value of valid of the shared memory-segment is checked:

    +

    If set, the values in the record (clockTimeStampSec, clockTimeStampUSec, receiveTimeStampSec, receiveTimeStampUSec, leap, precision) are passed to NTPD, and valid is cleared and count is bumped.

    +

    If not set, count is bumped.

    Operation mode=1

    -

    When the poll-method of the driver is called, the valid-flag of the shared memory-segment is checked:

    -

    If set, the count-field of the record is remembered, and the values in the record (clockTimeStampSec, clockTimeStampUSec, receiveTimeStampSec, receiveTimeStampUSec, leap, precision) are read. Then, the remembered count is compared to the count now in the record. If both are equal, the values read from the record are passed to ntp. If they differ, another process has modified the record while it was read out (was not able to produce this case), and failure is reported to ntp. The valid flag is cleared.

    -

    If not set, a timeout is reported to ntp, nothing else happend

    -

    Fudge Factors

    +

    Each second, valid in the shared memory-segment is checked:

    +

    If set, the count field of the record is remembered, and the values in the record (clockTimeStampSec, clockTimeStampUSec, receiveTimeStampSec, receiveTimeStampUSec, leap, precision) are read. Then, the remembered count is compared to current value of count now in the record. If both are equal, the values read from the record are passed to NTPD. If they differ, another process has modified the record while it was read out (was not able to produce this case), and failure is reported to NTPD. The valid flag is cleared and count is bumped.

    +

    If not set, count is bumped

    + +

    Mode-independent post-processing

    +After the time stamps have been successfully plucked from the SHM +segment, some sanity checks take place: +
      +
    • The receive time stamp of the SHM data must be in the last 5 + seconds before the time the data is processed. This helps in weeding + out stale data. +
    • If the absolute difference between remote and local clock + exceeds the limit (either time2 or the default of 4hrs), then + the sample is discarded. This check is disabled when flag1 is + set to 1. +
    + +

    GPSD

    + +GPSD +knows how to talk to many GPS devices. +It can work with NTPD through the SHM driver. +

    +The GPSD man page suggests setting minpoll and maxpoll to 4. +That was an attempt to reduce jitter. +The SHM driver was fixed (ntp-4.2.5p138) to collect data each second rather than +once per polling interval so that suggestion is no longer reasonable. +

    + Note: The GPSD client driver (type 46) uses the GPSD + client protocol to connect and talk to GPSD, but using the + SHM driver is the ancient way to have GPSD talk to NTPD. There + are some tricky points when using the SHM interface to interface + with GPSD, because GPSD will use two SHM clocks, one for the + serial data stream and one for the PPS information when + available. Receivers with a loose/sloppy timing between PPS and serial data + can easily cause trouble here because NTPD has no way to join the two + data streams and correlate the serial data with the PPS events. +

    +

    + +

    Clockstats

    +If flag4 is set when the driver is polled, a clockstats record is written. +The first 3 fields are the normal date, time, and IP address common to all clockstats records. +

    +The 4th field is the number of second ticks since the last poll. +The 5th field is the number of good data samples found. The last 64 will be used by NTPD. +The 6th field is the number of sample that didn't have valid data ready. +The 7th field is the number of bad samples. +The 8th field is the number of times the the mode 1 info was update while NTPD was trying to grab a sample. +

    + +Here is a sample showing the GPS reception fading out: +

    +54364 84927.157 127.127.28.0  66  65   1   0   0
    +54364 84990.161 127.127.28.0  63  63   0   0   0
    +54364 85053.160 127.127.28.0  63  63   0   0   0
    +54364 85116.159 127.127.28.0  63  62   1   0   0
    +54364 85180.158 127.127.28.0  64  63   1   0   0
    +54364 85246.161 127.127.28.0  66  66   0   0   0
    +54364 85312.157 127.127.28.0  66  50  16   0   0
    +54364 85375.160 127.127.28.0  63  41  22   0   0
    +54364 85439.155 127.127.28.0  64  64   0   0   0
    +54364 85505.158 127.127.28.0  66  36  30   0   0
    +54364 85569.157 127.127.28.0  64   0  64   0   0
    +54364 85635.157 127.127.28.0  66   0  66   0   0
    +54364 85700.160 127.127.28.0  65   0  65   0   0
    +
    + +

    The 'mode' word

    + +

    + Some aspects of the driver behavior can be adjusted by setting bits of + the 'mode' word in the server configuration line:
    +   server 127.127.28.x mode Y +

    + + + + + + + + + + + + + + + + + + + + + + +
    mode word bits and bit groups
    BitDecHexMeaning
    011The SHM segment is private (mode 0600). This is the fixed + default for clock units 0 and 1; clock units >1 are mode + 0666 unless this bit is set for the specific unit.
    1-31--reserved -- do not use
    + +

    Fudge Factors

    time1 time
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    time2 time -
    Not used by this driver. +
    Maximum allowed difference between remote and local + clock, in seconds. Values <1.0 or >86400.0 are ignored, and the + default value of 4hrs (14400s) is used instead. See also flag 1.
    stratum number
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    refid string
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default SHM.
    flag1 0 | 1 -
    Not used by this driver. +
    Skip the difference limit check if set. Useful + for systems where the RTC backup cannot keep the time over + long periods without power and the SHM clock must be able + to force long-distance initial jumps. Check the + difference limit if cleared (default).
    flag2 0 | 1
    Not used by this driver.
    flag3 0 | 1
    Not used by this driver.
    flag4 0 | 1 -
    Not used by this driver. -

    Additional Information

    -

    Reference Clock Drivers

    +
    If flag4 is set, clockstats records will be written when the driver is polled.
    + +

    Public vs. Private SHM segments

    + +

    The driver attempts to create a shared memory segment with an + identifier depending on the unit number. This identifier (which can be + a numeric value or a string) clearly depends on the method used, which + in turn depends on the host operating system:

    + +
      +
    • + Windows uses a file mapping to the page file with the + name 'Global\NTPu' for public accessible + mappings, where u is the clock unit. Private / + non-public mappings are created as + 'Local\NTPu'. +

      + Public access assigns a NULL DACL to the memory mapping, while + private access just uses the default DACL of the process creating + the mapping. +

      +
    • +
    • + SYSV IPC creates a shared memory segment with a key value + of 0x4E545030 + u, where u is again + the clock unit. (This value could be hex-decoded as 'NTP0', + 'NTP1',..., with funny characters for units > 9.) +

      + Public access means a permission set of 0666, while private access + creates the mapping with a permission set of 0600. +

      +
    • +
    + +

    There's no support for POSIX shared memory yet.

    + +

    NTPD is started as root on most POSIX-like operating systems + and uses the setuid/setgid system API to run under reduced rights once + the initial setup of the process is done. One consequence out of this + is that the allocation of SHM segments must be done early during the + clock setup. The actual polling of the clock is done as the run-time + user; deferring the creation of the SHM segment to this point will + create a SHM segment owned by the runtime-user account. The internal + structure of NTPD does not permit the use of a fudge flag if + this is to be avoided; this is the reason why a mode bit is used for + the configuration of a public segment. +

    + +

    When running under Windows, the chosen user account must be able to + create a SHM segment in the global object name space for SHM clocks with + public access. Otherwise the session isolation used by Windows kernels + after WinXP will get into the way if the client program does not run in + the same session. +

    + +

    Additional Information

    +

    Reference Clock Drivers

    +
    - \ No newline at end of file + + diff --git a/contrib/ntp/html/drivers/driver29.html b/contrib/ntp/html/drivers/driver29.html index 479978f8f..4939d8012 100644 --- a/contrib/ntp/html/drivers/driver29.html +++ b/contrib/ntp/html/drivers/driver29.html @@ -4,15 +4,27 @@ - Trimble Palisade Receiver + Trimble Palisade and Thunderbolt Receivers -

    Trimble Palisade Receiver +

    Trimble Palisade and Thunderbolt Receivers +

    Last update: + 21-Oct-2010 23:44 + UTC


    + + + + + +

    gif

    +
    +

    jpg

    +

    Synopsis

    @@ -50,12 +62,20 @@ + + + +
    9600 baud, 8-bits, 1-stop, odd parity
    +
    + Serial I/O (Thunderbolt):
    +
    9600 baud, 8-bits, 1-stop, no parity

    Description

    The refclock_palisade driver supports Trimble Navigation's Palisade Smart Antenna GPS receiver.
    Additional software and information about the Palisade GPS is available from: http://www.trimble.com/oem/ntp.
    Latest NTP driver source, executables and documentation is maintained at: ftp://ftp.trimble.com/pub/ntp

    This documentation describes version 7.12 of the GPS Firmware and version 2.46 (July 15, 1999) and later, of the driver source.
     

    +

    This documentation describes version 1 of the Thunderbolt Receiver Firmware, no tests have been made on further firmwares, please read "Notes on the Thunderbolt Receiver's Firmware" at the end of this documentation for more information.

    Operating System Compatibility

    The Palisade driver has been tested on the following software and hardware platforms:
     
    @@ -97,7 +117,8 @@ 20 us -
    +

    + Attention: Thunderbolt Receiver has not being tested on the previous software and hardware plataforms.

    GPS Receiver

    The Palisade GPS receiver is an 8-channel smart antenna, housing the GPS receiver, antenna and interface in a single unit, and is designed for rooftop deployment in static timing applications.

    Palisade generates a PPS synchronized to UTC within +/- 100 ns.  The Palisade's external event input with 40 nanosecond resolution is utilized by the Palisade NTP driver for asynchronous precision time transfer.

    @@ -199,6 +220,19 @@ # and set flag2 to turn off event polling.
    fudge 127.127.29.0 flag2 1
    #------------------------------------------------------------------------------
     

    + +

    Thunderbolt NTP Configuration file

    + #------------------------------------------------------------------------------ +

    Configuration without event polling:
    + #------------------------------------------------------------------------------
    + # The Primary reference
    + server 127.127.29.0 mode 2 # Trimble Thunderbolt GPS (Stratum 1).
    + # Set packet delay
    + fudge 127.127.29.0 time1 0.020
    + # and set flag2 to turn off event polling.
    + fudge 127.127.29.0 flag2 1
    + #------------------------------------------------------------------------------
     

    + Currently the Thunderbolt mode doesn't support event polling, the reasons are explained on the "Notes on the Thunderbolt Receiver's Firmware" section at the end of this documentation.

    Time Transfer and Polling

    Time transfer to the NTP host is performed via the Palisade's comprehensive time packet output. The time packets are output once per second, and whenever an event timestamp is requested.

    The driver requests an event time stamp at the end of each polling interval, by pulsing the RTS (request to send) line on the serial port. The Palisade GPS responds with a time stamped event packet.

    @@ -235,7 +269,7 @@

    Mode Parameter

    mode number -
    The mode parameter to the server command specifies the specific hardware this driver is for. The default is 0 for a normal Trimble Palisade. The only other option at this time is 1 for a Endrun Praecis in Trimble emulation mode. +
    The mode parameter to the server command specifies the specific hardware this driver is for. The default is 0 for a normal Trimble Palisade. The other options are 1 for an Endrun Praecis in Trimble emulation mode, and 2 for the Trimble Thunderbolt GPS Disciplined Clock Receiver.

    DEFINEs

    The following constants are defined in the driver source code. These defines may be modified to improve performance or adapt to new operating systems.
      @@ -369,6 +403,7 @@ +

    Leap Second Flag Definition:

    Bit 0:  (1) UTC Time is available
    Bits 1 - 3: Undefined
    Bit 4:  (1) Leap Scheduled: Leap second pending asserted by GPS control segment.
    Bit 5:  (1) Leap Pending: set 24 hours before, until beginning of leap second.
    Bit 6:  (1) GPS Leap Warning: 6 hours before until 6 hours after leap event
    Bit 7:  (1) Leap In Progress. Only set during the leap second. @@ -576,6 +611,281 @@ +

    Thunderbolt Timing packets Data Format

    + Thunderbolt can output 2 synchronous packets. +

    Primary Timing Packet - 0x8FAB

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    ByteBitItemTypeValueDescription
    0SubcodeUINT80xAB
    1-4Time of WeekUINT32GPS seconds of week
    5-6Week NumberUINT16GPS Week Number
    7-8UTC OffsetSINT16UTC Offset (seconds)
    9
    0
    1
    2
    3
    4
    Timing FlagBit field
    0 or 1
    0 or 1
    0 or 1
    0 or 1
    0 or 1
    GPS Time or UTC Time
    GPS PPS or UTC PPS
    time is set or time is not set
    have UTC info or no UTC info
    Time from GPS or time from user
    10SecondsUINT80-59(60 for UTC leap second event)
    11MinutesUINT80-59Minutes of Hour
    12HoursUINT80-23Hour of Day
    13Day of MonthUINT81-31Day of Month
    14MonthUINT81-12Month of Year
    15-16YearUINT16Four digits of Year (e.g. 1998)
    +
    +

    Supplemental Timing Packet - 0x8FAC

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    ByteBitItemTypeValueDescription
    0SubcodeUINT80xAC
    1Receiver ModeUINT8
    0
    1
    2
    3
    4
    5
    6
    Automatic (2D/3D)
    Single Satellite (Time)
    Horizontal (2D)
    Full Position (3D)
    DGPS Reference
    Clock Hold (2D)
    Overdetermined Clock
    2Disciplining ModeUINT8
    0
    1
    2
    3
    4
    5
    6
    Normal
    Power-Up
    Auto Holdover
    Manual Holdover
    Recovery
    Not Used
    Disciplining disabled
    3Self-Survey ProgressUINT 80-100%
    4-7Holdover DurationUINT 32seconds
    8-9
    0
    1
    2
    3
    4
    Critical AlarmsUINT16Bit field
    ROM checksum error
    RAM check has failed
    Power supply failure
    FPGA check has failed
    Oscillator control voltage at rail
    10-11
    0
    1
    2
    3
    4
    5
    6
    Minor AlarmsUINT16Bit field
    Normal
    Power-Up
    Auto Holdover
    Manual Holdover
    Recovery
    Not Used
    Disciplining disabled
    12GPS Decoding StatusUINT8
    0
    1
    3
    8
    9
    0x0A
    0x0B
    0x0C
    0x10
    Doing fixes
    Don t have GPS time
    PDOP is too high
    No usable sats
    Only 1 usable sat
    Only 2 usable sats
    Only 3 usable sats
    The chosen sat is unusable
    TRAIM rejected the fix
    13Disciplining ActivityUINT8
    0
    1
    2
    3
    4
    5
    6
    7
    8
    Phase locking
    Oscillator warming up
    Frequency locking
    Placing PPS
    Initializing loop filter
    Compensating OCXO
    Inactive
    Not used
    Recovery mode
    14Spare Status 1UINT80
    15Spare Status 2UINT80
    16-19PPS OffsetSingleEstimate of UTC/GPS offset (ns)
    20-2310 MHz OffsetSingleEstimate of UTC/GPS offset (ns)
    24-27DAC ValueUINT32Offset binary (0x00 - 0xFFFFF)
    28-31DAC VoltageSingleVolts
    32-35TemperatureSingledegrees C
    36-43LatitudeDoubleradians
    44-51LongitudeDoubleradians
    52-59AltitudeDoubleMeters
    60-67SpareFor Future Expantion
    +

    Pinouts

    The following connections are required when connecting Palisade with a host:
     
     
    @@ -762,15 +1072,22 @@
    + +

    Notes on the Thunderbolt Receiver's Firmware

    + + The support for Thunderbolt Receiver in the palisade driver doesn't support (for now) event-polling, the reason is that the Thunderbolt receiver the patch is written for doesn't support time-on-request, so you just have to sit there and wait for the time to arrive with the PPS. We tried to contact Trimble because there's presumably a firmware update that support it, but we didn't have much luck. +Here is a link explaining the situation:

    +https://lists.ntp.isc.org/pipermail/hackers/2006-April/002216.html


    Questions or Comments:
    Sven Dietrich
    Trimble Navigation Ltd.

    -

    (last updated July 29, 1999)

    + Fernando P. Hauscarriaga
    +

    (last updated January 15, 2007)


    ; - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver3.html b/contrib/ntp/html/drivers/driver3.html index e5a06be55..457e5a22b 100644 --- a/contrib/ntp/html/drivers/driver3.html +++ b/contrib/ntp/html/drivers/driver3.html @@ -1,28 +1,29 @@ - - - - - - PSTI/Traconex 1020 WWV/WWVH Receiver - - - - -

    PSTI/Traconex 1020 WWV/WWVH Receiver

    -
    -

    Synopsis

    -

    Address: 127.127.3.u
    - Reference ID: WWV
    - Driver ID: WWV_PST
    - Serial Port: /dev/wwvu; 9600 baud, 8-bits, no parity
    - Features: tty_clk

    -

    Description

    -

    This driver supports the PSTI 1010 and Traconex 1020 WWV/WWVH Receivers. No specific claim of accuracy is made for these receiver, but actual experience suggests that 10 ms would be a conservative assumption.

    -

    The dipswitches should be set for 9600 bps line speed, 24-hour day-of-year format and UTC time zone. Automatic correction for DST should be disabled. It is very important that the year be set correctly in the DIP-switches; otherwise, the day of year will be incorrect after 28 April of a normal or leap year. As the there are only four dipswitches to set the year and the base value of zero correspondes to 1986, years beyond 2001 recycle with the value of zero corresponding to 2002. The propagation delay DIP-switches should be set according to the distance from the transmitter for both WWV and WWVH, as described in the instructions. While the delay can be set only to within 11 ms, the fudge time1 parameter can be used for vernier corrections.

    -

    Using the poll sequence QTQDQM, the response timecode is in three sections totalling 50 ASCII printing characters, as concatenated by the driver, in the following format:

    -
    +
    +
    +
    +PSTI/Traconex 1020 WWV/WWVH Receiver
    +
    +
    +
    +

    PSTI/Traconex 1020 WWV/WWVH Receiver

    +

    Author: David L. Mills (mills@udel.edu)
    +Last update: + 11-Sep-2010 05:56 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.3.u
    + Reference ID: WWV
    + Driver ID: WWV_PST
    + Serial Port: /dev/wwvu; 9600 baud, 8-bits, no parity
    + Features: tty_clk

    +

    Description

    +

    This driver supports the PSTI 1010 and Traconex 1020 WWV/WWVH Receivers. No specific claim of accuracy is made for these receiver, but actual experience suggests that 10 ms would be a conservative assumption.

    +

    The dipswitches should be set for 9600 bps line speed, 24-hour day-of-year format and UTC time zone. Automatic correction for DST should be disabled. It is very important that the year be set correctly in the DIP-switches; otherwise, the day of year will be incorrect after 28 April of a normal or leap year. As the there are only four dipswitches to set the year and the base value of zero correspondes to 1986, years beyond 2001 recycle with the value of zero corresponding to 2002. The propagation delay DIP-switches should be set according to the distance from the transmitter for both WWV and WWVH, as described in the instructions. While the delay can be set only to within 11 ms, the fudge time1 parameter can be used for vernier corrections.

    +

    Using the poll sequence QTQDQM, the response timecode is in three sections totalling 50 ASCII printing characters, as concatenated by the driver, in the following format:

    +
     ahh:mm:ss.fffs<cr> yy/dd/mm/ddd<cr>
     frdzycchhSSFTttttuuxx<cr>
     
    @@ -45,32 +46,31 @@ T = transmitter (C = WWV, H = WWVH)
     tttt = time since last update (0000 = minutes)
     uu = flush character (03 = ^c)
     xx = 94 (unknown)
    -

    The alarm condition is indicated by other than 8 at a, which occurs during initial synchronization and when received signal is lost for an extended period; unlock condition is indicated by other than 0000 in the tttt subfield.

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWV. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - - - \ No newline at end of file +

    The alarm condition is indicated by other than 8 at a, which occurs during initial synchronization and when received signal is lost for an extended period; unlock condition is indicated by other than 0000 in the tttt subfield.

    +

    Monitor Data

    +

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    +

    Fudge Factors

    +
    +
    time1 time +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. +
    time2 time +
    Not used by this driver. +
    stratum number +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. +
    refid string +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWV. +
    flag1 0 | 1 +
    Not used by this driver. +
    flag2 0 | 1 +
    Not used by this driver. +
    flag3 0 | 1 +
    Not used by this driver. +
    flag4 0 | 1 +
    Not used by this driver. +
    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + + diff --git a/contrib/ntp/html/drivers/driver30.html b/contrib/ntp/html/drivers/driver30.html index d29dbcfc2..ddf9b9488 100644 --- a/contrib/ntp/html/drivers/driver30.html +++ b/contrib/ntp/html/drivers/driver30.html @@ -11,6 +11,9 @@

    Motorola Oncore GPS receiver

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.30.u
    @@ -80,4 +83,4 @@ - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver31.html b/contrib/ntp/html/drivers/driver31.html index aff093c52..a329faf84 100644 --- a/contrib/ntp/html/drivers/driver31.html +++ b/contrib/ntp/html/drivers/driver31.html @@ -11,6 +11,9 @@

    Rockwell Jupiter GPS receiver

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.31.u
    @@ -55,4 +58,4 @@ -= \ No newline at end of file += diff --git a/contrib/ntp/html/drivers/driver32.html b/contrib/ntp/html/drivers/driver32.html index 947924841..8cb810a60 100644 --- a/contrib/ntp/html/drivers/driver32.html +++ b/contrib/ntp/html/drivers/driver32.html @@ -10,6 +10,9 @@

    Chrono-log K-series WWVB receiver

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.32.u
    @@ -30,9 +33,8 @@ L - \n (newline) Z - timestamp indicator hh:mm:ss - local time

    - Last modified: Sun Feb 14 11:57:27 EST 1999
    - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver33.html b/contrib/ntp/html/drivers/driver33.html index f50dfb632..6142f5307 100644 --- a/contrib/ntp/html/drivers/driver33.html +++ b/contrib/ntp/html/drivers/driver33.html @@ -10,6 +10,9 @@

    Dumb Clock

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.33.u
    @@ -26,10 +29,8 @@ hh:mm:ss - local time C - \r (carriage return) L - \n (newline)

    -
    - Last modified: Sun Feb 14 12:07:01 EST 1999
    - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver34.html b/contrib/ntp/html/drivers/driver34.html index a98fad89c..65ce81948 100644 --- a/contrib/ntp/html/drivers/driver34.html +++ b/contrib/ntp/html/drivers/driver34.html @@ -1,117 +1,82 @@ - + + Ultralink Clock - -

    Ultralink Clock

    + + + + +

    Ultralink Clock

    +

    Last update: + 31-Dec-2007 19:43 + UTC


    Synopsis

    - Address: 127.127.34.u
    - Reference ID: WWVB
    - Driver ID: ULINK
    - Serial Port: /dev/wwvbu; 9600 bps, 8-bits, no parity
    -
    - Features: (none) +

    Address: 127.127.34.u
    + Reference ID: WWVB
    + Driver ID: ULINK
    + Serial Port: /dev/wwvbu; 9600 bps, 8-bits, no parity
    + Features: (none)

    Description

    -

    This driver supports the Ultralink Model 325 (replacement for Model 320) RS-232 powered WWVB receiver. PDF specs available on http://www.ulio.com/. This driver also supports the Model 320, 330,331,332 decoders in both polled or continous time code mode.
    - Leap second and quality are supported.

    -

    Most of this code is originally from refclock_wwvb.c with thanks. Any mistakes are mine. Any improvements are welcome.

    -
    -
      The Model 325 timecode format is:
    - 
    -   <cr><lf>RQ_1C00LYYYY+DDDUTCS_HH:MM:SSL+5
    - 
    -  where:
    - 
    -  R = Signal readability indicator, ranging from R1 to R5  
    -  Q	R1 is unreadable, R5 is best reception
    -  _ = Space
    -  1 = prev. received data bit, values: 0, 1 ,M or ? unknown
    -  C = Signal reception from (C)olorado or (H)awaii
    -  0 = Hours since last WWVB time and flag code update, values
    -  0	00 to 99 (hopefully always 00)
    -  L = HEX A5 if receiver is locked to WWVB, Space if not
    -  YYYY = Year from 2000 to 2099
    -  + = '+' if current year is a leap year, else ' '
    -  DDD = current day in the year from 1 to 365/366
    -  UTC = timezone (always UTC)
    -  S = Daylight savings indicator, (S)TD, (D)ST, (O) transition
    -      into DST, (I) transition out of DST
    -  _ = Space
    -  HH = UTC hour 0 to 23
    -  : = Time delimiter, ':' if synced, Space if not
    -  MM = Minutes of current hour from 0 to 59
    -  : = Time delimiter, ':' if synced, Space if not
    -  SS = Seconds of current minute from 0 to 59
    -  mm = 10's milliseconds of the current second from 00 to 99
    -  L  = Leap second pending at end of month, (I)nsert, (D)elete
    -       or Space
    -  +5 = UT1 correction, +/- .1 sec increments
    - 
    +

    This driver supports the Ultralink Model 325 (replacement for Model 320) RS-232 powered WWVB receiver. PDF specs available on http://www.ulio.com/. This driver also supports the Model 320, 330,331,332 decoders in both polled or continous time code mode.Leap second and quality are supported. Most of this code is originally from refclock_wwvb.c with thanks. Any mistakes are mine. Any improvements are welcome.

    +

    Model 325 timecode format

    +

    <cr><lf>RQ_1C00LYYYY+DDDUTCS_HH:MM:SSL+5

    +

    R = Signal readability indicator, ranging from R1 to R5 Q R1 is unreadable, R5 is best reception
    + _ = Space
    + 1 = prev. received data bit, values: 0, 1 ,M or ? unknown + C = Signal reception from (C)olorado or (H)awaii 0 = Hours since last WWVB time and flag code update, values 0 00 to 99 (hopefully always 00)
    + L = HEX A5 if receiver is locked to WWVB, Space if not
    + YYYY = Year from 2000 to 2099
    + + = '+' if current year is a leap year, else ' '
    + DDD = current day in the year from 1 to 365/366
    + UTC = timezone (always UTC)
    + S = Daylight savings indicator, (S)TD, (D)ST, (O) transition into DST, (I) transition out of DST
    + _ = Space
    + HH = UTC hour 0 to 23
    + : = Time delimiter, ':' if synced, Space if not
    + MM = Minutes of current hour from 0 to 59
    + : = Time delimiter, ':' if synced, Space if not
    + SS = Seconds of current minute from 0 to 59
    + mm = 10's milliseconds of the current second from 00 to 99
    + L = Leap second pending at end of month, (I)nsert, (D)elete or Space
    + +5 = UT1 correction, +/- .1 sec increments

    Note that Model 325 reports a very similar output like Model 33X series. The driver for this clock is similar to Model 33X behavior. On a unmodified new ULM325 clock, the polling flag (flag1 =1) needs to be set.

    -
    -
      The Model 320 timecode format is:
    - 
    -   <cr><lf>SQRYYYYDDD+HH:MM:SS.mmLT<cr>
    - 
    -  where:
    - 
    -  S = 'S' -- sync'd in last hour, '0'-'9' - hours x 10 since last update, else '?'
    -  Q = Number of correlating time-frames, from 0 to 5
    -  R = 'R' -- reception in progress, 'N' -- Noisy reception, ' ' -- standby mode
    -  YYYY = year from 1990 to 2089
    -  DDD = current day from 1 to 366
    -  + = '+' if current year is a leap year, else ' '
    -  HH = UTC hour 0 to 23
    -  MM = Minutes of current hour from 0 to 59
    -  SS = Seconds of current minute from 0 to 59
    -  mm = 10's milliseconds of the current second from 00 to 99
    -  L  = Leap second pending at end of month -- 'I' = inset, 'D'=delete
    -  T  = DST <-> STD transition indicators
    - 
    -

    Note that this driver does not do anything with the T flag.

    -

    The M320 also has a 'U' command which returns UT1 correction information. It is not used in this driver.

    -
    -
      The Model 33x timecode format is:
    -
    -    S9+D 00 YYYY+DDDUTCS HH:MM:SSl+5
    -
    -  Where:
    -
    -  S =    sync indicator S insync N not in sync
    -         the sync flag is WWVB decoder sync
    -         nothing to do with time being correct
    -  9+ =   signal level 0 thru 9+ If over 9 indicated as 9+
    -  D  =   data bit ( fun to watch but useless ;-)
    -  space
    -  00 =   hours since last GOOD WWVB frame sync
    -  space
    -  YYYY = current year
    -  +  =   leap year indicator
    -  DDD =  day of year
    -  UTC =  timezone (always UTC)
    -  S  =   daylight savings indicator
    -  space
    -  HH  =  hours
    -  :  =   This is the REAL in sync indicator (: = insync)
    -  MM  =  minutes
    -  :  =   : = in sync ? = NOT in sync
    -  SS  =  seconds
    -  L  =   leap second flag
    -  +5 =   UT1 correction (sign + digit ))
    - 
    -

    This driver ignores UT1 correction,DST indicator,Leap year and signal level.

    -
    +

    Model 320 timecode format

    +

    <cr><lf>SQRYYYYDDD+HH:MM:SS.mmLT<cr>

    +

    S = 'S' -- sync'd in last hour, '0'-'9' - hours x 10 since last update, else '?'
    + Q = Number of correlating time-frames, from 0 to 5
    + R = 'R' -- reception in progress,'N' -- Noisy reception, ' ' -- standby mode
    + YYYY = year from 1990 to 2089
    + DDD = current day from 1 to 366 + = '+' if current year is a leap year, else ' '
    + HH = UTC hour 0 to 23
    + MM = Minutes of current hour from 0 to 59
    + SS = Seconds of current minute from 0 to 59
    + mm = 10's milliseconds of the current second from 00 to 99
    + L = Leap second pending at end of month -- 'I' = insert, 'D'=delete
    + T = DST <-> STD transition indicators

    +

    Note that this driver does not do anything with the T flag. The M320 also has a 'U' command which returns UT1 correction information. It is not used in this driver.

    +

    Model 33x timecode format

    +

    S9+D 00 YYYY+DDDUTCS HH:MM:SSl+5

    +

    S = sync indicator S insync N not in sync the sync flag is WWVB decoder sync nothing to do with time being correct

    +

    9+ = signal level 0 thru 9+ If over 9 indicated as 9
    + D = data bit (fun to watch but useless ;-) space
    + 00 = hours since last GOOD WWVB frame sync space
    + YYYY = current year + = leap year indicator
    + DDD = day of year
    + UTC = timezone (always UTC)
    + S = daylight savings indicator space
    + HH = hours : = This is the REAL in sync indicator (: = insync)
    + MM = minutes : = : = in sync ? = NOT in sync
    + SS = seconds
    + L = leap second flag
    + +5 = UT1 correction (sign + digit ))

    +

    This driver ignores UT1 correction, DST indicator,Leap year and signal level.

    Fudge factors

    flag1 polling enable (1=poll 0=no poll)


    -
    mail
    - Last modified: Mon Mar 8 10:12:08 PST 2004 -
    - - - - - \ No newline at end of file + + + diff --git a/contrib/ntp/html/drivers/driver35.html b/contrib/ntp/html/drivers/driver35.html index 78a0881fc..3ded63feb 100644 --- a/contrib/ntp/html/drivers/driver35.html +++ b/contrib/ntp/html/drivers/driver35.html @@ -10,6 +10,9 @@

    Conrad parallel port radio clock

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.35.u
    @@ -45,4 +48,4 @@ - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver36.html b/contrib/ntp/html/drivers/driver36.html index 72fa665b4..2b253245c 100644 --- a/contrib/ntp/html/drivers/driver36.html +++ b/contrib/ntp/html/drivers/driver36.html @@ -1,146 +1,150 @@ - - - - - - Radio WWV/H Audio Demodulator/Decoder - - - - -

    Radio WWV/H Audio Demodulator/Decoder

    -
    -

    Synopsis

    - Address: 127.127.36.u
    - Reference ID: WVf or WHf
    - Driver ID: WWV_AUDIO
    - Autotune Port: /dev/icom; 1200/9600 baud, 8-bits, no parity
    - Audio Device: /dev/audio and /dev/audioctl -

    Description

    - This driver synchronizes the computer time using data encoded in shortwave radio transmissions from NIST time/frequency stations WWV in Ft. Collins, CO, and WWVH in Kauai, HI. Transmissions are made continuously on 2.5, 5, 10 and 15 MHz from both stations and on 20 MHz from WWV. An ordinary shortwave receiver can be tuned manually to one of these frequencies or, in the case of ICOM receivers, the receiver can be tuned automatically by the driver as propagation conditions change throughout the day and season. The performance of this driver when tracking one of the stations is ordinarily better than 1 ms in time with frequency drift less than 0.1 PPM when not tracking any station.

    The demodulation and decoding algorithms used by this driver are based on a machine language program developed for the TAPR DSP93 DSP unit, which uses the TI 320C25 DSP chip. The analysis, design and performance of the program running on this unit is described in: Mills, D.L. A precision radio clock for WWV transmissions. Electrical Engineering Report 97-8-1, University of Delaware, August 1997, 25 pp. Available from www.eecis.udel.edu/~mills/reports.htm. For use in this driver, the original program was rebuilt in the C language and adapted to the NTP driver interface. The algorithms have been modified to improve performance, especially under weak signal conditions and to provide an automatic frequency and station selection feature.

    -

    This driver incorporates several features in common with other audio drivers such as described in the Radio CHU Audio Demodulator/Decoder and the IRIG Audio Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    -

    The WWV signal format is described in NIST Special Publication 432 (Revised 1990). It consists of three elements, a 5-ms, 1000-Hz pulse, which occurs at the beginning of each second, a 800-ms, 1000-Hz pulse, which occurs at the beginning of each minute, and a pulse-width modulated 100-Hz subcarrier for the data bits, one bit per second. The WWVH format is identical, except that the 1000-Hz pulses are sent at 1200 Hz. Each minute encodes nine BCD digits for the time of century plus seven bits for the daylight savings time (DST) indicator, leap warning indicator and DUT1 correction.

    -

    Program Architecture

    -

    As in the original program, the clock discipline is modelled as a Markov process, with probabilistic state transitions corresponding to a conventional clock and the probabilities of received decimal digits. The result is a performance level which results in very high accuracy and reliability, even under conditions when the minute beep of the signal, normally its most prominent feature, can barely be detected by ear using a communications receiver.

    -

    The analog audio signal from the shortwave radio is sampled at 8000 Hz and converted to digital representation. The 1000/1200-Hz pulses and 100-Hz subcarrier are first separated using two IIR filters, a 600-Hz bandpass filter centered on 1100 Hz and a 150-Hz lowpass filter. The minute synch pulse is extracted using an 800-ms synchronous matched filter and pulse grooming logic which discriminates between WWV and WWVH signals and noise. The second synch pulse is extracted using a 5-ms FIR matched filter and 8000-stage comb filter.

    -

    The phase of the 100-Hz subcarrier relative to the second synch pulse is fixed at the transmitter; however, the audio stage in many radios affects the phase response at 100 Hz in unpredictable ways. The driver adjusts for each radio using two 170-ms synchronous matched filters. The I (in-phase) filter is used to demodulate the subcarrier envelope, while the Q (quadrature-phase) filter is used in a tracking loop to discipline the codec sample clock and thus the demodulator phase.

    -

    A bipolar data signal is determined from the matched filter I and Q channels using a pulse-width discriminator. The discriminator samples the I channel at 15 ms (n), 200 ms (s1) and 500 ms (s0), and the envelope (RMS I and Q channels) at 200 ms (e1) and the end of the second (e0). The bipolar data signal is expressed s1 - 2s0 - n. Note that, since the signals s0 and s1 include the noise n, this term cancels out. The data bit SNR is calculated as 20 log10(e1 / e0). If the driver has not synchronized to the minute pulse, or if the data bit amplitude e1 or SNR are below thresholds, the bit is considered invalid and the bipolar signal is forced to zero.

    -

    The bipolar signal is exponentially averaged in a set of 60 accumulators, one for each second, to determine the semi-static miscellaneous bits, such as DST indicator, leap second warning and DUT1 correction. In this design a data average value larger than a positive threshold is interpreted as +1 (hit) and a value smaller than a negative threshold as a -1 (miss). Values between the two thresholds, which can occur due to signal fades, are interpreted as an erasure and result in no change of indication.

    -

    The BCD digit in each digit position of the timecode is represented as four data bits. The bits are correlated with the bits corresponding to each of the valid decimal digits in this position. If any of the four bits are invalid, the correlated value for all digits in this position is assumed zero. In either case, the values for all digits are exponentially averaged in a likelihood vector associated with this position. The digit associated with the maximum over all averaged values then becomes the maximum likelihood selection for this position and the ratio of the maximum over the next lower value represents the digit SNR.

    -

    The decoding matrix contains nine row vectors, one for each digit position. Each row vector includes the maximum likelihood digit, likelihood vector and other related data. The maximum likelihood digit for each of the nine digit positions becomes the maximum likelihood time of the century. A built-in transition function implements a conventional clock with decimal digits that count the minutes, hours, days and years, as corrected for leap seconds and leap years. The counting operation also rotates the likelihood vector corresponding to each digit as it advances. Thus, once the clock is set, each clock digit should correspond to the maximum likelihood digit as transmitted.

    -

    Each row of the decoding matrix also includes a compare counter and the most recently determined maximum likelihood digit. If a digit likelihood exceeds the decision level and compares with previous digits for a number of successive minutes in any row, the maximum likelihood digit replaces the clock digit in that row. When this condition is true for all rows and the second epoch has been reliably determined, the clock is set (or verified if it has already been set) and delivers correct time to the integral second. The fraction within the second is derived from the logical master clock, which runs at 8000 Hz and drives all system timing functions.

    -

    The logical master clock is derived from the audio codec clock. Its frequency is disciplined by a frequency-lock loop (FLL) which operates independently of the data recovery functions. At averaging intervals determined by the measured jitter, the frequency error is calculated as the difference between the most recent and the current second epoch divided by the interval. The sample clock frequency is then corrected by this amount. When first started, the frequency averaging interval is eight seconds, in order to compensate for intrinsic codec clock frequency offsets up to 125 PPM. Under most conditions, the averaging interval doubles in stages from the initial value to over 1000 seconds, which results in an ultimate frequency precision of 0.125 PPM, or about 11 ms/day.

    -

    It is important that the logical clock frequency is stable and accurately determined, since in most applications the shortwave radio will be tuned to a fixed frequency where WWV or WWVH signals are not available throughout the day. In addition, in some parts of the US, especially on the west coast, signals from either or both WWV and WWVH may be available at different times or even at the same time. Since the propagation times from either station are almost always different, each station must be reliably identified before attempting to set the clock.

    -

    Reliable station identification requires accurate discrimination between very weak signals in noise and noise alone. The driver very aggresively soaks up every scrap of signal information, but has to be careful to avoid making pseudo-sense of noise alone. The signal quality metric depends on the minute pulse amplitude and SNR measured in second 0 of the minute, together with the data subcarrier amplitude and SNR measured in second 1. If all four values are above defined thresholds a hit is declared, otherwise a miss. The number of hits declared in the last six minutes by each station represents the high order bits of the metric value, while the current minute pulse amplitude repressents the low order bits. The resulting value is then scaled from zero to 100 for use as a quality indicator. It is used by the autotune function described below and reported in the timecode string.

    -

    Performance

    -

    It is the intent of the design that the accuracy and stability of the indicated time be limited only by the characteristics of the ionospheric propagation medium. Conventional wisdom is that synchronization via the HF medium is good only to a millisecond under the best propagation conditions. The performance of the NTP daemon disciplined by the driver is clearly better than this, even under marginal conditions. Ordinarily, with marginal to good signals and a frequency averaging interval of 1024 s, the frequency is stabilized within 0.1 PPM and the time within 0.5 ms. The frequency stability characteristic is highly important, since the clock may have to free-run for several hours before reacquiring the WWV/H signal.

    -

    The expected accuracy over a typical day was determined using the DSP93 and an oscilloscope and cesium oscillator calibrated with a GPS receiver. With marginal signals and allowing 15 minutes for initial synchronization and frequency compensation, the time accuracy determined from the WWV/H second synch pulse was reliably within 125 ms. In the particular DSP93 used for program development, the uncorrected CPU clock frequency offset was 45.8±0.1 PPM. Over the first hour after initial synchronization, the clock frequency drifted about 1 PPM as the frequency averaging interval increased to the maximum 1024 s. Once reaching the maximum, the frequency wandered over the day up to 1 PPM, but it is not clear whether this is due to the stability of the DSP93 clock oscillator or the changing height of the ionosphere. Once the frequency had stabilized and after loss of the WWV/H signal, the frequency drift was less than 0.5 PPM, which is equivalent to 1.8 ms/h or 43 ms/d. This resulted in a step phase correction up to several milliseconds when the signal returned.

    -

    The measured propagation delay from the WWV transmitter at Boulder, CO, to the receiver at Newark, DE, is 23.5±0.1 ms. This is measured to the peak of the pulse after the second synch comb filter and includes components due to the ionospheric propagation delay, nominally 8.9 ms, communications receiver delay and program delay. The propagation delay can be expected to change about 0.2 ms over the day, as the result of changing ionosphere height. The DSP93 program delay was measured at 5.5 ms, most of which is due to the 400-Hz bandpass filter and 5-ms matched filter. Similar delays can be expected of this driver.

    -

    Program Operation

    The driver begins operation immediately upon startup. It first searches for one or both of the stations WWV and WWVH and attempts to acquire minute synch. This may take some fits and starts, as the driver expects to see several consecutive minutes with good signals and low jitter. If the autotune function is active, the driver will rotate over all five frequencies and both WWV and WWVH stations until at least three good minutes are found.

    When a minute synch candidate has been found, the driver acquires second synch, which can take up to several minutes, depending on signal quality. At the same time the driver accumulates likelihood values for the unit (seconds) digit of the nine digits of the timecode, plus the seven miscellaneous bits included in the WWV/H transmission format. When a good unit digit has been found, the driver accumlates likelihood values for the remaining eight digits of the timecode. When three repetitions of all nine digits have decoded correctly, which normally takes 15 minutes with good signals, and up to 40 minutes when buried in noise, and the second synch has been acquired, the clock is set (or verified) and is selectable to discipline the system clock.

    -

    Once the clock is set, it continues to provide correct timecodes, even if all signals are losst. The time is considered correct as long as the second synch amplitude and SNR are above specified thresholds and jitter is below threshold. As long as the clock is set or verified, the system clock offsets are provided once each minute to the reference clock interface, where they are processed using the same algorithms used with other local reference clocks and remote servers. Using these algorithms, the system clock can in principle be disciplined to a much finer resolution than the 125-ms sample interval would suggest, although the ultimate accuracy is probably limited by propagation delay variations as the ionspheric height varies throughout the day and night.

    -

    The codec clock frequency is disciplined during times when WWV/H signals are available. The algorithm refines the frequency offset using increasingly longer averaging intervals to 1024 s, where the precision is about 0.1 PPM. With good signals, it takes well over two hours to reach this degree of precision; however, it can take many more hours than this in case of marginal signals. Once reaching the limit, the algorithm will follow frequency variations due to temperature fluctuations and ionospheric height variations.

    -

    It may happen as the hours progress around the clock that WWV and WWVH signals may appear alone, together or not at all. When the driver has mitigated which station and frequency is best, it sets the reference identifier to the string WVf for WWV and WHf for WWVH, where f is the frequency in megahertz. If the propagation delays have been properly set with the fudge time1 (WWV) and fudge time2 (WWVH) commands in the configuration file, handover from one station to the other is seamless.

    -

    Once the clock has been set for the first time, it will appear reachable and selectable to discipline the system clock. Operation continues as long as the signal quality from at least one station on at least one frequency is acceptable. A consequence of this design is that, once the clock is set, the time and frequency are disciplined only by the second synch pulse and the clock digits themselves are driven by the clock state machine. If for some reason the state machine drifts to the wrong second, it would never reresynchronize. To protect against this most unlikely situation, if after two days with no signals, the clock is considered unset and resumes the synchronization procedure from the beginning.

    -

    However, as long as the clock has once been set correctly and allowed to converge to the intrinsic codec clock frequency, it will continue to read correctly even during the holdover interval, but with increasing dispersion. Assuming the clock frequency can be disciplined within 1 PPM, it can coast without signals for several days without exceeding the NTP step threshold of 128 ms. During such periods the root dispersion increases at 5 ms per second, which makes the driver appear less likely for selection as time goes on. Eventually, when the dispersion due all causes exceeds 1 s, it is no longer suitable for synchronization.

    -

    To work well, the driver needs a shortwave receiver with good audio response at 100 Hz. Most shortwave and communications receivers roll off the audio response below 250 Hz, so this can be a problem, especially with receivers using DSP technology, since DSP filters can have very fast rolloff outside the passband. Some DSP transceivers, in particular the ICOM 775, have a programmable low frequency cutoff which can be set as low as 80 Hz. However, this particular radio has a strong low frequency buzz at about 10 Hz which appears in the audio output and can affect data recovery under marginal conditions. Although not tested, it would seem very likely that a cheap shortwave receiver could function just as well as an expensive communications receiver.

    -

    Autotune

    -

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a serial port using a level converter such as the CT-17.

    -

    Each ICOM radio is assigned a unique 8-bit ID select code, usually expressed in hex format. To activate the CI-V interface, the mode keyword of the server configuration command specifies a nonzero select code in decimal format. A table of ID select codes for the known ICOM radios is given on the Reference Clock Audio Drivers page. A missing mode keyword or a zero argument leaves the interface disabled.

    -

    If specified, the driver will attempt to open the device /dev/icom and, if successful will activate the autotune function and tune the radio to each operating frequency in turn while attempting to acquire minute synch from either WWV or WWVH. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus or radio is inoperative, the driver quietly gives up with no harm done.

    -

    Once acquiring minute synch, the driver operates as described above to set the clock. However, during seconds 59, 0 and 1 of each minute it tunes the radio to one of the five broadcast frequencies to measure the minute synch pulse amplitude and SNR in second 0 and data pulse amplitude and SNR in second 1 to update the signal metric. In principle, the data pulse in second 58 is usable, but the AGC in most radios is not fast enough for a reliable measurement. Each of the five frequencies are probed in a five-minute rotation to build a database of current propagation conditions for all signals that can be heard at the time. At the end of each probe a mitigation procedure scans the database and retunes the radio to the best frequency and station found. For this to work well, the radio should be set for a fast AGC recovery time. This is most important while tracking a strong signal, which is normally the case, and then probing another frequency, which may have much weaker signals.

    -

    At the end of each probe, the frequency and station with the maximum metric is chosen, with ties going first to the highest frequency and then to WWV in order. A station is considered valid only if the metric is above a specified threshold' if below, the rotating probes continue until a valid station is found.

    -
    -
    -

    Diagnostics

    -

    The autotune process produces diagnostic information along with the timecode. This is very useful for evaluating the performance of the algorithms, as well as radio propagation conditions in general. The message is produced once each minute for each frequency in turn after minute synch has been acquired.

    -

    wwv5 status agc epoch secamp/secsnr datamp/datsnr wwv wwvh

    -

    where the fields after the wwv5 identifier are: status contains status bits, agc audio gain, epoch second epoch, secamp/secsnr second pulse ampliture/SNR, and wwv and wwvh are two sets of fields, one each for WWV and WWVH. Each of the two fields has the format

    -

    ident score metric minamp/minsnr

    -

    where ident encodes the station (WV for WWV, WH for WWVH) and frequency (2, 5, 10, 15 or 20), score 32-bit shift register recording the hits (1) and misses (0) of the last 32 probes (hits and misses enter from the right), metric is described above, and minamp/minsnr minute pulse ampliture/SNR. An example is:

    -

    wwv5 000d 111 5753 3967/20.1 3523/10.2 WV20 bdeff 100 8348/30.0 WH20 0000 1 22/-12.4

    -

    There are several other messages that can occur; these are documented in the source listing.

    -

    Debugging Aids

    -

    The most convenient way to track the driver status is using the ntpq program and the clockvar command. This displays the last determined timecode and related status and error counters, even when the driver is not disciplining the system clock. If the debugging trace feature (-d on the ntpd command line)is enabled, the driver produces detailed status messages as it operates. If the fudge flag 4 is set, these messages are written to the clockstats file. All messages produced by this driver have the prefix wwv for convenient filtering with the Unix grep command.

    -

    Monitor Data

    - - When enabled by the filegen facility, every received timecode is written to the clockstats file in the following format: -

    sq yyyy ddd hh:mm:ss ld du lset agc ident metric errs freq avg
    - s
    synch indicator (? or space) - q quality character (see below) - yyyy Gregorian year - ddd day of year - hh hour of day - mm minute of hour - l leap second warning L - d DST state S, D, I, O
    - dut DUT sign and magnitude - lset minutes since last set - agc audio gain - ident station identifier and frequency - metric signal metric (0-100) - errs data bit errors in last minute - freq codec frequency offset (PPM) - avg frequency averaging interval (s) -

    - The fields beginning with year and extending through dut are decoded from the received data and are in fixed-length format. The agc and lset fields, as well as the following driver-dependent fields, are in variable-length format. -
    -
    s -
    The synch indicator is initially ? before the clock is set, but turns to space when all nine digits of the timecode are correctly set and the decoder is synchronized to the station within 125 ms. -
    q -
    The quality character is a four-bit hexadecimal code showing which alarms have been raised. Each bit is associated with a specific alarm condition according to the following: -
    -
    0x8 -
    synch alarm. The decoder is not synchronized to the station within 125 ms. -
    0x4 -
    Digit error alarm. Less than nine decimal digits were found in the last minute.
    0x2 -
    Error alarm. More than 40 data bit errors were found in the last minute.
    0x1 -
    Compare alarm. A maximum likelihood digit failed to agree with the current associated clock digit in the last minute.
    It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a condition that may result in an error. However, the local clock update is not suppressed if any alarm bits are set other than a synch alarm.
    yyyy ddd hh:mm:ss -
    The timecode format itself is self explanatory. Since the driver latches the on-time epoch directly from the second synch pulse, the seconds fraction is always zero. Although the transmitted timecode includes only the year of century, the Gregorian year is augmented by 2000.
    l -
    The leap second warning is normally space, but changes to L if a leap second is to occur at the end of the month of June or December. -
    d -
    The DST state is S or D when standard time or daylight time is in effect, respectively. The state is I or O when daylight time is about to go into effect or out of effect, respectively. -
    dut -
    The DUT sign and magnitude shows the current UT1 offset relative to the displayed UTC time, in deciseconds. -
    lset -
    Before the clock is set, the interval since last set is the number of minutes since the driver was started; after the clock is set, this is number of minutes since the decoder was last synchronized to the station within 125 ms. -
    agc -
    The audio gain shows the current codec gain setting in the range 0 to 255. Ordinarily, the receiver audio gain control should be set for a value midway in this range. -
    ident -
    The station identifier shows the station, WVf for WWV or WHf for WWVH, and frequency f being tracked. If neither station is heard on any frequency, the reference identifier shows NONE. -
    metric -
    The signal metric described above from 0 (no signal) to 100 (best). -
    errs -
    The bit error counter is useful to determine the quality of the data signal received in the most recent minute. It is normal to drop a couple of data bits under good signal conditions and increasing numbers as conditions worsen. While the decoder performs moderately well even with half the bits are in error in any minute, usually by that point the metric drops below threshold and the decoder switches to a different frequency.
    freq -
    The frequency offset is the current estimate of the codec frequency offset to within 0.1 PPM. This may wander a bit over the day due to local temperature fluctuations and propagation conditions. -
    avgt -
    The averaging time is the interval between frequency updates in powers of two to a maximum of 1024 s. Attainment of the maximum indicates the driver is operating at the best possible resolution in time and frequency. -
    -

    An example timecode is:

    -

    0 2000 006 22:36:00 S +3 1 115 WV20 86 5 66.4 1024

    -

    Here the clock has been set and no alarms are raised. The year, day and time are displayed along with no leap warning, standard time and DUT +0.3 s. The clock was set on the last minute, the AGC is safely in the middle ot the range 0-255, and the receiver is tracking WWV on 20 MHz. Good receiving conditions prevail, as indicated by the metric 86 and 5 bit errors during the last minute. The current frequency is 66.4 PPM and the averaging interval is 1024 s, indicating the maximum precision available.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the propagation delay for WWV (40:40:49.0N 105:02:27.0W), in seconds and fraction, with default 0.0. -
    time2 time -
    Specifies the propagation delay for WWVH (21:59:26.0N 159:46:00.0W), in seconds and fraction, with default 0.0. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Ordinarily, this field specifies the driver reference identifier; however, the driver sets the reference identifier automatically as described above. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port. -
    flag3 0 | 1 -
    Enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file + + + +Radio WWV/H Audio Demodulator/Decoder + + + +

    Radio WWV/H Audio Demodulator/Decoder

    +

    Author: David L. Mills (mills@udel.edu)
    +Last updage: + 15-Nov-2012 06:42 +UTC

    +
    +

    Synopsis

    +Address: 127.127.36.u
    +Reference ID: WVf or WHf
    +Driver ID: WWV_AUDIO
    +Autotune Port: /dev/icom; 1200/9600 baud, 8-bits, no parity
    +Audio Device: /dev/audio and /dev/audioctl +

    Description

    +This driver synchronizes the computer time using shortwave radio transmissions from NIST time/frequency stations WWV in Ft. Collins, CO, and WWVH in Kauai, HI. Transmissions are made continuously on 2.5, 5, 10 and 15 MHz from both stations and on 20 MHz from WWV. An ordinary shortwave receiver can be tuned manually to one of these frequencies or, in the case of ICOM receivers, the receiver can be tuned automatically by the driver as propagation conditions change throughout the day and season. The radio is connected via an optional attenuator and cable to either the microphone or line-in port of a workstation or PC. +

    The driver requires an audio codec or sound card with sampling rate 8 kHz and μ-law companding to demodulate the data. This is the same standard as used by the telephone industry and is supported by most hardware and operating systems, including Solaris, FreeBSD and Linux, among others. In this implementation only one audio driver and codec can be supported on a single machine. In order to assure reliable signal capture, the codec frequency error must be less than 187 PPM (.0187 percent). If necessary, the tinker codec configuration command can be used to bracket the codec frequency to this range.

    +

    In general and without calibration, the driver is accurate within 1 ms relative to the broadcast time when tracking a station. However, variations up to 0.3 ms can be expected due to diurnal variations in ionospheric layer height and ray geometry. In Newark DE, 2479 km from the transmitter, the predicted two-hop propagation delay varies from 9.3 ms in sunlight to 9.0 ms in moonlight. When not tracking the station the accuracy depends on the computer clock oscillator stability, ordinarily better than 0.5 PPM.

    +

    After calibration relative to the PPS signal from a GPS receiver, the mean offset with a 2.4-GHz P4 running FreeBSD 6.1 is generally within 0.1 ms short-term with 0.4 ms jitter. The long-term mean offset varies up to 0.3 ms due to propagation path geometry variations. The processor load due to the driver is 0.4 percent on the P4.

    +

    The driver performs a number of error checks to protect against overdriven or underdriven input signal levels, incorrect signal format or improper hardware configuration. The specific checks are detailed later in this page. Note that additional checks are done elsewhere in the reference clock interface routines.

    +

    This driver incorporates several features in common with other audio drivers such as described in the Radio CHU Audio Demodulator/Decoder and the IRIG Audio Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    +

    Technical Overview

    +

    The driver processes 8-kHz μ-law companded codec samples using maximum-likelihood techniques which exploit the considerable degree of redundancy available in the broadcast signal. The WWV signal format is described in NIST Special Publication 432 (Revised 1990) and also available on the WWV/H web site. It consists of three elements, a 5-ms, 1000-Hz pulse, which occurs at the beginning of each second, a 800-ms, 1000-Hz pulse, which occurs at the beginning of each minute, and a pulse-width modulated 100-Hz subcarrier for the data bits, one bit per second. The WWVH format is identical, except that the 1000-Hz pulses are sent at 1200 Hz. Each minute encodes nine BCD digits for the time of century plus seven bits for the daylight savings time (DST) indicator, leap warning indicator and DUT1 correction.

    +

    The demodulation and decoding algorithms used by this driver are based on a machine language program developed for the TAPR DSP93 DSP unit, which uses the TI 320C25 DSP chip. The analysis, design and performance of the program for this unit is described in: Mills, D.L. A precision radio clock for WWV transmissions. Electrical Engineering Report 97-8-1, University of Delaware, August 1997, 25 pp. Available from www.eecis.udel.edu/~mills/reports.htm. For use in this driver, the original program was rebuilt in the C language and adapted to the NTP driver interface. The algorithms have been modified to improve performance, especially under weak signal conditions and to provide an automatic frequency and station selection feature.

    +

    As in the original program, the clock discipline is modelled as a Markov process, with probabilistic state transitions corresponding to a conventional clock and the probabilities of received decimal digits. The result is a performance level with very high accuracy and reliability, even under conditions when the minute beep of the signal, normally its most prominent feature, can barely be detected by ear using a communications receiver.

    +

    Baseband Signal Processing

    +

    The 1000/1200-Hz pulses and 100-Hz subcarrier are first separated using a 600-Hz bandpass filter centered on 1100 Hz and a 150-Hz lowpass filter. The minute pulse is extracted using an 800-ms synchronous matched filter and pulse grooming logic which discriminates between WWV and WWVH signals and noise. The second pulse is extracted using a 5-ms FIR matched filter for each station and a single 8000-stage comb filter.

    +

    The phase of the 100-Hz subcarrier relative to the second pulse is fixed at the transmitter; however, the audio stage in many radios affects the phase response at 100 Hz in unpredictable ways. The driver adjusts for each radio using two 170-ms synchronous matched filters. The I (in-phase) filter is used to demodulate the subcarrier envelope, while the Q (quadrature-phase) filter is used in a type-1 phase-lock loop (PLL) to discipline the demodulator phase.

    +

    A bipolar data signal is determined from the matched filter subcarrier envelope using a pulse-width discriminator. The discriminator samples the I channel at 15 ms (n), 200 ms (s0) and 500 ms (s1), and the envelope (RMS I and Q channels) at 200 ms (e1) and the end of the second (e0). The bipolar data signal is expressed 2s1 - s0 - n, where positive values correspond to data 1 and negative values correspond to data 0. Note that, since the signals s0 and s1 include the noise n, the noise component cancels out. The data bit SNR is calculated as 20 log10(e1 / e0). If the driver has not synchronized to the minute pulse, or if the data bit amplitude e1 or SNR are below thresholds, the bit is considered invalid and the bipolar signal is forced to zero.

    +

    The bipolar signal is exponentially averaged in a set of 60 accumulators, one for each second, to determine the semi-static miscellaneous bits, such as DST indicator, leap second warning and DUT1 correction. In this design a data average value larger than a positive threshold is interpreted as +1 (hit) and a value smaller than a negative threshold as a -1 (miss). Values between the two thresholds, which can occur due to signal fades, are interpreted as an erasure and result in no change of indication.

    +

    Maximum-Likelihood Decoder

    +

    The BCD digit in each digit position of the timecode is represented as four data bits. The bits are correlated with the bits corresponding to each of the valid decimal digits in this position. If any of the four bits are invalid, the correlated value for all digits in this position is assumed zero. In either case, the values for all digits are exponentially averaged in a likelihood vector associated with this position. The digit associated with the maximum over all averaged values then becomes the maximum-likelihood candidate for this position and the ratio of the maximum over the next lower value represents the digit SNR.

    +

    The decoding matrix contains nine row vectors, one for each digit position. Each row vector includes the maximum-likelihood digit, likelihood vector and other related data. The maximum-likelihood digit for each of the nine digit positions becomes the maximum-likelihood time of the century. A built-in transition function implements a conventional clock with decimal digits that count the minutes, hours, days and years, as corrected for leap seconds and leap years. The counting operation also rotates the likelihood vector corresponding to each digit as it advances. Thus, once the clock is set, each clock digit should correspond to the maximum-likelihood digit as transmitted.

    +

    Each row of the decoding matrix also includes a compare counter and the most recently determined maximum-likelihood digit. If a digit likelihood exceeds the decision level and compares with previous digits for a number of successive minutes in any row, the maximum-likelihood digit replaces the clock digit in that row. When this condition is true for all rows and the second epoch has been reliably determined, the clock is set (or verified if it has already been set) and delivers correct time to the integral second. The fraction within the second is derived from the logical master clock, which runs at 8000 Hz and drives all system timing functions.

    +

    Master Clock Discipline

    +

    The logical master clock is derived from the audio codec clock. Its frequency is disciplined by a frequency-lock loop (FLL) which operates independently of the data recovery functions. The maximum value of the 5-ms pulse after the comb filter represents the on-time epoch of the second. At averaging intervals determined by the measured jitter, the frequency error is calculated as the difference between the epoches over the interval divided by the interval itself. The sample clock frequency is then corrected by this amount divided by a time constant of 8.

    +

    When first started, the frequency averaging interval is 8 seconds, in order to compensate for intrinsic codec clock frequency offsets up to 125 PPM. Under most conditions, the averaging interval doubles in stages from the initial value to 1024 s, which results in an ultimate frequency resolution of 0.125 PPM, or about 11 ms/day.

    +

    The data demodulation functions operate using the subcarrier clock, which is independent of the epoch. However, the data decoding functions are driven by the epoch. The decoder is phase-locked to the epoch in such a way that, when the clock state machine has reliably decoded the broadcast time to the second, the epoch timestamp of that second becomes a candidate to set the system clock.

    +

    The comb filter can have a long memory and is vulnerable to noise and stale data, especially when coming up after a long fade. Therefore, a candidate is considered valid only if the 5-ms signal amplitude and SNR are above thresholds. In addition, the system clock is not set until after one complete averaging interval has passed with valid candidates.

    +

    Station Identification

    +

    It is important that the logical clock frequency is stable and accurately determined, since in many applications the shortwave radio will be tuned to a fixed frequency where WWV or WWVH signals are not available throughout the day. In addition, in some parts of the US, especially on the west coast, signals from either or both WWV and WWVH may be available at different times or even at the same time. Since the propagation times from either station are almost always different, each station must be reliably identified before attempting to set the clock.

    +

    Reliable station identification requires accurate discrimination between very weak signals in noise and noise alone. The driver very aggressively soaks up every scrap of signal information, but has to be careful to avoid making pseudo-sense of noise alone. The signal quality metric depends on the minute pulse amplitude and SNR measured in second 0 of the minute, together with the data subcarrier amplitude and SNR measured in second 1. If all four values are above defined thresholds a hit is declared, otherwise a miss. In principle, the data pulse in second 58 is usable, but the AGC in most radios is not fast enough for a reliable measurement.

    +

    The number of hits declared in the last 6 minutes for each station represents the high order bits of the metric, while the current minute pulse amplitude represents the low order bits. Only if the metric is above a defined threshold is the station signal considered acceptable. The metric is also used by the autotune function described below and reported in the timecode string.

    +

    Performance

    +

    It is the intent of the design that the accuracy and stability of the indicated time be limited only by the characteristics of the ionospheric propagation medium. Conventional wisdom is that manual synchronization via oscilloscope and HF medium is good only to a millisecond under the best propagation conditions. The performance of the NTP daemon disciplined by this driver is clearly better than this, even under marginal conditions.

    +

    The figure below shows the measured offsets over a typical day near the bottom of the sunspot cycle ending in October, 2006. Variations up to ±0.4 ms can be expected due to changing ionospheric layer height and ray geometry over the day and night.

    +
    gif
    +

    The figure was constructed using a 2.4-GHz P4 running FreeBSD 6.1. For these measurements the computer clock was disciplined within a few microseconds of UTC using a PPS signal and GPS receiver and the measured offsets determined from the filegen peerstats data.

    +

    The predicted propagation delay from the WWV transmitter at Boulder, CO, to the receiver at Newark, DE, varies over 9.0-9.3 ms. In addition, the receiver contributes 4.7 ms and the 600-Hz bandpass filter 0.9 ms. With these values, the mean error is less than 0.1 ms and varies ±0.3 ms over the day as the result of changing ionospheric height and ray geometry.

    +

    Program Operation

    +The driver begins operation immediately upon startup. It first searches for one or both of the stations WWV and WWVH and attempts to acquire minute synch. This may take some fits and starts, as the driver expects to see several consecutive minutes with good signals and low jitter. If the autotune function is active, the driver will rotate over all five frequencies and both WWV and WWVH stations until finding a station and frequency with acceptable metric. +

    While this is going on the the driver acquires second synch, which can take up to several minutes, depending on signal quality. When minute synch has been acquired, the driver accumulates likelihood values for the unit (seconds) digit of the nine timecode digits, plus the seven miscellaneous bits included in the WWV/H transmission format. When a good unit digit has been found, the driver accumulated likelihood values for the remaining eight digits of the timecode. When three repetitions of all nine digits have decoded correctly, which normally takes 15 minutes with good signals, and up to 40 minutes when buried in noise, and the second synch has been acquired, the clock is set (or verified) and is selectable to discipline the system clock.

    +

    Once the clock is set, it continues to provide correct timecodes as long as the signal metric is above threshold, as described in the previous section. As long as the clock is correctly set or verified, the system clock offsets are provided once each minute to the reference clock interface, where they are processed using the same algorithms as with other reference clocks and remote servers.

    +

    It may happen as the hours progress around the clock that WWV and WWVH signals may appear alone, together or not at all. When the driver has mitigated which station and frequency is best, it sets the reference identifier to the string WVf for WWV and WHf for WWVH, where f is the frequency in megahertz. If the propagation delays have been properly set with the fudge time1 (WWV) and fudge time2 (WWVH) commands in the configuration file, handover from one station to the other is seamless.

    +

    Operation continues as long as the signal metric from at least one station on at least one frequency is acceptable. A consequence of this design is that, once the clock is set, the time and frequency are disciplined only by the second synch pulse and the clock digits themselves are driven by the clock state machine. If for some reason the state machine drifts to the wrong second, it would never resynchronize. To protect against this most unlikely situation, if after two days with no signals, the clock is considered unset and resumes the synchronization procedure from the beginning.

    +

    Once the system clock been set correctly it will continue to read correctly even during the holdover interval, but with increasing dispersion. Assuming the system clock frequency can be disciplined within 1 PPM, it can coast without signals for several days without exceeding the NTP step threshold of 128 ms. During such periods the root distance increases at 15 μs per second, which makes the driver appear less likely for selection as time goes on. Eventually, when the distance due all causes exceeds 1 s, it is no longer suitable for synchronization. Ordinarily, this happens after about 18 hours with no signals. The tinker maxdist configuration command can be used to change this value.

    +

    Autotune

    +

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a standard serial port using a level converter such as the CT-17. Further details are on the Reference Clock Audio Drivers page.

    +

    If specified, the driver will attempt to open the device /dev/icom and, if successful will activate the autotune function and tune the radio to each operating frequency in turn while attempting to acquire minute synch from either WWV or WWVH. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus is inoperative, the driver quietly gives up with no harm done.

    +

    Once acquiring minute synch, the driver operates as described above to set the clock. However, during seconds 59, 0 and 1 of each minute it tunes the radio to one of the five broadcast frequencies to measure the signal metric as described above. Each of the five frequencies are probed in a five-minute rotation to build a database of current propagation conditions for all signals that can be heard at the time. At the end of each probe a mitigation procedure scans the database and retunes the radio to the best frequency and station found. For this to work well, the radio should be set for a fast AGC recovery time. This is most important while tracking a strong signal, which is normally the case, and then probing another frequency, which may have much weaker signals.

    +

    The mitigation procedure selects the frequency and station with the highest valid metric, ties going first to the highest frequency and then to WWV in order. A station is considered valid only if the metric is above a specified threshold; if no station is above the metric, the rotating probes continue until a valid station is found.

    +

    The behavior of the autotune function over a typical day is shown in the figure below.

    +
    gif
    +

    As expected, the lower frequencies prevail when the ray path is in moonlight (0100-1300 UTC) and the higher frequencies when the path is in sunlight (1300-0100 UTC). Note three periods in the figure show zero frequency when signals are below the minimum for all frequencies and stations.

    +

    Debugging Aids

    +

    The most convenient way to track the driver status is using the ntpq program and the clockvar command. This displays the last determined timecode and related status and error counters, even when the driver is not disciplining the system clock. If the debugging trace feature (-d on the ntpd command line) is enabled, the driver produces detailed status messages as it operates. If the fudge flag 4 is set, these messages are written to the clockstats file. All messages produced by this driver have the prefix wwv for convenient filtering with the Unix grep command.

    +

    The autotune process produces diagnostic information along with the timecode. This is very useful for evaluating the performance of the algorithms, as well as radio propagation conditions in general. The message is produced once each minute for each frequency in turn after minute synch has been acquired.

    +

    wwv5 status agc epoch secamp/secsnr datamp/datsnr wwv wwvh

    +

    where the fields after the wwv5 identifier are: status contains status bits, agc audio gain, epoch second epoch, secamp/secsnr second pulse amplitude/SNR, and wwv and wwvh are two sets of fields, one each for WWV and WWVH. Each of the two fields has the format

    +

    ident score metric minamp/minsnr

    +

    where ident encodes the station (WV for WWV, WH for WWVH) and frequency (2, 5, 10, 15 or 20), score 32-bit shift register recording the hits (1) and misses (0) of the last 32 probes (hits and misses enter from the right), metric is described above, and minamp/minsnr is the minute pulse ampliture/SNR. An example is:

    +
    wwv5 000d 111 5753 3967/20.1 3523/10.2 WV20 bdeff 100 8348/30.0 WH20 0000 1 22/-12.4
    +

    There are several other messages that can occur; these are documented in the source listing.

    +

    Monitor Data

    +When enabled by the filegen facility, every received timecode is written to the clockstats file in the following format: +

    sq yyyy ddd hh:mm:ss l d du lset agc ident metric errs freq avg
    +

    +The fields beginning with yyyy and extending through du are decoded from the received data and are in fixed-length format. The remaining fields are in variable-length format. The fields are as follows: +
    +
    s
    +
    The synch indicator is initially ? before the clock is set, but turns to space when all nine digits of the timecode are correctly set and the decoder is synchronized to the station within 125 μs.
    +
    q
    +
    The quality character is a four-bit hexadecimal code showing which alarms have been raised. Each bit is associated with a specific alarm condition according to the following: +
    +
    0x8
    +
    synch alarm. The decoder is not synchronized to the station within 125 μs.
    +
    0x4
    +
    Digit error alarm. Less than nine decimal digits were found in the last minute.
    +
    0x2
    +
    Error alarm. More than 40 data bit errors were found in the last minute.
    +
    0x1
    +
    Compare alarm. A maximum-likelihood digit failed to agree with the current associated clock digit in the last minute.
    +
    + It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a marginal condition.
    +
    yyyy ddd hh:mm:ss
    +
    The timecode format itself is self explanatory. Since the driver latches the on-time epoch directly from the second synch pulse, the seconds fraction is always zero. Although the transmitted timecode includes only the year of century, the Gregorian year is augmented by 2000.
    +
    l
    +
    The leap second warning is normally space, but changes to L if a leap second is to occur at the end of the month.
    +
    d
    +
    The DST state is S or D when standard time or daylight time is in effect, respectively. The state is I or O when daylight time is about to go into effect or out of effect, respectively.
    +
    du
    +
    The DUT sign and magnitude shows the current UT1 offset relative to the displayed UTC time, in deciseconds.
    +
    lset
    +
    Before the clock is set, the interval since last set is the number of minutes since the driver was started; after the clock is set, this is number of minutes since the decoder was last synchronized to the station within 125 μs.
    +
    agc
    +
    The audio gain shows the current codec gain setting in the range 0 to 255. Ordinarily, the receiver audio gain control should be set for a value midway in this range.
    +
    ident
    +
    The station identifier shows the station, WVf for WWV or WHf for WWVH, and frequency f being tracked. If neither station is heard on any frequency, the reference identifier shows NONE.
    +
    metric
    +
    The signal metric described above from 0 (no signal) to 100 (best).
    +
    errs
    +
    The bit error counter is useful to determine the quality of the data signal received in the most recent minute. It is normal to drop a couple of data bits even under good signal conditions and increasing numbers as conditions worsen. While the decoder performs moderately well even with half the bits are in error in any minute, usually by that point the metric drops below threshold and the decoder switches to a different frequency.
    +
    freq
    +
    The frequency offset is the current estimate of the codec frequency offset to within 0.1 PPM. This may wander a bit over the day due to local temperature fluctuations and propagation conditions.
    +
    avg
    +
    The averaging time is the interval between frequency updates in powers of two to a maximum of 1024 s. Attainment of the maximum indicates the driver is operating at the best possible resolution in time and frequency.
    +
    +

    An example timecode is:

    +

    0 2000 006 22:36:00 S +3 1 115 WV20 86 5 66.4 1024

    +

    Here the clock has been set and no alarms are raised. The year, day and time are displayed along with no leap warning, standard time and DUT +0.3 s. The clock was set on the last minute, the AGC is safely in the middle ot the range 0-255, and the receiver is tracking WWV on 20 MHz. Good receiving conditions prevail, as indicated by the metric 86 and 5 bit errors during the last minute. The current frequency is 66.4 PPM and the averaging interval is 1024 s, indicating the maximum precision available.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the propagation delay for WWV (40:40:49.0N 105:02:27.0W), in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Specifies the propagation delay for WWVH (21:59:26.0N 159:46:00.0W), in seconds and fraction, with default 0.0.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Ordinarily, this field specifies the driver reference identifier; however, the driver sets the reference identifier automatically as described above.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Specifies the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port.
    +
    flag3 0 | 1
    +
    Enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started.
    +
    flag4 0 | 1
    +
    Enable verbose clockstats recording if set.
    +
    +
    + + + diff --git a/contrib/ntp/html/drivers/driver37.html b/contrib/ntp/html/drivers/driver37.html index 3bd50857d..c87a82f1e 100644 --- a/contrib/ntp/html/drivers/driver37.html +++ b/contrib/ntp/html/drivers/driver37.html @@ -10,6 +10,9 @@

    Forum Graphic GPS Dating station

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.37.u
    @@ -48,4 +51,4 @@ - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver38.html b/contrib/ntp/html/drivers/driver38.html index 283e38f24..445d70df2 100644 --- a/contrib/ntp/html/drivers/driver38.html +++ b/contrib/ntp/html/drivers/driver38.html @@ -10,6 +10,9 @@

    hopf Serial Line Receivers (6021 and  kompatible)

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    @@ -110,7 +113,7 @@

    Fudge Factors

    -
    time1 time +
    time1 time
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. Should be set to 20 milliseconds to correct serial line and operating system delays incurred in capturing time stamps from the synchronous packets.
    refid string
    Specifies the driver reference identifier, GPS or DCF. @@ -123,9 +126,8 @@

    Questions or Comments:

    Bernd Altmeier
    Ing.-Büro für Software www.ATLSoft.de

    -

    (last updated 02/28/2001)
     


    - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver39.html b/contrib/ntp/html/drivers/driver39.html index 482134e0e..9e1605f81 100644 --- a/contrib/ntp/html/drivers/driver39.html +++ b/contrib/ntp/html/drivers/driver39.html @@ -10,6 +10,9 @@

    hopf PCI-Bus Receiver (6039 GPS/DCF77)

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    @@ -105,9 +108,8 @@

    Questions or Comments:

    Bernd Altmeier
    Ing.-Büro für Software www.ATLSoft.de

    -

    (last updated 03/02/2001)
     


    - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver4.html b/contrib/ntp/html/drivers/driver4.html index bda4a104a..213928940 100644 --- a/contrib/ntp/html/drivers/driver4.html +++ b/contrib/ntp/html/drivers/driver4.html @@ -1,66 +1,76 @@ - - - - - Spectracom 8170 and Netclock/2 WWVB Receivers - - - - -

    Spectracom 8170 and Netclock/2 WWVB Receivers

    -
    -

    Synopsis

    - Address: 127.127.4.u
    - Reference ID: WWVB
    - Driver ID: WWVB_SPEC
    - Serial Port: /dev/wwvbu; 9600 baud, 8-bits, no parity
    - Features: tty_clk -

    Description

    -

    This driver supports all known Spectracom radio and satellite clocks, including the Model 8170 and Netclock/2 WWVB Synchronized Clocks and the Netclock/GPS GPS Master Clock. The claimed accuracy of the WWVB clocks is 100 usec relative to the broadcast signal. These clocks have proven a reliable source of time, except in some parts of the country with high levels of conducted RF interference. WIth the GPS clock the claimed accuracy is 130 ns. However, in most cases the actual accuracy is limited by the precision of the timecode and the latencies of the serial interface and operating system.

    -

    The DIPswitches on these clocks should be set to 24-hour display, AUTO DST off, data format 0 or 2 (see below) and baud rate 9600. If this clock is used as the source for the IRIG Audio Decoder (refclock_irig.c in this distribution), set the DIPswitches for AM IRIG output and IRIG format 1 (IRIG B with signature control).

    -

    There are two timecode formats used by these clocks. Format 0, which is available with all clocks, and format 2, which is available with all clocks except the original (unmodified) Model 8170.

    -

    Format 0 (22 ASCII printing characters):
    - <cr><lf>i ddd hh:mm:ss TZ=zz<cr><lf>

    -

    on-time = first <cr>
    - i = synchronization flag (' ' = in synch, '?' = out synch)
    - hh:mm:ss = hours, minutes, seconds

    -

    The alarm condition is indicated by other than ' ' at i, which occurs during initial synchronization and when received signal is lost for about ten hours.

    -

    Format 2 (24 ASCII printing characters):
    - lt;cr>lf>iqyy ddd hh:mm:ss.fff ld

    -

    on-time = <cr>
    - i = synchronization flag (' ' = in synch, '?' = out synch)
    - q = quality indicator (' ' = locked, 'A'...'D' = unlocked)
    - yy = year (as broadcast)
    - ddd = day of year
    - hh:mm:ss.fff = hours, minutes, seconds, milliseconds

    -

    The alarm condition is indicated by other than ' ' at i, which occurs during initial synchronization and when received signal is lost for about ten hours. The unlock condition is indicated by other than ' ' at q.

    -

    The q is normally ' ' when the time error is less than 1 ms and a character in the set A...D when the time error is less than 10, 100, 500 and greater than 500 ms respectively. The l is normally ' ', but is set to L early in the month of an upcoming UTC leap second and reset to ' ' on the first day of the following month. The d is set to S for standard time S, I on the day preceding a switch to daylight time, D for daylight time and O on the day preceding a switch to standard time. The start bit of the first <cr> is synchronized to the indicated time as returned.

    -

    This driver does not need to be told which format is in use - it figures out which one from the length of the message. A three-stage median filter is used to reduce jitter and provide a dispersion measure. The driver makes no attempt to correct for the intrinsic jitter of the radio itself, which is a known problem with the older radios.

    -

    Monitor Data

    -

    The driver writes each timecode as received to the clockstats file. When enabled by the flag4 fudge flag, a table of quality data maintained internally by the Netclock/2 is retrieved and written to the clockstats file when the first timecode message of a new dayis received.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWVB. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file + + +Spectracom WWVB/GPS Receivers + + + + +

    Spectracom WWVB/GPS Receivers

    +

    Author: David L. Mills (mills@udel.edu)
    + Last update: + 11-Sep-2010 05:56 + UTC

    +
    +

    Synopsis

    +

    Address: 127.127.4.u
    + Reference ID: WWVB
    + Driver ID: WWVB_SPEC
    + Serial Port: /dev/wwvbu; 9600 baud, 8-bits, no parity
    + Features: Optional PPS signal processing, tty_clk
    + Requires: Optional PPS signal processing requires the PPSAPI signal interface.

    +

    Description

    +

    This driver supports all known Spectracom radio and satellite clocks, including the Model 8170 and Netclock/2 WWVB Synchronized Clocks and the Netclock/GPS GPS Master Clock. The claimed accuracy of the WWVB clocks is 100 ms relative to the broadcast signal. These clocks have proven a reliable source of time, except in some parts of the country with high levels of conducted RF interference. WIth the GPS clock the claimed accuracy is 130 ns. However, in most cases the actual accuracy is limited by the precision of the timecode and the latencies of the serial interface and operating system.

    +

    The DIPswitches on these clocks should be set to 24-hour display, AUTO DST off, data format 0 or 2 (see below) and baud rate 9600. If this clock is used as the source for the IRIG Audio Decoder (refclock_irig.c in this distribution), set the DIPswitches for AM IRIG output and IRIG format 1 (IRIG B with signature control).

    +

    There are two timecode formats used by these clocks. Format 0, which is available with all clocks, and format 2, which is available with all clocks except the original (unmodified) Model 8170.

    +

    Format 0 (22 ASCII printing characters):
    + <cr><lf>i ddd hh:mm:ss TZ=zz<cr><lf>

    +

    on-time = first <cr>
    + i = synchronization flag (' ' = in synch, '?' = out synch)
    + hh:mm:ss = hours, minutes, seconds

    +

    The alarm condition is indicated by other than ' ' at i, which occurs during initial synchronization and when received signal is lost for about ten hours.

    +

    Format 2 (24 ASCII printing characters):
    + lt;cr>lf>iqyy ddd hh:mm:ss.fff ld

    +

    on-time = <cr>
    + i = synchronization flag (' ' = in synch, '?' = out synch)
    + q = quality indicator (' ' = locked, 'A'...'D' = unlocked)
    + yy = year (as broadcast)
    + ddd = day of year
    + hh:mm:ss.fff = hours, minutes, seconds, milliseconds

    +

    The alarm condition is indicated by other than ' ' at i, which occurs during initial synchronization and when received signal is lost for about ten hours. The unlock condition is indicated by other than ' ' at q.

    +

    The q is normally ' ' when the time error is less than 1 ms and a character in the set A...D when the time error is less than 10, 100, 500 and greater than 500 ms respectively. The l is normally ' ', but is set to L early in the month of an upcoming UTC leap second and reset to ' ' on the first day of the following month. The d is set to S for standard time S, I on the day preceding a switch to daylight time, D for daylight time and O on the day preceding a switch to standard time. The start bit of the first <cr> is synchronized to the indicated time as returned.

    +

    This driver does not need to be told which format is in use - it figures out which one from the length of the message. A three-stage median filter is used to reduce jitter and provide a dispersion measure. The driver makes no attempt to correct for the intrinsic jitter of the radio itself, which is a known problem with the older radios.

    +

    PPS Signal Processing

    +

    When PPS signal processing is enabled, and when the system clock has been set by this or another driver and the PPS signal offset is within 0.4 s of the system clock offset, the PPS signal replaces the timecode for as long as the PPS signal is active. If for some reason the PPS signal fails for one or more poll intervals, the driver reverts to the timecode. If the timecode fails for one or more poll intervals, the PPS signal is disconnected.

    +

    Monitor Data

    +

    The driver writes each timecode as received to the clockstats file. When enabled by the flag4 fudge flag, a table of quality data maintained internally by the Netclock/2 is retrieved and written to the clockstats file when the first timecode message of a new day is received.

    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the PPS time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Specifies the serial time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default WWVB.
    +
    flag1 0 | 1
    +
    Disable PPS signal processing if 0 (default); enable PPS signal processing if 1.
    +
    flag2 0 | 1
    +
    If PPS signal processing is enabled, capture the pulse on the rising edge if 0 (default); capture on the falling edge if 1.
    +
    flag3 0 | 1
    +
    If PPS signal processing is enabled, use the ntpd clock discipline if 0 (default); use the kernel discipline if 1.
    +
    flag4 0 | 1
    +
    Enable verbose clockstats recording if set.
    +
    +
    + + + diff --git a/contrib/ntp/html/drivers/driver40-ja.html b/contrib/ntp/html/drivers/driver40-ja.html new file mode 100644 index 000000000..8b67e9009 --- /dev/null +++ b/contrib/ntp/html/drivers/driver40-ja.html @@ -0,0 +1,534 @@ + + + + + + + + + + JJY Receivers + + + + + + +

    JJY Receivers

    +

    Last update: + 15-May-2015 00:00 + UTC          ENGLISH(英語)   JAPANESE(日本語)

    +
    +

    Synopsis

    + Address: 127.127.40.u
    + Reference ID: JJY
    + Driver ID: JJY
    + Serial Port: /dev/jjyu; それぞれのJJY受信機、GPS時計、テレフォンJJYを参照して下さい。 +

    Description

    +

    このドライバーは、以下の、日本で販売されている JJY受信機、GPS時計と、電話回線による時刻配信サービスをサポートしています。 +

    +
    + + + + +
    + トライステート   TS-JJY01, TS-JJY02
    + シーデックス   JST2000
    + エコー計測器   LT-2000
    + シチズンTIC   JJY-200
    + トライステート   TS-GPSclock-01
    +
    + セイコー タイム システム   TDC-300
    + テレフォンJJY
    +
    +
      + +
    • +

      トライステート   TS-JJY01, TS-JJY02   http://www.tristate.ne.jp/ (日本語)


      +
      +
      NTPの設定 ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 1
      +

      +
      fudge   127.127.40.X   time1 0.NNN   flag1 0|1
      +
      +

      Time1 は、受信機からの時刻に加算する調整時間を、固定小数点形式の秒で設定します。
      + この受信機には、数10ミリ秒 ( 0.0NN秒 ) から百数10ミリ秒 ( 0.1NN秒 ) の調整時間を設定すると良いでしょう。

      +

      Flag1 は、時刻同期には無関係です。Flag1 を 1 に設定すると、状態を問い合わせるコマンドを DATE コマンドと STIM コマンドの前に発行して、応答を clockstats ファイルに記録します。

      + + + +
      0 (Default)DCST と STUS コマンドは、発行しません。
      1DCST と STUS コマンドを、発行します。
      +
      +
      +
      +
      +
      インターフェース
      +
      +

      RS-232C, 9600 BPS, 8ビット, パリティなし, 1ストップ・ビット

      +
      +
      +
      日時データの形式
      +

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      コマンド --> å¿œç­”
      dcst{CR}{LF} --> valid{CR}{LF} | invalid{CR}{LF}
      stus{CR}{LF} --> adjusted{CR}{LF} | unadjusted{CR}{LF}
      time{CR}{LF} --> HH:MM:SS{CR}{LF}
      date{CR}{LF} --> YYYY/MM/DD WWW{CR}{LF}
      stim{CR}{LF} --> HH:MM:SS{CR}{LF}
      +

      日付と時刻は、別々に問い合わせます。日付が深夜0時の前か後かの不確定をチェックするため、日付の問い合わせの前後に時刻を問い合わせています。


      +
      +
      +
    • + +
    • +

      シーデックス   JST2000   http://www.c-dex.co.jp/ (日本語)


      +
      +
      NTPの設定 ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 2
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +
      +
      +
      +
      インターフェース
      +
      +

      RS-232C, 9600 BPS, 8ビット, パリティなし, 1ストップ・ビット

      +
      +
      +
      日時データの形式
      +

      + + + + + + + + + + + +
      コマンド --> å¿œç­”
      {ENQ}1J{ETX} --> {STX}JYYMMDD HHMMSSS{ETX}
      +
      +
      +
      +
    • + +
    • +

      エコー計測器   LT-2000   http://www.clock.co.jp/ (日本語)


      +
      +
      NTPの設定 ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 3
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +
      +
      +
      +
      Interface
      +
      +

      RS-232C, 9600 BPS, 8ビット, パリティなし, 1ストップ・ビット

      +
      +
      +
      Time code format
      +

      + + + + + + + + + + + + + + + + + + + + + +
      コマンド --> å¿œç­”
      C --> ( Mode 2 : Continuous )
      ( Every second before 0.5 second )YYMMDDWHHMMSS{ST1}{ST2}{ST3}{ST4}{CR}
      # --> ( Mode 1 : Request&Send )
      +
      +
      +
      +
    • + +
    • +

      シチズンTIC   JJY-200   http://www.tic-citizen.co.jp/ (日本語)


      +
      +
      NTPの設定 ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 4
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +
      +
      +
      +
      インターフェース
      +
      +

      RS-232C, 4800 BPS, 8ビット, パリティなし, 1ストップ・ビット

      +
      +
      +
      日時データの形式
      +

      + + + + + + + + + + + +
      コマンド --> å¿œç­”
      ( Every second )'XX YY/MM/DD W HH:MM:SS{CR}
      +
      +
      +
      +
    • + +
    • +

      トライステート   TS-GPSclock-01   http://www.tristate.ne.jp/ (日本語)

      +

      このドライバーは、JJY受信機ではないGPS時計のトライステート TS-GPSclock-01 のコマンド・レスポンス・モードをサポートします。
      + TS-GPSclock-01 は、オンボードのスイッチとメニューでコマンド・レスポンス・モードとタイム・ゾーンをJST(日本標準時)に設定しなければなりまん。
      + この Type 40 のドライバーの他, TS-GPSclock-01 のNMEAモードは、一般 NMEA GPS ドライバー ( Type 20 ) でも利用することができます。

      +
      +
      NTPの設定 ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 5
      +

      +
      fudge   127.127.40.X   time1 0.NNN   flag1 0|1
      +
      +

      Time1 は、受信機からの時刻に加算する調整時間を、固定小数点形式の秒で設定します

      +

      Flag1 は、時刻同期には無関係です。Flag1 を 1 に設定すると、状態を問い合わせるコマンドを DATE コマンドと STIM コマンドの前に発行して、応答を clockstats ファイルに記録します。

      + + + +
      0 (Default)STUS コマンドは、発行しません。
      1STUS コマンドを、発行します。
      +
      +
      +
      +
      +
      インターフェース
      +
      +

      USB ( /dev/ttyACM0 )

      +
      +
      +
      日時データの形式
      +

      + + + + + + + + + + + + + + + + + + + + + + + + + + +
      コマンド --> å¿œç­”
      stus{CR}{LF} --> *R{CR}{LF} | *G{CR}{LF} | *U{CR}{LF} | +U{CR}{LF}
      time{CR}{LF} --> HH:MM:SS{CR}{LF}
      date{CR}{LF} --> YYYY/MM/DD{CR}{LF}
      time{CR}{LF} --> HH:MM:SS{CR}{LF}
      +

      日付と時刻は、別々に問い合わせます。日付が深夜0時の前か後かの不確定をチェックするため、日付の問い合わせの前後に時刻を問い合わせています。


      +
      +
      +
    • + +
    • +

      セイコー タイム システム   TDC-300   http://www.seiko-sts.co.jp/ (英語と日本語)


      +

      TDC-300 は、フロント・パネルのメニュー表示とスイッチで type 3 のデータ形式に設定しなければなりません。

      +
      +
      NTP configuration ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 6
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +
      +
      +
      +
      インターフェース
      +
      +

      RS-232C, 2400 BPS, 8-bits, no parity, 1 stop bit

      +
      +
      +
      日時データの形式
      +

      + + + + + + + + + + + + + + + + +
      コマンド --> å¿œç­”
      {STX}YYMMDDWHHMMSS{ETX}
      ( 5 to 10 mSec. before second ){STX}{xE5}{ETX}
      +
      +
      +
      +
    • + +
    • +

      テレフォンJJY   http://jjy.nict.go.jp/ (英語と日本語)

      +

      テレフォンJJYは、電話回線による時刻配信サービスです。
      + このサービスは、国立研究開発法人 情報通信研究機構が提供しています。

      +

      注意: このモード(テレフォンJJY)は、refclock_acts ( Type 18 ) のドライバーと同時に利用することはできません。 + 設定ファイルの phone は、server と関係付けられていないため、ドライバーの refclock_acts ( type 18 ) も、この refclock_jjy ( type 40, mode 100 to 180 ) のいずれも、 + 複数の phone のうち、どれが自分に関係するものか識別できないからです。

      +
      +
      NTPの設定 ( ntp.conf )
      +
      +
      +
      server   127.127.40.X   mode (100, 101 to 180)   minpoll N
      +
      +

      モード 100 を設定した場合、このドライバーは、遅延を計測するためのループバック・コマンドは発行せず、電話回線とシステムの処理による遅延は調整しません。
      + モード 101 から 180 を設定した場合、このドライバーは、ループバック・コマンドを発行して、テレフォンJJYのループバック回路を通して電話回線とシステムの処理による遅延を計測します。
      + テレフォンJJYのループバック回路を経由した往復の時間は、5回、計測されます。 + それぞれの遅延時間のうち、700ミリ秒を超えたものは、平均遅延時間の計算より除外されます。 + また、700ミリ秒以下の有効な遅延時間が、3回以上の場合は、そのうち、最大の遅延時間は、平均遅延時間の計算より除外され、 + 4回以上の場合は、そのうち、最小の遅延時間は、平均遅延時間の計算より除外されます。 + 調整時間は、往復時間 × ( モード番号 - 100 ) % で計算し、同期する時刻に加算されます。
      + モード 101 から 180 を設定して自動遅延補正を選択するなら、モード 145 から 165 が良いでしょう。

      +

      デフォルトの日時問い合わせ処理間隔 6 ( 64 秒 ) は、このモードには、短すぎます。 "minpoll" は、8 ( 256 秒, 約 4 分 ) 以上を設定して下さい。
      + 日時問い合わせ処理間隔は、秒数を 2 のべき乗で指定します。 minpoll の値が、12 なら 4096 秒(約1時間)、14 なら 16384 秒(約4.5時間)、16 なら 65536 秒(約18時間)となります。


      +
      +
      fudge   127.127.40.X   flag1 0|1   flag2 0|1   flag3 0|1   flag4 0|1
      +
      +

      Time1 は、受信機からの時刻に加算する調整時間を、固定小数点形式の秒で設定します。
      + mode 100 の場合は、time1 で調整する時間を設定したほうが良いでしょう。
      + mode 101 から 180 の場合は、このドライバーが計測したループバックの遅延時間の一定の割合を同期時刻に加算しますので、time1 は設定しないほうが良いでしょう。

      +
      Flag1 は、タッチ・トーンかダイヤル・パルスかを指定します。
      + + + +
      0 (Default)タッチ・トーンATDWTnn...nn
      1ダイヤル・パルスATDWPnn...nn
      +
      +
      Flag2 は、エラー訂正プロトコルを指定します。
      + + + +
      0 (Default)ノーマル(エラー訂正なし)AT\N0
      1V42, MNP, ノーマルの自動選択AT\N3
      +
      +
      Flag3 は、スピーカーのオン/オフを指定します。
      + + + +
      0 (Default)オフATM0Ln
      1オンATM2Ln
      +
      +
      Flag4 は、スピーカーの音量を指定します。
      + + + +
      0 (Default)低ATMnL1
      1中ATMnL2
      +
      +
      +
      phone 042NNNNNNN
      +
      +

      電話番号は、http://jjy.nict.go.jp/ で公開されています。
      + 電話番号の桁数をチェックしています。もし、日本国外から発信するために国際電話アクセス番号と国番号を付加すると、桁数制限を超えます。
      + また、電話番号の最初の2桁や3桁をチェックしています。日本の緊急番号や特別のサービスの番号を指定することはできません。
      + 内線から外線に発信する時は、"0," ( ゼロとカンマ ) を先頭に付加して下さい。外線発信番号は、チェックしていて、それ以外の外線発信番号を指定することはできません。

      +
      +
      +
      +
      +
      インターフェース
      +
      +

      RS-232C 又は USB, 2400 BPS, 8ビット, パリティなし, 1ストップ・ビット

      +

      モデム制御コマンド:
      + ATE0Q0V1, ATMnLn, AT&K4, AT+MS=V22B, AT%C0, AT\Nn, ATH1, ATDWxnn...nn
      + +++, ATH0

      +
      +
      +
      日時データの形式
      +

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      プロンプト --> ã‚³ãƒžãƒ³ãƒ‰ --> å¿œç­”
      Name{SP}?{SP} --> TJJY{CR} --> Welcome messages
      > --> LOOP{CR} --> ( Switch to the loopback circuit )
         ( One char. ) --> ( One char. )
         COM{CR} --> ( Exit from the loopback circuit )
      > --> TIME{CR} --> HHMMSS{CR}HHMMSS{CR}HHMMSS{CR} 3 times on second
      > --> 4DATE{CR} --> YYYYMMDD{CR}
      > --> LEAPSEC{CR} --> {SP}0{CR} | +1{CR} | -1{CR}
      > --> TIME{CR} --> HHMMSS{CR}HHMMSS{CR}HHMMSS{CR} 3 times on second
      > --> BYE{CR} --> Sayounara messages
      +

      日付と時刻は、別々に問い合わせます。日付が深夜0時の前か後かの不確定をチェックするため、日付の問い合わせの前後に時刻を問い合わせています。
      + うるう秒は、処理していません。情報として clockstats ファイルに記録しているだけです。

      +
      +
      +
      +
    • + +
    + +

    JJY は、長波で日本標準時(JST)を送信している無線局で、国立研究開発法人 情報通信研究機構が運用しています。JJY の運用情報などは、 http://www.nict.go.jp/(英語と日本語)や http://jjy.nict.go.jp/(英語と日本語)で提供されています。

    +

    実際のシリアル・ポートのデバイスにシンボリック・リンクを作成して下さい。シンボリック・リンクを作成するコマンドは、以下のとおりです。

    +

    ln -s /dev/ttyS0 /dev/jjy0

    +

    RS-232C から USB への変換ケーブルを利用して、JJY受信機、GPS時計、モデムをRS-232Cポートではなく、USBに接続することができます。この場合のシンボリック・リンクを作成するコマンドは、以下のとおりです。

    +

    ln -s /dev/ttyUSB0 /dev/jjy0

    +

    Windows NT の場合は、 COMX: の数字部分がドライバーのユニット番号に使用されます。 ドライバーのユニット 1 は、COM1: にユニット 3 は、COM3: に対応します。

    +

    Monitor Data

    +

    このドライバーは、JJY受信機、GPS時計、モデムとの送受信データを clockstats ファイルに記録します。

    +

    + statsdir /var/log/ntpd/
    + filegen clockstats file clockstats type day enable +

    +
    レコード中のマークについて
    + + + + + + + + +
    JJY æƒ…報(このドライバーの開始または終了)
    --> é€ä¿¡ãƒ‡ãƒ¼ã‚¿
    <-- å—信データ
    --- æƒ…å ±
    === æƒ…報(ポーリングの開始、および、同期時刻)
    -W- è­¦å‘Šãƒ¡ãƒƒã‚»ãƒ¼ã‚¸
    -X- ã‚¨ãƒ©ãƒ¼ãƒ»ãƒ¡ãƒƒã‚»ãƒ¼ã‚¸
    +

    Fudge Factors

    +
    +
    time1 time
    +
    受信機からの時刻に対する調整時間を、固定小数点形式の秒で設定します。デフォルトは、0.0秒です。
    +
    time2 time
    +
    未使用。
    +
    stratum number
    +
    NTPの階層番号を 0 から 15 で指定します。デフォルトは、0です。
    +
    refid string
    +
    ドライバーIDで、ASCII の1文字から4文字で指定します。デフォルトは、JJY です。
    +
    flag1 0 | 1
    +
    それぞれのモードを参照して下さい。
    +
    flag2 0 | 1
    +
    それぞれのモードを参照して下さい。
    +
    flag3 0 | 1
    +
    それぞれのモードを参照して下さい。
    +
    flag4 0 | 1
    +
    それぞれのモードを参照して下さい。
    +
    +
    + + + + diff --git a/contrib/ntp/html/drivers/driver40.html b/contrib/ntp/html/drivers/driver40.html index 1901dcdbf..356429e49 100644 --- a/contrib/ntp/html/drivers/driver40.html +++ b/contrib/ntp/html/drivers/driver40.html @@ -5,6 +5,7 @@ + JJY Receivers @@ -14,25 +15,58 @@

    JJY Receivers

    +

    Last update: + 15-May-2015 00:00 + UTC          ENGLISH   JAPANESE


    Synopsis

    Address: 127.127.40.u
    Reference ID: JJY
    Driver ID: JJY
    - Serial Port: /dev/jjyu; 9600|4800(See corresponding receiver) baud, 8-bits, no parity, 1 stop bit + Serial Port: /dev/jjyu; See corresponding receiver

    Description

    -

    This driver supports the following JJY receivers sold in Japan.

    +

    This driver supports the following the JJY receivers and the GPS clock sold in Japan, and the time service through a telephone line. +

    + + + + + +
    + Tristate Ltd.   TS-JJY01, TS-JJY02
    + C-DEX Co.,Ltd.   JST2000
    + Echo Keisokuki Co.,Ltd.   LT-2000
    + CITIZEN T.I.C. CO.,LTD.   JJY-200
    + Tristate Ltd.   TS-GPSclock-01
    +
    + SEIKO TIME SYSTEMS INC.   TDC-300
    + Telephone JJY
    +
      -
    • Tristate Ltd. JJY01 http://www.tristate.ne.jp/ (Japanese only)
      + +
    • +

      Tristate Ltd.   TS-JJY01, TS-JJY02   http://www.tristate.ne.jp/ (Japanese only)


      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 1

      +

      +
      +
      server   127.127.40.X   mode 1
      +

      +
      fudge   127.127.40.X   time1 0.NNN   flag1 0|1
      +
      +

      Time1 may specify a constant to be added to the time offset for the time from the receiver, a fixed-point decimal number in seconds. You may specify the time offset from several tens of milli-seconds ( 0.0NN seconds ) to a hundred and several tens of milli-seconds ( 0.1NN seconds ) for this clock.

      +

      Flag1 has no effect for time synchronization. When flag1 is set to 1, status commands are issued before DATE and STIM commands, and write a response text into the clockstats file.

      + + + +
      0 (Default)DCST and STUS commands are not issued
      1DCST and STUS commands are issued
      +
      +

      -
      RS-232C
      +
      Interface
      -

      9600 Baud

      +

      RS-232C, 9600 BPS, 8-bits, no parity, 1 stop bit


      Time code format
      @@ -44,29 +78,51 @@ Reply - date<CR><LF> + dcst{CR}{LF} +  -->  + valid{CR}{LF} | invalid{CR}{LF} + + + stus{CR}{LF} +  -->  + adjusted{CR}{LF} | unadjusted{CR}{LF} + + + time{CR}{LF}  -->  - YYYY/MM/DD WWW<CR><LF> + HH:MM:SS{CR}{LF} - stim<CR><LF> + date{CR}{LF}  -->  - HH:MM:SS<CR><LF> + YYYY/MM/DD WWW{CR}{LF} + + + stim{CR}{LF} +  -->  + HH:MM:SS{CR}{LF} -
      +

      The date and time are requested separately. The time is requested before and after the date request to check uncertainty of the date whether it's before or after midnight.


      -
    • C-DEX Co.,Ltd. JST2000 http://www.c-dex.co.jp/ (Japanese only)
      +
    • + +
    • +

      C-DEX Co.,Ltd.   JST2000   http://www.c-dex.co.jp/ (Japanese only)


      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 2

      +

      +
      +
      server   127.127.40.X   mode 2
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +

      -
      RS-232C
      +
      Interface
      -

      9600 Baud

      +

      RS-232C, 9600 BPS, 8-bits, no parity, 1 stop bit


      Time code format
      @@ -78,25 +134,31 @@ Reply - <ENQ>1J<ETX> + {ENQ}1J{ETX}  -->  - <STX>JYYMMDD HHMMSSS<ETX> + {STX}JYYMMDD HHMMSSS{ETX}
      +
    • +
    • -

      Echo Keisokuki Co.,Ltd. LT-2000 http://www.clock.co.jp/ (Japanese only)

      +

      Echo Keisokuki Co.,Ltd.   LT-2000   http://www.clock.co.jp/ (Japanese only)


      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 3

      +

      +
      +
      server   127.127.40.X   mode 3
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +

      -
      RS-232C
      +
      Interface
      -

      9600 Baud

      +

      RS-232C, 9600 BPS, 8-bits, no parity, 1 stop bit


      Time code format
      @@ -115,7 +177,7 @@ ( Every second before 0.5 second ) - YYMMDDWHHMMSS<ST1><ST2><ST3><ST4><CR> + YYMMDDWHHMMSS{ST1}{ST2}{ST3}{ST4}{CR} # @@ -126,17 +188,23 @@
      +
    • +
    • -

      CITIZEN T.I.C. CO.,LTD. JJY-200 http://www.tic-citizen.co.jp/ (Japanese only)

      +

      CITIZEN T.I.C. CO.,LTD.   JJY-200   http://www.tic-citizen.co.jp/ (Japanese only)


      NTP configuration ( ntp.conf )
      -
      -

      server   127.127.40.X   mode 4

      +

      +
      +
      server   127.127.40.X   mode 4
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +

      -
      RS-232C
      +
      Interface
      -

      4800 Baud

      +

      RS-232C, 4800 BPS, 8-bits, no parity, 1 stop bit


      Time code format
      @@ -150,37 +218,314 @@ ( Every second ) - 'XX YY/MM/DD W HH:MM:SS<CR> + 'XX YY/MM/DD W HH:MM:SS{CR}
      +
    • + +
    • +

      Tristate Ltd.   TS-GPSclock-01   http://www.tristate.ne.jp/ (Japanese only)

      +

      This driver supports the Tristate TS-GPSclock-01 in command/response mode, though it is a GPS clock, not JJY radio clock. Using the menus and the onboard switches, the TS-GPSclock-01 should be set to command/response mode and JST time zone.
      + Besides this driver ( Type 40 ), the generic NMEA GPS driver ( Type 20 ) supports the TS-GPSclock-01 in NMEA mode.

      +
      +
      NTP configuration ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 5
      +

      +
      fudge   127.127.40.X   time1 0.NNN   flag1 0|1
      +
      +

      Time1 may specify a constant to be added to the time offset for the time from the receiver, a fixed-point decimal number in seconds.

      +

      Flag1 has no effect for time synchronization. When a flag1 is set to 1, status command is issued before DATE and TIME commands, and write a response text into a clockstats file.

      + + + +
      0 (Default)STUS command is not issued
      1STUS command is issued
      +
      +
      +
      +
      +
      Interface
      +
      +

      USB ( /dev/ttyACM0 )

      +
      +
      +
      Time code format
      +

      + + + + + + + + + + + + + + + + + + + + + + + + + + +
      Command --> Reply
      stus{CR}{LF} --> *R{CR}{LF} | *G{CR}{LF} | *U{CR}{LF} | +U{CR}{LF}
      time{CR}{LF} --> HH:MM:SS{CR}{LF}
      date{CR}{LF} --> YYYY/MM/DD{CR}{LF}
      time{CR}{LF} --> HH:MM:SS{CR}{LF}
      +

      The date and time are requested separately. The time is requested before and after the date request to check uncertainty of the date whether it's before or after midnight.


      +
      +
      +
    • + +
    • +

      SEIKO TIME SYSTEMS INC.   TDC-300   http://www.seiko-sts.co.jp/ (English and Japanese)


      +

      The TDC-300 must be set to the type 3 data format using the front panel menu display and the switches.

      +
      +
      NTP configuration ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode 6
      +

      +
      fudge   127.127.40.X   time1 0.NNN
      +
      +
      +
      +
      Interface
      +
      +

      RS-232C, 2400 BPS, 8-bits, no parity, 1 stop bit

      +
      +
      +
      Time code format
      +

      + + + + + + + + + + + + + + + + +
      Command --> Reply
      {STX}YYMMDDWHHMMSS{ETX}
      ( 5 to 10 mSec. before second ){STX}{xE5}{ETX}
      +
      +
      +
      +
    • + +
    • +

      Telephone JJY   http://jjy.nict.go.jp/ (English and Japanese)

      +

      The telephone JJY is the time service through a public telephone line.
      + The service is provided by the National Institute of Information and Communications Technology in Japan.

      +

      ATTENTION; This mode, the telephone JJY, can not be used with the refclock_acts ( type 18 ) at the same time. + Because the "phone" statement in the ntp configuration file is not involved with the "server" statement, + so the both the refclock_acts ( type 18 ) and this refclock_jjy ( type 40, mode 100 to 180 ) can not recognize the appropriate "phone" statement among the "phone" statements.

      +
      +
      NTP configuration ( ntp.conf )
      +

      +
      +
      server   127.127.40.X   mode (100, 101 to 180)   minpoll N
      +
      +

      The mode 100 is specified, this driver does not issue the loopback command in order to measure the delay, and the delay of the telephone line and the system processing is not adjusted.
      + The mode 101 to 180 is specified, this driver issues the loopback command and measures the delay of the telephone line and the system processing through the Telphone JJY loopback circuit.
      + The round trip time through the Telphone JJY loopback circuit is measured 5 times, and each delay time is greater than 700 milli-seconds, + that delay time is ignored during average delay time calculation. Also, if the valid delay time ( <= 700 mS. ) is measured more than 3 times, the maximum delay time among the valid delay times is ignored, + and if the valid delay time is measured more than 4 times, the minimum delay time among them is ignored, like marking/grading sports judgment.
      + The adjustment time is calculated by the formula,
      + multiply ( the measured round trip time ) by ( ( the mode number ) - 100 ) %,
      + and the adjustment delay time is added to the syncronizing time.
      + If you choose the automatic delay ajustment, in other words, the mode 101 to 180 is specifed, the recommended mode number is 145 to 165.

      +

      The default polling interval 6 ( 64 seconds ) is too short for this mode. The "minpoll" should be set to greater than or equal to 8 ( 256 seconds, about 4 minutes ).
      + The interval time is given the value in second power of 2. The minpoll value 12 is 4096 seconds interval ( about 1 hour ), 14 is 16384 seconds interval ( about 4.5 hours ), 16 is 65536 seconds ( about 18 hours ), respectively.


      +
      +
      fudge   127.127.40.X   flag1 0|1   flag2 0|1   flag3 0|1   flag4 0|1
      +
      +

      Time1 may specify a constant to be added to the time offset for the time from the receiver, a fixed-point decimal number in seconds.
      + When the mode 100 is specified, the time1 may be specified in order to adjust the time offset.
      + When the mode 101 to 180 is specified, the time1 should not be specified because this driver adds some percentage of the measured loopback delay, depending on the value of the mode number.

      +
      Flag1 is the modem dialing type.
      + + + +
      0 (Default)ToneATDWTnn...nn
      1PulseATDWPnn...nn
      +
      +
      Flag2 is the modem error correction type.
      + + + +
      0 (Default)NormalAT\N0
      1Auto V42, MNP, NormalAT\N3
      +
      +
      Flag3 is the modem speaker switch.
      + + + +
      0 (Default)OffATM0Ln
      1OnATM2Ln
      +
      +
      Flag4 is the modem speaker volume.
      + + + +
      0 (Default)LowATMnL1
      1MiddleATMnL2
      +
      +
      +
      phone 042NNNNNNN
      +
      +

      The phone number is available at http://jjy.nict.go.jp/
      + The number of digits of the phone number is checked. If the international access number and the country number are added in order to call from outside of Japan, the number of digits is over the limit.
      + The first 2 or 3 digits are checked. The emergency service number and the special service number in Japan are not allowed.
      + Calling from extension line, the number for an outside line should be prefix "0," ( Zero, Comma ). The prefix is also checked, and no other outside access number is allowed.

      +
      +
      +
      +
      +
      Interface
      +
      +

      RS-232C or USB, 2400 BPS, 8-bits, no parity, 1 stop bit

      +

      Modem control commands:
      + ATE0Q0V1, ATMnLn, AT&K4, AT+MS=V22B, AT%C0, AT\Nn, ATH1, ATDWxnn...nn
      + +++, ATH0

      +
      +
      +
      Time code format
      +

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      Prompt --> Command --> Reply
      Name{SP}?{SP} --> TJJY{CR} --> Welcome messages
      > --> LOOP{CR} --> ( Switch to the loopback circuit )
         ( One char. ) --> ( One char. )
         COM{CR} --> ( Exit from the loopback circuit )
      > --> TIME{CR} --> HHMMSS{CR}HHMMSS{CR}HHMMSS{CR} 3 times on second
      > --> 4DATE{CR} --> YYYYMMDD{CR}
      > --> LEAPSEC{CR} --> {SP}0{CR} | +1{CR} | -1{CR}
      > --> TIME{CR} --> HHMMSS{CR}HHMMSS{CR}HHMMSS{CR} 3 times on second
      > --> BYE{CR} --> Sayounara messages
      +

      The date and time are requested separately. The time is requested before and after the date request to check uncertainty of the date whether it's before or after midnight.
      + The leap second is not handled, and only written in the clockstats file as an information.

      +
      +
      +
      +
    • +
    -

    JJY is the radio station which transmites the JST (Japan Standard Time) in long wave radio. The station JJY is operated by the National Institute of Information and Communications Technology. An operating announcement and some information are avaiable from http://www.nict.go.jp/ (English and Japanese) and http://jjy.nict.go.jp/ (English and Japanese)

    -

    The user is expected to provide a symbolic link to an available serial port device. This is typically performed by a command such as:

    + +

    The JJY is the radio station which transmits the JST (Japan Standard Time) in long wave radio. The station JJY is operated by the National Institute of Information and Communications Technology. + An operating announcement and some information are available from http://www.nict.go.jp/ (English and Japanese) and http://jjy.nict.go.jp/ (English and Japanese)

    +

    The user is expected to provide a symbolic link to an available serial port device. This is typically performed by a command such as;

    ln -s /dev/ttyS0 /dev/jjy0

    +

    Using an RS-232C to USB converter cable, the clock or a modem can be connected to a USB port instead of a serial port. In this case, the typical symbolic link command is as follows;

    +

    ln -s /dev/ttyUSB0 /dev/jjy0

    Windows NT does not support symbolic links to device files. COMX: is the unit used by the driver, based on the refclock unit number, where unit 1 corresponds to COM1: and unit 3 corresponds to COM3:

    Monitor Data

    -

    The driver writes each timecode as received to the clockstats file.

    +

    The driver writes sent and received data to/from the JJY receivers, GPS clock, and the modem into the clockstats file.

    +

    + statsdir /var/log/ntpd/
    + filegen clockstats file clockstats type day enable +

    +
    Mark of the clockstats record
    + + + + + + + + +
    JJY Infomation message ( This refclock starts or stops. )
    --> Sent data
    <-- Received data
    --- Infomation message
    === Infomation message ( Start of each polling, and sync. time. )
    -W- Warning message
    -X- Error message

    Fudge Factors

    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default JJY. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Not used by this driver. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    Not used by this driver. +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default JJY.
    +
    flag1 0 | 1
    +
    See corresponding receiver.
    +
    flag2 0 | 1
    +
    See corresponding receiver.
    +
    flag3 0 | 1
    +
    See corresponding receiver.
    +
    flag4 0 | 1
    +
    See corresponding receiver.

    diff --git a/contrib/ntp/html/drivers/driver42.html b/contrib/ntp/html/drivers/driver42.html index 70820508e..86f676e3e 100644 --- a/contrib/ntp/html/drivers/driver42.html +++ b/contrib/ntp/html/drivers/driver42.html @@ -10,6 +10,9 @@

    Zyfer GPStarplus Receiver

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    Address: 127.127.42.u
    @@ -27,4 +30,4 @@ - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver43.html b/contrib/ntp/html/drivers/driver43.html index 0e1553fce..6d04102dd 100644 --- a/contrib/ntp/html/drivers/driver43.html +++ b/contrib/ntp/html/drivers/driver43.html @@ -10,6 +10,9 @@

    RIPE NCC interface for Trimble Palisade

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Trimble Acutime 2000

    Synopsis

    @@ -62,4 +65,4 @@ S1 [prn] [channel] [aqflag] [ephstat] [snr] [azinuth] [elevation] - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver44.html b/contrib/ntp/html/drivers/driver44.html index d2cddb9c7..a3fac5c5a 100644 --- a/contrib/ntp/html/drivers/driver44.html +++ b/contrib/ntp/html/drivers/driver44.html @@ -11,6 +11,9 @@

    NeoClock4X - DCF77 / TDF serial line receiver

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Synopsis

    @@ -85,4 +88,4 @@ - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver45.html b/contrib/ntp/html/drivers/driver45.html new file mode 100644 index 000000000..bef883fe8 --- /dev/null +++ b/contrib/ntp/html/drivers/driver45.html @@ -0,0 +1,32 @@ + + + + + + + Spectracom TSYNC PCI + + + + +

    Spectracom TSYNC PCI

    +

    Last update: + 26-Mar-2012 05:10 + UTC

    +
    +

    Synopsis

    + Address: 127.127.45.u
    + Reference ID: one of GPS, IRIG, HVQ, FREQ, ACTS, PPS, PTP, ACT, USR, LOCL
    + Driver ID: Spectracom TSYNC PCI
    + Driver Port: /dev/tsyncpciu + Features: (none) +

    Description

    +

    This driver supports the Spectracom TSYNC PCI receiver.

    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + + + diff --git a/contrib/ntp/html/drivers/driver46.html b/contrib/ntp/html/drivers/driver46.html new file mode 100644 index 000000000..cdb0b6899 --- /dev/null +++ b/contrib/ntp/html/drivers/driver46.html @@ -0,0 +1,363 @@ + + + GPSD-NG client driver + + + + + + + +

    GPSD NG client driver

    +

    Last update: + 30-Apr-2015 05:53 + UTC

    +
    +

    Synopsis

    + +

    + Address: 127.127.46.u
    + Reference ID: GPSD
    + Driver ID: GPSD_JSON
    + Serial Port: /dev/gpsu as symlink to the true + device (not used directly; see below)
    + Features: +

    + + + +

    Description

    +

    + This driver is a client driver to the GPSD daemon, which + over the time became increasingly popular for UN*Xish + platforms. GPSD can manage several devices in parallel, + aggregate information, and acts as a data hub for client + applications. GPSD can also auto-detect and handle PPS + hardware signals on serial ports. Have a look + at the + GPSD project page. +

    +

    + It is important to understand that this driver works best + using a GPS device with PPS support. +

    +

    + The GPSD-NG protocol is text based, using JSON notation to + transfer records in form of JSON objects. The driver uses a + TCP/IP connection to localhost:gpsd to connect to the + daemon and then requests the GPS + device /dev/gpsu to be watched. (Different clock + units use different devices, and + GPSD is able to give only the relevant information to a clock + instance.) +

    +

    + This driver does not expect GPSD to be running or the + clock device to be present a priori; it will try to + re-establish a lost or hitherto unsuccessful connection and will + wait for device to come up in GPSD. There is an initial + 10 seconds delay between a connection loss or failed attempt and + the next reconnect attempt; this makes sure that there is no + thrashing on the network layer. If the connection fails again, + an exponential back off is used with an upper limit of + approximately 10 minutes. +

    +

    + The overall accuracy depends on the receiver used. The driver + uses the error estimations (95% probability limits) provided by + GPSD to set the clock precision dynamically according to + these readings. +

    +

    + The driver needs the VERSION, TPV, PPS, WATCH and TOFF objects + of the GPSD protocol. (Others are quietly ignored.) The + driver can operate without the TOFF objects, which are available + with the protocol version 3.10 and above. (Not to be + confused with the release version of GPSD!) + Running without TOFF objects has a negative impact on the jitter + and offset of the serial timing information; if possible, a + version of GPSD with support for TOFF objects should be + used. +

    +

    The acronym STI is used here as a synonym for serial + time information from the data channel of the receiver, no + matter what objects were used to obtain it. +

    + + + +

    Naming a Device

    +

    + The GPSD driver uses the same device name as the NMEA + driver, namely /dev/gpsu. There is a simple + reason for that: While the NMEA driver and the GPSD + driver can be active at the same time for different + devices, they cannot access the same device at a + time. Having the same name helps on that. It also eases + migration from using NMEA directly to using GPSD, as no + new links etc need to be created. +

    +

    + GPSD is normally started with the device name to access; + it can also be instructed by hot-plug scripts to add or remove + devices from its device pool. Luckily, the symlinks used by the + NMEA driver are happily accepted and used by GPSD; this + makes it possible to use the symlink names as device + identification. This makes the migration from the built-in NMEA + driver a bit easier. +

    +

    Note: GPSD (as of version 3.10) cannot use kernel + mode PPS on devices that are hot-plugged. This would require to + attach the PPS line discipline to the character special file, + which is not possible when running with root privileges already + dropped. This is not likely to change in the future. +

    + + + +

    The 'mode' word

    +

    + A few operation modes can be selected with the mode word. +

    +

    +

    + + + + + + + + + + + + + + + + + + + + + + +
    The Mode Word
    BitsValueDescription
    0..10STI only operation. This mode is affected by the timing + stability of whatever protocol is used between the GPS + device and GPSD. +
    + Running on STI only is not recommended in general. Possible + use cases include: +
      +
    • The receiver does not provide a PPS signal. +
    • The receiver does provide a PPS signal and + the secondary PPS unit is used. +
    • The receiver has a stable serial timing and a proper + fudge can be established. +
    • You have other time sources available and want to + establish a useful fudge value for time2. +
    +
    1Strict operation. This mode needs a valid PPS and a + valid STI to combine the absolute time from the STI with + the time stamp from the PPS record. Does not feed clock + samples if no valid PPS+STI pair is available. +

    + This type of operation results in an ordinary clock with a + very low jitter as long as the PPS data is available, but + the clock fails once PPS drops out. This mode is a + possible choice for receivers that provide a PPS signal + most of the time but have an unstable serial timing that + cannot be fudge-compensated. +
    2Automatic mode. Tries to operate in strict mode unless + it fails to process valid samples for some time, currently + 120s. Then it reverts to STI-only operation until the PPS + is stable again for 40s, when strict mode is engaged + again. +

    Important Notice: This is an expiremental + feature!
    Switching between strict and STI-only + mode will cause changes in offset and jitter. Use this + mode only if STI-only works fairly well with your setup, + or if you expect longer dropouts of the PPS signal and + prefer to use STI alone over not getting synchronised at + all.
    3(reserved for future extension, do not use)
    2..31(reserved for future extension, do not + use)
    +

    + + + +

    Syslog flood throttle

    +

    This driver can create a lot of syslog messages when things go + wrong, and cluttering the log files is frowned upon. So we + attempt to log persistent or recurring errors only once per + hour. On the other hand, when tracking a problem the syslog + flood throttle can get into the way.

    +

    Therefore, fudge flag3 can be used to disable the + flood throttle at any time; the throttle is engaged by + default. Running with the syslog flood throttle disabled for + lengthy time is not recommended unless the log files are closely + monitored.

    + + + +

    PPS secondary clock unit

    +

    Units with numbers ≥128 act as secondary clock unit for the + primary clock unit (u mod 128). A secondary unit processes only + the PPS data from GPSD and needs the corresponding master + unit to work1. Use + the 'noselect' keyword on the primary unit if you are not + interested in its data. +

    The secondary unit employs the usual precautions before + feeding clock samples:

    +
      +
    • The system must be already in a synchronised state. +
    • The system offset must be less than 400ms absolute. +
    • The phase adjustment from the PPS signal must also be less + than 400ms absolute. +
    +

    If fudge flag flag1 is set for the secondary unit, the + unit asserts the PPS flag on the clock as long as PPS data is + available. This makes the unit eligible as PPS peer and should + only be used if the GPS receiver can be trusted for the quality + of its PPS signal2. The PPS flag gets cleared if no + PPS records can be aquired for some time. The unit also flushes + the sample buffer at this point to avoid the use of stale PPS + data.

    +

    Attention: This unit uses its own PPS fudge value + which must be set as fudge time1. Only the fudge + values time1 and flag1 have an impact on secondary + units.

    + + + +

    Clockstats

    +

    If flag4 is set when the driver is polled, a clockstats record + is written for the primary clock unit. (The secondary PPS unit + does not provide clock stats on its own.) The first 3 fields are + the normal date, time, and IP address common to all clockstats + records. +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    The Clockstats Line
    fieldDescription
    1Date as day number since NTP epoch.
    2Time as seconds since midnight.
    3(Pseudo-) IP address of clock unit.
    4Number of received known JSON records since last + poll. The driver knows about TPV, PPS, TOFF, VERSION and + WATCH records; others are silently ignored. +
    5Bad replies since last poll. A record is considered + malformed or a bad reply when it is missing vital fields + or the fields contain malformed data that cannot be + parsed. +
    6Number of sample cycles since last poll that were + discarded because there was no GPS fix. This is + effectively the number of TPV records with a fix value + < 2 or without a time stamp. +
    7Number of serial time information records (TPV or TOFF, + depending on the GPSD version) received since last poll. +
    8Number of serial time information records used for + clock samples since the last poll. +
    9Number of PPS records received since the last poll.
    10Number of PPS records used for clock samples on the + secondary channel since the last poll. +
    +

    + + + +

    Fudge Factors

    + +
    +
    time1 time
    +
    Specifies the PPS time offset calibration factor, in seconds + and fraction, with default 0.0.
    +
    time2 time
    +
    [Primary Unit] Specifies the TPV/TIME time offset + calibration factor, in seconds and fraction, with default + 0.0.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with + default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string + from one to four characters, with default GPSD.
    +
    flag1 0 | 1
    [Secondary + Unit] When set, flags the secondary clock unit as a + potential PPS peer as long as good PPS data is available. +
    +
    flag2 0 | 1
    +
    [Primary Unit] When set, disables the + processing of incoming PPS records. Intended as an aide to + test the effects of a PPS dropout when using automatic mode + (mode 2). +
    +
    flag3 0 | 1
    [Primary Unit] + If set, disables the log throttle. Useful when tracking + problems in the interaction between GPSD and NTPD, + since now all error events are logged. Persistent/recurrent + errors can easily fill up the log, so this should only be + enabled during bug hunts.
    +
    flag4 0 | 1
    [Primary Unit] + If set, write a clock stats line on every poll cycle. +
    +
    + + + +
    +

    1) Data transmission + an decoding is done only once by the primary unit. The decoded + data is then processed independently in both clock units. This + avoids double transmission over two sockets and decoding the + same data twice, but the primary unit is always needed as a + downside of this approach. +

    +

    2) The clock driver + suppresses the processing PPS records when the TPV/TIME data + indicates the receiver has no fix. It can also deal with + situations where the PPS signal is not delivered + to GPSD. But once it is available, it is also processed + and used to create samples. If a receiver cannot be trusted for + the precision of its PPS signal, it should not be used to create + a possible PPS peer: These get extra clout and can effectively + become the sole source of input for the control loop. You do not + want to use sloppy data for that. +


    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + diff --git a/contrib/ntp/html/drivers/driver5.html b/contrib/ntp/html/drivers/driver5.html index 1b539acaa..fa19764fa 100644 --- a/contrib/ntp/html/drivers/driver5.html +++ b/contrib/ntp/html/drivers/driver5.html @@ -2,71 +2,82 @@ - - - TrueTime GPS/GOES/OMEGA Receivers - - + + + TrueTime GPS/GOES/OMEGA/WWV Receivers + + - -

    TrueTime GPS/GOES/OMEGA Receivers

    -
    -

    Synopsis

    - Address: 127.127.5.u
    - Reference ID: GPS, OMEGA, GOES
    - Driver ID: TRUETIME
    - Serial Port: /dev/trueu; 9600 baud, 8-bits, no parity
    - Features: tty_clk -

    Description

    -

    This driver supports several models models of Kinemetrics/TrueTime timing receivers, including 468-DC MK III GOES Synchronized Clock, GPS- DC MK III and GPS/TM-TMD GPS Synchronized Clock, XL-DC (a 151-602-210, reported by the driver as a GPS/TM-TMD), GPS-800 TCU (an 805-957 with the RS232 Talker/Listener module), OM-DC OMEGA Synchronized Clock, and very likely others in the same model family that use the same timecode formats.

    -

    Most of this code is originally from refclock_wwvb.c with thanks. It has been so mangled that wwvb is not a recognizable ancestor.

    -

    Timcode format: ADDD:HH:MM:SSQCL A - control A (this is stripped before we see it) Q - Quality indication (see below) C - Carriage return L - Line feed Quality codes indicate possible error of

    -
    -
    468-DC GOES Receiver
    - GPS-TM/TMD Receiver -
    ? +/- 500 milliseconds # +/- 50 milliseconds
    - * +/- 5 milliseconds . +/- 1 millisecond
    - space less than 1 millisecond -
    OM-DC OMEGA Receiver: -
    > +/- 5 seconds
    - ? +/- 500 milliseconds # +/- 50 milliseconds
    - * +/- 5 milliseconds . +/- 1 millisecond
    - A-H less than 1 millisecond. Character indicates which station is being received as follows
    - A = Norway, B = Liberia, C = Hawaii, D = North Dakota, E = La Reunion, F = Argentina, G = Australia, H = Japan
    - The carriage return start bit begins on 0 seconds and extends to 1 bit time. -
    -

    Notes on 468-DC and OMEGA receiver:

    -

    Send the clock a R or C and once per second a timestamp will appear. Send a R to get the satellite position once (GOES only).

    -

    Notes on the 468-DC receiver:

    -

    Since the old east/west satellite locations are only historical, you can't set your clock propagation delay settings correctly and still use automatic mode. The manual says to use a compromise when setting the switches. This results in significant errors. The solution; use fudge time1 and time2 to incorporate corrections. If your clock is set for 50 and it should be 58 for using the west and 46 for using the east, use the line

    -

    fudge 127.127.5.0 time1 +0.008 time2 -0.004

    -

    This corrects the 4 milliseconds advance and 8 milliseconds retard needed. The software will ask the clock which satellite it sees.

    -

    The PCL720 from PC Labs has an Intel 8253 look-alike, as well as a bunch of TTL input and output pins, all brought out to the back panel. If you wire a PPS signal (such as the TTL PPS coming out of a GOES or other Kinemetrics/Truetime clock) to the 8253's GATE0, and then also wire the 8253's OUT0 to the PCL720's INPUT3.BIT0, then we can read CTR0 to get the number of microseconds since the last PPS upward edge, mediated by reading OUT0 to find out if the counter has wrapped around (this happens if more than 65535us (65ms) elapses between the PPS event and our being called.)

    -

    Monitor Data

    -

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, to be used for the West satellite, with default 0.0. -
    time2 time -
    . Specifies the time offset calibration factor, in seconds and fraction, to be used for the East satellite, with default 0.0. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default TRUE. -
    flag1 0 | 1 -
    Silence the clock side of ntpd, just reading the clock without trying to write to it. -
    flag2 0 | 1 -
    Generate a debug file /tmp/true%d. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - + +

    TrueTime GPS/GOES/OMEGA/WWV Receivers

    +
    +

    Synopsis

    + Address: 127.127.5.u
    + Reference ID: GPS, OMEGA, GOES, WWV
    + Driver ID: TRUETIME
    + Serial Port: /dev/trueu; 9600 baud, 8-bits, no parity
    + Features: tty_clk +

    Description

    +

    This driver supports several models models of Kinemetrics/TrueTime timing receivers, including 468-DC MK III GOES Synchronized Clock, GPS- DC MK III and GPS/TM-TMD GPS Synchronized Clock, XL-DC (a 151-602-210, reported by the driver as a GPS/TM-TMD), GPS-800 TCU (an 805-957 with the RS232 Talker/Listener module), OM-DC OMEGA Synchronized Clock, the TL-3 WWV receiver, and very likely others in the same model families that use the same timecode formats.

    +

    Most of this code is originally from refclock_wwvb.c with thanks. It has been so mangled that wwvb is not a recognizable ancestor.

    +

    Timcode format: ADDD:HH:MM:SSQCL
    +A - control A (this is stripped before we see it) Q - Quality indication (see below) C - Carriage return L - Line feed


    +Quality codes indicate possible error of: +
    +
    468-DC GOES Receiver
    + GPS-TM/TMD Receiver +
    ? +/- 500 milliseconds # +/- 50 milliseconds
    + * +/- 5 milliseconds . +/- 1 millisecond
    + space less than 1 millisecond +
    OM-DC OMEGA Receiver: +
    > +/- 5 seconds
    + ? +/- 500 milliseconds # +/- 50 milliseconds
    + * +/- 5 milliseconds . +/- 1 millisecond
    + A-H less than 1 millisecond. Character indicates which station is being received as follows
    + A = Norway, B = Liberia, C = Hawaii, D = North Dakota, E = La Reunion, F = Argentina, G = Australia, H = Japan
    + The carriage return start bit begins on 0 seconds and extends to 1 bit time. +
    TL-3 WWV Receiver: +
    ? receiver is unlocked
    +
    space +/- 5 milliseconds
    +
    +

    Notes on 468-DC and OMEGA receiver:

    +

    Send the clock a R or C and once per second a timestamp will appear. Send a R to get the satellite position once (GOES only).

    +

    Notes on the 468-DC receiver:

    +

    Since the old east/west satellite locations are only historical, you can't set your clock propagation delay settings correctly and still use automatic mode. The manual says to use a compromise when setting the switches. This results in significant errors. The solution; use fudge time1 and time2 to incorporate corrections. If your clock is set for 50 and it should be 58 for using the west and 46 for using the east, use the line

    +

    fudge 127.127.5.0 time1 +0.008 time2 -0.004

    +

    This corrects the 4 milliseconds advance and 8 milliseconds retard needed. The software will ask the clock which satellite it sees.

    +

    The PCL720 from PC Labs has an Intel 8253 look-alike, as well as a bunch of TTL input and output pins, all brought out to the back panel. If you wire a PPS signal (such as the TTL PPS coming out of a GOES or other Kinemetrics/Truetime clock) to the 8253's GATE0, and then also wire the 8253's OUT0 to the PCL720's INPUT3.BIT0, then we can read CTR0 to get the number of microseconds since the last PPS upward edge, mediated by reading OUT0 to find out if the counter has wrapped around (this happens if more than 65535us (65ms) elapses between the PPS event and our being called.)

    +

    Notes on the TL-3 receiver:

    +

    The mini-DIN RS-232 port uses the Apple pinout.
    + Send the clock ST1 to turn on continuous (1/sec) timecodes. +You can also enable "mode C" via the front panel. ST0 turns off this mode.
    +QV will return the firmware revision (and is useful in identifying this clock.)
    +QW will return its weekly signal log, useful if you're testing antennas. You may wish to turn the loss interval down from 4h (04) to 1h (01), so the receiver declares itself unlocked sooner. When in holdover, drift can be on the order of 10 ms/hr since there is no high quality reference oscillator.

    +

    Monitor Data

    +

    When enabled by the flag4 fudge flag, every received timecode is written as-is to the clockstats file.

    +

    Fudge Factors

    +
    +
    time1 time +
    Specifies the time offset calibration factor, in seconds and fraction, to be used for the West satellite, with default 0.0. +
    time2 time +
    . Specifies the time offset calibration factor, in seconds and fraction, to be used for the East satellite, with default 0.0. +
    stratum number +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. +
    refid string +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default TRUE. +
    flag1 0 | 1 +
    Silence the clock side of ntpd, just reading the clock without trying to write to it. +
    flag2 0 | 1 +
    Generate a debug file /tmp/true%d. +
    flag3 0 | 1 +
    Not used by this driver. +
    flag4 0 | 1 +
    Enable verbose clockstats recording if set. +
    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/driver6.html b/contrib/ntp/html/drivers/driver6.html index 8a51f16f0..ebb3683a9 100644 --- a/contrib/ntp/html/drivers/driver6.html +++ b/contrib/ntp/html/drivers/driver6.html @@ -1,92 +1,80 @@ - - - - - - IRIG Audio Decoder - - - - -

    IRIG Audio Decoder

    -
    -

    Synopsis

    - Address: 127.127.6.u
    - Reference ID: IRIG
    - Driver ID: IRIG_AUDIO
    - Audio Device: /dev/audio and /dev/audioctl -

    Note: This driver supersedes an older one of the same name, address and ID which required replacing the original kernel audio driver with another which worked only on older Sun SPARC architectures and SunOS operating systems. The new driver requires no modification of the operating system and works on FreeBSD, SunOS and Solaris. While it is generic and likely portable to other systems, it is somewhat slower than the original, since the extensive signal conditioning, filtering and decoding is done in user space, not kernel space.

    -

    Description

    -

    This driver supports the Inter-Range Instrumentation Group (IRIG) standard time distribution signal using the audio codec native to some workstations. This signal is generated by several radio clocks, including those made by Arbiter, Austron, Bancomm, Odetics, Spectracom and TrueTime, among others, although it is often an add-on option. The signal is connected via an optional attenuator box and cable to either the microphone or line-in port. The driver receives, demodulates and decodes the IRIG-B and IRIG-E signal formats using internal filters designed to reduce the effects of noise and interference.

    -

    This driver incorporates several features in common with other audio drivers such as described in the Radio CHU Audio Demodulator/Decoder and the Radio WWV/H Audio Demodulator/Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    -

    The IRIG signal format uses an amplitude-modulated carrier with pulse-width modulated data bits. For IRIG-B, the carrier frequency is 1000 Hz and bit rate 100 b/s; for IRIG-E, the carrier frequenchy is 100 Hz and bit rate 10 b/s. While IRIG-B provides the best accuracy, generally within a few tens of microseconds relative to IRIG time, it can also generate a significant load on the processor with older workstations. Generally, the accuracy with IRIG-E is about ten times worse than IRIG-B, but the processor load is ten times less.

    -

    The program processes 8000-Hz m-law companded samples using separate signal filters for IRIG-B and IRIG-E, a comb filter, envelope detector and automatic threshold corrector. Cycle crossings relative to the corrected slice level determine the width of each pulse and its value - zero, one or position identifier. The data encode 20 BCD digits which determine the second, minute, hour and day of the year and sometimes the year and synchronization condition. The comb filter exponentially averages the corresponding samples of successive baud intervals in order to reliably identify the reference carrier cycle. A type-II phase-lock loop (PLL) performs additional integration and interpolation to accurately determine the zero crossing of that cycle, which determines the reference timestamp. A pulse-width discriminator demodulates the data pulses, which are then encoded as the BCD digits of the timecode. The timecode and reference timestamp are updated once each second with IRIG-B (ten seconds with IRIG-E) and local clock offset samples saved for later processing. At poll intervals of 64 s, the saved samples are processed by a trimmed-mean filter and used to update the system clock.

    -

    Infinite impulse response (IIR) filters are used with both IRIG-B and IRIG-E formats. An 800-Hz highpass filter is used for IRIG-B and a 130-Hz lowpass filter for IRIG-E. These are intended for use with noisy signals, such as might be received over a telephone line or radio circuit, or when interfering signals may be present in the audio passband. The driver determines which IRIG format is in use by sampling the amplitude of each filter output and selecting the one with maximum signal. An automatic gain control feature provides protection against overdriven or underdriven input signal amplitudes. It is designed to maintain adequate demodulator signal amplitude while avoiding occasional noise spikes. In order to assure reliable capture, the decompanded input signal amplitude must be greater than 100 units and the codec sample frequency error less than 250 PPM (.025 percent).

    -

    The program performs a number of error checks to protect against overdriven or underdriven input signal levels, incorrect signal format or improper hardware configuration. The specific checks are detailed later in this page. Note that additional checks are done elsewhere in the reference clock interface routines.

    -

    Unlike other drivers, which can have multiple instantiations, this one supports only one. It does not seem likely that more than one audio codec would be useful in a single machine. More than one would probably chew up too much CPU time anyway.

    -

    IRIG-B Timecode Format

    -

    The 100 elements of the IRIG timecode are numbered from 0 through 99. Position identifiers occur at elements 0, 9, 19 and every ten thereafter to 99. The control function (CF) elements begin at element 50 (CF 1) and extend to element 78 (CF 27). The straight-binary-seconds (SBS) field, which encodes the seconds of the UTC day, begins at element 80 (CF 28) and extends to element 97 (CF 44). The encoding of elements 50 (CF 1) through 78 (CF 27) is device dependent. This driver presently decodes the CF elements, but does nothing with them.

    -

    Where feasible, the IRIG signal source should be operated with signature control so that, if the signal is lost or mutilated, the source produces an unmodulated signal, rather than possibly random digits. The driver will automatically reject the data and declare itself unsynchronized in this case. Some devices, in particular Spectracom radio/satellite clocks, provide additional year and status indication in the format:

    -
    -     Element   CF        Function
    -     -------------------------------------
    -     55        6         time sync status
    -     60-63     10-13     BCD year units
    -     65-68     15-18     BCD year tens
    -
    - Other devices set these elements to zero. -

    Performance and Horror Stories

    -

    The m-law companded data format allows considerable latitude in signal levels; however, an automatic gain control (AGC) function is implemented to further compensate for varying input signal levels and to avoid signal distortion. For proper operation, the IRIG signal source should be configured for analog signal levels, NOT digital TTL levels.

    -

    The accuracy of the system clock synchronized to the IRIG-B source with this driver and the ntpd daemon is 10-20 ms with a Sun UltraSPARC II running Solaris 2.6 and maybe twice that with a Sun SPARC IPC running SunOS 4.1.3. Be however acutely aware that the accuracy with Solaris 2.8 and presumably beyond has seriously degraded to the order of several milliseconds. The Sun kernel driver has a sawtooth modulation with amplitude over 5 ms peak-peak and period 5.5 s. The crafty IRIG driver uses a transverse filter to remove the modulation and something called a botttom-fisher to remove incidental positive spikes especially prevalent with Sun Blade 1000 and possibly other systems. The result is nominal accuracy and jitter something less than 0.5 ms, but the this is still far inferior to the performance with older systems.

    -

    The processor resources consumed by the daemon can be significant, ranging from about 1.2 percent on the faster UltraSPARC II to 38 percent on the slower SPARC IPC. However, the overall timing accuracy is limited by the resolution and stability of the CPU clock oscillator and the interval between clock corrections, which is 64 s with this driver. This performance, while probably the best that can be achieved by the daemon itself, can be improved with assist from the PPS discipline as described elsewhere in this documentation.

    -

    Autotune

    -

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a serial port using a level converter such as the CT-17.

    -

    Each ICOM radio is assigned a unique 8-bit ID select code, usually expressed in hex format. To activate the CI-V interface, the mode keyword of the server configuration command specifies a nonzero select code in decimal format. A table of ID select codes for the known ICOM radios is given on the Reference Clock Audio Drivers page. A missing mode keyword or a zero argument leaves the interface disabled.

    -

    If specified, the driver will attempt to open the device /dev/icom and, if successful will activate the autotune function and tune the radio to each operating frequency in turn while attempting to acquire minute sync from CHU. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus or radio is inoperative, the driver quietly gives up with no harm done.

    -

    Monitor Data

    - The timecode format used for debugging and data recording includes data helpful in diagnosing problems with the IRIG signal and codec connections. With debugging enabled (-d on the ntpd command line), the driver produces one line for each timecode in the following format: -

    00 1 98 23 19:26:52 721 143 0.694 47 20 0.083 66.5 3094572411.00027

    -

    The first field containes the error flags in hex, where the hex bits are interpreted as below. This is followed by the IRIG status indicator, year of century, day of year and time of day. The status indicator and year are not produced by some IRIG devices. Following these fields are the carrier amplitude (0-8100), codec gain (0-255), field phase (0-79), time constant (2-20), modulation index (0-1), carrier phase error (0±0.5) and carrier frequency error (PPM). The last field is the on-time timestamp in NTP format. The fraction part is a good indicator of how well the driver is doing. With an UltrSPARC 30, this is normally within a few tens of microseconds relative to the IRIG-B signal and within a few hundred microseconds with IRIG-E.

    -

    The error flags are defined as follows in hex:

    -
    -
    x01 -
    Low signal. The carrier amplitude is less than 100 units. This is usually the result of no signal or wrong input port. -
    x02 -
    Frequency error. The codec frequency error is greater than 250 PPM. This may be due to wrong signal format or (rarely) defective codec. -
    x04 -
    Modulation error. The IRIG modulation index is less than 0.5. This is usually the result of an overdriven codec, wrong signal format or wrong input port. -
    x08 -
    Frame synch error. The decoder frame does not match the IRIG frame. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal. It may also be the result of an IRIG signature check which indicates a failure of the IRIG signal synchronization source. -
    x10 -
    Data bit error. The data bit length is out of tolerance. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal. -
    x20 -
    Seconds numbering discrepancy. The decoder second does not match the IRIG second. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal. -
    x40 -
    Codec error (overrun). The machine is not fast enough to keep up with the codec. -
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default IRIG. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Specifies the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port. -
    flag3 0 | 1 -
    Enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file + + + +IRIG Audio Decoder + + + +

    IRIG Audio Decoder

    +

    Author: David L. Mills (mills@udel.edu)
    +Last update: + 17-Jul-2014 02:17 + UTC

    +
    +

    Synopsis

    +Address: 127.127.6.u
    +Reference ID: IRIG
    +Driver ID: IRIG_AUDIO
    +Audio Device: /dev/audio and /dev/audioctl +

    Description

    +

    This driver synchronizes the computer time using the Inter-Range Instrumentation Group (IRIG) standard time distribution signal. This signal is generated by several radio clocks, including those made by Arbiter, Austron, Bancomm, Odetics, Spectracom, Symmetricom and TrueTime, among others, although it is often an add-on option. The signal is connected via an optional attenuator and cable to either the microphone or line-in port of a workstation or PC.

    +

    The driver requires an audio codec or sound card with sampling rate 8 kHz and μ-law companding to demodulate the data. This is the same standard as used by the telephone industry and is supported by most hardware and operating systems, including Solaris, FreeBSD and Linux, among others. In this implementation, only one audio driver and codec can be supported on a single machine. In order to assure reliable signal capture, the codec frequency error must be less than 250 PPM (.025 percent). If necessary, the tinker codec configuration command can be used to bracket the codec frequency to this range.

    +

    For proper operation the IRIG signal source should be configured for analog signal levels, not digital TTL levels. In most radios the IRIG signal is driven ±10 V behind 50 Ohms. In such cases the cable should be terminated at the line-in port with a 50-Ohm resistor to avoid overloading the codec. Where feasible, the IRIG signal source should be operated with signature control so that, if the signal is lost or mutilated, the source produces an unmodulated signal, rather than possibly random digits. The driver automatically rejects the data and declares itself unsynchronized in this case. Some devices, in particular Spectracom radio/satellite clocks, provide additional year and status indication; other devices may not.

    +

    In general and without calibration, the driver is accurate within 500 μs relative to the IRIG time. After calibrating relative to the PPS signal from a GPS receiver, the mean offset with a 2.4-GHz P4 running FreeBSD 6.1 is less than 20 μs with standard deviation 10 μs. Most of this is due to residuals after filtering and averaging the raw codec samples, which have an inherent jitter of 125 μs. The processor load due to the driver is 0.6 percent on the P4.

    +

    However, be acutely aware that the accuracy with Solaris 2.8 and beyond has been seriously degraded to the order of several milliseconds. The Sun kernel driver has a sawtooth modulation with amplitude over 5 ms P-P and period 5.5 s. This distortion is especially prevalent with Sun Blade 1000 and possibly other systems.

    +

    The driver performs a number of error checks to protect against overdriven or underdriven input signal levels, incorrect signal format or improper hardware configuration. The specific checks are detailed later in this page. Note that additional checks are done elsewhere in the reference clock interface routines.

    +

    This driver incorporates several features in common with other audio drivers such as described in the Radio CHU Audio Demodulator/Decoder and the Radio WWV/H Audio Demodulator/Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    +

    Technical Overview

    +

    The IRIG signal format uses an amplitude-modulated carrier with pulse-width modulated data bits. For IRIG-B, the carrier frequency is 1000 Hz and bit rate 100 b/s; for IRIG-E, the carrier frequenchy is 100 Hz and bit rate 10 b/s. While IRIG-B provides the best accuracy, generally within a few tens of microseconds relative to IRIG time, it can also generate a significant processor load with older workstations. Generally, the accuracy with IRIG-E is about ten times worse than IRIG-B, but the processor load is somewhat less. Technical details about the IRIG formats can be found in IRIG Standard 200-98.

    +

    The driver processes 8000-Hz μ-law companded samples using separate signal filters for IRIG-B and IRIG-E, a comb filter, envelope detector and automatic threshold corrector. An infinite impulse response (IIR) 1000-Hz bandpass filter is used for IRIG-B and an IIR 130-Hz lowpass filter for IRIG-E. These are intended for use with noisy signals, such as might be received over a telephone line or radio circuit, or when interfering signals may be present in the audio passband. The driver determines which IRIG format is in use by sampling the amplitude of each filter output and selecting the one with maximum signal.

    +

    Cycle crossings relative to the corrected slice level determine the width of each pulse and its value - zero, one or position identifier (PI). The data encode ten characters (20 BCD digits) which determine the second, minute, hour and day of the year and with some IRIG generators the year and synchronization condition. The comb filter exponentially averages the corresponding samples of successive baud intervals in order to reliably identify the reference carrier cycle.

    +

    A type-II phase-lock loop (PLL) performs additional integration and interpolation to accurately determine the zero crossing of that cycle, which determines the reference timestamp. A pulse-width discriminator demodulates the data pulses, which are then encoded as the BCD digits of the timecode. The timecode and reference timestamp are updated once each second with IRIG-B (ten seconds with IRIG-E) and local clock offset samples saved for later processing. At poll intervals of 64 s, the saved samples are processed by a median filter and used to update the system clock.

    +

    Monitor Data

    +The timecode format used for debugging and data recording includes data helpful in diagnosing problems with the IRIG signal and codec connections. The driver produces one line for each timecode in the following format: +

    00 00 98 23 19:26:52 2782 143 0.694 10 0.3 66.5 3094572411.00027

    +

    If clockstats is enabled, the most recent line is written to the clockstats file every 64 s. If verbose recording is enabled (fudge flag 4) each line is written as generated.

    +

    The first field containes the error flags in hex, where the hex bits are interpreted as below. This is followed by the year of century, day of year and time of day. Note that the time of day is for the previous minute, not the current time. The status indicator and year are not produced by some IRIG devices and appear as zeros. Following these fields are the carrier amplitude (0-3000), codec gain (0-255), modulation index (0-1), time constant (4-10), carrier phase error (0±0.5) and carrier frequency error (PPM). The last field is the on-time timestamp in NTP format.

    +

    The error flags are defined as follows in hex:

    +
    +
    x01
    +
    Low signal. The carrier amplitude is less than 100 units. This is usually the result of no signal or wrong input port.
    +
    x02
    +
    Frequency error. The codec frequency error is greater than 250 PPM. This may be due to wrong signal format or (rarely) defective codec.
    +
    x04
    +
    Modulation error. The IRIG modulation index is less than 0.5. This is usually the result of an overdriven codec, wrong signal format or wrong input port.
    +
    x08
    +
    Frame synch error. The decoder frame does not match the IRIG frame. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal. It may also be the result of an IRIG signature check which indicates a failure of the IRIG signal synchronization source.
    +
    x10
    +
    Data bit error. The data bit length is out of tolerance. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal.
    +
    x20
    +
    Seconds numbering discrepancy. The decoder second does not match the IRIG second. This is usually the result of an overdriven codec, wrong signal format or noisy IRIG signal.
    +
    x40
    +
    Codec error (overrun). The machine is not fast enough to keep up with the codec.
    +
    x80
    +
    Device status error (Spectracom).
    +
    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default IRIG.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    Specifies the microphone port if set to zero or the line-in port if set to one. It does not seem useful to specify the compact disc player port.
    +
    flag3 0 | 1
    +
    Enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started.
    +
    flag4 0 | 1
    +
    Enable verbose clockstats recording if set.
    +
    +
    + + + diff --git a/contrib/ntp/html/drivers/driver7.html b/contrib/ntp/html/drivers/driver7.html index 8e050e721..90baf61a3 100644 --- a/contrib/ntp/html/drivers/driver7.html +++ b/contrib/ntp/html/drivers/driver7.html @@ -1,88 +1,68 @@ - - - - - - Radio CHU Audio Demodulator/Decoder - - - - -

    Radio CHU Audio Demodulator/Decoder

    -
    -

    Synopsis

    - Address: 127.127.7.u
    - Reference ID: CHU
    - Driver ID: CHU
    - Modem Port: /dev/chuu; 300 baud, 8-bits, no parity
    - Autotune Port: /dev/icom; 1200/9600 baud, 8-bits, no parity
    - Audio Device: /dev/chu_audio and /dev/audioctl -

    Description

    -

    This driver synchronizes the computer time using data encoded in radio transmissions from Canadian time/frequency station CHU in Ottawa, Ontario. It replaces an earlier one, built by Dennis Ferguson in 1988, which required a special line discipline to preprocessed the signal. The new driver includes more powerful algorithms implemented directly in the driver and requires no preprocessing.

    -

    CHU transmissions are made continuously on 3330 kHz, 7335 kHz and 14670 kHz in upper sideband, compatible AM mode. An ordinary shortwave receiver can be tuned manually to one of these frequencies or, in the case of ICOM receivers, the receiver can be tuned automatically as propagation conditions change throughout the day and night. The performance of this driver when tracking the station is ordinarily better than 1 ms in time with frequency drift less than 0.5 PPM when not tracking the station.

    -

    While there are currently no known commercial CHU receivers, a simple but effective receiver/demodulator can be constructed from an ordinary shortwave receiver and Bell 103 compatible, 300-b/s modem or modem chip, as described on the Pulse-per-second (PPS) Signal Interfacing page. The driver can use the modem to receive the radio signal and demodulate the data or, if available, the driver can use the audio codec of the Sun workstation or another with compatible audio interface. In the latter case, the driver implements the modem using DSP routines, so the radio can be connected directly to either the microphone or line input port.

    -

    This driver incorporates several features in common with other audio drivers such as described in the Radio WWV/H Audio Demodulator/Decoder and the IRIG Audio Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    -

    Ordinarily, the driver poll interval is set to 14 (about 4.5 h), although this can be changed with configuration commands. As long as the clock is set or verified at least once during this interval, the NTP algorithms will consider the source reachable and selectable to discipline the system clock. However, if this does not happen for eight poll intervals, the algorithms will consider the source unreachable and some other source will be chosen (if available) to discipline the system clock.

    -

    The decoding algorithms process the data using maximum-likelihood techniques which exploit the considerable degree of redundancy available in each broadcast message or burst. As described below, every character is sent twice and, in the case of format A bursts, the burst is sent eight times every minute. In the case of format B bursts, which are sent once each minute, the burst is considered correct only if every character matches its repetition in the burst. In the case of format A messages, a majority decoder requires at least six repetitions for each digit in the timecode and more than half of the repetitions decode to the same digit. Every character in every burst provides an independent timestamp upon arrival with a potential total of over 60 timestamps for each minute.

    -

    A timecode in the format described below is assembled when all bursts have been received in the minute. The timecode is considered valid and the clock set when at least one valid format B burst has been decoded and the above requirements are met. The yyyy year field in the timecode indicates whether a valid format B burst has been received. Upon startup, this field is initialized at zero; when a valid format B burst is received, it is set to the current Gregorian year. The q quality character field in the timecode indicates whether a valid timecode has been determined. If any of the high order three bits of this character are set, the timecode is invalid.

    -

    Once the clock has been set for the first time, it will appear reachable and selectable to discipline the system clock, even if the broadcast signal is lost. Since the signals are almost always available during some period of the day and the NTP clock discipline algorithms are designed to work well even in this case, it is unlikely that the system clock could drift more than a few tens of milliseconds during periods of signal loss. To protect against this most unlikely situation, if after four days with no signals, the clock is considered unset and resumes the synchronization procedure from the beginning.

    -

    The last three fields in the timecode are useful in assessing the quality of the radio channel during the most recent minute bursts were received. The bcnt field shows the number of format A bursts in the range 1-8. The dist field shows the majority decoder distance, or the minimum number of sample repetitions for each digit of the timecode in the range 0-16. The tsmp field shows the number of timestamps determined in the range 0-60. For a valid timecode, bcnt must be at least 3, dist must be greater than bcnt and tsmp must be at least 20.

    -

    Program Operation

    -

    The program consists of four major parts: the DSP modem, maximum likelihood UART, burst assembler and majority decoder. The DSP modem demodulates Bell 103 modem answer-frequency signals; that is, frequency-shift keyed (FSK) tones of 2225 Hz (mark) and 2025 Hz (space). This is done using a 4th-order IIR filter and limiter/discriminator with 500-Hz bandpass centered on 2125 Hz and followed by a FIR raised-cosine lowpass filter optimized for the 300-b/s data rate. Alternately, the driver can be compiled to delete the modem and input 300 b/s data directly from an external modem via a serial port.

    -

    The maximum likelihood UART is implemented using a set of eight 11-stage shift registers, one for each of eight phases of the 300-b/s bit clock. At each phase a new baseband signal value from the DSP modem is shifted into the corresponding register and the maximum and minimum over all 11 samples computed. This establishes a slice level midway between the maximum and minimum over all stages. For each stage, a signal level above this level is a mark (1) and below is a space (0). A quality metric is calculated for each register with respect to the slice level and the a-priori signal consisting of a mark bit (previous stop bit), space (start) bit, eight arbitrary information bits and the first of the two mark (stop) bits.

    -

    The shift registers are processed in round-robin order as each modem value arrives until one of them shows a valid framing pattern consisting of a mark bit, space bit, eight arbitrary data bits and a mark bit. When found, the data bits from the register with the best metric is chosen as the maximum likelihood character and the UART begins to process the next character.

    -

    The burst assembler processes characters either from the maximum likelihood UART or directly from the serial port as configured. A burst begins when a character is received and is processed after a timeout interval when no characters are received. If the interval between characters is greater than two characters, but less than the timeout interval, the burst is rejected as a runt and a new burst begun. As each character is received, a timestamp is captured and saved for later processing.

    -

    A valid burst consists of ten characters in two replicated five-character blocks. A format B block contains the year and other information in ten hexadecimal digits. A format A block contains the timecode in ten decimal digits, the first of which is a framing code (6). The burst assembler must deal with cases where the first character of a format A burst is lost or is noise. This is done using the framing code to correct the phase, either one character early or one character late.

    -

    The burst distance is incremented by one for each bit in the first block that matches the corresponding bit in the second block and decremented by one otherwise. In a format B burst the second block is bit-inverted relative to the first, so a perfect burst of five 8-bit characters has distance -40. In a format A block the two blocks are identical, so a perfect burst has distance +40. Format B bursts must be perfect to be acceptable; however, format A bursts, which are further processed by the majority decoder, are acceptable if the distance is at least 28.

    -

    Each minute of transmission includes eight format A bursts containing two timecodes for each second from 31 through 39. The majority decoder uses a decoding matrix of ten rows, one for each digit position in the timecode, and 16 columns, one for each 4-bit code combination that might be decoded at that position. In order to use the character timestamps, it is necessary to reliably determine the second number of each burst. In a valid burst, the last digit of the two timecodes in the block must match and the value must be in the range 2-9 and greater than in the previous burst.

    -

    As each hex digit of a valid burst is processed, the value at the row corresponding to the digit position in the timecode and column corresponding to the code found at that position is incremented. At the end of each minute of transmission, each row of the decoding matrix encodes the number of occurrences of each code found at the corresponding position of the timecode. However, the first digit (framing code) is always 6, the ninth (second tens) is always 3 and the last (second units) changes for each burst, so are not used.

    -

    The maximum over all occurrences at each timecode digit position is the distance for that position and the corresponding code is the maximum likelihood candidate. If the distance is zero, the decoder assumes a miss; if the distance is not more than half the total number of occurrences, the decoder assumes a soft error; if two different codes with the same distance are found, the decoder assumes a hard error. In all these cases the decoder encodes a non-decimal character which will later cause a format error when the timecode is reformatted. The decoding distance is defined as the minimum distance over the first nine digits; the tenth digit varies over the seconds and is uncounted.

    -

    The result of the majority decoder is a nine-digit timecode representing the maximum likelihood candidate for the transmitted timecode in that minute. Note that the second and fraction within the minute are always zero and that the actual reference point to calculate timestamp offsets is backdated to the first second of the minute. At this point the timecode block is reformatted and the year, days, hours and minutes extracted along with other information from the format B burst, including DST state, DUT1 correction and leap warning. The reformatting operation checks the timecode for invalid code combinations that might have been left by the majority decoder and rejects the entire timecode if found.

    -

    If the timecode is valid, it is passed to the reference clock interface along with the backdated timestamp offsets accumulated over the minute. A perfect set of nine bursts could generate as many as 90 timestamps, but the maximum the interface can handle is 60. These are processed by the interface using a median filter and trimmed-mean average, so the resulting system clock correction is usually much better than would otherwise be the case with radio noise, UART jitter and occasional burst errors.

    -

    Autotune

    -

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a standard serial port using a level converter such as the CT-17.

    -

    Each ICOM radio is assigned a unique 8-bit ID select code, usually expressed in hex format. To activate the CI-V interface, the mode keyword of the server configuration command specifies a nonzero select code in decimal format. A table of ID select codes for the known ICOM radios is given below. Since all ICOM select codes are less than 128, the high order bit of the code is used by the driver to specify the baud rate. If this bit is not set, the rate is 9600 bps for the newer radios; if set, the rate is 1200 bps for the older radios. A missing mode keyword or a zero argument leaves the interface disabled.

    -

    If specified, the driver will attempt to open the device /dev/icom and, if successful will tune the radio to 3.330 MHz. If after five minutes at this frequency not more than two format A bursts have been received for any minute, the driver will tune to 7.335 MHz, then to 14.670 MHz, then return to 3.330 MHz and continue in this cycle. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus or radio is inoperative, the driver quietly gives up with no harm done.

    -

    Radio Broadcast Format

    -

    The CHU time broadcast includes an audio signal compatible with the Bell 103 modem standard (mark = 2225 Hz, space = 2025 Hz). It consist of nine, ten-character bursts transmitted at 300 b/s and beginning each second from second 31 to second 39 of the minute. Each character consists of eight data bits plus one start bit and two stop bits to encode two hex digits. The burst data consist of five characters (ten hex digits) followed by a repeat of these characters. In format A, the characters are repeated in the same polarity; in format B, the characters are repeated in the opposite polarity.

    -

    Format A bursts are sent at seconds 32 through 39 of the minute in hex digits

    -

    6dddhhmmss6dddhhmmss

    -

    The first ten digits encode a frame marker (6) followed by the day (ddd), hour (hh), minute (mm) and second (ss). Since format A bursts are sent during the third decade of seconds the tens digit of ss is always 3. The driver uses this to determine correct burst synchronization. These digits are then repeated with the same polarity.

    -

    Format B bursts are sent at second 31 of the minute in hex digits

    -

    xdyyyyttaaxdyyyyttaa

    -

    The first ten digits encode a code (x described below) followed by the DUT1 (d in deciseconds), Gregorian year (yyyy), difference TAI - UTC (tt) and daylight time indicator (aa) peculiar to Canada. These digits are then repeated with inverted polarity.

    -

    The x is coded

    -
    -
    1 -
    Sign of DUT (0 = +)/dd> -
    2 -
    Leap second warning. One second will be added. -
    4 -
    Leap second warning. One second will be subtracted. This is not likely to happen in our universe. -
    8 -
    Even parity bit for this nibble. -
    -

    By design, the last stop bit of the last character in the burst coincides with 0.5 second. Since characters have 11 bits and are transmitted at 300 b/s, the last stop bit of the first character coincides with 0.5 - 10 * 11/300 = 0.133 second. Depending on the UART, character interrupts can vary somewhere between the beginning of bit 9 and end of bit 11. These eccentricities can be corrected along with the radio propagation delay using the fudge time1 variable.

    -

    Debugging Aids

    -

    The most convenient way to track the program status is using the ntpq program and the clockvar command. This displays the last determined timecode and related status and error counters, even when the program is not discipline the system clock. If the debugging trace feature (-d on the ntpd command line)is enabled, the program produces detailed status messages as it operates. If the fudge flag 4 is set, these messages are written to the clockstats file. All messages produced by this driver have the prefix chu for convenient filtering with the Unix grep command.

    -

    With debugging enabled the driver produces messages in the following formats:

    -

    A format chuA message is produced for each format A burst received in seconds 32 through 39 of the minute:

    -

    chuA n b s code

    -

    where n is the number of characters in the burst (0-11), b the burst distance (0-40), s the synchronization distance (0-40) and code the burst characters as received. Note that the hex digits in each character are reversed and the last ten digits inverted, so the burst

    -

    11 40 1091891300ef6e76ecff

    -

    is interpreted as containing 11 characters with burst distance 40. The nibble-swapped timecode shows DUT1 +0.1 second, year 1998 and TAI -UTC 31 seconds.

    -

    A format chuB message is produced for each format B burst received in second 31 of the minute:

    -

    chuB n b f s m code

    -

    where n is the number of characters in the burst (0-11), b the burst distance (0-40), f the field alignment (-1, 0, 1), sthe synchronization distance (0-16), mthe burst number (2-9) and code the burst characters as received. Note that the hex digits in each character are reversed, so the burst

    -

    10 38 0 16 9 06851292930685129293

    -

    is interpreted as containing 11 characters with burst distance 38, field alignment 0, synchronization distance 16 and burst number 9. The nibble-swapped timecode shows day 58, hour 21, minute 29 and second 39.

    -

    If the CI-V interface for ICOM radios is active, a debug level greater than 1 will produce a trace of the CI-V command and response messages. Interpretation of these messages requires knowledge of the CI-V protocol, which is beyond the scope of this document.

    -

    Monitor Data

    - When enabled by the filegen facility, every received timecode is written to the clockstats file in the following format: -
    -        sq yy ddd hh:mm:ss.fff ld dut lset agc rfrq bcnt dist tsmp
    +
    +
    +
    +Radio CHU Audio Demodulator/Decoder
    +
    +
    +
    +

    Radio CHU Audio Demodulator/Decoder

    +

    Author: David L. Mills (mills@udel.edu)
    +Last update: + 17-Jul-2014 02:17 + UTC

    +
    +

    Synopsis

    +Address: 127.127.7.u
    +Reference ID: CHU
    +Driver ID: CHU
    +Modem Port: /dev/chuu; 300 baud, 8-bits, no parity
    +Autotune Port: /dev/icom; 1200/9600 baud, 8-bits, no parity
    +Audio Device: /dev/audio and /dev/audioctl +

    Description

    +

    This driver synchronizes the computer time using shortwave radio transmissions + from Canadian time/frequency station CHU in + Ottawa, Ontario. CHU transmissions are made continuously on 3.330, + 7.850 and 14.670 MHz in upper sideband, compatible AM mode. An ordinary + shortwave receiver can be tuned manually to one of these frequencies or, in + the case of ICOM receivers, the receiver can be tuned automatically as propagation + conditions change throughout the day and season.

    +

    The driver can be compiled to use either an audio codec or soundcard, or a Bell 103-compatible, 300-b/s modem or modem chip, as described on the Pulse-per-second (PPS) Signal Interfacing page. If compiled for a modem, the driver uses it to receive the radio signal and demodulate the data. If compiled for the audio codec, it requires a sampling rate of 8 kHz and μ-law companding to demodulate the data. This is the same standard as used by the telephone industry and is supported by most hardware and operating systems, including Solaris, FreeBSD and Linux, among others. The radio is connected via an optional attenuator and cable to either the microphone or line-in port of a workstation or PC. In this implementation, only one audio driver and codec can be supported on a single machine.

    +

    In general and without calibration, the driver is accurate within 1 ms relative to the broadcast time when tracking a station. However, variations up to 0.3 ms can be expected due to diurnal variations in ionospheric layer height and ray geometry. In Newark DE, 625 km from the transmitter, the predicted one-hop propagation delay varies from 2.8 ms in sunlight to 2.6 ms in moonlight. When not tracking the station the accuracy depends on the computer clock oscillator stability, ordinarily better than 0.5 PPM.

    +

    After calibration relative to the PPS signal from a GPS receiver, the mean offset with a 2.4-GHz P4 running FreeBSD 6.1 is generally within 0.2 ms short-term with 0.4 ms jitter. The long-term mean offset varies up to 0.3 ms due to propagation path geometry variations. The processor load due to the driver is 0.4 percent on the P4.

    +

    The driver performs a number of error checks to protect against overdriven or underdriven input signal levels, incorrect signal format or improper hardware configuration. The specific checks are detailed later in this page. Note that additional checks are done elsewhere in the reference clock interface routines.

    +

    This driver incorporates several features in common with other audio drivers such as described in the Radio WWV/H Audio Demodulator/Decoder and the IRIG Audio Decoder pages. They include automatic gain control (AGC), selectable audio codec port and signal monitoring capabilities. For a discussion of these common features, as well as a guide to hookup, debugging and monitoring, see the Reference Clock Audio Drivers page.

    +

    Technical Overview

    +

    The driver processes 8-kHz μ-law companded codec samples using maximum-likelihood techniques which exploit the considerable degree of redundancy available in each broadcast message or burst. As described below, every character is sent twice and, in the case of format A bursts, the burst is sent eight times every minute. The single format B burst is considered correct only if every character matches its repetition in the burst. For the eight format A bursts, a majority decoder requires more than half of the 16 repetitions for each digit decode to the same value. Every character in every burst provides an independent timestamp upon arrival with a potential total of 60 timestamps for each minute.

    +

    The CHU timecode format is described on the CHU website. A timecode is assembled when all bursts have been received in each minute. The timecode is considered valid and the clock set when at least one valid format B burst has been decoded and the majority decoder declares success. Once the driver has synchronized for the first time, it will appear reachable and selectable to discipline the system clock. It is normal on occasion to miss a minute or two due to signal fades or noise. If eight successive minutes are missed, the driver is considered unreachable and the system clock will free-wheel at the latest determined frequency offset. Since the signals are almost always available during some period of the day and the NTP clock discipline algorithms are designed to work well even with long intervals between updates, it is unlikely that the system clock will drift more than a few milliseconds during periods of signal loss.

    +

    Baseband Signal Processing

    +

    The program consists of four major parts: the DSP modem, maximum-likelihood UART, burst assembler and majority decoder. The DSP modem demodulates Bell 103 modem answer-frequency signals; that is, frequency-shift keyed (FSK) tones of 2225 Hz (mark) and 2025 Hz (space). It consists of a 500-Hz bandpass filter centered on 2125 Hz followed by a limiter/discriminator and raised-cosine lowpass filter optimized for the 300-b/s data rate.

    +

    The maximum likelihood UART is implemented using a set of eight 11-stage shift registers, one for each of eight phases of the 300-b/s bit clock. At each phase a new baseband signal from the DSP modem is shifted into the corresponding register and the maximum and minimum over all 11 samples computed. This establishes a span (difference) and slice level (average) over all 11 stages. For each stage, a signal level above the slice is a mark (1) and below that is a space (0). A quality metric is calculated for each register with respect to the slice level and the a-priori signal consisting of a start bit (space), eight arbitrary information bits and two stop bits (mark).

    +

    The shift registers are processed in round-robin order as the phases of each bit arrive. At the end of each bit all eight phases are searched for valid framing bits, sufficient span and best metric. The best candidate found in this way represents the maximum-likelihood character. The process then continues for all ten characters in the burst.

    +

    The burst assembler processes characters either from the maximum-likelihood UART or directly from the serial port as configured. A burst begins when a character is received and is processed after a timeout interval when no characters are received. If the interval between characters is greater than two characters, but less than the timeout interval, the burst is rejected as a runt and a new burst begun. As each character is received, a timestamp is captured and saved for later processing.

    +

    A valid burst consists of ten characters in two replicated five-character blocks, each block representing ten 4-bit BCD digits. The format B blocks sent in second 31 contain the year and other information in ten digits. The eight format A blocks sent in seconds 32-39 contain the timecode in ten digits, the first of which is a framing code (6). The burst assembler must deal with cases where the first character of a format A burst is lost or is noise. This is done using the framing codes to correct the discrepancy, either one character early or one character late.

    +

    The burst distance is incremented by one for each bit in the first block that matches the corresponding bit in the second block and decremented by one otherwise. In a format B burst the second block is bit-inverted relative to the first, so a perfect burst of five 8-bit characters has distance -40. In a format A burst the two blocks are identical, so a perfect burst has distance +40. Format B bursts must be perfect to be acceptable; however, format A bursts, which are further processed by the majority decoder, are acceptable if the distance is at least 28.

    +

    Majority Decoder

    +

    Each minute of transmission includes eight format A bursts containing two timecodes for each second from 32 through 39. The majority decoder uses a decoding matrix of ten rows, one for each digit position in the timecode, and 16 columns, one for each 4-bit code combination that might be decoded at that position. In order to use the character timestamps, it is necessary to reliably determine the second number of each burst. In a valid burst, the last digit of the two timecodes in the burst must match and the value must be in the range 2-9 and greater than in the previous burst.

    +

    As each digit of a valid burst is processed, the value at the row corresponding to the digit position in the timecode and column corresponding to the code found at that position is incremented. At the end of the minute, each row of the decoding matrix encodes the number of occurrences of each code found at the corresponding position.

    +

    The maximum over all occurrences at each digit position is the distance for that position and the corresponding code is the maximum-likelihood digit. If the distance is not more than half the total number of occurrences, the decoder assumes a soft error and discards all information collected during the minute. The decoding distance is defined as the sum of the distances over the first nine digits; the tenth digit varies over the seconds and is uncounted.

    +

    The result of the majority decoder is a nine-digit timecode representing the maximum-likelihood candidate for the transmitted timecode in that minute. Note that the second and fraction within the minute are always zero and that the actual reference point to calculate timestamp offsets is backdated to the first second of the minute. At this point the timecode block is reformatted and the year, days, hours and minutes extracted along with other information from the format B burst, including DST state, DUT1 correction and leap warning. The reformatting operation checks the timecode for invalid code combinations that might have been left by the majority decoder and rejects the entire timecode if found.

    +

    If the timecode is valid, it is passed to the reference clock interface along with the backdated timestamps accumulated over the minute. A perfect set of eight bursts could generate as many as 80 timestamps, but the maximum the interface can handle is 60. These are processed using a median filter and trimmed-mean average, so the resulting system clock correction is usually much better than would otherwise be the case with radio noise, UART jitter and occasional burst errors.

    +

    Autotune

    +

    The driver includes provisions to automatically tune the radio in response to changing radio propagation conditions throughout the day and night. The radio interface is compatible with the ICOM CI-V standard, which is a bidirectional serial bus operating at TTL levels. The bus can be connected to a standard serial port using a level converter such as the CT-17. Further details are on the Reference Clock Audio Drivers page.

    +

    If specified, the driver will attempt to open the device /dev/icom and, if successful will tune the radio to 3.331 MHz. The 1-kHz offset is useful with a narrowband SSB filter where the passband includes the carrier and modem signals. However, the driver is liberal in what it assumes of the configuration. If the /dev/icom link is not present or the open fails or the CI-V bus is inoperative, the driver continues in single-frequency mode.

    +

    As long as no bursts are received, the driver cycles over the three frequencies in turn, one minute for each station. When bursts are received from one or more stations, the driver operates in a five-minute cycle. During the first four minutes it tunes to the station with the highest metric. During the last minute it alternates between the other two stations in turn in order to measure the metric.

    +

    Debugging Aids

    +

    The most convenient way to track the program status is using the ntpq program and the clockvar command. This displays the last determined timecode and related status and error counters, even when the program is not discipline the system clock. If the debugging trace feature (-d on the ntpd command line) is enabled, the program produces detailed status messages as it operates. If the fudge flag 4 is set, these messages are written to the clockstats file. All messages produced by this driver have the prefix chu for convenient filtering with the Unix grep command.

    +

    With debugging enabled the driver produces messages in the following formats: A single message beginning with chuB is produced for each format B burst received in second 31, while eight messages beginning with chuA are produced for each format A burst received in seconds 32 through 39 of the minute. The first four fields are

    +

    stat sig n b

    +

    where stat is the status code, sig the character span, n the number of characters in the burst (9-11) and b the burst distance (0-40). Good bursts will have spans of a 800 or more and the other numbers near the top of the range specified. See the source for the interpretation of the remaining data in the burst. Note that each character of the burst is encoded as two digits in nibble-swapped order.

    +

    If the CI-V interface for ICOM radios is active, a debug level greater than 1 will produce a trace of the CI-V command and response messages. Interpretation of these messages requires knowledge of the CI-V protocol, which is beyond the scope of this document.

    +

    Monitor Data

    +When enabled by the filegen facility, every received timecode is written to the clockstats file in the following format: +
    +        sq yyyy ddd hh:mm:ss lw dst du lset agc rfrq bcnt dist tsmp
     
             s       sync indicator
             q       quality character
    @@ -91,144 +71,74 @@
             hh      hour of day
             mm      minute of hour
             ss      second of minute
    -        fff     millisecond of second
    -        l       leap second warning
    -        d       DST state
    +        lw      leap second warning
    +        dst     DST state
             dut     DUT sign and magnitude in deciseconds
             lset    minutes since last set
             agc     audio gain (0-255)
    -        rfrq    radio frequency
    -        bcnt    burst count
    -        dist    decoding distance
    +        ident   CHU identifier code
    +        dist    decoder distance
             tsmp    timestamps captured
     
    - The fields beginning with year and extending through dut are decoded from the received data and are in fixed-length format. The agc and lset fields, as well as the following driver-dependent fields, are in variable-length format. -
    -
    s -
    The sync indicator is initially ? before the clock is set, but turns to space when the clock is correctly set. -
    q -
    The quality character is a four-bit hexadecimal code showing which alarms have been raised during the most recent minute. Each bit is associated with a specific alarm condition according to the following: -
    -
    8 -
    Decoder alarm. A majority of repetitions for at least one digit of the timecode fails to agree. -
    4 -
    Timestamp alarm. Fewer than 20 timestamps have been determined. -
    2 -
    Format alarm. The majority timecode contains invalid bit combinations. -
    1 -
    Frame alarm. A framing or format error occurred on at least one burst during the minute. -
    -

    It is important to note that one or more of the above alarms does not necessarily indicate a clock error, but only that the decoder has detected a condition that may in future result in an error.

    -
    yyyy ddd hh:mm:ss.fff -
    The timecode format itself is self explanatory. Note that the Gregorian year is decoded directly from the transmitted timecode. -
    l -
    The leap second warning is normally space, but changes to L if a leap second is to occur at the end of the month of June or December. -
    d -
    The DST code for Canada encodes the state for all provinces. -
    dut -
    The DUT sign and magnitude shows the current UT1 offset relative to the displayed UTC time, in deciseconds. -
    lset -
    Before the clock is set, the interval since last set is the number of minutes since the program was started; after the clock is set, this is number of minutes since the time was last verified relative to the broadcast signal. -
    agc -
    The audio gain shows the current codec gain setting in the range 0 to 255. Ordinarily, the receiver audio gain control or IRIG level control should be set for a value midway in this range. -
    rfrq -
    The current radio frequency, if the CI-V interface is active, or 'X' if not. -
    bcnt -
    The number of format A bursts received during the most recent minute bursts were received. -
    dist -
    The minimum decoding distance determined during the most recent minute bursts were received. -
    tsmp -
    The number of timestamps determined during the most recent minute bursts were received. -
    -

    Modes

    -

    The mode keyword of the server configuration command specifies the ICOM ID select code. A missing or zero argument disables the CI-V interface. Following are the ID select codes for the known radios.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    RadioHexDecimalRadioHexDecimal
    IC7250x2840IC7810x2638
    IC7260x3048R70000x088
    IC7350x044R710x1A26
    IC7510x1c28R71000x3452
    IC7610x1e30R720x3250
    IC7650x2c44R85000x4a74
    IC7750x4668R90000x2a42
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the propagation delay for CHU (45:18N 75:45N), in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default CHU. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    When the audio driver is compiled, this flag selects the audio input port, where 0 is the mike port (default) and 1 is the line-in port. It does not seem useful to select the compact disc player port. -
    flag3 0 | 1 -
    When the audio driver is compiled, this flag enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started. -
    flag4 0 | 1 -
    Enable verbose clockstats recording if set. -
    -
    - - - - \ No newline at end of file +The fields beginning with year and extending through dut are decoded from the received data and are in fixed-length format. The agc and lset fields, as well as the following driver-dependent fields, are in variable-length format. +
    +
    s
    +
    The sync indicator is initially ? before the clock is set, but turns to space when the clock has been correctly set.
    +
    q
    +
    The quality character is a four-bit hexadecimal code showing which alarms have been raised during the most recent minute. Each bit is associated with a specific alarm condition according to the following: +
    +
    8
    +
    Timestamp alarm. Fewer than 20 timestamps have been determined.
    +
    4
    +
    Decoder alarm. A majority of repetitions for at least one digit of the timecode fails to agree.
    +
    2
    +
    Format alarm. One or more bursts contained invalid data or was improperly formatted.
    +
    1
    +
    Frame alarm. One or more bursts was improperly framed or contained too many repetition errors.
    +
    + The timestamp and decoder alarms are fatal; the data accumulated during the minute are not used to set the clock. The format and fram alarm are nonfatal; only the data in the burst are discarded.
    +
    yyyy ddd hh:mm:ss
    +
    The timecode format itself is self explanatory. Note that the Gregorian year is decoded directly from the transmitted timecode.
    +
    lw
    +
    The leap second warning is normally space, but changes to L if a leap second is to occur at the end of the month.
    +
    dst
    +
    The DST code for Canada encodes the state for all provinces. It is encoded as two hex characters.
    +
    dut
    +
    The DUT sign and magnitude shows the current UT1 offset relative to the displayed UTC time, in deciseconds. It is encoded as one digit preceeded by sign.
    +
    lset
    +
    Before the clock is set, this is the number of minutes since the program was started; after the clock is set, this is the number of minutes since the time was last verified relative to the broadcast signal.
    +
    agc
    +
    The audio gain shows the current codec gain setting in the range 0 to 255. Ordinarily, the receiver audio gain control should be set for a value midway in this range.
    +
    ident
    +
    The CHU identifier CHU followed by the current radio frequency + code, if the CI-V interface is active, or CHU if not. The radio + frequncy is encoded as 0 for 3.330 MHz, 1 for 7.850 MHz and 2 + for 14.670 MHz.
    +
    dist
    +
    The decoding distance determined during the most recent minute bursts were received. The values range from 0 to 160, with the higher values indicating better signals. The decoding algorithms require the distance at least 50; otherwise all data in the minute are discarded.
    +
    tsmp
    +
    The number of timestamps determined during the most recent minute bursts were received. The values range from 0 to 60, with the higher values indicating better signals. The decoding algoriths require at least 20 timestamps in the minute; otherwise all data in the minute are discarded.
    +
    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the propagation delay for CHU (45:18N 75:45N), in seconds and fraction, with default 0.0.
    +
    time2 time
    +
    Not used by this driver.
    +
    stratum number
    +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0.
    +
    refid string
    +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default CHU.
    +
    flag1 0 | 1
    +
    Not used by this driver.
    +
    flag2 0 | 1
    +
    When the audio driver is compiled, this flag selects the audio input port, where 0 is the mike port (default) and 1 is the line-in port. It does not seem useful to select the compact disc player port.
    +
    flag3 0 | 1
    +
    When the audio driver is compiled, this flag enables audio monitoring of the input signal. For this purpose, the speaker volume must be set before the driver is started.
    +
    flag4 0 | 1
    +
    Enable verbose clockstats recording if set.
    +
    +
    + + + diff --git a/contrib/ntp/html/drivers/driver8.html b/contrib/ntp/html/drivers/driver8.html index fc12f3307..ab21f0f1f 100644 --- a/contrib/ntp/html/drivers/driver8.html +++ b/contrib/ntp/html/drivers/driver8.html @@ -2,278 +2,277 @@ - - - Generic Reference Driver - - - - -

    Generic Reference Driver

    -
    -

    Synopsis

    - Address: 127.127.8.u
    - Reference ID: PARSE
    - Driver ID: GENERIC
    - Serial Port: /dev/refclock-u; TTY mode according to clock type
    - PPS device: /dev/refclockpps-u; alternate PPS device (if not available via the serial port) -

    Description

    - The PARSE driver supports 20 different clock types/configurations. PARSE is actually a multi-clock driver.
    -
    -

    The actual receiver status is mapped into various synchronization states generally used by receivers. The driver is configured to interpret the time codes of Meinberg DCF77 AM receivers, DCF77 FM receivers, Meinberg GPS16x/17x receivers, Trimble SV6 GPS, ELV DCF7000, Schmid, Wharton 400A and low cost receivers (see list below).

    -

    The reference clock support in NTP contains the necessary configuration tables for those receivers. In addition to supporting several different clock types and up to 4 devices, the processing of a PPS signal is also provided as a configuration option. The PPS configuration option uses the receiver-generated time stamps for feeding the PPS loopfilter control for much finer clock synchronization.

    -

    CAUTION: The PPS configuration option is different from the hardware PPS signal, which is also supported (see below), as it controls the way ntpd is synchronized to the reference clock, while the hardware PPS signal controls the way time offsets are determined.

    -

    The use of the PPS option requires receivers with an accuracy of better than 1ms.

    -

    Timecode variables listed by ntpq (8)

    -

    The ntpq program can read and display several clock variables. These hold the following information:

    -
    -
    refclock_format
    -
    A qualification of the decoded time code format.
    -
    refclock_states
    -
    The overall running time and the accumulated times for the clock event states.
    -
    refclock_status
    -
    Lists the currently active receiver flags. Additional feature flags for the receiver are optionally listed in parentheses.
    -
    refclock_time
    -
    The local time with the offset to UTC (format HHMM).
    -
    timecode
    -
    The actual time code.
    -
    -

    If PPS information is present, additional variables are available:

    -
    -
    refclock_ppsskew
    -
    The difference between the RS-232-derived timestamp and the PPS timestamp.
    -
    refclock_ppstime
    -
    The PPS timestamp.
    -
    -

    Supported Devices

    -

    Currently, nineteen clock types (devices /dev/refclock-0 - /dev/refclock-3) are supported by the PARSE driver.
    - A note on the implementations:

    -
      -
    • These implementations were mainly done without actual access to the hardware, thus not all implementations provide full support. The development was done with the help of many kind souls who had the hardware and kindly lent me their time and patience during the development and debugging cycle. Thus for continued support and quality, direct access to the receivers is a big help. Nevertheless I am not prepared to buy these reference clocks - donations to (kardel <AT> ntp.org) are welcome as long as they work within Europe 8-). -

      Verified implementations are:

      -
        -
      • RAWDCF variants -

        These variants have been tested for correct decoding with my own homegrown receivers. Interfacing with specific commercial products may involve some fiddling with cables. In particular, commercial RAWDCF receivers have a seemingly unlimited number of ways to draw power from the RS-232 port and to encode the DCF77 datastream. You are mainly on your own here unless I have a sample of the receiver.

        -
      • Meinberg clocks -

        These implementations have been verified by the Meinberg people themselves and I have access to one of these clocks.

        -
      -
    -

    The pictures below have been taken from and are linked to the vendors' web pages.

    - -
      -
    • server 127.127.8.0-3 mode 0 -

      Meinberg PZF5xx receiver family (FM demodulation/TCXO / 50μs)
      -

      - -
    • server 127.127.8.0-3 mode 1 -

      Meinberg PZF5xx receiver family (FM demodulation/OCXO / 50μs)
      - Image PZF511
      -

      - -
    • server 127.127.8.0-3 mode 2 -

      Meinberg DCF C51 receiver and similar (AM demodulation / 4ms)
      - Image C51
      -

      -

      This mode expects the Meinberg standard time string format with 9600/7E2.

      -

      Note: mode 2 must also be used for Meinberg PCI cards under Linux, e.g. the GPS PCI card or the DCF77 PCI card. Please note the Meinberg Linux driver must be installed. That driver emulates a refclock device in order to allow ntpd to access those cards. For details, please refer to the README file that comes with the Meinberg driver package.
      -

      - -
    • server 127.127.8.0-3 mode 3 -

      ELV DCF7000 (sloppy AM demodulation / 50ms)
      -

      - -
    • server 127.127.8.0-3 mode 4 -

      Walter Schmid DCF receiver Kit (AM demodulation / 1ms)
      -

      - -
    • server 127.127.8.0-3 mode 5 -

      RAW DCF77 100/200ms pulses (Conrad DCF77 receiver module / 5ms)
      -

      - -
    • server 127.127.8.0-3 mode 6 -

      RAW DCF77 100/200ms pulses (TimeBrick DCF77 receiver module / 5ms)
      -

      - -
    • server 127.127.8.0-3 mode 7 -

      Meinberg GPS16x/GPS17x receivers (GPS / <<1μs)
      - Image GPS167
      -

      -

      This mode expects either the University of Erlangen time string format or the Meinberg standard time string format at 19200/8N1.

      -

      The University of Erlangen format is preferred. Newer Meinberg GPS receivers can be configured to transmit that format; for older devices, a special firmware version may be available.

      -

      In this mode some additional GPS receiver status information is also read. However, this requires a point-to-point connection. Mode 18 should be used if the device is accessed by a multidrop connection.

      -

      Note: mode 7 must not be used with Meinberg PCI cards; use mode 2 instead.
      -

      - -
    • server 127.127.8.0-3 mode 8 -

      IGEL clock
      - Image IGEL clock
      -

      - -
    • server 127.127.8.0-3 mode 9 -

      Trimble SVeeSix GPS receiver TAIP protocol (GPS / <<1μs)
      -

      - -
    • server 127.127.8.0-3 mode 10 -

      Trimble SVeeSix GPS receiver TSIP protocol (GPS / <<1μs) (no kernel support yet)
      - Image SVeeSix-CM3
      - Image Lassen-SK8
      -

      - -
    • server 127.127.8.0-3 mode 11 -

      Radiocode Clocks Ltd RCC 8000 Intelligent Off-Air Master Clock support
      -

      - -
    • server 127.127.8.0-3 mode 12 -

      HOPF Funkuhr 6021
      - Image DCF77 Interface Board
      -

      - -
    • server 127.127.8.0-3 mode 13 -

      Diem's Computime Radio Clock
      -

      - -
    • server 127.127.8.0-3 mode 14 -

      RAWDCF receiver (DTR=high/RTS=low)
      -

      - -
    • server 127.127.8.0-3 mode 15 -

      WHARTON 400A Series Clocks with a 404.2 Serial Interface
      -

      - -
    • server 127.127.8.0-3 mode 16 -

      RAWDCF receiver (DTR=low/RTS=high)
      -

      - -
    • server 127.127.8.0-3 mode 17 -

      VARITEXT Receiver (MSF)
      -

      - -
    • server 127.127.8.0-3 mode 18 -

      Meinberg GPS16x/GPS17x receivers (GPS / <<1μs)
      -

      -

      This mode works without additional data communication (version, GPS status etc.) and thus should be used with multidrop, heterogeneous multiclient operation.

      -

      Note: mode 18 must not be used with Meinberg PCI cards, use mode 2 instead.
      -

      -
    • server 127.127.8.0-3 mode 19 -

      Gude Analog- und Digitalsystem GmbH 'Expert mouseCLOCK USB v2.0'
      -

      - -
    -

    Actual data formats and setup requirements of the various clocks can be found in NTP PARSE clock data formats.

    -

    Operation

    -

    The reference clock support software carefully monitors the state transitions of the receiver. All state changes and exceptional events (such as loss of time code transmission) are logged via the syslog facility. Every hour a summary of the accumulated times for the clock states is listed via syslog.

    -

    PPS support is only available when the receiver is completely synchronized. The receiver is believed to deliver correct time for an additional period of time after losing synchronization, unless a disruption in time code transmission is detected (possible power loss). The trust period is dependent on the receiver oscillator and thus is a function of clock type.

    -

    Raw DCF77 pulses can be fed via a level converter to the RXD pin of an RS-232 serial port (pin 3 of a 25-pin connector or pin 2 of a 9-pin connector). The telegrams are decoded and used for synchronization. DCF77 AM receivers can be bought for as little as $25. The accuracy is dependent on the receiver and is somewhere between 2ms (expensive) and 10ms (cheap). Synchronization ceases when reception of the DCF77 signal deteriorates, since no backup oscillator is available as usually found in other reference clock receivers. So it is important to have a good place for the DCF77 antenna. During transmitter shutdowns you are out of luck unless you have other NTP servers with alternate time sources available.

    -

    In addition to the PPS loopfilter control, a true PPS hardware signal can be utilized via the PPSAPI interface. PPS pulses are usually fed via a level converter to the DCD pin of an RS-232 serial port (pin 8 of a 25-pin connector or pin 1 of a 9-pin connector). To select PPS support, the mode parameter is the mode value as above plus 128. If 128 is not added to the mode value, PPS will be detected to be available but will not be used. -

    -

    Hardware PPS support
    -

    -

    For PPS to be used, add 128 to the mode parameter.

    -

    If the PPS signal is fed in from a device different from the device providing the serial communication (/dev/refclock-{0..3}), this device is configured as /dev/refclockpps-{0..3}. This allows the PPS information to be fed in e.g. via the parallel port (if supported by the underlying operation system) and the date/time telegrams to be handled via the serial port.

    -

    Monitor Data

    -

    Clock state statistics are written hourly to the syslog service. Online information can be found by examining the clock variables via the ntpq cv command.
    - Some devices have quite extensive additional information (GPS16x/GPS17x, Trimble). The driver reads out much of the internal GPS data - and makes it accessible via clock variables. To find out about additional variable names, query for the clock_var_list variable on - a specific clock association as shown below. -

    -

    First let ntpq display the table of associations:

    -
    -  ntpq> as
    -  ind assID status  conf reach auth condition  last_event cnt
    -  ===========================================================
    -    1 19556  9154   yes   yes  none falsetick   reachable  5
    -    2 19557  9435   yes   yes  none  candidat  clock expt  3
    -    3 19558  9714   yes   yes  none  pps.peer   reachable  1
    -		
    -

    Then switch to raw output. This may be required because of display limitations in ntpq/ntpd - so large lists need to be retrieved in several queries.

    -
    -  ntpq> raw
    -  Output set to raw
    -		
    -

    Use the cv command to read the list of clock variables of a selected association:

    -
    -  ntpq> cv 19557 clock_var_list
    -		
    -

    The long output of the command above looks similar to:

    -
    -  assID=19557 status=0x0000,
    -  clock_var_list="type,timecode,poll,noreply,badformat,baddata,fudgetime1,
    -  fudgetime2,stratum,refid,flags,device,clock_var_list,refclock_time,refclock_status,
    -  refclock_format,refclock_states,refclock_id,refclock_iomode,refclock_driver_version,
    -  meinberg_gps_status,gps_utc_correction,gps_message,meinberg_antenna_status,gps_tot_51,
    -  gps_tot_63,gps_t0a,gps_cfg[1],gps_health[1],gps_cfg[2],gps_health[2],gps_cfg[3],
    -  gps_health[3],gps_cfg[4],gps_health[4],gps_cfg[5]"
    -		
    -

    Then use the cv command again to list selected clock variables. The following command must be entered as a single line:

    -
    -  ntpq> cv 19557 refclock_status,refclock_format,refclock_states,refclock_id,
    -  refclock_iomode,refclock_driver_version,meinberg_gps_status,gps_utc_correction,
    -  gps_message,meinberg_antenna_status,gps_tot_51,gps_tot_63,gps_t0a,gps_cfg[1],
    -  gps_health[1],gps_cfg[2],gps_health[2],gps_cfg[3],gps_health[3],gps_cfg[4],
    -  gps_health[4],gps_cfg[5]
    -		
    -

    The output of the command above is wrapped around depending on the screen width and looks similar to:

    -
    -  status=0x0003,
    -  refclock_status="UTC DISPLAY; TIME CODE; PPS; POSITION; (LEAP INDICATION;
    -  PPS SIGNAL; POSITION)",
    -  refclock_format="Meinberg GPS Extended",
    -  refclock_states="*NOMINAL: 21:21:36 (99.99%); FAULT: 00:00:03 (0.00%);
    -  running time: 21:21:39",
    -  refclock_id="GPS", refclock_iomode="normal",
    -  refclock_driver_version="refclock_parse.c,v 4.77 2006/08/05 07:44:49
    -  kardel RELEASE_20060805_A",
    -  meinberg_gps_status="[0x0000] <OK>",
    -  gps_utc_correction="current correction 14 sec, last correction
    -  on c7619a00.00000000  Sun, Jan  1 2006  0:00:00.000",
    -  gps_message="/PFU3SOP-4WG14EPU0V1KA",
    -  meinberg_antenna_status="RECONNECTED on 2006-07-18 08:13:20.0000000 (+0000)
    -  UTC CORR, LOCAL TIME, reconnect clockoffset +0.0000000 s,
    -  disconnect time 0000-00-00 00:00:00.0000000 (+0000) ",
    -  gps_tot_51="week 1400 + 3 days + 42300.0000000 sec",
    -  gps_tot_63="week 1400 + 3 days + 42294.0000000 sec",
    -  gps_t0a="week 1400 + 5 days + 71808.0000000 sec",
    -  gps_cfg[1]="[0x9] BLOCK II", gps_health[1]="[0x0] OK;SIGNAL OK",
    -  gps_cfg[2]="[0x0] BLOCK I", gps_health[2]="[0x3f] PARITY;MULTIPLE ERRS",
    -  gps_cfg[3]="[0x9] BLOCK II", gps_health[3]="[0x0] OK;SIGNAL OK",
    -  gps_cfg[4]="[0x9] BLOCK II", gps_health[6]="[0x0] OK;SIGNAL OK",
    -  gps_cfg[5]="[0x9] BLOCK II"
    -		
    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction. The default value depends on the clock type. -
    time2 time -
    - If flag1 is 0, time2 specifies the offset of the PPS signal from the actual time (PPS fine tuning). -
    - If flag1 is 1, time2 specifies the number of seconds a receiver with a premium local oscillator can be trusted after losing synchronisation. -
    stratum stratum -
    The stratum for this reference clock. -
    refid refid -
    The refid for this reference clock. -
    -
    -
    flag1 { 0 | 1 } -
    If 0, the fudge factor time2 refers to the PPS offset. -
    If 1, time2 refers to the TRUST TIME. -
    flag2 { 0 | 1 } -
    If flag2 is 1, sample PPS on CLEAR instead of on ASSERT. -
    flag3 { 0 | 1 } -
    If flag3 is 1, link kernel PPS tracking to this refclock instance. -
    flag4 { 0 | 1 } -
    Delete next leap second instead of adding it. (You'll need to wait a bit for that to happen 8-) -
    - Note about auxiliary Sun STREAMS modules (SunOS and Solaris):
    -
    -
    The timecode of these receivers can be sampled via a STREAMS module in the kernel. (The STREAMS module has been designed for use with Sun systems under SunOS 4.1.x or Solaris 2.3 - 2.8. It can be linked directly into the kernel or loaded via the loadable driver mechanism.) This STREAMS module can be adapted to convert different time code formats. Nowadays the PPSAPI mechanism is usually used. -
    -

    Making your own PARSE clocks

    -

    The parse clock mechanism deviates from the way other NTP reference clocks work. For a short description of how to build parse reference clocks, see making PARSE clocks.

    -

    Additional Information

    -

    Reference Clock Drivers

    -
    - - + + + Generic Reference Driver + + + +

    Generic Reference Driver

    +

    Last update: + 27-Jan-2014 05:31 + UTC

    +
    +

    Synopsis

    + Address: 127.127.8.u
    + Reference ID: PARSE
    + Driver ID: GENERIC
    + Serial Port: /dev/refclock-u; TTY mode according to clock type
    + PPS device: /dev/refclockpps-u; alternate PPS device (if not available via the serial port) +

    Description

    + The PARSE driver supports 20 different clock types/configurations. PARSE is actually a multi-clock driver.
    +
    +

    The actual receiver status is mapped into various synchronization states generally used by receivers. The driver is configured to interpret the time codes of Meinberg DCF77 AM receivers, DCF77 FM receivers, Meinberg GPS16x/17x receivers, Trimble SV6 GPS, ELV DCF7000, Schmid, Wharton 400A and low cost receivers (see list below).

    +

    The reference clock support in NTP contains the necessary configuration tables for those receivers. In addition to supporting several different clock types and up to 4 devices, the processing of a PPS signal is also provided as a configuration option. The PPS configuration option uses the receiver-generated time stamps for feeding the PPS loopfilter control for much finer clock synchronization.

    +

    CAUTION: The PPS configuration option is different from the hardware PPS signal, which is also supported (see below), as it controls the way ntpd is synchronized to the reference clock, while the hardware PPS signal controls the way time offsets are determined.

    +

    The use of the PPS option requires receivers with an accuracy of better than 1ms.

    +

    Timecode variables listed by ntpq (8)

    +

    The ntpq program can read and display several clock variables. These hold the following information:

    +
    +
    refclock_format
    +
    A qualification of the decoded time code format.
    +
    refclock_states
    +
    The overall running time and the accumulated times for the clock event states.
    +
    refclock_status
    +
    Lists the currently active receiver flags. Additional feature flags for the receiver are optionally listed in parentheses.
    +
    refclock_time
    +
    The local time with the offset to UTC (format HHMM).
    +
    timecode
    +
    The actual time code.
    +
    +

    If PPS information is present, additional variables are available:

    +
    +
    refclock_ppsskew
    +
    The difference between the RS-232-derived timestamp and the PPS timestamp.
    +
    refclock_ppstime
    +
    The PPS timestamp.
    +
    +

    Supported Devices

    +

    Currently, twenty-four clock types are supported by the PARSE driver and up to four (devices /dev/refclock-0 - /dev/refclock-3) of these clocks may be operational at any one time.
    + A note on the implementations:

    +
      +
    • These implementations were mainly done without actual access to the hardware, thus not all implementations provide full support. The development was done with the help of many kind souls who had the hardware and kindly lent me their time and patience during the development and debugging cycle. Thus for continued support and quality, direct access to the receivers is a big help. Nevertheless I am not prepared to buy these reference clocks - donations to (kardel <AT> ntp.org) are welcome as long as they work within Europe 8-). +

      Verified implementations are:

      +
        +
      • RAWDCF variants +

        These variants have been tested for correct decoding with my own homegrown receivers. Interfacing with specific commercial products may involve some fiddling with cables. In particular, commercial RAWDCF receivers have a seemingly unlimited number of ways to draw power from the RS-232 port and to encode the DCF77 datastream. You are mainly on your own here unless I have a sample of the receiver.

        +
      • +
      • Meinberg clocks +

        These implementations have been verified by the Meinberg people themselves and I have access to one of these clocks.

        +
      • +
      • Schweitzer Engineering + Laboratories SEL-240x clocks +

        This implementation was provided and verified by SEL and Network Time Foundation + has an SEL-2407 in one of its development labs.

        +
      • +
      +
    • +
    +

    The pictures below have been taken from and are linked to the vendors' web pages.

    + +
      +
    • server 127.127.8.0-3 mode 0 +

      Meinberg PZF5xx receiver family (FM demodulation/TCXO / 50μs)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 1 +

      Meinberg PZF5xx receiver family (FM demodulation/OCXO / 50μs)
      + Image PZF511
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 2 +

      Meinberg DCF C51 receiver and similar (AM demodulation / 4ms)
      + Image C51
      +

      +

      This mode expects the Meinberg standard time string format with 9600/7E2.

      +

      Note: mode 2 must also be used for Meinberg PCI cards under Linux, e.g. the GPS PCI card or the DCF77 PCI card. Please note the Meinberg Linux driver must be installed. That driver emulates a refclock device in order to allow ntpd to access those cards. For details, please refer to the README file that comes with the Meinberg driver package.
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 3 +

      ELV DCF7000 (sloppy AM demodulation / 50ms)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 4 +

      Walter Schmid DCF receiver Kit (AM demodulation / 1ms)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 5 +

      RAW DCF77 100/200ms pulses (Conrad DCF77 receiver module / 5ms)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 6 +

      RAW DCF77 100/200ms pulses (TimeBrick DCF77 receiver module / 5ms)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 7 +

      Meinberg GPS16x/GPS17x receivers (GPS / <<1μs)
      + Image GPS167
      +

      +

      This mode expects either the University of Erlangen time string format or the Meinberg standard time string format at 19200/8N1.

      +

      The University of Erlangen format is preferred. Newer Meinberg GPS receivers can be configured to transmit that format; for older devices, a special firmware version may be available.

      +

      In this mode some additional GPS receiver status information is also read. However, this requires a point-to-point connection. Mode 18 should be used if the device is accessed by a multidrop connection.

      +

      Note: mode 7 must not be used with Meinberg PCI cards; use mode 2 instead.
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 8 +

      IGEL clock
      + Image IGEL clock
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 9 +

      Trimble SVeeSix GPS receiver TAIP protocol (GPS / <<1μs)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 10 +

      Trimble SVeeSix GPS receiver TSIP protocol (GPS / <<1μs) (no kernel support yet)
      + Image SVeeSix-CM3
      + Image Lassen-SK8
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 11 +

      Radiocode Clocks Ltd RCC 8000 Intelligent Off-Air Master Clock support
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 12 +

      HOPF Funkuhr 6021
      + Image DCF77 Interface Board
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 13 +

      Diem's Computime Radio Clock
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 14 +

      RAWDCF receiver (DTR=high/RTS=low)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 15 +

      WHARTON 400A Series Clocks with a 404.2 Serial Interface
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 16 +

      RAWDCF receiver (DTR=low/RTS=high)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 17 +

      VARITEXT Receiver (MSF)
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 18 +

      Meinberg GPS16x/GPS17x receivers (GPS / <<1μs)
      +

      +

      This mode works without additional data communication (version, GPS status etc.) and thus should be used with multidrop, heterogeneous multiclient operation.

      +

      Note: mode 18 must not be used with Meinberg PCI cards, use mode 2 instead.
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 19 +

      Gude Analog- und Digitalsystem GmbH 'Expert mouseCLOCK USB v2.0'
      +
      +

      +
    • +
    • server 127.127.8.0-3 mode 20 +

      RAWDCF receiver similar to mode 14, but operating @ 75 baud (DTR=high/RTS=low)
      +

      +

      Driving the DCF clocks at 75 baud may help to get them to work with a bunch of common USB serial converters, that do 75 but cannot do 50 baud at all, e.g. those based on Prolific PL2303.
      +

      +
    • +
    • server 127.127.8.0-3 mode 21 +

      RAWDCF receiver similar to mode 16, but operating @ 75 baud (DTR=low/RTS=high)
      +

      +

      See comment from mode 20 clock.
      +

      +
    • +
    • server 127.127.8.0-3 mode 22 +

      MEINBERG, mode 2 but with POWERUP trust
      +

      +
    • +
    • server 127.127.8.0-3 mode 23 +

      MEINBERG, mode 7 but with POWERUP trust
      +

      +
    • +
    • server 127.127.8.0-3 mode 24 +

      Schweitzer Engineering Laboratories
      +

      +
    • +
    +

    Actual data formats and setup requirements of the various clocks can be found in NTP PARSE clock data formats.

    +

    Operation

    +

    The reference clock support software carefully monitors the state transitions of the receiver. All state changes and exceptional events (such as loss of time code transmission) are logged via the syslog facility. Every hour a summary of the accumulated times for the clock states is listed via syslog.

    +

    PPS support is only available when the receiver is completely synchronized. The receiver is believed to deliver correct time for an additional period of time after losing synchronization, unless a disruption in time code transmission is detected (possible power loss). The trust period is dependent on the receiver oscillator and thus is a function of clock type.

    +

    Raw DCF77 pulses can be fed via a level converter to the RXD pin of an RS-232 serial port (pin 3 of a 25-pin connector or pin 2 of a 9-pin connector). The telegrams are decoded and used for synchronization. DCF77 AM receivers can be bought for as little as $25. The accuracy is dependent on the receiver and is somewhere between 2ms (expensive) and 10ms (cheap). Synchronization ceases when reception of the DCF77 signal deteriorates, since no backup oscillator is available as usually found in other reference clock receivers. So it is important to have a good place for the DCF77 antenna. During transmitter shutdowns you are out of luck unless you have other NTP servers with alternate time sources available.

    +

    In addition to the PPS loopfilter control, a true PPS hardware signal can be utilized via the PPSAPI interface. PPS pulses are usually fed via a level converter to the DCD pin of an RS-232 serial port (pin 8 of a 25-pin connector or pin 1 of a 9-pin connector). To select PPS support, the mode parameter is the mode value as above plus 128. If 128 is not added to the mode value, PPS will be detected to be available but will not be used.

    +

    Hardware PPS support
    +

    +

    For PPS to be used, add 128 to the mode parameter.

    +

    If the PPS signal is fed in from a device different from the device providing the serial communication (/dev/refclock-{0..3}), this device is configured as /dev/refclockpps-{0..3}. This allows the PPS information to be fed in e.g. via the parallel port (if supported by the underlying operation system) and the date/time telegrams to be handled via the serial port.

    +

    Monitor Data

    +

    Clock state statistics are written hourly to the syslog service. Online information can be found by examining the clock variables via the ntpq cv command.
    + Some devices have quite extensive additional information (GPS16x/GPS17x, Trimble). The driver reads out much of the internal GPS data and makes it accessible via clock variables. To find out about additional variable names, query for the clock_var_list variable on a specific clock association as shown below.

    +

    First let ntpq display the table of associations:

    +
      ntpq> as    ind assID status  conf reach auth condition  last_event cnt    ===========================================================      1 19556  9154   yes   yes  none falsetick   reachable  5      2 19557  9435   yes   yes  none  candidat  clock expt  3      3 19558  9714   yes   yes  none  pps.peer   reachable  1  		
    +

    Then switch to raw output. This may be required because of display limitations in ntpq/ntpd - so large lists need to be retrieved in several queries.

    +
      ntpq> raw    Output set to raw  		
    +

    Use the cv command to read the list of clock variables of a selected association:

    +
      ntpq> cv 19557 clock_var_list  		
    +

    The long output of the command above looks similar to:

    +
      assID=19557 status=0x0000,    clock_var_list="type,timecode,poll,noreply,badformat,baddata,fudgetime1,    fudgetime2,stratum,refid,flags,device,clock_var_list,refclock_time,refclock_status,    refclock_format,refclock_states,refclock_id,refclock_iomode,refclock_driver_version,    meinberg_gps_status,gps_utc_correction,gps_message,meinberg_antenna_status,gps_tot_51,    gps_tot_63,gps_t0a,gps_cfg[1],gps_health[1],gps_cfg[2],gps_health[2],gps_cfg[3],    gps_health[3],gps_cfg[4],gps_health[4],gps_cfg[5]"  		
    +

    Then use the cv command again to list selected clock variables. The following command must be entered as a single line:

    +
      ntpq> cv 19557 refclock_status,refclock_format,refclock_states,refclock_id,    refclock_iomode,refclock_driver_version,meinberg_gps_status,gps_utc_correction,    gps_message,meinberg_antenna_status,gps_tot_51,gps_tot_63,gps_t0a,gps_cfg[1],    gps_health[1],gps_cfg[2],gps_health[2],gps_cfg[3],gps_health[3],gps_cfg[4],    gps_health[4],gps_cfg[5]  		
    +

    The output of the command above is wrapped around depending on the screen width and looks similar to:

    +
      status=0x0003,    refclock_status="UTC DISPLAY; TIME CODE; PPS; POSITION; (LEAP INDICATION;    PPS SIGNAL; POSITION)",    refclock_format="Meinberg GPS Extended",    refclock_states="*NOMINAL: 21:21:36 (99.99%); FAULT: 00:00:03 (0.00%);    running time: 21:21:39",    refclock_id="GPS", refclock_iomode="normal",    refclock_driver_version="refclock_parse.c,v 4.77 2006/08/05 07:44:49    kardel RELEASE_20060805_A",    meinberg_gps_status="[0x0000] <OK>",    gps_utc_correction="current correction 14 sec, last correction    on c7619a00.00000000  Sun, Jan  1 2006  0:00:00.000",    gps_message="/PFU3SOP-4WG14EPU0V1KA",    meinberg_antenna_status="RECONNECTED on 2006-07-18 08:13:20.0000000 (+0000)    UTC CORR, LOCAL TIME, reconnect clockoffset +0.0000000 s,    disconnect time 0000-00-00 00:00:00.0000000 (+0000) ",    gps_tot_51="week 1400 + 3 days + 42300.0000000 sec",    gps_tot_63="week 1400 + 3 days + 42294.0000000 sec",    gps_t0a="week 1400 + 5 days + 71808.0000000 sec",    gps_cfg[1]="[0x9] BLOCK II", gps_health[1]="[0x0] OK;SIGNAL OK",    gps_cfg[2]="[0x0] BLOCK I", gps_health[2]="[0x3f] PARITY;MULTIPLE ERRS",    gps_cfg[3]="[0x9] BLOCK II", gps_health[3]="[0x0] OK;SIGNAL OK",    gps_cfg[4]="[0x9] BLOCK II", gps_health[6]="[0x0] OK;SIGNAL OK",    gps_cfg[5]="[0x9] BLOCK II"  		
    +

    Fudge Factors

    +
    +
    time1 time
    +
    Specifies the time offset calibration factor, in seconds and fraction. The default value depends on the clock type.
    +
    time2 time
    +
    If flag1 is 0, time2 specifies the offset of the PPS signal from the actual time (PPS fine tuning).
    +
    If flag1 is 1, time2 specifies the number of seconds a receiver with a premium local oscillator can be trusted after losing synchronisation.
    +
    stratum stratum
    +
    The stratum for this reference clock.
    +
    refid refid
    +
    The refid for this reference clock.
    +
    +
    +
    flag1 { 0 | 1 }
    +
    If 0, the fudge factor time2 refers to the PPS offset.
    +
    If 1, time2 refers to the TRUST TIME.
    +
    flag2 { 0 | 1 }
    +
    If flag2 is 1, sample PPS on CLEAR instead of on ASSERT.
    +
    flag3 { 0 | 1 }
    +
    If flag3 is 1, link kernel PPS tracking to this refclock instance.
    +
    flag4 { 0 | 1 }
    +
    Delete next leap second instead of adding it. (You'll need to wait a bit for that to happen 8-)
    +
    + Note about auxiliary Sun STREAMS modules (SunOS and Solaris):
    +
    +
    The timecode of these receivers can be sampled via a STREAMS module in the kernel. (The STREAMS module has been designed for use with Sun systems under SunOS 4.1.x or Solaris 2.3 - 2.8. It can be linked directly into the kernel or loaded via the loadable driver mechanism.) This STREAMS module can be adapted to convert different time code formats. Nowadays the PPSAPI mechanism is usually used.
    +
    +

    Making your own PARSE clocks

    +

    The parse clock mechanism deviates from the way other NTP reference clocks work. For a short description of how to build parse reference clocks, see making PARSE clocks.

    +

    Additional Information

    +

    Reference Clock Drivers

    +
    + + diff --git a/contrib/ntp/html/drivers/driver9.html b/contrib/ntp/html/drivers/driver9.html index 112f2d7a3..2e52af8f0 100644 --- a/contrib/ntp/html/drivers/driver9.html +++ b/contrib/ntp/html/drivers/driver9.html @@ -2,57 +2,59 @@ - - - - Magnavox MX4200 GPS Receiver - - + + + + Magnavox MX4200 GPS Receiver + + - -

    Magnavox MX4200 GPS Receiver

    -
    -

    Synopsis

    - Address: 127.127.9.u
    - Reference ID: GPS
    - Driver ID: GPS_MX4200
    - Serial Port: /dev/gpsu; 4800 baud, 8-bits, no parity
    - Features: ppsclock (required) -

    Description

    -

    This driver supports the Magnavox MX4200 Navigation Receiver adapted to precision timing applications. It requires the ppsclock line discipline or streams module described in the Line Disciplines and Streams Modules page. It also requires a level converter such as described in the Pulse-per-second (PPS) Signal Interfacing page.

    -

    This driver supports all compatible receivers such as the 6-channel MX4200, MX4200D, and the 12-channel MX9212, MX9012R, MX9112.

    -

    Leica MX9400N Navigator Leica Geosystems acquired the Magnavox commercial GPS technology business in February of 1994. They now market and support former Magnavox GPS products such as the MX4200 and its successors.

    -
    -

    Leica MX9400N Navigator.

    -

    Operating Modes

    -

    This driver supports two modes of operation, static and mobile, controlled by clock flag 2.

    -

    In static mode (the default) the driver assumes that the GPS antenna is in a fixed location. The receiver is initially placed in a "Static, 3D Nav" mode, where latitude, longitude, elevation and time are calculated for a fixed station. An average position is calculated from this data. After 24 hours, the receiver is placed into a "Known Position" mode, initialized with the calculated position, and then solves only for time.

    -

    In mobile mode, the driver assumes the GPS antenna is mounted on a moving platform such as a car, ship, or aircraft. The receiver is placed in "Dynamic, 3D Nav" mode and solves for position, altitude and time while moving. No position averaging is performed.

    -

    Monitor Data

    -

    The driver writes each timecode as received to the clockstats file. Documentation for the NMEA-0183 proprietary sentences produced by the MX4200 can be found in MX4200 Receiver Data Format.

    -

    Fudge Factors

    -
    -
    time1 time -
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. -
    time2 time -
    Not used by this driver. -
    stratum number -
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. -
    refid string -
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. -
    flag1 0 | 1 -
    Not used by this driver. -
    flag2 0 | 1 -
    Assume GPS receiver is on a mobile platform if set. -
    flag3 0 | 1 -
    Not used by this driver. -
    flag4 0 | 1 -
    Not used by this driver. -
    -

    Additional Information

    -

    Reference Clock Drivers 

    -
    - - + +

    Magnavox MX4200 GPS Receiver

    +

    Last update: + 21-Oct-2010 23:44 + UTC

    +
    +

    Synopsis

    + Address: 127.127.9.u
    + Reference ID: GPS
    + Driver ID: GPS_MX4200
    + Serial Port: /dev/gpsu; 4800 baud, 8-bits, no parity
    + Features: ppsclock (required) +

    Description

    +

    This driver supports the Magnavox MX4200 Navigation Receiver adapted to precision timing applications. This driver supports all compatible receivers such as the 6-channel MX4200, MX4200D, and the 12-channel MX9212, MX9012R, MX9112.

    +

    Leica MX9400N Navigator Leica Geosystems acquired the Magnavox commercial GPS technology business in February of 1994. They now market and support former Magnavox GPS products such as the MX4200 and its successors.

    +
    +

    Leica MX9400N Navigator.

    +

    Operating Modes

    +

    This driver supports two modes of operation, static and mobile, controlled by clock flag 2.

    +

    In static mode (the default) the driver assumes that the GPS antenna is in a fixed location. The receiver is initially placed in a "Static, 3D Nav" mode, where latitude, longitude, elevation and time are calculated for a fixed station. An average position is calculated from this data. After 24 hours, the receiver is placed into a "Known Position" mode, initialized with the calculated position, and then solves only for time.

    +

    In mobile mode, the driver assumes the GPS antenna is mounted on a moving platform such as a car, ship, or aircraft. The receiver is placed in "Dynamic, 3D Nav" mode and solves for position, altitude and time while moving. No position averaging is performed.

    +

    Monitor Data

    +

    The driver writes each timecode as received to the clockstats file. Documentation for the NMEA-0183 proprietary sentences produced by the MX4200 can be found in MX4200 Receiver Data Format.

    +

    Fudge Factors

    +
    +
    time1 time +
    Specifies the time offset calibration factor, in seconds and fraction, with default 0.0. +
    time2 time +
    Not used by this driver. +
    stratum number +
    Specifies the driver stratum, in decimal from 0 to 15, with default 0. +
    refid string +
    Specifies the driver reference identifier, an ASCII string from one to four characters, with default GPS. +
    flag1 0 | 1 +
    Not used by this driver. +
    flag2 0 | 1 +
    Assume GPS receiver is on a mobile platform if set. +
    flag3 0 | 1 +
    Not used by this driver. +
    flag4 0 | 1 +
    Not used by this driver. +
    +

    Additional Information

    +

    Reference Clock Drivers 

    +
    + + - \ No newline at end of file + diff --git a/contrib/ntp/html/mx4200data.html b/contrib/ntp/html/drivers/mx4200data.html similarity index 98% rename from contrib/ntp/html/mx4200data.html rename to contrib/ntp/html/drivers/mx4200data.html index 7bf66b115..611da6a5f 100644 --- a/contrib/ntp/html/mx4200data.html +++ b/contrib/ntp/html/drivers/mx4200data.html @@ -3,11 +3,14 @@ MX4200 Receiver Data Format - +

    MX4200 Receiver Data Format

    +

    Last update: + 21-Oct-2010 23:44 + UTC


    Table of Contents

      @@ -1068,7 +1071,7 @@ Example:
      $PMVXG,830,T,1998,10,12,15:30:46,U,S,000298,00003,000000,01*02
      - + - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/oncore-shmem.html b/contrib/ntp/html/drivers/oncore-shmem.html index 8942927b1..ec1d97441 100644 --- a/contrib/ntp/html/drivers/oncore-shmem.html +++ b/contrib/ntp/html/drivers/oncore-shmem.html @@ -10,6 +10,9 @@

      Motorola ONCORE - The Shared Memory Interface

      +

      Last update: + 21-Oct-2010 23:44 + UTC


      Introduction

      In NMEA mode, the Oncore GPS receiver provides the user with the same information as other GPS receivers. In BINARY mode, it can provide a lot of additional information.

      @@ -158,4 +161,4 @@ - \ No newline at end of file + diff --git a/contrib/ntp/html/drivers/scripts/footer.txt b/contrib/ntp/html/drivers/scripts/footer.txt index 89216ce97..d716cbf20 100644 --- a/contrib/ntp/html/drivers/scripts/footer.txt +++ b/contrib/ntp/html/drivers/scripts/footer.txt @@ -1,7 +1,9 @@ document.write("\ \ -\ -\ -
      gif\ +\ Home Pagegif\ -Contacts
      ") \ No newline at end of file +\ +Site Map\ +\ +Contacts\ +") diff --git a/contrib/ntp/html/drivers/scripts/style.css b/contrib/ntp/html/drivers/scripts/style.css index 096b18a6a..7b90fce00 100644 --- a/contrib/ntp/html/drivers/scripts/style.css +++ b/contrib/ntp/html/drivers/scripts/style.css @@ -61,4 +61,4 @@ th {background: #FFFFCC; th.caption {background: #EEEEEE; color: #006600; - text-align: center;} \ No newline at end of file + text-align: center;} diff --git a/contrib/ntp/html/drivers/tf582_4.html b/contrib/ntp/html/drivers/tf582_4.html index 6b0ce0aaa..177976cff 100644 --- a/contrib/ntp/html/drivers/tf582_4.html +++ b/contrib/ntp/html/drivers/tf582_4.html @@ -11,6 +11,9 @@

      European Automated Computer Time Services

      +

      Last update: + 21-Oct-2010 23:44 + UTC


      Several European countries use the following message data format:

      Data format
      @@ -68,4 +71,4 @@ - \ No newline at end of file + diff --git a/contrib/ntp/html/extern.html b/contrib/ntp/html/extern.html index 3245fca65..764631d69 100644 --- a/contrib/ntp/html/extern.html +++ b/contrib/ntp/html/extern.html @@ -1,33 +1,48 @@ - - - - - - External Clock Discipline and the Local Clock Driver - - - - -

      External Clock Discipline and the Local Clock Driver

      -

      Last update: 18:38 UTC Thursday, July 28, 2005

      -
      -

      The NTPv4 implementation includes provisions for an external clock, where the system clock is implemented by some external hardware device. One implementation might take the form of a bus peripheral with a high resolution counter disciplined by a GPS receiver, for example. Another implementation might involve another synchronization protocol, such as the Digital Time Synchronization Service (DTSS), where the system time is disciplined to this protocol and NTP clients of the server obtain synchronization indirectly via the server. A third implementation might be a completely separate clock discipline algorithm and synchronization protocol, such as the Lockclock algorithm used with NIST Automated Computer Time Service (ACTS) modem synchronized time.

      -

      When external clocks are used in conjunction with NTP service, some way needs to be provided for the external clock driver and NTP daemon ntpd to communicate and determine which discipline is in control. This is necessary in order to provide backup, for instance if the external clock or protocol were to fail and synchronization service fall back to other means, such as a local reference clock or another NTP server. In addition, when the external clock and driver are in control, some means needs to be provided for the clock driver to pass on status information and error statistics to the NTP daemon.

      -

      Control and monitoring functions for the external clock and driver are implemented using the Local Clock (type 1) driver and the ntp_adjtime() system call. This system call is implemented by special kernel provisions included in the kernel of several operating systems, including Solaris, Tru64, FreeBSD and Linux, and possibly others. When the external clock is disabled or not implemented, the system call is used to pass time and frequency information, as well as error statistics, to the kernel. Besides disciplining the system time, the same interface can be used by other applications to determine the operating parameters of the discipline.

      -

      When the external clock is enabled, ntpd does not discipline the system clock, nor does it maintain the error statistics. In this case, the external clock and driver do this using mechanisms unknown to ntpd; however, in this case the kernel state variables are retrieved at 64-s intervals by the Local Clock driver and used by the clock selection and mitigation algorithms to determine the system variables presented to other NTP clients and peers. In this way, downstream clients and servers in the NTP subnet can make an intelligent choice when more than one server is available.

      -

      In order to implement a reliable mitigation between ordinary NTP sources and the external clock source, a protocol is necessary between the local clock driver and the external clock driver. This is implemented using Boolean variables and certain bits in the kernel clock status word. The Boolean variables include the following:

      -

      ntp_enable. set/reset by the enable command. enables ntp clock discipline

      -

      ntp_control. set during initial configuration if kernel support is available

      -

      kern_enable Set/reset by the enable command

      -

      If the kern_enable switch is set, the daemon computes the offset, frequency, maximum error, estimated error, time constand and status bits, then provides them to the kernel via ntp_adjtime(). If this switch is not set, these values are not passed to the kernel; however, the daemon retrieves their present values and uses them in place of the values computed by the daemon.

      -

      The pps_update bit set in the protocol routine if the prefer peer has survived and has offset less than 128 ms; otherwise set to zero.

      -

      The pps_control Updated to the current time by kernel support if the PPS signal is enabled and working correctly. Set to zero in the adjust routine if the interval since the last update exceeds 120 s.

      -

      The ntp_enable and kern_enable are set by the configuration module. Normally, both switches default on, so the daemon can control the time and the kernel discipline can be used, if available. The pps_update switch is set by the protocol module when it believes the PPS provider source is legitimate and operating within nominals. The ntp_control switch is set during configuration by interrogating the kernel. If both the kern_enable and ntp_control switches are set, the daemon disciplines the clock via the kernel and the internal daemon discipline is disabled.

      -

      The external clock driver controls the system time and clock selection in the following way. Normally, the driver adjusts the kernel time using the ntp_adjtime() system call in the same way as the daemon. In the case where the kernel discipline is to be used intact, the clock offset is provided in this call and the loop operates as specified. In the case where the driver steers only the frequency, the offset is specified as zero.

      -
      - - - - \ No newline at end of file + + + +External Clock Discipline and the Local Clock Driver + + + +

      External Clock Discipline and the Local Clock Driver

      +

      Last update: + 9-May-2014 04:46 + UTC

      +
      +

      The NTPv4 implementation includes provisions for an external clock, where + the system clock is implemented by some external hardware device. + One implementation might take the form of a bus peripheral with a high resolution + counter disciplined by a GPS receiver, for example. Another implementation + might involve another synchronization protocol, such as the Digital Time Synchronization + Service (DTSS), where the system time is disciplined to this protocol and + NTP clients of the server obtain synchronization indirectly via the server. + A third implementation might be a completely separate clock discipline algorithm + and synchronization protocol, such as the Lockclock algorithm used + with NIST Automated Computer Time Service (ACTS) modem synchronized time.

      +

      When external clocks are used in conjunction with NTP service, some way needs to be provided for the external clock driver and NTP daemon ntpd to communicate and determine which discipline is in control. This is necessary in order to provide backup, for instance if the external clock or protocol were to fail and synchronization service fall back to other means, such as a local reference clock or another NTP server. In addition, when the external clock and driver are in control, some means needs to be provided for the clock driver to pass on status information and error statistics to the NTP daemon.

      +

      Control and monitoring functions for the external clock and driver are implemented using the Local Clock (type 1) driver and the ntp_adjtime() system call. This system call is implemented by special kernel provisions included in the kernel of several operating systems, including Solaris, Tru64, FreeBSD and Linux, and possibly others. When the external clock is disabled or not implemented, the system call is used to pass time and frequency information, as well as error statistics, to the kernel. Besides disciplining the system time, the same interface can be used by other applications to determine the operating parameters of the discipline.

      +

      When the external clock is enabled, ntpd does not discipline the system clock, nor does it maintain the error statistics. In this case, the external clock and driver do this using mechanisms unknown to ntpd; however, in this case the kernel state variables are retrieved at 64-s intervals by the Local Clock driver and used by the clock selection and mitigation algorithms to determine the system variables presented to other NTP clients and peers. In this way, downstream clients and servers in the NTP subnet can make an intelligent choice when more than one server is available.

      +

      In order to implement a reliable mitigation between ordinary NTP sources and the external clock source, a protocol is necessary between the local clock driver and the external clock driver. This is implemented using Boolean variables and certain bits in the kernel clock status word. The Boolean variables include the following:

      +

      ntp_enable. set/reset by the enable command. enables ntpd + clock discipline

      +

      ntp_control. set during initial configuration if kernel support is available

      +

      kern_enable Set/reset by the enable command

      +

      If the kern_enable switch is set, the daemon computes the offset, + frequency, maximum error, estimated error, time constant and status bits, + then provides them to the kernel via ntp_adjtime(). If this switch + is not set, these values are not passed to the kernel; however, the daemon + retrieves their present values and uses them in place of the values computed + by the daemon.

      +

      The pps_update bit set in the protocol routine if the prefer peer has survived and has offset less than 128 ms; otherwise set to zero.

      +

      The PPS control Updated to the current time by kernel support if + the PPS signal is enabled and working correctly. Set to zero in the adjust + routine if the interval since the last update exceeds 120 s.

      +

      The ntp_enable and kern_enable are set by the configuration module. Normally, both switches default on, so the daemon can control the time and the kernel discipline can be used, if available. The pps_update switch is set by the protocol module when it believes the PPS provider source is legitimate and operating within nominals. The ntp_control switch is set during configuration by interrogating the kernel. If both the kern_enable and ntp_control switches are set, the daemon disciplines the clock via the kernel and the internal daemon discipline is disabled.

      +

      The external clock driver controls the system time and clock selection in the following way. Normally, the driver adjusts the kernel time using the ntp_adjtime() system call in the same way as the daemon. In the case where the kernel discipline is to be used intact, the clock offset is provided in this call and the loop operates as specified. In the case where the driver steers only the frequency, the offset is specified as zero.

      +
      + + + diff --git a/contrib/ntp/html/filter.html b/contrib/ntp/html/filter.html new file mode 100644 index 000000000..5f9ed0abc --- /dev/null +++ b/contrib/ntp/html/filter.html @@ -0,0 +1,34 @@ + + + + + +Clock Filter Algorithm + + + +

      Clock Filter Algorithm

      +

      Last update: + 10-Mar-2014 05:05 + UTC

      +
      +

      The clock filter algorithm processes the offset and delay samples produced by the on-wire protocol for each peer process separately. It uses a sliding window of eight samples and picks out the sample with the least expected error. This page describes the algorithm design principles along with an example of typical performance.

      +
      gif +

      Figure 1. Wedge Scattergram

      +
      +

      Figure 1 shows a typical wedge scattergram plotting sample points of offset versus delay collected over a 24-hr period. As the delay increases, the offset variation increases, so the best samples are those at the lowest delay. There are two limb lines at slope ±0.5, representing the limits of sample variation. However, it is apparent that, if a way could be found to find the sample of lowest delay, it would have the least offset variation and would be the best candidate to synchronize the system clock.

      +

      The clock filter algorithm works best when the delays are statistically identical in the reciprocal directions between the server and client. This is apparent in Figure 1, where the scattergram is symmetric about the x axis through the apex sample. In configurations where the delays are not reciprocal, or where the transmission delays on the two directions are traffic dependent, this may not be the case. A common case with DSL links is when downloading or uploading a large file. During the download or upload process, the delays may be significantly different resulting in large errrors. However, these errors can be largely eliminated using samples near the limb lines, as described on the Huff-n'-Puff Filter page.

      +

      In the clock filter algorithm the offset and delay samples from the on-wire protocol are inserted as the youngest stage of an eight-stage shift register, thus discarding the oldest stage. Each time an NTP packet is received from a source, a dispersion sample is initialized as the sum of the precisions of the server and client. Precision is defined by the latency to read the system clock and varies from 1000 ns to 100 ns in modern machines. The dispersion sample is inserted in the shift register along with the associated offset and delay samples. Subsequently, the dispersion sample in each stage is increased at a fixed rate of 15 μs/s, representing the worst case error due to skew between the server and client clock frequencies.

      +

      In each peer process the clock filter algorithm selects the stage with the smallest delay, which generally represents the most accurate data, and it and the associated offset sample become the peer variables of the same name. The peer jitter statistic is computed as the root mean square (RMS) differences between the offset samples and the offset of the selected stage.

      +

      The peer dispersion statistic is determined as a weighted sum of the dispersion samples in the shift register. Initially, the dispersion of all shift register stages is set to a large number "infinity" equal to 16 s. The weight factor for each stage, starting from the youngest numbered i = 1, is 2-i, which means the peer dispersion is approximately 16 s.

      +

      As samples enter the register, the peer dispersion drops from 16 s to 8 s, 4 s, 2 s, and so forth. In practice, the synchronization distance, which is equal to one-half the delay plus the dispersion, falls below the select threshold of 1.5 s in about four updates. This gives some time for meaningful comparison between sources, if more than one are available. The dispersion continues to grow at the same rate as the sample dispersion. For additional information on statistacl principles and performance metrics, see the Performance Metrics page.

      +

      As explained elsewhere, when a source becomes unreachable, the poll process inserts a dummy infinity sample in the shift register for each poll sent. After eight polls, the register returns to its original state.

      +
      gif   gif +

      Figure 2. Raw (left) and Filtered (right) Offsets

      +
      +

      Figure 2 shows the performance of the algorithm for a typical Internet path over a 24-hr period. The graph on the left shows the raw offsets produced by the on-wired protocol, while the figure on the right shows the filtered offsets produced by the clock filter algorithm. If we consider the series formed as the absolute value of the offset samples, the mean error is defined as the mean of this series. Thus, the mean error of the raw samples is 0.724 ms, while the mean error of the filtered series is 0.192 ms. Radio engineers would interpret this as a processing gain of 11.5 dB.

      +

      The reader might notice the somewhat boxy characteristic of the filtered offsets. Once a sample is selected, it remains selected until a newer sample with lower delay is available. This commonly occurs when an older selected sample is discarded from the shift register. The reason for this is to preserve causality; that is, time always moves forward, never backward. The result can be the loss of up to seven samples in the shift register, or more to the point, the output sample rate can never be less than one in eight input samples. The clock discipline algorithm is specifically designed to operate at this rate.

      +
      + + + diff --git a/contrib/ntp/html/gadget.html b/contrib/ntp/html/gadget.html deleted file mode 100644 index b13fe081f..000000000 --- a/contrib/ntp/html/gadget.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - Gadget Box PPS Level Converter and CHU Modem - - - - -

      Gadget Box PPS Level Converter and CHU Modem

      - gifA Gadget Box built by Chuck Hanavin -

      Related Links

      -

      - -
      -

      -

      table of Contents

      - -
      -

      Introduction

      -

      Many radio clocks used as a primary reference source for NTP servers produce a pulse-per-second (PPS) signal that can be used to improve accuracy to a high degree. However, the signals produced are usually incompatible with the modem interface signals on the serial ports used to connect the signal to the host. The gadget box consists of a handful of electronic components assembled in a small aluminum box. It includes level converters and a optional radio modem designed to decode the radio timecode signals transmitted by the Canadian time and frequency station CHU. A complete set of schematics, PCB artwork, drill templates can be obrtained via the web from ftp.udel.edu as gadget.tar.Z.

      -

      The gadget box is assembled in a 5"x3"x2" aluminum minibox containing the level converter and modem circuitry. It includes two subcircuits. One of these converts a TTL positive edge into a fixed-width pulse at EIA levels and is for use with a timecode receiver or oscillator including a TTL PPS output. The other converts the timecode modulation broadcast by Canadian time/frequency standard station CHU into a 300-bps serial character stream at EIA levels and is for use with the Radio CHU Audio Demodulator/Decoder driver.

      -
      - - - - \ No newline at end of file diff --git a/contrib/ntp/html/groups.html b/contrib/ntp/html/groups.html deleted file mode 100644 index 7f6d14bac..000000000 --- a/contrib/ntp/html/groups.html +++ /dev/null @@ -1,47 +0,0 @@ - - - - - - - - Trusted Hosts and Groups - - - - -

      Trusted Hosts and Groups

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      Alice holds the key.

      -

      Last update: 00:12 UTC Tuesday, November 08, 2005

      -
      -

      Related Links

      - -

      Table of Contents

      - -
      -

      Trusted Hosts and Groups

      -

      Each cryptographic configuration involves selection of a signature scheme and identification scheme, called a cryptotype, as explained in the Authentication Options page. The default cryptotype uses RSA encryption, MD5 message digest and TC identification. First, configure a NTP subnet including one or more low-stratum trusted hosts from which all other hosts derive synchronization directly or indirectly. Trusted hosts have trusted certificates; all other hosts have nontrusted certificates. These hosts will automatically and dynamically build authoritative certificate trails to one or more trusted hosts. A trusted group is the set of all hosts that have, directly or indirectly, a certificate trail ending at a trusted host. The trail is defined by static configuration file entries or dynamic means described on the Automatic NTP Configuration Options page.

      -

      On each trusted host as root, change to the keys directory. To insure a fresh fileset, remove all ntpkey files. Then run ntp-keygen -T to generate keys and a trusted certificate. On all other hosts do the same, but leave off the -T flag to generate keys and nontrusted certificates. When complete, start the NTP daemons beginning at the lowest stratum and working up the tree. It may take some time for Autokey to instantiate the certificate trails throughout the subnet, but setting up the environment is completely automatic.

      -

      If it is necessary to use a different sign key or different digest/signature scheme than the default, run ntp-keygen with the -S type option, where type is either RSA or DSA. The most often need to do this is when a DSA-signed certificate is used. If it is necessary to use a different certificate scheme than the default, run ntp-keygen with the -c scheme option and selected scheme as needed. If ntp-keygen is run again without these options, it generates a new certificate using the same scheme and sign key.

      -

      After setting up the environment it is advisable to update certificates from time to time, if only to extend the validity interval. Simply run ntp-keygen with the same flags as before to generate new certificates using existing keys. However, if the host or sign key is changed, ntpd should be restarted. When ntpd is restarted, it loads any new files and restarts the protocol. Other dependent hosts will continue as usual until signatures are refreshed, at which time the protocol is restarted.

      -

      Identity Schemes

      -

      As mentioned on the Autonomous Authentication page, the default TC identity scheme is vulnerable to a middleman attack. However, there are more secure identity schemes available, including PC, IFF, GQ and MV described on the Identification Schemes page. These schemes are based on a TA, one or more trusted hosts and some number of nontrusted hosts. Trusted hosts prove identity using values provided by the TA, while the remaining hosts prove identity using values provided by a trusted host and certificate trails that end on that host. The name of a trusted host is also the name of its sugroup and also the subject and issuer name on its trusted certificate. The TA is not necessarily a trusted host in this sense, but often is.

      -

      In some schemes there are separate keys for servers and clients. A server can also be a client of another server, but a client can never be a server for another client. In general, trusted hosts and nontrusted hosts that operate as both server and client have parameter files that contain both server and client keys. Hosts that operate only as clients have key files that contain only client keys.

      -

      The PC scheme supports only one trusted host in the group. On trusted host alice run ntp-keygen -P -p password to generate the host key file ntpkey_RSAkey_alice.filestamp and trusted private certificate file ntpkey_RSA-MD5_cert_alice.filestamp. Copy both files to all group hosts; they replace the files which would be generated in other schemes. On each host bob install a soft link from the generic name ntpkey_host_bob to the host key file and soft link ntpkey_cert_bob to the private certificate file. Note the generic links are on bob, but point to files generated by trusted host alice. In this scheme it is not possible to refresh either the keys or certificates without copying them to all other hosts in the group.

      -

      For the IFF scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -I -p password to produce her parameter file ntpkey_IFFpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts that operate as both servers and clients and install a soft link from the generic ntpkey_iff_alice to this file. If there are no hosts restricted to operate only as clients, there is nothing further to do. As the IFF scheme is independent of keys and certificates, these files can be refreshed as needed.

      -

      If a rogue client has the parameter file, it could masquerade as a legitimate server and present a middleman threat. To eliminate this threat, the client keys can be extracted from the parameter file and distributed to all restricted clients. After generating the parameter file, on alice run ntp-keygen -e and pipe the output to a file or mail program. Copy or mail this file to all restricted clients. On these clients install a soft link from the generic ntpkey_iff_alice to this file. To further protect the integrity of the keys, each file can be encrypted with a secret password.

      -

      For the GQ scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -G -p password to produce her parameter file ntpkey_GQpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts and install a soft link from the generic ntpkey_gq_alice to this file. In addition, on each host bob install a soft link from generic ntpkey_gq_bob to this file. As the GQ scheme updates the GQ parameters file and certificate at the same time, keys and certificates can be regenerated as needed.

      -

      For the MV scheme, proceed as in the TC scheme to generate keys and certificates for all group hosts. For illustration assume trish is the TA, alice one of several trusted hosts and bob one of her clients. On TA trish run ntp-keygen -V n -p password, where n is the number of revokable keys (typically 5) to produce the parameter file ntpkeys_MVpar_trish.filestamp and client key files ntpkeys_MVkeyd_trish.filestamp where d is the key number (0 < d < n). Copy the parameter file to alice and install a soft link from the generic ntpkey_mv_alice to this file. Copy one of the client key files to alice for later distribution to her clients. It doesn't matter which client key file goes to alice, since they all work the same way. Alice copies the client key file to all of her cliens. On client bob install a soft link from generic ntpkey_mvkey_bob to the client key file. As the MV scheme is independent of keys and certificates, these files can be refreshed as needed.

      -
      - - - - \ No newline at end of file diff --git a/contrib/ntp/html/hints.html b/contrib/ntp/html/hints.html new file mode 100644 index 000000000..7749ba9a1 --- /dev/null +++ b/contrib/ntp/html/hints.html @@ -0,0 +1,22 @@ + + + + +Hints and Kinks + + + +

      Hints and Kinks

      + from Alice's Adventures in Wonderland, Lewis Carroll +

      Mother in law has all the answers.

      +

      Last update: + 10-Mar-2014 05:06 + UTC

      +
      +
      +

      This is an index for a set of troubleshooting notes contained in individual text files in the ./hints directory. They were supplied by various volunteers in the form of mail messages, patches or just plain word of mouth. Each note applies to a specific computer and operating system and gives information found useful in setting up the NTP distribution or site configuration. The notes are very informal and subject to errors; no attempt has been made to verify the accuracy of the information contained in them.

      +

      Additions or corrections to this list or the information contained in the notes is solicited. The most useful submissions include the name of the computer manufacturer (and model numbers where appropriate), operating system (specific version(s) where appropriate), problem description, problem solution and submitter's name and electric address. If the submitter is willing to continue debate on the problem, please so advise. See the directory listing.

      +
      + + + diff --git a/contrib/ntp/html/build/hints/a-ux b/contrib/ntp/html/hints/a-ux similarity index 100% rename from contrib/ntp/html/build/hints/a-ux rename to contrib/ntp/html/hints/a-ux diff --git a/contrib/ntp/html/build/hints/aix b/contrib/ntp/html/hints/aix similarity index 100% rename from contrib/ntp/html/build/hints/aix rename to contrib/ntp/html/hints/aix diff --git a/contrib/ntp/html/build/hints/bsdi b/contrib/ntp/html/hints/bsdi similarity index 100% rename from contrib/ntp/html/build/hints/bsdi rename to contrib/ntp/html/hints/bsdi diff --git a/contrib/ntp/html/build/hints/changes b/contrib/ntp/html/hints/changes similarity index 100% rename from contrib/ntp/html/build/hints/changes rename to contrib/ntp/html/hints/changes diff --git a/contrib/ntp/html/build/hints/decosf1 b/contrib/ntp/html/hints/decosf1 similarity index 100% rename from contrib/ntp/html/build/hints/decosf1 rename to contrib/ntp/html/hints/decosf1 diff --git a/contrib/ntp/html/build/hints/decosf2 b/contrib/ntp/html/hints/decosf2 similarity index 100% rename from contrib/ntp/html/build/hints/decosf2 rename to contrib/ntp/html/hints/decosf2 diff --git a/contrib/ntp/html/build/hints/freebsd b/contrib/ntp/html/hints/freebsd similarity index 100% rename from contrib/ntp/html/build/hints/freebsd rename to contrib/ntp/html/hints/freebsd diff --git a/contrib/ntp/html/build/hints/hpux b/contrib/ntp/html/hints/hpux similarity index 100% rename from contrib/ntp/html/build/hints/hpux rename to contrib/ntp/html/hints/hpux diff --git a/contrib/ntp/html/build/hints/linux b/contrib/ntp/html/hints/linux similarity index 100% rename from contrib/ntp/html/build/hints/linux rename to contrib/ntp/html/hints/linux diff --git a/contrib/ntp/html/build/hints/mpeix b/contrib/ntp/html/hints/mpeix similarity index 100% rename from contrib/ntp/html/build/hints/mpeix rename to contrib/ntp/html/hints/mpeix diff --git a/contrib/ntp/html/build/hints/notes-xntp-v3 b/contrib/ntp/html/hints/notes-xntp-v3 similarity index 100% rename from contrib/ntp/html/build/hints/notes-xntp-v3 rename to contrib/ntp/html/hints/notes-xntp-v3 diff --git a/contrib/ntp/html/build/hints/parse b/contrib/ntp/html/hints/parse similarity index 97% rename from contrib/ntp/html/build/hints/parse rename to contrib/ntp/html/hints/parse index 07fbc6bfe..d2523515e 100644 --- a/contrib/ntp/html/build/hints/parse +++ b/contrib/ntp/html/hints/parse @@ -24,7 +24,7 @@ Directory contents: - Trimble SV6 GPS receiver If you want to add new clock types please check - with kardel informatik.uni-erlangen.de. These files + with kardel@informatik.uni-erlangen.de. These files implement the conversion of RS232 data streams into timing information used by refclock_parse.c which is mostly generic except for NTP configuration constants. diff --git a/contrib/ntp/html/build/hints/refclocks b/contrib/ntp/html/hints/refclocks similarity index 100% rename from contrib/ntp/html/build/hints/refclocks rename to contrib/ntp/html/hints/refclocks diff --git a/contrib/ntp/html/build/hints/rs6000 b/contrib/ntp/html/hints/rs6000 similarity index 100% rename from contrib/ntp/html/build/hints/rs6000 rename to contrib/ntp/html/hints/rs6000 diff --git a/contrib/ntp/html/build/hints/sco.html b/contrib/ntp/html/hints/sco.html similarity index 66% rename from contrib/ntp/html/build/hints/sco.html rename to contrib/ntp/html/hints/sco.html index bd08e981b..d5d1933b3 100644 --- a/contrib/ntp/html/build/hints/sco.html +++ b/contrib/ntp/html/hints/sco.html @@ -1,24 +1,29 @@ - + + + SCO Unix hints - + -

      SCO Unix hints

      -

      Older SCO Unix versions

      +

      SCO Unix hints

      +

      Last update: + 21-Oct-2010 23:44 + UTC

      +

      Older SCO Unix versions

      NTP 4.0.x does not run on SCO Unix prior to version 3.2.5.0.0. If you need NTP on an older SCO Unix system and don't mind to modify your kernel, use 3.5.91 which has patches for SCO Unix 3.2.4.x. Apply the kernel modifications as described in XNTP on SCO 3.2.4.2.

      -

      Compiling NTP

      +

      Compiling NTP

      Delete the old SCO supplied NTP programs using the "custom" utility. Run the NTP configure program with CFLAGS="-b elf -K processor-type" for best results.

      -

      Running NTP

      +

      Running NTP

      Run "tickadj -As" after every reboot to set the variables "clock_drift" and "track_rtc" to the right values.

      Run "ntpd" with a high negative nice-value, i.e. "nice --19 ntpd" for best results.

      -

      More information

      +

      More information

      More information on the way SCO Unix and NTP interact can be found in NTP on SCO Unix, which includes links to precompiled versions of NTP.

      -

      Kees Hendrikse, January 1999

      +

      Kees Hendrikse, January 1999

      - \ No newline at end of file + diff --git a/contrib/ntp/html/build/hints/sgi b/contrib/ntp/html/hints/sgi similarity index 100% rename from contrib/ntp/html/build/hints/sgi rename to contrib/ntp/html/hints/sgi diff --git a/contrib/ntp/html/build/hints/solaris-dosynctodr.html b/contrib/ntp/html/hints/solaris-dosynctodr.html similarity index 94% rename from contrib/ntp/html/build/hints/solaris-dosynctodr.html rename to contrib/ntp/html/hints/solaris-dosynctodr.html index fc7fae935..89a12b27d 100644 --- a/contrib/ntp/html/build/hints/solaris-dosynctodr.html +++ b/contrib/ntp/html/hints/solaris-dosynctodr.html @@ -25,7 +25,7 @@ - +
      @@ -35,12 +35,12 @@ - Sun Microsystemsgif + Sun Microsystems
      Home * Buy * My Sun(sm)sun.com Global Sections
      - +
      @@ -58,7 +58,7 @@ -
      Search SunSolve
      + @@ -86,9 +86,9 @@ Y2K Central
      Security Information
      -
      sopkoEdit
      +
        - +


      ------
      +tPT0o&n|BgHE%wCEDq_?S;Ch1)WS!CtY zMHb;~x5re3iIHw^?UK@%!v)MSdto|a3pD7>6Kx1q98wAe;15~Aws*&JX z9k$Vr@67p1lC{dP-hI0SybB{BYv4<7qnL`_Z+bvh{bJTH@7evN)gr#hrB7aYqVIR! zKAvOn-oFyPhR&m8uT!StYVEJn+ct{oa5uuZ4H6!^CnboIXVO0#{=H_sosEv$A}rHW z&Rg^J4auLK_>z}ZiBFB-CY8^W0q^shWC|<8$MNr@xTG^U@>(g zNnhF7be=JTbvC(^1&J&tZ4m!MH@bx~+(#h4Qxf&fgX0?h`NZHZJs1GWC1Zc4f>(dS zCne9~MA_ho26LTA_D1L`8zdQe3pbBU0JxglC7BzA$wH*G5#|dVkdIK8cMjtNF=Pg} z6Jz(bPj^zjWa&YUb?anhK7UJNuxks5UUhGHNARmPvSnlWZ!wYo&|1}B;%C-JNqI|A zRu)l@Yxkc$xc=PwziT&#vs22^u}O`N}N+g`t~_;&T#SgL}Rk0fLgViZSgGTX6e1Xi0Hw>!x2*0o3n7B zYV=ngz1j1^WR$Z0{Z;zv@If~;6Ypq}{>%!u`jv^%);i9G$Vq_3nvCz3OzKV0h$a0= zwxfDe;%GP4`lGA-{Aiz<;BOv$uzHPH6Wfd9vENK!@UwwZmxS?OORsviRIqKsCB*{3 z2VwV0UraW|fb~KH==W2ckKAtv*vq*3jaBT_0_ULI^m;ihVzp_vq)v^0qeq`g$oU>* z$PnRyRqhf?BPXDxymuQt;~(JUrUH)~HZuY57;p!%O}!l?8j+(*COMeg{H?+BThp;z zlx6Q_A~yvH0WyN-hZVkp|9fo<^P(G)rMgx`cuW0R68!7ioBa?}D9xE^qSpgrPvLl? zQNv(Mg4QDg<8!Bt7;fcfz8J27Tx;|X4t~echMvoABbUr5KyIS9RccA`>W$qBYu5&x zw(o$YjOduMZ|$5I^4s5Jn{~gd^ND$PS+t7@yF{NHJnq)gwn2~6x=Fu(uQf|`^ZHBM zQiOHyPUdTy&@23UCFLNWCs2A&ZCs#{1W`o`B(jA>S z7K|3VWo{mao`J%4h$EMB9@&yOt*2l0ZZ{jeo{{bIR~|O_aPO-|q<73;Yk~mTDE#Y) zY>JYkgY9C|fui+qzp*#akCV?kwAHBZMJc%_^)=chhp79lkU$qHmqDRlZ}X1PMt4%! zavnXpIU*|S4h}U`8Y1cDKAQC~dB8L0v%-WoWu7BPw8;-=7q^n34yr>IeRu^hIYn7VqygCNFzP>+hSnbc!cKR3g9&@1k zUcqR-T}ewwKEXDgRGna`k0U;U2imF&n8kFtnSWx99AIaS=nBcY-TT==+&x+4vHjJK zBZ;!(4f>Z(yi$8m5OOubV(iD3FWU;i-df!q{|>s3|i zG`j(C;jh1)>hv#DN?rAB%_FYuQri<`HdOq;@&Aop79tD0X;w|meV*n=SV|=L?7i{B zIO`|Ha=bKhUr_xa=VmHR0iL73QK=L>cm7zH>rBRfTGjJHkD+pHn(Gkbl%uOo&pYp1 z7GhnZ&mXae^^o5wTq7;~#`nzlk6dDLvezsMcFzgkwU*kIyI8*RonTawE!l%~H9nHL zdCtn%{m2tp8M94!({;5B3!A5+r5LlLx${qTj)ke9FuC5GtCsen=6rS_f3>>265q>W13x+G)YH@d*ck3kwSDW^=g(}GdkDlU`K z+Cjzv0z-!9O0G(hDu3NdRQSzfB^8I{D!`EbgZT+u4LBY&;s`Z96IEikv&Fn);gQJc zIB0H^SuLgo5%_Ur)tFXn4V%`>4=j5-Ud;yO@C_Qd<^9+&bQ*2POZ-;YaGX5I|0=0V z@i^MyczYz9?9fE%N|L5NUU(vJoz`bir00CMlwZO_F72K(J$J18 zhvhT)y`+n-PTl@;s@jLEt<(>{fnVbimLDcFsO~cWVupLh$(K-1havp|hq^<~Kp01? zA0-}V{wK%yoGuiny-YOo*8bseNB*wtlUpO)aer>yVEDfPga>>07M((ZVUWk8;%|To zs{5^xgwkqhVe+85UO;>)F>)SZ-`$MZP@B{Z#iG2%0w(Wk87H# zm%3+dh~K_DB`;!be5jfF2_hs5sQkQ(S7pH?{+gy$pg+bbSV0vu{Sz#jV}R3~&5q?y zKN-))j7@efYt57r(#P|KMa@QbD{K@dGYK6ei9c-Zhz2XG|7RJ|nJWw3*GoPPMS9;= z9R_~z7jK)aG~xq`}P_uL20kG>f*(0UcGwn_7%uB zS}2gASOxMjMo=JA7f%VE`WSL#$&*J$^OAA~Tbr9Xzs#I7XqKd)af&W5sOT)D1+oNn z&Gr;!s-aFTJ9YaSS-fV!;;ma2(eAR?z``}omQ|~rZ{-T|()W3E=z^$IXSKX-v{um? zlT^ND#F5mj5Xm-w9)0?Rp)9`~=(2Nso1}5}EHDMMP}bZ}T|1g3kWC3WSOYXf0ud3x7F~Q1p-uWj z1dEuKqCvhKUusMLC)2)w%D>aD=_8J;T0t$p*P?>aqfjows|&qaVrwg}+LCJq;y&Dx z%MG~;WvQYx!m7W(GRlf6r$b)Wx`Vc8xXb7ioCv&TjYoOHo!)RbHfW$n-0I6jSLqf<}|w5?WHS-}ccSgaOb%1W)v3%R`T!a3*e z%yBDX#JoXuCGOWa27Ef-`^!8G>{i$#_yl%AHw z>5C~A@M)03xL~DGifs0{uYWkMv-L9$qiQ74;pi&1LRyB61}PRY2e zEB+NEhqJmJH{`Bq+fY>Y;EL^{RtorH;X(R1iZ#;);jT@mZ=U;1yqxm_i>`W}fd*FC zJp~J3g-!{Jr*`UYB-)gAkiWJa!kfqekFDWo#VajUfL&`P++Y)Jw-&P z#coCa(ylDeIJqvk{`~XEapUr6|4c&)b(jq@35wYfnpjljnamrDD+J#R;NoOCKG%)D zPL4c8x=n&ZHGMDx{J<|<2ZkP3qsY~ix)n|y^wL|TIA}(>0U6tp&*4w zaWF*;tWY!P#fWTXG9Zku<^=)Rqy<>8R8h2JoBUBlbZ^m4sGOue_hk?f5Tx1=^D>a@ zWo&yE%v7nc0y4C8JrtNeer^y(W6kQ6#R@AZ zG7x^l7Hs0s2bA@JOjyARCvDX$#YK*o)mqRft=BAPog$T~q?&_@;y*-O$U<+yV+C2s zp^G?9k18u4lE4-RN+Ki_TZ}_v3IZk;tudMLjHkScSeHhHVvheJVz=6IJ-h&H76f#h zT2|Rj<6s4xtQ=IBT6sc_$OxS5T4%}RSy79|K}OQ-LZ_04(NM`Br9Ml?IMr#6r()Fm>XUcsBF9g94i%=lHHV48{^9V6%b)f zhQehQ$%)HY5}-2(M(Ao5qKPTAS5TUY=?+i*>Jle%!mKFhTsRHtTEj@xu5^JQ+u_gt zAlQXjc%cPl=~p$I*A;*TM=Z*rPFf%cu(VKctZ(^dV#~El{>)04f+1B$;mKCZwn#=? zxsYa47^*wi=6VnC!o_Cr08(;p29+ahD`auKE?gl80n;91iz2FocF|C@{gA9Yf~%Z5 zDV>)UE}Te(7leIu28fVdA8muJE|~TKOua^w04j>-WR|5)$e}!+h70w7r^@MgIv-sVj;8$!bujx r)+zd6lGnaA5ZkfKMzO(rqq9 zlH-yPr?W0fI+YVAoL|4==RAKrpXYtv_kG^a>)>Q>VHtJ`bb^^}5Fa1^_3Kyg6F9j6 z;0Jub4*rM1V1}Q8xQn0+fWG^np`k%jQ`6VickJJ8uo4C=EG%g0>}VbUW4uZLYJeO8 zU;xnlcR&-aw8J|U*xmsE-!{O;Hps}x$ji%CM+u~}LBT=nzq%Q91X>#?1@S<}|Q0uR} zCZF%+A_?h-M8DDs(U$aFI|^^kRlk^fb8ho!Q*ilzZE*NY>0yU-@yRJyQ}r_ne6QrB zDB$x8%RGp9)cN8IQrF9CUGyt&-ipf;+;+g@gegtU9o7g#QCm&t?TV`2ICEy{y;{6l zLobRsB+$lNJ`ytzjy=wv&mc!`sujv3`JXDmoPU&aM8}|lYZ)}dg zb7Ks8sQgp^L*3$ry$4w4p3_pdG0dr)midZvH`TVqf*4~r#6|5`q z8gFpbI8iF3`>wg{)q8KC+sga-NC7E33(kL5@Z0jE!O;7Www|OZ#_XCC;r>`&fXS$OEOOQW&>5~CS zwf>sYTk)SxBA8Wd1R;v7AnT4CkAs#ERA|Ad1pYoq!TBGu7i z#6DFASdCqCJXJAp#?P-%047+ zy4})BOy@4ToqM_qF|yH=Bp@I46R;6}YM&vpqmlnjl|@Ohsf|>h1r?k{ zbfp1uA6#R53=vXAp_ONR4NJQ_p9Es`zwjUw)Vb2GVZpj??ttvgri1+{Y#Xlu)Z3}I z11UeGn-3zZsIRE45=*ZlIlSxW*e`3&a;I9keWRalxU$MAG6Y+&a!6M^;qIlJJ4S4Z zOpLXEM7yX9Qy_5ACQvg)0s5&Xf(0FC)}69%qj3$vGff|Z&O<|0PU#~zrAICfk%qR~ z(H@uBlnE+g?*NEUh>`9KzT9`QVftcFH*)`C(v$fZ|GiY`UVp(t%K2ycE1h~*_$vTo z3wUzT9qQ{qaqI&7_26T9@uIL+gC>7fU@!nRa{ZDp!@dl@k)y7#TZYU9O#>f`vtDl} zd@<;Nqf?0*Zii8(l_Jt`;%@|h*2B4EL@qNQop*|V~w zi-r)WAKf~6hCH;o1wt1)Lx$#)j)~=pZoA!|h?ym&zl+oo|7m70IfV0LH;2?{Bo$$T zrJ$Jg^iS4jJ~1(Nou)c=-zxI<3P;L~=FY4vqtGA_Eddnex=e)Y^YKAcbMf z!`au4ylZnsAj=uJLw1eNmzpETf*8>KY-`0AY=oj@E@jd7peBhCxq8G#&ZCSB*J$%1 zMQdW5ZF(SeXAsUuX~=dNZpLPmlk7vlNkrDb&86SWn?hp?uBHvRKQ z7g4kE1r$sI(Tlid;nis*A7iH_jeEZ`_ayX1;}u+VM{zy3BFwGBH2x!bA9Ae!R#<5y zH>LsG4(+=n7a7U_;5~oI>mkvg;TD#0CcbNLUzZy;^5?Jq+4GsP-!tikM(OUm=jpd= zV_75L#pe%)xt+QCS5e*6i_?!e4w)Iv^l$0gkdAH_4vi;8%ZHTI;|)*LW|pVcVjwc$(D}hkjF8 z+rFCcPN$BRrD=A@jL~&11rk4zT3{tVMAk99!eICPUo-pSAmSj(wHDJ^$c=jHG5OO> z0GH)Y*1IIG3R+ZpKe>#qxL!ZT|Lr!Eg0X!W6Y+bV14gFvrp%pe?sBt%`Y=5(YvMTQ zlSIa*5~@F|f7l-=3bX%vzw>5bJ7k;gNx6_8a84Vn*Gt`W*c|AB>^Zxili&yc375oY z(#~Zb^c$tMGg|55!dCNy_dVley_V%Pq1}@R6ETA|IL}nIsB?{tOL~~`LjmNAI)X1d z6IN`E6IVx|u1%IbI*hLUh(Gp`31Q9&*Hu%^ETQLj(`Rg@?;KHZN>glQKDHH(lz*B@ zODi+bYkW=ZOZiO-c!asWejd>=Y_vr9qo%uUT7`4l=|vkuRaU;$+~|K5OupP*Bva3# zi}>T9qcUrXIJr9{yyIGqtNBbWvFL7B`n8`_=a7bzFPAzObP1bLAN?oXL^&}d*$%R( zF_?nff!Z{c_x_J*78pGN9~Yfx8S7b%5GoXrviGfN_}vfl?^}Pf^`K` z!s~4Je%Fpyzj~f8k}>`x`=?P$jp&TdeTme`{ZtfmDCg`{VwRWVmFiu!^?K_MJQ3Mz zL8!v-jL*rMTg3x}Db^;rExDk~V}Mm5%9`%bTnVljAXG{67P{lI>YMLjgMXK@zVjCS zGf4SpCTa43#slRBoolLh8PZQ#BdEg+0tWvd^4Z=EnZb##sulb_apmTJnzT}>6`qQ5 zl;igpL4)|eGv8cmO@CtH34>|g&9Hi|IQPiEV9VN?Q>gIzZ#*TXlcd`?D}QQOs<=nm z!`$Kc@Fj09ba$uS90a|6XFw%gBiW9kLFhl~gifWSuiA+{hBshHM}=tdVHy{zF)5|P zfv;)9`^pSmD4wKtl|Z<`&mOo1Q1UVgH(rJ)Qpl+t>XbJi);z6g_{?aDwh_yWz<|6$ zXa%!QJ0`*{(D*byntsh{$r$G4C>Q#Ym58`RXBpHQDgD)Bv_yvuK~;lAySBVDyX@r$ z8NGw@qf`MZiF2xsSB_T+UL7S*Tu? zcetLShRGjv;yAjXn3MH@Lp2ayi8g|eJxxU%1*QnJ^yYPGK|`01VH0*gx3~7WV8z!o ztr6rGbIdT3e8GfX6gtI@p{^n^7wKU`faStwZne;?0ET`mjg^am)2FhDYxc}lOXWb? zhAPxHJ>?$B3&y4%tA}eD!mdV0(<5lT^x~S$ypb6xManVFRr@YsMzbEY@m(&TQ$Ubp zGAD{=NJ^n5mVXE?JBkVGiKcjl^+I&9G1?wvA)oq6uhC53ui1MC>OCDX+P0+~H4C(r zVc<)pjTJR)c4e4_&KcPVU@mpg+$>lOmc^XN0(* zb_%j`O2B)Sc|$iqTAgIwL+3Woi>M_XsBaZY2mX48fDTbixQt@zl!3zweq;?M{ z(3S|xJ!h$y>yJs`RJ7r;joF!V5tUiO!y)Hc_=$??2wssfB!48c2V+urw_uH=8@gWU zh|DH1km}(_h$ZBvIqZrhpq{jbtdvsQ5wkb4R?r6)6k$F{K(5s)KF9(HPlNCJmPtap z6=cTyk`l06t7s4=E3~ubLfMc~XDpA(-X~oFJ{0|;=M3*RVFpD>n*<5$B+%?R>h`d} SpOx6BUuU0G=Zc1dBmW0<$sZ8_ literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/pogo4.gif b/contrib/ntp/html/pic/pogo4.gif new file mode 100644 index 0000000000000000000000000000000000000000..e0a3b178160bda62d7f718fd41562a964f14d886 GIT binary patch literal 3213 zcmc&z`9D+F~hxC##&;C7$S#!%Tm@fku8)^V>yY6O2}5GERpQxxRUJqzI3hE zQe!zuLZohAp{^||Lecqtj(_6&`R#c<&-31%bB-J}{m%iG8B`0cLJ&?o498I%M{pd* zafqle498F$LvRenF^FiQ7>=Siir^@WqYyERU^s%}2!bOpjzGjJjNvef!w3$;I1B+K z9Kvu2#UTWTU>pJkzy{C&3oL_ah~Oa}ieU(b!59V+w4g#!3`H;$#!!e*0h$PkAqa-R z7y=QZz$}bnFoMA_217t2Sj8X|gAfdYF$k~%)c_2L1}cFp&;!H(8$bgrunZA~h#EWu zMPU?$2!DVUR0x71Fp5BgU7!LqVFZO?6o!C%APUT)5Q0K53ITf{4YCDi}s!2;>Uv0u`W%KrjM<96{0` z0H6zugP?(15GBY1$OPLU4xkAb1`dI000u;ZO&|;C0K@!j8a^1Q&(cC&A5%bnnh}o^6iPX2UBUZQKAdax*kU-iJP26Nl2LZeV4L%2O zB@iC)v_%Eb{|`@gorep8Mj;h~oA@UnG7eSo?J%p%YQIGmR(9&HeB2qeU5=SyR+arU zRvh+v+g+8ziI*{o*>SWwwJN@Lyo8@)QBk||QbwUb#} z_%g>VSyZIhZ=$Zi@=tn5qqmrC5l_*ekSML>?}84`1@_2riG8_8o_>UBtms%R^KqmJ zRlCT^u_wzVE_n5#b52l2#7eA|uU(79wnG*OP5I2JIR2UEKLh@?)s)tSY@E=7Qtvc9 z{)uKW-yAIG04G&T{;J%te??utN>F#g>%3U~hZa&=pNCsaa@OCX@{Gs_!IS=2((v8G z$2}N-U>XTo60nHAp6WqZa+XnX9d9q+OfSW%`wRB!e|@te;gD}wx0#~#<*nj7xA+@Y zJ~@jk?_LjTMW0nPx{({s8PqD9k2=f7R0E&Wrc_C?uFtO<$oS_uM^7+G6d{2q9+RsU znhGwXgTZX8z_*7jRc-IOyc9|9)7Vu!wZnh3g*>Uzma)feuknX8IcAMjx18T8ljJ_N zr^bJoCsOircg1hC2fD^sZYIUL3bkr?Qchj|=$>Gg%|l~|Aa?}L+xDj+VHa9glkdlj zc}^v+YehSYc_ij5rcsrZ%(61BulH&6`Jw|_rE6=0_Z-xZq(3l5(vN9w${J3D%UVP` zGo-nTloGR4rf0&ET$g#IngVfpN?LRvnHHn*>w{b_vp;LXG;^MAZ&#aAEgMpw6e+;S zu8!Gd!m6^SFx(AlVyhOp(o0=+Tm$wT=@~FIG;rq=R*H|hL`_Ybxza^ZHQQl)zsk9G zAgA#|yCRuUR>>wG>2P8vRP`*!I+xWarB}2v4XXqhuk|T$ZK?N#meljsNJ@0JU;89y z7hEK$*|Eoces{QTXRNy9oR)MqJlgcATgt#Tre{RKmRb{jxN*_Z-C4E<`%&MRs2;Ru z=&Htp%4#Mbk}uv&q6viodhg zxYGHAD$htM3t+hRO%j22gI9ktVXYUXyc@QD4O zlyj$e&G@#qAWgqSRipQ#E2VwAYobr|jnGRgShx3;tv%eNsOx2>#*uXC=^9yFd zhCJcCr#&YG-INBxhUk65kS~xL3wyiOt=7SZ((7F4c5@fp|d+gnlPdtlX-V(R|6md0^oEN$Z&NJFPvn zyMCt{a~DN~&Y#n5X3HR4snGowhm)wo!mMX1`@`oc&QIjAC2?hg?E*Rl8M%c6NJsqG zTnZP&w=kclb;6a;29|lG>h`S9*0l%Pby+@S&s5)L;5asN}&Xn1iB}7|I?M$io zd|=*+7GzT&MvY{d7}I&e$#P8lV)C?@gHHNzw7UP}pqVMp#a`<_{~0ROm?q!K|G^o< z!@k#vmJYk?D38B-^DX|$u(yj3v!~+t{`#iiVpGc!^~u(eYNfoHOYt$fZM+TT8PoH& z`9I$ljm#ExKJ>oQ6BFIaEgl$**|^-goch^U;H|Y;m1x5kJ8}P(o9e&VBPHb|@8bgE ziEa6s4OdJ~dbFfFOht&b=M5hZ(vceTyDnafk`~$HW3QupKb9&-?v3?voGho8a(*w8 zH@)oD)%!uaSaY{mBi&Dsdt&G=#H;T2x_IDwJ?-yllX4R?lOAT{^0k^Zb=Nx?NWB6# ze&^vrw2SM>j|=7BTQ00i2tN1x34TE1YF1)Qb;L(qp;%netqGG{?m(1(|bAG z6Q9?f9*jhI8GffHlC)_1Ggt36cqE$JaI>kjee?-B$MD_7+YTX?()@ncB)Fj58ym?Oa+vjIv z=fYRv+DA*Z;v1tm`YZW9latBVx>#k{LdkEx_>Y=ww7m-Lcg>9E9`9fOZ}6eOvejQ+ zGv1cJhT_ANuPdf5xA}z3-oQ8E`G4RBPU9b~Z42hslV8ra{aQWrj@~AxyLm43#aFkc z-)@kWE(LPJI)npm@Se?I4gF#pS`ZNSHSuuUxkLI69%a74w100N{ph9EuIOUTRtRM8 L>E6!81?l_`sVvv{ literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/pogo5.gif b/contrib/ntp/html/pic/pogo5.gif new file mode 100644 index 0000000000000000000000000000000000000000..87ad8e490d6b459d4ec2bc9ad401f48b7013ccd1 GIT binary patch literal 5819 zcmWkwe>~IqAAj%nht2kxhLIoph*(rxQuOn)`Pq;eNpoe4eoY-F(sYJp4p*zjDejtz z>Pq<$rysiET9lJcsjJR+ew4bpjDD!QvakE|_4~);`T7yEF4)gMF#=o$(`H~cn;{5- zVVKEeve|4dm&@n#1puv8@w zEBJhoKf-194H^99Y@`fsH?)sWkMjk5gV~^{S4g!|zLd}Av$-NJ;*V&}T5+uy;Uh2` zhPklFEJ9=mQ^aJ7nTQtQj&qp`CVP<0o@OIM2(z9ED`1EZ!DTR{fS_6kGC%+VfDHf_ z0Dl1Z0Ehq(10VxH4uArHG61vy)C150Ksx{i00sdV0$>^d^Q43`9&IM<4_Svm7oA;QzqKMrL#8%lUFKTP$PCm=IHeD71*S8mVSOY!NIP zN5%z^Kn#f|;0Xn!n1-fjEt!DH1zdmN&j)+~5Qu7aMb41`L0GIc5ft>^twyRYZ3+I_QWt9xr$g>X~nC)gy4P@{#h1uC@5EQ^hOKi-}1) zkl*||8n)$Aq0HFN6R7a3yy$=3pP!EvVi{|EVwA=cNhH|8)3a?bf%70~|EGEEf1B|Z zw9gA&o7Lgp^Lg<$^K4_|7A5?WoH#!#20R`yI>njE1K0iS@@g-CnDQtsJ~C}8A2ZPt zdf>bgSLN5;tnE$PfopS+qiU@2mUDb}CvQJxDy@t5{w2&H{cF$2kFWB48!p6T@`&`h8en6n5Jp6-a6JP4{uyQXm?=J3p1eEQLOcYL<&B1So@l1GTlEXbGOsAwC$ z>)=vxSbf}ORb8Esm}wAU`3G{seFuc|<}ZDKe-QAk#+tYalI~D#}xpzhby;zvpeaF!$kC>v@V|`7P-m13Y z$y^GyGqhqt5%6TsDd8YoTB7yt4g$|e1fFr!F+ zP3?H^a347(^ntE`%&tts24<&Ty0MFJw#fT3tJWJ$V$M|Fv}Wyb$%AUvtb%Skowmhb zK8}Lh#fGKf2hOm4L&%soUXxaX-*lg4@xCKpNbNswahe*}50%VQwyGERCq~+kl{XwQ zwXAaQMB>VRJ2R1cS%;5G$>oH9|CwI51C4NN^|JlOY}K883-Z*Y?m{K6>g^;ed2`KRq6TGyIG|Z$}`Jv z?Irp$%0qWn3P=K|KvASAbo$7Gg3uc0u+v_7-G4{Z!DeBRjaKkp7gx0uTNeCi-M!qM zSl!VBt_7}W%>|J~sOQF}EP!`mVnlpc@EiKFg4WHWD!Nr`ucEcjwV17|`cMCKgoU5W za>xBbj{n+kDG9#^p~jnBjegeUrCTA7e57{veex9i1?1EbK$kA`d3g`0Jdf>oP61`DiEde+;_-v(fa;i1E zDuR22Zh=YwYm*XB?YFOSc(82C5w+;aFfFIM%V|yxDVWGQj`KrV^iXsgOAiQ7F&UO= zdLDNW3kDCPEBX*x=6%Mc8$BgS%Y8~l%WKcQT7qKn8cdY=O|r}1n&MTT zd8IL9?u%{pC_a4n@yqScGf#-o<^QA~%;)Lngd>M+)KA=j;OD!|9e;HNiUn_JD*e^nEZUCO#+{?`>^@Y@hQ%bZ7?cy=k|npG$Kk}95 z*94!djE%8#FKTWu*qpL&%%FaT++X^cB&z*)Sp^9Jg^PbBvx>SXx@b*WrBDq`TYfJ z$EV7|>4pW+8fD9c(~_HhFOK>vjs!uSlHi=2d@|E>{h!H`E-nP!srbEf>_*TZ-47$7 z*7erKuai4gntUEPm%n8W!ButeZ3p|Z;N!QQF6oX{m3UQcl*3t3?w{g~$nj_RjrO$gRjYv9^m>E5Pe zdv;^7xvGXj;W+pMt!%MAC{)GTU@QWe1@pf%mLJ$yEZk;!+b8_lq527QQm$q^J31w~ z+Z~q}`t3@37ArgMi?O0QH{zvLbHw}=^E~~FBWdVe9qXMEI#j@*t1<>74=e_JYKbfM zu$pH4YjtQF=JhKdywgV|$-U%;uy;#MLOJH8->EM1(PtDVkKW_c=w4QCiT+lw;#2ur z9&j#LLab;^B&*NOMc^VF{W=s@_kJ# z$OR_)OG#Bmj7msMT#?)`NE@;i=iS&0^;9-q0t!Z#}bE8+TR-5N0|D+8sLF{HV0^0=blOoy#Qfs z8JiS1+M&Y$yMbrH!nmcAuJaw}x`M}Jv=?bqfz2GFWW{P;lE=LSiw1Y6^iq+}vZ1pv zpH0*$)b4r)urPs>+?dvygHh4E8Qt=f0jepD`lf+4uHR6(y@aY+ghep(2+^t~R6&sV zrH1+nrB5&!ZBa31C9p>q<}Cp`ZI;y~(#F#^{?Cs-!~u_m)GsJa^3d{J;YSjsi;-AW0ld{WO#0Nc3TGhtcMkDT6n;;^KxiKRocl@8OY*?zl9nNmKbn zLu>J&C?%MjMj1|GsqkNM%O*aD0|=&&uA0h^{j>?ab0f#%@d3N+G|QV0%Fo9+67*JY zl+jf+8?1SDZLsAvHs;)(q-$VHUGpM)7`)O^-=MTl4YX+%ZJm4hF(IYW+-ObT_d>yocXeIea-s%fmaWL=V zV3jrC2@eY}Vz(uGXt@28K@RC?FAoh|lU zt9#0wReDvjjufq15Xf1%AREi>$1j)Q7CqTktZQz9f#11Zyvaa*zQ<%MX%mXoWZ-9D z?3`z*Uztc{dS^ZhCs4bY<}JK=Z*EhXf|u{{!q#=Oa{YJ#A+A63%oHK4AT!?>&Npy( z!ys1ZoN9uaFqq2>tI$_8_JE_`Sx$*=v1)s;Vf|rZJJ$pgbd?iMi5Df z5{h`3bMve~!R3SKc2<)z*!)5{9TORoF}uAnb&bT!uhiR?k}^$DgXIEVB4zam?SziF zS>d+v^paG+pv?;Rd=vAS=9lMLZ7ITq8>(QG+vJeEV7F22k`YPubYrCMe%46rrxW8* z&?3-_k~}ci;IPY~148+=SF~5!Uu?ovf5k@fG8W$17MYdd5w^03T24GPSz*P+;I8Iu zwDYbSCMp|Byfl;yWP&)!)Y z1xP!_Xsua!acK)~%MX$pfCXF%!Dqgj%IH;kK9J0hJJSl9kYBXkD9rdqLJSxs?lVP3 zd*OZ4uzlue$6YbEN=}E;&$Rwn6|(QL_lyuq;BR23Fn5iVwHyVKFXR@4NURSD^Dc5Q8`$3$1#X)vMg8 zrSz76m2Go!UTKU~(aF$r7x00a1zppaaaXc`KW@L{z8{vVjgwwYX`b=k^LG?@UmL#^ zWW=pHgNv&28e}k5vG4)?vj`GQmfp10=1@HtIa>UpSG@wste@ZOBq?OZC?)D15vxihtY7T4QD@ zaMHf)*PfetKXPRmD}s;S(=_2$bMQ`cU0j~rwWKdlnbNCj zE=_P3^&G+bq4*VgMNXDz-)(D@4nBD>N{omcp2gRIpT2%F9Z$1BT_+p&QI6n)`+tAm$bP|pVAXMeUH_ih*J<*xSLDg- z-bpNbUlRWVW+m(4L^^(r4%e6~q8J~YxHot1nWC_Q^WmogCSnF(9TBo~-D9Un7HCW0-)eSwr1uUSY>_2{Wzv&WsGGNZ&qJt2cbq`gmG zR^mCJ4$DHAE4m-5ZY1{`BYeQdUIq;N+XVa>z+ZgIfzetKg!OO_8A;7OyLh`0!kR94)s%hgAbhxA zwChp2i?7=bZ}Mi?ZSjv$)?L>}|K?(p1cfO*V6|uHFvdTuW8wADwyVTZnX2T4T53%0 zr{DJCdAfxV)Q^Yf{3aZEa$O{YiL*f3!@l}zTra0CpGQ>k@iavKZ}!|*%|FJrMx z09*lx03ZPXApn&CbOX>2z%T&Q0L%j*U8}KR8VgdfK!^nqSWpLpHW;jJFi!@qWY}hH z3I_g6I)_RYk^zqj$B{t-8T8YED-5JIfJugVWROY)!!}@^4LD?wO$SsM>q-WtOd#ce z1Ug7qD|o<$41{bzCBsx0z*xYhf+l~koB&EWU^otBb3k_j@V5c3Oc3D;`b$BaKM=-& zrfe|X1UPJv8Ucpu0Fw^Ngc+b}uIH3V=R46p#e0FVKo0{4f7n`2QwfTmIkh0Eoq6>Q@x>pRU^g*2aJC1Pi-% zDR3Ij^`iDu*mZ^hz4c|C8L+Ntq{QUa{Unv|4?ewMmG|UOblD5jM9n{v<`5xIU)t<=SgZbzBe=4>nsNSvgy3#-168`3gW_6$W1az|Qx0TL}oQk_iXpV=@ zyBmDqd-Ku{U@g9i2Zq*10ky++q$Ca* z4O)*J#I~p|MZxMRsmUb#QbC_ua4LYnFVeb~9YL>0To6yTQ|rSC9Z&up)#}6b zJB)G=u#!$tDSQY^W0W9qmic2RyuX>Tj+w?RIsh}=hNKettmw%Cuj{L8je1< zUGfl1Wq&E44pRj$QBnT4#bLCMxKZwomJtK!*RSvNV@#()#4(ZG!lGlxzA1|listy@ z;_a%+;fF5_=98&uWSw5h$saM!daEnU&gdz5|~0 z-Urt0*Duq1nU!+Yww{%OHyn$)`=0JEUg&_|T+(rov$>Z%Pj{>za5SvG(}0lkF3fY) zD=l4gF%$%pQ|oL-kG|#6Dv-m$U zs_$3VT21Gc*@0!W;#k-6l%ZDv2N<_=1-3Bb0@1~I^R9}_??T@PW8PRVDYYMQ)4uPd zH6M~=f%vVu{4JsBI_ZWiYKcyl8$woTPdl4t9g|@qNLH-rb*L54biYqHBYHLbQ3@@6 z-^DOcYIQJlnjq@al1ce2N6m*KW3S!`oP`LXe>x4nzCx@mBB$w<`{-H0bBgi%ky?M( zU-K?Z*(HF{y7A>wtBwteypV@Q>a^}mqY(+ln~z@q!wyMyfYy!aJkX~p{O-fxC*Wo# zMwEqD%=C@H)d>ok!Uc%a9}{fvP3m;$FRjOUx;ik9v#1}349g)o6_J-Y2M4%z? z3;0K&yBo3ZUHlzB*KjV(3a}xkHH^c%aYeJ1S#o@B1{1s;naDwT9Ev27hZgQDAQThr z)uGc)Zrqz)H)11QS9@8w+YJSYr!Q;I14u4goRiRHP!sjDH-31Kc%r^SE9Mn2d(?g> ziE&tanj!JijqU`B5`bq-x)6sP^14oGzbD(t47C@Gl-Xm*3q6j*3Zl9X=RAsb=>J@A zO6-%2E}dK>S1a!$fhXG>cUK+WvxYO9!mV(y(eyjVmgZwB>ld1RC~_-r=tg>ztIT>{RKSS7X4sVPhF1fK#g69O5XEp$p+fQK zE&k)|#T_Tw&myzBy6yyo`G&fkJMOgGKG&0fs<_3!;_5D{b&H9g=T4T^(<&OK^?-Df zYDa9EcWF`WzLl-}#~(SjbZ%kHIkPoKOJ6FsRG(aM<}3R0^08tSue=Qi1&J(5OTq_} zHfB;R-zf}1P5T9HhdOpnB&AXvY%HAIuXE&;#8gbhQj3u?Kwx!4^WrB39y(37PJQK0 z6W$crau#~iFhNU@Kqer9S~KbX;8`#s$2yx6`g$Oh5a;$w8^>4fE5)t7?wCBD5*-+S6$XTCPE zGJP9@2!kc3IO9i@qf&Oz8l79u?zj*`OrQoRL7~2^Nlub{>N@GQXkCA zU=#Nf7IyW^?Yh``jXk#riJ$JV;3KWyX}en<86ME(A3EbQ_m`a|vmeE<~@nbs>H$2m6_>V zr{fsOK~WHcGEU^*h{x9Rwd9mQ*h$*nlHWp-jA%H|u4K8TNe3ydyk2R?$WxNHAXW4B zKKzUGAw+o*uaDK3c_3eh#Dr5cILYaX4nYC!IuyngxJH@&e$jPx06P|oui)daEa2@J zC~p{7CBYbQk#q^F{Q_R(fyCcYvi5xribjJ%Cd2{9?BX5$^!A4u z-w?>;+mVD4jMjeKc^0lnj1y6qWfDvQz}HA{dC}-q$<8lJxQk*;IBP={Y^-?4_!0$w zP9ihtWZ9G+_5*ofB!;=1V$wc@`<;s~W0;(DwDm`+g*j+sApjBfE{XLbMS~YifQ1jb zO#2ug;yGP0|F&-L4+TIXIhlPYYl^O+Q;`V57WC3cL&6f*3{fKc0dk zzL{z1nOF!SS;9A}IDB>%)-Gz(dGJq+26{&QLT?s|dFF&EKyiVxA1C(6ZnBl8ia9@l zM?2!Q&wd?L)T4y054yd}Y*Vm`9Dn=irR?FOXGaRpj;?sArpOOaj9xk$1#G zDbI>m5NU{ExxqY=i3f6&ukb-a`~*~{8p)rcReB1*Fq(R7c}sK!fr1O389-hrXNP~n zH&W!b*qVf7NeL*De@mb!D6}-ep z?hq@vb*VRsWSc$YnklkPud3Hu6By8dzwB#CTu?QZ zAm^nZ_*L|#9-ukRC!8Q{+CL%tfFaw+EnR$I{hdLa&6Hcm4FW6$4197#SL2qS#o1V; z?*m8^3Yf1as+19@>mf7P_$Dm()JyKBSZS6*e5y*3mBg5`kI9NOlniz!ehR^N6K4ic z(<0>vCUNSrd?wD)q`U0bc(bC;EyK-Lq8EgRrxa@Xl&3{Vr}~TWe#Z9^oV_#+v84z4T(0SmAlJ7{YrGA{&ZW zf{xjL19}!Tw;u05tG9N3j5)v#+xk>}=R@y`7($=uQuG~54OdoFd9d3TeHm#G9lKEQ zxQwRk0c|cnBM0K?953%%s?uosz6v$u$Fz5YmSiuupk%gEFGe95)Rb_8A&fKgEAo5f5O4OxZ(P88Bq6jYwA@*{;4$Atv+k%6u1YL z9opy)#Vbp6Wm7fttat^L4oTIzHVX9-FVx*8ywL*+aaBUmup)eeqVf#zsWO|y#j z^(961mx_nz_V$LlpOm#(ldW_|Q0NNPK5TL?J8@k~21rI#sc+M2aUe?%*ylANlDCsY z8`BEaulG`5QGIQ6>#MIveMnBzwPCI=qB90tfW+!Ag?l-9=MSQeO8nO0j`@v_Cq&LG@Qvy$lK9==Y~pWL4^?GNxdFIm+_z*T9M)n4lEif2vq3E=sUmM zW+JH?*-oZ|M)pL0eCeopF~aM~WC&d!K4xQ4$UJ<1kcwqM^`2e>Q1&fTo}u0`TBpIz zSTa_yH?h6@SZwoHBRI2EcT1R6g3xW1dg_F#fSal+h6t~F)}1rKyQ4y~7T3`ci58KU zy#g}$`765S)NE)dqZbvvr}0M5Z56KEj@@+qMl+pP2`;g73SOlKzmx{*rR*aP7@0g% zxtgtc9--dMbfo&NJ3VID_VD2JipI+Eu!uKC_k%c`_}UYS5Af~5oKFp{xzr*W^{t&= z0fst?Q(N)5i>SxTi1Mkqk8-c5DlLG(9)p4^jYLlSrp`|D(VG@AfBLW?MJ~F8n@(;t zE{(>?KEU!t;sXeS76l`I_4eXoGjSe1f{S2KP^&Eb<$9dBf>{>~l2)n?zc7DB&dN=} zt(fBNu(&EQN_UDFPR5l;5t)5^91h3mwFSq{CVKv(ZuesX5bE2}F~_u@gGDpkXb0}e z-^3z;$=7GN0zoz1)YY%oxSEA8Vm%G`h|eCt=5X;@3=8cT=OGPxmxJlUN&m<0kQA`i3|*nR}a91@t+Ft8hbSr=Yva6R>|kcH3ZA`GL^ z=cDl@4BUkU+)4_*l7a`-m?vI|doRjd`$CMCJD%TW{A`ja^uX8DD}{@VWe>$sg6w8% z`wFLsHG9)`d?0cF(iX;D;bSZr!i{`%$25j58l1X-zXIcnJ#e|O@eMvYTYxKu@kwXV zMq=b$X^*jE@6KA*GhDJ-pjlk;N5zh2etERaB|iFw2ad#(+4B(}CC2zgqk}!%YsBb1 zKt|~z{tyEbCr;veAh-g&+WFD36x>~9Xyga{!$)sl25kYt)-ayaCNQWS1MgLE4ieN2 zzD&O{eziW;eeVWa7V;n?(Qg6eM!|g{;mR2JQV+ahQ`YY<^sVNeh=OpV<)eOL1VfBk z^}xqaa1)cbuN?fP0o*0A3?^DrEx?kuU5_O9tfBErp?%O3#sA$6@d442x$)rLwG01-T+UyU{H|ifaD(L9CT+<_86n3Z2Ew%%Y zY4-Mw#>bGKE%!#+FP=1tgjGP#*mR!O!vN-y4_@Hm$9o6t#iir*aZu*rhAlqh9CpC0 z_Yf$nxR0bX8l$&eA2+<_G``P%ws~B?oKR$sxY72jUivlfL-+0XKH9VX)oHsa-@aQ$ zIEjVzzPZw!Adr23WMua0>2o9mhcvYn5$mFG@oZ9*SL))S<>U|7)?Y35d#2d`#O?XP zJi%`viJNJ#d+zNo=jH`*&Q~XEZpAu>du{n+=T+mXIcm(k g`&3YrKVQ=TFz!YdpBn_#o~LLp>IANXAh7xW00&fQkN^Mx literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/pogo7.gif b/contrib/ntp/html/pic/pogo7.gif new file mode 100644 index 0000000000000000000000000000000000000000..36befe7a692c9a012c835395f7288ed711fcaa15 GIT binary patch literal 13817 zcmY+qcT`i$7dCuya!8>jp@kwOfOL>v1ThI6M5S`<^J;JeZN1x^{utntW#$8Jo}lwXV&Z)Pj3$g#{&<5 zZeU#uh{a+Y4o4&s$z-yTk&&gPrK6)GjYjkF@d*kFiin7aii%1|NJvRZ$;!%Nv)Kg& z1*N5>RaI5>_4RFSZ9P3bgM)*kqoa$9iz_QDpFe+IUtbrmuMhV0wAI)5w6%>64pxl>aNa{;km6rBYRkcaV($c}w(osoSP%v6hFjrbSDJcsICfV#cHhVHFYc4BmQ6ecR zD^XD^5fLjvL7ye!pH~(~s}kmV3MSjwqmnQ6DW4ZdCkN|SCfgQA>nD3kN81V}>l0Sy z21k3U=6cwZZCRuBDT|XmbAzRmJq4qZR)dn7Rg-NgqxA`cJ@qSdJ(Gh~lRfOwwybrD zuATx(52J(ipI0Uad#cvgKa0idgAz1t^%CwSKdP!q>+7p}B)r#`_VkpltVDeN9JIb} zw7yOjizPyojJ#Nk5sQJI!L}$d(MXKRnoA*zaT2~Hv`Tm!lqivmT$@Busbr8ObQ`T3 zNw}5}jT7TAVhkV#Fk&1a#zd?nWX%<{jY_~(RY@qQulm2{_0*3JCaf$<+=V?knYFl> zu(%ksvO@d(*>Qc{^8bbMf6@GZP$YoX#Str?iJ!$Ob1QA5lTnkO9Vf*FgNqUM;`%m; zcZjRlVu@Mx{|A=Dk=lAndj<;zSE3~Lt$Yspy#D{HCa?ehO_Z1`>GJbv{orC$&tgK) zTvinT079XV{1ZX|5<5&KufYF_35vvf#8^!)0e^_8DsLP)CO9x8qk^H?R7};}%_myN zzZmNvk8q?FcbXEXX?I!rTOz|K{5Jr?0z06&Mrhc68i^Sh!Oj3uC1T_1Rj=;G=>pvL zAe(WeMoQVv%?+kTHbyf%j2Y2zsxx8drLBj4DO&7?cT_|lcpTzO&z9m+m$WYV-e`Bj z>S)t@@`GZ)_Ct>*BYmw67Vd!Y`gZU!3e>to;nSc)<+YexRYOWEw-hmgLF=z7|D4i; zAXLBp+;|Vngs|#vf+?dZ5-lHt?{B+#<1>{dU$gWL_#WC5+xL%+#h2*ES3}?UoS`7H z7jLL)*}$27H$&cPmrRN$ck(IBHPRM}#g4iCKqr!MzEDl9?+2oYHUac%eR@~kph0jL z;sra{Z!4l=KFO{oZRP;#mo@3s?wEQ&D*eDACWz6KLLktMuP^Q8xf|e)sk&K+{B>gM z2@rbBMiE91gw6m8HU!;M+;3;lWJ2$50LiqVVRXH8e!kKfu*^o6FyQNvq<*sZnD$PO zWG@55=GXOk<`HXTge+wZ4@qGH;5|w<6d37R7#C9IzgcP}SQhrW8m$7;QJ|Eb1&5a| zS~`=wMVSF0Wi+#B^R#L9o!&FJsr<@CM7?xnHiUPa;z#qDUecv$i)%7_1Ge+ zAz7BVHpcVahkXGSTF|ii014Rbs}$$M+=(idI!M~S)$v_j`pB248XolQeM@b)=$Vw| zueu;8GbvZiO{ne^>La4+F%RKQ8O)2gzpHNtpdu7Z-WmuiRs&*{B?OsYYa`ankYFY&UOSSxr)R$IoBL-D!{8kKn zSGnTGCa=epkRbwVW7RbNY`J3*z_bcnAruiFR`oEhe9a3zpV(ZMPoWDDcv*2LrNwNQ zuyheGzz>~L5RjRO+Fc&gQUuZ6)R|*@MQXvmdn}lhDp7|n`Mhs$D34YR7J2F|od1(d zk~bB>n8J~Evu0@r!Pi@be~8ov_^CoqWV0PVPFH4N_PkUa3G_tDxWSyGiOyR?1n<5$ zZhMpF7gP4*p#IIr(V>o_1@-OA7eDgCF09rK-n#4OMf$byWt< z$P7A+mIcr>!IBBhrw}2sA=HtfZM&ao9Tuz$YJfM!3QWFK+*~mPEfciD*pL<-PEDlg z%LrWm(#zT2uQu+fTLOb`Rqa*g_2{2v9Ncd{^U}FGyJdRADuM0WtM^$px2#K zZyfU>C%sYSJh+5*9+SWxfI#ya03|ytXCM5a@P0`{XorCTp9m3k0dzU(3{Z`6gHQ}u zL0QN^h5=Yg62_jQgFBd2ISAGOm8n)BjzK|^glcCK12>;d79ztQ!_-I<`CPj2$||GH zi=+ce&qKo-9Yv=YL-Kk8n)1}F@`aa;)cxamU}u1oF$I=OhgnFSB($4g$nVLE=SZ92 zn(;vW&HIDy=XE;_vfVuO@O9FW14?558Jq~w6p&+tW5AIc%c{3A9+vWe+!2S_nwJju zz}2Lpvx`wl=0YaEfX~uRoW0_12r8bXvvn&{uNazTD`=5=OkM7hLi>c!k0|)n#tMQ! zAtJRzDvi#Etj^8or0&!k8gsKSrylTf*@DAhPYlZ!#?@zNPTigv&7G zU_g2{wm$%ch_3Q77An>*`bLxj9!`c2V87KU{P|MkI~Sydas%Z0ED8S$>AoO% z&GtEES~RP(ytC$Lw0}U25Hch=T;3@ROx-kM@B(M8+WzH4xo~y2I)bTnQb(TUrGJ`0 zNB@umqa5)=q*cm8HE~&B;1j~?ueCMcLXU0W5mzDdXw)_LUMwvy5O{y=OjTv8Z)RXp zs~h*OGUi2a=+Mh1Nc3*zc$+Umfg#ix5TP{NuO;?-*Iu7ryCub*I96Az4Xxog`{F&p zzG*p~>Kj`OPAFPHuh{P*JM5U7t(n0M2epriaYjBvSekcPS? z)1N{CtDaROttVcei=-(2VPJkojL zsk2Vm)Isrh;yLS*z5U#}5YoAG3up5)u2)R#^`C_G-;ZLlFP(lHY+Ue=bjFu`V9kL} zGo$)ugR>PK6P}O%w8UKOrL<~ty=Td&>@#~9_;X3 ztZr-biwp9!a8;c@n{nbonRMyOX7tyyUr6TfkV*_tx;NZ6(Z16Qy2n_GnFWuX4JITG zk12>@SoJ7U)5ckSE-&wC_QXMc)oR36#x5SBHJCWUZhRJhrc3ISic+qsXs7If)h6eGzQ8cjpfzFW=inWu{Nt+zH9um5I7kOe`bDrn0tws3D=j1UV7y@^Ry% zvj7Yd&vXD619U+;P&l;*E8I*1l=If&_V8#_FyZb~of2f|VGqWOF9`#~r;Lg--+$Tt zVcO2^IIdfys@y>PaS$y7qZ(gnEF@!2(Op(%Xg?I~-Fo#*m%Pp{2g|Hs13Q6FyB(aQ zQrA|ZjcNdO5D|M2VN5X8m@(0wCga#iBv3lFZqNIa?Vnuj*K0M5OVjxxR5=dQd{8eD zKpewGy&v|*3Q;J)V|>~vm4Yt7aad!RQ=+5C>~qv>wn^Q{3K!Rqy@v=84&lT}FVj=} z9c&-X+T8TY<)W(QweMIq1O0S(e{%|^GgVJPgg$}sHMi9JYU5Al5%@fHY_jzUWq|h0 z_#`KObKH@idU#_ik{km_uVJ5yg;kP7m;GEM_g$|Ichu!}Zu>LBX^U z^`fA2?lS~YokyITRl0zMVddZfCu2RUdtD9ml<1?^j4v`USaE>gekDW#Af1cccM8Uw6tI8iU{0-JKi}g{#UbsRk@56?z;h z+EBVANNS`@H`M?)MKZU9GHuY=B~j_ED&jOE;nj-S%D=QhUWASA;g(py_?^;Z4abwGgAZ^qP$}MxMqiHu zPD&PN_j#C8DZK)Ziu!dc}&+!rmy z4Xk0qWwYs^VxvQ0({y?_pv*A&c+cOpJorIScx*#_HP?Y{5gGqB@6$Nu= zz{+;*Te8~yRoAXGY|=K(ED26c^-QW+z&;->j17j%fXlrr>=W&@@sH28? zhQqC7U_U$hzi%p`mioh3yF^`(D*#v`w9z;0Nd{JaO?RvjI937VGB9Wg_`X)%ED1OX zqYI~wo=kDMwmEc+nRx9nAPXEobJaV(Sm&TFCD+!0HCTqoZB=lh@ZA7-3Fp~_kHO#&Cxu%H3@q&j7EeO_FVrNz>1s+tNF_D=ijV4#ZUV$; zqA#gqU7I@>Z1As(_CJp6iqEd-z=s&AnN{kX4s`!&l-6vi$Q;%o@LIl=#^sG#a`Rfw zjoap8_4Rlx9_YS-*A$d4t=y(YYxBL?ScVz0+ri*FpY z9P7L?hcm|-Of_FMt~q=m))B`%V!Y>&<=rBpn?|h25Gw)*B#@|fAnmMnB>sxtvv{37 zDoT%At{lMoppWd~|q^HQU2lgBGfP!hY27f&esZ_*>h)hxA%u^Dr(Zg2{T_= z=4f z{rp(!avxSLS9>GI^U_M*gL3tbe^O`jG?qiO{<*1sx8ZbgQ-Y_xt)Tudr08~MdHa{E z+Y-?oXXcLAqWpDVn}CrGi8##UMY@w}I*t$AoXPMmEupasatQXLyR;@t^cD`H6NCpb z$+4+YecAfKHTO;CYXHmlKE;ZvwU#;mT+m^ZRl2;dD0eqEjO}ebrVWwm-Qup#*N2``FLKsbM$b9~Nn>WJnc}<8MU;kJm*M8nE zm$C0OoSso<2E*nyGw#q7P}zyF-AqJ^E;psvBf_k%RG3{H>6eWrfSJng!*1VRxOD+> z8gKKc+LHF?xno@k<3E|=`DD*Ox{)_6Ym0R-mto+j5R)P>0!XeGf8Ph_u?kk&*NPu< zLfO^8&V2aNiSvr()~C&$=#Q8>=1kaZglMKCx&spti{hvQDpShFYNv0T=<0FJbW&V? zCu=0a+9G(O)No&pLm3z z6krc@dGnI*Yo>m5>fY9KeOSuFcZOq3c8Oiubvedf`99V9sdBw0e6Oe zeZSFfF7Q;fZfI5aey3$vE^1qXT--~Pqinb1*yD-Vy_?MN@!{n7jPLqVZiW4KLVJb> zyX}lt2QsSS^kiEZH&1vkDk>EuV;O?|3<^!NwD`r+PBe0%Z!3OZ9O2E41SOn~abPh0 zEoDBb?M+{XoFm5dncbTMHSP}f{rD3X(v4TeT^bmXmst%PLjp4r%@P$KniZ&lE!XxD z^8%50mk+Ac1V0%Y$G@hru>oes^^CZb34z{KGzp>22c%M6n(w&$Sk5zjoo4$)nX~#K-o~emKjB{#dUUqUPY#QS6!a@r|?@>_Dgo!-*+uM=4?;%!juTG z$LJ!RCZMH2``oXJhd++p$X3s6aJ|;Se>wVECH1co>?XQfC}&M?JBZNj-+g0p`3bR@ zb3>z0=d4A@nT*$law62-sF!V)7M#PrORp?9Ya%YL+4s9yzv5WRW3rKJPZIS{KY6dS z<q&7-Yp?0;=AIYvI=F<%K{~ zr?2ryP+yIGqYWS}z&J%YKmTwrwg$NHqsv@2uERXkiV6yOC3oz)#!z+x2h!r*tQrPI z1^WO(0JacDU9dnz|JQ^O2N%c+P?>8O9vvOG_Rrv*J&5gI`BQt8D@Okp7(8`o}nxbunlJOPI~YR1zh2o82r0u+R@At((qCeUe#_=LOXf`fb{y9NFiIg_gQ z*Ue=FNEZNSrj+_V8UdNfsF)i@SF8Z8PEmD!u2->RLZ911iKEXNc{{M2b*Eg)mqQj)7y*eDFaIgSBP*AYl*hpC}HuYR)YQKHe8D;$<)MHmby#xY1t)N7h|4MxR_gg`6x zCc;b0zuRe`?9>{<8AE=pKqHd%vLR`lkOp#10K^2b_md+r>V?epv-@tw>E;qUWfbtP zs{&UAmL6M9L2U_NgfX`!Wm8;!MisjdnRkk)nxqldr{M<{c(yrT$V76i1A))-0^JcE z><~+C!npgR@TGJBAaDC2dgL5(tl)Dmfr#?wR6HE+aVjmk5IKZ zWwg&I3Lj6V>gff9|3@_kKuzLnt_5@NGy-GjH7FY(lDJS!pXe}Uu zpD{Y2An&F5c5Q-b`7m{#%@+qfCK9;S3PU1TEGm|Nz75Lux}Z|bb#i9I6HA)FCj?qQ zj4j%J{uCRCNjNe;hm^Mfy6h7C)Es$c1r;mh$lIJ1>F7QD2pK~TpLyxpUauq!DV>f$ z{?MC*q3i#P#-UJ57UZm6lfre^s(^|pdc9Fh-(@Icy{Cl8r0I z3z7v1TD^6EoeGZ+H!6@T<-~xJfP(rac9|^Kue}YkGD4_T?i@BfpsDU zap>m=d24hNH5~z#k5__*05DNp&tc%OY~l9^CY?v2kcG?3R9I|9;f*!R{Ap03n6)=7*m4 zk(YtI{1cOEw!>cMBI$PUVTu%g#my_W)9eZJoW5d?x4(~N>6MTW-_&m22Z!R)mgtz; z_88_}vT$1`bmcGgvGLvi1eLE4yd#JV7v4$qUpl(M>0@8V_UZ?FY(muUOa11V8_7p3 z@|1ISj$E}AH|>aVbQ0prem>+h#*|18k7bY9UMfqMvH0nO&xuddu^K-cej4yLplF!hvl^6dessc6Jgo{W=3by4Oxz-Sm@okKtj>kLuuQ zTgUI*wevN&mUM{r96P0;YItm(6{R-V_$amRLMKS-&WF?U>e8zJkZsnpYT z2|2Iv_c@kTS*$EiX(-S-Dt?7ryPdq+3Gz*2 zPOe;9D^*75QzqZu{oaH(&3Dxikn%-Jb|)-je7|NQPQ3Bko$0gN_f?bCd3~E2)8}s^ zZJRt(hm^#DZ=~PR^aIFyHeDBBcD%D?X3q9LYmQM&Th-ZO(VmAp8=2}izNIUpHXMI` zw@*yMi=epxtH50?x<(&2$;2>kWIkxR95O~lVh`D^H^%JZ^}JTs?bO5c?%33BK2+R0ceJSc%vqCg zuY)tI0YX~F2UB0`S^e~C(FM*d$U4vN)f*mm z`7lz2aS#Q6XkQuxFz4qnPNuc4JmSceReG+AvkopU?8SzB_{IIx(iVkJJ~%wQUR}M5 zkMI=Bz6&<#<;w3DRcF>k=-fHT98SAxmw9lpV%bo8@!LNLE&3h(03ydlxP(i%j(jIn zx$eID30JfROscE2E*Ki}8(!=S8*qElO?u{A+-7Kf`RX<)Q$0}F`I=+0@!-T0<8v}S zWll%F$0(k(bN{}oku!`z5XD$8t*vg*!7%vU-fxHK{V5sQzn`vT^xEQq)H9*p=S3br z@0?cK*=#^VP%ZtNl+U&~McMAA2S&6N&zbsat7rv~Xnq5~*x)ydU>T*a^Rf+7XZ4(B zP+oj+znbBrvsF7f;n~f}d9pc~X9!YZDKpe_PXeAA&&|i0#u(HGMEFIMIXb%|P&i$2 zrsnLWsLyguoXwMn5w)F?lysKMhxYRKbDgwncVmq*7D0rBX1V$9WO?cKn4VS`ZNYbgrp!DN&8Q91 z-7$d;f)nQ)&+kV?UN4_)9ow3Vb{eR2mL|?W(B*&I@%viei|9z{X8@we!1u4X`qW21 zV-M8ah~`8r&m55<9o#Mb^7i>iPRsvXHkA^m1ZIBkTNnBqqoowXa2txxPqA~|N2sG| z5s(Huc*p&$w+fHI;IsQ$W><6!rrmbtB@!%{V=21<>Z3z@+mC*d7Ulw*{)zrzDIR@B z_v;7r=!!Xpr}aV*qd=kvf49otLeJ6gV=^Ia&@IMTW&BX?I~M%c+4lRTHgrG+?)2R_ z=K5<>`BeY6Yke-wIAjE|OhChjP$WdBw>t3)B7u>|p&m#HR15nDJkIAW@d+$W1!tI*8=LXAwLu5giW zEif$D+XvA1&Hva5EO=3QH-Unb*2`ZS*u4cPhZ}>-Ml!u*F&e|x!>av*C_n==r;dut z1miHZTk=cFH#68fzEn{8Rog1dj$2&^Nz}CdDqZz%O&)xcckK)Z_BheM=SZD)Oi+g_!;7Wgw{Pj- z-wOwz`C(=zaHJAASk=-beY+H}vw#f6eT{h@^UnCCd(^j=kr;~hw5J!Qe7ghNW*(+s z)t>`^1icK#3JI5n%-*BaDQV-CX>VDO*Wi(4&72DO#xJ2X1^5~zQy6taVWeF;p6}>` zl_QsyF!aOJDggkDFR|24P3K>sxn!;%lcn@d1 z@f3=W5R&K1m1O{(v+xyl)6*39BE;~_DqdlT<=^PZk>1*@ZWM3S{};1mwHZHV-0j=! zFn_aBy4Mt(Zx=uDxl;9veRO~&z|)-P*~ksHWR`Tm;k~#pL}zWEXW0Poiv-1~(z_i= zjVJfOJ>d@(z7U<}*;+p#(T2S=VnQZNb=&=7hyo1!tIx&w2wM%g>SoQ&u-hF~t_C*M z2eY3_b*t!bie&#-D}VKq?ImP+rn6fh_Ku2s83pd0(Ey5N4w96=IumGNfc+Y7-yN<( z6z5ttaIeo$TJR{jA3&!UdE^_V1#=*tmF37#YKd_wxdb^6L1qNq181b(vc?eQ?rUId z7@ImZu#FFewFUq}woL`gI;{H2R<&DH80Bz_{3pNo{q+fqqh(#;gs6JFW7}#aAU;xK zD|}F2%&08%)h2FM3eE6&m#5!-0`TXm{uOco_p?0JL35e~C65dsT044v@-V`Rp8oDw zN3C=V!-It*)%kMBi< z=rUEp##Nt6Lcv1F^5X0a(`;m_J7yHwH90UhD`5>@XM(! zT4xwz)s^980i4*8>Gd6XQkee3ziyu?tFE5FDXbAGZ$OBnpgAmy4!C!H32zYTX_FVx zm;<}a-)%*n&rb$^hAD{nn#k7X--&MUrEp%5OzyYl3pJxpZa$Nx=9~QcK$fgh#b)6+ zY==1ZSl;FOyeDb07X@VhJA2jfR6@-{VSdCIiOLpyVTq;ILIyT4&qpH9c(=n zOMAI)Bb3G_$_E^QClRywK){9qIZ@cIYnvvSK-C{|efWh7i7rxiCjbp6F6-O|SWZhK&}Z~pFk3_!1L#$yZ)mP9@~ zyJi97td-j1LW^TxsL%|c`^COxRb~JyukkhxfCC+Qvj_P_S5dM(*gg-T=`1HYw3Uza z=w)g2kNz(GyGm#KIox8aOu#iA`+Ac*7Jt;l(l_sYon6xM7HXmhB+JLorf|)?3VFwB z3Y~W%5Xj?>`Q|FW4dJH@pc;}m?mc|2k_X4U2t4L zkYP>|GLX)CBe&SHd~I-{?WFpXj*|^-g!YRWCZ74OJ%J^5T@?;orD>BFJZL(wi zVxE1dx;$+n%<)XQBI}9o&v*Fo%Fr*``{eWDisd%uEbJ*N3ZswAqKI70 z0()K{dA}vC>yPmLyb5!d>j&P<0H{vIF8Zy(Qt7~<=M6{pI0j59IqAI^J8`r=kM6vt ztSrT}va(Mxv23*T?ac?I92ECEvpM;y|B9-Ry^!2bwnZM`6>YL`wrJ6TPv5G&7+_hW zM=knaoOu2sAeYKj{17B#!E)oISX*E`PyI#AQAT-LFBlp>-eLTcj(TWbajmJm@?3;7 zJR*rDuYgpI;BPM-iC7H5D-S|bDt7U{NZW^Q{=~@2syO|i+_DBoAhIcrWl)&mcC>89 zjJ{Qkia!^Aqm0;`$@Yk2`%hgjBQMLIL0Z3M|2Wf(#i$2II}a`;TRoH0{uLoWJXhFz z;dHyy!q6_ev%rPxFTc7aDD*)YRMrw5pjBKhU;7au>Pzc!R;dZ%3@(((=Cz+yC+TX<5 zL*F+ea$G2E7sHN5ChSjVxlTDR_?2AwsDAV+_t?L;Lp!)nZ<=%XQaG-Rv?Mzg>G-PO z5dk}a+)|GtOSk%h*UnR<_o!lV2vjPd-HD`vx;MSyn_t_y11?(@!M<-<6go?fT(ZbN z=4API)8O7}`421KxQFnz`f21?(XBBi>_=ofak@x9%l~vG3FGcQKNY;cJYPPN zs+g;C4o3QqOI3ctK3yfF}TtHp-efwduSbgQ|66VVD*rXL< zG^+(0-`7%acY}GiuEtv4J_GjK0642cqzH=gLPgKB^_~@?h3FGw=-9PFgE&ynAtTK| zKXL01oEK9m1vK~4w&93}a<^e|H$D!vxE|(Y9{cfdFXH1)_l)Li`%k(=|M&ZN4$8O6r`0%^k5-?u)``5g^C8? zCXZ9j=_Ky%VHuRNyj%KIldy5;)u6Wc@5Xbj5jO}nnD5O`vsErc6mI2GvxAy<*KAz_ z=C1YLW;l*Dd^F$3z`lL?A?sQ-OU>gP&gCm1maC z``5aHazfrIPv_bLoyU8(+FR9ao~V!`dJV=?TP5p>x*kcCLS0>WxvT51+uxn$8lqy3m$eCo zDP06>DZcq6@7@4l7PV(zCBZx5?u86p$vOygaa_EuiASL-%`bQ5{U% zT_JeAfM6IUs+-wq`_YDiK$!xF#D>1(y74+^dIEwvdt#%4V*MyE;!0zXj~^bl;k!k` zBXjTZ1HqF!KJY^nARGJ|1*fAK=!Si?2_Z%*c#c_A$VLt;Wf%D5l}*L{^aCpMoxLqE zWES-J9w}co8?9AXQC{M|^^Klx5eAW`d!;4gZfV$BT0>ls-NJDu=}xJ7 zY?QT~r{D2In%S{~5$JD>Vc#Ix10!;tf8cDq)jS=-O4;BboDPu^mHzY1aVpEH(i7O} zd31GnV!qYZCk37`=D{r=D;*OyGqzw+gGxjk*B15H@oOk)6 zqy~Odr&Ex*q7IDSNkK;|BC!#;gWE9z-;v#BgCCN&C6W+G+b^h~L>Wguj8K#!MrAlW zdyu$OXC@Wi^u&th)q^cf6n_Pf6gpZ%E@`Eq&#`N6whlTusvedcL>YoqL$c6(Ryr_b zz-lcxqRpHiveGhDO!kH$8#)?FE|5ez>qNFE#F9;>)PTe(EG9O5jWTEY{+sYJ+ccR2 zUG5!7oPbPmObC8X{dnJGOZFKMv9_rTnxz%nW=6en{#je1J3B6w*O+KVz7+c3&z_pl zJ(j$3j_9+&vD2Lx&6xaOb(;`Y7R-lk>e8yYF)s58$`;+;oj~+s8E;- z@MzYH-=dC*;!-J`5P_qNko4%b@g2DITHQVV*JptMAvx`2#fT0`c*bvjJcTW|JWc|n zu~KU>zq0@t8T5dM5!Hct0|rEP9ZUtJ{SvdZM|hcY zX|0#t>k+ok)RC(ed5?~q!@tQ|&d&U@>bxe}-WkBKMdhW=65>(Pzc5-80tfDvNZF7;Zh8Y@ z3(v{Fxdc&&k=*ATzp=$L44Ia;Af>CGdu!fWwAiLn>D8{Q+$YbZGzGvtpHLFc3kXqo01qvD_Wy43{#%6s zR~ivo*pi#WW3jpZ?Bup%bjpkhgX5sb$IEQ&aXp^~C}01C^O9+Qxtbe_@UjrZSic@P z5d@FANHTvX@26ce!9lAs{E`fcx8t5x8Nov^_U(xH`C7B-zZ>`EOMbEuzeG$w?tvTW z=@if~nKQp{8NkD`f2XS6kN2bRmz!rlGf#JtT2P8~=1n7wxuY_NdhbWRYwfUb+9&_P zWnp}xWn#VGeL{t$ZFNd+KS@f1s26H)(McdpBvw$tXLDCe2fg8&9{@edDY)Fkpnc9kU zgA)dF?wo!`w^Il)^|1W)JkS00CQqXrFxCY&!Nb51O^9euq<5rXwOEVRnQL l0M<@^@9ElGhICx*d2W7O?$O|?p?516{%cRx(K0dzRx7Jx_o%6@@to`i0&spa=zs4;J4a>{` z=fIQ^7>z~>g~DJke0+QY0s_Lq!lI(0xLhuu&ld;;B9TZe7E7hl`ucjgT&_?kR4P?h zSC>|+?ds^zc6Esa0;yOm;PbT|9lEYAE{DU3k5|d%@ljEOU0wC2SW^lg`!?0>X6H&0zq4S{a{<0PNf>_=;$!5RVtlAG1k^57YHWW+C&^q zn^>%^uUCmgQZBc{go(q^Nu?w8^-~IkRxEB42vmH&PAu*a22Q*L?qJk`6B|s z7@t4LL7lv-Lp(9U>F8)Pu_6|m3N}^A zX)}e%P0We3+BQ=i3Wb!<=V-MGk%%jon`q9>0He{z zXk?fqH5x&Owv96qulO%|sa)Ej>)?y|DxFHK5Q`KdxlS(alJe#J`oVf}msm6+;t!h0 z;&aEi+zD>LL;z!ofj8ni{wubkt<9u*y-L-l)5$wJ1X8KW1j}Ryole}*A=T;XM@IN6 zm1uBKJT@jW;nQkOaJf3239AWW)Wk&8|KppO@R^#TPEDEc;f+R`AW)d>V6utHBPJzH_Th3(>J9!^y@`N;5tD!n#sq^gMWs&t zzlQNq6H?KLT&$~?no6x#h;>{JU%(g1`C1dxI%%6qt{9Q4000_|hVdN@nRExUOk41O zXM%+{9SVX|tXkP!iMRGm?^QQntDzXPNq32w>F5bQ6{>eNu9j7N&sy&vs8ck=zOJU3R`aAG!mO&GWSxDcQ6C%ny^X1 zlt7j71gv{;#nFC5l~`{^8B(4|_FB9(r1+A}ujX!v2V8BZ%OLZ)rSDq)dDrMlk{xrL zk>Fe_SrlJO%X8wf&n~`o&EFRlmbbV4RbNdsig9gew3%g)`2ux8Xk_ILo9q-StFmvk zgW07kc$w0d58<2Eg*4DRUhDVlaGUsdc@V|kKd*BLR98zNbe`Y;Oc}hW{vE6IMrCvP zoWd_-3k8W+%QpV}mXUp>CEu|~?0}}`E%0vcE=G}qO43*PfG z8y8s6)emDb7^Y~t^C>;{&7_H{US6)}5Tfz3<(A3_?s<_>coc6>vzs7~S1Epf(d+p} z42cJoS$Hx5+BYPn&gZ!D!2w`Lijfe#%JojU;m2-bt; zRw?QzDS2Pcv+atGn^n+-@~~wn==!wv&bJpY9-*FZo?2}`tulDpV~W;{MPIgI-aT?Z z=twt~?t61(t`CWRtyZ^%iAc;ZF%hcetbH={d@Kb4Cr^d5AW4XEET^{W*rS6)EJeL@ zm85P;NwoDgsH&_fEY^;N*$o)Gv~0!=Nd4_1-`)|g+y*fbdIe_Y^>LO`sPlE8<)nY> z0eDiMo`eo+o@F=lz3MFpFV^hqytNl(#)T-@-Af|^=`3i!nZrj_O#o9v*neR0Y2ffO zyc>%SV$Ft8aZ0l03Simv+*bLFG;JFp@cK@N{58v);7{i+BFSlaP%+SBppp%px`dKAj9QG7_~VJzRxIh`j)SKiVyZ)MX-Nz1 z5^}BGx~%a*-O$3tDMcN)Kj&+(*zuU^Zro)AbUE~%S$m56*MD}7t{;1|V*z|8VtVX& zxUwH~&$7Nd(N{FWL6haa5Q<3gVc*ZxLf0hU_Ue(P;cM6|fSpCJAd)G((vx4Gr;87^ z>Jops85piUgeEHf*1#hcG63N<%@E3yi3HPvCM_bz%QhTHM0XxPv#Q1O&nV?7JRNEI zI#v`+K&H?#P}S0xV)hB(I)xQC(; z5*9B^8{)G;Iv}=1@`lBbZLxN&>09zRXI=Q-jw#} zY4j^f;5*tJquk|f>lA6mX^Co=-&hn97>RT2tbyGB_;cRVXg^YYw5!u-ZOn85nKsEv zj8W6<*{kQ+=OQJ?8YPx=<$O=72KJAIwg$`!!@PrWF*4Y?^Te8ipGe#3-)a8dtTO*w z;1pU|;ji67wDU%Y5kg>1*PxTbqaiBm;N{1+m-@bgjpwr{cA5Vxk}m1gv-MWX-(m1~09vUGw2_%J#yqbMI{H zrqUr$LS6UMZ0N?*IdEHS)y&*agc&3QFjF?4GV^Sy zoDr0m7jBO8F1lBREL^JX8Cu}21liBGuAN1^OSEG@sJf%UV@oS+z+AQTR06jI<(Xs7 zlURJ7Jc=?@1xX9;n~#2&PbgiTU|}71DnpAwt8@Pc-sH0@kPT(Bcm!(vz^ zb&w|S-K_->t@AkA^TKiRJe`>XomGQeqWSkqLOSB0+<*5qlaCE>dIKV%5VkKdj^)Kj zb920_^^IQQ*TxF1yxVKfnop}+%i-@>{XRC}RTT6?|@zzRv_e_uiCacCo6 zxi9j7=WPU?z)lQqO6nsJ5?s%HVoVle(`KNH592R%s>o(LS!k@G0=w+QR(-wg+)o3? z`gUidPYy3e|K<6Fy6QbZ)mE0eECSDBS&(_C29OPiV?jF+->I3Mxo@uJfvw@5+Iu7} zIk}(e^5?D^Zo6GRCRm19vSF(^+Rfo={|)Q|Pl$vVHqbj8`1`cW_m;w7ElZ6Bb`6y{u-Y5bK54TMS&

      51%C*oPsg-_|Q9Qd7Zr@joanH-d zTk;_X)@!@PFW-VD;bM>ay)}s~Kl5n6OR)(es>3WzI@X9ka^gx1M2bP+Rj;jR3A_q> z*(iqE)J>#t58lm<#IoPI7o`J~C6i)qJ|rjM325q3!2)V%B|cFI73939ucL!?RmqK5 z5ZO9W^lHOVK5ggm>dI$+$dB`t5LACE(9;U|5~HBGzi@*>=+XU)Gyrq-HIqwuxWTa3 z$(}BU?lCkpyGqDEWwAKyY~*!^NjNG8K;3T=%of?-yS$}q$?ee|R42V_sn2^jy|lYO zBa3)Q3clh79R2fo+1Fj=*k?Aax6*&3Iow&j6f@nhKaUM+5?8@PVK0N)3BzNdhF;$% z|4GLEesG$knf^%#6ejQ#`6bmvxz83O@vH8q+s&YeT@5*vdCF}gwMlS?Qj0xzM)G5Y z0nId2;DcC|j*ktPzXmsIf|phX#5bP_X;|&GPDvh^EX&YfX3D|b=kbS+&e(NWyh{QN zv%{{RpO^gzi=7G-QXKOns_yP)3mGaE^Ej_{|8q4E7Sjc|+BiOqfn*KdJyZlW_GOCr5pbbLYIzwxOG-#q7$o znj5KADJh$q0wOHIEF*%+R730O5RQ&r99>b)L%p-HLg3-%;HI1jPnMVM6#wvwqpacd?P6s22=P3SXzO1J!(Mdw$u-C!3~-FW zGXHkk`CMAsLe3LQ&#zH{J?T&MLPHd%r$aNY=gbMH0Ca$Aj<%{i%YMy3o&73k<`?(% zr(G+A7?Zrb6wHy%Ux@t~>!WxBJ(-6pA#ro@_1fM2Xur)T@wm75*YVi#A zLIVQkbjsgnLQK}CkzHFndY7cjQhhX-C{fOMyDwT6a3)w@!z$R0tV9W8hjxi?GEg@= zn?Bdp?u{)^fN{9hbJp+Pzq``;(`!2gi%>9WeVZQ;_GZPC4%#y-|6U`b;(8j*RsBnN zWCVuk5@s3t;JZbe7jB=1U{48!lo98d(5`Dd8VnVFr$sCWo$dz}72DD&@IQEWFQr{s zA*4jH{%o9sh9F6FD#ZLFXB>O+@JuT?_|Y?iM+X;5mp?&s{%uShzzEm#XBBGqRwnO2 zL)IIzKnjA1V57+D4GU4Cy>6Dx(Ww<~V4%2GUY6FG=^aABK0-BGx`(En&*C28(cEw_ z6HUy)ETjiriKTQ1=f(C%plnv4H7m-4J!&L7u#-SC6o7vi(9xgu$}Iwl3B_i@?aioE zI_AtOKSw4oX9Zc)P49tbqdKz?HwP!2eGI=?Y&-+G0+f#$8bYHoS>X9K-}WydGfQ$x zJ&(V6W8u5dcH`}1-3aM6LJ|eX83ANQX<>P`oO}g{GJhTe?Czvz&^;}zLu+={sY@%RKfVD6jC0`xLvI+r^d;5&K4li3J zwC>XK%c7jbTLI^jf1zxh<6AvvQ)xL~AM(#!A4efD*MsRvC2eu^T8Xok1F*ug-U9GX zO%g$W*6$=B>d)ep(6P97f{|H>r?lr+mJ#(}+c)6#Si-zed;M7alW5e7*mF}-s0g4# zl(F$AUDpHLU$=2}EZpD^i@#-Lt7eE(43m^Qk{m6ql#6v*0<9osI}1#!$&b|J?plkv z=)Hf2o7yLsfzNN!52y*W zM}#H~&VffB)0j`F&0kQ!l+xm_>XjR)=c-oYFhcuAJwC^h5G(;A2sg!>MOKggKc_3^PDIJkFZe>t6$lkHBJll8k0sWJq^?4?n-2 z0_lwpaQWSYMu0L(<9R@LfxL+^{%=vXrw(1SpGc6Zp;qu)Gd-mIZ zxd6%aggPc`?tMZHlT~c6t7C!Bz{2WZb6d@P)@Njx)ly{#bEJfg!|SF>SWCX*=NE#U z%md=Dc6Azj84tXpcR!y@@L?}WJPDl+NQ@C;e$%5P45)b;R49V7VJs7B!sfB3fX}YxBg@ws4(&lAjlGPX?1ztlT zH1Td|pX2tjt_E^I19H(`hU?!=*uvv_J;E^6;6pd43lxT9aULf92?(&&z%Cldjd?3T zhT_R!72`w!8*ffHF3DO5+g_1-zrZo8FYJxJ0!C4VIJh{{3}pZ(R7g z&oGGxoO!S`hRSM$d(OJhSSUOlrphX4GVVW_it_;|5kRAc1DnsyfQd6UO(B0JpishV zY6#Wx2;<2E6gDHBU`=4Vg!O>9+r>@)=qyT0;$OfyIk1bq%YPKYGPk~lRwfnr3M^-S zgmh%));*buPnnMPrN6Hli`yIE^{<+0C4rho5(DE@JC-* z7HsOey(VLmN_uBXpbYx&Um*0$23m$u=xNP@Xp}`ZbQluCyP{A9!tT0Tzdv1Ob?7OE zqR$QyV$m84du2EIK6Rjn`QoBa$q8#bK*c?*10FZYn_@(U^2h|Dy{TbN*EB4 zILfGHR$hp+BM+J_+w3uC?lj4B{_{pp$e-u8(e>{ox8m;h+dpoWxQsY8Py>NGqknzI z-4EUVAZ=HqsqO7f>K*kt?bJY_xc#flNSc#oHO|PZ9`5v8ih84L>2tBruy6qS)btyr zl$Nt6E+y^Q-k58BmT_!jSA-R-&GRx?2T-F8aFLA5^-36vyoXIYcA;(8=CY+bdm|iK z$AULLvv8HkX$hFzx~53**esW#hP?b-{e=Lh7G>x`R0a(*v;{(h==LK)v{F1B$`fedgO8NJjd$&bI0|1KJuENM!+E!@vMPh9}LYuAMzp+ z>#Birco0G3ftLZH4A@d`eJI*CSOnrPoBgRYYo`6|)TO+A zY3+$rCP=@y%r4~Q-#|lGbUvQZ?@-#Emwnr&A^qe z&fO>(nxuJWL?8#D0X03;8H;kHCpzP;Atm%1f^kxkSC#CG3HNJRUb1!FM zo@F|7BK#fFWxs!3ne2(c%32JY6@b>1B~Pzd9ETdF!<%cN`D_qlH27R<)Sb!qdHD6f z=vA5v3wd!idS3O4{siukOsofvf=NM+f%13NCsbvBl5leu06M&Z(K$e0)OWP z*;Wf!whc-vgy6bmeTmW?H6#nVYZAsWyWsXCm54dl>cnlEH zYLe_Q$#>?{XT$K1jcM=CfPiG54EBAhY%LA}GApu{x%p$cOd1G;%%|iB-}08lJFv;? z|FUv?O_ZG_dWgR+J5BSa13K$)v*ka0Gv%2$?BI;>t2>Fn=c)U!jXm%!Tmuixkv#hY z6wh2#b3jcioJEN`Sc($n@JyH7%li z?6QZcu_XLtw_tTsdPtC+zLaHz0^JCqq2<$O*ZT|2&&}H4xE_7wf?c+hzVAgXuH|_~8iaLjJ^u*~z3{^Xt_R^l#oWZ+c{f1ZVW*rRzRjwSLM zsY5qX9oHNs8Y+l*dy-Wv(LaJ72gt1jlFqOCpLgfq?i}x_e!OUHJwU@Pi%^5+L-#{l5ZB6Ai_uRmFtXH*1 zp|SU@`>d5O`7q-~gQtHdkcT{Rn5kR}Z+e*Q_-lC5H3Tjyf2g76_JV9Ul1*z*1L zbGk|FkT-mS3Wua6F0#}>*bp`+VaT(QA@SdLgT!&O-XDjU;qhRp7wt$sl5r>yX@;+o zcQ@Xns81uKE7vZIyfAA;T1MS))o!|j-Iw4MgKuZa`pL5h=dBa6JqV{C;F+U(*LRmR zS5j@ahpw9Pypnhns{a62!&l!=ogn`hm+p*jDdOBXE^}O8xzoDdX1Qa~IO)}%fO&VS zHqTTWn~4n=q>|{^TXgpPlHf)b3gx;yhTn)yi-+-R8<2e)?=f?;DmePqyEQH$DWvM# zztkp}w>+F0ndsS6x9{}#0|h=iY?Nh71JnI-5i`c1_@;k$Y<)FsCWOWSC3I9oT}fRp zO!)qE+-~-o)v?eq*I2rQstTuLoG*qd16xK9j5GZyEnA{P7r_&kp%{0z_Q}8RzTPxD zYmlU94_&Ite(BzX1Pf4l0}SPDdKC3rW~@QFJH0ntoA)XGe=e)TvseYrt=z-4w72hS z53L9p9+@7?Tnw1VuD-N^D(iFvn@)ks^Q_%y8-E2K`;xDwJo3uN)6uCK*sgWbD4~*A zD4pdKG=)txLw5YWAglLp_k}hg_YEj4kM*hW9~GfzeMRZ>%+k*ckFGAsXy{+z3l=kZoPB^ z&;`Bd@*e6-+b1ext-b9hEJjw%a&x#hje%_td$XYmH=EvrFoj1ibrveoSR zwB4)wR9({HAKX~r#B|s`^xS?h@A)RzcvBB2Sp&HWBdIp}4yWQOtkd{G&=KE0cJX6$ zgHt+Wqek#UGb>>F%&fi76OR@&xXYe;!)G7t!7w$EVb?O3Zho68VC)pblUdrPsUwRo ko%i{cxlVNGK{|nX{-O=CuDDHb=zT`&Wv7b^SpfXUIo#0laKyfQA8X!npyv4P+7Hf;UySqCSDO~oy z_dfUBbJp2+-#cq1vyxfs%QG{tKJS}{>4#+iS3y=@761YN7!UUVg_4YfG^Lgm%+~p} z<7*o`D|bqHXBa!B4uqWp0zAwC?*QBtArMnOSFeteAo z;~IdBhk{Q9kw7I-H%Fs(CFBf_|AI~*}HW#JZrf%)t?F$pOhJp&^XGdB+} zAHRU0l(dYj98_LGQ%hS%S5MynW@%+@V{2#c{>H=8>#es>=)17@AHpLd5ebP&$sa#` zPWhUhlbe@cP*_x1Rb5kCSKrY1F zi_5Fu*Ee{Nkdcs)!N_QTgA79QdVGQLkWr{0sQ41JUz@Wzu zU_3w!IAQ^X0fc}WNF3$w6VZB0T}&DYC#>^0t9GeO^lPC^g;Dgb=YCMzs)Z^L7^7SD zQQe(-w1Tx)miOwSWVS-80LVfL!UP!q{Rye&d{Mi}$q^c`Jw#u`Vl3_cjBl0q>@^K@ zP;eb_r-Vqu-5&?JvY=|(u^OD}foihoApVy%rRNpAH5w2R; zDVD@S7$qq3sV+lQl^tVfTvKJli$e3;1CTs$zkP4rFx{o`?{6E(LT7hgt0NZUx>VOD z7QkpCaX0D{xSj)7!b9rR6)o7s?cl3w$c}v03CPO!*$0rome#=!BkH)THr4Cm9D6W@N5gvFhSyr*CrB41B zH4$$M0dC;kFp>rdUF)6S&-ot%L7mrb=SdAJ~A9gpew}6^q-{lUtc&OsLzPVp$EPa%G5q&;!tW#Yc=k3 zexn9C2YQTQYKowQ;1pmm<kL(un0WA!h z_t|7#YNN{f3vIqf9mv1)|0Onuc9C;QI=^80{Q)rDX8D{f`2U~-{MQpvvbagqMq4E0 zd!?VLhqKuE)sS^@BW980k(l`6a2Btj?U!4*U=s3z)603jS>iBkW7!wTX=}UgP|LO1 zcgT~bC)YT)KVxwE(B!LBIJy0$_wS`+~{XLWyoJ1=xT?ou1dPd z+c+i*Q~Vm<$jc*KYA&4VD4Ondsbj>sHGOqf@+{xD&vtj0gqSnq9a*T7#qhtSvSf{L z{<5D`cEHMFT*m-F@6QNqMu9{#+vavlI6u#_e7qdWbUR#Tej^)wPr?{}PT ztux3BxoPN3I@=Y#YsUA>+)F*~GT5EOt3NI1w;@DmdkKnPxjZ+=2S?7Re`Oy*oWA>S zw$HXkwB6YoIhV-I@jhcp%UsB)ms1JdR8Q!V%omeIt+;d|{c?VNcHz7o)I~RCPcSABzRtJJ)4i!O)%?J3#h^l%1>YSRs>| z;!62dW&5G!?>&5ngBMU-^g7Ec{$)*5OwQ!Zr{C^EE2c8{pkXKPya;~Y=jr3ZC|K~i z@^@4=J0~-}*(UNB=;eif_)XC^VPRv46eEgN3_eJDFud!T)xrn0(Y_hl($Ak(mH4@% zsPZnTdvAbc7YTKCCA?cR?d65BP7qISotN1WQG+!d-`C}f?xEVVsXv)2g4C%7#n|id zIf$lJ2Ys+CF8Yu#hXDUkC(|Hj4T7|StcMogDPGTqVE7LU8XCD?s7qT9;3-g`+>C)M zh*#f7igN^66HT*88HG4ad(tLY-~BR#p|I44c&qvPCMX!lhdzy2ug-oa2^wl~y(^Hf zrsdIltuX^`Aa|9vDf`O$RPq9+$Acf7#Yu4Urf94DurK~?tXedAr-1vI&zrjn$xqiQ zJlq3*3kvwF{A-$zegtfW&9zt^`@M{Z#%R7RoBnOv1v}GBq5?W4t_0c_Lacv=5#Y{s z#|DPUMyn?L9oHmEdRt^dAh8TWd>4DalZWQ99RG>Bd#F1wm;NIQb{+#<;Dmc|_}gjz zYY$>AYqpfvVtP*cyKPb_>I4-hSR#k&hP-4 z!wZHZ1Bsw~FAX&NErdoYstKgp1nT?^vm3JQ6TpKlT&zXUDR=tC+moxrp*iFv4zh$s z(oGS=$mZB#zKb~L7-$k9!Isr47(^@RQgDm@W*hUB2f>txzJbz11}j*L^Lg1aK3Y?Q z^4#IGSN5ApNImScr3UC4u7@+&gg?wG;f`CE_$|4eFlnO!jU0o_((=vuRTdt7N}%5w z!;41*F*aGGb!rWx3kVM4keOM%ax#J+i26Z+PB(!Iro6Zk_a=R-BvS!=4uS41(cfa} z_Pv$7j^trEX6EIx5?F3npSmbaP4js|W4UK|b(uSgpk`{zhuuO+qOX$qsxnJSsOch>P>$-REzw6kS#GTYT zImD1aBS$#OoT0!(b5_>vTdYZ&3DaOu%+jGAL3GL@dx^#7@t3kq!2e(;ci#HSyxv&b z=sZ{q9Xl>b*)`y1mi>prdfP5Mr8pAqY%k6@ZmV>whLj@CGt|AL03yE%d2b$d-;lYZ zxF2&T$G6s_@D|~Sl|YI!Jn<*dig6+FJlp`f8s+fJnMlhrc?f)Vq(8JWJis$(FK2J2 z$*fQ>tD}H*ew_R5@L+w@0aJC5ewdbYG0UFCPkyCr9_jl=(pk0 zP4xZ=2Sa`tu$AGUw_Q`uhE`M{9j_fp!h86nP3-8+ppceZt@Z_@F^A!TNR-n{#}BO2 zb7xnyu#?S3owi|k58cowc#A=IKVkX|F|jbt*#I}lseZ8!-t-&+nf4*wEG=8}wKYvy zBjj!+<85nS}Q`Wk2zT&_sTFuREnzD1vuI4Bt5Y!np5HH}nt40w?aF?y_)TYdji!zwU8%Nw zBwL^GFU2Ohz_~`7e*mWF?`4Z9@Cl|*PWek^`3TX~nCv+^gfLfOgztHNOPzngI>$j} zr;epK>k=y{xTUM<-S~I(5E~=zATcgu`!?3qZx_VIXfF z+K`{2AvKIo=RLD1e^Sw@l~6|$Yx-^5LG*3uV1oTZUTv6PWsAiD^Q{C+kdMuj@Dx{4 z9Z?_F;pz9(^JB;%e7tc;3lubA0QydTTY9$RZ6N7$X0DWT;*fl>X|& z$49l|s#~88gF4lt!9}+_9B0kqt^2t>d+Fw_;zJRp!f)D%y9LOHR`e7-%=5n(+|PQm z^9qK~qBA?U3=)N%lHvzeYQn4XT;H2aS$ zC9eB>dgLI!*u(WWu4|mZ>b%*o9%j1S!GogUavW80#>;psgU+Nx6l%RZk0&%CP!dX? zQ?9WZ8v%DmRrNhG=WGzP=Qiuu{k$YK@r{y`egbt|7Iu)$FlcES$GxqvI=6x*Dug#_ zD}*@1=Tt;+LO-|QlBr)I8#Vw?-nJfLw=7K&mGD}|j*)*aObVFGz&J$*w=S;H*TOs4 z2A)1uSb##sJkBzkCwy)v<9)zB=`~FRF3+P;G{k5$>9R&VD;fWC;4Jojc3y!O?GL~? zfi_MA#=bX+iGu_DCt^{bA3FU9g&uh?caaYYeYuW_YpWM4)nI<+WNOda@kKb`CG2Xm zYb5aIT+hom>PeP3Dp^$k{}(EEa)uA9ir&AV9M4#B2JDm#D04ks?^#Gr=ypURWAEN* z`qHGlUZfhEm3~UA)D2VaNQ|$G6TGJk;7L-hCKCEM;|#)6qD3NmT9Us$-*Cq@*^v9D zWMJY@L|iU*&?$0DfEX6NoQCsd6%ljbALJMvoDOr_LlD)**L&tNo`%f7>uNUopcFQX zyTu^V-sOz5vREBeX~ou+Tk}0Q#RF3J@s3qR5BmYoO!z(O)--I?yWvKAruJ2c(ywJC z^W*Uqb@*PsMp8n<+l8IYndwi_k?*#8``%o1V90Zq+0R3ti3z%I)I+84p|oL2mp#a9 z!r1wQV|LY+=LEiSM5#VuZ3}}VX(v06%5+uew%tSh6JuRB%;g2reo^pGa6!ig=+W< z>vg0}`0h%`_x11J{^xdC5xPsX?2N_ zc+8=8xs(%F75F>AFLANQgFKml`YhxxSPeO3rW7}uf#-Au86DEA-_=9Q7NO*Bmb02^ z(TrPp5UFkVL8jV6nf%yP(WUXgi(<^OkqYj~ykHCMkM4257m^t~1#PBI%1k`puti8$ zimdiyMwqBw^MgIzGY1Rh>pa2qSff3yFX|A`ivcG2`~uv;mrM(EYH)0HBN+eX-I*?f z*(rT2XFF&3X)pL=`!&#g2bbH>EHVTc3-BXHlZD_=-fC!gB8!Y<5SxGMHd_c%75&_` zV!%{qeM$O)^2KxrW{CGJ+BQE$nDvEMJ+Itlsx95=(KD@iQ5_@qIGoeRcq&}8aXeA+ zvQ*?p(Lzty;Bc=Br~8if{#s3M&HL+1T5@gLygJ8>jI{6+~= zu@Wi0YE={AJ-i=5IV{9hJ&s#Jf`K2l44HCD(3|XDGaJP9^5Gjk8AJnT_Er>3Offco zE+*S<@~oBnQU_KaGy#%n5}`ot0|nFeE_AmKi;*|KkmA1$JiPcJVY4e(rIUe(w$}A`N&5UAT7o}02E#K4G)02et&)1t8n;% z&+!8=rn;kiE@0I}KdSU(^LnHzfdpM^?PB#?1>p6_CjHG#)_G< zzEMyIRLC&f?3_C}HCkHsZTiZ*XVw{^WyWnR#Se6HA4?thkQPrt_waJ%S6wckdPIyQQ{@^sIT)EIHsH&cW9@eN<>OP2Y-;sj6wSrH%LO#XIf?4-j^+2ruo zp^!Wlte*Lm54+#TA6L6VlRYfYVxHnq*vAD{UZV*$<{MoV!+*TitgB|(3PV1e&Vm1o z{OqXlN=N1|773Xz^JGKpkNfKl6|qMze%7pOSYQ7AEk5H6Du=#`Dsag&z7Rc`n~r_& zFsI6CqO!_0M*Z%P?~A30g7aMo0LFtqk}=A==7ZNI>VmmTmrFAWPRi>ril5WtykiyH zvbZh{PbZ7t^0>b4E$RzuDc;lA9LcfMTyGf8Q;3cnA$u)rJo>gp?4tjXj#L+kjOcVw z*gR8D)UT4ZX0)Ly|9*~^_qIdRAKPnk<1N`wjJPjW#AqixG1BWHh?e)g2FWpG{MU(O z6h7+?*)|$Ey4&6zDg^_@LYP9Ddlrr~{2CHgX!9f1UFKLJ9D|60g?Cm@`;c(*ods?t z7;6fK;nIFmOjcGXx*=q5>-6ATn4bO+jMpvN-7{$zxC6hyzrXLv<9d&<{@;(sWnOAOu8LDs(iQ(}& z=9JYJMNM6CN+W)B(LFMF=;51-QtESp`2(j#$rj1&@DGEY@yL-= z&IB%t-QX7Io={s=4053;@p@*U?@cz=a=k#34Sz<76g;ir_~nPR9VD7VNKPT%R>-Hy z>{x5ra>P8#ORd8&8kbnpQ(Leuyf@P>jQPK6))W*1p$(&67C_+Ug*@-}`mbOXk|ps?4(tb?i~S zUiq|lJ|ExLNQ&4>{FD9XZL0MIzT+%<+kQYz+TnU>VJe3Dq1VCzzChB%NQ?T9_iSm= zco`X8rFO(Mo*m{y3J`CnmHSP8GwfmiW0$sj?z~(QV=7x2!D|lG(`-*pj@w)%U&#<` z!PB4Lq%MkLo5;1hoaCXbWncRXdi>j8Y=A>JeUZd(Ci&8~f!pD_Sf>%+Mg zj>N%bB$o8ZF2)=s%j_=xe_DT3zkBVwEz&=eg~Pk^{?r?DJ^eeVi)K0iDb1d{q*uyd z1Wn8ajrcY-wSeJvF(~s#wR=k&x1p@~Ylct+j&Kl^)^9#Kbb#z~p4B*#uTqSDdm@}F za28xI`pX@j&P*quC$+AvryXh)WfoK4^<=44LkzR0mD2~;R6k;EzKj^zc-~E5+09>t zzbJ3voRs<&WpFCI0X>}0rC!a)@;3f@N=|53=n0i8;b(TJI7uz)&|q_5)5XzPv$QGC zEZwv*i>Ptu4hbQQX8(tHAi-!U%a?393Gl(|XtLr*euioKO)0GEQJ&0WqF6Zd0>obk zFXOu2?eSGWM@oACDlK99wBCi%Jpe%uz_w&r=C6q4F5ceCr}?=aoXGEqqBndpn6O-f z{U#F9dwov!peU!UzO7#5ffT2VAgeIir}2GQ1aQ~;z;r5vyS(jl)*U|+$hqp?-;BwR zUBBI_5BI69_wVdC8h*0%J!9s#aB9Qj_1nP0Q9+g1tV|uA3`-q%{?von`1vLEFEcE% zjKG;PeGyNgY}#y#fsrW7ffrzW7-$Yl;+*_G2@;tw^4WuFm#IQRF)0qC-3(FX+%5D8 zCu{v;J%F5hBBSJmWn2y-S*#_FU8%h#U(auO zeNDvw?EtgUk}bQY{?+492wT-p_yKE@XO20hlL62;V1-G4kqcw7qMq-TsJ&e{0B&WQ8-()X-)nI-g?H zBH7>yJ0k)^v`tf!+bG>!GfHHE8_X>oMAdX^{9rkuY7%_>#n0ut>GfFqnDn@2bg=A) z4dt-<+xh_>uW|O7m)Q=qb~M$_h0)-8oYh0Ip&f%UdD~C(2GpZ7L7%?Oafm-g)AY|z zmZxMocXS`OyU3O!>{3U@LyVPkx_M75w`jT35RWXQN1yXe@Ogo{ z;8POziHTfPPOp_@Va9ec*Wf`Zo8yZT8x)5ql~5@rGblX=db+j`0T zPHgPY6oW)%Fz}->#qoG)!Xr-U19SAFZZn;x+xv z$E=>LV0H~2>;Op#Vww=4XxE-UV#s6B998~ru)yvW+ zJVA8RF_9Csn*qTo;!U$Oo0b5t!?x_EyWQHkCwk^dLey`6#3Zf_C9~mQ%iOh3UTuiv z-a$w+*bS0E1(2O-1YRyrIV8pF^2sx}w|=gAQ}Se<3$H!|V=d$H*L>$lO31a&r56ae zD+$pRo`$;U#$h3W?u)N)$rwH$bR2c?(KB}Od%M9{Scm*Wk}i1_8|pq)GRjq=EXCfX z`1)91)u~XP12A&;-{)nSHpCG$Ml!s0`8}6bvVF^CrzGeCLzLk7BNc891H!HT5{(4u zhOt#UXSNk9NA@!+F9b`)q8gsF=Oj5b z-RoR`jKjwE34L6p9rcCG_AiuR{!fO8b0nJyE7Hrw4aLK#U(Xzx$jqosjzTs6$s!J$ z@I7+yc^2}46w+YkV?4|1en&A`_0eM0m9OssAYdsA+^BlAXtHIhnuDnm@LRrFWGKK& z6aRi0a$5L$M{OYq9?3^pUvX*?-yUAM_0r%y+BZqj)-9sYqJ{>QuuVlyi$!ZBGOhwT zJu+MzCD+FsM7~cExpX*6mUx`t&)8j29Y;n-x(^90M{hIr;7W!{;2&+fVr;~GO`gKD zg;g6Z?Di-(w|as5knrj{UWH$E)_k8ysU^{Wuw$bxHjBN?Xq(h7GU-A6NrLhdkk?YL zf7e9@K#?z&b&O_b_St^Pc*$AQtV_`dP2KMd!gf3^B8}Ew>?^?_tfI z9$_hc`q8&Qmuw}tZBU>G2(YLOsZI*#l9|a^mOI6R zESvITpyp}iL<2N=I8vX34k`zIk|}PUdMK{SD#FT+g@SF~^tbu_EVZjvx=HrndAslI z%x(!66Sbsy<9ia;$>HBFHa@P>+nrTzDs)Tanm11R=JN3uJ6Iw^MmHdd9Gah1-#o)|^R4-}Q8v><}%@CbrZL z{pw|yO?2}>ldwwa8kSNh`aFyV{((qygj9wlh4%s2`~1>&k}Nb1)V>Qn8Y9BH$~IT% z*;XW;m(1^1rF1I=!ED`Ogrmf>Sj_QbfIm@oS|D`w(K zJxks1xj#wwrXM9{H7N3->gl{sOJjx*m{=ENK>;7m3(_;zDtGN>chzO`6NdpR`n zSA=HkGX&)@) zciMNR;>YezRK8X__Kw8cbD(c{ki|_iG%NEmWLIDXo@|Cr%w1zn8Yb2X#-bw{Jvzz0 zoWa`3eI`mHc1@d3$CRj-4x}p{kxjSF1fjY?f<$htzbdTB;Nb8&FS%~VPJPqbbsaF` zwd`~MR&^#i>9ya+ZxVK_=d}hFDGzAi$JqZ_SfiKx7ZXZ&5qORIsPT{d{BW4DSOftZ z+{vM!-zA5e-CmZFTMu|?3-VP%N$0v3HT*N8Kk%G@KrNZ`BU96+g)Z?`8PlEYWi`7c z>zIETtsP%B8r!BA8I5o31E5EwHSTx_>+dG@ytT9~$tgm}z1eH;?ow5{xG0L&GVlMC zv0l~L_MI+015#de78knB58$+E#&UZ3L|*AoA#Ub|K2HkJ3Z)($qaO@k4Xwbhuiv;T z&*PVm_&TCXJ%b_ptw7z-C>FbDGOx-7Jxm5TR61g76kl#Bex{M^*4F;?=5{{T(dM{h zCznttvT>rwNXXi0g+#6JHs*WUZ3zFJ{h##Vi0pLB+A|9Q4Gi)|U7AqM$FfGeWr%~* zk0%I)Z&-cR2u`_qfpc&x!)#+3A)6)okH+W@cjiQNaT?+W!10FpF^JAMw7gZgo{%q)kU?KI<`$dcm+YXOro6^Imon`rr zU`J-8ouzdI^YKm~o!KH1-Oa7Xf<|U%xkkd2n*yJjIpj1Wuz9jNZ=tIYix+-bP&9I= zYa!uM-%Y%CUb?>DCnu3*+MX@LY_yRg3E5bwxY$}uNvXhaaGm12eD2xF;*#@T$K9m^ zgUT}m>8fi*zU7h06wNV)T$jTFvet^;4B6LT&>eafP~po^H!R*hw{;I43^;VbF$ok@ z-o_wJiZ}mT0~SbC_W_8rTso%sgRVXLJDziTbFwj<@Ff=%Wd~}WVT;@HeH8Yb8>=So zOgQr}a!`gQzA-UshA92AsnsO(2=?s`wK7qcYuK*I*+SKe##nS{AB-gncE`?rTRVFs@(R1PM+(9(2)z@>NO33-T z=UtI~ivzb2Ey9bkx$3#s0j0Z1E{EOJP~R5kos@(hP}jgWoaCUn@> z=9s!>t9Et6|EYvMZL%d|5jujDr2oS8x?cEXM_<0?I2+n7G85yGZ5$P0!Vmqxs+A0; zVHn@4c}?P5XDP3rqJzt=!$cU0#fh`3n(H>`>b@zf)Px?d)H#F16zdRX0Vua!SRW)& zNL=u!7aYCOuqHau^k?XY(p9>NeP4VxrQs#6n9to9&q7v#oc5(gMfBlgsId*XPFmy1W#aMO*ZwG(((X<^OJe1p^?nx8 zwb-_|J8(U5t5wZZOy#T<-c9n;gCat#Kjr7=B@Jg8>oZw$wE`WQ_c4aoaF#EkLEi_8 zB^!+nHksl?W!J$88E+3ptDBSJ3=79+4Ej%{_?7aO-Q&l&Q>FM=IRDO>{*_|?XHU}~ zTk3(!D5d}yjh1(yMaHAr1vRY3^`%(*P2J!;<~n^5UGt8&O1X*{Sct;eOfTf%owVo& zV9EG)O@O7wl`Yz#0BIMWt@b)@&4G|5AvlAnP)5!*WkgUcfwi}PlTVuNemlko98H$? z2b6EcKeNyBOg~LLocQ{61n&)jk&4cAVX>_Q|7+GD!r&pJ0Kye++EIoPnEo@rqTu*W zAGdjJRs9!ZK2N-nEe?(&A@Bu$qLids&VmanEl?w9D3_0+;xnhqW0#c-9phrZ%$x&% zzTD?JWNadB*G?C~%u;)VSyJ!m+-z~{jSw%6x5%_lVAaiJT60t-gZgVy(K%@$iQB`j z_}{}xKf2$q^me{vaq#a{PLrz-uE*I^mOu@w+7gNWs)d=Vx7PP0nxg}M1hel;dR^$D zTOiH@pkL-}bNm%`0JwIqMu49-7yR}@o*u|=rfs55eeDL_&u`RRZ)a`t*_U*^*4&7r zK8#suD*TpcG^b3|qH-n1L`DV^@$RzUfk&z5y!o~gg~sZo)RgJnPT@P1tKI1!fjRf1 zf{FH(`((m61|tc|!n}?v20bm4kSv;}3dGG*(zzXFqq$S~b5g{%Ai;07)yWk%A1S8Y zJG+Fyw!m{LUBy-DK3Edl5YH4$=>46q1~J-I4mebUl#KL47L^+lR&#FVqQKthS1UHS z!Meq!>D7=}jQ53UOOMh!%BM{vcP#AYk&(K#`g9=qS)y*RFd1yNR2u;r$N@6RKLP9~oFRgq4Dh6C!p6j; zDEY6us5D7ceb{{1x&r6KL-eI}!)P5@CiTCjBAy8nhvF|btgDrAPP7D7VD)$li9#A& z`0w0ho7(~}pH}g6DZ6rB$(e!ff^vJ2E4FJmu%?~6iPTNme<9Hb9fUXK;`GqHRke0Cv1oc9+@WrmQiED)j3onlHUYlX_a zx{?)?$LUwzPOV3I4*+JEToZYe{0g}I^><(`j;0%JFXfxXw|c$G7Q#wQu(FFDHk27P zkl8*_O`kw&C7oCJNS9^^3^$P37i972zxGG{mD3s*!q3f@?rjPCN=)-5GJZA{(u88ClEMI^D^(vLCr|*-@Gein=SRyj~ceo!# zlW}~chl%OsL}FjW_$11|?nnGbBZ#%b18}mQc`+PFW1unr+0h(3srgWRMLq_F>VvQ* z?xePPO%Tm!Pz9L|q{k)l33Ea>YQh;QGZRPe2p2w4GBdWV!}=_@x!**eSwb=)xXQ(6!+_>9$7Wa1|`vF>}R%)uIMp#&IP`q!kd=~!+|Kfwk|is5fJgFqdCyhCh_ zTt?8S?^EKj6IaH;0QbxQI}hAp$XNa;f;iE%oOBlLCN=Zw0mx;t=l0|Y{~tx=zX3&e zcA{)juKHDmCg~IVWtXXtf1ic;c?#V?;VWyUwXZB0i*(JOuLwUqkx&2wh+< zF52~5qa`L`QLlgB#O_IzkHpfOcy*mXxIK^szDkqWbd9e@P0PF%rT#4s#!e#}ujO{$ zu77sAHpRo5<1rEUZ;8`Cq>2!vbE{I@s-%?3vAy>b$MMEjGdj(aK$jy`cHD7G%28(p zO)0MaCL}P~N9X%agt4>q82V!?CUl>)}=1JKC;%)UB&bS2l@Dps<7Fz$U8f4Gm?sAr9D@d8qO{$5&v)J z_BXxzmtTV6C(q)!b}g3WXr$X##)vii0~+=Yjtufr%4?Yx+Fb*PC9OWmPHRDXo+Ql2 z<_ggjxEqZPqy8xRTjzL$Bl>PJUfBQ9-v95O8nX2w0VJ`r#k^}ERwdDRwoU$@e-QZB JPXHcf{ug0^k^KMw literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/pzf511.jpg b/contrib/ntp/html/pic/pzf511.jpg new file mode 100644 index 0000000000000000000000000000000000000000..c470af2f6daa1d2ac840ae6746fd3bffc3d43665 GIT binary patch literal 20370 zcmd42Wl$VZ*EKr026uN0?lM3K?hbf8NultGdpfn%docR-e7sUgvG`Z4-c{AR{jWfPn=7EZz^m+c5xJ%ER2=2LJ3%7kQ4Izd8Hb+E;P;Ee`vou0|ScygMfg5^zO)ioPdGFhNI?^z=20lHwDw+ zx&-HORKWlLI*iaI z6(qEH7)%{1*qOko4VOy551Rz9qUw9=#L6|1*zGvg&-@Xu-m<5BTri%fE22VXHCry6 zE}ZL*(s_g^fo+mNi{|L>1nH_@W1@0gtZg?KOj=*;#E#o!ehJ?0 zx!8@Bk2=>&q*Fh#cH^9T2a@AXl2lu}L}^4N5YK=Kz%-VU+oJA0WR?J4f%t&_jgD#t zlD2H}PLYc&bM9JcjX$4%=PHL|;4Q|ljvAk=t>;@E6OqQQb&f#CNtQ!rGiPMS|W*&aX zap_ZtWgLlZeujt5x}iKfxMy*ouiY6+b3yY4AemDhm?%%os#!|UG;~FwlU18^L`U9K zrDDMgMTrmf_G8&q2?eMnu9(E_mD0tmH#biX#h9}s_PogHOV5WLX(y+KBkItGN=lV{ zmb6Pe;6w!ew4AYsWPsU@#3w`{=%^(uUCtQLt<@wmj}g|^9!ud@>*iwh(Q=gE{21)N zeD>Ty^89EYG@_@-1KJTTrDKBq_J8Wg6gOeax2EXjbYXhh7BQ_A%sQ>KOS&!Tis^Xc zY~7Sj5JSh-00v~Z-e+3d@AKk^{z5CA3L}ewZzfy zs+gEDu&^KE>T}~m#<-2=yFOWkv=m1Z;XX1U?NwT)SN?x^1MrMqq>i?)OJdOfaU^r-lIdKXt5tjW@tY)!UIflCI8C!(qr%O-l>w>)}fMwyjt! zpQT6iS4TTS#T4S=bWmCvbQ`+iVX#>kJsWFWueNMN z5ezA#hvyNK`L9Y6_V%>74XrQ19@E9o%2j`o==O{cm&}iD=)h9g5Z0nR@aKr1*k!E* z=A}M9vua7A{gZ=}5qm>se+%PK=9bQqXL{ALrHQ_9TQ&*;e-XU!vnK(|z8tP^)HCKbS1{a_VTq zrL2Hgm*&z&KR>km{~dJiFFR;7^`$;Asv4rh)PM2yPjNXZ>sOpJndz zEmN{K>;rjBdI7{&U}-Q4cv;A4B8qHy#d@X^`LZ#bj_a4I$dS>#h> zySa5WTfh!GC+8Q!*^myu=Dj>GqOrKYU3ZE5PCL`Ye?`G);>a@b_h^mW2fEW?atF3; zW^fL*d_}%TulF-CQ}Qu6j1-2-Qwf+_Yk!Bt{gx>nP`^GE-;o+v&+@$P7~3=_u6qNl zUNXkaYs@Dw%}r%q86>(W7wZZeMG7_iiSmCs?H(^ia(V1J;)HwU2#VzwIEc+JtgaX~ ziP{Y3e4IGKvmhAz{zWK)Yvw6~S!1lyRYdpOt+>(C5<sJN;-T>Ylzz=P|Q3T%r+Zl=4^VPSqw|80cZ-CP5ouM$Hk|i$sh{dXDTdcJ}>Z6Mo zZIucmjh$peZM2+Xv04tlQz0ToM^fmRf@NWsmHS_3I-Z9l+2NE4r$Frw z6b-_C|NU|ztDL?8l7hBNHvZ>hbZUaSIsgOJkXRHO{jL&_oW=I}WovulLQM?K>C@5h!mzR+=L^iDnrQgOF5Me6V|Fg@1LhyPOs; zq?;MVl|Q-d@GGq~Q5xlxPEaVu2? z#oj{=Z=jNl6ns&nOlTBa8_38wt1^+I&a>^TCVbeU$c#(^fD7%}X%dO5ZgB<;r>?x{ z9d}wJ2obubDLpRkK=8(YYa3C8kpWxo=L~p_oF*+g5qJVDj(uEsaPb-aZ^A&^Izz~c z@BgLojFe^^dg@`%f)Am9;z=>%lnGG5NbbZDmqyXi8RsVbSPR~?V=`ywmu8q>yeP-) zHOQTQlp}$RH9fB)IU?Bd%S%2oQzQJ@d*!}!|Qx$J`8{y5#;V$fAKmLgCi|yg4)-<@1x%bk#XFb@|+v@1{+Z?*DkH8IN4gHD3>#Aoa z){_fz+fs)=RQltG6P>>s#p}o$1<7war-sS|um2C~( zZA!NtA^m)^E5>bMQiw5=RqotkSNu$Bz!1OuVKRH3zv81~)~&DONWZ61e@(%k!9OnP zvGrb)2&?Zt%{K3>_Fb>wOp-5kc3 z)f`$Jq*M%G5PRD0KNgXp{4sZX@71G=im}?WooSaPC7nhJvma~q7jj9aw(|3J0X(+o_#4;U#0&-*U^RwlvE)$TM>%4~+&O z>_#)u)gt_?KEy_1|3H-b=B(ON}(w8j#J9~fE zO!+9>oKbWR^F~ARWjSj&fbUN)!;M!R?i--S^R-g-H8N&6r>Je|;xorTS@WtB;Mof( z?vN%~>V@^GQ)b#1x{P)SNqPgc7CgiKiOZLkiL1Vr#uVKw zIKBZe9o~Pa|4D31T_Z3n(88z#t;6ippXd&`ZiUPPm1xXPfZ`QTY4n)CU8fMq?}at1 zcf;%pIs-BS1eSx$KMswgK+#t$DA@&)(7|8RI3Ylpn`Q0F$2;X?Is<;^@+c3L5J z3O~Zul3OF{Jnt{Hjw4#l3!@ zIz-PBkFJzM3qMBiFTwQEN>y7L-tTK%4v!U9e8gl6=CkE>-{^K!B-6iBb7r(NJ=54f zGx{)oD$;HrPC-A2EqB39_iAnV#ba!jL>j{3krW%H+frVX24!UUFw^RCAp?9e1l6&x zu%-|3e>v}pj+wcvdP#k?``3UEaDO|45 z2(;%HFjA{-EUn&e*+0?b70Hp*IBXl_R=~@oU@M-lt7z4vo!-4JK>+#u{ICuBL)uk{ zolQONictHK-(0RfTSFP{!MkeofwpnYtWW!;*4yPp-B|l>PwZ&i2-U>mCKXi;{0(kM zp$1DLn)LhvIN|3@@ukF_0XV~|xgB4}Ih^g`Qm&0+2|=0MgZft3ulxA_D^tmdYBZ%_ zwj9Z%5!|4s)vI5c0)CZ&D5;}?i_0(jX(#M7v|~IW4JQnop3&%V6pBuyl9T916Z|xl zmEd+>hi2-2Sc*3Q8)=E{zmIma0#0*Y@ubcF(n-wwI(A&8%%rgxSh6#|_s~@p`Ya4Y zrezpp*s7;y53lJfC(E4*)sNeaI>(OEP6w)6eEodyva9i@RP0Lc`cMIydeA9j%it!$ z#VnA*HTx-0eao(hi*KsK^iF0ar_Jhk3hD8si)e3P^wUq{zX_^vvlNysq3#FfhO#-E zf%^y50V**VM<}SUXk9@k58ajB0mkc=>=yo{;67Qv{d}F=M!Jx1jCM9Ne_7t2;wP2C zQfXD^u?-Ct*dG)dYoDd@BENCqH=%~vqiU^nA-n-vf?oSU+GZS`(ogfeq;CNK0;akU zQvGN1*c*9q?psQpKW~7)uXDFaA2OX*y?}G!uykH>y*~72bw$J4)|MZfvBdbYSnAj) zXuCl3p^-qQS_b7zZ^3`dBG_p@GZiPwg3mz9#UvI~4C2d^T^o*0r*v6}z zh!e8HWDS)pLJ$Khr?HBye6EXt^%eEy{dW3}Ls;K|&~j zOu%v^Z_$VAnMEh;AOP?0y=R+LO`TPA=!zJ3s)Z7WU5`b*cP1dIKA|)bE`>usPqOg! zOv=;cv>#88By=%*zIG}8va|O}HSHc3UgkPaMfLAgLXzn@7>jQhH%cT+`bQSTi6Z1N z8y@7(L9Krz|YS|2kgL>Cb!Pe0|80W};;wP8K#F@B9Sxx6_|$`d7_dW>-t$lr{Ey z?`Ujz#A0xqwe%34Irg+*Vn&#E{ngx=f-i9`3zPZE#}41e4{_#>;f%f34It}AOZSls ztt^ST_6L1vYHCZ2C6n&wgd<>anZ6%lD^CzdbTt-8{ZBC}I|}R^^YDZRyOhU0x#bAm zz>ZQ*^o5-)lUBV8Oj0}_2bW78k?wehc{62pK#KQ7hEQ!4kc49@s490E_B+0XFu zHD3hRKG+hJ`aUxx$b}B|*a`r+E<7v)v=#_hK!{=nc#>gN@Tw12xkOxdfg*K?zT zLjG|QOiAeoZj(zJDeq)`zlb;fquO3ZLTu1Wul=2ueP}X4ImW0XgupdY3;Duvrmp$B zuW|serabyz$Qhrr@-|BJ#B>I~S9*G3w}NCbS2=c(LpBA_UR0TvWAVb-HZ|V0D54hI zLU5O3F0s^uDG3YqI&>CvQC)zaR`Ui>eacz;53CSa-eHB?8UAWKd|z@q_&>NJOnmmD zxY8e3NPm&>&fnDfb#S!Gp`nb?xI9Z;u%dQIQ^qBhF=uGAR7KN0 z$r5aM(mdQZI%Jq7lb$MR zT5@6h&@GL2a)!+(ST(i!WZciG6 zqez&2#_->(EZTO~lab4XnT{XoU3U{%Hqk4(Q*6N6( zhYX7hC1G_eIxUwsmd#R%O(Q8OKB1H@&`AZ^E=$E@q-|k!5}@rsAMAzAZ1ZxfJtdvm z1le%ddA-Nz+>kmNa?%yN0c?<=cH)%$c@j1!f~KzdNZ-}?g@mc#A702RYP=tY@aG3MCK3QzlcAxQ#QJhJ>OVd6iX>p&A zuLZ!hp4{D8aF$DDK0JkI7xm7pimV&y@@z^C24tw?!91`uT@~z}t=0&!59b#&+$7fD zmefvVW&`VZI4NAxD!%51U9Mi-W%IQU->zI?bX-{G*tw+=%Lipzu$EF*!f;zq;24JA zZd}dQ*O7RhGVHcNqYc%`WMJaRmN1!Adr~PsMGwFcc4j*ne#~~i`}JH6+(&Wf)Be*) zqWaemrIvsiW1EqGl{NsLN|SVm*eApdYB%O4`>hQ(+K__1ZDCX9m^?4D`BMR@_loNq zAPZ2>EZ=XAMnR15SBD$TV00oV)P3kk>^m^i30%!_%5eMakG$CvN_u$d>Kj6TWe)MT zAQ||%*{yyG%j`+*zltP0qA2BJu;)}rb=!F1i?U^Yk|y}|6qF!FaT1dn>#`ZD`@^!o zq0Ews^DEn(c2cHK(zcr=vt!cHokr43W5lVFjhn93aI8?h0J8O%$dF-kwttv^i;YSl zLdN;w9)PTT)K-`xVW&T+xT4hqoEV4ce5zJVcc0K~%)6`)2ip$E5PygG=sdQf>#8h_ zAw>Z(?#oN<{DUKbPOht_2oJvq<0?BXacY5StHqn`M9Q)g2=ZGj(`{imSlD;;WNc11=l9Cpu9t|Fb5gpRK^L;fCtgUm$-*x5;Gt`dW zM7D8W11)|7WVGD~^Zti0M|L`UkEt#L-`9Y&CO@B~Ht@L>=$&#(d>m?umFe6#>Ryoy z-C=mnVxZ-9M{)h5|@uy6!DQXC{1)#bhc@@vyZf7YE6jifnH7KU>fDl&-~QR^mR z07Y-6>O~i>Fke1R_9fTrlGyBhJ59%7t&=A<5|wYXl{V|uLpC)nuA-s(nbz{lfjmr! zh_iq+Yzt3gqRnE*-TXlE!+=f6Sfw0C=@sI9*B2<^33qq9oz6U}UOcXs%t>kl;u0N^ zW^YTI4J|AAubt`!E0av=*Zz|VCOVBtT(iiUF_Q?MxZht+y{ETjYqw5jLXX6he52S? zAGE0Bf{}*mbCNxij=Vhk>7&Rj9ZTT69e-Pg`Ov_sRH7fpdCyBxc$)9d`T5xkXn8+3 zZXwAiA@=vKZ;!6H3WH7Stt7zAhbjJ+xM_ofO&xhst^2x>+FBp`S};ou=yxNlh41jA zPxcuSYi!#>*VD z+J;P}*ce4yeGcuhisUgHb>1^I*DB)vI2@H^WH6k2$}<*2x68eZz{CMdfM_JE$UM`( z%a{YFFENL=Jz9H9aPUi@Fd7v)v`x`7Es++pha7D z?YUd$NWC-a@2$nftw`Gm&Mv_%O%fC1tDr8J$g$}?l)|TV@Mk8jrC^OHqBTix`UiYj z0E*5^(C*b}b6sxCRrZFEyg2J$@Yqr%AQN`A>9~$W%%@qYd6D7AkrHS&N_9C%S)~^V z?_06m&v&QlUI#QunIfbhPm7?T+H`pEIjne!LirCTD+L+%;#pUTUYllJZq>6mWhxHG zyOel{MtIzfJsw>J%^%D~`5aYCz32FNr@9!-o3Fr8^O9tsawRIC5DI~=uJDyxUHO#! zjjh15_XI`x`oBnsJtkaqmHjP#Mesk%#)pwunUPe5RXgzjV{W;ByBDVlP}?uAwHDqo zkYhf_gI*W*TU2)T_Zg2c*{k}|uJA`4o8^`=I^ahX?$h%Gz5o0>>oal*r z)iHkqguMX{%GM(u_3peQV+uT+K$m$ zWg~fVX|%~&Lp0}Wrn5{27Kj^$3SH~4_T`JWOOrHikrGEAcYZ>d9yH3KD7P=3B?85PakM`ksX{Q4gEkbc3&+MPk_- zv?9x^L!s8!|2kSQ6+41xF`a$-#^Ol?pQqVY7Z1sLZ|ClG@%+^7)RoPmCi8!1dwI@u zTQ~{bv;B;(q&NRXv}_>6iUlq{61*y7jai3b7ZZlirE@1+ne$d5=94IU3M;Us?vja_ z1d+_Rpwhyvlh?&0v+9xl;a2*FLY2x$gh!R=3KufK`TV`W<=1JSIB$ZO&CMtC)8DyP zJH4sI{Ucusgps&u&bxZm_h$V3J__)fvTK)>;Ikw-oV2L$i!@IPkFX*uop7Km9+7Ji zY*smGYmG$8vwq;I<+n9E*_3r4leSguvo;#5Tl7=3YH%5w8g%2D!8y5?ZRLv0jfy*FQ^%x}w4n6vZc2)#}* zkS0R0;2=K@bVbMiUjBl-0Rmprl45cMZ}&EmTV?8Y&M-;BASsCMgUHi_7Ks{Rt{Fib z99U72#xo0X+^ZTc39AF#eo;KFR|)EE%^2uU{t{GjMo?@;PI)sHCrROlC``*X<3{yj zBrPZ-qwYEBj)mh)vnK-`b6gx4Ob2GR3@71>C5+}!u;IqJB$(x(TxOwVkuSC;lm%;s z*iSk{r{iFmB^H-17pOVngw5pFWM~ml&1;@TevU|^)Oww0ky!c&NFpnjHynCsUj#{+S z=HdB%U+Qno)EvRl+58OGWSk4p%p(`Ck=qe-#o=XFZ$uBld?E1<&+Iw__mO)Z@&yxN z{|tQ?GkWh6?9O4t=$s%n4!f&dP#egs%s;G%@57)6qfhNm-t%s$$%7UqQFA9t?&?k? zo+*{bhxvp4>E}9t(b!TqT3b|Qv)IzQrI3$?F4bQB_L~0~XYtrNl16lrnLBlz;+#Oq zrm+&t0m}P-=MLAgZIU6gg0^^ereAz?4LWx7F1*?k+ng<#V^k6a+#~72SjW>gqxA(7 z^ziYFZ?zHov#i^Gfp?TynEB2`Urjp!pH{hhZc%pL`Pu?Ewi^L)-cG$gK`y7qw9ytj zQhyhB+AYQ>KGql7Ar{!&RDRqwh8th!>uA&RRm~Iun}lUOfF%Tg%6~rW5gG71)$$k- z&lL$cBCe_e0&efMWTafGeXElyR1Kx|l`6;mTLzG%E*h^2?F4D~8(!3^j>{^BNBdh# znCP=DH3cw;3Gu_`T8BvxW_yQH-Ae!cG#JBvj}Ut9Xvqi=;}%6&q*tJC0M>ozKb}I7IxX09nBx9y_d}Y{fHq{s{2NBsiaU`4E4L%(wd$9E&X0Y z+=b?s=m6bqjSP=EFkohqj|E8%xo0)@rJvn5u8jW!uK%V_Pc5$-Blm-^cG`LG;8I6$ zGGl4p|5J#@OtGARpz|Xu5^miCfYJoBJ19v{4$Zmy`O+RLVU~O(9rp113K|pVOo>;? zZWWiX{{}b>%EOB;O_8&X>9Mf*s@?jX)tkcb!E z+14gh#hjTm+431{r~di)l0p{T&%|$lvL>qJC5*cm@U`Fr-@`M zon#9y>UIrUK~-wh33IKbcBQJ4Bg3Qu4tAKP?a7Ex*7S5Dy)?^2(R?n2HF-|GNQpgZ zxKc&9JMFT@gT(y7T*#>9qOqI~uP(&95f2?-Ut1tLu!32la2{35x$~kxz&Vl0x*O&; z|DxcMwS3)}fDW;|V5qf>p<}oT!p*Am+F2W*2y~VCQKw0kAQfzd6tkrIUS&RW-+e9z z+KCOVH9tpy&4w8m6PSv|41GuhEx>$0M<**W!~419N^Nf1CoM}p*`0-D?2@@LqDb0G z=BZLCb_KNIA<047xYVJB<(0hTY+%wa+`-$ZAm(*+(;*C9e0041s#E32tA}qSaUIDj zkhM*R*4X4q+hgp}zE!T!y}^+N4_00NXIf?7R&P!u)%_-Zv29(HJMRxuqo4|jgcR&L zuW>4j@)U#fTMS+oTirX93qx~5Af{QO6MDVnNFpLhiTdtPOns3ISUIbebgi*!@@N{h zvWB8RsdUb~^vQhnDaciO#WMino0Y!84%&_sBPaUxov!|{6$z5;j65T`7#j7}{kx4V zkE8d!jc1t`t3R{$_6WE8crY>1gMUx5HGuDk-!pw}+rVu#QJTX81n;e{>jECPAtI=U z+iMLQc%{7d(HiIyNiTd1h>CiS`uycg%+kz!#MDY)pVVge_)0tdFP!o9Um8;XKLqq& zrwgT}OQv+VH`FaZ8AHRx@D<842zdjH`gsHRjffQVP1wU(*T;_9SF$Q{$J7VAF*fR6 zmiK25rjGu@7(8{nu8;ojl(!IlTARKtacn*zVA)fgm(vlTSF>-M9dJ3X+AjaHlzrP> zPJXiu!@Hsm!ix7)i~$R zH_cPo-*ENJsu!w*Vgjd;=Qeg!aSX1t8-;{^h1=mPRC;0Dya51-p5FQ@(I2=%#jK|| zEbr$`Sqci`7+qwQ2MuPr)$WY<{)|H=24eA}QNGwHUl&jyKdX`q5&kNi!}Kb>ZUwav z%V;}ug}eBcbe_CGpED_)qfPsT&D#=QY@=4jLwa0Vo7mS}Z0Srwr>oZLPZdBjw`GL` zyHFjPfvDvsr3?LH*!!LrDbGz03|<7D+2A(-#YSe#??lR+!H;O^1-n9HuU9X~MG8a^ zPGeT>9*Rq3*tR%!%<+n4H*|H0*+`W3b6POPCynnCMJl-^Kd%e}l6|BZJZ=#1y+-f8 z2=|Tj4<_hYuY6f0Z)eR>r~7+=#T(u0EA2e1r?C3md30ONbf{^JB&rt`rCotNy6S1z zl}P!Zvp}&_LdbEHB4nKwH=W@jZQ@iYJ8-n=uuLPoV6roNcuv;^JIZ{8fGX(2 zh?w|5Wwtfn*~`x$veMRz5SoH(^#U0UrI>QM!!meV{`jWJda(T79}!P#AwyU9A{(A{ z`jxN61CwLn{~A@9QXTE{8_noI8)arwX_McdPQ2g*m08nQ~X9JY1*mB6?ONddg9Ngt_mrK=_EfI%?#74~BvPzr%%L3$mI9H$uLOExmN{kR%RSB6WK~a87ge~z)PaPY zkv=F4DjPW>5HhzqTkay(OVMvx?j=H)^(S{tq{Wuig3?Y2?gL)I!36A}4C=f$0E{F7 zhg0NYCJ*NoUmVBCXvN2f0u&E4_sfzF)DHry;p4q)+}ysd%Dh}1BG>UA=-=wJJtan; z@kqK#VpP^~hm?;XqD}nM_aaVo;63QhyRIW)kwK6#LmsQ#{GX=@U1^mkSyysn`bOHF z>(C-?nAhPxq*dAlXDmHVG)ablbKS^T!o%L*j;t(-=4Nw^1|Q?RuI>Ep&HpQ!_dFxfi5lTPDr8ei`!ksWO0;( z5E-2W=#Nxgyk!upzqR^h_d(?i?^HW<$4t4~su(yjKQtuQ@MUfvU8Z$Kxy_a_=HENe z=ep503a)iXGHpE6K<{kF1^>x-!CBPvPK6|Q!*DL%cbiC6k_qf>bFd_H3x#rDGZ)o` z^>M2giU2ZKLC>mnBoDh3*P*8}Nni6fZ>FwSilY=XL<|}DJ&=n9P5@6*656?wl*?UY z0*hOl6RDPwq4FSh-N0vgsSG_ixeys_8Fk?m8N+TQCx#ZXK0FPdB0QOcxPA`@ zg$MkvlZd*)%i=Y3&Iz{SVNe0GA}8YMCqR?*2YMmkiaY79wda%aO?qwr4M=Gl#X`%6 zU|mBJ?Vzh_C|X7X#Bjj?XobfxyS6}m&n+p$|Dk@yPF2o5oqcd6o^dG0xn+B;LH;EL1dLZ+ zLl#9NI9pwaC9xw>T7^MKULA+%?%>4E-V+?;-6XAWDj%`w=#~}7XO<$A3Wr%n%U(n` z`lC@o?g45w?T-lwwb_bAY8b9B^75z4kmu*^8H!YHCvPTerB87|S9oj;O{A(wTfY;C zZc2+xr4(p9=raAS_0GU~#l+NGn43>>xSIw@eI?d(j^rMXp$M4EIZf!m2j{BV=``H~}FByn>8a^X6r%^3<#~IT+Ws*b?N6vy(AE$FEYfCm zX4smUN+~)Wt7kqZlBz(YIN>B^7f^%3^_@4a=Q)JDzjde5u4h}GST+`t5XjVCb7QAB zgA`^}cbM=7Xjf#E#v8S!rMH-!(KEl2Yu}K>(0LCnXFk6m9@dYgGSKn#d0`WjQNyDs zFn{!;po49iwh9H>=V%6C{wHU{>{9Nq=YV29jOc_}T7y5uwE9)u%@5IhtUV!|yS{C& z$3m&YKo)==yFJ)_x^h^l{R&?ZS>!uW{dpXe0+erq4rFE|AT;oIvM#OzljiGf7a(Z{ z-^A}?0EK>@!e(Sr+{h!ptE@pS9|c;`G=5~8I)WBs%BdvntTvT9*9q?QzbT5h+^!z9 zyX8$gyA}_uCU~!Ge4eAj|6Ho>iU&XedSjA&V~Z81;F=s~LCMp)p{t!dmBB$SeAUBL z4#)N5U>S0Bk{xrc6v_IW;TYquwBN$T(*hToA)rKNGed*iu)q(Z(e)uzveZsKMa&l1 zW`mA4hPGSy%{%r@uaIHyZFR$4KPi}Xo<*=8r4z-ARPGiESSGPll+EnYW|?}j=`_k+ zwgEpb?8*&ll8Ay%S$9|J-S-{a*snfsO0ol^as}cQoC*OYkkiT&Xk>vbnXluMMq+Z~ zbB%bTT$KL)cqdGGwy-Q(^RWzi8zUt7sxzEGP&k^bA&_dS^WGJNE-?`vSv*%C_ht7Z%rw61RnVHxUmgs$GgXCX0gR&@ z8ahY5A6_3A8@H-O%RSuH5h%?ksXRK@FUU3p3Z^g%bHGN%kaDbT4?2W^_nDXmB zAM(g)Kz~=Pj%Z2Ru=_f&*Z?peKG>>tel}k#t;lwl=0w$ zS^?}VZ!c;r`SP}8{OVNURIl&+Ml+j#|MDUpiv>V)TXz|Lgj}v-a_aNC_im+^`&wdy z=;M3T{#ZMg&l_3S%kUx0F0+l!DZH1@s8{@cv~@w-w|i4(2bTATAEU{?j{VJ0-=)=n zfQc;WBOg+K)>S9MU$AX#z3$(=L$*Y6`M+{2=O=TX|AlO<*E^@#er#074sH6>MjXLv z16TI7d|)jyHgI&EsW*MW_6|}Su&_4Pv}@TL0rzQ!J8hh+fBFG*MELyK{bFBUm>`m` zEA$RK0&`BGVc3a8NfEuBQ_J$mD{R-0m;l03a>+ zPj{U-s_kb}(wKU?D|s>I@XTh8kC4=%x@?;VC(WSM1d|kT+oT%jGZC$&TBo}Hu%%2r zNH9%Mxh5HRO8ik$b%@6%VR)@^bz!#b-#;rA)rBgPt6;|o0_@clyx$?>niPA45LRUamcbhqN&JHHtzpm>~srKns!y>=;v+!Dj&8_F!r zm0uQ0>ujafS!fojAG5kb(1B~sY(xGI_uQ_u+Ue9TX#J%ZoGJ@wMIg+vtu5{AAef0x8f9~;Zr)unI7TRGR7AG_qvLaK4t;Q73<||C_Z}oK3+7Y zDy@EoL=T)NOG{JI{8}=s=~h$i*`MmUucuYx4SrHMSylh_ZXTn&JdWuQx5^+*EOmW6AO8 zsO7;!X(YX`-vA1@?`Qe?FyC#a1mI^{A@zqrfo;0p=+#5?hxQ`#@vZHMZ zIHrv`VOTmjjw=dwoiiw{9Z4~^7z{Ii+YTOlHLva}#}H z^nx==*o+fuORvE;MZGa9_`GUAm`d(cr8>Kz7v)FQqV>m%b@tJLH|b`tgVQvkl<$y;qX_TQ}S=i!z~uGADG%T?}uoy z7^&)!PmaeqbBsZa5cN}X&ffrTPfe3$zr&jlzJL3E7UDENA$}Y*snE#t5g2`nL^I%4 z6)nvGS*hRs%Uxi>ghNWsQRIUo9rK$vxAYd7Mp`WrHh32wjO_n2l?^2sWCnomSlAE%|kJ!{g%6F9!PHxk2Brf{Ro!43Db$N*d44 z+(%SX|7knsYu)k)o;X%~RoNOo>8=r+-v83fXe_N1&y_XIz+N?KqMH1#=||rR}VP7n1{Z{(7K(-&LR(%&&jbS*g7RrnS^G^Wfa_O-%&8X7#tXVJ8}R zKyqn0t;Ya`M_$J84E!B;N@b*^_8s(xjO+uZbP;%T0>%V!N)Z-stJ+` zE(Y_`ht%WqGTG17czGp{HZ#gAQSl=U!=*J2&vHG(WR4}&?tCkchIZqJA-rcw@l?al zLIu`7?@9lsH^7f<8(>6_EAW2aH{(ELk*dc;?T$ahMesp`_tMJ2X-0bX3onC`iv-W&DQ-XZBU+ll5`{DH}H%7 zT`n+(WWfYfGEU)I%&gvUuNU??m>kVTG|AO)Kv4(}+H2lOZ~BnC%P;RMvw<+ZSpDy2 zF+@WrFv(4!wBbF=4Zk$q?Mi!BlPp7Z;KQsaONdFG&e+LZn|FcBsX&R;$^glM;Il%s zkea@Vra4a%6;9hZ^J5ZA^Ib>Mq)ZuD%){%6YwYnJwDTdffi8|PA+xaL(y z{l9dUWX$;LyaN+U?de1&2B(S`mTqcz?TX7q zZuetMg4QG<8keNU^9>(w=pj>U$!>}bl*CYOd_xl@4X6~qxS|xkYkpoP(_DmLH0DX< z#m&KaNL^Jv&;Ks)=7}1_cjzzeu!Y^p#2~oWIk>5+Cq8-Z$4$LR&0&|R!TX=NUgG&z zy- zuiflRwZ!i#vsDDS!`rQoZhl_!jHkT^=l8P-q5_L8$WzdffM0#V1X9sO@2q9nEImYw zjN`b>@*c;y(pL6|PFL5>z}Q7|>{1_O@sdxT_liKd51*Sg7+y7y&E~$A#NAt$ZMHeb zdd%K@&8TaDABq(#Xl!U`96dF5eTJ9vE4u>0Ke#3bld}ceZit?Bgh_VkN$amDN599( ze6}GOQG_1sDM*981fd%eXEN?@FXLr!Mi2h+oEHpM+Bn#AAFSyc>pf2wjtCh3F|f8K z{5mOX*zlVmW@pG|##7N@CJL-9uk^Ln%<+%_8QA@B7-`2vbJ}d)`WtyULY?wCI+Y9r zTj7^XRyEYNli@CAQt=4xkRS6<3p4x+?O9@vq57OlW1!C73n0A9VDF!3u%Atc>~VZv z-uw4se;g~2)gN@Z8x%v?c>22bS`$3Ay1OZZRre**cYCnL3?crxBxkR*zcG0x@!16C zx6B1l{l?$}>>^)#tp3D+k8j{uj#rF=+_b1L+l<>e{-mOu*5$4?uu5UbU71uEJo)op z=dX2%m4_5=r+w=-mXpjUihrP3 zaJnKnR@?r_fO4+>wd#YQ7pw2N9q7Ts`OY6b+f%6%NEaa~H_)lG>45!{47r8U!*wlC z^W;HU=0m-J`%1$GsZ-{Il!CP+jfM0_Vg_U)lPJRuZNO7Hr;lSEeWGt7{-atSf6*iS^I@d(3%ZrjnQ;+)P#$YUB1mznOcxYGr( z;zx>E0#w+dqYj(n4}ZJDDc>`Z$i}8Cyf!fSBt0Y9$=)+sla;6e&hDFBKmF0CBLT`U zc{IJxOc?!f^?3;%<+)UIeLo_%Gk0V#qcDO^q*S=clefe?)D{YFkU54#NN{Fu;sKOxp-R*1P}29iats@jL*7*#~KLlvZ<&Llr~#58Gpsg)6FsnT`THR>+Z_bAKV zH)8Z?j!?`DxGyYHbZB~D0vY?)^e8F*X^?(hv9K8hn{WC{E4W)V*Eo7GM}&aIUMT1k z%f0Dz5_{O%RxdBA)4Eg(Z*Xe&3uLP5Z{xlWm;D{YX#kbVVFM)-B1qXk*THj3)l+1I!hNER$1iAp>QoP1Tx&mq{$I`9X*3l4 z9tUu{j3QeVubdJ*vI>>7&c;o* zdF5nfgZ!@bunJy5KzG0Gr|?Y27l?mcuQ6@HLzn!!8&+7^xZc^ZtIHL{yJm>0ZXo-1 zifqeqK@SPKYK}0}v|1|?ddbk0LNsX?LM|^e9OIp~m22h^D>0gjZqz^ri;R_9{5A@M z!FOhdTs~D_C2cgK65_wPQl+`6vls@gaVll??4jAz(W;Bj(^Z|@PcA;LZNr=FBrxu) zA2S6Dc=;?{3|v$tzS7|49@B;Pp#<+qVt1_tFU<5=`KhszHoBYQQfn;tJ$c5!IBzaZ z;TyZd{K4B=(5Yc&DjiZyDxi?wELMV_g;H46N0pSDLZixhDd_=emTH#l{N=fS*hfcd zA?u#W$ls@M?IgClgq2MA1bMwcjUAmgfOrd7vvu7x(9Fh~jbbG4+0mQphP zG_jziEYM?3b$<4)5VZhuclRk_-TIq|b!_Ba?EXiSP11;GINCO@rc3?8Dfp7&K{w2# zO{{gX?L5C)tsc|s5J6>}bDhTr!>vak#Rbz!ICd#hf1TQ&Swkl3NP!6Gqy-3uda`MD zd?|?J1zG708prAvFX{G-Pgz%U#Z94IzI}c;8S=jDvs|?6^O2iV(8&2mzK40H0Q!da zZ7!P=W8vLFBS;zZ@<(W&6XJejUdsX|t8HOJ5wUk!C*i%Gr@P{Fv}DA$aa*G;I>S4+u{Ch(#4ToB%3vXXK^_5FH-)_kOm_eGzXw*vn)w;EZv9KnZF9yhP zr$mG>$}@thMz4*fH+lH(Cj?<~059C%pXaa4BN&xzJHv74^vS|~Z!w9FKAnqwcr2Qn zu{*{~AD7Dde#{iGBhy8`i;27Ay69?@&<(R3(pT%~t;%$TZ%Q#$inHeV2wOllzms-q zoD;TdO<@rkwWH?jg-)qJGY8OdVn9XeO*}B%dc&$ll z+99z1%1LGigjB=-A#7cmo4GvP>yNQ*b$t!HmD59yv@}`uXEj|hGYU~cCvt?<)n{X< z=jsA-O#xhBo%;aW-s>aJVK34}9GyG1>)HeXuCw-X1^gZ{Wn)!a(WiKBpq0yG8p#$j zL7xj_^(#zESdzlnTla9wqRJq}J3e6!^r8{Nf(nqLV|yfq;JgT-!(^SZJ3tLtVBbWC z1VLFi4A$G+L{nG;f4d-2CDu&+0x{Mei@`Ilo_zQ5HUb0In#CS;oKPSwq^bzh4c7e} zUs9yGwIP$$(w|b&`;7YXl-jx?v?9&$41qKwc}?^l<8twkqm3{>Y2a;#vaHgB4GGdP z(DJ6(kg~6cFegO>XhHM$g}&f@{W;5x9z7p$QnRHgoU>cGiIZyxm=Uek1vCR_XlB@b+^3{%29Z zydOFS?prl_;>)2*I>j->hPj!(9I~rc&U}5|5EEY)n}Tl)pY6w>sb5+u)?_hL@kS^T z-$a7)MdK7@BQndNmlSVEiXCiSRl)du{P6JE zZbE`7#MCusZZ1t<*jx$V$7~Jg-bs>8Xi3d_^yAbj`hlbMxs1BYvqk6SOS|+XL}bp_ zt9-g5sQj{xHQqGg4df!?B3w=&b@eB|TXRa>?ZK6s6nddxm5aRN-XnT1$6#3ytjtaL zDpmbjr~xf3BB-Zx1yo7HPEF^; z#J|4%DP<)vkS+cp?Ol08%x}*^+Ze)qQ*S5&Ia=|NCC5c!t~|ANW23k^WFbpT*SN(n zlXvlXokjRIZ{2=D=o))3jlt-ls+JV8Wyw7RM$P?EM4jCv-iis?9-bAtU^*ukzSY<4 zG2qFVey&F=t)-+Y%834fnfkho>UTVpJvwGu)T#8cS7|Yo(AVrY0`h=43m*Gv z?Ba%D$Fb9Ai5VcIGJ!U%JSY7^0=oUiLI`BikKQ>=`@a)r)V4gXcnLQ4Sm!V{Pqy}(mfK!&OF&xzLtgO6J}PaG^JjKKY6&(G`QwV7A(?i|o^t=5Q{~ea*S+ z9q!yLl@+(CWdnAyJJ1;EjX{Wmzy>kmv}kZ=#}?S&`MH}IbNw8kxqhLRryqz$Y-`J{T6qV^zQoJCQPlRhwAgiiB|KdH#B#k}-TvCdCI+*rs~x~hk{R{x;KkuqHI z){s<(aDtAcKgEfoMB09g60*?Me(T0%Kaxknr(W<5T3O0VyCvOIV&3`n1n90icZOMD zihOzAm(0rw%GN#40^iFtk}g$c+`Ec$kT1tP3@7aP`klMiDO)K!lH?!Ke92b9j9?&6 zi&x~-r(|%E2I{RIwOYpM;_f`)}wRxNj)<459f4|Qp^@fx}T*2r?c8~AF`amC&Wp$f$ z#O&RIJtPB!02+WqX}gt>{;&1Id5gASp!<3K-4x;>1p}T>hr0001b0Ji`D z1phF}Nvpj$>&?6WU?`4cX`X1Ru59bRa4gUCIMjGtAV`7ny_|5>+g*4A<8WC*@+`o? z0Ku$^qy?n}G3831*6_y5^KFyJFICKjs)Nq-_tvf_(m;7sIUdU#;#)rnow zI31-#}0kPY_HfE>Ww68UH&d ztB6istdJncAsm(uWlDwkSORewf(#D;IHT2a2a;xmTR3w%45rQ}he&yXI=qENqER;% zmjcSdG04*&$)v7?cJ+v)kK|5Obb56qq;3@j_6$jIBgt_I`gE1>s^nWWbSTX1+6`CB{y!REY$d8Oidr6TuD9P@I{&MTRj zAZm0O>dFOV0Rn!EBOn0=kKsLoso0YF-G z!Ld;v59tMv-a=1Ywj6S?ktbh;6!OAdsIYb2qX@I_#j9%<`|nm$x#@fl00%~0cvrnr%_=-GMLRBJ@S*> zeBX(8+>+CkNFhJ{Z9#!8X0kwrKm`mLTpmpt83%H_0eB;qP7cQ%1#0OT!ghgm_t%08 z)d}Z?NWx|v8h3h`XIv6&hs$_@&1PngkcMRogiH0A;|{**b{d$yIa%pXdIf3%rmQAV zOeUqgxy5x7lE)>ED3Z40fa=+2DW*^I1J|A#Ru~^+D&j~duPZ)!DgTyK0NPw?9uO1J z1gP2A9&bBdIGuZO{;+43tlp5N3_Z{yn`@=!2p_LTcHu31U}Sr0mgc&eZ-n<05eTh& zO*m$*c(z9%t(CHB#<_vD5-70MLQCYKa@HrYtxDgOc>3s6j#ql!Q;7*WuZbqDxx75aA*YC4ab*}tRm8IXaHAcVLTFPrYoOF z%;Uj}lW-!P@LE~T9@&yOsdObNt7VxjRCAl@LVzvPq|MS{lZ6BP8N8MwD(Y;iIn}JE z#MF|?BQES8Qh294iNP8yDRh(F9DwA)xxl>P3jZTOP^UaIWgK;qtf0Q5<}xzcQH25^ z5f=j7%#i zta+0-<^*?lt(cb#rA(ialOHziCFs`q%qjj9j$Vc6O#m0T`W=f_lU(RRvFg)pdVqp{ zn(SORE0w90o6lBjdz1h=q)0ZUfLJ2PN}R0RP+OS<4CBx#Dn$l{Bk42jE#La@K=G4IO%d z)S%{i=cS!JEL^`kT$0jMva_A-a&w!u1?CSGA`NaU^?Ss^o;AK6tlE4B>?TQgk5|4` zElKH$Un~AkEjR=KGyMu+sy&Fn%f$!9cxzqiQga^cy=>2J+S3Z>VMqf`;6`3HHPrt0 z!#(h3){>bw5bc)vI{&W?BN85llPq1=_OW~nN! z8go@DH-_Po#j=Zt@PwQs7P6FOdz3(sSge7?aawdt5^gY0ArX19bjKXkqd@qtFHEvq z+MJFzr>@UHJ*%0yF=NDF^U9mbGyj0A(&hzi`7eRC>77&ST7kg0#PF@~b;rTwI6Qh& zFRt+pWQ(0a3w6pzR`XcK5{ErE8q7o9!Kg`!#>WIT%IZz>r(=bRU7PuxJ)N~p*?DWU zrrN}xE(QXZtP)`Nl++sq&SZb$7Iruy3(nR?zKbc~VxtwZ=e{olR;?n_DY>PKaNokZ@DLM77YC z@)6_WY=2Lg!N)%MR_yX_S8w}8mX5f^=SJ`tTO8BS&UG}HZ5SrIV!t8JG)8L@W|Ncq zu-(-%M@-S{x3uG@?~Lo_JpTY&-26AwQ!O8+dp((W{(04d;_1m{K6D!ZUFN7xb8a}u z3nBVkC6&Fo6l>UobXl6h9mRU9HLR7pJjBKF8}Ib!@zxVssp~N*GYYixLK(S_;wVw zHYp?&xozBVtFFDznE!!Owo~`y0t~}ORi|FJ2VRW^YQR=fSC(D$7acj%R<7|gLRC`+ z$9@o(dNh-*rbHFmTM_ zNFpLBU0{LjKoop8ayW)X6K88A(+DSLODENN4+njER)ns>N^InB2(lNzf?YgVg1_fM zc(;KcB`$ijH0ShAd{Q@T1UnV*YOBLL)pc&JB_i(RdO=5iV=xV`;sp@#25gdn?$?D> zghW-xC)MPCC5HkCgg+z&g#Olt@dY{`cmWWW1d!)!>vVrRcna+1gk9H%Cukh(6o{4x zHxf{C<#Yz|Hva}3*Ka)4eLd)YvsDuU2Z|L?P53c#z*dQR;cyS0I3m?cXwM9L6`R&0Hk1NhIY9)7aka2+UAv}WMvX(MzS~&(=cI47K#kf6W!K~ zUD%ZRkb~1^Y$<0x2EiC`NRLCNX%`@lmLL-9QEM^gO7GQ-s6~6U$5teSF5~DGLG@P= zwtL_eEsZ$@2StrtWKBn@AIfJm3AqZ7$Sy3{N}Y)lerSUkQ7?C(3JxJU6!tJfA(ogF YS!`39mq{1_xgm5RmcIF$RuBOIJFj{yo&W#< literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/radio2.jpg b/contrib/ntp/html/pic/radio2.jpg new file mode 100644 index 0000000000000000000000000000000000000000..ceb7c76e36fa4bee7ef9e10763d5364d6e74cbaa GIT binary patch literal 17006 zcmbum1z4NGwl4eycbDSsR@|*Pl!oFi1&X^vAuSYWf#Obq;ts_fTA+BLxVshCP&_wn z_uYG+^PF@3``WGKH?}Yce1^|M;{&D@SL&E-}LxShNf9jt9DWm<#;n|-$7=KEj zzaBLV$Gl9QJHPYEAf0|E@;`TwpX_(#I^ zFUg;KUct)%;0o{8f0+<}{#O5&D%k&v?oXfpdf<0o;r&FA`TPEdKZxK`0Ql`Q(4V?k zzl*rbzsvA9++IKd4mAM4FcvQF0v-V%*nc%z4*;{Gouf6akGq|xr?oTf3qM*}E0-76 zwErB#Vp>7&$FL&+=Z_q)dJVrf2(|#c1+dW2(9qGa(9yB*F)=XliE**8aETug5)u;< zKElWPlm2n}Tlmj82pba<8wVQ?2M3P`2M34fcZNgsw+a6L$qis%0DLrfM_my?^Z)`r z2oWCyTY@_U71jfihFggY`jg-W|4xYTNs5Gwf{KQYfeD|2|4|775D@>j5)S|&fe;ap z5Rg$((2xB<6My?F+a2}sb_NYqM-iU)D~3trFU3z zVMFiq_NB0ro{djO9q%+4=-009AREz%#GP*IQt|Cm6>OMnEoz>S^|neR;;(QgaB zYL1=oGrm}J50019BDVApIAuclZ2&5>VAnX@h&)m&1sx$z>-B${@ZVd&@-Gu$^8gm& zpJ(C&(g0L}RD?I$Z|zgU8T#Vt7|WYMs`)V&sL3@RyF+yDdE{lMY*%LM05@>B;{(+N z-`(s|=j~sdVU`7yd1{{tKR)!eymSg$*{n358}Ie-+1^^n+!JWT&e@>Mlvc3dzVPNh z@BEr`pHg5W)VQ-b1D>nlo1b4^U+U`9-Mx|iwV9$3K>pBVZup|ju@QeQ#^yoRUD5-$ z2pUurq~?CcyW~(b?u~uSHIIn1zSP;0(84qI<;U1$F)d=<&8Igo;7NN~{%)pE{*U?n zpglrfB^%vwdJ1UyJP~fzVy9HE6qwroA;wzm)vXN$67m` zpIwndhxY}=#3_xF_a7`%EWy);r9ZVVI^HK3wNwyQ=ls%fDXPyg8%T3;H)8>NBGxNNqHgM& z>V}xRwVN~U;#&Tq*=d?UXWU4nlj9%S+YpPvK7(3ZmLdyb;&08VPJ)XjpFB7T{hWTR zjL*c+*OWfw=C~LS1tJMc(`|kT4KI|eF1pdJ-DSUo4(HVu2}q9e87^Y7eO992_JBxV zvl|KDM|$o<9F{MlKl#Tz%i|i`lWcWHeB*#y;JvbW?7Zbm{Qdsv0Evb5<23rqdGs{; zy;++j7=Wo0nX{7Xq9YCa0aefv2)k%2;*+^>bPegN%eHSQwpiTRFjAYBt(tT&_Vtj< zHqD;&@a}{G{4)6xMniMngDpXqf>TF(&#lKvnkd`^jbMgqtkfH_peoW#`cY9Y`En(8e7kunb~{zNW5u%JAzi5rkLu$EAF2%j#a~GZIP-&$Le58t;)*^2Yq0NY+Z{Z~VLCHF8xcLWQjexm_%wG`U z8}Nm_p7oCd(>$y7wixxg=H}?nA0$^SD|=lAV8Gj@-O?SQ;Rb6GE2}mmOKKRPckn_^ zXg_i3;9lJOA^c$F(+zdwc?#W*m!dRj@kT}!)IDnk#Xy%A2ipOXZ)KU{@BOed2f1*1 zmyPq&TMS3bpW*PyR?JJ?pHDg^Se7Iive%ZC;Mbk)n4y zxNaR4LAdsmLR_SV(y%co$jLhpwZ6w2iJPJn`m8#1rgrJg+v)Kcz%yg;X>QsG!m+Rss*#QXisKkkLtaPI8PC!(O$tEqivx5lCl2u zq0?|*#q^;|;qkM^m7A`wwH1^5I3}r69s8L=nm#DE;IYfh1(WOjjxy5yYv5*1;Z5kM zN6q{U>a!%F%qoxN`_{DMx!OB=9A?z%Fsp@>cihf8$4-99H{}i&6rIYysuvny0G-Ga zvsRvJm-fiJBk9xJlV4s30dtl#Z=%O6?8JqIZEa(oRei5)mCF3?vQyH!&nzAS|B9V` zxD2Zc-mS9bg0lV!ieAZu0a_0j1+&{0fi?sEU-L?ToCjp>S9c#3jy{_{oOAiPZz>puzxAUg0Au zq1Qr(vom;0OI15Ja***)wdM6OP>u>{(=UgwX*=GB3%?+2KB81S`%G6eCJ-=5$M%i4 zuEG2E?>L+;oj-7Gsu$WLQAQ%)If~zSgze+DPFj&~t(2qaN_Jer0D*UJN5Y93ubW=~lmz4+9kH@jJC8Z3OftxGibyN~+uz(PDcS4t@znyGt$h z{Zu=U{T@@P9B56-&$ExBR=p>*DYgB%n}f@ib7J?|HycnUxWtm5)zBbfVz)tt2is!N zd%8D}#-me|s#DY5v0Q)nmFo;Tu!-k&dQXnMqI2F7nCM(lAuN)fq2AkN{5?#_$w6{q z;Ue+*06PAoelkKC6qP4#D4N9hB~0^sOA3v8nUk(=<)w|*dbat8JZ@a|4L8+|7dTMi z+IxyA?wIKX7vtS2@^af+=7ym(%GR6R&&PWk<;(7KUc#FjbDujJY`5_pyvKVRIz7@3 zmh^VYDa29?y7%Q67*V#TymVV~r>k3M$=8~b9zJyBNq_Xvj(_`l62C~Jiv=BDlc1yb z5&|2azNv@WwF}Ioq>!1&;2D0gNXlL;7`gF=0o|Psjk}d*pPE113`|AJ&b2bu;UB$; zRUS7vei%P~ESBK(6Y6DudJwc1n)`a9Ej#=O!gEi)?vH}112GsLsv=7^@~Hf5>7SJr zV7g;fKPhcJCDhp5X;XDbowDnweQh_W_%h%S27GEbm&aK9nLN_!SEpm-==Ock$@hC{ zuTubGMs)?2N4Zl>?L|!OjqnZ6qEV)0aa2&+mrDsxq=3AJsDK^#;-%mpAlTNiS6?7NsN9kVj%%v4H}S|C_Gb?e(ybNSu+OzTAvWTK=qx9XmzY&R%V=V#hAbke;# zsC--cRei(bci0q$+qGVn_v9s0VwG|?*#$mRcP*8Tb{8?@Jbo^_6gQHsW#PEm~nH{~94@zguP zgR^t^ccc0DM^!ep7Y{JtLa?%oq1cP2TAJuyZx503@#}s(;McRL`(yVVH~%n&qrgPZ zr+rPJJ+VU4G{!v`Fm~(1bc7+GH2(%yfb6jTUNhpOV`b5?rHO%Krz`fwzIBgAU#rjg zG~{Q&QlN1y4-X;*Kdn%qo`XaES{KUr$~fN2*i3r|+?N^bW!Lq6);p$y;qx6;J5HbD zgis$-F*y259b0~EwA;IPZnLlE?WllaoSJsq6jCaCWLA~#_(QTUGWP<;M3J$T=JTQq zRu1fGs+XWeBbeTT6Rq`&}yZ9GmPCeAV+?qGp|4LbBG zJ~Ysh{^)LH8O*5c8Z2F&cND9bFIv$*GITRKdHUgqD4h>;_GyCAqkY!7+g8(Nu*$ts zRm0~|t?B;w?xjztQa0DvhF8f@c7Nzqv&i&|Eo&Vw?HP;t_5JV)1?r;4h1i>i?*}kI zxylpkSyE`0ScB(%^`+4zb++@$STgVTMxN3`pP#&QmQH0fWDl9mW~XNPT7%|2vHEXu z@sPYAu!$qLdsYhX9_;F#Am>@|O~cM;Q6pH(d4=ZXefHoD<_=P_$gE!r!P1S*MaIjO zJgG6qqnLfY8}O}HNyctM;kIyd?aywf3T9iQMJvM%fu^^W0{*^)}`E0P|?>Ri_f7 z)h%Kh)aMrqq2%55dovNnL?2_b{HH!?cN&}*d2RdB`xkm6C2Xn;(7>6By+v;e%9l|3 zA$1><-Bz}`zJ2Unk?Did1*+R$)>`l{y%`A_B}b-y5S$>pNz z=o%QXbz_=-R+p50=6ZNfS-2LZ5k zEPWL@IWrASu%gOS1pox!|6?gXwR3hsfJY9ToITw&m7dV*8yM1}jsOS%Iy~ON3jh|D z9xzEzwy7)<@BFO0x-d)tU*irFZurw!nbsF_xu}w0Qjw}JuKn) zExe_pkEiQz`3W2oy>R%A5q`%oh}_`@!ttZu*yb8XT3gz}@nbl~ za@W?BgJTH*K*O^6H~iw?u&1>z+)e>C^*@8(WBa$p z`SU+x1|k{$m+W6{|0Q$Dg-4O#(K5u?f5~2?0YGCY06d!imyGcfJa+UJ02)UBtv@8c z=ZmeUr>htbkB^TJx1F^m_iu;(GyQ*7_-D=k9{k($xPL$IpT47&w|;5i<>*QK+o_f= zjxJvAv>vV&me#af|9KMsUpM?Wv;NHvPEG5V*6!BM@JH#wXPKR|4Scwrt?WGQT%2j` zod3HK{=aPYZ#Mjff9EwE5avGsL}uIo-Y5}(csL9o5n=*}##wL;=%3^E6kQk4fJ^jf zcK*(LIEL&0}e~aZbwP`KA+`WI}zoA6{8NdK=0V045pavKKR)7oO z1B3x_Kn5OkQw6|)Hedjl0+xU+-~_k>KENyB4G;!I0ySTmrZ72puX28$<{q1JQt(KpY@GkO)W$qyTyf(gYcR%t1CF zXOI`@6(|H035o}$gK|J6plVPv=qqRdGzOXjt$}tyXP_GdLKT zH3V%069gLsHw1r#w+PV)sR+3U

      Q3UlE27rVv&U_7R|n03s$L2_hXL7orHF93mLe z5b-6VJ7N%G1Y$B`E@CBO3t}JQ1mY^<0pc|h3KAg_EfN=!IFd4w4w5C38&VKb6jC}; zF;W9k57GqE8qx{U12Q%;B{B!H7_thoKC%t64{{iCGIAkuJ@Pl?Dda8WOB56o5)>8` zVH9N)0~C9d0F)?{Oq42=FDPRu8z@jzR8%rl4pd20FscQrCu$gK8frOeC+axr7U~rm zCK?SIADSYXA(}H*MwX2zDmHpKSCj>ay*?#5omzQQ5I;l@$HvBH7iWZ*R5jN=^PqT@2* z%Ho>h`r{_!*5Z!h9^j$lG2_YMS>OfXW#BdA&EP@t3GsRH!T3)2QTV0!1Nc7)Pzjg` z6bP&c-V)>ybQ5e4A`&tX$`M);h7jfxek0r>LLp)yQX#S@iX^Ha8X-C%CLk6d)+P2O z&LD0lUL`>!VJ1-_aU_W$sUevrxgn(@l_j+%eNS3RI!^lQ5yc~!N7j!b9#uV>dUQiZ zOQt~PKo&>VNVY_dM9xnBoZN>zi~Jk;0R<6-IE5ue1Vs(SJS74pJEbON0A(KKFeQ|V zno5bvl`4&@o9cj?gj$B$o;s1bgL;>SkVcBejwX?&lV*>Wm{yk7kv5gKhxUYyl1`b< zi!O(5gzlD}g@ALT&c z5aO`o$mAH~MCKIbbmq+EoZ-UalI8N|D&tz?CgFa{9n9UxeZ<4aW5^T7)5r7hSn#pq zVpK|(=w!EnJY!FwTL zA$Orlp`yuxPkxv_409 zuJJtM`L-sn<}1xUEkZ3btx~N^?I+qX+6y|YI$kIn^rw22Xk7fEJG1IYr(*(n$)UMZ`oPg9%H7}H|Y?$T}3 zr!t;oRDGoU`2ORsOsmZCESapzY^v^1So5^L6w43PcJ@ z3dsv23-61Zi&l#@i+f6hOG-*9OJm9q%Dl>U%ZA>iC+X3tJ?}UDF{c`Zt=Ich6S=U0he)nY0^PZ7!YTx>M6??n;Wcxb%CHvb3#0HuN zMFty(goYZ11&8au3x2O35gKV26&`K+A^M|bOk%8KTzdTLg#1MBq{`&b)U&CvX`SiW z8RMDNS*zKfbB=ST^WO8f3$GWE7bBMNmXen#mvdLxR;pHoR@>L)*M`@%))zJ`H}*F@ zHt)9HZewpJ@6ha&{N(%DwyU`NW6x-BYu|PM_8{yK|M24x>rvgY%<=Gv{>j#<`zh=! z>YVJn=tAJ43#tKKzI3|0{S|RVc2#^Wa@}{Mce8WrbBB7Dde3&>@}Tyx2y=pSn*aZ~ z!QTsqzuX`S5)u+J5(+Xh3OWk>jfsYWf`*BOfq{vEfra;%2>i$8KeK{=%OLn~AvPBF zBRsrE|1aF2Bk&m!1Siw}#SN0cxk32y7eM`YY7js|MnpgX0sr6z5fBjnUHc!oK?D%u zZ*C9;6%n2xcz_TP@sR*zI5{Z$9EH#VP7V_B#pR$9|K;Y^_(@)zFuDhyGRX;O#pl*o zdUOfOvn1rz3Xy7Cd3KMlqcMk|V>}{zo2a0eU#B~v!%BX(asHbhwDt;3`pXgiHx!|W zvc9eFyVT;Q{@I^bY@#X#c7E^EN}31ecCXpRR1NL@BhpJ-2Iu!~{&I#WS<{8;F)p|+A3~~~ z0B24gkueJ?kh55M>Ik3Z)poP8O>CUMP0X+Rk0vYr8?X8AwB~=X`F}9^Khckh>=T~- ziOo{|U*7UgUYsZkqifju96g>@7w~d=jFFMJutI^UP&IyI!T~M5-0u(~i8vll_u_!2 z?r!v3I;ejDgIOF>VZdsbP~G*yIsYKF)s)0o@siz*XQPG+oW51+38SW+!6J|&8ixVg zZBU9cC!AdcZwW;h;5HB+VWs<^aGu=r^OroNRJu|KUv(x(?L79izdzRm^%o_rn^Qvz z|CLyYBP+`roRg5d&&~I86iOIMqzSJUC_6jGsw_7)Tv+ZVB1F`7d9M3zjUuHvmbn(e zP8`Mu@g<71w8VK@bW=%moxIYL1!sM!FUOn&!c!NJp)S@25spK+@0Kig)HU~qA3r%^(EsW{ zRbJ{>z!4PukdU&_IhDncM9dCmq;|ea!4l>@Z{}OuOON!_5EVvzN6~Lx z0+89KpQCAe4or`o0-XYp^pYzX8=4f7$%uk6nu-^lQZK)oJR>$S`J4l%_5LwBVpwQ? zs@MC29cD>k_0W{2q>rD%XbceC?<*SYSKm9)an7_I=J`cTZ=3PFUyqodo3^tG|6##^ z8}fR-jxw46AIv@JB4|QCq!h2Nr`ejJ9if8FE#k&I@C8(>+bpU$GWjlUdS+pNhEJIx zc}F)Yx@iA3!Yk=kQSG;#d1o*nMhHYWu9B3U#)Zia7HT3o-s4(yl-^txl)4J+tVjv3 zKN-kecre?m1rt=IRZTHk+~xnc+>ihG1!+RwuZZi~vP3>SCiOV=s*y02MTdKJ^PNm_ z48#7(Q95)8|A+GHnbWV=HPWHkZ>XVFIer7O9|WywA0~`~mHN;6&g;jdlVkkRt|>37(2;^<`6HC9Db=`Hvv8zqt<6DZW zQ;6_=yjl6|qGJEdFZ^ye*~vAePDkgHJ53H9=(?S?N<_PexT-Z9bW*8&RnJr&?-3}q zrwn2mxL8EbomWuOS!4M^7S#7GHg&0--_=d^=D=MU0_U?7+4HS+IYSQFa!{e01jX4_ z7HGaW?S7m4l5*2C8|gNjYjhDpaTsOzr*6K3oAhAC8`%#wLq6Uq8$%88hO_02gX0`Z z2JggyV+NYAj2ZNfV(uRmuNsT5Axa6)+v=kOY&W0rB|+iq{VTP==p{Z)@%j*z)$zL| z>Eo>1r-Z`4!W20TS{uHrpCK>`fw?j?5){s&;yR1`tSREa!Lr>JGQP>uRoFxyR4<`GK;QzKoB{twEaukr9MV|rBBcGu|gg3XQKd<-hGI<*=E^_39wC-8Ql)#Q?xgh ze|87)&%9iDMU#{gU_OjMT;Gad&-Cu_GXWbg-68pyinDd%`gLTuakYPQGHw1?r|-vx z6QoU?Xj8R~Z`8}?6Tali^>B)qt@D=i%@}wfCX%RixZ}lVCxjcM_?k9(+G2(^V#e5K zCL!t~!-NBs9>ld>6q@5H>J8+H9{1n~RNJ_IPSUj;aAc)pe$EMi~E?T zuo8-QPc$`yX#^=NNrAoyvbn*yj|0=f_Q%9`=5|k-c)E)Whq3h9_9MI>~CA zfcg`SCX?U>9N1qKR!MRuVDSD~Psmr&GhQ>G4vyQZZII)N2# zzuqC)CpVJq^9v&nNl8;}y#GfvIbrLr_}QqP2FI1ayG7&)^>apBvcayoXObyxsLq+#RP3dhIz;Rup@rH7g0IMpGCuRVWGB2Xv_O(>a?Uf9a zuFh1#;XxT^v~5y@bGx6vXJ0+;6^=8NGIHv-vZh!3 z?h#cs0e!5lxnms7@j)!W?GXV13}|`ID)D|}55T2ysZEjRU2X*5H8bVgJ!+k#pRl<2 z!UrCVUU-Emv+%1w%jtbVVTB`IdxX0GIPuC}&M1vh0h8HM{PXaxPMh^F1-L?m)?-7N zFZx$hH?p#CI}Nnc-8gm+x(~A>4=n1mOx-2~Dx}8e$_3TbpQuD~4%l(J*Tm+z(<{)a zRO&=ZQys{$J&Ef~n$Jus%J3W#IjYEy-*}d_y!N6sb7kto)R}m620Tp>|!r@&J-FYyzr?{A6i_J|5%3XYC@cK_+t!c*mhX_=`R}jMGfY{)RX! z&!T8<&xd&)^JN-~@BHJ%X+nL!IFSC42*gZejv=fBaMVVGz;$ zhpHUvhtoo>YR$|C*QKDo>-X*Ts=7toc-K|{ON~^m#83z(XP3=k^Tq#cRKM8 ztCA=SV^`3VFNr%t>AF>A3!Oz}exZdiDg4O$H=a2hZPDl~ANXYaX!C!~q$g#S{G@`I zhRySrbdftV*o=G1@-RDaTOt>*4mtmM2|3E^SZ#d?`k}b;pRgJEx;u^+mMi39?EN zH6a)VkV#5!e$nXVqO+r!iHjtAbmtf};U$fKtMm$;Nq3L-b%aYOW@SB_v!hd`HOusq z>9cA^QVc}JzMfMF$m|BO*;eS}PP<2u-RHf8QeMxdmzd-U&r~%+`tPGMtJ$X?@6%{b zS;fdSBs19%G7#zVJ~55~>S9VY(w z2b`8N=Z{%>-IErHmGX@)b>Sg+fx&Q z1zN@6m-Gs@%TtnyoDg#!)=BpVA5jcRGK{_SJ@Uo$q=n^SAlXnLWQ`?mzX@~b-rnl< zizg^MBW}Ah_zUXA>V@yLCL4Vj?9ja}ht?F$V%B8HMk$pg34pzKQ_!IgrZyd!7!ncG zPvCJoXQSvoGztcXxv~luaLV(^%5nPz`{$!n38yX}3V}}r?DZHy({is*US}+!%*3|m zdk?NvnkTC;#RSP(YokHtTpeRk-z8G32zFF+NR<_Y44M=)DlU>SC|Vi%y2Zhl)2^e| z2(#9eA=kk+r0(-eN~a{kHR1UDY{)5T_bYg~H>J%sSoZT#kz?fdSZ-+)39g#@7$MJ- zYVteOT0&owHwrZ+;?Ch9^hzb+tn8h35iDm5y+s!rG;I@*ikJlr#Z{c6pSRRPw!ZX+gL<9t$k2&Kypal&?_F5wMwry?Ca; z-jmzecCmMdTPXaFox?n7JleME@!o@B)09ASU4`ny%*zTFp9=iJErUL(*c=#@1NO-CMz>^iAl} zn6FCdviH7hXlWDX#eF*Dcgn6)((htc9Z!I^#uj@9Ei?;Z{1QEoG;0OTCsE z{1~$UKZJ!!aFU#Jw%6Ws67(^Yq0t)My@G+PU194|)D5h5AWV2!y^aCWY8bOhCM$AM zun-ztY2jBX6JtSJkB@2mQJO(4z5K}YD2RB;0YDPZG z9j$|)&k;l zWMM#*ovGPDcFZ+)SR_@jT7go9nd&GsEOZB(v!<<0pD4$^axtwLN0h@tLHwSVILdq9 zgJ={_Ch4e0vm84h`byYPe)0OO>ye}+nHL2Kr@_}I&am8UYlK%O!rclVkP!Xm+33^7 zr`wx~w=hy9T}f8pUyta zH12X&@3*Zc9-2KJJ+>^)_G~1QU4=3( zJzs(|{m9qR+g1vDYdD09)e#Ybh*%i-YhDOLVAB`KE8D0k2NlcPm*6s^UiP!WvE0`Z zYLADX7r%FpPL^d!IhXD?+-jdr%iH&E3B9{KEB8)5-fJ$!ACtXO2x3U4>Ndlc5LdfP z7bYbY3*4;TH=L?(^H{VSN7(Ksu4ZgzWIOqn?TOai33pG5bRVx?bt1dYUwbf}Ssz};L^p5@)jL3q{ECS}2K zogzQWk@O90ezoyR7w5wl)cKDKOmvhr!MB`L28MMjNoMKZ2?~@C#*^|X*j;$lwNot< ztDL0w$rMj?vrNv7_Kx$Eik3RcqxvsdqbE?F>r#>wSwuJm_{ohz^wSq@=i{>Gv)Z04 zyASkhyMw$diD+Sf{B{0&k=Ye|Orpehg%V^zOM|XZMKNSZ4hDRsq~%ItD7Vk7w4ynv(SCGF z93biPoWMPK>!Yt|@tr#(YrMG5IabZAVr)``m#d-v<%>FTa`Sg=OyI#^PJUH}vLz;b zv&qb>wI`*o)kOm`KM$GrkXG2)70j6`2)$uySz+UH?u$C(z*EpT!yymnSUgv?E*uIF z+}iX{S`aD;z&bUm74d)AY9Q8GG752HVF9(EoBP}-Wn2`*>t=+uMLim#FV;L@4Pr({ z24DNmxO0izm9)%|o>M3p6=_CU*}si`>#sgG388%ZHNP(dHnV>2SNoi9+=w`F@>Ca! z9TZ#y-J%2yo`T(%_=i3Epou2j;%t=&FrY~3yR}SMfzCS$X?R$|XS-*}S*0@Z)q+>a zcc~<Yu6ZoQ^)W5*(YK1xq^mdUdwx$OR2&#*zEd4R;%x=E7v*KhU9!$nac-9{yyu}8&rTMKK?I)9EP z1=-M?uNQ%(w{x=l8{dw->I^))smq>Vy8Z|mjif-%=3lHr=hmnYdh-q*G?W~ z#vCdoj6YD>+BC|VG&z(CJrHJy7FT5F4;qme&|GDdW7lI!vi}}io zF#hBqe$KNPow=)XJnL_b=hj^p`=cTiA!Uy&_)Onp2)J>6=S==4#~GKiBd>ewa`G^O zUmCZg&U+9g6O48F5YG+~{910GLV_?cr5~bPtAbVvAhaeG9d*@fHZhbX`e|`yCPmBl zr`>esS6LwW2W1Pe*`}zfB<0|Tb85KXvRvC4^UbK5Fr3LAeDr}@!GLFZZacGzaf094 zJ1c9H*<54!6vzC%xUJ05SN(7|uY#tP&Y6!wcsBb_T-}~kMeac%g-`sXpSF%Wb31d> zDsMLHcxvXh(QKevE;n02$HldSlvAv~%#<;&Ogufh8z|B@>m#~!En94JZ@Os}O%o-y zBbJdWDwM$csGl`RGdlE;dESw; z)9Td}zcN+pMhIr2f8Q;Bj!|8nc)!DRm2j!YbGO>M76RG4M2rsbEAnov{_e8JY5Pep z{>LjuFO)1Yno-CT8fHlBLl*dAfHTXx;q#O{|9l@2<)fPk8Ee$|*m8!_1Mu9dw5edJ zcY+U3Ltc4YxAXUdbN3A8#bRq4Tm9&ix1025d!zkmlv@F$J0&(eE1OE1;gAp9!|=r` zN6I}vEje`>Q_{SF{x|I58iU@b;IIlm{Q3HmVd@`KZWbwpytDV*J}-ZcP=5ND#)o^^ zl|H()Fl4(h&EzwS%xUXg^=iXyV9)xoABX<6jfM{r-jK;RG+N5fNun=Mjzz}Xs%&oD zvM!NRjqSyvJQP?fh+GZdJd}Ps2oTnwi`k934g~Yg&)ZpNqK}f^afLdJ`%!~=4d*1V zEiBP>U7oS_BhhCeRCd~h3X9g=ZF1Z;iS^s^$wLC-&87{mlZxlMbL}tTfsn_(bfhtD zlbB=$kbxx+YSDFCCA5{RjH3LsVU~4p81KXJ71KRS%$%%;N2wfks+mc@{`En9(W|aB zqMfg>vFvO90dnDFCnVjHJ(I^Y`t7m0N>T{f){p_Rfvw3Qy2W-zH${YCz3VNm14wd9 zqVcp5TVXvLR-|I+^mE*v_np|GTxJ# zDBpwiCMits8ITW15)2h~#ntSH+|Wss*hqUBjly~FUMiZZ$3|s{V49`0K<{p{3VhFk z)+}y{!^m{!HsiOSu~su67!p~0--v-9F_a?YN|b3Q9Z4|_i~M>|WI&)TtW{V1Ia_&b zW^5_5qpR!{4b8VWWO=8}#t!QlCr{hwmFqr9uf=@wXr}REr4U5kBWU0*HDAm@Y*;KL zkoO;+HuLR1$JG@N!FnwJ>$wVJmy&+B;M2rBrGBMv(%x-+j7K4)nSOaj@Tfb!VSU+G zC!)AgWwPZpTI;wkD)ScKBwyYi7u=61tN3DY477Y(>PvN*-`if^>R0m}Bg-*J+cJwF zdX2Vu(@u5Oc%%o4KOvF5{=~I8)}@@F!WymDpg+iIJc-czV)GRy4NvW<`TG|PE_4cN zE1ZjRltOeSp$xoq?S8m(_|^A6&9>G~tiv3>r2R~GZV`R&>lXi*;Uc!D(;VYe{EX#L z_%N_MAMC>r@{*sa{aZ?EUUM_vAS!a`7MGg~;SWt=JE52FAr@y395}oolkiV~z-{ZX z0N90T6MnwdP@s{M*y>_$yr7QGX;8YGwCq+Ieu9&ZjR$9XSeiF}N9nAg%no}vc|I}5 z0cxk0sEMM|UCTiCLZtM*bRCTqXfq8o8huhD)L#5d?-F@x%4k=hiw~Dr~5174_;=l(i!$aRsOD-L5oA{EJ~i><~VoV{O}oo_vK*vHA~EJdBIG7^2HhPecn?BWe(}j_fkHkZ>PKB8Gm_ygadcyR^O-csmw}hAy1KCNIy{o^R(?gyJ)&5w3G+L z!MnE>gdfW*`Mu5U*q=G+`opzD(Of}AN3&yfk$Z1`=76}*fXm_pU7#G%IZH+-kIm%N zA=GxB)H7W%CJvKcQ1%nW>8-wq8vKOiV%}ZRw#(2E{Y?D6?vSuBFJp|VhoDW)eGvHXC@_4OulWdT?N@nYCX8q3~27o2%R_x)u_`8xHZ?U+O8tVp;NryTd`qsSi5dJ zTREp0h&2ZD+s9?O8q=<$GppoUAssGdd%RUa!R4<%Cr+DjD%?&$q6&A-EnCn}Y50+e&wkwB+h(?} zV(s<3hXrDI+^Ngo`6dYV!T=;M%oF(j;||g~Y}_k=)r@*i&Y+@IZ(xHA81cDMC9*juDIvH zf#Zy?ln}#*(HQqC$!)7dQ?^&W&Q2~PLXN?KKD z^uewBtZRH)gxk}AC0;OZQS~g$V=0CN{(rMK!))6lxTPB>Hs7Mo@U04Ia22de#XGTIJ*WKgju>tCUnv+ld%;~~+8%0~8_3?5LJHh*Y#`YlnhXv`JI`2-=jT5!bW&C zz?pZJU-d#pEw$zp3HO{w%b^`EM$3b%R3vaNB36>uaqv7yH*qS zwZ8WCp@rgJ_e#@`^gBAcaK0w;bmm8q5`0lNpj3AjZ7XIAkAM5zZB%U~wTI{U*$8g+ zeKVS1=)I6+EnN(vNoFxi%&0$MSj3Noj7SD)ajH?+J=?@RrnXa~@lZrO={rvYpE7j4 z{z;5`w{g6snvPAF6p&^OkDs1F(!bwrovbb5oju4t=&@aSY8SongKW3GpL+S=K^IAL z{v`52{=onzof5(ackOpyoGPC4NV*W3b2-%WqPvX@6(6e6L@om5ZS(k9GFJK`1JUZM z7Z1)#{GRD0qvJl@+(jrNM?wnMkpnl>am9AE_P>Pq?B_Ka#X>jy6XyCgnH+q#BFl8M zGTd)pK?aBK5_m)3^cowx5+o6RA=r)_ArGr6zOLDO*_yRSh&xj`t>(FA7#glSe{#4Mmh2pDy?n8+o42#B`W(t0SgI32faG4_bcz z*z6^*^7EBcXOY=#)jSNayfyQ-l8d<9o;a%a?NrmcN1fS#0i+WXFd)9Ot>~t??%Q=t z_^r*x`@WR$JDmrYjZiY09QeMp8CP!R_^128)`@gXc;pSXY1xIF-bJjBnf7{6#a^Jm z#?^MMaOfSSv!awZR5P=)tnb%Hj>ANhff>b&iA@L92ePLn^z)|DN@MZCNj1|Mx><`3 zQ4>TGSp`D-3xyiBO83Q91}_frc1QNFq$|7WroODj$+MMs6lX#E(=C(znH746 zGV_l2F55g;F?Wbw4=5LbE;oi}RnzV4uS~NKW*!7@$yz6TgJ_Omz{rC~RSN0*+Yw0j z-Av4`*=kjB(WF%UjmPVI7U-y6431oO+0g2(+2V~Ejg$mmloSvCdKKe*w)2;`9Ij literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/sheepb.jpg b/contrib/ntp/html/pic/sheepb.jpg new file mode 100644 index 0000000000000000000000000000000000000000..1b3323ee4c04ffd79133287b70d921b2eadb365a GIT binary patch literal 20295 zcmcG#cUY56*Do5nf`A|a1SwKPy7Ugxn-qaiLQ{GOA<_ke*bwQ0^eWN=AyPsw`Y1)3 z)X+icML-C}gaA7}&-=aK_nvF-v(GgjKm#)qL!fv#SX27djQ-gC=deo1(4|KA6@_%>G!Ya zA1+FIc0F5OeIK~XLm%FI5Kpf_h_5HFrmv@u`=2zFB**`56S~S`^zhL`U-tla z-v7)5Kub#g50U>}t0OjTxDVW)*WjU#MKePyZ`?z=@Cim|68KiAm#G^ zL)_nOaEV$!2;%1cr>dmZ{8I}6`Q3jU;2#}x(}OJT@xp`M{r&&N_@@Q`iQ}NQ^ntkk zlNv?}{HOMRq5*(W{M}Ia2G8T>=0Co|4qG3SbA2UHtF9nq2^c zrW@SF9pFadBk{}vUIMOMx^(ICr7M>&Utyx7rDFmzUb(^uWWRO|cJsllA1N~J7hN~8E6fawyc0=5)nd;oGLG72WLi+Pd) zs4u>dX^^C(BKw<20{4M|~-Ix9?!v9$Uq5l@)Vg_)9;_ot< z02+Yhj_C|o$zESC=3VowvwIR*Tl0!O>a7*f^Stv zG)1^AT8ajkuu1nFD1>>GQ8%oq4V>{S=r`;%+&*$}n5&vx$*JsX>9Mh&Z>ldaExlu0 z%dj_MHPa5QK1UoT8JdRsi$CCKYA$}wah<2{xb?ibnYpqW^W)9Z_RT6D!`af{9lyDC zm5rZTExFn3lXkUkdb8}y-=|!;I>*NFgRM+{j((jt%)2|*W6$B#E0J7(5$w%sD@Cr@`hiQwVV8Dzan?xTnoW5>Jov#pOJ zhBQj%)@%qy7l7>Q&R@d9Hm)nf%XY_8a_IxcoeFayFyFV0{;t9j`e zhYO1Kh+U|LM)lu7sRVlQfXsRRan7Wgp|eGt#$TcgJtcz}^!rZOQo^UgsBQ^ZqYN~} zYFkad@h~_taqm|Sv*pWg);)^h*-LbHZvix}pUBk^mw=d=8{qHX9Rxy>dGge;7l3hz zm$k9m46dRQUR9h_Fu*15(wR8z2z|xKFewKd$ z7@0h05>(v@nzmmM3n=Xs=gnH*gyjvc3KpgeJNZnBGRkZw4MN)oW_vINnJGqyi{a&c zXdS0ub6V^P7S}l8yGGWt364O|pC;;c?ljxTV2_)8UyWlYZuTJBCTgl@TixwDbBYe- zA``q^T$$+}aD6H>7ur9EJuJ|dpfT&1b|yI3hc0bTICZZ& zx*pez{(x!CUsvkPya4#_A#eu4fjN4QH^0l_2P!5zIT~p=ws;Dlxw`kJcNX`~0}dg= z>&GkYXfIdMBTY7N-^?sG;AA%(F%}--q2S(tcxh99>iTf0Wzp-wgYZhvHnhEz*80b#uG%2OKlj$BOuIaO+|TTu;|8h zz7M9$?%7t0Mrw=21c-3)9SP`-b=tb@Iw$f=kJBFp^Zh21=tcn3kNH|gPiOr+6B<1h z>ZEP6ULs7^D!=G@?4GnRd&3l)K5I2rbK0r=t&q50nv%_(AD}%CW031*;}o5nA0$Hs zG$LM&aa%5H8Rsy@A4-um#?9Kt5>Jb2_M?D0?6>t`nUvBQmJVd4WF+u-iNwK(Y? zYoj06cHtZQ?VhKVJo|_u(58nP=KkBQIuF}3yN)7-R@?<3Yko^=$dh0;Dp008v(s|Q zy&)N%`~B|lc4Np~;t z%B&Ym!_A{lDnw)aR2Shrbpbd;{L0TZ@;>v}hHp7LOZgGfU_D@mh1CiMnS%2oV2`i(k z45D51+hV=rwq}g1g1@sdt7tvS-bTY`3J5&E)T4_CR^jK>ho-26G^}?}ghkuk5lDAc z!ftg22&!Pa7MY0b=#Rvz&x+P2{nknSaRG?mtxHbJ9{~SE%?k~C=$i&TQA?NpupWR< z2VwFT7tg^3zq_|4m8%%u#$y@Y%!R@K3a6b#Gu-Rs$2?Z+-CDJZgy7_c)Eq z+G@NNyUCt#3~~gu6#O>B6qjif2gS!T?!!~VAf6Sz0UKL75%QK1E=bf)-HC7r!HlrY zcKx+Podj~j50-?Y8u2e`Gh`jJyYqJHQ~<7@1E+1 zo@#7sl%5F@MUWy0qasP3YwXtZD`04zqn=5YV!G0^4%7vpF!-BM=b>D289L&w+ArC+ z=s`he3hB8PHGA&}NeT6S07J~#c#7r4=qu`Z)ZES&vfV(6iVMJ3aa9M0M@~y*a}ft_ z%o^e66#-3l?`>5sb4F7}Y&*qcYjU6Kt9=ic-6$^ee82o-`N+GL?68qdwkZ;qxwS1( zP;wf7#Fl>caG<{xWq%4fFBzZToa4mTV`eMeBlq6V6yS%Bt`leWveIuX-n%TJp7WxO ze-q(O+YvVw)@W14$@dg|T2*r*EB$Sgy|ZLtXCOd*h^X%t*0@*OdLTubGE;Kl`+4IB z2g?5w9&U#J}M{s265bABxx!5nxXI``0E3QYjc>_m20hx3q zojEWGf-^x165&-=%JAVlYhvmSq~jGPPiy2j8Zc>-W+_sgedcUA4m)zJov9Hi?Pslf zq#RUW!w|_TwWX%Qy6zkud)$CLyXD}sXd+L?6QFidn^Z4@PqI8`95)J;+z%<(^gIIR zc=`I8QoR7MN4J+vgkL|4XuSaFpEI5d`)5UH%kWFg<>mj9lsg$ z6KY0VY$}ovC2t?c=PFl*SB*~2+pEv)nKY^Z(LL@@gh6r9$9?{f_CD@}J4HNBwM?Z5N9 zJ88vtjmFxJ?D#Oqj(7xiAZKN2r5fxM=7=$V4B|(ePHPUw?K?*iCKrGr&tdy`-|XVj z#?qi)zYM_v0%j?s@o;Rl#@~xQRKCds)zE;|l*TH|9|ppUHxB2C7?+_!M~|_jpN~E$ zW%In>KXf~XkJ>5zoCc*e7ZVy}G2as?v>UN&XOiI!h%s>B*!Dz_CMqBw`a%7M6EDH( ztwvCe=}rNjGIg$N(9er9nx_aYQ9!WQ@C!m%9$dG_ao&fS`3fdgscd9ElAIU9i!XK( zkG>uHKFb)F^bohUvAY1!JrqwTmv5YIMz@B)>bn5QgiZ8pWZ5>~Qw+tpyDzIaYtJ?q zZ@bRx4!Jt@tEp6y`qWvBFm9-MoRDPR-#|PY?4y+KZsYnq>iNF!=lnTST9O&!xAQui z-%%ZM)iuJ3&>0i`ppin99ElFlB;12Zl(SueI&I%ZjGeIL9pe92D~8n**)#waBeD1_x`ATI#kn_&?^TVGz^z{ash1o5|r z?VV;*I|(EM6iQKwUDh*KPJy!0(=_NEOI$3h;VB8EeKfayn=xR) zqepFZSKtERjME6Je28Ks&a1jQGQCn+o-x*sXe%xzYe)nKa`S1$z>F!#U!XfM zXPBP+j;dSE-0S8``q?5AvlV`vg{4D>SzzkC!A|ek@@0Xti;1-`lW^f)*Ymf>VK9oj z;N@Mq(yl@j>r*%8`NY=+MflEaWZ**Fq^Ow0=Cp~#)w2mZazu!J1mh|Ki(Sw#+2TJR zaia%d%MxggEi6SuU_l4kPjA+gws&M;IJrka@Y+eKAE?mws9J}$nxBQw5`hid&aPS3 zeGPEy>(SXdH|$^j#_kbgMU~xWUnI)4zDluOe)s!j>i0%YWY86<(UvGHkjasJ^v|Gb zIa$o}s)UXgei1&<>syNi=XKFD^30yzhzvJ(Yhs+F$DNK`8(;Je`->5e(E28YQB2z8 zp+>;Tq?wJ`hn*wgQ1S2Stpy9?qQLJ;)o<;S(x;YJQj!n-0=A&2Dx2cF1xNm45vB-+ z8Nj1G{AZsHEl$n{Of{cZtiDwV&FsAq7WQ0L`_eid!}~Gws(jC=RwOX0ntaf}i^fsD zd->bCC>i#Ax$V%@_$xu;G{u6=^+n~&bE{;ne`lH4Bv2>u5` z0bKjPaPR`;0TO^ae=_{1Z0ajU=DPa4_k$k(DUuWpp!pkRB9(XX-)PI-KMDRuTgd-S z6r_I?lq8>o4p9CfDr%~~iJF>*<`NAJ_2tX7v?NsKKZ%Tjf`W>Y>M}L;WqR7nwDgRB z&=y7#W<#QXJ+A!o_Mhqg{q_&qQV&R=AS1yO|BbdVlhBs;f5iWvU<-hfih`V)4Dc_s zg(U0$jQvlvg`6ZB32mXKp&)tW0c7M9Oq2jB65OJBpZeNE65PTfom@x*{0Hs$A;aqO zOThp6zM!_OWyn~Gv^@{7Q$3V9^4wi9$ z5Eu8LsI-4jm;VFkqG(|2_4svWc~kGy#&2OILpw-lOjbqn*Xd2Xh_VsbJ1jOE+0r+& zMfeAup`aqElbZ4p1qJNi0FfrueUik~e$SGn3u}I{d>Z+|uLZPl@!yvbkkx+9nqn#V z-nI5Gnt)NcC7l;+R&PmI6#MmC^12*CZh;_$gQB|6w}r=+aW7Mg>;F?^z5js}{ZF9i zKV<%Y5&1s>9sK?p;~;!!P}{2G#kuulj_1>%d&8xT5n5Jt@)f;ua_7g2)*!OLE6Ii3XbZJQ+bkeoP0cZ1bz|wY3Dz+ROFP zxL!|NO168WG#|#0Cj~M#lL~80uMCI~AJ>{4O(FagUgtH}5)`p6&R1Egz~mPNK)hE6 zJ{YA?L46}z=DH_@w^-3s;E^^ztBq}#2hydcQCiP(>#Z)IA+XK;g)y@*iwd?hI%zDn zold_6@*{iEGJbac6|=*fPL#EKie>$fRc|iK?RT;QE>#@|`c%4t@&~XIGqU0on)utQ zkpteLQG$SzMPLXzg7T4g8J54frcT2lW;P9ZJ}!IXMP1Rgu8QVz_DU)&#xYPJgFI9` zVNT0HXCljHMIWyShg0UJ$aE)=Q~a7pFr;|b1vU(d zkra2;*j2?HjV@R^-IrS8xNoFpFzbh7M_#jRZn2YN%_khF=z7FW=y_z>rPrHlQUz~Y znx=KxPJDJY_Fw|V^H?SHXEh;3KHRn&9%mN4f9O(SrO;Bhja_kY)VCWoh6V_c^9%Vi zd~4ct0Bty>T>!9Gc#3`1OEj-1z8F7J(;7!XjY76#J1>Uu@)^}H3i$cwy0>f#3|gt* zBe@9Aj$5Q=fss*;7l0x5ZLnbD>QQ$YKC9FoQjq0j**+P#cz8KfAGtZ>6V|dBaQ-_g z-QJa7@5fUlPgIS~x(?f(--FU0Z^!j@*vK-eq@P~^Rv&pE()iB0lxMjF=c^=d*?%z8 z3%3AHN6)Ns6kRn7Xr2Y$t z+QS!7;hfE1*Ci*uvGPzw$n+F3-2)wIq%Aj&spb_I2;(DF_S8b3FW4t|PBa=<#)+#N zmc?yhKMV~dxiBnG@A7}3-phHz0>nDlrt|eO=V%<3*!1z1!-sue|MnkT) zDan`?z5COT55N??@gTO9L3Kx%UHzVfH^&M=ph9i1>!roLw$+C`dwE_Cy#^qPpOZ^0 zT~3%)F4dWNsH9Lv(2D@7p7E&F_NT4+3m~ahT}fH5O}=;WV?UppFo<-cpP-TR`Vk?F z$(RT^lOjCi?q+O6tyn+d^K!E0w=HRYh_+|pOKH!#6Y zhZeei)(UHkqMVl^=vrAFT_#-Y>pK&$#$h5UDau5L=Pmgv!&gQ8tk7FBa2k|k*#M(u z+*tIrPM*f@oX1P(i;>^^h%m{rd`lM7uS3|iv9~}^=4{{Amt1{MT9?q{K%C^-WNxQ$ zTign1MHZ>tlzGsmZ#o;yW*TZ^r(h=+`q8)V!)!R86eh2Z99P{Tc%i@&^#f zCuJe(l zBYj`ouWKCT{_zBb{&dM}S4=I~<}zILi|?pX^6O-9`4J6l-v+rk7_fF54J*P4M(2nj z^c)7Ep@G$Po60Y5dqzEb!>@mt)&(Bl4V@bUx^X|8@D-C4m((8v!Jah2D+gp@GLu(} z480nD5fV$~ueH{(rf7xuR|(&hvZ(=wHr~UToL7XUy)Fhjg!D)7sn!?;8T9e@y|%+L zofcP8%knu#6KdYhL-cV27QB_Ro z*Rrkje4jC&-D;pg`lW?g^VA--7aFv~I!ZY3c>8VP*gCl4%&bBt;*M-He{J2^_tvIZ zqKqF?c2cFY3@BDajz5y~jo$2Y;5`WeN0DVG4hPis{PdQnAM)-O5iZetF|4;&DW!gY zmE|HVq18?7O~(#7cWANmt4$My=_-{jmcyt?Zi_+7Z>fQ*tWp-X}gY3nv zk6|E`y#YtwLILf)iU5Bm*A$^=_dH@K${EL!G;7L1tKem z==qElr8ckPNA$l?+QH88%cw=Lk7m?#gKK1feEF; zjOFb0UP=tc-+&LYOIy(nc3TAFjT!6QMmD&gL=n_&c#iOT(N;?Ei|IYTmv5fFI_jfKxCV#mv()r-HrZg1ns6Wt>k+tIzZ8u(GQ`=C}pyye9AD6r$)B9TKc~R1d z+jB$ECL2d|I&reh)@jlEq{XzoY$2e-c_hCyFKCO`&@JIX_VmP4D`bs`y5zKMms4y; zhwhlHy&9eI#BTbezI|Y$jP2!)I_U-7&;TKRF&%C{0)$EII z+TKwgek!c{MHyO^Kq)N3mNwY;i>!=4K}2z{l`OV4;?`mx*dvCk5?^OAzFSUI^?J&uj(@7k%c4 z3k5Dm@l{x_IKOcMQKzaaR$gIcB2=ewH@Q38XO+o(4LjrVv$+_ zQ7a+x8?}aT@1>wuD?;U~E^In5g$=%KgfRHIm7Uzjw%2zgT&F@^-%(cdlN9jBaw=5Mo(j#^xj()*42w!=f z+*5k{@PUlBkj&@gux$F@yMCYxzz<*XBYV5*on^-D&m!kr0qhTm5xnZ`8zOW404b~E z{$3pRV2k}ny45p_*%&$>N_WQ_)P<7Z{rCIm$jnOR4+lYWFjp}#azlalTPo?)9+5sA z*RPM)b_<&`OzgzAU;BD))>wn}<=F=7X6B?)&ko#N7`?r_?B(QTCH*RJ{i}DM3UMN= zVEm9SPhDI+g6->Q0>}Dj)1-TQfO^?AyDa{gJe$lI2Vv%l8*U(mc|TD0t+=u+ebdxM zynNrWajyXL{Gfoy&1Z!{%mT4n`_iq#l#F#kGko#L&TL{!_FrF16T`pq z;Q70=WDB4nT2{0^8*#sA9e%yBAz593ODi)oNPuetve+TgODtOR9QBcn5GEEDJANt@ z8T3198ujc95cW*5;J=R=m5X9NrT-I_ABS>efBf8$JeM2HTY({j!#aL22lhI>q<)7DTAC> zkhjVW)bf=lr0%O~3tJolsY`RC!p49mJE}D|?hn+=noh=jS_w?3W>&n1baYO62Tpc! zgTj)y!7~$vB@Un-AD50r~2?EIA#ShXV}B5)~e9(H>9)d`SVw^1th{ zlpIEH9s-Y)ew8jst`hW@Neh<=++_NWYerJBKx2y1OaE>+s`=QI6a~g8?{^eSQG+tAP7TGR{F<6zbJu!RLj8wUkFomh6O4~$Hv435R`&6%s@=i)&(F95j{IIi_o zjWxDZ3^XBfgjgq^0IML)YolU2@0#Qhw(i*r*WINfz)DQyI4SvAS~*%IVR10bBZ`K& zEMHQE8APwNS68g`f0J>9Y|GmCzg~OEDVx3IwUVOEA^RZqnl-JVoS;n?4{on>00qa1 z4uU7&>=7%A@ujnU!H6ZaeCQsCI&`Orj6S`<)%$J~V}<1xk>Te*jei1N3UK-PkLro7 z#PtJibZKZG?pyl0-pElq^kCbjDb?0l=T-n))q|^L6UDL+X5rgI^m=oCHuD9z1dfhI zd>vjHA+0+74i7zOfDb^9 zlG^!*cwExDP?l;X{vq{?)jd(X{z0oQ$Kc>`YVCP)Hl2ig!^oVOAAb#GEv5FLdj5n` zrCOmS>(<2C%HAEnE++3#%}dl@;v) zM#NkI6z}7o;p6ZaycsGI7U>tdq>?8z=;V^r-{IK$TokJG{S`Loxjy7aJnc6%US8PU zh#H$!H0ij&y1)?v-&26^l~jjvYi0Kj1_z&HlPsf`xVtSK2I8nayAp$&q2_v@wmD@I ztw8+8aUy3|NL9N=US9|DVZh1ot-9%=kQLbw; zYi#6Tmeu#wKx)F3>|^w;S8Dtag!-$56Vg5xQ?44lsg zo$JhVZh&5u5!V&gsGHZ%=$vu!#~~bQ#C_Y)7bf)$OtWIly-FsO8rK9y7>YGm&%saq zY_?wI6@4|Ob(~0c)AF*d zy~A|RL>0Zico<=2SAbK$$DgW90wbeI(137QFnql-Mo!U3&g|Dp3gqoQHEr^qn<*A9 zD^}(21Q;etMTjCq09C5r>0JobyK#w;q_=b+=SaRMNWmK z%-aP$0>}T>$ba%zXSzlT$KGmmPIc*lUdbw##$jp$lB#n;66N}w=Ux}cw(M|5DLDqn zBKuCUvafR;+u<{eQk}Q}C|zF-Kl7{KK@2PyT*G^F+R>UxPZ`S$VZWIV^m$kVp6F1R zW>(_1agpmoqxb@w(YDPBL%+~sqrMR{&RA_3xxWMqg?jWL5jx;!+QS?ZHrql4oiZ4d z&n@w<>=RtI$520m?4g&&zj}t0@Rtz#=s8s4Jj&$+WPQ!Z6C6PJ&m``w z^>+TR7XTb-t0wu}7Z+Tb9g^;&I#e0tZ^Bn^Ujls`pU|bxz5rSsrk$)7A=sZsDuk{Z zI}a`1IrFp{uO`M-Aa&o}!%6a348?A(@p5I$C|P;X8x+6ey%t-7!2R4CyZ{J=a^k)X zIyvK7&n)_J_WdEsLK$4MW3Nnf=CmI*3|s)bBHX$*yC*0zz5$;!<4=pX^KFU4xQ3)P zaa|1OhOfOFUh&|M2OFDa%X3&V-8zv*CIU7Vrc&Krqp)2 zul&r=fnDl_Bb78~R3|RF!>q#YT*M#vt1lQKqa23wDcm>j{37Dg4z zq8t*TeQb$Zy1-odGg@@7v#gn)AZe3HNKI=jm(8Eq$x^`geu^F}CyB$#2jT#_Lu@=4 zKli|urOHk`H{8L9dw0*6iaaiqxhY~cEp9}VLy;*~5^Q6;Qlvhs&pnZ?l4B}^4|a%bF}C?;-5A9fDS#=j!@cq z={=yjHhbf^J6HN;y_Jfnnfb$DEzQ48gn#9N_M?d_jKt-}oMN;~s3r2r&KQA zn;MT?>J5A;nVq^eqTjq0f0owHJFDvU?naGO+`;nsqrHI^{dIVDPYPzx8HAHuo8;e8fp`Nn33a71SrgqIKQY*Q@Wc+P>A;xxeJOpV9o2MSKZzOWhsQh`Y9>e1qUv z=gqfvH%RF{rp;(hmNtgd*!In}ZpDul-hMVMp={@V{no?8JbV_ZN8?vp9ep{?RPAq7 ztQIMzh)(CPn@lp-7L(0He&^uoo}+u*3#Bj-IN#NDn5JO$_rmPA}lYQ zxlEfp??{&UYn-89%tPI?{CkyVm#zLPnz)>phNrI%)py2qrbb8(*vHZR#;9@H8sRID`*X;nJcWZWjjvpyP6v8rB~zhneT!KHxm3bJ7T11w z(=O@M%e+8}48KnQBMa|zRlA(mJf6TOFUtQ6k9Zm|j%}sSY15`9GG{G8$l?Rea`XMt zZ8qy#DP7o|w&Z(|8*BHa<@+{|!euhw8jyT z5V%C1AN@eNd1`33bfo-)#jAjL5Y8-5gBKwTJGub$)5}eZg^TMp|-Spe5h1$#ma+q3)o^DRFd^v0^3HfNaUb85kNtFsL3R>>53$+8T78>oSv z(2ypQAM0i}@to)WH2qHA#DYXDy^YS8Y`cqS5ezsHe{!w6*53J3Z*M6m>39W9+KCP6 za`q#&Io)~ixp!nlXaLS0XG3zAC7+b6zP@(%L+uBQiMlQRi$wMAt)|yj1gWH#vDq1N zl$O9Jq-}7e=5;iGq&;Ft4;-3vu(q_Y?sVYB5m`O#ZM_!+5hM=l%jKPY$Xeih53+l4 zN7(vS8nDaR1u?`#DpKn_05N2Oj~?m>#5Ht2P(|bI9v&GkjqT_rx3#rJ^;Lcliz3$> zov>o@cE!c~&m@P}12_$^b;5!Gl#v0X5oSCyJ zGJ5YS$F18UfzG;!Awk5D_PGyY$STqU($F$gSR9HlB(~O^$)V;qg5jRBqcVg$Q`fe3 zQw}OqXo1#bR@qTbt``7}8>D$zw5aAlEZY*Zo+B3rGm5xxRv}*h%WjCO3$yd-k*1;7 zE16DamI-<(o4!T_uE04r()}PRBUKI-Zsf>3Gb2!6KX!N;9(vRMj>T=%ve`2=b-r9Y zEkO7l=o(&S?Qz?Bi8lco_kLzBwCCQ$JtvQ=I`JOR(-;Zn-{R~#?uE{C<%LD!^nNxS zj^|Eu`0U96vkE-?UJdqWQFbac{eZEup~6*ZtbV$F<9&)sh5ltqiyE;T&yAUtT&lvI zNTytPGq(OT2DbWPg!tM2`5Hn-EmdYwZhdC$F>n0DQ-LU!Ws~jLcIShhgZGOEhjX&v zlI|k0RVTyUOEI>;KrVc`Afpc&m(UF&C+eh{j3!H z>G}`GLS7zQ9ZiECD=0itUv-fmbql|J?rg;;5gqB1Gkl#g_t28p1?#Fg!Ny@7?!+{fttzzHM zQ}d2Jl@MI2bxc~!Z#x4(bZ~hY*E#n~D(6~f-17ym(Or_E47dO&)N6=AP2lU_L_^=2 zH@}jO;D?5mga4A%p)%hVAk9f>Yn>H#V9j6!C)WGG$5;%1{L{VB z%*sPPdrk|hVqtc3j;B5b<)!nDipb=K1YmU8mqgVK1=Y$AzkrI!%P4_Rqf{rcJ}*e8 zYYz}U4E8&0L@6FDbg)-mjIPXZ9lDyPEjP!wOTU*&=zVQ)BSz`AQ1T6pMqs$$EA-XI zqoNdpgzeVh@vO(f9{fQ8cjX0^&<>-RODI>?HCxmu0~yP6`Nfn9-nYj{RVmPB1x>!@ zby}+^OuilqI1m-GITq$pvAx~Mn!u9nv*q5-W7&quOy(Mw7PedR0M!0eqR@gG1$H@S zI_GNO;^k$$E&!QMk6&1ho8`)O4on5Y^hirsZ5C|UUxWq)u{U2t4s`lu3RoBDCz!9k3gm5_30F0-?Am5<)ZA!gnuL$F( z-dCXg&UH58G6kck6Mmkw1-*bzLr9ezthGzj$I!mU2%B`}%?fyN#n5jl&1=;@15W}Y zqDVaqh36`bG}&@`GAbLcvZ#FSzG%i3)llMlFgvrA%~}TKI!ZRkdM@Z~TSqkN@4YG< z+u=hR8RAJ!3ny2dhmXcTBSh}m;DQ=+$Gushz}nAh`S1D~Mj0#psqYT5Qg|y3vq$?X(CA6w0|(t{va(ntA1O-t2>W|%4-j$vvb|kIMnsfRkU4w@+ru3 zC4{(yUfs)(OA=p zu(*%%v+@TQmqyW(3FMzuIDmZ8{g5$0C6y;4?dKBT1JSQUGR|yHdR%+oeD`xE7al|X zftB~y-mclv=Cne(kPc5_b}lS=aS|il?^AtYT9LV+9k65;pD|qPz@p&-z}}QC)$M&J z=*LaXMk90B;SySJ?8!DmA+X*$<#M5aguo+aJu6DmrJ2z*xw*tlq`HQj39zeeJM?lq z;4KcW`9ScQ;6$7hihLB)Wk;2iS^s-=A}Fph3p@%@nw{=m8aWQqd8l$#bK^T;VA0L` zol9l?M%$-#Nf~@^q#ZQ7wAn8Jx@sIjXZBph_;GY*{cI&CMDj}rwWZJ{*y_!Z#{j`A zy#@{-f-}B<<@FJ~53Mx4&F$MdR(gO=v%QY;i_v73j4=u7Of@sA~jEfIz8G8eN)L8`Pvr z3M8pQ8YBNw{kqO5)L*Q>;w-Vj7K|OKQcjP5?*-GYaAIUZdSAT?zVi{d(WfWUgODJd zpbx?SsG9jiun<>;a2w-n(lw-I)#S&GS?i!;Hf-RKi4-j`uSe4(!@1h`=$Ud*zSp@K zE@ChJ&^STCy8Qr)S=r$`Rz&alh`S^>TZTX0t@`;hE+F7~9fYEV+4yb$qb8(g@n%8x zRebe|SFkdsGy~~f{K))8uD3Ri>nhz zX%41&j;6gWtmnNKTNxTM6p~^_Fx`bXx+llZ+<5~s;_IY@$MmWY9ZaNb%IvnV8Q$3* z6;STdI;CW8k2}a>9TN@>=6J?C*S$m!{?A79JJ*(JJ)oG4>)({Rky!0$NcZ&EI zL3Tnik(XPH&N{a9+EJdx*1CCPOH72VOQY9AQ<|rZwC0y=lGOQ=c8HDy7xc#L*Ot!A zPSMWw8Rv8`Hpi>cZyImt48mAn_O~?eO!3N}x&JF#oA(ja%%fU_s7D&p=14}Oyy{?8 zXwSgXWlX11gkw+uoVG`BW@h&FgXHlicdUwJMx$Z`(0754Z%$N;2cFup+F5KZ$Xydx zD%#V@dOVg);mwsOa>h%VU16d6Ryf33XTEArfI?ZBJ>FY!7xwM1y&ykD9ii8NDBG-$ zG!JH7(9=Iw;x1X=_lZSGm9f7!AE$T(nal{d2O?Lk{eVqY9T~5yUg5C1Ekw+I;Q#_1 zdPw^vy$#E0C9`xqIXzuM$rlJ1-Qd3rSgAC^KtB*5v89Ve(@evM@llUw{olQjFLT@n zF(NhlM=MsHXi$$2t3^m>b|>%;@!_Z~*2oY@eRIkTe&^__6EgP!G&J3yUje7z3v1r# z5E-an-U^Mj@_<-iM?8$D3dJ5PJx!addMO+!_Gvhqxis-3vSJXO9@KLny8yG@ey?9C zj`XH)((3!7f0NQ*YZ0(?*_xXj`Eb?VzCWol%;F5Z!=WGVpm^m?U(Ba8+X*v~k(fCb zwDs67Sm3By$j+n9vmw*5=BjKTGI%!mHo(P%3?*gLh^P40cmc?8@;*T41pY40u^GKF zKNUs)m+j*_DKcFq%(^Q8luG^-@;=GRXUOO)$O=QGA@0=gC|FJq2iNGfyd5ZLe(^lj95!ut|0<(&ke&X=!;wdzI?a zOs8R&bIT$L!_LSLV#I&8?G!^Ot6~Dq*@xe!>TPN z;BqF=0sN-mKBO=3O!p^0Ukbloe@2 zvW6qw5kq&kGg@rkMCB?w6~F-4qnzz%FiA4Eu92m<}8e3XEIU+5$v3SVp>mU=l0W7!MXv(PZAoq{>V78b( zO6c?bsLVUJw6(m-exMyd>0VbxyL>%l1iL1Y0(n|Bb^`uuhL@4|KLKL1E#a>+E3r@7 zOEKpeYba$kBZ9&ALyys&6sFl4h?~x1)s&}%!?D>^$#luR zd_P$vkrT3A7PFnCS+8%ZXTyv)w07U_%kXjIAv}VJ89xODgTK~lidXXq0PE% zAv^{&J0fl8n5jUWbTaOZsx|@>N!tOAJOfy-$p&GnFUL0IN}ytCjiT-ay<1P;*hCLn zz11PvOW|jvJ1a`s>s&4~J^k69sl<`hN-iF=2&eM_vjF;Waq5}?sKkLm?!kCRIIiPauxd1fs|z(=V2fcmHZ5^W{E#O5K40v%x;F5MHa@v@ z1H8BrvZj$P8~0mvmhr9X3GA_)Z5FqRIEC%_`_<4J-hEL<^U@`B{+A3EGAqYcaj%}e z$6o++aHe@{YLfi~o*dGa$zW2Z-0g)0QO$C^|3(p5HWsi-U-eW`&})G&vyz|q4!4_J z8k&Q@0iJ9cjK6sq{;N%$Dk*n*7Pc%2^ZYP0t^V}dDumc0RaRG25jIpd; zzihR1Hg3h_Ogh=sBk<7N3Rf=mZtDx}*%b02@bHS}3T^E^NF_v$VvZ@cy#3(aDj(8{ zymik)v@frbtH!F%yfq=3spq9P*T?DdyOlPdXMqN!3mEvM5>ld~)QdF$Eu0 zsNU?y^`#{DF5Pn^`M#JJ4Ra|n1SQ|)T(tNmtjL?^twM+0!9>DSoMU2ENa_64)~9y~ zsJ&`kxZqXf1f@kw3jI}aNV}BHYQ|b;CPwmWk_!IRg76M2C+=$AIEGT4q~Ww}`vgQ) z9s7UwRx%iwja#v+9K z#%$lrSCV32JIF8aw0-%Tej&NMOY{OI9LN_195rgRRT7f;o^Ohd&<}%9$Z zSSZ4%=J`lzQ^=Yq-*u6CvCF2M0P?-qj`;)bXYw)bFyDi!0vk)7YC5>yd_u?uX>nuw z{DnWoCwHZ)xARRwZd7fy+Wc?!I3v(UMDc=h&5s%EoVh2}76 z6{>gcRMHmdoK+?*UNvb(DL*C^=xP6+-$Q^ys^V0ZD!5wYfkHa=X9c)Oyr4n>gtmMQ@(YqcnPVy{452ScNgarIW?UJ%V4 z6e87+7YFSVLGe=+Lq%bvF+?&(QIIz$xllP6$zxUHTGF%|;;1)+PHCMILP17l3oK<< zj}9iJboh?le&dR&OQPwbBzt*emI-)?8RbF&aP$buDacc$aaI#>vc!Ew6{{6i0)t~i zu-mmURX$6=_2tNX9DS=w;;;YF`E&VIVvFbBE41;+FppfSLf(@`?*5`EFLCgSkOJ~n zP)|dOz5f8q8gq+1@e+9!G$NGSY*p{xMM>fEq%g^M z9QtkGVP|e723X8|W_e6Os*(Qje`n%q(Cv!7A4ymE8a0yH!>PB6m+u^)2B%{{!E5^Q zSF7m}tK3H<$mi2PyjcLFJ5W#ovmU^1y1Yb(QYb+b9Zo9zPW;~g0Gu=Y*VBJHJi+-{D?DpPX+$))#Iuys|OkDri7ZO*f?uD*bE!0H1UD z3sCaC*XDKhs?bNN=vus9ShTonN-D2R59{XL%Q+gfqU)W6>cvt2AsuS6!jx>FTO+TJN{jI!BVFt4bQu}($7HAYn_ zNY!5B(3)snR#)|5U>FBb7*NPaEO?%PVy{8+-kmHr55ZNK%+exnK$N8kB<^unrCZ4s zjb{#_bEjNS8o#EEX#u&Sll|i=Rh3ksB-0f~={iP%E#{}J-&{vFpQ>9W#*1|eJZ$DL z&|FLDyYMVI)Sf#9Qq^t3tF?VIL$dtT{Vl3_g|6>(ugkA5!D1Jb3l+7*_cOh?baq)C zki@Ev2{ckMSBL)q&RThXPd@%zU3r&G(<8RkKQHEkScVIDy+b~k1d*Aor{vX8=%v^Z zLcs0RVy$bJ`ahF@H~#?V9)CGJtE6f2X`h+CSGe-Gn6&#CQr;BQ;4s~2$I&L7zOKs+ zPSjcrsYPDF`6-}kzn9)({KJY%D^D)zesA+t&zPYXoc(SWutLzfw64rYGTlDU5-0!| ztM2bDPc`JI1h8C0fun24oHw@MQjAFXVy{lLia6s9#4@NXdJnU?_r+4{eO~HFY~^&d z5dJzatNv#Khw1R4<4C&X=vrFR#NX{N(>9fVA0caPE~fM}wON@~l~ zk!{K8++wNy#+oHwP^(559&w&kYE$7NwAv#4)KOZG>JG(B-uI|=kT z;uac(g6Qugk3Ghr9Fjfcks3G)UJ3WU`$W}=CB~{1TX03L`RP28&yt|=Bnpc*g8m@(;YE!q7 zQ_ME^Zw{7jq$UVsjuJ!0tjwOF`zuPW)he?6H}dcED^%A|Yx?XLu&q|w-%Nwji_wjg z#*UJ_uT@p!P{0vZ?nWy6bID#?lT5cqxn^l!iFGVUD7C2TO88>0SB({l9h5Brp{Bs? zxbL@IRa5k4n#y5oND4cNWnWE7yMaK=JCF?rhAOJoI()vX8%Uho1xuwU4?ZLn(D|q9$E*I2P;=~WLQ%aMtII3`-TDtXMlAsui2au_$0d{ShVY%BCW|kUd zrMyZ6oSH>Y>_-k%JA8l`t24KrG9#%JP$+xQczfcgsV*f&LJI~5Vo9S^b>Cn`F;&A; zXtxf(>XW$lII2BwN|8wwl#pa#N8yU2qP>m5Zc9q+LB&))u~Nhppz!fHt3v#%L>zD{ zURC{gsvq=%diCVIsn(*ntN+#PdLR80qv}@QR{cBmuigD?>R+X)>QU?I^Z5N9b>Z9W z(-nGVmHz-jNA){zsDFz7tLlE@zh3)&>;1T^EYtr0=u-H{^)K;FeLeYoW0xJP%a+|S zR!wdH07B1J`nULxjYU7a<4XR|E&AfA?Wg?<*B|s>@f|sue|z?~tt*PB*1z(j`42<% z{{TPQ{_?cNQ>$P3Q=D7s{{W@^KK12F{{UQ7liL3P%C+?u(fudS{n!2FdJ6s&#aRS@ z;EpHL`u_kL8dI0??~0-q{25iJ)@egpa;<23)4nRMKf)geAFXs8KGlEN;;E7U01f&v zSL=SAO)Ji|@9m1AB>w;jb6#It{{SwWsZa8;RaE}~3-SK|kG`Un<%+KV0G(^%r`G!X zU3%iJr}%S-=3?e#!5d>2p zfDst}7mvuF7~X$k{?zpQUo|~;GjnpcwsQOTnp{Aw|8E`UCRob<4{3k;01rpS)6UZB zx~X7qUbh0kko(I6f9aT+SnrVrtFxDto7=w_uY2&XGFn*!`qaz z05W5M4uGKlcQa!jAd$CpHn##SUxADe^ehkp5aHqB;o}kE;}ek+5)hJ8lM)e;QqxgV zQd3gWkrVxK|9brO=YI_$#Ds*zB*bJSBxF=1BqUVV0SVP#S;+ry3P67W$nikQ^)Ml~ z01R>nCOHH>4=Ml${S5*IrNoB(aiGB04ilW{SlBqYc=!Z_;N<tO|4js)Gq zyJ#hIM^b8M7SwHfdxw7dW#ZUFeskt zT7r&8!-qob=F4uc6BKl*E!>5VIB>27z~vPAIsyujPiv{9C+cDK>u(YMdkMJy5dl2| z5MlnQlN^8o{aY}DkAiLGmMz>udyp#sd#|KQY^R^@^j6Zl3zRSH$UM{DeR6*zGkhr9 zqRdIwu@d{o-L`6gf@FI>+k7Ow6&Y5nHoZq`A9nov5DH{rw^y4Kx#2;BIf(d~lTv?Vt4ys7#w@s7C`o!GucVQ|}$>luRb=%5#A6@M88v z!QMK?6P7k#LRy9fp2+a4>=utKZabXbx$qB=fw#lpfn)plTU*dxB$aFDdHz{wWXVOr zq+@_@h07{qPZ%0tNQySq#gxBtNbC)qHp%co_03cYZBLq*@mW(Eol}^=tt=bKKj|;+ zw8})G6zI?ZY>S+4lf`hqB01}>(M&flb(Gf&*_ge`bGK9?G~jU+`R(Jw&lx+sMuEh+KZ|(rWcR^ z&GH@AMhfU&4H_t@yn4FTszA77LfkN3S56v6!6+sXbLN=6_&Fq>6`%Dgf+Ad!Y?tN8 zZb)SU$HUZ=f5?lnmhgOX+sU!Ku+Hhk>q3eJ4U|wk-N0nL@^T_AaV}a&aa!DNADi3# zv4}i7(6v4bAe~d=ujWS&4P3nssRxKo4L&C4lPayL-$er=9x}Al={|*h9|J=n zGh+B2EpvPQCzIJ`8=e}^80(jxSls4aOrnF>hDkQ_)GO4Z;ukV$OKS-ka4~7R``!7h zEKX=P;)6~W>pUp<+-|; z-Pa0}6pjiKJSfm-)*mbw+U=(K9os5h3zi3IbuPOKN09cqJ2?7xLLbO{YpSpat7w7i z2s97sHr{KI=_m0|Q=_%T+HIJ1Z!oY7biTTuc%Y!Ij0Ps&I-!AgzL}U2^f9~_Qf>p^ z0yc|2oBdGG&M8axp3qo7=@rzn4}D6%m-fw=qvP@kitI9gA2w>7LqmA5m6on`sax3= z;ZR-CJcLFALriN_s_Wv>mP?hoR}=QnhV- zKkPzZ@3qzhbT%?(nMR<#VQzxOs|#EkU6~dQn@5jiyxYn9MK5G?r;dW#-nPJMidsgI z;|*xw-i0rwwefgRpFk08(9IN%iJRMCDl3}}TPUD&gE8s*PhFx&^q~_~=+^ zevMF;8zFcX7M?6Bic)Pgo|818QBRHS^9~%v>z(~uXIty^YTakfd8-gXuRJ9hD1W`E zx*Rh`@w<@Tn25dThauQo!_Np;`rMXYa0IBPk|GzKwB#;^Pu~oBib8J`h%GGEJXFo? z_xf?gTd9i%vW)E$koT<>mq!nGX)*)fSqN$dJXqI$BZ3B2M{_?!?TtI5f%+$Cppfjc zX_qF)f+>TYaAY^P{{71QX<{j)ssCFbylT7O`AT6H4Jg?MJnpM1UticSR+c()aXptU zHlX&4agDsXApiuUrY4^&`P! z{>1_IEKr0hTQL;TB>a+Yn1l9eh3g209{F*RIo9mNEqDayp*BKBR1^-Fv5M5SHhi98 zs84C|^goyIlwmGUU8?EOjHw(9(5`GTnG{%9Z$R@`p$>4stM`K>DW zSJ7Th(dL(g;7(95nQiqX;EFd};5WjtBopW8l|pxwSN~##BO1VK$!z~2rqQBuQdv1f z^rg#^iEU2CvarvZT8HAG5H>GTbDY)4Hv98V#8`aC_U;T1EC{o|65J_y%8B}y9@R=)a7dw|MW1O+^e=U2(+N$Iu$N+6}d(P?9PCJVgaJ_@|1UHtf(o z*hT~hHh<{*R>o+^D>^1)Ix3mpTqN3c5ZIG_GMC9S?dE4i#x}2)H^GCFmhsiqL=_QX`vPi9D~8_}WXC zerm0}ti1&sMXw;BZ7qSxfeNj(R(?L%C)K;wPwN>le;j#oWP&rPT1nu;otQ!8UZ!7x zCl#%Gw&&usWWzWj(229s@}}x5p<*5P&mB+zp5 zVRiEUp<$a^3GbZWD3QyQdKwXUgBR=&PDjyCEE*Por$F4o;?#q&p4lwSaQ{_&OxIat zML!x4GXJqP;D~5oNaLv$h;f`~Y;i4OFr5~5vB|p%ae=3tn`$aP-He+w+PQ0IT^U-l zowlfZ(RWHiBWChr%ZYZaro+BL>_$*5&qs{;v#Y#{=`CmH;tLl2!QaB$Ql5H^uRG9y zOytSz+2JB@TebBfoZ@k)I@DQ8XnyOez_hEy>D)4aWnn5I@iz~OA3e6@7x&4Nv1o3- zK6QFqRJ1d)LEJIddE{xU@?=i>$N|aC^&()&6Bz$ki+a7`=)c!EZ4tSE;B${k@YvWl zmZc$VE>`X+iE;7Nt6TWt7bB&<{i?t3YIQ_b&t$EKc7EVIU@LNNNg+$sn>9T*V$&tC za5llXo#P}_Ib}$B>uQ8oKO4ng0acKRKFY{~otRs`#fb=NRro1dBp$jqK0pkq+rOtW zI@~{haOP(>t7lcYy9>yTuk|~ z*!idFg{@NWCJ5_ABh?MncpWZoE@Uz_mCr37Onq{1E3g@jI&a~7E&ghr3g+s1sxB{`VOVfMgsv&8Ue72K4I~+5E9&CXVl5^DrT4OZb?*d zRNhi2`t+LuT&u^bplG0raEE2%`7b(@CU`hfxkGvsKG|}z3+|!d4!NZ$Q}X+^s<(fO zpk3*VUG;KRx2vPV`CEp!I${<^J0%N*NA=C?Ke3zr%3XP98eLHWenT5Y7OCZ>M&3ha%NoZxaaKxkaIh{C+O>+xJ(?=^E^02~bvqk*)7OeFKcZ#8g* z2WM3|3_bmq1?48azLlFhXij6baCUSt^RP3wbFlO9Wwmp%zBZ`*u}eU%trDbwJYWep z1LlAgzzRGBY(d%s^zMJCYnuh-|AB)Q5C!;vdm!h(tY#uhMki$1{nZ2I(fJ~Qn}A+_{4}6cL2Zu?Q%Gv zZ3i&3aCgzvRepS3l$w$Pt2@YaP50j}$;!8UXN!Z2pZl|2Nvh$_JDa0RAyx-nO{IDj*>t&Z=tV?EqRJc^{ft*qgao zvMOAU3@5OI{%Z4eE`Z`%x2&L&MFk{8MR^7JK=uFa{>Q|>x&CM3x^MsDfb0C}GYC!J zKXL!${U^@(J!lm?1$7hmPn>x=05rS-0J@of;@IDTqd5cs>IeU=Jv7(j#n!{aMUtQ2 z+uNJZ&dP%CTA_ct|0BcSoc}%XZ}stA*Y~&XSQV|T%{(1ESg)080UCon-B{gS%q*-} zdH>fz{QsQs-^BViId~pffp%akC$K7gaFktJ$`zcQEbXo>?BF8s-}UhSW43>j;hOww zT!RE<0ScfpwXuQG#ed9zmW!o5JDR2WPcoEZEV;u!K6>KKnPj4^C5TrvDG zLNH=5(lFj*lw;ImbYS#ijAJZe>|mT?0+@uDG?+Irc`?N?6)?3ijWDe--7o_&BQR4i z-(yx{He+^Sj$$rh?qVXaaIh$`Sh0Aqq_9-6^sp?jT(JVNqOdZsK48^jeZv~XTE;rW zLSYkQGh%aNOJb{G8)DmFdt--Ur(hRh*I|Fh9>-q8KEuJmp~2z85yMf%d4lr-#~&vO zCmW{<=L^m-&I-;cE-vm3Ty9($Ty0!4To2q(+;rS>+;-d%+%??ac!YQ?c!GG!ct&_m zc(3tN@JjL8@J8@9@GkMm@Hy}$@wM?S@qO`Q@eA;q@dxqO@Gl9-3AhMk2p$u>AP6Ez zBd8?!PB2FRCnO}iMJPe2Lug0%iZG4vBVjk;G9iM9g6J-h0?{)fPofy2VxliZ(?oD$ zVq#8WIbtJX58@c&65>wc1>)Z%lq7s4Y9y86eNuc<4pMni6H-6Y6w+GK zLDF3^d@@cl1u`?TK(b7-CbCJgQ*ugj0dj3}NAf80Qu3eVn-sVdoD@nFmJ}fr`4pWL zE0ma&Y?KO=7L>u11(e?@*Qju)xTw^qUQk6+RZtC39a2+J3sdV;`%q_6w^A?BVA62X zsL?pk#M0EzOwe4=GSSM@TG58nR??2pp3^bV$2>J6>2v76)9*4+F-S33FhnraFw8JwFy3W+#OTkM&)CO!%EZj1!sNn~&eX}Y z%S^*8$NYjhiMfq=i-nR!mc@=GiKU%oo0XbXp4EXhjrAMr;Z4Sysy97v=G`2)d3lTL zmfo$`x2kT+Scq$L`?V5x--9C;QIOU5vXTcWv)x-W}w|;1=b!f(bPW9SL&_TM6d~Pl-^9Xo`f1d=~q<7vP;mLP&4Rz=r1`oIZL@BxefU{@-O7e<@fL3yYF_t?*6%gq(Xqg z7e!1(6~zd}0VN70J*5n#1?5}HHp*qnhbkf}{wiNou~pSo<5efsnA9xPO4JS?h&>2+ z@J*daT~|Fr{g=jF4L6NuO$^Nknu(foS{zzVS`FHOwwiXL_WVPxhprD>bZ~SY>SXGy zKN5KK@==#ArLL)NsqWe1`;TKE&+6UQ^VIvQPpbb+zeNAsK+zzYi0Am+vB`OkGqbag^RNrIOQ_3|tE6kP>!F*vTai1& z-Ppa+g96rjS=5D{oZZl!cOn zx`j@LNrmOU#d>S^b|73RJUtv0VHwdAc`q_05*cL?)e|icofeIbv5pyt6^+e_!-;c> zn}~Y2Kfrjgc|&Ym8Zj?A#l7|*<) zS(U|@6`pmTZJ9liBbQT|%aj|Ld-2Zh-Bg}RUj2K{_bK@}`Cj?!1^NYDh2n)JMf63H zMOVd6#Y-O^efU-)R#H;RSQ=Y~QRZ2;RsO7es6w%#v68nkuZpHB@+0uk^W%2)^XiEj z^_s7>;*4Q?J zwvaY-yI=e17nd))9X1^+UroQxb{ck$ebf0i@Lm0T_YdVCon7)>?cFlnpMOgJZ0Zs3 zY3LR0t?v`*tLqo(uNx2@s2>y?Y#fppY95vzZX1D)bc`yF{uomm>mAn`AD+;gn3{Yx zxin=twK?rDeKg}Wb2nR&78zq~9o1eFow}!T#Zm;dQ>|E}K?vd|h?cd)2bRc)ocW8LHcI0-1K8}Ll zfES+#pL{)ic)D=rcy@Un@%zT_4+wEY*M-5w#-%qB7nyc-=c*Z{j+#R|f&lkF_^BLt zAovSE#rWG{f)pke7=m~o*0saN!T#fLaBy+)aB*?)@d*e(ob^8)1QQbz8w(pB2M3>+ z0H1)E^cp`U1yNYg{p&&W*T4VF_xC^aAN+I*$j5|$fa5>-DK&_ng2!3__ut`D01F!v z0|x^93qJ*A{rA-W#7{9m(LnqZ2Nx3zFx(*+nB-UhHVB}~>)=qDfdDF%V0<1f^&-Guiw7Vcj~6uA=fYei`vTY7Yk{KDf5#wVb=5t5{&T<}SMRPQ$Z z@e2GJL$&gJll&Ks`rp8);;M$WK5x@LGaUIk`(dnU=YM2at|jHXZz@1 zDq$JDZLO|d>!&^s-Cw^$74ukxMeCW6*}9vee?Ltwj)A;zEXt({<@Q1|^?2;D6L*De z{z1hVWiA8_aFgclni2%`fGDOoXfu(xzg~uLb$~4Xf|I;%uX;%LGC*W9I(Fld65%_^ z?gtwngAM4UrLZ9aic5oypy{7Ki=lzW809A(8^}+xHmCeSA{Jmt{9s9n+vJ}k3s{ew zMSMMU55`3l@|y~`&ze$=7%9! zuC5D6CsMj^iulrw_-XrdBhObkzjI*02n~D=l{SK%{%HzU5IqvO<+XCz7R*pzS(e~%G)d$6(sHvNa;YH%A^2rKAgYr>;) zw1$SYO_=SEcSbjjBXvek z74Tj923TvG;-jgxjYwY#_Q%}%7E;!T`qo92YiJA`{M5d|>S1hjOnS$*KG5gbGsI2Z zYF)Icx;o*4GurYL`|~7o!Aph&SLlmmCbv!V(B~XCf&xf)iTcFV*A@?r+eu79Smynb zesP;T^MO??u7w?s9PDVYpodn#$q^ptfozAXY(SIHfWY$_=i9#fJ6hwqeJG9UdS8z{ zBl}1dQs1I-)=cjY8$61xQZ+-np70!vdr7J*)YZSy0PT)pyd+!Z4iwSNFLo99W8jx5 zzlv)BO(EfC*@qwZJ6tz=s^^4p_gsvQ^k+WF)Eb29CT(vc&Ku~9e+{OI6pT4L%Qo4& zie)4kj4|}dTIX!7`LEiEf4>oeytCyh6@6YTC*&sZ3N+|U-d$Y(b!4(NUX=j!rVQHaR2VKwG=BP<-~|wJ$1q=`yNRJn^r^DwH0durt0{7G6vY$oRA0sXC?5QLc)zJ zFqe6GTzEvf*JhpDKizy(w)oWR^zGyIf&Rx@F9ytk27QRm3H__V&N!r@%fa|YK) zFxTQfF@9c;2;GXfD)ZyXP?L98x5nG~Po3EVO}6Oy(_c<!xL=PycR#YBR|)EWMc|7nDlS?B4h0v0`JhVt?{;Q=X+v z=&hW!i6Q()!=sTV7-oq{<_UZ&`$Z&W@{zjI z?%4|xuA~9Fyg!y>%fD3JlINZjlE4O7KV7l(`gtZTJdfDWYl5F-y!kp~C``r~OB@xK zbh@xHE=DTzY#2)(`|h)e*X~JHv7xcF0jStfr^SygM#jlyF-7DQNs6!96e2jq4rt9X zpZZ4jy46McMjkIq_cKL@ZJvH|^gGacTYP(poVOdtn5nm+~ti$NpGR{=5b$2V{+K-Hf>&ce-1K{zHIFXBF{+B8?cQ;FP9wcDM&%ha_k&%u0uv;=779&4vq zyRy_3<)TLrd*CFC_j7)Y!Kxb-J`eftkS z_!u6|HVy2kPd8eH3g&w*95?5T|BU2$4@|W>qu$K^tbLkhw5(&Kx=zX*pPwI0SstW7 z$Y1jS=$%)?wU&S#TQehGq5%uJy{yUZ+uKlh6tf~|1(G=B-ZA^2&NzwjWAH)UZ3}{T z_swf@IHYko9$+@fXwjXSkPo12QAYi96v^OzEsp#I-bq6P>1DH5w|8cticVi z@B7BQXjIQ~#v6O=be(K)ooovmU_lwO)RiHUVmf#9=i4`DNsqm<+*#~&XC+#KGf^(^ zXuy6~M%f@lzL`GM-O2b4&>{Y}vQ|6ym z8-nffYKOmtrJQ+-o~u>(zSeI@=1{ds7_m*u!{YuiG519Cw)|A|M;PaGsaNvnHB7as zje=9K4HoH4?D6qm52|=)^QE;5w@4{mRa++kScaH8n z9nA3gLxxk?T~l?+ZSqpJEknEE3o~rocaP@$6wkSvBp9L&(`f;Y1BT@m!REU zTsKCHv~Mtir=mFu`oZH%y_>NQP*HIXfmy|h-jO+`y#^lwYqhwpKuAz){O6HKJ9-pR z0Zxo*&r@iBdrwO!_M56Ko)-Z7(7?M0@13O8_~n$vuYv33#+avz117e)eL0WeWd1lc zC(b<6zHx?!P4|23^hziFD6`HoBi~Xsh)J6N`Ys*rDAJ!qGcojObkJ4WRq=Is-)JL1 zO5tadzsZi1Bbdr6<|8{4B$*BwYfXT1B1)*-jwcH63gzozTL~zgQCO+UI{iQx6wYyM z0K0=oz+?UufcY?V0b5XA=xL*(-nQY$E21os3*Q{_1olhB$DCMUr8F|!1pRl>VGpd3 zkx|r*PNJ)LTOopl9i*-wI|B^fuMrOsBkzr}+C647D8zOXCK!P;K|bsZE#I~uc|?$S zLKJobjSBEI=Ck7yt* zY{|QX*@e6F${%i+2gMN-KWGK`-$@YnGm$Jn?M3ouQ618C4=-W5iO4YU3d|$E0MS!6 zK{beBN4^BN=G9I@Y(w^ITVfNb^J; zB}I8O<;O)2;;#;W7}^+p<@V(p^BKo_J$J!?9|7gFSu5F;a;PpYGNInSy+2#L5VPZ* zX*d4S$;KgKgKIW44|3q=)Wu@jej+=H+(q^@H6pW+m&fg!YJ0pM{I|Bf_CAPUKizJN zw*z<;H8C1!rPy;fcUl4J)UYEbLGjDd#^C}m! zY`W49d1mz|1KyEkXX6V=aZKU&Z`{tBp8U-s42F-a#K4npq>Mykr?<4L*0EBb;16UI z8BMDy!@f``-P%(U?Z?EoD)JglIejB;hopS$EjD(mJ)yR0PR=*$9gSAUp(5a(thd~J zZ}H)WYSqKb8IkzUloeMTa5p>p7D$)s7@iDJ3$7@ozMEaTQ7|$@STM54bX|Q_2migj zl!4;d&t2Ic`pck4xK~GUR}-EraYLhV5ChX3)fb zQ^mFi`MnpL(xE}6{*QjF=N>zgu2;jvUk)RrSAKIG-wp0vcn-Dcy{MLjJ_OghQeXal zGn5OWU=t3zhm1HlM70iW(pLoRI>EMcRN!<~+bqI?+G600;U;-giP`q16tYk+20hhg zLqvIg3hQS{>Vv*Ey;b+g(L7m_xj_7sv*#CBC*EKzqH{gIupilZe5WYebDftHpO^Q< zKP5sf;1Nf4BUdso^@eIz0%{u&y<24~*vVJZm&Z)r$;VWAA!RbSN9+{JDV|>~>csxO zU314=fooHiUvqG5U+!?u11XdXJ!Cucx?c+00{69CRJgw?47|biAS}TC5z*YI5Tmi? zx^kp98erdxYF|>B!c7fF<({$ntIe=pfv=|-kM>j^HMTWGEZ8eGMBI>(yY*VJ>`}4^ z^NkUIpA)ACfNVp(pw1@BG5R3bGd!sHw zrGxzP#hBWmFP{b<`;xBmXR@01<7?%0YO6}ud2g$6f52D!W{Z#e)`rx`z+pwolqc%u zcZ1f+*6m9%yr5)bQ&aboVw78de=hP@?1tudCClUHuc0j?_K`kYre}s8?GI&5^LqH# zBgetp^;K+Wfayg5i(Zj>;8~6!I8(+Eq5SefsaLW!Pl}5yd8F|v4?9}Tai{nmWy9E#5hiiA|-lnIS zK%!LV8h)?z)m@?i)#prwiOtZh`@ePe^-a5-**})q2L?Fj=6vo)1HO#$dyJn;p<4>K zSAw?Al8XCs6Hscy(hcjpUNS0!-r9Lv1~XCm6&vkBr9BfV$66o0y`Y9fJj_b+SKukY zEp|r^b(@DTw4JZUB!aJ6GV8or>V^hAqd%M;idW^lJham>z4&~P`Eoc#Jki2=^ZVkN zX>GA_nt9ZR-k*Dtra7N?0)?k7hlvZ@itWAqsYekT13lr6X1zOtts*JUOFHUTbhSem z%e09QzkPh<;*x^mqFp+-IfJBhcf_Gfw~54SUNq5RuwhtzPiVZw^Gc)K6Y#vrHVGAe zxtDKm^doMDLCZs(YK*TEcbzob!r-;3#t-wga*W-tdN<|P6dI`{yfmIv5BRKFxX{=t zmpSP}pbuv%hQJrQr6)X38eOe_#gbC@NOPr!V?CLpi}&uF^TwZRPhVW`dT>I_#cJA4XRPeMf^zwY|sn5O$ly95-=GeYR3LzqRl;DlqW#>s*j_+S69OGiTs*W zN#&-PIw}yP#qRsn>+}4-sW+7|Q{lRClu38RSJ-?|O$OnvuTZH(1LK%xpfNDZ8u=BP zW17~y7%$Sf;fTR2rqncEQOC;f(iQ(b=z`CbV#aYEEZNXZZEw#wK z7xRrNH^Z>NC(6=d{$%&E)bwXR&Hz`2cAs`Xq2VpYLidfmzzAtgrx=Tv(LVn+)4I_t zvVGNe;G02?k|J^hIX{}9_0p*TKJk(5x2EjqGpNa8jD}Z=eMR{G_7}4s^*cZPG|OTY z;JNUaRTmqZI(U7)V1<;J*i_CGEU6~O9BO-Y*Hw;+Kdqh5Iaf)H-e$vQeeIjUUH#l& zmre3V`Z%Hp@{qG46GhU7)0&tZQ6vIvZ3(h{62^J5*qhteDmExg!V%bz0R^Iv%tr8 z3(C20Hsgun3C3B}bG!2iFP*0gPZdA*lIu{H3M)RlGtDmjs$}VQu|=q0)S%?1^ZGCw zGx@Vc>WfDg3&kv9Ck-V=sKNZL$%DR}o1VYd9H~sv69~4oc^1P-&sGbKp--9f?mE^& zUBy%K9DRKeb=KtH%EwIBGp!!259%RMUIsvIny6$`=mdFk6i3k3M zXe(|Wk*kXw8WFDIK|~<-cRe)~RK`&shD`-hZW7g~#^3W~oP4|JCdAD`H5f*h$SQ_W z<^0+vLMN6g2(vAk3uTO420KQ6DYfl6a^-k_BHv1)$skC?Q*q^1v#L+EaYiP&_Pf>M zf(gjhcmB95O>>un0P=h^FaX|<9FVa0PRX!NMl==eG}q_diRl^mI)Jh(PRMFhq0;Z` z8(Vl~Md#1*G{u~(Q&9VXM(s+7LmZ%uTtxID%v{%4gr}eRM!+>f(SY(8FZ-C&CtgR^ zupOF_`|Qd6(bQC}hQF;luL#a6`Ja87zU}0-W=hj|mXo0fN#Od0R6U+th0h{h&nna- z2ac8VE2pqx9BCE;%&H`)ALeg^mjVOid)~cLaZR6z=6v?5t1}Hc?oaalEDACmB_2d>Syp&ZAvxjQ^o@{ZB&nTLeX zRv~4_Ew-44j9j4#Z>QrpH&0d-_KHzN0g1VcdE!=#kD|JhEX4iH*}hnOr+EHi8&yQT zQS}qre`6J1m04#DRT%x`{~P;9UgdU5#)(>y0%mwYmNsVs1@w*W{*NsCkw&4Yrj1nL zqs(sSaJy|Z^YO_JMyq;i^@#r>>9@nSRy?JWETQqLNX|TrYo3Rhx zYag@hBBxse^hg!GK(t~4l`47zwv<}jr=_;J?&j*6V3X+USk3sfbA+2^ggfCHT5&Jj zL<32=nX=As?Od3EbT)S5@kz64&8Wx?=l%Sqmgf3K9buiPm=qT-i3WKhR6VDz%w$mx z^B#E(=`S-sogPnG2`x)2D`q!mFXm68fgIEL^AxvP(?ILZkFyKO4Xek!q+D^ssSJ-8+6&(PeQ`(1uAj2B1e&LGqtNfjlsk`(oW_%s|^dkAAe`$^k%`ciT3uo zl`P|RL;AkC0bQop#>C)k3+CIeKe1jCU<|@DQLYnTM@|d_eGw)MGDcG!{3=_*L~fvgb$;+OMS)K&J&s(*@Bw<2oQ=_gQ%41zhU2|4 zzf5`j*9&y3Nk-}7IOcM^nK50R;^|Yjc5((}-#`DRe-QMt7ZI5A?6@oWbFX8SQaLn@ z#%f&nQ+>*Uqo|>x<`4NhtJ?uu(!WcO^>unH9hYUL7}*VAo33jyZ$7tYB~|fg!QQ*jmrn?vS;5Oba7+!;J=%SSkF`qP*_+~w`~`z8$@)+_B*r5 zuRGF$Fj+S31x?vng&#LDW_R@#jiAbfpsLXmr?$333U-y7K5^NxPJM{2!Ydc`7K@>3$YI12T-A%w3 zn{*a<(nR!@CZhPmmo){tqLGtt<`vBuB5}epu`h9nd@%xTPOBJGyTFrO3Fy@+dEx_| zx5-sQKWv#5mN3=d>eI#lfwPpGer5ZMUFXhvHpmnV`oxNv9Wf*C^?|w%Mz%E8Xy92q zukhFUv#dtHgwT3wqYMYqUQX7#ySeb#o#(eCA;eSj*0-Qk0Zg8 zU8!R`vuw)*J8)>lM~yNSuxL;<63<_Kf@aTj70@Bo?aVskIa?wn^&6qQ1XC>OR+P7* zYe5Bob15sgsiiL17AH)5KY*9(Nv+Pb|n@q1{j_C3S2K#E3Qr+vI zhyf5)!dt4nqDIV?|MbxS?^_$_jC`V7dAxBMOsL|p`#sTn6`OSW!y*d??u$!xyBs-* z+>D30@N5=%;#aEs=!O7vgU`&)+O$8?b~Wox&f{T^z(-`a zB|cV{J#=g{^ca38HrpQ-EyeW~*>fBG&;V4Kar1{%xVm-{H&5iYt&x<@q^IMqCY}rl zdGV{&NA4P@P{ArRpil;?%~6nU4cReLMN!(9=nGS_D$NL1t|^qKW~M`#G~lFVO-pto zN5EswhA3=940%6br;}^uF$d#~ly9Dj?nnmq89`CBM53>O>wJf#$>$E+wb6M?bfxwk7 z!gZrzD_8p}mih4|-1Q5i77~VnmgqySkG&r%q)F@#mqPS zC0w;|oI3mb`AxFz)RO!KF^NwF&FPMG352xu2INiVrJ5>c@ku^!Z>F)zMJ%=LB&sZ$|eK&dz#H^Fh)mSuV^>m#0d#U%-L&sVp`0;%qL-d zEt|jibMNZ?SyheDj-| zTWZixnZF&VJnC^N#GlCCGS0Kyq$5@EI6+PIWImi)8kp^@f1(neVT>n4hRTr9L1j|-EV@?`l+F~~dj%=pEqiRni%-7cO6A~_SSeKEjs@!c1M z*AslE^hNR6h}|zt-M2Dx(uMA}t+zJu#bNVzxjvwL=x0u{{eFy!po6m5C}Z>m$#1op zS|O_|xa{b*Ol(6zcWGX?NI(>uB3Y-Qm~lYukQDlc`3o zvr+-L)+(Y9Hnt{yiHbeb-nDzn?U6F3h|U1UCu%Q59B(+WzcJTTKM5?{VGB~YZ91}$ zZhfnzf_q38H0{J&jM%I)YOighNE^=hukTgxj#RxlAD8Yd+FakeMYE_sT2*jSqF`Vf za#4^KmCZ1=rafJxf}oJ@8|-F3J4D&cUQ#H5*~m2`18wU3VU4b6z{*G4tP`=u(z`fx z2{UiF!h4Bpfha%&H}hjJxxabwkRDN?0q~_+Vecv;9MscIiXqZ|n&R-`F4Ol19LQ)0 zQVEt?^;>pvs&dvZU)T1maWjl#7c zT6Mz12gh<$?$5$iCoA6hUPMNIvAQ z)`&a{_n7~6ndCqG;k@PvSv{64Ru5^qO|~PJEy|MCyJvI!ln|)g<28xzJT!{$yzVW+ zN<~x|{r*FXJiWH5AzK|dkpBa&a~U7)-AjzdBGiCawQ;#p^2FBK&GNrvqc3_DIs0Z} zCaQl+j?-V7A&2N_05G_{e{lIV+8bzXqabz_jI$GB6cS1-4KfO_bdP_aE8@s|IZGdW z(flXWzWldorzdoF_tS>!M;K4I*pf7BP|0?E zK5O~C_hZ$+&DY^rH$6p3&EC-#Pd$DfKlyXEzajs-JJDNL8MCSAYF50?)>Bo-dj0b2 zqC%uKWpwQFTXe91=KD~sx^F+XU%1)k*BWBZ<#xrjc4dCOOs1)#I#f$Phjrf#>eU@czOP-T zEg$XEb{ONx_5_D2E4Bw`7=`Z>9)YKo51eoR7SkZ*c6LmW(xh)#-AJ%~$K2Ktt<|*2 z*Xi`(rCogcjlo!uxzbv*a&U=g4YZ`2oMy&<5xtB*B#w^;>HyrCRC#sgadRRttV7{- zijElDW7GPcV0$A5?(KB;+f+#$zaGB->krDUSY0cT7;S<^kO2*#JyUpTDiVnOQ$$aq zhkpkQ=Z#?{NEE4JMV_?Z(e>$xD!DMiP+RjTA-_tg_6^ZY#Zc_95x3Ausg5wD+ns zIk>Qe#rjW74*j=;R}j*Z`Q}Z><-#Lvju8538KmqamFnDEflI2&De@~Xh8?)fTESES zKAG5|_IVmQA(qk=BHAJ}tTrRCeEAFqBl0Da$ob?p(hmlg9q=>;uTGAgz2Z^06Ok`- z4|<|^eQv$B1}u(D8Yc~g<~$6qxXxa90zQA*u|(E+rLfFC4jifO5@EpD9is3*&m*WT~hWP;dFAbiBHT4$&cZhST}D_oavh9<$&S9bZ48){cS6ASE#a^_u6NM+vG zf@Bkz(e0t@)A^&+#bl{(0dg=vP=N_#5~I||Jsx~}2K?1j?7nU{z@$iVv-yHFxMqc4|3Lbg3I9_ve;w-EIdW1!q=l1peOuRUdR}^8RmrE8(TtWFQ|2-t4=rp9gg|>raCfXvKhv=W0 z)k!?FcwR5)mLIU_j4yb%w2|hSLIbbpC-;MCrf755Dp`aNl^U5pvreNKFAZHVKX*RnZ6?4*$xzKDE zpR4H${t0ILLy%had%JWu6dHeEk}}o$LV11#l=@wLOfMhHX0yVQg|3)0-)BI}CL_g~ zy@@C>Ua~W>bb!q_{XXob7d^n^-t4;`>A=KmA2`J?PALvUwOWCtzLsf;-}Q-2rx#Ntdt$2 zejH*AONOR>cUQ`fk>SiVnntbYjg)v0{(%(tZg$C?@}A?+bC~?h&%29xwdpskw?jNJ zn1+_Bsy}Wb>%m6iR=?Z^HG;OI6!uO}!als^UM86WvnV)2FM|EN*{6>!dg||o3wD&> z(x!PIp7zK)CwGBf?!n8YmGit)$3PzG_O197kz;sT7mE1d>#_yvWJS5SebP%hd%x+o zbZ6B}+>L@SSz9fi%+-W}uH0Kjy&GqrXr1y3il;qzA3jc$OttG5y)8<6dvOr#um{F_ zyaVe*!)0EsG1;{z${pz{1^R01MRB}_FwE33C=Rh@UN{i{Q2m zPH^d#7&^*q)tCiwsW7`I8+2eSBm7aqPEX#(vi>yHo;NovT9JXBJ+#Yz!H&;kg#3>J-&r1-MPfqOF-qpfQ?_Z_|(Smf7GHo}V zO#NPI4ylfWwl!|#KEWt4CdICKQAnyKe&f!(*VgtDxo%VRuFfwpdrqei+x`xOg|A{V{&|h}*Jd~uF-W6H)-O0`ym~a!Y<42J z*BZwYT_oT!M08b*$aHqxjoqLQ{+vj~f?$hLINi9g7!S}}{ zlW7&oKFWn(VzDYV%j6^XCtG}@I9nf5OV302YGDAtge$iNUx-S+Wr^Xhe2VHiHz6eKa5}O(%$bCt~PpRDWkhgG02Z zq${QjO^eej>)*7G$FwJP6QS+1I3_JD`;hUH`+TG!$>xQ->VBr%lc8HD6fW)MMh@KDXkahTF+pN{cUPML)hqjWWAA@r z>)Gj-X&YDgaOni}jJNE??Vtm%4X_w$zvuA^g-`&1$ zo_tp--62V#iiSR+em+7d3m-qoqSVpqqgjD`3gdv`HrG;-8OW4XJyIP3nxZuKWsMj( zyZPhqq2XPaS-!leQ}zS>)P63K1V}@MyT)C51)d}0kRkzk==)@s^L|Xy$@sZ|7HLb1 zCSwcVITpCf_hX{29{rguqVZ+*T6WAm{SbDg>o$E&(N>yDE|j|X<-M6lj!kFHA;A%H zPDZyVt=@CJjTU7+#GZ$O*Lwweqe5OOTZbBD$G44yN`x6_t+FAiJB$G%A2E+;Rb#Vj zevduZ)>*sx(oh-tqFF^hG1W%Xy5zs8T4Ob#J(;yK^=-)^Nyb|1_|k6cgu~&Hsc{eR zdTPaZPTc)Ij+^crYuDaWa%dmgX05fe`Vs4ic0on+t|G+7uXM789flOq}amob>;CF3}>=C4q~_5HYIM~&-QtgX0HQ^ ztMOGNC_*1AW1-67)1@Vtk*}Z4ZF#& z6DV;|*&T2h%+!Q;R?aU6n;RXMwS8u*5}UKQ`xvC_?4fxxT8y-{jp|mZ!wnY))m_2E*j5J3B8z}Iw0vQfWyW(-T$EI z$jw-JZXN36s^8{9{og)IYwh;fC8DN3VF*5BWmoM@E((a_1;igq#8oU|gzXh#Q|+Zo zf!4Im{8XivzM=TusN)sT)jshD^+8|6NH`>EBkt1R-ss{Y%89Sag&Lt*<`DarH~pI6 zb?y*4JYPeznKtFPidAFcYqcs70M-^nz{Uh@^myumr;MHBeN&u%NmITE)wz8qiL5M63uxK7>gD3c&vt(7?SSSe&$ChrI(>YUi+eqiTj-;^(LC4H!ElfdbLQpx6x?WM}QfSazxx+xWlPGs4#t`fSd5-p$a{B|*5v zoG82&%n3x0rnQkZv0Z{pP7!p?wS%0;Rw~+Z`un3c;(^yLhG~oL2rFi3o z<$<7k;LnF&Qx^4q-nW_B5#h#5;_dbH9N`1A^{DL%4JDqU56zb9fqcsdOgPWa*)f!i zIx>kp^)(oCt#R2aOb#3`f88Yu{aiH!h<*y;y3G`Lkx~KZ!9LQw5S}18@|gxOl3Ig# zG{88`1|EO!s)d4%78CbWG0w`fj#WM4L#NjNT#pj& zu(8|fAeNg2}#AZfQF#c;#V82jMF$ofnBc}L_Eo;Q`;hZfkzM6rRd06+(?cWv76m%RWj3`d9L1Uh{3 zLX21c*FA#}PcZGu%6;`2$jfr2NYS6cpB>piJm7CP*|U@FHln~{q)lMU-)=*Uu?m`Z z#+X?sGc!@<{ifKR-%zNOxK9zhh6R(hPSI=0q0O+M(rv=`8ofJo0`{hwj0rQjc<=W? zOlu5Sx%S9-Z%I4@X~Q`ddo4i3YTPW`9p6(o(>?LIN#>7*d*Iw{U)8I#cD(G#6tQ05 zTb}>Dp>x~~x7jm9@GO0UDF9a#3S*dzv8eG+&>CLs=`MAbwam;6xN)IuP;IsdeMWyz zMu+7!t9zeGu|$2oidOAtt?*klw8*94A(=3Tgqme1e?M)rR@;aDn>*VFHk7WGeaoXx zpakxH&L1sPsj?3&fPPmB9XG*n#p;9igztNqecx#DfHiI3x~tQWkkb(70;Yz$aSJ@h zM*Q=?Xr}{4tu-85`7^s+8Kdf3%NMU9E1Vq>5Bw$SZZvCo-;AZDD-#l3kyUPJziVts zNa}Js%BxD+G|1qksVcUy#a#GbmMGWsa#^&`1o*P0y2rU@i!FBBuV)Ry$4S#ZRb;Gt{9Y<1TMgzM{JuqCV@Pr8D=8u zsM^KareB4L3du}uCH`H-?z{|8Pam(P`g6?fn&qR$eE&uGj7PfGgUv?5n$HE>r>%;Yft0iP)JIagj!Zrk2(+bUuh zP9$h#PRymsqxHNxI#a}KO|Pjl8>{E!vZ<~*NGtcV*sGW4ZJTRea-A6POX5^&C zEi=ZYo9*JW<byk!R>Isv@N9XiMtnDn4e(w9Z2c9>f~M!z`ixt~oZ zP|rU7k0n!5GHBlW)R9Nl@y1P<$gbJJFE=(jJvz>Vk}fM9;mP1?Y%X(pb(u4ZJdIrk z!gT8K=Ov-~*2J;JM;702|0ul0PCK=d z6QUW>YT5N?v7h&6;hTmX+9kM|^d`TeNm&n$jSI1p*H>rR$JH8ZAOD1t$;kBN;;7ST zdi;)*w=n-91?EOWgmFxvp!Sky%QtymuGu?A?M(FzQwMn*>FX(^!G2Mh+Y$9~M_kPu zbG&z2L(*(>oucM7q`PFI`23@;JxU1)P%>OM%5U0#pT;`llu`IWifQ?j>X8GdRhP@~ zs>@t}frITwV?4S;qr_7@;=q(U*QoW{qfBmFhm2|J=ilP(1RmVBq8|A5whZX+-h3IC zG?E#(1RM94ccbz_53oVhNja9w9t}zSgRi^ZUlxuO%q3+EmiIyl`F?Ps1>pD_4ucK_ z+UK)XFYljW!&A4}@S8g~)(zP^F8D4tFvlV7nNGbc|0d2b)si~pEA`TxYKW5x=`!Ox zKh#VQvRgB{aKRWL*^Zc9v}z)VBy{IZE!hs+`7rh>SkuJ44SH01P4RY;_@?4%i~3y7 z9vskNC4+0nL$uQU^BkUb;TLxqW2>cU;xwDB{9o1Ud+}~s50t0VT%NPcIrrWl_>)uq zSdzz!-Jj@(-+g)4Y;%oZY{p|0gEVS>L%FXTHKJBgyWyn2xQ1UFRlNTXB*o=PX0x=u zdcyKy*8ESyErTLb8{s`Qd}R3fW_4*lq?eOeNLp)tYwSVv#8DtgUp-`%k<0e*t;ih* z(#$QHHnMf_)W!|mrTlg`eLn1cAMo&GQ%DO;wCnG+@;v`?<2srl4Whp_9IHhzd3JgzpQ^d_T-eA6I4jymL+R6~N(h?~fr_YQO{h&TA}DA! z>R~S4+34EV~8&i&h@V8i={yknaF3}ApC3oI@?seo1jZ>()S7AE8&i!we>ksPC1 zd5KS*IL_0PuR>64st#ycoA-`3ZZ9_ozyL`{fCMk!vE<9_8V~ZTU9*5gMgkwY@3aJ( z3+lT&M!9*0J@0<|QJ1Z|!9t1%`SR)o9^;yCK`C&ABB9N(JnY#aY2kKp2VuI}O(K%| z)6(*LsfM!m%nq3OdaUV{0SZ7+6KPeQ?Lvn7XNl+ezgCOWlR~K#^#9*^=EK6hUi{ z%k>Irg*3-3M9jo~SS^0>KkA#!c0d0kI&T>!2b1X;Bn=bfsr?m7$6+}elzeAegNi4X zFgdXF9E|vq&55b@Qn&_;?b7F7W=a|O2f_q~do9&RiH+Cj&o&U<~~Kw^JvKRfon zE#71R-i&F70~iJapMYhBjD&n{ObSkRiCZjqdFM$&QkH>g{DZ^CstSc0m7hn^oGyc|u25gD0g9NBE^y@8X8%ez#;~ zGQ3UEIJ%*(>r*Z`|)#79wmmxeTOHc-#mBwllrD0K8_ojciIJQoz zr1QhJ;83EFHOz|kq5#k;bclszdZonT=gldr8=Dm zV)^z9z191U^_=$Np7FzM95QFLnD_X%jIcfjsJidClwv>IcRrJCt-K)91R$DeYneeq zI!<+ov$}{RYOfOW%P4oC40|UOc$+OJR85V!e_EQnv-#rcr8!qYl(X5G0{@fpu=6Rd zbfX_Re~*T?GZE`<$V95K6wOh}>&)BMG~e`}aeZ&9vSJrURsCLUDXbduw$f^E%?*Q| z7KVQTF;-LlN;S?#=(ssN$elNHwYbD!0;!83$p%sG$5 zn}oBP$DvmH&x(AGmt*C@`F}OTQu*U06B~a}UTWe`6V5_U7ZYAY{?zX3WQCtI_q2+Z zG6lZjX%#hl{N{%BvbMZ<8Hw`vK;i+6Z$mFqFR|GCMJQhT)Y~{7Xe2KBI|g;+UYL5w zKW3SKO_S${0yP#ayEKq!)BB}s|EC*2%oXvMLE<=Iur>|grZgX`kNKD?l{FVowt(T{H4w?2!0RlntnYEnDB7mUhx3b zFSmh7hUZ(}xJu>ZOg3U(nd{Ga9(E;+YZjG{*?TZm$bn!Hh0ZtP=h@He}A7VDPl)$>D zFFIw|G<6{Am^zcPzQlJWefdA$wxp8DvUK@`@*h5w@(aIbayZhyDn(6b{r>IlUT7g9 zQ23cAU?esJ6#W~AUYS}BHzcYs(rVrEXC2DIt zW|x)mvLr=2U^;leFF)bMy>d<#xF%oy1;MI(#$j9_=8?Em=%?%)gVbyBCH&eJrvi_b z_(`RYb2}nUR>p&vzfT!NTu8C~H|ZK7S>sGf%so8+ongYw;bP2%Q^>Pk1t{__9n>#%|Q-^;|UPAPl^jfmdz1MOyfmS@U>X}xNcMNGB&e;Qu3`|b< zB)oN+E7E}^(|Z@u^K0qBT5)#KDkK5`A%}E_I5F)0&Pa?`DCWzDfjPvbuU(&)?B~(x zs|OpG#;0=fP8SRB=J~S6&sh;CBL0FZy099(TaW4xKHDVZswmj-MeAZd|0NtCuS>$U zO8HgoE=sBnkcQ7!*q<^DOi&^is|@zghJ}vFx^NKcHQ)A1OjXzsk;;FPZ00sQlB>~t zvMB6$nJO9L3a?fqlta$qKgu=caPAztK;Z3@ zKr|5t+F*(_#FDG?<#x9#5u33?>02)igjA>4*|4R$bmi}W{fN&R-Hqk_nN}W5 z534Ntbdihu={;YPQI%F2 z724d{TwboM?|vOfKywOG{=6@P;cg;%uNN)24<3kN$Z}xWv>>r4+VOKn;4F@~+rQmc z-a&O@W*u4A9;@6p1-f>{Nm!OEI9kH8!cBRc3j? zW92FgDZm#%A@$z}rr)99GL58bm{*!Bi3^MsA|{h$ypVC(&S){jJBSHC!kGwg9)?3s z|5PtgIzd@hpGW*s&yCEte=DMOE2q7b#3xHF`+JIm?RXw)7InP1P=YY;_V0d)Otwib zMmN)ct}MJ7R+kX>%)YrOTACwN>ukN*>k9+YC-!c>N0sF)nFS`O_mUG8_O z>=Mnm=l9boQ6T1w_1CSJsyjjnld6Ym-%r~1_Gii3ECp$Nu9!GR8zcWZ~)UT+dzhE1}%e&DN&KbtE41EqQ;0E2Lx7QBC)HT)1XBQ5;{ zrHj?91Yd=cFp~j_*GX0MRSG+^vetz?dKn$ZtgoK3@;t?J-h8P;O;YskInrVW;h=uC ze`4E%yV#*D2Tj^zq@?$VDV!2-pJ z45At=3Sq1HaK0~Qc>lKGu(#=p8jdNt0<{ZL+`ZDl^rYoI2bXO=O!ZnN`VcT)jc|d$ zGfQXARYss}@7Rz~#^VD+2S3N>+UOlsuC}US0Emf86Tvb(c!^-!zc#e1SAt1>g_lfp zUX$5*aUpip@1NZ(kU(Xsrp3P>`H}eJu)KYql|?fXCCQ>`%01h;+Ap5+f;M%~OLb*y z6Ec9m`nsU|o0tlI4k0SNgsr#w)a-9{+RpZ#{rP$IMpKkxtfhGTDTSq@Y2h_l>RTvi z>71TQ=zN#t{Vk5`Y|ramqL+7%fi!)@DgO!MO*%$Z%0q8%hp_zk^cP0fo&2D7%IX8R z7MD!>^>0xi?~hKFmfhsH!6h^lI2d@_R?G9wah1}Wom0;n%eAytYD@-FjcvYyl+_@b z5`^OxrD}~^4C_n(^X@OMRkh+NH^3Eis+;Lg)488qf6GjM12j}qj50fM;30X(1Qf*QCNsw#=y6FKkp!i|^5tUQ?;y>VlCq;C5CN_2p28o< zJTL-@@uwGls~>!T@8htsu44GF@8;+)cqCO1dm3&>L1b8~WNBOcfjwd##gVi7 zBm_o1$$+(c7V0r2{Tz$iTsXOx0mcE<3lAx$bUygq$f{Qg%3_Ln3)vF!6T9I6Gp_jh zrx>U`(nmr&gxht}p4Lh%Y^qZ@N>)LMqwK_=SdLaKd$D1ejm%}>>E-t!h_lN9yVT7; z+&P>rKoA-PZth_@1d}0!f~BS&=p2pu-#{M{*cI}L{&CC5|zW))2f z7k7lE5`dEw4j>8ie{y;Oqqq&Q;ut>27*y1xpjj#gwo&|meZU!6a`|aftDB{O0IWU% zPOnu;9K^T>R{u5_hjWOBYds+|rt+Ug+QWb%?rG->n0#m{B+T&k`54213)xLO7h>uQ zgyd)8>dgYgehd}#!fJ^gDf`Vo7;p~hw-v9(LB?T&@(kaJ-RQ&OmyJ|MsaG+Q4C`Rt z`iUE1#8Tpw>OraPhu;NE&Cgdm);;qHkLQAV#Fjn4t1IWDm08&MgBE zA7T#rB1`mM{GXmi`|mTIw|5X2$sxd;3wN86^X{@rJH~t7 zO=zB?uWs#%>!cRTbI73Q4fbqc8ii)b`Lv1$-e)GaIp9g9#RC*)ecCrV zCw(eww9yRks5sH2vBW!F4oGp8OK!s6Lg-gc&spSAr=h2z0Tsqw-^)c@ue6;Dj`)eQ z>!^4!#cV>zDlB1YKl8u~`0}Anta1hpFzSZcRS^vt1c|4*(~jCoyOM|w(Me`6^*svKKhB$JA6TmUqpwAgR)r?_GYY&`1>wndF$aX_oeKCvY&4c8YGV7G zt$W*QDB=$D@{`ernsG0lMVV;aEv_;0ambV-h|~{r@N=T^)ue`DKapjLQKbZ)NyJQE ztgzwA;7C5>6|*tr6joeABcMSSb;nBLMr~% z9pT@c7`(xP2~8{)P-Sx+^^NSe+h0NG+2J!9J>~v^-el4}VsGLCPnF5&zV|!^V-B%l zbC~EP5&=U%e;TzVK%3g5P^Kq~i$c6@ttoe%V>DMwZ~j-I{oqrkzJz0ZP33TZL2qpA z>aX)!90Hhhv1hkU9^U67YroTlha3-FjjG literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/stats.gif b/contrib/ntp/html/pic/stats.gif new file mode 100644 index 0000000000000000000000000000000000000000..b0d0aaa31e8d66acfa7cfbe3b9e09f5ddcd36bba GIT binary patch literal 12168 zcmWk!cU+R+7k=U8g%?Bxao|eaXl7VeI7(0)r6#V@vcgf>#)g>V7@cHxSH*enf z`1(G5`n2-k!EL#@hpG;@w6qkLlr}Y;kx28>($a^9hWJ?<2L=Y7KY#x6<;(Z)-;ca| zr_pG3?%LJX)~0T4)oQhagM;_)-FK#};X=mp6^)IjQqcrpCC&7amW7qo`VIV+^XDNPoVak|!9$0pOl9oZyEl95)(aOenvl&lZ^^DZcFfw= zc9%e~WZ5!%2b%B9St7BdwXN;fuU}(hV|VY}8-D%z`i&c2-c$P@KK%Rl@A&xm@87?F z{`~pl$B$2+K0SQ+@Xwz=dcFSp_wV1neQP>%MyJz_j*i|?tG|BzDiVudzka=W%a-Bc z;d}QqA3uI<@94O8{rcOH5m`au_3PI+ZrXgaxA)4`tKB_4A3uHCw}1c9f1W*ld~bRA zhmRkt6^guk*@+YNr%yL^c6Ggb_pZOc|IVGepFVx|nCw+pRQ%=3mwWf_-MV%A?%jK5 z{-r|m*}He|*3{O{kKvwcX*qeaf$lkZ^_sQ&4;&zxn4W5E?C*bgyYFc< z4W~~1i~Z@QrslI}`}+ExJb7~N+_}e(A3uBk{Kd|6|G{J;+fK;e9=moF)_C)qPe!S zh&n|?(JGI2@1|MQ_U&t~ySW!@BTcz^_Sh|PNn@!0+;hk89Aa*IUquJIZ&kCbN*{~T zPxJ{a8h8a}Evp{Tw>2pJE^i9Aphq2E{cOl*UTF|ai?xru(3o5>&F=7$$eDYDoV77= z4Njg-OAhb%oT55JhD_$}0C7h!-Lj-s8RbdTDb*=t z4sl=M<$?>y<+{eFFw zzu&|EN|pqCiP~}bM`6#I|5BP%m$Iug7Lf+S5taYgyT@ymo|S+8kKS>FHZpu)zKX(gp>SCa_ zdg*D%T`N!=W-1oVS{@gIGOG#6;~npb3zn4mgxAC#{3y@o)Vc%%iHE9MJ7pE2D{Bk0 zE4y9RWA>XD*o9As3z)t`vR9Jw(UGH^ul-h)Gk-Q5=J6`M#B*?$* zo_U|a0KE;Hkr1d|t564l3BIQ)FMiD(Xu@uNvu5syN|$eESc?vxTKbe6>bqLc=<}Id zJ}=l&u4d(-7XVqk^u(5x? znxAj#Kz(QtI<4!uAp!}(R7%wOKF8!_#Gx{r2wPT+@5N6Q_-YEVH~1TWt4`kdbhh;E z>fgUP)c#nau?i-)n$2OdjnH@a>MLsG&$G(nl}v!FoYr$x=DuHzb|j%lxwHZ63AN19 z?kIkm5)2)07Izcda1ZqhXV2#sMkRDm{=h;bH^pUjAj{UG>`An*V<`;~S|3;RFyHI) zXVYFeoB`S$4A(V6LBBKZ#E4C(6WerJzt-k~KjFc^%lw~ypAcVksMOn1SE7Dz| zHo)sQe{tBrIpP0kTh%I?kB8IoI4GE1w*9zAb;g(!6*bbescDk}b9!#TmW>5l*LGX% zhF3+ri;eklx@pcc-vakZY++o+F!k9WYU(^28(EjDqOT(}Eaq%ql@25@Q3&z9oS1Dc zA_n<-99Z9m$7H;s5U6dT(_#xv$QWGxdd{8-c zlR+Jv3b2i9srN&JU%cuL`)SrrXWQ*!`|YKbPcb>&Lnr872{P1J`v%yUMG^`!YfiSdg;M}Q(`*W3lW_U~Vq0T|Ob zWOtgehjnb*`Vqq?IhS^8(us1J}RSuDL!VdgI}%-Wb4a z9lY3T`eXGi_nPzRS(zfYAdIs)7qc42mzAKtRxd7H`W! z8R|BE%lGj3VS`edini_q;RQn{mZmMY?^PUaQS&18Ae{#vp2ck5 zBH_7`I{WkNQRIDPC^Q4RJ}KYG$87Me2+Blu4CdFwN*34U?PAI#6%<4kDoTH9%W7Ma#!|#!uQl zQgD`Dq=+D2RlKT+Vo$+v<6KYyfFSF=;gqNRuiUA?s(g`R& zXm`ZbmuxhkCiIhwZs|)32a63Pd>jq;8E|W*k-J%@FBnq>WFJzXnf2@Dv>o>uXsBmlEGa6l~7*A2kZsV%wNxPb~(gBR(MEo%kg~ z_c3@4G*b&05KICI_m6^3E1?nv>X;f@%Ao&|6KuIaoYwS%bVrK*5ygx z}wlel56}8}-=|2=dRiF{Y2D8+XECoKD zYigcF@MG}}YVJCqGHr~ID+hmf5&g8lB4wpPQ(3*rJj?Ik?Mkd0?u}bd3gDGZ%$0On@KQw=g)MGnMeG zk5pFIY_r@9pf_r;+4?$22nys9^rB-6Y@~@f(qxr%NzSpQzmJu&@>W#jhmR606-FHS zKius$@NgRe(1ee-XF;`Uu2c(6<5oTjLv3VWzOd2vc(`#MuvKZggaSWMV=Q&1tp=7c zM@cxxBMzy7h}COEsn{GfUiJ!(U(LPxRh&+iy!DY}#2&yOtu_~)Jh+HiH6*@^YDjQw z7-l!5r#4{44V0ROLqjKJ;HhxOQ~$9~C8VCZDmrCWbE>iTl=Ri9FjV7^V`DhG@lsl& z0cnhT&~W77k@0MW`Ejn%F&%u2VRS0jyi$vTXaqx#D09T_ z65n_q`}Fr*iZK`Xr~&x$(rc|}W|a|3NWc{(?9pv`kYT!n1r_Vgb{bAJ3Hwf)jS^fD z2;`b(a={aRv$6s3qz>93uku5k4s$%cCKZ>cKuTXUS6-%QXuzd?=%*1BwU#i?g-Tyc zspNr58o5%Lv6Y-*)@&*u8PEH%U}>9&9Re2e%qNt)o~r%O70q2_6jQ#cgngb|MCs?j zw>JU9h2$7M;7p~aMp7zuL?4>v0YZlUYe;GvCK$$B)Wj4W?D;j6 zCk>RQ$XNz8il$B)RD$+2(0LZ|mlijJbYvO@9VbUyp-dfV=+;|_?c1$fXhz05%zX8l z^*Rv4$3Xn)hq*uw37yCQ?GM$h7;T<88ZY31bu&ztX;uyWF^!|;5Ohl)YETDAcvm%- zE(a^QSTxIhpBk!`;}iK_0puHB|5yad9kd4=8g#fRa-R!4S6gn@k)KnuwHG=_U_OhG z$lqj{g@4c5vB40T5f}{7l!U2raHbaTq6DX>0>ykFTN~$$fY%Wsng>|FFj_)l9$UGh zX^T}L!?_lK%60gC3d=M(xUL+H*R;-MKy%lge7)#=INNxc#>;FJVhkJ2@dRQu_{pkH zgU%?H2N77^DGXDMcrT**2eE=`9QD2uKIUvfG2e99oPcQ8lS7OF9WLq9s#@iK`S~9F2iLS{@@h4_^Sdcg z2W|njwDF;HaxgEDe3WIh;uqd3U`5CiGEp~AvOiaYK#~I(|6EEnX7!7)t1~|Zf{HW?N>seQCVe1xJ<~anc zM)0Xfwwi7EG+NVZP(5a;;(9nCk%W-03xU$8M^}@l|{_f!t1x+h+E^TRzrc>IA0bf zo3EtQ5E2yGCjg^%;L{W-JM zh)Kg7IrKch2c#+=@9TRUv!~Up9wp%ZbK>Q@tu3z)paon|pYtrn?7+mFyTs1VPf$kX zEXL}hSzJc%TA954u1=)hUWl~rYX$_K&NZ#Qu?ql zT;qmvkj5~cCO9pbAMMYD(1*Xys|NzKqXHfrDL)u;&t*S?P10g`XCz7zx>zx{Kmit! zz(~V}H>DH_4;CQMFa}(@t7)--+qlNES%-Vb!oIElaRrs&MYD zK4_1(F|rjp{>ysx?F)i0su8`pSua%bdB-@tvq@uHP5FV)vQM?P7nV-+@G-vbsv!G~ z4Gs5i(&|%K&ejnb1D|ii2{=;D%#x=;>r>oJ9^`E;mR%_@UHY+B|8~#r?5!$fwK9gH z;2^3kPsjedd*p~8!L^}mXzxOp-EpghY*!VZ?D3m~+i!13Du|;8Hcn$5O*&iax;icX z)#ITH1#br|uKRphTKYpt^(9M>bl^CO85eI=TnX!;3D@^LKs%mYesYu9wpZFKOEhQy zb9Ol$8^32;w5d(j(d$kSbe+EL!q9|u=+Wus+u#z+F56RHrQTzmSW+4iehl86rOrqB zrQMnmJ?QBdR7;aQZLlZ--&zcu^X{$h zkOi83IYD~Q1Dv>lV;xq>N&MH<>5aNjbMHo$^q_yHYS_W){{W{x{niZ`O*GRi$TC@4 zg&_Me>VRNi96|hNQolLa^po1G*7_%S%yD^VYnbP3+Q4!x1t#zS)u=($RJ-uKuE_h_w?k!fd>B;}a*6?Q4= znNETAW8sppiq>JgwZ109i0Xt-C-NrVLHXcBmavGw;ssbH@U8Et5Ul0Ds7SAK6 zg=x)X{}Ay4O+9K>0V3u)$E?*GT50$R2I3rHjwD)zB|IAm@iL0IbyWHnLdPOx?Q8j|Ne<7`^7z%1f*wQbrz`rPthqWf93cHgX8FqdR1Ux-RpQ{pgv zT8A0Kq}ZaL6E!%=vT3dCe1S<1s(CxG?W+Xq-3(!DCdjV~7EIhs&yUn(wcDOs>r$aQ*6m4}H>|vV*y~Bi=UsUw~o!E8UP|hx`bThRBo(TX% z?*o_E<3~x`Rp`p#i$zn0+bAa@pS_>xyZoqgefIe)OFn00VK*}nqmS^Um|?NYOKa2k zhfDx4*@IurXbUo{!D1&|@)LHD9Tn5Kp|n_O7L`LVP6|y*I#2%5{KcV++D;HOiv=1H zi7b?mOwjn?k1re!C84KGONACiagcm*#~g;RC}2DtEKH&`+sGPAcxcNuvuF61q_PEp z>?sCar=>57ys)^&+;;5Hr`q$VN#A|krv%0gQGZd^u~HAfv9GCrQ z9COAQ0RzNz4<2C$H=|*T4OZb*^NxVd9=*`gl9VMpcSg3YFF^5n;0Y zdORC|(r8Sod@2p_`3jQHroJOp0a8kYZZ}`8D9=nk0Qv>vJxB@0)}h@tI60aV7HqYF z262ufVw1vJvy=?!2GUF1B*{@yUoc|T|2nwSe!6?5JlK47rW|x>cRK}7fm0>ktkk^8F6NXutd5X5eR=)n01CfuWMHHfx0p$1BIO~@<$S_4 zE-o z&a;#utpVA;gR8wscqB(?Hiv;s4MaKFW@4tU_bExx16y$0AZiM$h+eMUzqKBHgyckU zyL}Yct!K{>>|v&Nk?12yET_u|0=ay2_#qck*JtGeS8K_B6$nnt!fno^kss^Bz4#e+pIR45!Px;sZc8ZyL{PYoQ?zc@bsri*Et zrGIvNbKW~t^D{yN$@y-qV8W+#kMO0f;s|+b@t4`IPkc8P7~QU&Q6U2@8gof;El&B> z75NzQM*OxBl%Oa(xW%cq$h>E)jdw@4=k~_Z@U=&)v9&mm=1-2Hr`ujkAfn5&8S}owDB$|iyqf42ZJoIl|3Idqug=J&^ zy0rNh|0#PUoI#XUY4@G&R~6#l7*YTPm-ggk0uVh%b{I_0Klc&^Q7_2ptw$RpuXOZmu7YWdLt<@ym=?v=fL3hNi1P zKrNxm6%0Nmf`lWn&|(!pQoB(|K=>f!QZKQ1FZRtrHt{e%dK^b4oP-zB<@pN%bcGjc zgQVRdv-3)0^b_B1-3W`UL(YAbtl>+;;k$-7I>$l{k$L%v^}=fa6iY{#DomUnSg6Q9 zj>gT?Aw2zLkdGwtAv4lH*%Pz89x~!f`Bdx|Ow2+x0suH;8oHq4?BlD^zZ+vV-oEoi zg$dN=iIeiO<*dssF(`X(a@4%OOtjqyI%!bYSgZzIxp0Z*-^9q35u6e0BxMH|9}4r~ z`KEulB;#1JeXQA(Sjy~J@_EEGrzTbhnD30Gmc&}S#*&%m?>-57(yuX|0l%0W_uQUo+_!Ynr|kETc6vr1 zntbe@*FMdZ^X=Zz<&@;v2LH|1I5pg2uLtn#2mVpUKQlO$v1&#Om!CRIj8f5?)n zPXYr9zYm=`Y*VF#JoO-xG%q4Y9L&Sb(1QUQ&;cmI*Q4v@$YK>HeFQS(s?cm2_|KlF z1df7nDVdTfvccBK@^#PPXaz8PAIT%oP&F$>Cc~2WNH`rz)kEG|Y_1a7sg=YHf(`p*i*nF+K9%aH zEZ91`x9HlP@fotn95-=})P;q_=*98Qc_4!)R!fX^LSO^}AA?JoaD0w5NTHR{q}vs@ ziFs2^?&3|u;ALvmx+j1&mF;s>Vwdy6AYIkqkvwRUY}M7APMwPTRR92JlwZ;-?ka{ZCj zTCsa3naq>Wf@R6|^>JG1ncM!%&%^}`bH6#^{!P&V6Zv>KZYf`q-R@BaL20sTtklBW zAFfy@g4Gy<7K7aoxzvahc!~D(4Qnud#69{r9A7Vuqf3)VNHMHM$7aCCmlL=O+(JDP z{ptly1441cv>(I(mUzHlwrgg$;QB3OCOc|AafKe7!?iv?w!-iBs(W-KNRC~fBdhlA zR$RDMvtJ#d6ua~w)+K#AnaC_qU98#!}WFzx(f|V`lNe_UI4(z{fX{7zYG>b=Sgc&p(Jq*1%rxujD|}^`HY)yaK_s zd~QuzUrJD;Z#SW$X%gF+y{DQYZ|-9C&NPZ5iG%9JuZ&k&jIZsZNzL_Qn~|FhZrz6d zIlT|F)dSeV`AXEk+GJ=x`$RTzH3LkQ)^v5f=+65nfIq|A{!6ey^rPHt&B(e1v#WSe zww76-gk~g3w|~3*`c3Kc($4>8&iknhTB??irWLn^yJN>K9UVem-11`Jz!yt45Jn&W{RfPqb?B(a8{+Tp!1jaylp=u z5WO}^i(>v`coLMWlCX6P_mODkBaj;t?fmv-+Z@?eSQMtg{_8@AX(MGU>C#NJlML0j zWss^bGR_2s{NW%#1kfez!KmeT3qq|*!nSsXyU*KJA_-Dl5>!CIq;I`ZBI|xxG-3Jb ziO>HeYO6tuD?;IBA)KZZZD!-Byp7xDFiO;zWD>FQ7UYFwS1CU+=X|P7$u3^|bLA{J zLNB&>h+2|^;n4iP%*#tSTsK|k8KVImdHE?x&IU=(Pp4`ZGz=Qa^7!o+NmI)V&t*$8 zfr$wm5f0sX&j6~w7WDjd!1hd*b@S^F6;juCQ?p8_=u3ZbJY}h@9ak%sFM01f~IKNeC>^gC-1kN?LAsX2d)eszj69sr_BZ&8JbV*XtUXs<#3- zZ@R`~L8i!@hh0*Xmtw#fmLg({%UBoPg$xC_RwfSJC}Pg~IWLnqxpQmn@V0-~bLFA` z1v%7Kyg(&JGobbLAR*_xsS^E^B4YJO=JY@TFbc~DJOK0;n|u}xJrajp%aP6;%->EE zy(>FZijxV@I5V$IouV}eQHQ(DwG?dbRmDy2{%HeZo(XH#4>*cyY$VU&e@a&U8g zINz*1!)0Hk^>my2<10_z7ajE9YQqtRnB7wZ=bKGg#5c2ZmKRT3_x}4ku660=u;1~g zco>!;V~j#&qwb~0OP;6j0aiypKP5=&-<& z-f?*Gm|{s@X!yfdq30|`*Jk|k!@DsPQ>!kTdM^E(GHv+Sy%X^paxT3A9ieVK&j$+`n+11;K^lvNzg)ETi-svmLgcJYjyc$Ug0oYxK17 zQP+ypLcis1mCFxqb33?dPjb}Gj|nwyRaw1$Cn^)YV*fKqWRa!BoxjK26+(hPy+&%2 zORvofD{FUvb9!9sKq2UQY~P}WqmV=YtU}y@+~2GAIuW_ms1lc4&xVr?mm3r%NtC&D K%>;825b!_KF<;IA literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/sx5.gif b/contrib/ntp/html/pic/sx5.gif new file mode 100644 index 0000000000000000000000000000000000000000..504e38b73287823027aff0a56078f662f7e102c1 GIT binary patch literal 20470 zcmb4`x=cB5wA}(P^gkcJtfCFxBZVnC(va+*RS63^ms$K>JC@HISbaXg4IvE-n zF|)D>i;9A=prqvFqhn)H(J{}@&w&3QG5iJr0RT9F`~OV;mk9trBW_b1-O5}WTRks_ zeYuwdyuO6A{ulAzvs^i*y&NcgrrLkjQ}WG9J&9`wJU*j2X#QK+`~9{ME#Bhg^RBQ( z@4+uOeGxiuKb}=xMlS#N=NX0mU$NM@piqcud`fCsdPZhec20}o1(1zm851)QfDg!BShB&y2YRl! zZCK4&E^J!he}r#+`D{LGzA(LGc67cvc$4RQ9m5}Ob_JMN*wAf3IUqR@M&LSnj@SmoVe~u$XV?Yjff!h#3ce#Nz$tDv zH}97>2=ru#9OmL5QO8QkD%*^nS7cI3Na@_KAEOq?RMX{bc z-1~hr+s#&BwjlHsjsU#zV z<_oCFE7aQ_!5bdQSnt85i0OVB({`cPn;-1cPfdBYw3h?udWTqKtQ(zq2JymfeTEr+ zy=oKO)wo`Qh7jL)Unv5C$RJ~L7Qc8}5Wt+(@Y%wO1fHr3{m1kkj*>Br6 z$)_x4)0RS;_aj#7lWNtm$Uh~SI^~VaC$D&(Kk%sdl zB%9=6hs;3QO@KcBBdCB*`)_3MnOe#{1=H)+n#aw=Og9ES!v1_|89DLOb3JErRsl}oBYk>%{clnj|73&xtZbc zlFQ3L8SSYYW$nfAL)-ROC z*O0}7m?#TqzYy@d%+Hg(W{0%r6Q?@Pu#3=1nN;$Ip6s+8FN5KK@_lZS}-icqs!blz;v}ki+-c#n{K$*=R5WYQd#8k@DJLqUi7| z0m@IejkcpJxiSzqjOtV`T5b=V4Y4Ob_ru1(b+shu7A9JO^K!IxsCu3o@~`MQs4nTx z-CnVl6Q;&#)L~Kui#l>YJAZ185i3a;Xv^q94BUoYN##PP75a*rr>G~wXH&8SIl^zC zBCdiCIa&8(oY)@BHWTV9H-2xi52tXYh^rH|9P;EQlk88!t5{`6t096Qb3K?|&0S7> z;!2~5$H77$XP}~hMomhrWo`)s8wkEqg=OX(llum%QTpj43iqn{6$w>&Lj-Lz8{%aw z-RAD4m2;arQeLI>)k;KGpw|{Y(!AR*ql{z7ACO**8NyES(wa9K*Q(k)73A<0!+;nR>%IjZN>+w~eNYoO-Q|o2_9+WR`y$ zO{WKz(zEWHUB8u?tR5Gu(Uktbz#_{xyPvv@yUX_7ZIYA;1nF!=L5Ku5=a&P5H~(3yXk7!^ zH{X2tJVEmetFT9<+@x>Oc#8SC>rhBCLgx5MX(RfxG#?zZuBen=d(^8Mq(~LhrrKIA z{B1c!Ss35ZD8ryo6_4r!6=7Rd`sglfhF;3vL_I-1Q{NNCpM@hGH23^JzvX-YK6UU)0#&kO^?`U!SBbU)Iq7t>u%sOSN_#JY?xE$jg+7 zQve}JhrL{awzD!kJja+k(g6HE73%+H+$ye$K=iegsM!_tD1~-to^Vsix$)Y#2~mTA z<>zN@{kBSHei_ax%DkOEm9A!{ydAi&Oc|-|#A!m78Hbm7Z5g@c2~S1~&xr#x;Tqcz zjS_SPCD!R1A4(H(D~ty0>hob6*tdvdYjiUP^7Vt`CS1`uqxBlqvY+Dho(;7eIi_cv zf8tZl&(UdHU)&i;XU9#QbFR2miBOZJxpb>)NO$FWjRU%za8}k^@~Z0EXqmj0!-a;J zd0%mAdA)!9`Fip9&*8Z^)Re$aN!c)cDykRR=*TUp=|tbb#7>L+=AwhIgyJ^Bod%nG-}#6BmNZwp7MYd!mSae+vFW$Er+RLZ zy`J_&tJf6Tbk*=9YG3+X^)1J0_P@Im0hzBR^aPuR#lp?He~)|N#pU6&v=%1Q`}1(a zdx-Y!NcjcjNMa^-%k_5$g+J#h4G$gKth9=c;PMh{U=ILruAQ?7*`ngTy+j#Krc9@douT_HQl zECHmNJbh0f)0cfeS3e)IyKq4wb+udiAr%G@2gr1Qhk+fqeN~g>m$)fPbQOW&iZ&pF zVg-`Au_)8mK(L0oxRhqd6>ISD4X9muSuvulz*T$+r(nDle;Gj;@+ww#W9@r+O4m#) z*PCb?@>n)|vi^3%?hYY&1Lcx&HEnh*UlA`xHk)B3XOTd;Dn0feDjxofakCt~&grXatQz!t?8TbeJ;xpbJ>n z+3oN&2CfoL?dM9jop2(j6WBqJ=cv6tA^U~j2M-Nf!9>`Tu#O0VX7cH#RkXWI@oLma z>@on&B#gO7c#(HWUj$!u+Ecn3QyRJA6)3`99mLD8YaQq@VI9gF>Bn!3GML`T(Sf+2 zMvfCGi%@ym)f)qEQ|;{-M06#@!!IocNl81Q5opZSjAZ?w|7u^{^zfJE8#Ypw9xIj# zOTQ7m{&V+9dubXw$6|&E#u!nyi^xk6J{jfkw?NWXW&mtoSlOA%keN<#k{D!%PwEKP z$cyc=jlFBjGif>!b!vf z6Q{NoT?WkC$K zyD>H(5h5B75wOz3J>!VQ}8Fm@)lO|gHXk6CZe>nN%GsB4Gl>D+~zVm01Vs#D+kiQ z_UV58*5zsE9kR8mfb?9^Ih%1+CvEHIR;awue15&kSF zau;G4D$tIu6qyQgiY==1-to*-(jbYYd`5HDkCIqqm}uAhk`OU>C=+LGH8wnpje?Gp zaQ2XXa^(1t*f6qBXL3uzHqDk66elQO=g6A$&NVq(p=rhiEHz#n40=@>YSi5>=Mh~6 z{=v+GE~17qdABjq9_o@5$>Q|BdLSvpgX_yXaRp{7VywzaHnI&o)TSR5JGHwQ8OTF1 z7{bs5v#u5-;}U@t1kXQhdN5mohb1Tm;&!`M+_0keBeD--ys4{=tvI-9V=xbO$W%QU z1~nleCtm({JMcMoV<5{IQn` z@6s3y4gbxL^ow-o$2++x^~orBc9RqRebL!gZlP-tdfe7kM%g8JtaZ1Ux#A{lO|6F^ zuRcef^D186$-qCaJ@biDIK+-$?1Xed1TNnb|9r&8<^ef%qL0W7eXG>Nq;CU4+vxpK zpe^XMi*;mXwLLYpwUj5g2`0t%XAByruk~vV`;oOn_?p*_Xxf3l)HvD+#qcySu+8b# zV(f_-NBk_9W1CFshFz<|*)NE}VF9UWeJIhIdCi|oQOD6pC`ead!S_Pg_p`06mqt#E zb5dtOkpQ;qT%)$NZ#EMe_H_2H3a1r!ZjfHVftM9vUCVUJ>4}%!ft)qUIONC`jrFb# zSaVZcU!xr()cu-|e}%$-K9^HyLweJbP}_-2Hfld+v5wUNaI&l|+;sl=XJX0Ukmq+H5~bLSglIh|*Tz z{3w{;LF=>#CA~`Ykj%0e*f?wt;G83DQxHFk;?%?@vV%@~yJVe~&%QMFD;?r>1qAGq zMiM4Cs+kaJkaIqN^OxX?W*N~e2!zeR$s+sN=Bo`MAAaJ?ND~n!h3h|9K2SS#l61sE zMp~!H8SR2s_QeDyWg%%d>qK1Wx}|zG%}X#I*Az6EM9($=z7{){>8oA)7CMFmTtpZ8M4il z>!#K>n|D`*$8Cq}yIIt^S*&u=gS3&t%<~+i3YJ@opT2f@qR1=kCwI11HhRJERMOqX zt}zh^eu64q-L%LW`kM=1|1khoj@K1$`Ibx3K?q){(h)AjIdU`C6E$yNv^qT2$aja5 z^6#vTXn3AaT9M`MS#3lshKwL1$C}UOff>4*YHO;dWNKu&^y4vg%)Fwa{(F8iMcJ9; zVA%0*z5%c-<5|P7f)HZ{=NU34@1&HDIH?c;RwMm+}{PYkizlAz%2 zHBn3coKElp^JrB$K$+0!P9Vc+)fP23T~NzFy*e({E+e@9;T&iOkZqRXwth)T1+KgYg|Y9ZGI+%0v!HqpF1m2W*2Exb3ulg7(j)Q0S@7GzbURb!P= zu~m7q;>trT@Cgk{ckSBc5@`lkWzQa_3<{3QaYL}p?EcXTGah6_t0sS2_1c%u6r4Ab z&P>d-%XtymqrtI8)4tasz-%Qzt)b#C+ixIaP% z$FQRF-8ral`yW{5dtZM}^xn*Q(P?URQ9##oU3>xkyIi6({XJs-YO9ackq|6F`|P+P z{)%7bpJovM{P|K%xA#c54`PA-_*|OWnAuM0#Uz8OPNIXtSFe?(y*qqMHS!ZostXKa zkc;f+0_%etOAI-hK~ZYv?@ZYm;b9_uvZNF-#AnC#J00Hm`N@5}6@4%1uG|J=N|uan ze}Oxi4hqd2$Z4A%3~IW7-ah(Fq&W0L(eN0db7lL*KD(uuzknNL?k?HQZAHOw{_FFDN6Wv# zn^td8gp%uP^G%hfO`kMZcR`Nli%-0EsnGEebN$gf-%-oRjUHOc!38(kr%p=|S8QQ- z9hnq-d`P&8Z?`!kzfY{BJBFnY8|G3%QGuh9LqC=sp`^xccSp38ZsS{}iOX6kH7$_F z0{1tE`}gl(*@$m@4454p8hsA0_(k6| zl@olK+@Rg};hvsXemXA6n*oo9NUsyr!JeY$DrT7Y&l!*Pd6(K4pL&yc6&4A0E-Ajv zQl$&S4utoQ)n&4-c-sl5U$D}gl}+bzq4DXQdmrcdHdUvmSC;d%rstk@u`n{u5vY*L zhJlWjKV$9E>)nw@5`UyK4mN1edE){oKoVMh)lQPq3x(bXdNSCeD>-grxb31;g4iXY z1|Scd3^IY_>Ghvo?~;g;x+HGk8-?%qFUs#o2$fl|MGjII2=N3Kf6K@*-jld{`v--+ zit_*dOFXV<3R-4P+qMJugh0icYsz*%*8&c&zdtk%a@;jY}S+Iqo(Ug zU+ciyI^wYCFkxPf?LW$Q>YYGBi6hX_!x~a-+_i-JasqiPHsR+f4OHD4kOcfyuFn)V zRyj(s@dkClmbDk1K;Cdp$)0YS~Ej1A9tKHOvxY zwi1;9Sai+-=-Gqd04jZ64F=J?BrOaBFgrgM6Qhu~FrKTKu<}L&QyKnebb!E7_E%5l zAeeKi5#a!LV2L~#7!ANe+(X+=Trf4+UKGdpmZPjeY5x=udX;mTL(-r^`L5d}?=p@s zCPMhO)2D34y^<3SbKxZ5TMR@9OE@bb2ueqx#w#Z5^aajKFk=~UPf8cYz!+?h*F!9J&8WR#yUXam(!c6jz1WEx47&fqgGQal{hg8^sjvP^nzra6p801Cs zmjO`Njskbb$c_V0_63wCk%!r~ntn6dqM8xOJ5T7&7+i>Qz_74PXD zKTGos8JQWmqV%2Bf(mcXlaeU&;eZ}6*0XXGGPaL1{}P#?+FsV$KSpI)vmcL*AzhOk zB^coRA^E^Sgpq!ZY?`U5Dp3x%?GL1h1kZ0un2-X-voSY9`{Blb1?mlC4_rX}+M_ox z7Ti!aX?_?1f=U8WK;}=Z)UXHg`!P%))SD^R@G=8^`DFNM zG52NUTY66}eo>EGwd4IpVdz3{o-u*=C)HnBjf8`(fM%@K7{lBt-k({{heMqG@hJe9 z#-sLayHaHWYv0yjoVS^*CSgt<>5?&(}3-0~shYUUEo9j63E=NYopu zNqr3xg%B5}M;m*v@--8tzFVzY2@4s88QM-7H@Ee@){`aMoC!x?Hnc7O#rnM~?yE!$ zn%44>^Vw7%e?mQAidfPTAW;e1)C>lY!v!>}2DDG(wH z9$2i(OkV0#lb1yKhr|>o`a+vsyDcRL^yGZ zV7TX_Q#u(opSArDD^><`iZ>TMuKy<3AhSy&d8%;Yz7ycbAvEBrD+%mSe z6+49$XP<&C|NP&}SOMX9ta?R^SCD`_5Oi5f`l^EXP-4KuR#g1pL?o$_zmCFQQ_CX8rlYApWfOu zj#j>@Qt0FP_>`Ng1yVILVSlNMBre_ntBZ=kr5c)ghtCKdA>n?1!|j9kbcXm%+v>T{ z4EBiiN)?_4ha_jj`Hou+i&PM{y=D19&5;_~Hd^~20(Rw>R|1ryh$zM9@wWw&-&r!- zKTl?5akhTQ!HwO4a5-1VVc@%3P0lU~|6uk>7_(mFw_YikfJL;YaEoqWZtN6RAGHSl%cQASc&Qe_XR7yAy5x*f?eW@#EGzHVSldv#2COPI=5C}wkmalLp9W+rnj8=-w`C`wX1QJfqKXO zei1#_f~2CWwRI9!DeFepr<}%p02%=hUkAVk4bU^#*B=-~OOmJ;4;Yq&&bRB`p0)l? zWg7It)g?SFp(jnzHoYdXb;6ZQLS~luljJgEWCnMP%A>{twv;zUcAqTmh+ko~?CrKMBp*so{&yEQaARxMW@9EEh4o53CgH`#fyE^+Jj8j9Yvwd{=IC&*wmi4eAmas}lZBZm+Qy@w4LV(F3Vo_)eajxzl zl2j&S?jUMFA?ofRW-o$eP2Xtu#f& zGW|aqebzDwy2rCtBattOrDw(}RbDGnj|tj8!Zii?T7ixhj)c`g)L>Qjkc=;ujy%w; za<^(J98fJK*`l1jsRWt)urfvu%KT>J!7m41Z^{3A7Uv?3+;+l>edg5HaDc}KD6%)A zwAbW|&(`%hiZY5hBkR8cxw-ndBA8Kh7eMD4tWin!Ru5P+^o+KMD8wz9bVfQE)l$`T ztrKA6i``FXi$^I?e$3&IRlmV{=w|V0PEqDgTyFc|LPFu927cIIN+sM7WHwX~!~-)b z!`42vNXwJ`+ZCKENz5!T+1^cc%BP{x;lYI^fyZtO{c?-x7>nkIY6hup2wl)`eqX) z`f_!z8%F0cmf~I07yj--kvVaIy&gneV@M`%{r)Khb|OzyrsWKFw~m%28j7Q5f0Yyl z!(qwX&M;ur|93{*R-Dv>4*b5yy+2Bb{#cO5+LW>HC%znPi=*jeLiFp%Ck^JYP4M|d zgQbl{zNGjq=#-hZfyM8m?P&$)Vs(4hBr!1K@!Y&0&=|G7pyZe3V@Lj)n;4!Ej|nBX zh)AKSNl8XJXI$^;QL5G$PYu8zL;6%W6VHcX%xZxZAPi{2Xogz=FC&4TV&Bco0W#gE zh(LD5E~(@3&?aaK;(R4wD2kFC%wKmV>~)u?Q;ikG4%D+gyK zIkV*4uGus%l?#J(l00vl3y#-ooUUwa5?@_hMC95ScSh`4ym*ylkOwC6ZGe=ic;`+U zdNLcPaE+3=m`7Dm?ICoJX=xj&y{Lu2#ZTzz>Hg5OTy3PvfX+M|URYh-H zwaYF+W|A|meCGw)pJ!_XZbo@KGWLBUaUVa1XqEq6P8+G&0`IEk;@%pS(Sd#yiEFJa z_gTCF&PHD;&PEj*@(Y_~Exvf^9r{dP4GYE(d`3r^FtiFJIb8ThTO9C6qN*-BT6q8; z&Of_f&RyrUTwm>8f7-bI_SHLfvh}iLlV{I}sZoxoYxLCrbS6Z}_*}`jgq$K_Z6{T( zzJ&a?BS*)Pw*eGo^T~=R0=SKqXOfnu35Xee;Z2+~|KDc-&^d1})H_=k!@4~GR|~1j*_@dWMAffijm+>TR9i`4S9C^t#`<`Q%qrc1RYE76`zA+4 zrYj2bT{)123E0@p+uZeu-V7kjaWuD9mPIv;E(h7eIRW=v56R>IFBD1Wh|73;1bhDl zGs6-nBH#0CRBxC+b_p=hm*CFKZc^|T7k*oBl~mW7CW<}7h4dXcxLHRXgPupZU@;SJ z0(teb1Wg2;bM>9CuSmKpwK(z@7`uw8&boWezDR>b>SL6+)dDBjpSlNTIv0vK9$+qD~ZJVDu2_+=W% z3sq~RY#O<27kP1PeBY-FfNl9PLo< zI~hS2sKSdOpwq|IQTvDd7+tIU#&DzNV2WlO#viWK9g#*5`|vw*oH1v|3Yh}u3^L{T z9MSjpP#M2c7Ke!?u=DUYl=hc9M;YwLV`XAn1B_~*v3oxG%v}7)%Fm=(+#1W<6~-l_ zH9={4tTRPat-jySW^xia3>q}GDZj$dW++`l7*doK#lOZ$L$j@i`9>_>wKw4B6j~u3 zHS|mx+{CGMrIC588pDikj*yQ>1$W#8d&NwB?Yl9j8ez89_(LN$F{?^697C zs3iK;=RGm{lU0CUI|bgn3K&}A{10;X>c1bHE~MO}e}EyIMpnO}bjzDj&XT{UMkg+3 zJ{5SAz0AVNxt#bu4EePNEU3?O;fc5t0Tk-^xfF`+A}gKP6JwyVGsmg}0Ak|(G4A3ekBk{|buuj`AS zCEIcy8=4+ds~;Qr$VN~3Oh>i3_m=9KGU3N@SufGN;Dkf%MBSCJFWXG9aTHp=9KIk; zG$JRi%CG+A=y-yBvyV^wyj4wK$LIu1D^CTc3D2&9!;B(@bHIZ7r#@1{7p zmdr08sWlu&yj;7^@wESHE^uYmXypbnvBsi_=8pxe)a~_9Grc9-WRR*{c_K?KZ&Rt# z7PE<_Cb`u(*yqX<9LDOS7Dw#n2x{pTtm&hj?oj{x`Ww36TQE1!WIB~uQGxyNLNt;l z^&e!OuY>kiJ5K!*bmP`hX=tt9P63=SVA5@z1Yxd)9loQf*+{f7I~^f^aO!^Uq#Ru1 z_>!+Gq)kh9t`-s-q}BA72OC5n@`AdV(fop*|97D}qc~6qx5&P4=#Zvae}eeI`KWQk z03$a&f-CkiKkZnxDpD`&)D876`05>QEd*i9u-qNFN8jOrNCamZw1eZ+-_PUmjdK|& ze<29A`7=ily-Hq#DzLTTK=&}TMa94A4Ed?AklLN`WbW1GXk&X*C?aCS7N{wXo&Qe7 zAzWi_bF@r4*}VQ$NYC6s!MB!XOYx6bwdGgDB8r&+lQ^xpzoq}wM_$liRLLt|C0SYx zORGZ3bTfZF?u-9>MQEV9?aPq(J@(z<&tTx@Wk@SCgmlYjz@^P1PZ+lUY&j(hg~EYK zjK_uCJyO;rNxtgr~a210+g#BZ3UE>a&SIbe-Bq^9Sp7iLkJ6NJNXN`|k_+ z3g-K>2L@p4>x~$!xw4GdbL@V7#G%Ihq)G85Pe!5LQh0gX4iard>7hZ-;DMZSOWdTFK>@gI zT(t{@?XEkO)#D2Qu55V0SJJ7(#$f&$z&B?XwnQLAPBcJZI4jJkHP<*512sxnC%JZ3?)o=r9%>4AXm`#|#-H4&^ zi<=30-9Kt#rTjfls@uYY?BaS>YcVc1LAUP&75#aodz1V=Ydb(w1z|sTNq;e9L?_~L zW}-Y5@Fj@7l;{#2vov^T9kX>_U_0gTR5P4pLX8q@2!%GXobs(-VLKPtr>Q&VK6x2B z=c?4sIv0BnW4o02FL9g{1$<6)DGR%vb$QdVbKz1Rg|FdS5hsX!UXjE*=USC^Sm^5T zw)=pYzD@rzj^OroOG{r#uD4Vjb1(0LUjxdIOc?KLU)IJ_xM#}l#aeu{42bWBXrnkK%Vo`iCQAtXoYR+>XB<)j)H;a8o8 z!(=+*SR?R~*Z!sa7&ZdhS`=n~%k;{bu`IQ2+TRK==_p|+CKDK7GIJ-1K!oDjVa1~n zB^^*6)jaN#5>ad*n{fvrpKDnIg8*-(Xe)Q-6jM}k!z-p3mWdgh`6XB>!vt(UZZbg` zW$G8>Z4YXT7O|j_&tnk*?V}X)6C*Pu`k#E0tG}-D159jCe;+=CMB5AQ`Ac<^3yWSM zKz*DA$8ui^CQ&`J(+YU~)F#HF^T_V*=gn?fais-DyMTBn{90e?kLT+#LmL{#R{Q#x zDOcRtWVq z3G>iw{Lz)Ty|i-r4uxIHs`~};KVW$4e;C*B=MC@E11o++={TI#y_L069}RtI`>4K` zN83EB#6)9fw%qrjsBO>DO)X*EdCr$NoaQaFb}>GvkE9h_V3d@}Z(OC;F7B^BgrpX= zAhlLY?Cj`dEG(t&+ku(ocE?QvlE%A}o_<57cVIuDf#RUiOCg5>gB16dSsl+3eURQ9 zmlk&H1<*JI6)0>?PEL(x4QBA{*v3<}ItuNJ!o`THfJ^pK@p&Ku$lN};7FN~J5^0~cjB7`iDlcb!73KbSrGy%J z-V#z@Ek__ntaFthM*a!RT7jtH_+~3Yav*pRFkhZ2M2AXx>?o|9tNx41m}28AZ#$AlRBxXd^nCBjb!#4vHxuZjOS z#QSTwr6gE-GEoWKYOHwdAE+MKD`Io&HxVjr$${myMHq=}hiP@i0dodI+zXSkCk`2{ zYUupjc2Fq9Ps#)t_3Q)-X9F$UYSt<<7*Tw4ZlSvu_G0IN_A^q5{q`Y7VDDz_DpECQw%uJp zB}rDusMaW;wETPNA2b--kJX#qmds=CW|`ZavnSLb{$ttt47QwkHU@=7N;9uAB+1DT zX&kC?h7~9p5>_pw+jqm4cL+H-6||PZMJAnIl5BY_e(r0{ex~KE_v8o8vPp125cnjU z1g0H5xR=Lttw|oo?!ec-wrYm|-3Y1wQi>0qN*gkk*9k*`j%HN!>rb-2-F1HSu3WKZ zoyaRrv3_>=ewc-Iy_9E6(aHtljFBWG7Hu>=W1iTG*08p7%QODZBO54|s&j!Gf{3c? zd@!~>y``^)*6FIQxSK_zVW+NpNm@V3zrmTX`XO(26h@QY6CwE4*b8x!+K=T2SD<`H zzSkMw)CaUTP(2QsnyjOFkNcObA*QMpSS}Sz)lxn~H{eatCmaa=dX_Le5GaJL>sA;j zC~W}5>J0yiok{SSwn~VB`ge|Cd;#9i4n+(Y!|;MQ0QH8sOUcVvs2HsJA)0dJZ<_?? zvel~RQfIvml?j}hX`F;=eJfT@u>Hu6NsZtKJ(0Z3#6G4b!RdFI3t*D4NGtcm0SpJ&sYYo%8mS_3f4*2xs3!yR6LX`wH$Tf#jj zj(^ADUXG;*BP}B_0}_O=rknL9d`hQc*bo6aBc=m=$s8%x;u|Y@q^WBRUVohA<5%pX z3x|roKFIDOX2$xqa(rT21__SAZah2+mTADf4BrC z4{Kg>EmN(z|ACZgWVz)}ShN5yG(2%gNVlrRBjmavng@2W%?o32vx;`7A zFs*+E_D_4$zU1f01-NCZ;o3#CltW-_;yGA;E?uDL4{%5}ZbOy=hCPI-JQ9BrLT|#@ z&;~m5qk0jj^vZ>Rg@dC^0#L4?=8{xZElv^+~_?R!Fxt(+C9?sx{zbEPR+g8_L1 zQM`Cg^m3P9ryx(ikCB^f1|E|>)1WwnT%HqWEa`B<>VDE@@jRs+sOKjb z=lDzh&wa{PLTYpt{ReU0g@V*C(6j?nHYfJ96W6q}ZJXnSw9A>aZ{oOL&(m(9HuM!? z-|JOxDEPax@Rp{o{>(F}oFOTe2gw9A!2P&H7WaA1P!Z~&ggh16e^cnzjLZ#CcchK^mXf~s<)`Sno7qq8lZL12W+Kg!k2vlV*B%3A!9yvUM&*6aAOML|3;H~` zDTq8FAE@Dt3Ty)iBb{?GK(L>RuL98?@&=>`Qziv*qvyDC$o`fyH|hoAr2_{WX5k3& zB|`41KW?lS0W+isMerL`+jW3m*|Rbl9hg}%0=UM|m8(dO_&37kZ&>t6qi>i*dP!>d z5rMs4sD02X0KlhFA-s=`t5*>mUCGE{kPpah_$h(^)itaxll4gPUxVv^JC>W%d<@#(tQtV((1w>FY)VWxV%9jyNlaV~bIF;}XaZhQj%D7!X~BuP&5!g% zQOlF*cQE0T7{ZYI4jknvouPik%5}CkHD(F==E!Om4g~?usuvCQnHdxryWUC_ujk2$ zsYw+Yeuk_2RZkPSuL@v!6u50&u%9Ku7?fO|IYD4!jeK!CTF@iaIh(j0XAEh(SW$0L z`Ae4=-^RD@1bqSo42NKS7MBmGhMX8s6nXuaJ7tbt#I_2F-35IRlOE>*z8QjG^%4IU znbcUdlfErSF%{%(UeLlCe@{}i+m7&AXe?!5izA8aD<)hHag($;OtDPT7a`n}asppS z^y&QoS?xH&CW=mI<5hu{<#=UeK0GjnQWJ@VV~fL@;m&Idwg{2^+s+TV#BTdVUPc`D z@*~tq_i?0a0X4HsW2*w%AN`~#kxV#@z2b0%bt!jKqp?wO z`w8d;gcJUOf`~}kp_oB?3;(5u)zd2Vcf~$URbn0@p)o*I`5&4)#mtv6jO=%e>~Yv% z2U>4j)8ATHBQe+%HM?4I2YZtTW6d;*cO-j?2jAlkU7nb=vfASm8}^i4_HwTnG}55xYZDbZ8z^?>{0P|AM5=zW`>mvlc@%gB4xhO|Eb zTVZ&FI}VPp3xU>0>OMv_0U&^OkDo#^$1XcNzfFcemhNd(_ivrNnv!URJH&}UM;fJ1 zcSf&#Vj?x^|9-uJ*Y=IX29DI|SmFK{P6>uH4lX?>)pVv|FB<)%?+~K$!oaRJ5Uq4f zh{f*N&RH^cNQTAWI?2G!toK1>x09${aA4(T+-`bs-gS__qSFxI_va;5E7~z+2Rv(6 zV|3&_5au@>D+^F zpW^pf60l?9;o{gwDT{yo5Xvsq(U%>)_yAcJcoBvh%Wex*6XDuX>?QA=Z$@DdKS3l{ z1FpB2z{JW}n(E&|Yb{;q*X0^H_ghwoxa1M7J4)`!D||Upx}kPzr@yDr>ewO~7+)ir z^Ce07!b8a`FPACKBcD~lS$%h(J20)Fa4mRxAxT0S*>OpyQFA*X}2!exv^vybnY0z*stBui-wrojR`p zz^0=f8)7$YU^fz!h{TW}^UFR`8z2>nhA(3{)fp{(g{~IyoU13@=vo#dYFnz=z60z6 z;ak85OuqmB`OZm@9NtBzaWe<#G{Xf97@>%NzbanM3%$4Aj9(7sPKxWjZjJ}(#=P$9 z!%pmw;=9F;?8*Kmwyx~W?(9dx?9VRkM514~?q7gtSTP9-6(Zz}xMSiH8-GO}X2l#j z_F;qQLHLu9e>ISA#aGxakolcq3AtqT;Y=tANg{R$#WC*=k!1bwayZ4MO17dav0s>t zFGVI3OQs&AG<*ue?E>G^#O1UxLB;@2@Xo@4z0pz(2EoEU1SBm6ObS8(wtk#!dR%MB zZhCmsrudLyk0yvkdwto${&Re5t@D~VsxL*@2^D%*GUiR`3 zH`o8%DGGbWz?0BvN6OJ+Mi)a-%H`c&=lK>qNh}#uHcT+*G9gy0mD@xwPnxXg-i;@S;vpOyM{A`_bzOId&*zpEdHk{eku z>ipkb$uTWB+2LFlRPfeR$8%CR$M&{Wn?!Vu)DKNZh=B%jO#sgOu*-muy|@4g-w-4f z1Ilf|NcNQ6LW{Htpcr+~bgrUge?)L5gI+zCSQ191@Gh;lpGY2~92ME@&zUAWkQY zNjeOUBt$ZaxK$wn+x8K_K7ZF1;9Yv*;15D{-p=X@VSNzZ%Rt#4M1bGJmH zagdPVa|YBr%$5LUD8$P;@0DcJ25{4@3 zr=C#g1sGCG+7)2}a%j=_;YB-QC=?KDY{Ft3NgxTEbWutv#ZpsRc_o%vYPltsU3!_+ zCO&={)tF@xK^bWPMefs&QQFj75D4~TKdMKia zQVBtIiaPozq>)NG>2y_6dMT!v_Bq!fnm#J%4*>{(q!kPb;XqvgI1s=9F`U?Hr+UHj z0}2P?_TUd3SrQ|zwpu|dhH%A_RZ@@dIYF0 z5XD9$uma(LCMAqT6EPLt5zQjx7AS}%*SVW8h z1sW=ya>%;^C+Sp>guxKA4kBsC%*PZJ=Cct&9$bWYA>)%2W7lHkL;wohTZ{~4;Gmly z7h7>+Km%9GXveY11Pg@Nm_VRwOT&Ri9w}(iEXk&YRzlk?IVf-=My|9T1RNpRtijF_ zJxG89kY!NUPJAU2vmBYM_c(B4Xn^241JdjoxtM{ta035L+?s|MiYNCapIbqBd&xb4 zxh{MgK~phe-m#=7Q55wL3!KhPPD}H>!cm1@mkKshj9+4`8)uMkPlDveA#tsX&7j!`nt6+)->vz<9AN}> z0ow}raUy!aC4fuIp9{XCnE>D*BiB;^DZo$wQZ3F_0hoLC`t?up+p-%#Ues! zmVv$y1FH}wi|JAuRyJ~sHWEZ67eXUE+GxWt31tz(5CI(xF-Q?MBQZI!zibza@aXK1jz&kSP~$dg0dn0AcoRHK*bIaMv~~H1+UBs7Iq+r zx%J{DC6Hwd&=N*AxC&bloF-o$iOw7$)OZM z*@O6mpuiK^4hzAFVmZsH05oL96X&T579jtVIk5CmF8u?~JM@qhRl%Slyonha%Ahbn zL;(egu?S%{8moI80HwOHrAl$pn$MUtfrY3;f;O=T066NWS*FSXek!Tlu>YKrbrZCe~70PFfhSDqhkaDxT6RaRHG0&@>MmM2!w8(3kL8J zNFvfwxkGr%4~dD!JXEHLy8O#M?(st+wvbl|Z73uJNUKN?iwYevE3asvtZKkViX@<7 z3od9Yo#KF4i76sI3u0nRs*zb=1+^*gaZ>5{1E5!xMp{li0T>VvN6~tVv}9%MZA+V; zHN4hdX?-nTK}4_{P6G^2aqeqbyF~ws(Uq#d>KkNvTUP)e&uah$D|o{zUTuJaQ10-q zrN*n?^|Dt{EinKJ|C!$Q(zm|$y)T=-i{Jh7x4-_C>U{qz-~kiZzxpjOf)lLZf$4Vu z45ETmb zl4C?5)<(sJL0oM>jWCQQYb7|zW0Oz@;`#zTu!%#&w4oL)4<(Y2z{9LufCAl=rV?e< z4HSR@XWwWt29O~JBK?5}xCH;f%>=N-sJ3!~8ClGhMGcDxIJr+6EPBdiAwXvV&?q6O zY#K94@|D3j;Y%#~$P=@1j7UAB!C-pGY?g;VS$L{2vq!aH4g(wGss=MlaShdY#I5zr zpi@plEuE#qjH(>q6EK0Rn>`g1{-I4h?1LI%nx-C#sAqUo8f9deVK4i^ zEAp&Ep_%jCq{D(Gbpt>e~#+9{rEpTJTUc#8?ex$R_@)5zt` zWCLR`8c~xIWJqQ|M0E<#U8RUzh>B;b4k-O3a6qAqcF)2YICgb{*W%M=>Gvq3;jI=7 zwW#axIO*0=MrW6SLm8(x1Sa|g8{i-sllR40*QT^$Xm}t`9x%VnbzyefHy##B+u-%>&S^eYJy`DZ)tpe-JL7ZaHUuEZ8JYir zERqxYP;Ao*v}gb6I*EX9VBZuS!&!Ml<%LiEp&p_s95%t$95|Rxh?>2OUQ@Y%0rXVL z2|>=~pB}sh$)FAd%FVvrR=<1`Z5YDz+)G+igS-I45V4Q9DAy!7N2rW|6RZF=^vVyM zS3Qi`hJaWAU;-l4M1PQ3Cuq^nxCd1=LT4FK~LBp>uFJr1pzgH0em%q z3}7LNq)tu0fa39OJ`t0xK!JNKvADT#63J6=9$1jjm$ahRfqsY1qGcE(F&o!T-3yfVMQKzqX1gPNQlZAK+FJA1C0#> zsI5etNx@SrK(*mPxoMDcM8Z0%${`s92r=5SmBFLIfB~GrG^)V=aF1Q-#6K!VC1jxS zj1pGJ68*IwBD9Qws6hFkzmqd<^fOtR7ZkdWkc!95N}TG@?bz+@H-!?RF>F9Jb1KAXV|gJ3Wp zMvDJr9zcvzt`IrmWAm^LIy#4L6vB+GBlJYu3PogNJb}DLBZl$Vi4B3iyvsJqSOtPd z7_G{tRUiPASdyXGiur^uHjClVCAipSW{ur2fesbv8G_i2ht1`P*(DjON@;`#tE37M z4Z`EVU3t(LlG$34X;`Yzm<~Khl%WNItXhhJgWoU|XVREs;>+9cWsL<6YhjKAnx>0= zrew0irlI0e^3FQpWzRTfja6k`zU3ig+APhOXx^qRO__&f!5-bg0R3iI+2Mj^r*>{9 zp3ouXVJCNnr+AL1mZS*5OdENor+TjEmK+#+z9)RfCx9iOeAcIZ-ltmPr+)5deY$fe zfBq+cCYXN)D1jE}eo@B)7=VH*rjov7Z=BSSDD3A82kNzl-2C0w^ PDUlYbk-q3Aga80LY2{Kp literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/thunderbolt.jpg b/contrib/ntp/html/pic/thunderbolt.jpg new file mode 100644 index 0000000000000000000000000000000000000000..49253ab543e8a308629bdf9fec2f24742cbddfe0 GIT binary patch literal 38718 zcmbTdcTiJr)W;bJUAlmjP$ZEO5a}lLA|-SJgsw;r(tD9!6bymTL3HqJJ0Q z?;JoCaEpS1ih}$W6(to7^(`6(5F-N}9Rn{LI}=C{A_NtH@bljnS9*9~R9=*yAEpDB zS5?zQXbMT|o9L+^75ifw4 zfe6Sz^tTJZ{coP6ME^4Y|K}hg29l7HkyB7o-TLRyKo1}$0s@IifTW}(B>%ia|2+qg zFpx6d6;md=ZTOU&*NaI!5?4S0R;g`gMt=PTk+AiSqNHNE!^*~fkB?tK5GpAp{SXG1 zQGKMQuAzz0GBP$nnVOkf*x5TcIys|Ve0=@<0|JABqhn&@Uc8J?NJ&jg&v>2rCadsm zQE^FW8KL}rU427iQ*+CQj?S*`p5DIxf$@pSsp)Ss-)DcUtgfwZY;JAu93CB?oSvQk zzPS94iwFSxU#x%k{{{Pha54PjA|@dLl92z$MMNC%&wvahq<6*07?lmlpL*Tq6_2D~ zQo$9}wo`&7kiVF1y}weiKqP4-{Juo0E&R4 z9=qnF;LES66a3s3s*~5wm0cpMJK-`qc}8kXZQ`N2A{(5eo4SP&T%2D%h0Az4-W-lj zzh(M)iL6DWIDA;U@y+hz4!rSQgZxnHm+}_SLAUIgj}n+^X1)uhujD#kU^T2R+22da z*0UbR7e6$7K;uFRTQslPm@YiudffJ5czM-Ra-!S{e>Hh1ox8dbpOF&iin08WO+Ge0 zQO*vPA9{D5gALuzwIhnqQ>e$&I`5j=^L5SZA99Zrt%(HWjlAta@5lgxb5CaCt4hTB zSfhULe4750Vlk56zoFIx=x1uoFlA|6wD$tn1(csNJRVtUeFbbJXMTlF6E~}B>q36y zwtFP{XogX1dw1BnA;FSWyWvAqOUb?C`5~~TK}z6iF;DZFrGTDAkQp|Doe<=;(KzWe zBd_~-k_6Y@_$U#{bVYxP!f;I;n;f*`M-I@2%jIFz+#|vzaGc zf7;t2QS!mYDs1AGL$K3fT}XDDaA#==^!{dvmx^mPBQ$qt>48;l{jb=I_T62BcnY@V zX!W0sKBM`?WtBQ*H}31U6%%X(|I~ilu()zLEH_p{>%GE4MQ>RBV!=TFy8jmIjUT-u z_}(jSo$<)){dC?+dmAnnclqS8q0SVIRsF;w13m3f8ZzNaM?5c7oT4Y#;Ek|4Ze5P7 z@4WP51aY!@@bYAQi#l<17MndAtm1PFCh!(f)Xe3C+#8&KMLO3;33i!_j&(VqCLslw zni6tbSD^I;!5T=><_Nh)ugZHb=}bm4HBMk?PhL11)u*_O)6?|+PTEu&kbcNLk|reB z4_Gspd)YH~=S!6=V8d<(?+-7VwE{Nhjo{K>z-2W&EL<@$5#RZWKLT=XMlU-rCa%W2 z7_UOuE4R5#M&$`H_{6HdvQ1}yNg{9y{Jcm+-Fx_A>Ymf+KsZ&py&tP9=(Kc?xGVQ5 zIUD?RmF9ykIogqm*;I{fWDE?Y3TLbET&ewdQX7wx)F)Ts{8OMju~}+|XpF#FmhvAL6TNZ@0?tp`Y<^KF#H1hO6>CT}v5CUK8S=j+ z&t3~*7)Gm1$xB_VK%4MxWS&i}m=aTZpNC5Dr1q!kTggjCnxNYCny|D}OpDwaol7`N z$8B07o2zT|S5Xm!_Z?2euAx*%UV8F-tVDt;#BP5dJU0HplB_sS>P;<&XxnK%TzzEY z>1jF63c3l1I~{ci(U~Xd1=sE(^tEeea*Aw-G%mtF=<>WCa^+lr0S*mb&jWa<7%td= za|u?LnCuXu`r51Ggy;5k_Mi2j#BFzBmkG93yiJg3?5S11JNUI?;Mqn>`sc&Taa1o1 ziTtWWsm5eLq{lRyMT+wJl-zoV*pjSnXDuM{R70y)4ztJFqqt64vw9R?4>&25RP?-( zoFU=Odpwm|H}$r_|G{5?OV9A@Mk77;bOOJ0Co@IdkiBF}Z*a1Oxu$}7P3W-32ZNs0 zdNx5<%JXs~?Tu!eg3wrnodp|D=1$+t)G*?7}G_|I4cwj6LO1%34JS7(;R-JfDio9i1z zi4ZxWZoS62+xI@4mX?biHgs$t4cQ_CO!S!}~8j;3paCDso-`7xAh#$KR^NW>Wi)CF-ME6SX;u><$zaqVh5C z@wB8m5mD-5MjegO5JdSwY3fW9c(DnD!!Jazd;$PeEF5BQq-JM@=V>I z4M4YUR767aDRq_rBuT4XbCX1f7(^`FzQwU|OfYpsI3+wEwN>wq>>ri#)J$lBow1hh zvG1`-uEnVXX>gA$E$O_&#h5U5xhMHANK(k4O&P{HT@U5#8i;kcUmupACAtf-h`&wN z3r%E%0S|zAT9s!0Fv)Ky$nzQUiK++AXSW#pAL=cpGvIAr?~Nf@+f3H%xqDvp4 z0YgHtE+xa!$zDjI%u%-X9a1#goVx0xY|Vc1)Lk9*=ENGUGIW1Oc{jg<&*yx$A{{`4jAiRklr%Q{n`X6+QlHRQyqtnXBq^34= z_&6bP>@?9Jhhg-ZSWHeAO4fKBRg+?;;@(bR(d~TqIBo1sgtvYbh4c~8?&8Y@>M%Xv zk&6Sat>gHljJ3(c!oYtO%&j$hzeIE6A}vas@<6LR0-$wrvhjvbnS`u&TgzNJF2I3g z8E^8k%D?0x`TmQ8>GI0Tq<)WgRgZH}{PTQ_LSeRqmU~HZ!6@;Cj92A9R>?1rpw!ec zV=s^ZXDxD#p}(?dX8e%{-?D~I@LAD(i5@<3azcd2u#JD)WaUBgCixC@`a}GdeQxP4 zLitbcu9_ddU5zOXV5r6fFg`oJ;7_NPr+HLnnLEi4joC=88!PrB1nN5uXT-i3n|fLO z)0UMXHFph#qAP|*=`&|XNg^Hki=t2vn&vG)A*Ibr#@$c3Q+K}e%_YC#nqnC*id)@P zK~z|cAJklcBr;59>0Fe0Vcq;pT)GCCw-F!t(x^{1k{)2|Z#x2Ki&P`0vl#JAsfdht zk_Ze@|ABUNmKv!Zsl2-8X_@0or3ieMH`WJBu9XJ3Lqa`~48%;r=~TpH8prjZ&T}sG zcQ!a_G?`M{nSOmyP=|tIG%`{#zPn0^e*yg!yrN{Jng#`cNW&o(Cn=Yz4>7}Zc&dRFLP^xV9uD+3iB=?k~fUJ7YzITBsYDN>m53(P>#bmZ@$B71t zd*=U{Doxq|*kwJ9PdgHHWr4o76%9i=Q)yV?Pbw6Q#5dWxsjD!!_F~Ukvz|H4(Xje; z_0cMw+ts8{o{d-YC{CK{AI&G{#aV-c*566d%c5ZNU!^(wRJoh2=%+LJrkrYOJZEy} z%%MLxly3Fy_!vm4>8n8fEEBpIB1&Pys^Z?7FmO#pEE(KtLar8rrE8^(WUmom;tKs^ z^jK7LAv*V@%6*V;&97LHXFZJp+mn}1XA{qcvYGeeL?4zRtERl#m>J6iw|DcjynFvN zP%Q}@%o4=SQr?JnYtAZawX#1Eq@lml@|1*c`x3vn7*lp_@7ULkj_FzV~tk+`vms!iu;fH<9t$z9{R zXvzzv%Vemwq5tO- zjDKv(ANOj{!1(rJt=+xEnkBKhtgyXG|3(Q-9OoOkzW@s|R=mKxfF}9=s5hw)ai2fN zrw6Uze#iamEH3BmlQehu)-x0LqEvE*?qi3#`LhzS`J5MTgN?$!-Cb1KEMvZ1A>1LJ zCwLLJxtvgPa*O^`#K5EHv3+(}C?zKXA{|cEBqY!DdlII@GlzhS$YZ52ddF1!uWIha;=q_uZ)ypT?m!1-Y^ z9z-vC{!f)tC|qg!l0LC zwKO6^9^EsPaXm*MUn~z;$*l}AhJB73Fr9B@?5ARMXAaypv3JBZHNg*bdP285VeLif z4fkD$d=jkjj%ffvnc86>nwVC`HhR=h(=xXK@+^zn>s}}s=7g0H3NqZ&NT}Dct|b77%D)F zahSLBV5_k!o)6u5_XlSUVHGojN{`(Gc%-VCSR;Gn7#Zk z9fEPJFOJPiMm(LFu$c2E2#uDYrM%1roCDU9m5Xr{I`3F3kScdbxD?YL^>tz}0fdjt z31iX6pud3AoxqtQn;H<8k17vTFNm3Eq_fqNF5IGdUmMhJ_~F+AlsLs+Op)IUDGmkE zWheN$wGb(a+sR8<$XmyNZ?luL87?vN>giCcM){2S7zX_cYJqY9BQeO#9|>X-)OW}! z$l;ep`gH*3DFX&x{1I&9E!w{~qHQxeeH+=)rIF#V7;NmV=YYBB>s)eUL5(TXOrQ01 zSkY44IKC0C#sVk9>@2Si_i?N~JS^@Xd31dTA#HhS9u<8D)Rbf$#c6Zf?B8T#dc2tdQF!J7AVg5>G)S~tuR z%52D63?FlwyQKx}Vx#U1GJLBg1QSCmWO8=?L>?sIEJNxsgSd9G%yClNa`Q3n4=&DU zZXWkFSKk`H9#iSij0UtTuW}OFg7CQ%+gSf8#8$j8OjaRO8G<(3yk0v{9-D=MM!`jU z)&1U!NvSoL?0v+;WU;l3^S-igSx!jJQYT;)%YCu#=GCf4h*74NzVi~yK3fS++^+F3 ztCow&uS|BO6hk{DK2yfq!7$mx?4ZR3yuD|VCU7}blyXm2gRBOp<7>}=nM`Qj9g#7> z&?zGckC$(lQ*9aUgcujH-0HhV_x)CzZ3YwMcZOWJu>nr4EUI_4J%e~wPnc!eKKYD( z2@aaCR08Kt{=%-=9LWHcx{hkw2-G?TTts_D<(X~#TpYK#4ltj!4rZyP3RL{ji^PUV|D28Si@tin%np zio2E3vjVfIcv+ntw@;&E@28*X*F#=qMlbI6ph-T>*c5c!L@o1YytR!JAKTY1_X}-- z=G3D2eR@*HY;8~a@lb#8ZL&1RZ2f+=?yX!m=j{hvGV1-QwvH7c1e8dx> zEa(-^ly2^J6Y~V-xmdZef;lw!cXhDebEp%F-l?xrSqaABsQo8t(+EWA0b@G#NmA*Sp%@fc1#U=BuZ~p6}7CSN z4Hq!!VJsN8SkJ1)`v!It65*dkfV`(S5rgjah)o)L3eKmg%~l-y!@G^*q_Roh!+G#i z*#yqjSaV~65di2$a=e<}f%w5h71BnTlhB+us78`!l(cCg!W%gA3$Wc^pG-;Csxy zBpR!czxK!Y?u^EJqr0vc>f-}#;Yici=MPZs=ws6Odl}ymoouXs0fAmRSjxLYQMwC# z7TUhHEs030b2-vNRnOy0>l!mV&RUI3;)SlcI6Vz8Z}wRnsZ{}243)Z0*PS)*su4Ox zEfz;{W;G%vU-DwUZriU8DCC@HQ2&9+LSu_yJr7J#K>{gM&1US71d$TWPo~MIJ~bM) z3}ECYCgWJc0JEwf@X+6~8n%H1AY#LAa9y2o1FVg_##ygC}2JytJ|5em3$;rmYdN$Zpk{<}A@3s+=|kJrnAnz2B4m>ovy5s1=@MtLLAiT4r)r zNFk}%bX$Qz5c95H0?l5=J=2NVcfwTWkDl}FAj+D&@)L$(1I)0UP;>{MVeY?FgCa9d zUn3l7-gf@;-DnOpCdPQj<4rQ4b-P2rV-z0gCnktOFF0N8q;k5y7Y;iJgFQr@REGQpcn zfbqbd{TvF(HC`!xm)cYQVj2dBjnC3zE;CVQHJzs*5kn@UPYU8EdQT9l1hOLs7i*2F zi_VbeN_=Aid+^GUvYl+JwIwS0eYe707{|oI_1|3UyQIDBDiPh}@l$AE1%`#~QUSc; z?Y&yDp=g>q075PlO=czrSHQC;_v|RsV6Yp>%()AZ!U>walJDmVPia%a71l>!J?5We=LV^WGtQIAN`aX^q-GX`n&(Cj#VYC6O63 zvW)SXeiK{;DrC;kf6o1@WPa4QE8}Igj202wdD-#@mizTd;s|naT0Lm}j9NtqdYW;4 zY+sIrKP!sudr3%0X1uLe`%1clc3BSay$n_q*3DA5GH#Fvb6zTUN)arefeIr?t*8Fn z*MPW|!0!b;Og%@yfa9et9~2!kq(h59ZoRxIBYZ~zT64HKPnkc4&pz@T3-PK!x_K%=t4edpic)%KNL>Hwd9(F)IoL4Ni)|m{a z3hW~&jNxA!^|iI%_@Nj;33jkV#F-pUiPw~;`MeG(|+#n)NS3^V}OXzJj;=gliP zyf42yjBE0TsOdfHHbz4)Ep0VRVV$%Sh0g9SKLW_dgqa}NfL%x#g9`V{C& z;903isTK`pSZdI9nX~7iUiKYgUHl~b1@-~1ue3)!sO;ZC0vU-7yDp7{9%VE=@!C67 z6^z#4DxYx59P4`XSaUhgV!WZ5Pq&f+m`mfMCGB7~uI7-KDPDWdEbP^{6~JuJ%Ly&~ zD84LB?(&gNsk+niAmJ6}YXXpp=+kX1(YC>WmXlC~z8wzPRY{+`>bX`&+rUF?qm}Pr z@)tmr9f>lHDSSB@2ma#XYroeEJ1NaPVvV81;!nz6iMnsfU#n>gG6MQJ7%*ILroD2* z0D1s-pivXSfR&m27qgu71K;0Gai~?fYVwW10=|xIW+i9<5$+pnY4j&%cX=`WtcN-v zu42tzsD^=t-6Lmv2g97M@hQOP$BQw1PzHaAH&CmNnSQy)kcr8wO-%!XkfTMtA> zE!Ib^d*2G}5L*HllbK!Rmt&fDqo+%<7$90;A&`=1*Q&x43A&*T&V!9E7G*YFvun{D z3HH$%kDD#}5t1T`{wdwGf25yZB2&9|y4}>O$taxfS;})c5g$ZJq|6mzWYZ^W$r0ME zEeq=dWPr=@1|;M@gxRp|^;ltmY^r1?C(&tHS|kstcyO2$oYX+rs*#Soe1aI^6vYGu zlVC;FDJz#`crf>?G4?eU{ge#tyoiN2k<4ZX zY81=MzK~U^{4Qao3^vv_(3*)iTM-0Hu`DIVOvC`27uDb`I-aam6ePz75af~%#dsV- zq2;m8eJH~b8Nb41{mozgYo}~wY_m$Wu?D7!4}J8Ys?}7{bMk`kzelr?>>uD)a`uJD z7a~}w>2u*bVGRs99TDPGm+bD}bj!8hW0?_sSAr#Q;Pd>e1p#6&KmIg>3VVE1C#-^H z8c-6NDCnTIPlQi3)JSj)51-I z;i1QmyfS6QdkKX{i<&D54;J38-dknk;r6oNH5+U(9=u6Q zVubaXfbt5;Us0o}U*7^HB+R?Zh4D7pN=FH-W=5EJ%XQ+f$gC>(E7LI!Qt7861hQV-TFaxLXQvvRqgk&`kzCPdL0f&rCuzHlzI|dg1a&r z9Bucr9bsq=?*@w+%(JeM?WfvT`E#VSncbr?q3#a2KZ=2=y_t z?7de>TfrJ6@zEP5ha~3kp>MK_TZI2RfYfsBI^jr%8eD?{76LzC4dI_e`U^_K(^HFcHxuA=w+VDTMZx;1mkhKK;P-ChG zq#2$T=aUpO87g&Tq@;y9v$Lf6=oT}*(y;>h7L(w#dqT@*y+sA@*f1Rai?3L69d>t3 zBwz%+!p8$(&7FEMRJ;bahlcKq4`{75$=9Ope|kumFaKaZP@A`!y7pvfrEyP=Sr9Pn z{ZbxGdi?vBqQ!_VJO6xFQ%;l}Y0`A#eYQL*2OuXIyejhwUOc;AV%v3k3~9T1@p~%$ z(?n%E%U1rSdVW}IxJ3uz@hYMfXEtZWtXtbSisI1NaG6E#Ts8ja{k29nv}|H7)eE_x zcYAuJk!s98>0S(xi}9IDc-75bE)k~QQXj>uGakzo^B0h}X@CeXZKEAOYO;mhJXtl* zXzVzA8C28eE0-0uGp&u57VT5?dl76k@=dc?>tS8+>-BGMB+i@}|7pEq1M0N+>8(tqUNFDLVUJ)t}BZQRqN zK6%#g$A#suB*j0uE*ftSKH5x{SKiWSuC~*goMj{k+0bHTO;IVT6>Z5@(*3E|#=BGD zz1xd~vSF*uGzZ-ojd*4z8EJB*7TNNgskY?R0ecKJbYHTc?_yt+$lIyV z>vH}UlIzta$TaPJSsGbf9pIz2vCpL6rSYL4g@O}RAX{0%?5=Q}J*!cJ)+YaW4wbA* z0FMnh3QjeeH^YvT+~08<5#`|N&^=uS_ciMa2JfE zuK@U;?%qhDZTun=>R9t4G!M3QV~a7|pI(hckZU=sdwFu)^Y%Jjsc!2Di5O;eP4?#I zP5k(mi^!!4vRBy)pH_fxG#HwM;>@y295{c5Q zUV<4KtbGT+k(TD89QjKa+qq>O zhxbpJKR&aSONiSxbNfb3tmNxbwr1;Dyw!$zY;L{BfGJAwyalXAS&Dk+lhZF1rBw}M?Q`tJX6lI!7BO24k7mVO+^4&&L2EDWfCE~`b zNq+&>vgTB4M%Kk2p*jz>K1o2mlC)d{YTt{QnAMJf{3^HgR?Oo!OZFSAYWVk8O3rB# zIVwJ>t@W`W(l!IZ+}FXQ-fQbUl$)?!T>!AHApZX7lVJNse)zu2&_j{h%sA0Nl0%c) zZUKeP!-9C(JA7H|#*}Y6Zl{Q~7cIHRcg5_lRWGLB$>w><7YvF}lQQ@DpmrZCvyz_B zyj=cIlg;%R&tV-r+(xkP8$~Ik{SI@21RKBK^ZlQ+fNWY+w9uMt6DVe)BD=>_?_Wf0 zxcHiBEfF74j*tg{zIx5L3v|0$23n$83|9JAF@FJrh(q=pw}jdHUrdS7et{9;{v;1B z@eg*98#pcD)mlBX?=J!NStrhN;35l~p+rH>{d<1_-%Ytk-u24IM$EY;MEFOE=Dm9| zUFVlFGc8$k2_h|xJGD%w&CsjOyFiODgiCk3e*ew8UNf=K6LD&m{AI`UOO>yr`dlk`11)wbqL}koJ4dG7 z%Z*Wx`?#C<=3hFAKzrxq1}Sms!KJKbgQ~*@EFNu{9VQHq=roU)PG#6no7IZ80mDN- zJC^(GJVa*Df$0ojgq65w0)ushPQN*-w9e4JQNH0)mp?vmyF>jPUw!Z1D@gfiJ+gvO zOoY3YI#Sd&>hs_dW)on=G1oaLK~t=0x@2FqPIi?C8KeikHQ5r9H2e8wm7AM z{uEetXijRM~Ca%f#+TCynG= zUO3uu)*JMA;XZEgZ|9!6NQ5MB>dCUGAcRulQ$op!>nlCF3m8VBq$dk0iqMVO9kh06 z!MZ1`$CK#fjG(2)E1XO((bGA}{mx6*Xnk_T?;^c2SWB0z*zx{5jW-l-Vb((pB-$?Ca*nfJ5?MJLAbAFa9ar;ZQ<&A>bMf2VPx`Hx?Jo{pV z&`gAwQH2J?DFt-tr9&E1zK%o~pK}HTkM|3^=)Z2$QyS6VH0kTSDp&O-;mWgkHK3#| z8AI5v|E1WINz&(##<)(osgTY-_a3_90P*SDHZ81A+3uLz$6t#0SR@A;8K&IbBxz6{ zxyS_GNFkm)mCo3dV^>eRjopMeT^wrpu=zj9gztP2WS-H;M>h_zuN;;>?KivgZpCG) zxu%iGwZ3b_=YvO9l~L;5Vep$5S|2{7NY_UW+NF?bOxG{}$|$ILwOv)H;`92?Qn5QC zByh0FGg0iT`d5>-dG8Tg_}WH8BJIx?Mzz#o91}bMT`##cE)qMJXcMUi)Rbe0(&3hG zIO=?|OQ5A8Z)D0mxAJ&p&&%Mbu!g4E_`G`DdVrv?sSZD>dDsz`7R7dme8ZPYUFW}{wRHqB-&LwBZXQr+&lXPQd#p`f8GrjEi@+{oLoRBkr z>;^MV#UTYG*h}b^UVJ8G4J)^TC4K`7Q|g>DL%gl6w?~^FW`?ao!i9kUnjkE`TPtbn z*SQcn#E*0#q}sBtzKHGRLtT$lJ}cSC`(V+>=K1QLm0G74aT6!QYLec(*=2c~kL6yo z-k9VFn+CiWMQNUUGt>SIk9CewCCp2{jQ4YSx|z~SaRuF;SWThm#xH|K5DR#29h8NI z-fIs2ms;gsuid{?InQ@e97-9_vf^OoWp&vm-lmGG2e85OA6_$cpjlDoZB zWE5xJs+=duvc+94F}{9Q(T1-A_kZvQ4_x$ldiKr|(6z$T&a-B#JLL#|a24-cQF{~h z*dN@YFqW!C;1xSd;dNP0aTbz?*(0lOlMITbWkdwSs9DcLBQYN#6k(fvYF?3 z0$hNVg4~;xADNOEATE5#1B8CP+F0iZr z)F(;3t+J({&-G~!|D{18Bl`bzr_!=vaXby5#HU~3alU(cQzHCFrLwgmXCCvx4$5rg z-(c14C-vh_&NgbX8VjPlz0JXEK9}Fpwk#G#;=^7`cQL|zJwEI%Xr8~bpYRiUz_9K7 z>+|ixefYD0n;&QLiBBPyS>5=(snxj=m5#_H1jh#d;lG+~;pmo|VnmhpF1V#2N9#l0 zK;8X)u8}9aJ~2P1h9*9j`m%eSql%DbnXf~;ilV=(>*{(ua~$Bl_hkuo4Yf=a9xrK! z_Q)iYOOb!)w4bjbeu2^SNeWi;k#4YacjLvG?`g^gIxs7Z3K)F01ISPxT0C{LahuSq z)cEyI`8O)`qy`}ns0v(?qpRXW>n>>!+z=jhmUXw~lbTA^dXozhm7 z35(LhPo>wm$cwDRcNn)nWeju`SG`Q;t(s?PD=h&ct$SS)K{dT`TmIBHe$<5;Zr>z$ z^Umh@kC-jc{BCiGnV!D@-~831^0iwbQ4|PbJh!U;>lWJ9&rD|MJ^JfyK94i?v2Ypn zW}FEI)fcP&^UILZ>Bif@u&;Mn`oS2lhTu?_)6Y0UUqTE;8ff3H@2uQV9a#Z)9~!Mk z`1d?)cGnn?h*g+EZa{P--SuGt3mWUQ9|prIE~?qlTt@Re-Ont3KVF>2Sn@WV=cQWQ zvy;UWYk2txq>L}xd|%_a2$yN%j(f1bAwB?(sB;3GToOHwKciS_8wrbM>f~AktX@o6 z-vw1FFsZ0o&-V-N1hw(K>nuT^DY5Q-1AkT|RG~1K{Y~auDiY)AZI$03)ansoY$XEC zxoV8EB%@#$vy<&Ri{R%)xYTahNJr`KxQMpI%F^V{u_UeG+*w_T=Vt;Ab)Zk=_XGvHwucTGVfCdRe#zt`Suj`r?OPGyfCLyPg(xxnaZ)= zvDy4g?+bq4#@cF<;L`QP6Id;k3-I+Em-tuhE?C~8QzcWJq8^vJ0 z$4dfo2~k5Ih^3?Qa$Uv(pWJOH{SB{7B(ZGnaJz+zT*^wm9i_e!o!_nD#nr96#@Isg zu(airU{K_48ieD>>5U4fBDvR&4KnVlRQYqg^U6icc{S} z%yblwV2{M)1X0y(Sw>vM!Y`M`>=hcWfwL!#-=!wh{o{<%pMu(ZMuo+?2PRl0( z9VZOpB!I6ht6EG)N&ZZ=cPj?Ic|6PMvRh|mev!f04T5+!?qckw>nt`9eAg#ywL5w~ zRzft|olV_*swAIZTwCRyPNIXmKUWNrVjcb**0w8Z?bJq&&q0K^4n)P|Z;abqlsTcC%4=*NV@hC`TV9$FEYHJp@IPa1>8o@rA3W;HB7;MV3+5 z&8#LyZx{$gpx0;gmYJ%z0vR(9wgM|CBvOAHF+9D4Mf1N;*pbFQLRO0Yi#EG@dU@Bu z={{|WdIIybD&cfFAYCcE2NX_iM-JikFx;DNsi?@l@W>E@mLdzjt;+?xGZkQ^*Wlj# z3wURi)f<;_cIO$2enf)?s}NV4F4BX`^BJmU)*;aJH$uIE;JkISCIRr>`zF&mN1esb zp2?V;rvHfBAVZKZgu%HA%jpwPf_Kr7eGO%^o!pYLMC1lX;A;Hf5JFLOmGknP@W#=1 zE_N|UfWtlf_H>RwlxTG#>)d(HC}6Wu2r^>VY~vm;luSEMxHPGXwGA3fPWa7`BJpBd z_e1P`tzOQqSLp+_^5j3pbKqHlZ_VRoh#()hD6U)tOGwYuh5|>qj#(u3; z3T{E}k?h=1vXF^BlI4|TZ)XnGu(UT9A10#s4*-@tihKcZOjg(AFA-FUU2bwwJq5QLA}y2f zYmvRdc7o)yc|@J3d#W>*@|uyi&d^a== zM;Dg=EjQ4k%V*29C~48MKT;C%YxUdAIa#Zt>?=3-alxu$#yd~u2LcyvI)g>4(Y zT6^1IJSf=6@R3Yi$otaS^(@`Gc{yi21w%}zn#$o%TC8b+^^az$FWhlO&96g;x-*Ys z9_#)q4wcDRE%p@`)Bb%1}g|x{GHY5giTYosGD(P;O}C&i*!^an1NK<0K1au0#Kzm>{u8IxkjSwN5F+ zJWpT>CQ3lNo~&`9kBWrqxHw6{PjcFT??s?9H4QNib~HDK!7j+ngftsG;MFm?YG2c zu{;&Ucfq-QPO#1O-DZ=Ez42YUe+@zmo~d>`N&7YXUj`}?C*YAQ48!z;U3%g4A%xRP z{#!1IcCuSt;1G*9r=MbHmJ2XpbaE$SnOp%>fAR0Q+eIn z>nQPrcVP0`vic{+q^E&#z~h_rwDk1vTBb7-`q0aXpTT(IjhPevgPu_1Z};B?%4{OI zU2FV5)`BVt=PPGVt>;LC+St7a)Z)+8|5 z{@|b7@XeY-rPCMkp}}@1m+Aetw;?%n_7Cme+^1~w@T-2NKe=B|xgK>eZ2jWeD7yW? zIyp*okUh!k&b=Db4befR@iFZUoU&If)T^= zH>J={Z)sj#qTG5heu%W}XR;vzqZ-YjLyF71&6`vFR48W69vOkk?UD>+K#O9cD#38C z;5p7RN3TLsrsuWXx684NGos8wH43^i)@m8+@pvXp=H@lLwBX1`<6IaUAwPCa9fvcc zUQgIOsjNOApc;FS2#8yKgfVxvhmjF$lihQ(Je|xF0ptFm3%HGmZOccow%OYppA-%HZUVnGz*}s6vaFXLP%AIs{Y!)x zxM=v{eX!En%?&x6PCM(ek%Y5X@^V!0ga-e_Vp@cfLVYH!upfdx+#i{qKTBcQ_@~^~(FJb`wk=OKmsCnF zZhq7dX79QsEDjzR%$(=C_eAx;#In{Sr{tngsupa_8+}fPu*OHJxXFNJ!mVH$m}t}>J0@fsn59Y-TDjo6kcropH}=D z_OI_U{v+6I`fiMx;nrKGBTC87c;xL!9aViD+WI%Uqpc)|x_tQs550P|?0oXpxAlYp ztI-FGg^tYkG0$p&%vShc^FF)!{)(OB6%veaIc|%TFw(W2fm{n=T8r^7Y$M4xg-g+099JFT`C)@hDK0f23sY2)| zR>R|6u#N7KyRUxQ)eAW6Can$S{niup+$Rz&Z~+ znzyu{fy@LEfJ*!z8Q$NvI-Ug-y@=XBJ1GUh0eet|Uvk%i5Yij#?6gz(wh}SneoJzk zoSna(;Mbh|tI9jq1*7YlUCVsj{2#D+NiHGG7X~ntdt}SC08x9Je9PXWulEPa`^-6M zZE-N?(WbJqEp#w3E!}hx;3wxjHf%FZz`rsJUIUSuQcihMC<&R6n)Xu=A&M7<94s zwEPk>9k-pvY*Cu3vC+N;uUnunU*YGBnWqm=@5#+rM^fMvs1714&6YP9(CW zvq{Al`|BUdD$YyI_=Mw3Og z2okke$!3{sT2P?2q@uEt`pY8@tlb~Jc$4xq`PR#)ZB30>DX!?O1k3)YJKie3qgu~+jE3FO@3(!- zb)*z(3TECW_Fki))^38T7m3Wy}8LSrm2U1!oCuk6UIws>aol50bC* zU^B}!Azlb)aqzb+-A|X}HSGlY2Zy3e_(~RTC!&-iYITqY8#N_2R@P)sLq|CFCs0uE z^{W8k&xGqAhAJ%)7v4X8cxH`{+oWm%UKDr0Fyk#mdo2)<@$BrYo2Ol|%aP`>qb2T=dQel<^)Q{#`>?#-{OXGxzYHtIe&mm)LQ z>Of0bKg4&TFqI`!mKQUkwlZk;+- zidQWml5IF6aVM@uDXJH%6OV4SBVmfO0>i&F(!P|_6^0xE$ju^P9&^a&oKyU=PDkfX z1hND>a1MAJ)3~fcc{u}$909j!ImbDv2pxKQ8cn}1x7WQFCB$m)b^$pp*l|cnayUE= z!j(qDmKhW}kOLLKZiE_SjQWmgFhI`Sk6%h~QrrQY`%_!-rY43FmL0R)^rq7H3+})MAq^%&gyd{b@T>n0)8!K;o!L z365!TOV_Of+L37h9qM#V>Ivr+5L4)C#9-iYiitC5M1tXQiiWM-AQ2;S4r--TUD1tI z?+Z&w`O=D`G)Ws^*G=J{5txqn2?j`y!kxM1Ob!=OfahxOZj>o?DFk;m<+zq%hv>?8T!o9Be91 zPu8Ge=FRiOz(jJbyQ%sQ>q{u|<52CJ;i!Wu9tr!i6Vrc z@8)n1;Y_{ot*hG4Z#1DD(VhiNZH31?9-tper54qM+PTSipT+WciU5&mDR1Q+>2WLm z@o~=>`g_(?I?kglvWux8g5GTHmDlfM^CLYyDwp4Q^8r^#(3 zfgn{)yNXJ{l^&~)LsI!)sMdmCfhC-CL%(dJ8;WBM+<*1!Hp^3z(p|FT9P^%s>;5&a ze|a?fbqH7G94dfZV>ms#bTyrRx^x~|#~_+MImzBXr{zQ!K$GfpmQ%%cq2X>v-d^Ij ztyFAA40D_n$8Oc-@y&6kOq0O)O#H6BKhL#xx*v$(yeJcj$GV{A0Ye`OR`gN)k+*`rC$s#5{yx6U!q)?XTUBpD30aYZoG9cax3lIk&&`qbJ@*#*%gBuRK;kP#B{WM&brKBu43 zrGjf~JL!ogXu^V<6nv-Z!=J5YThDhSvb3->c`VH$vurJn!#wAw6+&p*>N57sODO&9 zLm=nZp0s;CY{hf9(|k>0q{}=jZy@0Z=rQsN-UnL;tO*B{Tfesf%Ax!~42t~Ag{&P*N0`?>yK&Z1PDeiKMl=_7~0+ky{Y zr6-mHb?4fxGzK;+w1N*Ih7M>E4Wo=2%b4Eiu2dO5a!yW8J?Vux>%ikRbjEjX10tC( z&m*w`N$2GpP^1?tGLi-{jN{&iP~CXPrA%WWADeI-=bARQM@8?0-krdz6c7L(kEJxA zUNOn*o-tNga(+>YZZa_x>WHu&&ce0(h#`he8BakLzz1sDLp}}A)a5%bJsM!Mo7uPH5n%-lh=xH zcI}h(qf*x^=sZNbhzBC1R0?<$py%cTif|*ZN`~38idzj|-bu7|sl+4@!{#HdDg=+t zke@IoY}Kfcsj@!d_!BZ=jP6FS$OBAX-VEEJyodDOGkPu zQ#2^zly%J|DCZQ0hpF56*Hz(<5xtD5Z!?h|en&sReLj`WM{6XO($2efL{v9C^PF+` zR6{F@iALz9q3`w=>w6JA2OWX^YR-Qe@^1`yk?q+nt|TCIjzinn`&Xt~UoF%i@wtBT zgZkDE>DiWBW*9l9c=N@NbxGl!{!OeKH2Y1bn|BY>?^i2lyY;=)3rwIC6i`lQyC0M$PMkD z^nhvs^GwSkvkq0;p!#$b8aR_Otc9at!j;G4>rzZzw)t)spPP*2QZZh0&S(M*mvTu% z9zI^@G}#x-eX>WC7$E1r(w+jK!hoaD35v`a26ZJz2*%>6%FEp6GPDb9Zixdax{TsQ7xcRjYLHF-1% z$L}s4D|PN!s;Bn;v8WK1cI$5$w*VuCZ01`=lEVj~U zc3&*F4|OL^snVm9#F8RoOVg16=)`V6rB#$^`aHXS$@ZC44aLqvpHEEtRfzS(xwd&D zw*zK#<>Z0*jM9^F-Pmi`t)qWa4&%gHtg_}ysR0M>jtAvhdUfoVcIzaVW&y$Nxa0o- zuUPu!%rnUpv5Y$c91(+&>r&}=VjDLk0s^_m;YyUf{m!gRVJte5jf!8{*YBfAb#WE# zoyxcFzjihNc)=ZU@7l0u(;>RHS-#sLkq`qBU@~%k?mKXKHNM_6oo!Oy&gd*mncX6m zXuECC_|`q(FBBS`qBL^G&A#FcVn+2Kbg5T7rgKea`{58Txtkk^;EvpWb-5RZY~-_9 z8&QvIox#6{r}ujG%~I60ne`%o!iZCx#xP0lPAfk$J_9&VIKbdm-t+1TI+LP(o^umA zynQ}nl|N5PzxEqpv_}ga-m(S9s5$HSR#>+id*`w2YeLR*8lZO#&KCzIKl;@YeN!uv z#+ydAw)u`rl|VNbKtV~-Lj`a4g<@OX zUfA3;g9@#Z$ax3Xis`hw$n^_+G=qGDEfb8Ay*hUl$l)q4n)gP^QK_cPlIrJ2)NGUO z(5^QEH-^bd8s6%(B#C9l9ts5rZ zynipww&m(aF`aFqT#ZECPYhxeKpV^;5J=&OBi6eMZwxifzFSa_C32!A`3I(Z)j{KH zJz%W&O182jMlGdxY$Wv=>MNtsZFL`(SCSEKz-2ZP8_=&zeL1R(BKKD%wz`=*Pl+RI zca4f--{sssUYv7XCYSbWyK#FOL|uu@ss|(-XEn^c!)(*_~2r4dOec#=__2lo6f}twVQoVc+(N zP$>r^rU%e-TyCj#4fdqhV%+(e1xp-b9Xfs$AKT|i8QF2X{LLRzp1G=&X4ut{w>6HN z;<+dLGwqrs$hZh{eVhB=UMbpF!+~=OPjRTBjrkvE8?rv9{3hT2%&nPSYs+zRWv)Yp;{yEsEMhGTKl3#oTvb1^j!{@AYf#XG><$=ZLwF z_m<^G;t1#o?@pqHwg|ag@?x8E2*9Y>Gk`hAYPBp+3zU^gGMqBE1bsyyftgE=Lh<#k zRdajTq*tyu&oqQ&0o>J=jDhd!aE9Hii}`n1CF$r7|wpa{{V$K zt>g+YGJ0{^nyI%t#u#KRpl0E5PH)A6ZcP#=ys=9`s~ z9G5A76Lji%rz&&Sk%kzI_opBj_p4)yB?oE~{3nz3r;HKrO~=XWPef(OjgCDHWX*?& z)gs(*e!Z#5DT@Ug<>}I+Qp^Z%m=jAQnDVi%034rMn_oa9mQBToIrgg3CJuX3i}g7i z(@S6+n%XMHbF)NjFljqek3mi8R&&@;DOar^6far^YH90c`_}W$3QB-uJqCHt^r)|6 zfgUkz%*aq~FVr?UA57J~3Q3k}L=wdr!m;x@HW*{_JpD6T!F3F%SZw9!0LcFUriwrI zZ~S(PT@Lm+Wnu+(ei!i}43^g|i5H0E_4YN(&!=5mK(fsqBYXvI!yKq#`c*|GM)AM| zbMINoH!A13+ug0qMD#t!r38WWHN$vg#4Rf&ywCgKK2m>-e~orYI?S7t;Etg7tTuLK z4v>ddRsolx2hyOC6{9iqTw@Ez9@wWdfOr)VbBrI(fDv}01XG1kfzC}vSadWoJ?cMi z$j|`IoPkjiY0gJcOv(QM3Ir!4;+Nj1gHF4;$CU$+d!7g9SAVf%wj1>u*kB#Ta%z%n zH_;g-vDTI-q@A|Hk0JC?n$T@aL9+hLT43=OsdhGLmT3xqu(`nc^rxY` zaP?ZdR$h7%!{O`cS9IGTPggZK)AXA$o13PcfX>+Zew9UZty@r?MdizGWA}G%Kak?I z8sAT|V2^ULkZ@R^mm{xAZ8fT2csg|Byszk1e-XoM#yu}h0lIE+&*UkL-XYZo&gKZu zzQO)AuMgQu`Ii1sAKr+JQ;o|svBazQh!s&+-H+QwAH#>=sn0iu!Zz!f-c~=|82wFO zvA5BLzFckusxtUp*!*heh?ZG2`;W24W@wpEM5KW2-zU&!yzc7fQ<(jUC0jF`JZif@ z{Cb*m<$}=>?W)z$v(ToUV}Yi%ktTsM2~*0E>rK($nZrG}N5RX#P z+e^8XQguvuu^tbm;nOw3Yj$_qE~gw57DkNjMhAu+h&7yQyIqjstBKHS+D@-)5~RzO zbG(E(RVS`J39DKi<)pT&V>WGHq;tY{vLEU_sXQa%KQcD3)ZfgGMn60C3~Emi_P7QUwA)Pp48n`&8%?(#xcP;z{kBgC2a(sb9UQV)U_s&W0DJKBT~jymC76(yz^8ucpBr-Q;%LV=CL2g_Gv`d!F5?mO66HX)0P= z8*7L%QSJse6OR2yLyj>@oFgBFTH>6Wdb4-KnzhB>?poOSi2ndMk?`2)NC&PfuzTwS zh^)++!5&MlTaRx_;B9oq)oe}7@BaW3VJFEx_6pz*N56BCS>7hT)Z$w|wp%T<@Utq- zA0B1^>Fr%Hm9$1}cQxC zA#?KMJ&ku$Dss|cSJd>Z9a{HJTXu?f6U5wYRo&0A>}hjfaB=KQYkvl#Z|1^A2MwO8 zed+#LEwBJR`x@Yd$+fyNSji%wKQ8X1d*ZHKc!v6Mv1Ab^q+FKDW24`s_`=)wj4kyIyh;aC=-#5Z{aZ-8 z(XM=(xX2uoamu*$2CrUdS2{5lmJ)fek_dIKk3`ns)#5sCw1~(?Npbf*^V{oFI&BUz zJoJ)&qN619z{hIa@fMo~m8r>XZ6})u!z1JzsrptvFnR4<+dDI5+=-Cm{A#R=zD>QC zo=shRk8IUhRBv9*-#sfxF^y5Y0hT%71;t#6KXx)O-iE72b`&QadgrZKCy+DA?Mgyo zc|ivq{{TvcMF%_Z0UT8FACqew5<693nK)L;VQ#N| z?-)hg8$U`TyCgJo7H!8nsYFc5RWQS^y<*$GrJ;;Mpx`qR*V3F2$sf$X5!#qQ+7Ci_ z#VQpHHv^uTrZP6PW*Jfls`5rrinj!It#UKafms)1`JM67s+^pijOS#oM$#Ms*mj^0 z)fFft9E#q@FFv}G(s!j(xKL_KFX^6HmQOa>ryf~2U*P0?-_P@{SN_ctD0pt+Q2gUL z19{KskHl6+n%ieNx%)m*hWvHo?*2V1p!2Ux*^gDXkcP-EKigBE%;)emOJTD-rkylO zhWc_7WAA464|OKUl$ja{dKln}rGPFK+S6Z%%luAs{pHnww&s2C%kzN7m7 zLaVa7LQL8^wpZ`R+c919yHNeRf zkVwla6m`Zy7{y6%GeI)T6BKkg1a_>Xu4s>25+s8?JwfUzj`-<{gGjhdYexRkk!17Z zVHD{A2XV&?bJDaY8a|Q(T~7B5dMfv*9nXa9zh)vu9+~%uHHt>Wo^#>#K6{4pe zuHtyPC2DCzsRo;8ZUGR7Z&&8EV3nAxF|Jv-3OKB>xu0iNKc!7)a4l~dSsN)DmaSA$ z*yo((J!I}#)Y?Rl*v8C?7j?|**Zt944zsIYNq(tezBp6lju6BF^&QQ3`ZtL5{YK&# zNb=>KOoYEXo3PL8S^h5YMg6O?omETw4|G$TFEh2^5d9-tJK zLW65pF*dz*q})7`#@=LE8(4A;Cx^8s(QdrmN#va*8(Fdbte)PZ`qTVX8)_F~c-&2H zz$(b6Bzqrm?_7%O)ZS6EeVKPj@zinOTElpuE#_0^F*(B?{{T+4tKv->-&BR>v)a-h zxr4(V?eBrp-!nog1{9PalXhuXBYTVt&!+YEB7FTmU}w4S?9erY6lwfl0) z1b65@WzIa${=G+}X!qAq-AZo^5?U!^0ng3Gc?W^T9Et2)rESqt-@`X?ktMv!-|z59 z{6C#`8XmN>2Gg&KNUN16a657DTo$jYOR7U05=d-TIL_xsZIXYyy^qqd^ueiES)EcC ziL(v0`RCI(>)#oxhr0AJlfI1fOI*o%n^yJ~74! z{C>5~>6*>0-HA6g@<|{hB(cf2@FO3}wq&|{jSl8XI06EyqoR&@tsLVk_aCvGVx-oG z7i~P2vn;VT)*bri>sK!9t+ludLW>p9$uSNCd$0Ia0nl-Za*~8HueEGwkima8AitI!MN2sjxW_$!}x z0y2ZM0N_8;wP`Y=JD4qLCEF>rwUBy~(xzP%A_U%DM-zW_PUH2hEpGWNVukJ`H$OH= zjfjoY(~gJnHOpJy+l%LUg9MNjP!HW12b0(T0M$`u_9?SkDD2U(Z*48pj_tz!l()?T zx%*9tX*P@`Y&c&)4`0HoPc+t{W{%;ELx9~zJqYY-J6QEyVr3EGqEDDgfGUr~^gh(% z6cSC5-C95_A(q9`N08;3vy~F^6L+S6tvN(# zmNkzKtSZ+!dx;_gF9~73Kf}1Ldc7jn*Gkm%=&j^2+Fix>F4S@x(oi~kFyPlQtN2F$ z07<&?=V)16Zbyx`D-Y>TGP3uX5{|y*sCa#KFYRk+G_BBFG=Oenl=b{aUMo{n)q&NnH0zx{2(E;_ThA1w zS0k^=c)_eHMYW-D-jV@Za^h)2JX4^tL1(9#Z;L?5WEr(;wqr^6ILszcPa?^RP@F_8nwS`4CmX5 zRb7hB{8;p+pPiHSAoi+m|@ z?nQ-Aa-{Nc(wA{p3^SS+7y*YQ)0CLmgL-3;(xsFJUBl+idYUpBhX(_yibDgOZL{{XYgjt>;kL9$>*ZbvgXbe>#-Md|d-sTHO87 zfsFNa1Nr_!orGX&dz$Q)xEC2jK4(n)qmRR<;Z>6-pGvc-f+s@O!q}LQ>>c>wzaF&& zYH&w!Q1>)j9lwGlBG&aXaCRT(O~1K&yS8(}soJ>o6yF6L{j7C6RQ~`viOwf=&qg(s zckZNmS$bEK>UJ6=Flq21IP+X(oBCHnZ*dIYE=EYMcGk*y;#Nf^a1BXuD`}R#dVJ2O zEC*p*Mw&?Ts?E-Az0K>(i0zxpNXyHN;Net$CbFlyxRW4Cs!8E3*K>Yn{37U3AIagnm|=Iu-TtV^1IIv>UxZ7_ZM%rS17wqa0gtDy~SrwGLJq&%;$HP9EyHc z1F6GuGBJutJC8%sB%EANCA4nqG(h=^IqAl7I*Nuk=3Dt8pLz#E3b?_>DxROG1=6iv zJgmkcyOJ^wI5np>r6WZU)NUeYh;32_&$rz7u7=gGAcQ2{qONli+qRu|3P{9fCvZOe zS6!m`vuukE%e3+1YqO45p1$I-?saQdP`_tcuy`&wtar=Z385ZQ>9IO~Rmkeb58Zb= zqlBq7?<*ajh;)^=U$@yR$!^0W0gye9xALs(Ce)|1G7Cj*H3sQ7C|B*1{?QogP1C$X zbEVs~H&B@^uq=U%jq*5=<#NsPCL=V>_DF^mE9t+bY>JmWY%R%BgjahBU- zCg2CoBup}&o$KXn_nkz2v% z$7eU4Zj!K$PwxupBX9Vp=U@6{f30(NcEZvHiAgx`?^~)*_9e(C8H@VX5O>BC5Q6X)jQ!Uic|ZEz z)Xl!1iOn>DgOQJV6R@WRC1zCAZEiHj4J54aI^sFicVu(MbDs5H%T&12r;KR}wpp=| z*&y-I^N(8Cis-``ibNAzzYi1i{5>ldRno<}8>=GH+McR@^k?7G>s@rFrK3FRl%-AI zp{*vabtwS3-2PrO3-m_rKmY;HN~5UTHOztJwM01R4nIEihLX>-cv%dXBuUB2_s_L% z+Fjquuc{-*cGzW_-*4SgI)FbOohx@60(a1Doa=64-yD&`>ITw&WI5_H)B*=u^*t&< zq}wDDhMLMC8-CH$p5SrcHRTr)!+kBfT0kIzDF*MKa}wCe&!-jNSSp9G^2VZKVb>pka(5la;s7Ic{&sJUX-nTdmgD z2)q2a7dzWL06pt3#MTdfES}Bn=faiq5q3Bq^wU4ZnpAaB`xKYq4gfdqn_td zv+#^px0cqk*-0=|fbc(8cZ zM_)@MLZz+Q7RJZ}@bxs9&r{7xanAs^)|<4P=k%^?n^=!-DZ5DNQkCQ0kf^}MezaT& z70dP4Zs2wQ= z)?&el$mnUU01#ugJw-n!9R3-mjsYhmV}Xis$t3smsbwM)h6nEOdy0)$_r#D+MNG;M zZhdK~_m1yQqOCC*A25}((4Lhc2)F@GbMtyr)FXxx;c~|$b)jGkes{u=fsUu}u9nFg z@@3Qv6Zd=mbt0^d8vt{TaZvdTBmkpedvl5mZcsNk?adl@7;tftNc8DW18Md&ENTWw z$vgl(XdhgG*op=@RiA{@P?&R25msdx zs_oXgVsh15jiQPwj&exfkPUPiex-MGW3)?nCMug$I)T7e9e#)O70uO~X^OT3VY?7% zJvBzLchQ|R(4DN;S~d;|-5KC;r?B?N{}Lon(X0iYU&)tK|{%0Ozm1f2C&*xfPq-wXxZFG4UZRlljq14p@!0y-%B*=)xyd{& zM>dpMUiVIwCcBSnvw*<7L**wOv0P|NiBP%%w=k;25;ZEtdS`*pq0d~`SuVFR8(~F= zcJ6A#kXw0d*EeP4AZMPL8R$CxwV$+$_)dj`m6txBiOH^&C!d(qBzrcd^M_JLC*|sT z{uN^1NVm6SHyfvD&kDn8_0J=zuBO4!(Nf+ZPBs!(Zco%?)K^++?Rn;tbdqi(VFY`7 zoYcw9tHqnbg&4a@8Pi|f&-dgY9x%KQ%B$x!r){HL%0fIsGbh|>TW8~r^+Q`J;roSx z?iuBghCxxaKLUEz9?qn-XH2Wnq^*CrjQ+K93$X!4hB4*{${stD*Wa~Ti0L=>kzCov z@xWZBX6i^@`0bjL?RK`rHKGw905%2(xdijiN`B43>c<+YtW%02c<*k?wZwlTkUn+5 z;C_7vYIWRJb`x#0GZ|1|i3nsU--T2HZ2MT=4WX!&<+J@(tudt44*+zr6sX)r3pL9 z5yNi`0}({4j`-%K%}$mxGVWjzeOroIVUE@?@~pCgLV$>QCayH6E{0RY(WRyS;<_tH z;Z$UryENM@XGJ*y0Hl@Uw^AMBw;j}+vHUA8^HzXB*7oXKc?G0A9C`s=3JRQE-lv&g z66>_0v_yNxa8ErccjR(!@e*u9n`?Ba^mCeslN==H%6G zm=s9_5&r;o5wL!hMVoT~+>_MRU3Mu`msWN9hluPRGc%+YGRnJ_G>pb=+o#?icn~@o z=gzIVb(ie>WQ?7K9E=0hAM@*3-!?k+^`~_MvF}N{?r5NqqZRX@*%G8H{n(cuuV2=s z54h!yPpRg!Bm2Xiohs6A``d{a=CGVcYiwvE3{%5^IO|nnVBK;)l`6M9VER@K7Nl81 zq~{*yg1{5bYPgVX=YlB=r=o&5spVtlMS|;|qMs$mx^>DxHjIAmFq@C5$5T}N#x0Hp zdkSh2pb^(R)gUj)o z#fEY3)YDrBuMO*ppJuy{o%SK#qpoQggA=smVxGz|oq>qsp4A3Q1C0BcQi5ACsSKG^ z_4~u74@!Zf%HU)Z+qF$0%X<%6Zvc^;E+|(*dy(L%$m(fWZ98*}`ufwc+|-*vA9n

      mLMo|mF2orurUpuP~#N4L1L@_0P3PJ zJj1!RoPBBBmS!rKxISv`OrE?EPM$GszjF=kz$?fVU8Fzyt-z#z9y)jBGs*JeIh=%eo%ib*nYuz}mx6-&rqTjcGvdJgm} z41>)vh*ieW*&TXfoDRepAp3e%SY)NLKKEYdy+(167mRf@EQ$|IjB`x{ci_@U2&5fq z1{FJz(xPk{)+RL(7AYyllC(LR5|m_g;L(aY8U$I2KzjA9_^&N5caQADxm2<8Nf_zR z=zluq0U+n4UbMWH0$vv=%8I$*x#m$%KvKM&TZCnt}_v@fT) zys@^P=H(^a@A8klr#$ED)~GKG2^>_*a^tbm_)YfTNI&V8fAQf{>H`<^{{X&fpN5z% z^W=ZaCjN)|Rqa>)LNoUHvshw&1bP?`j$VaK(}gylB)?|TuI`Z)rHf|W;~-??rE)?p zQnEcdl@&NSzJ!rm%{y(1CXo6l%~^`rJWUe>Nkekk%K_iZj|N6T$tSz03H)nMNkIY|M-55~3U0vM5EKsPoH(N-5bexLe|X!NHhIQ6aZ!za-q{oEmTTq(0hzr( z{PEVZ^76K@i2WI>D)U*tzi;%Lsa$s*2jnWbU{@u%&rY=TkHU;) zI+OU_&X!LXAccI3H1qL>k=s1`Rz2pus9muVTohCMDZs4eVYGUlcsx@%^A&NAT-9?) znW#k*n&7dVy z$B(a2crS0SKPt$?kA{^!%x%pf)(&%FoBkpXpHsA-8P@*@i_(A#8OYOw^7e01=$}WAvwSSb;$~8SB{7 zNCPDEnv}2@z#mF#<&QYda0LJ~eeRjZwM(=pp#baIeL z*iX`G2=Y;sF}mA<_upvlgJ{ZBV-Jt2Pbz2kx@FxzbQQ9fH|(zK=MN; z-VKH52P;gG$x!98#Bx0;W6V+j;DsZTj?~vx8;X@9JPK=Y5R51}$vvqUjs_`(vba2R z+LO~AYV0eI&rETXNaU944;@7yRdNT7`S)T#pYtoWocwnbe>%H=>g?OC;Bc)O!> zLHTtD82l%=5_^DuO3Khq>*P4VF~~9h00A|vtAEGZpHy1M5&Sc|1N>L$ zP^V24ml{><5TSQr!kbPES2!eR(zxL+StfdwVeKH{+|}@0_Z}W;My(>7XG|;} zX68ejHcR!bK^2WT{6tcjs%kQtb2`9SJaNluU%EY<(xc! zD#5z(cA0JRz>?jt>HG;;_g*v9=TertEhF@adHm{HZ+23t82MLJ!KbbUsAR_(;DA+q7%!I#LBYj{Jk4 z&Zb!u9!E@422J@Jvb>LKVjyG*oyY0yYBJpAR~YM$TC*dpqc5IG?cSTejA3v%6w?zC zCzVbzdHz(JzG7Lko}l-oW5zHrJq0kR<7m&})7pWO$u{g2`FP+8NTv|-6dpeIDWP2m zIRhS@>Em`V2pHg;^`)Q=k;IO!syY$%q>fFIvV~VCKX_*p)>7P%27g*qhkJzuK*{Bf zF+dG>&M*k$){}Ny8OC|Z?L#KT!2Ibvyqrm}%9CMS!OB)v2 zqy;Lt;d$%zswC#FBoaGqP^1%_ccdHPW3}*c&UoUZ`9qLYk&{w6$jcvYy{pi*v@zdM zmPU{O4*&t2&{jW_Yvhs0J--@Lxl|H3?Vn0(eA`IL1KNZ!rH;+H;2%n9BcIZa{Pd+G z1mI)P8lefCfG9Z!=}DiZ1Cx&Q3gCM6q*eK|=}JZqBbuEQd3<%wXl}rxc0ffijMUBm z$Q*tZ86KzcrkOHCc+r>#XsDGgm6MuEnq7C8rZKDkp{ z+J&5x#|+Uf>>ve4UX{prdiia&J9V9c#9!|*z+TnaO{~~iM1p&$_W%aeJJ0D+IH^aK zoiu8?a_2^TdVR#7^3169ZYt~=Fk&~mKd3?dYa;i?FtW6Ewx&QvH%xFpA^tUyb>a4bF(gNRF=B_+rsm$t8)+AC6 z#T*~4WhIQ$F~BE1&w9NEkMn-;^s94(4rlEq?;=~j7HZd-RhV0$<7^AJ_3K&dZF6-Y zX5P$tvyw@zsBB?`Z~-9oBCM)_a0V+GVn3A>sV=5nwvm(j(~8iKO@c4s1dm?TF#Cky zoN+%Of!9gV-Lmydp@+9dba%?^>=&kpBQdQu%IA z0G{0`!r9LNW9wZBqz_UO0M8Vj!#s4WA7?ojRtKmZX$`!9?Q9H;(aedl0;w6n=j%$* zG8{Phh|e`LTDiss2VQF8TRG*qB=bsD5(^_R$C1G2rxhN}ht{>Ex7Y^KKs<5O(^|-| z%Whxpib|>zie_HZ*A(T+Yye3;gkt$n464@|+(-SjwvCSw$e@uUfYqzAzMat4RjZK^X6vu$JTzn&*{EjUuvJlffPO zRLc-jII96R^!6r{xXH&L9&yxGS8Tfx5J2h2UrIowhp8Tv_94i|MtJ-w>kw2K$0t11 zCEQJkmIDPq#RP_2u-ZMxT9azVgs~s}e@bC~4(1p>f}{x8;2d%O)j`8KJmmBSrIEvu zqL_+F@9Dv-OF=QLpq@&m{WO zk}Nl?d+~}_0xT;P8*$HCc#IyP6O7`e+E{w$pQ)!~<-j99%B8ZBATWYK8??@Hqw-7}SKwNk9^`n?p8S><+;PxKhT44lX zvA{h5slHNA%6bkxDL(E(91m04i;l#5PB0svrDxe zcjWWxO*0uB57MVL?(#aQ7#(tPQOJRE8OD7*Dut-RxeUd2@yDe|88{5WK05a`7y!s* zC#NSTtw|6DOraY{IHm_O%oMSaNO0T^*rm!y8wur;)0~6tM9BGK$2cSg^`^XrU7&(+ zxE{b)qq)vCP_f1i2exS*P5#1%BmfkU54|IBIBc4sTuwOVf^o<5q#T^KXwG_`ohg%X z#AE}X!xWt<0nbu%?M8Dz?ula?j~OI$Q>IIEpPPa2Rgw0NnCGag49dk@X(zb`vyr4; zglsT=Vbt^$8-d%3o!I1)-?l0y$2iV2)|z0^2^7*XQW4aQ(+^6~7)cGyA6i|fH6(WK z_}U5jQ*9y?WXQ3R%_s)6A=0Ff6O3ZDEwp%$D>H5+aw{2EgiWJCz0Q4Mci<@|tV5>F zDf^^-Yo(6bD8LGXo;VbRLY|#JTIYC|(Hkl;TbWSk*dM(-_S;uuwT1-&S0g;zv}4bH5nIIu7*YAG{pn9eC?fB1{d# zaQcx-7bh#6novd$8Kui%RPq;$@1LDsEoQpA-No&7%(`uoQ>lcD7< zWSQG>hU(-lHa0gC=Kf~FVW%@UB?_D6Zla;m(Hb+8G($E`|-N2*L6K#VyeD7hS)y@_U83O7fkjCS_(1dp=0*@N*p$a4*3}Y zUFOX%JQV=YX^oGy=pXM(zELk)1SQGrVfh*6ht@pO3;F-{=zDMNPHi@%EIZ*3EkB-M zyqZX_%hW-33v1@jo*K8sw{awex7S-zPLP1zTehXQ6qvsgB|sN>$uFE3i*LQE)O!t& z_4EHaW<+PCkf#DCOae;|9C^;|{Il8!F}D`x6_^2nH=CoIR&~^u-c`i6*cQIh*PVmu zx5f1SX>)fAqUH}=8DUhHSTTpZ{s+LA0eN?#S!ckq zJx1?=-V;NLYnwa^{)DP@gk~7?C9QvJ!Ocsy*lvKDe=VCN-5Ra54uI-e1)<~4?jNI$ zUkmX&$fp{1qkPiDKGaZ_c&dF^36cqJl`kva9Et}xGJdN1 zh6&gVpQ%h^Y)zmMNM70mKGG|ez4~$?|5wGCW?=OmSe|a1tJf>g#?R6(C6qiB$KW5Y zGf#r+H3`kZhP*EoB$+lkajIBr=BR!i=ZKG$g;UTHe&}y@f3$+*-!aVpK9v4@iI^$n z6wQV@^}4+8GC5Ix4oeF^{UFttnP6(F5SmyEZU$3{xtuC?(Ng5K8c-rUHqf z*|N;PO-?KrAnGEdm<0FHo3xqn?a3Q(o&Ha`YOqAvL{D%=!EnwXl(}%GGYd@}zx=e( zqa8q=2q@4p8_bv- z*BOq{rNy-%fcgkCJZ@}LI#PUJ4m`LarIXC- z3&jA81NALIX^aUqB4I=d6?aXgi1c$`3PWQafJ&!1)Hg8teJd9LhCEWYtmIoxq!iUt z!N?bhPA`~#Lvu2x3|N1M?Z@{*N)iE{#vQuUqBT(98l;<&r(lEMcS~`n13>?>Gv+B{ z&jVLIz2kw_5k`c9K18vF$HRd{H`b5E+X1tW!mfyP>W@uHPb?*`;y%Y(oFjAxS=`1j+ySHe5P#_xMkbaRs}j?;(lm-Dqxn14&@5D!<{}6kc@r zR<2IMm0o5zSR;ih1+N;`N+WoG}wj<1sQZLMqYBeUddcA|}Sb zf>D8%C^+AS#i%rE7dEy9*0!S5S{7Y4*Zf1^YY=K-Mt@%yYEzJS-Pi_7^dfJ{v5j6v z5f~k!ng$5xdbgw+SjT})WFvm&zc}H(&XvcaP7SG6*VTkNhTlLm$X!#Ex$ywXsO|71Ql6NK ztm`i(W#|>P+HPc9X5n3MDqWEzVU586t*eNovjyT?;=mU;Tee9UfUrqh?o{t<&H;T6 z$fX}%v-$OVNTiQFxXOQQWda52y!e?<)XVJ$NMXwM6xyVGjDDwgGC9wN@$BLLj(a3U zJ$HclIT%s)Q#GJ_oW8C2iRDsk#%8wawe_E*!pFZixivw~D6VU0;$ddeGSdaw7(r<8wC4~ZCd9dOOI^K7GNAh z>ZZTuQMtA6KJyk;*;+Y+#g{GbhGF7A?Hk-3aTOxdD$^Q@ElMJL}PFKH>e{^9$U33U^l{KPdTXk#cN_bKNt)CNyG1ye>1yg670mFJg; zw753(7zb>a%Nlu*cq7(IP3>ZRjQ^^otDbdyn&2=g1Ycl6(&SRN8h~~hvO)w3P*z$P zE3CYl69Ay54!RvhD5?OLus{#(V~N#_ho7H7NRiwQ!CS&-AZV6z5jFNBf9YKa0MO3yF!$<=B|0qC!h=3i%?D!-ib zNZ6e~gMGs>f?5*|Reb2_-+&iNiJ9lt>F0l*f3w{#PU|sA+=vpo2{Ddusy;#A=fA7r zMZlV9l!dA$sOdY{aF&K$VMy=*nMU^ROV`>q-tBwptBif9w!^)qhgxE{(CK{b9h5Sv z-nIttkH_jVmF0W1#F{*x-B5z=Rqzj!@rD|yxm!JsCb@6gdvp&}M^%mI(v_cDs-hNx zYv7=F9XvB27=aNOoc{{{r_K$#x~G?PCK|V#?XI^Yk%J6a6fF zz`o%Tn?%Fh&1$7FBbW@|8|1JYb1xQ;jLH}0nD5?GdHFrA$r6B_NpTgg@8FfDIWv&2 zYr&_|wseHH^cT$b{dB;Y_VD7iI)AWyaM_T9e#bGLWEKZhksP#9b3(wj$zfHH%nKV@2QV&+~$mn<}aI-#2+ed*sl>PT;B*q1O;7AP^zeY zlQA43$=vEPnl(bxR8z?SwLR5ks3HX~v=AUVkut)rYM;*viXxDcZ?$}?h@3U#WT}|n zc0c`fYw*}rLoRX#f(HtfpSo@?_@aiw_*S>Tt;b)JKYnO1B4k~79hqkp^gsm#Q0Ilw)0n|#`U7Fl%e>BJq1;j&jQJ-@#&ACBo7aY zA0Vn_VWfOSJ8EiE$`8gGl+4`cQa;l0Z_CZ6ht~_~R-in8>Ms6;k-W6dItwq4!-Zo0 zdpzuOD$_AQ2lge1SN)9g3bwxB7n*EYB9rV(UZBITtLHhfet4xR;}z!hwK)&*gUF%LIZYlnn0c5L6iXSLkRzJoYa#?%?u zP47Y4feFDo8Bt@w*6K{5-eT$HC{PI!y*qNp3JHcUcpJsg^F>XDVPH@dVeC=)h>5&7 zX@Oo9VY5L`-LBh+M8L8}do6({^R-OFqu|_UW99PtR;%vF5@c7M4Ta%DRk>0gPHhgG zP@()&-qUUYL=2PtUhE;{S$V?W!!c%RE1hQjJCEt9^`MUTL<`kuYDF|x@x8Y$O2=?F z(C}1mc<|-Z1hK^6FFph*zvVQhE%Yr8@CL-sW&pS!BTkdMQJaIf*Ukl~ZNV#ZxNN(r z0)P_df&UF^fztvK_QuXs@$G5Ig<-r2$wXQss^Q5@Y{t*L@_^SV=1*m;?t9I?usd;> zL0sDrjy0!f^=l*l(Ia;yv#At+s?;{+@~ga{QSKS*WigC;!paH;Q4TWdMShR7O(`mW zXbQMqkAjWdq;Lzkt%2S)qn%XrY6kkv0Ia8sm5%RU_Ot9zRO$(f$9**zU~-bC9Jnu9 zm5n=`epEfNVn_?)NmTKee!`VW-%L#qU3$#hxWjS4G8>cdc+$m3xe!F05rRyZ->d~6ogY9;+5D87qa^0HwJt5s+r!P5S613)^hCZvw|*kF%)z`rQ^5L;B)|G<3Ee%)eyxWkMR*&fzvp>>wx2v zdrLAgX@x1Vo?j#=#ON{OzYI0}16ep@73>3zCuA20V3OGcfxngFo33 zo)jfYC<#%D*G>J^U*@RVZ=+SExB%1j8{fm2hW|5NZ0k zT@)lrP`C6FNh;1WEj%83BA33sX){X+@OCBB`=8VpSPo&XdpAgr&s&Ey<5rzYUC&+G zUcAVx_jqhQ;7`pdwVbNHi)Y~A&<3Zleq|-V*ZQem^w(~)0eB5ElEkCFxHUj}&*0{U#S)W?LjroDBw^Tj^U{^D}#s&;HRk zBr5$O?EKeXUA1a1`R}anCn%OJ?l)BX#VIl^<+ZGU`g-S@4)fE#H@SVhj?2-629&{3 zC-&K3Xqa+G2om|JmdL-6=DId9#`V60_=Oi9qLz;w`X{<0h?SfFn6o|Tr_r)Ba<@NT z=Ng@^-}~o&a06Txar_|VS&!L-`+zvN7}>SxtPJcw9I`I-4#yvTbuiGz%)piCzgx!PewKM+_ zuWgmz-zCyqK5$S7yF;AI-Dr`QRxoS#9#jj!%Gexq^%B2BDw5%3l$b~zvzCkOl;B^s z_sP=_n$T@$Q#?Eqd`QVyfDlfHFdohkbwEWIM&$RrGm(LBwLZu?wa(+^gi9UZI-Q(S z^kqh5!(zOwK{m71V-ts9b=Mg!?_RMfbol{e*!YKsC0WaE;-qCQ+!j*kWoai_7rf+1 z>ar@>SFA+%!WfsDQn}1VAFQtNbPpT}N8|?el^;&Y;9FgRvEFIbn;%enwfkBF&>J7& z&ndh-oDzVTQZ_jWMleqd&{%`8xP=OPKnC;}B))7&(rwV>{0ao)#&1jj`rnz*EDT-F z<#k_-2&KoSF8pWXtCYW8WZ=!CUA)P?zOnmeP8`R0s<;reEJ>3g%&uyo5UoxjpbBzc zh&Vg5b`WBXLt((ONGKgJC3dd(IVgMXQyn*< z*BOmL*rewV>-DU*mJ0v8h3vOo*GcS%8MKv!Y`o-Pb5s?Dg~pQfNdsIxHyFf!%U`w#AqB*s750{+B#t@VDv@)vVX1}cpJU#I;5AYiK- zt~54Wh~s;uvjZs^hTup3?x@%4mY9Q)nMDGnj6|igPo-|V;}6+?6A1rH!s=gS<^Hl` zM>=+@J3_&5qGss1i+}?Lh1m(48+9X5#QzW$=Cha(pG>q;lD5};3mj%ZXCl6!Afn33 z?i>Gx%(S1xpN{93T|Fj48!NsW&j$gGXTPn!dDz?b&wVCDY_D@4l-ZLbtsVHN@AmRI zTh*!BxxeGXL(ajdF#q=UQ|f2;=InJD==wa*^J)ovJkb5+MZF}B=`z@}zS!q4|NBw0 z=(V>8j(|@rh4sY{?iaRTZoRhI{5W%-SQyAMiO;HPi@KnfIvBtDr1#SK+2gxESC+Ksj-CMQ+$w3y3VN4^`ycz z5ZTYNZ)`a2JygKF@DhY&GIdWc=cFIRv;%I*n)FFq%X;ac1nE2x2}Ozb1im4dFaan) z=++M)W(5dWkm?qzKE3?U%7lu|7UMlm6*oDLuni6&vprnSH6W}^eeINj-%`{#o=KXQ zSQ?~qFOVgYS9bx2_fjetJIsC-TK~vINa;c0*C|8-L%GlM^UuJ_!_F9gi@-{TDe zbkcCN_A$OnIBFy2aovaYoUJ{*fl>!z1H)P1PRpBrmUvLDf$+!~E5-Lz)vog&>c@&q zn5t`|{Z-aRkb&Ou8PlB2DIuuv@*{&2D~L9y)+HU!4cRTbx&ki+mdvW4N|~8mCCLBe zdrwi4geB#M8Ps5LgEa_)mjfr_(m}UYa&%u)ikhoh-S;~CA+K}cNL@_I`YHlc(iYhQLW15B2(edfW^k#yAqeHG|8_8Iu z!tOp_UQA5LlCqB6CmpFj;Am1Tvui+VVyt2FvV6q#uT!4+C(XHqL9-=FOH}5W$(15V z-LkZk`b0pugJxy3n=*Rxfv22)LDTC!&tFqXdc`s3NGvuNMb`YQ_W@+HlnY{dXL+JB zYy@O=PK^O8l-0y3U;qZcJe;Fq=Uo|E5VwHZ$NZp!n$zz~>pV$7_^PPW-1kOUc6smzM)V@Ngi>(?_dzW8nkFr z=;iSl?;M4ZD7c(S?PqQqek~mEr0*AIOW2ords3_b(8}Bxc)_X+ochDn*Xvbe zQ&81xLM>2YDx-=bX;td*tiXo>@RsSTcSna&WAsb@N49dJWsjtRGhX7ix^gIM=~yA3 zydO*PnrcD~=l6}t5sdZ3jPhR`O_dRklD3DvDh)aj#>uDWM!o*6o-X62CkVAR$cNCy zI-mGllXMIklMJX=ioqS9T)``XKE0#MDl_LCSR5M}DpY>*THD_xrtXA8NMu%Rsy*u3 zzLm50qXBnsCrTb6=^Z^6KX(+mbk9*z@L&~2dS5+0x!1bjT;+1s<$p8F>}<+L9W20X zE2@dg{jdGwRD_lVMeO*?rqa>VqpC79S#tKj#>!`keBzWZCo0#dG$6LbLZw9%_Lxl4 z<-nhatpOUnqOyU{^|bcRI{Wk+WmkqTi$Hcm?*;{5MF67bcGj$EK)(znOc=Z;E;z(+ z?AM${j!ucknu^?~K23pGV?f;OA?50aGN(=yBF%DnU$$3X-`$YEP*DSM z&-@%H64rPR{lhMO|5~sa+xmfPPe=LVwJ@{YS2G1YT{m3TBmH+5UQYM)^gdpXPTpM< zpnLnqUH*-&*nO?d2FoU?!gU!S+x5M33Jxvhh74=;shtDHuLU@%QQ0?|JCrNzkJ?=y zxwdaUxWqr()Uri!F|x(b6FTXlE;g)-#F`yWs<9^1t+05%l>MIIZxXg;-Un1Cm2^Ua zSfzttc>#UJryUOt!YpSMRJN0Lf>hGD$sel8{D3^e=0w3wqvx6so^X4 z{dhdu$^O5$1I(!kkgKsYi5Vj2F*2K2@|-$8vWGhG#DBx;aw;@SfK+O;_{$ELOn$v) zBG0Bjcw2FitpH2Aj&G|7w(+8C-~Y;)sI>|GIe6f1zH{QSE^~14Q2iZZw~Hg;=v;X@ zUt67N0ClD>$X%}+B*Kh4<@fPOl>uu9?M0D3f6?d~VyISH;t_AK-4)Mh@qHZ{v(FFT zV;|Nu45Ka})hwmuQM1)5;rNGs3&Z6fpQvpoh~C&1Klyt;nFZvSJlNRd_IInovc6uT z`S*(_e}4=L|Jx|M|L2pN@b`g>cD0Gke}CS83N zDgIJvG$Cz&J4tWMLt;WnQZrpN6f3`@ARF$vhnGG*#9ZA>A1O*F?3iiLSZIz1p2I>~ zvzCWgm>m}BC0U)Ealrjp&q2mv;FvQXh{qd|0nch5bknH}#*9SxhYXOs%oTfxCx1U> zLe_%^AtNv{yi6?;wa)6qVLsJ{FACX!o9=-1$6aYy=^9x{Uc zQxlCn37jIyXTLmn3-E83%V_LY0Ref6hIztjn*Xz!+;pnQ8@_wBgVbl5UjZ{Ggpc!G z#?OIs|I8{t$cM#AKppSWJqNi37`_OhPaMiC3p+c~fKlO|e^rt@)0aEIxCGPJntBPy z8+bDX*%q`tpW{W9A$khqBG~}^Cgix_&~esWU_MSp{+KaEKKnq84mP{+eFMgq`)eYkeM=AbvBx25Uq|FbK^YsU(-R$*WbHCNDyx zNY`8}CT+M^MB|~UKRiVggKPC}$SF?M7LwsA%}&-w;y#jV%$NlYWZA8f7{kumYD##k zx+aYea63ePbedW)8v{yk5qa6-L?siDY+SSS231q)D6F%N<8V9XLPFTSsqkoico!EQ zxj?R5Zg_a!&$w3hH^*Ro)R@8$V<4Iio0eE6p>*Rk4xDf5z=Z2_8_#pgTk1Kgy%LJ= z8iis~H=f2CT~x`F5@sgSh6Ol{eY@KjfvD^4YX(zc5) z8qsx(8j}+0TdNmjpRJ0<6C=^{cEK@f0VA^UHQYK+`E5evbZ_g_l*#?o3p5dQ=Q42b z1AxxJcm5FP0BsIUrWOm1f|)~)^lug>>DofmHj|qFBSk*;bvzr=_Q=$!^W;s5mbRWS z`@s3?^EEBAde-ZT*y#b~0G=|~CzqLid$uip8al z49QM?CnlOzGnJf9%+@P6g2Nr85aq3%6i6 zcPLm^f6F@JT&q|L$Ibq_+RU}c+mUEw#Jm~z@Y=}o5DGpsY-}`Yl4G9CM?%A$9zSGf zu#Le@`to=ZoPHeLKPG10ORyg_2`_DCjYNixGi=6bYh+kao$n6ve7D~^hT(^cDT6JS``_4)JX2Yr1l4Gn!QEuSa9*VJ%WtSq^l&*7ws z#oDB#KDGMQYr=`@*i+m4J>q`rJ;|{nYh^Ar⁡a~d*I zQ@Na)KyE`ISBxS_e6Bi>+b0jaSfjrv50nS;rF?FdTzs)ctxgJ@=+QT1Nwql{(#gqu zj$W(QtFwAq^bcCp6MZ!~snWkMYV}!ib*i{WpW2Wkf7OzeD&;?I$f(JZCW*PPE@~Tc zqAJtMUtiL2+J6G%&YOIA)+jyfkP zHHkmDHcG@jsoX5C^p!NQFEH@$ zKyDA0^OS??QP$rqBnv_G2-1KceF*Xt0rLMJn-&0i0C@Vp*rcj600$8#NjYLZkaAh_ zK#(N{YAL8m;$+DYwH(O#Kr7Fx(Prq?XhQ~)H93@;QKJQu&?HG&>a0n^CTW|5v7w=7 z5=JgJFez!02)ovUCcp&QNn$i~<`W`0OM8vASBg+qX^rIMp?Sqj=G+Us zOjX&G?|VnVu=v^43a^->ORt@B7r`;#u6>-<8&xGx7}cF(&#)TccdSNil#B2xs~zEL z(1t;KY^YIRV!VE<4)V2>Vb|{uS60uy@{U&bE8d>(Jy&<6?n9{k>?L;L?3qLQJOUNg zNJRBN|Hu^LYS_a+Q!1@oS9x2Q_2S35Opop|b61!Z3VDn>M!OWGUBZ1ANrY@HzXbV4 zll%Bpg;Xp{4Xp?D+RH$=^6*Kk#u6KW!mLrbDh}7opu6K`n2A7k^GLw6eO<6(n|j|B zCJe&x060WVL_+rfjJISTa2d7_r+RyTdOy!<_+F&4G2uqoZlCIR6KFv{&O&grHo+!l z?N|h|q`thzmhMrt&wj-?4j+v#z~JPP?WO~1o*Lc(GM@nQDc{*+Luv0S(L-tO!JBle z;nsyhYcAfUJ(-xwGR*{}ZQstU1;Hh}D#$Ai+`(Ll9pwyfKxNN?n38&c$ ztK@`eWjHW*-@R4;?|96uIdHTPWZNl5f5@gep`ukbGDT;jnHvD_OWRuw)>_P*P>O2o zg-WOpXKxTn7wumUHRo<>z;Nds(3K*Kfz3jgiiWA2Hu-zY@PzIyD%g)K?8Mm$URDt- zx*xgYZuH(O3wXK#2jRYBMWS?CCmC>Y*sQf3)T%BS-ezDH1JeDVgz7qb4hso*j-g7+ z3>M|LW{z``APQ_JL*AGpMn@MOQ_m@OwY^FFsku74h_z|}$`3iQNCugft!%>{5b45B*iLxxOBlsXe(lra&42&**_;z{ zRrq>Zm^AZi!@)~`*s^sn)wN#H#cr|SN#6Xrd=bjsY7wTI+^6EZhYJ>wK4Tm5@u?dn z8vSiNHJ*5TC(M?4{~YMCwEe~c|2L=0)*%31;}-{g8w#8?M*$+w-heF>e3khf1UqS- z(+;^iSgcW(*!S?hoxGB)&#?aun-@Mo9MO>xU^SRw8zvjlNTXa(tJ)jaE)-0wZu$vo zpI;fW8=_})G&>Aph5m5U=@*PKt!%aM>$j_#h>s^Y_2by5r(O)#11>+mx$!J&_(7*d z58Yu<*Aq1m9^vosUUGJyp8Y+%i^M)@g$fb8ckPMN^r<^vWM~LA3`sh6a;L&)PZVOy zAjitt%zuCVLRsI{f?~{9R6zK~hmha`_MUt!1VvSKBc~Sb;+j4jj+1zni>;4i1ych$ zqgGA7YqNhq?KAs!@#?NFYrek*W-^K+qr?mnhw!@o751v~Z?JWn`S~}fcioCm`G00o zQ1)Sz=w;%P(uFt=_JrzTEq?yu-z!6$WhzVf?G&)F)*B~e`b_4{1R}&aE9MlOp6;6D zO4x0M@hIaTKvE6{qLMLU)v&>0R1LFqS9foE4Mmkcgq&n^W1@sLJ$b)z-4tzjp5b7U ztI(xL`YY7*Gn#E&z&SU%lN_dit!0OVBVwJzVg-!HhBzl8_UwBf11snm2|4zv`Y-^e z5Z)$ol(Nb&4+t~mv+iJ*rrjH&H2lKGD{KrxM5cgS#i9 zFw1OZKKQOA%<4$Ch?C?`DLe-F{)$sm?H8=ubK~*L*`LoYc;EQlnH@KhG|R=t+#Ble zkmm~)@v}xmmSIAv=NxQioMUekQFr;Rn0SsfAYA$m)t|g4q9xxZ+kT{ya&L-gJC-1L zrUD}|6;qkUUuAa9L1dYs`P!O{u!Xf#TTZQ5n?LX;^QiG^YOmYAzvgKa8|(f!sh;PP zTAZKT0)}&a*ih48x#2L#v&k+*d<^1a8jy#M&hsD|z2785^st z_*dP#Wkg?Ha+@!QI71vH72h!35q-R+%P|6)-mx z5~i>%t)!!M%zcb;qnPL7z%7U6nF_LLYj1k zY|0d&VG8e1TV3zAfjZ}pN`9=DiQl_+?_Fx95JHrH<_DM3arR*DU!tAyD|bPPm}+qS zaKMb6C_Vx!|9e|Rl`Zu-1U2m^V7mY*j14skgwXFfW{v+e-+{TkFik-r@eEL*OROP$ zR%2i1%fwSRn6+)*sw4L;aNpUh;X7q2#MtAobz-e>snbs?g7C`}GS3R%vl3bq8P87N zUmM2$YKa$k4E?UX5rfTy=EMo{)7c2=xvU`Q#mxqw*c0NVERiQZ;m@Hi0rlndv~e76 z?^!HlRbK;ySHwU((+5e!r|N4`m<+H!yF5U9oawUJk=0KW^+%hp$@d(iZ2dY{2Oz`pf9PnKP7r$#dWCzu0#tu# zE<%l7KZi1vs!tv*pwe~TnZ)<&laDyR0fIQuO<7^om%4S{85s1-!M}`j!UU~d$V9eq_Ji$Xqo-JYWi=w|Bd_Hf^nTW&Z1Bp){v zQ3{_2S#Qu#T!ioe4v63p+=jQOhl0jYfa=^zT%d2Ui+5#0wnCMiQuR1fWv82IsQ_7x z;ni{=d$GJxNcNDBi-qK;{$!03DId+7fslO>@{WE)+mDp$@@I7*WGIEf21Mn?mHK6I zZQ!_Fz`Hx5JAi&ew#BU2ICqvXlMmr|;7K_2EbZr;D=AN1`F@9xcfZcrA!OLd0Bnjr zd}!`vyMUL6)cyVRK0yB(oxMOzu|2&x(wdbNGl`S1NueYd=bUS*Ddr_%`=Z> zZ)eh;3l7-HoQ~c@D$U#RLqLxO+Kgpusupg; z(^K5&wQknuNsOktXa~<|e5dObs}*D!2ph`A35x^|eddz!N*OgzE~eD5+uLzL4&v*rw8*Y9#M9kneod-E^bw6_z)R>g)okE4uxS z_sWw5ah6!zRxwmN#G;zBoBTl5P|BMa(B510o5_J}gcztWYFBjKL~TwZJ1c9CRYM-S zvwWsbL_t#B5KNky(4~< z6e~tI)_P6!gP&vxKN$&{O48ad!v2muWex5b*BmrglbSi8`t>^MD0Ic02sSgm<%9hV z)yKc=HExk?wcpnk8J2Jrj^u%xEFTLDxYn1npI!PpfdLy5l%tS{ji0TA5woK6OU

      r#&4g`2BD4t& z6Zzc>IPlTr@WauFC5*U>@nJ+ErBMMpgyp{> z;n_W|FD>64vEHaV;L$_OFr|<<`x{Nm`vg9|V~__g&3)K%#{*c%ft_|uBZ0)y9;a zU0m9MP8jaD58BO2oS8&dIDLh#F=E{4k3M`*99$kA_oZN+t)a#wlA8_Z_-=c%y>2 zs{io1uf%l}qGFWj_%AUE9f`jiQ? zWgG@qjX^$ac&s&*t-~*v75F7>UK|hh;KBR0S|u?S_aE7iX&}juk(QeY%h;sV7{K=v zmdk9DghUTEF=Z;k`s#l0iZgyq+QCeGr8f+tAzq`+o+vDgCTuNdeb=RNO*@g3z=m!8 zMJIX3UMI^0%iDFwBY&}shSFs2{|NS-Z_*4Of?$QhcPMo%;OD(J?0j^~g+6jN@l*Jg$Sopr$OZ-P&OBnS`UUEno0Z3uB=j#y9irNHO8}Vdty0E`PV4 zJy1Kf^(1%r&K}1R;Jsz)R6eK_?7g*;B21WF@9I^MXP39$D|aF=k*Og5leqJqfcu4w zaw~qYS9l#(OgjO&(+$2XUVtB;5MfMPc_=GM6Oh?8i>lD$Il#(bWY(^q^Es;r&u(Oc zUCBukGO&2WXO+35?@r4%EYE!-9>X!YDzC&+uizPcIKA6fOf*%Lxf<13&3y!m!@zHp#*sV`U=BjP0m z(ae!MS>fM#!1bOx?#TIY8&6_?rXT4np2Hj0po>%mc8Z>*r}qWVL=##88VivWIO$Tt zUX^#E9{S{HT3HdWxM+*_UBad-ku2*?OC~N9E?w_l!kJF&pKGUso;NLE>6&RGP)TJ^ z9rYY$yUy!}4}QqkilMksm|2qvk1cB!QQk_zcW|~gSOJwe;EsX*NHJ?rHe+CkciZ@7 zKmO%s>mlD}d!TGaIZ(Zjnf?rAj>48V_hxtO%YAm1t#^(*bUt56R2Uacdm&U^`N_UK z!1Kd~WhoG@U*vaEo?;9Zo~xgXQ2-KJnK!+iQ${-IyAW9+`uMEe|(T` zNZ{i`+NfNfXcvH2ETR_q9Y1z6j5{N-ZQk@cIvusJRzNDx75RRE3VbO2AS9czR7NUu zgoo@Gl053l4%sXj+LJvYSU=p=`|5&jqih?l7Tl?*TxtbTc$T48Ex(xLRp-v`cxnGf zA~0XSb&|2g>Vdy=Sj4f2TDa^$hH`2+WMk34UXuf&LUZOmPM{eOtr00}$uB`4<+C4^ zFMCv?%h#`aWWTDV#B_#QUiOudqsWJ%D!^9;DDfty`4aA=dE^eAIinP=KexGygr{(ltZf8kcb2ivZ?x!b{%7KjF#H!nf<_ zZ0MGsZ|Fo*Ks^fCn&h<^u?O#o?wf&4Yyj1CaDv^mIZgQk7edX-IVH_jt0?F!>XJ6v z_lvYvw6b#Pk~1x=+-x-W*tC~f;13&s3YU@CO?H1;X1db1-=kX`4mg_}Gp)r$zdeJ* zfNqAO%?9#sZ0d0{<&-&)gi)G!)FbG#BRl}ho}D;HYmqJ4=SqH@j~J(hR`kzt-HLXc zdAjEA)8^aqm&1{RX4-qNS!af_&W*P%e18U4z*JO)5hK8$pP8}Z`QqbK4th;@cwuRK ziT=P$dm^J__cpIw0e#o?#9p$(H!t3{1gSKVh8}?hc(Tpy#NFA0w-7)yMQq1Qy(T<; z%acu67B-eT$yeZP!L~jRBb6q^;xH=x0?{bh8;hwB7E5CEnaa zQ?#r;Gy9=C^uE6s7&PoX&Qu;bwFBJ=?y?~JrF*AQhhF=gq&-lM+*S{^yAO;x7N=sTXs_P-vw^Y1)I;ra8siDU|?coP$~^ zV*8KHtxL2>KTdzrzi?z(*K1Wk)c}fr;j?z5CvmJPg1=`%x!5F*(=qH2yBPYdbMW?X zYopV%*M}PU&@LsC`WPjmWb@seLEERt2M@j8aI`gRM73hpyL7w76B{Wn|3bfXuCp{v zT8J5RMd4Pm%u1*jRs(mS@1B9F;ku5#!phv8I{5^VAf4O zmc>qg{WHvo+jIzZ>2nYT1TH7N_-?WoyY~-#^2zD2kI|>5)}vcIA=#Ha+1IW*0#@AW zkCtStZyaNK6v_G?c~$=7?vOc7h@f<*gET)SYOrA#-V!>2_lr#751!MO&6a)vzt~4k zCp|b97=1d-&W&*F)u3g;hUH&HHs8$!gy?8qoBr5$%X4`hWjmS={!%?V7~0ipV*%zv zv5_S1))FhbhaP1WU6vmJ6AAuj>+|?y4Qt6UcWC{de^0ohB;KgC!ugBu-`N9Srf=Lv zEY}kF`z(3pWhO#_G1+$TXmc_#7tBwnl$U`ACda+efJ_?-vV7i;&pRp7V%b%KBn(ob4u%rMHHt3 z3-_dZBhea4l5=bo=v3*Kq+jo>cx7oXP`!3}9z&`;qOJeR3=?!h@Z8mX2bj8|o4B*(?u!l&G_C|eKW%#YAD2yk zjBIe0do26CEty2ocX{{8aF;OC#soduR>F0#}Ae%4({ zTEufavzBaycS=~kfAbWa00W(z{Bs*ehq%l8M-;LhPVmil1Dxj#+2f;Ab-xORR#XbO z$&XpTVc?wM-tS-Thq> zs`Xy@4Y*J59zl;F5{{y+%z|fv%ux)m+wWUs0f3l*;c9OmMkY>ugQP}!Trs7TgqQ{7 zogpxq3Y9oXe&P@j#NfPDPQfsW?;-Qer?%s%rPJhNjk<~rqQXj!=UyQY1drsmimJN1 zrg-jK`d<6(fh0ALa$P^stHRl4BPumI&^SdpwOxN_`#04HglJ;k?1UchQg>GDO6-{e zzirm|@r))HZ2;JQKQexg(`t(lj}Z-I{9bN=NG>{)Drfr4Pj_O1x3cqy>CYwS3?94& zU~=&#n6!rXQ9Jy!Q7`LH>#Wvyc*_n|M%wJ|PSI9;XSvdt$ND$A^xBT5L5MSA#(9U2 z+TqazgmZ$CfM5h>REG~lq>aA1Qcq-=u!Up+8}A~Qs5CY#Lk1wQ*}~ds+!96Uh3=}Z z-so?gi|?0SpA)%kW1`e`N5HC$ccv_TRhd3e`lH~zeh@m zwfBi&ytPL0PW9aL5L<0^v}vxoRocJw{hoq6_orvCdR>{4T9|nFbE$)*u7Q6vy?wFA zMe(C4f!k_btg1{9#o$i%?*>yOA{(9A(nSvlUJ0GZE^{8ELqTy*&;oY<1R&NN0#D{6 zgk3xskxx%`Z*rnavKcWSuWs`D7{T8at+l&-!ZpMkntyb(FhC2@rb>(LC1DKw+UE71 z1~EPoz`3$c1Q=3m{FD@{@n?BtmL0(s94U!aP#mUqBHo+TmQ@DTeV3A{zvO9GJQo+a zQ7HtP0xKHD!sx?w_FL~UV6>JJgNptMSOuds!ZqnMA<0=;vWjoUd!wBcynUX{f(R(# zXfL#ojiE-)x+%u`=O5+z?urCRB=D%$yON_;aYswof= zJo#7t-P(YXdAc=T3}KINILy$S*G7(;9%-<1))TRuR9f51M{+jo6s=b6%2&M5V0dqV z20Gv>g;}#OVF#Sj8m7VRHT_V%zkczzeQ_<_!kf9@4J+h#mrHwk#2F%QfBP>w0&X=zf%}M6o4^mpD7vZ(uOIBA%-I?+ba=m z_c$Q}6BOpa0}Q-@;x)jc&U$HS%@%eZ3uXG&xWdX7*7^+_ST#C#!6jfH45_n5N9 zN9ART7t`05(Bp4Imo@?}QwR~%Z@myB;BI@ntUxHpOdF?(H+r zAIGOoIE`tJ0l0J^yEjg2;u6`|#g*7^zE}-y6c(>_aZg2EDVNNzC^?fs6qvpLVFb*@G;HF z(+o&LU`IAa-tw-8R~hrU&!dlI#|ohb^EA3+=}?Sp3`ROY^{rS4iseJjb2|g+Eqq%R z$(1P(66H$)d8yFtg0G42^#;Sy+62=V+u&yJ2WzJa2OIl8wcB7=<738otHM_JVE??RTNUQzq|;oZ<<1y7150af(dAMeSvg zOOf+LD)?+9&3XC^0EOau?BoOY<PWq@$y3495{3@Q^HiMx87eL0Sdc? zJ6(ru`|wYOqpF`dYffft$^#Ah>M-kbeTX*;_LS4+?*^U)>b5&hmnN-Yp$5 z_P}jc_L~qQek3GAQ+5SgsVw}dzi{11VTD&~^NkM1*P`-h1mVr`J_=|80?pL%*DlTN zLsez{dc5p%qLu1dwon6HQ?j4}GYA~b=a*vFgH8|y#fWmY@O(Sm6r4L!xHf^vtUE&; zB~kS41OcE4iy;BVbi}CXSi&*??H^i^o5=P=?4QsQRaU9pe1w!hzhG}oiJtkO4ik*x z&MDeBHvlbr_P>JSiH%fKZ;|EZ74{|3h4x^2dKsxq*36hV~60>)9*Q%8L zl?UslEC|z}N{pPaFNO^c-ah@+8i%C{^c^z;w_#KncFFNnOw*-xO~fVdh`@M?lFi%m z$k=m(iU?-V5Nu!FA%Yi16PzzKTuv^%oQq&nX*=-(3u<<+Rf@hpRP(k%s2UBKz=T)4y?zkm!X`d0q3YyJ`g(enju(3a+XE zk`O*NVv}6&LIY${72PMgMlGXw%kpDn7g$l`C8fbs7P!`GWFEtSu5g{8c%|`5MKl4>j>69pD*v=W(*KBI*6bB2uDLTh8QrdScB?;5BZ{{5f_L+5kp8xU@Je=n!?8D z_;P%@iPa4#%6%!mnguy?R|LUhc3mW~Lw=BhN6i;zw*BTS(cpU9xuw{l#{#mfWExga%$`jcpJ_d6 zR|%<@0+^SAkR(`9_o;KiB?QT@-Q>$@F*esjZ^maB2V)VE$&oPUgit|By+Vh)&FA*x7l2vHP(lbegByTZ9h&068y}<~wX>*V zyj>(C`|I*I%r1u6uGZ!~BEgQUwP&f>7~Tuu1e3_HU@uTQMS!^M0J~u;pSIP}&}_zW#@Rkei^6K*2l~eqI7zvrHYX#7AV~ zCnAuT(w2dUfdq*$K{Apc5#l4Ws~<*b?3ozVh=o*O?dj-|6=B}9v7_Gp9(Sv_P1lA5 z(LquJyc(Nf4KBmKUohN1n4noTc3|p~xww1@@r%x7{nFUKP za)ZnCUGZ?oLLCoe;}|3XzHQyo)&g}w`W5T{ihTb))hYm$e-1h>y+tpbec{i-Yaffm zcz#pV|~YE^wbnc;hsxDHc`X zpUqjmY2#9fgix^yt3dj5M~nwY7j2r)j31QbHWgmGIe4hzLcm%8Jz`$Y3qLWZ0B0WD z<628n&aatWsZS_eDdEO~ogu<_sYWfq@S)jiNflmd{BfkEu_j1!rVSK{s7oIUPJJY; z))l7ngxTGtU~Wm!*wi)G`u>YW76}L|1qCq}0o_E1#|VqOk`oLBMtE|Pkzl*K;Drtg zN8@|2anqiR!MWKuBJB;FVL6m`aqiBeey{a2uB`9R6W+PK?L&9 z()=JsF>7ZVrk_bDs=mUli@$K6n4u%4_bwq;%|6atGT~lWYGu<(^ujCmD>MTDYQjhG z5(?O@m)2c7h+Yd1D)#MLBI;X0Fb&fapS{XnuGU~I;zPGj2Vl)JhoJ*YGD6$TOTClK z7iLDLkF3aOBKlBUdL1!Z`13pIVCCcK2V!R`|I7E$1IOd|u6|AY%DG7k6t90+ah
      \ +\ +
      @@ -177,7 +177,7 @@ - +
      @@ -191,7 +191,7 @@
      SRDB ID   Synopsis4 Sep 1999

      - +
      Problem Description Top
      Ever since upgrading to Solaris 2.6, the system clock has been drifting and
      @@ -200,7 +200,7 @@ didn''t complete' and 'time reset (step)' a lot in the /var/adm/messages
       file. The system either was previously working fine with the freeware
       xntpd or the configuration was copied from another system that was 
       using the freeware version.
      --- 23-Apr-99 08:22 US/Eastern --
      +-- 23-Apr-99 08:22 US/Eastern --
      Problem Solution Top
      The common lore for setting up xntpd on Solaris using
      @@ -221,7 +221,7 @@ clock, the hard clock is also controlled. Setting
       defaulkt behavior, having exactly the opposite effect 
       as that intended.
       
      -Do not set dosynctodr to 0.
      +Do not set dosynctodr to 0.
      diff --git a/contrib/ntp/html/hints/solaris.html b/contrib/ntp/html/hints/solaris.html new file mode 100644 index 000000000..4b83862e7 --- /dev/null +++ b/contrib/ntp/html/hints/solaris.html @@ -0,0 +1,236 @@ + + +Solaris hints and kinks + + + +Information on compiling and executing ntpd under Solaris. +
      +

      Last update: + 27-Jan-2014 05:31 + UTC, +John Hawkinson, + <jhawk@MIT.EDU> +

      +

      +If you're not running Solaris 2.5.1 or later, it is likely +that you will have problems; upgrading would be a really good plan. +

      +

      All Solaris versions

      +

      + We have a report that says starting with Solaris 2.6 we should leave + dosynctodr alone. + Here is the report. +

      +Proper operation of ntp under Solaris may require setting the kernel +variable dosynctodr to zero (meaning "do not synchronize the clock +to the hardware time-of-day clock"). This can be done with the +tickadj utility: +

      +tickadj -s +
      +If you prefer, it can also be done with the native Solaris kernel debugger: +
      +echo dosynctodr/W0 | adb -k -w /dev/ksyms /dev/mem +
      +

      +Or, it can also be set by adding a line to /etc/system: +

      +set dosynctodr = 0 +
      +

      +Instead of the tick kernel variable, which many operating +systems use to control microseconds added to the system time every +clock tick (c.f. Dealing +with Frequency Tolerance Violations), Solaris has the variables +nsec_per_tick and usec_per_tick. +

      +nsec_per_tick and usec_per_tick control the number of +nanoseconds and microseconds, respectively, added to the system clock +each clock interrupt. Enterprising souls may set these based on +information collected by ntpd in the /etc/ntp.drift file +to correct for individual hardware variations. +

      +On UltraSPARC systems, nsec_per_tick and usec_per_tick +are ignored in favor of the cpu_tick_freq variable, which +should be automatically be determined by the PROM in an accurate +fashion. +

      +In general, the same ntp binaries should not be used across multiple +operating system releases. There is enough variation in the core operating +system support for timekeeping that a rebuild of ntpd for the idiosyncracies +of your specific operating system version is advisable. +

      +It is recommended that ntp be started via a script like this one, installed in +/etc/init.d/ntpd with a symbol link from +/etc/rc2.d/S99ntpd. + + +

      Dealing with Frequency Tolerance Violations (tickadj and +Friends)

      + The NTP Version 3 specification RFC-1305 calls for a maximum + oscillator frequency tolerance of +-100 parts-per-million (PPM), which is +representative of those components suitable for use in relatively +inexpensive workstation platforms. For those platforms meeting this +tolerance, NTP will automatically compensate for the frequency errors of the +individual oscillator and no further adjustments are required, either to the +configuration file or to various kernel variables. For the NTP Version 4 +release, this tolerance has been increased to +-500 PPM.

      However, in the +case of certain notorious platforms, in particular Sun 4.1.1 systems, the +performance can be improved by adjusting the values of certain kernel +variables; in particular, tick and tickadj. The variable +tick is the increment in microseconds added to the system time on +each interval- timer interrupt, while the variable tickadj is used +by the time adjustment code as a slew rate, in microseconds per tick. When +the time is being adjusted via a call to the system routine +adjtime(), the kernel increases or reduces tick by tickadj +microseconds per tick until the specified adjustment has been +completed. Unfortunately, in most Unix implementations the tick increment +must be either zero or plus/minus exactly tickadj microseconds, +meaning that adjustments are truncated to be an integral multiple of +tickadj (this latter behaviour is a misfeature, and is the only +reason the tickadj code needs to concern itself with the internal +implementation of tickadj at all). In addition, the stock Unix +implementation considers it an error to request another adjustment before a +prior one has completed.

      Thus, to make very sure it avoids problems +related to the roundoff, the tickadj program can be used to adjust +the values of tick and tickadj. This ensures that all +adjustments given to adjtime() are an even multiple of +tickadj microseconds and computes the largest adjustment that can +be completed in the adjustment interval (using both the value of +tick and the value of tickadj) so it can avoid exceeding +this limit. It is important to note that not all systems will allow +inspection or modification of kernel variables other than at system build +time. It is also important to know that, with the current NTP tolerances, it +is rarely necessary to make these changes, but in many cases they will +substantially improve the general accuracy of the time service.

      +

      Unfortunately, the value of tickadj set by default is almost +always too large for ntpd. NTP operates by continuously making +small adjustments to the clock, usually at one-second intervals. If +tickaj is set too large, the adjustments will disappear in the +roundoff; while, if tickadj is too small, NTP will have difficulty +if it needs to make an occasional large adjustment. While the daemon itself +will read the kernel's values of these variables, it will not change the +values, even if they are unsuitable. You must do this yourself before the +daemon is started using the tickadj program included in the +./util directory of the distribution. Note that the latter program +will also compute an optimal value of tickadj for NTP use based on +the kernel's value of tick.

      The tickadj program can +reset several other kernel variables if asked. It can change the value of +tick if asked. This is handy to compensate for kernel bugs which +cause the clock to run with a very large frequency error, as with SunOS +4.1.1 systems. It can also be used to set the value of the kernel +dosynctodr variable to zero. This variable controls whether to +synchronize the system clock to the time-of-day clock, something you really +don't want to be happen when ntpd is trying to keep it under +control. In some systems, such as recent Sun Solaris kernels, the +dosynctodr variable is the only one that can be changed by the +tickadj program. In this and other modern kernels, it is not +necessary to change the other variables in any case.

      + +

      We have a report that says starting with Solaris 2.6 we should leave +dosynctodr alone.

      In order to maintain reasonable correctness +bounds, as well as reasonably good accuracy with acceptable polling +intervals, ntpd will complain if the frequency error is greater +than 500 PPM. For machines with a value of tick in the 10-ms range, +a change of one in the value of tick will change the frequency by +about 100 PPM. In order to determine the value of tick for a +particular CPU, disconnect the machine from all source s of time +(dosynctodr = 0) and record its actual time compared to an outside +source (eyeball-and-wristwatch will do) over a day or more. Multiply the +time change over the day by 0.116 and add or subtract the result to tick, +depending on whether the CPU is fast or slow. An example call to +tickadj useful on SunOS 4.1.1 is:

      +
      +     tickadj -t 9999 -a 5 -s
      +
      +which sets tick 100 PPM fast, tickadj to 5 microseconds and turns +off the clock/calendar chip fiddle. This line can be added to the rc.local configuration file to automatically set the kernel variables +at boot time.

      All this stuff about diddling kernel variables so the NTP +daemon will work is really silly. If vendors would ship machines with clocks +that kept reasonable time and would make their adjtime() system +call apply the slew it is given exactly, independent of the value of +tickadj, all this could go away. This is in fact the case on many +current Unix systems.

      + +

      Solaris 2.6

      +

      +Solaris 2.6 adds support for kernel PLL timekeeping, but breaks this +support in such a fashion that using it worse than not. This is SUN Bug ID 4095849, and it is not yet +fixed as of June 1998. +

      +

      Solaris 2.5 and 2.5.1

      +

      +On UltraSPARC systems, calculation of cpu_tick_freq is broken +such that values that are off by significant amounts may be used +instead. This unfortunately means that ntpd may have severe problems +keeping synchronization. This is SUN Bug ID +4023118. Bryan Cantrill of Sun +posted patchfreq, a workaround script, +to comp.protocols.time.ntp in March of 1997. +

      +


      +

      OLD DATA

      +I can't vouch for the accuracy the information below this +rule. It may be significantly dated or incorrect. +

      +

      +

      Solaris 2.2

      +

      +Solaris 2.2 and later contain completely re-written clock code to +provide high resolution microsecond timers. A benefit of the +re-written clock code is that adjtime does not round off its +adjustments, so ntp does not have to compensate for this +rounding. Under Solaris 2.2 and later, ntp #define's +ADJTIME_IS_ACCURATE, and does not look for the tickadj +kernel variable. +

      +

      Solaris 2.1

      +(This originally written by William L. Jones <jones@chpc.utexas.edu>) +

      +Solaris 2.1 contains fairly traditional clock code, with tick +and tickadj. +

      +Since settimeofday under Solaris 2.1 only sets the seconds part of timeval +care must be used in starting xntpd. I suggest the following start +up script: +

      +tickadj -s -a 1000 +
      ntpdate -v server1 server2 +
      sleep 20 +
      ntpdate -v server1 server2 +
      sleep 20 +
      tickadj -a 200 +
      xntpd +
      + +The first tickadj turns of the time of day clock and sets the tick +adjust value to 1 millisecond. This will insure that an adjtime value +of at most 2 seconds will complete in 20 seconds. +

      +The first ntpdate will set the time to within two seconds +using settimeofday or it will adjust time using adjtime. +

      +The first sleep insures the adjtime has completed for the first ntpdate. +

      +The second ntpdate will use adjtime to set the time of day since the +clock should be within 2 seconds of the correct time. +

      +The second tickadj set the tick adjust system value to 5 microseconds. +

      +The second sleeps insure that adjtime will complete before starting +the next xntpd. +

      +I tried running with a tickadj of 5 microseconds with out much success. +200 microseconds seems to work well. +

      +


      +Prior versions of this file had major text contributed by: + +
    • Denny Gentry <denny@eng.sun.com> +
    • + + diff --git a/contrib/ntp/html/build/hints/solaris.xtra.4023118 b/contrib/ntp/html/hints/solaris.xtra.4023118 similarity index 100% rename from contrib/ntp/html/build/hints/solaris.xtra.4023118 rename to contrib/ntp/html/hints/solaris.xtra.4023118 diff --git a/contrib/ntp/html/build/hints/solaris.xtra.4095849 b/contrib/ntp/html/hints/solaris.xtra.4095849 similarity index 100% rename from contrib/ntp/html/build/hints/solaris.xtra.4095849 rename to contrib/ntp/html/hints/solaris.xtra.4095849 diff --git a/contrib/ntp/html/build/hints/solaris.xtra.S99ntpd b/contrib/ntp/html/hints/solaris.xtra.S99ntpd similarity index 100% rename from contrib/ntp/html/build/hints/solaris.xtra.S99ntpd rename to contrib/ntp/html/hints/solaris.xtra.S99ntpd diff --git a/contrib/ntp/html/build/hints/solaris.xtra.patchfreq b/contrib/ntp/html/hints/solaris.xtra.patchfreq similarity index 100% rename from contrib/ntp/html/build/hints/solaris.xtra.patchfreq rename to contrib/ntp/html/hints/solaris.xtra.patchfreq diff --git a/contrib/ntp/html/build/hints/sun4 b/contrib/ntp/html/hints/sun4 similarity index 100% rename from contrib/ntp/html/build/hints/sun4 rename to contrib/ntp/html/hints/sun4 diff --git a/contrib/ntp/html/build/hints/svr4-dell b/contrib/ntp/html/hints/svr4-dell similarity index 100% rename from contrib/ntp/html/build/hints/svr4-dell rename to contrib/ntp/html/hints/svr4-dell diff --git a/contrib/ntp/html/build/hints/svr4_package b/contrib/ntp/html/hints/svr4_package similarity index 100% rename from contrib/ntp/html/build/hints/svr4_package rename to contrib/ntp/html/hints/svr4_package diff --git a/contrib/ntp/html/build/hints/todo b/contrib/ntp/html/hints/todo similarity index 100% rename from contrib/ntp/html/build/hints/todo rename to contrib/ntp/html/hints/todo diff --git a/contrib/ntp/html/hints/vxworks.html b/contrib/ntp/html/hints/vxworks.html new file mode 100644 index 000000000..eac9312f1 --- /dev/null +++ b/contrib/ntp/html/hints/vxworks.html @@ -0,0 +1,88 @@ + + + + + + + + vxWorks Port of NTP + + + + + +

      VxWorks port of NTP

      +

      Last update: + 21-Oct-2010 23:44 + UTC

      +

      Creating a port for vxWorks posed some problems. This port may help as a starting point for similar ports to real-time OS's and other embeddable kernels, particularly where main() is not allowed, and where the configure scripts need to be altered.

      +

      Configuration issues

      +

      I decided to do as little invasive surgery as possible on the NTP code, so I brought the vxWorks header tree in line with the standard Unix tree. The following changes were needed, as a side effect these changes will allow for easy porting of other autoconfigure enabled code.

      +

      Where I have 386 you will need to put in your target type. The vxWorks tree entry point is /usr/wind. If these are the same for your system, you should be able to cut and paste the changes.

      +

      WARNING: Check you are not overwriting files, before entering the following: there should be no conflict, but check first...

      +
      +            export CC="cc386 -nostdlib -m486 -DCPU=I80486 -I/usr/wind/target/h"
      +            export RANLIB=ranlib386
      +            export AR=ar386
      +            export VX_KERNEL=/usr/wind/target/config/ims_std_bsp/vxWorks
      + + cd /usr/wind/target/sys + ln -s ../signal.h + ln -s ../time.h + ln -s socket.h sockio.h + ln -s ../selectLib.h select.h + ln -s ../timers.h + touch file.h param.h resource.h utsname.h var.h ../netdb.h ../a.out.h ../termios.h + echo " ******ADD #include \"sys/times.h\" to sys/time.h " +
      + The configure script must be changed in the following way to get the linking tests to work, once in the correct directory issue the following commands: + +
            sed -e 's%main.*()%vxmain()%' configure > configure.vxnew
      +            mv configure.vxnew configure
      +            chmod 755 configure
      +      
      +

      The new version 4 of NTP requires some maths functions so it links in the maths library (-lm) in the ./ntpd/Makefile.am file change the line ntpd_LDADD = $(LDADD) -lm by removing the "-lm".

      +

      >You are now ready to compile +

      The ./configure.in file needed to be altered to allow for a host-target configuration to take place.

      +
        +
      • The define SYS_VXWORKS was added to the compilation flags. +
      • Little endianess is set if the target is of type iX86. +
      • The size of char, integer, long values are all set. If Wind River ever changes these values they will need to be updated. +
      • clock_settime() is defined to be used for setting the clock. +
      • The Linking flags have -r added to allow for relinking into the vxWorks kernel +
      +

      Unfortunately I have had to make use of the ./include/ntp_machine.h file to add in the checks that would have been checked at linking stage by autoconf, a better method should be devised.

      +
        +
      • There is now a NO_MAIN_ALLOWED define that simulates command line args, this allows the use of the normal startup sysntax. +
      • POSIX timers have been added. +
      • Structures normally found in netdb.h have been added with, the corresponding code is in ./libntp/machines.c. Where possible the defines for these have been kept non-vxWorks specific. +
      +

      Unfortunately there are still quite a few SYS_VXWORKS type defines in the source, but I have eliminated as many as possible. You have the choice of using the usrtime.a library avaliable from the vxworks archives or forgoing adjtime() and using the clock_[get|set]time(). The ./include/ntp_machine.h file clearly marks how to do this.

      +

      Compilation issues

      +

      You will need autoconf and automake ... available free from the gnu archives worldwide.

      +

      The variable arch is the target architecture (e.g. i486)

      +
      +            mkdir A.vxworks)
      +            cd A.vxworks
      +            ../configure --target=arch-wrs-vxworks
      +            make
      +       
      +

      Options I normally use are the --disable-all-clocks --enable-LOCAL-CLOCK flags. The program should proceed to compile without problem. The daemon ntpd, ntpdate, ntptrace, ntpdc, ntpq programs and of course the libraries are all fully ported. The other utilities are not, but they should be easy to port.

      +

      Running the software

      +

      Load in the various files, call them in the normal vxWorks function type manner. Here are some examples. Refer to the man pages for further information.

      +
      +            ld < ntpdate/ntpdate
      +            ld < ntpd/ntpd
      +            ld < ntptrace/ntptrace
      +            ld < ntpq/ntpq
      +            ld < ntpdc/ntpdc
      +            ntpdate ("-b", "192.168.0.245")
      +            sp(ntpd, "-c", "/export/home/casey/ntp/ntp.conf")
      +            ntpdc("-c", "monlist", "192.168.0.244")
      +            ntpq("-c", "peers", "192.168.0.244")
      +            ntptrace("192.168.0.244")
      +        
      +

      Casey Crellin, casey@csc.co.za

      + + + diff --git a/contrib/ntp/html/hints/winnt.html b/contrib/ntp/html/hints/winnt.html new file mode 100644 index 000000000..7c41b861b --- /dev/null +++ b/contrib/ntp/html/hints/winnt.html @@ -0,0 +1,90 @@ + + + + + + + + NTP on Windows NT + + + +

      NTP 4.x for Windows

      + +

      Introduction

      +

      The NTP 4 distribution runs as service on Windows 2000 and later. It will NOT run on Windows 95, 98, ME, etc. Lately it has been run the most on Windows-7 and later. The binaries work on multi-processor systems. This port has not been tested on the Alpha platform. This release now uses OpenSSL for authentication. IPv6 is not implemented yet for Win32 platforms. A ready-to-run install distribution is available from Meinberg at http://www.meinberg.de/english/sw/ntp.htm.

      +

      Users should note that the stock Windows client sends requests as mode-1 packets, which can have unintended consequences and create a security risk. The client should send requests as mode-3 (client) packets, which conform to the protocol specification. The issues and resolution are described in Microsoft KB 875424. A less desirable alternative that avoids changing registry keys is to use the --with-wintime option when building the executable.

      +

      Authentication Keys

      +

      With this release ntp-keygen is supported. See the ntp keygen documentation for details on how to use ntp-keygen.

      +

      ntpd can now use the generated keys in the same way as on Unix platforms. Please refer to the Authentication Options for details on how to use these.

      +

      NOTE: ntpd and ntp-keygen both use OpenSSL which requires a random + character file called .rnd by default. Both of these programs will automatically generate this file if they are not found. The programs will look for an environmental variable called RANDFILE and use that for the name of the random character file if the variable exists. If it does not exist it will look for an environmental variable called HOME and use that directory to search for a file called .rnd in that directory. Finally, if neither RANDFILE nor HOME exists it will look in C:\ for a .rnd file. In each case it will search for and create the file if the environmental variable exists or in the C:\ directory if it doesn't.

      +

      Note that ntpd normally runs as a service so that the only way that it will have either RANDFILE or HOME defined is if it is a System environmental variable or if the service is run under a specific account name and that account has one of those variables defined. Otherwise it will use the file c:\.rnd. This was done so that OpenSSL will work normally on Win32 systems. This obviates the need to ship the OpenSSL.exe file and explain how to generate the .rnd file. A future version may change this behavior.

      +

      Refer to Compiling Requirements and Instructions for how to compile the program.

      +

      Reference Clocks

      +

      Reference clock support under Windows NT is tricky because the IO functions are so much different. Some of the clock types have been built into the ntpd executable and should work but have not been tested by the ntp project. If you have a clock that runs on Win32 and the driver is there but not implemented on Win32 you will have make the required configuration changes in config.h and then build ntpd from source and test it. The following reference clock is known to work and is supported by Windows NT: Type 1 Undisciplined Local Clock (LOCAL)

      +

      Functions Supported

      +

      All NTP functions are supported with some constraints. See the TODO list below. Note that the ntptrace executable is not supported and you should use the PERL script version instead.

      +

      Accuracy

      +

      Greg Brackley has implemented a fantastic interpolation scheme that improves the precision of the NTP clock using a realtime thread (is that poetic or what!) which captures a tick count from the 8253 counter after each OS tick. The count is used to interpolate the time between operating system ticks.

      +

      On a typical 200+ MHz system NTP achieves a precision of about 5 microseconds and synchronizes the clock to +/-500 microseconds using the Trimble Palisade as UTC reference. This allows distributed applications to use the 10 milliseconds ticks available to them with high confidence.

      +

      Binaries

      +

      Recent InstallShield based executable versions of NTP for Windows NT (intel) are available from:

      + +

      ToDo

      +

      These tasks are in no particular order of priority.

      +
        +
      • Add IPv6 support +
      • See if precision can be improved by using CPU cycle counter for tick interpolation. +
      • Make precision time available to applications using NTP_GETTIME API +
      +

      Compiling Requirements

      +
        +
      • Windows 7 or Windows.NET Server 2003, or later. +
      • Windows NT 4.0 Windows 2000, Windows XP or Windows Vista may still work. +
      • Microsoft Visual C++ 2008, 2010, or 2013 EE +
      • Some way of uncompressing and untarring the gzipped tar file. +
      • OpenSSL must be built on the box before building NTP. Additional steps would + be required to not use OpenSSL. +
      • Microsoft Visual C++ redistributables
      + Compiling Instructions +
        +
      1. Install Micosoft Visual C++ redistributables +
      2. Install OpenSSL full installer for Windows. Add the following to your system environment variables in the control panel (adjusting paths as appropriate to point to the directory containing only an openssl subdirectory, for OPENSSL_INC, and to the directory containing openssl .lib files for OPENSSL_LIB: +
        • OPENSSL_INC=C:\OpenSSL\include +
        • OPENSSL_LIB=C:\OpenSSL\lib
        +
      3. Unpack the NTP-4.x.tar.gz using utilities such as WinZip or WinRar. +
      4. Run Microsoft Visual C++ 2008 EE. +
      5. Open the ports\winnt\vs2008\ntp.sln solution file +
      6. Batch build all projects (Build menu, Batch Build..., select all, build). +
      7. The built binaries can be found in the ports\winnt\v2008\Win32-bin\Release directory. +
      8. If you are shipping binaries in a kit it is strongly recommended that you ship this file (winnt.html) along with the binaries. +
      +

      Configuration File

      +

      The default NTP configuration file path is %SystemRoot%\system32\drivers\etc\. (%SystemRoot% is an environmental variable that can be determined by typing "set" at the "Command Prompt" or from the "System" icon in the "Control Panel").

      +

      Refer to your system environment and create your ntp.conf file in the directory corresponding to your system  installation. The older <WINDIR>\ntp.conf is still supported but you will get a log entry reporting that the first file wasn't found. +

      Installation Instructions

      +

      The instsrv program in the instsrv subdirectory of the distribution can be used to install 'ntpd' as a service and start automatically at boot time. Instsrv is automatically compiled with the rest of the distribution if you followed the steps above.

      +
        +
      1. Start a command prompt and enter "instsrv.exe <pathname_for_ntpd.exe>" +
      2. Clicking on the "Services" icon in the "Control Panel" will display the list of currently installed services in a dialog box. The NetworkTimeProtocol service should show up in this list. Select it in the list and hit the "Start" button in the dialog box. The NTP service should start. +
      3. You can also stop and start the service by typing net start|stop NetworkTimeProtocol at the DOS prompt. +
      4. View the event log by clicking on the "Event Viewer" icon in the "Administrative Tools" group, there should be several successful startup messages from NTP. NTP will keep running and restart automatically when the machine is rebooted. +
      +

      You can change the start mode (automatic/manual) and other startup parameters corresponding to the NTP service in the "Services" dialog box if you wish.

      +

      Removing NTP

      +

      You can also use instsrv to delete the NTP service by entering: >"instsrv.exe remove" +

      Command Line Parameters and Registry Entries

      +

      Unlike the Unix environment, there is no clean way to run 'ntpdate' and reset the clock before starting 'ntpd' at boot time. NTP will step the clock up to 1000 seconds by default. While there is no reason that the system clock should be that much off during bootup if ntpd was running before, you may wish to override this default and/or pass other command line directives. +

      Use the registry editor to edit the value for the ntpd executable under LocalMachine\System\CurrentControlSet\Services\NTP.

      +

      Add the -g option to the ImagePath key, behind "%INSTALLDIR>\ntpd.exe". This will force NTP to accept large time errors (including 1.1.1980 00:00)

      +

      Bug Reports

      +

      Please follow the NTP Bug Reporting Procedures to report bugs or request enhancements.

      +

      Last update: + 6-Apr-2014 23:27 +

      + + + diff --git a/contrib/ntp/html/history.html b/contrib/ntp/html/history.html new file mode 100644 index 000000000..8b1ad5041 --- /dev/null +++ b/contrib/ntp/html/history.html @@ -0,0 +1,74 @@ + + + + + +Historical Notes + + + +

      Historical Notes

      +

      Last update: + 10-Mar-2014 05:07 + UTC

      +
      +

      Historical Notes on NTP Upgrades

      +

      This is an interim report on recent upgrades to the NTPv4 reference implementation code base and documentation. This report documents the upgrade program, which began in June 2007 and continued until March 2008. It is very important to recognize that this historic document describes the upgrade status as of 2008. Additional upgrades have been implemented since then. As of mid 2011, the additional upgrades are documented on the NTP Version 4 Release Notes page.

      +

      The motivation for this project was the overhaul and refinement of the code, some of which dates back twenty years. Some four dozen sets of fingers have introduced sometimes incompatible "improvements" that to some degree enhance or burden the product. There has been a continuing effort over the years to maintain the briar patch and pluck the more flagrant weeds, but it now requires a more systematic and thorough examination of purpose, design and implementation. The project is not complete, but far enough along to present a status report and review of significant changes.

      +

      Please note THE CHANGES DO NOT AFFECT THE PROTOCOL SPECIFICATION AND DO NOT AFFECT INTEROPERABILITY WITH PREVIOUS VERSIONS.

      +

      1. Transparent Design

      +

      During the project a number of minor inconsistencies in various algorithms were found and resolved. In most cases this did not result in any changes in behavior, just a more simplified, transparent and easier to maintain design. In a few cases behavior has been modified to correct deficiencies and to avoid hostile attacks, as described below.

      +

      2. Documentation

      +

      The documentation required a major upgrade. Many pages have been overhauled, some completely rewritten and new ones added. A site map has been added and sorted by page category. A comprehensive command index has been added and sorted by page category. The command index includes a brief gloss for each command. A page has been added to show the various status word and event decodes used for monitoring and event reporting. The decodes show the internal code, ASCII report and short function gloss.

      +

      New pages have been added on association management, automatic server discovery and rate management. Much of the overburden on the program manual and configuration pages has been moved to these pages with the intent of the original pages to contain primarily a functional description for the commands and command line options. This is still an ongoing process.

      +

      3. Bulletproofing

      +

      In a continuing mission the code flow has been carefully adjusted to decrease vulnerability to configuration errors and possibly hostile attack. The order of restriction processing was adjusted to deflect access denials as early as possible and without consuming useless processor cycles. This is especially important in rate defense, as the MRU list should only be used for clients that could be legitimately served. In addition, the Autokey protocol was adjusted to avoid some potentially nasty disruption attacks.

      +

      4. Rate Management

      +

      Strict rate controls have been refined in both outbound and inbound traffic for both minimum headway (guard time) and minimum average headway. This is a major improvement over the original limitreject design of 1992 and upgrade circa 2003. Headway violations result in an optional kiss-o'-death (KoD) packet. To avoid a clogging vulnerability, the KoD packets are themselves rate controlled for each source address separately.

      +

      The main feature of the revised design is that it is responsive to the server minimum headway and avoids guessing. This is done by setting the ppoll field in the server packet to the maximum of (a) the ppoll field in the client packet and (b) the server headway. The client sets the ppoll field in the association to the maximum of (a) the ppoll field in the server packet and (b) the minpoll field in the association. If this is a KoD and this value is greater than minpoll, minpoll is set to this value. The result is that the client continues sending, but only at headway at least as large as the server.

      +

      The revised design makes possible a decrease in the minimum time constant/poll interval to 3 (8 s), which reduces the risetime to 250 s. This may be useful for rapid convergence when a client is first started, but should not be used for links with moderate to large jitter. This is done using the average option of the discard command, which sets the minimum poll interval and headway from the default 4 (16 s) to a value in the range 3 (8 s) to 6 (64 s). Larger values than 4 might be appropriate for very busy public servers.

      +

      Rate management applies also to Autokey messages. This fixes a problem when iburst and autokey are both in play and when for some reason an association with iburst is repeatedly restarted. This may appear spooky to some folks that frequently restart a client for testing. The server remembers. Further information is in the current web documentation.

      +

      5. Frequency File

      +

      Initial frequency training has always been a problem, as it can take a very long time to trim the frequency estimate to nominal values. Once this happens and the frequency file is written, subsequent reboots will restore the frequency and frequency training is avoided. The problem is exacerbated using toll modem services such as ACTS which make a call at each poll interval. Until the training is complete the poll interval is held below the desired maximum as toll charges accrue.

      +

      The problem was solved by changing the clock state machine so that, if no frequency file is available, an initial training interval of 300 s occurs, after which the frequency is directly calculated and the discipline then turned over to the feedback loop. The choice of 300 s is based on the assumption that time can be estimated within 1 ms and the resulting frequency estimate within nominal 1 PPM.

      +

      Note that once the initial time offset is either stepped or slewed, no further time offsets are amortized during the training period. If the frequency error is large, the time offset at the end of the period can be moderately large, which then must be amortized by the feedback loop. While this may take up to an hour and result in a minor frequency tweak, the behavior is very much better than without the initial training. The remedy would require intricate and fragile code revisions.

      +

      In the original design the frequency file was written at one-hour intervals. This apparently makes embedded systems folks nervous, since this can tire the flash NVRAM after several years. The interval between writes now depends on the ambient clock stability and normally maxes out at something over one day unless the frequency takes an unusual twitch.

      +

      6. Leapseconds

      +

      The leapsecond processing has been overhauled once again. The problem is to avoid fake leap warnings displayed by an errant server and to insure correct response in case of large time changes which might validate or invalidate arming for a subsequent leap. No leap information is used unless the client is synchronized to a proventic source. The values obtained from an Autokey server or peer are updated if newer than the current values. Server leap warning bits are disregarded if these values are available. If not, and if either a majority of the servers show leap warning bits or if one or more of the survivors are a reference clock with leap warning bit, the leap is armed. If armed by server leap warning bits and these provisions no longer prevail, the leap is disarmed. The NTPv4 protocol specifically does not speak to this issue.

      +

      The leap armed condition is displayed in the host status word. Transitions between warnings and no warnings are reported to the protostats file, system log and traps.

      +

      7. Orphan Mode and Local Clock Driver

      +

      The orphan mode code has been overhauled to correct some minor bugs and to clarify operation under normal and recovery conditions. The requirement that all subnet hosts have orphan configuration has been removed. The only requirement is that the orphan clients on the DMZ network sharing the root server(s) be so configured The scheme now works if the root servers are configured with each other, either in symmetric or broadcast modes. Orphan mode is not considered in the NTPv4 protocol specification.

      +

      The local clock driver can be very dangerous when used as a fallback when connectivity to Internet time servers is interrupted. Orphan mode was designed to reduce the need for the local clock driver, as it is active only if no server is available. The local clock driver has been modified to have the same characteristics, regardless of stratum. Only if the host running the local clock driver loses all servers, regardless of stratum, is the driver activated. Thus, it is possible, but not recommended, to run the driver at any stratum, including zero.

      +

      8. Poll Rate Control

      +

      One of the most persistent problems is when after long operation and then a failure and then subsequently recovery, a client can take a long time to refresh the clock filter and resynchronize. Once the client has backed off the poll interval after a lengthy outage, it sends polls at that interval until receiving a response. At that time it temporarily retries at the minimum poll interval to fill up the clock filter. If iburst is configured, this will happen after 10 seconds or so and the client then resumes its poll interval required by the discipline time constant. This avoids needless network traffic while the poll interval increases gradually to the maximum. Further information is in the current web documentation.

      +

      The same thing happens on initial startup or when an association is restarted. The intent is to avoid a blast of iburst packets unless the server actually responds to the first one and to retry only while responding to the the rate controls.

      +

      In order to speed response to initial startup when a reference clock is available, the clock is set on the first message received from the driver. This exposed an interesting bug, now fixed, with the ACTS modem driver, which began prematurely to ramp up the poll interval.

      +

      9. Autokey

      +

      The management of host and group names with respect to Autokey configuration and key generation has been removed and simplified. On host certificates, the subject and issuer fields carry the group name, while other certificates carry the host name, which can be an arbitrary string having nothing to do with the DNS name. This opens up a possible future plan to use the Autokey name rather than the IP address when constructing the session key. It also allows a client to easily switch from one group to another without regenerating the certificate. Further information is in the current web documentation and in the latest Autokey ID.

      +

      Various protocol refinements have been done in the Autokey state machine. A bug was found in symmetric modes where the peer cookies were not EXORed. A bug was found in processing the certificate cache when a participant was a client of two or more server in the same group which themselves had certificate trails to different trusted hosts.

      +

      The protocol machine is now restarted every several days in order to update certificates and leapseconds values when they are changed.

      +

      10. Report, Log and Event Codes

      +

      The status, selection, source, event and log decodes have been adjusted for consistency. Some of the decodes were missing, some with errors and a few new ones added. Old versions of ntpq continue to work without change, but display a new code as space. Except for the new codes, this behavior is consistent with RFC 1305 and proposed for the NTPv4 protocol specification.

      +

      The ntpq as command has been changed to fix some very old bugs. The display is now consistent with the system and peer billboards. The authentication state is correctly displayed for broadcast server associations.

      +

      The event reporting has been cleaned up for more straightforward interpretation by a remote agent. All significant state transitions are reported, including clock state machine changes, mobilization, /demobilization, system and peer restart, system peer change, panic stop and so forth.

      +

      A new protostats monitoring file facility has been added. It works just like the other monitor files. All events are recorded to this file as reported and optionally to the system log. Many reports that sometimes clog up the system log are more usefully directed to this file. The reports also trigger a trap packet that can be sent via an agent to page an administrator.

      +

      When the current mode-6 monitoring protocol was designed circa 1988 the considered intent was that monitoring functions rely only on the NTP packet itself and the system, peer and clock status words provided in the mode-6 packet. While the strongly felt advice at that time was to avoid reformatting the plain ASCII text sent by the server, at various times folks have cheated and reformatted the text. In some places this is good, like displaying the filter shift register; in some places this is bad, like reformatting the timestamps. There is nothing much that can be done about this now without angry mobs rioting when forced to upgrade to a new ntpq. I will not rule this out in future.

      +

      A more serious comment has to do with using other than the NTP packet, status words and events for monitoring purposes. Emphasis added: monitors should not parse such things as the flash codes, clock state or anything else not called out in the NTPv4 specification. The clock state machine is defined in the specification, but no specific numbers are assigned to the states.

      +

      When the numbers were changed to align for reporting purposes, some scripts no longer worked. The scripts should be changed to use only the leap and select fields of the system status word. If the leap field is other than 0, the client has synchronized at least once; if the select field is other than 0, the client is currently synchronized to the source indicated in the decode.

      +

      11. Two-step and timestamp capture

      +

      A number of interesting ideas were found in the IEEE 1588 Precision Time Protocol specification. One of them was the two-step protocol in which the transmit timestamp is sent in a following message. However, the PTP design operates only in a master-slave configuration and is not directly usable in NTP. The protocol was adapted to the NTP symmetric design, which requires four state variables rather than two. It is described on Timestamp Capture Principles. This might be an interesting project for future research.

      +

      A detailed study of the timestamp capture opportunities for both hardware and software timestamping revealed that the most accurate and interoperable design involves the transmit timestamp at the beginning of the packet and then receive timestamp at the end. This makes it possible to accurately measure the offset and delay even if the ends of the synchronization path operate at different rates. It is described on the Timestamp Capture Principles page.

      +

      12. Windows client bug

      +

      The Windows XP and Vista clients send the NTP request in symmetric active mode rather than client mode. An unsuspecting server could mobilize a symmetric passive association, which is a serious security vulnerability. The NTPv4 servers, including those at NIST and USNO, discard symmetric active requests unless cryptographically authenticated, so Windows clients do not work. The Microsoft KB 875424 discusses the preferred workaround; however, an optional workaround is now available so that, if the request is not authenticated, the server responds with symmetric passive mode, but without mobilize an association. The workaround is enabled with the WINTIME build option.

      +

      The spec assumes that either peer in symmetric modes can synchronize the other should a peer lose all sources. The workaround violates that assumption and some legitimate configuration might be badly misused. It should be used only with this understanding.

      +

      13. Autonomous configuration

      +

      The autonomous configuration (pool and manycast) code was refined to more reliably prune excess servers. If a truechimer is discarded by the clustering algorithm and the total number of survivors is greater than the maxclock option of the tos command, it is considered excess and shows a "#" tally code. If the association is ephemeral and survives the clustering algorithm, the watchdog counter is reset. If the watchdog timer expires and the total number of associations is greater than the maxclock option of the tos command, it is demobilized. This behavior is not considered in the NTPv4 protocol specification.

      +

      14. Code ornamentation

      +

      When auditing the code and figuring out its historic origin and evolution, additional commentary has been added so future generations can figure it out, too.

      +

      David L. Mills
      + 17 March 2008
      +

      +
      +

      + + diff --git a/contrib/ntp/html/howto.html b/contrib/ntp/html/howto.html index 3a1007fd8..e89fa788e 100644 --- a/contrib/ntp/html/howto.html +++ b/contrib/ntp/html/howto.html @@ -1,109 +1,109 @@ - - - - - - How to Write a Reference Clock Driver - - - - -

      How to Write a Reference Clock Driver

      - giffrom Pogo, Walt Kelly -

      You need a little magic.

      -

      Last update: 18:39 UTC Thursday, July 28, 2005

      -
      -

      Related Links

      - -

      Table of Contents

      - -
      -

      Description

      -

      NTP reference clock support maintains the fiction that the clock is actually an ordinary peer in the NTP tradition, but operating at a synthetic stratum of zero. The entire suite of algorithms used to filter the received data, select the best clocks or peers and combine them to produce a system clock correction operate just like ordinary NTP peers. In this way, defective clocks can be detected and removed from the peer population. As no packets are exchanged with a reference clock; however, the transmit, receive and packet procedures are replaced with separate code to simulate them.

      -

      It is important to understand how the NTP clock driver interface works. The driver assumes three timescales: standard time maintained by a distant laboratory such as USNO or NIST, reference time maintained by the external radio and the system time maintained by NTP. The radio synchronizes reference time and frequency to standard time via radio, satellite or modem. As the transmission means may not always be reliable, most radios continue to provide clock updates for some time after signal loss using an internal reference oscillator. In such cases the radio may or may not reveal the time since last synchronized and/or the estimated time error.

      -

      All three timescales run only in Coordinated Universal Time (UTC), 24-hour format, and are not adjusted for local timezone or standard/daylight time. The local timezone, standard/daylight indicator and year, if provided, are ignored. However, it is important to determine whether a leap second is to be inserted in the UTC timescale in the near future so NTP can insert it in the system timescale at the appropriate epoch.

      -

      The NTP clock driver synchronizes the system time and frequency to the radio via serial or parallel port, PPS signal or other means. The driver routinely checks the radio timecode string or status indicators to determine whether it is operating correctly or not. If it is, the driver decodes the radio timecode in days, hours, minutes, seconds and nanoseconds and provides these data with the NTP receive timestamp corresponding to the on-time epoch of the timecode. The driver interface computes the difference between the timecode time and NTP timestamp and saves the difference in a circular buffer for later processing. Once each poll interval, usually 64 s, the driver provides ancillary data including leap bits and last reference time to the interface. The interface processes the circular buffer using a median/trimmed mean algorithm to extract the best estimate and provides this and the ancillary data to the clock filter as with ordinary NTP peers.

      -

      The audio drivers are designed to look like a typical external radio in that the reference oscillator is derived from the audio codec oscillator and separate from the system clock oscillator. In the WWV and IRIG drivers, the codec oscillator is disciplined in frequency to the standard timescale via radio or local sources and can be assumed to have the same reliability and accuracy as an external radio. In these cases the driver continues to provide updates to the clock filter even if the WWV or IRIG signals are lost. However, the interface is provided the last reference time when the signals were received and increases the dispersion as expected with an ordinary peer.

      -

      The best way to understand how the clock drivers work is to study the ntp_refclock.c module and one of the drivers already implemented, such as refclock_wwvb.c. Routines refclock_transmit() and refclock_receive() maintain the peer variables in a state analogous to a network peer and pass received data on through the clock filters. Routines refclock_peer() and refclock_unpeer() initialize and terminate reference clock associations, should this ever be necessary. A set of utility routines is included to open serial devices, process sample data, edit input lines to extract embedded timestamps and to perform various debugging functions.

      -

      The main interface used by these routines is the refclockproc structure, which contains for most drivers the decimal equivalents of the year, day, month, hour, second and nanosecond decoded from the radio timecode. Additional information includes the receive timestamp, reference timestamp, exception reports, statistics tallies, etc. The support routines are passed a pointer to the peer structure, which is used for all peer-specific processing and contains a pointer to the refclockproc structure, which in turn contains a pointer to the unit structure, if used. For legacy purposes, a table typeunit[type][unit] contains the peer structure pointer for each configured clock type and unit. This structure should not be used for new implementations.

      -

      The reference clock interface supports auxiliary functions to support in-stream timestamping, pulse-per-second (PPS) interfacing and precision time kernel support. In most cases the drivers do not need to be aware of them, since they are detected at autoconfigure time and loaded automatically when the device is opened. These include the tty_clk STREAMS module and ppsapi PPS interface described in the Line Disciplines and Streams Modules page. The tty_clk module reduces latency errors due to the operating system and serial port code in slower systems. The ppsapi PPS interface replaces the ppsclock STREAMS module and is expected to become the IETF standard cross-platform interface for PPS signals. In either case, the PPS signal can be connected via a level converter/pulse generator described in the Pulse-per-second (PPS) Signal Interfacing page.

      -

      Radio and modem reference clocks by convention have addresses in the form 127.127.t.u, where t is the clock type and u in the range 0-3 is used to distinguish multiple instances of clocks of the same type. Most clocks require a serial or parallel port or special bus peripheral. The particular device is normally specified by adding a soft link /dev/devicedd to the particular hardware device involved, where d corresponds to the unit number.

      -

      By convention, reference clock drivers are named in the form refclock_xxxx.c, where xxxx is a unique string. Each driver is assigned a unique type number, long-form driver name, short-form driver name and device name. The existing assignments are in the Reference Clock Drivers page and its dependencies. All drivers supported by the particular hardware and operating system are automatically detected in the autoconfigure phase and conditionally compiled. They are configured when the daemon is started according to the configuration file, as described in the Configuration Options page.

      -

      The standard clock driver interface includes a set of common support routines some of which do such things as start and stop the device, open the serial port, and establish special functions such as PPS signal support. Other routines read and write data to the device and process time values. Most drivers need only a little customizing code to, for instance, transform idiosyncratic timecode formats to standard form, poll the device as necessary, and handle exception conditions. A standard interface is available for remote debugging and monitoring programs, such as ntpq and ntpdc, as well as the filegen facility, which can be used to record device status on a continuous basis.

      -

      The general organization of a typical clock driver includes a receive-interrupt routine to read a timecode from the I/O buffer and convert to internal format, generally in days, hours, minutes, seconds and fraction. Some timecode formats include provisions for leap-second warning and determine the clock hardware and software health. The interrupt routine then calls refclock_process() with these data and the timestamp captured at the on-time character of the timecode. This routine saves each sample as received in a circular buffer, which can store from a few up to 60 samples, in cases where the timecodes arrive one per second.

      -

      The refclock_transmit() routine in the interface is called by the system at intervals defined by the poll interval in the peer structure, generally 64 s. This routine in turn calls the transmit poll routine in the driver. In the intended design, the driver calls the refclock_receive() to process the offset samples that have accumulated since the last poll and produce the final offset and variance. The samples are processed by recursively discarding median outlyers until about 60 percent of samples remain, then averaging the surviving samples. When a reference clock must be explicitly polled to produce a timecode, the driver can reset the poll interval so that the poll routine is called a specified number of times at 1-s intervals.

      -

      The interface code and this documentation have been developed over some time and required not a little hard work converting old drivers, etc. Should you find success writing a driver for a new radio or modem service, please consider contributing it to the common good. Send the driver file itself and patches for the other files to Dave Mills (mills@udel.edu).

      -

      Conventions, Fudge Factors and Flags

      -

      Most drivers support manual or automatic calibration for systematic offset bias using values encoded in the fudge configuration command. By convention, the time1 value defines the calibration offset in seconds. For those drivers that support statistics collection using the filegen utility and the clockstats file, the flag4 switch enables the utility. When a PPS signal is available, a special automatic calibration facility is provided. If the flag1 switch is set and the PPS signal is actively disciplining the system time, the calibration value is automatically adjusted to maintain a residual offset of zero. Should the PPS signal or the prefer peer fail, the adjustment is frozen and the remaining drivers continue to discipline the system clock with a minimum of residual error.

      -

      Files Which Need to be Changed

      -

      A new reference clock implementation needs to supply, in addition to the driver itself, several changes to existing files.

      -
      -
      ./include/ntp.h -
      The reference clock type defines are used in many places. Each driver is assigned a unique type number. Unused numbers are clearly marked in the list. A unique REFCLK_xxxx identification code should be recorded in the list opposite its assigned type number. -
      ./libntp/clocktypes.c -
      The ./libntp/clktype array is used by certain display functions. A unique short-form name of the driver should be entered together with its assigned identification code. -
      ./ntpd/ntp_control.c -
      The clocktypes array is used for certain control message displays functions. It should be initialized with the reference clock class assigned to the driver, as per the NTP specification RFC-1305. See the ./include/ntp_control.h header file for the assigned classes. -
      ./ntpd/refclock_conf.c -
      This file contains a list of external structure definitions which are conditionally defined. A new set of entries should be installed similar to those already in the table. The refclock_conf array is a set of pointers to transfer vectors in the individual drivers. The external name of the transfer vector should be initialized in correspondence with the type number. -
      ./configure.in -
      This is a configuration file used by the autoconfigure scheme. Add lines similar to the following: -
      -  AC_MSG_CHECKING(FOO clock_description)
      -  AC_ARG_ENABLE(FOO,
      -      AC_HELP_STRING([--enable-FOO], [x clock_description]),
      -      [ntp_ok=$enableval], [ntp_ok=$ntp_eac])
      -  if test "$ntp_ok" = "yes"; then
      -      ntp_refclock=yes
      -      AC_DEFINE(CLOCK_FOO, 1, [Foo clock?])
      -  fi
      -  AC_MSG_RESULT($ntp_ok)
      -
      -
      (Note that $ntp_eac is the value from --{dis,en}able-all-clocks for non-PARSE clocks and $ntp_eacp is the value from --{dis,en}able-parse-clocks for PARSE clocks. See the documentation on the autoconf and automake tools from the GNU distributions.) -
      ./ntpd/Makefile.am -
      This is the makefile prototype used by the autoconfigure scheme. Add the driver file name to the entries already in the ntpd_SOURCES list. -
      Do the following sequence of commands: -
      -  autoreconf
      -  configure
      -
      -
      or simply run make, which will do this command sequence automatically. -
      -

      Interface Routine Overview

      -
      -
      refclock_newpeer - initialize and start a reference clock -
      This routine allocates and initializes the interface structure which supports a reference clock in the form of an ordinary NTP peer. A driver-specific support routine completes the initialization, if used. Default peer variables which identify the clock and establish its reference ID and stratum are set here. It returns one if success and zero if the clock address is invalid or already running, insufficient resources are available or the driver declares a bum rap. -
      refclock_unpeer - shut down a clock -
      This routine is used to shut down a clock and return its resources to the system. -
      refclock_transmit - simulate the transmit procedure -
      This routine implements the NTP transmit procedure for a reference clock. This provides a mechanism to call the driver at the NTP poll interval, as well as provides a reachability mechanism to detect a broken radio or other madness. -
      refclock_sample - process a pile of samples from the clock -
      This routine converts the timecode in the form days, hours, minutes, seconds, milliseconds/microseconds to internal timestamp format. It then calculates the difference from the receive timestamp and assembles the samples in a shift register. It implements a recursive median filter to suppress spikes in the data, as well as determine a rough dispersion estimate. A configuration constant time adjustment fudgetime1 can be added to the final offset to compensate for various systematic errors. The routine returns one if success and zero if failure due to invalid timecode data or very noisy offsets. -
      Note that no provision is included for the year, as provided by some (but not all) radio clocks. Ordinarily, the year is implicit in the Unix file system and hardware/software clock support, so this is ordinarily not a problem. Nevertheless, the absence of the year should be considered more a bug than a feature and may be supported in future. -
      refclock_receive - simulate the receive and packet procedures -
      This routine simulates the NTP receive and packet procedures for a reference clock. This provides a mechanism in which the ordinary NTP filter, selection and combining algorithms can be used to suppress misbehaving radios and to mitigate between them when more than one is available for backup. -
      refclock_gtlin - groom next input line and extract timestamp -
      This routine processes the timecode received from the clock and removes the parity bit and control characters. If a timestamp is present in the timecode, as produced by the tty_clk line discipline/streams module, it returns that as the timestamp; otherwise, it returns the buffer timestamp. The routine return code is the number of characters in the line. -
      refclock_open - open serial port for reference clock -
      This routine opens a serial port for I/O and sets default options. It returns the file descriptor if success and zero if failure. -
      refclock_ioctl - set serial port control functions -
      This routine attempts to hide the internal, system-specific details of serial ports. It can handle POSIX (termios), SYSV (termio) and BSD (sgtty) interfaces with varying degrees of success. The routine sets up the tty_clk, chu_clk and ppsclock streams module/line discipline, if compiled in the daemon and requested in the call. The routine returns one if success and zero if failure. -
      refclock_control - set and/or return clock values -
      This routine is used mainly for debugging. It returns designated values from the interface structure that can be displayed using ntpdc and the clockstat command. It can also be used to initialize configuration variables, such as fudgetimes, fudgevalues, reference ID and stratum. -
      refclock_buginfo - return debugging info -
      This routine is used mainly for debugging. It returns designated values from the interface structure that can be displayed using ntpdc and the clkbug command. -
      -
      -
      - gif
      -
      - - - - \ No newline at end of file + + + +How to Write a Reference Clock Driver + + + +

      How to Write a Reference Clock Driver

      +giffrom Pogo, Walt Kelly +

      You need a little magic.

      +

      Last update: + 10-Mar-2014 05:08 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      Description

      +

      NTP reference clock support maintains the fiction that the clock is actually an ordinary server in the NTP tradition, but operating at a synthetic stratum of zero. The entire suite of algorithms filter the received data and select the best sources to correct the system clock. No packets are exchanged with a reference clock; however, the transmit, receive and packet procedures are replaced with code to simulate them.

      +

      The driver assumes three timescales: standard time maintained by a distant laboratory such as USNO or NIST, reference time maintained by the external radio and the system time maintained by NTP. The radio synchronizes reference time via radio, satellite or modem. As the transmission means may not always be reliable, most radios continue to provide clock updates for some time after signal loss using an internal reference oscillator. In such cases the radio may or may not reveal the time since last synchronized or the estimated time error.

      +

      All three timescales run only in Coordinated Universal Time (UTC) and are not adjusted for local timezone or standard/daylight time. The local timezone, standard/daylight indicator and year, if provided, are ignored. However, it is important to determine whether a leap second is to be inserted in the UTC timescale in the near future so NTP can insert it in the system timescale at the appropriate epoch.

      +

      The interface routines in the ntp_refclock.c source file call the following driver routines via a transfer vector:

      +
      +
      startup
      +
      The association has just been mobilized. The driver may allocate a private structure and open the device(s) required.
      +
      shutdown
      +
      The association is about to be demobilized. The driver should close all device(s) and free private structures.
      +
      receive
      +
      A timecode string is ready for retrieval using the refclock_gtlin() or refclock_gtraw() routines and provide clock updates.
      +
      poll
      +
      Called at poll timeout, by default 64 s. Ordinarily, the driver will send a poll sequence to the radio as required.
      +
      timer
      +
      Called once per second. This can be used for housekeeping functions. In the case with pulse-per-second (PPS) signals, this can be used to process the signals and provide clock updates.
      +
      +

      The receive routine retrieves a timecode string via serial or parallel port, PPS signal or other means. It decodes the timecode in days, hours, minutes, seconds and nanoseconds and checks for errors. It provides these data along with the on-time timestamp to the refclock_process routine, which saves the computed offset in a 60-sample circular buffer. On occasion, either by timeout, sample count or call to the poll routine, the driver calls refclock_receive to process the circular buffer samples and update the system clock.

      +

      The best way to understand how the clock drivers work is to study one of the drivers already implemented, such as refclock_wwvb.c. The main interface is the refclockproc structure, which contains for most drivers the decoded timecode, on-time timestamp, reference timestamp, exception reports and statistics tallies, etc. The support routines are passed a pointer to the peer structure, which contains a pointer to the refclockproc structure, which in turn contains a pointer to the unit structure, if used. For legacy purposes, a table typeunit[type][unit] contains the peer structure pointer for each configured clock type and unit. This structure should not be used for new implementations.

      +

      Radio and modem reference clocks by convention have addresses of the form 127.127.t.u, where t is the clock type and u in the range 0-3 is used to distinguish multiple instances of clocks of the same type. Most clocks require a serial or parallel port or special bus peripheral. The particular device is normally specified by adding a soft link /dev/deviceu to the particular hardware device.

      +

      By convention, reference clock drivers are named in the form refclock_xxxx.c, where xxxx is a unique string. Each driver is assigned a unique type number, long-form driver name, short-form driver name and device name. The existing assignments are in the Reference Clock Drivers page and its dependencies. All drivers supported by the particular hardware and operating system are automatically detected in the autoconfigure phase and conditionally compiled.

      +

      Conventions, Fudge Factors and Flags

      +

      Most drivers support manual or automatic calibration for systematic offset bias using values encoded in the fudge configuration command. By convention, the time1 value defines the calibration offset in seconds. For those drivers that support statistics collection using the filegen utility and the clockstats file, the flag4 switch enables the utility.

      +

      If the calibration feature has been enabled, the flag1 switch is set and the PPS signal is actively disciplining the system time, the time1 value is automatically adjusted to maintain a residual offset of zero. Once the its value has stabilized, the value can be inserted in the configuration file and the calibration feature disabled.

      +

      Files Which Need to be Changed

      +

      When a new reference clock driver is installed, the following files need to be edited. Note that changes are also necessary to properly integrate the driver in the configuration and makefile scripts, but these are decidedly beyond the scope of this page.

      +
      +
      ./include/ntp.h
      +
      The reference clock type defines are used in many places. Each driver is assigned a unique type number. Unused numbers are clearly marked in the list. A unique REFCLK_xxxx identification code should be recorded in the list opposite its assigned type number.
      +
      ./libntp/clocktypes.c
      +
      The ./libntp/clktype array is used by certain display functions. A unique short-form name of the driver should be entered together with its assigned identification code.
      +
      ./ntpd/ntp_control.c
      +
      The clocktypes array is used for certain control message displays functions. It should be initialized with the reference clock class assigned to the driver, as per the NTP specification RFC-1305. See the ./include/ntp_control.h header file for the assigned classes.
      +
      ./ntpd/refclock_conf.c
      +
      This file contains a list of external structure definitions which are conditionally defined. A new set of entries should be installed similar to those already in the table. The refclock_conf array is a set of pointers to transfer vectors in the individual drivers. The external name of the transfer vector should be initialized in correspondence with the type number.
      +
      +

      Interface Routine Overview

      +
      +
      refclock_newpeer - initialize and start a reference clock.
      +
      This routine allocates and initializes the interface structure which supports a reference clock in the form of an ordinary NTP peer. A driver-specific support routine completes the initialization, if used. Default peer variables which identify the clock and establish its reference ID and stratum are set here. It returns one if success and zero if the clock address is invalid or already running, insufficient resources are available or the driver declares a bum rap.
      +
      refclock_unpeer - shut down a clock
      +
      This routine is used to shut down a clock and return its resources to the system.
      +
      refclock_transmit - simulate the transmit procedure
      +
      This routine implements the NTP transmit procedure for a reference clock. This provides a mechanism to call the driver at the NTP poll interval, as well as provides a reachability mechanism to detect a broken radio or other madness.
      +
      refclock_process - insert a sample in the circular buffer
      +
      This routine saves the offset computed from the on-time timestamp and the days, hours, minutes, seconds and nanoseconds in the circular buffer. Note that no provision is included for the year, as provided by some (but not all) radio clocks. Ordinarily, the year is implicit in the Unix file system and hardware/software clock support, so this is ordinarily not a problem.
      +
      refclock_receive - simulate the receive and packet procedures
      +
      This routine simulates the NTP receive and packet procedures for a reference clock. This provides a mechanism in which the ordinary NTP filter, selection and combining algorithms can be used to suppress misbehaving radios and to mitigate between them when more than one is available for backup.
      +
      refclock_gtraw, refclock_gtlin - read the buffer and on-time timestamp
      +
      These routines return the data received from the clock and the on-time timestamp. The refclock_gtraw routine returns a batch of one or more characters returned by the Unix terminal routines in raw mode. The refclock_gtlin routine removes the parity bit and control characters and returns all the characters up to and including the line terminator. Either routine returns the number of characters delivered.
      +
      refclock_open - open a serial port for reference clock
      +
      This routine opens a serial port for I/O and sets default options. It returns the file descriptor if success and zero if failure.
      +
      refclock_ioctl - set serial port control functions
      +
      This routine attempts to hide the internal, system-specific details of serial ports. It can handle POSIX (termios), SYSV (termio) and BSD (sgtty) interfaces with varying degrees of success. The routine returns one if success and zero if failure.
      +
      refclock_ppsapi
      +
      This routine initializes the Pulse-per-Second interface (see below).
      +
      refclock_pps
      +
      This routine is called once per second to read the latest PPS offset and save it in the circular buffer (see below).
      +
      +

      Pulse-per-Second Interface

      +

      When the Pulse-per-Second Application Interface (RFC 2783) is present, a + compact PPS interface is available to all drivers. See the Mitigation + Rules and the Prefer Peer page for further information. To use this interface, + include the timeppps.h and refclock_atom.h header files + and define the refclock_atom structure in the driver private storage. + The timepps.h file is specific to each operating system and may not + be available for some systems.

      +

      To use the interface, call refclock_ppsapi from the startup routine + passing the device file descriptor and refclock_atom structure pointer. + Then, call refclock_pps from the timer routine passing the association + pointer and refclock_atom structure pointer. See the refclock_atom.c file + for examples and calling sequences. If the PPS signal is valid, the offset + sample will be save in the circular buffer and a bit set in the association + flags word indicating the sample is valid and the driver an be selected as + a PPS peer. If this bit is set when the poll routine is called, the driver + calls the refclock_receive routine to process the samples in the + circular buffer and update the system clock.

      +
      +
      gif
      +
      + + + diff --git a/contrib/ntp/html/huffpuff.html b/contrib/ntp/html/huffpuff.html new file mode 100644 index 000000000..2be4d4a9b --- /dev/null +++ b/contrib/ntp/html/huffpuff.html @@ -0,0 +1,31 @@ + + + + + +The Huff-n'-Puff Filter + + + +

      The Huff-n'-Puff Filter

      +

      Last update: + 10-Mar-2014 05:09 + UTC

      +
      +

      In scenarios where a considerable amount of data are downloaded or uploaded using DSL or telephone modem lines, timekeeping quality can be seriously degraded. This occurs because the traffic volume, and thus the queuing delays, on the upload and download directions of transmission can be very different. In many cases the apparent time errors are so large as to exceed the step threshold and a step correction can occur during and after the data transfer.

      +

      The huff-n'-puff filter is designed to correct the apparent time offset in these cases. It depends on knowledge of the propagation delay when no other traffic is present, such as during other than work hours. The filter remembers the minimum delay over the most recent interval measured usually in hours. Under conditions of large delay, the filter corrects the apparent offset using the sign of the offset and the difference between the apparent delay and minimum delay. The name of the filter reflects the negative (huff) and positive (puff) correction, which depends on the sign of the offset. The filter is activated by the tinker huffpuff command, as described in the Miscellaneous Options page.

      +
      +
      gif +

      Figure 1. Huff-n'-Puff Wedge Scattergram

      +
      +

      Figure 1 shows how the huff-n'-puff filter works. Recall from the Clock Filter Algorithm page that the wedge scattergram plots sample points (x, y) corresponding to the measured delay and offset, and that the limb lines are at slope ±0.5. Note in the figure that the samples are clustered close to the upper limb line, representing heavy traffic in the download direction. The apparent offset y0 is near zero at the minimum delay x0, which is near 0.1s. Thus, for a point (x, y), the true offset is

      +
      +

      θ = y - (x - x0) / 2 for y > y0 at or near the upper limb line or
      + θ = y + (x - x0) / 2 for y < y0 at or near the lower limb line.

      +
      +

      In either case the associated delay is δ = x.

      +

      In the interior of the wedge scattergram far from the limb lines, the corrections are less effective and can lead to significant errors if the area between the limb lines is heavily populated.

      +
      +

      + + diff --git a/contrib/ntp/html/icons/sitemap.png b/contrib/ntp/html/icons/sitemap.png new file mode 100644 index 0000000000000000000000000000000000000000..17c7c55177e4fb1782b65cdadfa5d32cbbc30279 GIT binary patch literal 2825 zcmV+k3-Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D02y>eSaefwW^{L9 za%BKeVQFr3E>1;MAa*k@H7+4+_}gGrBHP zh$&ushADr1=-%Gm>o;%T;aFB@mr81`evu&UN49<$g-y4h?s|mEfj>iY^%J_^g|cl2 z^*wVi^$mWNsc0Q%@%7>UJnb9L3_?j?S=+pwxO{VQqieDHN!w}>N-D}w*0znJw(H<3 z))1lG1V?oPk?L*4R_;L2@esFnN3pV7h|NFfF|*MRbMN#PD^VZuOaS*EKB(@UGk(>$ zkOAXzHfray(6UqxUFQu17c3w|x{OfyD#D952;v5~>Mi6n?qFxvf|>gQEIblnc`qGX zj}4fZn@4VGcjx~FpcTKm^WcuLb6)?XZZ;i;nKbC8(@-^&fttB2bS<=_esCU%Wh)4l zE+MpV1>r^O1aKX^%57}izKx}wS}biZV`I0%3UK|g5)b|~i|%2|RlRBKmp=$WiC@~e zceloPP5yOhcOn#>d{mAnqkTj56u>Zd1;)i<^vq5pQN0YG_*QswYLTSbK>5`zWYpe5 zMb8$@;}5a^P>+S(eFZiiOK@|y?`v6QkNyXfk6YFq+a{VmubvVhBA$)Bh8SFX(1iXi zEi{uU&`mK4q@!t}6bl>oz!uLSD0hywVbKb}DA2O7jp))XOsw9*)SX1@7A!v!(yIScI>bYoIvlFOc=TK^N7-l+wBxC$pO&M=(un4vMevGe z5OC!hSUDE3Z2+ON6@5UPLZ^sb;A2%MEq3Pd+uGmnW;rTGL?m-3RHktV6cY%{9ENZDDEu?WtpI^y0?6A} zAcO#T>J6C3R&nEgFV^nW;@<88`1*Sg);vV#>>la{Zo!$QY^I#gSpn!Ksko{ixKLMJXI_P|Tf42E^Qy@Ooi4ia>9HQh(wMi=JpPNG0F_=s}8#Uy^og{}NlW1NDnuMh?8;gAwQ zVRs}<<9dk8#&C%W%Pp=A?(qb`@3sPXrw~BuF#OWT_5pIH!Iszns1q1~@H`8&y<3>S zy^6t=X|%6bp!Iqo`e(+z;!B!BnB=bP#2Ta(_M)nznW{VyN~-q4t|;gS3n0^u;bNo- z7h}wDJpdpDJcauJJ`BKt0tCQ1q(G|Lg3kFaw5}DQejyhP%MzH@@-cMXgk-6?j!7<0 zm36@*LWfXc16q3K(bm6+!D|*YjTz88)enKR7w5SqT!?OlYiujrc^&Xb?1rbH58laF z_W{160Chs%Jjyzk&|pzOKSiD~n}xdhY&0xM(7UOHy1wTVCV98Cd>ChZm9Y0z;IwxM zKJ+WY#fU2KB^^jB?nZs*6xhO6gr;{QI;Rh;_y(kxj3S|E7@kSJRsdfS12DS31=&+z zQ7h`m>uatRKr@j7kvtmJGnts*>p=Tj32Hj}pV&DCDrSl`qd4Iz#YuNLP7#1T1K?W< zhk#1BaSTux2BB~3BztY339FH-OGm?SEmX!yc<{Sy3Jj0}L$n1<4NM?_0P<><&@tPD z@-YD<)p1aD3t?WBW8_X9%!60Iv2$iC7i8swIDS44CoUG?1NTClx>StQUMedT$utzEby(ImVYcX@ zolLcwRpWdf+Q$ZA=SV9rq~yoWigEm0F5YJV+z7y<$O=%T?|{sdip&}guGA3#IiJ`V zhXQjF%6nwc_9;<6TtyW;3a)r~AAnlX&(?~J7jR^=C^l`NX?Tr1UsK&`J{jh%4##j zwLGNiLu~+z0+9p|O$rb|(>?%G1F6bUxF492trdM!ZDz!{q0I|2bnEcv*WO{0y9My{ z2;f%W9f$ON0GAvbKP$oe7xED)szsSujTCM0A%KYQ0OV8h`hix2XY^1jGG^3abwf|a zjF?U!fc-*bI$;{(s%5xxDyyvyM_&7Bl)!+aj_G*&%(no?&Pj0EgI2HWLRMAuA%HMz z4P=o5+~gosb`_&#WE$tmj4niz88Kc!Zury-7&A&^%xDapf*E9#PX5b@rC=X;dvXY0 zkB?l%cg~3J<%lP@;;#YRQoM0WXa#u3A?+yuS5OUI zTRD=-E<;!mh!hP0=t7Wb;KDrAhM3G&IJ2wZ5?X_^;q^GrIRwCK-v^*VjLfG)rD_h; zVc(u=3;@Xx%Mlp9boH0v4SNP4g%n7`JEVX|unH{$?cl5ZYyhMH0hG1LQBpMmr@%^@ zPz$G^Zvp;S0e?|HvMOfCIV&E1=RCKq{&hOt?uz9daQ2Xp0s_2wngBjZgT1Q+Lz5Q7 zt90KNf%f?6AZ9xfpUs{-dZjkE<#bSSkTRW*eWk%@Ve3HiZS zDW>u-hN(Y`Pos(4a}EKdqD0#VX>B?ZRDR%>_#s2hN2c5ezc?-I88`G%!@<8CX96{F zV(Z~d03V0d!6T;G+W$gX{}Y!WRq2nu#YRR(J{OsA#oj%k<&J^g&*^6oIii_(WIWB-ydOm(ps-AK3sL3BWC~9%+hEL}j+%Qn*~li_=_;x1a?#@j-C43z+jjf>Z7?ICv{? zK8TXW)F7IwUnuQ{H~pOP2)dFK6&3X=#jk1JpHq&X(DlX8(9jp`=;nFmfj;~x4S0>> zEqXpm@jk@|tcavYudv)E@2K+6+3|XCga+#S7VtAoNX%+NQnnfVEHijn&ETdQ!QvbK z?Zquw3=9`aLOAiBG{;Gb6BNg2?zbs^OZUH^c*%~>=QGJ)=5RQ_q3gT0!5`Aqf#M8> zqb;1gLNWv{ESbeAQ2q%?`Q^c{RJ#AdIk51~Id*;>ZJ8g9cRKVvW)5a9X3kR-@6keE br+DSRN0fz1Ty_B>00000NkvXXu0mjf5Dh9d literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/index.html b/contrib/ntp/html/index.html index 5c1931317..d40983796 100644 --- a/contrib/ntp/html/index.html +++ b/contrib/ntp/html/index.html @@ -1,101 +1,73 @@ - - - - - - The Network Time Protocol (NTP) Distribution - - - - -

      The Network Time Protocol (NTP) Distribution

      - gifP.T. Bridgeport Bear; from Pogo, Walt Kelly -

      Pleased to meet you.

      -

      Last update: 18:39 UTC Thursday, July 28, 2005

      -
      -

      Related Links

      - -
      -

      Table of Contents

      - -
      -

      Introduction

      -

      Note: The software contained in this distribution is available without charge under the conditions set forth in the Copyright Notice.

      -

      The Network Time Protocol (NTP) is used to synchronize the time of a computer client or server to another server or reference time source, such as a radio or satellite receiver or modem. It provides accuracies typically within a millisecond on LANs and up to a few tens of milliseconds on WANs relative to Coordinated Universal Time (UTC) via a Global Positioning Service (GPS) receiver, for example. Typical NTP configurations utilize multiple redundant servers and diverse network paths in order to achieve high accuracy and reliability.

      -

      This software release implements NTP Version 4 (NTPv4), but is in general backwards compatible with previous versions except NTP Version 1, support for which is no longer viable. NTPv4 includes support for both symmetric key and public key cryptography to prevent accidental or malicious protocol attacks, as well as automatic server discovery using IP multicast means. This release includes full support for the IPv6 address family, where the operating system supports it, as well as the default IPv4 address family. Either or both families can be used at the same time on the same machine.

      -

      Background information on computer network time synchronization can be found on the Executive Summary - Computer Network Time Synchronization page. Discussion on protocol conformance issues and interoperability with previous NTP versions can be found on the Protocol Conformance Statement page. Discussion on how NTP reckons the time can be found on the NTP Timescale and Leap Seconds page. Background information, bibliography and briefing slides suitable for presentations can be found on the Network Time Synchronization Project page. Additional information can be found at the NTP web site www.ntp.org. Please send bug reports to <bugs@mail.ntp.org>.

      -

      Building and Installing NTP

      -

      NTP supports Unix and Windows (XP, NT4 and 2000) systems. The Building and Installing the Distribution page presents an overview of the procedures for compiling the distribution and installing it on a typical client or server. The build procedures inspect the system hardware and software environment and automatically select the appropriate options for that environment. While these procedures work with most computers and operating systems marketed today, exceptions requiring manual intervention do exist, as documented on the Configuration Options and Release Notes pages.

      -

      Bringing up a NTP primary server requires a radio or satellite receiver or modem. The distribution includes hardware drivers for some forty radio and satellite clocks and modem services. A list of supported drivers is given on the Reference Clock Drivers page. It is also possible to use an otherwise undisciplined machine as a primary or backup server, as described on the Undisciplined Local Clock page. For most popular workstations marketed by Sun, Silicon Graphics and Hewlett Packard, as well as widely available Unix clones such as FreeBSD and Linux, the automatic build procedures select all drivers that run on the target machine. While this increases the size of the executable binary somewhat, individual drivers can be included or excluded using the configure utility documented in the Configuration Options page.

      -

      Some programs included in this distribution use cryptographic algorithms to verify authenticity and credentials. Where local security policy permits relatively weak symmetric key cryptography, the required software is included in this distribution. However, where local policy requires stronger public key cryptography, additional software not in this distribution is required. This distribution uses the OpenSSL library available from http://www.openssl.org. This library is also used by the Secure Shell facility, so is often already installed on Unix workstations and servers. It includes support for most message digest and digital signature algorithms used in the industry, as well as X.509 certificate generation, signing and verification.

      -

      While public key cryptography is optional but highly recommended for all NTP operations, it is required for the NTPv4 Autokey protocol described on the Autonomous Authentication page and is an integral component of the generic automatic configuration scheme described on the Autonomous Configuration page. In addition, access can be restricted in various ways described on the Access Control Options page.

      -

      Configuring Clients and Servers

      -

      NTP is by its very nature a complex distributed network application and can be configured and used for a great many widely divergent timekeeping scenarios. The documentation presented on these pages attempts to cover the entire suite of configuration, operation and maintenance facilities which this distribution supports. However, most applications will need only a few of these facilities. If this is the case, the Quick Start page may be useful to get a simple workstation on the air with an existing server.

      -

      However, in order to participate in the existing NTP synchronization subnet and obtain accurate, reliable time, it is usually necessary to construct an appropriate configuration file, commonly called ntp.conf, which establishes the servers and/or external receivers or modems to be used by this particular machine. Directions for constructing this file are in the Notes on Configuring NTP and Setting up a NTP Subnet page. However, in many common cases involving simple network topologies and workstations, the configuration data can be specified entirely on the command line for the ntpd - Network Time Protocol (NTP) daemon.

      -

      The most important factor in providing accurate, reliable time is the selection of modes and servers to be used in the configuration file. A discussion on the available modes is on the Association Management page. NTP support for one or more computers is normally engineered as part of the existing public NTP synchronization subnet. The public subnet consists of a multiply redundant hierarchy of servers and clients, with each level in the hierarchy identified by stratum number. Primary servers operate at stratum one and provide synchronization to secondary servers operating at stratum two and so on to higher strata. In this hierarchy, clients are simply servers that have no dependents.

      -

      Configuring a corporate or campus NTP subnet can be an engineering challenge. NTP contains many features designed to survive system and network failures, software bugs, clock errors and hacker attacks. Surviving these hazards requires intricate design of the timekeeping network using good principles of server redundancy and path diversity. The Manycast mode, new to NTPv4, is designed to track the current server and network states and adjust the client/server configuration for the best available accuracy and reliability. More information on the Manycast mode is on the Athentication Options and Automatic NTP Configuration Options pages.

      -

      The NTP subnet in early 2003 includes well over a hundred public primary (stratum 1) servers synchronized directly to UTC by radio, satellite or modem and located in every continent of the globe, including Antarctica. Normally, client workstations and servers with a relatively small number of clients do not synchronize to primary servers. There are well over a hundred public secondary (stratum 2) servers synchronized to the primary servers and providing synchronization to a total well over 100,000 clients and servers in the Internet. The current lists are maintained on the Information on Time and Frequency Services page, which is updated frequently. There are thousands upon thousands of private primary and secondary servers not normally available to the public, many hiding behind firewalls. Clients are strongly discouraged against using these servers, since they sometimes hide in little ghettos behind dinky links to the outside world and unwanted traffic can bring up expensive ISDN lines, causing much grief and frustration. There are defensive means described on the Access Control Options page, including the Kiss-of-Death packet.

      -

      Resolving Problems

      -

      Like other things Internet, the NTP synchronization subnets tend to be large and devilishly intricate, with many opportunities for misconfiguration and network problems. The NTP engineering model is specifically designed to help isolate and repair such problems using an integrated management protocol, together with a suite of monitoring and debugging tools. There is an optional statistics data recording facility which can be used to record normal and aberrant operation, log problems to the system log facility, and retain records of client access. The NTP Debugging Techniques and Hints and Kinks pages contain useful information for identifying problems and devising solutions. In extreme cases, problems can be detected through the use of the ntpdsim - Network Time Protocol (NTP) simulator included in this software distribution.

      -

      Users are requested to report bugs, offer suggestions and contribute additions to this distribution. The Patching Procedures page suggests procedures which greatly simplify distribution updates, while the Porting Hints page suggest ways to make porting this code to new hardware and operating systems easier. Additional information on reference clock driver construction and debugging can be found in the Debugging Hints for Reference Clock Drivers page.

      -

      Program Manual Pages

      - -

      Supporting Documentation

      - -

      Background Information

      - -

      Application Notes

      - -
      -
      - gif
      -
      - - - - \ No newline at end of file + + + +The Network Time Protocol (NTP) Distribution + + + +

      The Network Time Protocol (NTP) Distribution

      +gifP.T. Bridgeport Bear; from Pogo, Walt Kelly +

      Pleased to meet you.

      +

      Last update: + 31-Mar-2014 05:41 +

      +
      +

      Related Links

      +
        +
      • A list of all links is on the Site Map page.
      • +
      +

      Table of Contents

      + +
      +

      Introduction

      +

      Note: The NTP Version 4 software contained in this distribution is available without charge under the conditions set forth in the Copyright Notice.

      +
      +
      It is very important that readers understand that the NTP document collection began 25 years ago and remains today a work in progress. It has evolved as new features were invented and old features retired. It has been widely copied, cached and morphed to other formats, including man pages, with varying loss of fidelity. However, these HTML pages are the ONLY authoritative and definitive reference. Readers should always use the collection that comes with the distribution they use. A copy of the online collection at www.ntp.org is normally included in the most recent snapshot, but might not agree with an earlier snapshot or release version.
      +
      +

      This distribution is an implementation of RFC-5905 "Network Time Protocol Version 4: Protocol and Algorithms Specification".
      + NTP is widely used to synchronize a computer to Internet time servers or other sources, such as a radio or satellite receiver or telephone modem service. It can also be used as a server for dependent clients. It provides accuracies typically less than a millisecond on LANs and up to a few milliseconds on WANs. Typical NTP configurations utilize multiple redundant servers and diverse network paths in order to achieve high accuracy and reliability.

      +

      This distribution includes a simulation framework in which substantially all the runtime NTP operations and most features can be tested and evaluated. This has been very useful in exploring in vitro response to unusual circumstances or over time periods impractical in vivo. Details are on the Network Time Protocol (NTP) Simulator page.

      +

      The Handbook

      +

      A good deal of tutorial and directive information is available on the handbook pages. These should be read in conjunction with the command and option information available on the pages listed on the sitemap page.

      +
      +
      NTP Version 4 Release Notes
      +
      Lists recent changes and new features in the current distribution.
      +
      Association Management
      +
      Describes how to configure servers and peers and manage the various options. Includes automatic server discovery schemes.
      +
      Automatic Server Discovery Schemes
      +
      Describes automatic server discovery using broadcast, multicast, manycast and server pool scheme.
      +
      Access Control Support
      +
      Describes the access control mechanisms that can be used to limit client access to various time and management functions.
      +
      Authentication Support
      +
      Describes the authentication mechanisms for symmetric-key and public-key cryptography.
      +
      Rate Management
      +
      Describes the principles of rate management to minimize network load and defend against DoS attacks.
      +
       
      +
      Reference Clock Support
      +
      Describes the collection of radio clocks used to synchronize primary servers.
      +
      How NTP Works
      +
      Gives an overview of the NTP daemon architecture and how it works.
      +
      +

      Building and Installing NTP

      +

      NTP supports Unix, VMS and Windows (2000 and later) systems. The Building and Installing the Distribution page details the procedures for building and installing on a typical system. This distribution includes drivers for many radio and satellite receivers and telephone modem services in the US, Canada and Europe. A list of supported drivers is on the Reference Clock Drivers page. The default build includes the debugging options and all drivers that run on the target machine; however, options and drivers can be included or excluded using options on the Configuration Options page.

      +

      Resolving Problems

      +

      Like other things in modern Internet life, NTP problems can be devilishly intricate. This distribution includes a number of utilities designed to identify and repair problems using an integrated management protocol supported by the ntpq utility program.

      +

      The NTP Debugging Techniques and Hints and Kinks pages contain useful information for identifying problems and devising solutions. Additional information on reference clock driver construction and debugging is in the Debugging Hints for Reference Clock Drivers page.

      +

      Users are invited to report bugs and offer suggestions via the NTP Bug Reporting Procedures page.

      +

      Further Information

      +

      The Site Map page contains a list of document collections arranged by topic. The Program Manual Pages collection may be the best place to start. The Command Index collection contains a list of all configuration file commands together with a short function description. A great wealth of additional information is available via the External Links collection, including a book and numerous background papers and briefing presentations.

      +

      Background information on computer network time synchronization is on the Executive Summary - Computer Network Time Synchronization page. Discussion on new features and interoperability with previous NTP versions is on the NTP Version 4 Release Notes page. Background information, bibliography and briefing slides suitable for presentations are on the Network Time Synchronization Research Project page. Additional information is at the NTP web site www.ntp.org.

      +
      +
      gif
      +
      + + + diff --git a/contrib/ntp/html/kern.html b/contrib/ntp/html/kern.html index cc23504cc..b1660451b 100644 --- a/contrib/ntp/html/kern.html +++ b/contrib/ntp/html/kern.html @@ -1,34 +1,32 @@ - - - - - - Kernel Model for Precision Timekeeping - - - - -

      Kernel Model for Precision Timekeeping

      -

      gif from Pogo, Walt Kelly

      -

      Alice touched the kernel and it exploded.

      -

      Last update: 18:40 UTC Thursday, July 28, 2005

      -
      -

      Related Links

      - -
      -

      The technical report [2], which is a major revision and update of RFC-1589 [3], describes an engineering model for a precision time-of-day function for a generic operating system. The model is based on the principles of disciplined oscillators using phase-lock loops (PLL) and frequency-lock loops (FLL) often found in the engineering literature. The model uses a hybrid PLL/FLL discipline algorithm implemented in the kernel. The algorithm, which is very similar to the algorithm implemented in the NTP daemon, provides automatic time and frequency steering with update intervals from a few seconds to tens of minutes.

      -

      The hybrid PLL/FLL code described in [2] is included in Solaris and Digital/Compaq/HP Tru64. It includes two system calls ntp_gettime() and ntp_adjtime() and can discipline the system clock with microsecond resolution. However, newer hardware and kernels with the same system calls can discipline the clock with nanosecond resolution. The new code described in [1] is available for Linux, FreeBSD, SunOS and Tru64; however, only the Linux and FreeBSD implementations, which do not include licensed code, are readily available. The software and documentation, including a simulator used to verify correct behavior, but not involving licensed code, is available at nanokernel.tar.gz.

      -

      The model also changes the way the system clock is adjusted in time and frequency relative to an external precision timing source, such as described in the Pulse-per-second (PPS) Signal Interfacing page. The NTP software daemon uses the PPS to provide synchronization limited in principle only by the accuracy and stability of the external timing source.

      -

      References

      -
        -
      1. Mills, D.L., and P.-H. Kamp. The nanokernel. Proc. Precision Time and Time Interval (PTTI) Applications and Planning Meeting (Reston VA, November 2000). Paper: PostScript | PDF, Slides: HTML | PostScript | PDF | PowerPoint -
      2. Mills, D.L. Unix kernel modifications for precision time synchronization. Electrical Engineering Department Report 94-10-1, University of Delaware, October 1994, 24 pp. Abstract: PostScript | PDF, Body: PostScript | PDF -
      3. Mills, D.L. A kernel model for precision timekeeping. Network Working Group Report RFC-1589, University of Delaware, March 1994. 31 pp. ASCII -
      -
      - - - - \ No newline at end of file + + + +Kernel Model for Precision Timekeeping + + + +

      Kernel Model for Precision Timekeeping

      +

      gif from Pogo, Walt Kelly

      +

      Alice finds the kernel a house of cards.

      +

      Last update: + 10-Mar-2014 05:10 + UTC

      +
      +

      Related Links

      + +
      +

      The technical report [2], which is a revision and update of an earlier report [3], describes an engineering model for a precision clock discipline function for a generic operating system. The model is the same hybrid phase/frequecy-lock feedback loop used by ntpd, but implemented in the kernel. The code described in [2] is included in Solaris and Digital/Compaq/HP Tru64. It provides two system calls ntp_gettime() and ntp_adjtime() and can discipline the system clock with microsecond resolution. However, newer hardware and kernels with the same system calls can discipline the clock with nanosecond resolution. The new code described in [1] is in FreeBSD, Linux and Tru64. The software and documentation, including a simulator used to verify correct behavior, but not involving licensed code, is available in the nanokernel.tar.gz distribution

      +

      Ordinarily, the kernel clock discipline function is used with the NTP daemon, but could be used for other purposes. The ntptime utility program can be used to control it manually.

      +

      The kernel model also provides support for an external precision timing source, such as described in the Pulse-per-second (PPS) Signal Interfacing page. The new system calls are used by the PPSAPI interface and in turn by the PPS Clock Discipline driver (type 22) to provide synchronization limited in principle only by the accuracy and stability of the external timing source. Typical results with the PPS signal from a GPS receiver and a modern computer are in the 3 μs range.

      +

      References

      +
        +
      1. Mills, D.L., and P.-H. Kamp. The nanokernel. Proc. Precision Time and Time Interval (PTTI) Applications and Planning Meeting (Reston VA, November 2000). Paper: PostScript | PDF, Slides: HTML | PostScript | PDF | PowerPoint
      2. +
      3. Mills, D.L. Unix kernel modifications for precision time synchronization. Electrical Engineering Department Report 94-10-1, University of Delaware, October 1994, 24 pp. Abstract: PostScript | PDF, Body: PostScript | PDF
      4. +
      5. Mills, D.L. A kernel model for precision timekeeping. Network Working Group Report RFC-1589, University of Delaware, March 1994. 31 pp. ASCII
      6. +
      +
      + + + diff --git a/contrib/ntp/html/kernpps.html b/contrib/ntp/html/kernpps.html new file mode 100644 index 000000000..b7536bd65 --- /dev/null +++ b/contrib/ntp/html/kernpps.html @@ -0,0 +1,49 @@ + + + + +PPSAPI Interface for Precision Time Signals + + + +

      PPSAPI Interface for Precision Time Signals

      +giffrom NBS Special Publication 432, 1979 (out of print) +

      Last update: + 10-Mar-2014 05:10 + UTC

      +
      +

      Related Links

      +

      + +
      +

      +
      +

      Introduction

      +

      RFC-2783 describes the PPSAPI application programming interface for external precision time signals, such as the pulse-per-second (PPS) signal generated by some radio clocks and cesium oscillators. The PPSAPI provides a generic capability in the ubiquitous Unix kernel which can be used for a wide variety of measurement applications, including network time synchronization and related experiments. The hardware to do this requires only a serial port and a modem control lead, such as the data carrier detect (DCD) lead, which can be driven by an external source via a level converter/pulse generator such as described on the Pulse-per-second (PPS) Signal Interfacing page. In some systems a parallel port can be used for the same purpose.

      +

      The PPSAPI interface defined in RFC-2783 is the only PPS interface supported in NTP Version 4. The PPSAPI is supported in stock FreeBSD and, with the addition of the PPSkit kernel module, in Linux.

      +

      The special header file /usr/include/sys/timepps.h implements the PPSAPI using whatever primitives are available in each archeticture and operating system. It obsoletes previous APIs based on the tty_clock and ppsclock line disciplines and streams modules, which are no longer supported.

      +

      The PPS Clock Discipline driver (type 22) uses the PPSAPI in conjunction with a local radio clock or remote NTP server as a reference clock. The driver can also use the PPSAPI as an interface directly to the kernel PPS facility as described on the Kernel Model for Precision Timekeeping page.

      +

      PPSAPI Application Program Interface

      +

      The PPSAPI interface provides the following functions:

      +
      +
      time_pps_create
      +
      Creates a PPS interface instance and returns a handle to it.
      +
      time_pps_destroy
      +
      Destroys a PPS interface and returns the resources used.
      +
      time_pps_setparams
      +
      Sets the parameters associated with a PPS interface instance, including offsets to be automatically added to captured timestamps.
      +
      time_pps_getparams
      +
      Returns the parameters associated with a PPS interface instance. +
      time_pps_getcap
      +
      Returns the capabilities of the current interface and kernel implementation.
      +
      time_pps_fetch
      +
      Returns the current timestamps associated with a PPS interface instance in either nanoseconds and nanoseconds (Unix timespec) or seconds and fraction (NTP) format.
      +
      time_pps_kcbind
      +
      If kernel PPS processing is supported, this binds the support to the associated PPS interface instance.
      +
      +

      The entire PPS interface functionality is currently provided by inline code in the timepps.h header file. While not all implementations support the full PPSAPI specification, they do support all the functions required for the PPS driver described next. The FreeBSD, Linux and Solaris implementations can be used with the stock kernels provided with those systems; however, the Tru64 and SunOS kernels require additional functions not provided in the stock kernels. Solaris users are cautioned that these functions operate improperly in Solaris versions prior to 2.8 with patch Generic_108528-02. Header files for other systems can be found via the web at nanokernel.tar.gz.

      +
      +
      + + + diff --git a/contrib/ntp/html/keygen.html b/contrib/ntp/html/keygen.html index 7953eb1c3..191b7147b 100644 --- a/contrib/ntp/html/keygen.html +++ b/contrib/ntp/html/keygen.html @@ -1,116 +1,116 @@ - - - - - - ntp-keygen - generate public and private keys - - - - -

      ntp-keygen - generate public and private keys

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      Alice holds the key.

      -

      Last update: 22:32 UTC Monday, November 07, 2005

      -
      -

      Related Links

      - -

      Table of Contents

      - -
      -

      Synopsis

      -

      ntp-keygen [ -deGgHIMnPT ] [ -c [RSA-MD2 | RSA-MD5 | RSA-SHA | RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ] ] [ -i name ] [ -p password ] [ -S [ RSA | DSA ] ] [ -s name ] [ -v nkeys ]

      -

      Description

      -

      This program generates cryptographic data files used by the NTPv4 authentication and identification schemes. It generates MD5 key files used in symmetric key cryptography. In addition, if the OpenSSL software library has been installed, it generates keys, certificate and identity files used in public key cryptography. These files are used for cookie encryption, digital signature and challenge/response identification algorithms compatible with the Internet standard security infrastructure.

      -

      By default, files are not encrypted by ntp-keygen. The -p password option specifies the write password and -q password option the read password for previously encrypted files. The ntp-keygen program prompts for the password if it reads an encrypted file and the password is missing or incorrect. If an encrypted file is read successfully and no write password is specified, the read password is used as the write password by default.

      -

      The ntpd configuration command crypto pw password specifies the read password for previously encrypted files. The daemon expires on the spot if the password is missing or incorrect. For convenience, if a file has been previously encrypted, the default read password is the name of the host running the program. If the previous write password is specified as the host name, these files can be read by that host with no explicit password.

      -

      All files are in PEM-encoded printable ASCII format, so they can be embedded as MIME attachments in mail to other sites and certificate authorities. File names begin with the prefix ntpkey_ and end with the postfix _hostname.filestamp, where hostname is usually the string returned by the Unix gethostname() routine, and filestamp is the NTP seconds when the file was generated, in decimal digits. This both guarantees uniqueness and simplifies maintenance procedures, since all files can be quickly removed by a rm ntpkey* command or all files generated at a specific time can be removed by a rm *filestamp command. To further reduce the risk of misconfiguration, the first two lines of a file contain the file name and generation date and time as comments.

      -

      All files are installed by default in the keys directory /usr/local/etc, which is normally in a shared filesystem in NFS-mounted networks. The actual location of the keys directory and each file can be overridden by configuration commands, but this is not recommended. Normally, the files for each host are generated by that host and used only by that host, although exceptions exist as noted later on this page.

      -

      Normally, files containing private values, including the host key, sign key and identification parameters, are permitted root read/write-only; while others containing public values are permitted world readable. Alternatively, files containing private values can be encrypted and these files permitted world readable, which simplifies maintenance in shared file systems. Since uniqueness is insured by the hostname and file name extensions, the files for a NFS server and dependent clients can all be installed in the same shared directory.

      -

      The recommended practice is to keep the file name extensions when installing a file and to install a soft link from the generic names specified elsewhere on this page to the generated files. This allows new file generations to be activated simply by changing the link. If a link is present, ntpd follows it to the file name to extract the filestamp. If a link is not present, ntpd extracts the filestamp from the file itself. This allows clients to verify that the file and generation times are always current. The ntp-keygen program uses the same extension for all files generated at one time, so each generation is distinct and can be readily recognized in monitoring data.

      -

      Running the program

      -

      The safest way to run the ntp-keygen program is logged in directly as root. The recommended procedure is change to the keys directory, usually /ust/local/etc, then run the program. When run for the first time, or if all ntpkey files have been removed, the program generates a RSA host key file and matching RSA-MD5 certificate file, which is all that is necessary in many cases. The program also generates soft links from the generic names to the respective files. If run again, the program uses the same host key file, but generates a new certificate file and link.

      -

      The host key is used to encrypt the cookie when required and so must be RSA type. By default, the host key is also the sign key used to encrypt signatures. When necessary, a different sign key can be specified and this can be either RSA or DSA type. By default, the message digest type is MD5, but any combination of sign key type and message digest type supported by the OpenSSL library can be specified, including those using the MD2, MD5, SHA, SHA1, MDC2 and RIPE160 message digest algorithms. However, the scheme specified in the certificate must be compatible with the sign key. Certificates using any digest algorithm are compatible with RSA sign keys; however, only SHA and SHA1 certificates are compatible with DSA sign keys.

      -

      Private/public key files and certificates are compatible with other OpenSSL applications and very likely other libraries as well. Certificates or certificate requests derived from them should be compatible with extant industry practice, although some users might find the interpretation of X509v3 extension fields somewhat liberal. However, the identification parameter files, although encoded as the other files, are probably not compatible with anything other than Autokey.

      -

      Running the program as other than root and using the Unix su command to assume root may not work properly, since by default the OpenSSL library looks for the random seed file .rnd in the user home directory. However, there should be only one .rnd, most conveniently in the root directory, so it is convenient to define the $RANDFILE environment variable used by the OpenSSL library as the path to /.rnd.

      -

      Installing the keys as root might not work in NFS-mounted shared file systems, as NFS clients may not be able to write to the shared keys directory, even as root. In this case, NFS clients can specify the files in another directory such as /etc using the keysdir command. There is no need for one client to read the keys and certificates of other clients or servers, as these data are obtained automatically by the Autokey protocol.

      -

      Ordinarily, cryptographic files are generated by the host that uses them, but it is possible for a trusted agent (TA) to generate these files for other hosts; however, in such cases files should always be encrypted. The subject name and trusted name default to the hostname of the host generating the files, but can be changed by command line options. It is convenient to designate the owner name and trusted name as the subject and issuer fields, respectively, of the certificate. The owner name is also used for the host and sign key files, while the trusted name is used for the identity files.

      -

      Trusted Hosts and Groups

      -

      Each cryptographic configuration involves selection of a signature scheme and identification scheme, called a cryptotype, as explained in the Authentication Options page. The default cryptotype uses RSA encryption, MD5 message digest and TC identification. First, configure a NTP subnet including one or more low-stratum trusted hosts from which all other hosts derive synchronization directly or indirectly. Trusted hosts have trusted certificates; all other hosts have nontrusted certificates. These hosts will automatically and dynamically build authoritative certificate trails to one or more trusted hosts. A trusted group is the set of all hosts that have, directly or indirectly, a certificate trail ending at a trusted host. The trail is defined by static configuration file entries or dynamic means described on the Automatic NTP Configuration Options page.

      -

      On each trusted host as root, change to the keys directory. To insure a fresh fileset, remove all ntpkey files. Then run ntp-keygen -T to generate keys and a trusted certificate. On all other hosts do the same, but leave off the -T flag to generate keys and nontrusted certificates. When complete, start the NTP daemons beginning at the lowest stratum and working up the tree. It may take some time for Autokey to instantiate the certificate trails throughout the subnet, but setting up the environment is completely automatic.

      -

      If it is necessary to use a different sign key or different digest/signature scheme than the default, run ntp-keygen with the -S type option, where type is either RSA or DSA. The most often need to do this is when a DSA-signed certificate is used. If it is necessary to use a different certificate scheme than the default, run ntp-keygen with the -c scheme option and selected scheme as needed. If ntp-keygen is run again without these options, it generates a new certificate using the same scheme and sign key.

      -

      After setting up the environment it is advisable to update certificates from time to time, if only to extend the validity interval. Simply run ntp-keygen with the same flags as before to generate new certificates using existing keys. However, if the host or sign key is changed, ntpd should be restarted. When ntpd is restarted, it loads any new files and restarts the protocol. Other dependent hosts will continue as usual until signatures are refreshed, at which time the protocol is restarted.

      -

      Identity Schemes

      -

      As mentioned on the Autonomous Authentication page, the default TC identity scheme is vulnerable to a middleman attack. However, there are more secure identity schemes available, including PC, IFF, GQ and MV described on the Identification Schemes page. These schemes are based on a TA, one or more trusted hosts and some number of nontrusted hosts. Trusted hosts prove identity using values provided by the TA, while the remaining hosts prove identity using values provided by a trusted host and certificate trails that end on that host. The name of a trusted host is also the name of its sugroup and also the subject and issuer name on its trusted certificate. The TA is not necessarily a trusted host in this sense, but often is.

      -

      In some schemes there are separate keys for servers and clients. A server can also be a client of another server, but a client can never be a server for another client. In general, trusted hosts and nontrusted hosts that operate as both server and client have parameter files that contain both server and client keys. Hosts that operate only as clients have key files that contain only client keys.

      -

      The PC scheme supports only one trusted host in the group. On trusted host alice run ntp-keygen -P -p password to generate the host key file ntpkey_RSAkey_alice.filestamp and trusted private certificate file ntpkey_RSA-MD5_cert_alice.filestamp. Copy both files to all group hosts; they replace the files which would be generated in other schemes. On each host bob install a soft link from the generic name ntpkey_host_bob to the host key file and soft link ntpkey_cert_bob to the private certificate file. Note the generic links are on bob, but point to files generated by trusted host alice. In this scheme it is not possible to refresh either the keys or certificates without copying them to all other hosts in the group.

      -

      For the IFF scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -I -p password to produce her parameter file ntpkey_IFFpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts that operate as both servers and clients and install a soft link from the generic ntpkey_iff_alice to this file. If there are no hosts restricted to operate only as clients, there is nothing further to do. As the IFF scheme is independent of keys and certificates, these files can be refreshed as needed.

      -

      If a rogue client has the parameter file, it could masquerade as a legitimate server and present a middleman threat. To eliminate this threat, the client keys can be extracted from the parameter file and distributed to all restricted clients. After generating the parameter file, on alice run ntp-keygen -e and pipe the output to a file or mail program. Copy or mail this file to all restricted clients. On these clients install a soft link from the generic ntpkey_iff_alice to this file. To further protect the integrity of the keys, each file can be encrypted with a secret password.

      -

      For the GQ scheme proceed as in the TC scheme to generate keys and certificates for all group hosts, then for every trusted host in the group, generate the IFF parameter file. On trusted host alice run ntp-keygen -T -G -p password to produce her parameter file ntpkey_GQpar_alice.filestamp, which includes both server and client keys. Copy this file to all group hosts and install a soft link from the generic ntpkey_gq_alice to this file. In addition, on each host bob install a soft link from generic ntpkey_gq_bob to this file. As the GQ scheme updates the GQ parameters file and certificate at the same time, keys and certificates can be regenerated as needed.

      -

      For the MV scheme, proceed as in the TC scheme to generate keys and certificates for all group hosts. For illustration assume trish is the TA, alice one of several trusted hosts and bob one of her clients. On TA trish run ntp-keygen -V n -p password, where n is the number of revokable keys (typically 5) to produce the parameter file ntpkeys_MVpar_trish.filestamp and client key files ntpkeys_MVkeyd_trish.filestamp where d is the key number (0 < d < n). Copy the parameter file to alice and install a soft link from the generic ntpkey_mv_alice to this file. Copy one of the client key files to alice for later distribution to her clients. It doesn't matter which client key file goes to alice, since they all work the same way. Alice copies the client key file to all of her cliens. On client bob install a soft link from generic ntpkey_mvkey_bob to the client key file. As the MV scheme is independent of keys and certificates, these files can be refreshed as needed.

      -

      Command Line Options

      -
      -
      -c [ RSA-MD2 | RSA-MD5 | RSA-SHA | RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ] -
      Select certificate message digest/signature encryption scheme. Note that RSA schemes must be used with a RSA sign key and DSA schemes must be used with a DSA sign key. The default without this option is RSA-MD5. -
      -d -
      Enable debugging. This option displays the cryptographic data produced in eye-friendly billboards. -
      -e -
      Write the IFF client keys to the standard output. This is intended for automatic key distribution by mail. -
      -G -
      Generate parameters and keys for the GQ identification scheme, obsoleting any that may exist. -
      -g -
      Generate keys for the GQ identification scheme using the existing GQ parameters. If the GQ parameters do not yet exist, create them first. -
      -H -
      Generate new host keys, obsoleting any that may exist. -
      -I -
      Generate parameters for the IFF identification scheme, obsoleting any that may exist. -
      -i name -
      Set the suject name to name. This is used as the subject field in certificates and in the file name for host and sign keys. -
      -M -
      Generate MD5 keys, obsoleting any that may exist. -
      -P -
      Generate a private certificate. By default, the program generates public certificates. -
      -p password -
      Encrypt generated files containing private data with password and the DES-CBC algorithm. -
      -q -
      Set the password for reading files to password. -
      -S [ RSA | DSA ] -
      Generate a new sign key of the designated type, obsoleting any that may exist. By default, the program uses the host key as the sign key. -
      -s name -
      Set the issuer name to name. This is used for the issuer field in certificates and in the file name for identity files. -
      -T -
      Generate a trusted certificate. By default, the program generates a non-trusted certificate. -
      -V nkeys -
      Generate parameters and keys for the Mu-Varadharajan (MV) identification scheme. -
      -

      Random Seed File

      -

      All cryptographically sound key generation schemes must have means to randomize the entropy seed used to initialize the internal pseudo-random number generator used by the library routines. The OpenSSL library uses a designated random seed file for this purpose. The file must be available when starting the NTP daemon and ntp-keygen program. If a site supports OpenSSL or its companion OpenSSH, it is very likely that means to do this are already available.

      -

      It is important to understand that entropy must be evolved for each generation, for otherwise the random number sequence would be predictable. Various means dependent on external events, such as keystroke intervals, can be used to do this and some systems have built-in entropy sources. Suitable means are described in the OpenSSL software documentation, but are outside the scope of this page.

      -

      The entropy seed used by the OpenSSL library is contained in a file, usually called .rnd, which must be available when starting the NTP daemon or the ntp-keygen program. The NTP daemon will first look for the file using the path specified by the randfile subcommand of the crypto configuration command. If not specified in this way, or when starting the ntp-keygen program, the OpenSSL library will look for the file using the path specified by the RANDFILE environment variable in the user home directory, whether root or some other user. If the RANDFILE environment variable is not present, the library will look for the .rnd file in the user home directory. If the file is not available or cannot be written, the daemon exits with a message to the system log and the program exits with a suitable error message.

      -

      Cryptographic Data Files

      -

      All other file formats begin with two lines. The first contains the file name, including the generated host name and filestamp. The second contains the datestamp in conventional Unix date format. Lines beginning with # are considered comments and ignored by the ntp-keygen program and ntpd daemon. Cryptographic values are encoded first using ASN.1 rules, then encrypted if necessary, and finally written PEM-encoded printable ASCII format preceded and followed by MIME content identifier lines.

      -

      The format of the symmetric keys file is somewhat different than the other files in the interest of backward compatibility. Since DES-CBC is deprecated in NTPv4, the only key format of interest is MD5 alphanumeric strings. Following hte heard the keys are entered one per line in the format

      -

      keyno type key

      -

      where keyno is a positive integer in the range 1-65,535, type is the string MD5 defining the key format and key is the key itself, which is a printable ASCII string 16 characters or less in length. Each character is chosen from the 93 printable characters in the range 0x21 through 0x7f excluding space and the '#' character.

      -

      Note that the keys used by the ntpq and ntpdc programs are checked against passwords requested by the programs and entered by hand, so it is generally appropriate to specify these keys in human readable ASCII format.

      -

      The ntp-keygen program generates a MD5 symmetric keys file ntpkey_MD5key_hostname.filestamp. Since the file contains private shared keys, it should be visible only to root and distributed by secure means to other subnet hosts. The NTP daemon loads the file ntp.keys, so ntp-keygen installs a soft link from this name to the generated file. Subsequently, similar soft links must be installed by manual or automated means on the other subnet hosts. While this file is not used with the Autokey Version 2 protocol, it is needed to authenticate some remote configuration commands used by the ntpq and ntpdc utilities.

      -

      Bugs

      -

      It can take quite a while to generate some cryptographic values, from one to several minutes with modern architectures such as UltraSPARC and up to tens of minutes to an hour with older architectures such as SPARC IPC.

      -
      - - - - \ No newline at end of file + + + +ntp-keygen - generate public and private keys + + + +

      ntp-keygen - generate public and private keys

      +

      giffrom Alice's Adventures in Wonderland, Lewis Carroll

      +

      Alice holds the key.

      +

      Last update: + 10-Mar-2014 05:11 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      Synopsis

      +

      ntp-keygen [ -deGHIMPT ] [ -b modulus ] [ -c [ RSA-MD2 | RSA-MD5 | RSA-SHA + | RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ] ] + [ -C cipher ] [-i group ] [ -l days] + [ -m modulus ] [ -p passwd1 ] [ -q passwd2 ] + [ -S [ RSA | DSA ] ] [ -s host ] [ -V nkeys ]

      +

      Description

      +

      This program generates cryptographic data files used by the NTPv4 authentication and identity schemes. It can generate message digest keys used in symmetric key cryptography and, if the OpenSSL software library has been installed, it can generate host keys, sign keys, certificates, and identity keys and parameters used by the Autokey public key cryptography. The message digest keys file is generated in a format compatible with NTPv3. All other files are in PEM-encoded printable ASCII format so they can be embedded as MIME attachments in mail to other sites.

      +

      When used to generate message digest keys, the program produces a file containing + ten pseudo-random printable ASCII strings suitable for the MD5 message digest algorithm included in the distribution. If the OpenSSL library is installed, it produces an additional ten hex-encoded random bit strings suitable for the SHA1 and other message digest algorithms. The message digest keys file must be distributed and stored using secure means beyond the scope of NTP itself. Besides the keys used for ordinary NTP associations, additional keys can be defined as passwords for the ntpq and ntpdc utility programs.

      +

      The remaining generated files are compatible with other OpenSSL applications and other Public Key Infrastructure (PKI) resources. Certificates generated by this program are compatible with extant industry practice, although some users might find the interpretation of X509v3 extension fields somewhat liberal. However, the identity keys are probably not compatible with anything other than Autokey.

      +

      Some files used by this program are encrypted using a private password. The -p option specifies the password for local encrypted files and the -q option the password for encrypted files sent to remote sites. If no password is specified, the host name returned by the Unix gethostname() function, normally the DNS name of the host, is used.

      +

      The pw option of the crypto configuration command specifies the read password for previously encrypted local files. This must match the local password used by this program. If not specified, the host name is used. Thus, if files are generated by this program without password, they can be read back by ntpd without password, but only on the same host.

      +

      Normally, encrypted files for each host are generated by that host and used only by that host, although exceptions exist as noted later on this page. The symmetric keys file, normally called ntp.keys, is usually installed in /etc. Other files and links are usually installed in /usr/local/etc, which is normally in a shared filesystem in NFS-mounted networks and cannot be changed by shared clients. The location of the keys directory can be changed by the keysdir configuration command in such cases. Normally, this is in /etc.

      +

      This program directs commentary and error messages to the standard error stream stderr and remote files to the standard output stream stdout where they can be piped to other applications or redirected to files. The names used for generated files and links all begin with the string ntpkey and include the file type, generating host and filestamp, as described in the Cryptographic Data Files section below

      +

      Running the Program

      +

      To test and gain experience with Autokey concepts, log in as root and change to the keys directory, usually /usr/local/etc. When run for the first time, or if all files with names beginning ntpkey have been removed, use the ntp-keygen command without arguments to generate a default RSA host key and matching RSA-MD5 certificate with expiration date one year hence. If run again without options, the program uses the existing keys and parameters and generates only a new certificate with new expiration date one year hence.

      +

      Run the command on as many hosts as necessary. Designate one of them as the trusted host (TH) using ntp-keygen with the -T option and configure it to synchronize from reliable Internet servers. Then configure the other hosts to synchronize to the TH directly or indirectly. A certificate trail is created when Autokey asks the immediately ascendant host towards the TH to sign its certificate, which is then provided to the immediately descendant host on request. All group hosts should have acyclic certificate trails ending on the TH.

      +

      The host key is used to encrypt the cookie when required and so must be RSA type. By default, the host key is also the sign key used to encrypt signatures. A different sign key can be assigned using the -S option and this can be either RSA or DSA type. By default, the signature message digest type is MD5, but any combination of sign key type and message digest type supported by the OpenSSL library can be specified using the -c option.

      +
      The rules say cryptographic media should be generated with proventic filestamps, which means the host should already be synchronized before this program is run. This of course creates a chicken-and-egg problem when the host is started for the first time. Accordingly, the host time should be set by some other means, such as eyeball-and-wristwatch, at least so that the certificate lifetime is within the current year. After that and when the host is synchronized to a proventic source, the certificate should be re-generated.
      +

      Additional information on trusted groups and identity schemes is on the Autokey Public-Key Authentication page.

      +

      Command Line Options

      +
      +
      -b modulus
      +
      Set the modulus for generating identity keys to modulus bits. The modulus defaults to 256, but can be set from 256 (32 octets) to 2048 (256 octets). Use the larger moduli with caution, as this can consume considerable computing resources and increases the size of authenticated packets.
      +
      -c [ RSA-MD2 | RSA-MD5 | RSA-SHA | RSA-SHA1 | RSA-MDC2 | RSA-RIPEMD160 | DSA-SHA | DSA-SHA1 ]
      +
      Select certificate digital signature and message digest scheme. Note that RSA schemes must be used with an RSA sign key and DSA schemes must be used with a DSA sign key. The default without this option is RSA-MD5. If compatibility with FIPS 140-2 is required, either the DSA-SHA or DSA-SHA1 scheme must be used.
      +
      -C cipher
      +
      Select the OpenSSL cipher to use for password-protected keys. The openssl -h command provided with OpenSSL displays available ciphers. The default without this option is des-ede3-cbc.
      +
      -d
      +
      Enable debugging. This option displays the cryptographic data produced for eye-friendly billboards.
      +
      -e
      +
      Extract the IFF or GQ public parameters from the IFFkey or GQkey keys file previously specified. Send the unencrypted data to the standard output stream stdout.
      +
      -G
      +
      Generate a new encrypted GQ key file for the Guillou-Quisquater (GQ) identity scheme. This option is mutually exclusive with the -I and -V options.
      +
      -H
      +
      Generate a new encrypted RSA public/private host key file.
      +
      -i group
      +
      Set the optional Autokey group name to group. This is used in the identity scheme parameter file names. In that role, the default is the host name if no group is provided. The group name, if specified using -i or using -s following an @ character, is also used in certificate subject and issuer names in the form host@group and should match the group specified via crypto ident or server ident in ntpd's configuration file.
      +
      -I
      +
      Generate a new encrypted IFF key file for the Schnorr (IFF) identity scheme. This option is mutually exclusive with the -G and -V options.
      +
      -l days
      +
      Set the lifetime for certificates to days. The default lifetime is one year (365 d).
      +
      -m modulus
      +
      Set the modulus for generating files to modulus bits. The modulus defaults to 512, but can be set from 256 (32 octets) to 2048 (256 octets). Use the larger moduli with caution, as this can consume considerable computing resources and increases the size of authenticated packets.
      +
      -M
      +
      Generate a new keys file containing 10 MD5 keys and 10 SHA keys. An MD5 key is a string of 20 random printable ASCII characters, while a SHA key is a string of 40 random hex digits. The file can be edited using a text editor to change the key type or key content. This option is mutually exclusive with all other option.
      +
      -P
      +
      Generate a new private certificate used by the PC identity scheme. By default, the program generates public certificates. Note: the PC identity scheme is not recommended for new installations.
      +
      -p passwd
      +
      Set the password for reading and writing encrypted files to passwd. These include the host, sign and identify key files. By default, the password is the string returned by the Unix gethostname() routine.
      +
      -q passwd
      +
      Set the password for writing encrypted IFF, GQ and MV identity files redirected to stdout to passwd. In effect, these files are decrypted with the -p password, then encrypted with the -q password. By default, the password is the string returned by the Unix gethostname() routine.
      +
      -S [ RSA | DSA ]
      +
      Generate a new encrypted public/private sign key file of the specified type. By default, the sign key is + the host key and has the same type. If compatibly with FIPS 140-2 is required, + the sign key type must be DSA.
      +
      -s host[@group]
      +
      Specify the Autokey host name, where host is the host name and group is the optional group name. The host name, and if provided, group name are used in host@group form as certificate subject and issuer. Specifying -s @group is allowed, and results in leaving the host name unchanged, as with -i group. The group name, or if no group is provided, the host name are also used in the file names of IFF, GQ, and MV identity scheme parameter files. If host is not specified, the default host name is the string returned by the gethostname() routine.
      +
      -T
      +
      Generate a trusted certificate. By default, the program generates nontrusted certificates.
      +
      -V nkeys
      +
      Generate nkeys encrypted server keys for the Mu-Varadharajan (MV) identity scheme. This option is mutually exclusive with the -I and -G options. Note: support for this option should be considered a work in progress.
      +
      +

      Random Seed File

      +

      All cryptographically sound key generation schemes must have means to randomize the entropy seed used to initialize the internal pseudo-random number generator used by the OpenSSL library routines. If a site supports ssh, it is very likely that means to do this are already available. The entropy seed used by the OpenSSL library is contained in a file, usually called .rnd, which must be available when starting the ntp-keygen program or ntpd daemon.

      +

      The OpenSSL library looks for the file using the path specified by the RANDFILE environment variable in the user home directory, whether root or some other user. If the RANDFILE environment variable is not present, the library looks for the .rnd file in the user home directory. Since both the ntp-keygen program and ntpd daemon must run as root, the logical place to put this file is in /.rnd or /root/.rnd. If the file is not available or cannot be written, the program exits with a message to the system log.

      +

      Cryptographic Data Files

      +

      File and link names are in the form ntpkey_key_name.fstamp, where key is the key or parameter type, name is the host or group name and fstamp is the filestamp (NTP seconds) when the file was created). By convention, key names in generated file names include both upper and lower case characters, while key names in generated link names include only lower case characters. The filestamp is not used in generated link names.

      +

      The key name is a string defining the cryptographic key type. Key types include public/private keys host and sign, certificate cert and several challenge/response key types. By convention, client files used for challenges have a par subtype, as in the IFF challenge IFFpar, while server files for responses have a key subtype, as in the GQ response GQkey.

      +

      All files begin with two nonencrypted lines. The first line contains the file name in the format ntpkey_key_host.fstamp. The second line contains the datestamp in conventional Unix date format. Lines beginning with # are ignored.

      +

      The remainder of the file contains cryptographic data encoded first using ASN.1 rules, then encrypted using the DES-CBC algorithm with given password and finally written in PEM-encoded printable ASCII text preceded and followed by MIME content identifier lines.

      +

      The format of the symmetric keys file, ordinarily named ntp.keys, is somewhat different than the other files in the interest of backward compatibility. Ordinarily, the file is generated by this program, but it can be constructed and edited using an ordinary text editor.

      +
      +

      gif

      +

      Figure 1. Typical Symmetric Key File

      +
      +

      Figure 1 shows a typical symmetric keys file used by the reference implementation. Each line of the file contains three fields, first an integer between 1 and 65534, inclusive, representing the key identifier used in the server and peer configuration commands. Next is the key type for the message digest algorithm, which in the absence of the OpenSSL library must be MD5 to designate the MD5 message digest algorithm. If the OpenSSL library is installed, the key type can be any message digest algorithm supported by that library. However, if compatibility with FIPS 140-2 is required, the key type must be either SHA or SHA1. The key type can be changed using an ASCII text editor.

      +

      An MD5 key consists of a printable ASCII string less than or equal to 16 characters and terminated by whitespace or a # character. An OpenSSL key consists of a hex-encoded ASCII string of 40 characters, which is truncated as necessary.

      +

      Note that the keys used by the ntpq and ntpdc programs are checked against passwords requested by the programs and entered by hand, so it is generally appropriate to specify these keys in human readable ASCII format.

      +

      The ntp-keygen program generates a MD5 symmetric keys file ntpkey_MD5key_hostname.filestamp. Since the file contains private shared keys, it should be visible only to root and distributed by secure means to other subnet hosts. The NTP daemon loads the file ntp.keys, so ntp-keygen installs a soft link from this name to the generated file. Subsequently, similar soft links must be installed by manual or automated means on the other subnet hosts. While this file is not used with the Autokey Version 2 protocol, it is needed to authenticate some remote configuration commands used by the ntpq and ntpdc utilities.

      +

      Bugs

      +

      It can take quite a while to generate some cryptographic values, from one to several minutes with modern architectures such as UltraSPARC and up to tens of minutes to an hour with older architectures such as SPARC IPC.

      +
      + + + diff --git a/contrib/ntp/html/ldisc.html b/contrib/ntp/html/ldisc.html deleted file mode 100644 index 428a2513a..000000000 --- a/contrib/ntp/html/ldisc.html +++ /dev/null @@ -1,47 +0,0 @@ - - - - - - - Line Disciplines and Streams Modules - - - - -

      Line Disciplines and Streams Modules

      -

      Last update: 18:40 UTC Thursday, July 28, 2005

      -

      Related Links

      - -
      -

      Description

      -

      Most radio and modem clocks used for a primary (stratum-1) NTP server utilize serial ports operating at speeds of 9600 baud or greater. The intrinsic delay and jitter contributed by the serial port hardware and software driver can accumulate up to a millisecond in newer Unix systems and tens of milliseconds in older ones. In order to reduce the effects of delay and jitter, a set of special line disciplines, stream modules and operating system calls (ioctls) can be configured in some Unix kernels. These routines intercept special characters or signals provided by the radio or modem clock and save a timestamp for later processing.

      -

      The routines provide two important functions. Some insert a timestamp in the receive data stream upon occurance of a designated character or characters at the serial interface. This can be used to timestamp an on-time character produced by a radio clock, for example. Other routines support an application program interface for pulse-per-second (PPS) signals generated by some radio clocks and laboratory instruments. These routines are normally accessed through the PPSAPI application program interface described below.

      -

      The routines can be compiled in the kernel in older BSD-derived systems, or installed as System V streams modules and either compiled in the kernel or dynamically loaded when required. In either case, they require minor changes in some kernel files and in the NTP daemon ntpd. The streams modules can be pushed and popped from the streams stack using conventional System V streams program primitives. Note that some Unix kernels do not support line disciplines and some do not support System V streams. The routines described here are known to work correctly with the Unix kernels called out in the descriptions, but have not been tested for other kernels.

      -

      tty_clk Line Discipline/Streams Module

      -

      This routine intercepts characters received from the serial port and passes unchanged all except a set of designated characters to the generic serial port discipline. For each of the exception characters, the character is inserted in the receiver buffer followed by a local timestamp in Unix timeval format. Both select() and SIGIO are supported by the routine. Support for this routine is automatically detected during the NTP build process and interface code compiled as necessary.

      -

      There are two versions of the tty_clk routine. The tty_clk.c line discipline is designed for older BSD systems and is compiled in the kernel. The tty_clk_STREAMS.c is designed for System V streams, in which case it can be either compiled in the kernel or dynamically loaded. Since these programs are small, unobtrusive, and do nothing unless specifically enabled by an application program, it probably doesn't matter which version is chosen. Instructions on how to configure and build a kernel supporting either of these routines is in the README file in the ./kernel directory.

      -

      The tty_clk routine defines a new ioctl CLK_SETSTR, which takes a pointer to a string of no more than 32 characters. Until the first CLK_SETSTR is performed, the routine will simply pass through characters. Once it is passed a string by CLK_SETSTR, any character in that string will be immediately followed by a timestamp in Unix timeval format. You can change the string whenever you want by doing another CLK_SETSTR. The character must be an exact, 8 bit match. The character '\000' cannot, be used, as it is the string terminator. Passing an empty string to CLK_SETSTR turns off timestamping. Passing NULL may produce surprising results.

      -

      TIOCDCDTIMESTAMP ioctl in FreeBSD

      -

      This ioctl is included in FreeBSD 2.2 and later. It causes a timestamp to be inserted in the serial port receive data stream when the data carrier detect (DCD) signal is asserted. This is useful for those radio clocks that indicate the on-time epoch by means of a modem control signal. It is not recommended that this be used for PPS timestamps, as this function is available using the PPS application program interface included in FreeBSD 3.4 and later.

      -

      The TIOCDCDTIMESTAMP ioctl() is detected and compiled automatically on FreeBSD systems if available. With FreeBSD 2.2 the measured delay between activation of the DCD signal and the time the timestamp is captured on a 66MHz 486DX2 is 19 ms and on a 100MHz Pentium is 6 ms.

      -

      ppsclockStreams Module (depredated)

      -

      This routine is a streams module which causes a timestamp to be captured when the DCD signal is asserted. It is normally used in connection with a PPS signal generated by some radio clocks. However, it is normally used only by the PPSAPI interface and SunOS 4.1.3 and should be avoided in other contexts. Instructions on how to configure and build a kernel supporting either of these routines is in the README file in the ./kernel directory.

      -

      The ppsclock streams module implements the CIOGETEV ioctl, which takes a pointer to the structure

      -
      -struct ppsclockev {
      -     struct timeval tv;
      -     u_int serial;
      -};
      -
      -

      The ppsclock module is pushed on the streams stack of the serial port connected to the DCD line. At each positive-going edge of the PPS signal, the routine latches the current local timestamp and increments a counter. At each CIOGETEV ioctl call, the current values of the timestamp and counter are returned in the ppsclockev structure.

      -

      TIOCSPPS and TIOCGETPPSEV ioctls in Solaris

      -

      These ioctls are included in Solaris 2.4 and later. They implement the same function as the ppsclock streams module, but are implemented as integrated system calls independent of the streams facility. They are normally used in connection with a pulse-per-second (PPS) signal generated by some radio clocks. However, these ioctls are normally used only by the PPSAPI interface and should be avoided in other contexts. See the Sun documentation for the calling sequence and return values.

      -

      Users are cautioned that these ioctls function improperly in Solaris versions prior to 2.8 with patch Generic_108528-02.

      -

      tty_chu Line Discipline/Streams Module (depredated)

      -

      This routine is a special purpose line discipline for receiving a special timecode broadcast by Canadian time and frequency standard station CHU. It has been removed from the distribution since its function has been replaced by the Radio CHU Audio Demodulator/Decoder (type 7) clock driver.

      -
      - - - - \ No newline at end of file diff --git a/contrib/ntp/html/leap.html b/contrib/ntp/html/leap.html new file mode 100644 index 000000000..8abec149a --- /dev/null +++ b/contrib/ntp/html/leap.html @@ -0,0 +1,24 @@ + + + + + +Leap Second Processing + + + +

      Leap Second Processing

      +

      Last update: + 10-Mar-2014 05:11 + UTC

      +
      +

      About every eighteen months the International Earth Rotation Service (IERS) issues a bulletin announcing the insertion of a leap second in the Universal Coordinated Time (UTC) timescale. Ordinarily, this happens at the end of the last day of June or December; but, in principle, it could happen at the end of any month. While these bulletins are available on the Internet at www.iers.org, advance notice of leap seconds is also available in signals broadcast from national time and frequency stations, in GPS signals and in telephone modem services. Many, but not all, reference clocks recognize these signals and many, but not all, drivers for them can decode the signals and set the leap bits in the timecode accordingly. This means that many, but not all, primary servers can pass on these bits in the NTP packet heard to dependent secondary servers and clients. Secondary servers can pass these bits to their dependents and so on throughout the NTP subnet.

      +

      A leap second is inserted following second 59 of the last minute of the day and becomes second 60 of that day. A leap second is deleted by omitting second 59 of the last minute of the day, although this has never happened and is highly unlikely to happen in future. So far as is known, there are no provisions in the Unix or Windows libraries to account for this occasion other than to affect the conversion of an NTP datestamp or timestamp to conventional civil time.

      +

      When an update is received from a reference clock or downstratum server, the leap bits are inspected for all survivors of the cluster algorithm. If the number of survivors showing a leap bit is greater than half the total number of survivors, a pending leap condition exists until the end of the current month.

      +

      When no means are available to determine the leap bits from a reference clock or downstratum server, a leapseconds file can be downloaded from time.nist.gov and installed using the leapfile command. The file includes a list of historic leap seconds and the NTP time of insertion. It is parsed by the ntpd daemon at startup and the latest leap time saved for future reference. Each time the clock is set, the current time is compared with the last leap time. If the current time is later than the last leap time, nothing further is done. If earlier, the leap timer is initialized with the time in seconds until the leap time and counts down from there. When the leap timer is less than one month, a pending leap condition exists until the end of the current month. If the leapseconds file is present, the leap bits for reference clocks and downstratum servers are ignored.

      +

      If the precision time kernel support is available and enabled, at the beginning of the day of the leap event, the leap bits are set by the Unix ntp_adjtime() system call to arm the kernel for the leap at the end of the day. The kernel automatically inserts one second exactly at the time of the leap, after which the leap bits are turned off. If the kernel support is not availed or disabled, the leap is implemented as a crude hack by setting the clock back one second using the Unix settimeofday() system call, which effectively repeats the last second. Note however that in any case setting the time backwards by one second does not actually set the system clock backwards, but effectively stalls the clock for one second. These points are expanded in the white paper The NTP Timescale and Leap Seconds. If the leap timer is less than one day, the leap bits are set for dependent servers and clients.

      +

      As an additional feature when the NIST leap seconds file is installed, it is possible to determine the number of leap seconds inserted in UTC since UTC began on 1 January 1972. This represents the offset between International Atomic Time (TAI) and UTC. If the precision time kernel modifications are available and enabled, the TAI offset is available to application programs using the antipasti() system call. If the Autokey public-key cryptography feature is installed, the TAI offset is automatically propagated along with other cryptographic media to dependent servers and clients.

      +
      +

      + + diff --git a/contrib/ntp/html/manyopt.html b/contrib/ntp/html/manyopt.html deleted file mode 100644 index 83869cab4..000000000 --- a/contrib/ntp/html/manyopt.html +++ /dev/null @@ -1,83 +0,0 @@ - - - - - - - - Automatic NTP Configuration Options - - - - -

      Automatic NTP Configuration Options

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      Make sure who your friends are.

      -

      Last update: 20:55 UTC Tuesday, October 11, 2005

      -
      -

      Related Links

      - -

      Table of Contents

      - -
      -

      Broadcasting

      -

      Broadcasting is the simplest way to provide automatic server discovery. It uses the multi-destination paradigm, where the subnet spanning tree is constructed automatically, either by the switches in an Ethernet LAN or the DVMRP or PIM protocols when spanning multiple networks.

      -

      A broadcast or multicast server is mobilized by the broadcast configuration command. The addresses can be either from the IPv4 broadcast/mulitcast address family or the IPv6 address family. Multiple broadcast server associations can be specified for a single host.

      -

      A host is enabled for broadcast reception using the broadcastclient configuration command, with or without the novolley option. Upon receiving the first message from a broadcast server, the client mobilizes an ephemeral client association and exchanges a volley of client/server messages in order to quickly authenticate the source, set the clock and measure the propagation delay, then reverts to listen-only mode. A multicast client is mobilized in the same way using the multicastclient configuration command and specified multicast group address.

      -

      Broadcasting can be used with either symmetric key or public key cryptography. Public key cryptography offers the best protection against compromised keys and is generally considered stronger. By default, either of these two means is required, but this can be overridden by the disable auth command.

      -

      In both broadcast and multicast client operations the client association is demobilized in case of error or timeout due to loss of server or connectivity.

      -

      Manycasting

      -

      Manycasting is a automatic discovery and configuration paradigm new to NTPv4. It is intended as a means for a client to troll the nearby network neighborhood to find cooperating servers, validate them using cryptographic means and evaluate their time values with respect to other servers that might be lurking in the vicinity. The intended result is that each client mobilizes associations with a given number of the "best" nearby servers, yet automatically reconfigures to sustain this number of servers should one or another fail.

      -

      Note that the manycast paradigm does not coincide with the anycast paradigm described in RFC-1546, which is designed to find a single server from a clique of servers providing the same service. The manycast paradigm is designed to find a plurality of redundant servers satisfying defined optimality criteria.

      -

      Manycasting can be used with either symmetric key or public key cryptography. Public key cryptography offers the best protection against compromised keys and is generally considered stronger. By default, either of these two means is required, but this can be overridden by the disable auth command.

      -

      A manycast client association is configured using the manycastclient configuration command, which is similar to the server configuration command, but with a broadcast or multicast address. Depending on address family. The manycast client sends ordinary client mode messages, but with a broadcast address rather than a unicast address. It sends only if less than a given threshold of servers have been found and then only at the minimum feasible rate and minimum feasible time-to-live (TTL) hops. There can be as many manycast client associations as different broadcast addresses, each one serving as a template for a future unicast client/server association.

      -

      Manycast servers configured with the manycastserver command listen on the specified broadcast address for manycast client messages. If a manycast server is in scope of the current TTL and is itself synchronized to a valid source and operating at a stratum level equal to or lower than the manycast client, it replies to the manycast client message with an ordinary unicast server message.

      -

      The manycast client receiving this message mobilizes a preemptable client association according to the matching manycast client template, but only if cryptographically authenticated and the server stratum is less than or equal to the client stratum. The client runs the NTP mitigation algorithms, which act to demobilize all but a threshold number of associations according to stratum and synchronization distance. The surviving associations then continue in ordinary client/server mode.

      -

      If for some reason the number of available servers falls below the threshold, the manycast client resumes sending broadcast messages. The polling strategy is designed to reduce as much as possible the volume of broadcast messages and the effects of implosion due to near-simultaneous arrival of manycast server messages. The strategy is determined by the tos and ttl configuration commands described below.

      -

      It is possible and frequently useful to configure a host as both manycast client and manycast server. A number of hosts configured this way and sharing a common group address will automatically organize themselves in an optimum configuration based on stratum and synchronization distance.

      -

      For example, consider an NTP subnet of two primary servers and several secondary servers and a number of dependent clients. With twoAll servers and clients have identical configuration files including both multicastclient and multicastserver commands using, for instance, multicast group address 239.1.1.1. Each primary server configuration file must include commands for the primary reference source such as a GPS receiver.

      -

      The remaining configuration files for all secondary servers and clients have the same contents, except for the tos command, which is specific for each stratum level. For stratum 1 and stratum 2 servers, that command is not necessary. For stratum 3 and above servers the tos floor value is set to the intended stratum number. Thus, all stratum 3 configuration files use tos floor 3, all stratum 4 files use tos floor 4 and so forth.

      -

      Once operations have stabilized, the primary servers will find the primary reference source and each other, since they both operate at the same stratum (1), but not with any secondary server or client, since these operate at a higher stratum. The secondary servers will find the servers at the same stratum level. If one of the primary servers loses its GPS receiver, it will continue to operate as a client and other clients will time out the corresponding association and re-associate accordingly.

      -

      Orphan Mode

      -

      Sometimes it is necessary to operate an NTP subnet in isolation, because a local reference clock is unavailable or connectivity to the Internet is not provided. In such cases it may be necessary that the subnet servers and clients remain synchronized to a common timescale, not necessarily the UTC timescale. Previously, this function was provided by the local clock driver, which could be configured for a server that could be reached, directly or indirectly from all other servers and clients in the subnet.

      -

      There are many disadvantages using the local clock driver: multiple source redundancy is not possible and the subnet is vulnerable to single-point failures. Orphan mode is intended to replace the need for the local clock driver. It operates in subnet configurations in all modes, including broadcast, and multiple servers and clients and handles seamless switching as primary sources fail and recover.

      -

      A server or client is enabled for orphan mode using the tos orphan stratum command, where stratum is some stratum less than 16 and greater than any anticipated stratum that might occur with ordinary Internet servers. This is the same consideration that guides the local clock driver stratum.

      -

      As long as the stratum of any orphan is less than the orphan stratum, the servers and clients operate in the normal way. However, if the stratum equals or exceeds this stratum, the server or client is considered an orphan. If under these conditions a host has no sources of the same or lower stratum, it is designated an orphan parent; otherwise, it is considered an orphan child. Orphan parents show offset zero, root delay zero and reference ID 127.0.0.1, which of course is the Unix loopback address. Orphan children show the mitigated offset of their servers, root delay randomized over a moderate range and reference ID of their system peer. An important distinction is that the entire subnet operates at the same orphan stratum and that the order of preference is the root delay, not the stratum and root distance as usual.

      -

      For the most flexible and reliable operation, all servers and clients in the subnet should include the orphan command in the configuration file and with the same orphan stratum. This provides mutual redundancy and diversity for all NTP modes of operation, including broadcast.

      -

      For example, consider the case where several campus secondary (stratum 2) servers are configured for public Internet primary servers and with each other using symmetric modes. These servers provide synchronization with a number of department servers using broadcast mode, where each of these servers is configured as both a broadcast server and broadcast client. Individual workstations on the department LAN are configured as broadcast clients only. All servers (not necessarily the clients) have the orphan 5 command, for example.

      -

      In normal operation all servers and clients operate below stratum 5, so operate with the subnet configuration determined by stratum and root distance. If all sources are lost at any stratum level, the server or client continues operation as orphan parent. However, if sources at the orphan stratum are found, the host synchronizes to the source with lowest root delay. Since orphan root delay is determined randomly at startup, loops are avoided, even in broadcast modes where multiple servers are available.

      -

      Server Discovery Options

      -
      -
      tos [ ceiling ceiling | cohort {0 | 1} | floor floor | orphan orphan | maxdistance maxdistance | minclock minclock | minsane minsane ] -
      This command affects the clock selection and clustering algorithms. It can be used to select the quality and quantity of peers used to synchronize the system clock and is most useful in manycast mode. The variables operate as follows: -
      beacon beacon -
      The manycast server sends packets at intervals of 64 s if less than maxclock servers are available. Otherwise, it sends packets at the beacon interval in seconds. The default is 3600 s.
      ceiling ceiling -
      Servers with stratum at or above ceiling will be discarded if there are at least minclock peers remaining. This value defaults to 15, but can be changed to any number from 1 to 15. -
      cohort { 0 | 1 } -
      This is a binary flag which enables (0) or disables (1) manycast server replies to manycast clients with the same stratum level. This is useful to reduce implosions where large numbers of clients with the same stratum level are present. The default is to enable these replies. -
      floor floor -
      Peers with strata below floor will be discarded if there are at least minclock peers remaining. This value defaults to 1, but can be changed to any number from 1 to 15. -
      orphan stratum -
      If stratum is set at some value less than 16 a special orphan mode is enterred when no outside source of synchronization is available. To use orphan mode a number of participants are identically configured both as broadcast client and as broadcast server. One or more participants are configured to use an outside source, either a reference clock or another Internet server. When the source or sources fail, the system stratum is set at stratum and a leader is elected to serve as the reference source. When an outside source of synchronization is again available, the orphan mode is disabled.
      mindist mindistance -
      The slection algorithm normally pads each intersection a minimum of one millisecond to avoid needless classification. In some cases, such as reference clocks with high jitter and a PPS signal, it is useful to increase the padding. This command can be used for that purpose. As a general rule, set the mindistance to the maximum expected offset plus the maxiumum expected jitter, in seconds. -
      maxdist maxdistance -
      The selection algorithm accumulates a number of packets before setting the clock in order to use the best data available. The number is determined by the synchronization distance for each association and a limit called the distance threshold. The synchronization distance starts at 16, then drops by a factor of about two as each packet is received. The default distance threshold is 1.0, which usually results in four packets. Setting maxdistance to some value between 1 and 16 can be used to change the number of packets required. For instance, setting it to 16 will set the clock on the first packet received; howver, setting it to this value essentially disables the mitigation and grooming algorithms. -
      minclock minclock -
      The clustering algorithm repeatedly casts out outlyer associations until no more than minclock associations remain. This value defaults to 3, but can be changed to any number from 1 to the number of configured sources. -
      minsane minsane -
      This is the minimum number of candidates available to the clock selection algorithm in order to produce one or more truechimers for the clustering algorithm. If fewer than this number are available, the clock is undisciplined and allowed to run free. The default is 1 for legacy purposes. However, according to principles of Byzantine agreement, minsane should be at least 4 in order to detect and discard a single falseticker. -
      - -
      ttl hop ... -
      This command specifies a list of TTL values in increasing order. up to 8 values can be specified. In manycast mode these values are used in turn in an expanding-ring search. The default is eight multiples of 32 starting at 31. -
      -
      - - - - \ No newline at end of file diff --git a/contrib/ntp/html/measure.html b/contrib/ntp/html/measure.html deleted file mode 100644 index 9cce97a14..000000000 --- a/contrib/ntp/html/measure.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - Time and Time Interval Measurement with Application to Computer and Network Performance Evaluation - - - - -

      Time and Time Interval Measurement with Application to Computer and Network Performance Evaluation

      -

      Last update: 18:41 UTC Thursday, July 28, 2005

      -
      -

      The technical memorandum: Time and Time Interval Measurement with Application to Computer and Network Performance Evaluation(PostScript) describes a number of techniques for conducting experiments typical of computer network and transmission systems engineering.

      -

      In most experiments in which time is involved, it is necessary to develop estimates of time, frequency and measurement errors from a series of time measurements between the clocks of a number of computers and ancillary devices interconnected by some kind of computer network. However, time is not a physical quantity, such as mass, nor can it be measured relative to an absolute frame of reference, such as velocity. The only way to measure time in our universe is to compare the reading of one clock, which runs according to its own timescale, with another clock, which runs according to a given timescale, at some given instant or epoch. The errors arise from the precision of time comparisons and the accuracy of frequency estimates between the timescales involved.

      -

      The usual data collected during a performance run of some experiment might include time offsets, time delays, frequency offsets and various error statistics. While time offsets between two clocks can be measured directly, frequency offsets can be estimated only from two or more time offsets made over some time interval in the experiment. In practice, a sequence of time comparisons can be performed over the lifetime of the experiment and the instantaneous frequency estimated either in real time with a recurrence relation, or retrospectively with a polynomial fit to the data.

      -

      Estimating time and frequency errors in real time has been studied by a distinct subspecies of physicists who have made a career of the technology involved. Various means including autoregressive models, Kalman filters and simple weighted-average algorithms are used extensively by national standards laboratories to model cesium-clock ensembles. These techniques have been adapted to computer network and transmission engineering problems as well. This memorandum explores issues in performing experiments of this type and summarizes various techniques found useful in practice.

      -
      - - - - \ No newline at end of file diff --git a/contrib/ntp/html/miscopt.html b/contrib/ntp/html/miscopt.html index 54041b197..c6190222b 100644 --- a/contrib/ntp/html/miscopt.html +++ b/contrib/ntp/html/miscopt.html @@ -1,123 +1,182 @@ - - - - - Miscellaneous Options - - - - -

      Miscellaneous Options

      - giffrom Pogo, Walt Kelly -

      We have three, now looking for more.

      -

      Last update: 18:50 UTC Monday, January 09, 2006

      -
      -

      Related Links

      - -
      -
      -
      broadcastdelay seconds -
      The broadcast and multicast modes require a special calibration to determine the network delay between the local and remote servers. Ordinarily, this is done automatically by the initial protocol exchanges between the client and server. In some cases, the calibration procedure may fail due to network or server access controls, for example. This command specifies the default delay to be used under these circumstances. Typically (for Ethernet), a number between 0.003 and 0.007 seconds is appropriate. The default when this command is not used is 0.004 seconds. -
      calldelay delay -
      This option controls the delay in seconds between the first and second packets sent in burst or iburst mode to allow additional time for a modem or ISDN call to complete. -
      driftfile driftfile [ - minutes [ tolerance ] ] -
      This command specifies the complete path and name of the file used to record the frequency of the local clock oscillator. This is the same operation as the -f command linke option. If the file exists, it is read at startup in order to set the initial frequency and then updated once per hour with the current frequency computed by the daemon. If the file name is specified, but the file itself does not exist, the starts with an initial frequency of zero and creates the file when writing it for the first time. If this command is not given, the daemon will always start with an initial frequency of zero. -

      The file format consists of a single line containing a single floating point number, which records the frequency offset measured in parts-per-million (PPM). The file is updated by first writing the current drift value into a temporary file and then renaming this file to replace the old version. This implies that ntpd must have write permission for the directory the drift file is located in, and that file system links, symbolic or otherwise, should be avoided.

      - -

      The two optional values determine how often the file is written, and -are particuarly useful when is it desirable to avoid spinning up the -disk unnecessarily. The parameter minutes is how often the file will be written. If omitted or less -than 1, the interval will be 60 minutes (one hour). The parameter tolerance is the -threshold to skip writing the new value. If the new value is within -tolerance percent of the last value written (compared out to 3 -decimal places), the write will be -skipped. The default is 0.0, which means that the write will occur -unless the current and previous values are the same. A tolerance of -.1 equates roughly to a difference in the 2nd decimal place.

      -
      enable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats]
      - disable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats ] -
      Provides a way to enable or disable various system options. Flags not mentioned are unaffected. Note that all of these flags can be controlled remotely using the ntpdc utility program. -
      -
      auth -
      Enables the server to synchronize with unconfigured peers only if the peer has been correctly authenticated using either public key or private key cryptography. The default for this flag is enable. -
      bclient -
      Enables the server to listen for a message from a broadcast or multicast server, as in the multicastclient command with default address. The default for this flag is disable. -
      calibrate -
      Enables the calibrate feature for reference clocks. The default for this flag is disable. -
      kernel -
      Enables the kernel time discipline, if available. The default for this flag is enable if support is available, otherwise disable. -
      monitor -
      Enables the monitoring facility. See the ntpdc program and the monlist command or further information. The default for this flag is enable. -
      ntp -
      Enables time and frequency discipline. In effect, this switch opens and closes the feedback loop, which is useful for testing. The default for this flag is enable. -
      pps -
      Enables the pulse-per-second (PPS) signal when frequency and time is disciplined by the precision time kernel modifications. See the A Kernel Model for Precision Timekeeping page for further information. The default for this flag is disable. -
      stats -
      Enables the statistics facility. See the Monitoring Options page for further information. The default for this flag is disable -
      -
      includefile includefile -
      This command allows additional configuration commands to be included from a separate file. Include files may be nested to a depth of five; upon reaching the end of any include file, command processing resumes in the previous configuration file. This option is useful for sites that run ntpd on multiple hosts, with (mostly) common options (e.g., a restriction list). -
      logconfig configkeyword -
      This command controls the amount and type of output written to the system syslog facility or the alternate logfile log file. All configkeyword keywords can be prefixed with =, + and -, where = sets the syslogmask, + adds and - removes messages. syslog messages can be controlled in four classes (clock, peer, sys and sync). Within these classes four types of messages can be controlled: informational messages (info), event messages (events), statistics messages (statistics) and status messages (status). -

      Configuration keywords are formed by concatenating the message class with the event class. The all prefix can be used instead of a message class. A message class may also be followed by the all keyword to enable/disable all messages of the respective message class. By default, logconfig output is set to allsync. -

      Thus, a minimal log configuration could look like this:

      -

      logconfig=syncstatus +sysevents

      -
      -
      -

      This would just list the synchronizations state of ntpd and the major system events. For a simple reference server, the following minimum message configuration could be useful:

      - -
      - -
      -

      logconfig=allsync +allclock

      -
      -
      -

      This configuration will list all clock information and synchronization information. All other events and messages about peers, system events and so on is suppressed.

      - -
      -
      logfile logfile -
      -
      -

      This command specifies the location of an alternate log file to be used instead of the default system syslog facility. This is the same operation as the -l command line option.

      - -
      -
      phone dial1 dial2 ... -
      -
      This command is used in conjunction with the ACTS modem driver (type 18). The arguments consist of a maximum of 10 telephone numbers used to dial USNO, NIST or European time services. The Hayes command ATDT is normally prepended to the number, which can contain other modem control codes as well. -
      -
      setvar variable [default] -
      This command adds an additional system variable. These variables can be used to distribute additional information such as the access policy. If the variable of the form name = value is followed by the default keyword, the variable will be listed as part of the default system variables (ntpq rv command). These additional variables serve informational purposes only. They are not related to the protocol other that they can be listed. The known protocol variables will always override any variables defined via the setvar mechanism. There are three special variables that contain the names of all variable of the same group. The sys_var_list holds the names of all system variables. The peer_var_list holds the names of all peer variables and the clock_var_list holds the names of the reference clock variables. -
      tinker [ allan allan | dispersion dispersion | freq freq | huffpuff huffpuff | panic panic | step step | stepout stepout ] -
      This command can be used to alter several system variables in very exceptional circumstances. It should occur in the configuration file before any other configuration options. The default values of these variables have been carefully optimized for a wide range of network speeds and reliability expectations. In general, they interact in intricate ways that are hard to predict and some combinations can result in some very nasty behavior. Very rarely is it necessary to change the default values; but, some folks can't resist twisting the knobs anyway and this command is for them. Emphasis added: twisters are on their own and can expect no help from the support group. -

      The variables operate as follows:

      -
      -
      allan allan -
      The argument becomes the new value for the Allan intercept, which is a parameter of the PLL/FLL clock discipline algorithm. The value is in seconds with default 1500 s, which is appropriate for most computer clocks.
      dispersion dispersion -
      The argument becomes the new value for the dispersion increase rate, normally .000015 s/s. -
      freq freq -
      The argument becomes the initial value of the frequency offset in parts-per-million. This overrides the value in the frequency file, if present, and avoids the initial training state if it is not. -
      huffpuff huffpuff -
      The argument becomes the new value for the experimental huff-n'-puff filter span, which determines the most recent interval the algorithm will search for a minimum delay. The lower limit is 900 s (15 m), but a more reasonable value is 7200 (2 hours). There is no default, since the filter is not enabled unless this command is given. -
      panic panic -
      The argument is the panic threshold, by default 1000 s. If set to zero, the panic sanity check is disabled and a clock offset of any value will be accepted. -
      step step -
      The argument is the step threshold, by default 0.128 s. It can be set to any positive number in seconds. If set to zero, step adjustments will never occur. Note: The kernel time discipline is disabled if the step threshold is set to zero or greater than the default. -
      stepout stepout -
      The argument is the stepout timeout, by default 900 s. It can be set to any positive number in seconds. If set to zero, the stepout pulses will not be suppressed. -
      -
      trap host_address [port port_number] [interface interface_address] -
      This command configures a trap receiver at the given host address and port number for sending messages with the specified local interface address. If the port number is unspecified, a value of 18447 is used. If the interface address is not specified, the message is sent with a source address of the local interface the message is sent through. Note that on a multihomed host the interface used may vary from time to time with routing changes. -

      The trap receiver will generally log event messages and other information from the server in a log file. While such monitor programs may also request their own trap dynamically, configuring a trap receiver will ensure that no messages are lost when the server is started.

      -
      ttl hop ... -
      This command specifies a list of TTL values in increasing order. up to 8 values can be specified. In manycast mode these values are used in turn in an expanding-ring search. The default is eight multiples of 32 starting at 31. -
      -

      Files

      - ntp.drift frequency compensation (PPM) -
      - - - + + +Miscellaneous Commands and Options + + + + +

      Miscellaneous Commands and Options

      +giffrom Pogo, Walt Kelly +

      We have three, now looking for more.

      +

      Last update: + 23-Sep-2015 10:20 + UTC

      +
      +

      Related Links

      + + +
      +

      Commands and Options

      +
      +
      broadcastdelay delay
      +
      In broadcast and multicast modes, means are required to determine the network delay between the server and client. Ordinarily, this is done automatically by the initial calibration exchanges between the client and server. In some cases, the exchange might not be possible due to network or server access controls. The value of delay is by default zero, in which case the exchange is enabled. If delay is greater than zero, it becomes the roundtrip delay (s), as measured by the Unix ping program, and the exchange is disabled.
      +
       
      +
      driftfile driftfile
      +
      This command specifies the complete path and name of the file used to record the frequency of the local clock oscillator. This is the same operation as the -f command line option. This command is mutually exclusive with the freq option of the tinker command.
      +
      If the file exists, it is read at startup in order to set the initial frequency and then updated once per hour or more with the current frequency computed by the daemon. If the file name is specified, but the file itself does not exist, the starts with an initial frequency of zero and creates the file when writing it for the first time. If this command is not given, the daemon will always start with an initial frequency of zero.
      +
      The file format consists of a single line containing a single floating point number, which records the frequency offset measured in parts-per-million (PPM). The file is updated by first writing the current drift value into a temporary file and then renaming this file to replace the old version.
      +
      dscp dscp
      +
      This command specifies the Differentiated Services Code Point (DSCP) value that is used in sent NTP packets. The default value is 46 for Expedited Forwarding (EF).
      +
      enable [auth | bclient | calibrate | kernel | mode7 | monitor | ntp | stats]
      + disable [auth | bclient | calibrate | kernel | mode7 | monitor | ntp | stats]
      +
      Provides a way to enable or disable various system options. Flags not mentioned are unaffected. Note that most of these flags can be modified remotely using ntpq utility program's :config and config-from-file commands. +
      +
      auth
      +
      Enables the server to synchronize with unconfigured peers only if the peer has been correctly authenticated using either public key or private key cryptography. The default for this flag is enable.
      +
      bclient
      +
      Enables the server to listen for a message from a broadcast or multicast server, as in the multicastclient command with default address. The default for this flag is disable.
      +
      calibrate
      +
      Enables the calibrate feature for reference clocks. The default for this flag is disable.
      +
      kernel
      +
      Enables the kernel time discipline, if available. The default for this flag is enable if support is available, otherwise disable.
      +
      mode7
      +
      Enables processing of NTP mode 7 implementation-specific requests which are used by the deprecated ntpdc program. The default for this flag is disable. This flag is excluded from runtime configuration using ntpq. The ntpq program provides the same capabilities as ntpdc using standard mode 6 requests.
      +
      monitor
      +
      Enables the monitoring facility. See the ntpq program and the monstats and mrulist commands, as well as the Access Control Options for details. + The monitoring facility is also enabled by the presence of limited in any restrict commands. The default for this flag is enable.
      +
      ntp
      +
      Enables time and frequency discipline. In effect, this switch opens and closes the feedback loop, which is useful for testing. The default for this flag is enable.
      +
      stats
      +
      Enables the statistics facility. See the Monitoring Options page for further information. The default for this flag is enabled. This flag is excluded from runtime configuration using ntpq.
      +
      +
      +
      includefile includefile
      +
      This command allows additional configuration commands to be included from a separate file. Include files may be nested to a depth of five; upon reaching the end of any include file, command processing resumes in the previous configuration file. This option is useful for sites that run ntpd on multiple hosts, with (mostly) common options (e.g., a restriction list).
      +
      interface [listen | ignore | drop] [all | ipv4 | ipv6 | wildcard | name | address[/prefixlen]]
      +
      This command controls which network addresses ntpd opens, and whether input is dropped without processing. The first parameter determines the action for addresses which match the second parameter. That parameter specifies a class of addresses, or a specific interface name, or an address. In the address case, prefixlen determines how many bits must match for this rule to apply. ignore prevents opening matching addresses, drop causes ntpd to open the address and drop all received packets without examination. Multiple interface commands can be used. The last rule which matches a particular address determines the action for it. interface commands are disabled if any -I, --interface, -L, or --novirtualips command-line options are used. If none of those options are used and no interface actions are specified in the configuration file, all available network addresses are opened. The nic command is an alias for interface.
      +
      leapfile leapfile
      +
      This command loads the NIST leapseconds file and initializes the leapsecond values for the next leapsecond time, expiration time and TAI offset. The file can be obtained directly from NIST national time servers using ftp as the ASCII file pub/leap-seconds.
      +
      The leapfile is scanned when ntpd processes the leapfile directive or when ntpd detects that leapfile has changed. ntpd checks once a day to see if the leapfile has changed.
      +
      While not strictly a security function, the Autokey protocol provides means to securely retrieve the current or updated leapsecond values from a server.
      +
      leapsmearinterval seconds
      +
      This EXPERIMENTAL option is only available if ntpd was built with the --enable-leap-smear option to the configure script. It specifies the interval over which a leap second correction will be applied. Recommended values for this option are between 7200 (2 hours) and 86400 (24 hours). DO NOT USE THIS OPTION ON PUBLIC-ACCESS SERVERS! See http://bugs.ntp.org/2855 for more information.
      +
      logconfig configkeyword
      +
      This command controls the amount and type of output written to the system syslog facility or the alternate logfile log file. All configkeyword keywords can be prefixed with =, + and -, where = sets the syslogmask, + adds and - removes messages. syslog messages can be controlled in four classes (clock, peer, sys and sync). Within these classes four types of messages can be controlled: informational messages (info), event messages (events), statistics messages (statistics) and status messages (status).
      +
      Configuration keywords are formed by concatenating the message class with the event class. The all prefix can be used instead of a message class. A message class may also be followed by the all keyword to enable/disable all messages of the respective message class. By default, logconfig output is set to allsync.
      +
      Thus, a minimal log configuration could look like this:
      +
      logconfig=syncstatus +sysevents
      +
      This would just list the synchronizations state of ntpd and the major system events. For a simple reference server, the following minimum message configuration could be useful:
      +
      logconfig=syncall +clockall
      +
      This configuration will list all clock information and synchronization information. All other events and messages about peers, system events and so on is suppressed.
      +
      logfile logfile
      +
      This command specifies the location of an alternate log file to be used instead of the default system syslog facility. This is the same operation as the -l command line option.
      +
      mru [maxdepth count | maxmem kilobytes | mindepth count | maxage seconds | initalloc count | initmem kilobytes | incalloc count | incmem kilobytes]
      +
      Controls size limits of the monitoring facility Most Recently Used (MRU) list of client addresses, which is also used by the rate control facility. +
      +
      maxdepth count
      + maxmem kilobytes
      +
      Equivalent upper limits on the size of the MRU list, in terms of entries or kilobytes. The actual limit will be up to incalloc entries or incmem kilobytes larger. As with all + of the mru options offered in units of entries or kilobytes, if both maxdepth and maxmem are used, the last one used controls. The default is 1024 kilobytes.
      +
      mindepth count
      +
      Lower limit on the MRU list size. When the MRU list has fewer than mindepth entries, existing entries are never removed to make room for newer ones, regardless of their age. + The default is 600 entries.
      +
      maxage seconds
      +
      Once the MRU list has mindepth entries and an additional client address is to be added to the list, if the oldest entry was updated more than maxage seconds ago, that entry + is removed and its storage reused. If the oldest entry was updated more recently, the MRU list + is grown, subject to maxdepth/maxmem. The default is 64 seconds.
      +
      initalloc count
      + initmem kilobytes
      +
      Initial memory allocation at the time the monitoring facility is first enabled, in terms of entries or kilobytes. The default is 4 kilobytes.
      +
      incalloc count
      + incmem kilobytes
      +
      Size of additional memory allocations when growing the MRU list, in entries or kilobytes. The default is 4 kilobytes.
      +
      +
      +
      nonvolatile threshold
      +
      Specify the threshold in seconds to write the frequency file, with default of 1e-7 (0.1 PPM). The frequency file is inspected each hour. If the difference between the current frequency and the last value written exceeds the threshold, the file is written and the threshold becomes the new threshold value. If the threshold is not exceeded, it is reduced by half. This is intended to reduce the frequency of unnecessary file writes for embedded systems with nonvolatile memory.
      +
      phone dial ...
      +
      This command is used in conjunction with the ACTS modem driver (type 18). The arguments consist of a maximum of 10 telephone numbers used to dial USNO, NIST or European time services. The Hayes command ATDT is normally prepended to the number, which can contain other modem control codes as well.
      +
      reset [allpeers] [auth] [ctl] [io] [mem] [sys] [timer]
      +
      Reset one or more groups of counters maintained by ntpd and exposed by ntpq and ntpdc.
      +
      rlimit [memlock Nmegabytes | stacksize N4kPages | filenum Nfiledescriptors]
      +
      This command alters certain process storage allocation limits, and is only available on some operating systems. Options are as follows:
      +
      +
      +
      memlock Nmegabytes
      +
      Specify the number of megabytes of memory that should be allocated and locked. Probably only available under Linux, this option may be useful when dropping root (the -i option). The default is 32 megabytes on non-Linux machines, and -1 under Linux. -1 means "do not lock the process into memory". 0 means "lock whatever memory the process wants into memory".
      +
      stacksize N4kPages
      +
      Specifies the maximum size of the process stack on systems with the mlockall() function. Defaults to 50 4k pages (200 4k pages in OpenBSD).
      +
      filenum Nfiledescriptors
      +
      Specifies the maximum number of file descriptors ntp may have open at the same time. Defaults to system default.
      +
      +
      +
      saveconfigdir directory_path
      +
      Specify the directory in which to write configuration snapshots requested with ntpq's saveconfig command. If saveconfigdir does not appear in the configuration file, saveconfig requests are rejected by ntpd.
      +
      setvar variable [default]
      +
      This command adds an additional system variable. These variables can be used to distribute additional information such as the access policy. If the variable of the form name = value is followed by the default keyword, the variable will be listed as part of the default system variables (ntpq rv command). These additional variables serve informational purposes only. They are not related to the protocol other that they can be listed. The known protocol variables will always override any variables defined via the setvar mechanism. There are three special variables that contain the names of all variable of the same group. The sys_var_list holds the names of all system variables. The peer_var_list holds the names of all peer variables and the clock_var_list holds the names of the reference clock variables.
      +
      tinker [allan allan | dispersion dispersion | freq freq | huffpuff huffpuff | panic panic | step step | stepout stepout]
      +
      This command alters certain system variables used by the clock discipline algorithm. The default values of these variables have been carefully optimized for a wide range of network speeds and reliability expectations. Very rarely is it necessary to change the default values; but, some folks can't resist twisting the knobs. Options are as follows:
      +
      +
      +
      allan allan
      +
      Specifies the Allan intercept, which is a parameter of the PLL/FLL clock discipline algorithm, in seconds with default 1500 s.
      +
      dispersion dispersion
      +
      Specifies the dispersion increase rate in parts-per-million (PPM) with default 15 PPM.
      +
      freq freq
      +
      Specifies the frequency offset in parts-per-million (PPM). This option is mutually exclusive with the driftfile command.
      +
      huffpuff huffpuff
      +
      Specifies the huff-n'-puff filter span, which determines the most recent interval the algorithm will search for a minimum delay. The lower limit is 900 s (15 min), but a more reasonable value is 7200 (2 hours).See the Huff-n'-Puff Filter page for further information.
      +
      panic panic
      +
      Specifies the panic threshold in seconds with default 1000 s. If set to zero, the panic sanity check is disabled and a clock offset of any value will be accepted.
      +
      step step
      +
      Specifies the step threshold in seconds. The default without this command is 0.128 s. If set to zero, step adjustments will never occur. Note: The kernel time discipline is disabled if the step threshold is set to zero or greater than 0.5 + s. Further details are on the Clock State Machine page.
      +
      stepout stepout
      +
      Specifies the stepout threshold in seconds. The default without this command is 300 s. Since this option also affects the training and startup intervals, it should not be set less than the default. Further details are on the Clock State Machine page.
      +
      +
      +
      tos [beacon beacon | ceiling ceiling | cohort {0 | 1} | floor floor | maxclock maxclock | maxdist maxdist | minclock minclock | mindist mindist | minsane minsane | orphan stratum | orphanwait delay]
      +
      This command alters certain system variables used by the the clock selection and clustering algorithms. The default values of these variables have been carefully optimized for a wide range of network speeds and reliability expectations. Very rarely is it necessary to change the default values; but, some folks can't resist twisting the knobs. It can be used to select the quality and quantity of peers used to synchronize the system clock and is most useful in dynamic server discovery schemes. The options are as follows:
      +
      +
      +
      beacon beacon
      +
      The manycast server sends packets at intervals of 64 s if less than maxclock servers are available. Otherwise, it sends packets at the beacon interval in seconds. The default is 3600 s. See the Automatic Server Discovery page for further details.
      +
      ceiling ceiling
      +
      Specify the maximum stratum (exclusive) for acceptable server packets. The default is 16. See the Automatic Server Discovery page for further details.
      +
      cohort { 0 | 1 }
      +
      Specify whether (1) or whether not (0) a server packet will be accepted for the same stratum as the client. The default is 0. See the Automatic Server Discovery page for further details.
      +
      floor floor
      +
      Specify the minimum stratum (inclusive) for acceptable server packets. The default is 1. See the Automatic Server Discovery page for further details.
      +
      maxclock maxclock
      +
      Specify the maximum number of servers retained by the server discovery schemes. The default is 10. See the Automatic Server Discovery page for further details.
      +
      maxdist maxdistance
      +
      Specify the synchronization distance threshold used by the clock selection algorithm. The default is 1.5 s. This determines both the minimum number of packets to set the system clock and the maximum roundtrip delay. It can be decreased to improve reliability or increased to synchronize clocks on the Moon or planets.
      +
      minclock minclock
      +
      Specify the number of servers used by the clustering algorithm as the minimum to include on the candidate list. The default is 3. This is also the number of servers to be averaged by the combining algorithm.
      +
      mindist mindistance
      +
      Specify the minimum distance used by the selection and anticlockhop + algorithm. Larger values increase the tolerance for outliers; + smaller values increase the selectivity. The default is .001 s. In some + cases, such as reference clocks with high jitter and a PPS signal, it is + useful to increase the value to insure the intersection interval is + always nonempty.
      +
      minsane minsane
      +
      Specify the number of servers used by the selection algorithm as the minimum to set the system clock. The default is 1 for legacy purposes; however, for critical applications the value should be somewhat higher but less than minclock.
      +
      orphan stratum
      +
      Specify the orphan stratum with default 16. If less than 16 this is the stratum assumed by the root servers. See the Orphan Mode page for further details.
      +
      orphanwait delay
      +
      Specify the delay in seconds from the time all sources are lost until orphan parent mode is enabled with default 300 s (five minutes). During this period, the local clock driver and the modem driver are not selectable, unless marked with the prefer keyword. This allows time for one or more primary sources to become reachable and selectable before using backup sources, and avoids transient use of the backup sources at startup.
      +
      +
      +
      trap host_address [port port_number] [interface interfSace_address]
      +
      This command configures a trap receiver at the given host address and port number for sending messages with the specified local interface address. If the port number is unspecified, a value of 18447 is used. If the interface address is not specified, the message is sent with a source address of the local interface the message is sent through. Note that on a multihomed host the interface used may vary from time to time with routing changes.
      +
      The trap receiver will generally log event messages and other information from the server in a log file. While such monitor programs may also request their own trap dynamically, configuring a trap receiver will ensure that no messages are lost when the server is started.
      +
      ttl hop ...
      +
      This command specifies a list of TTL values in increasing order. up to 8 values can be specified. In manycast mode these values are used in turn in an expanding-ring search. The default is eight multiples of 32 starting at 31.
      +
      +
      + + diff --git a/contrib/ntp/html/monopt.html b/contrib/ntp/html/monopt.html index a4c073a24..acf48473a 100644 --- a/contrib/ntp/html/monopt.html +++ b/contrib/ntp/html/monopt.html @@ -1,132 +1,566 @@ - - - - - - Monitoring Options - - - - -

      Monitoring Options

      - giffrom Pogo, Walt Kelly -

      The pig watches the logs.

      -

      Last update: 00:40 UTC Sunday, December 24, 2006

      -
      -

      Related Links

      - -
      - ntpd includes a comprehensive monitoring facility suitable for continuous, long term recording of server and client timekeeping performance. See the statistics command below for a listing and example of each type of statistics currently supported. Statistic files are managed using file generation sets and scripts in the ./scripts directory of this distribution. Using these facilities and Unix cron jobs, the datacan be automatically summarized and archived for retrospective analysis. -

      Monitoring Commands

      -
      -
      statistics name [...] -
      Enables writing of statistics records. Currently, six kinds of namestatistics are supported. -
      -
      clockstats -
      Enables recording of clock driver statistics information. Each update received from a clock driver appends a line of the following form to the file generation set named clockstats: -
      49213 525.624 127.127.4.1 93 226 00:08:29.606 D -
      The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next field shows the clock address in dotted-quad notation, The final field shows the last timecode received from the clock in decoded ASCII format, where meaningful. In some clock drivers a good deal of additional information can be gathered and displayed as well. See information specific to each clock for further details. -
      cryptostats -
      This option requires the OpenSSL cryptographic software library. It enables recording of cryptographic public key protocol information. Each message received by the protocol module appends a line of the following form to the file generation set named cryptostats: -
      49213 525.624 127.127.4.1 message -
      The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next field shows the peer address in dotted-quad notation, The final message field includes the message type and certain ancillary information. See the Authentication Options page for further information. -
      loopstats -
      Enables recording of loop filter statistics information. Each update of the local clock outputs a line of the following form to the file generation set named loopstats: -
      50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 6 -
      The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next five fields show time offset (seconds), frequency offset (parts per million - PPM), RMS jitter (seconds), Allan deviation (PPM) and clock discipline time constant. -
      peerstats -
      Enables recording of peer statistics information. This includes statistics records of all peers of a NTP server and of special signals, where present and configured. Each valid update appends a line of the following form to the current element of a file generation set named peerstats: -
      48773 10847.650 127.127.4.1 9714 -0.001605376 0.000000000 0.001424877 0.000958674 -
      The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next two fields show the peer address in dotted-quad notation and status, respectively. The status field is encoded in hex in the format described in Appendix B of the NTP specification RFC 1305. The final four fields show the offset, delay, dispersion and RMS jitter, all in seconds. -
      rawstats -
      Enables recording of raw-timestamp statistics information. This includes statistics records of all peers of a NTP server and of special signals, where present and configured. Each NTP message received from a peer or clock driver appends a line of the following form to the file generation set named rawstats: -
      50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 -
      The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next two fields show the remote peer or clock address followed by the local address in dotted-quad notation, The final four fields show the originate, receive, transmit and final NTP timestamps in order. The timestamp values are as received and before processing by the various data smoothing and mitigation algorithms. -
      sysstats -
      Enables recording of ntpd statistics counters on a periodic basis. Each hour a line of the following form is appended to the file generation set named sysstats: -
      50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 -
      The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The remaining ten fields show the statistics counter values accumulated since the last generated line. -
      -
      Time since restart 36000 -
      Time in hours since the system was last rebooted. -
      Packets received 81965 -
      Total number of packets received. -
      Packets processed 0 -
      Number of packets received in response to previous packets sent -
      Current version 9546 -
      Number of packets matching the current NTP version. -
      Previous version 56 -
      Number of packets matching the previous NTP version. -
      Bad version 71793 -
      Number of packets matching neither NTP version. -
      Access denied 512 -
      Number of packets denied access for any reason. -
      Bad length or format 540 -
      Number of packets with invalid length, format or port number. -
      Bad authentication 10 -
      Number of packets not verified as authentic. -
      Rate exceeded 147 -
      Number of packets discarded due to rate limitation. -
      -
      timingstats -
      ONLY available when the deamon is compiled with process time debugging support (--enable-debug-timing - costs performance). Enables recording of ntpd processing time information for various selected code paths: -
      53876 36.920 10.0.3.5 1 0.000014592 input processing delay -
      The first two fields show the date (Modified Julian Day) and time (seconds and fraction past UTC midnight). The next field is a potential peer address, - or -REFCLOCK- depending on the associated io source. Then an event count for the number of processed events in the code path follows. The fifth field is the total time spend for the events. The rest of the line denotes the code path description (see source for more information). -
      statsdir directory_path -
      Indicates the full path of a directory where statistics files should be created (see below). This keyword allows the (otherwise constant) filegen filename prefix to be modified for file generation sets, which is useful for handling statistics logs. -
      filegen name [file filename] [type typename] [link | nolink] [enable | disable] -
      Configures setting of generation file set name. Generation file sets provide a means for handling files that are continuously growing during the lifetime of a server. Server statistics are a typical example for such files. Generation file sets provide access to a set of files used to store the actual data. At any time at most one element of the set is being written to. The type given specifies when and how data will be directed to a new element of the set. This way, information stored in elements of a file set that are currently unused are available for administrational operations without the risk of disturbing the operation of ntpd. (Most important: they can be removed to free space for new data produced.) -
      Note that this command can be sent from the ntpdc program running at a remote location. -
      -
      name -
      This is the type of the statistics records, as shown in the statistics command. -
      -
      file filename -
      -
      This is the file name for the statistics records. Filenames of set members are built from three concatenated elements prefix, filename and suffix: -
      -
      prefix -
      This is a constant filename path. It is not subject to modifications via the filegen option. It is defined by the server, usually specified as a compile-time constant. It may, however, be configurable for individual file generation sets via other commands. For example, the prefix used with loopstats and peerstats generation can be configured using the statsdir option explained above. -
      filename -
      This string is directly concatenated to the prefix mentioned above (no intervening / (slash)). This can be modified using the file argument to the filegen statement. No .. elements are allowed in this component to prevent filenames referring to parts outside the filesystem hierarchy denoted by prefix. -
      suffix -
      This part is reflects individual elements of a file set. It is generated according to the type of a file set. -
      -
      -
      type typename -
      -
      A file generation set is characterized by its type. The following types are supported: -
      -
      none -
      The file set is actually a single plain file. -
      pid -
      One element of file set is used per incarnation of a ntpd server. This type does not perform any changes to file set members during runtime, however it provides an easy way of separating files belonging to different ntpd server incarnations. The set member filename is built by appending a . (dot) to concatenated prefix and filename strings, and appending the decimal representation of the process ID of the ntpd server process. -
      day -
      One file generation set element is created per day. A day is defined as the period between 00:00 and 24:00 UTC. The file set member suffix consists of a . (dot) and a day specification in the form YYYYMMdd. YYYY is a 4-digit year number (e.g., 1992). MM is a two digit month number. dd is a two digit day number. Thus, all information written at 10 December 1992 would end up in a file named prefix filename.19921210. -
      week -
      Any file set member contains data related to a certain week of a year. The term week is defined by computing day-of-year modulo 7. Elements of such a file generation set are distinguished by appending the following suffix to the file set filename base: A dot, a 4-digit year number, the letter W, and a 2-digit week number. For example, information from January, 10th 1992 would end up in a file with suffix .1992W1. -
      month -
      One generation file set element is generated per month. The file name suffix consists of a dot, a 4-digit year number, and a 2-digit month. -
      year -
      One generation file element is generated per year. The filename suffix consists of a dot and a 4 digit year number. -
      age -
      This type of file generation sets changes to a new element of the file set every 24 hours of server operation. The filename suffix consists of a dot, the letter a, and an 8-digit number. This number is taken to be the number of seconds the server is running at the start of the corresponding 24-hour period. Information is only written to a file generation by specifying enable; output is prevented by specifying disable. -
      -
      -
      link | nolink -
      -
      It is convenient to be able to access the current element of a file generation set by a fixed name. This feature is enabled by specifying link and disabled using nolink. If link is specified, a hard link from the current file set element to a file without suffix is created. When there is already a file with this name and the number of links of this file is one, it is renamed appending a dot, the letter C, and the pid of the ntpd server process. When the number of links is greater than one, the file is unlinked. This allows the current file to be accessed by a constant name. -
      -
      enable | disable -
      -
      Enables or disables the recording function. -
      -
      -
      - -
      - - + + + +Monitoring Options + + + +

      Monitoring Commands and Options

      +gif from Pogo, Walt Kelly +

      Pig was hired to watch the logs.

      +

      Last update: + 31-Jan-2014 06:54 + UTC

      +
      +

      Related Links

      + + +

      Table of Contents

      + +
      +

      Naming Conventions

      +

      The ntpd includes a comprehensive monitoring facility which collects + statistical data of various types and writes the data to files associated with + each type at defined events or intervals. The files associated with a particular + type are collectively called the generation file set for that type. The files + in the file set are the members of that set.

      +

      File sets have names specific to the type and generation epoch. The names + are constructed from three concatenated elements prefix, filename and suffix:

      +
      +
      prefix
      +
      The directory path specified in the statsdir command.
      +
      name
      +
      The name specified by the file option of the filegen command.
      +
      suffix
      +
      A string of elements bdginning with . (dot) followed by a number of elements + depending on the file set type.
      +
      +

      Statistics files can be managed using scripts, examples of which are in the ./scripts directory. + Using these or similar scripts and Unix cron jobs, the files can be + automatically summarized and archived for retrospective analysis.

      +

      Monitoring Commands and Options

      +

      Unless noted otherwise, further information about these commands is on the Event Messages and Status Codes page.

      page.

      +
      filegen name [file filename] [type type] + [link | nolink] [enable | disable]
      +
      +
      +
      name
      +
      Specifies the file set type from the list in the next section.
      +
      file filename
      +
      Specifies the filename prefix. The default is the file set type, such as "loopstats".
      +
      type typename
      +
      Specifies the file set interval. The following intervals are supported + with default day:
      +
      +
      +
      none
      +
      The file set is actually a single plain file.
      +
      pid
      +
      One file set member is created for every incarnation of ntpd. + The file name suffix is the string .n, where n is the + process ID of the ntpd server process.
      +
      day
      +
      One file set member is created per day. A day is defined as the period + between 00:00 and 23:59 UTC. The file name suffix is the string .yyyymmdd, + where yyyy is the year, mm the month of the year and dd the + day of the month. Thus, member created on 10 December 1992 would have suffix .19921210.
      +
      week
      +
      One file set member is created per week. The week is defined as the + day of year modulo 7. The file name suffix is the string .yyyyWww, + where yyyy is the year, W stands for itself and ww the + week number starting from 0. For example, The member created on 10 January + 1992 would have suffix .1992W1.
      +
      month
      +
      One file set member is created per month. The file name suffix is the + string .yyyymm, where yyyy is the year and mm the + month of the year starting from 1. For example, The member created on 10 + January 1992 would have suffix .199201.
      +
      year
      +
      One file set member is generated per year. The file name suffix is the + string .yyyy, where yyyy is the year. For example, The + member created on 1 January 1992 would have suffix .1992.
      +
      age
      +
      One file set member is generated every 24 hours of ntpd operation. + The filename suffix is the string .adddddddd, where a stands + for itself and dddddddd is the ntpd running time in seconds + at the start of the corresponding 24-hour period.
      +
      +
      +
      link | nolink
      +
      It is convenient to be able to access the current file set members by + file name, but without the suffix. This feature is enabled by link and + disabled by nolink. If enabled, which is the default, a hard link + from the current file set member to a file without suffix is created. When + there is already a file with this name and the number of links to this file + is one, it is renamed by appending a dot, the letter C, and the + pid of the ntpd server process. When the number of links is greater + than one, the file is unlinked. This allows the current file to be accessed + by a constant name.
      +
      enable | disable
      +
      Enable or disable the recording function, with default enable. + These options are intended for remote configuration commands.
      +
      +
      +
      statistics name...
      +
      Enables writing of statistics records. Currently, eight kinds of + statistics are supported: names specify the file set type(s) from + the list in the next section.
      +
      statsdir directory_path
      +
      Specify the directory path prefix for statistics file names.
      +
      +

      File Set Types

      +
      +
      clockstats
      +
      Record reference clock statistics. Each update received from a reference + clock driver appends one line to the clockstats file set:
      +
      49213 525.624 127.127.4.1 93 226 00:08:29.606 D
      +
      +
      Product Area Bundled Network
      Product
      + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      49213MJDdate
      525.624stime past midnight
      127.127.4.1IPreference clock address
      messagetextlog message
      + +
      The message field includes the last timecode received in + decoded ASCII format, where meaningful. In some cases a good deal of additional + information is displayed. See information specific to each reference clock + for further details.
      +
      cryptostats
      +
      Record significant events in the Autokey protocol. This option requires + the OpenSSL cryptographic software library. Each event appends one line to + the cryptostats file set:
      +
      49213 525.624 128.4.1.1 message
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      49213MJDdate
      525.624stime past midnight
      128.4.1.1IPsource address (0.0.0.0 for system)
      messagetextlog message
      +
      +
      The message field includes the message type and certain + ancillary information. See the Authentication Options page + for further information.
      +
      loopstats
      +
      Record clock discipline loop statistics. Each system clock update appends + one line to the loopstats file set:
      +
      50935 75440.031 0.000006019 13.778 0.000351733 0.013380 6
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      50935MJDdate
      75440.031stime past midnight
      0.000006019sclock offset
      13.778PPMfrequency offset
      0.000351733sRMS jitter
      0.013380PPMRMS frequency jitter (aka wander)
      6 log2 sclock discipline loop time constant
      +
      +
      peerstats
      +
      Record peer statistics. Each NTP packet or reference clock update received + appends one line to the peerstats file set:
      +
      48773 10847.650 127.127.4.1 9714 -0.001605376 0.000000000 0.001424877 + 0.000958674
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      48773MJDdate
      10847.650stime past midnight
      127.127.4.1IPsource address
      9714hexstatus word
      -0.001605376sclock offset
      0.000000000 sroundtrip delay
      0.001424877sdispersion
      0.000958674sRMS jitter
      +
      +
      The status field is encoded in hex format as described in Appendix B of + the NTP specification RFC 1305.
      +
      protostats
      +
      Record significant peer, system and [rptpcp; events. Each significant event + appends one line to the protostats file set:
      +
      49213 525.624 128.4.1.1 963a 8a message
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      49213MJDdate
      525.624stime past midnight
      128.4.1.1IPsource address (0.0.0.0 for system)
      963acodestatus word
      8acodeevent message code
      messagetextevent message
      +
      +
      The event message code and message field are described on + the Event Messages and Status Words page.
      +
      rawstats
      +
      Record timestamp statistics. Each NTP packet received appends one line to + the rawstats file set:
      +
      56285 54575.160 128.4.1.1 192.168.1.5 3565350574.400229473 3565350574.442385200 3565350574.442436000 3565350575.154505763 0 4 4 1 8 -21 0.000000 0.000320 .PPS.
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      56285MJDdate
      54575.160stime past midnight
      128.4.1.1IPsource address
      192.168.1.5IPdestination address
      3565350574.400229473NTP sorigin timestamp
      3565350574.442385200NTP sreceive timestamp
      3565350574.442436000NTP stransmit timestamp
      3565350575.154505763NTP sdestination timestamp
      00: OK, 1: insert pending,
      2: delete pending, 3: not synced
      leap warning indicator
      44 was current in 2012NTP version
      43: client, 4: server, 5: broadcastmode
      11-15, 16: not syncedstratum
      8log2 secondspoll
      -21log2 secondsprecision
      0.000000secondstotal roundtrip delay to the primary reference clock
      0.000320secondstotal dispersion to the primary reference clock
      PPS.IP or textrefid, association ID
      +
      +
      sysstats
      +
      Record system statistics. Each hour one line is appended to the sysstats file + set in the following format:
      +
      50928 2132.543 3600 81965 0 9546 56 512 540 10 4 147 1
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      50928MJDdate
      2132.543stime past midnight
      3600stime since reset
      81965#packets received
      0#packets for this host
      9546#current versions
      56#old version
      512#access denied
      540#bad length or format
      10#bad authentication
      4#declined
      147#rate exceeded
      1#kiss-o'-death packets sent
      +
      +
      timingstats
      +
      (Only available when the deamon is compiled with process time debugging + support (--enable-debug-timing - costs performance). Record processing time + statistics for various selected code paths.
      +
      53876 36.920 10.0.3.5 1 0.000014592 input processing delay
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ItemUnitsDescription
      53876MJDdate
      36.920stime past midnight
      10.0.3.5IPserver address
      1#event count
      0.000014592stotal time
      messagetextcode path description (see source)
      +
      + +
      + + diff --git a/contrib/ntp/html/msyslog.html b/contrib/ntp/html/msyslog.html index 9e03cf821..affa088a3 100644 --- a/contrib/ntp/html/msyslog.html +++ b/contrib/ntp/html/msyslog.html @@ -1,122 +1,129 @@ - - - - ntpd System Log Messages - - - -

      ntpd System Log Messages

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      The mushroom knows all the error codes, which is more than most of us do.

      -

      Last update: 19:24 UTC Saturday, October 01, 2005

      -
      -

      Related Links

      -

      -

      -
      -

      You have come here because you found a cryptic message in the system log. This page by no means lists all messages that might be found, since new ones come and old ones go. Generally, however, the most common ones will be found here. They are listed by program module and log severity code in bold: LOG_ERR, LOG_NOTICE and LOG_INFO.

      -

      Most of the time LOG_ERR messages are fatal, but often ntpd limps onward in the hopes of discovering more errors. The LOG_NOTICE messages usually mean the time has changed or some other condition that probably should be noticed. The LOG_INFO messages usually say something about the system operations, but do not affect the time.

      -

      In the following a '?' character stands for text in the message. The meaning should be clear from context.

      -

      Protocol Module

      -

      LOG_ERR

      -
      -
      buffer overflow ? - -
      Fatal error. An input packet is too long for processing. -
      -

      LOG_NOTICE

      -
      -
      no reply; clock not set -
      In ntpdate mode no servers have been found. The server(s) and/or network may be down. Standard debugging procedures apply. -

      LOG_INFO

      -
      proto_config: illegal item ?, value ? -
      Program error. Please report to bugs@ntp.org. -
      pps sync enabled -
      The PPS signal has been detected and enabled. -
      transmit: encryption key ? not found -
      The encryption key is not defined or not trusted. -
      precision = ? usec -
      This reports the precision measured for this machine. -
      using 10ms tick adjustments -
      Gotcha for some machines with dirty rotten clock hardware. -
      no servers reachable -
      The system clock is running on internal batteries. The server(s) and/or network may be down. -
      -

      Clock Discipline Module

      -

      LOG_ERR

      -
      -
      time correction of ? seconds exceeds sanity limit (?); set clock manually to the correct UTC time. -
      Fatal error. Better do what it says, then restart the daemon. Be advised NTP and Unix know nothing about local time zones. The clock must be set to Coordinated Universal Time (UTC). Believe it; by international agreement abbreviations are in French and descriptions are in English. -
      sigaction() fails to save SIGSYS trap: ?
      -
      sigaction() fails to restore SIGSYS trap: ? -
      Program error. Please report to bugs@ntp.org. -
      -

      LOG_NOTICE

      -
      -
      frequency error ? exceeds tolerance 500 PPM -
      The hardware clock frequency error exceeds the rate the kernel can correct. This could be a hardware or a kernel problem. -
      time slew ? s -
      The time error exceeds the step threshold and is being slewed to the correct time. You may have to wait a very long time. -
      time reset ? s -
      The time error exceeds the step threshold and has been reset to the correct time. Computer scientists don't like this, but they can set the ntpd -x option and wait forever. -
      kernel time sync disabled ? -
      The kernel reports an error. See the codes in the timex.h file. -
      pps sync disabled -
      The PPS signal has died, probably due to a dead radio, broken wire or loose connector. -
      -

      LOG_INFO

      -
      -
      kernel time sync status ? -
      For information only. See the codes in the timex.h file. -
      -

      Cryptographic Module

      -

      LOG_ERR

      -
      -
      cert_parse ?
      -
      cert_sign ?
      -
      crypto_cert ?
      -
      crypto_encrypt ?
      -
      crypto_gq ?
      -
      crypto_iff ?
      -
      crypto_key ?
      -
      crypto_mv ?
      -
      crypto_setup ?
      -
      make_keys ? -
      Usually fatal errors. These messages display error codes returned from the OpenSSL library. See the OpenSSL documentation for explanation. -
      crypto_setup: certificate ? is trusted, but not self signed.
      -
      crypto_setup: certificate ? not for this host
      -
      crypto_setup: certificate file ? not found or corrupt
      -
      crypto_setup: host key file ? not found or corrupt
      -
      crypto_setup: host key is not RSA key type
      -
      crypto_setup: random seed file ? not found
      -
      rypto_setup: random seed file not specified -
      Fatal errors. These messages show problems during the initialization procedure. -
      -

      LOG_INFO

      -
      -
      cert_parse: expired ?
      -
      cert_parse: invalid issuer ?
      -
      cert_parse: invalid signature ?
      -
      cert_parse: invalid subject ? -
      There is a problem with a certificate. Operation cannot proceed untill the problem is fixed. If the certificate is local, it can be regenerated using the ntp-keygen program. If it is held somewhere else, it must be fixed by the holder. -
      crypto_?: defective key
      -
      crypto_?: invalid filestamp
      -
      crypto_?: missing challenge
      -
      crypto_?: scheme unavailable -
      There is a problem with the identity scheme. Operation cannot proceed untill the problem is fixed. Usually errors are due to misconfiguration or an orphan association. If the latter, ntpd will usually time out and recover by itself. -
      crypto_cert: wrong PEM type ? -
      The certificate does not have MIME type CERTIFICATE. You are probably using the wrong type from OpenSSL or an external certificate authority. -
      crypto_ident: no compatible identity scheme found -
      Configuration error. The server and client identity schemes are incompatible. -
      crypto_tai: kernel TAI update failed -
      The kernel does not support this function. You may need a new kernel or patch. -
      crypto_tai: leapseconds file ? error ? -
      The leapseconds file is corrupt. Obtain the latest file from time.nist.gov. -
      -
      - - - - \ No newline at end of file + + + +ntpd System Log Messages + + + +

      ntpd System Log Messages

      +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

      The log can be shrill at times.

      +

      Last update: + 10-Mar-2014 05:12 + UTC

      +
      +

      Related Links

      +

      + +

      +
      +

      You have come here because you found a cryptic message in the system log. This page by no means lists all messages that might be found, since new ones come and old ones go. Generally, however, the most common ones will be found here. They are listed by program module and log severity code in bold: LOG_ERR, LOG_NOTICE and LOG_INFO.

      +

      Most of the time LOG_ERR messages are fatal, but often ntpd limps onward in the hopes of discovering more errors. The LOG_NOTICE messages usually mean the time has changed or some other condition that probably should be noticed. The LOG_INFO messages usually say something about the system operations, but do not affect the time.

      +

      In the following a '?' character stands for text in the message. The meaning should be clear from context.

      +

      Protocol Module

      +

      LOG_ERR

      +
      +
      buffer overflow ?
      +
      Fatal error. An input packet is too long for processing.
      +
      +

      LOG_NOTICE

      +
      +
      no reply; clock not set
      +
      In ntpdate mode no servers have been found. The server(s) and/or network may be down. Standard debugging procedures apply.
      +
      +

      LOG_INFO

      +
      +
      proto_config: illegal item ?, value ?
      +
      Program error. Bugs can be reported here.
      +
      receive: autokey requires two-way communication
      +
      Configuration error on the broadcastclient command.
      +
      receive: server server maaximum rate exceeded
      +
      A kiss-o'death packet has been received. The transmit rate is automatically reduced.
      +
      pps sync enabled
      +
      The PPS signal has been detected and enabled.
      +
      transmit: encryption key ? not found
      +
      The encryption key is not defined or not trusted.
      +
      precision = ? usec
      +
      This reports the precision measured for this machine.
      +
      using 10ms tick adjustments
      +
      Gotcha for some machines with dirty rotten clock hardware.
      +
      no servers reachable
      +
      The system clock is running on internal batteries. The server(s) and/or network may be down.
      +
      +

      Clock Discipline Module

      +

      LOG_ERR

      +
      +
      time correction of ? seconds exceeds sanity limit (?); set clock manually to the correct UTC time.
      +
      Fatal error. Better do what it says, then restart the daemon. Be advised NTP and Unix know nothing about local time zones. The clock must be set to Coordinated Universal Time (UTC). Believe it; by international agreement abbreviations are in French and descriptions are in English.
      +
      sigaction() fails to save SIGSYS trap: ?
      +
      sigaction() fails to restore SIGSYS trap: ?
      +
      Program error. Bugs can be reported here.
      +
      +

      LOG_NOTICE

      +
      +
      frequency error ? exceeds tolerance 500 PPM
      +
      The hardware clock frequency error exceeds the rate the kernel can correct. This could be a hardware or a kernel problem.
      +
      time slew ? s
      +
      The time error exceeds the step threshold and is being slewed to the correct time. You may have to wait a very long time.
      +
      time reset ? s
      +
      The time error exceeds the step threshold and has been reset to the correct time. Computer scientists don't like this, but they can set the ntpd -x option and wait forever.
      +
      kernel time sync disabled ?
      +
      The kernel reports an error. See the codes in the timex.h file.
      +
      pps sync disabled
      +
      The PPS signal has died, probably due to a dead radio, broken wire or loose connector.
      +
      +

      LOG_INFO

      +
      +
      kernel time sync status ?
      +
      For information only. See the codes in the timex.h file.
      +
      +

      Cryptographic Module

      +

      LOG_ERR

      +
      +
      cert_parse ?
      +
      cert_sign ?
      +
      crypto_cert ?
      +
      crypto_encrypt ?
      +
      crypto_gq ?
      +
      crypto_iff ?
      +
      crypto_key ?
      +
      crypto_mv ?
      +
      crypto_setup ?
      +
      make_keys ?
      +
      Usually fatal errors. These messages display error codes returned from the OpenSSL library. See the OpenSSL documentation for explanation.
      +
      crypto_setup: certificate ? is trusted, but not self signed.
      +
      crypto_setup: certificate ? not for this host
      +
      crypto_setup: certificate file ? not found or corrupt
      +
      crypto_setup: host key file ? not found or corrupt
      +
      crypto_setup: host key is not RSA key type
      +
      crypto_setup: random seed file ? not found
      +
      rypto_setup: random seed file not specified
      +
      Fatal errors. These messages show problems during the initialization procedure.
      +
      +

      LOG_INFO

      +
      +
      cert_parse: expired ?
      +
      cert_parse: invalid issuer ?
      +
      cert_parse: invalid signature ?
      +
      cert_parse: invalid subject ?
      +
      There is a problem with a certificate. Operation cannot proceed untill the problem is fixed. If the certificate is local, it can be regenerated using the ntp-keygen program. If it is held somewhere else, it must be fixed by the holder.
      +
      crypto_?: defective key
      +
      crypto_?: invalid filestamp
      +
      crypto_?: missing challenge
      +
      crypto_?: scheme unavailable
      +
      There is a problem with the identity scheme. Operation cannot proceed untill the problem is fixed. Usually errors are due to misconfiguration or an orphan association. If the latter, ntpd will usually time out and recover by itself.
      +
      crypto_cert: wrong PEM type ?
      +
      The certificate does not have MIME type CERTIFICATE. You are probably using the wrong type from OpenSSL or an external certificate authority.
      +
      crypto_ident: no compatible identity scheme found
      +
      Configuration error. The server and client identity schemes are incompatible.
      +
      crypto_tai: kernel TAI update failed
      +
      The kernel does not support this function. You may need a new kernel or patch.
      +
      crypto_tai: leapseconds file ? error ?
      +
      The leapseconds file is corrupt. Obtain the latest file from time.nist.gov.
      +
      +
      + + + diff --git a/contrib/ntp/html/notes.html b/contrib/ntp/html/notes.html deleted file mode 100644 index e757dbd83..000000000 --- a/contrib/ntp/html/notes.html +++ /dev/null @@ -1,280 +0,0 @@ - - - - - - - - Notes on setting up a NTP subnet - - - - -

      Notes on setting up a NTP subnet

      - gifFrom NBS Special Publication 432 (out of print) -

      Last update: 18:44 UTC Thursday, July 28, 2005

      -
      -
      -

      Introduction

      -

      This document is a collection of notes concerning the use of ntpd and related programs, and on coping with the Network Time Protocol (NTP) in general. It is a major rewrite and update of an earlier document written by Dennis Ferguson of the University of Toronto and includes many changes and additions resulting from the NTP Version 3 specification and new Version 4 implementation features. It supersedes earlier documents, which should no longer be used for new configurations.

      -

      ntpd includes a complete implementation of the NTP Version 3 specification, as defined in:

      -
        -
      • Mills, D.L. Network Time Protocol (Version 3) specification, implementation and analysis. Network Working Group Report RFC-1305, University of Delaware, March 1992, 113 pp. Abstract: PostScript | PDF, Body: PostScript | PDF, Appendices: PostScript | PDF -
      -

      Additional features have are described for NTP Version 4 Release Notes. It also retains compatibility with both NTP Version 2, as defined in RFC-1119, and NTP Version 1, as defined in RFC-1059, although this compatibility is sometimes strained and only semiautomatic. In order to support in principle the ultimate precision of about 232 picoseconds in the NTP specification, ntpd uses NTP timestamp format for external communication and double precision floating point arithmetic internally. ntpd fully implements NTP Versions 2 and 3 authentication and in addition Version 4 autokey. It supports the NTP mode-6 control message facility along with a private mode-7 control- message facility used to remotely reconfigure the system and monitor a considerable amount of internal detail. As extensions to the specification, a flexible address-and-mask restriction facility has been included.

      -

      The code is biased towards the needs of a busy time server with numerous, often hundreds, of clients and other servers. Tables are hashed to allow efficient handling of many associations, though at the expense of additional overhead when the number of associations is small. Many fancy features have been included to permit efficient management and monitoring of a busy primary server, features which are probably excess baggage for a high stratum client. In such cases, a stripped-down version of the protocol, the Simple Network Time Protocol (SNTP) can be used. SNTP and NTP servers and clients can interwork in most situations, as described in: Mills, D.L. Simple Network Time Protocol (SNTP). Network Working Group Report RFC-2030, University of Delaware, October 1996, 14 pp. (ASCII).

      -

      The code was written with near demonic attention to details which can affect precision and as a consequence should be able to make good use of high performance, special purpose hardware such as precision oscillators and radio clocks. The present code supports a number of radio clocks, including those for the WWV, CHU, WWVB, MSF, DCF77, GOES and GPS radio and satellite time services and USNO, ACTS and PTB modem time services. It also supports the IRIG-B and IRIG-E signal format connected via an audio codec. The server methodically avoids the use of Unix-specific library routines where possible by implementing local versions, in order to aid in porting the code to perverse Unix and non-Unix platforms.

      -

      While this implementation conforms in most respects to the NTP Version 3 specification RFC-1305, a number of improvements have been made which are described in the conformance statement in the NTP Protocol Conformance Statement page. It has been specifically tuned to achieve the highest accuracy possible on whatever hardware and operating-system platform is available. In general, its precision and stability are limited only by the characteristics of the onboard clock source used by the hardware and operating system, usually an uncompensated crystal oscillator. On modern RISC-based processors connected directly to radio clocks via serial-asynchronous interfaces, the accuracy is usually limited by the radio clock and interface to the order of a millisecond or less. The code includes special features to support a pulse-per-second (PPS) signal and/or an IRIG-B signal generated by some radio clocks. When used in conjunction with a suitable hardware level converter, the accuracy can be improved to a few tens of microseconds. Further improvement is possible using an outboard, stabilized frequency source, in which the accuracy and stability are limited only by the characteristics of that source.

      -

      The NTP Version 4 distribution includes, in addition to the daemon itself (ntpd), several utility programs, including two remote-monitoring programs (ntpq, ntpdc), a remote clock-setting program similar to the Unix rdate program (ntpdate), a traceback utility useful to discover suitable synchronization sources (ntptrace), and various programs used to configure the local platform and calibrate the intrinsic errors. NTP has been ported to a large number of platforms, including most RISC and CISC workstations and mainframes manufactured today. Example configuration files for many models of these machines are included in the distribution. While in most cases the standard version of the implementation runs with no hardware or operating system modifications, not all features of the distribution are available on all platforms. For instance, a special feature allowing Sun workstations to achieve accuracies in the order of 100 microseconds requires some minor changes and additions to the kernel and input/output support.

      -

      There are, however, several drawbacks to all of this. ntpd is quite fat. This is rotten if your intended platform for the daemon is memory limited. ntpd uses SIGIO for all input, a facility which appears to not enjoy universal support and whose use seems to exercise the parts of your vendors' kernels which are most likely to have been done poorly. The code is unforgiving in the face of kernel problems which affect performance, and generally requires that you repair the problems in order to achieve acceptable performance. The code has a distinctly experimental flavour and contains features which could charitably be termed failed experiments, but which have not been completely hacked out. Much was learned from the addition of support for a variety of radio clocks, with the result that some radio clock drivers could use some rewriting.

      -

      How NTP Works

      -

      The approach used by NTP to achieve reliable time synchronization from a set of possibly unreliable remote time servers is somewhat different than other protocols. In particular, NTP does not attempt to synchronize clocks to each other. Rather, each server attempts to synchronize to Universal Coordinated Time (UTC) using the best available source and available transmission paths to that source. This is a fine point which is worth understanding. A group of NTP-synchronized clocks may be close to each other in time, but this is not a consequence of the clocks in the group having synchronized to each other, but rather because each clock has synchronized closely to UTC via the best source it has access to. As such, trying to synchronize a set of clocks to a set of servers whose time is not in mutual agreement may not result in any sort of useful synchronization of the clocks, even if you don't care about UTC. However, in networks isolated from UTC sources, provisions can made to nominate one of them as a phantom UTC source.

      -

      NTP operates on the premise that there is one true standard time, and that if several servers which claim synchronization to standard time disagree about what that time is, then one or more of them must be broken. There is no attempt to resolve differences more gracefully since the premise is that substantial differences cannot exist. In essence, NTP expects that the time being distributed from the root of the synchronization subnet will be derived from some external source of UTC (e.g., a radio clock). This makes it somewhat inconvenient (though by no means impossible) to synchronize hosts together without a reliable source of UTC to synchronize them to. If your network is isolated and you cannot access other people's servers across the Internet, a radio clock may make a good investment.

      -

      Time is distributed through a hierarchy of NTP servers, with each server adopting a stratum which indicates how far away from an external source of UTC it is operating at. Stratum-1 servers, which are at the top of the pile (or bottom, depending on your point of view), have access to some external time source, usually a radio clock synchronized to time signal broadcasts from radio stations which explicitly provide a standard time service. A stratum-2 server is one which is currently obtaining time from a stratum-1 server, a stratum-3 server gets its time from a stratum-2 server, and so on. To avoid long lived synchronization loops the number of strata is limited to 15.

      -

      Each client in the synchronization subnet (which may also be a server for other, higher stratum clients) chooses exactly one of the available servers to synchronize to, usually from among the lowest stratum servers it has access to. This is, however, not always an optimal configuration, for indeed NTP operates under another premise as well, that each server's time should be viewed with a certain amount of distrust. NTP really prefers to have access to several sources of lower stratum time (at least three) since it can then apply an agreement algorithm to detect insanity on the part of any one of these. Normally, when all servers are in agreement, NTP will choose the best of these, where "best" is defined in terms of lowest stratum, closest (in terms of network delay) and claimed precision, along with several other considerations. The implication is that, while one should aim to provide each client with three or more sources of lower stratum time, several of these will only be providing backup service and may be of lesser quality in terms of network delay and stratum (i.e., a same-stratum peer which receives time from lower stratum sources the local server doesn't access directly can also provide good backup service).

      -

      Finally, there is the issue of association modes. There are a number of modes in which NTP servers can associate with each other, with the mode of each server in the pair indicating the behaviour the other server can expect from it. In particular, when configuring a server to obtain time from other servers, there is a choice of two modes which may be used. Configuring an association in symmetric-active mode (usually indicated by a peer declaration in the configuration file) indicates to the remote server that one wishes to obtain time from the remote server and that one is also willing to supply time to the remote server if need be. This mode is appropriate in configurations involving a number of redundant time servers interconnected via diverse network paths, which is presently the case for most stratum-1 and stratum-2 servers on the Internet today. Configuring an association in client mode (usually indicated by a server declaration in the configuration file) indicates that one wishes to obtain time from the remote server, but that one is not willing to provide time to the remote server. This mode is appropriate for file-server and workstation clients that do not provide synchronization to other local clients. Client mode is also useful for boot-date-setting programs and the like, which really have no time to provide and which don't retain state about associations over the longer term.

      -

      Where the requirements in accuracy and reliability are modest, clients can be configured to use broadcast and/or multicast modes. These modes are not normally utilized by servers with dependent clients. The advantage of these modes is that clients do not need to be configured for a specific server, so that all clients operating can use the same configuration file. Broadcast mode requires a broadcast server on the same subnet, while multicast mode requires support for IP multicast on the client machine, as well as connectivity via the MBONE to a multicast server. Since broadcast messages are not propagated by routers, only those broadcast servers on the same subnet will be used. There is at present no way to select which of possibly many multicast servers will be used, since all operate on the same group address.

      -

      Where the maximum accuracy and reliability provided by NTP are needed, clients and servers operate in either client/server or symmetric modes. Symmetric modes are most often used between two or more servers operating as a mutually redundant group. In these modes, the servers in the group members arrange the synchronization paths for maximum performance, depending on network jitter and propagation delay. If one or more of the group members fail, the remaining members automatically reconfigure as required. Dependent clients and servers normally operate in client/server mode, in which a client or dependent server can be synchronized to a group member, but no group member can synchronize to the client or dependent server. This provides protection against malfunctions or protocol attacks.

      -

      Servers that provide synchronization to a sizeable population of clients normally operate as a group of three or more mutually redundant servers, each operating with three or more stratum-one or stratum-two servers in client-server modes, as well as all other members of the group in symmetric modes. This provides protection against malfunctions in which one or more servers fail to operate or provide incorrect time. The NTP algorithms have been specifically engineered to resist attacks where some fraction of the configured synchronization sources accidently or purposely provide incorrect time. In these cases a special voting procedure is used to identify spurious sources and discard their data.

      -

      Configuring Your Subnet

      - At startup time the ntpd daemon running on a host reads the initial configuration information from a file, usually /etc/ntp.conf, unless a different name has been specified at compile time. Putting something in this file which will enable the host to obtain time from somewhere else is usually the first big hurdle after installation of the software itself, which is described in the Building and Installing the Distribution page. At its simplest, what you need to do in the configuration file is declare the servers that the daemon should poll for time synchronization. In principle, no such list is needed if some other time server operating in broadcast/multicast mode is available, which requires the client to operate in a broadcastclient mode. -

      In the case of a workstation operating in an enterprise network for a public or private organization, there is often an administrative department that coordinates network services, including NTP. Where available, the addresses of appropriate servers can be provided by that department. However, if this infrastructure is not available, it is necessary to explore some portion of the existing NTP subnet now running in the Internet. There are at present many thousands of time servers running NTP in the Internet, a significant number of which are willing to provide a public time- synchronization service. Some of these are listed in the list of public time servers, which can be accessed via the NTP web page. These data are updated on a regular basis using information provided voluntarily by various site administrators. There are other ways to explore the nearby subnet using the ntptrace and ntpdc programs.

      -

      It is vital to carefully consider the issues of robustness and reliability when selecting the sources of synchronization. Normally, not less than three sources should be available, preferably selected to avoid common points of failure. It is usually better to choose sources which are likely to be "close" to you in terms of network topology, though you shouldn't worry overly about this if you are unable to determine who is close and who isn't. Normally, it is much more serious when a server becomes faulty and delivers incorrect time than when it simply stops operating, since an NTP-synchronized host normally can coast for hours or even days without its clock accumulating serious error approaching a second, for instance. Selecting at least three sources from different operating administrations, where possible, is the minimum recommended, although a lesser number could provide acceptable service with a degraded degree of robustness.

      -

      Normally, it is not considered good practice for a single workstation to request synchronization from a primary (stratum-1) time server. At present, these servers provide synchronization for hundreds of clients in many cases and could, along with the network access paths, become seriously overloaded if large numbers of workstation clients requested synchronization directly. Therefore, workstations located in sparsely populated administrative domains with no local synchronization infrastructure should request synchronization from nearby stratum-2 servers instead. In most cases the keepers of those servers in the lists of public servers provide unrestricted access without prior permission; however, in all cases it is considered polite to notify the administrator listed in the file upon commencement of regular service. In all cases the access mode and notification requirements listed in the file must be respected. Under no conditions should servers not in these lists be used without prior permission, as to do so can create severe problems in the local infrastructure, especially in cases of dial-up access to the Internet.

      -

      In the case of a gateway or file server providing service to a significant number of workstations or file servers in an enterprise network it is even more important to provide multiple, redundant sources of synchronization and multiple, diversity-routed, network access paths. The preferred configuration is at least three administratively coordinated time servers providing service throughout the administrative domain including campus networks and subnetworks. Each of these should obtain service from at least two different outside sources of synchronization, preferably via different gateways and access paths. These sources should all operate at the same stratum level, which is one less than the stratum level to be used by the local time servers themselves. In addition, each of these time servers should peer with all of the other time servers in the local administrative domain at the stratum level used by the local time servers, as well as at least one (different) outside source at this level. This configuration results in the use of six outside sources at a lower stratum level (toward the primary source of synchronization, usually a radio clock), plus three outside sources at the same stratum level, for a total of nine outside sources of synchronization. While this may seem excessive, the actual load on network resources is minimal, since the interval between polling messages exchanged between peers usually ratchets back to no more than one message every 17 minutes.

      -

      The stratum level to be used by the local time servers is an engineering choice. As a matter of policy, and in order to reduce the load on the primary servers, it is desirable to use the highest stratum consistent with reliable, accurate time synchronization throughout the administrative domain. In the case of enterprise networks serving hundreds or thousands of client file servers and workstations, conventional practice is to obtain service from stratum-1 primary servers listed for public access. When choosing sources away from the primary sources, the particular synchronization path in use at any time can be verified using the ntptrace program included in this distribution. It is important to avoid loops and possible common points of failure when selecting these sources. Note that, while NTP detects and rejects loops involving neighboring servers, it does not detect loops involving intervening servers. In the unlikely case that all primary sources of synchronization are lost throughout the subnet, the remaining servers on that subnet can form temporary loops and, if the loss continues for an interval of many hours, the servers will drop off the subnet and free-run with respect to their internal (disciplined) timing sources. After some period with no outside timing source (currently one day), a host will declare itself unsynchronized and provide this information to local application programs.

      -

      In many cases the purchase of one or more radio clocks is justified, in which cases good engineering practice is to use the configurations described above anyway and connect the radio clock to one of the local servers. This server is then encouraged to participate in a special primary-server subnetwork in which each radio-equipped server peers with several other similarly equipped servers. In this way the radio-equipped server may provide synchronization, as well as receive synchronization, should the local or remote radio clock(s) fail or become faulty. ntpd treats attached radio clock(s) in the same way as other servers and applies the same criteria and algorithms to the time indications, so can detect when the radio fails or becomes faulty and switch to alternate sources of synchronization. It is strongly advised, and in practice for most primary servers today, to employ the authentication or access-control features of the NTP specification in order to protect against hostile intruders and possible destabilization of the time service. Using this or similar strategies, the remaining hosts in the same administrative domain can be synchronized to the three (or more) selected time servers. Assuming these servers are synchronized directly to stratum-1 sources and operate normally as stratum-2, the next level away from the primary source of synchronization, for instance various campus file servers, will operate at stratum 3 and dependent workstations at stratum 4. Engineered correctly, such a subnet will survive all but the most exotic failures or even hostile penetrations of the various, distributed timekeeping resources.

      -

      The above arrangement should provide very good, robust time service with a minimum of traffic to distant servers and with manageable loads on the local servers. While it is theoretically possible to extend the synchronization subnet to even higher strata, this is seldom justified and can make the maintenance of configuration files unmanageable. Serving time to a higher stratum peer is very inexpensive in terms of the load on the lower stratum server if the latter is located on the same concatenated LAN. When justified by the accuracy expectations, NTP can be operated in broadcast and multicast modes, so that clients need only listen for periodic broadcasts and do not need to send anything.

      -

      When planning your network you might, beyond this, keep in mind a few generic don'ts, in particular:

      -
        -
      • Don't synchronize a local time server to another peer at the same stratum, unless the latter is receiving time from lower stratum sources the former doesn't talk to directly. This minimizes the occurrence of common points of failure, but does not eliminate them in cases where the usual chain of associations to the primary sources of synchronization are disrupted due to failures. -

      • -
      • Don't configure peer associations with higher stratum servers. Let the higher strata configure lower stratum servers, but not the reverse. This greatly simplifies configuration file maintenance, since there is usually much greater configuration churn in the high stratum clients such as personal workstations. -

      • -
      • Don't synchronize more than one time server in a particular administrative domain to the same time server outside that domain. Such a practice invites common points of failure, as well as raises the possibility of massive abuse, should the configuration file be automatically distributed do a large number of clients. -
      - There are many useful exceptions to these rules. When in doubt, however, follow them. -

      Configuring Your Server or Client

      -

      As mentioned previously, the configuration file is usually called /etc/ntp.conf. This is an ASCII file conforming to the usual comment and whitespace conventions. A working configuration file might look like (in this and other examples, do not copy this directly):

      -
      -     # peer configuration for host whimsy
      -     # (expected to operate at stratum 2)
      -
      -     server rackety.udel.edu
      -     server umd1.umd.edu
      -     server lilben.tn.cornell.edu
      -
      -     driftfile /etc/ntp.drift
      -
      - (Note the use of host names, although host addresses in dotted-quad notation can also be used. It is always preferable to use names rather than addresses, since over time the addresses can change, while the names seldom change.) -

      This particular host is expected to operate as a client at stratum 2 by virtue of the server keyword and the fact that two of the three servers declared (the first two) have radio clocks and usually run at stratum 1. The third server in the list has no radio clock, but is known to maintain associations with a number of stratum 1 peers and usually operates at stratum 2. Of particular importance with the last host is that it maintains associations with peers besides the two stratum 1 peers mentioned. This can be verified using the ntpq program mentioned above. When configured using the server keyword, this host can receive synchronization from any of the listed servers, but can never provide synchronization to them.

      -

      Unless restricted using facilities described later, this host can provide synchronization to dependent clients, which do not have to be listed in the configuration file. Associations maintained for these clients are transitory and result in no persistent state in the host. These clients are normally not visible using the ntpq program included in the distribution; however, ntpd includes a monitoring feature (described later) which caches a minimal amount of client information useful for debugging administrative purposes.

      -

      A time server expected to both receive synchronization from another server, as well as to provide synchronization to it, is declared using the peer keyword instead of the server keyword. In all other aspects the server operates the same in either mode and can provide synchronization to dependent clients or other peers. If a local source of UTC time is available, it is considered good engineering practice to declare time servers outside the administrative domain as peer and those inside as server in order to provide redundancy in the global Internet, while minimizing the possibility of instability within the domain itself. A time server in one domain can in principle heal another domain temporarily isolated from all other sources of synchronization. However, it is probably unwise for a casual workstation to bridge fragments of the local domain which have become temporarily isolated.

      -

      Note the inclusion of a driftfile declaration. One of the things the NTP daemon does when it is first started is to compute the error in the intrinsic frequency of the clock on the computer it is running on. It usually takes about a day or so after the daemon is started to compute a good estimate of this (and it needs a good estimate to synchronize closely to its server). Once the initial value is computed, it will change only by relatively small amounts during the course of continued operation. The driftfile declaration indicates to the daemon the name of a file where it may store the current value of the frequency error so that, if the daemon is stopped and restarted, it can reinitialize itself to the previous estimate and avoid the day's worth of time it will take to recompute the frequency estimate. Since this is a desirable feature, a driftfile declaration should always be included in the configuration file.

      -

      An implication in the above is that, should ntpd be stopped for some reason, the local platform time will diverge from UTC by an amount that depends on the intrinsic error of the clock oscillator and the time since last synchronized. In view of the length of time necessary to refine the frequency estimate, every effort should be made to operate the daemon on a continuous basis and minimize the intervals when for some reason it is not running.

      -

      Configuring NTP with NetInfo

      - If NetInfo support is compiled into NTP, you can opt to configure NTP in your NetInfo domain. NTP will look in the NetInfo directory /locations/ntp for property/value pairs which are equivalent to the lines in the configuration file described above. Each configuration keyword may have a corresponding property in NetInfo. Each value for a given property is treated as arguments to that property, similar to a line in the configuration file. -

      For example, the configuration shown in the configuration file above can be duplicated in NetInfo by adding a property "server" with values "rackety.udel.edu", "umd1.umd.edu", and "lilben.tn.cornell.edu"; and a property "driftfile" with the single value "/etc/ntp.drift".

      -

      Values may contain multiple tokens similar to the arguments available in the configuration file. For example, to use mimsy.mil as an NTP version 1 time server, you would add a value "mimsy.mil version 1" to the "server" property.

      -

      Ntp4 Versus Previous Versions

      - There are several items of note when dealing with a mixture of ntp4 and previous distributions of NTP Version 2 (ntpd) and NTP Version 1 (ntp3.4). The ntp4 implementation conforms to the NTP Version 3 specification RFC-1305 and, in addition, contains additional features documented in the Release Notes page. As such, by default when no additional information is available concerning the preferences of the peer, ntpd claims to be version 4 in the packets that it sends from configured associations. The version subcommand of the server, peer, broadcast and manycastclient command can be used to change the default. In unconfigured (ephemeral) associaitons, the daemon always replies in the same version as the request. -

      An NTP implementation conforming to a previous version specification ordinarily discards packets from a later version. However, in most respects documented in RFC-1305, The version 2 implementation is compatible with the version 3 algorithms and protocol. The version 1 implementation contains most of the version 2 algorithms, but without important features for clock selection and robustness. Nevertheless, in most respects the NTP versions are backwards compatible. The sticky part here is that, when a previous version implementation receives a packet claiming to be from a version 4 server, it discards it without further processing. Hence there is a danger that in some situations synchronization with previous versions will fail.

      -

      The trouble occurs when an previous version is to be included in an ntpd configuration file. With no further indication, ntpd will send packets claiming to be version 4 when it polls. To get around this, ntpd allows a qualifier to be added to configuration entries to indicate which version to use when polling. Hence the entries

      -
      -     # specify NTP version 1
      -
      -     server mimsy.mil version
      -1     # server running ntpd version 1
      -     server apple.com version
      -2     # server running ntpd version 2
      -
      - will cause version 1 packets to be sent to the host mimsy.mil and version 2 packets to be sent to apple.com. If you are testing ntpd against previous version servers you will need to be careful about this. Note that, as indicated in the RFC-1305 specification, there is no longer support for the original NTP specification, once called NTP Version 0. -

      Traffic Monitoring

      - ntpd handles peers whose stratum is higher than the stratum of the local server and polls using client mode by a fast path which minimizes the work done in responding to their polls, and normally retains no memory of these pollers. Sometimes, however, it is interesting to be able to determine who is polling the server, and how often, as well as who has been sending other types of queries to the server. -

      To allow this, ntpd implements a traffic monitoring facility which records the source address and a minimal amount of other information from each packet which is received by the server. This feature is normally enabled, but can be disabled if desired using the configuration file entry:

      -
      -     # disable monitoring feature
      -     disable monitor
      -
      - The recorded information can be displayed using the ntpdc query program, described briefly below. -

      Address-and-Mask Restrictions

      - The address-and-mask configuration facility supported by ntpd is quite flexible and general, but is not an integral part of the NTP Version 3 specification. The major drawback is that, while the internal implementation is very nice, the user interface is not. For this reason it is probably worth doing an example here. Briefly, the facility works as follows. There is an internal list, each entry of which holds an address, a mask and a set of flags. On receipt of a packet, the source address of the packet is compared to each entry in the list, with a match being posted when the following is true: -
      -     (source_addr & mask) == (address &
      -mask)
      -
      - A particular source address may match several list entries. In this case the entry with the most one bits in the mask is chosen. The flags associated with this entry are used to control the access. -

      In the current implementation the flags always add restrictions. In effect, an entry with no flags set leaves matching hosts unrestricted. An entry can be added to the internal list using a restrict declaration. The flags associated with the entry are specified textually. For example, the notrust flag indicates that hosts matching this entry, while treated normally in other respects, shouldn't be trusted to provide synchronization even if otherwise so enabled. The nomodify flag indicates that hosts matching this entry should not be allowed to do run-time configuration. There are many more flags, see the ntpd page.

      -

      Now the example. Suppose you are running the server on a host whose address is 128.100.100.7. You would like to ensure that run time reconfiguration requests can only be made from the local host and that the server only ever synchronizes to one of a pair of off-campus servers or, failing that, a time source on net 128.100. The following entries in the configuration file would implement this policy:

      -
      -     # by default, don't trust and don't allow
      -modifications
      -
      -     restrict default notrust nomodify
      -
      -     # these guys are trusted for time, but no
      -modifications allowed
      -
      -     restrict 128.100.0.0 mask 255.255.0.0 nomodify
      -     restrict 128.8.10.1 nomodify
      -     restrict 192.35.82.50 nomodify
      -
      -     # the local addresses are unrestricted
      -
      -     restrict 128.100.100.7
      -     restrict 127.0.0.1
      -
      - The first entry is the default entry, which all hosts match and hence which provides the default set of flags. The next three entries indicate that matching hosts will only have the nomodify flag set and hence will be trusted for time. If the mask isn't specified in the restrict keyword, it defaults to 255.255.255.255. Note that the address 128.100.100.7 matches three entries in the table, the default entry (mask 0.0.0.0), the entry for net 128.100 (mask 255.255.0.0) and the entry for the host itself (mask 255.255.255.255). As expected, the flags for the host are derived from the last entry since the mask has the most bits set. -

      The only other thing worth mentioning is that the restrict declarations apply to packets from all hosts, including those that are configured elsewhere in the configuration file and even including your clock pseudopeer(s), if any. Hence, if you specify a default set of restrictions which you don't wish to be applied to your configured peers, you must remove those restrictions for the configured peers with additional restrict declarations mentioning each peer separately.

      -

      Authentication

      - ntpd supports the optional authentication procedure specified in the NTP Version 2 and 3 specifications. Briefly, when an association runs in authenticated mode, each packet transmitted has appended to it a 32-bit key ID and a 64/128-bit cryptographic checksum of the packet contents computed using either the Data Encryption Standard (DES) or Message Digest (MD5) algorithms. Note that, while either of these algorithms provide sufficient protection from message- modification attacks, distribution of the former algorithm implementation is restricted to the U.S. and Canada, while the latter presently is free from such restrictions. For this reason, the DES algorithm is not included in the current distribution. Directions for obtaining it in other countries is in the Building and Installing the Distribution page. With either algorithm the receiving peer recomputes the checksum and compares it with the one included in the packet. For this to work, the peers must share at least one encryption key and, furthermore, must associate the shared key with the same key ID. -

      This facility requires some minor modifications to the basic packet processing procedures, as required by the specification. These modifications are enabled by the enable auth configuration declaration, which is currently the default. In authenticated mode, peers which send unauthenticated packets, peers which send authenticated packets which the local server is unable to decrypt and peers which send authenticated packets encrypted using a key we don't trust are all marked untrustworthy and unsuitable for synchronization. Note that, while the server may know many keys (identified by many key IDs), it is possible to declare only a subset of these as trusted. This allows the server to share keys with a client which requires authenticated time and which trusts the server, but which is not trusted by the server. Also, some additional configuration language is required to specify the key ID to be used to authenticate each configured peer association. Hence, for a server running in authenticated mode, the configuration file might look similar to the following:

      -
      -     # peer configuration for 128.100.100.7
      -     # (expected to operate at stratum 2)
      -     # fully authenticated this time
      -
      -     peer 128.100.49.105 key 22 #
      -suzuki.ccie.utoronto.ca
      -     peer 128.8.10.1 key 4    #
      -umd1.umd.edu
      -     peer 192.35.82.50 key 6  #
      -lilben.tn.cornell.edu
      -
      -     keys /usr/local/etc/ntp.keys  # path for
      -key file
      -     trustedkey 1 2 14 15     #
      -define trusted keys
      -     requestkey
      -15            #
      -key (7) for accessing server variables
      -     controlkey
      -15            #
      -key (6) for accessing server variables
      -
      -     authdelay
      -0.000094       # authentication delay
      -(Sun4c/50 IPX)
      -
      - There are a couple of previously unmentioned things in here. The keys line specifies the path to the keys file (see below and the ntpd document page for details of the file format). The trustedkey declaration identifies those keys that are known to be uncompromised; the remainder presumably represent the expired or possibly compromised keys. Both sets of keys must be declared by key identifier in the ntp.keys file described below. This provides a way to retire old keys while minimizing the frequency of delicate key-distribution procedures. The requestkey line establishes the key to be used for mode-6 control messages as specified in RFC-1305 and used by the ntpq utility program, while the controlkey line establishes the key to be used for mode-7 private control messages used by the ntpdc utility program. These keys are used to prevent unauthorized modification of daemon variables. -

      Ordinarily, the authentication delay; that is, the processing time taken between the freezing of a transmit timestamp and the actual transmission of the packet when authentication is enabled (i.e. more or less the time it takes for the DES or MD5 routine to encrypt a single block) is computed automatically by the daemon. If necessary, the delay can be overridden by the authdelay line, which is used as a correction for the transmit timestamp.

      - Additional utility programs included in the ./authstuff directory can be used to generate random keys, certify implementation correctness and display sample keys. As a general rule, keys should be chosen randomly, except possibly the request and control keys, which must be entered by the user as a password. -

      The ntp.keys file contains the list of keys and associated key IDs the server knows about (for obvious reasons this file is better left unreadable by anyone except root). The contents of this file might look like:

      -
      -     # ntp keys file (ntp.keys)
      -     1    N   
      -29233E0461ECD6AE    # DES key in NTP format
      -     2    M   
      -RIrop8KPPvQvYotM    # md5 key as an ASCII random string
      -     14   M   
      -sundial           
      -;  # md5 key as an ASCII string
      -     15   A   
      -sundial           
      -;  # DES key as an ASCII string
      -
      -     # the following 3 keys are identical
      -
      -     10   A    SeCReT
      -     10   N   
      -d3e54352e5548080
      -     10   S   
      -a7cb86a4cba80101
      -
      - In the keys file the first token on each line indicates the key ID, the second token the format of the key and the third the key itself. There are four key formats. An A indicates a DES key written as a 1- to-8 character string in 7-bit ASCII representation, with each character standing for a key octet (like a Unix password). An S indicates a DES key written as a hex number in the DES standard format, with the low order bit (LSB) of each octet being the (odd) parity bit. An N indicates a DES key again written as a hex number, but in NTP standard format with the high order bit of each octet being the (odd) parity bit (confusing enough?). An M indicates an MD5 key written as a 1-to-31 character ASCII string in the A format. Note that, because of the simple tokenizing routine, the characters ' ', '#', '\t', '\n' and '\0' can't be used in either a DES or MD5 ASCII key. Everything else is fair game, though. Key 0 (zero) is used for special purposes and should not appear in this file. -

      The big trouble with the authentication facility is the keys file. It is a maintenance headache and a security problem. This should be fixed some day. Presumably, this whole bag of worms goes away if/when a generic security regime for the Internet is established. An alternative with NTP Version 4 is the autokey feature, which uses random session keys and public-key cryptography and avoids the key file entirely. While this feature is not completely finished yet, details can be found in the Release Notes page.

      -

      Query Programs

      - Three utility query programs are included with the distribution, ntpq, ntptrace and ntpdc. ntpq is a handy program which sends queries and receives responses using NTP standard mode-6 control messages. Since it uses the standard control protocol specified in RFC- 1305, it may be used with NTP Version 2 and Version 3 implementations for both Unix and Fuzzball, but not Version 1 implementations. It is most useful to query remote NTP implementations to assess timekeeping accuracy and expose bugs in configuration or operation. -

      ntptrace can be used to display the current synchronization path from a selected host through possibly intervening servers to the primary source of synchronization, usually a radio clock. It works with both version 2 and version 3 servers, but not version 1.

      -

      ntpdc is a horrid program which uses NTP private mode-7 control messages to query local or remote servers. The format and contents of these messages are specific to this version of ntpd and some older versions. The program does allow inspection of a wide variety of internal counters and other state data, and hence does make a pretty good debugging tool, even if it is frustrating to use. The other thing of note about ntpdc is that it provides a user interface to the run time reconfiguration facility. See the respective document pages for details on the use of these programs.

      -

      Run-Time Reconfiguration

      - ntpd was written specifically to allow its configuration to be fully modifiable at run time. Indeed, the only way to configure the server is at run time. The configuration file is read only after the rest of the server has been initialized into a running default-configured state. This facility was included not so much for the benefit of Unix, where it is handy but not strictly essential, but rather for dedicated platforms where the feature is more important for maintenance. Nevertheless, run time configuration works very nicely for Unix servers as well. -

      Nearly all of the things it is possible to configure in the configuration file may be altered via NTP mode-7 messages using the ntpdc program. Mode-6 messages may also provide some limited configuration functionality (though the only thing you can currently do with mode-6 messages is set the leap-second warning bits) and the ntpq program provides generic support for the latter. The leap bits that can be set in the leap_warning variable (up to one month ahead) and in the leap_indication variable have a slightly different encoding than the usual interpretation:

      -
      -       
      -Value           Action
      -
      -        
      -00            
      -p; The daemon passes the leap bits of its
      -            
      -           
      -synchronisation source (usual mode of operation)
      -
      -        01/10   A leap
      -second is added/deleted
      -
      -        
      -11            
      -p; Leap information from the synchronization source
      -            
      -            is
      -ignored (thus LEAP_NOWARNING is passed on)
      -
      - Mode-6 and mode-7 messages which would modify the configuration of the server are required to be authenticated using standard NTP authentication. To enable the facilities one must, in addition to specifying the location of a keys file, indicate in the configuration file the key IDs to be used for authenticating reconfiguration commands. Hence the following fragment might be added to a configuration file to enable the mode-6 (ntpq) and mode-7 (ntpdc) facilities in the daemon: -
      -     # specify mode-6 and mode-7 trusted keys
      -
      -     requestkey 65535    # for mode-7
      -requests
      -     controlkey 65534    # for mode-6
      -requests
      -
      - If the requestkey and/or the controlkey configuration declarations are omitted from the configuration file, the corresponding run-time reconfiguration facility is disabled. -

      The query programs require the user to specify a key ID and a key to use for authenticating requests to be sent. The key ID provided should be the same as the one mentioned in the configuration file, while the key should match that corresponding to the key ID in the keys file. As the query programs prompt for the key as a password, it is useful to make the request and control authentication keys typeable (in ASCII format) from the keyboard.

      -

      Name Resolution

      - ntpd includes the capability to specify host names requiring resolution in peer and server declarations in the configuration file. However, in some outposts of the Internet, name resolution is unreliable and the interface to the Unix resolver routines is synchronous. The hangups and delays resulting from name-resolver clanking can be unacceptable once the NTP server is running (and remember it is up and running before the configuration file is read). However, it is advantageous to resolve time server names, since their addresses are occasionally changed. -

      In order to prevent configuration delays due to the name resolver, the daemon runs the name resolution process in parallel with the main daemon code. When the daemon comes across a peer or server entry with a non-numeric host address, it records the relevant information in a temporary file and continues on. When the end of the configuration file has been reached and one or more entries requiring name resolution have been found, the server runs the name resolver from the temporary file. The server then continues on normally but with the offending peers/servers omitted from its configuration.

      -

      As each name is resolved, it configures the associated entry into the server using the same mode-7 run time reconfiguration facility that ntpdc uses. If temporary resolver failures occur, the resolver will periodically retry the requests until a definite response is received. The program will continue to run until all entries have been resolved.

      -

      Dealing with Frequency Tolerance Violations (tickadj and Friends)

      - The NTP Version 3 specification RFC-1305 calls for a maximum oscillator frequency tolerance of +-100 parts-per-million (PPM), which is representative of those components suitable for use in relatively inexpensive workstation platforms. For those platforms meeting this tolerance, NTP will automatically compensate for the frequency errors of the individual oscillator and no further adjustments are required, either to the configuration file or to various kernel variables. For the NTP Version 4 release, this tolerance has been increased to +-500 PPM. -

      However, in the case of certain notorious platforms, in particular Sun 4.1.1 systems, the performance can be improved by adjusting the values of certain kernel variables; in particular, tick and tickadj. The variable tick is the increment in microseconds added to the system time on each interval- timer interrupt, while the variable tickadj is used by the time adjustment code as a slew rate, in microseconds per tick. When the time is being adjusted via a call to the system routine adjtime(), the kernel increases or reduces tick by tickadj microseconds per tick until the specified adjustment has been completed. Unfortunately, in most Unix implementations the tick increment must be either zero or plus/minus exactly tickadj microseconds, meaning that adjustments are truncated to be an integral multiple of tickadj (this latter behaviour is a misfeature, and is the only reason the tickadj code needs to concern itself with the internal implementation of tickadj at all). In addition, the stock Unix implementation considers it an error to request another adjustment before a prior one has completed.

      -

      Thus, to make very sure it avoids problems related to the roundoff, the tickadj program can be used to adjust the values of tick and tickadj. This ensures that all adjustments given to adjtime() are an even multiple of tickadj microseconds and computes the largest adjustment that can be completed in the adjustment interval (using both the value of tick and the value of tickadj) so it can avoid exceeding this limit. It is important to note that not all systems will allow inspection or modification of kernel variables other than at system build time. It is also important to know that, with the current NTP tolerances, it is rarely necessary to make these changes, but in many cases they will substantially improve the general accuracy of the time service.

      -

      Unfortunately, the value of tickadj set by default is almost always too large for ntpd. NTP operates by continuously making small adjustments to the clock, usually at one-second intervals. If tickadj is set too large, the adjustments will disappear in the roundoff; while, if tickadj is too small, NTP will have difficulty if it needs to make an occasional large adjustment. While the daemon itself will read the kernel's values of these variables, it will not change the values, even if they are unsuitable. You must do this yourself before the daemon is started using the tickadj program included in the ./util directory of the distribution. Note that the latter program will also compute an optimal value of tickadj for NTP use based on the kernel's value of tick.

      -

      The tickadj program can reset several other kernel variables if asked. It can change the value of tick if asked. This is handy to compensate for kernel bugs which cause the clock to run with a very large frequency error, as with SunOS 4.1.1 systems. It can also be used to set the value of the kernel dosynctodr variable to zero. This variable controls whether to synchronize the system clock to the time-of-day clock, something you really don't want to be happen when ntpd is trying to keep it under control. In some systems, such as recent Sun Solaris kernels, the dosynctodr variable is the only one that can be changed by the tickadj program. In this and other modern kernels, it is not necessary to change the other variables in any case.

      -

      We have a report that says starting with Solaris 2.6 we should leave dosynctodr alone.

      -

      In order to maintain reasonable correctness bounds, as well as reasonably good accuracy with acceptable polling intervals, ntpd will complain if the frequency error is greater than 500 PPM. For machines with a value of tick in the 10-ms range, a change of one in the value of tick will change the frequency by about 100 PPM. In order to determine the value of tick for a particular CPU, disconnect the machine from all sources of time (dosynctodr = 0) and record its actual time compared to an outside source (eyeball-and-wristwatch will do) over a day or more. Multiply the time change over the day by 0.116 and add or subtract the result to tick, depending on whether the CPU is fast or slow. An example call to tickadj useful on SunOS 4.1.1 is:

      -
      -     tickadj -t 9999 -a 5 -s
      -
      - which sets tick 100 PPM fast, tickadj to 5 microseconds and turns off the clock/calendar chip fiddle. This line can be added to the rc.local configuration file to automatically set the kernel variables at boot time. -

      All this stuff about diddling kernel variables so the NTP daemon will work is really silly. If vendors would ship machines with clocks that kept reasonable time and would make their adjtime() system call apply the slew it is given exactly, independent of the value of tickadj, all this could go away. This is in fact the case on many current Unix systems.

      -

      Tuning Your Subnet

      - There are several parameters available for tuning the NTP subnet for maximum accuracy and minimum jitter. One of these is the prefer configuration declaration described in Mitigation Rules and the prefer Keyword documentation page. When more than one eligible server exists, the NTP clock-selection and combining algorithms act to winnow out all except the "best" set of servers using several criteria based on differences between the readings of different servers and between successive readings of the same server. The result is usually a set of surviving servers that are apparently statistically equivalent in accuracy, jitter and stability. The population of survivors remaining in this set depends on the individual server characteristics measured during the selection process and may vary from time to time as the result of normal statistical variations. In LANs with high speed RISC-based time servers, the population can become somewhat unstable, with individual servers popping in and out of the surviving population, generally resulting in a regime called clockhopping. -

      When only the smallest residual jitter can be tolerated, it may be convenient to elect one of the servers at each stratum level as the preferred one using the keyword prefer on the configuration declaration for the selected server:

      -
      -     # preferred server declaration
      -
      -     peer rackety.udel.edu prefer   
      -# preferred server
      -
      - The preferred server will always be included in the surviving population, regardless of its characteristics and as long as it survives preliminary sanity checks and validation procedures. -

      The most useful application of the prefer keyword is in high speed LANs equipped with precision radio clocks, such as a GPS receiver. In order to insure robustness, the hosts need to include outside peers as well as the GPS-equipped server; however, as long as that server is running, the synchronization preference should be that server. The keyword should normally be used in all cases in order to prefer an attached radio clock. It is probably inadvisable to use this keyword for peers outside the LAN, since it interferes with the carefully crafted judgement of the selection and combining algorithms.

      -

      Provisions for Leap Seconds and Accuracy Metrics

      - ntpd understands leap seconds and will attempt to take appropriate action when one occurs. In principle, every host running ntpd will insert a leap second in the local timescale in precise synchronization with UTC. This requires that the leap-warning bits be activated some time prior to the occurrence of a leap second at the primary (stratum 1) servers. Subsequently, these bits are propagated throughout the subnet depending on these servers by the NTP protocol itself and automatically implemented by ntpd and the time- conversion routines of each host. The implementation is independent of the idiosyncrasies of the particular radio clock, which vary widely among the various devices, as long as the idiosyncratic behavior does not last for more than about 20 minutes following the leap. Provisions are included to modify the behavior in cases where this cannot be guaranteed. While provisions for leap seconds have been carefully crafted so that correct timekeeping immediately before, during and after the occurrence of a leap second is scrupulously correct, stock Unix systems are mostly inept in responding to the available information. This caveat goes also for the maximum-error and statistical-error bounds carefully calculated for all clients and servers, which could be very useful for application programs needing to calibrate the delays and offsets to achieve a near- simultaneous commit procedure, for example. While this information is maintained in the ntpd data structures, there is at present no way for application programs to access it. This may be a topic for further development. -

      Clock Support Overview

      - ntpd was designed to support radio (and other external) clocks and does some parts of this function with utmost care. Clocks are treated by the protocol as ordinary NTP peers, even to the point of referring to them with an (invalid) IP host address. Clock addresses are of the form 127.127.t.u, where t specifies the particular type of clock (i.e., refers to a particular clock driver) and u is a unit number whose interpretation is clock-driver dependent. This is analogous to the use of major and minor device numbers by Unix and permits multiple instantiations of clocks of the same type on the same server, should such magnificent redundancy be required. -

      Because clocks look much like peers, both configuration file syntax and run time reconfiguration commands can be used to control clocks in the same way as ordinary peers. Clocks are configured via server declarations in the configuration file, can be started and stopped using ntpdc and are subject to address-and-mask restrictions much like a normal peer, should this stretch of imagination ever be useful. As a concession to the need to sometimes transmit additional information to clock drivers, an additional configuration file is available: the fudge statement. This enables one to specify the values of two time quantities, two integral values and two flags, the use of which is dependent on the particular clock driver. For example, to configure a PST radio clock which can be accessed through the serial device /dev/pst1, with propagation delays to WWV and WWVH of 7.5 and 26.5 milliseconds, respectively, on a machine with an imprecise system clock and with the driver set to disbelieve the radio clock once it has gone 30 minutes without an update, one might use the following configuration file entries:

      -
      -     # radio clock fudge fiddles
      -     server 127.127.3.1
      -     fudge 127.127.3.1 time1 0.0075 time2 0.0265
      -     fudge 127.127.3.1 value2 30 flag1 1
      -
      - Additional information on the interpretation of these data with respect to various radio clock drivers is given in the Reference Clock Drivers document page and in the individual driver documents accessible via that page. -

      Towards the Ultimate Tick

      - This section considers issues in providing precision time synchronization in NTP subnets which need the highest quality time available in the present technology. These issues are important in subnets supporting real-time services such as distributed multimedia conferencing and wide-area experiment control and monitoring. -

      In the Internet of today synchronization paths often span continents and oceans with moderate to high variations in delay due to traffic spasms. NTP is specifically designed to minimize timekeeping jitter due to delay variations using intricately crafted filtering and selection algorithms; however, in cases where these variations are as much as a second or more, the residual jitter following these algorithms may still be excessive. Sometimes, as in the case of some isolated NTP subnets where a local source of precision time is available, such as a PPS signal produced by a calibrated cesium clock, it is possible to remove the jitter and retime the local clock oscillator of the NTP server. This has turned out to be a useful feature to improve the synchronization quality of time distributed in remote places where radio clocks are not available. In these cases special features of the distribution are used together with the PPS signal to provide a jitter-free timing signal, while NTP itself is used to provide the coarse timing and resolve the seconds numbering.

      -

      Most available radio clocks can provide time to an accuracy in the order of milliseconds, depending on propagation conditions, local noise levels and so forth. However, as a practical matter, all clocks can occasionally display errors significantly exceeding nominal specifications. Usually, the algorithms used by NTP for ordinary network peers, as well as radio clock peers will detect and discard these errors as discrepancies between the disciplined local clock oscillator and the decoded time message produced by the radio clock. Some radio clocks can produce a special PPS signal which can be interfaced to the server platform in a number of ways and used to substantially improve the (disciplined) clock oscillator jitter and wander characteristics by at least an order of magnitude. Using these features it is possible to achieve accuracies in the order of a few tens of microseconds with a fast RISC- based platform.

      -

      There are three ways to implement PPS support, depending on the radio clock model, platform model and serial line interface. These are described in detail in the application notes mentioned in the The Network Time Protocol (NTP) Distribution document page. Each of these requires circuitry to convert the TTL signal produced by most clocks to the EIA levels used by most serial interfaces. The Pulse-per-second (PPS) Signal Interfacing page describes a device designed to do this. Besides being useful for this purpose, this device includes an inexpensive modem designed for use with the Canadian CHU time/frequency radio station.

      -

      In order to select the appropriate implementation, it is important to understand the underlying PPS mechanism used by ntpd. The PPS support depends on a continuous source of PPS pulses used to calculate an offset within +-500 milliseconds relative to the local clock. The serial timecode produced by the radio or the time determined by NTP in absence of the radio is used to adjust the local clock within +-128 milliseconds of the actual time. As long as the local clock is within this interval the PPS support is used to discipline the local clock and the timecode used only to verify that the local clock is in fact within the interval. Outside this interval the PPS support is disabled and the timecode used directly to control the local clock.

      -

      Parting Shots

      - There are several undocumented programs which can be useful in unusual cases. They can be found in the ./clockstuff and ./authstuff directories of the distribution. One of these is the propdelay program, which can compute high frequency radio propagation delays between any two points whose latitude and longitude are known. The program understands something about the phenomena which allow high frequency radio propagation to occur, and will generally provide a better estimate than a calculation based on the great circle distance. Other programs of interest include clktest, which allows one to exercise the generic clock line discipline, and chutest, which runs the basic reduction algorithms used by the daemon on data received from a serial port.  -
      -
      - gif
      -
      - - - - diff --git a/contrib/ntp/html/ntp-wait.html b/contrib/ntp/html/ntp-wait.html new file mode 100644 index 000000000..dcc6a10c8 --- /dev/null +++ b/contrib/ntp/html/ntp-wait.html @@ -0,0 +1,33 @@ + + + + + + ntp-wait - waits until ntpd is in synchronized state + + + +

      ntp-wait - waits until ntpd is in synchronized state

      +

      Last update: + 12-Jul-2011 22:03 + UTC

      +
      +

      Synopsis

      +

      ntp-wait [ -v ] [ -n tries ] [ -s seconds ]

      +

      Description

      +

      The ntp-wait program blocks until ntpd is in synchronized state. + This can be useful at boot time, to delay the boot sequence + until after "ntpd -g" has set the time. +

      Command Line Options

      +
      +
      -n tries +
      Number of tries before giving up. The default is 1000. +
      -s seconds +
      Seconds to sleep between tries. The default is 6 seconds. +
      -v +
      Be verbose. +
      + + + + diff --git a/contrib/ntp/html/ntp_conf.html b/contrib/ntp/html/ntp_conf.html index 520ce45c9..73d26cde9 100644 --- a/contrib/ntp/html/ntp_conf.html +++ b/contrib/ntp/html/ntp_conf.html @@ -1,173 +1,174 @@ - - - - - - Configuration File Definition (Advanced) - - - - -

      Configuration File Definition (Advanced)

      - giffrom Pogo, Walt Kelly -

      A typical NTP monitoring packet

      -

      Last update: 19:46 UTC Friday, June 16, 2006

      -
      -
      -

      Table of Contents

      - -

      Synopsis

      -

      The NTP configuration process is driven by a phrase-structure grammar which is used to specify the format of the configuration commands and the actions needed to build an abstract syntax tree (AST). The grammar is fed to a parser generator (Bison) which produces a parser for the configuration file.

      -

      The generated parser is used to parse an NTP configuration file and check it for syntax and semantic errors. The result of the parse is an AST, which contains a representation of the various commands and options. This AST is then traversed to set up the NTP daemon to the correct configuration.

      -

      This document is intended for developers who wish to modify the configuration code and/or add configuration commands and options. It contains a description of the files used in the configuration process as well as guidelines on how to construct them.

      -

      Files

      -

      A brief description of the files used by the configuration code is given below:

      - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
      FileDescription
      ntp_config.yThis file is a Bison source file that contains the phrase-structure grammar and the actions that need to be performed to generate an AST.
      ntp_config.cThis file contains the major chunk of the configuration code. It contains all the functions that are called for building the AST as well as the functions that are needed for traversing the AST.
      ntp_config.hThis file is the header file for ntp_config.c. It mainly contains the structure definitions needed to build the AST.
      ntp_scanner.cThis file contains the code for a simple lexical analyzer. This file is directly included into the ntp_config.c file since this code is only used by the configuration code. The most important function in this file is yylex, which is called by the generated parser to get the next token on the input line.
      ntp_data_structures.cThis file contains a generic implementation of a priority queue and a simple queue. This code can be used to create a queue for any structure.
      ntp_data_structures.hThis header file contains the structure declarations and function prototypes needed to use the data structures defined in ntp_data_structures.c. This file forms the public interface of the data structures.
      ntp_config.tab.cThis file is generated by Bison from the ntp_config.y file. This file is also included directly into the configuration code.
      -

      High-Level Description

      -

      A high-level description of the configuration process showing where all the files fit in is given below:

      -

      JPEG

      -

      The scanner reads in an NTP configuration file and converts it into tokens. The Bison generated parser reads these tokens and converts them into an AST. The AST traverser consists of a set of functions that configure parts of NTP on the basis of what is on the tree. A more detailed description of these parts and the files used is given below:

      -

      Detailed Description

      -
      -
      ntp_scanner.c -
      This file contains the scanner. The scanner is a small program that converts an input NTP configuration file into a set of tokens that correspond to lexemes in the input. Lexemes are strings in the input, delimited by whitespace and/or special characters. Tokens are basically unique integers that represent these lexemes. A different token is generated for each reserved word and special character in the input. There are two main functions in the public interface of this file: -
      int yylex() -
      This function is called yylex for historical reasons; lex is a program that takes a set of regular expressions and generates a scanner that returns tokens corresponding to those regular expressions. The name of the generated function is called yylex. We aren't using lex because it requires linking against an external library and we didn't want to increase the compile-time requirements of NTP. -
      History lessons aside, this function basically checks to see if the next input character is a special character as defined in the array char special_char[]. (The function int is_special(char ch), can be used for this.) If yes, the special character is returned as the token. If not, a set of characters is read until the next whitespace or special character is encountered. This set of characters forms the lexeme; yylex then checks whether this lexeme is an integer, a double, an IP address or a reserved word. If yes, the corresponding token is returned. If not, a token for a string is returned as the default token. -
      struct state *create_keyword_scanner(struct key_tok *keyword_list) -
      This function takes a list of (keyword, token) pairs and converts them into a trie that can recognize the keywords (reserved words). Every time the scanner reads a lexeme, it compares it against the list of reserved words. If it finds a match, it returns the corresponding token for that keyword. -
      ntp_data_structures.c -
      This file contains an implementation of a generic priority queue and FIFO queue. By generic, we mean that these queues can hold element of any type (integers, user-defined structs, etc.), provided that these elements are allocated on the heap using the function void *get_node(size_t size). Note that the prototype for this function is exactly the same as that of malloc and that it can be used in the exact same way. Behind the scenes, get_node calls malloc to allocate size plus some extra memory needed for bookkeeping. The allocated memory can be freed using the function void free_node (void *my_node). In addition to these two functions, the public interface of this file contains the following functions: -
      queue *create_priority_queue(int (*get_order)(void *, void*)) -
      This function creates a priority queue in which the order of the elements is determined by the get_order function that is passed as input to the priority queue. The get_order function should return positive if the priority of the first element is less than the priority of the second element. -
      queue *create_queue(void) -
      This function creates a FIFO queue. It basically calls the create_priority_queue function with the get_fifo_order function as its argument. -
      void destroy_queue(queue *my_queue) -
      This function deletes my_queue and frees up all the memory allocated to it an its elements. -
      int empty(queue *my_queue) -
      This function checks to see if my_queue is empty. Returns true if my_queue does not have any elements, else it returns false. -
      queue *enqueue(queue *my_queue, void *my_node) -
      This function adds an element, my_node, to a queue, my_queue. my_node must be allocated on the heap using the get_node function instead of malloc. -
      void *dequeue(queue *my_queue) -
      This function returns the element at the front of the queue. This element will be element with the highest priority. -
      int get_no_of_elements(queue *my_queue) -
      This function returns the number of elements in my_queue. -
      void append_queue(queue *q1, queue *q2) -
      This function adds all the elements of q2 to q1. The queue q2 is destroyed in the process. -
      ntp_config.y -
      This file is structured as a standard Bison file and consists of three main parts, separated by %%: -
      -
        -
      1. The prologue and bison declarations: This section contains a list of the terminal symbols, the non-terminal symbols and the types of these symbols.
      2. The rules section: This section contains a description of the actual phrase-structure rules that are used to parse the configuration commands. Each rule consists of a left-hand side (LHS), a right-hand side (RHS) and an optional action. As is standard with phrase-structure grammars, the LHS consists of a single non-terminal symbol. The RHS can contain both terminal and non-terminal symbols, while the optional action can consist of any arbitrary C code. -
      3. The epilogue: This section is left empty on purpose. It is traditionally used to code the support functions needed to build the ASTs Since, we have moved all the support functions to ntp_config.c, this section is left empty. -
      -

      Prologue and Bison Declarations

      -

      All the terminal symbols (also known as tokens) have to be declared in the prologue section. Note that terminals and non-terminals may have values associated with them and these values have types. (More on this later). An unnamed union has to be declared with all the possible types at the start of the prologue section. For example, we declare the following union at the start of the ntp_config.y file:

      -

      %union {
      -     char *String;
      -     double Double;
      -     int Integer;
      -     void *VoidPtr;
      -     queue *Queue;
      -     struct attr_val *Attr_val;
      -     struct address_node *Address_node;
      -     struct setvar_node *Set_var;
      -     /* Simulation types */
      -     server_info *Sim_server;
      -     script_info *Sim_script;
      - }

      -

      Some tokens may not have any types. For example, tokens that correspond to reserved words do not usually have types as they simply indicate that a reserved word has been read in the input file. Such tokens have to be declared as follows:

      -

      %token T_Discard
      - %token T_Dispersion

      -

      Other tokens do have types. For example, a T_Double token is returned by the scanner whenever it sees a floating-point double in the configuration file. The value associated with the token is the actual number that was read in the configuration file and its type (after conversion) is double. Hence, the token T_Double will have to be declared as follows in the prologue of ntp_config.y file:

      -

      %token <Double> T_Double

      -

      Note that the declaration given in the angled brackets is not double but Double, which is the name of the variable given in the %union {} declaration above.

      -

      Finally, non-terminal symbols may also have values associated with them, which have types. This is because Bison allows non-terminal symbols to have actions associated with them. Actions may be thought of as small functions which get executed whenever the RHS of a non-terminal is detected. The return values of these functions are the values associated with the non-terminals. The types of the non-terminals are specified with a %type declaration as shown below:

      -

      %type <Queue> address_list
      - %type <Integer> boolean

      -

      The %type declaration may be omitted for non-terminals that do not return any value and do not have type information associated with them.

      -

      The Rules Section

      -

      The rule section only consists of phrase-structure grammar rules. Each rule typically has the following format:

      -

      LHS : RHS [{ Actions }]
      -     ;

      -

      where LHS consists of a single non-terminal symbol and the RHS consists of one or more terminal and non-terminal symbols. The Actions are optional and may consist of any number of arbitrary C statements. Note that Bison can only process LALR(1) grammars, which imposes additional restrictions on the kind of rules that can be specified. Examples of rules are shown below:

      -

      orphan_mode_command
      -     : T_Tos tos_option_list
      -         { append_queue(my_config.orphan_cmds, $2); }
      -     ;

      -

      tos_option_list
      -     : tos_option_list tos_option { $$ = enqueue($1, $2); }
      -     | tos_option { $$ = enqueue_in_new_queue($1); }
      -     ;

      -

      The $n notation, where n is an integer, is used to refer to the value of a terminal or non-terminal symbol. All terminals and non-terminal symbols within a particular rule are numbered (starting from 1) according to the order in which they appear within the RHS of a rule. $$ is used to refer to the value of the LHS terminal symbol - it is used to return a value for the non-terminal symbol specified in the LHS of the rule.

      -

      Invoking Bison

      -

      Bison needs to be invoked in order to convert the ntp_config.y file into a C source file. To invoke Bison, simply enter the command:

      -

      bison ntp_config.y

      -

      at the command prompt. If no errors are detected, an ntp_config.tab.c file will be generated by default. This generated file can be directly included into the ntp_config.c file.

      -

      If Bison report shift-reduce errors or reduce-reduce errors, it means that the grammar specified using the rules in not LALR(1). To debug such a grammar, invoke Bison with a -v switch, as shown below. This will generate a ntp_config.output file, which will contain a description of the generated state machine, together with a list of states that have shift-reduce/reduce-reduce conflicts. You can then change the rules to remove such conflicts.

      -

      bison -v ntp_config.y

      -

      For more information, refer to the Bison manual.

      -

      ntp_config.c

      -

      This file contains the major chunk of the configuration code including all the support functions needed for building and traversing the ASTs. As such, most of the functions in this file can be divided into two groups:

      -
        -
      1. Functions that have a create_ prefix. These functions are used to build a node of the AST. -
      2. Functions that have a config_ prefix. These functions are used to traverse the AST and configure NTP according to the nodes present on the tree. -
      -

      Guidelines for Adding Configuration Commands

      -

      The following steps may be used to add a new configuration command to the NTP reference implementation:

      -
        -
      1. Write phrase-structure grammar rules for the syntax of the new command. Add these rules to the rules section of the ntp_config.y file. -
      2. Write the action to be performed on recognizing the rules. These actions will be used to build the AST. -
      3. If new reserved words are needed, add these to the struct key_tok keyword_list[]structure in the ntp_config.c file. This will allow the scanner to recognize these reserved words and generate the desired tokens on recognizing them. -
      4. Specify the types of all the terminals and non-terminal symbols in the prologue section of the ntp_config.c file. -
      5. Write a function with a config_ prefix that will be executed for this new command. Make sure this function is called in the config_ntpd()function. -
      -
      -
      Sachin Kamboj
      - - - + + + +Configuration File Definition (Advanced) + + + +

      Configuration File Definition (Advanced)

      +giffrom Pogo, Walt Kelly +

      Racoon is shooting configuration bugs.

      +

      Last update: + 4-Oct-2010 05:13 + UTC

      +
      +

      Table of Contents

      + +
      +

      Synopsis

      +

      The NTP configuration process is driven by a phrase-structure grammar which is used to specify the format of the configuration commands and the actions needed to build an abstract syntax tree (AST). The grammar is fed to a parser generator (Bison) which produces a parser for the configuration file.

      +

      The generated parser is used to parse an NTP configuration file and check it for syntax and semantic errors. The result of the parse is an AST, which contains a representation of the various commands and options. This AST is then traversed to set up the NTP daemon to the correct configuration.

      +

      This document is intended for developers who wish to modify the configuration code and/or add configuration commands and options. It contains a description of the files used in the configuration process as well as guidelines on how to construct them.

      +

      Files

      +

      A brief description of the files used by the configuration code is given below:

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      FileDescription
      ntp_config.yThis file is a Bison source file that contains the phrase-structure grammar and the actions that need to be performed to generate an AST.
      ntp_config.cThis file contains the major chunk of the configuration code. It contains all the functions that are called for building the AST as well as the functions that are needed for traversing the AST.
      ntp_config.hThis file is the header file for ntp_config.c. It mainly contains the structure definitions needed to build the AST.
      ntp_scanner.cThis file contains the code for a simple lexical analyzer. This file is directly included into the ntp_config.c file since this code is only used by the configuration code. The most important function in this file is yylex, which is called by the generated parser to get the next token on the input line.
      ntp_data_structures.cThis file contains a generic implementation of a priority queue and a simple queue. This code can be used to create a queue for any structure.
      ntp_data_structures.hThis header file contains the structure declarations and function prototypes needed to use the data structures defined in ntp_data_structures.c. This file forms the public interface of the data structures.
      ntp_config.tab.cThis file is generated by Bison from the ntp_config.y file. This file is also included directly into the configuration code.
      +

      High-Level Description

      +

      A high-level description of the configuration process showing where all the files fit in is given below:

      +

      JPEG

      +

      The scanner reads in an NTP configuration file and converts it into tokens. The Bison generated parser reads these tokens and converts them into an AST. The AST traverser consists of a set of functions that configure parts of NTP on the basis of what is on the tree. A more detailed description of these parts and the files used is given below:

      +

      Detailed Description

      +
      +
      ntp_scanner.c
      +
      This file contains the scanner. The scanner is a small program that converts an input NTP configuration file into a set of tokens that correspond to lexemes in the input. Lexemes are strings in the input, delimited by whitespace and/or special characters. Tokens are basically unique integers that represent these lexemes. A different token is generated for each reserved word and special character in the input. There are two main functions in the public interface of this file:
      +
      int yylex()
      +
      This function is called yylex for historical reasons; lex is a program that takes a set of regular expressions and generates a scanner that returns tokens corresponding to those regular expressions. The name of the generated function is called yylex. We aren't using lex because it requires linking against an external library and we didn't want to increase the compile-time requirements of NTP.
      +
      History lessons aside, this function basically checks to see if the next input character is a special character as defined in the array char special_char[]. (The function int is_special(char ch), can be used for this.) If yes, the special character is returned as the token. If not, a set of characters is read until the next whitespace or special character is encountered. This set of characters forms the lexeme; yylex then checks whether this lexeme is an integer, a double, an IP address or a reserved word. If yes, the corresponding token is returned. If not, a token for a string is returned as the default token.
      +
      struct state *create_keyword_scanner(struct key_tok *keyword_list)
      +
      This function takes a list of (keyword, token) pairs and converts them into a trie that can recognize the keywords (reserved words). Every time the scanner reads a lexeme, it compares it against the list of reserved words. If it finds a match, it returns the corresponding token for that keyword.
      +
      ntp_data_structures.c
      +
      This file contains an implementation of a generic priority queue and FIFO queue. By generic, we mean that these queues can hold element of any type (integers, user-defined structs, etc.), provided that these elements are allocated on the heap using the function void *get_node(size_t size). Note that the prototype for this function is exactly the same as that of malloc and that it can be used in the exact same way. Behind the scenes, get_node calls malloc to allocate size plus some extra memory needed for bookkeeping. The allocated memory can be freed using the function void free_node (void *my_node). In addition to these two functions, the public interface of this file contains the following functions:
      +
      queue *create_priority_queue(int (*get_order)(void *, void*))
      +
      This function creates a priority queue in which the order of the elements is determined by the get_order function that is passed as input to the priority queue. The get_order function should return positive if the priority of the first element is less than the priority of the second element.
      +
      queue *create_queue(void)
      +
      This function creates a FIFO queue. It basically calls the create_priority_queue function with the get_fifo_order function as its argument.
      +
      void destroy_queue(queue *my_queue)
      +
      This function deletes my_queue and frees up all the memory allocated to it an its elements.
      +
      int empty(queue *my_queue)
      +
      This function checks to see if my_queue is empty. Returns true if my_queue does not have any elements, else it returns false.
      +
      queue *enqueue(queue *my_queue, void *my_node)
      +
      This function adds an element, my_node, to a queue, my_queue. my_node must be allocated on the heap using the get_node function instead of malloc.
      +
      void *dequeue(queue *my_queue)
      +
      This function returns the element at the front of the queue. This element will be element with the highest priority.
      +
      int get_no_of_elements(queue *my_queue)
      +
      This function returns the number of elements in my_queue.
      +
      void append_queue(queue *q1, queue *q2)
      +
      This function adds all the elements of q2 to q1. The queue q2 is destroyed in the process.
      +
      ntp_config.y
      +
      This file is structured as a standard Bison file and consists of three main parts, separated by %%:
      +
      +
        +
      1. The prologue and bison declarations: This section contains a list of the terminal symbols, the non-terminal symbols and the types of these symbols.
      2. +
      3. The rules section: This section contains a description of the actual phrase-structure rules that are used to parse the configuration commands. Each rule consists of a left-hand side (LHS), a right-hand side (RHS) and an optional action. As is standard with phrase-structure grammars, the LHS consists of a single non-terminal symbol. The RHS can contain both terminal and non-terminal symbols, while the optional action can consist of any arbitrary C code.
      4. +
      5. The epilogue: This section is left empty on purpose. It is traditionally used to code the support functions needed to build the ASTs Since, we have moved all the support functions to ntp_config.c, this section is left empty.
      6. +
      +

      Prologue and Bison Declarations

      +

      All the terminal symbols (also known as tokens) have to be declared in the prologue section. Note that terminals and non-terminals may have values associated with them and these values have types. (More on this later). An unnamed union has to be declared with all the possible types at the start of the prologue section. For example, we declare the following union at the start of the ntp_config.y file:

      +

      %union {
      +     char *String;
      +     double Double;
      +     int Integer;
      +     void *VoidPtr;
      +     queue *Queue;
      +     struct attr_val *Attr_val;
      +     struct address_node *Address_node;
      +     struct setvar_node *Set_var;
      +     /* Simulation types */
      +     server_info *Sim_server;
      +     script_info *Sim_script;
      + }

      +

      Some tokens may not have any types. For example, tokens that correspond to reserved words do not usually have types as they simply indicate that a reserved word has been read in the input file. Such tokens have to be declared as follows:

      +

      %token T_Discard
      + %token T_Dispersion

      +

      Other tokens do have types. For example, a T_Double token is returned by the scanner whenever it sees a floating-point double in the configuration file. The value associated with the token is the actual number that was read in the configuration file and its type (after conversion) is double. Hence, the token T_Double will have to be declared as follows in the prologue of ntp_config.y file:

      +

      %token <Double> T_Double

      +

      Note that the declaration given in the angled brackets is not double but Double, which is the name of the variable given in the %union {} declaration above.

      +

      Finally, non-terminal symbols may also have values associated with them, which have types. This is because Bison allows non-terminal symbols to have actions associated with them. Actions may be thought of as small functions which get executed whenever the RHS of a non-terminal is detected. The return values of these functions are the values associated with the non-terminals. The types of the non-terminals are specified with a %type declaration as shown below:

      +

      %type <Queue> address_list
      + %type <Integer> boolean

      +

      The %type declaration may be omitted for non-terminals that do not return any value and do not have type information associated with them.

      +

      The Rules Section

      +

      The rule section only consists of phrase-structure grammar rules. Each rule typically has the following format:

      +

      LHS : RHS [{ Actions }]
      +     ;

      +

      where LHS consists of a single non-terminal symbol and the RHS consists of one or more terminal and non-terminal symbols. The Actions are optional and may consist of any number of arbitrary C statements. Note that Bison can only process LALR(1) grammars, which imposes additional restrictions on the kind of rules that can be specified. Examples of rules are shown below:

      +

      orphan_mode_command
      +     : T_Tos tos_option_list
      +         { append_queue(my_config.orphan_cmds, $2); }
      +     ;

      +

      tos_option_list
      +     : tos_option_list tos_option { $$ = enqueue($1, $2); }
      +     | tos_option { $$ = enqueue_in_new_queue($1); }
      +     ;

      +

      The $n notation, where n is an integer, is used to refer to the value of a terminal or non-terminal symbol. All terminals and non-terminal symbols within a particular rule are numbered (starting from 1) according to the order in which they appear within the RHS of a rule. $$ is used to refer to the value of the LHS terminal symbol - it is used to return a value for the non-terminal symbol specified in the LHS of the rule.

      +

      Invoking Bison

      +

      Bison needs to be invoked in order to convert the ntp_config.y file into a C source file. To invoke Bison, simply enter the command:

      +

      bison ntp_config.y

      +

      at the command prompt. If no errors are detected, an ntp_config.tab.c file will be generated by default. This generated file can be directly included into the ntp_config.c file.

      +

      If Bison report shift-reduce errors or reduce-reduce errors, it means that the grammar specified using the rules in not LALR(1). To debug such a grammar, invoke Bison with a -v switch, as shown below. This will generate a ntp_config.output file, which will contain a description of the generated state machine, together with a list of states that have shift-reduce/reduce-reduce conflicts. You can then change the rules to remove such conflicts.

      +

      bison -v ntp_config.y

      +

      For more information, refer to the Bison manual.

      +

      ntp_config.c

      +

      This file contains the major chunk of the configuration code including all the support functions needed for building and traversing the ASTs. As such, most of the functions in this file can be divided into two groups:

      +
        +
      1. Functions that have a create_ prefix. These functions are used to build a node of the AST.
      2. +
      3. Functions that have a config_ prefix. These functions are used to traverse the AST and configure NTP according to the nodes present on the tree.
      4. +
      +

      Guidelines for Adding Configuration Commands

      +

      The following steps may be used to add a new configuration command to the NTP reference implementation:

      +
        +
      1. Write phrase-structure grammar rules for the syntax of the new command. Add these rules to the rules section of the ntp_config.y file.
      2. +
      3. Write the action to be performed on recognizing the rules. These actions will be used to build the AST.
      4. +
      5. If new reserved words are needed, add these to the struct key_tok keyword_list[]structure in the ntp_config.c file. This will allow the scanner to recognize these reserved words and generate the desired tokens on recognizing them.
      6. +
      7. Specify the types of all the terminals and non-terminal symbols in the prologue section of the ntp_config.c file.
      8. +
      9. Write a function with a config_ prefix that will be executed for this new command. Make sure this function is called in the config_ntpd()function.
      10. +
      +
      +
      +Sachin Kamboj +
      + + diff --git a/contrib/ntp/html/ntpd.html b/contrib/ntp/html/ntpd.html index 3b70694a6..418d199fb 100644 --- a/contrib/ntp/html/ntpd.html +++ b/contrib/ntp/html/ntpd.html @@ -1,185 +1,176 @@ - - - - - - ntpd - Network Time Protocol (NTP) daemon - - - - -

      ntpd - Network Time Protocol (NTP) daemon

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      The mushroom knows all the command line options.

      -

      Last update: 18:44 UTC Thursday, July 28, 2005

      -
      -

      Related Links

      - -

      Table of Contents

      - -
      -

      Synopsis

      - ntpd [ -46aAbdDgLmnNqx ] [ -c conffile ] [ -f driftfile ] [ -i jaildir ] [ -k keyfile ] [ -l logfile ] [ -p pidfile ] [ -P priority ] [ -r broadcastdelay ] [ -s statsdir ] [ -t key ] [ -u user[:group] ] [ -U interface_update_interval ] [ -v variable ] [ -V variable ] -

      Description

      -

      The ntpd program is an operating system daemon which sets and maintains the system time of day in synchronism with Internet standard time servers. It is a complete implementation of the Network Time Protocol (NTP) version 4, but also retains compatibility with version 3, as defined by RFC-1305, and version 1 and 2, as defined by RFC-1059 and RFC-1119, respectively. ntpd does most computations in 64-bit floating point arithmetic and does relatively clumsy 64-bit fixed point operations only when necessary to preserve the ultimate precision, about 232 picoseconds. While the ultimate precision is not achievable with ordinary workstations and networks of today, it may be required with future gigahertz CPU clocks and gigabit LANs.

      -

      How NTP Operates

      -

      The ntpd program operates by exchanging messages with one or more configured servers at designated poll intervals. When started, whether for the first or subsequent times, the program requires several exchanges from the majority of these servers so the signal processing and mitigation algorithms can accumulate and groom the data and set the clock. In order to protect the network from bursts, the initial poll interval for each server is delayed an interval randomized over a few seconds. At the default initial poll interval of 64s, several minutes can elapse before the clock is set. The initial delay to set the clock can be reduced using the iburst keyword with the server configuration command, as described on the Configuration Options page.

      -

      Most operating systems and hardware of today incorporate a time-of-year (TOY) chip to maintain the time during periods when the power is off. When the machine is booted, the chip is used to initialize the operating system time. After the machine has synchronized to a NTP server, the operating system corrects the chip from time to time. In case there is no TOY chip or for some reason its time is more than 1000s from the server time, ntpd assumes something must be terribly wrong and the only reliable action is for the operator to intervene and set the clock by hand. This causes ntpd to exit with a panic message to the system log. The -g option overrides this check and the clock will be set to the server time regardless of the chip time. However, and to protect against broken hardware, such as when the CMOS battery fails or the clock counter becomes defective, once the clock has been set, an error greater than 1000s will cause ntpd to exit anyway.

      -

      Under ordinary conditions, ntpd adjusts the clock in small steps so that the timescale is effectively continuous and without discontinuities. Under conditions of extreme network congestion, the roundtrip delay jitter can exceed three seconds and the synchronization distance, which is equal to one-half the roundtrip delay plus error budget terms, can become very large. The ntpd algorithms discard sample offsets exceeding 128 ms, unless the interval during which no sample offset is less than 128 ms exceeds 900s. The first sample after that, no matter what the offset, steps the clock to the indicated time. In practice this reduces the false alarm rate where the clock is stepped in error to a vanishingly low incidence.

      -

      As the result of this behavior, once the clock has been set, it very rarely strays more than 128 ms, even under extreme cases of network path congestion and jitter. Sometimes, in particular when ntpd is first started, the error might exceed 128 ms. This may on occasion cause the clock to be set backwards if the local clock time is more than 128 s in the future relative to the server. In some applications, this behavior may be unacceptable. If the -x option is included on the command line, the clock will never be stepped and only slew corrections will be used.

      -

      The issues should be carefully explored before deciding to use the -x option. The maximum slew rate possible is limited to 500 parts-per-million (PPM) as a consequence of the correctness principles on which the NTP protocol and algorithm design are based. As a result, the local clock can take a long time to converge to an acceptable offset, about 2,000 s for each second the clock is outside the acceptable range. During this interval the local clock will not be consistent with any other network clock and the system cannot be used for distributed applications that require correctly synchronized network time.

      -

      In spite of the above precautions, sometimes when large frequency errors are present the resulting time offsets stray outside the 128-ms range and an eventual step or slew time correction is required. If following such a correction the frequency error is so large that the first sample is outside the acceptable range, ntpd enters the same state as when the ntp.drift file is not present. The intent of this behavior is to quickly correct the frequency and restore operation to the normal tracking mode. In the most extreme cases (time.ien.it comes to mind), there may be occasional step/slew corrections and subsequent frequency corrections. It helps in these cases to use the burst keyword when configuring the server.

      -

      Frequency Discipline

      -

      The ntpd behavior at startup depends on whether the frequency file, usually ntp.drift, exists. This file contains the latest estimate of clock frequency error. When the ntpd is started and the file does not exist, the ntpd enters a special mode designed to quickly adapt to the particular system clock oscillator time and frequency error. This takes approximately 15 minutes, after which the time and frequency are set to nominal values and the ntpd enters normal mode, where the time and frequency are continuously tracked relative to the server. After one hour the frequency file is created and the current frequency offset written to it. When the ntpd is started and the file does exist, the ntpd frequency is initialized from the file and enters normal mode immediately. After that the current frequency offset is written to the file at hourly intervals.

      -

      Operating Modes

      -

      ntpd can operate in any of several modes, including symmetric active/passive, client/server broadcast/multicast and manycast, as described in the Association Management page. It normally operates continuously while monitoring for small changes in frequency and trimming the clock for the ultimate precision. However, it can operate in a one-time mode where the time is set from an external server and frequency is set from a previously recorded frequency file. A broadcast/multicast or manycast client can discover remote servers, compute server-client propagation delay correction factors and configure itself automatically. This makes it possible to deploy a fleet of workstations without specifying configuration details specific to the local environment.

      -

      By default, ntpd runs in continuous mode where each of possibly several external servers is polled at intervals determined by an intricate state machine. The state machine measures the incidental roundtrip delay jitter and oscillator frequency wander and determines the best poll interval using a heuristic algorithm. Ordinarily, and in most operating environments, the state machine will start with 64s intervals and eventually increase in steps to 1024s. A small amount of random variation is introduced in order to avoid bunching at the servers. In addition, should a server become unreachable for some time, the poll interval is increased in steps to 1024s in order to reduce network overhead.

      -

      In some cases it may not be practical for ntpd to run continuously. A common workaround has been to run the ntpdate program from a cron job at designated times. However, this program does not have the crafted signal processing, error checking and mitigation algorithms of ntpd. The -q option is intended for this purpose. Setting this option will cause ntpd to exit just after setting the clock for the first time. The procedure for initially setting the clock is the same as in continuous mode; most applications will probably want to specify the iburst keyword with the server configuration command. With this keyword a volley of messages are exchanged to groom the data and the clock is set in about 10 s. If nothing is heard after a couple of minutes, the daemon times out and exits. After a suitable period of mourning, the ntpdate program may be retired.

      -

      When kernel support is available to discipline the clock frequency, which is the case for stock Solaris, Tru64, Linux and FreeBSD, a useful feature is available to discipline the clock frequency. First, ntpd is run in continuous mode with selected servers in order to measure and record the intrinsic clock frequency offset in the frequency file. It may take some hours for the frequency and offset to settle down. Then the ntpd is stopped and run in one-time mode as required. At each startup, the frequency is read from the file and initializes the kernel frequency.

      -

      Poll Interval Control

      -

      This version of NTP includes an intricate state machine to reduce the network load while maintaining a quality of synchronization consistent with the observed jitter and wander. There are a number of ways to tailor the operation in order enhance accuracy by reducing the interval or to reduce network overhead by increasing it. However, the user is advised to carefully consider the consequences of changing the poll adjustment range from the default minimum of 64 s to the default maximum of 1,024 s. The default minimum can be changed with the tinker minpoll command to a value not less than 16 s. This value is used for all configured associations, unless overridden by the minpoll option on the configuration command. Note that most device drivers will not operate properly if the poll interval is less than 64 s and that the broadcast server and manycast client associations will also use the default, unless overridden.

      -

      In some cases involving dial up or toll services, it may be useful to increase the minimum interval to a few tens of minutes and maximum interval to a day or so. Under normal operation conditions, once the clock discipline loop has stabilized the interval will be increased in steps from the minimum to the maximum. However, this assumes the intrinsic clock frequency error is small enough for the discipline loop correct it. The capture range of the loop is 500 PPM at an interval of 64s decreasing by a factor of two for each doubling of interval. At a minimum of 1,024 s, for example, the capture range is only 31 PPM. If the intrinsic error is greater than this, the drift file ntp.drift will have to be specially tailored to reduce the residual error below this limit. Once this is done, the drift file is automatically updated once per hour and is available to initialize the frequency on subsequent daemon restarts.

      -

      The huff-n'-puff Filter

      -

      In scenarios where a considerable amount of data are to be downloaded or uploaded over telephone modems, timekeeping quality can be seriously degraded. This occurs because the differential delays on the two directions of transmission can be quite large. In many cases the apparent time errors are so large as to exceed the step threshold and a step correction can occur during and after the data transfer is in progress.

      -

      The huff-n'-puff filter is designed to correct the apparent time offset in these cases. It depends on knowledge of the propagation delay when no other traffic is present. In common scenarios this occurs during other than work hours. The filter maintains a shift register that remembers the minimum delay over the most recent interval measured usually in hours. Under conditions of severe delay, the filter corrects the apparent offset using the sign of the offset and the difference between the apparent delay and minimum delay. The name of the filter reflects the negative (huff) and positive (puff) correction, which depends on the sign of the offset.

      -

      The filter is activated by the tinker command and huffpuff keyword, as described in the Miscellaneous Options page.

      -

      Notes

      -

      If NetInfo support is built into ntpd, then ntpd will attempt to read its configuration from the NetInfo if the default ntp.conf file cannot be read and no file is specified by the -c option.

      -

      In contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

      -

      Various internal ntpd variables can be displayed and configuration options altered while the ntpd is running using the ntpq and ntpdc utility programs.

      -

      When ntpd starts it looks at the value of umask, and if zero ntpd will set the umask to 022.

      -

      Command Line Options

      -
      -
      -a -
      Require cryptographic authentication for broadcast client, multicast client and symmetric passive associations. This is the default. -
      -A -
      Do not require cryptographic authentication for broadcast client, multicast client and symmetric passive associations. This is almost never a good idea. -
      -b -
      Enable the client to synchronize to broadcast servers. -
      -c conffile -
      Specify the name and path of the configuration file, default /etc/ntp.conf. -
      -d -
      Specify debugging mode. This option may occur more than once, with each occurrence indicating greater detail of display. -
      -D level -
      Specify debugging level directly. -
      -f driftfile -
      Specify the name and path of the frequency file, default /etc/ntp.drift. This is the same operation as the driftfile driftfile configuration command. -
      -g -
      Normally, ntpd exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, ntpd will exit with a message to the system log. This option can be used with the -q and -x options. See the tinker command for other options. -
      -i jaildir -
      Chroot the server to the directory jaildir. This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. You may need to also specify a -u option. -
      -k keyfile -
      Specify the name and path of the symmetric key file, default /etc/ntp.keys. This is the same operation as the keys keyfile configuration command. -
      -l logfile -
      Specify the name and path of the log file. The default is the system log file. This is the same operation as the logfile logfile configuration command. -
      -L -
      Do not listen to virtual IPs. The default is to listen. -
      -n -
      Don't fork. -
      -N -
      To the extent permitted by the operating system, run the ntpd at the highest priority. -
      -p pidfile -
      Specify the name and path of the file used to record the ntpd process ID. This is the same operation as the pidfile pidfile configuration command. -
      -P priority -
      To the extent permitted by the operating system, run the ntpd at the specified priority. -
      -q -
      Exit the ntpd just after the first time the clock is set. This behavior mimics that of the ntpdate program, which is to be retired. The -g and -x options can be used with this option. Note: The kernel time discipline is disabled with this option. -
      -r broadcastdelay -
      Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. -
      -s statsdir -
      Specify the directory path for files created by the statistics facility. This is the same operation as the statsdir statsdir configuration command. -
      -t key -
      Add a key number to the trusted key list. This option can occur more than once. -
      -u user[:group] -
      Specify a user, and optionally a group, to switch to. This option is only available if the OS supports to run the server without full root privileges. Currently, this option is supported under NetBSD (configure with --enable-clockctl) and Linux (configure with --enable-linuxcaps). -
      -U interface update interval -
      Number of seconds to wait between interface list scans to pick up new and delete network interface. Set to 0 to disable dynamic interface list updating. The default is to scan every 5 minutes.
      -
      -v variable -
      -V variable -
      Add a system variable listed by default. -
      -x -
      Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. Thus, an adjustment as much as 600 s will take almost 14 days to complete. This option can be used with the -g and -q options. See the tinker command for other options. Note: The kernel time discipline is disabled with this option. -
      -

      The Configuration File

      -

      Ordinarily, ntpd reads the ntp.conf configuration file at startup time in order to determine the synchronization sources and operating modes. It is also possible to specify a working, although limited, configuration entirely on the command line, obviating the need for a configuration file. This may be particularly useful when the local host is to be configured as a broadcast/multicast client, with all peers being determined by listening to broadcasts at run time.

      -

      Usually, the configuration file is installed in the /etc directory, but could be installed elsewhere (see the -c conffile command line option). The file format is similar to other Unix configuration files - comments begin with a # character and extend to the end of the line; blank lines are ignored.

      -

      Configuration commands consist of an initial keyword followed by a list of arguments, some of which may be optional, separated by whitespace. Commands may not be continued over multiple lines. Arguments may be host names, host addresses written in numeric, dotted-quad form, integers, floating point numbers (when specifying times in seconds) and text strings. Optional arguments are delimited by [ ] in the following descriptions, while alternatives are separated by |. The notation [ ... ] means an optional, indefinite repetition of the last item before the [ ... ].

      -

      Configuration Options

      -

      Server Options
      - Authentication Options
      - Monitoring Options
      - Access Control Options
      - Automatic NTP Configuration Options
      - Reference Clock Options
      - Miscellaneous Options

      -

      Files

      - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
      FileDefaultOptionCommand
      configuration file/etc/ntp.conf-cnone
      frequency file/etc/ntp.drift-fdriftfile
      process ID filenone-ppidfile
      log filesystem log-llogfile
      include filenonenoneincludefile
      statistics path/var/NTP-sstatsdir
      keys path/usr/local/etc-kkeysdir
      -
      - - - + + + +ntpd - Network Time Protocol (NTP) daemon + + + + +

      ntpd - Network Time Protocol (NTP) Daemon

      +giffrom The Wizard of Oz, L. Frank Baum +

      You need help from the monkeys.

      +

      Last update: + 10-Mar-2014 05:14 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      Synopsis

      +ntpd [ -46aAbdDgLmnNqx ] [ -c conffile ] [ -f driftfile ] [ -i jaildir ] [ -I InterfaceOrAddress ] [ -k keyfile ] [ -l logfile ] [ -p pidfile ] [ -P priority ] [ -r broadcastdelay ] [ -s statsdir ] [ -t key ] [ -u user[:group] ] [ -U interface_update_interval ] [ -v variable ] [ -V variable ] +

      Description

      +

      The ntpd program is an operating system daemon that synchronizes the system clock to remote NTP time servers or local reference clocks. It is a complete implementation of NTP version 4 defined by RFC-5905, but also retains compatible with version 3 defined by RFC-1305 and versions 1 and 2, defined by RFC-1059 and RFC-1119, respectively. The program can operate in any of several modes, including client/server, symmetric and broadcast modes, and with both symmetric-key and public key-cryptography

      +

      The ntpd program ordinarily requires a configuration file described on this page. It contains configuration commands described on the pages listed above. However a client can discover remote servers and configure them automatically. This makes it possible to deploy a fleet of workstations without specifying configuration details specific to the local environment. Further details are on the

      +

      The ntpd program normally operates continuously while adjusting the system time and frequency, but in some cases this might not be practical. With the -q option ntpd operates as in continuous mode, but exits just after setting the clock for the first time. Most applications will probably want to specify the iburst option with the server command. With this option a volley of messages is exchanged to groom the data and set the clock in about ten seconds. If nothing is heard after a few minutes, the daemon times out and exits without setting the clock.

      +

      Command Line Options

      +
      +
      -4 +
      Force DNS resolution of host names to the IPv4 namespace. +
      -6 +
      Force DNS resolution of host names to the IPv6 namespace. +
      -a
      +
      Require cryptographic authentication for broadcast client, multicast client and symmetric passive associations. This is the same operation as the enable auth command and is the default.
      +
      -A
      +
      Do not require cryptographic authentication for broadcast client, multicast client and symmetric passive associations. This is the same operation as the disable auth command and almost never a good idea.
      +
      -b
      +
      Enable the client to synchronize to broadcast servers.
      +
      -c conffile
      +
      Specify the name and path of the configuration file. Without the option the default is /etc/ntp.conf.
      +
      -d
      +
      Disable switching into daemon mode, so ntpd stays attached to the starting terminal which will get all the debugging printout. Also, ^C will kill it. This option may occur more than once, with each occurrence indicating greater detail of display.
      +
      -D level
      +
      Specify debugging level directly, with level corresponding to the numbe of -d options..
      +
      -f driftfile
      +
      Specify the name and path of the frequency file. This is the same operation as the driftfile driftfile configuration command. +
      -g
      +
      Normally, ntpd exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, ntpd will exit with a message to the system log. This option can be used with the -q and -x options. See the tinker command for other options.
      +
      -i jaildir
      +
      Chroot the server to the directory jaildir. This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. You may need to also specify a -u option.
      +
      -I [address | interface name]
      +
      Open the network address given, or all the addresses associated with the given interface name. This option may appear multiple times. This option also implies not opening other addresses, except wildcard and localhost. This option is deprecated. Please consider using the configuration file interface command, which is more versatile.
      +
      -k keyfile
      +
      Specify the name and path of the symmetric key file. This is the same operation as the keys keyfile command.
      +
      -l logfile
      +
      Specify the name and path of the log file. The default is the system log file. This is the same operation as the logfile logfile command.
      +
      -m
      +
      Once the system clock is synchronized, register with mDNS as an available server.
      +
      -L
      +
      Do not listen to virtual interfaces, defined as those with names containing a colon. This option is deprecated. Please consider using the configuration file interface command, which is more versatile.
      +
      -M
      +
      Raise scheduler precision to its maximum (1 ms) using timeBeginPeriod. (Windows only)
      +
      -n
      +
      Don't fork.
      +
      -N
      +
      To the extent permitted by the operating system, run the ntpd at the highest priority.
      +
      -p pidfile
      +
      Specify the name and path of the file used to record the ntpd process ID. This is the same operation as the pidfile pidfile command.
      +
      -P priority
      +
      To the extent permitted by the operating system, run the ntpd at the specified priority.
      +
      -q
      +
      Exit the ntpd just after the first time the clock is set. This behavior mimics that of the ntpdate program, which is to be retired. The -g and -x options can be used with this option. Note: The kernel time discipline is disabled with this option.
      +
      -r broadcastdelay
      +
      Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol.
      +
      -s statsdir
      +
      Specify the directory path for files created by the statistics facility. This is the same operation as the statsdir statsdir command.
      +
      -t key
      +
      Add a key number to the trusted key list. This option can occur more than once. This is the same operation as the trustedkey key command.
      +
      -u user[:group]
      +
      Specify a user, and optionally a group, to switch to. This option is only available if the OS supports running the server without full root privileges. Currently, this option is supported under NetBSD (configure with --enable-clockctl) and Linux (configure with --enable-linuxcaps).
      +
      -U interface update interval
      +
      Number of seconds to wait between interface list scans to pick up old and delete network interface. Set to 0 to disable dynamic interface list updating. The default is to scan every 5 minutes.
      +
      -v variable
      + -V variable
      +
      Add a system variable listed by default.
      +
      -x
      +
      Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. Thus, an adjustment as much as 600 s will take almost 14 days to complete. This option can be used with the -g and -q options. See the tinker command for other options. Note: The kernel time discipline is disabled with this option.
      +
      --pccfreq frequency
      +
      Substitute processor cycle counter for QueryPerformanceCounter unconditionally + using the given frequency (in Hz). --pccfreq can be used on systems + which do not use the PCC to implement QueryPerformanceCounter + and have a fixed PCC frequency. The frequency specified must + be accurate within 0.5 percent. --usepcc is equivalent on many systems and should + be tried first, as it does not require determining the frequency + of the processor cycle counter. For x86-compatible processors, the PCC is + also referred to as RDTSC, which is the assembly-language instruction to retrieve + the current value.  (Windows only)
      +
      --usepcc
      +
      Substitute processor cycle counter for QueryPerformanceCounter if they + appear equivalent. This option should be used only if the PCC + frequency is fixed. Power-saving functionality on many laptops varies the + PCC frequency. (Windows only)
      +
      +

      The Configuration File

      +

      Ordinarily, ntpd reads the ntp.conf configuration file at startup in order to determine the synchronization sources and operating modes. It is also possible to specify a working, although limited, configuration entirely on the command line, obviating the need for a configuration file. This may be particularly useful when the local host is to be configured as a broadcast client, with servers determined by listening to broadcasts at run time.

      +

      Usually, the configuration file is installed as/etc/ntp.conf, but could be installed elsewhere (see the -c conffile command line option). The file format is similar to other Unix configuration files - comments begin with a # character and extend to the end of the line; blank lines are ignored.

      +

      Configuration commands consist of an initial command keyword followed by a list of option keywords separated by whitespace. Commands may not be continued over multiple lines. Options may be host names, host addresses written in numeric, dotted-quad form, integers, floating point numbers (when specifying times in seconds) and text strings. Optional arguments are delimited by [ ] in the options pages, while alternatives are separated by |. The notation [ ... ] means an optional, indefinite repetition of the last item before the [ ... ].

      +

      Files

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      FileDefaultOptionOption
      configuration file/etc/ntp.conf-cconffile
      frequency filenone-fdriftfile
      leapseconds filenoneleapfile
      process ID filenone-ppidfile
      log filesystem log-llogfile
      include filenonenoneincludefile
      statistics path/var/NTP-sstatsdir
      keys path/usr/local/etcnonekeysdir
      +
      + + diff --git a/contrib/ntp/html/ntpdate.html b/contrib/ntp/html/ntpdate.html index 30d8cadd0..9216b6c05 100644 --- a/contrib/ntp/html/ntpdate.html +++ b/contrib/ntp/html/ntpdate.html @@ -1,72 +1,81 @@ - - - - - - ntpdate - set the date and time via NTP - - - - -

      ntpdate - set the date and time via NTP

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      I told you it was eyeball and wristwatch.

      -

      Last update: 18:44 UTC Thursday, July 28, 2005

      -
      -
      -

      Disclaimer: The functionality of this program is now available in the ntpd program. See the -q command line option in the ntpd - Network Time Protocol (NTP) daemon page. After a suitable period of mourning, the ntpdate program is to be retired from this distribution

      -

      Synopsis

      - ntpdate [ -bBdoqsuv ] [ -a key ] [ -e authdelay ] [ -k keyfile ] [ -o version ] [ -p samples ] [ -t timeout ] server [ ... ] -

      Description

      - ntpdate sets the local date and time by polling the Network Time Protocol (NTP) server(s) given as the server arguments to determine the correct time. It must be run as root on the local host. A number of samples are obtained from each of the servers specified and a subset of the NTP clock filter and selection algorithms are applied to select the best of these. Note that the accuracy and reliability of ntpdate depends on the number of servers, the number of polls each time it is run and the interval between runs. -

      ntpdate can be run manually as necessary to set the host clock, or it can be run from the host startup script to set the clock at boot time. This is useful in some cases to set the clock initially before starting the NTP daemon ntpd. It is also possible to run ntpdate from a cron script. However, it is important to note that ntpdate with contrived cron scripts is no substitute for the NTP daemon, which uses sophisticated algorithms to maximize accuracy and reliability while minimizing resource use. Finally, since ntpdate does not discipline the host clock frequency as does ntpd, the accuracy using ntpdate is limited.

      -

      Time adjustments are made by ntpdate in one of two ways. If ntpdate determines the clock is in error more than 0.5 second it will simply step the time by calling the system settimeofday() routine. If the error is less than 0.5 seconds, it will slew the time by calling the system adjtime() routine. The latter technique is less disruptive and more accurate when the error is small, and works quite well when ntpdate is run by cron every hour or two.

      -

      ntpdate will decline to set the date if an NTP server daemon (e.g., ntpd) is running on the same host. When running ntpdate on a regular basis from cron as an alternative to running a daemon, doing so once every hour or two will result in precise enough timekeeping to avoid stepping the clock.

      -

      Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

      -

      If NetInfo support is compiled into ntpdate, then the server argument is optional if ntpdate can find a time server in the NetInfo configuration for ntpd.

      -

      Command Line Options

      -
      -
      -4 -
      Force DNS resolution of following host names on the command line to the IPv4 namespace. -
      -6 -
      Force DNS resolution of following host names on the command line to the IPv6 namespace. -
      -a key -
      Enable the authentication function and specify the key identifier to be used for authentication as the argument keyntpdate. The keys and key identifiers must match in both the client and server key files. The default is to disable the authentication function. -
      -B -
      Force the time to always be slewed using the adjtime() system call, even if the measured offset is greater than +-128 ms. The default is to step the time using settimeofday() if the offset is greater than +-128 ms. Note that, if the offset is much greater than +-128 ms in this case, that it can take a long time (hours) to slew the clock to the correct value. During this time. the host should not be used to synchronize clients. -
      -b -
      Force the time to be stepped using the settimeofday() system call, rather than slewed (default) using the adjtime() system call. This option should be used when called from a startup file at boot time. -
      -d -
      Enable the debugging mode, in which ntpdate will go through all the steps, but not adjust the local clock. Information useful for general debugging will also be printed. -
      -e authdelay -
      Specify the processing delay to perform an authentication function as the value authdelay, in seconds and fraction (see ntpd for details). This number is usually small enough to be negligible for most purposes, though specifying a value may improve timekeeping on very slow CPU's. -
      -k keyfile -
      Specify the path for the authentication key file as the string keyfile. The default is /etc/ntp.keys. This file should be in the format described in ntpd. -
      -o version -
      Specify the NTP version for outgoing packets as the integer version, which can be 1 or 2. The default is 3. This allows ntpdate to be used with older NTP versions. -
      -p samples -
      Specify the number of samples to be acquired from each server as the integer samples, with values from 1 to 8 inclusive. The default is 4. -
      -q -
      Query only - don't set the clock. -
      -s -
      Divert logging output from the standard output (default) to the system syslog facility. This is designed primarily for convenience of cron scripts. -
      -t timeout -
      Specify the maximum time waiting for a server response as the value timeout, in seconds and fraction. The value is is rounded to a multiple of 0.2 seconds. The default is 1 second, a value suitable for polling across a LAN. -
      -u -
      Direct ntpdate to use an unprivileged port or outgoing packets. This is most useful when behind a firewall that blocks incoming traffic to privileged ports, and you want to synchronise with hosts beyond the firewall. Note that the -d option always uses unprivileged ports. -
      -v -
      Be verbose. This option will cause ntpdate's version identification string to be logged. -
      -

      Diagnostics

      - ntpdate's exit status is zero if it finds a server and updates the clock, and nonzero otherwise. -

      Files

      - /etc/ntp.keys - encryption keys used by ntpdate. -

      Bugs

      - The slew adjustment is actually 50% larger than the measured offset, since this (it is argued) will tend to keep a badly drifting clock more accurate. This is probably not a good idea and may cause a troubling hunt for some values of the kernel variables tick and tickadj.  -
      - - - + + + +ntpdate - set the date and time via NTP + + + +

      ntpdate - set the date and time via NTP

      +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

      I told you it was eyeball and wristwatch.

      +

      Last update: + 9-Feb-2014 03:34 + UTC

      +
      +
      +

      Disclaimer: This program has known bugs and deficiencies and nobody +has volunteered to fix them in a long time. The good news is the +functionality originally intended for this program is available in the ntpd and +sntp programs. See the Deprecating +ntpdate topic in the NTP Support wiki +for a thorough discussion and analysis of the issues. +See the -q command line option in the ntpd - Network Time Protocol (NTP) daemon +page and/or the sntp - Simple Network Time +Protocol (SNTP) Client page. After a suitable period of mourning, the ntpdate program will be retired from this distribution.

      +

      Synopsis

      +ntpdate [ -46bBdqsuv ] [ -a key ] [ -e authdelay ] [ -k keyfile ] [ -o version ] [ -p samples ] [ -t timeout ] server [ ... ] +

      Description

      +

      ntpdate sets the local date and time by polling the Network Time Protocol (NTP) server(s) given as the server arguments to determine the correct time. It must be run as root on the local host. A number of samples are obtained from each of the servers specified and a subset of the NTP clock filter and selection algorithms are applied to select the best of these. Note that the accuracy and reliability of ntpdate depends on the number of servers, the number of polls each time it is run and the interval between runs.

      +

      ntpdate can be run manually as necessary to set the host clock, or it can be run from the host startup script to set the clock at boot time. This is useful in some cases to set the clock initially before starting the NTP daemon ntpd. It is also possible to run ntpdate from a cron script. However, it is important to note that ntpdate with contrived cron scripts is no substitute for the NTP daemon, which uses sophisticated algorithms to maximize accuracy and reliability while minimizing resource use. Finally, since ntpdate does not discipline the host clock frequency as does ntpd, the accuracy using ntpdate is limited.

      +

      Time adjustments are made by ntpdate in one of two ways. If ntpdate determines the clock is in error more than 0.5 second it will simply step the time by calling the system settimeofday() routine. If the error is less than 0.5 seconds, it will slew the time by calling the system adjtime() routine. The latter technique is less disruptive and more accurate when the error is small, and works quite well when ntpdate is run by cron every hour or two.

      +

      ntpdate will, if the -u flag was not specified, decline to set the date if an NTP server daemon (e.g., ntpd) is running on the same host. When running ntpdate on a regular basis from cron as an alternative to running a daemon, doing so once every hour or two will result in precise enough timekeeping to avoid stepping the clock.

      +

      Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

      +

      If NetInfo support is compiled into ntpdate, then the server argument is optional if ntpdate can find a time server in the NetInfo configuration for ntpd.

      +

      Command Line Options

      +
      +
      -4
      +
      Force DNS resolution of following host names on the command line to the IPv4 namespace.
      +
      -6
      +
      Force DNS resolution of following host names on the command line to the IPv6 namespace.
      +
      -a key
      +
      Enable the authentication function and specify the key identifier to be used for authentication as the argument key. The keys and key identifiers must match in both the client and server key files. The default is to disable the authentication function. +
      -B
      +
      Force the time to always be slewed using the adjtime() system call, even if the measured offset is greater than +-500 ms. The default is to step the time using settimeofday() if the offset is greater than +-500 ms. Note that, if the offset is much greater than +-500 ms in this case, that it can take a long time (hours) to slew the clock to the correct value. During this time. the host should not be used to synchronize clients. +
      -b
      +
      Force the time to be stepped using the settimeofday() system call, rather than slewed (default) using the adjtime() system call. This option should be used when called from a startup file at boot time.
      +
      -d
      +
      Enable the debugging mode, in which ntpdate will go through all the steps, but not adjust the local clock and using an unprivileged port. Information useful for general debugging will also be printed.
      +
      -e authdelay
      +
      Specify the processing delay to perform an authentication function as the value authdelay, in seconds and fraction (see ntpd for details). This number is usually small enough to be negligible for most purposes, though specifying a value may improve timekeeping on very slow CPU's.
      +
      -k keyfile
      +
      Specify the path for the authentication key file as the string keyfile. The default is /etc/ntp.keys. This file should be in the format described in ntpd.
      +
      -o version
      +
      Specify the NTP version for outgoing packets as the integer + version, which can be 1, 2, 3 or 4. The default is 4. This allows ntpdate to be used with older NTP versions.
      +
      -p samples
      +
      Specify the number of samples to be acquired from each server as the integer samples, with values from 1 to 8 inclusive. The default is 4.
      +
      -q
      +
      Query only - don't set the clock.
      +
      -s
      +
      Divert logging output from the standard output (default) to the system syslog facility. This is designed primarily for convenience of cron scripts.
      +
      -t timeout
      +
      Specify the maximum time waiting for a server response as the value timeout, in seconds and fraction. The value is is rounded to a multiple of 0.2 seconds. The default is 1 second, a value suitable for polling across a LAN.
      +
      -u
      +
      Direct ntpdate to use an unprivileged port for outgoing packets. This is most useful when behind a firewall that blocks incoming traffic to privileged ports, and you want to synchronize with hosts beyond the firewall. Note that the -d option always uses unprivileged ports. +
      -v
      +
      Be verbose. This option will cause ntpdate's version identification string to be logged.
      +
      +

      Diagnostics

      +ntpdate's exit status is zero if it finds a server and updates the clock, and nonzero otherwise. +

      Files

      +/etc/ntp.keys - encryption keys used by ntpdate. +

      Bugs

      +The slew adjustment is actually 50% larger than the measured offset, since this (it is argued) will tend to keep a badly drifting clock more accurate. This is probably not a good idea and may cause a troubling hunt for some values of the kernel variables tick and tickadj.  +
      + + diff --git a/contrib/ntp/html/ntpdc.html b/contrib/ntp/html/ntpdc.html index 92fde1de7..7a68dd2f7 100644 --- a/contrib/ntp/html/ntpdc.html +++ b/contrib/ntp/html/ntpdc.html @@ -1,215 +1,178 @@ - - - - - - ntpdc - special NTP query program - - - - -

      ntpdc - special NTP query program

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      This program is a big puppy.

      -

      Last update: 04:11 AM UTC Monday, November 27, 2006

      -
      -

      More Help

      - -
      -

      Synopsis

      - ntpdc [ -ilnps ] [ -c command ] [ host ] [ ... ] -

      Description

      - ntpdc is used to query the ntpd daemon about its current state and to request changes in that state. The program may be run either in interactive mode or controlled using command line arguments. Extensive state and statistics information is available through the ntpdc interface. In addition, nearly all the configuration options which can be specified at startup using ntpd's configuration file may also be specified at run time using ntpdc. -

      If one or more request options are included on the command line when ntpdc is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, ntpdc will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. ntpdc will prompt for commands if the standard input is a terminal device.

      -

      ntpdc uses NTP mode 7 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. ntpdc makes no attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time.

      -

      The operation of ntpdc are specific to the particular implementation of the ntpd daemon and can be expected to work only with this and maybe some previous versions of the daemon. Requests from a remote ntpdc program which affect the state of the local server must be authenticated, which requires both the remote program and local server share a common key and key identifier.

      -

      Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

      -

      Command Line Options

      -

      Specifying a command line option other than -i or -n will cause the specified query (queries) to be sent to the indicated host(s) immediately. Otherwise, ntpdc will attempt to read interactive format commands from the standard input.

      -
      -
      -4 -
      Force DNS resolution of following host names on the command line to the IPv4 namespace. -
      -6 -
      Force DNS resolution of following host names on the command line to the IPv6 namespace. -
      -c command -
      The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified host(s). Multiple -c options may be given. -
      -i -
      Force ntpdc to operate in interactive mode. Prompts will be written to the standard output and commands read from the standard input. -
      -l -
      Obtain a list of peers which are known to the server(s). This switch is equivalent to -c listpeers. -
      -n -
      Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names. -
      -p -
      Print a list of the peers known to the server as well as a summary of their state. This is equivalent to -c peers. -
      -s -
      Print a list of the peers known to the server as well as a summary of their state, but in a slightly different format than the -p switch. This is equivalent to -c dmpeers. -
      -

      Interactive Commands

      -

      Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a <, followed by a file name, to the command line.

      -

      A number of interactive format commands are executed entirely within the ntpdc program itself and do not result in NTP mode 7 requests being sent to a server. These are described following.

      -
      -
      ? [ command_keyword ]
      - help [ command_keyword ] -
      A ? by itself will print a list of all the command keywords known to this incarnation of ntpq. A ? followed by a command keyword will print function and usage information about the command. This command is probably a better source of information about ntpq than this manual page. -
      delay milliseconds -
      Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete. -
      host hostname -
      Set the host to which future queries will be sent. Hostname may be either a host name or a numeric address. -
      hostnames [ yes | no ] -
      If yes is specified, host names are printed in information displays. If no is specified, numeric addresses are printed instead. The default is yes, unless modified using the command line -n switch. -
      keyid keyid -
      This command allows the specification of a - key number to be used to authenticate configuration - requests from ntpdc to the host(s). This must - correspond to a key number which the host/server has - been configured to use for this purpose (server - options: trustedkey, and - requestkey). If authentication is not - enabled on the host(s) for ntpdc - commands, the command - "keyid 0" should be given; otherwise the - keyid of the next subsequent addpeer/addserver/broadcast - command will - be used. -
      quit -
      Exit ntpdc. -
      passwd -
      This command prompts you to type in a password (which will not be echoed) which will be used to authenticate configuration requests. The password must correspond to the key configured for use by the NTP server for this purpose if such requests are to be successful. -
      timeout milliseconds -
      Specify a timeout period for responses to server queries. The default is about 8000 milliseconds. Note that since ntpdc retries each query once after a timeout, the total waiting time for a timeout will be twice the timeout value set. -
      -

      Control Message Commands

      -

      Query commands result in NTP mode 7 packets containing requests for information being sent to the server. These are read-only commands in that they make no modification of the server configuration state.

      -
      -
      listpeers -
      Obtains and prints a brief list of the peers for which the server is maintaining state. These should include all configured peer associations as well as those peers whose stratum is such that they are considered by the server to be possible future synchronization candidates. -
      peers -
      Obtains a list of peers for which the server is maintaining state, along with a summary of that state. Summary information includes the address of the remote peer, the local interface address (0.0.0.0 if a local address has yet to be determined), the stratum of the remote peer (a stratum of 16 indicates the remote peer is unsynchronized), the polling interval, in seconds, the reachability register, in octal, and the current estimated delay, offset and dispersion of the peer, all in seconds. -

      The character in the left margin indicates the mode this peer entry is operating in. A + denotes symmetric active, a - indicates symmetric passive, a = means the remote server is being polled in client mode, a ^ indicates that the server is broadcasting to this address, a ~ denotes that the remote peer is sending broadcasts and a * marks the peer the server is currently synchronizing to.

      -

      The contents of the host field may be one of four forms. It may be a host name, an IP address, a reference clock implementation name with its parameter or REFCLK(implementation number, parameter). On hostnames no only IP-addresses will be displayed.

      -
      dmpeers -
      A slightly different peer summary list. Identical to the output of the peers command, except for the character in the leftmost column. Characters only appear beside peers which were included in the final stage of the clock selection algorithm. A . indicates that this peer was cast off in the falseticker detection, while a + indicates that the peer made it through. A * denotes the peer the server is currently synchronizing with. -
      showpeer peer_address [...] -
      Shows a detailed display of the current peer variables for one or more peers. Most of these values are described in the NTP Version 2 specification. -
      pstats peer_address [...] -
      Show per-peer statistic counters associated with the specified peer(s). -
      clockinfo clock_peer_address [...] -
      Obtain and print information concerning a peer clock. The values obtained provide information on the setting of fudge factors and other clock performance information. -
      kerninfo -
      Obtain and print kernel phase-lock loop operating parameters. This information is available only if the kernel has been specially modified for a precision timekeeping function. -
      loopinfo [ oneline | multiline ] -
      Print the values of selected loop filter variables. The loop filter is the part of NTP which deals with adjusting the local system clock. The offset is the last offset given to the loop filter by the packet processing code. The frequency is the frequency error of the local clock in parts-per-million (ppm). The time_const controls the stiffness of the phase-lock loop and thus the speed at which it can adapt to oscillator drift. The watchdog timer value is the number of seconds which have elapsed since the last sample offset was given to the loop filter. The oneline and multiline options specify the format in which this information is to be printed, with multiline as the default. -
      sysinfo -
      Print a variety of system state variables, i.e., state related to the local server. All except the last four lines are described in the NTP Version 3 specification, RFC-1305. -

      The system flags show various system flags, some of which can be set and cleared by the enable and disable configuration commands, respectively. These are the auth, bclient, monitor, pll, pps and stats flags. See the ntpd documentation for the meaning of these flags. There are two additional flags which are read only, the kernel_pll and kernel_pps. These flags indicate the synchronization status when the precision time kernel modifications are in use. The kernel_pll indicates that the local clock is being disciplined by the kernel, while the kernel_pps indicates the kernel discipline is provided by the PPS signal.

      -

      The stability is the residual frequency error remaining after the system frequency correction is applied and is intended for maintenance and debugging. In most architectures, this value will initially decrease from as high as 500 ppm to a nominal value in the range .01 to 0.1 ppm. If it remains high for some time after starting the daemon, something may be wrong with the local clock, or the value of the kernel variable tick may be incorrect.

      -

      The broadcastdelay shows the default broadcast delay, as set by the broadcastdelay configuration command.

      -

      The authdelay shows the default authentication delay, as set by the authdelay configuration command.

      -
      sysstats -
      Print statistics counters maintained in the protocol module. -
      memstats -
      Print statistics counters related to memory allocation code. -
      iostats -
      Print statistics counters maintained in the input-output module. -
      timerstats -
      Print statistics counters maintained in the timer/event queue support code. -
      reslist -
      Obtain and print the server's restriction list. This list is (usually) printed in sorted order and may help to understand how the restrictions are applied. -
      ifstats -
      List interface statistics for interfaces used by ntpd for network communication.
      -
      ifreload -
      Force rescan of current system interfaces. Outputs interface statistics for interfaces that could possibly change. Marks unchanged interfaces with ., added interfaces with + and deleted interfaces with -.
      -
      monlist [ version ] -
      Obtain and print traffic counts collected and maintained by the monitor facility. The version number should not normally need to be specified. -
      clkbug clock_peer_address [...] -
      Obtain debugging information for a reference clock driver. This information is provided only by some clock drivers and is mostly undecodable without a copy of the driver source in hand. -
      -

      Runtime Configuration Requests

      -

      All requests which cause state changes in the server are authenticated by the server using a configured NTP key (the facility can also be disabled by the server by not configuring a key). The key number and the corresponding key must also be made known to ntpdc. This can be done using the keyid and passwd commands, the latter of which will prompt at the terminal for a password to use as the encryption key. You will also be prompted automatically for both the key number and password the first time a command which would result in an authenticated request to the server is given. Authentication not only provides verification that the requester has permission to make such changes, but also gives an extra degree of protection again transmission errors.

      -

      Authenticated requests always include a timestamp in the packet data, which is included in the computation of the authentication code. This timestamp is compared by the server to its receive time stamp. If they differ by more than a small amount the request is rejected. This is done for two reasons. First, it makes simple replay attacks on the server, by someone who might be able to overhear traffic on your LAN, much more difficult. Second, it makes it more difficult to request configuration changes to your server from topologically remote hosts. While the reconfiguration facility will work well with a server on the local host, and may work adequately between time-synchronized hosts on the same LAN, it will work very poorly for more distant hosts. As such, if reasonable passwords are chosen, care is taken in the distribution and protection of keys and appropriate source address restrictions are applied, the run time reconfiguration facility should provide an adequate level of security.

      -

      The following commands all make authenticated requests.

      -
      -
      addpeer peer_address [ - keyid ] [ version ] [ - minpoll# | prefer | iburst | burst | minpoll - N | maxpoll N [...] ] -
      addpeer peer_address [ - prefer | iburst | burst | minpoll - N | maxpoll N | keyid - N | version N [...] ] -
      Add a configured peer association at the - given address and operating in symmetric - active mode. Note that an existing association - with the same peer may be deleted when this - command is executed, or may simply be - converted to conform to the new configuration, - as appropriate. If the keyid - is nonzero, all outgoing packets to - the remote server will have an authentication - field attached encrypted with this key. If the - value is 0 (or not given) no authentication - will be done. If ntpdc's key number has not - yet been set (e.g., by the keyid - command), it will be set to this value. - The version# can be 1 through 4 and defaults to 3. The remaining - options are either a numeric value for minpoll or - literals prefer, iburst, - burst, minpoll N, - keyid N, version N, or - maxpoll N (where N is a numeric value), and have the action as specified in the - peer configuration file command of - ntpd. See the Server Options page for further information. - Each flag (or its absence) replaces the - previous setting. The prefer keyword indicates a preferred peer (and thus will be used primarily for clock synchronisation if possible). The preferred peer also determines the validity of the PPS signal - if the preferred peer is suitable for synchronisation so is the PPS signal. -
      addserver peer_address [ - keyid ] [ version ] [ - minpoll# | prefer | iburst | burst | minpoll - N | maxpoll N [...] ] -
      addserver peer_address [ - prefer | iburst | burst | minpoll - N | maxpoll N | keyid - N | version N [...] ] -
      Identical to the addpeer command, except that the operating mode is client. -
      broadcast peer_address [ - keyid ] [ version ] [ prefer ] -
      Identical to the addpeer command, except - that the operating mode is broadcast. In this - case a valid non-zero key identifier and key are required. The peer_address parameter can be the broadcast address of the local network or a multicast group address assigned to NTP. If a multicast address, a multicast-capable kernel is required. -
      unconfig peer_address [...] -
      This command causes the configured bit to be removed from the specified peer(s). In many cases this will cause the peer association to be deleted. When appropriate, however, the association may persist in an unconfigured mode if the remote peer is willing to continue on in this fashion. -
      fudge peer_address [ time1 ] [ time2 ] [ stratum ] [ refid ] -
      This command provides a way to set certain data for a reference clock. See the source listing for further information. -
      enable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats]
      - disable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats] -
      These commands operate in the same way as the enable and disable configuration file commands of ntpd. See the Miscellaneous Options page for further information. -
      restrict address mask flag [ flag ] -
      This command operates in the same way as the restrict configuration file commands of ntpd. -
      unrestrict address mask flag [ flag ] -
      Unrestrict the matching entry from the restrict list. -
      delrestrict address mask [ ntpport ] -
      Delete the matching entry from the restrict list. -
      readkeys -
      Causes the current set of authentication keys to be purged and a new set to be obtained by rereading the keys file (which must have been specified in the ntpd configuration file). This allows encryption keys to be changed without restarting the server. -
      trustedkey keyid [...] -
      untrustedkey keyid [...] -
      These commands operate in the same way as the trustedkey and untrustedkey configuration file commands of ntpd. -
      authinfo -
      Returns information concerning the authentication module, including known keys and counts of encryptions and decryptions which have been done. -
      traps -
      Display the traps set in the server. See the source listing for further information. -
      addtrap [ address [ port ] [ interface ] -
      Set a trap for asynchronous messages. See the source listing for further information. -
      clrtrap [ address [ port ] [ interface] -
      Clear a trap for asynchronous messages. See the source listing for further information. -
      reset -
      Clear the statistics counters in various modules of the server. See the source listing for further information. -
      -

      Bugs

      -

      ntpdc is a crude hack. Much of the information it shows is deadly boring and could only be loved by its implementer. The program was designed so that new (and temporary) features were easy to hack in, at great expense to the program's ease of use. Despite this, the program is occasionally useful.

      -
      - - - + + + +ntpdc - special NTP query program + + + + +

      ntpdc - special NTP query program

      +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

      This program is a big, deprecated puppy.

      +

      Last update: + 31-Jan-2014 06:54 + UTC

      +
      +

      More Help

      + +
      +

      Synopsis

      +ntpdc [ -46dilnps ] [ -c command ] [ host ] [ ... ] +

      Description

      +

      ntpdc is deprecated - please use ntpq now, as it uses a more sane interface and can provide all of the information that ntpdc used to provide.

      +

      ntpdc is used to query the ntpd daemon about its current state and to request changes in that state. The program may be run either in interactive mode or controlled using command line arguments. Extensive state and statistics information is available through the ntpdc interface. In addition, nearly all the configuration options which can be specified at startup using ntpd's configuration file may also be specified at run time using ntpdc.

      +

      If one or more request options are included on the command line when ntpdc is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, ntpdc will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. ntpdc will prompt for commands if the standard input is a terminal device.

      +

      ntpdc uses NTP mode 7 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. ntpdc makes no attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time.

      +

      The operation of ntpdc are specific to the particular implementation of the ntpd daemon and can be expected to work only with this and maybe some previous versions of the daemon. Requests from a remote ntpdc program which affect the state of the local server must be authenticated, which requires both the remote program and local server share a common key and key identifier.

      +

      Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

      +

      Command Line Options

      +

      Specifying a command line option other than -i or -n will cause the specified query (queries) to be sent to the indicated host(s) immediately. Otherwise, ntpdc will attempt to read interactive format commands from the standard input.

      +
      +
      -4
      +
      Force DNS resolution of following host names on the command line to the IPv4 namespace.
      +
      -6
      +
      Force DNS resolution of following host names on the command line to the IPv6 namespace.
      +
      -c command
      +
      The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified host(s). Multiple -c options may be given.
      +
      -d +
      Turn on debugging mode. +
      -i
      +
      Force ntpdc to operate in interactive mode. Prompts will be written to the standard output and commands read from the standard input.
      +
      -l
      +
      Obtain a list of peers which are known to the server(s). This switch is equivalent to -c listpeers.
      +
      -n
      +
      Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names.
      +
      -p
      +
      Print a list of the peers known to the server as well as a summary of their state. This is equivalent to -c peers.
      +
      -s
      +
      Print a list of the peers known to the server as well as a summary of their state, but in a slightly different format than the -p switch. This is equivalent to -c dmpeers.
      +
      +

      Interactive Commands

      +

      Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a <, followed by a file name, to the command line.

      +

      A number of interactive format commands are executed entirely within the ntpdc program itself and do not result in NTP mode 7 requests being sent to a server. These are described following.

      +
      +
      ? [ command_keyword ]
      + help [ command_keyword ]
      +
      A ? by itself will print a list of all the command keywords known to this incarnation of ntpq. A ? followed by a command keyword will print function and usage information about the command. This command is probably a better source of information about ntpq than this manual page.
      +
      delay milliseconds
      +
      Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete.
      +
      host hostname
      +
      Set the host to which future queries will be sent. Hostname may be either a host name or a numeric address.
      +
      hostnames [ yes | no ]
      +
      If yes is specified, host names are printed in information displays. If no is specified, numeric addresses are printed instead. The default is yes, unless modified using the command line -n switch.
      +
      keyid keyid
      +
      This command allows the specification of a + key number to be used to authenticate configuration + requests from ntpdc to the host(s). This must + correspond to a key number which the host/server has + been configured to use for this purpose (server + options: trustedkey, and requestkey). If authentication is not + enabled on the host(s) for ntpdc + commands, the command "keyid 0" should be given; otherwise the keyid of the next subsequent addpeer/addserver/broadcast command will + be used.
      +
      quit
      +
      Exit ntpdc.
      +
      passwd
      +
      This command prompts you to type in a password (which will not be echoed) which will be used to authenticate configuration requests. The password must correspond to the key configured for use by the NTP server for this purpose if such requests are to be successful.
      +
      timeout milliseconds
      +
      Specify a timeout period for responses to server queries. The default is about 8000 milliseconds. Note that since ntpdc retries each query once after a timeout, the total waiting time for a timeout will be twice the timeout value set.
      +
      +

      Control Message Commands

      +

      Query commands result in NTP mode 7 packets containing requests for information being sent to the server. These are read-only commands in that they make no modification of the server configuration state.

      +
      +
      listpeers
      +
      Obtains and prints a brief list of the peers for which the server is maintaining state. These should include all configured peer associations as well as those peers whose stratum is such that they are considered by the server to be possible future synchronization candidates.
      +
      peers
      +
      Obtains a list of peers for which the server is maintaining state, along with a summary of that state. Summary information includes the address of the remote peer, the local interface address (0.0.0.0 if a local address has yet to be determined), the stratum of the remote peer (a stratum of 16 indicates the remote peer is unsynchronized), the polling interval, in seconds, the reachability register, in octal, and the current estimated delay, offset and dispersion of the peer, all in seconds.
      +
      The character in the left margin indicates the mode this peer entry is operating in. A + denotes symmetric active, a - indicates symmetric passive, a = means the remote server is being polled in client mode, a ^ indicates that the server is broadcasting to this address, a ~ denotes that the remote peer is sending broadcasts and a * marks the peer the server is currently synchronizing to.
      +
      The contents of the host field may be one of four forms. It may be a host name, an IP address, a reference clock implementation name with its parameter or REFCLK(implementation number, parameter). On hostnames no only IP-addresses will be displayed.
      +
      dmpeers
      +
      A slightly different peer summary list. Identical to the output of the peers command, except for the character in the leftmost column. Characters only appear beside peers which were included in the final stage of the clock selection algorithm. A . indicates that this peer was cast off in the falseticker detection, while a + indicates that the peer made it through. A * denotes the peer the server is currently synchronizing with.
      +
      showpeer peer_address [...]
      +
      Shows a detailed display of the current peer variables for one or more peers. Most of these values are described in the NTP Version 2 specification.
      +
      pstats peer_address [...]
      +
      Show per-peer statistic counters associated with the specified peer(s).
      +
      clockstat clock_peer_address [...]
      +
      Obtain and print information concerning a peer clock. The values obtained provide information on the setting of fudge factors and other clock performance information.
      +
      kerninfo
      +
      Obtain and print kernel phase-lock loop operating parameters. This information is available only if the kernel has been specially modified for a precision timekeeping function.
      +
      loopinfo [ oneline | multiline ]
      +
      Print the values of selected loop filter variables. The loop filter is the part of NTP which deals with adjusting the local system clock. The offset is the last offset given to the loop filter by the packet processing code. The frequency is the frequency error of the local clock in parts-per-million (ppm). The time_const controls the stiffness of the phase-lock loop and thus the speed at which it can adapt to oscillator drift. The watchdog timer value is the number of seconds which have elapsed since the last sample offset was given to the loop filter. The oneline and multiline options specify the format in which this information is to be printed, with multiline as the default.
      +
      sysinfo
      +
      Print a variety of system state variables, i.e., state related to the local server. All except the last four lines are described in the NTP Version 3 specification, RFC-1305.
      +
      The system flags show various system flags, some of which can be set and cleared by the enable and disable configuration commands, respectively. These are the auth, bclient, monitor, pll, pps and stats flags. See the ntpd documentation for the meaning of these flags. There are two additional flags which are read only, the kernel_pll and kernel_pps. These flags indicate the synchronization status when the precision time kernel modifications are in use. The kernel_pll indicates that the local clock is being disciplined by the kernel, while the kernel_pps indicates the kernel discipline is provided by the PPS signal.
      +
      Note that some directives, like enable pps, are only supported on certain versions of ntpd.
      +
      The stability is the residual frequency error remaining after the system frequency correction is applied and is intended for maintenance and debugging. In most architectures, this value will initially decrease from as high as 500 ppm to a nominal value in the range .01 to 0.1 ppm. If it remains high for some time after starting the daemon, something may be wrong with the local clock, or the value of the kernel variable tick may be incorrect.
      +
      The broadcastdelay shows the default broadcast delay, as set by the broadcastdelay configuration command.
      +
      The authdelay shows the default authentication delay, as set by the authdelay configuration command.
      +
      sysstats
      +
      Print statistics counters maintained in the protocol module.
      +
      memstats
      +
      Print statistics counters related to memory allocation code.
      +
      iostats
      +
      Print statistics counters maintained in the input-output module.
      +
      timerstats
      +
      Print statistics counters maintained in the timer/event queue support code.
      +
      reslist
      +
      Obtain and print the server's restriction list. This list is (usually) printed in sorted order and may help to understand how the restrictions are applied.
      +
      ifstats
      +
      List interface statistics for interfaces used by ntpd for network communication.
      +
      ifreload
      +
      Force rescan of current system interfaces. Outputs interface statistics for interfaces that could possibly change. Marks unchanged interfaces with ., added interfaces with + and deleted interfaces with -.
      +
      monlist [ version ]
      +
      Obtain and print traffic counts collected and maintained by the monitor facility. The version number should not normally need to be specified. At most, 600 entries are displayed by monlist. To display the entire MRU list, use the ntpq program's mrulist command.
      +
      clkbug clock_peer_address [...]
      +
      Obtain debugging information for a reference clock driver. This information is provided only by some clock drivers and is mostly undecodable without a copy of the driver source in hand.
      +
      +

      Runtime Configuration Requests

      +

      All requests which cause state changes in the server are authenticated by the server using a configured NTP key (the facility can also be disabled by the server by not configuring a key). The key number and the corresponding key must also be made known to ntpdc. This can be done using the keyid and passwd commands, the latter of which will prompt at the terminal for a password to use as the encryption key. You will also be prompted automatically for both the key number and password the first time a command which would result in an authenticated request to the server is given. Authentication not only provides verification that the requester has permission to make such changes, but also gives an extra degree of protection again transmission errors.

      +

      Authenticated requests always include a timestamp in the packet data, which is included in the computation of the authentication code. This timestamp is compared by the server to its receive time stamp. If they differ by more than a small amount the request is rejected. This is done for two reasons. First, it makes simple replay attacks on the server, by someone who might be able to overhear traffic on your LAN, much more difficult. Second, it makes it more difficult to request configuration changes to your server from topologically remote hosts. While the reconfiguration facility will work well with a server on the local host, and may work adequately between time-synchronized hosts on the same LAN, it will work very poorly for more distant hosts. As such, if reasonable passwords are chosen, care is taken in the distribution and protection of keys and appropriate source address restrictions are applied, the run time reconfiguration facility should provide an adequate level of security.

      +

      The following commands all make authenticated requests.

      +
      +
      addpeer peer_address [ keyid ] [ version ] [ minpoll# | prefer | minpoll N | maxpoll N [...] ]
      +
      addpeer peer_address [ prefer | minpoll N | maxpoll N | keyid N | version N [...] ]
      +
      Add a configured peer association at the given address and operating in symmetric + active mode. Note that an existing association with the same peer may be deleted when this + command is executed, or may simply be converted to conform to the new configuration, as appropriate. If the keyid is nonzero, all outgoing packets to the remote server will have an authentication field attached encrypted with this key. If the value is 0 (or not given) no authentication will be done. If ntpdc's key number has not yet been set (e.g., by the keyid command), it will be set to this value. The version# can be 1 through 4 and defaults to 3. The remaining options are either a numeric value for minpoll or literals prefer, burst, minpoll N, keyid N, version N, or maxpoll N (where N is a numeric value), and have the action as specified in the peer configuration file command of + ntpd. See the Server Options page for further information. Each flag (or its absence) replaces the previous setting. The prefer keyword indicates a preferred peer (and thus will be used primarily for clock synchronisation if possible). The preferred peer also determines the validity of the PPS signal - if the preferred peer is suitable for synchronisation so is the PPS signal. The dynamic keyword allows association configuration even when no suitable network interface is found at configuration time. The dynamic interface update mechanism may complete the configuration when new interfaces appear (e.g. WLAN/PPP interfaces) at a later time and thus render the association operable.
      +
      addserver peer_address [ address [ keyid ] [ version ] [ minpoll | prefer | iburst | burst | minpoll N | maxpoll N [...] ] prefer | iburst | burst | minpoll N | maxpoll N | keyid N | version N [...] ]
      +
      Identical to the addpeer command, except that the operating mode is client.
      +
      broadcast peer_address [ keyid ] [ version ] [ prefer ]
      +
      Identical to the addpeer command, except that the operating mode is broadcast. In this case a valid non-zero key identifier and key are required. The peer_address parameter can be the broadcast address of the local network or a multicast group address assigned to NTP. If a multicast address, a multicast-capable kernel is required.
      +
      unconfig peer_address [...]
      +
      This command causes the configured bit to be removed from the specified peer(s). In many cases this will cause the peer association to be deleted. When appropriate, however, the association may persist in an unconfigured mode if the remote peer is willing to continue on in this fashion.
      +
      fudge peer_address [ time1 ] [ time2 ] [ stratum ] [ refid ]
      +
      This command provides a way to set certain data for a reference clock. See the source listing for further information.
      +
      enable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats]
      + disable [ auth | bclient | calibrate | kernel | monitor | ntp | pps | stats]
      +
      These commands operate in the same way as the enable and disable configuration file commands of ntpd. See the Miscellaneous Options page for further information.
      +
      restrict address mask flag [ flag ]
      +
      This command operates in the same way as the restrict configuration file commands of ntpd.
      +
      unrestrict address mask flag [ flag ]
      +
      Unrestrict the matching entry from the restrict list.
      +
      delrestrict address mask [ ntpport ]
      +
      Delete the matching entry from the restrict list.
      +
      readkeys
      +
      Causes the current set of authentication keys to be purged and a new set to be obtained by rereading the keys file (which must have been specified in the ntpd configuration file). This allows encryption keys to be changed without restarting the server.
      +
      trustedkey keyid [...]
      +
      untrustedkey keyid [...]
      +
      These commands operate in the same way as the trustedkey and untrustedkey configuration file commands of ntpd.
      +
      authinfo
      +
      Returns information concerning the authentication module, including known keys and counts of encryptions and decryptions which have been done.
      +
      traps
      +
      Display the traps set in the server. See the source listing for further information.
      +
      addtrap [ address [ port ] [ interface ]
      +
      Set a trap for asynchronous messages. See the source listing for further information.
      +
      clrtrap [ address [ port ] [ interface]
      +
      Clear a trap for asynchronous messages. See the source listing for further information.
      +
      reset
      +
      Clear the statistics counters in various modules of the server. See the source listing for further information.
      +
      +

      Bugs

      +

      ntpdc is a crude hack. Much of the information it shows is deadly boring and could only be loved by its implementer. The program was designed so that new (and temporary) features were easy to hack in, at great expense to the program's ease of use. Despite this, the program is occasionally useful.

      +
      + + diff --git a/contrib/ntp/html/ntpdsim.html b/contrib/ntp/html/ntpdsim.html index 31eccf84e..3f823dfc6 100644 --- a/contrib/ntp/html/ntpdsim.html +++ b/contrib/ntp/html/ntpdsim.html @@ -1,73 +1,71 @@ - - - - - - ntpdsim - Network Time Protocol (NTP) simulator - - - - -

      ntpdsim - Network Time Protocol (NTP) simulator

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      The mushroom knows all the command line options.

      -

      Last update: 20:07 UTC Friday, June 16, 2006

      -
      -

      Related Links

      - -

      Table of Contents

      - -
      -

      Synopsis

      - ntpdsim [ -B bdly ] [ -C snse ] [ -O clk_time ] [ -S sim_time ] [ -T ferr ] [ -W fsne ] [ -Y ndly ] [ -X pdly ] -

      Description

      -

      The ntpdsim program is an adaptation of the ntpd operating system daemon. The program operates as a discrete time simulator using specified systematic and random driving sources. It includes all the mitigation and discipline algorithms of the actual daemon, but with the packet I/O and system clock algorithms driven by simulation. Most functions of the real ntpd remain intact, including the monitoring, statistics recording, trace and host name resolution features. Further information on the simulator is on the NTP Discrete Event Simulator page.

      -

      The simulator is most useful to study NTP behavior in response to time and/or frequency transients under specific conditions of network jitter and oscillator wander. For this purpose the daemon can be driven by pseudorandom jitter and wander sample sequences characteristic of real networks and oscillators. The jitter generator produces samples from a Poisson distribution, while the wander generator produces samples from a Guassian distribution.

      -

      The easiest way to use this program is to create a ntpstats directory, configuration file ntp.conf and frequency file ntp.drift and test shell test.sh in the base directory. The ntp.drift file and ntpstats directory can be empty to start. The test.sh script can contain something like

      -
      rm ./ntpstats/*
      +
      +
      +
      +ntpdsim - Network Time Protocol (NTP) simulator
      +
      +
      +
      +

      ntpdsim - Network Time Protocol (NTP) simulator

      +giffrom The Wizard of Oz, L. Frank Baum +

      All in a row.

      +

      Last update: + 11-Sep-2010 05:55 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      Synopsis

      +ntpdsim [ -B bdly ] [ -C snse ] [ -O clk_time ] [ -S sim_time ] [ -T ferr ] [ -W fsne ] [ -Y ndly ] [ -X pdly ] +

      Description

      +

      The ntpdsim program is an adaptation of the ntpd operating system daemon. The program operates as a discrete time simulator using specified systematic and random driving sources. It includes all the mitigation and discipline algorithms of the actual daemon, but with the packet I/O and system clock algorithms driven by simulation. Most functions of the real ntpd remain intact, including the monitoring, statistics recording, trace and host name resolution features. Further information on the simulator is on the NTP Discrete Event Simulator page.

      +

      The simulator is most useful to study NTP behavior in response to time and/or frequency transients under specific conditions of network jitter and oscillator wander. For this purpose the daemon can be driven by pseudorandom jitter and wander sample sequences characteristic of real networks and oscillators. The jitter generator produces samples from a Poisson distribution, while the wander generator produces samples from a Guassian distribution.

      +

      The easiest way to use this program is to create a ntpstats directory, configuration file ntp.conf and frequency file ntp.drift and test shell test.sh in the base directory. The ntp.drift file and ntpstats directory can be empty to start. The test.sh script can contain something like

      +
      rm ./ntpstats/*
       ntpdsim -O 0.1 -C .001 -T 400 -W 1 -c ./ntp.conf,
       
      -

      which starts the simulator with a time offset 100 ms, network jitter 1 ms, frequency offset 400 PPM and oscillator wander 1 PPM/s. These parameters represent typical conditions with modern workstations on a Ethernet LAN. The ntp.conf file should contain something like

      -
      disable kernel
      +

      which starts the simulator with a time offset 100 ms, network jitter 1 ms, frequency offset 400 PPM and oscillator wander 1 PPM/s. These parameters represent typical conditions with modern workstations on a Ethernet LAN. The ntp.conf file should contain something like

      +
      disable kernel
       server pogo
       driftfile ./ntp.drift
       statsdir ./ntpstats/
       filegen loopstats type day enable
       filegen peerstats type day enable
       
      -

      Command Line Options

      -
      -
      Note: The NTP development team is moving to the use of a syntax-directed configuration file design. When complete these options will be replaced by a new one. Most of the ntpd command line options apply also to ntpdsim. In addition, the following command line options apply to ntpdsim. -
      -B bdly -
      Specify beep delay (3600) s. -
      -C snse -
      Specify network jitter parameter (0) s. -
      -O clk_time -
      Specify initial time offset (0) s. -
      -S sim_time -
      Specify simulation duration (86400) s. -
      -T ferr -
      Specify initial frequency offset (0) PPM. -
      -W fnse -
      Specify oscillator wander parameter (0) PPM/s. -
      -Y ndly -
      Specify network propagation delay (.001) s. -
      -Z pdly -
      Specify server processing delay (.001) s. -
      -

      Files

      - /etc/ntp.conf - the default name of the configuration file
      - /etc/ntp.drift - the default name of the drift file
      - /etc/ntp.keys - the default name of the key file -
      - - - - \ No newline at end of file +

      Command Line Options

      +
      +
      Note: The NTP development team is moving to the use of a syntax-directed configuration file design. When complete these options will be replaced by a new one. Most of the ntpd command line options apply also to ntpdsim. In addition, the following command line options apply to ntpdsim.
      +
      -B bdly
      +
      Specify beep delay (3600) s.
      +
      -C snse
      +
      Specify network jitter parameter (0) s.
      +
      -O clk_time
      +
      Specify initial time offset (0) s.
      +
      -S sim_time
      +
      Specify simulation duration (86400) s.
      +
      -T ferr
      +
      Specify initial frequency offset (0) PPM.
      +
      -W fnse
      +
      Specify oscillator wander parameter (0) PPM/s.
      +
      -Y ndly
      +
      Specify network propagation delay (.001) s.
      +
      -Z pdly
      +
      Specify server processing delay (.001) s.
      +
      +

      Files

      +/etc/ntp.conf - the default name of the configuration file
      +/etc/ntp.drift - the default name of the drift file
      +/etc/ntp.keys - the default name of the key file +
      + + + diff --git a/contrib/ntp/html/ntpdsim_new.html b/contrib/ntp/html/ntpdsim_new.html index 47c226ac1..54c67438a 100644 --- a/contrib/ntp/html/ntpdsim_new.html +++ b/contrib/ntp/html/ntpdsim_new.html @@ -1,47 +1,54 @@ - - - - - - ntpdsim - Network Time Protocol (NTP) simulator - - - - -

      ntpdsim - Network Time Protocol (NTP) simulator

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      The mushroom knows all the command line options.

      -

      Last update: 21:32 UTC Friday, June 16, 2006

      -
      -

      Related Links

      - -

      Table of Contents

      - -

      Description

      -

      The ntpdsim program is used to simulate and study the behavior of an NTP daemon that derives its time from a number of different simulated time sources (servers). Each simulated server can be configured to have a different time offset, frequency offset, propagation delay, processing delay, network jitter and oscillator wander.

      -

      The ntpdsim program runs all the same selection, mitigation, and discipline algorithms as the actual ntpd daemon at the client. (It actually uses the same code). However, the input/output routines and servers are simulated. That is, instead of sending the client messages over the network to the actual servers, the client messages are intercepted by the ntpdsim program, which then generates the replies to those messages. The reply messages are carefully "inserted" into the input queue of the client at the right time according to the specified server properties (like propagation delay).

      -

      Each simulated server runs according to a specified script that describes the server properties at a particular time. Each script consists of a series of consecutive acts. Each act runs for a particular duration and specifies the frequency offset, propagation delay, processing delay, network jitter and oscillator wander of the server for that duration. Once the duration of an act expires, the simulated server reconfigures itself according to the properties specified in the next act.

      -

      Configuration

      -

      The ntpdsim program is configured by providing a configuration file at startup. The crux of the simulator configuration is specified using a simulate command, the syntax of which is given below. Note that all time quantities are in seconds and all frequency quantities are in parts per million (PPM):

      -

      <simulate_command> ::= simulate { <init_statement_list> <server_list> }
      - <init_statement_list> ::= <init_statement_list> <init_statement> | <init_statement>
      - <init_statement> ::= beep_delay = <number> | simulation_duration = <number>
      - <server_list> ::= <server_list> <server> | <server>
      - <server_list> ::= server = <address> { server_offset = <number> <act_list> }
      - <act_list> ::= <act_list> <act> | <act>
      - <act> ::= duration = <number> { <act_stmt_list> }
      - <act_stmt_list> ::= <act_stmt_list> <act_stmt> | <act_stmt>
      - <act_stmt> ::= freq_offset = <number> | wander = <number> | jitter = <number> | prop_delay = <number> | proc_delay = <number>

      -

      In addition to the simulate command, other standard NTP configuration commands can be specified. These commands have the same meaning as in the ntpd configuration. Note that newlines are not significant within the simulate command even though they are used to mark the end of a normal NTP configuration command.

      -

      Sample Configuration File

      -

      A sample ntpdsim configuration file is given below. It specifies two simulated servers, each of which has two acts.

      -
      +
      +
      +
      +ntpdsim - Network Time Protocol (NTP) Simulator
      +
      +
      +
      +

      ntpdsim - Network Time Protocol (NTP) Simulator

      +giffrom The Wizard of Oz, L. Frank Baum +

      All in a row.

      +

      Last update: + 31-Jan-2014 06:54 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      Description

      +

      The ntpdsim program is used to simulate and study the behavior of an NTP daemon that derives its time from a number of different simulated time sources (servers). Each simulated server can be configured to have a different time offset, frequency offset, propagation delay, processing delay, network jitter and oscillator wander.

      +

      The ntpdsim program runs all the same selection, mitigation, and discipline + algorithms as the actual ntpd daemon at the client. (It actually + uses the same code). However, the input/output routines and servers are simulated. + That is, instead of sending the client messages over the network + to the actual servers, the client messages are intercepted by the ntpdsim + program, which then generates the replies to those messages. The reply messages + are carefully "inserted" into the input queue of the client at the right time + according to the specified server properties (like propagation delay).

      +

      Each simulated server runs according to a specified script that describes the server properties at a particular time. Each script consists of a series of consecutive acts. Each act runs for a particular duration and specifies the frequency offset, propagation delay, processing delay, network jitter and oscillator wander of the server for that duration. Once the duration of an act expires, the simulated server reconfigures itself according to the properties specified in the next act.

      +

      Configuration

      +

      The ntpdsim program is configured by providing a configuration file at startup. The crux of the simulator configuration is specified using a simulate command, the syntax of which is given below. Note that all time quantities are in seconds and all frequency quantities are in parts per million (PPM):

      +

      <simulate_command> ::= simulate { <init_statement_list> <server_list> }
      + <init_statement_list> ::= <init_statement_list> <init_statement> ; | <init_statement> ;
      + <init_statement> ::= beep_delay = <number> | simulation_duration = <number>
      + <server_list> ::= <server_list> <server> | <server>
      + <server_list> ::= server = <address> { server_offset = <number> ; <act_list> }
      + <act_list> ::= <act_list> <act> | <act>
      + <act> ::= duration = <number> { <act_stmt_list> }
      + <act_stmt_list> ::= <act_stmt_list> <act_stmt> ; | <act_stmt> ;
      + <act_stmt> ::= freq_offset = <number> | wander = <number> | jitter = <number> | prop_delay = <number> | proc_delay = <number>

      +

      In addition to the simulate command, other standard NTP configuration commands can be specified. These commands have the same meaning as in the ntpd configuration. Note that newlines are not significant within the simulate command even though they are used to mark the end of a normal NTP configuration command. While a newline is an "end of command" terminator for other configuration commands, in the simulate stanza ; (the semicolon) is the "end of command" terminator.

      +

      Sample Configuration File

      +

      A sample ntpdsim configuration file is given below. It specifies two simulated servers, each of which has two acts.

      +
           # Client configuration 
           disable kernel
           server pogo
      @@ -52,51 +59,52 @@
       
           # Simulation configuration
           simulate {
      -        simulation_duration = 86400
      -        beep_delay = 3600
      +        simulation_duration = 86400;
      +        beep_delay = 3600;
       
               # Server 1
       	server = louie.udel.edu {
      -	    server_offset = 0 
      +	    server_offset = 0;
                   duration = 50000 {
      -		freq_offset = 400
      -		wander = 1.0
      -		jitter = 0.001
      -		prop_delay = 0.001
      -		proc_delay = 0.001
      +		freq_offset = 400;
      +		wander = 1.0;
      +		jitter = 0.001;
      +		prop_delay = 0.001;
      +		proc_delay = 0.001;
       	    }
                   duration = 6400 {
      -		freq_offset = 200
      -		wander = 1.0
      -		jitter = 0.001
      -		prop_delay = 0.001
      -		proc_delay = 0.001
      +		freq_offset = 200;
      +		wander = 1.0;
      +		jitter = 0.001;
      +		prop_delay = 0.001;
      +		proc_delay = 0.001;
       	    }
       	}
       
               # Server 2
       	server = baldwin.udel.edu {
      -	    server_offset = 0.02
      +	    server_offset = 0.02;
       	    duration = 10000 {
      -		freq_offset = 400
      -		wander = 1.0
      -		jitter = 0.001
      -		prop_delay = 0.5
      -		proc_delay = 0.001
      +		freq_offset = 400;
      +		wander = 1.0;
      +		jitter = 0.001;
      +		prop_delay = 0.5;
      +		proc_delay = 0.001;
       	    }
       	    duration = 60000 {
      -		freq_offset = 200
      -		wander = 1.0
      -		jitter = 0.05
      -		prop_delay = 0.005
      -		proc_delay = 0.001
      +		freq_offset = 200;
      +		wander = 1.0;
      +		jitter = 0.05;
      +		prop_delay = 0.005;
      +		proc_delay = 0.001;
       	    }
       	}
      -    }
      + }
         
      -
      -
      Sachin Kamboj
      - - - +
      +
      +Sachin Kamboj +
      + + diff --git a/contrib/ntp/html/ntpq.html b/contrib/ntp/html/ntpq.html index 4c077e22c..1aa8df3fc 100644 --- a/contrib/ntp/html/ntpq.html +++ b/contrib/ntp/html/ntpq.html @@ -1,264 +1,654 @@ - - - - - - ntpq - standard NTP query program - - - - -

      ntpq - standard NTP query program

      - giffrom Pogo, Walt Kelly -

      A typical NTP monitoring packet

      -

      Last update: 18:45 UTC Thursday, July 28, 2005

      -
      -

      More Help

      - -
      -

      Synopsis

      - ntpq [-inp] [-c command] [host] [...] -

      Description

      -

      The ntpq utility program is used to monitor NTP daemon ntpd operations and determine performance. It uses the standard NTP mode 6 control message formats defined in Appendix B of the NTPv3 specification RFC1305. The same formats are used in NTPv4, although some of the variables have changed and new ones added. The description on this page is for the NTPv4 variables.

      -

      The program can be run either in interactive mode or controlled using command line arguments. Requests to read and write arbitrary variables can be assembled, with raw and pretty-printed output options being available. The ntpq can also obtain and print a list of peers in a common format by sending multiple queries to the server.

      -

      If one or more request options is included on the command line when ntpq is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, ntpq will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. ntpqwill prompt for commands if the standard input is a terminal device.

      -

      ntpq uses NTP mode 6 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. ntpq makes one attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time.

      -

      Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

      -

      For examples and usage, see the NTP Debugging Techniques page.

      -

      Command line options are described following. Specifying a command line option other than -i or -n will cause the specified query (queries) to be sent to the indicated host(s) immediately. Otherwise, ntpq will attempt to read interactive format commands from the standard input.

      -
      -
      -4 -
      Force DNS resolution of following host names on the command line to the IPv4 namespace. -
      -6 -
      Force DNS resolution of following host names on the command line to the IPv6 namespace. -
      -c -
      The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified host(s). Multiple -c options may be given. -
      -d -
      Turn on debugging mode. -
      -i -
      Force ntpq to operate in interactive mode. Prompts will be written to the standard output and commands read from the standard input. -
      -n -
      Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names. -
      -p -
      Print a list of the peers known to the server as well as a summary of their state. This is equivalent to the peers interactive command. -
      -

      Internal Commands

      -

      Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a >, followed by a file name, to the command line. A number of interactive format commands are executed entirely within the ntpq program itself and do not result in NTP mode 6 requests being sent to a server. These are described following.

      -
      -
      ? [command_keyword]
      - helpl [command_keyword] -
      A ? by itself will print a list of all the command keywords known to this incarnation of ntpq. A ? followed by a command keyword will print function and usage information about the command. This command is probably a better source of information about ntpq than this manual page. -
      addvars variable_name [ = value] [...]
      - rmvars variable_name [...]
      - clearvars -
      The data carried by NTP mode 6 messages consists of a list of items of the form variable_name = value, where the = value is ignored, and can be omitted, in requests to the server to read variables. ntpq maintains an internal list in which data to be included in control messages can be assembled, and sent using the readlist and writelist commands described below. The addvars command allows variables and their optional values to be added to the list. If more than one variable is to be added, the list should be comma-separated and not contain white space. The rmvars command can be used to remove individual variables from the list, while the clearlist command removes all variables from the list. -
      cooked -
      Causes output from query commands to be "cooked", so that variables which are recognized by ntpq will have their values reformatted for human consumption. Variables which ntpq thinks should have a decodable value but didn't are marked with a trailing ?. -
      debug more | less | off -
      Turns internal query program debugging on and off. -
      delay milliseconds -
      Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete. -
      host hostname -
      Set the host to which future queries will be sent. Hostname may be either a host name or a numeric address. -
      hostnames [yes | no] -
      If yes is specified, host names are printed in information displays. If no is specified, numeric addresses are printed instead. The default is yes, unless modified using the command line -n switch. -
      keyid keyid -
      This command specifies the key number to be used to authenticate configuration requests. This must correspond to a key number the server has been configured to use for this purpose. -
      ntpversion 1 | 2 | 3 | 4 -
      Sets the NTP version number which ntpq claims in packets. Defaults to 2, Note that mode 6 control messages (and modes, for that matter) didn't exist in NTP version 1. -
      passwd -
      This command prompts for a password (which will not be echoed) which will be used to authenticate configuration requests. The password must correspond to the key configured for NTP server for this purpose. -
      quit -
      Exit ntpq. -
      raw -
      Causes all output from query commands is printed as received from the remote server. The only formating/interpretation done on the data is to transform nonascii data into a printable (but barely understandable) form. -
      timeout millseconds -
      Specify a timeout period for responses to server queries. The default is about 5000 milliseconds. Note that since ntpq retries each query once after a timeout, the total waiting time for a timeout will be twice the timeout value set. -
      -

      Control Message Commands

      -

      Each association known to an NTP server has a 16 bit integer association identifier. NTP control messages which carry peer variables must identify the peer the values correspond to by including its association ID. An association ID of 0 is special, and indicates the variables are system variables, whose names are drawn from a separate name space.

      -

      Control message commands result in one or more NTP mode 6 messages being sent to the server, and cause the data returned to be printed in some format. Most commands currently implemented send a single message and expect a single response. The current exceptions are the peers command, which will send a preprogrammed series of messages to obtain the data it needs, and the mreadlist and mreadvar commands, which will iterate over a range of associations.

      -
      -
      associations -
      Obtains and prints a list of association identifiers and peer statuses for in-spec peers of the server being queried. The list is printed in columns. The first of these is an index numbering the associations from 1 for internal use, the second the actual association identifier returned by the server and the third the status word for the peer. This is followed by a number of columns containing data decoded from the status word. See the peers command for a decode of the condition field. Note that the data returned by the associations command is cached internally in ntpq. The index is then of use when dealing with stupid servers which use association identifiers which are hard for humans to type, in that for any subsequent commands which require an association identifier as an argument, the form &index may be used as an alternative. -
      clockvar [assocID] [variable_name [ = value [...]] [...] -
      cv [assocID] [variable_name [ = value [...] ][...] -
      Requests that a list of the server's clock variables be sent. Servers which have a radio clock or other external synchronization will respond positively to this. If the association identifier is omitted or zero the request is for the variables of the system clock and will generally get a positive response from all servers with a clock. If the server treats clocks as pseudo-peers, and hence can possibly have more than one clock connected at once, referencing the appropriate peer association ID will show the variables of a particular clock. Omitting the variable list will cause the server to return a default variable display. -
      lassociations -
      Obtains and prints a list of association identifiers and peer statuses for all associations for which the server is maintaining state. This command differs from the associations command only for servers which retain state for out-of-spec client associations (i.e., fuzzballs). Such associations are normally omitted from the display when the associations command is used, but are included in the output of lassociations. -
      lpassociations -
      Print data for all associations, including out-of-spec client associations, from the internally cached list of associations. This command differs from passociations only when dealing with fuzzballs. -
      lpeers -
      Like R peers, except a summary of all associations for which the server is maintaining state is printed. This can produce a much longer list of peers from fuzzball servers. -
      mreadlist assocID assocID
      - mrl assocID assocID -
      Like the readlist command, except the query is done for each of a range of (nonzero) association IDs. This range is determined from the association list cached by the most recent associations command. -
      mreadvar assocID assocID [ variable_name [ = value[ ... ]
      - mrv assocID assocID [ variable_name [ = value[ ... ] -
      Like the readvar command, except the query is done for each of a range of (nonzero) association IDs. This range is determined from the association list cached by the most recent associations command. -
      opeers -
      An old form of the peers command with the reference ID replaced by the local interface address. -
      passociations -
      Displays association data concerning in-spec peers from the internally cached list of associations. This command performs identically to the associations except that it displays the internally stored data rather than making a new query. -
      peers -
      Obtains a current list peers of the server, along with a summary of each peer's state. Summary information includes the address of the remote peer, the reference ID (0.0.0.0 if this is unknown), the stratum of the remote peer, the type of the peer (local, unicast, multicast or broadcast), when the last packet was received, the polling interval, in seconds, the reachability register, in octal, and the current estimated delay, offset and dispersion of the peer, all in milliseconds. The character at the left margin of each line shows the synchronization status of the association and is a valuable diagnostic tool. The encoding and meaning of this character, called the tally code, is given later in this page. -
      pstatus assocID -
      Sends a read status request to the server for the given association. The names and values of the peer variables returned will be printed. Note that the status word from the header is displayed preceding the variables, both in hexadecimal and in pidgeon English. -
      readlist [ assocID ]
      - rl [ assocID ] -
      Requests that the values of the variables in the internal variable list be returned by the server. If the association ID is omitted or is 0 the variables are assumed to be system variables. Otherwise they are treated as peer variables. If the internal variable list is empty a request is sent without data, which should induce the remote server to return a default display. -
      readvar assocID variable_name [ = value ] [ ...]
      - rv assocID [ variable_name [ = value ] [...] -
      Requests that the values of the specified variables be returned by the server by sending a read variables request. If the association ID is omitted or is given as zero the variables are system variables, otherwise they are peer variables and the values returned will be those of the corresponding peer. Omitting the variable list will send a request with no data which should induce the server to return a default display. The encoding and meaning of the variables derived from NTPv3 is given in RFC-1305; the encoding and meaning of the additional NTPv4 variables are given later in this page. -
      writevar assocID variable_name [ = value [ ...] -
      Like the readvar request, except the specified variables are written instead of read. -
      writelist [ assocID ] -
      Like the readlist request, except the internal list variables are written instead of read. -
      -

      Tally Codes

      -

      The character in the left margin in the peers billboard, called the tally code, shows the fate of each association in the clock selection process. Following is a list of these characters, the pigeon used in the rv command, and a short explanation of the condition revealed.

      -
      -
      space reject -
      The peer is discarded as unreachable, synchronized to this server (synch loop) or outrageous synchronization distance. -
      x  falsetick -
      The peer is discarded by the intersection algorithm as a falseticker. -
      .  excess -
      The peer is discarded as not among the first ten peers sorted by synchronization distance and so is probably a poor candidate for further consideration. -
      -  outlyer -
      The peer is discarded by the clustering algorithm as an outlyer. -
      +  candidat -
      The peer is a survivor and a candidate for the combining algorithm. -
      #  selected -
      The peer is a survivor, but not among the first six peers sorted by synchronization distance. If the association is ephemeral, it may be demobilized to conserve resources. -
      *  sys.peer -
      The peer has been declared the system peer and lends its variables to the system variables. -
      o  pps.peer -
      The peer has been declared the system peer and lends its variables to thesystem variables. However, the actual system synchronization is derived from a pulse-per-second (PPS) signal, either indirectly via the PPS reference clock driver or directly via kernel interface. -
      -

      System Variables

      -

      The status, leap, stratum, precision, rootdelay, rootdispersion, refid, reftime, poll, offset, and frequency variables are described in RFC-1305 specification. Additional NTPv4 system variables include the following.

      -
      -
      version -
      Everything you might need to know about the software version and generation time. -
      processor -
      The processor and kernel identification string. -
      system -
      The operating system version and release identifier. -
      state -
      The state of the clock discipline state machine. The values are described in the architecture briefing on the NTP Project page linked from www.ntp.org. -
      peer -
      The internal integer used to identify the association currently designated the system peer. -
      jitter -
      The estimated time error of the system clock measured as an exponential average of RMS time differences. -
      stability -
      The estimated frequency stability of the system clock measured as an exponential average of RMS frequency differences. -
      -

      When the NTPv4 daemon is compiled with the OpenSSL software library, additional system variables are displayed, including some or all of the following, depending on the particular dance:

      -
      -
      flags -
      The current flags word bits and message digest algorithm identifier (NID) in hex format. The high order 16 bits of the four-byte word contain the NID from the OpenSSL ligrary, while the low-order bits are interpreted as follows: -
      -
      -
      0x01 -
      autokey enabled -
      0x02 -
      NIST leapseconds file loaded -
      0x10 -
      PC identity scheme -
      0x20 -
      IFF identity scheme -
      0x40 -
      GQ identity scheme -
      -
      hostname -
      The name of the host as returned by the Unix gethostname() library function. -
      hostkey -
      The NTP filestamp of the host key file. -
      cert -
      A list of certificates held by the host. Each entry includes the subject, issuer, flags and NTP filestamp in order. The bits are interpreted as follows: -
      -
      -
      0x01 -
      certificate has been signed by the server -
      0x02 -
      certificate is trusted -
      0x04 -
      certificate is private -
      0x08 -
      certificate contains errors and should not be trusted -
      -
      leapseconds -
      The NTP filestamp of the NIST leapseconds file. -
      refresh -
      The NTP timestamp when the host public cryptographic values were refreshed and signed. -
      signature -
      The host digest/signature scheme name from the OpenSSL library. -
      tai -
      The TAI-UTC offset in seconds obtained from the NIST leapseconds table. -
      -

      Peer Variables

      -

      The status, srcadr, srcport, dstadr, dstport, leap, stratum, precision, rootdelay, rootdispersion, readh, hmode, pmode, hpoll, ppoll, offset, delay, dspersion, reftime variables are described in the RFC-1305 specification, as are the timestamps org, rec and xmt. Additional NTPv4 system variables include the following.

      -
      -
      flash -
      The flash code for the most recent packet received. The encoding and meaning of these codes is given later in this page. -
      jitter -
      The estimated time error of the peer clock measured as an exponential average of RMS time differences. -
      unreach -
      The value of the counter which records the number of poll intervals since the last valid packet was received. -
      -

      When the NTPv4 daemon is compiled with the OpenSSL software library, additional peer variables are displayed, including the following:

      -
      -
      flags -
      The current flag bits. This word is the server host status word with additional bits used by the Autokey state machine. See the source code for the bit encoding. -
      hostname -
      The server host name. -
      initkey key -
      The initial key used by the key list generator in the Autokey protocol. -
      initsequence index -
      The initial index used by the key list generator in the Autokey protocol. -
      signature -
      The server message digest/signature scheme name from the OpenSSL software library. -
      timestamp time -
      The NTP timestamp when the last Autokey key list was generated and signed. -
      -

      Flash Codes

      -

      The flash code is a valuable debugging aid displayed in the peer variables list. It shows the results of the original sanity checks defined in the NTP specification RFC-1305 and additional ones added in NTPv4. There are 12 tests designated TEST1 through TEST12. The tests are performed in a certain order designed to gain maximum diagnostic information while protecting against accidental or malicious errors. The flash variable is initialized to zero as each packet is received. If after each set of tests one or more bits are set, the packet is discarded.

      -

      Tests TEST1 through TEST3 check the packet timestamps from which the offset and delay are calculated. If any bits are set, the packet is discarded; otherwise, the packet header variables are saved. TEST4 and TEST5 are associated with access control and cryptographic authentication. If any bits are set, the packet is discarded immediately with nothing changed.

      -

      Tests TEST6 through TEST8 check the health of the server. If any bits are set, the packet is discarded; otherwise, the offset and delay relative to the server are calculated and saved. TEST9 checks the health of the association itself. If any bits are set, the packet is discarded; otherwise, the saved variables are passed to the clock filter and mitigation algorithms.

      -

      Tests TEST10 through TEST12 check the authentication state using Autokey public-key cryptography, as described in the Authentication Options page. If any bits are set and the association has previously been marked reachable, the packet is discarded; otherwise, the originate and receive timestamps are saved, as required by the NTP protocol, and processing continues.

      -

      The flash bits for each test are defined as follows.

      -
      -
      0x001 TEST1 -
      Duplicate packet. The packet is at best a casual retransmission and at worst a malicious replay. -
      0x002 TEST2 -
      Bogus packet. The packet is not a reply to a message previously sent. This can happen when the NTP daemon is restarted and before somebody else notices. -
      0x004 TEST3 -
      Unsynchronized. One or more timestamp fields are invalid. This normally happens when the first packet from a peer is received. -
      0x008 TEST4 -
      Access is denied. See the Access Control Options page. -
      0x010 TEST5 -
      Cryptographic authentication fails. See the Authentication Options page. -
      0x020TEST6 -
      The server is unsynchronized. Wind up its clock first. -
      0x040 TEST7 -
      The server stratum is at the maximum than 15. It is probably unsynchronized and its clock needs to be wound up. -
      0x080 TEST8 -
      Either the root delay or dispersion is greater than one second, which is highly unlikely unless the peer is unsynchronized to Mars. -
      0x100 TEST9 -
      Either the peer delay or dispersion is greater than one second, which is higly unlikely unless the peer is on Mars. -
      0x200 TEST10 -
      The autokey protocol has detected an authentication failure. See the Authentication Options page. -
      0x400 TEST11 -
      The autokey protocol has not verified the server or peer is proventic and has valid public key credentials. See the Authentication Options page. -
      0x800 TEST12 -
      A protocol or configuration error has occurred in the public key algorithms or a possible intrusion event has been detected. See the Authentication Options page. -
      -

      Bugs

      -

      The peers command is non-atomic and may occasionally result in spurious error messages about invalid associations occurring and terminating the command. The timeout time is a fixed constant, which means you wait a long time for timeouts since it assumes sort of a worst case. The program should improve the timeout estimate as it sends queries to a particular host, but doesn't.

      -
      - - - - \ No newline at end of file + + + +ntpq - standard NTP query program + + + +

      ntpq - standard NTP query program

      +giffrom Pogo, Walt Kelly +

      A typical NTP monitoring packet

      +

      Last update: + 31-Jan-2014 06:54 + UTC

      +
      +

      More Help

      + +
      +

      Synopsis

      +ntpq [-46dinp] [-c command] [host] [...] +

      Description

      +

      The ntpq utility program is used to monitor NTP daemon ntpd operations + and determine performance. It uses the standard NTP mode 6 control + message formats defined in Appendix B of the NTPv3 specification + RFC1305. The same formats are used in NTPv4, although some of the + variable names have changed and new ones added. The description + on this page is for the NTPv4 variables.

      +

      The program can be run either in interactive mode or controlled using command line arguments. Requests to read and write arbitrary variables can be assembled, with raw and pretty-printed output options being available. The ntpq can also obtain and print a list of peers in a common format by sending multiple queries to the server.

      +

      If one or more request options is included on the command line when ntpq is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, ntpq will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. ntpq will prompt for commands if the standard input is a terminal device.

      +

      ntpq uses NTP mode 6 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. ntpq makes one attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time.

      +

      Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.

      +

      For examples and usage, see the NTP Debugging Techniques page.

      +

      Command line options are described following. Specifying a command line option other than -i or -n will cause the specified query (queries) to be sent to the indicated host(s) immediately. Otherwise, ntpq will attempt to read interactive format commands from the standard input.

      +
      +
      -4
      +
      Force DNS resolution of following host names on the command line to the IPv4 namespace.
      +
      -6
      +
      Force DNS resolution of following host names on the command line to the IPv6 namespace.
      +
      -c
      +
      The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified host(s). Multiple -c options may be given.
      +
      -d
      +
      Turn on debugging mode.
      +
      -i
      +
      Force ntpq to operate in interactive mode. Prompts will be written to the standard output and commands read from the standard input.
      +
      -n
      +
      Output all host addresses in dotted-quad numeric format rather than converting to the canonical host names.
      +
      -p
      +
      Print a list of the peers known to the server as well as a summary of their state. This is equivalent to the peers interactive command.
      +
      +

      Internal Commands

      +

      Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a >, followed by a file name, to the command line. A number of interactive format commands are executed entirely within the ntpq program itself and do not result in NTP mode-6 requests being sent to a server. These are described following.

      +
      +
      ? [command_keyword]
      + help [command_keyword]
      +
      A ? by itself will print a list of all the command keywords known to ntpq. A ? followed by a command keyword will print function and usage information about the command.
      +
      addvars name [ = value] [...]
      + rmvars name [...]
      + clearvars
      +
      The arguments to this command consist of a list of items of the form name = value, where the = value is ignored, and can be omitted in read requests. ntpq maintains an internal list in which data to be included in control messages can be assembled, and sent using the readlist and writelist commands described below. The addvars command allows variables and optional values to be added to the list. If more than one variable is to be added, the list should be comma-separated and not contain white space. The rmvars command can be used to remove individual variables from the list, while the clearlist command removes all variables from the list.
      +
      cooked
      +
      Display server messages in prettyprint format.
      +
      debug more | less | off
      +
      Turns internal query program debugging on and off.
      +
      delay milliseconds
      +
      Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete.
      +
      host name
      +
      Set the host to which future queries will be sent. The name may be either a DNS name or a numeric address.
      +
      hostnames [yes | no]
      +
      If yes is specified, host names are printed in information displays. If no is specified, numeric addresses are printed instead. The default is yes, unless modified using the command line -n switch.
      +
      keyid keyid
      +
      This command specifies the key number to be used to authenticate configuration requests. This must correspond to a key ID configured in ntp.conf for this purpose.
      +
      keytype
      +
      Specify the digest algorithm to use for authenticated requests, with default MD5. If the OpenSSL library is installed, digest can be be any message digest algorithm supported by the library. The current selections are: MD2, MD4, MD5, MDC2, RIPEMD160, SHA and SHA1.
      +
      ntpversion 1 | 2 | 3 | 4
      +
      Sets the NTP version number which ntpq claims in packets. Defaults to 2, Note that mode-6 control messages (and modes, for that matter) didn't exist in NTP version 1.
      +
      passwd
      +
      This command prompts for a password to authenticate requests. The password must correspond to the key ID configured in ntp.conf for this purpose.
      +
      quit
      +
      Exit ntpq.
      +
      raw
      +
      Display server messages as received and without reformatting.
      +
      timeout millseconds
      +
      Specify a timeout period for responses to server queries. The default is about 5000 milliseconds. Note that since ntpq retries each query once after a timeout, the total waiting time for a timeout will be twice the timeout value set.
      +
      +

      Control Message Commands

      +

      Association IDs are used to identify system, peer and clock variables. System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. Most control commands send a single mode-6 message to the server and expect a single response message. The exceptions are the peers command, which sends a series of messages, and the mreadlist and mreadvar commands, which iterate over a range of associations.

      +
      +
      associations
      +
      Display a list of mobilized associations in the form
      +
      ind assid status conf reach auth condition last_event cnt
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      VariableDescription
      indindex on this list
      assidassociation ID
      statuspeer status word
      confyes: persistent, no: ephemeral
      reachyes: reachable, no: unreachable
      authok, yes, bad and none
      conditionselection status (see the select field of the peer status word)
      last_eventevent report (see the event field of the peer status word)
      cntevent count (see the count field of the peer status word)
      +
      +
      clockvar assocID [name [ = value [...]] [...]
      + cv assocID [name [ = value [...] ][...]
      +
      Display a list of clock variables for those associations supporting a reference clock.
      +
      :config [...]
      +
      Send the remainder of the command line, including whitespace, to the server as a run-time configuration command in the same format as the configuration file. This command is experimental until further notice and clarification. Authentication is of course required.
      +
      config-from-file filename
      +
      Send the each line of filename to the server as run-time configuration commands in the same format as the configuration file. This command is experimental until further notice and clarification. Authentication is required.
      +
      ifstats
      +
      Display statistics for each local network address. Authentication is required.
      +
      iostats
      +
      Display network and reference clock I/O statistics.
      +
      kerninfo
      +
      Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable.
      +
      lassociations
      +
      Perform the same function as the associations command, except display mobilized and unmobilized associations.
      +
      monstats
      +
      Display monitor facility statistics.
      +
      mrulist [limited | kod | mincount=count | laddr=localaddr | sort=sortorder | resany=hexmask | resall=hexmask]
      +
      Obtain and print traffic counts collected and maintained by the monitor facility. With the exception of sort=sortorder, the options filter the list returned by ntpd. The limited and kod options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. The mincount=count option filters entries representing less than count packets. The laddr=localaddr option filters entries for packets received on any local address other than localaddr. resany=hexmask and resall=hexmask filter entries containing none or less than all, respectively, of the bits in hexmask, which must begin with 0x.
      +
      The sortorder defaults to lstint and may be any of addr, count, avgint, lstint, or any of those preceded by a minus sign (hyphen) to reverse the sort order. The output columns are: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      ColumnDescription
      lstintInterval in s between the receipt of the most recent packet from this address and the completion of the + retrieval of the MRU list by ntpq.
      avgintAverage interval in s between packets from this address.
      rstrRestriction flags associated with this address. Most are copied unchanged from the matching restrict command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this + address triggered a rate control response.
      rRate control indicator, either a period, L or K for no rate control response, + rate limiting by discarding, or rate limiting with a KoD response, respectively.
      mPacket mode.
      vPacket version number.
      countPackets received from this address.
      rportSource port of last packet from this address.
      remote addressDNS name, numeric address, or address followed by claimed DNS name which + could not be verified in parentheses.
      +
      +
      mreadvar assocID assocID [ variable_name [ = value[ ... ]
      +
      mrv assocID assocID [ variable_name [ = value[ ... ]
      +
      Perform the same function as the readvar command, except for a range of association IDs. This range is determined from the association list cached by the most recent associations command.
      +
      passociations
      +
      Perform the same function as the associations command, except that it uses previously stored data rather than making a new query.
      +
      peers
      +
      Display a list of peers in the form
      +
      [tally]remote refid st t when pool reach delay offset jitter
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      VariableDescription
      [tally]single-character code indicating current value of the select field of the peer status word
      remotehost name (or IP number) of peer
      refidassociation ID or kiss code
      ststratum
      tu: unicast or manycast client, b: + broadcast or multicast client, l: local (reference clock), s: symmetric (peer), A: manycast server, B: + broadcast server, M: multicast server
      whensec/min/hr since last received packet
      pollpoll interval (log2 s)
      reachreach shift register (octal)
      delayroundtrip delay
      offsetoffset of server relative to this host
      jitterjitter
      +
      +
      readvar assocID name [ = value ] [,...]
      + rv assocID [ name ] [,...]
      +
      Display the specified variables. If assocID is zero, the + variables are from the system variables name space, + otherwise they are from the peer variables name space. + The assocID is required, as the same name can occur in both spaces. If no name is + included, all operative variables in the name space are displayed. + In this case only, if the assocID is omitted, it is assumed zero. Multiple + names are specified with comma separators and without whitespace. + Note that time values are represented in milliseconds and frequency + values in parts-per-million (PPM). Some NTP timestamps are represented + in the format YYYYMMDDTTTT, where YYYY is the year, MM the month + of year, DD the day of month and TTTT the time of day.
      +
      saveconfig filename
      +
      Write the current configuration, including any runtime modifications given with :config or config-from-file, to the ntpd host's file filename. This command will be rejected by the server unless saveconfigdir appears in the ntpd configuration file. filename can use strftime() format specifies to substitute the current date and time, for example, saveconfig ntp-%Y%m%d-%H%M%S.conf. The filename used is stored in system variable savedconfig. Authentication is required.
      +
      writevar assocID name = value [,...]
      +
      Write the specified variables. If the assocID is zero, the variables are from the system variables name space, otherwise they are from the peer variables name space. The assocID is required, as the same name can occur in both spaces.
      +
      sysinfo
      +
      Display operational summary.
      +
      sysstats
      +
      Print statistics counters maintained in the protocol module.
      +
      +

      Status Words and Kiss Codes

      +

      The current state of the operating program is shown in a set of status words maintained by the system and each association separately. These words are displayed in the rv and as commands both in hexadecimal and decoded short tip strings. The codes, tips and short explanations are on the Event Messages and Status Words page. The page also includes a list of system and peer messages, the code for the latest of which is included in the status word.

      +

      Information resulting from protocol machine state transitions is displayed using an informal set of ASCII strings called kiss codes. The original purpose was for kiss-o'-death (KoD) packets sent by the server to advise the client of an unusual condition. They are now displayed, when appropriate, in the reference identifier field in various billboards.

      +

      System Variables

      +

      The following system variables appear in the rv billboard. Not all variables are displayed in some configurations.

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      VariableDescription
      statussystem status word
      versionNTP software version and build time
      processorhardware platform and version
      systemoperating system and version
      leapleap warning indicator (0-3)
      stratumstratum (1-15)
      precisionprecision (log2 s)
      rootdelaytotal roundtrip delay to the primary reference clock
      rootdisptotal dispersion to the primary reference clock
      peersystem peer association ID
      tctime constant and poll exponent (log2 s) (3-17)
      mintcminimum time constant (log2 s) (3-10)
      clockdate and time of day
      refidreference ID or kiss code
      reftimereference time
      offsetcombined offset of server relative to this host
      sys_jittercombined system jitter
      frequency frequency offset (PPM) relative to hardware clock
      clk_wanderclock frequency wander (PPM)
      clk_jitterclock jitter
      taiTAI-UTC offset (s)
      leapsecNTP seconds when the next leap second is/was inserted
      expireNTP seconds when the NIST leapseconds file expires
      +
      +
      The jitter and wander statistics are exponentially-weighted RMS averages. + The system jitter is defined in the NTPv4 specification; the + clock jitter statistic is computed by the clock discipline module.
      +
      When the NTPv4 daemon is compiled with the OpenSSL software library, additional + system variables are displayed, including some or all of the following, depending + on the particular Autokey dance:
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      VariableDescription
      hostAutokey host name for this host
      identAutokey group name for this host
      flagshost flags (see Autokey specification)
      digestOpenSSL message digest algorithm
      signatureOpenSSL digest/signature scheme
      updateNTP seconds at last signature update
      certcertificate subject, issuer and certificate flags
      untilNTP seconds when the certificate expires
      +

      Peer Variables

      +

      The following peer variables appear in the rv billboard for each association. Not all variables are displayed in some configurations.

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      VariableDescription
      associdassociation ID
      statuspeer status word
      srcadr
      + srcport
      source (remote) IP address and port
      dstadr
      + dstport
      destination (local) IP address and port
      leapleap indicator (0-3)
      stratumstratum (0-15)
      precisionprecision (log2 s)
      rootdelaytotal roundtrip delay to the primary reference clock
      rootdisptotal root dispersion to the primary reference clock
      refidreference ID or kiss code
      reftimereference time
      reachreach register (octal)
      unreachunreach counter
      hmodehost mode (1-6)
      pmodepeer mode (1-5)
      hpollhost poll exponent (log2 s) (3-17)
      ppollpeer poll exponent (log2 s) (3-17)
      headwayheadway (see Rate Management and the Kiss-o'-Death Packet)
      flashflash status word
      offsetfilter offset
      delayfilter delay
      dispersionfilter dispersion
      jitterfilter jitter
      identAutokey group name for this association
      biasunicast/broadcast bias
      xleaveinterleave delay (see NTP Interleaved Modes)
      +

      The bias variable is calculated when the first broadcast packet is received + after the calibration volley. It represents the offset of the broadcast + subgraph relative to the unicast subgraph. The xleave variable appears + only the interleaved symmetric and interleaved modes. It represents + the internal queuing, buffering and transmission delays for the preceding + packet.

      +

      When the NTPv4 daemon is compiled with the OpenSSL software library, additional peer variables are displayed, including the following:

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      VariableDescription
      flagspeer flags (see Autokey specification)
      hostAutokey server name
      flagspeer flags (see Autokey specification)
      signatureOpenSSL digest/signature scheme
      initsequenceinitial key ID
      initkeyinitial key index
      timestampAutokey signature timestamp
      +

      Clock Variables

      +

      The following clock variables appear in the cv billboard for each association with a reference clock. Not all variables are displayed in some configurations.

      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      VariableDescription
      associdassociation ID
      statusclock status word
      devicedevice description
      timecodeASCII time code string (specific to device)
      pollpoll messages sent
      noreplyno reply
      badformatbad format
      baddatabad date or time
      fudgetime1fudge time 1
      fudgetime2fudge time 2
      stratumdriver stratum
      refiddriver reference ID
      flagsdriver flags
      +
      + + + diff --git a/contrib/ntp/html/ntptime.html b/contrib/ntp/html/ntptime.html index a9ea33b5f..8f1476106 100644 --- a/contrib/ntp/html/ntptime.html +++ b/contrib/ntp/html/ntptime.html @@ -1,48 +1,46 @@ - - - - - - ntptime - read kernel time variables - - - - -

      ntptime - read kernel time variables

      - giffrom Pogo, Walt Kelly -

      The turtle has been swimming in the kernel.

      -

      Last update: 18:46 UTC Thursday, July 28, 2005

      -
      -
      -

      Synopsis

      - ntptime [ -chr ] [ -e est_error ] [ -f frequency ] [ -m max_error ] [ -o offset ] [ -s status ] [ -t time_constant] -

      Description

      -

      This program is useful only with special kernels described in the A Kernel Model for Precision Timekeeping page. It reads and displays time-related kernel variables using the ntp_gettime() system call. A similar display can be obtained using the ntpdc program and kerninfo command.

      -

      Options

      -
      -
      -c -
      Display the execution time of ntptime itself. -
      -e est_error -
      Specify estimated error, in microseconds. -
      -f frequency -
      Specify frequency offset, in parts per million. -
      -h -
      Display help information. -
      -m max_error -
      Specify max possible errors, in microseconds. -
      -o offset -
      Specify clock offset, in microseconds. -
      -r -
      Display Unix and NTP times in raw format. -
      -s status -
      Specify clock status. Better know what you are doing. -
      -t time_constant -
      Specify time constant, an integer in the range 0-10. -
      -
      - - - - \ No newline at end of file + + + +ntptime - read and set kernel time variables + + + +

      ntptime - read and set kernel time variables

      +giffrom Pogo, Walt Kelly +

      The turtle has been swimming in the kernel.

      +

      Last update: + 11-Sep-2010 05:55 + UTC

      +
      +
      +

      Synopsis

      +ntptime [ -chr ] [ -e est_error ] [ -f frequency ] [ -m max_error ] [ -o offset ] [ -s status ] [ -t time_constant] +

      Description

      +

      This program is useful only with special kernels described in the A Kernel Model for Precision Timekeeping page. It reads and displays time-related kernel variables using the ntp_gettime() system call. A similar display can be obtained using the ntpdc program and kerninfo command.

      +

      Options

      +
      +
      -c
      +
      Display the execution time of ntptime itself.
      +
      -e est_error
      +
      Specify estimated error, in microseconds.
      +
      -f frequency
      +
      Specify frequency offset, in parts per million.
      +
      -h
      +
      Display help information.
      +
      -m max_error
      +
      Specify max possible errors, in microseconds.
      +
      -o offset
      +
      Specify clock offset, in microseconds.
      +
      -r
      +
      Display Unix and NTP times in raw format.
      +
      -s status
      +
      Specify clock status. Better know what you are doing.
      +
      -t time_constant
      +
      Specify time constant, an integer in the range 0-10.
      +
      +
      + + + diff --git a/contrib/ntp/html/ntptrace.html b/contrib/ntp/html/ntptrace.html index 3b533f9ec..bd47bd977 100644 --- a/contrib/ntp/html/ntptrace.html +++ b/contrib/ntp/html/ntptrace.html @@ -1,49 +1,42 @@ - - - - - - ntptrace - trace a chain of NTP servers back to the primary source - - - - -

      ntptrace - trace a chain of NTP servers back to the primary source

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      The rabbit knows the way back.

      -

      Last update: 18:47 UTC Thursday, July 28, 2005

      -
      -
      -

      Synopsis

      - ntptrace [ -vdn ] [ -r retries ] [ -t timeout ] [ server ] -

      Description

      -

      ntptrace determines where a given Network Time Protocol (NTP) server gets its time from, and follows the chain of NTP servers back to their master time source. If given no arguments, it starts with localhost. Here is an example of the output from ntptrace:

      -
      +
      +
      +
      +ntptrace - trace a chain of NTP servers back to the primary source
      +
      +
      +
      +

      ntptrace - trace a chain of NTP servers back to the primary source

      +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

      The rabbit knows the way back.

      +

      Last update: + 31-Jan-2014 06:54 + UTC

      +
      +
      +

      Synopsis

      +ntptrace [ -n ] [ -m maxhosts ] [ server ] +

      Description

      +

      ntptrace is a perl script that uses the ntpq utility program to follow the chain of NTP servers from a given host back to the primary time source. For ntptrace to work properly, each of these servers must implement the NTP Control and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets.

      +

      If given no arguments, ntptrace starts with localhost. Here is an example of the output from ntptrace:

      +
       % ntptrace
       localhost: stratum 4, offset 0.0019529, synch distance 0.144135
       server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784
       usndh.edu: stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB'
       
      -

      On each line, the fields are (left to right): the host name, the host stratum, the time offset between that host and the local host (as measured by ntptrace; this is why it is not always zero for "localhost"), the host synchronization distance, and (only for stratum-1 servers) the reference clock ID. All times are given in seconds. Note that the stratum is the server hop count to the primary source, while the synchronization distance is the estimated error relative to the primary source. These terms are precisely defined in RFC-1305.

      -

      Options

      -
      -
      -d -
      Turns on some debugging output. -
      -n -
      Turns off the printing of host names; instead, host IP addresses are given. This may be useful if a nameserver is down. -
      -r retries -
      Sets the number of retransmission attempts for each host (default = 5). -
      -t timeout -
      Sets the retransmission timeout (in seconds) (default = 2). -
      -v -
      Prints verbose information about the NTP servers. -
      -

      Bugs

      -

      This program makes no attempt to improve accuracy by doing multiple samples.

      -
      - - - - \ No newline at end of file +

      On each line, the fields are (left to right): the host name, the host stratum, the time offset between that host and the local host (as measured by ntptrace; this is why it is not always zero for "localhost"), the host synchronization distance, and (only for stratum-1 servers) the reference clock ID. All times are given in seconds. Note that the stratum is the server hop count to the primary source, while the synchronization distance is the estimated error relative to the primary source. These terms are precisely defined in RFC-1305.

      +

      Options

      +
      +
      -m max_hosts
      +
      Sets the upper limit of the number of hosts to check (default: unlimited).
      +
      -n
      +
      Turns off the printing of host names; instead, host IP addresses are given. This may be useful if a nameserver is down.
      +
      +

      Bugs

      +

      This program makes no attempt to improve accuracy by doing multiple samples.

      +
      + + + diff --git a/contrib/ntp/html/orphan.html b/contrib/ntp/html/orphan.html new file mode 100644 index 000000000..3174c8e29 --- /dev/null +++ b/contrib/ntp/html/orphan.html @@ -0,0 +1,42 @@ + + + + + +Orphan Mode + + + +

      Orphan Mode

      +

      Last update: + 4-Aug-2011 23:40 + UTC

      +
      +

      Sometimes an NTP subnet becomes isolated from all UTC sources such as local reference clocks or Internet time servers. In such cases it may be necessary that the subnet servers and clients remain synchronized to a common timescale, not necessarily the UTC timescale. Previously, this function was provided by the local clock driver to simulate a UTC source. A server with this driver could be used to synchronize other hosts in the subnet directly or indirectly.

      +

      There are many disadvantages using the local clock driver, primarily that the subnet is vulnerable to single-point failures and multiple server redundancy is not possible. Orphan mode is intended to replace the local clock driver. It provides a single simulated UTC source with multiple servers and provides seamless switching as servers fail and recover.

      +

      A common configuration for private networks includes one or more core servers operating at the lowest stratum. Good practice is to configure each of these servers as backup for the others using symmetric or broadcast modes. As long as at least one core server can reach a UTC source, the entire subnet can synchronize to it.

      +

      If no UTC sources are available to any core server, one of them can provide a simulated UTC source for all other hosts in the subnet. However, only one core server can simulate the UTC source and all direct dependents, called orphan children, must select the same server, called the orphan parent.

      +

      Hosts sharing the same common subnet, including potential orphan parents and potential orphan children, can be enabled for orphan mode using the orphan stratum option of the tos command, where stratum is some stratum less than 16 and greater than any anticipated stratum that might occur with configured Internet time servers. However, sufficient headroom should remain so every subnet host dependent on the orphan children has stratum less than 16. Where no associations for other servers or reference clocks are configured, the orphan stratum can be set to 1. These are the same considerations that guide the local clock driver stratum selection.

      +

      In order to avoid premature enabling orphan mode, a holdoff delay occurs when the daemon is first started and when all sources have been lost after that. The delay is intended to allow time for other sources to become reachable and selectable. Only when the delay has expired with no sources will orphan mode be enabled. By default the delay is 300 s (five minutes), but this can be changed using the orphanwait option of the tos command.

      +

      A orphan parent with no sources shows reference ID LOOP if + operating at stratum 1 and 127.0.0.1 (IPv4 loopback address) otherwise. + While ordinary NTP clients use a selection metric based on delay + and dispersion, orphan children use a metric computed from the IP + address of each core server. Each orphan child chooses the orphan + parent as the core server with the smallest metric.

      +

      For orphan mode to work well, each core server with available sources should operate at the same stratum. All core servers and orphan children should include the same tos command in the configuration file. Each orphan child should include in the configuration file all root servers.

      +
      gif +

      Figure 1. Orphan Peer Configuration

      +
      +

      For example, consider the peer network configuration in Figure 1, where two or more campus primary or secondary (stratum 2) servers are configured with reference clocks or public Internet primary servers and with each other using symmetric modes. With this configuration a server that loses all sources continues to discipline the system clock using the other servers as backup. Only the core servers and orphan children need to be enabled for orphan mode.

      +
      gif +

      Figure 2. Orphan Broadcast Configuration

      +
      +

      For broadcast networks each core server is configured in both broadcast server and broadcast client modes as shown in Figure 2. Orphan children operate as broadcast clients of all core servers. As in peer networks, the core servers back up each other and only they and the orphan children need to be enabled for orphan mode.

      +

      In normal operation subnet hosts operate below stratum 5, so the subnet is automatically configured as described in the NTP specification. If all UTC sources are lost, all core servers become orphans and the orphan children will select the same core server to become the orphan parent.

      +
      +

      + +

      + + diff --git a/contrib/ntp/html/parsedata.html b/contrib/ntp/html/parsedata.html index 301d8e7de..4d3734b91 100644 --- a/contrib/ntp/html/parsedata.html +++ b/contrib/ntp/html/parsedata.html @@ -12,6 +12,9 @@

      NTP PARSE clock data formats

      The parse driver currently supports several clocks with different query mechanisms. In order for you to find a sample that might be similar to a clock you might want to integrate into parse I'll sum up the major features of the clocks (this information is distributed in the parse/clk_*.c and ntpd/refclock_parse.c files).

      +

      Last update: + 21-Oct-2010 23:44 + UTC


      Meinberg clocks

      @@ -346,4 +349,4 @@ Meinberg: start=<STX>, end=<ETX>, sync on start
       		
       	
       
      -
      \ No newline at end of file
      +
      diff --git a/contrib/ntp/html/parsenew.html b/contrib/ntp/html/parsenew.html
      index 4f11a463b..244612f84 100644
      --- a/contrib/ntp/html/parsenew.html
      +++ b/contrib/ntp/html/parsenew.html
      @@ -11,6 +11,9 @@
       	
       		

      How to build new PARSE clocks

      Here is an attempt to sketch out what you need to do in order to add another clock to the parse driver: Currently the implementation is being cleaned up - so not all information in here is completely correct. Refer to the included code where in doubt.

      +

      Last update: + 13-Oct-2010 00:33 + UTC

      Prerequisites:

      _`v7d0`DDL24b4rsIz<(BQ`xhoh9K+ax5z{g;Ut-ZUsWPW1H{Uf+!E zXTH4KTNGKVcL*aF8dDF{Yl!0y=6RL)aehCjAuc-|n$}c!m4}VF(BY(13PzegROG!^ zw1BMs`Gs6=d{$78s4LUj`d_Z?U6RHco>=czvNP~7N6UUXPNq zF#E9~y)1etBYoZRSJ$-WDL0TGZa4r z4L`XxHywLE7<>12>Bg@`6R}Qv?*B)Z-Y(i^CT*ATbJL$oC3veO?1e2BlfJ5;>cO(0 zg4i(Xp~Av*&d-krRgl;Pdv{awnk_q!lJozfGd)(HQ;;?f6m9Pyaom8iQXP&R0lXz) z*|o?(eXa!f@aMJl&n*F@gTF*<-BEZj8zVJ62!9>a;nkX-e(r)kR(<1bcjtWVfH>vG zvyX*{yvo0@>P2o9JWug9bA>u|{14@{l~_&>9=%9rr`P;`X=PQ^iO0k>D3&dpYqWYz z7+G}UxW*#&2!dGUn#vXa8JgaGtXx(RBkAhRk*D`g68b|AzFP=+i5GmyC}hpR_eL0b z*k8?0ioLM8n*IszF1s?||0IYo-M7FZOP^C2#8JK7jr?7ZP0aOrwiQW_9b1={_{YM3 zNqd7zE-)PGc7PdsH5XSQP*vI82c@;nQx8_sf4f)ud%?-W2!&*P_%(s+zu2i0PrCK! z_@D4^?ST|W75|*N`)!KmcFH4zd388_AS0phXGw8(73sjd!}A{45HQ+@Wh0vL9W~#J za3jn`(`LM=7E?y2At)AJZ-MkvE2X;&%-8$!c&EORsD4P<+_?SPSNF#?Q(OtLfRJE_ z+0+=5sQA24M@ZCsUf8eRvh#D!AL<1Oyi#5PuIho^+4$Wq1vFwQIr98L!I|w?)hDO3 zL1x>?|Jo*g4hrt1?Xeub8P0e`vm~qnvHm|^NFMZN(f`^bwa7n+{mA8PR~Bs+oSEO5 zeoj~ldh_@8=WQEvS$Bm&RA6aQ7GAW-Tj48MI6{0CMrRu?`E8Z6kJUwNf!8lKF!!!m zRFEja(qbs!wf=w~;e=*Xf&YiN@)%P>}_dge6Gpw*by|p)|(`qOfLt5(lD0-N*;rz9yVNl5aVm9HbD)y7DbYP{K&QBHn56<*o_p z>(Qr)vrlAtZaz2H^5yBFiGa0Pl*SI%IWw_m)b=N5tgEDe$i*+cL)nd5?=|5975T?A zibZVPKEo~`!3jhu!4GqOIF%oqkYBqI&1HeX)y3`671gZVV0NY6{L4{*%*y`8@JZKo zURG1=eAkYQa=JBEp7Q4OF_-W{rdL(UC?>`Q5Kgdsyk0JdgeY9vb=QbKr(J|Gb6|ys zsoKwdvqP0`%(LGhF0$Gv@y^2))U$mC5>NFr`AOHCIiWA3sx{=l`n#_bEpl#5p?e!- zAANprTf>n`j1{KPJd{>nTW$SvcWi<99V4c(uQ~>0yn{Bpx{{E)bnJ5d@YzrN=e>4Z zx9Lp^4*nqJ{Dxx1>0|?UBYyt#bj5Z1;4Polo_yx9$RQWHqdys=R6T!uE^EHR*eY{o zr82f%Vs)Bq15>`arK7QVDtyYj@p9R=S)bmC=xzr>vve^yo4j2~28Gln#IddQ=UdM3 z!93_N;$<&1ZJ&GORsGqy_b5((kp+sMNNf2K&fDrwMmYRZa|hrobg(@EAJw7D#jok$ g6#cMuoTK5C2waNY_h!44aF2Glluk=wq9Ex10kR^!%K!iX literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/tribeb.gif b/contrib/ntp/html/pic/tribeb.gif new file mode 100644 index 0000000000000000000000000000000000000000..59e8a7c48706c4192f3c6101cabebe75be862050 GIT binary patch literal 30287 zcmWh!d0Z0d|DOvO4iOZuybv!m4>S)_v%wS163a@>3QNn%ip+{_tsPF$tgx)?GBhi@ zsjRiK0yLu=%UUaIQLD9YZA-`Qvb*j2^Ea>gduE>J^L*xcUr%OM27hvi9q0i51OU1d z8*z(vO)6lo*VC%>VA+0xA8K@8AaPR4h4=)1@K;9s?j#`rn6L*|w zpt@2zpIp2#a5*r^w`P|jZBBB9X7QD$XV2YkColl~VCBRp?t-V(kdyJB7qDuXdj>Sz3c5otpJ) z%2rKl)8kQzjH`F$eJ|S|zd92Xfd+<=-MxvtIFF7y3slsynam8XA6a^a8)zGPAd@{FU{7L=?k#FXu-0?zjYipXg}1mw5BOp!dNv zS2xNvL(}kUFv#cm&X|Nep9ZvFMw!O_tHyM5Gdx7lo?zx?vE-3E;OjM{CC=lvdb8~a#Wa(bHY zqLReH7cI}9b$)sce*GW$=>u20jTawFwcD_zrIYNR@a`K+-oM>*VDIuje*s_i`F|ds zI602W_94y4W^GZ1+uzT7-Y>s!R{HSH_P&RgGB7AH4jy^nXuQ0}J^=jw6MFBW&!yv; zou>+ZJS7ef0&I_6@BbM3`9;?Gw(RfLB%5#4+AYARdk)j45<>h*Q~9i^lRds)Gxh2j z$)htay(i*hBi+6X?bDy!Z8re#uA&c41Yd87FE8}}{mt=f9Xme^U4A$6;OFxbo}XdI zhtsd0-So%D$I}zh5H^9!MhyoNOXtR1JJ;~_G&0mi9X{%e#d-bI0DWjCTlVwT%<cvernThGai^ElVG{cRn<^9Js31nna|_EC#% z#Ij)qYxLEl5Le*Wx38{gOD`X9vX2goTE`zXI>i?az7P*KzOe8<`(x!%LmQp4rkW?rhRfAPDzm? zgov0mU)Hd1?B*@Lb0F)&(UiPkHcx0UU=T`>H`ik=WCmM@L8lU^7z1l1ko;Vqb=5hAzW9+lbL7s!X+K(>=@8x=!(d^w7H1y>xT7;D zh#>z1J9Z6;w?L=aJ2Lz9nKyTv5-GF#UN2XZxSNuj0K*Cp^a?_x_)x8vqw}HFl2jPXNu4~_4d4I+C71ndx!9TB=2g;Xnj>@4J{MKqXYnT{4+Ojk=g4^|rRS`GT zmlk|5Up5$#VeS*UHi^&A$nXY4xANe?!*>(z1(-djIHVNJ^^bU@a?SBZ0RV>XnYVMy z<*mc34(Y&@`k4);UQUxGrL_LZ*QHv-5ubypEAwYj!+!b@G(&z!c=+XxT<`8JzIZ$M zR?%)=O!qP9;~7Dr=DykR@)$WKY-;PDTlXxz(0C)VNHU0;SdXM?x6%d*;#Ps7_n_f~wK!JnMdFe7wt(&rhz z|LfXum-Au~ku>FThktI|uG@aJ@CV%1c~{6sAI~`H_%x-q>u38gHELT&j`=PxcrZF( zgO*E*_*~k$HuRAB3pw;i=i#+MPfqw{dF}9;a4!EhG@mr#QOC%(*pHeEGosIz?v03l z*|Esc>-~q+^NN)RpfAtL5B-aBG>pnD9dubC3EEaaqIq!My68^ahTt(Ta`e*}+1E!^ zLwV`J{LJ;j@Q%u)i-W;$wkn z`;`8w#}2XAzJA&2eX%||n|sk#d5=GO_sjh_W6y$5m?nfI4^Yw>4zm1Y2%h%L| z8CqOBL`u&3AtH}I;_~Z2&A#;t`Ud^5_a`9r9q+Jgw1+*p@7*?F%m~}A6J?^qCF6OK}FUmx(08oCH$-^f_#vJ_<@$AP)LGFSU z$`Qw;j_yUj7+J61mYf_ymP~YR0)GAaOZV%>H`;*qZjO5iX%-{WwN-11XM~?sn=&7gV>i z+X`+mMj_z&O9Q#Q9scm)7bN)gcH~xlchtf)^&-8Ab^M>6sD1dB**&eabCS%2`X3FM zIm2s*r0R&Y$xNT57K-y7)%~DF%Ce+s)WlJRZz(<|_qfLOLoK;S1E+HmT8y?|L-KGWZt-aKvh7iN!0^~rqMAS~rL{XKBgZF`Y6 z%vwTP*!2E_39Jbc3P{c&tf|DF*#%?!*rXt|eQpU)5!t`Px$I(QqK$VcjLV^vo(NOgPyC zyV(swyUe+ZeOkclBTZ=+c>Ev=XYW2on>M}aF;SD$bU7kH0z0oiw`FVoVz(PCb7JzEI>G|T`N-RI zn3w>iqWMq*^~h3joXN3JBy*_zSMg%i#l8hE1@yQ4K83h-<^JRsxKS6r^#ewD zaSiopzpu_++QvNYs)gC3 zMWXZ5UuhLO*<|@o>;!RYN8eErCK-O@Q3CsznDn@UE>0b0^y-$80y@$>nstjzK0{>6 zog(^{F+(bM&MTt8_xqFA2|W=Xr)UFzkdb6WJ1yT>H69JcieCCD^6YDjU&qQXVjc7UR@kl#+)pY zJ1t)!zdQ^s$|fp#HujKjzm6Eh1JUA-zlEcn8lAVqBloZe8&#T3@yqMfiGxP^>OuHDnw2r;YLaP$ z$cXnv+O6H;pSSIN=I&Z1CKS&|X7DV2(e$@~d_+X=l86xj*}|Z`aicZ=`JKwd zJd9JXTj?qr^@fg6iv95WPl!DpIm|BamfmqR)ULtleADBPWtgE!~@E< zu7@timapw0uG2C$083nisK!cpa*1(UOnJ+ub2RF=R{E&K@k=J7NaU~ypzIWF=Dekt zwV^n+)-{T9OT74yh{Qa*Tuh0oWx-w3a}R{;3LO5`M$0woBr6GqRog&}O}-SNpUP1O0=TevPM|vYTMG z7H-FCcG<{#bi}nv(!#mS^&$$olfJ}2xhSqoK#9|F!e4IRr&`y~Ba}^Llul-&LwHdx z03A;cT_iy!0n(`$>}5gXF=(~~x_J~N?IIMik%NXUuz-?bQ$>Cuo}0t`j_o+eaCpmh z{A`tVnjNl490{KY-}A`yM)Vb%x(g@&C*rQ%%{*drIA^7vGf*B{{1W&Krxfb5rmcq! z=$E7OI({l&u804$LTxr=D-LZP)5AP1AxIA~-sUnh>Qo$L2(P1n#3A;kEpFs0145ON zf^A5oF4ZHB{!u&a`O;mZcm~u0=V8?E8MJp|RAWPbW>Xsg%6bOnH=W~uByA;{w3$am0?0WK{?7UD%)gUToKkXc00 zi9jR|SVJxe*~lPosX?pQWNH-H{U?-Jz&!<|{$mU8lSCP;+Cl?*-bVF%OKrf>pAEEi z<>W9|ie2ZJCt97L-%JE!4vA@TcB+ZJr)^z86Hcm=h?lX+(|JgXXhn;KxF%CtcYAgW zgU%fvKdyuQ*t8#mM3*lj3jm1|QFObk2;9r4vl2I1Rn$GZ+m16LafrmquFhwL>(%Tkeu_Vom#Y5ck~pGa-Wnj6F@iFV0CNEw=oM+#Gqv9E1!iNUY+^< z9uHBRjZn=i6UD)`BBWM}uI6nRU&=EuNL|k8?{#b`BxkH+=v$yr9vEN%*%t5^!(qeM zBX9AjhR=jul0BzI2o_mZ7Kb5-VOBDCgOZIx+eohicSHI_u0g+mkew;wDUD@&1 zv3b95T+tg;+7t@SKnZ7flofj7&D}8JmZO*#z&ZzeUm#JJqRTHcOa{mII9abkU)UTz zV~(9M9`BX)J8jgPBHAelafC;{`DJpO81xopO!TDP)q|y#MQ`=c|m~W%l~G3OQ1A1#FvmR>WTB&qIv8& ze~XbXml;hAQj>_B?Xg5-(YqSaJ~8De<~X8v9M(EKV1#V3lJ;91?)*i)U?pqxKvSgk?Cy8 zzjZ%kO-vU4(+m(w=DL^MRD%JMBB=y9Po3tcEq*UawHsb+VvqL82U+~bPm zVa&l}F*2kh_gWloh-pn$@^<&@!7A-p+F3rp$DaG!U_oy*dS`# zL3I;AmtluK*Dluv(!V${#7dsimi$*BDFtgjC!+NlPFFA-G?E$nMdT0wq>PEU79Mq% zu3I)uU#U-;v>#n>AX>Gw#G?yu>(B}b5@Cf3c~BD;v{^#P#(S3Y(9F@Z1A7lPoInJZ zkZkR|xlLD`cF)TaBOJ-a&biYzTM;)S+-yL0X!TipNG_ke0R4neoW7#m@iCjRA4GrX zGMzF|n}K8JB<7hGfWk&MThR3u3eHBTJZPb{7&=#fh}}AR^+JXI_W8HOI0=%8Lx1H| zPZLAgVpz%}OtXSX7`fF#T%fN!W2H2Tk<@{5$3I}Yw2eLoX_Z`@Dy~moAK>OkZji*( z?TKp;A0QfCK&wlW&7tYD!$LWECWHP1&D?7sUK!KU_t_luk_Hbe5F(kq+eV!I1aQ&Q zpZwuatDQdSE;Zov!VDe3-`ZcuzN4HAhgzX&JhaVroGCuS`dMBp!iXCp*C`Wnpy&|%aL4a`5H4F6|kNjY! zLsR&=dI{~Qjk-IBs@R2gXbF*dJK(p($|5Xof| z&jl;Z@g=gk6;rLNI`@QbHXsXDFgF-br42o+HF8b|IQIc~I6!8ABNoqp484$m0-I{OZ`jCPJnGM19A4}0p+1CK z425Souretvk23^w;LU~i7F(%{{&MIPvqEuFn$BUCj*zNF7Kw=EA99NW%b+*&WMj8$ zTm+OYyjdHpN0+8v(oj#%lexHIkg1wcNu)-vq`jBWUXZA6MdV#<>WGb8UW*?3k)*Sd zd#%&s3ie!J7t|Ua1imX%ipZM`j%gnBO?vt&8}j!lg4jx4%p)GPl2=G*VV5Y4BErFm zCqr;jsD&t7K)m24%}f~H`Uk1S?ZPEN>5H* zMZ2jbJz+b>U5nd=)tt9Ze)Efbm(AgoWRGv{kEackqg$>244{X^XoH^Acbj<2I*zrn z&+>?$Md-~hWGMirN=T^;LZ}T{har&w>|=w%B~YlOw}4G79GiExmna(hg_*-6M=Gcm z{GJZjLMnkg#DFsf&@u4iwEG5ta#Ql^rj53RM?c1+uYf57R7!)M{3bs10py^zQjyhr z?j9$fGT7ixg!AT^yKIClZ1N6(d)s!zGZ$TJb4dS?J6*pL=!6s5gxOZmTMPzZ$bTD& zS(u3RZ^vX_vyUG+As0PlA(`>G)7Kf^Jn&cp;DmuJ{V<^qy(%L2V)W5#^gKr@DecmJ zOV*pYn{5CZNJMwq&~3K7wIbrdo#fr(KPEu*Ase~bN>y4&cNugGyX8^lZlwry7~IO$ zp`_Ea-vGyRxs=&DD98ZKwjv#4dg227`vtq2i*|i=Ga@=$^nNU;-$A`ge43aCI@r9p z7-b$t+0o^Fl|eWu{;d~aJS^XOH?6)PC~bdG_yHx#JTJimpcBad9tW>(&K{aj^UDAy zj{CYkpzzV_tj3VpXG)(r9cfx;ne*3#4Rs7o%H-7>yMM3Mo{OAt{oA|4A2PQcp1Qfc z4>mhCCqxPJj}I%&^?^a!|9CC43n;87#b+A7J`l~w-}Guar&L3aPLi&_|1$7YX$_Ga z#A3wsWn{-ymU$e`2!F^a-s`ie?vIeCZFLQCdm92z&hd|R`llfJkK+SjIfqT@RTMRP z{M_-`XP1O$GMiX;mmJv{A8~B#e%7A#&w^gBsHcQ%{x-m`tD5*I(rI13UsUXj10k_> zkwg3Z&k+4migs2wMeLZ7V#MB@`noD_y)aV_o{8ul2g8s zvwXfwJC`}6}9UCMocjzhlk^4TqAujr^;3EHAHZ8_PPdD$Qy33jey` zVm3rij2OPpEQl!ar!TDh{Kh4zgME`U+&G*aG7{jVB*h2;g+uzbCPB#Qj?Y#VnPXRw z`Y*xV+dox7s_+y{MxrM*4-iz51OBx&%LfJolyuSPV#l1BtprE^l%a=H7g+c=nab$C zQfCpP_OhFf zoRTbf!iZ}!_)`y{h4)x9cv;3DLBCP%@Ymnlt)C)7Fz#x+|6jf*x%5qBmY2nqC7`uyc= zoL*h4a-Yp;2y9$DFq+;lqjDLCzHDFT5Yef~jw8Vd7p0H6>xW8+fojpPW_~3=U@c_7 zi$-0Fg?^3U-Y1Z~>G|4K#CMXHPqx<%n%^LvS57=ol6`pMQHUZGP(1r}fwBH4J{=}c z)f!#9rm>cdLG|+`5zAN^5#%E~rsdC66xdYOhwZ9wy6t#SQd5cOj&-`Xl@4S&;RNlMWR=o}Gy?A&>_LXwEQ+9j%h}!i) zr?G^!`&$X(x>aK%q?z=vU#k3aoYLovi*bqQ2CcpXn{X%sR$wm12NW<1i#`x%Gi2|taOC}avAMmU`q%+G2%LIsVnn$CgtS*lUFQLZ@;ScG4?Fo+ z%UD8D4~N(1UB@;tzD(lyo@yZQEi%S=QQEH8K*x*^!|vDGZ~p$&pz#_zwT1anuSj|{ zL|>D3*y~n1F}(2;EmxQ_?k>VX#eyxXt4G|M$3?%-*1E!Pi^MI~o{7V@scI(Oai}28 z&tabv?_LSL%piAFi{N)*0+PupD9*>_-@XD>X=0de))9_`8HrMxY-WWX@~8)dlf}o= z#vzV-6Gr(yqzFVrj{zQbY#xAk=F3TO^^nI#3z)HPh}@Q8q=&aEWBc*?PiY*A7=0zo z5Q7VJt*));bZ!`v5~VF=eRMZR4i0VGWQH9R51?$5v8F6+gt|~OksmOVxF@(+8z;`dHmKSa(!jgF+UQ(1#RZE9o77_GQG)j@4hhiLrBQ^Hcj?Gjp0l8mz6 zAYirQD&IaU5?YW#ml_mIuaYC-1ZDDi1MJKw0n;ZLXb$WSl1K~zdYSLh4Nf=uObp!s z%)V~X_%}7Ub%;}4t8Dbr>KevI^zkNPG(?fgnDuBn=cEVaw>u#Hqpl}@<0psj+Makw zM^oqh`u)NM)f`HfFmtlhxTQdP*t<_(Gi5=GCeJ2gah6voYJtLtG=qC;g20fJf%PXB%)POdjNw$~dc^V!O; zt)-;1qVyTGp4Y15stZsjauNDY&xqqK`EE(nC8v(_P5mx`Ilg_XTym2k$TE!+rh?gB-7}g-EN&(1H46Mw=0Rv7r+MmhV zH-h+EONv5kP43IvlEfqT9Ivp+Fxw!r)Nf$T-K;pY(}+ePy&jjfz5L{cIY|Q;XCuEg zdX52dmE!lEo++Y-?`>Hx@t^R{o{`WSMgOiewfTE9;R~&^_@Bt2bm~MA_n0EGK|IzbPfZsSp- zFfY#&QSx2YM(-m91pTqM)TquU4*Pb%2n_&&-S6eijfiyIhBlOGhtZ7D9{wMnwl4W! zi=&M{?2@CGJC$C8_X#o%+&H(r;?xVzkBl$;9>0f@p0cnu^TT4-yeFGZ2Du6K-5x=A zRku@GT%g<-)%G>CM3E8AK%t%@gDi-<=%Q=qI|S3YEZ)?ToLg@AsQg3D^vdLHty%M`V61*V>o$!+F{Qb zJJI!?Q3{V!Iyn5B(N!n=XH(~5uV33Qe7&8#t-Pt*yM6+7sLcc-zgN?MQ{G>#zSclzs!jqqD z=nN9eXPOz=JSa}A@MoyQERYKh`bg!WY$)eAM91V~o$WYz^fY+@@HT^|r3O|ucu)@b zxg+~!*i4Pg9fR8^-`I(%x#h^OkFbip$I>v>QUgu`06+-jw5#$kmB`Ywn5W8@9LhH% zg;M2o(G*Oh_E|o$RL73hZJSsCN!|k!`0CYWb(LLNAtC*`mbBicUc)0*jn z|ACZT5fYl?P^LwKMDD@uaB!3Qq{o3EhBF6H1nViBc6o5S;&?m6Gr$}(u+IsgaAl;h zi>zol(E#|MBnMuLSAqOG4m&mB)5xR{evi0GnX6My7pGOokXbzSBs((Kj3WSEHtwt# zdPMC(v$QoiX62YDN0k?Yl(t7Mm8!$|7Y@%-lkdnx?{TI9UIX-As3cWkHC1Tv{L-3{ zqT1!$j34;DWu5S$qTbzBLI$9k%_r85_{I+qc*3sB21U9BY)-75&+c*7q|Uv2ZUVQZ z%?@vBkM}ot6c@^${@ocSk+0>~xS};&ZmpO{Tx})fU@E>;mCIL^%xuoIO$ap*W=IvW zLS&9aMH1rf=)J}5gskt>(@=G}O_jq#ZVCw^9NE zqCj@kZh_@U7+N#6;CQj1h5H&0wfXv9=gq5Q=rkOkADZsigd){K3gP zh#wkO4+j~LNIv{8O%<b%H_hFKb<;T zNxjG%z{_>%iFRV8d%nXa^=2+_f%}$V!|k6M(If^L;SkaX2q9eVE-^f{T$xv(m?TC{ z$3UAcHIZCZZUHQ@ka7x;Sn*bG9scTk-mZP#v;F~n%Ha?`x~7TeX!6BLt1_}pUe<~aSZi3GgQd5J(;fvVuMRN zpMTx~QQFhcCLn!O6>OGWFF2Mf{;^VsEVdy**r{SWw8>0}k;*dwB;A%5ZUz5IxI%Iv z5*Lt4M!}q!AY*`@1inz1Xgda90HaJHzaQ z%dK#-?NMwK{N!Kx)W@VvD9L+4O+-PFpg`T6YSNRplJ$CS@6XbCE4DIQhM(8zrFCG)k&A4!V1f>M`(aWPySXHZHy zp|V(os?sING89~GlGxSJqtIWol@C{vOLQ%RL%7!${Pn*LXZS6|;ssf9D9ByLDVI6u z@%iTYk|q`FGqH%FK3e#E#d9#LbIy{R@`!>L#Zpy#yGHD;`d*JydBC+!V4VS3YF3Cu zu+*&R1zxYVD=TftQb0XMyF`rPlQs4q3*Q@y#ig#pL;HdG;qY2^w!yjW>V_d1tsI}c0H;d9Jd`l2 zQ?`7RP&NP;>EGlEhibOTuMZFo&2XPN2Z|DA?R{%#NIJ;WgCz_o*borFhB^4vu^l30 zemgPAvW>-7O~v8n^JkOzh5t}U)dnO>4FBApvDDmK-alBo7IKUwCkeq^JCfV}CR+Eu z_kGY(kwW55xS9x0FMk@LDbCf-&!?(Z^WY~>YNi?#AywoO1~As#<7$0EdNaG?0hqz3 z1ZqncY(34?C<++^p|;g7(z@VpP`S`8S>x(2dKoWPme)7&QQ~}UXF?O2ry-Oz0b~GR zvT&+dm4~Xztzev0_L-vonu8Q25!V?!{3UWhJ?v+x*}#{3OQ8dOv~p?922_0*1{-{i z(^?@PE1n>%-Rk?Yj1^mmm;hem4Kj zY**oef@)D?k~}I9&S4aAEC;Ct#B_}&8B-Sm$mRjrR4pX+A^2$dEKfqP?Qn4uI>nA` zZhH8#kIIy&-M167^y)R~s%b(b$e>~Ufy_in8~LOdP0(nG@+XUW`+LQYMK=#8asofj z^8{p`VklIkB)7{O0a7r6_!N+Gq)@!MhP8a+R4bg{yzHk^#e6CBUr2U2q5xX!iaUSY zse$6P2+ykI3*}GBl!5LbPr80AqkN94h^zVxQLXo!Kg=W zcM8F|e;xS!YXHXdGJs?)z|@W)yf@oZ)vI-cW0Hb6J7T91LWJssc6kC{?P*=+(xjPU zL&TjVcQFn$;Y18xp!u}ailj@`OBsY|dS#H8VzrX^8^T0S!!Nt)( z-ZGb!FbKR(8SOkkcYnXbTGMk-vm8(?w+=0?sC)Y#=^r*E2GlF6A#pqWSOW*+Z-UC- z1dGYBLU8G5@lu8&uKg5OH;<3jcooc1$&pF=#0a(`EWaw$KD2#I)~Dm{836X5SS&cD zV2;ima}%xDwFk(m{EnmJduaoF^mum6n=$|yZ?l;n;n;$~#rVTmcMuzpIZNb88=!Ni ze_GvyuaknkRGe!0=+3=>nCEWpr&K%iV)tYvU{0qxri7gB+h9kL;|QY7hndo z(>zj?Ay19Wr+4n0^SrgK)+&)V9;o*ivVUh8R2ej~Soey*?VS|9fYVP$(%$X%t<|Ae;<(O+31;V)+vjEATGrS#(}M z6tyTjdd?|sta0R*QeSM--yfc(rXX~m45`SN`es{eU3k6y-sj&AU6;23(>+$tyq}OG z$@#DQ*h7@bzTBMe_o%J5HB1qMkM#TOFU7f=yNGTDK+DpqV3<4pV}@EA_kMLl|1)NaLmP#(;&by6EhcVr6$N zCvh;38X9Nj^)P19hPqirIexvY(;6p&8X@h(l?sycRjcvU)av{ZqI+&ko-ZyLJq(_nskQwafjD(;OX?b2lNtL~ zJnNS8km0c^f4=OAOMY>q6Va{t9&>2!(ykWG#5sjg6rU!0j{>Z4VZdasYB)azQf8#J#^$;3mRS|jp}B^_8Z1NQ?kr#wd-!pA_vb~n>q$7%?E8tR)2_z zNUyLCWiebOqMNy6T_cWywt$fkpSC8F&?iINnh|@8+4yMcldAJ~Hw6s-goF&;%RWhp zPZIQSuF%cI#E%2_9pYbhS$f=tq`8KS3wC{6mU*{H@hDTJ~-=Z2+eaw zL5|j^o(FBs+LRBD3vR{1W9}|>A`l@48DxigM!fBIjjMG$rD&D;&izMzbiz<9W*RNa*QKd1xi|r%$y|=c5XbZEI?H?FIr*yw9u6 z0>Y=ti^s!F0Y`;sTGH9|V-qm9Yi9fh0c&%iAYE}$t*X(EUP$<)PZgeIK2OrB!eG4&p`|H>z~b9&(taeBg21LuDQv=U)Q?LX)kBF7&HMS^dClXZ$wsm16%VkCT&8T}{Ypd=Jd!9p8%p!LE_W%aa z!~hV=+n<+|>SW^9avJ-$q$R=hMTVV$#cOK3JK3~rh8|~&sK&MU(}`8@dx+cCM0+K* z#5b}h(7!H?$<-UtaqxU3W|++5ANKtXC5;8~8dSNv5PBk`*EhS>G4_LX_hlfXWWT83 z2ZIsz9(TsmL^bnK|MS>8+oba)^jZ1-UR&|*=o2klO>??Yf18YwP*UW6^`I)I2UA19@zst633iWe{>pTLMb$Jz>Ry z+Bv8{b(SHGljJu$yrb3SJ84R=P^1d#0Z&Q?(!Ffjl5{JZP@$D8f5lYkB8b#1HF>w& zhGtX+Q@gCU5`nRXde+Z>2E3)$Od7PsE$#7hJE+TC6qV;jNHcUy=Y7WO@tVy|3Wvn@ z&mXh7HDTjY^Eyni?4)FN48L_~8^6bCGdAAVclHIhr+6$m2fMrb5qxm0Vc)cfV20fN zm_41tTQgaH{btMZ;#F?ce=F18kC3+lO5e%`!d$ICvrC`KDrVN*So61&u04$>&m*}E z!pP!{kpv#*8CB|cI&hgOEG>$f&0XYrOP|8x2~>JtBjtj=m!lDF>3)Ti0}5C^QVA(H zEx5a}lShA0_w?dXoFZg{yv?m}dfJfpzUcUtd-olSN^hg9Jr8;g8y#s?7zmjGLZ$4t zF>vb(ud`Z{Z^DzpxazyfjD}R@fbQD$e61zGmYN%;WKZmtPxRFQyEdL%|4F9GA zkT41OyhA{{$V%#eGu#$G)9d+^p;@Of03D7xSzeCNM@Rfe{TS9qz6 zU#?&%=Qwdwm;4Iw^0#GJ1Ef|A27|Oz~-ga2w>Q7xi@{QN*lWWM6+ zap1lN%zHW4SC6^if|?fmzfMEc;Cyu+7-)IE!t_t%i~Yk5KdOu-E(2EY}-_})Q-2tg9Xqz{m_Je?b6bZrNGw9TvDK|X^5mH}+< z>JBWH+xj1Sq|sG_kE2dKW5$d@tAD>c&wO)YMTwh}am^a$7sB&kgqcm_y(B2hqJ?g=)h!yAZ9=j_#s6Q(;F$4d**ut z7r_*MYHX>Is}XqW@U#QjzM9Ni7>QldGp?vHrKwXk6ABIp+)l~dFk@R( zO5z;3iCgccG)|x$%})}(Hv7AZWlXHjmu~<81Cj&)O}j%Faz8fYheM&oGlU6^Zck=_ z{INqBOzc|j{#oP?X#lWFG284#YSF&IPgLTGa796dG zRt_0;9me2qrb!yPtGkR@YGhai{I8&=-N2}a#x1jnTGQqOIJFaFzP3#47lc2TF}+fY zhOn?c4qf%nKcJyE`sLlQznn5E?I{pSCnP;z@CPlWi7j%`S4Vop)eGO z@&WP(Y~CGkYX7cDR#VAlLjFC$6o;1a}w#;Xv} zJ8sjx6d_$HG4)OV2|Z_K2-I)19rsxtZ&VQmfh)H?BEWp^erh{IInGLwOHbf`r^@8A zWlv23vrGVT_KC(h>w%94(j*ENGl&E-=H39}nP zdVnCpE^xa)WBfoH1vm0@`uyD??=*pTr>cHqgGa*LG(yomj{uMXz_@V@q6pN4`$rFp=_~O(_0|FX`mtYt$j{lFB83-MUq^9mzFU6CXl!v9pvF~KTKnnk;;ODP0 z-!LPy+{i5!Mp{fgUGfC0U|JwF*&Pn|f{&)lHd2W657@=k3KE0>u_=Sv1e`VisC9o_ zh0*l@IH#iBBWItvfBC5*fty$`MJ1c^@`x!werTh@ztj}!l_GusjW6I3R@OZ2UFYhE zfC`g8!xV52n&9PDO2Iu6d_59^JX(iZu3>ycv9JgV>P!hQh5{QE{NnD|D(CppR9ezp zC<(i^J_IPnsGacZ-Msh#83R?&x!n;O*^Em9lC-xcE!DR~KBfFNykB>)?CIZ67R?u`2-uBTw2C2=uYT?L-G{?LMW&)jcI7liOlEG8Vl0t0?&WiYawpMdUN^2oN-1oza0>J(N!SRSOVBouvddH!<3zEl^0 zHYx}#HhG>B;HngVr97!)Mf|6e-2V4#)0aTn=STrYl{m+HT?nckw=WGYoyNdr0w1fu zOQ;C8$)_YKVo^Bwy1_Xun4+&RhNrO5@p8%>BxCaNFh{V(yK2dcyU=Y$QFl^Lcam2# z=|QT$Sk6(>nK;NV5A^9om|gdO@bV&S{x|iTky>Ct`3BeT08;%n2j$s@!0xyuvZRg1 z2_G1{?{RL;*k}46a#BJSfwF;jCii+pB$wq^Dv!*m_kJy>do6-vaIgdO=BJi9nf#MX zA&ml#A^PI^o8YOE{5>rm!{Lj*$rf^2vX;ss%<$FSlK8T2Di3Rk!eC4S@o>1nK<((B z`(fgxHC@(%!Bz1Z7kjkQ{(;01r+JB!2K& zg#!zeOIe+Uad*XMTmYLeM&nnn_lYsN*%h7vkDUQ{f`}uKro|5WFneU1zGdbxWRt9^ zu@%_WDj;$JKrmpGZ=c@&3V2z3-3H1uGb*{|sk=g;nn2K1m%@}n9=OrHJ|fB*Gvgt| zsy90Kz_9Rbdc*iWEC`_;f__YKX5GG#gO#h7d?{R!f5QtD8mL{0qvYH_qvV`Z;A@`? z&;=q&-nenDc7$+G~OXfwrsJ02nli+yd}^2QjP!{nTjb8M#Z+Qz5B^PiZQ z1_A$rELp2|PrpPNlne z&?)m2LcH?xk)GTC<$Lc-<*kVO!~Dj?Mfo2ZBZQ325oii(OF5oolwPQt#30Z~yX4vQ8M zH6mJ6YA1l;E?T8%X&V%+d*k}YYUQ2x3nXVwa-QY>UH3I>>|1Ez`T(TS0{5<1Shqg)AxlWAzp9Bky!u&ql=@p8F^LuFI-Y;{3%Dj__YPf~*oTHheG02x zJU=Ui=O%e?1IEO8YUKKWR?zj*N_p%XPZi{$o4C55z1R1N!L6pJ@bAty!ylzyUbcOp z*Bt?uNpdaf`QAxxBcUFqpSs50po>kBa{$$d+EW$bP!VC%u9oQx;ikyxRjNN7w*+V8 z&wdGblpObB`NjRPZITl;#O?_TjG&IRL4gq=IBhaE-SZCQ=r-WoLYoGM24?7y?Ro%r z1Q8SpAz86%|N1DpLgMG%3-6B#aRfP-!H?c503x$~FaGfXNHRiabw|Yk<|l+Y;Ltp7 zh&ilwhNk9Zz_7j`#NVHEn_4UK9h;$S_5Wp|c(Oc@E+ye4Z)Z<~S66;Sy1TMoEg8H) ztIu8Aq|9U-IqgnLEZ{0~Le_sm?-H2L%MY4fzhr87nY8v>_wV^bxC%xg@KhQ^`MD;`EeX&lRvz*EQaL)+e3Q(alPe$?; zf2o5<&qsiL9^VwOWNzb^e-*eca*nIj5P02;hV8Z$QP!Ql0wJ$YB*IsM6l_xClVYK; z$PH5pIYDiUkEu2_?F<+=w&>cL&ZhlkkEc3?u8X+(-M_M93unZ4%~X`jt~-UT+tAdw z^f#smnU#7W^h(s=gz@KfDd3*wq9X^t+Vt>)SDU+;%F28gcWvEDeC}z-$G?2qcj&$# z@#_npKc31`l*PP#5cJq%m0i`cU+W*W{Td|?+0pVDbdBgMmDps4<(6%x&F6V6h`qe| zKl{9_d#84WtXw#js9HicUE90t%2KudYrak3V|IV#6aa!_jd)^EnyuO1szyI%;V`yV!dCa$mSi3wfe4M;@!Pw^6 zj$1mOPA%Wb+9!}5;Kpiu5vv3x@E%tCt3Q+A2RIksqIxb*uOKrUK=A%v?laVav2?VoJoLSN|y9P^sax?UUBDm->?h*x+xEh=+;A{xWU{DNIJI^1SPoW2ivj*d<) z0-~m%0H~Sr6tCiWA|OMhXZ#!#Q97q0HT>49gPSiXJ$@j{{MI?9T@V)@3~$POSiO2s zG2pc2+Sww9)KgDa9}H|7p6whn_`F!QkQec2PhP#^QT66wIeauYQ42uak&|mcrc^_M zP*fPEXUc|=LZ|9c*ZS<&uV=^P+}-m!ZO51W#WrZ(=ErPR_EVUzl71?llxQ*8@g{Fk zLKR`{@YD&r@Y`wQr`K7k7CEQN^R7$M{4e*}%`Ry?9y0sFNt_wnW_<;Q=cx);mM51g z8C9?jI26OD<{B{y9EY^V%}*0UR@h(kS(oh9FW=Nq{i9=2%vyN&*VkClvaOhH@&5H0 zj}9;1*zb3-I<=GRV=vdG_p+ihPqOy=;8jI?XAEo1@ajE-4+^^mpEBGam+ySR4U=$- zL6Dc}R_1tb9CG}wC*`L!^j%ezb~*6zT4}tG>w{7sOC~HxBvT4X!k)Fd1m2F`ls_9_X9aQ>JKi0k6bDWBBzqxR)sIIR4g1y5Qli#D- z#i?_e?Cu()axRgKxNrldwkYy!vU1k=Kmk7E2Is>T8ba;xub%Y7FoFMkF&g|npSr+N zwX(kE*>^)6D@+l4W8_Buj?4((DL=M^0j}KC%mOOc5yr`1u=kbbuX<)FkcBj|=O-^a zkfZ0Nob8ny-9q#2P85Bem57$p+7XLQURTSd3b?1h` z9&USPp?6w3J0bZY>)4ZMf8T`CxixR(wc3jw;~|A!JiU0PC|~9-!ZU}PK@bJbh_reZ zN^WACP!E-PpCagibI7`=5Uj@5RSwd-ftcM9#ghX~YI($yCH_q)N7biiEsn^4GS}`# znvY-HGwq7~O((;OFHZjt~fFBUa~X=-STbj-;y`m$8HTAr%C>|)XIgTh^fEqMQojC5kbi0k5xbEToR zRs8)oIP2e_g%cM}UQRJZaOVtXI7j($_9aEwefbnU;T@&t__>+wQ$@XkN(=Ab~hOQgq#TU1udKx$fqUFqPM`&2z=>bnSOQ*4YAhTA}%04Oe*2fH93Z^RCc zDlv!b#D=zn=1=-Qoi=NDB5az=7{trW>)oC~YPU{{K63&$Wy91as+D>5Hg3Z{%b zV9X7Ck=2Cp>!@`9=k!_^LR92?O`kWkU*d9&r1>Yh&~?KAFT@1qCk%uYiQahJS9SyS zt_;WITl5fsCd$BRxt|R}(#lJ!AUHGRYKJ_aawhzc$2xaE=-jRHO_w?sSJ&^k`^@9= zis6UyXR&4x0Cvn+$4d#@gy_0qlB?l>7WwJo9e!b|@P0%8;F zL$&HPB$P=edeol`$ql6y|I-uc-`T-c;iK%mV7|D+_{`ljE}zlbFGf|65KEcMoSB>X z40tfH<%)TpYaZV*N4%@9EYeBR93{UoSmvw74N#hn)JQ~T-SPOGM_9|{``@gc9cdfJ1Bs*i(HZxu;Tr6g6vjw6etU~`} zrFhB{k`<>lT#&V&c-Yw*koK#6`c<`fe)o~kF~5@wu94ib<6XtuXiDk+z zjOmK#IpMl6=Xii7ePLi1h&q%a-OH%KUTG2uSoZSrbpZ%%Dyk2x7ZtnutN(U0GER)> zgXUzrI^4_b4`@>EYL9lT-c$2kSd+NIH_*)f@;rK)%_w_4(e&^*5#f9vD{z13D*Tzk z&Z__6gqs@e!blXhaKDD)P{m=i}SK?9}k_HlbaU97mAp^=zlGhrgT(Z0x$}2rj78AjBBEaK(kak%1=X5eUU%+#d_ZtfN-xl zcj$&=oIbss;9etmk1cZK=)H3!x0>VzkBV&c98YzWr&$s{D%T(!a#UDC%0*^Tu+k>( z$p6=>uyhtxz}@!(nm{lp70c3KPCQTgvr)n7#_PwG4!6xt9eRbdMRvjL-k|y5vX*tW z(cYkzG>yv91$G94ZAHaWv!Fd)yvw3kr{;BFb9KNo4Wj5H=_LpavE0IZDa#bBB?Vf5 z*-A=U5%xCUX}~S*zRQNp{LXaj03xUbm`MO53E-3g+-?8JJISGNf@65%UqY}4 zNp_xEfWLWBJ?eBj!S<2f?skC`;mU3TyO)dan@Em{ z_@+y!MYau`YNw`CM>;tg-ChMgF0qrPGf`?E21+{!aiIG8m|5D__-^77Pa-Ig->zUC zw5ra64qbXX-%-f})aC$!SrM*Ay}g@|$wA3sl(&2>tHVOaQ2ESeK?6Eh4m>{dEEUG# z1EiqL0!!6&|2OhPTzY^l%1*b>F)RKpcbj8Ylvo%Wadw`b9}F-tg0&)%L!}d|_56*; zXzoZ(OCP%|^KRbr7i~(%1L-eot~xfEB?eG>p+$V)Hn$s)+3sg-Y7xcdzbqU)T8#&bpDh% z&L7ezHR%@*5%0T3ZLSgPrd)Os^f^srK8o7aXk!EN`f*mJ+Qy1;)-{T2)O;$_y-&#Q zQJUu!uxl0(t~v8kbE~f>)k7o zo=4Kt0M-c3zvNCasjOtOCx#F#C!e@Rp^1TYO&I^LlMTfB&AIEW%8 z4L~XJiXDqi|Bbjl(=2_Wc6RfUen^j=qjtJrw#&TeG!t|hu9DkS%8x6Bsg3f=QQN#x z!JQ=D#C?=6id1Z;OMKOeGZyZ)9BC0I?ZX){jeHHk>Et{PXDxL`<}Q6Rc@YUE5@PLc z_P>qopP#4ofRYiCuLGDGfTl$_FVIuN7}E!!X;4NWNejjUze$|ifU>0Nr8T49&Ydf_ znmrfYaiW`WuI~L|@5?+nbR}*kD z0k5+#D*>VEZ}wiL_dByN8)anRj3Si(1rxnOIf+q>aJ|iLa_(y)JM0=;rCeX4oitNj ztuafB(q;DGB&piI%)BV9(A5jVr)%ksnc&p+QRi3sNo96|f>GxoC0C`l=^k~s zQAGvxoN7cW*Qb3ZSsAF@ljOCu@Gkh&n!YCqf{ulkSE6>s_>Zx0C4wY2JTRv8xa1sHzVb3x0M1y5fz>Bc| zuAJD*TEHxDIM?W~@sLBrA;-(0Q{twbb&ZaFF5OpvUFQkz5XyfB@b0XXYOCo6xuMY} zLn(~W^Eq$r$8DT$kJ{IoZ9b?S$CP$s+!9xURsrzGs}&_`#ke}46rny`ei+y7R^rT2 zVGhZhu#k)xfS!pm?_h-kcbP?G-9F4Yk0Du(6!_bfEL_M*1Q<~k$VwC*@S>Jb=ZYik zve^nNF1Sb1DO@(sqFx9stXzM%XVl93EheC~JiEQw3d>Lr$^_Km{B z1Wjd$`zob1=qzhH$}TWVf*TK2r1P^~r9NtIY`S>w9>oE*W53eD`S_9(W~UF0LmC8< zAy6E3id8z*s%7IBu~USh1L0SvD=%X3-cfD=df-QtUWrp*7dx?=Nc|2k%thIc)rttU zyaEU6rQo03EzuS@t>cHPWYJ+Y=kdMTA-Xd)*-o?wl1OTG?O1186g00cZfXg2z6?wM z5+~s;r`kC_+&qgwrk`}mU;dR^d`CZB-N!oj+NPer>#BuU^gGwhEa}E}ohNOlJ`w`! zsYhkDo%Q}UZ_RuH)^4LG6M`7TG1h!)kwu`Y-r?85QYmwHVQ@F*r~(g-dx%%7b-$%M zg)5KlPj?tm+IQ*YL!=<@ZgrD6@@w@4DFS88vk6pAs@6-IkRKKS@N$cDfs$**3NNCp zhCEgh!p*Ym=_Bi|zkhs~;4{({5$T+Xf<_RT8e~^TquP4@7H9~Jxj@*Hm|b>b$ByG^ zpVf*c^oRNVlTY*el_+Ed=%Qw7=ReWnR(hcO=`bM`4}LwQ?m0#6lo&J5n|rO2F9*9` zhrGH$a%(M;A@Wt5|NU+YmuDPGBN=U5nc2bLxrSDc{v>#Cg;55I2Kd};j+A-11 zN+N7$>cLZl(*sf(qUSZC@>doIx3v!a>5gN1d9B$toFb;Bi$}~X)RM|_gv0gH`v}M0 z%!o}FMOffhpr9J$*{gXLl9@yBx1;pEDcq1>>n@%SxR}fRVzIf6%3-ABCr&~vMx#tN z8+ZHUki^8&Gm^2CWwJE`3cW0fq&HY5PsMW=pnpF3_4wn_I&z#{?RK}uZK&BXSneHs z8whS9;ckNWuIrP{DD;(5R{cAthy3dpDvc#1TAZ&z8l<%kKn(;Se?XgzhbPm?$`||uL%(9aG6Z~dlEobjdHeQ9A5;yq5$2>R>fKvZAi!4 z2(xzAulD+7-wT|F33i8$hSZd#jHx%EOqH5dHWc_Av&Y^ubk(fkuYxB=oPs-nV3nE{ z0ZMLKzFe_5RDyONe&+TNf4vQ{ETt4rNKXcrE^Qe7PE+WE|=!yPqXV*yz8tO`u@8G$?X zVk=RXi?K2;Gyct7)G}ADL**TFSUxYfhf%Iv{b@E1wol$dnM$WzDM`hlPB12^uIL#m zj!j%v(`a9d-HXPV$v>5(xEW*hSL{ab08Q+wutj9Zk=tyZb12UtY&*+uMPJO$>d>rr zKPD&wmUY#H%E~#l%QtoBgr>Mpp5l@FVpuV{qK_r>o>+Y+Ey3k)p6&eP96))ogd_G% z>I&ifO0SHHF1sBOnK9cVuD0!uvxQUl97}q7rty5y%WEey-yG+k%FP=-eY$t%{*G1N zvJyRCP7d2fT@=N2R*a8xhX=&ADcf7_>5Ij#tCWmFR^#FMt;*EudtEpPL7*Q+ZsLsj zwl+P${@|&q-vXm8){o!vf1flnW5={O>n6wDDZW(@Qz~}A zT4P6h1hX%;NChFDxe-AF!;R$uKle$>d|r{K_e{)q6ZJ4Ypz(>#_2Ax?_sZ$N)oz&| zb}K8F>ouRGW*=TJv;&fu7bcc)CT}!ydth8up>+1R>Y`+Z&hLunyugSuL1cx^+{&4R zHG(1Y5us}wji^BqANcy>+QVLk;;_3TlBN5{D-s77(lk@A;J??}I@rr(zG+t$F787Y zB&qu(^8;_qk=*9b_4Lw`uZ`lXI&q9knpQl|CoRy-^-tF&#Mq_Rh`HWpb0SKed%DN_A<{d^;0;FNVX^SuscHQN>*esSui$MrjJt`|%? zzG`pk`VFo(Q;t|4^4!s(74xT_E;+exf*Tw++FQBf9&+*P6NdIr zrlM6oj;d*XNXumQ{G^A6_WfI{0cLq!8oU3zw- zOXQCi!&*XWA|+VC+tS%1-}OfO&M%OZ*)FaN{26~DEg@ISK%H6O66H<=l-SYWak3w#~rl$)_tLoA5$%YH3p=eI^? z#oq2?)w;czulOrxV7vWbK~JXq{;_J72Q)Q^ekG`qyGzBzyAF}8o)AO8Fa~F@ z)o@cy=7*%lEHilv!}0u}P6G0}bC|=AB|!m>%Q^vF{H17a_GrPhzz9}3**l4Ico*`_ z)iEL}#%YRH|A*UVnoE~cdjko(wDS15)RvOn$bGo>wX%6jiG5x%Bi#64>#l$M{K(#N zE#ms^vJxqke9mV2>!x&(dR`JdZJ4yXasRL4 ze)n=ps>;doM$!@+_iiSx<7bTYa3kf}?Xs|XV*A6SC(nyJmHbqonyCizB^Gndjm&*P zI;29fc$6J362Vd&fJ2Z#_((5*1!{=zBXjU%#w=M?p|*ZwN$bi!c9gL%YXyVW_4~!m z1`&)Uos@iaG}1TX%*C9t8_G`7#iI?NIZ>VbRbxGV%U{zoYutEsWi@^?zd60QfnN&<_jSI37WWj60Z%>i(5CrDT9Tl1`V>5OOUj&HJU;Z_N9{%vbIZ6Q#vPHj?vp( z*}tr1RnrUL#YH<}_72V?-~Y*JG>XuiBtRk$uw$z9+%BBfAM2J2T) zUJ~g+1%wUr^C$m6=I`5kvT~WHVG;^Qg?v^SqRAX6whx$|fa?G7Q`?-lROsba#l4HG z?fT~Z7`A&rv@F)Z%b-H=g0RY!ZV%*JEIr;-Du`vSTlh=K9q%z+ki!#X(YwYu?C`;Y zl&&7e;)ShiA5E9Chb=58Bk0^e+SoZ9Ve4?LKQH!HbV0PEnWeK3G96)my9Kg-5S69 z@ueR-?=meqt|a2q?|trXtc9290L0b;Fl>aDWawm1Sx3Ox_QG_x9)Y3=T-1a!7gY2* z9Kw1e+Xmr<1=}9)DV@q({+>1x%HLyarvbqEk}7xK?j_47(gw zwxUKXKL*cgRqyosP`a3K`JT2e6R$Kdmxn!6EZsjfbtA~tjHGjETHu1*f`j1ztpQ>9 zjVXoR2Ukh<4es@jj&QJOB^zRcT`2lWb_A-l$ zJ*Bpol6ZaHq7&zACX!A>eL3_07KVH~?mZXG2`b+0SHNr_po)Fwl9cVk;rAO2ZZ;tO z`;Ak0?Zk}J!bGNR1pwP!%9|f&%~zNZRzoITN}#WPZL+X5TF`k|Ri?~;8Cll~JBL|- zZ@CsgP)kB?R`%}I23gb>jq1K}SHLy{>qPQJS2Uq?dMf~Rp7`pee(tA|qS1t-o_!wL zTkH*vAYG!tUr!zsd;{Ni`V`W6?Ur@zwv4;=XN^(y>uXPXj5TrEz?gpy;6-VkVS>0P zu~}!>KB0;~{89=sIFu{vsFkq~StcNW{mjDs1Hk@U zfXW0WYFL#T)=4dIqt#h~0{z9{ZAhpKWV@!A+$-CIQ>^Uin8Du5&(^4>h z-YwQ$LZlmHEk)_cR(7d|v4t#ra?)upum~Y2UMbok5}t-lz+OfNIf4YF&-AuBB$1q2 zB$gADU=svo5e!M94?Tz5A>zdh7I;nvU=sNBhV8M3bD6OH4VMu(dz}^40lavUQ3^0C#I6}@sdj2j<*@%BXmKF zNa)+djca7Z0L-0$xSV9TYpA+nz>!$SktghABRmCXI|o9B>2hBZ3f4M$njn7_^s}qv zvcV}l z65gaPqJ!+M1ij9}%HPk8|g`A0Y=Bd5*CDLTS2TG?@`uxbC_Pl)4*_)m!K z|9iXtB~f((`FgCt=cP(;LM6Cn_8qb#8A;eqJkh z{~PZQl%I#V_q)Ot#9;%Dr(4)HBJV>qaf`^?3!}}URG0{Z)CTxX=7nQ49l=735a1&D zCH;pmEA6UOLgl|-Whoo^}v*Qh-s&nhCh9leG77LyZ z^2vL3cx2yOnNN#4N!-_rm5AUOIK-Zijnfe}hHGF^@E&i~DP**vr5jl)x5zwqB6Xd4&J zWRbw-urOU+fa=1WS3Y)}yVkkYN94UAhaY zHDQbdCL(~O60pH?pcCQ zc}mN%-5aUs(+YTB(P`Mhon;*on{z(~WvyVhFcTJB9No933-Hprwbe3*qZ`#C4&y>F{E%WE^s{zvxC z)8A4Zn#oU~8wWr~97;tvv$Yd&s*&M|LVoxrxyY#n;bmzYk~?#588=Qtj@<^T{!?-D zto#j+v)wNX{vrj|B|Ey;Qr2T7B^P~&3!b3-M$9R-g;9nSxB`qgEic^&2Z-ohL#%b0 z@bfr(Un_0f63GHYmwXnQ3edc*G<$@n!>d=h-U1epe)CmeE(uQ8 zPF~UxT2G_7ia@Rw&U58#ML4Ml&(i`^hXEeyxxfmSBYCks4AL?`q{Y9?#NGUacLST? z3{<0k83opX><1P>bZVVl)AsKD{038WjENg&r8fYK0ns;U2%EHk_EyoQE*`6#DNV8! z>e=59CV6X^vwNXj6^%Z5l7|ZNrjP_w;!Q$6NP}PQxd3a5`yd$q>q=h$vPC(^OtvQD zENL~R1U@XlvtbpmxfB9_>u6JP`mnZJbsX~`vqDR|iF1xwIJ#4`d=!unpeq5|TL1_H z7?vX}RWmqeN(&AMHSks=^CuV15W?vpsHzA=k&F2q-17)5-dr^>%0Lh%zsZqZAuwOg zZYUKHPboR}@vU5K_gTg*BD%~-Uq?AdExcp+1U+3FQ%^v_RuNSI-XNlP0?c_P+Dx3i z+mkuN#Jhe9nx>Hi$uN*|nok&FTKjvC3+8R_xHnkeFWAPPH)`VvYR zDkGeS!bc!)FKaK_JwfYgg=UThGMjW!1n;0~sn54EpQ{~p0EYyikE?;8rQl)fc_~Dt zdD-vlIh%~UD_YuCgeUdnJl8OtEr1XM?J-)u2Kf8p0C;&|yCVe=9~J`OkQS~rQqN5P zr;gbY2vHFxeNm5%Ia8#Ue+w}-sxI>zY23wi4OxO$qWX8=bUhj5U&jyqK{Si6@qgJM zJU6&wX_8Yp!9Qo>dWq=m0KG2@p84~)Q&%$ICFOaMq6gzJg3-Iht7H7M&#$3o|%xMD^#rgwMhRe{Vbfheq%L6D~Z!=cOGt zmvS0Np-nJ+@jhIJ(U%S0&nCbq)!E1COqUnzgD5)@fOprQxoi2;54rCD*)$fgFmVv3 zjM1ei!xv#R1VO)_pZU|(gR?>C;(f*#!MVi^{{o7>wlGyapA&<$_ z{E$ywcsz~FpN()T5awiE;{^aN8o>C&V8Av&JP7hM6MztX5N--NnR+P&o$I?1q_2YL zd-`lhzz*T@Zo#=$QHyB?9dw%ex8P^C`GXxl+5XT$Ot?OcC$11&$CV?4`~^$+-=AiE zmBTzo$)s?qZAPyZ(J5zjvXRw5QiGcXyRsn_LigzA{=ATxX+3bm!ua@#=SebhO}dRn z?s1L2UCToe5b8OouaU}eXyhHd!6;amh91#!39I0$2|y?Bq=~>^OzeGa974pqiXKrG zKFtydzCj{&DkydjG!27T7RkRZAOzfVe04;5<1Gw;Jfvc)2CgL;t|G@^sy{pU{KB8$ z|K0#R;vHWf&p*k$Z3;Bu=7&(Ektl_kbelx-8aasHF0$~dx#LskLQ1|vUeJp zU%kt{cuLTIl>e6oUV+maObq#t?BqetDvLPJXhV@NUaA?l#Evt4c_Tq1ceXMkjZ5~7 za%K#`AtHLRB+!2|T=?)oz%Kgj_wcI!h~3}II;?_!w9MIBP=q|Ef^|NzX9LdL1LVKP z_)k@qi`j{LQ0}OOeQpr4nGRVN(eqw_G9*r^1)2PNEG=M%E;GAIs0nMdkJ>B#!Ru;tRPE02=&-Lg zi!WYeHO%hJoa53TSu6;M$(4gKDWS=|*ggBz&t)B3pZmPb97M^*pzX}l9V_Q6{8x3) zJam4~71^DnBWMEW$5#8=ka(;GPl%=!h#?Wey447PFwByiK`rW07FV^(3u+c{q+Y5x zxw!H5Vg@Z-qD8L7_U7{c@L6{!@y7WD!(BfI@AGvyoq0IKYsFhrf-E>ocPr7U9&yjz zIez`q*sX<%fNPSou?2nXL#pUBl)ycH(%#kOgvwo#(XQMTOQ56~;8<5qar#5x_?ERgAvk^Ey{4gd`58Lp{d zsR~HxiLnrr<5-v3S8$Bg>)CeCB%rVWDW7k4K_?VX>bpIpBA{*`yKFRFI8@|iZuhw=rN zG%bR_j1Z`Z!V!3Sn!S}QGN)yrIP}E@8Cx)Oec`J8bZL=ann~Y6nZ3CI=NP z?62GOedFP}?EaHuHqi|&UDgSGgANq(66dbX_h|ELGC(kZ&|PKs(h(=#--6xitj6`{ zEmA)hd7DZd-LRplgRWq$cE)J)S0{MLlCdiK?oD{nqrI)zy^NY^#K(e)bxHKc*rXWa z{b?p4iPHY&FGT=3cb=ZVU=VJuoRXRe0wBbqi~~2s6Ym*kfP%3ekB-OA-|9m9D_1i9 z?q1H1vywDXNv1)Xgn?3vS>R=kr77gSXQROBn}m6T11tpecfkL_OJ z7pGU612oBzlD6SK_e78zcce*HHca!UViK1X0xMI{K$1sw>u~WlCJN)Mb$BP)mDP zT}LiD7|ixx121Ld@30T`&ZkxNAp1XSpFHU&wnnvrvF?=put^*xn;Li1fK~UKeTJ z^#~fU2wQ(t&%VawN6AO_wuUCX(qYVxB`DYjhV3XyBd08MkW9IOFh#xmrl(Enjt|K32z$}EG@9HyEWcFeTDL9`p61N2M`_d zZZq34P|xYS1p8uhSrLOu`M%bC;qF5|P!{#p$Rjww3P_|64~lkSJ}aFP%2p=1$jyjj z!lL!lLS9%{-?&~1Gd1z!;$AopNezL`fY+<-6Du7WS7o_(TsaAF5jsd+#=cM%TB%p#wehEaxl%Vp_9)3X?LBYSQ) zK)^&o`j-w{*JWhN<7HSUZt zLV}d!+5X5IL0pEkt71>_;=fd7cPet7V@gbsDm5n&TOq!CiRLOZ7p)9`ccKIEH+qA+ zc8t3^j%yf#R*X608f1F{FHnk{n2FNZE-&^nM&V%JCG8p&CX59?DMy%$8_@0q3?7||2%bp zv=yMm7!6G$nn!c*^w^%$z`lz?_9l&iF91~O8j_aIT7Atpo4!~V9IyxZ5PxlN@#j}noNIsXFqvp#LBY7(1{E%6_j|1EQO1ob<0W^y-g zi^y=1?9vq|zwBl{dh_SUo5f#fb4D2fw&%x>sJ?%5D122Ee*b?RyS^X4IO~h=)D?Df z)<<)E0;)K)9Ydn3uD;3b2|Jes)_(rqz>Y6Yx6_q@Ur$UhNq{PjyOB^J`I*fEX8a$2 CUN6xA literal 0 HcmV?d00001 diff --git a/contrib/ntp/html/pic/wingdorothy.gif b/contrib/ntp/html/pic/wingdorothy.gif new file mode 100644 index 0000000000000000000000000000000000000000..3f2e0be66330a93f7ff3856a837776cef9c01ae8 GIT binary patch literal 10849 zcmXw;d05if7x2Hpmrce`e{xY9UmQ>v(u;)pT>J8N4v}NgvDY(r>0C*EG!fA@&qh}m^(Vy zqf(S<#pKbR_D-#$Q&XHLC|+$tF)?OjUumD%xl-G#6sSu zXFcPC?V~-~!EQ~vrdX@W(Im0|&@tm!IA>`3id9=Cd=7uYZd1ZOrJRze@Jf{)l ziFslnt1OSEDx+x>G_8uan#qZ zpE^6+ySqEJT21?$6RI+?n5$3-ghGZ`%n%C6Div*X6#MBD@b&8)c0ed*DO7m^FLd6_St%^5CcFrqRF;9^<2aBsM6DW#V+Oj!7;&u&Bqu{E_xEcj{ zuwB^QF6h*|7hf zqMo6EPYjxdM%L2E?JS0Z%W7xP=0Z;^6wLLDS+p`PLm?KH6^k`IR-RZ`%wvh?0!_dZ z2zkOhp}1I_C*bk`05BSjTcpGS=BIh>@~`fy69x1#uszM0J_8n?oD_+LjHX27oC9m9{lCk4E&#!g-Q zAiU<&_H**+n%kCsd|<>_#V&@yq(DDioK=qJ7%UNXi6A80KB?n@upC-JjlhHi4RXXG zc(PD@=^OmWa97>4=fe1ua((3>?*Yx0N4+#;jt zciRMsNwHpU1A*DadQZ!DI^OB$B-aj@pw`h5PGBXY-w3e_UDg8P!tuT1d(+tuD%P*L zf3dtK)^qEFd~W_&^ZEoM37%ftZ3Jx@ad!QOal>^Sm?m}8TNnvz2g7p#vd}4HYwxoy ze(%kEU{ygzxy_zv_K;CCnEp4dE4(Xx z!mivZHCMEUIhnksfH~O&8(s2;D$q9M`zw=Nr`LPjnCC@#6zM>W05~u#(*(eC9GW7m z{YZ8Zwu>>0Y#e|wKEnpkdu2H(lHrr#l56CfEfU(PpE|GK=GQ&@5h z=F~E3bmKyd!vGm(Vl5kc>$vnilM ziMO!`-^TF$z_X_IKzKG%zEr@`!n+@FtD?tg=mV3VZHRjXy+s&Nf*&^kl zG``7s%%}^_YN_3bfw?%iRtBCgw8|5~h<#@GBF7A6!d5-59-ArTDI5J#UfD<_&--49 z?49~$8QXUDwQQ#=f(~{3!p4Yf4+6f{t09hVZKQz1t2mno3tVpSqZWrkb_<6@)+Bl* zuDDPRVebLfanOnH9#o|F7)ZX42wrcCTxdpJqBd9lRF8KH{?CxGsD!f@q*VFceu0W? zvN~~zRI&Pt-ub>RDqyo6itOD2zv;`hA|Wq3zn3noM@4$m$x&Vg0CC9N?|%Oh_Nb8q zn{5goT28|<)m5I{Dem6-8$==ovhhsP?-;g8Ypi~kL?VsFTw>4ew;PsO=hQ8*7tzZL z^$DKnGauQ#Bw1}&|SgUJ$Ib()B5$@&vI8FdcIFa1pNNqb%$(J)^IimZc%Wf+eD zdm6nZ6%@*>UWlTUJ73wXlt9oLC=z$g&J!|WGriWw*Wb7$@`#-KR<-Hg(WQSM=cm_A z>YW?*>`|P+LIj$lH4l`R*zA?`sqpzh2U?3FV4NnIwdpI?CRDaJAuVqe`7^>lIv2Ib zd^G$G{|x3e3E5;<;~HmBP+#emS-pL{Noh%--7Y$fL<3H2bvcfm5s_~CGyIw8&?LLp zH+vYn$_pnQ%HdgYO*|}9M`7mo`o5}$;4VN{%V+yHA-Je`%@xx4o>OKtSPMCLlpltD z`k}=xmax|V;>N%DjidG9UfRuJo{zbz zpZU~tV4hWFE?Rr^zJg-7$O%?+tPhYX<_AHLHojbJ(Kl{3dP#AJ$X`fTEub`|P;6eV zun+p$LY#nHjAzTYzY8p%{-QvqU+Ri{Wl{8HJ6VMp*0}A)rYQ$|5mbI3ZfQgLtx(zO zT(TTrPf|QfpjJ|`DYVF~9qy!=*_+^lWXzz;lD$S*fe*g+e^+iRY!^1Kf;8Q*YP#!y zWpZv;6~ze)FTQ5n04`%_-b;G@N4B^WAYOT(FQ-o8oxc3&ARxyki>#YM>0n zgP7fO`$bYiO(iUbEw?mUf?V+sE8m4*?}4LG$4hPOVDU=ABLkAR^1!@;v~a?89mGHA z^&bydo>s>OL5dkb2hPp}rn1Bzz=h1;*T!(MS)wXL>Q|f4F8Qx7ihpw@J%7UKSfEj} z-Az9>$F1_#GDjHYzE8@*MPg5gL+0Vx7#7-DTIKl9$|DRL)3-skJ4^^+TNz4jdcbAP-W;kKB zLLYpVVI#h6M267S9qj($r8eigf<<`+vl%d~W&fAkGOis{($Lk3w%W4QjmR?Co2C+O zjj^`ESTEmQZySaUC@TZ0XKHgN3LGrc`tv zohJL3Cui}M?D=FSB)w&)+s2?bhq-qEryJe~1VdIWX1|m_G{P6<%aHj^eNc5d^fI5b z*9&u+4S1`eFpGPn4zhIHPK+HuRTp6$fEN9#k4avkUB#cr9AeGj{(<>nrqV1hVT&N!nZKwA4{;O z#p@EM!EJ59InNm%7`!CqrVlNt!4?M}b?Cb#%P;&h4`Sd(kYMLs z6;4g{Kh(0pj}8*Ig@l-)dI)q8774MeOJ_r!0eBYZ#YVz&4$uP-g)?I|#PM z#4TWA=e+>mtfD+@57mDL(PTh>5i7AkwNxCkWz*TMDXuM0z6E?g4d$m+C&Fv#4lzI;-vkez1=N@pNF1Bg3|rjXS_9=k2@MG= zC5zUlR{NN#;ee~>U3gcTUHXpIbUK`m4P6GnxR)tyY3^ZIc;4N#y#uS`>GBX0)PoLd zMdH%O*dHLUNJ~!3CCVBD_}h8mWTE5QL~ll&Ym#|~Jv?+!Zg2Hq{>H9!L`*_F8T4Y! z&v@yW+(isDrK3^<4DjVXmnmdQ#*%Z(tRvTb83VgzF3H;ju!eweOB`1U#+jWN{bBlP zn5hot{=%DXP-CYZk6&gqFInhncGBaV(xq`XCz7`qA%0R(F4?S64bu|$xPrz;9z7;*P!S+LjHOC7uue{yvAc>oOO=f~dN6G5kRQo*b*F8wLl z-i!!_!5&%Mc&H1EWM?Kx7W4T~27ga%(H_4R@b8K}eA0n6;n3nn*v=K99&NeBQ*}07 z&|g-&Abtlotae*T-}rMmL%;@O47+UvvD=~#?fkkfz)-QY83#4t{SDyGj@>r{U|>?% z=ejJKEU?P6S}&{4yxY+GVp+N%j49_`az;LK7;js&5VasA9e;?Jplls* zW}*`}kQOGwmrj#Iu$9T}P{)z^^(DT;#q0NTi08V*dI)@tsato0e}DEkua-kPTLH!b zlxQi~_nCNQ!u78#=x40$6rbx20G>qN{-ZpzOm zbr(i*>^L%w4gVFUPZu#EvfgTj-Ia0%0OSY| z7TDh{q0L0qp`h>(KHNuYKZ1eXjwSl7Ql9;MGr^2(v7qY>=vKDX9X{tF+xqj8(vt>s z2>=~1%N_CP1`CQNg{eg-oxW7iqPR@Ud2#-w*r?iONb=}+w)HB>lCfS${{gJT z*l__y>A`NUBJ`HSygk-0D3a`S?y_50DKVgij@gj6qP0@=-X)lG*s(`+OdKDUxC&tC zU_)7OuHoEbX3mA#zoC^{Z=m@5OZ8%TRsP|%%~P4I$ab)2!u5m(K$27M>()9Sl}mRN+J8)_OF+F z(!I{_Pv%d%k9)$UWAr+Y#M})9_@BIkTcHvIwDlfgyAHD0c#c|*Zc(Fksf)gNO{Dh1 zx4eo^XwO{CY1+JF<(uwhtNotbx^b%tcV?v3a1&YWq*U-WPeCUyQSKa=|}@61nmdru#CI5A3j zIXay2IJOBp+_lU(5^H)`qqBlL$J@1elM;Y88P6&}94QR%=CgP|jts=v!orLY>}rRg zpirBvcDZfNA~UqF)&Iz0Y}K_;^~3jzz#hHq{rU}$C;s=rJpbd1v!};Q< zAAKCqb)+L1_-z4y7F>c#qTeS;hT1mU;TFS+*SigV{tK7!8C3icfOascv~1NwKqXe)*tEO-dg$@X2&muVv}l68TGBV z99gq?|Evj9OSp@mjcFIKVWh!5;Ytq5AQ`ZAjX%oF?P|LfuA!xz&U(vF*iYlO;Y&Yf zWosK*vmYd9U!pZ6ZgvDQKpd-4EL}CyJQitX@3As7NOpHalmO!22G-dvh^lvU+qcK# z;OEyEa)>CHe71d9dzMzvuMF@Q!h44|Z7swN3}YP%-4T+m1uHPLR919zSGl5ZNqSBK z`7CJV+S_~+VL9F(li3s5gtt3c+5*@xYPMF_!3yd<18_G=#0N5FrJjtL7fl&ngKED* zD86o@4Xtu#NgieIsaL8e1fu>DL4S4S8_aV_E(VU6_K#KePjE`->dtG1VjuQpMAZ#e zG)!gR1^u49|Mon`3~Z>h_tZ9JAUuRd->?d(Nr(2*HtDOq6lwbIKX?-_*!P(HTRvWg zm3=4NvL+zGw$NRfHSXJuSWd5bid#)ZWa*FkDWsd>j!stQ3gU(-z4gH&KKJ4o|E$vn zBCY{yMaelUKB<2~;Z~9kNH|j0myZ}#=#3?M^os*Va%J1uA4prmVG(86uSxBVe36-x zvHQ)loDVnsnKPK0e~KjhN=GPoGA?l2S(%b_*fNV_*dAm4b{o)I=_`J-<({gZyA%Mi zk3s1IE24Hne|$ExDHDyn7>!3ZZ(1013^@8I){1yE$FJ(eZnPC5>s4l~XEJ zTr0|2?|8$K?3_L?@1q1dqcw}aFKt~zNgq6Yb&W5ATyhYy*7Ilei|P&5ewZ4spIs@{ z!h`jhK17YQFXc|M=}u4RZe=E-p>gOrWmp&uUCq6^A==i~6Vr#L=%r*UTakqFl$-wJ zmd~+Fvy;MYD~yA3O2wPUt$)*=`YeYgF5Q zdb#%af%^A1bAQo#uX=2zXXt?)-hIEhXO#qV9W&{}ZpU63Y*ThBogR&+ z*dA`2;64gH^e6*a{j*92-Wry_oD%Jpa`o86ibCYCMX1th$C|V!w<*Gz(-o1s=?~BZ zgUdlOgsNYR&aFMttM|g$a7!NJ*TyTw{}naB$jTX61(}J;L=%-mE!Ctp!(|pzA(biJ zo_v?xue!=yKegmSiM-rfLy$AP)byd$E501qU%Rbc=Z+RKGlLNronT$kt>|YyM>0fQ z%sNrPn+_7+HK%VEHhgwr_jZ?>-z8Hib4wkwS?`@>UL2Sh$r!D)IP;&V$~TEt?S=1E?VwD&ANWARYY2(f}4 z9(KnXNf*U$_Jmiw0j1WzzP0{c-LCM%W+3RN7ED{+xI*3V3i<4tI_ZDG2T%}Ps*j}C znm^>0^gonUK!@mR{e8lsE)P^l&K{dn#kUd@+wxZOH@KzHVV<%{bcCpHJUD9~8I++< zmiM)4GRsl3LF|K%pLl|7QD?S4N646Z;8A+40ciWny-0ea#%zEQ{xf>+nohu6Fm@*B zskR9%9)&e*@WeyN%GnsXb!WCm!dnGsUjo1=Mkzd$t;gm_VKaRSw=c%!uaX6auYU&j zDI+<~Gt}d6bh1YsI#f78?s;|mFl9(8{T6!9`VHc_ivP)5SQR+Qt6 z3EAe^J+A;2P8?Cg9nQvX-uhS`mCZh=NgF^Ep^Pr67J2h~0F0d2=xIHoh}FG)p@?kx2d$nOcERl(jV2G6ORlX|wok(6z9n&o`F#z>mVT`}vI zIPn(e>!NTCg={S}KyV^M#mzTIBWB9Dub+KavoIVvg&SAyU+*}md+q%<p&7WhJi;nb3BkV)zv#KOcS*cjZk_*{M4?u~)|mSWK6E|aL6W)$8+w=H z=rIe7GPoC$W80*Q2|d1n{cm3b^6c=Pe1GYQC$HB*084p{hYWCLQtVzlCg=~R!mHno zkakO9qw$cMFn-_6o(t545!=ZUi41W;UE!N!yjjkSAc15h8|2#6&8qvUJ{hPcHe`8B z>_f~CDP(gt5fD z2s+ov|{V~tKLvC z8R(cCi1lFpGyFvsC-mim)NInGnIOllADd(1Pdz+!v%YvK4lQ^3#ZnHHu+IfX_rg7g znq;1}5Uer>Hs2XyrDS8oCYbw-84g#2Q5#aBc2){lYAF)!I>C0bv~Q}KiHw0iheRop zpx*uk%M%zQE03gAY(Se=aDc}Ds1s1C5(&U(WV2W`U>bRUW>>Q3jl})$EXy^$nCO9E zmw!Zv&_VzSfiiKSqtHb^fAE<~MQ;xu5bW75TbV?F;*J{Ls)q8S0_nXqP?8;?Sf^n234dkpqg}e~?x%jLT;}}%BPNw6jbHs0eS94Kk0QoNA)?lw z1Z@jRjI;Z|(67AboTxbAI##LY;em&>Yo;@CnQtNw<5B2;`XRV~1RI*(OEIFEJ|`o4 zW|3Nk@+m0?Ht8I$Lh|oF`HzCbO(|USdpk2$4K0sxsJPN`NL=*qZ~t4`wzhkOoj9)x za+lcJ_{$sVjS4ZuT5gQH(zzL7q2Jv6_v~|x|9t>(_J+CwfE1!?3TU@U$8`L|5?mDh zA}9%&bb%sWCeAaGo&$&38^RnXsIqW)gW_}0kr=edZLr8ZE#G3#CKmhLzbt2U|i!lF? zupX#G{(x-IvfF<~_O9&Y)+?RAprnv#+TDLycI2Ma-B!%EayPTQ>oJ6kg1)i@W!>nD znWp?kf%Zs9M4*vsxulPl&K6^l+f4E@EV2kCcL9yg1ewj4%}JvSM@RW;>_1w`>tYu% z(_~ChyARe@V*-3NR@f5%jIw#PD7Pb@Ys%-o#L}SOo#onas0gyW$>5;QleyX0j3P z79h)j$W_N=0J48$RJ&*PPYS~v`3pBB_NDF|1o*P}hx@W!Re-eowAH!G@Ag4@?S&cm zH)k7}f6A#%I{vLF+Jv*0bnmsaL;gD4d?up#c4e*-v92kmpafBXt;{eXLR53$>B*t<`_uUw10;)=*;S7rjTY;{bO zvi~@b=ol^co07SYb^VdgJ;?KZk?2)nk`AKOL@7*Pt#+D0;&M(E57+*YvG?P_YFd7c zo8|nrILvizWw!ZN{zS!rUAHotDl>JlYb-MFWRAC*uG}^9Z7t!CWV8cNf6a&ZvwJ8b>c6-nlbaqVzA6Om^?2W`yj`E|HJU%z~)%BlR8T_5p z7IWdF6z$1|I?X83L~y=TLERU#mRXTbxO*iOE+il_46)4$L|BJ{FFMQTDeL{hnv3fTe{J+Xp?hv_t%p zJKYW{r@D5foS~o=OLJ?B>LCwx0auToSo=CP3R_tqy}7wPRx|}KAXRQs!{=X8yIW+L zLx}84{Iw;G1SzbP7kx-s?$$v(tv`-`z-dGQ-Bt&0Z<3KnBdu?126vu@G?zOKUB9Ls z&NRRyvG8aVVgm}{ehJ?E9-fAU0wn2xND)~AnRJncBu91BLGKmH9;wUsr8EKTuwU=4 z!V%OoZ%CJ>`t|fG)h4GX#$)oU_FqiEb!}1>0g(n&=IRi-2Z#-pa(9x{B}n=|8iY_M z51~rQ5{EvzB4J8#X##q!bm44(A5p`PB&d7tOyhp>lV8oLnO1V0oi95~@Czp3899~d zmV|slWu|ffhy1;4IfU*S7^nEU z3?*J8C-Q?5nBegORDGYVjd5N|Svf1GX0eOfPhHCl3@Oc2)jo*=%QqR{PF6@K{{^+@k`Q78G8>Jys$cxPxX| z?mGBG{S6S`Qn6*ql?J#!=^q)3b-p}Zi;&5^qetAvQeqQunQ!HyWepC|&Hj=<;v}g6 z+7#tx?dk0r7X1X*7ysMp-{!q;ihkAfOTA0YTe;B$%zGOhyWMJ9Eg$%R`o4HW{NGPf zN2`Z&YCJ^{vKlff5A;-?-27_ou{71RTKOVhHIs~TdEs%U=E<)#`GMlV+oI=ASTkY% z>+H=+fFw&Rw(|B~Ohx_bp4jtM|B$F2JcZ9b_g8&2wKniuotjk*qNUEH-Nz$ZN=F*p zfS0o+<95G%$I=L-gZ0W`jcoh6+M`DQZ@pNT8JLp<;zE)ol4auydXBw%v_f?ocipD@ zT}N=#lbU}Vzn#=9{}=herH42&MTi_@r9sl_U3Pu1auDr(XA)Flr7R2jj?ZH^(ztfB zvI#nmuIk2VMn1t4kp!q6es(Q0d{ZY+xO%lpX}9*oVwD|;$?;mj{dp*PJ`!V;RhY> zOG{IKTJ81CZ~h|;A1H-=X@EM6s=^)L5-T8NZ>VO(t|t?J^7^LH?Jk`YS7;Va>gb;3 zfckbnX~e!~(}5R^k*{9v8$}y&ouPj RcFXkqEuZJ_mI6S?{{a + + + + +Poll Process + + + +

      Poll Process

      +

      Last update: + 10-Mar-2014 05:17 + UTC

      +
      +

      The poll process sends NTP packets at intervals determined by the clock discipline algorithm. The process is designed to provide a sufficient update rate to maximize accuracy while minimizing network overhead. The process is designed to operate over a poll exponent range between 3 (8 s) and 17 (36 hr). The minimum and maximum poll exponent within this range can be set using the minpoll and maxpoll options of the server command, with default 6 (64 s) and 10 (1024 s), respectively.

      +

      The poll interval is managed by a heuristic algorithm developed over several years of experimentation. It depends on an exponentially weighted average of clock offset differences, called clock jitter, and a jiggle counter, which is initially set to zero. When a clock update is received and the offset exceeds the clock jitter by a factor of 4, the jiggle counter is increased by the poll exponent; otherwise, it is decreased by twice the poll exponent. If the jiggle counter is greater than an arbitrary threshold of 30, it is reset to 0 and the the poll exponent is increased by 1. If the jiggle counter is less than -30, it is set to 0 and the poll exponent decreased by 1. In effect, the algorithm has a relatively slow reaction to good news, but a relatively fast reaction to bad news.

      +

      As an option of the server command, instead of a single packet, the poll process can send a burst of several packets at 2-s intervals. This is designed to reduce the time to synchronize the clock at initial startup (iburst) and/or to reduce the phase noise at the longer poll intervals (burst). The iburst option is effective only when the server is unreachable, while the burst option is effective only when the server is reachable. The two options are independent of each other and both can be enabled at the same time.

      +

      For the iburst option the number of packets in the burst is six, which is the number normally needed to synchronize the clock; for the burst option, the number of packets in the burst is determined by the difference between the current poll exponent and the minimum poll exponent as a power of 2. For instance, with the default minimum poll exponent of 6 (64 s), only one packet is sent for every poll, while the full number of eight packets is sent at poll exponents of 9 (512 s) or more. This insures that the average headway will never exceed the minimum headway.

      +

      The burst options can result in increased load on the network if not carefully designed. Both options are affected by the provisions described on the Rate Management and the Kiss-o'-Death Packet page. In addition, when iburst or burst are enabled, the first packet of the burst is sent, but the remaining packets sent only when the reply to the fist packet is received. If no reply has been received after a timeout set by the minpoll option, the first packet is sent again. This means that, even if a server is unreachable, the network load is no more than at the minimum poll interval.

      +

      To further reduce the network load when a server is unreachable, an unreach timer is incremented by 1 at each poll interval, but is set to 0 as each packet is received. If the timer exceeds the unreach threshold set at 10, the poll exponent is incremented by 1 and the unreach timer set to 0. This continues until the poll exponent reaches the maximum set by the maxpoll option.

      +
      +

      + +

      + + diff --git a/contrib/ntp/html/pps.html b/contrib/ntp/html/pps.html index b9fcd7f38..0b9bd5d49 100644 --- a/contrib/ntp/html/pps.html +++ b/contrib/ntp/html/pps.html @@ -1,41 +1,47 @@ - - - - - - Pulse-per-second (PPS) Signal Interfacing - - - - -

      Pulse-per-second (PPS) Signal Interfacing

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      Alice is trying to find the PPS signal connector.

      -

      Last update: 18:48 UTC Thursday, July 28, 2005

      -
      -

      Related Links

      - -
      -

      Some radio clocks and related timekeeping gear have a pulse-per-second (PPS) signal that can be used to discipline the system clock to a high degree of precision, typically to the order less than 10 ms in time and 0.01 parts-per-million (PPM) in frequency. This page describes the hardware and software necessar for NTP to use this signal.

      - gifA Gadget Box built by Chuck Hanavin
      -

      Gadget Box

      -

      The PPS signal can be connected in either of two ways: via the data carrier detector (DCD) pin of a serial port or via the acknowledge (ACK) pin of a parallel port, depending on the hardware and operating system. Note that NTP no longer supports connection via the data leads of a serial port. However, the PPS signal levels are usually incompatible with serial port levels. The gadget box consists of a handful of electronic components assembled in a small aluminum box. It includes level converters and a optional modem designed to decode the radio timecode signals transmitted by Canadian time and frequency station CHU. This can be used with the Radio CHU Audio Demodulator/Decoder. A complete set of schematics, PCB artwork and drill templates can be obrtained via the web at gadget.tar.Z.

      -

      Operating System Support 

      -

      Both the serial and parallel port connection require operating system support, which is available in only a few operating systems, including FreeBSD, Linux (with PPSkit patch) and Solaris. Support on an experimental basis is available for several other systems, including SunOS and HP/Compaq/Digital Tru64. The PPSAPI application program interface defined in [1] is the only interface currently supported. Older PPS interfaces based on the ppsclock and tty_clk streams modules are no longer supported. As the PPSAPI is expected to become an IETF cross-platform standard, it should be used by new applications.

      -

      The entire PPS interface functionality is currently provided by inline code in the timepps.h header file. While not all implementations support the full PPSAPI specification, they do support all the functions required for the PPS driver described next. The FreeBSD, Linux and Solaris implementations can be used with the stock kernels provided with those systems; however, the Tru64 and SunOS kernels require additional functions not provided in the stock kernels. Solaris users are cautioned that these functions operate improperly in Solaris versions prior to 2.8 with patch Generic_108528-02. Header files for other systems can be found via the web at nanokernel.tar.gz.

      -

      PPS Driver

      -

      In the preferred mode of operation, PPS signals are processed by the PPS Clock Discipline driver and other clock drivers which might be involved need not know or care about them. In some cases where there is no other driver, time might be obtained from remote NTP servers via the network and local PPS signals, for instance from a calibrated cesium oscillator, used to stabilize the frequency and remove network jitter. Note that the pps configuration command has been obsoleted by this driver.

      -

      The PPS driver operates in conjunction with a preferred peer, as described in the Mitigation Rules and the prefer Keyword page. One of the drivers described in the Reference Clock Drivers page or another NTP server furnishes the coarse timing and disambiguates the seconds numbering of the PPS signal itself. The NTP daemon mitigates between the clock driver or NTP server and the PPS driver as described in that page in order to provide the most accurate time, while respecting the various types of equipment failures that could happen.

      -

      Some Unix system kernels support a PPS signal directly, as described in the A Kernel Model for Precision Timekeeping page. Specifically, the PPS driver can be used to direct the PPS signal to the kernel for use as a discipline source for both time and frequency. The presence of the kernel support is automatically detected during the NTP build process and supporting code automatically compiled. Note that the PPS driver does not normally enable the PPS kernel code, since performance is generally better without it. However, this code can be enabled by a driver fudge flag if necessary.

      -

      Some configurations may include multiple radio clocks with individual PPS outputs. In some PPSAPI designs multiple PPS signals can be connected to multiple instances of the PPS driver. In such cases the NTP mitigation and grooming algorithms operate with all the radio timecodes and PPS signals to develop the highest degree of redundancy and survivability.

      -

      Reference

      -
        -
      1. Mogul, J., D. Mills, J. Brittenson, J. Stone and U. Windl. Pulse-per-second API for Unix-like operating systems, version 1. Request for Comments RFC-2783, Internet Engineering Task Force, March 2000, 31 pp. ASCII -
      -
      - - - - \ No newline at end of file + + + +Pulse-Per-Second (PPS) Signal Interfacing + + + +

      Pulse-Per-Second (PPS) Signal Interfacing

      +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

      Alice is trying to find the PPS signal connector.

      +

      Last update: + 10-Mar-2014 05:17 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      Introduction

      +

      Most radio clocks are connected using a serial port operating at speeds of 9600 bps. The accuracy using typical timecode formats, where the on-time epoch is indicated by a designated ASCII character such as carriage-return <cr>, is normally limited to 100 μs. Using carefully crafted averaging techniques, the NTP algorithms can whittle this down to a few tens of microseconds. However, some radios produce a pulse-per-second (PPS) signal which can be used to improve the accuracy to a few microseconds. This page describes the hardware and software necessary for NTP to use the PPS signal.

      +

      The PPS signal can be connected in either of two ways. On FreeBSD systems (with the PPS_SYNC and pps kernel options) it can be connected directly to the ACK pin of a parallel port. This is the preferred way, as it requires no additional hardware. Alternatively, it can be connected via the DCD pin of a serial port. However, the PPS signal levels are usually incompatible with the serial port interface signals. Note that NTP no longer supports connection via the RD pin of a serial port.

      +
      +

      gif

      +

      A Gadget Box built by Chuck Hanavin

      +
      +

      Gadget Box

      +

      The gadget box shown above is assembled in a 5"x3"x2" aluminum minibox containing the the circuitry, serial connector and optional 12-V power connector. A complete set of schematics, PCB artwork, drill templates can be obtained via the web from ftp.udel.edu as gadget.tar.Z.

      +

      The gadget box includes two subcircuits. One of these converts a TTL positive edge into a fixed-width pulse at EIA levels and is for use with a timecode receiver or precision oscillator with a TTL PPS output. The other converts the timecode modulation broadcast by Canadian time/frequency standard station CHU into a 300-bps serial character stream at EIA levels and is for use with the Radio CHU Audio Demodulator/Decoder driver.

      +

      Operating System Support

      +

      Both the serial and parallel port connection require operating system support, which is available in a few operating systems, including FreeBSD, Linux (with PPSkit patch) and Solaris. Support on an experimental basis is available for several other systems, including SunOS and HP/Compaq/Digital Tru64. The kernel interface described on the PPSAPI Interface for Precision Time Signals page is the only interface currently supported. Older PPS interfaces based on the ppsclock and tty_clk streams modules are no longer supported. The interface consists of the timepps.h header file which is specific to each system. It is included automatically when the distribution is built.

      +

      PPS Driver

      +

      PPS support requires is built into some drivers, in particular the WWVB and NMEA drivers, and may be added to other drivers in future. Alternatively, the PPS driver described on the Type 22 PPS Clock Discipline page can be used. It operates in conjunction with another source that provides seconds numbering. The selected source is designate a prefer peer, as using the prefer option, as described on the Mitigation Rules and the prefer Keyword page. The prefer peer is ordinarily the radio clock that provides the PPS signal, but in principle another radio clock or even a remote Internet server could be designated preferred Note that the pps configuration command has been obsoleted by this driver.

      +

      Using the Pulse-per-Second (PPS) Signal

      +

      The PPS signal can be used in either of two ways, one using the NTP grooming and mitigation algorithms and the other using the kernel PPS signal support described in the Kernel Model for Precision Timekeeping page. The presence of  kernel support is automatically detected during the NTP build process and supporting code automatically compiled. In either case, the PPS signal must be present and within nominal jitter and wander tolerances. In addition, the prefer peer must be a truechimer; that is, survive the sanity checks and intersection algorithm. Finally, the offset of the system clock relative to the prefer peer must be within ±0.5 s. The kernel maintains a watchdog timer for the PPS signal; if the signal has not been heard or is out of tolerance for more than some interval, currently two minutes, the kernel discipline is disabled and operation continues as if it were not present.

      +

      An option flag in the driver determines whether the NTP algorithms or kernel support is enabled (if available). For historical reasons, the NTP algorithms are selected by by default, since performance is generally better using older, slower systems. However, performance is generally better with kernl support using newer, faster systems.

      +
      + + + diff --git a/contrib/ntp/html/prefer.html b/contrib/ntp/html/prefer.html index 00225d1db..0fd0b8f4b 100644 --- a/contrib/ntp/html/prefer.html +++ b/contrib/ntp/html/prefer.html @@ -1,72 +1,93 @@ - - - - - Mitigation Rules and the prefer Keyword - - - - -

      Mitigation Rules and the prefer Keyword

      - gif from Alice's Adventures in Wonderland, Lewis Carroll -

      Listen carefully to what I say; it is very complicated.

      -

      Last update: 18:49 UTC Thursday, July 28, 2005

      -
      -

      Related Links

      - -

      Table of Contents

      - -
      -

      Introduction

      -

      The mechanics of the NTP algorithms which select the best data sample from each available server and the best subset of the server population have been finely crafted to resist network jitter, faults in the network or server operations, and to deliver the best possible accuracy. Most of the time these algorithms do a good job without requiring explicit manual tailoring of the configuration file. However, there are times when the accuracy can be improved by some careful tailoring. The following sections explain how to do this using explicit configuration items and special signals, when available, that are generated by some radio clocks and laboratory instruments.

      -

      In order to provide robust backup sources, primary (stratum-1) servers are usually operated in a diversity configuration, in which the server operates with a number of remote servers in addition to one or more radio or modem clocks. In these configurations the suite of algorithms used in NTP to refine the data from each peer separately and to select and combine the data from a number of servers and clocks. As the result of these algorithms, a set of survivors are identified which can presumably provide the most reliable and accurate time. Ordinarily, the individual clock offsets of the survivors are combined on a weighted average basis to produce an offset used to control the system clock.

      -

      However, because of small but significant systematic time offsets between the survivors, it is in general not possible to achieve the lowest jitter and highest stability in these configurations. This happens because the selection algorithm tends to clockhop between survivors of substantially the same quality, but showing small systematic offsets between them. In addition, there are a number of configurations involving pulse-per-second (PPS) signals, modem backup services and other special cases, so that a set of mitigation rules becomes necessary to select a single peer from among the survivors. These rules are based on a set of special characteristics of the various remote servers and reference clock drivers specified in the configuration file.

      -

      The prefer Peer

      -

      The mitigation rules are designed to provide an intelligent selection between various sources of substantially the same statistical quality without compromising the normal operation of the NTP algorithms. While they have been implemented in NTP Version 4 and will be incorporated in the NTP Version 4 specification when published, they are not in the NTP Version 3 specification RFC-1305. The rules are based on the concept of prefer peer, which is specified by including the prefer keyword with the associated server or peer command in the configuration file. This keyword can be used with any server or peer, but is most commonly used with a radio clock. While the rules do not forbid it, it does not seem useful to designate more than one peer as preferred, since the additional complexities to mitigate among them do not seem justified from on-air experience.

      -

      The prefer scheme works on the set of peers that have survived the sanity checks and intersection algorithms of the clock selection procedures. Ordinarily, the members of this set can be considered truechimers and any one of them could in principle provide correct time; however, due to various error contributions, not all can provide the most accurate and stable time. The job of the clustering algorithm, which is invoked at this point, is to select the best subset of the survivors providing the least variance in the combined ensemble average, compared to the variance in each member of the subset separately. The detailed operation of the clustering algorithm, which is given in RFC-1305, is beyond the scope of discussion here. It operates in rounds, where a survivor, presumably the worst of the lot, is discarded in each round until one of several termination conditions is met. An example terminating condition is when the number of survivors is about to be reduced below three.

      -

      In the prefer scheme the clustering algorithm is modified so that the prefer peer is never discarded; on the contrary, its potential removal becomes a termination condition. If the original algorithm were about to toss out the prefer peer, the algorithm terminates immediately. The prefer peer can still be discarded by the sanity checks and intersection algorithm, of course, but it will always survive the clustering algorithm. If it does not survive or for some reason it fails to provide updates, it will eventually become unreachable and the clock selection will remitigate to select the next best source.

      -

      Along with this behavior, the clock selection procedures are modified so that the combining algorithm is not used when a prefer peer is present. Instead, the offset of the prefer peer is used exclusively as the synchronization source. In the usual case involving a radio clock and a flock of remote stratum-1 peers, and with the radio clock designated a prefer peer, the result is that the high quality radio time disciplines the server clock as long as the radio itself remains operational and with valid time, as determined from the remote peers, sanity checks and intersection algorithm.

      -

      Peer Classification

      -

      In order to understand the effects of the various intricate schemes involved, it is necessary to understand some arcane details on how the algorithms decide on a synchronization source when more than one source is available. This is done on the basis of a set of explicit mitigation rules, which define special classes of remote serves and local radio clocks as a function of configuration declarations and clock driver type:

      -
        -
      1. The prefer peer is designated using the prefer keyword with the server or peer commands. All other things being equal, this peer will be selected for synchronization over all other survivors of the clock selection procedures. -
      2. When a PPS signal is connected via the PPS Clock Discipline driver (type 22), this is called the PPS peer. This driver provides precision clock corrections only within one second, so is always operated in conjunction with another server or radio clock driver, which provides the seconds numbering. The PPS peer is active only under conditions explained below. -
      3. When the Undisciplined Local Clock driver (type 1) is configured, this is called the local clock peer. This is used either as a backup reference source (stratum greater than zero), should all other synchronization sources fail, or as the primary reference source (stratum zero) in cases where the kernel time is disciplined by some other means of synchronization, such as the NIST lockclock scheme, or another synchronization protocol, such as the Digital Time Synchronization Service (DTSS). -
      4. When a modem driver such as the Automated Computer Time Service driver (type 18) is configured, this is called the modem peer. This is used either as a backup reference source, should all other primary sources fail, or as the (only) primary reference source. -
      5. Where support is available, the PPS signal may be processed directly by the kernel, as described in the A Kernel Model for Precision Timekeeping page. This is called the kernel discipline. The PPS signal can discipline the kernel in both frequency and time. The frequency discipline is active as long as the PPS interface device and signal itself is operating correctly, as determined by the kernel algorithms. The time discipline is active only under conditions explained below. -
      -

      Reference clock drivers operate in the manner described in the Reference Clock Drivers page and its dependencies. The drivers are ordinarily operated at stratum zero, so that as the result of ordinary NTP operations, the server itself operates at stratum one, as required by the NTP specification. In some cases described below, the driver is intentionally operated at an elevated stratum, so that it will be selected only if no other survivor is present with a lower stratum. In the case of the PPS peer or kernel time discipline, these sources appear active only if the prefer peer has survived the intersection and clustering algorithms, as described below, and its clock offset relative to the current local clock is less than a specified value, currently 128 ms.

      -

      The modem clock drivers are a special case. Ordinarily, the update interval between modem calls to synchronize the system clock is many times longer than the interval between polls of either a remote server or local radio clock. In order to provide the best stability, the operation of the clock discipline algorithm changes gradually from a phase-lock mode at the shorter update intervals to a frequency-lock mode at the longer update intervals. If remote servers or local radio clocks together with a modem peer operate in the same client, the following things can happen.

      -

      First the clock selection algorithm can select one or more remote servers or local radio clocks and the clock discipline algorithm will optimize for the shorter update intervals. Then, the selection algorithm can select the modem peer, which requires a much different optimization. The intent in the design is to allow the modem peer to control the system clock either when no other source is available or, if the modem peer happens to be marked as prefer, then it always controls the clock, as long as it passes the sanity checks and intersection algorithm. There still is room for suboptimal operation in this scheme, since a noise spike can still cause a clockhop either way. Nevertheless, the optimization function is slow to adapt, so that a clockhop or two does not cause much harm.

      -

      The local clock driver is another special case. Normally, this driver is eligible for selection only if no other source is available. When selected, vernier adjustments introduced via the configuration file or remotely using the ntpdc program can be used to trim the local clock frequency and time. However, if the local clock driver is designated the prefer peer, this driver is always selected and all other sources are ignored. This behavior is intended for use when the kernel time is controlled by some means external to NTP, such as the NIST lockclock algorithm or another time synchronization protocol such as DTSS. In this case the only way to disable the local clock driver is to mark it unsynchronized using the leap indicator bits. In the case of modified kernels with the ntp_adjtime() system call, this can be done automatically if the external synchronization protocol uses it to discipline the kernel time.

      -

      Mitigation Rules

      -

      The mitigation rules apply in the intersection and clustering algorithms described in the NTP specification. The intersection algorithm first scans all peers with a persistent association and includes only those that satisfy specified sanity checks. In addition to the checks required by the specification, the mitigation rules require either the local-clock peer or modem peer to be included only if marked as the prefer peer. The intersection algorithm operates on the included population to select only those peers believed to represent the correct time. If one or more peers survive the algorithm, processing continues in the clustering algorithm. Otherwise, if there is a modem peer, it is declared the only survivor; otherwise, if there is a local-clock peer, it is declared the only survivor. Processing then continues in the clustering algorithm.

      -

      The clustering algorithm repeatedly discards outlyers in order to reduce the residual jitter in the survivor population. As required by the NTP specification, these operations continue until either a specified minimum number of survivors remain or the minimum select dispersion of the population is greater than the maximum peer dispersion of any member. The mitigation rules require an additional terminating condition which stops these operations at the point where the prefer peer is about to be discarded.

      -

      The mitigation rules establish the choice of system peer, which determines the stratum, reference identifier and several other system variables which are visible to clients of the server. In addition, they establish which source or combination of sources control the local clock.

      -
        -
      1. If there is a prefer peer and it is the local-clock peer or the modem peer; or, if there is a prefer peer and the kernel time discipline is active, choose the prefer peer as the system peer and its offset as the system clock offset. If the prefer peer is the local-clock peer, an offset can be calculated by the driver to produce a frequency offset in order to correct for systematic frequency errors. In case a source other than NTP is controlling the system clock, corrections determined by NTP can be ignored by using the disable pll in the configuration file. If the prefer peer is the modem peer, it must be the primary source for the reasons noted above. If the kernel time discipline is active, the system clock offset is ignored and the corrections handled directly by the kernel. -
      2. If the above is not the case and there is a PPS peer, then choose it as the system peer and its offset as the system clock offset. -
      3. If the above is not the case and there is a prefer peer (not the local-clock or modem peer in this case), then choose it as the system peer and its offset as the system clock offset. -
      4. If the above is not the case and the peer previously chosen as the system peer is in the surviving population, then choose it as the system peer and average its offset along with the other survivors to determine the system clock offset. This behavior is designed to avoid excess jitter due to clockhopping, when switching the system peer would not materially improve the time accuracy. -
      5. If the above is not the case, then choose the first candidate in the list of survivors ranked in order of synchronization distance and average its offset along with the other survivors to determine the system clock offset. This is the default case and the only case considered in the current NTP specification. -
      -

      Using the Pulse-per-Second (PPS) Signal

      -

      Most radio clocks are connected using a serial port operating at speeds of 9600 bps or higher. The accuracy using typical timecode formats, where the on-time epoch is indicated by a designated ASCII character, like carriage-return <cr>, is limited to a millisecond or two. However, some radios produce a PPS signal which can be used to improve the accuracy with typical workstation servers to the order of microseconds. The details of how this can be accomplished are discussed in the Pulse-per-second (PPS) Signal Interfacing page. The following paragraphs discuss how the PPS signal is affected by the mitigation rules.

      -

      First, it should be pointed out that the PPS signal is inherently ambiguous, in that it provides a precise seconds epoch, but does not provide a way to number the seconds. In principle and most commonly, another source of synchronization, either the timecode from an associated radio clock, or even one or more remote NTP servers, is available to perform that function. In all cases, a specific, configured peer or server must be designated as associated with the PPS signal. This is done using the prefer keyword as described previously. The PPS signal can be associated in this way with any peer, but is most commonly used with the radio clock generating the PPS signal.

      -

      The PPS signal can be used in two ways to discipline the local clock, one using a special PPS driver described in the PPS Clock Discipline page, the other using PPS signal support in the kernel, as described in the A Kernel Model for Precision Timekeeping page. In either case, the signal must be present and within nominal jitter and wander error tolerances. In addition, the associated prefer peer must have survived the sanity checks and intersection algorithms and the dispersion settled below 1 s. This insures that the radio clock hardware is operating correctly and that, presumably, the PPS signal is operating correctly as well. Second, the absolute offset of the local clock from that peer must be less than 128 ms, or well within the 0.5-s unambiguous range of the PPS signal itself. In the case of the PPS driver, the time offsets generated from the PPS signal are propagated via the clock filter to the clock selection procedures just like any other peer. Should these pass the sanity checks and intersection algorithms, they will show up along with the offsets of the prefer peer itself. Note that, unlike the prefer peer, the PPS peer samples are not protected from discard by the clustering algorithm. These complicated procedures insure that the PPS offsets developed in this way are the most accurate, reliable available for synchronization.

      -

      The PPS peer remains active as long as it survives the intersection algorithm and the prefer peer is reachable; however, like any other clock driver, it runs a reachability algorithm on the PPS signal itself. If for some reason the signal fails or displays gross errors, the PPS peer will either become unreachable or stray out of the survivor population. In this case the clock selection remitigates as described above.

      -

      When kernel support for the PPS signal is available, the PPS signal is interfaced to the kernel serial driver code via a modem control lead. As the PPS signal is derived from external equipment, cables, etc., which sometimes fail, a good deal of error checking is done in the kernel to detect signal failure and excessive noise. The way in which the mitigation rules affect the kernel discipline is as follows.

      -

      PPS support requires the PPS driver (type 22) and PPSAPI interface described in the Pulse-per-second (PPS) Signal Interfacing page. In order to operate, the prefer peer must be designated and the kernel support enabled by the enable pps command in the configuration file and the signal must be present and within nominal jitter and wander error tolerances. In the NTP daemon, the PPS discipline is active only when the prefer peer is among the survivors of the clustering algorithm, and its absolute offset is within 128 ms, as determined by the PPS driver. Under these conditions the kernel disregards updates produced by the NTP daemon and uses its internal PPS source instead. The kernel maintains a watchdog timer for the PPS signal; if the signal has not been heard or is out of tolerance for more than some interval, currently two minutes, the kernel discipline is declared inoperable and operation continues as if it were not present.

      -
      - - - - \ No newline at end of file + + +Mitigation Rules and the prefer Keyword + + + +

      Mitigation Rules and the prefer Keyword

      +gif from Alice's Adventures in Wonderland, Lewis Carroll +

      Listen carefully to what I say; it is very complicated.

      +

      Last update: + 10-Mar-2014 05:18 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      1. Introduction and Overview

      +

      This page summarizes the criteria for choosing from among the survivors of the clock cluster algorithm a set of contributors to the clock discipline algorithm. The criteria are very meticulous, since they have to handle many different scenarios that may be optimized for special circumstances, including some scenarios designed to support planetary and deep space missions. For additional information on statistical principles and performance metrics, see the Performance Metrics page.

      +

      Recall the suite of NTP data acquisition and grooming algorithms. These algorithms proceed in five phases. Phase one discovers the available sources and mobilizes an association for each source found. These sources can result from explicit configuration, broadcast discovery or the pool and manycast autonomous configuration schemes. See the Automatic Server Discovery Schemes page for further information.

      +

      Phase two selects the candidates from among the sources by excluding those sources showing one or more of the errors summarized on the Clock Select Algorithm page and to determine the truechimers from among the candidates, leaving behind the falsetickers. A server or peer configured with the true option is declared a truechimer independent of this algorithm. Phase four uses the algorithm described on the Clock Cluster Algorithm page to prune the statistical outliers from the truechimers, leaving the survivor list as result.

      +

      Phase five uses a set of algorithms and mitigation rules to combined the survivor statistics and discipline the system clock. The mitigation rules select from among the survivors a system peer from which a set of system statistics can be inherited and passed along to dependent clients, if any. The mitigation algorithms and rules are the main topic of this page. The clock offset developed from these algorithms can discipline the system clock, either using the clock discipline algorithm or using the kernel to discipline the system clock directly, as described on the A Kernel Model for Precision Timekeeping page.

      +

      2. Combine Algorithm

      +

      The clock combine algorithm uses the survivor list to produce a weighted average of both offset and jitter. Absent other considerations discussed later, the combined offset is used to discipline the system clock, while the combined jitter is augmented with other components to produce the system jitter statistic inherited by dependent clients, if any.

      +

      The clock combine algorithm uses a weight factor for each survivor equal to the reciprocal of the root distance. This is normalized so that the sum of the reciprocals is equal to unity. This design favors the survivors at the smallest root distance and thus the smallest maximum error.

      +

      3. Anti-Clockhop Algorithm

      +

      The anti-clockhop algorithm is intended for cases where multiple servers are available on a fast LAN with modern computers. Typical offset differences between servers in such cases are less than 0.5 ms. However, changes between servers can result in unnecessary system jitter. The object of the anti-clockhop algorithm is to avoid changing the current system peer, unless it becomes stale or has significant offset relative to other candidates on the survivor list.

      +

      For the purposes of the following description, call the last selected system peer the old peer, and the currently selected source the candidate peer. At each update, the candidate peer is selected as the first peer on the survivor list sorted by increasing root distance. The algorithm initializes the -clockhop threshold with the value of mindist, by default 1 ms.

      +

      The anti-clockhop algorithm is called immediately after the combine algorithm. If there was no old peer or the old and candidate peers are the same, the candidate peer becomes the system peer. If the old peer and the candidate peer are different, the algorithm measures the difference between the offset of the old peer and the candidate peer. If the difference exceeds the clockhop threshold, the candidate peer becomes the system peer and the clockhop threshold is restored to its original value. If the difference is less than the clockhop threshold, the old peer continues as the system peer. However, at each subsequent update, the algorithm reduces the clockhop threshold by half. Should operation continue in this way, the candidate peer will eventually become the system peer.

      +

      4. Peer Classification

      +

      The behavior of the various algorithms and mitigation rules involved depends on how the various synchronization sources are classified. This depends on whether the source is local or remote and if local, the type of source. The following classes are defined:

      +
        +
      1. A selectable association configured for a remote server or peer is classified as a client association. All other selectable associations are classified as device driver associations of one kind or another. In general, one or more sources of either type will be available in each installation.
      2. +
      3. If all sources have been lost and one or more hosts on a common DMZ network have specified the orphan stratum in the orphan option of the tos command, each of them can become an orphan parent. Dependent orphan children on the same DMZ network will see the orphan parents as if synchronized to a server at the orphan stratum. Note that, as described on the Orphan Mode page, all orphan children will select the same orphan parent for synchronization.
      4. +
      5. When a device driver has been configured for pulse-per-second (PPS) signals and PPS signals are being received, it is designated the PPS driver. Note that the Pulse-per-Second driver (type 22) is often used as a PPS driver, but any driver can be configure as a PPS driver if the hardware facilities are available. The PPS driver provides precision clock discipline only within ±0.4 s, so it is always associated with another source or sources that provide the seconds numbering function.
      6. +
      7. When the Undisciplined Local Clock driver (type 1) is configured, it is designated the local driver. It can be used either as a backup source (stratum greater than zero) should all sources fail, or as the primary source (stratum zero) whether or not other sources are available if the prefer option is present. The local driver can be used when the kernel time is disciplined by some other means of synchronization, such as the NIST lock clock scheme, or another synchronization protocol such as the IEEE 1588 Precision Time Protocol (PTP) or Digital Time Synchronization Service (DTSS).
      8. +
      9. When the Automated Computer Time Service driver (type 18) is configured, it is designated the modem driver. It is used either as a backup source, should all other sources fail, or as the primary source if the prefer option is present.
      10. +
      +

      5. The prefer Peer

      +

      The mitigation rules are designed to provide an intelligent selection of the system peer from among the selectable sources of different types. When used with the server or peer commands, the prefer option designates one or more sources as preferred over all others. While the rules do not forbid it, it is usually not useful to designate more than one source as preferred; however, if more than one source is so designated, they are used in the order specified in the configuration file. If the first one becomes un selectable, the second one is considered and so forth. This order of priority is also applicable to multiple PPS drivers, multiple modem drivers and even multiple local drivers, although that would not normally be useful.

      +

      The cluster algorithm works on the set of truechimers produced by the select algorithm. At each round the algorithm casts off the survivor least likely to influence the choice of system peer. If selectable, the prefer peer is never discarded; on the contrary, its potential removal becomes a termination condition. However, the prefer peer can still be discarded by the select algorithm as a falseticker; otherwise, the prefer peer becomes the system peer.

      +

      Ordinarily, the combine algorithm computes a weighted average of the survivor + offset and jitter to produce the final values. However, if a prefer + peer is among the survivors, the combine algorithm is not used. Instead, + the offset and jitter of the prefer peer are used exclusively as the final values. In the common case involving a radio clock and a flock of remote backup + servers, and with the radio clock designated a prefer peer, the + the radio clock disciplines the system clock as long as the radio itself + remains operational. However, if the radio fails or becomes a falseticker, + the combined backup sources continue to discipline the system clock.

      +

      6. Mitigation Rules

      +

      As the select algorithm scans the associations for selectable candidates, the modem driver and local driver are segregated for later, but only if not designated a prefer peer. If so designated, the driver is included among the candidate population. In addition, if orphan parents are found, the parent with the lowest metric is segregated for later; the others are discarded. For this purpose the metric is defined as the four-octet IPv4 address or the first four octets of the hashed IPv6 address. The resulting candidates, including any prefer peers found, are processed by the select algorithm to produce a possibly empty set of truechimers.

      +

      As previously noted, the cluster algorithm casts out outliers, leaving the survivor list for later processing. The survivor list is then sorted by increasing root distance and the first entry temporarily designated the system peer. At this point the following contributors to the system clock discipline may be available:

      +
        +
      • (potential) system peer, if there are survivors;
      • +
      • orphan parent, if present;
      • +
      • local driver, if present;
      • +
      • modem driver, if present;
      • +
      • prefer peer, if present;
      • +
      • PPS driver, if present.
      • +
      +

      The mitigation algorithm proceeds in three steps in turn.

      +
        +
      1. If there are no survivors, the modem driver becomes the only survivor if there is one. If not, the local driver becomes the only survivor if there is one. If not, the orphan parent becomes the only survivor if there is one. If the number of survivors at this point is less than the minsane option of the tos command, the algorithm is terminated and the system variables remain unchanged. Note that minsane is by default 1, but can be set at any value including 0.
      2. +
      3. If the prefer peer is among the survivors, it becomes the system peer and its offset and jitter are inherited by the corresponding system variables. Otherwise, the combine algorithm computes these variables from the survivor population.
      4. +
      5. If there is a PPS driver and the system clock offset at this point is less than 0.4 s, and if there is a prefer peer among the survivors or if the PPS peer is designated as a prefer peer, the PPS driver becomes the system peer and its offset and jitter are inherited by the system variables, thus overriding any variables already computed. Note that a PPS driver is present only if PPS signals are actually being received and enabled by the associated driver.
      6. +
      +

      If none of the above is the case, the data are disregarded and the system variables remain as they are.

      +

      7. The minsane Option

      +

      The minsane option of the tos command, the prefer option of the server and peer commands and the flag option of the fudge command for a selected driver can be used with the mitigation rules to provide many useful configurations. The minsane option specifies the minimum number of survivors required to synchronize the system clock. The prefer option operates as described in previous sections. The flag option enables the PPS signal for the selected driver.

      +

      A common scenario is a GPS driver with a serial timecode and PPS signal. The + PPS signal is disabled until the system clock has been set by some means, not + necessarily the GPS driver. If the serial timecode is within 0.4 s of the PPS + signal, the GPS driver is designated the PPS driver and the PPS signal disciplines + the system clock. If the serial timecode becomes unreliable, or if the PPS signal is + disconnected, the GPS driver stops updating the system clock and so eventually + becomes unreachable and is replaced by other sources.

      +

      Whether or not the GPS driver disables the PPS signal when the timecode becomes unreliable is + at the discretion of the driver. Ordinarily, the PPS signal is disabled in this case; however, when the GPS receiver has a precision holdover oscillator, the driver may elect to continue PPS discipline . In this case, minsane can be set to zero so the PPS signal continues to discipline the system clock.

      +
      + + + diff --git a/contrib/ntp/html/quick.html b/contrib/ntp/html/quick.html new file mode 100644 index 000000000..9b6859baa --- /dev/null +++ b/contrib/ntp/html/quick.html @@ -0,0 +1,45 @@ + + + + + +Quick Start + + + +

      Last update: + 1-Dec-2012 04:44 + UTC

      +

      Quick Start

      +gifFAX test image for SATNET (1979). +

      The baby panda was scanned at University College London and used as a FAX test image for a demonstration of the DARPA Atlantic SATNET Program and the first transatlantic Internet connection in 1978. The computing system used for that demonstration was called the Fuzzball. As it happened, this was also the first Internet multimedia presentation and the first to use a predecessor of NTP in regular operation. The image was widely copied and used for testing purpose throughout much of the 1980s.

      +

      Last update: + 1-Dec-2012 04:44 + UTC

      +

      Related Links

      + +
      +

      For the rank amateur the sheer volume of the documentation collection must be intimidating. However, it doesn't take much to fly the ntpd daemon with a simple configuration where a workstation needs to synchronize to some server elsewhere in the Internet. The first thing is to build the distribution for the particular workstation and install in the usual place. The Building and Installing the Distribution page describes how to do this.

      +

      While it is possible that certain configurations do not need a configuration file, most do. The file, called by default /etc/ntp.conf, need only contain one command specifying a remote server, for instance

      +

      server foo.bar.com

      +

      Choosing an appropriate remote server is somewhat of a black art, but a + suboptimal choice is seldom a problem. The simplest and best is to use the + Server Pool Scheme on the Automatic Server Discovery page. There + are about two dozen public time servers operated by the National + Institutes of Science and Technology (NIST), US + Naval Observatory (USNO), Canadian + Metrology Centre (CMC) and many others available on the Internet. Lists + of public primary and secondary NTP servers maintained on the Public + NTP Time Servers page, which is updated frequently. The lists are sorted + by country and, in the case of the US, by state. Usually, the best + choice is the nearest in geographical terms, but the terms of engagement + specified in each list entry should be carefully respected.

      +

      During operation ntpd measures and corrects for incidental clock frequency error and occasionally writes the current value to a file specified by the

      +

      driftfile /etc/ntp.drift

      +

      configuration command. If ntpd is stopped and restarted, it initializes the frequency from this file and avoids the potentially lengthy interval to relearn the correction.

      +

      That's all there is to it, unless some problem in network connectivity or local operating system configuration occurs. The most common problem is some firewall between the workstation and server. System administrators should understand NTP uses UDP port 123 as both the source and destination port and that NTP does not involve any operating system interaction other than to set the system clock. While almost all modern Unix systems have included NTP and UDP port 123 defined in the services file, this should be checked if ntpd fails to come up at all.

      +

      The best way to confirm NTP is working is using the ntpq utility, although the ntpdc utility may be useful in extreme cases. See the documentation pages for further information. Don't forget to check for system log messages. In the most extreme cases the -d option on the ntpd command line results in a blow-by-blow trace of the daemon operations. While the trace output can be cryptic, to say the least, it gives a general idea of what the program is doing and, in particular, details the arriving and departing packets and any errors found.

      +
      + + + diff --git a/contrib/ntp/html/rate.html b/contrib/ntp/html/rate.html new file mode 100644 index 000000000..2b47db80b --- /dev/null +++ b/contrib/ntp/html/rate.html @@ -0,0 +1,67 @@ + + + + + +Rate Management and the Kiss-o'-Death + + + + +

      Rate Management and the Kiss-o'-Death Packet

      +giffrom Pogo, Walt Kelly +

      Our junior managers and the administrators.

      +

      Last update: + 10-Mar-2014 05:19 + UTC

      +
      +

      Related Links

      + + +

      Table of Contents

      + +
      +

      Introduction

      +

      This page describes the various rate management provisions in NTPv4. Some national time metrology laboratories, including NIST and USNO, use the NTP reference implementation in their very busy public time servers. They operate multiple servers behind load-balancing devices to support aggregate rates up to ten thousand packets per second. The servers need to defend themselves against all manner of broken client implementations that can clog the server and network infrastructure. On the other hand, friendly clients need to avoid configurations that can result in unfriendly behavior.

      +

      A review of past client abuse incidence shows the most frequent scenario is a broken client that attempts to send packets at rates of one per second or more. On one occasion due to a defective client design [1], over 750,000 clients demonstrated this abuse. There have been occasions where this abuse has persisted for days at a time. These scenarios are the most damaging, as they can threaten not only the victim server but the network infrastructure as well.

      +

      There are several features in the reference implementation designed to defend the servers and network against accidental or intentional flood attack. Other features are used to insure that the client is a good citizen, even if configured in unfriendly ways. The ground rules are:

      +
        +
      • Send at the lowest rate consistent with the expected accuracy requirements.
      • +
      • Maintain strict guard time and minimum average headway time, even if multiple burst options and/or the Autokey protocol are operating.
      • +
      • When the first packet of a burst is sent to a server, do not send further packets until the first packet has been received from the server.
      • +
      • Upon receiving a Kiss-o'-Death packet (KoD, see below), immediately reduce the sending rate.
      • +
      +

      Rate management involves four algorithms to manage resources: (1) poll rate control, (2) burst control, (3) average headway time and (4) guard time. The first two algorithms are described on the Poll Program page; the remaining two are described in following sections.

      +

      Minimum Headway Time

      +

      The headway is defined for each source as the interval between the last packet sent or received and the next packet for that source. The minimum receive headway is defined as the guard time. In the reference implementation, if the receive headway is less than the guard time, the packet is discarded. The guard time defaults to 2 s, but this can be changed using the minimum option of the discard command. By design, the minimum interval between burst and iburst packets sent by any client is 2 s, which does not violate this constraint. Packets sent by other implementations that violate this constraint will be dropped and a KoD packet returned, if enabled.

      +

      Minimum Average Headway Time

      +

      There are two features in the reference implementation to manage the minimum average headway time between one packet and the next, and thus the maximum average rate for each source. The transmit throttle limits the rate for transmit packets, while the receive discard limits the rate for receive packets. These features make use of a pair of counters: a client output counter for each association and a server input counter for each distinct client IP address. For each packet received, the input counter increments by a value equal to the minimum average headway (MAH) and then decrements by one each second. For each packet transmitted, the output counter increments by the MAH and then decrements by one each second. The default MAH is 8 s, but this can be changed using the average option of the discard command.

      +

      If the iburst or burst options are present, the poll algorithm sends a burst of packets instead of a single packet at each poll opportunity. The NTPv4 specification requires that bursts contain no more than eight packets. Starting from an output counter value of zero, the maximum counter value, called the ceiling, can be no more than eight times the MAH. However, if the burst starts with a counter value other than zero, there is a potential to exceed the ceiling. This can result from protocol restarts and/or Autokey protocol operations. In these cases the poll algorithm throttles the output rate by computing an additional headway time so that the next packet sent will not exceed the ceiling. Designs such as this are often called leaky buckets.

      +

      The reference implementation uses a special most-recently used (MRU) list of entries, one entry for each distinct client IP address found. Each entry includes the IP address, input counter and process time at the last packet arrival. As each packet arrives, the IP source address is compared to the IP address in each entry in turn. If a match is found the entry is removed and inserted first on the list. If the IP source address does not match any entry, a new entry is created and inserted first, possibly discarding the last entry if the list is full. Observers will note this is the same algorithm used for page replacement in virtual memory systems. However, in the virtual memory algorithm the entry of interest is the last, whereas here the entry of interest is the first.

      +

      The input counter for the first entry on the MRU list, representing the current input packet, is decreased by the interval since the entry was last referenced, but not below zero. If the input counter is greater than the ceiling, the packet is discarded. Otherwise, the counter is increased by the MAH and the packet is processed. The result is, if the client maintains an average headway greater than the ceiling and transmits no more than eight packets in a burst, the input counter will not exceed the ceiling. Packets sent by other implementations that violate this constraint will be dropped and a KoD packet returned, if enabled.

      +

      The reference implementation has a maximum MRU list size of a few hundred entries. The national time servers operated by NIST and USNO have an aggregate packet rate in the thousands of packets per second from many thousands of customers. Under these conditions, the list overflows after only a few seconds of traffic. However, analysis shows that the vast majority of the abusive traffic is due to a tiny minority of the customers, some of which send at over one packet per second. This means that the few seconds retained on the list is sufficient to identify and discard by far the majority of the abusive traffic.

      +

      The Kiss-of-Death Packet

      +

      Ordinarily, packets denied service are simply dropped with no further action except incrementing statistics counters. Sometimes a more proactive response is needed to cause the client to slow down. A special packet has been created for this purpose called the kiss-o'-death (KoD) packet. KoD packets have leap indicator 3, stratum 0 and the reference identifier set to a four-octet ASCII code. At present, only one code RATE is sent by the server if the limited and kod flags of the restrict command are present and either the guard time or MAH time are violated.

      +

      A client receiving a KoD packet is expected to slow down; however, no explicit mechanism is specified in the protocol to do this. In the reference implementation, the server sets the poll field of the KoD packet to the greater of (a) the server MAH and (b) client packet poll field. In response to the KoD packet, the client sets the peer poll interval to the maximum of (a) the client MAH and (b) the server packet poll field. This automatically increases the headway for following client packets.

      +

      In order to make sure the client notices the KoD packet, the server sets the receive and transmit timestamps to the transmit timestamp of the client packet. Thus, even if the client ignores all except the timestamps, it cannot do any useful time computations. KoD packets themselves are rate limited to no more than one packet per guard time, in order to defend against flood attacks.

      +

      References

      +
        +
      1. Mills, D.L., J. Levine, R. Schmidt and D. Plonka. Coping with overload on the Network Time Protocol public servers. Proc. Precision Time and Time Interval (PTTI) Applications and Planning Meeting (Washington DC, December 2004), 5-16. Paper: PDF, Slides:PDF | PowerPoint
      2. +
      +
      + + + diff --git a/contrib/ntp/html/rdebug.html b/contrib/ntp/html/rdebug.html index d49514dfc..f14bf43c9 100644 --- a/contrib/ntp/html/rdebug.html +++ b/contrib/ntp/html/rdebug.html @@ -1,32 +1,29 @@ - - - - - Debugging Reference Clock Drivers - - - - -

      Debugging Reference Clock Drivers

      - giffrom The Wizard of Oz, L. Frank Baum -

      Call the girls and the'll sweep your bugs.

      -

      Last update: 18:49 UTC Thursday, July 28, 2005

      -
      -

      Related Links

      - -

      More Help

      - -
      -

      The ntpq and ntpdc utility programs can be used to debug reference clocks, either on the server itself or from another machine elsewhere in the network. The server is compiled, installed and started using the configuration file described in the ntpd page and its dependencies. If the clock appears in the ntpq utility and pe command, no errors have occurred and the daemon has started, opened the devices specified and waiting for peers and radios to come up. If not, the first thing to look for are error messages on the system log. These are usually due to improper configuration, missing links or multiple instances of the daemon.

      -

      It normally takes a minute or so for evidence to appear that the clock is running and the driver is operating correctly. The first indication is a nonzero value in the reach column in the pe billboard. If nothing appears after a few minutes, the next step is to be sure the RS232 messages, if used, are getting to and from the clock. The most reliable way to do this is with an RS232 tester and to look for data flashes as the driver polls the clock and/or as data arrive from the clock. Our experience is that the overwhelming fraction of problems occurring during installation are due to problems such as miswired connectors or improperly configured device links at this stage.

      -

      If RS232 messages are getting to and from the clock, the variables of interest can be inspected using the ntpq program and various commands described on the documentation page. First, use the pe and as commands to display billboards showing the peer configuration and association IDs for all peers, including the radio clock. The assigned clock address should appear in the pe billboard and the association ID for it at the same relative line position in the as billboard.

      -

      Additional information is available with the rv and clockvar commands, which take as argument the association ID shown in the as billboard. The rv command with no argument shows the system variables, while the rv command with association ID argument shows the peer variables for the clock, as well as other peers of interest. The clockvar command with argument shows the peer variables specific to reference clock peers, including the clock status, device name, last received timecode (if relevant), and various event counters. In addition, a subset of the fudge parameters is included. The poll and error counters in the clockvar billboard are useful debugging aids. The poll counts the poll messages sent to the clock, while the noreply, badformat and baddate count various errors. Check the timecode to be sure it matches what the driver expects. This may require consulting the clock hardware reference manual, which is probably pretty dusty at this stage.

      -

      The ntpdc utility program can be used for detailed inspection of the clock driver status. The most useful are the clockstat and clkbug commands described in the document page. While these commands permit getting quite personal with the particular driver involved, their use is seldom necessary, unless an implementation bug shows up. If all else fails, turn on the debugging trace using two -d flags in the ntpd startup command line. Most drivers will dump status at every received message in this case. While the displayed trace can be intimidating, this provides the most detailed and revealing indicator of how the driver and clock are performing and where bugs might lurk.

      -

      Most drivers write a message to the clockstats file as each timecode or surrogate is received from the radio clock. By convention, this is the last ASCII timecode (or ASCII gloss of a binary-coded one) received from the radio clock. This file is managed by the filegen facility described in the ntpd page and requires specific commands in the configuration file. This forms a highly useful record to discover anomalies during regular operation of the clock. The scripts included in the ./scripts/stats directory can be run from a cron job to collect and summarize these data on a daily or weekly basis. The summary files have proven inspirational to detect infrequent misbehavior due to clock implementation bugs in some radios.

      -
      - - - - \ No newline at end of file + + +Debugging Reference Clock Drivers + + + +

      Debugging Reference Clock Drivers

      +giffrom The Wizard of Oz, L. Frank Baum +

      Call the girls and they'll sweep your bugs.

      +

      Last update: + 10-Mar-2014 05:19 + UTC

      +
      +

      Related Links

      + + +
      +

      The ntpq and ntpdc utility programs can be used to debug reference clocks, either on the server itself or from another machine elsewhere in the network. The server is compiled, installed and started using the configuration file described in the ntpd page and its dependencies. If the clock appears in the ntpq utility and pe command, no errors have occurred and the daemon has started, opened the devices specified and waiting for peers and radios to come up. If not, the first thing to look for are error messages on the system log. These are usually due to improper configuration, missing links or multiple instances of the daemon.

      +

      It normally takes a minute or so for evidence to appear that the clock is running and the driver is operating correctly. The first indication is a nonzero value in the reach column in the pe billboard. If nothing appears after a few minutes, the next step is to be sure the RS232 messages, if used, are getting to and from the clock. The most reliable way to do this is with an RS232 tester and to look for data flashes as the driver polls the clock and/or as data arrive from the clock. Our experience is that the overwhelming fraction of problems occurring during installation are due to problems such as miswired connectors or improperly configured device links at this stage.

      +

      If RS232 messages are getting to and from the clock, the variables of interest can be inspected using the ntpq program and various commands described on the documentation page. First, use the pe and as commands to display billboards showing the peer configuration and association IDs for all peers, including the radio clock. The assigned clock address should appear in the pe billboard and the association ID for it at the same relative line position in the as billboard.

      +

      Additional information is available with the rv and clockvar commands, which take as argument the association ID shown in the as billboard. The rv command with no argument shows the system variables, while the rv command with association ID argument shows the peer variables for the clock, as well as other peers of interest. The clockvar command with argument shows the peer variables specific to reference clock peers, including the clock status, device name, last received timecode (if relevant), and various event counters. In addition, a subset of the fudge parameters is included. The poll and error counters in the clockvar billboard are useful debugging aids. The poll counts the poll messages sent to the clock, while the noreply, badformat and baddate count various errors. Check the timecode to be sure it matches what the driver expects. This may require consulting the clock hardware reference manual, which is probably pretty dusty at this stage.

      +

      The ntpdc utility program can be used for detailed inspection of the clock driver status. The most useful are the clockstat and clkbug commands described in the document page. While these commands permit getting quite personal with the particular driver involved, their use is seldom necessary, unless an implementation bug shows up. If all else fails, turn on the debugging trace using two -d flags in the ntpd startup command line. Most drivers will dump status at every received message in this case. While the displayed trace can be intimidating, this provides the most detailed and revealing indicator of how the driver and clock are performing and where bugs might lurk.

      +

      Most drivers write a message to the clockstats file as each timecode or surrogate is received from the radio clock. By convention, this is the last ASCII timecode (or ASCII gloss of a binary-coded one) received from the radio clock. This file is managed by the filegen facility described in the ntpd page and requires specific commands in the configuration file. This forms a highly useful record to discover anomalies during regular operation of the clock. The scripts included in the ./scripts/stats directory can be run from a cron job to collect and summarize these data on a daily or weekly basis. The summary files have proven inspirational to detect infrequent misbehavior due to clock implementation bugs in some radios.

      +
      + + + diff --git a/contrib/ntp/html/refclock.html b/contrib/ntp/html/refclock.html index 733b7bf56..46d4908fd 100644 --- a/contrib/ntp/html/refclock.html +++ b/contrib/ntp/html/refclock.html @@ -1,103 +1,93 @@ - - - - - - Reference Clock Drivers - - - - -

      Reference Clock Drivers

      - gifMaster Time Facility at the UDel Internet Research Laboratory -

      Last update: 13:06 UTC Wednesday, August 10, 2005

      -
      -

      Related Links

      - -

      Pulse-Per-Second Interfacing Links

      -

      - -

      -

      Audio Driver Links

      -

      - -

      -

      Table of Contents

      - -
      -

      Reference Clock Drivers

      -

      Support for most of the commonly available radio and modem reference clocks is included in the default configuration of the NTP daemon for Unix ntpd. Individual clocks can be activated by configuration file commands, specifically the server and fudge commands described in the ntpd program manual page. The following discussion presents Information on how to select and configure the device drivers in a running Unix system.

      -

      Many radio reference clocks can be set to display local time as adjusted for timezone and daylight saving mode. For use with NTP the clock must be set for Coordinated Universal Time (UTC) only. Ordinarily, these adjustments are performed by the kernel, so the fact that the clock runs on UTC will be transparent to the user.

      -

      Radio and modem clocks by convention have addresses in the form 127.127.t.u, where t is the clock type and u is a unit number in the range 0-3 used to distinguish multiple instances of clocks of the same type. Most of these clocks require support in the form of a serial port or special bus peripheral, but some can work directly from the audio codec found in some workstations. The particular device is normally specified by adding a soft link /dev/deviceu to the particular hardware device involved, where u correspond to the unit number above.

      -

      Most clock drivers communicate with the reference clock using a serial port, usually at 9600 bps. There are several application program interfaces (API) used in the various Unix and NT systems, most of which can be detected at configuration time. Thus, it is important that the NTP daemon and utilities be compiled on the target system or clone. In some cases special features are available, such as timestamping in the kernel or pulse-per-second (PPS) interface. In most cases these features can be detected at configuration time as well; however, the kernel may have to be recompiled in order for them to work.

      -

      The audio drivers are a special case. These include support for the NIST time/frequency stations WWV and WWVH, the Canadian time/frequency station CHU and generic IRIG signals. Currently, support for the Solaris and SunOS audio API is included in the distribution. It is left to the volunteer corps to extend this support to other systems. Further information on hookup, debugging and monitoring is given in the Audio Drivers page.

      -

      The local clock driver is also a special case. A server configured with this driver can operate as a primary server to synchronize other clients when no other external synchronization sources are available. If the server is connected directly or indirectly to the public Internet, there is some danger that it can adversely affect the operation of unrelated clients. Carefully read the Undisciplined Local Clock page and respect the stratum limit.

      -

      The local clock driver also supports an external synchronization source such as a high resolution counter disciplined by a GPS receiver, for example. Further information is on the External Clock Discipline and the Local Clock Driver page.

      -

      Driver Calibration

      -

      Some drivers depending on longwave and shortwave radio services need to know the radio propagation time from the transmitter to the receiver, which can amount to some tens of milliseconds. This must be calculated for each specific receiver location and requires the geographic coordinates of both the transmitter and receiver. The transmitter coordinates for various radio services are given in the Time and Frequency Standard Station Information page. Receiver coordinates can be obtained or estimated from various sources. The actual calculations are beyond the scope of this document.

      -

      When more than one clock driver is supported, it is often the case that each shows small systematic offset differences relative to the rest. To reduce the effects of jitter when switching from one driver to the another, it is useful to calibrate the drivers to a common ensemble offset. The enable calibrate configuration command in the Miscellaneous Options page is useful for this purpose. The calibration function can also be enabled and disabled using the ntpdc program utility.

      -

      Most clock drivers use the time1 value specified in the fudge configuration command to provide the calibration correction when this cannot be provided by the clock or interface. When the calibration function is enabled, the time1 value is automatically adjusted to match the offset of the remote server or local clock driver selected for synchronization. Ordinarily, the NTP selection algorithm chooses the best from among all sources, usually the best radio clock determined on the basis of stratum, synchronization distance and jitter. The calibration function adjusts the time1 values for all clock drivers except this source so that their indicated offsets tend to zero. If the selected source is the kernel PPS discipline, the fudge time1 values for all clock drivers are adjusted.

      -

      The adjustment function is an exponential average designed to improve accuracy, so the function takes some time to converge. The recommended procedure is to enable the function, let it run for an hour or so, then edit the configuration file using the time1 values displayed by the ntpq utility and clockvar command. Finally, disable the calibration function to avoid possible future disruptions due to misbehaving clocks or drivers.

      -

      Performance Enhancements

      -

      In general, performance can be improved, especially when more than one clock driver is supported, to use the prefer peer function described in the Mitigation Rules and the prefer Keyword page. The prefer peer is ordinarily designated the remote peer or local clock driver which provides the best quality time. All other things equal, only the prefer peer source is used to discipline the system clock and jitter-producing "clockhopping" between sources is avoided. This is valuable when more than one clock driver is present and especially valuable when the PPS clock driver (type 22) is used. Support for PPS signals is summarized in the Pulse-per-second (PPS) Signal Interfacing page.

      -

      Where the highest performance is required, generally better than one millisecond, additional hardware and/or software functions may be required. Kernel modifications for precision time are described in the A Kernel Model for Precision Timekeeping page. Special line discipline and streams modules for use in capturing precision timestamps are described in the Line Disciplines and Streams Drivers page.

      -

      Comprehensive List of Clock Drivers

      -

      Following is a list showing the type and title of each driver currently implemented. The compile-time identifier for each is shown in parentheses. Click on a selected type for specific description and configuration documentation, including the clock address, reference ID, driver ID, device name and serial line speed, and features (line disciplines, etc.). For those drivers without specific documentation, please contact the author listed in the Copyright Notice page.

      -
        -
      • Type 1 Undisciplined Local Clock (LOCAL) -
      • Type 2 Trak 8820 GPS Receiver (GPS_TRAK) -
      • Type 3 PSTI/Traconex 1020 WWV/WWVH Receiver (WWV_PST) -
      • Type 4 Spectracom WWVB and GPS Receivers (WWVB_SPEC) -
      • Type 5 TrueTime GPS/GOES/OMEGA Receivers (TRUETIME) -
      • Type 6 IRIG Audio Decoder (IRIG_AUDIO) -
      • Type 7 Radio CHU Audio Demodulator/Decoder (CHU) -
      • Type 8 Generic Reference Driver (PARSE) -
      • Type 9 Magnavox MX4200 GPS Receiver (GPS_MX4200) -
      • Type 10 Austron 2200A/2201A GPS Receivers (GPS_AS2201) -
      • Type 11 Arbiter 1088A/B GPS Receiver (GPS_ARBITER) -
      • Type 12 KSI/Odetics TPRO/S IRIG Interface (IRIG_TPRO) -
      • Type 13 Leitch CSD 5300 Master Clock Controller (ATOM_LEITCH) -
      • Type 14 EES M201 MSF Receiver (MSF_EES) -
      • Type 15 reserved -
      • Type 16 Bancomm GPS/IRIG Receiver (GPS_BANCOMM) -
      • Type 17 Datum Precision Time System (GPS_DATUM) -
      • Type 18 Automated Computer Time Service (ACTS_MODEM) -
      • Type 19 Heath WWV/WWVH Receiver (WWV_HEATH) -
      • Type 20 Generic NMEA GPS Receiver (NMEA) -
      • Type 21 TrueTime GPS-VME Interface (GPS_VME) -
      • Type 22 PPS Clock Discipline (PPS) -
      • Type 23 reserved -
      • Type 24 reserved -
      • Type 25 reserved -
      • Type 26 Hewlett Packard 58503A GPS Receiver (GPS_HP) -
      • Type 27 Arcron MSF Receiver (MSF_ARCRON) -
      • Type 28 Shared Memory Driver (SHM) -
      • Type 29 Trimble Navigation Palisade GPS (GPS_PALISADE) -
      • Type 30 Motorola UT Oncore GPS GPS_ONCORE) -
      • Type 31 Rockwell Jupiter GPS (GPS_JUPITER) -
      • Type 32 Chrono-log K-series WWVB receiver (CHRONOLOG) -
      • Type 33 Dumb Clock (DUMBCLOCK) -
      • Type 34 Ultralink WWVB Receivers (ULINK) -
      • Type 35 Conrad Parallel Port Radio Clock (PCF) -
      • Type 36 Radio WWV/H Audio Demodulator/Decoder (WWV) -
      • Type 37 Forum Graphic GPS Dating station (FG) -
      • Type 38 hopf GPS/DCF77 6021/komp for Serial Line (HOPF_S) -
      • Type 39 hopf GPS/DCF77 6039 for PCI-Bus (HOPF_P) -
      • Type 40 JJY Receivers (JJY) -
      • Type 41 TrueTime 560 IRIG-B Decoder -
      • Type 42 Zyfer GPStarplus Receiver -
      • Type 43 RIPE NCC interface for Trimble Palisade -
      • Type 44 NeoClock4X - DCF77 / TDF serial line -
      -
      - - - - \ No newline at end of file + + + +Reference Clock Support + + + +

      Reference Clock Support

      +gifMaster Time Facility at the UDel Internet Research Laboratory +

      Last update: + 10-Mar-2014 05:20 + UTC

      +
      +

      Related Links

      + + + +

      Table of Contents

      + +
      +

      Introduction

      +

      NTP Version 4 supports almost four dozen satellite, radio and telephone modem reference clocks plus several audio devices for instrumentation signals. A general description of the reference clock support is on this page. Additional information about each reference clock driver can be found via links from this page. Additional information is on the Debugging Hints for Reference Clock Drivers and How To Write a Reference Clock Driver pages. Information on how to support pulse-per-second (PPS) signals produced by some devices is on the Pulse-per-second (PPS) Signal Interfacing page. All reference clock drivers require that the reference clock use only Coordinated Universal Time (UTC). Timezone and standard/daylight adjustments are performed by the operating system kernel.

      +

      A reference clock will generally (though not always) be a radio timecode receiver synchronized to standard time as provided by NIST and USNO in the US, NRC in Canada and their counterparts elsewhere in the world. A device driver specific to each reference clock must be compiled in the distribution; however, most common radio, satellite and telephone modem clocks are included by default and are activated by configuration commands.

      +

      Reference clocks are supported in the same way as ordinary NTP clients and use the same filter, select, cluster and combine algorithms. Drivers have addresses in the form 127.127.t.u, where t is the driver type and u is a unit number in the range 0-3 to distinguish multiple instances of the same driver. The connection to the computer is device dependent, usually a serial port, parallel port or special bus peripheral, but some can work directly from an audio codec or sound card. The particular device is specified by adding a soft link from the name used by the driver to the particular device name.

      +

      The server command is used to configure a reference clock. Only the mode, minpoll, maxpoll, and prefer options are supported for reference clocks, as described on the Reference Clock Commands page. The prefer option is discussed on the Mitigation Rules and the prefer Keyword page. Some of these options have meaning only for selected clock drivers.

      +

      The fudge command can be used to provide additional information for individual drivers and normally follows immediately after the server command. The reference clock stratum is by default 0, so that the server stratum appears to clients as 1. The stratum option can be used to set the stratum to any value in the range 0 through 15. The refid option can be used to change the reference identifier, as might in the case when the driver is disciplined by a pulse-per-second (PPS) source. The device-dependent mode, time and flag options can provide additional driver customization.

      +

      Special Considerations

      +

      The Audio Drivers page describes three software drivers that process audio signals from an audio codec or sound card. One is for the NIST time and frequency stations WWV and WWVH, another for the Canadian time and frequency station CHU. These require an external shortwave radio and antenna. A third is for the generic IRIG signal produced by some timing devices. Currently, these are supported in FreeBSD, Solaris and SunOS and likely in other system as well.

      +

      The Undisciplined Local Clock driver can simulate a reference clock when no external synchronization sources are available. If a server with this driver is connected directly or indirectly to the public Internet, there is some danger that it can destabilize other clients. It is not recommended that the local clock driver be used in this way, as the orphan mode described on the Association Management page provides a generic backup capability.

      +

      The local clock driver can also be used when an external synchronization source such as the IEEE 1588 Precision Time Protocol or NIST Lockclock directly synchronizes the computer time. Further information is on the External Clock Discipline and the Local Clock Driver page.

      +

      Several drivers make use of the pulse-per-second (PPS) signal discipline, which is part of the generic driver interface, so require no specific configuration. For those drivers that do not use this interface, the PPS Clock Discipline driver can be can provide this function. It normally works in conjunction with the reference clock that produces the timecode signal, but can work with another driver or remote server. When PPS kernel features are present, the driver can redirect the PPS signal to the kernel.

      +

      Some drivers depending on longwave or shortwave radio services need to know the radio propagation time from the transmitter to the receiver. This must be calculated for each specific receiver location and requires the geographic coordinates of both the transmitter and receiver. The transmitter coordinates for various radio services are given in the Time and Frequency Standard Station Information page. Receiver coordinates can be obtained locally or from Google Earth. The actual calculations are beyond the scope of this document.

      +

      Depending on interface type, port speed, etc., a reference clock can have a small residual offset relative to another. To reduce the effects of jitter when switching from one driver to the another, it is useful to calibrate the drivers to a common ensemble offset. The enable calibrate configuration command described on the Miscellaneous Options page activates a special feature which automatically calculates a correction factor for each driver relative to an association designated the prefer peer.

      +

      List of Reference Clock Drivers

      +

      Following is a list showing the type and title of each driver currently implemented. The compile-time identifier for each is shown in parentheses. Click on a selected type for specific description and configuration documentation, including the clock address, reference ID, driver ID, device name and serial line speed. For those drivers without specific documentation, please contact the author listed in the Copyright Notice page.

      +
        +
      • Type 1 Undisciplined Local Clock (LOCAL)
      • +
      • Type 2 Deprecated: was Trak 8820 GPS Receiver
      • +
      • Type 3 PSTI/Traconex 1020 WWV/WWVH Receiver (WWV_PST)
      • +
      • Type 4 Spectracom WWVB/GPS Receivers (WWVB_SPEC)
      • +
      • Type 5 TrueTime GPS/GOES/OMEGA Receivers (TRUETIME)
      • +
      • Type 6 IRIG Audio Decoder (IRIG_AUDIO)
      • +
      • Type 7 Radio CHU Audio Demodulator/Decoder (CHU)
      • +
      • Type 8 Generic Reference Driver (PARSE)
      • +
      • Type 9 Magnavox MX4200 GPS Receiver (GPS_MX4200)
      • +
      • Type 10 Austron 2200A/2201A GPS Receivers (GPS_AS2201)
      • +
      • Type 11 Arbiter 1088A/B GPS Receiver (GPS_ARBITER)
      • +
      • Type 12 KSI/Odetics TPRO/S IRIG Interface (IRIG_TPRO)
      • +
      • Type 13 Leitch CSD 5300 Master Clock Controller (ATOM_LEITCH)
      • +
      • Type 14 EES M201 MSF Receiver (MSF_EES)
      • +
      • Type 15 reserved
      • +
      • Type 16 Bancomm GPS/IRIG Receiver (GPS_BANCOMM)
      • +
      • Type 17 Datum Precision Time System (GPS_DATUM)
      • +
      • Type 18 NIST/USNO/PTB Modem Time Services (ACTS_MODEM)
      • +
      • Type 19 Heath WWV/WWVH Receiver (WWV_HEATH)
      • +
      • Type 20 Generic NMEA GPS Receiver (NMEA)
      • +
      • Type 21 TrueTime GPS-VME Interface (GPS_VME)
      • +
      • Type 22 PPS Clock Discipline (PPS)
      • +
      • Type 23 reserved
      • +
      • Type 24 reserved
      • +
      • Type 25 reserved
      • +
      • Type 26 Hewlett Packard 58503A GPS Receiver (GPS_HP)
      • +
      • Type 27 Arcron MSF Receiver (MSF_ARCRON)
      • +
      • Type 28 Shared Memory Driver (SHM)
      • +
      • Type 29 Trimble Navigation Palisade GPS (GPS_PALISADE)
      • +
      • Type 30 Motorola UT Oncore GPS GPS_ONCORE)
      • +
      • Type 31 Rockwell Jupiter GPS (GPS_JUPITER)
      • +
      • Type 32 Chrono-log K-series WWVB receiver (CHRONOLOG)
      • +
      • Type 33 Dumb Clock (DUMBCLOCK)
      • +
      • Type 34 Ultralink WWVB Receivers (ULINK)
      • +
      • Type 35 Conrad Parallel Port Radio Clock (PCF)
      • +
      • Type 36 Radio WWV/H Audio Demodulator/Decoder (WWV)
      • +
      • Type 37 Forum Graphic GPS Dating station (FG)
      • +
      • Type 38 hopf GPS/DCF77 6021/komp for Serial Line (HOPF_S)
      • +
      • Type 39 hopf GPS/DCF77 6039 for PCI-Bus (HOPF_P)
      • +
      • Type 40 JJY Receivers (JJY)
      • +
      • Type 41 TrueTime 560 IRIG-B Decoder
      • +
      • Type 42 Zyfer GPStarplus Receiver
      • +
      • Type 43 RIPE NCC interface for Trimble Palisade
      • +
      • Type 44 NeoClock4X - DCF77 / TDF serial line
      • +
      • Type 45 Spectracom TSYNC PCI
      • +
      • Type 46 GPSD NG client protocol
      • +
      +
      + + + diff --git a/contrib/ntp/html/release.html b/contrib/ntp/html/release.html index b2f4d054e..f940603a0 100644 --- a/contrib/ntp/html/release.html +++ b/contrib/ntp/html/release.html @@ -1,70 +1,72 @@ - - - - - - NTP Version 4 Release Notes - - - - -

      NTP Version 4 Release Notes

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      The rabbit toots to make sure you read this

      -

      Last update: 19:17 UTC Monday, October 10, 2005

      - .
      -
      -

      NTP Version 4 Release Notes

      -

      This release of the NTP Version 4 (NTPv4) daemon for Unix, VMS and Windows incorporates new features and refinements to the NTP Version 3 (NTPv3) algorithms. However, it continues the tradition of retaining backwards compatibility with older versions, including NTPv3 and NTPv2, but not NTPv1. Support for NTPv1 has been discontinued because of certain security vulnerabilities. The NTPv4 version has been under development for quite a while and isn't finished yet. In fact, quite a number of NTPv4 features have already been retrofitted in the older NTPv3, although this version is not actively maintained by the NTPv4 developer corps.

      -

      The code compiles and runs properly in all test host configurations available to the developer corps, including Sun Microsystems, Digital/Compaq, Hewlett Packard, FreeBSD and Linux. Other volunteers have verified it works in IRIX and Windows NT and XP. We invite comments and corrections about the various architectures, operating systems and hardware complement that can't be verified by the developer corps. Of particular interest are other Windows versions, VMS and various reference clock drivers. As always, corrections and bugfixes are warmly received, especially in the form of context diffs sent to bugs@ntp.org.

      -

      This release has been compiled and tested on many systems, including SunOS 4.1.3, Solaris 2.5.1-2.10, Alpha Tru64 4.0-5.1, Ultrix 4.4, Linux 2.4.2, FreeBSD 4.5-5.3 and HP-UX 10.02. It has been compiled and tested by others on Windows NT4, 2000 and XP, but not yet on other Windows versions or for VMS. There are several new features apparently incompatible with Linux systems, including some modes used with the Autokey protocol. The developer corps looks for help elsewhere to resolve these differences.

      -

      This note summarizes the differences between this software release of NTPv4, called ntp-4.x.x, and the previous NTPv3 version, called xntp3-5.x.x. Additional information on protocol compatibility details is on the Protocol Conformance Statement page.

      -

      New Features

      -
        -
      1. Support for the IPv6 addressing family is included in this distribution. If the Basic Socket Interface Extensions for IPv6 (RFC-2553) is detected, support for the IPv6 address family is generated in addition to the default support for the IPv4 address family. Combination IPv6 and IPv4 configurations have been successfully tested in all protocol modes supported by NTP and using both symmetric and public key (Autokey) cryptography. However, users should note that IPv6 support is new and we have not had a lot of experience with it in various operational scenarios and local infrastructure environments. As always, feedback is welcome. -
      2. Most calculations are now done using 64-bit floating double format, rather than 64-bit fixed point format. The motivation for this is to reduce size, improve speed and avoid messy bounds checking. Workstations of today are much faster than when the original NTP version was designed in the early 1980s, and it is rare to find a processor architecture that does not support floating double. The fixed point format is still used with raw timestamps, in order to retain the full precision of about 212 picoseconds. However, the algorithms which process raw timestamps all produce fixed point differences before converting to floating double. The differences are ordinarily quite small so can be expressed without loss of accuracy in this format. - -
      3. The clock discipline algorithm has been redesigned to improve accuracy, reduce the impact of network jitter and allow increased in poll intervals to well over one day with only moderate sacrifice in accuracy. -
      -
        -
          -
        • A new feature called huffpuff maximizes accuracy in cases of highly asymmetric network delays typical of ISDN and modem access circuits. -
        • The NTPv4 design allows clients to increase the poll intervals even when synchronized directly to the server. In NTPv3 the poll interval in such cases was clamped to the minimum, usually 64 s. For those servers with hundreds of clients, the new design can dramatically reduce the network load, especially when large numbers of potential clients, as in national laboratory services. -
        • A scheme designed to reduce "clockhopping" when the choice of servers changes frequently as the result of comparatively insignificant quality changes. -
        -
      -
        -
      1. This release includes support for the nanokernel precision time kernel support, which is now in stock FreeBSD and optional Linux kernels. If a precision time source such as a GPS timing receiver or cesium clock is available, kernel timekeeping can be improved to the order of one microsecond. The older microtime kernel for Digital/Compaq/HP Tru64, Digital Ultrix, as well as Sun Microsystems SunOS and Solaris, continues to be supported. -
      2. This release includes support for Autokey public-key cryptography, which is the preferred scheme for authenticating servers to clients. Autokey Version 2 uses NTP header extension fields and protocols as described on the NTP project page linked from www.ntp.org. This release includes support for additional message digest and digital signature schemes supported by the OpenSSL software library, as well as new identity schemes based on cryptographic challenge/responce algorithms. The new design greatly simplifies key generation and distribution and provides orderly key refreshment. Security procedures and media formats are consistent with industry standard X.509 Version 3 certificates and authority procedures. Specific improvements to the protocol include a reduction in the number of messages required and a method to protect the cookie used in client/server mode against disclosure. Additional information about Autokey cryptography is contained in the Authentication Options page and links from there. See also the new cryptostats monitoring statistics file in the Monitoring Options page. -
      3. This release includes support for a discrete event simulator (DES), which allows the NTP algorithms to be tested in an embedded environment with systematic and pseudorandom network delay and oscillator wander distributions. This has been used to verify correct operation under conditions of extreme error and misconfiguration. See the ntpdsim - Network Time Protocol (NTP) simulator page. -
      4. NTPv4 includes two new association modes which in most applications can avoid per-host configuration altogether. Both of these are based on IP multicast technology and Autokey cryptography. They provide automatic discovery, configuration and authentication of servers and clients without identifying servers or clients in advance. In multicast mode a server sends a message at fixed intervals using specified multicast group addresses, while clients listen on these addresses. -

        Upon receiving the the first message, a client exchanges several messages with the server in order to calibrate the multicast propagation delay between the client and server and run the authentication protocol. In manycast mode a client sends a message to a specified multicast group address and expects one or more servers to reply. Using engineered algorithms, the client selects an appropriate subset of servers from the messages received and continues an ordinary client/server campaign. The manycast scheme can provide somewhat better accuracy than the multicast scheme at the price of additional network overhead. See the Automatic NTP Configuration Options page for further information.

        -
      5. This release includes support for the orphan mode, which replaces the local clock driver for most configurations. The local clock driver provides a synchronization source for networks not connected to the public Internet or reference clock driver. However, it does not opperate with multiple sources nor multiple failures. The orphan mode provides an automatic, subnet-wide synchronization feature with multiple sources. It can be used in isolated networks or in Internet subnets where the servers or Internet connection have failed. See the Automatic NTP Configuration Options page for further information.
      6. This release includes support for preemptable servers, which are provisionally mobilized in manycast mode or by participants in the pool scheme. Manycast mode is described in these notes. In the pool scheme multiple client associations are mobilized for a designated DNS name such as pool.ntp.org. The DNS resolver randomizes replies over a set of volunteer service providers. The NTP mitigation algorithms select the best three from among the set and demobilizes the excess. See the Automatic NTP Configuration Options page for further information.
      7. There are two burst mode features available where special conditions apply. One of these is enabled by the iburst keyword in the server configuration command. It is intended for cases where it is important to set the clock quickly when an association is first mobilized. The other is enabled by the burst keyword in the server configuration command. It is intended for cases where the network attachment requires an initial calling or training procedure. See the Association Management page for further information. -
      8. The reference clock driver interface is smaller, more rational and more accurate. Support for pulse-per-second (PPS) signals has been extended to all drivers as an intrinsic function. Most of the drivers in NTPv3 have been converted to the NTPv4 interface and continue to operate as before. New drivers have been added for several GPS receivers now on the market for a total of 44 drivers. Audio drivers for the Canadian standard time and frequency station CHU, the US standard time and frequency stations WWV/H and for IRIG signals have been updated and capabilities added to allow direct connection of these signals to a Sun or FreeBSD audio port. See the Reference Clock Audio Drivers page for further information. -
      9. In all except a very few cases, all timing intervals are randomized, so that the tendency for NTPv3 to self-synchronize and bunch messages, especially with a large number of configured associations, is minimized. -
      10. In NTPv3 a large number of weeds and useless code had grown over the years since the original NTPv1 code was implemented almost twenty years ago. Using a powerful weedwacker, much of the shrubbery has been removed, with effect a substantial reduction in size of almost 40 percent. -
      11. The entire distribution has been converted to gnu automake, which should greatly ease the task of porting to new and different programming environments, as well as reduce the incidence of bugs due to improper handling of idiosyncratic kernel functions. Version control is provided by Bitkeeper using an online repository at www.ntp.org. -
      12. Several new options have been added for the ntpd command line. For the inveterate knob twiddlers several of the more important performance variables can be changed to fit actual or perceived special conditions. In particular, the tos command can be used to limit the accepted stratum range, specify minimum dispersion increment and maximum selection theshold, and activate orphan mode. -
      13. The ntpd daemon can be operated in a one-time mode similar to ntpdate, which program is headed for retirement. See the ntpd - Network Time Protocol (NTP) daemon page for the new features. -
      -

      Nasty Surprises

      -

      There are a few things different about this release that have changed since the latest NTP Version 3 release. Following are a few things to worry about:

      -
        -
      1. When both IPv4 and IPv6 address families are in use, the host's resolver library may not choose the intended address family if a server has an IPv4 and IPv6 address associated with the same DNS name. The solution is to use the IPv4 or IPv6 address directly in such cases or use another DNS name that resolves to the intended address family. Older versions of ntpdc will only show the IPv4 associations with the peers and other simular commands. Older versions of ntpq will show 0.0.0.0 for IPv6 associations with the peers and other simular commands. -
      2. There is a minor change to the reference ID field of the NTP packet header when operating with IPv6 associations. In IPv4 associations this field contains the 32-bit IPv4 address of the server, in order to detect and avoid loops. In IPv6 associations this field contains the first 32-bits of a MD5 hash formed from the address (IPv4 or IPv6) each of the configured associations. Normally, this detail would not be of concern; however, the ntptrace program originally depended on that field in order to display a server traceback to the primary reference source. This program has now been replaced by a script that does the same function, but does not depend on the reference ID field. The ntpdc utility now uses a special version number to communicate with the ntpd server. The server uses this version number to select which address family to used in reply packets. The ntpdc program falls back to the older version behavior when communicating with older NTP versions. -
      3. As required by Defense Trade Regulations (DTR), the cryptographic routines supporting the Data Encryption Standard (DES) have been removed from the base distribution of NTPv3. For NTPv4 a new interface has been implemented for the OpenSSL cryptographic library, which is widely available on the web at www.openssl.org. This library replaces the library formerly available from RSA Laboratories. Besides being somewhat faster and more widely available, the OpenSSL library supports many additional cryptographic algorithms, which are now selectable at run time. Directions for using OpenSSL are in the Building and Installing the Distribution page. -
      4. As the result of the above, the ./authstuff directory, intended as a development and testing aid for porting cryptographic routines to exotic architectures, has been removed. Testing and conformance validation tools are in the OpenSSL software distrbution. -
      5. The NTPv4 enable and disable commands have a few changes in the arguments. See the ntpd Miscellaneous Options page for details. Note that the authenticate command has been removed. -
      6. To help reduce the level of spurious network traffic due to obsolete configuration files, a special control message called the kiss-o'-death packet has been implemented. If enabled and a packet is denied service or exceeds the client limits, a compliant server will send this message to the client. A compliant client will cease further transmission and send a message to the system log. See the Authentication Options page for further information. -
      7. The tty_clk and ppsclock pulse-per-second (PPS) line discipline/streams modules are no longer supported. The PPS function is now handled by the PPS Clock Discipline driver, which uses the new PPSAPI application program interface adopted by the IETF. Note that the pps configuration file command has been obsoleted by the driver. See the Pulse-per-second (PPS) Signal Interfacing page for further information. -
      8. Support for the NTPv1 symmetric mode has been discontinued, since it hasn't worked for years. Support continues for the NTPv1 client mode, which is used in some SNTP clients. -
      9. The precision time support in stock Solaris 2.6 has bugs that were fixed in 2.7. A patch is available that fixes the 2.6 bugs. The 2.6 PPS kernel discipline has been disabled by default. For testing, the kernel can be enabled using the enable kernel command either in the configuration file or via ntpdc. -
      10. The HTML documentation has been partially updated. However, most of the NTPv3 documentation continues to apply to NTPv4. Until a comprehensive update happens, what you see is what you get. We are always happy to accept comments, corrections and bug reports. However, we are most thrilled upon receipt of patches to fix the dang bugs. Please send bug reports to bugs@ntp.org, not the individual members on the team. -
      -
      - - - - \ No newline at end of file + + + +NTP Version 4 Release Notes + + + +

      NTP Version 4 Release Notes

      +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

      The rabbit toots to make sure you read this.

      +

      Last update: + 3-Oct-2011 21:51 + UTC

      +
      +

      Related Links

      + +

      Table of Contents

      + +
      +

      NTP has been under development for almost 30 years, but the paint ain't dry even now. This release of the NTP Version 4 (NTPv4) distribution for Unix, VMS and Windows incorporates new features and refinements, but retaining backwards compatibility with older versions, including NTPv3 and NTPv2, but not NTPv1. Support for NTPv1 has been discontinued because of certain security vulnerabilities.

      +

      New Features

      +
        +
      • The behavior of the daemon at startup has been considerably improved. The time to measure the frequency and correct an initial offset error when started for the first time is now no more than ten minutes. Upon restart, it takes no more than five minutes to reduce the initial offset to less than one millisecond without adversely affecting the frequency. This avoids a subsequent frequency correction which could take up to several hours.
      • +
      • A new feature called interleaved mode can be used in NTP + symmetric and broadcast modes. It is designed to improve accuracy + by minimizing errors due to queuing and transmission delays. It is described on the NTP + Interleaved Modes page.
      • +
      • The huff-n'-puff filter is designed to avoid large errors with DSL circuits and highly asymmetrical traffic, as when downloading large files. Details are on the The Huff-n'-Puff Filter page.
      • +
      • A new feature called orphan mode provides an automatic, subnet-wide synchronization feature with multiple sources. It provides reliable backup in isolated networks or in pr when Internet sources have become unavailable. See the Orphan Mode page for further information.
      • +
      • This release includes comprehensive packet rate management tools to help reduce the level of spurious network traffic and protect the busiest servers from overload. There is support for the optional Kiss-o'-Death (KoD) packet intended to slow down an abusive client. See the Rate Management and the Kiss-o'-Death Packet page for further information.
      • +
      • There are two new burst mode features available where special conditions apply. One of these is enabled by the iburst keyword in the server configuration command. It is intended for cases where it is important to set the clock quickly when an association is first mobilized. The other is enabled by the burst keyword in the server configuration command. It is intended for cases where the network attachment requires an initial calling or training procedure. See the Association Management page for further information.
      • +
      • The OpenSSL cryptographic library has replaced the library formerly available from RSA Laboratories. All cryptographic routines except a version of the MD5 message digest algorithm have been removed from the base distribution. All 128-bit and 160-bit message digests algorithms are now supported for both symmetric key and public key cryptosystems. See the Authentication Support page for further information and the Authentication Options page for a list of supported digest algorithms.
      • +
      • This release includes support for Autokey public-key cryptography for authenticating public servers to clients, as described in RFC 5906. This support requires the --enable-autokey option when building the distribution, which is the default is OpenSSL is available. The deployment of Autokey subnets is now considerably simpler than in earlier versions. A subnet naming scheme is now available to filter manycast and pool configurations. Additional information about Autokey is on the Autokey Public Key Authentication page and links from there.
      • +
      • The NTP descrete even simulator has been substantially upgraded, now including scenarios with multiple servers and time-sensitive scripts. This allows the NTP algorithms to be tested in an embedded environment with systematic and pseudo-random network delay and oscillator wander distributions. This has been used to verify correct operation under conditions of extreme error and misconfiguration. See the ntpdsim - Network Time Protocol (NTP) simulator page. A technical description and performance analysis is given in the white papers at the NTP Project Page.
      • +
      • NTPv4 includes three new server discovery schemes, which in most applications can avoid per-host configuration altogether. Two of these are based on IP multicast technology, while the remaining one is based on crafted DNS lookups. See the Automatic NTP Configuration Schemes page for further information.
      • +
      • The status display and event report monitoring functions have been considerably expanded, including new statistics files and event reporting to files and the system log. See the Event Messages and Status Words page for further information.
      • +
      • Several new options have been added for the ntpd command line. For the inveterate knob twiddlers several of the more important performance variables can be changed to fit actual or perceived special conditions. In particular, the tinker and tos commands can be used to adjust thresholds, throw switches and change limits.
      • +
      • The ntpd daemon can be operated in a one-time mode similar to ntpdate, which program is headed for retirement. See the ntpd - Network Time Protocol (NTP) daemon page for the new features.
      • +
      • A number of white papers have been added to the library on the NTP Reseatch Project Page, including:
      • +
      + +

      Changes and Upgrades Since the NTPv3 Version (xntp3-5)

      +

      This section summarizes general changes since the publication of RFC-1305. Specific changes made during the code upgrade of 2007-2008 are summarized in Historical Notes.

      +
        +
      • If the Basic Socket Interface Extensions for IPv6 (RFC-2553) is detected, support for the IPv6 address family is supported in addition to the default support for the IPv4 address family. In contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace.
      • +
      • Many changes have been made in the NTP algorithms to improve performance and reliability A clock state machine has been incorporated to improve behavior under transient conditions. The clock discipline algorithm has been redesigned to improve accuracy, reduce the impact of network disruptions and allow increased poll intervals to 36 hours with only moderate sacrifice in accuracy. The clock select, cluster and combine algorithms have been overhauled as the result of a thorough statistical analysis.
      • +
      • In all except a very few cases, all timing intervals are randomized, so that the tendency for NTPv3 to self-synchronize and bunch messages, especially with a large number of configured associations, is minimized.
      • +
      • Support for the precision time kernel modifications, which are now in stock FreeBSD and optional in Linux kernels, is included. With this support the system clock can be disciplined to the order of one nanosecond. The older microtime kernel modifications in Digital/Compaq/HP Tru64, Digital Ultrix and Sun Microsystems SunOS and Solaris, continue to be supported. In either case the support eliminates sawtooth error, which can be in the hundreds of microseconds. Further information is on the Kernel Model for Precision Timekeeping page.
      • +
      • New reference clock drivers have been added for several GPS receivers now on the market for a total of 44 drivers. The reference clock driver interface is smaller, more rational, more flexible and more accurate. Most of the drivers in NTPv3 have been converted to the NTPv4 interface and continue to operate as before. A summary of the supported drivers is on the Reference Clock Support page. Audio drivers for the Canadian standard time and frequency station CHU, the US standard time and frequency stations WWV/H and for IRIG signals have been updated and capabilities added to allow direct connection of these signals to an audio port. See the Reference Clock Audio Drivers page for further information.
      • +
      • Support for pulse-per-second (PPS) signals has been extended to all drivers as an intrinsic function. Further information is on the Pulse-Per-Second (PPS) Signal Interfacing page. Typical performance with the PPS interface and a fast machine are in the low microseconds.
      • +
      • Several small changes have been made to make administration and maintenance more convenience. The entire distribution has been converted to gnu automake, which greatly ease the task of porting to new and different programming environments, as well as reduce the incidence of bugs due to improper handling of idiosyncratic kernel functions. Version control is provided by Bitkeeper using an online repository at www.ntp.org. Trouble ticket reporting is provided using Bugzilla. If ntpd, is configured with NetInfo support, it will attempt to read its configuration from the NetInfo service if the default ntp.conf file cannot be read and no file is specified by the -c option. When ntpd starts it looks at the value of umask, and if zero ntpd will set the umask to 022.
      • +
      +

      Nasty Surprises

      +

      There are a few things different about this release that have changed since the latest NTP Version 3 release. Following are a few things to worry about:

      +
        +
      • Some configuration commands have been removed, others added and some changed in minor ways. See the Commands and Options collection on the Site Map page.
      • +
      • When both IPv4 and IPv6 address families are in use, the host's resolver library may not choose the intended address family if a server has an IPv4 and IPv6 address associated with the same DNS name. The solution is to use the IPv4 or IPv6 address directly in such cases or use another DNS name that resolves to the intended address family. Older versions of ntpdc will show only the IPv4 associations with the peers and some other commands. Older versions of ntpq will show 0.0.0.0 for IPv6 associations with the peers and some other commands.
      • +
      • There is a minor change to the reference ID field of the NTP packet header when operating with IPv6 associations. In IPv4 associations this field contains the 32-bit IPv4 address of the server, in order to detect and avoid loops. In IPv6 associations this field contains the first 32-bits of a MD5 hash formed from the IPv6 address. All programs in the distribution have been modified to work with both address families.
      • +
      • The tty_clk and ppsclock pulse-per-second (PPS) line discipline/streams modules are no longer supported. The PPS function is now handled by the PPS Clock Discipline driver, which uses the new PPSAPI application program interface adopted by the IETF. Note that the pps configuration file command has been obsoleted by the driver. See the Pulse-Per-Second (PPS) Signal Interfacing page for further information.
      • +
      • Support for the NTPv1 symmetric mode has been discontinued, since it hasn't worked for years. Support continues for the NTPv1 client mode, which is used by some SNTP clients.
      • +
      • The authstuff directory, intended as a development and testing aid for porting cryptographic routines to exotic architectures, has been removed. Testing and conformance validation tools are available in the OpenSSL software distribution.
      • +
      +
      + + + diff --git a/contrib/ntp/html/scripts/accopt.txt b/contrib/ntp/html/scripts/accopt.txt new file mode 100644 index 000000000..d8f02800b --- /dev/null +++ b/contrib/ntp/html/scripts/accopt.txt @@ -0,0 +1,5 @@ +document.write("

      Access Control Commands and Options

      ") diff --git a/contrib/ntp/html/scripts/audio.txt b/contrib/ntp/html/scripts/audio.txt new file mode 100644 index 000000000..5fb11fc97 --- /dev/null +++ b/contrib/ntp/html/scripts/audio.txt @@ -0,0 +1,7 @@ +document.write("

      Reference Clock Audio Drivers

      ") diff --git a/contrib/ntp/html/scripts/authopt.txt b/contrib/ntp/html/scripts/authopt.txt new file mode 100644 index 000000000..5064b1814 --- /dev/null +++ b/contrib/ntp/html/scripts/authopt.txt @@ -0,0 +1,12 @@ +document.write("

      Authentication Commands and Options

      ") diff --git a/contrib/ntp/html/scripts/clockopt.txt b/contrib/ntp/html/scripts/clockopt.txt new file mode 100644 index 000000000..1c76a1ce4 --- /dev/null +++ b/contrib/ntp/html/scripts/clockopt.txt @@ -0,0 +1,5 @@ +document.write("

      Reference Clock Commands and Options

      ") diff --git a/contrib/ntp/html/scripts/command.txt b/contrib/ntp/html/scripts/command.txt new file mode 100644 index 000000000..ec6169e96 --- /dev/null +++ b/contrib/ntp/html/scripts/command.txt @@ -0,0 +1,7 @@ +document.write("\ +\ +\ +\ +
      gif\ +Home Pagegif\ +Contacts
      ") diff --git a/contrib/ntp/html/scripts/config.txt b/contrib/ntp/html/scripts/config.txt new file mode 100644 index 000000000..84c226af0 --- /dev/null +++ b/contrib/ntp/html/scripts/config.txt @@ -0,0 +1,5 @@ +document.write("

      Client and Server Configuration

      ") diff --git a/contrib/ntp/html/scripts/confopt.txt b/contrib/ntp/html/scripts/confopt.txt new file mode 100644 index 000000000..c524f5998 --- /dev/null +++ b/contrib/ntp/html/scripts/confopt.txt @@ -0,0 +1,12 @@ +document.write("

      Server Commands and Options

      ") diff --git a/contrib/ntp/html/scripts/external.txt b/contrib/ntp/html/scripts/external.txt new file mode 100644 index 000000000..5e7070525 --- /dev/null +++ b/contrib/ntp/html/scripts/external.txt @@ -0,0 +1,19 @@ +document.write("

      External Links

      ") diff --git a/contrib/ntp/html/scripts/footer.txt b/contrib/ntp/html/scripts/footer.txt index 7fc6dd87a..48830e656 100644 --- a/contrib/ntp/html/scripts/footer.txt +++ b/contrib/ntp/html/scripts/footer.txt @@ -1,7 +1,9 @@ document.write("\ \ -\ -\ -
      gif\ +\ Home Pagegif\ -Contacts
      ") \ No newline at end of file +
      \ +Site Map\ +Contacts
      ") diff --git a/contrib/ntp/html/scripts/hand.txt b/contrib/ntp/html/scripts/hand.txt new file mode 100644 index 000000000..95da082b1 --- /dev/null +++ b/contrib/ntp/html/scripts/hand.txt @@ -0,0 +1,11 @@ +document.write("

      Handbook Pages

      ") diff --git a/contrib/ntp/html/scripts/install.txt b/contrib/ntp/html/scripts/install.txt new file mode 100644 index 000000000..e8185f245 --- /dev/null +++ b/contrib/ntp/html/scripts/install.txt @@ -0,0 +1,10 @@ +document.write("

      Build and Install

      ") diff --git a/contrib/ntp/html/scripts/links10.txt b/contrib/ntp/html/scripts/links10.txt deleted file mode 100644 index 880e379fd..000000000 --- a/contrib/ntp/html/scripts/links10.txt +++ /dev/null @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/scripts/links11.txt b/contrib/ntp/html/scripts/links11.txt deleted file mode 100644 index 59e701746..000000000 --- a/contrib/ntp/html/scripts/links11.txt +++ /dev/null @@ -1,7 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/scripts/links12.txt b/contrib/ntp/html/scripts/links12.txt deleted file mode 100644 index 7ca9249b9..000000000 --- a/contrib/ntp/html/scripts/links12.txt +++ /dev/null @@ -1,5 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/scripts/links7.txt b/contrib/ntp/html/scripts/links7.txt deleted file mode 100644 index 0d33473cc..000000000 --- a/contrib/ntp/html/scripts/links7.txt +++ /dev/null @@ -1,6 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/scripts/links8.txt b/contrib/ntp/html/scripts/links8.txt deleted file mode 100644 index 135310c8c..000000000 --- a/contrib/ntp/html/scripts/links8.txt +++ /dev/null @@ -1,6 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/scripts/links9.txt b/contrib/ntp/html/scripts/links9.txt deleted file mode 100644 index 6ea32f06d..000000000 --- a/contrib/ntp/html/scripts/links9.txt +++ /dev/null @@ -1,8 +0,0 @@ -document.write("") \ No newline at end of file diff --git a/contrib/ntp/html/scripts/manual.txt b/contrib/ntp/html/scripts/manual.txt new file mode 100644 index 000000000..bad1f93e8 --- /dev/null +++ b/contrib/ntp/html/scripts/manual.txt @@ -0,0 +1,13 @@ +document.write("

      Program Manual Pages

      ") diff --git a/contrib/ntp/html/scripts/misc.txt b/contrib/ntp/html/scripts/misc.txt new file mode 100644 index 000000000..2dfb2896a --- /dev/null +++ b/contrib/ntp/html/scripts/misc.txt @@ -0,0 +1,9 @@ +document.write("

      Miscellaneous Pages

      ") diff --git a/contrib/ntp/html/scripts/miscopt.txt b/contrib/ntp/html/scripts/miscopt.txt new file mode 100644 index 000000000..64987c8b1 --- /dev/null +++ b/contrib/ntp/html/scripts/miscopt.txt @@ -0,0 +1,21 @@ +document.write("

      Miscellaneous Commands and Options

      ") diff --git a/contrib/ntp/html/scripts/monopt.txt b/contrib/ntp/html/scripts/monopt.txt new file mode 100644 index 000000000..b7d5a2f32 --- /dev/null +++ b/contrib/ntp/html/scripts/monopt.txt @@ -0,0 +1,6 @@ +document.write("

      Monitoring Commands and Options

      ") diff --git a/contrib/ntp/html/scripts/refclock.txt b/contrib/ntp/html/scripts/refclock.txt new file mode 100644 index 000000000..b32e5fa34 --- /dev/null +++ b/contrib/ntp/html/scripts/refclock.txt @@ -0,0 +1,7 @@ +document.write("

      Reference Clock Support

      ") diff --git a/contrib/ntp/html/scripts/special.txt b/contrib/ntp/html/scripts/special.txt new file mode 100644 index 000000000..b62d15e50 --- /dev/null +++ b/contrib/ntp/html/scripts/special.txt @@ -0,0 +1,17 @@ +document.write("

      Special Topics

      ") diff --git a/contrib/ntp/html/scripts/style.css b/contrib/ntp/html/scripts/style.css index 7d7b27640..7a0cc5471 100644 --- a/contrib/ntp/html/scripts/style.css +++ b/contrib/ntp/html/scripts/style.css @@ -61,4 +61,4 @@ th {background: #FFFFCC; th.caption {background: #EEEEEE; color: #006600; - text-align: center;} \ No newline at end of file + text-align: center;} diff --git a/contrib/ntp/html/select.html b/contrib/ntp/html/select.html new file mode 100644 index 000000000..6cfa186d0 --- /dev/null +++ b/contrib/ntp/html/select.html @@ -0,0 +1,41 @@ + + + + + +Clock Select Algorithm + + + + +

      Clock Select Algorithm

      +

      Last update: + 10-Mar-2014 05:22 + UTC

      +
      +

      The clock select algorithm determines from a set of sources , which are correct (truechimers) and which are not (falsetickers) according to a set of formal correctness assertions. The principles are based on the observation that the maximum error in determining the offset of a candidate cannot exceed one-half the roundtrip delay to the primary reference clock at the time of measurement. This must be increased by the maximum error that can accumulate since then. The selection metric, called the root distance,, is one-half the roundtrip root delay plus the root dispersion plus minor error contributions not considered here.

      +

      First, a number of sanity checks is performed to sift the selectable candidate from among the source population. The sanity checks are sumarized as follows:.

      +
        +
      1. A stratum error occurs if (1) the source had never been synchronized or (2) the stratum of the source is below the floor option or not below the ceiling option of the tos command. The default values for these options are 0 and 15, respectively. Note that 15 is a valid stratum, but a server operating at that stratum cannot synchronize clients.
      2. +
      3. A distance error occurs for a source if the root distance (also known ad synchronization distance) of the source is not below the distance threshold maxdist option of the tos command. The default value for this option is 1.5 s for networks including only the Earth, but this should be increased to 2.5 s for networks including the Moon.
      4. +
      5. A loop error occurs if the source is synchronized to the client. This can occur if two peers are configured with each other in symmetric modes.
      6. +
      7. An unreachable error occurs if the source is unreachable or if the server or peer command for the source includes the noselect option.
      8. +
      +Sources showing one or more of these errors are considered nonselectable; only the selectable candidates are considered in the following algorithm. Given the measured offset θ0 and root distance λ, this defines a correctness interval0 − λ, θ0 + λ] of points where the true value of θ lies somewhere on the interval. The given problem is to determine from a set of correctness intervals, which represent truechimers and which represent falsetickers. The principles must be given a precise definition. The intersection interval is the smallest interval containing points from the largest number of correctness intervals. An algorithm that finds the intersection interval was devised by Keith Marzullo in his doctoral dissertation. It was first implemented in the Digital Time Synchronization Service (DTSS) for the VMS operating system for the VAX. +

      While the NTP algorithm is based on DTSS, it remains to establish which point in the correctness interval represents the best estimate of the offset for each candidate. The best point is at the midpoint θ0 of the correctness interval; however, the midpoint might not be within the intersection interval. A candidate with a correctness interval that contains points in the intersection interval is a truechimer and the best offset estimate is the midpoint of its correctness interval. A candidate with a correctness interval that contains no points in the intersection interval is a falseticker.

      +
      gif +

      Figure 1. Intersection Interval

      +
      +

      Figure 1 shows correctness intervals for each of four candidates A, B, C and D. We need to find the maximum number of candidates that contain points in common. The result is the interval labeled DTSS. In the figure there are three truechimers A, B and C, and one falseticker D. In DTSS any point in the intersection interval can represent the true time; however, as shown below, this may throw away valuable statistical information. In any case, the clock is considered correct if the number of truechimers found in this way are greater than half the total number of candidates.

      +

      The question remains, which is the best point to represent the true time of each correctness interval? Fortunately, we already have the maximum likelihood estimate at the midpoint of each correctness interval. But, while the midpoint of candidate C is outside the intersection interval, its correctness interval contains points in common with the intersection interval, so the candidate is a truechimer and the midpoint is chosen to represent its time.

      +

      The DTSS correctness assertions do not consider how best to represent the truechimer time. To support the midpoint choice, consider the selection algorithm as a method to reject correctness intervals that cannot contribute to the final outcome; that is, they are falsetickers. The remaining correctness intervals can contribute to the final outcome; that is, they are truechimers. Samples in the intersection interval are usually of very low probability and thus poor estimates for truechimer time. On the other hand, the midpoint sample produced by the clock filter algorithm is the maximum likelihood estimate and thus best represents the truechimer time.

      +
      gif +

      Figure 2. Clock Select Algorithm

      +
      +

      The algorithm operates as shown in Figure 2. Let m be the number of candidates and f the number of falsetickers, initially zero. Move a pointer from the leftmost endpoint towards the rightmost endpoint in Figure 1 and count the number of candidates, stopping when that number reaches mf; this is the left endpoint of the intersection interval. Then, do the same, but moving from the rightmost endpoint towards the leftmost endpoint; this is the right endpoint of the intersection interval. If the left endpoint is less than the right endpoint, the intersection interval has been found. Otherwise, increase f by 1. If f is less than n / 2, try again; otherwise, the algorithm fails and no truechimers could be found.

      +

      The clock select algorithm again scans the correctness intervals. If the right endpoint of the correctness interval for a candidate is greater than the left endpoint of the intersection interval, or if the left endpoint of the correctness interval is less than the right endpoint of the intersection interval, the candidate is a truechimer; otherwise, it is a falseticker.

      +

      In practice, with fast LANs and modern computers, the correctness interval can be quite small, especially when the candidates are multiple reference clocks. In such cases the intersection interval might be empty, due to insignificant differences in the reference clock offsets. To avoid this, the size of the correctness interval is padded to the value of mindist, with default 1 ms. This value can be changed using the mindist option of the tos command.

      +
      + + + diff --git a/contrib/ntp/html/sitemap.html b/contrib/ntp/html/sitemap.html new file mode 100644 index 000000000..c4b9110a1 --- /dev/null +++ b/contrib/ntp/html/sitemap.html @@ -0,0 +1,33 @@ + + + + + +Site Map + + + +

      Site Map

      +giffrom Alice in Wonderland, Lewis Carroll +

      Welcome to the tea party.

      +

      Last update: + 11-Sep-2010 05:55 + UTC
      +

      +

      Related Links

      + + + + + + + + + + +
      +
      gif
      +
      + + + diff --git a/contrib/ntp/html/sntp.html b/contrib/ntp/html/sntp.html index 839271e5b..84c6f29d5 100644 --- a/contrib/ntp/html/sntp.html +++ b/contrib/ntp/html/sntp.html @@ -1,57 +1,79 @@ - - - - - Simple Network Time Protocol (SNTP) Client - - - - -

      Simple Network Time Protocol (SNTP) Client

      - giffrom Alice's Adventures in Wonderland, Lewis Carroll -

      S is for snakeoil

      -

      Last update: 18:50 UTC Thursday, July 28, 2005

      -
      -
      -

      Synopsis

      - sntp [{-h --help -?}][{ -v -V -W }][{-r -a}][-P prompt][-e minerr][-E maxerr][-c count][-d delay][address(es)] -

      Description

      -

      This program is a Simple Network Time Protocol (SNTP) client that can be used to query a Network TIme Protocol (NTP) server and display the time offset of the system clock relative to the server clock. Run as root it can correct the system clock to this offset as well. It can be run as an interactive command or from a script by a cron job. The program implements the SNTP protocol defined in RFC-2030, which is a subset of the NTP protocol defined in RFC-1305, but does not provide the sanity checks, access controls, security functions and mitigation algorithms as in the full NTP implementation.

      -

      While this program can do other things, including operation as a primitive server, some of these things are truly dangerous in a ubiquitous public time server network. A full disclosure is in the man page in the ./sntp directory, but be truly advised RFC-2030 specifically forbids a SNTP client to operate as a server for other NTP or SNTP clients. If such operation is contemplated, do not allow access by clients on the public Internet.

      -

      By default, sntp writes the local date and time (i.e., not UTC) to the standard output in the format

      -

      1996 Oct 15 20:17:25.123 + 4.567 +/- 0.089 secs,

      -

      where the + 4.567 +/- 0.089 secs indicates the time offset and error bound of the system clock relative to the server clock.

      -

      If a NTP server address is explicitly specified, the program sends a single message to the server and waits up to delay seconds for a unicast server message. Otherwise, it sends no message and waits up to delay seconds for a broadcast server message.

      -

      Options

      -

      sntp recognizes the following options:

      -
      -
      -h, --help -
      displays usage information. -
      -v -
      writes diagnostic messages and a limited amount of tracing to standard error. The -v, -V and -W give increasing levels of detail. -
      -r -
      steps the system clock to the correct time by the Unix settimeofday system call. Requires root priviledge. -
      -a -
      slews the system clock to the correct time by the Unix adjtime system call. Requires root priviledge. -
      -e minerr -
      sets the minimum offset to minerr seconds. Measured offsets less than this are ignored. Acceptable values are from 0.001 to 1 with default 0.1 if unicast mode and 0.5 for broadcast mode. -
      -E maxerr -
      sets the maximum offset to maxerr seconds. Measured offsets greater than this are ignored. Acceptable values are from 1 to 60 with default 5. -
      -P prompt -
      sets the maximum automatic offset to maxerr seconds. Acceptable values are from 1 to 3600 or no, with default 30. If the program is being run interactively, measured offsets greater than this will prompt the user for confirmation. Specifying no will disable this and the correction will be made regardless. -
      -c count -
      sets the maximum number of NTP packets required to count. Acceptable values are from 1 to 25 in unicast mode and 5 to 25 in broadcast mode. The default is 5 in either mode. -
      -d delay -
      sets the maximum waiting time in broadcast mode to delay seconds. Acceptable values are from 1 to 3600, with default 15 in unicast mode and 300 in broadcast mode. -
      -

      Return Value

      -

      The program returns an exit status of zero for success and non-zero otherwise.

      -

      Author

      -

      sntp was developed by N.M. Maclaren of the University of Cambridge Computing Service.

      -
      - - - - \ No newline at end of file + + +sntp - Simple Network Time Protocol (SNTP) Client + + + + +

      sntp - Simple Network Time Protocol (SNTP) Client

      +giffrom Alice's Adventures in Wonderland, Lewis Carroll +

      S is for snakeoil.

      +

      Last update: + 1-Apr-2015 11:05 + UTC

      +
      +
      +

      Synopsis

      +sntp [{--help -?}][{-4 -6}][-a keynum][-b bcaddress][-B bctimeout][-c][-d][-D debug-level][-g delay][-K kodfile][-k keyfile][-l logfile][-M steplimit][-o ntpver][-r][-S][-s][-u uctimeout][--wait][--version][address(es)] +

      Description

      +

      This program is a Simple Network Time Protocol (SNTP) client that can be used to query a Network Time Protocol (NTP) server and display the time offset of the system clock relative to the server clock. Run as root it can correct the system clock to this offset as well. It can be run as an interactive command or from a script by a cron job. The program implements the SNTP client protocol defined in RFC 5905, including the full on-wire protocol but does not provide the sanity checks, access controls, security functions and mitigation algorithms as in the full NTP version 4 specification, also defined in RFC 5905.

      +

      By default, sntp writes the local date and time (i.e., not UTC) to the standard output in the format

      +

      2011-08-04 00:40:36.642222 (+0000) +0.006611 +/- 0.041061 psp-os1 149.20.68.26 s3 no-leap

      +

      where the +0.006611 +/- 0.041061 indicates the time offset and error bound of the system clock relative to the server clock, in seconds. The hostname and/or the IP is displayed, as is the stratum of the server. Finally, the leap indicator status is displayed.

      +

      If -b bcaddress is not specified, the program sends a single message to each address and waits up to uctimeout (default 5) seconds for a unicast server response. Otherwise, it sends no message and waits up to bctimeout (default 68) seconds for a broadcast NTP message.

      +

      Options

      +

      sntp recognizes the following options:

      +
      +
      -?, --help
      +
      displays usage information. The short form typically requires shell quoting, such as -\?, otherwise ? is consumed by the shell.
      +
      -4, --ipv4
      +
      When resolving hostnames to IP addresses, use IPv4 addresses only.
      +
      -6, --ipv6
      +
      When resolving hostnames to IP addresses, use IPv6 addresses only.
      +
      -a keynum, --authentication keynum
      +
      Enable authentication with the key ID keynum. keynum is a number specified in the keyfile along with an authentication secret (password or digest). See the -k, --keyfile option for more details.
      +
      -b bcaddress, --broadcast bcaddress
      +
      Listen for NTP packets sent to the broadcast or multicast address bcaddress, which can be a DNS name or IP address. The default maximum time to listen for broadcasts/multicasts, 68 seconds, can be modified with the -B, --bctimeout option.
      +
      -B bctimeout, --bctimeout bctimeout
      +
      Wait bctimeout seconds for broadcast or multicast NTP message before terminating. The default is 68 seconds, chosen because ntpd typically transmits broadcasts/multicasts every 64 seconds. Note that the short option is -B, an uppercase letter B.
      +
      -c, --concurrent
      +
      Concurrently query all addresses returned for hostname. Requests from an NTP client to a single server should never be sent more often than once every two seconds. By default, all addresses resolved from a single hostname are assumed to be for a single instance of ntpd, and therefore sntp will send queries to these addresses one after another, waiting two seconds between queries. This option indicates multiple addresses returned for a hostname are on different machines, so sntp can send concurrent queries. This is appropriate when using *.pool.ntp.org, for example.
      +
      -d, --debug-level
      +
      Increase debug verbosity level by one. May be specified multiple times. See also the -D, --set-debug-level option.
      +
      -D debug-level, --set-debug-level debug-level
      +
      Set the debug verbosity level to debug-level. The default level is zero. Note that the short option is -D, an uppercase letter D. See also the -d, --debug-level option.
      +
      -g delay, --gap delay
      +
      Specify the delay in milliseconds between outgoing queries, defaulting to 50. sntp sends queries to all provided hostnames/addresses in short succession, and by default terminates once the first valid response is received. With multiple time sources provided, all but one will not be used. To limit the number of queries whose responses will not be used, each query is separated from the preceding one by delay milliseconds, to allow time for responses to earlier queries to be received. A larger delay reduces the query load on the time sources, increasing the time to receive a valid response if the first source attempted is slow or unreachable.
      +
      -K kodfile, --kod kodfile
      +
      Specifies the filename kodfile to be used for the persistent history of KoD (Kiss Of Death, or rate-limiting) responses received from servers. The default is /var/db/ntp-kod. If the file does not exist, a warning message will be displayed. The file will not be created. Note that the short option is -K, an uppercase letter K.
      +
      -k keyfile, --keyfile keyfile
      +
      Specifies the filename keyfile used with the -a/--authentication option. The format of the file is described on the ntp-keygen page.
      +
      -l logfile, --filelog logfile
      +
      Specifies the filename in which to append a copy of status messages, which also appear on the terminal.
      +
      -M steplimit, --steplimit steplimit
      +
      If both -S/--step and -s/--slew options are provided, an offset of less than steplimit milliseconds will be corrected by slewing the clock using adjtime(), while an offset of steplimit or more will be corrected by setting the clock to the corrected time. Note that the short option is -M, an uppercase letter M.
      +
      -o ntpver, --ntpversion ntpver
      +
      Specifies the NTP protocol version number ntpver to include in requests, default 4. This option is rarely useful.
      +
      -r, --usereservedport
      +
      By default, sntp uses a UDP source port number selected by the operating system. When this option is used, the reserved NTP port 123 is used, which most often requires sntp be invoked as the superuser (commonly "root"). This can help identify connectivity failures due to port-based firewalling which affect ntpd, which always uses source port 123.
      +
      -S, --step
      +
      By default, sntp displays the clock offset but does not attempt to correct it. This option enables offset correction by stepping, that is, directly setting the clock to the corrected time. This typically requires sntp be invoked as the superuser ("root"). Note that the short option is -S, an uppercase letter S.
      +
      -s, --slew
      +
      By default, sntp displays the clock offset but does not attempt to correct it. This option enables offset correction by slewing using adjtime(), which changes the rate of the clock for a period long enough to accomplish the required offset (phase) correction. This typically requires sntp be invoked as the superuser ("root").
      +
      -u uctimeout, --uctimeout uctimeout
      +
      Specifies the maximum time uctimeout in seconds to wait for a unicast response before terminating.
      +
      --wait
      +
      When neither -S/--step nor -s/--slew options are provided, sntp will by default terminate after the first valid response is received. This option causes sntp to instead wait for all pending queries' responses.
      +
      --version
      +
      Display the sntp program's version number and the date and time it was compiled.
      +
      +

      Return Value

      +

      The program returns an exit status of zero for if a valid response is received and non-zero otherwise.

      +

      Author

      +

      This sntp was originally developed by Johannes Maximilian Kuehn. Harlan Stenn and Dave Hart modified it to query more than one server at a time. See the file ChangeLog in the distribution for details.

      +
      + + + diff --git a/contrib/ntp/html/stats.html b/contrib/ntp/html/stats.html new file mode 100644 index 000000000..c5bc34c41 --- /dev/null +++ b/contrib/ntp/html/stats.html @@ -0,0 +1,70 @@ + + + + + +Performance Metrics + + + +

      Performance Metrics

      +

      Last update: + 26-Jul-2015 06:29 + UTC

      +

      Related Links

      + + +

      Table of Contents

      + +
      +

      1. Introduction

      + +

      This page describes several statistics provided in the NTP specification and reference implementation and how they determine the accuracy and error measured during routine and exceptional operation. These statistics provide the following information.

      +
        +
      • Nominal estimate of the server clock time relative to the client clock time. This is called clock offset symbolized by the Greek letter θ.
      • +
      • Roundtrip system and network delay measured by the on-wire protocol. This is call roundtrip delay symbolized by the Greek letter δ.
      • +
      • Potential clock offset error due to the maximum uncorrected system clock frequency error. This is called dispersion symbolized by the Greek letter ε.
      • +
      • Expected error, consisting of the root mean square (RMS) nominal clock offset sample differencess in a sliding window of several samples. This is called jitter symbolized by the Greek letter φ.
      • +
      +

      Figure 1 shows how the various measured statistics are collected and compiled to calibrate NTP performance.

      +
      +gif +

      Figure 1. Statistics Budget

      +
      +

      The data represented in boxes labeled Server are contained in fields in packet received from the server. The data represented in boxes labeled Peer are computed by the on-wire protocol, as described below. The algorithms of the box labeled Selection and Combining Algorithms process the peer data to select a system peer. The System box represents summary data inherited from the system peer. These data are available to application programs and dependent downstream clients.

      +

      2. Statistics Summary

      +

      Each NTP synchronization source is characterized by the offset θ and delay δ samples measured by the on-wire protocol, as described on the How NTP Works page. In addition, the dispersion ε sample is initialized with the sum of the source precision ρR and the client precision ρ (not shown) as each source packet is received. The dispersion increases at a rate of 15 μs/s after that. For this purpose, the precision is equal to the latency to read the system clock. The offset, delay and dispersion are called the sample statistics.

      +
      +

      Note. In very fast networks where the client clock frequency is not within 1 PPM or so of the the server clock frequency, the roundtrip delay may have small negative values. This is usually a temporary condition when the client is first started. When using the roundtrip delay in calculations, negative values are assumed zero.

      +
      +

      In a window of eight (offset, delay, dispersion) samples, the algorithm described on the Clock Filter Algorithm page selects the sample with minimum delay, which generally represents the most accurate offset statistic. The selected offset sample determines the peer offset and peer delay statistics. The peer dispersion is a weighted average of the dispersion samples in the window. These quantities are recalculated as each update is received from the source. Between updates, both the sample dispersion and peer dispersion continue to grow at the same rate, 15 μs/s. Finally, the peer jitter φ is determined as the RMS differences between the offset samples in the window relative to the selected offset sample. The peer statistics are recorded by the peerstats option of the filegen command. Peer variables are displayed by the rv command of the ntpq program.

      +

      The clock filter algorithm continues to process updates in this way until the source is no longer reachable. Reachability is determined by an eight-bit shift register, which is shifted left by one bit as each poll packet is sent, with 0 replacing the vacated rightmost bit. Each time a valid update is received, the rightmost bit is set to 1. The source is considered reachable if any bit is set to 1 in the register; otherwise, it is considered unreachable. When a source becomes unreachable, a dummy sample with "infinite" dispersion is inserted in the filter window at each poll, thus displacing old samples. This causes the peer dispersion to increase eventually to infinity.

      +

      The composition of the source population and the system peer selection is redetermined as each update from each source is received. The system peer and system variables are determined as described on the Mitigation Rules and the prefer Keyword page. The system variables Θ, Δ, Ε and Φ are updated from the system peer variables of the same name and the system stratum set one greater than the system peer stratum. The system statistics are recorded by the loopstats option of the filegen command. System variables are displayed by the rv command of the ntpq program.

      +

      Although it might seem counterintuitive, a cardinal rule in the selection process is, once a sample has been selected by the clock filter algorithm, older samples are no longer selectable. This applies also to the clock select algorithm. Once the peer variables for a source have been selected, older variables of the same or other sources are no longer selectable. The reason for these rules is to limit the time delay in the clock discipline algorithm. This is necessary to preserve the optimum impulse response and thus the risetime and overshoot.

      +

      This means that not every sample can be used to update the peer variables, and up to seven samples can be ignored between selected samples. This fact has been carefully considered in the discipline algorithm design with due consideration for feedback loop delay and minimum sampling rate. In engineering terms, even if only one sample in eight survives, the resulting sample rate is twice the Nyquist rate at any time constant and poll interval.

      +

      3. Quality of Service

      +

      This section discusses how an NTP client determines the system performance using a peer population including reference clocks and remote servers. This is determined for each peer from two statistics, peer jitter and root distance. Peer jitter is determined from various jitter components as described above. It represents the expected error in determining the clock offset estimate. Root distance represents the maximum error of the estimate due to all causes.

      +

      The root distance statistic is computed as one-half the root delay of the primary source of time; i.e., the reference clock, plus the root dispersion of that source. The root variables are included in the NTP packet header received from each source. At each update the root delay is recomputed as the sum of the root delay in the packet plus the peer delay, while the root dispersion is recomputed as the sum of the root dispersion in the packet plus the peer dispersion.

      +
      +

      Note. In order to avoid timing loops, the root distance is adjusted to the maximum of the above computation and a minimum threshold. The minimum threshold defaults to 1 ms, but can be changed according to client preference using the mindist option of the tos command.

      +
      +

      A source is considered selectable only if its root distance is less than the select threshold, by default 1.5 s, but can be changed according to client preference using the maxdist option of the tos command. When an upstream server loses all sources, its root distance apparent to dependent clients continues to increase. The clients are not aware of this condition and continue to accept synchronization as long as the root distance is less than the select threshold.

      +

      The root distance statistic is used by the select, cluster and mitigation algorithms. In this respect, it is sometimes called the synchronization distance often shortened simply to distance. The root distance is also used in the following ways.

      +
        +
      • Root distance defines the maximum error of the clock offset estimate due to all causes as long as the source remains reachable..
      • +
      • Root distance defines the upper and lower limits of the correctness interval. This interval represents the maximum clock offset for each of possibly several sources. The clock select algorithm computes the intersection of the correctness intervals to determine the truechimers from the selectable source population.
      • +
      • Root distance is used by the clock cluster algorithm as a weight factor when pruning outliers from the truechimer population.
      • +
      • The (normalized) reciprocal of the root distance is used as a weight factor by the combine algorithm when computing the system clock offset and system jitter.
      • +
      • Root distance is used by the mitigation algorithm to select the system peer from among the cluster algorithm survivors.
      • +
      +

      The root distance thus functions as a metric in the selection and weighting of the various available sources. The strategy is to select the system peer as the source with the minimum root distance and thus the minimum maximum error. The reference implementation uses the Bellman-Ford algorithm described in the literature, where the goal is to minimize the root distance. The algorithm selects the system peer, from which the system root delay and system root dispersion are inherited.

      +

      The algorithms described on the Mitigation Rules and the prefer Keyword page deliver several important statistics. The system offset and system jitter are weighted averages computed by the clock combine algorithm. System offset is best interpreted as the maximum-likelihood estimate of the system clock offset, while system jitter, also called estimated error, is best interpreted as the expected error of this estimate. System delay is the root delay inherited from the system peer, while system dispersion is the root dispersion plus contributions due to jitter and the absolute value of the system offset.

      +

      The maximum system error, or system distance, is computed as one-half the system delay plus the system dispersion. In order to simplify discussion, certain minor contributions to the maximum error statistic are ignored. If the precision time kernel support is available, both the estimated error and maximum error are reported to user programs via the ntp_adjtime() kernel system call. See the Kernel Model for Precision Timekeeping page for further information.

      +
      + + + diff --git a/contrib/ntp/html/tickadj.html b/contrib/ntp/html/tickadj.html index 14559eda4..3c38f844c 100644 --- a/contrib/ntp/html/tickadj.html +++ b/contrib/ntp/html/tickadj.html @@ -1,49 +1,45 @@ - - - - - - tickadj - set time-related kernel variables - - - - -

      tickadj - set time-related kernel variables

      -

      Last update: 18:50 UTC Thursday, July 28, 2005

      -
      -

      Synopsis

      - tickadj [ -Aqs ] [ -a tickadj ] [ -t tick ] -

      Description

      -

      The tickadj program reads, and optionally modifies, several timekeeping-related variables in older kernels that do not have support for precision ttimekeeping, including HP-UX, SunOS, Ultrix, SGI and probably others. Those machines provide means to patch the kernel /dev/kmem. Newer machines with precision time support, including Solaris, Tru64, FreeBSD and Linux (with PPSkit patch) should NOT use the program. The particular variables that can be changed with tickadj include tick, which is the number of microseconds added to the system time for a clock interrupt, tickadj, which sets the slew rate and resolution used by the adjtime system call, and dosynctodr, which indicates to the kernels on some machines whether they should internally adjust the system clock to keep it in line with time-of-day clock or not.

      -

      By default, with no arguments, tickadj reads the variables of interest in the kernel and displays them. At the same time, it determines an "optimal" value for the value of the tickadj variable if the intent is to run the ntpd Network Time Protocol (NTP) daemon, and prints this as well. Since the operation of tickadj when reading the kernel mimics the operation of similar parts of the ntpd program fairly closely, this can be useful when debugging problems with ntpd.

      -

      Note that tickadj should be run with some caution when being used for the first time on different types of machines. The operations which tickadj tries to perform are not guaranteed to work on all Unix machines and may in rare cases cause the kernel to crash.

      -

      Command Line Options

      -
      -
      -a tickadj -
      Set the kernel variable tickadj to the value tickadjspecified. -
      -A -
      Set the kernel variable tickadj to an internally computed "optimal" value. -
      -t tick -
      Set the kernel variable tick to the value tick specified. -
      -s -
      Set the kernel variable dosynctodr to zero, which disables the hardware time-of-year clock, a prerequisite for running the ntpd daemon under SunOS4. -
      -q -
      Normally, tickadj is quite verbose about what it is doing. The -q flag tells it to shut up about everything except errors. -
      -

      Files

      -
      -/vmunix
      -
      -/unix
      -
      -/dev/kmem
      -
      -

      Bugs

      - Fiddling with kernel variables at run time as a part of ordinary operations is a hideous practice which is only necessary to make up for deficiencies in the implementation of adjtime in many kernels and/or brokenness of the system clock in some vendors' kernels. It would be much better if the kernels were fixed and the tickadj program went away. -
      - - - - \ No newline at end of file + + + +tickadj - set time-related kernel variables + + + +

      tickadj - set time-related kernel variables

      +

      Last update: + 10-Mar-2014 05:24 + UTC

      +
      +

      Synopsis

      +tickadj [ -Aqs ] [ -a tickadj ] [ -t tick ] +

      Description

      +

      The tickadj program reads, and optionally modifies, several timekeeping-related variables in older kernels that do not have support for precision timekeeping, including HP-UX, SunOS, Ultrix, SGI and probably others. Those machines provide means to patch the kernel /dev/kmem. Newer machines with kernel time support, including Solaris, Tru64, FreeBSD and Linux, should NOT use the program, even if it appears to work, as it will destabilize the kernel time support. Use the ntptime program instead.

      +

      The particular variables that can be changed with tickadj include tick, which is the number of microseconds added to the system time for a clock interrupt, tickadj, which sets the slew rate and resolution used by the adjtime system call, and dosynctodr, which indicates to the kernels on some machines whether they should internally adjust the system clock to keep it in line with time-of-day clock or not.

      +

      By default, with no arguments, tickadj reads the variables of interest in the kernel and displays them. At the same time, it determines an "optimal" value for the value of the tickadj variable if the intent is to run the ntpd Network Time Protocol (NTP) daemon, and prints this as well. Since the operation of tickadj when reading the kernel mimics the operation of similar parts of the ntpd program fairly closely, this can be useful when debugging problems with ntpd.

      +

      Note that tickadj should be run with some caution when being used for the first time on different types of machines. The operations which tickadj tries to perform are not guaranteed to work on all Unix machines and may in rare cases cause the kernel to crash.

      +

      Command Line Options

      +
      +
      -a tickadj
      +
      Set the kernel variable tickadj to the value tickadj specified.
      +
      -A
      +
      Set the kernel variable tickadj to an internally computed "optimal" value.
      +
      -t tick
      +
      Set the kernel variable tick to the value tick specified.
      +
      -s
      +
      Set the kernel variable dosynctodr to zero, which disables the hardware time-of-year clock, a prerequisite for running the ntpd daemon under SunOS 4.x.
      +
      -q
      +
      Normally, tickadj is quite verbose about what it is doing. The -q flag tells it to shut up about everything except errors.
      +
      +

      Files

      +/vmunix
      +/unix
      +/dev/kmem
      +
      +

      Bugs

      +Fiddling with kernel variables at run time as a part of ordinary operations is a hideous practice which is only necessary to make up for deficiencies in the implementation of adjtime in many kernels and/or brokenness of the system clock in some vendors' kernels. It would be much better if the kernels were fixed and the tickadj program went away. +
      + + + diff --git a/contrib/ntp/html/warp.html b/contrib/ntp/html/warp.html new file mode 100644 index 000000000..1d42dd63f --- /dev/null +++ b/contrib/ntp/html/warp.html @@ -0,0 +1,60 @@ + + + + + +How NTP Works + + + +

      How NTP Works

      +

      Last update: + 10-Mar-2014 05:24 + UTC

      +

      Related Links

      + + +

      Table of Contents

      + +
      +

      Abstract

      +
      +

      This page and its dependencies contain a technical description of the Network Time Protocol (NTP) architecture and operation. It is intended for administrators, operators and monitoring personnel. Additional information for nontechnical readers can be found in the white paper Executive Summary: Computer Network Time Synchronization. While this page and its dependencies are primarily concerned with NTP, additional information on related protocols can be found in the white papers IEEE 1588 Precision Time Protocol (PTP) and Time Synchronization for Space Data Links. Note that reference to a page in this document collection is to a page in the collection, while reference to a white paper is to a document at the Network Time Synchronization Research Project web site.

      +
      +

      1. Introduction and Overview

      + +

      NTP time synchronization services are widely available in the public Internet. The public NTP subnet currently includes several thousand servers in most countries and on every continent of the globe, including Antarctica, and sometimes in space and on the sea floor. These servers support, directly or indirectly, a total population estimated at over 25 million computers in the global Internet.

      +

      The NTP subnet operates with a hierarchy of levels, where each level is assigned a number called the stratum. Stratum 1 (primary) servers at the lowest level are directly synchronized to national time services via satellite, radio or telephone modem. Stratum 2 (secondary) servers at the next higher level are synchronized to stratum 1 servers and so on. Normally, NTP clients and servers with a relatively small number of clients do not synchronize to public primary servers. There are several hundred public secondary servers operating at higher strata and are the preferred choice.

      +

      This page presents an overview of the NTP implementation included in this software distribution. We refer to this implementation as the reference implementation only because it was used to test and validate the NTPv4 specification RFC-5905. It is best read in conjunction with the briefings and white papers on the Network Time Synchronization Research Project page. An executive summary suitable for management and planning purposes is in the white paper Executive Summary: Computer Network Time Synchronization.

      +

      2. NTP Timescale and Data Formats

      +

      NTP clients and servers synchronize to the Coordinated Universal Time (UTC) timescale used by national laboratories and disseminated by radio, satellite and telephone modem. This is a global timescale independent of geographic position. There are no provisions to correct for local time zone or daylight savings time; however, these functions can be performed by the operating system on a per-user basis.

      +

      The UT1 timescale, upon which UTC is based, is determined by the rotation of the Earth about its axis. The Earth rotation is gradually slowing down relative to International Atomic Time (TAI). In order to rationalize UTC with respect to TAI, a leap second is inserted at intervals of about 18 months, as determined by the International Earth Rotation Service (IERS). Reckoning with leap seconds in the NTP timescale is described in the white paper The NTP Timescale and Leap Seconds.

      +

      The historic insertions are documented in the leap-seconds.list file, which can be downloaded from the NIST FTP servers. This file is updated at intervals not exceeding six months. Leap second warnings are disseminated by the national laboratories in the broadcast timecode format. These warnings are propagated from the NTP primary servers via other server to the clients by the NTP on-wire protocol. The leap second is implemented by the operating system kernel, as described in the white paper The NTP Timescale and Leap Seconds. Implementation details are described on the Leap Second Processing page.

      +
      +gif +

      Figure 1. NTP Data Formats

      +
      +

      Figure 1 shows two NTP time formats, a 64-bit timestamp format and a 128-bit datestamp format. The datestamp format is used internally, while the timestamp format is used in packet headers exchanged between clients and servers. The timestamp format spans 136 years, called an era. The current era began on 1 January 1900, while the next one begins in 2036. Details on these formats and conversions between them are in the white paper The NTP Era and Era Numbering. However, the NTP protocol will synchronize correctly, regardless of era, as long as the system clock is set initially within 68 years of the correct time. Further discussion on this issue is in the white paper NTP Timestamp Calculations. Ordinarily, these formats are not seen by application programs, which convert these NTP formats to native Unix or Windows formats.

      +

      3. Architecture and Algorithms

      +
      +

      gif

      +

      Figure 2. NTP Daemon Processes and Algorithms

      +
      +

      The overall organization of the NTP architecture is shown in Figure 2. It is useful in this context to consider the implementation as both a client of upstream (lower stratum) servers and as a server for downstream (higher stratum) clients. It includes a pair of peer/poll processes for each reference clock or remote server used as a synchronization source. Packets are exchanged between the client and server using the on-wire protocol described in the white paper Analysis and Simulation of the NTP On-Wire Protocols. The protocol is resistant to lost, replayed or spoofed packets.

      +

      The poll process sends NTP packets at intervals ranging from 8 s to 36 hr. The intervals are managed as described on the Poll Process page to maximize accuracy while minimizing network load. The peer process receives NTP packets and performs the packet sanity tests described on the Event Messages and Status Words page and flash status word. The flash status word reports in addition the results of various access control and security checks described in the white paper NTP Security Analysis. A sophisticated traffic monitoring facility described on the Rate Management and the Kiss-o'-Death Packet page protects against denial-of-service (DoS) attacks.

      +

      Packets that fail one or more of these tests are summarily discarded. Otherwise, the peer process runs the on-wire protocol that uses four raw timestamps: the origin timestamp T1 upon departure of the client request, the receive timestamp T2 upon arrival at the server, the transmit timestamp T3 upon departure of the server reply, and the destination timestamp T4 upon arrival at the client. These timestamps, which are recorded by the rawstats option of the filegen command, are used to calculate the clock offset and roundtrip delay samples:

      +
      +

      offset = [(T2 - T1) + (T3 - T4)] / 2,
      + delay = (T4 - T1) - (T3 - T2).

      +
      +

      In this description the transmit timestamps T1 and T3 are softstamps measured by the inline code. Softstamps are subject to various queuing and processing delays. A more accurate measurement uses drivestamps, as described on the NTP Interleaved Modes page. These issues along with mathematical models are discussed in the white paper NTP Timestamp Calculations.

      +

      The offset and delay statistics for one or more peer processes are processed by a suite of mitigation algorithms. The algorithm described on the Clock Filter Algorithm page selects the offset and delay samples most likely to produce accurate results. Those servers that have passed the sanity tests are declared selectable. From the selectable population the statistics are used by the algorithm described on the Clock Select Algorithm page to determine a number of truechimers according to Byzantine agreement and correctness principles. From the truechimer population the algorithm described on the Clock Cluster Algorithm page determines a number of survivors on the basis of statistical clustering principles.

      +

      The algorithms described on the Mitigation Rules and the prefer Keyword page combine the survivor offsets, designate one of them as the system peer and produces the final offset used by the algorithm described on the Clock Discipline Algorithm page to adjust the system clock time and frequency. The clock offset and frequency, are recorded by the loopstats option of the filegen command. For additional details about these algorithms, see the Architecture Briefing on the Network Time Synchronization Research Project page. For additional information on statistacl principles and performance metrics, see the Performance Metrics page.

      +
      + + + diff --git a/contrib/ntp/html/xleave.html b/contrib/ntp/html/xleave.html new file mode 100644 index 000000000..417185cec --- /dev/null +++ b/contrib/ntp/html/xleave.html @@ -0,0 +1,30 @@ + + + + + +NTP Interleaved Modes + + + +

      NTP Interleaved Modes

      +giffrom Pogo, Walt Kelly +

      You need a little magic.

      +

      Last update: + 10-Mar-2014 05:25 + UTC

      +
      +
      +

      In the protocol described in the NTP specification and reference implementation up to now, the transmit timestamp, which is captured before the message digest is computed and the packet queued for output, is properly called as a softstamp The receive timestamp, which is captured after the input driver interrupt routine and before the packet is queued for input, is properly called a drivestamp. For enhanced accuracy it is desirable to capture the transmit timestamp as close to the wire as possible; for example, after the output driver interrupt routine.

      +

      In other words, we would like to replace the transmit softstamp with a drivestamp, but the problem is the transmit drivestamp is available only after the packet has been sent. A solution for this problem is the two-step or interleaved protocol described on this page and included in the the current reference implementation. In interleaved modes the transmit drivestamp for one packet is actually carried in the immediately following packet. The trick, however, is to implement the interleaved protocol without changing the NTP packet header format, without compromising backwards compatibility and without compromising the error recovery properties.

      +

      The reference implementation captures a softstamp before the message digest routine and a drivestamp after the output interrupt routine. In this design the latter timestamp can be considered most accurate, as it avoids the various queuing and transmission latencies. The difference between the two timestamps, which is called the interleaved or output delay, varies from 16 μs for a dual-core Pentium running FreeBSD 6.1 to 1100 μs for a Sun Blade 1500 running Solaris 10.

      +

      Interleaved mode can be used only in NTP symmetric and broadcast modes. + It is activated by the xleave option with the peer or broadcast configuration +commands. A broadcast server configured for interleaved mode is transparent to ordinary broadcast clients, so both ordinary and interleaved broadcast clients can use the same packets. An interleaved symmetric active peer automatically switches to ordinary symmetric mode if the other peer is not capable of operation in interleaved mode.

      +

      As demonstrated in the white paper Analysis and Simulation of the NTP On-Wire Protocols, the interleaved modes have the same resistance to lost packets, duplicate packets, packets crossed in flight and protocol restarts as the ordinary modes. An application of the interleaved symmetric mode in space missions is presented in the white paper Time Synchronization for Space Data Links.

      +
      +
      gif
      +
      + + + diff --git a/contrib/ntp/include/Makefile.am b/contrib/ntp/include/Makefile.am index 1fbe6fcfe..f032c97e7 100644 --- a/contrib/ntp/include/Makefile.am +++ b/contrib/ntp/include/Makefile.am @@ -1,63 +1,79 @@ -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr -ETAGS_ARGS = $(srcdir)/Makefile.am -EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def +NULL = SUBDIRS = isc -noinst_HEADERS = \ - adjtime.h \ - audio.h \ - ascii.h \ - audio.h \ - binio.h \ - global.h \ - gps.h \ - hopf6039.h \ - icom.h \ - ieee754io.h \ - iosignal.h \ - l_stdlib.h \ - mbg_gps166.h \ - mx4200.h \ - ntif.h \ - ntp.h \ - ntp_calendar.h \ - ntp_cmdargs.h \ - ntp_config.h \ - ntp_control.h \ - ntp_crypto.h \ - ntp_datum.h \ - ntp_debug.h \ - ntp_filegen.h \ - ntp_fp.h \ - ntp_if.h \ - ntp_io.h \ - ntp_machine.h \ - ntp_malloc.h \ - ntp_md5.h \ - ntp_proto.h \ - ntp_random.h \ - ntp_refclock.h \ - ntp_request.h \ - ntp_rfc2553.h \ - ntp_select.h \ - ntp_sprintf.h \ - ntp_stdlib.h \ - ntp_string.h \ - ntp_syscall.h \ - ntp_syslog.h \ - ntp_tty.h \ - ntp_types.h \ - ntp_unixtime.h \ - ntpd.h \ - ntpsim.h \ - parse.h \ - parse_conf.h \ - recvbuff.h \ - rsa_md5.h \ +noinst_HEADERS = \ + adjtime.h \ + audio.h \ + ascii.h \ + audio.h \ + binio.h \ + declcond.h \ + gps.h \ + hopf6039.h \ + icom.h \ + ieee754io.h \ + intreswork.h \ + iosignal.h \ + l_stdlib.h \ + lib_strbuf.h \ + libntp.h \ + mbg_gps166.h \ + mx4200.h \ + ntif.h \ + ntp.h \ + ntp_assert.h \ + ntp_calendar.h \ + ntp_cmdargs.h \ + ntp_config.h \ + ntp_control.h \ + ntp_crypto.h \ + ntp_prio_q.h \ + ntp_datum.h \ + ntp_debug.h \ + ntp_filegen.h \ + ntp_fp.h \ + ntp_if.h \ + ntp_intres.h \ + ntp_io.h \ + ntp_libopts.h \ + ntp_lineedit.h \ + ntp_lists.h \ + ntp_machine.h \ + ntp_malloc.h \ + ntp_md5.h \ + ntp_net.h \ + ntp_proto.h \ + ntp_random.h \ + ntp_refclock.h \ + ntp_request.h \ + ntp_rfc2553.h \ + ntp_select.h \ + ntp_stdlib.h \ + ntp_string.h \ + ntp_syscall.h \ + ntp_syslog.h \ + ntp_tty.h \ + ntp_types.h \ + ntp_unixtime.h \ + ntp_worker.h \ + ntp_workimpl.h \ + ntpd.h \ + ntpsim.h \ + parse.h \ + parse_conf.h \ + rc_cmdlength.h \ + recvbuff.h \ + refclock_atom.h \ + refidsmear.h \ + ssl_applink.c \ timepps-SCO.h \ timepps-Solaris.h \ timepps-SunOS.h \ - trimble.h + timespecops.h \ + timetoa.h \ + timevalops.h \ + trimble.h \ + vint64ops.h \ + $(NULL) diff --git a/contrib/ntp/include/Makefile.in b/contrib/ntp/include/Makefile.in index 70b0330d7..8f0968bf7 100644 --- a/contrib/ntp/include/Makefile.in +++ b/contrib/ntp/include/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -16,6 +15,61 @@ @SET_MAKE@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -35,38 +89,110 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = include -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = SOURCES = DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ - html-recursive info-recursive install-data-recursive \ - install-dvi-recursive install-exec-recursive \ - install-html-recursive install-info-recursive \ - install-pdf-recursive install-ps-recursive install-recursive \ - installcheck-recursive installdirs-recursive pdf-recursive \ - ps-recursive uninstall-recursive +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac HEADERS = $(noinst_HEADERS) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive -AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ - $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \ +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) am__relativize = \ dir0=`pwd`; \ @@ -94,42 +220,74 @@ am__relativize = \ done; \ reldir="$$dir2" ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -137,8 +295,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -148,15 +309,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -164,23 +386,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -227,67 +485,82 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr -ETAGS_ARGS = $(srcdir)/Makefile.am -EXTRA_DIST = autogen-version.def copyright.def debug-opt.def homerc.def version.def +NULL = SUBDIRS = isc noinst_HEADERS = \ - adjtime.h \ - audio.h \ - ascii.h \ - audio.h \ - binio.h \ - global.h \ - gps.h \ - hopf6039.h \ - icom.h \ - ieee754io.h \ - iosignal.h \ - l_stdlib.h \ - mbg_gps166.h \ - mx4200.h \ - ntif.h \ - ntp.h \ - ntp_calendar.h \ - ntp_cmdargs.h \ - ntp_config.h \ - ntp_control.h \ - ntp_crypto.h \ - ntp_datum.h \ - ntp_debug.h \ - ntp_filegen.h \ - ntp_fp.h \ - ntp_if.h \ - ntp_io.h \ - ntp_machine.h \ - ntp_malloc.h \ - ntp_md5.h \ - ntp_proto.h \ - ntp_random.h \ - ntp_refclock.h \ - ntp_request.h \ - ntp_rfc2553.h \ - ntp_select.h \ - ntp_sprintf.h \ - ntp_stdlib.h \ - ntp_string.h \ - ntp_syscall.h \ - ntp_syslog.h \ - ntp_tty.h \ - ntp_types.h \ - ntp_unixtime.h \ - ntpd.h \ - ntpsim.h \ - parse.h \ - parse_conf.h \ - recvbuff.h \ - rsa_md5.h \ + adjtime.h \ + audio.h \ + ascii.h \ + audio.h \ + binio.h \ + declcond.h \ + gps.h \ + hopf6039.h \ + icom.h \ + ieee754io.h \ + intreswork.h \ + iosignal.h \ + l_stdlib.h \ + lib_strbuf.h \ + libntp.h \ + mbg_gps166.h \ + mx4200.h \ + ntif.h \ + ntp.h \ + ntp_assert.h \ + ntp_calendar.h \ + ntp_cmdargs.h \ + ntp_config.h \ + ntp_control.h \ + ntp_crypto.h \ + ntp_prio_q.h \ + ntp_datum.h \ + ntp_debug.h \ + ntp_filegen.h \ + ntp_fp.h \ + ntp_if.h \ + ntp_intres.h \ + ntp_io.h \ + ntp_libopts.h \ + ntp_lineedit.h \ + ntp_lists.h \ + ntp_machine.h \ + ntp_malloc.h \ + ntp_md5.h \ + ntp_net.h \ + ntp_proto.h \ + ntp_random.h \ + ntp_refclock.h \ + ntp_request.h \ + ntp_rfc2553.h \ + ntp_select.h \ + ntp_stdlib.h \ + ntp_string.h \ + ntp_syscall.h \ + ntp_syslog.h \ + ntp_tty.h \ + ntp_types.h \ + ntp_unixtime.h \ + ntp_worker.h \ + ntp_workimpl.h \ + ntpd.h \ + ntpsim.h \ + parse.h \ + parse_conf.h \ + rc_cmdlength.h \ + recvbuff.h \ + refclock_atom.h \ + refidsmear.h \ + ssl_applink.c \ timepps-SCO.h \ timepps-Solaris.h \ timepps-SunOS.h \ - trimble.h + timespecops.h \ + timetoa.h \ + timevalops.h \ + trimble.h \ + vint64ops.h \ + $(NULL) all: all-recursive @@ -304,7 +577,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign include/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -330,22 +602,25 @@ clean-libtool: -rm -rf .libs _libs # This directory's subdirectories are mostly independent; you can cd -# into them and run `make' without going through this Makefile. -# To change the values of `make' variables: instead of editing Makefiles, -# (1) if the variable is set in `config.status', edit `config.status' -# (which will cause the Makefiles to be regenerated when you run `make'); -# (2) otherwise, pass the desired values on the `make' command line. -$(RECURSIVE_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ @@ -360,57 +635,12 @@ $(RECURSIVE_TARGETS): $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" -$(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - rev=''; for subdir in $$list; do \ - if test "$$subdir" = "."; then :; else \ - rev="$$subdir $$rev"; \ - fi; \ - done; \ - rev="$$rev ."; \ - target=`echo $@ | sed s/-recursive//`; \ - for subdir in $$rev; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done && test -z "$$fail" -tags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ - done -ctags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ - done +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ @@ -426,12 +656,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -443,15 +668,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -460,6 +681,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -496,13 +732,10 @@ distdir: $(DISTFILES) done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ - test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ @@ -537,10 +770,15 @@ install-am: all-am installcheck: installcheck-recursive install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: @@ -618,22 +856,22 @@ ps-am: uninstall-am: -.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \ - install-am install-strip tags-recursive - -.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ - all all-am check check-am clean clean-generic clean-libtool \ - ctags ctags-recursive distclean distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs installdirs-am maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \ - uninstall uninstall-am +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. diff --git a/contrib/ntp/include/audio.h b/contrib/ntp/include/audio.h index 6d16347ec..0d7422666 100644 --- a/contrib/ntp/include/audio.h +++ b/contrib/ntp/include/audio.h @@ -9,6 +9,6 @@ /* * Function prototypes */ -int audio_init P((char *, int, int)); -int audio_gain P((int, int, int)); -void audio_show P((void)); +int audio_init (const char *, int, int); +int audio_gain (int, int, int); +void audio_show (void); diff --git a/contrib/ntp/include/autogen-version.def b/contrib/ntp/include/autogen-version.def deleted file mode 100644 index 89439830e..000000000 --- a/contrib/ntp/include/autogen-version.def +++ /dev/null @@ -1,2 +0,0 @@ -#assert (version-compare >= autogen-version "5.9.1") -guard-option-names; diff --git a/contrib/ntp/include/binio.h b/contrib/ntp/include/binio.h index 56e671fdb..cf9863357 100644 --- a/contrib/ntp/include/binio.h +++ b/contrib/ntp/include/binio.h @@ -37,15 +37,25 @@ #include "ntp_stdlib.h" -long get_lsb_short P((unsigned char **)); -void put_lsb_short P((unsigned char **, long)); -long get_lsb_long P((unsigned char **)); -void put_lsb_long P((unsigned char **, long)); +long get_lsb_short (unsigned char **); +void put_lsb_short (unsigned char **, long); +long get_lsb_long (unsigned char **); +void put_lsb_long (unsigned char **, long); -long get_msb_short P((unsigned char **)); -void put_msb_short P((unsigned char **, long)); -long get_msb_long P((unsigned char **)); -void put_msb_long P((unsigned char **, long)); +#define get_lsb_int16( _x_ ) ((int16_t) get_lsb_short( _x_ )) +#define get_lsb_uint16( _x_ ) ((uint16_t) get_lsb_short( _x_ )) +#define get_lsb_int32( _x_ ) ((int32_t) get_lsb_long( _x_ )) +#define get_lsb_uint32( _x_ ) ((uint32_t) get_lsb_long( _x_ )) + +long get_msb_short (unsigned char **); +void put_msb_short (unsigned char **, long); +long get_msb_long (unsigned char **); +void put_msb_long (unsigned char **, long); + +#define get_msb_int16( _x_ ) ((int16_t) get_msb_short( _x_ )) +#define get_msb_uint16( _x_ ) ((uint16_t) get_msb_short( _x_ )) +#define get_msb_int32( _x_ ) ((int32_t) get_msb_long( _x_ )) +#define get_msb_uint32( _x_ ) ((uint32_t) get_msb_long( _x_ )) #endif /* diff --git a/contrib/ntp/include/copyright.def b/contrib/ntp/include/copyright.def deleted file mode 100644 index ccc3e91cf..000000000 --- a/contrib/ntp/include/copyright.def +++ /dev/null @@ -1,18 +0,0 @@ -/* -*- Mode: Text -*- */ - -copyright = { - date = "1970-2009"; - owner = "David L. Mills and/or others"; - eaddr = "http://bugs.ntp.org, bugs@ntp.org"; - type = note; - text = "see html/copyright.html"; -}; - -long-opts; -config-header = config.h; -environrc; - -version = ` -eval VERSION=\`sed -e 's/.*,\\[//' -e 's/\\].*//' < ../version.m4\` -[ -z "${VERSION}" ] && echo "Cannot determine VERSION" && kill -TERM $AG_pid -echo $VERSION`; diff --git a/contrib/ntp/include/debug-opt.def b/contrib/ntp/include/debug-opt.def deleted file mode 100644 index 2c3da2a63..000000000 --- a/contrib/ntp/include/debug-opt.def +++ /dev/null @@ -1,34 +0,0 @@ - -include = <<- _EOF_ - #ifdef __windows - extern int atoi(const char*); - #else - # include - #endif - _EOF_; - -flag = { - name = debug-level; - value = d; - max = NOLIMIT; - ifdef = DEBUG; - nopreset; - descrip = "Increase output debug message level"; - doc = <<- _EndOfDoc_ - Increase the debugging message output level. - _EndOfDoc_; -}; - -flag = { - name = set-debug-level; - value = D; - max = NOLIMIT; - ifdef = DEBUG; - descrip = "Set the output debug message level"; - arg-type = string; - flag-code = 'DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg );'; - doc = <<- _EndOfDoc_ - Set the output debugging level. Can be supplied multiple times, - but each overrides the previous value(s). - _EndOfDoc_; -}; diff --git a/contrib/ntp/include/declcond.h b/contrib/ntp/include/declcond.h new file mode 100644 index 000000000..751eff9d1 --- /dev/null +++ b/contrib/ntp/include/declcond.h @@ -0,0 +1,21 @@ +/* + * declcond.h - declarations conditionalized for ntpd + * + * The NTP reference implementation distribution includes two distinct + * declcond.h files, one in ntpd/ used only by ntpd, and another in + * include/ used by libntp and utilities. This relies on the source + * file's directory being ahead of include/ in the include search. + * + * The ntpd variant of declcond.h declares "debug" only #ifdef DEBUG, + * as the --disable-debugging version of ntpd should not reference + * "debug". The libntp and utilities variant always declares debug, + * as it is used in those codebases even without DEBUG defined. + */ +#ifndef DECLCOND_H +#define DECLCOND_H + +/* #ifdef DEBUG */ /* uncommented in ntpd/declcond.h */ +extern int debug; +/* #endif */ /* uncommented in ntpd/declcond.h */ + +#endif /* DECLCOND_H */ diff --git a/contrib/ntp/include/global.h b/contrib/ntp/include/global.h deleted file mode 100644 index 742f84cd9..000000000 --- a/contrib/ntp/include/global.h +++ /dev/null @@ -1,54 +0,0 @@ -/* GLOBAL.H - RSAREF types and constants */ - -/* Copyright (C) RSA Laboratories, a division of RSA Data Security, - Inc., created 1991. All rights reserved. - */ - -/* - * Note: the modifications are necessary for little-endian machines - */ -#include "ntp_types.h" /* local modification */ - -#ifndef _GLOBAL_H_ -#define _GLOBAL_H_ 1 - -/* PROTOTYPES should be set to one if and only if the compiler supports - function argument prototyping. - The following makes PROTOTYPES default to 1 if it has not already been - defined as 0 with C compiler flags. - */ -#ifdef HAVE_PROTOTYPES -#define PROTOTYPES 1 -#endif - -/* POINTER defines a generic pointer type */ -typedef unsigned char *POINTER; - -/* UINT2 defines a two byte word */ -typedef unsigned short int UINT2; - -/* UINT4 defines a four byte word */ -typedef u_int32 UINT4; /* local modification */ - -/* BYTE defines a unsigned character */ -typedef unsigned char BYTE; /* local modification for RSAEuro */ - -#ifndef NULL_PTR -#define NULL_PTR ((POINTER)0) -#endif - -#ifndef UNUSED_ARG -#define UNUSED_ARG(x) x = *(&x); -#endif - -/* PROTO_LIST is defined depending on how PROTOTYPES is defined above. - If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it - returns an empty list. - */ -#if PROTOTYPES -#define PROTO_LIST(list) list -#else -#define PROTO_LIST(list) () -#endif - -#endif /* end _GLOBAL_H_ */ diff --git a/contrib/ntp/include/icom.h b/contrib/ntp/include/icom.h index aac62c8d3..b271afbec 100644 --- a/contrib/ntp/include/icom.h +++ b/contrib/ntp/include/icom.h @@ -83,5 +83,5 @@ /* * Function prototypes */ -int icom_init P((char *, int, int)); -int icom_freq P((int, int, double)); +int icom_init (const char *, int, int); +int icom_freq (int, int, double); diff --git a/contrib/ntp/include/ieee754io.h b/contrib/ntp/include/ieee754io.h index 6906731cb..73e7f7983 100644 --- a/contrib/ntp/include/ieee754io.h +++ b/contrib/ntp/include/ieee754io.h @@ -52,8 +52,8 @@ #define IEEE_OFFSETS 8 /* number of byte positions */ typedef unsigned char offsets_t[IEEE_OFFSETS]; -int fetch_ieee754 P((unsigned char **bufp, int size, l_fp *lfpp, offsets_t offsets)); -int put_ieee754 P((unsigned char **bufpp, int size, l_fp *lfpp, offsets_t offsets)); +int fetch_ieee754 (unsigned char **bufp, int size, l_fp *lfpp, offsets_t offsets); +int put_ieee754 (unsigned char **bufpp, int size, l_fp *lfpp, offsets_t offsets); #endif /* diff --git a/contrib/ntp/include/intreswork.h b/contrib/ntp/include/intreswork.h new file mode 100644 index 000000000..c343ac013 --- /dev/null +++ b/contrib/ntp/include/intreswork.h @@ -0,0 +1,29 @@ +/* + * intreswork.h -- declarations private to ntp_intres.c, ntp_worker.c. + */ +#ifndef INTRESWORK_H +#define INTRESWORK_H + +#include "ntp_worker.h" + +#ifdef WORKER + +extern int blocking_getaddrinfo(blocking_child *, + blocking_pipe_header *); +extern int blocking_getnameinfo(blocking_child *, + blocking_pipe_header *); + +#ifdef TEST_BLOCKING_WORKER +extern void gai_test_callback(int rescode, int gai_errno, + void *context, const char *name, + const char *service, + const struct addrinfo *hints, + const struct addrinfo *ai_res); +extern void gni_test_callback(int rescode, int gni_errno, + sockaddr_u *psau, int flags, + const char *host, + const char *service, void *context); +#endif /* TEST_BLOCKING_WORKER */ +#endif /* WORKER */ + +#endif /* INTRESWORK_H */ diff --git a/contrib/ntp/include/iosignal.h b/contrib/ntp/include/iosignal.h index bd74e096d..406804e14 100644 --- a/contrib/ntp/include/iosignal.h +++ b/contrib/ntp/include/iosignal.h @@ -1,23 +1,58 @@ -#if !defined _ntp_iosignaled_h -#define _ntp_iosignaled_h +#ifndef IOSIGNAL_H +#define IOSIGNAL_H #include "ntp_refclock.h" + /* + * Some systems (MOST) define SIGPOLL == SIGIO, others SIGIO == SIGPOLL, and + * a few have separate SIGIO and SIGPOLL signals. This code checks for the + * SIGIO == SIGPOLL case at compile time. + * Do not define USE_SIGPOLL or USE_SIGIO. + * these are interal only to iosignal.c and ntpd/work_fork.c! + */ +#if defined(USE_SIGPOLL) +# undef USE_SIGPOLL +#endif +#if defined(USE_SIGIO) +# undef USE_SIGIO +#endif + +/* type of input handler function - only shared between iosignal.c and ntp_io.c */ +typedef void (input_handler_t)(l_fp *); + #if defined(HAVE_SIGNALED_IO) -extern void block_sigio P((void)); -extern void unblock_sigio P((void)); -extern int init_clock_sig P((struct refclockio *)); -extern void init_socket_sig P((int)); -extern void set_signal P((void)); -RETSIGTYPE sigio_handler P((int)); +# if defined(USE_TTY_SIGPOLL) || defined(USE_UDP_SIGPOLL) +# define USE_SIGPOLL +# endif -# define BLOCKIO() ((void) block_sigio()) -# define UNBLOCKIO() ((void) unblock_sigio()) +# if !defined(USE_TTY_SIGPOLL) || !defined(USE_UDP_SIGPOLL) +# define USE_SIGIO +# endif -#else +# if defined(USE_SIGIO) && defined(USE_SIGPOLL) +# if SIGIO == SIGPOLL +# define USE_SIGIO +# undef USE_SIGPOLL +# endif /* SIGIO == SIGPOLL */ +# endif /* USE_SIGIO && USE_SIGPOLL */ -# define BLOCKIO() -# define UNBLOCKIO() -#endif /* HAVE_SIGNALED_IO */ +#define USING_SIGIO() using_sigio +extern int using_sigio; + +extern void block_sigio (void); +extern void unblock_sigio (void); +extern int init_clock_sig (struct refclockio *); +extern void init_socket_sig (int); +extern void set_signal (input_handler_t *); + +# define BLOCKIO() block_sigio() +# define UNBLOCKIO() unblock_sigio() + +#else /* !HAVE_SIGNALED_IO follows */ +# define BLOCKIO() do {} while (0) +# define UNBLOCKIO() do {} while (0) +# define USING_SIGIO() FALSE #endif + +#endif /* IOSIGNAL_H */ diff --git a/contrib/ntp/include/isc/Makefile.am b/contrib/ntp/include/isc/Makefile.am index 3d8c2a47f..160203b0c 100644 --- a/contrib/ntp/include/isc/Makefile.am +++ b/contrib/ntp/include/isc/Makefile.am @@ -1,37 +1,5 @@ -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr -ETAGS_ARGS = $(srcdir)/Makefile.am -#EXTRA_DIST = TAGS +NULL = -noinst_HEADERS = \ - app.h \ - assertions.h \ - boolean.h \ - buffer.h \ - error.h \ - formatcheck.h \ - int.h \ - interfaceiter.h \ - ipv6.h \ - lang.h \ - lib.h \ - list.h \ - magic.h \ - mem.h \ - msgcat.h \ - msgs.h \ - mutex.h \ - net.h \ - netaddr.h \ - netscope.h \ - offset.h \ - once.h \ - platform.h \ - print.h \ - result.h \ - region.h \ - sockaddr.h \ - strerror.h \ - string.h \ - types.h \ - util.h +noinst_HEADERS = \ + mem.h \ + $(NULL) diff --git a/contrib/ntp/include/isc/Makefile.in b/contrib/ntp/include/isc/Makefile.in index 531da09b4..5bd25d615 100644 --- a/contrib/ntp/include/isc/Makefile.in +++ b/contrib/ntp/include/isc/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -16,6 +15,61 @@ @SET_MAKE@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -35,63 +89,163 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = include/isc -DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = SOURCES = DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -99,8 +253,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -110,15 +267,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -126,23 +344,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -189,43 +443,10 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr -ETAGS_ARGS = $(srcdir)/Makefile.am -#EXTRA_DIST = TAGS +NULL = noinst_HEADERS = \ - app.h \ - assertions.h \ - boolean.h \ - buffer.h \ - error.h \ - formatcheck.h \ - int.h \ - interfaceiter.h \ - ipv6.h \ - lang.h \ - lib.h \ - list.h \ - magic.h \ - mem.h \ - msgcat.h \ - msgs.h \ - mutex.h \ - net.h \ - netaddr.h \ - netscope.h \ - offset.h \ - once.h \ - platform.h \ - print.h \ - result.h \ - region.h \ - sockaddr.h \ - strerror.h \ - string.h \ - types.h \ - util.h + mem.h \ + $(NULL) all: all-am @@ -242,7 +463,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/isc/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign include/isc/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -267,26 +487,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -298,15 +507,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -315,6 +520,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -363,10 +583,15 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: @@ -446,19 +671,21 @@ uninstall-am: .MAKE: install-am install-strip -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-libtool ctags distclean distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool cscopelist-am ctags ctags-am distclean \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ uninstall-am +.PRECIOUS: Makefile + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/contrib/ntp/include/isc/app.h b/contrib/ntp/include/isc/app.h deleted file mode 100644 index 5aa3d23ac..000000000 --- a/contrib/ntp/include/isc/app.h +++ /dev/null @@ -1,212 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: app.h,v 1.1 2001/07/06 19:50:03 gson Exp $ */ - -#ifndef ISC_APP_H -#define ISC_APP_H 1 - -/***** - ***** Module Info - *****/ - -/* - * ISC Application Support - * - * Dealing with program termination can be difficult, especially in a - * multithreaded program. The routines in this module help coordinate - * the shutdown process. They are used as follows by the initial (main) - * thread of the application: - * - * isc_app_start(); Call very early in main(), before - * any other threads have been created. - * - * isc_app_run(); This will post any on-run events, - * and then block until application - * shutdown is requested. A shutdown - * request is made by calling - * isc_app_shutdown(), or by sending - * SIGINT or SIGTERM to the process. - * After isc_app_run() returns, the - * application should shutdown itself. - * - * isc_app_finish(); Call very late in main(). - * - * Applications that want to use SIGHUP/isc_app_reload() to trigger reloading - * should check the result of isc_app_run() and call the reload routine if - * the result is ISC_R_RELOAD. They should then call isc_app_run() again - * to resume waiting for reload or termination. - * - * Use of this module is not required. In particular, isc_app_start() is - * NOT an ISC library initialization routine. - * - * MP: - * Clients must ensure that isc_app_start(), isc_app_run(), and - * isc_app_finish() are called at most once. isc_app_shutdown() - * is safe to use by any thread (provided isc_app_start() has been - * called previously). - * - * Reliability: - * No anticipated impact. - * - * Resources: - * None. - * - * Security: - * No anticipated impact. - * - * Standards: - * None. - */ - -#include -#include -#include - -typedef isc_event_t isc_appevent_t; - -#define ISC_APPEVENT_FIRSTEVENT (ISC_EVENTCLASS_APP + 0) -#define ISC_APPEVENT_SHUTDOWN (ISC_EVENTCLASS_APP + 1) -#define ISC_APPEVENT_LASTEVENT (ISC_EVENTCLASS_APP + 65535) - -ISC_LANG_BEGINDECLS - -isc_result_t -isc_app_start(void); -/* - * Start an ISC library application. - * - * Notes: - * This call should be made before any other ISC library call, and as - * close to the beginning of the application as possible. - */ - -isc_result_t -isc_app_onrun(isc_mem_t *mctx, isc_task_t *task, isc_taskaction_t action, - void *arg); -/* - * Request delivery of an event when the application is run. - * - * Requires: - * isc_app_start() has been called. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_NOMEMORY - */ - -isc_result_t -isc_app_run(void); -/* - * Run an ISC library application. - * - * Notes: - * The caller (typically the initial thread of an application) will - * block until shutdown is requested. When the call returns, the - * caller should start shutting down the application. - * - * Requires: - * isc_app_start() has been called. - * - * Ensures: - * Any events requested via isc_app_onrun() will have been posted (in - * FIFO order) before isc_app_run() blocks. - * - * Returns: - * ISC_R_SUCCESS Shutdown has been requested. - * ISC_R_RELOAD Reload has been requested. - */ - -isc_result_t -isc_app_shutdown(void); -/* - * Request application shutdown. - * - * Notes: - * It is safe to call isc_app_shutdown() multiple times. Shutdown will - * only be triggered once. - * - * Requires: - * isc_app_run() has been called. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_UNEXPECTED - */ - -isc_result_t -isc_app_reload(void); -/* - * Request application reload. - * - * Requires: - * isc_app_run() has been called. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_UNEXPECTED - */ - -void -isc_app_finish(void); -/* - * Finish an ISC library application. - * - * Notes: - * This call should be made at or near the end of main(). - * - * Requires: - * isc_app_start() has been called. - * - * Ensures: - * Any resources allocated by isc_app_start() have been released. - */ - -void -isc_app_block(void); -/* - * Indicate that a blocking operation will be performed. - * - * Notes: - * If a blocking operation is in process, a call to isc_app_shutdown() - * or an external signal will abort the program, rather than allowing - * clean shutdown. This is primarily useful for reading user input. - * - * Requires: - * isc_app_start() has been called. - * No other blocking operations are in progress. - */ - -void -isc_app_unblock(void); -/* - * Indicate that a blocking operation is complete. - * - * Notes: - * When a blocking operation has completed, return the program to a - * state where a call to isc_app_shutdown() or an external signal will - * shutdown normally. - * - * Requires: - * isc_app_start() has been called. - * isc_app_block() has been called by the same thread. - */ - - -ISC_LANG_ENDDECLS - -#endif /* ISC_APP_H */ diff --git a/contrib/ntp/include/isc/boolean.h b/contrib/ntp/include/isc/boolean.h deleted file mode 100644 index d10007b58..000000000 --- a/contrib/ntp/include/isc/boolean.h +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (C) 1998-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: boolean.h,v 1.12 2001/01/09 21:56:45 bwelling Exp $ */ - -#ifndef ISC_BOOLEAN_H -#define ISC_BOOLEAN_H 1 - -typedef enum { isc_boolean_false = 0, isc_boolean_true = 1 } isc_boolean_t; - -#define ISC_FALSE isc_boolean_false -#define ISC_TRUE isc_boolean_true -#define ISC_TF(x) ((x) ? ISC_TRUE : ISC_FALSE) - -#endif /* ISC_BOOLEAN_H */ diff --git a/contrib/ntp/include/isc/formatcheck.h b/contrib/ntp/include/isc/formatcheck.h deleted file mode 100644 index e9b91698e..000000000 --- a/contrib/ntp/include/isc/formatcheck.h +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: formatcheck.h,v 1.6 2001/01/09 21:56:55 bwelling Exp $ */ - -#ifndef ISC_FORMATCHECK_H -#define ISC_FORMATCHECK_H 1 - -/* - * fmt is the location of the format string parameter. - * args is the location of the first argument (or 0 for no argument checking). - * Note: the first parameter is 1, not 0. - */ -#ifdef __GNUC__ -#define ISC_FORMAT_PRINTF(fmt, args) __attribute__((__format__(__printf__, fmt, args))) -#else -#define ISC_FORMAT_PRINTF(fmt, args) -#endif - -#endif /* ISC_FORMATCHECK_H */ diff --git a/contrib/ntp/include/isc/interfaceiter.h b/contrib/ntp/include/isc/interfaceiter.h deleted file mode 100644 index f2d11ba8a..000000000 --- a/contrib/ntp/include/isc/interfaceiter.h +++ /dev/null @@ -1,139 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: interfaceiter.h,v 1.10 2001/01/09 21:57:01 bwelling Exp $ */ - -#ifndef ISC_INTERFACEITER_H -#define ISC_INTERFACEITER_H 1 - -/***** - ***** Module Info - *****/ - -/* - * Interface iterator - * - * Iterate over the list of network interfaces. - * - * Interfaces whose address family is not supported are ignored and never - * returned by the iterator. Interfaces whose netmask, interface flags, - * or similar cannot be obtained are also ignored, and the failure is logged. - * - * Standards: - * The API for scanning varies greatly among operating systems. - * This module attempts to hide the differences. - */ - -/*** - *** Imports - ***/ - -#include -#include -#include - -/* - * Public structure describing a network interface. - */ - -struct isc_interface { - char name[32]; /* Interface name, null-terminated. */ - unsigned int af; /* Address family. */ - isc_netaddr_t address; /* Local address. */ - isc_netaddr_t netmask; /* Network mask. */ - isc_netaddr_t broadcast; /* Broadcast address. */ - isc_netaddr_t dstaddress; /* Destination address - (point-to-point only). */ - isc_uint32_t flags; /* Flags; see below. */ - unsigned int ifindex; /* Interface Index */ - unsigned int scopeid; /* Scope id for Multicasting */ -}; - -/* Interface flags. */ - -#define INTERFACE_F_UP 0x00000001U /* Interface is up */ -#define INTERFACE_F_POINTTOPOINT 0x00000002U /*this is point-to-point interface*/ -#define INTERFACE_F_LOOPBACK 0x00000004U /* this is loopback interface */ -#define INTERFACE_F_BROADCAST 0x00000008U /* Broadcast is supported */ -#define INTERFACE_F_MULTICAST 0x00000010U /* multicast is supported */ - -/*** - *** Functions - ***/ - -ISC_LANG_BEGINDECLS - -isc_result_t -isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp); -/* - * Create an iterator for traversing the operating system's list - * of network interfaces. - * - * Returns: - * ISC_R_SUCCESS - * ISC_R_NOMEMORY - * Various network-related errors - */ - -isc_result_t -isc_interfaceiter_first(isc_interfaceiter_t *iter); -/* - * Position the iterator on the first interface. - * - * Returns: - * ISC_R_SUCCESS Success. - * ISC_R_NOMORE There are no interfaces. - */ - -isc_result_t -isc_interfaceiter_current(isc_interfaceiter_t *iter, - isc_interface_t *ifdata); -/* - * Get information about the interface the iterator is currently - * positioned at and store it at *ifdata. - * - * Requires: - * The iterator has been successfully positioned using - * isc_interface_iter_first() / isc_interface_iter_next(). - * - * Returns: - * ISC_R_SUCCESS Success. - */ - -isc_result_t -isc_interfaceiter_next(isc_interfaceiter_t *iter); -/* - * Position the iterator on the next interface. - * - * Requires: - * The iterator has been successfully positioned using - * isc_interface_iter_first() / isc_interface_iter_next(). - * - * Returns: - * ISC_R_SUCCESS Success. - * ISC_R_NOMORE There are no more interfaces. - */ - -void -isc_interfaceiter_destroy(isc_interfaceiter_t **iterp); -/* - * Destroy the iterator. - */ - -ISC_LANG_ENDDECLS - -#endif /* ISC_INTERFACEITER_H */ diff --git a/contrib/ntp/include/isc/lang.h b/contrib/ntp/include/isc/lang.h deleted file mode 100644 index b3ba5908f..000000000 --- a/contrib/ntp/include/isc/lang.h +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: lang.h,v 1.6 2001/01/09 21:57:03 bwelling Exp $ */ - -#ifndef ISC_LANG_H -#define ISC_LANG_H 1 - -#ifdef __cplusplus -#define ISC_LANG_BEGINDECLS extern "C" { -#define ISC_LANG_ENDDECLS } -#else -#define ISC_LANG_BEGINDECLS -#define ISC_LANG_ENDDECLS -#endif - -#endif /* ISC_LANG_H */ diff --git a/contrib/ntp/include/isc/lib.h b/contrib/ntp/include/isc/lib.h deleted file mode 100644 index 7feef43c5..000000000 --- a/contrib/ntp/include/isc/lib.h +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: lib.h,v 1.7 2001/11/19 03:08:25 mayer Exp $ */ - -#ifndef ISC_LIB_H -#define ISC_LIB_H 1 - -#include -#include - -ISC_LANG_BEGINDECLS - -LIBISC_EXTERNAL_DATA extern isc_msgcat_t *isc_msgcat; - -void -isc_lib_initmsgcat(void); -/* - * Initialize the ISC library's message catalog, isc_msgcat, if it - * has not already been initialized. - */ - -ISC_LANG_ENDDECLS - -#endif /* ISC_LIB_H */ diff --git a/contrib/ntp/include/isc/mem.h b/contrib/ntp/include/isc/mem.h index f8e73d0e7..ba1bfeb0e 100644 --- a/contrib/ntp/include/isc/mem.h +++ b/contrib/ntp/include/isc/mem.h @@ -1,31 +1,68 @@ /* + * libntp local override of isc/mem.h to stub it out. + * + * include/isc is searched before any of the lib/isc include + * directories and should be used only for replacement NTP headers + * overriding headers of the same name under lib/isc. + * + * NOTE: this assumes the system malloc is thread-safe and does + * not use any normal lib/isc locking. + */ + +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1997-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: mem.h,v 1.58 2001/09/07 00:51:51 marka Exp $ */ +/* $Id: mem.h,v 1.78.120.3 2009/02/11 03:07:01 jinmei Exp $ */ #ifndef ISC_MEM_H #define ISC_MEM_H 1 #include + +#include +#include +#include #include +#include + +#include + + +#define ISC_MEM_UNUSED_ARG(a) ((void)(a)) + +#define isc_mem_allocate(c, cnt) isc_mem_get(c, cnt) +#define isc_mem_get(c, cnt) \ + ( ISC_MEM_UNUSED_ARG(c), emalloc(cnt) ) + +#define isc_mem_reallocate(c, mem, cnt) \ + ( ISC_MEM_UNUSED_ARG(c), erealloc((mem), cnt) ) + +#define isc_mem_put(c, mem, cnt) \ + ( ISC_MEM_UNUSED_ARG(cnt), isc_mem_free(c, (mem)) ) + +#define isc_mem_free(c, mem) \ + ( ISC_MEM_UNUSED_ARG(c), free(mem) ) + +#define isc_mem_strdup(c, str) \ + ( ISC_MEM_UNUSED_ARG(c), estrdup(str) ) -void * -isc_mem_get(isc_mem_t *, size_t); -void -isc_mem_put(isc_mem_t *, void *, size_t); +#define isc__mem_attach(src, ptgt) do { *(ptgt) = (src); } while (0) +#define isc__mem_detach(c) ISC_MEM_UNUSED_ARG(c) +#define isc__mem_printallactive(s) fprintf((s), \ + "isc_mem_printallactive() stubbed.\n") #endif /* ISC_MEM_H */ diff --git a/contrib/ntp/include/isc/msgs.h b/contrib/ntp/include/isc/msgs.h deleted file mode 100644 index 967005bf3..000000000 --- a/contrib/ntp/include/isc/msgs.h +++ /dev/null @@ -1,183 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 2000-2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: msgs.h,v 1.5.2.2.8.3 2004/03/06 08:14:44 marka Exp $ */ - -#ifndef ISC_MSGS_H -#define ISC_MSGS_H 1 - -#include /* Provide isc_msgcat global variable. */ -#include /* Provide isc_msgcat_*() functions. */ - -/* - * Message sets, named per source file, excepting "GENERAL". - * IMPORTANT: The original list is alphabetical, but any new sets must - * be added to the end. - */ -#define ISC_MSGSET_GENERAL 1 -/* ISC_RESULT_RESULTSET 2 */ /* XXX */ -/* ISC_RESULT_UNAVAILABLESET 3 */ /* XXX */ -#define ISC_MSGSET_APP 4 -#define ISC_MSGSET_COMMANDLINE 5 -#define ISC_MSGSET_ENTROPY 6 -#define ISC_MSGSET_IFITERIOCTL 7 -#define ISC_MSGSET_IFITERSYSCTL 8 -#define ISC_MSGSET_LEX 9 -#define ISC_MSGSET_LOG 10 -#define ISC_MSGSET_MEM 11 -#define ISC_MSGSET_NETADDR 12 -#define ISC_MSGSET_PRINT 13 -#define ISC_MSGSET_RESULT 14 -#define ISC_MSGSET_RWLOCK 15 -#define ISC_MSGSET_SOCKADDR 16 -#define ISC_MSGSET_SOCKET 17 -#define ISC_MSGSET_TASK 18 -#define ISC_MSGSET_TIMER 19 -#define ISC_MSGSET_UTIL 20 -#define ISC_MSGSET_IFITERGETIFADDRS 21 - -/* - * Message numbers. They are only required to be unique per message set, - * but are unique throughout the entire catalog to not be as confusing when - * debugging. - * - * The initial numbering was done by multiply by 100 the set number the - * message appears in then adding the incremental message number. - */ -#define ISC_MSG_FAILED 101 /* "failed" */ -#define ISC_MSG_SUCCEEDED 102 /* Compatible with "failed" */ -#define ISC_MSG_SUCCESS 103 /* More usual way to say "success" */ -#define ISC_MSG_STARTING 104 /* As in "daemon: starting" */ -#define ISC_MSG_STOPING 105 /* As in "daemon: stopping" */ -#define ISC_MSG_ENTERING 106 /* As in "some_subr: entering" */ -#define ISC_MSG_EXITING 107 /* As in "some_subr: exiting" */ -#define ISC_MSG_CALLING 108 /* As in "calling some_subr()" */ -#define ISC_MSG_RETURNED 109 /* As in "some_subr: returned " */ -#define ISC_MSG_FATALERROR 110 /* "fatal error" */ -#define ISC_MSG_SHUTTINGDOWN 111 /* "shutting down" */ -#define ISC_MSG_RUNNING 112 /* "running" */ -#define ISC_MSG_WAIT 113 /* "wait" */ -#define ISC_MSG_WAITUNTIL 114 /* "waituntil" */ - -#define ISC_MSG_SIGNALSETUP 201 /* "handle_signal() %d setup: %s" */ - -#define ISC_MSG_ILLEGALOPT 301 /* "illegal option" */ -#define ISC_MSG_OPTNEEDARG 302 /* "option requires an argument" */ - -#define ISC_MSG_ENTROPYSTATS 401 /* "Entropy pool %p: refcnt %u ..." */ - -#define ISC_MSG_MAKESCANSOCKET 501 /* "making interface scan socket: %s" */ -#define ISC_MSG_GETIFCONFIG 502 /* "get interface configuration: %s" */ -#define ISC_MSG_BUFFERMAX 503 /* "... maximum buffer size exceeded" */ -#define ISC_MSG_GETDESTADDR 504 /* "%s: getting destination address: %s" */ -#define ISC_MSG_GETNETMASK 505 /* "%s: getting netmask: %s" */ - -#define ISC_MSG_GETIFLISTSIZE 601 /* "getting interface list size: ..." */ -#define ISC_MSG_GETIFLIST 602 /* "getting interface list: ..." */ -#define ISC_MSG_UNEXPECTEDTYPE 603 /* "... unexpected ... message type" */ - -#define ISC_MSG_UNEXPECTEDSTATE 701 /* "Unexpected state %d" */ - -#define ISC_MSG_BADTIME 801 /* "Bad 00 99:99:99.999 " */ -#define ISC_MSG_LEVEL 802 /* "level %d: " */ - -#define ISC_MSG_ADDTRACE 901 /* "add %p size %u " */ -#define ISC_MSG_DELTRACE 902 /* "del %p size %u " */ -#define ISC_MSG_POOLSTATS 903 /* "[Pool statistics]\n" */ -#define ISC_MSG_POOLNAME 904 /* "name" */ -#define ISC_MSG_POOLSIZE 905 /* "size" */ -#define ISC_MSG_POOLMAXALLOC 906 /* "maxalloc" */ -#define ISC_MSG_POOLALLOCATED 907 /* "allocated" */ -#define ISC_MSG_POOLFREECOUNT 908 /* "freecount" */ -#define ISC_MSG_POOLFREEMAX 909 /* "freemax" */ -#define ISC_MSG_POOLFILLCOUNT 910 /* "fillcount" */ -#define ISC_MSG_POOLGETS 911 /* "gets" */ -#define ISC_MSG_DUMPALLOC 912 /* "DUMP OF ALL OUTSTANDING MEMORY ..." */ -#define ISC_MSG_NONE 913 /* "\tNone.\n" */ -#define ISC_MSG_PTRFILELINE 914 /* "\tptr %p file %s line %u\n" */ - -#define ISC_MSG_UNKNOWNADDR 1001 /* "" */ - -#define ISC_MSG_NOLONGDBL 1104 /* "long doubles are not supported" */ - -#define ISC_MSG_PRINTLOCK 1201 /* "rwlock %p thread %lu ..." */ -#define ISC_MSG_READ 1202 /* "read" */ -#define ISC_MSG_WRITE 1203 /* "write" */ -#define ISC_MSG_READING 1204 /* "reading" */ -#define ISC_MSG_WRITING 1205 /* "writing" */ -#define ISC_MSG_PRELOCK 1206 /* "prelock" */ -#define ISC_MSG_POSTLOCK 1207 /* "postlock" */ -#define ISC_MSG_PREUNLOCK 1208 /* "preunlock" */ -#define ISC_MSG_POSTUNLOCK 1209 /* "postunlock" */ - -#define ISC_MSG_UNKNOWNFAMILY 1301 /* "unknown address family: %d" */ - -#define ISC_MSG_WRITEFAILED 1401 /* "write() failed during watcher ..." */ -#define ISC_MSG_READFAILED 1402 /* "read() failed during watcher ... " */ -#define ISC_MSG_PROCESSCMSG 1403 /* "processing cmsg %p" */ -#define ISC_MSG_IFRECEIVED 1404 /* "interface received on ifindex %u" */ -#define ISC_MSG_SENDTODATA 1405 /* "sendto pktinfo data, ifindex %u" */ -#define ISC_MSG_DOIORECV 1406 /* "doio_recv: recvmsg(%d) %d bytes ..." */ -#define ISC_MSG_PKTRECV 1407 /* "packet received correctly" */ -#define ISC_MSG_DESTROYING 1408 /* "destroying" */ -#define ISC_MSG_CREATED 1409 /* "created" */ -#define ISC_MSG_ACCEPTLOCK 1410 /* "internal_accept called, locked ..." */ -#define ISC_MSG_ACCEPTEDCXN 1411 /* "accepted connection, new socket %p" */ -#define ISC_MSG_INTERNALRECV 1412 /* "internal_recv: task %p got event %p" */ -#define ISC_MSG_INTERNALSEND 1413 /* "internal_send: task %p got event %p" */ -#define ISC_MSG_WATCHERMSG 1414 /* "watcher got message %d" */ -#define ISC_MSG_SOCKETSREMAIN 1415 /* "sockets exist" */ -#define ISC_MSG_PKTINFOPROVIDED 1416 /* "pktinfo structure provided, ..." */ -#define ISC_MSG_BOUND 1417 /* "bound" */ -#define ISC_MSG_ACCEPTRETURNED 1418 /* accept() returned %d/%s */ -#define ISC_MSG_TOOMANYFDS 1419 /* %s: too many open file descriptors */ -#define ISC_MSG_ZEROPORT 1420 /* dropping source port zero packet */ -#define ISC_MSG_FILTER 1420 /* setsockopt(SO_ACCEPTFILTER): %s */ - -#define ISC_MSG_AWAKE 1502 /* "awake" */ -#define ISC_MSG_WORKING 1503 /* "working" */ -#define ISC_MSG_EXECUTE 1504 /* "execute action" */ -#define ISC_MSG_EMPTY 1505 /* "empty" */ -#define ISC_MSG_DONE 1506 /* "done" */ -#define ISC_MSG_QUANTUM 1507 /* "quantum" */ - -#define ISC_MSG_SCHEDULE 1601 /* "schedule" */ -#define ISC_MSG_SIGNALSCHED 1602 /* "signal (schedule)" */ -#define ISC_MSG_SIGNALDESCHED 1603 /* "signal (deschedule)" */ -#define ISC_MSG_SIGNALDESTROY 1604 /* "signal (destroy)" */ -#define ISC_MSG_IDLERESCHED 1605 /* "idle reschedule" */ -#define ISC_MSG_EVENTNOTALLOC 1606 /* "couldn't allocate event" */ -#define ISC_MSG_SCHEDFAIL 1607 /* "couldn't schedule timer: %u" */ -#define ISC_MSG_POSTING 1608 /* "posting" */ -#define ISC_MSG_WAKEUP 1609 /* "wakeup" */ - -#define ISC_MSG_LOCK 1701 /* "LOCK" */ -#define ISC_MSG_LOCKING 1702 /* "LOCKING" */ -#define ISC_MSG_LOCKED 1703 /* "LOCKED" */ -#define ISC_MSG_UNLOCKED 1704 /* "UNLOCKED" */ -#define ISC_MSG_RWLOCK 1705 /* "RWLOCK" */ -#define ISC_MSG_RWLOCKED 1706 /* "RWLOCKED" */ -#define ISC_MSG_RWUNLOCK 1707 /* "RWUNLOCK" */ -#define ISC_MSG_BROADCAST 1708 /* "BROADCAST" */ -#define ISC_MSG_SIGNAL 1709 /* "SIGNAL" */ -#define ISC_MSG_UTILWAIT 1710 /* "WAIT" */ -#define ISC_MSG_WAITED 1711 /* "WAITED" */ - -#define ISC_MSG_GETIFADDRS 1801 /* "getting interface addresses: ..." */ - - -#endif /* ISC_MSGS_H */ diff --git a/contrib/ntp/include/isc/once.h b/contrib/ntp/include/isc/once.h deleted file mode 100644 index f57d6215f..000000000 --- a/contrib/ntp/include/isc/once.h +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: once.h,v 1.3 2001/01/09 21:57:56 bwelling Exp $ */ - -#ifndef ISC_ONCE_H -#define ISC_ONCE_H 1 - -#include - -typedef isc_boolean_t isc_once_t; - -#define ISC_ONCE_INIT ISC_FALSE - -#define isc_once_do(op, f) \ - (!*(op) ? (f(), *(op) = ISC_TRUE, ISC_R_SUCCESS) : ISC_R_SUCCESS) - -#endif /* ISC_ONCE_H */ diff --git a/contrib/ntp/include/isc/result.h b/contrib/ntp/include/isc/result.h deleted file mode 100644 index 93f7cefbd..000000000 --- a/contrib/ntp/include/isc/result.h +++ /dev/null @@ -1,106 +0,0 @@ -/* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") - * Copyright (C) 1998-2001, 2003 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH - * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY - * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM - * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE - * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR - * PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: result.h,v 1.57.2.2.8.5 2004/05/15 03:46:13 jinmei Exp $ */ - -#ifndef ISC_RESULT_H -#define ISC_RESULT_H 1 - -#include -#include - -#define ISC_R_SUCCESS 0 /* success */ -#define ISC_R_NOMEMORY 1 /* out of memory */ -#define ISC_R_TIMEDOUT 2 /* timed out */ -#define ISC_R_NOTHREADS 3 /* no available threads */ -#define ISC_R_ADDRNOTAVAIL 4 /* address not available */ -#define ISC_R_ADDRINUSE 5 /* address in use */ -#define ISC_R_NOPERM 6 /* permission denied */ -#define ISC_R_NOCONN 7 /* no pending connections */ -#define ISC_R_NETUNREACH 8 /* network unreachable */ -#define ISC_R_HOSTUNREACH 9 /* host unreachable */ -#define ISC_R_NETDOWN 10 /* network down */ -#define ISC_R_HOSTDOWN 11 /* host down */ -#define ISC_R_CONNREFUSED 12 /* connection refused */ -#define ISC_R_NORESOURCES 13 /* not enough free resources */ -#define ISC_R_EOF 14 /* end of file */ -#define ISC_R_BOUND 15 /* socket already bound */ -#define ISC_R_RELOAD 16 /* reload */ -#define ISC_R_LOCKBUSY 17 /* lock busy */ -#define ISC_R_EXISTS 18 /* already exists */ -#define ISC_R_NOSPACE 19 /* ran out of space */ -#define ISC_R_CANCELED 20 /* operation canceled */ -#define ISC_R_NOTBOUND 21 /* socket is not bound */ -#define ISC_R_SHUTTINGDOWN 22 /* shutting down */ -#define ISC_R_NOTFOUND 23 /* not found */ -#define ISC_R_UNEXPECTEDEND 24 /* unexpected end of input */ -#define ISC_R_FAILURE 25 /* generic failure */ -#define ISC_R_IOERROR 26 /* I/O error */ -#define ISC_R_NOTIMPLEMENTED 27 /* not implemented */ -#define ISC_R_UNBALANCED 28 /* unbalanced parentheses */ -#define ISC_R_NOMORE 29 /* no more */ -#define ISC_R_INVALIDFILE 30 /* invalid file */ -#define ISC_R_BADBASE64 31 /* bad base64 encoding */ -#define ISC_R_UNEXPECTEDTOKEN 32 /* unexpected token */ -#define ISC_R_QUOTA 33 /* quota reached */ -#define ISC_R_UNEXPECTED 34 /* unexpected error */ -#define ISC_R_ALREADYRUNNING 35 /* already running */ -#define ISC_R_IGNORE 36 /* ignore */ -#define ISC_R_MASKNONCONTIG 37 /* addr mask not contiguous */ -#define ISC_R_FILENOTFOUND 38 /* file not found */ -#define ISC_R_FILEEXISTS 39 /* file already exists */ -#define ISC_R_NOTCONNECTED 40 /* socket is not connected */ -#define ISC_R_RANGE 41 /* out of range */ -#define ISC_R_NOENTROPY 42 /* out of entropy */ -#define ISC_R_MULTICAST 43 /* invalid use of multicast */ -#define ISC_R_NOTFILE 44 /* not a file */ -#define ISC_R_NOTDIRECTORY 45 /* not a directory */ -#define ISC_R_QUEUEFULL 46 /* queue is full */ -#define ISC_R_FAMILYMISMATCH 47 /* address family mismatch */ -#define ISC_R_FAMILYNOSUPPORT 48 /* AF not supported */ -#define ISC_R_BADHEX 49 /* bad hex encoding */ -#define ISC_R_TOOMANYOPENFILES 50 /* too many open files */ -#define ISC_R_NOTBLOCKING 51 /* not blocking */ -#define ISC_R_UNBALANCEDQUOTES 52 /* unbalanced quotes */ -#define ISC_R_INPROGRESS 53 /* operation in progress */ -#define ISC_R_CONNECTIONRESET 54 /* connection reset */ -#define ISC_R_SOFTQUOTA 55 /* soft quota reached */ -#define ISC_R_BADNUMBER 56 /* not a valid number */ -#define ISC_R_DISABLED 57 /* disabled */ -#define ISC_R_MAXSIZE 58 /* max size */ -#define ISC_R_BADADDRESSFORM 59 /* invalid address format */ - -/* - * Not a result code: the number of results. - */ -#define ISC_R_NRESULTS 60 - -ISC_LANG_BEGINDECLS - -const char * -isc_result_totext(isc_result_t); -/* - * Convert an isc_result_t into a string message describing the result. - */ - -isc_result_t -isc_result_register(unsigned int base, unsigned int nresults, - const char **text, isc_msgcat_t *msgcat, int set); - -ISC_LANG_ENDDECLS - -#endif /* ISC_RESULT_H */ diff --git a/contrib/ntp/include/isc/strerror.h b/contrib/ntp/include/isc/strerror.h deleted file mode 100644 index ca428af95..000000000 --- a/contrib/ntp/include/isc/strerror.h +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (C) 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: strerror.h,v 1.3 2001/11/20 01:45:47 gson Exp $ */ - -#ifndef ISC_STRERROR_H -#define ISC_STRERROR_H - -#include - -#include - -ISC_LANG_BEGINDECLS - -#define ISC_STRERRORSIZE 128 - -/* - * Provide a thread safe wrapper to strerrror(). - * - * Requires: - * 'buf' to be non NULL. - */ -void -isc__strerror(int num, char *buf, size_t bufsize); - -ISC_LANG_ENDDECLS - -#endif /* ISC_STRERROR_H */ diff --git a/contrib/ntp/include/isc/string.h b/contrib/ntp/include/isc/string.h deleted file mode 100644 index e16219fda..000000000 --- a/contrib/ntp/include/isc/string.h +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright (C) 2000, 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: string.h,v 1.9 2001/01/09 21:57:37 bwelling Exp $ */ - -#ifndef ISC_STRING_H -#define ISC_STRING_H 1 - -#include - -#include -#include -#include - -ISC_LANG_BEGINDECLS - -isc_uint64_t -isc_string_touint64(char *source, char **endp, int base); -/* - * Convert the string pointed to by 'source' to isc_uint64_t. - * - * On successful conversion 'endp' points to the first character - * after conversion is complete. - * - * 'base': 0 or 2..36 - * - * If base is 0 the base is computed from the string type. - * - * On error 'endp' points to 'source'. - */ - - -char * -isc_string_separate(char **stringp, const char *delim); - -#ifdef ISC_PLATFORM_NEEDSTRSEP -#define strsep isc_string_separate -#endif - -ISC_LANG_ENDDECLS - -#endif /* ISC_STRING_H */ diff --git a/contrib/ntp/include/isc/types.h b/contrib/ntp/include/isc/types.h deleted file mode 100644 index b30f55ee7..000000000 --- a/contrib/ntp/include/isc/types.h +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright (C) 1999-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: types.h,v 1.33 2002/07/19 03:39:44 marka Exp $ */ - -#ifndef ISC_TYPES_H -#define ISC_TYPES_H 1 - -/* - * OS-specific types, from the OS-specific include directories. - */ -#include -#include - -/* - * XXXDCL should isc_boolean_t be moved here, requiring an explicit include - * of when ISC_TRUE/ISC_FALSE/ISC_TF() are desired? - */ -#include -/* - * XXXDCL This is just for ISC_LIST and ISC_LINK, but gets all of the other - * list macros too. - */ -#include - -/*** - *** Core Types. Alphabetized by defined type. - ***/ - -typedef struct isc_bitstring isc_bitstring_t; -typedef struct isc_buffer isc_buffer_t; -typedef ISC_LIST(isc_buffer_t) isc_bufferlist_t; -typedef struct isc_constregion isc_constregion_t; -typedef struct isc_consttextregion isc_consttextregion_t; -typedef struct isc_entropy isc_entropy_t; -typedef struct isc_entropysource isc_entropysource_t; -typedef struct isc_event isc_event_t; -typedef ISC_LIST(isc_event_t) isc_eventlist_t; -typedef unsigned int isc_eventtype_t; -typedef isc_uint32_t isc_fsaccess_t; -typedef struct isc_interface isc_interface_t; -typedef struct isc_interfaceiter isc_interfaceiter_t; -typedef struct isc_interval isc_interval_t; -typedef struct isc_lex isc_lex_t; -typedef struct isc_log isc_log_t; -typedef struct isc_logcategory isc_logcategory_t; -typedef struct isc_logconfig isc_logconfig_t; -typedef struct isc_logmodule isc_logmodule_t; -typedef struct isc_mem isc_mem_t; -typedef struct isc_mempool isc_mempool_t; -typedef struct isc_msgcat isc_msgcat_t; -typedef struct isc_ondestroy isc_ondestroy_t; -typedef struct isc_netaddr isc_netaddr_t; -typedef struct isc_quota isc_quota_t; -typedef struct isc_random isc_random_t; -typedef struct isc_ratelimiter isc_ratelimiter_t; -typedef struct isc_region isc_region_t; -typedef isc_uint64_t isc_resourcevalue_t; -typedef unsigned int isc_result_t; -typedef struct isc_rwlock isc_rwlock_t; -typedef struct isc_sockaddr isc_sockaddr_t; -typedef struct isc_socket isc_socket_t; -typedef struct isc_socketevent isc_socketevent_t; -typedef struct isc_socketmgr isc_socketmgr_t; -typedef struct isc_symtab isc_symtab_t; -typedef struct isc_task isc_task_t; -typedef ISC_LIST(isc_task_t) isc_tasklist_t; -typedef struct isc_taskmgr isc_taskmgr_t; -typedef struct isc_textregion isc_textregion_t; -typedef struct isc_time isc_time_t; -typedef struct isc_timer isc_timer_t; -typedef struct isc_timermgr isc_timermgr_t; - -typedef void (*isc_taskaction_t)(isc_task_t *, isc_event_t *); - -typedef enum { - isc_resource_coresize = 1, - isc_resource_cputime, - isc_resource_datasize, - isc_resource_filesize, - isc_resource_lockedmemory, - isc_resource_openfiles, - isc_resource_processes, - isc_resource_residentsize, - isc_resource_stacksize -} isc_resource_t; - -#endif /* ISC_TYPES_H */ diff --git a/contrib/ntp/include/l_stdlib.h b/contrib/ntp/include/l_stdlib.h index 58bbeedc2..073ea4641 100644 --- a/contrib/ntp/include/l_stdlib.h +++ b/contrib/ntp/include/l_stdlib.h @@ -3,26 +3,15 @@ * This is optional */ -#ifndef _l_stdlib_h -#define _l_stdlib_h - -#ifdef HAVE_CONFIG_H -#include -#endif +#ifndef L_STDLIB_H +#define L_STDLIB_H #ifdef HAVE_STDLIB_H # include #endif -#if defined(__STDC__) || defined(HAVE_STDARG_H) -# include -#else -# include -#endif - -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include +#include /* Needed for speed_t. */ #ifdef HAVE_TERMIOS_H @@ -40,195 +29,185 @@ #ifdef DECL_ADJTIME_0 struct timeval; -extern int adjtime P((struct timeval *, struct timeval *)); +extern int adjtime (struct timeval *, struct timeval *); #endif #ifdef DECL_BCOPY_0 #ifndef bcopy -extern void bcopy P((const char *, char *, int)); +extern void bcopy (const char *, char *, int); #endif #endif #ifdef DECL_BZERO_0 #ifndef bzero -extern void bzero P((char *, int)); +extern void bzero (char *, int); #endif #endif #ifdef DECL_CFSETISPEED_0 struct termios; -extern int cfsetispeed P((struct termios *, speed_t)); -extern int cfsetospeed P((struct termios *, speed_t)); +extern int cfsetispeed (struct termios *, speed_t); +extern int cfsetospeed (struct termios *, speed_t); #endif -extern char * getpass P((const char *)); +extern char * getpass (const char *); #ifdef DECL_HSTRERROR_0 -extern const char * hstrerror P((int)); +extern const char * hstrerror (int); #endif #ifdef DECL_INET_NTOA_0 struct in_addr; -extern char * inet_ntoa P((struct in_addr)); +extern char * inet_ntoa (struct in_addr); #endif #ifdef DECL_IOCTL_0 -extern int ioctl P((int, u_long, char *)); +extern int ioctl (int, u_long, char *); #endif #ifdef DECL_IPC_0 struct sockaddr; -extern int bind P((int, struct sockaddr *, int)); -extern int connect P((int, struct sockaddr *, int)); -extern int recv P((int, char *, int, int)); -extern int recvfrom P((int, char *, int, int, struct sockaddr *, int *)); -extern int send P((int, char *, int, int)); -extern int sendto P((int, char *, int, int, struct sockaddr *, int)); -extern int setsockopt P((int, int, int, char *, int)); -extern int socket P((int, int, int)); +extern int bind (int, struct sockaddr *, int); +extern int connect (int, struct sockaddr *, int); +extern int recv (int, char *, int, int); +extern int recvfrom (int, char *, int, int, struct sockaddr *, int *); +extern int send (int, char *, int, int); +extern int sendto (int, char *, int, int, struct sockaddr *, int); +extern int setsockopt (int, int, int, char *, int); +extern int socket (int, int, int); #endif #ifdef DECL_MEMMOVE_0 -extern void * memmove P((void *, const void *, size_t)); +extern void * memmove (void *, const void *, size_t); #endif #ifdef DECL_MEMSET_0 -extern char * memset P((char *, int, int)); +extern char * memset (char *, int, int); #endif #ifdef DECL_MKSTEMP_0 -extern int mkstemp P((char *)); +extern int mkstemp (char *); #endif #ifdef DECL_MKTEMP_0 -extern char *mktemp P((char *)); +extern char *mktemp (char *); #endif #ifdef DECL_NLIST_0 struct nlist; -extern int nlist P((const char *, struct nlist *)); +extern int nlist (const char *, struct nlist *); #endif #ifdef DECL_PLOCK_0 -extern int plock P((int)); +extern int plock (int); #endif #ifdef DECL_RENAME_0 -extern int rename P((const char *, const char *)); +extern int rename (const char *, const char *); #endif #ifdef DECL_SELECT_0 -#ifdef _ntp_select_h -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); +#ifdef NTP_SELECT_H +extern int select (int, fd_set *, fd_set *, fd_set *, struct timeval *); #endif #endif #ifdef DECL_SETITIMER_0 struct itimerval; -extern int setitimer P((int , struct itimerval *, struct itimerval *)); +extern int setitimer (int , struct itimerval *, struct itimerval *); #endif #ifdef PRIO_PROCESS #ifdef DECL_SETPRIORITY_0 -extern int setpriority P((int, int, int)); +extern int setpriority (int, int, int); #endif #ifdef DECL_SETPRIORITY_1 -extern int setpriority P((int, id_t, int)); +extern int setpriority (int, id_t, int); #endif #endif #ifdef DECL_SIGVEC_0 struct sigvec; -extern int sigvec P((int, struct sigvec *, struct sigvec *)); -#endif - -#ifndef HAVE_SNPRINTF -/* PRINTFLIKE3 */ -extern int snprintf P((char *, size_t, const char *, ...)); -#endif - -/* HMS: does this need further protection? */ -#ifndef HAVE_VSNPRINTF -extern int vsnprintf P((char *, size_t, const char *, va_list)); +extern int sigvec (int, struct sigvec *, struct sigvec *); #endif #ifdef DECL_STDIO_0 #if defined(FILE) || defined(BUFSIZ) -extern int _flsbuf P((int, FILE *)); -extern int _filbuf P((FILE *)); -extern int fclose P((FILE *)); -extern int fflush P((FILE *)); -extern int fprintf P((FILE *, const char *, ...)); -extern int fscanf P((FILE *, const char *, ...)); -extern int fputs P((const char *, FILE *)); -extern int fputc P((int, FILE *)); -extern int fread P((char *, int, int, FILE *)); -extern void perror P((const char *)); -extern int printf P((const char *, ...)); -extern int setbuf P((FILE *, char *)); +extern int _flsbuf (int, FILE *); +extern int _filbuf (FILE *); +extern int fclose (FILE *); +extern int fflush (FILE *); +extern int fprintf (FILE *, const char *, ...); +extern int fscanf (FILE *, const char *, ...); +extern int fputs (const char *, FILE *); +extern int fputc (int, FILE *); +extern int fread (char *, int, int, FILE *); +extern void perror (const char *); +extern int printf (const char *, ...); +extern int setbuf (FILE *, char *); # ifdef HAVE_SETLINEBUF -extern int setlinebuf P((FILE *)); +extern int setlinebuf (FILE *); # endif -extern int setvbuf P((FILE *, char *, int, int)); -extern int scanf P((const char *, ...)); -extern int sscanf P((const char *, const char *, ...)); -extern int vfprintf P((FILE *, const char *, ...)); -extern int vsprintf P((char *, const char *, ...)); +extern int setvbuf (FILE *, char *, int, int); +extern int scanf (const char *, ...); +extern int sscanf (const char *, const char *, ...); +extern int vfprintf (FILE *, const char *, ...); +extern int vsprintf (char *, const char *, ...); #endif #endif #ifdef DECL_STIME_0 -extern int stime P((const time_t *)); +extern int stime (const time_t *); #endif #ifdef DECL_STIME_1 -extern int stime P((long *)); +extern int stime (long *); #endif #ifdef DECL_STRERROR_0 -extern char * strerror P((int errnum)); +extern char * strerror (int errnum); #endif #ifdef DECL_STRTOL_0 -extern long strtol P((const char *, char **, int)); +extern long strtol (const char *, char **, int); #endif #ifdef DECL_SYSCALL -extern int syscall P((int, ...)); +extern int syscall (int, ...); #endif #ifdef DECL_SYSLOG_0 -extern void closelog P((void)); +extern void closelog (void); #ifndef LOG_DAEMON -extern void openlog P((const char *, int)); +extern void openlog (const char *, int); #else -extern void openlog P((const char *, int, int)); +extern void openlog (const char *, int, int); #endif -extern int setlogmask P((int)); -extern void syslog P((int, const char *, ...)); +extern int setlogmask (int); +extern void syslog (int, const char *, ...); #endif #ifdef DECL_TIME_0 -extern time_t time P((time_t *)); +extern time_t time (time_t *); #endif #ifdef DECL_TIMEOFDAY_0 #ifdef SYSV_TIMEOFDAY -extern int gettimeofday P((struct timeval *)); -extern int settimeofday P((struct timeval *)); +extern int gettimeofday (struct timeval *); +extern int settimeofday (struct timeval *); #else /* not SYSV_TIMEOFDAY */ struct timezone; -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, void *)); +extern int gettimeofday (struct timeval *, struct timezone *); +extern int settimeofday (struct timeval *, void *); #endif /* not SYSV_TIMEOFDAY */ #endif #ifdef DECL_TOLOWER_0 -extern int tolower P((int)); +extern int tolower (int); #endif #ifdef DECL_TOUPPER_0 -extern int toupper P((int)); +extern int toupper (int); #endif /* @@ -242,265 +221,4 @@ extern int errno; extern int h_errno; #endif -/*******************************************************/ - -#if 0 -/* - * Unprotoyped library functions for SunOS 4.x.x - */ -#ifdef SYS_SUNOS4 -extern void closelog P((void)); -extern void openlog P((char *, int, int)); -extern void syslog P((int, char *, ...)); -extern int setlogmask P((int)); - -extern char * getpass P((char *)); - -extern int setpriority P((int ,int ,int)); - -extern long strtol P((char *, char **, int)); - -#if !defined(NTP_POSIX_SOURCE) -extern int atoi P((char *)); -extern int dup2 P((int, int)); -extern int execve P((char *, char **,char **)); -extern int fork P((void)); -extern int getdtablesize P((void)); -extern int qsort (void *, int , int, - int P((*compar)(void *, void *))); -extern int setpgrp P((int, int)); -extern void bcopy P((const char *, char *, int)); -#endif - -#ifndef bzero /* XXX macro prototyping clash */ -extern void bzero P((char *, int)); -extern int bcmp P((char *, char *, int)); -extern void bcopy P((const char *, char *, int)); -#endif -extern char *mktemp P((char *)); - -extern int tolower P((int)); - -extern int isatty P((int)); - -extern unsigned sleep P((unsigned )); -extern unsigned int alarm P((unsigned int)); -extern int pause P((void)); - -extern int getpid P((void)); -extern int getppid P((void)); - -extern int close P((int)); -extern int ioctl P((int, int, char *)); -extern int rename P((char *, char *)); -#if 0 -extern int read P((int, void *, size_t)); -extern int write P((int, const void *, size_t)); -#endif -extern int unlink P((const char *)); -extern int link P((const char *, const char *)); - -#ifdef FILE -extern int fclose P((FILE *)); -extern int fflush P((FILE *)); -extern int fprintf P((FILE *, char *, ...)); -extern int fscanf P((FILE *, char *, ...)); -extern int fputs P((char *, FILE *)); -extern int fputc P((char, FILE *)); -extern int fread P((char *, int, int, FILE *)); -extern int printf P((char *, ...)); -extern int setbuf P((FILE *, char *)); -extern int setvbuf P((FILE *, char *, int, int)); -extern int scanf P((char *, ...)); -extern int sscanf P((char *, char *, ...)); -extern int vsprintf P((char *, char *, ...)); -extern int _flsbuf P((int, FILE *)); -extern int _filbuf P((FILE *)); -extern void perror P((char *)); -#ifdef HAVE_SETLINEBUF -extern int setlinebuf P((FILE *)); -#endif -#endif - -#ifdef _ntp_string_h -#ifdef NTP_POSIX_SOURCE /* these are builtins */ -#ifndef NTP_NEED_BOPS /* but may be emulated by bops */ -extern char *memcpy P(()); -extern char *memset P(()); -extern int memcmp P(()); -#endif -#endif -#endif - -#ifdef _sys_socket_h -extern int bind P((int, struct sockaddr *, int)); -extern int connect P((int, struct sockaddr *, int)); -extern int sendto P((int, char *, int, int, struct sockaddr *, int)); -extern int setsockopt P((int, int, int, char *, int)); -extern int socket P((int, int, int)); -extern int recvfrom P((int, char *, int, int, struct sockaddr *, int *)); -#endif /* _sys_socket_h */ - -#ifdef _ntp_select_h -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); -#endif - -#ifdef _sys_time_h -extern int adjtime P((struct timeval *, struct timeval *)); -extern int setitimer P((int , struct itimerval *, struct itimerval *)); -#ifdef SYSV_TIMEOFDAY -extern int gettimeofday P((struct timeval *)); -extern int settimeofday P((struct timeval *)); -#else /* ! SYSV_TIMEOFDAY */ -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, struct timezone *)); -#endif /* SYSV_TIMEOFDAY */ -#endif /* _sys_time_h */ - -#ifdef __time_h -extern time_t time P((time_t *)); -#endif - -#ifdef __setjmp_h -extern int setjmp P((jmp_buf)); -extern void longjmp P((jmp_buf, int)); -#endif - -#ifdef _sys_resource_h -extern int getrusage P((int, struct rusage *)); -#endif - -#ifdef _nlist_h -extern int nlist P((char *, struct nlist *)); -#endif - -#endif /* SYS_SUNOS4 */ - -/* - * Unprototyped library functions for DEC OSF/1 - */ -#ifdef SYS_DECOSF1 -#ifndef _MACHINE_ENDIAN_H_ -#define _MACHINE_ENDIAN_H_ -extern u_short htons P((u_short)); -extern u_short ntohs P((u_short)); -extern u_int32 htonl P((u_int32)); -extern u_int32 ntohl P((u_int32)); -#endif /* _MACHINE_ENDIAN_H_ */ - -/* -extern char * getpass P((char *)); -*/ -extern char * mktemp P((char *)); -#ifndef SYS_IX86OSF1 -extern int ioctl P((int, u_long, char *)); -extern void bzero P((char *, int)); -#endif - -#ifdef SOCK_DGRAM -extern int bind P((int, const struct sockaddr *, int)); -extern int connect P((int, const struct sockaddr *, int)); -extern int socket P((int, int, int)); -extern int sendto P((int, const void *, int, int, const struct sockaddr *, int)); -extern int setsockopt P((int, int, int, const void *, int)); -extern int recvfrom P((int, void *, int, int, struct sockaddr *, int *)); -#endif /* SOCK_STREAM */ - -#ifdef _ntp_select_h -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); -#endif - -#endif /* DECOSF1 */ - -/* - * Unprototyped library functions for Ultrix - */ -#ifdef SYS_ULTRIX -extern int close P((int)); -extern char * getpass P((char *)); -extern int getpid P((void)); -extern int ioctl P((int, int, char *)); -extern char *mktemp P((char *)); -extern int unlink P((const char *)); -extern int link P((const char *, const char *)); - -extern void closelog P((void)); -extern void syslog P((int, char *, ...)); -#ifndef LOG_DAEMON -extern void openlog P((char *, int)); -#else -extern void openlog P((char *, int, int)); -#endif - -extern int setpriority P((int ,int ,int )); - -#ifdef SOCK_DGRAM -extern int bind P((int, struct sockaddr *, int)); -extern int connect P((int, struct sockaddr *, int)); -extern int socket P((int, int, int)); -extern int sendto P((int, char *, int, int, struct sockaddr *, int)); -extern int setsockopt P((int, int, int, char *, int)); -extern int recvfrom P((int, char *, int, int, struct sockaddr *, int *)); -#endif /* SOCK_STREAM */ - -#ifdef _TIME_H_ -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, struct timezone *)); -extern int adjtime P((struct timeval *, struct timeval *)); -extern int select P((int, fd_set *, fd_set *, fd_set *, struct timeval *)); -extern int setitimer P((int , struct itimerval *, struct itimerval *)); -#endif /* _TIME_H_ */ - -#ifdef N_UNDF -extern int nlist P((char *, struct nlist *)); -#endif - -#ifndef bzero /* XXX macro prototyping clash */ -extern void bzero P((char *, int)); -extern int bcmp P((char *, char *, int)); -extern void bcopy P((const char *, char *, int)); -#endif - -#ifndef NTP_POSIX_SOURCE -extern int atoi P((char *)); -extern void bzero P((char *, int)); -extern int bcmp P((char *, char *, int)); -extern void bcopy P((const char *, char *, int)); -extern int execve P((char *, char **,char **)); -extern int fork P((void)); -extern int getdtablesize P((void)); -extern int ran P((void)); -#ifdef _TIME_H_ -extern int gettimeofday P((struct timeval *, struct timezone *)); -extern int settimeofday P((struct timeval *, struct timezone *)); -#endif -#endif - -#ifdef _RESOURCE_H_ -extern int getrusage P((int, struct rusage *)); -#endif - -#endif /* SYS_ULTRIX */ - -#if defined(__convex__) -extern char * getpass P((char *)); -#endif - -#ifdef SYS_IRIX4 -extern char * getpass P((char *)); -#endif /* IRIX4 */ - -#ifdef SYS_VAX -extern char * getpass P((char *)); -#endif /* VAX */ - -#ifdef SYS_DOMAINOS -extern char * getpass P((char *)); -#endif /* SYS_DOMAINOS */ - -#ifdef SYS_BSD -#define IN_CLASSD(i) (((long)(i) & 0xf0000000) == 0xe0000000) -#endif - -#endif /* 0 */ -#endif /* l_stdlib_h */ +#endif /* L_STDLIB_H */ diff --git a/contrib/ntp/include/lib_strbuf.h b/contrib/ntp/include/lib_strbuf.h new file mode 100644 index 000000000..5ee92d6f8 --- /dev/null +++ b/contrib/ntp/include/lib_strbuf.h @@ -0,0 +1,32 @@ +/* + * lib_strbuf.h - definitions for routines which use the common string buffers + */ +#ifndef LIB_STRBUF_H +#define LIB_STRBUF_H + +#include +#include /* for ZERO() */ + +/* + * Sizes of things + */ +#define LIB_NUMBUF 16 +#define LIB_BUFLENGTH 128 + +typedef char libbufstr[LIB_BUFLENGTH]; +extern libbufstr lib_stringbuf[LIB_NUMBUF]; +extern int lib_nextbuf; +extern int lib_inited; + + +/* + * Macro to get a pointer to the next buffer + */ +#define LIB_GETBUF(bufp) \ + do { \ + ZERO(lib_stringbuf[lib_nextbuf]); \ + (bufp) = &lib_stringbuf[lib_nextbuf++][0]; \ + lib_nextbuf %= COUNTOF(lib_stringbuf); \ + } while (FALSE) + +#endif /* LIB_STRBUF_H */ diff --git a/contrib/ntp/include/libntp.h b/contrib/ntp/include/libntp.h new file mode 100644 index 000000000..8d87c024f --- /dev/null +++ b/contrib/ntp/include/libntp.h @@ -0,0 +1,16 @@ +/* libntp.h */ + +#if defined(HAVE_SYSCONF) && defined(_SC_OPEN_MAX) +#define GETDTABLESIZE() ((int)sysconf(_SC_OPEN_MAX)) +#elif defined(HAVE_GETDTABLESIZE) +#define GETDTABLESIZE getdtablesize +#else +/* + * if we have no idea about the max fd value set up things + * so we will start at FOPEN_MAX + */ +#define GETDTABLESIZE() (FOPEN_MAX + FD_CHUNK) +#endif + +extern void make_socket_nonblocking( SOCKET fd ); +extern SOCKET move_fd( SOCKET fd ); diff --git a/contrib/ntp/include/mbg_gps166.h b/contrib/ntp/include/mbg_gps166.h index edaae9df2..b9b3d7783 100644 --- a/contrib/ntp/include/mbg_gps166.h +++ b/contrib/ntp/include/mbg_gps166.h @@ -39,206 +39,459 @@ #define MBG_GPS166_H -/***************************************************************************/ -/* */ -/* File: GPSSERIO.H 4.1 */ -/* */ -/* Project: Common C Library */ -/* */ -/* Compiler: Borland C++ */ -/* */ -/* Author: M. Burnicki, Meinberg Funkuhren */ -/* */ -/* */ -/* Description: */ -/* This file defines structures and codes to be used to access GPS166 */ -/* via its serial interface COM0. COM0 should be set to a high baud */ -/* rate, default is 19200. */ -/* */ -/* Standard GPS166 serial operation is to send a time string that is */ -/* compatible with Meinberg UA31 or PZF535 DCF77 radio remote clocks. */ -/* That string can be transmitted automatically once per second, once */ -/* per minute or on request per ASCII '?'. */ -/* */ -/* Parameter setup or parameter readout works using blocks of binary */ -/* data which have to be isolated from the standard string. A block of */ -/* data starts with a SOH code (ASCII Start Of Header, 0x01) followed */ -/* by a message header with constant length and a data portion with */ -/* variable length. The first field (cmd) of the message header holds */ -/* the command code rsp. the type of data to be transmitted. The next */ -/* field (len) gives the number of data bytes that are transmitted */ -/* after the header. This number ranges from 0 to sizeof( MSG_DATA ). */ -/* The third field (data_csum) holds a checksum of all data bytes and */ -/* the last field of the header finally holds the checksum of the. */ -/* header. */ -/* */ -/***************************************************************************/ - -/* the control codes defined below are to be or'ed with a command/type code */ - -#define GPS_REQACK 0x8000 /* to GPS166: request acknowledge */ -#define GPS_ACK 0x4000 /* from GPS166: acknowledge a command */ -#define GPS_NACK 0x2000 /* from GPS166: error receiving command */ - -#define GPS_CTRL_MSK 0xF000 /* masks control code from command */ - - -/* The codes below specify commands/types of data to be supplied to GPS166: */ - -/* GPS166 auto-message to host */ -/* þ host request, GPS166 response */ -/* þ þ host download to GPS166 */ -/* þ þ þ */ -enum { /* þ þ þ */ - /* system data */ - GPS_AUTO_ON = 0x000, /* þ þ þ X þ enable auto-messages from GPS166 */ - GPS_AUTO_OFF, /* þ þ þ X þ disable auto-messages from GPS166 */ - GPS_SW_REV, /* þ þ X þ þ request software revision */ - GPS_STAT, /* þ þ X þ þ request status of buffered variables */ - GPS_TIME, /* þ X þ þ X þ current time or capture or init board time */ - GPS_POS_XYZ, /* þ þ X þ X þ current position in ECEF coords */ - GPS_POS_LLA, /* þ þ X þ X þ current position in geographic coords */ - GPS_TZDL, /* þ þ X þ X þ time zone / daylight saving */ - GPS_PORT_PARM, /* þ þ X þ X þ parameters of the serial ports */ - GPS_SYNTH, /* þ þ X þ X þ synthesizer's frequency and phase */ - GPS_ANT_INFO, /* þ X þ X þ þ time diff after antenna disconnect */ - GPS_UCAP, /* þ X þ X þ þ user capture */ +/*************************************************************************** + * + * Definitions taken from Meinberg's gpsserio.h and gpsdefs.h files. + * + * Author: Martin Burnicki, Meinberg Funkuhren + * + * Copyright (c) Meinberg Funkuhren, Bad Pyrmont, Germany + * + * Description: + * Structures and codes to be used to access Meinberg GPS clocks via + * their serial interface COM0. COM0 should be set to a high baud rate, + * default is 19200. + * + * Standard Meinberg GPS serial operation is to send the Meinberg + * standard time string automatically once per second, once per + * minute, or on request per ASCII '?'. + * + * GPS parameter setup or parameter readout uses blocks of binary + * data which have to be isolated from the standard string. A block + * of data starts with a SOH code (ASCII Start Of Header, 0x01) + * followed by a message header with constant length and a block of + * data with variable length. + * + * The first field (cmd) of the message header holds the command + * code resp. the type of data to be transmitted. The next field (len) + * gives the number of data bytes that follow the header. This number + * ranges from 0 to sizeof( MSG_DATA ). The third field (data_csum) + * holds a checksum of all data bytes and the last field of the header + * finally holds the checksum of the header itself. + * + ***************************************************************************/ + +/** + * @brief GPS epoch bias from ordinary time_t epoch + * + * The Unix time_t epoch is usually 1970-01-01 00:00 whereas + * the GPS epoch is 1980-01-06 00:00, so the difference is 10 years, + * plus 2 days due to leap years (1972 and 1976), plus the difference + * of the day-of-month (6 - 1), so:
      + * + * time_t t = ( gps_week * ::SECS_PER_WEEK ) + sec_of_week + ::GPS_SEC_BIAS + */ +#define GPS_SEC_BIAS 315964800UL // ( ( ( 10UL * 365UL ) + 2 + 5 ) * SECS_PER_DAY ) + + +#ifndef _COM_HS_DEFINED + /** + * @brief Enumeration of handshake modes + */ + enum COM_HANSHAKE_MODES { HS_NONE, HS_XONXOFF, HS_RTSCTS, N_COM_HS }; + #define _COM_HS_DEFINED +#endif + +#ifndef _COM_PARM_DEFINED + /** + * @brief A data type to configure a serial port's baud rate + * + * @see ::MBG_BAUD_RATES + */ + typedef int32_t BAUD_RATE; + + /** + * @brief Indices used to identify a parameter in the framing string + * + * @see ::MBG_FRAMING_STRS + */ + enum MBG_FRAMING_STR_IDXS { F_DBITS, F_PRTY, F_STBITS }; + + /** + * @brief A structure to store the configuration of a serial port + */ + typedef struct + { + BAUD_RATE baud_rate; ///< transmission speed, e.g. 19200L, see ::MBG_BAUD_RATES + char framing[4]; ///< ASCIIZ framing string, e.g. "8N1" or "7E2", see ::MBG_FRAMING_STRS + int16_t handshake; ///< handshake mode, yet only ::HS_NONE supported + + } COM_PARM; + + #define _COM_PARM_DEFINED +#endif + + +/** + * @brief Enumeration of modes supported for time string transmission + * + * This determines e.g. at which point in time a string starts + * to be transmitted via the serial port. + * Used with ::PORT_SETTINGS::mode. + * + * @see ::STR_MODE_MASKS + */ +enum STR_MODES +{ + STR_ON_REQ, ///< transmission on request by received '?' character only + STR_PER_SEC, ///< transmission automatically if second changes + STR_PER_MIN, ///< transmission automatically if minute changes + STR_AUTO, ///< transmission automatically if required, e.g. on capture event + STR_ON_REQ_SEC, ///< transmission if second changes and a request has been received before + N_STR_MODE ///< the number of known modes +}; + + +/** + * The number of serial ports which are at least available + * even with very old GPS receiver models. For devices providing + * a ::RECEIVER_INFO structure the number of provided COM ports + * is available in ::RECEIVER_INFO::n_com_ports. + */ +#define DEFAULT_N_COM 2 + + +/** + * @brief A The structure used to store the configuration of two serial ports + * + * @deprecated This structure is deprecated, ::PORT_SETTINGS and related structures + * should be used instead, if supported by the device. + */ +typedef struct +{ + COM_PARM com[DEFAULT_N_COM]; ///< COM0 and COM1 settings + uint8_t mode[DEFAULT_N_COM]; ///< COM0 and COM1 output mode + +} PORT_PARM; + + +/** + * @brief The type of a GPS command code + * + * @see ::GPS_CMD_CODES + */ +typedef uint16_t GPS_CMD; + + +/** + * @brief Control codes to be or'ed with a particular command/type code + */ +enum GPS_CMD_CTRL_CODES +{ + GPS_REQACK = 0x8000, ///< to device: request acknowledge + GPS_ACK = 0x4000, ///< from device: acknowledge a command + GPS_NACK = 0x2000, ///< from device: error evaluating a command +}; + +#define GPS_CTRL_MSK 0xF000 ///< bit mask of all ::GPS_CMD_CTRL_CODES + + +/** + * @brief Command codes for the binary protocol + * + * These codes specify commands and associated data types used by Meinberg's + * binary protocol to exchange data with a device via serial port, direct USB, + * or socket I/O. + * + * Some commands and associated data structures can be read (r) from a device, others + * can be written (w) to the device, and some can also be sent automatically (a) by + * a device after a ::GPS_AUTO_ON command has been sent to the device. + * The individual command codes are marked with (rwa) accordingly, where '-' is used + * to indicate that a particular mode is not supported. + * + * @note Not all command code are supported by all devices. + * See the hints for a particular command. + * + * @note If ::GPS_ALM, ::GPS_EPH or a code named ..._IDX is sent to retrieve + * some data from a device then an uint16_t parameter must be also supplied + * in order to specify the index number of the data set to be returned. + * The valid index range depends on the command code. + * For ::GPS_ALM and ::GPS_EPH the index is the SV number which may be 0 or + * ::MIN_SVNO_GPS to ::MAX_SVNO_GPS. If the number is 0 then all ::N_SVNO_GPS + * almanacs or ephemeris data structures are returned. + * + * @see ::GPS_CMD_CODES_TABLE + */ +enum GPS_CMD_CODES +{ /* system data */ + GPS_AUTO_ON = 0x000, ///< (-w-) no data, enable auto-msgs from device + GPS_AUTO_OFF, ///< (-w-) no data, disable auto-msgs from device + GPS_SW_REV, ///< (r--) deprecated, ::SW_REV, software revision, use only if ::GPS_RECEIVER_INFO not supp. + GPS_BVAR_STAT, ///< (r--) ::BVAR_STAT, status of buffered variables, only if ::GPS_MODEL_HAS_BVAR_STAT + GPS_TIME, ///< (-wa) ::TTM, current time or capture, or init board time + GPS_POS_XYZ, ///< (rw-) ::XYZ, current position in ECEF coordinates, only if ::GPS_MODEL_HAS_POS_XYZ + GPS_POS_LLA, ///< (rw-) ::LLA, current position in geographic coordinates, only if ::GPS_MODEL_HAS_POS_LLA + GPS_TZDL, ///< (rw-) ::TZDL, time zone / daylight saving, only if ::GPS_MODEL_HAS_TZDL + GPS_PORT_PARM, ///< (rw-) deprecated, ::PORT_PARM, use ::PORT_SETTINGS etc. if ::GPS_RECEIVER_INFO supported + GPS_SYNTH, ///< (rw-) ::SYNTH, synthesizer settings, only if ::GPS_HAS_SYNTH + GPS_ANT_INFO, ///< (r-a) ::ANT_INFO, time diff after antenna disconnect, only if ::GPS_MODEL_HAS_ANT_INFO + GPS_UCAP, ///< (r-a) ::TTM, user capture events, only if ::RECEIVER_INFO::n_ucaps > 0 /* GPS data */ - GPS_CFGH = 0x100, /* þ þ X þ X þ SVs' configuration and health codes */ - GPS_ALM, /* þ þ X þ X þ one SV's almanac */ - GPS_EPH, /* þ þ X þ X þ one SV's ephemeris */ - GPS_UTC, /* þ þ X þ X þ UTC correction parameters */ - GPS_IONO, /* þ þ X þ X þ ionospheric correction parameters */ - GPS_ASCII_MSG /* þ þ X þ þ the GPS ASCII message */ + GPS_CFGH = 0x100, ///< (rw-) ::CFGH, SVs' configuration and health codes + GPS_ALM, ///< (rw-) req: uint16_t SV num, ::SV_ALM, one SV's almanac + GPS_EPH, ///< (rw-) req: uint16_t SV num, ::SV_EPH, one SV's ephemeris + GPS_UTC, ///< (rw-) ::UTC, GPS %UTC correction parameters + GPS_IONO, ///< (rw-) ::IONO, GPS ionospheric correction parameters + GPS_ASCII_MSG ///< (r--) ::ASCII_MSG, the GPS ASCII message }; -/* - * modelled after GPSDEFS.H Revision 1.5 - */ -/***************************************************************************/ -/* */ -/* File: GPSDEFS.H 4.1 */ -/* */ -/* Project: Common C Library */ -/* */ -/* Compiler: Borland C++ */ -/* */ -/* Author: M. Burnicki, Meinberg Funkuhren */ -/* */ -/* */ -/* Description: */ -/* General definitions to be used with GPS166 */ -/* GPS166 Rev. 1.23 or above */ -/* */ -/* Modifications: see file GPSLIB.TXT */ -/* */ -/***************************************************************************/ -#define _GPSDEFS_H -/* the type of various checksums */ #ifndef _CSUM_DEFINED - typedef unsigned short CSUM; -# define _CSUM_DEFINED + typedef uint16_t CSUM; /* checksum used by some structures stored in non-volatile memory */ + #define _CSUM_DEFINED #endif -/* the message header */ -typedef struct { - unsigned short gps_cmd; - unsigned short gps_len; - unsigned short gps_data_csum; - unsigned short gps_hdr_csum; +/** + * @brief The header of a binary message. + */ +typedef struct +{ + GPS_CMD cmd; ///< see ::GPS_CMD_CODES + uint16_t len; ///< length of the data portion appended after the header + CSUM data_csum; ///< checksum of the data portion appended after the header + CSUM hdr_csum; ///< checksum of the preceding header bytes + } GPS_MSG_HDR; -/* a struct used to hold the software revision information */ -typedef struct { - unsigned short code; /* e.g. 0x0120 means rev. 1.20 */ - unsigned char name[17]; /* used to identify customized versions */ +#define GPS_ID_STR_LEN 16 +#define GPS_ID_STR_SIZE ( GPS_ID_STR_LEN + 1 ) + +/** + * @brief Software revision information + * + * Contains a software revision code, plus an optional + * identifier for a customized version. + */ +typedef struct +{ + uint16_t code; ///< Version number, e.g. 0x0120 means v1.20 + char name[GPS_ID_STR_SIZE]; ///< Optional string identifying a customized version + uint8_t reserved; ///< Reserved field to yield even structure size + } SW_REV; -/* GPS ASCII message */ -typedef struct { - CSUM csum; /* checksum of the remaining bytes */ - short valid; /* flag data are valid */ - char s[23]; /* 22 chars GPS ASCII message plus trailing zero */ -} ASCII_MSG; +/** + * @brief GNSS satellite numbers + * + * @todo: Check if MAX_SVNO_GLN is 94 instead of 95, and thus + * N_SVNO_GLN is 30 instead of 31, as reported by Wikipedia. + */ +enum GNSS_SVNOS +{ + MIN_SVNO_GPS = 1, ///< min. GPS satellite PRN number + MAX_SVNO_GPS = 32, ///< max. GPS satellite PRN number + N_SVNO_GPS = 32, ///< max. number of active GPS satellites + + MIN_SVNO_WAAS = 33, ///< min. WAAS satellite number + MAX_SVNO_WAAS = 64, ///< max. WAAS satellite number + N_SVNO_WAAS = 32, ///< max. number of active WAAS satellites + + MIN_SVNO_GLONASS = 65, ///< min. Glonass satellite number (64 + sat slot ID) + MAX_SVNO_GLONASS = 95, ///< max. Glonass satellite number (64 + sat slot ID) + N_SVNO_GLONASS = 31 ///< max. number of active Glonass satellites +}; + + +typedef uint16_t SVNO; ///< the number of an SV (Space Vehicle, i.e. satellite) +typedef uint16_t HEALTH; ///< an SV's 6 bit health code +typedef uint16_t CFG; ///< an SV's 4 bit configuration code +typedef uint16_t IOD; ///< Issue-Of-Data code + + +/** + * @brief Status flags of battery buffered data + * + * Related to data received from the satellites, or data derived thereof. + * + * All '0' means OK, single bits set to '1' indicate + * the associated type of GPS data is not available. + * + * @see ::BVAR_FLAGS + */ +typedef uint16_t BVAR_STAT; + +#define _mbg_swab_bvar_stat( _p ) _mbg_swab16( (_p) ) -#define MIN_SVNO 1 /* min. SV number */ -#define MAX_SVNO 32 /* max. SV number */ -#define N_SVNO ( MAX_SVNO - MIN_SVNO + 1) /* number of possibly active SVs */ +/** + * @brief Enumeration of flag bits used to define ::BVAR_FLAGS + * + * For each bit which is set this means the associated data set in + * non-volatile memory is not available, or incomplete. + * Most data sets will just be re-collected from the data streams sent + * by the satellites. However, the receiver position has usually been + * computed earlier during normal operation, and will be re-computed + * when a sufficient number of satellites can be received. + * + * @see ::BVAR_STAT + * @see ::BVAR_FLAGS + * @see ::BVAR_FLAG_NAMES + */ +enum BVAR_FLAG_BITS +{ + BVAR_BIT_CFGH_INVALID, ///< Satellite configuration and health parameters incomplete + BVAR_BIT_ALM_NOT_COMPLETE, ///< Almanac parameters incomplete + BVAR_BIT_UTC_INVALID, ///< %UTC offset parameters incomplete + BVAR_BIT_IONO_INVALID, ///< Ionospheric correction parameters incomplete + BVAR_BIT_RCVR_POS_INVALID, ///< No valid receiver position available + N_BVAR_BIT ///< number of defined ::BVAR_STAT bits +}; + + +/** + * @brief Bit masks associated with ::BVAR_FLAG_BITS + * + * Used with ::BVAR_STAT. + * + * @see ::BVAR_STAT + * @see ::BVAR_FLAG_BITS + * @see ::BVAR_FLAG_NAMES + */ +enum BVAR_FLAGS +{ + BVAR_CFGH_INVALID = ( 1UL << BVAR_BIT_CFGH_INVALID ), ///< see ::BVAR_BIT_CFGH_INVALID + BVAR_ALM_NOT_COMPLETE = ( 1UL << BVAR_BIT_ALM_NOT_COMPLETE ), ///< see ::BVAR_BIT_ALM_NOT_COMPLETE + BVAR_UTC_INVALID = ( 1UL << BVAR_BIT_UTC_INVALID ), ///< see ::BVAR_BIT_UTC_INVALID + BVAR_IONO_INVALID = ( 1UL << BVAR_BIT_IONO_INVALID ), ///< see ::BVAR_BIT_IONO_INVALID + BVAR_RCVR_POS_INVALID = ( 1UL << BVAR_BIT_RCVR_POS_INVALID ), ///< see ::BVAR_BIT_RCVR_POS_INVALID +}; -typedef short SVNO; /* the number of a SV */ -typedef unsigned short HEALTH; /* a SV's health code */ -typedef unsigned short CFG; /* a SV's configuration code */ -typedef unsigned short IOD; /* Issue-Of-Data code */ -/* Date and time referred to the linear time scale defined by GPS. */ -/* GPS time is defined by the number of weeks since midnight from */ -/* January 5, 1980 to January 6, 1980 plus the number of seconds of */ -/* the current week plus fractions of a second. GPS time differs from */ -/* UTC because UTC is corrected with leap seconds while GPS time scale */ -/* is continuous. */ +/** + * @brief A structure used to hold time in GPS format + * + * Date and time refer to the linear time scale defined by GPS, with + * the epoch starting at %UTC midnight at the beginning of January 6, 1980. + * + * GPS time is counted by the week numbers since the epoch, plus second + * of the week, plus fraction of the second. The week number transmitted + * by the satellites rolls over from 1023 to 0, but Meinberg devices + * just continue to count the weeks beyond the 1024 week limit to keep + * the receiver's internal time. + * + * %UTC time differs from GPS time since a number of leap seconds have + * been inserted in the %UTC time scale after the GPS epoche. The number + * of leap seconds is disseminated by the satellites using the ::UTC + * parameter set, which also provides info on pending leap seconds. + */ +typedef struct +{ + uint16_t wn; ///< the week number since GPS has been installed + uint32_t sec; ///< the second of that week + uint32_t tick; ///< fractions of a second, 1/::RECEIVER_INFO::ticks_per_sec units -typedef struct { - unsigned short wn; /* the week number since GPS has been installed */ - unsigned long sec; /* the second of that week */ - unsigned long tick; /* fractions of a second; scale: 1E-7 */ } T_GPS; -/* Local date and time computed from GPS time. The current number */ -/* of leap seconds have to be added to get UTC from GPS time. */ -/* Additional corrections could have been made according to the */ -/* time zone/daylight saving parameters (TZDL, see below) defined */ -/* by the user. The status field can be checked to see which corrections */ -/* have been applied. */ - -#ifndef _TM_DEFINED - typedef struct { - short year; /* 0..9999 */ - char month; /* 1..12 */ - char mday; /* 1..31 */ - short yday; /* 1..366 */ - char wday; /* 0..6 == Sun..Sat */ - char hour; /* 0..23 */ - char minute; /* 0..59 */ - char second; /* 0..59 */ - long frac; /* fractions of a second, scale 1E-7 */ - long offs_from_utc; /* local time's offset from UTC */ - unsigned short status; /* flags */ - } TM; - - /* status flags used with conversion from GPS time to local time */ - -# define TM_UTC 0x01 /* UTC correction has been made */ -# define TM_LOCAL 0x02 /* UTC has been converted to local time */ -# define TM_DL_ANN 0x04 /* state of daylight saving is going to change */ -# define TM_DL_ENB 0x08 /* daylight saving is enabled */ -# define TM_LS_ANN 0x10 /* leap second will be inserted */ -# define TM_LS_ENB 0x20 /* current second is leap second */ - -# define _TM_DEFINED -#endif +/** + * @brief Local date and time computed from GPS time + * + * The current number of leap seconds have to be added to get %UTC + * from GPS time. Additional corrections could have been made according + * to the time zone/daylight saving parameters ::TZDL defined by the user. + * The status field can be checked to see which corrections + * have actually been applied. + * + * @note Conversion from GPS time to %UTC and/or local time can only be + * done if some valid ::UTC correction parameters are available in the + * receiver's non-volatile memory. + */ +typedef struct +{ + int16_t year; ///< year number, 0..9999 + int8_t month; ///< month, 1..12 + int8_t mday; ///< day of month, 1..31 + int16_t yday; ///< day of year, 1..365, or 366 in case of leap year + int8_t wday; ///< day of week, 0..6 == Sun..Sat + int8_t hour; ///< hours, 0..23 + int8_t min; ///< minutes, 0..59 + int8_t sec; ///< seconds, 0..59, or 60 in case of inserted leap second + int32_t frac; ///< fractions of a second, 1/::RECEIVER_INFO::ticks_per_sec units + int32_t offs_from_utc; ///< local time offset from %UTC [sec] + uint16_t status; ///< status flags, see ::TM_GPS_STATUS_BIT_MASKS + +} TM_GPS; + + + +/** + * @brief Status flag bits used to define ::TM_GPS_STATUS_BIT_MASKS + * + * These bits report info on the time conversion from GPS time to %UTC + * and/or local time as well as device status info. + * + * @see ::TM_GPS_STATUS_BIT_MASKS + */ +enum TM_GPS_STATUS_BITS +{ + TM_BIT_UTC, ///< %UTC correction has been made + TM_BIT_LOCAL, ///< %UTC has been converted to local time according to ::TZDL settings + TM_BIT_DL_ANN, ///< state of daylight saving is going to change + TM_BIT_DL_ENB, ///< daylight saving is in effect + TM_BIT_LS_ANN, ///< leap second pending + TM_BIT_LS_ENB, ///< current second is leap second + TM_BIT_LS_ANN_NEG, ///< set in addition to ::TM_BIT_LS_ANN if leap sec is negative + TM_BIT_INVT, ///< invalid time, e.g. if RTC battery bas been empty + + TM_BIT_EXT_SYNC, ///< synchronized externally + TM_BIT_HOLDOVER, ///< in holdover mode after previous synchronization + TM_BIT_ANT_SHORT, ///< antenna cable short circuited + TM_BIT_NO_WARM, ///< OCXO has not warmed up + TM_BIT_ANT_DISCONN, ///< antenna currently disconnected + TM_BIT_SYN_FLAG, ///< TIME_SYN output is low + TM_BIT_NO_SYNC, ///< time sync actually not verified + TM_BIT_NO_POS ///< position actually not verified, LOCK LED off +}; -/* the status flags below are defined starting with rev. 1.32 */ +/** + * @brief Status flag masks used with ::TM_GPS::status + * + * These bits report info on the time conversion from GPS time to %UTC + * and/or local time as well as device status info. + * + * @see ::TM_GPS_STATUS_BITS + */ +enum TM_GPS_STATUS_BIT_MASKS +{ + TM_UTC = ( 1UL << TM_BIT_UTC ), ///< see ::TM_BIT_UTC + TM_LOCAL = ( 1UL << TM_BIT_LOCAL ), ///< see ::TM_BIT_LOCAL + TM_DL_ANN = ( 1UL << TM_BIT_DL_ANN ), ///< see ::TM_BIT_DL_ANN + TM_DL_ENB = ( 1UL << TM_BIT_DL_ENB ), ///< see ::TM_BIT_DL_ENB + TM_LS_ANN = ( 1UL << TM_BIT_LS_ANN ), ///< see ::TM_BIT_LS_ANN + TM_LS_ENB = ( 1UL << TM_BIT_LS_ENB ), ///< see ::TM_BIT_LS_ENB + TM_LS_ANN_NEG = ( 1UL << TM_BIT_LS_ANN_NEG ), ///< see ::TM_BIT_LS_ANN_NEG + TM_INVT = ( 1UL << TM_BIT_INVT ), ///< see ::TM_BIT_INVT + + TM_EXT_SYNC = ( 1UL << TM_BIT_EXT_SYNC ), ///< see ::TM_BIT_EXT_SYNC + TM_HOLDOVER = ( 1UL << TM_BIT_HOLDOVER ), ///< see ::TM_BIT_HOLDOVER + TM_ANT_SHORT = ( 1UL << TM_BIT_ANT_SHORT ), ///< see ::TM_BIT_ANT_SHORT + TM_NO_WARM = ( 1UL << TM_BIT_NO_WARM ), ///< see ::TM_BIT_NO_WARM + TM_ANT_DISCONN = ( 1UL << TM_BIT_ANT_DISCONN ), ///< see ::TM_BIT_ANT_DISCONN + TM_SYN_FLAG = ( 1UL << TM_BIT_SYN_FLAG ), ///< see ::TM_BIT_SYN_FLAG + TM_NO_SYNC = ( 1UL << TM_BIT_NO_SYNC ), ///< see ::TM_BIT_NO_SYNC + TM_NO_POS = ( 1UL << TM_BIT_NO_POS ) ///< see ::TM_BIT_NO_POS +}; -#define TM_ANT_DISCONN 0x1000 /* antenna currently disconnected */ -#define TM_SYN_FLAG 0x2000 /* TIME_SYN output is low */ -#define TM_NO_SYNC 0x4000 /* not sync'ed after reset */ -#define TM_NO_POS 0x8000 /* position not computed after reset, */ - /* LOCK LED off */ -/* a struct used to transmit information on date and time */ +/** + * @brief A structure used to transmit information on date and time + * + * This structure can be used to transfer the current time, in which + * case the channel field has to be set to -1, or an event capture time + * retrieved from the on-board FIFO, in which case the channel field + * contains the index of the time capture input, e.g. 0 or 1. + */ +typedef struct +{ + int16_t channel; ///< -1: the current on-board time; >= 0 the capture channel number + T_GPS t; ///< time in GPS scale and format + TM_GPS tm; ///< time converted to %UTC and/or local time according to ::TZDL settings -typedef struct { - short channel; /* -1: the current time; 0, 1: capture 0, 1 */ - T_GPS t; /* time in GPS format */ - TM tm; /* that time converted to local time */ } TTM; @@ -249,306 +502,486 @@ typedef struct { /* to geographic coordinates as defined by WGS84 (World Geodetic */ /* System from 1984). */ -#ifndef _XYZ_DEFINED - /* sequence and number of components of a cartesian position */ - enum { XP, YP, ZP, N_XYZ }; +/** + * @brief Sequence and number of components of a cartesian position + */ +enum XYZ_FIELDS { XP, YP, ZP, N_XYZ }; // x, y, z + +/** + * @brief A position in cartesian coordinates + * + * Usually earth centered, earth fixed (ECEF) coordinates, + * in [m]. + * + * @note In the original code this is an array of double. + * + * @see ::XYZ_FIELDS + */ +typedef l_fp XYZ[N_XYZ]; - /* a type of array holding a cartesian position */ - typedef l_fp XYZ[N_XYZ]; /* values are in [m] */ -# define _XYZ_DEFINED -#endif +/** + * @brief Sequence and number of components of a geographic position + */ +enum LLA_FIELDS { LAT, LON, ALT, N_LLA }; /* latitude, longitude, altitude */ +/** + * @brief A geographic position based on latitude, longitude, and altitude + * + * The geographic position associated to specific cartesian coordinates + * depends on the characteristics of the ellipsoid used for the computation, + * the so-called geographic datum. GPS uses the WGS84 (World Geodetic System + * from 1984) ellipsoid by default. + * + * lon, lat in [rad], alt in [m] + * + * @note In the original code this is an array of double. + * + * @see ::LLA_FIELDS + */ +typedef l_fp LLA[N_LLA]; -#ifndef _LLA_DEFINED - /* sequence and number of components of a geographic position */ - enum { LAT, LON, ALT, N_LLA }; /* latitude, longitude, altitude */ - /* a type of array holding a geographic position */ - typedef l_fp LLA[N_LLA]; /* lon, lat in [rad], alt in [m] */ +/** + * @defgroup group_synth Synthesizer parameters + * + * Synthesizer frequency is expressed as a + * four digit decimal number (freq) to be multiplied by 0.1 Hz and an + * base 10 exponent (range). If the effective frequency is less than + * 10 kHz its phase is synchronized corresponding to the variable phase. + * Phase may be in a range from -360 deg to +360 deg with a resolution + * of 0.1 deg, so the resulting numbers to be stored are in a range of + * -3600 to +3600. + * + * Example:
      + * Assume the value of freq is 2345 (decimal) and the value of phase is 900. + * If range == 0 the effective frequency is 234.5 Hz with a phase of +90 deg. + * If range == 1 the synthesizer will generate a 2345 Hz output frequency + * and so on. + * + * Limitations:
      + * If freq == 0 the synthesizer is disabled. If range == 0 the least + * significant digit of freq is limited to 0, 3, 5 or 6. The resulting + * frequency is shown in the examples below: + * - freq == 1230 --> 123.0 Hz + * - freq == 1233 --> 123 1/3 Hz (real 1/3 Hz, NOT 123.3 Hz) + * - freq == 1235 --> 123.5 Hz + * - freq == 1236 --> 123 2/3 Hz (real 2/3 Hz, NOT 123.6 Hz) + * + * If range == ::MAX_SYNTH_RANGE the value of freq must not exceed 1000, so + * the output frequency is limited to 10 MHz (see ::MAX_SYNTH_FREQ_VAL). + * + * @{ */ -# define _LLA_DEFINED -#endif +#define N_SYNTH_FREQ_DIGIT 4 ///< number of digits to edit +#define MAX_SYNTH_FREQ 1000 ///< if range == ::MAX_SYNTH_RANGE -/* Synthesizer parameters. Synthesizer frequency is expressed as a */ -/* four digit decimal number (freq) to be multiplied by 0.1 Hz and an */ -/* base 10 exponent (range). If the effective frequency is less than */ -/* 10 kHz its phase is synchronized corresponding to the variable phase. */ -/* Phase may be in a range from -360° to +360° with a resolution of 0.1°, */ -/* so the resulting numbers to be stored are in a range of -3600 to +3600. */ - -/* Example: */ -/* Assume the value of freq is 2345 (decimal) and the value of phase is 900. */ -/* If range == 0 the effective frequency is 234.5 Hz with a phase of +90°. */ -/* If range == 1 the synthesizer will generate a 2345 Hz output frequency */ -/* and so on. */ - -/* Limitations: */ -/* If freq == 0 the synthesizer is disabled. If range == 0 the least */ -/* significant digit of freq is limited to 0, 3, 5 or 6. The resulting */ -/* frequency is shown in the examples below: */ -/* freq == 1230 --> 123.0 Hz */ -/* freq == 1233 --> 123 1/3 Hz (real 1/3 Hz, NOT 123.3 Hz) */ -/* freq == 1235 --> 123.5 Hz */ -/* freq == 1236 --> 123 2/3 Hz (real 2/3 Hz, NOT 123.6 Hz) */ - -/* If range == MAX_RANGE the value of freq must not exceed 1200, so the */ -/* output frequency is limited to 12 MHz. */ - -/* Phase will be ignored if the resulting frequency is greater or equal */ -/* to 10 kHz. */ - -#define MAX_SYNTH_FREQ 1200 /* if range == MAX_SYNTH_RANGE */ #define MIN_SYNTH_RANGE 0 #define MAX_SYNTH_RANGE 5 -#define MAX_SYNTH_PHASE 3600 +#define N_SYNTH_RANGE ( MAX_SYNTH_RANGE - MIN_SYNTH_RANGE + 1 ) -typedef struct { - short freq; /* four digits used; scale: 0.1; e.g. 1234 -> 123.4 Hz */ - short range; /* scale factor for freq; 0..MAX_SYNTH_RANGE */ - short phase; /* -MAX_SYNTH_PHASE..+MAX_SYNTH_PHASE; >0 -> pulses later */ -} SYNTH; +#define N_SYNTH_PHASE_DIGIT 4 +#define MAX_SYNTH_PHASE 3600 +#define MAX_SYNTH_FREQ_EDIT 9999 ///< max sequence of digits when editing -/* Time zone/daylight saving parameters. */ -/* the name of a time zone, 5 characters plus trailing zero */ -typedef char TZ_NAME[6]; +/** + * @brief The maximum frequency that can be configured for the synthesizer + */ +#define MAX_SYNTH_FREQ_VAL 10000000UL ///< 10 MHz +/* == MAX_SYNTH_FREQ * 10^(MAX_SYNTH_RANGE-1) */ -typedef struct { - long offs; /* offset from UTC to local time [sec] */ - long offs_dl; /* additional offset if daylight saving enabled [sec] */ - TM tm_on; /* date/time when daylight saving starts */ - TM tm_off; /* date/time when daylight saving ends */ - TZ_NAME name[2]; /* names without and with daylight saving enabled */ -} TZDL; +/** + * @brief The synthesizer's phase is only be synchronized if the frequency is below this limit + */ +#define SYNTH_PHASE_SYNC_LIMIT 10000UL ///< 10 kHz -/* The constant below is defined beginning with software rev. 1.29. */ -/* If the year in tzdl.tmon and tzdl.tm_off is or'ed with that constant, */ -/* the receiver automatically generates daylight saving year by year. */ -/* See GPSLIB.TXT for more information. */ +/** + * A Macro used to determine the position of the decimal point + * when printing the synthesizer frequency as 4 digit value + */ +#define _synth_dp_pos_from_range( _r ) \ + ( ( ( N_SYNTH_RANGE - (_r) ) % ( N_SYNTH_FREQ_DIGIT - 1 ) ) + 1 ) + +/** + * @brief Synthesizer frequency units + * + * An initializer for commonly displayed synthesizer frequency units + * (::N_SYNTH_RANGE strings) + */ +#define DEFAULT_FREQ_RANGES \ +{ \ + "Hz", \ + "kHz", \ + "kHz", \ + "kHz", \ + "MHz", \ + "MHz", \ +} -#define DL_AUTO_FLAG 0x8000 -/* Example: */ -/* for automatic daylight saving enable/disable in Central Europe, */ -/* the variables are to be set as shown below: */ -/* offs = 3600L one hour from UTC */ -/* offs_dl = 3600L one additional hour if daylight saving enabled */ -/* tm_on = first Sunday from March 25, 02:00:00h ( year |= DL_AUTO_FLAG ) */ -/* tm_off = first Sunday from Sept 24, 03:00:00h ( year |= DL_AUTO_FLAG ) */ -/* name[0] == "MEZ " name if daylight saving not enabled */ -/* name[1] == "MESZ " name if daylight saving is enabled */ +/** + * @brief Synthesizer configuration parameters + */ +typedef struct +{ + int16_t freq; ///< four digits used; scale: 0.1 Hz; e.g. 1234 -> 123.4 Hz + int16_t range; ///< scale factor for freq; 0..::MAX_SYNTH_RANGE + int16_t phase; ///< -::MAX_SYNTH_PHASE..+::MAX_SYNTH_PHASE; >0 -> pulses later +} SYNTH; +#define _mbg_swab_synth( _p ) \ +{ \ + _mbg_swab16( &(_p)->freq ); \ + _mbg_swab16( &(_p)->range ); \ + _mbg_swab16( &(_p)->phase ); \ +} -/* the structure below was defined in rev. 1.31. It reflects the status */ -/* of the antenna, the times of last disconnect/reconnect and the boards */ -/* clock offset after the phase of disconnection. */ -typedef struct { - short status; /* current status of antenna */ - TM tm_disconn; /* time of antenna disconnect */ - TM tm_reconn; /* time of antenna reconnect */ - long delta_t; /* clock offset at reconnect time, units: TICKS_PER_SEC */ -} ANT_INFO; +/** + * @brief Enumeration of synthesizer states + */ +enum SYNTH_STATES +{ + SYNTH_DISABLED, ///< disbled by cfg, i.e. freq == 0.0 + SYNTH_OFF, ///< not enabled after power-up + SYNTH_FREE, ///< enabled, but not synchronized + SYNTH_DRIFTING, ///< has initially been sync'd, but now running free + SYNTH_SYNC, ///< fully synchronized + N_SYNTH_STATE ///< the number of known states +}; + +/** + * @brief A structure used to report the synthesizer state + */ +typedef struct +{ + uint8_t state; ///< state code as enumerated in ::SYNTH_STATES + uint8_t flags; ///< reserved, currently always 0 -/* the status field may be set to one of the values below: */ +} SYNTH_STATE; -enum { - ANT_INVALID, /* struct not set yet because ant. has not been disconn. */ - ANT_DISCONN, /* ant. now disconn., tm_reconn and delta_t not set */ - ANT_RECONN /* ant. has been disconn. and reconn., all fields valid */ -}; +#define _mbg_swab_synth_state( _p ) _nop_macro_fnc() +#define SYNTH_FLAG_PHASE_IGNORED 0x01 -/* Summary of configuration and health data of all SVs. */ +/** @} defgroup group_synth */ -typedef struct { - CSUM csum; /* checksum of the remaining bytes */ - short valid; /* flag data are valid */ - T_GPS tot_51; /* time of transmission, page 51 */ - T_GPS tot_63; /* time of transmission, page 63 */ - T_GPS t0a; /* complete reference time almanac */ - CFG cfg[N_SVNO]; /* SV configuration from page 63 */ - HEALTH health[N_SVNO]; /* SV health from pages 51, 63 */ -} CFGH; +/** + * @defgroup group_tzdl Time zone / daylight saving parameters + * + * Example:
      + * For automatic daylight saving enable/disable in Central Europe, + * the variables are to be set as shown below:
      + * - offs = 3600L one hour from %UTC + * - offs_dl = 3600L one additional hour if daylight saving enabled + * - tm_on = first Sunday from March 25, 02:00:00h ( year |= ::DL_AUTO_FLAG ) + * - tm_off = first Sunday from October 25, 03:00:00h ( year |= ::DL_AUTO_FLAG ) + * - name[0] == "CET " name if daylight saving not enabled + * - name[1] == "CEST " name if daylight saving is enabled + * + * @{ */ + +/** + * @brief The name of a time zone + * + * @note Up to 5 printable characters, plus trailing zero + */ +typedef char TZ_NAME[6]; +/** + * @brief Time zone / daylight saving parameters + * + * This structure is used to specify how a device converts on-board %UTC + * to local time, including computation of beginning and end of daylight + * saving time (DST), if required. + * + * @note The ::TZDL structure contains members of type ::TM_GPS to specify + * the times for beginning and end of DST. However, the ::TM_GPS::frac, + * ::TM_GPS::offs_from_utc, and ::TM_GPS::status fields of these ::TZDL::tm_on + * and ::TZDL::tm_off members are ignored for the conversion to local time, + * and thus should be 0. + */ +typedef struct +{ + int32_t offs; ///< standard offset from %UTC to local time [sec] + int32_t offs_dl; ///< additional offset if daylight saving enabled [sec] + TM_GPS tm_on; ///< date/time when daylight saving starts + TM_GPS tm_off; ///< date/time when daylight saving ends + TZ_NAME name[2]; ///< names without and with daylight saving enabled +} TZDL; + +/** + * @brief A flag indicating automatic computation of DST + * + * If this flag is or'ed to the year numbers in ::TZDL::tm_on and ::TZDL::tm_off + * then daylight saving is computed automatically year by year. + */ +#define DL_AUTO_FLAG 0x8000 -/* UTC correction parameters */ +/** @} defgroup group_tzdl */ -typedef struct { - CSUM csum; /* checksum of the remaining bytes */ - short valid; /* flag data are valid */ - T_GPS t0t; /* Reference Time UTC Parameters [sec] */ - l_fp A0; /* ± Clock Correction Coefficient 0 [sec] */ - l_fp A1; /* ± Clock Correction Coefficient 1 [sec/sec] */ - ushort WNlsf; /* week number of nearest leap second */ - short DNt; /* the day number at the end of which LS is inserted */ - char delta_tls; /* */ - char delta_tlsf; /* */ +/** + * @brief Antenna status and error at reconnect information + * + * The structure below reflects the status of the antenna, + * the times of last disconnect/reconnect, and the board's + * clock offset when it has synchronized again after the + * disconnection interval. + * + * @note ::ANT_INFO::status changes back to ::ANT_RECONN only + * after the antenna has been reconnected and the + * receiver has re-synchronized to the satellite signal. + * In this case ::ANT_INFO::delta_t reports the time offset + * before resynchronization, i.e. how much the internal + * time has drifted while the antenna was disconnected. + */ +typedef struct +{ + int16_t status; ///< current status of antenna, see ::ANT_STATUS_CODES + TM_GPS tm_disconn; ///< time of antenna disconnect + TM_GPS tm_reconn; ///< time of antenna reconnect + int32_t delta_t; ///< clock offs at reconn. time in 1/::RECEIVER_INFO::ticks_per_sec units -} UTC; +} ANT_INFO; -/* a struct used to hold the settings of a serial port */ -#ifndef _COM_PARM_DEFINED - typedef long BAUD_RATE; +/** + * @brief Status code used with ::ANT_INFO::status + */ +enum ANT_STATUS_CODES +{ + ANT_INVALID, ///< No other fields valid since antenna has not yet been disconnected + ANT_DISCONN, ///< Antenna is disconnected, tm_reconn and delta_t not yet set + ANT_RECONN, ///< Antenna has been disconnect, and receiver sync. after reconnect, so all fields valid + N_ANT_STATUS_CODES ///< the number of known status codes +}; - /* indices used to identify a parameter in the framing string */ - enum { F_DBITS, F_PRTY, F_STBITS }; - /* types of handshake */ - enum { HS_NONE, HS_XONXOFF, HS_RTSCTS }; - typedef struct { - BAUD_RATE baud_rate; /* e.g. 19200L */ - char framing[4]; /* e.g. "8N1" */ - short handshake; /* a numeric value, only HS_NONE supported yet */ - } COM_PARM; +/** + * @brief Summary of configuration and health data of all satellites + */ +typedef struct +{ + CSUM csum; ///< checksum of the remaining bytes + int16_t valid; ///< flag data are valid + + T_GPS tot_51; ///< time of transmission, page 51 + T_GPS tot_63; ///< time of transmission, page 63 + T_GPS t0a; ///< complete reference time almanac + + CFG cfg[N_SVNO_GPS]; ///< 4 bit SV configuration code from page 63 + HEALTH health[N_SVNO_GPS]; ///< 6 bit SV health codes from pages 51, 63 + +} CFGH; + -#define _COM_PARM_DEFINED -#endif +/** + * @brief GPS %UTC correction parameters + * + * %UTC correction parameters basically as sent by the GPS satellites. + * + * The csum field is only used by the card's firmware to check the + * consistency of the structure in non-volatile memory. + * + * The field labeled valid indicates if the parameter set is valid, i.e. + * if it contains data received from the satellites. + * + * t0t, A0 and A1 contain fractional correction parameters for the current + * GPS-%UTC time offset in addition to the whole seconds. This is evaluated + * by the receivers' firmware to convert GPS time to %UTC time. + * + * The delta_tls field contains the current full seconds offset between + * GPS time and %UTC, which corresponds to the number of leap seconds inserted + * into the %UTC time scale since GPS was put into operation in January 1980. + * + * delta_tlfs holds the number of "future" leap seconds, i.e. the %UTC offset + * after the next leap second event defined by WNlsf and DNt. + * + * The fields WNlsf and DNt specify the GPS week number and the day number + * in that week for the end of which a leap second has been scheduled. + * + * @note: The satellites transmit WNlsf only as a signed 8 bit value, so it + * can only define a point in time which is +/- 127 weeks off the current time. + * The firmware tries to expand this based on the current week number, but + * the result is ambiguous if the leap second occurs or occurred more + * than 127 weeks in the future or past. + * + * So the leap second date should only be evaluated and displayed + * in a user interface if the fields delta_tls and delta_tlsf have + * different values, in which case there is indeed a leap second announcement + * inside the +/- 127 week range. + * + * @note In the original code the type of A0 and A1 is double. + */ +typedef struct +{ + CSUM csum; ///< Checksum of the remaining bytes + int16_t valid; ///< Flag indicating %UTC parameters are valid + T_GPS t0t; ///< Reference Time %UTC Parameters [wn|sec] + l_fp A0; ///< +- Clock Correction Coefficient 0 [sec] + l_fp A1; ///< +- Clock Correction Coefficient 1 [sec/sec] -/* the codes below define what has to comes out of the serial ports */ + uint16_t WNlsf; ///< Week number of nearest leap second + int16_t DNt; ///< The day number at the end of which a leap second occurs + int8_t delta_tls; ///< Current %UTC offset to GPS system time [sec] + int8_t delta_tlsf; ///< Future %UTC offset to GPS system time after next leap second transition [sec] -enum { STR_ON_REQ, STR_PER_SEC, - STR_PER_MIN, N_STR_MODE_0, /* COM0 and COM1 */ - STR_UCAP = N_STR_MODE_0, - STR_UCAP_REQ, N_STR_MODE_1 /* COM1 only */ - }; +} UTC; -#define N_COM 2 /* the number of serial ports */ +/** + * @brief GPS ASCII message + */ +typedef struct +{ + CSUM csum; ///< checksum of the remaining bytes */ + int16_t valid; ///< flag data are valid + char s[23]; ///< 22 chars GPS ASCII message plus trailing zero -/* the structure used to store the modes of both serial ports */ +} ASCII_MSG; -typedef struct { - COM_PARM com[N_COM]; /* COM0 and COM1 settings */ - u_char mode[N_COM]; /* COM0 and COM1 output mode */ -} PORT_PARM; -/* Ephemeris parameters of one specific SV. Needed to compute the position */ -/* of a satellite at a given time with high precision. Valid for an */ -/* interval of 4 to 6 hours from start of transmission. */ - -typedef struct { - CSUM csum; /* checksum of the remaining bytes */ - short valid; /* flag data are valid */ - - HEALTH health; /* health indication of transmitting SV [---] */ - IOD IODC; /* Issue Of Data, Clock */ - IOD IODE2; /* Issue of Data, Ephemeris (Subframe 2) */ - IOD IODE3; /* Issue of Data, Ephemeris (Subframe 3) */ - T_GPS tt; /* time of transmission */ - T_GPS t0c; /* Reference Time Clock [---] */ - T_GPS t0e; /* Reference Time Ephemeris [---] */ - - l_fp sqrt_A; /* Square Root of semi-major Axis [sqrt(m)] */ - l_fp e; /* Eccentricity [---] */ - l_fp M0; /* ± Mean Anomaly at Ref. Time [rad] */ - l_fp omega; /* ± Argument of Perigee [rad] */ - l_fp OMEGA0; /* ± Longit. of Asc. Node of orbit plane [rad] */ - l_fp OMEGADOT; /* ± Rate of Right Ascension [rad/sec] */ - l_fp deltan; /* ± Mean Motion Diff. from computed value [rad/sec] */ - l_fp i0; /* ± Inclination Angle [rad] */ - l_fp idot; /* ± Rate of Inclination Angle [rad/sec] */ - l_fp crc; /* ± Cosine Corr. Term to Orbit Radius [m] */ - l_fp crs; /* ± Sine Corr. Term to Orbit Radius [m] */ - l_fp cuc; /* ± Cosine Corr. Term to Arg. of Latitude [rad] */ - l_fp cus; /* ± Sine Corr. Term to Arg. of Latitude [rad] */ - l_fp cic; /* ± Cosine Corr. Term to Inclination Angle [rad] */ - l_fp cis; /* ± Sine Corr. Term to Inclination Angle [rad] */ - - l_fp af0; /* ± Clock Correction Coefficient 0 [sec] */ - l_fp af1; /* ± Clock Correction Coefficient 1 [sec/sec] */ - l_fp af2; /* ± Clock Correction Coefficient 2 [sec/sec²] */ - l_fp tgd; /* ± estimated group delay differential [sec] */ - - u_short URA; /* predicted User Range Accuracy */ - - u_char L2code; /* code on L2 channel [---] */ - u_char L2flag; /* L2 P data flag [---] */ +/** + * @brief Ephemeris parameters of one specific satellite + * + * Needed to compute the position of a satellite at a given time with + * high precision. Valid for an interval of 4 to 6 hours from start + * of transmission. + */ +typedef struct +{ + CSUM csum; ///< checksum of the remaining bytes + int16_t valid; ///< flag data are valid + + HEALTH health; ///< health indication of transmitting SV [---] + IOD IODC; ///< Issue Of Data, Clock + IOD IODE2; ///< Issue of Data, Ephemeris (Subframe 2) + IOD IODE3; ///< Issue of Data, Ephemeris (Subframe 3) + T_GPS tt; ///< time of transmission + T_GPS t0c; ///< Reference Time Clock [---] + T_GPS t0e; ///< Reference Time Ephemeris [---] + + l_fp sqrt_A; ///< Square Root of semi-major Axis [sqrt(m)] + l_fp e; ///< Eccentricity [---] + l_fp M0; ///< +- Mean Anomaly at Ref. Time [rad] + l_fp omega; ///< +- Argument of Perigee [rad] + l_fp OMEGA0; ///< +- Longit. of Asc. Node of orbit plane [rad] + l_fp OMEGADOT; ///< +- Rate of Right Ascension [rad/sec] + l_fp deltan; ///< +- Mean Motion Diff. from computed value [rad/sec] + l_fp i0; ///< +- Inclination Angle [rad] + l_fp idot; ///< +- Rate of Inclination Angle [rad/sec] + l_fp crc; ///< +- Cosine Corr. Term to Orbit Radius [m] + l_fp crs; ///< +- Sine Corr. Term to Orbit Radius [m] + l_fp cuc; ///< +- Cosine Corr. Term to Arg. of Latitude [rad] + l_fp cus; ///< +- Sine Corr. Term to Arg. of Latitude [rad] + l_fp cic; ///< +- Cosine Corr. Term to Inclination Angle [rad] + l_fp cis; ///< +- Sine Corr. Term to Inclination Angle [rad] + + l_fp af0; ///< +- Clock Correction Coefficient 0 [sec] + l_fp af1; ///< +- Clock Correction Coefficient 1 [sec/sec] + l_fp af2; ///< +- Clock Correction Coefficient 2 [sec/sec^2] + l_fp tgd; ///< +- estimated group delay differential [sec] + + uint16_t URA; ///< predicted User Range Accuracy + + uint8_t L2code; ///< code on L2 channel [---] + uint8_t L2flag; ///< L2 P data flag [---] } EPH; -/* Almanac parameters of one specific SV. A reduced precision set of */ -/* parameters used to check if a satellite is in view at a given time. */ -/* Valid for an interval of more than 7 days from start of transmission. */ -typedef struct { - CSUM csum; /* checksum of the remaining bytes */ - short valid; /* flag data are valid */ - HEALTH health; /* [---] */ - T_GPS t0a; /* Reference Time Almanac [sec] */ +/** + * @brief Almanac parameters of one specific satellite + * + * A reduced precision set of parameters used to check if a satellite + * is in view at a given time. Valid for an interval of more than 7 days + * from start of transmission. + */ +typedef struct +{ + CSUM csum; ///< checksum of the remaining bytes + int16_t valid; ///< flag data are valid + + HEALTH health; ///< [---] + T_GPS t0a; ///< Reference Time Almanac [sec] + + l_fp sqrt_A; ///< Square Root of semi-major Axis [sqrt(m)] + l_fp e; ///< Eccentricity [---] - l_fp sqrt_A; /* Square Root of semi-major Axis [sqrt(m)] */ - l_fp e; /* Eccentricity [---] */ + l_fp M0; ///< +- Mean Anomaly at Ref. Time [rad] + l_fp omega; ///< +- Argument of Perigee [rad] + l_fp OMEGA0; ///< +- Longit. of Asc. Node of orbit plane [rad] + l_fp OMEGADOT; ///< +- Rate of Right Ascension [rad/sec] + l_fp deltai; ///< +- [rad] + l_fp af0; ///< +- Clock Correction Coefficient 0 [sec] + l_fp af1; ///< +- Clock Correction Coefficient 1 [sec/sec] - l_fp M0; /* ± Mean Anomaly at Ref. Time [rad] */ - l_fp omega; /* ± Argument of Perigee [rad] */ - l_fp OMEGA0; /* ± Longit. of Asc. Node of orbit plane [rad] */ - l_fp OMEGADOT; /* ± Rate of Right Ascension [rad/sec] */ - l_fp deltai; /* ± [rad] */ - l_fp af0; /* ± Clock Correction Coefficient 0 [sec] */ - l_fp af1; /* ± Clock Correction Coefficient 1 [sec/sec] */ } ALM; -/* ionospheric correction parameters */ -typedef struct { - CSUM csum; /* checksum of the remaining bytes */ - short valid; /* flag data are valid */ +/** + * @brief Ionospheric correction parameters + */ +typedef struct +{ + CSUM csum; ///< checksum of the remaining bytes + int16_t valid; ///< flag data are valid - l_fp alpha_0; /* Ionosph. Corr. Coeff. Alpha 0 [sec] */ - l_fp alpha_1; /* Ionosph. Corr. Coeff. Alpha 1 [sec/deg] */ - l_fp alpha_2; /* Ionosph. Corr. Coeff. Alpha 2 [sec/deg^2] */ - l_fp alpha_3; /* Ionosph. Corr. Coeff. Alpha 3 [sec/deg^3] */ + l_fp alpha_0; ///< Ionosph. Corr. Coeff. Alpha 0 [sec] + l_fp alpha_1; ///< Ionosph. Corr. Coeff. Alpha 1 [sec/deg] + l_fp alpha_2; ///< Ionosph. Corr. Coeff. Alpha 2 [sec/deg^2] + l_fp alpha_3; ///< Ionosph. Corr. Coeff. Alpha 3 [sec/deg^3] - l_fp beta_0; /* Ionosph. Corr. Coeff. Beta 0 [sec] */ - l_fp beta_1; /* Ionosph. Corr. Coeff. Beta 1 [sec/deg] */ - l_fp beta_2; /* Ionosph. Corr. Coeff. Beta 2 [sec/deg^2] */ - l_fp beta_3; /* Ionosph. Corr. Coeff. Beta 3 [sec/deg^3] */ + l_fp beta_0; ///< Ionosph. Corr. Coeff. Beta 0 [sec] + l_fp beta_1; ///< Ionosph. Corr. Coeff. Beta 1 [sec/deg] + l_fp beta_2; ///< Ionosph. Corr. Coeff. Beta 2 [sec/deg^2] + l_fp beta_3; ///< Ionosph. Corr. Coeff. Beta 3 [sec/deg^3] } IONO; -void mbg_tm_str P((char **, TM *, int)); -void mbg_tgps_str P((char **, T_GPS *, int)); -void get_mbg_header P((unsigned char **, GPS_MSG_HDR *)); -void put_mbg_header P((unsigned char **, GPS_MSG_HDR *)); -void get_mbg_sw_rev P((unsigned char **, SW_REV *)); -void get_mbg_ascii_msg P((unsigned char **, ASCII_MSG *)); -void get_mbg_svno P((unsigned char **, SVNO *)); -void get_mbg_health P((unsigned char **, HEALTH *)); -void get_mbg_cfg P((unsigned char **, CFG *)); -void get_mbg_tgps P((unsigned char **, T_GPS *)); -void get_mbg_tm P((unsigned char **, TM *)); -void get_mbg_ttm P((unsigned char **, TTM *)); -void get_mbg_synth P((unsigned char **, SYNTH *)); -void get_mbg_tzdl P((unsigned char **, TZDL *)); -void get_mbg_antinfo P((unsigned char **, ANT_INFO *)); -void get_mbg_cfgh P((unsigned char **, CFGH *)); -void get_mbg_utc P((unsigned char **, UTC *)); -void get_mbg_lla P((unsigned char **, LLA)); -void get_mbg_xyz P((unsigned char **, XYZ)); -void get_mbg_portparam P((unsigned char **, PORT_PARM *)); -void get_mbg_eph P((unsigned char **, EPH *)); -void get_mbg_alm P((unsigned char **, ALM *)); -void get_mbg_iono P((unsigned char **, IONO *)); - -unsigned long mbg_csum P((unsigned char *, unsigned int)); + + +void mbg_tm_str (char **, TM_GPS *, int, int); +void mbg_tgps_str (char **, T_GPS *, int); +void get_mbg_header (unsigned char **, GPS_MSG_HDR *); +void put_mbg_header (unsigned char **, GPS_MSG_HDR *); +void get_mbg_sw_rev (unsigned char **, SW_REV *); +void get_mbg_ascii_msg (unsigned char **, ASCII_MSG *); +void get_mbg_svno (unsigned char **, SVNO *); +void get_mbg_health (unsigned char **, HEALTH *); +void get_mbg_cfg (unsigned char **, CFG *); +void get_mbg_tgps (unsigned char **, T_GPS *); +void get_mbg_tm (unsigned char **, TM_GPS *); +void get_mbg_ttm (unsigned char **, TTM *); +void get_mbg_synth (unsigned char **, SYNTH *); +void get_mbg_tzdl (unsigned char **, TZDL *); +void get_mbg_antinfo (unsigned char **, ANT_INFO *); +void get_mbg_cfgh (unsigned char **, CFGH *); +void get_mbg_utc (unsigned char **, UTC *); +void get_mbg_lla (unsigned char **, LLA); +void get_mbg_xyz (unsigned char **, XYZ); +void get_mbg_portparam (unsigned char **, PORT_PARM *); +void get_mbg_eph (unsigned char **, EPH *); +void get_mbg_alm (unsigned char **, ALM *); +void get_mbg_iono (unsigned char **, IONO *); + +CSUM mbg_csum (unsigned char *, unsigned int); #endif /* diff --git a/contrib/ntp/include/ntp.h b/contrib/ntp/include/ntp.h index dad9de136..4ffc35f6f 100644 --- a/contrib/ntp/include/ntp.h +++ b/contrib/ntp/include/ntp.h @@ -4,15 +4,18 @@ #ifndef NTP_H #define NTP_H -#include "ntp_types.h" +#include #include -#ifdef OPENSSL -#include "ntp_crypto.h" -#endif /* OPENSSL */ + +#include +#include +#include +#include +#include #include +#include #include -#include /* * Calendar arithmetic - contributed by G. Healton @@ -86,12 +89,6 @@ typedef char s_char; # undef SO_SNDBUF # endif #endif -#ifndef TRUE -# define TRUE 1 -#endif /* TRUE */ -#ifndef FALSE -# define FALSE 0 -#endif /* FALSE */ /* * NTP protocol parameters. See section 3.2.6 of the specification. @@ -103,14 +100,13 @@ typedef char s_char; /* * Poll interval parameters */ -#define NTP_UNREACH 24 /* poll unreach threshold */ -#define NTP_MINPOLL 4 /* log2 min poll interval (16 s) */ +#define NTP_UNREACH 10 /* poll unreach threshold */ +#define NTP_MINPOLL 3 /* log2 min poll interval (8 s) */ #define NTP_MINDPOLL 6 /* log2 default min poll (64 s) */ #define NTP_MAXDPOLL 10 /* log2 default max poll (~17 m) */ #define NTP_MAXPOLL 17 /* log2 max poll interval (~36 h) */ -#define NTP_BURST 8 /* packets in burst */ -#define BURST_DELAY 2 /* interburst delay (s) */ -#define RESP_DELAY 1 /* crypto response delay (s) */ +#define NTP_RETRY 3 /* max packet retries */ +#define NTP_MINPKT 2 /* guard time (s) */ /* * Clock filter algorithm tuning parameters @@ -124,25 +120,25 @@ typedef char s_char; */ #define NTP_MINCLOCK 3 /* min survivors */ #define NTP_MAXCLOCK 10 /* max candidates */ -#define NTP_MAXASSOC 50 /* max associations */ -#define MINDISPERSE .005 /* min dispersion increment */ -#define MAXDISTANCE 1. /* max root distance (select threshold) */ +#define MINDISPERSE .001 /* min distance */ +#define MAXDISTANCE 1.5 /* max root distance (select threshold) */ #define CLOCK_SGATE 3. /* popcorn spike gate */ #define HUFFPUFF 900 /* huff-n'-puff sample interval (s) */ #define MAXHOP 2 /* anti-clockhop threshold */ #define MAX_TTL 8 /* max ttl mapping vector size */ #define BEACON 7200 /* manycast beacon interval */ -#define NTP_MAXEXTEN 1024 /* max extension field size */ +#define NTP_MAXEXTEN 2048 /* max extension field size */ +#define NTP_ORPHWAIT 300 /* orphan wair (s) */ /* * Miscellaneous stuff */ #define NTP_MAXKEY 65535 /* max authentication key number */ - +#define KEY_TYPE_MD5 NID_md5 /* MD5 digest NID */ /* * Limits of things */ -#define MAXFILENAME 128 /* max length of file name */ +#define MAXFILENAME 256 /* max length of file name */ #define MAXHOSTNAME 512 /* max length of host/node name */ #define NTP_MAXSTRLEN 256 /* max string length */ @@ -153,48 +149,53 @@ typedef char s_char; * dispersion component (frequency error plus precision). The frequency * error component is computed as CLOCK_PHI times the difference between * the epoch of the time measurement and the reference time. The - * precision componen is computed as the square root of the mean of the + * precision component is computed as the square root of the mean of the * squares of a zero-mean, uniform distribution of unit maximum * amplitude. Whether this makes statistical sense may be arguable. */ #define SQUARE(x) ((x) * (x)) #define SQRT(x) (sqrt(x)) #define DIFF(x, y) (SQUARE((x) - (y))) -#define LOGTOD(a) ((a) < 0 ? 1. / (1L << -(a)) : \ - 1L << (int)(a)) /* log2 to double */ +#define LOGTOD(a) ldexp(1., (int)(a)) /* log2 to double */ #define UNIVAR(x) (SQUARE(.28867513 * LOGTOD(x))) /* std uniform distr */ -#define ULOGTOD(a) (1L << (int)(a)) /* ulog2 to double */ +#define ULOGTOD(a) ldexp(1., (int)(a)) /* ulog2 to double */ #define EVENT_TIMEOUT 0 /* one second, that is */ + /* * The interface structure is used to hold the addresses and socket - * numbers of each of the interfaces we are using. + * numbers of each of the local network addresses we are using. + * Because "interface" is a reserved word in C++ and has so many + * varied meanings, a change to "endpt" (via typedef) is under way. + * Eventually the struct tag will change from interface to endpt_tag. + * endpt is unrelated to the select algorithm's struct endpoint. */ +typedef struct interface endpt; struct interface { - SOCKET fd; /* socket this is opened on */ - SOCKET bfd; /* socket for receiving broadcasts */ - struct sockaddr_storage sin; /* interface address */ - struct sockaddr_storage bcast; /* broadcast address */ - struct sockaddr_storage mask; /* interface mask */ - char name[32]; /* name of interface */ - short family; /* Address family */ - int flags; /* interface flags */ - int last_ttl; /* last TTL specified */ - u_int32 addr_refid; /* IPv4 addr or IPv6 hash */ - int num_mcast; /* No. of IP addresses in multicast socket */ - u_long starttime; /* current_time as of creation of interface structure */ - volatile long received; /* number of incoming packets */ - long sent; /* number of outgoing packets */ - long notsent; /* number of send failures */ - u_int scopeid; /* Scope used for Multicasting */ - u_int ifindex; /* interface index */ - u_int ifnum; /* sequential interface instance count */ - u_char phase; /* phase in update cycle */ - isc_boolean_t ignore_packets; /* Specify whether the packet should be ignored */ - ISC_LIST(struct peer) peers; /* list of peers for the interface */ - u_int peercnt; /* number of peers referencinf this interface - informational only */ - ISC_LINK(struct interface) link; /* interface list */ + endpt * elink; /* endpt list link */ + endpt * mclink; /* per-AF_* multicast list */ + SOCKET fd; /* socket descriptor */ + SOCKET bfd; /* for receiving broadcasts */ + u_int32 ifnum; /* endpt instance count */ + sockaddr_u sin; /* unicast address */ + sockaddr_u mask; /* subnet mask */ + sockaddr_u bcast; /* broadcast address */ + char name[32]; /* name of interface */ + u_short family; /* AF_INET/AF_INET6 */ + u_short phase; /* phase in update cycle */ + u_int32 flags; /* interface flags */ + int last_ttl; /* last TTL specified */ + u_int32 addr_refid; /* IPv4 addr or IPv6 hash */ + int num_mcast; /* mcast addrs enabled */ + u_long starttime; /* current_time at creation */ + volatile long received; /* number of incoming packets */ + long sent; /* number of outgoing packets */ + long notsent; /* number of send failures */ + u_int ifindex; /* for IPV6_MULTICAST_IF */ + isc_boolean_t ignore_packets; /* listen-read-drop this? */ + struct peer * peers; /* list of peers using endpt */ + u_int peercnt; /* count of same */ }; /* @@ -205,10 +206,13 @@ struct interface { #define INT_LOOPBACK 0x004 /* the loopback interface */ #define INT_BROADCAST 0x008 /* can broadcast out this interface */ #define INT_MULTICAST 0x010 /* can multicast out this interface */ -#define INT_BCASTOPEN 0x020 /* broadcast socket is open */ +#define INT_BCASTOPEN 0x020 /* broadcast receive socket is open */ #define INT_MCASTOPEN 0x040 /* multicasting enabled */ -#define INT_WILDCARD 0x080 /* wildcard interface - usually skipped */ -#define INT_MCASTIF 0x100 /* bound directly to MCAST address */ +#define INT_WILDCARD 0x080 /* wildcard interface - usually skipped */ +#define INT_MCASTIF 0x100 /* bound directly to MCAST address */ +#define INT_PRIVACY 0x200 /* RFC 4941 IPv6 privacy address */ +#define INT_BCASTXMIT 0x400 /* socket setup to allow broadcasts */ + /* * Define flasher bits (tests 1 through 11 in packet procedure) * These reveal the state at the last grumble from the peer and are @@ -221,11 +225,11 @@ struct interface { #define TEST2 0x0002 /* bogus packet */ #define TEST3 0x0004 /* protocol unsynchronized */ #define TEST4 0x0008 /* access denied */ -#define TEST5 0x0010 /* authentication error */ +#define TEST5 0x0010 /* bad authentication */ #define TEST6 0x0020 /* bad synch or stratum */ -#define TEST7 0x0040 /* bad header data */ -#define TEST8 0x0080 /* autokey error */ -#define TEST9 0x0100 /* crypto error */ +#define TEST7 0x0040 /* bad header */ +#define TEST8 0x0080 /* bad autokey */ +#define TEST9 0x0100 /* bad crypto */ #define PKT_TEST_MASK (TEST1 | TEST2 | TEST3 | TEST4 | TEST5 |\ TEST6 | TEST7 | TEST8 | TEST9) /* @@ -237,25 +241,21 @@ struct interface { #define TEST13 0x1000 /* peer unreacable */ #define PEER_TEST_MASK (TEST10 | TEST11 | TEST12 | TEST13) -/* - * Authentication codes - */ -#define AUTH_NONE 0 /* no authentication */ -#define AUTH_OK 1 /* authentication OK */ -#define AUTH_ERROR 2 /* authentication error */ -#define AUTH_CRYPTO 3 /* crypto-NAK */ - /* * The peer structure. Holds state information relating to the guys * we are peering with. Most of this stuff is from section 3.2 of the * spec. */ struct peer { - struct peer *next; /* pointer to next association */ - struct peer *ass_next; /* link pointer in associd hash */ - struct sockaddr_storage srcadr; /* address of remote host */ - struct interface *dstadr; /* pointer to address on local host */ - ISC_LINK(struct peer) ilink; /* interface link list */ + struct peer *p_link; /* link pointer in free & peer lists */ + struct peer *adr_link; /* link pointer in address hash */ + struct peer *aid_link; /* link pointer in associd hash */ + struct peer *ilink; /* list of peers for interface */ + sockaddr_u srcadr; /* address of remote host */ + char * hostname; /* if non-NULL, remote name */ + struct addrinfo *addrs; /* hostname query result */ + struct addrinfo *ai; /* position within addrs */ + endpt * dstadr; /* local address */ associd_t associd; /* association ID */ u_char version; /* version number */ u_char hmode; /* local association mode */ @@ -264,10 +264,10 @@ struct peer { u_char maxpoll; /* max poll interval */ u_int flags; /* association flags */ u_char cast_flags; /* additional flags */ - u_int flash; /* protocol error test tally bits */ u_char last_event; /* last peer error code */ u_char num_events; /* number of error events */ - u_char ttl; /* ttl/refclock mode */ + u_int32 ttl; /* ttl/refclock mode */ + char *ident; /* group identifier name */ /* * Variables used by reference clock support @@ -287,8 +287,8 @@ struct peer { u_char stratum; /* remote stratum */ u_char ppoll; /* remote poll interval */ s_char precision; /* remote clock precision */ - double rootdelay; /* roundtrip delay to primary clock */ - double rootdispersion; /* dispersion to primary clock */ + double rootdelay; /* roundtrip delay to primary source */ + double rootdisp; /* dispersion to primary source */ u_int32 refid; /* remote reference ID */ l_fp reftime; /* update epoch */ @@ -296,23 +296,26 @@ struct peer { * Variables used by authenticated client */ keyid_t keyid; /* current key ID */ -#ifdef OPENSSL -#define clear_to_zero assoc +#ifdef AUTOKEY +#define clear_to_zero opcode + u_int32 opcode; /* last request opcode */ associd_t assoc; /* peer association ID */ u_int32 crypto; /* peer status word */ EVP_PKEY *pkey; /* public key */ const EVP_MD *digest; /* message digest algorithm */ char *subject; /* certificate subject name */ char *issuer; /* certificate issuer name */ + struct cert_info *xinfo; /* issuer certificate */ keyid_t pkeyid; /* previous key ID */ + keyid_t hcookie; /* host cookie */ keyid_t pcookie; /* peer cookie */ - EVP_PKEY *ident_pkey; /* identity key */ - tstamp_t fstamp; /* identity filestamp */ - BIGNUM *iffval; /* IFF/GQ challenge */ - BIGNUM *grpkey; /* GQ group key */ - struct value cookval; /* cookie values */ + const struct pkey_info *ident_pkey; /* identity key */ + BIGNUM *iffval; /* identity challenge (IFF, GQ, MV) */ + const BIGNUM *grpkey; /* identity challenge key (GQ) */ + struct value cookval; /* receive cookie values */ struct value recval; /* receive autokey values */ struct exten *cmmd; /* extension pointer */ + u_long refresh; /* next refresh epoch */ /* * Variables used by authenticated server @@ -321,43 +324,59 @@ struct peer { int keynumber; /* current key number */ struct value encrypt; /* send encrypt values */ struct value sndval; /* send autokey values */ - struct value tai_leap; /* send leapsecond table */ -#else /* OPENSSL */ +#else /* !AUTOKEY follows */ #define clear_to_zero status -#endif /* OPENSSL */ +#endif /* !AUTOKEY */ /* * Ephemeral state variables */ u_char status; /* peer status */ + u_char new_status; /* under-construction status */ u_char reach; /* reachability register */ + int flash; /* protocol error test tally bits */ u_long epoch; /* reference epoch */ - u_int burst; /* packets remaining in burst */ - u_int filter_nextpt; /* index into filter shift register */ + int burst; /* packets remaining in burst */ + int retry; /* retry counter */ + int flip; /* interleave mode control */ + int filter_nextpt; /* index into filter shift register */ double filter_delay[NTP_SHIFT]; /* delay shift register */ double filter_offset[NTP_SHIFT]; /* offset shift register */ double filter_disp[NTP_SHIFT]; /* dispersion shift register */ u_long filter_epoch[NTP_SHIFT]; /* epoch shift register */ u_char filter_order[NTP_SHIFT]; /* filter sort index */ - l_fp org; /* originate time stamp */ l_fp rec; /* receive time stamp */ l_fp xmt; /* transmit time stamp */ + l_fp dst; /* destination timestamp */ + l_fp aorg; /* origin timestamp */ + l_fp borg; /* alternate origin timestamp */ double offset; /* peer clock offset */ double delay; /* peer roundtrip delay */ double jitter; /* peer jitter (squares) */ double disp; /* peer dispersion */ - double estbdelay; /* clock offset to broadcast server */ + double xleave; /* interleave delay */ + double bias; /* programmed offset bias */ + + /* + * Variables used to correct for packet length and asymmetry. + */ + double t21; /* outbound packet delay */ + int t21_bytes; /* outbound packet length */ + int t21_last; /* last outbound packet length */ + double r21; /* outbound data rate */ + double t34; /* inbound packet delay */ + int t34_bytes; /* inbound packet length */ + double r34; /* inbound data rate */ /* * End of clear-to-zero area */ u_long update; /* receive epoch */ - u_int unreach; /* unreachable count */ -#define end_clear_to_zero unreach +#define end_clear_to_zero update + int unreach; /* watchdog counter */ + int throttle; /* rate control */ u_long outdate; /* send time last packet */ u_long nextdate; /* send time next packet */ - u_long nextaction; /* peer local activity timeout (refclocks) */ - void (*action) P((struct peer *)); /* action timeout function */ /* * Statistic counters @@ -368,12 +387,12 @@ struct peer { u_long sent; /* packets sent */ u_long received; /* packets received */ - u_long processed; /* packets processed by the protocol */ - u_long badauth; /* packets cryptosum failed */ - u_long bogusorg; /* packets bogus origin */ - u_long oldpkt; /* packets duplicate packet */ - u_long seldisptoolarge; /* packets dispersion too large */ - u_long selbroken; /* not used */ + u_long processed; /* packets processed */ + u_long badauth; /* bad authentication (TEST5) */ + u_long bogusorg; /* bogus origin (TEST2, TEST3) */ + u_long oldpkt; /* old duplicate (TEST1) */ + u_long seldisptoolarge; /* bad header (TEST6, TEST7) */ + u_long selbroken; /* KoD received */ }; /* @@ -390,7 +409,7 @@ struct peer { * function. MODE_CONTROL and MODE_PRIVATE can appear in packets, * but those never survive to the transition function. * is a - */ +/ */ #define MODE_UNSPEC 0 /* unspecified (old version) */ #define MODE_ACTIVE 1 /* symmetric active mode */ #define MODE_PASSIVE 2 /* symmetric passive mode */ @@ -416,23 +435,27 @@ struct peer { #define STRATUM_UNSPEC ((u_char)16) /* unspecified */ /* - * Values for peer.flags + * Values for peer.flags (u_int) */ #define FLAG_CONFIG 0x0001 /* association was configured */ -#define FLAG_AUTHENABLE 0x0002 /* authentication required */ +#define FLAG_PREEMPT 0x0002 /* preemptable association */ #define FLAG_AUTHENTIC 0x0004 /* last message was authentic */ -#define FLAG_SKEY 0x0008 /* autokey authentication */ -#define FLAG_MCAST 0x0010 /* multicast client mode */ -#define FLAG_REFCLOCK 0x0020 /* this is actually a reference clock */ -#define FLAG_SYSPEER 0x0040 /* this is one of the selected peers */ -#define FLAG_PREFER 0x0080 /* this is the preferred peer */ -#define FLAG_BURST 0x0100 /* burst mode */ -#define FLAG_IBURST 0x0200 /* initial burst mode */ -#define FLAG_NOSELECT 0x0400 /* never select */ -#define FLAG_ASSOC 0x0800 /* autokey request */ -#define FLAG_FIXPOLL 0x1000 /* stick at minpoll */ -#define FLAG_TRUE 0x2000 /* select truechimer */ -#define FLAG_PREEMPT 0x4000 /* preemptable association */ +#define FLAG_REFCLOCK 0x0008 /* this is actually a reference clock */ +#define FLAG_BC_VOL 0x0010 /* broadcast client volleying */ +#define FLAG_PREFER 0x0020 /* prefer peer */ +#define FLAG_BURST 0x0040 /* burst mode */ +#define FLAG_PPS 0x0080 /* steered by PPS */ +#define FLAG_IBURST 0x0100 /* initial burst mode */ +#define FLAG_NOSELECT 0x0200 /* never select */ +#define FLAG_TRUE 0x0400 /* force truechimer */ +#define FLAG_SKEY 0x0800 /* autokey authentication */ +#define FLAG_XLEAVE 0x1000 /* interleaved protocol */ +#define FLAG_XB 0x2000 /* interleaved broadcast */ +#define FLAG_XBOGUS 0x4000 /* interleaved bogus packet */ +#ifdef OPENSSL +# define FLAG_ASSOC 0x8000 /* autokey request */ +#endif /* OPENSSL */ +#define FLAG_TSTAMP_PPS 0x10000 /* PPS source provides absolute timestamp */ /* * Definitions for the clear() routine. We use memset() to clear @@ -441,18 +464,12 @@ struct peer { */ #define CLEAR_TO_ZERO(p) ((char *)&((p)->clear_to_zero)) #define END_CLEAR_TO_ZERO(p) ((char *)&((p)->end_clear_to_zero)) -#define LEN_CLEAR_TO_ZERO (END_CLEAR_TO_ZERO((struct peer *)0) \ - - CLEAR_TO_ZERO((struct peer *)0)) +#define LEN_CLEAR_TO_ZERO(p) (END_CLEAR_TO_ZERO(p) - CLEAR_TO_ZERO(p)) #define CRYPTO_TO_ZERO(p) ((char *)&((p)->clear_to_zero)) #define END_CRYPTO_TO_ZERO(p) ((char *)&((p)->end_clear_to_zero)) #define LEN_CRYPTO_TO_ZERO (END_CRYPTO_TO_ZERO((struct peer *)0) \ - CRYPTO_TO_ZERO((struct peer *)0)) -/* - * Reference clock identifiers (for pps signal) - */ -#define PPSREFID (u_int32)"PPS " /* used when pps controls stratum>1 */ - /* * Reference clock types. Added as necessary. */ @@ -500,88 +517,10 @@ struct peer { #define REFCLK_ZYFER 42 /* Zyfer GPStarplus receiver */ #define REFCLK_RIPENCC 43 /* RIPE NCC Trimble driver */ #define REFCLK_NEOCLOCK4X 44 /* NeoClock4X DCF77 or TDF receiver */ -#define REFCLK_MAX 44 /* NeoClock4X DCF77 or TDF receiver */ - - /* - * Macro for sockaddr_storage structures operations - */ -#define SOCKCMP(sock1, sock2) \ - (((struct sockaddr_storage *)sock1)->ss_family \ - == ((struct sockaddr_storage *)sock2)->ss_family ? \ - ((struct sockaddr_storage *)sock1)->ss_family == AF_INET ? \ - memcmp(&((struct sockaddr_in *)sock1)->sin_addr, \ - &((struct sockaddr_in *)sock2)->sin_addr, \ - sizeof(struct in_addr)) == 0 : \ - memcmp(&((struct sockaddr_in6 *)sock1)->sin6_addr, \ - &((struct sockaddr_in6 *)sock2)->sin6_addr, \ - sizeof(struct in6_addr)) == 0 : \ - 0) - -#define SOCKNUL(sock1) \ - (((struct sockaddr_storage *)sock1)->ss_family == AF_INET ? \ - (((struct sockaddr_in *)sock1)->sin_addr.s_addr == 0) : \ - (IN6_IS_ADDR_UNSPECIFIED(&((struct sockaddr_in6 *)sock1)->sin6_addr))) - -#define SOCKLEN(sock) \ - (((struct sockaddr_storage *)sock)->ss_family == AF_INET ? \ - (sizeof(struct sockaddr_in)) : (sizeof(struct sockaddr_in6))) +#define REFCLK_TSYNCPCI 45 /* Spectracom TSYNC PCI timing board */ +#define REFCLK_GPSDJSON 46 +#define REFCLK_MAX 46 -#define ANYSOCK(sock) \ - memset(((struct sockaddr_storage *)sock), 0, \ - sizeof(struct sockaddr_storage)) - -#define ANY_INTERFACE_CHOOSE(sock) \ - (((struct sockaddr_storage *)sock)->ss_family == AF_INET ? \ - any_interface : any6_interface) - -/* - * We tell reference clocks from real peers by giving the reference - * clocks an address of the form 127.127.t.u, where t is the type and - * u is the unit number. We define some of this here since we will need - * some sanity checks to make sure this address isn't interpretted as - * that of a normal peer. - */ -#define REFCLOCK_ADDR 0x7f7f0000 /* 127.127.0.0 */ -#define REFCLOCK_MASK 0xffff0000 /* 255.255.0.0 */ - -#define ISREFCLOCKADR(srcadr) ((SRCADR(srcadr) & REFCLOCK_MASK) \ - == REFCLOCK_ADDR) - -/* - * Macro for checking for invalid addresses. This is really, really - * gross, but is needed so no one configures a host on net 127 now that - * we're encouraging it the the configuration file. - */ -#define LOOPBACKADR 0x7f000001 -#define LOOPNETMASK 0xff000000 - -#define ISBADADR(srcadr) (((SRCADR(srcadr) & LOOPNETMASK) \ - == (LOOPBACKADR & LOOPNETMASK)) \ - && (SRCADR(srcadr) != LOOPBACKADR)) - -/* - * Utilities for manipulating addresses and port numbers - */ -#define NSRCADR(src) (((struct sockaddr_in *)src)->sin_addr.s_addr) /* address in net byte order */ -#define NSRCPORT(src) (((struct sockaddr_in *)src)->sin_port) /* port in net byte order */ -#define SRCADR(src) (ntohl(NSRCADR((src)))) /* address in host byte order */ -#define SRCPORT(src) (ntohs(NSRCPORT((src)))) /* host port */ - -#define CAST_V4(src) ((struct sockaddr_in *)&(src)) -#define CAST_V6(src) ((struct sockaddr_in6 *)&(src)) -#define GET_INADDR(src) (CAST_V4(src)->sin_addr.s_addr) -#define GET_INADDR6(src) (CAST_V6(src)->sin6_addr) - -#define SET_HOSTMASK(addr, family) \ - do { \ - memset((char *)(addr), 0, sizeof(struct sockaddr_storage)); \ - (addr)->ss_family = (family); \ - if ((family) == AF_INET) \ - GET_INADDR(*(addr)) = 0xffffffff; \ - else \ - memset(&GET_INADDR6(*(addr)), 0xff, \ - sizeof(struct in6_addr)); \ - } while(0) /* * NTP packet format. The mac field is optional. It isn't really @@ -592,39 +531,45 @@ struct peer { * and must be converted (except the mac, which isn't, really). */ struct pkt { - u_char li_vn_mode; /* leap indicator, version and mode */ + u_char li_vn_mode; /* peer leap indicator */ u_char stratum; /* peer stratum */ u_char ppoll; /* peer poll interval */ s_char precision; /* peer clock precision */ - u_fp rootdelay; /* distance to primary clock */ - u_fp rootdispersion; /* clock dispersion */ - u_int32 refid; /* reference clock ID */ - l_fp reftime; /* time peer clock was last updated */ + u_fp rootdelay; /* roundtrip delay to primary source */ + u_fp rootdisp; /* dispersion to primary source*/ + u_int32 refid; /* reference id */ + l_fp reftime; /* last update time */ l_fp org; /* originate time stamp */ l_fp rec; /* receive time stamp */ l_fp xmt; /* transmit time stamp */ -#define LEN_PKT_NOMAC 12 * sizeof(u_int32) /* min header length */ -#define LEN_PKT_MAC LEN_PKT_NOMAC + sizeof(u_int32) -#define MIN_MAC_LEN 3 * sizeof(u_int32) /* DES */ -#define MAX_MAC_LEN 5 * sizeof(u_int32) /* MD5 */ +#define LEN_PKT_NOMAC (12 * sizeof(u_int32)) /* min header length */ +#define MIN_MAC_LEN (1 * sizeof(u_int32)) /* crypto_NAK */ +#define MAX_MD5_LEN (5 * sizeof(u_int32)) /* MD5 */ +#define MAX_MAC_LEN (6 * sizeof(u_int32)) /* SHA */ /* * The length of the packet less MAC must be a multiple of 64 - * with an RSA modulus and Diffie-Hellman prime of 64 octets + * with an RSA modulus and Diffie-Hellman prime of 256 octets * and maximum host name of 128 octets, the maximum autokey * command is 152 octets and maximum autokey response is 460 * octets. A packet can contain no more than one command and one - * response, so the maximum total extension field length is 672 + * response, so the maximum total extension field length is 864 * octets. But, to handle humungus certificates, the bank must * be broke. + * + * The different definitions of the 'exten' field are here for + * the benefit of applications that want to send a packet from + * an auto variable in the stack - not using the AUTOKEY version + * saves 2KB of stack space. The receive buffer should ALWAYS be + * big enough to hold a full extended packet if the extension + * fields have to be parsed or skipped. */ -#ifdef OPENSSL - u_int32 exten[NTP_MAXEXTEN / 4]; /* max extension field */ -#else /* OPENSSL */ - u_int32 exten[1]; /* misused */ -#endif /* OPENSSL */ - u_char mac[MAX_MAC_LEN]; /* mac */ +#ifdef AUTOKEY + u_int32 exten[(NTP_MAXEXTEN + MAX_MAC_LEN) / sizeof(u_int32)]; +#else /* !AUTOKEY follows */ + u_int32 exten[(MAX_MAC_LEN) / sizeof(u_int32)]; +#endif /* !AUTOKEY */ }; /* @@ -635,10 +580,11 @@ struct pkt { #define PKT_LEAP(li_vn_mode) ((u_char)(((li_vn_mode) >> 6) & 0x3)) /* - * Stuff for putting things back into li_vn_mode + * Stuff for putting things back into li_vn_mode in packets and vn_mode + * in ntp_monitor.c's mon_entry. */ -#define PKT_LI_VN_MODE(li, vn, md) \ - ((u_char)((((li) << 6) & 0xc0) | (((vn) << 3) & 0x38) | ((md) & 0x7))) +#define VN_MODE(v, m) ((((v) & 7) << 3) | ((m) & 0x7)) +#define PKT_LI_VN_MODE(l, v, m) ((((l) & 3) << 6) | VN_MODE((v), (m))) /* @@ -661,33 +607,51 @@ struct pkt { * System event codes */ #define EVNT_UNSPEC 0 /* unspecified */ -#define EVNT_SYSRESTART 1 /* system restart */ -#define EVNT_SYSFAULT 2 /* wsystem or hardware fault */ -#define EVNT_SYNCCHG 3 /* new leap or synch change */ -#define EVNT_PEERSTCHG 4 /* new source or stratum */ -#define EVNT_CLOCKRESET 5 /* clock reset */ -#define EVNT_BADDATETIM 6 /* invalid time or date */ -#define EVNT_CLOCKEXCPT 7 /* reference clock exception */ +#define EVNT_NSET 1 /* freq not set */ +#define EVNT_FSET 2 /* freq set */ +#define EVNT_SPIK 3 /* spike detect */ +#define EVNT_FREQ 4 /* freq mode */ +#define EVNT_SYNC 5 /* clock sync */ +#define EVNT_SYSRESTART 6 /* restart */ +#define EVNT_SYSFAULT 7 /* panic stop */ +#define EVNT_NOPEER 8 /* no sys peer */ +#define EVNT_ARMED 9 /* leap armed */ +#define EVNT_DISARMED 10 /* leap disarmed */ +#define EVNT_LEAP 11 /* leap event */ +#define EVNT_CLOCKRESET 12 /* clock step */ +#define EVNT_KERN 13 /* kernel event */ +#define EVNT_TAI 14 /* TAI */ +#define EVNT_LEAPVAL 15 /* stale leapsecond values */ /* * Peer event codes */ -#define EVNT_PEERIPERR (1 | PEER_EVENT) /* IP error */ -#define EVNT_PEERAUTH (2 | PEER_EVENT) /* authentication failure */ -#define EVNT_UNREACH (3 | PEER_EVENT) /* change to unreachable */ -#define EVNT_REACH (4 | PEER_EVENT) /* change to reachable */ -#define EVNT_PEERCLOCK (5 | PEER_EVENT) /* clock exception */ +#define PEVNT_MOBIL (1 | PEER_EVENT) /* mobilize */ +#define PEVNT_DEMOBIL (2 | PEER_EVENT) /* demobilize */ +#define PEVNT_UNREACH (3 | PEER_EVENT) /* unreachable */ +#define PEVNT_REACH (4 | PEER_EVENT) /* reachable */ +#define PEVNT_RESTART (5 | PEER_EVENT) /* restart */ +#define PEVNT_REPLY (6 | PEER_EVENT) /* no reply */ +#define PEVNT_RATE (7 | PEER_EVENT) /* rate exceeded */ +#define PEVNT_DENY (8 | PEER_EVENT) /* access denied */ +#define PEVNT_ARMED (9 | PEER_EVENT) /* leap armed */ +#define PEVNT_NEWPEER (10 | PEER_EVENT) /* sys peer */ +#define PEVNT_CLOCK (11 | PEER_EVENT) /* clock event */ +#define PEVNT_AUTH (12 | PEER_EVENT) /* bad auth */ +#define PEVNT_POPCORN (13 | PEER_EVENT) /* popcorn */ +#define PEVNT_XLEAVE (14 | PEER_EVENT) /* interleave mode */ +#define PEVNT_XERR (15 | PEER_EVENT) /* interleave error */ /* * Clock event codes */ #define CEVNT_NOMINAL 0 /* unspecified */ -#define CEVNT_TIMEOUT 1 /* poll timeout */ -#define CEVNT_BADREPLY 2 /* bad reply format */ -#define CEVNT_FAULT 3 /* hardware or software fault */ -#define CEVNT_PROP 4 /* propagation failure */ -#define CEVNT_BADDATE 5 /* bad date format or value */ -#define CEVNT_BADTIME 6 /* bad time format or value */ +#define CEVNT_TIMEOUT 1 /* no reply */ +#define CEVNT_BADREPLY 2 /* bad format */ +#define CEVNT_FAULT 3 /* fault */ +#define CEVNT_PROP 4 /* bad signal */ +#define CEVNT_BADDATE 5 /* bad date */ +#define CEVNT_BADTIME 6 /* bad time */ #define CEVNT_MAX CEVNT_BADTIME /* @@ -700,15 +664,9 @@ struct pkt { * To speed lookups, peers are hashed by the low order bits of the * remote IP address. These definitions relate to that. */ -#define NTP_HASH_SIZE 128 -#define NTP_HASH_MASK (NTP_HASH_SIZE-1) -#define NTP_HASH_ADDR(src) sock_hash(src) - -/* - * How we randomize polls. The poll interval is a power of two. We chose - * a random interval which is this value plus-minus one second. - */ -#define RANDPOLL(x) ((1 << (x)) - 1 + (ntp_random() & 0x3)) +#define NTP_HASH_SIZE 128 +#define NTP_HASH_MASK (NTP_HASH_SIZE-1) +#define NTP_HASH_ADDR(src) (sock_hash(src) & NTP_HASH_MASK) /* * min, min3 and max. Makes it easier to transliterate the spec without @@ -744,25 +702,31 @@ struct pkt { #define PROTO_CALLDELAY 20 #define PROTO_MINDISP 21 #define PROTO_MAXDIST 22 -#define PROTO_ADJ 23 + /* available 23 */ #define PROTO_MAXHOP 24 #define PROTO_BEACON 25 #define PROTO_ORPHAN 26 +#define PROTO_ORPHWAIT 27 +#define PROTO_MODE7 28 /* * Configuration items for the loop filter */ -#define LOOP_DRIFTINIT 1 /* set initial frequency offset */ -#define LOOP_DRIFTCOMP 2 /* set frequency offset */ -#define LOOP_MAX 3 /* set step offset */ -#define LOOP_PANIC 4 /* set panic offseet */ -#define LOOP_PHI 5 /* set dispersion rate */ -#define LOOP_MINSTEP 6 /* set step timeout */ -#define LOOP_MINPOLL 7 /* set min poll interval (log2 s) */ -#define LOOP_ALLAN 8 /* set minimum Allan intercept */ -#define LOOP_HUFFPUFF 9 /* set huff-n'-puff filter length */ -#define LOOP_FREQ 10 /* set initial frequency */ -#define LOOP_KERN_CLEAR 11 /* reset kernel pll parameters */ +#define LOOP_DRIFTINIT 1 /* iniitialize frequency */ +#define LOOP_KERN_CLEAR 2 /* set initial frequency offset */ +#define LOOP_MAX 3 /* set both step offsets */ +#define LOOP_MAX_BACK 4 /* set bacward-step offset */ +#define LOOP_MAX_FWD 5 /* set forward-step offset */ +#define LOOP_PANIC 6 /* set panic offseet */ +#define LOOP_PHI 7 /* set dispersion rate */ +#define LOOP_MINSTEP 8 /* set step timeout */ +#define LOOP_MINPOLL 9 /* set min poll interval (log2 s) */ +#define LOOP_ALLAN 10 /* set minimum Allan intercept */ +#define LOOP_HUFFPUFF 11 /* set huff-n'-puff filter length */ +#define LOOP_FREQ 12 /* set initial frequency */ +#define LOOP_CODEC 13 /* set audio codec frequency */ +#define LOOP_LEAP 14 /* insert leap after second 23:59 */ +#define LOOP_TICK 15 /* sim. low precision clock */ /* * Configuration items for the stats printer @@ -770,105 +734,128 @@ struct pkt { #define STATS_FREQ_FILE 1 /* configure drift file */ #define STATS_STATSDIR 2 /* directory prefix for stats files */ #define STATS_PID_FILE 3 /* configure ntpd PID file */ +#define STATS_LEAP_FILE 4 /* configure ntpd leapseconds file */ #define MJD_1900 15020 /* MJD for 1 Jan 1900 */ /* * Default parameters. We use these in the absence of something better. */ -#define DEFBROADDELAY 4e-3 /* default broadcast offset */ #define INADDR_NTP 0xe0000101 /* NTP multicast address 224.0.1.1 */ /* * Structure used optionally for monitoring when this is turned on. */ +typedef struct mon_data mon_entry; struct mon_data { - struct mon_data *hash_next; /* next structure in hash list */ - struct mon_data *mru_next; /* next structure in MRU list */ - struct mon_data *mru_prev; /* previous structure in MRU list */ - u_long drop_count; /* dropped due RESLIMIT*/ - double avg_interval; /* average interpacket interval */ - u_long lasttime; /* interval since last packet */ - u_long count; /* total packet count */ - struct sockaddr_storage rmtadr; /* address of remote host */ - struct interface *interface; /* interface on which this arrived */ - u_short rmtport; /* remote port last came from */ - u_char mode; /* mode of incoming packet */ - u_char version; /* version of incoming packet */ - u_char cast_flags; /* flags MDF_?CAST */ + mon_entry * hash_next; /* next structure in hash list */ + DECL_DLIST_LINK(mon_entry, mru);/* MRU list link pointers */ + struct interface * lcladr; /* address on which this arrived */ + l_fp first; /* first time seen */ + l_fp last; /* last time seen */ + int leak; /* leaky bucket accumulator */ + int count; /* total packet count */ + u_short flags; /* restrict flags */ + u_char vn_mode; /* packet mode & version */ + u_char cast_flags; /* flags MDF_?CAST */ + sockaddr_u rmtadr; /* address of remote host */ }; /* - * Values for cast_flags + * Values for cast_flags in mon_entry and struct peer. mon_entry uses + * only the first three, MDF_UCAST, MDF_MCAST, and MDF_BCAST. */ -#define MDF_UCAST 0x01 /* unicast */ -#define MDF_MCAST 0x02 /* multicast */ -#define MDF_BCAST 0x04 /* broadcast */ -#define MDF_LCAST 0x08 /* localcast */ -#define MDF_ACAST 0x10 /* manycast */ -#define MDF_BCLNT 0x20 /* broadcast client */ -#define MDF_ACLNT 0x40 /* manycast client */ - +#define MDF_UCAST 0x01 /* unicast client */ +#define MDF_MCAST 0x02 /* multicast server */ +#define MDF_BCAST 0x04 /* broadcast server */ +#define MDF_POOL 0x08 /* pool client solicitor */ +#define MDF_ACAST 0x10 /* manycast client solicitor */ +#define MDF_BCLNT 0x20 /* eph. broadcast/multicast client */ +#define MDF_UCLNT 0x40 /* preemptible manycast or pool client */ +/* + * In the context of struct peer in ntpd, three of the cast_flags bits + * represent configured associations which never receive packets, and + * whose reach is always 0: MDF_BCAST, MDF_MCAST, and MDF_ACAST. The + * last can be argued as responses are received, but those responses do + * not affect the MDF_ACAST association's reach register, rather they + * (may) result in mobilizing ephemeral MDF_ACLNT associations. + */ +#define MDF_TXONLY_MASK (MDF_BCAST | MDF_MCAST | MDF_ACAST | MDF_POOL) +/* + * manycastclient-like solicitor association cast_flags bits + */ +#define MDF_SOLICIT_MASK (MDF_ACAST | MDF_POOL) /* * Values used with mon_enabled to indicate reason for enabling monitoring */ -#define MON_OFF 0x00 /* no monitoring */ -#define MON_ON 0x01 /* monitoring explicitly enabled */ -#define MON_RES 0x02 /* implicit monitoring for RES_LIMITED */ +#define MON_OFF 0x00 /* no monitoring */ +#define MON_ON 0x01 /* monitoring explicitly enabled */ +#define MON_RES 0x02 /* implicit monitoring for RES_LIMITED */ /* * Structure used for restrictlist entries */ -struct restrictlist { - struct restrictlist *next; /* link to next entry */ - u_int32 addr; /* Ipv4 host address (host byte order) */ - u_int32 mask; /* Ipv4 mask for address (host byte order) */ - u_long count; /* number of packets matched */ - u_short flags; /* accesslist flags */ - u_short mflags; /* match flags */ -}; - -struct restrictlist6 { - struct restrictlist6 *next; /* link to next entry */ - struct in6_addr addr6; /* Ipv6 host address */ - struct in6_addr mask6; /* Ipv6 mask address */ - u_long count; /* number of packets matched */ - u_short flags; /* accesslist flags */ - u_short mflags; /* match flags */ +typedef struct res_addr4_tag { + u_int32 addr; /* IPv4 addr (host order) */ + u_int32 mask; /* IPv4 mask (host order) */ +} res_addr4; + +typedef struct res_addr6_tag { + struct in6_addr addr; /* IPv6 addr (net order) */ + struct in6_addr mask; /* IPv6 mask (net order) */ +} res_addr6; + +typedef struct restrict_u_tag restrict_u; +struct restrict_u_tag { + restrict_u * link; /* link to next entry */ + u_int32 count; /* number of packets matched */ + u_short flags; /* accesslist flags */ + u_short mflags; /* match flags */ + u_long expire; /* valid until time */ + union { /* variant starting here */ + res_addr4 v4; + res_addr6 v6; + } u; }; - +#define V4_SIZEOF_RESTRICT_U (offsetof(restrict_u, u) \ + + sizeof(res_addr4)) +#define V6_SIZEOF_RESTRICT_U (offsetof(restrict_u, u) \ + + sizeof(res_addr6)) /* * Access flags */ -#define RES_IGNORE 0x001 /* ignore packet */ -#define RES_DONTSERVE 0x002 /* access denied */ -#define RES_DONTTRUST 0x004 /* authentication required */ -#define RES_VERSION 0x008 /* version mismatch */ -#define RES_NOPEER 0x010 /* new association denied */ -#define RES_LIMITED 0x020 /* packet rate exceeded */ - +#define RES_IGNORE 0x0001 /* ignore packet */ +#define RES_DONTSERVE 0x0002 /* access denied */ +#define RES_DONTTRUST 0x0004 /* authentication required */ +#define RES_VERSION 0x0008 /* version mismatch */ +#define RES_NOPEER 0x0010 /* new association denied */ +#define RES_LIMITED 0x0020 /* packet rate exceeded */ #define RES_FLAGS (RES_IGNORE | RES_DONTSERVE |\ RES_DONTTRUST | RES_VERSION |\ RES_NOPEER | RES_LIMITED) -#define RES_NOQUERY 0x040 /* mode 6/7 packet denied */ -#define RES_NOMODIFY 0x080 /* mode 6/7 modify denied */ -#define RES_NOTRAP 0x100 /* mode 6/7 set trap denied */ -#define RES_LPTRAP 0x200 /* mode 6/7 low priority trap */ +#define RES_NOQUERY 0x0040 /* mode 6/7 packet denied */ +#define RES_NOMODIFY 0x0080 /* mode 6/7 modify denied */ +#define RES_NOTRAP 0x0100 /* mode 6/7 set trap denied */ +#define RES_LPTRAP 0x0200 /* mode 6/7 low priority trap */ -#define RES_DEMOBILIZE 0x400 /* send kiss of death packet */ -#define RES_TIMEOUT 0x800 /* timeout this entry */ +#define RES_KOD 0x0400 /* send kiss of death packet */ +#define RES_MSSNTP 0x0800 /* enable MS-SNTP authentication */ +#define RES_FLAKE 0x1000 /* flakeway - drop 10% */ +#define RES_NOMRULIST 0x2000 /* mode 6 mrulist denied */ -#define RES_ALLFLAGS (RES_FLAGS | RES_NOQUERY |\ - RES_NOMODIFY | RES_NOTRAP |\ - RES_LPTRAP | RES_DEMOBILIZE |\ - RES_TIMEOUT) +#define RES_ALLFLAGS (RES_FLAGS | RES_NOQUERY | \ + RES_NOMODIFY | RES_NOTRAP | \ + RES_LPTRAP | RES_KOD | \ + RES_MSSNTP | RES_FLAKE | \ + RES_NOMRULIST) /* * Match flags */ -#define RESM_INTERFACE 0x1 /* this is an interface */ -#define RESM_NTPONLY 0x2 /* match ntp port only */ +#define RESM_INTERFACE 0x1000 /* this is an interface */ +#define RESM_NTPONLY 0x2000 /* match source port 123 */ +#define RESM_SOURCE 0x4000 /* from "restrict source" */ /* * Restriction configuration ops @@ -876,7 +863,7 @@ struct restrictlist6 { #define RESTRICT_FLAGS 1 /* add flags to restrict entry */ #define RESTRICT_UNFLAG 2 /* remove flags from restrict entry */ #define RESTRICT_REMOVE 3 /* remove a restrict entry */ -#define RESTRICT_REMOVEIF 4 /* remove an interface restrict entry */ +#define RESTRICT_REMOVEIF 4 /* remove an interface restrict entry */ /* * Endpoint structure for the select algorithm @@ -891,17 +878,21 @@ struct endpoint { */ #define AM_ERR -1 /* error */ #define AM_NOMATCH 0 /* no match */ -#define AM_PROCPKT 1 /* server/symmetric packet */ -#define AM_BCST 2 /* broadcast packet */ +#define AM_PROCPKT 1 /* server/symmetric packet */ +#define AM_BCST 2 /* broadcast packet */ #define AM_FXMIT 3 /* client packet */ -#define AM_MANYCAST 4 /* manycast packet */ +#define AM_MANYCAST 4 /* manycast or pool */ #define AM_NEWPASS 5 /* new passive */ #define AM_NEWBCL 6 /* new broadcast */ -#define AM_POSSBCL 7 /* discard broadcast */ +#define AM_POSSBCL 7 /* discard broadcast */ /* NetInfo configuration locations */ #ifdef HAVE_NETINFO #define NETINFO_CONFIG_DIR "/config/ntp" #endif +/* ntpq -c mrulist rows per request limit in ntpd */ +#define MRU_ROW_LIMIT 256 +/* similar datagrams per response limit for ntpd */ +#define MRU_FRAGS_LIMIT 128 #endif /* NTP_H */ diff --git a/contrib/ntp/include/ntp_assert.h b/contrib/ntp/include/ntp_assert.h new file mode 100644 index 000000000..42d78acab --- /dev/null +++ b/contrib/ntp/include/ntp_assert.h @@ -0,0 +1,104 @@ +/* + * ntp_assert.h - design by contract stuff + * + * example: + * + * int foo(char *a) { + * int result; + * int value; + * + * REQUIRE(a != NULL); + * ... + * bar(&value); + * INSIST(value > 2); + * ... + * + * ENSURE(result != 12); + * return result; + * } + * + * open question: when would we use INVARIANT()? + * + * For cases where the overhead for non-debug builds is deemed too high, + * use DEBUG_REQUIRE(), DEBUG_INSIST(), DEBUG_ENSURE(), and/or + * DEBUG_INVARIANT(). + */ + +#ifndef NTP_ASSERT_H +#define NTP_ASSERT_H + +# ifdef CALYSTO +/* see: http://www.domagoj-babic.com/index.php/ResearchProjects/Calysto */ + +extern void calysto_assume(unsigned char cnd); /* assume this always holds */ +extern void calysto_assert(unsigned char cnd); /* check whether this holds */ +#define ALWAYS_REQUIRE(x) calysto_assert(x) +#define ALWAYS_INSIST(x) calysto_assume(x) /* DLH calysto_assert()? */ +#define ALWAYS_INVARIANT(x) calysto_assume(x) +#define ALWAYS_ENSURE(x) calysto_assert(x) + +/* # elif defined(__COVERITY__) */ +/* + * DH: try letting coverity scan our actual assertion macros, now that + * isc_assertioncallback_t is marked __attribute__ __noreturn__. + */ + +/* + * Coverity has special knowledge that assert(x) terminates the process + * if x is not true. Rather than teach it about our assertion macros, + * just use the one it knows about for Coverity Prevent scans. This + * means our assertion code (and ISC's) escapes Coverity analysis, but + * that seems to be a reasonable trade-off. + */ + +/* +#define ALWAYS_REQUIRE(x) assert(x) +#define ALWAYS_INSIST(x) assert(x) +#define ALWAYS_INVARIANT(x) assert(x) +#define ALWAYS_ENSURE(x) assert(x) +*/ + + +#elif defined(__FLEXELINT__) + +#include + +#define ALWAYS_REQUIRE(x) assert(x) +#define ALWAYS_INSIST(x) assert(x) +#define ALWAYS_INVARIANT(x) assert(x) +#define ALWAYS_ENSURE(x) assert(x) + +# else /* neither Calysto, Coverity or FlexeLint */ + +#include "isc/assertions.h" + +#define ALWAYS_REQUIRE(x) ISC_REQUIRE(x) +#define ALWAYS_INSIST(x) ISC_INSIST(x) +#define ALWAYS_INVARIANT(x) ISC_INVARIANT(x) +#define ALWAYS_ENSURE(x) ISC_ENSURE(x) + +# endif /* neither Coverity nor Calysto */ + +#define REQUIRE(x) ALWAYS_REQUIRE(x) +#define INSIST(x) ALWAYS_INSIST(x) +#define INVARIANT(x) ALWAYS_INVARIANT(x) +#define ENSURE(x) ALWAYS_ENSURE(x) + +/* + * We initially used NTP_REQUIRE() instead of REQUIRE() etc, but that + * is unneccesarily verbose, as libisc use of REQUIRE() etc shows. + */ + +# ifdef DEBUG +#define DEBUG_REQUIRE(x) REQUIRE(x) +#define DEBUG_INSIST(x) INSIST(x) +#define DEBUG_INVARIANT(x) INVARIANT(x) +#define DEBUG_ENSURE(x) ENSURE(x) +# else +#define DEBUG_REQUIRE(x) do {} while (FALSE) +#define DEBUG_INSIST(x) do {} while (FALSE) +#define DEBUG_INVARIANT(x) do {} while (FALSE) +#define DEBUG_ENSURE(x) do {} while (FALSE) +# endif + +#endif /* NTP_ASSERT_H */ diff --git a/contrib/ntp/include/ntp_calendar.h b/contrib/ntp/include/ntp_calendar.h index 95e2c1297..6f36c0777 100644 --- a/contrib/ntp/include/ntp_calendar.h +++ b/contrib/ntp/include/ntp_calendar.h @@ -4,20 +4,62 @@ #ifndef NTP_CALENDAR_H #define NTP_CALENDAR_H +#include + #include "ntp_types.h" +/* gregorian calendar date */ struct calendar { - u_short year; /* year (A.D.) */ - u_short yearday; /* day of year, 1 = January 1 */ - u_char month; /* month, 1 = January */ - u_char monthday; /* day of month */ - u_char hour; /* hour of day, midnight = 0 */ - u_char minute; /* minute of hour */ - u_char second; /* second of minute */ + uint16_t year; /* year (A.D.) */ + uint16_t yearday; /* day of year, 1 = January 1 */ + uint8_t month; /* month, 1 = January */ + uint8_t monthday; /* day of month */ + uint8_t hour; /* hour of day, midnight = 0 */ + uint8_t minute; /* minute of hour */ + uint8_t second; /* second of minute */ + uint8_t weekday; /* 0..7, 0=Sunday */ +}; + +/* ISO week calendar date */ +struct isodate { + uint16_t year; /* year (A.D.) */ + uint8_t week; /* 1..53, week in year */ + uint8_t weekday; /* 1..7, 1=Monday */ + uint8_t hour; /* hour of day, midnight = 0 */ + uint8_t minute; /* minute of hour */ + uint8_t second; /* second of minute */ }; +/* general split representation */ +typedef struct { + int32_t hi; + int32_t lo; +} ntpcal_split; + +typedef time_t (*systime_func_ptr)(time_t *); + +/* + * set the function for getting the system time. This is mostly used for + * unit testing to provide a fixed / shifted time stamp. Setting the + * value to NULL restores the original function, that is, 'time()', + * which is also the automatic default. + */ +extern systime_func_ptr ntpcal_set_timefunc(systime_func_ptr); + /* - * Days in each month. 30 days hath September... + * days-of-week + */ +#define CAL_SUNDAY 0 +#define CAL_MONDAY 1 +#define CAL_TUESDAY 2 +#define CAL_WEDNESDAY 3 +#define CAL_THURSDAY 4 +#define CAL_FRIDAY 5 +#define CAL_SATURDAY 6 +#define CAL_SUNDAY7 7 /* also sunday */ + +/* + * Days in each month. 30 days hath September... */ #define JAN 31 #define FEB 28 @@ -34,52 +76,311 @@ struct calendar { #define DEC 31 /* - * We deal in a 4 year cycle starting at March 1, 1900. We assume + * We deal in a 4 year cycle starting at March 1, 1900. We assume * we will only want to deal with dates since then, and not to exceed * the rollover day in 2036. */ #define SECSPERMIN (60) /* seconds per minute */ #define MINSPERHR (60) /* minutes per hour */ #define HRSPERDAY (24) /* hours per day */ +#define DAYSPERWEEK (7) /* days per week */ #define DAYSPERYEAR (365) /* days per year */ -#define SECSPERDAY (SECSPERMIN*MINSPERHR*HRSPERDAY) -#define SECSPERYEAR (365 * SECSPERDAY) /* regular year */ +#define SECSPERHR (SECSPERMIN * MINSPERHR) +#define SECSPERDAY (SECSPERHR * HRSPERDAY) +#define SECSPERWEEK (DAYSPERWEEK * SECSPERDAY) +#define SECSPERYEAR (365 * SECSPERDAY) /* regular year */ #define SECSPERLEAPYEAR (366 * SECSPERDAY) /* leap year */ - -#define MAR1900 ((JAN+FEB) * SECSPERDAY) /* no leap year in 1900 */ -#define DAYSPERCYCLE (365+365+365+366) /* 3 normal years plus leap */ -#define SECSPERCYCLE (DAYSPERCYCLE*SECSPERDAY) -#define YEARSPERCYCLE 4 +#define SECSPERAVGYEAR 31556952 /* mean year length over 400yrs */ /* - * Gross hacks. I have illicit knowlege that there won't be overflows + * Gross hacks. I have illicit knowlege that there won't be overflows * here, the compiler often can't tell this. */ -#define TIMES60(val) ((((val)<<4) - (val))<<2) /* *(16 - 1) * 4 */ +#define TIMES60(val) ((((val)<<4) - (val))<<2) /* *(16 - 1) * 4 */ #define TIMES24(val) (((val)<<4) + ((val)<<3)) /* *16 + *8 */ -#define TIMES7(val) (((val)<<3) - (val)) /* *8 - *1 */ +#define TIMES7(val) (((val)<<3) - (val)) /* *8 - *1 */ #define TIMESDPERC(val) (((val)<<10) + ((val)<<8) \ + ((val)<<7) + ((val)<<5) \ + ((val)<<4) + ((val)<<2) + (val)) /* *big* hack */ + +extern const char * const months[12]; +extern const char * const daynames[7]; + +extern void caljulian (uint32_t, struct calendar *); +extern uint32_t caltontp (const struct calendar *); + /* - * Another big hack. Cycle 22 started on March 1, 1988. This is - * STARTCYCLE22 seconds after the start of cycle 0. + * Convert between 'time_t' and 'vint64' */ -#define CYCLE22 (22) -#define STARTCYCLE22 (u_long)(0xa586b500) /* 2777068800 */ -#define MAR1988 (u_long)(STARTCYCLE22 + (u_long)MAR1900) +extern vint64 time_to_vint64(const time_t *); +extern time_t vint64_to_time(const vint64 *); /* - * The length of January + February in leap and non-leap years. + * Get the build date & time. ATTENTION: The time zone is not specified! + * This depends entirely on the C compilers' capabilities to properly + * expand the '__TIME__' and '__DATE__' macros, as required by the C + * standard. */ -#define JANFEBNOLEAP ((JAN+FEB) * SECSPERDAY) -#define JANFEBLEAP ((JAN+FEBLEAP) * SECSPERDAY) +extern int +ntpcal_get_build_date(struct calendar * /* jd */); +/* + * Convert a timestamp in NTP scale to a time_t value in the UN*X + * scale with proper epoch unfolding around a given pivot or the + * current system time. + */ +extern vint64 +ntpcal_ntp_to_time(uint32_t /* ntp */, const time_t * /* pivot */); + +/* + * Convert a timestamp in NTP scale to a 64bit seconds value in the NTP + * scale with proper epoch unfolding around a given pivot or the current + * system time. + * Note: The pivot must be given in UN*X time scale! + */ +extern vint64 +ntpcal_ntp_to_ntp(uint32_t /* ntp */, const time_t * /* pivot */); + +/* + * Split a time stamp in seconds into elapsed days and elapsed seconds + * since midnight. + */ +extern ntpcal_split +ntpcal_daysplit(const vint64 *); -extern void caljulian P((u_long, struct calendar *)); -extern u_long caltontp P((const struct calendar *)); +/* + * Merge a number of days and a number of seconds into seconds, + * expressed in 64 bits to avoid overflow. + */ +extern vint64 +ntpcal_dayjoin(int32_t /* days */, int32_t /* seconds */); + +/* Get the number of leap years since epoch for the number of elapsed + * full years + */ +extern int32_t +ntpcal_leapyears_in_years(int32_t /* years */); + +/* + * Convert elapsed years in Era into elapsed days in Era. + */ +extern int32_t +ntpcal_days_in_years(int32_t /* years */); + +/* + * Convert a number of elapsed month in a year into elapsed days + * in year. + * + * The month will be normalized, and 'res.hi' will contain the + * excessive years that must be considered when converting the years, + * while 'res.lo' will contain the days since start of the + * year. (Expect the resulting days to be negative, with a positive + * excess! But then, we need no leap year flag, either...) + */ +extern ntpcal_split +ntpcal_days_in_months(int32_t /* months */); + +/* + * Convert ELAPSED years/months/days of gregorian calendar to elapsed + * days in Gregorian epoch. No range checks done here! + */ +extern int32_t +ntpcal_edate_to_eradays(int32_t /* years */, int32_t /* months */, int32_t /* mdays */); + +/* + * Convert a time spec to seconds. No range checks done here! + */ +extern int32_t +ntpcal_etime_to_seconds(int32_t /* hours */, int32_t /* minutes */, int32_t /* seconds */); + +/* + * Convert ELAPSED years/months/days of gregorian calendar to elapsed + * days in year. + * + * Note: This will give the true difference to the start of the given year, + * even if months & days are off-scale. + */ +extern int32_t +ntpcal_edate_to_yeardays(int32_t /* years */, int32_t /* months */, int32_t /* mdays */); + +/* + * Convert the date part of a 'struct tm' (that is, year, month, + * day-of-month) into the RataDie of that day. + */ +extern int32_t +ntpcal_tm_to_rd(const struct tm * /* utm */); + +/* + * Convert the date part of a 'struct calendar' (that is, year, month, + * day-of-month) into the RataDie of that day. + */ +extern int32_t +ntpcal_date_to_rd(const struct calendar * /* jt */); + +/* + * Given the number of elapsed days in the calendar era, split this + * number into the number of elapsed years in 'res.quot' and the + * number of elapsed days of that year in 'res.rem'. + * + * if 'isleapyear' is not NULL, it will receive an integer that is 0 + * for regular years and a non-zero value for leap years. + * + * The input is limited to [-2^30, 2^30-1]. If the days exceed this + * range, errno is set to EDOM and the result is saturated. + */ +extern ntpcal_split +ntpcal_split_eradays(int32_t /* days */, int/*BOOL*/ * /* isleapyear */); + +/* + * Given a number of elapsed days in a year and a leap year indicator, + * split the number of elapsed days into the number of elapsed months + * in 'res.quot' and the number of elapsed days of that month in + * 'res.rem'. + */ +extern ntpcal_split +ntpcal_split_yeardays(int32_t /* eyd */, int/*BOOL*/ /* isleapyear */); + +/* + * Convert a RataDie number into the date part of a 'struct + * calendar'. Return 0 if the year is regular year, !0 if the year is + * a leap year. + */ +extern int/*BOOL*/ +ntpcal_rd_to_date(struct calendar * /* jt */, int32_t /* rd */); + +/* + * Convert a RataDie number into the date part of a 'struct + * tm'. Return 0 if the year is regular year, !0 if the year is a leap + * year. + */ +extern int/*BOOL*/ +ntpcal_rd_to_tm(struct tm * /* utm */, int32_t /* rd */); + +/* + * Take a value of seconds since midnight and split it into hhmmss in + * a 'struct calendar'. Return excessive days. + */ +extern int32_t +ntpcal_daysec_to_date(struct calendar * /* jt */, int32_t /* secs */); + +/* + * Take the time part of a 'struct calendar' and return the seconds + * since midnight. + */ +extern int32_t +ntpcal_date_to_daysec(const struct calendar *); + +/* + * Take a value of seconds since midnight and split it into hhmmss in + * a 'struct tm'. Return excessive days. + */ +extern int32_t +ntpcal_daysec_to_tm(struct tm * /* utm */, int32_t /* secs */); + +extern int32_t +ntpcal_tm_to_daysec(const struct tm * /* utm */); + +/* + * convert a year number to rata die of year start + */ +extern int32_t +ntpcal_year_to_ystart(int32_t /* year */); + +/* + * For a given RataDie, get the RataDie of the associated year start, + * that is, the RataDie of the last January,1st on or before that day. + */ +extern int32_t +ntpcal_rd_to_ystart(int32_t /* rd */); + +/* + * convert a RataDie to the RataDie of start of the calendar month. + */ +extern int32_t +ntpcal_rd_to_mstart(int32_t /* year */); + + +extern int +ntpcal_daysplit_to_date(struct calendar * /* jt */, + const ntpcal_split * /* ds */, int32_t /* dof */); + +extern int +ntpcal_daysplit_to_tm(struct tm * /* utm */, const ntpcal_split * /* ds */, + int32_t /* dof */); + +extern int +ntpcal_time_to_date(struct calendar * /* jd */, const vint64 * /* ts */); + +extern int32_t +ntpcal_periodic_extend(int32_t /* pivot */, int32_t /* value */, + int32_t /* cycle */); + +extern int +ntpcal_ntp64_to_date(struct calendar * /* jd */, const vint64 * /* ntp */); + +extern int +ntpcal_ntp_to_date(struct calendar * /* jd */, uint32_t /* ntp */, + const time_t * /* pivot */); + +extern vint64 +ntpcal_date_to_ntp64(const struct calendar * /* jd */); + +extern uint32_t +ntpcal_date_to_ntp(const struct calendar * /* jd */); + +extern time_t +ntpcal_date_to_time(const struct calendar * /* jd */); + +/* + * ISO week-calendar conversions + */ +extern int32_t +isocal_weeks_in_years(int32_t /* years */); + +/* + * The input is limited to [-2^30, 2^30-1]. If the weeks exceed this + * range, errno is set to EDOM and the result is saturated. + */ +extern ntpcal_split +isocal_split_eraweeks(int32_t /* weeks */); + +extern int +isocal_ntp64_to_date(struct isodate * /* id */, const vint64 * /* ntp */); + +extern int +isocal_ntp_to_date(struct isodate * /* id */, uint32_t /* ntp */, + const time_t * /* pivot */); + +extern vint64 +isocal_date_to_ntp64(const struct isodate * /* id */); + +extern uint32_t +isocal_date_to_ntp(const struct isodate * /* id */); + + +/* + * day-of-week calculations + * + * Given a RataDie and a day-of-week, calculate a RDN that is reater-than, + * greater-or equal, closest, less-or-equal or less-than the given RDN + * and denotes the given day-of-week + */ +extern int32_t +ntpcal_weekday_gt(int32_t /* rdn */, int32_t /* dow */); + +extern int32_t +ntpcal_weekday_ge(int32_t /* rdn */, int32_t /* dow */); + +extern int32_t +ntpcal_weekday_close(int32_t /* rdn */, int32_t /* dow */); + +extern int32_t +ntpcal_weekday_le(int32_t /* rdn */, int32_t /* dow */); + +extern int32_t +ntpcal_weekday_lt(int32_t /* rdn */, int32_t /* dow */); /* * Additional support stuff for Ed Rheingold's calendrical calculations @@ -87,26 +388,44 @@ extern u_long caltontp P((const struct calendar *)); /* * Start day of NTP time as days past the imaginary date 12/1/1 BC. - * P((This is the beginning of the Christian Era, or BCE.)) + * (This is the beginning of the Christian Era, or BCE.) + */ +#define DAY_NTP_STARTS 693596 + +/* + * Start day of the UNIX epoch. This is the Rata Die of 1970-01-01. */ -#define DAY_NTP_STARTS 693596 +#define DAY_UNIX_STARTS 719163 + +/* + * Difference between UN*X and NTP epoch (25567). + */ +#define NTP_TO_UNIX_DAYS (DAY_UNIX_STARTS - DAY_NTP_STARTS) + +/* + * Days in a normal 4 year leap year calendar cycle (1461). + */ +#define GREGORIAN_NORMAL_LEAP_CYCLE_DAYS (3 * 365 + 366) + /* - * The Gregorian calendar is based on a 400 year cycle. This is the number - * of days in each cycle. + * Days in a normal 100 year leap year calendar (36524). We lose a + * leap day in years evenly divisible by 100 but not by 400. */ -#define GREGORIAN_CYCLE_DAYS 146097 +#define GREGORIAN_NORMAL_CENTURY_DAYS \ + (25 * GREGORIAN_NORMAL_LEAP_CYCLE_DAYS - 1) /* - * Days in a normal 100 year leap year calendar. We lose a leap year day - * in years evenly divisible by 100 but not by 400. + * The Gregorian calendar is based on a 400 year cycle. This is the + * number of days in each cycle (146097). We gain a leap day in years + * divisible by 400 relative to the "normal" century. */ -#define GREGORIAN_NORMAL_CENTURY_DAYS 36524 +#define GREGORIAN_CYCLE_DAYS (4 * GREGORIAN_NORMAL_CENTURY_DAYS + 1) /* - * Days in a normal 4 year leap year calendar cycle. + * Number of weeks in 400 years (20871). */ -#define GREGORIAN_NORMAL_LEAP_CYCLE_DAYS 1461 +#define GREGORIAN_CYCLE_WEEKS (GREGORIAN_CYCLE_DAYS / 7) -#define is_leapyear(y) (y%4 == 0 && !(y%100 == 0 && !(y%400 == 0))) +#define is_leapyear(y) (!((y) % 4) && !(!((y) % 100) && (y) % 400)) #endif diff --git a/contrib/ntp/include/ntp_cmdargs.h b/contrib/ntp/include/ntp_cmdargs.h index e9ab9b1c2..de45d8d5e 100644 --- a/contrib/ntp/include/ntp_cmdargs.h +++ b/contrib/ntp/include/ntp_cmdargs.h @@ -1,4 +1 @@ -#include "ntp_types.h" - -extern void getstartup P((int, char **)); -extern void getCmdOpts P((int, char **)); +extern void getCmdOpts(int, char **); diff --git a/contrib/ntp/include/ntp_config.h b/contrib/ntp/include/ntp_config.h index 66d4f9f90..bd8f595d9 100644 --- a/contrib/ntp/include/ntp_config.h +++ b/contrib/ntp/include/ntp_config.h @@ -1,3 +1,14 @@ +#ifndef NTP_CONFIG_H +#define NTP_CONFIG_H + +#ifdef HAVE_SYS_RESOURCE_H +# include +#endif /* HAVE_SYS_RESOURCE_H */ + +#include "ntp_machine.h" +#include "ntpsim.h" + + /* * Configuration file name */ @@ -11,171 +22,302 @@ # endif /* SYS_WINNT */ #endif /* not CONFIG_FILE */ -/* - * Types of entries we understand. - */ -#define CONFIG_UNKNOWN 0 /* - * Command keywords + * We keep config trees around for possible saveconfig use. When + * built with configure --disable-saveconfig, and when built with + * debugging enabled, include the free_config_*() routines. In the + * DEBUG case, they are used in an atexit() cleanup routine to make + * postmortem leak check reports more interesting. */ -#define CONFIG_PEER 1 -#define CONFIG_SERVER 2 -#define CONFIG_AUTOMAX 3 -#define CONFIG_DRIFTFILE 4 -#define CONFIG_BROADCAST 5 -#define CONFIG_BROADCASTCLIENT 6 -#define CONFIG_AUTHENTICATE 7 -#define CONFIG_KEYS 8 -#define CONFIG_REVOKE 9 -#define CONFIG_CDELAY 10 -#define CONFIG_RESTRICT 11 -#define CONFIG_BDELAY 12 -#define CONFIG_TRUSTEDKEY 13 -#define CONFIG_REQUESTKEY 14 -#define CONFIG_CONTROLKEY 15 -#define CONFIG_TRAP 16 -#define CONFIG_FUDGE 17 -#define CONFIG_TINKER 18 -#define CONFIG_STATSDIR 19 -#define CONFIG_FILEGEN 20 -#define CONFIG_STATISTICS 21 -#define CONFIG_PIDFILE 22 -#define CONFIG_SETVAR 23 -#define CONFIG_DISCARD 24 -#define CONFIG_ADJ 25 -#define CONFIG_MULTICASTCLIENT 26 -#define CONFIG_ENABLE 27 -#define CONFIG_DISABLE 28 -#define CONFIG_PHONE 29 -#define CONFIG_LOGFILE 30 -#define CONFIG_LOGCONFIG 31 -#define CONFIG_MANYCASTCLIENT 32 -#define CONFIG_MANYCASTSERVER 33 -#define CONFIG_TOS 34 -#define CONFIG_TTL 35 -#define CONFIG_INCLUDEFILE 36 -#define CONFIG_KEYSDIR 37 -#define CONFIG_END 38 -#ifdef OPENSSL -#define CONFIG_CRYPTO 39 -#endif /* OPENSSL */ +#if !defined(FREE_CFG_T) && (!defined(SAVECONFIG) || defined(DEBUG)) +#define FREE_CFG_T +#endif -/* - * "peer", "server", "broadcast" modifier keywords - */ -#define CONF_MOD_VERSION 1 -#define CONF_MOD_KEY 2 -#define CONF_MOD_MINPOLL 3 -#define CONF_MOD_MAXPOLL 4 -#define CONF_MOD_PREFER 5 -#define CONF_MOD_BURST 6 -#define CONF_MOD_IBURST 7 -#define CONF_MOD_SKEY 8 -#define CONF_MOD_TTL 9 -#define CONF_MOD_MODE 10 -#define CONF_MOD_NOSELECT 11 -#define CONF_MOD_TRUE 12 -#define CONF_MOD_PREEMPT 13 -#define CONF_MOD_DYNAMIC 14 +/* Limits */ +#define MAXLINE 1024 -/* - * "restrict" modifier keywords - */ -#define CONF_RES_MASK 1 -#define CONF_RES_IGNORE 2 -#define CONF_RES_NOSERVE 3 -#define CONF_RES_NOTRUST 4 -#define CONF_RES_NOQUERY 5 -#define CONF_RES_NOMODIFY 6 -#define CONF_RES_NOPEER 7 -#define CONF_RES_NOTRAP 8 -#define CONF_RES_LPTRAP 9 -#define CONF_RES_NTPPORT 10 -#define CONF_RES_LIMITED 11 -#define CONF_RES_VERSION 12 -#define CONF_RES_DEMOBILIZE 13 +/* Configuration sources */ -/* - * "trap" modifier keywords - */ -#define CONF_TRAP_PORT 1 -#define CONF_TRAP_INTERFACE 2 +#define CONF_SOURCE_FILE 0 +#define CONF_SOURCE_NTPQ 1 -/* - * "fudge" modifier keywords - */ -#define CONF_FDG_TIME1 1 -#define CONF_FDG_TIME2 2 -#define CONF_FDG_STRATUM 3 -#define CONF_FDG_REFID 4 -#define CONF_FDG_FLAG1 5 -#define CONF_FDG_FLAG2 6 -#define CONF_FDG_FLAG3 7 -#define CONF_FDG_FLAG4 8 +/* list of servers from command line for config_peers() */ +extern int cmdline_server_count; +extern char ** cmdline_servers; -/* - * "filegen" modifier keywords - */ -#define CONF_FGEN_FILE 1 -#define CONF_FGEN_TYPE 2 -#define CONF_FGEN_FLAG_LINK 3 -#define CONF_FGEN_FLAG_NOLINK 4 -#define CONF_FGEN_FLAG_ENABLE 5 -#define CONF_FGEN_FLAG_DISABLE 6 +/* set to zero if we're not locking memory */ +extern int cur_memlock; -/* - * "discard" modifier keywords - */ -#define CONF_DISCARD_AVERAGE 1 -#define CONF_DISCARD_MINIMUM 2 -#define CONF_DISCARD_MONITOR 3 +typedef struct int_range_tag { + int first; + int last; +} int_range; -/* - * "tinker" modifier keywords - */ -#define CONF_CLOCK_MAX 1 -#define CONF_CLOCK_PANIC 2 -#define CONF_CLOCK_PHI 3 -#define CONF_CLOCK_MINSTEP 4 -#define CONF_CLOCK_ALLAN 5 -#define CONF_CLOCK_HUFFPUFF 6 -#define CONF_CLOCK_FREQ 7 +/* Structure for storing an attribute-value pair */ +typedef struct attr_val_tag attr_val; +struct attr_val_tag { + attr_val * link; + int attr; + int type; /* T_String, T_Integer, ... */ + union val { + int i; + u_int u; + int_range r; + double d; + char * s; + } value; +}; + +typedef DECL_FIFO_ANCHOR(attr_val) attr_val_fifo; + +/* Structure for nodes on the syntax tree */ +typedef struct address_node_tag address_node; +struct address_node_tag { + address_node * link; + char * address; + u_short type; /* family, AF_UNSPEC (0), AF_INET[6] */ +}; + +typedef DECL_FIFO_ANCHOR(address_node) address_fifo; + +typedef struct int_node_tag int_node; +struct int_node_tag { + int_node * link; + int i; +}; + +typedef DECL_FIFO_ANCHOR(int_node) int_fifo; + +typedef struct string_node_tag string_node; +struct string_node_tag { + string_node * link; + char * s; +}; + +typedef DECL_FIFO_ANCHOR(string_node) string_fifo; + +typedef struct restrict_node_tag restrict_node; +struct restrict_node_tag { + restrict_node * link; + address_node * addr; + address_node * mask; + int_fifo * flags; + int line_no; +}; + +typedef DECL_FIFO_ANCHOR(restrict_node) restrict_fifo; + +typedef struct peer_node_tag peer_node; +struct peer_node_tag { + peer_node * link; + int host_mode; + address_node * addr; + attr_val_fifo * peerflags; + u_char minpoll; + u_char maxpoll; + u_int32 ttl; + u_char peerversion; + keyid_t peerkey; + char * group; +}; + +typedef DECL_FIFO_ANCHOR(peer_node) peer_fifo; + +typedef struct unpeer_node_tag unpeer_node; +struct unpeer_node_tag { + unpeer_node * link; + associd_t assocID; + address_node * addr; +}; + +typedef DECL_FIFO_ANCHOR(unpeer_node) unpeer_fifo; + +typedef struct auth_node_tag auth_node; +struct auth_node_tag { + int control_key; + int cryptosw; + attr_val_fifo * crypto_cmd_list; + char * keys; + char * keysdir; + int request_key; + int revoke; + attr_val_fifo * trusted_key_list; + char * ntp_signd_socket; +}; + +typedef struct filegen_node_tag filegen_node; +struct filegen_node_tag { + filegen_node * link; + int filegen_token; + attr_val_fifo * options; +}; + +typedef DECL_FIFO_ANCHOR(filegen_node) filegen_fifo; + +typedef struct setvar_node_tag setvar_node; +struct setvar_node_tag { + setvar_node * link; + char * var; + char * val; + int isdefault; +}; + +typedef DECL_FIFO_ANCHOR(setvar_node) setvar_fifo; + +typedef struct nic_rule_node_tag nic_rule_node; +struct nic_rule_node_tag { + nic_rule_node * link; + int match_class; + char * if_name; /* or numeric address */ + int action; +}; + +typedef DECL_FIFO_ANCHOR(nic_rule_node) nic_rule_fifo; + +typedef struct addr_opts_node_tag addr_opts_node; +struct addr_opts_node_tag { + addr_opts_node *link; + address_node * addr; + attr_val_fifo * options; +}; + +typedef DECL_FIFO_ANCHOR(addr_opts_node) addr_opts_fifo; + +typedef struct sim_node_tag sim_node; +struct sim_node_tag { + sim_node * link; + attr_val_fifo * init_opts; + server_info_fifo * servers; +}; + +typedef DECL_FIFO_ANCHOR(sim_node) sim_fifo; + +/* The syntax tree */ +typedef struct config_tree_tag config_tree; +struct config_tree_tag { + config_tree * link; + + attr_val source; + time_t timestamp; + + peer_fifo * peers; + unpeer_fifo * unpeers; + + /* Other Modes */ + int broadcastclient; + address_fifo * manycastserver; + address_fifo * multicastclient; + + attr_val_fifo * orphan_cmds; /* s/b renamed tos_options */ + + /* Monitoring Configuration */ + int_fifo * stats_list; + char * stats_dir; + filegen_fifo * filegen_opts; + + /* Access Control Configuration */ + attr_val_fifo * discard_opts; + attr_val_fifo * mru_opts; + restrict_fifo * restrict_opts; + + addr_opts_fifo *fudge; + attr_val_fifo * rlimit; + attr_val_fifo * tinker; + attr_val_fifo * enable_opts; + attr_val_fifo * disable_opts; + + auth_node auth; + + attr_val_fifo * logconfig; + string_fifo * phone; + setvar_fifo * setvar; + int_fifo * ttl; + addr_opts_fifo *trap; + attr_val_fifo * vars; + nic_rule_fifo * nic_rules; + int_fifo * reset_counters; + + sim_fifo * sim_details; + int mdnstries; +}; + + +/* Structure for holding a remote configuration command */ +struct REMOTE_CONFIG_INFO { + char buffer[MAXLINE]; + char err_msg[MAXLINE]; + int pos; + int err_pos; + int no_errors; +}; -/* - * "tos" modifier keywords - */ -#define CONF_TOS_MINCLOCK 1 -#define CONF_TOS_MAXCLOCK 2 -#define CONF_TOS_MINSANE 3 -#define CONF_TOS_FLOOR 4 -#define CONF_TOS_CEILING 5 -#define CONF_TOS_COHORT 6 -#define CONF_TOS_MINDISP 7 -#define CONF_TOS_MAXDIST 8 -#define CONF_TOS_MAXHOP 9 -#define CONF_TOS_BEACON 10 -#define CONF_TOS_ORPHAN 11 - -#ifdef OPENSSL -/* - * "crypto" modifier keywords - */ -#define CONF_CRYPTO_RSA 1 -#define CONF_CRYPTO_SIGN 2 -#define CONF_CRYPTO_LEAP 3 -#define CONF_CRYPTO_CERT 4 -#define CONF_CRYPTO_RAND 5 -#define CONF_CRYPTO_KEYS 6 -#define CONF_CRYPTO_IDENT 7 -#define CONF_CRYPTO_IFFPAR 8 -#define CONF_CRYPTO_GQPAR 9 -#define CONF_CRYPTO_MVPAR 10 -#define CONF_CRYPTO_PW 11 -#endif /* OPENSSL */ /* - * Address selection, IPv4 or IPv6 + * context for trap_name_resolved() to call ctlsettrap() once the + * name->address resolution completes. */ -#define CONF_ADDR_IPV4 1 -#define CONF_ADDR_IPV6 2 +typedef struct settrap_parms_tag { + sockaddr_u ifaddr; + int ifaddr_nonnull; +} settrap_parms; + + +/* get text from T_ tokens */ +const char * token_name(int token); + +/* generic fifo routines for structs linked by 1st member */ +void* append_gen_fifo(void *fifo, void *entry); +void * concat_gen_fifos(void *first, void *second); +#define APPEND_G_FIFO(pf, pe) \ + ((pf) = append_gen_fifo((pf), (pe))) +#define CONCAT_G_FIFOS(first, second) \ + ((first) = concat_gen_fifos((first), (second))) +#define HEAD_PFIFO(pf) \ + (((pf) != NULL) \ + ? HEAD_FIFO(*(pf)) \ + : NULL) + +peer_node *create_peer_node(int hmode, address_node *addr, + attr_val_fifo *options); +unpeer_node *create_unpeer_node(address_node *addr); +address_node *create_address_node(char *addr, int type); +void destroy_address_node(address_node *my_node); +attr_val *create_attr_dval(int attr, double value); +attr_val *create_attr_ival(int attr, int value); +attr_val *create_attr_uval(int attr, u_int value); +attr_val *create_attr_rangeval(int attr, int first, int last); +attr_val *create_attr_sval(int attr, const char *s); +filegen_node *create_filegen_node(int filegen_token, + attr_val_fifo *options); +string_node *create_string_node(char *str); +restrict_node *create_restrict_node(address_node *addr, + address_node *mask, + int_fifo *flags, int line_no); +int_node *create_int_node(int val); +addr_opts_node *create_addr_opts_node(address_node *addr, + attr_val_fifo *options); +sim_node *create_sim_node(attr_val_fifo *init_opts, + server_info_fifo *servers); +setvar_node *create_setvar_node(char *var, char *val, int isdefault); +nic_rule_node *create_nic_rule_node(int match_class, char *if_name, + int action); + +script_info *create_sim_script_info(double duration, + attr_val_fifo *script_queue); +server_info *create_sim_server(address_node *addr, double server_offset, + script_info_fifo *script); + +extern struct REMOTE_CONFIG_INFO remote_config; +void config_remotely(sockaddr_u *); + +#ifdef SAVECONFIG +int dump_config_tree(config_tree *ptree, FILE *df, int comment); +int dump_all_config_trees(FILE *df, int comment); +#endif + +#if defined(HAVE_SETRLIMIT) +void ntp_rlimit(int, rlim_t, int, const char *); +#endif + +#endif /* !defined(NTP_CONFIG_H) */ diff --git a/contrib/ntp/include/ntp_control.h b/contrib/ntp/include/ntp_control.h index c29979453..85f41056c 100644 --- a/contrib/ntp/include/ntp_control.h +++ b/contrib/ntp/include/ntp_control.h @@ -4,6 +4,11 @@ #include "ntp_types.h" +typedef union ctl_pkt_u_tag { + u_char data[480 + MAX_MAC_LEN]; /* data + auth */ + u_int32 u32[(480 + MAX_MAC_LEN) / sizeof(u_int32)]; +} ctl_pkt_u; + struct ntp_control { u_char li_vn_mode; /* leap, version, mode */ u_char r_m_e_op; /* response, more, error, opcode */ @@ -12,13 +17,13 @@ struct ntp_control { associd_t associd; /* association ID */ u_short offset; /* offset of this batch of data */ u_short count; /* count of data in this packet */ - u_char data[(480 + MAX_MAC_LEN)]; /* data + auth */ + ctl_pkt_u u; }; /* * Length of the control header, in octets */ -#define CTL_HEADER_LEN 12 +#define CTL_HEADER_LEN (offsetof(struct ntp_control, u)) #define CTL_MAX_DATA_LEN 468 @@ -37,38 +42,42 @@ struct ntp_control { #define CTL_MORE 0x20 #define CTL_OP_MASK 0x1f -#define CTL_ISRESPONSE(r_m_e_op) (((r_m_e_op) & 0x80) != 0) -#define CTL_ISMORE(r_m_e_op) (((r_m_e_op) & 0x20) != 0) -#define CTL_ISERROR(r_m_e_op) (((r_m_e_op) & 0x40) != 0) -#define CTL_OP(r_m_e_op) ((r_m_e_op) & CTL_OP_MASK) +#define CTL_ISRESPONSE(r_m_e_op) ((CTL_RESPONSE & (r_m_e_op)) != 0) +#define CTL_ISMORE(r_m_e_op) ((CTL_MORE & (r_m_e_op)) != 0) +#define CTL_ISERROR(r_m_e_op) ((CTL_ERROR & (r_m_e_op)) != 0) +#define CTL_OP(r_m_e_op) (CTL_OP_MASK & (r_m_e_op)) /* * Opcodes */ -#define CTL_OP_UNSPEC 0 -#define CTL_OP_READSTAT 1 -#define CTL_OP_READVAR 2 -#define CTL_OP_WRITEVAR 3 -#define CTL_OP_READCLOCK 4 -#define CTL_OP_WRITECLOCK 5 -#define CTL_OP_SETTRAP 6 -#define CTL_OP_ASYNCMSG 7 -#define CTL_OP_UNSETTRAP 31 +#define CTL_OP_UNSPEC 0 /* unspeciffied */ +#define CTL_OP_READSTAT 1 /* read status */ +#define CTL_OP_READVAR 2 /* read variables */ +#define CTL_OP_WRITEVAR 3 /* write variables */ +#define CTL_OP_READCLOCK 4 /* read clock variables */ +#define CTL_OP_WRITECLOCK 5 /* write clock variables */ +#define CTL_OP_SETTRAP 6 /* set trap address */ +#define CTL_OP_ASYNCMSG 7 /* asynchronous message */ +#define CTL_OP_CONFIGURE 8 /* runtime configuration */ +#define CTL_OP_SAVECONFIG 9 /* save config to file */ +#define CTL_OP_READ_MRU 10 /* retrieve MRU (mrulist) */ +#define CTL_OP_READ_ORDLIST_A 11 /* ordered list req. auth. */ +#define CTL_OP_REQ_NONCE 12 /* request a client nonce */ +#define CTL_OP_UNSETTRAP 31 /* unset trap */ /* * {En,De}coding of the system status word */ -#define CTL_SST_TS_UNSPEC 0 /* time source unspecified */ -#define CTL_SST_TS_ATOM 1 /* time source calibrated atomic */ -#define CTL_SST_TS_LF 2 /* time source VLF or LF radio */ -#define CTL_SST_TS_HF 3 /* time source HF radio */ -#define CTL_SST_TS_UHF 4 /* time source UHF radio */ -#define CTL_SST_TS_LOCAL 5 /* time source LOCAL */ -#define CTL_SST_TS_NTP 6 /* time source NTP */ -#define CTL_SST_TS_UDPTIME 7 /* time source UDP/TIME */ -#define CTL_SST_TS_WRSTWTCH 8 /* time source is wristwatch */ -#define CTL_SST_TS_TELEPHONE 9 /* time source is telephone modem */ -#define CTL_SST_TS_PPS 0x20 /* time source is PPS signal */ +#define CTL_SST_TS_UNSPEC 0 /* unspec */ +#define CTL_SST_TS_ATOM 1 /* pps */ +#define CTL_SST_TS_LF 2 /* lf radio */ +#define CTL_SST_TS_HF 3 /* hf radio */ +#define CTL_SST_TS_UHF 4 /* uhf radio */ +#define CTL_SST_TS_LOCAL 5 /* local */ +#define CTL_SST_TS_NTP 6 /* ntp */ +#define CTL_SST_TS_UDPTIME 7 /* other */ +#define CTL_SST_TS_WRSTWTCH 8 /* wristwatch */ +#define CTL_SST_TS_TELEPHONE 9 /* telephone */ #define CTL_SYS_MAXEVENTS 15 @@ -90,14 +99,14 @@ struct ntp_control { #define CTL_PST_AUTHENABLE 0x40 #define CTL_PST_AUTHENTIC 0x20 #define CTL_PST_REACH 0x10 -#define CTL_PST_UNSPEC 0x08 +#define CTL_PST_BCAST 0x08 #define CTL_PST_SEL_REJECT 0 /* reject */ #define CTL_PST_SEL_SANE 1 /* x falsetick */ #define CTL_PST_SEL_CORRECT 2 /* . excess */ -#define CTL_PST_SEL_SELCAND 3 /* - outlyer */ -#define CTL_PST_SEL_SYNCCAND 4 /* + candidat */ -#define CTL_PST_SEL_DISTSYSPEER 5 /* # selected */ +#define CTL_PST_SEL_SELCAND 3 /* - outlier */ +#define CTL_PST_SEL_SYNCCAND 4 /* + candidate */ +#define CTL_PST_SEL_EXCESS 5 /* # backup */ #define CTL_PST_SEL_SYSPEER 6 /* * sys.peer */ #define CTL_PST_SEL_PPS 7 /* o pps.peer */ @@ -142,124 +151,12 @@ struct ntp_control { #define CERR_NORESOURCE CERR_PERMISSION /* wish there was a different code */ -/* - * System variables we understand - */ -#define CS_LEAP 1 -#define CS_STRATUM 2 -#define CS_PRECISION 3 -#define CS_ROOTDELAY 4 -#define CS_ROOTDISPERSION 5 -#define CS_REFID 6 -#define CS_REFTIME 7 -#define CS_POLL 8 -#define CS_PEERID 9 -#define CS_STATE 10 -#define CS_OFFSET 11 -#define CS_DRIFT 12 -#define CS_JITTER 13 -#define CS_ERROR 14 -#define CS_CLOCK 15 -#define CS_PROCESSOR 16 -#define CS_SYSTEM 17 -#define CS_VERSION 18 -#define CS_STABIL 19 -#define CS_VARLIST 20 -#ifdef OPENSSL -#define CS_FLAGS 21 -#define CS_HOST 22 -#define CS_PUBLIC 23 -#define CS_CERTIF 24 -#define CS_REVTIME 25 -#define CS_LEAPTAB 26 -#define CS_TAI 27 -#define CS_DIGEST 28 -#define CS_IDENT 29 -#define CS_REVOKE 30 -#define CS_MAXCODE CS_REVOKE -#else -#define CS_MAXCODE CS_VARLIST -#endif /* OPENSSL */ - -/* - * Peer variables we understand - */ -#define CP_CONFIG 1 -#define CP_AUTHENABLE 2 -#define CP_AUTHENTIC 3 -#define CP_SRCADR 4 -#define CP_SRCPORT 5 -#define CP_DSTADR 6 -#define CP_DSTPORT 7 -#define CP_LEAP 8 -#define CP_HMODE 9 -#define CP_STRATUM 10 -#define CP_PPOLL 11 -#define CP_HPOLL 12 -#define CP_PRECISION 13 -#define CP_ROOTDELAY 14 -#define CP_ROOTDISPERSION 15 -#define CP_REFID 16 -#define CP_REFTIME 17 -#define CP_ORG 18 -#define CP_REC 19 -#define CP_XMT 20 -#define CP_REACH 21 -#define CP_UNREACH 22 -#define CP_TIMER 23 -#define CP_DELAY 24 -#define CP_OFFSET 25 -#define CP_JITTER 26 -#define CP_DISPERSION 27 -#define CP_KEYID 28 -#define CP_FILTDELAY 29 -#define CP_FILTOFFSET 30 -#define CP_PMODE 31 -#define CP_RECEIVED 32 -#define CP_SENT 33 -#define CP_FILTERROR 34 -#define CP_FLASH 35 -#define CP_TTL 36 -#define CP_VARLIST 37 -#ifdef OPENSSL -#define CP_FLAGS 38 -#define CP_HOST 39 -#define CP_VALID 40 -#define CP_INITSEQ 41 -#define CP_INITKEY 42 -#define CP_INITTSP 43 -#define CP_DIGEST 44 -#define CP_IDENT 45 -#define CP_MAXCODE CP_IDENT -#else -#define CP_MAXCODE CP_VARLIST -#endif /* OPENSSL */ - -/* - * Clock variables we understand - */ -#define CC_TYPE 1 -#define CC_TIMECODE 2 -#define CC_POLL 3 -#define CC_NOREPLY 4 -#define CC_BADFORMAT 5 -#define CC_BADDATA 6 -#define CC_FUDGETIME1 7 -#define CC_FUDGETIME2 8 -#define CC_FUDGEVAL1 9 -#define CC_FUDGEVAL2 10 -#define CC_FLAGS 11 -#define CC_DEVICE 12 -#define CC_VARLIST 13 - -#define CC_MAXCODE CC_VARLIST - /* * Definition of the structure used internally to hold trap information. * ntp_request.c wants to see this. */ struct ctl_trap { - struct sockaddr_storage tr_addr;/* address of trap recipient */ + sockaddr_u tr_addr; /* address of trap recipient */ struct interface *tr_localaddr; /* interface to send this through */ u_long tr_settime; /* time trap was set */ u_long tr_count; /* async messages sent to this guy */ @@ -269,7 +166,7 @@ struct ctl_trap { u_char tr_flags; /* trap flags */ u_char tr_version; /* version number of trapper */ }; -extern struct ctl_trap ctl_trap[]; +extern struct ctl_trap ctl_traps[CTL_MAXTRAPS]; /* * Flag bits @@ -285,3 +182,11 @@ extern struct ctl_trap ctl_trap[]; #define TYPE_SYS 1 #define TYPE_PEER 2 #define TYPE_CLOCK 3 + +/* + * IFSTATS_FIELDS is the number of fields ntpd supplies for each ifstats + * row. Similarly RESLIST_FIELDS for reslist. + */ +#define IFSTATS_FIELDS 12 +#define RESLIST_FIELDS 4 + diff --git a/contrib/ntp/include/ntp_crypto.h b/contrib/ntp/include/ntp_crypto.h index 14795e72d..b80100614 100644 --- a/contrib/ntp/include/ntp_crypto.h +++ b/contrib/ntp/include/ntp_crypto.h @@ -1,8 +1,33 @@ /* * ntp_crypto.h - definitions for cryptographic operations */ -#ifdef OPENSSL +#ifndef NTP_CRYPTO_H +#define NTP_CRYPTO_H + +/* + * Configuration codes (also needed for parser without AUTOKEY) + */ +#define CRYPTO_CONF_NONE 0 /* nothing doing */ +#define CRYPTO_CONF_PRIV 1 /* host name */ +#define CRYPTO_CONF_IDENT 2 /* group name */ +#define CRYPTO_CONF_CERT 3 /* certificate file name */ +#define CRYPTO_CONF_RAND 4 /* random seed file name */ +#define CRYPTO_CONF_IFFPAR 5 /* IFF parameters file name */ +#define CRYPTO_CONF_GQPAR 6 /* GQ parameters file name */ +#define CRYPTO_CONF_MVPAR 7 /* MV parameters file name */ +#define CRYPTO_CONF_PW 8 /* private key password */ +#define CRYPTO_CONF_NID 9 /* specify digest name */ + +#ifdef AUTOKEY +#ifndef OPENSSL +#error AUTOKEY should be defined only if OPENSSL is. +invalidsyntax: AUTOKEY should be defined only if OPENSSL is. +#endif + #include "openssl/evp.h" +#include "ntp_calendar.h" /* for fields in the cert_info structure */ + + /* * The following bits are set by the CRYPTO_ASSOC message from * the server and are not modified by the client. @@ -20,13 +45,14 @@ * The following bits are used by the client during the protocol * exchange. */ -#define CRYPTO_FLAG_VALID 0x0100 /* public key verified */ +#define CRYPTO_FLAG_CERT 0x0100 /* public key verified */ #define CRYPTO_FLAG_VRFY 0x0200 /* identity verified */ #define CRYPTO_FLAG_PROV 0x0400 /* signature verified */ -#define CRYPTO_FLAG_AGREE 0x0800 /* cookie verifed */ +#define CRYPTO_FLAG_COOK 0x0800 /* cookie verifed */ #define CRYPTO_FLAG_AUTO 0x1000 /* autokey verified */ #define CRYPTO_FLAG_SIGN 0x2000 /* certificate signed */ -#define CRYPTO_FLAG_LEAP 0x4000 /* leapseconds table verified */ +#define CRYPTO_FLAG_LEAP 0x4000 /* leapsecond values verified */ +#define CRYPTO_FLAG_ALL 0x7f00 /* all mask */ /* * Flags used for certificate management @@ -48,7 +74,7 @@ #define CRYPTO_CERT CRYPTO_CMD(2) /* certificate */ #define CRYPTO_COOK CRYPTO_CMD(3) /* cookie value */ #define CRYPTO_AUTO CRYPTO_CMD(4) /* autokey values */ -#define CRYPTO_TAI CRYPTO_CMD(5) /* leapseconds table */ +#define CRYPTO_LEAP CRYPTO_CMD(5) /* leapsecond values */ #define CRYPTO_SIGN CRYPTO_CMD(6) /* certificate sign */ #define CRYPTO_IFF CRYPTO_CMD(7) /* IFF identity scheme */ #define CRYPTO_GQ CRYPTO_CMD(8) /* GQ identity scheme */ @@ -72,37 +98,20 @@ #define XEVNT_VFY XEVNT_CMD(9) /* certificate not verified */ #define XEVNT_PER XEVNT_CMD(10) /* host certificate expired */ #define XEVNT_CKY XEVNT_CMD(11) /* bad or missing cookie */ -#define XEVNT_DAT XEVNT_CMD(12) /* bad or missing leapseconds table */ +#define XEVNT_DAT XEVNT_CMD(12) /* bad or missing leapseconds */ #define XEVNT_CRT XEVNT_CMD(13) /* bad or missing certificate */ #define XEVNT_ID XEVNT_CMD(14) /* bad or missing group key */ #define XEVNT_ERR XEVNT_CMD(15) /* protocol error */ -#define XEVNT_SRV XEVNT_CMD(16) /* server certificate expired */ - -/* - * Configuration codes - */ -#define CRYPTO_CONF_NONE 0 /* nothing doing */ -#define CRYPTO_CONF_PRIV 1 /* host keys file name */ -#define CRYPTO_CONF_SIGN 2 /* signature keys file name */ -#define CRYPTO_CONF_LEAP 3 /* leapseconds table file name */ -#define CRYPTO_CONF_KEYS 4 /* keys directory path */ -#define CRYPTO_CONF_CERT 5 /* certificate file name */ -#define CRYPTO_CONF_RAND 6 /* random seed file name */ -#define CRYPTO_CONF_TRST 7 /* specify trust */ -#define CRYPTO_CONF_IFFPAR 8 /* IFF parameters file name */ -#define CRYPTO_CONF_GQPAR 9 /* GQ parameters file name */ -#define CRYPTO_CONF_MVPAR 10 /* GQ parameters file name */ -#define CRYPTO_CONF_PW 11 /* private key password */ -#define CRYPTO_CONF_IDENT 12 /* specify identity scheme */ /* * Miscellaneous crypto stuff */ #define NTP_MAXSESSION 100 /* maximum session key list entries */ -#define NTP_AUTOMAX 13 /* log2 default max session key life */ -#define KEY_REVOKE 16 /* log2 default key revoke timeout */ -#define NTP_MAXEXTEN 1024 /* maximum extension field size */ -#define TAI_1972 10 /* initial TAI offset (s) */ +#define NTP_MAXEXTEN 2048 /* maximum extension field size */ +#define NTP_AUTOMAX 12 /* default key list timeout (log2 s) */ +#define KEY_REVOKE 17 /* default key revoke timeout (log2 s) */ +#define NTP_REFRESH 19 /* default restart timeout (log2 s) */ +#define NTP_MAXKEY 65535 /* maximum symmetric key ID */ /* * The autokey structure holds the values used to authenticate key IDs. @@ -121,7 +130,7 @@ struct value { /* network byte order */ tstamp_t tstamp; /* timestamp */ tstamp_t fstamp; /* filestamp */ u_int32 vallen; /* value length */ - u_char *ptr; /* data pointer (various) */ + void *ptr; /* data pointer (various) */ u_int32 siglen; /* signature length */ u_char *sig; /* signature */ }; @@ -139,6 +148,7 @@ struct exten { u_int32 pkt[1]; /* start of value field */ }; + /* * The certificate info/value structure */ @@ -150,21 +160,31 @@ struct cert_info { int nid; /* signature/digest ID */ const EVP_MD *digest; /* message digest algorithm */ u_long serial; /* serial number */ - tstamp_t first; /* not valid before */ - tstamp_t last; /* not valid after */ + struct calendar first; /* not valid before */ + struct calendar last; /* not valid after */ char *subject; /* subject common name */ char *issuer; /* issuer common name */ - u_char *grpkey; /* GQ group key */ - u_int grplen; /* GQ group key length */ + BIGNUM *grpkey; /* GQ group key */ struct value cert; /* certificate/value */ }; +/* + * The keys info/value structure + */ +struct pkey_info { + struct pkey_info *link; /* forward link */ + EVP_PKEY *pkey; /* generic key */ + char *name; /* file name */ + tstamp_t fstamp; /* filestamp */ +}; + /* * Cryptographic values */ -extern char *keysdir; /* crypto keys directory */ extern u_int crypto_flags; /* status word */ +extern int crypto_nid; /* digest nid */ extern struct value hostval; /* host name/value */ extern struct cert_info *cinfo; /* host certificate information */ extern struct value tai_leap; /* leapseconds table */ -#endif /* OPENSSL */ +#endif /* AUTOKEY */ +#endif /* NTP_CRYPTO_H */ diff --git a/contrib/ntp/include/ntp_debug.h b/contrib/ntp/include/ntp_debug.h index 55b2e1a76..b0e846e0b 100644 --- a/contrib/ntp/include/ntp_debug.h +++ b/contrib/ntp/include/ntp_debug.h @@ -9,20 +9,19 @@ #define NTP_DEBUG_H /* - * macros for debugging output - cut down on #ifdef pollution in the code + * macro for debugging output - cut down on #ifdef pollution. + * + * TRACE() is similar to ntpd's DPRINTF() for utilities and libntp. + * Uses mprintf() and so supports %m, replaced by strerror(errno). + * + * The calling convention is not attractive: + * TRACE(debuglevel, (fmt, ...)); + * TRACE(2, ("this will appear on stdout if debug >= %d\n", 2)); */ - -#ifdef DEBUG -#define DPRINTF(_lvl_, _arg_) \ +#define TRACE(lvl, arg) \ do { \ - if (debug >= (_lvl_)) \ - printf _arg_; \ + if (debug >= (lvl)) \ + mprintf arg; \ } while (0) -#else -#define DPRINTF(_lvl_, _arg_) do {} while (0) -#endif -#endif -/* - * $Log$ - */ +#endif /* NTP_DEBUG_H */ diff --git a/contrib/ntp/include/ntp_filegen.h b/contrib/ntp/include/ntp_filegen.h index 836ec04ec..549bedbc8 100644 --- a/contrib/ntp/include/ntp_filegen.h +++ b/contrib/ntp/include/ntp_filegen.h @@ -5,7 +5,7 @@ * * * Copyright (C) 1992, 1996 by Rainer Pruy - * Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * This code may be modified and used freely * provided the credits remain intact. @@ -23,7 +23,7 @@ #define FILEGEN_WEEK 3 /* one filegen per week */ #define FILEGEN_MONTH 4 /* one filegen per month */ #define FILEGEN_YEAR 5 /* one filegen per year */ -#define FILEGEN_AGE 6 /* change filegen each FG_AGE_SECS */ +#define FILEGEN_AGE 6 /* change filegen each FG_AGE_SECS */ /* * supported file generation flags @@ -31,21 +31,26 @@ #define FGEN_FLAG_LINK 0x01 /* make a link to base name */ -#define FGEN_FLAG_ENABLED 0x80 /* set this to really create files */ +#define FGEN_FLAG_ENABLED 0x80 /* set this to really create files */ /* without this, open is suppressed */ -typedef struct FILEGEN - { - FILE *fp; /* file referring to current generation */ - char *prefix; /* filename prefix and basename to be used*/ - char *basename; /* for constructing filename of generation file */ - /* WARNING: must be malloced !!! will be fed to free()*/ - u_long id; /* id of current generation */ - u_char type; /* type of file generation */ - u_char flag; /* flags modifying processing of file generation */ - } FILEGEN; - -extern void filegen_setup P((FILEGEN *, u_long)); -extern void filegen_config P((FILEGEN *, char *, u_int, u_int)); -extern FILEGEN *filegen_get P((char *)); -extern void filegen_register P((char *, const char *, FILEGEN *)); +typedef struct filegen_tag { + FILE * fp; /* file referring to current generation */ + char * dir; /* currently always statsdir */ + char * fname; /* filename prefix of generation file */ + /* must be malloced, will be fed to free() */ + u_long id_lo; /* lower bound of ident value */ + u_long id_hi; /* upper bound of ident value */ + u_char type; /* type of file generation */ + u_char flag; /* flags modifying processing of file generation */ +} FILEGEN; + +extern void filegen_setup (FILEGEN *, u_int32); +extern void filegen_config (FILEGEN *, const char *, const char *, + u_int, u_int); +extern void filegen_statsdir(void); +extern FILEGEN *filegen_get (const char *); +extern void filegen_register (const char *, const char *, FILEGEN *); +#ifdef DEBUG +extern void filegen_unregister(const char *); +#endif diff --git a/contrib/ntp/include/ntp_fp.h b/contrib/ntp/include/ntp_fp.h index 307ab102d..780693226 100644 --- a/contrib/ntp/include/ntp_fp.h +++ b/contrib/ntp/include/ntp_fp.h @@ -5,12 +5,6 @@ #ifndef NTP_FP_H #define NTP_FP_H -#include -#include -#include - -#include "ntp_rfc2553.h" - #include "ntp_types.h" /* @@ -38,16 +32,11 @@ typedef struct { u_int32 Xl_ui; int32 Xl_i; } Ul_i; - union { - u_int32 Xl_uf; - int32 Xl_f; - } Ul_f; + u_int32 l_uf; } l_fp; #define l_ui Ul_i.Xl_ui /* unsigned integral part */ #define l_i Ul_i.Xl_i /* signed integral part */ -#define l_uf Ul_f.Xl_uf /* unsigned fractional part */ -#define l_f Ul_f.Xl_f /* signed fractional part */ /* * Fractional precision (of an l_fp) is actually the number of @@ -76,7 +65,7 @@ typedef int32 s_fp; typedef u_int32 u_fp; /* - * A unit second in fp format. Actually 2**(half_the_bits_in_a_long) + * A unit second in fp format. Actually 2**(half_the_bits_in_a_long) */ #define FP_SECOND (0x10000) @@ -84,25 +73,32 @@ typedef u_int32 u_fp; * Byte order conversions */ #define HTONS_FP(x) (htonl(x)) -#define HTONL_FP(h, n) do { (n)->l_ui = htonl((h)->l_ui); \ - (n)->l_uf = htonl((h)->l_uf); } while (0) #define NTOHS_FP(x) (ntohl(x)) -#define NTOHL_FP(n, h) do { (h)->l_ui = ntohl((n)->l_ui); \ - (h)->l_uf = ntohl((n)->l_uf); } while (0) -#define NTOHL_MFP(ni, nf, hi, hf) \ - do { (hi) = ntohl(ni); (hf) = ntohl(nf); } while (0) -#define HTONL_MFP(hi, hf, ni, nf) \ - do { (ni) = ntohl(hi); (nf) = ntohl(hf); } while (0) - -/* funny ones. Converts ts fractions to net order ts */ -#define HTONL_UF(uf, nts) \ - do { (nts)->l_ui = 0; (nts)->l_uf = htonl(uf); } while (0) -#define HTONL_F(f, nts) do { (nts)->l_uf = htonl(f); \ - if ((f) & 0x80000000) \ - (nts)->l_i = -1; \ - else \ - (nts)->l_i = 0; \ - } while (0) + +#define NTOHL_MFP(ni, nf, hi, hf) \ + do { \ + (hi) = ntohl(ni); \ + (hf) = ntohl(nf); \ + } while (FALSE) + +#define HTONL_MFP(hi, hf, ni, nf) \ + do { \ + (ni) = htonl(hi); \ + (nf) = htonl(hf); \ + } while (FALSE) + +#define HTONL_FP(h, n) \ + HTONL_MFP((h)->l_ui, (h)->l_uf, (n)->l_ui, (n)->l_uf) + +#define NTOHL_FP(n, h) \ + NTOHL_MFP((n)->l_ui, (n)->l_uf, (h)->l_ui, (h)->l_uf) + +/* Convert unsigned ts fraction to net order ts */ +#define HTONL_UF(uf, nts) \ + do { \ + (nts)->l_ui = 0; \ + (nts)->l_uf = htonl(uf); \ + } while (FALSE) /* * Conversions between the two fixed point types @@ -110,13 +106,13 @@ typedef u_int32 u_fp; #define MFPTOFP(x_i, x_f) (((x_i) >= 0x00010000) ? 0x7fffffff : \ (((x_i) <= -0x00010000) ? 0x80000000 : \ (((x_i)<<16) | (((x_f)>>16)&0xffff)))) -#define LFPTOFP(v) MFPTOFP((v)->l_i, (v)->l_f) +#define LFPTOFP(v) MFPTOFP((v)->l_i, (v)->l_uf) #define UFPTOLFP(x, v) ((v)->l_ui = (u_fp)(x)>>16, (v)->l_uf = (x)<<16) #define FPTOLFP(x, v) (UFPTOLFP((x), (v)), (x) < 0 ? (v)->l_ui -= 0x10000 : 0) -#define MAXLFP(v) ((v)->l_ui = 0x7fffffff, (v)->l_uf = 0xffffffff) -#define MINLFP(v) ((v)->l_ui = 0x80000000, (v)->l_uf = 0) +#define MAXLFP(v) ((v)->l_ui = 0x7fffffffu, (v)->l_uf = 0xffffffffu) +#define MINLFP(v) ((v)->l_ui = 0x80000000u, (v)->l_uf = 0u) /* * Primitive operations on long fixed point values. If these are @@ -124,127 +120,72 @@ typedef u_int32 u_fp; * be replaced by inline assembler for particular machines someday. * These are the (kind of inefficient) run-anywhere versions. */ -#define M_NEG(v_i, v_f) /* v = -v */ \ +#define M_NEG(v_i, v_f) /* v = -v */ \ do { \ - if ((v_f) == 0) \ - (v_i) = -((s_fp)(v_i)); \ - else { \ - (v_f) = -((s_fp)(v_f)); \ - (v_i) = ~(v_i); \ - } \ - } while(0) + (v_f) = ~(v_f) + 1u; \ + (v_i) = ~(v_i) + ((v_f) == 0); \ + } while (FALSE) -#define M_NEGM(r_i, r_f, a_i, a_f) /* r = -a */ \ +#define M_NEGM(r_i, r_f, a_i, a_f) /* r = -a */ \ do { \ - if ((a_f) == 0) { \ - (r_f) = 0; \ - (r_i) = -(a_i); \ - } else { \ - (r_f) = -(a_f); \ - (r_i) = ~(a_i); \ - } \ - } while(0) + (r_f) = ~(a_f) + 1u; \ + (r_i) = ~(a_i) + ((r_f) == 0); \ + } while (FALSE) -#define M_ADD(r_i, r_f, a_i, a_f) /* r += a */ \ +#define M_ADD(r_i, r_f, a_i, a_f) /* r += a */ \ do { \ - register u_int32 lo_tmp; \ - register u_int32 hi_tmp; \ - \ - lo_tmp = ((r_f) & 0xffff) + ((a_f) & 0xffff); \ - hi_tmp = (((r_f) >> 16) & 0xffff) + (((a_f) >> 16) & 0xffff); \ - if (lo_tmp & 0x10000) \ - hi_tmp++; \ - (r_f) = ((hi_tmp & 0xffff) << 16) | (lo_tmp & 0xffff); \ - \ - (r_i) += (a_i); \ - if (hi_tmp & 0x10000) \ - (r_i)++; \ - } while (0) + u_int32 add_t = (r_f); \ + (r_f) += (a_f); \ + (r_i) += (a_i) + ((u_int32)(r_f) < add_t); \ + } while (FALSE) -#define M_ADD3(r_ovr, r_i, r_f, a_ovr, a_i, a_f) /* r += a, three word */ \ +#define M_ADD3(r_o, r_i, r_f, a_o, a_i, a_f) /* r += a, three word */ \ do { \ - register u_int32 lo_tmp; \ - register u_int32 hi_tmp; \ - \ - lo_tmp = ((r_f) & 0xffff) + ((a_f) & 0xffff); \ - hi_tmp = (((r_f) >> 16) & 0xffff) + (((a_f) >> 16) & 0xffff); \ - if (lo_tmp & 0x10000) \ - hi_tmp++; \ - (r_f) = ((hi_tmp & 0xffff) << 16) | (lo_tmp & 0xffff); \ - \ - lo_tmp = ((r_i) & 0xffff) + ((a_i) & 0xffff); \ - if (hi_tmp & 0x10000) \ - lo_tmp++; \ - hi_tmp = (((r_i) >> 16) & 0xffff) + (((a_i) >> 16) & 0xffff); \ - if (lo_tmp & 0x10000) \ - hi_tmp++; \ - (r_i) = ((hi_tmp & 0xffff) << 16) | (lo_tmp & 0xffff); \ - \ - (r_ovr) += (a_ovr); \ - if (hi_tmp & 0x10000) \ - (r_ovr)++; \ - } while (0) + u_int32 add_t, add_c; \ + add_t = (r_f); \ + (r_f) += (a_f); \ + add_c = ((u_int32)(r_f) < add_t); \ + (r_i) += add_c; \ + add_c = ((u_int32)(r_i) < add_c); \ + add_t = (r_i); \ + (r_i) += (a_i); \ + add_c |= ((u_int32)(r_i) < add_t); \ + (r_o) += (a_o) + add_c; \ + } while (FALSE) #define M_SUB(r_i, r_f, a_i, a_f) /* r -= a */ \ do { \ - register u_int32 lo_tmp; \ - register u_int32 hi_tmp; \ - \ - if ((a_f) == 0) { \ - (r_i) -= (a_i); \ - } else { \ - lo_tmp = ((r_f) & 0xffff) + ((-((s_fp)(a_f))) & 0xffff); \ - hi_tmp = (((r_f) >> 16) & 0xffff) \ - + (((-((s_fp)(a_f))) >> 16) & 0xffff); \ - if (lo_tmp & 0x10000) \ - hi_tmp++; \ - (r_f) = ((hi_tmp & 0xffff) << 16) | (lo_tmp & 0xffff); \ - \ - (r_i) += ~(a_i); \ - if (hi_tmp & 0x10000) \ - (r_i)++; \ - } \ - } while (0) + u_int32 sub_t = (r_f); \ + (r_f) -= (a_f); \ + (r_i) -= (a_i) + ((u_int32)(r_f) > sub_t); \ + } while (FALSE) #define M_RSHIFTU(v_i, v_f) /* v >>= 1, v is unsigned */ \ do { \ - (v_f) = (u_int32)(v_f) >> 1; \ - if ((v_i) & 01) \ - (v_f) |= 0x80000000; \ - (v_i) = (u_int32)(v_i) >> 1; \ - } while (0) + (v_f) = ((u_int32)(v_f) >> 1) | ((u_int32)(v_i) << 31); \ + (v_i) = ((u_int32)(v_i) >> 1); \ + } while (FALSE) #define M_RSHIFT(v_i, v_f) /* v >>= 1, v is signed */ \ do { \ - (v_f) = (u_int32)(v_f) >> 1; \ - if ((v_i) & 01) \ - (v_f) |= 0x80000000; \ - if ((v_i) & 0x80000000) \ - (v_i) = ((v_i) >> 1) | 0x80000000; \ - else \ - (v_i) = (v_i) >> 1; \ - } while (0) + (v_f) = ((u_int32)(v_f) >> 1) | ((u_int32)(v_i) << 31); \ + (v_i) = ((u_int32)(v_i) >> 1) | ((u_int32)(v_i) & 0x80000000); \ + } while (FALSE) #define M_LSHIFT(v_i, v_f) /* v <<= 1 */ \ do { \ - (v_i) <<= 1; \ - if ((v_f) & 0x80000000) \ - (v_i) |= 0x1; \ - (v_f) <<= 1; \ - } while (0) + (v_i) = ((u_int32)(v_i) << 1) | ((u_int32)(v_f) >> 31); \ + (v_f) = ((u_int32)(v_f) << 1); \ + } while (FALSE) -#define M_LSHIFT3(v_ovr, v_i, v_f) /* v <<= 1, with overflow */ \ +#define M_LSHIFT3(v_o, v_i, v_f) /* v <<= 1, with overflow */ \ do { \ - (v_ovr) <<= 1; \ - if ((v_i) & 0x80000000) \ - (v_ovr) |= 0x1; \ - (v_i) <<= 1; \ - if ((v_f) & 0x80000000) \ - (v_i) |= 0x1; \ - (v_f) <<= 1; \ - } while (0) + (v_o) = ((u_int32)(v_o) << 1) | ((u_int32)(v_i) >> 31); \ + (v_i) = ((u_int32)(v_i) << 1) | ((u_int32)(v_f) >> 31); \ + (v_f) = ((u_int32)(v_f) << 1); \ + } while (FALSE) -#define M_ADDUF(r_i, r_f, uf) /* r += uf, uf is u_int32 fraction */ \ +#define M_ADDUF(r_i, r_f, uf) /* r += uf, uf is u_int32 fraction */ \ M_ADD((r_i), (r_f), 0, (uf)) /* let optimizer worry about it */ #define M_SUBUF(r_i, r_f, uf) /* r -= uf, uf is u_int32 fraction */ \ @@ -252,25 +193,34 @@ typedef u_int32 u_fp; #define M_ADDF(r_i, r_f, f) /* r += f, f is a int32 fraction */ \ do { \ - if ((f) > 0) \ - M_ADD((r_i), (r_f), 0, (f)); \ - else if ((f) < 0) \ - M_ADD((r_i), (r_f), (-1), (f));\ + int32 add_f = (int32)(f); \ + if (add_f >= 0) \ + M_ADD((r_i), (r_f), 0, (uint32)( add_f)); \ + else \ + M_SUB((r_i), (r_f), 0, (uint32)(-add_f)); \ } while(0) -#define M_ISNEG(v_i, v_f) /* v < 0 */ \ +#define M_ISNEG(v_i) /* v < 0 */ \ (((v_i) & 0x80000000) != 0) +#define M_ISGT(a_i, a_f, b_i, b_f) /* a > b signed */ \ + (((u_int32)((a_i) ^ 0x80000000) > (u_int32)((b_i) ^ 0x80000000)) || \ + ((a_i) == (b_i) && ((u_int32)(a_f)) > ((u_int32)(b_f)))) + +#define M_ISGTU(a_i, a_f, b_i, b_f) /* a > b unsigned */ \ + (((u_int32)(a_i)) > ((u_int32)(b_i)) || \ + ((a_i) == (b_i) && ((u_int32)(a_f)) > ((u_int32)(b_f)))) + #define M_ISHIS(a_i, a_f, b_i, b_f) /* a >= b unsigned */ \ (((u_int32)(a_i)) > ((u_int32)(b_i)) || \ ((a_i) == (b_i) && ((u_int32)(a_f)) >= ((u_int32)(b_f)))) #define M_ISGEQ(a_i, a_f, b_i, b_f) /* a >= b signed */ \ - (((int32)(a_i)) > ((int32)(b_i)) || \ - ((a_i) == (b_i) && ((u_int32)(a_f)) >= ((u_int32)(b_f)))) + (((u_int32)((a_i) ^ 0x80000000) > (u_int32)((b_i) ^ 0x80000000)) || \ + ((a_i) == (b_i) && (u_int32)(a_f) >= (u_int32)(b_f))) #define M_ISEQU(a_i, a_f, b_i, b_f) /* a == b unsigned */ \ - ((a_i) == (b_i) && (a_f) == (b_f)) + ((u_int32)(a_i) == (u_int32)(b_i) && (u_int32)(a_f) == (u_int32)(b_f)) /* * Operations on the long fp format @@ -286,18 +236,18 @@ typedef u_int32 u_fp; #define L_LSHIFT(v) M_LSHIFT((v)->l_ui, (v)->l_uf) #define L_CLR(v) ((v)->l_ui = (v)->l_uf = 0) -#define L_ISNEG(v) (((v)->l_ui & 0x80000000) != 0) -#define L_ISZERO(v) ((v)->l_ui == 0 && (v)->l_uf == 0) -#define L_ISHIS(a, b) ((a)->l_ui > (b)->l_ui || \ - ((a)->l_ui == (b)->l_ui && (a)->l_uf >= (b)->l_uf)) -#define L_ISGEQ(a, b) ((a)->l_i > (b)->l_i || \ - ((a)->l_i == (b)->l_i && (a)->l_uf >= (b)->l_uf)) +#define L_ISNEG(v) M_ISNEG((v)->l_ui) +#define L_ISZERO(v) (((v)->l_ui | (v)->l_uf) == 0) +#define L_ISGT(a, b) M_ISGT((a)->l_i, (a)->l_uf, (b)->l_i, (b)->l_uf) +#define L_ISGTU(a, b) M_ISGTU((a)->l_ui, (a)->l_uf, (b)->l_ui, (b)->l_uf) +#define L_ISHIS(a, b) M_ISHIS((a)->l_ui, (a)->l_uf, (b)->l_ui, (b)->l_uf) +#define L_ISGEQ(a, b) M_ISGEQ((a)->l_ui, (a)->l_uf, (b)->l_ui, (b)->l_uf) #define L_ISEQU(a, b) M_ISEQU((a)->l_ui, (a)->l_uf, (b)->l_ui, (b)->l_uf) /* * s_fp/double and u_fp/double conversions */ -#define FRIC 65536. /* 2^16 as a double */ +#define FRIC 65536.0 /* 2^16 as a double */ #define DTOFP(r) ((s_fp)((r) * FRIC)) #define DTOUFP(r) ((u_fp)((r) * FRIC)) #define FPTOD(r) ((double)(r) / FRIC) @@ -305,75 +255,169 @@ typedef u_int32 u_fp; /* * l_fp/double conversions */ -#define FRAC 4294967296. /* 2^32 as a double */ -#define M_DTOLFP(d, r_i, r_uf) /* double to l_fp */ \ +#define FRAC 4294967296.0 /* 2^32 as a double */ + +/* + * Use 64 bit integers if available. Solaris on SPARC has a problem + * compiling parsesolaris.c if ntp_fp.h includes math.h, due to + * archaic gets() and printf() prototypes used in Solaris kernel + * headers. So far the problem has only been seen with gcc, but it + * may also affect Sun compilers, in which case the defined(__GNUC__) + * term should be removed. + * XSCALE also generates bad code for these, at least with GCC 3.3.5. + * This is unrelated to math.h, but the same solution applies. + */ +#if defined(HAVE_U_INT64) && \ + !(defined(__SVR4) && defined(__sun) && \ + defined(sparc) && defined(__GNUC__) || \ + defined(__arm__) && defined(__XSCALE__) && defined(__GNUC__)) + +#include /* ldexp() */ + +#define M_DTOLFP(d, r_ui, r_uf) /* double to l_fp */ \ + do { \ + double d_tmp; \ + u_int64 q_tmp; \ + int M_isneg; \ + \ + d_tmp = (d); \ + M_isneg = (d_tmp < 0.); \ + if (M_isneg) { \ + d_tmp = -d_tmp; \ + } \ + q_tmp = (u_int64)ldexp(d_tmp, 32); \ + if (M_isneg) { \ + q_tmp = ~q_tmp + 1; \ + } \ + (r_uf) = (u_int32)q_tmp; \ + (r_ui) = (u_int32)(q_tmp >> 32); \ + } while (FALSE) + +#define M_LFPTOD(r_ui, r_uf, d) /* l_fp to double */ \ + do { \ + double d_tmp; \ + u_int64 q_tmp; \ + int M_isneg; \ + \ + q_tmp = ((u_int64)(r_ui) << 32) + (r_uf); \ + M_isneg = M_ISNEG(r_ui); \ + if (M_isneg) { \ + q_tmp = ~q_tmp + 1; \ + } \ + d_tmp = ldexp((double)q_tmp, -32); \ + if (M_isneg) { \ + d_tmp = -d_tmp; \ + } \ + (d) = d_tmp; \ + } while (FALSE) + +#else /* use only 32 bit unsigned values */ + +#define M_DTOLFP(d, r_ui, r_uf) /* double to l_fp */ \ do { \ - register double d_tmp; \ - \ - d_tmp = (d); \ - if (d_tmp < 0) { \ - d_tmp = -d_tmp; \ - (r_i) = (int32)(d_tmp); \ - (r_uf) = (u_int32)(((d_tmp) - (double)(r_i)) * FRAC); \ - M_NEG((r_i), (r_uf)); \ + double d_tmp; \ + if ((d_tmp = (d)) < 0) { \ + (r_ui) = (u_int32)(-d_tmp); \ + (r_uf) = (u_int32)(-(d_tmp + (double)(r_ui)) * FRAC); \ + M_NEG((r_ui), (r_uf)); \ } else { \ - (r_i) = (int32)(d_tmp); \ - (r_uf) = (u_int32)(((d_tmp) - (double)(r_i)) * FRAC); \ + (r_ui) = (u_int32)d_tmp; \ + (r_uf) = (u_int32)((d_tmp - (double)(r_ui)) * FRAC); \ } \ } while (0) -#define M_LFPTOD(r_i, r_uf, d) /* l_fp to double */ \ +#define M_LFPTOD(r_ui, r_uf, d) /* l_fp to double */ \ do { \ - register l_fp l_tmp; \ - \ - l_tmp.l_i = (r_i); \ - l_tmp.l_f = (r_uf); \ - if (l_tmp.l_i < 0) { \ - M_NEG(l_tmp.l_i, l_tmp.l_uf); \ - (d) = -((double)l_tmp.l_i + ((double)l_tmp.l_uf) / FRAC); \ + u_int32 l_thi, l_tlo; \ + l_thi = (r_ui); l_tlo = (r_uf); \ + if (M_ISNEG(l_thi)) { \ + M_NEG(l_thi, l_tlo); \ + (d) = -((double)l_thi + (double)l_tlo / FRAC); \ } else { \ - (d) = (double)l_tmp.l_i + ((double)l_tmp.l_uf) / FRAC; \ + (d) = (double)l_thi + (double)l_tlo / FRAC; \ } \ } while (0) +#endif + #define DTOLFP(d, v) M_DTOLFP((d), (v)->l_ui, (v)->l_uf) #define LFPTOD(v, d) M_LFPTOD((v)->l_ui, (v)->l_uf, (d)) /* * Prototypes */ -extern char * dofptoa P((u_fp, int, short, int)); -extern char * dolfptoa P((u_long, u_long, int, short, int)); - -extern int atolfp P((const char *, l_fp *)); -extern int buftvtots P((const char *, l_fp *)); -extern char * fptoa P((s_fp, short)); -extern char * fptoms P((s_fp, short)); -extern int hextolfp P((const char *, l_fp *)); -extern void gpstolfp P((int, int, unsigned long, l_fp *)); -extern int mstolfp P((const char *, l_fp *)); -extern char * prettydate P((l_fp *)); -extern char * gmprettydate P((l_fp *)); -extern char * uglydate P((l_fp *)); -extern void mfp_mul P((int32 *, u_int32 *, int32, u_int32, int32, u_int32)); - -extern void get_systime P((l_fp *)); -extern int step_systime P((double)); -extern int adj_systime P((double)); - -extern struct tm * ntp2unix_tm P((u_long ntp, int local)); - -#define lfptoa(_fpv, _ndec) mfptoa((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) -#define lfptoms(_fpv, _ndec) mfptoms((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) - -#define stoa(_sin) socktoa((_sin)) -#define stohost(_sin) socktohost((_sin)) - -#define ntoa(_sin) stoa(_sin) -#define ntohost(_sin) stohost(_sin) - -#define ufptoa(_fpv, _ndec) dofptoa((_fpv), 0, (_ndec), 0) -#define ufptoms(_fpv, _ndec) dofptoa((_fpv), 0, (_ndec), 1) -#define ulfptoa(_fpv, _ndec) dolfptoa((_fpv)->l_ui, (_fpv)->l_uf, 0, (_ndec), 0) -#define ulfptoms(_fpv, _ndec) dolfptoa((_fpv)->l_ui, (_fpv)->l_uf, 0, (_ndec), 1) -#define umfptoa(_fpi, _fpf, _ndec) dolfptoa((_fpi), (_fpf), 0, (_ndec), 0) +extern char * dofptoa (u_fp, int, short, int); +extern char * dolfptoa (u_int32, u_int32, int, short, int); + +extern int atolfp (const char *, l_fp *); +extern int buftvtots (const char *, l_fp *); +extern char * fptoa (s_fp, short); +extern char * fptoms (s_fp, short); +extern int hextolfp (const char *, l_fp *); +extern void gpstolfp (int, int, unsigned long, l_fp *); +extern int mstolfp (const char *, l_fp *); +extern char * prettydate (l_fp *); +extern char * gmprettydate (l_fp *); +extern char * uglydate (l_fp *); +extern void mfp_mul (int32 *, u_int32 *, int32, u_int32, int32, u_int32); + +extern void set_sys_fuzz (double); +extern void init_systime (void); +extern void get_systime (l_fp *); +extern int step_systime (double); +extern int adj_systime (double); + +extern struct tm * ntp2unix_tm (u_int32 ntp, int local); + +#define lfptoa(fpv, ndec) mfptoa((fpv)->l_ui, (fpv)->l_uf, (ndec)) +#define lfptoms(fpv, ndec) mfptoms((fpv)->l_ui, (fpv)->l_uf, (ndec)) + +#define stoa(addr) socktoa(addr) +#define ntoa(addr) stoa(addr) +#define sptoa(addr) sockporttoa(addr) +#define stohost(addr) socktohost(addr) + +#define ufptoa(fpv, ndec) dofptoa((fpv), 0, (ndec), 0) +#define ufptoms(fpv, ndec) dofptoa((fpv), 0, (ndec), 1) +#define ulfptoa(fpv, ndec) dolfptoa((fpv)->l_ui, (fpv)->l_uf, 0, (ndec), 0) +#define ulfptoms(fpv, ndec) dolfptoa((fpv)->l_ui, (fpv)->l_uf, 0, (ndec), 1) +#define umfptoa(fpi, fpf, ndec) dolfptoa((fpi), (fpf), 0, (ndec), 0) + +/* + * Optional callback from libntp step_systime() to ntpd. Optional +* because other libntp clients like ntpdate don't use it. + */ +typedef void (*time_stepped_callback)(void); +extern time_stepped_callback step_callback; + +/* + * Multi-thread locking for get_systime() + * + * On most systems, get_systime() is used solely by the main ntpd + * thread, but on Windows it's also used by the dedicated I/O thread. + * The [Bug 2037] changes to get_systime() have it keep state between + * calls to ensure time moves in only one direction, which means its + * use on Windows needs to be protected against simultaneous execution + * to avoid falsely detecting Lamport violations by ensuring only one + * thread at a time is in get_systime(). + */ +#ifdef SYS_WINNT +extern CRITICAL_SECTION get_systime_cs; +# define INIT_GET_SYSTIME_CRITSEC() \ + InitializeCriticalSection(&get_systime_cs) +# define ENTER_GET_SYSTIME_CRITSEC() \ + EnterCriticalSection(&get_systime_cs) +# define LEAVE_GET_SYSTIME_CRITSEC() \ + LeaveCriticalSection(&get_systime_cs) +# define INIT_WIN_PRECISE_TIME() \ + init_win_precise_time() +#else /* !SYS_WINNT follows */ +# define INIT_GET_SYSTIME_CRITSEC() \ + do {} while (FALSE) +# define ENTER_GET_SYSTIME_CRITSEC() \ + do {} while (FALSE) +# define LEAVE_GET_SYSTIME_CRITSEC() \ + do {} while (FALSE) +# define INIT_WIN_PRECISE_TIME() \ + do {} while (FALSE) +#endif #endif /* NTP_FP_H */ diff --git a/contrib/ntp/include/ntp_intres.h b/contrib/ntp/include/ntp_intres.h new file mode 100644 index 000000000..1b6bd66e0 --- /dev/null +++ b/contrib/ntp/include/ntp_intres.h @@ -0,0 +1,45 @@ +/* + * ntp_intres.h - client interface to blocking-worker name resolution. + */ +#ifndef NTP_INTRES_H +#define NTP_INTRES_H + +#include + +#ifdef WORKER +#define INITIAL_DNS_RETRY 2 /* seconds between queries */ + +/* + * you call getaddrinfo_sometime(name, service, &hints, retry, callback_func, context); + * later (*callback_func)(rescode, gai_errno, context, name, service, hints, ai_result) is called. + */ +typedef void (*gai_sometime_callback) + (int, int, void *, const char *, const char *, + const struct addrinfo *, const struct addrinfo *); +extern int getaddrinfo_sometime(const char *, const char *, + const struct addrinfo *, int, + gai_sometime_callback, void *); +/* + * In gai_sometime_callback routines, the resulting addrinfo list is + * only available until the callback returns. To hold on to the list + * of addresses after the callback returns, use copy_addrinfo_list(): + * + * struct addrinfo *copy_addrinfo_list(const struct addrinfo *); + */ + + +/* + * you call getnameinfo_sometime(sockaddr, namelen, servlen, flags, callback_func, context); + * later (*callback_func)(rescode, gni_errno, sockaddr, flags, name, service, context) is called. + */ +typedef void (*gni_sometime_callback) + (int, int, sockaddr_u *, int, const char *, + const char *, void *); +extern int getnameinfo_sometime(sockaddr_u *, size_t, size_t, int, + gni_sometime_callback, void *); +#endif /* WORKER */ + +/* intres_timeout_req() is provided by the client, ntpd or sntp. */ +extern void intres_timeout_req(u_int); + +#endif /* NTP_INTRES_H */ diff --git a/contrib/ntp/include/ntp_io.h b/contrib/ntp/include/ntp_io.h index 983c6c7dc..5950f0035 100644 --- a/contrib/ntp/include/ntp_io.h +++ b/contrib/ntp/include/ntp_io.h @@ -1,16 +1,13 @@ -#if !defined _NTP_IO_H -#define _NTP_IO_H +#ifndef NTP_IO_H +#define NTP_IO_H + +#include "ntp_workimpl.h" + /* * POSIX says use to get O_* symbols and * SEEK_SET symbol form . */ -#ifdef HAVE_CONFIG_H -# include -#endif - -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include #ifdef HAVE_UNISTD_H # include #endif @@ -30,6 +27,19 @@ # include "win32_io.h" #endif +#include +#include + +#if defined(HAVE_NETINET_IN_H) && defined(HAVE_NETINET_IP_H) +# include +# ifdef HAVE_NETINET_IN_SYSTM_H +# include +# endif +# include +#endif + +#include "libntp.h" /* This needs Something above for GETDTABLESIZE */ + /* * Define FNDELAY and FASYNC using O_NONBLOCK and O_ASYNC if we need * to (and can). This is here initially for QNX, but may help for @@ -47,4 +57,42 @@ # endif #endif + +/* + * NIC rule match types + */ +typedef enum { + MATCH_ALL, + MATCH_IPV4, + MATCH_IPV6, + MATCH_WILDCARD, + MATCH_IFNAME, + MATCH_IFADDR +} nic_rule_match; + +/* + * NIC rule actions + */ +typedef enum { + ACTION_LISTEN, + ACTION_IGNORE, + ACTION_DROP +} nic_rule_action; + + +extern int qos; +SOCKET move_fd(SOCKET fd); +isc_boolean_t get_broadcastclient_flag(void); +extern int is_ip_address(const char *, u_short, sockaddr_u *); +extern void sau_from_netaddr(sockaddr_u *, const isc_netaddr_t *); +extern void add_nic_rule(nic_rule_match match_type, + const char *if_name, int prefixlen, + nic_rule_action action); +#ifndef HAVE_IO_COMPLETION_PORT +extern void maintain_activefds(int fd, int closing); +#else +#define maintain_activefds(f, c) do {} while (0) #endif + + +#endif /* NTP_IO_H */ diff --git a/contrib/ntp/include/ntp_libopts.h b/contrib/ntp/include/ntp_libopts.h new file mode 100644 index 000000000..b03b2f66c --- /dev/null +++ b/contrib/ntp/include/ntp_libopts.h @@ -0,0 +1,14 @@ +/* + * ntp_libopts.h + * + * Common code interfacing with Autogen's libopts command-line option + * processing. + */ +#ifndef NTP_LIBOPTS_H +# define NTP_LIBOPTS_H +# include "autoopts/options.h" + +extern int ntpOptionProcess(tOptions *pOpts, int argc, + char ** argv); +extern void ntpOptionPrintVersion(tOptions *, tOptDesc *); +#endif diff --git a/contrib/ntp/include/ntp_lineedit.h b/contrib/ntp/include/ntp_lineedit.h new file mode 100644 index 000000000..623c6f402 --- /dev/null +++ b/contrib/ntp/include/ntp_lineedit.h @@ -0,0 +1,13 @@ + +/* + * ntp_lineedit.h - generic interface to various line editing libs + */ + +int ntp_readline_init(const char *prompt); +void ntp_readline_uninit(void); + +/* + * strings returned by ntp_readline go home to free() + */ +char * ntp_readline(int *pcount); + diff --git a/contrib/ntp/include/ntp_lists.h b/contrib/ntp/include/ntp_lists.h new file mode 100644 index 000000000..d74197494 --- /dev/null +++ b/contrib/ntp/include/ntp_lists.h @@ -0,0 +1,443 @@ +/* + * ntp_lists.h - linked lists common code + * + * SLIST: singly-linked lists + * ========================== + * + * These macros implement a simple singly-linked list template. Both + * the listhead and per-entry next fields are declared as pointers to + * the list entry struct type. Initialization to NULL is typically + * implicit (for globals and statics) or handled by zeroing of the + * containing structure. + * + * The name of the next link field is passed as an argument to allow + * membership in several lists at once using multiple next link fields. + * + * When possible, placing the link field first in the entry structure + * allows slightly smaller code to be generated on some platforms. + * + * LINK_SLIST(listhead, pentry, nextlink) + * add entry at head + * + * LINK_TAIL_SLIST(listhead, pentry, nextlink, entrytype) + * add entry at tail. This is O(n), if this is a common + * operation the FIFO template may be more appropriate. + * + * LINK_SORT_SLIST(listhead, pentry, beforecur, nextlink, entrytype) + * add entry in sorted order. beforecur is an expression comparing + * pentry with the current list entry. The current entry can be + * referenced within beforecur as L_S_S_CUR(), which is short for + * LINK_SORT_SLIST_CUR(). beforecur is nonzero if pentry sorts + * before L_S_S_CUR(). + * + * UNLINK_HEAD_SLIST(punlinked, listhead, nextlink) + * unlink first entry and point punlinked to it, or set punlinked + * to NULL if the list is empty. + * + * UNLINK_SLIST(punlinked, listhead, ptounlink, nextlink, entrytype) + * unlink entry pointed to by ptounlink. punlinked is set to NULL + * if the entry is not found on the list, otherwise it is set to + * ptounlink. + * + * UNLINK_EXPR_SLIST(punlinked, listhead, expr, nextlink, entrytype) + * unlink entry where expression expr is nonzero. expr can refer + * to the entry being tested using UNLINK_EXPR_SLIST_CURRENT(), + * alias U_E_S_CUR(). See the implementation of UNLINK_SLIST() + * below for an example. U_E_S_CUR() is NULL iff the list is empty. + * punlinked is pointed to the removed entry or NULL if none + * satisfy expr. + * + * FIFO: singly-linked lists plus tail pointer + * =========================================== + * + * This is the same as FreeBSD's sys/queue.h STAILQ -- a singly-linked + * list implementation with tail-pointer maintenance, so that adding + * at the tail for first-in, first-out access is O(1). + * + * DECL_FIFO_ANCHOR(entrytype) + * provides the type specification portion of the declaration for + * a variable to refer to a FIFO queue (similar to listhead). The + * anchor contains the head and indirect tail pointers. Example: + * + * #include "ntp_lists.h" + * + * typedef struct myentry_tag myentry; + * struct myentry_tag { + * myentry *next_link; + * ... + * }; + * + * DECL_FIFO_ANCHOR(myentry) my_fifo; + * + * void somefunc(myentry *pentry) + * { + * LINK_FIFO(my_fifo, pentry, next_link); + * } + * + * If DECL_FIFO_ANCHOR is used with stack or heap storage, it + * should be initialized to NULL pointers using a = { NULL }; + * initializer or memset. + * + * HEAD_FIFO(anchor) + * TAIL_FIFO(anchor) + * Pointer to first/last entry, NULL if FIFO is empty. + * + * LINK_FIFO(anchor, pentry, nextlink) + * add entry at tail. + * + * UNLINK_FIFO(punlinked, anchor, nextlink) + * unlink head entry and point punlinked to it, or set punlinked + * to NULL if the list is empty. + * + * CONCAT_FIFO(q1, q2, nextlink) + * empty fifoq q2 moving its nodes to q1 following q1's existing + * nodes. + * + * DLIST: doubly-linked lists + * ========================== + * + * Elements on DLISTs always have non-NULL forward and back links, + * because both link chains are circular. The beginning/end is marked + * by the listhead, which is the same type as elements for simplicity. + * An empty list's listhead has both links set to its own address. + * + * + */ +#ifndef NTP_LISTS_H +#define NTP_LISTS_H + +#include "ntp_types.h" /* TRUE and FALSE */ +#include "ntp_assert.h" + +#ifdef DEBUG +# define NTP_DEBUG_LISTS_H +#endif + +/* + * If list debugging is not enabled, save a little time by not clearing + * an entry's link pointer when it is unlinked, as the stale pointer + * is harmless as long as it is ignored when the entry is not in a + * list. + */ +#ifndef NTP_DEBUG_LISTS_H +#define MAYBE_Z_LISTS(p) do { } while (FALSE) +#else +#define MAYBE_Z_LISTS(p) (p) = NULL +#endif + +#define LINK_SLIST(listhead, pentry, nextlink) \ +do { \ + (pentry)->nextlink = (listhead); \ + (listhead) = (pentry); \ +} while (FALSE) + +#define LINK_TAIL_SLIST(listhead, pentry, nextlink, entrytype) \ +do { \ + entrytype **pptail; \ + \ + pptail = &(listhead); \ + while (*pptail != NULL) \ + pptail = &((*pptail)->nextlink); \ + \ + (pentry)->nextlink = NULL; \ + *pptail = (pentry); \ +} while (FALSE) + +#define LINK_SORT_SLIST_CURRENT() (*ppentry) +#define L_S_S_CUR() LINK_SORT_SLIST_CURRENT() + +#define LINK_SORT_SLIST(listhead, pentry, beforecur, nextlink, \ + entrytype) \ +do { \ + entrytype **ppentry; \ + \ + ppentry = &(listhead); \ + while (TRUE) { \ + if (NULL == *ppentry || (beforecur)) { \ + (pentry)->nextlink = *ppentry; \ + *ppentry = (pentry); \ + break; \ + } \ + ppentry = &((*ppentry)->nextlink); \ + if (NULL == *ppentry) { \ + (pentry)->nextlink = NULL; \ + *ppentry = (pentry); \ + break; \ + } \ + } \ +} while (FALSE) + +#define UNLINK_HEAD_SLIST(punlinked, listhead, nextlink) \ +do { \ + (punlinked) = (listhead); \ + if (NULL != (punlinked)) { \ + (listhead) = (punlinked)->nextlink; \ + MAYBE_Z_LISTS((punlinked)->nextlink); \ + } \ +} while (FALSE) + +#define UNLINK_EXPR_SLIST_CURRENT() (*ppentry) +#define U_E_S_CUR() UNLINK_EXPR_SLIST_CURRENT() + +#define UNLINK_EXPR_SLIST(punlinked, listhead, expr, nextlink, \ + entrytype) \ +do { \ + entrytype **ppentry; \ + \ + ppentry = &(listhead); \ + \ + while (!(expr)) \ + if (*ppentry != NULL && \ + (*ppentry)->nextlink != NULL) { \ + ppentry = &((*ppentry)->nextlink); \ + } else { \ + ppentry = NULL; \ + break; \ + } \ + \ + if (ppentry != NULL) { \ + (punlinked) = *ppentry; \ + *ppentry = (punlinked)->nextlink; \ + MAYBE_Z_LISTS((punlinked)->nextlink); \ + } else { \ + (punlinked) = NULL; \ + } \ +} while (FALSE) + +#define UNLINK_SLIST(punlinked, listhead, ptounlink, nextlink, \ + entrytype) \ + UNLINK_EXPR_SLIST(punlinked, listhead, (ptounlink) == \ + U_E_S_CUR(), nextlink, entrytype) + +#define CHECK_SLIST(listhead, nextlink, entrytype) \ +do { \ + entrytype *pentry; \ + \ + for (pentry = (listhead); \ + pentry != NULL; \ + pentry = pentry->nextlink) { \ + INSIST(pentry != pentry->nextlink); \ + INSIST((listhead) != pentry->nextlink); \ + } \ +} while (FALSE) + +/* + * FIFO + */ + +#define DECL_FIFO_ANCHOR(entrytype) \ +struct { \ + entrytype * phead; /* NULL if list empty */ \ + entrytype ** pptail; /* NULL if list empty */ \ +} + +#define HEAD_FIFO(anchor) ((anchor).phead) +#define TAIL_FIFO(anchor) ((NULL == (anchor).pptail) \ + ? NULL \ + : *((anchor).pptail)) + +/* + * For DEBUG builds only, verify both or neither of the anchor pointers + * are NULL with each operation. + */ +#if !defined(NTP_DEBUG_LISTS_H) +#define CHECK_FIFO_CONSISTENCY(anchor) do { } while (FALSE) +#else +#define CHECK_FIFO_CONSISTENCY(anchor) \ + check_gen_fifo_consistency(&(anchor)) +void check_gen_fifo_consistency(void *fifo); +#endif + +/* + * generic FIFO element used to access any FIFO where each element + * begins with the link pointer + */ +typedef struct gen_node_tag gen_node; +struct gen_node_tag { + gen_node * link; +}; + +/* generic FIFO */ +typedef DECL_FIFO_ANCHOR(gen_node) gen_fifo; + + +#define LINK_FIFO(anchor, pentry, nextlink) \ +do { \ + CHECK_FIFO_CONSISTENCY(anchor); \ + \ + (pentry)->nextlink = NULL; \ + if (NULL != (anchor).pptail) { \ + (*((anchor).pptail))->nextlink = (pentry); \ + (anchor).pptail = \ + &(*((anchor).pptail))->nextlink; \ + } else { \ + (anchor).phead = (pentry); \ + (anchor).pptail = &(anchor).phead; \ + } \ + \ + CHECK_FIFO_CONSISTENCY(anchor); \ +} while (FALSE) + +#define UNLINK_FIFO(punlinked, anchor, nextlink) \ +do { \ + CHECK_FIFO_CONSISTENCY(anchor); \ + \ + (punlinked) = (anchor).phead; \ + if (NULL != (punlinked)) { \ + (anchor).phead = (punlinked)->nextlink; \ + if (NULL == (anchor).phead) \ + (anchor).pptail = NULL; \ + else if ((anchor).pptail == \ + &(punlinked)->nextlink) \ + (anchor).pptail = &(anchor).phead; \ + MAYBE_Z_LISTS((punlinked)->nextlink); \ + CHECK_FIFO_CONSISTENCY(anchor); \ + } \ +} while (FALSE) + +#define UNLINK_MID_FIFO(punlinked, anchor, tounlink, nextlink, \ + entrytype) \ +do { \ + entrytype **ppentry; \ + \ + CHECK_FIFO_CONSISTENCY(anchor); \ + \ + ppentry = &(anchor).phead; \ + \ + while ((tounlink) != *ppentry) \ + if ((*ppentry)->nextlink != NULL) { \ + ppentry = &((*ppentry)->nextlink); \ + } else { \ + ppentry = NULL; \ + break; \ + } \ + \ + if (ppentry != NULL) { \ + (punlinked) = *ppentry; \ + *ppentry = (punlinked)->nextlink; \ + if (NULL == *ppentry) \ + (anchor).pptail = NULL; \ + else if ((anchor).pptail == \ + &(punlinked)->nextlink) \ + (anchor).pptail = &(anchor).phead; \ + MAYBE_Z_LISTS((punlinked)->nextlink); \ + CHECK_FIFO_CONSISTENCY(anchor); \ + } else { \ + (punlinked) = NULL; \ + } \ +} while (FALSE) + +#define CONCAT_FIFO(f1, f2, nextlink) \ +do { \ + CHECK_FIFO_CONSISTENCY(f1); \ + CHECK_FIFO_CONSISTENCY(f2); \ + \ + if ((f2).pptail != NULL) { \ + if ((f1).pptail != NULL) { \ + (*(f1).pptail)->nextlink = (f2).phead; \ + if ((f2).pptail == &(f2).phead) \ + (f1).pptail = \ + &(*(f1).pptail)->nextlink; \ + else \ + (f1).pptail = (f2).pptail; \ + CHECK_FIFO_CONSISTENCY(f1); \ + } else { \ + (f1) = (f2); \ + } \ + MAYBE_Z_LISTS((f2).phead); \ + MAYBE_Z_LISTS((f2).pptail); \ + } \ +} while (FALSE) + +/* + * DLIST + */ +#define DECL_DLIST_LINK(entrytype, link) \ +struct { \ + entrytype * b; \ + entrytype * f; \ +} link + +#define INIT_DLIST(listhead, link) \ +do { \ + (listhead).link.f = &(listhead); \ + (listhead).link.b = &(listhead); \ +} while (FALSE) + +#define HEAD_DLIST(listhead, link) \ + ( \ + (&(listhead) != (listhead).link.f) \ + ? (listhead).link.f \ + : NULL \ + ) + +#define TAIL_DLIST(listhead, link) \ + ( \ + (&(listhead) != (listhead).link.b) \ + ? (listhead).link.b \ + : NULL \ + ) + +#define NEXT_DLIST(listhead, entry, link) \ + ( \ + (&(listhead) != (entry)->link.f) \ + ? (entry)->link.f \ + : NULL \ + ) + +#define PREV_DLIST(listhead, entry, link) \ + ( \ + (&(listhead) != (entry)->link.b) \ + ? (entry)->link.b \ + : NULL \ + ) + +#define LINK_DLIST(listhead, pentry, link) \ +do { \ + (pentry)->link.f = (listhead).link.f; \ + (pentry)->link.b = &(listhead); \ + (listhead).link.f->link.b = (pentry); \ + (listhead).link.f = (pentry); \ +} while (FALSE) + +#define LINK_TAIL_DLIST(listhead, pentry, link) \ +do { \ + (pentry)->link.b = (listhead).link.b; \ + (pentry)->link.f = &(listhead); \ + (listhead).link.b->link.f = (pentry); \ + (listhead).link.b = (pentry); \ +} while (FALSE) + +#define UNLINK_DLIST(ptounlink, link) \ +do { \ + (ptounlink)->link.b->link.f = (ptounlink)->link.f; \ + (ptounlink)->link.f->link.b = (ptounlink)->link.b; \ + MAYBE_Z_LISTS((ptounlink)->link.b); \ + MAYBE_Z_LISTS((ptounlink)->link.f); \ +} while (FALSE) + +#define ITER_DLIST_BEGIN(listhead, iter, link, entrytype) \ +{ \ + entrytype *i_dl_nextiter; \ + \ + for ((iter) = (listhead).link.f; \ + (iter) != &(listhead) \ + && ((i_dl_nextiter = (iter)->link.f), TRUE); \ + (iter) = i_dl_nextiter) { +#define ITER_DLIST_END() \ + } \ +} + +#define REV_ITER_DLIST_BEGIN(listhead, iter, link, entrytype) \ +{ \ + entrytype *i_dl_nextiter; \ + \ + for ((iter) = (listhead).link.b; \ + (iter) != &(listhead) \ + && ((i_dl_nextiter = (iter)->link.b), TRUE); \ + (iter) = i_dl_nextiter) { +#define REV_ITER_DLIST_END() \ + } \ +} + +#endif /* NTP_LISTS_H */ diff --git a/contrib/ntp/include/ntp_machine.h b/contrib/ntp/include/ntp_machine.h index 2a3b6e6a6..c5e7248e4 100644 --- a/contrib/ntp/include/ntp_machine.h +++ b/contrib/ntp/include/ntp_machine.h @@ -1,24 +1,19 @@ /* + * ntp_machine.h + * * Collect all machine dependent idiosyncrasies in one place. + * + * The functionality formerly in this file is mostly handled by + * Autoconf these days. */ -#ifndef __ntp_machine -#define __ntp_machine +#ifndef NTP_MACHINE_H +#define NTP_MACHINE_H -#ifdef HAVE_CONFIG_H -# include -#endif - -#ifdef TIME_WITH_SYS_TIME +#ifdef HAVE_SYS_TIME_H # include -# include -#else -# ifdef HAVE_SYS_TIME_H -# include -# else -# include -# endif #endif +#include #include "ntp_proto.h" @@ -26,9 +21,6 @@ HEY! CHECK THIS OUT! - The first half of this file is obsolete, and is only there to help - reconcile "what went before" with "current behavior". - The per-system SYS_* #defins ARE NO LONGER USED, with the temporary exception of SYS_WINNT. @@ -40,13 +32,6 @@ /* -INFO ON NEW KERNEL PLL SYS CALLS - - NTP_SYSCALLS_STD - use the "normal" ones - NTP_SYSCALL_GET - SYS_ntp_gettime id - NTP_SYSCALL_ADJ - SYS_ntp_adjtime id - NTP_SYSCALLS_LIBC - ntp_adjtime() and ntp_gettime() are in libc. - HOW TO GET IP INTERFACE INFORMATION Some UNIX V.4 machines implement a sockets library on top of @@ -74,225 +59,13 @@ WILL IOCTL(SIOCGIFCONF) WORK ON A SOCKET MISC - HAVE_PROTOTYPES - Prototype functions DOSYNCTODR - Resync TODR clock every hour. RETSIGTYPE - Define signal function type. NO_SIGNED_CHAR_DECL - No "signed char" see include/ntp.h LOCK_PROCESS - Have plock. */ -/* - * Set up for prototyping (duplicated from ntp_types.h) - */ -#ifndef P -#if defined(__STDC__) || defined(HAVE_PROTOTYPES) -#define P(x) x -#else /* not __STDC__ and not HAVE_PROTOTYPES */ -#define P(x) () -#endif /* not __STDC__ and not HAVE_PROTOTYPES */ -#endif /* P */ - -#if !defined(HAVE_NTP_ADJTIME) && defined(HAVE___ADJTIMEX) -# define ntp_adjtime __adjtimex -#endif - -#if 0 - -/* - * IRIX 4.X and IRIX 5.x - */ -#if defined(SYS_IRIX4)||defined(SYS_IRIX5) -# define ADJTIME_IS_ACCURATE -# define LOCK_PROCESS -#endif - -/* - * Ultrix - * Note: posix version has NTP_POSIX_SOURCE and HAVE_SIGNALED_IO - */ -#if defined(SYS_ULTRIX) -# define S_CHAR_DEFINED -# define NTP_SYSCALLS_STD -# define HAVE_MODEM_CONTROL -#endif - -/* - * AUX - */ -#if defined(SYS_AUX2) || defined(SYS_AUX3) -# define NO_SIGNED_CHAR_DECL -# define LOCK_PROCESS -# define NTP_POSIX_SOURCE -/* - * This requires that _POSIX_SOURCE be forced on the - * compiler command flag. We can't do it here since this - * file is included _after_ the system header files and we - * need to let _them_ know we're POSIX. We do this in - * compilers/aux3.gcc... - */ -# define LOG_NTP LOG_LOCAL1 -#endif - -/* - * HPUX - */ -#if defined(SYS_HPUX) -# define getdtablesize() sysconf(_SC_OPEN_MAX) -# define setlinebuf(f) setvbuf(f, NULL, _IOLBF, 0) -# define NO_SIGNED_CHAR_DECL -# define LOCK_PROCESS -#endif - -/* - * BSD/OS 2.0 and above - */ -#if defined(SYS_BSDI) -# define USE_FSETOWNCTTY /* this funny system demands a CTTY for FSETOWN */ -#endif - -/* - * FreeBSD 2.0 and above - */ -#ifdef SYS_FREEBSD -# define KERNEL_PLL -#endif - -/* - * Linux - */ -#if defined(SYS_LINUX) -# define ntp_adjtime __adjtimex -#endif - -/* - * PTX - */ -#if defined(SYS_PTX) -# define LOCK_PROCESS -struct timezone { int __0; }; /* unused placebo */ -/* - * no comment !@! - */ -typedef unsigned int u_int; -# ifndef _NETINET_IN_SYSTM_INCLUDED /* i am about to comment... */ -typedef unsigned char u_char; -typedef unsigned short u_short; -typedef unsigned long u_long; -# endif -#endif - -/* - * UNIX V.4 on and NCR 3000 - */ -#if defined(SYS_SVR4) -# define STREAM -# define LOCK_PROCESS -# define SIZE_RETURNED_IN_BUFFER -#endif - -/* - * (Univel/Novell) Unixware1 SVR4 on intel x86 processor - */ -#if defined(SYS_UNIXWARE1) -/* #define _POSIX_SOURCE */ -# define STREAM -# define STREAMS -# undef STEP_SLEW /* TWO step */ -# define LOCK_PROCESS -# define SIZE_RETURNED_IN_BUFFER -# include -# include -# include -#endif - -/* - * DomainOS - */ -#if defined(SYS_DOMAINOS) -# define NTP_SYSCALLS_STD -/* older versions of domain/os don't have class D */ -# ifndef IN_CLASSD -# define IN_CLASSD(i) (((long)(i) & 0xf0000000) == 0xe0000000) -# define IN_CLASSD_NET 0xf0000000 -# define IN_CLASSD_NSHIFT 28 -# define IN_CLASSD_HOST 0xfffffff -# define IN_MULTICAST(i) IN_CLASSD(i) -# endif -#endif - -/* - * Fujitsu UXP/V - */ -#if defined(SYS_UXPV) -# define LOCK_PROCESS -# define SIZE_RETURNED_IN_BUFFER -#endif - - -#endif /* 0 */ - -/* - * Define these here for non-Windows NT systems - * SOCKET and INVALID_SOCKET are native macros - * on Windows NT and since they have different - * requirements we use them in the code and - * make them macros for everyone else - */ -#ifndef SYS_WINNT -# define SOCKET int -# define INVALID_SOCKET -1 -# define SOCKET_ERROR -1 -# define closesocket close -#endif -/* - * Windows NT - */ -#if defined(SYS_WINNT) -# if !defined(HAVE_CONFIG_H) || !defined(__config) -# include -# endif /* HAVE_CONFIG_H) */ -# include -# include -# include - -# define ifreq _INTERFACE_INFO -# define ifr_flags iiFlags -# define ifr_addr iiAddress.AddressIn -# define ifr_broadaddr iiBroadcastAddress.AddressIn -# define ifr_mask iiNetmask.AddressIn -# define zz_family sin_family - -# define S_IFREG _S_IFREG -# define stat _stat -# define isascii __isascii -# define isatty _isatty -# define mktemp _mktemp -# define unlink _unlink -# define fileno _fileno -# define write _write -#ifndef close -# define close _close -#endif -# undef interface -# include -#define getpid _getpid -/* - * Defining registers are not a good idea on Windows - * This gets rid of the usage - */ -#ifndef register -# define register -#endif - typedef char *caddr_t; -# define vsnprintf _vsnprintf -#endif /* SYS_WINNT */ - -int ntp_set_tod P((struct timeval *tvp, void *tzp)); - -#if defined (SYS_CYGWIN32) -#include -#define __int64 long long -#endif +int ntp_set_tod (struct timeval *tvp, void *tzp); /*casey Tue May 27 15:45:25 SAT 1997*/ #ifdef SYS_VXWORKS @@ -315,8 +88,6 @@ int ntp_set_tod P((struct timeval *tvp, void *tzp)); #define HAVE_RANDOM 1 /* configure does not set this ... */ #define HAVE_SRANDOM 1 /* configure does not set this ... */ -#define NODETACH 1 - /* vxWorks specific additions to take care of its * unix (non)complicance */ @@ -326,7 +97,7 @@ int ntp_set_tod P((struct timeval *tvp, void *tzp)); #include "taskLib.h" #include "time.h" -extern int sysClkRateGet P(()); +extern int sysClkRateGet (); /* usrtime.h * Bob Herlien's excellent time code find it at: @@ -335,14 +106,14 @@ extern int sysClkRateGet P(()); * adjtime() too ... casey */ /* -extern int gettimeofday P(( struct timeval *tp, struct timezone *tzp )); -extern int settimeofday P((struct timeval *, struct timezone *)); -extern int adjtime P(( struct timeval *delta, struct timeval *olddelta )); +extern int gettimeofday ( struct timeval *tp, struct timezone *tzp ); +extern int settimeofday (struct timeval *, struct timezone *); +extern int adjtime ( struct timeval *delta, struct timeval *olddelta ); */ /* in machines.c */ -extern void sleep P((int seconds)); -extern void alarm P((int seconds)); +extern void sleep (int seconds); +extern void alarm (int seconds); /* machines.c */ @@ -382,10 +153,10 @@ extern int h_errno; #define TRY_AGAIN 2 -struct hostent *gethostbyname P((char * netnum)); -struct hostent *gethostbyaddr P((char * netnum, int size, int addr_type)); +struct hostent *gethostbyname (char * netnum); +struct hostent *gethostbyaddr (char * netnum, int size, int addr_type); /* type is the protocol */ -struct servent *getservbyname P((char *name, char *type)); +struct servent *getservbyname (char *name, char *type); #endif /* NO_NETDB */ #ifdef NO_MAIN_ALLOWED @@ -479,7 +250,6 @@ struct servent *getservbyname P((char *name, char *type)); # define IN_CLASSD(i) ((((long)(i))&0xf0000000)==0xe0000000) # define IN_MULTICAST IN_CLASSD # define ITIMER_REAL 0 -# define MAXHOSTNAMELEN 64 /* standard structures missing from MPE include files */ @@ -515,76 +285,13 @@ extern char *strdup(const char *); #if !defined(HAVE_ATT_NICE) \ && !defined(HAVE_BSD_NICE) \ - && !defined(HAVE_NO_NICE) \ - && !defined(SYS_WINNT) + && !defined(HAVE_NO_NICE) #include "ERROR: You must define one of the HAVE_xx_NICE defines!" #endif -/* - * use only one tty model - no use in initialising - * a tty in three ways - * HAVE_TERMIOS is preferred over HAVE_SYSV_TTYS over HAVE_BSD_TTYS - */ - -#ifdef HAVE_TERMIOS_H -# define HAVE_TERMIOS -#else -# ifdef HAVE_TERMIO_H -# define HAVE_SYSV_TTYS -# else -# ifdef HAVE_SGTTY_H -# define HAVE_BSD_TTYS -# endif -# endif -#endif - -#ifdef HAVE_TERMIOS -# undef HAVE_BSD_TTYS -# undef HAVE_SYSV_TTYS -#endif - #ifndef HAVE_TIMEGM -extern time_t timegm P((struct tm *)); -#endif - -#ifdef HAVE_SYSV_TTYS -# undef HAVE_BSD_TTYS +extern time_t timegm (struct tm *); #endif -#if !defined(SYS_WINNT) && !defined(VMS) && !defined(SYS_VXWORKS) -# if !defined(HAVE_SYSV_TTYS) \ - && !defined(HAVE_BSD_TTYS) \ - && !defined(HAVE_TERMIOS) -#include "ERROR: no tty type defined!" -# endif -#endif /* SYS_WINNT || VMS || SYS_VXWORKS*/ - -#ifdef WORDS_BIGENDIAN -# define XNTP_BIG_ENDIAN 1 -#else -# define XNTP_LITTLE_ENDIAN 1 -#endif - -/* - * Byte order woes. - * This used to be resolved by calling ntohl() and htonl() to swap things - * around, but this turned out to be quite costly on Vaxes where those - * things are actual functions. The code now straightens out byte - * order troubles on its own, with no performance penalty for little - * end first machines, but at great expense to cleanliness. - */ -#if !defined(XNTP_BIG_ENDIAN) && !defined(XNTP_LITTLE_ENDIAN) - /* - * Pick one or the other. - */ - BYTE_ORDER_NOT_DEFINED_FOR_AUTHENTICATION -#endif - -#if defined(XNTP_BIG_ENDIAN) && defined(XNTP_LITTLE_ENDIAN) - /* - * Pick one or the other. - */ - BYTE_ORDER_NOT_DEFINED_FOR_AUTHENTICATION -#endif -#endif /* __ntp_machine */ +#endif /* NTP_MACHINE_H */ diff --git a/contrib/ntp/include/ntp_malloc.h b/contrib/ntp/include/ntp_malloc.h index 099c83eff..4cde62e1a 100644 --- a/contrib/ntp/include/ntp_malloc.h +++ b/contrib/ntp/include/ntp_malloc.h @@ -1,19 +1,61 @@ /* * Define malloc and friends. */ -#ifndef _ntp_malloc_h -#define _ntp_malloc_h - -#ifdef HAVE_CONFIG_H -# include -#endif +#ifndef NTP_MALLOC_H +#define NTP_MALLOC_H #ifdef HAVE_STDLIB_H # include -#else /* HAVE_STDLIB_H */ +#else # ifdef HAVE_MALLOC_H # include # endif -#endif /* HAVE_STDLIB_H */ +#endif + +/* + * Deal with platform differences declaring alloca() + * This comes nearly verbatim from: + * + * http://www.gnu.org/software/autoconf/manual/autoconf.html#Particular-Functions + * + * The only modifications were to remove C++ support and guard against + * redefining alloca. + */ +#ifdef HAVE_ALLOCA_H +# include +#elif defined __GNUC__ +# ifndef alloca +# define alloca __builtin_alloca +# endif +#elif defined _AIX +# ifndef alloca +# define alloca __alloca +# endif +#elif defined _MSC_VER +# include +# ifndef alloca +# define alloca _alloca +# endif +#else +# include +void * alloca(size_t); +#endif + +#ifdef EREALLOC_IMPL +# define EREALLOC_CALLSITE /* preserve __FILE__ and __LINE__ */ +#else +# define EREALLOC_IMPL(ptr, newsz, filenm, loc) \ + realloc(ptr, (newsz)) +#endif + +#ifdef HAVE_STRINGS_H +# include +# define zero_mem(p, s) bzero(p, s) +#endif + +#ifndef zero_mem +# define zero_mem(p, s) memset(p, 0, s) +#endif +#define ZERO(var) zero_mem(&(var), sizeof(var)) -#endif /* _ntp_malloc_h */ +#endif /* NTP_MALLOC_H */ diff --git a/contrib/ntp/include/ntp_md5.h b/contrib/ntp/include/ntp_md5.h index bb6985a2f..2306b9a87 100644 --- a/contrib/ntp/include/ntp_md5.h +++ b/contrib/ntp/include/ntp_md5.h @@ -1,9 +1,40 @@ /* * ntp_md5.h: deal with md5.h headers + * + * Use the system MD5 if available, otherwise libisc's. */ +#ifndef NTP_MD5_H +#define NTP_MD5_H -#ifdef HAVE_MD5_H -# include -#else -# include "rsa_md5.h" -#endif +#ifdef OPENSSL +# include "openssl/evp.h" +#else /* !OPENSSL follows */ +/* + * Provide OpenSSL-alike MD5 API if we're not using OpenSSL + */ +# if defined HAVE_MD5_H && defined HAVE_MD5INIT +# include +# else +# include "isc/md5.h" + typedef isc_md5_t MD5_CTX; +# define MD5Init(c) isc_md5_init(c) +# define MD5Update(c, p, s) isc_md5_update(c, p, s) +# define MD5Final(d, c) isc_md5_final((c), (d)) /* swapped */ +# endif + + typedef MD5_CTX EVP_MD_CTX; +# define EVP_get_digestbynid(t) NULL +# define EVP_md5() NULL +# define EVP_MD_CTX_init(c) +# define EVP_MD_CTX_set_flags(c, f) +# define EVP_DigestInit(c, dt) (MD5Init(c), 1) +# define EVP_DigestInit_ex(c, dt, i) (MD5Init(c), 1) +# define EVP_DigestUpdate(c, p, s) MD5Update(c, (const void *)(p), \ + s) +# define EVP_DigestFinal(c, d, pdl) \ + do { \ + MD5Final((d), (c)); \ + *(pdl) = 16; \ + } while (0) +# endif /* !OPENSSL */ +#endif /* NTP_MD5_H */ diff --git a/contrib/ntp/include/ntp_net.h b/contrib/ntp/include/ntp_net.h new file mode 100644 index 000000000..0577402bf --- /dev/null +++ b/contrib/ntp/include/ntp_net.h @@ -0,0 +1,238 @@ +/* + * ntp_net.h - definitions for NTP network stuff + */ + +#ifndef NTP_NET_H +#define NTP_NET_H + +#include +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NET_IF_H +#include +#endif +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NET_IF_VAR_H +#include +#endif +#ifdef HAVE_NETINET_IN_VAR_H +#include +#endif + +#include "ntp_rfc2553.h" +#include "ntp_malloc.h" + +typedef union { + struct sockaddr sa; + struct sockaddr_in sa4; + struct sockaddr_in6 sa6; +} sockaddr_u; + +/* + * Utilities for manipulating sockaddr_u v4/v6 unions + */ +#define SOCK_ADDR4(psau) ((psau)->sa4.sin_addr) +#define SOCK_ADDR6(psau) ((psau)->sa6.sin6_addr) + +#define PSOCK_ADDR4(psau) (&SOCK_ADDR4(psau)) +#define PSOCK_ADDR6(psau) (&SOCK_ADDR6(psau)) + +#define AF(psau) ((psau)->sa.sa_family) + +#define IS_IPV4(psau) (AF_INET == AF(psau)) +#define IS_IPV6(psau) (AF_INET6 == AF(psau)) + +/* sockaddr_u v4 address in network byte order */ +#define NSRCADR(psau) (SOCK_ADDR4(psau).s_addr) + +/* sockaddr_u v4 address in host byte order */ +#define SRCADR(psau) (ntohl(NSRCADR(psau))) + +/* sockaddr_u v6 address in network byte order */ +#define NSRCADR6(psau) (SOCK_ADDR6(psau).s6_addr) + +/* assign sockaddr_u v4 address from host byte order */ +#define SET_ADDR4(psau, addr4) (NSRCADR(psau) = htonl(addr4)) + +/* assign sockaddr_u v4 address from network byte order */ +#define SET_ADDR4N(psau, addr4n) (NSRCADR(psau) = (addr4n)); + +/* assign sockaddr_u v6 address from network byte order */ +#define SET_ADDR6N(psau, s6_addr) \ + (SOCK_ADDR6(psau) = (s6_addr)) + +/* sockaddr_u v4/v6 port in network byte order */ +#define NSRCPORT(psau) ((psau)->sa4.sin_port) + +/* sockaddr_u v4/v6 port in host byte order */ +#define SRCPORT(psau) (ntohs(NSRCPORT(psau))) + +/* assign sockaddr_u v4/v6 port from host byte order */ +#define SET_PORT(psau, port) (NSRCPORT(psau) = htons(port)) + +/* sockaddr_u v6 scope */ +#define SCOPE_VAR(psau) ((psau)->sa6.sin6_scope_id) + +#ifdef ISC_PLATFORM_HAVESCOPEID +/* v4/v6 scope (always zero for v4) */ +# define SCOPE(psau) (IS_IPV4(psau) \ + ? 0 \ + : SCOPE_VAR(psau)) + +/* are two v6 sockaddr_u scopes equal? */ +# define SCOPE_EQ(psau1, psau2) \ + (SCOPE_VAR(psau1) == SCOPE_VAR(psau2)) + +/* assign scope if supported */ +# define SET_SCOPE(psau, s) \ + do \ + if (IS_IPV6(psau)) \ + SCOPE_VAR(psau) = (s); \ + while (0) +#else /* ISC_PLATFORM_HAVESCOPEID not defined */ +# define SCOPE(psau) (0) +# define SCOPE_EQ(psau1, psau2) (1) +# define SET_SCOPE(psau, s) do { } while (0) +#endif /* ISC_PLATFORM_HAVESCOPEID */ + +/* v4/v6 is multicast address */ +#define IS_MCAST(psau) \ + (IS_IPV4(psau) \ + ? IN_CLASSD(SRCADR(psau)) \ + : IN6_IS_ADDR_MULTICAST(PSOCK_ADDR6(psau))) + +/* v6 is interface ID scope universal, as with MAC-derived addresses */ +#define IS_IID_UNIV(psau) \ + (!!(0x02 & NSRCADR6(psau)[8])) + +#define SIZEOF_INADDR(fam) \ + ((AF_INET == (fam)) \ + ? sizeof(struct in_addr) \ + : sizeof(struct in6_addr)) + +#define SIZEOF_SOCKADDR(fam) \ + ((AF_INET == (fam)) \ + ? sizeof(struct sockaddr_in) \ + : sizeof(struct sockaddr_in6)) + +#define SOCKLEN(psau) \ + (IS_IPV4(psau) \ + ? sizeof((psau)->sa4) \ + : sizeof((psau)->sa6)) + +#define ZERO_SOCK(psau) \ + ZERO(*(psau)) + +/* blast a byte value across sockaddr_u v6 address */ +#define MEMSET_ADDR6(psau, v) \ + memset((psau)->sa6.sin6_addr.s6_addr, (v), \ + sizeof((psau)->sa6.sin6_addr.s6_addr)) + +#define SET_ONESMASK(psau) \ + do { \ + if (IS_IPV6(psau)) \ + MEMSET_ADDR6((psau), 0xff); \ + else \ + NSRCADR(psau) = 0xffffffff; \ + } while(0) + +/* zero sockaddr_u, fill in family and all-ones (host) mask */ +#define SET_HOSTMASK(psau, family) \ + do { \ + ZERO_SOCK(psau); \ + AF(psau) = (family); \ + SET_ONESMASK(psau); \ + } while (0) + +/* + * compare two in6_addr returning negative, 0, or positive. + * ADDR6_CMP is negative if *pin6A is lower than *pin6B, zero if they + * are equal, positive if *pin6A is higher than *pin6B. IN6ADDR_ANY + * is the lowest address (128 zero bits). + */ +#define ADDR6_CMP(pin6A, pin6B) \ + memcmp((pin6A)->s6_addr, (pin6B)->s6_addr, \ + sizeof(pin6A)->s6_addr) + +/* compare two in6_addr for equality only */ +#if !defined(SYS_WINNT) || !defined(in_addr6) +#define ADDR6_EQ(pin6A, pin6B) \ + (!ADDR6_CMP(pin6A, pin6B)) +#else +#define ADDR6_EQ(pin6A, pin6B) \ + IN6_ADDR_EQUAL(pin6A, pin6B) +#endif + +/* compare a in6_addr with socket address */ +#define S_ADDR6_EQ(psau, pin6) \ + ADDR6_EQ(&(psau)->sa6.sin6_addr, pin6) + +/* are two sockaddr_u's addresses equal? (port excluded) */ +#define SOCK_EQ(psau1, psau2) \ + ((AF(psau1) != AF(psau2)) \ + ? 0 \ + : IS_IPV4(psau1) \ + ? (NSRCADR(psau1) == NSRCADR(psau2)) \ + : (S_ADDR6_EQ((psau1), PSOCK_ADDR6(psau2)) \ + && SCOPE_EQ((psau1), (psau2)))) + +/* are two sockaddr_u's addresses and ports equal? */ +#define ADDR_PORT_EQ(psau1, psau2) \ + ((NSRCPORT(psau1) != NSRCPORT(psau2) \ + ? 0 \ + : SOCK_EQ((psau1), (psau2)))) + +/* is sockaddr_u address unspecified? */ +#define SOCK_UNSPEC(psau) \ + (IS_IPV4(psau) \ + ? !NSRCADR(psau) \ + : IN6_IS_ADDR_UNSPECIFIED(PSOCK_ADDR6(psau))) + +/* just how unspecified do you mean? (scope 0/unspec too) */ +#define SOCK_UNSPEC_S(psau) \ + (SOCK_UNSPEC(psau) && !SCOPE(psau)) + +/* choose a default net interface (struct interface) for v4 or v6 */ +#define ANY_INTERFACE_BYFAM(family) \ + ((AF_INET == family) \ + ? any_interface \ + : any6_interface) + +/* choose a default interface for addresses' protocol (addr family) */ +#define ANY_INTERFACE_CHOOSE(psau) \ + ANY_INTERFACE_BYFAM(AF(psau)) + + +/* + * We tell reference clocks from real peers by giving the reference + * clocks an address of the form 127.127.t.u, where t is the type and + * u is the unit number. We define some of this here since we will need + * some sanity checks to make sure this address isn't interpretted as + * that of a normal peer. + */ +#define REFCLOCK_ADDR 0x7f7f0000 /* 127.127.0.0 */ +#define REFCLOCK_MASK 0xffff0000 /* 255.255.0.0 */ + +#define ISREFCLOCKADR(srcadr) \ + (IS_IPV4(srcadr) && \ + (SRCADR(srcadr) & REFCLOCK_MASK) == REFCLOCK_ADDR) + +/* + * Macro for checking for invalid addresses. This is really, really + * gross, but is needed so no one configures a host on net 127 now that + * we're encouraging it the the configuration file. + */ +#define LOOPBACKADR 0x7f000001 +#define LOOPNETMASK 0xff000000 + +#define ISBADADR(srcadr) \ + (IS_IPV4(srcadr) \ + && ((SRCADR(srcadr) & LOOPNETMASK) \ + == (LOOPBACKADR & LOOPNETMASK)) \ + && SRCADR(srcadr) != LOOPBACKADR) + + +#endif /* NTP_NET_H */ diff --git a/contrib/ntp/include/ntp_prio_q.h b/contrib/ntp/include/ntp_prio_q.h new file mode 100644 index 000000000..4b5ffca52 --- /dev/null +++ b/contrib/ntp/include/ntp_prio_q.h @@ -0,0 +1,83 @@ +/* ntp_prio_q.h + * + * This file contains the structures and function prototypes for the + * priority queue implementation used by the discrete event simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ + +#ifndef NTP_PRIO_Q_H +#define NTP_PRIO_Q_H + +#include /* size_t */ + +/* Structures for storing a priority queue + * --------------------------------------- + */ + +typedef struct node { + union { + struct node *next; + double d; + } nodeu; +} node; +#define node_next nodeu.next + +typedef int (*q_order_func)(const void *, const void *); + +typedef struct Queue { + q_order_func get_order; + node * front; + int no_of_elements; +} queue; + + +/* FUNCTION PROTOTYPES + * ------------------- + */ +/* Define a function to create a FIFO queue */ +#define create_queue() create_priority_queue(&get_fifo_order) + +void destroy_queue(queue *my_queue); +void free_node(void *my_node); +void *next_node(void *my_node); +int empty(queue *my_queue); +void *queue_head(queue *my_queue); +queue *enqueue(queue *my_queue, void *my_node); +void append_queue(queue *q1, queue *q2); +void *dequeue(queue *my_queue); +int get_no_of_elements(queue *my_queue); +int get_fifo_order(const void *el1, const void *el2); + +/* + * Preserve original callsite __FILE__ and __LINE__ for these + * malloc-like funcs when using MS C runtime debug heap. + */ +#ifdef _CRTDBG_MAP_ALLOC +# define create_priority_queue(order) debug_create_priority_queue(order, __FILE__, __LINE__) +# define get_node(size) debug_get_node(size, __FILE__, __LINE__) +#else +# define create_priority_queue(order) debug_create_priority_queue(order) +# define get_node(size) debug_get_node(size) +#endif + +queue *debug_create_priority_queue( + q_order_func get_order +#ifdef _CRTDBG_MAP_ALLOC + , const char * sourcefile + , int line_num +#endif + ); + +void *debug_get_node( + size_t size +#ifdef _CRTDBG_MAP_ALLOC + , const char * sourcefile + , int line_num +#endif + ); + +#endif /* NTP_PRIO_Q_H */ diff --git a/contrib/ntp/include/ntp_proto.h b/contrib/ntp/include/ntp_proto.h index e6e785533..1d04b78ab 100644 --- a/contrib/ntp/include/ntp_proto.h +++ b/contrib/ntp/include/ntp_proto.h @@ -1,10 +1,6 @@ -#ifndef __ntp_proto_h -#define __ntp_proto_h - -#ifdef HAVE_CONFIG_H -#include -#endif +#ifndef NTP_PROTO_H +#define NTP_PROTO_H #define NTP_MAXFREQ 500e-6 -#endif /* __ntp_proto_h */ +#endif /* NTP_PROTO_H */ diff --git a/contrib/ntp/include/ntp_random.h b/contrib/ntp/include/ntp_random.h index 766dcc376..fa77f6553 100644 --- a/contrib/ntp/include/ntp_random.h +++ b/contrib/ntp/include/ntp_random.h @@ -1,14 +1,17 @@ #include -long ntp_random P((void)); -void ntp_srandom P((unsigned long)); -void ntp_srandomdev P((void)); -char * ntp_initstate P((unsigned long, /* seed for R.N.G. */ +void ntp_crypto_srandom(void); +int ntp_crypto_random_buf(void *buf, size_t nbytes); + +long ntp_random (void); +void ntp_srandom (unsigned long); +void ntp_srandomdev (void); +char * ntp_initstate (unsigned long, /* seed for R.N.G. */ char *, /* pointer to state array */ long /* # bytes of state info */ - )); -char * ntp_setstate P((char *)); /* pointer to state array */ + ); +char * ntp_setstate (char *); /* pointer to state array */ diff --git a/contrib/ntp/include/ntp_refclock.h b/contrib/ntp/include/ntp_refclock.h index d63f3af38..f92d14cdb 100644 --- a/contrib/ntp/include/ntp_refclock.h +++ b/contrib/ntp/include/ntp_refclock.h @@ -5,44 +5,14 @@ #ifndef NTP_REFCLOCK_H #define NTP_REFCLOCK_H -#include "ntp_types.h" - -#if defined(HAVE_BSD_TTYS) -#include -#endif /* HAVE_BSD_TTYS */ - -#if defined(HAVE_SYSV_TTYS) -#include -#endif /* HAVE_SYSV_TTYS */ - -#if defined(HAVE_TERMIOS) -# ifdef TERMIOS_NEEDS__SVID3 -# define _SVID3 -# endif -# include -# ifdef TERMIOS_NEEDS__SVID3 -# undef _SVID3 -# endif -#endif - #if defined(HAVE_SYS_MODEM_H) #include #endif -#if 0 /* If you need that, include ntp_io.h instead */ -#if defined(STREAM) -#include -#if defined(CLK) /* This is never defined, except perhaps by a system header file */ -#include -#endif /* CLK */ -#endif /* STREAM */ -#endif - +#include "ntp_types.h" +#include "ntp_tty.h" #include "recvbuff.h" -#if !defined(SYSV_TTYS) && !defined(STREAM) & !defined(BSD_TTYS) -#define BSD_TTYS -#endif /* SYSV_TTYS STREAM BSD_TTYS */ #define SAMPLE(x) pp->coderecv = (pp->coderecv + 1) % MAXSTAGE; \ pp->filter[pp->coderecv] = (x); \ @@ -110,7 +80,7 @@ struct refclockstat { double fudgetime1; /* configure fudge time1 */ double fudgetime2; /* configure fudge time2 */ int32 fudgeval1; /* configure fudge value1 */ - int32 fudgeval2; /* configure fudge value2 */ + u_int32 fudgeval2; /* configure fudge value2 */ u_char currentstatus; /* clock status */ u_char lastevent; /* last exception event */ u_char leap; /* leap bits */ @@ -123,15 +93,20 @@ struct refclockstat { */ struct refclockio { struct refclockio *next; /* link to next structure */ - void (*clock_recv) P((struct recvbuf *)); /* completion routine */ - int (*io_input) P((struct recvbuf *)); /* input routine - + void (*clock_recv) (struct recvbuf *); /* completion routine */ + int (*io_input) (struct recvbuf *); /* input routine - to avoid excessive buffer use due to small bursts of refclock input data */ - caddr_t srcclock; /* pointer to clock structure */ - int datalen; /* lenth of data */ - SOCKET fd; /* file descriptor */ + struct peer *srcclock; /* refclock peer */ + int datalen; /* length of data */ + int fd; /* file descriptor */ u_long recvcount; /* count of receive completions */ + int active; /* nonzero when in use */ + +#ifdef HAVE_IO_COMPLETION_PORT + void * device_context; /* device-related data for i/o subsystem */ +#endif }; /* @@ -149,6 +124,10 @@ struct refclockbug { l_fp times[NCLKBUGTIMES]; /* real times */ }; +#ifdef HAVE_IO_COMPLETION_PORT +extern HANDLE WaitableIoEventHandle; +#endif + /* * Structure interface between the reference clock support * ntp_refclock.c and the driver utility routines @@ -159,33 +138,21 @@ struct refclockbug { #define GMT 0 /* I hope nobody sees this */ #define MAXDIAL 60 /* max length of modem dial strings */ -/* - * Line discipline flags. These require line discipline or streams - * modules to be installed/loaded in the kernel. If specified, but not - * installed, the code runs as if unspecified. - */ -#define LDISC_STD 0x00 /* standard */ -#define LDISC_CLK 0x01 /* tty_clk \n intercept */ -#define LDISC_CLKPPS 0x02 /* tty_clk \377 intercept */ -#define LDISC_ACTS 0x04 /* tty_clk #* intercept */ -#define LDISC_CHU 0x08 /* depredated */ -#define LDISC_PPS 0x10 /* ppsclock, ppsapi */ -#define LDISC_RAW 0x20 /* raw binary */ -#define LDISC_ECHO 0x40 /* enable echo */ -#define LDISC_REMOTE 0x80 /* remote mode */ -#define LDISC_7O1 0x100 /* 7-bit, odd parity for Z3801A */ struct refclockproc { - struct refclockio io; /* I/O handler structure */ - caddr_t unitptr; /* pointer to unit structure */ + void * unitptr; /* pointer to unit structure */ + struct refclock * conf; /* refclock_conf[type] */ + struct refclockio io; /* I/O handler structure */ u_char leap; /* leap/synchronization code */ u_char currentstatus; /* clock status */ u_char lastevent; /* last exception event */ u_char type; /* clock type */ const char *clockdesc; /* clock description */ + u_long nextaction; /* local activity timeout */ + void (*action)(struct peer *); /* timeout callback */ char a_lastcode[BMAX]; /* last timecode received */ - u_short lencode; /* length of last timecode */ + int lencode; /* length of last timecode */ int year; /* year of eternity */ int day; /* day of year */ @@ -231,43 +198,42 @@ struct refclockproc { #define NOFLAGS 0 /* flag for null flags */ struct refclock { - int (*clock_start) P((int, struct peer *)); - void (*clock_shutdown) P((int, struct peer *)); - void (*clock_poll) P((int, struct peer *)); - void (*clock_control) P((int, struct refclockstat *, - struct refclockstat *, struct peer *)); - void (*clock_init) P((void)); - void (*clock_buginfo) P((int, struct refclockbug *, struct peer *)); - void (*clock_timer) P((int, struct peer *)); + int (*clock_start) (int, struct peer *); + void (*clock_shutdown) (int, struct peer *); + void (*clock_poll) (int, struct peer *); + void (*clock_control) (int, const struct refclockstat *, + struct refclockstat *, struct peer *); + void (*clock_init) (void); + void (*clock_buginfo) (int, struct refclockbug *, struct peer *); + void (*clock_timer) (int, struct peer *); }; /* * Function prototypes */ -/* - * auxiliary PPS interface (implemented by refclock_atom()) - */ -extern int pps_sample P((l_fp *)); -extern int io_addclock_simple P((struct refclockio *)); -extern int io_addclock P((struct refclockio *)); -extern void io_closeclock P((struct refclockio *)); +extern int io_addclock (struct refclockio *); +extern void io_closeclock (struct refclockio *); #ifdef REFCLOCK -extern void refclock_buginfo P((struct sockaddr_storage *, - struct refclockbug *)); -extern void refclock_control P((struct sockaddr_storage *, - struct refclockstat *, - struct refclockstat *)); -extern int refclock_open P((char *, u_int, u_int)); -extern int refclock_setup P((int, u_int, u_int)); -extern void refclock_timer P((struct peer *)); -extern void refclock_transmit P((struct peer *)); -extern int refclock_ioctl P((int, u_int)); -extern int refclock_process P((struct refclockproc *)); -extern void refclock_process_offset P((struct refclockproc *, l_fp, l_fp, double)); -extern void refclock_report P((struct peer *, int)); -extern int refclock_gtlin P((struct recvbuf *, char *, int, l_fp *)); -extern int refclock_gtraw P((struct recvbuf *, char *, int, l_fp *)); +extern void refclock_buginfo(sockaddr_u *, + struct refclockbug *); +extern void refclock_control(sockaddr_u *, + const struct refclockstat *, + struct refclockstat *); +extern int refclock_open (char *, u_int, u_int); +extern int refclock_setup (int, u_int, u_int); +extern void refclock_timer (struct peer *); +extern void refclock_transmit(struct peer *); +extern int refclock_process(struct refclockproc *); +extern int refclock_process_f(struct refclockproc *, double); +extern void refclock_process_offset(struct refclockproc *, l_fp, + l_fp, double); +extern void refclock_report (struct peer *, int); +extern int refclock_gtlin (struct recvbuf *, char *, int, l_fp *); +extern int refclock_gtraw (struct recvbuf *, char *, int, l_fp *); +extern int indicate_refclock_packet(struct refclockio *, + struct recvbuf *); +extern void process_refclock_packet(struct recvbuf *); #endif /* REFCLOCK */ #endif /* NTP_REFCLOCK_H */ diff --git a/contrib/ntp/include/ntp_request.h b/contrib/ntp/include/ntp_request.h index eb13fadb8..c750b7750 100644 --- a/contrib/ntp/include/ntp_request.h +++ b/contrib/ntp/include/ntp_request.h @@ -2,10 +2,12 @@ * ntp_request.h - definitions for the ntpd remote query facility */ -#ifndef _NTP_REQUEST_H -#define _NTP_REQUEST_H +#ifndef NTP_REQUEST_H +#define NTP_REQUEST_H +#include "stddef.h" #include "ntp_types.h" +#include "recvbuff.h" /* * A mode 7 packet is used exchanging data between an NTP server @@ -67,7 +69,7 @@ * requested wasn't performed. * * 0 - no error - * 1 - incompatable implementation number + * 1 - incompatible implementation number * 2 - unimplemented request code * 3 - format error (wrong data items, data size, packet size etc.) * 4 - no data available (e.g. request for details on unknown peer) @@ -114,12 +116,18 @@ /* * union of raw addresses to save space */ -union addrun -{ +union addrun { struct in6_addr addr6; struct in_addr addr; }; +#define MODE7_PAYLOAD_LIM 176 + +typedef union req_data_u_tag { + u_int32 u32[MODE7_PAYLOAD_LIM / sizeof(u_int32)]; + char data[MODE7_PAYLOAD_LIM]; /* data area (176 byte max) */ +} req_data_u; /* struct conf_peer must fit */ + /* * A request packet. These are almost a fixed length. */ @@ -130,11 +138,10 @@ struct req_pkt { u_char request; /* request number */ u_short err_nitems; /* error code/number of data items */ u_short mbz_itemsize; /* item size */ - char data[MAXFILENAME + 48]; /* data area [32 prev](176 byte max) */ - /* struct conf_peer must fit */ + req_data_u u; /* data area */ l_fp tstamp; /* time stamp, for authentication */ - keyid_t keyid; /* encryption key */ - char mac[MAX_MAC_LEN-sizeof(u_int32)]; /* (optional) 8 byte auth code */ + keyid_t keyid; /* (optional) encryption key */ + char mac[MAX_MAC_LEN-sizeof(keyid_t)]; /* (optional) auth code */ }; /* @@ -143,24 +150,30 @@ struct req_pkt { */ struct req_pkt_tail { l_fp tstamp; /* time stamp, for authentication */ - keyid_t keyid; /* encryption key */ - char mac[MAX_MAC_LEN-sizeof(u_int32)]; /* (optional) 8 byte auth code */ + keyid_t keyid; /* (optional) encryption key */ + char mac[MAX_MAC_LEN-sizeof(keyid_t)]; /* (optional) auth code */ }; -/* - * Input packet lengths. One with the mac, one without. - */ -#define REQ_LEN_HDR 8 /* 4 * u_char + 2 * u_short */ -#define REQ_LEN_MAC (sizeof(struct req_pkt)) -#define REQ_LEN_NOMAC (sizeof(struct req_pkt) - MAX_MAC_LEN) +/* MODE_PRIVATE request packet header length before optional items. */ +#define REQ_LEN_HDR (offsetof(struct req_pkt, u)) +/* MODE_PRIVATE request packet fixed length without MAC. */ +#define REQ_LEN_NOMAC (offsetof(struct req_pkt, keyid)) +/* MODE_PRIVATE req_pkt_tail minimum size (16 octet digest) */ +#define REQ_TAIL_MIN \ + (sizeof(struct req_pkt_tail) - (MAX_MAC_LEN - MAX_MD5_LEN)) /* - * A response packet. The length here is variable, this is a - * maximally sized one. Note that this implementation doesn't + * A MODE_PRIVATE response packet. The length here is variable, this + * is a maximally sized one. Note that this implementation doesn't * authenticate responses. */ -#define RESP_HEADER_SIZE (8) -#define RESP_DATA_SIZE (500) +#define RESP_HEADER_SIZE (offsetof(struct resp_pkt, u)) +#define RESP_DATA_SIZE 500 + +typedef union resp_pkt_u_tag { + char data[RESP_DATA_SIZE]; + u_int32 u32[RESP_DATA_SIZE / sizeof(u_int32)]; +} resp_pkt_u; struct resp_pkt { u_char rm_vn_mode; /* response, more, version, mode */ @@ -169,7 +182,7 @@ struct resp_pkt { u_char request; /* request number */ u_short err_nitems; /* error code/number of data items */ u_short mbz_itemsize; /* item size */ - char data[RESP_DATA_SIZE]; /* data area */ + resp_pkt_u u; /* data area */ }; @@ -177,11 +190,12 @@ struct resp_pkt { * Information error codes */ #define INFO_OKAY 0 -#define INFO_ERR_IMPL 1 /* incompatable implementation */ +#define INFO_ERR_IMPL 1 /* incompatible implementation */ #define INFO_ERR_REQ 2 /* unknown request code */ #define INFO_ERR_FMT 3 /* format error */ #define INFO_ERR_NODATA 4 /* no data for this request */ #define INFO_ERR_AUTH 7 /* authentication failure */ +#define MAX_INFO_ERR INFO_ERR_AUTH /* * Maximum sequence number. @@ -239,7 +253,7 @@ struct resp_pkt { */ /* - * NTPD request codes go here. + * ntpdc -> ntpd request codes go here. */ #define REQ_PEER_LIST 0 /* return list of peers */ #define REQ_PEER_LIST_SUM 1 /* return summary info for all peers */ @@ -381,7 +395,7 @@ struct info_peer { u_int32 pkeyid; /* unused */ u_int32 refid; /* peer.refid */ u_int32 timer; /* peer.timer */ - s_fp rootdelay; /* peer.distance */ + s_fp rootdelay; /* peer.delay */ u_fp rootdispersion; /* peer.dispersion */ l_fp reftime; /* peer.reftime */ l_fp org; /* peer.org */ @@ -465,7 +479,7 @@ struct info_sys { u_char leap; /* system leap bits */ u_char stratum; /* our stratum */ s_char precision; /* local clock precision */ - s_fp rootdelay; /* distance from sync source */ + s_fp rootdelay; /* delay from sync source */ u_fp rootdispersion; /* dispersion from sync source */ u_int32 refid; /* reference ID of sync source */ l_fp reftime; /* system reference time */ @@ -588,7 +602,7 @@ struct conf_peer { u_char ttl; /* time to live (multicast) or refclock mode */ u_short unused1; /* unused */ keyid_t keyid; /* key to use for this association */ - char keystr[MAXFILENAME]; /* public key file name*/ + char keystr[128]; /* public key file name */ u_int v6_flag; /* is this v6 or not */ u_int unused2; /* unused, padding for peeraddr6 */ struct in6_addr peeraddr6; /* ipv6 address to poll */ @@ -665,9 +679,9 @@ struct conf_restrict { * Structure used for returning monitor data */ struct info_monitor_1 { - u_int32 lasttime; /* last packet from this host */ - u_int32 firsttime; /* first time we received a packet */ - u_int32 lastdrop; /* last time we rejected a packet due to client limitation policy */ + u_int32 avg_int; /* avg s between packets from this host */ + u_int32 last_int; /* s since we last received a packet */ + u_int32 restr; /* restrict bits (was named lastdrop) */ u_int32 count; /* count of packets received */ u_int32 addr; /* host address V4 style */ u_int32 daddr; /* destination host address */ @@ -686,9 +700,9 @@ struct info_monitor_1 { * Structure used for returning monitor data */ struct info_monitor { - u_int32 lasttime; /* last packet from this host */ - u_int32 firsttime; /* first time we received a packet */ - u_int32 lastdrop; /* last time we rejected a packet due to client limitation policy */ + u_int32 avg_int; /* avg s between packets from this host */ + u_int32 last_int; /* s since we last received a packet */ + u_int32 restr; /* restrict bits (was named lastdrop) */ u_int32 count; /* count of packets received */ u_int32 addr; /* host address */ u_short port; /* port number of last reception */ @@ -700,7 +714,7 @@ struct info_monitor { }; /* - * Structure used for returning monitor data (old format + * Structure used for returning monitor data (old format) */ struct old_info_monitor { u_int32 lasttime; /* last packet from this host */ @@ -729,9 +743,15 @@ struct reset_flags { #define RESET_FLAG_AUTH 0x20 #define RESET_FLAG_CTL 0x40 -#define RESET_ALLFLAGS \ - (RESET_FLAG_ALLPEERS|RESET_FLAG_IO|RESET_FLAG_SYS \ - |RESET_FLAG_MEM|RESET_FLAG_TIMER|RESET_FLAG_AUTH|RESET_FLAG_CTL) +#define RESET_ALLFLAGS ( \ + RESET_FLAG_ALLPEERS | \ + RESET_FLAG_IO | \ + RESET_FLAG_SYS | \ + RESET_FLAG_MEM | \ + RESET_FLAG_TIMER | \ + RESET_FLAG_AUTH | \ + RESET_FLAG_CTL \ +) /* * Structure used to return information concerning the authentication @@ -820,7 +840,7 @@ struct info_clock { l_fp fudgetime1; l_fp fudgetime2; int32 fudgeval1; - int32 fudgeval2; + u_int32 fudgeval2; }; @@ -831,7 +851,7 @@ struct conf_fudge { u_int32 clockadr; u_int32 which; l_fp fudgetime; - int32 fudgeval_flags; + u_int32 fudgeval_flags; }; #define FUDGE_TIME1 1 @@ -887,26 +907,26 @@ struct info_kernel { * interface statistics */ struct info_if_stats { - union addrun unaddr; /* address */ - union addrun unbcast; /* broadcast */ - union addrun unmask; /* mask */ - u_int32 v6_flag; /* is this v6 */ + union addrun unaddr; /* address */ + union addrun unbcast; /* broadcast */ + union addrun unmask; /* mask */ + u_int32 v6_flag; /* is this v6 */ char name[32]; /* name of interface */ int32 flags; /* interface flags */ int32 last_ttl; /* last TTL specified */ int32 num_mcast; /* No. of IP addresses in multicast socket */ - int32 received; /* number of incoming packets */ + int32 received; /* number of incoming packets */ int32 sent; /* number of outgoing packets */ int32 notsent; /* number of send failures */ - int32 uptime; /* number of seconds this interface was active */ + int32 uptime; /* number of seconds this interface was active */ u_int32 scopeid; /* Scope used for Multicasting */ u_int32 ifindex; /* interface index - from system */ - u_int32 ifnum; /* sequential interface number */ - u_int32 peercnt; /* number of peers referencinf this interface - informational only */ + u_int32 ifnum; /* sequential interface number */ + u_int32 peercnt; /* number of peers referencinf this interface - informational only */ u_short family; /* Address family */ - u_char ignore_packets; /* Specify whether the packet should be ignored */ - u_char action; /* reason the item is listed */ - int32 _filler0; /* pad to a 64 bit size boundary */ + u_char ignore_packets; /* Specify whether the packet should be ignored */ + u_char action; /* reason the item is listed */ + int32 _filler0; /* pad to a 64 bit size boundary */ }; #define IFS_EXISTS 1 /* just exists */ @@ -923,4 +943,10 @@ struct info_dns_assoc { associd_t associd; /* association ID */ char hostname[NTP_MAXHOSTNAME]; /* hostname */ }; + +/* + * function declarations + */ +int get_packet_mode(struct recvbuf *rbufp); /* Return packet mode */ + #endif /* NTP_REQUEST_H */ diff --git a/contrib/ntp/include/ntp_rfc2553.h b/contrib/ntp/include/ntp_rfc2553.h index 662b11894..08ccbc415 100644 --- a/contrib/ntp/include/ntp_rfc2553.h +++ b/contrib/ntp/include/ntp_rfc2553.h @@ -65,47 +65,63 @@ /* * Compatability shims with the rfc2553 API to simplify ntp. */ -#ifndef _NTP_RFC2553_H_ -#define _NTP_RFC2553_H_ - -/* - * Ensure that we include the configuration file before we check - * for IPV6 - */ -#include +#ifndef NTP_RFC2553_H +#define NTP_RFC2553_H #include +#include #include "ntp_types.h" +#include "ntp_malloc.h" + +struct addrinfo *copy_addrinfo_impl(const struct addrinfo * +#ifdef EREALLOC_CALLSITE /* from ntp_malloc.h */ + , + const char *, int +#endif + ); +struct addrinfo *copy_addrinfo_list_impl(const struct addrinfo * +#ifdef EREALLOC_CALLSITE /* from ntp_malloc.h */ + , + const char *, int +#endif + ); +#ifdef EREALLOC_CALLSITE +# define copy_addrinfo(l) \ + copy_addrinfo_impl((l), __FILE__, __LINE__) +# define copy_addrinfo_list(l) \ + copy_addrinfo_list_impl((l), __FILE__, __LINE__) +#else +# define copy_addrinfo(l) copy_addrinfo_impl(l) +# define copy_addrinfo_list(l) copy_addrinfo_list_impl(l) +#endif /* - * Don't include any additional IPv6 definitions - * We are defining our own here. - */ -#define ISC_IPV6_H 1 - - /* * If various macros are not defined we need to define them */ #ifndef AF_INET6 -#define AF_INET6 AF_MAX -#define PF_INET6 AF_INET6 +# define AF_INET6 AF_MAX +# define PF_INET6 AF_INET6 #endif #if !defined(_SS_MAXSIZE) && !defined(_SS_ALIGNSIZE) -#define _SS_MAXSIZE 128 -#define _SS_ALIGNSIZE (sizeof(ntp_uint64_t)) -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR -#define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t)) -#define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t) - \ +# define _SS_MAXSIZE 128 +# define _SS_ALIGNSIZE (sizeof(ntp_uint64_t)) +# ifdef ISC_PLATFORM_HAVESALEN +# define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t)) +# define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(u_char) - sizeof(ntp_u_int8_t) - \ _SS_PAD1SIZE - _SS_ALIGNSIZE) -#else -#define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(short)) -#define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(short) - \ +# else +# define _SS_PAD1SIZE (_SS_ALIGNSIZE - sizeof(short)) +# define _SS_PAD2SIZE (_SS_MAXSIZE - sizeof(short) - \ _SS_PAD1SIZE - _SS_ALIGNSIZE) -#endif /* HAVE_SA_LEN_IN_STRUCT_SOCKADDR */ +# endif /* ISC_PLATFORM_HAVESALEN */ +#endif + +#ifndef INET6_ADDRSTRLEN +# define INET6_ADDRSTRLEN 46 /* max len of IPv6 addr in ascii */ #endif /* @@ -115,7 +131,7 @@ #ifndef HAVE_STRUCT_SOCKADDR_STORAGE struct sockaddr_storage { -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +#ifdef ISC_PLATFORM_HAVESALEN ntp_u_int8_t ss_len; /* address length */ ntp_u_int8_t ss_family; /* address family */ #else @@ -135,7 +151,7 @@ struct sockaddr_storage { /* * Flag values for getaddrinfo() */ -#ifndef AI_NUMERICHOST +#ifndef AI_PASSIVE #define AI_PASSIVE 0x00000001 /* get address to use bind() */ #define AI_CANONNAME 0x00000002 /* fill ai_canonname */ #define AI_NUMERICHOST 0x00000004 /* prevent name resolution */ @@ -144,90 +160,24 @@ struct sockaddr_storage { (AI_PASSIVE | AI_CANONNAME | AI_NUMERICHOST | AI_ADDRCONFIG) #define AI_ADDRCONFIG 0x00000400 /* only if any address is assigned */ -#endif +#endif /* !AI_PASSIVE */ -#ifndef ISC_PLATFORM_HAVEIPV6 -/* - * Definition of some useful macros to handle IP6 addresses - */ -#ifdef ISC_PLATFORM_NEEDIN6ADDRANY -#ifdef SYS_WINNT -#define IN6ADDR_ANY_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }} -#else -#define IN6ADDR_ANY_INIT \ - {{{ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, \ - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }}} -#endif -#endif - - -/* - * IPv6 address - */ -#ifdef SYS_WINNT -#define in6_addr in_addr6 +#ifndef AI_NUMERICHOST /* such as AIX 4.3 */ +# define Z_AI_NUMERICHOST 0 #else - -struct in6_addr { - union { - ntp_u_int8_t __u6_addr8[16]; - ntp_u_int16_t __u6_addr16[8]; - ntp_u_int32_t __u6_addr32[4]; - } __u6_addr; /* 128-bit IP6 address */ -}; - -#define s6_addr __u6_addr.__u6_addr8 -#endif - -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRANY) -extern const struct in6_addr in6addr_any; +# define Z_AI_NUMERICHOST AI_NUMERICHOST #endif -#define SIN6_LEN -#ifndef HAVE_SOCKADDR_IN6 -struct sockaddr_in6 { -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - ntp_u_int8_t sin6_len; /* length of this struct(sa_family_t)*/ - ntp_u_int8_t sin6_family; /* AF_INET6 (sa_family_t) */ +#ifndef AI_NUMERICSERV /* not in RFC 2553 */ +# define Z_AI_NUMERICSERV 0 #else - short sin6_family; /* AF_INET6 (sa_family_t) */ -#endif - ntp_u_int16_t sin6_port; /* Transport layer port # (in_port_t)*/ - ntp_u_int32_t sin6_flowinfo; /* IP6 flow information */ - struct in6_addr sin6_addr; /* IP6 address */ - ntp_u_int32_t sin6_scope_id; /* scope zone index */ -}; +# define Z_AI_NUMERICSERV AI_NUMERICSERV #endif -/* - * Unspecified - */ -#ifndef IN6_IS_ADDR_UNSPECIFIED -#define IN6_IS_ADDR_UNSPECIFIED(a) \ - ((*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[0]) == 0) && \ - (*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[4]) == 0) && \ - (*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[8]) == 0) && \ - (*(const ntp_u_int32_t *)(const void *)(&(a)->s6_addr[12]) == 0)) -#endif -/* - * Multicast - */ -#ifndef IN6_IS_ADDR_MULTICAST -#define IN6_IS_ADDR_MULTICAST(a) ((a)->s6_addr[0] == 0xff) -#endif -/* - * Unicast link / site local. - */ -#ifndef IN6_IS_ADDR_LINKLOCAL -#define IN6_IS_ADDR_LINKLOCAL(a) (\ -(*((u_long *)((a)->s6_addr) ) == 0xfe) && \ -((*((u_long *)((a)->s6_addr) + 1) & 0xc0) == 0x80)) -#endif +#ifndef ISC_PLATFORM_HAVEIPV6 -#ifndef IN6_IS_ADDR_SITELOCAL -#define IN6_IS_ADDR_SITELOCAL(a) (\ -(*((u_long *)((a)->s6_addr) ) == 0xfe) && \ -((*((u_long *)((a)->s6_addr) + 1) & 0xc0) == 0xc0)) +#ifdef SYS_WINNT +# define in6_addr in_addr6 #endif struct addrinfo { @@ -260,12 +210,12 @@ struct addrinfo { #define EAI_MAX 14 -int getaddrinfo P((const char *, const char *, - const struct addrinfo *, struct addrinfo **)); -int getnameinfo P((const struct sockaddr *, u_int, char *, - size_t, char *, size_t, int)); -void freeaddrinfo P((struct addrinfo *)); -char *gai_strerror P((int)); +int getaddrinfo (const char *, const char *, + const struct addrinfo *, struct addrinfo **); +int getnameinfo (const struct sockaddr *, u_int, char *, + size_t, char *, size_t, int); +void freeaddrinfo (struct addrinfo *); +char *gai_strerror (int); /* * Constants for getnameinfo() @@ -287,6 +237,17 @@ char *gai_strerror P((int)); #define NI_WITHSCOPEID 0x00000020 #endif -#endif /* ISC_PLATFORM_HAVEIPV6 */ +#endif /* !ISC_PLATFORM_HAVEIPV6 */ + +/* + * Set up some macros to look for IPv6 and IPv6 multicast + */ + +#if defined(ISC_PLATFORM_HAVEIPV6) && defined(WANT_IPV6) +# define INCLUDE_IPV6_SUPPORT +# if defined(IPV6_JOIN_GROUP) && defined(IPV6_LEAVE_GROUP) +# define INCLUDE_IPV6_MULTICAST_SUPPORT +# endif /* IPV6 Multicast Support */ +#endif /* IPv6 Support */ -#endif /* !_NTP_RFC2553_H_ */ +#endif /* !NTP_RFC2553_H */ diff --git a/contrib/ntp/include/ntp_select.h b/contrib/ntp/include/ntp_select.h index 79c0fc0a5..2c0fbeec9 100644 --- a/contrib/ntp/include/ntp_select.h +++ b/contrib/ntp/include/ntp_select.h @@ -1,35 +1,35 @@ /* * Not all machines define FD_SET in sys/types.h */ -#ifndef _ntp_select_h -#define _ntp_select_h +#ifndef NTP_SELECT_H +#define NTP_SELECT_H /* note: tested by include/l_stdlib.h */ /* Was: (defined(RS6000)||defined(SYS_PTX))&&!defined(_BSD) */ /* Could say: !defined(FD_SET) && defined(HAVE_SYS_SELECT_H) */ +/* except FD_SET can legitimately be a typedef... */ #if defined(HAVE_SYS_SELECT_H) && !defined(_BSD) -#ifndef SYS_VXWORKS -#include -#else -#include -extern int select P((int width, fd_set *pReadFds, fd_set *pWriteFds, - fd_set *pExceptFds, struct timeval *pTimeOut)); - -#endif +# ifndef SYS_VXWORKS +# include +# else +# include +extern int select(int width, fd_set *pReadFds, fd_set *pWriteFds, + fd_set *pExceptFds, struct timeval *pTimeOut); +# endif #endif -#if !defined(FD_SET) && !defined(SYS_WINNT) -#define NFDBITS 32 -#define FD_SETSIZE 32 -#define FD_SET(n, p) ((p)->fds_bits[(n)/NFDBITS] |= (1 << ((n) % NFDBITS))) -#define FD_CLR(n, p) ((p)->fds_bits[(n)/NFDBITS] &= ~(1 << ((n) % NFDBITS))) -#define FD_ISSET(n, p) ((p)->fds_bits[(n)/NFDBITS] & (1 << ((n) % NFDBITS))) -#define FD_ZERO(p) memset((char *)(p), 0, sizeof(*(p))) +#if !defined(FD_SET) +# define NFDBITS 32 +# define FD_SETSIZE 32 +# define FD_SET(n, p) ((p)->fds_bits[(n)/NFDBITS] |= (1 << ((n) % NFDBITS))) +# define FD_CLR(n, p) ((p)->fds_bits[(n)/NFDBITS] &= ~(1 << ((n) % NFDBITS))) +# define FD_ISSET(n, p) ((p)->fds_bits[(n)/NFDBITS] & (1 << ((n) % NFDBITS))) +# define FD_ZERO(p) memset((p), 0, sizeof(*(p))) #endif #if defined(VMS) typedef struct { - unsigned int fds_bits[1]; + unsigned int fds_bits[1]; } fd_set; #endif -#endif /* _ntp_select_h */ +#endif /* NTP_SELECT_H */ diff --git a/contrib/ntp/include/ntp_sprintf.h b/contrib/ntp/include/ntp_sprintf.h deleted file mode 100644 index a456a8925..000000000 --- a/contrib/ntp/include/ntp_sprintf.h +++ /dev/null @@ -1,13 +0,0 @@ -/* - * Handle ancient char* *s*printf*() systems - */ - -#ifdef SPRINTF_CHAR -# define SPRINTF(x) strlen(sprintf/**/x) -# define SNPRINTF(x) strlen(snprintf/**/x) -# define VSNPRINTF(x) strlen(vsnprintf/**/x) -#else -# define SPRINTF(x) ((size_t)sprintf x) -# define SNPRINTF(x) ((size_t)snprintf x) -# define VSNPRINTF(x) ((size_t)vsnprintf x) -#endif diff --git a/contrib/ntp/include/ntp_stdlib.h b/contrib/ntp/include/ntp_stdlib.h index c389d1ecc..a2e62dabe 100644 --- a/contrib/ntp/include/ntp_stdlib.h +++ b/contrib/ntp/include/ntp_stdlib.h @@ -1,117 +1,184 @@ /* * ntp_stdlib.h - Prototypes for NTP lib. */ +#ifndef NTP_STDLIB_H +#define NTP_STDLIB_H + #include +#ifdef HAVE_SYS_SOCKET_H #include -#include "ntp_rfc2553.h" +#endif -#include "ntp_types.h" -#include "ntp_string.h" +#include "declcond.h" /* ntpd uses ntpd/declcond.h, others include/ */ #include "l_stdlib.h" +#include "ntp_net.h" +#include "ntp_debug.h" +#include "ntp_malloc.h" +#include "ntp_string.h" +#include "ntp_syslog.h" + +#ifdef __GNUC__ +#define NTP_PRINTF(fmt, args) __attribute__((__format__(__printf__, fmt, args))) +#else +#define NTP_PRINTF(fmt, args) +#endif + +extern int mprintf(const char *, ...) NTP_PRINTF(1, 2); +extern int mfprintf(FILE *, const char *, ...) NTP_PRINTF(2, 3); +extern int mvfprintf(FILE *, const char *, va_list) NTP_PRINTF(2, 0); +extern int mvsnprintf(char *, size_t, const char *, va_list) + NTP_PRINTF(3, 0); +extern int msnprintf(char *, size_t, const char *, ...) + NTP_PRINTF(3, 4); +extern void msyslog(int, const char *, ...) NTP_PRINTF(2, 3); +extern void mvsyslog(int, const char *, va_list) NTP_PRINTF(2, 0); +extern void init_logging (const char *, u_int32, int); +extern int change_logfile (const char *, int); +extern void setup_logfile (const char *); +#ifndef errno_to_str +extern void errno_to_str(int, char *, size_t); +#endif /* - * Handle gcc __attribute__ if available. + * When building without OpenSSL, use a few macros of theirs to + * minimize source differences in NTP. */ -#ifndef __attribute__ -/* This feature is available in gcc versions 2.5 and later. */ -# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || (defined(__STRICT_ANSI__)) -# define __attribute__(Spec) /* empty */ -# endif -/* The __-protected variants of `format' and `printf' attributes - are accepted by gcc versions 2.6.4 (effectively 2.7) and later. */ -# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7) -# define __format__ format -# define __printf__ printf -# endif +#ifndef OPENSSL +#define NID_md5 4 /* from openssl/objects.h */ +/* from openssl/evp.h */ +#define EVP_MAX_MD_SIZE 64 /* longest known is SHA512 */ #endif -#if defined(__STDC__) || defined(HAVE_STDARG_H) -# include -extern void msyslog P((int, const char *, ...)) - __attribute__((__format__(__printf__, 2, 3))); -extern void netsyslog P((int, const char *, ...)) - __attribute__((__format__(__printf__, 2, 3))); +#define SAVE_ERRNO(stmt) \ + { \ + int preserved_errno; \ + \ + preserved_errno = socket_errno(); \ + { \ + stmt \ + } \ + errno = preserved_errno; \ + } + +typedef void (*ctrl_c_fn)(void); + +/* authkeys.c */ +extern void auth_delkeys (void); +extern int auth_havekey (keyid_t); +extern int authdecrypt (keyid_t, u_int32 *, int, int); +extern int authencrypt (keyid_t, u_int32 *, int); +extern int authhavekey (keyid_t); +extern int authistrusted (keyid_t); +extern int authreadkeys (const char *); +extern void authtrust (keyid_t, u_long); +extern int authusekey (keyid_t, int, const u_char *); + +/* + * Based on the NTP timestamp, calculate the NTP timestamp of + * the corresponding calendar unit. Use the pivot time to unfold + * the NTP timestamp properly, or the current system time if the + * pivot pointer is NULL. + */ +extern u_int32 calyearstart (u_int32 ntptime, const time_t *pivot); +extern u_int32 calmonthstart (u_int32 ntptime, const time_t *pivot); +extern u_int32 calweekstart (u_int32 ntptime, const time_t *pivot); +extern u_int32 caldaystart (u_int32 ntptime, const time_t *pivot); + +extern const char *clockname (int); +extern int clocktime (int, int, int, int, int, u_int32, u_long *, u_int32 *); +extern int ntp_getopt (int, char **, const char *); +extern void init_auth (void); +extern void init_lib (void); +extern struct savekey *auth_findkey (keyid_t); +extern void auth_moremem (int); +extern void auth_prealloc_symkeys(int); +extern int ymd2yd (int, int, int); + +/* a_md5encrypt.c */ +extern int MD5authdecrypt (int, u_char *, u_int32 *, int, int); +extern int MD5authencrypt (int, u_char *, u_int32 *, int); +extern void MD5auth_setkey (keyid_t, int, const u_char *, size_t); +extern u_int32 addr2refid (sockaddr_u *); + +/* emalloc.c */ +#ifndef EREALLOC_CALLSITE /* ntp_malloc.h defines */ +extern void * ereallocz (void *, size_t, size_t, int); +extern void * oreallocarray (void *optr, size_t nmemb, size_t size); +#define erealloczsite(p, n, o, z, f, l) ereallocz((p), (n), (o), (z)) +#define emalloc(n) ereallocz(NULL, (n), 0, FALSE) +#define emalloc_zero(c) ereallocz(NULL, (c), 0, TRUE) +#define erealloc(p, c) ereallocz((p), (c), 0, FALSE) +#define erealloc_zero(p, n, o) ereallocz((p), (n), (o), TRUE) +#define ereallocarray(p, n, s) oreallocarray((p), (n), (s)) +#define eallocarray(n, s) oreallocarray(NULL, (n), (s)) +extern char * estrdup_impl(const char *); +#define estrdup(s) estrdup_impl(s) #else -# include -extern void msyslog P(()); -extern void netsyslog P(()); +extern void * ereallocz (void *, size_t, size_t, int, + const char *, int); +extern void * oreallocarray (void *optr, size_t nmemb, size_t size, + const char *, int); +#define erealloczsite ereallocz +#define emalloc(c) ereallocz(NULL, (c), 0, FALSE, \ + __FILE__, __LINE__) +#define emalloc_zero(c) ereallocz(NULL, (c), 0, TRUE, \ + __FILE__, __LINE__) +#define erealloc(p, c) ereallocz((p), (c), 0, FALSE, \ + __FILE__, __LINE__) +#define erealloc_zero(p, n, o) ereallocz((p), (n), (o), TRUE, \ + __FILE__, __LINE__) +#define ereallocarray(p, n, s) oreallocarray((p), (n), (s), \ + __FILE__, __LINE__) +#define eallocarray(n, s) oreallocarray(NULL, (n), (s), \ + __FILE__, __LINE__) +extern char * estrdup_impl(const char *, const char *, int); +#define estrdup(s) estrdup_impl((s), __FILE__, __LINE__) #endif -extern void auth_delkeys P((void)); -extern int auth_havekey P((keyid_t)); -extern int authdecrypt P((keyid_t, u_int32 *, int, int)); -extern int authencrypt P((keyid_t, u_int32 *, int)); -extern int authhavekey P((keyid_t)); -extern int authistrusted P((keyid_t)); -extern int authreadkeys P((const char *)); -extern void authtrust P((keyid_t, u_long)); -extern int authusekey P((keyid_t, int, const u_char *)); - -extern u_long calyearstart P((u_long)); -extern const char *clockname P((int)); -extern int clocktime P((int, int, int, int, int, u_long, u_long *, u_int32 *)); -#if defined SYS_WINNT && defined DEBUG -# define emalloc(_c) debug_emalloc(_c, __FILE__, __LINE__) -extern void * debug_emalloc P((u_int, char *, int)); -#else -extern void * emalloc P((u_int)); + +extern int atoint (const char *, long *); +extern int atouint (const char *, u_long *); +extern int hextoint (const char *, u_long *); +extern const char * humanlogtime (void); +extern const char * humantime (time_t); +extern char * mfptoa (u_int32, u_int32, short); +extern char * mfptoms (u_int32, u_int32, short); +extern const char * modetoa (size_t); +extern const char * eventstr (int); +extern const char * ceventstr (int); +extern const char * res_match_flags(u_short); +extern const char * res_access_flags(u_short); +#ifdef KERNEL_PLL +extern const char * k_st_flags (u_int32); #endif -extern int ntp_getopt P((int, char **, const char *)); -extern void init_auth P((void)); -extern void init_lib P((void)); -extern struct savekey *auth_findkey P((keyid_t)); -extern int auth_moremem P((void)); -extern int ymd2yd P((int, int, int)); - -extern int MD5authdecrypt P((u_char *, u_int32 *, int, int)); -extern int MD5authencrypt P((u_char *, u_int32 *, int)); -extern void MD5auth_setkey P((keyid_t, const u_char *, const int)); -extern u_int32 addr2refid P((struct sockaddr_storage *)); - -extern int atoint P((const char *, long *)); -extern int atouint P((const char *, u_long *)); -extern int hextoint P((const char *, u_long *)); -extern char * humandate P((u_long)); -extern char * humanlogtime P((void)); -extern char * inttoa P((long)); -extern char * mfptoa P((u_long, u_long, short)); -extern char * mfptoms P((u_long, u_long, short)); -extern const char * modetoa P((int)); -extern const char * eventstr P((int)); -extern const char * ceventstr P((int)); -extern char * statustoa P((int, int)); -extern const char * sysstatstr P((int)); -extern const char * peerstatstr P((int)); -extern const char * clockstatstr P((int)); -extern struct sockaddr_storage* netof P((struct sockaddr_storage*)); -extern char * numtoa P((u_int32)); -extern char * numtohost P((u_int32)); -extern char * socktoa P((struct sockaddr_storage *)); -extern char * socktohost P((struct sockaddr_storage *)); -extern int octtoint P((const char *, u_long *)); -extern u_long ranp2 P((int)); -extern char * refnumtoa P((struct sockaddr_storage *)); -extern int tsftomsu P((u_long, int)); -extern char * uinttoa P((u_long)); - -extern int decodenetnum P((const char *, struct sockaddr_storage *)); - -extern const char * FindConfig P((const char *)); - -extern void signal_no_reset P((int, RETSIGTYPE (*func)(int))); - -extern void getauthkeys P((const char *)); -extern void auth_agekeys P((void)); -extern void rereadkeys P((void)); +extern char * statustoa (int, int); +extern sockaddr_u * netof (sockaddr_u *); +extern char * numtoa (u_int32); +extern char * numtohost (u_int32); +extern const char * socktoa (const sockaddr_u *); +extern const char * sockporttoa(const sockaddr_u *); +extern u_short sock_hash (const sockaddr_u *); +extern int sockaddr_masktoprefixlen(const sockaddr_u *); +extern const char * socktohost (const sockaddr_u *); +extern int octtoint (const char *, u_long *); +extern u_long ranp2 (int); +extern const char *refnumtoa (sockaddr_u *); +extern const char *refid_str (u_int32, int); -/* - * Variable declarations for libntp. - */ +extern int decodenetnum (const char *, sockaddr_u *); + +extern const char * FindConfig (const char *); + +extern void signal_no_reset (int, RETSIGTYPE (*func)(int)); +extern void set_ctrl_c_hook (ctrl_c_fn); + +extern void getauthkeys (const char *); +extern void auth_agekeys (void); +extern void rereadkeys (void); /* - * Defined by any program. + * Variable declarations for libntp. */ -extern volatile int debug; /* debugging flag */ /* authkeys.c */ extern u_long authkeynotfound; /* keys not found */ @@ -128,23 +195,83 @@ extern int authnumfreekeys; * The key cache. We cache the last key we looked at here. */ extern keyid_t cache_keyid; /* key identifier */ -extern u_char * cache_key; /* key pointer */ -extern u_int cache_keylen; /* key length */ +extern int cache_type; /* key type */ +extern u_char * cache_secret; /* secret */ +extern u_short cache_secretsize; /* secret octets */ +extern u_short cache_flags; /* KEY_ bit flags */ /* getopt.c */ extern char * ntp_optarg; /* global argument pointer */ extern int ntp_optind; /* global argv index */ +/* lib_strbuf.c */ +extern int ipv4_works; +extern int ipv6_works; + /* machines.c */ -extern const char *set_tod_using; +typedef void (*pset_tod_using)(const char *); +extern pset_tod_using set_tod_using; + +/* ssl_init.c */ +#ifdef OPENSSL +extern void ssl_init (void); +extern void ssl_check_version (void); +extern int ssl_init_done; +#define INIT_SSL() \ + do { \ + if (!ssl_init_done) \ + ssl_init(); \ + } while (0) +#else /* !OPENSSL follows */ +#define INIT_SSL() do {} while (0) +#endif +extern int keytype_from_text (const char *, size_t *); +extern const char *keytype_name (int); +extern char * getpass_keytype (int); + +/* strl-obsd.c */ +#ifndef HAVE_STRLCPY /* + */ +/* + * Copy src to string dst of size siz. At most siz-1 characters + * will be copied. Always NUL terminates (unless siz == 0). + * Returns strlen(src); if retval >= siz, truncation occurred. + */ +extern size_t strlcpy(char *dst, const char *src, size_t siz); +#endif +#ifndef HAVE_STRLCAT /* + */ +/* + * Appends src to string dst of size siz (unlike strncat, siz is the + * full size of dst, not space left). At most siz-1 characters + * will be copied. Always NUL terminates (unless siz <= strlen(dst)). + * Returns strlen(src) + MIN(siz, strlen(initial dst)). + * If retval >= siz, truncation occurred. + */ +extern size_t strlcat(char *dst, const char *src, size_t siz); +#endif + + -/* mexit.c */ -#if defined SYS_WINNT || defined SYS_CYGWIN32 -extern HANDLE hServDoneEvent; +/* lib/isc/win32/strerror.c + * + * To minimize Windows-specific changes to the rest of the NTP code, + * particularly reference clocks, we hijack calls to strerror() to deal + * with our mixture of error codes from the C runtime (open, write) + * and Windows (sockets, serial ports). This is an ugly hack because + * both use the lowest values differently, but particularly for ntpd, + * it's not a problem. + */ +#ifdef NTP_REDEFINE_STRERROR +#define strerror(e) ntp_strerror(e) +extern char * ntp_strerror (int e); #endif /* systime.c */ -extern double sys_tick; /* adjtime() resolution */ +extern double sys_tick; /* tick size or time to read */ +extern double measured_tick; /* non-overridable sys_tick */ +extern double sys_fuzz; /* min clock read latency */ +extern int trunc_os_clock; /* sys_tick > measured_tick */ /* version.c */ extern const char *Version; /* version declaration */ + +#endif /* NTP_STDLIB_H */ diff --git a/contrib/ntp/include/ntp_string.h b/contrib/ntp/include/ntp_string.h index f7f0092ae..9b62ec2d9 100644 --- a/contrib/ntp/include/ntp_string.h +++ b/contrib/ntp/include/ntp_string.h @@ -1,13 +1,9 @@ /* - * Define string ops: strchr strrchr memcmp memmove memset + * Define string ops: strchr strrchr memcmp memmove memset */ -#ifndef _ntp_string_h -#define _ntp_string_h - -#ifdef HAVE_CONFIG_H -#include -#endif +#ifndef NTP_STRING_H +#define NTP_STRING_H #ifdef HAVE_MEMORY_H # include @@ -21,28 +17,21 @@ # include #endif -#ifndef STDC_HEADERS -# ifndef HAVE_STRCHR -# include -# define strchr index -# define strrchr rindex -# endif -# ifndef __GNUC__ -char *strchr(), *strrchr(); -# endif -# ifndef HAVE_MEMCPY -# define NTP_NEED_BOPS -# endif -#endif /* STDC_HEADERS */ - #ifdef NTP_NEED_BOPS -# define memcmp(a,b,c) bcmp(a,b,(int)c) -# define memmove(t,f,c) bcopy(f,t,(int)c) -# define memcpy(t,f,c) bcopy(f,t,(int)c) -# define memset(a,x,c) if (x == 0x00) bzero(a,(int)c); else ntp_memset((char*)a,x,c) -void ntp_memset P((char *, int, int)); +#ifdef HAVE_STRINGS_H +# include /* bcmp, bcopy, bzero */ +#endif + +void ntp_memset (char *, int, int); +#define memcmp(a, b, c) bcmp(a, b, (int)(c)) +#define memmove(t, f, c) bcopy(f, t, (int)(c)) +#define memcpy(t, f, c) bcopy(f, t, (int)(c)) +#define memset(a, x, c) if (0 == (x)) \ + bzero(a, (int)(c)); \ + else \ + ntp_memset((char *)(a), x, c) #endif /* NTP_NEED_BOPS */ -#endif /* _ntp_string_h */ +#endif /* NTP_STRING_H */ diff --git a/contrib/ntp/include/ntp_syscall.h b/contrib/ntp/include/ntp_syscall.h index 521e753f6..d1ce03ea9 100644 --- a/contrib/ntp/include/ntp_syscall.h +++ b/contrib/ntp/include/ntp_syscall.h @@ -6,24 +6,28 @@ #ifndef NTP_SYSCALL_H #define NTP_SYSCALL_H -#ifdef HAVE_CONFIG_H -#include -#endif - #ifdef HAVE_SYS_TIMEX_H # include #endif #ifndef NTP_SYSCALLS_LIBC -#ifdef NTP_SYSCALLS_STD -# define ntp_adjtime(t) syscall(SYS_ntp_adjtime, (t)) -# define ntp_gettime(t) syscall(SYS_ntp_gettime, (t)) -#else /* !NTP_SYSCALLS_STD */ -# ifdef HAVE___ADJTIMEX -extern int __adjtimex P((struct timex *)); - -# define ntp_adjtime(t) __adjtimex((t)) +# ifdef NTP_SYSCALLS_STD +# define ntp_adjtime(t) syscall(SYS_ntp_adjtime, (t)) +# define ntp_gettime(t) syscall(SYS_ntp_gettime, (t)) +# else /* !NTP_SYSCALLS_STD */ +# ifdef HAVE_NTP_ADJTIME +extern int ntp_adjtime (struct timex *); + +# ifndef HAVE_STRUCT_NTPTIMEVAL +struct ntptimeval +{ + struct timeval time; /* current time (ro) */ + long int maxerror; /* maximum error (us) (ro) */ + long int esterror; /* estimated error (us) (ro) */ +}; +# endif +# ifndef HAVE_NTP_GETTIME static inline int ntp_gettime( struct ntptimeval *ntv @@ -32,24 +36,21 @@ ntp_gettime( struct timex tntx; int result; - tntx.modes = 0; - result = __adjtimex (&tntx); + ZERO(tntx); + result = ntp_adjtime(&tntx); ntv->time = tntx.time; ntv->maxerror = tntx.maxerror; ntv->esterror = tntx.esterror; -#ifdef NTP_API -# if NTP_API > 3 +# ifdef NTP_API +# if NTP_API > 3 ntv->tai = tntx.tai; -# endif -#endif - return(result); +# endif +# endif + return result; } -# else /* !HAVE__ADJTIMEX */ -# ifdef HAVE___NTP_GETTIME -# define ntp_gettime(t) __ntp_gettime((t)) -# endif -# endif /* !HAVE_ADJTIMEX */ -#endif /* !NTP_SYSCALLS_STD */ -#endif /* !NTP_SYSCALLS_LIBC */ +# endif /* !HAVE_NTP_GETTIME */ +# endif /* !HAVE_NTP_ADJTIME */ +# endif /* !NTP_SYSCALLS_STD */ +#endif /* !NTP_SYSCALLS_LIBC */ -#endif /* NTP_SYSCALL_H */ +#endif /* NTP_SYSCALL_H */ diff --git a/contrib/ntp/include/ntp_syslog.h b/contrib/ntp/include/ntp_syslog.h index 38021e251..ecc634679 100644 --- a/contrib/ntp/include/ntp_syslog.h +++ b/contrib/ntp/include/ntp_syslog.h @@ -5,17 +5,26 @@ #ifndef NTP_SYSLOG_H #define NTP_SYSLOG_H -# ifdef VMS +#include /* u_int32 type */ + +#ifdef VMS extern void msyslog(); -# else -# ifndef SYS_VXWORKS -# include -# endif -# endif /* VMS */ -# include +extern void mvsyslog(); +#else +# ifndef SYS_VXWORKS +# include +# endif +#endif /* VMS */ +#include -extern int syslogit; -extern FILE *syslog_file; +extern int syslogit; +extern int msyslog_term; /* duplicate to stdout/err */ +extern int msyslog_term_pid; +extern int msyslog_include_timestamp; +extern FILE * syslog_file; /* if syslogit is FALSE, log to + this file and not syslog */ +extern char * syslog_fname; +extern char * syslog_abs_fname; #if defined(VMS) || defined (SYS_VXWORKS) #define LOG_EMERG 0 /* system is unusable */ @@ -37,34 +46,41 @@ extern FILE *syslog_file; #define NLOG_STATIST 0x00000008 #define NLOG_OSYS 0 /* offset for system flags */ -#define NLOG_SYSMASK 0x0000000F /* system log events */ +#define NLOG_SYSMASK 0x0000000F /* system log events */ #define NLOG_SYSINFO 0x00000001 /* system info log events */ #define NLOG_SYSEVENT 0x00000002 /* system events */ #define NLOG_SYSSTATUS 0x00000004 /* system status (sync/unsync) */ #define NLOG_SYSSTATIST 0x00000008 /* system statistics output */ #define NLOG_OPEER 4 /* offset for peer flags */ -#define NLOG_PEERMASK 0x000000F0 /* peer log events */ +#define NLOG_PEERMASK 0x000000F0 /* peer log events */ #define NLOG_PEERINFO 0x00000010 /* peer info log events */ #define NLOG_PEEREVENT 0x00000020 /* peer events */ #define NLOG_PEERSTATUS 0x00000040 /* peer status (sync/unsync) */ #define NLOG_PEERSTATIST 0x00000080 /* peer statistics output */ #define NLOG_OCLOCK 8 /* offset for clock flags */ -#define NLOG_CLOCKMASK 0x00000F00 /* clock log events */ +#define NLOG_CLOCKMASK 0x00000F00 /* clock log events */ #define NLOG_CLOCKINFO 0x00000100 /* clock info log events */ #define NLOG_CLOCKEVENT 0x00000200 /* clock events */ #define NLOG_CLOCKSTATUS 0x00000400 /* clock status (sync/unsync) */ #define NLOG_CLOCKSTATIST 0x00000800 /* clock statistics output */ #define NLOG_OSYNC 12 /* offset for sync flags */ -#define NLOG_SYNCMASK 0x0000F000 /* sync log events */ +#define NLOG_SYNCMASK 0x0000F000 /* sync log events */ #define NLOG_SYNCINFO 0x00001000 /* sync info log events */ #define NLOG_SYNCEVENT 0x00002000 /* sync events */ #define NLOG_SYNCSTATUS 0x00004000 /* sync status (sync/unsync) */ #define NLOG_SYNCSTATIST 0x00008000 /* sync statistics output */ -extern unsigned long ntp_syslogmask; -#define NLOG(_X_) if (ntp_syslogmask & (_X_)) +extern u_int32 ntp_syslogmask; + +#define NLOG(bits) if (ntp_syslogmask & (bits)) + +#define LOGIF(nlog_suffix, msl_args) \ +do { \ + NLOG(NLOG_##nlog_suffix) /* like "if (...) */ \ + msyslog msl_args; \ +} while (FALSE) #endif /* NTP_SYSLOG_H */ diff --git a/contrib/ntp/include/ntp_tty.h b/contrib/ntp/include/ntp_tty.h index 983311923..6dc48b6c7 100644 --- a/contrib/ntp/include/ntp_tty.h +++ b/contrib/ntp/include/ntp_tty.h @@ -1,10 +1,31 @@ /* * ntp_tty.h - header file for serial lines handling */ - #ifndef NTP_TTY_H #define NTP_TTY_H +/* + * use only one tty model - no use in initialising + * a tty in three ways + * HAVE_TERMIOS is preferred over HAVE_SYSV_TTYS over HAVE_BSD_TTYS + */ + +#if defined(HAVE_TERMIOS_H) || defined(HAVE_SYS_TERMIOS_H) +# define HAVE_TERMIOS +#elif defined(HAVE_TERMIO_H) +# define HAVE_SYSV_TTYS +#elif defined(HAVE_SGTTY_H) +# define HAVE_BSD_TTYS +#endif + +#if !defined(VMS) && !defined(SYS_VXWORKS) +# if !defined(HAVE_SYSV_TTYS) \ + && !defined(HAVE_BSD_TTYS) \ + && !defined(HAVE_TERMIOS) +#include "ERROR: no tty type defined!" +# endif +#endif /* !VMS && !SYS_VXWORKS*/ + #if defined(HAVE_BSD_TTYS) #include #define TTY struct sgttyb @@ -34,22 +55,49 @@ #endif /* HAVE_SYSV_TTYS */ #if defined(HAVE_TERMIOS) -# ifdef TERMIOS_NEEDS__SVID3 -# define _SVID3 -# endif -# include -# ifdef TERMIOS_NEEDS__SVID3 -# undef _SVID3 +# if defined(HAVE_TERMIOS_H) +# ifdef TERMIOS_NEEDS__SVID3 +# define _SVID3 +# endif +# include +# ifdef TERMIOS_NEEDS__SVID3 +# undef _SVID3 +# endif +# elif defined(HAVE_SYS_TERMIOS_H) +# include # endif -#define TTY struct termios +# define TTY struct termios #endif #if defined(HAVE_SYS_MODEM_H) #include #endif -#if !defined(SYSV_TTYS) && !defined(STREAM) & !defined(BSD_TTYS) -#define BSD_TTYS -#endif /* SYSV_TTYS STREAM BSD_TTYS */ +/* + * Line discipline flags. The depredated ones required line discipline + * or streams modules to be installed/loaded in the kernel and are now + * ignored. Leave the LDISC_CLK and other deprecated symbols defined + * until 2013 or 2014 to avoid complicating the use of newer drivers on + * older ntpd, which is often as easy as dropping in the refclock *.c. + */ +#define LDISC_STD 0x000 /* standard */ +#define LDISC_CLK 0x001 /* depredated tty_clk \n */ +#define LDISC_CLKPPS 0x002 /* depredated tty_clk \377 */ +#define LDISC_ACTS 0x004 /* depredated tty_clk #* */ +#define LDISC_CHU 0x008 /* depredated */ +#define LDISC_PPS 0x010 /* depredated */ +#define LDISC_RAW 0x020 /* raw binary */ +#define LDISC_ECHO 0x040 /* enable echo */ +#define LDISC_REMOTE 0x080 /* remote mode */ +#define LDISC_7O1 0x100 /* 7-bit, odd parity for Z3801A */ + +/* function prototypes for ntp_tty.c */ +#if !defined(SYS_VXWORKS) && !defined(SYS_WINNT) +# if defined(HAVE_TERMIOS) || defined(HAVE_SYSV_TTYS) || \ + defined(HAVE_BSD_TTYS) +extern int ntp_tty_setup(int, u_int, u_int); +extern int ntp_tty_ioctl(int, u_int); +# endif +#endif #endif /* NTP_TTY_H */ diff --git a/contrib/ntp/include/ntp_types.h b/contrib/ntp/include/ntp_types.h index 0b575c8c6..a947f3057 100644 --- a/contrib/ntp/include/ntp_types.h +++ b/contrib/ntp/include/ntp_types.h @@ -1,14 +1,39 @@ /* * ntp_types.h - defines how int32 and u_int32 are treated. + * + * New style: Make sure C99 fixed width integer types are available: + * intN_t and uintN_t + + * Old style: defines how int32 and u_int32 are treated. * For 64 bit systems like the DEC Alpha, they have to be defined * as int and u_int. * For 32 bit systems, define them as long and u_long */ +#ifndef NTP_TYPES_H +#define NTP_TYPES_H + #include +#if defined(HAVE_INTTYPES_H) +# include +#endif +#if defined(HAVE_STDINT_H) +# include +#endif + +/* Bug 2813 */ +#ifdef HAVE_LIMITS_H +# include +#endif + #include "ntp_machine.h" -#ifndef _NTP_TYPES_ -#define _NTP_TYPES_ + +#ifndef TRUE +# define TRUE 1 +#endif +#ifndef FALSE +# define FALSE 0 +#endif /* * This is another naming conflict. @@ -23,15 +48,19 @@ #endif /* - * Set up for prototyping + * used to quiet compiler warnings + */ +#ifndef UNUSED_ARG +#define UNUSED_ARG(arg) ((void)(arg)) +#endif +#ifndef UNUSED_LOCAL +#define UNUSED_LOCAL(arg) ((void)(arg)) +#endif + +/* + * COUNTOF(array) - size of array in elements */ -#ifndef P -#if defined(__STDC__) || defined(HAVE_PROTOTYPES) -#define P(x) x -#else /* not __STDC__ and not HAVE_PROTOTYPES */ -#define P(x) () -#endif /* not __STDC__ and HAVE_PROTOTYPES */ -#endif /* P */ +#define COUNTOF(arr) (sizeof(arr) / sizeof((arr)[0])) /* * VMS DECC (v4.1), {u_char,u_short,u_long} are only in SOCKET.H, @@ -40,41 +69,226 @@ #if defined(VMS) #include typedef unsigned int u_int; -/* - * Note: VMS DECC has long == int (even on __alpha), - * so the distinction below doesn't matter - */ #endif /* VMS */ -#if (SIZEOF_INT == 4) -# ifndef int32 -# define int32 int +#ifdef HAVE_UINT32_T +# ifndef HAVE_INT32 + typedef int32_t int32; # endif -# ifndef u_int32 -# define u_int32 unsigned int +# ifndef HAVE_U_INT32 + typedef uint32_t u_int32; +# if defined(UINT32_MAX) && !defined(U_INT32_MAX) +# define U_INT32_MAX UINT32_MAX +# endif # endif -#else /* not sizeof(int) == 4 */ +#elif (SIZEOF_INT == 4) +# if !defined(HAVE_INT32) && !defined(int32) + typedef int int32; +# ifndef INT32_MIN +# define INT32_MIN INT_MIN +# endif +# ifndef INT32_MAX +# define INT32_MAX INT_MAX +# endif +# endif +# if !defined(HAVE_U_INT32) && !defined(u_int32) + typedef unsigned u_int32; +# if defined(UINT_MAX) && !defined(U_INT32_MAX) +# define U_INT32_MAX UINT_MAX +# endif +# endif +#else /* SIZEOF_INT != 4 */ # if (SIZEOF_LONG == 4) -# else /* not sizeof(long) == 4 */ -# ifndef int32 -# define int32 long +# if !defined(HAVE_INT32) && !defined(int32) + typedef long int32; +# ifndef INT32_MIN +# define INT32_MIN LONG_MIN +# endif +# ifndef INT32_MAX +# define INT32_MAX LONG_MAX +# endif # endif -# ifndef u_int32 -# define u_int32 unsigned long +# if !defined(HAVE_U_INT32) && !defined(u_int32) + typedef unsigned long u_int32; +# if defined(ULONG_MAX) && !defined(U_INT32_MAX) +# define U_INT32_MAX ULONG_MAX +# endif # endif -# endif /* not sizeof(long) == 4 */ -# include "Bletch: what's 32 bits on this machine?" -#endif /* not sizeof(int) == 4 */ +# else /* SIZEOF_LONG != 4 */ +# include "Bletch: what's 32 bits on this machine?" +# endif +#endif /* !HAVE_UINT32_T && SIZEOF_INT != 4 */ + +#ifndef U_INT32_MAX +# define U_INT32_MAX 0xffffffff +#endif + + +/* + * Ugly dance to find out if we have 64bit integer type. + */ +#if !defined(HAVE_INT64) + +/* assume best for now, fix if frustrated later. */ +# define HAVE_INT64 +# define HAVE_U_INT64 + +/* now check the cascade. Feel free to add things. */ +# ifdef INT64_MAX + +typedef int64_t int64; +typedef uint64_t u_int64; + +# elif SIZEOF_LONG == 8 -typedef u_char ntp_u_int8_t; -typedef u_short ntp_u_int16_t; -typedef u_int32 ntp_u_int32_t; +typedef long int64; +typedef unsigned long u_int64; + +# elif SIZEOF_LONG_LONG == 8 + +typedef long long int64; +typedef unsigned long long u_int64; + +# else + +/* no 64bit scalar, give it up. */ +# undef HAVE_INT64 +# undef HAVE_U_INT64 + +# endif + +#endif + +/* + * and here the trouble starts: We need a representation with more than + * 64 bits. If a scalar of that size is not available, we need a struct + * that holds the value in split representation. + * + * To ease the usage a bit, we alwys use a union that is in processor + * byte order and might or might not contain a 64bit scalar. + */ + +#if SIZEOF_SHORT != 2 +# error short is not 2 bytes -- what is 16 bit integer on this target? +#endif + +typedef union { +# ifdef WORDS_BIGENDIAN + struct { + int16_t hh; uint16_t hl; uint16_t lh; uint16_t ll; + } w_s; + struct { + uint16_t hh; uint16_t hl; uint16_t lh; uint16_t ll; + } W_s; + struct { + int32 hi; u_int32 lo; + } d_s; + struct { + u_int32 hi; u_int32 lo; + } D_s; +# else + struct { + uint16_t ll; uint16_t lh; uint16_t hl; int16_t hh; + } w_s; + struct { + uint16_t ll; uint16_t lh; uint16_t hl; uint16_t hh; + } W_s; + struct { + u_int32 lo; int32 hi; + } d_s; + struct { + u_int32 lo; u_int32 hi; + } D_s; +# endif + +# ifdef HAVE_INT64 + int64 q_s; /* signed quad scalar */ + u_int64 Q_s; /* unsigned quad scalar */ +# endif +} vint64; /* variant int 64 */ + + +typedef uint8_t ntp_u_int8_t; +typedef uint16_t ntp_u_int16_t; +typedef uint32_t ntp_u_int32_t; typedef struct ntp_uint64_t { u_int32 val[2]; } ntp_uint64_t; -typedef unsigned short associd_t; /* association ID */ +typedef uint16_t associd_t; /* association ID */ +#define ASSOCID_MAX USHRT_MAX typedef u_int32 keyid_t; /* cryptographic key ID */ +#define KEYID_T_MAX (0xffffffff) typedef u_int32 tstamp_t; /* NTP seconds timestamp */ -#endif /* _NTP_TYPES_ */ +/* + * Cloning malloc()'s behavior of always returning pointers suitably + * aligned for the strictest alignment requirement of any type is not + * easy to do portably, as the maximum alignment required is not + * exposed. Use the size of a union of the types known to represent the + * strictest alignment on some platform. + */ +typedef union max_alignment_tag { + double d; +} max_alignment; + +#define MAXALIGN sizeof(max_alignment) +#define ALIGN_UNITS(sz) (((sz) + MAXALIGN - 1) / MAXALIGN) +#define ALIGNED_SIZE(sz) (MAXALIGN * ALIGN_UNITS(sz)) +#define INC_ALIGNED_PTR(b, m) ((void *)aligned_ptr((void *)(b), m)) + +static inline +max_alignment * +aligned_ptr( + max_alignment * base, + size_t minsize + ) +{ + return base + ALIGN_UNITS((minsize < 1) ? 1 : minsize); +} + +/* + * Macro to use in otherwise-empty source files to comply with ANSI C + * requirement that each translation unit (source file) contain some + * declaration. This has commonly been done by declaring an unused + * global variable of type int or char. An extern reference to exit() + * serves the same purpose without bloat. + */ +#define NONEMPTY_TRANSLATION_UNIT extern void exit(int); + +/* + * On Unix struct sock_timeval is equivalent to struct timeval. + * On Windows built with 64-bit time_t, sock_timeval.tv_sec is a long + * as required by Windows' socket() interface timeout argument, while + * timeval.tv_sec is time_t for the more common use as a UTC time + * within NTP. + */ +#ifndef SYS_WINNT +#define sock_timeval timeval +#endif + +/* + * On Unix open() works for tty (serial) devices just fine, while on + * Windows refclock serial devices are opened using CreateFile, a lower + * level than the CRT-provided descriptors, because the C runtime lacks + * tty APIs. For refclocks which wish to use open() as well as or + * instead of refclock_open(), tty_open() is equivalent to open() on + * Unix and implemented in the Windows port similarly to + * refclock_open(). + * Similarly, the termios emulation in the Windows code needs to know + * about serial ports being closed, while the Posix systems do not. + */ +#ifndef SYS_WINNT +# define tty_open(f, a, m) open(f, a, m) +# define closeserial(fd) close(fd) +# define closesocket(fd) close(fd) +typedef int SOCKET; +# define INVALID_SOCKET (-1) +# define SOCKET_ERROR (-1) +# define socket_errno() (errno) +#else /* SYS_WINNT follows */ +# define socket_errno() (errno = WSAGetLastError()) +#endif + + +#endif /* NTP_TYPES_H */ diff --git a/contrib/ntp/include/ntp_unixtime.h b/contrib/ntp/include/ntp_unixtime.h index ce9698020..eaa8b1ed4 100644 --- a/contrib/ntp/include/ntp_unixtime.h +++ b/contrib/ntp/include/ntp_unixtime.h @@ -1,13 +1,12 @@ /* - * ntp_unixtime.h - contains constants and macros for converting between - * NTP time stamps (l_fp) and Unix times (struct timeval) + * ntp_unixtime.h - much of what was here is now in timevalops.h */ -#include "ntp_types.h" +#ifndef NTP_UNIXTIME_H +#define NTP_UNIXTIME_H -#ifdef SIM -#include "ntpsim.h" -#endif +#include "ntp_types.h" /* picks up time.h via ntp_machine.h */ +#include "ntp_calendar.h" #ifdef SIM # define GETTIMEOFDAY(a, b) (node_gettime(&ntp_node, a)) @@ -19,7 +18,7 @@ # if defined(HAVE_SYS_TIMERS_H) && defined(HAVE_GETCLOCK) # include int getclock (int clock_type, struct timespec *tp); -/* Don't #define GETTIMEOFDAY because we shouldn't be using it in this case. */ +# define GETTIMEOFDAY(a, b) (gettimeofday(a, b)) # define SETTIMEOFDAY(a, b) (settimeofday(a, b)) # else /* not (HAVE_SYS_TIMERS_H && HAVE_GETCLOCK) */ # ifdef SYSV_TIMEOFDAY @@ -39,103 +38,10 @@ int getclock (int clock_type, struct timespec *tp); /* * Time of day conversion constant. Ntp's time scale starts in 1900, - * Unix in 1970. - */ -#define JAN_1970 0x83aa7e80 /* 2208988800 1970 - 1900 in seconds */ - -/* - * These constants are used to round the time stamps computed from - * a struct timeval to the microsecond (more or less). This keeps - * things neat. + * Unix in 1970. The value is 1970 - 1900 in seconds, 0x83aa7e80 or + * 2208988800. This is larger than 32-bit INT_MAX, so unsigned + * type is forced. */ -#define TS_MASK 0xfffff000 /* mask to usec, for time stamps */ -#define TS_ROUNDBIT 0x00000800 /* round at this bit */ - - -/* - * Convert usec to a time stamp fraction. If you use this the program - * must include the following declarations: - */ -extern u_long ustotslo[]; -extern u_long ustotsmid[]; -extern u_long ustotshi[]; - -#define TVUTOTSF(tvu, tsf) \ - (tsf) = ustotslo[(tvu) & 0xff] \ - + ustotsmid[((tvu) >> 8) & 0xff] \ - + ustotshi[((tvu) >> 16) & 0xf] - -/* - * Convert a struct timeval to a time stamp. - */ -#define TVTOTS(tv, ts) \ - do { \ - (ts)->l_ui = (u_long)(tv)->tv_sec; \ - TVUTOTSF((tv)->tv_usec, (ts)->l_uf); \ - } while(0) - -#define sTVTOTS(tv, ts) \ - do { \ - int isneg = 0; \ - long usec; \ - (ts)->l_ui = (tv)->tv_sec; \ - usec = (tv)->tv_usec; \ - if (((tv)->tv_sec < 0) || ((tv)->tv_usec < 0)) { \ - usec = -usec; \ - (ts)->l_ui = -(ts)->l_ui; \ - isneg = 1; \ - } \ - TVUTOTSF(usec, (ts)->l_uf); \ - if (isneg) { \ - L_NEG((ts)); \ - } \ - } while(0) - -/* - * TV_SHIFT is used to turn the table result into a usec value. To round, - * add in TV_ROUNDBIT before shifting - */ -#define TV_SHIFT 3 -#define TV_ROUNDBIT 0x4 - - -/* - * Convert a time stamp fraction to microseconds. The time stamp - * fraction is assumed to be unsigned. To use this in a program, declare: - */ -extern long tstouslo[]; -extern long tstousmid[]; -extern long tstoushi[]; - -#define TSFTOTVU(tsf, tvu) \ - (tvu) = (tstoushi[((tsf) >> 24) & 0xff] \ - + tstousmid[((tsf) >> 16) & 0xff] \ - + tstouslo[((tsf) >> 9) & 0x7f] \ - + TV_ROUNDBIT) >> TV_SHIFT -/* - * Convert a time stamp to a struct timeval. The time stamp - * has to be positive. - */ -#define TSTOTV(ts, tv) \ - do { \ - (tv)->tv_sec = (ts)->l_ui; \ - TSFTOTVU((ts)->l_uf, (tv)->tv_usec); \ - if ((tv)->tv_usec == 1000000) { \ - (tv)->tv_sec++; \ - (tv)->tv_usec = 0; \ - } \ - } while (0) - -/* - * Convert milliseconds to a time stamp fraction. This shouldn't be - * here, but it is convenient since the guys who use the definition will - * often be including this file anyway. - */ -extern u_long msutotsflo[]; -extern u_long msutotsfhi[]; - -#define MSUTOTSF(msu, tsf) \ - (tsf) = msutotsfhi[((msu) >> 5) & 0x1f] + msutotsflo[(msu) & 0x1f] +#define JAN_1970 ((u_int)NTP_TO_UNIX_DAYS * (u_int)SECSPERDAY) -extern char * tvtoa P((const struct timeval *)); -extern char * utvtoa P((const struct timeval *)); +#endif /* !defined(NTP_UNIXTIME_H) */ diff --git a/contrib/ntp/include/ntp_worker.h b/contrib/ntp/include/ntp_worker.h new file mode 100644 index 000000000..f7e8d5be7 --- /dev/null +++ b/contrib/ntp/include/ntp_worker.h @@ -0,0 +1,162 @@ +/* + * ntp_worker.h + */ + +#ifndef NTP_WORKER_H +#define NTP_WORKER_H + +#include "ntp_workimpl.h" + +#ifdef WORKER +# if defined(WORK_THREAD) && defined(WORK_PIPE) +# ifdef HAVE_SEMAPHORE_H +# include +# endif +# endif +#include "ntp_stdlib.h" + +/* #define TEST_BLOCKING_WORKER */ /* ntp_config.c ntp_intres.c */ + +typedef enum blocking_work_req_tag { + BLOCKING_GETNAMEINFO, + BLOCKING_GETADDRINFO, +} blocking_work_req; + +typedef void (*blocking_work_callback)(blocking_work_req, void *, size_t, void *); + +typedef enum blocking_magic_sig_e { + BLOCKING_REQ_MAGIC = 0x510c7ecf, + BLOCKING_RESP_MAGIC = 0x510c7e54, +} blocking_magic_sig; + +/* + * The same header is used for both requests to and responses from + * the child. In the child, done_func and context are opaque. + */ +typedef struct blocking_pipe_header_tag { + size_t octets; + blocking_magic_sig magic_sig; + blocking_work_req rtype; + u_int child_idx; + blocking_work_callback done_func; + void * context; +} blocking_pipe_header; + +# ifdef WORK_THREAD +# ifdef WORK_PIPE +typedef pthread_t * thr_ref; +typedef sem_t * sem_ref; +# else +typedef HANDLE thr_ref; +typedef HANDLE sem_ref; +# endif +# endif + +/* + * + */ +#ifdef WORK_FORK +typedef struct blocking_child_tag { + int reusable; + int pid; + int req_write_pipe; /* parent */ + int resp_read_pipe; + void * resp_read_ctx; + int req_read_pipe; /* child */ + int resp_write_pipe; + int ispipe; +} blocking_child; +#elif defined(WORK_THREAD) +typedef struct blocking_child_tag { +/* + * blocking workitems and blocking_responses are dynamically-sized + * one-dimensional arrays of pointers to blocking worker requests and + * responses. + */ + int reusable; + thr_ref thread_ref; + u_int thread_id; + blocking_pipe_header * volatile * volatile + workitems; + volatile size_t workitems_alloc; + size_t next_workitem; /* parent */ + size_t next_workeritem; /* child */ + blocking_pipe_header * volatile * volatile + responses; + volatile size_t responses_alloc; + size_t next_response; /* child */ + size_t next_workresp; /* parent */ + /* event handles / sem_t pointers */ + /* sem_ref child_is_blocking; */ + sem_ref blocking_req_ready; + sem_ref wake_scheduled_sleep; +#ifdef WORK_PIPE + int resp_read_pipe; /* parent */ + int resp_write_pipe;/* child */ + int ispipe; + void * resp_read_ctx; /* child */ +#else + sem_ref blocking_response_ready; +#endif +} blocking_child; + +#endif /* WORK_THREAD */ + +extern blocking_child ** blocking_children; +extern size_t blocking_children_alloc; +extern int worker_per_query; /* boolean */ +extern int intres_req_pending; + +extern u_int available_blocking_child_slot(void); +extern int queue_blocking_request(blocking_work_req, void *, + size_t, blocking_work_callback, + void *); +extern int queue_blocking_response(blocking_child *, + blocking_pipe_header *, size_t, + const blocking_pipe_header *); +extern void process_blocking_resp(blocking_child *); +extern int send_blocking_req_internal(blocking_child *, + blocking_pipe_header *, + void *); +extern int send_blocking_resp_internal(blocking_child *, + blocking_pipe_header *); +extern blocking_pipe_header * + receive_blocking_req_internal(blocking_child *); +extern blocking_pipe_header * + receive_blocking_resp_internal(blocking_child *); +extern int blocking_child_common(blocking_child *); +extern void exit_worker(int) + __attribute__ ((__noreturn__)); +extern int worker_sleep(blocking_child *, time_t); +extern void worker_idle_timer_fired(void); +extern void interrupt_worker_sleep(void); +extern int req_child_exit(blocking_child *); +#ifndef HAVE_IO_COMPLETION_PORT +extern int pipe_socketpair(int fds[2], int *is_pipe); +extern void close_all_beyond(int); +extern void close_all_except(int); +extern void kill_asyncio (int); +#endif + +# ifdef WORK_PIPE +typedef void (*addremove_io_fd_func)(int, int, int); +extern addremove_io_fd_func addremove_io_fd; +# else +extern void handle_blocking_resp_sem(void *); +typedef void (*addremove_io_semaphore_func)(sem_ref, int); +extern addremove_io_semaphore_func addremove_io_semaphore; +# endif + +# ifdef WORK_FORK +extern int worker_process; +# endif + +#endif /* WORKER */ + +#if defined(HAVE_DROPROOT) && defined(WORK_FORK) +extern void fork_deferred_worker(void); +#else +# define fork_deferred_worker() do {} while (0) +#endif + +#endif /* !NTP_WORKER_H */ diff --git a/contrib/ntp/include/ntp_workimpl.h b/contrib/ntp/include/ntp_workimpl.h new file mode 100644 index 000000000..a86c2cd0b --- /dev/null +++ b/contrib/ntp/include/ntp_workimpl.h @@ -0,0 +1,30 @@ +/* + * ntp_workimpl.h - selects worker child implementation + */ +#ifndef NTP_WORKIMPL_H +#define NTP_WORKIMPL_H + +/* + * Some systems do not support fork() and don't have an alternate + * threads implementation of ntp_intres. Such systems are limited + * to using numeric IP addresses. + */ +#if defined(SYS_WINNT) +# define WORK_THREAD +#elif defined(ISC_PLATFORM_USETHREADS) && \ + defined(HAVE_SEM_TIMEDWAIT) && \ + (defined(HAVE_GETCLOCK) || defined(HAVE_CLOCK_GETTIME)) +# define WORK_THREAD +# define WORK_PIPE +#elif defined(VMS) || defined(SYS_VXWORKS) + /* empty */ +#elif defined(HAVE_WORKING_FORK) +# define WORK_FORK +# define WORK_PIPE +#endif + +#if defined(WORK_FORK) || defined(WORK_THREAD) +# define WORKER +#endif + +#endif /* !NTP_WORKIMPL_H */ diff --git a/contrib/ntp/include/ntpd.h b/contrib/ntp/include/ntpd.h index d0957191b..be3cd3e76 100644 --- a/contrib/ntp/include/ntpd.h +++ b/contrib/ntp/include/ntpd.h @@ -1,32 +1,74 @@ /* - * ntpd.h - Prototypes for ntpd. + * ntpd.h - Prototypes and external variables for ntpd. + * + * Note the first half is primarily function prototypes, type + * declarations, and preprocessor macros, with variables declared + * primarily in the second half. + * + * Each half is further divided into sections for each source file. */ -#include "ntp_syslog.h" -#include "ntp_fp.h" #include "ntp.h" +#include "ntp_stdlib.h" +#include "ntp_syslog.h" #include "ntp_debug.h" +#include "ntp_syslog.h" #include "ntp_select.h" #include "ntp_malloc.h" #include "ntp_refclock.h" +#include "ntp_intres.h" #include "recvbuff.h" +/* + * First half: ntpd types, functions, macros + * ----------------------------------------- + */ -/* ntp_config.c */ -extern void getconfig P((int, char **)); +/* + * macro for debugging output - cut down on #ifdef pollution. + * + * DPRINTF() is for use by ntpd only, and compiles away to nothing + * without DEBUG (configure --disable-debugging). + * + * TRACE() is similar for libntp and utilities, which retain full + * debug capability even when compiled without DEBUG. + * + * The calling convention is not attractive: + * DPRINTF(debuglevel, (fmt, ...)); + * DPRINTF(2, ("shows #ifdef DEBUG and if debug >= %d\n", 2)); + */ +#ifdef DEBUG +# define DPRINTF(lvl, arg) \ + do { \ + if (debug >= (lvl)) \ + mprintf arg; \ + } while (0) +#else +# define DPRINTF(lvl, arg) do {} while (0) +#endif + + +/* nt_clockstuff.c */ +#ifdef SYS_WINNT +extern void win_time_stepped(void); +#endif /* ntp_config.c */ -extern void ctl_clr_stats P((void)); -extern int ctlclrtrap P((struct sockaddr_storage *, struct interface *, int)); -extern u_short ctlpeerstatus P((struct peer *)); -extern int ctlsettrap P((struct sockaddr_storage *, struct interface *, int, int)); -extern u_short ctlsysstatus P((void)); -extern void init_control P((void)); -extern void process_control P((struct recvbuf *, int)); -extern void report_event P((int, struct peer *)); - -extern double fabs P((double)); -extern double sqrt P((double)); +#define TAI_1972 10 /* initial TAI offset (s) */ +extern char *keysdir; /* crypto keys and leaptable directory */ +extern char * saveconfigdir; /* ntpq saveconfig output directory */ + +extern void getconfig (int, char **); +extern void ctl_clr_stats (void); +extern int ctlclrtrap (sockaddr_u *, struct interface *, int); +extern u_short ctlpeerstatus (struct peer *); +extern int ctlsettrap (sockaddr_u *, struct interface *, int, int); +extern u_short ctlsysstatus (void); +extern void init_control (void); +extern void process_control (struct recvbuf *, int); +extern void report_event (int, struct peer *, const char *); +extern int mprintf_event (int, struct peer *, const char *, ...) + NTP_PRINTF(3, 4); /* ntp_control.c */ /* @@ -36,7 +78,7 @@ extern double sqrt P((double)); struct ctl_var { u_short code; u_short flags; - char *text; + const char *text; }; /* * Flag values @@ -52,120 +94,120 @@ struct ctl_var { #define WO (CAN_WRITE) #define RW (CAN_READ|CAN_WRITE) -extern char * add_var P((struct ctl_var **, u_long, u_short)); -extern void free_varlist P((struct ctl_var *)); -extern void set_var P((struct ctl_var **, const char *, u_long, u_short)); -extern void set_sys_var P((const char *, u_long, u_short)); - -/* ntp_intres.c */ -extern void ntp_res_name P((struct sockaddr_storage, u_short)); -extern void ntp_res_recv P((void)); -extern void ntp_intres P((void)); +extern char * add_var (struct ctl_var **, u_long, u_short); +extern void free_varlist (struct ctl_var *); +extern void set_var (struct ctl_var **, const char *, u_long, u_short); +extern void set_sys_var (const char *, u_long, u_short); +extern const char * get_ext_sys_var(const char *tag); /* ntp_io.c */ typedef struct interface_info { - struct interface *interface; - u_char action; + endpt * ep; + u_char action; } interface_info_t; -typedef void (*interface_receiver_t)(void *, interface_info_t *); - -extern volatile int disable_dynamic_updates; - -extern void interface_enumerate P((interface_receiver_t, void *)); -extern struct interface *findinterface P((struct sockaddr_storage *)); -extern struct interface *findbcastinter P((struct sockaddr_storage *)); -extern void enable_broadcast P((struct interface *, struct sockaddr_storage *)); -extern void enable_multicast_if P((struct interface *, struct sockaddr_storage *)); -extern void interface_dump P((struct interface *)); - -extern void interface_update P((interface_receiver_t, void *)); -extern void init_io P((void)); -extern void input_handler P((l_fp *)); -extern void io_clr_stats P((void)); -extern void io_setbclient P((void)); -extern void io_unsetbclient P((void)); -extern void io_multicast_add P((struct sockaddr_storage)); -extern void io_multicast_del P((struct sockaddr_storage)); -extern void kill_asyncio P((int)); -extern void sendpkt P((struct sockaddr_storage *, struct interface *, int, struct pkt *, int)); +typedef void (*interface_receiver_t) (void *, interface_info_t *); + +extern void interface_enumerate (interface_receiver_t, void *); +extern endpt * getinterface (sockaddr_u *, u_int32); +extern endpt * select_peerinterface (struct peer *, sockaddr_u *, + endpt *); +extern endpt * findinterface (sockaddr_u *); +extern endpt * findbcastinter (sockaddr_u *); +extern void enable_broadcast (endpt *, sockaddr_u *); +extern void enable_multicast_if (endpt *, sockaddr_u *); +extern void interface_update (interface_receiver_t, void *); +#ifndef HAVE_IO_COMPLETION_PORT +extern void io_handler (void); +#endif +extern void init_io (void); +extern void io_open_sockets (void); +extern void io_clr_stats (void); +extern void io_setbclient (void); +extern void io_unsetbclient (void); +extern void io_multicast_add(sockaddr_u *); +extern void io_multicast_del(sockaddr_u *); +extern void sendpkt (sockaddr_u *, struct interface *, int, struct pkt *, int); #ifdef DEBUG -extern void collect_timing P((struct recvbuf *, const char *, int, l_fp *)); +extern void collect_timing (struct recvbuf *, const char *, int, l_fp *); #endif #ifdef HAVE_SIGNALED_IO -extern void wait_for_signal P((void)); -extern void unblock_io_and_alarm P((void)); -extern void block_io_and_alarm P((void)); -#define UNBLOCK_IO_AND_ALARM() unblock_io_and_alarm() -#define BLOCK_IO_AND_ALARM() block_io_and_alarm() +extern void wait_for_signal (void); +extern void unblock_io_and_alarm (void); +extern void block_io_and_alarm (void); +# define UNBLOCK_IO_AND_ALARM() unblock_io_and_alarm() +# define BLOCK_IO_AND_ALARM() block_io_and_alarm() #else -#define UNBLOCK_IO_AND_ALARM() -#define BLOCK_IO_AND_ALARM() +# define UNBLOCK_IO_AND_ALARM() do {} while (0) +# define BLOCK_IO_AND_ALARM() do {} while (0) #endif - -/* ntp_leap.c */ -extern void init_leap P((void)); -extern void leap_process P((void)); -extern int leap_setleap P((int, int)); -/* - * there seems to be a bug in the IRIX 4 compiler which prevents - * u_char from beeing used in prototyped functions. - * This is also true AIX compiler. - * So give up and define it to be int. WLJ - */ -extern int leap_actual P((int)); +#define latoa(pif) localaddrtoa(pif) +extern const char * localaddrtoa(endpt *); /* ntp_loopfilter.c */ -extern void init_loopfilter P((void)); -extern int local_clock P((struct peer *, double)); -extern void adj_host_clock P((void)); -extern void loop_config P((int, double)); -extern void huffpuff P((void)); +extern void init_loopfilter(void); +extern int local_clock(struct peer *, double); +extern void adj_host_clock(void); +extern void loop_config(int, double); +extern void select_loop(int); +extern void huffpuff(void); extern u_long sys_clocktime; -extern u_long sys_tai; +extern u_int sys_tai; +extern int freq_cnt; /* ntp_monitor.c */ -extern void init_mon P((void)); -extern void mon_start P((int)); -extern void mon_stop P((int)); -extern int ntp_monitor P((struct recvbuf *)); -extern void ntp_monclearinterface P((struct interface *interface)); +#define MON_HASH_SIZE (1U << mon_hash_bits) +#define MON_HASH_MASK (MON_HASH_SIZE - 1) +#define MON_HASH(addr) (sock_hash(addr) & MON_HASH_MASK) +extern void init_mon (void); +extern void mon_start (int); +extern void mon_stop (int); +extern u_short ntp_monitor (struct recvbuf *, u_short); +extern void mon_clearinterface(endpt *interface); /* ntp_peer.c */ -extern void init_peer P((void)); -extern struct peer *findexistingpeer P((struct sockaddr_storage *, struct peer *, int)); -extern struct peer *findpeer P((struct sockaddr_storage *, struct interface *, int, int *)); -extern struct peer *findpeerbyassoc P((u_int)); -extern void set_peerdstadr P((struct peer *peer, struct interface *interface)); -extern struct peer *newpeer P((struct sockaddr_storage *, struct interface *, int, int, int, int, u_int, u_char, int, keyid_t)); -extern void peer_all_reset P((void)); -extern void peer_clr_stats P((void)); -extern struct peer *peer_config P((struct sockaddr_storage *, struct interface *, int, int, int, int, u_int, int, keyid_t, u_char *)); -extern void peer_reset P((struct peer *)); -extern int peer_unconfig P((struct sockaddr_storage *, struct interface *, int)); -extern void refresh_all_peerinterfaces P((void)); -extern void unpeer P((struct peer *)); -extern void clear_all P((void)); - -#ifdef OPENSSL -extern void expire_all P((void)); -#endif /* OPENSSL */ -extern struct peer *findmanycastpeer P((struct recvbuf *)); +extern void init_peer (void); +extern struct peer *findexistingpeer(sockaddr_u *, const char *, + struct peer *, int, u_char); +extern struct peer *findpeer (struct recvbuf *, int, int *); +extern struct peer *findpeerbyassoc(associd_t); +extern void set_peerdstadr (struct peer *, endpt *); +extern struct peer *newpeer (sockaddr_u *, const char *, + endpt *, u_char, u_char, + u_char, u_char, u_int, u_char, u_int32, + keyid_t, const char *); +extern void peer_all_reset (void); +extern void peer_clr_stats (void); +extern struct peer *peer_config(sockaddr_u *, const char *, + endpt *, u_char, u_char, + u_char, u_char, u_int, u_int32, + keyid_t, const char *); +extern void peer_reset (struct peer *); +extern void refresh_all_peerinterfaces(void); +extern void unpeer (struct peer *); +extern void clear_all (void); +extern int score_all (struct peer *); +extern struct peer *findmanycastpeer(struct recvbuf *); +extern void peer_cleanup (void); /* ntp_crypto.c */ -#ifdef OPENSSL -extern int crypto_recv P((struct peer *, struct recvbuf *)); -extern int crypto_xmit P((struct pkt *, struct sockaddr_storage *, int, struct exten *, keyid_t)); -extern keyid_t session_key P((struct sockaddr_storage *, struct sockaddr_storage *, keyid_t, keyid_t, u_long)); -extern int make_keylist P((struct peer *, struct interface *)); -extern void key_expire P((struct peer *)); -extern void crypto_update P((void)); -extern void crypto_config P((int, char *)); -extern void crypto_setup P((void)); -extern u_int crypto_ident P((struct peer *)); -extern struct exten *crypto_args P((struct peer *, u_int, char *)); -extern int crypto_public P((struct peer *, u_char *, u_int)); -extern void value_free P((struct value *)); +#ifdef AUTOKEY +extern int crypto_recv (struct peer *, struct recvbuf *); +extern int crypto_xmit (struct peer *, struct pkt *, + struct recvbuf *, int, + struct exten *, keyid_t); +extern keyid_t session_key (sockaddr_u *, sockaddr_u *, keyid_t, + keyid_t, u_long); +extern int make_keylist (struct peer *, struct interface *); +extern void key_expire (struct peer *); +extern void crypto_update (void); +extern void crypto_update_taichange(void); +extern void crypto_config (int, char *); +extern void crypto_setup (void); +extern u_int crypto_ident (struct peer *); +extern struct exten *crypto_args (struct peer *, u_int, associd_t, char *); +extern int crypto_public (struct peer *, u_char *, u_int); +extern void value_free (struct value *); extern char *iffpar_file; extern EVP_PKEY *iffpar_pkey; extern char *gqpar_file; @@ -173,80 +215,108 @@ extern EVP_PKEY *gqpar_pkey; extern char *mvpar_file; extern EVP_PKEY *mvpar_pkey; extern struct value tai_leap; -#endif /* OPENSSL */ +#endif /* AUTOKEY */ /* ntp_proto.c */ -extern void transmit P((struct peer *)); -extern void receive P((struct recvbuf *)); -extern void peer_crypto_clear P((struct peer *peer)); -extern void peer_clear P((struct peer *, char *)); -extern void process_packet P((struct peer *, struct pkt *)); -extern void clock_select P((void)); -extern void kod_proto P((void)); - -/* - * there seems to be a bug in the IRIX 4 compiler which prevents - * u_char from beeing used in prototyped functions. - * This is also true AIX compiler. - * So give up and define it to be int. WLJ - */ -extern void poll_update P((struct peer *, int)); +extern void transmit (struct peer *); +extern void receive (struct recvbuf *); +extern void peer_clear (struct peer *, const char *); +extern void process_packet (struct peer *, struct pkt *, u_int); +extern void clock_select (void); +extern void set_sys_leap (u_char); + +extern u_long leapsec; /* seconds to next leap (proximity class) */ +extern int leapdif; /* TAI difference step at next leap second*/ +extern int sys_orphan; +extern double sys_mindisp; +extern double sys_maxdist; + +extern char *sys_ident; /* identity scheme */ +extern void poll_update (struct peer *, u_char); + +extern void clear (struct peer *); +extern void clock_filter (struct peer *, double, double, double); +extern void init_proto (void); +extern void set_sys_tick_precision(double); +extern void proto_config (int, u_long, double, sockaddr_u *); +extern void proto_clr_stats (void); -extern void clear P((struct peer *)); -extern void clock_filter P((struct peer *, double, double, double)); -extern void init_proto P((void)); -extern void proto_config P((int, u_long, double, struct sockaddr_storage*)); -extern void proto_clr_stats P((void)); - -#ifdef REFCLOCK /* ntp_refclock.c */ -extern int refclock_newpeer P((struct peer *)); -extern void refclock_unpeer P((struct peer *)); -extern void refclock_receive P((struct peer *)); -extern void refclock_transmit P((struct peer *)); -extern void init_refclock P((void)); +#ifdef REFCLOCK +extern int refclock_newpeer (struct peer *); +extern void refclock_unpeer (struct peer *); +extern void refclock_receive (struct peer *); +extern void refclock_transmit (struct peer *); +extern void init_refclock (void); #endif /* REFCLOCK */ /* ntp_request.c */ -extern void init_request P((void)); -extern void process_private P((struct recvbuf *, int)); +extern void init_request (void); +extern void process_private (struct recvbuf *, int); +extern void reset_auth_stats(void); /* ntp_restrict.c */ -extern void init_restrict P((void)); -extern int restrictions P((struct sockaddr_storage *, int)); -extern void hack_restrict P((int, struct sockaddr_storage *, struct sockaddr_storage *, int, int)); +extern void init_restrict (void); +extern u_short restrictions (sockaddr_u *); +extern void hack_restrict (int, sockaddr_u *, sockaddr_u *, + u_short, u_short, u_long); +extern void restrict_source (sockaddr_u *, int, u_long); /* ntp_timer.c */ -extern void init_timer P((void)); -extern void reinit_timer P((void)); -extern void timer P((void)); -extern void timer_clr_stats P((void)); -extern void timer_interfacetimeout P((u_long)); -extern volatile int interface_interval; - -#ifdef OPENSSL -extern char *sys_hostname; -extern l_fp sys_revoketime; -#endif /* OPENSSL */ +extern void init_timer (void); +extern void reinit_timer (void); +extern void timer (void); +extern void timer_clr_stats (void); +extern void timer_interfacetimeout (u_long); +extern volatile int interface_interval; +extern u_long orphwait; /* orphan wait time */ +#ifdef AUTOKEY +extern char *sys_hostname; /* host name */ +extern char *sys_groupname; /* group name */ +extern char *group_name; /* group name */ +extern u_long sys_revoke; /* keys revoke timeout */ +extern u_long sys_automax; /* session key timeout */ +#endif /* AUTOKEY */ /* ntp_util.c */ -extern void init_util P((void)); -extern void write_stats P((void)); -extern void stats_config P((int, const char *)); -extern void record_peer_stats P((struct sockaddr_storage *, int, double, double, double, double)); -extern void record_loop_stats P((double, double, double, double, int)); -extern void record_clock_stats P((struct sockaddr_storage *, const char *)); -extern void record_raw_stats P((struct sockaddr_storage *, struct sockaddr_storage *, l_fp *, l_fp *, l_fp *, l_fp *)); -extern void record_sys_stats P((void)); -extern void record_crypto_stats P((struct sockaddr_storage *, const char *)); +extern void init_util (void); +extern void write_stats (void); +extern void stats_config (int, const char *); +extern void record_peer_stats (sockaddr_u *, int, double, double, double, double); +extern void record_proto_stats (char *); +extern void record_loop_stats (double, double, double, double, int); +extern void record_clock_stats (sockaddr_u *, const char *); +extern int mprintf_clock_stats(sockaddr_u *, const char *, ...) + NTP_PRINTF(2, 3); +extern void record_raw_stats (sockaddr_u *srcadr, sockaddr_u *dstadr, l_fp *t1, l_fp *t2, l_fp *t3, l_fp *t4, int leap, int version, int mode, int stratum, int ppoll, int precision, double root_delay, double root_dispersion, u_int32 refid); +extern void check_leap_file (int is_daily_check, u_int32 ntptime, const time_t * systime); +extern void record_crypto_stats (sockaddr_u *, const char *); #ifdef DEBUG -extern void record_timing_stats P((const char *)); +extern void record_timing_stats (const char *); #endif -extern int sock_hash P((struct sockaddr_storage *)); -extern double old_drift; +extern char * fstostr(time_t); /* NTP timescale seconds */ +/* ntpd.c */ +extern void parse_cmdline_opts(int *, char ***); +/* + * Signals we catch for debugging. + */ +#define MOREDEBUGSIG SIGUSR1 +#define LESSDEBUGSIG SIGUSR2 /* - * Variable declarations for ntpd. + * Signals which terminate us gracefully. + */ +#ifndef SYS_WINNT +# define SIGDIE1 SIGHUP +# define SIGDIE2 SIGINT +# define SIGDIE3 SIGQUIT +# define SIGDIE4 SIGTERM +#endif /* SYS_WINNT */ + + +/* + * Last half: ntpd variables + * ------------------------- */ /* ntp_config.c */ @@ -256,6 +326,20 @@ extern char *sys_phone[]; /* ACTS phone numbers */ extern int config_priority_override; extern int config_priority; #endif +extern char *ntp_signd_socket; +extern struct config_tree_tag *cfg_tree_history; + +#ifdef BC_LIST_FRAMEWORK_NOT_YET_USED +/* + * backwards compatibility flags + */ +typedef struct bc_entry_tag { + int token; + int enabled; +} bc_entry; + +extern bc_entry bc_list[]; +#endif /* ntp_control.c */ extern int num_ctl_traps; @@ -280,15 +364,6 @@ extern u_long numctldatatooshort; /* data too short for count */ extern u_long numctlbadop; /* bad op code found in packet */ extern u_long numasyncmsgs; /* number of async messages we've sent */ -/* ntp_intres.c */ -extern keyid_t req_keyid; /* request keyid */ -extern char * req_file; /* name of the file with configuration info */ -#ifdef SYS_WINNT -extern HANDLE ResolverEventHandle; -#else -extern int resolver_pipe_fd[2]; /* used to let the resolver process alert the parent process */ -#endif /* SYS_WINNT */ - /* * Other statistics of possible interest */ @@ -302,27 +377,23 @@ extern volatile u_long handler_calls; /* number of calls to interrupt handler */ extern volatile u_long handler_pkts; /* number of pkts received by handler */ extern u_long io_timereset; /* time counters were reset */ -/* - * Interface stuff - */ -extern struct interface *any_interface; /* default ipv4 interface */ -extern struct interface *any6_interface;/* default ipv6 interface */ -extern struct interface *loopback_interface; /* loopback interface */ - -/* - * File descriptor masks etc. for call to select - */ -extern fd_set activefds; -extern int maxactivefd; +/* ntp_io.c */ +extern int disable_dynamic_updates; +extern u_int sys_ifnum; /* next .ifnum to assign */ +extern endpt * any_interface; /* IPv4 wildcard */ +extern endpt * any6_interface; /* IPv6 wildcard */ +extern endpt * loopback_interface; /* IPv4 loopback for refclocks */ +extern endpt * ep_list; /* linked list */ /* ntp_loopfilter.c */ extern double drift_comp; /* clock frequency (s/s) */ extern double clock_stability; /* clock stability (s/s) */ -extern double clock_max; /* max offset before step (s) */ +extern double clock_max_back; /* max backward offset before step (s) */ +extern double clock_max_fwd; /* max forward offset before step (s) */ extern double clock_panic; /* max offset before panic (s) */ extern double clock_phi; /* dispersion rate (s/s) */ extern double clock_minstep; /* step timeout (s) */ -extern u_long pps_control; /* last pps sample time */ +extern double clock_codec; /* codec frequency */ #ifdef KERNEL_PLL extern int pll_status; /* status bits for kernel pll */ #endif /* KERNEL_PLL */ @@ -333,11 +404,12 @@ extern int pll_status; /* status bits for kernel pll */ extern int ntp_enable; /* clock discipline enabled */ extern int pll_control; /* kernel support available */ extern int kern_enable; /* kernel support enabled */ -extern int pps_enable; /* kernel PPS discipline enabled */ +extern int hardpps_enable; /* kernel PPS discipline enabled */ extern int ext_enable; /* external clock enabled */ extern int cal_enable; /* refclock calibrate enable */ -extern int allow_panic; /* allow panic correction */ -extern int mode_ntpdate; /* exit on first clock set */ +extern int allow_panic; /* allow panic correction (-g) */ +extern int force_step_once; /* always step time once at startup (-G) */ +extern int mode_ntpdate; /* exit on first clock set (-q) */ extern int peer_ntpdate; /* count of ntpdate peers */ /* @@ -348,21 +420,34 @@ extern int state; /* clock discipline state */ extern int tc_counter; /* poll-adjust counter */ extern u_long last_time; /* time of last clock update (s) */ extern double last_offset; /* last clock offset (s) */ -extern double allan_xpt; /* Allan intercept (s) */ +extern u_char allan_xpt; /* Allan intercept (log2 s) */ extern double clock_jitter; /* clock jitter (s) */ +extern double sys_offset; /* system offset (s) */ extern double sys_jitter; /* system jitter (s) */ /* ntp_monitor.c */ -extern struct mon_data mon_mru_list; -extern struct mon_data mon_fifo_list; -extern int mon_enabled; +extern u_char mon_hash_bits; /* log2 size of hash table */ +extern mon_entry ** mon_hash; /* MRU hash table */ +extern mon_entry mon_mru_list; /* mru listhead */ +extern u_int mon_enabled; /* MON_OFF (0) or other MON_* */ +extern u_int mru_alloc; /* mru list + free list count */ +extern u_int mru_entries; /* mru list count */ +extern u_int mru_peakentries; /* highest mru_entries */ +extern u_int mru_initalloc; /* entries to preallocate */ +extern u_int mru_incalloc; /* allocation batch factor */ +extern u_int mru_mindepth; /* preempt above this */ +extern int mru_maxage; /* for entries older than */ +extern u_int mru_maxdepth; /* MRU size hard limit */ +extern int mon_age; /* preemption limit */ /* ntp_peer.c */ -extern struct peer *peer_hash[]; /* peer hash table */ -extern int peer_hash_count[]; /* count of peers in each bucket */ -extern struct peer *assoc_hash[]; /* association ID hash table */ -extern int assoc_hash_count[]; -extern int peer_free_count; +extern struct peer *peer_hash[NTP_HASH_SIZE]; /* peer hash table */ +extern int peer_hash_count[NTP_HASH_SIZE]; /* count of in each bucket */ +extern struct peer *assoc_hash[NTP_HASH_SIZE]; /* association ID hash table */ +extern int assoc_hash_count[NTP_HASH_SIZE];/* count of in each bucket */ +extern struct peer *peer_list; /* peer structures list */ +extern int peer_count; /* count in peer_list */ +extern int peer_free_count; /* count in peer_free */ /* * Miscellaneous statistic counters which may be queried. @@ -375,22 +460,20 @@ extern u_long peer_demobilizations; /* number of structs freed to free list */ extern int total_peer_structs; /* number of peer structs in circulation */ extern int peer_associations; /* mobilized associations */ extern int peer_preempt; /* preemptable associations */ + /* ntp_proto.c */ /* * System variables are declared here. See Section 3.2 of the * specification. */ extern u_char sys_leap; /* system leap indicator */ -extern u_char sys_stratum; /* stratum of system */ +extern u_char sys_stratum; /* system stratum */ extern s_char sys_precision; /* local clock precision */ -extern double sys_rootdelay; /* distance to current sync source */ -extern double sys_rootdispersion; /* dispersion of system clock */ -extern u_int32 sys_refid; /* reference source for local clock */ -extern l_fp sys_reftime; /* time we were last updated */ -extern struct peer *sys_peer; /* our current peer */ -extern struct peer *sys_pps; /* our current PPS peer */ -extern struct peer *sys_prefer; /* our cherished peer */ -extern u_long sys_automax; /* maximum session key lifetime */ +extern double sys_rootdelay; /* roundtrip delay to primary source */ +extern double sys_rootdisp; /* dispersion to primary source */ +extern u_int32 sys_refid; /* reference id */ +extern l_fp sys_reftime; /* last update time */ +extern struct peer *sys_peer; /* current peer */ /* * Nonspecified system state variables. @@ -399,74 +482,97 @@ extern int sys_bclient; /* we set our time to broadcasts */ extern double sys_bdelay; /* broadcast client default delay */ extern int sys_authenticate; /* requre authentication for config */ extern l_fp sys_authdelay; /* authentication delay */ +extern u_long sys_epoch; /* last clock update time */ extern keyid_t sys_private; /* private value for session seed */ extern int sys_manycastserver; /* respond to manycast client pkts */ extern int sys_minclock; /* minimum survivors */ extern int sys_minsane; /* minimum candidates */ extern int sys_floor; /* cluster stratum floor */ extern int sys_ceiling; /* cluster stratum ceiling */ -extern u_char sys_ttl[]; /* ttl mapping vector */ +extern u_char sys_ttl[MAX_TTL]; /* ttl mapping vector */ extern int sys_ttlmax; /* max ttl mapping vector index */ -extern int leap_next; /* leap consensus */ /* * Statistics counters */ -extern u_long sys_stattime; /* time when we started recording */ +extern u_long sys_stattime; /* time since reset */ +extern u_long sys_received; /* packets received */ +extern u_long sys_processed; /* packets for this host */ extern u_long sys_restricted; /* restricted packets */ -extern u_long sys_oldversionpkt; /* old version packets */ -extern u_long sys_newversionpkt; /* new version packets */ -extern u_long sys_unknownversion; /* don't know version packets */ +extern u_long sys_newversion; /* current version */ +extern u_long sys_oldversion; /* old version */ +extern u_long sys_restricted; /* access denied */ extern u_long sys_badlength; /* bad length or format */ -extern u_long sys_processed; /* packets processed */ extern u_long sys_badauth; /* bad authentication */ -extern u_long sys_limitrejected; /* rate limit exceeded */ -extern u_long sys_received; /* packets received */ - -/* ntp_refclock.c */ -#ifdef REFCLOCK -#ifdef PPS -extern int fdpps; /* pps file descriptor */ -#endif /* PPS */ -#endif +extern u_long sys_declined; /* declined */ +extern u_long sys_limitrejected; /* rate exceeded */ +extern u_long sys_kodsent; /* KoD sent */ /* ntp_request.c */ extern keyid_t info_auth_keyid; /* keyid used to authenticate requests */ +extern u_long auth_timereset; /* ntp_restrict.c */ -extern struct restrictlist *restrictlist; /* the ipv4 restriction list */ -extern struct restrictlist6 *restrictlist6; /* the ipv6 restriction list */ -extern u_long res_min_interval; -extern u_long res_avg_interval; -extern u_long mon_age; /* monitor preempt age */ +extern restrict_u * restrictlist4; /* IPv4 restriction list */ +extern restrict_u * restrictlist6; /* IPv6 restriction list */ +extern int ntp_minpkt; +extern u_char ntp_minpoll; + +/* ntp_scanner.c */ +extern u_int32 conf_file_sum; /* Simple sum of characters */ + +/* ntp_signd.c */ +#ifdef HAVE_NTP_SIGND +extern void send_via_ntp_signd(struct recvbuf *, int, keyid_t, int, + struct pkt *); +#endif /* ntp_timer.c */ extern volatile int alarm_flag; /* alarm flag */ -extern u_char sys_revoke; /* keys revoke timeout (log2 s) */ extern volatile u_long alarm_overflow; -extern u_long current_time; /* current time (s) */ +extern u_long current_time; /* seconds since startup */ extern u_long timer_timereset; extern u_long timer_overflows; extern u_long timer_xmtcalls; +extern int leap_sec_in_progress; +#ifdef LEAP_SMEAR +extern struct leap_smear_info leap_smear; +extern int leap_smear_intv; +#endif +#ifdef SYS_WINNT +HANDLE WaitableTimerHandle; +#endif /* ntp_util.c */ -extern int stats_control; /* write stats to fileset? */ -extern int stats_write_period; /* # of seconds between writes. */ -extern double stats_write_tolerance; +extern char statsdir[MAXFILENAME]; +extern int stats_control; /* write stats to fileset? */ +extern int stats_write_period; /* # of seconds between writes. */ +extern double stats_write_tolerance; +extern double wander_threshold; /* ntpd.c */ -extern volatile int debug; /* debugging flag */ -extern int nofork; /* no-fork flag */ -extern int initializing; /* initializing flag */ +extern int nofork; /* no-fork flag */ +extern int initializing; /* initializing flag */ #ifdef HAVE_DROPROOT -extern int droproot; /* flag: try to drop root privileges after startup */ -extern char *user; /* user to switch to */ -extern char *group; /* group to switch to */ -extern char *chrootdir; /* directory to chroot to */ +extern int droproot; /* flag: try to drop root privileges after startup */ +extern int root_dropped; /* root has been dropped */ +extern char *user; /* user to switch to */ +extern char *group; /* group to switch to */ +extern const char *chrootdir; /* directory to chroot() to */ +#endif +#ifdef HAVE_WORKING_FORK +extern int waitsync_fd_to_close; /* -w/--wait-sync */ +#endif + +/* ntservice.c */ +#ifdef SYS_WINNT +extern int accept_wildcard_if_for_winnt; #endif /* refclock_conf.c */ #ifdef REFCLOCK -extern struct refclock *refclock_conf[]; /* refclock configuration table */ +/* refclock configuration table */ +extern struct refclock * const refclock_conf[]; extern u_char num_refclock_conf; #endif + diff --git a/contrib/ntp/include/ntpsim.h b/contrib/ntp/include/ntpsim.h index c48dc5954..b270ce640 100644 --- a/contrib/ntp/include/ntpsim.h +++ b/contrib/ntp/include/ntpsim.h @@ -1,13 +1,21 @@ -/* - * ntpsim.h - Prototypes for ntpsim +/* ntpsim.h + * + * The header file for the ntp discrete event simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 */ -#ifndef __ntpsim_h -#define __ntpsim_h +#ifndef NTPSIM_H +#define NTPSIM_H #include #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif #include #include "ntp_syslog.h" #include "ntp_fp.h" @@ -18,76 +26,121 @@ #include "recvbuff.h" #include "ntp_io.h" #include "ntp_stdlib.h" +#include "ntp_prio_q.h" + +/* CONSTANTS */ + +#ifdef PI +# undef PI +#endif +#define PI 3.1415926535 /* The world's most famous constant */ +#define SIM_TIME 86400 /* end simulation time */ +#define NET_DLY .001 /* network delay */ +#define PROC_DLY .001 /* processing delay */ +#define BEEP_DLY 3600 /* beep interval (s) */ -#define PI 3.1415926535 -/* - * ntpsim declarations +/* Discrete Event Queue + * -------------------- + * The NTP simulator is a discrete event simulator. + * + * Central to this simulator is an event queue which is a priority queue + * in which the "priority" is given by the time of arrival of the event. + * + * A discrete set of events can happen and are stored in the queue to arrive + * at a particular time. */ + +/* Possible Discrete Events */ + typedef enum { - BEEP, CLOCK, TIMER, PACKET + BEEP, /* Event to record simulator stats */ + CLOCK, /* Event to advance the clock to the specified time */ + TIMER, /* Event that designates a timer interrupt. */ + PACKET /* Event that designates arrival of a packet */ } funcTkn; + +/* Event information */ + typedef struct { - double time; - union { - struct pkt evnt_pkt; - struct recvbuf evnt_buf; - } buffer; + double time; /* Time at which event occurred */ + funcTkn function; /* Type of event that occured */ + union { + struct pkt evnt_pkt; + struct recvbuf evnt_buf; + } buffer; /* Other data associated with the event */ #define ntp_pkt buffer.evnt_pkt #define rcv_buf buffer.evnt_buf - funcTkn function; } Event; -typedef struct List { - Event event; - struct List *next; -} *Queue; - -typedef struct nde { - double time; /* simulation time */ - double sim_time; /* end simulation time */ - double ntp_time; /* client disciplined time */ - double adj; /* remaining time correction */ - double slew; /* correction slew rate */ - - double clk_time; /* server time */ - double ferr; /* frequency errort */ - double fnse; /* random walk noise */ - double ndly; /* network delay */ - double snse; /* phase noise */ - double pdly; /* processing delay */ - double bdly; /* beep interval */ - - double last_time; /* last clock read time */ - Queue events; /* Node Event Queue */ - struct recvbuf *rbuflist; /* Node Receive Buffer */ -} Node; - -/* - * Function prototypes - */ -int ntpsim P((int argc, char *argv[])); -Event event P((double, funcTkn)); -Queue queue P((Event, Queue )); -Node node P((void)); -void push P((Event, Queue *)); -Event pop P((Queue *)); -void ndbeep P((Node *, Event)); -void ndeclk P((Node *, Event)); -void ntptmr P((Node *, Event)); -void netpkt P((Node *, Event)); -int srvr_rply P((Node *, struct sockaddr_storage *, - struct interface *, struct pkt *)); -double gauss P((double, double)); -double poisson P((double, double)); -int node_clock P((Node *, double)); -void abortsim P((char *)); - -/* - * The global Node - */ -Node ntp_node; -#endif +/* Server Script Information */ +typedef struct script_info_tag script_info; +struct script_info_tag { + script_info * link; + double duration; + double freq_offset; + double wander; + double jitter; + double prop_delay; + double proc_delay; +}; + +typedef DECL_FIFO_ANCHOR(script_info) script_info_fifo; + + +/* Server Structures */ + +typedef struct server_info_tag server_info; +struct server_info_tag { + server_info * link; + double server_time; + sockaddr_u * addr; + script_info_fifo * script; + script_info * curr_script; +}; + +typedef DECL_FIFO_ANCHOR(server_info) server_info_fifo; + + +/* Simulation control information */ + +typedef struct Sim_Info { + double sim_time; /* Time in the simulation */ + double end_time; /* Time at which simulation needs to be ended */ + double beep_delay; /* Delay between simulation "beeps" at which + simulation stats are recorded. */ + int num_of_servers; /* Number of servers in the simulation */ + server_info *servers; /* Pointer to array of servers */ +} sim_info; + + +/* Local Clock (Client) Variables */ + +typedef struct Local_Clock_Info { + double local_time; /* Client disciplined time */ + double adj; /* Remaining time correction */ + double slew; /* Correction Slew Rate */ + double last_read_time; /* Last time the clock was read */ +} local_clock_info; + +extern local_clock_info simclock; /* Local Clock Variables */ +extern sim_info simulation; /* Simulation Control Variables */ + +/* Function Prototypes */ + +int ntpsim (int argc, char *argv[]); +Event *event (double t, funcTkn f); +void sim_event_timer (Event *e); +int simulate_server (sockaddr_u *serv_addr, endpt *inter, + struct pkt *rpkt); +void sim_update_clocks (Event *e); +void sim_event_recv_packet (Event *e); +void sim_event_beep (Event *e); +void abortsim (char *errmsg); +double gauss (double, double); +double poisson (double, double); +void create_server_associations(void); +#endif /* NTPSIM_H */ diff --git a/contrib/ntp/include/parse.h b/contrib/ntp/include/parse.h index 8b4edcf8e..9b1ffb227 100644 --- a/contrib/ntp/include/parse.h +++ b/contrib/ntp/include/parse.h @@ -3,8 +3,8 @@ * * parse.h,v 4.12 2007/01/14 08:36:03 kardel RELEASE_20070114_A * - * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2015 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -58,11 +58,11 @@ #endif #ifdef PARSEKERNEL #ifndef _KERNEL -extern caddr_t kmem_alloc P((unsigned int)); -extern caddr_t kmem_free P((caddr_t, unsigned int)); -extern unsigned int splx P((unsigned int)); -extern unsigned int splhigh P((void)); -extern unsigned int splclock P((void)); +extern caddr_t kmem_alloc (unsigned int); +extern caddr_t kmem_free (caddr_t, unsigned int); +extern unsigned int splx (unsigned int); +extern unsigned int splhigh (void); +extern unsigned int splclock (void); #define MALLOC(_X_) (char *)kmem_alloc(_X_) #define FREE(_X_, _Y_) kmem_free((caddr_t)_X_, _Y_) #else @@ -104,6 +104,13 @@ extern unsigned int splclock P((void)); #define TIMES10(_X_) (((_X_) << 3) + ((_X_) << 1)) #endif +/* + * some constants useful for GPS time conversion + */ +#define GPSORIGIN 2524953600UL /* NTP origin - GPS origin in seconds */ +#define GPSWRAP 990U /* assume week count less than this in the previous epoch */ +#define GPSWEEKS 1024U /* number of weeks until the GPS epch rolls over */ + /* * state flags */ @@ -127,14 +134,14 @@ extern unsigned int splclock P((void)); /* * optional status information */ -#define PARSEB_ALTERNATE 0x00001000 /* alternate antenna used */ +#define PARSEB_CALLBIT 0x00001000 /* "call bit" used to signalize irregularities in the control facilities */ #define PARSEB_POSITION 0x00002000 /* position available */ #define PARSEB_MESSAGE 0x00004000 /* addtitional message data */ /* * feature information */ #define PARSEB_S_LEAP 0x00010000 /* supports LEAP */ -#define PARSEB_S_ANTENNA 0x00020000 /* supports antenna information */ +#define PARSEB_S_CALLBIT 0x00020000 /* supports callbit information */ #define PARSEB_S_PPS 0x00040000 /* supports PPS time stamping */ #define PARSEB_S_POSITION 0x00080000 /* supports position information (GPS) */ @@ -145,7 +152,7 @@ extern unsigned int splclock P((void)); #define PARSEB_PPS 0x20000000 /* valid PPS sample */ #define PARSE_TCINFO (PARSEB_ANNOUNCE|PARSEB_POWERUP|PARSEB_NOSYNC|PARSEB_DST|\ - PARSEB_UTC|PARSEB_LEAPS|PARSEB_ALTERNATE|PARSEB_S_LEAP|\ + PARSEB_UTC|PARSEB_LEAPS|PARSEB_CALLBIT|PARSEB_S_LEAP|\ PARSEB_S_LOCATION|PARSEB_TIMECODE|PARSEB_MESSAGE) #define PARSE_POWERUP(x) ((x) & PARSEB_POWERUP) @@ -156,11 +163,11 @@ extern unsigned int splclock P((void)); #define PARSE_UTC(x) ((x) & PARSEB_UTC) #define PARSE_LEAPADD(x) (PARSE_SYNC(x) && (((x) & PARSEB_LEAPS) == PARSEB_LEAPADD)) #define PARSE_LEAPDEL(x) (PARSE_SYNC(x) && (((x) & PARSEB_LEAPS) == PARSEB_LEAPDEL)) -#define PARSE_ALTERNATE(x) ((x) & PARSEB_ALTERNATE) +#define PARSE_CALLBIT(x) ((x) & PARSEB_CALLBIT) #define PARSE_LEAPSECOND(x) (PARSE_SYNC(x) && ((x) & PARSEB_LEAP_SECOND)) #define PARSE_S_LEAP(x) ((x) & PARSEB_S_LEAP) -#define PARSE_S_ANTENNA(x) ((x) & PARSEB_S_ANTENNA) +#define PARSE_S_CALLBIT(x) ((x) & PARSEB_S_CALLBIT) #define PARSE_S_PPS(x) ((x) & PARSEB_S_PPS) #define PARSE_S_POSITION(x) ((x) & PARSEB_S_POSITION) @@ -229,13 +236,13 @@ typedef struct parsetime parsetime_t; #define PARSE_IO_CSIZE 0x00000003 #define PARSE_IO_CS5 0x00000000 #define PARSE_IO_CS6 0x00000001 -#define PARSE_IO_CS7 0x00000002 -#define PARSE_IO_CS8 0x00000003 +#define PARSE_IO_CS7 0x00000002 +#define PARSE_IO_CS8 0x00000003 /* * ioctl structure */ -union parsectl +union parsectl { struct parsegettc { @@ -258,7 +265,7 @@ union parsectl u_long parse_cs; /* character size (needed for stripping) */ } parsesetcs; }; - + typedef union parsectl parsectl_t; /*------ for conversion routines --------*/ @@ -266,7 +273,7 @@ typedef union parsectl parsectl_t; struct parse /* parse module local data */ { int parse_flags; /* operation and current status flags */ - + int parse_ioflags; /* io handling flags (5-8 Bit control currently) */ /* @@ -286,7 +293,7 @@ struct parse /* parse module local data */ char *parse_ldata; /* last data buffer */ unsigned short parse_ldsize; /* last data buffer length */ u_long parse_badformat; /* number of unparsable pakets */ - + timestamp_t parse_lastchar; /* last time a character was received */ parsetime_t parse_dtime; /* external data prototype */ }; @@ -337,15 +344,19 @@ typedef struct clocktime clocktime_t; #define SYNC_ZERO 0x00 #define SYNC_ONE 0x01 +typedef u_long parse_inp_fnc_t(parse_t *, char, timestamp_t *); +typedef u_long parse_cvt_fnc_t(unsigned char *, int, struct format *, clocktime_t *, void *); +typedef u_long parse_pps_fnc_t(parse_t *, int, timestamp_t *); + struct clockformat { /* special input protocol - implies fixed format */ - u_long (*input) P((parse_t *, unsigned int, timestamp_t *)); + parse_inp_fnc_t *input; /* conversion routine */ - u_long (*convert) P((unsigned char *, int, struct format *, clocktime_t *, void *)); + parse_cvt_fnc_t *convert; /* routine for handling RS232 sync events (time stamps) */ /* PPS input routine */ - u_long (*syncpps) P((parse_t *, int, timestamp_t *)); + parse_pps_fnc_t *syncpps; /* time code synthesizer */ void *data; /* local parameters */ @@ -359,30 +370,30 @@ typedef struct clockformat clockformat_t; /* * parse interface */ -extern int parse_ioinit P((parse_t *)); -extern void parse_ioend P((parse_t *)); -extern int parse_ioread P((parse_t *, unsigned int, timestamp_t *)); -extern int parse_iopps P((parse_t *, int, timestamp_t *)); -extern void parse_iodone P((parse_t *)); -extern int parse_timecode P((parsectl_t *, parse_t *)); -extern int parse_getfmt P((parsectl_t *, parse_t *)); -extern int parse_setfmt P((parsectl_t *, parse_t *)); -extern int parse_setcs P((parsectl_t *, parse_t *)); - -extern unsigned int parse_restart P((parse_t *, unsigned int)); -extern unsigned int parse_addchar P((parse_t *, unsigned int)); -extern unsigned int parse_end P((parse_t *)); - -extern int Strok P((const unsigned char *, const unsigned char *)); -extern int Stoi P((const unsigned char *, long *, int)); - -extern time_t parse_to_unixtime P((clocktime_t *, u_long *)); -extern u_long updatetimeinfo P((parse_t *, u_long)); -extern void syn_simple P((parse_t *, timestamp_t *, struct format *, u_long)); -extern u_long pps_simple P((parse_t *, int, timestamp_t *)); -extern u_long pps_one P((parse_t *, int, timestamp_t *)); -extern u_long pps_zero P((parse_t *, int, timestamp_t *)); -extern int parse_timedout P((parse_t *, timestamp_t *, struct timeval *)); +extern int parse_ioinit (parse_t *); +extern void parse_ioend (parse_t *); +extern int parse_ioread (parse_t *, char, timestamp_t *); +extern int parse_iopps (parse_t *, int, timestamp_t *); +extern void parse_iodone (parse_t *); +extern int parse_timecode (parsectl_t *, parse_t *); +extern int parse_getfmt (parsectl_t *, parse_t *); +extern int parse_setfmt (parsectl_t *, parse_t *); +extern int parse_setcs (parsectl_t *, parse_t *); + +extern unsigned int parse_restart (parse_t *, char); +extern unsigned int parse_addchar (parse_t *, char); +extern unsigned int parse_end (parse_t *); + +extern int Strok (const unsigned char *, const unsigned char *); +extern int Stoi (const unsigned char *, long *, int); + +extern time_t parse_to_unixtime (clocktime_t *, u_long *); +extern u_long updatetimeinfo (parse_t *, u_long); +extern void syn_simple (parse_t *, timestamp_t *, struct format *, u_long); +extern parse_pps_fnc_t pps_simple; +extern parse_pps_fnc_t pps_one; +extern parse_pps_fnc_t pps_zero; +extern int parse_timedout (parse_t *, timestamp_t *, struct timeval *); #endif diff --git a/contrib/ntp/include/parse_conf.h b/contrib/ntp/include/parse_conf.h index 319dd543c..d17d616a4 100644 --- a/contrib/ntp/include/parse_conf.h +++ b/contrib/ntp/include/parse_conf.h @@ -4,7 +4,7 @@ * parse_conf.h,v 4.7 2005/06/25 10:58:45 kardel RELEASE_20050625_A * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -41,13 +41,13 @@ /* * field location structure */ -#define O_DAY 0 +#define O_DAY 0 #define O_MONTH 1 -#define O_YEAR 2 -#define O_HOUR 3 -#define O_MIN 4 -#define O_SEC 5 -#define O_WDAY 6 +#define O_YEAR 2 +#define O_HOUR 3 +#define O_MIN 4 +#define O_SEC 5 +#define O_WDAY 6 #define O_FLAGS 7 #define O_ZONE 8 #define O_UTCHOFFSET 9 diff --git a/contrib/ntp/include/rc_cmdlength.h b/contrib/ntp/include/rc_cmdlength.h new file mode 100644 index 000000000..87947573d --- /dev/null +++ b/contrib/ntp/include/rc_cmdlength.h @@ -0,0 +1,2 @@ + +extern size_t remoteconfig_cmdlength( const char *src_buf, const char *src_end ); diff --git a/contrib/ntp/include/recvbuff.h b/contrib/ntp/include/recvbuff.h index 771b90b94..92188f599 100644 --- a/contrib/ntp/include/recvbuff.h +++ b/contrib/ntp/include/recvbuff.h @@ -1,15 +1,10 @@ -#if !defined __recvbuff_h -#define __recvbuff_h - -#ifdef HAVE_CONFIG_H -# include -#endif +#ifndef RECVBUFF_H +#define RECVBUFF_H #include "ntp.h" -#include "ntp_fp.h" -#include "ntp_types.h" +#include "ntp_net.h" +#include "ntp_lists.h" -#include #include /* @@ -22,14 +17,14 @@ #if defined HAVE_IO_COMPLETION_PORT # include "ntp_iocompletionport.h" -#include "ntp_timer.h" +# include "ntp_timer.h" # define RECV_BLOCK_IO() EnterCriticalSection(&RecvCritSection) # define RECV_UNBLOCK_IO() LeaveCriticalSection(&RecvCritSection) /* Return the event which is set when items are added to the full list */ -extern HANDLE get_recv_buff_event P((void)); +extern HANDLE get_recv_buff_event(void); #else # define RECV_BLOCK_IO() # define RECV_UNBLOCK_IO() @@ -52,41 +47,40 @@ extern HANDLE get_recv_buff_event P((void)); typedef struct recvbuf recvbuf_t; struct recvbuf { - ISC_LINK(recvbuf_t) link; + recvbuf_t * link; /* next in list */ union { - struct sockaddr_storage X_recv_srcadr; - caddr_t X_recv_srcclock; - struct peer *X_recv_peer; + sockaddr_u X_recv_srcadr; + caddr_t X_recv_srcclock; + struct peer * X_recv_peer; } X_from_where; -#define recv_srcadr X_from_where.X_recv_srcadr -#define recv_srcclock X_from_where.X_recv_srcclock -#define recv_peer X_from_where.X_recv_peer -#if defined HAVE_IO_COMPLETION_PORT - WSABUF wsabuff; +#define recv_srcadr X_from_where.X_recv_srcadr +#define recv_srcclock X_from_where.X_recv_srcclock +#define recv_peer X_from_where.X_recv_peer +#ifndef HAVE_IO_COMPLETION_PORT + sockaddr_u srcadr; /* where packet came from */ #else - struct sockaddr_storage srcadr; /* where packet came from */ + int recv_srcadr_len;/* filled in on completion */ #endif - int src_addr_len; /* source address length */ - struct interface *dstadr; /* interface datagram arrived thru */ - SOCKET fd; /* fd on which it was received */ - int msg_flags; /* Flags received about the packet */ - l_fp recv_time; /* time of arrival */ - void (*receiver) P((struct recvbuf *)); /* routine to receive buffer */ - int recv_length; /* number of octets received */ + endpt * dstadr; /* address pkt arrived on */ + SOCKET fd; /* fd on which it was received */ + int msg_flags; /* Flags received about the packet */ + l_fp recv_time; /* time of arrival */ + void (*receiver)(struct recvbuf *); /* callback */ + int recv_length; /* number of octets received */ union { - struct pkt X_recv_pkt; - u_char X_recv_buffer[RX_BUFF_SIZE]; + struct pkt X_recv_pkt; + u_char X_recv_buffer[RX_BUFF_SIZE]; } recv_space; - int used; -#define recv_pkt recv_space.X_recv_pkt -#define recv_buffer recv_space.X_recv_buffer +#define recv_pkt recv_space.X_recv_pkt +#define recv_buffer recv_space.X_recv_buffer + int used; /* reference count */ }; -extern void init_recvbuff P((int)); +extern void init_recvbuff(int); /* freerecvbuf - make a single recvbuf available for reuse */ -extern void freerecvbuf P((struct recvbuf *)); +extern void freerecvbuf(struct recvbuf *); /* Get a free buffer (typically used so an async * read can directly place data into the buffer @@ -94,30 +88,36 @@ extern void freerecvbuf P((struct recvbuf *)); * The buffer is removed from the free list. Make sure * you put it back with freerecvbuf() or */ -extern struct recvbuf *get_free_recv_buffer P((void)); /* signal safe - no malloc */ -extern struct recvbuf *get_free_recv_buffer_alloc P((void)); /* signal unsafe - may malloc */ + +/* signal safe - no malloc */ +extern struct recvbuf *get_free_recv_buffer(void); +/* signal unsafe - may malloc */ +extern struct recvbuf *get_free_recv_buffer_alloc(void); /* Add a buffer to the full list */ -extern void add_full_recv_buffer P((struct recvbuf *)); - -/*extern void process_recv_buffers P((void)); */ +extern void add_full_recv_buffer(struct recvbuf *); /* number of recvbufs on freelist */ -extern u_long free_recvbuffs P((void)); -extern u_long full_recvbuffs P((void)); -extern u_long total_recvbuffs P((void)); -extern u_long lowater_additions P((void)); +extern u_long free_recvbuffs(void); +extern u_long full_recvbuffs(void); +extern u_long total_recvbuffs(void); +extern u_long lowater_additions(void); /* Returns the next buffer in the full list. * */ -extern struct recvbuf *get_full_recv_buffer P((void)); +extern struct recvbuf *get_full_recv_buffer(void); /* - * Checks to see if there are buffers to process + * purge_recv_buffers_for_fd() - purges any previously-received input + * from a given file descriptor. */ -extern isc_boolean_t has_full_recv_buffer P((void)); +extern void purge_recv_buffers_for_fd(SOCKET); -#endif /* defined __recvbuff_h */ +/* + * Checks to see if there are buffers to process + */ +extern isc_boolean_t has_full_recv_buffer(void); +#endif /* RECVBUFF_H */ diff --git a/contrib/ntp/include/refclock_atom.h b/contrib/ntp/include/refclock_atom.h new file mode 100644 index 000000000..452e933a8 --- /dev/null +++ b/contrib/ntp/include/refclock_atom.h @@ -0,0 +1,15 @@ +/* + * Definitions for the atom driver and its friends + */ +#undef NANOSECOND /* some systems define it differently */ +#define NANOSECOND 1000000000 /* one second (ns) */ + +struct refclock_atom { + pps_handle_t handle; + pps_params_t pps_params; + struct timespec ts; +}; + +extern int refclock_ppsapi(int, struct refclock_atom *); +extern int refclock_params(int, struct refclock_atom *); +extern int refclock_pps(struct peer *, struct refclock_atom *, int); diff --git a/contrib/ntp/include/refidsmear.h b/contrib/ntp/include/refidsmear.h new file mode 100644 index 000000000..9c0f24529 --- /dev/null +++ b/contrib/ntp/include/refidsmear.h @@ -0,0 +1,3 @@ + +extern l_fp convertRefIDToLFP(uint32_t r); +extern uint32_t convertLFPToRefID(l_fp num); diff --git a/contrib/ntp/include/rsa_md5.h b/contrib/ntp/include/rsa_md5.h deleted file mode 100644 index 824164760..000000000 --- a/contrib/ntp/include/rsa_md5.h +++ /dev/null @@ -1,51 +0,0 @@ -/* MD5.H - header file for MD5C.C - */ - -/* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All - rights reserved. - - License to copy and use this software is granted provided that it - is identified as the "RSA Data Security, Inc. MD5 Message-Digest - Algorithm" in all material mentioning or referencing this software - or this function. - - License is also granted to make and use derivative works provided - that such works are identified as "derived from the RSA Data - Security, Inc. MD5 Message-Digest Algorithm" in all material - mentioning or referencing the derived work. - - RSA Data Security, Inc. makes no representations concerning either - the merchantability of this software or the suitability of this - software for any particular purpose. It is provided "as is" - without express or implied warranty of any kind. - - These notices must be retained in any copies of any part of this - documentation and/or software. - */ - -#ifndef _MD5_H_ -#define _MD5_H_ 1 - -#ifdef __cplusplus -extern "C" { -#endif - -/*#include "global.h" */ - -/* MD5 context. */ -typedef struct { - UINT4 state[4]; /* state (ABCD) */ - UINT4 count[2]; /* number of bits, modulo 2^64 (lsb first) */ - unsigned char buffer[64]; /* input buffer */ -} MD5_CTX; - -void MD5Init PROTO_LIST ((MD5_CTX *)); -void MD5Update PROTO_LIST - ((MD5_CTX *, unsigned char *, unsigned int)); -void MD5Final PROTO_LIST ((unsigned char [16], MD5_CTX *)); - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/contrib/ntp/include/ssl_applink.c b/contrib/ntp/include/ssl_applink.c new file mode 100644 index 000000000..ba1f4a8fe --- /dev/null +++ b/contrib/ntp/include/ssl_applink.c @@ -0,0 +1,74 @@ +/* + * include/ssl_applink.c -- common NTP code for openssl/applink.c + * + * Each program which uses OpenSSL should include this file in _one_ + * of its source files and call ssl_applink() before any OpenSSL + * functions. + */ + +#if defined(OPENSSL) && defined(SYS_WINNT) +# ifdef _MSC_VER +# pragma warning(push) +# pragma warning(disable: 4152) +# endif +# include +# ifdef _MSC_VER +# pragma warning(pop) +# endif +#endif + +#if defined(OPENSSL) && defined(_MSC_VER) && defined(_DEBUG) +#define WRAP_DBG_MALLOC +#endif + +#ifdef WRAP_DBG_MALLOC +void *wrap_dbg_malloc(size_t s, const char *f, int l); +void *wrap_dbg_realloc(void *p, size_t s, const char *f, int l); +void wrap_dbg_free(void *p); +#endif + + +#if defined(OPENSSL) && defined(SYS_WINNT) +void ssl_applink(void); + +void +ssl_applink(void) +{ +#ifdef WRAP_DBG_MALLOC + CRYPTO_set_mem_ex_functions(wrap_dbg_malloc, wrap_dbg_realloc, wrap_dbg_free); +#else + CRYPTO_malloc_init(); +#endif +} +#else /* !OPENSSL || !SYS_WINNT */ +#define ssl_applink() do {} while (0) +#endif + + +#ifdef WRAP_DBG_MALLOC +/* + * OpenSSL malloc overriding uses different parameters + * for DEBUG malloc/realloc/free (lacking block type). + * Simple wrappers convert. + */ +void *wrap_dbg_malloc(size_t s, const char *f, int l) +{ + void *ret; + + ret = _malloc_dbg(s, _NORMAL_BLOCK, f, l); + return ret; +} + +void *wrap_dbg_realloc(void *p, size_t s, const char *f, int l) +{ + void *ret; + + ret = _realloc_dbg(p, s, _NORMAL_BLOCK, f, l); + return ret; +} + +void wrap_dbg_free(void *p) +{ + _free_dbg(p, _NORMAL_BLOCK); +} +#endif /* WRAP_DBG_MALLOC */ diff --git a/contrib/ntp/include/timepps-SCO.h b/contrib/ntp/include/timepps-SCO.h index 130a153c6..ce9052e24 100644 --- a/contrib/ntp/include/timepps-SCO.h +++ b/contrib/ntp/include/timepps-SCO.h @@ -3,7 +3,7 @@ * Copyright (c) David L. Mills 1999-2000 * * * * Permission to use, copy, modify, and distribute this software and * - * its documentation for any purpose and without fee is hereby * + * its documentation for any purpose and with or without fee is hereby * * granted, provided that the above copyright notice appears in all * * copies and that both the copyright notice and this permission * * notice appear in supporting documentation, and that the name * diff --git a/contrib/ntp/include/timepps-Solaris.h b/contrib/ntp/include/timepps-Solaris.h index da8fd9403..bcae382fe 100644 --- a/contrib/ntp/include/timepps-Solaris.h +++ b/contrib/ntp/include/timepps-Solaris.h @@ -1,9 +1,9 @@ /*********************************************************************** * * - * Copyright (c) David L. Mills 1999-2000 * + * Copyright (c) David L. Mills 1999-2009 * * * * Permission to use, copy, modify, and distribute this software and * - * its documentation for any purpose and without fee is hereby * + * its documentation for any purpose and with or without fee is hereby * * granted, provided that the above copyright notice appears in all * * copies and that both the copyright notice and this permission * * notice appear in supporting documentation, and that the name * @@ -178,26 +178,52 @@ typedef struct pps_params { #define assert_offset_ntpfp assert_off_tu.ntpfp #define clear_offset_ntpfp clear_off_tu.ntpfp +/* addition of NTP fixed-point format */ + +#define NTPFP_M_ADD(r_i, r_f, a_i, a_f) /* r += a */ \ + do { \ + register u_int32 lo_tmp; \ + register u_int32 hi_tmp; \ + \ + lo_tmp = ((r_f) & 0xffff) + ((a_f) & 0xffff); \ + hi_tmp = (((r_f) >> 16) & 0xffff) + (((a_f) >> 16) & 0xffff); \ + if (lo_tmp & 0x10000) \ + hi_tmp++; \ + (r_f) = ((hi_tmp & 0xffff) << 16) | (lo_tmp & 0xffff); \ + \ + (r_i) += (a_i); \ + if (hi_tmp & 0x10000) \ + (r_i)++; \ + } while (0) + +#define NTPFP_L_ADDS(r, a) NTPFP_M_ADD((r)->integral, (r)->fractional, \ + (int)(a)->integral, (a)->fractional) + /* * The following definitions are architecture-dependent */ #define PPS_CAP (PPS_CAPTUREASSERT | PPS_OFFSETASSERT | PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP) -#define PPS_RO (PPS_CANWAIT | PPS_CANPOLL | PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP) +#define PPS_RO (PPS_CANWAIT | PPS_CANPOLL) typedef struct { int filedes; /* file descriptor */ pps_params_t params; /* PPS parameters set by user */ } pps_unit_t; -typedef pps_unit_t* pps_handle_t; /* pps handlebars */ - /* *------ Here begins the implementation-specific part! ------ */ #include +/* + * pps handlebars, which are required to be an opaque scalar. This + * implementation uses the handle as a pointer so it must be large + * enough. uintptr_t is as large as a pointer. + */ +typedef uintptr_t pps_handle_t; + /* * create PPS handle from file descriptor */ @@ -208,6 +234,7 @@ time_pps_create( pps_handle_t *handle /* returned handle */ ) { + pps_unit_t *punit; int one = 1; /* @@ -228,16 +255,18 @@ time_pps_create( * Allocate and initialize default unit structure. */ - *handle = malloc(sizeof(pps_unit_t)); - if (!(*handle)) { - errno = EBADF; + punit = malloc(sizeof(*punit)); + if (NULL == punit) { + errno = ENOMEM; return (-1); /* what, no memory? */ } - memset(*handle, 0, sizeof(pps_unit_t)); - (*handle)->filedes = filedes; - (*handle)->params.api_version = PPS_API_VERS_1; - (*handle)->params.mode = PPS_CAPTUREASSERT | PPS_TSFMT_TSPEC; + memset(punit, 0, sizeof(*punit)); + punit->filedes = filedes; + punit->params.api_version = PPS_API_VERS_1; + punit->params.mode = PPS_CAPTUREASSERT | PPS_TSFMT_TSPEC; + + *handle = (pps_handle_t)punit; return (0); } @@ -250,6 +279,8 @@ time_pps_destroy( pps_handle_t handle ) { + pps_unit_t *punit; + /* * Check for valid arguments and detach PPS signal. */ @@ -258,7 +289,8 @@ time_pps_destroy( errno = EBADF; return (-1); /* bad handle */ } - free(handle); + punit = (pps_unit_t *)handle; + free(punit); return (0); } @@ -272,7 +304,8 @@ time_pps_setparams( const pps_params_t *params ) { - int mode, mode_in; + pps_unit_t * punit; + int mode, mode_in; /* * Check for valid arguments and set parameters. */ @@ -302,14 +335,42 @@ time_pps_setparams( */ mode_in = params->mode; + punit = (pps_unit_t *)handle; + + /* + * Only one of the time formats may be selected + * if a nonzero assert offset is supplied. + */ + if ((mode_in & (PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP)) == + (PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP)) { + + if (punit->params.assert_offset.tv_sec || + punit->params.assert_offset.tv_nsec) { + + errno = EINVAL; + return(-1); + } + + /* + * If no offset was specified but both time + * format flags are used consider it harmless + * but turn off PPS_TSFMT_NTPFP so getparams + * will not show both formats lit. + */ + mode_in &= ~PPS_TSFMT_NTPFP; + } /* turn off read-only bits */ mode_in &= ~PPS_RO; - /* test remaining bits, should only have captureassert and/or offsetassert */ + /* + * test remaining bits, should only have captureassert, + * offsetassert, and/or timestamp format bits. + */ - if (mode_in & ~(PPS_CAPTUREASSERT | PPS_OFFSETASSERT)) { + if (mode_in & ~(PPS_CAPTUREASSERT | PPS_OFFSETASSERT | + PPS_TSFMT_TSPEC | PPS_TSFMT_NTPFP)) { errno = EOPNOTSUPP; return(-1); } @@ -318,10 +379,10 @@ time_pps_setparams( * ok, ready to go. */ - mode = handle->params.mode; - memcpy(&handle->params, params, sizeof(pps_params_t)); - handle->params.api_version = PPS_API_VERS_1; - handle->params.mode = mode | mode_in; + mode = punit->params.mode; + memcpy(&punit->params, params, sizeof(punit->params)); + punit->params.api_version = PPS_API_VERS_1; + punit->params.mode = mode | mode_in; return (0); } @@ -335,6 +396,8 @@ time_pps_getparams( pps_params_t *params ) { + pps_unit_t * punit; + /* * Check for valid arguments and get parameters. */ @@ -349,11 +412,12 @@ time_pps_getparams( return (-1); /* bad argument */ } - memcpy(params, &handle->params, sizeof(pps_params_t)); + punit = (pps_unit_t *)handle; + memcpy(params, &punit->params, sizeof(*params)); return (0); } -/* ( +/* * get capabilities for handle */ @@ -397,7 +461,8 @@ time_pps_fetch( u_int serial; } ev; - pps_info_t infobuf; + pps_info_t infobuf; + pps_unit_t * punit; /* * Check for valid arguments and fetch timestamps @@ -419,56 +484,58 @@ time_pps_fetch( */ memset(&infobuf, 0, sizeof(infobuf)); + punit = (pps_unit_t *)handle; /* * if not captureassert, nothing to return. */ - if (!handle->params.mode & PPS_CAPTUREASSERT) { - memcpy(ppsinfo, &infobuf, sizeof(pps_info_t)); + if (!punit->params.mode & PPS_CAPTUREASSERT) { + memcpy(ppsinfo, &infobuf, sizeof(*ppsinfo)); return (0); } - if (ioctl(handle->filedes, TIOCGPPSEV, (caddr_t) &ev) < 0) { + if (ioctl(punit->filedes, TIOCGPPSEV, (caddr_t) &ev) < 0) { perror("time_pps_fetch:"); errno = EOPNOTSUPP; return(-1); } - /* - * Apply offsets as specified. Note that only assert timestamps - * are captured by this interface. - */ - infobuf.assert_sequence = ev.serial; infobuf.assert_timestamp.tv_sec = ev.tv.tv_sec; infobuf.assert_timestamp.tv_nsec = ev.tv.tv_usec * 1000; - if (handle->params.mode & PPS_OFFSETASSERT) { - infobuf.assert_timestamp.tv_sec += handle->params.assert_offset.tv_sec; - infobuf.assert_timestamp.tv_nsec += handle->params.assert_offset.tv_nsec; - PPS_NORMALIZE(infobuf.assert_timestamp); - } - /* - * Translate to specified format + * Translate to specified format then apply offset */ switch (tsformat) { case PPS_TSFMT_TSPEC: - break; /* timespec format requires no translation */ + /* timespec format requires no conversion */ + if (punit->params.mode & PPS_OFFSETASSERT) { + infobuf.assert_timestamp.tv_sec += + punit->params.assert_offset.tv_sec; + infobuf.assert_timestamp.tv_nsec += + punit->params.assert_offset.tv_nsec; + PPS_NORMALIZE(infobuf.assert_timestamp); + } + break; - case PPS_TSFMT_NTPFP: /* NTP format requires conversion to fraction form */ + case PPS_TSFMT_NTPFP: + /* NTP format requires conversion to fraction form */ PPS_TSPECTONTP(infobuf.assert_timestamp_ntpfp); - break; + if (punit->params.mode & PPS_OFFSETASSERT) + NTPFP_L_ADDS(&infobuf.assert_timestamp_ntpfp, + &punit->params.assert_offset_ntpfp); + break; default: errno = EINVAL; return (-1); } - infobuf.current_mode = handle->params.mode; - memcpy(ppsinfo, &infobuf, sizeof(pps_info_t)); + infobuf.current_mode = punit->params.mode; + memcpy(ppsinfo, &infobuf, sizeof(*ppsinfo)); return (0); } @@ -480,7 +547,8 @@ static inline int time_pps_kcbind( pps_handle_t handle, const int kernel_consumer, - const int edge, const int tsformat + const int edge, + const int tsformat ) { /* diff --git a/contrib/ntp/include/timepps-SunOS.h b/contrib/ntp/include/timepps-SunOS.h index 6cd166e69..4e4c05e0f 100644 --- a/contrib/ntp/include/timepps-SunOS.h +++ b/contrib/ntp/include/timepps-SunOS.h @@ -3,7 +3,7 @@ * Copyright (c) David L. Mills 1999-2000 * * * * Permission to use, copy, modify, and distribute this software and * - * its documentation for any purpose and without fee is hereby * + * its documentation for any purpose and with or without fee is hereby * * granted, provided that the above copyright notice appears in all * * copies and that both the copyright notice and this permission * * notice appear in supporting documentation, and that the name * diff --git a/contrib/ntp/include/timespecops.h b/contrib/ntp/include/timespecops.h new file mode 100644 index 000000000..fa32e42a6 --- /dev/null +++ b/contrib/ntp/include/timespecops.h @@ -0,0 +1,393 @@ +/* + * timespecops.h -- calculations on 'struct timespec' values + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * + * Rationale + * --------- + * + * Doing basic arithmetic on a 'struct timespec' is not exceedingly + * hard, but it requires tedious and repetitive code to keep the result + * normalised. We consider a timespec normalised when the nanosecond + * fraction is in the interval [0 .. 10^9[ ; there are multiple value + * pairs of seconds and nanoseconds that denote the same time interval, + * but the normalised representation is unique. No two different + * intervals can have the same normalised representation. + * + * Another topic is the representation of negative time intervals. + * There's more than one way to this, since both the seconds and the + * nanoseconds of a timespec are signed values. IMHO, the easiest way is + * to use a complement representation where the nanoseconds are still + * normalised, no matter what the sign of the seconds value. This makes + * normalisation easier, since the sign of the integer part is + * irrelevant, and it removes several sign decision cases during the + * calculations. + * + * As long as no signed integer overflow can occur with the nanosecond + * part of the operands, all operations work as expected and produce a + * normalised result. + * + * The exception to this are functions fix a '_fast' suffix, which do no + * normalisation on input data and therefore expect the input data to be + * normalised. + * + * Input and output operands may overlap; all input is consumed before + * the output is written to. + */ +#ifndef TIMESPECOPS_H +#define TIMESPECOPS_H + +#include +#include +#include + +#include "ntp.h" +#include "timetoa.h" + + +/* nanoseconds per second */ +#define NANOSECONDS 1000000000 + +/* predicate: returns TRUE if the nanoseconds are in nominal range */ +#define timespec_isnormal(x) \ + ((x)->tv_nsec >= 0 && (x)->tv_nsec < NANOSECONDS) + +/* predicate: returns TRUE if the nanoseconds are out-of-bounds */ +#define timespec_isdenormal(x) (!timespec_isnormal(x)) + +/* conversion between l_fp fractions and nanoseconds */ +#ifdef HAVE_U_INT64 +# define FTOTVN(tsf) \ + ((int32) \ + (((u_int64)(tsf) * NANOSECONDS + 0x80000000) >> 32)) +# define TVNTOF(tvu) \ + ((u_int32) \ + ((((u_int64)(tvu) << 32) + NANOSECONDS / 2) / \ + NANOSECONDS)) +#else +# define NSECFRAC (FRAC / NANOSECONDS) +# define FTOTVN(tsf) \ + ((int32)((tsf) / NSECFRAC + 0.5)) +# define TVNTOF(tvu) \ + ((u_int32)((tvu) * NSECFRAC + 0.5)) +#endif + + + +/* make sure nanoseconds are in nominal range */ +static inline struct timespec +normalize_tspec( + struct timespec x + ) +{ +#if SIZEOF_LONG > 4 + long z; + + /* + * tv_nsec is of type 'long', and on a 64-bit machine using only + * loops becomes prohibitive once the upper 32 bits get + * involved. On the other hand, division by constant should be + * fast enough; so we do a division of the nanoseconds in that + * case. The floor adjustment step follows with the standard + * normalisation loops. And labs() is intentionally not used + * here: it has implementation-defined behaviour when applied + * to LONG_MIN. + */ + if (x.tv_nsec < -3l * NANOSECONDS || + x.tv_nsec > 3l * NANOSECONDS) { + z = x.tv_nsec / NANOSECONDS; + x.tv_nsec -= z * NANOSECONDS; + x.tv_sec += z; + } +#endif + /* since 10**9 is close to 2**32, we don't divide but do a + * normalisation in a loop; this takes 3 steps max, and should + * outperform a division even if the mul-by-inverse trick is + * employed. */ + if (x.tv_nsec < 0) + do { + x.tv_nsec += NANOSECONDS; + x.tv_sec--; + } while (x.tv_nsec < 0); + else if (x.tv_nsec >= NANOSECONDS) + do { + x.tv_nsec -= NANOSECONDS; + x.tv_sec++; + } while (x.tv_nsec >= NANOSECONDS); + + return x; +} + +/* x = a + b */ +static inline struct timespec +add_tspec( + struct timespec a, + struct timespec b + ) +{ + struct timespec x; + + x = a; + x.tv_sec += b.tv_sec; + x.tv_nsec += b.tv_nsec; + + return normalize_tspec(x); +} + +/* x = a + b, b is fraction only */ +static inline struct timespec +add_tspec_ns( + struct timespec a, + long b + ) +{ + struct timespec x; + + x = a; + x.tv_nsec += b; + + return normalize_tspec(x); +} + +/* x = a - b */ +static inline struct timespec +sub_tspec( + struct timespec a, + struct timespec b + ) +{ + struct timespec x; + + x = a; + x.tv_sec -= b.tv_sec; + x.tv_nsec -= b.tv_nsec; + + return normalize_tspec(x); +} + +/* x = a - b, b is fraction only */ +static inline struct timespec +sub_tspec_ns( + struct timespec a, + long b + ) +{ + struct timespec x; + + x = a; + x.tv_nsec -= b; + + return normalize_tspec(x); +} + +/* x = -a */ +static inline struct timespec +neg_tspec( + struct timespec a + ) +{ + struct timespec x; + + x.tv_sec = -a.tv_sec; + x.tv_nsec = -a.tv_nsec; + + return normalize_tspec(x); +} + +/* x = abs(a) */ +static inline struct timespec +abs_tspec( + struct timespec a + ) +{ + struct timespec c; + + c = normalize_tspec(a); + if (c.tv_sec < 0) { + if (c.tv_nsec != 0) { + c.tv_sec = -c.tv_sec - 1; + c.tv_nsec = NANOSECONDS - c.tv_nsec; + } else { + c.tv_sec = -c.tv_sec; + } + } + + return c; +} + +/* + * compare previously-normalised a and b + * return 1 / 0 / -1 if a < / == / > b + */ +static inline int +cmp_tspec( + struct timespec a, + struct timespec b + ) +{ + int r; + + r = (a.tv_sec > b.tv_sec) - (a.tv_sec < b.tv_sec); + if (0 == r) + r = (a.tv_nsec > b.tv_nsec) - + (a.tv_nsec < b.tv_nsec); + + return r; +} + +/* + * compare possibly-denormal a and b + * return 1 / 0 / -1 if a < / == / > b + */ +static inline int +cmp_tspec_denorm( + struct timespec a, + struct timespec b + ) +{ + return cmp_tspec(normalize_tspec(a), normalize_tspec(b)); +} + +/* + * test previously-normalised a + * return 1 / 0 / -1 if a < / == / > 0 + */ +static inline int +test_tspec( + struct timespec a + ) +{ + int r; + + r = (a.tv_sec > 0) - (a.tv_sec < 0); + if (r == 0) + r = (a.tv_nsec > 0); + + return r; +} + +/* + * test possibly-denormal a + * return 1 / 0 / -1 if a < / == / > 0 + */ +static inline int +test_tspec_denorm( + struct timespec a + ) +{ + return test_tspec(normalize_tspec(a)); +} + +/* return LIB buffer ptr to string rep */ +static inline const char * +tspectoa( + struct timespec x + ) +{ + return format_time_fraction(x.tv_sec, x.tv_nsec, 9); +} + +/* + * convert to l_fp type, relative and absolute + */ + +/* convert from timespec duration to l_fp duration */ +static inline l_fp +tspec_intv_to_lfp( + struct timespec x + ) +{ + struct timespec v; + l_fp y; + + v = normalize_tspec(x); + y.l_uf = TVNTOF(v.tv_nsec); + y.l_i = (int32)v.tv_sec; + + return y; +} + +/* x must be UN*X epoch, output will be in NTP epoch */ +static inline l_fp +tspec_stamp_to_lfp( + struct timespec x + ) +{ + l_fp y; + + y = tspec_intv_to_lfp(x); + y.l_ui += JAN_1970; + + return y; +} + +/* convert from l_fp type, relative signed/unsigned and absolute */ +static inline struct timespec +lfp_intv_to_tspec( + l_fp x + ) +{ + struct timespec out; + l_fp absx; + int neg; + + neg = L_ISNEG(&x); + absx = x; + if (neg) { + L_NEG(&absx); + } + out.tv_nsec = FTOTVN(absx.l_uf); + out.tv_sec = absx.l_i; + if (neg) { + out.tv_sec = -out.tv_sec; + out.tv_nsec = -out.tv_nsec; + out = normalize_tspec(out); + } + + return out; +} + +static inline struct timespec +lfp_uintv_to_tspec( + l_fp x + ) +{ + struct timespec out; + + out.tv_nsec = FTOTVN(x.l_uf); + out.tv_sec = x.l_ui; + + return out; +} + +/* + * absolute (timestamp) conversion. Input is time in NTP epoch, output + * is in UN*X epoch. The NTP time stamp will be expanded around the + * pivot time *p or the current time, if p is NULL. + */ +static inline struct timespec +lfp_stamp_to_tspec( + l_fp x, + const time_t * p + ) +{ + struct timespec out; + vint64 sec; + + sec = ntpcal_ntp_to_time(x.l_ui, p); + out.tv_nsec = FTOTVN(x.l_uf); + + /* copying a vint64 to a time_t needs some care... */ +#if SIZEOF_TIME_T <= 4 + out.tv_sec = (time_t)sec.d_s.lo; +#elif defined(HAVE_INT64) + out.tv_sec = (time_t)sec.q_s; +#else + out.tv_sec = ((time_t)sec.d_s.hi << 32) | sec.d_s.lo; +#endif + + return out; +} + +#endif /* TIMESPECOPS_H */ diff --git a/contrib/ntp/include/timetoa.h b/contrib/ntp/include/timetoa.h new file mode 100644 index 000000000..259944907 --- /dev/null +++ b/contrib/ntp/include/timetoa.h @@ -0,0 +1,83 @@ +/* + * timetoa.h -- time_t related string formatting + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * + * Printing a 'time_t' has some portability pitfalls, due to it's opaque + * base type. The only requirement imposed by the standard is that it + * must be a numeric type. For all practical purposes it's a signed int, + * and 32 bits are common. + * + * Since the UN*X time epoch will cause a signed integer overflow for + * 32-bit signed int values in the year 2038, implementations slowly + * move to 64bit base types for time_t, even in 32-bit environments. In + * such an environment sizeof(time_t) could be bigger than sizeof(long) + * and the commonly used idiom of casting to long leads to truncation. + * + * As the printf() family has no standardised type specifier for time_t, + * guessing the right output format specifier is a bit troublesome and + * best done with the help of the preprocessor and "config.h". + */ +#ifndef TIMETOA_H +#define TIMETOA_H + +#include "ntp_fp.h" +#include "ntp_stdlib.h" +#include "ntp_unixtime.h" + +/* + * Given the size of time_t, guess what can be used as an unsigned value + * to hold a time_t and the printf() format specifcation. + * + * These should be used with the string constant concatenation feature + * of the compiler like this: + * + * printf("a time stamp: %" TIME_FORMAT " and more\n", a_time_t_value); + * + * It's not exactly nice, but there's not much leeway once we want to + * use the printf() family on time_t values. + */ + +#if SIZEOF_TIME_T <= SIZEOF_INT + +typedef unsigned int u_time; +#define TIME_FORMAT "d" +#define UTIME_FORMAT "u" + +#elif SIZEOF_TIME_T <= SIZEOF_LONG + +typedef unsigned long u_time; +#define TIME_FORMAT "ld" +#define UTIME_FORMAT "lu" + +#elif defined(SIZEOF_LONG_LONG) && SIZEOF_TIME_T <= SIZEOF_LONG_LONG + +typedef unsigned long long u_time; +#define TIME_FORMAT "lld" +#define UTIME_FORMAT "llu" + +#else +#include "GRONK: what size has a time_t here?" +#endif + +/* + * general fractional time stamp formatting. + * + * secs - integral seconds of time stamp + * frac - fractional units + * prec - log10 of units per second (3=milliseconds, 6=microseconds,..) + * or in other words: the count of decimal digits required. + * If prec is < 0, abs(prec) is taken for the precision and secs + * is treated as an unsigned value. + * + * The function will eventually normalise the fraction and adjust the + * seconds accordingly. + * + * This function uses the string buffer library for the return value, + * so do not keep the resulting pointers around. + */ +extern const char * +format_time_fraction(time_t secs, long frac, int prec); + +#endif /* !defined(TIMETOA_H) */ diff --git a/contrib/ntp/include/timevalops.h b/contrib/ntp/include/timevalops.h new file mode 100644 index 000000000..e873b8b80 --- /dev/null +++ b/contrib/ntp/include/timevalops.h @@ -0,0 +1,446 @@ +/* + * timevalops.h -- calculations on 'struct timeval' values + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * + * For a rationale look at 'timespecops.h'; we do the same here, but the + * normalisation keeps the microseconds in [0 .. 10^6[, of course. + */ +#ifndef TIMEVALOPS_H +#define TIMEVALOPS_H + +#include +#include + +#include "ntp.h" +#include "timetoa.h" + + +/* microseconds per second */ +#define MICROSECONDS 1000000 + +#ifndef HAVE_U_INT64 +# define USE_TSF_USEC_TABLES +#endif + +/* + * Convert usec to a time stamp fraction. + */ +#ifdef USE_TSF_USEC_TABLES +extern const u_int32 ustotslo[]; +extern const u_int32 ustotsmid[]; +extern const u_int32 ustotshi[]; + +# define TVUTOTSF(tvu, tsf) \ + ((tsf) = ustotslo[(tvu) & 0xff] \ + + ustotsmid[((tvu) >> 8) & 0xff] \ + + ustotshi[((tvu) >> 16) & 0xf]) +#else +# define TVUTOTSF(tvu, tsf) \ + ((tsf) = (u_int32) \ + ((((u_int64)(tvu) << 32) + MICROSECONDS / 2) / \ + MICROSECONDS)) +#endif + +/* + * Convert a time stamp fraction to microseconds. The time stamp + * fraction is assumed to be unsigned. + */ +#ifdef USE_TSF_USEC_TABLES +extern const u_int32 tstouslo[256]; +extern const u_int32 tstousmid[256]; +extern const u_int32 tstoushi[128]; + +/* + * TV_SHIFT is used to turn the table result into a usec value. To + * round, add in TV_ROUNDBIT before shifting. + */ +#define TV_SHIFT 3 +#define TV_ROUNDBIT 0x4 + +# define TSFTOTVU(tsf, tvu) \ + ((tvu) = (tstoushi[((tsf) >> 24) & 0xff] \ + + tstousmid[((tsf) >> 16) & 0xff] \ + + tstouslo[((tsf) >> 9) & 0x7f] \ + + TV_ROUNDBIT) >> TV_SHIFT) +#else +# define TSFTOTVU(tsf, tvu) \ + ((tvu) = (int32) \ + (((u_int64)(tsf) * MICROSECONDS + 0x80000000) >> 32)) +#endif + +/* + * Convert a struct timeval to a time stamp. + */ +#define TVTOTS(tv, ts) \ + do { \ + (ts)->l_ui = (u_long)(tv)->tv_sec; \ + TVUTOTSF((tv)->tv_usec, (ts)->l_uf); \ + } while (FALSE) + +#define sTVTOTS(tv, ts) \ + do { \ + int isneg = 0; \ + long usec; \ + (ts)->l_ui = (tv)->tv_sec; \ + usec = (tv)->tv_usec; \ + if (((tv)->tv_sec < 0) || ((tv)->tv_usec < 0)) { \ + usec = -usec; \ + (ts)->l_ui = -(ts)->l_ui; \ + isneg = 1; \ + } \ + TVUTOTSF(usec, (ts)->l_uf); \ + if (isneg) { \ + L_NEG((ts)); \ + } \ + } while (FALSE) + +/* + * Convert a time stamp to a struct timeval. The time stamp + * has to be positive. + */ +#define TSTOTV(ts, tv) \ + do { \ + (tv)->tv_sec = (ts)->l_ui; \ + TSFTOTVU((ts)->l_uf, (tv)->tv_usec); \ + if ((tv)->tv_usec == 1000000) { \ + (tv)->tv_sec++; \ + (tv)->tv_usec = 0; \ + } \ + } while (FALSE) + + +/* + * predicate: returns TRUE if the microseconds are in nominal range + * use like: int timeval_isnormal(const struct timeval *x) + */ +#define timeval_isnormal(x) \ + ((x)->tv_usec >= 0 && (x)->tv_usec < MICROSECONDS) + +/* + * Convert milliseconds to a time stamp fraction. Unused except for + * refclock_leitch.c, so accompanying lookup tables were removed in + * favor of reusing the microseconds conversion tables. + */ +#define MSUTOTSF(msu, tsf) TVUTOTSF((msu) * 1000, tsf) + +/* + * predicate: returns TRUE if the microseconds are out-of-bounds + * use like: int timeval_isdenormal(const struct timeval *x) + */ +#define timeval_isdenormal(x) (!timeval_isnormal(x)) + +/* make sure microseconds are in nominal range */ +static inline struct timeval +normalize_tval( + struct timeval x + ) +{ + long z; + + /* + * If the fraction becomes excessive denormal, we use division + * to do first partial normalisation. The normalisation loops + * following will do the remaining cleanup. Since the size of + * tv_usec has a peculiar definition by the standard the range + * check is coded manually. And labs() is intentionally not used + * here: it has implementation-defined behaviour when applied + * to LONG_MIN. + */ + if (x.tv_usec < -3l * MICROSECONDS || + x.tv_usec > 3l * MICROSECONDS ) { + z = x.tv_usec / MICROSECONDS; + x.tv_usec -= z * MICROSECONDS; + x.tv_sec += z; + } + + /* + * Do any remaining normalisation steps in loops. This takes 3 + * steps max, and should outperform a division even if the + * mul-by-inverse trick is employed. (It also does the floor + * division adjustment if the above division was executed.) + */ + if (x.tv_usec < 0) + do { + x.tv_usec += MICROSECONDS; + x.tv_sec--; + } while (x.tv_usec < 0); + else if (x.tv_usec >= MICROSECONDS) + do { + x.tv_usec -= MICROSECONDS; + x.tv_sec++; + } while (x.tv_usec >= MICROSECONDS); + + return x; +} + +/* x = a + b */ +static inline struct timeval +add_tval( + struct timeval a, + struct timeval b + ) +{ + struct timeval x; + + x = a; + x.tv_sec += b.tv_sec; + x.tv_usec += b.tv_usec; + + return normalize_tval(x); +} + +/* x = a + b, b is fraction only */ +static inline struct timeval +add_tval_us( + struct timeval a, + long b + ) +{ + struct timeval x; + + x = a; + x.tv_usec += b; + + return normalize_tval(x); +} + +/* x = a - b */ +static inline struct timeval +sub_tval( + struct timeval a, + struct timeval b + ) +{ + struct timeval x; + + x = a; + x.tv_sec -= b.tv_sec; + x.tv_usec -= b.tv_usec; + + return normalize_tval(x); +} + +/* x = a - b, b is fraction only */ +static inline struct timeval +sub_tval_us( + struct timeval a, + long b + ) +{ + struct timeval x; + + x = a; + x.tv_usec -= b; + + return normalize_tval(x); +} + +/* x = -a */ +static inline struct timeval +neg_tval( + struct timeval a + ) +{ + struct timeval x; + + x.tv_sec = -a.tv_sec; + x.tv_usec = -a.tv_usec; + + return normalize_tval(x); +} + +/* x = abs(a) */ +static inline struct timeval +abs_tval( + struct timeval a + ) +{ + struct timeval c; + + c = normalize_tval(a); + if (c.tv_sec < 0) { + if (c.tv_usec != 0) { + c.tv_sec = -c.tv_sec - 1; + c.tv_usec = MICROSECONDS - c.tv_usec; + } else { + c.tv_sec = -c.tv_sec; + } + } + + return c; +} + +/* + * compare previously-normalised a and b + * return 1 / 0 / -1 if a < / == / > b + */ +static inline int +cmp_tval( + struct timeval a, + struct timeval b + ) +{ + int r; + + r = (a.tv_sec > b.tv_sec) - (a.tv_sec < b.tv_sec); + if (0 == r) + r = (a.tv_usec > b.tv_usec) - + (a.tv_usec < b.tv_usec); + + return r; +} + +/* + * compare possibly-denormal a and b + * return 1 / 0 / -1 if a < / == / > b + */ +static inline int +cmp_tval_denorm( + struct timeval a, + struct timeval b + ) +{ + return cmp_tval(normalize_tval(a), normalize_tval(b)); +} + +/* + * test previously-normalised a + * return 1 / 0 / -1 if a < / == / > 0 + */ +static inline int +test_tval( + struct timeval a + ) +{ + int r; + + r = (a.tv_sec > 0) - (a.tv_sec < 0); + if (r == 0) + r = (a.tv_usec > 0); + + return r; +} + +/* + * test possibly-denormal a + * return 1 / 0 / -1 if a < / == / > 0 + */ +static inline int +test_tval_denorm( + struct timeval a + ) +{ + return test_tval(normalize_tval(a)); +} + +/* return LIB buffer ptr to string rep */ +static inline const char * +tvaltoa( + struct timeval x + ) +{ + return format_time_fraction(x.tv_sec, x.tv_usec, 6); +} + +/* convert from timeval duration to l_fp duration */ +static inline l_fp +tval_intv_to_lfp( + struct timeval x + ) +{ + struct timeval v; + l_fp y; + + v = normalize_tval(x); + TVUTOTSF(v.tv_usec, y.l_uf); + y.l_i = (int32)v.tv_sec; + + return y; +} + +/* x must be UN*X epoch, output *y will be in NTP epoch */ +static inline l_fp +tval_stamp_to_lfp( + struct timeval x + ) +{ + l_fp y; + + y = tval_intv_to_lfp(x); + y.l_ui += JAN_1970; + + return y; +} + +/* convert to l_fp type, relative signed/unsigned and absolute */ +static inline struct timeval +lfp_intv_to_tval( + l_fp x + ) +{ + struct timeval out; + l_fp absx; + int neg; + + neg = L_ISNEG(&x); + absx = x; + if (neg) { + L_NEG(&absx); + } + TSFTOTVU(absx.l_uf, out.tv_usec); + out.tv_sec = absx.l_i; + if (neg) { + out.tv_sec = -out.tv_sec; + out.tv_usec = -out.tv_usec; + out = normalize_tval(out); + } + + return out; +} + +static inline struct timeval +lfp_uintv_to_tval( + l_fp x + ) +{ + struct timeval out; + + TSFTOTVU(x.l_uf, out.tv_usec); + out.tv_sec = x.l_ui; + + return out; +} + +/* + * absolute (timestamp) conversion. Input is time in NTP epoch, output + * is in UN*X epoch. The NTP time stamp will be expanded around the + * pivot time *p or the current time, if p is NULL. + */ +static inline struct timeval +lfp_stamp_to_tval( + l_fp x, + const time_t * p + ) +{ + struct timeval out; + vint64 sec; + + sec = ntpcal_ntp_to_time(x.l_ui, p); + TSFTOTVU(x.l_uf, out.tv_usec); + + /* copying a vint64 to a time_t needs some care... */ +#if SIZEOF_TIME_T <= 4 + out.tv_sec = (time_t)sec.d_s.lo; +#elif defined(HAVE_INT64) + out.tv_sec = (time_t)sec.q_s; +#else + out.tv_sec = ((time_t)sec.d_s.hi << 32) | sec.d_s.lo; +#endif + out = normalize_tval(out); + + return out; +} + +#endif /* TIMEVALOPS_H */ diff --git a/contrib/ntp/include/trimble.h b/contrib/ntp/include/trimble.h index 038763961..aaa5baa78 100644 --- a/contrib/ntp/include/trimble.h +++ b/contrib/ntp/include/trimble.h @@ -132,7 +132,7 @@ typedef struct cmd_info extern cmd_info_t trimble_rcmds[]; extern cmd_info_t trimble_scmds[]; -extern cmd_info_t *trimble_convert P((unsigned int cmd, cmd_info_t *tbl)); +extern cmd_info_t *trimble_convert (unsigned int cmd, cmd_info_t *tbl); #endif /* diff --git a/contrib/ntp/include/version.def b/contrib/ntp/include/version.def deleted file mode 100644 index f0dc44414..000000000 --- a/contrib/ntp/include/version.def +++ /dev/null @@ -1 +0,0 @@ -version = '4.2.4p8'; diff --git a/contrib/ntp/include/vint64ops.h b/contrib/ntp/include/vint64ops.h new file mode 100644 index 000000000..2c3deffb3 --- /dev/null +++ b/contrib/ntp/include/vint64ops.h @@ -0,0 +1,28 @@ +/* + * vint64ops.h - operations on 'vint64' values + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * ---------------------------------------------------------------------- + * This is an attempt to get the vint64 calculations stuff centralised. + */ +#ifndef VINT64OPS_H +#define VINT64OPS_H + +/* signed/unsigned compare. returns 1/0/-1 if lhs >/=/< rhs */ +extern int icmpv64(const vint64 * lhs, const vint64 * rhs); +extern int ucmpv64(const vint64 * lhs, const vint64 * rhs); + +/* add / subtract */ +extern vint64 addv64(const vint64 *lhs, const vint64 *rhs); +extern vint64 addv64i32(const vint64 * lhs, int32_t rhs); +extern vint64 addv64u32(const vint64 * lhs, uint32_t rhs); + +extern vint64 subv64(const vint64 *lhs, const vint64 *rhs); +extern vint64 subv64i32(const vint64 * lhs, int32_t rhs); +extern vint64 subv64u32(const vint64 * lhs, uint32_t rhs); + +/* parsing. works like strtoul() or strtoull() */ +extern vint64 strtouv64(const char * begp, char ** endp, int base); + +#endif /*!defined(VINT64OPS_H)*/ diff --git a/contrib/ntp/includes.mf b/contrib/ntp/includes.mf new file mode 100644 index 000000000..e868ba470 --- /dev/null +++ b/contrib/ntp/includes.mf @@ -0,0 +1,6 @@ +## includes.mf - automake fragment + +NTP_INCS = -I$(top_srcdir)/include +NTP_INCS += -I$(top_srcdir)/lib/isc/include +NTP_INCS += -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include +NTP_INCS += -I$(top_srcdir)/lib/isc/unix/include diff --git a/contrib/ntp/kernel/Makefile.am b/contrib/ntp/kernel/Makefile.am index b3cfc9d6d..081839c48 100644 --- a/contrib/ntp/kernel/Makefile.am +++ b/contrib/ntp/kernel/Makefile.am @@ -1,5 +1 @@ -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr SUBDIRS = sys -ETAGS_ARGS = Makefile.am -EXTRA_DIST = chuinit.c clkinit.c tty_chu.c tty_chu_STREAMS.c tty_clk.c tty_clk_STREAMS.c diff --git a/contrib/ntp/kernel/Makefile.in b/contrib/ntp/kernel/Makefile.in index b00e41a72..dd0014474 100644 --- a/contrib/ntp/kernel/Makefile.in +++ b/contrib/ntp/kernel/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -15,6 +14,61 @@ @SET_MAKE@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -34,36 +88,108 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = kernel -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = SOURCES = DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ - html-recursive info-recursive install-data-recursive \ - install-dvi-recursive install-exec-recursive \ - install-html-recursive install-info-recursive \ - install-pdf-recursive install-ps-recursive install-recursive \ - installcheck-recursive installdirs-recursive pdf-recursive \ - ps-recursive uninstall-recursive +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive -AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ - $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \ +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) am__relativize = \ dir0=`pwd`; \ @@ -91,42 +217,74 @@ am__relativize = \ done; \ reldir="$$dir2" ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -134,8 +292,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -145,15 +306,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -161,23 +383,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -224,12 +482,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr SUBDIRS = sys -ETAGS_ARGS = Makefile.am -EXTRA_DIST = chuinit.c clkinit.c tty_chu.c tty_chu_STREAMS.c tty_clk.c tty_clk_STREAMS.c all: all-recursive .SUFFIXES: @@ -245,7 +498,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign kernel/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign kernel/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -271,22 +523,25 @@ clean-libtool: -rm -rf .libs _libs # This directory's subdirectories are mostly independent; you can cd -# into them and run `make' without going through this Makefile. -# To change the values of `make' variables: instead of editing Makefiles, -# (1) if the variable is set in `config.status', edit `config.status' -# (which will cause the Makefiles to be regenerated when you run `make'); -# (2) otherwise, pass the desired values on the `make' command line. -$(RECURSIVE_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ @@ -301,57 +556,12 @@ $(RECURSIVE_TARGETS): $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" -$(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - rev=''; for subdir in $$list; do \ - if test "$$subdir" = "."; then :; else \ - rev="$$subdir $$rev"; \ - fi; \ - done; \ - rev="$$rev ."; \ - target=`echo $@ | sed s/-recursive//`; \ - for subdir in $$rev; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done && test -z "$$fail" -tags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ - done -ctags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ - done +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ @@ -367,12 +577,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -384,15 +589,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -401,6 +602,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -437,13 +653,10 @@ distdir: $(DISTFILES) done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ - test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ @@ -478,10 +691,15 @@ install-am: all-am installcheck: installcheck-recursive install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: @@ -559,22 +777,22 @@ ps-am: uninstall-am: -.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \ - install-am install-strip tags-recursive - -.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ - all all-am check check-am clean clean-generic clean-libtool \ - ctags ctags-recursive distclean distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs installdirs-am maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \ - uninstall uninstall-am +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. diff --git a/contrib/ntp/kernel/README b/contrib/ntp/kernel/README deleted file mode 100644 index 253d04e4e..000000000 --- a/contrib/ntp/kernel/README +++ /dev/null @@ -1,200 +0,0 @@ -Installing Line Disciplines and Streams Modules - -Description - -Most radio and modem clocks used for a primary (stratum-1) NTP server -utilize serial ports operating at speeds of 9600 baud or greater. The -timing jitter contributed by the serial port hardware and software -discipline can accumulate to several milliseconds on a typical Unix -workstation. In order to reduce these errors, a set of special line -disciplines can be configured in the operating system process. These -disciplines intercept special characters or signals provided by the -radio or modem clock and save a local timestamp for later processing. - -The disciplines can be compiled in the kernel in older BSD-derived -systems, or installed as System V streams modules and either compiled in -the kernel or dynamically loaded when required. In either case, they -require reconfiguration of the Unix kernel and provisions in the NTP -daemon xntpd. The streams modules can be pushed and popped from the -streams stack using conventional System V streams program primitives. -Note that not all Unix kernels support line disciplines and of those -that do, not all support System V streams. The disciplines here are -known to work correctly with SunOS 4.x kernels, but have not been tested -for other kernels. - -There are two line disciplines included in the distribution. Support for -each is enabled by adding flags to the DEFS_LOCAL line of the build -configuration file ./Config.local. This can be done automatically by the -autoconfiguration build procedures, or can be inserted/deleted after the -process has completed. - -tty_clk (CLK) - - This discipline intercepts characters received from the serial port - and passes unchanged all except a set of designated characters to - the generic serial port discipline. For each of the exception - characters, the character is inserted in the receiver buffer - followed by a timestamp in Unix timeval format. Both select() and - SIGIO are supported by the discipline. The -DCLK flag is used to - compile support for this disipline in the NTP daemon. This flag is - included if the clkdefs.h file is found in the /sys/sys directory, - or it can be added (or deleted) manually. - -tty_chu (CHU) - - This discipline is a special purpose line discipline for receiving - a special timecode broadcast by Canadian time and frequency - standard station CHU. The radio signal is first demodulated by the - 300-baud modem included in the gadget box, then processed by the - discipline and finally processed by the Scratchbuilt CHU Receiver - discipline (type 7). This discipline should be used in raw mode. - The -DCHU flag is used to compile support for this disipline in the - NTP daemon. This flag is included if the chudefs.h file is found in - the /sys/sys directory, or it can be added (or deleted) manually. - -There are two sets of line disciplines. The tty_clk.c and chu_clk.c are -designed for use with older BSD systems and are compiled in the kernel. -The tty_clk_STREAMS.c and chu_clk_STREAMS.c are designed for use with -System V streams, in which case they can be either compiled in the -kernel or dynamically loaded. Since these disciplines are small, -unobtrusive, and to nothing unless specifically enabled by an -application program, it probably doesn't matter which method is choosen. - -Compiling with the Kernel - -The following procedures are for the tty_clk line discipline; for the -chu_clk, change "tty" to "chu". -1. Copy tty_clk.c into /sys/os and clkdefs.h into /sys/sys. - -2. For SunOS 4.x systems, edit /sys/os/tty_conf.c using some facsimile - of the following lines: - - #include "clk.h" - ... - #if NCLK > 0 - int clkopen(), clkclose(), clkwrite(), clkinput(), clkioctl(); - #endif - ... - #if NCLK > 0 - { clkopen, clkclose, ttread, clkwrite, clkioctl, - clkinput, nodev, nulldev, ttstart, nullmodem, /* 10 CLK */ - ttselect }, - #else - { nodev, nodev, nodev, nodev, nodev, - nodev, nodev, nodev, nodev, nodev, - nodev }, - #endif - - For Ultrix 4.x systems, edit /sys/data/tty_conf_data.c using some - facsimile of the following lines: - - #include "clk.h" - ... - #if NCLK > 0 - int clkopen(), clkclose(), clkwrite(), clkinput(), clkioctl(); - #endif - ... - #if NCLK > 0 - clkopen, clkclose, ttread, clkwrite, clkioctl, /* 10 CLK */ - clkinput, nodev, nulldev, ttstart, nulldev, - #else - nodev, nodev, nodev, nodev, nodev, - nodev, nodev, nodev, nodev, nodev, - #endif - - If the kernel doesn't include the ??select() entry in the structure - (i.e., there are only ten entry points in the structure) just leave - it out. Also note that the number you give the line discipline (10 - in most kernels) will be specific to that kernel and will depend on - what is in there already. The entries sould be in order with no - missing space; that is, if there are only seven disciplines already - defined and you want to use 10 for good reason, you should define a - dummy 9th entry like this: - - nodev, nodev, nodev, nodev, nodev, /* 9 CLK */ - nodev, nodev, nodev, nodev, nodev, - -3. Edit /sys/h/ioctl.h and include a line somewhere near where other - line disciplines are defined like: - - #define CLKLDISC 10 /* clock line discipline */ - - The "10" should match what you used as the number in the preceding - step. - -4. Edit /sys/conf/files and add a line which looks like: - - sys/tty_clk.c optional clk - -5. Edit the kernel configuration file to include the following: - - pseudo-device tty 4 # TTY clock support -6. Run config, then make clean, then make depend, then make vmunix, - then reboot the new kernel. - -Installing as a streams module - -The following procedures are for the tty_clk_STREAMS line discipline; -for the tty_chu_STREAMS, change "clk" to "chu". - -1. Copy your choice to /sys/os, removing the "_STREAMS" in the - filename. - -2. Copy the clkdefs.h file to /usr/include/sys, then construct a soft - link to /sys/sys. - -3. Append to /sys/conf.common/files.cmn: - - os/tty_tty.c optional tty - -4. Edit /sys/sun/str_conf.c. You'll want to add lines in three places. - It'll be sort of clear where when you see the file. - - #include "tty.h" - ... - #if NTTY > 0 - extern struct streamtab ttyinfo; - #endif - ... - #if NTTY > 0 - { "tty", &ttyinfo }, - #endif - -5. Edit /sys/[arch]/conf/[k-name] (substituting the architecture and - kernel name) to stick in: - - pseudo-device tty 4 # TTY clock support - - You can change "4" to anything you like. It will limit the number - of instantiations of the tty discipline you can use at the same - time. - -6. Run config, then make clean, then make depend, then make vmunix, - then reboot the new kernel. - -Both disciplines can be dynamically loaded using streams procedures -specific to the kernel. Before using the chu_clk discipline, all other -streams modules that may already be on the stack should be popped, then -the discipline should be pushed on the stack. - -How to Use the tty_clk Line Discipline - -The tty_clk line discipline defines a new ioctl(), CLK_SETSTR, which -takes a pointer to a string of no more than CLK_MAXSTRSIZE characters. -Until the first CLK_SETSTR is performed, the discipline will simply pass -through characters. Once it is passed a string by CLK_SETSTR, any -character in that string will be immediately followed by a timestamp in -Unix timeval format. You can change the string whenever you want by -doing another CLK_SETSTR. The character must be an exact, 8 bit match. -The character '\000' cannot, unfortunately, be used, as it is the string -terminator. Passing an empty string to CLK_SETSTR turns off stamping. -Passing NULL will produce undefined results. - -How to Use the tty_chu Line Discipline -The tty_chu line discipline translates data received from the CHU modem -and returns chucode structures, as defined in chudefs.h, and expected by -the Scratchbuilt CHU Receiver reference clock driver. Depending on the -settings of PEDANTIC and ANAL_RETENTIVE used when compiling the kernel, -some checking of the data may or may not be necessary. - -David L. Mills (mills@udel.edu) diff --git a/contrib/ntp/kernel/chuinit.c b/contrib/ntp/kernel/chuinit.c deleted file mode 100644 index 270c3d55f..000000000 --- a/contrib/ntp/kernel/chuinit.c +++ /dev/null @@ -1,74 +0,0 @@ -/* -** dynamically loadable chu driver -** -** william robertson -*/ - -#include -#include -#include -#include -#include - -#include -#include - -extern int findmod(); /* os/str_io.c */ - -extern struct streamtab chuinfo; - -struct vdldrv vd = { - VDMAGIC_USER, - "chu" - }; - - -int -xxxinit(function_code, vdp, vdi, vds) -unsigned int function_code; -struct vddrv *vdp; -addr_t vdi; -struct vdstat *vds; -{ - register int i = 0; - register int j; - - switch (function_code) { - case VDLOAD: - - if (findmod("chu") >= 0) { - log(LOG_ERR, "chu stream module already loaded\n"); - return (EADDRINUSE); - } - - i = findmod("\0"); - - if (i == -1 || fmodsw[i].f_name[0] != '\0') - return(-1); - - for (j = 0; vd.Drv_name[j] != '\0'; j++) /* XXX check bounds */ - fmodsw[i].f_name[j] = vd.Drv_name[j]; - - fmodsw[i].f_name[j] = '\0'; - fmodsw[i].f_str = &chuinfo; - - vdp->vdd_vdtab = (struct vdlinkage *) &vd; - - return(0); - - case VDUNLOAD: - if ((i = findmod(vd.Drv_name)) == -1) - return(-1); - - fmodsw[i].f_name[0] = '\0'; - fmodsw[i].f_str = 0; - - return(0); - - case VDSTAT: - return(0); - - default: - return(EIO); - } -} diff --git a/contrib/ntp/kernel/clkinit.c b/contrib/ntp/kernel/clkinit.c deleted file mode 100644 index 716ca815e..000000000 --- a/contrib/ntp/kernel/clkinit.c +++ /dev/null @@ -1,74 +0,0 @@ -/* -** dynamically loadable clk driver -** -** william robertson -*/ - -#include -#include -#include -#include -#include - -#include -#include - -extern int findmod(); /* os/str_io.c */ - -extern struct streamtab clkinfo; - -struct vdldrv vd = { - VDMAGIC_USER, - "clk" - }; - - -int -xxxinit(function_code, vdp, vdi, vds) -unsigned int function_code; -struct vddrv *vdp; -addr_t vdi; -struct vdstat *vds; -{ - register int i = 0; - register int j; - - switch (function_code) { - case VDLOAD: - - if (findmod("clk") >= 0) { - log(LOG_ERR, "clk stream module already loaded\n"); - return (EADDRINUSE); - } - - i = findmod("\0"); - - if (i == -1 || fmodsw[i].f_name[0] != '\0') - return(-1); - - for (j = 0; vd.Drv_name[j] != '\0'; j++) /* XXX check bounds */ - fmodsw[i].f_name[j] = vd.Drv_name[j]; - - fmodsw[i].f_name[j] = '\0'; - fmodsw[i].f_str = &clkinfo; - - vdp->vdd_vdtab = (struct vdlinkage *) &vd; - - return(0); - - case VDUNLOAD: - if ((i = findmod(vd.Drv_name)) == -1) - return(-1); - - fmodsw[i].f_name[0] = '\0'; - fmodsw[i].f_str = 0; - - return(0); - - case VDSTAT: - return(0); - - default: - return(EIO); - } -} diff --git a/contrib/ntp/kernel/sys/Makefile.am b/contrib/ntp/kernel/sys/Makefile.am index e8465d90d..72923448a 100644 --- a/contrib/ntp/kernel/sys/Makefile.am +++ b/contrib/ntp/kernel/sys/Makefile.am @@ -1,8 +1,2 @@ -#AUTOMAKE_OPTIONS = ../../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../../util/ansi2knr -noinst_HEADERS = bsd_audioirig.h chudefs.h clkdefs.h i8253.h parsestreams.h \ +noinst_HEADERS = bsd_audioirig.h i8253.h parsestreams.h \ pcl720.h ppsclock.h timex.h tpro.h tt560_api.h -#EXTRA_DIST= TAGS -# HMS: Avoid bug in automake -#ETAGS_ARGS = "" -ETAGS_ARGS = Makefile.am diff --git a/contrib/ntp/kernel/sys/Makefile.in b/contrib/ntp/kernel/sys/Makefile.in index 4565a2e8a..58b0b6eee 100644 --- a/contrib/ntp/kernel/sys/Makefile.in +++ b/contrib/ntp/kernel/sys/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -16,6 +15,61 @@ @SET_MAKE@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -35,63 +89,163 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = kernel/sys -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = SOURCES = DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -99,8 +253,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -110,15 +267,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -126,23 +344,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -189,16 +443,9 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../../util/ansi2knr -noinst_HEADERS = bsd_audioirig.h chudefs.h clkdefs.h i8253.h parsestreams.h \ +noinst_HEADERS = bsd_audioirig.h i8253.h parsestreams.h \ pcl720.h ppsclock.h timex.h tpro.h tt560_api.h -#EXTRA_DIST= TAGS -# HMS: Avoid bug in automake -#ETAGS_ARGS = "" -ETAGS_ARGS = Makefile.am all: all-am .SUFFIXES: @@ -214,7 +461,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign kernel/sys/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign kernel/sys/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -239,26 +485,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -270,15 +505,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -287,6 +518,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -335,10 +581,15 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: @@ -418,19 +669,21 @@ uninstall-am: .MAKE: install-am install-strip -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-libtool ctags distclean distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool cscopelist-am ctags ctags-am distclean \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ uninstall-am +.PRECIOUS: Makefile + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/contrib/ntp/kernel/sys/chudefs.h b/contrib/ntp/kernel/sys/chudefs.h deleted file mode 100644 index f5549f58b..000000000 --- a/contrib/ntp/kernel/sys/chudefs.h +++ /dev/null @@ -1,22 +0,0 @@ -/* - * Definitions for the CHU line discipline v2.0 - */ - -/* - * The CHU time code consists of 10 BCD digits and is repeated - * twice for a total of 10 characters. A time is taken after - * the arrival of each character. The following structure is - * used to return this stuff. - */ -#define NCHUCHARS (10) - -struct chucode { - u_char codechars[NCHUCHARS]; /* code characters */ - u_char ncodechars; /* number of code characters */ - u_char chutype; /* packet type */ - struct timeval codetimes[NCHUCHARS]; /* arrival times */ -}; - -#define CHU_TIME 0 /* second half is equal to first half */ -#define CHU_YEAR 1 /* second half is one's complement */ - diff --git a/contrib/ntp/kernel/sys/clkdefs.h b/contrib/ntp/kernel/sys/clkdefs.h deleted file mode 100644 index afbc77a8f..000000000 --- a/contrib/ntp/kernel/sys/clkdefs.h +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Defines for the "clk" timestamping STREAMS module - */ - -#if defined(sun) -#include -#else -#include -#endif - -/* - * First, we need to define the maximum size of the set of - * characters to timestamp. 32 is MORE than enough. - */ - -#define CLK_MAXSTRSIZE 32 -struct clk_tstamp_charset { /* XXX to use _IOW not _IOWN */ - char val[CLK_MAXSTRSIZE]; -}; - -/* - * ioctl(fd, CLK_SETSTR, (char*)c ); - * - * will tell the driver that any char in the null-terminated - * string c should be timestamped. It is possible, though - * unlikely that this ioctl number could collide with an - * existing one on your system. If so, change the 'K' - * to some other letter. However, once you've compiled - * the kernel with this include file, you should NOT - * change this file. - */ - -#if defined(__STDC__) /* XXX avoid __STDC__=0 on SOLARIS */ -#define CLK_SETSTR _IOW('K', 01, struct clk_tstamp_charset) -#else -#define CLK_SETSTR _IOW(K, 01, struct clk_tstamp_charset) -#endif - diff --git a/contrib/ntp/kernel/sys/parsestreams.h b/contrib/ntp/kernel/sys/parsestreams.h index e784f9e8b..bd40093d3 100644 --- a/contrib/ntp/kernel/sys/parsestreams.h +++ b/contrib/ntp/kernel/sys/parsestreams.h @@ -4,7 +4,7 @@ * parsestreams.h,v 4.5 2005/06/25 10:52:47 kardel RELEASE_20050625_A * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions diff --git a/contrib/ntp/kernel/tty_chu.c b/contrib/ntp/kernel/tty_chu.c deleted file mode 100644 index 4615875e7..000000000 --- a/contrib/ntp/kernel/tty_chu.c +++ /dev/null @@ -1,276 +0,0 @@ -/* tty_chu.c,v 3.1 1993/07/06 01:07:30 jbj Exp - * tty_chu.c - CHU line driver - */ - -#include "chu.h" -#if NCHU > 0 - -#include "../h/param.h" -#include "../h/types.h" -#include "../h/systm.h" -#include "../h/dir.h" -#include "../h/user.h" -#include "../h/ioctl.h" -#include "../h/tty.h" -#include "../h/proc.h" -#include "../h/file.h" -#include "../h/conf.h" -#include "../h/buf.h" -#include "../h/uio.h" - -#include "../h/chudefs.h" - -/* - * Line discipline for receiving CHU time codes. - * Does elementary noise elimination, takes time stamps after - * the arrival of each character, returns a buffer full of the - * received 10 character code and the associated time stamps. - */ -#define NUMCHUBUFS 3 - -struct chudata { - u_char used; /* Set to 1 when structure in use */ - u_char lastindex; /* least recently used buffer */ - u_char curindex; /* buffer to use */ - u_char sleeping; /* set to 1 when we're sleeping on a buffer */ - struct chucode chubuf[NUMCHUBUFS]; -} chu_data[NCHU]; - -/* - * Number of microseconds we allow between - * character arrivals. The speed is 300 baud - * so this should be somewhat more than 30 msec - */ -#define CHUMAXUSEC (50*1000) /* 50 msec */ - -int chu_debug = 0; - -/* - * Open as CHU time discipline. Called when discipline changed - * with ioctl, and changes the interpretation of the information - * in the tty structure. - */ -/*ARGSUSED*/ -chuopen(dev, tp) - dev_t dev; - register struct tty *tp; -{ - register struct chudata *chu; - - /* - * Don't allow multiple opens. This will also protect us - * from someone opening /dev/tty - */ - if (tp->t_line == CHULDISC) - return (EBUSY); - ttywflush(tp); - for (chu = chu_data; chu < &chu_data[NCHU]; chu++) - if (!chu->used) - break; - if (chu >= &chu[NCHU]) - return (EBUSY); - chu->used++; - chu->lastindex = chu->curindex = 0; - chu->sleeping = 0; - chu->chubuf[0].ncodechars = 0; - tp->T_LINEP = (caddr_t) chu; - return (0); -} - -/* - * Break down... called when discipline changed or from device - * close routine. - */ -chuclose(tp) - register struct tty *tp; -{ - register int s = spl5(); - - ((struct chudata *) tp->T_LINEP)->used = 0; - tp->t_cp = 0; - tp->t_inbuf = 0; - tp->t_rawq.c_cc = 0; /* clear queues -- paranoid */ - tp->t_canq.c_cc = 0; - tp->t_line = 0; /* paranoid: avoid races */ - splx(s); -} - -/* - * Read a CHU buffer. Sleep on the current buffer - */ -churead(tp, uio) - register struct tty *tp; - struct uio *uio; -{ - register struct chudata *chu; - register struct chucode *chucode; - register int s; - - if ((tp->t_state&TS_CARR_ON)==0) - return (EIO); - - chu = (struct chudata *) (tp->T_LINEP); - - s = spl5(); - chucode = &(chu->chubuf[chu->lastindex]); - while (chu->curindex == chu->lastindex) { - chu->sleeping = 1; - sleep((caddr_t)chucode, TTIPRI); - } - chu->sleeping = 0; - if (++(chu->lastindex) >= NUMCHUBUFS) - chu->lastindex = 0; - splx(s); - - return (uiomove((caddr_t)chucode, sizeof(*chucode), UIO_READ, uio)); -} - -/* - * Low level character input routine. - * If the character looks okay, grab a time stamp. If the stuff in - * the buffer is too old, dump it and start fresh. If the character is - * non-BCDish, everything in the buffer too. - */ -chuinput(c, tp) - register int c; - register struct tty *tp; -{ - register struct chudata *chu = (struct chudata *) tp->T_LINEP; - register struct chucode *chuc; - register int i; - long sec, usec; - struct timeval tv; - - /* - * Do a check on the BSDness of the character. This delays - * the time stamp a bit but saves a fair amount of overhead - * when the static is bad. - */ - if (((c) & 0xf) > 9 || (((c)>>4) & 0xf) > 9) { - chuc = &(chu->chubuf[chu->curindex]); - chuc->ncodechars = 0; /* blow all previous away */ - return; - } - - /* - * Call microtime() to get the current time of day - */ - microtime(&tv); - - /* - * Compute the difference in this character's time stamp - * and the last. If it exceeds the margin, blow away all - * the characters currently in the buffer. - */ - chuc = &(chu->chubuf[chu->curindex]); - i = (int)chuc->ncodechars; - if (i > 0) { - sec = tv.tv_sec - chuc->codetimes[i-1].tv_sec; - usec = tv.tv_usec - chuc->codetimes[i-1].tv_usec; - if (usec < 0) { - sec -= 1; - usec += 1000000; - } - if (sec != 0 || usec > CHUMAXUSEC) { - i = 0; - chuc->ncodechars = 0; - } - } - - /* - * Store the character. If we're done, have to tell someone - */ - chuc->codechars[i] = (u_char)c; - chuc->codetimes[i] = tv; - - if (++i < NCHUCHARS) { - /* - * Not much to do here. Save the count and wait - * for another character. - */ - chuc->ncodechars = (u_char)i; - } else { - /* - * Mark this buffer full and point at next. If the - * next buffer is full we overwrite it by bumping the - * next pointer. - */ - chuc->ncodechars = NCHUCHARS; - if (++(chu->curindex) >= NUMCHUBUFS) - chu->curindex = 0; - if (chu->curindex == chu->lastindex) - if (++(chu->lastindex) >= NUMCHUBUFS) - chu->lastindex = 0; - chu->chubuf[chu->curindex].ncodechars = 0; - - /* - * Wake up anyone sleeping on this. Also wake up - * selectors and/or deliver a SIGIO as required. - */ - if (tp->t_rsel) { - selwakeup(tp->t_rsel, tp->t_state&TS_RCOLL); - tp->t_state &= ~TS_RCOLL; - tp->t_rsel = 0; - } - if (tp->t_state & TS_ASYNC) - gsignal(tp->t_pgrp, SIGIO); - if (chu->sleeping) - (void) wakeup((caddr_t)chuc); - } -} - -/* - * Handle ioctls. We reject all tty-style except those that - * change the line discipline. - */ -chuioctl(tp, cmd, data, flag) - struct tty *tp; - int cmd; - caddr_t data; - int flag; -{ - - if ((cmd>>8) != 't') - return (-1); - switch (cmd) { - case TIOCSETD: - case TIOCGETD: - case TIOCGETP: - case TIOCGETC: - return (-1); - } - return (ENOTTY); /* not quite appropriate */ -} - - -chuselect(dev, rw) - dev_t dev; - int rw; -{ - register struct tty *tp = &cdevsw[major(dev)].d_ttys[minor(dev)]; - struct chudata *chu; - int s = spl5(); - - chu = (struct chudata *) (tp->T_LINEP); - - switch (rw) { - - case FREAD: - if (chu->curindex != chu->lastindex) - goto win; - if (tp->t_rsel && tp->t_rsel->p_wchan == (caddr_t)&selwait) - tp->t_state |= TS_RCOLL; - else - tp->t_rsel = u.u_procp; - break; - - case FWRITE: - goto win; - } - splx(s); - return (0); -win: - splx(s); - return (1); -} -#endif NCHU diff --git a/contrib/ntp/kernel/tty_chu_STREAMS.c b/contrib/ntp/kernel/tty_chu_STREAMS.c deleted file mode 100644 index f46e25d2a..000000000 --- a/contrib/ntp/kernel/tty_chu_STREAMS.c +++ /dev/null @@ -1,603 +0,0 @@ -/* - * CHU STREAMS module for SunOS - * - * Version 2.6 - * - * Copyright 1991-1994, Nick Sayer - * - * Special thanks to Greg Onufer for his debug assists. - * Special thanks to Matthias Urlichs for the 4.1.x loadable driver support - * code. - * Special wet-noodle whippings to Sun for not properly documenting - * ANYTHING that makes this stuff at all possible. - * - * Should be PUSHed directly on top of a serial I/O channel. - * Provides complete chucode structures to user space. - * - * COMPILATION: - * - * - * To make a SunOS 4.1.x compatable loadable module (from the ntp kernel - * directory): - * - * % cc -c -I../include -DLOADABLE tty_chu_STREAMS.c - * - * The resulting .o file is the loadable module. Modload it - * thusly: - * - * % modload tty_chu_STREAMS.o -entry _chuinit - * - * When none of the instances are pushed in a STREAM, you can - * modunload the driver in the usual manner if you wish. - * - * As an alternative to loading it dynamically you can compile it - * directly into the kernel by hacking str_conf.c. See the README - * file for more details on doing it the old fashioned way. - * - * - * To make a Solaris 2.x compatable module (from the ntp kernel - * directory): - * - * % {gcc,cc} -c -I../include -DSOLARIS2 tty_chu_STREAMS.c - * % ld -r -o /usr/kernel/strmod/chu tty_chu_STREAMS.o - * % chmod 755 /usr/kernel/strmod/chu - * - * The OS will load it for you automagically when it is first pushed. - * - * If you get syntax errors from (really references - * to types that weren't typedef'd in gcc's version of types.h), - * add -D_SYS_TIMER_H to blot out the miscreants. - * - * Under Solaris 2.2 and previous, do not attempt to modunload the - * module unless you're SURE it's not in use. I haven't tried it, but - * I've been told it won't do the right thing. Under Solaris 2.3 (and - * presumably future revs) an attempt to unload the module when it's in - * use will properly refuse with a "busy" message. - * - * - * HISTORY: - * - * v2.6 - Mutexed the per-instance chucode just to be safe. - * v2.5 - Fixed show-stopper bug in Solaris 2.x - qprocson(). - * v2.4 - Added dynamic allocation support for Solaris 2.x. - * v2.3 - Added support for Solaris 2.x. - * v2.2 - Added SERVICE IMMEDIATE hack. - * v2.1 - Added 'sixth byte' heuristics. - * v2.0 - first version with an actual version number. - * Added support for new CHU 'second 31' data format. - * Deleted PEDANTIC and ANAL_RETENTIVE. - * - */ - -#ifdef SOLARIS2 -# ifndef NCHU -# define NCHU 1 -# endif -# define _KERNEL -#elif defined(LOADABLE) -# ifndef NCHU -# define NCHU 3 -# define KERNEL -# endif -#else -# include "chu.h" -#endif - -#if NCHU > 0 - -/* - * Number of microseconds we allow between - * character arrivals. The speed is 300 baud - * so this should be somewhat more than 30 msec - */ -#define CHUMAXUSEC (60*1000) /* 60 msec */ - -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -#ifdef SOLARIS2 - -#include -#include -#include -#include -#include -#include -#include -#include - -#endif - -#ifdef LOADABLE - -#include -#include -#include -#include -#include -#include - -#endif - - -static struct module_info rminfo = { 0, "chu", 0, INFPSZ, 0, 0 }; -static struct module_info wminfo = { 0, "chu", 0, INFPSZ, 0, 0 }; -static int chuopen(), churput(), chuwput(), chuclose(); - -static struct qinit rinit = { churput, NULL, chuopen, chuclose, NULL, - &rminfo, NULL }; - -static struct qinit winit = { chuwput, NULL, NULL, NULL, NULL, - &wminfo, NULL }; - -struct streamtab chuinfo = { &rinit, &winit, NULL, NULL }; - -/* - * Here's our private data type and structs - */ -struct priv_data -{ -#ifdef SOLARIS2 - kmutex_t chucode_mutex; -#else - char in_use; -#endif - struct chucode chu_struct; -}; - -#ifndef SOLARIS2 -struct priv_data our_priv_data[NCHU]; -#endif - -#ifdef SOLARIS2 - -static struct fmodsw fsw = -{ - "chu", - &chuinfo, - D_NEW | D_MP -}; - -extern struct mod_ops mod_strmodops; - -static struct modlstrmod modlstrmod = -{ - &mod_strmodops, - "CHU timecode decoder v2.6", - &fsw -}; - -static struct modlinkage modlinkage = -{ - MODREV_1, - (void*) &modlstrmod, - NULL -}; - -int _init() -{ - return mod_install(&modlinkage); -} - -int _info(foo) -struct modinfo *foo; -{ - return mod_info(&modlinkage,foo); -} - -int _fini() -{ - return mod_remove(&modlinkage); -} - -#endif /* SOLARIS2 */ - -#ifdef LOADABLE - -# ifdef sun - -static struct vdldrv vd = -{ - VDMAGIC_PSEUDO, - "chu", - NULL, NULL, NULL, 0, 0, NULL, NULL, 0, 0, -}; - -static struct fmodsw *chu_fmod; - -/*ARGSUSED*/ -chuinit (fc, vdp, vdi, vds) - unsigned int fc; - struct vddrv *vdp; - addr_t vdi; - struct vdstat *vds; -{ - switch (fc) { - case VDLOAD: - { - int dev, i; - - /* Find free entry in fmodsw */ - for (dev = 0; dev < fmodcnt; dev++) { - if (fmodsw[dev].f_str == NULL) - break; - } - if (dev == fmodcnt) - return (ENODEV); - chu_fmod = &fmodsw[dev]; - - /* If you think a kernel would have strcpy() you're mistaken. */ - for (i = 0; i <= FMNAMESZ; i++) - chu_fmod->f_name[i] = wminfo.mi_idname[i]; - - chu_fmod->f_str = &chuinfo; - } - vdp->vdd_vdtab = (struct vdlinkage *) & vd; - - { - int i; - - for (i=0; if_name[0] = '\0'; - chu_fmod->f_str = NULL; - return 0; - case VDSTAT: - return 0; - default: - return EIO; - } -} - -# endif /* sun */ - -#endif /* LOADABLE */ - -#if !defined(LOADABLE) && !defined(SOLARIS2) - -char chu_first_open=1; - -#endif - -/*ARGSUSED*/ -static int chuopen(q, dev, flag, sflag) -queue_t *q; -dev_t dev; -int flag; -int sflag; -{ - int i; - -#if !defined(LOADABLE) && !defined(SOLARIS2) - if (chu_first_open) - { - chu_first_open=0; - - for(i=0;iq_ptr = kmem_alloc( sizeof(struct priv_data), KM_SLEEP ); - ((struct priv_data *) q->q_ptr)->chu_struct.ncodechars = 0; - - mutex_init(&((struct priv_data *) q->q_ptr)->chucode_mutex,"Chucode Mutex",MUTEX_DRIVER,NULL); - qprocson(q); - - if (!putnextctl1(WR(q), M_CTL, MC_SERVICEIMM)) - { - qprocsoff(q); - mutex_destroy(&((struct priv_data *)q->q_ptr)->chucode_mutex); - kmem_free(q->q_ptr, sizeof(struct chucode) ); - return (EFAULT); - } - - return 0; - -#else - for(i=0;iq_ptr))=&(our_priv_data[i]); - our_priv_data[i].in_use++; - our_priv_data[i].chu_struct.ncodechars = 0; - if (!putctl1(WR(q)->q_next, M_CTL, MC_SERVICEIMM)) - { - our_priv_data[i].in_use=0; - u.u_error = EFAULT; - return (OPENFAIL); - } - return 0; - } - - u.u_error = EBUSY; - return (OPENFAIL); -#endif - -} - -/*ARGSUSED*/ -static int chuclose(q, flag) -queue_t *q; -int flag; -{ -#ifdef SOLARIS2 - qprocsoff(q); - mutex_destroy(&((struct priv_data *)q->q_ptr)->chucode_mutex); - kmem_free(q->q_ptr, sizeof(struct chucode) ); -#else - ((struct priv_data *) (q->q_ptr))->in_use=0; -#endif - return (0); -} - -/* - * Now the crux of the biscuit. - * - * We will be passed data from the man downstairs. If it's not a data - * packet, it must be important, so pass it along unmunged. If, however, - * it is a data packet, we're gonna do special stuff to it. We're going - * to pass each character we get to the old line discipline code we - * include below for just such an occasion. When the old ldisc code - * gets a full chucode struct, we'll hand it back upstairs. - * - * chuinput takes a single character and q (as quickly as possible). - * passback takes a pointer to a chucode struct and q and sends it upstream. - */ - -void chuinput(); -void passback(); - -static int churput(q, mp) -queue_t *q; -mblk_t *mp; -{ - mblk_t *bp; - - switch(mp->b_datap->db_type) - { - case M_DATA: - for(bp=mp; bp!=NULL; bp=bp->b_cont) - { - while(bp->b_rptr < bp->b_wptr) - chuinput( ((u_char)*(bp->b_rptr++)) , q ); - } - freemsg(mp); - break; - default: - putnext(q,mp); - break; - } - -} - -/* - * Writing to a chu device doesn't make sense, but we'll pass them - * through in case they're important. - */ - -static int chuwput(q, mp) -queue_t *q; -mblk_t *mp; -{ - putnext(q,mp); -} - -/* - * Take a pointer to a filled chucode struct and a queue and - * send the chucode stuff upstream - */ - -void passback(outdata,q) -struct chucode *outdata; -queue_t *q; -{ - mblk_t *mp; - int j; - - mp=(mblk_t*) allocb(sizeof(struct chucode),BPRI_LO); - - if (mp==NULL) - { -#ifdef SOLARIS2 - cmn_err(CE_WARN,"chu module couldn't allocate message block"); -#else - log(LOG_ERR,"chu: cannot allocate message"); -#endif - return; - } - - for(j=0;jb_wptr++ = *( ((char*)outdata) + j ); - - putnext(q,mp); -} - -/* - * This routine was copied nearly verbatim from the old line discipline. - */ -void chuinput(c,q) -register u_char c; -queue_t *q; -{ - register struct chucode *chuc; - register int i; - long sec, usec; - struct timeval tv; - - /* - * Quick, Batman, get a timestamp! We need to do this - * right away. The time between the end of the stop bit - * and this point is critical, and should be as nearly - * constant and as short as possible. (Un)fortunately, - * the Sun's clock granularity is so big this isn't a - * major problem. - * - * uniqtime() is totally undocumented, but there you are. - */ - uniqtime(&tv); - -#ifdef SOLARIS2 - mutex_enter(&((struct priv_data *)q->q_ptr)->chucode_mutex); -#endif - - /* - * Now, locate the chu struct once so we don't have to do it - * over and over. - */ - chuc=&(((struct priv_data *) (q->q_ptr))->chu_struct); - - /* - * Compute the difference in this character's time stamp - * and the last. If it exceeds the margin, blow away all - * the characters currently in the buffer. - */ - i = (int)chuc->ncodechars; - if (i > 0) - { - sec = tv.tv_sec - chuc->codetimes[i-1].tv_sec; - usec = tv.tv_usec - chuc->codetimes[i-1].tv_usec; - if (usec < 0) - { - sec -= 1; - usec += 1000000; - } - if (sec != 0 || usec > CHUMAXUSEC) - { - i = 0; - chuc->ncodechars = 0; - } - } - - /* - * Store the character. - */ - chuc->codechars[i] = (u_char)c; - chuc->codetimes[i] = tv; - - /* - * Now we perform the 'sixth byte' heuristics. - * - * This is a long story. - * - * We used to be able to count on the first byte of the code - * having a '6' in the LSD. This prevented most code framing - * errors (garbage before the first byte wouldn't typically - * have a 6 in the LSD). That's no longer the case. - * - * We can get around this, however, by noting that the 6th byte - * must be either equal to or one's complement of the first. - * If we get a sixth byte that ISN'T like that, then it may - * well be that the first byte is garbage. The right thing - * to do is to left-shift the whole buffer one count and - * continue to wait for the sixth byte. - */ - if (i == NCHUCHARS/2) - { - register u_char temp_byte; - - temp_byte=chuc->codechars[i] ^ chuc->codechars[0]; - - if ( (temp_byte) && (temp_byte!=0xff) ) - { - register int t; - /* - * No match. Left-shift the buffer and try again - */ - for(t=0;t<=NCHUCHARS/2;t++) - { - chuc->codechars[t]=chuc->codechars[t+1]; - chuc->codetimes[t]=chuc->codetimes[t+1]; - } - - i--; /* This is because of the ++i immediately following */ - } - } - - /* - * We done yet? - */ - if (++i < NCHUCHARS) - { - /* - * We're not done. Not much to do here. Save the count and wait - * for another character. - */ - chuc->ncodechars = (u_char)i; - } - else - { - /* - * We are done. Mark this buffer full and pass it along. - */ - chuc->ncodechars = NCHUCHARS; - - /* - * Now we have a choice. Either the front half and back half - * have to match, or be one's complement of each other. - * - * So let's try the first byte and see - */ - - if(chuc->codechars[0] == chuc->codechars[NCHUCHARS/2]) - { - chuc->chutype = CHU_TIME; - for( i=0; i<(NCHUCHARS/2); i++) - if (chuc->codechars[i] != chuc->codechars[i+(NCHUCHARS/2)]) - { - chuc->ncodechars = 0; -#ifdef SOLARIS2 - mutex_exit(&((struct priv_data *)q->q_ptr)->chucode_mutex); -#endif - return; - } - } - else - { - chuc->chutype = CHU_YEAR; - for( i=0; i<(NCHUCHARS/2); i++) - if (((chuc->codechars[i] ^ chuc->codechars[i+(NCHUCHARS/2)]) & 0xff) - != 0xff ) - { - chuc->ncodechars = 0; -#ifdef SOLARIS2 - mutex_exit(&((struct priv_data *)q->q_ptr)->chucode_mutex); -#endif - return; - } - } - - passback(chuc,q); /* We're done! */ - chuc->ncodechars = 0; /* Start all over again! */ - } -#ifdef SOLARIS2 - mutex_exit(&((struct priv_data *)q->q_ptr)->chucode_mutex); -#endif -} - -#endif /* NCHU > 0 */ diff --git a/contrib/ntp/kernel/tty_clk.c b/contrib/ntp/kernel/tty_clk.c deleted file mode 100644 index 072061039..000000000 --- a/contrib/ntp/kernel/tty_clk.c +++ /dev/null @@ -1,317 +0,0 @@ -/* tty_clk.c,v 3.1 1993/07/06 01:07:33 jbj Exp - * tty_clk.c - Generic line driver for receiving radio clock timecodes - */ - -#include "clk.h" -#if NCLK > 0 - -#include "../h/param.h" -#include "../h/types.h" -#include "../h/systm.h" -#include "../h/dir.h" -#include "../h/user.h" -#include "../h/ioctl.h" -#include "../h/tty.h" -#include "../h/proc.h" -#include "../h/file.h" -#include "../h/conf.h" -#include "../h/buf.h" -#include "../h/uio.h" -#include "../h/clist.h" - -/* - * This line discipline is intended to provide well performing - * generic support for the reception and time stamping of radio clock - * timecodes. Most radio clock devices return a string where a - * particular character in the code (usually a \r) is on-time - * synchronized with the clock. The idea here is to collect characters - * until (one of) the synchronization character(s) (we allow two) is seen. - * When the magic character arrives we take a timestamp by calling - * microtime() and insert the eight bytes of struct timeval into the - * buffer after the magic character. We then wake up anyone waiting - * for the buffer and return the whole mess on the next read. - * - * To use this the calling program is expected to first open the - * port, and then to set the port into raw mode with the speed - * set appropriately with a TIOCSETP ioctl(), with the erase and kill - * characters set to those to be considered magic (yes, I know this - * is gross, but they were so convenient). If only one character is - * magic you can set then both the same, or perhaps to the alternate - * parity versions of said character. After getting all this set, - * change the line discipline to CLKLDISC and you are on your way. - * - * The only other bit of magic we do in here is to flush the receive - * buffers on writes if the CRMOD flag is set (hack, hack). - */ - -/* - * We run this very much like a raw mode terminal, with the exception - * that we store up characters locally until we hit one of the - * magic ones and then dump it into the rawq all at once. We keep - * the buffered data in clists since we can then often move it to - * the rawq without copying. For sanity we limit the number of - * characters between specials, and the total number of characters - * before we flush the rawq, as follows. - */ -#define CLKLINESIZE (256) -#define NCLKCHARS (CLKLINESIZE*4) - -struct clkdata { - int inuse; - struct clist clkbuf; -}; -#define clk_cc clkbuf.c_cc -#define clk_cf clkbuf.c_cf -#define clk_cl clkbuf.c_cl - -struct clkdata clk_data[NCLK]; - -/* - * Routine for flushing the internal clist - */ -#define clk_bflush(clk) (ndflush(&((clk)->clkbuf), (clk)->clk_cc)) - -int clk_debug = 0; - -/*ARGSUSED*/ -clkopen(dev, tp) - dev_t dev; - register struct tty *tp; -{ - register struct clkdata *clk; - - /* - * Don't allow multiple opens. This will also protect us - * from someone opening /dev/tty - */ - if (tp->t_line == CLKLDISC) - return (EBUSY); - ttywflush(tp); - for (clk = clk_data; clk < &clk_data[NCLK]; clk++) - if (!clk->inuse) - break; - if (clk >= &clk_data[NCLK]) - return (EBUSY); - clk->inuse++; - clk->clk_cc = 0; - clk->clk_cf = clk->clk_cl = NULL; - tp->T_LINEP = (caddr_t) clk; - return (0); -} - - -/* - * Break down... called when discipline changed or from device - * close routine. - */ -clkclose(tp) - register struct tty *tp; -{ - register struct clkdata *clk; - register int s = spltty(); - - clk = (struct clkdata *)tp->T_LINEP; - if (clk->clk_cc > 0) - clk_bflush(clk); - clk->inuse = 0; - tp->t_line = 0; /* paranoid: avoid races */ - splx(s); -} - - -/* - * Receive a write request. We pass these requests on to the terminal - * driver, except that if the CRMOD bit is set in the flags we - * first flush the input queues. - */ -clkwrite(tp, uio) - register struct tty *tp; - struct uio *uio; -{ - if (tp->t_flags & CRMOD) { - register struct clkdata *clk; - int s; - - s = spltty(); - if (tp->t_rawq.c_cc > 0) - ndflush(&tp->t_rawq, tp->t_rawq.c_cc); - clk = (struct clkdata *) tp->T_LINEP; - if (clk->clk_cc > 0) - clk_bflush(clk); - (void)splx(s); - } - ttwrite(tp, uio); -} - - -/* - * Low level character input routine. - * If the character looks okay, grab a time stamp. If the stuff in - * the buffer is too old, dump it and start fresh. If the character is - * non-BCDish, everything in the buffer too. - */ -clkinput(c, tp) - register int c; - register struct tty *tp; -{ - register struct clkdata *clk; - register int i; - register long s; - struct timeval tv; - - /* - * Check to see whether this isn't the magic character. If not, - * save the character and return. - */ -#ifdef ultrix - if (c != tp->t_cc[VERASE] && c != tp->t_cc[VKILL]) { -#else - if (c != tp->t_erase && c != tp->t_kill) { -#endif - clk = (struct clkdata *) tp->T_LINEP; - if (clk->clk_cc >= CLKLINESIZE) - clk_bflush(clk); - if (putc(c, &clk->clkbuf) == -1) { - /* - * Hopeless, no clists. Flush what we have - * and hope things improve. - */ - clk_bflush(clk); - } - return; - } - - /* - * Here we have a magic character. Get a timestamp and store - * everything. - */ - microtime(&tv); - clk = (struct clkdata *) tp->T_LINEP; - - if (putc(c, &clk->clkbuf) == -1) - goto flushout; - -#ifdef CLKLDISC - /* - * STREAMS people started writing timestamps this way. - * It's not my fault, I am just going along with the flow... - */ - for (i = 0; i < sizeof(struct timeval); i++) - if (putc(*( ((char*)&tv) + i ), &clk->clkbuf) == -1) - goto flushout; -#else - /* - * This is a machine independant way of puting longs into - * the datastream. It has fallen into disuse... - */ - s = tv.tv_sec; - for (i = 0; i < sizeof(long); i++) { - if (putc((s >> 24) & 0xff, &clk->clkbuf) == -1) - goto flushout; - s <<= 8; - } - - s = tv.tv_usec; - for (i = 0; i < sizeof(long); i++) { - if (putc((s >> 24) & 0xff, &clk->clkbuf) == -1) - goto flushout; - s <<= 8; - } -#endif - - /* - * If the length of the rawq exceeds our sanity limit, dump - * all the old crap in there before copying this in. - */ - if (tp->t_rawq.c_cc > NCLKCHARS) - ndflush(&tp->t_rawq, tp->t_rawq.c_cc); - - /* - * Now copy the buffer in. There is a special case optimization - * here. If there is nothing on the rawq at present we can - * just copy the clists we own over. Otherwise we must concatenate - * the present data on the end. - */ - s = (long)spltty(); - if (tp->t_rawq.c_cc <= 0) { - tp->t_rawq = clk->clkbuf; - clk->clk_cc = 0; - clk->clk_cl = clk->clk_cf = NULL; - (void) splx((int)s); - } else { - (void) splx((int)s); - catq(&clk->clkbuf, &tp->t_rawq); - clk_bflush(clk); - } - - /* - * Tell the world - */ - ttwakeup(tp); - return; - -flushout: - /* - * It would be nice if this never happened. Flush the - * internal clists and hope someone else frees some of them - */ - clk_bflush(clk); - return; -} - - -/* - * Handle ioctls. We reject most tty-style except those that - * change the line discipline and a couple of others.. - */ -clkioctl(tp, cmd, data, flag) - struct tty *tp; - int cmd; - caddr_t data; - int flag; -{ - int flags; - struct sgttyb *sg; - - if ((cmd>>8) != 't') - return (-1); - switch (cmd) { - case TIOCSETD: - case TIOCGETD: - case TIOCGETP: - case TIOCGETC: - case TIOCOUTQ: - return (-1); - - case TIOCSETP: - /* - * He likely wants to set new magic characters in. - * Do this part. - */ - sg = (struct sgttyb *)data; -#ifdef ultrix - tp->t_cc[VERASE] = sg->sg_erase; - tp->t_cc[VKILL] = sg->sg_kill; -#else - tp->t_erase = sg->sg_erase; - tp->t_kill = sg->sg_kill; -#endif - return (0); - - case TIOCFLUSH: - flags = *(int *)data; - if (flags == 0 || (flags & FREAD)) { - register struct clkdata *clk; - - clk = (struct clkdata *) tp->T_LINEP; - if (clk->clk_cc > 0) - clk_bflush(clk); - } - return (-1); - - default: - break; - } - return (ENOTTY); /* not quite appropriate */ -} -#endif NCLK diff --git a/contrib/ntp/kernel/tty_clk_STREAMS.c b/contrib/ntp/kernel/tty_clk_STREAMS.c deleted file mode 100644 index 13b0a25f1..000000000 --- a/contrib/ntp/kernel/tty_clk_STREAMS.c +++ /dev/null @@ -1,266 +0,0 @@ -/* tty_clk_STREAMS.c,v 3.1 1993/07/06 01:07:34 jbj Exp - * Timestamp STREAMS module for SunOS 4.1 - * - * Copyright 1991, Nick Sayer - * - * Special thanks to Greg Onufer for his debug assists. - * - * Should be PUSHed directly on top of a serial I/O channel. - * For any character in a user-designated set, adds a kernel - * timestamp to that character. - * - * BUGS: - * - * Only so many characters can be timestamped. This number, however, - * is adjustable. - * - * The null character ($00) cannot be timestamped. - * - * The M_DATA messages passed upstream will not be the same - * size as when they arrive from downstream, even if no - * timestamp character is in the message. This, however, - * should not affect anything. - * - */ - -#include "clk.h" -#if NCLK > 0 -/* - * How big should the messages we pass upstream be? - */ -#define MESSAGE_SIZE 128 - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -static struct module_info rminfo = { 0, "clk", 0, INFPSZ, 0, 0 }; -static struct module_info wminfo = { 0, "clk", 0, INFPSZ, 0, 0 }; -static int clkopen(), clkrput(), clkwput(), clkclose(); - -static struct qinit rinit = { clkrput, NULL, clkopen, clkclose, NULL, - &rminfo, NULL }; - -static struct qinit winit = { clkwput, NULL, NULL, NULL, NULL, - &wminfo, NULL }; - -struct streamtab clkinfo = { &rinit, &winit, NULL, NULL }; - -struct priv_data_type -{ - char in_use; - char string[CLK_MAXSTRSIZE]; -} priv_data[NCLK]; - -char first_open=1; - -/* - * God only knows why, but linking with strchr() fails - * on my system, so here's a renamed copy. - */ - -u_char *str_chr(s,c) -u_char *s; -int c; -{ - while (*s) - if(*s++ == c) - return (s-1); - return NULL; -} - -/*ARGSUSED*/ -static int clkopen(q, dev, flag, sflag) -queue_t *q; -dev_t dev; -int flag; -int sflag; -{ - int i; - -/* Damn it! We can't even have the global data struct properly - initialized! So we have a mark to tell us to init the global - data on the first open */ - - if (first_open) - { - first_open=0; - - for(i=0;iq_ptr))=priv_data+i; - priv_data[i].string[0]=0; - return (0); - } - u.u_error = EBUSY; - return (OPENFAIL); -} - -/*ARGSUSED*/ -static int clkclose(q, flag) -queue_t *q; -int flag; -{ - ((struct priv_data_type *) (q->q_ptr))->in_use=0; - - return (0); -} - -/* - * Now the crux of the biscuit. - * - * If it's an M_DATA package, we take each character and pass - * it to clkchar. - */ - -void clkchar(); - -static int clkrput(q, mp) -queue_t *q; -mblk_t *mp; -{ - mblk_t *bp; - - switch(mp->b_datap->db_type) - { - case M_DATA: - clkchar(0,q,2); - for(bp=mp; bp!=NULL; bp=bp->b_cont) - { - while(bp->b_rptr < bp->b_wptr) - clkchar( ((u_char)*(bp->b_rptr++)) , q , 0 ); - } - clkchar(0,q,1); - freemsg(mp); - break; - default: - putnext(q,mp); - break; - } - -} - -/* - * If it's a matching M_IOCTL, handle it. - */ - -static int clkwput(q, mp) -queue_t *q; -mblk_t *mp; -{ - struct iocblk *iocp; - - switch(mp->b_datap->db_type) - { - case M_IOCTL: - iocp=(struct iocblk*) mp->b_rptr; - if (iocp->ioc_cmd==CLK_SETSTR) - { - strncpy( ((struct priv_data_type *) (RD(q)->q_ptr))->string, - (char *) mp->b_cont->b_rptr,CLK_MAXSTRSIZE); - /* make sure it's null terminated */ - ((struct priv_data_type *) (RD(q)->q_ptr))->string[CLK_MAXSTRSIZE-1]=0; - mp->b_datap->db_type = M_IOCACK; - qreply(q,mp); - } - else - putnext(q,mp); - break; - default: - putnext(q,mp); - break; - } -} - -/* - * Now clkchar. It takes a character, a queue pointer and an action - * flag and depending on the flag either: - * - * 0 - adds the character to the current message. If there's a - * timestamp to be done, do that too. If the message is less than - * 8 chars from being full, link in a new one, and set it up for - * the next call. - * - * 1 - sends the whole mess to Valhala. - * - * 2 - set things up. - * - * Yeah, it's an ugly hack. Complaints may be filed with /dev/null. - */ - - -void clkchar(c,q,f) - register u_char c; - queue_t *q; - char f; -{ - static char error; - static mblk_t *message,*mp; - struct timeval tv; - -/* Get a timestamp ASAP! */ - uniqtime(&tv); - - switch(f) - { - case 1: - if (!error) - putnext(q,message); - break; - case 2: - mp=message= (mblk_t*) allocb(MESSAGE_SIZE,BPRI_LO); - error=(message==NULL); - if (error) - log(LOG_ERR,"clk: cannot allocate message - data lost"); - break; - case 0: - if (error) /* If we had an error, forget it. */ - return; - - *mp->b_wptr++=c; /* Put the char away first. - - /* If it's in the special string, append a struct timeval */ - - if (str_chr( ((struct priv_data_type *) (q->q_ptr))->string , - c )!=NULL) - { - int i; - - for (i=0;ib_wptr++= *( ((char*)&tv) + i ); - } - - /* If we don't have space for a complete struct timeval, and a - char, it's time for a new mp block */ - - if (((mp->b_wptr-mp->b_rptr)+sizeof(struct timeval)+2)>MESSAGE_SIZE) - { - mp->b_cont= (mblk_t*) allocb(MESSAGE_SIZE,BPRI_LO); - error=(mp->b_cont==NULL); - if (error) - { - log(LOG_ERR,"clk: cannot allocate message - data lost"); - freemsg(message); - } - mp=mp->b_cont; - } - - break; - } -} - -#endif diff --git a/contrib/ntp/lib/isc/Atffile b/contrib/ntp/lib/isc/Atffile new file mode 100644 index 000000000..1edb838c6 --- /dev/null +++ b/contrib/ntp/lib/isc/Atffile @@ -0,0 +1,5 @@ +Content-Type: application/X-atf-atffile; version="1" + +prop: test-suite = bind9 + +tp: tests diff --git a/contrib/ntp/lib/isc/alpha/include/isc/atomic.h b/contrib/ntp/lib/isc/alpha/include/isc/atomic.h new file mode 100644 index 000000000..ab3de5de7 --- /dev/null +++ b/contrib/ntp/lib/isc/alpha/include/isc/atomic.h @@ -0,0 +1,184 @@ +/* + * Copyright (C) 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.7 2009/04/08 06:48:23 tbox Exp $ */ + +/* + * This code was written based on FreeBSD's kernel source whose copyright + * follows: + */ + +/*- + * Copyright (c) 1998 Doug Rabson + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $FreeBSD: 258945 2013-12-04 21:33:17Z roberto $ + */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEOSFASM +#include + +#pragma intrinsic(asm) + +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. Memory access ordering around this function + * can be critical, so we add explicit memory block instructions at the + * beginning and the end of it (same for other functions). + */ +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + return (asm("mb;" + "1:" + "ldl_l %t0, 0(%a0);" /* load old value */ + "mov %t0, %v0;" /* copy the old value */ + "addl %t0, %a1, %t0;" /* calculate new value */ + "stl_c %t0, 0(%a0);" /* attempt to store */ + "beq %t0, 1b;" /* spin if failed */ + "mb;", + p, val)); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + (void)asm("mb;" + "1:" + "ldl_l %t0, 0(%a0);" /* load old value */ + "mov %a1, %t0;" /* value to store */ + "stl_c %t0, 0(%a0);" /* attempt to store */ + "beq %t0, 1b;" /* spin if failed */ + "mb;", + p, val); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + + return(asm("mb;" + "1:" + "ldl_l %t0, 0(%a0);" /* load old value */ + "mov %t0, %v0;" /* copy the old value */ + "cmpeq %t0, %a1, %t0;" /* compare */ + "beq %t0, 2f;" /* exit if not equal */ + "mov %a2, %t0;" /* value to store */ + "stl_c %t0, 0(%a0);" /* attempt to store */ + "beq %t0, 1b;" /* if it failed, spin */ + "2:" + "mb;", + p, cmpval, val)); +} +#elif defined (ISC_PLATFORM_USEGCCASM) +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t temp, prev; + + __asm__ volatile( + "mb;" + "1:" + "ldl_l %0, %1;" /* load old value */ + "mov %0, %2;" /* copy the old value */ + "addl %0, %3, %0;" /* calculate new value */ + "stl_c %0, %1;" /* attempt to store */ + "beq %0, 1b;" /* spin if failed */ + "mb;" + : "=&r"(temp), "+m"(*p), "=&r"(prev) + : "r"(val) + : "memory"); + + return (prev); +} + +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + isc_int32_t temp; + + __asm__ volatile( + "mb;" + "1:" + "ldl_l %0, %1;" /* load old value */ + "mov %2, %0;" /* value to store */ + "stl_c %0, %1;" /* attempt to store */ + "beq %0, 1b;" /* if it failed, spin */ + "mb;" + : "=&r"(temp), "+m"(*p) + : "r"(val) + : "memory"); +} + +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + isc_int32_t temp, prev; + + __asm__ volatile( + "mb;" + "1:" + "ldl_l %0, %1;" /* load old value */ + "mov %0, %2;" /* copy the old value */ + "cmpeq %0, %3, %0;" /* compare */ + "beq %0, 2f;" /* exit if not equal */ + "mov %4, %0;" /* value to store */ + "stl_c %0, %1;" /* attempt to store */ + "beq %0, 1b;" /* if it failed, spin */ + "2:" + "mb;" + : "=&r"(temp), "+m"(*p), "=&r"(prev) + : "r"(cmpval), "r"(val) + : "memory"); + + return (prev); +} +#else + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif + +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/lib/isc/api b/contrib/ntp/lib/isc/api new file mode 100644 index 000000000..ed4b69f8b --- /dev/null +++ b/contrib/ntp/lib/isc/api @@ -0,0 +1,8 @@ +# LIBINTERFACE ranges +# 9.6: 50-59, 110-119 +# 9.7: 60-79 +# 9.8: 80-89 +# 9.9: 90-109 +LIBINTERFACE = 91 +LIBREVISION = 1 +LIBAGE = 1 diff --git a/contrib/ntp/lib/isc/app_api.c b/contrib/ntp/lib/isc/app_api.c new file mode 100644 index 000000000..ce767d175 --- /dev/null +++ b/contrib/ntp/lib/isc/app_api.c @@ -0,0 +1,136 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: app_api.c,v 1.5 2009/09/02 23:48:02 tbox Exp $ */ + +#include + +#include + +#include +#include +#include +#include +#include + +static isc_mutex_t createlock; +static isc_once_t once = ISC_ONCE_INIT; +static isc_appctxcreatefunc_t appctx_createfunc = NULL; + +#define ISCAPI_APPMETHODS_VALID(m) ISC_MAGIC_VALID(m, ISCAPI_APPMETHODS_MAGIC) + +static void +initialize(void) { + RUNTIME_CHECK(isc_mutex_init(&createlock) == ISC_R_SUCCESS); +} + +isc_result_t +isc_app_register(isc_appctxcreatefunc_t createfunc) { + isc_result_t result = ISC_R_SUCCESS; + + RUNTIME_CHECK(isc_once_do(&once, initialize) == ISC_R_SUCCESS); + + LOCK(&createlock); + if (appctx_createfunc == NULL) + appctx_createfunc = createfunc; + else + result = ISC_R_EXISTS; + UNLOCK(&createlock); + + return (result); +} + +isc_result_t +isc_appctx_create(isc_mem_t *mctx, isc_appctx_t **ctxp) { + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(appctx_createfunc != NULL); + result = (*appctx_createfunc)(mctx, ctxp); + + UNLOCK(&createlock); + + return (result); +} + +void +isc_appctx_destroy(isc_appctx_t **ctxp) { + REQUIRE(ctxp != NULL && ISCAPI_APPCTX_VALID(*ctxp)); + + (*ctxp)->methods->ctxdestroy(ctxp); + + ENSURE(*ctxp == NULL); +} + +isc_result_t +isc_app_ctxstart(isc_appctx_t *ctx) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + + return (ctx->methods->ctxstart(ctx)); +} + +isc_result_t +isc_app_ctxrun(isc_appctx_t *ctx) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + + return (ctx->methods->ctxrun(ctx)); +} + +isc_result_t +isc_app_ctxsuspend(isc_appctx_t *ctx) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + + return (ctx->methods->ctxsuspend(ctx)); +} + +isc_result_t +isc_app_ctxshutdown(isc_appctx_t *ctx) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + + return (ctx->methods->ctxshutdown(ctx)); +} + +void +isc_app_ctxfinish(isc_appctx_t *ctx) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + + ctx->methods->ctxfinish(ctx); +} + +void +isc_appctx_settaskmgr(isc_appctx_t *ctx, isc_taskmgr_t *taskmgr) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + REQUIRE(taskmgr != NULL); + + ctx->methods->settaskmgr(ctx, taskmgr); +} + +void +isc_appctx_setsocketmgr(isc_appctx_t *ctx, isc_socketmgr_t *socketmgr) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + REQUIRE(socketmgr != NULL); + + ctx->methods->setsocketmgr(ctx, socketmgr); +} + +void +isc_appctx_settimermgr(isc_appctx_t *ctx, isc_timermgr_t *timermgr) { + REQUIRE(ISCAPI_APPCTX_VALID(ctx)); + REQUIRE(timermgr != NULL); + + ctx->methods->settimermgr(ctx, timermgr); +} diff --git a/contrib/ntp/lib/isc/assertions.c b/contrib/ntp/lib/isc/assertions.c new file mode 100644 index 000000000..31c4fe7c9 --- /dev/null +++ b/contrib/ntp/lib/isc/assertions.c @@ -0,0 +1,139 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: assertions.c,v 1.26 2009/09/29 15:06:07 fdupont Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include +#include + +/* + * The maximum number of stack frames to dump on assertion failure. + */ +#ifndef BACKTRACE_MAXFRAME +#define BACKTRACE_MAXFRAME 128 +#endif + +/*% + * Forward. + */ +static void +default_callback(const char *, int, isc_assertiontype_t, const char *); + +static isc_assertioncallback_t isc_assertion_failed_cb = default_callback; + +/*% + * Public. + */ + +/*% assertion failed handler */ +/* coverity[+kill] */ +void +isc_assertion_failed(const char *file, int line, isc_assertiontype_t type, + const char *cond) +{ + isc_assertion_failed_cb(file, line, type, cond); + abort(); + /* NOTREACHED */ +} + +/*% Set callback. */ +void +isc_assertion_setcallback(isc_assertioncallback_t cb) { + if (cb == NULL) + isc_assertion_failed_cb = default_callback; + else + isc_assertion_failed_cb = cb; +} + +/*% Type to Text */ +const char * +isc_assertion_typetotext(isc_assertiontype_t type) { + const char *result; + + /* + * These strings have purposefully not been internationalized + * because they are considered to essentially be keywords of + * the ISC development environment. + */ + switch (type) { + case isc_assertiontype_require: + result = "REQUIRE"; + break; + case isc_assertiontype_ensure: + result = "ENSURE"; + break; + case isc_assertiontype_insist: + result = "INSIST"; + break; + case isc_assertiontype_invariant: + result = "INVARIANT"; + break; + default: + result = NULL; + } + return (result); +} + +/* + * Private. + */ + +static void +default_callback(const char *file, int line, isc_assertiontype_t type, + const char *cond) +{ + void *tracebuf[BACKTRACE_MAXFRAME]; + int i, nframes; + const char *logsuffix = "."; + const char *fname; + isc_result_t result; + + result = isc_backtrace_gettrace(tracebuf, BACKTRACE_MAXFRAME, &nframes); + if (result == ISC_R_SUCCESS && nframes > 0) + logsuffix = ", back trace"; + + fprintf(stderr, "%s:%d: %s(%s) %s%s\n", + file, line, isc_assertion_typetotext(type), cond, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), logsuffix); + if (result == ISC_R_SUCCESS) { + for (i = 0; i < nframes; i++) { + unsigned long offset; + + fname = NULL; + result = isc_backtrace_getsymbol(tracebuf[i], &fname, + &offset); + if (result == ISC_R_SUCCESS) { + fprintf(stderr, "#%d %p in %s()+0x%lx\n", i, + tracebuf[i], fname, offset); + } else { + fprintf(stderr, "#%d %p in ??\n", i, + tracebuf[i]); + } + } + } + fflush(stderr); +} diff --git a/contrib/ntp/lib/isc/backtrace-emptytbl.c b/contrib/ntp/lib/isc/backtrace-emptytbl.c new file mode 100644 index 000000000..bd534d60c --- /dev/null +++ b/contrib/ntp/lib/isc/backtrace-emptytbl.c @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: backtrace-emptytbl.c,v 1.3 2009/09/01 20:13:44 each Exp $ */ + +/*! \file */ + +/* + * This file defines an empty (default) symbol table used in backtrace.c + * If the application wants to have a complete symbol table, it should redefine + * isc__backtrace_symtable with the complete table in some way, and link the + * version of the library not including this definition + * (e.g. libisc-nosymbol.a). + */ + +#include + +#include + +const int isc__backtrace_nsymbols = 0; +const isc_backtrace_symmap_t isc__backtrace_symtable[] = { { NULL, "" } }; diff --git a/contrib/ntp/lib/isc/backtrace.c b/contrib/ntp/lib/isc/backtrace.c new file mode 100644 index 000000000..4274da31b --- /dev/null +++ b/contrib/ntp/lib/isc/backtrace.c @@ -0,0 +1,285 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: backtrace.c,v 1.3 2009/09/02 23:48:02 tbox Exp $ */ + +/*! \file */ + +#include "config.h" + +#include +#include +#ifdef HAVE_LIBCTRACE +#include +#endif + +#include +#include +#include + +#ifdef ISC_PLATFORM_USEBACKTRACE +/* + * Getting a back trace of a running process is tricky and highly platform + * dependent. Our current approach is as follows: + * 1. If the system library supports the "backtrace()" function, use it. + * 2. Otherwise, if the compiler is gcc and the architecture is x86_64 or IA64, + * then use gcc's (hidden) Unwind_Backtrace() function. Note that this + * function doesn't work for C programs on many other architectures. + * 3. Otherwise, if the architecture x86 or x86_64, try to unwind the stack + * frame following frame pointers. This assumes the executable binary + * compiled with frame pointers; this is not always true for x86_64 (rather, + * compiler optimizations often disable frame pointers). The validation + * checks in getnextframeptr() hopefully rejects bogus values stored in + * the RBP register in such a case. If the backtrace function itself crashes + * due to this problem, the whole package should be rebuilt with + * --disable-backtrace. + */ +#ifdef HAVE_LIBCTRACE +#define BACKTRACE_LIBC +#elif defined(__GNUC__) && (defined(__x86_64__) || defined(__ia64__)) +#define BACKTRACE_GCC +#elif defined(__x86_64__) || defined(__i386__) +#define BACKTRACE_X86STACK +#else +#define BACKTRACE_DISABLED +#endif /* HAVE_LIBCTRACE */ +#else /* !ISC_PLATFORM_USEBACKTRACE */ +#define BACKTRACE_DISABLED +#endif /* ISC_PLATFORM_USEBACKTRACE */ + +#ifdef BACKTRACE_LIBC +isc_result_t +isc_backtrace_gettrace(void **addrs, int maxaddrs, int *nframes) { + int n; + + /* + * Validate the arguments: intentionally avoid using REQUIRE(). + * See notes in backtrace.h. + */ + if (addrs == NULL || nframes == NULL) + return (ISC_R_FAILURE); + + /* + * backtrace(3) includes this function itself in the address array, + * which should be eliminated from the returned sequence. + */ + n = backtrace(addrs, maxaddrs); + if (n < 2) + return (ISC_R_NOTFOUND); + n--; + memmove(addrs, &addrs[1], sizeof(void *) * n); + *nframes = n; + return (ISC_R_SUCCESS); +} +#elif defined(BACKTRACE_GCC) +extern int _Unwind_Backtrace(void* fn, void* a); +extern void* _Unwind_GetIP(void* ctx); + +typedef struct { + void **result; + int max_depth; + int skip_count; + int count; +} trace_arg_t; + +static int +btcallback(void *uc, void *opq) { + trace_arg_t *arg = (trace_arg_t *)opq; + + if (arg->skip_count > 0) + arg->skip_count--; + else + arg->result[arg->count++] = (void *)_Unwind_GetIP(uc); + if (arg->count == arg->max_depth) + return (5); /* _URC_END_OF_STACK */ + + return (0); /* _URC_NO_REASON */ +} + +isc_result_t +isc_backtrace_gettrace(void **addrs, int maxaddrs, int *nframes) { + trace_arg_t arg; + + /* Argument validation: see above. */ + if (addrs == NULL || nframes == NULL) + return (ISC_R_FAILURE); + + arg.skip_count = 1; + arg.result = addrs; + arg.max_depth = maxaddrs; + arg.count = 0; + _Unwind_Backtrace(btcallback, &arg); + + *nframes = arg.count; + + return (ISC_R_SUCCESS); +} +#elif defined(BACKTRACE_X86STACK) +#ifdef __x86_64__ +static unsigned long +getrbp() { + __asm("movq %rbp, %rax\n"); +} +#endif + +static void ** +getnextframeptr(void **sp) { + void **newsp = (void **)*sp; + + /* + * Perform sanity check for the new frame pointer, derived from + * google glog. This can actually be bogus depending on compiler. + */ + + /* prohibit the stack frames from growing downwards */ + if (newsp <= sp) + return (NULL); + + /* A heuristics to reject "too large" frame: this actually happened. */ + if ((char *)newsp - (char *)sp > 100000) + return (NULL); + + /* + * Not sure if other checks used in glog are needed at this moment. + * For our purposes we don't have to consider non-contiguous frames, + * for example. + */ + + return (newsp); +} + +isc_result_t +isc_backtrace_gettrace(void **addrs, int maxaddrs, int *nframes) { + int i = 0; + void **sp; + + /* Argument validation: see above. */ + if (addrs == NULL || nframes == NULL) + return (ISC_R_FAILURE); + +#ifdef __x86_64__ + sp = (void **)getrbp(); + if (sp == NULL) + return (ISC_R_NOTFOUND); + /* + * sp is the frame ptr of this function itself due to the call to + * getrbp(), so need to unwind one frame for consistency. + */ + sp = getnextframeptr(sp); +#else + /* + * i386: the frame pointer is stored 2 words below the address for the + * first argument. Note that the body of this function cannot be + * inlined since it depends on the address of the function argument. + */ + sp = (void **)&addrs - 2; +#endif + + while (sp != NULL && i < maxaddrs) { + addrs[i++] = *(sp + 1); + sp = getnextframeptr(sp); + } + + *nframes = i; + + return (ISC_R_SUCCESS); +} +#elif defined(BACKTRACE_DISABLED) +isc_result_t +isc_backtrace_gettrace(void **addrs, int maxaddrs, int *nframes) { + /* Argument validation: see above. */ + if (addrs == NULL || nframes == NULL) + return (ISC_R_FAILURE); + + UNUSED(maxaddrs); + + return (ISC_R_NOTIMPLEMENTED); +} +#endif + +isc_result_t +isc_backtrace_getsymbolfromindex(int idx, const void **addrp, + const char **symbolp) +{ + REQUIRE(addrp != NULL && *addrp == NULL); + REQUIRE(symbolp != NULL && *symbolp == NULL); + + if (idx < 0 || idx >= isc__backtrace_nsymbols) + return (ISC_R_RANGE); + + *addrp = isc__backtrace_symtable[idx].addr; + *symbolp = isc__backtrace_symtable[idx].symbol; + return (ISC_R_SUCCESS); +} + +static int +symtbl_compare(const void *addr, const void *entryarg) { + const isc_backtrace_symmap_t *entry = entryarg; + const isc_backtrace_symmap_t *end = + &isc__backtrace_symtable[isc__backtrace_nsymbols - 1]; + + if (isc__backtrace_nsymbols == 1 || entry == end) { + if (addr >= entry->addr) { + /* + * If addr is equal to or larger than that of the last + * entry of the table, we cannot be sure if this is + * within a valid range so we consider it valid. + */ + return (0); + } + return (-1); + } + + /* entry + 1 is a valid entry from now on. */ + if (addr < entry->addr) + return (-1); + else if (addr >= (entry + 1)->addr) + return (1); + return (0); +} + +isc_result_t +isc_backtrace_getsymbol(const void *addr, const char **symbolp, + unsigned long *offsetp) +{ + isc_result_t result = ISC_R_SUCCESS; + isc_backtrace_symmap_t *found; + + /* + * Validate the arguments: intentionally avoid using REQUIRE(). + * See notes in backtrace.h. + */ + if (symbolp == NULL || *symbolp != NULL || offsetp == NULL) + return (ISC_R_FAILURE); + + if (isc__backtrace_nsymbols < 1) + return (ISC_R_NOTFOUND); + + /* + * Search the table for the entry that meets: + * entry.addr <= addr < next_entry.addr. + */ + found = bsearch(addr, isc__backtrace_symtable, isc__backtrace_nsymbols, + sizeof(isc__backtrace_symtable[0]), symtbl_compare); + if (found == NULL) + result = ISC_R_NOTFOUND; + else { + *symbolp = found->symbol; + *offsetp = (const char *)addr - (char *)found->addr; + } + + return (result); +} diff --git a/contrib/ntp/lib/isc/base32.c b/contrib/ntp/lib/isc/base32.c new file mode 100644 index 000000000..d25e3c471 --- /dev/null +++ b/contrib/ntp/lib/isc/base32.c @@ -0,0 +1,373 @@ +/* + * Copyright (C) 2008, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base32.c,v 1.6 2009/10/21 01:22:29 each Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include + +#define RETERR(x) do { \ + isc_result_t _r = (x); \ + if (_r != ISC_R_SUCCESS) \ + return (_r); \ + } while (0) + + +/*@{*/ +/*! + * These static functions are also present in lib/dns/rdata.c. I'm not + * sure where they should go. -- bwelling + */ +static isc_result_t +str_totext(const char *source, isc_buffer_t *target); + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length); + +/*@}*/ + +static const char base32[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567=abcdefghijklmnopqrstuvwxyz234567"; +static const char base32hex[] = + "0123456789ABCDEFGHIJKLMNOPQRSTUV=0123456789abcdefghijklmnopqrstuv"; + +static isc_result_t +base32_totext(isc_region_t *source, int wordlength, const char *wordbreak, + isc_buffer_t *target, const char base[]) +{ + char buf[9]; + unsigned int loops = 0; + + if (wordlength >= 0 && wordlength < 8) + wordlength = 8; + + memset(buf, 0, sizeof(buf)); + while (source->length > 0) { + buf[0] = base[((source->base[0]>>3)&0x1f)]; /* 5 + */ + if (source->length == 1) { + buf[1] = base[(source->base[0]<<2)&0x1c]; + buf[2] = buf[3] = buf[4] = '='; + buf[5] = buf[6] = buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[1] = base[((source->base[0]<<2)&0x1c)| /* 3 = 8 */ + ((source->base[1]>>6)&0x03)]; /* 2 + */ + buf[2] = base[((source->base[1]>>1)&0x1f)]; /* 5 + */ + if (source->length == 2) { + buf[3] = base[(source->base[1]<<4)&0x10]; + buf[4] = buf[5] = buf[6] = buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[3] = base[((source->base[1]<<4)&0x10)| /* 1 = 8 */ + ((source->base[2]>>4)&0x0f)]; /* 4 + */ + if (source->length == 3) { + buf[4] = base[(source->base[2]<<1)&0x1e]; + buf[5] = buf[6] = buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[4] = base[((source->base[2]<<1)&0x1e)| /* 4 = 8 */ + ((source->base[3]>>7)&0x01)]; /* 1 + */ + buf[5] = base[((source->base[3]>>2)&0x1f)]; /* 5 + */ + if (source->length == 4) { + buf[6] = base[(source->base[3]<<3)&0x18]; + buf[7] = '='; + RETERR(str_totext(buf, target)); + break; + } + buf[6] = base[((source->base[3]<<3)&0x18)| /* 2 = 8 */ + ((source->base[4]>>5)&0x07)]; /* 3 + */ + buf[7] = base[source->base[4]&0x1f]; /* 5 = 8 */ + RETERR(str_totext(buf, target)); + isc_region_consume(source, 5); + + loops++; + if (source->length != 0 && wordlength >= 0 && + (int)((loops + 1) * 8) >= wordlength) + { + loops = 0; + RETERR(str_totext(wordbreak, target)); + } + } + if (source->length > 0) + isc_region_consume(source, source->length); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + return (base32_totext(source, wordlength, wordbreak, target, base32)); +} + +isc_result_t +isc_base32hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + return (base32_totext(source, wordlength, wordbreak, target, + base32hex)); +} + +/*% + * State of a base32 decoding process in progress. + */ +typedef struct { + int length; /*%< Desired length of binary data or -1 */ + isc_buffer_t *target; /*%< Buffer for resulting binary data */ + int digits; /*%< Number of buffered base32 digits */ + isc_boolean_t seen_end; /*%< True if "=" end marker seen */ + int val[8]; + const char *base; /*%< Which encoding we are using */ + int seen_32; /*%< Number of significant bytes if non zero */ +} base32_decode_ctx_t; + +static inline void +base32_decode_init(base32_decode_ctx_t *ctx, int length, + const char base[], isc_buffer_t *target) +{ + ctx->digits = 0; + ctx->seen_end = ISC_FALSE; + ctx->seen_32 = 0; + ctx->length = length; + ctx->target = target; + ctx->base = base; +} + +static inline isc_result_t +base32_decode_char(base32_decode_ctx_t *ctx, int c) { + char *s; + unsigned int last; + + if (ctx->seen_end) + return (ISC_R_BADBASE32); + if ((s = strchr(ctx->base, c)) == NULL) + return (ISC_R_BADBASE32); + last = s - ctx->base; + /* + * Handle lower case. + */ + if (last > 32) + last -= 33; + /* + * Check that padding is contiguous. + */ + if (last != 32 && ctx->seen_32 != 0) + return (ISC_R_BADBASE32); + /* + * Check that padding starts at the right place and that + * bits that should be zero are. + * Record how many significant bytes in answer (seen_32). + */ + if (last == 32 && ctx->seen_32 == 0) + switch (ctx->digits) { + case 0: + case 1: + return (ISC_R_BADBASE32); + case 2: + if ((ctx->val[1]&0x03) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 1; + break; + case 3: + return (ISC_R_BADBASE32); + case 4: + if ((ctx->val[3]&0x0f) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 3; + break; + case 5: + if ((ctx->val[4]&0x01) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 3; + break; + case 6: + return (ISC_R_BADBASE32); + case 7: + if ((ctx->val[6]&0x07) != 0) + return (ISC_R_BADBASE32); + ctx->seen_32 = 4; + break; + } + /* + * Zero fill pad values. + */ + ctx->val[ctx->digits++] = (last == 32) ? 0 : last; + + if (ctx->digits == 8) { + int n = 5; + unsigned char buf[5]; + + if (ctx->seen_32 != 0) { + ctx->seen_end = ISC_TRUE; + n = ctx->seen_32; + } + buf[0] = (ctx->val[0]<<3)|(ctx->val[1]>>2); + buf[1] = (ctx->val[1]<<6)|(ctx->val[2]<<1)|(ctx->val[3]>>4); + buf[2] = (ctx->val[3]<<4)|(ctx->val[4]>>1); + buf[3] = (ctx->val[4]<<7)|(ctx->val[5]<<2)|(ctx->val[6]>>3); + buf[4] = (ctx->val[6]<<5)|(ctx->val[7]); + RETERR(mem_tobuffer(ctx->target, buf, n)); + if (ctx->length >= 0) { + if (n > ctx->length) + return (ISC_R_BADBASE32); + else + ctx->length -= n; + } + ctx->digits = 0; + } + return (ISC_R_SUCCESS); +} + +static inline isc_result_t +base32_decode_finish(base32_decode_ctx_t *ctx) { + if (ctx->length > 0) + return (ISC_R_UNEXPECTEDEND); + if (ctx->digits != 0) + return (ISC_R_BADBASE32); + return (ISC_R_SUCCESS); +} + +static isc_result_t +base32_tobuffer(isc_lex_t *lexer, const char base[], isc_buffer_t *target, + int length) +{ + base32_decode_ctx_t ctx; + isc_textregion_t *tr; + isc_token_t token; + isc_boolean_t eol; + + base32_decode_init(&ctx, length, base, target); + + while (!ctx.seen_end && (ctx.length != 0)) { + unsigned int i; + + if (length > 0) + eol = ISC_FALSE; + else + eol = ISC_TRUE; + RETERR(isc_lex_getmastertoken(lexer, &token, + isc_tokentype_string, eol)); + if (token.type != isc_tokentype_string) + break; + tr = &token.value.as_textregion; + for (i = 0; i < tr->length; i++) + RETERR(base32_decode_char(&ctx, tr->base[i])); + } + if (ctx.length < 0 && !ctx.seen_end) + isc_lex_ungettoken(lexer, &token); + RETERR(base32_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + return (base32_tobuffer(lexer, base32, target, length)); +} + +isc_result_t +isc_base32hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + return (base32_tobuffer(lexer, base32hex, target, length)); +} + +static isc_result_t +base32_decodestring(const char *cstr, const char base[], isc_buffer_t *target) { + base32_decode_ctx_t ctx; + + base32_decode_init(&ctx, -1, base, target); + for (;;) { + int c = *cstr++; + if (c == '\0') + break; + if (c == ' ' || c == '\t' || c == '\n' || c== '\r') + continue; + RETERR(base32_decode_char(&ctx, c)); + } + RETERR(base32_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_decodestring(const char *cstr, isc_buffer_t *target) { + return (base32_decodestring(cstr, base32, target)); +} + +isc_result_t +isc_base32hex_decodestring(const char *cstr, isc_buffer_t *target) { + return (base32_decodestring(cstr, base32hex, target)); +} + +static isc_result_t +base32_decoderegion(isc_region_t *source, const char base[], isc_buffer_t *target) { + base32_decode_ctx_t ctx; + + base32_decode_init(&ctx, -1, base, target); + while (source->length != 0) { + int c = *source->base; + RETERR(base32_decode_char(&ctx, c)); + isc_region_consume(source, 1); + } + RETERR(base32_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base32_decoderegion(isc_region_t *source, isc_buffer_t *target) { + return (base32_decoderegion(source, base32, target)); +} + +isc_result_t +isc_base32hex_decoderegion(isc_region_t *source, isc_buffer_t *target) { + return (base32_decoderegion(source, base32hex, target)); +} + +static isc_result_t +str_totext(const char *source, isc_buffer_t *target) { + unsigned int l; + isc_region_t region; + + isc_buffer_availableregion(target, ®ion); + l = strlen(source); + + if (l > region.length) + return (ISC_R_NOSPACE); + + memcpy(region.base, source, l); + isc_buffer_add(target, l); + return (ISC_R_SUCCESS); +} + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length) { + isc_region_t tr; + + isc_buffer_availableregion(target, &tr); + if (length > tr.length) + return (ISC_R_NOSPACE); + memcpy(tr.base, base, length); + isc_buffer_add(target, length); + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/base64.c b/contrib/ntp/lib/isc/base64.c new file mode 100644 index 000000000..bad1565be --- /dev/null +++ b/contrib/ntp/lib/isc/base64.c @@ -0,0 +1,252 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base64.c,v 1.34 2009/10/21 23:48:05 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include + +#define RETERR(x) do { \ + isc_result_t _r = (x); \ + if (_r != ISC_R_SUCCESS) \ + return (_r); \ + } while (0) + + +/*@{*/ +/*! + * These static functions are also present in lib/dns/rdata.c. I'm not + * sure where they should go. -- bwelling + */ +static isc_result_t +str_totext(const char *source, isc_buffer_t *target); + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length); + +static const char base64[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="; +/*@}*/ + +isc_result_t +isc_base64_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + char buf[5]; + unsigned int loops = 0; + + if (wordlength < 4) + wordlength = 4; + + memset(buf, 0, sizeof(buf)); + while (source->length > 2) { + buf[0] = base64[(source->base[0]>>2)&0x3f]; + buf[1] = base64[((source->base[0]<<4)&0x30)| + ((source->base[1]>>4)&0x0f)]; + buf[2] = base64[((source->base[1]<<2)&0x3c)| + ((source->base[2]>>6)&0x03)]; + buf[3] = base64[source->base[2]&0x3f]; + RETERR(str_totext(buf, target)); + isc_region_consume(source, 3); + + loops++; + if (source->length != 0 && + (int)((loops + 1) * 4) >= wordlength) + { + loops = 0; + RETERR(str_totext(wordbreak, target)); + } + } + if (source->length == 2) { + buf[0] = base64[(source->base[0]>>2)&0x3f]; + buf[1] = base64[((source->base[0]<<4)&0x30)| + ((source->base[1]>>4)&0x0f)]; + buf[2] = base64[((source->base[1]<<2)&0x3c)]; + buf[3] = '='; + RETERR(str_totext(buf, target)); + isc_region_consume(source, 2); + } else if (source->length == 1) { + buf[0] = base64[(source->base[0]>>2)&0x3f]; + buf[1] = base64[((source->base[0]<<4)&0x30)]; + buf[2] = buf[3] = '='; + RETERR(str_totext(buf, target)); + isc_region_consume(source, 1); + } + return (ISC_R_SUCCESS); +} + +/*% + * State of a base64 decoding process in progress. + */ +typedef struct { + int length; /*%< Desired length of binary data or -1 */ + isc_buffer_t *target; /*%< Buffer for resulting binary data */ + int digits; /*%< Number of buffered base64 digits */ + isc_boolean_t seen_end; /*%< True if "=" end marker seen */ + int val[4]; +} base64_decode_ctx_t; + +static inline void +base64_decode_init(base64_decode_ctx_t *ctx, int length, isc_buffer_t *target) +{ + ctx->digits = 0; + ctx->seen_end = ISC_FALSE; + ctx->length = length; + ctx->target = target; +} + +static inline isc_result_t +base64_decode_char(base64_decode_ctx_t *ctx, int c) { + char *s; + + if (ctx->seen_end) + return (ISC_R_BADBASE64); + if ((s = strchr(base64, c)) == NULL) + return (ISC_R_BADBASE64); + ctx->val[ctx->digits++] = s - base64; + if (ctx->digits == 4) { + int n; + unsigned char buf[3]; + if (ctx->val[0] == 64 || ctx->val[1] == 64) + return (ISC_R_BADBASE64); + if (ctx->val[2] == 64 && ctx->val[3] != 64) + return (ISC_R_BADBASE64); + /* + * Check that bits that should be zero are. + */ + if (ctx->val[2] == 64 && (ctx->val[1] & 0xf) != 0) + return (ISC_R_BADBASE64); + /* + * We don't need to test for ctx->val[2] != 64 as + * the bottom two bits of 64 are zero. + */ + if (ctx->val[3] == 64 && (ctx->val[2] & 0x3) != 0) + return (ISC_R_BADBASE64); + n = (ctx->val[2] == 64) ? 1 : + (ctx->val[3] == 64) ? 2 : 3; + if (n != 3) { + ctx->seen_end = ISC_TRUE; + if (ctx->val[2] == 64) + ctx->val[2] = 0; + if (ctx->val[3] == 64) + ctx->val[3] = 0; + } + buf[0] = (ctx->val[0]<<2)|(ctx->val[1]>>4); + buf[1] = (ctx->val[1]<<4)|(ctx->val[2]>>2); + buf[2] = (ctx->val[2]<<6)|(ctx->val[3]); + RETERR(mem_tobuffer(ctx->target, buf, n)); + if (ctx->length >= 0) { + if (n > ctx->length) + return (ISC_R_BADBASE64); + else + ctx->length -= n; + } + ctx->digits = 0; + } + return (ISC_R_SUCCESS); +} + +static inline isc_result_t +base64_decode_finish(base64_decode_ctx_t *ctx) { + if (ctx->length > 0) + return (ISC_R_UNEXPECTEDEND); + if (ctx->digits != 0) + return (ISC_R_BADBASE64); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base64_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + base64_decode_ctx_t ctx; + isc_textregion_t *tr; + isc_token_t token; + isc_boolean_t eol; + + base64_decode_init(&ctx, length, target); + + while (!ctx.seen_end && (ctx.length != 0)) { + unsigned int i; + + if (length > 0) + eol = ISC_FALSE; + else + eol = ISC_TRUE; + RETERR(isc_lex_getmastertoken(lexer, &token, + isc_tokentype_string, eol)); + if (token.type != isc_tokentype_string) + break; + tr = &token.value.as_textregion; + for (i = 0; i < tr->length; i++) + RETERR(base64_decode_char(&ctx, tr->base[i])); + } + if (ctx.length < 0 && !ctx.seen_end) + isc_lex_ungettoken(lexer, &token); + RETERR(base64_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_base64_decodestring(const char *cstr, isc_buffer_t *target) { + base64_decode_ctx_t ctx; + + base64_decode_init(&ctx, -1, target); + for (;;) { + int c = *cstr++; + if (c == '\0') + break; + if (c == ' ' || c == '\t' || c == '\n' || c== '\r') + continue; + RETERR(base64_decode_char(&ctx, c)); + } + RETERR(base64_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +static isc_result_t +str_totext(const char *source, isc_buffer_t *target) { + unsigned int l; + isc_region_t region; + + isc_buffer_availableregion(target, ®ion); + l = strlen(source); + + if (l > region.length) + return (ISC_R_NOSPACE); + + memcpy(region.base, source, l); + isc_buffer_add(target, l); + return (ISC_R_SUCCESS); +} + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length) { + isc_region_t tr; + + isc_buffer_availableregion(target, &tr); + if (length > tr.length) + return (ISC_R_NOSPACE); + memcpy(tr.base, base, length); + isc_buffer_add(target, length); + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/bitstring.c b/contrib/ntp/lib/isc/bitstring.c new file mode 100644 index 000000000..33c7c1fa6 --- /dev/null +++ b/contrib/ntp/lib/isc/bitstring.c @@ -0,0 +1,127 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bitstring.c,v 1.17 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include + +#define DIV8(x) ((x) >> 3) +#define MOD8(x) ((x) & 0x00000007U) +#define OCTETS(n) (((n) + 7) >> 3) +#define PADDED(n) ((((n) + 7) >> 3) << 3) +#define BITSET(bs, n) (((bs)->data[DIV8(n)] & \ + (1 << (7 - MOD8(n)))) != 0) +#define SETBIT(bs, n) (bs)->data[DIV8(n)] |= (1 << (7 - MOD8(n))) +#define CLEARBIT(bs, n) (bs)->data[DIV8(n)] &= ~(1 << (7 - MOD8(n))) + +#define BITSTRING_MAGIC ISC_MAGIC('B', 'S', 't', 'r') +#define VALID_BITSTRING(b) ISC_MAGIC_VALID(b, BITSTRING_MAGIC) + +void +isc_bitstring_init(isc_bitstring_t *bitstring, unsigned char *data, + unsigned int length, unsigned int size, isc_boolean_t lsb0) +{ + /* + * Make 'bitstring' refer to the bitstring of 'size' bits starting + * at 'data'. 'length' bits of the bitstring are valid. If 'lsb0' + * is set then, bit 0 refers to the least significant bit of the + * bitstring. Otherwise bit 0 is the most significant bit. + */ + + REQUIRE(bitstring != NULL); + REQUIRE(data != NULL); + REQUIRE(length <= size); + + bitstring->magic = BITSTRING_MAGIC; + bitstring->data = data; + bitstring->length = length; + bitstring->size = size; + bitstring->lsb0 = lsb0; +} + +void +isc_bitstring_invalidate(isc_bitstring_t *bitstring) { + + /* + * Invalidate 'bitstring'. + */ + + REQUIRE(VALID_BITSTRING(bitstring)); + + bitstring->magic = 0; + bitstring->data = NULL; + bitstring->length = 0; + bitstring->size = 0; + bitstring->lsb0 = ISC_FALSE; +} + +void +isc_bitstring_copy(isc_bitstring_t *source, unsigned int sbitpos, + isc_bitstring_t *target, unsigned int tbitpos, + unsigned int n) +{ + unsigned int tlast; + + /* + * Starting at bit 'sbitpos', copy 'n' bits from 'source' to + * the 'n' bits of 'target' starting at 'tbitpos'. + */ + + REQUIRE(VALID_BITSTRING(source)); + REQUIRE(VALID_BITSTRING(target)); + REQUIRE(source->lsb0 == target->lsb0); + if (source->lsb0) { + REQUIRE(sbitpos <= source->length); + sbitpos = PADDED(source->size) - sbitpos; + REQUIRE(sbitpos >= n); + sbitpos -= n; + } else + REQUIRE(sbitpos + n <= source->length); + tlast = tbitpos + n; + if (target->lsb0) { + REQUIRE(tbitpos <= target->length); + tbitpos = PADDED(target->size) - tbitpos; + REQUIRE(tbitpos >= n); + tbitpos -= n; + } else + REQUIRE(tlast <= target->size); + + if (tlast > target->length) + target->length = tlast; + + /* + * This is far from optimal... + */ + + while (n > 0) { + if (BITSET(source, sbitpos)) + SETBIT(target, tbitpos); + else + CLEARBIT(target, tbitpos); + sbitpos++; + tbitpos++; + n--; + } +} diff --git a/contrib/ntp/lib/isc/buffer.c b/contrib/ntp/lib/isc/buffer.c new file mode 100644 index 000000000..1b59e650a --- /dev/null +++ b/contrib/ntp/lib/isc/buffer.c @@ -0,0 +1,489 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: buffer.c,v 1.49 2008/09/25 04:02:39 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include + +void +isc__buffer_init(isc_buffer_t *b, const void *base, unsigned int length) { + /* + * Make 'b' refer to the 'length'-byte region starting at 'base'. + * XXXDCL see the comment in buffer.h about base being const. + */ + + REQUIRE(b != NULL); + + ISC__BUFFER_INIT(b, base, length); +} + +void +isc__buffer_initnull(isc_buffer_t *b) { + /* + * Initialize a new buffer which has no backing store. This can + * later be grown as needed and swapped in place. + */ + + ISC__BUFFER_INIT(b, NULL, 0); +} + +void +isc_buffer_reinit(isc_buffer_t *b, void *base, unsigned int length) { + /* + * Re-initialize the buffer enough to reconfigure the base of the + * buffer. We will swap in the new buffer, after copying any + * data we contain into the new buffer and adjusting all of our + * internal pointers. + * + * The buffer must not be smaller than the length of the original + * buffer. + */ + REQUIRE(b->length <= length); + REQUIRE(base != NULL); + + (void)memmove(base, b->base, b->length); + b->base = base; + b->length = length; +} + +void +isc__buffer_invalidate(isc_buffer_t *b) { + /* + * Make 'b' an invalid buffer. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(!ISC_LINK_LINKED(b, link)); + REQUIRE(b->mctx == NULL); + + ISC__BUFFER_INVALIDATE(b); +} + +void +isc__buffer_region(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_REGION(b, r); +} + +void +isc__buffer_usedregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the used region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_USEDREGION(b, r); +} + +void +isc__buffer_availableregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the available region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_AVAILABLEREGION(b, r); +} + +void +isc__buffer_add(isc_buffer_t *b, unsigned int n) { + /* + * Increase the 'used' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + n <= b->length); + + ISC__BUFFER_ADD(b, n); +} + +void +isc__buffer_subtract(isc_buffer_t *b, unsigned int n) { + /* + * Decrease the 'used' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used >= n); + + ISC__BUFFER_SUBTRACT(b, n); +} + +void +isc__buffer_clear(isc_buffer_t *b) { + /* + * Make the used region empty. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + + ISC__BUFFER_CLEAR(b); +} + +void +isc__buffer_consumedregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the consumed region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_CONSUMEDREGION(b, r); +} + +void +isc__buffer_remainingregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the remaining region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_REMAININGREGION(b, r); +} + +void +isc__buffer_activeregion(isc_buffer_t *b, isc_region_t *r) { + /* + * Make 'r' refer to the active region of 'b'. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + ISC__BUFFER_ACTIVEREGION(b, r); +} + +void +isc__buffer_setactive(isc_buffer_t *b, unsigned int n) { + /* + * Sets the end of the active region 'n' bytes after current. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->current + n <= b->used); + + ISC__BUFFER_SETACTIVE(b, n); +} + +void +isc__buffer_first(isc_buffer_t *b) { + /* + * Make the consumed region empty. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + + ISC__BUFFER_FIRST(b); +} + +void +isc__buffer_forward(isc_buffer_t *b, unsigned int n) { + /* + * Increase the 'consumed' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->current + n <= b->used); + + ISC__BUFFER_FORWARD(b, n); +} + +void +isc__buffer_back(isc_buffer_t *b, unsigned int n) { + /* + * Decrease the 'consumed' region of 'b' by 'n' bytes. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(n <= b->current); + + ISC__BUFFER_BACK(b, n); +} + +void +isc_buffer_compact(isc_buffer_t *b) { + unsigned int length; + void *src; + + /* + * Compact the used region by moving the remaining region so it occurs + * at the start of the buffer. The used region is shrunk by the size + * of the consumed region, and the consumed region is then made empty. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + + src = isc_buffer_current(b); + length = isc_buffer_remaininglength(b); + (void)memmove(b->base, src, (size_t)length); + + if (b->active > b->current) + b->active -= b->current; + else + b->active = 0; + b->current = 0; + b->used = length; +} + +isc_uint8_t +isc_buffer_getuint8(isc_buffer_t *b) { + unsigned char *cp; + isc_uint8_t result; + + /* + * Read an unsigned 8-bit integer from 'b' and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 1); + + cp = isc_buffer_current(b); + b->current += 1; + result = ((isc_uint8_t)(cp[0])); + + return (result); +} + +void +isc__buffer_putuint8(isc_buffer_t *b, isc_uint8_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 1 <= b->length); + + ISC__BUFFER_PUTUINT8(b, val); +} + +isc_uint16_t +isc_buffer_getuint16(isc_buffer_t *b) { + unsigned char *cp; + isc_uint16_t result; + + /* + * Read an unsigned 16-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 2); + + cp = isc_buffer_current(b); + b->current += 2; + result = ((unsigned int)(cp[0])) << 8; + result |= ((unsigned int)(cp[1])); + + return (result); +} + +void +isc__buffer_putuint16(isc_buffer_t *b, isc_uint16_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 2 <= b->length); + + ISC__BUFFER_PUTUINT16(b, val); +} + +void +isc__buffer_putuint24(isc_buffer_t *b, isc_uint32_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 3 <= b->length); + + ISC__BUFFER_PUTUINT24(b, val); +} + +isc_uint32_t +isc_buffer_getuint32(isc_buffer_t *b) { + unsigned char *cp; + isc_uint32_t result; + + /* + * Read an unsigned 32-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 4); + + cp = isc_buffer_current(b); + b->current += 4; + result = ((unsigned int)(cp[0])) << 24; + result |= ((unsigned int)(cp[1])) << 16; + result |= ((unsigned int)(cp[2])) << 8; + result |= ((unsigned int)(cp[3])); + + return (result); +} + +void +isc__buffer_putuint32(isc_buffer_t *b, isc_uint32_t val) { + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 4 <= b->length); + + ISC__BUFFER_PUTUINT32(b, val); +} + +isc_uint64_t +isc_buffer_getuint48(isc_buffer_t *b) { + unsigned char *cp; + isc_uint64_t result; + + /* + * Read an unsigned 48-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + */ + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used - b->current >= 6); + + cp = isc_buffer_current(b); + b->current += 6; + result = ((isc_int64_t)(cp[0])) << 40; + result |= ((isc_int64_t)(cp[1])) << 32; + result |= ((isc_int64_t)(cp[2])) << 24; + result |= ((isc_int64_t)(cp[3])) << 16; + result |= ((isc_int64_t)(cp[4])) << 8; + result |= ((isc_int64_t)(cp[5])); + + return (result); +} + +void +isc__buffer_putuint48(isc_buffer_t *b, isc_uint64_t val) { + isc_uint16_t valhi; + isc_uint32_t vallo; + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + 6 <= b->length); + + valhi = (isc_uint16_t)(val >> 32); + vallo = (isc_uint32_t)(val & 0xFFFFFFFF); + ISC__BUFFER_PUTUINT16(b, valhi); + ISC__BUFFER_PUTUINT32(b, vallo); +} + +void +isc__buffer_putmem(isc_buffer_t *b, const unsigned char *base, + unsigned int length) +{ + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(b->used + length <= b->length); + + ISC__BUFFER_PUTMEM(b, base, length); +} + +void +isc__buffer_putstr(isc_buffer_t *b, const char *source) { + unsigned int l; + unsigned char *cp; + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(source != NULL); + + /* + * Do not use ISC__BUFFER_PUTSTR(), so strlen is only done once. + */ + l = strlen(source); + + REQUIRE(l <= isc_buffer_availablelength(b)); + + cp = isc_buffer_used(b); + memcpy(cp, source, l); + b->used += l; +} + +isc_result_t +isc_buffer_copyregion(isc_buffer_t *b, const isc_region_t *r) { + unsigned char *base; + unsigned int available; + + REQUIRE(ISC_BUFFER_VALID(b)); + REQUIRE(r != NULL); + + /* + * XXXDCL + */ + base = isc_buffer_used(b); + available = isc_buffer_availablelength(b); + if (r->length > available) + return (ISC_R_NOSPACE); + memcpy(base, r->base, r->length); + b->used += r->length; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_buffer_allocate(isc_mem_t *mctx, isc_buffer_t **dynbuffer, + unsigned int length) +{ + isc_buffer_t *dbuf; + + REQUIRE(dynbuffer != NULL); + REQUIRE(*dynbuffer == NULL); + + dbuf = isc_mem_get(mctx, length + sizeof(isc_buffer_t)); + if (dbuf == NULL) + return (ISC_R_NOMEMORY); + + isc_buffer_init(dbuf, ((unsigned char *)dbuf) + sizeof(isc_buffer_t), + length); + dbuf->mctx = mctx; + + *dynbuffer = dbuf; + + return (ISC_R_SUCCESS); +} + +void +isc_buffer_free(isc_buffer_t **dynbuffer) { + unsigned int real_length; + isc_buffer_t *dbuf; + isc_mem_t *mctx; + + REQUIRE(dynbuffer != NULL); + REQUIRE(ISC_BUFFER_VALID(*dynbuffer)); + REQUIRE((*dynbuffer)->mctx != NULL); + + dbuf = *dynbuffer; + *dynbuffer = NULL; /* destroy external reference */ + + real_length = dbuf->length + sizeof(isc_buffer_t); + mctx = dbuf->mctx; + dbuf->mctx = NULL; + isc_buffer_invalidate(dbuf); + + isc_mem_put(mctx, dbuf, real_length); +} diff --git a/contrib/ntp/lib/isc/bufferlist.c b/contrib/ntp/lib/isc/bufferlist.c new file mode 100644 index 000000000..0e5c1251b --- /dev/null +++ b/contrib/ntp/lib/isc/bufferlist.c @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bufferlist.c,v 1.17 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include + +unsigned int +isc_bufferlist_usedcount(isc_bufferlist_t *bl) { + isc_buffer_t *buffer; + unsigned int length; + + REQUIRE(bl != NULL); + + length = 0; + buffer = ISC_LIST_HEAD(*bl); + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + length += isc_buffer_usedlength(buffer); + buffer = ISC_LIST_NEXT(buffer, link); + } + + return (length); +} + +unsigned int +isc_bufferlist_availablecount(isc_bufferlist_t *bl) { + isc_buffer_t *buffer; + unsigned int length; + + REQUIRE(bl != NULL); + + length = 0; + buffer = ISC_LIST_HEAD(*bl); + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + length += isc_buffer_availablelength(buffer); + buffer = ISC_LIST_NEXT(buffer, link); + } + + return (length); +} diff --git a/contrib/ntp/lib/isc/commandline.c b/contrib/ntp/lib/isc/commandline.c new file mode 100644 index 000000000..aca1203ce --- /dev/null +++ b/contrib/ntp/lib/isc/commandline.c @@ -0,0 +1,225 @@ +/* + * Portions Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Portions Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Copyright (c) 1987, 1993, 1994 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/* $Id: commandline.c,v 1.22 2008/09/25 04:02:39 tbox Exp $ */ + +/*! \file + * This file was adapted from the NetBSD project's source tree, RCS ID: + * NetBSD: getopt.c,v 1.15 1999/09/20 04:39:37 lukem Exp + * + * The primary change has been to rename items to the ISC namespace + * and format in the ISC coding style. + */ + +/* + * \author Principal Authors: Computer Systems Research Group at UC Berkeley + * \author Principal ISC caretaker: DCL + */ + +#include + +#include + +#include +#include +#include +#include + +/*% Index into parent argv vector. */ +LIBISC_EXTERNAL_DATA int isc_commandline_index = 1; +/*% Character checked for validity. */ +LIBISC_EXTERNAL_DATA int isc_commandline_option; +/*% Argument associated with option. */ +LIBISC_EXTERNAL_DATA char *isc_commandline_argument; +/*% For printing error messages. */ +LIBISC_EXTERNAL_DATA char *isc_commandline_progname; +/*% Print error messages. */ +LIBISC_EXTERNAL_DATA isc_boolean_t isc_commandline_errprint = ISC_TRUE; +/*% Reset processing. */ +LIBISC_EXTERNAL_DATA isc_boolean_t isc_commandline_reset = ISC_TRUE; + +static char endopt = '\0'; + +#define BADOPT '?' +#define BADARG ':' +#define ENDOPT &endopt + +/*! + * getopt -- + * Parse argc/argv argument vector. + */ +int +isc_commandline_parse(int argc, char * const *argv, const char *options) { + static char *place = ENDOPT; + char *option; /* Index into *options of option. */ + + REQUIRE(argc >= 0 && argv != NULL && options != NULL); + + /* + * Update scanning pointer, either because a reset was requested or + * the previous argv was finished. + */ + if (isc_commandline_reset || *place == '\0') { + if (isc_commandline_reset) { + isc_commandline_index = 1; + isc_commandline_reset = ISC_FALSE; + } + + if (isc_commandline_progname == NULL) + isc_commandline_progname = argv[0]; + + if (isc_commandline_index >= argc || + *(place = argv[isc_commandline_index]) != '-') { + /* + * Index out of range or points to non-option. + */ + place = ENDOPT; + return (-1); + } + + if (place[1] != '\0' && *++place == '-' && place[1] == '\0') { + /* + * Found '--' to signal end of options. Advance + * index to next argv, the first non-option. + */ + isc_commandline_index++; + place = ENDOPT; + return (-1); + } + } + + isc_commandline_option = *place++; + option = strchr(options, isc_commandline_option); + + /* + * Ensure valid option has been passed as specified by options string. + * '-:' is never a valid command line option because it could not + * distinguish ':' from the argument specifier in the options string. + */ + if (isc_commandline_option == ':' || option == NULL) { + if (*place == '\0') + isc_commandline_index++; + + if (isc_commandline_errprint && *options != ':') + fprintf(stderr, "%s: %s -- %c\n", + isc_commandline_progname, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_COMMANDLINE, + ISC_MSG_ILLEGALOPT, + "illegal option"), + isc_commandline_option); + + return (BADOPT); + } + + if (*++option != ':') { + /* + * Option does not take an argument. + */ + isc_commandline_argument = NULL; + + /* + * Skip to next argv if at the end of the current argv. + */ + if (*place == '\0') + ++isc_commandline_index; + + } else { + /* + * Option needs an argument. + */ + if (*place != '\0') + /* + * Option is in this argv, -D1 style. + */ + isc_commandline_argument = place; + + else if (argc > ++isc_commandline_index) + /* + * Option is next argv, -D 1 style. + */ + isc_commandline_argument = argv[isc_commandline_index]; + + else { + /* + * Argument needed, but no more argv. + */ + place = ENDOPT; + + /* + * Silent failure with "missing argument" return + * when ':' starts options string, per historical spec. + */ + if (*options == ':') + return (BADARG); + + if (isc_commandline_errprint) + fprintf(stderr, "%s: %s -- %c\n", + isc_commandline_progname, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_COMMANDLINE, + ISC_MSG_OPTNEEDARG, + "option requires " + "an argument"), + isc_commandline_option); + + return (BADOPT); + } + + place = ENDOPT; + + /* + * Point to argv that follows argument. + */ + isc_commandline_index++; + } + + return (isc_commandline_option); +} diff --git a/contrib/ntp/lib/isc/entropy.c b/contrib/ntp/lib/isc/entropy.c new file mode 100644 index 000000000..da9e81fb3 --- /dev/null +++ b/contrib/ntp/lib/isc/entropy.c @@ -0,0 +1,1277 @@ +/* + * Copyright (C) 2004-2007, 2009, 2010 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: entropy.c,v 1.22 2010/08/10 23:48:19 tbox Exp $ */ + +/*! \file + * \brief + * This is the system independent part of the entropy module. It is + * compiled via inclusion from the relevant OS source file, ie, + * \link unix/entropy.c unix/entropy.c \endlink or win32/entropy.c. + * + * \author Much of this code is modeled after the NetBSD /dev/random implementation, + * written by Michael Graff . + */ + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + + +#define ENTROPY_MAGIC ISC_MAGIC('E', 'n', 't', 'e') +#define SOURCE_MAGIC ISC_MAGIC('E', 'n', 't', 's') + +#define VALID_ENTROPY(e) ISC_MAGIC_VALID(e, ENTROPY_MAGIC) +#define VALID_SOURCE(s) ISC_MAGIC_VALID(s, SOURCE_MAGIC) + +/*** + *** "constants." Do not change these unless you _really_ know what + *** you are doing. + ***/ + +/*% + * Size of entropy pool in 32-bit words. This _MUST_ be a power of 2. + */ +#define RND_POOLWORDS 128 +/*% Pool in bytes. */ +#define RND_POOLBYTES (RND_POOLWORDS * 4) +/*% Pool in bits. */ +#define RND_POOLBITS (RND_POOLWORDS * 32) + +/*% + * Number of bytes returned per hash. This must be true: + * threshold * 2 <= digest_size_in_bytes + */ +#define RND_ENTROPY_THRESHOLD 10 +#define THRESHOLD_BITS (RND_ENTROPY_THRESHOLD * 8) + +/*% + * Size of the input event queue in samples. + */ +#define RND_EVENTQSIZE 32 + +/*% + * The number of times we'll "reseed" for pseudorandom seeds. This is an + * extremely weak pseudorandom seed. If the caller is using lots of + * pseudorandom data and they cannot provide a stronger random source, + * there is little we can do other than hope they're smart enough to + * call _adddata() with something better than we can come up with. + */ +#define RND_INITIALIZE 128 + +/*% Entropy Pool */ +typedef struct { + isc_uint32_t cursor; /*%< current add point in the pool */ + isc_uint32_t entropy; /*%< current entropy estimate in bits */ + isc_uint32_t pseudo; /*%< bits extracted in pseudorandom */ + isc_uint32_t rotate; /*%< how many bits to rotate by */ + isc_uint32_t pool[RND_POOLWORDS]; /*%< random pool data */ +} isc_entropypool_t; + +struct isc_entropy { + unsigned int magic; + isc_mem_t *mctx; + isc_mutex_t lock; + unsigned int refcnt; + isc_uint32_t initialized; + isc_uint32_t initcount; + isc_entropypool_t pool; + unsigned int nsources; + isc_entropysource_t *nextsource; + ISC_LIST(isc_entropysource_t) sources; +}; + +/*% Sample Queue */ +typedef struct { + isc_uint32_t last_time; /*%< last time recorded */ + isc_uint32_t last_delta; /*%< last delta value */ + isc_uint32_t last_delta2; /*%< last delta2 value */ + isc_uint32_t nsamples; /*%< number of samples filled in */ + isc_uint32_t *samples; /*%< the samples */ + isc_uint32_t *extra; /*%< extra samples added in */ +} sample_queue_t; + +typedef struct { + sample_queue_t samplequeue; +} isc_entropysamplesource_t; + +typedef struct { + isc_boolean_t start_called; + isc_entropystart_t startfunc; + isc_entropyget_t getfunc; + isc_entropystop_t stopfunc; + void *arg; + sample_queue_t samplequeue; +} isc_cbsource_t; + +typedef struct { + FILESOURCE_HANDLE_TYPE handle; +} isc_entropyfilesource_t; + +struct isc_entropysource { + unsigned int magic; + unsigned int type; + isc_entropy_t *ent; + isc_uint32_t total; /*%< entropy from this source */ + ISC_LINK(isc_entropysource_t) link; + char name[32]; + isc_boolean_t bad; + isc_boolean_t warn_keyboard; + isc_keyboard_t kbd; + union { + isc_entropysamplesource_t sample; + isc_entropyfilesource_t file; + isc_cbsource_t callback; + isc_entropyusocketsource_t usocket; + } sources; +}; + +#define ENTROPY_SOURCETYPE_SAMPLE 1 /*%< Type is a sample source */ +#define ENTROPY_SOURCETYPE_FILE 2 /*%< Type is a file source */ +#define ENTROPY_SOURCETYPE_CALLBACK 3 /*%< Type is a callback source */ +#define ENTROPY_SOURCETYPE_USOCKET 4 /*%< Type is a Unix socket source */ + +/*@{*/ +/*% + * The random pool "taps" + */ +#define TAP1 99 +#define TAP2 59 +#define TAP3 31 +#define TAP4 9 +#define TAP5 7 +/*@}*/ + +/*@{*/ +/*% + * Declarations for function provided by the system dependent sources that + * include this file. + */ +static void +fillpool(isc_entropy_t *, unsigned int, isc_boolean_t); + +static int +wait_for_sources(isc_entropy_t *); + +static void +destroyfilesource(isc_entropyfilesource_t *source); + +static void +destroyusocketsource(isc_entropyusocketsource_t *source); + +/*@}*/ + +static void +samplequeue_release(isc_entropy_t *ent, sample_queue_t *sq) { + REQUIRE(sq->samples != NULL); + REQUIRE(sq->extra != NULL); + + isc_mem_put(ent->mctx, sq->samples, RND_EVENTQSIZE * 4); + isc_mem_put(ent->mctx, sq->extra, RND_EVENTQSIZE * 4); + sq->samples = NULL; + sq->extra = NULL; +} + +static isc_result_t +samplesource_allocate(isc_entropy_t *ent, sample_queue_t *sq) { + sq->samples = isc_mem_get(ent->mctx, RND_EVENTQSIZE * 4); + if (sq->samples == NULL) + return (ISC_R_NOMEMORY); + + sq->extra = isc_mem_get(ent->mctx, RND_EVENTQSIZE * 4); + if (sq->extra == NULL) { + isc_mem_put(ent->mctx, sq->samples, RND_EVENTQSIZE * 4); + sq->samples = NULL; + return (ISC_R_NOMEMORY); + } + + sq->nsamples = 0; + + return (ISC_R_SUCCESS); +} + +/*% + * Add in entropy, even when the value we're adding in could be + * very large. + */ +static inline void +add_entropy(isc_entropy_t *ent, isc_uint32_t entropy) { + /* clamp input. Yes, this must be done. */ + entropy = ISC_MIN(entropy, RND_POOLBITS); + /* Add in the entropy we already have. */ + entropy += ent->pool.entropy; + /* Clamp. */ + ent->pool.entropy = ISC_MIN(entropy, RND_POOLBITS); +} + +/*% + * Decrement the amount of entropy the pool has. + */ +static inline void +subtract_entropy(isc_entropy_t *ent, isc_uint32_t entropy) { + entropy = ISC_MIN(entropy, ent->pool.entropy); + ent->pool.entropy -= entropy; +} + +/*! + * Add in entropy, even when the value we're adding in could be + * very large. + */ +static inline void +add_pseudo(isc_entropy_t *ent, isc_uint32_t pseudo) { + /* clamp input. Yes, this must be done. */ + pseudo = ISC_MIN(pseudo, RND_POOLBITS * 8); + /* Add in the pseudo we already have. */ + pseudo += ent->pool.pseudo; + /* Clamp. */ + ent->pool.pseudo = ISC_MIN(pseudo, RND_POOLBITS * 8); +} + +/*! + * Decrement the amount of pseudo the pool has. + */ +static inline void +subtract_pseudo(isc_entropy_t *ent, isc_uint32_t pseudo) { + pseudo = ISC_MIN(pseudo, ent->pool.pseudo); + ent->pool.pseudo -= pseudo; +} + +/*! + * Add one word to the pool, rotating the input as needed. + */ +static inline void +entropypool_add_word(isc_entropypool_t *rp, isc_uint32_t val) { + /* + * Steal some values out of the pool, and xor them into the + * word we were given. + * + * Mix the new value into the pool using xor. This will + * prevent the actual values from being known to the caller + * since the previous values are assumed to be unknown as well. + */ + val ^= rp->pool[(rp->cursor + TAP1) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP2) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP3) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP4) & (RND_POOLWORDS - 1)]; + val ^= rp->pool[(rp->cursor + TAP5) & (RND_POOLWORDS - 1)]; + if (rp->rotate == 0) + rp->pool[rp->cursor++] ^= val; + else + rp->pool[rp->cursor++] ^= + ((val << rp->rotate) | (val >> (32 - rp->rotate))); + + /* + * If we have looped around the pool, increment the rotate + * variable so the next value will get xored in rotated to + * a different position. + * Increment by a value that is relatively prime to the word size + * to try to spread the bits throughout the pool quickly when the + * pool is empty. + */ + if (rp->cursor == RND_POOLWORDS) { + rp->cursor = 0; + rp->rotate = (rp->rotate + 7) & 31; + } +} + +/*! + * Add a buffer's worth of data to the pool. + * + * Requires that the lock is held on the entropy pool. + */ +static void +entropypool_adddata(isc_entropy_t *ent, void *p, unsigned int len, + isc_uint32_t entropy) +{ + isc_uint32_t val; + unsigned long addr; + isc_uint8_t *buf; + + addr = (unsigned long)p; + buf = p; + + if ((addr & 0x03U) != 0U) { + val = 0; + switch (len) { + case 3: + val = *buf++; + len--; + case 2: + val = val << 8 | *buf++; + len--; + case 1: + val = val << 8 | *buf++; + len--; + } + + entropypool_add_word(&ent->pool, val); + } + + for (; len > 3; len -= 4) { + val = *((isc_uint32_t *)buf); + + entropypool_add_word(&ent->pool, val); + buf += 4; + } + + if (len != 0) { + val = 0; + switch (len) { + case 3: + val = *buf++; + case 2: + val = val << 8 | *buf++; + case 1: + val = val << 8 | *buf++; + } + + entropypool_add_word(&ent->pool, val); + } + + add_entropy(ent, entropy); + subtract_pseudo(ent, entropy); +} + +static inline void +reseed(isc_entropy_t *ent) { + isc_time_t t; + pid_t pid; + + if (ent->initcount == 0) { + pid = getpid(); + entropypool_adddata(ent, &pid, sizeof(pid), 0); + pid = getppid(); + entropypool_adddata(ent, &pid, sizeof(pid), 0); + } + + /*! + * After we've reseeded 100 times, only add new timing info every + * 50 requests. This will keep us from using lots and lots of + * CPU just to return bad pseudorandom data anyway. + */ + if (ent->initcount > 100) + if ((ent->initcount % 50) != 0) + return; + + TIME_NOW(&t); + entropypool_adddata(ent, &t, sizeof(t), 0); + ent->initcount++; +} + +static inline unsigned int +estimate_entropy(sample_queue_t *sq, isc_uint32_t t) { + isc_int32_t delta; + isc_int32_t delta2; + isc_int32_t delta3; + + /*! + * If the time counter has overflowed, calculate the real difference. + * If it has not, it is simpler. + */ + if (t < sq->last_time) + delta = UINT_MAX - sq->last_time + t; + else + delta = sq->last_time - t; + + if (delta < 0) + delta = -delta; + + /* + * Calculate the second and third order differentials + */ + delta2 = sq->last_delta - delta; + if (delta2 < 0) + delta2 = -delta2; + + delta3 = sq->last_delta2 - delta2; + if (delta3 < 0) + delta3 = -delta3; + + sq->last_time = t; + sq->last_delta = delta; + sq->last_delta2 = delta2; + + /* + * If any delta is 0, we got no entropy. If all are non-zero, we + * might have something. + */ + if (delta == 0 || delta2 == 0 || delta3 == 0) + return 0; + + /* + * We could find the smallest delta and claim we got log2(delta) + * bits, but for now return that we found 1 bit. + */ + return 1; +} + +static unsigned int +crunchsamples(isc_entropy_t *ent, sample_queue_t *sq) { + unsigned int ns; + unsigned int added; + + if (sq->nsamples < 6) + return (0); + + added = 0; + sq->last_time = sq->samples[0]; + sq->last_delta = 0; + sq->last_delta2 = 0; + + /* + * Prime the values by adding in the first 4 samples in. This + * should completely initialize the delta calculations. + */ + for (ns = 0; ns < 4; ns++) + (void)estimate_entropy(sq, sq->samples[ns]); + + for (ns = 4; ns < sq->nsamples; ns++) + added += estimate_entropy(sq, sq->samples[ns]); + + entropypool_adddata(ent, sq->samples, sq->nsamples * 4, added); + entropypool_adddata(ent, sq->extra, sq->nsamples * 4, 0); + + /* + * Move the last 4 samples into the first 4 positions, and start + * adding new samples from that point. + */ + for (ns = 0; ns < 4; ns++) { + sq->samples[ns] = sq->samples[sq->nsamples - 4 + ns]; + sq->extra[ns] = sq->extra[sq->nsamples - 4 + ns]; + } + + sq->nsamples = 4; + + return (added); +} + +static unsigned int +get_from_callback(isc_entropysource_t *source, unsigned int desired, + isc_boolean_t blocking) +{ + isc_entropy_t *ent = source->ent; + isc_cbsource_t *cbs = &source->sources.callback; + unsigned int added; + unsigned int got; + isc_result_t result; + + if (desired == 0) + return (0); + + if (source->bad) + return (0); + + if (!cbs->start_called && cbs->startfunc != NULL) { + result = cbs->startfunc(source, cbs->arg, blocking); + if (result != ISC_R_SUCCESS) + return (0); + cbs->start_called = ISC_TRUE; + } + + added = 0; + result = ISC_R_SUCCESS; + while (desired > 0 && result == ISC_R_SUCCESS) { + result = cbs->getfunc(source, cbs->arg, blocking); + if (result == ISC_R_QUEUEFULL) { + got = crunchsamples(ent, &cbs->samplequeue); + added += got; + desired -= ISC_MIN(got, desired); + result = ISC_R_SUCCESS; + } else if (result != ISC_R_SUCCESS && + result != ISC_R_NOTBLOCKING) + source->bad = ISC_TRUE; + + } + + return (added); +} + +/* + * Extract some number of bytes from the random pool, decreasing the + * estimate of randomness as each byte is extracted. + * + * Do this by stiring the pool and returning a part of hash as randomness. + * Note that no secrets are given away here since parts of the hash are + * xored together before returned. + * + * Honor the request from the caller to only return good data, any data, + * etc. + */ +isc_result_t +isc_entropy_getdata(isc_entropy_t *ent, void *data, unsigned int length, + unsigned int *returned, unsigned int flags) +{ + unsigned int i; + isc_sha1_t hash; + unsigned char digest[ISC_SHA1_DIGESTLENGTH]; + isc_uint32_t remain, deltae, count, total; + isc_uint8_t *buf; + isc_boolean_t goodonly, partial, blocking; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(data != NULL); + REQUIRE(length > 0); + + goodonly = ISC_TF((flags & ISC_ENTROPY_GOODONLY) != 0); + partial = ISC_TF((flags & ISC_ENTROPY_PARTIAL) != 0); + blocking = ISC_TF((flags & ISC_ENTROPY_BLOCKING) != 0); + + REQUIRE(!partial || returned != NULL); + + LOCK(&ent->lock); + + remain = length; + buf = data; + total = 0; + while (remain != 0) { + count = ISC_MIN(remain, RND_ENTROPY_THRESHOLD); + + /* + * If we are extracting good data only, make certain we + * have enough data in our pool for this pass. If we don't, + * get some, and fail if we can't, and partial returns + * are not ok. + */ + if (goodonly) { + unsigned int fillcount; + + fillcount = ISC_MAX(remain * 8, count * 8); + + /* + * If, however, we have at least THRESHOLD_BITS + * of entropy in the pool, don't block here. It is + * better to drain the pool once in a while and + * then refill it than it is to constantly keep the + * pool full. + */ + if (ent->pool.entropy >= THRESHOLD_BITS) + fillpool(ent, fillcount, ISC_FALSE); + else + fillpool(ent, fillcount, blocking); + + /* + * Verify that we got enough entropy to do one + * extraction. If we didn't, bail. + */ + if (ent->pool.entropy < THRESHOLD_BITS) { + if (!partial) + goto zeroize; + else + goto partial_output; + } + } else { + /* + * If we've extracted half our pool size in bits + * since the last refresh, try to refresh here. + */ + if (ent->initialized < THRESHOLD_BITS) + fillpool(ent, THRESHOLD_BITS, blocking); + else + fillpool(ent, 0, ISC_FALSE); + + /* + * If we've not initialized with enough good random + * data, seed with our crappy code. + */ + if (ent->initialized < THRESHOLD_BITS) + reseed(ent); + } + + isc_sha1_init(&hash); + isc_sha1_update(&hash, (void *)(ent->pool.pool), + RND_POOLBYTES); + isc_sha1_final(&hash, digest); + + /* + * Stir the extracted data (all of it) back into the pool. + */ + entropypool_adddata(ent, digest, ISC_SHA1_DIGESTLENGTH, 0); + + for (i = 0; i < count; i++) + buf[i] = digest[i] ^ digest[i + RND_ENTROPY_THRESHOLD]; + + buf += count; + remain -= count; + + deltae = count * 8; + deltae = ISC_MIN(deltae, ent->pool.entropy); + total += deltae; + subtract_entropy(ent, deltae); + add_pseudo(ent, count * 8); + } + + partial_output: + memset(digest, 0, sizeof(digest)); + + if (returned != NULL) + *returned = (length - remain); + + UNLOCK(&ent->lock); + + return (ISC_R_SUCCESS); + + zeroize: + /* put the entropy we almost extracted back */ + add_entropy(ent, total); + memset(data, 0, length); + memset(digest, 0, sizeof(digest)); + if (returned != NULL) + *returned = 0; + + UNLOCK(&ent->lock); + + return (ISC_R_NOENTROPY); +} + +static void +isc_entropypool_init(isc_entropypool_t *pool) { + pool->cursor = RND_POOLWORDS - 1; + pool->entropy = 0; + pool->pseudo = 0; + pool->rotate = 0; + memset(pool->pool, 0, RND_POOLBYTES); +} + +static void +isc_entropypool_invalidate(isc_entropypool_t *pool) { + pool->cursor = 0; + pool->entropy = 0; + pool->pseudo = 0; + pool->rotate = 0; + memset(pool->pool, 0, RND_POOLBYTES); +} + +isc_result_t +isc_entropy_create(isc_mem_t *mctx, isc_entropy_t **entp) { + isc_result_t result; + isc_entropy_t *ent; + + REQUIRE(mctx != NULL); + REQUIRE(entp != NULL && *entp == NULL); + + ent = isc_mem_get(mctx, sizeof(isc_entropy_t)); + if (ent == NULL) + return (ISC_R_NOMEMORY); + + /* + * We need a lock. + */ + result = isc_mutex_init(&ent->lock); + if (result != ISC_R_SUCCESS) + goto errout; + + /* + * From here down, no failures will/can occur. + */ + ISC_LIST_INIT(ent->sources); + ent->nextsource = NULL; + ent->nsources = 0; + ent->mctx = NULL; + isc_mem_attach(mctx, &ent->mctx); + ent->refcnt = 1; + ent->initialized = 0; + ent->initcount = 0; + ent->magic = ENTROPY_MAGIC; + + isc_entropypool_init(&ent->pool); + + *entp = ent; + return (ISC_R_SUCCESS); + + errout: + isc_mem_put(mctx, ent, sizeof(isc_entropy_t)); + + return (result); +} + +/*! + * Requires "ent" be locked. + */ +static void +destroysource(isc_entropysource_t **sourcep) { + isc_entropysource_t *source; + isc_entropy_t *ent; + isc_cbsource_t *cbs; + + source = *sourcep; + *sourcep = NULL; + ent = source->ent; + + ISC_LIST_UNLINK(ent->sources, source, link); + ent->nextsource = NULL; + REQUIRE(ent->nsources > 0); + ent->nsources--; + + switch (source->type) { + case ENTROPY_SOURCETYPE_FILE: + if (! source->bad) + destroyfilesource(&source->sources.file); + break; + case ENTROPY_SOURCETYPE_USOCKET: + if (! source->bad) + destroyusocketsource(&source->sources.usocket); + break; + case ENTROPY_SOURCETYPE_SAMPLE: + samplequeue_release(ent, &source->sources.sample.samplequeue); + break; + case ENTROPY_SOURCETYPE_CALLBACK: + cbs = &source->sources.callback; + if (cbs->start_called && cbs->stopfunc != NULL) { + cbs->stopfunc(source, cbs->arg); + cbs->start_called = ISC_FALSE; + } + samplequeue_release(ent, &cbs->samplequeue); + break; + } + + memset(source, 0, sizeof(isc_entropysource_t)); + + isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t)); +} + +static inline isc_boolean_t +destroy_check(isc_entropy_t *ent) { + isc_entropysource_t *source; + + if (ent->refcnt > 0) + return (ISC_FALSE); + + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + switch (source->type) { + case ENTROPY_SOURCETYPE_FILE: + case ENTROPY_SOURCETYPE_USOCKET: + break; + default: + return (ISC_FALSE); + } + source = ISC_LIST_NEXT(source, link); + } + + return (ISC_TRUE); +} + +static void +destroy(isc_entropy_t **entp) { + isc_entropy_t *ent; + isc_entropysource_t *source; + isc_mem_t *mctx; + + REQUIRE(entp != NULL && *entp != NULL); + ent = *entp; + *entp = NULL; + + LOCK(&ent->lock); + + REQUIRE(ent->refcnt == 0); + + /* + * Here, detach non-sample sources. + */ + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + switch(source->type) { + case ENTROPY_SOURCETYPE_FILE: + case ENTROPY_SOURCETYPE_USOCKET: + destroysource(&source); + break; + } + source = ISC_LIST_HEAD(ent->sources); + } + + /* + * If there are other types of sources, we've found a bug. + */ + REQUIRE(ISC_LIST_EMPTY(ent->sources)); + + mctx = ent->mctx; + + isc_entropypool_invalidate(&ent->pool); + + UNLOCK(&ent->lock); + + DESTROYLOCK(&ent->lock); + + memset(ent, 0, sizeof(isc_entropy_t)); + isc_mem_put(mctx, ent, sizeof(isc_entropy_t)); + isc_mem_detach(&mctx); +} + +void +isc_entropy_destroysource(isc_entropysource_t **sourcep) { + isc_entropysource_t *source; + isc_entropy_t *ent; + isc_boolean_t killit; + + REQUIRE(sourcep != NULL); + REQUIRE(VALID_SOURCE(*sourcep)); + + source = *sourcep; + *sourcep = NULL; + + ent = source->ent; + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + + destroysource(&source); + + killit = destroy_check(ent); + + UNLOCK(&ent->lock); + + if (killit) + destroy(&ent); +} + +isc_result_t +isc_entropy_createcallbacksource(isc_entropy_t *ent, + isc_entropystart_t start, + isc_entropyget_t get, + isc_entropystop_t stop, + void *arg, + isc_entropysource_t **sourcep) +{ + isc_result_t result; + isc_entropysource_t *source; + isc_cbsource_t *cbs; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(get != NULL); + REQUIRE(sourcep != NULL && *sourcep == NULL); + + LOCK(&ent->lock); + + source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t)); + if (source == NULL) { + result = ISC_R_NOMEMORY; + goto errout; + } + source->bad = ISC_FALSE; + + cbs = &source->sources.callback; + + result = samplesource_allocate(ent, &cbs->samplequeue); + if (result != ISC_R_SUCCESS) + goto errout; + + cbs->start_called = ISC_FALSE; + cbs->startfunc = start; + cbs->getfunc = get; + cbs->stopfunc = stop; + cbs->arg = arg; + + /* + * From here down, no failures can occur. + */ + source->magic = SOURCE_MAGIC; + source->type = ENTROPY_SOURCETYPE_CALLBACK; + source->ent = ent; + source->total = 0; + memset(source->name, 0, sizeof(source->name)); + ISC_LINK_INIT(source, link); + + /* + * Hook it into the entropy system. + */ + ISC_LIST_APPEND(ent->sources, source, link); + ent->nsources++; + + *sourcep = source; + + UNLOCK(&ent->lock); + return (ISC_R_SUCCESS); + + errout: + if (source != NULL) + isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t)); + + UNLOCK(&ent->lock); + + return (result); +} + +void +isc_entropy_stopcallbacksources(isc_entropy_t *ent) { + isc_entropysource_t *source; + isc_cbsource_t *cbs; + + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + if (source->type == ENTROPY_SOURCETYPE_CALLBACK) { + cbs = &source->sources.callback; + if (cbs->start_called && cbs->stopfunc != NULL) { + cbs->stopfunc(source, cbs->arg); + cbs->start_called = ISC_FALSE; + } + } + + source = ISC_LIST_NEXT(source, link); + } + + UNLOCK(&ent->lock); +} + +isc_result_t +isc_entropy_createsamplesource(isc_entropy_t *ent, + isc_entropysource_t **sourcep) +{ + isc_result_t result; + isc_entropysource_t *source; + sample_queue_t *sq; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(sourcep != NULL && *sourcep == NULL); + + LOCK(&ent->lock); + + source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t)); + if (source == NULL) { + result = ISC_R_NOMEMORY; + goto errout; + } + + sq = &source->sources.sample.samplequeue; + result = samplesource_allocate(ent, sq); + if (result != ISC_R_SUCCESS) + goto errout; + + /* + * From here down, no failures can occur. + */ + source->magic = SOURCE_MAGIC; + source->type = ENTROPY_SOURCETYPE_SAMPLE; + source->ent = ent; + source->total = 0; + memset(source->name, 0, sizeof(source->name)); + ISC_LINK_INIT(source, link); + + /* + * Hook it into the entropy system. + */ + ISC_LIST_APPEND(ent->sources, source, link); + ent->nsources++; + + *sourcep = source; + + UNLOCK(&ent->lock); + return (ISC_R_SUCCESS); + + errout: + if (source != NULL) + isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t)); + + UNLOCK(&ent->lock); + + return (result); +} + +/*! + * Add a sample, and return ISC_R_SUCCESS if the queue has become full, + * ISC_R_NOENTROPY if it has space remaining, and ISC_R_NOMORE if the + * queue was full when this function was called. + */ +static isc_result_t +addsample(sample_queue_t *sq, isc_uint32_t sample, isc_uint32_t extra) { + if (sq->nsamples >= RND_EVENTQSIZE) + return (ISC_R_NOMORE); + + sq->samples[sq->nsamples] = sample; + sq->extra[sq->nsamples] = extra; + sq->nsamples++; + + if (sq->nsamples >= RND_EVENTQSIZE) + return (ISC_R_QUEUEFULL); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_entropy_addsample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra) +{ + isc_entropy_t *ent; + sample_queue_t *sq; + unsigned int entropy; + isc_result_t result; + + REQUIRE(VALID_SOURCE(source)); + + ent = source->ent; + + LOCK(&ent->lock); + + sq = &source->sources.sample.samplequeue; + result = addsample(sq, sample, extra); + if (result == ISC_R_QUEUEFULL) { + entropy = crunchsamples(ent, sq); + add_entropy(ent, entropy); + } + + UNLOCK(&ent->lock); + + return (result); +} + +isc_result_t +isc_entropy_addcallbacksample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra) +{ + sample_queue_t *sq; + isc_result_t result; + + REQUIRE(VALID_SOURCE(source)); + REQUIRE(source->type == ENTROPY_SOURCETYPE_CALLBACK); + + sq = &source->sources.callback.samplequeue; + result = addsample(sq, sample, extra); + + return (result); +} + +void +isc_entropy_putdata(isc_entropy_t *ent, void *data, unsigned int length, + isc_uint32_t entropy) +{ + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + + entropypool_adddata(ent, data, length, entropy); + + if (ent->initialized < THRESHOLD_BITS) + ent->initialized = THRESHOLD_BITS; + + UNLOCK(&ent->lock); +} + +static void +dumpstats(isc_entropy_t *ent, FILE *out) { + fprintf(out, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_ENTROPY, + ISC_MSG_ENTROPYSTATS, + "Entropy pool %p: refcnt %u cursor %u," + " rotate %u entropy %u pseudo %u nsources %u" + " nextsource %p initialized %u initcount %u\n"), + ent, ent->refcnt, + ent->pool.cursor, ent->pool.rotate, + ent->pool.entropy, ent->pool.pseudo, + ent->nsources, ent->nextsource, ent->initialized, + ent->initcount); +} + +/* + * This function ignores locking. Use at your own risk. + */ +void +isc_entropy_stats(isc_entropy_t *ent, FILE *out) { + REQUIRE(VALID_ENTROPY(ent)); + + LOCK(&ent->lock); + dumpstats(ent, out); + UNLOCK(&ent->lock); +} + +unsigned int +isc_entropy_status(isc_entropy_t *ent) { + unsigned int estimate; + + LOCK(&ent->lock); + estimate = ent->pool.entropy; + UNLOCK(&ent->lock); + + return estimate; +} + +void +isc_entropy_attach(isc_entropy_t *ent, isc_entropy_t **entp) { + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(entp != NULL && *entp == NULL); + + LOCK(&ent->lock); + + ent->refcnt++; + *entp = ent; + + UNLOCK(&ent->lock); +} + +void +isc_entropy_detach(isc_entropy_t **entp) { + isc_entropy_t *ent; + isc_boolean_t killit; + + REQUIRE(entp != NULL && VALID_ENTROPY(*entp)); + ent = *entp; + *entp = NULL; + + LOCK(&ent->lock); + + REQUIRE(ent->refcnt > 0); + ent->refcnt--; + + killit = destroy_check(ent); + + UNLOCK(&ent->lock); + + if (killit) + destroy(&ent); +} + +static isc_result_t +kbdstart(isc_entropysource_t *source, void *arg, isc_boolean_t blocking) { + /* + * The intent of "first" is to provide a warning message only once + * during the run of a program that might try to gather keyboard + * entropy multiple times. + */ + static isc_boolean_t first = ISC_TRUE; + + UNUSED(arg); + + if (! blocking) + return (ISC_R_NOENTROPY); + + if (first) { + if (source->warn_keyboard) + fprintf(stderr, "You must use the keyboard to create " + "entropy, since your system is lacking\n" + "/dev/random (or equivalent)\n\n"); + first = ISC_FALSE; + } + fprintf(stderr, "start typing:\n"); + + return (isc_keyboard_open(&source->kbd)); +} + +static void +kbdstop(isc_entropysource_t *source, void *arg) { + + UNUSED(arg); + + if (! isc_keyboard_canceled(&source->kbd)) + fprintf(stderr, "stop typing.\r\n"); + + (void)isc_keyboard_close(&source->kbd, 3); +} + +static isc_result_t +kbdget(isc_entropysource_t *source, void *arg, isc_boolean_t blocking) { + isc_result_t result; + isc_time_t t; + isc_uint32_t sample; + isc_uint32_t extra; + unsigned char c; + + UNUSED(arg); + + if (!blocking) + return (ISC_R_NOTBLOCKING); + + result = isc_keyboard_getchar(&source->kbd, &c); + if (result != ISC_R_SUCCESS) + return (result); + + TIME_NOW(&t); + + sample = isc_time_nanoseconds(&t); + extra = c; + + result = isc_entropy_addcallbacksample(source, sample, extra); + if (result != ISC_R_SUCCESS) { + fprintf(stderr, "\r\n"); + return (result); + } + + fprintf(stderr, "."); + fflush(stderr); + + return (result); +} + +isc_result_t +isc_entropy_usebestsource(isc_entropy_t *ectx, isc_entropysource_t **source, + const char *randomfile, int use_keyboard) +{ + isc_result_t result; + isc_result_t final_result = ISC_R_NOENTROPY; + isc_boolean_t userfile = ISC_TRUE; + + REQUIRE(VALID_ENTROPY(ectx)); + REQUIRE(source != NULL && *source == NULL); + REQUIRE(use_keyboard == ISC_ENTROPY_KEYBOARDYES || + use_keyboard == ISC_ENTROPY_KEYBOARDNO || + use_keyboard == ISC_ENTROPY_KEYBOARDMAYBE); + +#ifdef PATH_RANDOMDEV + if (randomfile == NULL) { + randomfile = PATH_RANDOMDEV; + userfile = ISC_FALSE; + } +#endif + + if (randomfile != NULL && use_keyboard != ISC_ENTROPY_KEYBOARDYES) { + result = isc_entropy_createfilesource(ectx, randomfile); + if (result == ISC_R_SUCCESS && + use_keyboard == ISC_ENTROPY_KEYBOARDMAYBE) + use_keyboard = ISC_ENTROPY_KEYBOARDNO; + if (result != ISC_R_SUCCESS && userfile) + return (result); + + final_result = result; + } + + if (use_keyboard != ISC_ENTROPY_KEYBOARDNO) { + result = isc_entropy_createcallbacksource(ectx, kbdstart, + kbdget, kbdstop, + NULL, source); + if (result == ISC_R_SUCCESS) + (*source)->warn_keyboard = + ISC_TF(use_keyboard == + ISC_ENTROPY_KEYBOARDMAYBE); + + if (final_result != ISC_R_SUCCESS) + final_result = result; + } + + /* + * final_result is ISC_R_SUCCESS if at least one source of entropy + * could be started, otherwise it is the error from the most recently + * failed operation (or ISC_R_NOENTROPY if PATH_RANDOMDEV is not + * defined and use_keyboard is ISC_ENTROPY_KEYBOARDNO). + */ + return (final_result); +} diff --git a/contrib/ntp/libisc/error.c b/contrib/ntp/lib/isc/error.c similarity index 74% rename from contrib/ntp/libisc/error.c rename to contrib/ntp/lib/isc/error.c index ed0469d10..095100a7c 100644 --- a/contrib/ntp/libisc/error.c +++ b/contrib/ntp/lib/isc/error.c @@ -1,21 +1,23 @@ /* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: error.c,v 1.16 2001/08/08 22:54:49 gson Exp $ */ +/* $Id: error.c,v 1.21 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ #include @@ -25,14 +27,17 @@ #include #include +/*% Default unexpected callback. */ static void default_unexpected_callback(const char *, int, const char *, va_list) ISC_FORMAT_PRINTF(3, 0); +/*% Default fatal callback. */ static void default_fatal_callback(const char *, int, const char *, va_list) ISC_FORMAT_PRINTF(3, 0); +/*% unexpected_callback */ static isc_errorcallback_t unexpected_callback = default_unexpected_callback; static isc_errorcallback_t fatal_callback = default_fatal_callback; diff --git a/contrib/ntp/lib/isc/event.c b/contrib/ntp/lib/isc/event.c new file mode 100644 index 000000000..e97961682 --- /dev/null +++ b/contrib/ntp/lib/isc/event.c @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: event.c,v 1.21 2007/06/19 23:47:17 tbox Exp $ */ + +/*! + * \file + * \author Principal Author: Bob Halley + */ + +#include + +#include +#include +#include + +/*** + *** Events. + ***/ + +static void +destroy(isc_event_t *event) { + isc_mem_put(event->ev_destroy_arg, event, event->ev_size); +} + +isc_event_t * +isc_event_allocate(isc_mem_t *mctx, void *sender, isc_eventtype_t type, + isc_taskaction_t action, const void *arg, size_t size) +{ + isc_event_t *event; + void *deconst_arg; + + REQUIRE(size >= sizeof(struct isc_event)); + REQUIRE(action != NULL); + + event = isc_mem_get(mctx, size); + if (event == NULL) + return (NULL); + + /* + * Removing the const attribute from "arg" is the best of two + * evils here. If the event->ev_arg member is made const, then + * it affects a great many users of the task/event subsystem + * which are not passing in an "arg" which starts its life as + * const. Changing isc_event_allocate() and isc_task_onshutdown() + * to not have "arg" prototyped as const (which is quite legitimate, + * because neither of those functions modify arg) can cause + * compiler whining anytime someone does want to use a const + * arg that they themselves never modify, such as with + * gcc -Wwrite-strings and using a string "arg". + */ + DE_CONST(arg, deconst_arg); + + ISC_EVENT_INIT(event, size, 0, NULL, type, action, deconst_arg, + sender, destroy, mctx); + + return (event); +} + +void +isc_event_free(isc_event_t **eventp) { + isc_event_t *event; + + REQUIRE(eventp != NULL); + event = *eventp; + REQUIRE(event != NULL); + + if (event->ev_destroy != NULL) + (event->ev_destroy)(event); + + *eventp = NULL; +} diff --git a/contrib/ntp/lib/isc/fsaccess.c b/contrib/ntp/lib/isc/fsaccess.c new file mode 100644 index 000000000..5c9718318 --- /dev/null +++ b/contrib/ntp/lib/isc/fsaccess.c @@ -0,0 +1,102 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: fsaccess.c,v 1.10 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file + * \brief + * This file contains the OS-independent functionality of the API. + */ +#include +#include +#include + +/*! + * Shorthand. Maybe ISC__FSACCESS_PERMISSIONBITS should not even be in + * . Could check consistency with sizeof(isc_fsaccess_t) + * and the number of bits in each function. + */ +#define STEP (ISC__FSACCESS_PERMISSIONBITS) +#define GROUP (STEP) +#define OTHER (STEP * 2) + +void +isc_fsaccess_add(int trustee, int permission, isc_fsaccess_t *access) { + REQUIRE(trustee <= 0x7); + REQUIRE(permission <= 0xFF); + + if ((trustee & ISC_FSACCESS_OWNER) != 0) + *access |= permission; + + if ((trustee & ISC_FSACCESS_GROUP) != 0) + *access |= (permission << GROUP); + + if ((trustee & ISC_FSACCESS_OTHER) != 0) + *access |= (permission << OTHER); +} + +void +isc_fsaccess_remove(int trustee, int permission, isc_fsaccess_t *access) { + REQUIRE(trustee <= 0x7); + REQUIRE(permission <= 0xFF); + + + if ((trustee & ISC_FSACCESS_OWNER) != 0) + *access &= ~permission; + + if ((trustee & ISC_FSACCESS_GROUP) != 0) + *access &= ~(permission << GROUP); + + if ((trustee & ISC_FSACCESS_OTHER) != 0) + *access &= ~(permission << OTHER); +} + +static isc_result_t +check_bad_bits(isc_fsaccess_t access, isc_boolean_t is_dir) { + isc_fsaccess_t bits; + + /* + * Check for disallowed user bits. + */ + if (is_dir) + bits = ISC_FSACCESS_READ | + ISC_FSACCESS_WRITE | + ISC_FSACCESS_EXECUTE; + else + bits = ISC_FSACCESS_CREATECHILD | + ISC_FSACCESS_ACCESSCHILD | + ISC_FSACCESS_DELETECHILD | + ISC_FSACCESS_LISTDIRECTORY; + + /* + * Set group bad bits. + */ + bits |= bits << STEP; + /* + * Set other bad bits. + */ + bits |= bits << STEP; + + if ((access & bits) != 0) { + if (is_dir) + return (ISC_R_NOTFILE); + else + return (ISC_R_NOTDIRECTORY); + } + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/hash.c b/contrib/ntp/lib/isc/hash.c new file mode 100644 index 000000000..f1d68c770 --- /dev/null +++ b/contrib/ntp/lib/isc/hash.c @@ -0,0 +1,404 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hash.c,v 1.16 2009/09/01 00:22:28 jinmei Exp $ */ + +/*! \file + * Some portion of this code was derived from universal hash function + * libraries of Rice University. +\section license UH Universal Hashing Library + +Copyright ((c)) 2002, Rice University +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials provided + with the distribution. + + * Neither the name of Rice University (RICE) nor the names of its + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + + +This software is provided by RICE and the contributors on an "as is" +basis, without any representations or warranties of any kind, express +or implied including, but not limited to, representations or +warranties of non-infringement, merchantability or fitness for a +particular purpose. In no event shall RICE or contributors be liable +for any direct, indirect, incidental, special, exemplary, or +consequential damages (including, but not limited to, procurement of +substitute goods or services; loss of use, data, or profits; or +business interruption) however caused and on any theory of liability, +whether in contract, strict liability, or tort (including negligence +or otherwise) arising in any way out of the use of this software, even +if advised of the possibility of such damage. +*/ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define HASH_MAGIC ISC_MAGIC('H', 'a', 's', 'h') +#define VALID_HASH(h) ISC_MAGIC_VALID((h), HASH_MAGIC) + +/*% + * A large 32-bit prime number that specifies the range of the hash output. + */ +#define PRIME32 0xFFFFFFFB /* 2^32 - 5 */ + +/*@{*/ +/*% + * Types of random seed and hash accumulator. Perhaps they can be system + * dependent. + */ +typedef isc_uint32_t hash_accum_t; +typedef isc_uint16_t hash_random_t; +/*@}*/ + +/*% isc hash structure */ +struct isc_hash { + unsigned int magic; + isc_mem_t *mctx; + isc_mutex_t lock; + isc_boolean_t initialized; + isc_refcount_t refcnt; + isc_entropy_t *entropy; /*%< entropy source */ + unsigned int limit; /*%< upper limit of key length */ + size_t vectorlen; /*%< size of the vector below */ + hash_random_t *rndvector; /*%< random vector for universal hashing */ +}; + +static isc_mutex_t createlock; +static isc_once_t once = ISC_ONCE_INIT; +static isc_hash_t *hash = NULL; + +static unsigned char maptolower[] = { + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, + 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, + 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, + 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, + 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, + 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, + 0x40, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x5b, 0x5c, 0x5d, 0x5e, 0x5f, + 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x67, + 0x68, 0x69, 0x6a, 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, + 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, + 0x78, 0x79, 0x7a, 0x7b, 0x7c, 0x7d, 0x7e, 0x7f, + 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, + 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, + 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, + 0x98, 0x99, 0x9a, 0x9b, 0x9c, 0x9d, 0x9e, 0x9f, + 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, + 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, + 0xb0, 0xb1, 0xb2, 0xb3, 0xb4, 0xb5, 0xb6, 0xb7, + 0xb8, 0xb9, 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, + 0xc0, 0xc1, 0xc2, 0xc3, 0xc4, 0xc5, 0xc6, 0xc7, + 0xc8, 0xc9, 0xca, 0xcb, 0xcc, 0xcd, 0xce, 0xcf, + 0xd0, 0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd6, 0xd7, + 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xdf, + 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, + 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef, + 0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, + 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff +}; + +isc_result_t +isc_hash_ctxcreate(isc_mem_t *mctx, isc_entropy_t *entropy, + unsigned int limit, isc_hash_t **hctxp) +{ + isc_result_t result; + isc_hash_t *hctx; + size_t vlen; + hash_random_t *rv; + hash_accum_t overflow_limit; + + REQUIRE(mctx != NULL); + REQUIRE(hctxp != NULL && *hctxp == NULL); + + /* + * Overflow check. Since our implementation only does a modulo + * operation at the last stage of hash calculation, the accumulator + * must not overflow. + */ + overflow_limit = + 1 << (((sizeof(hash_accum_t) - sizeof(hash_random_t))) * 8); + if (overflow_limit < (limit + 1) * 0xff) + return (ISC_R_RANGE); + + hctx = isc_mem_get(mctx, sizeof(isc_hash_t)); + if (hctx == NULL) + return (ISC_R_NOMEMORY); + + vlen = sizeof(hash_random_t) * (limit + 1); + rv = isc_mem_get(mctx, vlen); + if (rv == NULL) { + result = ISC_R_NOMEMORY; + goto errout; + } + + /* + * We need a lock. + */ + result = isc_mutex_init(&hctx->lock); + if (result != ISC_R_SUCCESS) + goto errout; + + /* + * From here down, no failures will/can occur. + */ + hctx->magic = HASH_MAGIC; + hctx->mctx = NULL; + isc_mem_attach(mctx, &hctx->mctx); + hctx->initialized = ISC_FALSE; + result = isc_refcount_init(&hctx->refcnt, 1); + if (result != ISC_R_SUCCESS) + goto cleanup_lock; + hctx->entropy = NULL; + hctx->limit = limit; + hctx->vectorlen = vlen; + hctx->rndvector = rv; + +#ifdef BIND9 + if (entropy != NULL) + isc_entropy_attach(entropy, &hctx->entropy); +#else + UNUSED(entropy); +#endif + + *hctxp = hctx; + return (ISC_R_SUCCESS); + + cleanup_lock: + DESTROYLOCK(&hctx->lock); + errout: + isc_mem_put(mctx, hctx, sizeof(isc_hash_t)); + if (rv != NULL) + isc_mem_put(mctx, rv, vlen); + + return (result); +} + +static void +initialize_lock(void) { + RUNTIME_CHECK(isc_mutex_init(&createlock) == ISC_R_SUCCESS); +} + +isc_result_t +isc_hash_create(isc_mem_t *mctx, isc_entropy_t *entropy, size_t limit) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(mctx != NULL); + INSIST(hash == NULL); + + RUNTIME_CHECK(isc_once_do(&once, initialize_lock) == ISC_R_SUCCESS); + + LOCK(&createlock); + + if (hash == NULL) + result = isc_hash_ctxcreate(mctx, entropy, limit, &hash); + + UNLOCK(&createlock); + + return (result); +} + +void +isc_hash_ctxinit(isc_hash_t *hctx) { + LOCK(&hctx->lock); + + if (hctx->initialized == ISC_TRUE) + goto out; + + if (hctx->entropy) { +#ifdef BIND9 + isc_result_t result; + + result = isc_entropy_getdata(hctx->entropy, + hctx->rndvector, hctx->vectorlen, + NULL, 0); + INSIST(result == ISC_R_SUCCESS); +#else + INSIST(0); +#endif + } else { + isc_uint32_t pr; + unsigned int i, copylen; + unsigned char *p; + + p = (unsigned char *)hctx->rndvector; + for (i = 0; i < hctx->vectorlen; i += copylen, p += copylen) { + isc_random_get(&pr); + if (i + sizeof(pr) <= hctx->vectorlen) + copylen = sizeof(pr); + else + copylen = hctx->vectorlen - i; + + memcpy(p, &pr, copylen); + } + INSIST(p == (unsigned char *)hctx->rndvector + + hctx->vectorlen); + } + + hctx->initialized = ISC_TRUE; + + out: + UNLOCK(&hctx->lock); +} + +void +isc_hash_init() { + INSIST(hash != NULL && VALID_HASH(hash)); + + isc_hash_ctxinit(hash); +} + +void +isc_hash_ctxattach(isc_hash_t *hctx, isc_hash_t **hctxp) { + REQUIRE(VALID_HASH(hctx)); + REQUIRE(hctxp != NULL && *hctxp == NULL); + + isc_refcount_increment(&hctx->refcnt, NULL); + *hctxp = hctx; +} + +static void +destroy(isc_hash_t **hctxp) { + isc_hash_t *hctx; + isc_mem_t *mctx; + unsigned char canary0[4], canary1[4]; + + REQUIRE(hctxp != NULL && *hctxp != NULL); + hctx = *hctxp; + *hctxp = NULL; + + LOCK(&hctx->lock); + + isc_refcount_destroy(&hctx->refcnt); + + mctx = hctx->mctx; +#ifdef BIND9 + if (hctx->entropy != NULL) + isc_entropy_detach(&hctx->entropy); +#endif + if (hctx->rndvector != NULL) + isc_mem_put(mctx, hctx->rndvector, hctx->vectorlen); + + UNLOCK(&hctx->lock); + + DESTROYLOCK(&hctx->lock); + + memcpy(canary0, hctx + 1, sizeof(canary0)); + memset(hctx, 0, sizeof(isc_hash_t)); + memcpy(canary1, hctx + 1, sizeof(canary1)); + INSIST(memcmp(canary0, canary1, sizeof(canary0)) == 0); + isc_mem_put(mctx, hctx, sizeof(isc_hash_t)); + isc_mem_detach(&mctx); +} + +void +isc_hash_ctxdetach(isc_hash_t **hctxp) { + isc_hash_t *hctx; + unsigned int refs; + + REQUIRE(hctxp != NULL && VALID_HASH(*hctxp)); + hctx = *hctxp; + + isc_refcount_decrement(&hctx->refcnt, &refs); + if (refs == 0) + destroy(&hctx); + + *hctxp = NULL; +} + +void +isc_hash_destroy() { + unsigned int refs; + + INSIST(hash != NULL && VALID_HASH(hash)); + + isc_refcount_decrement(&hash->refcnt, &refs); + INSIST(refs == 0); + + destroy(&hash); +} + +static inline unsigned int +hash_calc(isc_hash_t *hctx, const unsigned char *key, unsigned int keylen, + isc_boolean_t case_sensitive) +{ + hash_accum_t partial_sum = 0; + hash_random_t *p = hctx->rndvector; + unsigned int i = 0; + + /* Make it sure that the hash context is initialized. */ + if (hctx->initialized == ISC_FALSE) + isc_hash_ctxinit(hctx); + + if (case_sensitive) { + for (i = 0; i < keylen; i++) + partial_sum += key[i] * (hash_accum_t)p[i]; + } else { + for (i = 0; i < keylen; i++) + partial_sum += maptolower[key[i]] * (hash_accum_t)p[i]; + } + + partial_sum += p[i]; + + return ((unsigned int)(partial_sum % PRIME32)); +} + +unsigned int +isc_hash_ctxcalc(isc_hash_t *hctx, const unsigned char *key, + unsigned int keylen, isc_boolean_t case_sensitive) +{ + REQUIRE(hctx != NULL && VALID_HASH(hctx)); + REQUIRE(keylen <= hctx->limit); + + return (hash_calc(hctx, key, keylen, case_sensitive)); +} + +unsigned int +isc_hash_calc(const unsigned char *key, unsigned int keylen, + isc_boolean_t case_sensitive) +{ + INSIST(hash != NULL && VALID_HASH(hash)); + REQUIRE(keylen <= hash->limit); + + return (hash_calc(hash, key, keylen, case_sensitive)); +} diff --git a/contrib/ntp/lib/isc/heap.c b/contrib/ntp/lib/isc/heap.c new file mode 100644 index 000000000..ebadd2fd8 --- /dev/null +++ b/contrib/ntp/lib/isc/heap.c @@ -0,0 +1,265 @@ +/* + * Copyright (C) 2004-2007, 2010-2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file + * Heap implementation of priority queues adapted from the following: + * + * \li "Introduction to Algorithms," Cormen, Leiserson, and Rivest, + * MIT Press / McGraw Hill, 1990, ISBN 0-262-03141-8, chapter 7. + * + * \li "Algorithms," Second Edition, Sedgewick, Addison-Wesley, 1988, + * ISBN 0-201-06673-4, chapter 11. + */ + +#include + +#include +#include +#include +#include /* Required for memcpy. */ +#include + +/*@{*/ +/*% + * Note: to make heap_parent and heap_left easy to compute, the first + * element of the heap array is not used; i.e. heap subscripts are 1-based, + * not 0-based. The parent is index/2, and the left-child is index*2. + * The right child is index*2+1. + */ +#define heap_parent(i) ((i) >> 1) +#define heap_left(i) ((i) << 1) +/*@}*/ + +#define SIZE_INCREMENT 1024 + +#define HEAP_MAGIC ISC_MAGIC('H', 'E', 'A', 'P') +#define VALID_HEAP(h) ISC_MAGIC_VALID(h, HEAP_MAGIC) + +/*% + * When the heap is in a consistent state, the following invariant + * holds true: for every element i > 1, heap_parent(i) has a priority + * higher than or equal to that of i. + */ +#define HEAPCONDITION(i) ((i) == 1 || \ + ! heap->compare(heap->array[(i)], \ + heap->array[heap_parent(i)])) + +/*% ISC heap structure. */ +struct isc_heap { + unsigned int magic; + isc_mem_t * mctx; + unsigned int size; + unsigned int size_increment; + unsigned int last; + void **array; + isc_heapcompare_t compare; + isc_heapindex_t index; +}; + +isc_result_t +isc_heap_create(isc_mem_t *mctx, isc_heapcompare_t compare, + isc_heapindex_t index, unsigned int size_increment, + isc_heap_t **heapp) +{ + isc_heap_t *heap; + + REQUIRE(heapp != NULL && *heapp == NULL); + REQUIRE(compare != NULL); + + heap = isc_mem_get(mctx, sizeof(*heap)); + if (heap == NULL) + return (ISC_R_NOMEMORY); + heap->magic = HEAP_MAGIC; + heap->size = 0; + heap->mctx = NULL; + isc_mem_attach(mctx, &heap->mctx); + if (size_increment == 0) + heap->size_increment = SIZE_INCREMENT; + else + heap->size_increment = size_increment; + heap->last = 0; + heap->array = NULL; + heap->compare = compare; + heap->index = index; + + *heapp = heap; + + return (ISC_R_SUCCESS); +} + +void +isc_heap_destroy(isc_heap_t **heapp) { + isc_heap_t *heap; + + REQUIRE(heapp != NULL); + heap = *heapp; + REQUIRE(VALID_HEAP(heap)); + + if (heap->array != NULL) + isc_mem_put(heap->mctx, heap->array, + heap->size * sizeof(void *)); + heap->magic = 0; + isc_mem_putanddetach(&heap->mctx, heap, sizeof(*heap)); + + *heapp = NULL; +} + +static isc_boolean_t +resize(isc_heap_t *heap) { + void **new_array; + size_t new_size; + + REQUIRE(VALID_HEAP(heap)); + + new_size = heap->size + heap->size_increment; + new_array = isc_mem_get(heap->mctx, new_size * sizeof(void *)); + if (new_array == NULL) + return (ISC_FALSE); + if (heap->array != NULL) { + memcpy(new_array, heap->array, heap->size * sizeof(void *)); + isc_mem_put(heap->mctx, heap->array, + heap->size * sizeof(void *)); + } + heap->size = new_size; + heap->array = new_array; + + return (ISC_TRUE); +} + +static void +float_up(isc_heap_t *heap, unsigned int i, void *elt) { + unsigned int p; + + for (p = heap_parent(i) ; + i > 1 && heap->compare(elt, heap->array[p]) ; + i = p, p = heap_parent(i)) { + heap->array[i] = heap->array[p]; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + } + heap->array[i] = elt; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + + INSIST(HEAPCONDITION(i)); +} + +static void +sink_down(isc_heap_t *heap, unsigned int i, void *elt) { + unsigned int j, size, half_size; + size = heap->last; + half_size = size / 2; + while (i <= half_size) { + /* Find the smallest of the (at most) two children. */ + j = heap_left(i); + if (j < size && heap->compare(heap->array[j+1], + heap->array[j])) + j++; + if (heap->compare(elt, heap->array[j])) + break; + heap->array[i] = heap->array[j]; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + i = j; + } + heap->array[i] = elt; + if (heap->index != NULL) + (heap->index)(heap->array[i], i); + + INSIST(HEAPCONDITION(i)); +} + +isc_result_t +isc_heap_insert(isc_heap_t *heap, void *elt) { + unsigned int new_last; + + REQUIRE(VALID_HEAP(heap)); + + new_last = heap->last + 1; + RUNTIME_CHECK(new_last > 0); /* overflow check */ + if (new_last >= heap->size && !resize(heap)) + return (ISC_R_NOMEMORY); + heap->last = new_last; + + float_up(heap, new_last, elt); + + return (ISC_R_SUCCESS); +} + +void +isc_heap_delete(isc_heap_t *heap, unsigned int index) { + void *elt; + isc_boolean_t less; + + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1 && index <= heap->last); + + if (index == heap->last) { + heap->array[heap->last] = NULL; + heap->last--; + } else { + elt = heap->array[heap->last]; + heap->array[heap->last] = NULL; + heap->last--; + + less = heap->compare(elt, heap->array[index]); + heap->array[index] = elt; + if (less) + float_up(heap, index, heap->array[index]); + else + sink_down(heap, index, heap->array[index]); + } +} + +void +isc_heap_increased(isc_heap_t *heap, unsigned int index) { + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1 && index <= heap->last); + + float_up(heap, index, heap->array[index]); +} + +void +isc_heap_decreased(isc_heap_t *heap, unsigned int index) { + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1 && index <= heap->last); + + sink_down(heap, index, heap->array[index]); +} + +void * +isc_heap_element(isc_heap_t *heap, unsigned int index) { + REQUIRE(VALID_HEAP(heap)); + REQUIRE(index >= 1); + + if (index <= heap->last) + return (heap->array[index]); + return (NULL); +} + +void +isc_heap_foreach(isc_heap_t *heap, isc_heapaction_t action, void *uap) { + unsigned int i; + + REQUIRE(VALID_HEAP(heap)); + REQUIRE(action != NULL); + + for (i = 1 ; i <= heap->last ; i++) + (action)(heap->array[i], uap); +} diff --git a/contrib/ntp/lib/isc/hex.c b/contrib/ntp/lib/isc/hex.c new file mode 100644 index 000000000..3fa0e699f --- /dev/null +++ b/contrib/ntp/lib/isc/hex.c @@ -0,0 +1,201 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hex.c,v 1.20 2008/09/25 04:02:39 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +#define RETERR(x) do { \ + isc_result_t _r = (x); \ + if (_r != ISC_R_SUCCESS) \ + return (_r); \ + } while (0) + + +/* + * BEW: These static functions are copied from lib/dns/rdata.c. + */ +static isc_result_t +str_totext(const char *source, isc_buffer_t *target); + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length); + +static const char hex[] = "0123456789ABCDEF"; + +isc_result_t +isc_hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target) +{ + char buf[3]; + unsigned int loops = 0; + + if (wordlength < 2) + wordlength = 2; + + memset(buf, 0, sizeof(buf)); + while (source->length > 0) { + buf[0] = hex[(source->base[0] >> 4) & 0xf]; + buf[1] = hex[(source->base[0]) & 0xf]; + RETERR(str_totext(buf, target)); + isc_region_consume(source, 1); + + loops++; + if (source->length != 0 && + (int)((loops + 1) * 2) >= wordlength) + { + loops = 0; + RETERR(str_totext(wordbreak, target)); + } + } + return (ISC_R_SUCCESS); +} + +/*% + * State of a hex decoding process in progress. + */ +typedef struct { + int length; /*%< Desired length of binary data or -1 */ + isc_buffer_t *target; /*%< Buffer for resulting binary data */ + int digits; /*%< Number of buffered hex digits */ + int val[2]; +} hex_decode_ctx_t; + +static inline void +hex_decode_init(hex_decode_ctx_t *ctx, int length, isc_buffer_t *target) +{ + ctx->digits = 0; + ctx->length = length; + ctx->target = target; +} + +static inline isc_result_t +hex_decode_char(hex_decode_ctx_t *ctx, int c) { + char *s; + + if ((s = strchr(hex, toupper(c))) == NULL) + return (ISC_R_BADHEX); + ctx->val[ctx->digits++] = s - hex; + if (ctx->digits == 2) { + unsigned char num; + + num = (ctx->val[0] << 4) + (ctx->val[1]); + RETERR(mem_tobuffer(ctx->target, &num, 1)); + if (ctx->length >= 0) { + if (ctx->length == 0) + return (ISC_R_BADHEX); + else + ctx->length -= 1; + } + ctx->digits = 0; + } + return (ISC_R_SUCCESS); +} + +static inline isc_result_t +hex_decode_finish(hex_decode_ctx_t *ctx) { + if (ctx->length > 0) + return (ISC_R_UNEXPECTEDEND); + if (ctx->digits != 0) + return (ISC_R_BADHEX); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length) { + hex_decode_ctx_t ctx; + isc_textregion_t *tr; + isc_token_t token; + isc_boolean_t eol; + + hex_decode_init(&ctx, length, target); + + while (ctx.length != 0) { + unsigned int i; + + if (length > 0) + eol = ISC_FALSE; + else + eol = ISC_TRUE; + RETERR(isc_lex_getmastertoken(lexer, &token, + isc_tokentype_string, eol)); + if (token.type != isc_tokentype_string) + break; + tr = &token.value.as_textregion; + for (i = 0; i < tr->length; i++) + RETERR(hex_decode_char(&ctx, tr->base[i])); + } + if (ctx.length < 0) + isc_lex_ungettoken(lexer, &token); + RETERR(hex_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_hex_decodestring(const char *cstr, isc_buffer_t *target) { + hex_decode_ctx_t ctx; + + hex_decode_init(&ctx, -1, target); + for (;;) { + int c = *cstr++; + if (c == '\0') + break; + if (c == ' ' || c == '\t' || c == '\n' || c== '\r') + continue; + RETERR(hex_decode_char(&ctx, c)); + } + RETERR(hex_decode_finish(&ctx)); + return (ISC_R_SUCCESS); +} + +static isc_result_t +str_totext(const char *source, isc_buffer_t *target) { + unsigned int l; + isc_region_t region; + + isc_buffer_availableregion(target, ®ion); + l = strlen(source); + + if (l > region.length) + return (ISC_R_NOSPACE); + + memcpy(region.base, source, l); + isc_buffer_add(target, l); + return (ISC_R_SUCCESS); +} + +static isc_result_t +mem_tobuffer(isc_buffer_t *target, void *base, unsigned int length) { + isc_region_t tr; + + isc_buffer_availableregion(target, &tr); + if (length > tr.length) + return (ISC_R_NOSPACE); + memcpy(tr.base, base, length); + isc_buffer_add(target, length); + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/hmacmd5.c b/contrib/ntp/lib/isc/hmacmd5.c new file mode 100644 index 000000000..6abe6e27d --- /dev/null +++ b/contrib/ntp/lib/isc/hmacmd5.c @@ -0,0 +1,149 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hmacmd5.c,v 1.16 2009/02/06 23:47:42 tbox Exp $ */ + +/*! \file + * This code implements the HMAC-MD5 keyed hash algorithm + * described in RFC2104. + */ + +#include "config.h" + +#include +#include +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_OPENSSLHASH + +void +isc_hmacmd5_init(isc_hmacmd5_t *ctx, const unsigned char *key, + unsigned int len) +{ + HMAC_Init(ctx, (const void *) key, (int) len, EVP_md5()); +} + +void +isc_hmacmd5_invalidate(isc_hmacmd5_t *ctx) { + HMAC_CTX_cleanup(ctx); +} + +void +isc_hmacmd5_update(isc_hmacmd5_t *ctx, const unsigned char *buf, + unsigned int len) +{ + HMAC_Update(ctx, buf, (int) len); +} + +void +isc_hmacmd5_sign(isc_hmacmd5_t *ctx, unsigned char *digest) { + HMAC_Final(ctx, digest, NULL); + HMAC_CTX_cleanup(ctx); +} + +#else + +#define PADLEN 64 +#define IPAD 0x36 +#define OPAD 0x5C + +/*! + * Start HMAC-MD5 process. Initialize an md5 context and digest the key. + */ +void +isc_hmacmd5_init(isc_hmacmd5_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[PADLEN]; + int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_md5_t md5ctx; + isc_md5_init(&md5ctx); + isc_md5_update(&md5ctx, key, len); + isc_md5_final(&md5ctx, ctx->key); + } else + memcpy(ctx->key, key, len); + + isc_md5_init(&ctx->md5ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < PADLEN; i++) + ipad[i] ^= ctx->key[i]; + isc_md5_update(&ctx->md5ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacmd5_invalidate(isc_hmacmd5_t *ctx) { + isc_md5_invalidate(&ctx->md5ctx); + memset(ctx->key, 0, sizeof(ctx->key)); +} + +/*! + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacmd5_update(isc_hmacmd5_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_md5_update(&ctx->md5ctx, buf, len); +} + +/*! + * Compute signature - finalize MD5 operation and reapply MD5. + */ +void +isc_hmacmd5_sign(isc_hmacmd5_t *ctx, unsigned char *digest) { + unsigned char opad[PADLEN]; + int i; + + isc_md5_final(&ctx->md5ctx, digest); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < PADLEN; i++) + opad[i] ^= ctx->key[i]; + + isc_md5_init(&ctx->md5ctx); + isc_md5_update(&ctx->md5ctx, opad, sizeof(opad)); + isc_md5_update(&ctx->md5ctx, digest, ISC_MD5_DIGESTLENGTH); + isc_md5_final(&ctx->md5ctx, digest); + isc_hmacmd5_invalidate(ctx); +} +#endif /* !ISC_PLATFORM_OPENSSLHASH */ + +/*! + * Verify signature - finalize MD5 operation and reapply MD5, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacmd5_verify(isc_hmacmd5_t *ctx, unsigned char *digest) { + return (isc_hmacmd5_verify2(ctx, digest, ISC_MD5_DIGESTLENGTH)); +} + +isc_boolean_t +isc_hmacmd5_verify2(isc_hmacmd5_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_MD5_DIGESTLENGTH]; + + REQUIRE(len <= ISC_MD5_DIGESTLENGTH); + isc_hmacmd5_sign(ctx, newdigest); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} diff --git a/contrib/ntp/lib/isc/hmacsha.c b/contrib/ntp/lib/isc/hmacsha.c new file mode 100644 index 000000000..d7b9f1897 --- /dev/null +++ b/contrib/ntp/lib/isc/hmacsha.c @@ -0,0 +1,594 @@ +/* + * Copyright (C) 2005-2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* + * This code implements the HMAC-SHA1, HMAC-SHA224, HMAC-SHA256, HMAC-SHA384 + * and HMAC-SHA512 keyed hash algorithm described in RFC 2104 and + * draft-ietf-dnsext-tsig-sha-01.txt. + */ + +#include "config.h" + +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_OPENSSLHASH + +void +isc_hmacsha1_init(isc_hmacsha1_t *ctx, const unsigned char *key, + unsigned int len) +{ + HMAC_Init(ctx, (const void *) key, (int) len, EVP_sha1()); +} + +void +isc_hmacsha1_invalidate(isc_hmacsha1_t *ctx) { + HMAC_CTX_cleanup(ctx); +} + +void +isc_hmacsha1_update(isc_hmacsha1_t *ctx, const unsigned char *buf, + unsigned int len) +{ + HMAC_Update(ctx, buf, (int) len); +} + +void +isc_hmacsha1_sign(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA1_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA1_DIGESTLENGTH); + + HMAC_Final(ctx, newdigest, NULL); + HMAC_CTX_cleanup(ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +void +isc_hmacsha224_init(isc_hmacsha224_t *ctx, const unsigned char *key, + unsigned int len) +{ + HMAC_Init(ctx, (const void *) key, (int) len, EVP_sha224()); +} + +void +isc_hmacsha224_invalidate(isc_hmacsha224_t *ctx) { + HMAC_CTX_cleanup(ctx); +} + +void +isc_hmacsha224_update(isc_hmacsha224_t *ctx, const unsigned char *buf, + unsigned int len) +{ + HMAC_Update(ctx, buf, (int) len); +} + +void +isc_hmacsha224_sign(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA224_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA224_DIGESTLENGTH); + + HMAC_Final(ctx, newdigest, NULL); + HMAC_CTX_cleanup(ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +void +isc_hmacsha256_init(isc_hmacsha256_t *ctx, const unsigned char *key, + unsigned int len) +{ + HMAC_Init(ctx, (const void *) key, (int) len, EVP_sha256()); +} + +void +isc_hmacsha256_invalidate(isc_hmacsha256_t *ctx) { + HMAC_CTX_cleanup(ctx); +} + +void +isc_hmacsha256_update(isc_hmacsha256_t *ctx, const unsigned char *buf, + unsigned int len) +{ + HMAC_Update(ctx, buf, (int) len); +} + +void +isc_hmacsha256_sign(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA256_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA256_DIGESTLENGTH); + + HMAC_Final(ctx, newdigest, NULL); + HMAC_CTX_cleanup(ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +void +isc_hmacsha384_init(isc_hmacsha384_t *ctx, const unsigned char *key, + unsigned int len) +{ + HMAC_Init(ctx, (const void *) key, (int) len, EVP_sha384()); +} + +void +isc_hmacsha384_invalidate(isc_hmacsha384_t *ctx) { + HMAC_CTX_cleanup(ctx); +} + +void +isc_hmacsha384_update(isc_hmacsha384_t *ctx, const unsigned char *buf, + unsigned int len) +{ + HMAC_Update(ctx, buf, (int) len); +} + +void +isc_hmacsha384_sign(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA384_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA384_DIGESTLENGTH); + + HMAC_Final(ctx, newdigest, NULL); + HMAC_CTX_cleanup(ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +void +isc_hmacsha512_init(isc_hmacsha512_t *ctx, const unsigned char *key, + unsigned int len) +{ + HMAC_Init(ctx, (const void *) key, (int) len, EVP_sha512()); +} + +void +isc_hmacsha512_invalidate(isc_hmacsha512_t *ctx) { + HMAC_CTX_cleanup(ctx); +} + +void +isc_hmacsha512_update(isc_hmacsha512_t *ctx, const unsigned char *buf, + unsigned int len) +{ + HMAC_Update(ctx, buf, (int) len); +} + +void +isc_hmacsha512_sign(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA512_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA512_DIGESTLENGTH); + + HMAC_Final(ctx, newdigest, NULL); + HMAC_CTX_cleanup(ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +#else + +#define IPAD 0x36 +#define OPAD 0x5C + +/* + * Start HMAC-SHA1 process. Initialize an sha1 context and digest the key. + */ +void +isc_hmacsha1_init(isc_hmacsha1_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA1_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha1_t sha1ctx; + isc_sha1_init(&sha1ctx); + isc_sha1_update(&sha1ctx, key, len); + isc_sha1_final(&sha1ctx, ctx->key); + } else + memcpy(ctx->key, key, len); + + isc_sha1_init(&ctx->sha1ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA1_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha1_update(&ctx->sha1ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha1_invalidate(isc_hmacsha1_t *ctx) { + isc_sha1_invalidate(&ctx->sha1ctx); + memset(ctx, 0, sizeof(*ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha1_update(isc_hmacsha1_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha1_update(&ctx->sha1ctx, buf, len); +} + +/* + * Compute signature - finalize SHA1 operation and reapply SHA1. + */ +void +isc_hmacsha1_sign(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA1_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA1_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA1_DIGESTLENGTH); + isc_sha1_final(&ctx->sha1ctx, newdigest); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA1_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha1_init(&ctx->sha1ctx); + isc_sha1_update(&ctx->sha1ctx, opad, sizeof(opad)); + isc_sha1_update(&ctx->sha1ctx, newdigest, ISC_SHA1_DIGESTLENGTH); + isc_sha1_final(&ctx->sha1ctx, newdigest); + isc_hmacsha1_invalidate(ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Start HMAC-SHA224 process. Initialize an sha224 context and digest the key. + */ +void +isc_hmacsha224_init(isc_hmacsha224_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA224_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha224_t sha224ctx; + isc_sha224_init(&sha224ctx); + isc_sha224_update(&sha224ctx, key, len); + isc_sha224_final(ctx->key, &sha224ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha224_init(&ctx->sha224ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA224_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha224_update(&ctx->sha224ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha224_invalidate(isc_hmacsha224_t *ctx) { + memset(ctx, 0, sizeof(*ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha224_update(isc_hmacsha224_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha224_update(&ctx->sha224ctx, buf, len); +} + +/* + * Compute signature - finalize SHA224 operation and reapply SHA224. + */ +void +isc_hmacsha224_sign(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA224_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA224_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA224_DIGESTLENGTH); + isc_sha224_final(newdigest, &ctx->sha224ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA224_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha224_init(&ctx->sha224ctx); + isc_sha224_update(&ctx->sha224ctx, opad, sizeof(opad)); + isc_sha224_update(&ctx->sha224ctx, newdigest, ISC_SHA224_DIGESTLENGTH); + isc_sha224_final(newdigest, &ctx->sha224ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Start HMAC-SHA256 process. Initialize an sha256 context and digest the key. + */ +void +isc_hmacsha256_init(isc_hmacsha256_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA256_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha256_t sha256ctx; + isc_sha256_init(&sha256ctx); + isc_sha256_update(&sha256ctx, key, len); + isc_sha256_final(ctx->key, &sha256ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha256_init(&ctx->sha256ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA256_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha256_update(&ctx->sha256ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha256_invalidate(isc_hmacsha256_t *ctx) { + memset(ctx, 0, sizeof(*ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha256_update(isc_hmacsha256_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha256_update(&ctx->sha256ctx, buf, len); +} + +/* + * Compute signature - finalize SHA256 operation and reapply SHA256. + */ +void +isc_hmacsha256_sign(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA256_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA256_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA256_DIGESTLENGTH); + isc_sha256_final(newdigest, &ctx->sha256ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA256_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha256_init(&ctx->sha256ctx); + isc_sha256_update(&ctx->sha256ctx, opad, sizeof(opad)); + isc_sha256_update(&ctx->sha256ctx, newdigest, ISC_SHA256_DIGESTLENGTH); + isc_sha256_final(newdigest, &ctx->sha256ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Start HMAC-SHA384 process. Initialize an sha384 context and digest the key. + */ +void +isc_hmacsha384_init(isc_hmacsha384_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA384_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha384_t sha384ctx; + isc_sha384_init(&sha384ctx); + isc_sha384_update(&sha384ctx, key, len); + isc_sha384_final(ctx->key, &sha384ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha384_init(&ctx->sha384ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA384_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha384_update(&ctx->sha384ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha384_invalidate(isc_hmacsha384_t *ctx) { + memset(ctx, 0, sizeof(*ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha384_update(isc_hmacsha384_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha384_update(&ctx->sha384ctx, buf, len); +} + +/* + * Compute signature - finalize SHA384 operation and reapply SHA384. + */ +void +isc_hmacsha384_sign(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA384_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA384_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA384_DIGESTLENGTH); + isc_sha384_final(newdigest, &ctx->sha384ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA384_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha384_init(&ctx->sha384ctx); + isc_sha384_update(&ctx->sha384ctx, opad, sizeof(opad)); + isc_sha384_update(&ctx->sha384ctx, newdigest, ISC_SHA384_DIGESTLENGTH); + isc_sha384_final(newdigest, &ctx->sha384ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} + +/* + * Start HMAC-SHA512 process. Initialize an sha512 context and digest the key. + */ +void +isc_hmacsha512_init(isc_hmacsha512_t *ctx, const unsigned char *key, + unsigned int len) +{ + unsigned char ipad[ISC_SHA512_BLOCK_LENGTH]; + unsigned int i; + + memset(ctx->key, 0, sizeof(ctx->key)); + if (len > sizeof(ctx->key)) { + isc_sha512_t sha512ctx; + isc_sha512_init(&sha512ctx); + isc_sha512_update(&sha512ctx, key, len); + isc_sha512_final(ctx->key, &sha512ctx); + } else + memcpy(ctx->key, key, len); + + isc_sha512_init(&ctx->sha512ctx); + memset(ipad, IPAD, sizeof(ipad)); + for (i = 0; i < ISC_SHA512_BLOCK_LENGTH; i++) + ipad[i] ^= ctx->key[i]; + isc_sha512_update(&ctx->sha512ctx, ipad, sizeof(ipad)); +} + +void +isc_hmacsha512_invalidate(isc_hmacsha512_t *ctx) { + memset(ctx, 0, sizeof(*ctx)); +} + +/* + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_hmacsha512_update(isc_hmacsha512_t *ctx, const unsigned char *buf, + unsigned int len) +{ + isc_sha512_update(&ctx->sha512ctx, buf, len); +} + +/* + * Compute signature - finalize SHA512 operation and reapply SHA512. + */ +void +isc_hmacsha512_sign(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len) { + unsigned char opad[ISC_SHA512_BLOCK_LENGTH]; + unsigned char newdigest[ISC_SHA512_DIGESTLENGTH]; + unsigned int i; + + REQUIRE(len <= ISC_SHA512_DIGESTLENGTH); + isc_sha512_final(newdigest, &ctx->sha512ctx); + + memset(opad, OPAD, sizeof(opad)); + for (i = 0; i < ISC_SHA512_BLOCK_LENGTH; i++) + opad[i] ^= ctx->key[i]; + + isc_sha512_init(&ctx->sha512ctx); + isc_sha512_update(&ctx->sha512ctx, opad, sizeof(opad)); + isc_sha512_update(&ctx->sha512ctx, newdigest, ISC_SHA512_DIGESTLENGTH); + isc_sha512_final(newdigest, &ctx->sha512ctx); + memcpy(digest, newdigest, len); + memset(newdigest, 0, sizeof(newdigest)); +} +#endif /* !ISC_PLATFORM_OPENSSLHASH */ + +/* + * Verify signature - finalize SHA1 operation and reapply SHA1, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha1_verify(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA1_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA1_DIGESTLENGTH); + isc_hmacsha1_sign(ctx, newdigest, ISC_SHA1_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Verify signature - finalize SHA224 operation and reapply SHA224, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha224_verify(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA224_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA224_DIGESTLENGTH); + isc_hmacsha224_sign(ctx, newdigest, ISC_SHA224_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Verify signature - finalize SHA256 operation and reapply SHA256, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha256_verify(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA256_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA256_DIGESTLENGTH); + isc_hmacsha256_sign(ctx, newdigest, ISC_SHA256_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Verify signature - finalize SHA384 operation and reapply SHA384, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha384_verify(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA384_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA384_DIGESTLENGTH); + isc_hmacsha384_sign(ctx, newdigest, ISC_SHA384_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} + +/* + * Verify signature - finalize SHA512 operation and reapply SHA512, then + * compare to the supplied digest. + */ +isc_boolean_t +isc_hmacsha512_verify(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len) { + unsigned char newdigest[ISC_SHA512_DIGESTLENGTH]; + + REQUIRE(len <= ISC_SHA512_DIGESTLENGTH); + isc_hmacsha512_sign(ctx, newdigest, ISC_SHA512_DIGESTLENGTH); + return (ISC_TF(memcmp(digest, newdigest, len) == 0)); +} diff --git a/contrib/ntp/lib/isc/httpd.c b/contrib/ntp/lib/isc/httpd.c new file mode 100644 index 000000000..16a8c9fe1 --- /dev/null +++ b/contrib/ntp/lib/isc/httpd.c @@ -0,0 +1,1028 @@ +/* + * Copyright (C) 2006-2008, 2010-2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include +#include + +#include + +/*% + * TODO: + * + * o Put in better checks to make certain things are passed in correctly. + * This includes a magic number for externally-visible structures, + * checking for NULL-ness before dereferencing, etc. + * o Make the URL processing external functions which will fill-in a buffer + * structure we provide, or return an error and we will render a generic + * page and close the client. + */ + +#define MSHUTTINGDOWN(cm) ((cm->flags & ISC_HTTPDMGR_FLAGSHUTTINGDOWN) != 0) +#define MSETSHUTTINGDOWN(cm) (cm->flags |= ISC_HTTPDMGR_FLAGSHUTTINGDOWN) + +#ifdef DEBUG_HTTPD +#define ENTER(x) do { fprintf(stderr, "ENTER %s\n", (x)); } while (0) +#define EXIT(x) do { fprintf(stderr, "EXIT %s\n", (x)); } while (0) +#define NOTICE(x) do { fprintf(stderr, "NOTICE %s\n", (x)); } while (0) +#else +#define ENTER(x) do { } while(0) +#define EXIT(x) do { } while(0) +#define NOTICE(x) do { } while(0) +#endif + +#define HTTP_RECVLEN 1024 +#define HTTP_SENDGROW 1024 +#define HTTP_SEND_MAXLEN 10240 + +/*% + * HTTP urls. These are the URLs we manage, and the function to call to + * provide the data for it. We pass in the base url (so the same function + * can handle multiple requests), and a structure to fill in to return a + * result to the client. We also pass in a pointer to be filled in for + * the data cleanup function. + */ +struct isc_httpdurl { + char *url; + isc_httpdaction_t *action; + void *action_arg; + ISC_LINK(isc_httpdurl_t) link; +}; + +#define HTTPD_CLOSE 0x0001 /* Got a Connection: close header */ +#define HTTPD_FOUNDHOST 0x0002 /* Got a Host: header */ + +/*% http client */ +struct isc_httpd { + isc_httpdmgr_t *mgr; /*%< our parent */ + ISC_LINK(isc_httpd_t) link; + unsigned int state; + isc_socket_t *sock; + + /*% + * Received data state. + */ + char recvbuf[HTTP_RECVLEN]; /*%< receive buffer */ + isc_uint32_t recvlen; /*%< length recv'd */ + unsigned int method; + char *url; + char *querystring; + char *protocol; + + /* + * Flags on the httpd client. + */ + int flags; + + /*% + * Transmit data state. + * + * This is the data buffer we will transmit. + * + * This free function pointer is filled in by the rendering function + * we call. The free function is called after the data is transmitted + * to the client. + * + * The bufflist is the list of buffers we are currently transmitting. + * The headerdata is where we render our headers to. If we run out of + * space when rendering a header, we will change the size of our + * buffer. We will not free it until we are finished, and will + * allocate an additional HTTP_SENDGROW bytes per header space grow. + * + * We currently use two buffers total, one for the headers (which + * we manage) and another for the client to fill in (which it manages, + * it provides the space for it, etc) -- we will pass that buffer + * structure back to the caller, who is responsible for managing the + * space it may have allocated as backing store for it. This second + * buffer is bodybuffer, and we only allocate the buffer itself, not + * the backing store. + */ + isc_bufferlist_t bufflist; + char *headerdata; /*%< send header buf */ + unsigned int headerlen; /*%< current header buffer size */ + isc_buffer_t headerbuffer; + + const char *mimetype; + unsigned int retcode; + const char *retmsg; + isc_buffer_t bodybuffer; + isc_httpdfree_t *freecb; + void *freecb_arg; +}; + +/*% lightweight socket manager for httpd output */ +struct isc_httpdmgr { + isc_mem_t *mctx; + isc_socket_t *sock; /*%< listening socket */ + isc_task_t *task; /*%< owning task */ + isc_timermgr_t *timermgr; + + isc_httpdclientok_t *client_ok; /*%< client validator */ + isc_httpdondestroy_t *ondestroy; /*%< cleanup callback */ + void *cb_arg; /*%< argument for the above */ + + unsigned int flags; + ISC_LIST(isc_httpd_t) running; /*%< running clients */ + + isc_mutex_t lock; + + ISC_LIST(isc_httpdurl_t) urls; /*%< urls we manage */ + isc_httpdaction_t *render_404; + isc_httpdaction_t *render_500; +}; + +/*% + * HTTP methods. + */ +#define ISC_HTTPD_METHODUNKNOWN 0 +#define ISC_HTTPD_METHODGET 1 +#define ISC_HTTPD_METHODPOST 2 + +/*% + * Client states. + * + * _IDLE The client is not doing anything at all. This state should + * only occur just after creation, and just before being + * destroyed. + * + * _RECV The client is waiting for data after issuing a socket recv(). + * + * _RECVDONE Data has been received, and is being processed. + * + * _SEND All data for a response has completed, and a reply was + * sent via a socket send() call. + * + * _SENDDONE Send is completed. + * + * Badly formatted state table: + * + * IDLE -> RECV when client has a recv() queued. + * + * RECV -> RECVDONE when recvdone event received. + * + * RECVDONE -> SEND if the data for a reply is at hand. + * + * SEND -> RECV when a senddone event was received. + * + * At any time -> RECV on error. If RECV fails, the client will + * self-destroy, closing the socket and freeing memory. + */ +#define ISC_HTTPD_STATEIDLE 0 +#define ISC_HTTPD_STATERECV 1 +#define ISC_HTTPD_STATERECVDONE 2 +#define ISC_HTTPD_STATESEND 3 +#define ISC_HTTPD_STATESENDDONE 4 + +#define ISC_HTTPD_ISRECV(c) ((c)->state == ISC_HTTPD_STATERECV) +#define ISC_HTTPD_ISRECVDONE(c) ((c)->state == ISC_HTTPD_STATERECVDONE) +#define ISC_HTTPD_ISSEND(c) ((c)->state == ISC_HTTPD_STATESEND) +#define ISC_HTTPD_ISSENDDONE(c) ((c)->state == ISC_HTTPD_STATESENDDONE) + +/*% + * Overall magic test that means we're not idle. + */ +#define ISC_HTTPD_SETRECV(c) ((c)->state = ISC_HTTPD_STATERECV) +#define ISC_HTTPD_SETRECVDONE(c) ((c)->state = ISC_HTTPD_STATERECVDONE) +#define ISC_HTTPD_SETSEND(c) ((c)->state = ISC_HTTPD_STATESEND) +#define ISC_HTTPD_SETSENDDONE(c) ((c)->state = ISC_HTTPD_STATESENDDONE) + +static void isc_httpd_accept(isc_task_t *, isc_event_t *); +static void isc_httpd_recvdone(isc_task_t *, isc_event_t *); +static void isc_httpd_senddone(isc_task_t *, isc_event_t *); +static void destroy_client(isc_httpd_t **); +static isc_result_t process_request(isc_httpd_t *, int); +static void httpdmgr_destroy(isc_httpdmgr_t *); +static isc_result_t grow_headerspace(isc_httpd_t *); +static void reset_client(isc_httpd_t *httpd); +static isc_result_t render_404(const char *, const char *, + void *, + unsigned int *, const char **, + const char **, isc_buffer_t *, + isc_httpdfree_t **, void **); +static isc_result_t render_500(const char *, const char *, + void *, + unsigned int *, const char **, + const char **, isc_buffer_t *, + isc_httpdfree_t **, void **); + +static void +destroy_client(isc_httpd_t **httpdp) +{ + isc_httpd_t *httpd = *httpdp; + isc_httpdmgr_t *httpdmgr = httpd->mgr; + + *httpdp = NULL; + + LOCK(&httpdmgr->lock); + + isc_socket_detach(&httpd->sock); + ISC_LIST_UNLINK(httpdmgr->running, httpd, link); + + if (httpd->headerlen > 0) + isc_mem_put(httpdmgr->mctx, httpd->headerdata, + httpd->headerlen); + + isc_mem_put(httpdmgr->mctx, httpd, sizeof(isc_httpd_t)); + + UNLOCK(&httpdmgr->lock); + + httpdmgr_destroy(httpdmgr); +} + +isc_result_t +isc_httpdmgr_create(isc_mem_t *mctx, isc_socket_t *sock, isc_task_t *task, + isc_httpdclientok_t *client_ok, + isc_httpdondestroy_t *ondestroy, void *cb_arg, + isc_timermgr_t *tmgr, isc_httpdmgr_t **httpdp) +{ + isc_result_t result; + isc_httpdmgr_t *httpd; + + REQUIRE(mctx != NULL); + REQUIRE(sock != NULL); + REQUIRE(task != NULL); + REQUIRE(tmgr != NULL); + REQUIRE(httpdp != NULL && *httpdp == NULL); + + httpd = isc_mem_get(mctx, sizeof(isc_httpdmgr_t)); + if (httpd == NULL) + return (ISC_R_NOMEMORY); + + result = isc_mutex_init(&httpd->lock); + if (result != ISC_R_SUCCESS) { + isc_mem_put(mctx, httpd, sizeof(isc_httpdmgr_t)); + return (result); + } + httpd->mctx = NULL; + isc_mem_attach(mctx, &httpd->mctx); + httpd->sock = NULL; + isc_socket_attach(sock, &httpd->sock); + httpd->task = NULL; + isc_task_attach(task, &httpd->task); + httpd->timermgr = tmgr; /* XXXMLG no attach function? */ + httpd->client_ok = client_ok; + httpd->ondestroy = ondestroy; + httpd->cb_arg = cb_arg; + + ISC_LIST_INIT(httpd->running); + ISC_LIST_INIT(httpd->urls); + + /* XXXMLG ignore errors on isc_socket_listen() */ + result = isc_socket_listen(sock, SOMAXCONN); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_socket_listen() failed: %s", + isc_result_totext(result)); + goto cleanup; + } + + (void)isc_socket_filter(sock, "httpready"); + + result = isc_socket_accept(sock, task, isc_httpd_accept, httpd); + if (result != ISC_R_SUCCESS) + goto cleanup; + + httpd->render_404 = render_404; + httpd->render_500 = render_500; + + *httpdp = httpd; + return (ISC_R_SUCCESS); + + cleanup: + isc_task_detach(&httpd->task); + isc_socket_detach(&httpd->sock); + isc_mem_detach(&httpd->mctx); + (void)isc_mutex_destroy(&httpd->lock); + isc_mem_put(mctx, httpd, sizeof(isc_httpdmgr_t)); + return (result); +} + +static void +httpdmgr_destroy(isc_httpdmgr_t *httpdmgr) +{ + isc_mem_t *mctx; + isc_httpdurl_t *url; + + ENTER("httpdmgr_destroy"); + + LOCK(&httpdmgr->lock); + + if (!MSHUTTINGDOWN(httpdmgr)) { + NOTICE("httpdmgr_destroy not shutting down yet"); + UNLOCK(&httpdmgr->lock); + return; + } + + /* + * If all clients are not shut down, don't do anything yet. + */ + if (!ISC_LIST_EMPTY(httpdmgr->running)) { + NOTICE("httpdmgr_destroy clients still active"); + UNLOCK(&httpdmgr->lock); + return; + } + + NOTICE("httpdmgr_destroy detaching socket, task, and timermgr"); + + isc_socket_detach(&httpdmgr->sock); + isc_task_detach(&httpdmgr->task); + httpdmgr->timermgr = NULL; + + /* + * Clear out the list of all actions we know about. Just free the + * memory. + */ + url = ISC_LIST_HEAD(httpdmgr->urls); + while (url != NULL) { + isc_mem_free(httpdmgr->mctx, url->url); + ISC_LIST_UNLINK(httpdmgr->urls, url, link); + isc_mem_put(httpdmgr->mctx, url, sizeof(isc_httpdurl_t)); + url = ISC_LIST_HEAD(httpdmgr->urls); + } + + UNLOCK(&httpdmgr->lock); + (void)isc_mutex_destroy(&httpdmgr->lock); + + if (httpdmgr->ondestroy != NULL) + (httpdmgr->ondestroy)(httpdmgr->cb_arg); + + mctx = httpdmgr->mctx; + isc_mem_putanddetach(&mctx, httpdmgr, sizeof(isc_httpdmgr_t)); + + EXIT("httpdmgr_destroy"); +} + +#define LENGTHOK(s) (httpd->recvbuf - (s) < (int)httpd->recvlen) +#define BUFLENOK(s) (httpd->recvbuf - (s) < HTTP_RECVLEN) + +static isc_result_t +process_request(isc_httpd_t *httpd, int length) +{ + char *s; + char *p; + int delim; + + ENTER("request"); + + httpd->recvlen += length; + + httpd->recvbuf[httpd->recvlen] = 0; + + /* + * If we don't find a blank line in our buffer, return that we need + * more data. + */ + s = strstr(httpd->recvbuf, "\r\n\r\n"); + delim = 1; + if (s == NULL) { + s = strstr(httpd->recvbuf, "\n\n"); + delim = 2; + } + if (s == NULL) + return (ISC_R_NOTFOUND); + + /* + * Determine if this is a POST or GET method. Any other values will + * cause an error to be returned. + */ + if (strncmp(httpd->recvbuf, "GET ", 4) == 0) { + httpd->method = ISC_HTTPD_METHODGET; + p = httpd->recvbuf + 4; + } else if (strncmp(httpd->recvbuf, "POST ", 5) == 0) { + httpd->method = ISC_HTTPD_METHODPOST; + p = httpd->recvbuf + 5; + } else { + return (ISC_R_RANGE); + } + + /* + * From now on, p is the start of our buffer. + */ + + /* + * Extract the URL. + */ + s = p; + while (LENGTHOK(s) && BUFLENOK(s) && + (*s != '\n' && *s != '\r' && *s != '\0' && *s != ' ')) + s++; + if (!LENGTHOK(s)) + return (ISC_R_NOTFOUND); + if (!BUFLENOK(s)) + return (ISC_R_NOMEMORY); + *s = 0; + + /* + * Make the URL relative. + */ + if ((strncmp(p, "http:/", 6) == 0) + || (strncmp(p, "https:/", 7) == 0)) { + /* Skip first / */ + while (*p != '/' && *p != 0) + p++; + if (*p == 0) + return (ISC_R_RANGE); + p++; + /* Skip second / */ + while (*p != '/' && *p != 0) + p++; + if (*p == 0) + return (ISC_R_RANGE); + p++; + /* Find third / */ + while (*p != '/' && *p != 0) + p++; + if (*p == 0) { + p--; + *p = '/'; + } + } + + httpd->url = p; + p = s + delim; + s = p; + + /* + * Now, see if there is a ? mark in the URL. If so, this is + * part of the query string, and we will split it from the URL. + */ + httpd->querystring = strchr(httpd->url, '?'); + if (httpd->querystring != NULL) { + *(httpd->querystring) = 0; + httpd->querystring++; + } + + /* + * Extract the HTTP/1.X protocol. We will bounce on anything but + * HTTP/1.1 for now. + */ + while (LENGTHOK(s) && BUFLENOK(s) && + (*s != '\n' && *s != '\r' && *s != '\0')) + s++; + if (!LENGTHOK(s)) + return (ISC_R_NOTFOUND); + if (!BUFLENOK(s)) + return (ISC_R_NOMEMORY); + *s = 0; + if ((strncmp(p, "HTTP/1.0", 8) != 0) + && (strncmp(p, "HTTP/1.1", 8) != 0)) + return (ISC_R_RANGE); + httpd->protocol = p; + p = s + 1; + s = p; + + if (strstr(s, "Connection: close") != NULL) + httpd->flags |= HTTPD_CLOSE; + + if (strstr(s, "Host: ") != NULL) + httpd->flags |= HTTPD_FOUNDHOST; + + /* + * Standards compliance hooks here. + */ + if (strcmp(httpd->protocol, "HTTP/1.1") == 0 + && ((httpd->flags & HTTPD_FOUNDHOST) == 0)) + return (ISC_R_RANGE); + + EXIT("request"); + + return (ISC_R_SUCCESS); +} + +static void +isc_httpd_accept(isc_task_t *task, isc_event_t *ev) +{ + isc_result_t result; + isc_httpdmgr_t *httpdmgr = ev->ev_arg; + isc_httpd_t *httpd; + isc_region_t r; + isc_socket_newconnev_t *nev = (isc_socket_newconnev_t *)ev; + isc_sockaddr_t peeraddr; + + ENTER("accept"); + + LOCK(&httpdmgr->lock); + if (MSHUTTINGDOWN(httpdmgr)) { + NOTICE("accept shutting down, goto out"); + goto out; + } + + if (nev->result == ISC_R_CANCELED) { + NOTICE("accept canceled, goto out"); + goto out; + } + + if (nev->result != ISC_R_SUCCESS) { + /* XXXMLG log failure */ + NOTICE("accept returned failure, goto requeue"); + goto requeue; + } + + (void)isc_socket_getpeername(nev->newsocket, &peeraddr); + if (httpdmgr->client_ok != NULL && + !(httpdmgr->client_ok)(&peeraddr, httpdmgr->cb_arg)) { + isc_socket_detach(&nev->newsocket); + goto requeue; + } + + httpd = isc_mem_get(httpdmgr->mctx, sizeof(isc_httpd_t)); + if (httpd == NULL) { + /* XXXMLG log failure */ + NOTICE("accept failed to allocate memory, goto requeue"); + isc_socket_detach(&nev->newsocket); + goto requeue; + } + + httpd->mgr = httpdmgr; + ISC_LINK_INIT(httpd, link); + ISC_LIST_APPEND(httpdmgr->running, httpd, link); + ISC_HTTPD_SETRECV(httpd); + httpd->sock = nev->newsocket; + isc_socket_setname(httpd->sock, "httpd", NULL); + httpd->flags = 0; + + /* + * Initialize the buffer for our headers. + */ + httpd->headerdata = isc_mem_get(httpdmgr->mctx, HTTP_SENDGROW); + if (httpd->headerdata == NULL) { + isc_mem_put(httpdmgr->mctx, httpd, sizeof(isc_httpd_t)); + isc_socket_detach(&nev->newsocket); + goto requeue; + } + httpd->headerlen = HTTP_SENDGROW; + isc_buffer_init(&httpd->headerbuffer, httpd->headerdata, + httpd->headerlen); + + ISC_LIST_INIT(httpd->bufflist); + + isc_buffer_initnull(&httpd->bodybuffer); + reset_client(httpd); + + r.base = (unsigned char *)httpd->recvbuf; + r.length = HTTP_RECVLEN - 1; + result = isc_socket_recv(httpd->sock, &r, 1, task, isc_httpd_recvdone, + httpd); + /* FIXME!!! */ + POST(result); + NOTICE("accept queued recv on socket"); + + requeue: + result = isc_socket_accept(httpdmgr->sock, task, isc_httpd_accept, + httpdmgr); + if (result != ISC_R_SUCCESS) { + /* XXXMLG what to do? Log failure... */ + NOTICE("accept could not reaccept due to failure"); + } + + out: + UNLOCK(&httpdmgr->lock); + + httpdmgr_destroy(httpdmgr); + + isc_event_free(&ev); + + EXIT("accept"); +} + +static isc_result_t +render_404(const char *url, const char *querystring, + void *arg, + unsigned int *retcode, const char **retmsg, + const char **mimetype, isc_buffer_t *b, + isc_httpdfree_t **freecb, void **freecb_args) +{ + static char msg[] = "No such URL."; + + UNUSED(url); + UNUSED(querystring); + UNUSED(arg); + + *retcode = 404; + *retmsg = "No such URL"; + *mimetype = "text/plain"; + isc_buffer_reinit(b, msg, strlen(msg)); + isc_buffer_add(b, strlen(msg)); + *freecb = NULL; + *freecb_args = NULL; + + return (ISC_R_SUCCESS); +} + +static isc_result_t +render_500(const char *url, const char *querystring, + void *arg, + unsigned int *retcode, const char **retmsg, + const char **mimetype, isc_buffer_t *b, + isc_httpdfree_t **freecb, void **freecb_args) +{ + static char msg[] = "Internal server failure."; + + UNUSED(url); + UNUSED(querystring); + UNUSED(arg); + + *retcode = 500; + *retmsg = "Internal server failure"; + *mimetype = "text/plain"; + isc_buffer_reinit(b, msg, strlen(msg)); + isc_buffer_add(b, strlen(msg)); + *freecb = NULL; + *freecb_args = NULL; + + return (ISC_R_SUCCESS); +} + +static void +isc_httpd_recvdone(isc_task_t *task, isc_event_t *ev) +{ + isc_region_t r; + isc_result_t result; + isc_httpd_t *httpd = ev->ev_arg; + isc_socketevent_t *sev = (isc_socketevent_t *)ev; + isc_httpdurl_t *url; + isc_time_t now; + char datebuf[32]; /* Only need 30, but safety first */ + + ENTER("recv"); + + INSIST(ISC_HTTPD_ISRECV(httpd)); + + if (sev->result != ISC_R_SUCCESS) { + NOTICE("recv destroying client"); + destroy_client(&httpd); + goto out; + } + + result = process_request(httpd, sev->n); + if (result == ISC_R_NOTFOUND) { + if (httpd->recvlen >= HTTP_RECVLEN - 1) { + destroy_client(&httpd); + goto out; + } + r.base = (unsigned char *)httpd->recvbuf + httpd->recvlen; + r.length = HTTP_RECVLEN - httpd->recvlen - 1; + /* check return code? */ + (void)isc_socket_recv(httpd->sock, &r, 1, task, + isc_httpd_recvdone, httpd); + goto out; + } else if (result != ISC_R_SUCCESS) { + destroy_client(&httpd); + goto out; + } + + ISC_HTTPD_SETSEND(httpd); + + /* + * XXXMLG Call function here. Provide an add-header function + * which will append the common headers to a response we generate. + */ + isc_buffer_initnull(&httpd->bodybuffer); + isc_time_now(&now); + isc_time_formathttptimestamp(&now, datebuf, sizeof(datebuf)); + url = ISC_LIST_HEAD(httpd->mgr->urls); + while (url != NULL) { + if (strcmp(httpd->url, url->url) == 0) + break; + url = ISC_LIST_NEXT(url, link); + } + if (url == NULL) + result = httpd->mgr->render_404(httpd->url, httpd->querystring, + NULL, + &httpd->retcode, + &httpd->retmsg, + &httpd->mimetype, + &httpd->bodybuffer, + &httpd->freecb, + &httpd->freecb_arg); + else + result = url->action(httpd->url, httpd->querystring, + url->action_arg, + &httpd->retcode, &httpd->retmsg, + &httpd->mimetype, &httpd->bodybuffer, + &httpd->freecb, &httpd->freecb_arg); + if (result != ISC_R_SUCCESS) { + result = httpd->mgr->render_500(httpd->url, httpd->querystring, + NULL, &httpd->retcode, + &httpd->retmsg, + &httpd->mimetype, + &httpd->bodybuffer, + &httpd->freecb, + &httpd->freecb_arg); + RUNTIME_CHECK(result == ISC_R_SUCCESS); + } + + isc_httpd_response(httpd); + isc_httpd_addheader(httpd, "Content-Type", httpd->mimetype); + isc_httpd_addheader(httpd, "Date", datebuf); + isc_httpd_addheader(httpd, "Expires", datebuf); + isc_httpd_addheader(httpd, "Last-Modified", datebuf); + isc_httpd_addheader(httpd, "Pragma: no-cache", NULL); + isc_httpd_addheader(httpd, "Cache-Control: no-cache", NULL); + isc_httpd_addheader(httpd, "Server: libisc", NULL); + isc_httpd_addheaderuint(httpd, "Content-Length", + isc_buffer_usedlength(&httpd->bodybuffer)); + isc_httpd_endheaders(httpd); /* done */ + + ISC_LIST_APPEND(httpd->bufflist, &httpd->headerbuffer, link); + /* + * Link the data buffer into our send queue, should we have any data + * rendered into it. If no data is present, we won't do anything + * with the buffer. + */ + if (isc_buffer_length(&httpd->bodybuffer) > 0) + ISC_LIST_APPEND(httpd->bufflist, &httpd->bodybuffer, link); + + /* check return code? */ + (void)isc_socket_sendv(httpd->sock, &httpd->bufflist, task, + isc_httpd_senddone, httpd); + + out: + isc_event_free(&ev); + EXIT("recv"); +} + +void +isc_httpdmgr_shutdown(isc_httpdmgr_t **httpdmgrp) +{ + isc_httpdmgr_t *httpdmgr; + isc_httpd_t *httpd; + httpdmgr = *httpdmgrp; + *httpdmgrp = NULL; + + ENTER("isc_httpdmgr_shutdown"); + + LOCK(&httpdmgr->lock); + + MSETSHUTTINGDOWN(httpdmgr); + + isc_socket_cancel(httpdmgr->sock, httpdmgr->task, ISC_SOCKCANCEL_ALL); + + httpd = ISC_LIST_HEAD(httpdmgr->running); + while (httpd != NULL) { + isc_socket_cancel(httpd->sock, httpdmgr->task, + ISC_SOCKCANCEL_ALL); + httpd = ISC_LIST_NEXT(httpd, link); + } + + UNLOCK(&httpdmgr->lock); + + EXIT("isc_httpdmgr_shutdown"); +} + +static isc_result_t +grow_headerspace(isc_httpd_t *httpd) +{ + char *newspace; + unsigned int newlen; + isc_region_t r; + + newlen = httpd->headerlen + HTTP_SENDGROW; + if (newlen > HTTP_SEND_MAXLEN) + return (ISC_R_NOSPACE); + + newspace = isc_mem_get(httpd->mgr->mctx, newlen); + if (newspace == NULL) + return (ISC_R_NOMEMORY); + isc_buffer_region(&httpd->headerbuffer, &r); + isc_buffer_reinit(&httpd->headerbuffer, newspace, newlen); + + isc_mem_put(httpd->mgr->mctx, r.base, r.length); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_response(isc_httpd_t *httpd) +{ + isc_result_t result; + unsigned int needlen; + + needlen = strlen(httpd->protocol) + 1; /* protocol + space */ + needlen += 3 + 1; /* room for response code, always 3 bytes */ + needlen += strlen(httpd->retmsg) + 2; /* return msg + CRLF */ + + while (isc_buffer_availablelength(&httpd->headerbuffer) < needlen) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + sprintf(isc_buffer_used(&httpd->headerbuffer), "%s %03d %s\r\n", + httpd->protocol, httpd->retcode, httpd->retmsg); + isc_buffer_add(&httpd->headerbuffer, needlen); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_addheader(isc_httpd_t *httpd, const char *name, + const char *val) +{ + isc_result_t result; + unsigned int needlen; + + needlen = strlen(name); /* name itself */ + if (val != NULL) + needlen += 2 + strlen(val); /* : and val */ + needlen += 2; /* CRLF */ + + while (isc_buffer_availablelength(&httpd->headerbuffer) < needlen) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + if (val != NULL) + sprintf(isc_buffer_used(&httpd->headerbuffer), + "%s: %s\r\n", name, val); + else + sprintf(isc_buffer_used(&httpd->headerbuffer), + "%s\r\n", name); + + isc_buffer_add(&httpd->headerbuffer, needlen); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_endheaders(isc_httpd_t *httpd) +{ + isc_result_t result; + + while (isc_buffer_availablelength(&httpd->headerbuffer) < 2) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + sprintf(isc_buffer_used(&httpd->headerbuffer), "\r\n"); + isc_buffer_add(&httpd->headerbuffer, 2); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_httpd_addheaderuint(isc_httpd_t *httpd, const char *name, int val) { + isc_result_t result; + unsigned int needlen; + char buf[sizeof "18446744073709551616"]; + + sprintf(buf, "%d", val); + + needlen = strlen(name); /* name itself */ + needlen += 2 + strlen(buf); /* : and val */ + needlen += 2; /* CRLF */ + + while (isc_buffer_availablelength(&httpd->headerbuffer) < needlen) { + result = grow_headerspace(httpd); + if (result != ISC_R_SUCCESS) + return (result); + } + + sprintf(isc_buffer_used(&httpd->headerbuffer), + "%s: %s\r\n", name, buf); + + isc_buffer_add(&httpd->headerbuffer, needlen); + + return (ISC_R_SUCCESS); +} + +static void +isc_httpd_senddone(isc_task_t *task, isc_event_t *ev) +{ + isc_httpd_t *httpd = ev->ev_arg; + isc_region_t r; + isc_socketevent_t *sev = (isc_socketevent_t *)ev; + + ENTER("senddone"); + INSIST(ISC_HTTPD_ISSEND(httpd)); + + /* + * First, unlink our header buffer from the socket's bufflist. This + * is sort of an evil hack, since we know our buffer will be there, + * and we know it's address, so we can just remove it directly. + */ + NOTICE("senddone unlinked header"); + ISC_LIST_UNLINK(sev->bufferlist, &httpd->headerbuffer, link); + + /* + * We will always want to clean up our receive buffer, even if we + * got an error on send or we are shutting down. + * + * We will pass in the buffer only if there is data in it. If + * there is no data, we will pass in a NULL. + */ + if (httpd->freecb != NULL) { + isc_buffer_t *b = NULL; + if (isc_buffer_length(&httpd->bodybuffer) > 0) + b = &httpd->bodybuffer; + httpd->freecb(b, httpd->freecb_arg); + NOTICE("senddone free callback performed"); + } + if (ISC_LINK_LINKED(&httpd->bodybuffer, link)) { + ISC_LIST_UNLINK(sev->bufferlist, &httpd->bodybuffer, link); + NOTICE("senddone body buffer unlinked"); + } + + if (sev->result != ISC_R_SUCCESS) { + destroy_client(&httpd); + goto out; + } + + if ((httpd->flags & HTTPD_CLOSE) != 0) { + destroy_client(&httpd); + goto out; + } + + ISC_HTTPD_SETRECV(httpd); + + NOTICE("senddone restarting recv on socket"); + + reset_client(httpd); + + r.base = (unsigned char *)httpd->recvbuf; + r.length = HTTP_RECVLEN - 1; + /* check return code? */ + (void)isc_socket_recv(httpd->sock, &r, 1, task, + isc_httpd_recvdone, httpd); + +out: + isc_event_free(&ev); + EXIT("senddone"); +} + +static void +reset_client(isc_httpd_t *httpd) +{ + /* + * Catch errors here. We MUST be in RECV mode, and we MUST NOT have + * any outstanding buffers. If we have buffers, we have a leak. + */ + INSIST(ISC_HTTPD_ISRECV(httpd)); + INSIST(!ISC_LINK_LINKED(&httpd->headerbuffer, link)); + INSIST(!ISC_LINK_LINKED(&httpd->bodybuffer, link)); + + httpd->recvbuf[0] = 0; + httpd->recvlen = 0; + httpd->method = ISC_HTTPD_METHODUNKNOWN; + httpd->url = NULL; + httpd->querystring = NULL; + httpd->protocol = NULL; + httpd->flags = 0; + + isc_buffer_clear(&httpd->headerbuffer); + isc_buffer_invalidate(&httpd->bodybuffer); +} + +isc_result_t +isc_httpdmgr_addurl(isc_httpdmgr_t *httpdmgr, const char *url, + isc_httpdaction_t *func, void *arg) +{ + isc_httpdurl_t *item; + + if (url == NULL) { + httpdmgr->render_404 = func; + return (ISC_R_SUCCESS); + } + + item = isc_mem_get(httpdmgr->mctx, sizeof(isc_httpdurl_t)); + if (item == NULL) + return (ISC_R_NOMEMORY); + + item->url = isc_mem_strdup(httpdmgr->mctx, url); + if (item->url == NULL) { + isc_mem_put(httpdmgr->mctx, item, sizeof(isc_httpdurl_t)); + return (ISC_R_NOMEMORY); + } + + item->action = func; + item->action_arg = arg; + ISC_LINK_INIT(item, link); + ISC_LIST_APPEND(httpdmgr->urls, item, link); + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/ia64/include/isc/atomic.h b/contrib/ntp/lib/isc/ia64/include/isc/atomic.h new file mode 100644 index 000000000..6c22f2a53 --- /dev/null +++ b/contrib/ntp/lib/isc/ia64/include/isc/atomic.h @@ -0,0 +1,100 @@ +/* + * Copyright (C) 2006, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.7 2009/06/24 02:22:50 marka Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + * + * Open issue: can 'fetchadd' make the code faster for some particular values + * (e.g., 1 and -1)? + */ +static inline isc_int32_t +#ifdef __GNUC__ +__attribute__ ((unused)) +#endif +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) +{ + isc_int32_t prev, swapped; + + for (prev = *(volatile isc_int32_t *)p; ; prev = swapped) { + swapped = prev + val; + __asm__ volatile( + "mov ar.ccv=%2;" + "cmpxchg4.acq %0=%4,%3,ar.ccv" + : "=r" (swapped), "=m" (*p) + : "r" (prev), "r" (swapped), "m" (*p) + : "memory"); + if (swapped == prev) + break; + } + + return (prev); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +#ifdef __GNUC__ +__attribute__ ((unused)) +#endif +isc_atomic_store(isc_int32_t *p, isc_int32_t val) +{ + __asm__ volatile( + "st4.rel %0=%1" + : "=m" (*p) + : "r" (val) + : "memory" + ); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +#ifdef __GNUC__ +__attribute__ ((unused)) +#endif +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) +{ + isc_int32_t ret; + + __asm__ volatile( + "mov ar.ccv=%2;" + "cmpxchg4.acq %0=%4,%3,ar.ccv" + : "=r" (ret), "=m" (*p) + : "r" (cmpval), "r" (val), "m" (*p) + : "memory"); + + return (ret); +} +#else /* !ISC_PLATFORM_USEGCCASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/lib/isc/include/isc/app.h b/contrib/ntp/lib/isc/include/isc/app.h new file mode 100644 index 000000000..e0be79063 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/app.h @@ -0,0 +1,375 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: app.h,v 1.11 2009/09/02 23:48:03 tbox Exp $ */ + +#ifndef ISC_APP_H +#define ISC_APP_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/app.h + * \brief ISC Application Support + * + * Dealing with program termination can be difficult, especially in a + * multithreaded program. The routines in this module help coordinate + * the shutdown process. They are used as follows by the initial (main) + * thread of the application: + * + *\li isc_app_start(); Call very early in main(), before + * any other threads have been created. + * + *\li isc_app_run(); This will post any on-run events, + * and then block until application + * shutdown is requested. A shutdown + * request is made by calling + * isc_app_shutdown(), or by sending + * SIGINT or SIGTERM to the process. + * After isc_app_run() returns, the + * application should shutdown itself. + * + *\li isc_app_finish(); Call very late in main(). + * + * Applications that want to use SIGHUP/isc_app_reload() to trigger reloading + * should check the result of isc_app_run() and call the reload routine if + * the result is ISC_R_RELOAD. They should then call isc_app_run() again + * to resume waiting for reload or termination. + * + * Use of this module is not required. In particular, isc_app_start() is + * NOT an ISC library initialization routine. + * + * This module also supports per-thread 'application contexts'. With this + * mode, a thread-based application will have a separate context, in which + * it uses other ISC library services such as tasks or timers. Signals are + * not caught in this mode, so that the application can handle the signals + * in its preferred way. + * + * \li MP: + * Clients must ensure that isc_app_start(), isc_app_run(), and + * isc_app_finish() are called at most once. isc_app_shutdown() + * is safe to use by any thread (provided isc_app_start() has been + * called previously). + * + * The same note applies to isc_app_ctxXXX() functions, but in this case + * it's a per-thread restriction. For example, a thread with an + * application context must ensure that isc_app_ctxstart() with the + * context is called at most once. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * None. + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +#include +#include +#include +#include + +/*** + *** Types + ***/ + +typedef isc_event_t isc_appevent_t; + +#define ISC_APPEVENT_FIRSTEVENT (ISC_EVENTCLASS_APP + 0) +#define ISC_APPEVENT_SHUTDOWN (ISC_EVENTCLASS_APP + 1) +#define ISC_APPEVENT_LASTEVENT (ISC_EVENTCLASS_APP + 65535) + +/*% + * app module methods. Only app driver implementations use this structure. + * Other clients should use the top-level interfaces (i.e., isc_app_xxx + * functions). magic must be ISCAPI_APPMETHODS_MAGIC. + */ +typedef struct isc_appmethods { + void (*ctxdestroy)(isc_appctx_t **ctxp); + isc_result_t (*ctxstart)(isc_appctx_t *ctx); + isc_result_t (*ctxrun)(isc_appctx_t *ctx); + isc_result_t (*ctxsuspend)(isc_appctx_t *ctx); + isc_result_t (*ctxshutdown)(isc_appctx_t *ctx); + void (*ctxfinish)(isc_appctx_t *ctx); + void (*settaskmgr)(isc_appctx_t *ctx, + isc_taskmgr_t *timermgr); + void (*setsocketmgr)(isc_appctx_t *ctx, + isc_socketmgr_t *timermgr); + void (*settimermgr)(isc_appctx_t *ctx, + isc_timermgr_t *timermgr); +} isc_appmethods_t; + +/*% + * This structure is actually just the common prefix of an application context + * implementation's version of an isc_appctx_t. + * \brief + * Direct use of this structure by clients is forbidden. app implementations + * may change the structure. 'magic' must be ISCAPI_APPCTX_MAGIC for any + * of the isc_app_ routines to work. app implementations must maintain + * all app context invariants. + */ +struct isc_appctx { + unsigned int impmagic; + unsigned int magic; + isc_appmethods_t *methods; +}; + +#define ISCAPI_APPCTX_MAGIC ISC_MAGIC('A','a','p','c') +#define ISCAPI_APPCTX_VALID(c) ((c) != NULL && \ + (c)->magic == ISCAPI_APPCTX_MAGIC) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_app_ctxstart(isc_appctx_t *ctx); + +isc_result_t +isc_app_start(void); +/*!< + * \brief Start an ISC library application. + * + * Notes: + * This call should be made before any other ISC library call, and as + * close to the beginning of the application as possible. + * + * Requires: + * 'ctx' is a valid application context (for app_ctxstart()). + */ + +isc_result_t +isc_app_onrun(isc_mem_t *mctx, isc_task_t *task, isc_taskaction_t action, + void *arg); +/*!< + * \brief Request delivery of an event when the application is run. + * + * Requires: + *\li isc_app_start() has been called. + * + * Returns: + * ISC_R_SUCCESS + * ISC_R_NOMEMORY + */ + +isc_result_t +isc_app_ctxrun(isc_appctx_t *ctx); + +isc_result_t +isc_app_run(void); +/*!< + * \brief Run an ISC library application. + * + * Notes: + *\li The caller (typically the initial thread of an application) will + * block until shutdown is requested. When the call returns, the + * caller should start shutting down the application. + * + * Requires: + *\li isc_app_[ctx]start() has been called. + * + * Ensures: + *\li Any events requested via isc_app_onrun() will have been posted (in + * FIFO order) before isc_app_run() blocks. + *\li 'ctx' is a valid application context (for app_ctxrun()). + * + * Returns: + *\li ISC_R_SUCCESS Shutdown has been requested. + *\li ISC_R_RELOAD Reload has been requested. + */ + +isc_result_t +isc_app_ctxshutdown(isc_appctx_t *ctx); + +isc_result_t +isc_app_shutdown(void); +/*!< + * \brief Request application shutdown. + * + * Notes: + *\li It is safe to call isc_app_shutdown() multiple times. Shutdown will + * only be triggered once. + * + * Requires: + *\li isc_app_[ctx]run() has been called. + *\li 'ctx' is a valid application context (for app_ctxshutdown()). + * + * Returns: + *\li ISC_R_SUCCESS + *\li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_app_ctxsuspend(isc_appctx_t *ctx); +/*!< + * \brief This has the same behavior as isc_app_ctxsuspend(). + */ + +isc_result_t +isc_app_reload(void); +/*!< + * \brief Request application reload. + * + * Requires: + *\li isc_app_run() has been called. + * + * Returns: + *\li ISC_R_SUCCESS + *\li ISC_R_UNEXPECTED + */ + +void +isc_app_ctxfinish(isc_appctx_t *ctx); + +void +isc_app_finish(void); +/*!< + * \brief Finish an ISC library application. + * + * Notes: + *\li This call should be made at or near the end of main(). + * + * Requires: + *\li isc_app_start() has been called. + *\li 'ctx' is a valid application context (for app_ctxfinish()). + * + * Ensures: + *\li Any resources allocated by isc_app_start() have been released. + */ + +void +isc_app_block(void); +/*!< + * \brief Indicate that a blocking operation will be performed. + * + * Notes: + *\li If a blocking operation is in process, a call to isc_app_shutdown() + * or an external signal will abort the program, rather than allowing + * clean shutdown. This is primarily useful for reading user input. + * + * Requires: + * \li isc_app_start() has been called. + * \li No other blocking operations are in progress. + */ + +void +isc_app_unblock(void); +/*!< + * \brief Indicate that a blocking operation is complete. + * + * Notes: + * \li When a blocking operation has completed, return the program to a + * state where a call to isc_app_shutdown() or an external signal will + * shutdown normally. + * + * Requires: + * \li isc_app_start() has been called. + * \li isc_app_block() has been called by the same thread. + */ + +isc_result_t +isc_appctx_create(isc_mem_t *mctx, isc_appctx_t **ctxp); +/*!< + * \brief Create an application context. + * + * Requires: + *\li 'mctx' is a valid memory context. + *\li 'ctxp' != NULL && *ctxp == NULL. + */ + +void +isc_appctx_destroy(isc_appctx_t **ctxp); +/*!< + * \brief Destroy an application context. + * + * Requires: + *\li '*ctxp' is a valid application context. + * + * Ensures: + *\li *ctxp == NULL. + */ + +void +isc_appctx_settaskmgr(isc_appctx_t *ctx, isc_taskmgr_t *taskmgr); +/*!< + * \brief Associate a task manager with an application context. + * + * This must be done before running tasks within the application context. + * + * Requires: + *\li 'ctx' is a valid application context. + *\li 'taskmgr' is a valid task manager. + */ + +void +isc_appctx_setsocketmgr(isc_appctx_t *ctx, isc_socketmgr_t *socketmgr); +/*!< + * \brief Associate a socket manager with an application context. + * + * This must be done before handling socket events within the application + * context. + * + * Requires: + *\li 'ctx' is a valid application context. + *\li 'socketmgr' is a valid socket manager. + */ + +void +isc_appctx_settimermgr(isc_appctx_t *ctx, isc_timermgr_t *timermgr); +/*!< + * \brief Associate a socket timer with an application context. + * + * This must be done before handling timer events within the application + * context. + * + * Requires: + *\li 'ctx' is a valid application context. + *\li 'timermgr' is a valid timer manager. + */ + +#ifdef USE_APPIMPREGISTER +/*%< + * See isc_appctx_create() above. + */ +typedef isc_result_t +(*isc_appctxcreatefunc_t)(isc_mem_t *mctx, isc_appctx_t **ctxp); + +isc_result_t +isc_app_register(isc_appctxcreatefunc_t createfunc); +/*%< + * Register a new application implementation and add it to the list of + * supported implementations. This function must be called when a different + * event library is used than the one contained in the ISC library. + */ + +isc_result_t +isc__app_register(void); +/*%< + * A short cut function that specifies the application module in the ISC + * library for isc_app_register(). An application that uses the ISC library + * usually do not have to care about this function: it would call + * isc_lib_register(), which internally calls this function. + */ +#endif /* USE_APPIMPREGISTER */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_APP_H */ diff --git a/contrib/ntp/include/isc/assertions.h b/contrib/ntp/lib/isc/include/isc/assertions.h similarity index 71% rename from contrib/ntp/include/isc/assertions.h rename to contrib/ntp/lib/isc/include/isc/assertions.h index 45855c663..2c81b1ae9 100644 --- a/contrib/ntp/include/isc/assertions.h +++ b/contrib/ntp/lib/isc/include/isc/assertions.h @@ -1,22 +1,24 @@ /* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1997-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ /* - * $Id: assertions.h,v 1.17 2001/07/12 05:58:21 mayer Exp $ + * $Id: assertions.h,v 1.28 2009/09/29 23:48:04 tbox Exp $ + */ +/*! \file isc/assertions.h */ #ifndef ISC_ASSERTIONS_H @@ -27,6 +29,7 @@ ISC_LANG_BEGINDECLS +/*% isc assertion type */ typedef enum { isc_assertiontype_require, isc_assertiontype_ensure, @@ -37,7 +40,10 @@ typedef enum { typedef void (*isc_assertioncallback_t)(const char *, int, isc_assertiontype_t, const char *); -LIBISC_EXTERNAL_DATA extern isc_assertioncallback_t isc_assertion_failed; +/* coverity[+kill] */ +ISC_PLATFORM_NORETURN_PRE +void isc_assertion_failed(const char *, int, isc_assertiontype_t, + const char *) ISC_PLATFORM_NORETURN_POST; void isc_assertion_setcallback(isc_assertioncallback_t); @@ -45,14 +51,14 @@ isc_assertion_setcallback(isc_assertioncallback_t); const char * isc_assertion_typetotext(isc_assertiontype_t type); -#ifdef ISC_CHECK_ALL +#if defined(ISC_CHECK_ALL) || defined(__COVERITY__) #define ISC_CHECK_REQUIRE 1 #define ISC_CHECK_ENSURE 1 #define ISC_CHECK_INSIST 1 #define ISC_CHECK_INVARIANT 1 #endif -#ifdef ISC_CHECK_NONE +#if defined(ISC_CHECK_NONE) && !defined(__COVERITY__) #define ISC_CHECK_REQUIRE 0 #define ISC_CHECK_ENSURE 0 #define ISC_CHECK_INSIST 0 diff --git a/contrib/ntp/lib/isc/include/isc/backtrace.h b/contrib/ntp/lib/isc/include/isc/backtrace.h new file mode 100644 index 000000000..7d7fc3217 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/backtrace.h @@ -0,0 +1,131 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: backtrace.h,v 1.2 2009/09/01 18:40:25 jinmei Exp $ */ + +/*! \file isc/backtrace.h + * \brief provide a back trace of the running process to help debug problems. + * + * This module tries to get a back trace of the process using some platform + * dependent way when available. It also manages an internal symbol table + * that maps function addresses used in the process to their textual symbols. + * This module is expected to be used to help debug when some fatal error + * happens. + * + * IMPORTANT NOTE: since the (major) intended use case of this module is + * dumping a back trace on a fatal error, normally followed by self termination, + * functions defined in this module generally doesn't employ assertion checks + * (if it did, a program bug could cause infinite recursive calls to a + * backtrace function). These functions still perform minimal checks and return + * ISC_R_FAILURE if they detect an error, but the caller should therefore be + * very careful about the use of these functions, and generally discouraged to + * use them except in an exit path. The exception is + * isc_backtrace_getsymbolfromindex(), which is expected to be used in a + * non-error-handling context and validates arguments with assertion checks. + */ + +#ifndef ISC_BACKTRACE_H +#define ISC_BACKTRACE_H 1 + +/*** + *** Imports + ***/ + +#include + +/*** + *** Types + ***/ +struct isc_backtrace_symmap { + void *addr; + const char *symbol; +}; + +extern const int isc__backtrace_nsymbols; +extern const isc_backtrace_symmap_t isc__backtrace_symtable[]; + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS +isc_result_t +isc_backtrace_gettrace(void **addrs, int maxaddrs, int *nframes); +/*%< + * Get a back trace of the running process above this function itself. On + * success, addrs[i] will store the address of the call point of the i-th + * stack frame (addrs[0] is the caller of this function). *nframes will store + * the total number of frames. + * + * Requires (note that these are not ensured by assertion checks, see above): + * + *\li 'addrs' is a valid array containing at least 'maxaddrs' void * entries. + * + *\li 'nframes' must be non NULL. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_FAILURE + *\li #ISC_R_NOTFOUND + *\li #ISC_R_NOTIMPLEMENTED + */ + +isc_result_t +isc_backtrace_getsymbolfromindex(int idx, const void **addrp, + const char **symbolp); +/*%< + * Returns the content of the internal symbol table of the given index. + * On success, *addrsp and *symbolp point to the address and the symbol of + * the 'index'th entry of the table, respectively. If 'idx' is not in the + * range of the symbol table, ISC_R_RANGE will be returned. + * + * Requires + * + *\li 'addrp' must be non NULL && '*addrp' == NULL. + * + *\li 'symbolp' must be non NULL && '*symbolp' == NULL. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_RANGE + */ + +isc_result_t +isc_backtrace_getsymbol(const void *addr, const char **symbolp, + unsigned long *offsetp); +/*%< + * Searches the internal symbol table for the symbol that most matches the + * given 'addr'. On success, '*symbolp' will point to the name of function + * to which the address 'addr' belong, and '*offsetp' will store the offset + * from the function's entry address to 'addr'. + * + * Requires (note that these are not ensured by assertion checks, see above): + * + *\li 'symbolp' must be non NULL && '*symbolp' == NULL. + * + *\li 'offsetp' must be non NULL. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_FAILURE + *\li #ISC_R_NOTFOUND + */ +ISC_LANG_ENDDECLS + +#endif /* ISC_BACKTRACE_H */ diff --git a/contrib/ntp/lib/isc/include/isc/base32.h b/contrib/ntp/lib/isc/include/isc/base32.h new file mode 100644 index 000000000..978a8db46 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/base32.h @@ -0,0 +1,128 @@ +/* + * Copyright (C) 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base32.h,v 1.3 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_BASE32_H +#define ISC_BASE32_H 1 + +/*! \file */ + +/* + * Routines for manipulating base 32 and base 32 hex encoded data. + * Based on RFC 4648. + * + * Base 32 hex preserves the sort order of data when it is encoded / + * decoded. + */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_base32_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +isc_result_t +isc_base32hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +/*!< + * \brief Convert data into base32 encoded text. + * + * Notes: + *\li The base32 encoded text in 'target' will be divided into + * words of at most 'wordlength' characters, separated by + * the 'wordbreak' string. No parentheses will surround + * the text. + * + * Requires: + *\li 'source' is a region containing binary data + *\li 'target' is a text buffer containing available space + *\li 'wordbreak' points to a null-terminated string of + * zero or more whitespace characters + * + * Ensures: + *\li target will contain the base32 encoded version of the data + * in source. The 'used' pointer in target will be advanced as + * necessary. + */ + +isc_result_t +isc_base32_decodestring(const char *cstr, isc_buffer_t *target); +isc_result_t +isc_base32hex_decodestring(const char *cstr, isc_buffer_t *target); +/*!< + * \brief Decode a null-terminated base32 string. + * + * Requires: + *\li 'cstr' is non-null. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADBASE32 -- 'cstr' is not a valid base32 encoding. + * + * Other error returns are any possible error code from: + *\li isc_lex_create(), + *\li isc_lex_openbuffer(), + *\li isc_base32_tobuffer(). + */ + +isc_result_t +isc_base32_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +isc_result_t +isc_base32hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +/*!< + * \brief Convert base32 encoded text from a lexer context into data. + * + * Requires: + *\li 'lex' is a valid lexer context + *\li 'target' is a buffer containing binary data + *\li 'length' is an integer + * + * Ensures: + *\li target will contain the data represented by the base32 encoded + * string parsed by the lexer. No more than length bytes will be read, + * if length is positive. The 'used' pointer in target will be + * advanced as necessary. + */ + +isc_result_t +isc_base32_decoderegion(isc_region_t *source, isc_buffer_t *target); +isc_result_t +isc_base32hex_decoderegion(isc_region_t *source, isc_buffer_t *target); +/*!< + * \brief Decode a packed (no white space permitted) base32 region. + * + * Requires: + *\li 'source' is a valid region. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADBASE32 -- 'source' is not a valid base32 encoding. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_BASE32_H */ diff --git a/contrib/ntp/lib/isc/include/isc/base64.h b/contrib/ntp/lib/isc/include/isc/base64.h new file mode 100644 index 000000000..e48ef2a40 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/base64.h @@ -0,0 +1,99 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: base64.h,v 1.22 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BASE64_H +#define ISC_BASE64_H 1 + +/*! \file isc/base64.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_base64_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +/*!< + * \brief Convert data into base64 encoded text. + * + * Notes: + *\li The base64 encoded text in 'target' will be divided into + * words of at most 'wordlength' characters, separated by + * the 'wordbreak' string. No parentheses will surround + * the text. + * + * Requires: + *\li 'source' is a region containing binary data + *\li 'target' is a text buffer containing available space + *\li 'wordbreak' points to a null-terminated string of + * zero or more whitespace characters + * + * Ensures: + *\li target will contain the base64 encoded version of the data + * in source. The 'used' pointer in target will be advanced as + * necessary. + */ + +isc_result_t +isc_base64_decodestring(const char *cstr, isc_buffer_t *target); +/*!< + * \brief Decode a null-terminated base64 string. + * + * Requires: + *\li 'cstr' is non-null. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADBASE64 -- 'cstr' is not a valid base64 encoding. + * + * Other error returns are any possible error code from: + *\li isc_lex_create(), + *\li isc_lex_openbuffer(), + *\li isc_base64_tobuffer(). + */ + +isc_result_t +isc_base64_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +/*!< + * \brief Convert base64 encoded text from a lexer context into data. + * + * Requires: + *\li 'lex' is a valid lexer context + *\li 'target' is a buffer containing binary data + *\li 'length' is an integer + * + * Ensures: + *\li target will contain the data represented by the base64 encoded + * string parsed by the lexer. No more than length bytes will be read, + * if length is positive. The 'used' pointer in target will be + * advanced as necessary. + */ + + + +ISC_LANG_ENDDECLS + +#endif /* ISC_BASE64_H */ diff --git a/contrib/ntp/lib/isc/include/isc/bind9.h b/contrib/ntp/lib/isc/include/isc/bind9.h new file mode 100644 index 000000000..00bcb24c4 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/bind9.h @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bind9.h,v 1.2 2009/12/05 23:31:41 each Exp $ */ + +#ifndef ISC_BIND9_H +#define ISC_BIND9_H 1 + +/* + * This determines whether we are building BIND9 or using the exported + * libisc/libdns libraries. The version of this file included in the + * standard BIND9 build defines BIND9; the version included with the + * exportable libraries does not. + */ +#define BIND9 1 + +#endif /* ISC_BIND9_H */ diff --git a/contrib/ntp/lib/isc/include/isc/bitstring.h b/contrib/ntp/lib/isc/include/isc/bitstring.h new file mode 100644 index 000000000..252d1117a --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/bitstring.h @@ -0,0 +1,157 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bitstring.h,v 1.14 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BITSTRING_H +#define ISC_BITSTRING_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/bitstring.h + * + * \brief Bitstring manipulation functions. + * + * A bitstring is a packed array of bits, stored in a contiguous + * sequence of octets. The "most significant bit" (msb) of a bitstring + * is the high bit of the first octet. The "least significant bit" of a + * bitstring is the low bit of the last octet. + * + * Two bit numbering schemes are supported, "msb0" and "lsb0". + * + * In the "msb0" scheme, bit number 0 designates the most significant bit, + * and any padding bits required to make the bitstring a multiple of 8 bits + * long are added to the least significant end of the last octet. + * + * In the "lsb0" scheme, bit number 0 designates the least significant bit, + * and any padding bits required to make the bitstring a multiple of 8 bits + * long are added to the most significant end of the first octet. + * + * E.g., consider the bitstring "11010001111". This bitstring is 11 bits + * long and will take two octets. Let "p" denote a pad bit. In the msb0 + * encoding, it would be + * + * \verbatim + * Octet 0 Octet 1 + * | + * 1 1 0 1 0 0 0 1 | 1 1 1 p p p p p + * ^ | ^ + * | | + * bit 0 bit 15 + * \endverbatim + * + * In the lsb0 encoding, it would be + * + * \verbatim + * Octet 0 Octet 1 + * | + * p p p p p 1 1 0 | 1 0 0 0 1 1 1 1 + * ^ | ^ + * | | + * bit 15 bit 0 + * \endverbatim + */ + +/*** + *** Imports + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Types + ***/ + +struct isc_bitstring { + unsigned int magic; + unsigned char * data; + unsigned int length; + unsigned int size; + isc_boolean_t lsb0; +}; + +/*** + *** Functions + ***/ + +void +isc_bitstring_init(isc_bitstring_t *bitstring, unsigned char *data, + unsigned int length, unsigned int size, isc_boolean_t lsb0); +/*!< + * \brief Make 'bitstring' refer to the bitstring of 'size' bits starting + * at 'data'. 'length' bits of the bitstring are valid. If 'lsb0' + * is set then, bit 0 refers to the least significant bit of the + * bitstring. Otherwise bit 0 is the most significant bit. + * + * Requires: + * + *\li 'bitstring' points to a isc_bitstring_t. + * + *\li 'data' points to an array of unsigned char large enough to hold + * 'size' bits. + * + *\li 'length' <= 'size'. + * + * Ensures: + * + *\li 'bitstring' is a valid bitstring. + */ + +void +isc_bitstring_invalidate(isc_bitstring_t *bitstring); +/*!< + * \brief Invalidate 'bitstring'. + * + * Requires: + * + *\li 'bitstring' is a valid bitstring. + * + * Ensures: + * + *\li 'bitstring' is not a valid bitstring. + */ + +void +isc_bitstring_copy(isc_bitstring_t *source, unsigned int sbitpos, + isc_bitstring_t *target, unsigned int tbitpos, + unsigned int n); +/*!< + * \brief Starting at bit 'sbitpos', copy 'n' bits from 'source' to + * the 'n' bits of 'target' starting at 'tbitpos'. + * + * Requires: + * + *\li 'source' and target are valid bitstrings with the same lsb0 setting. + * + *\li 'sbitpos' + 'n' is less than or equal to the length of 'source'. + * + *\li 'tbitpos' + 'n' is less than or equal to the size of 'target'. + * + * Ensures: + * + *\li The specified bits have been copied, and the length of 'target' + * adjusted (if required). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_BITSTRING_H */ diff --git a/contrib/ntp/lib/isc/include/isc/boolean.h b/contrib/ntp/lib/isc/include/isc/boolean.h new file mode 100644 index 000000000..348b09691 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/boolean.h @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: boolean.h,v 1.19 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BOOLEAN_H +#define ISC_BOOLEAN_H 1 + +/*! \file isc/boolean.h */ + +typedef enum { isc_boolean_false = 0, isc_boolean_true = 1 } isc_boolean_t; + +#define ISC_FALSE isc_boolean_false +#define ISC_TRUE isc_boolean_true +#define ISC_TF(x) ((x) ? ISC_TRUE : ISC_FALSE) + +#endif /* ISC_BOOLEAN_H */ diff --git a/contrib/ntp/include/isc/buffer.h b/contrib/ntp/lib/isc/include/isc/buffer.h similarity index 67% rename from contrib/ntp/include/isc/buffer.h rename to contrib/ntp/lib/isc/include/isc/buffer.h index 47c8f0c95..ae7e4c3df 100644 --- a/contrib/ntp/include/isc/buffer.h +++ b/contrib/ntp/lib/isc/include/isc/buffer.h @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2008, 2010 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: buffer.h,v 1.39.12.2 2004/03/08 09:04:51 marka Exp $ */ +/* $Id: buffer.h,v 1.55 2010/12/20 23:47:21 tbox Exp $ */ #ifndef ISC_BUFFER_H #define ISC_BUFFER_H 1 @@ -24,10 +24,9 @@ ***** Module Info *****/ -/* - * Buffers +/*! \file isc/buffer.h * - * A buffer is a region of memory, together with a set of related subregions. + * \brief A buffer is a region of memory, together with a set of related subregions. * Buffers are used for parsing and I/O operations. * * The 'used region' and the 'available' region are disjoint, and their @@ -51,6 +50,7 @@ * is empty. If the current offset advances beyond the chosen offset, the * active region will also be empty. * + * \verbatim * /------------entire length---------------\ * /----- used region -----\/-- available --\ * +----------------------------------------+ @@ -69,9 +69,11 @@ * a-b == consumed region. * b-d == remaining region. * b-c == optional active region. + *\endverbatim * * The following invariants are maintained by all routines: * + *\code * length > 0 * * base is a valid pointer to length bytes of memory @@ -82,21 +84,22 @@ * * 0 <= active <= used * (although active < current implies empty active region) + *\endcode * - * MP: + * \li MP: * Buffers have no synchronization. Clients must ensure exclusive * access. * - * Reliability: + * \li Reliability: * No anticipated impact. * - * Resources: + * \li Resources: * Memory: 1 pointer + 6 unsigned integers per buffer. * - * Security: + * \li Security: * No anticipated impact. * - * Standards: + * \li Standards: * None. */ @@ -108,19 +111,21 @@ #include #include -/* - * To make many functions be inline macros (via #define) define this. +/*! + * To make many functions be inline macros (via \#define) define this. * If it is undefined, a function will be used. */ -#define ISC_BUFFER_USEINLINE +/* #define ISC_BUFFER_USEINLINE */ ISC_LANG_BEGINDECLS -/*** +/*@{*/ +/*! *** Magic numbers ***/ #define ISC_BUFFER_MAGIC 0x42756621U /* Buf!. */ #define ISC_BUFFER_VALID(b) ISC_MAGIC_VALID(b, ISC_BUFFER_MAGIC) +/*@}*/ /* * The following macros MUST be used only on valid buffers. It is the @@ -129,7 +134,8 @@ ISC_LANG_BEGINDECLS * another macro.) */ -/* +/*@{*/ +/*! * Fundamental buffer elements. (A through E in the introductory comment.) */ #define isc_buffer_base(b) ((void *)(b)->base) /*a*/ @@ -140,8 +146,10 @@ ISC_LANG_BEGINDECLS #define isc_buffer_used(b) \ ((void *)((unsigned char *)(b)->base + (b)->used)) /*d*/ #define isc_buffer_length(b) ((b)->length) /*e*/ +/*@}*/ -/* +/*@{*/ +/*! * Derived lengths. (Described in the introductory comment.) */ #define isc_buffer_usedlength(b) ((b)->used) /* d-a */ @@ -149,8 +157,9 @@ ISC_LANG_BEGINDECLS #define isc_buffer_remaininglength(b) ((b)->used - (b)->current) /* d-b */ #define isc_buffer_activelength(b) ((b)->active - (b)->current) /* c-b */ #define isc_buffer_availablelength(b) ((b)->length - (b)->used) /* e-d */ +/*@}*/ -/* +/*! * Note that the buffer structure is public. This is principally so buffer * operations can be implemented using macros. Applications are strongly * discouraged from directly manipulating the structure. @@ -159,14 +168,16 @@ ISC_LANG_BEGINDECLS struct isc_buffer { unsigned int magic; void *base; - /* The following integers are byte offsets from 'base'. */ + /*@{*/ + /*! The following integers are byte offsets from 'base'. */ unsigned int length; unsigned int used; unsigned int current; unsigned int active; - /* linkable */ + /*@}*/ + /*! linkable */ ISC_LINK(isc_buffer_t) link; - /* private internal elements */ + /*! private internal elements */ isc_mem_t *mctx; }; @@ -177,397 +188,468 @@ struct isc_buffer { isc_result_t isc_buffer_allocate(isc_mem_t *mctx, isc_buffer_t **dynbuffer, unsigned int length); -/* - * Allocate a dynamic linkable buffer which has "length" bytes in the +/*!< + * \brief Allocate a dynamic linkable buffer which has "length" bytes in the * data region. * * Requires: - * "mctx" is valid. + *\li "mctx" is valid. * - * "dynbuffer" is non-NULL, and "*dynbuffer" is NULL. + *\li "dynbuffer" is non-NULL, and "*dynbuffer" is NULL. * * Returns: - * ISC_R_SUCCESS - success - * ISC_R_NOMEMORY - no memory available + *\li ISC_R_SUCCESS - success + *\li ISC_R_NOMEMORY - no memory available * * Note: - * Changing the buffer's length field is not permitted. + *\li Changing the buffer's length field is not permitted. */ void isc_buffer_free(isc_buffer_t **dynbuffer); -/* - * Release resources allocated for a dynamic buffer. +/*!< + * \brief Release resources allocated for a dynamic buffer. * * Requires: - * "dynbuffer" is not NULL. + *\li "dynbuffer" is not NULL. * - * "*dynbuffer" is a valid dynamic buffer. + *\li "*dynbuffer" is a valid dynamic buffer. * * Ensures: - * "*dynbuffer" will be NULL on return, and all memory associated with + *\li "*dynbuffer" will be NULL on return, and all memory associated with * the dynamic buffer is returned to the memory context used in * isc_buffer_allocate(). */ void isc__buffer_init(isc_buffer_t *b, const void *base, unsigned int length); -/* - * Make 'b' refer to the 'length'-byte region starting at base. +/*!< + * \brief Make 'b' refer to the 'length'-byte region starting at base. + * + * Requires: + * + *\li 'length' > 0 + * + *\li 'base' is a pointer to a sequence of 'length' bytes. + * + */ + +void +isc__buffer_initnull(isc_buffer_t *b); +/*!< + *\brief Initialize a buffer 'b' with a null data and zero length/ + */ + +void +isc_buffer_reinit(isc_buffer_t *b, void *base, unsigned int length); +/*!< + * \brief Make 'b' refer to the 'length'-byte region starting at base. + * Any existing data will be copied. * * Requires: * - * 'length' > 0 + *\li 'length' > 0 AND length >= previous length * - * 'base' is a pointer to a sequence of 'length' bytes. + *\li 'base' is a pointer to a sequence of 'length' bytes. * */ void isc__buffer_invalidate(isc_buffer_t *b); -/* - * Make 'b' an invalid buffer. +/*!< + * \brief Make 'b' an invalid buffer. * * Requires: - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * * Ensures: - * If assertion checking is enabled, future attempts to use 'b' without + *\li If assertion checking is enabled, future attempts to use 'b' without * calling isc_buffer_init() on it will cause an assertion failure. */ void isc__buffer_region(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the region of 'b'. +/*!< + * \brief Make 'r' refer to the region of 'b'. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'r' points to a region structure. + *\li 'r' points to a region structure. */ void isc__buffer_usedregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the used region of 'b'. +/*!< + * \brief Make 'r' refer to the used region of 'b'. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'r' points to a region structure. + *\li 'r' points to a region structure. */ void isc__buffer_availableregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the available region of 'b'. +/*!< + * \brief Make 'r' refer to the available region of 'b'. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'r' points to a region structure. + *\li 'r' points to a region structure. */ void isc__buffer_add(isc_buffer_t *b, unsigned int n); -/* - * Increase the 'used' region of 'b' by 'n' bytes. +/*!< + * \brief Increase the 'used' region of 'b' by 'n' bytes. * * Requires: * - * 'b' is a valid buffer + *\li 'b' is a valid buffer * - * used + n <= length + *\li used + n <= length * */ void isc__buffer_subtract(isc_buffer_t *b, unsigned int n); -/* - * Decrease the 'used' region of 'b' by 'n' bytes. +/*!< + * \brief Decrease the 'used' region of 'b' by 'n' bytes. * * Requires: * - * 'b' is a valid buffer + *\li 'b' is a valid buffer * - * used >= n + *\li used >= n * */ void isc__buffer_clear(isc_buffer_t *b); -/* - * Make the used region empty. +/*!< + * \brief Make the used region empty. * * Requires: * - * 'b' is a valid buffer + *\li 'b' is a valid buffer * * Ensures: * - * used = 0 + *\li used = 0 * */ void isc__buffer_consumedregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the consumed region of 'b'. +/*!< + * \brief Make 'r' refer to the consumed region of 'b'. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'r' points to a region structure. + *\li 'r' points to a region structure. */ void isc__buffer_remainingregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the remaining region of 'b'. +/*!< + * \brief Make 'r' refer to the remaining region of 'b'. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'r' points to a region structure. + *\li 'r' points to a region structure. */ void isc__buffer_activeregion(isc_buffer_t *b, isc_region_t *r); -/* - * Make 'r' refer to the active region of 'b'. +/*!< + * \brief Make 'r' refer to the active region of 'b'. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'r' points to a region structure. + *\li 'r' points to a region structure. */ void isc__buffer_setactive(isc_buffer_t *b, unsigned int n); -/* - * Sets the end of the active region 'n' bytes after current. +/*!< + * \brief Sets the end of the active region 'n' bytes after current. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * current + n <= used + *\li current + n <= used */ void isc__buffer_first(isc_buffer_t *b); -/* - * Make the consumed region empty. +/*!< + * \brief Make the consumed region empty. * * Requires: * - * 'b' is a valid buffer + *\li 'b' is a valid buffer * * Ensures: * - * current == 0 + *\li current == 0 * */ void isc__buffer_forward(isc_buffer_t *b, unsigned int n); -/* - * Increase the 'consumed' region of 'b' by 'n' bytes. +/*!< + * \brief Increase the 'consumed' region of 'b' by 'n' bytes. * * Requires: * - * 'b' is a valid buffer + *\li 'b' is a valid buffer * - * current + n <= used + *\li current + n <= used * */ void isc__buffer_back(isc_buffer_t *b, unsigned int n); -/* - * Decrease the 'consumed' region of 'b' by 'n' bytes. +/*!< + * \brief Decrease the 'consumed' region of 'b' by 'n' bytes. * * Requires: * - * 'b' is a valid buffer + *\li 'b' is a valid buffer * - * n <= current + *\li n <= current * */ void isc_buffer_compact(isc_buffer_t *b); -/* - * Compact the used region by moving the remaining region so it occurs +/*!< + * \brief Compact the used region by moving the remaining region so it occurs * at the start of the buffer. The used region is shrunk by the size of * the consumed region, and the consumed region is then made empty. * * Requires: * - * 'b' is a valid buffer + *\li 'b' is a valid buffer * * Ensures: * - * current == 0 + *\li current == 0 * - * The size of the used region is now equal to the size of the remaining + *\li The size of the used region is now equal to the size of the remaining * region (as it was before the call). The contents of the used region * are those of the remaining region (as it was before the call). */ isc_uint8_t isc_buffer_getuint8(isc_buffer_t *b); -/* - * Read an unsigned 8-bit integer from 'b' and return it. +/*!< + * \brief Read an unsigned 8-bit integer from 'b' and return it. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * The length of the available region of 'b' is at least 1. + *\li The length of the available region of 'b' is at least 1. * * Ensures: * - * The current pointer in 'b' is advanced by 1. + *\li The current pointer in 'b' is advanced by 1. * * Returns: * - * A 8-bit unsigned integer. + *\li A 8-bit unsigned integer. */ void isc__buffer_putuint8(isc_buffer_t *b, isc_uint8_t val); -/* - * Store an unsigned 8-bit integer from 'val' into 'b'. +/*!< + * \brief Store an unsigned 8-bit integer from 'val' into 'b'. * * Requires: - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * The length of the unused region of 'b' is at least 1. + *\li The length of the unused region of 'b' is at least 1. * * Ensures: - * The used pointer in 'b' is advanced by 1. + *\li The used pointer in 'b' is advanced by 1. */ isc_uint16_t isc_buffer_getuint16(isc_buffer_t *b); -/* - * Read an unsigned 16-bit integer in network byte order from 'b', convert +/*!< + * \brief Read an unsigned 16-bit integer in network byte order from 'b', convert * it to host byte order, and return it. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * The length of the available region of 'b' is at least 2. + *\li The length of the available region of 'b' is at least 2. * * Ensures: * - * The current pointer in 'b' is advanced by 2. + *\li The current pointer in 'b' is advanced by 2. * * Returns: * - * A 16-bit unsigned integer. + *\li A 16-bit unsigned integer. */ void isc__buffer_putuint16(isc_buffer_t *b, isc_uint16_t val); -/* - * Store an unsigned 16-bit integer in host byte order from 'val' +/*!< + * \brief Store an unsigned 16-bit integer in host byte order from 'val' * into 'b' in network byte order. * * Requires: - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * The length of the unused region of 'b' is at least 2. + *\li The length of the unused region of 'b' is at least 2. * * Ensures: - * The used pointer in 'b' is advanced by 2. + *\li The used pointer in 'b' is advanced by 2. */ isc_uint32_t isc_buffer_getuint32(isc_buffer_t *b); -/* - * Read an unsigned 32-bit integer in network byte order from 'b', convert +/*!< + * \brief Read an unsigned 32-bit integer in network byte order from 'b', convert * it to host byte order, and return it. * * Requires: * - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * The length of the available region of 'b' is at least 4. + *\li The length of the available region of 'b' is at least 4. * * Ensures: * - * The current pointer in 'b' is advanced by 4. + *\li The current pointer in 'b' is advanced by 4. * * Returns: * - * A 32-bit unsigned integer. + *\li A 32-bit unsigned integer. */ void isc__buffer_putuint32(isc_buffer_t *b, isc_uint32_t val); -/* - * Store an unsigned 32-bit integer in host byte order from 'val' +/*!< + * \brief Store an unsigned 32-bit integer in host byte order from 'val' * into 'b' in network byte order. * * Requires: - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * The length of the unused region of 'b' is at least 4. + *\li The length of the unused region of 'b' is at least 4. * * Ensures: - * The used pointer in 'b' is advanced by 4. + *\li The used pointer in 'b' is advanced by 4. + */ + +isc_uint64_t +isc_buffer_getuint48(isc_buffer_t *b); +/*!< + * \brief Read an unsigned 48-bit integer in network byte order from 'b', + * convert it to host byte order, and return it. + * + * Requires: + * + *\li 'b' is a valid buffer. + * + *\li The length of the available region of 'b' is at least 6. + * + * Ensures: + * + *\li The current pointer in 'b' is advanced by 6. + * + * Returns: + * + *\li A 48-bit unsigned integer (stored in a 64-bit integer). + */ + +void +isc__buffer_putuint48(isc_buffer_t *b, isc_uint64_t val); +/*!< + * \brief Store an unsigned 48-bit integer in host byte order from 'val' + * into 'b' in network byte order. + * + * Requires: + *\li 'b' is a valid buffer. + * + *\li The length of the unused region of 'b' is at least 6. + * + * Ensures: + *\li The used pointer in 'b' is advanced by 6. + */ + +void +isc__buffer_putuint24(isc_buffer_t *b, isc_uint32_t val); +/*!< + * Store an unsigned 24-bit integer in host byte order from 'val' + * into 'b' in network byte order. + * + * Requires: + *\li 'b' is a valid buffer. + * + * The length of the unused region of 'b' is at least 3. + * + * Ensures: + *\li The used pointer in 'b' is advanced by 3. */ void isc__buffer_putmem(isc_buffer_t *b, const unsigned char *base, unsigned int length); -/* - * Copy 'length' bytes of memory at 'base' into 'b'. +/*!< + * \brief Copy 'length' bytes of memory at 'base' into 'b'. * * Requires: - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'base' points to 'length' bytes of valid memory. + *\li 'base' points to 'length' bytes of valid memory. * */ void isc__buffer_putstr(isc_buffer_t *b, const char *source); -/* - * Copy 'source' into 'b', not including terminating NUL. +/*!< + * \brief Copy 'source' into 'b', not including terminating NUL. * * Requires: - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'source' to be a valid NULL terminated string. + *\li 'source' to be a valid NULL terminated string. * - * strlen(source) <= isc_buffer_available(b) + *\li strlen(source) <= isc_buffer_available(b) */ isc_result_t isc_buffer_copyregion(isc_buffer_t *b, const isc_region_t *r); -/* - * Copy the contents of 'r' into 'b'. +/*!< + * \brief Copy the contents of 'r' into 'b'. * * Requires: - * 'b' is a valid buffer. + *\li 'b' is a valid buffer. * - * 'r' is a valid region. + *\li 'r' is a valid region. * * Returns: * - * ISC_R_SUCCESS - * ISC_R_NOSPACE The available region of 'b' is not + *\li ISC_R_SUCCESS + *\li ISC_R_NOSPACE The available region of 'b' is not * big enough. */ @@ -580,7 +662,7 @@ ISC_LANG_ENDDECLS * ones beginning with "isc__" */ -/* +/*! \note * XXXDCL Something more could be done with initializing buffers that * point to const data. For example, a new function, isc_buffer_initconst, * could be used, and a new boolean flag in the buffer structure could @@ -614,6 +696,8 @@ ISC_LANG_ENDDECLS (_b)->magic = ISC_BUFFER_MAGIC; \ } while (0) +#define ISC__BUFFER_INITNULL(_b) ISC__BUFFER_INIT(_b, NULL, 0) + #define ISC__BUFFER_INVALIDATE(_b) \ do { \ (_b)->magic = 0; \ @@ -741,6 +825,17 @@ ISC_LANG_ENDDECLS _cp[1] = (unsigned char)(_val2 & 0x00ffU); \ } while (0) +#define ISC__BUFFER_PUTUINT24(_b, _val) \ + do { \ + unsigned char *_cp; \ + isc_uint32_t _val2 = (_val); \ + _cp = isc_buffer_used(_b); \ + (_b)->used += 3; \ + _cp[0] = (unsigned char)((_val2 & 0xff0000U) >> 16); \ + _cp[1] = (unsigned char)((_val2 & 0xff00U) >> 8); \ + _cp[2] = (unsigned char)(_val2 & 0x00ffU); \ + } while (0) + #define ISC__BUFFER_PUTUINT32(_b, _val) \ do { \ unsigned char *_cp; \ @@ -755,6 +850,7 @@ ISC_LANG_ENDDECLS #if defined(ISC_BUFFER_USEINLINE) #define isc_buffer_init ISC__BUFFER_INIT +#define isc_buffer_initnull ISC__BUFFER_INITNULL #define isc_buffer_invalidate ISC__BUFFER_INVALIDATE #define isc_buffer_region ISC__BUFFER_REGION #define isc_buffer_usedregion ISC__BUFFER_USEDREGION @@ -773,9 +869,11 @@ ISC_LANG_ENDDECLS #define isc_buffer_putstr ISC__BUFFER_PUTSTR #define isc_buffer_putuint8 ISC__BUFFER_PUTUINT8 #define isc_buffer_putuint16 ISC__BUFFER_PUTUINT16 +#define isc_buffer_putuint24 ISC__BUFFER_PUTUINT24 #define isc_buffer_putuint32 ISC__BUFFER_PUTUINT32 #else #define isc_buffer_init isc__buffer_init +#define isc_buffer_initnull isc__buffer_initnull #define isc_buffer_invalidate isc__buffer_invalidate #define isc_buffer_region isc__buffer_region #define isc_buffer_usedregion isc__buffer_usedregion @@ -794,7 +892,13 @@ ISC_LANG_ENDDECLS #define isc_buffer_putstr isc__buffer_putstr #define isc_buffer_putuint8 isc__buffer_putuint8 #define isc_buffer_putuint16 isc__buffer_putuint16 +#define isc_buffer_putuint24 isc__buffer_putuint24 #define isc_buffer_putuint32 isc__buffer_putuint32 #endif +/* + * No inline method for this one (yet). + */ +#define isc_buffer_putuint48 isc__buffer_putuint48 + #endif /* ISC_BUFFER_H */ diff --git a/contrib/ntp/lib/isc/include/isc/bufferlist.h b/contrib/ntp/lib/isc/include/isc/bufferlist.h new file mode 100644 index 000000000..54e00c76f --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/bufferlist.h @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bufferlist.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_BUFFERLIST_H +#define ISC_BUFFERLIST_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/bufferlist.h + * + * + *\brief Buffer lists have no synchronization. Clients must ensure exclusive + * access. + * + * \li Reliability: + * No anticipated impact. + + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +unsigned int +isc_bufferlist_usedcount(isc_bufferlist_t *bl); +/*!< + * \brief Return the length of the sum of all used regions of all buffers in + * the buffer list 'bl' + * + * Requires: + * + *\li 'bl' is not NULL. + * + * Returns: + *\li sum of all used regions' lengths. + */ + +unsigned int +isc_bufferlist_availablecount(isc_bufferlist_t *bl); +/*!< + * \brief Return the length of the sum of all available regions of all buffers in + * the buffer list 'bl' + * + * Requires: + * + *\li 'bl' is not NULL. + * + * Returns: + *\li sum of all available regions' lengths. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_BUFFERLIST_H */ diff --git a/contrib/ntp/lib/isc/include/isc/commandline.h b/contrib/ntp/lib/isc/include/isc/commandline.h new file mode 100644 index 000000000..384640a45 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/commandline.h @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: commandline.h,v 1.16 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_COMMANDLINE_H +#define ISC_COMMANDLINE_H 1 + +/*! \file isc/commandline.h */ + +#include +#include +#include + +/*% Index into parent argv vector. */ +LIBISC_EXTERNAL_DATA extern int isc_commandline_index; +/*% Character checked for validity. */ +LIBISC_EXTERNAL_DATA extern int isc_commandline_option; +/*% Argument associated with option. */ +LIBISC_EXTERNAL_DATA extern char *isc_commandline_argument; +/*% For printing error messages. */ +LIBISC_EXTERNAL_DATA extern char *isc_commandline_progname; +/*% Print error message. */ +LIBISC_EXTERNAL_DATA extern isc_boolean_t isc_commandline_errprint; +/*% Reset getopt. */ +LIBISC_EXTERNAL_DATA extern isc_boolean_t isc_commandline_reset; + +ISC_LANG_BEGINDECLS + +/*% parse command line */ +int +isc_commandline_parse(int argc, char * const *argv, const char *options); + +ISC_LANG_ENDDECLS + +#endif /* ISC_COMMANDLINE_H */ diff --git a/contrib/ntp/lib/isc/include/isc/entropy.h b/contrib/ntp/lib/isc/include/isc/entropy.h new file mode 100644 index 000000000..d28f29a56 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/entropy.h @@ -0,0 +1,314 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: entropy.h,v 1.35 2009/10/19 02:37:08 marka Exp $ */ + +#ifndef ISC_ENTROPY_H +#define ISC_ENTROPY_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/entropy.h + * \brief The entropy API + * + * \li MP: + * The entropy object is locked internally. All callbacks into + * application-provided functions (for setup, gathering, and + * shutdown of sources) are guaranteed to be called with the + * entropy API lock held. This means these functions are + * not permitted to call back into the entropy API. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * A buffer, used as an entropy pool. + * + * \li Security: + * While this code is believed to implement good entropy gathering + * and distribution, it has not been reviewed by a cryptographic + * expert. + * Since the added entropy is only as good as the sources used, + * this module could hand out bad data and never know it. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include + +#include +#include + +/*@{*/ +/*% Entropy callback function. */ +typedef isc_result_t (*isc_entropystart_t)(isc_entropysource_t *source, + void *arg, isc_boolean_t blocking); +typedef isc_result_t (*isc_entropyget_t)(isc_entropysource_t *source, + void *arg, isc_boolean_t blocking); +typedef void (*isc_entropystop_t)(isc_entropysource_t *source, void *arg); +/*@}*/ + +/*** + *** Flags. + ***/ + +/*! + * \brief + * Extract only "good" data; return failure if there is not enough + * data available and there are no sources which we can poll to get + * data, or those sources are empty. + * + * + */ +#define ISC_ENTROPY_GOODONLY 0x00000001U +/*! + * \brief + * Extract as much good data as possible, but if there isn't enough + * at hand, return what is available. This flag only makes sense + * when used with _GOODONLY. + */ +#define ISC_ENTROPY_PARTIAL 0x00000002U +/*! + * \brief + * Block the task until data is available. This is contrary to the + * ISC task system, where tasks should never block. However, if + * this is a special purpose application where blocking a task is + * acceptable (say, an offline zone signer) this flag may be set. + * This flag only makes sense when used with _GOODONLY, and will + * block regardless of the setting for _PARTIAL. + */ +#define ISC_ENTROPY_BLOCKING 0x00000004U + +/*! + * \brief + * Estimate the amount of entropy contained in the sample pool. + * If this is not set, the source will be gathered and periodically + * mixed into the entropy pool, but no increment in contained entropy + * will be assumed. This flag only makes sense on sample sources. + */ +#define ISC_ENTROPYSOURCE_ESTIMATE 0x00000001U + +/* + * For use with isc_entropy_usebestsource(). + */ +/*! + * \brief + * Use the keyboard as the only entropy source. + */ +#define ISC_ENTROPY_KEYBOARDYES 1 +/*! + * \brief + * Never use the keyboard as an entropy source. + */ +#define ISC_ENTROPY_KEYBOARDNO 2 +/*! + * \brief + * Use the keyboard as an entropy source only if opening the + * random device fails. + */ +#define ISC_ENTROPY_KEYBOARDMAYBE 3 + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_entropy_create(isc_mem_t *mctx, isc_entropy_t **entp); +/*!< + * \brief Create a new entropy object. + */ + +void +isc_entropy_attach(isc_entropy_t *ent, isc_entropy_t **entp); +/*!< + * Attaches to an entropy object. + */ + +void +isc_entropy_detach(isc_entropy_t **entp); +/*!< + * \brief Detaches from an entropy object. + */ + +isc_result_t +isc_entropy_createfilesource(isc_entropy_t *ent, const char *fname); +/*!< + * \brief Create a new entropy source from a file. + * + * The file is assumed to contain good randomness, and will be mixed directly + * into the pool with every byte adding 8 bits of entropy. + * + * The file will be put into non-blocking mode, so it may be a device file, + * such as /dev/random. /dev/urandom should not be used here if it can + * be avoided, since it will always provide data even if it isn't good. + * We will make as much pseudorandom data as we need internally if our + * caller asks for it. + * + * If we hit end-of-file, we will stop reading from this source. Callers + * who require strong random data will get failure when our pool drains. + * The file will never be opened/read again once EOF is reached. + */ + +void +isc_entropy_destroysource(isc_entropysource_t **sourcep); +/*!< + * \brief Removes an entropy source from the entropy system. + */ + +isc_result_t +isc_entropy_createsamplesource(isc_entropy_t *ent, + isc_entropysource_t **sourcep); +/*!< + * \brief Create an entropy source that consists of samples. Each sample is + * added to the source via isc_entropy_addsamples(), below. + */ + +isc_result_t +isc_entropy_createcallbacksource(isc_entropy_t *ent, + isc_entropystart_t start, + isc_entropyget_t get, + isc_entropystop_t stop, + void *arg, + isc_entropysource_t **sourcep); +/*!< + * \brief Create an entropy source that is polled via a callback. + * + * This would + * be used when keyboard input is used, or a GUI input method. It can + * also be used to hook in any external entropy source. + * + * Samples are added via isc_entropy_addcallbacksample(), below. + * _addcallbacksample() is the only function which may be called from + * within an entropy API callback function. + */ + +void +isc_entropy_stopcallbacksources(isc_entropy_t *ent); +/*!< + * \brief Call the stop functions for callback sources that have had their + * start functions called. + */ + +/*@{*/ +isc_result_t +isc_entropy_addcallbacksample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra); +isc_result_t +isc_entropy_addsample(isc_entropysource_t *source, isc_uint32_t sample, + isc_uint32_t extra); +/*!< + * \brief Add a sample to the sample source. + * + * The sample MUST be a timestamp + * that increases over time, with the exception of wrap-around for + * extremely high resolution timers which will quickly wrap-around + * a 32-bit integer. + * + * The "extra" parameter is used only to add a bit more unpredictable + * data. It is not used other than included in the hash of samples. + * + * When in an entropy API callback function, _addcallbacksource() must be + * used. At all other times, _addsample() must be used. + */ +/*@}*/ + +isc_result_t +isc_entropy_getdata(isc_entropy_t *ent, void *data, unsigned int length, + unsigned int *returned, unsigned int flags); +/*!< + * \brief Extract data from the entropy pool. This may load the pool from various + * sources. + * + * Do this by stiring the pool and returning a part of hash as randomness. + * Note that no secrets are given away here since parts of the hash are + * xored together before returned. + * + * Honor the request from the caller to only return good data, any data, + * etc. + */ + +void +isc_entropy_putdata(isc_entropy_t *ent, void *data, unsigned int length, + isc_uint32_t entropy); +/*!< + * \brief Add "length" bytes in "data" to the entropy pool, incrementing the + * pool's entropy count by "entropy." + * + * These bytes will prime the pseudorandom portion even if no entropy is + * actually added. + */ + +void +isc_entropy_stats(isc_entropy_t *ent, FILE *out); +/*!< + * \brief Dump some (trivial) stats to the stdio stream "out". + */ + +unsigned int +isc_entropy_status(isc_entropy_t *end); +/* + * Returns the number of bits the pool currently contains. This is just + * an estimate. + */ + +isc_result_t +isc_entropy_usebestsource(isc_entropy_t *ectx, isc_entropysource_t **source, + const char *randomfile, int use_keyboard); +/*!< + * \brief Use whatever source of entropy is best. + * + * Notes: + *\li If "randomfile" is not NULL, open it with + * isc_entropy_createfilesource(). + * + *\li If "randomfile" is NULL and the system's random device was detected + * when the program was configured and built, open that device with + * isc_entropy_createfilesource(). + * + *\li If "use_keyboard" is #ISC_ENTROPY_KEYBOARDYES, then always open + * the keyboard as an entropy source (possibly in addition to + * "randomfile" or the random device). + * + *\li If "use_keyboard" is #ISC_ENTROPY_KEYBOARDMAYBE, open the keyboard only + * if opening the random file/device fails. A message will be + * printed describing the need for keyboard input. + * + *\li If "use_keyboard" is #ISC_ENTROPY_KEYBOARDNO, the keyboard will + * never be opened. + * + * Returns: + *\li #ISC_R_SUCCESS if at least one source of entropy could be started. + * + *\li #ISC_R_NOENTROPY if use_keyboard is #ISC_ENTROPY_KEYBOARDNO and + * there is no random device pathname compiled into the program. + * + *\li A return code from isc_entropy_createfilesource() or + * isc_entropy_createcallbacksource(). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_ENTROPY_H */ diff --git a/contrib/ntp/include/isc/error.h b/contrib/ntp/lib/isc/include/isc/error.h similarity index 52% rename from contrib/ntp/include/isc/error.h rename to contrib/ntp/lib/isc/include/isc/error.h index 1dc07748c..e0cdfa83e 100644 --- a/contrib/ntp/include/isc/error.h +++ b/contrib/ntp/lib/isc/include/isc/error.h @@ -1,48 +1,56 @@ /* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: error.h,v 1.13 2001/01/09 21:56:51 bwelling Exp $ */ +/* $Id: error.h,v 1.22 2009/09/29 23:48:04 tbox Exp $ */ #ifndef ISC_ERROR_H #define ISC_ERROR_H 1 +/*! \file isc/error.h */ + #include #include #include +#include ISC_LANG_BEGINDECLS typedef void (*isc_errorcallback_t)(const char *, int, const char *, va_list); +/*% set unexpected error */ void isc_error_setunexpected(isc_errorcallback_t); +/*% set fatal error */ void isc_error_setfatal(isc_errorcallback_t); +/*% unexpected error */ void isc_error_unexpected(const char *, int, const char *, ...) ISC_FORMAT_PRINTF(3, 4); -void +/*% fatal error */ +ISC_PLATFORM_NORETURN_PRE void isc_error_fatal(const char *, int, const char *, ...) - ISC_FORMAT_PRINTF(3, 4); +ISC_FORMAT_PRINTF(3, 4) ISC_PLATFORM_NORETURN_POST; +/*% runtimecheck error */ void isc_error_runtimecheck(const char *, int, const char *); diff --git a/contrib/ntp/lib/isc/include/isc/event.h b/contrib/ntp/lib/isc/include/isc/event.h new file mode 100644 index 000000000..68fabb2fc --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/event.h @@ -0,0 +1,121 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: event.h,v 1.34 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_EVENT_H +#define ISC_EVENT_H 1 + +/*! \file isc/event.h */ + +#include +#include + +/***** + ***** Events. + *****/ + +typedef void (*isc_eventdestructor_t)(isc_event_t *); + +#define ISC_EVENT_COMMON(ltype) \ + size_t ev_size; \ + unsigned int ev_attributes; \ + void * ev_tag; \ + isc_eventtype_t ev_type; \ + isc_taskaction_t ev_action; \ + void * ev_arg; \ + void * ev_sender; \ + isc_eventdestructor_t ev_destroy; \ + void * ev_destroy_arg; \ + ISC_LINK(ltype) ev_link + +/*% + * Attributes matching a mask of 0x000000ff are reserved for the task library's + * definition. Attributes of 0xffffff00 may be used by the application + * or non-ISC libraries. + */ +#define ISC_EVENTATTR_NOPURGE 0x00000001 + +/*% + * The ISC_EVENTATTR_CANCELED attribute is intended to indicate + * that an event is delivered as a result of a canceled operation + * rather than successful completion, by mutual agreement + * between the sender and receiver. It is not set or used by + * the task system. + */ +#define ISC_EVENTATTR_CANCELED 0x00000002 + +#define ISC_EVENT_INIT(event, sz, at, ta, ty, ac, ar, sn, df, da) \ +do { \ + (event)->ev_size = (sz); \ + (event)->ev_attributes = (at); \ + (event)->ev_tag = (ta); \ + (event)->ev_type = (ty); \ + (event)->ev_action = (ac); \ + (event)->ev_arg = (ar); \ + (event)->ev_sender = (sn); \ + (event)->ev_destroy = (df); \ + (event)->ev_destroy_arg = (da); \ + ISC_LINK_INIT((event), ev_link); \ +} while (0) + +/*% + * This structure is public because "subclassing" it may be useful when + * defining new event types. + */ +struct isc_event { + ISC_EVENT_COMMON(struct isc_event); +}; + +#define ISC_EVENTTYPE_FIRSTEVENT 0x00000000 +#define ISC_EVENTTYPE_LASTEVENT 0xffffffff + +#define ISC_EVENT_PTR(p) ((isc_event_t **)(void *)(p)) + +ISC_LANG_BEGINDECLS + +isc_event_t * +isc_event_allocate(isc_mem_t *mctx, void *sender, isc_eventtype_t type, + isc_taskaction_t action, const void *arg, size_t size); +/*%< + * Allocate an event structure. + * + * Allocate and initialize in a structure with initial elements + * defined by: + * + * \code + * struct { + * ISC_EVENT_COMMON(struct isc_event); + * ... + * }; + * \endcode + * + * Requires: + *\li 'size' >= sizeof(struct isc_event) + *\li 'action' to be non NULL + * + * Returns: + *\li a pointer to a initialized structure of the requested size. + *\li NULL if unable to allocate memory. + */ + +void +isc_event_free(isc_event_t **); + +ISC_LANG_ENDDECLS + +#endif /* ISC_EVENT_H */ diff --git a/contrib/ntp/lib/isc/include/isc/eventclass.h b/contrib/ntp/lib/isc/include/isc/eventclass.h new file mode 100644 index 000000000..9e6c145ac --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/eventclass.h @@ -0,0 +1,53 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: eventclass.h,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_EVENTCLASS_H +#define ISC_EVENTCLASS_H 1 + +/*! \file isc/eventclass.h + ***** Registry of Predefined Event Type Classes + *****/ + +/*% + * An event class is an unsigned 16 bit number. Each class may contain up + * to 65536 events. An event type is formed by adding the event number + * within the class to the class number. + * + */ + +#define ISC_EVENTCLASS(eclass) ((eclass) << 16) + +/*@{*/ +/*! + * Classes < 1024 are reserved for ISC use. + * Event classes >= 1024 and <= 65535 are reserved for application use. + */ + +#define ISC_EVENTCLASS_TASK ISC_EVENTCLASS(0) +#define ISC_EVENTCLASS_TIMER ISC_EVENTCLASS(1) +#define ISC_EVENTCLASS_SOCKET ISC_EVENTCLASS(2) +#define ISC_EVENTCLASS_FILE ISC_EVENTCLASS(3) +#define ISC_EVENTCLASS_DNS ISC_EVENTCLASS(4) +#define ISC_EVENTCLASS_APP ISC_EVENTCLASS(5) +#define ISC_EVENTCLASS_OMAPI ISC_EVENTCLASS(6) +#define ISC_EVENTCLASS_RATELIMITER ISC_EVENTCLASS(7) +#define ISC_EVENTCLASS_ISCCC ISC_EVENTCLASS(8) +/*@}*/ + +#endif /* ISC_EVENTCLASS_H */ diff --git a/contrib/ntp/lib/isc/include/isc/file.h b/contrib/ntp/lib/isc/include/isc/file.h new file mode 100644 index 000000000..5db506a38 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/file.h @@ -0,0 +1,304 @@ +/* + * Copyright (C) 2004-2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_FILE_H +#define ISC_FILE_H 1 + +/*! \file isc/file.h */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_file_settime(const char *file, isc_time_t *itime); + +isc_result_t +isc_file_getmodtime(const char *file, isc_time_t *itime); +/*!< + * \brief Get the time of last modification of a file. + * + * Notes: + *\li The time that is set is relative to the (OS-specific) epoch, as are + * all isc_time_t structures. + * + * Requires: + *\li file != NULL. + *\li time != NULL. + * + * Ensures: + *\li If the file could not be accessed, 'time' is unchanged. + * + * Returns: + *\li #ISC_R_SUCCESS + * Success. + *\li #ISC_R_NOTFOUND + * No such file exists. + *\li #ISC_R_INVALIDFILE + * The path specified was not usable by the operating system. + *\li #ISC_R_NOPERM + * The file's metainformation could not be retrieved because + * permission was denied to some part of the file's path. + *\li #ISC_R_EIO + * Hardware error interacting with the filesystem. + *\li #ISC_R_UNEXPECTED + * Something totally unexpected happened. + * + */ + +isc_result_t +isc_file_mktemplate(const char *path, char *buf, size_t buflen); +/*!< + * \brief Generate a template string suitable for use with isc_file_openunique(). + * + * Notes: + *\li This function is intended to make creating temporary files + * portable between different operating systems. + * + *\li The path is prepended to an implementation-defined string and + * placed into buf. The string has no path characters in it, + * and its maximum length is 14 characters plus a NUL. Thus + * buflen should be at least strlen(path) + 15 characters or + * an error will be returned. + * + * Requires: + *\li buf != NULL. + * + * Ensures: + *\li If result == #ISC_R_SUCCESS: + * buf contains a string suitable for use as the template argument + * to isc_file_openunique(). + * + *\li If result != #ISC_R_SUCCESS: + * buf is unchanged. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOSPACE buflen indicates buf is too small for the catenation + * of the path with the internal template string. + */ + + +isc_result_t +isc_file_openunique(char *templet, FILE **fp); +isc_result_t +isc_file_openuniqueprivate(char *templet, FILE **fp); +isc_result_t +isc_file_openuniquemode(char *templet, int mode, FILE **fp); +/*!< + * \brief Create and open a file with a unique name based on 'templet'. + * + * Notes: + *\li 'template' is a reserved work in C++. If you want to complain + * about the spelling of 'templet', first look it up in the + * Merriam-Webster English dictionary. (http://www.m-w.com/) + * + *\li This function works by using the template to generate file names. + * The template must be a writable string, as it is modified in place. + * Trailing X characters in the file name (full file name on Unix, + * basename on Win32 -- eg, tmp-XXXXXX vs XXXXXX.tmp, respectively) + * are replaced with ASCII characters until a non-existent filename + * is found. If the template does not include pathname information, + * the files in the working directory of the program are searched. + * + *\li isc_file_mktemplate is a good, portable way to get a template. + * + * Requires: + *\li 'fp' is non-NULL and '*fp' is NULL. + * + *\li 'template' is non-NULL, and of a form suitable for use by + * the system as described above. + * + * Ensures: + *\li If result is #ISC_R_SUCCESS: + * *fp points to an stream opening in stdio's "w+" mode. + * + *\li If result is not #ISC_R_SUCCESS: + * *fp is NULL. + * + * No file is open. Even if one was created (but unable + * to be reopened as a stdio FILE pointer) then it has been + * removed. + * + *\li This function does *not* ensure that the template string has not been + * modified, even if the operation was unsuccessful. + * + * Returns: + *\li #ISC_R_SUCCESS + * Success. + *\li #ISC_R_EXISTS + * No file with a unique name could be created based on the + * template. + *\li #ISC_R_INVALIDFILE + * The path specified was not usable by the operating system. + *\li #ISC_R_NOPERM + * The file could not be created because permission was denied + * to some part of the file's path. + *\li #ISC_R_IOERROR + * Hardware error interacting with the filesystem. + *\li #ISC_R_UNEXPECTED + * Something totally unexpected happened. + */ + +isc_result_t +isc_file_remove(const char *filename); +/*!< + * \brief Remove the file named by 'filename'. + */ + +isc_result_t +isc_file_rename(const char *oldname, const char *newname); +/*!< + * \brief Rename the file 'oldname' to 'newname'. + */ + +isc_boolean_t +isc_file_exists(const char *pathname); +/*!< + * \brief Return #ISC_TRUE if the calling process can tell that the given file exists. + * Will not return true if the calling process has insufficient privileges + * to search the entire path. + */ + +isc_boolean_t +isc_file_isabsolute(const char *filename); +/*!< + * \brief Return #ISC_TRUE if the given file name is absolute. + */ + +isc_result_t +isc_file_isplainfile(const char *name); +/*!< + * \brief Check that the file is a plain file + * + * Returns: + *\li #ISC_R_SUCCESS + * Success. The file is a plain file. + *\li #ISC_R_INVALIDFILE + * The path specified was not usable by the operating system. + *\li #ISC_R_FILENOTFOUND + * The file does not exist. This return code comes from + * errno=ENOENT when stat returns -1. This code is mentioned + * here, because in logconf.c, it is the one rcode that is + * permitted in addition to ISC_R_SUCCESS. This is done since + * the next call in logconf.c is to isc_stdio_open(), which + * will create the file if it can. + *\li #other ISC_R_* errors translated from errno + * These occur when stat returns -1 and an errno. + */ + +isc_boolean_t +isc_file_iscurrentdir(const char *filename); +/*!< + * \brief Return #ISC_TRUE if the given file name is the current directory ("."). + */ + +isc_boolean_t +isc_file_ischdiridempotent(const char *filename); +/*%< + * Return #ISC_TRUE if calling chdir(filename) multiple times will give + * the same result as calling it once. + */ + +const char * +isc_file_basename(const char *filename); +/*%< + * Return the final component of the path in the file name. + */ + +isc_result_t +isc_file_progname(const char *filename, char *buf, size_t buflen); +/*!< + * \brief Given an operating system specific file name "filename" + * referring to a program, return the canonical program name. + * + * + * Any directory prefix or executable file name extension (if + * used on the OS in case) is stripped. On systems where program + * names are case insensitive, the name is canonicalized to all + * lower case. The name is written to 'buf', an array of 'buflen' + * chars, and null terminated. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOSPACE The name did not fit in 'buf'. + */ + +isc_result_t +isc_file_template(const char *path, const char *templet, char *buf, + size_t buflen); +/*%< + * Create an OS specific template using 'path' to define the directory + * 'templet' to describe the filename and store the result in 'buf' + * such that path can be renamed to buf atomically. + */ + +isc_result_t +isc_file_renameunique(const char *file, char *templet); +/*%< + * Rename 'file' using 'templet' as a template for the new file name. + */ + +isc_result_t +isc_file_absolutepath(const char *filename, char *path, size_t pathlen); +/*%< + * Given a file name, return the fully qualified path to the file. + */ + +/* + * XXX We should also have a isc_file_writeeopen() function + * for safely open a file in a publicly writable directory + * (see write_open() in BIND 8's ns_config.c). + */ + +isc_result_t +isc_file_truncate(const char *filename, isc_offset_t size); +/*%< + * Truncate/extend the file specified to 'size' bytes. + */ + +isc_result_t +isc_file_safecreate(const char *filename, FILE **fp); +/*%< + * Open 'filename' for writing, truncating if necessary. Ensure that + * if it existed it was a normal file. If creating the file, ensure + * that only the owner can read/write it. + */ + +isc_result_t +isc_file_splitpath(isc_mem_t *mctx, char *path, + char **dirname, char **basename); +/*%< + * Split a path into dirname and basename. If 'path' contains no slash + * (or, on windows, backslash), then '*dirname' is set to ".". + * + * Allocates memory for '*dirname', which can be freed with isc_mem_free(). + * + * Returns: + * - ISC_R_SUCCESS on success + * - ISC_R_INVALIDFILE if 'path' is empty or ends with '/' + * - ISC_R_NOMEMORY if unable to allocate memory + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_FILE_H */ diff --git a/contrib/ntp/lib/isc/include/isc/formatcheck.h b/contrib/ntp/lib/isc/include/isc/formatcheck.h new file mode 100644 index 000000000..51ce3cac2 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/formatcheck.h @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: formatcheck.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_FORMATCHECK_H +#define ISC_FORMATCHECK_H 1 + +/*! \file isc/formatcheck.h */ + +/*% + * ISC_FORMAT_PRINTF(). + * + * \li fmt is the location of the format string parameter. + * \li args is the location of the first argument (or 0 for no argument checking). + * + * Note: + * \li The first parameter is 1, not 0. + */ +#ifdef __GNUC__ +#define ISC_FORMAT_PRINTF(fmt, args) __attribute__((__format__(__printf__, fmt, args))) +#else +#define ISC_FORMAT_PRINTF(fmt, args) +#endif + +#endif /* ISC_FORMATCHECK_H */ diff --git a/contrib/ntp/lib/isc/include/isc/fsaccess.h b/contrib/ntp/lib/isc/include/isc/fsaccess.h new file mode 100644 index 000000000..7962bbe21 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/fsaccess.h @@ -0,0 +1,178 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: fsaccess.h,v 1.16 2009/01/17 23:47:43 tbox Exp $ */ + +#ifndef ISC_FSACCESS_H +#define ISC_FSACCESS_H 1 + +/*! \file isc/fsaccess.h + * \brief The ISC filesystem access module encapsulates the setting of file + * and directory access permissions into one API that is meant to be + * portable to multiple operating systems. + * + * The two primary operating system flavors that are initially accommodated + * are POSIX and Windows NT 4.0 and later. The Windows NT access model is + * considerable more flexible than POSIX's model (as much as I am loathe to + * admit it), and so the ISC API has a higher degree of complexity than would + * be needed to simply address POSIX's needs. + * + * The full breadth of NT's flexibility is not available either, for the + * present time. Much of it is to provide compatibility with what Unix + * programmers are expecting. This is also due to not yet really needing all + * of the functionality of an NT system (or, for that matter, a POSIX system) + * in BIND9, and so resolving how to handle the various incompatibilities has + * been a purely theoretical exercise with no operational experience to + * indicate how flawed the thinking may be. + * + * Some of the more notable dumbing down of NT for this API includes: + * + *\li Each of FILE_READ_DATA and FILE_READ_EA are set with #ISC_FSACCESS_READ. + * + * \li All of FILE_WRITE_DATA, FILE_WRITE_EA and FILE_APPEND_DATA are + * set with #ISC_FSACCESS_WRITE. FILE_WRITE_ATTRIBUTES is not set + * so as to be consistent with Unix, where only the owner of the file + * or the superuser can change the attributes/mode of a file. + * + * \li Both of FILE_ADD_FILE and FILE_ADD_SUBDIRECTORY are set with + * #ISC_FSACCESS_CREATECHILD. This is similar to setting the WRITE + * permission on a Unix directory. + * + * \li SYNCHRONIZE is always set for files and directories, unless someone + * can give me a reason why this is a bad idea. + * + * \li READ_CONTROL and FILE_READ_ATTRIBUTES are always set; this is + * consistent with Unix, where any file or directory can be stat()'d + * unless the directory path disallows complete access somewhere along + * the way. + * + * \li WRITE_DAC is only set for the owner. This too is consistent with + * Unix, and is tighter security than allowing anyone else to be + * able to set permissions. + * + * \li DELETE is only set for the owner. On Unix the ability to delete + * a file is controlled by the directory permissions, but it isn't + * currently clear to me what happens on NT if the directory has + * FILE_DELETE_CHILD set but a file within it does not have DELETE + * set. Always setting DELETE on the file/directory for the owner + * gives maximum flexibility to the owner without exposing the + * file to deletion by others. + * + * \li WRITE_OWNER is never set. This too is consistent with Unix, + * and is also tighter security than allowing anyone to change the + * ownership of the file apart from the superu..ahem, Administrator. + * + * \li Inheritance is set to NO_INHERITANCE. + * + * Unix's dumbing down includes: + * + * \li The sticky bit cannot be set. + * + * \li setuid and setgid cannot be set. + * + * \li Only regular files and directories can be set. + * + * The rest of this comment discusses a few of the incompatibilities + * between the two systems that need more thought if this API is to + * be extended to accommodate them. + * + * The Windows standard access right "DELETE" doesn't have a direct + * equivalent in the Unix world, so it isn't clear what should be done + * with it. + * + * The Unix sticky bit is not supported. While NT does have a concept + * of allowing users to create files in a directory but not delete or + * rename them, it does not have a concept of allowing them to be deleted + * if they are owned by the user trying to delete/rename. While it is + * probable that something could be cobbled together in NT 5 with inheritance, + * it can't really be done in NT 4 as a single property that you could + * set on a directory. You'd need to coordinate something with file creation + * so that every file created had DELETE set for the owner but noone else. + * + * On Unix systems, setting #ISC_FSACCESS_LISTDIRECTORY sets READ. + * ... setting either #ISC_FSACCESS_CREATECHILD or #ISC_FSACCESS_DELETECHILD + * sets WRITE. + * ... setting #ISC_FSACCESS_ACCESSCHILD sets EXECUTE. + * + * On NT systems, setting #ISC_FSACCESS_LISTDIRECTORY sets FILE_LIST_DIRECTORY. + * ... setting #ISC_FSACCESS_CREATECHILD sets FILE_CREATE_CHILD independently. + * ... setting #ISC_FSACCESS_DELETECHILD sets FILE_DELETE_CHILD independently. + * ... setting #ISC_FSACCESS_ACCESSCHILD sets FILE_TRAVERSE. + * + * Unresolved: XXXDCL + * \li What NT access right controls the ability to rename a file? + * \li How does DELETE work? If a directory has FILE_DELETE_CHILD but a + * file or directory within it does not have DELETE, is that file + * or directory deletable? + * \li To implement isc_fsaccess_get(), mapping an existing Unix permission + * mode_t back to an isc_fsaccess_t is pretty trivial; however, mapping + * an NT DACL could be impossible to do in a responsible way. + * \li Similarly, trying to implement the functionality of being able to + * say "add group writability to whatever permissions already exist" + * could be tricky on NT because of the order-of-entry issue combined + * with possibly having one or more matching ACEs already explicitly + * granting or denying access. Because this functionality is + * not yet needed by the ISC, no code has been written to try to + * solve this problem. + */ + +#include +#include + +/* + * Trustees. + */ +#define ISC_FSACCESS_OWNER 0x1 /*%< User account. */ +#define ISC_FSACCESS_GROUP 0x2 /*%< Primary group owner. */ +#define ISC_FSACCESS_OTHER 0x4 /*%< Not the owner or the group owner. */ +#define ISC_FSACCESS_WORLD 0x7 /*%< User, Group, Other. */ + +/* + * Types of permission. + */ +#define ISC_FSACCESS_READ 0x00000001 /*%< File only. */ +#define ISC_FSACCESS_WRITE 0x00000002 /*%< File only. */ +#define ISC_FSACCESS_EXECUTE 0x00000004 /*%< File only. */ +#define ISC_FSACCESS_CREATECHILD 0x00000008 /*%< Dir only. */ +#define ISC_FSACCESS_DELETECHILD 0x00000010 /*%< Dir only. */ +#define ISC_FSACCESS_LISTDIRECTORY 0x00000020 /*%< Dir only. */ +#define ISC_FSACCESS_ACCESSCHILD 0x00000040 /*%< Dir only. */ + +/*% + * Adding any permission bits beyond 0x200 would mean typedef'ing + * isc_fsaccess_t as isc_uint64_t, and redefining this value to + * reflect the new range of permission types, Probably to 21 for + * maximum flexibility. The number of bits has to accommodate all of + * the permission types, and three full sets of them have to fit + * within an isc_fsaccess_t. + */ +#define ISC__FSACCESS_PERMISSIONBITS 10 + +ISC_LANG_BEGINDECLS + +void +isc_fsaccess_add(int trustee, int permission, isc_fsaccess_t *access); + +void +isc_fsaccess_remove(int trustee, int permission, isc_fsaccess_t *access); + +isc_result_t +isc_fsaccess_set(const char *path, isc_fsaccess_t access); + +ISC_LANG_ENDDECLS + +#endif /* ISC_FSACCESS_H */ diff --git a/contrib/ntp/lib/isc/include/isc/hash.h b/contrib/ntp/lib/isc/include/isc/hash.h new file mode 100644 index 000000000..ca04b4e43 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/hash.h @@ -0,0 +1,185 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hash.h,v 1.12 2009/01/17 23:47:43 tbox Exp $ */ + +#ifndef ISC_HASH_H +#define ISC_HASH_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/hash.h + * + * \brief The hash API + * provides an unpredictable hash value for variable length data. + * A hash object contains a random vector (which is hidden from clients + * of this API) to make the actual hash value unpredictable. + * + * The algorithm used in the API guarantees the probability of hash + * collision; in the current implementation, as long as the values stored + * in the random vector are unpredictable, the probability of hash + * collision between arbitrary two different values is at most 1/2^16. + * + * Although the API is generic about the hash keys, it mainly expects + * DNS names (and sometimes IPv4/v6 addresses) as inputs. It has an + * upper limit of the input length, and may run slow to calculate the + * hash values for large inputs. + * + * This API is designed to be general so that it can provide multiple + * different hash contexts that have different random vectors. However, + * it should be typical to have a single context for an entire system. + * To support such cases, the API also provides a single-context mode. + * + * \li MP: + * The hash object is almost read-only. Once the internal random vector + * is initialized, no write operation will occur, and there will be no + * need to lock the object to calculate actual hash values. + * + * \li Reliability: + * In some cases this module uses low-level data copy to initialize the + * random vector. Errors in this part are likely to crash the server or + * corrupt memory. + * + * \li Resources: + * A buffer, used as a random vector for calculating hash values. + * + * \li Security: + * This module intends to provide unpredictable hash values in + * adversarial environments in order to avoid denial of service attacks + * to hash buckets. + * Its unpredictability relies on the quality of entropy to build the + * random vector. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include + +/*** + *** Functions + ***/ +ISC_LANG_BEGINDECLS + +isc_result_t +isc_hash_ctxcreate(isc_mem_t *mctx, isc_entropy_t *entropy, unsigned int limit, + isc_hash_t **hctx); +isc_result_t +isc_hash_create(isc_mem_t *mctx, isc_entropy_t *entropy, size_t limit); +/*!< + * \brief Create a new hash object. + * + * isc_hash_ctxcreate() creates a different object. + * + * isc_hash_create() creates a module-internal object to support the + * single-context mode. It should be called only once. + * + * 'entropy' must be NULL or a valid entropy object. If 'entropy' is NULL, + * pseudo random values will be used to build the random vector, which may + * weaken security. + * + * 'limit' specifies the maximum number of hash keys. If it is too large, + * these functions may fail. + */ + +void +isc_hash_ctxattach(isc_hash_t *hctx, isc_hash_t **hctxp); +/*!< + * \brief Attach to a hash object. + * + * This function is only necessary for the multiple-context mode. + */ + +void +isc_hash_ctxdetach(isc_hash_t **hctxp); +/*!< + * \brief Detach from a hash object. + * + * This function is for the multiple-context mode, and takes a valid + * hash object as an argument. + */ + +void +isc_hash_destroy(void); +/*!< + * \brief This function is for the single-context mode, and is expected to be used + * as a counterpart of isc_hash_create(). + * + * A valid module-internal hash object must have been created, and this + * function should be called only once. + */ + +/*@{*/ +void +isc_hash_ctxinit(isc_hash_t *hctx); +void +isc_hash_init(void); +/*!< + * \brief Initialize a hash object. + * + * It fills in the random vector with a proper + * source of entropy, which is typically from the entropy object specified + * at the creation. Thus, it is desirable to call these functions after + * initializing the entropy object with some good entropy sources. + * + * These functions should be called before the first hash calculation. + * + * isc_hash_ctxinit() is for the multiple-context mode, and takes a valid hash + * object as an argument. + * + * isc_hash_init() is for the single-context mode. A valid module-internal + * hash object must have been created, and this function should be called only + * once. + */ +/*@}*/ + +/*@{*/ +unsigned int +isc_hash_ctxcalc(isc_hash_t *hctx, const unsigned char *key, + unsigned int keylen, isc_boolean_t case_sensitive); +unsigned int +isc_hash_calc(const unsigned char *key, unsigned int keylen, + isc_boolean_t case_sensitive); +/*!< + * \brief Calculate a hash value. + * + * isc_hash_ctxinit() is for the multiple-context mode, and takes a valid hash + * object as an argument. + * + * isc_hash_init() is for the single-context mode. A valid module-internal + * hash object must have been created. + * + * 'key' is the hash key, which is a variable length buffer. + * + * 'keylen' specifies the key length, which must not be larger than the limit + * specified for the corresponding hash object. + * + * 'case_sensitive' specifies whether the hash key should be treated as + * case_sensitive values. It should typically be ISC_FALSE if the hash key + * is a DNS name. + */ +/*@}*/ + +ISC_LANG_ENDDECLS + +#endif /* ISC_HASH_H */ diff --git a/contrib/ntp/lib/isc/include/isc/heap.h b/contrib/ntp/lib/isc/include/isc/heap.h new file mode 100644 index 000000000..77bf07c34 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/heap.h @@ -0,0 +1,170 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: heap.h,v 1.26 2009/01/17 23:47:43 tbox Exp $ */ + +#ifndef ISC_HEAP_H +#define ISC_HEAP_H 1 + +/*! \file isc/heap.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*% + * The comparison function returns ISC_TRUE if the first argument has + * higher priority than the second argument, and ISC_FALSE otherwise. + */ +typedef isc_boolean_t (*isc_heapcompare_t)(void *, void *); + +/*% + * The index function allows the client of the heap to receive a callback + * when an item's index number changes. This allows it to maintain + * sync with its external state, but still delete itself, since deletions + * from the heap require the index be provided. + */ +typedef void (*isc_heapindex_t)(void *, unsigned int); + +/*% + * The heapaction function is used when iterating over the heap. + * + * NOTE: The heap structure CANNOT BE MODIFIED during the call to + * isc_heap_foreach(). + */ +typedef void (*isc_heapaction_t)(void *, void *); + +typedef struct isc_heap isc_heap_t; + +isc_result_t +isc_heap_create(isc_mem_t *mctx, isc_heapcompare_t compare, + isc_heapindex_t index, unsigned int size_increment, + isc_heap_t **heapp); +/*!< + * \brief Create a new heap. The heap is implemented using a space-efficient + * storage method. When the heap elements are deleted space is not freed + * but will be reused when new elements are inserted. + * + * Requires: + *\li "mctx" is valid. + *\li "compare" is a function which takes two void * arguments and + * returns ISC_TRUE if the first argument has a higher priority than + * the second, and ISC_FALSE otherwise. + *\li "index" is a function which takes a void *, and an unsigned int + * argument. This function will be called whenever an element's + * index value changes, so it may continue to delete itself from the + * heap. This option may be NULL if this functionality is unneeded. + *\li "size_increment" is a hint about how large the heap should grow + * when resizing is needed. If this is 0, a default size will be + * used, which is currently 1024, allowing space for an additional 1024 + * heap elements to be inserted before adding more space. + *\li "heapp" is not NULL, and "*heap" is NULL. + * + * Returns: + *\li ISC_R_SUCCESS - success + *\li ISC_R_NOMEMORY - insufficient memory + */ + +void +isc_heap_destroy(isc_heap_t **heapp); +/*!< + * \brief Destroys a heap. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + */ + +isc_result_t +isc_heap_insert(isc_heap_t *heap, void *elt); +/*!< + * \brief Inserts a new element into a heap. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + */ + +void +isc_heap_delete(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Deletes an element from a heap, by element index. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + */ + +void +isc_heap_increased(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Indicates to the heap that an element's priority has increased. + * This function MUST be called whenever an element has increased in priority. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + */ + +void +isc_heap_decreased(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Indicates to the heap that an element's priority has decreased. + * This function MUST be called whenever an element has decreased in priority. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + */ + +void * +isc_heap_element(isc_heap_t *heap, unsigned int index); +/*!< + * \brief Returns the element for a specific element index. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "index" is a valid element index, as provided by the "index" callback + * provided during heap creation. + * + * Returns: + *\li A pointer to the element for the element index. + */ + +void +isc_heap_foreach(isc_heap_t *heap, isc_heapaction_t action, void *uap); +/*!< + * \brief Iterate over the heap, calling an action for each element. The + * order of iteration is not sorted. + * + * Requires: + *\li "heapp" is not NULL and "*heap" points to a valid isc_heap_t. + *\li "action" is not NULL, and is a function which takes two arguments. + * The first is a void *, representing the element, and the second is + * "uap" as provided to isc_heap_foreach. + *\li "uap" is a caller-provided argument, and may be NULL. + * + * Note: + *\li The heap structure CANNOT be modified during this iteration. The only + * safe function to call while iterating the heap is isc_heap_element(). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_HEAP_H */ diff --git a/contrib/ntp/lib/isc/include/isc/hex.h b/contrib/ntp/lib/isc/include/isc/hex.h new file mode 100644 index 000000000..a5e2f532d --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/hex.h @@ -0,0 +1,98 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hex.h,v 1.13 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_HEX_H +#define ISC_HEX_H 1 + +/*! \file isc/hex.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Functions + ***/ + +isc_result_t +isc_hex_totext(isc_region_t *source, int wordlength, + const char *wordbreak, isc_buffer_t *target); +/*!< + * \brief Convert data into hex encoded text. + * + * Notes: + *\li The hex encoded text in 'target' will be divided into + * words of at most 'wordlength' characters, separated by + * the 'wordbreak' string. No parentheses will surround + * the text. + * + * Requires: + *\li 'source' is a region containing binary data + *\li 'target' is a text buffer containing available space + *\li 'wordbreak' points to a null-terminated string of + * zero or more whitespace characters + * + * Ensures: + *\li target will contain the hex encoded version of the data + * in source. The 'used' pointer in target will be advanced as + * necessary. + */ + +isc_result_t +isc_hex_decodestring(const char *cstr, isc_buffer_t *target); +/*!< + * \brief Decode a null-terminated hex string. + * + * Requires: + *\li 'cstr' is non-null. + *\li 'target' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS -- the entire decoded representation of 'cstring' + * fit in 'target'. + *\li #ISC_R_BADHEX -- 'cstr' is not a valid hex encoding. + * + * Other error returns are any possible error code from: + * isc_lex_create(), + * isc_lex_openbuffer(), + * isc_hex_tobuffer(). + */ + +isc_result_t +isc_hex_tobuffer(isc_lex_t *lexer, isc_buffer_t *target, int length); +/*!< + * \brief Convert hex encoded text from a lexer context into data. + * + * Requires: + *\li 'lex' is a valid lexer context + *\li 'target' is a buffer containing binary data + *\li 'length' is an integer + * + * Ensures: + *\li target will contain the data represented by the hex encoded + * string parsed by the lexer. No more than length bytes will be read, + * if length is positive. The 'used' pointer in target will be + * advanced as necessary. + */ + + +ISC_LANG_ENDDECLS + +#endif /* ISC_HEX_H */ diff --git a/contrib/ntp/lib/isc/include/isc/hmacmd5.h b/contrib/ntp/lib/isc/include/isc/hmacmd5.h new file mode 100644 index 000000000..9ecad453d --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/hmacmd5.h @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hmacmd5.h,v 1.14 2009/02/06 23:47:42 tbox Exp $ */ + +/*! \file isc/hmacmd5.h + * \brief This is the header file for the HMAC-MD5 keyed hash algorithm + * described in RFC2104. + */ + +#ifndef ISC_HMACMD5_H +#define ISC_HMACMD5_H 1 + +#include +#include +#include +#include + +#define ISC_HMACMD5_KEYLENGTH 64 + +#ifdef ISC_PLATFORM_OPENSSLHASH +#include + +typedef HMAC_CTX isc_hmacmd5_t; + +#else + +typedef struct { + isc_md5_t md5ctx; + unsigned char key[ISC_HMACMD5_KEYLENGTH]; +} isc_hmacmd5_t; +#endif + +ISC_LANG_BEGINDECLS + +void +isc_hmacmd5_init(isc_hmacmd5_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacmd5_invalidate(isc_hmacmd5_t *ctx); + +void +isc_hmacmd5_update(isc_hmacmd5_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacmd5_sign(isc_hmacmd5_t *ctx, unsigned char *digest); + +isc_boolean_t +isc_hmacmd5_verify(isc_hmacmd5_t *ctx, unsigned char *digest); + +isc_boolean_t +isc_hmacmd5_verify2(isc_hmacmd5_t *ctx, unsigned char *digest, size_t len); + +ISC_LANG_ENDDECLS + +#endif /* ISC_HMACMD5_H */ diff --git a/contrib/ntp/lib/isc/include/isc/hmacsha.h b/contrib/ntp/lib/isc/include/isc/hmacsha.h new file mode 100644 index 000000000..1d0e18409 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/hmacsha.h @@ -0,0 +1,169 @@ +/* + * Copyright (C) 2005-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: hmacsha.h,v 1.9 2009/02/06 23:47:42 tbox Exp $ */ + +/*! \file isc/hmacsha.h + * This is the header file for the HMAC-SHA1, HMAC-SHA224, HMAC-SHA256, + * HMAC-SHA334 and HMAC-SHA512 hash algorithm described in RFC 2104. + */ + +#ifndef ISC_HMACSHA_H +#define ISC_HMACSHA_H 1 + +#include +#include +#include +#include +#include + +#define ISC_HMACSHA1_KEYLENGTH ISC_SHA1_BLOCK_LENGTH +#define ISC_HMACSHA224_KEYLENGTH ISC_SHA224_BLOCK_LENGTH +#define ISC_HMACSHA256_KEYLENGTH ISC_SHA256_BLOCK_LENGTH +#define ISC_HMACSHA384_KEYLENGTH ISC_SHA384_BLOCK_LENGTH +#define ISC_HMACSHA512_KEYLENGTH ISC_SHA512_BLOCK_LENGTH + +#ifdef ISC_PLATFORM_OPENSSLHASH +#include + +typedef HMAC_CTX isc_hmacsha1_t; +typedef HMAC_CTX isc_hmacsha224_t; +typedef HMAC_CTX isc_hmacsha256_t; +typedef HMAC_CTX isc_hmacsha384_t; +typedef HMAC_CTX isc_hmacsha512_t; + +#else + +typedef struct { + isc_sha1_t sha1ctx; + unsigned char key[ISC_HMACSHA1_KEYLENGTH]; +} isc_hmacsha1_t; + +typedef struct { + isc_sha224_t sha224ctx; + unsigned char key[ISC_HMACSHA224_KEYLENGTH]; +} isc_hmacsha224_t; + +typedef struct { + isc_sha256_t sha256ctx; + unsigned char key[ISC_HMACSHA256_KEYLENGTH]; +} isc_hmacsha256_t; + +typedef struct { + isc_sha384_t sha384ctx; + unsigned char key[ISC_HMACSHA384_KEYLENGTH]; +} isc_hmacsha384_t; + +typedef struct { + isc_sha512_t sha512ctx; + unsigned char key[ISC_HMACSHA512_KEYLENGTH]; +} isc_hmacsha512_t; +#endif + +ISC_LANG_BEGINDECLS + +void +isc_hmacsha1_init(isc_hmacsha1_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha1_invalidate(isc_hmacsha1_t *ctx); + +void +isc_hmacsha1_update(isc_hmacsha1_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha1_sign(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha1_verify(isc_hmacsha1_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha224_init(isc_hmacsha224_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha224_invalidate(isc_hmacsha224_t *ctx); + +void +isc_hmacsha224_update(isc_hmacsha224_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha224_sign(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha224_verify(isc_hmacsha224_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha256_init(isc_hmacsha256_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha256_invalidate(isc_hmacsha256_t *ctx); + +void +isc_hmacsha256_update(isc_hmacsha256_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha256_sign(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha256_verify(isc_hmacsha256_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha384_init(isc_hmacsha384_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha384_invalidate(isc_hmacsha384_t *ctx); + +void +isc_hmacsha384_update(isc_hmacsha384_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha384_sign(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha384_verify(isc_hmacsha384_t *ctx, unsigned char *digest, size_t len); + + +void +isc_hmacsha512_init(isc_hmacsha512_t *ctx, const unsigned char *key, + unsigned int len); + +void +isc_hmacsha512_invalidate(isc_hmacsha512_t *ctx); + +void +isc_hmacsha512_update(isc_hmacsha512_t *ctx, const unsigned char *buf, + unsigned int len); + +void +isc_hmacsha512_sign(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len); + +isc_boolean_t +isc_hmacsha512_verify(isc_hmacsha512_t *ctx, unsigned char *digest, size_t len); + +ISC_LANG_ENDDECLS + +#endif /* ISC_HMACSHA_H */ diff --git a/contrib/ntp/lib/isc/include/isc/httpd.h b/contrib/ntp/lib/isc/include/isc/httpd.h new file mode 100644 index 000000000..ba7f90019 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/httpd.h @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2006-2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: httpd.h,v 1.9 2008/08/08 05:06:49 marka Exp $ */ + +#ifndef ISC_HTTPD_H +#define ISC_HTTPD_H 1 + +/*! \file */ + +#include +#include +#include +#include +#include + +#define HTTPD_EVENTCLASS ISC_EVENTCLASS(4300) +#define HTTPD_SHUTDOWN (HTTPD_EVENTCLASS + 0x0001) + +#define ISC_HTTPDMGR_FLAGSHUTTINGDOWN 0x00000001 + +/* + * Create a new http daemon which will send, once every time period, + * a http-like header followed by HTTP data. + */ +isc_result_t +isc_httpdmgr_create(isc_mem_t *mctx, isc_socket_t *sock, isc_task_t *task, + isc_httpdclientok_t *client_ok, + isc_httpdondestroy_t *ondestory, void *cb_arg, + isc_timermgr_t *tmgr, isc_httpdmgr_t **httpdp); + +void +isc_httpdmgr_shutdown(isc_httpdmgr_t **httpdp); + +isc_result_t +isc_httpdmgr_addurl(isc_httpdmgr_t *httpdmgr, const char *url, + isc_httpdaction_t *func, void *arg); + +isc_result_t +isc_httpd_response(isc_httpd_t *httpd); + +isc_result_t +isc_httpd_addheader(isc_httpd_t *httpd, const char *name, + const char *val); + +isc_result_t +isc_httpd_addheaderuint(isc_httpd_t *httpd, const char *name, int val); + +isc_result_t isc_httpd_endheaders(isc_httpd_t *httpd); + +#endif /* ISC_HTTPD_H */ diff --git a/contrib/ntp/lib/isc/include/isc/interfaceiter.h b/contrib/ntp/lib/isc/include/isc/interfaceiter.h new file mode 100644 index 000000000..544f54b12 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/interfaceiter.h @@ -0,0 +1,138 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: interfaceiter.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_INTERFACEITER_H +#define ISC_INTERFACEITER_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/interfaceiter.h + * \brief Iterates over the list of network interfaces. + * + * Interfaces whose address family is not supported are ignored and never + * returned by the iterator. Interfaces whose netmask, interface flags, + * or similar cannot be obtained are also ignored, and the failure is logged. + * + * Standards: + * The API for scanning varies greatly among operating systems. + * This module attempts to hide the differences. + */ + +/*** + *** Imports + ***/ + +#include +#include +#include + +/*! + * \brief Public structure describing a network interface. + */ + +struct isc_interface { + char name[32]; /*%< Interface name, null-terminated. */ + unsigned int af; /*%< Address family. */ + isc_netaddr_t address; /*%< Local address. */ + isc_netaddr_t netmask; /*%< Network mask. */ + isc_netaddr_t broadcast; /*&< Broadcast address. */ + isc_netaddr_t dstaddress; /*%< Destination address (point-to-point only). */ + isc_uint32_t flags; /*%< Flags; see INTERFACE flags. */ + unsigned int ifindex; /*%< Interface index for IP(V6)_MULTICAST_IF. */ +}; + +/*@{*/ +/*! Interface flags. */ + +#define INTERFACE_F_UP 0x00000001U +#define INTERFACE_F_POINTTOPOINT 0x00000002U +#define INTERFACE_F_LOOPBACK 0x00000004U +#define INTERFACE_F_BROADCAST 0x00000008U +#define INTERFACE_F_MULTICAST 0x00000010U +#define INTERFACE_F_PRIVACY 0x00000020U /* RFC 4941 */ +/*@}*/ + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp); +/*!< + * \brief Create an iterator for traversing the operating system's list + * of network interfaces. + * + * Returns: + *\li #ISC_R_SUCCESS + * \li #ISC_R_NOMEMORY + *\li Various network-related errors + */ + +isc_result_t +isc_interfaceiter_first(isc_interfaceiter_t *iter); +/*!< + * \brief Position the iterator on the first interface. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOMORE There are no interfaces. + */ + +isc_result_t +isc_interfaceiter_current(isc_interfaceiter_t *iter, + isc_interface_t *ifdata); +/*!< + * \brief Get information about the interface the iterator is currently + * positioned at and store it at *ifdata. + * + * Requires: + *\li The iterator has been successfully positioned using + * isc_interface_iter_first() / isc_interface_iter_next(). + * + * Returns: + *\li #ISC_R_SUCCESS Success. + */ + +isc_result_t +isc_interfaceiter_next(isc_interfaceiter_t *iter); +/*!< + * \brief Position the iterator on the next interface. + * + * Requires: + * \li The iterator has been successfully positioned using + * isc_interface_iter_first() / isc_interface_iter_next(). + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOMORE There are no more interfaces. + */ + +void +isc_interfaceiter_destroy(isc_interfaceiter_t **iterp); +/*!< + * \brief Destroy the iterator. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_INTERFACEITER_H */ diff --git a/contrib/ntp/include/isc/ipv6.h b/contrib/ntp/lib/isc/include/isc/ipv6.h similarity index 82% rename from contrib/ntp/include/isc/ipv6.h rename to contrib/ntp/lib/isc/include/isc/ipv6.h index 007de7c0d..8054c9e18 100644 --- a/contrib/ntp/include/isc/ipv6.h +++ b/contrib/ntp/lib/isc/include/isc/ipv6.h @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,12 +15,12 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: ipv6.h,v 1.17.12.4 2004/03/09 05:21:09 marka Exp $ */ +/* $Id: ipv6.h,v 1.24 2007/06/19 23:47:18 tbox Exp $ */ #ifndef ISC_IPV6_H #define ISC_IPV6_H 1 -/* +/*! * Also define LWRES_IPV6_H to keep it from being included if liblwres is * being used, or redefinition errors will occur. */ @@ -30,23 +30,23 @@ ***** Module Info *****/ -/* - * IPv6 definitions for systems which do not support IPv6. +/*! \file isc/ipv6.h + * \brief IPv6 definitions for systems which do not support IPv6. * - * MP: + * \li MP: * No impact. * - * Reliability: + * \li Reliability: * No anticipated impact. * - * Resources: + * \li Resources: * N/A. * - * Security: + * \li Security: * No anticipated impact. * - * Standards: - * RFC 2553. + * \li Standards: + * RFC2553. */ /*** @@ -56,10 +56,6 @@ #include #include -/* - * We probably don't need this on NTP - */ -#ifdef ISC_ONLY_IPV6 /*** *** Types. ***/ @@ -76,8 +72,8 @@ struct in6_addr { #define s6_addr16 _S6_un._S6_u16 #define s6_addr32 _S6_un._S6_u32 -#define IN6ADDR_ANY_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }} -#define IN6ADDR_LOOPBACK_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }} +#define IN6ADDR_ANY_INIT {{{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }}} +#define IN6ADDR_LOOPBACK_INIT {{{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }}} LIBISC_EXTERNAL_DATA extern const struct in6_addr in6addr_any; LIBISC_EXTERNAL_DATA extern const struct in6_addr in6addr_loopback; @@ -99,17 +95,16 @@ struct sockaddr_in6 { #define SIN6_LEN 1 #endif -/* +/*% * Unspecified */ -#ifndef IN6_IS_ADDR_UNSPECIFIED #define IN6_IS_ADDR_UNSPECIFIED(a) \ (((a)->s6_addr32[0] == 0) && \ ((a)->s6_addr32[1] == 0) && \ ((a)->s6_addr32[2] == 0) && \ ((a)->s6_addr32[3] == 0)) -#endif -/* + +/*% * Loopback */ #define IN6_IS_ADDR_LOOPBACK(a) \ @@ -118,7 +113,7 @@ struct sockaddr_in6 { ((a)->s6_addr32[2] == 0) && \ ((a)->s6_addr32[3] == htonl(1))) -/* +/*% * IPv4 compatible */ #define IN6_IS_ADDR_V4COMPAT(a) \ @@ -128,7 +123,7 @@ struct sockaddr_in6 { ((a)->s6_addr32[3] != 0) && \ ((a)->s6_addr32[3] != htonl(1))) -/* +/*% * Mapped */ #define IN6_IS_ADDR_V4MAPPED(a) \ @@ -136,14 +131,13 @@ struct sockaddr_in6 { ((a)->s6_addr32[1] == 0) && \ ((a)->s6_addr32[2] == htonl(0x0000ffff))) -/* +/*% * Multicast */ -#ifndef IN6_IS_ADDR_MULTICAST #define IN6_IS_ADDR_MULTICAST(a) \ ((a)->s6_addr8[0] == 0xffU) -#endif -/* + +/*% * Unicast link / site local. */ #define IN6_IS_ADDR_LINKLOCAL(a) \ @@ -151,5 +145,4 @@ struct sockaddr_in6 { #define IN6_IS_ADDR_SITELOCAL(a) \ (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0xc0)) -#endif /* ISC_ONLY_IPV6 */ #endif /* ISC_IPV6_H */ diff --git a/contrib/ntp/lib/isc/include/isc/iterated_hash.h b/contrib/ntp/lib/isc/include/isc/iterated_hash.h new file mode 100644 index 000000000..a8173f0ab --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/iterated_hash.h @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: iterated_hash.h,v 1.3 2008/09/25 04:02:39 tbox Exp $ */ + +#ifndef ISC_ITERATED_HASH_H +#define ISC_ITERATED_HASH_H 1 + +#include +#include + +/* + * The maximal hash length that can be encoded it a name + * using base32hex. floor(255/8)*5 + */ +#define NSEC3_MAX_HASH_LENGTH 155 + +/* + * The maximum has that can be encoded in a single label using + * base32hex. floor(63/8)*5 + */ +#define NSEC3_MAX_LABEL_HASH 35 + +ISC_LANG_BEGINDECLS + +int isc_iterated_hash(unsigned char out[NSEC3_MAX_HASH_LENGTH], + unsigned int hashalg, int iterations, + const unsigned char *salt, int saltlength, + const unsigned char *in, int inlength); + + +ISC_LANG_ENDDECLS + +#endif /* ISC_ITERATED_HASH_H */ diff --git a/contrib/ntp/lib/isc/include/isc/lang.h b/contrib/ntp/lib/isc/include/isc/lang.h new file mode 100644 index 000000000..8c608669b --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/lang.h @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lang.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_LANG_H +#define ISC_LANG_H 1 + +/*! \file isc/lang.h */ + +#ifdef __cplusplus +#define ISC_LANG_BEGINDECLS extern "C" { +#define ISC_LANG_ENDDECLS } +#else +#define ISC_LANG_BEGINDECLS +#define ISC_LANG_ENDDECLS +#endif + +#endif /* ISC_LANG_H */ diff --git a/contrib/ntp/lib/isc/include/isc/lex.h b/contrib/ntp/lib/isc/include/isc/lex.h new file mode 100644 index 000000000..861215099 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/lex.h @@ -0,0 +1,431 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lex.h,v 1.37 2008/05/30 23:47:01 tbox Exp $ */ + +#ifndef ISC_LEX_H +#define ISC_LEX_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/lex.h + * \brief The "lex" module provides a lightweight tokenizer. It can operate + * on files or buffers, and can handle "include". It is designed for + * parsing of DNS master files and the BIND configuration file, but + * should be general enough to tokenize other things, e.g. HTTP. + * + * \li MP: + * No synchronization is provided. Clients must ensure exclusive + * access. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include + +#include +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Options + ***/ + +/*@{*/ +/*! + * Various options for isc_lex_gettoken(). + */ + +#define ISC_LEXOPT_EOL 0x01 /*%< Want end-of-line token. */ +#define ISC_LEXOPT_EOF 0x02 /*%< Want end-of-file token. */ +#define ISC_LEXOPT_INITIALWS 0x04 /*%< Want initial whitespace. */ +#define ISC_LEXOPT_NUMBER 0x08 /*%< Recognize numbers. */ +#define ISC_LEXOPT_QSTRING 0x10 /*%< Recognize qstrings. */ +/*@}*/ + +/*@{*/ +/*! + * The ISC_LEXOPT_DNSMULTILINE option handles the processing of '(' and ')' in + * the DNS master file format. If this option is set, then the + * ISC_LEXOPT_INITIALWS and ISC_LEXOPT_EOL options will be ignored when + * the paren count is > 0. To use this option, '(' and ')' must be special + * characters. + */ +#define ISC_LEXOPT_DNSMULTILINE 0x20 /*%< Handle '(' and ')'. */ +#define ISC_LEXOPT_NOMORE 0x40 /*%< Want "no more" token. */ + +#define ISC_LEXOPT_CNUMBER 0x80 /*%< Recognize octal and hex. */ +#define ISC_LEXOPT_ESCAPE 0x100 /*%< Recognize escapes. */ +#define ISC_LEXOPT_QSTRINGMULTILINE 0x200 /*%< Allow multiline "" strings */ +#define ISC_LEXOPT_OCTAL 0x400 /*%< Expect a octal number. */ +/*@}*/ +/*@{*/ +/*! + * Various commenting styles, which may be changed at any time with + * isc_lex_setcomments(). + */ + +#define ISC_LEXCOMMENT_C 0x01 +#define ISC_LEXCOMMENT_CPLUSPLUS 0x02 +#define ISC_LEXCOMMENT_SHELL 0x04 +#define ISC_LEXCOMMENT_DNSMASTERFILE 0x08 +/*@}*/ + +/*** + *** Types + ***/ + +/*! Lex */ + +typedef char isc_lexspecials_t[256]; + +/* Tokens */ + +typedef enum { + isc_tokentype_unknown = 0, + isc_tokentype_string = 1, + isc_tokentype_number = 2, + isc_tokentype_qstring = 3, + isc_tokentype_eol = 4, + isc_tokentype_eof = 5, + isc_tokentype_initialws = 6, + isc_tokentype_special = 7, + isc_tokentype_nomore = 8 +} isc_tokentype_t; + +typedef union { + char as_char; + unsigned long as_ulong; + isc_region_t as_region; + isc_textregion_t as_textregion; + void * as_pointer; +} isc_tokenvalue_t; + +typedef struct isc_token { + isc_tokentype_t type; + isc_tokenvalue_t value; +} isc_token_t; + +/*** + *** Functions + ***/ + +isc_result_t +isc_lex_create(isc_mem_t *mctx, size_t max_token, isc_lex_t **lexp); +/*%< + * Create a lexer. + * + * 'max_token' is a hint of the number of bytes in the largest token. + * + * Requires: + *\li '*lexp' is a valid lexer. + * + *\li max_token > 0. + * + * Ensures: + *\li On success, *lexp is attached to the newly created lexer. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + */ + +void +isc_lex_destroy(isc_lex_t **lexp); +/*%< + * Destroy the lexer. + * + * Requires: + *\li '*lexp' is a valid lexer. + * + * Ensures: + *\li *lexp == NULL + */ + +unsigned int +isc_lex_getcomments(isc_lex_t *lex); +/*%< + * Return the current lexer commenting styles. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + *\li The commenting sytles which are currently allowed. + */ + +void +isc_lex_setcomments(isc_lex_t *lex, unsigned int comments); +/*%< + * Set allowed lexer commenting styles. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'comments' has meaningful values. + */ + +void +isc_lex_getspecials(isc_lex_t *lex, isc_lexspecials_t specials); +/*%< + * Put the current list of specials into 'specials'. + * + * Requires: + *\li 'lex' is a valid lexer. + */ + +void +isc_lex_setspecials(isc_lex_t *lex, isc_lexspecials_t specials); +/*!< + * The characters in 'specials' are returned as tokens. Along with + * whitespace, they delimit strings and numbers. + * + * Note: + *\li Comment processing takes precedence over special character + * recognition. + * + * Requires: + *\li 'lex' is a valid lexer. + */ + +isc_result_t +isc_lex_openfile(isc_lex_t *lex, const char *filename); +/*%< + * Open 'filename' and make it the current input source for 'lex'. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li filename is a valid C string. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY Out of memory + *\li #ISC_R_NOTFOUND File not found + *\li #ISC_R_NOPERM No permission to open file + *\li #ISC_R_FAILURE Couldn't open file, not sure why + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_lex_openstream(isc_lex_t *lex, FILE *stream); +/*%< + * Make 'stream' the current input source for 'lex'. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'stream' is a valid C stream. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY Out of memory + */ + +isc_result_t +isc_lex_openbuffer(isc_lex_t *lex, isc_buffer_t *buffer); +/*%< + * Make 'buffer' the current input source for 'lex'. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'buffer' is a valid buffer. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY Out of memory + */ + +isc_result_t +isc_lex_close(isc_lex_t *lex); +/*%< + * Close the most recently opened object (i.e. file or buffer). + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMORE No more input sources + */ + +isc_result_t +isc_lex_gettoken(isc_lex_t *lex, unsigned int options, isc_token_t *tokenp); +/*%< + * Get the next token. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'lex' has an input source. + * + *\li 'options' contains valid options. + * + *\li '*tokenp' is a valid pointer. + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_UNEXPECTEDEND + *\li #ISC_R_NOMEMORY + * + * These two results are returned only if their corresponding lexer + * options are not set. + * + *\li #ISC_R_EOF End of input source + *\li #ISC_R_NOMORE No more input sources + */ + +isc_result_t +isc_lex_getmastertoken(isc_lex_t *lex, isc_token_t *token, + isc_tokentype_t expect, isc_boolean_t eol); +/*%< + * Get the next token from a DNS master file type stream. This is a + * convenience function that sets appropriate options and handles quoted + * strings and end of line correctly for master files. It also ungets + * unexpected tokens. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'token' is a valid pointer + * + * Returns: + * + * \li any return code from isc_lex_gettoken(). + */ + +isc_result_t +isc_lex_getoctaltoken(isc_lex_t *lex, isc_token_t *token, isc_boolean_t eol); +/*%< + * Get the next token from a DNS master file type stream. This is a + * convenience function that sets appropriate options and handles end + * of line correctly for master files. It also ungets unexpected tokens. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'token' is a valid pointer + * + * Returns: + * + * \li any return code from isc_lex_gettoken(). + */ + +void +isc_lex_ungettoken(isc_lex_t *lex, isc_token_t *tokenp); +/*%< + * Unget the current token. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'lex' has an input source. + * + *\li 'tokenp' points to a valid token. + * + *\li There is no ungotten token already. + */ + +void +isc_lex_getlasttokentext(isc_lex_t *lex, isc_token_t *tokenp, isc_region_t *r); +/*%< + * Returns a region containing the text of the last token returned. + * + * Requires: + *\li 'lex' is a valid lexer. + * + *\li 'lex' has an input source. + * + *\li 'tokenp' points to a valid token. + * + *\li A token has been gotten and not ungotten. + */ + +char * +isc_lex_getsourcename(isc_lex_t *lex); +/*%< + * Return the input source name. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + * \li source name or NULL if no current source. + *\li result valid while current input source exists. + */ + + +unsigned long +isc_lex_getsourceline(isc_lex_t *lex); +/*%< + * Return the input source line number. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + *\li Current line number or 0 if no current source. + */ + +isc_result_t +isc_lex_setsourcename(isc_lex_t *lex, const char *name); +/*%< + * Assigns a new name to the input source. + * + * Requires: + * + * \li 'lex' is a valid lexer. + * + * Returns: + * \li #ISC_R_SUCCESS + * \li #ISC_R_NOMEMORY + * \li #ISC_R_NOTFOUND - there are no sources. + */ + +isc_boolean_t +isc_lex_isfile(isc_lex_t *lex); +/*%< + * Return whether the current input source is a file. + * + * Requires: + *\li 'lex' is a valid lexer. + * + * Returns: + * \li #ISC_TRUE if the current input is a file, + *\li #ISC_FALSE otherwise. + */ + + +ISC_LANG_ENDDECLS + +#endif /* ISC_LEX_H */ diff --git a/contrib/ntp/lib/isc/include/isc/lfsr.h b/contrib/ntp/lib/isc/include/isc/lfsr.h new file mode 100644 index 000000000..d4d970700 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/lfsr.h @@ -0,0 +1,130 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lfsr.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_LFSR_H +#define ISC_LFSR_H 1 + +/*! \file isc/lfsr.h */ + +#include +#include + +typedef struct isc_lfsr isc_lfsr_t; + +/*% + * This function is called when reseeding is needed. It is allowed to + * modify any state in the LFSR in any way it sees fit OTHER THAN "bits". + * + * It MUST set "count" to a new value or the lfsr will never reseed again. + * + * Also, a reseed will never occur in the middle of an extraction. This + * is purely an optimization, and is probably what one would want. + */ +typedef void (*isc_lfsrreseed_t)(isc_lfsr_t *, void *); + +/*% + * The members of this structure can be used by the application, but care + * needs to be taken to not change state once the lfsr is in operation. + */ +struct isc_lfsr { + isc_uint32_t state; /*%< previous state */ + unsigned int bits; /*%< length */ + isc_uint32_t tap; /*%< bit taps */ + unsigned int count; /*%< reseed count (in BITS!) */ + isc_lfsrreseed_t reseed; /*%< reseed function */ + void *arg; /*%< reseed function argument */ +}; + +ISC_LANG_BEGINDECLS + + +void +isc_lfsr_init(isc_lfsr_t *lfsr, isc_uint32_t state, unsigned int bits, + isc_uint32_t tap, unsigned int count, + isc_lfsrreseed_t reseed, void *arg); +/*%< + * Initialize an LFSR. + * + * Note: + * + *\li Putting untrusted values into this function will cause the LFSR to + * generate (perhaps) non-maximal length sequences. + * + * Requires: + * + *\li lfsr != NULL + * + *\li 8 <= bits <= 32 + * + *\li tap != 0 + */ + +void +isc_lfsr_generate(isc_lfsr_t *lfsr, void *data, unsigned int count); +/*%< + * Returns "count" bytes of data from the LFSR. + * + * Requires: + * + *\li lfsr be valid. + * + *\li data != NULL. + * + *\li count > 0. + */ + +void +isc_lfsr_skip(isc_lfsr_t *lfsr, unsigned int skip); +/*%< + * Skip "skip" states. + * + * Requires: + * + *\li lfsr be valid. + */ + +isc_uint32_t +isc_lfsr_generate32(isc_lfsr_t *lfsr1, isc_lfsr_t *lfsr2); +/*%< + * Given two LFSRs, use the current state from each to skip entries in the + * other. The next states are then xor'd together and returned. + * + * WARNING: + * + *\li This function is used only for very, very low security data, such + * as DNS message IDs where it is desired to have an unpredictable + * stream of bytes that are harder to predict than a simple flooding + * attack. + * + * Notes: + * + *\li Since the current state from each of the LFSRs is used to skip + * state in the other, it is important that no state be leaked + * from either LFSR. + * + * Requires: + * + *\li lfsr1 and lfsr2 be valid. + * + *\li 1 <= skipbits <= 31 + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_LFSR_H */ diff --git a/contrib/ntp/lib/isc/include/isc/lib.h b/contrib/ntp/lib/isc/include/isc/lib.h new file mode 100644 index 000000000..f24fef850 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/lib.h @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lib.h,v 1.16 2009/09/02 23:48:03 tbox Exp $ */ + +#ifndef ISC_LIB_H +#define ISC_LIB_H 1 + +/*! \file isc/lib.h */ + +#include +#include + +ISC_LANG_BEGINDECLS + +LIBISC_EXTERNAL_DATA extern isc_msgcat_t *isc_msgcat; + +void +isc_lib_initmsgcat(void); +/*!< + * \brief Initialize the ISC library's message catalog, isc_msgcat, if it + * has not already been initialized. + */ + +void +isc_lib_register(void); +/*!< + * \brief Register the ISC library implementations for some base services + * such as memory or event management and handling socket or timer events. + * An external application that wants to use the ISC library must call this + * function very early in main(). + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_LIB_H */ diff --git a/contrib/ntp/include/isc/list.h b/contrib/ntp/lib/isc/include/isc/list.h similarity index 81% rename from contrib/ntp/include/isc/list.h rename to contrib/ntp/lib/isc/include/isc/list.h index d0ae7a91a..c9bdfc7ad 100644 --- a/contrib/ntp/include/isc/list.h +++ b/contrib/ntp/lib/isc/include/isc/list.h @@ -1,21 +1,21 @@ /* - * Copyright (C) 1997-2001 Internet Software Consortium. + * Copyright (C) 2004, 2006, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: list.h,v 1.19 2002/05/09 07:09:30 marka Exp $ */ +/* $Id$ */ #ifndef ISC_LIST_H #define ISC_LIST_H 1 @@ -90,12 +90,16 @@ do { \ if ((elt)->link.next != NULL) \ (elt)->link.next->link.prev = (elt)->link.prev; \ - else \ + else { \ + ISC_INSIST((list).tail == (elt)); \ (list).tail = (elt)->link.prev; \ + } \ if ((elt)->link.prev != NULL) \ (elt)->link.prev->link.next = (elt)->link.next; \ - else \ + else { \ + ISC_INSIST((list).head == (elt)); \ (list).head = (elt)->link.next; \ + } \ (elt)->link.prev = (type *)(-1); \ (elt)->link.next = (type *)(-1); \ } while (0) @@ -165,6 +169,19 @@ (list2).tail = NULL; \ } while (0) +#define ISC_LIST_PREPENDLIST(list1, list2, link) \ + do { \ + if (ISC_LIST_EMPTY(list1)) \ + (list1) = (list2); \ + else if (!ISC_LIST_EMPTY(list2)) { \ + (list2).tail->link.next = (list1).head; \ + (list1).head->link.prev = (list2).tail; \ + (list1).head = (list2).head; \ + } \ + (list2).head = NULL; \ + (list2).tail = NULL; \ + } while (0) + #define ISC_LIST_ENQUEUE(list, elt, link) ISC_LIST_APPEND(list, elt, link) #define __ISC_LIST_ENQUEUEUNSAFE(list, elt, link) \ __ISC_LIST_APPENDUNSAFE(list, elt, link) diff --git a/contrib/ntp/lib/isc/include/isc/log.h b/contrib/ntp/lib/isc/include/isc/log.h new file mode 100644 index 000000000..741c53242 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/log.h @@ -0,0 +1,914 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: log.h,v 1.59 2009/02/16 02:01:16 marka Exp $ */ + +#ifndef ISC_LOG_H +#define ISC_LOG_H 1 + +/*! \file isc/log.h */ + +#include +#include +#include /* XXXDCL NT */ + +#include +#include +#include +#include + +/*@{*/ +/*! + * \brief Severity levels, patterned after Unix's syslog levels. + * + */ +#define ISC_LOG_DEBUG(level) (level) +/*! + * #ISC_LOG_DYNAMIC can only be used for defining channels with + * isc_log_createchannel(), not to specify a level in isc_log_write(). + */ +#define ISC_LOG_DYNAMIC 0 +#define ISC_LOG_INFO (-1) +#define ISC_LOG_NOTICE (-2) +#define ISC_LOG_WARNING (-3) +#define ISC_LOG_ERROR (-4) +#define ISC_LOG_CRITICAL (-5) +/*@}*/ + +/*@{*/ +/*! + * \brief Destinations. + */ +#define ISC_LOG_TONULL 1 +#define ISC_LOG_TOSYSLOG 2 +#define ISC_LOG_TOFILE 3 +#define ISC_LOG_TOFILEDESC 4 +/*@}*/ + +/*@{*/ +/*% + * Channel flags. + */ +#define ISC_LOG_PRINTTIME 0x0001 +#define ISC_LOG_PRINTLEVEL 0x0002 +#define ISC_LOG_PRINTCATEGORY 0x0004 +#define ISC_LOG_PRINTMODULE 0x0008 +#define ISC_LOG_PRINTTAG 0x0010 +#define ISC_LOG_PRINTALL 0x001F +#define ISC_LOG_DEBUGONLY 0x1000 +#define ISC_LOG_OPENERR 0x8000 /* internal */ +/*@}*/ + +/*@{*/ +/*! + * \brief Other options. + * + * XXXDCL INFINITE doesn't yet work. Arguably it isn't needed, but + * since I am intend to make large number of versions work efficiently, + * INFINITE is going to be trivial to add to that. + */ +#define ISC_LOG_ROLLINFINITE (-1) +#define ISC_LOG_ROLLNEVER (-2) +/*@}*/ + +/*! + * \brief Used to name the categories used by a library. + * + * An array of isc_logcategory + * structures names each category, and the id value is initialized by calling + * isc_log_registercategories. + */ +struct isc_logcategory { + const char *name; + unsigned int id; +}; + +/*% + * Similar to isc_logcategory, but for all the modules a library defines. + */ +struct isc_logmodule { + const char *name; + unsigned int id; +}; + +/*% + * The isc_logfile structure is initialized as part of an isc_logdestination + * before calling isc_log_createchannel(). + * + * When defining an #ISC_LOG_TOFILE + * channel the name, versions and maximum_size should be set before calling + * isc_log_createchannel(). To define an #ISC_LOG_TOFILEDESC channel set only + * the stream before the call. + * + * Setting maximum_size to zero implies no maximum. + */ +typedef struct isc_logfile { + FILE *stream; /*%< Initialized to NULL for #ISC_LOG_TOFILE. */ + const char *name; /*%< NULL for #ISC_LOG_TOFILEDESC. */ + int versions; /* >= 0, #ISC_LOG_ROLLNEVER, #ISC_LOG_ROLLINFINITE. */ + /*% + * stdio's ftell is standardized to return a long, which may well not + * be big enough for the largest file supportable by the operating + * system (though it is _probably_ big enough for the largest log + * anyone would want). st_size returned by fstat should be typedef'd + * to a size large enough for the largest possible file on a system. + */ + isc_offset_t maximum_size; + isc_boolean_t maximum_reached; /*%< Private. */ +} isc_logfile_t; + +/*% + * Passed to isc_log_createchannel to define the attributes of either + * a stdio or a syslog log. + */ +typedef union isc_logdestination { + isc_logfile_t file; + int facility; /* XXXDCL NT */ +} isc_logdestination_t; + +/*@{*/ +/*% + * The built-in categories of libisc. + * + * Each library registering categories should provide library_LOGCATEGORY_name + * definitions with indexes into its isc_logcategory structure corresponding to + * the order of the names. + */ +LIBISC_EXTERNAL_DATA extern isc_logcategory_t isc_categories[]; +LIBISC_EXTERNAL_DATA extern isc_log_t *isc_lctx; +LIBISC_EXTERNAL_DATA extern isc_logmodule_t isc_modules[]; +/*@}*/ + +/*@{*/ +/*% + * Do not log directly to DEFAULT. Use another category. When in doubt, + * use GENERAL. + */ +#define ISC_LOGCATEGORY_DEFAULT (&isc_categories[0]) +#define ISC_LOGCATEGORY_GENERAL (&isc_categories[1]) +/*@}*/ + +#define ISC_LOGMODULE_SOCKET (&isc_modules[0]) +#define ISC_LOGMODULE_TIME (&isc_modules[1]) +#define ISC_LOGMODULE_INTERFACE (&isc_modules[2]) +#define ISC_LOGMODULE_TIMER (&isc_modules[3]) +#define ISC_LOGMODULE_FILE (&isc_modules[4]) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_log_create(isc_mem_t *mctx, isc_log_t **lctxp, isc_logconfig_t **lcfgp); +/*%< + * Establish a new logging context, with default channels. + * + * Notes: + *\li isc_log_create() calls isc_logconfig_create(), so see its comment + * below for more information. + * + * Requires: + *\li mctx is a valid memory context. + *\li lctxp is not null and *lctxp is null. + *\li lcfgp is null or lcfgp is not null and *lcfgp is null. + * + * Ensures: + *\li *lctxp will point to a valid logging context if all of the necessary + * memory was allocated, or NULL otherwise. + *\li *lcfgp will point to a valid logging configuration if all of the + * necessary memory was allocated, or NULL otherwise. + *\li On failure, no additional memory is allocated. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +isc_result_t +isc_logconfig_create(isc_log_t *lctx, isc_logconfig_t **lcfgp); +/*%< + * Create the data structure that holds all of the configurable information + * about where messages are actually supposed to be sent -- the information + * that could changed based on some configuration file, as opposed to the + * the category/module specification of isc_log_[v]write[1] that is compiled + * into a program, or the debug_level which is dynamic state information. + * + * Notes: + *\li It is necessary to specify the logging context the configuration + * will be used with because the number of categories and modules + * needs to be known in order to set the configuration. However, + * the configuration is not used by the logging context until the + * isc_logconfig_use function is called. + * + *\li The memory context used for operations that allocate memory for + * the configuration is that of the logging context, as specified + * in the isc_log_create call. + * + *\li Four default channels are established: + *\verbatim + * default_syslog + * - log to syslog's daemon facility #ISC_LOG_INFO or higher + * default_stderr + * - log to stderr #ISC_LOG_INFO or higher + * default_debug + * - log to stderr #ISC_LOG_DEBUG dynamically + * null + * - log nothing + *\endverbatim + * + * Requires: + *\li lctx is a valid logging context. + *\li lcftp is not null and *lcfgp is null. + * + * Ensures: + *\li *lcfgp will point to a valid logging context if all of the necessary + * memory was allocated, or NULL otherwise. + *\li On failure, no additional memory is allocated. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +isc_logconfig_t * +isc_logconfig_get(isc_log_t *lctx); +/*%< + * Returns a pointer to the configuration currently in use by the log context. + * + * Requires: + *\li lctx is a valid context. + * + * Ensures: + *\li The configuration pointer is non-null. + * + * Returns: + *\li The configuration pointer. + */ + +isc_result_t +isc_logconfig_use(isc_log_t *lctx, isc_logconfig_t *lcfg); +/*%< + * Associate a new configuration with a logging context. + * + * Notes: + *\li This is thread safe. The logging context will lock a mutex + * before attempting to swap in the new configuration, and isc_log_doit + * (the internal function used by all of isc_log_[v]write[1]) locks + * the same lock for the duration of its use of the configuration. + * + * Requires: + *\li lctx is a valid logging context. + *\li lcfg is a valid logging configuration. + *\li lctx is the same configuration given to isc_logconfig_create + * when the configuration was created. + * + * Ensures: + *\li Future calls to isc_log_write will use the new configuration. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +void +isc_log_destroy(isc_log_t **lctxp); +/*%< + * Deallocate the memory associated with a logging context. + * + * Requires: + *\li *lctx is a valid logging context. + * + * Ensures: + *\li All of the memory associated with the logging context is returned + * to the free memory pool. + * + *\li Any open files are closed. + * + *\li The logging context is marked as invalid. + */ + +void +isc_logconfig_destroy(isc_logconfig_t **lcfgp); +/*%< + * Destroy a logging configuration. + * + * Notes: + *\li This function cannot be used directly with the return value of + * isc_logconfig_get, because a logging context must always have + * a valid configuration associated with it. + * + * Requires: + *\li lcfgp is not null and *lcfgp is a valid logging configuration. + *\li The logging configuration is not in use by an existing logging context. + * + * Ensures: + *\li All memory allocated for the configuration is freed. + * + *\li The configuration is marked as invalid. + */ + +void +isc_log_registercategories(isc_log_t *lctx, isc_logcategory_t categories[]); +/*%< + * Identify logging categories a library will use. + * + * Notes: + *\li A category should only be registered once, but no mechanism enforces + * this rule. + * + *\li The end of the categories array is identified by a NULL name. + * + *\li Because the name is used by #ISC_LOG_PRINTCATEGORY, it should not + * be altered or destroyed after isc_log_registercategories(). + * + *\li Because each element of the categories array is used by + * isc_log_categorybyname, it should not be altered or destroyed + * after registration. + * + *\li The value of the id integer in each structure is overwritten + * by this function, and so id need not be initialized to any particular + * value prior to the function call. + * + *\li A subsequent call to isc_log_registercategories with the same + * logging context (but new categories) will cause the last + * element of the categories array from the prior call to have + * its "name" member changed from NULL to point to the new + * categories array, and its "id" member set to UINT_MAX. + * + * Requires: + *\li lctx is a valid logging context. + *\li categories != NULL. + *\li categories[0].name != NULL. + * + * Ensures: + * \li There are references to each category in the logging context, + * so they can be used with isc_log_usechannel() and isc_log_write(). + */ + +void +isc_log_registermodules(isc_log_t *lctx, isc_logmodule_t modules[]); +/*%< + * Identify logging categories a library will use. + * + * Notes: + *\li A module should only be registered once, but no mechanism enforces + * this rule. + * + *\li The end of the modules array is identified by a NULL name. + * + *\li Because the name is used by #ISC_LOG_PRINTMODULE, it should not + * be altered or destroyed after isc_log_registermodules(). + * + *\li Because each element of the modules array is used by + * isc_log_modulebyname, it should not be altered or destroyed + * after registration. + * + *\li The value of the id integer in each structure is overwritten + * by this function, and so id need not be initialized to any particular + * value prior to the function call. + * + *\li A subsequent call to isc_log_registermodules with the same + * logging context (but new modules) will cause the last + * element of the modules array from the prior call to have + * its "name" member changed from NULL to point to the new + * modules array, and its "id" member set to UINT_MAX. + * + * Requires: + *\li lctx is a valid logging context. + *\li modules != NULL. + *\li modules[0].name != NULL; + * + * Ensures: + *\li Each module has a reference in the logging context, so they can be + * used with isc_log_usechannel() and isc_log_write(). + */ + +isc_result_t +isc_log_createchannel(isc_logconfig_t *lcfg, const char *name, + unsigned int type, int level, + const isc_logdestination_t *destination, + unsigned int flags); +/*%< + * Specify the parameters of a logging channel. + * + * Notes: + *\li The name argument is copied to memory in the logging context, so + * it can be altered or destroyed after isc_log_createchannel(). + * + *\li Defining a very large number of channels will have a performance + * impact on isc_log_usechannel(), since the names are searched + * linearly until a match is made. This same issue does not affect + * isc_log_write, however. + * + *\li Channel names can be redefined; this is primarily useful for programs + * that want their own definition of default_syslog, default_debug + * and default_stderr. + * + *\li Any channel that is redefined will not affect logging that was + * already directed to its original definition, _except_ for the + * default_stderr channel. This case is handled specially so that + * the default logging category can be changed by redefining + * default_stderr. (XXXDCL Though now that I think of it, the default + * logging category can be changed with only one additional function + * call by defining a new channel and then calling isc_log_usechannel() + * for #ISC_LOGCATEGORY_DEFAULT.) + * + *\li Specifying #ISC_LOG_PRINTTIME or #ISC_LOG_PRINTTAG for syslog is allowed, + * but probably not what you wanted to do. + * + * #ISC_LOG_DEBUGONLY will mark the channel as usable only when the + * debug level of the logging context (see isc_log_setdebuglevel) + * is non-zero. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + *\li name is not NULL. + * + *\li type is #ISC_LOG_TOSYSLOG, #ISC_LOG_TOFILE, #ISC_LOG_TOFILEDESC or + * #ISC_LOG_TONULL. + * + *\li destination is not NULL unless type is #ISC_LOG_TONULL. + * + *\li level is >= #ISC_LOG_CRITICAL (the most negative logging level). + * + *\li flags does not include any bits aside from the ISC_LOG_PRINT* bits + * or #ISC_LOG_DEBUGONLY. + * + * Ensures: + *\li #ISC_R_SUCCESS + * A channel with the given name is usable with + * isc_log_usechannel(). + * + *\li #ISC_R_NOMEMORY or #ISC_R_UNEXPECTED + * No additional memory is being used by the logging context. + * Any channel that previously existed with the given name + * is not redefined. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + *\li #ISC_R_UNEXPECTED type was out of range and REQUIRE() + * was disabled. + */ + +isc_result_t +isc_log_usechannel(isc_logconfig_t *lcfg, const char *name, + const isc_logcategory_t *category, + const isc_logmodule_t *module); +/*%< + * Associate a named logging channel with a category and module that + * will use it. + * + * Notes: + *\li The name is searched for linearly in the set of known channel names + * until a match is found. (Note the performance impact of a very large + * number of named channels.) When multiple channels of the same + * name are defined, the most recent definition is found. + * + *\li Specifying a very large number of channels for a category will have + * a moderate impact on performance in isc_log_write(), as each + * call looks up the category for the start of a linked list, which + * it follows all the way to the end to find matching modules. The + * test for matching modules is integral, though. + * + *\li If category is NULL, then the channel is associated with the indicated + * module for all known categories (including the "default" category). + * + *\li If module is NULL, then the channel is associated with every module + * that uses that category. + * + *\li Passing both category and module as NULL would make every log message + * use the indicated channel. + * + * \li Specifying a channel that is #ISC_LOG_TONULL for a category/module pair + * has no effect on any other channels associated with that pair, + * regardless of ordering. Thus you cannot use it to "mask out" one + * category/module pair when you have specified some other channel that + * is also used by that category/module pair. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + *\li category is NULL or has an id that is in the range of known ids. + * + * module is NULL or has an id that is in the range of known ids. + * + * Ensures: + *\li #ISC_R_SUCCESS + * The channel will be used by the indicated category/module + * arguments. + * + *\li #ISC_R_NOMEMORY + * If assignment for a specific category has been requested, + * the channel has not been associated with the indicated + * category/module arguments and no additional memory is + * used by the logging context. + * If assignment for all categories has been requested + * then _some_ may have succeeded (starting with category + * "default" and progressing through the order of categories + * passed to isc_log_registercategories()) and additional memory + * is being used by whatever assignments succeeded. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource limit: Out of memory + */ + +/* Attention: next four comments PRECEED code */ +/*! + * \brief + * Write a message to the log channels. + * + * Notes: + *\li Log messages containing natural language text should be logged with + * isc_log_iwrite() to allow for localization. + * + *\li lctx can be NULL; this is allowed so that programs which use + * libraries that use the ISC logging system are not required to + * also use it. + * + *\li The format argument is a printf(3) string, with additional arguments + * as necessary. + * + * Requires: + *\li lctx is a valid logging context. + * + *\li The category and module arguments must have ids that are in the + * range of known ids, as established by isc_log_registercategories() + * and isc_log_registermodules(). + * + *\li level != #ISC_LOG_DYNAMIC. ISC_LOG_DYNAMIC is used only to define + * channels, and explicit debugging level must be identified for + * isc_log_write() via ISC_LOG_DEBUG(level). + * + *\li format != NULL. + * + * Ensures: + *\li The log message is written to every channel associated with the + * indicated category/module pair. + * + * Returns: + *\li Nothing. Failure to log a message is not construed as a + * meaningful error. + */ +void +isc_log_write(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, ...) + +ISC_FORMAT_PRINTF(5, 6); + +/*% + * Write a message to the log channels. + * + * Notes: + *\li lctx can be NULL; this is allowed so that programs which use + * libraries that use the ISC logging system are not required to + * also use it. + * + *\li The format argument is a printf(3) string, with additional arguments + * as necessary. + * + * Requires: + *\li lctx is a valid logging context. + * + *\li The category and module arguments must have ids that are in the + * range of known ids, as established by isc_log_registercategories() + * and isc_log_registermodules(). + * + *\li level != #ISC_LOG_DYNAMIC. ISC_LOG_DYNAMIC is used only to define + * channels, and explicit debugging level must be identified for + * isc_log_write() via ISC_LOG_DEBUG(level). + * + *\li format != NULL. + * + * Ensures: + *\li The log message is written to every channel associated with the + * indicated category/module pair. + * + * Returns: + *\li Nothing. Failure to log a message is not construed as a + * meaningful error. + */ +void +isc_log_vwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, va_list args) + +ISC_FORMAT_PRINTF(5, 0); + +/*% + * Write a message to the log channels, pruning duplicates that occur within + * a configurable amount of seconds (see isc_log_[sg]etduplicateinterval). + * This function is otherwise identical to isc_log_write(). + */ +void +isc_log_write1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, ...) + +ISC_FORMAT_PRINTF(5, 6); + +/*% + * Write a message to the log channels, pruning duplicates that occur within + * a configurable amount of seconds (see isc_log_[sg]etduplicateinterval). + * This function is otherwise identical to isc_log_vwrite(). + */ +void +isc_log_vwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, + va_list args) + +ISC_FORMAT_PRINTF(5, 0); + +/*% + * These are four internationalized versions of the isc_log_[v]write[1] + * functions. + * + * The only difference is that they take arguments for a message + * catalog, message set, and message number, all immediately preceding the + * format argument. The format argument becomes the default text, a la + * isc_msgcat_get. If the message catalog is NULL, no lookup is attempted + * for a message -- which makes the message set and message number irrelevant, + * and the non-internationalized call should have probably been used instead. + * + * Yes, that means there are now *eight* interfaces to logging a message. + * Sheesh. Make the madness stop! + */ +/*@{*/ +void +isc_log_iwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, ...) +ISC_FORMAT_PRINTF(8, 9); + +void +isc_log_ivwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, va_list args) +ISC_FORMAT_PRINTF(8, 0); + +void +isc_log_iwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, ...) +ISC_FORMAT_PRINTF(8, 9); + +void +isc_log_ivwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *format, va_list args) +ISC_FORMAT_PRINTF(8, 0); +/*@}*/ + +void +isc_log_setdebuglevel(isc_log_t *lctx, unsigned int level); +/*%< + * Set the debugging level used for logging. + * + * Notes: + *\li Setting the debugging level to 0 disables debugging log messages. + * + * Requires: + *\li lctx is a valid logging context. + * + * Ensures: + *\li The debugging level is set to the requested value. + */ + +unsigned int +isc_log_getdebuglevel(isc_log_t *lctx); +/*%< + * Get the current debugging level. + * + * Notes: + *\li This is provided so that a program can have a notion of + * "increment debugging level" or "decrement debugging level" + * without needing to keep track of what the current level is. + * + *\li A return value of 0 indicates that debugging messages are disabled. + * + * Requires: + *\li lctx is a valid logging context. + * + * Ensures: + *\li The current logging debugging level is returned. + */ + +isc_boolean_t +isc_log_wouldlog(isc_log_t *lctx, int level); +/*%< + * Determine whether logging something to 'lctx' at 'level' would + * actually cause something to be logged somewhere. + * + * If #ISC_FALSE is returned, it is guaranteed that nothing would + * be logged, allowing the caller to omit unnecessary + * isc_log_write() calls and possible message preformatting. + */ + +void +isc_log_setduplicateinterval(isc_logconfig_t *lcfg, unsigned int interval); +/*%< + * Set the interval over which duplicate log messages will be ignored + * by isc_log_[v]write1(), in seconds. + * + * Notes: + *\li Increasing the duplicate interval from X to Y will not necessarily + * filter out duplicates of messages logged in Y - X seconds since the + * increase. (Example: Message1 is logged at midnight. Message2 + * is logged at 00:01:00, when the interval is only 30 seconds, causing + * Message1 to be expired from the log message history. Then the interval + * is increased to 3000 (five minutes) and at 00:04:00 Message1 is logged + * again. It will appear the second time even though less than five + * passed since the first occurrence. + * + * Requires: + *\li lctx is a valid logging context. + */ + +unsigned int +isc_log_getduplicateinterval(isc_logconfig_t *lcfg); +/*%< + * Get the current duplicate filtering interval. + * + * Requires: + *\li lctx is a valid logging context. + * + * Returns: + *\li The current duplicate filtering interval. + */ + +isc_result_t +isc_log_settag(isc_logconfig_t *lcfg, const char *tag); +/*%< + * Set the program name or other identifier for #ISC_LOG_PRINTTAG. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + * Notes: + *\li If this function has not set the tag to a non-NULL, non-empty value, + * then the #ISC_LOG_PRINTTAG channel flag will not print anything. + * Unlike some implementations of syslog on Unix systems, you *must* set + * the tag in order to get it logged. It is not implicitly derived from + * the program name (which is pretty impossible to infer portably). + * + *\li Setting the tag to NULL or the empty string will also cause the + * #ISC_LOG_PRINTTAG channel flag to not print anything. If tag equals the + * empty string, calls to isc_log_gettag will return NULL. + * + * Returns: + *\li #ISC_R_SUCCESS Success + *\li #ISC_R_NOMEMORY Resource Limit: Out of memory + * + * XXXDCL when creating a new isc_logconfig_t, it might be nice if the tag + * of the currently active isc_logconfig_t was inherited. this does not + * currently happen. + */ + +char * +isc_log_gettag(isc_logconfig_t *lcfg); +/*%< + * Get the current identifier printed with #ISC_LOG_PRINTTAG. + * + * Requires: + *\li lcfg is a valid logging configuration. + * + * Notes: + *\li Since isc_log_settag() will not associate a zero-length string + * with the logging configuration, attempts to do so will cause + * this function to return NULL. However, a determined programmer + * will observe that (currently) a tag of length greater than zero + * could be set, and then modified to be zero length. + * + * Returns: + *\li A pointer to the current identifier, or NULL if none has been set. + */ + +void +isc_log_opensyslog(const char *tag, int options, int facility); +/*%< + * Initialize syslog logging. + * + * Notes: + *\li XXXDCL NT + * This is currently equivalent to openlog(), but is not going to remain + * that way. In the meantime, the arguments are all identical to + * those used by openlog(3), as follows: + * + * \code + * tag: The string to use in the position of the program + * name in syslog messages. Most (all?) syslogs + * will use basename(argv[0]) if tag is NULL. + * + * options: LOG_CONS, LOG_PID, LOG_NDELAY ... whatever your + * syslog supports. + * + * facility: The default syslog facility. This is irrelevant + * since isc_log_write will ALWAYS use the channel's + * declared facility. + * \endcode + * + *\li Zero effort has been made (yet) to accommodate systems with openlog() + * that only takes two arguments, or to identify valid syslog + * facilities or options for any given architecture. + * + *\li It is necessary to call isc_log_opensyslog() to initialize + * syslogging on machines which do not support network connections to + * syslogd because they require a Unix domain socket to be used. Since + * this is a chore to determine at run-time, it is suggested that it + * always be called by programs using the ISC logging system. + * + * Requires: + *\li Nothing. + * + * Ensures: + *\li openlog() is called to initialize the syslog system. + */ + +void +isc_log_closefilelogs(isc_log_t *lctx); +/*%< + * Close all open files used by #ISC_LOG_TOFILE channels. + * + * Notes: + *\li This function is provided for programs that want to use their own + * log rolling mechanism rather than the one provided internally. + * For example, a program that wanted to keep daily logs would define + * a channel which used #ISC_LOG_ROLLNEVER, then once a day would + * rename the log file and call isc_log_closefilelogs(). + * + *\li #ISC_LOG_TOFILEDESC channels are unaffected. + * + * Requires: + *\li lctx is a valid context. + * + * Ensures: + *\li The open files are closed and will be reopened when they are + * next needed. + */ + +isc_logcategory_t * +isc_log_categorybyname(isc_log_t *lctx, const char *name); +/*%< + * Find a category by its name. + * + * Notes: + *\li The string name of a category is not required to be unique. + * + * Requires: + *\li lctx is a valid context. + *\li name is not NULL. + * + * Returns: + *\li A pointer to the _first_ isc_logcategory_t structure used by "name". + * + *\li NULL if no category exists by that name. + */ + +isc_logmodule_t * +isc_log_modulebyname(isc_log_t *lctx, const char *name); +/*%< + * Find a module by its name. + * + * Notes: + *\li The string name of a module is not required to be unique. + * + * Requires: + *\li lctx is a valid context. + *\li name is not NULL. + * + * Returns: + *\li A pointer to the _first_ isc_logmodule_t structure used by "name". + * + *\li NULL if no module exists by that name. + */ + +void +isc_log_setcontext(isc_log_t *lctx); +/*%< + * Sets the context used by the libisc for logging. + * + * Requires: + *\li lctx be a valid context. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_LOG_H */ diff --git a/contrib/ntp/include/isc/magic.h b/contrib/ntp/lib/isc/include/isc/magic.h similarity index 54% rename from contrib/ntp/include/isc/magic.h rename to contrib/ntp/lib/isc/include/isc/magic.h index ff3df24bd..073de90dc 100644 --- a/contrib/ntp/include/isc/magic.h +++ b/contrib/ntp/lib/isc/include/isc/magic.h @@ -1,34 +1,35 @@ /* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: magic.h,v 1.11 2001/01/09 21:57:10 bwelling Exp $ */ +/* $Id: magic.h,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ #ifndef ISC_MAGIC_H #define ISC_MAGIC_H 1 +/*! \file isc/magic.h */ + typedef struct { unsigned int magic; } isc__magic_t; -/* +/*% * To use this macro the magic number MUST be the first thing in the * structure, and MUST be of type "unsigned int". - * * The intent of this is to allow magic numbers to be checked even though * the object is otherwise opaque. */ diff --git a/contrib/ntp/lib/isc/include/isc/md5.h b/contrib/ntp/lib/isc/include/isc/md5.h new file mode 100644 index 000000000..dfa586d0a --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/md5.h @@ -0,0 +1,83 @@ +/* + * Copyright (C) 2004-2007, 2009, 2010 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: md5.h,v 1.20 2010/01/07 23:48:54 tbox Exp $ */ + +/*! \file isc/md5.h + * \brief This is the header file for the MD5 message-digest algorithm. + * + * The algorithm is due to Ron Rivest. This code was + * written by Colin Plumb in 1993, no copyright is claimed. + * This code is in the public domain; do with it what you wish. + * + * Equivalent code is available from RSA Data Security, Inc. + * This code has been tested against that, and is equivalent, + * except that you don't need to include two pages of legalese + * with every copy. + * + * To compute the message digest of a chunk of bytes, declare an + * MD5Context structure, pass it to MD5Init, call MD5Update as + * needed on buffers full of bytes, and then call MD5Final, which + * will fill a supplied 16-byte array with the digest. + * + * Changed so as no longer to depend on Colin Plumb's `usual.h' + * header definitions; now uses stuff from dpkg's config.h + * - Ian Jackson . + * Still in the public domain. + */ + +#ifndef ISC_MD5_H +#define ISC_MD5_H 1 + +#include +#include +#include + +#define ISC_MD5_DIGESTLENGTH 16U +#define ISC_MD5_BLOCK_LENGTH 64U + +#ifdef ISC_PLATFORM_OPENSSLHASH +#include + +typedef EVP_MD_CTX isc_md5_t; + +#else + +typedef struct { + isc_uint32_t buf[4]; + isc_uint32_t bytes[2]; + isc_uint32_t in[16]; +} isc_md5_t; +#endif + +ISC_LANG_BEGINDECLS + +void +isc_md5_init(isc_md5_t *ctx); + +void +isc_md5_invalidate(isc_md5_t *ctx); + +void +isc_md5_update(isc_md5_t *ctx, const unsigned char *buf, unsigned int len); + +void +isc_md5_final(isc_md5_t *ctx, unsigned char *digest); + +ISC_LANG_ENDDECLS + +#endif /* ISC_MD5_H */ diff --git a/contrib/ntp/lib/isc/include/isc/mem.h b/contrib/ntp/lib/isc/include/isc/mem.h new file mode 100644 index 000000000..5101ea3fe --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/mem.h @@ -0,0 +1,750 @@ +/* + * Copyright (C) 2004-2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_MEM_H +#define ISC_MEM_H 1 + +/*! \file isc/mem.h */ + +#include + +#include +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +#define ISC_MEM_LOWATER 0 +#define ISC_MEM_HIWATER 1 +typedef void (*isc_mem_water_t)(void *, int); + +typedef void * (*isc_memalloc_t)(void *, size_t); +typedef void (*isc_memfree_t)(void *, void *); + +/*% + * Define ISC_MEM_DEBUG=1 to make all functions that free memory + * set the pointer being freed to NULL after being freed. + * This is the default; set ISC_MEM_DEBUG=0 to disable it. + */ +#ifndef ISC_MEM_DEBUG +#define ISC_MEM_DEBUG 1 +#endif + +/*% + * Define ISC_MEM_TRACKLINES=1 to turn on detailed tracing of memory + * allocation and freeing by file and line number. + */ +#ifndef ISC_MEM_TRACKLINES +#define ISC_MEM_TRACKLINES 1 +#endif + +/*% + * Define ISC_MEM_CHECKOVERRUN=1 to turn on checks for using memory outside + * the requested space. This will increase the size of each allocation. + */ +#ifndef ISC_MEM_CHECKOVERRUN +#define ISC_MEM_CHECKOVERRUN 1 +#endif + +/*% + * Define ISC_MEM_FILL=1 to fill each block of memory returned to the system + * with the byte string '0xbe'. This helps track down uninitialized pointers + * and the like. On freeing memory, the space is filled with '0xde' for + * the same reasons. + */ +#ifndef ISC_MEM_FILL +#define ISC_MEM_FILL 1 +#endif + +/*% + * Define ISC_MEMPOOL_NAMES=1 to make memory pools store a symbolic + * name so that the leaking pool can be more readily identified in + * case of a memory leak. + */ +#ifndef ISC_MEMPOOL_NAMES +#define ISC_MEMPOOL_NAMES 1 +#endif + +LIBISC_EXTERNAL_DATA extern unsigned int isc_mem_debugging; +/*@{*/ +#define ISC_MEM_DEBUGTRACE 0x00000001U +#define ISC_MEM_DEBUGRECORD 0x00000002U +#define ISC_MEM_DEBUGUSAGE 0x00000004U +#define ISC_MEM_DEBUGSIZE 0x00000008U +#define ISC_MEM_DEBUGCTX 0x00000010U +#define ISC_MEM_DEBUGALL 0x0000001FU +/*!< + * The variable isc_mem_debugging holds a set of flags for + * turning certain memory debugging options on or off at + * runtime. It is initialized to the value ISC_MEM_DEGBUGGING, + * which is 0 by default but may be overridden at compile time. + * The following flags can be specified: + * + * \li #ISC_MEM_DEBUGTRACE + * Log each allocation and free to isc_lctx. + * + * \li #ISC_MEM_DEBUGRECORD + * Remember each allocation, and match them up on free. + * Crash if a free doesn't match an allocation. + * + * \li #ISC_MEM_DEBUGUSAGE + * If a hi_water mark is set, print the maximum inuse memory + * every time it is raised once it exceeds the hi_water mark. + * + * \li #ISC_MEM_DEBUGSIZE + * Check the size argument being passed to isc_mem_put() matches + * that passed to isc_mem_get(). + * + * \li #ISC_MEM_DEBUGCTX + * Check the mctx argument being passed to isc_mem_put() matches + * that passed to isc_mem_get(). + */ +/*@}*/ + +#if ISC_MEM_TRACKLINES +#define _ISC_MEM_FILELINE , __FILE__, __LINE__ +#define _ISC_MEM_FLARG , const char *, unsigned int +#else +#define _ISC_MEM_FILELINE +#define _ISC_MEM_FLARG +#endif + +/*! + * Define ISC_MEM_USE_INTERNAL_MALLOC=1 to use the internal malloc() + * implementation in preference to the system one. The internal malloc() + * is very space-efficient, and quite fast on uniprocessor systems. It + * performs poorly on multiprocessor machines. + * JT: we can overcome the performance issue on multiprocessor machines + * by carefully separating memory contexts. + */ + +#ifndef ISC_MEM_USE_INTERNAL_MALLOC +#define ISC_MEM_USE_INTERNAL_MALLOC 1 +#endif + +/* + * Flags for isc_mem_create2()calls. + */ +#define ISC_MEMFLAG_NOLOCK 0x00000001 /* no lock is necessary */ +#define ISC_MEMFLAG_INTERNAL 0x00000002 /* use internal malloc */ +#if ISC_MEM_USE_INTERNAL_MALLOC +#define ISC_MEMFLAG_DEFAULT ISC_MEMFLAG_INTERNAL +#else +#define ISC_MEMFLAG_DEFAULT 0 +#endif + + +/*%< + * We use either isc___mem (three underscores) or isc__mem (two) depending on + * whether it's for BIND9's internal purpose (with -DBIND9) or generic export + * library. This condition is generally handled in isc/namespace.h, but for + * Windows it doesn't work if it involves multiple times of macro expansion + * (such as isc_mem to isc__mem then to isc___mem). The following definitions + * are used to work around this portability issue. Right now, we don't support + * the export library for Windows, so we always use the three-underscore + * version. + */ +#ifdef WIN32 +#define ISCMEMFUNC(sfx) isc___mem_ ## sfx +#define ISCMEMPOOLFUNC(sfx) isc___mempool_ ## sfx +#else +#define ISCMEMFUNC(sfx) isc__mem_ ## sfx +#define ISCMEMPOOLFUNC(sfx) isc__mempool_ ## sfx +#endif + +#define isc_mem_get(c, s) ISCMEMFUNC(get)((c), (s) _ISC_MEM_FILELINE) +#define isc_mem_allocate(c, s) ISCMEMFUNC(allocate)((c), (s) _ISC_MEM_FILELINE) +#define isc_mem_reallocate(c, p, s) ISCMEMFUNC(reallocate)((c), (p), (s) _ISC_MEM_FILELINE) +#define isc_mem_strdup(c, p) ISCMEMFUNC(strdup)((c), (p) _ISC_MEM_FILELINE) +#define isc_mempool_get(c) ISCMEMPOOLFUNC(get)((c) _ISC_MEM_FILELINE) + +/*% + * isc_mem_putanddetach() is a convenience function for use where you + * have a structure with an attached memory context. + * + * Given: + * + * \code + * struct { + * ... + * isc_mem_t *mctx; + * ... + * } *ptr; + * + * isc_mem_t *mctx; + * + * isc_mem_putanddetach(&ptr->mctx, ptr, sizeof(*ptr)); + * \endcode + * + * is the equivalent of: + * + * \code + * mctx = NULL; + * isc_mem_attach(ptr->mctx, &mctx); + * isc_mem_detach(&ptr->mctx); + * isc_mem_put(mctx, ptr, sizeof(*ptr)); + * isc_mem_detach(&mctx); + * \endcode + */ + +/*% memory and memory pool methods */ +typedef struct isc_memmethods { + void (*attach)(isc_mem_t *source, isc_mem_t **targetp); + void (*detach)(isc_mem_t **mctxp); + void (*destroy)(isc_mem_t **mctxp); + void *(*memget)(isc_mem_t *mctx, size_t size _ISC_MEM_FLARG); + void (*memput)(isc_mem_t *mctx, void *ptr, size_t size _ISC_MEM_FLARG); + void (*memputanddetach)(isc_mem_t **mctxp, void *ptr, + size_t size _ISC_MEM_FLARG); + void *(*memallocate)(isc_mem_t *mctx, size_t size _ISC_MEM_FLARG); + void *(*memreallocate)(isc_mem_t *mctx, void *ptr, + size_t size _ISC_MEM_FLARG); + char *(*memstrdup)(isc_mem_t *mctx, const char *s _ISC_MEM_FLARG); + void (*memfree)(isc_mem_t *mctx, void *ptr _ISC_MEM_FLARG); + void (*setdestroycheck)(isc_mem_t *mctx, isc_boolean_t flag); + void (*setwater)(isc_mem_t *ctx, isc_mem_water_t water, + void *water_arg, size_t hiwater, size_t lowater); + void (*waterack)(isc_mem_t *ctx, int flag); + size_t (*inuse)(isc_mem_t *mctx); + isc_boolean_t (*isovermem)(isc_mem_t *mctx); + isc_result_t (*mpcreate)(isc_mem_t *mctx, size_t size, + isc_mempool_t **mpctxp); +} isc_memmethods_t; + +typedef struct isc_mempoolmethods { + void (*destroy)(isc_mempool_t **mpctxp); + void *(*get)(isc_mempool_t *mpctx _ISC_MEM_FLARG); + void (*put)(isc_mempool_t *mpctx, void *mem _ISC_MEM_FLARG); + unsigned int (*getallocated)(isc_mempool_t *mpctx); + void (*setmaxalloc)(isc_mempool_t *mpctx, unsigned int limit); + void (*setfreemax)(isc_mempool_t *mpctx, unsigned int limit); + void (*setname)(isc_mempool_t *mpctx, const char *name); + void (*associatelock)(isc_mempool_t *mpctx, isc_mutex_t *lock); + void (*setfillcount)(isc_mempool_t *mpctx, unsigned int limit); +} isc_mempoolmethods_t; + +/*% + * This structure is actually just the common prefix of a memory context + * implementation's version of an isc_mem_t. + * \brief + * Direct use of this structure by clients is forbidden. mctx implementations + * may change the structure. 'magic' must be ISCAPI_MCTX_MAGIC for any of the + * isc_mem_ routines to work. mctx implementations must maintain all mctx + * invariants. + */ +struct isc_mem { + unsigned int impmagic; + unsigned int magic; + isc_memmethods_t *methods; +}; + +#define ISCAPI_MCTX_MAGIC ISC_MAGIC('A','m','c','x') +#define ISCAPI_MCTX_VALID(m) ((m) != NULL && \ + (m)->magic == ISCAPI_MCTX_MAGIC) + +/*% + * This is the common prefix of a memory pool context. The same note as + * that for the mem structure applies. + */ +struct isc_mempool { + unsigned int impmagic; + unsigned int magic; + isc_mempoolmethods_t *methods; +}; + +#define ISCAPI_MPOOL_MAGIC ISC_MAGIC('A','m','p','l') +#define ISCAPI_MPOOL_VALID(mp) ((mp) != NULL && \ + (mp)->magic == ISCAPI_MPOOL_MAGIC) + +#if ISC_MEM_DEBUG +#define isc_mem_put(c, p, s) \ + do { \ + ISCMEMFUNC(put)((c), (p), (s) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#define isc_mem_putanddetach(c, p, s) \ + do { \ + ISCMEMFUNC(putanddetach)((c), (p), (s) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#define isc_mem_free(c, p) \ + do { \ + ISCMEMFUNC(free)((c), (p) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#define isc_mempool_put(c, p) \ + do { \ + ISCMEMPOOLFUNC(put)((c), (p) _ISC_MEM_FILELINE); \ + (p) = NULL; \ + } while (0) +#else +#define isc_mem_put(c, p, s) ISCMEMFUNC(put)((c), (p), (s) _ISC_MEM_FILELINE) +#define isc_mem_putanddetach(c, p, s) \ + ISCMEMFUNC(putanddetach)((c), (p), (s) _ISC_MEM_FILELINE) +#define isc_mem_free(c, p) ISCMEMFUNC(free)((c), (p) _ISC_MEM_FILELINE) +#define isc_mempool_put(c, p) ISCMEMPOOLFUNC(put)((c), (p) _ISC_MEM_FILELINE) +#endif + +/*@{*/ +isc_result_t +isc_mem_create(size_t max_size, size_t target_size, + isc_mem_t **mctxp); + +isc_result_t +isc_mem_create2(size_t max_size, size_t target_size, + isc_mem_t **mctxp, unsigned int flags); + +isc_result_t +isc_mem_createx(size_t max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, + void *arg, isc_mem_t **mctxp); + +isc_result_t +isc_mem_createx2(size_t max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, + void *arg, isc_mem_t **mctxp, unsigned int flags); + +/*!< + * \brief Create a memory context. + * + * 'max_size' and 'target_size' are tuning parameters. When + * ISC_MEMFLAG_INTERNAL is set, allocations smaller than 'max_size' + * will be satisfied by getting blocks of size 'target_size' from the + * system allocator and breaking them up into pieces; larger allocations + * will use the system allocator directly. If 'max_size' and/or + * 'target_size' are zero, default values will be * used. When + * ISC_MEMFLAG_INTERNAL is not set, 'target_size' is ignored. + * + * 'max_size' is also used to size the statistics arrays and the array + * used to record active memory when ISC_MEM_DEBUGRECORD is set. Setting + * 'max_size' too low can have detrimental effects on performance. + * + * A memory context created using isc_mem_createx() will obtain + * memory from the system by calling 'memalloc' and 'memfree', + * passing them the argument 'arg'. A memory context created + * using isc_mem_create() will use the standard library malloc() + * and free(). + * + * If ISC_MEMFLAG_NOLOCK is set in 'flags', the corresponding memory context + * will be accessed without locking. The user who creates the context must + * ensure there be no race. Since this can be a source of bug, it is generally + * inadvisable to use this flag unless the user is very sure about the race + * condition and the access to the object is highly performance sensitive. + * + * Requires: + * mctxp != NULL && *mctxp == NULL */ +/*@}*/ + +/*@{*/ +void +isc_mem_attach(isc_mem_t *, isc_mem_t **); +void +isc_mem_detach(isc_mem_t **); +/*!< + * \brief Attach to / detach from a memory context. + * + * This is intended for applications that use multiple memory contexts + * in such a way that it is not obvious when the last allocations from + * a given context has been freed and destroying the context is safe. + * + * Most applications do not need to call these functions as they can + * simply create a single memory context at the beginning of main() + * and destroy it at the end of main(), thereby guaranteeing that it + * is not destroyed while there are outstanding allocations. + */ +/*@}*/ + +void +isc_mem_destroy(isc_mem_t **); +/*%< + * Destroy a memory context. + */ + +isc_result_t +isc_mem_ondestroy(isc_mem_t *ctx, + isc_task_t *task, + isc_event_t **event); +/*%< + * Request to be notified with an event when a memory context has + * been successfully destroyed. + */ + +void +isc_mem_stats(isc_mem_t *mctx, FILE *out); +/*%< + * Print memory usage statistics for 'mctx' on the stream 'out'. + */ + +void +isc_mem_setdestroycheck(isc_mem_t *mctx, + isc_boolean_t on); +/*%< + * If 'on' is ISC_TRUE, 'mctx' will check for memory leaks when + * destroyed and abort the program if any are present. + */ + +/*@{*/ +void +isc_mem_setquota(isc_mem_t *, size_t); +size_t +isc_mem_getquota(isc_mem_t *); +/*%< + * Set/get the memory quota of 'mctx'. This is a hard limit + * on the amount of memory that may be allocated from mctx; + * if it is exceeded, allocations will fail. + */ +/*@}*/ + +size_t +isc_mem_inuse(isc_mem_t *mctx); +/*%< + * Get an estimate of the number of memory in use in 'mctx', in bytes. + * This includes quantization overhead, but does not include memory + * allocated from the system but not yet used. + */ + +isc_boolean_t +isc_mem_isovermem(isc_mem_t *mctx); +/*%< + * Return true iff the memory context is in "over memory" state, i.e., + * a hiwater mark has been set and the used amount of memory has exceeds + * the mark. + */ + +void +isc_mem_setwater(isc_mem_t *mctx, isc_mem_water_t water, void *water_arg, + size_t hiwater, size_t lowater); +/*%< + * Set high and low water marks for this memory context. + * + * When the memory usage of 'mctx' exceeds 'hiwater', + * '(water)(water_arg, #ISC_MEM_HIWATER)' will be called. 'water' needs to + * call isc_mem_waterack() with #ISC_MEM_HIWATER to acknowledge the state + * change. 'water' may be called multiple times. + * + * When the usage drops below 'lowater', 'water' will again be called, this + * time with #ISC_MEM_LOWATER. 'water' need to calls isc_mem_waterack() with + * #ISC_MEM_LOWATER to acknowledge the change. + * + * static void + * water(void *arg, int mark) { + * struct foo *foo = arg; + * + * LOCK(&foo->marklock); + * if (foo->mark != mark) { + * foo->mark = mark; + * .... + * isc_mem_waterack(foo->mctx, mark); + * } + * UNLOCK(&foo->marklock); + * } + * + * If 'water' is NULL then 'water_arg', 'hi_water' and 'lo_water' are + * ignored and the state is reset. + * + * Requires: + * + * 'water' is not NULL. + * hi_water >= lo_water + */ + +void +isc_mem_waterack(isc_mem_t *ctx, int mark); +/*%< + * Called to acknowledge changes in signaled by calls to 'water'. + */ + +void +isc_mem_printactive(isc_mem_t *mctx, FILE *file); +/*%< + * Print to 'file' all active memory in 'mctx'. + * + * Requires ISC_MEM_DEBUGRECORD to have been set. + */ + +void +isc_mem_printallactive(FILE *file); +/*%< + * Print to 'file' all active memory in all contexts. + * + * Requires ISC_MEM_DEBUGRECORD to have been set. + */ + +void +isc_mem_checkdestroyed(FILE *file); +/*%< + * Check that all memory contexts have been destroyed. + * Prints out those that have not been. + * Fatally fails if there are still active contexts. + */ + +unsigned int +isc_mem_references(isc_mem_t *ctx); +/*%< + * Return the current reference count. + */ + +void +isc_mem_setname(isc_mem_t *ctx, const char *name, void *tag); +/*%< + * Name 'ctx'. + * + * Notes: + * + *\li Only the first 15 characters of 'name' will be copied. + * + *\li 'tag' is for debugging purposes only. + * + * Requires: + * + *\li 'ctx' is a valid ctx. + */ + +const char * +isc_mem_getname(isc_mem_t *ctx); +/*%< + * Get the name of 'ctx', as previously set using isc_mem_setname(). + * + * Requires: + *\li 'ctx' is a valid ctx. + * + * Returns: + *\li A non-NULL pointer to a null-terminated string. + * If the ctx has not been named, the string is + * empty. + */ + +void * +isc_mem_gettag(isc_mem_t *ctx); +/*%< + * Get the tag value for 'task', as previously set using isc_mem_setname(). + * + * Requires: + *\li 'ctx' is a valid ctx. + * + * Notes: + *\li This function is for debugging purposes only. + * + * Requires: + *\li 'ctx' is a valid task. + */ + +#ifdef HAVE_LIBXML2 +void +isc_mem_renderxml(xmlTextWriterPtr writer); +/*%< + * Render all contexts' statistics and status in XML for writer. + */ +#endif /* HAVE_LIBXML2 */ + +/* + * Memory pools + */ + +isc_result_t +isc_mempool_create(isc_mem_t *mctx, size_t size, isc_mempool_t **mpctxp); +/*%< + * Create a memory pool. + * + * Requires: + *\li mctx is a valid memory context. + *\li size > 0 + *\li mpctxp != NULL and *mpctxp == NULL + * + * Defaults: + *\li maxalloc = UINT_MAX + *\li freemax = 1 + *\li fillcount = 1 + * + * Returns: + *\li #ISC_R_NOMEMORY -- not enough memory to create pool + *\li #ISC_R_SUCCESS -- all is well. + */ + +void +isc_mempool_destroy(isc_mempool_t **mpctxp); +/*%< + * Destroy a memory pool. + * + * Requires: + *\li mpctxp != NULL && *mpctxp is a valid pool. + *\li The pool has no un"put" allocations outstanding + */ + +void +isc_mempool_setname(isc_mempool_t *mpctx, const char *name); +/*%< + * Associate a name with a memory pool. At most 15 characters may be used. + * + * Requires: + *\li mpctx is a valid pool. + *\li name != NULL; + */ + +void +isc_mempool_associatelock(isc_mempool_t *mpctx, isc_mutex_t *lock); +/*%< + * Associate a lock with this memory pool. + * + * This lock is used when getting or putting items using this memory pool, + * and it is also used to set or get internal state via the isc_mempool_get*() + * and isc_mempool_set*() set of functions. + * + * Multiple pools can each share a single lock. For instance, if "manager" + * type object contained pools for various sizes of events, and each of + * these pools used a common lock. Note that this lock must NEVER be used + * by other than mempool routines once it is given to a pool, since that can + * easily cause double locking. + * + * Requires: + * + *\li mpctpx is a valid pool. + * + *\li lock != NULL. + * + *\li No previous lock is assigned to this pool. + * + *\li The lock is initialized before calling this function via the normal + * means of doing that. + */ + +/* + * The following functions get/set various parameters. Note that due to + * the unlocked nature of pools these are potentially random values unless + * the imposed externally provided locking protocols are followed. + * + * Also note that the quota limits will not always take immediate effect. + * For instance, setting "maxalloc" to a number smaller than the currently + * allocated count is permitted. New allocations will be refused until + * the count drops below this threshold. + * + * All functions require (in addition to other requirements): + * mpctx is a valid memory pool + */ + +unsigned int +isc_mempool_getfreemax(isc_mempool_t *mpctx); +/*%< + * Returns the maximum allowed size of the free list. + */ + +void +isc_mempool_setfreemax(isc_mempool_t *mpctx, unsigned int limit); +/*%< + * Sets the maximum allowed size of the free list. + */ + +unsigned int +isc_mempool_getfreecount(isc_mempool_t *mpctx); +/*%< + * Returns current size of the free list. + */ + +unsigned int +isc_mempool_getmaxalloc(isc_mempool_t *mpctx); +/*!< + * Returns the maximum allowed number of allocations. + */ + +void +isc_mempool_setmaxalloc(isc_mempool_t *mpctx, unsigned int limit); +/*%< + * Sets the maximum allowed number of allocations. + * + * Additional requirements: + *\li limit > 0 + */ + +unsigned int +isc_mempool_getallocated(isc_mempool_t *mpctx); +/*%< + * Returns the number of items allocated from this pool. + */ + +unsigned int +isc_mempool_getfillcount(isc_mempool_t *mpctx); +/*%< + * Returns the number of items allocated as a block from the parent memory + * context when the free list is empty. + */ + +void +isc_mempool_setfillcount(isc_mempool_t *mpctx, unsigned int limit); +/*%< + * Sets the fillcount. + * + * Additional requirements: + *\li limit > 0 + */ + + +/* + * Pseudo-private functions for use via macros. Do not call directly. + */ +void * +ISCMEMFUNC(get)(isc_mem_t *, size_t _ISC_MEM_FLARG); +void +ISCMEMFUNC(putanddetach)(isc_mem_t **, void *, size_t _ISC_MEM_FLARG); +void +ISCMEMFUNC(put)(isc_mem_t *, void *, size_t _ISC_MEM_FLARG); +void * +ISCMEMFUNC(allocate)(isc_mem_t *, size_t _ISC_MEM_FLARG); +void * +ISCMEMFUNC(reallocate)(isc_mem_t *, void *, size_t _ISC_MEM_FLARG); +void +ISCMEMFUNC(free)(isc_mem_t *, void * _ISC_MEM_FLARG); +char * +ISCMEMFUNC(strdup)(isc_mem_t *, const char *_ISC_MEM_FLARG); +void * +ISCMEMPOOLFUNC(get)(isc_mempool_t * _ISC_MEM_FLARG); +void +ISCMEMPOOLFUNC(put)(isc_mempool_t *, void * _ISC_MEM_FLARG); + +#ifdef USE_MEMIMPREGISTER + +/*%< + * See isc_mem_create2() above. + */ +typedef isc_result_t +(*isc_memcreatefunc_t)(size_t init_max_size, size_t target_size, + isc_mem_t **ctxp, unsigned int flags); + +isc_result_t +isc_mem_register(isc_memcreatefunc_t createfunc); +/*%< + * Register a new memory management implementation and add it to the list of + * supported implementations. This function must be called when a different + * memory management library is used than the one contained in the ISC library. + */ + +isc_result_t +isc__mem_register(void); +/*%< + * A short cut function that specifies the memory management module in the ISC + * library for isc_mem_register(). An application that uses the ISC library + * usually do not have to care about this function: it would call + * isc_lib_register(), which internally calls this function. + */ +#endif /* USE_MEMIMPREGISTER */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_MEM_H */ diff --git a/contrib/ntp/include/isc/msgcat.h b/contrib/ntp/lib/isc/include/isc/msgcat.h similarity index 54% rename from contrib/ntp/include/isc/msgcat.h rename to contrib/ntp/lib/isc/include/isc/msgcat.h index d2bf1e162..fe3d33682 100644 --- a/contrib/ntp/include/isc/msgcat.h +++ b/contrib/ntp/lib/isc/include/isc/msgcat.h @@ -1,21 +1,21 @@ /* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: msgcat.h,v 1.8 2001/01/09 21:57:13 bwelling Exp $ */ +/* $Id: msgcat.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ #ifndef ISC_MSGCAT_H #define ISC_MSGCAT_H 1 @@ -24,34 +24,33 @@ ***** Module Info *****/ -/* - * ISC Message Catalog - * - * Message catalogs aid internationalization of applications by allowing +/*! \file isc/msgcat.h + * \brief The ISC Message Catalog + * aids internationalization of applications by allowing * messages to be retrieved from locale-specific files instead of * hardwiring them into the application. This allows translations of * messages appropriate to the locale to be supplied without recompiling * the application. * * Notes: - * It's very important that message catalogs work, even if only the + *\li It's very important that message catalogs work, even if only the * default_text can be used. * * MP: - * The caller must ensure appropriate synchronization of + *\li The caller must ensure appropriate synchronization of * isc_msgcat_open() and isc_msgcat_close(). isc_msgcat_get() * ensures appropriate synchronization. * * Reliability: - * No anticipated impact. + *\li No anticipated impact. * * Resources: - * + *\li TBS * - * Security: + * \li Security: * No anticipated impact. * - * Standards: + * \li Standards: * None. */ @@ -70,61 +69,61 @@ ISC_LANG_BEGINDECLS void isc_msgcat_open(const char *name, isc_msgcat_t **msgcatp); -/* +/*%< * Open a message catalog. * * Notes: * - * If memory cannot be allocated or other failures occur, *msgcatp + *\li If memory cannot be allocated or other failures occur, *msgcatp * will be set to NULL. If a NULL msgcat is given to isc_msgcat_get(), * the default_text will be returned, ensuring that some message text * will be available, no matter what's going wrong. * * Requires: * - * 'name' is a valid string. + *\li 'name' is a valid string. * - * msgcatp != NULL && *msgcatp == NULL + *\li msgcatp != NULL && *msgcatp == NULL */ void isc_msgcat_close(isc_msgcat_t **msgcatp); -/* +/*%< * Close a message catalog. * * Notes: * - * Any string pointers returned by prior calls to isc_msgcat_get() are + *\li Any string pointers returned by prior calls to isc_msgcat_get() are * invalid after isc_msgcat_close() has been called and must not be * used. * * Requires: * - * *msgcatp is a valid message catalog or is NULL. + *\li *msgcatp is a valid message catalog or is NULL. * * Ensures: * - * All resources associated with the message catalog are released. + *\li All resources associated with the message catalog are released. * - * *msgcatp == NULL + *\li *msgcatp == NULL */ const char * isc_msgcat_get(isc_msgcat_t *msgcat, int set, int message, const char *default_text); -/* +/*%< * Get message 'message' from message set 'set' in 'msgcat'. If it * is not available, use 'default_text'. * * Requires: * - * 'msgcat' is a valid message catalog or is NULL. + *\li 'msgcat' is a valid message catalog or is NULL. * - * set > 0 + *\li set > 0 * - * message > 0 + *\li message > 0 * - * 'default_text' is a valid string. + *\li 'default_text' is a valid string. */ ISC_LANG_ENDDECLS diff --git a/contrib/ntp/lib/isc/include/isc/msgs.h b/contrib/ntp/lib/isc/include/isc/msgs.h new file mode 100644 index 000000000..60c5c7caf --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/msgs.h @@ -0,0 +1,195 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: msgs.h,v 1.19 2009/10/01 23:48:08 tbox Exp $ */ + +#ifndef ISC_MSGS_H +#define ISC_MSGS_H 1 + +/*! \file isc/msgs.h */ + +#include /* Provide isc_msgcat global variable. */ +#include /* Provide isc_msgcat_*() functions. */ + +/*@{*/ +/*! + * \brief Message sets, named per source file, excepting "GENERAL". + * + * IMPORTANT: The original list is alphabetical, but any new sets must + * be added to the end. + */ +#define ISC_MSGSET_GENERAL 1 +/* ISC_RESULT_RESULTSET 2 */ /* XXX */ +/* ISC_RESULT_UNAVAILABLESET 3 */ /* XXX */ +#define ISC_MSGSET_APP 4 +#define ISC_MSGSET_COMMANDLINE 5 +#define ISC_MSGSET_ENTROPY 6 +#define ISC_MSGSET_IFITERIOCTL 7 +#define ISC_MSGSET_IFITERSYSCTL 8 +#define ISC_MSGSET_LEX 9 +#define ISC_MSGSET_LOG 10 +#define ISC_MSGSET_MEM 11 +#define ISC_MSGSET_NETADDR 12 +#define ISC_MSGSET_PRINT 13 +#define ISC_MSGSET_RESULT 14 +#define ISC_MSGSET_RWLOCK 15 +#define ISC_MSGSET_SOCKADDR 16 +#define ISC_MSGSET_SOCKET 17 +#define ISC_MSGSET_TASK 18 +#define ISC_MSGSET_TIMER 19 +#define ISC_MSGSET_UTIL 20 +#define ISC_MSGSET_IFITERGETIFADDRS 21 +/*@}*/ + +/*@{*/ +/*! + * Message numbers + * are only required to be unique per message set, + * but are unique throughout the entire catalog to not be as confusing when + * debugging. + * + * The initial numbering was done by multiply by 100 the set number the + * message appears in then adding the incremental message number. + */ +#define ISC_MSG_FAILED 101 /*%< "failed" */ +#define ISC_MSG_SUCCEEDED 102 /*%< Compatible with "failed" */ +#define ISC_MSG_SUCCESS 103 /*%< More usual way to say "success" */ +#define ISC_MSG_STARTING 104 /*%< As in "daemon: starting" */ +#define ISC_MSG_STOPING 105 /*%< As in "daemon: stopping" */ +#define ISC_MSG_ENTERING 106 /*%< As in "some_subr: entering" */ +#define ISC_MSG_EXITING 107 /*%< As in "some_subr: exiting" */ +#define ISC_MSG_CALLING 108 /*%< As in "calling some_subr()" */ +#define ISC_MSG_RETURNED 109 /*%< As in "some_subr: returned " */ +#define ISC_MSG_FATALERROR 110 /*%< "fatal error" */ +#define ISC_MSG_SHUTTINGDOWN 111 /*%< "shutting down" */ +#define ISC_MSG_RUNNING 112 /*%< "running" */ +#define ISC_MSG_WAIT 113 /*%< "wait" */ +#define ISC_MSG_WAITUNTIL 114 /*%< "waituntil" */ + +#define ISC_MSG_SIGNALSETUP 201 /*%< "handle_signal() %d setup: %s" */ + +#define ISC_MSG_ILLEGALOPT 301 /*%< "illegal option" */ +#define ISC_MSG_OPTNEEDARG 302 /*%< "option requires an argument" */ + +#define ISC_MSG_ENTROPYSTATS 401 /*%< "Entropy pool %p: refcnt %u ..." */ + +#define ISC_MSG_MAKESCANSOCKET 501 /*%< "making interface scan socket: %s" */ +#define ISC_MSG_GETIFCONFIG 502 /*%< "get interface configuration: %s" */ +#define ISC_MSG_BUFFERMAX 503 /*%< "... maximum buffer size exceeded" */ +#define ISC_MSG_GETDESTADDR 504 /*%< "%s: getting destination address: %s" */ +#define ISC_MSG_GETNETMASK 505 /*%< "%s: getting netmask: %s" */ +#define ISC_MSG_GETBCSTADDR 506 /*%< "%s: getting broadcast address: %s" */ + +#define ISC_MSG_GETIFLISTSIZE 601 /*%< "getting interface list size: ..." */ +#define ISC_MSG_GETIFLIST 602 /*%< "getting interface list: ..." */ +#define ISC_MSG_UNEXPECTEDTYPE 603 /*%< "... unexpected ... message type" */ + +#define ISC_MSG_UNEXPECTEDSTATE 701 /*%< "Unexpected state %d" */ + +#define ISC_MSG_BADTIME 801 /*%< "Bad 00 99:99:99.999 " */ +#define ISC_MSG_LEVEL 802 /*%< "level %d: " */ + +#define ISC_MSG_ADDTRACE 901 /*%< "add %p size %u " */ +#define ISC_MSG_DELTRACE 902 /*%< "del %p size %u " */ +#define ISC_MSG_POOLSTATS 903 /*%< "[Pool statistics]\n" */ +#define ISC_MSG_POOLNAME 904 /*%< "name" */ +#define ISC_MSG_POOLSIZE 905 /*%< "size" */ +#define ISC_MSG_POOLMAXALLOC 906 /*%< "maxalloc" */ +#define ISC_MSG_POOLALLOCATED 907 /*%< "allocated" */ +#define ISC_MSG_POOLFREECOUNT 908 /*%< "freecount" */ +#define ISC_MSG_POOLFREEMAX 909 /*%< "freemax" */ +#define ISC_MSG_POOLFILLCOUNT 910 /*%< "fillcount" */ +#define ISC_MSG_POOLGETS 911 /*%< "gets" */ +#define ISC_MSG_DUMPALLOC 912 /*%< "DUMP OF ALL OUTSTANDING MEMORY ..." */ +#define ISC_MSG_NONE 913 /*%< "\tNone.\n" */ +#define ISC_MSG_PTRFILELINE 914 /*%< "\tptr %p file %s line %u\n" */ + +#define ISC_MSG_UNKNOWNADDR 1001 /*%< "" */ + +#define ISC_MSG_NOLONGDBL 1104 /*%< "long doubles are not supported" */ + +#define ISC_MSG_PRINTLOCK 1201 /*%< "rwlock %p thread %lu ..." */ +#define ISC_MSG_READ 1202 /*%< "read" */ +#define ISC_MSG_WRITE 1203 /*%< "write" */ +#define ISC_MSG_READING 1204 /*%< "reading" */ +#define ISC_MSG_WRITING 1205 /*%< "writing" */ +#define ISC_MSG_PRELOCK 1206 /*%< "prelock" */ +#define ISC_MSG_POSTLOCK 1207 /*%< "postlock" */ +#define ISC_MSG_PREUNLOCK 1208 /*%< "preunlock" */ +#define ISC_MSG_POSTUNLOCK 1209 /*%< "postunlock" */ + +#define ISC_MSG_UNKNOWNFAMILY 1301 /*%< "unknown address family: %d" */ + +#define ISC_MSG_WRITEFAILED 1401 /*%< "write() failed during watcher ..." */ +#define ISC_MSG_READFAILED 1402 /*%< "read() failed during watcher ... " */ +#define ISC_MSG_PROCESSCMSG 1403 /*%< "processing cmsg %p" */ +#define ISC_MSG_IFRECEIVED 1404 /*%< "interface received on ifindex %u" */ +#define ISC_MSG_SENDTODATA 1405 /*%< "sendto pktinfo data, ifindex %u" */ +#define ISC_MSG_DOIORECV 1406 /*%< "doio_recv: recvmsg(%d) %d bytes ..." */ +#define ISC_MSG_PKTRECV 1407 /*%< "packet received correctly" */ +#define ISC_MSG_DESTROYING 1408 /*%< "destroying" */ +#define ISC_MSG_CREATED 1409 /*%< "created" */ +#define ISC_MSG_ACCEPTLOCK 1410 /*%< "internal_accept called, locked ..." */ +#define ISC_MSG_ACCEPTEDCXN 1411 /*%< "accepted connection, new socket %p" */ +#define ISC_MSG_INTERNALRECV 1412 /*%< "internal_recv: task %p got event %p" */ +#define ISC_MSG_INTERNALSEND 1413 /*%< "internal_send: task %p got event %p" */ +#define ISC_MSG_WATCHERMSG 1414 /*%< "watcher got message %d" */ +#define ISC_MSG_SOCKETSREMAIN 1415 /*%< "sockets exist" */ +#define ISC_MSG_PKTINFOPROVIDED 1416 /*%< "pktinfo structure provided, ..." */ +#define ISC_MSG_BOUND 1417 /*%< "bound" */ +#define ISC_MSG_ACCEPTRETURNED 1418 /*%< accept() returned %d/%s */ +#define ISC_MSG_TOOMANYFDS 1419 /*%< %s: too many open file descriptors */ +#define ISC_MSG_ZEROPORT 1420 /*%< dropping source port zero packet */ +#define ISC_MSG_FILTER 1421 /*%< setsockopt(SO_ACCEPTFILTER): %s */ + +#define ISC_MSG_TOOMANYHANDLES 1422 /*%< %s: too many open WSA event handles: %s */ +#define ISC_MSG_POKED 1423 /*%< "poked flags: %d" */ + +#define ISC_MSG_AWAKE 1502 /*%< "awake" */ +#define ISC_MSG_WORKING 1503 /*%< "working" */ +#define ISC_MSG_EXECUTE 1504 /*%< "execute action" */ +#define ISC_MSG_EMPTY 1505 /*%< "empty" */ +#define ISC_MSG_DONE 1506 /*%< "done" */ +#define ISC_MSG_QUANTUM 1507 /*%< "quantum" */ + +#define ISC_MSG_SCHEDULE 1601 /*%< "schedule" */ +#define ISC_MSG_SIGNALSCHED 1602 /*%< "signal (schedule)" */ +#define ISC_MSG_SIGNALDESCHED 1603 /*%< "signal (deschedule)" */ +#define ISC_MSG_SIGNALDESTROY 1604 /*%< "signal (destroy)" */ +#define ISC_MSG_IDLERESCHED 1605 /*%< "idle reschedule" */ +#define ISC_MSG_EVENTNOTALLOC 1606 /*%< "couldn't allocate event" */ +#define ISC_MSG_SCHEDFAIL 1607 /*%< "couldn't schedule timer: %u" */ +#define ISC_MSG_POSTING 1608 /*%< "posting" */ +#define ISC_MSG_WAKEUP 1609 /*%< "wakeup" */ + +#define ISC_MSG_LOCK 1701 /*%< "LOCK" */ +#define ISC_MSG_LOCKING 1702 /*%< "LOCKING" */ +#define ISC_MSG_LOCKED 1703 /*%< "LOCKED" */ +#define ISC_MSG_UNLOCKED 1704 /*%< "UNLOCKED" */ +#define ISC_MSG_RWLOCK 1705 /*%< "RWLOCK" */ +#define ISC_MSG_RWLOCKED 1706 /*%< "RWLOCKED" */ +#define ISC_MSG_RWUNLOCK 1707 /*%< "RWUNLOCK" */ +#define ISC_MSG_BROADCAST 1708 /*%< "BROADCAST" */ +#define ISC_MSG_SIGNAL 1709 /*%< "SIGNAL" */ +#define ISC_MSG_UTILWAIT 1710 /*%< "WAIT" */ +#define ISC_MSG_WAITED 1711 /*%< "WAITED" */ + +#define ISC_MSG_GETIFADDRS 1801 /*%< "getting interface addresses: ..." */ + +/*@}*/ + +#endif /* ISC_MSGS_H */ diff --git a/contrib/ntp/lib/isc/include/isc/mutexblock.h b/contrib/ntp/lib/isc/include/isc/mutexblock.h new file mode 100644 index 000000000..65bf2bf27 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/mutexblock.h @@ -0,0 +1,71 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutexblock.h,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_MUTEXBLOCK_H +#define ISC_MUTEXBLOCK_H 1 + +/*! \file isc/mutexblock.h */ + +#include +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_mutexblock_init(isc_mutex_t *block, unsigned int count); +/*%< + * Initialize a block of locks. If an error occurs all initialized locks + * will be destroyed, if possible. + * + * Requires: + * + *\li block != NULL + * + *\li count > 0 + * + * Returns: + * + *\li Any code isc_mutex_init() can return is a valid return for this + * function. + */ + +isc_result_t +isc_mutexblock_destroy(isc_mutex_t *block, unsigned int count); +/*%< + * Destroy a block of locks. + * + * Requires: + * + *\li block != NULL + * + *\li count > 0 + * + *\li Each lock in the block be initialized via isc_mutex_init() or + * the whole block was initialized via isc_mutex_initblock(). + * + * Returns: + * + *\li Any code isc_mutex_init() can return is a valid return for this + * function. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_MUTEXBLOCK_H */ diff --git a/contrib/ntp/lib/isc/include/isc/namespace.h b/contrib/ntp/lib/isc/include/isc/namespace.h new file mode 100644 index 000000000..cd4ec9ad1 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/namespace.h @@ -0,0 +1,171 @@ +/* + * Copyright (C) 2009-2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISCAPI_NAMESPACE_H +#define ISCAPI_NAMESPACE_H 1 + +/*% + * name space conversions + */ + +#ifdef BIND9 + +#define isc_app_start isc__app_start +#define isc_app_ctxstart isc__app_ctxstart +#define isc_app_onrun isc__app_onrun +#define isc_app_run isc__app_run +#define isc_app_ctxrun isc__app_ctxrun +#define isc_app_shutdown isc__app_shutdown +#define isc_app_ctxfinish isc__app_ctxfinish +#define isc_app_ctxshutdown isc__app_ctxshutdown +#define isc_app_ctxsuspend isc__app_ctxsuspend +#define isc_app_reload isc__app_reload +#define isc_app_finish isc__app_finish +#define isc_app_block isc__app_block +#define isc_app_unblock isc__app_unblock +#define isc_appctx_create isc__appctx_create +#define isc_appctx_destroy isc__appctx_destroy +#define isc_appctx_settaskmgr isc__appctx_settaskmgr +#define isc_appctx_setsocketmgr isc__appctx_setsocketmgr +#define isc_appctx_settimermgr isc__appctx_settimermgr + +#define isc_mem_checkdestroyed isc__mem_checkdestroyed +#define isc_mem_createx isc__mem_createx +#define isc_mem_createx2 isc__mem_createx2 +#define isc_mem_create isc__mem_create +#define isc_mem_create2 isc__mem_create2 +#define isc_mem_attach isc__mem_attach +#define isc_mem_detach isc__mem_detach +#define isc__mem_putanddetach isc___mem_putanddetach +#define isc_mem_destroy isc__mem_destroy +#define isc_mem_ondestroy isc__mem_ondestroy +#define isc__mem_get isc___mem_get +#define isc__mem_put isc___mem_put +#define isc_mem_stats isc__mem_stats +#define isc__mem_allocate isc___mem_allocate +#define isc__mem_free isc___mem_free +#define isc__mem_strdup isc___mem_strdup +#define isc__mem_reallocate isc___mem_reallocate +#define isc_mem_references isc__mem_references +#define isc_mem_setdestroycheck isc__mem_setdestroycheck +#define isc_mem_setquota isc__mem_setquota +#define isc_mem_getname isc__mem_getname +#define isc_mem_getquota isc__mem_getquota +#define isc_mem_gettag isc__mem_gettag +#define isc_mem_inuse isc__mem_inuse +#define isc_mem_isovermem isc__mem_isovermem +#define isc_mem_setname isc__mem_setname +#define isc_mem_setwater isc__mem_setwater +#define isc_mem_printallactive isc__mem_printallactive +#define isc_mem_waterack isc__mem_waterack +#define isc_mempool_create isc__mempool_create +#define isc_mempool_setname isc__mempool_setname +#define isc_mempool_destroy isc__mempool_destroy +#define isc_mempool_associatelock isc__mempool_associatelock +#define isc__mempool_get isc___mempool_get +#define isc__mempool_put isc___mempool_put +#define isc_mempool_setfreemax isc__mempool_setfreemax +#define isc_mempool_getfreemax isc__mempool_getfreemax +#define isc_mempool_getfreecount isc__mempool_getfreecount +#define isc_mempool_setmaxalloc isc__mempool_setmaxalloc +#define isc_mempool_getmaxalloc isc__mempool_getmaxalloc +#define isc_mempool_getallocated isc__mempool_getallocated +#define isc_mempool_setfillcount isc__mempool_setfillcount +#define isc_mempool_getfillcount isc__mempool_getfillcount + +#define isc_socket_create isc__socket_create +#define isc_socket_dup isc__socket_dup +#define isc_socket_attach isc__socket_attach +#define isc_socket_detach isc__socket_detach +#define isc_socketmgr_create isc__socketmgr_create +#define isc_socketmgr_create2 isc__socketmgr_create2 +#define isc_socketmgr_destroy isc__socketmgr_destroy +#define isc_socket_open isc__socket_open +#define isc_socket_close isc__socket_close +#define isc_socket_recvv isc__socket_recvv +#define isc_socket_recv isc__socket_recv +#define isc_socket_recv2 isc__socket_recv2 +#define isc_socket_send isc__socket_send +#define isc_socket_sendto isc__socket_sendto +#define isc_socket_sendv isc__socket_sendv +#define isc_socket_sendtov isc__socket_sendtov +#define isc_socket_sendto2 isc__socket_sendto2 +#define isc_socket_cleanunix isc__socket_cleanunix +#define isc_socket_permunix isc__socket_permunix +#define isc_socket_bind isc__socket_bind +#define isc_socket_filter isc__socket_filter +#define isc_socket_listen isc__socket_listen +#define isc_socket_accept isc__socket_accept +#define isc_socket_connect isc__socket_connect +#define isc_socket_getfd isc__socket_getfd +#define isc_socket_getname isc__socket_getname +#define isc_socket_gettag isc__socket_gettag +#define isc_socket_getpeername isc__socket_getpeername +#define isc_socket_getsockname isc__socket_getsockname +#define isc_socket_cancel isc__socket_cancel +#define isc_socket_gettype isc__socket_gettype +#define isc_socket_isbound isc__socket_isbound +#define isc_socket_ipv6only isc__socket_ipv6only +#define isc_socket_setname isc__socket_setname +#define isc_socketmgr_getmaxsockets isc__socketmgr_getmaxsockets +#define isc_socketmgr_setstats isc__socketmgr_setstats +#define isc_socketmgr_setreserved isc__socketmgr_setreserved +#define isc__socketmgr_maxudp isc___socketmgr_maxudp +#define isc_socket_fdwatchcreate isc__socket_fdwatchcreate +#define isc_socket_fdwatchpoke isc__socket_fdwatchpoke + +#define isc_task_create isc__task_create +#define isc_task_attach isc__task_attach +#define isc_task_detach isc__task_detach +/* #define isc_task_exiting isc__task_exiting XXXMPA */ +#define isc_task_send isc__task_send +#define isc_task_sendanddetach isc__task_sendanddetach +#define isc_task_purgerange isc__task_purgerange +#define isc_task_purge isc__task_purge +#define isc_task_purgeevent isc__task_purgeevent +#define isc_task_unsendrange isc__task_unsendrange +#define isc_task_unsend isc__task_unsend +#define isc_task_onshutdown isc__task_onshutdown +#define isc_task_shutdown isc__task_shutdown +#define isc_task_destroy isc__task_destroy +#define isc_task_setname isc__task_setname +#define isc_task_getname isc__task_getname +#define isc_task_gettag isc__task_gettag +#define isc_task_getcurrenttime isc__task_getcurrenttime +#define isc_taskmgr_create isc__taskmgr_create +#define isc_taskmgr_setmode isc__taskmgr_setmode +#define isc_taskmgr_mode isc__taskmgr_mode +#define isc_taskmgr_destroy isc__taskmgr_destroy +#define isc_task_beginexclusive isc__task_beginexclusive +#define isc_task_endexclusive isc__task_endexclusive +#define isc_task_setprivilege isc__task_setprivilege +#define isc_task_privilege isc__task_privilege + +#define isc_timer_create isc__timer_create +#define isc_timer_reset isc__timer_reset +#define isc_timer_gettype isc__timer_gettype +#define isc_timer_touch isc__timer_touch +#define isc_timer_attach isc__timer_attach +#define isc_timer_detach isc__timer_detach +#define isc_timermgr_create isc__timermgr_create +#define isc_timermgr_poke isc__timermgr_poke +#define isc_timermgr_destroy isc__timermgr_destroy + +#endif /* BIND9 */ + +#endif /* ISCAPI_NAMESPACE_H */ diff --git a/contrib/ntp/include/isc/netaddr.h b/contrib/ntp/lib/isc/include/isc/netaddr.h similarity index 66% rename from contrib/ntp/include/isc/netaddr.h rename to contrib/ntp/lib/isc/include/isc/netaddr.h index e209a9fa7..954d77019 100644 --- a/contrib/ntp/include/isc/netaddr.h +++ b/contrib/ntp/lib/isc/include/isc/netaddr.h @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,22 +15,32 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: netaddr.h,v 1.18.12.7 2004/03/08 09:04:52 marka Exp $ */ +/* $Id: netaddr.h,v 1.37 2009/01/17 23:47:43 tbox Exp $ */ #ifndef ISC_NETADDR_H #define ISC_NETADDR_H 1 +/*! \file isc/netaddr.h */ + #include #include #include +#ifdef ISC_PLATFORM_HAVESYSUNH +#include +#include +#endif + ISC_LANG_BEGINDECLS struct isc_netaddr { unsigned int family; union { - struct in_addr in; + struct in_addr in; struct in6_addr in6; +#ifdef ISC_PLATFORM_HAVESYSUNH + char un[sizeof(((struct sockaddr_un *)0)->sun_path)]; +#endif } type; isc_uint32_t zone; }; @@ -38,51 +48,56 @@ struct isc_netaddr { isc_boolean_t isc_netaddr_equal(const isc_netaddr_t *a, const isc_netaddr_t *b); +/*%< + * Compare network addresses 'a' and 'b'. Return #ISC_TRUE if + * they are equal, #ISC_FALSE if not. + */ + isc_boolean_t isc_netaddr_eqprefix(const isc_netaddr_t *a, const isc_netaddr_t *b, unsigned int prefixlen); -/* +/*%< * Compare the 'prefixlen' most significant bits of the network - * addresses 'a' and 'b'. Return ISC_TRUE if they are equal, - * ISC_FALSE if not. + * addresses 'a' and 'b'. If 'b''s scope is zero then 'a''s scope is + * ignored. Return #ISC_TRUE if they are equal, #ISC_FALSE if not. */ isc_result_t isc_netaddr_masktoprefixlen(const isc_netaddr_t *s, unsigned int *lenp); -/* +/*%< * Convert a netmask in 's' into a prefix length in '*lenp'. * The mask should consist of zero or more '1' bits in the most * most significant part of the address, followed by '0' bits. - * If this is not the case, ISC_R_MASKNONCONTIG is returned. + * If this is not the case, #ISC_R_MASKNONCONTIG is returned. * * Returns: - * ISC_R_SUCCESS - * ISC_R_MASKNONCONTIG + *\li #ISC_R_SUCCESS + *\li #ISC_R_MASKNONCONTIG */ isc_result_t isc_netaddr_totext(const isc_netaddr_t *netaddr, isc_buffer_t *target); -/* +/*%< * Append a text representation of 'sockaddr' to the buffer 'target'. * The text is NOT null terminated. Handles IPv4 and IPv6 addresses. * * Returns: - * ISC_R_SUCCESS - * ISC_R_NOSPACE The text or the null termination did not fit. - * ISC_R_FAILURE Unspecified failure + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOSPACE The text or the null termination did not fit. + *\li #ISC_R_FAILURE Unspecified failure */ void isc_netaddr_format(const isc_netaddr_t *na, char *array, unsigned int size); -/* +/*%< * Format a human-readable representation of the network address '*na' * into the character array 'array', which is of size 'size'. * The resulting string is guaranteed to be null-terminated. */ #define ISC_NETADDR_FORMATSIZE \ - sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX") -/* + sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX%SSSSSSSSSS") +/*%< * Minimum size of array to pass to isc_netaddr_format(). */ @@ -95,6 +110,9 @@ isc_netaddr_fromin(isc_netaddr_t *netaddr, const struct in_addr *ina); void isc_netaddr_fromin6(isc_netaddr_t *netaddr, const struct in6_addr *ina6); +isc_result_t +isc_netaddr_frompath(isc_netaddr_t *netaddr, const char *path); + void isc_netaddr_setzone(isc_netaddr_t *netaddr, isc_uint32_t zone); @@ -103,46 +121,59 @@ isc_netaddr_getzone(const isc_netaddr_t *netaddr); void isc_netaddr_any(isc_netaddr_t *netaddr); -/* +/*%< * Return the IPv4 wildcard address. */ void isc_netaddr_any6(isc_netaddr_t *netaddr); -/* +/*%< * Return the IPv6 wildcard address. */ isc_boolean_t isc_netaddr_ismulticast(isc_netaddr_t *na); -/* +/*%< * Returns ISC_TRUE if the address is a multicast address. */ isc_boolean_t isc_netaddr_isexperimental(isc_netaddr_t *na); -/* +/*%< * Returns ISC_TRUE if the address is a experimental (CLASS E) address. */ isc_boolean_t isc_netaddr_islinklocal(isc_netaddr_t *na); -/* - * Returns ISC_TRUE if the address is a link local address. +/*%< + * Returns #ISC_TRUE if the address is a link local address. */ isc_boolean_t isc_netaddr_issitelocal(isc_netaddr_t *na); -/* - * Returns ISC_TRUE if the address is a site local address. +/*%< + * Returns #ISC_TRUE if the address is a site local address. */ void isc_netaddr_fromv4mapped(isc_netaddr_t *t, const isc_netaddr_t *s); -/* +/*%< * Convert an IPv6 v4mapped address into an IPv4 address. */ +isc_result_t +isc_netaddr_prefixok(const isc_netaddr_t *na, unsigned int prefixlen); +/* + * Test whether the netaddr 'na' and 'prefixlen' are consistant. + * e.g. prefixlen within range. + * na does not have bits set which are not covered by the prefixlen. + * + * Returns: + * ISC_R_SUCCESS + * ISC_R_RANGE prefixlen out of range + * ISC_R_NOTIMPLEMENTED unsupported family + * ISC_R_FAILURE extra bits. + */ ISC_LANG_ENDDECLS diff --git a/contrib/ntp/include/isc/netscope.h b/contrib/ntp/lib/isc/include/isc/netscope.h similarity index 75% rename from contrib/ntp/include/isc/netscope.h rename to contrib/ntp/lib/isc/include/isc/netscope.h index 7cc0f182d..163a08ca2 100644 --- a/contrib/ntp/include/isc/netscope.h +++ b/contrib/ntp/lib/isc/include/isc/netscope.h @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,26 +15,29 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: netscope.h,v 1.4.142.5 2004/03/08 09:04:52 marka Exp $ */ +/* $Id: netscope.h,v 1.13 2009/06/25 23:48:02 tbox Exp $ */ #ifndef ISC_NETSCOPE_H #define ISC_NETSCOPE_H 1 +/*! \file isc/netscope.h */ + ISC_LANG_BEGINDECLS -/* +/*% * Convert a string of an IPv6 scope zone to zone index. If the conversion * succeeds, 'zoneid' will store the index value. + * * XXXJT: when a standard interface for this purpose is defined, * we should use it. * * Returns: - * ISC_R_SUCCESS: conversion succeeds - * ISC_R_FAILURE: conversion fails + * \li ISC_R_SUCCESS: conversion succeeds + * \li ISC_R_FAILURE: conversion fails */ isc_result_t isc_netscope_pton(int af, char *scopename, void *addr, isc_uint32_t *zoneid); ISC_LANG_ENDDECLS -#endif /* ISC_NETADDR_H */ +#endif /* ISC_NETSCOPE_H */ diff --git a/contrib/ntp/lib/isc/include/isc/ondestroy.h b/contrib/ntp/lib/isc/include/isc/ondestroy.h new file mode 100644 index 000000000..64bd64333 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/ondestroy.h @@ -0,0 +1,116 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ondestroy.h,v 1.14 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ONDESTROY_H +#define ISC_ONDESTROY_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +/*! \file isc/ondestroy.h + * ondestroy handling. + * + * Any class ``X'' of objects that wants to send out notifications + * on its destruction should declare a field of type isc_ondestroy_t + * (call it 'ondest'). + * + * \code + * typedef struct { + * ... + * isc_ondestroy_t ondest; + * ... + * } X; + * \endcode + * + * When an object ``A'' of type X is created + * it must initialize the field ondest with a call to + * + * \code + * isc_ondestroy_init(&A->ondest). + * \endcode + * + * X should also provide a registration function for third-party + * objects to call to register their interest in being told about + * the destruction of a particular instance of X. + * + * \code + * isc_result_t + * X_ondestroy(X *instance, isc_task_t *task, + * isc_event_t **eventp) { + * return(isc_ondestroy_register(&instance->ondest, task,eventp)); + * } + * \endcode + * + * Note: locking of the ondestory structure embedded inside of X, is + * X's responsibility. + * + * When an instance of X is destroyed, a call to isc_ondestroy_notify() + * sends the notifications: + * + * \code + * X *instance; + * isc_ondestroy_t ondest = instance->ondest; + * + * ... completely cleanup 'instance' here... + * + * isc_ondestroy_notify(&ondest, instance); + * \endcode + * + * + * see lib/dns/zone.c for an ifdef'd-out example. + */ + +struct isc_ondestroy { + unsigned int magic; + isc_eventlist_t events; +}; + +void +isc_ondestroy_init(isc_ondestroy_t *ondest); +/*%< + * Initialize the on ondest structure. *must* be called before first call + * to isc_ondestroy_register(). + */ + +isc_result_t +isc_ondestroy_register(isc_ondestroy_t *ondest, isc_task_t *task, + isc_event_t **eventp); + +/*%< + * Stores task and *eventp away inside *ondest. Ownership of **event is + * taken from the caller (and *eventp is set to NULL). The task is attached + * to. + */ + +void +isc_ondestroy_notify(isc_ondestroy_t *ondest, void *sender); +/*%< + * Dispatches the event(s) to the task(s) that were given in + * isc_ondestroy_register call(s) (done via calls to + * isc_task_sendanddetach()). Before dispatch, the sender value of each + * event structure is set to the value of the sender paramater. The + * internal structures of the ondest parameter are cleaned out, so no other + * cleanup is needed. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_ONDESTROY_H */ diff --git a/contrib/ntp/lib/isc/include/isc/os.h b/contrib/ntp/lib/isc/include/isc/os.h new file mode 100644 index 000000000..3cf59e2cb --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/os.h @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: os.h,v 1.12 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_OS_H +#define ISC_OS_H 1 + +/*! \file isc/os.h */ + +#include + +ISC_LANG_BEGINDECLS + +unsigned int +isc_os_ncpus(void); +/*%< + * Return the number of CPUs available on the system, or 1 if this cannot + * be determined. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_OS_H */ diff --git a/contrib/ntp/lib/isc/include/isc/parseint.h b/contrib/ntp/lib/isc/include/isc/parseint.h new file mode 100644 index 000000000..504767685 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/parseint.h @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001, 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: parseint.h,v 1.9 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_PARSEINT_H +#define ISC_PARSEINT_H 1 + +#include +#include + +/*! \file isc/parseint.h + * \brief Parse integers, in a saner way than atoi() or strtoul() do. + */ + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_parse_uint32(isc_uint32_t *uip, const char *string, int base); + +isc_result_t +isc_parse_uint16(isc_uint16_t *uip, const char *string, int base); + +isc_result_t +isc_parse_uint8(isc_uint8_t *uip, const char *string, int base); +/*%< + * Parse the null-terminated string 'string' containing a base 'base' + * integer, storing the result in '*uip'. + * The base is interpreted + * as in strtoul(). Unlike strtoul(), leading whitespace, minus or + * plus signs are not accepted, and all errors (including overflow) + * are reported uniformly through the return value. + * + * Requires: + *\li 'string' points to a null-terminated string + *\li 0 <= 'base' <= 36 + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_BADNUMBER The string is not numeric (in the given base) + *\li #ISC_R_RANGE The number is not representable as the requested type. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_PARSEINT_H */ diff --git a/contrib/ntp/include/isc/platform.h b/contrib/ntp/lib/isc/include/isc/platform.h similarity index 100% rename from contrib/ntp/include/isc/platform.h rename to contrib/ntp/lib/isc/include/isc/platform.h diff --git a/contrib/ntp/lib/isc/include/isc/platform.h.in b/contrib/ntp/lib/isc/include/isc/platform.h.in new file mode 100644 index 000000000..03c2710ba --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/platform.h.in @@ -0,0 +1,367 @@ +/* + * Copyright (C) 2004-2010 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: platform.h.in,v 1.56 2010/12/18 01:56:23 each Exp $ */ + +#ifndef ISC_PLATFORM_H +#define ISC_PLATFORM_H 1 + +/*! \file */ + +/***** + ***** Platform-dependent defines. + *****/ + +/*** + *** Network. + ***/ + +/*! \brief + * Define if this system needs the header file included + * for full IPv6 support (pretty much only UnixWare). + */ +@ISC_PLATFORM_NEEDNETINETIN6H@ + +/*! \brief + * Define if this system needs the header file included + * to support in6_pkinfo (pretty much only BSD/OS). + */ +@ISC_PLATFORM_NEEDNETINET6IN6H@ + +/*! \brief + * If sockaddrs on this system have an sa_len field, ISC_PLATFORM_HAVESALEN + * will be defined. + */ +@ISC_PLATFORM_HAVESALEN@ + +/*! \brief + * If this system has the IPv6 structure definitions, ISC_PLATFORM_HAVEIPV6 + * will be defined. + */ +@ISC_PLATFORM_HAVEIPV6@ + +/*! \brief + * If this system is missing in6addr_any, ISC_PLATFORM_NEEDIN6ADDRANY will + * be defined. + */ +@ISC_PLATFORM_NEEDIN6ADDRANY@ + +/*! \brief + * If this system is missing in6addr_loopback, ISC_PLATFORM_NEEDIN6ADDRLOOPBACK + * will be defined. + */ +@ISC_PLATFORM_NEEDIN6ADDRLOOPBACK@ + +/*! \brief + * If this system has in6_pktinfo, ISC_PLATFORM_HAVEIN6PKTINFO will be + * defined. + */ +@ISC_PLATFORM_HAVEIN6PKTINFO@ + +/*! \brief + * If this system has in_addr6, rather than in6_addr, ISC_PLATFORM_HAVEINADDR6 + * will be defined. + */ +@ISC_PLATFORM_HAVEINADDR6@ + +/*! \brief + * If this system has sin6_scope_id, ISC_PLATFORM_HAVESCOPEID will be defined. + */ +@ISC_PLATFORM_HAVESCOPEID@ + +/*! \brief + * If this system needs inet_ntop(), ISC_PLATFORM_NEEDNTOP will be defined. + */ +@ISC_PLATFORM_NEEDNTOP@ + +/*! \brief + * If this system needs inet_pton(), ISC_PLATFORM_NEEDPTON will be defined. + */ +@ISC_PLATFORM_NEEDPTON@ + +/*! \brief + * If this system needs in_port_t, ISC_PLATFORM_NEEDPORTT will be defined. + */ +@ISC_PLATFORM_NEEDPORTT@ + +/*! \brief + * Define if the system has struct lifconf which is a extended struct ifconf + * for IPv6. + */ +@ISC_PLATFORM_HAVELIFCONF@ + +/*! \brief + * Define if the system has struct if_laddrconf which is a extended struct + * ifconf for IPv6. + */ +@ISC_PLATFORM_HAVEIF_LADDRCONF@ + +/*! \brief + * Define if the system has struct if_laddrreq. + */ +@ISC_PLATFORM_HAVEIF_LADDRREQ@ + +/*! \brief + * Define either ISC_PLATFORM_BSD44MSGHDR or ISC_PLATFORM_BSD43MSGHDR. + */ +@ISC_PLATFORM_MSGHDRFLAVOR@ + +/*! \brief + * Define if the system supports if_nametoindex. + */ +@ISC_PLATFORM_HAVEIFNAMETOINDEX@ + +/*! \brief + * Define on some UnixWare systems to fix erroneous definitions of various + * IN6_IS_ADDR_* macros. + */ +@ISC_PLATFORM_FIXIN6ISADDR@ + +/*! \brief + * Define if the system supports kqueue multiplexing + */ +@ISC_PLATFORM_HAVEKQUEUE@ + +/*! \brief + * Define if the system supports epoll multiplexing + */ +@ISC_PLATFORM_HAVEEPOLL@ + +/*! \brief + * Define if the system supports /dev/poll multiplexing + */ +@ISC_PLATFORM_HAVEDEVPOLL@ + +/*! \brief + * Define if we want to log backtrace + */ +@ISC_PLATFORM_USEBACKTRACE@ + +/* + *** Printing. + ***/ + +/*! \brief + * If this system needs vsnprintf() and snprintf(), ISC_PLATFORM_NEEDVSNPRINTF + * will be defined. + */ +@ISC_PLATFORM_NEEDVSNPRINTF@ + +/*! \brief + * If this system need a modern sprintf() that returns (int) not (char*). + */ +@ISC_PLATFORM_NEEDSPRINTF@ + +/*! \brief + * The printf format string modifier to use with isc_uint64_t values. + */ +@ISC_PLATFORM_QUADFORMAT@ + +/*** + *** String functions. + ***/ +/* + * If the system needs strsep(), ISC_PLATFORM_NEEDSTRSEP will be defined. + */ +@ISC_PLATFORM_NEEDSTRSEP@ + +/* + * If the system needs strlcpy(), ISC_PLATFORM_NEEDSTRLCPY will be defined. + */ +@ISC_PLATFORM_NEEDSTRLCPY@ + +/* + * If the system needs strlcat(), ISC_PLATFORM_NEEDSTRLCAT will be defined. + */ +@ISC_PLATFORM_NEEDSTRLCAT@ + +/* + * Define if this system needs strtoul. + */ +@ISC_PLATFORM_NEEDSTRTOUL@ + +/* + * Define if this system needs memmove. + */ +@ISC_PLATFORM_NEEDMEMMOVE@ + +/*** + *** Miscellaneous. + ***/ + +/* + * Defined if we are using threads. + */ +@ISC_PLATFORM_USETHREADS@ + +/* + * Defined if unistd.h does not cause fd_set to be delared. + */ +@ISC_PLATFORM_NEEDSYSSELECTH@ + +/* + * Defined to or for how to include + * the GSSAPI header. + */ +@ISC_PLATFORM_GSSAPIHEADER@ + +/* + * Defined to or for how to + * include the GSSAPI KRB5 header. + */ +@ISC_PLATFORM_GSSAPI_KRB5_HEADER@ + +/* + * Defined to or for how to include + * the KRB5 header. + */ +@ISC_PLATFORM_KRB5HEADER@ + +/* + * Type used for resource limits. + */ +@ISC_PLATFORM_RLIMITTYPE@ + +/* + * Define if your compiler supports "long long int". + */ +@ISC_PLATFORM_HAVELONGLONG@ + +/* + * Define if PTHREAD_ONCE_INIT should be surrounded by braces to + * prevent compiler warnings (such as with gcc on Solaris 2.8). + */ +@ISC_PLATFORM_BRACEPTHREADONCEINIT@ + +/* + * Used to control how extern data is linked; needed for Win32 platforms. + */ +@ISC_PLATFORM_USEDECLSPEC@ + +/* + * Define if the platform has . + */ +@ISC_PLATFORM_HAVESYSUNH@ + +/* + * If the "xadd" operation is available on this architecture, + * ISC_PLATFORM_HAVEXADD will be defined. + */ +@ISC_PLATFORM_HAVEXADD@ + +/* + * If the "xaddq" operation (64bit xadd) is available on this architecture, + * ISC_PLATFORM_HAVEXADDQ will be defined. + */ +@ISC_PLATFORM_HAVEXADDQ@ + +/* + * If the "atomic swap" operation is available on this architecture, + * ISC_PLATFORM_HAVEATOMICSTORE" will be defined. + */ +@ISC_PLATFORM_HAVEATOMICSTORE@ + +/* + * If the "compare-and-exchange" operation is available on this architecture, + * ISC_PLATFORM_HAVECMPXCHG will be defined. + */ +@ISC_PLATFORM_HAVECMPXCHG@ + +/* + * Define if gcc ASM extension is available + */ +@ISC_PLATFORM_USEGCCASM@ + +/* + * Define if Tru64 style ASM syntax must be used. + */ +@ISC_PLATFORM_USEOSFASM@ + +/* + * Define if the standard __asm function must be used. + */ +@ISC_PLATFORM_USESTDASM@ + +/* + * Define if the platform has . + */ +@ISC_PLATFORM_HAVESTRINGSH@ + +/* + * Define if the hash functions must be provided by OpenSSL. + */ +@ISC_PLATFORM_OPENSSLHASH@ + +/* + * Defines for the noreturn attribute. + */ +@ISC_PLATFORM_NORETURN_PRE@ +@ISC_PLATFORM_NORETURN_POST@ + +/*** + *** Windows dll support. + ***/ + +/* + * Define if MacOS style of PPC assembly must be used. + * e.g. "r6", not "6", for register six. + */ +@ISC_PLATFORM_USEMACASM@ + +#ifndef ISC_PLATFORM_USEDECLSPEC +#define LIBISC_EXTERNAL_DATA +#define LIBDNS_EXTERNAL_DATA +#define LIBISCCC_EXTERNAL_DATA +#define LIBISCCFG_EXTERNAL_DATA +#define LIBBIND9_EXTERNAL_DATA +#else /*! \brief ISC_PLATFORM_USEDECLSPEC */ +#ifdef LIBISC_EXPORTS +#define LIBISC_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBISC_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBDNS_EXPORTS +#define LIBDNS_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBDNS_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBISCCC_EXPORTS +#define LIBISCCC_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBISCCC_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBISCCFG_EXPORTS +#define LIBISCCFG_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBISCCFG_EXTERNAL_DATA __declspec(dllimport) +#endif +#ifdef LIBBIND9_EXPORTS +#define LIBBIND9_EXTERNAL_DATA __declspec(dllexport) +#else +#define LIBBIND9_EXTERNAL_DATA __declspec(dllimport) +#endif +#endif /*! \brief ISC_PLATFORM_USEDECLSPEC */ + +/* + * Tell emacs to use C mode for this file. + * + * Local Variables: + * mode: c + * End: + */ + +#endif /* ISC_PLATFORM_H */ diff --git a/contrib/ntp/lib/isc/include/isc/portset.h b/contrib/ntp/lib/isc/include/isc/portset.h new file mode 100644 index 000000000..774d6bb18 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/portset.h @@ -0,0 +1,141 @@ +/* + * Copyright (C) 2008, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: portset.h,v 1.6 2009/06/25 05:28:34 marka Exp $ */ + +/*! \file isc/portset.h + * \brief Transport Protocol Port Manipulation Module + * + * This module provides simple utilities to handle a set of transport protocol + * (UDP or TCP) port numbers, e.g., for creating an ACL list. An isc_portset_t + * object is an opaque instance of a port set, for which the user can add or + * remove a specific port or a range of consecutive ports. This object is + * expected to be used as a temporary work space only, and does not protect + * simultaneous access from multiple threads. Therefore it must not be stored + * in a place that can be accessed from multiple threads. + */ + +#ifndef ISC_PORTSET_H +#define ISC_PORTSET_H 1 + +/*** + *** Imports + ***/ + +#include + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_portset_create(isc_mem_t *mctx, isc_portset_t **portsetp); +/*%< + * Create a port set and initialize it as an empty set. + * + * Requires: + *\li 'mctx' to be valid. + *\li 'portsetp' to be non NULL and '*portsetp' to be NULL; + * + * Returns: + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + */ + +void +isc_portset_destroy(isc_mem_t *mctx, isc_portset_t **portsetp); +/*%< + * Destroy a port set. + * + * Requires: + *\li 'mctx' to be valid and must be the same context given when the port set + * was created. + *\li '*portsetp' to be a valid set. + */ + +isc_boolean_t +isc_portset_isset(isc_portset_t *portset, in_port_t port); +/*%< + * Test whether the given port is stored in the portset. + * + * Requires: + *\li 'portset' to be a valid set. + * + * Returns + * \li #ISC_TRUE if the port is found, ISC_FALSE otherwise. + */ + +unsigned int +isc_portset_nports(isc_portset_t *portset); +/*%< + * Provides the number of ports stored in the given portset. + * + * Requires: + *\li 'portset' to be a valid set. + * + * Returns + * \li the number of ports stored in portset. + */ + +void +isc_portset_add(isc_portset_t *portset, in_port_t port); +/*%< + * Add the given port to the portset. The port may or may not be stored in + * the portset. + * + * Requires: + *\li 'portlist' to be valid. + */ + +void +isc_portset_remove(isc_portset_t *portset, in_port_t port); +/*%< + * Remove the given port to the portset. The port may or may not be stored in + * the portset. + * + * Requires: + *\li 'portlist' to be valid. + */ + +void +isc_portset_addrange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi); +/*%< + * Add a subset of [port_lo, port_hi] (inclusive) to the portset. Ports in the + * subset may or may not be stored in portset. + * + * Requires: + *\li 'portlist' to be valid. + *\li port_lo <= port_hi + */ + +void +isc_portset_removerange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi); +/*%< + * Subtract a subset of [port_lo, port_hi] (inclusive) from the portset. Ports + * in the subset may or may not be stored in portset. + * + * Requires: + *\li 'portlist' to be valid. + *\li port_lo <= port_hi + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_PORTSET_H */ diff --git a/contrib/ntp/include/isc/print.h b/contrib/ntp/lib/isc/include/isc/print.h similarity index 55% rename from contrib/ntp/include/isc/print.h rename to contrib/ntp/lib/isc/include/isc/print.h index 7a1bc83b6..cd1e38eaf 100644 --- a/contrib/ntp/include/isc/print.h +++ b/contrib/ntp/lib/isc/include/isc/print.h @@ -1,25 +1,27 @@ /* - * Copyright (C) 1999-2001 Internet Software Consortium. + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001, 2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: print.h,v 1.17 2001/02/27 02:19:33 gson Exp $ */ +/* $Id: print.h,v 1.26 2007/06/19 23:47:18 tbox Exp $ */ #ifndef ISC_PRINT_H #define ISC_PRINT_H 1 +/*! \file isc/print.h */ + /*** *** Imports ***/ @@ -28,7 +30,7 @@ #include #include -/* +/*! * This block allows lib/isc/print.c to be cleanly compiled even if * the platform does not need it. The standard Makefile will still * not compile print.c or archive print.o, so this is just to make test @@ -38,6 +40,10 @@ #define ISC_PLATFORM_NEEDVSNPRINTF #endif +#if !defined(ISC_PLATFORM_NEEDSPRINTF) && defined(ISC__PRINT_SOURCE) +#define ISC_PLATFORM_NEEDSPRINTF +#endif + /*** *** Macros ***/ @@ -50,9 +56,15 @@ #ifdef ISC_PLATFORM_NEEDVSNPRINTF #include #include +#endif +#ifdef ISC_PLATFORM_NEEDSPRINTF +#include +#endif + ISC_LANG_BEGINDECLS +#ifdef ISC_PLATFORM_NEEDVSNPRINTF int isc_print_vsnprintf(char *str, size_t size, const char *format, va_list ap) ISC_FORMAT_PRINTF(3, 0); @@ -62,8 +74,14 @@ int isc_print_snprintf(char *str, size_t size, const char *format, ...) ISC_FORMAT_PRINTF(3, 4); #define snprintf isc_print_snprintf +#endif /* ISC_PLATFORM_NEEDVSNPRINTF */ + +#ifdef ISC_PLATFORM_NEEDSPRINTF +int +isc_print_sprintf(char *str, const char *format, ...) ISC_FORMAT_PRINTF(2, 3); +#define sprintf isc_print_sprintf +#endif ISC_LANG_ENDDECLS -#endif /* ISC_PLATFORM_NEEDVSNPRINTF */ #endif /* ISC_PRINT_H */ diff --git a/contrib/ntp/lib/isc/include/isc/queue.h b/contrib/ntp/lib/isc/include/isc/queue.h new file mode 100644 index 000000000..5bf84c527 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/queue.h @@ -0,0 +1,100 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* + * This is a generic implementation of a two-lock concurrent queue. + * There are built-in mutex locks for the head and tail of the queue, + * allowing elements to be safely added and removed at the same time. + */ + +#ifndef ISC_QUEUE_H +#define ISC_QUEUE_H 1 +#include +#include +#include + +#ifdef ISC_QUEUE_CHECKINIT +#define ISC_QLINK_INSIST(x) ISC_INSIST(x) +#else +#define ISC_QLINK_INSIST(x) (void)0 +#endif + +#define ISC_QLINK(type) struct { void *next; isc_boolean_t linked; } +#define ISC_QLINK_INIT(elt, link) \ + do { \ + (elt)->link.next = (void *)(-1); \ + (elt)->link.linked = ISC_FALSE; \ + } while (0) +#define ISC_QLINK_LINKED(elt, link) ((elt)->link.linked) + +#define ISC_QUEUE(type) struct { \ + type headnode; \ + type *head, *tail; \ + isc_mutex_t headlock, taillock; \ +} + +#define ISC_QUEUE_INIT(queue, link) \ + do { \ + isc_mutex_init(&(queue).headlock); \ + isc_mutex_init(&(queue).taillock); \ + (queue).head = (void *) &((queue).headnode); \ + (queue).tail = (void *) &((queue).headnode); \ + ISC_QLINK_INIT((queue).head, link); \ + } while (0) + +#define ISC_QUEUE_EMPTY(queue) ISC_TF((queue).head == (queue).tail) + +#define ISC_QUEUE_DESTROY(queue) \ + do { \ + ISC_QLINK_INSIST(ISC_QUEUE_EMPTY(queue)); \ + isc_mutex_destroy(&(queue).headlock); \ + isc_mutex_destroy(&(queue).taillock); \ + } while (0) + +#define ISC_QUEUE_PUSH(queue, elt, link) \ + do { \ + ISC_QLINK_INSIST(!ISC_QLINK_LINKED(elt, link)); \ + (elt)->link.next = (void *)(-1); \ + LOCK(&(queue).taillock); \ + (queue).tail->link.next = elt; \ + (queue).tail = elt; \ + UNLOCK(&(queue).taillock); \ + (elt)->link.linked = ISC_TRUE; \ + } while (0) + +#define ISC_QUEUE_POP(queue, link, ret) \ + do { \ + LOCK(&(queue).headlock); \ + ret = (queue).head->link.next; \ + if (ret == (void *)(-1)) { \ + UNLOCK(&(queue).headlock); \ + ret = NULL; \ + } else { \ + (queue).head->link.next = ret->link.next; \ + if (ret->link.next == (void *)(-1)) { \ + LOCK(&(queue).taillock); \ + (queue).tail = (queue).head; \ + UNLOCK(&(queue).taillock); \ + } \ + UNLOCK(&(queue).headlock); \ + ret->link.next = (void *)(-1); \ + ret->link.linked = ISC_FALSE; \ + } \ + } while (0) + +#endif /* ISC_QUEUE_H */ diff --git a/contrib/ntp/lib/isc/include/isc/quota.h b/contrib/ntp/lib/isc/include/isc/quota.h new file mode 100644 index 000000000..7b0d0d9be --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/quota.h @@ -0,0 +1,119 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: quota.h,v 1.16 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_QUOTA_H +#define ISC_QUOTA_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/quota.h + * + * \brief The isc_quota_t object is a simple helper object for implementing + * quotas on things like the number of simultaneous connections to + * a server. It keeps track of the amount of quota in use, and + * encapsulates the locking necessary to allow multiple tasks to + * share a quota. + */ + +/*** + *** Imports. + ***/ + +#include +#include +#include + +/***** + ***** Types. + *****/ + +ISC_LANG_BEGINDECLS + +/*% isc_quota structure */ +struct isc_quota { + isc_mutex_t lock; /*%< Locked by lock. */ + int max; + int used; + int soft; +}; + +isc_result_t +isc_quota_init(isc_quota_t *quota, int max); +/*%< + * Initialize a quota object. + * + * Returns: + * ISC_R_SUCCESS + * Other error Lock creation failed. + */ + +void +isc_quota_destroy(isc_quota_t *quota); +/*%< + * Destroy a quota object. + */ + +void +isc_quota_soft(isc_quota_t *quota, int soft); +/*%< + * Set a soft quota. + */ + +void +isc_quota_max(isc_quota_t *quota, int max); +/*%< + * Re-set a maximum quota. + */ + +isc_result_t +isc_quota_reserve(isc_quota_t *quota); +/*%< + * Attempt to reserve one unit of 'quota'. + * + * Returns: + * \li #ISC_R_SUCCESS Success + * \li #ISC_R_SOFTQUOTA Success soft quota reached + * \li #ISC_R_QUOTA Quota is full + */ + +void +isc_quota_release(isc_quota_t *quota); +/*%< + * Release one unit of quota. + */ + +isc_result_t +isc_quota_attach(isc_quota_t *quota, isc_quota_t **p); +/*%< + * Like isc_quota_reserve, and also attaches '*p' to the + * quota if successful (ISC_R_SUCCESS or ISC_R_SOFTQUOTA). + */ + +void +isc_quota_detach(isc_quota_t **p); +/*%< + * Like isc_quota_release, and also detaches '*p' from the + * quota. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_QUOTA_H */ diff --git a/contrib/ntp/lib/isc/include/isc/radix.h b/contrib/ntp/lib/isc/include/isc/radix.h new file mode 100644 index 000000000..6b413a23b --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/radix.h @@ -0,0 +1,240 @@ +/* + * Copyright (C) 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: radix.h,v 1.13 2008/12/01 23:47:45 tbox Exp $ */ + +/* + * This source was adapted from MRT's RCS Ids: + * Id: radix.h,v 1.6 1999/08/03 03:32:53 masaki Exp + * Id: mrt.h,v 1.57.2.6 1999/12/28 23:41:27 labovit Exp + * Id: defs.h,v 1.5.2.2 2000/01/15 14:19:16 masaki Exp + */ + +#include +#include +#include +#include +#include + +#include + +#ifndef _RADIX_H +#define _RADIX_H + +#define NETADDR_TO_PREFIX_T(na,pt,bits) \ + do { \ + memset(&(pt), 0, sizeof(pt)); \ + if((na) != NULL) { \ + (pt).family = (na)->family; \ + (pt).bitlen = (bits); \ + if ((pt).family == AF_INET6) { \ + memcpy(&(pt).add.sin6, &(na)->type.in6, \ + ((bits)+7)/8); \ + } else \ + memcpy(&(pt).add.sin, &(na)->type.in, \ + ((bits)+7)/8); \ + } else { \ + (pt).family = AF_UNSPEC; \ + (pt).bitlen = 0; \ + } \ + isc_refcount_init(&(pt).refcount, 0); \ + } while(0) + +typedef struct isc_prefix { + unsigned int family; /* AF_INET | AF_INET6, or AF_UNSPEC for "any" */ + unsigned int bitlen; /* 0 for "any" */ + isc_refcount_t refcount; + union { + struct in_addr sin; + struct in6_addr sin6; + } add; +} isc_prefix_t; + +typedef void (*isc_radix_destroyfunc_t)(void *); +typedef void (*isc_radix_processfunc_t)(isc_prefix_t *, void **); + +#define isc_prefix_tochar(prefix) ((char *)&(prefix)->add.sin) +#define isc_prefix_touchar(prefix) ((u_char *)&(prefix)->add.sin) + +#define BIT_TEST(f, b) ((f) & (b)) + +/* + * We need "first match" when we search the radix tree to preserve + * compatibility with the existing ACL implementation. Radix trees + * naturally lend themselves to "best match". In order to get "first match" + * behavior, we keep track of the order in which entries are added to the + * tree--and when a search is made, we find all matching entries, and + * return the one that was added first. + * + * An IPv4 prefix and an IPv6 prefix may share a radix tree node if they + * have the same length and bit pattern (e.g., 127/8 and 7f::/8). To + * disambiguate between them, node_num and data are two-element arrays; + * node_num[0] and data[0] are used for IPv4 addresses, node_num[1] + * and data[1] for IPv6 addresses. The only exception is a prefix of + * 0/0 (aka "any" or "none"), which is always stored as IPv4 but matches + * IPv6 addresses too. + */ + +#define ISC_IS6(family) ((family) == AF_INET6 ? 1 : 0) +typedef struct isc_radix_node { + isc_uint32_t bit; /* bit length of the prefix */ + isc_prefix_t *prefix; /* who we are in radix tree */ + struct isc_radix_node *l, *r; /* left and right children */ + struct isc_radix_node *parent; /* may be used */ + void *data[2]; /* pointers to IPv4 and IPV6 data */ + int node_num[2]; /* which node this was in the tree, + or -1 for glue nodes */ +} isc_radix_node_t; + +#define RADIX_TREE_MAGIC ISC_MAGIC('R','d','x','T'); +#define RADIX_TREE_VALID(a) ISC_MAGIC_VALID(a, RADIX_TREE_MAGIC); + +typedef struct isc_radix_tree { + unsigned int magic; + isc_mem_t *mctx; + isc_radix_node_t *head; + isc_uint32_t maxbits; /* for IP, 32 bit addresses */ + int num_active_node; /* for debugging purposes */ + int num_added_node; /* total number of nodes */ +} isc_radix_tree_t; + +isc_result_t +isc_radix_search(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_prefix_t *prefix); +/*%< + * Search 'radix' for the best match to 'prefix'. + * Return the node found in '*target'. + * + * Requires: + * \li 'radix' to be valid. + * \li 'target' is not NULL and "*target" is NULL. + * \li 'prefix' to be valid. + * + * Returns: + * \li ISC_R_NOTFOUND + * \li ISC_R_SUCCESS + */ + +isc_result_t +isc_radix_insert(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_radix_node_t *source, isc_prefix_t *prefix); +/*%< + * Insert 'source' or 'prefix' into the radix tree 'radix'. + * Return the node added in 'target'. + * + * Requires: + * \li 'radix' to be valid. + * \li 'target' is not NULL and "*target" is NULL. + * \li 'prefix' to be valid or 'source' to be non NULL and contain + * a valid prefix. + * + * Returns: + * \li ISC_R_NOMEMORY + * \li ISC_R_SUCCESS + */ + +void +isc_radix_remove(isc_radix_tree_t *radix, isc_radix_node_t *node); +/*%< + * Remove the node 'node' from the radix tree 'radix'. + * + * Requires: + * \li 'radix' to be valid. + * \li 'node' to be valid. + */ + +isc_result_t +isc_radix_create(isc_mem_t *mctx, isc_radix_tree_t **target, int maxbits); +/*%< + * Create a radix tree with a maximum depth of 'maxbits'; + * + * Requires: + * \li 'mctx' to be valid. + * \li 'target' to be non NULL and '*target' to be NULL. + * \li 'maxbits' to be less than or equal to RADIX_MAXBITS. + * + * Returns: + * \li ISC_R_NOMEMORY + * \li ISC_R_SUCCESS + */ + +void +isc_radix_destroy(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func); +/*%< + * Destroy a radix tree optionally calling 'func' to clean up node data. + * + * Requires: + * \li 'radix' to be valid. + */ + +void +isc_radix_process(isc_radix_tree_t *radix, isc_radix_processfunc_t func); +/*%< + * Walk a radix tree calling 'func' to process node data. + * + * Requires: + * \li 'radix' to be valid. + * \li 'func' to point to a function. + */ + +#define RADIX_MAXBITS 128 +#define RADIX_NBIT(x) (0x80 >> ((x) & 0x7f)) +#define RADIX_NBYTE(x) ((x) >> 3) + +#define RADIX_DATA_GET(node, type) (type *)((node)->data) +#define RADIX_DATA_SET(node, value) ((node)->data = (void *)(value)) + +#define RADIX_WALK(Xhead, Xnode) \ + do { \ + isc_radix_node_t *Xstack[RADIX_MAXBITS+1]; \ + isc_radix_node_t **Xsp = Xstack; \ + isc_radix_node_t *Xrn = (Xhead); \ + while ((Xnode = Xrn)) { \ + if (Xnode->prefix) + +#define RADIX_WALK_ALL(Xhead, Xnode) \ +do { \ + isc_radix_node_t *Xstack[RADIX_MAXBITS+1]; \ + isc_radix_node_t **Xsp = Xstack; \ + isc_radix_node_t *Xrn = (Xhead); \ + while ((Xnode = Xrn)) { \ + if (1) + +#define RADIX_WALK_BREAK { \ + if (Xsp != Xstack) { \ + Xrn = *(--Xsp); \ + } else { \ + Xrn = (radix_node_t *) 0; \ + } \ + continue; } + +#define RADIX_WALK_END \ + if (Xrn->l) { \ + if (Xrn->r) { \ + *Xsp++ = Xrn->r; \ + } \ + Xrn = Xrn->l; \ + } else if (Xrn->r) { \ + Xrn = Xrn->r; \ + } else if (Xsp != Xstack) { \ + Xrn = *(--Xsp); \ + } else { \ + Xrn = (isc_radix_node_t *) 0; \ + } \ + } \ + } while (0) + +#endif /* _RADIX_H */ diff --git a/contrib/ntp/lib/isc/include/isc/random.h b/contrib/ntp/lib/isc/include/isc/random.h new file mode 100644 index 000000000..1f9572d30 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/random.h @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: random.h,v 1.20 2009/01/17 23:47:43 tbox Exp $ */ + +#ifndef ISC_RANDOM_H +#define ISC_RANDOM_H 1 + +#include +#include + +/*! \file isc/random.h + * \brief Implements a random state pool which will let the caller return a + * series of possibly non-reproducible random values. + * + * Note that the + * strength of these numbers is not all that high, and should not be + * used in cryptography functions. It is useful for jittering values + * a bit here and there, such as timeouts, etc. + */ + +ISC_LANG_BEGINDECLS + +void +isc_random_seed(isc_uint32_t seed); +/*%< + * Set the initial seed of the random state. + */ + +void +isc_random_get(isc_uint32_t *val); +/*%< + * Get a random value. + * + * Requires: + * val != NULL. + */ + +isc_uint32_t +isc_random_jitter(isc_uint32_t max, isc_uint32_t jitter); +/*%< + * Get a random value between (max - jitter) and (max). + * This is useful for jittering timer values. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_RANDOM_H */ diff --git a/contrib/ntp/lib/isc/include/isc/ratelimiter.h b/contrib/ntp/lib/isc/include/isc/ratelimiter.h new file mode 100644 index 000000000..00a720975 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/ratelimiter.h @@ -0,0 +1,134 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ratelimiter.h,v 1.23 2009/01/18 23:48:14 tbox Exp $ */ + +#ifndef ISC_RATELIMITER_H +#define ISC_RATELIMITER_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/ratelimiter.h + * \brief A rate limiter is a mechanism for dispatching events at a limited + * rate. This is intended to be used when sending zone maintenance + * SOA queries, NOTIFY messages, etc. + */ + +/*** + *** Imports. + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/***** + ***** Functions. + *****/ + +isc_result_t +isc_ratelimiter_create(isc_mem_t *mctx, isc_timermgr_t *timermgr, + isc_task_t *task, isc_ratelimiter_t **ratelimiterp); +/*%< + * Create a rate limiter. The execution interval is initially undefined. + */ + +isc_result_t +isc_ratelimiter_setinterval(isc_ratelimiter_t *rl, isc_interval_t *interval); +/*!< + * Set the minimum interval between event executions. + * The interval value is copied, so the caller need not preserve it. + * + * Requires: + * '*interval' is a nonzero interval. + */ + +void +isc_ratelimiter_setpertic(isc_ratelimiter_t *rl, isc_uint32_t perint); +/*%< + * Set the number of events processed per interval timer tick. + * If 'perint' is zero it is treated as 1. + */ + +isc_result_t +isc_ratelimiter_enqueue(isc_ratelimiter_t *rl, isc_task_t *task, + isc_event_t **eventp); +/*%< + * Queue an event for rate-limited execution. + * + * This is similar + * to doing an isc_task_send() to the 'task', except that the + * execution may be delayed to achieve the desired rate of + * execution. + * + * '(*eventp)->ev_sender' is used to hold the task. The caller + * must ensure that the task exists until the event is delivered. + * + * Requires: + *\li An interval has been set by calling + * isc_ratelimiter_setinterval(). + * + *\li 'task' to be non NULL. + *\li '(*eventp)->ev_sender' to be NULL. + */ + +void +isc_ratelimiter_shutdown(isc_ratelimiter_t *ratelimiter); +/*%< + * Shut down a rate limiter. + * + * Ensures: + *\li All events that have not yet been + * dispatched to the task are dispatched immediately with + * the #ISC_EVENTATTR_CANCELED bit set in ev_attributes. + * + *\li Further attempts to enqueue events will fail with + * #ISC_R_SHUTTINGDOWN. + * + *\li The rate limiter is no longer attached to its task. + */ + +void +isc_ratelimiter_attach(isc_ratelimiter_t *source, isc_ratelimiter_t **target); +/*%< + * Attach to a rate limiter. + */ + +void +isc_ratelimiter_detach(isc_ratelimiter_t **ratelimiterp); +/*%< + * Detach from a rate limiter. + */ + +isc_result_t +isc_ratelimiter_stall(isc_ratelimiter_t *rl); +/*%< + * Stall event processing. + */ + +isc_result_t +isc_ratelimiter_release(isc_ratelimiter_t *rl); +/*%< + * Release a stalled rate limiter. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_RATELIMITER_H */ diff --git a/contrib/ntp/lib/isc/include/isc/refcount.h b/contrib/ntp/lib/isc/include/isc/refcount.h new file mode 100644 index 000000000..b72b1585b --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/refcount.h @@ -0,0 +1,233 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: refcount.h,v 1.17 2009/09/29 23:48:04 tbox Exp $ */ + +#ifndef ISC_REFCOUNT_H +#define ISC_REFCOUNT_H 1 + +#include +#include +#include +#include +#include +#include + +/*! \file isc/refcount.h + * \brief Implements a locked reference counter. + * + * These functions may actually be + * implemented using macros, and implementations of these macros are below. + * The isc_refcount_t type should not be accessed directly, as its contents + * depend on the implementation. + */ + +ISC_LANG_BEGINDECLS + +/* + * Function prototypes + */ + +/* + * isc_result_t + * isc_refcount_init(isc_refcount_t *ref, unsigned int n); + * + * Initialize the reference counter. There will be 'n' initial references. + * + * Requires: + * ref != NULL + */ + +/* + * void + * isc_refcount_destroy(isc_refcount_t *ref); + * + * Destroys a reference counter. + * + * Requires: + * ref != NULL + * The number of references is 0. + */ + +/* + * void + * isc_refcount_increment(isc_refcount_t *ref, unsigned int *targetp); + * isc_refcount_increment0(isc_refcount_t *ref, unsigned int *targetp); + * + * Increments the reference count, returning the new value in targetp if it's + * not NULL. The reference counter typically begins with the initial counter + * of 1, and will be destroyed once the counter reaches 0. Thus, + * isc_refcount_increment() additionally requires the previous counter be + * larger than 0 so that an error which violates the usage can be easily + * caught. isc_refcount_increment0() does not have this restriction. + * + * Requires: + * ref != NULL. + */ + +/* + * void + * isc_refcount_decrement(isc_refcount_t *ref, unsigned int *targetp); + * + * Decrements the reference count, returning the new value in targetp if it's + * not NULL. + * + * Requires: + * ref != NULL. + */ + + +/* + * Sample implementations + */ +#ifdef ISC_PLATFORM_USETHREADS +#ifdef ISC_PLATFORM_HAVEXADD + +#define ISC_REFCOUNT_HAVEATOMIC 1 + +typedef struct isc_refcount { + isc_int32_t refs; +} isc_refcount_t; + +#define isc_refcount_destroy(rp) REQUIRE((rp)->refs == 0) +#define isc_refcount_current(rp) ((unsigned int)((rp)->refs)) + +#define isc_refcount_increment0(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + isc_int32_t prev; \ + prev = isc_atomic_xadd(&(rp)->refs, 1); \ + if (_tmp != NULL) \ + *_tmp = prev + 1; \ + } while (0) + +#define isc_refcount_increment(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + isc_int32_t prev; \ + prev = isc_atomic_xadd(&(rp)->refs, 1); \ + REQUIRE(prev > 0); \ + if (_tmp != NULL) \ + *_tmp = prev + 1; \ + } while (0) + +#define isc_refcount_decrement(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + isc_int32_t prev; \ + prev = isc_atomic_xadd(&(rp)->refs, -1); \ + REQUIRE(prev > 0); \ + if (_tmp != NULL) \ + *_tmp = prev - 1; \ + } while (0) + +#else /* ISC_PLATFORM_HAVEXADD */ + +typedef struct isc_refcount { + int refs; + isc_mutex_t lock; +} isc_refcount_t; + +/*% Destroys a reference counter. */ +#define isc_refcount_destroy(rp) \ + do { \ + REQUIRE((rp)->refs == 0); \ + DESTROYLOCK(&(rp)->lock); \ + } while (0) + +#define isc_refcount_current(rp) ((unsigned int)((rp)->refs)) + +/*% Increments the reference count, returning the new value in targetp if it's not NULL. */ +#define isc_refcount_increment0(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + LOCK(&(rp)->lock); \ + ++((rp)->refs); \ + if (_tmp != NULL) \ + *_tmp = ((rp)->refs); \ + UNLOCK(&(rp)->lock); \ + } while (0) + +#define isc_refcount_increment(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + LOCK(&(rp)->lock); \ + REQUIRE((rp)->refs > 0); \ + ++((rp)->refs); \ + if (_tmp != NULL) \ + *_tmp = ((rp)->refs); \ + UNLOCK(&(rp)->lock); \ + } while (0) + +/*% Decrements the reference count, returning the new value in targetp if it's not NULL. */ +#define isc_refcount_decrement(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + LOCK(&(rp)->lock); \ + REQUIRE((rp)->refs > 0); \ + --((rp)->refs); \ + if (_tmp != NULL) \ + *_tmp = ((rp)->refs); \ + UNLOCK(&(rp)->lock); \ + } while (0) + +#endif /* ISC_PLATFORM_HAVEXADD */ +#else /* ISC_PLATFORM_USETHREADS */ + +typedef struct isc_refcount { + int refs; +} isc_refcount_t; + +#define isc_refcount_destroy(rp) REQUIRE((rp)->refs == 0) +#define isc_refcount_current(rp) ((unsigned int)((rp)->refs)) + +#define isc_refcount_increment0(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + int _n = ++(rp)->refs; \ + if (_tmp != NULL) \ + *_tmp = _n; \ + } while (0) + +#define isc_refcount_increment(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + int _n; \ + REQUIRE((rp)->refs > 0); \ + _n = ++(rp)->refs; \ + if (_tmp != NULL) \ + *_tmp = _n; \ + } while (0) + +#define isc_refcount_decrement(rp, tp) \ + do { \ + unsigned int *_tmp = (unsigned int *)(tp); \ + int _n; \ + REQUIRE((rp)->refs > 0); \ + _n = --(rp)->refs; \ + if (_tmp != NULL) \ + *_tmp = _n; \ + } while (0) + +#endif /* ISC_PLATFORM_USETHREADS */ + +isc_result_t +isc_refcount_init(isc_refcount_t *ref, unsigned int n); + +ISC_LANG_ENDDECLS + +#endif /* ISC_REFCOUNT_H */ diff --git a/contrib/ntp/include/isc/region.h b/contrib/ntp/lib/isc/include/isc/region.h similarity index 81% rename from contrib/ntp/include/isc/region.h rename to contrib/ntp/lib/isc/include/isc/region.h index 5622394aa..43d8f8f2d 100644 --- a/contrib/ntp/include/isc/region.h +++ b/contrib/ntp/lib/isc/include/isc/region.h @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,11 +15,13 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: region.h,v 1.16.12.3 2004/03/08 09:04:53 marka Exp $ */ +/* $Id: region.h,v 1.25 2007/06/19 23:47:18 tbox Exp $ */ #ifndef ISC_REGION_H #define ISC_REGION_H 1 +/*! \file isc/region.h */ + #include struct isc_region { @@ -45,7 +47,8 @@ struct isc_consttextregion { unsigned int length; }; -/* +/*@{*/ +/*! * The region structure is not opaque, and is usually directly manipulated. * Some macros are defined below for convenience. */ @@ -76,20 +79,21 @@ struct isc_consttextregion { _r->base += _l; \ _r->length -= _l; \ } while (0) +/*@}*/ int isc_region_compare(isc_region_t *r1, isc_region_t *r2); -/* +/*%< * Compares the contents of two regions * * Requires: - * 'r1' is a valid region - * 'r2' is a valid region + *\li 'r1' is a valid region + *\li 'r2' is a valid region * * Returns: - * < 0 if r1 is lexicographically less than r2 - * = 0 if r1 is lexicographically identical to r2 - * > 0 if r1 is lexicographically greater than r2 + *\li < 0 if r1 is lexicographically less than r2 + *\li = 0 if r1 is lexicographically identical to r2 + *\li > 0 if r1 is lexicographically greater than r2 */ #endif /* ISC_REGION_H */ diff --git a/contrib/ntp/lib/isc/include/isc/resource.h b/contrib/ntp/lib/isc/include/isc/resource.h new file mode 100644 index 000000000..747c9fdf4 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/resource.h @@ -0,0 +1,97 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: resource.h,v 1.13 2008/07/11 23:47:09 tbox Exp $ */ + +#ifndef ISC_RESOURCE_H +#define ISC_RESOURCE_H 1 + +/*! \file isc/resource.h */ + +#include +#include + +#define ISC_RESOURCE_UNLIMITED ((isc_resourcevalue_t)ISC_UINT64_MAX) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_resource_setlimit(isc_resource_t resource, isc_resourcevalue_t value); +/*%< + * Set the maximum limit for a system resource. + * + * Notes: + *\li If 'value' exceeds the maximum possible on the operating system, + * it is silently limited to that maximum -- or to "infinity", if + * the operating system has that concept. #ISC_RESOURCE_UNLIMITED + * can be used to explicitly ask for the maximum. + * + * Requires: + *\li 'resource' is a valid member of the isc_resource_t enumeration. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. + *\li #ISC_R_NOPERM The calling process did not have adequate permission + * to change the resource limit. + */ + +isc_result_t +isc_resource_getlimit(isc_resource_t resource, isc_resourcevalue_t *value); +/*%< + * Get the maximum limit for a system resource. + * + * Notes: + *\li 'value' is set to the maximum limit. + * + *\li #ISC_RESOURCE_UNLIMITED is the maximum value of isc_resourcevalue_t. + * + *\li On many (all?) Unix systems, RLIM_INFINITY is a valid value that is + * significantly less than #ISC_RESOURCE_UNLIMITED, but which in practice + * behaves the same. + * + *\li The current ISC libdns configuration file parser assigns a value + * of ISC_UINT32_MAX for a size_spec of "unlimited" and ISC_UNIT32_MAX - 1 + * for "default", the latter of which is supposed to represent "the + * limit that was in force when the server started". Since these are + * valid values in the middle of the range of isc_resourcevalue_t, + * there is the possibility for confusion over what exactly those + * particular values are supposed to represent in a particular context -- + * discrete integral values or generalized concepts. + * + * Requires: + *\li 'resource' is a valid member of the isc_resource_t enumeration. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. + */ + +isc_result_t +isc_resource_getcurlimit(isc_resource_t resource, isc_resourcevalue_t *value); +/*%< + * Same as isc_resource_getlimit(), but returns the current (soft) limit. + * + * Returns: + *\li #ISC_R_SUCCESS Success. + *\li #ISC_R_NOTIMPLEMENTED 'resource' is not a type known by the OS. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_RESOURCE_H */ + diff --git a/contrib/ntp/lib/isc/include/isc/result.h b/contrib/ntp/lib/isc/include/isc/result.h new file mode 100644 index 000000000..dcd457b3d --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/result.h @@ -0,0 +1,109 @@ +/* + * Copyright (C) 2004-2009, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_RESULT_H +#define ISC_RESULT_H 1 + +/*! \file isc/result.h */ + +#include +#include + +#define ISC_R_SUCCESS 0 /*%< success */ +#define ISC_R_NOMEMORY 1 /*%< out of memory */ +#define ISC_R_TIMEDOUT 2 /*%< timed out */ +#define ISC_R_NOTHREADS 3 /*%< no available threads */ +#define ISC_R_ADDRNOTAVAIL 4 /*%< address not available */ +#define ISC_R_ADDRINUSE 5 /*%< address in use */ +#define ISC_R_NOPERM 6 /*%< permission denied */ +#define ISC_R_NOCONN 7 /*%< no pending connections */ +#define ISC_R_NETUNREACH 8 /*%< network unreachable */ +#define ISC_R_HOSTUNREACH 9 /*%< host unreachable */ +#define ISC_R_NETDOWN 10 /*%< network down */ +#define ISC_R_HOSTDOWN 11 /*%< host down */ +#define ISC_R_CONNREFUSED 12 /*%< connection refused */ +#define ISC_R_NORESOURCES 13 /*%< not enough free resources */ +#define ISC_R_EOF 14 /*%< end of file */ +#define ISC_R_BOUND 15 /*%< socket already bound */ +#define ISC_R_RELOAD 16 /*%< reload */ +#define ISC_R_SUSPEND ISC_R_RELOAD /*%< alias of 'reload' */ +#define ISC_R_LOCKBUSY 17 /*%< lock busy */ +#define ISC_R_EXISTS 18 /*%< already exists */ +#define ISC_R_NOSPACE 19 /*%< ran out of space */ +#define ISC_R_CANCELED 20 /*%< operation canceled */ +#define ISC_R_NOTBOUND 21 /*%< socket is not bound */ +#define ISC_R_SHUTTINGDOWN 22 /*%< shutting down */ +#define ISC_R_NOTFOUND 23 /*%< not found */ +#define ISC_R_UNEXPECTEDEND 24 /*%< unexpected end of input */ +#define ISC_R_FAILURE 25 /*%< generic failure */ +#define ISC_R_IOERROR 26 /*%< I/O error */ +#define ISC_R_NOTIMPLEMENTED 27 /*%< not implemented */ +#define ISC_R_UNBALANCED 28 /*%< unbalanced parentheses */ +#define ISC_R_NOMORE 29 /*%< no more */ +#define ISC_R_INVALIDFILE 30 /*%< invalid file */ +#define ISC_R_BADBASE64 31 /*%< bad base64 encoding */ +#define ISC_R_UNEXPECTEDTOKEN 32 /*%< unexpected token */ +#define ISC_R_QUOTA 33 /*%< quota reached */ +#define ISC_R_UNEXPECTED 34 /*%< unexpected error */ +#define ISC_R_ALREADYRUNNING 35 /*%< already running */ +#define ISC_R_IGNORE 36 /*%< ignore */ +#define ISC_R_MASKNONCONTIG 37 /*%< addr mask not contiguous */ +#define ISC_R_FILENOTFOUND 38 /*%< file not found */ +#define ISC_R_FILEEXISTS 39 /*%< file already exists */ +#define ISC_R_NOTCONNECTED 40 /*%< socket is not connected */ +#define ISC_R_RANGE 41 /*%< out of range */ +#define ISC_R_NOENTROPY 42 /*%< out of entropy */ +#define ISC_R_MULTICAST 43 /*%< invalid use of multicast */ +#define ISC_R_NOTFILE 44 /*%< not a file */ +#define ISC_R_NOTDIRECTORY 45 /*%< not a directory */ +#define ISC_R_QUEUEFULL 46 /*%< queue is full */ +#define ISC_R_FAMILYMISMATCH 47 /*%< address family mismatch */ +#define ISC_R_FAMILYNOSUPPORT 48 /*%< AF not supported */ +#define ISC_R_BADHEX 49 /*%< bad hex encoding */ +#define ISC_R_TOOMANYOPENFILES 50 /*%< too many open files */ +#define ISC_R_NOTBLOCKING 51 /*%< not blocking */ +#define ISC_R_UNBALANCEDQUOTES 52 /*%< unbalanced quotes */ +#define ISC_R_INPROGRESS 53 /*%< operation in progress */ +#define ISC_R_CONNECTIONRESET 54 /*%< connection reset */ +#define ISC_R_SOFTQUOTA 55 /*%< soft quota reached */ +#define ISC_R_BADNUMBER 56 /*%< not a valid number */ +#define ISC_R_DISABLED 57 /*%< disabled */ +#define ISC_R_MAXSIZE 58 /*%< max size */ +#define ISC_R_BADADDRESSFORM 59 /*%< invalid address format */ +#define ISC_R_BADBASE32 60 /*%< bad base32 encoding */ +#define ISC_R_UNSET 61 /*%< unset */ + +/*% Not a result code: the number of results. */ +#define ISC_R_NRESULTS 62 + +ISC_LANG_BEGINDECLS + +const char * +isc_result_totext(isc_result_t); +/*%< + * Convert an isc_result_t into a string message describing the result. + */ + +isc_result_t +isc_result_register(unsigned int base, unsigned int nresults, + const char **text, isc_msgcat_t *msgcat, int set); + +ISC_LANG_ENDDECLS + +#endif /* ISC_RESULT_H */ diff --git a/contrib/ntp/lib/isc/include/isc/resultclass.h b/contrib/ntp/lib/isc/include/isc/resultclass.h new file mode 100644 index 000000000..d91e800e0 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/resultclass.h @@ -0,0 +1,51 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: resultclass.h,v 1.20 2009/09/02 23:48:03 tbox Exp $ */ + +#ifndef ISC_RESULTCLASS_H +#define ISC_RESULTCLASS_H 1 + + +/*! \file isc/resultclass.h + * \brief Registry of Predefined Result Type Classes + * + * A result class number is an unsigned 16 bit number. Each class may + * contain up to 65536 results. A result code is formed by adding the + * result number within the class to the class number multiplied by 65536. + * + * Classes < 1024 are reserved for ISC use. + * Result classes >= 1024 and <= 65535 are reserved for application use. + */ + +#define ISC_RESULTCLASS_FROMNUM(num) ((num) << 16) +#define ISC_RESULTCLASS_TONUM(rclass) ((rclass) >> 16) +#define ISC_RESULTCLASS_SIZE 65536 +#define ISC_RESULTCLASS_INCLASS(rclass, result) \ + ((rclass) == ((result) & 0xFFFF0000)) + + +#define ISC_RESULTCLASS_ISC ISC_RESULTCLASS_FROMNUM(0) +#define ISC_RESULTCLASS_DNS ISC_RESULTCLASS_FROMNUM(1) +#define ISC_RESULTCLASS_DST ISC_RESULTCLASS_FROMNUM(2) +#define ISC_RESULTCLASS_DNSRCODE ISC_RESULTCLASS_FROMNUM(3) +#define ISC_RESULTCLASS_OMAPI ISC_RESULTCLASS_FROMNUM(4) +#define ISC_RESULTCLASS_ISCCC ISC_RESULTCLASS_FROMNUM(5) +#define ISC_RESULTCLASS_DHCP ISC_RESULTCLASS_FROMNUM(6) + + +#endif /* ISC_RESULTCLASS_H */ diff --git a/contrib/ntp/lib/isc/include/isc/rwlock.h b/contrib/ntp/lib/isc/include/isc/rwlock.h new file mode 100644 index 000000000..28052cdd7 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/rwlock.h @@ -0,0 +1,135 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: rwlock.h,v 1.28 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_RWLOCK_H +#define ISC_RWLOCK_H 1 + +/*! \file isc/rwlock.h */ + +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +typedef enum { + isc_rwlocktype_none = 0, + isc_rwlocktype_read, + isc_rwlocktype_write +} isc_rwlocktype_t; + +#ifdef ISC_PLATFORM_USETHREADS +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) +#define ISC_RWLOCK_USEATOMIC 1 +#endif + +struct isc_rwlock { + /* Unlocked. */ + unsigned int magic; + isc_mutex_t lock; + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + /* + * When some atomic instructions with hardware assistance are + * available, rwlock will use those so that concurrent readers do not + * interfere with each other through mutex as long as no writers + * appear, massively reducing the lock overhead in the typical case. + * + * The basic algorithm of this approach is the "simple + * writer-preference lock" shown in the following URL: + * http://www.cs.rochester.edu/u/scott/synchronization/pseudocode/rw.html + * but our implementation does not rely on the spin lock unlike the + * original algorithm to be more portable as a user space application. + */ + + /* Read or modified atomically. */ + isc_int32_t write_requests; + isc_int32_t write_completions; + isc_int32_t cnt_and_flag; + + /* Locked by lock. */ + isc_condition_t readable; + isc_condition_t writeable; + unsigned int readers_waiting; + + /* Locked by rwlock itself. */ + unsigned int write_granted; + + /* Unlocked. */ + unsigned int write_quota; + +#else /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ + + /*%< Locked by lock. */ + isc_condition_t readable; + isc_condition_t writeable; + isc_rwlocktype_t type; + + /*% The number of threads that have the lock. */ + unsigned int active; + + /*% + * The number of lock grants made since the lock was last switched + * from reading to writing or vice versa; used in determining + * when the quota is reached and it is time to switch. + */ + unsigned int granted; + + unsigned int readers_waiting; + unsigned int writers_waiting; + unsigned int read_quota; + unsigned int write_quota; + isc_rwlocktype_t original; +#endif /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ +}; +#else /* ISC_PLATFORM_USETHREADS */ +struct isc_rwlock { + unsigned int magic; + isc_rwlocktype_t type; + unsigned int active; +}; +#endif /* ISC_PLATFORM_USETHREADS */ + + +isc_result_t +isc_rwlock_init(isc_rwlock_t *rwl, unsigned int read_quota, + unsigned int write_quota); + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type); + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type); + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type); + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl); + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl); + +void +isc_rwlock_destroy(isc_rwlock_t *rwl); + +ISC_LANG_ENDDECLS + +#endif /* ISC_RWLOCK_H */ diff --git a/contrib/ntp/lib/isc/include/isc/serial.h b/contrib/ntp/lib/isc/include/isc/serial.h new file mode 100644 index 000000000..a5e03970c --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/serial.h @@ -0,0 +1,75 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: serial.h,v 1.18 2009/01/18 23:48:14 tbox Exp $ */ + +#ifndef ISC_SERIAL_H +#define ISC_SERIAL_H 1 + +#include +#include + +/*! \file isc/serial.h + * \brief Implement 32 bit serial space arithmetic comparison functions. + * Note: Undefined results are returned as ISC_FALSE. + */ + +/*** + *** Functions + ***/ + +ISC_LANG_BEGINDECLS + +isc_boolean_t +isc_serial_lt(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' < 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_gt(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' > 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_le(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' <= 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_ge(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' >= 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_eq(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' == 'b' otherwise false. + */ + +isc_boolean_t +isc_serial_ne(isc_uint32_t a, isc_uint32_t b); +/*%< + * Return true if 'a' != 'b' otherwise false. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SERIAL_H */ diff --git a/contrib/ntp/lib/isc/include/isc/sha1.h b/contrib/ntp/lib/isc/include/isc/sha1.h new file mode 100644 index 000000000..313ff9639 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/sha1.h @@ -0,0 +1,68 @@ +/* + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +#ifndef ISC_SHA1_H +#define ISC_SHA1_H 1 + +/* $Id: sha1.h,v 1.19 2009/02/06 23:47:42 tbox Exp $ */ + +/* $NetBSD: sha1.h,v 1.2 1998/05/29 22:55:44 thorpej Exp $ */ + +/*! \file isc/sha1.h + * \brief SHA-1 in C + * \author By Steve Reid + * \note 100% Public Domain + */ + +#include +#include +#include + +#define ISC_SHA1_DIGESTLENGTH 20U +#define ISC_SHA1_BLOCK_LENGTH 64U + +#ifdef ISC_PLATFORM_OPENSSLHASH +#include + +typedef EVP_MD_CTX isc_sha1_t; + +#else + +typedef struct { + isc_uint32_t state[5]; + isc_uint32_t count[2]; + unsigned char buffer[ISC_SHA1_BLOCK_LENGTH]; +} isc_sha1_t; +#endif + +ISC_LANG_BEGINDECLS + +void +isc_sha1_init(isc_sha1_t *ctx); + +void +isc_sha1_invalidate(isc_sha1_t *ctx); + +void +isc_sha1_update(isc_sha1_t *ctx, const unsigned char *data, unsigned int len); + +void +isc_sha1_final(isc_sha1_t *ctx, unsigned char *digest); + +ISC_LANG_ENDDECLS + +#endif /* ISC_SHA1_H */ diff --git a/contrib/ntp/lib/isc/include/isc/sha2.h b/contrib/ntp/lib/isc/include/isc/sha2.h new file mode 100644 index 000000000..0c9dea8eb --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/sha2.h @@ -0,0 +1,145 @@ +/* + * Copyright (C) 2005-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: sha2.h,v 1.12 2009/10/22 02:21:31 each Exp $ */ + +/* $FreeBSD: 258945 2013-12-04 21:33:17Z roberto $ */ +/* $KAME: sha2.h,v 1.3 2001/03/12 08:27:48 itojun Exp $ */ + +/* + * sha2.h + * + * Version 1.0.0beta1 + * + * Written by Aaron D. Gifford + * + * Copyright 2000 Aaron D. Gifford. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the copyright holder nor the names of contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) AND CONTRIBUTOR(S) ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR(S) OR CONTRIBUTOR(S) BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + */ + +#ifndef ISC_SHA2_H +#define ISC_SHA2_H + +#include +#include +#include + +/*** SHA-224/256/384/512 Various Length Definitions ***********************/ + +#define ISC_SHA224_BLOCK_LENGTH 64U +#define ISC_SHA224_DIGESTLENGTH 28U +#define ISC_SHA224_DIGESTSTRINGLENGTH (ISC_SHA224_DIGESTLENGTH * 2 + 1) +#define ISC_SHA256_BLOCK_LENGTH 64U +#define ISC_SHA256_DIGESTLENGTH 32U +#define ISC_SHA256_DIGESTSTRINGLENGTH (ISC_SHA256_DIGESTLENGTH * 2 + 1) +#define ISC_SHA384_BLOCK_LENGTH 128 +#define ISC_SHA384_DIGESTLENGTH 48U +#define ISC_SHA384_DIGESTSTRINGLENGTH (ISC_SHA384_DIGESTLENGTH * 2 + 1) +#define ISC_SHA512_BLOCK_LENGTH 128U +#define ISC_SHA512_DIGESTLENGTH 64U +#define ISC_SHA512_DIGESTSTRINGLENGTH (ISC_SHA512_DIGESTLENGTH * 2 + 1) + +/*** SHA-256/384/512 Context Structures *******************************/ + +#ifdef ISC_PLATFORM_OPENSSLHASH +#include + +typedef EVP_MD_CTX isc_sha256_t; +typedef EVP_MD_CTX isc_sha512_t; + +#else + +/* + * Keep buffer immediately after bitcount to preserve alignment. + */ +typedef struct { + isc_uint32_t state[8]; + isc_uint64_t bitcount; + isc_uint8_t buffer[ISC_SHA256_BLOCK_LENGTH]; +} isc_sha256_t; + +/* + * Keep buffer immediately after bitcount to preserve alignment. + */ +typedef struct { + isc_uint64_t state[8]; + isc_uint64_t bitcount[2]; + isc_uint8_t buffer[ISC_SHA512_BLOCK_LENGTH]; +} isc_sha512_t; +#endif + +typedef isc_sha256_t isc_sha224_t; +typedef isc_sha512_t isc_sha384_t; + +ISC_LANG_BEGINDECLS + +/*** SHA-224/256/384/512 Function Prototypes ******************************/ + +void isc_sha224_init (isc_sha224_t *); +void isc_sha224_invalidate (isc_sha224_t *); +void isc_sha224_update (isc_sha224_t *, const isc_uint8_t *, size_t); +void isc_sha224_final (isc_uint8_t[ISC_SHA224_DIGESTLENGTH], isc_sha224_t *); +char *isc_sha224_end (isc_sha224_t *, char[ISC_SHA224_DIGESTSTRINGLENGTH]); +char *isc_sha224_data (const isc_uint8_t *, size_t, char[ISC_SHA224_DIGESTSTRINGLENGTH]); + +void isc_sha256_init (isc_sha256_t *); +void isc_sha256_invalidate (isc_sha256_t *); +void isc_sha256_update (isc_sha256_t *, const isc_uint8_t *, size_t); +void isc_sha256_final (isc_uint8_t[ISC_SHA256_DIGESTLENGTH], isc_sha256_t *); +char *isc_sha256_end (isc_sha256_t *, char[ISC_SHA256_DIGESTSTRINGLENGTH]); +char *isc_sha256_data (const isc_uint8_t *, size_t, char[ISC_SHA256_DIGESTSTRINGLENGTH]); + +void isc_sha384_init (isc_sha384_t *); +void isc_sha384_invalidate (isc_sha384_t *); +void isc_sha384_update (isc_sha384_t *, const isc_uint8_t *, size_t); +void isc_sha384_final (isc_uint8_t[ISC_SHA384_DIGESTLENGTH], isc_sha384_t *); +char *isc_sha384_end (isc_sha384_t *, char[ISC_SHA384_DIGESTSTRINGLENGTH]); +char *isc_sha384_data (const isc_uint8_t *, size_t, char[ISC_SHA384_DIGESTSTRINGLENGTH]); + +void isc_sha512_init (isc_sha512_t *); +void isc_sha512_invalidate (isc_sha512_t *); +void isc_sha512_update (isc_sha512_t *, const isc_uint8_t *, size_t); +void isc_sha512_final (isc_uint8_t[ISC_SHA512_DIGESTLENGTH], isc_sha512_t *); +char *isc_sha512_end (isc_sha512_t *, char[ISC_SHA512_DIGESTSTRINGLENGTH]); +char *isc_sha512_data (const isc_uint8_t *, size_t, char[ISC_SHA512_DIGESTSTRINGLENGTH]); + +ISC_LANG_ENDDECLS + +#endif /* ISC_SHA2_H */ diff --git a/contrib/ntp/include/isc/sockaddr.h b/contrib/ntp/lib/isc/include/isc/sockaddr.h similarity index 59% rename from contrib/ntp/include/isc/sockaddr.h rename to contrib/ntp/lib/isc/include/isc/sockaddr.h index 635af3811..1e6914222 100644 --- a/contrib/ntp/include/isc/sockaddr.h +++ b/contrib/ntp/lib/isc/include/isc/sockaddr.h @@ -1,34 +1,42 @@ /* - * Copyright (C) 1998-2002 Internet Software Consortium. + * Copyright (C) 2004-2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: sockaddr.h,v 1.39 2002/04/03 06:38:36 marka Exp $ */ +/* $Id: sockaddr.h,v 1.57 2009/01/18 23:48:14 tbox Exp $ */ #ifndef ISC_SOCKADDR_H #define ISC_SOCKADDR_H 1 +/*! \file isc/sockaddr.h */ + #include #include #include +#ifdef ISC_PLATFORM_HAVESYSUNH +#include +#endif struct isc_sockaddr { union { struct sockaddr sa; struct sockaddr_in sin; struct sockaddr_in6 sin6; +#ifdef ISC_PLATFORM_HAVESYSUNH + struct sockaddr_un sunix; +#endif } type; unsigned int length; /* XXXRTH beginning? */ ISC_LINK(struct isc_sockaddr) link; @@ -36,17 +44,36 @@ struct isc_sockaddr { typedef ISC_LIST(struct isc_sockaddr) isc_sockaddrlist_t; +#define ISC_SOCKADDR_CMPADDR 0x0001 /*%< compare the address + * sin_addr/sin6_addr */ +#define ISC_SOCKADDR_CMPPORT 0x0002 /*%< compare the port + * sin_port/sin6_port */ +#define ISC_SOCKADDR_CMPSCOPE 0x0004 /*%< compare the scope + * sin6_scope */ +#define ISC_SOCKADDR_CMPSCOPEZERO 0x0008 /*%< when comparing scopes + * zero scopes always match */ + ISC_LANG_BEGINDECLS +isc_boolean_t +isc_sockaddr_compare(const isc_sockaddr_t *a, const isc_sockaddr_t *b, + unsigned int flags); +/*%< + * Compare the elements of the two address ('a' and 'b') as specified + * by 'flags' and report if they are equal or not. + * + * 'flags' is set from ISC_SOCKADDR_CMP*. + */ + isc_boolean_t isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b); -/* +/*%< * Return ISC_TRUE iff the socket addresses 'a' and 'b' are equal. */ isc_boolean_t isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b); -/* +/*%< * Return ISC_TRUE iff the address parts of the socket addresses * 'a' and 'b' are equal, ignoring the ports. */ @@ -54,14 +81,15 @@ isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b); isc_boolean_t isc_sockaddr_eqaddrprefix(const isc_sockaddr_t *a, const isc_sockaddr_t *b, unsigned int prefixlen); -/* +/*%< * Return ISC_TRUE iff the most significant 'prefixlen' bits of the * socket addresses 'a' and 'b' are equal, ignoring the ports. + * If 'b''s scope is zero then 'a''s scope will be ignored. */ unsigned int isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only); -/* +/*%< * Return a hash value for the socket address 'sockaddr'. If 'address_only' * is ISC_TRUE, the hash value will not depend on the port. * @@ -71,129 +99,140 @@ isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only); void isc_sockaddr_any(isc_sockaddr_t *sockaddr); -/* +/*%< * Return the IPv4 wildcard address. */ void isc_sockaddr_any6(isc_sockaddr_t *sockaddr); -/* +/*%< * Return the IPv6 wildcard address. */ void isc_sockaddr_anyofpf(isc_sockaddr_t *sockaddr, int family); -/* +/*%< * Set '*sockaddr' to the wildcard address of protocol family * 'family'. * * Requires: - * 'family' is AF_INET or AF_INET6. + * \li 'family' is AF_INET or AF_INET6. */ void isc_sockaddr_fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, in_port_t port); -/* +/*%< * Construct an isc_sockaddr_t from an IPv4 address and port. */ void isc_sockaddr_fromin6(isc_sockaddr_t *sockaddr, const struct in6_addr *ina6, in_port_t port); -/* +/*%< * Construct an isc_sockaddr_t from an IPv6 address and port. */ void isc_sockaddr_v6fromin(isc_sockaddr_t *sockaddr, const struct in_addr *ina, in_port_t port); -/* +/*%< * Construct an IPv6 isc_sockaddr_t representing a mapped IPv4 address. */ void isc_sockaddr_fromnetaddr(isc_sockaddr_t *sockaddr, const isc_netaddr_t *na, in_port_t port); -/* +/*%< * Construct an isc_sockaddr_t from an isc_netaddr_t and port. */ int isc_sockaddr_pf(const isc_sockaddr_t *sockaddr); -/* +/*%< * Get the protocol family of 'sockaddr'. * * Requires: * - * 'sockaddr' is a valid sockaddr with an address family of AF_INET + *\li 'sockaddr' is a valid sockaddr with an address family of AF_INET * or AF_INET6. * * Returns: * - * The protocol family of 'sockaddr', e.g. PF_INET or PF_INET6. + *\li The protocol family of 'sockaddr', e.g. PF_INET or PF_INET6. */ void isc_sockaddr_setport(isc_sockaddr_t *sockaddr, in_port_t port); -/* +/*%< * Set the port of 'sockaddr' to 'port'. */ in_port_t -isc_sockaddr_getport(isc_sockaddr_t *sockaddr); -/* +isc_sockaddr_getport(const isc_sockaddr_t *sockaddr); +/*%< * Get the port stored in 'sockaddr'. */ isc_result_t isc_sockaddr_totext(const isc_sockaddr_t *sockaddr, isc_buffer_t *target); -/* +/*%< * Append a text representation of 'sockaddr' to the buffer 'target'. * The text will include both the IP address (v4 or v6) and the port. * The text is null terminated, but the terminating null is not * part of the buffer's used region. * * Returns: - * ISC_R_SUCCESS - * ISC_R_NOSPACE The text or the null termination did not fit. + * \li ISC_R_SUCCESS + * \li ISC_R_NOSPACE The text or the null termination did not fit. */ void isc_sockaddr_format(const isc_sockaddr_t *sa, char *array, unsigned int size); -/* +/*%< * Format a human-readable representation of the socket address '*sa' * into the character array 'array', which is of size 'size'. * The resulting string is guaranteed to be null-terminated. */ isc_boolean_t -isc_sockaddr_ismulticast(isc_sockaddr_t *sa); -/* - * Returns ISC_TRUE if the address is a multicast address. +isc_sockaddr_ismulticast(const isc_sockaddr_t *sa); +/*%< + * Returns #ISC_TRUE if the address is a multicast address. */ isc_boolean_t -isc_sockaddr_isexperimental(isc_sockaddr_t *sa); +isc_sockaddr_isexperimental(const isc_sockaddr_t *sa); /* * Returns ISC_TRUE if the address is a experimental (CLASS E) address. */ isc_boolean_t -isc_sockaddr_islinklocal(isc_sockaddr_t *sa); -/* - * Returns ISC_TRUE if the address is a link local addresss. +isc_sockaddr_islinklocal(const isc_sockaddr_t *sa); +/*%< + * Returns ISC_TRUE if the address is a link local address. */ isc_boolean_t -isc_sockaddr_issitelocal(isc_sockaddr_t *sa); -/* +isc_sockaddr_issitelocal(const isc_sockaddr_t *sa); +/*%< * Returns ISC_TRUE if the address is a sitelocal address. */ -#define ISC_SOCKADDR_FORMATSIZE \ - sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX#YYYYY") +isc_result_t +isc_sockaddr_frompath(isc_sockaddr_t *sockaddr, const char *path); /* + * Create a UNIX domain sockaddr that refers to path. + * + * Returns: + * \li ISC_R_NOSPACE + * \li ISC_R_NOTIMPLEMENTED + * \li ISC_R_SUCCESS + */ + +#define ISC_SOCKADDR_FORMATSIZE \ + sizeof("xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:XXX.XXX.XXX.XXX%SSSSSSSSSS#YYYYY") +/*%< * Minimum size of array to pass to isc_sockaddr_format(). */ diff --git a/contrib/ntp/lib/isc/include/isc/socket.h b/contrib/ntp/lib/isc/include/isc/socket.h new file mode 100644 index 000000000..46e05a077 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/socket.h @@ -0,0 +1,1168 @@ +/* + * Copyright (C) 2004-2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_SOCKET_H +#define ISC_SOCKET_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/socket.h + * \brief Provides TCP and UDP sockets for network I/O. The sockets are event + * sources in the task system. + * + * When I/O completes, a completion event for the socket is posted to the + * event queue of the task which requested the I/O. + * + * \li MP: + * The module ensures appropriate synchronization of data structures it + * creates and manipulates. + * Clients of this module must not be holding a socket's task's lock when + * making a call that affects that socket. Failure to follow this rule + * can result in deadlock. + * The caller must ensure that isc_socketmgr_destroy() is called only + * once for a given manager. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports + ***/ + +#include +#include +#include +#include +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Constants + ***/ + +/*% + * Maximum number of buffers in a scatter/gather read/write. The operating + * system in use must support at least this number (plus one on some.) + */ +#define ISC_SOCKET_MAXSCATTERGATHER 8 + +/*% + * In isc_socket_bind() set socket option SO_REUSEADDR prior to calling + * bind() if a non zero port is specified (AF_INET and AF_INET6). + */ +#define ISC_SOCKET_REUSEADDRESS 0x01U + +/*% + * Statistics counters. Used as isc_statscounter_t values. + */ +enum { + isc_sockstatscounter_udp4open = 0, + isc_sockstatscounter_udp6open = 1, + isc_sockstatscounter_tcp4open = 2, + isc_sockstatscounter_tcp6open = 3, + isc_sockstatscounter_unixopen = 4, + + isc_sockstatscounter_udp4openfail = 5, + isc_sockstatscounter_udp6openfail = 6, + isc_sockstatscounter_tcp4openfail = 7, + isc_sockstatscounter_tcp6openfail = 8, + isc_sockstatscounter_unixopenfail = 9, + + isc_sockstatscounter_udp4close = 10, + isc_sockstatscounter_udp6close = 11, + isc_sockstatscounter_tcp4close = 12, + isc_sockstatscounter_tcp6close = 13, + isc_sockstatscounter_unixclose = 14, + isc_sockstatscounter_fdwatchclose = 15, + + isc_sockstatscounter_udp4bindfail = 16, + isc_sockstatscounter_udp6bindfail = 17, + isc_sockstatscounter_tcp4bindfail = 18, + isc_sockstatscounter_tcp6bindfail = 19, + isc_sockstatscounter_unixbindfail = 20, + isc_sockstatscounter_fdwatchbindfail = 21, + + isc_sockstatscounter_udp4connect = 22, + isc_sockstatscounter_udp6connect = 23, + isc_sockstatscounter_tcp4connect = 24, + isc_sockstatscounter_tcp6connect = 25, + isc_sockstatscounter_unixconnect = 26, + isc_sockstatscounter_fdwatchconnect = 27, + + isc_sockstatscounter_udp4connectfail = 28, + isc_sockstatscounter_udp6connectfail = 29, + isc_sockstatscounter_tcp4connectfail = 30, + isc_sockstatscounter_tcp6connectfail = 31, + isc_sockstatscounter_unixconnectfail = 32, + isc_sockstatscounter_fdwatchconnectfail = 33, + + isc_sockstatscounter_tcp4accept = 34, + isc_sockstatscounter_tcp6accept = 35, + isc_sockstatscounter_unixaccept = 36, + + isc_sockstatscounter_tcp4acceptfail = 37, + isc_sockstatscounter_tcp6acceptfail = 38, + isc_sockstatscounter_unixacceptfail = 39, + + isc_sockstatscounter_udp4sendfail = 40, + isc_sockstatscounter_udp6sendfail = 41, + isc_sockstatscounter_tcp4sendfail = 42, + isc_sockstatscounter_tcp6sendfail = 43, + isc_sockstatscounter_unixsendfail = 44, + isc_sockstatscounter_fdwatchsendfail = 45, + + isc_sockstatscounter_udp4recvfail = 46, + isc_sockstatscounter_udp6recvfail = 47, + isc_sockstatscounter_tcp4recvfail = 48, + isc_sockstatscounter_tcp6recvfail = 49, + isc_sockstatscounter_unixrecvfail = 50, + isc_sockstatscounter_fdwatchrecvfail = 51, + + isc_sockstatscounter_max = 52 +}; + +/*** + *** Types + ***/ + +struct isc_socketevent { + ISC_EVENT_COMMON(isc_socketevent_t); + isc_result_t result; /*%< OK, EOF, whatever else */ + unsigned int minimum; /*%< minimum i/o for event */ + unsigned int n; /*%< bytes read or written */ + unsigned int offset; /*%< offset into buffer list */ + isc_region_t region; /*%< for single-buffer i/o */ + isc_bufferlist_t bufferlist; /*%< list of buffers */ + isc_sockaddr_t address; /*%< source address */ + isc_time_t timestamp; /*%< timestamp of packet recv */ + struct in6_pktinfo pktinfo; /*%< ipv6 pktinfo */ + isc_uint32_t attributes; /*%< see below */ + isc_eventdestructor_t destroy; /*%< original destructor */ +}; + +typedef struct isc_socket_newconnev isc_socket_newconnev_t; +struct isc_socket_newconnev { + ISC_EVENT_COMMON(isc_socket_newconnev_t); + isc_socket_t * newsocket; + isc_result_t result; /*%< OK, EOF, whatever else */ + isc_sockaddr_t address; /*%< source address */ +}; + +typedef struct isc_socket_connev isc_socket_connev_t; +struct isc_socket_connev { + ISC_EVENT_COMMON(isc_socket_connev_t); + isc_result_t result; /*%< OK, EOF, whatever else */ +}; + +/*@{*/ +/*! + * _ATTACHED: Internal use only. + * _TRUNC: Packet was truncated on receive. + * _CTRUNC: Packet control information was truncated. This can + * indicate that the packet is not complete, even though + * all the data is valid. + * _TIMESTAMP: The timestamp member is valid. + * _PKTINFO: The pktinfo member is valid. + * _MULTICAST: The UDP packet was received via a multicast transmission. + */ +#define ISC_SOCKEVENTATTR_ATTACHED 0x80000000U /* internal */ +#define ISC_SOCKEVENTATTR_TRUNC 0x00800000U /* public */ +#define ISC_SOCKEVENTATTR_CTRUNC 0x00400000U /* public */ +#define ISC_SOCKEVENTATTR_TIMESTAMP 0x00200000U /* public */ +#define ISC_SOCKEVENTATTR_PKTINFO 0x00100000U /* public */ +#define ISC_SOCKEVENTATTR_MULTICAST 0x00080000U /* public */ +/*@}*/ + +#define ISC_SOCKEVENT_ANYEVENT (0) +#define ISC_SOCKEVENT_RECVDONE (ISC_EVENTCLASS_SOCKET + 1) +#define ISC_SOCKEVENT_SENDDONE (ISC_EVENTCLASS_SOCKET + 2) +#define ISC_SOCKEVENT_NEWCONN (ISC_EVENTCLASS_SOCKET + 3) +#define ISC_SOCKEVENT_CONNECT (ISC_EVENTCLASS_SOCKET + 4) + +/* + * Internal events. + */ +#define ISC_SOCKEVENT_INTR (ISC_EVENTCLASS_SOCKET + 256) +#define ISC_SOCKEVENT_INTW (ISC_EVENTCLASS_SOCKET + 257) + +typedef enum { + isc_sockettype_udp = 1, + isc_sockettype_tcp = 2, + isc_sockettype_unix = 3, + isc_sockettype_fdwatch = 4 +} isc_sockettype_t; + +/*@{*/ +/*! + * How a socket should be shutdown in isc_socket_shutdown() calls. + */ +#define ISC_SOCKSHUT_RECV 0x00000001 /*%< close read side */ +#define ISC_SOCKSHUT_SEND 0x00000002 /*%< close write side */ +#define ISC_SOCKSHUT_ALL 0x00000003 /*%< close them all */ +/*@}*/ + +/*@{*/ +/*! + * What I/O events to cancel in isc_socket_cancel() calls. + */ +#define ISC_SOCKCANCEL_RECV 0x00000001 /*%< cancel recv */ +#define ISC_SOCKCANCEL_SEND 0x00000002 /*%< cancel send */ +#define ISC_SOCKCANCEL_ACCEPT 0x00000004 /*%< cancel accept */ +#define ISC_SOCKCANCEL_CONNECT 0x00000008 /*%< cancel connect */ +#define ISC_SOCKCANCEL_ALL 0x0000000f /*%< cancel everything */ +/*@}*/ + +/*@{*/ +/*! + * Flags for isc_socket_send() and isc_socket_recv() calls. + */ +#define ISC_SOCKFLAG_IMMEDIATE 0x00000001 /*%< send event only if needed */ +#define ISC_SOCKFLAG_NORETRY 0x00000002 /*%< drop failed UDP sends */ +/*@}*/ + +/*@{*/ +/*! + * Flags for fdwatchcreate. + */ +#define ISC_SOCKFDWATCH_READ 0x00000001 /*%< watch for readable */ +#define ISC_SOCKFDWATCH_WRITE 0x00000002 /*%< watch for writable */ +/*@}*/ + +/*% Socket and socket manager methods */ +typedef struct isc_socketmgrmethods { + void (*destroy)(isc_socketmgr_t **managerp); + isc_result_t (*socketcreate)(isc_socketmgr_t *manager, int pf, + isc_sockettype_t type, + isc_socket_t **socketp); + isc_result_t (*fdwatchcreate)(isc_socketmgr_t *manager, int fd, + int flags, + isc_sockfdwatch_t callback, + void *cbarg, isc_task_t *task, + isc_socket_t **socketp); +} isc_socketmgrmethods_t; + +typedef struct isc_socketmethods { + void (*attach)(isc_socket_t *sock, + isc_socket_t **socketp); + void (*detach)(isc_socket_t **socketp); + isc_result_t (*bind)(isc_socket_t *sock, isc_sockaddr_t *sockaddr, + unsigned int options); + isc_result_t (*sendto)(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, + const void *arg, isc_sockaddr_t *address, + struct in6_pktinfo *pktinfo); + isc_result_t (*connect)(isc_socket_t *sock, isc_sockaddr_t *addr, + isc_task_t *task, isc_taskaction_t action, + const void *arg); + isc_result_t (*recv)(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg); + void (*cancel)(isc_socket_t *sock, isc_task_t *task, + unsigned int how); + isc_result_t (*getsockname)(isc_socket_t *sock, + isc_sockaddr_t *addressp); + isc_sockettype_t (*gettype)(isc_socket_t *sock); + void (*ipv6only)(isc_socket_t *sock, isc_boolean_t yes); + isc_result_t (*fdwatchpoke)(isc_socket_t *sock, int flags); + isc_result_t (*dup)(isc_socket_t *sock, + isc_socket_t **socketp); + int (*getfd)(isc_socket_t *sock); +} isc_socketmethods_t; + +/*% + * This structure is actually just the common prefix of a socket manager + * object implementation's version of an isc_socketmgr_t. + * \brief + * Direct use of this structure by clients is forbidden. socket implementations + * may change the structure. 'magic' must be ISCAPI_SOCKETMGR_MAGIC for any + * of the isc_socket_ routines to work. socket implementations must maintain + * all socket invariants. + * In effect, this definition is used only for non-BIND9 version ("export") + * of the library, and the export version does not work for win32. So, to avoid + * the definition conflict with win32/socket.c, we enable this definition only + * for non-Win32 (i.e. Unix) platforms. + */ +#ifndef WIN32 +struct isc_socketmgr { + unsigned int impmagic; + unsigned int magic; + isc_socketmgrmethods_t *methods; +}; +#endif + +#define ISCAPI_SOCKETMGR_MAGIC ISC_MAGIC('A','s','m','g') +#define ISCAPI_SOCKETMGR_VALID(m) ((m) != NULL && \ + (m)->magic == ISCAPI_SOCKETMGR_MAGIC) + +/*% + * This is the common prefix of a socket object. The same note as + * that for the socketmgr structure applies. + */ +#ifndef WIN32 +struct isc_socket { + unsigned int impmagic; + unsigned int magic; + isc_socketmethods_t *methods; +}; +#endif + +#define ISCAPI_SOCKET_MAGIC ISC_MAGIC('A','s','c','t') +#define ISCAPI_SOCKET_VALID(s) ((s) != NULL && \ + (s)->magic == ISCAPI_SOCKET_MAGIC) + +/*** + *** Socket and Socket Manager Functions + *** + *** Note: all Ensures conditions apply only if the result is success for + *** those functions which return an isc_result. + ***/ + +isc_result_t +isc_socket_fdwatchcreate(isc_socketmgr_t *manager, + int fd, + int flags, + isc_sockfdwatch_t callback, + void *cbarg, + isc_task_t *task, + isc_socket_t **socketp); +/*%< + * Create a new file descriptor watch socket managed by 'manager'. + * + * Note: + * + *\li 'fd' is the already-opened file descriptor. + *\li This function is not available on Windows. + *\li The callback function is called "in-line" - this means the function + * needs to return as fast as possible, as all other I/O will be suspended + * until the callback completes. + * + * Requires: + * + *\li 'manager' is a valid manager + * + *\li 'socketp' is a valid pointer, and *socketp == NULL + * + *\li 'fd' be opened. + * + * Ensures: + * + * '*socketp' is attached to the newly created fdwatch socket + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_NORESOURCES + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_fdwatchpoke(isc_socket_t *sock, + int flags); +/*%< + * Poke a file descriptor watch socket informing the manager that it + * should restart watching the socket + * + * Note: + * + *\li 'sock' is the socket returned by isc_socket_fdwatchcreate + * + *\li 'flags' indicates what the manager should watch for on the socket + * in addition to what it may already be watching. It can be one or + * both of ISC_SOCKFDWATCH_READ and ISC_SOCKFDWATCH_WRITE. To + * temporarily disable watching on a socket the value indicating + * no more data should be returned from the call back routine. + * + *\li This function is not available on Windows. + * + * Requires: + * + *\li 'sock' is a valid isc socket + * + * + * Returns: + * + *\li #ISC_R_SUCCESS + */ + +isc_result_t +isc_socket_create(isc_socketmgr_t *manager, + int pf, + isc_sockettype_t type, + isc_socket_t **socketp); +/*%< + * Create a new 'type' socket managed by 'manager'. + * + * For isc_sockettype_fdwatch sockets you should use isc_socket_fdwatchcreate() + * rather than isc_socket_create(). + * + * Note: + * + *\li 'pf' is the desired protocol family, e.g. PF_INET or PF_INET6. + * + * Requires: + * + *\li 'manager' is a valid manager + * + *\li 'socketp' is a valid pointer, and *socketp == NULL + * + *\li 'type' is not isc_sockettype_fdwatch + * + * Ensures: + * + * '*socketp' is attached to the newly created socket + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_NORESOURCES + *\li #ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_dup(isc_socket_t *sock0, isc_socket_t **socketp); +/*%< + * Duplicate an existing socket, reusing its file descriptor. + */ + +void +isc_socket_cancel(isc_socket_t *sock, isc_task_t *task, + unsigned int how); +/*%< + * Cancel pending I/O of the type specified by "how". + * + * Note: if "task" is NULL, then the cancel applies to all tasks using the + * socket. + * + * Requires: + * + * \li "socket" is a valid socket + * + * \li "task" is NULL or a valid task + * + * "how" is a bitmask describing the type of cancelation to perform. + * The type ISC_SOCKCANCEL_ALL will cancel all pending I/O on this + * socket. + * + * \li ISC_SOCKCANCEL_RECV: + * Cancel pending isc_socket_recv() calls. + * + * \li ISC_SOCKCANCEL_SEND: + * Cancel pending isc_socket_send() and isc_socket_sendto() calls. + * + * \li ISC_SOCKCANCEL_ACCEPT: + * Cancel pending isc_socket_accept() calls. + * + * \li ISC_SOCKCANCEL_CONNECT: + * Cancel pending isc_socket_connect() call. + */ + +void +isc_socket_shutdown(isc_socket_t *sock, unsigned int how); +/*%< + * Shutdown 'socket' according to 'how'. + * + * Requires: + * + * \li 'socket' is a valid socket. + * + * \li 'task' is NULL or is a valid task. + * + * \li If 'how' is 'ISC_SOCKSHUT_RECV' or 'ISC_SOCKSHUT_ALL' then + * + * The read queue must be empty. + * + * No further read requests may be made. + * + * \li If 'how' is 'ISC_SOCKSHUT_SEND' or 'ISC_SOCKSHUT_ALL' then + * + * The write queue must be empty. + * + * No further write requests may be made. + */ + +void +isc_socket_attach(isc_socket_t *sock, isc_socket_t **socketp); +/*%< + * Attach *socketp to socket. + * + * Requires: + * + * \li 'socket' is a valid socket. + * + * \li 'socketp' points to a NULL socket. + * + * Ensures: + * + * \li *socketp is attached to socket. + */ + +void +isc_socket_detach(isc_socket_t **socketp); +/*%< + * Detach *socketp from its socket. + * + * Requires: + * + * \li 'socketp' points to a valid socket. + * + * \li If '*socketp' is the last reference to the socket, + * then: + * + * There must be no pending I/O requests. + * + * Ensures: + * + * \li *socketp is NULL. + * + * \li If '*socketp' is the last reference to the socket, + * then: + * + * The socket will be shutdown (both reading and writing) + * for all tasks. + * + * All resources used by the socket have been freed + */ + +isc_result_t +isc_socket_open(isc_socket_t *sock); +/*%< + * Open a new socket file descriptor of the given socket structure. It simply + * opens a new descriptor; all of the other parameters including the socket + * type are inherited from the existing socket. This function is provided to + * avoid overhead of destroying and creating sockets when many short-lived + * sockets are frequently opened and closed. When the efficiency is not an + * issue, it should be safer to detach the unused socket and re-create a new + * one. This optimization may not be available for some systems, in which + * case this function will return ISC_R_NOTIMPLEMENTED and must not be used. + * + * isc_socket_open() should not be called on sockets created by + * isc_socket_fdwatchcreate(). + * + * Requires: + * + * \li there must be no other reference to this socket. + * + * \li 'socket' is a valid and previously closed by isc_socket_close() + * + * \li 'sock->type' is not isc_sockettype_fdwatch + * + * Returns: + * Same as isc_socket_create(). + * \li ISC_R_NOTIMPLEMENTED + */ + +isc_result_t +isc_socket_close(isc_socket_t *sock); +/*%< + * Close a socket file descriptor of the given socket structure. This function + * is provided as an alternative to destroying an unused socket when overhead + * destroying/re-creating sockets can be significant, and is expected to be + * used with isc_socket_open(). This optimization may not be available for some + * systems, in which case this function will return ISC_R_NOTIMPLEMENTED and + * must not be used. + * + * isc_socket_close() should not be called on sockets created by + * isc_socket_fdwatchcreate(). + * + * Requires: + * + * \li The socket must have a valid descriptor. + * + * \li There must be no other reference to this socket. + * + * \li There must be no pending I/O requests. + * + * \li 'sock->type' is not isc_sockettype_fdwatch + * + * Returns: + * \li #ISC_R_NOTIMPLEMENTED + */ + +isc_result_t +isc_socket_bind(isc_socket_t *sock, isc_sockaddr_t *addressp, + unsigned int options); +/*%< + * Bind 'socket' to '*addressp'. + * + * Requires: + * + * \li 'socket' is a valid socket + * + * \li 'addressp' points to a valid isc_sockaddr. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_NOPERM + * \li ISC_R_ADDRNOTAVAIL + * \li ISC_R_ADDRINUSE + * \li ISC_R_BOUND + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_filter(isc_socket_t *sock, const char *filter); +/*%< + * Inform the kernel that it should perform accept filtering. + * If filter is NULL the current filter will be removed.:w + */ + +isc_result_t +isc_socket_listen(isc_socket_t *sock, unsigned int backlog); +/*%< + * Set listen mode on the socket. After this call, the only function that + * can be used (other than attach and detach) is isc_socket_accept(). + * + * Notes: + * + * \li 'backlog' is as in the UNIX system call listen() and may be + * ignored by non-UNIX implementations. + * + * \li If 'backlog' is zero, a reasonable system default is used, usually + * SOMAXCONN. + * + * Requires: + * + * \li 'socket' is a valid, bound TCP socket or a valid, bound UNIX socket. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_accept(isc_socket_t *sock, + isc_task_t *task, isc_taskaction_t action, const void *arg); +/*%< + * Queue accept event. When a new connection is received, the task will + * get an ISC_SOCKEVENT_NEWCONN event with the sender set to the listen + * socket. The new socket structure is sent inside the isc_socket_newconnev_t + * event type, and is attached to the task 'task'. + * + * REQUIRES: + * \li 'socket' is a valid TCP socket that isc_socket_listen() was called + * on. + * + * \li 'task' is a valid task + * + * \li 'action' is a valid action + * + * RETURNS: + * \li ISC_R_SUCCESS + * \li ISC_R_NOMEMORY + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_connect(isc_socket_t *sock, isc_sockaddr_t *addressp, + isc_task_t *task, isc_taskaction_t action, + const void *arg); +/*%< + * Connect 'socket' to peer with address *saddr. When the connection + * succeeds, or when an error occurs, a CONNECT event with action 'action' + * and arg 'arg' will be posted to the event queue for 'task'. + * + * Requires: + * + * \li 'socket' is a valid TCP socket + * + * \li 'addressp' points to a valid isc_sockaddr + * + * \li 'task' is a valid task + * + * \li 'action' is a valid action + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_NOMEMORY + * \li ISC_R_UNEXPECTED + * + * Posted event's result code: + * + * \li ISC_R_SUCCESS + * \li ISC_R_TIMEDOUT + * \li ISC_R_CONNREFUSED + * \li ISC_R_NETUNREACH + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_getpeername(isc_socket_t *sock, isc_sockaddr_t *addressp); +/*%< + * Get the name of the peer connected to 'socket'. + * + * Requires: + * + * \li 'socket' is a valid TCP socket. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_TOOSMALL + * \li ISC_R_UNEXPECTED + */ + +isc_result_t +isc_socket_getsockname(isc_socket_t *sock, isc_sockaddr_t *addressp); +/*%< + * Get the name of 'socket'. + * + * Requires: + * + * \li 'socket' is a valid socket. + * + * Returns: + * + * \li ISC_R_SUCCESS + * \li ISC_R_TOOSMALL + * \li ISC_R_UNEXPECTED + */ + +/*@{*/ +isc_result_t +isc_socket_recv(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, + isc_task_t *task, isc_taskaction_t action, const void *arg); +isc_result_t +isc_socket_recvv(isc_socket_t *sock, isc_bufferlist_t *buflist, + unsigned int minimum, + isc_task_t *task, isc_taskaction_t action, const void *arg); + +isc_result_t +isc_socket_recv2(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_socketevent_t *event, unsigned int flags); + +/*! + * Receive from 'socket', storing the results in region. + * + * Notes: + * + *\li Let 'length' refer to the length of 'region' or to the sum of all + * available regions in the list of buffers '*buflist'. + * + *\li If 'minimum' is non-zero and at least that many bytes are read, + * the completion event will be posted to the task 'task.' If minimum + * is zero, the exact number of bytes requested in the region must + * be read for an event to be posted. This only makes sense for TCP + * connections, and is always set to 1 byte for UDP. + * + *\li The read will complete when the desired number of bytes have been + * read, if end-of-input occurs, or if an error occurs. A read done + * event with the given 'action' and 'arg' will be posted to the + * event queue of 'task'. + * + *\li The caller may not modify 'region', the buffers which are passed + * into this function, or any data they refer to until the completion + * event is received. + * + *\li For isc_socket_recvv(): + * On successful completion, '*buflist' will be empty, and the list of + * all buffers will be returned in the done event's 'bufferlist' + * member. On error return, '*buflist' will be unchanged. + * + *\li For isc_socket_recv2(): + * 'event' is not NULL, and the non-socket specific fields are + * expected to be initialized. + * + *\li For isc_socket_recv2(): + * The only defined value for 'flags' is ISC_SOCKFLAG_IMMEDIATE. If + * set and the operation completes, the return value will be + * ISC_R_SUCCESS and the event will be filled in and not sent. If the + * operation does not complete, the return value will be + * ISC_R_INPROGRESS and the event will be sent when the operation + * completes. + * + * Requires: + * + *\li 'socket' is a valid, bound socket. + * + *\li For isc_socket_recv(): + * 'region' is a valid region + * + *\li For isc_socket_recvv(): + * 'buflist' is non-NULL, and '*buflist' contain at least one buffer. + * + *\li 'task' is a valid task + * + *\li For isc_socket_recv() and isc_socket_recvv(): + * action != NULL and is a valid action + * + *\li For isc_socket_recv2(): + * event != NULL + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_INPROGRESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + * + * Event results: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_UNEXPECTED + *\li XXX needs other net-type errors + */ +/*@}*/ + +/*@{*/ +isc_result_t +isc_socket_send(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg); +isc_result_t +isc_socket_sendto(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo); +isc_result_t +isc_socket_sendv(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg); +isc_result_t +isc_socket_sendtov(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo); +isc_result_t +isc_socket_sendto2(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + isc_socketevent_t *event, unsigned int flags); + +/*! + * Send the contents of 'region' to the socket's peer. + * + * Notes: + * + *\li Shutting down the requestor's task *may* result in any + * still pending writes being dropped or completed, depending on the + * underlying OS implementation. + * + *\li If 'action' is NULL, then no completion event will be posted. + * + *\li The caller may not modify 'region', the buffers which are passed + * into this function, or any data they refer to until the completion + * event is received. + * + *\li For isc_socket_sendv() and isc_socket_sendtov(): + * On successful completion, '*buflist' will be empty, and the list of + * all buffers will be returned in the done event's 'bufferlist' + * member. On error return, '*buflist' will be unchanged. + * + *\li For isc_socket_sendto2(): + * 'event' is not NULL, and the non-socket specific fields are + * expected to be initialized. + * + *\li For isc_socket_sendto2(): + * The only defined values for 'flags' are ISC_SOCKFLAG_IMMEDIATE + * and ISC_SOCKFLAG_NORETRY. + * + *\li If ISC_SOCKFLAG_IMMEDIATE is set and the operation completes, the + * return value will be ISC_R_SUCCESS and the event will be filled + * in and not sent. If the operation does not complete, the return + * value will be ISC_R_INPROGRESS and the event will be sent when + * the operation completes. + * + *\li ISC_SOCKFLAG_NORETRY can only be set for UDP sockets. If set + * and the send operation fails due to a transient error, the send + * will not be retried and the error will be indicated in the event. + * Using this option along with ISC_SOCKFLAG_IMMEDIATE allows the caller + * to specify a region that is allocated on the stack. + * + * Requires: + * + *\li 'socket' is a valid, bound socket. + * + *\li For isc_socket_send(): + * 'region' is a valid region + * + *\li For isc_socket_sendv() and isc_socket_sendtov(): + * 'buflist' is non-NULL, and '*buflist' contain at least one buffer. + * + *\li 'task' is a valid task + * + *\li For isc_socket_sendv(), isc_socket_sendtov(), isc_socket_send(), and + * isc_socket_sendto(): + * action == NULL or is a valid action + * + *\li For isc_socket_sendto2(): + * event != NULL + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_INPROGRESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + * + * Event results: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_UNEXPECTED + *\li XXX needs other net-type errors + */ +/*@}*/ + +isc_result_t +isc_socketmgr_createinctx(isc_mem_t *mctx, isc_appctx_t *actx, + isc_socketmgr_t **managerp); + +isc_result_t +isc_socketmgr_create(isc_mem_t *mctx, isc_socketmgr_t **managerp); + +isc_result_t +isc_socketmgr_create2(isc_mem_t *mctx, isc_socketmgr_t **managerp, + unsigned int maxsocks); +/*%< + * Create a socket manager. If "maxsocks" is non-zero, it specifies the + * maximum number of sockets that the created manager should handle. + * isc_socketmgr_create() is equivalent of isc_socketmgr_create2() with + * "maxsocks" being zero. + * isc_socketmgr_createinctx() also associates the new manager with the + * specified application context. + * + * Notes: + * + *\li All memory will be allocated in memory context 'mctx'. + * + * Requires: + * + *\li 'mctx' is a valid memory context. + * + *\li 'managerp' points to a NULL isc_socketmgr_t. + * + *\li 'actx' is a valid application context (for createinctx()). + * + * Ensures: + * + *\li '*managerp' is a valid isc_socketmgr_t. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + *\li #ISC_R_NOTIMPLEMENTED + */ + +isc_result_t +isc_socketmgr_getmaxsockets(isc_socketmgr_t *manager, unsigned int *nsockp); +/*%< + * Returns in "*nsockp" the maximum number of sockets this manager may open. + * + * Requires: + * + *\li '*manager' is a valid isc_socketmgr_t. + *\li 'nsockp' is not NULL. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOTIMPLEMENTED + */ + +void +isc_socketmgr_setstats(isc_socketmgr_t *manager, isc_stats_t *stats); +/*%< + * Set a general socket statistics counter set 'stats' for 'manager'. + * + * Requires: + * \li 'manager' is valid, hasn't opened any socket, and doesn't have + * stats already set. + * + *\li stats is a valid statistics supporting socket statistics counters + * (see above). + */ + +void +isc_socketmgr_destroy(isc_socketmgr_t **managerp); +/*%< + * Destroy a socket manager. + * + * Notes: + * + *\li This routine blocks until there are no sockets left in the manager, + * so if the caller holds any socket references using the manager, it + * must detach them before calling isc_socketmgr_destroy() or it will + * block forever. + * + * Requires: + * + *\li '*managerp' is a valid isc_socketmgr_t. + * + *\li All sockets managed by this manager are fully detached. + * + * Ensures: + * + *\li *managerp == NULL + * + *\li All resources used by the manager have been freed. + */ + +isc_sockettype_t +isc_socket_gettype(isc_socket_t *sock); +/*%< + * Returns the socket type for "sock." + * + * Requires: + * + *\li "sock" is a valid socket. + */ + +/*@{*/ +isc_boolean_t +isc_socket_isbound(isc_socket_t *sock); + +void +isc_socket_ipv6only(isc_socket_t *sock, isc_boolean_t yes); +/*%< + * If the socket is an IPv6 socket set/clear the IPV6_IPV6ONLY socket + * option if the host OS supports this option. + * + * Requires: + *\li 'sock' is a valid socket. + */ +/*@}*/ + +void +isc_socket_cleanunix(isc_sockaddr_t *addr, isc_boolean_t active); + +/*%< + * Cleanup UNIX domain sockets in the file-system. If 'active' is true + * then just unlink the socket. If 'active' is false try to determine + * if there is a listener of the socket or not. If no listener is found + * then unlink socket. + * + * Prior to unlinking the path is tested to see if it a socket. + * + * Note: there are a number of race conditions which cannot be avoided + * both in the filesystem and any application using UNIX domain + * sockets (e.g. socket is tested between bind() and listen(), + * the socket is deleted and replaced in the file-system between + * stat() and unlink()). + */ + +isc_result_t +isc_socket_permunix(isc_sockaddr_t *sockaddr, isc_uint32_t perm, + isc_uint32_t owner, isc_uint32_t group); +/*%< + * Set ownership and file permissions on the UNIX domain socket. + * + * Note: On Solaris and SunOS this secures the directory containing + * the socket as Solaris and SunOS do not honour the filesystem + * permissions on the socket. + * + * Requires: + * \li 'sockaddr' to be a valid UNIX domain sockaddr. + * + * Returns: + * \li #ISC_R_SUCCESS + * \li #ISC_R_FAILURE + */ + +void isc_socket_setname(isc_socket_t *sock, const char *name, void *tag); +/*%< + * Set the name and optional tag for a socket. This allows tracking of the + * owner or purpose for this socket, and is useful for tracing and statistics + * reporting. + */ + +const char *isc_socket_getname(isc_socket_t *sock); +/*%< + * Get the name associated with a socket, if any. + */ + +void *isc_socket_gettag(isc_socket_t *sock); +/*%< + * Get the tag associated with a socket, if any. + */ + +int isc_socket_getfd(isc_socket_t *sock); +/*%< + * Get the file descriptor associated with a socket + */ + +void +isc__socketmgr_setreserved(isc_socketmgr_t *mgr, isc_uint32_t); +/*%< + * Temporary. For use by named only. + */ + +void +isc__socketmgr_maxudp(isc_socketmgr_t *mgr, int maxudp); +/*%< + * Test interface. Drop UDP packet > 'maxudp'. + */ + +#ifdef HAVE_LIBXML2 + +void +isc_socketmgr_renderxml(isc_socketmgr_t *mgr, xmlTextWriterPtr writer); +/*%< + * Render internal statistics and other state into the XML document. + */ + +#endif /* HAVE_LIBXML2 */ + +#ifdef USE_SOCKETIMPREGISTER +/*%< + * See isc_socketmgr_create() above. + */ +typedef isc_result_t +(*isc_socketmgrcreatefunc_t)(isc_mem_t *mctx, isc_socketmgr_t **managerp); + +isc_result_t +isc_socket_register(isc_socketmgrcreatefunc_t createfunc); +/*%< + * Register a new socket I/O implementation and add it to the list of + * supported implementations. This function must be called when a different + * event library is used than the one contained in the ISC library. + */ + +isc_result_t +isc__socket_register(void); +/*%< + * A short cut function that specifies the socket I/O module in the ISC + * library for isc_socket_register(). An application that uses the ISC library + * usually do not have to care about this function: it would call + * isc_lib_register(), which internally calls this function. + */ +#endif /* USE_SOCKETIMPREGISTER */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SOCKET_H */ diff --git a/contrib/ntp/lib/isc/include/isc/stats.h b/contrib/ntp/lib/isc/include/isc/stats.h new file mode 100644 index 000000000..682eefded --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/stats.h @@ -0,0 +1,121 @@ +/* + * Copyright (C) 2009, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_STATS_H +#define ISC_STATS_H 1 + +/*! \file isc/stats.h */ + +#include + +ISC_LANG_BEGINDECLS + +/*%< + * Flag(s) for isc_stats_dump(). + */ +#define ISC_STATSDUMP_VERBOSE 0x00000001 /*%< dump 0-value counters */ + +/*%< + * Dump callback type. + */ +typedef void (*isc_stats_dumper_t)(isc_statscounter_t, isc_uint64_t, void *); + +isc_result_t +isc_stats_create(isc_mem_t *mctx, isc_stats_t **statsp, int ncounters); +/*%< + * Create a statistics counter structure of general type. It counts a general + * set of counters indexed by an ID between 0 and ncounters -1. + * + * Requires: + *\li 'mctx' must be a valid memory context. + * + *\li 'statsp' != NULL && '*statsp' == NULL. + * + * Returns: + *\li ISC_R_SUCCESS -- all ok + * + *\li anything else -- failure + */ + +void +isc_stats_attach(isc_stats_t *stats, isc_stats_t **statsp); +/*%< + * Attach to a statistics set. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + * + *\li 'statsp' != NULL && '*statsp' == NULL + */ + +void +isc_stats_detach(isc_stats_t **statsp); +/*%< + * Detaches from the statistics set. + * + * Requires: + *\li 'statsp' != NULL and '*statsp' is a valid isc_stats_t. + */ + +int +isc_stats_ncounters(isc_stats_t *stats); +/*%< + * Returns the number of counters contained in stats. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + * + */ + +void +isc_stats_increment(isc_stats_t *stats, isc_statscounter_t counter); +/*%< + * Increment the counter-th counter of stats. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + * + *\li counter is less than the maximum available ID for the stats specified + * on creation. + */ + +void +isc_stats_decrement(isc_stats_t *stats, isc_statscounter_t counter); +/*%< + * Decrement the counter-th counter of stats. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + */ + +void +isc_stats_dump(isc_stats_t *stats, isc_stats_dumper_t dump_fn, void *arg, + unsigned int options); +/*%< + * Dump the current statistics counters in a specified way. For each counter + * in stats, dump_fn is called with its current value and the given argument + * arg. By default counters that have a value of 0 is skipped; if options has + * the ISC_STATSDUMP_VERBOSE flag, even such counters are dumped. + * + * Requires: + *\li 'stats' is a valid isc_stats_t. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_STATS_H */ diff --git a/contrib/ntp/lib/isc/include/isc/stdio.h b/contrib/ntp/lib/isc/include/isc/stdio.h new file mode 100644 index 000000000..1a7ae642d --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/stdio.h @@ -0,0 +1,77 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdio.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_STDIO_H +#define ISC_STDIO_H 1 + +/*! \file isc/stdio.h */ + +/*% + * These functions are wrappers around the corresponding stdio functions. + * + * They return a detailed error code in the form of an an isc_result_t. ANSI C + * does not guarantee that stdio functions set errno, hence these functions + * must use platform dependent methods (e.g., the POSIX errno) to construct the + * error code. + */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +/*% Open */ +isc_result_t +isc_stdio_open(const char *filename, const char *mode, FILE **fp); + +/*% Close */ +isc_result_t +isc_stdio_close(FILE *f); + +/*% Seek */ +isc_result_t +isc_stdio_seek(FILE *f, long offset, int whence); + +/*% Read */ +isc_result_t +isc_stdio_read(void *ptr, size_t size, size_t nmemb, FILE *f, + size_t *nret); + +/*% Write */ +isc_result_t +isc_stdio_write(const void *ptr, size_t size, size_t nmemb, FILE *f, + size_t *nret); + +/*% Flush */ +isc_result_t +isc_stdio_flush(FILE *f); + +isc_result_t +isc_stdio_sync(FILE *f); +/*%< + * Invoke fsync() on the file descriptor underlying an stdio stream, or an + * equivalent system-dependent operation. Note that this function has no + * direct counterpart in the stdio library. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_STDIO_H */ diff --git a/contrib/ntp/lib/isc/include/isc/stdlib.h b/contrib/ntp/lib/isc/include/isc/stdlib.h new file mode 100644 index 000000000..02243f086 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/stdlib.h @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdlib.h,v 1.8 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_STDLIB_H +#define ISC_STDLIB_H 1 + +/*! \file isc/stdlib.h */ + +#include + +#include +#include + +#ifdef ISC_PLATFORM_NEEDSTRTOUL +#define strtoul isc_strtoul +#endif + +ISC_LANG_BEGINDECLS + +unsigned long isc_strtoul(const char *, char **, int); + +ISC_LANG_ENDDECLS + +#endif diff --git a/contrib/ntp/lib/isc/include/isc/string.h b/contrib/ntp/lib/isc/include/isc/string.h new file mode 100644 index 000000000..b49fdbc32 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/string.h @@ -0,0 +1,231 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: string.h,v 1.23 2007/09/13 04:48:16 each Exp $ */ + +#ifndef ISC_STRING_H +#define ISC_STRING_H 1 + +/*! \file isc/string.h */ + +#include +#include +#include +#include +#include + +#include + +#ifdef ISC_PLATFORM_HAVESTRINGSH +#include +#endif + +#define ISC_STRING_MAGIC 0x5e + +ISC_LANG_BEGINDECLS + +isc_uint64_t +isc_string_touint64(char *source, char **endp, int base); +/*%< + * Convert the string pointed to by 'source' to isc_uint64_t. + * + * On successful conversion 'endp' points to the first character + * after conversion is complete. + * + * 'base': 0 or 2..36 + * + * If base is 0 the base is computed from the string type. + * + * On error 'endp' points to 'source'. + */ + +isc_result_t +isc_string_copy(char *target, size_t size, const char *source); +/* + * Copy the string pointed to by 'source' to 'target' which is a + * pointer to a string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * If result == ISC_R_SUCCESS + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + * + * If result == ISC_R_NOSPACE + * 'target' is undefined. + * + * Returns: + * ISC_R_SUCCESS -- 'source' was successfully copied to 'target'. + * ISC_R_NOSPACE -- 'source' could not be copied since 'target' + * is too small. + */ + +void +isc_string_copy_truncate(char *target, size_t size, const char *source); +/* + * Copy the string pointed to by 'source' to 'target' which is a + * pointer to a string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + */ + +isc_result_t +isc_string_append(char *target, size_t size, const char *source); +/* + * Append the string pointed to by 'source' to 'target' which is a + * pointer to a NUL terminated string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a NUL terminated char[] of at + * least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * If result == ISC_R_SUCCESS + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + * + * If result == ISC_R_NOSPACE + * 'target' is undefined. + * + * Returns: + * ISC_R_SUCCESS -- 'source' was successfully appended to 'target'. + * ISC_R_NOSPACE -- 'source' could not be appended since 'target' + * is too small. + */ + +void +isc_string_append_truncate(char *target, size_t size, const char *source); +/* + * Append the string pointed to by 'source' to 'target' which is a + * pointer to a NUL terminated string of at least 'size' bytes. + * + * Requires: + * 'target' is a pointer to a NUL terminated char[] of at + * least 'size' bytes. + * 'size' an integer > 0. + * 'source' == NULL or points to a NUL terminated string. + * + * Ensures: + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + */ + +isc_result_t +isc_string_printf(char *target, size_t size, const char *format, ...) + ISC_FORMAT_PRINTF(3, 4); +/* + * Print 'format' to 'target' which is a pointer to a string of at least + * 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'format' == NULL or points to a NUL terminated string. + * + * Ensures: + * If result == ISC_R_SUCCESS + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + * + * If result == ISC_R_NOSPACE + * 'target' is undefined. + * + * Returns: + * ISC_R_SUCCESS -- 'format' was successfully printed to 'target'. + * ISC_R_NOSPACE -- 'format' could not be printed to 'target' since it + * is too small. + */ + +void +isc_string_printf_truncate(char *target, size_t size, const char *format, ...) + ISC_FORMAT_PRINTF(3, 4); +/* + * Print 'format' to 'target' which is a pointer to a string of at least + * 'size' bytes. + * + * Requires: + * 'target' is a pointer to a char[] of at least 'size' bytes. + * 'size' an integer > 0. + * 'format' == NULL or points to a NUL terminated string. + * + * Ensures: + * 'target' will be a NUL terminated string of no more + * than 'size' bytes (including NUL). + */ + + +char * +isc_string_regiondup(isc_mem_t *mctx, const isc_region_t *source); +/* + * Copy the region pointed to by r to a NUL terminated string + * allocated from the memory context pointed to by mctx. + * + * The result should be deallocated using isc_mem_free() + * + * Requires: + * 'mctx' is a point to a valid memory context. + * 'source' is a pointer to a valid region. + * + * Returns: + * a pointer to a NUL terminated string or + * NULL if memory for the copy could not be allocated + * + */ + +char * +isc_string_separate(char **stringp, const char *delim); + +#ifdef ISC_PLATFORM_NEEDSTRSEP +#define strsep isc_string_separate +#endif + +#ifdef ISC_PLATFORM_NEEDMEMMOVE +#define memmove(a,b,c) bcopy(b,a,c) +#endif + +size_t +isc_string_strlcpy(char *dst, const char *src, size_t size); + + +#ifdef ISC_PLATFORM_NEEDSTRLCPY +#define strlcpy isc_string_strlcpy +#endif + + +size_t +isc_string_strlcat(char *dst, const char *src, size_t size); + +#ifdef ISC_PLATFORM_NEEDSTRLCAT +#define strlcat isc_string_strlcat +#endif + +ISC_LANG_ENDDECLS + +#endif /* ISC_STRING_H */ diff --git a/contrib/ntp/lib/isc/include/isc/symtab.h b/contrib/ntp/lib/isc/include/isc/symtab.h new file mode 100644 index 000000000..9d0e5e2f2 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/symtab.h @@ -0,0 +1,139 @@ +/* + * Copyright (C) 2004-2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1996-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_SYMTAB_H +#define ISC_SYMTAB_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/symtab.h + * \brief Provides a simple memory-based symbol table. + * + * Keys are C strings, and key comparisons are case-insensitive. A type may + * be specified when looking up, defining, or undefining. A type value of + * 0 means "match any type"; any other value will only match the given + * type. + * + * It's possible that a client will attempt to define a + * tuple when a tuple with the given key and type already exists in the table. + * What to do in this case is specified by the client. Possible policies are: + * + *\li #isc_symexists_reject Disallow the define, returning #ISC_R_EXISTS + *\li #isc_symexists_replace Replace the old value with the new. The + * undefine action (if provided) will be called + * with the old tuple. + *\li #isc_symexists_add Add the new tuple, leaving the old tuple in + * the table. Subsequent lookups will retrieve + * the most-recently-defined tuple. + * + * A lookup of a key using type 0 will return the most-recently defined + * symbol with that key. An undefine of a key using type 0 will undefine the + * most-recently defined symbol with that key. Trying to define a key with + * type 0 is illegal. + * + * The symbol table library does not make a copy the key field, so the + * caller must ensure that any key it passes to isc_symtab_define() will not + * change until it calls isc_symtab_undefine() or isc_symtab_destroy(). + * + * A user-specified action will be called (if provided) when a symbol is + * undefined. It can be used to free memory associated with keys and/or + * values. + * + * A symbol table is implemented as a hash table of lists; the size of the + * hash table is set by the 'size' parameter to isc_symtbl_create(). When + * the number of entries in the symbol table reaches three quarters of this + * value, the hash table is reallocated with size doubled, in order to + * optimize lookup performance. This has a negative effect on insertion + * performance, which can be mitigated by sizing the table appropriately + * when creating it. + * + * \li MP: + * The callers of this module must ensure any required synchronization. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + +/*** + *** Imports. + ***/ + +#include +#include + +/* + *** Symbol Tables. + ***/ +/*% Symbol table value. */ +typedef union isc_symvalue { + void * as_pointer; + const void * as_cpointer; + int as_integer; + unsigned int as_uinteger; +} isc_symvalue_t; + +typedef void (*isc_symtabaction_t)(char *key, unsigned int type, + isc_symvalue_t value, void *userarg); +/*% Symbol table exists. */ +typedef enum { + isc_symexists_reject = 0, /*%< Disallow the define */ + isc_symexists_replace = 1, /*%< Replace the old value with the new */ + isc_symexists_add = 2 /*%< Add the new tuple */ +} isc_symexists_t; + +ISC_LANG_BEGINDECLS + +/*% Create a symbol table. */ +isc_result_t +isc_symtab_create(isc_mem_t *mctx, unsigned int size, + isc_symtabaction_t undefine_action, void *undefine_arg, + isc_boolean_t case_sensitive, isc_symtab_t **symtabp); + +/*% Destroy a symbol table. */ +void +isc_symtab_destroy(isc_symtab_t **symtabp); + +/*% Lookup a symbol table. */ +isc_result_t +isc_symtab_lookup(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t *value); + +/*% Define a symbol table. */ +isc_result_t +isc_symtab_define(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t value, isc_symexists_t exists_policy); + +/*% Undefine a symbol table. */ +isc_result_t +isc_symtab_undefine(isc_symtab_t *symtab, const char *key, unsigned int type); + +ISC_LANG_ENDDECLS + +#endif /* ISC_SYMTAB_H */ diff --git a/contrib/ntp/lib/isc/include/isc/task.h b/contrib/ntp/lib/isc/include/isc/task.h new file mode 100644 index 000000000..594d80f34 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/task.h @@ -0,0 +1,796 @@ +/* + * Copyright (C) 2004-2007, 2009-2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_TASK_H +#define ISC_TASK_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/task.h + * \brief The task system provides a lightweight execution context, which is + * basically an event queue. + + * When a task's event queue is non-empty, the + * task is runnable. A small work crew of threads, typically one per CPU, + * execute runnable tasks by dispatching the events on the tasks' event + * queues. Context switching between tasks is fast. + * + * \li MP: + * The module ensures appropriate synchronization of data structures it + * creates and manipulates. + * The caller must ensure that isc_taskmgr_destroy() is called only + * once for a given manager. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + * + * \section purge Purging and Unsending + * + * Events which have been queued for a task but not delivered may be removed + * from the task's event queue by purging or unsending. + * + * With both types, the caller specifies a matching pattern that selects + * events based upon their sender, type, and tag. + * + * Purging calls isc_event_free() on the matching events. + * + * Unsending returns a list of events that matched the pattern. + * The caller is then responsible for them. + * + * Consumers of events should purge, not unsend. + * + * Producers of events often want to remove events when the caller indicates + * it is no longer interested in the object, e.g. by canceling a timer. + * Sometimes this can be done by purging, but for some event types, the + * calls to isc_event_free() cause deadlock because the event free routine + * wants to acquire a lock the caller is already holding. Unsending instead + * of purging solves this problem. As a general rule, producers should only + * unsend events which they have sent. + */ + + +/*** + *** Imports. + ***/ + +#include +#include +#include +#include +#include + +#define ISC_TASKEVENT_FIRSTEVENT (ISC_EVENTCLASS_TASK + 0) +#define ISC_TASKEVENT_SHUTDOWN (ISC_EVENTCLASS_TASK + 1) +#define ISC_TASKEVENT_TEST (ISC_EVENTCLASS_TASK + 1) +#define ISC_TASKEVENT_LASTEVENT (ISC_EVENTCLASS_TASK + 65535) + +/***** + ***** Tasks. + *****/ + +ISC_LANG_BEGINDECLS + +/*** + *** Types + ***/ + +typedef enum { + isc_taskmgrmode_normal = 0, + isc_taskmgrmode_privileged +} isc_taskmgrmode_t; + +/*% Task and task manager methods */ +typedef struct isc_taskmgrmethods { + void (*destroy)(isc_taskmgr_t **managerp); + void (*setmode)(isc_taskmgr_t *manager, + isc_taskmgrmode_t mode); + isc_taskmgrmode_t (*mode)(isc_taskmgr_t *manager); + isc_result_t (*taskcreate)(isc_taskmgr_t *manager, + unsigned int quantum, + isc_task_t **taskp); +} isc_taskmgrmethods_t; + +typedef struct isc_taskmethods { + void (*attach)(isc_task_t *source, isc_task_t **targetp); + void (*detach)(isc_task_t **taskp); + void (*destroy)(isc_task_t **taskp); + void (*send)(isc_task_t *task, isc_event_t **eventp); + void (*sendanddetach)(isc_task_t **taskp, isc_event_t **eventp); + unsigned int (*unsend)(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag, isc_eventlist_t *events); + isc_result_t (*onshutdown)(isc_task_t *task, isc_taskaction_t action, + const void *arg); + void (*shutdown)(isc_task_t *task); + void (*setname)(isc_task_t *task, const char *name, void *tag); + unsigned int (*purgeevents)(isc_task_t *task, void *sender, + isc_eventtype_t type, void *tag); + unsigned int (*purgerange)(isc_task_t *task, void *sender, + isc_eventtype_t first, isc_eventtype_t last, + void *tag); + isc_result_t (*beginexclusive)(isc_task_t *task); + void (*endexclusive)(isc_task_t *task); + void (*setprivilege)(isc_task_t *task, isc_boolean_t priv); + isc_boolean_t (*privilege)(isc_task_t *task); +} isc_taskmethods_t; + +/*% + * This structure is actually just the common prefix of a task manager + * object implementation's version of an isc_taskmgr_t. + * \brief + * Direct use of this structure by clients is forbidden. task implementations + * may change the structure. 'magic' must be ISCAPI_TASKMGR_MAGIC for any + * of the isc_task_ routines to work. task implementations must maintain + * all task invariants. + */ +struct isc_taskmgr { + unsigned int impmagic; + unsigned int magic; + isc_taskmgrmethods_t *methods; +}; + +#define ISCAPI_TASKMGR_MAGIC ISC_MAGIC('A','t','m','g') +#define ISCAPI_TASKMGR_VALID(m) ((m) != NULL && \ + (m)->magic == ISCAPI_TASKMGR_MAGIC) + +/*% + * This is the common prefix of a task object. The same note as + * that for the taskmgr structure applies. + */ +struct isc_task { + unsigned int impmagic; + unsigned int magic; + isc_taskmethods_t *methods; +}; + +#define ISCAPI_TASK_MAGIC ISC_MAGIC('A','t','s','t') +#define ISCAPI_TASK_VALID(s) ((s) != NULL && \ + (s)->magic == ISCAPI_TASK_MAGIC) + +isc_result_t +isc_task_create(isc_taskmgr_t *manager, unsigned int quantum, + isc_task_t **taskp); +/*%< + * Create a task. + * + * Notes: + * + *\li If 'quantum' is non-zero, then only that many events can be dispatched + * before the task must yield to other tasks waiting to execute. If + * quantum is zero, then the default quantum of the task manager will + * be used. + * + *\li The 'quantum' option may be removed from isc_task_create() in the + * future. If this happens, isc_task_getquantum() and + * isc_task_setquantum() will be provided. + * + * Requires: + * + *\li 'manager' is a valid task manager. + * + *\li taskp != NULL && *taskp == NULL + * + * Ensures: + * + *\li On success, '*taskp' is bound to the new task. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + *\li #ISC_R_SHUTTINGDOWN + */ + +void +isc_task_attach(isc_task_t *source, isc_task_t **targetp); +/*%< + * Attach *targetp to source. + * + * Requires: + * + *\li 'source' is a valid task. + * + *\li 'targetp' points to a NULL isc_task_t *. + * + * Ensures: + * + *\li *targetp is attached to source. + */ + +void +isc_task_detach(isc_task_t **taskp); +/*%< + * Detach *taskp from its task. + * + * Requires: + * + *\li '*taskp' is a valid task. + * + * Ensures: + * + *\li *taskp is NULL. + * + *\li If '*taskp' is the last reference to the task, the task is idle (has + * an empty event queue), and has not been shutdown, the task will be + * shutdown. + * + *\li If '*taskp' is the last reference to the task and + * the task has been shutdown, + * all resources used by the task will be freed. + */ + +void +isc_task_send(isc_task_t *task, isc_event_t **eventp); +/*%< + * Send '*event' to 'task'. + * + * Requires: + * + *\li 'task' is a valid task. + *\li eventp != NULL && *eventp != NULL. + * + * Ensures: + * + *\li *eventp == NULL. + */ + +void +isc_task_sendanddetach(isc_task_t **taskp, isc_event_t **eventp); +/*%< + * Send '*event' to '*taskp' and then detach '*taskp' from its + * task. + * + * Requires: + * + *\li '*taskp' is a valid task. + *\li eventp != NULL && *eventp != NULL. + * + * Ensures: + * + *\li *eventp == NULL. + * + *\li *taskp == NULL. + * + *\li If '*taskp' is the last reference to the task, the task is + * idle (has an empty event queue), and has not been shutdown, + * the task will be shutdown. + * + *\li If '*taskp' is the last reference to the task and + * the task has been shutdown, + * all resources used by the task will be freed. + */ + + +unsigned int +isc_task_purgerange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag); +/*%< + * Purge events from a task's event queue. + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li last >= first + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is >= first and <= last, and whose tag is 'tag' will be purged, + * unless they are marked as unpurgable. + * + *\li A sender of NULL will match any sender. A NULL tag matches any + * tag. + * + * Returns: + * + *\li The number of events purged. + */ + +unsigned int +isc_task_purge(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag); +/*%< + * Purge events from a task's event queue. + * + * Notes: + * + *\li This function is equivalent to + * + *\code + * isc_task_purgerange(task, sender, type, type, tag); + *\endcode + * + * Requires: + * + *\li 'task' is a valid task. + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is 'type', and whose tag is 'tag' will be purged, unless they + * are marked as unpurgable. + * + *\li A sender of NULL will match any sender. A NULL tag matches any + * tag. + * + * Returns: + * + *\li The number of events purged. + */ + +isc_boolean_t +isc_task_purgeevent(isc_task_t *task, isc_event_t *event); +/*%< + * Purge 'event' from a task's event queue. + * + * XXXRTH: WARNING: This method may be removed before beta. + * + * Notes: + * + *\li If 'event' is on the task's event queue, it will be purged, + * unless it is marked as unpurgeable. 'event' does not have to be + * on the task's event queue; in fact, it can even be an invalid + * pointer. Purging only occurs if the event is actually on the task's + * event queue. + * + * \li Purging never changes the state of the task. + * + * Requires: + * + *\li 'task' is a valid task. + * + * Ensures: + * + *\li 'event' is not in the event queue for 'task'. + * + * Returns: + * + *\li #ISC_TRUE The event was purged. + *\li #ISC_FALSE The event was not in the event queue, + * or was marked unpurgeable. + */ + +unsigned int +isc_task_unsendrange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag, isc_eventlist_t *events); +/*%< + * Remove events from a task's event queue. + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li last >= first. + * + *\li *events is a valid list. + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is >= first and <= last, and whose tag is 'tag' will be dequeued + * and appended to *events. + * + *\li A sender of NULL will match any sender. A NULL tag matches any + * tag. + * + * Returns: + * + *\li The number of events unsent. + */ + +unsigned int +isc_task_unsend(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag, isc_eventlist_t *events); +/*%< + * Remove events from a task's event queue. + * + * Notes: + * + *\li This function is equivalent to + * + *\code + * isc_task_unsendrange(task, sender, type, type, tag, events); + *\endcode + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li *events is a valid list. + * + * Ensures: + * + *\li Events in the event queue of 'task' whose sender is 'sender', whose + * type is 'type', and whose tag is 'tag' will be dequeued and appended + * to *events. + * + * Returns: + * + *\li The number of events unsent. + */ + +isc_result_t +isc_task_onshutdown(isc_task_t *task, isc_taskaction_t action, + const void *arg); +/*%< + * Send a shutdown event with action 'action' and argument 'arg' when + * 'task' is shutdown. + * + * Notes: + * + *\li Shutdown events are posted in LIFO order. + * + * Requires: + * + *\li 'task' is a valid task. + * + *\li 'action' is a valid task action. + * + * Ensures: + * + *\li When the task is shutdown, shutdown events requested with + * isc_task_onshutdown() will be appended to the task's event queue. + * + + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_TASKSHUTTINGDOWN Task is shutting down. + */ + +void +isc_task_shutdown(isc_task_t *task); +/*%< + * Shutdown 'task'. + * + * Notes: + * + *\li Shutting down a task causes any shutdown events requested with + * isc_task_onshutdown() to be posted (in LIFO order). The task + * moves into a "shutting down" mode which prevents further calls + * to isc_task_onshutdown(). + * + *\li Trying to shutdown a task that has already been shutdown has no + * effect. + * + * Requires: + * + *\li 'task' is a valid task. + * + * Ensures: + * + *\li Any shutdown events requested with isc_task_onshutdown() have been + * posted (in LIFO order). + */ + +void +isc_task_destroy(isc_task_t **taskp); +/*%< + * Destroy '*taskp'. + * + * Notes: + * + *\li This call is equivalent to: + * + *\code + * isc_task_shutdown(*taskp); + * isc_task_detach(taskp); + *\endcode + * + * Requires: + * + * '*taskp' is a valid task. + * + * Ensures: + * + *\li Any shutdown events requested with isc_task_onshutdown() have been + * posted (in LIFO order). + * + *\li *taskp == NULL + * + *\li If '*taskp' is the last reference to the task, + * all resources used by the task will be freed. + */ + +void +isc_task_setname(isc_task_t *task, const char *name, void *tag); +/*%< + * Name 'task'. + * + * Notes: + * + *\li Only the first 15 characters of 'name' will be copied. + * + *\li Naming a task is currently only useful for debugging purposes. + * + * Requires: + * + *\li 'task' is a valid task. + */ + +const char * +isc_task_getname(isc_task_t *task); +/*%< + * Get the name of 'task', as previously set using isc_task_setname(). + * + * Notes: + *\li This function is for debugging purposes only. + * + * Requires: + *\li 'task' is a valid task. + * + * Returns: + *\li A non-NULL pointer to a null-terminated string. + * If the task has not been named, the string is + * empty. + * + */ + +void * +isc_task_gettag(isc_task_t *task); +/*%< + * Get the tag value for 'task', as previously set using isc_task_settag(). + * + * Notes: + *\li This function is for debugging purposes only. + * + * Requires: + *\li 'task' is a valid task. + */ + +isc_result_t +isc_task_beginexclusive(isc_task_t *task); +/*%< + * Request exclusive access for 'task', which must be the calling + * task. Waits for any other concurrently executing tasks to finish their + * current event, and prevents any new events from executing in any of the + * tasks sharing a task manager with 'task'. + * + * The exclusive access must be relinquished by calling + * isc_task_endexclusive() before returning from the current event handler. + * + * Requires: + *\li 'task' is the calling task. + * + * Returns: + *\li #ISC_R_SUCCESS The current task now has exclusive access. + *\li #ISC_R_LOCKBUSY Another task has already requested exclusive + * access. + */ + +void +isc_task_endexclusive(isc_task_t *task); +/*%< + * Relinquish the exclusive access obtained by isc_task_beginexclusive(), + * allowing other tasks to execute. + * + * Requires: + *\li 'task' is the calling task, and has obtained + * exclusive access by calling isc_task_spl(). + */ + +void +isc_task_getcurrenttime(isc_task_t *task, isc_stdtime_t *t); +/*%< + * Provide the most recent timestamp on the task. The timestamp is considered + * as the "current time" in the second-order granularity. + * + * Requires: + *\li 'task' is a valid task. + *\li 't' is a valid non NULL pointer. + * + * Ensures: + *\li '*t' has the "current time". + */ + +isc_boolean_t +isc_task_exiting(isc_task_t *t); +/*%< + * Returns ISC_TRUE if the task is in the process of shutting down, + * ISC_FALSE otherwise. + * + * Requires: + *\li 'task' is a valid task. + */ + +void +isc_task_setprivilege(isc_task_t *task, isc_boolean_t priv); +/*%< + * Set or unset the task's "privileged" flag depending on the value of + * 'priv'. + * + * Under normal circumstances this flag has no effect on the task behavior, + * but when the task manager has been set to privileged exeuction mode via + * isc_taskmgr_setmode(), only tasks with the flag set will be executed, + * and all other tasks will wait until they're done. Once all privileged + * tasks have finished executing, the task manager will automatically + * return to normal execution mode and nonprivileged task can resume. + * + * Requires: + *\li 'task' is a valid task. + */ + +isc_boolean_t +isc_task_privilege(isc_task_t *task); +/*%< + * Returns the current value of the task's privilege flag. + * + * Requires: + *\li 'task' is a valid task. + */ + +/***** + ***** Task Manager. + *****/ + +isc_result_t +isc_taskmgr_createinctx(isc_mem_t *mctx, isc_appctx_t *actx, + unsigned int workers, unsigned int default_quantum, + isc_taskmgr_t **managerp); +isc_result_t +isc_taskmgr_create(isc_mem_t *mctx, unsigned int workers, + unsigned int default_quantum, isc_taskmgr_t **managerp); +/*%< + * Create a new task manager. isc_taskmgr_createinctx() also associates + * the new manager with the specified application context. + * + * Notes: + * + *\li 'workers' in the number of worker threads to create. In general, + * the value should be close to the number of processors in the system. + * The 'workers' value is advisory only. An attempt will be made to + * create 'workers' threads, but if at least one thread creation + * succeeds, isc_taskmgr_create() may return ISC_R_SUCCESS. + * + *\li If 'default_quantum' is non-zero, then it will be used as the default + * quantum value when tasks are created. If zero, then an implementation + * defined default quantum will be used. + * + * Requires: + * + *\li 'mctx' is a valid memory context. + * + *\li workers > 0 + * + *\li managerp != NULL && *managerp == NULL + * + *\li 'actx' is a valid application context (for createinctx()). + * + * Ensures: + * + *\li On success, '*managerp' will be attached to the newly created task + * manager. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_NOTHREADS No threads could be created. + *\li #ISC_R_UNEXPECTED An unexpected error occurred. + *\li #ISC_R_SHUTTINGDOWN The non-threaded, shared, task + * manager shutting down. + */ + +void +isc_taskmgr_setmode(isc_taskmgr_t *manager, isc_taskmgrmode_t mode); + +isc_taskmgrmode_t +isc_taskmgr_mode(isc_taskmgr_t *manager); +/*%< + * Set/get the current operating mode of the task manager. Valid modes are: + * + *\li isc_taskmgrmode_normal + *\li isc_taskmgrmode_privileged + * + * In privileged execution mode, only tasks that have had the "privilege" + * flag set via isc_task_setprivilege() can be executed. When all such + * tasks are complete, the manager automatically returns to normal mode + * and proceeds with running non-privileged ready tasks. This means it is + * necessary to have at least one privileged task waiting on the ready + * queue *before* setting the manager into privileged execution mode, + * which in turn means the task which calls this function should be in + * task-exclusive mode when it does so. + * + * Requires: + * + *\li 'manager' is a valid task manager. + */ + +void +isc_taskmgr_destroy(isc_taskmgr_t **managerp); +/*%< + * Destroy '*managerp'. + * + * Notes: + * + *\li Calling isc_taskmgr_destroy() will shutdown all tasks managed by + * *managerp that haven't already been shutdown. The call will block + * until all tasks have entered the done state. + * + *\li isc_taskmgr_destroy() must not be called by a task event action, + * because it would block forever waiting for the event action to + * complete. An event action that wants to cause task manager shutdown + * should request some non-event action thread of execution to do the + * shutdown, e.g. by signaling a condition variable or using + * isc_app_shutdown(). + * + *\li Task manager references are not reference counted, so the caller + * must ensure that no attempt will be made to use the manager after + * isc_taskmgr_destroy() returns. + * + * Requires: + * + *\li '*managerp' is a valid task manager. + * + *\li isc_taskmgr_destroy() has not be called previously on '*managerp'. + * + * Ensures: + * + *\li All resources used by the task manager, and any tasks it managed, + * have been freed. + */ + +#ifdef HAVE_LIBXML2 + +void +isc_taskmgr_renderxml(isc_taskmgr_t *mgr, xmlTextWriterPtr writer); + +#endif + +/*%< + * See isc_taskmgr_create() above. + */ +typedef isc_result_t +(*isc_taskmgrcreatefunc_t)(isc_mem_t *mctx, unsigned int workers, + unsigned int default_quantum, + isc_taskmgr_t **managerp); + +isc_result_t +isc_task_register(isc_taskmgrcreatefunc_t createfunc); +/*%< + * Register a new task management implementation and add it to the list of + * supported implementations. This function must be called when a different + * event library is used than the one contained in the ISC library. + */ + +isc_result_t +isc__task_register(void); +/*%< + * A short cut function that specifies the task management module in the ISC + * library for isc_task_register(). An application that uses the ISC library + * usually do not have to care about this function: it would call + * isc_lib_register(), which internally calls this function. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_TASK_H */ diff --git a/contrib/ntp/lib/isc/include/isc/taskpool.h b/contrib/ntp/lib/isc/include/isc/taskpool.h new file mode 100644 index 000000000..46f395ea2 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/taskpool.h @@ -0,0 +1,157 @@ +/* + * Copyright (C) 2004-2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_TASKPOOL_H +#define ISC_TASKPOOL_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/taskpool.h + * \brief A task pool is a mechanism for sharing a small number of tasks + * among a large number of objects such that each object is + * assigned a unique task, but each task may be shared by several + * objects. + * + * Task pools are used to let objects that can exist in large + * numbers (e.g., zones) use tasks for synchronization without + * the memory overhead and unfair scheduling competition that + * could result from creating a separate task for each object. + */ + + +/*** + *** Imports. + ***/ + +#include +#include + +ISC_LANG_BEGINDECLS + +/***** + ***** Types. + *****/ + +typedef struct isc_taskpool isc_taskpool_t; + +/***** + ***** Functions. + *****/ + +isc_result_t +isc_taskpool_create(isc_taskmgr_t *tmgr, isc_mem_t *mctx, + unsigned int ntasks, unsigned int quantum, + isc_taskpool_t **poolp); +/*%< + * Create a task pool of "ntasks" tasks, each with quantum + * "quantum". + * + * Requires: + * + *\li 'tmgr' is a valid task manager. + * + *\li 'mctx' is a valid memory context. + * + *\li poolp != NULL && *poolp == NULL + * + * Ensures: + * + *\li On success, '*taskp' points to the new task pool. + * + * Returns: + * + *\li #ISC_R_SUCCESS + *\li #ISC_R_NOMEMORY + *\li #ISC_R_UNEXPECTED + */ + +void +isc_taskpool_gettask(isc_taskpool_t *pool, isc_task_t **targetp); +/*%< + * Attach to a task from the pool. Currently the next task is chosen + * from the pool at random. (This may be changed in the future to + * something that guaratees balance.) + */ + +int +isc_taskpool_size(isc_taskpool_t *pool); +/*%< + * Returns the number of tasks in the task pool 'pool'. + */ + +isc_result_t +isc_taskpool_expand(isc_taskpool_t **sourcep, unsigned int size, + isc_taskpool_t **targetp); + +/*%< + * If 'size' is larger than the number of tasks in the pool pointed to by + * 'sourcep', then a new taskpool of size 'size' is allocated, the existing + * tasks from are moved into it, additional tasks are created to bring the + * total number up to 'size', and the resulting pool is attached to + * 'targetp'. + * + * If 'size' is less than or equal to the tasks in pool 'source', then + * 'sourcep' is attached to 'targetp' without any other action being taken. + * + * In either case, 'sourcep' is detached. + * + * Requires: + * + * \li 'sourcep' is not NULL and '*source' is not NULL + * \li 'targetp' is not NULL and '*source' is NULL + * + * Ensures: + * + * \li On success, '*targetp' points to a valid task pool. + * \li On success, '*sourcep' points to NULL. + * + * Returns: + * + * \li #ISC_R_SUCCESS + * \li #ISC_R_NOMEMORY + */ + +void +isc_taskpool_destroy(isc_taskpool_t **poolp); +/*%< + * Destroy a task pool. The tasks in the pool are detached but not + * shut down. + * + * Requires: + * \li '*poolp' is a valid task pool. + */ + +void +isc_taskpool_setprivilege(isc_taskpool_t *pool, isc_boolean_t priv); +/*%< + * Set the privilege flag on all tasks in 'pool' to 'priv'. If 'priv' is + * true, then when the task manager is set into privileged mode, only + * tasks wihin this pool will be able to execute. (Note: It is important + * to turn the pool tasks' privilege back off before the last task finishes + * executing.) + * + * Requires: + * \li 'pool' is a valid task pool. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_TASKPOOL_H */ diff --git a/contrib/ntp/lib/isc/include/isc/timer.h b/contrib/ntp/lib/isc/include/isc/timer.h new file mode 100644 index 000000000..fa9abb16a --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/timer.h @@ -0,0 +1,431 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: timer.h,v 1.43 2009/09/02 23:48:03 tbox Exp $ */ + +#ifndef ISC_TIMER_H +#define ISC_TIMER_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file isc/timer.h + * \brief Provides timers which are event sources in the task system. + * + * Three types of timers are supported: + * + *\li 'ticker' timers generate a periodic tick event. + * + *\li 'once' timers generate an idle timeout event if they are idle for too + * long, and generate a life timeout event if their lifetime expires. + * They are used to implement both (possibly expiring) idle timers and + * 'one-shot' timers. + * + *\li 'limited' timers generate a periodic tick event until they reach + * their lifetime when they generate a life timeout event. + * + *\li 'inactive' timers generate no events. + * + * Timers can change type. It is typical to create a timer as + * an 'inactive' timer and then change it into a 'ticker' or + * 'once' timer. + * + *\li MP: + * The module ensures appropriate synchronization of data structures it + * creates and manipulates. + * Clients of this module must not be holding a timer's task's lock when + * making a call that affects that timer. Failure to follow this rule + * can result in deadlock. + * The caller must ensure that isc_timermgr_destroy() is called only + * once for a given manager. + * + * \li Reliability: + * No anticipated impact. + * + * \li Resources: + * TBS + * + * \li Security: + * No anticipated impact. + * + * \li Standards: + * None. + */ + + +/*** + *** Imports + ***/ + +#include +#include +#include +#include +#include + +ISC_LANG_BEGINDECLS + +/*** + *** Types + ***/ + +/*% Timer Type */ +typedef enum { + isc_timertype_ticker = 0, /*%< Ticker */ + isc_timertype_once = 1, /*%< Once */ + isc_timertype_limited = 2, /*%< Limited */ + isc_timertype_inactive = 3 /*%< Inactive */ +} isc_timertype_t; + +typedef struct isc_timerevent { + struct isc_event common; + isc_time_t due; +} isc_timerevent_t; + +#define ISC_TIMEREVENT_FIRSTEVENT (ISC_EVENTCLASS_TIMER + 0) +#define ISC_TIMEREVENT_TICK (ISC_EVENTCLASS_TIMER + 1) +#define ISC_TIMEREVENT_IDLE (ISC_EVENTCLASS_TIMER + 2) +#define ISC_TIMEREVENT_LIFE (ISC_EVENTCLASS_TIMER + 3) +#define ISC_TIMEREVENT_LASTEVENT (ISC_EVENTCLASS_TIMER + 65535) + +/*% Timer and timer manager methods */ +typedef struct { + void (*destroy)(isc_timermgr_t **managerp); + isc_result_t (*timercreate)(isc_timermgr_t *manager, + isc_timertype_t type, + isc_time_t *expires, + isc_interval_t *interval, + isc_task_t *task, + isc_taskaction_t action, + const void *arg, + isc_timer_t **timerp); +} isc_timermgrmethods_t; + +typedef struct { + void (*attach)(isc_timer_t *timer, isc_timer_t **timerp); + void (*detach)(isc_timer_t **timerp); + isc_result_t (*reset)(isc_timer_t *timer, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_boolean_t purge); + isc_result_t (*touch)(isc_timer_t *timer); +} isc_timermethods_t; + +/*% + * This structure is actually just the common prefix of a timer manager + * object implementation's version of an isc_timermgr_t. + * \brief + * Direct use of this structure by clients is forbidden. timer implementations + * may change the structure. 'magic' must be ISCAPI_TIMERMGR_MAGIC for any + * of the isc_timer_ routines to work. timer implementations must maintain + * all timer invariants. + */ +struct isc_timermgr { + unsigned int impmagic; + unsigned int magic; + isc_timermgrmethods_t *methods; +}; + +#define ISCAPI_TIMERMGR_MAGIC ISC_MAGIC('A','t','m','g') +#define ISCAPI_TIMERMGR_VALID(m) ((m) != NULL && \ + (m)->magic == ISCAPI_TIMERMGR_MAGIC) + +/*% + * This is the common prefix of a timer object. The same note as + * that for the timermgr structure applies. + */ +struct isc_timer { + unsigned int impmagic; + unsigned int magic; + isc_timermethods_t *methods; +}; + +#define ISCAPI_TIMER_MAGIC ISC_MAGIC('A','t','m','r') +#define ISCAPI_TIMER_VALID(s) ((s) != NULL && \ + (s)->magic == ISCAPI_TIMER_MAGIC) + +/*** + *** Timer and Timer Manager Functions + *** + *** Note: all Ensures conditions apply only if the result is success for + *** those functions which return an isc_result_t. + ***/ + +isc_result_t +isc_timer_create(isc_timermgr_t *manager, + isc_timertype_t type, + isc_time_t *expires, + isc_interval_t *interval, + isc_task_t *task, + isc_taskaction_t action, + const void *arg, + isc_timer_t **timerp); +/*%< + * Create a new 'type' timer managed by 'manager'. The timers parameters + * are specified by 'expires' and 'interval'. Events will be posted to + * 'task' and when dispatched 'action' will be called with 'arg' as the + * arg value. The new timer is returned in 'timerp'. + * + * Notes: + * + *\li For ticker timers, the timer will generate a 'tick' event every + * 'interval' seconds. The value of 'expires' is ignored. + * + *\li For once timers, 'expires' specifies the time when a life timeout + * event should be generated. If 'expires' is 0 (the epoch), then no life + * timeout will be generated. 'interval' specifies how long the timer + * can be idle before it generates an idle timeout. If 0, then no + * idle timeout will be generated. + * + *\li If 'expires' is NULL, the epoch will be used. + * + * If 'interval' is NULL, the zero interval will be used. + * + * Requires: + * + *\li 'manager' is a valid manager + * + *\li 'task' is a valid task + * + *\li 'action' is a valid action + * + *\li 'expires' points to a valid time, or is NULL. + * + *\li 'interval' points to a valid interval, or is NULL. + * + *\li type == isc_timertype_inactive || + * ('expires' and 'interval' are not both 0) + * + *\li 'timerp' is a valid pointer, and *timerp == NULL + * + * Ensures: + * + *\li '*timerp' is attached to the newly created timer + * + *\li The timer is attached to the task + * + *\li An idle timeout will not be generated until at least Now + the + * timer's interval if 'timer' is a once timer with a non-zero + * interval. + * + * Returns: + * + *\li Success + *\li No memory + *\li Unexpected error + */ + +isc_result_t +isc_timer_reset(isc_timer_t *timer, + isc_timertype_t type, + isc_time_t *expires, + isc_interval_t *interval, + isc_boolean_t purge); +/*%< + * Change the timer's type, expires, and interval values to the given + * values. If 'purge' is TRUE, any pending events from this timer + * are purged from its task's event queue. + * + * Notes: + * + *\li If 'expires' is NULL, the epoch will be used. + * + *\li If 'interval' is NULL, the zero interval will be used. + * + * Requires: + * + *\li 'timer' is a valid timer + * + *\li The same requirements that isc_timer_create() imposes on 'type', + * 'expires' and 'interval' apply. + * + * Ensures: + * + *\li An idle timeout will not be generated until at least Now + the + * timer's interval if 'timer' is a once timer with a non-zero + * interval. + * + * Returns: + * + *\li Success + *\li No memory + *\li Unexpected error + */ + +isc_result_t +isc_timer_touch(isc_timer_t *timer); +/*%< + * Set the last-touched time of 'timer' to the current time. + * + * Requires: + * + *\li 'timer' is a valid once timer. + * + * Ensures: + * + *\li An idle timeout will not be generated until at least Now + the + * timer's interval if 'timer' is a once timer with a non-zero + * interval. + * + * Returns: + * + *\li Success + *\li Unexpected error + */ + +void +isc_timer_attach(isc_timer_t *timer, isc_timer_t **timerp); +/*%< + * Attach *timerp to timer. + * + * Requires: + * + *\li 'timer' is a valid timer. + * + *\li 'timerp' points to a NULL timer. + * + * Ensures: + * + *\li *timerp is attached to timer. + */ + +void +isc_timer_detach(isc_timer_t **timerp); +/*%< + * Detach *timerp from its timer. + * + * Requires: + * + *\li 'timerp' points to a valid timer. + * + * Ensures: + * + *\li *timerp is NULL. + * + *\li If '*timerp' is the last reference to the timer, + * then: + * + *\code + * The timer will be shutdown + * + * The timer will detach from its task + * + * All resources used by the timer have been freed + * + * Any events already posted by the timer will be purged. + * Therefore, if isc_timer_detach() is called in the context + * of the timer's task, it is guaranteed that no more + * timer event callbacks will run after the call. + *\endcode + */ + +isc_timertype_t +isc_timer_gettype(isc_timer_t *timer); +/*%< + * Return the timer type. + * + * Requires: + * + *\li 'timer' to be a valid timer. + */ + +isc_result_t +isc_timermgr_createinctx(isc_mem_t *mctx, isc_appctx_t *actx, + isc_timermgr_t **managerp); + +isc_result_t +isc_timermgr_create(isc_mem_t *mctx, isc_timermgr_t **managerp); +/*%< + * Create a timer manager. isc_timermgr_createinctx() also associates + * the new manager with the specified application context. + * + * Notes: + * + *\li All memory will be allocated in memory context 'mctx'. + * + * Requires: + * + *\li 'mctx' is a valid memory context. + * + *\li 'managerp' points to a NULL isc_timermgr_t. + * + *\li 'actx' is a valid application context (for createinctx()). + * + * Ensures: + * + *\li '*managerp' is a valid isc_timermgr_t. + * + * Returns: + * + *\li Success + *\li No memory + *\li Unexpected error + */ + +void +isc_timermgr_destroy(isc_timermgr_t **managerp); +/*%< + * Destroy a timer manager. + * + * Notes: + * + *\li This routine blocks until there are no timers left in the manager, + * so if the caller holds any timer references using the manager, it + * must detach them before calling isc_timermgr_destroy() or it will + * block forever. + * + * Requires: + * + *\li '*managerp' is a valid isc_timermgr_t. + * + * Ensures: + * + *\li *managerp == NULL + * + *\li All resources used by the manager have been freed. + */ + +void isc_timermgr_poke(isc_timermgr_t *m); + +#ifdef USE_TIMERIMPREGISTER +/*%< + * See isc_timermgr_create() above. + */ +typedef isc_result_t +(*isc_timermgrcreatefunc_t)(isc_mem_t *mctx, isc_timermgr_t **managerp); + +isc_result_t +isc__timer_register(void); +/*%< + * Register a new timer management implementation and add it to the list of + * supported implementations. This function must be called when a different + * event library is used than the one contained in the ISC library. + */ + +isc_result_t +isc_timer_register(isc_timermgrcreatefunc_t createfunc); +/*%< + * A short cut function that specifies the timer management module in the ISC + * library for isc_timer_register(). An application that uses the ISC library + * usually do not have to care about this function: it would call + * isc_lib_register(), which internally calls this function. + */ +#endif /* USE_TIMERIMPREGISTER */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_TIMER_H */ diff --git a/contrib/ntp/lib/isc/include/isc/types.h b/contrib/ntp/lib/isc/include/isc/types.h new file mode 100644 index 000000000..8dbf67ed1 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/types.h @@ -0,0 +1,129 @@ +/* + * Copyright (C) 2004-2009, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_TYPES_H +#define ISC_TYPES_H 1 + +#include +#include + +/*! \file isc/types.h + * \brief + * OS-specific types, from the OS-specific include directories. + */ +#include +#include + +/* + * XXXDCL should isc_boolean_t be moved here, requiring an explicit include + * of when ISC_TRUE/ISC_FALSE/ISC_TF() are desired? + */ +#include +/* + * XXXDCL This is just for ISC_LIST and ISC_LINK, but gets all of the other + * list macros too. + */ +#include + +/* Core Types. Alphabetized by defined type. */ + +typedef struct isc_appctx isc_appctx_t; /*%< Application context */ +typedef struct isc_backtrace_symmap isc_backtrace_symmap_t; /*%< Symbol Table Entry */ +typedef struct isc_bitstring isc_bitstring_t; /*%< Bitstring */ +typedef struct isc_buffer isc_buffer_t; /*%< Buffer */ +typedef ISC_LIST(isc_buffer_t) isc_bufferlist_t; /*%< Buffer List */ +typedef struct isc_constregion isc_constregion_t; /*%< Const region */ +typedef struct isc_consttextregion isc_consttextregion_t; /*%< Const Text Region */ +typedef struct isc_entropy isc_entropy_t; /*%< Entropy */ +typedef struct isc_entropysource isc_entropysource_t; /*%< Entropy Source */ +typedef struct isc_event isc_event_t; /*%< Event */ +typedef ISC_LIST(isc_event_t) isc_eventlist_t; /*%< Event List */ +typedef unsigned int isc_eventtype_t; /*%< Event Type */ +typedef isc_uint32_t isc_fsaccess_t; /*%< FS Access */ +typedef struct isc_hash isc_hash_t; /*%< Hash */ +typedef struct isc_httpd isc_httpd_t; /*%< HTTP client */ +typedef void (isc_httpdfree_t)(isc_buffer_t *, void *); /*%< HTTP free function */ +typedef struct isc_httpdmgr isc_httpdmgr_t; /*%< HTTP manager */ +typedef struct isc_httpdurl isc_httpdurl_t; /*%< HTTP URL */ +typedef void (isc_httpdondestroy_t)(void *); /*%< Callback on destroying httpd */ +typedef struct isc_interface isc_interface_t; /*%< Interface */ +typedef struct isc_interfaceiter isc_interfaceiter_t; /*%< Interface Iterator */ +typedef struct isc_interval isc_interval_t; /*%< Interval */ +typedef struct isc_lex isc_lex_t; /*%< Lex */ +typedef struct isc_log isc_log_t; /*%< Log */ +typedef struct isc_logcategory isc_logcategory_t; /*%< Log Category */ +typedef struct isc_logconfig isc_logconfig_t; /*%< Log Configuration */ +typedef struct isc_logmodule isc_logmodule_t; /*%< Log Module */ +typedef struct isc_mem isc_mem_t; /*%< Memory */ +typedef struct isc_mempool isc_mempool_t; /*%< Memory Pool */ +typedef struct isc_msgcat isc_msgcat_t; /*%< Message Catalog */ +typedef struct isc_ondestroy isc_ondestroy_t; /*%< On Destroy */ +typedef struct isc_netaddr isc_netaddr_t; /*%< Net Address */ +typedef struct isc_portset isc_portset_t; /*%< Port Set */ +typedef struct isc_quota isc_quota_t; /*%< Quota */ +typedef struct isc_random isc_random_t; /*%< Random */ +typedef struct isc_ratelimiter isc_ratelimiter_t; /*%< Rate Limiter */ +typedef struct isc_region isc_region_t; /*%< Region */ +typedef isc_uint64_t isc_resourcevalue_t; /*%< Resource Value */ +typedef unsigned int isc_result_t; /*%< Result */ +typedef struct isc_rwlock isc_rwlock_t; /*%< Read Write Lock */ +typedef struct isc_sockaddr isc_sockaddr_t; /*%< Socket Address */ +typedef struct isc_socket isc_socket_t; /*%< Socket */ +typedef struct isc_socketevent isc_socketevent_t; /*%< Socket Event */ +typedef struct isc_socketmgr isc_socketmgr_t; /*%< Socket Manager */ +typedef struct isc_stats isc_stats_t; /*%< Statistics */ +typedef int isc_statscounter_t; /*%< Statistics Counter */ +typedef struct isc_symtab isc_symtab_t; /*%< Symbol Table */ +typedef struct isc_task isc_task_t; /*%< Task */ +typedef ISC_LIST(isc_task_t) isc_tasklist_t; /*%< Task List */ +typedef struct isc_taskmgr isc_taskmgr_t; /*%< Task Manager */ +typedef struct isc_textregion isc_textregion_t; /*%< Text Region */ +typedef struct isc_time isc_time_t; /*%< Time */ +typedef struct isc_timer isc_timer_t; /*%< Timer */ +typedef struct isc_timermgr isc_timermgr_t; /*%< Timer Manager */ + +typedef void (*isc_taskaction_t)(isc_task_t *, isc_event_t *); +typedef int (*isc_sockfdwatch_t)(isc_task_t *, isc_socket_t *, void *, int); + +/* The following cannot be listed alphabetically due to forward reference */ +typedef isc_result_t (isc_httpdaction_t)(const char *url, + const char *querystring, + void *arg, + unsigned int *retcode, + const char **retmsg, + const char **mimetype, + isc_buffer_t *body, + isc_httpdfree_t **freecb, + void **freecb_args); +typedef isc_boolean_t (isc_httpdclientok_t)(const isc_sockaddr_t *, void *); + +/*% Resource */ +typedef enum { + isc_resource_coresize = 1, + isc_resource_cputime, + isc_resource_datasize, + isc_resource_filesize, + isc_resource_lockedmemory, + isc_resource_openfiles, + isc_resource_processes, + isc_resource_residentsize, + isc_resource_stacksize +} isc_resource_t; + +#endif /* ISC_TYPES_H */ diff --git a/contrib/ntp/include/isc/util.h b/contrib/ntp/lib/isc/include/isc/util.h similarity index 87% rename from contrib/ntp/include/isc/util.h rename to contrib/ntp/lib/isc/include/isc/util.h index 6144e11ba..670b28bc4 100644 --- a/contrib/ntp/include/isc/util.h +++ b/contrib/ntp/lib/isc/include/isc/util.h @@ -1,31 +1,32 @@ /* + * Copyright (C) 2004-2007, 2010-2012 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1998-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: util.h,v 1.23 2001/11/30 01:59:38 gson Exp $ */ +/* $Id$ */ #ifndef ISC_UTIL_H #define ISC_UTIL_H 1 -/* +/*! \file isc/util.h * NOTE: * * This file is not to be included from any (or other) library * files. * + * \brief * Including this file puts several macros in your name space that are * not protected (as all the other ISC functions/macros do) by prepending * ISC_ or isc_ to the name. @@ -35,21 +36,27 @@ *** General Macros. ***/ -/* +/*% * Use this to hide unused function arguments. - * + * \code * int * foo(char *bar) * { * UNUSED(bar); * } + * \endcode */ #define UNUSED(x) (void)(x) +/*% + * The opposite: silent warnings about stored values which are never read. + */ +#define POST(x) (void)(x) + #define ISC_MAX(a, b) ((a) > (b) ? (a) : (b)) #define ISC_MIN(a, b) ((a) < (b) ? (a) : (b)) -/* +/*% * Use this to remove the const qualifier of a variable to assign it to * a non-const variable or pass it as a non-const function argument ... * but only when you are sure it won't then be changed! @@ -64,16 +71,15 @@ var = _u.v; \ } while (0) -/* +/*% * Use this in translation units that would otherwise be empty, to * suppress compiler warnings. */ -#define EMPTY_TRANSLATION_UNIT static void isc__empty(void) { isc__empty(); } +#define EMPTY_TRANSLATION_UNIT extern void exit(int); -/* +/*% * We use macros instead of calling the routines directly because * the capital letters make the locking stand out. - * * We RUNTIME_CHECK for success since in general there's no way * for us to continue if they fail. */ @@ -203,9 +209,13 @@ */ #include /* Contractual promise. */ +/*% Require Assertion */ #define REQUIRE(e) ISC_REQUIRE(e) +/*% Ensure Assertion */ #define ENSURE(e) ISC_ENSURE(e) +/*% Insist Assertion */ #define INSIST(e) ISC_INSIST(e) +/*% Invariant Assertion */ #define INVARIANT(e) ISC_INVARIANT(e) /* @@ -213,11 +223,14 @@ */ #include /* Contractual promise. */ +/*% Unexpected Error */ #define UNEXPECTED_ERROR isc_error_unexpected +/*% Fatal Error */ #define FATAL_ERROR isc_error_fatal +/*% Runtime Check */ #define RUNTIME_CHECK(cond) ISC_ERROR_RUNTIMECHECK(cond) -/* +/*% * Time */ #define TIME_NOW(tp) RUNTIME_CHECK(isc_time_now((tp)) == ISC_R_SUCCESS) diff --git a/contrib/ntp/lib/isc/include/isc/version.h b/contrib/ntp/lib/isc/include/isc/version.h new file mode 100644 index 000000000..ec00bdea7 --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/version.h @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: version.h,v 1.9 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file isc/version.h */ + +#include + +LIBISC_EXTERNAL_DATA extern const char isc_version[]; + +LIBISC_EXTERNAL_DATA extern const unsigned int isc_libinterface; +LIBISC_EXTERNAL_DATA extern const unsigned int isc_librevision; +LIBISC_EXTERNAL_DATA extern const unsigned int isc_libage; diff --git a/contrib/ntp/lib/isc/include/isc/xml.h b/contrib/ntp/lib/isc/include/isc/xml.h new file mode 100644 index 000000000..d31a31a7f --- /dev/null +++ b/contrib/ntp/lib/isc/include/isc/xml.h @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: xml.h,v 1.4 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_XML_H +#define ISC_XML_H 1 + +/* + * This file is here mostly to make it easy to add additional libxml header + * files as needed across all the users of this file. Rather than place + * these libxml includes in each file, one include makes it easy to handle + * the ifdef as well as adding the ability to add additional functions + * which may be useful. + */ + +#ifdef HAVE_LIBXML2 +#include +#include +#endif + +#define ISC_XMLCHAR (const xmlChar *) + +#define ISC_XML_RENDERCONFIG 0x00000001 /* render config data */ +#define ISC_XML_RENDERSTATS 0x00000002 /* render stats */ +#define ISC_XML_RENDERALL 0x000000ff /* render everything */ + +#endif /* ISC_XML_H */ diff --git a/contrib/ntp/libisc/inet_aton.c b/contrib/ntp/lib/isc/inet_aton.c similarity index 94% rename from contrib/ntp/libisc/inet_aton.c rename to contrib/ntp/lib/isc/inet_aton.c index 530b0103b..14b4887f4 100644 --- a/contrib/ntp/libisc/inet_aton.c +++ b/contrib/ntp/lib/isc/inet_aton.c @@ -1,8 +1,8 @@ /* - * Portions Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Portions Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") * Portions Copyright (C) 1996-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -67,10 +67,11 @@ * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS * SOFTWARE. */ +/*! \file */ #if defined(LIBC_SCCS) && !defined(lint) static char sccsid[] = "@(#)inet_addr.c 8.1 (Berkeley) 6/17/93"; -static char rcsid[] = "$Id: inet_aton.c,v 1.15.12.3 2004/03/08 09:04:49 marka Exp $"; +static char rcsid[] = "$Id: inet_aton.c,v 1.23 2008/12/01 23:47:45 tbox Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -81,7 +82,7 @@ static char rcsid[] = "$Id: inet_aton.c,v 1.15.12.3 2004/03/08 09:04:49 marka Ex #include #include -/* +/*% * Check whether "cp" is a valid ascii representation * of an Internet address and convert to a binary address. * Returns 1 if the address is valid, 0 if not. @@ -144,7 +145,7 @@ isc_net_aton(const char *cp, struct in_addr *addr) { * a.b.c (with c treated as 16 bits) * a.b (with b treated as 24 bits) */ - if (pp >= parts + 3 || val > 0xff) + if (pp >= parts + 3 || val > 0xffU) return (0); *pp++ = (isc_uint8_t)val; c = *++cp; @@ -171,19 +172,19 @@ isc_net_aton(const char *cp, struct in_addr *addr) { break; case 2: /* a.b -- 8.24 bits */ - if (val > 0xffffff) + if (val > 0xffffffU) return (0); val |= parts[0] << 24; break; case 3: /* a.b.c -- 8.8.16 bits */ - if (val > 0xffff) + if (val > 0xffffU) return (0); val |= (parts[0] << 24) | (parts[1] << 16); break; case 4: /* a.b.c.d -- 8.8.8.8 bits */ - if (val > 0xff) + if (val > 0xffU) return (0); val |= (parts[0] << 24) | (parts[1] << 16) | (parts[2] << 8); break; diff --git a/contrib/ntp/libisc/inet_ntop.c b/contrib/ntp/lib/isc/inet_ntop.c similarity index 76% rename from contrib/ntp/libisc/inet_ntop.c rename to contrib/ntp/lib/isc/inet_ntop.c index 395d0e50d..773018031 100644 --- a/contrib/ntp/libisc/inet_ntop.c +++ b/contrib/ntp/lib/isc/inet_ntop.c @@ -1,23 +1,25 @@ /* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1996-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ +/*! \file */ + #if defined(LIBC_SCCS) && !defined(lint) static char rcsid[] = - "$Id: inet_ntop.c,v 1.13 2001/11/27 01:56:00 gson Exp $"; + "$Id: inet_ntop.c,v 1.21 2009/07/17 23:47:41 tbox Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -27,8 +29,7 @@ static char rcsid[] = #include #include - -#include "ntp_sprintf.h" +#include #define NS_INT16SZ 2 #define NS_IN6ADDRSZ 16 @@ -45,13 +46,14 @@ static const char *inet_ntop4(const unsigned char *src, char *dst, static const char *inet_ntop6(const unsigned char *src, char *dst, size_t size); #endif +const char *isc_net_ntop(int af, const void *src, char *dst, size_t size); -/* char * +/*! char * * isc_net_ntop(af, src, dst, size) * convert a network format address to presentation format. - * return: + * \return * pointer to presentation format address (`dst'), or NULL (see errno). - * author: + * \author * Paul Vixie, 1996. */ const char * @@ -71,15 +73,16 @@ isc_net_ntop(int af, const void *src, char *dst, size_t size) /* NOTREACHED */ } -/* const char * +/*! const char * * inet_ntop4(src, dst, size) * format an IPv4 address - * return: + * \return * `dst' (as a const) - * notes: + * \note * (1) uses no statics + * \note * (2) takes a unsigned char* not an in_addr as input - * author: + * \author * Paul Vixie, 1996. */ static const char * @@ -87,21 +90,23 @@ inet_ntop4(const unsigned char *src, char *dst, size_t size) { static const char *fmt = "%u.%u.%u.%u"; char tmp[sizeof("255.255.255.255")]; + int len; - if (SPRINTF((tmp, fmt, src[0], src[1], src[2], src[3])) >= size) + len = snprintf(tmp, sizeof(tmp), fmt, src[0], src[1], src[2], src[3]); + if (len < 0 || (size_t)len >= size) { errno = ENOSPC; return (NULL); } - strcpy(dst, tmp); + memcpy(dst, tmp, 1 + len); return (dst); } -/* const char * +/*! const char * * isc_inet_ntop6(src, dst, size) * convert IPv6 binary address into presentation (printable) format - * author: + * \author * Paul Vixie, 1996. */ #ifdef AF_INET6 @@ -129,9 +134,8 @@ inet_ntop6(const unsigned char *src, char *dst, size_t size) for (i = 0; i < NS_IN6ADDRSZ; i++) words[i / 2] |= (src[i] << ((1 - (i % 2)) << 3)); best.base = -1; - best.len = 0; cur.base = -1; - cur.len = 0; + best.len = cur.len = 0; for (i = 0; i < (NS_IN6ADDRSZ / NS_INT16SZ); i++) { if (words[i] == 0) { if (cur.base == -1) @@ -169,15 +173,16 @@ inet_ntop6(const unsigned char *src, char *dst, size_t size) if (i != 0) *tp++ = ':'; /* Is this address an encapsulated IPv4? */ - if (i == 6 && best.base == 0 && - (best.len == 6 || (best.len == 5 && words[5] == 0xffff))) { + if (i == 6 && best.base == 0 && (best.len == 6 || + (best.len == 7 && words[7] != 0x0001) || + (best.len == 5 && words[5] == 0xffff))) { if (!inet_ntop4(src+12, tp, sizeof(tmp) - (tp - tmp))) return (NULL); tp += strlen(tp); break; } - tp += SPRINTF((tp, "%x", words[i])); + tp += snprintf(tp, sizeof(tmp) - (tp - tmp), "%x", words[i]); } /* Was it a trailing run of 0x00's? */ if (best.base != -1 && (best.base + best.len) == @@ -192,7 +197,7 @@ inet_ntop6(const unsigned char *src, char *dst, size_t size) errno = ENOSPC; return (NULL); } - strcpy(dst, tmp); + memcpy(dst, tmp, (size_t)(tp - tmp)); return (dst); } #endif /* AF_INET6 */ diff --git a/contrib/ntp/libisc/inet_pton.c b/contrib/ntp/lib/isc/inet_pton.c similarity index 82% rename from contrib/ntp/libisc/inet_pton.c rename to contrib/ntp/lib/isc/inet_pton.c index afda394ca..66b5de0bf 100644 --- a/contrib/ntp/libisc/inet_pton.c +++ b/contrib/ntp/lib/isc/inet_pton.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1996-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,9 +15,11 @@ * PERFORMANCE OF THIS SOFTWARE. */ +/*! \file */ + #if defined(LIBC_SCCS) && !defined(lint) static char rcsid[] = - "$Id: inet_pton.c,v 1.10.2.4.2.1 2004/03/06 08:14:31 marka Exp $"; + "$Id: inet_pton.c,v 1.19 2007/06/19 23:47:17 tbox Exp $"; #endif /* LIBC_SCCS and not lint */ #include @@ -27,8 +29,11 @@ static char rcsid[] = #include +/*% INT16 Size */ #define NS_INT16SZ 2 +/*% IPv4 Address Size */ #define NS_INADDRSZ 4 +/*% IPv6 Address Size */ #define NS_IN6ADDRSZ 16 /* @@ -38,16 +43,16 @@ static char rcsid[] = static int inet_pton4(const char *src, unsigned char *dst); static int inet_pton6(const char *src, unsigned char *dst); +int isc_net_pton(int af, const char *src, void *dst); -/* int - * isc_net_pton(af, src, dst) +/*% * convert from presentation format (which usually means ASCII printable) * to network format (which is usually some kind of binary format). - * return: + * \return * 1 if the address was valid for the specified address family * 0 if the address wasn't valid (`dst' is untouched in this case) * -1 if some other error occurred (`dst' is untouched in this case, too) - * author: + * \author * Paul Vixie, 1996. */ int @@ -64,14 +69,14 @@ isc_net_pton(int af, const char *src, void *dst) { /* NOTREACHED */ } -/* int - * inet_pton4(src, dst) +/*!\fn static int inet_pton4(const char *src, unsigned char *dst) + * \brief * like inet_aton() but without all the hexadecimal and shorthand. - * return: + * \return * 1 if `src' is a valid dotted quad, else 0. - * notice: + * \note * does not touch `dst' unless it's returning 1. - * author: + * \author * Paul Vixie, 1996. */ static int @@ -87,13 +92,13 @@ inet_pton4(const char *src, unsigned char *dst) { const char *pch; if ((pch = strchr(digits, ch)) != NULL) { - unsigned int new = *tp * 10 + (pch - digits); + unsigned int newv = *tp * 10 + (pch - digits); if (saw_digit && *tp == 0) return (0); - if (new > 255) + if (newv > 255) return (0); - *tp = (unsigned char) new; + *tp = (unsigned char)newv; if (!saw_digit) { if (++octets > 4) return (0); @@ -113,17 +118,17 @@ inet_pton4(const char *src, unsigned char *dst) { return (1); } -/* int - * inet_pton6(src, dst) +/*% * convert presentation level address to network order binary form. - * return: + * \return * 1 if `src' is a valid [RFC1884 2.2] address, else 0. - * notice: + * \note * (1) does not touch `dst' unless it's returning 1. + * \note * (2) :: in a full address is silently ignored. - * credit: + * \author * inspired by Mark Andrews. - * author: + * \author * Paul Vixie, 1996. */ static int @@ -132,7 +137,7 @@ inet_pton6(const char *src, unsigned char *dst) { xdigits_u[] = "0123456789ABCDEF"; unsigned char tmp[NS_IN6ADDRSZ], *tp, *endp, *colonp; const char *xdigits, *curtok; - int ch, saw_xdigit; + int ch, seen_xdigits; unsigned int val; memset((tp = tmp), '\0', NS_IN6ADDRSZ); @@ -143,7 +148,7 @@ inet_pton6(const char *src, unsigned char *dst) { if (*++src != ':') return (0); curtok = src; - saw_xdigit = 0; + seen_xdigits = 0; val = 0; while ((ch = *src++) != '\0') { const char *pch; @@ -153,14 +158,13 @@ inet_pton6(const char *src, unsigned char *dst) { if (pch != NULL) { val <<= 4; val |= (pch - xdigits); - if (val > 0xffff) + if (++seen_xdigits > 4) return (0); - saw_xdigit = 1; continue; } if (ch == ':') { curtok = src; - if (!saw_xdigit) { + if (!seen_xdigits) { if (colonp) return (0); colonp = tp; @@ -168,25 +172,25 @@ inet_pton6(const char *src, unsigned char *dst) { } if (tp + NS_INT16SZ > endp) return (0); - *tp++ = (unsigned char) ((val >> 8) & 0xff); - *tp++ = (unsigned char) (val & 0xff); - saw_xdigit = 0; + *tp++ = (unsigned char) (val >> 8) & 0xff; + *tp++ = (unsigned char) val & 0xff; + seen_xdigits = 0; val = 0; continue; } if (ch == '.' && ((tp + NS_INADDRSZ) <= endp) && inet_pton4(curtok, tp) > 0) { tp += NS_INADDRSZ; - saw_xdigit = 0; + seen_xdigits = 0; break; /* '\0' was seen by inet_pton4(). */ } return (0); } - if (saw_xdigit) { + if (seen_xdigits) { if (tp + NS_INT16SZ > endp) return (0); - *tp++ = (unsigned char) ((val >> 8) & 0xff); - *tp++ = (unsigned char) (val & 0xff); + *tp++ = (unsigned char) (val >> 8) & 0xff; + *tp++ = (unsigned char) val & 0xff; } if (colonp != NULL) { /* diff --git a/contrib/ntp/lib/isc/iterated_hash.c b/contrib/ntp/lib/isc/iterated_hash.c new file mode 100644 index 000000000..86dedde28 --- /dev/null +++ b/contrib/ntp/lib/isc/iterated_hash.c @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2006, 2008, 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: iterated_hash.c,v 1.6 2009/02/18 23:47:48 tbox Exp $ */ + +#include "config.h" + +#include + +#include +#include + +int +isc_iterated_hash(unsigned char out[ISC_SHA1_DIGESTLENGTH], + unsigned int hashalg, int iterations, + const unsigned char *salt, int saltlength, + const unsigned char *in, int inlength) +{ + isc_sha1_t ctx; + int n = 0; + + if (hashalg != 1) + return (0); + + do { + isc_sha1_init(&ctx); + isc_sha1_update(&ctx, in, inlength); + isc_sha1_update(&ctx, salt, saltlength); + isc_sha1_final(&ctx, out); + in = out; + inlength = ISC_SHA1_DIGESTLENGTH; + } while (n++ < iterations); + + return (ISC_SHA1_DIGESTLENGTH); +} diff --git a/contrib/ntp/lib/isc/lex.c b/contrib/ntp/lib/isc/lex.c new file mode 100644 index 000000000..8749ed0b0 --- /dev/null +++ b/contrib/ntp/lib/isc/lex.c @@ -0,0 +1,959 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lex.c,v 1.86 2007/09/17 09:56:29 shane Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +typedef struct inputsource { + isc_result_t result; + isc_boolean_t is_file; + isc_boolean_t need_close; + isc_boolean_t at_eof; + isc_buffer_t * pushback; + unsigned int ignored; + void * input; + char * name; + unsigned long line; + unsigned long saved_line; + ISC_LINK(struct inputsource) link; +} inputsource; + +#define LEX_MAGIC ISC_MAGIC('L', 'e', 'x', '!') +#define VALID_LEX(l) ISC_MAGIC_VALID(l, LEX_MAGIC) + +struct isc_lex { + /* Unlocked. */ + unsigned int magic; + isc_mem_t * mctx; + size_t max_token; + char * data; + unsigned int comments; + isc_boolean_t comment_ok; + isc_boolean_t last_was_eol; + unsigned int paren_count; + unsigned int saved_paren_count; + isc_lexspecials_t specials; + LIST(struct inputsource) sources; +}; + +static inline isc_result_t +grow_data(isc_lex_t *lex, size_t *remainingp, char **currp, char **prevp) { + char *new; + + new = isc_mem_get(lex->mctx, lex->max_token * 2 + 1); + if (new == NULL) + return (ISC_R_NOMEMORY); + memcpy(new, lex->data, lex->max_token + 1); + *currp = new + (*currp - lex->data); + if (*prevp != NULL) + *prevp = new + (*prevp - lex->data); + isc_mem_put(lex->mctx, lex->data, lex->max_token + 1); + lex->data = new; + *remainingp += lex->max_token; + lex->max_token *= 2; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_create(isc_mem_t *mctx, size_t max_token, isc_lex_t **lexp) { + isc_lex_t *lex; + + /* + * Create a lexer. + */ + + REQUIRE(lexp != NULL && *lexp == NULL); + REQUIRE(max_token > 0U); + + lex = isc_mem_get(mctx, sizeof(*lex)); + if (lex == NULL) + return (ISC_R_NOMEMORY); + lex->data = isc_mem_get(mctx, max_token + 1); + if (lex->data == NULL) { + isc_mem_put(mctx, lex, sizeof(*lex)); + return (ISC_R_NOMEMORY); + } + lex->mctx = mctx; + lex->max_token = max_token; + lex->comments = 0; + lex->comment_ok = ISC_TRUE; + lex->last_was_eol = ISC_TRUE; + lex->paren_count = 0; + lex->saved_paren_count = 0; + memset(lex->specials, 0, 256); + INIT_LIST(lex->sources); + lex->magic = LEX_MAGIC; + + *lexp = lex; + + return (ISC_R_SUCCESS); +} + +void +isc_lex_destroy(isc_lex_t **lexp) { + isc_lex_t *lex; + + /* + * Destroy the lexer. + */ + + REQUIRE(lexp != NULL); + lex = *lexp; + REQUIRE(VALID_LEX(lex)); + + while (!EMPTY(lex->sources)) + RUNTIME_CHECK(isc_lex_close(lex) == ISC_R_SUCCESS); + if (lex->data != NULL) + isc_mem_put(lex->mctx, lex->data, lex->max_token + 1); + lex->magic = 0; + isc_mem_put(lex->mctx, lex, sizeof(*lex)); + + *lexp = NULL; +} + +unsigned int +isc_lex_getcomments(isc_lex_t *lex) { + /* + * Return the current lexer commenting styles. + */ + + REQUIRE(VALID_LEX(lex)); + + return (lex->comments); +} + +void +isc_lex_setcomments(isc_lex_t *lex, unsigned int comments) { + /* + * Set allowed lexer commenting styles. + */ + + REQUIRE(VALID_LEX(lex)); + + lex->comments = comments; +} + +void +isc_lex_getspecials(isc_lex_t *lex, isc_lexspecials_t specials) { + /* + * Put the current list of specials into 'specials'. + */ + + REQUIRE(VALID_LEX(lex)); + + memcpy(specials, lex->specials, 256); +} + +void +isc_lex_setspecials(isc_lex_t *lex, isc_lexspecials_t specials) { + /* + * The characters in 'specials' are returned as tokens. Along with + * whitespace, they delimit strings and numbers. + */ + + REQUIRE(VALID_LEX(lex)); + + memcpy(lex->specials, specials, 256); +} + +static inline isc_result_t +new_source(isc_lex_t *lex, isc_boolean_t is_file, isc_boolean_t need_close, + void *input, const char *name) +{ + inputsource *source; + isc_result_t result; + + source = isc_mem_get(lex->mctx, sizeof(*source)); + if (source == NULL) + return (ISC_R_NOMEMORY); + source->result = ISC_R_SUCCESS; + source->is_file = is_file; + source->need_close = need_close; + source->at_eof = ISC_FALSE; + source->input = input; + source->name = isc_mem_strdup(lex->mctx, name); + if (source->name == NULL) { + isc_mem_put(lex->mctx, source, sizeof(*source)); + return (ISC_R_NOMEMORY); + } + source->pushback = NULL; + result = isc_buffer_allocate(lex->mctx, &source->pushback, + lex->max_token); + if (result != ISC_R_SUCCESS) { + isc_mem_free(lex->mctx, source->name); + isc_mem_put(lex->mctx, source, sizeof(*source)); + return (result); + } + source->ignored = 0; + source->line = 1; + ISC_LIST_INITANDPREPEND(lex->sources, source, link); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_openfile(isc_lex_t *lex, const char *filename) { + isc_result_t result; + FILE *stream = NULL; + + /* + * Open 'filename' and make it the current input source for 'lex'. + */ + + REQUIRE(VALID_LEX(lex)); + + result = isc_stdio_open(filename, "r", &stream); + if (result != ISC_R_SUCCESS) + return (result); + + result = new_source(lex, ISC_TRUE, ISC_TRUE, stream, filename); + if (result != ISC_R_SUCCESS) + (void)fclose(stream); + return (result); +} + +isc_result_t +isc_lex_openstream(isc_lex_t *lex, FILE *stream) { + char name[128]; + + /* + * Make 'stream' the current input source for 'lex'. + */ + + REQUIRE(VALID_LEX(lex)); + + snprintf(name, sizeof(name), "stream-%p", stream); + + return (new_source(lex, ISC_TRUE, ISC_FALSE, stream, name)); +} + +isc_result_t +isc_lex_openbuffer(isc_lex_t *lex, isc_buffer_t *buffer) { + char name[128]; + + /* + * Make 'buffer' the current input source for 'lex'. + */ + + REQUIRE(VALID_LEX(lex)); + + snprintf(name, sizeof(name), "buffer-%p", buffer); + + return (new_source(lex, ISC_FALSE, ISC_FALSE, buffer, name)); +} + +isc_result_t +isc_lex_close(isc_lex_t *lex) { + inputsource *source; + + /* + * Close the most recently opened object (i.e. file or buffer). + */ + + REQUIRE(VALID_LEX(lex)); + + source = HEAD(lex->sources); + if (source == NULL) + return (ISC_R_NOMORE); + + ISC_LIST_UNLINK(lex->sources, source, link); + if (source->is_file) { + if (source->need_close) + (void)fclose((FILE *)(source->input)); + } + isc_mem_free(lex->mctx, source->name); + isc_buffer_free(&source->pushback); + isc_mem_put(lex->mctx, source, sizeof(*source)); + + return (ISC_R_SUCCESS); +} + +typedef enum { + lexstate_start, + lexstate_crlf, + lexstate_string, + lexstate_number, + lexstate_maybecomment, + lexstate_ccomment, + lexstate_ccommentend, + lexstate_eatline, + lexstate_qstring +} lexstate; + +#define IWSEOL (ISC_LEXOPT_INITIALWS | ISC_LEXOPT_EOL) + +static void +pushback(inputsource *source, int c) { + REQUIRE(source->pushback->current > 0); + if (c == EOF) { + source->at_eof = ISC_FALSE; + return; + } + source->pushback->current--; + if (c == '\n') + source->line--; +} + +static isc_result_t +pushandgrow(isc_lex_t *lex, inputsource *source, int c) { + if (isc_buffer_availablelength(source->pushback) == 0) { + isc_buffer_t *tbuf = NULL; + unsigned int oldlen; + isc_region_t used; + isc_result_t result; + + oldlen = isc_buffer_length(source->pushback); + result = isc_buffer_allocate(lex->mctx, &tbuf, oldlen * 2); + if (result != ISC_R_SUCCESS) + return (result); + isc_buffer_usedregion(source->pushback, &used); + result = isc_buffer_copyregion(tbuf, &used); + INSIST(result == ISC_R_SUCCESS); + tbuf->current = source->pushback->current; + isc_buffer_free(&source->pushback); + source->pushback = tbuf; + } + isc_buffer_putuint8(source->pushback, (isc_uint8_t)c); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_gettoken(isc_lex_t *lex, unsigned int options, isc_token_t *tokenp) { + inputsource *source; + int c; + isc_boolean_t done = ISC_FALSE; + isc_boolean_t no_comments = ISC_FALSE; + isc_boolean_t escaped = ISC_FALSE; + lexstate state = lexstate_start; + lexstate saved_state = lexstate_start; + isc_buffer_t *buffer; + FILE *stream; + char *curr, *prev; + size_t remaining; + isc_uint32_t as_ulong; + unsigned int saved_options; + isc_result_t result; + + /* + * Get the next token. + */ + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + REQUIRE(tokenp != NULL); + + if (source == NULL) { + if ((options & ISC_LEXOPT_NOMORE) != 0) { + tokenp->type = isc_tokentype_nomore; + return (ISC_R_SUCCESS); + } + return (ISC_R_NOMORE); + } + + if (source->result != ISC_R_SUCCESS) + return (source->result); + + lex->saved_paren_count = lex->paren_count; + source->saved_line = source->line; + + if (isc_buffer_remaininglength(source->pushback) == 0 && + source->at_eof) + { + if ((options & ISC_LEXOPT_DNSMULTILINE) != 0 && + lex->paren_count != 0) { + lex->paren_count = 0; + return (ISC_R_UNBALANCED); + } + if ((options & ISC_LEXOPT_EOF) != 0) { + tokenp->type = isc_tokentype_eof; + return (ISC_R_SUCCESS); + } + return (ISC_R_EOF); + } + + isc_buffer_compact(source->pushback); + + saved_options = options; + if ((options & ISC_LEXOPT_DNSMULTILINE) != 0 && lex->paren_count > 0) + options &= ~IWSEOL; + + curr = lex->data; + *curr = '\0'; + + prev = NULL; + remaining = lex->max_token; + +#ifdef HAVE_FLOCKFILE + if (source->is_file) + flockfile(source->input); +#endif + + do { + if (isc_buffer_remaininglength(source->pushback) == 0) { + if (source->is_file) { + stream = source->input; + +#if defined(HAVE_FLOCKFILE) && defined(HAVE_GETCUNLOCKED) + c = getc_unlocked(stream); +#else + c = getc(stream); +#endif + if (c == EOF) { + if (ferror(stream)) { + source->result = ISC_R_IOERROR; + result = source->result; + goto done; + } + source->at_eof = ISC_TRUE; + } + } else { + buffer = source->input; + + if (buffer->current == buffer->used) { + c = EOF; + source->at_eof = ISC_TRUE; + } else { + c = *((char *)buffer->base + + buffer->current); + buffer->current++; + } + } + if (c != EOF) { + source->result = pushandgrow(lex, source, c); + if (source->result != ISC_R_SUCCESS) { + result = source->result; + goto done; + } + } + } + + if (!source->at_eof) { + if (state == lexstate_start) + /* Token has not started yet. */ + source->ignored = + isc_buffer_consumedlength(source->pushback); + c = isc_buffer_getuint8(source->pushback); + } else { + c = EOF; + } + + if (c == '\n') + source->line++; + + if (lex->comment_ok && !no_comments) { + if (!escaped && c == ';' && + ((lex->comments & ISC_LEXCOMMENT_DNSMASTERFILE) + != 0)) { + saved_state = state; + state = lexstate_eatline; + no_comments = ISC_TRUE; + continue; + } else if (c == '/' && + (lex->comments & + (ISC_LEXCOMMENT_C| + ISC_LEXCOMMENT_CPLUSPLUS)) != 0) { + saved_state = state; + state = lexstate_maybecomment; + no_comments = ISC_TRUE; + continue; + } else if (c == '#' && + ((lex->comments & ISC_LEXCOMMENT_SHELL) + != 0)) { + saved_state = state; + state = lexstate_eatline; + no_comments = ISC_TRUE; + continue; + } + } + + no_read: + /* INSIST(c == EOF || (c >= 0 && c <= 255)); */ + switch (state) { + case lexstate_start: + if (c == EOF) { + lex->last_was_eol = ISC_FALSE; + if ((options & ISC_LEXOPT_DNSMULTILINE) != 0 && + lex->paren_count != 0) { + lex->paren_count = 0; + result = ISC_R_UNBALANCED; + goto done; + } + if ((options & ISC_LEXOPT_EOF) == 0) { + result = ISC_R_EOF; + goto done; + } + tokenp->type = isc_tokentype_eof; + done = ISC_TRUE; + } else if (c == ' ' || c == '\t') { + if (lex->last_was_eol && + (options & ISC_LEXOPT_INITIALWS) + != 0) { + lex->last_was_eol = ISC_FALSE; + tokenp->type = isc_tokentype_initialws; + tokenp->value.as_char = c; + done = ISC_TRUE; + } + } else if (c == '\n') { + if ((options & ISC_LEXOPT_EOL) != 0) { + tokenp->type = isc_tokentype_eol; + done = ISC_TRUE; + } + lex->last_was_eol = ISC_TRUE; + } else if (c == '\r') { + if ((options & ISC_LEXOPT_EOL) != 0) + state = lexstate_crlf; + } else if (c == '"' && + (options & ISC_LEXOPT_QSTRING) != 0) { + lex->last_was_eol = ISC_FALSE; + no_comments = ISC_TRUE; + state = lexstate_qstring; + } else if (lex->specials[c]) { + lex->last_was_eol = ISC_FALSE; + if ((c == '(' || c == ')') && + (options & ISC_LEXOPT_DNSMULTILINE) != 0) { + if (c == '(') { + if (lex->paren_count == 0) + options &= ~IWSEOL; + lex->paren_count++; + } else { + if (lex->paren_count == 0) { + result = ISC_R_UNBALANCED; + goto done; + } + lex->paren_count--; + if (lex->paren_count == 0) + options = + saved_options; + } + continue; + } + tokenp->type = isc_tokentype_special; + tokenp->value.as_char = c; + done = ISC_TRUE; + } else if (isdigit((unsigned char)c) && + (options & ISC_LEXOPT_NUMBER) != 0) { + lex->last_was_eol = ISC_FALSE; + if ((options & ISC_LEXOPT_OCTAL) != 0 && + (c == '8' || c == '9')) + state = lexstate_string; + else + state = lexstate_number; + goto no_read; + } else { + lex->last_was_eol = ISC_FALSE; + state = lexstate_string; + goto no_read; + } + break; + case lexstate_crlf: + if (c != '\n') + pushback(source, c); + tokenp->type = isc_tokentype_eol; + done = ISC_TRUE; + lex->last_was_eol = ISC_TRUE; + break; + case lexstate_number: + if (c == EOF || !isdigit((unsigned char)c)) { + if (c == ' ' || c == '\t' || c == '\r' || + c == '\n' || c == EOF || + lex->specials[c]) { + int base; + if ((options & ISC_LEXOPT_OCTAL) != 0) + base = 8; + else if ((options & ISC_LEXOPT_CNUMBER) != 0) + base = 0; + else + base = 10; + pushback(source, c); + + result = isc_parse_uint32(&as_ulong, + lex->data, + base); + if (result == ISC_R_SUCCESS) { + tokenp->type = + isc_tokentype_number; + tokenp->value.as_ulong = + as_ulong; + } else if (result == ISC_R_BADNUMBER) { + isc_tokenvalue_t *v; + + tokenp->type = + isc_tokentype_string; + v = &(tokenp->value); + v->as_textregion.base = + lex->data; + v->as_textregion.length = + lex->max_token - + remaining; + } else + goto done; + done = ISC_TRUE; + continue; + } else if (!(options & ISC_LEXOPT_CNUMBER) || + ((c != 'x' && c != 'X') || + (curr != &lex->data[1]) || + (lex->data[0] != '0'))) { + /* Above test supports hex numbers */ + state = lexstate_string; + } + } else if ((options & ISC_LEXOPT_OCTAL) != 0 && + (c == '8' || c == '9')) { + state = lexstate_string; + } + if (remaining == 0U) { + result = grow_data(lex, &remaining, + &curr, &prev); + if (result != ISC_R_SUCCESS) + goto done; + } + INSIST(remaining > 0U); + *curr++ = c; + *curr = '\0'; + remaining--; + break; + case lexstate_string: + /* + * EOF needs to be checked before lex->specials[c] + * as lex->specials[EOF] is not a good idea. + */ + if (c == '\r' || c == '\n' || c == EOF || + (!escaped && + (c == ' ' || c == '\t' || lex->specials[c]))) { + pushback(source, c); + if (source->result != ISC_R_SUCCESS) { + result = source->result; + goto done; + } + tokenp->type = isc_tokentype_string; + tokenp->value.as_textregion.base = lex->data; + tokenp->value.as_textregion.length = + lex->max_token - remaining; + done = ISC_TRUE; + continue; + } + if ((options & ISC_LEXOPT_ESCAPE) != 0) + escaped = (!escaped && c == '\\') ? + ISC_TRUE : ISC_FALSE; + if (remaining == 0U) { + result = grow_data(lex, &remaining, + &curr, &prev); + if (result != ISC_R_SUCCESS) + goto done; + } + INSIST(remaining > 0U); + *curr++ = c; + *curr = '\0'; + remaining--; + break; + case lexstate_maybecomment: + if (c == '*' && + (lex->comments & ISC_LEXCOMMENT_C) != 0) { + state = lexstate_ccomment; + continue; + } else if (c == '/' && + (lex->comments & ISC_LEXCOMMENT_CPLUSPLUS) != 0) { + state = lexstate_eatline; + continue; + } + pushback(source, c); + c = '/'; + no_comments = ISC_FALSE; + state = saved_state; + goto no_read; + case lexstate_ccomment: + if (c == EOF) { + result = ISC_R_UNEXPECTEDEND; + goto done; + } + if (c == '*') + state = lexstate_ccommentend; + break; + case lexstate_ccommentend: + if (c == EOF) { + result = ISC_R_UNEXPECTEDEND; + goto done; + } + if (c == '/') { + /* + * C-style comments become a single space. + * We do this to ensure that a comment will + * act as a delimiter for strings and + * numbers. + */ + c = ' '; + no_comments = ISC_FALSE; + state = saved_state; + goto no_read; + } else if (c != '*') + state = lexstate_ccomment; + break; + case lexstate_eatline: + if ((c == '\n') || (c == EOF)) { + no_comments = ISC_FALSE; + state = saved_state; + goto no_read; + } + break; + case lexstate_qstring: + if (c == EOF) { + result = ISC_R_UNEXPECTEDEND; + goto done; + } + if (c == '"') { + if (escaped) { + escaped = ISC_FALSE; + /* + * Overwrite the preceding backslash. + */ + INSIST(prev != NULL); + *prev = '"'; + } else { + tokenp->type = isc_tokentype_qstring; + tokenp->value.as_textregion.base = + lex->data; + tokenp->value.as_textregion.length = + lex->max_token - remaining; + no_comments = ISC_FALSE; + done = ISC_TRUE; + } + } else { + if (c == '\n' && !escaped && + (options & ISC_LEXOPT_QSTRINGMULTILINE) == 0) { + pushback(source, c); + result = ISC_R_UNBALANCEDQUOTES; + goto done; + } + if (c == '\\' && !escaped) + escaped = ISC_TRUE; + else + escaped = ISC_FALSE; + if (remaining == 0U) { + result = grow_data(lex, &remaining, + &curr, &prev); + if (result != ISC_R_SUCCESS) + goto done; + } + INSIST(remaining > 0U); + prev = curr; + *curr++ = c; + *curr = '\0'; + remaining--; + } + break; + default: + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_LEX, + ISC_MSG_UNEXPECTEDSTATE, + "Unexpected state %d"), + state); + /* Does not return. */ + } + + } while (!done); + + result = ISC_R_SUCCESS; + done: +#ifdef HAVE_FLOCKFILE + if (source->is_file) + funlockfile(source->input); +#endif + return (result); +} + +isc_result_t +isc_lex_getmastertoken(isc_lex_t *lex, isc_token_t *token, + isc_tokentype_t expect, isc_boolean_t eol) +{ + unsigned int options = ISC_LEXOPT_EOL | ISC_LEXOPT_EOF | + ISC_LEXOPT_DNSMULTILINE | ISC_LEXOPT_ESCAPE; + isc_result_t result; + + if (expect == isc_tokentype_qstring) + options |= ISC_LEXOPT_QSTRING; + else if (expect == isc_tokentype_number) + options |= ISC_LEXOPT_NUMBER; + result = isc_lex_gettoken(lex, options, token); + if (result == ISC_R_RANGE) + isc_lex_ungettoken(lex, token); + if (result != ISC_R_SUCCESS) + return (result); + + if (eol && ((token->type == isc_tokentype_eol) || + (token->type == isc_tokentype_eof))) + return (ISC_R_SUCCESS); + if (token->type == isc_tokentype_string && + expect == isc_tokentype_qstring) + return (ISC_R_SUCCESS); + if (token->type != expect) { + isc_lex_ungettoken(lex, token); + if (token->type == isc_tokentype_eol || + token->type == isc_tokentype_eof) + return (ISC_R_UNEXPECTEDEND); + if (expect == isc_tokentype_number) + return (ISC_R_BADNUMBER); + return (ISC_R_UNEXPECTEDTOKEN); + } + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_lex_getoctaltoken(isc_lex_t *lex, isc_token_t *token, isc_boolean_t eol) +{ + unsigned int options = ISC_LEXOPT_EOL | ISC_LEXOPT_EOF | + ISC_LEXOPT_DNSMULTILINE | ISC_LEXOPT_ESCAPE| + ISC_LEXOPT_NUMBER | ISC_LEXOPT_OCTAL; + isc_result_t result; + + result = isc_lex_gettoken(lex, options, token); + if (result == ISC_R_RANGE) + isc_lex_ungettoken(lex, token); + if (result != ISC_R_SUCCESS) + return (result); + + if (eol && ((token->type == isc_tokentype_eol) || + (token->type == isc_tokentype_eof))) + return (ISC_R_SUCCESS); + if (token->type != isc_tokentype_number) { + isc_lex_ungettoken(lex, token); + if (token->type == isc_tokentype_eol || + token->type == isc_tokentype_eof) + return (ISC_R_UNEXPECTEDEND); + return (ISC_R_BADNUMBER); + } + return (ISC_R_SUCCESS); +} + +void +isc_lex_ungettoken(isc_lex_t *lex, isc_token_t *tokenp) { + inputsource *source; + /* + * Unget the current token. + */ + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + REQUIRE(source != NULL); + REQUIRE(tokenp != NULL); + REQUIRE(isc_buffer_consumedlength(source->pushback) != 0 || + tokenp->type == isc_tokentype_eof); + + UNUSED(tokenp); + + isc_buffer_first(source->pushback); + lex->paren_count = lex->saved_paren_count; + source->line = source->saved_line; + source->at_eof = ISC_FALSE; +} + +void +isc_lex_getlasttokentext(isc_lex_t *lex, isc_token_t *tokenp, isc_region_t *r) +{ + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + REQUIRE(source != NULL); + REQUIRE(tokenp != NULL); + REQUIRE(isc_buffer_consumedlength(source->pushback) != 0 || + tokenp->type == isc_tokentype_eof); + + UNUSED(tokenp); + + INSIST(source->ignored <= isc_buffer_consumedlength(source->pushback)); + r->base = (unsigned char *)isc_buffer_base(source->pushback) + + source->ignored; + r->length = isc_buffer_consumedlength(source->pushback) - + source->ignored; +} + + +char * +isc_lex_getsourcename(isc_lex_t *lex) { + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + + if (source == NULL) + return (NULL); + + return (source->name); +} + +unsigned long +isc_lex_getsourceline(isc_lex_t *lex) { + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + + if (source == NULL) + return (0); + + return (source->line); +} + + +isc_result_t +isc_lex_setsourcename(isc_lex_t *lex, const char *name) { + inputsource *source; + char *newname; + + REQUIRE(VALID_LEX(lex)); + source = HEAD(lex->sources); + + if (source == NULL) + return(ISC_R_NOTFOUND); + newname = isc_mem_strdup(lex->mctx, name); + if (newname == NULL) + return (ISC_R_NOMEMORY); + isc_mem_free(lex->mctx, source->name); + source->name = newname; + return (ISC_R_SUCCESS); +} + +isc_boolean_t +isc_lex_isfile(isc_lex_t *lex) { + inputsource *source; + + REQUIRE(VALID_LEX(lex)); + + source = HEAD(lex->sources); + + if (source == NULL) + return (ISC_FALSE); + + return (source->is_file); +} diff --git a/contrib/ntp/lib/isc/lfsr.c b/contrib/ntp/lib/isc/lfsr.c new file mode 100644 index 000000000..0b8d782ec --- /dev/null +++ b/contrib/ntp/lib/isc/lfsr.c @@ -0,0 +1,161 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: lfsr.c,v 1.20 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include + +#define VALID_LFSR(x) (x != NULL) + +void +isc_lfsr_init(isc_lfsr_t *lfsr, isc_uint32_t state, unsigned int bits, + isc_uint32_t tap, unsigned int count, + isc_lfsrreseed_t reseed, void *arg) +{ + REQUIRE(VALID_LFSR(lfsr)); + REQUIRE(8 <= bits && bits <= 32); + REQUIRE(tap != 0); + + lfsr->state = state; + lfsr->bits = bits; + lfsr->tap = tap; + lfsr->count = count; + lfsr->reseed = reseed; + lfsr->arg = arg; + + if (count == 0 && reseed != NULL) + reseed(lfsr, arg); + if (lfsr->state == 0) + lfsr->state = 0xffffffffU >> (32 - lfsr->bits); +} + +/*! + * Return the next state of the lfsr. + */ +static inline isc_uint32_t +lfsr_generate(isc_lfsr_t *lfsr) +{ + + /* + * If the previous state is zero, we must fill it with something + * here, or we will begin to generate an extremely predictable output. + * + * First, give the reseed function a crack at it. If the state is + * still 0, set it to all ones. + */ + if (lfsr->state == 0) { + if (lfsr->reseed != NULL) + lfsr->reseed(lfsr, lfsr->arg); + if (lfsr->state == 0) + lfsr->state = 0xffffffffU >> (32 - lfsr->bits); + } + + if (lfsr->state & 0x01) { + lfsr->state = (lfsr->state >> 1) ^ lfsr->tap; + return (1); + } else { + lfsr->state >>= 1; + return (0); + } +} + +void +isc_lfsr_generate(isc_lfsr_t *lfsr, void *data, unsigned int count) +{ + unsigned char *p; + unsigned int bit; + unsigned int byte; + + REQUIRE(VALID_LFSR(lfsr)); + REQUIRE(data != NULL); + REQUIRE(count > 0); + + p = data; + byte = count; + + while (byte--) { + *p = 0; + for (bit = 0; bit < 7; bit++) { + *p |= lfsr_generate(lfsr); + *p <<= 1; + } + *p |= lfsr_generate(lfsr); + p++; + } + + if (lfsr->count != 0 && lfsr->reseed != NULL) { + if (lfsr->count <= count * 8) + lfsr->reseed(lfsr, lfsr->arg); + else + lfsr->count -= (count * 8); + } +} + +static inline isc_uint32_t +lfsr_skipgenerate(isc_lfsr_t *lfsr, unsigned int skip) +{ + while (skip--) + (void)lfsr_generate(lfsr); + + (void)lfsr_generate(lfsr); + + return (lfsr->state); +} + +/* + * Skip "skip" states in "lfsr". + */ +void +isc_lfsr_skip(isc_lfsr_t *lfsr, unsigned int skip) +{ + REQUIRE(VALID_LFSR(lfsr)); + + while (skip--) + (void)lfsr_generate(lfsr); +} + +/* + * Skip states in lfsr1 and lfsr2 using the other's current state. + * Return the final state of lfsr1 ^ lfsr2. + */ +isc_uint32_t +isc_lfsr_generate32(isc_lfsr_t *lfsr1, isc_lfsr_t *lfsr2) +{ + isc_uint32_t state1, state2; + isc_uint32_t skip1, skip2; + + REQUIRE(VALID_LFSR(lfsr1)); + REQUIRE(VALID_LFSR(lfsr2)); + + skip1 = lfsr1->state & 0x01; + skip2 = lfsr2->state & 0x01; + + /* cross-skip. */ + state1 = lfsr_skipgenerate(lfsr1, skip2); + state2 = lfsr_skipgenerate(lfsr2, skip1); + + return (state1 ^ state2); +} diff --git a/contrib/ntp/libisc/lib.c b/contrib/ntp/lib/isc/lib.c similarity index 52% rename from contrib/ntp/libisc/lib.c rename to contrib/ntp/lib/isc/lib.c index 95dd47900..a50542551 100644 --- a/contrib/ntp/libisc/lib.c +++ b/contrib/ntp/lib/isc/lib.c @@ -1,30 +1,38 @@ /* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: lib.c,v 1.9 2001/11/19 03:08:23 mayer Exp $ */ +/* $Id: lib.c,v 1.16 2009/09/02 23:48:02 tbox Exp $ */ + +/*! \file */ #include #include #include -#include -#include +#include #include +#include +#include +#include +#include +#include +#include +#include /*** *** Globals @@ -39,7 +47,6 @@ LIBISC_EXTERNAL_DATA isc_msgcat_t * isc_msgcat = NULL; static isc_once_t msgcat_once = ISC_ONCE_INIT; - /*** *** Functions ***/ @@ -53,7 +60,7 @@ void isc_lib_initmsgcat(void) { isc_result_t result; - /* + /*! * Initialize the ISC library's message catalog, isc_msgcat, if it * has not already been initialized. */ @@ -75,3 +82,22 @@ isc_lib_initmsgcat(void) { abort(); } } + +#ifndef BIND9 +static isc_once_t register_once = ISC_ONCE_INIT; + +static void +do_register(void) { + RUNTIME_CHECK(isc__mem_register() == ISC_R_SUCCESS); + RUNTIME_CHECK(isc__app_register() == ISC_R_SUCCESS); + RUNTIME_CHECK(isc__task_register() == ISC_R_SUCCESS); + RUNTIME_CHECK(isc__socket_register() == ISC_R_SUCCESS); + RUNTIME_CHECK(isc__timer_register() == ISC_R_SUCCESS); +} + +void +isc_lib_register() { + RUNTIME_CHECK(isc_once_do(®ister_once, do_register) + == ISC_R_SUCCESS); +} +#endif diff --git a/contrib/ntp/lib/isc/log.c b/contrib/ntp/lib/isc/log.c new file mode 100644 index 000000000..38f0c4ff5 --- /dev/null +++ b/contrib/ntp/lib/isc/log.c @@ -0,0 +1,1767 @@ +/* + * Copyright (C) 2004-2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file + * \author Principal Authors: DCL */ + +#include + +#include +#include +#include +#include + +#include /* dev_t FreeBSD 2.1 */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include "ntp_stdlib.h" /* NTP change for strlcpy, strlcat */ + +#define LCTX_MAGIC ISC_MAGIC('L', 'c', 't', 'x') +#define VALID_CONTEXT(lctx) ISC_MAGIC_VALID(lctx, LCTX_MAGIC) + +#define LCFG_MAGIC ISC_MAGIC('L', 'c', 'f', 'g') +#define VALID_CONFIG(lcfg) ISC_MAGIC_VALID(lcfg, LCFG_MAGIC) + +/* + * XXXDCL make dynamic? + */ +#define LOG_BUFFER_SIZE (8 * 1024) + +#ifndef PATH_MAX +#define PATH_MAX 1024 /* AIX and others don't define this. */ +#endif + +/*! + * This is the structure that holds each named channel. A simple linked + * list chains all of the channels together, so an individual channel is + * found by doing strcmp()s with the names down the list. Their should + * be no performance penalty from this as it is expected that the number + * of named channels will be no more than a dozen or so, and name lookups + * from the head of the list are only done when isc_log_usechannel() is + * called, which should also be very infrequent. + */ +typedef struct isc_logchannel isc_logchannel_t; + +struct isc_logchannel { + char * name; + unsigned int type; + int level; + unsigned int flags; + isc_logdestination_t destination; + ISC_LINK(isc_logchannel_t) link; +}; + +/*! + * The logchannellist structure associates categories and modules with + * channels. First the appropriate channellist is found based on the + * category, and then each structure in the linked list is checked for + * a matching module. It is expected that the number of channels + * associated with any given category will be very short, no more than + * three or four in the more unusual cases. + */ +typedef struct isc_logchannellist isc_logchannellist_t; + +struct isc_logchannellist { + const isc_logmodule_t * module; + isc_logchannel_t * channel; + ISC_LINK(isc_logchannellist_t) link; +}; + +/*! + * This structure is used to remember messages for pruning via + * isc_log_[v]write1(). + */ +typedef struct isc_logmessage isc_logmessage_t; + +struct isc_logmessage { + char * text; + isc_time_t time; + ISC_LINK(isc_logmessage_t) link; +}; + +/*! + * The isc_logconfig structure is used to store the configurable information + * about where messages are actually supposed to be sent -- the information + * that could changed based on some configuration file, as opposed to the + * the category/module specification of isc_log_[v]write[1] that is compiled + * into a program, or the debug_level which is dynamic state information. + */ +struct isc_logconfig { + unsigned int magic; + isc_log_t * lctx; + ISC_LIST(isc_logchannel_t) channels; + ISC_LIST(isc_logchannellist_t) *channellists; + unsigned int channellist_count; + unsigned int duplicate_interval; + int highest_level; + char * tag; + isc_boolean_t dynamic; +}; + +/*! + * This isc_log structure provides the context for the isc_log functions. + * The log context locks itself in isc_log_doit, the internal backend to + * isc_log_write. The locking is necessary both to provide exclusive access + * to the buffer into which the message is formatted and to guard against + * competing threads trying to write to the same syslog resource. (On + * some systems, such as BSD/OS, stdio is thread safe but syslog is not.) + * Unfortunately, the lock cannot guard against a _different_ logging + * context in the same program competing for syslog's attention. Thus + * There Can Be Only One, but this is not enforced. + * XXXDCL enforce it? + * + * Note that the category and module information is not locked. + * This is because in the usual case, only one isc_log_t is ever created + * in a program, and the category/module registration happens only once. + * XXXDCL it might be wise to add more locking overall. + */ +struct isc_log { + /* Not locked. */ + unsigned int magic; + isc_mem_t * mctx; + isc_logcategory_t * categories; + unsigned int category_count; + isc_logmodule_t * modules; + unsigned int module_count; + int debug_level; + isc_mutex_t lock; + /* Locked by isc_log lock. */ + isc_logconfig_t * logconfig; + char buffer[LOG_BUFFER_SIZE]; + ISC_LIST(isc_logmessage_t) messages; +}; + +/*! + * Used when ISC_LOG_PRINTLEVEL is enabled for a channel. + */ +static const char *log_level_strings[] = { + "debug", + "info", + "notice", + "warning", + "error", + "critical" +}; + +/*! + * Used to convert ISC_LOG_* priorities into syslog priorities. + * XXXDCL This will need modification for NT. + */ +static const int syslog_map[] = { + LOG_DEBUG, + LOG_INFO, + LOG_NOTICE, + LOG_WARNING, + LOG_ERR, + LOG_CRIT +}; + +/*! + * When adding new categories, a corresponding ISC_LOGCATEGORY_foo + * definition needs to be added to . + * + * The default category is provided so that the internal default can + * be overridden. Since the default is always looked up as the first + * channellist in the log context, it must come first in isc_categories[]. + */ +LIBISC_EXTERNAL_DATA isc_logcategory_t isc_categories[] = { + { "default", 0 }, /* "default" must come first. */ + { "general", 0 }, + { NULL, 0 } +}; + +/*! + * See above comment for categories on LIBISC_EXTERNAL_DATA, and apply it to modules. + */ +LIBISC_EXTERNAL_DATA isc_logmodule_t isc_modules[] = { + { "socket", 0 }, + { "time", 0 }, + { "interface", 0 }, + { "timer", 0 }, + { "file", 0 }, + { NULL, 0 } +}; + +/*! + * This essentially constant structure must be filled in at run time, + * because its channel member is pointed to a channel that is created + * dynamically with isc_log_createchannel. + */ +static isc_logchannellist_t default_channel; + +/*! + * libisc logs to this context. + */ +LIBISC_EXTERNAL_DATA isc_log_t *isc_lctx = NULL; + +/*! + * Forward declarations. + */ +static isc_result_t +assignchannel(isc_logconfig_t *lcfg, unsigned int category_id, + const isc_logmodule_t *module, isc_logchannel_t *channel); + +static isc_result_t +sync_channellist(isc_logconfig_t *lcfg); + +static isc_result_t +greatest_version(isc_logchannel_t *channel, int *greatest); + +static isc_result_t +roll_log(isc_logchannel_t *channel); + +static void +isc_log_doit(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, isc_boolean_t write_once, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) + ISC_FORMAT_PRINTF(9, 0); + +/*@{*/ +/*! + * Convenience macros. + */ + +#define FACILITY(channel) (channel->destination.facility) +#define FILE_NAME(channel) (channel->destination.file.name) +#define FILE_STREAM(channel) (channel->destination.file.stream) +#define FILE_VERSIONS(channel) (channel->destination.file.versions) +#define FILE_MAXSIZE(channel) (channel->destination.file.maximum_size) +#define FILE_MAXREACHED(channel) (channel->destination.file.maximum_reached) + +/*@}*/ +/**** + **** Public interfaces. + ****/ + +/* + * Establish a new logging context, with default channels. + */ +isc_result_t +isc_log_create(isc_mem_t *mctx, isc_log_t **lctxp, isc_logconfig_t **lcfgp) { + isc_log_t *lctx; + isc_logconfig_t *lcfg = NULL; + isc_result_t result; + + REQUIRE(mctx != NULL); + REQUIRE(lctxp != NULL && *lctxp == NULL); + REQUIRE(lcfgp == NULL || *lcfgp == NULL); + + lctx = isc_mem_get(mctx, sizeof(*lctx)); + if (lctx != NULL) { + lctx->mctx = mctx; + lctx->categories = NULL; + lctx->category_count = 0; + lctx->modules = NULL; + lctx->module_count = 0; + lctx->debug_level = 0; + + ISC_LIST_INIT(lctx->messages); + + result = isc_mutex_init(&lctx->lock); + if (result != ISC_R_SUCCESS) { + isc_mem_put(mctx, lctx, sizeof(*lctx)); + return (result); + } + + /* + * Normally setting the magic number is the last step done + * in a creation function, but a valid log context is needed + * by isc_log_registercategories and isc_logconfig_create. + * If either fails, the lctx is destroyed and not returned + * to the caller. + */ + lctx->magic = LCTX_MAGIC; + + isc_log_registercategories(lctx, isc_categories); + isc_log_registermodules(lctx, isc_modules); + result = isc_logconfig_create(lctx, &lcfg); + + } else + result = ISC_R_NOMEMORY; + + if (result == ISC_R_SUCCESS) + result = sync_channellist(lcfg); + + if (result == ISC_R_SUCCESS) { + lctx->logconfig = lcfg; + + *lctxp = lctx; + if (lcfgp != NULL) + *lcfgp = lcfg; + + } else { + if (lcfg != NULL) + isc_logconfig_destroy(&lcfg); + if (lctx != NULL) + isc_log_destroy(&lctx); + } + + return (result); +} + +isc_result_t +isc_logconfig_create(isc_log_t *lctx, isc_logconfig_t **lcfgp) { + isc_logconfig_t *lcfg; + isc_logdestination_t destination; + isc_result_t result = ISC_R_SUCCESS; + int level = ISC_LOG_INFO; + + REQUIRE(lcfgp != NULL && *lcfgp == NULL); + REQUIRE(VALID_CONTEXT(lctx)); + + lcfg = isc_mem_get(lctx->mctx, sizeof(*lcfg)); + + if (lcfg != NULL) { + lcfg->lctx = lctx; + lcfg->channellists = NULL; + lcfg->channellist_count = 0; + lcfg->duplicate_interval = 0; + lcfg->highest_level = level; + lcfg->tag = NULL; + lcfg->dynamic = ISC_FALSE; + + ISC_LIST_INIT(lcfg->channels); + + /* + * Normally the magic number is the last thing set in the + * structure, but isc_log_createchannel() needs a valid + * config. If the channel creation fails, the lcfg is not + * returned to the caller. + */ + lcfg->magic = LCFG_MAGIC; + + } else + result = ISC_R_NOMEMORY; + + /* + * Create the default channels: + * default_syslog, default_stderr, default_debug and null. + */ + if (result == ISC_R_SUCCESS) { + destination.facility = LOG_DAEMON; + result = isc_log_createchannel(lcfg, "default_syslog", + ISC_LOG_TOSYSLOG, level, + &destination, 0); + } + + if (result == ISC_R_SUCCESS) { + destination.file.stream = stderr; + destination.file.name = NULL; + destination.file.versions = ISC_LOG_ROLLNEVER; + destination.file.maximum_size = 0; + result = isc_log_createchannel(lcfg, "default_stderr", + ISC_LOG_TOFILEDESC, + level, + &destination, + ISC_LOG_PRINTTIME); + } + + if (result == ISC_R_SUCCESS) { + /* + * Set the default category's channel to default_stderr, + * which is at the head of the channels list because it was + * just created. + */ + default_channel.channel = ISC_LIST_HEAD(lcfg->channels); + + destination.file.stream = stderr; + destination.file.name = NULL; + destination.file.versions = ISC_LOG_ROLLNEVER; + destination.file.maximum_size = 0; + result = isc_log_createchannel(lcfg, "default_debug", + ISC_LOG_TOFILEDESC, + ISC_LOG_DYNAMIC, + &destination, + ISC_LOG_PRINTTIME); + } + + if (result == ISC_R_SUCCESS) + result = isc_log_createchannel(lcfg, "null", + ISC_LOG_TONULL, + ISC_LOG_DYNAMIC, + NULL, 0); + + if (result == ISC_R_SUCCESS) + *lcfgp = lcfg; + + else + if (lcfg != NULL) + isc_logconfig_destroy(&lcfg); + + return (result); +} + +isc_logconfig_t * +isc_logconfig_get(isc_log_t *lctx) { + REQUIRE(VALID_CONTEXT(lctx)); + + ENSURE(lctx->logconfig != NULL); + + return (lctx->logconfig); +} + +isc_result_t +isc_logconfig_use(isc_log_t *lctx, isc_logconfig_t *lcfg) { + isc_logconfig_t *old_cfg; + isc_result_t result; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(VALID_CONFIG(lcfg)); + REQUIRE(lcfg->lctx == lctx); + + /* + * Ensure that lcfg->channellist_count == lctx->category_count. + * They won't be equal if isc_log_usechannel has not been called + * since any call to isc_log_registercategories. + */ + result = sync_channellist(lcfg); + if (result != ISC_R_SUCCESS) + return (result); + + LOCK(&lctx->lock); + + old_cfg = lctx->logconfig; + lctx->logconfig = lcfg; + + UNLOCK(&lctx->lock); + + isc_logconfig_destroy(&old_cfg); + + return (ISC_R_SUCCESS); +} + +void +isc_log_destroy(isc_log_t **lctxp) { + isc_log_t *lctx; + isc_logconfig_t *lcfg; + isc_mem_t *mctx; + isc_logmessage_t *message; + + REQUIRE(lctxp != NULL && VALID_CONTEXT(*lctxp)); + + lctx = *lctxp; + mctx = lctx->mctx; + + if (lctx->logconfig != NULL) { + lcfg = lctx->logconfig; + lctx->logconfig = NULL; + isc_logconfig_destroy(&lcfg); + } + + DESTROYLOCK(&lctx->lock); + + while ((message = ISC_LIST_HEAD(lctx->messages)) != NULL) { + ISC_LIST_UNLINK(lctx->messages, message, link); + + isc_mem_put(mctx, message, + sizeof(*message) + strlen(message->text) + 1); + } + + lctx->buffer[0] = '\0'; + lctx->debug_level = 0; + lctx->categories = NULL; + lctx->category_count = 0; + lctx->modules = NULL; + lctx->module_count = 0; + lctx->mctx = NULL; + lctx->magic = 0; + + isc_mem_put(mctx, lctx, sizeof(*lctx)); + + *lctxp = NULL; +} + +void +isc_logconfig_destroy(isc_logconfig_t **lcfgp) { + isc_logconfig_t *lcfg; + isc_mem_t *mctx; + isc_logchannel_t *channel; + isc_logchannellist_t *item; + char *filename; + unsigned int i; + + REQUIRE(lcfgp != NULL && VALID_CONFIG(*lcfgp)); + + lcfg = *lcfgp; + + /* + * This function cannot be called with a logconfig that is in + * use by a log context. + */ + REQUIRE(lcfg->lctx != NULL && lcfg->lctx->logconfig != lcfg); + + mctx = lcfg->lctx->mctx; + + while ((channel = ISC_LIST_HEAD(lcfg->channels)) != NULL) { + ISC_LIST_UNLINK(lcfg->channels, channel, link); + + if (channel->type == ISC_LOG_TOFILE) { + /* + * The filename for the channel may have ultimately + * started its life in user-land as a const string, + * but in isc_log_createchannel it gets copied + * into writable memory and is not longer truly const. + */ + DE_CONST(FILE_NAME(channel), filename); + isc_mem_free(mctx, filename); + + if (FILE_STREAM(channel) != NULL) + (void)fclose(FILE_STREAM(channel)); + } + + isc_mem_free(mctx, channel->name); + isc_mem_put(mctx, channel, sizeof(*channel)); + } + + for (i = 0; i < lcfg->channellist_count; i++) + while ((item = ISC_LIST_HEAD(lcfg->channellists[i])) != NULL) { + ISC_LIST_UNLINK(lcfg->channellists[i], item, link); + isc_mem_put(mctx, item, sizeof(*item)); + } + + if (lcfg->channellist_count > 0) + isc_mem_put(mctx, lcfg->channellists, + lcfg->channellist_count * + sizeof(ISC_LIST(isc_logchannellist_t))); + + lcfg->dynamic = ISC_FALSE; + if (lcfg->tag != NULL) + isc_mem_free(lcfg->lctx->mctx, lcfg->tag); + lcfg->tag = NULL; + lcfg->highest_level = 0; + lcfg->duplicate_interval = 0; + lcfg->magic = 0; + + isc_mem_put(mctx, lcfg, sizeof(*lcfg)); + + *lcfgp = NULL; +} + +void +isc_log_registercategories(isc_log_t *lctx, isc_logcategory_t categories[]) { + isc_logcategory_t *catp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(categories != NULL && categories[0].name != NULL); + + /* + * XXXDCL This somewhat sleazy situation of using the last pointer + * in one category array to point to the next array exists because + * this registration function returns void and I didn't want to have + * change everything that used it by making it return an isc_result_t. + * It would need to do that if it had to allocate memory to store + * pointers to each array passed in. + */ + if (lctx->categories == NULL) + lctx->categories = categories; + + else { + /* + * Adjust the last (NULL) pointer of the already registered + * categories to point to the incoming array. + */ + for (catp = lctx->categories; catp->name != NULL; ) + if (catp->id == UINT_MAX) + /* + * The name pointer points to the next array. + * Ick. + */ + DE_CONST(catp->name, catp); + else + catp++; + + catp->name = (void *)categories; + catp->id = UINT_MAX; + } + + /* + * Update the id number of the category with its new global id. + */ + for (catp = categories; catp->name != NULL; catp++) + catp->id = lctx->category_count++; +} + +isc_logcategory_t * +isc_log_categorybyname(isc_log_t *lctx, const char *name) { + isc_logcategory_t *catp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(name != NULL); + + for (catp = lctx->categories; catp->name != NULL; ) + if (catp->id == UINT_MAX) + /* + * catp is neither modified nor returned to the + * caller, so removing its const qualifier is ok. + */ + DE_CONST(catp->name, catp); + else { + if (strcmp(catp->name, name) == 0) + return (catp); + catp++; + } + + return (NULL); +} + +void +isc_log_registermodules(isc_log_t *lctx, isc_logmodule_t modules[]) { + isc_logmodule_t *modp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(modules != NULL && modules[0].name != NULL); + + /* + * XXXDCL This somewhat sleazy situation of using the last pointer + * in one category array to point to the next array exists because + * this registration function returns void and I didn't want to have + * change everything that used it by making it return an isc_result_t. + * It would need to do that if it had to allocate memory to store + * pointers to each array passed in. + */ + if (lctx->modules == NULL) + lctx->modules = modules; + + else { + /* + * Adjust the last (NULL) pointer of the already registered + * modules to point to the incoming array. + */ + for (modp = lctx->modules; modp->name != NULL; ) + if (modp->id == UINT_MAX) + /* + * The name pointer points to the next array. + * Ick. + */ + DE_CONST(modp->name, modp); + else + modp++; + + modp->name = (void *)modules; + modp->id = UINT_MAX; + } + + /* + * Update the id number of the module with its new global id. + */ + for (modp = modules; modp->name != NULL; modp++) + modp->id = lctx->module_count++; +} + +isc_logmodule_t * +isc_log_modulebyname(isc_log_t *lctx, const char *name) { + isc_logmodule_t *modp; + + REQUIRE(VALID_CONTEXT(lctx)); + REQUIRE(name != NULL); + + for (modp = lctx->modules; modp->name != NULL; ) + if (modp->id == UINT_MAX) + /* + * modp is neither modified nor returned to the + * caller, so removing its const qualifier is ok. + */ + DE_CONST(modp->name, modp); + else { + if (strcmp(modp->name, name) == 0) + return (modp); + modp++; + } + + return (NULL); +} + +isc_result_t +isc_log_createchannel(isc_logconfig_t *lcfg, const char *name, + unsigned int type, int level, + const isc_logdestination_t *destination, + unsigned int flags) +{ + isc_logchannel_t *channel; + isc_mem_t *mctx; + + REQUIRE(VALID_CONFIG(lcfg)); + REQUIRE(name != NULL); + REQUIRE(type == ISC_LOG_TOSYSLOG || type == ISC_LOG_TOFILE || + type == ISC_LOG_TOFILEDESC || type == ISC_LOG_TONULL); + REQUIRE(destination != NULL || type == ISC_LOG_TONULL); + REQUIRE(level >= ISC_LOG_CRITICAL); + REQUIRE((flags & + (unsigned int)~(ISC_LOG_PRINTALL | ISC_LOG_DEBUGONLY)) == 0); + + /* XXXDCL find duplicate names? */ + + mctx = lcfg->lctx->mctx; + + channel = isc_mem_get(mctx, sizeof(*channel)); + if (channel == NULL) + return (ISC_R_NOMEMORY); + + channel->name = isc_mem_strdup(mctx, name); + if (channel->name == NULL) { + isc_mem_put(mctx, channel, sizeof(*channel)); + return (ISC_R_NOMEMORY); + } + + channel->type = type; + channel->level = level; + channel->flags = flags; + ISC_LINK_INIT(channel, link); + + switch (type) { + case ISC_LOG_TOSYSLOG: + FACILITY(channel) = destination->facility; + break; + + case ISC_LOG_TOFILE: + /* + * The file name is copied because greatest_version wants + * to scribble on it, so it needs to be definitely in + * writable memory. + */ + FILE_NAME(channel) = + isc_mem_strdup(mctx, destination->file.name); + FILE_STREAM(channel) = NULL; + FILE_VERSIONS(channel) = destination->file.versions; + FILE_MAXSIZE(channel) = destination->file.maximum_size; + FILE_MAXREACHED(channel) = ISC_FALSE; + break; + + case ISC_LOG_TOFILEDESC: + FILE_NAME(channel) = NULL; + FILE_STREAM(channel) = destination->file.stream; + FILE_MAXSIZE(channel) = 0; + FILE_VERSIONS(channel) = ISC_LOG_ROLLNEVER; + break; + + case ISC_LOG_TONULL: + /* Nothing. */ + break; + + default: + isc_mem_put(mctx, channel->name, strlen(channel->name) + 1); + isc_mem_put(mctx, channel, sizeof(*channel)); + return (ISC_R_UNEXPECTED); + } + + ISC_LIST_PREPEND(lcfg->channels, channel, link); + + /* + * If default_stderr was redefined, make the default category + * point to the new default_stderr. + */ + if (strcmp(name, "default_stderr") == 0) + default_channel.channel = channel; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_log_usechannel(isc_logconfig_t *lcfg, const char *name, + const isc_logcategory_t *category, + const isc_logmodule_t *module) +{ + isc_log_t *lctx; + isc_logchannel_t *channel; + isc_result_t result = ISC_R_SUCCESS; + unsigned int i; + + REQUIRE(VALID_CONFIG(lcfg)); + REQUIRE(name != NULL); + + lctx = lcfg->lctx; + + REQUIRE(category == NULL || category->id < lctx->category_count); + REQUIRE(module == NULL || module->id < lctx->module_count); + + for (channel = ISC_LIST_HEAD(lcfg->channels); channel != NULL; + channel = ISC_LIST_NEXT(channel, link)) + if (strcmp(name, channel->name) == 0) + break; + + if (channel == NULL) + return (ISC_R_NOTFOUND); + + if (category != NULL) + result = assignchannel(lcfg, category->id, module, channel); + + else + /* + * Assign to all categories. Note that this includes + * the default channel. + */ + for (i = 0; i < lctx->category_count; i++) { + result = assignchannel(lcfg, i, module, channel); + if (result != ISC_R_SUCCESS) + break; + } + + return (result); +} + +void +isc_log_write(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_FALSE, + NULL, 0, 0, format, args); + va_end(args); +} + +void +isc_log_vwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_FALSE, + NULL, 0, 0, format, args); +} + +void +isc_log_write1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_TRUE, + NULL, 0, 0, format, args); + va_end(args); +} + +void +isc_log_vwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_TRUE, + NULL, 0, 0, format, args); +} + +void +isc_log_iwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_FALSE, + msgcat, msgset, msg, format, args); + va_end(args); +} + +void +isc_log_ivwrite(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_FALSE, + msgcat, msgset, msg, format, args); +} + +void +isc_log_iwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, ...) +{ + va_list args; + + /* + * Contract checking is done in isc_log_doit(). + */ + + va_start(args, format); + isc_log_doit(lctx, category, module, level, ISC_TRUE, + msgcat, msgset, msg, format, args); + va_end(args); +} + +void +isc_log_ivwrite1(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) +{ + /* + * Contract checking is done in isc_log_doit(). + */ + isc_log_doit(lctx, category, module, level, ISC_TRUE, + msgcat, msgset, msg, format, args); +} + +void +isc_log_setcontext(isc_log_t *lctx) { + isc_lctx = lctx; +} + +void +isc_log_setdebuglevel(isc_log_t *lctx, unsigned int level) { + isc_logchannel_t *channel; + + REQUIRE(VALID_CONTEXT(lctx)); + + LOCK(&lctx->lock); + + lctx->debug_level = level; + /* + * Close ISC_LOG_DEBUGONLY channels if level is zero. + */ + if (lctx->debug_level == 0) + for (channel = ISC_LIST_HEAD(lctx->logconfig->channels); + channel != NULL; + channel = ISC_LIST_NEXT(channel, link)) + if (channel->type == ISC_LOG_TOFILE && + (channel->flags & ISC_LOG_DEBUGONLY) != 0 && + FILE_STREAM(channel) != NULL) { + (void)fclose(FILE_STREAM(channel)); + FILE_STREAM(channel) = NULL; + } + UNLOCK(&lctx->lock); +} + +unsigned int +isc_log_getdebuglevel(isc_log_t *lctx) { + REQUIRE(VALID_CONTEXT(lctx)); + + return (lctx->debug_level); +} + +void +isc_log_setduplicateinterval(isc_logconfig_t *lcfg, unsigned int interval) { + REQUIRE(VALID_CONFIG(lcfg)); + + lcfg->duplicate_interval = interval; +} + +unsigned int +isc_log_getduplicateinterval(isc_logconfig_t *lcfg) { + REQUIRE(VALID_CONTEXT(lcfg)); + + return (lcfg->duplicate_interval); +} + +isc_result_t +isc_log_settag(isc_logconfig_t *lcfg, const char *tag) { + REQUIRE(VALID_CONFIG(lcfg)); + + if (tag != NULL && *tag != '\0') { + if (lcfg->tag != NULL) + isc_mem_free(lcfg->lctx->mctx, lcfg->tag); + lcfg->tag = isc_mem_strdup(lcfg->lctx->mctx, tag); + if (lcfg->tag == NULL) + return (ISC_R_NOMEMORY); + + } else { + if (lcfg->tag != NULL) + isc_mem_free(lcfg->lctx->mctx, lcfg->tag); + lcfg->tag = NULL; + } + + return (ISC_R_SUCCESS); +} + +char * +isc_log_gettag(isc_logconfig_t *lcfg) { + REQUIRE(VALID_CONFIG(lcfg)); + + return (lcfg->tag); +} + +/* XXXDCL NT -- This interface will assuredly be changing. */ +void +isc_log_opensyslog(const char *tag, int options, int facility) { + (void)openlog(tag, options, facility); +} + +void +isc_log_closefilelogs(isc_log_t *lctx) { + isc_logchannel_t *channel; + + REQUIRE(VALID_CONTEXT(lctx)); + + LOCK(&lctx->lock); + for (channel = ISC_LIST_HEAD(lctx->logconfig->channels); + channel != NULL; + channel = ISC_LIST_NEXT(channel, link)) + + if (channel->type == ISC_LOG_TOFILE && + FILE_STREAM(channel) != NULL) { + (void)fclose(FILE_STREAM(channel)); + FILE_STREAM(channel) = NULL; + } + UNLOCK(&lctx->lock); +} + +/**** + **** Internal functions + ****/ + +static isc_result_t +assignchannel(isc_logconfig_t *lcfg, unsigned int category_id, + const isc_logmodule_t *module, isc_logchannel_t *channel) +{ + isc_logchannellist_t *new_item; + isc_log_t *lctx; + isc_result_t result; + + REQUIRE(VALID_CONFIG(lcfg)); + + lctx = lcfg->lctx; + + REQUIRE(category_id < lctx->category_count); + REQUIRE(module == NULL || module->id < lctx->module_count); + REQUIRE(channel != NULL); + + /* + * Ensure lcfg->channellist_count == lctx->category_count. + */ + result = sync_channellist(lcfg); + if (result != ISC_R_SUCCESS) + return (result); + + new_item = isc_mem_get(lctx->mctx, sizeof(*new_item)); + if (new_item == NULL) + return (ISC_R_NOMEMORY); + + new_item->channel = channel; + new_item->module = module; + ISC_LIST_INITANDPREPEND(lcfg->channellists[category_id], + new_item, link); + + /* + * Remember the highest logging level set by any channel in the + * logging config, so isc_log_doit() can quickly return if the + * message is too high to be logged by any channel. + */ + if (channel->type != ISC_LOG_TONULL) { + if (lcfg->highest_level < channel->level) + lcfg->highest_level = channel->level; + if (channel->level == ISC_LOG_DYNAMIC) + lcfg->dynamic = ISC_TRUE; + } + + return (ISC_R_SUCCESS); +} + +/* + * This would ideally be part of isc_log_registercategories(), except then + * that function would have to return isc_result_t instead of void. + */ +static isc_result_t +sync_channellist(isc_logconfig_t *lcfg) { + unsigned int bytes; + isc_log_t *lctx; + void *lists; + + REQUIRE(VALID_CONFIG(lcfg)); + + lctx = lcfg->lctx; + + REQUIRE(lctx->category_count != 0); + + if (lctx->category_count == lcfg->channellist_count) + return (ISC_R_SUCCESS); + + bytes = lctx->category_count * sizeof(ISC_LIST(isc_logchannellist_t)); + + lists = isc_mem_get(lctx->mctx, bytes); + + if (lists == NULL) + return (ISC_R_NOMEMORY); + + memset(lists, 0, bytes); + + if (lcfg->channellist_count != 0) { + bytes = lcfg->channellist_count * + sizeof(ISC_LIST(isc_logchannellist_t)); + memcpy(lists, lcfg->channellists, bytes); + isc_mem_put(lctx->mctx, lcfg->channellists, bytes); + } + + lcfg->channellists = lists; + lcfg->channellist_count = lctx->category_count; + + return (ISC_R_SUCCESS); +} + +static isc_result_t +greatest_version(isc_logchannel_t *channel, int *greatestp) { + /* XXXDCL HIGHLY NT */ + char *basenam, *digit_end; + const char *dirname; + int version, greatest = -1; + unsigned int basenamelen; + isc_dir_t dir; + isc_result_t result; + char sep = '/'; +#ifdef _WIN32 + char *basename2; +#endif + + REQUIRE(channel->type == ISC_LOG_TOFILE); + + /* + * It is safe to DE_CONST the file.name because it was copied + * with isc_mem_strdup in isc_log_createchannel. + */ + basenam = strrchr(FILE_NAME(channel), sep); +#ifdef _WIN32 + basename2 = strrchr(FILE_NAME(channel), '\\'); + if ((basenam != NULL && basename2 != NULL && basename2 > basenam) || + (basenam == NULL && basename2 != NULL)) { + basenam = basename2; + sep = '\\'; + } +#endif + if (basenam != NULL) { + *basenam++ = '\0'; + dirname = FILE_NAME(channel); + } else { + DE_CONST(FILE_NAME(channel), basenam); + dirname = "."; + } + basenamelen = strlen(basenam); + + isc_dir_init(&dir); + result = isc_dir_open(&dir, dirname); + + /* + * Replace the file separator if it was taken out. + */ + if (basenam != FILE_NAME(channel)) + *(basenam - 1) = sep; + + /* + * Return if the directory open failed. + */ + if (result != ISC_R_SUCCESS) + return (result); + + while (isc_dir_read(&dir) == ISC_R_SUCCESS) { + if (dir.entry.length > basenamelen && + strncmp(dir.entry.name, basenam, basenamelen) == 0 && + dir.entry.name[basenamelen] == '.') { + + version = strtol(&dir.entry.name[basenamelen + 1], + &digit_end, 10); + if (*digit_end == '\0' && version > greatest) + greatest = version; + } + } + isc_dir_close(&dir); + + *greatestp = ++greatest; + + return (ISC_R_SUCCESS); +} + +static isc_result_t +roll_log(isc_logchannel_t *channel) { + int i, n, greatest; + char current[PATH_MAX + 1]; + char new[PATH_MAX + 1]; + const char *path; + isc_result_t result; + + /* + * Do nothing (not even excess version trimming) if ISC_LOG_ROLLNEVER + * is specified. Apparently complete external control over the log + * files is desired. + */ + if (FILE_VERSIONS(channel) == ISC_LOG_ROLLNEVER) + return (ISC_R_SUCCESS); + + path = FILE_NAME(channel); + + /* + * Set greatest_version to the greatest existing version + * (not the maximum requested version). This is 1 based even + * though the file names are 0 based, so an oldest log of log.1 + * is a greatest_version of 2. + */ + result = greatest_version(channel, &greatest); + if (result != ISC_R_SUCCESS) + return (result); + + /* + * Now greatest should be set to the highest version number desired. + * Since the highest number is one less than FILE_VERSIONS(channel) + * when not doing infinite log rolling, greatest will need to be + * decremented when it is equal to -- or greater than -- + * FILE_VERSIONS(channel). When greatest is less than + * FILE_VERSIONS(channel), it is already suitable for use as + * the maximum version number. + */ + + if (FILE_VERSIONS(channel) == ISC_LOG_ROLLINFINITE || + FILE_VERSIONS(channel) > greatest) + ; /* Do nothing. */ + else + /* + * When greatest is >= FILE_VERSIONS(channel), it needs to + * be reduced until it is FILE_VERSIONS(channel) - 1. + * Remove any excess logs on the way to that value. + */ + while (--greatest >= FILE_VERSIONS(channel)) { + n = snprintf(current, sizeof(current), "%s.%d", + path, greatest); + if (n >= (int)sizeof(current) || n < 0) + result = ISC_R_NOSPACE; + else + result = isc_file_remove(current); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, + "unable to remove log file '%s.%d': %s", + path, greatest, + isc_result_totext(result)); + } + + for (i = greatest; i > 0; i--) { + result = ISC_R_SUCCESS; + n = snprintf(current, sizeof(current), "%s.%d", path, i - 1); + if (n >= (int)sizeof(current) || n < 0) + result = ISC_R_NOSPACE; + if (result == ISC_R_SUCCESS) { + n = snprintf(new, sizeof(new), "%s.%d", path, i); + if (n >= (int)sizeof(new) || n < 0) + result = ISC_R_NOSPACE; + } + if (result == ISC_R_SUCCESS) + result = isc_file_rename(current, new); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, + "unable to rename log file '%s.%d' to " + "'%s.%d': %s", path, i - 1, path, i, + isc_result_totext(result)); + } + + if (FILE_VERSIONS(channel) != 0) { + n = snprintf(new, sizeof(new), "%s.0", path); + if (n >= (int)sizeof(new) || n < 0) + result = ISC_R_NOSPACE; + else + result = isc_file_rename(path, new); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, + "unable to rename log file '%s' to '%s.0': %s", + path, path, isc_result_totext(result)); + } else { + result = isc_file_remove(path); + if (result != ISC_R_SUCCESS && + result != ISC_R_FILENOTFOUND) + syslog(LOG_ERR, "unable to remove log file '%s': %s", + path, isc_result_totext(result)); + } + + return (ISC_R_SUCCESS); +} + +static isc_result_t +isc_log_open(isc_logchannel_t *channel) { + struct stat statbuf; + isc_boolean_t regular_file; + isc_boolean_t roll = ISC_FALSE; + isc_result_t result = ISC_R_SUCCESS; + const char *path; + + REQUIRE(channel->type == ISC_LOG_TOFILE); + REQUIRE(FILE_STREAM(channel) == NULL); + + path = FILE_NAME(channel); + + REQUIRE(path != NULL && *path != '\0'); + + /* + * Determine type of file; only regular files will be + * version renamed, and only if the base file exists + * and either has no size limit or has reached its size limit. + */ + if (stat(path, &statbuf) == 0) { + regular_file = S_ISREG(statbuf.st_mode) ? ISC_TRUE : ISC_FALSE; + /* XXXDCL if not regular_file complain? */ + if ((FILE_MAXSIZE(channel) == 0 && + FILE_VERSIONS(channel) != ISC_LOG_ROLLNEVER) || + (FILE_MAXSIZE(channel) > 0 && + statbuf.st_size >= FILE_MAXSIZE(channel))) + roll = regular_file; + } else if (errno == ENOENT) { + regular_file = ISC_TRUE; + POST(regular_file); + } else + result = ISC_R_INVALIDFILE; + + /* + * Version control. + */ + if (result == ISC_R_SUCCESS && roll) { + if (FILE_VERSIONS(channel) == ISC_LOG_ROLLNEVER) + return (ISC_R_MAXSIZE); + result = roll_log(channel); + if (result != ISC_R_SUCCESS) { + if ((channel->flags & ISC_LOG_OPENERR) == 0) { + syslog(LOG_ERR, + "isc_log_open: roll_log '%s' " + "failed: %s", + FILE_NAME(channel), + isc_result_totext(result)); + channel->flags |= ISC_LOG_OPENERR; + } + return (result); + } + } + + result = isc_stdio_open(path, "a", &FILE_STREAM(channel)); + + return (result); +} + +isc_boolean_t +isc_log_wouldlog(isc_log_t *lctx, int level) { + /* + * Try to avoid locking the mutex for messages which can't + * possibly be logged to any channels -- primarily debugging + * messages that the debug level is not high enough to print. + * + * If the level is (mathematically) less than or equal to the + * highest_level, or if there is a dynamic channel and the level is + * less than or equal to the debug level, the main loop must be + * entered to see if the message should really be output. + * + * NOTE: this is UNLOCKED access to the logconfig. However, + * the worst thing that can happen is that a bad decision is made + * about returning without logging, and that's not a big concern, + * because that's a risk anyway if the logconfig is being + * dynamically changed. + */ + + if (lctx == NULL || lctx->logconfig == NULL) + return (ISC_FALSE); + + return (ISC_TF(level <= lctx->logconfig->highest_level || + (lctx->logconfig->dynamic && + level <= lctx->debug_level))); +} + +static void +isc_log_doit(isc_log_t *lctx, isc_logcategory_t *category, + isc_logmodule_t *module, int level, isc_boolean_t write_once, + isc_msgcat_t *msgcat, int msgset, int msg, + const char *format, va_list args) +{ + int syslog_level; + char time_string[64]; + char level_string[24]; + size_t octets; + const char *iformat; + struct stat statbuf; + isc_boolean_t matched = ISC_FALSE; + isc_boolean_t printtime, printtag; + isc_boolean_t printcategory, printmodule, printlevel; + isc_logconfig_t *lcfg; + isc_logchannel_t *channel; + isc_logchannellist_t *category_channels; + isc_result_t result; + + REQUIRE(lctx == NULL || VALID_CONTEXT(lctx)); + REQUIRE(category != NULL); + REQUIRE(module != NULL); + REQUIRE(level != ISC_LOG_DYNAMIC); + REQUIRE(format != NULL); + + /* + * Programs can use libraries that use this logging code without + * wanting to do any logging, thus the log context is allowed to + * be non-existent. + */ + if (lctx == NULL) + return; + + REQUIRE(category->id < lctx->category_count); + REQUIRE(module->id < lctx->module_count); + + if (! isc_log_wouldlog(lctx, level)) + return; + + if (msgcat != NULL) + iformat = isc_msgcat_get(msgcat, msgset, msg, format); + else + iformat = format; + + time_string[0] = '\0'; + level_string[0] = '\0'; + + LOCK(&lctx->lock); + + lctx->buffer[0] = '\0'; + + lcfg = lctx->logconfig; + + category_channels = ISC_LIST_HEAD(lcfg->channellists[category->id]); + + /* + * XXXDCL add duplicate filtering? (To not write multiple times to + * the same source via various channels). + */ + do { + /* + * If the channel list end was reached and a match was made, + * everything is finished. + */ + if (category_channels == NULL && matched) + break; + + if (category_channels == NULL && ! matched && + category_channels != ISC_LIST_HEAD(lcfg->channellists[0])) + /* + * No category/module pair was explicitly configured. + * Try the category named "default". + */ + category_channels = + ISC_LIST_HEAD(lcfg->channellists[0]); + + if (category_channels == NULL && ! matched) + /* + * No matching module was explicitly configured + * for the category named "default". Use the internal + * default channel. + */ + category_channels = &default_channel; + + if (category_channels->module != NULL && + category_channels->module != module) { + category_channels = ISC_LIST_NEXT(category_channels, + link); + continue; + } + + matched = ISC_TRUE; + + channel = category_channels->channel; + category_channels = ISC_LIST_NEXT(category_channels, link); + + if (((channel->flags & ISC_LOG_DEBUGONLY) != 0) && + lctx->debug_level == 0) + continue; + + if (channel->level == ISC_LOG_DYNAMIC) { + if (lctx->debug_level < level) + continue; + } else if (channel->level < level) + continue; + + if ((channel->flags & ISC_LOG_PRINTTIME) != 0 && + time_string[0] == '\0') { + isc_time_t isctime; + + TIME_NOW(&isctime); + isc_time_formattimestamp(&isctime, time_string, + sizeof(time_string)); + } + + if ((channel->flags & ISC_LOG_PRINTLEVEL) != 0 && + level_string[0] == '\0') { + if (level < ISC_LOG_CRITICAL) + snprintf(level_string, sizeof(level_string), + "%s %d: ", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_LOG, + ISC_MSG_LEVEL, + "level"), + level); + else if (level > ISC_LOG_DYNAMIC) + snprintf(level_string, sizeof(level_string), + "%s %d: ", log_level_strings[0], + level); + else + snprintf(level_string, sizeof(level_string), + "%s: ", log_level_strings[-level]); + } + + /* + * Only format the message once. + */ + if (lctx->buffer[0] == '\0') { + (void)vsnprintf(lctx->buffer, sizeof(lctx->buffer), + iformat, args); + + /* + * Check for duplicates. + */ + if (write_once) { + isc_logmessage_t *message, *new; + isc_time_t oldest; + isc_interval_t interval; + + isc_interval_set(&interval, + lcfg->duplicate_interval, 0); + + /* + * 'oldest' is the age of the oldest messages + * which fall within the duplicate_interval + * range. + */ + TIME_NOW(&oldest); + if (isc_time_subtract(&oldest, &interval, &oldest) + != ISC_R_SUCCESS) + /* + * Can't effectively do the checking + * without having a valid time. + */ + message = NULL; + else + message =ISC_LIST_HEAD(lctx->messages); + + while (message != NULL) { + if (isc_time_compare(&message->time, + &oldest) < 0) { + /* + * This message is older + * than the duplicate_interval, + * so it should be dropped from + * the history. + * + * Setting the interval to be + * to be longer will obviously + * not cause the expired + * message to spring back into + * existence. + */ + new = ISC_LIST_NEXT(message, + link); + + ISC_LIST_UNLINK(lctx->messages, + message, link); + + isc_mem_put(lctx->mctx, + message, + sizeof(*message) + 1 + + strlen(message->text)); + + message = new; + continue; + } + + /* + * This message is in the duplicate + * filtering interval ... + */ + if (strcmp(lctx->buffer, message->text) + == 0) { + /* + * ... and it is a duplicate. + * Unlock the mutex and + * get the hell out of Dodge. + */ + UNLOCK(&lctx->lock); + return; + } + + message = ISC_LIST_NEXT(message, link); + } + + /* + * It wasn't in the duplicate interval, + * so add it to the message list. + */ + octets = strlen(lctx->buffer) + 1; + new = isc_mem_get(lctx->mctx, + sizeof(isc_logmessage_t) + + octets); + if (new != NULL) { + /* + * Put the text immediately after + * the struct. The strcpy is safe. + */ + new->text = (char *)(new + 1); + strlcpy(new->text, lctx->buffer, octets); + + TIME_NOW(&new->time); + + ISC_LIST_APPEND(lctx->messages, + new, link); + } + } + } + + printtime = ISC_TF((channel->flags & ISC_LOG_PRINTTIME) + != 0); + printtag = ISC_TF((channel->flags & ISC_LOG_PRINTTAG) + != 0 && lcfg->tag != NULL); + printcategory = ISC_TF((channel->flags & ISC_LOG_PRINTCATEGORY) + != 0); + printmodule = ISC_TF((channel->flags & ISC_LOG_PRINTMODULE) + != 0); + printlevel = ISC_TF((channel->flags & ISC_LOG_PRINTLEVEL) + != 0); + + switch (channel->type) { + case ISC_LOG_TOFILE: + if (FILE_MAXREACHED(channel)) { + /* + * If the file can be rolled, OR + * If the file no longer exists, OR + * If the file is less than the maximum size, + * (such as if it had been renamed and + * a new one touched, or it was truncated + * in place) + * ... then close it to trigger reopening. + */ + if (FILE_VERSIONS(channel) != + ISC_LOG_ROLLNEVER || + (stat(FILE_NAME(channel), &statbuf) != 0 && + errno == ENOENT) || + statbuf.st_size < FILE_MAXSIZE(channel)) { + (void)fclose(FILE_STREAM(channel)); + FILE_STREAM(channel) = NULL; + FILE_MAXREACHED(channel) = ISC_FALSE; + } else + /* + * Eh, skip it. + */ + break; + } + + if (FILE_STREAM(channel) == NULL) { + result = isc_log_open(channel); + if (result != ISC_R_SUCCESS && + result != ISC_R_MAXSIZE && + (channel->flags & ISC_LOG_OPENERR) == 0) { + syslog(LOG_ERR, + "isc_log_open '%s' failed: %s", + FILE_NAME(channel), + isc_result_totext(result)); + channel->flags |= ISC_LOG_OPENERR; + } + if (result != ISC_R_SUCCESS) + break; + channel->flags &= ~ISC_LOG_OPENERR; + } + /* FALLTHROUGH */ + + case ISC_LOG_TOFILEDESC: + fprintf(FILE_STREAM(channel), "%s%s%s%s%s%s%s%s%s%s\n", + printtime ? time_string : "", + printtime ? " " : "", + printtag ? lcfg->tag : "", + printtag ? ": " : "", + printcategory ? category->name : "", + printcategory ? ": " : "", + printmodule ? (module != NULL ? module->name + : "no_module") + : "", + printmodule ? ": " : "", + printlevel ? level_string : "", + lctx->buffer); + + fflush(FILE_STREAM(channel)); + + /* + * If the file now exceeds its maximum size + * threshold, note it so that it will not be logged + * to any more. + */ + if (FILE_MAXSIZE(channel) > 0) { + INSIST(channel->type == ISC_LOG_TOFILE); + + /* XXXDCL NT fstat/fileno */ + /* XXXDCL complain if fstat fails? */ + if (fstat(fileno(FILE_STREAM(channel)), + &statbuf) >= 0 && + statbuf.st_size > FILE_MAXSIZE(channel)) + FILE_MAXREACHED(channel) = ISC_TRUE; + } + + break; + + case ISC_LOG_TOSYSLOG: + if (level > 0) + syslog_level = LOG_DEBUG; + else if (level < ISC_LOG_CRITICAL) + syslog_level = LOG_CRIT; + else + syslog_level = syslog_map[-level]; + + (void)syslog(FACILITY(channel) | syslog_level, + "%s%s%s%s%s%s%s%s%s%s", + printtime ? time_string : "", + printtime ? " " : "", + printtag ? lcfg->tag : "", + printtag ? ": " : "", + printcategory ? category->name : "", + printcategory ? ": " : "", + printmodule ? (module != NULL ? module->name + : "no_module") + : "", + printmodule ? ": " : "", + printlevel ? level_string : "", + lctx->buffer); + break; + + case ISC_LOG_TONULL: + break; + + } + + } while (1); + + UNLOCK(&lctx->lock); +} diff --git a/contrib/ntp/lib/isc/md5.c b/contrib/ntp/lib/isc/md5.c new file mode 100644 index 000000000..7c6419b2a --- /dev/null +++ b/contrib/ntp/lib/isc/md5.c @@ -0,0 +1,277 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: md5.c,v 1.16 2009/02/06 23:47:42 tbox Exp $ */ + +/*! \file + * This code implements the MD5 message-digest algorithm. + * The algorithm is due to Ron Rivest. This code was + * written by Colin Plumb in 1993, no copyright is claimed. + * This code is in the public domain; do with it what you wish. + * + * Equivalent code is available from RSA Data Security, Inc. + * This code has been tested against that, and is equivalent, + * except that you don't need to include two pages of legalese + * with every copy. + * + * To compute the message digest of a chunk of bytes, declare an + * MD5Context structure, pass it to MD5Init, call MD5Update as + * needed on buffers full of bytes, and then call MD5Final, which + * will fill a supplied 16-byte array with the digest. + */ + +#include "config.h" + +#include +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_OPENSSLHASH + +void +isc_md5_init(isc_md5_t *ctx) { + EVP_DigestInit(ctx, EVP_md5()); +} + +void +isc_md5_invalidate(isc_md5_t *ctx) { + EVP_MD_CTX_cleanup(ctx); +} + +void +isc_md5_update(isc_md5_t *ctx, const unsigned char *buf, unsigned int len) { + EVP_DigestUpdate(ctx, (const void *) buf, (size_t) len); +} + +void +isc_md5_final(isc_md5_t *ctx, unsigned char *digest) { + EVP_DigestFinal(ctx, digest, NULL); +} + +#else + +static void +byteSwap(isc_uint32_t *buf, unsigned words) +{ + unsigned char *p = (unsigned char *)buf; + + do { + *buf++ = (isc_uint32_t)((unsigned)p[3] << 8 | p[2]) << 16 | + ((unsigned)p[1] << 8 | p[0]); + p += 4; + } while (--words); +} + +/*! + * Start MD5 accumulation. Set bit count to 0 and buffer to mysterious + * initialization constants. + */ +void +isc_md5_init(isc_md5_t *ctx) { + ctx->buf[0] = 0x67452301; + ctx->buf[1] = 0xefcdab89; + ctx->buf[2] = 0x98badcfe; + ctx->buf[3] = 0x10325476; + + ctx->bytes[0] = 0; + ctx->bytes[1] = 0; +} + +void +isc_md5_invalidate(isc_md5_t *ctx) { + memset(ctx, 0, sizeof(isc_md5_t)); +} + +/*@{*/ +/*! The four core functions - F1 is optimized somewhat */ + +/* #define F1(x, y, z) (x & y | ~x & z) */ +#define F1(x, y, z) (z ^ (x & (y ^ z))) +#define F2(x, y, z) F1(z, x, y) +#define F3(x, y, z) (x ^ y ^ z) +#define F4(x, y, z) (y ^ (x | ~z)) +/*@}*/ + +/*! This is the central step in the MD5 algorithm. */ +#define MD5STEP(f,w,x,y,z,in,s) \ + (w += f(x,y,z) + in, w = (w<>(32-s)) + x) + +/*! + * The core of the MD5 algorithm, this alters an existing MD5 hash to + * reflect the addition of 16 longwords of new data. MD5Update blocks + * the data and converts bytes into longwords for this routine. + */ +static void +transform(isc_uint32_t buf[4], isc_uint32_t const in[16]) { + register isc_uint32_t a, b, c, d; + + a = buf[0]; + b = buf[1]; + c = buf[2]; + d = buf[3]; + + MD5STEP(F1, a, b, c, d, in[0] + 0xd76aa478, 7); + MD5STEP(F1, d, a, b, c, in[1] + 0xe8c7b756, 12); + MD5STEP(F1, c, d, a, b, in[2] + 0x242070db, 17); + MD5STEP(F1, b, c, d, a, in[3] + 0xc1bdceee, 22); + MD5STEP(F1, a, b, c, d, in[4] + 0xf57c0faf, 7); + MD5STEP(F1, d, a, b, c, in[5] + 0x4787c62a, 12); + MD5STEP(F1, c, d, a, b, in[6] + 0xa8304613, 17); + MD5STEP(F1, b, c, d, a, in[7] + 0xfd469501, 22); + MD5STEP(F1, a, b, c, d, in[8] + 0x698098d8, 7); + MD5STEP(F1, d, a, b, c, in[9] + 0x8b44f7af, 12); + MD5STEP(F1, c, d, a, b, in[10] + 0xffff5bb1, 17); + MD5STEP(F1, b, c, d, a, in[11] + 0x895cd7be, 22); + MD5STEP(F1, a, b, c, d, in[12] + 0x6b901122, 7); + MD5STEP(F1, d, a, b, c, in[13] + 0xfd987193, 12); + MD5STEP(F1, c, d, a, b, in[14] + 0xa679438e, 17); + MD5STEP(F1, b, c, d, a, in[15] + 0x49b40821, 22); + + MD5STEP(F2, a, b, c, d, in[1] + 0xf61e2562, 5); + MD5STEP(F2, d, a, b, c, in[6] + 0xc040b340, 9); + MD5STEP(F2, c, d, a, b, in[11] + 0x265e5a51, 14); + MD5STEP(F2, b, c, d, a, in[0] + 0xe9b6c7aa, 20); + MD5STEP(F2, a, b, c, d, in[5] + 0xd62f105d, 5); + MD5STEP(F2, d, a, b, c, in[10] + 0x02441453, 9); + MD5STEP(F2, c, d, a, b, in[15] + 0xd8a1e681, 14); + MD5STEP(F2, b, c, d, a, in[4] + 0xe7d3fbc8, 20); + MD5STEP(F2, a, b, c, d, in[9] + 0x21e1cde6, 5); + MD5STEP(F2, d, a, b, c, in[14] + 0xc33707d6, 9); + MD5STEP(F2, c, d, a, b, in[3] + 0xf4d50d87, 14); + MD5STEP(F2, b, c, d, a, in[8] + 0x455a14ed, 20); + MD5STEP(F2, a, b, c, d, in[13] + 0xa9e3e905, 5); + MD5STEP(F2, d, a, b, c, in[2] + 0xfcefa3f8, 9); + MD5STEP(F2, c, d, a, b, in[7] + 0x676f02d9, 14); + MD5STEP(F2, b, c, d, a, in[12] + 0x8d2a4c8a, 20); + + MD5STEP(F3, a, b, c, d, in[5] + 0xfffa3942, 4); + MD5STEP(F3, d, a, b, c, in[8] + 0x8771f681, 11); + MD5STEP(F3, c, d, a, b, in[11] + 0x6d9d6122, 16); + MD5STEP(F3, b, c, d, a, in[14] + 0xfde5380c, 23); + MD5STEP(F3, a, b, c, d, in[1] + 0xa4beea44, 4); + MD5STEP(F3, d, a, b, c, in[4] + 0x4bdecfa9, 11); + MD5STEP(F3, c, d, a, b, in[7] + 0xf6bb4b60, 16); + MD5STEP(F3, b, c, d, a, in[10] + 0xbebfbc70, 23); + MD5STEP(F3, a, b, c, d, in[13] + 0x289b7ec6, 4); + MD5STEP(F3, d, a, b, c, in[0] + 0xeaa127fa, 11); + MD5STEP(F3, c, d, a, b, in[3] + 0xd4ef3085, 16); + MD5STEP(F3, b, c, d, a, in[6] + 0x04881d05, 23); + MD5STEP(F3, a, b, c, d, in[9] + 0xd9d4d039, 4); + MD5STEP(F3, d, a, b, c, in[12] + 0xe6db99e5, 11); + MD5STEP(F3, c, d, a, b, in[15] + 0x1fa27cf8, 16); + MD5STEP(F3, b, c, d, a, in[2] + 0xc4ac5665, 23); + + MD5STEP(F4, a, b, c, d, in[0] + 0xf4292244, 6); + MD5STEP(F4, d, a, b, c, in[7] + 0x432aff97, 10); + MD5STEP(F4, c, d, a, b, in[14] + 0xab9423a7, 15); + MD5STEP(F4, b, c, d, a, in[5] + 0xfc93a039, 21); + MD5STEP(F4, a, b, c, d, in[12] + 0x655b59c3, 6); + MD5STEP(F4, d, a, b, c, in[3] + 0x8f0ccc92, 10); + MD5STEP(F4, c, d, a, b, in[10] + 0xffeff47d, 15); + MD5STEP(F4, b, c, d, a, in[1] + 0x85845dd1, 21); + MD5STEP(F4, a, b, c, d, in[8] + 0x6fa87e4f, 6); + MD5STEP(F4, d, a, b, c, in[15] + 0xfe2ce6e0, 10); + MD5STEP(F4, c, d, a, b, in[6] + 0xa3014314, 15); + MD5STEP(F4, b, c, d, a, in[13] + 0x4e0811a1, 21); + MD5STEP(F4, a, b, c, d, in[4] + 0xf7537e82, 6); + MD5STEP(F4, d, a, b, c, in[11] + 0xbd3af235, 10); + MD5STEP(F4, c, d, a, b, in[2] + 0x2ad7d2bb, 15); + MD5STEP(F4, b, c, d, a, in[9] + 0xeb86d391, 21); + + buf[0] += a; + buf[1] += b; + buf[2] += c; + buf[3] += d; +} + +/*! + * Update context to reflect the concatenation of another buffer full + * of bytes. + */ +void +isc_md5_update(isc_md5_t *ctx, const unsigned char *buf, unsigned int len) { + isc_uint32_t t; + + /* Update byte count */ + + t = ctx->bytes[0]; + if ((ctx->bytes[0] = t + len) < t) + ctx->bytes[1]++; /* Carry from low to high */ + + t = 64 - (t & 0x3f); /* Space available in ctx->in (at least 1) */ + if (t > len) { + memcpy((unsigned char *)ctx->in + 64 - t, buf, len); + return; + } + /* First chunk is an odd size */ + memcpy((unsigned char *)ctx->in + 64 - t, buf, t); + byteSwap(ctx->in, 16); + transform(ctx->buf, ctx->in); + buf += t; + len -= t; + + /* Process data in 64-byte chunks */ + while (len >= 64) { + memcpy(ctx->in, buf, 64); + byteSwap(ctx->in, 16); + transform(ctx->buf, ctx->in); + buf += 64; + len -= 64; + } + + /* Handle any remaining bytes of data. */ + memcpy(ctx->in, buf, len); +} + +/*! + * Final wrapup - pad to 64-byte boundary with the bit pattern + * 1 0* (64-bit count of bits processed, MSB-first) + */ +void +isc_md5_final(isc_md5_t *ctx, unsigned char *digest) { + int count = ctx->bytes[0] & 0x3f; /* Number of bytes in ctx->in */ + unsigned char *p = (unsigned char *)ctx->in + count; + + /* Set the first char of padding to 0x80. There is always room. */ + *p++ = 0x80; + + /* Bytes of padding needed to make 56 bytes (-8..55) */ + count = 56 - 1 - count; + + if (count < 0) { /* Padding forces an extra block */ + memset(p, 0, count + 8); + byteSwap(ctx->in, 16); + transform(ctx->buf, ctx->in); + p = (unsigned char *)ctx->in; + count = 56; + } + memset(p, 0, count); + byteSwap(ctx->in, 14); + + /* Append length in bits and transform */ + ctx->in[14] = ctx->bytes[0] << 3; + ctx->in[15] = ctx->bytes[1] << 3 | ctx->bytes[0] >> 29; + transform(ctx->buf, ctx->in); + + byteSwap(ctx->buf, 4); + memcpy(digest, ctx->buf, 16); + memset(ctx, 0, sizeof(isc_md5_t)); /* In case it's sensitive */ +} +#endif diff --git a/contrib/ntp/lib/isc/mem.c b/contrib/ntp/lib/isc/mem.c new file mode 100644 index 000000000..5b4b16c57 --- /dev/null +++ b/contrib/ntp/lib/isc/mem.c @@ -0,0 +1,2477 @@ +/* + * Copyright (C) 2004-2010, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1997-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define MCTXLOCK(m, l) if (((m)->flags & ISC_MEMFLAG_NOLOCK) == 0) LOCK(l) +#define MCTXUNLOCK(m, l) if (((m)->flags & ISC_MEMFLAG_NOLOCK) == 0) UNLOCK(l) + +#ifndef ISC_MEM_DEBUGGING +#define ISC_MEM_DEBUGGING 0 +#endif +LIBISC_EXTERNAL_DATA unsigned int isc_mem_debugging = ISC_MEM_DEBUGGING; + +/* + * Constants. + */ + +#define DEF_MAX_SIZE 1100 +#define DEF_MEM_TARGET 4096 +#define ALIGNMENT_SIZE 8U /*%< must be a power of 2 */ +#define NUM_BASIC_BLOCKS 64 /*%< must be > 1 */ +#define TABLE_INCREMENT 1024 +#define DEBUGLIST_COUNT 1024 + +/* + * Types. + */ +typedef struct isc__mem isc__mem_t; +typedef struct isc__mempool isc__mempool_t; + +#if ISC_MEM_TRACKLINES +typedef struct debuglink debuglink_t; +struct debuglink { + ISC_LINK(debuglink_t) link; + const void *ptr[DEBUGLIST_COUNT]; + unsigned int size[DEBUGLIST_COUNT]; + const char *file[DEBUGLIST_COUNT]; + unsigned int line[DEBUGLIST_COUNT]; + unsigned int count; +}; + +#define FLARG_PASS , file, line +#define FLARG , const char *file, unsigned int line +#else +#define FLARG_PASS +#define FLARG +#endif + +typedef struct element element; +struct element { + element * next; +}; + +typedef struct { + /*! + * This structure must be ALIGNMENT_SIZE bytes. + */ + union { + size_t size; + isc__mem_t *ctx; + char bytes[ALIGNMENT_SIZE]; + } u; +} size_info; + +struct stats { + unsigned long gets; + unsigned long totalgets; + unsigned long blocks; + unsigned long freefrags; +}; + +#define MEM_MAGIC ISC_MAGIC('M', 'e', 'm', 'C') +#define VALID_CONTEXT(c) ISC_MAGIC_VALID(c, MEM_MAGIC) + +#if ISC_MEM_TRACKLINES +typedef ISC_LIST(debuglink_t) debuglist_t; +#endif + +/* List of all active memory contexts. */ + +static ISC_LIST(isc__mem_t) contexts; +static isc_once_t once = ISC_ONCE_INIT; +static isc_mutex_t lock; + +/*% + * Total size of lost memory due to a bug of external library. + * Locked by the global lock. + */ +static isc_uint64_t totallost; + +struct isc__mem { + isc_mem_t common; + isc_ondestroy_t ondestroy; + unsigned int flags; + isc_mutex_t lock; + isc_memalloc_t memalloc; + isc_memfree_t memfree; + void * arg; + size_t max_size; + isc_boolean_t checkfree; + struct stats * stats; + unsigned int references; + char name[16]; + void * tag; + size_t quota; + size_t total; + size_t inuse; + size_t maxinuse; + size_t hi_water; + size_t lo_water; + isc_boolean_t hi_called; + isc_boolean_t is_overmem; + isc_mem_water_t water; + void * water_arg; + ISC_LIST(isc__mempool_t) pools; + unsigned int poolcnt; + + /* ISC_MEMFLAG_INTERNAL */ + size_t mem_target; + element ** freelists; + element * basic_blocks; + unsigned char ** basic_table; + unsigned int basic_table_count; + unsigned int basic_table_size; + unsigned char * lowest; + unsigned char * highest; + +#if ISC_MEM_TRACKLINES + debuglist_t * debuglist; + unsigned int debuglistcnt; +#endif + + unsigned int memalloc_failures; + ISC_LINK(isc__mem_t) link; +}; + +#define MEMPOOL_MAGIC ISC_MAGIC('M', 'E', 'M', 'p') +#define VALID_MEMPOOL(c) ISC_MAGIC_VALID(c, MEMPOOL_MAGIC) + +struct isc__mempool { + /* always unlocked */ + isc_mempool_t common; /*%< common header of mempool's */ + isc_mutex_t *lock; /*%< optional lock */ + isc__mem_t *mctx; /*%< our memory context */ + /*%< locked via the memory context's lock */ + ISC_LINK(isc__mempool_t) link; /*%< next pool in this mem context */ + /*%< optionally locked from here down */ + element *items; /*%< low water item list */ + size_t size; /*%< size of each item on this pool */ + unsigned int maxalloc; /*%< max number of items allowed */ + unsigned int allocated; /*%< # of items currently given out */ + unsigned int freecount; /*%< # of items on reserved list */ + unsigned int freemax; /*%< # of items allowed on free list */ + unsigned int fillcount; /*%< # of items to fetch on each fill */ + /*%< Stats only. */ + unsigned int gets; /*%< # of requests to this pool */ + /*%< Debugging only. */ +#if ISC_MEMPOOL_NAMES + char name[16]; /*%< printed name in stats reports */ +#endif +}; + +/* + * Private Inline-able. + */ + +#if ! ISC_MEM_TRACKLINES +#define ADD_TRACE(a, b, c, d, e) +#define DELETE_TRACE(a, b, c, d, e) +#else +#define ADD_TRACE(a, b, c, d, e) \ + do { \ + if ((isc_mem_debugging & (ISC_MEM_DEBUGTRACE | \ + ISC_MEM_DEBUGRECORD)) != 0 && \ + b != NULL) \ + add_trace_entry(a, b, c, d, e); \ + } while (0) +#define DELETE_TRACE(a, b, c, d, e) delete_trace_entry(a, b, c, d, e) + +static void +print_active(isc__mem_t *ctx, FILE *out); + +/*% + * The following can be either static or public, depending on build environment. + */ + +#ifdef BIND9 +#define ISC_MEMFUNC_SCOPE +#else +#define ISC_MEMFUNC_SCOPE static +#endif + +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_createx(size_t init_max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, void *arg, + isc_mem_t **ctxp); +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_createx2(size_t init_max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, void *arg, + isc_mem_t **ctxp, unsigned int flags); +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_create(size_t init_max_size, size_t target_size, isc_mem_t **ctxp); +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_create2(size_t init_max_size, size_t target_size, + isc_mem_t **ctxp, unsigned int flags); +ISC_MEMFUNC_SCOPE void +isc__mem_attach(isc_mem_t *source, isc_mem_t **targetp); +ISC_MEMFUNC_SCOPE void +isc__mem_detach(isc_mem_t **ctxp); +ISC_MEMFUNC_SCOPE void +isc___mem_putanddetach(isc_mem_t **ctxp, void *ptr, size_t size FLARG); +ISC_MEMFUNC_SCOPE void +isc__mem_destroy(isc_mem_t **ctxp); +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_ondestroy(isc_mem_t *ctx, isc_task_t *task, isc_event_t **event); +ISC_MEMFUNC_SCOPE void * +isc___mem_get(isc_mem_t *ctx, size_t size FLARG); +ISC_MEMFUNC_SCOPE void +isc___mem_put(isc_mem_t *ctx, void *ptr, size_t size FLARG); +ISC_MEMFUNC_SCOPE void +isc__mem_stats(isc_mem_t *ctx, FILE *out); +ISC_MEMFUNC_SCOPE void * +isc___mem_allocate(isc_mem_t *ctx, size_t size FLARG); +ISC_MEMFUNC_SCOPE void * +isc___mem_reallocate(isc_mem_t *ctx, void *ptr, size_t size FLARG); +ISC_MEMFUNC_SCOPE void +isc___mem_free(isc_mem_t *ctx, void *ptr FLARG); +ISC_MEMFUNC_SCOPE char * +isc___mem_strdup(isc_mem_t *mctx, const char *s FLARG); +ISC_MEMFUNC_SCOPE void +isc__mem_setdestroycheck(isc_mem_t *ctx, isc_boolean_t flag); +ISC_MEMFUNC_SCOPE void +isc__mem_setquota(isc_mem_t *ctx, size_t quota); +ISC_MEMFUNC_SCOPE size_t +isc__mem_getquota(isc_mem_t *ctx); +ISC_MEMFUNC_SCOPE size_t +isc__mem_inuse(isc_mem_t *ctx); +ISC_MEMFUNC_SCOPE isc_boolean_t +isc__mem_isovermem(isc_mem_t *ctx); +ISC_MEMFUNC_SCOPE void +isc__mem_setwater(isc_mem_t *ctx, isc_mem_water_t water, void *water_arg, + size_t hiwater, size_t lowater); +ISC_MEMFUNC_SCOPE void +isc__mem_waterack(isc_mem_t *ctx0, int flag); +ISC_MEMFUNC_SCOPE void +isc__mem_setname(isc_mem_t *ctx, const char *name, void *tag); +ISC_MEMFUNC_SCOPE const char * +isc__mem_getname(isc_mem_t *ctx); +ISC_MEMFUNC_SCOPE void * +isc__mem_gettag(isc_mem_t *ctx); +ISC_MEMFUNC_SCOPE isc_result_t +isc__mempool_create(isc_mem_t *mctx, size_t size, isc_mempool_t **mpctxp); +ISC_MEMFUNC_SCOPE void +isc__mempool_setname(isc_mempool_t *mpctx, const char *name); +ISC_MEMFUNC_SCOPE void +isc__mempool_destroy(isc_mempool_t **mpctxp); +ISC_MEMFUNC_SCOPE void +isc__mempool_associatelock(isc_mempool_t *mpctx, isc_mutex_t *lock); +ISC_MEMFUNC_SCOPE void * +isc___mempool_get(isc_mempool_t *mpctx FLARG); +ISC_MEMFUNC_SCOPE void +isc___mempool_put(isc_mempool_t *mpctx, void *mem FLARG); +ISC_MEMFUNC_SCOPE void +isc__mempool_setfreemax(isc_mempool_t *mpctx, unsigned int limit); +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getfreemax(isc_mempool_t *mpctx); +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getfreecount(isc_mempool_t *mpctx); +ISC_MEMFUNC_SCOPE void +isc__mempool_setmaxalloc(isc_mempool_t *mpctx, unsigned int limit); +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getmaxalloc(isc_mempool_t *mpctx); +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getallocated(isc_mempool_t *mpctx); +ISC_MEMFUNC_SCOPE void +isc__mempool_setfillcount(isc_mempool_t *mpctx, unsigned int limit); +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getfillcount(isc_mempool_t *mpctx); +#ifdef BIND9 +ISC_MEMFUNC_SCOPE void +isc__mem_printactive(isc_mem_t *ctx0, FILE *file); +ISC_MEMFUNC_SCOPE void +isc__mem_printallactive(FILE *file); +ISC_MEMFUNC_SCOPE void +isc__mem_checkdestroyed(FILE *file); +ISC_MEMFUNC_SCOPE unsigned int +isc__mem_references(isc_mem_t *ctx0); +#endif + +static struct isc__memmethods { + isc_memmethods_t methods; + + /*% + * The following are defined just for avoiding unused static functions. + */ +#ifndef BIND9 + void *createx, *create, *create2, *ondestroy, *stats, + *setquota, *getquota, *setname, *getname, *gettag; +#endif +} memmethods = { + { + isc__mem_attach, + isc__mem_detach, + isc__mem_destroy, + isc___mem_get, + isc___mem_put, + isc___mem_putanddetach, + isc___mem_allocate, + isc___mem_reallocate, + isc___mem_strdup, + isc___mem_free, + isc__mem_setdestroycheck, + isc__mem_setwater, + isc__mem_waterack, + isc__mem_inuse, + isc__mem_isovermem, + isc__mempool_create + } +#ifndef BIND9 + , + (void *)isc__mem_createx, (void *)isc__mem_create, + (void *)isc__mem_create2, (void *)isc__mem_ondestroy, + (void *)isc__mem_stats, (void *)isc__mem_setquota, + (void *)isc__mem_getquota, (void *)isc__mem_setname, + (void *)isc__mem_getname, (void *)isc__mem_gettag +#endif +}; + +static struct isc__mempoolmethods { + isc_mempoolmethods_t methods; + + /*% + * The following are defined just for avoiding unused static functions. + */ +#ifndef BIND9 + void *getfreemax, *getfreecount, *getmaxalloc, *getfillcount; +#endif +} mempoolmethods = { + { + isc__mempool_destroy, + isc___mempool_get, + isc___mempool_put, + isc__mempool_getallocated, + isc__mempool_setmaxalloc, + isc__mempool_setfreemax, + isc__mempool_setname, + isc__mempool_associatelock, + isc__mempool_setfillcount + } +#ifndef BIND9 + , + (void *)isc__mempool_getfreemax, (void *)isc__mempool_getfreecount, + (void *)isc__mempool_getmaxalloc, (void *)isc__mempool_getfillcount +#endif +}; + +/*! + * mctx must be locked. + */ +static inline void +add_trace_entry(isc__mem_t *mctx, const void *ptr, unsigned int size + FLARG) +{ + debuglink_t *dl; + unsigned int i; + unsigned int mysize = size; + + if ((isc_mem_debugging & ISC_MEM_DEBUGTRACE) != 0) + fprintf(stderr, isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_ADDTRACE, + "add %p size %u " + "file %s line %u mctx %p\n"), + ptr, size, file, line, mctx); + + if (mctx->debuglist == NULL) + return; + + if (mysize > mctx->max_size) + mysize = mctx->max_size; + + dl = ISC_LIST_HEAD(mctx->debuglist[mysize]); + while (dl != NULL) { + if (dl->count == DEBUGLIST_COUNT) + goto next; + for (i = 0; i < DEBUGLIST_COUNT; i++) { + if (dl->ptr[i] == NULL) { + dl->ptr[i] = ptr; + dl->size[i] = size; + dl->file[i] = file; + dl->line[i] = line; + dl->count++; + return; + } + } + next: + dl = ISC_LIST_NEXT(dl, link); + } + + dl = malloc(sizeof(debuglink_t)); + INSIST(dl != NULL); + + ISC_LINK_INIT(dl, link); + for (i = 1; i < DEBUGLIST_COUNT; i++) { + dl->ptr[i] = NULL; + dl->size[i] = 0; + dl->file[i] = NULL; + dl->line[i] = 0; + } + + dl->ptr[0] = ptr; + dl->size[0] = size; + dl->file[0] = file; + dl->line[0] = line; + dl->count = 1; + + ISC_LIST_PREPEND(mctx->debuglist[mysize], dl, link); + mctx->debuglistcnt++; +} + +static inline void +delete_trace_entry(isc__mem_t *mctx, const void *ptr, unsigned int size, + const char *file, unsigned int line) +{ + debuglink_t *dl; + unsigned int i; + + if ((isc_mem_debugging & ISC_MEM_DEBUGTRACE) != 0) + fprintf(stderr, isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_DELTRACE, + "del %p size %u " + "file %s line %u mctx %p\n"), + ptr, size, file, line, mctx); + + if (mctx->debuglist == NULL) + return; + + if (size > mctx->max_size) + size = mctx->max_size; + + dl = ISC_LIST_HEAD(mctx->debuglist[size]); + while (dl != NULL) { + for (i = 0; i < DEBUGLIST_COUNT; i++) { + if (dl->ptr[i] == ptr) { + dl->ptr[i] = NULL; + dl->size[i] = 0; + dl->file[i] = NULL; + dl->line[i] = 0; + + INSIST(dl->count > 0); + dl->count--; + if (dl->count == 0) { + ISC_LIST_UNLINK(mctx->debuglist[size], + dl, link); + free(dl); + } + return; + } + } + dl = ISC_LIST_NEXT(dl, link); + } + + /* + * If we get here, we didn't find the item on the list. We're + * screwed. + */ + INSIST(dl != NULL); +} +#endif /* ISC_MEM_TRACKLINES */ + +static inline size_t +rmsize(size_t size) { + /* + * round down to ALIGNMENT_SIZE + */ + return (size & (~(ALIGNMENT_SIZE - 1))); +} + +static inline size_t +quantize(size_t size) { + /*! + * Round up the result in order to get a size big + * enough to satisfy the request and be aligned on ALIGNMENT_SIZE + * byte boundaries. + */ + + if (size == 0U) + return (ALIGNMENT_SIZE); + return ((size + ALIGNMENT_SIZE - 1) & (~(ALIGNMENT_SIZE - 1))); +} + +static inline isc_boolean_t +more_basic_blocks(isc__mem_t *ctx) { + void *new; + unsigned char *curr, *next; + unsigned char *first, *last; + unsigned char **table; + unsigned int table_size; + size_t increment; + int i; + + /* Require: we hold the context lock. */ + + /* + * Did we hit the quota for this context? + */ + increment = NUM_BASIC_BLOCKS * ctx->mem_target; + if (ctx->quota != 0U && ctx->total + increment > ctx->quota) + return (ISC_FALSE); + + INSIST(ctx->basic_table_count <= ctx->basic_table_size); + if (ctx->basic_table_count == ctx->basic_table_size) { + table_size = ctx->basic_table_size + TABLE_INCREMENT; + table = (ctx->memalloc)(ctx->arg, + table_size * sizeof(unsigned char *)); + if (table == NULL) { + ctx->memalloc_failures++; + return (ISC_FALSE); + } + if (ctx->basic_table_size != 0) { + memcpy(table, ctx->basic_table, + ctx->basic_table_size * + sizeof(unsigned char *)); + (ctx->memfree)(ctx->arg, ctx->basic_table); + } + ctx->basic_table = table; + ctx->basic_table_size = table_size; + } + + new = (ctx->memalloc)(ctx->arg, NUM_BASIC_BLOCKS * ctx->mem_target); + if (new == NULL) { + ctx->memalloc_failures++; + return (ISC_FALSE); + } + ctx->total += increment; + ctx->basic_table[ctx->basic_table_count] = new; + ctx->basic_table_count++; + + curr = new; + next = curr + ctx->mem_target; + for (i = 0; i < (NUM_BASIC_BLOCKS - 1); i++) { + ((element *)curr)->next = (element *)next; + curr = next; + next += ctx->mem_target; + } + /* + * curr is now pointing at the last block in the + * array. + */ + ((element *)curr)->next = NULL; + first = new; + last = first + NUM_BASIC_BLOCKS * ctx->mem_target - 1; + if (first < ctx->lowest || ctx->lowest == NULL) + ctx->lowest = first; + if (last > ctx->highest) + ctx->highest = last; + ctx->basic_blocks = new; + + return (ISC_TRUE); +} + +static inline isc_boolean_t +more_frags(isc__mem_t *ctx, size_t new_size) { + int i, frags; + size_t total_size; + void *new; + unsigned char *curr, *next; + + /*! + * Try to get more fragments by chopping up a basic block. + */ + + if (ctx->basic_blocks == NULL) { + if (!more_basic_blocks(ctx)) { + /* + * We can't get more memory from the OS, or we've + * hit the quota for this context. + */ + /* + * XXXRTH "At quota" notification here. + */ + return (ISC_FALSE); + } + } + + total_size = ctx->mem_target; + new = ctx->basic_blocks; + ctx->basic_blocks = ctx->basic_blocks->next; + frags = total_size / new_size; + ctx->stats[new_size].blocks++; + ctx->stats[new_size].freefrags += frags; + /* + * Set up a linked-list of blocks of size + * "new_size". + */ + curr = new; + next = curr + new_size; + total_size -= new_size; + for (i = 0; i < (frags - 1); i++) { + ((element *)curr)->next = (element *)next; + curr = next; + next += new_size; + total_size -= new_size; + } + /* + * Add the remaining fragment of the basic block to a free list. + */ + total_size = rmsize(total_size); + if (total_size > 0U) { + ((element *)next)->next = ctx->freelists[total_size]; + ctx->freelists[total_size] = (element *)next; + ctx->stats[total_size].freefrags++; + } + /* + * curr is now pointing at the last block in the + * array. + */ + ((element *)curr)->next = NULL; + ctx->freelists[new_size] = new; + + return (ISC_TRUE); +} + +static inline void * +mem_getunlocked(isc__mem_t *ctx, size_t size) { + size_t new_size = quantize(size); + void *ret; + + if (size >= ctx->max_size || new_size >= ctx->max_size) { + /* + * memget() was called on something beyond our upper limit. + */ + if (ctx->quota != 0U && ctx->total + size > ctx->quota) { + ret = NULL; + goto done; + } + ret = (ctx->memalloc)(ctx->arg, size); + if (ret == NULL) { + ctx->memalloc_failures++; + goto done; + } + ctx->total += size; + ctx->inuse += size; + ctx->stats[ctx->max_size].gets++; + ctx->stats[ctx->max_size].totalgets++; + /* + * If we don't set new_size to size, then the + * ISC_MEM_FILL code might write over bytes we + * don't own. + */ + new_size = size; + goto done; + } + + /* + * If there are no blocks in the free list for this size, get a chunk + * of memory and then break it up into "new_size"-sized blocks, adding + * them to the free list. + */ + if (ctx->freelists[new_size] == NULL && !more_frags(ctx, new_size)) + return (NULL); + + /* + * The free list uses the "rounded-up" size "new_size". + */ + ret = ctx->freelists[new_size]; + ctx->freelists[new_size] = ctx->freelists[new_size]->next; + + /* + * The stats[] uses the _actual_ "size" requested by the + * caller, with the caveat (in the code above) that "size" >= the + * max. size (max_size) ends up getting recorded as a call to + * max_size. + */ + ctx->stats[size].gets++; + ctx->stats[size].totalgets++; + ctx->stats[new_size].freefrags--; + ctx->inuse += new_size; + + done: + +#if ISC_MEM_FILL + if (ret != NULL) + memset(ret, 0xbe, new_size); /* Mnemonic for "beef". */ +#endif + + return (ret); +} + +#if ISC_MEM_FILL && ISC_MEM_CHECKOVERRUN +static inline void +check_overrun(void *mem, size_t size, size_t new_size) { + unsigned char *cp; + + cp = (unsigned char *)mem; + cp += size; + while (size < new_size) { + INSIST(*cp == 0xbe); + cp++; + size++; + } +} +#endif + +static inline void +mem_putunlocked(isc__mem_t *ctx, void *mem, size_t size) { + size_t new_size = quantize(size); + + if (size == ctx->max_size || new_size >= ctx->max_size) { + /* + * memput() called on something beyond our upper limit. + */ +#if ISC_MEM_FILL + memset(mem, 0xde, size); /* Mnemonic for "dead". */ +#endif + (ctx->memfree)(ctx->arg, mem); + INSIST(ctx->stats[ctx->max_size].gets != 0U); + ctx->stats[ctx->max_size].gets--; + INSIST(size <= ctx->total); + ctx->inuse -= size; + ctx->total -= size; + return; + } + +#if ISC_MEM_FILL +#if ISC_MEM_CHECKOVERRUN + check_overrun(mem, size, new_size); +#endif + memset(mem, 0xde, new_size); /* Mnemonic for "dead". */ +#endif + + /* + * The free list uses the "rounded-up" size "new_size". + */ + ((element *)mem)->next = ctx->freelists[new_size]; + ctx->freelists[new_size] = (element *)mem; + + /* + * The stats[] uses the _actual_ "size" requested by the + * caller, with the caveat (in the code above) that "size" >= the + * max. size (max_size) ends up getting recorded as a call to + * max_size. + */ + INSIST(ctx->stats[size].gets != 0U); + ctx->stats[size].gets--; + ctx->stats[new_size].freefrags++; + ctx->inuse -= new_size; +} + +/*! + * Perform a malloc, doing memory filling and overrun detection as necessary. + */ +static inline void * +mem_get(isc__mem_t *ctx, size_t size) { + char *ret; + +#if ISC_MEM_CHECKOVERRUN + size += 1; +#endif + + ret = (ctx->memalloc)(ctx->arg, size); + if (ret == NULL) + ctx->memalloc_failures++; + +#if ISC_MEM_FILL + if (ret != NULL) + memset(ret, 0xbe, size); /* Mnemonic for "beef". */ +#else +# if ISC_MEM_CHECKOVERRUN + if (ret != NULL) + ret[size-1] = 0xbe; +# endif +#endif + + return (ret); +} + +/*! + * Perform a free, doing memory filling and overrun detection as necessary. + */ +static inline void +mem_put(isc__mem_t *ctx, void *mem, size_t size) { +#if ISC_MEM_CHECKOVERRUN + INSIST(((unsigned char *)mem)[size] == 0xbe); +#endif +#if ISC_MEM_FILL + memset(mem, 0xde, size); /* Mnemonic for "dead". */ +#else + UNUSED(size); +#endif + (ctx->memfree)(ctx->arg, mem); +} + +/*! + * Update internal counters after a memory get. + */ +static inline void +mem_getstats(isc__mem_t *ctx, size_t size) { + ctx->total += size; + ctx->inuse += size; + + if (size > ctx->max_size) { + ctx->stats[ctx->max_size].gets++; + ctx->stats[ctx->max_size].totalgets++; + } else { + ctx->stats[size].gets++; + ctx->stats[size].totalgets++; + } +} + +/*! + * Update internal counters after a memory put. + */ +static inline void +mem_putstats(isc__mem_t *ctx, void *ptr, size_t size) { + UNUSED(ptr); + + INSIST(ctx->inuse >= size); + ctx->inuse -= size; + + if (size > ctx->max_size) { + INSIST(ctx->stats[ctx->max_size].gets > 0U); + ctx->stats[ctx->max_size].gets--; + } else { + INSIST(ctx->stats[size].gets > 0U); + ctx->stats[size].gets--; + } +} + +/* + * Private. + */ + +static void * +default_memalloc(void *arg, size_t size) { + UNUSED(arg); + if (size == 0U) + size = 1; + return (malloc(size)); +} + +static void +default_memfree(void *arg, void *ptr) { + UNUSED(arg); + free(ptr); +} + +static void +initialize_action(void) { + RUNTIME_CHECK(isc_mutex_init(&lock) == ISC_R_SUCCESS); + ISC_LIST_INIT(contexts); + totallost = 0; +} + +/* + * Public. + */ + +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_createx(size_t init_max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, void *arg, + isc_mem_t **ctxp) +{ + return (isc__mem_createx2(init_max_size, target_size, memalloc, memfree, + arg, ctxp, ISC_MEMFLAG_DEFAULT)); + +} + +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_createx2(size_t init_max_size, size_t target_size, + isc_memalloc_t memalloc, isc_memfree_t memfree, void *arg, + isc_mem_t **ctxp, unsigned int flags) +{ + isc__mem_t *ctx; + isc_result_t result; + + REQUIRE(ctxp != NULL && *ctxp == NULL); + REQUIRE(memalloc != NULL); + REQUIRE(memfree != NULL); + + INSIST((ALIGNMENT_SIZE & (ALIGNMENT_SIZE - 1)) == 0); + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + ctx = (memalloc)(arg, sizeof(*ctx)); + if (ctx == NULL) + return (ISC_R_NOMEMORY); + + if ((flags & ISC_MEMFLAG_NOLOCK) == 0) { + result = isc_mutex_init(&ctx->lock); + if (result != ISC_R_SUCCESS) { + (memfree)(arg, ctx); + return (result); + } + } + + if (init_max_size == 0U) + ctx->max_size = DEF_MAX_SIZE; + else + ctx->max_size = init_max_size; + ctx->flags = flags; + ctx->references = 1; + memset(ctx->name, 0, sizeof(ctx->name)); + ctx->tag = NULL; + ctx->quota = 0; + ctx->total = 0; + ctx->inuse = 0; + ctx->maxinuse = 0; + ctx->hi_water = 0; + ctx->lo_water = 0; + ctx->hi_called = ISC_FALSE; + ctx->is_overmem = ISC_FALSE; + ctx->water = NULL; + ctx->water_arg = NULL; + ctx->common.impmagic = MEM_MAGIC; + ctx->common.magic = ISCAPI_MCTX_MAGIC; + ctx->common.methods = (isc_memmethods_t *)&memmethods; + isc_ondestroy_init(&ctx->ondestroy); + ctx->memalloc = memalloc; + ctx->memfree = memfree; + ctx->arg = arg; + ctx->stats = NULL; + ctx->checkfree = ISC_TRUE; +#if ISC_MEM_TRACKLINES + ctx->debuglist = NULL; + ctx->debuglistcnt = 0; +#endif + ISC_LIST_INIT(ctx->pools); + ctx->poolcnt = 0; + ctx->freelists = NULL; + ctx->basic_blocks = NULL; + ctx->basic_table = NULL; + ctx->basic_table_count = 0; + ctx->basic_table_size = 0; + ctx->lowest = NULL; + ctx->highest = NULL; + + ctx->stats = (memalloc)(arg, + (ctx->max_size+1) * sizeof(struct stats)); + if (ctx->stats == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + memset(ctx->stats, 0, (ctx->max_size + 1) * sizeof(struct stats)); + + if ((flags & ISC_MEMFLAG_INTERNAL) != 0) { + if (target_size == 0U) + ctx->mem_target = DEF_MEM_TARGET; + else + ctx->mem_target = target_size; + ctx->freelists = (memalloc)(arg, ctx->max_size * + sizeof(element *)); + if (ctx->freelists == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + memset(ctx->freelists, 0, + ctx->max_size * sizeof(element *)); + } + +#if ISC_MEM_TRACKLINES + if ((isc_mem_debugging & ISC_MEM_DEBUGRECORD) != 0) { + unsigned int i; + + ctx->debuglist = (memalloc)(arg, + (ctx->max_size+1) * sizeof(debuglist_t)); + if (ctx->debuglist == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + for (i = 0; i <= ctx->max_size; i++) + ISC_LIST_INIT(ctx->debuglist[i]); + } +#endif + + ctx->memalloc_failures = 0; + + LOCK(&lock); + ISC_LIST_INITANDAPPEND(contexts, ctx, link); + UNLOCK(&lock); + + *ctxp = (isc_mem_t *)ctx; + return (ISC_R_SUCCESS); + + error: + if (ctx != NULL) { + if (ctx->stats != NULL) + (memfree)(arg, ctx->stats); + if (ctx->freelists != NULL) + (memfree)(arg, ctx->freelists); +#if ISC_MEM_TRACKLINES + if (ctx->debuglist != NULL) + (ctx->memfree)(ctx->arg, ctx->debuglist); +#endif /* ISC_MEM_TRACKLINES */ + if ((ctx->flags & ISC_MEMFLAG_NOLOCK) == 0) + DESTROYLOCK(&ctx->lock); + (memfree)(arg, ctx); + } + + return (result); +} + +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_create(size_t init_max_size, size_t target_size, isc_mem_t **ctxp) { + return (isc__mem_createx2(init_max_size, target_size, + default_memalloc, default_memfree, NULL, + ctxp, ISC_MEMFLAG_DEFAULT)); +} + +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_create2(size_t init_max_size, size_t target_size, + isc_mem_t **ctxp, unsigned int flags) +{ + return (isc__mem_createx2(init_max_size, target_size, + default_memalloc, default_memfree, NULL, + ctxp, flags)); +} + +static void +destroy(isc__mem_t *ctx) { + unsigned int i; + isc_ondestroy_t ondest; + + LOCK(&lock); + ISC_LIST_UNLINK(contexts, ctx, link); + totallost += ctx->inuse; + UNLOCK(&lock); + + ctx->common.impmagic = 0; + ctx->common.magic = 0; + + INSIST(ISC_LIST_EMPTY(ctx->pools)); + +#if ISC_MEM_TRACKLINES + if (ctx->debuglist != NULL) { + if (ctx->checkfree) { + for (i = 0; i <= ctx->max_size; i++) { + if (!ISC_LIST_EMPTY(ctx->debuglist[i])) + print_active(ctx, stderr); + INSIST(ISC_LIST_EMPTY(ctx->debuglist[i])); + } + } else { + debuglink_t *dl; + + for (i = 0; i <= ctx->max_size; i++) + for (dl = ISC_LIST_HEAD(ctx->debuglist[i]); + dl != NULL; + dl = ISC_LIST_HEAD(ctx->debuglist[i])) { + ISC_LIST_UNLINK(ctx->debuglist[i], + dl, link); + free(dl); + } + } + (ctx->memfree)(ctx->arg, ctx->debuglist); + } +#endif + INSIST(ctx->references == 0); + + if (ctx->checkfree) { + for (i = 0; i <= ctx->max_size; i++) { +#if ISC_MEM_TRACKLINES + if (ctx->stats[i].gets != 0U) + print_active(ctx, stderr); +#endif + INSIST(ctx->stats[i].gets == 0U); + } + } + + (ctx->memfree)(ctx->arg, ctx->stats); + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + for (i = 0; i < ctx->basic_table_count; i++) + (ctx->memfree)(ctx->arg, ctx->basic_table[i]); + (ctx->memfree)(ctx->arg, ctx->freelists); + if (ctx->basic_table != NULL) + (ctx->memfree)(ctx->arg, ctx->basic_table); + } + + ondest = ctx->ondestroy; + + if ((ctx->flags & ISC_MEMFLAG_NOLOCK) == 0) + DESTROYLOCK(&ctx->lock); + (ctx->memfree)(ctx->arg, ctx); + + isc_ondestroy_notify(&ondest, ctx); +} + +ISC_MEMFUNC_SCOPE void +isc__mem_attach(isc_mem_t *source0, isc_mem_t **targetp) { + isc__mem_t *source = (isc__mem_t *)source0; + + REQUIRE(VALID_CONTEXT(source)); + REQUIRE(targetp != NULL && *targetp == NULL); + + MCTXLOCK(source, &source->lock); + source->references++; + MCTXUNLOCK(source, &source->lock); + + *targetp = (isc_mem_t *)source; +} + +ISC_MEMFUNC_SCOPE void +isc__mem_detach(isc_mem_t **ctxp) { + isc__mem_t *ctx; + isc_boolean_t want_destroy = ISC_FALSE; + + REQUIRE(ctxp != NULL); + ctx = (isc__mem_t *)*ctxp; + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); + INSIST(ctx->references > 0); + ctx->references--; + if (ctx->references == 0) + want_destroy = ISC_TRUE; + MCTXUNLOCK(ctx, &ctx->lock); + + if (want_destroy) + destroy(ctx); + + *ctxp = NULL; +} + +/* + * isc_mem_putanddetach() is the equivalent of: + * + * mctx = NULL; + * isc_mem_attach(ptr->mctx, &mctx); + * isc_mem_detach(&ptr->mctx); + * isc_mem_put(mctx, ptr, sizeof(*ptr); + * isc_mem_detach(&mctx); + */ + +ISC_MEMFUNC_SCOPE void +isc___mem_putanddetach(isc_mem_t **ctxp, void *ptr, size_t size FLARG) { + isc__mem_t *ctx; + isc_boolean_t want_destroy = ISC_FALSE; + size_info *si; + size_t oldsize; + + REQUIRE(ctxp != NULL); + ctx = (isc__mem_t *)*ctxp; + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(ptr != NULL); + + /* + * Must be before mem_putunlocked() as ctxp is usually within + * [ptr..ptr+size). + */ + *ctxp = NULL; + + if ((isc_mem_debugging & (ISC_MEM_DEBUGSIZE|ISC_MEM_DEBUGCTX)) != 0) { + if ((isc_mem_debugging & ISC_MEM_DEBUGSIZE) != 0) { + si = &(((size_info *)ptr)[-1]); + oldsize = si->u.size - ALIGNMENT_SIZE; + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) + oldsize -= ALIGNMENT_SIZE; + INSIST(oldsize == size); + } + isc_mem_free((isc_mem_t *)ctx, ptr); + + MCTXLOCK(ctx, &ctx->lock); + ctx->references--; + if (ctx->references == 0) + want_destroy = ISC_TRUE; + MCTXUNLOCK(ctx, &ctx->lock); + if (want_destroy) + destroy(ctx); + + return; + } + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + mem_putunlocked(ctx, ptr, size); + } else { + mem_put(ctx, ptr, size); + MCTXLOCK(ctx, &ctx->lock); + mem_putstats(ctx, ptr, size); + } + + DELETE_TRACE(ctx, ptr, size, file, line); + INSIST(ctx->references > 0); + ctx->references--; + if (ctx->references == 0) + want_destroy = ISC_TRUE; + + MCTXUNLOCK(ctx, &ctx->lock); + + if (want_destroy) + destroy(ctx); +} + +ISC_MEMFUNC_SCOPE void +isc__mem_destroy(isc_mem_t **ctxp) { + isc__mem_t *ctx; + + /* + * This routine provides legacy support for callers who use mctxs + * without attaching/detaching. + */ + + REQUIRE(ctxp != NULL); + ctx = (isc__mem_t *)*ctxp; + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); +#if ISC_MEM_TRACKLINES + if (ctx->references != 1) + print_active(ctx, stderr); +#endif + REQUIRE(ctx->references == 1); + ctx->references--; + MCTXUNLOCK(ctx, &ctx->lock); + + destroy(ctx); + + *ctxp = NULL; +} + +ISC_MEMFUNC_SCOPE isc_result_t +isc__mem_ondestroy(isc_mem_t *ctx0, isc_task_t *task, isc_event_t **event) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + isc_result_t res; + + MCTXLOCK(ctx, &ctx->lock); + res = isc_ondestroy_register(&ctx->ondestroy, task, event); + MCTXUNLOCK(ctx, &ctx->lock); + + return (res); +} + +ISC_MEMFUNC_SCOPE void * +isc___mem_get(isc_mem_t *ctx0, size_t size FLARG) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + void *ptr; + isc_boolean_t call_water = ISC_FALSE; + + REQUIRE(VALID_CONTEXT(ctx)); + + if ((isc_mem_debugging & (ISC_MEM_DEBUGSIZE|ISC_MEM_DEBUGCTX)) != 0) + return (isc__mem_allocate(ctx0, size FLARG_PASS)); + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + ptr = mem_getunlocked(ctx, size); + } else { + ptr = mem_get(ctx, size); + MCTXLOCK(ctx, &ctx->lock); + if (ptr != NULL) + mem_getstats(ctx, size); + } + + ADD_TRACE(ctx, ptr, size, file, line); + if (ctx->hi_water != 0U && ctx->inuse > ctx->hi_water && + !ctx->is_overmem) { + ctx->is_overmem = ISC_TRUE; + } + if (ctx->hi_water != 0U && !ctx->hi_called && + ctx->inuse > ctx->hi_water) { + call_water = ISC_TRUE; + } + if (ctx->inuse > ctx->maxinuse) { + ctx->maxinuse = ctx->inuse; + if (ctx->hi_water != 0U && ctx->inuse > ctx->hi_water && + (isc_mem_debugging & ISC_MEM_DEBUGUSAGE) != 0) + fprintf(stderr, "maxinuse = %lu\n", + (unsigned long)ctx->inuse); + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_HIWATER); + + return (ptr); +} + +ISC_MEMFUNC_SCOPE void +isc___mem_put(isc_mem_t *ctx0, void *ptr, size_t size FLARG) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + isc_boolean_t call_water = ISC_FALSE; + size_info *si; + size_t oldsize; + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(ptr != NULL); + + if ((isc_mem_debugging & (ISC_MEM_DEBUGSIZE|ISC_MEM_DEBUGCTX)) != 0) { + if ((isc_mem_debugging & ISC_MEM_DEBUGSIZE) != 0) { + si = &(((size_info *)ptr)[-1]); + oldsize = si->u.size - ALIGNMENT_SIZE; + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) + oldsize -= ALIGNMENT_SIZE; + INSIST(oldsize == size); + } + isc_mem_free((isc_mem_t *)ctx, ptr); + return; + } + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + mem_putunlocked(ctx, ptr, size); + } else { + mem_put(ctx, ptr, size); + MCTXLOCK(ctx, &ctx->lock); + mem_putstats(ctx, ptr, size); + } + + DELETE_TRACE(ctx, ptr, size, file, line); + + /* + * The check against ctx->lo_water == 0 is for the condition + * when the context was pushed over hi_water but then had + * isc_mem_setwater() called with 0 for hi_water and lo_water. + */ + if (ctx->is_overmem && + (ctx->inuse < ctx->lo_water || ctx->lo_water == 0U)) { + ctx->is_overmem = ISC_FALSE; + } + if (ctx->hi_called && + (ctx->inuse < ctx->lo_water || ctx->lo_water == 0U)) { + if (ctx->water != NULL) + call_water = ISC_TRUE; + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_LOWATER); +} + +ISC_MEMFUNC_SCOPE void +isc__mem_waterack(isc_mem_t *ctx0, int flag) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); + if (flag == ISC_MEM_LOWATER) + ctx->hi_called = ISC_FALSE; + else if (flag == ISC_MEM_HIWATER) + ctx->hi_called = ISC_TRUE; + MCTXUNLOCK(ctx, &ctx->lock); +} + +#if ISC_MEM_TRACKLINES +static void +print_active(isc__mem_t *mctx, FILE *out) { + if (mctx->debuglist != NULL) { + debuglink_t *dl; + unsigned int i, j; + const char *format; + isc_boolean_t found; + + fprintf(out, "%s", isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_DUMPALLOC, + "Dump of all outstanding " + "memory allocations:\n")); + found = ISC_FALSE; + format = isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_PTRFILELINE, + "\tptr %p size %u file %s line %u\n"); + for (i = 0; i <= mctx->max_size; i++) { + dl = ISC_LIST_HEAD(mctx->debuglist[i]); + + if (dl != NULL) + found = ISC_TRUE; + + while (dl != NULL) { + for (j = 0; j < DEBUGLIST_COUNT; j++) + if (dl->ptr[j] != NULL) + fprintf(out, format, + dl->ptr[j], + dl->size[j], + dl->file[j], + dl->line[j]); + dl = ISC_LIST_NEXT(dl, link); + } + } + if (!found) + fprintf(out, "%s", isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_NONE, "\tNone.\n")); + } +} +#endif + +/* + * Print the stats[] on the stream "out" with suitable formatting. + */ +ISC_MEMFUNC_SCOPE void +isc__mem_stats(isc_mem_t *ctx0, FILE *out) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + size_t i; + const struct stats *s; + const isc__mempool_t *pool; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + for (i = 0; i <= ctx->max_size; i++) { + s = &ctx->stats[i]; + + if (s->totalgets == 0U && s->gets == 0U) + continue; + fprintf(out, "%s%5lu: %11lu gets, %11lu rem", + (i == ctx->max_size) ? ">=" : " ", + (unsigned long) i, s->totalgets, s->gets); + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0 && + (s->blocks != 0U || s->freefrags != 0U)) + fprintf(out, " (%lu bl, %lu ff)", + s->blocks, s->freefrags); + fputc('\n', out); + } + + /* + * Note that since a pool can be locked now, these stats might be + * somewhat off if the pool is in active use at the time the stats + * are dumped. The link fields are protected by the isc_mem_t's + * lock, however, so walking this list and extracting integers from + * stats fields is always safe. + */ + pool = ISC_LIST_HEAD(ctx->pools); + if (pool != NULL) { + fprintf(out, "%s", isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLSTATS, + "[Pool statistics]\n")); + fprintf(out, "%15s %10s %10s %10s %10s %10s %10s %10s %1s\n", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLNAME, "name"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLSIZE, "size"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLMAXALLOC, "maxalloc"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLALLOCATED, "allocated"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLFREECOUNT, "freecount"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLFREEMAX, "freemax"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLFILLCOUNT, "fillcount"), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_MEM, + ISC_MSG_POOLGETS, "gets"), + "L"); + } + while (pool != NULL) { + fprintf(out, "%15s %10lu %10u %10u %10u %10u %10u %10u %s\n", + pool->name, (unsigned long) pool->size, pool->maxalloc, + pool->allocated, pool->freecount, pool->freemax, + pool->fillcount, pool->gets, + (pool->lock == NULL ? "N" : "Y")); + pool = ISC_LIST_NEXT(pool, link); + } + +#if ISC_MEM_TRACKLINES + print_active(ctx, out); +#endif + + MCTXUNLOCK(ctx, &ctx->lock); +} + +/* + * Replacements for malloc() and free() -- they implicitly remember the + * size of the object allocated (with some additional overhead). + */ + +static void * +isc__mem_allocateunlocked(isc_mem_t *ctx0, size_t size) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + size_info *si; + + size += ALIGNMENT_SIZE; + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) + size += ALIGNMENT_SIZE; + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) + si = mem_getunlocked(ctx, size); + else + si = mem_get(ctx, size); + + if (si == NULL) + return (NULL); + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) { + si->u.ctx = ctx; + si++; + } + si->u.size = size; + return (&si[1]); +} + +ISC_MEMFUNC_SCOPE void * +isc___mem_allocate(isc_mem_t *ctx0, size_t size FLARG) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + size_info *si; + isc_boolean_t call_water = ISC_FALSE; + + REQUIRE(VALID_CONTEXT(ctx)); + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + si = isc__mem_allocateunlocked((isc_mem_t *)ctx, size); + } else { + si = isc__mem_allocateunlocked((isc_mem_t *)ctx, size); + MCTXLOCK(ctx, &ctx->lock); + if (si != NULL) + mem_getstats(ctx, si[-1].u.size); + } + +#if ISC_MEM_TRACKLINES + ADD_TRACE(ctx, si, si[-1].u.size, file, line); +#endif + if (ctx->hi_water != 0U && ctx->inuse > ctx->hi_water && + !ctx->is_overmem) { + ctx->is_overmem = ISC_TRUE; + } + + if (ctx->hi_water != 0U && !ctx->hi_called && + ctx->inuse > ctx->hi_water) { + ctx->hi_called = ISC_TRUE; + call_water = ISC_TRUE; + } + if (ctx->inuse > ctx->maxinuse) { + ctx->maxinuse = ctx->inuse; + if (ctx->hi_water != 0U && ctx->inuse > ctx->hi_water && + (isc_mem_debugging & ISC_MEM_DEBUGUSAGE) != 0) + fprintf(stderr, "maxinuse = %lu\n", + (unsigned long)ctx->inuse); + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_HIWATER); + + return (si); +} + +ISC_MEMFUNC_SCOPE void * +isc___mem_reallocate(isc_mem_t *ctx0, void *ptr, size_t size FLARG) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + void *new_ptr = NULL; + size_t oldsize, copysize; + + REQUIRE(VALID_CONTEXT(ctx)); + + /* + * This function emulates the realloc(3) standard library function: + * - if size > 0, allocate new memory; and if ptr is non NULL, copy + * as much of the old contents to the new buffer and free the old one. + * Note that when allocation fails the original pointer is intact; + * the caller must free it. + * - if size is 0 and ptr is non NULL, simply free the given ptr. + * - this function returns: + * pointer to the newly allocated memory, or + * NULL if allocation fails or doesn't happen. + */ + if (size > 0U) { + new_ptr = isc__mem_allocate(ctx0, size FLARG_PASS); + if (new_ptr != NULL && ptr != NULL) { + oldsize = (((size_info *)ptr)[-1]).u.size; + INSIST(oldsize >= ALIGNMENT_SIZE); + oldsize -= ALIGNMENT_SIZE; + copysize = oldsize > size ? size : oldsize; + memcpy(new_ptr, ptr, copysize); + isc__mem_free(ctx0, ptr FLARG_PASS); + } + } else if (ptr != NULL) + isc__mem_free(ctx0, ptr FLARG_PASS); + + return (new_ptr); +} + +ISC_MEMFUNC_SCOPE void +isc___mem_free(isc_mem_t *ctx0, void *ptr FLARG) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + size_info *si; + size_t size; + isc_boolean_t call_water= ISC_FALSE; + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(ptr != NULL); + + if ((isc_mem_debugging & ISC_MEM_DEBUGCTX) != 0) { + si = &(((size_info *)ptr)[-2]); + REQUIRE(si->u.ctx == ctx); + size = si[1].u.size; + } else { + si = &(((size_info *)ptr)[-1]); + size = si->u.size; + } + + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(ctx, &ctx->lock); + mem_putunlocked(ctx, si, size); + } else { + mem_put(ctx, si, size); + MCTXLOCK(ctx, &ctx->lock); + mem_putstats(ctx, si, size); + } + + DELETE_TRACE(ctx, ptr, size, file, line); + + /* + * The check against ctx->lo_water == 0 is for the condition + * when the context was pushed over hi_water but then had + * isc_mem_setwater() called with 0 for hi_water and lo_water. + */ + if (ctx->is_overmem && + (ctx->inuse < ctx->lo_water || ctx->lo_water == 0U)) { + ctx->is_overmem = ISC_FALSE; + } + + if (ctx->hi_called && + (ctx->inuse < ctx->lo_water || ctx->lo_water == 0U)) { + ctx->hi_called = ISC_FALSE; + + if (ctx->water != NULL) + call_water = ISC_TRUE; + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (call_water) + (ctx->water)(ctx->water_arg, ISC_MEM_LOWATER); +} + + +/* + * Other useful things. + */ + +ISC_MEMFUNC_SCOPE char * +isc___mem_strdup(isc_mem_t *mctx0, const char *s FLARG) { + isc__mem_t *mctx = (isc__mem_t *)mctx0; + size_t len; + char *ns; + + REQUIRE(VALID_CONTEXT(mctx)); + REQUIRE(s != NULL); + + len = strlen(s); + + ns = isc___mem_allocate((isc_mem_t *)mctx, len + 1 FLARG_PASS); + + if (ns != NULL) + strncpy(ns, s, len + 1); + + return (ns); +} + +ISC_MEMFUNC_SCOPE void +isc__mem_setdestroycheck(isc_mem_t *ctx0, isc_boolean_t flag) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + ctx->checkfree = flag; + + MCTXUNLOCK(ctx, &ctx->lock); +} + +/* + * Quotas + */ + +ISC_MEMFUNC_SCOPE void +isc__mem_setquota(isc_mem_t *ctx0, size_t quota) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + ctx->quota = quota; + + MCTXUNLOCK(ctx, &ctx->lock); +} + +ISC_MEMFUNC_SCOPE size_t +isc__mem_getquota(isc_mem_t *ctx0) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + size_t quota; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + quota = ctx->quota; + + MCTXUNLOCK(ctx, &ctx->lock); + + return (quota); +} + +ISC_MEMFUNC_SCOPE size_t +isc__mem_inuse(isc_mem_t *ctx0) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + size_t inuse; + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + inuse = ctx->inuse; + + MCTXUNLOCK(ctx, &ctx->lock); + + return (inuse); +} + +ISC_MEMFUNC_SCOPE void +isc__mem_setwater(isc_mem_t *ctx0, isc_mem_water_t water, void *water_arg, + size_t hiwater, size_t lowater) +{ + isc__mem_t *ctx = (isc__mem_t *)ctx0; + isc_boolean_t callwater = ISC_FALSE; + isc_mem_water_t oldwater; + void *oldwater_arg; + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(hiwater >= lowater); + + MCTXLOCK(ctx, &ctx->lock); + oldwater = ctx->water; + oldwater_arg = ctx->water_arg; + if (water == NULL) { + callwater = ctx->hi_called; + ctx->water = NULL; + ctx->water_arg = NULL; + ctx->hi_water = 0; + ctx->lo_water = 0; + ctx->hi_called = ISC_FALSE; + } else { + if (ctx->hi_called && + (ctx->water != water || ctx->water_arg != water_arg || + ctx->inuse < lowater || lowater == 0U)) + callwater = ISC_TRUE; + ctx->water = water; + ctx->water_arg = water_arg; + ctx->hi_water = hiwater; + ctx->lo_water = lowater; + ctx->hi_called = ISC_FALSE; + } + MCTXUNLOCK(ctx, &ctx->lock); + + if (callwater && oldwater != NULL) + (oldwater)(oldwater_arg, ISC_MEM_LOWATER); +} + +ISC_MEMFUNC_SCOPE isc_boolean_t +isc__mem_isovermem(isc_mem_t *ctx0) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + + /* + * We don't bother to lock the context because 100% accuracy isn't + * necessary (and even if we locked the context the returned value + * could be different from the actual state when it's used anyway) + */ + return (ctx->is_overmem); +} + +ISC_MEMFUNC_SCOPE void +isc__mem_setname(isc_mem_t *ctx0, const char *name, void *tag) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + + LOCK(&ctx->lock); + memset(ctx->name, 0, sizeof(ctx->name)); + strncpy(ctx->name, name, sizeof(ctx->name) - 1); + ctx->tag = tag; + UNLOCK(&ctx->lock); +} + +ISC_MEMFUNC_SCOPE const char * +isc__mem_getname(isc_mem_t *ctx0) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + + return (ctx->name); +} + +ISC_MEMFUNC_SCOPE void * +isc__mem_gettag(isc_mem_t *ctx0) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + + return (ctx->tag); +} + +/* + * Memory pool stuff + */ + +ISC_MEMFUNC_SCOPE isc_result_t +isc__mempool_create(isc_mem_t *mctx0, size_t size, isc_mempool_t **mpctxp) { + isc__mem_t *mctx = (isc__mem_t *)mctx0; + isc__mempool_t *mpctx; + + REQUIRE(VALID_CONTEXT(mctx)); + REQUIRE(size > 0U); + REQUIRE(mpctxp != NULL && *mpctxp == NULL); + + /* + * Allocate space for this pool, initialize values, and if all works + * well, attach to the memory context. + */ + mpctx = isc_mem_get((isc_mem_t *)mctx, sizeof(isc__mempool_t)); + if (mpctx == NULL) + return (ISC_R_NOMEMORY); + + mpctx->common.methods = (isc_mempoolmethods_t *)&mempoolmethods; + mpctx->common.impmagic = MEMPOOL_MAGIC; + mpctx->common.magic = ISCAPI_MPOOL_MAGIC; + mpctx->lock = NULL; + mpctx->mctx = mctx; + mpctx->size = size; + mpctx->maxalloc = UINT_MAX; + mpctx->allocated = 0; + mpctx->freecount = 0; + mpctx->freemax = 1; + mpctx->fillcount = 1; + mpctx->gets = 0; +#if ISC_MEMPOOL_NAMES + mpctx->name[0] = 0; +#endif + mpctx->items = NULL; + + *mpctxp = (isc_mempool_t *)mpctx; + + MCTXLOCK(mctx, &mctx->lock); + ISC_LIST_INITANDAPPEND(mctx->pools, mpctx, link); + mctx->poolcnt++; + MCTXUNLOCK(mctx, &mctx->lock); + + return (ISC_R_SUCCESS); +} + +ISC_MEMFUNC_SCOPE void +isc__mempool_setname(isc_mempool_t *mpctx0, const char *name) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + + REQUIRE(name != NULL); + REQUIRE(VALID_MEMPOOL(mpctx)); + +#if ISC_MEMPOOL_NAMES + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + strncpy(mpctx->name, name, sizeof(mpctx->name) - 1); + mpctx->name[sizeof(mpctx->name) - 1] = '\0'; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +#else + UNUSED(mpctx); + UNUSED(name); +#endif +} + +ISC_MEMFUNC_SCOPE void +isc__mempool_destroy(isc_mempool_t **mpctxp) { + isc__mempool_t *mpctx; + isc__mem_t *mctx; + isc_mutex_t *lock; + element *item; + + REQUIRE(mpctxp != NULL); + mpctx = (isc__mempool_t *)*mpctxp; + REQUIRE(VALID_MEMPOOL(mpctx)); +#if ISC_MEMPOOL_NAMES + if (mpctx->allocated > 0) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc__mempool_destroy(): mempool %s " + "leaked memory", + mpctx->name); +#endif + REQUIRE(mpctx->allocated == 0); + + mctx = mpctx->mctx; + + lock = mpctx->lock; + + if (lock != NULL) + LOCK(lock); + + /* + * Return any items on the free list + */ + MCTXLOCK(mctx, &mctx->lock); + while (mpctx->items != NULL) { + INSIST(mpctx->freecount > 0); + mpctx->freecount--; + item = mpctx->items; + mpctx->items = item->next; + + if ((mctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + mem_putunlocked(mctx, item, mpctx->size); + } else { + mem_put(mctx, item, mpctx->size); + mem_putstats(mctx, item, mpctx->size); + } + } + MCTXUNLOCK(mctx, &mctx->lock); + + /* + * Remove our linked list entry from the memory context. + */ + MCTXLOCK(mctx, &mctx->lock); + ISC_LIST_UNLINK(mctx->pools, mpctx, link); + mctx->poolcnt--; + MCTXUNLOCK(mctx, &mctx->lock); + + mpctx->common.impmagic = 0; + mpctx->common.magic = 0; + + isc_mem_put((isc_mem_t *)mpctx->mctx, mpctx, sizeof(isc__mempool_t)); + + if (lock != NULL) + UNLOCK(lock); + + *mpctxp = NULL; +} + +ISC_MEMFUNC_SCOPE void +isc__mempool_associatelock(isc_mempool_t *mpctx0, isc_mutex_t *lock) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + + REQUIRE(VALID_MEMPOOL(mpctx)); + REQUIRE(mpctx->lock == NULL); + REQUIRE(lock != NULL); + + mpctx->lock = lock; +} + +ISC_MEMFUNC_SCOPE void * +isc___mempool_get(isc_mempool_t *mpctx0 FLARG) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + element *item; + isc__mem_t *mctx; + unsigned int i; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + mctx = mpctx->mctx; + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + /* + * Don't let the caller go over quota + */ + if (mpctx->allocated >= mpctx->maxalloc) { + item = NULL; + goto out; + } + + /* + * if we have a free list item, return the first here + */ + item = mpctx->items; + if (item != NULL) { + mpctx->items = item->next; + INSIST(mpctx->freecount > 0); + mpctx->freecount--; + mpctx->gets++; + mpctx->allocated++; + goto out; + } + + /* + * We need to dip into the well. Lock the memory context here and + * fill up our free list. + */ + MCTXLOCK(mctx, &mctx->lock); + for (i = 0; i < mpctx->fillcount; i++) { + if ((mctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + item = mem_getunlocked(mctx, mpctx->size); + } else { + item = mem_get(mctx, mpctx->size); + if (item != NULL) + mem_getstats(mctx, mpctx->size); + } + if (item == NULL) + break; + item->next = mpctx->items; + mpctx->items = item; + mpctx->freecount++; + } + MCTXUNLOCK(mctx, &mctx->lock); + + /* + * If we didn't get any items, return NULL. + */ + item = mpctx->items; + if (item == NULL) + goto out; + + mpctx->items = item->next; + mpctx->freecount--; + mpctx->gets++; + mpctx->allocated++; + + out: + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + +#if ISC_MEM_TRACKLINES + if (item != NULL) { + MCTXLOCK(mctx, &mctx->lock); + ADD_TRACE(mctx, item, mpctx->size, file, line); + MCTXUNLOCK(mctx, &mctx->lock); + } +#endif /* ISC_MEM_TRACKLINES */ + + return (item); +} + +ISC_MEMFUNC_SCOPE void +isc___mempool_put(isc_mempool_t *mpctx0, void *mem FLARG) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + isc__mem_t *mctx; + element *item; + + REQUIRE(VALID_MEMPOOL(mpctx)); + REQUIRE(mem != NULL); + + mctx = mpctx->mctx; + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + INSIST(mpctx->allocated > 0); + mpctx->allocated--; + +#if ISC_MEM_TRACKLINES + MCTXLOCK(mctx, &mctx->lock); + DELETE_TRACE(mctx, mem, mpctx->size, file, line); + MCTXUNLOCK(mctx, &mctx->lock); +#endif /* ISC_MEM_TRACKLINES */ + + /* + * If our free list is full, return this to the mctx directly. + */ + if (mpctx->freecount >= mpctx->freemax) { + if ((mctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + MCTXLOCK(mctx, &mctx->lock); + mem_putunlocked(mctx, mem, mpctx->size); + MCTXUNLOCK(mctx, &mctx->lock); + } else { + mem_put(mctx, mem, mpctx->size); + MCTXLOCK(mctx, &mctx->lock); + mem_putstats(mctx, mem, mpctx->size); + MCTXUNLOCK(mctx, &mctx->lock); + } + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + return; + } + + /* + * Otherwise, attach it to our free list and bump the counter. + */ + mpctx->freecount++; + item = (element *)mem; + item->next = mpctx->items; + mpctx->items = item; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +/* + * Quotas + */ + +ISC_MEMFUNC_SCOPE void +isc__mempool_setfreemax(isc_mempool_t *mpctx0, unsigned int limit) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + mpctx->freemax = limit; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getfreemax(isc_mempool_t *mpctx0) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + unsigned int freemax; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + freemax = mpctx->freemax; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (freemax); +} + +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getfreecount(isc_mempool_t *mpctx0) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + unsigned int freecount; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + freecount = mpctx->freecount; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (freecount); +} + +ISC_MEMFUNC_SCOPE void +isc__mempool_setmaxalloc(isc_mempool_t *mpctx0, unsigned int limit) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + + REQUIRE(limit > 0); + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + mpctx->maxalloc = limit; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getmaxalloc(isc_mempool_t *mpctx0) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + unsigned int maxalloc; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + maxalloc = mpctx->maxalloc; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (maxalloc); +} + +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getallocated(isc_mempool_t *mpctx0) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + unsigned int allocated; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + allocated = mpctx->allocated; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (allocated); +} + +ISC_MEMFUNC_SCOPE void +isc__mempool_setfillcount(isc_mempool_t *mpctx0, unsigned int limit) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + + REQUIRE(limit > 0); + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + mpctx->fillcount = limit; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); +} + +ISC_MEMFUNC_SCOPE unsigned int +isc__mempool_getfillcount(isc_mempool_t *mpctx0) { + isc__mempool_t *mpctx = (isc__mempool_t *)mpctx0; + + unsigned int fillcount; + + REQUIRE(VALID_MEMPOOL(mpctx)); + + if (mpctx->lock != NULL) + LOCK(mpctx->lock); + + fillcount = mpctx->fillcount; + + if (mpctx->lock != NULL) + UNLOCK(mpctx->lock); + + return (fillcount); +} + +#ifdef USE_MEMIMPREGISTER +isc_result_t +isc__mem_register() { + return (isc_mem_register(isc__mem_create2)); +} +#endif + +#ifdef BIND9 +ISC_MEMFUNC_SCOPE void +isc__mem_printactive(isc_mem_t *ctx0, FILE *file) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + + REQUIRE(VALID_CONTEXT(ctx)); + REQUIRE(file != NULL); + +#if !ISC_MEM_TRACKLINES + UNUSED(ctx); + UNUSED(file); +#else + print_active(ctx, file); +#endif +} + +ISC_MEMFUNC_SCOPE void +isc__mem_printallactive(FILE *file) { +#if !ISC_MEM_TRACKLINES + UNUSED(file); +#else + isc__mem_t *ctx; + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + LOCK(&lock); + for (ctx = ISC_LIST_HEAD(contexts); + ctx != NULL; + ctx = ISC_LIST_NEXT(ctx, link)) { + fprintf(file, "context: %p\n", ctx); + print_active(ctx, file); + } + UNLOCK(&lock); +#endif +} + +ISC_MEMFUNC_SCOPE void +isc__mem_checkdestroyed(FILE *file) { + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + LOCK(&lock); + if (!ISC_LIST_EMPTY(contexts)) { +#if ISC_MEM_TRACKLINES + isc__mem_t *ctx; + + for (ctx = ISC_LIST_HEAD(contexts); + ctx != NULL; + ctx = ISC_LIST_NEXT(ctx, link)) { + fprintf(file, "context: %p\n", ctx); + print_active(ctx, file); + } + fflush(file); +#endif + INSIST(0); + } + UNLOCK(&lock); +} + +ISC_MEMFUNC_SCOPE unsigned int +isc_mem_references(isc_mem_t *ctx0) { + isc__mem_t *ctx = (isc__mem_t *)ctx0; + unsigned int references; + + REQUIRE(VALID_CONTEXT(ctx)); + + MCTXLOCK(ctx, &ctx->lock); + references = ctx->references; + MCTXUNLOCK(ctx, &ctx->lock); + + return (references); +} + +#ifdef HAVE_LIBXML2 + +typedef struct summarystat { + isc_uint64_t total; + isc_uint64_t inuse; + isc_uint64_t blocksize; + isc_uint64_t contextsize; +} summarystat_t; + +static void +renderctx(isc__mem_t *ctx, summarystat_t *summary, xmlTextWriterPtr writer) { + REQUIRE(VALID_CONTEXT(ctx)); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "context"); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "id"); + xmlTextWriterWriteFormatString(writer, "%p", ctx); + xmlTextWriterEndElement(writer); /* id */ + + if (ctx->name[0] != 0) { + xmlTextWriterStartElement(writer, ISC_XMLCHAR "name"); + xmlTextWriterWriteFormatString(writer, "%s", ctx->name); + xmlTextWriterEndElement(writer); /* name */ + } + + REQUIRE(VALID_CONTEXT(ctx)); + MCTXLOCK(ctx, &ctx->lock); + + summary->contextsize += sizeof(*ctx) + + (ctx->max_size + 1) * sizeof(struct stats) + + ctx->max_size * sizeof(element *) + + ctx->basic_table_count * sizeof(char *); +#if ISC_MEM_TRACKLINES + if (ctx->debuglist != NULL) { + summary->contextsize += + (ctx->max_size + 1) * sizeof(debuglist_t) + + ctx->debuglistcnt * sizeof(debuglink_t); + } +#endif + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", ctx->references); + xmlTextWriterEndElement(writer); /* references */ + + summary->total += ctx->total; + xmlTextWriterStartElement(writer, ISC_XMLCHAR "total"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->total); + xmlTextWriterEndElement(writer); /* total */ + + summary->inuse += ctx->inuse; + xmlTextWriterStartElement(writer, ISC_XMLCHAR "inuse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->inuse); + xmlTextWriterEndElement(writer); /* inuse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "maxinuse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->maxinuse); + xmlTextWriterEndElement(writer); /* maxinuse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "blocksize"); + if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0) { + summary->blocksize += ctx->basic_table_count * + NUM_BASIC_BLOCKS * ctx->mem_target; + xmlTextWriterWriteFormatString(writer, + "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t) + ctx->basic_table_count * + NUM_BASIC_BLOCKS * + ctx->mem_target); + } else + xmlTextWriterWriteFormatString(writer, "%s", "-"); + xmlTextWriterEndElement(writer); /* blocksize */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "pools"); + xmlTextWriterWriteFormatString(writer, "%u", ctx->poolcnt); + xmlTextWriterEndElement(writer); /* pools */ + summary->contextsize += ctx->poolcnt * sizeof(isc_mempool_t); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "hiwater"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->hi_water); + xmlTextWriterEndElement(writer); /* hiwater */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "lowater"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + (isc_uint64_t)ctx->lo_water); + xmlTextWriterEndElement(writer); /* lowater */ + + MCTXUNLOCK(ctx, &ctx->lock); + + xmlTextWriterEndElement(writer); /* context */ +} + +void +isc_mem_renderxml(xmlTextWriterPtr writer) { + isc__mem_t *ctx; + summarystat_t summary; + isc_uint64_t lost; + + memset(&summary, 0, sizeof(summary)); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "contexts"); + + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); + + LOCK(&lock); + lost = totallost; + for (ctx = ISC_LIST_HEAD(contexts); + ctx != NULL; + ctx = ISC_LIST_NEXT(ctx, link)) { + renderctx(ctx, &summary, writer); + } + UNLOCK(&lock); + + xmlTextWriterEndElement(writer); /* contexts */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "summary"); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "TotalUse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.total); + xmlTextWriterEndElement(writer); /* TotalUse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "InUse"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.inuse); + xmlTextWriterEndElement(writer); /* InUse */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "BlockSize"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.blocksize); + xmlTextWriterEndElement(writer); /* BlockSize */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "ContextSize"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + summary.contextsize); + xmlTextWriterEndElement(writer); /* ContextSize */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "Lost"); + xmlTextWriterWriteFormatString(writer, "%" ISC_PRINT_QUADFORMAT "u", + lost); + xmlTextWriterEndElement(writer); /* Lost */ + + xmlTextWriterEndElement(writer); /* summary */ +} + +#endif /* HAVE_LIBXML2 */ +#endif /* BIND9 */ diff --git a/contrib/ntp/lib/isc/mem_api.c b/contrib/ntp/lib/isc/mem_api.c new file mode 100644 index 000000000..85abb9b45 --- /dev/null +++ b/contrib/ntp/lib/isc/mem_api.c @@ -0,0 +1,303 @@ +/* + * Copyright (C) 2009, 2010 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mem_api.c,v 1.8 2010/08/12 21:30:26 jinmei Exp $ */ + +#include + +#include +#include +#include +#include + +#if ISC_MEM_TRACKLINES +#define FLARG_PASS , file, line +#define FLARG , const char *file, unsigned int line +#else +#define FLARG_PASS +#define FLARG +#endif + +static isc_mutex_t createlock; +static isc_once_t once = ISC_ONCE_INIT; +static isc_memcreatefunc_t mem_createfunc = NULL; + +static void +initialize(void) { + RUNTIME_CHECK(isc_mutex_init(&createlock) == ISC_R_SUCCESS); +} + +isc_result_t +isc_mem_register(isc_memcreatefunc_t createfunc) { + isc_result_t result = ISC_R_SUCCESS; + + RUNTIME_CHECK(isc_once_do(&once, initialize) == ISC_R_SUCCESS); + + LOCK(&createlock); + if (mem_createfunc == NULL) + mem_createfunc = createfunc; + else + result = ISC_R_EXISTS; + UNLOCK(&createlock); + + return (result); +} + +isc_result_t +isc_mem_create(size_t init_max_size, size_t target_size, isc_mem_t **mctxp) { + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(mem_createfunc != NULL); + result = (*mem_createfunc)(init_max_size, target_size, mctxp, + ISC_MEMFLAG_DEFAULT); + + UNLOCK(&createlock); + + return (result); +} + +isc_result_t +isc_mem_create2(size_t init_max_size, size_t target_size, isc_mem_t **mctxp, + unsigned int flags) +{ + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(mem_createfunc != NULL); + result = (*mem_createfunc)(init_max_size, target_size, mctxp, flags); + + UNLOCK(&createlock); + + return (result); +} + +void +isc_mem_attach(isc_mem_t *source, isc_mem_t **targetp) { + REQUIRE(ISCAPI_MCTX_VALID(source)); + REQUIRE(targetp != NULL && *targetp == NULL); + + source->methods->attach(source, targetp); + + ENSURE(*targetp == source); +} + +void +isc_mem_detach(isc_mem_t **mctxp) { + REQUIRE(mctxp != NULL && ISCAPI_MCTX_VALID(*mctxp)); + + (*mctxp)->methods->detach(mctxp); + + ENSURE(*mctxp == NULL); +} + +void +isc_mem_destroy(isc_mem_t **mctxp) { + REQUIRE(mctxp != NULL && ISCAPI_MCTX_VALID(*mctxp)); + + (*mctxp)->methods->destroy(mctxp); + + ENSURE(*mctxp == NULL); +} + +void * +isc__mem_get(isc_mem_t *mctx, size_t size FLARG) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (mctx->methods->memget(mctx, size FLARG_PASS)); +} + +void +isc__mem_put(isc_mem_t *mctx, void *ptr, size_t size FLARG) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + mctx->methods->memput(mctx, ptr, size FLARG_PASS); +} + +void +isc__mem_putanddetach(isc_mem_t **mctxp, void *ptr, size_t size FLARG) { + REQUIRE(mctxp != NULL && ISCAPI_MCTX_VALID(*mctxp)); + + (*mctxp)->methods->memputanddetach(mctxp, ptr, size FLARG_PASS); + + /* + * XXX: We cannot always ensure *mctxp == NULL here + * (see lib/isc/mem.c). + */ +} + +void * +isc__mem_allocate(isc_mem_t *mctx, size_t size FLARG) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (mctx->methods->memallocate(mctx, size FLARG_PASS)); +} + +void * +isc__mem_reallocate(isc_mem_t *mctx, void *ptr, size_t size FLARG) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (mctx->methods->memreallocate(mctx, ptr, size FLARG_PASS)); +} + +char * +isc__mem_strdup(isc_mem_t *mctx, const char *s FLARG) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (mctx->methods->memstrdup(mctx, s FLARG_PASS)); +} + +void +isc__mem_free(isc_mem_t *mctx, void *ptr FLARG) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + mctx->methods->memfree(mctx, ptr FLARG_PASS); +} + +void +isc_mem_setdestroycheck(isc_mem_t *mctx, isc_boolean_t flag) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + mctx->methods->setdestroycheck(mctx, flag); +} + +void +isc_mem_setwater(isc_mem_t *ctx, isc_mem_water_t water, void *water_arg, + size_t hiwater, size_t lowater) +{ + REQUIRE(ISCAPI_MCTX_VALID(ctx)); + + ctx->methods->setwater(ctx, water, water_arg, hiwater, lowater); +} + +void +isc_mem_waterack(isc_mem_t *ctx, int flag) { + REQUIRE(ISCAPI_MCTX_VALID(ctx)); + + ctx->methods->waterack(ctx, flag); +} + +size_t +isc_mem_inuse(isc_mem_t *mctx) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (mctx->methods->inuse(mctx)); +} + +isc_boolean_t +isc_mem_isovermem(isc_mem_t *mctx) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (mctx->methods->isovermem(mctx)); +} + +void +isc_mem_setname(isc_mem_t *mctx, const char *name, void *tag) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + UNUSED(name); + UNUSED(tag); + + return; +} + +const char * +isc_mem_getname(isc_mem_t *mctx) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (""); +} + +void * +isc_mem_gettag(isc_mem_t *mctx) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (NULL); +} + +isc_result_t +isc_mempool_create(isc_mem_t *mctx, size_t size, isc_mempool_t **mpctxp) { + REQUIRE(ISCAPI_MCTX_VALID(mctx)); + + return (mctx->methods->mpcreate(mctx, size, mpctxp)); +} + +void +isc_mempool_destroy(isc_mempool_t **mpctxp) { + REQUIRE(mpctxp != NULL && ISCAPI_MPOOL_VALID(*mpctxp)); + + (*mpctxp)->methods->destroy(mpctxp); + + ENSURE(*mpctxp == NULL); +} + +void * +isc__mempool_get(isc_mempool_t *mpctx FLARG) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + return (mpctx->methods->get(mpctx FLARG_PASS)); +} + +void +isc__mempool_put(isc_mempool_t *mpctx, void *mem FLARG) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + mpctx->methods->put(mpctx, mem FLARG_PASS); +} + +unsigned int +isc_mempool_getallocated(isc_mempool_t *mpctx) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + return (mpctx->methods->getallocated(mpctx)); +} + +void +isc_mempool_setmaxalloc(isc_mempool_t *mpctx, unsigned int limit) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + mpctx->methods->setmaxalloc(mpctx, limit); +} + +void +isc_mempool_setfreemax(isc_mempool_t *mpctx, unsigned int limit) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + mpctx->methods->setfreemax(mpctx, limit); +} + +void +isc_mempool_setname(isc_mempool_t *mpctx, const char *name) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + mpctx->methods->setname(mpctx, name); +} + +void +isc_mempool_associatelock(isc_mempool_t *mpctx, isc_mutex_t *lock) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + mpctx->methods->associatelock(mpctx, lock); +} + +void +isc_mempool_setfillcount(isc_mempool_t *mpctx, unsigned int limit) { + REQUIRE(ISCAPI_MPOOL_VALID(mpctx)); + + mpctx->methods->setfillcount(mpctx, limit); +} diff --git a/contrib/ntp/lib/isc/mips/include/isc/atomic.h b/contrib/ntp/lib/isc/mips/include/isc/atomic.h new file mode 100644 index 000000000..bb739f740 --- /dev/null +++ b/contrib/ntp/lib/isc/mips/include/isc/atomic.h @@ -0,0 +1,98 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.3 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + */ +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, int val) { + isc_int32_t orig; + + /* add is a cheat, since MIPS has no mov instruction */ + __asm__ volatile ( + "1:" + "ll $3, %1\n" + "add %0, $0, $3\n" + "add $3, $3, %2\n" + "sc $3, %1\n" + "beq $3, 0, 1b" + : "=&r"(orig) + : "m"(*p), "r"(val) + : "memory", "$3" + ); + + return (orig); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + __asm__ volatile ( + "1:" + "ll $3, %0\n" + "add $3, $0, %1\n" + "sc $3, %0\n" + "beq $3, 0, 1b" + : + : "m"(*p), "r"(val) + : "memory", "$3" + ); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, int cmpval, int val) { + isc_int32_t orig; + + __asm__ volatile( + "1:" + "ll $3, %1\n" + "add %0, $0, $3\n" + "bne $3, %2, 2f\n" + "add $3, $0, %3\n" + "sc $3, %1\n" + "beq $3, 0, 1b\n" + "2:" + : "=&r"(orig) + : "m"(*p), "r"(cmpval), "r"(val) + : "memory", "$3" + ); + + return (orig); +} + +#else /* !ISC_PLATFORM_USEGCCASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/lib/isc/mutexblock.c b/contrib/ntp/lib/isc/mutexblock.c new file mode 100644 index 000000000..d41e9d28d --- /dev/null +++ b/contrib/ntp/lib/isc/mutexblock.c @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include + +isc_result_t +isc_mutexblock_init(isc_mutex_t *block, unsigned int count) { + isc_result_t result; + unsigned int i; + + for (i = 0; i < count; i++) { + result = isc_mutex_init(&block[i]); + if (result != ISC_R_SUCCESS) { + while (i > 0U) { + i--; + DESTROYLOCK(&block[i]); + } + return (result); + } + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_mutexblock_destroy(isc_mutex_t *block, unsigned int count) { + isc_result_t result; + unsigned int i; + + for (i = 0; i < count; i++) { + result = isc_mutex_destroy(&block[i]); + if (result != ISC_R_SUCCESS) + return (result); + } + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/libisc/netaddr.c b/contrib/ntp/lib/isc/netaddr.c similarity index 75% rename from contrib/ntp/libisc/netaddr.c rename to contrib/ntp/lib/isc/netaddr.c index 1fcd1027b..457576b77 100644 --- a/contrib/ntp/libisc/netaddr.c +++ b/contrib/ntp/lib/isc/netaddr.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007, 2010-2012 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,11 +15,11 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: netaddr.c,v 1.18.12.9 2004/05/15 03:46:12 jinmei Exp $ */ +/* $Id$ */ -#include +/*! \file */ -#define ISC_ONLY_IPV6 +#include #include @@ -31,6 +31,7 @@ #include #include #include +#include "ntp_stdlib.h" /* NTP change for strlcpy, strlcat */ isc_boolean_t isc_netaddr_equal(const isc_netaddr_t *a, const isc_netaddr_t *b) { @@ -53,6 +54,12 @@ isc_netaddr_equal(const isc_netaddr_t *a, const isc_netaddr_t *b) { a->zone != b->zone) return (ISC_FALSE); break; +#ifdef ISC_PLATFORM_HAVESYSUNH + case AF_UNIX: + if (strcmp(a->type.un, b->type.un) != 0) + return (ISC_FALSE); + break; +#endif default: return (ISC_FALSE); } @@ -63,17 +70,17 @@ isc_boolean_t isc_netaddr_eqprefix(const isc_netaddr_t *a, const isc_netaddr_t *b, unsigned int prefixlen) { - const unsigned char *pa, *pb; - unsigned int ipabytes; /* Length of whole IP address in bytes */ - unsigned int nbytes; /* Number of significant whole bytes */ - unsigned int nbits; /* Number of significant leftover bits */ + const unsigned char *pa = NULL, *pb = NULL; + unsigned int ipabytes = 0; /* Length of whole IP address in bytes */ + unsigned int nbytes; /* Number of significant whole bytes */ + unsigned int nbits; /* Number of significant leftover bits */ REQUIRE(a != NULL && b != NULL); if (a->family != b->family) return (ISC_FALSE); - if (a->zone != b->zone) + if (a->zone != b->zone && b->zone != 0) return (ISC_FALSE); switch (a->family) { @@ -88,8 +95,6 @@ isc_netaddr_eqprefix(const isc_netaddr_t *a, const isc_netaddr_t *b, ipabytes = 16; break; default: - pa = pb = NULL; /* Avoid silly compiler warning. */ - ipabytes = 0; /* Ditto. */ return (ISC_FALSE); } @@ -137,6 +142,16 @@ isc_netaddr_totext(const isc_netaddr_t *netaddr, isc_buffer_t *target) { case AF_INET6: type = &netaddr->type.in6; break; +#ifdef ISC_PLATFORM_HAVESYSUNH + case AF_UNIX: + alen = strlen(netaddr->type.un); + if (alen > isc_buffer_availablelength(target)) + return (ISC_R_NOSPACE); + isc_buffer_putmem(target, + (const unsigned char *)(netaddr->type.un), + alen); + return (ISC_R_SUCCESS); +#endif default: return (ISC_R_FAILURE); } @@ -172,6 +187,9 @@ isc_netaddr_format(const isc_netaddr_t *na, char *array, unsigned int size) { isc_buffer_init(&buf, array, size); result = isc_netaddr_totext(na, &buf); + if (size == 0) + return; + /* * Null terminate. */ @@ -184,17 +202,53 @@ isc_netaddr_format(const isc_netaddr_t *na, char *array, unsigned int size) { if (result != ISC_R_SUCCESS) { snprintf(array, size, + "<%s %u>", isc_msgcat_get(isc_msgcat, ISC_MSGSET_NETADDR, ISC_MSG_UNKNOWNADDR, - ""), + "unknown address, family"), na->family); array[size - 1] = '\0'; } } + +isc_result_t +isc_netaddr_prefixok(const isc_netaddr_t *na, unsigned int prefixlen) { + static const unsigned char zeros[16] = { 0 }; + unsigned int nbits, nbytes, ipbytes = 0; + const unsigned char *p; + + switch (na->family) { + case AF_INET: + p = (const unsigned char *) &na->type.in; + ipbytes = 4; + if (prefixlen > 32) + return (ISC_R_RANGE); + break; + case AF_INET6: + p = (const unsigned char *) &na->type.in6; + ipbytes = 16; + if (prefixlen > 128) + return (ISC_R_RANGE); + break; + default: + return (ISC_R_NOTIMPLEMENTED); + } + nbytes = prefixlen / 8; + nbits = prefixlen % 8; + if (nbits != 0) { + if ((p[nbytes] & (0xff>>nbits)) != 0U) + return (ISC_R_FAILURE); + nbytes++; + } + if (memcmp(p + nbytes, zeros, ipbytes - nbytes) != 0) + return (ISC_R_FAILURE); + return (ISC_R_SUCCESS); +} + isc_result_t isc_netaddr_masktoprefixlen(const isc_netaddr_t *s, unsigned int *lenp) { - unsigned int nbits, nbytes, ipbytes, i; + unsigned int nbits = 0, nbytes = 0, ipbytes = 0, i; const unsigned char *p; switch (s->family) { @@ -207,10 +261,8 @@ isc_netaddr_masktoprefixlen(const isc_netaddr_t *s, unsigned int *lenp) { ipbytes = 16; break; default: - ipbytes = 0; return (ISC_R_NOTIMPLEMENTED); } - nbytes = nbits = 0; for (i = 0; i < ipbytes; i++) { if (p[i] != 0xFF) break; @@ -248,6 +300,25 @@ isc_netaddr_fromin6(isc_netaddr_t *netaddr, const struct in6_addr *ina6) { netaddr->type.in6 = *ina6; } +isc_result_t +isc_netaddr_frompath(isc_netaddr_t *netaddr, const char *path) { +#ifdef ISC_PLATFORM_HAVESYSUNH + if (strlen(path) > sizeof(netaddr->type.un) - 1) + return (ISC_R_NOSPACE); + + memset(netaddr, 0, sizeof(*netaddr)); + netaddr->family = AF_UNIX; + strlcpy(netaddr->type.un, path, sizeof(netaddr->type.un)); + netaddr->zone = 0; + return (ISC_R_SUCCESS); +#else + UNUSED(netaddr); + UNUSED(path); + return (ISC_R_NOTIMPLEMENTED); +#endif +} + + void isc_netaddr_setzone(isc_netaddr_t *netaddr, isc_uint32_t zone) { /* we currently only support AF_INET6. */ @@ -278,6 +349,12 @@ isc_netaddr_fromsockaddr(isc_netaddr_t *t, const isc_sockaddr_t *s) { t->zone = 0; #endif break; +#ifdef ISC_PLATFORM_HAVESYSUNH + case AF_UNIX: + memcpy(t->type.un, s->type.sunix.sun_path, sizeof(t->type.un)); + t->zone = 0; + break; +#endif default: INSIST(0); } @@ -290,14 +367,12 @@ isc_netaddr_any(isc_netaddr_t *netaddr) { netaddr->type.in.s_addr = INADDR_ANY; } -#ifdef ISC_PLATFORM_HAVEIPV6 void isc_netaddr_any6(isc_netaddr_t *netaddr) { memset(netaddr, 0, sizeof(*netaddr)); netaddr->family = AF_INET6; netaddr->type.in6 = in6addr_any; } -#endif isc_boolean_t isc_netaddr_ismulticast(isc_netaddr_t *na) { @@ -345,7 +420,6 @@ isc_netaddr_issitelocal(isc_netaddr_t *na) { } } -#ifdef ISC_PLATFORM_HAVEIPV6 void isc_netaddr_fromv4mapped(isc_netaddr_t *t, const isc_netaddr_t *s) { isc_netaddr_t *src; @@ -360,4 +434,3 @@ isc_netaddr_fromv4mapped(isc_netaddr_t *t, const isc_netaddr_t *s) { memcpy(&t->type.in, (char *)&src->type.in6 + 12, 4); return; } -#endif diff --git a/contrib/ntp/libisc/netscope.c b/contrib/ntp/lib/isc/netscope.c similarity index 90% rename from contrib/ntp/libisc/netscope.c rename to contrib/ntp/lib/isc/netscope.c index f0bffc44a..9aa11db9a 100644 --- a/contrib/ntp/libisc/netscope.c +++ b/contrib/ntp/lib/isc/netscope.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2002 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,9 +15,11 @@ * PERFORMANCE OF THIS SOFTWARE. */ +/*! \file */ + #if defined(LIBC_SCCS) && !defined(lint) static char rcsid[] = - "$Id: netscope.c,v 1.5.142.7 2004/03/12 10:31:26 marka Exp $"; + "$Id: netscope.c,v 1.13 2007/06/19 23:47:17 tbox Exp $"; #endif /* LIBC_SCCS and not lint */ #include diff --git a/contrib/ntp/libisc/msgcat.c b/contrib/ntp/lib/isc/nls/msgcat.c similarity index 76% rename from contrib/ntp/libisc/msgcat.c rename to contrib/ntp/lib/isc/nls/msgcat.c index 8253a0613..3d6b6764d 100644 --- a/contrib/ntp/libisc/msgcat.c +++ b/contrib/ntp/lib/isc/nls/msgcat.c @@ -1,30 +1,31 @@ /* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: msgcat.c,v 1.12 2001/11/30 01:59:39 gson Exp $ */ +/* $Id: msgcat.c,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ -/* - * Principal Author: Bob Halley +/*! \file msgcat.c + * + * \author Principal Author: Bob Halley */ #include +#include #include -#include #include #include diff --git a/contrib/ntp/lib/isc/noatomic/include/isc/atomic.h b/contrib/ntp/lib/isc/noatomic/include/isc/atomic.h new file mode 100644 index 000000000..942ba036e --- /dev/null +++ b/contrib/ntp/lib/isc/noatomic/include/isc/atomic.h @@ -0,0 +1,24 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.4 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +/* This file is inherently empty. */ + +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/lib/isc/nothreads/condition.c b/contrib/ntp/lib/isc/nothreads/condition.c new file mode 100644 index 000000000..9be8f835f --- /dev/null +++ b/contrib/ntp/lib/isc/nothreads/condition.c @@ -0,0 +1,24 @@ +/* + * Copyright (C) 2004, 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.c,v 1.10 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include + +EMPTY_TRANSLATION_UNIT diff --git a/contrib/ntp/lib/isc/nothreads/include/isc/condition.h b/contrib/ntp/lib/isc/nothreads/include/isc/condition.h new file mode 100644 index 000000000..b269f82fc --- /dev/null +++ b/contrib/ntp/lib/isc/nothreads/include/isc/condition.h @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ + +/* + * This provides a limited subset of the isc_condition_t + * functionality for use by single-threaded programs that + * need to block waiting for events. Only a single + * call to isc_condition_wait() may be blocked at any given + * time, and the _waituntil and _broadcast functions are not + * supported. This is intended primarily for use by the omapi + * library, and may go away once omapi goes away. Use for + * other purposes is strongly discouraged. + */ + +#ifndef ISC_CONDITION_H +#define ISC_CONDITION_H 1 + +#include + +typedef int isc_condition_t; + +isc_result_t isc__nothread_wait_hack(isc_condition_t *cp, isc_mutex_t *mp); +isc_result_t isc__nothread_signal_hack(isc_condition_t *cp); + +#define isc_condition_init(cp) \ + (*(cp) = 0, ISC_R_SUCCESS) + +#define isc_condition_wait(cp, mp) \ + isc__nothread_wait_hack(cp, mp) + +#define isc_condition_waituntil(cp, mp, tp) \ + ((void)(cp), (void)(mp), (void)(tp), ISC_R_NOTIMPLEMENTED) + +#define isc_condition_signal(cp) \ + isc__nothread_signal_hack(cp) + +#define isc_condition_broadcast(cp) \ + ((void)(cp), ISC_R_NOTIMPLEMENTED) + +#define isc_condition_destroy(cp) \ + (*(cp) == 0 ? (*(cp) = -1, ISC_R_SUCCESS) : ISC_R_UNEXPECTED) + +#endif /* ISC_CONDITION_H */ diff --git a/contrib/ntp/include/isc/mutex.h b/contrib/ntp/lib/isc/nothreads/include/isc/mutex.h similarity index 57% rename from contrib/ntp/include/isc/mutex.h rename to contrib/ntp/lib/isc/nothreads/include/isc/mutex.h index fd6f3ec5e..1f2187b8b 100644 --- a/contrib/ntp/include/isc/mutex.h +++ b/contrib/ntp/lib/isc/nothreads/include/isc/mutex.h @@ -1,21 +1,21 @@ /* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2000, 2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: mutex.h,v 1.3 2001/01/09 21:57:55 bwelling Exp $ */ +/* $Id: mutex.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ #ifndef ISC_MUTEX_H #define ISC_MUTEX_H 1 diff --git a/contrib/ntp/lib/isc/nothreads/include/isc/once.h b/contrib/ntp/lib/isc/nothreads/include/isc/once.h new file mode 100644 index 000000000..ab705a4a4 --- /dev/null +++ b/contrib/ntp/lib/isc/nothreads/include/isc/once.h @@ -0,0 +1,32 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: once.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ONCE_H +#define ISC_ONCE_H 1 + +#include + +typedef isc_boolean_t isc_once_t; + +#define ISC_ONCE_INIT ISC_FALSE + +#define isc_once_do(op, f) \ + (!*(op) ? (f(), *(op) = ISC_TRUE, ISC_R_SUCCESS) : ISC_R_SUCCESS) + +#endif /* ISC_ONCE_H */ diff --git a/contrib/ntp/lib/isc/nothreads/include/isc/thread.h b/contrib/ntp/lib/isc/nothreads/include/isc/thread.h new file mode 100644 index 000000000..313bc5f95 --- /dev/null +++ b/contrib/ntp/lib/isc/nothreads/include/isc/thread.h @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.h,v 1.6 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_THREAD_H +#define ISC_THREAD_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +void +isc_thread_setconcurrency(unsigned int level); + +#define isc_thread_self() ((unsigned long)0) + +ISC_LANG_ENDDECLS + +#endif /* ISC_THREAD_H */ diff --git a/contrib/ntp/lib/isc/nothreads/mutex.c b/contrib/ntp/lib/isc/nothreads/mutex.c new file mode 100644 index 000000000..50ba0f4d6 --- /dev/null +++ b/contrib/ntp/lib/isc/nothreads/mutex.c @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2004, 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.c,v 1.10 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include + +EMPTY_TRANSLATION_UNIT + diff --git a/contrib/ntp/lib/isc/nothreads/thread.c b/contrib/ntp/lib/isc/nothreads/thread.c new file mode 100644 index 000000000..9075e2551 --- /dev/null +++ b/contrib/ntp/lib/isc/nothreads/thread.c @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.c,v 1.5 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include +#include + +void +isc_thread_setconcurrency(unsigned int level) { + UNUSED(level); +} diff --git a/contrib/ntp/lib/isc/ondestroy.c b/contrib/ntp/lib/isc/ondestroy.c new file mode 100644 index 000000000..32a75e1f9 --- /dev/null +++ b/contrib/ntp/lib/isc/ondestroy.c @@ -0,0 +1,85 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ondestroy.c,v 1.16 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +#define ONDESTROY_MAGIC ISC_MAGIC('D', 'e', 'S', 't') +#define VALID_ONDESTROY(s) ISC_MAGIC_VALID(s, ONDESTROY_MAGIC) + +void +isc_ondestroy_init(isc_ondestroy_t *ondest) { + ondest->magic = ONDESTROY_MAGIC; + ISC_LIST_INIT(ondest->events); +} + +isc_result_t +isc_ondestroy_register(isc_ondestroy_t *ondest, isc_task_t *task, + isc_event_t **eventp) +{ + isc_event_t *theevent; + isc_task_t *thetask = NULL; + + REQUIRE(VALID_ONDESTROY(ondest)); + REQUIRE(task != NULL); + REQUIRE(eventp != NULL); + + theevent = *eventp; + + REQUIRE(theevent != NULL); + + isc_task_attach(task, &thetask); + + theevent->ev_sender = thetask; + + ISC_LIST_APPEND(ondest->events, theevent, ev_link); + + return (ISC_R_SUCCESS); +} + +void +isc_ondestroy_notify(isc_ondestroy_t *ondest, void *sender) { + isc_event_t *eventp; + isc_task_t *task; + + REQUIRE(VALID_ONDESTROY(ondest)); + + eventp = ISC_LIST_HEAD(ondest->events); + while (eventp != NULL) { + ISC_LIST_UNLINK(ondest->events, eventp, ev_link); + + task = eventp->ev_sender; + eventp->ev_sender = sender; + + isc_task_sendanddetach(&task, &eventp); + + eventp = ISC_LIST_HEAD(ondest->events); + } +} + + diff --git a/contrib/ntp/lib/isc/parseint.c b/contrib/ntp/lib/isc/parseint.c new file mode 100644 index 000000000..266d44cec --- /dev/null +++ b/contrib/ntp/lib/isc/parseint.c @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: parseint.c,v 1.8 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include +#include +#include + +isc_result_t +isc_parse_uint32(isc_uint32_t *uip, const char *string, int base) { + unsigned long n; + char *e; + if (! isalnum((unsigned char)(string[0]))) + return (ISC_R_BADNUMBER); + errno = 0; + n = strtoul(string, &e, base); + if (*e != '\0') + return (ISC_R_BADNUMBER); + if (n == ULONG_MAX && errno == ERANGE) + return (ISC_R_RANGE); + *uip = n; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_parse_uint16(isc_uint16_t *uip, const char *string, int base) { + isc_uint32_t val; + isc_result_t result; + result = isc_parse_uint32(&val, string, base); + if (result != ISC_R_SUCCESS) + return (result); + if (val > 0xFFFF) + return (ISC_R_RANGE); + *uip = (isc_uint16_t) val; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_parse_uint8(isc_uint8_t *uip, const char *string, int base) { + isc_uint32_t val; + isc_result_t result; + result = isc_parse_uint32(&val, string, base); + if (result != ISC_R_SUCCESS) + return (result); + if (val > 0xFF) + return (ISC_R_RANGE); + *uip = (isc_uint8_t) val; + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/portset.c b/contrib/ntp/lib/isc/portset.c new file mode 100644 index 000000000..471ca8e8d --- /dev/null +++ b/contrib/ntp/lib/isc/portset.c @@ -0,0 +1,143 @@ +/* + * Copyright (C) 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: portset.c,v 1.4 2008/06/24 23:24:35 marka Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include + +#define ISC_PORTSET_BUFSIZE (65536 / (sizeof(isc_uint32_t) * 8)) + +/*% + * Internal representation of portset. It's an array of 32-bit integers, each + * bit corresponding to a single port in the ascending order. For example, + * the second most significant bit of buf[0] corresponds to port 1. + */ +struct isc_portset { + unsigned int nports; /*%< number of ports in the set */ + isc_uint32_t buf[ISC_PORTSET_BUFSIZE]; +}; + +static inline isc_boolean_t +portset_isset(isc_portset_t *portset, in_port_t port) { + return (ISC_TF((portset->buf[port >> 5] & (1 << (port & 31))) != 0)); +} + +static inline void +portset_add(isc_portset_t *portset, in_port_t port) { + if (!portset_isset(portset, port)) { + portset->nports++; + portset->buf[port >> 5] |= (1 << (port & 31)); + } +} + +static inline void +portset_remove(isc_portset_t *portset, in_port_t port) { + if (portset_isset(portset, port)) { + portset->nports--; + portset->buf[port >> 5] &= ~(1 << (port & 31)); + } +} + +isc_result_t +isc_portset_create(isc_mem_t *mctx, isc_portset_t **portsetp) { + isc_portset_t *portset; + + REQUIRE(portsetp != NULL && *portsetp == NULL); + + portset = isc_mem_get(mctx, sizeof(*portset)); + if (portset == NULL) + return (ISC_R_NOMEMORY); + + /* Make the set 'empty' by default */ + memset(portset, 0, sizeof(*portset)); + *portsetp = portset; + + return (ISC_R_SUCCESS); +} + +void +isc_portset_destroy(isc_mem_t *mctx, isc_portset_t **portsetp) { + isc_portset_t *portset; + + REQUIRE(portsetp != NULL); + portset = *portsetp; + + isc_mem_put(mctx, portset, sizeof(*portset)); +} + +isc_boolean_t +isc_portset_isset(isc_portset_t *portset, in_port_t port) { + REQUIRE(portset != NULL); + + return (portset_isset(portset, port)); +} + +unsigned int +isc_portset_nports(isc_portset_t *portset) { + REQUIRE(portset != NULL); + + return (portset->nports); +} + +void +isc_portset_add(isc_portset_t *portset, in_port_t port) { + REQUIRE(portset != NULL); + + portset_add(portset, port); +} + +void +isc_portset_remove(isc_portset_t *portset, in_port_t port) { + portset_remove(portset, port); +} + +void +isc_portset_addrange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi) +{ + in_port_t p; + + REQUIRE(portset != NULL); + REQUIRE(port_lo <= port_hi); + + p = port_lo; + do { + portset_add(portset, p); + } while (p++ < port_hi); +} + +void +isc_portset_removerange(isc_portset_t *portset, in_port_t port_lo, + in_port_t port_hi) +{ + in_port_t p; + + REQUIRE(portset != NULL); + REQUIRE(port_lo <= port_hi); + + p = port_lo; + do { + portset_remove(portset, p); + } while (p++ < port_hi); +} diff --git a/contrib/ntp/lib/isc/powerpc/include/isc/atomic.h b/contrib/ntp/lib/isc/powerpc/include/isc/atomic.h new file mode 100644 index 000000000..030007f34 --- /dev/null +++ b/contrib/ntp/lib/isc/powerpc/include/isc/atomic.h @@ -0,0 +1,197 @@ +/* + * Copyright (C) 2005, 2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +/*!\file + * static inline isc_int32_t + * isc_atomic_xadd(isc_int32_t *p, isc_int32_t val); + * + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + * + * static inline void + * isc_atomic_store(void *p, isc_int32_t val); + * + * This routine atomically stores the value 'val' in 'p'. + * + * static inline isc_int32_t + * isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val); + * + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ + +#if defined(_AIX) + +#include + +#define isc_atomic_store(p, v) _clear_lock(p, v) + +#ifdef __GNUC__ +static inline isc_int32_t +#else +static isc_int32_t +#endif +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + int ret; + +#ifdef __GNUC__ + asm("ics"); +#else + __isync(); +#endif + + ret = fetch_and_add((atomic_p)p, (int)val); + +#ifdef __GNUC__ + asm("ics"); +#else + __isync(); +#endif + + return (ret); +} + +#ifdef __GNUC__ +static inline int +#else +static int +#endif +isc_atomic_cmpxchg(atomic_p p, int old, int new) { + int orig = old; + +#ifdef __GNUC__ + asm("ics"); +#else + __isync(); +#endif + if (compare_and_swap(p, &orig, new)) + orig = old; + +#ifdef __GNUC__ + asm("ics"); +#else + __isync(); +#endif + + return (orig); +} + +#elif defined(ISC_PLATFORM_USEGCCASM) || defined(ISC_PLATFORM_USEMACASM) +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t orig; + + __asm__ volatile ( +#ifdef ISC_PLATFORM_USEMACASM + "1:" + "lwarx r6, 0, %1\n" + "mr %0, r6\n" + "add r6, r6, %2\n" + "stwcx. r6, 0, %1\n" + "bne- 1b\n" + "sync" +#else + "1:" + "lwarx 6, 0, %1\n" + "mr %0, 6\n" + "add 6, 6, %2\n" + "stwcx. 6, 0, %1\n" + "bne- 1b\n" + "sync" +#endif + : "=&r"(orig) + : "r"(p), "r"(val) + : "r6", "memory" + ); + + return (orig); +} + +static inline void +isc_atomic_store(void *p, isc_int32_t val) { + __asm__ volatile ( +#ifdef ISC_PLATFORM_USEMACASM + "1:" + "lwarx r6, 0, %0\n" + "lwz r6, %1\n" + "stwcx. r6, 0, %0\n" + "bne- 1b\n" + "sync" +#else + "1:" + "lwarx 6, 0, %0\n" + "lwz 6, %1\n" + "stwcx. 6, 0, %0\n" + "bne- 1b\n" + "sync" +#endif + : + : "r"(p), "m"(val) + : "r6", "memory" + ); +} + +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + isc_int32_t orig; + + __asm__ volatile ( +#ifdef ISC_PLATFORM_USEMACASM + "1:" + "lwarx r6, 0, %1\n" + "mr %0,r6\n" + "cmpw r6, %2\n" + "bne 2f\n" + "mr r6, %3\n" + "stwcx. r6, 0, %1\n" + "bne- 1b\n" + "2:\n" + "sync" +#else + "1:" + "lwarx 6, 0, %1\n" + "mr %0,6\n" + "cmpw 6, %2\n" + "bne 2f\n" + "mr 6, %3\n" + "stwcx. 6, 0, %1\n" + "bne- 1b\n" + "2:\n" + "sync" +#endif + : "=&r" (orig) + : "r"(p), "r"(cmpval), "r"(val) + : "r6", "memory" + ); + + return (orig); +} + +#else + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/lib/isc/print.c b/contrib/ntp/lib/isc/print.c new file mode 100644 index 000000000..a5e5ba669 --- /dev/null +++ b/contrib/ntp/lib/isc/print.c @@ -0,0 +1,624 @@ +/* + * Copyright (C) 2004-2008, 2010 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: print.c,v 1.37 2010/10/18 23:47:08 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include /* for sprintf() */ +#include /* for strlen() */ + +#define ISC__PRINT_SOURCE /* Used to get the isc_print_* prototypes. */ + +#include +#include +#include +#include +#include +#include + +int +isc_print_sprintf(char *str, const char *format, ...) { + va_list ap; + + va_start(ap, format); + vsprintf(str, format, ap); + va_end(ap); + return (strlen(str)); +} + +/*! + * Return length of string that would have been written if not truncated. + */ + +int +isc_print_snprintf(char *str, size_t size, const char *format, ...) { + va_list ap; + int ret; + + va_start(ap, format); + ret = vsnprintf(str, size, format, ap); + va_end(ap); + return (ret); + +} + +/*! + * Return length of string that would have been written if not truncated. + */ + +int +isc_print_vsnprintf(char *str, size_t size, const char *format, va_list ap) { + int h; + int l; + int q; + int alt; + int zero; + int left; + int plus; + int space; + int neg; + isc_int64_t tmpi; + isc_uint64_t tmpui; + unsigned long width; + unsigned long precision; + unsigned int length; + char buf[1024]; + char c; + void *v; + char *save = str; + const char *cp; + const char *head; + int count = 0; + int pad; + int zeropad; + int dot; + double dbl; +#ifdef HAVE_LONG_DOUBLE + long double ldbl; +#endif + char fmt[32]; + + INSIST(str != NULL); + INSIST(format != NULL); + + while (*format != '\0') { + if (*format != '%') { + if (size > 1) { + *str++ = *format; + size--; + } + count++; + format++; + continue; + } + format++; + + /* + * Reset flags. + */ + dot = neg = space = plus = left = zero = alt = h = l = q = 0; + width = precision = 0; + head = ""; + length = pad = zeropad = 0; + + do { + if (*format == '#') { + alt = 1; + format++; + } else if (*format == '-') { + left = 1; + zero = 0; + format++; + } else if (*format == ' ') { + if (!plus) + space = 1; + format++; + } else if (*format == '+') { + plus = 1; + space = 0; + format++; + } else if (*format == '0') { + if (!left) + zero = 1; + format++; + } else + break; + } while (1); + + /* + * Width. + */ + if (*format == '*') { + width = va_arg(ap, int); + format++; + } else if (isdigit((unsigned char)*format)) { + char *e; + width = strtoul(format, &e, 10); + format = e; + } + + /* + * Precision. + */ + if (*format == '.') { + format++; + dot = 1; + if (*format == '*') { + precision = va_arg(ap, int); + format++; + } else if (isdigit((unsigned char)*format)) { + char *e; + precision = strtoul(format, &e, 10); + format = e; + } + } + + switch (*format) { + case '\0': + continue; + case '%': + if (size > 1) { + *str++ = *format; + size--; + } + count++; + break; + case 'q': + q = 1; + format++; + goto doint; + case 'h': + h = 1; + format++; + goto doint; + case 'l': + l = 1; + format++; + if (*format == 'l') { + q = 1; + format++; + } + goto doint; + case 'n': + case 'i': + case 'd': + case 'o': + case 'u': + case 'x': + case 'X': + doint: + if (precision != 0) + zero = 0; + switch (*format) { + case 'n': + if (h) { + short int *p; + p = va_arg(ap, short *); + REQUIRE(p != NULL); + *p = str - save; + } else if (l) { + long int *p; + p = va_arg(ap, long *); + REQUIRE(p != NULL); + *p = str - save; + } else { + int *p; + p = va_arg(ap, int *); + REQUIRE(p != NULL); + *p = str - save; + } + break; + case 'i': + case 'd': + if (q) + tmpi = va_arg(ap, isc_int64_t); + else if (l) + tmpi = va_arg(ap, long int); + else + tmpi = va_arg(ap, int); + if (tmpi < 0) { + head = "-"; + tmpui = -tmpi; + } else { + if (plus) + head = "+"; + else if (space) + head = " "; + else + head = ""; + tmpui = tmpi; + } + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lu", + (unsigned long)tmpui); + else { + unsigned long mid; + unsigned long lo; + unsigned long hi; + lo = tmpui % 1000000000; + tmpui /= 1000000000; + mid = tmpui % 1000000000; + hi = tmpui / 1000000000; + if (hi != 0) + sprintf(buf, "%lu", hi); + else + buf[0] = '\n'; + sprintf(buf + strlen(buf), "%lu", mid); + sprintf(buf + strlen(buf), "%lu", lo); + } + goto printint; + case 'o': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, long int); + else + tmpui = va_arg(ap, int); + if (tmpui <= 0xffffffffU) + sprintf(buf, alt ? "%#lo" : "%lo", + (unsigned long)tmpui); + else { + unsigned long mid; + unsigned long lo; + unsigned long hi; + lo = tmpui % 010000000000; + tmpui /= 010000000000; + mid = tmpui % 010000000000; + hi = tmpui / 010000000000; + if (hi != 0) { + sprintf(buf, + alt ? "%#lo" : "%lo", + hi); + sprintf(buf + strlen(buf), + "%lo", mid); + } else + sprintf(buf, + alt ? "%#lo" : "%lo", + mid); + sprintf(buf + strlen(buf), "%lo", lo); + } + goto printint; + case 'u': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, unsigned long int); + else + tmpui = va_arg(ap, unsigned int); + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lu", + (unsigned long)tmpui); + else { + unsigned long mid; + unsigned long lo; + unsigned long hi; + lo = tmpui % 1000000000; + tmpui /= 1000000000; + mid = tmpui % 1000000000; + hi = tmpui / 1000000000; + if (hi != 0) + sprintf(buf, "%lu", hi); + else + buf[0] = '\n'; + sprintf(buf + strlen(buf), "%lu", mid); + sprintf(buf + strlen(buf), "%lu", lo); + } + goto printint; + case 'x': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, unsigned long int); + else + tmpui = va_arg(ap, unsigned int); + if (alt) { + head = "0x"; + if (precision > 2) + precision -= 2; + } + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lx", + (unsigned long)tmpui); + else { + unsigned long hi = tmpui>>32; + unsigned long lo = tmpui & 0xffffffff; + sprintf(buf, "%lx", hi); + sprintf(buf + strlen(buf), "%lx", lo); + } + goto printint; + case 'X': + if (q) + tmpui = va_arg(ap, isc_uint64_t); + else if (l) + tmpui = va_arg(ap, unsigned long int); + else + tmpui = va_arg(ap, unsigned int); + if (alt) { + head = "0X"; + if (precision > 2) + precision -= 2; + } + if (tmpui <= 0xffffffffU) + sprintf(buf, "%lX", + (unsigned long)tmpui); + else { + unsigned long hi = tmpui>>32; + unsigned long lo = tmpui & 0xffffffff; + sprintf(buf, "%lX", hi); + sprintf(buf + strlen(buf), "%lX", lo); + } + goto printint; + printint: + if (precision != 0 || width != 0) { + length = strlen(buf); + if (length < precision) + zeropad = precision - length; + else if (length < width && zero) + zeropad = width - length; + if (width != 0) { + pad = width - length - + zeropad - strlen(head); + if (pad < 0) + pad = 0; + } + } + count += strlen(head) + strlen(buf) + pad + + zeropad; + if (!left) { + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + } + cp = head; + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (zeropad > 0 && size > 1) { + *str++ = '0'; + size--; + zeropad--; + } + cp = buf; + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + default: + break; + } + break; + case 's': + cp = va_arg(ap, char *); + REQUIRE(cp != NULL); + + if (precision != 0) { + /* + * cp need not be NULL terminated. + */ + const char *tp; + unsigned long n; + + n = precision; + tp = cp; + while (n != 0 && *tp != '\0') + n--, tp++; + length = precision - n; + } else { + length = strlen(cp); + } + if (width != 0) { + pad = width - length; + if (pad < 0) + pad = 0; + } + count += pad + length; + if (!left) + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + if (precision != 0) + while (precision > 0 && *cp != '\0' && + size > 1) { + *str++ = *cp++; + size--; + precision--; + } + else + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + case 'c': + c = va_arg(ap, int); + if (width > 0) { + count += width; + width--; + if (left && size > 1) { + *str++ = c; + size--; + } + while (width-- > 0 && size > 1) { + *str++ = ' '; + size--; + } + if (!left && size > 1) { + *str++ = c; + size--; + } + } else { + count++; + if (size > 1) { + *str++ = c; + size--; + } + } + break; + case 'p': + v = va_arg(ap, void *); + sprintf(buf, "%p", v); + length = strlen(buf); + if (precision > length) + zeropad = precision - length; + if (width > 0) { + pad = width - length - zeropad; + if (pad < 0) + pad = 0; + } + count += length + pad + zeropad; + if (!left) + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + cp = buf; + if (zeropad > 0 && buf[0] == '0' && + (buf[1] == 'x' || buf[1] == 'X')) { + if (size > 1) { + *str++ = *cp++; + size--; + } + if (size > 1) { + *str++ = *cp++; + size--; + } + while (zeropad > 0 && size > 1) { + *str++ = '0'; + size--; + zeropad--; + } + } + while (*cp != '\0' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + case 'D': /*deprecated*/ + INSIST("use %ld instead of %D" == NULL); + case 'O': /*deprecated*/ + INSIST("use %lo instead of %O" == NULL); + case 'U': /*deprecated*/ + INSIST("use %lu instead of %U" == NULL); + + case 'L': +#ifdef HAVE_LONG_DOUBLE + l = 1; +#else + INSIST("long doubles are not supported" == NULL); +#endif + /*FALLTHROUGH*/ + case 'e': + case 'E': + case 'f': + case 'g': + case 'G': + if (!dot) + precision = 6; + /* + * IEEE floating point. + * MIN 2.2250738585072014E-308 + * MAX 1.7976931348623157E+308 + * VAX floating point has a smaller range than IEEE. + * + * precisions > 324 don't make much sense. + * if we cap the precision at 512 we will not + * overflow buf. + */ + if (precision > 512) + precision = 512; + sprintf(fmt, "%%%s%s.%lu%s%c", alt ? "#" : "", + plus ? "+" : space ? " " : "", + precision, l ? "L" : "", *format); + switch (*format) { + case 'e': + case 'E': + case 'f': + case 'g': + case 'G': +#ifdef HAVE_LONG_DOUBLE + if (l) { + ldbl = va_arg(ap, long double); + sprintf(buf, fmt, ldbl); + } else +#endif + { + dbl = va_arg(ap, double); + sprintf(buf, fmt, dbl); + } + length = strlen(buf); + if (width > 0) { + pad = width - length; + if (pad < 0) + pad = 0; + } + count += length + pad; + if (!left) + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + cp = buf; + while (*cp != ' ' && size > 1) { + *str++ = *cp++; + size--; + } + while (pad > 0 && size > 1) { + *str++ = ' '; + size--; + pad--; + } + break; + default: + continue; + } + break; + default: + continue; + } + format++; + } + if (size > 0) + *str = '\0'; + return (count); +} diff --git a/contrib/ntp/lib/isc/pthreads/condition.c b/contrib/ntp/lib/isc/pthreads/condition.c new file mode 100644 index 000000000..50281a2b8 --- /dev/null +++ b/contrib/ntp/lib/isc/pthreads/condition.c @@ -0,0 +1,74 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.c,v 1.36 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include + +isc_result_t +isc_condition_waituntil(isc_condition_t *c, isc_mutex_t *m, isc_time_t *t) { + int presult; + isc_result_t result; + struct timespec ts; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(c != NULL && m != NULL && t != NULL); + + /* + * POSIX defines a timespec's tv_sec as time_t. + */ + result = isc_time_secondsastimet(t, &ts.tv_sec); + if (result != ISC_R_SUCCESS) + return (result); + + /*! + * POSIX defines a timespec's tv_nsec as long. isc_time_nanoseconds + * ensures its return value is < 1 billion, which will fit in a long. + */ + ts.tv_nsec = (long)isc_time_nanoseconds(t); + + do { +#if ISC_MUTEX_PROFILE + presult = pthread_cond_timedwait(c, &m->mutex, &ts); +#else + presult = pthread_cond_timedwait(c, m, &ts); +#endif + if (presult == 0) + return (ISC_R_SUCCESS); + if (presult == ETIMEDOUT) + return (ISC_R_TIMEDOUT); + } while (presult == EINTR); + + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "pthread_cond_timedwait() %s %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RETURNED, "returned"), + strbuf); + return (ISC_R_UNEXPECTED); +} diff --git a/contrib/ntp/lib/isc/pthreads/include/isc/condition.h b/contrib/ntp/lib/isc/pthreads/include/isc/condition.h new file mode 100644 index 000000000..04a61185d --- /dev/null +++ b/contrib/ntp/lib/isc/pthreads/include/isc/condition.h @@ -0,0 +1,65 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.h,v 1.26 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_CONDITION_H +#define ISC_CONDITION_H 1 + +/*! \file */ + +#include +#include +#include +#include + +typedef pthread_cond_t isc_condition_t; + +#define isc_condition_init(cp) \ + ((pthread_cond_init((cp), NULL) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#if ISC_MUTEX_PROFILE +#define isc_condition_wait(cp, mp) \ + ((pthread_cond_wait((cp), &((mp)->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#else +#define isc_condition_wait(cp, mp) \ + ((pthread_cond_wait((cp), (mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#define isc_condition_signal(cp) \ + ((pthread_cond_signal((cp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#define isc_condition_broadcast(cp) \ + ((pthread_cond_broadcast((cp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#define isc_condition_destroy(cp) \ + ((pthread_cond_destroy((cp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_condition_waituntil(isc_condition_t *, isc_mutex_t *, isc_time_t *); + +ISC_LANG_ENDDECLS + +#endif /* ISC_CONDITION_H */ diff --git a/contrib/ntp/lib/isc/pthreads/include/isc/mutex.h b/contrib/ntp/lib/isc/pthreads/include/isc/mutex.h new file mode 100644 index 000000000..dd7d32687 --- /dev/null +++ b/contrib/ntp/lib/isc/pthreads/include/isc/mutex.h @@ -0,0 +1,145 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.h,v 1.30 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_MUTEX_H +#define ISC_MUTEX_H 1 + +/*! \file */ + +#include +#include + +#include +#include /* for ISC_R_ codes */ + +ISC_LANG_BEGINDECLS + +/*! + * Supply mutex attributes that enable deadlock detection + * (helpful when debugging). This is system dependent and + * currently only supported on NetBSD. + */ +#if ISC_MUTEX_DEBUG && defined(__NetBSD__) && defined(PTHREAD_MUTEX_ERRORCHECK) +extern pthread_mutexattr_t isc__mutex_attrs; +#define ISC__MUTEX_ATTRS &isc__mutex_attrs +#else +#define ISC__MUTEX_ATTRS NULL +#endif + +/* XXX We could do fancier error handling... */ + +/*! + * Define ISC_MUTEX_PROFILE to turn on profiling of mutexes by line. When + * enabled, isc_mutex_stats() can be used to print a table showing the + * number of times each type of mutex was locked and the amount of time + * waiting to obtain the lock. + */ +#ifndef ISC_MUTEX_PROFILE +#define ISC_MUTEX_PROFILE 0 +#endif + +#if ISC_MUTEX_PROFILE +typedef struct isc_mutexstats isc_mutexstats_t; + +typedef struct { + pthread_mutex_t mutex; /*%< The actual mutex. */ + isc_mutexstats_t * stats; /*%< Mutex statistics. */ +} isc_mutex_t; +#else +typedef pthread_mutex_t isc_mutex_t; +#endif + + +#if ISC_MUTEX_PROFILE +#define isc_mutex_init(mp) \ + isc_mutex_init_profile((mp), __FILE__, __LINE__) +#else +#if ISC_MUTEX_DEBUG && defined(PTHREAD_MUTEX_ERRORCHECK) +#define isc_mutex_init(mp) \ + isc_mutex_init_errcheck((mp)) +#else +#define isc_mutex_init(mp) \ + isc__mutex_init((mp), __FILE__, __LINE__) +isc_result_t isc__mutex_init(isc_mutex_t *mp, const char *file, unsigned int line); +#endif +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_lock(mp) \ + isc_mutex_lock_profile((mp), __FILE__, __LINE__) +#else +#define isc_mutex_lock(mp) \ + ((pthread_mutex_lock((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_unlock(mp) \ + isc_mutex_unlock_profile((mp), __FILE__, __LINE__) +#else +#define isc_mutex_unlock(mp) \ + ((pthread_mutex_unlock((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_trylock(mp) \ + ((pthread_mutex_trylock((&(mp)->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_LOCKBUSY) +#else +#define isc_mutex_trylock(mp) \ + ((pthread_mutex_trylock((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_LOCKBUSY) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_destroy(mp) \ + ((pthread_mutex_destroy((&(mp)->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#else +#define isc_mutex_destroy(mp) \ + ((pthread_mutex_destroy((mp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) +#endif + +#if ISC_MUTEX_PROFILE +#define isc_mutex_stats(fp) isc_mutex_statsprofile(fp); +#else +#define isc_mutex_stats(fp) +#endif + +#if ISC_MUTEX_PROFILE + +isc_result_t +isc_mutex_init_profile(isc_mutex_t *mp, const char * _file, int _line); +isc_result_t +isc_mutex_lock_profile(isc_mutex_t *mp, const char * _file, int _line); +isc_result_t +isc_mutex_unlock_profile(isc_mutex_t *mp, const char * _file, int _line); + +void +isc_mutex_statsprofile(FILE *fp); + +isc_result_t +isc_mutex_init_errcheck(isc_mutex_t *mp); + +#endif /* ISC_MUTEX_PROFILE */ + +ISC_LANG_ENDDECLS +#endif /* ISC_MUTEX_H */ diff --git a/contrib/ntp/lib/isc/pthreads/include/isc/once.h b/contrib/ntp/lib/isc/pthreads/include/isc/once.h new file mode 100644 index 000000000..31d76fb6f --- /dev/null +++ b/contrib/ntp/lib/isc/pthreads/include/isc/once.h @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: once.h,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_ONCE_H +#define ISC_ONCE_H 1 + +/*! \file */ + +#include + +#include +#include + +typedef pthread_once_t isc_once_t; + +#ifdef ISC_PLATFORM_BRACEPTHREADONCEINIT +/*! + * This accomodates systems that define PTHRAD_ONCE_INIT improperly. + */ +#define ISC_ONCE_INIT { PTHREAD_ONCE_INIT } +#else +/*! + * This is the usual case. + */ +#define ISC_ONCE_INIT PTHREAD_ONCE_INIT +#endif + +/* XXX We could do fancier error handling... */ + +#define isc_once_do(op, f) \ + ((pthread_once((op), (f)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#endif /* ISC_ONCE_H */ diff --git a/contrib/ntp/lib/isc/pthreads/include/isc/thread.h b/contrib/ntp/lib/isc/pthreads/include/isc/thread.h new file mode 100644 index 000000000..7dcc9527c --- /dev/null +++ b/contrib/ntp/lib/isc/pthreads/include/isc/thread.h @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.h,v 1.26 2007/06/19 23:47:18 tbox Exp $ */ + +#ifndef ISC_THREAD_H +#define ISC_THREAD_H 1 + +/*! \file */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +typedef pthread_t isc_thread_t; +typedef void * isc_threadresult_t; +typedef void * isc_threadarg_t; +typedef isc_threadresult_t (*isc_threadfunc_t)(isc_threadarg_t); +typedef pthread_key_t isc_thread_key_t; + +isc_result_t +isc_thread_create(isc_threadfunc_t, isc_threadarg_t, isc_thread_t *); + +void +isc_thread_setconcurrency(unsigned int level); + +/* XXX We could do fancier error handling... */ + +#define isc_thread_join(t, rp) \ + ((pthread_join((t), (rp)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED) + +#define isc_thread_self \ + (unsigned long)pthread_self + +#define isc_thread_key_create pthread_key_create +#define isc_thread_key_getspecific pthread_getspecific +#define isc_thread_key_setspecific pthread_setspecific +#define isc_thread_key_delete pthread_key_delete + +ISC_LANG_ENDDECLS + +#endif /* ISC_THREAD_H */ diff --git a/contrib/ntp/lib/isc/pthreads/mutex.c b/contrib/ntp/lib/isc/pthreads/mutex.c new file mode 100644 index 000000000..62ad540a7 --- /dev/null +++ b/contrib/ntp/lib/isc/pthreads/mutex.c @@ -0,0 +1,284 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.c,v 1.18 2011/01/04 23:47:14 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include + +#include +#include +#include + +#if HAVE_PTHREADS < 5 /* HP-UX 10.20 has 4, needs this */ +# define pthread_mutex_init(m, a) \ + pthread_mutex_init(m, (a) \ + ? *(const pthread_mutexattr_t *)(a) \ + : pthread_mutexattr_default) +# define PTHREAD_MUTEX_RECURSIVE MUTEX_RECURSIVE_NP +# define pthread_mutexattr_settype pthread_mutexattr_setkind_np +#endif + +#if ISC_MUTEX_PROFILE + +/*@{*/ +/*% Operations on timevals; adapted from FreeBSD's sys/time.h */ +#define timevalclear(tvp) ((tvp)->tv_sec = (tvp)->tv_usec = 0) +#define timevaladd(vvp, uvp) \ + do { \ + (vvp)->tv_sec += (uvp)->tv_sec; \ + (vvp)->tv_usec += (uvp)->tv_usec; \ + if ((vvp)->tv_usec >= 1000000) { \ + (vvp)->tv_sec++; \ + (vvp)->tv_usec -= 1000000; \ + } \ + } while (0) +#define timevalsub(vvp, uvp) \ + do { \ + (vvp)->tv_sec -= (uvp)->tv_sec; \ + (vvp)->tv_usec -= (uvp)->tv_usec; \ + if ((vvp)->tv_usec < 0) { \ + (vvp)->tv_sec--; \ + (vvp)->tv_usec += 1000000; \ + } \ + } while (0) + +/*@}*/ + +#define ISC_MUTEX_MAX_LOCKERS 32 + +typedef struct { + const char * file; + int line; + unsigned count; + struct timeval locked_total; + struct timeval wait_total; +} isc_mutexlocker_t; + +struct isc_mutexstats { + const char * file; /*%< File mutex was created in. */ + int line; /*%< Line mutex was created on. */ + unsigned count; + struct timeval lock_t; + struct timeval locked_total; + struct timeval wait_total; + isc_mutexlocker_t * cur_locker; + isc_mutexlocker_t lockers[ISC_MUTEX_MAX_LOCKERS]; +}; + +#ifndef ISC_MUTEX_PROFTABLESIZE +#define ISC_MUTEX_PROFTABLESIZE (1024 * 1024) +#endif +static isc_mutexstats_t stats[ISC_MUTEX_PROFTABLESIZE]; +static int stats_next = 0; +static isc_boolean_t stats_init = ISC_FALSE; +static pthread_mutex_t statslock = PTHREAD_MUTEX_INITIALIZER; + + +isc_result_t +isc_mutex_init_profile(isc_mutex_t *mp, const char *file, int line) { + int i, err; + + err = pthread_mutex_init(&mp->mutex, NULL); + if (err == ENOMEM) + return (ISC_R_NOMEMORY); + if (err != 0) + return (ISC_R_UNEXPECTED); + + RUNTIME_CHECK(pthread_mutex_lock(&statslock) == 0); + + if (stats_init == ISC_FALSE) + stats_init = ISC_TRUE; + + /* + * If all statistics entries have been used, give up and trigger an + * assertion failure. There would be no other way to deal with this + * because we'd like to keep record of all locks for the purpose of + * debugging and the number of necessary locks is unpredictable. + * If this failure is triggered while debugging, named should be + * rebuilt with an increased ISC_MUTEX_PROFTABLESIZE. + */ + RUNTIME_CHECK(stats_next < ISC_MUTEX_PROFTABLESIZE); + mp->stats = &stats[stats_next++]; + + RUNTIME_CHECK(pthread_mutex_unlock(&statslock) == 0); + + mp->stats->file = file; + mp->stats->line = line; + mp->stats->count = 0; + timevalclear(&mp->stats->locked_total); + timevalclear(&mp->stats->wait_total); + for (i = 0; i < ISC_MUTEX_MAX_LOCKERS; i++) { + mp->stats->lockers[i].file = NULL; + mp->stats->lockers[i].line = 0; + mp->stats->lockers[i].count = 0; + timevalclear(&mp->stats->lockers[i].locked_total); + timevalclear(&mp->stats->lockers[i].wait_total); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_mutex_lock_profile(isc_mutex_t *mp, const char *file, int line) { + struct timeval prelock_t; + struct timeval postlock_t; + isc_mutexlocker_t *locker = NULL; + int i; + + gettimeofday(&prelock_t, NULL); + + if (pthread_mutex_lock(&mp->mutex) != 0) + return (ISC_R_UNEXPECTED); + + gettimeofday(&postlock_t, NULL); + mp->stats->lock_t = postlock_t; + + timevalsub(&postlock_t, &prelock_t); + + mp->stats->count++; + timevaladd(&mp->stats->wait_total, &postlock_t); + + for (i = 0; i < ISC_MUTEX_MAX_LOCKERS; i++) { + if (mp->stats->lockers[i].file == NULL) { + locker = &mp->stats->lockers[i]; + locker->file = file; + locker->line = line; + break; + } else if (mp->stats->lockers[i].file == file && + mp->stats->lockers[i].line == line) { + locker = &mp->stats->lockers[i]; + break; + } + } + + if (locker != NULL) { + locker->count++; + timevaladd(&locker->wait_total, &postlock_t); + } + + mp->stats->cur_locker = locker; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_mutex_unlock_profile(isc_mutex_t *mp, const char *file, int line) { + struct timeval unlock_t; + + UNUSED(file); + UNUSED(line); + + if (mp->stats->cur_locker != NULL) { + gettimeofday(&unlock_t, NULL); + timevalsub(&unlock_t, &mp->stats->lock_t); + timevaladd(&mp->stats->locked_total, &unlock_t); + timevaladd(&mp->stats->cur_locker->locked_total, &unlock_t); + mp->stats->cur_locker = NULL; + } + + return ((pthread_mutex_unlock((&mp->mutex)) == 0) ? \ + ISC_R_SUCCESS : ISC_R_UNEXPECTED); +} + + +void +isc_mutex_statsprofile(FILE *fp) { + isc_mutexlocker_t *locker; + int i, j; + + fprintf(fp, "Mutex stats (in us)\n"); + for (i = 0; i < stats_next; i++) { + fprintf(fp, "%-12s %4d: %10u %lu.%06lu %lu.%06lu %5d\n", + stats[i].file, stats[i].line, stats[i].count, + stats[i].locked_total.tv_sec, + stats[i].locked_total.tv_usec, + stats[i].wait_total.tv_sec, + stats[i].wait_total.tv_usec, + i); + for (j = 0; j < ISC_MUTEX_MAX_LOCKERS; j++) { + locker = &stats[i].lockers[j]; + if (locker->file == NULL) + continue; + fprintf(fp, " %-11s %4d: %10u %lu.%06lu %lu.%06lu %5d\n", + locker->file, locker->line, locker->count, + locker->locked_total.tv_sec, + locker->locked_total.tv_usec, + locker->wait_total.tv_sec, + locker->wait_total.tv_usec, + i); + } + } +} + +#endif /* ISC_MUTEX_PROFILE */ + +#if ISC_MUTEX_DEBUG && defined(PTHREAD_MUTEX_ERRORCHECK) +isc_result_t +isc_mutex_init_errcheck(isc_mutex_t *mp) +{ + pthread_mutexattr_t attr; + int err; + + if (pthread_mutexattr_init(&attr) != 0) + return (ISC_R_UNEXPECTED); + + if (pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_ERRORCHECK) != 0) { + pthread_mutexattr_destroy(&attr); + return (ISC_R_UNEXPECTED); + } + + err = pthread_mutex_init(mp, &attr) != 0) + pthread_mutexattr_destroy(&attr); + if (err == ENOMEM) + return (ISC_R_NOMEMORY); + return ((err == 0) ? ISC_R_SUCCESS : ISC_R_UNEXPECTED); +} +#endif + +#if ISC_MUTEX_DEBUG && defined(__NetBSD__) && defined(PTHREAD_MUTEX_ERRORCHECK) +pthread_mutexattr_t isc__mutex_attrs = { + PTHREAD_MUTEX_ERRORCHECK, /* m_type */ + 0 /* m_flags, which appears to be unused. */ +}; +#endif + +#if !(ISC_MUTEX_DEBUG && defined(PTHREAD_MUTEX_ERRORCHECK)) && !ISC_MUTEX_PROFILE +isc_result_t +isc__mutex_init(isc_mutex_t *mp, const char *file, unsigned int line) { + char strbuf[ISC_STRERRORSIZE]; + isc_result_t result = ISC_R_SUCCESS; + int err; + + err = pthread_mutex_init(mp, ISC__MUTEX_ATTRS); + if (err == ENOMEM) + return (ISC_R_NOMEMORY); + if (err != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(file, line, "isc_mutex_init() failed: %s", + strbuf); + result = ISC_R_UNEXPECTED; + } + return (result); +} +#endif diff --git a/contrib/ntp/lib/isc/pthreads/thread.c b/contrib/ntp/lib/isc/pthreads/thread.c new file mode 100644 index 000000000..4b5b4919b --- /dev/null +++ b/contrib/ntp/lib/isc/pthreads/thread.c @@ -0,0 +1,76 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.c,v 1.17 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#ifndef THREAD_MINSTACKSIZE +#define THREAD_MINSTACKSIZE (64U * 1024) +#endif + +isc_result_t +isc_thread_create(isc_threadfunc_t func, isc_threadarg_t arg, + isc_thread_t *thread) +{ + pthread_attr_t attr; + size_t stacksize; + int ret; + + pthread_attr_init(&attr); + +#if defined(HAVE_PTHREAD_ATTR_GETSTACKSIZE) && \ + defined(HAVE_PTHREAD_ATTR_SETSTACKSIZE) + ret = pthread_attr_getstacksize(&attr, &stacksize); + if (ret != 0) + return (ISC_R_UNEXPECTED); + + if (stacksize < THREAD_MINSTACKSIZE) { + ret = pthread_attr_setstacksize(&attr, THREAD_MINSTACKSIZE); + if (ret != 0) + return (ISC_R_UNEXPECTED); + } +#endif + +#if defined(PTHREAD_SCOPE_SYSTEM) && defined(NEED_PTHREAD_SCOPE_SYSTEM) + ret = pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM); + if (ret != 0) + return (ISC_R_UNEXPECTED); +#endif + + ret = pthread_create(thread, &attr, func, arg); + if (ret != 0) + return (ISC_R_UNEXPECTED); + + pthread_attr_destroy(&attr); + + return (ISC_R_SUCCESS); +} + +void +isc_thread_setconcurrency(unsigned int level) { +#if defined(CALL_PTHREAD_SETCONCURRENCY) + (void)pthread_setconcurrency(level); +#else + UNUSED(level); +#endif +} diff --git a/contrib/ntp/lib/isc/quota.c b/contrib/ntp/lib/isc/quota.c new file mode 100644 index 000000000..5e5c50c0e --- /dev/null +++ b/contrib/ntp/lib/isc/quota.c @@ -0,0 +1,101 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: quota.c,v 1.18 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +#include +#include + +isc_result_t +isc_quota_init(isc_quota_t *quota, int max) { + quota->max = max; + quota->used = 0; + quota->soft = 0; + return (isc_mutex_init("a->lock)); +} + +void +isc_quota_destroy(isc_quota_t *quota) { + INSIST(quota->used == 0); + quota->max = 0; + quota->used = 0; + quota->soft = 0; + DESTROYLOCK("a->lock); +} + +void +isc_quota_soft(isc_quota_t *quota, int soft) { + LOCK("a->lock); + quota->soft = soft; + UNLOCK("a->lock); +} + +void +isc_quota_max(isc_quota_t *quota, int max) { + LOCK("a->lock); + quota->max = max; + UNLOCK("a->lock); +} + +isc_result_t +isc_quota_reserve(isc_quota_t *quota) { + isc_result_t result; + LOCK("a->lock); + if (quota->max == 0 || quota->used < quota->max) { + if (quota->soft == 0 || quota->used < quota->soft) + result = ISC_R_SUCCESS; + else + result = ISC_R_SOFTQUOTA; + quota->used++; + } else + result = ISC_R_QUOTA; + UNLOCK("a->lock); + return (result); +} + +void +isc_quota_release(isc_quota_t *quota) { + LOCK("a->lock); + INSIST(quota->used > 0); + quota->used--; + UNLOCK("a->lock); +} + +isc_result_t +isc_quota_attach(isc_quota_t *quota, isc_quota_t **p) +{ + isc_result_t result; + INSIST(p != NULL && *p == NULL); + result = isc_quota_reserve(quota); + if (result == ISC_R_SUCCESS || result == ISC_R_SOFTQUOTA) + *p = quota; + return (result); +} + +void +isc_quota_detach(isc_quota_t **p) +{ + INSIST(p != NULL && *p != NULL); + isc_quota_release(*p); + *p = NULL; +} diff --git a/contrib/ntp/lib/isc/radix.c b/contrib/ntp/lib/isc/radix.c new file mode 100644 index 000000000..ac211efb6 --- /dev/null +++ b/contrib/ntp/lib/isc/radix.c @@ -0,0 +1,706 @@ +/* + * Copyright (C) 2007-2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* + * This source was adapted from MRT's RCS Ids: + * Id: radix.c,v 1.10.2.1 1999/11/29 05:16:24 masaki Exp + * Id: prefix.c,v 1.37.2.9 2000/03/10 02:53:19 labovit Exp + */ + +#include + +#include +#include +#include +#include + +static isc_result_t +_new_prefix(isc_mem_t *mctx, isc_prefix_t **target, int family, + void *dest, int bitlen); + +static void +_deref_prefix(isc_mem_t *mctx, isc_prefix_t *prefix); + +static isc_result_t +_ref_prefix(isc_mem_t *mctx, isc_prefix_t **target, isc_prefix_t *prefix); + +static int +_comp_with_mask(void *addr, void *dest, u_int mask); + +static void +_clear_radix(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func); + +static isc_result_t +_new_prefix(isc_mem_t *mctx, isc_prefix_t **target, int family, void *dest, + int bitlen) +{ + isc_prefix_t *prefix; + + REQUIRE(target != NULL); + + if (family != AF_INET6 && family != AF_INET && family != AF_UNSPEC) + return (ISC_R_NOTIMPLEMENTED); + + prefix = isc_mem_get(mctx, sizeof(isc_prefix_t)); + if (prefix == NULL) + return (ISC_R_NOMEMORY); + + if (family == AF_INET6) { + prefix->bitlen = (bitlen >= 0) ? bitlen : 128; + memcpy(&prefix->add.sin6, dest, 16); + } else { + /* AF_UNSPEC is "any" or "none"--treat it as AF_INET */ + prefix->bitlen = (bitlen >= 0) ? bitlen : 32; + memcpy(&prefix->add.sin, dest, 4); + } + + prefix->family = family; + + isc_refcount_init(&prefix->refcount, 1); + + *target = prefix; + return (ISC_R_SUCCESS); +} + +static void +_deref_prefix(isc_mem_t *mctx, isc_prefix_t *prefix) { + int refs; + + if (prefix == NULL) + return; + + isc_refcount_decrement(&prefix->refcount, &refs); + + if (refs <= 0) { + isc_refcount_destroy(&prefix->refcount); + isc_mem_put(mctx, prefix, sizeof(isc_prefix_t)); + } +} + +static isc_result_t +_ref_prefix(isc_mem_t *mctx, isc_prefix_t **target, isc_prefix_t *prefix) { + INSIST(prefix != NULL); + INSIST((prefix->family == AF_INET && prefix->bitlen <= 32) || + (prefix->family == AF_INET6 && prefix->bitlen <= 128) || + (prefix->family == AF_UNSPEC && prefix->bitlen == 0)); + REQUIRE(target != NULL && *target == NULL); + + /* + * If this prefix is a static allocation, copy it into new memory. + * (Note, the refcount still has to be destroyed by the calling + * routine.) + */ + if (isc_refcount_current(&prefix->refcount) == 0) { + isc_result_t ret; + ret = _new_prefix(mctx, target, prefix->family, + &prefix->add, prefix->bitlen); + return ret; + } + + isc_refcount_increment(&prefix->refcount, NULL); + + *target = prefix; + return (ISC_R_SUCCESS); +} + +static int +_comp_with_mask(void *addr, void *dest, u_int mask) { + + /* Mask length of zero matches everything */ + if (mask == 0) + return (1); + + if (memcmp(addr, dest, mask / 8) == 0) { + int n = mask / 8; + int m = ((~0) << (8 - (mask % 8))); + + if ((mask % 8) == 0 || + (((u_char *)addr)[n] & m) == (((u_char *)dest)[n] & m)) + return (1); + } + return (0); +} + +isc_result_t +isc_radix_create(isc_mem_t *mctx, isc_radix_tree_t **target, int maxbits) { + isc_radix_tree_t *radix; + + REQUIRE(target != NULL && *target == NULL); + + radix = isc_mem_get(mctx, sizeof(isc_radix_tree_t)); + if (radix == NULL) + return (ISC_R_NOMEMORY); + + radix->mctx = mctx; + radix->maxbits = maxbits; + radix->head = NULL; + radix->num_active_node = 0; + radix->num_added_node = 0; + RUNTIME_CHECK(maxbits <= RADIX_MAXBITS); /* XXX */ + radix->magic = RADIX_TREE_MAGIC; + *target = radix; + return (ISC_R_SUCCESS); +} + +/* + * if func is supplied, it will be called as func(node->data) + * before deleting the node + */ + +static void +_clear_radix(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func) { + + REQUIRE(radix != NULL); + + if (radix->head != NULL) { + + isc_radix_node_t *Xstack[RADIX_MAXBITS+1]; + isc_radix_node_t **Xsp = Xstack; + isc_radix_node_t *Xrn = radix->head; + + while (Xrn != NULL) { + isc_radix_node_t *l = Xrn->l; + isc_radix_node_t *r = Xrn->r; + + if (Xrn->prefix != NULL) { + _deref_prefix(radix->mctx, Xrn->prefix); + if (func != NULL && (Xrn->data[0] != NULL || + Xrn->data[1] != NULL)) + func(Xrn->data); + } else { + INSIST(Xrn->data[0] == NULL && + Xrn->data[1] == NULL); + } + + isc_mem_put(radix->mctx, Xrn, sizeof(*Xrn)); + radix->num_active_node--; + + if (l != NULL) { + if (r != NULL) { + *Xsp++ = r; + } + Xrn = l; + } else if (r != NULL) { + Xrn = r; + } else if (Xsp != Xstack) { + Xrn = *(--Xsp); + } else { + Xrn = NULL; + } + } + } + RUNTIME_CHECK(radix->num_active_node == 0); +} + + +void +isc_radix_destroy(isc_radix_tree_t *radix, isc_radix_destroyfunc_t func) +{ + REQUIRE(radix != NULL); + _clear_radix(radix, func); + isc_mem_put(radix->mctx, radix, sizeof(*radix)); +} + + +/* + * func will be called as func(node->prefix, node->data) + */ +void +isc_radix_process(isc_radix_tree_t *radix, isc_radix_processfunc_t func) +{ + isc_radix_node_t *node; + + REQUIRE(func != NULL); + + RADIX_WALK(radix->head, node) { + func(node->prefix, node->data); + } RADIX_WALK_END; +} + + +isc_result_t +isc_radix_search(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_prefix_t *prefix) +{ + isc_radix_node_t *node; + isc_radix_node_t *stack[RADIX_MAXBITS + 1]; + u_char *addr; + isc_uint32_t bitlen; + int tfamily = -1; + int cnt = 0; + + REQUIRE(radix != NULL); + REQUIRE(prefix != NULL); + REQUIRE(target != NULL && *target == NULL); + RUNTIME_CHECK(prefix->bitlen <= radix->maxbits); + + *target = NULL; + + if (radix->head == NULL) { + return (ISC_R_NOTFOUND); + } + + node = radix->head; + addr = isc_prefix_touchar(prefix); + bitlen = prefix->bitlen; + + while (node->bit < bitlen) { + if (node->prefix) + stack[cnt++] = node; + + if (BIT_TEST(addr[node->bit >> 3], 0x80 >> (node->bit & 0x07))) + node = node->r; + else + node = node->l; + + if (node == NULL) + break; + } + + if (node && node->prefix) + stack[cnt++] = node; + + while (cnt-- > 0) { + node = stack[cnt]; + + if (_comp_with_mask(isc_prefix_tochar(node->prefix), + isc_prefix_tochar(prefix), + node->prefix->bitlen)) { + if (node->node_num[ISC_IS6(prefix->family)] != -1 && + ((*target == NULL) || + (*target)->node_num[ISC_IS6(tfamily)] > + node->node_num[ISC_IS6(prefix->family)])) { + *target = node; + tfamily = prefix->family; + } + } + } + + if (*target == NULL) { + return (ISC_R_NOTFOUND); + } else { + return (ISC_R_SUCCESS); + } +} + +isc_result_t +isc_radix_insert(isc_radix_tree_t *radix, isc_radix_node_t **target, + isc_radix_node_t *source, isc_prefix_t *prefix) +{ + isc_radix_node_t *node, *new_node, *parent, *glue = NULL; + u_char *addr, *test_addr; + isc_uint32_t bitlen, fam, check_bit, differ_bit; + isc_uint32_t i, j, r; + isc_result_t result; + + REQUIRE(radix != NULL); + REQUIRE(target != NULL && *target == NULL); + REQUIRE(prefix != NULL || (source != NULL && source->prefix != NULL)); + RUNTIME_CHECK(prefix == NULL || prefix->bitlen <= radix->maxbits); + + if (prefix == NULL) + prefix = source->prefix; + + INSIST(prefix != NULL); + + bitlen = prefix->bitlen; + fam = prefix->family; + + if (radix->head == NULL) { + node = isc_mem_get(radix->mctx, sizeof(isc_radix_node_t)); + if (node == NULL) + return (ISC_R_NOMEMORY); + node->bit = bitlen; + node->node_num[0] = node->node_num[1] = -1; + node->prefix = NULL; + result = _ref_prefix(radix->mctx, &node->prefix, prefix); + if (result != ISC_R_SUCCESS) { + isc_mem_put(radix->mctx, node, + sizeof(isc_radix_node_t)); + return (result); + } + node->parent = NULL; + node->l = node->r = NULL; + if (source != NULL) { + /* + * If source is non-NULL, then we're merging in a + * node from an existing radix tree. To keep + * the node_num values consistent, the calling + * function will add the total number of nodes + * added to num_added_node at the end of + * the merge operation--we don't do it here. + */ + if (source->node_num[0] != -1) + node->node_num[0] = radix->num_added_node + + source->node_num[0]; + if (source->node_num[1] != -1) + node->node_num[1] = radix->num_added_node + + source->node_num[1]; + node->data[0] = source->data[0]; + node->data[1] = source->data[1]; + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + node->node_num[0] = node->node_num[1] = + ++radix->num_added_node; + } else { + node->node_num[ISC_IS6(fam)] = + ++radix->num_added_node; + } + node->data[0] = NULL; + node->data[1] = NULL; + } + radix->head = node; + radix->num_active_node++; + *target = node; + return (ISC_R_SUCCESS); + } + + addr = isc_prefix_touchar(prefix); + node = radix->head; + + while (node->bit < bitlen || node->prefix == NULL) { + if (node->bit < radix->maxbits && + BIT_TEST(addr[node->bit >> 3], 0x80 >> (node->bit & 0x07))) + { + if (node->r == NULL) + break; + node = node->r; + } else { + if (node->l == NULL) + break; + node = node->l; + } + + INSIST(node != NULL); + } + + INSIST(node->prefix != NULL); + + test_addr = isc_prefix_touchar(node->prefix); + /* Find the first bit different. */ + check_bit = (node->bit < bitlen) ? node->bit : bitlen; + differ_bit = 0; + for (i = 0; i*8 < check_bit; i++) { + if ((r = (addr[i] ^ test_addr[i])) == 0) { + differ_bit = (i + 1) * 8; + continue; + } + /* I know the better way, but for now. */ + for (j = 0; j < 8; j++) { + if (BIT_TEST (r, (0x80 >> j))) + break; + } + /* Must be found. */ + INSIST(j < 8); + differ_bit = i * 8 + j; + break; + } + + if (differ_bit > check_bit) + differ_bit = check_bit; + + parent = node->parent; + while (parent != NULL && parent->bit >= differ_bit) { + node = parent; + parent = node->parent; + } + + if (differ_bit == bitlen && node->bit == bitlen) { + if (node->prefix != NULL) { + /* Set node_num only if it hasn't been set before */ + if (source != NULL) { + /* Merging node */ + if (node->node_num[0] == -1 && + source->node_num[0] != -1) { + node->node_num[0] = + radix->num_added_node + + source->node_num[0]; + node->data[0] = source->data[0]; + } + if (node->node_num[1] == -1 && + source->node_num[0] != -1) { + node->node_num[1] = + radix->num_added_node + + source->node_num[1]; + node->data[1] = source->data[1]; + } + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + int next = radix->num_added_node + 1; + if (node->node_num[0] == -1) { + node->node_num[0] = next; + radix->num_added_node = next; + } + if (node->node_num[1] == -1) { + node->node_num[1] = next; + radix->num_added_node = next; + } + } else { + if (node->node_num[ISC_IS6(fam)] == -1) + node->node_num[ISC_IS6(fam)] + = ++radix->num_added_node; + } + } + *target = node; + return (ISC_R_SUCCESS); + } else { + result = + _ref_prefix(radix->mctx, &node->prefix, prefix); + if (result != ISC_R_SUCCESS) + return (result); + } + INSIST(node->data[0] == NULL && node->node_num[0] == -1 && + node->data[1] == NULL && node->node_num[1] == -1); + if (source != NULL) { + /* Merging node */ + if (source->node_num[0] != -1) { + node->node_num[0] = radix->num_added_node + + source->node_num[0]; + node->data[0] = source->data[0]; + } + if (source->node_num[1] != -1) { + node->node_num[1] = radix->num_added_node + + source->node_num[1]; + node->data[1] = source->data[1]; + } + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + node->node_num[0] = node->node_num[1] = + ++radix->num_added_node; + } else { + node->node_num[ISC_IS6(fam)] = + ++radix->num_added_node; + } + } + *target = node; + return (ISC_R_SUCCESS); + } + + new_node = isc_mem_get(radix->mctx, sizeof(isc_radix_node_t)); + if (new_node == NULL) + return (ISC_R_NOMEMORY); + if (node->bit != differ_bit && bitlen != differ_bit) { + glue = isc_mem_get(radix->mctx, sizeof(isc_radix_node_t)); + if (glue == NULL) { + isc_mem_put(radix->mctx, new_node, + sizeof(isc_radix_node_t)); + return (ISC_R_NOMEMORY); + } + } + new_node->bit = bitlen; + new_node->prefix = NULL; + result = _ref_prefix(radix->mctx, &new_node->prefix, prefix); + if (result != ISC_R_SUCCESS) { + isc_mem_put(radix->mctx, new_node, sizeof(isc_radix_node_t)); + if (glue != NULL) + isc_mem_put(radix->mctx, glue, + sizeof(isc_radix_node_t)); + return (result); + } + new_node->parent = NULL; + new_node->l = new_node->r = NULL; + new_node->node_num[0] = new_node->node_num[1] = -1; + radix->num_active_node++; + + if (source != NULL) { + /* Merging node */ + if (source->node_num[0] != -1) + new_node->node_num[0] = radix->num_added_node + + source->node_num[0]; + if (source->node_num[1] != -1) + new_node->node_num[1] = radix->num_added_node + + source->node_num[1]; + new_node->data[0] = source->data[0]; + new_node->data[1] = source->data[1]; + } else { + if (fam == AF_UNSPEC) { + /* "any" or "none" */ + new_node->node_num[0] = new_node->node_num[1] = + ++radix->num_added_node; + } else { + new_node->node_num[ISC_IS6(fam)] = + ++radix->num_added_node; + } + new_node->data[0] = NULL; + new_node->data[1] = NULL; + } + + if (node->bit == differ_bit) { + INSIST(glue == NULL); + new_node->parent = node; + if (node->bit < radix->maxbits && + BIT_TEST(addr[node->bit >> 3], 0x80 >> (node->bit & 0x07))) + { + INSIST(node->r == NULL); + node->r = new_node; + } else { + INSIST(node->l == NULL); + node->l = new_node; + } + *target = new_node; + return (ISC_R_SUCCESS); + } + + if (bitlen == differ_bit) { + INSIST(glue == NULL); + if (bitlen < radix->maxbits && + BIT_TEST(test_addr[bitlen >> 3], 0x80 >> (bitlen & 0x07))) { + new_node->r = node; + } else { + new_node->l = node; + } + new_node->parent = node->parent; + if (node->parent == NULL) { + INSIST(radix->head == node); + radix->head = new_node; + } else if (node->parent->r == node) { + node->parent->r = new_node; + } else { + node->parent->l = new_node; + } + node->parent = new_node; + } else { + INSIST(glue != NULL); + glue->bit = differ_bit; + glue->prefix = NULL; + glue->parent = node->parent; + glue->data[0] = glue->data[1] = NULL; + glue->node_num[0] = glue->node_num[1] = -1; + radix->num_active_node++; + if (differ_bit < radix->maxbits && + BIT_TEST(addr[differ_bit>>3], 0x80 >> (differ_bit & 07))) { + glue->r = new_node; + glue->l = node; + } else { + glue->r = node; + glue->l = new_node; + } + new_node->parent = glue; + + if (node->parent == NULL) { + INSIST(radix->head == node); + radix->head = glue; + } else if (node->parent->r == node) { + node->parent->r = glue; + } else { + node->parent->l = glue; + } + node->parent = glue; + } + + *target = new_node; + return (ISC_R_SUCCESS); +} + +void +isc_radix_remove(isc_radix_tree_t *radix, isc_radix_node_t *node) { + isc_radix_node_t *parent, *child; + + REQUIRE(radix != NULL); + REQUIRE(node != NULL); + + if (node->r && node->l) { + /* + * This might be a placeholder node -- have to check and + * make sure there is a prefix associated with it! + */ + if (node->prefix != NULL) + _deref_prefix(radix->mctx, node->prefix); + + node->prefix = NULL; + node->data[0] = node->data[1] = NULL; + return; + } + + if (node->r == NULL && node->l == NULL) { + parent = node->parent; + _deref_prefix(radix->mctx, node->prefix); + isc_mem_put(radix->mctx, node, sizeof(*node)); + radix->num_active_node--; + + if (parent == NULL) { + INSIST(radix->head == node); + radix->head = NULL; + return; + } + + if (parent->r == node) { + parent->r = NULL; + child = parent->l; + } else { + INSIST(parent->l == node); + parent->l = NULL; + child = parent->r; + } + + if (parent->prefix) + return; + + /* We need to remove parent too. */ + + if (parent->parent == NULL) { + INSIST(radix->head == parent); + radix->head = child; + } else if (parent->parent->r == parent) { + parent->parent->r = child; + } else { + INSIST(parent->parent->l == parent); + parent->parent->l = child; + } + child->parent = parent->parent; + isc_mem_put(radix->mctx, parent, sizeof(*parent)); + radix->num_active_node--; + return; + } + + if (node->r) { + child = node->r; + } else { + INSIST(node->l != NULL); + child = node->l; + } + parent = node->parent; + child->parent = parent; + + _deref_prefix(radix->mctx, node->prefix); + isc_mem_put(radix->mctx, node, sizeof(*node)); + radix->num_active_node--; + + if (parent == NULL) { + INSIST(radix->head == node); + radix->head = child; + return; + } + + if (parent->r == node) { + parent->r = child; + } else { + INSIST(parent->l == node); + parent->l = child; + } +} + +/* +Local Variables: +c-basic-offset: 4 +indent-tabs-mode: t +End: +*/ diff --git a/contrib/ntp/lib/isc/random.c b/contrib/ntp/lib/isc/random.c new file mode 100644 index 000000000..8b73ed569 --- /dev/null +++ b/contrib/ntp/lib/isc/random.c @@ -0,0 +1,113 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: random.c,v 1.28 2009/07/16 05:52:46 marka Exp $ */ + +/*! \file */ + +#include + +#include +#include /* Required for time(). */ +#ifdef HAVE_SYS_TYPES_H +#include +#endif +#ifdef HAVE_UNISTD_H +#include +#endif + +#include +#include +#include +#include +#include + +static isc_once_t once = ISC_ONCE_INIT; + +static void +initialize_rand(void) +{ +#ifndef HAVE_ARC4RANDOM + unsigned int pid = getpid(); + + /* + * The low bits of pid generally change faster. + * Xor them with the high bits of time which change slowly. + */ + pid = ((pid << 16) & 0xffff0000) | ((pid >> 16) & 0xffff); + + srand(time(NULL) ^ pid); +#endif +} + +static void +initialize(void) +{ + RUNTIME_CHECK(isc_once_do(&once, initialize_rand) == ISC_R_SUCCESS); +} + +void +isc_random_seed(isc_uint32_t seed) +{ + initialize(); + +#ifndef HAVE_ARC4RANDOM + srand(seed); +#else + arc4random_addrandom((u_char *) &seed, sizeof(isc_uint32_t)); +#endif +} + +void +isc_random_get(isc_uint32_t *val) +{ + REQUIRE(val != NULL); + + initialize(); + +#ifndef HAVE_ARC4RANDOM + /* + * rand()'s lower bits are not random. + * rand()'s upper bit is zero. + */ +#if RAND_MAX >= 0xfffff + /* We have at least 20 bits. Use lower 16 excluding lower most 4 */ + *val = ((rand() >> 4) & 0xffff) | ((rand() << 12) & 0xffff0000); +#elif RAND_MAX >= 0x7fff + /* We have at least 15 bits. Use lower 10/11 excluding lower most 4 */ + *val = ((rand() >> 4) & 0x000007ff) | ((rand() << 7) & 0x003ff800) | + ((rand() << 18) & 0xffc00000); +#else +#error RAND_MAX is too small +#endif +#else + *val = arc4random(); +#endif +} + +isc_uint32_t +isc_random_jitter(isc_uint32_t max, isc_uint32_t jitter) { + isc_uint32_t rnd; + + REQUIRE(jitter < max || (jitter == 0 && max == 0)); + + if (jitter == 0) + return (max); + + isc_random_get(&rnd); + return (max - rnd % jitter); +} diff --git a/contrib/ntp/lib/isc/ratelimiter.c b/contrib/ntp/lib/isc/ratelimiter.c new file mode 100644 index 000000000..07bcc7c7a --- /dev/null +++ b/contrib/ntp/lib/isc/ratelimiter.c @@ -0,0 +1,328 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ratelimiter.c,v 1.25 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include + +typedef enum { + isc_ratelimiter_stalled = 0, + isc_ratelimiter_ratelimited = 1, + isc_ratelimiter_idle = 2, + isc_ratelimiter_shuttingdown = 3 +} isc_ratelimiter_state_t; + +struct isc_ratelimiter { + isc_mem_t * mctx; + isc_mutex_t lock; + int refs; + isc_task_t * task; + isc_timer_t * timer; + isc_interval_t interval; + isc_uint32_t pertic; + isc_ratelimiter_state_t state; + isc_event_t shutdownevent; + ISC_LIST(isc_event_t) pending; +}; + +#define ISC_RATELIMITEREVENT_SHUTDOWN (ISC_EVENTCLASS_RATELIMITER + 1) + +static void +ratelimiter_tick(isc_task_t *task, isc_event_t *event); + +static void +ratelimiter_shutdowncomplete(isc_task_t *task, isc_event_t *event); + +isc_result_t +isc_ratelimiter_create(isc_mem_t *mctx, isc_timermgr_t *timermgr, + isc_task_t *task, isc_ratelimiter_t **ratelimiterp) +{ + isc_result_t result; + isc_ratelimiter_t *rl; + INSIST(ratelimiterp != NULL && *ratelimiterp == NULL); + + rl = isc_mem_get(mctx, sizeof(*rl)); + if (rl == NULL) + return ISC_R_NOMEMORY; + rl->mctx = mctx; + rl->refs = 1; + rl->task = task; + isc_interval_set(&rl->interval, 0, 0); + rl->timer = NULL; + rl->pertic = 1; + rl->state = isc_ratelimiter_idle; + ISC_LIST_INIT(rl->pending); + + result = isc_mutex_init(&rl->lock); + if (result != ISC_R_SUCCESS) + goto free_mem; + result = isc_timer_create(timermgr, isc_timertype_inactive, + NULL, NULL, rl->task, ratelimiter_tick, + rl, &rl->timer); + if (result != ISC_R_SUCCESS) + goto free_mutex; + + /* + * Increment the reference count to indicate that we may + * (soon) have events outstanding. + */ + rl->refs++; + + ISC_EVENT_INIT(&rl->shutdownevent, + sizeof(isc_event_t), + 0, NULL, ISC_RATELIMITEREVENT_SHUTDOWN, + ratelimiter_shutdowncomplete, rl, rl, NULL, NULL); + + *ratelimiterp = rl; + return (ISC_R_SUCCESS); + +free_mutex: + DESTROYLOCK(&rl->lock); +free_mem: + isc_mem_put(mctx, rl, sizeof(*rl)); + return (result); +} + +isc_result_t +isc_ratelimiter_setinterval(isc_ratelimiter_t *rl, isc_interval_t *interval) { + isc_result_t result = ISC_R_SUCCESS; + LOCK(&rl->lock); + rl->interval = *interval; + /* + * If the timer is currently running, change its rate. + */ + if (rl->state == isc_ratelimiter_ratelimited) { + result = isc_timer_reset(rl->timer, isc_timertype_ticker, NULL, + &rl->interval, ISC_FALSE); + } + UNLOCK(&rl->lock); + return (result); +} + +void +isc_ratelimiter_setpertic(isc_ratelimiter_t *rl, isc_uint32_t pertic) { + if (pertic == 0) + pertic = 1; + rl->pertic = pertic; +} + +isc_result_t +isc_ratelimiter_enqueue(isc_ratelimiter_t *rl, isc_task_t *task, + isc_event_t **eventp) +{ + isc_result_t result = ISC_R_SUCCESS; + isc_event_t *ev; + + REQUIRE(eventp != NULL && *eventp != NULL); + REQUIRE(task != NULL); + ev = *eventp; + REQUIRE(ev->ev_sender == NULL); + + LOCK(&rl->lock); + if (rl->state == isc_ratelimiter_ratelimited || + rl->state == isc_ratelimiter_stalled) { + isc_event_t *ev = *eventp; + ev->ev_sender = task; + ISC_LIST_APPEND(rl->pending, ev, ev_link); + *eventp = NULL; + } else if (rl->state == isc_ratelimiter_idle) { + result = isc_timer_reset(rl->timer, isc_timertype_ticker, NULL, + &rl->interval, ISC_FALSE); + if (result == ISC_R_SUCCESS) { + ev->ev_sender = task; + rl->state = isc_ratelimiter_ratelimited; + } + } else { + INSIST(rl->state == isc_ratelimiter_shuttingdown); + result = ISC_R_SHUTTINGDOWN; + } + UNLOCK(&rl->lock); + if (*eventp != NULL && result == ISC_R_SUCCESS) + isc_task_send(task, eventp); + return (result); +} + +static void +ratelimiter_tick(isc_task_t *task, isc_event_t *event) { + isc_result_t result = ISC_R_SUCCESS; + isc_ratelimiter_t *rl = (isc_ratelimiter_t *)event->ev_arg; + isc_event_t *p; + isc_uint32_t pertic; + + UNUSED(task); + + isc_event_free(&event); + + pertic = rl->pertic; + while (pertic != 0) { + pertic--; + LOCK(&rl->lock); + p = ISC_LIST_HEAD(rl->pending); + if (p != NULL) { + /* + * There is work to do. Let's do it after unlocking. + */ + ISC_LIST_UNLINK(rl->pending, p, ev_link); + } else { + /* + * No work left to do. Stop the timer so that we don't + * waste resources by having it fire periodically. + */ + result = isc_timer_reset(rl->timer, + isc_timertype_inactive, + NULL, NULL, ISC_FALSE); + RUNTIME_CHECK(result == ISC_R_SUCCESS); + rl->state = isc_ratelimiter_idle; + pertic = 0; /* Force the loop to exit. */ + } + UNLOCK(&rl->lock); + if (p != NULL) { + isc_task_t *evtask = p->ev_sender; + isc_task_send(evtask, &p); + } + INSIST(p == NULL); + } +} + +void +isc_ratelimiter_shutdown(isc_ratelimiter_t *rl) { + isc_event_t *ev; + isc_task_t *task; + LOCK(&rl->lock); + rl->state = isc_ratelimiter_shuttingdown; + (void)isc_timer_reset(rl->timer, isc_timertype_inactive, + NULL, NULL, ISC_FALSE); + while ((ev = ISC_LIST_HEAD(rl->pending)) != NULL) { + ISC_LIST_UNLINK(rl->pending, ev, ev_link); + ev->ev_attributes |= ISC_EVENTATTR_CANCELED; + task = ev->ev_sender; + isc_task_send(task, &ev); + } + isc_timer_detach(&rl->timer); + /* + * Send an event to our task. The delivery of this event + * indicates that no more timer events will be delivered. + */ + ev = &rl->shutdownevent; + isc_task_send(rl->task, &ev); + + UNLOCK(&rl->lock); +} + +static void +ratelimiter_shutdowncomplete(isc_task_t *task, isc_event_t *event) { + isc_ratelimiter_t *rl = (isc_ratelimiter_t *)event->ev_arg; + + UNUSED(task); + + isc_ratelimiter_detach(&rl); +} + +static void +ratelimiter_free(isc_ratelimiter_t *rl) { + DESTROYLOCK(&rl->lock); + isc_mem_put(rl->mctx, rl, sizeof(*rl)); +} + +void +isc_ratelimiter_attach(isc_ratelimiter_t *source, isc_ratelimiter_t **target) { + REQUIRE(source != NULL); + REQUIRE(target != NULL && *target == NULL); + + LOCK(&source->lock); + REQUIRE(source->refs > 0); + source->refs++; + INSIST(source->refs > 0); + UNLOCK(&source->lock); + *target = source; +} + +void +isc_ratelimiter_detach(isc_ratelimiter_t **rlp) { + isc_ratelimiter_t *rl = *rlp; + isc_boolean_t free_now = ISC_FALSE; + + LOCK(&rl->lock); + REQUIRE(rl->refs > 0); + rl->refs--; + if (rl->refs == 0) + free_now = ISC_TRUE; + UNLOCK(&rl->lock); + + if (free_now) + ratelimiter_free(rl); + + *rlp = NULL; +} + +isc_result_t +isc_ratelimiter_stall(isc_ratelimiter_t *rl) { + isc_result_t result = ISC_R_SUCCESS; + + LOCK(&rl->lock); + switch (rl->state) { + case isc_ratelimiter_shuttingdown: + result = ISC_R_SHUTTINGDOWN; + break; + case isc_ratelimiter_ratelimited: + result = isc_timer_reset(rl->timer, isc_timertype_inactive, + NULL, NULL, ISC_FALSE); + RUNTIME_CHECK(result == ISC_R_SUCCESS); + case isc_ratelimiter_idle: + case isc_ratelimiter_stalled: + rl->state = isc_ratelimiter_stalled; + break; + } + UNLOCK(&rl->lock); + return (result); +} + +isc_result_t +isc_ratelimiter_release(isc_ratelimiter_t *rl) { + isc_result_t result = ISC_R_SUCCESS; + + LOCK(&rl->lock); + switch (rl->state) { + case isc_ratelimiter_shuttingdown: + result = ISC_R_SHUTTINGDOWN; + break; + case isc_ratelimiter_stalled: + if (!ISC_LIST_EMPTY(rl->pending)) { + result = isc_timer_reset(rl->timer, + isc_timertype_ticker, NULL, + &rl->interval, ISC_FALSE); + if (result == ISC_R_SUCCESS) + rl->state = isc_ratelimiter_ratelimited; + } else + rl->state = isc_ratelimiter_idle; + break; + case isc_ratelimiter_ratelimited: + case isc_ratelimiter_idle: + break; + } + UNLOCK(&rl->lock); + return (result); +} diff --git a/contrib/ntp/lib/isc/refcount.c b/contrib/ntp/lib/isc/refcount.c new file mode 100644 index 000000000..36dfff297 --- /dev/null +++ b/contrib/ntp/lib/isc/refcount.c @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: refcount.c,v 1.5 2007/06/19 23:47:17 tbox Exp $ */ + +#include + +#include + +#include +#include +#include + +isc_result_t +isc_refcount_init(isc_refcount_t *ref, unsigned int n) { + REQUIRE(ref != NULL); + + ref->refs = n; +#if defined(ISC_PLATFORM_USETHREADS) && !defined(ISC_PLATFORM_HAVEXADD) + return (isc_mutex_init(&ref->lock)); +#else + return (ISC_R_SUCCESS); +#endif +} diff --git a/contrib/ntp/lib/isc/region.c b/contrib/ntp/lib/isc/region.c new file mode 100644 index 000000000..cf6497900 --- /dev/null +++ b/contrib/ntp/lib/isc/region.c @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: region.c,v 1.7 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include + +int +isc_region_compare(isc_region_t *r1, isc_region_t *r2) { + unsigned int l; + int result; + + REQUIRE(r1 != NULL); + REQUIRE(r2 != NULL); + + l = (r1->length < r2->length) ? r1->length : r2->length; + + if ((result = memcmp(r1->base, r2->base, l)) != 0) + return ((result < 0) ? -1 : 1); + else + return ((r1->length == r2->length) ? 0 : + (r1->length < r2->length) ? -1 : 1); +} diff --git a/contrib/ntp/lib/isc/result.c b/contrib/ntp/lib/isc/result.c new file mode 100644 index 000000000..da57272df --- /dev/null +++ b/contrib/ntp/lib/isc/result.c @@ -0,0 +1,214 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include +#include +#include +#include + +typedef struct resulttable { + unsigned int base; + unsigned int last; + const char ** text; + isc_msgcat_t * msgcat; + int set; + ISC_LINK(struct resulttable) link; +} resulttable; + +static const char *text[ISC_R_NRESULTS] = { + "success", /*%< 0 */ + "out of memory", /*%< 1 */ + "timed out", /*%< 2 */ + "no available threads", /*%< 3 */ + "address not available", /*%< 4 */ + "address in use", /*%< 5 */ + "permission denied", /*%< 6 */ + "no pending connections", /*%< 7 */ + "network unreachable", /*%< 8 */ + "host unreachable", /*%< 9 */ + "network down", /*%< 10 */ + "host down", /*%< 11 */ + "connection refused", /*%< 12 */ + "not enough free resources", /*%< 13 */ + "end of file", /*%< 14 */ + "socket already bound", /*%< 15 */ + "reload", /*%< 16 */ + "lock busy", /*%< 17 */ + "already exists", /*%< 18 */ + "ran out of space", /*%< 19 */ + "operation canceled", /*%< 20 */ + "socket is not bound", /*%< 21 */ + "shutting down", /*%< 22 */ + "not found", /*%< 23 */ + "unexpected end of input", /*%< 24 */ + "failure", /*%< 25 */ + "I/O error", /*%< 26 */ + "not implemented", /*%< 27 */ + "unbalanced parentheses", /*%< 28 */ + "no more", /*%< 29 */ + "invalid file", /*%< 30 */ + "bad base64 encoding", /*%< 31 */ + "unexpected token", /*%< 32 */ + "quota reached", /*%< 33 */ + "unexpected error", /*%< 34 */ + "already running", /*%< 35 */ + "ignore", /*%< 36 */ + "address mask not contiguous", /*%< 37 */ + "file not found", /*%< 38 */ + "file already exists", /*%< 39 */ + "socket is not connected", /*%< 40 */ + "out of range", /*%< 41 */ + "out of entropy", /*%< 42 */ + "invalid use of multicast address", /*%< 43 */ + "not a file", /*%< 44 */ + "not a directory", /*%< 45 */ + "queue is full", /*%< 46 */ + "address family mismatch", /*%< 47 */ + "address family not supported", /*%< 48 */ + "bad hex encoding", /*%< 49 */ + "too many open files", /*%< 50 */ + "not blocking", /*%< 51 */ + "unbalanced quotes", /*%< 52 */ + "operation in progress", /*%< 53 */ + "connection reset", /*%< 54 */ + "soft quota reached", /*%< 55 */ + "not a valid number", /*%< 56 */ + "disabled", /*%< 57 */ + "max size", /*%< 58 */ + "invalid address format", /*%< 59 */ + "bad base32 encoding", /*%< 60 */ + "unset", /*%< 61 */ +}; + +#define ISC_RESULT_RESULTSET 2 +#define ISC_RESULT_UNAVAILABLESET 3 + +static isc_once_t once = ISC_ONCE_INIT; +static ISC_LIST(resulttable) tables; +static isc_mutex_t lock; + +static isc_result_t +register_table(unsigned int base, unsigned int nresults, const char **txt, + isc_msgcat_t *msgcat, int set) +{ + resulttable *table; + + REQUIRE(base % ISC_RESULTCLASS_SIZE == 0); + REQUIRE(nresults <= ISC_RESULTCLASS_SIZE); + REQUIRE(txt != NULL); + + /* + * We use malloc() here because we we want to be able to use + * isc_result_totext() even if there is no memory context. + */ + table = malloc(sizeof(*table)); + if (table == NULL) + return (ISC_R_NOMEMORY); + table->base = base; + table->last = base + nresults - 1; + table->text = txt; + table->msgcat = msgcat; + table->set = set; + ISC_LINK_INIT(table, link); + + LOCK(&lock); + + ISC_LIST_APPEND(tables, table, link); + + UNLOCK(&lock); + + return (ISC_R_SUCCESS); +} + +static void +initialize_action(void) { + isc_result_t result; + + RUNTIME_CHECK(isc_mutex_init(&lock) == ISC_R_SUCCESS); + ISC_LIST_INIT(tables); + + result = register_table(ISC_RESULTCLASS_ISC, ISC_R_NRESULTS, text, + isc_msgcat, ISC_RESULT_RESULTSET); + if (result != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "register_table() %s: %u", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + result); +} + +static void +initialize(void) { + isc_lib_initmsgcat(); + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); +} + +const char * +isc_result_totext(isc_result_t result) { + resulttable *table; + const char *txt, *default_text; + int idx; + + initialize(); + + LOCK(&lock); + + txt = NULL; + for (table = ISC_LIST_HEAD(tables); + table != NULL; + table = ISC_LIST_NEXT(table, link)) { + if (result >= table->base && result <= table->last) { + idx = (int)(result - table->base); + default_text = table->text[idx]; + /* + * Note: we use 'idx + 1' as the message number + * instead of idx because isc_msgcat_get() requires + * the message number to be > 0. + */ + txt = isc_msgcat_get(table->msgcat, table->set, + idx + 1, default_text); + break; + } + } + if (txt == NULL) + txt = isc_msgcat_get(isc_msgcat, ISC_RESULT_UNAVAILABLESET, + 1, "(result code text not available)"); + + UNLOCK(&lock); + + return (txt); +} + +isc_result_t +isc_result_register(unsigned int base, unsigned int nresults, + const char **txt, isc_msgcat_t *msgcat, int set) +{ + initialize(); + + return (register_table(base, nresults, txt, msgcat, set)); +} diff --git a/contrib/ntp/lib/isc/rwlock.c b/contrib/ntp/lib/isc/rwlock.c new file mode 100644 index 000000000..9c84c258a --- /dev/null +++ b/contrib/ntp/lib/isc/rwlock.c @@ -0,0 +1,809 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include + +#define RWLOCK_MAGIC ISC_MAGIC('R', 'W', 'L', 'k') +#define VALID_RWLOCK(rwl) ISC_MAGIC_VALID(rwl, RWLOCK_MAGIC) + +#ifdef ISC_PLATFORM_USETHREADS + +#ifndef RWLOCK_DEFAULT_READ_QUOTA +#define RWLOCK_DEFAULT_READ_QUOTA 4 +#endif + +#ifndef RWLOCK_DEFAULT_WRITE_QUOTA +#define RWLOCK_DEFAULT_WRITE_QUOTA 4 +#endif + +#ifdef ISC_RWLOCK_TRACE +#include /* Required for fprintf/stderr. */ +#include /* Required for isc_thread_self(). */ + +static void +print_lock(const char *operation, isc_rwlock_t *rwl, isc_rwlocktype_t type) { + fprintf(stderr, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRINTLOCK, + "rwlock %p thread %lu %s(%s): %s, %u active, " + "%u granted, %u rwaiting, %u wwaiting\n"), + rwl, isc_thread_self(), operation, + (type == isc_rwlocktype_read ? + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_READ, "read") : + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_WRITE, "write")), + (rwl->type == isc_rwlocktype_read ? + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_READING, "reading") : + isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_WRITING, "writing")), + rwl->active, rwl->granted, rwl->readers_waiting, + rwl->writers_waiting); +} +#endif + +isc_result_t +isc_rwlock_init(isc_rwlock_t *rwl, unsigned int read_quota, + unsigned int write_quota) +{ + isc_result_t result; + + REQUIRE(rwl != NULL); + + /* + * In case there's trouble initializing, we zero magic now. If all + * goes well, we'll set it to RWLOCK_MAGIC. + */ + rwl->magic = 0; + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + rwl->write_requests = 0; + rwl->write_completions = 0; + rwl->cnt_and_flag = 0; + rwl->readers_waiting = 0; + rwl->write_granted = 0; + if (read_quota != 0) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "read quota is not supported"); + } + if (write_quota == 0) + write_quota = RWLOCK_DEFAULT_WRITE_QUOTA; + rwl->write_quota = write_quota; +#else + rwl->type = isc_rwlocktype_read; + rwl->original = isc_rwlocktype_none; + rwl->active = 0; + rwl->granted = 0; + rwl->readers_waiting = 0; + rwl->writers_waiting = 0; + if (read_quota == 0) + read_quota = RWLOCK_DEFAULT_READ_QUOTA; + rwl->read_quota = read_quota; + if (write_quota == 0) + write_quota = RWLOCK_DEFAULT_WRITE_QUOTA; + rwl->write_quota = write_quota; +#endif + + result = isc_mutex_init(&rwl->lock); + if (result != ISC_R_SUCCESS) + return (result); + + result = isc_condition_init(&rwl->readable); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init(readable) %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + isc_result_totext(result)); + result = ISC_R_UNEXPECTED; + goto destroy_lock; + } + result = isc_condition_init(&rwl->writeable); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init(writeable) %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + isc_result_totext(result)); + result = ISC_R_UNEXPECTED; + goto destroy_rcond; + } + + rwl->magic = RWLOCK_MAGIC; + + return (ISC_R_SUCCESS); + + destroy_rcond: + (void)isc_condition_destroy(&rwl->readable); + destroy_lock: + DESTROYLOCK(&rwl->lock); + + return (result); +} + +void +isc_rwlock_destroy(isc_rwlock_t *rwl) { + REQUIRE(VALID_RWLOCK(rwl)); + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + REQUIRE(rwl->write_requests == rwl->write_completions && + rwl->cnt_and_flag == 0 && rwl->readers_waiting == 0); +#else + LOCK(&rwl->lock); + REQUIRE(rwl->active == 0 && + rwl->readers_waiting == 0 && + rwl->writers_waiting == 0); + UNLOCK(&rwl->lock); +#endif + + rwl->magic = 0; + (void)isc_condition_destroy(&rwl->readable); + (void)isc_condition_destroy(&rwl->writeable); + DESTROYLOCK(&rwl->lock); +} + +#if defined(ISC_PLATFORM_HAVEXADD) && defined(ISC_PLATFORM_HAVECMPXCHG) + +/* + * When some architecture-dependent atomic operations are available, + * rwlock can be more efficient than the generic algorithm defined below. + * The basic algorithm is described in the following URL: + * http://www.cs.rochester.edu/u/scott/synchronization/pseudocode/rw.html + * + * The key is to use the following integer variables modified atomically: + * write_requests, write_completions, and cnt_and_flag. + * + * write_requests and write_completions act as a waiting queue for writers + * in order to ensure the FIFO order. Both variables begin with the initial + * value of 0. When a new writer tries to get a write lock, it increments + * write_requests and gets the previous value of the variable as a "ticket". + * When write_completions reaches the ticket number, the new writer can start + * writing. When the writer completes its work, it increments + * write_completions so that another new writer can start working. If the + * write_requests is not equal to write_completions, it means a writer is now + * working or waiting. In this case, a new readers cannot start reading, or + * in other words, this algorithm basically prefers writers. + * + * cnt_and_flag is a "lock" shared by all readers and writers. This integer + * variable is a kind of structure with two members: writer_flag (1 bit) and + * reader_count (31 bits). The writer_flag shows whether a writer is working, + * and the reader_count shows the number of readers currently working or almost + * ready for working. A writer who has the current "ticket" tries to get the + * lock by exclusively setting the writer_flag to 1, provided that the whole + * 32-bit is 0 (meaning no readers or writers working). On the other hand, + * a new reader tries to increment the "reader_count" field provided that + * the writer_flag is 0 (meaning there is no writer working). + * + * If some of the above operations fail, the reader or the writer sleeps + * until the related condition changes. When a working reader or writer + * completes its work, some readers or writers are sleeping, and the condition + * that suspended the reader or writer has changed, it wakes up the sleeping + * readers or writers. + * + * As already noted, this algorithm basically prefers writers. In order to + * prevent readers from starving, however, the algorithm also introduces the + * "writer quota" (Q). When Q consecutive writers have completed their work, + * suspending readers, the last writer will wake up the readers, even if a new + * writer is waiting. + * + * Implementation specific note: due to the combination of atomic operations + * and a mutex lock, ordering between the atomic operation and locks can be + * very sensitive in some cases. In particular, it is generally very important + * to check the atomic variable that requires a reader or writer to sleep after + * locking the mutex and before actually sleeping; otherwise, it could be very + * likely to cause a deadlock. For example, assume "var" is a variable + * atomically modified, then the corresponding code would be: + * if (var == need_sleep) { + * LOCK(lock); + * if (var == need_sleep) + * WAIT(cond, lock); + * UNLOCK(lock); + * } + * The second check is important, since "var" is protected by the atomic + * operation, not by the mutex, and can be changed just before sleeping. + * (The first "if" could be omitted, but this is also important in order to + * make the code efficient by avoiding the use of the mutex unless it is + * really necessary.) + */ + +#define WRITER_ACTIVE 0x1 +#define READER_INCR 0x2 + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + isc_int32_t cntflag; + + REQUIRE(VALID_RWLOCK(rwl)); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRELOCK, "prelock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + if (rwl->write_requests != rwl->write_completions) { + /* there is a waiting or active writer */ + LOCK(&rwl->lock); + if (rwl->write_requests != rwl->write_completions) { + rwl->readers_waiting++; + WAIT(&rwl->readable, &rwl->lock); + rwl->readers_waiting--; + } + UNLOCK(&rwl->lock); + } + + cntflag = isc_atomic_xadd(&rwl->cnt_and_flag, READER_INCR); + POST(cntflag); + while (1) { + if ((rwl->cnt_and_flag & WRITER_ACTIVE) == 0) + break; + + /* A writer is still working */ + LOCK(&rwl->lock); + rwl->readers_waiting++; + if ((rwl->cnt_and_flag & WRITER_ACTIVE) != 0) + WAIT(&rwl->readable, &rwl->lock); + rwl->readers_waiting--; + UNLOCK(&rwl->lock); + + /* + * Typically, the reader should be able to get a lock + * at this stage: + * (1) there should have been no pending writer when + * the reader was trying to increment the + * counter; otherwise, the writer should be in + * the waiting queue, preventing the reader from + * proceeding to this point. + * (2) once the reader increments the counter, no + * more writer can get a lock. + * Still, it is possible another writer can work at + * this point, e.g. in the following scenario: + * A previous writer unlocks the writer lock. + * This reader proceeds to point (1). + * A new writer appears, and gets a new lock before + * the reader increments the counter. + * The reader then increments the counter. + * The previous writer notices there is a waiting + * reader who is almost ready, and wakes it up. + * So, the reader needs to confirm whether it can now + * read explicitly (thus we loop). Note that this is + * not an infinite process, since the reader has + * incremented the counter at this point. + */ + } + + /* + * If we are temporarily preferred to writers due to the writer + * quota, reset the condition (race among readers doesn't + * matter). + */ + rwl->write_granted = 0; + } else { + isc_int32_t prev_writer; + + /* enter the waiting queue, and wait for our turn */ + prev_writer = isc_atomic_xadd(&rwl->write_requests, 1); + while (rwl->write_completions != prev_writer) { + LOCK(&rwl->lock); + if (rwl->write_completions != prev_writer) { + WAIT(&rwl->writeable, &rwl->lock); + UNLOCK(&rwl->lock); + continue; + } + UNLOCK(&rwl->lock); + break; + } + + while (1) { + cntflag = isc_atomic_cmpxchg(&rwl->cnt_and_flag, 0, + WRITER_ACTIVE); + if (cntflag == 0) + break; + + /* Another active reader or writer is working. */ + LOCK(&rwl->lock); + if (rwl->cnt_and_flag != 0) + WAIT(&rwl->writeable, &rwl->lock); + UNLOCK(&rwl->lock); + } + + INSIST((rwl->cnt_and_flag & WRITER_ACTIVE) != 0); + rwl->write_granted++; + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTLOCK, "postlock"), rwl, type); +#endif + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + isc_int32_t cntflag; + + REQUIRE(VALID_RWLOCK(rwl)); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRELOCK, "prelock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + /* If a writer is waiting or working, we fail. */ + if (rwl->write_requests != rwl->write_completions) + return (ISC_R_LOCKBUSY); + + /* Otherwise, be ready for reading. */ + cntflag = isc_atomic_xadd(&rwl->cnt_and_flag, READER_INCR); + if ((cntflag & WRITER_ACTIVE) != 0) { + /* + * A writer is working. We lose, and cancel the read + * request. + */ + cntflag = isc_atomic_xadd(&rwl->cnt_and_flag, + -READER_INCR); + /* + * If no other readers are waiting and we've suspended + * new writers in this short period, wake them up. + */ + if (cntflag == READER_INCR && + rwl->write_completions != rwl->write_requests) { + LOCK(&rwl->lock); + BROADCAST(&rwl->writeable); + UNLOCK(&rwl->lock); + } + + return (ISC_R_LOCKBUSY); + } + } else { + /* Try locking without entering the waiting queue. */ + cntflag = isc_atomic_cmpxchg(&rwl->cnt_and_flag, 0, + WRITER_ACTIVE); + if (cntflag != 0) + return (ISC_R_LOCKBUSY); + + /* + * XXXJT: jump into the queue, possibly breaking the writer + * order. + */ + (void)isc_atomic_xadd(&rwl->write_completions, -1); + + rwl->write_granted++; + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTLOCK, "postlock"), rwl, type); +#endif + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl) { + isc_int32_t prevcnt; + + REQUIRE(VALID_RWLOCK(rwl)); + + /* Try to acquire write access. */ + prevcnt = isc_atomic_cmpxchg(&rwl->cnt_and_flag, + READER_INCR, WRITER_ACTIVE); + /* + * There must have been no writer, and there must have been at least + * one reader. + */ + INSIST((prevcnt & WRITER_ACTIVE) == 0 && + (prevcnt & ~WRITER_ACTIVE) != 0); + + if (prevcnt == READER_INCR) { + /* + * We are the only reader and have been upgraded. + * Now jump into the head of the writer waiting queue. + */ + (void)isc_atomic_xadd(&rwl->write_completions, -1); + } else + return (ISC_R_LOCKBUSY); + + return (ISC_R_SUCCESS); + +} + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl) { + isc_int32_t prev_readers; + + REQUIRE(VALID_RWLOCK(rwl)); + + /* Become an active reader. */ + prev_readers = isc_atomic_xadd(&rwl->cnt_and_flag, READER_INCR); + /* We must have been a writer. */ + INSIST((prev_readers & WRITER_ACTIVE) != 0); + + /* Complete write */ + (void)isc_atomic_xadd(&rwl->cnt_and_flag, -WRITER_ACTIVE); + (void)isc_atomic_xadd(&rwl->write_completions, 1); + + /* Resume other readers */ + LOCK(&rwl->lock); + if (rwl->readers_waiting > 0) + BROADCAST(&rwl->readable); + UNLOCK(&rwl->lock); +} + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + isc_int32_t prev_cnt; + + REQUIRE(VALID_RWLOCK(rwl)); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PREUNLOCK, "preunlock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + prev_cnt = isc_atomic_xadd(&rwl->cnt_and_flag, -READER_INCR); + + /* + * If we're the last reader and any writers are waiting, wake + * them up. We need to wake up all of them to ensure the + * FIFO order. + */ + if (prev_cnt == READER_INCR && + rwl->write_completions != rwl->write_requests) { + LOCK(&rwl->lock); + BROADCAST(&rwl->writeable); + UNLOCK(&rwl->lock); + } + } else { + isc_boolean_t wakeup_writers = ISC_TRUE; + + /* + * Reset the flag, and (implicitly) tell other writers + * we are done. + */ + (void)isc_atomic_xadd(&rwl->cnt_and_flag, -WRITER_ACTIVE); + (void)isc_atomic_xadd(&rwl->write_completions, 1); + + if (rwl->write_granted >= rwl->write_quota || + rwl->write_requests == rwl->write_completions || + (rwl->cnt_and_flag & ~WRITER_ACTIVE) != 0) { + /* + * We have passed the write quota, no writer is + * waiting, or some readers are almost ready, pending + * possible writers. Note that the last case can + * happen even if write_requests != write_completions + * (which means a new writer in the queue), so we need + * to catch the case explicitly. + */ + LOCK(&rwl->lock); + if (rwl->readers_waiting > 0) { + wakeup_writers = ISC_FALSE; + BROADCAST(&rwl->readable); + } + UNLOCK(&rwl->lock); + } + + if (rwl->write_requests != rwl->write_completions && + wakeup_writers) { + LOCK(&rwl->lock); + BROADCAST(&rwl->writeable); + UNLOCK(&rwl->lock); + } + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTUNLOCK, "postunlock"), + rwl, type); +#endif + + return (ISC_R_SUCCESS); +} + +#else /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ + +static isc_result_t +doit(isc_rwlock_t *rwl, isc_rwlocktype_t type, isc_boolean_t nonblock) { + isc_boolean_t skip = ISC_FALSE; + isc_boolean_t done = ISC_FALSE; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_RWLOCK(rwl)); + + LOCK(&rwl->lock); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PRELOCK, "prelock"), rwl, type); +#endif + + if (type == isc_rwlocktype_read) { + if (rwl->readers_waiting != 0) + skip = ISC_TRUE; + while (!done) { + if (!skip && + ((rwl->active == 0 || + (rwl->type == isc_rwlocktype_read && + (rwl->writers_waiting == 0 || + rwl->granted < rwl->read_quota))))) + { + rwl->type = isc_rwlocktype_read; + rwl->active++; + rwl->granted++; + done = ISC_TRUE; + } else if (nonblock) { + result = ISC_R_LOCKBUSY; + done = ISC_TRUE; + } else { + skip = ISC_FALSE; + rwl->readers_waiting++; + WAIT(&rwl->readable, &rwl->lock); + rwl->readers_waiting--; + } + } + } else { + if (rwl->writers_waiting != 0) + skip = ISC_TRUE; + while (!done) { + if (!skip && rwl->active == 0) { + rwl->type = isc_rwlocktype_write; + rwl->active = 1; + rwl->granted++; + done = ISC_TRUE; + } else if (nonblock) { + result = ISC_R_LOCKBUSY; + done = ISC_TRUE; + } else { + skip = ISC_FALSE; + rwl->writers_waiting++; + WAIT(&rwl->writeable, &rwl->lock); + rwl->writers_waiting--; + } + } + } + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTLOCK, "postlock"), rwl, type); +#endif + + UNLOCK(&rwl->lock); + + return (result); +} + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + return (doit(rwl, type, ISC_FALSE)); +} + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + return (doit(rwl, type, ISC_TRUE)); +} + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_RWLOCK(rwl)); + LOCK(&rwl->lock); + REQUIRE(rwl->type == isc_rwlocktype_read); + REQUIRE(rwl->active != 0); + + /* If we are the only reader then succeed. */ + if (rwl->active == 1) { + rwl->original = (rwl->original == isc_rwlocktype_none) ? + isc_rwlocktype_read : isc_rwlocktype_none; + rwl->type = isc_rwlocktype_write; + } else + result = ISC_R_LOCKBUSY; + + UNLOCK(&rwl->lock); + return (result); +} + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl) { + + REQUIRE(VALID_RWLOCK(rwl)); + LOCK(&rwl->lock); + REQUIRE(rwl->type == isc_rwlocktype_write); + REQUIRE(rwl->active == 1); + + rwl->type = isc_rwlocktype_read; + rwl->original = (rwl->original == isc_rwlocktype_none) ? + isc_rwlocktype_write : isc_rwlocktype_none; + /* + * Resume processing any read request that were blocked when + * we upgraded. + */ + if (rwl->original == isc_rwlocktype_none && + (rwl->writers_waiting == 0 || rwl->granted < rwl->read_quota) && + rwl->readers_waiting > 0) + BROADCAST(&rwl->readable); + + UNLOCK(&rwl->lock); +} + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + + REQUIRE(VALID_RWLOCK(rwl)); + LOCK(&rwl->lock); + REQUIRE(rwl->type == type); + + UNUSED(type); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_PREUNLOCK, "preunlock"), rwl, type); +#endif + + INSIST(rwl->active > 0); + rwl->active--; + if (rwl->active == 0) { + if (rwl->original != isc_rwlocktype_none) { + rwl->type = rwl->original; + rwl->original = isc_rwlocktype_none; + } + if (rwl->type == isc_rwlocktype_read) { + rwl->granted = 0; + if (rwl->writers_waiting > 0) { + rwl->type = isc_rwlocktype_write; + SIGNAL(&rwl->writeable); + } else if (rwl->readers_waiting > 0) { + /* Does this case ever happen? */ + BROADCAST(&rwl->readable); + } + } else { + if (rwl->readers_waiting > 0) { + if (rwl->writers_waiting > 0 && + rwl->granted < rwl->write_quota) { + SIGNAL(&rwl->writeable); + } else { + rwl->granted = 0; + rwl->type = isc_rwlocktype_read; + BROADCAST(&rwl->readable); + } + } else if (rwl->writers_waiting > 0) { + rwl->granted = 0; + SIGNAL(&rwl->writeable); + } else { + rwl->granted = 0; + } + } + } + INSIST(rwl->original == isc_rwlocktype_none); + +#ifdef ISC_RWLOCK_TRACE + print_lock(isc_msgcat_get(isc_msgcat, ISC_MSGSET_RWLOCK, + ISC_MSG_POSTUNLOCK, "postunlock"), + rwl, type); +#endif + + UNLOCK(&rwl->lock); + + return (ISC_R_SUCCESS); +} + +#endif /* ISC_PLATFORM_HAVEXADD && ISC_PLATFORM_HAVECMPXCHG */ +#else /* ISC_PLATFORM_USETHREADS */ + +isc_result_t +isc_rwlock_init(isc_rwlock_t *rwl, unsigned int read_quota, + unsigned int write_quota) +{ + REQUIRE(rwl != NULL); + + UNUSED(read_quota); + UNUSED(write_quota); + + rwl->type = isc_rwlocktype_read; + rwl->active = 0; + rwl->magic = RWLOCK_MAGIC; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_lock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + REQUIRE(VALID_RWLOCK(rwl)); + + if (type == isc_rwlocktype_read) { + if (rwl->type != isc_rwlocktype_read && rwl->active != 0) + return (ISC_R_LOCKBUSY); + rwl->type = isc_rwlocktype_read; + rwl->active++; + } else { + if (rwl->active != 0) + return (ISC_R_LOCKBUSY); + rwl->type = isc_rwlocktype_write; + rwl->active = 1; + } + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_rwlock_trylock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + return (isc_rwlock_lock(rwl, type)); +} + +isc_result_t +isc_rwlock_tryupgrade(isc_rwlock_t *rwl) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_RWLOCK(rwl)); + REQUIRE(rwl->type == isc_rwlocktype_read); + REQUIRE(rwl->active != 0); + + /* If we are the only reader then succeed. */ + if (rwl->active == 1) + rwl->type = isc_rwlocktype_write; + else + result = ISC_R_LOCKBUSY; + return (result); +} + +void +isc_rwlock_downgrade(isc_rwlock_t *rwl) { + + REQUIRE(VALID_RWLOCK(rwl)); + REQUIRE(rwl->type == isc_rwlocktype_write); + REQUIRE(rwl->active == 1); + + rwl->type = isc_rwlocktype_read; +} + +isc_result_t +isc_rwlock_unlock(isc_rwlock_t *rwl, isc_rwlocktype_t type) { + REQUIRE(VALID_RWLOCK(rwl)); + REQUIRE(rwl->type == type); + + UNUSED(type); + + INSIST(rwl->active > 0); + rwl->active--; + + return (ISC_R_SUCCESS); +} + +void +isc_rwlock_destroy(isc_rwlock_t *rwl) { + REQUIRE(rwl != NULL); + REQUIRE(rwl->active == 0); + rwl->magic = 0; +} + +#endif /* ISC_PLATFORM_USETHREADS */ diff --git a/contrib/ntp/lib/isc/serial.c b/contrib/ntp/lib/isc/serial.c new file mode 100644 index 000000000..b43aac7ed --- /dev/null +++ b/contrib/ntp/lib/isc/serial.c @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: serial.c,v 1.12 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +isc_boolean_t +isc_serial_lt(isc_uint32_t a, isc_uint32_t b) { + /* + * Undefined => ISC_FALSE + */ + if (a == (b ^ 0x80000000U)) + return (ISC_FALSE); + return (((isc_int32_t)(a - b) < 0) ? ISC_TRUE : ISC_FALSE); +} + +isc_boolean_t +isc_serial_gt(isc_uint32_t a, isc_uint32_t b) { + return (((isc_int32_t)(a - b) > 0) ? ISC_TRUE : ISC_FALSE); +} + +isc_boolean_t +isc_serial_le(isc_uint32_t a, isc_uint32_t b) { + return ((a == b) ? ISC_TRUE : isc_serial_lt(a, b)); +} + +isc_boolean_t +isc_serial_ge(isc_uint32_t a, isc_uint32_t b) { + return ((a == b) ? ISC_TRUE : isc_serial_gt(a, b)); +} + +isc_boolean_t +isc_serial_eq(isc_uint32_t a, isc_uint32_t b) { + return ((a == b) ? ISC_TRUE : ISC_FALSE); +} + +isc_boolean_t +isc_serial_ne(isc_uint32_t a, isc_uint32_t b) { + return ((a != b) ? ISC_TRUE : ISC_FALSE); +} diff --git a/contrib/ntp/lib/isc/sha1.c b/contrib/ntp/lib/isc/sha1.c new file mode 100644 index 000000000..cce960360 --- /dev/null +++ b/contrib/ntp/lib/isc/sha1.c @@ -0,0 +1,354 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* $NetBSD: sha1.c,v 1.5 2000/01/22 22:19:14 mycroft Exp $ */ +/* $OpenBSD: sha1.c,v 1.9 1997/07/23 21:12:32 kstailey Exp $ */ + +/*! \file + * SHA-1 in C + * \author By Steve Reid + * 100% Public Domain + * \verbatim + * Test Vectors (from FIPS PUB 180-1) + * "abc" + * A9993E36 4706816A BA3E2571 7850C26C 9CD0D89D + * "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq" + * 84983E44 1C3BD26E BAAE4AA1 F95129E5 E54670F1 + * A million repetitions of "a" + * 34AA973C D4C4DAA4 F61EEB2B DBAD2731 6534016F + * \endverbatim + */ + +#include "config.h" + +#include +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_OPENSSLHASH + +void +isc_sha1_init(isc_sha1_t *context) +{ + INSIST(context != NULL); + + EVP_DigestInit(context, EVP_sha1()); +} + +void +isc_sha1_invalidate(isc_sha1_t *context) { + EVP_MD_CTX_cleanup(context); +} + +void +isc_sha1_update(isc_sha1_t *context, const unsigned char *data, + unsigned int len) +{ + INSIST(context != 0); + INSIST(data != 0); + + EVP_DigestUpdate(context, (const void *) data, (size_t) len); +} + +void +isc_sha1_final(isc_sha1_t *context, unsigned char *digest) { + INSIST(digest != 0); + INSIST(context != 0); + + EVP_DigestFinal(context, digest, NULL); +} + +#else + +#define rol(value, bits) (((value) << (bits)) | ((value) >> (32 - (bits)))) + +/*@{*/ +/*! + * blk0() and blk() perform the initial expand. + * I got the idea of expanding during the round function from SSLeay + */ +#if !defined(WORDS_BIGENDIAN) +# define blk0(i) \ + (block->l[i] = (rol(block->l[i], 24) & 0xFF00FF00) \ + | (rol(block->l[i], 8) & 0x00FF00FF)) +#else +# define blk0(i) block->l[i] +#endif +#define blk(i) \ + (block->l[i & 15] = rol(block->l[(i + 13) & 15] \ + ^ block->l[(i + 8) & 15] \ + ^ block->l[(i + 2) & 15] \ + ^ block->l[i & 15], 1)) + +/*@}*/ +/*@{*/ +/*! + * (R0+R1), R2, R3, R4 are the different operations (rounds) used in SHA1 + */ +#define R0(v,w,x,y,z,i) \ + z += ((w & (x ^ y)) ^ y) + blk0(i) + 0x5A827999 + rol(v, 5); \ + w = rol(w, 30); +#define R1(v,w,x,y,z,i) \ + z += ((w & (x ^ y)) ^ y) + blk(i) + 0x5A827999 + rol(v, 5); \ + w = rol(w, 30); +#define R2(v,w,x,y,z,i) \ + z += (w ^ x ^ y) + blk(i) + 0x6ED9EBA1 + rol(v, 5); \ + w = rol(w, 30); +#define R3(v,w,x,y,z,i) \ + z += (((w | x) & y) | (w & x)) + blk(i) + 0x8F1BBCDC + rol(v, 5); \ + w = rol(w, 30); +#define R4(v,w,x,y,z,i) \ + z += (w ^ x ^ y) + blk(i) + 0xCA62C1D6 + rol(v, 5); \ + w = rol(w, 30); + +/*@}*/ + +typedef union { + unsigned char c[64]; + unsigned int l[16]; +} CHAR64LONG16; + +#ifdef __sparc_v9__ +static void do_R01(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); +static void do_R2(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); +static void do_R3(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); +static void do_R4(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, + isc_uint32_t *d, isc_uint32_t *e, CHAR64LONG16 *); + +#define nR0(v,w,x,y,z,i) R0(*v,*w,*x,*y,*z,i) +#define nR1(v,w,x,y,z,i) R1(*v,*w,*x,*y,*z,i) +#define nR2(v,w,x,y,z,i) R2(*v,*w,*x,*y,*z,i) +#define nR3(v,w,x,y,z,i) R3(*v,*w,*x,*y,*z,i) +#define nR4(v,w,x,y,z,i) R4(*v,*w,*x,*y,*z,i) + +static void +do_R01(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR0(a,b,c,d,e, 0); nR0(e,a,b,c,d, 1); nR0(d,e,a,b,c, 2); + nR0(c,d,e,a,b, 3); nR0(b,c,d,e,a, 4); nR0(a,b,c,d,e, 5); + nR0(e,a,b,c,d, 6); nR0(d,e,a,b,c, 7); nR0(c,d,e,a,b, 8); + nR0(b,c,d,e,a, 9); nR0(a,b,c,d,e,10); nR0(e,a,b,c,d,11); + nR0(d,e,a,b,c,12); nR0(c,d,e,a,b,13); nR0(b,c,d,e,a,14); + nR0(a,b,c,d,e,15); nR1(e,a,b,c,d,16); nR1(d,e,a,b,c,17); + nR1(c,d,e,a,b,18); nR1(b,c,d,e,a,19); +} + +static void +do_R2(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR2(a,b,c,d,e,20); nR2(e,a,b,c,d,21); nR2(d,e,a,b,c,22); + nR2(c,d,e,a,b,23); nR2(b,c,d,e,a,24); nR2(a,b,c,d,e,25); + nR2(e,a,b,c,d,26); nR2(d,e,a,b,c,27); nR2(c,d,e,a,b,28); + nR2(b,c,d,e,a,29); nR2(a,b,c,d,e,30); nR2(e,a,b,c,d,31); + nR2(d,e,a,b,c,32); nR2(c,d,e,a,b,33); nR2(b,c,d,e,a,34); + nR2(a,b,c,d,e,35); nR2(e,a,b,c,d,36); nR2(d,e,a,b,c,37); + nR2(c,d,e,a,b,38); nR2(b,c,d,e,a,39); +} + +static void +do_R3(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR3(a,b,c,d,e,40); nR3(e,a,b,c,d,41); nR3(d,e,a,b,c,42); + nR3(c,d,e,a,b,43); nR3(b,c,d,e,a,44); nR3(a,b,c,d,e,45); + nR3(e,a,b,c,d,46); nR3(d,e,a,b,c,47); nR3(c,d,e,a,b,48); + nR3(b,c,d,e,a,49); nR3(a,b,c,d,e,50); nR3(e,a,b,c,d,51); + nR3(d,e,a,b,c,52); nR3(c,d,e,a,b,53); nR3(b,c,d,e,a,54); + nR3(a,b,c,d,e,55); nR3(e,a,b,c,d,56); nR3(d,e,a,b,c,57); + nR3(c,d,e,a,b,58); nR3(b,c,d,e,a,59); +} + +static void +do_R4(isc_uint32_t *a, isc_uint32_t *b, isc_uint32_t *c, isc_uint32_t *d, + isc_uint32_t *e, CHAR64LONG16 *block) +{ + nR4(a,b,c,d,e,60); nR4(e,a,b,c,d,61); nR4(d,e,a,b,c,62); + nR4(c,d,e,a,b,63); nR4(b,c,d,e,a,64); nR4(a,b,c,d,e,65); + nR4(e,a,b,c,d,66); nR4(d,e,a,b,c,67); nR4(c,d,e,a,b,68); + nR4(b,c,d,e,a,69); nR4(a,b,c,d,e,70); nR4(e,a,b,c,d,71); + nR4(d,e,a,b,c,72); nR4(c,d,e,a,b,73); nR4(b,c,d,e,a,74); + nR4(a,b,c,d,e,75); nR4(e,a,b,c,d,76); nR4(d,e,a,b,c,77); + nR4(c,d,e,a,b,78); nR4(b,c,d,e,a,79); +} +#endif + +/*! + * Hash a single 512-bit block. This is the core of the algorithm. + */ +static void +transform(isc_uint32_t state[5], const unsigned char buffer[64]) { + isc_uint32_t a, b, c, d, e; + CHAR64LONG16 *block; + CHAR64LONG16 workspace; + + INSIST(buffer != NULL); + INSIST(state != NULL); + + block = &workspace; + (void)memcpy(block, buffer, 64); + + /* Copy context->state[] to working vars */ + a = state[0]; + b = state[1]; + c = state[2]; + d = state[3]; + e = state[4]; + +#ifdef __sparc_v9__ + do_R01(&a, &b, &c, &d, &e, block); + do_R2(&a, &b, &c, &d, &e, block); + do_R3(&a, &b, &c, &d, &e, block); + do_R4(&a, &b, &c, &d, &e, block); +#else + /* 4 rounds of 20 operations each. Loop unrolled. */ + R0(a,b,c,d,e, 0); R0(e,a,b,c,d, 1); R0(d,e,a,b,c, 2); R0(c,d,e,a,b, 3); + R0(b,c,d,e,a, 4); R0(a,b,c,d,e, 5); R0(e,a,b,c,d, 6); R0(d,e,a,b,c, 7); + R0(c,d,e,a,b, 8); R0(b,c,d,e,a, 9); R0(a,b,c,d,e,10); R0(e,a,b,c,d,11); + R0(d,e,a,b,c,12); R0(c,d,e,a,b,13); R0(b,c,d,e,a,14); R0(a,b,c,d,e,15); + R1(e,a,b,c,d,16); R1(d,e,a,b,c,17); R1(c,d,e,a,b,18); R1(b,c,d,e,a,19); + R2(a,b,c,d,e,20); R2(e,a,b,c,d,21); R2(d,e,a,b,c,22); R2(c,d,e,a,b,23); + R2(b,c,d,e,a,24); R2(a,b,c,d,e,25); R2(e,a,b,c,d,26); R2(d,e,a,b,c,27); + R2(c,d,e,a,b,28); R2(b,c,d,e,a,29); R2(a,b,c,d,e,30); R2(e,a,b,c,d,31); + R2(d,e,a,b,c,32); R2(c,d,e,a,b,33); R2(b,c,d,e,a,34); R2(a,b,c,d,e,35); + R2(e,a,b,c,d,36); R2(d,e,a,b,c,37); R2(c,d,e,a,b,38); R2(b,c,d,e,a,39); + R3(a,b,c,d,e,40); R3(e,a,b,c,d,41); R3(d,e,a,b,c,42); R3(c,d,e,a,b,43); + R3(b,c,d,e,a,44); R3(a,b,c,d,e,45); R3(e,a,b,c,d,46); R3(d,e,a,b,c,47); + R3(c,d,e,a,b,48); R3(b,c,d,e,a,49); R3(a,b,c,d,e,50); R3(e,a,b,c,d,51); + R3(d,e,a,b,c,52); R3(c,d,e,a,b,53); R3(b,c,d,e,a,54); R3(a,b,c,d,e,55); + R3(e,a,b,c,d,56); R3(d,e,a,b,c,57); R3(c,d,e,a,b,58); R3(b,c,d,e,a,59); + R4(a,b,c,d,e,60); R4(e,a,b,c,d,61); R4(d,e,a,b,c,62); R4(c,d,e,a,b,63); + R4(b,c,d,e,a,64); R4(a,b,c,d,e,65); R4(e,a,b,c,d,66); R4(d,e,a,b,c,67); + R4(c,d,e,a,b,68); R4(b,c,d,e,a,69); R4(a,b,c,d,e,70); R4(e,a,b,c,d,71); + R4(d,e,a,b,c,72); R4(c,d,e,a,b,73); R4(b,c,d,e,a,74); R4(a,b,c,d,e,75); + R4(e,a,b,c,d,76); R4(d,e,a,b,c,77); R4(c,d,e,a,b,78); R4(b,c,d,e,a,79); +#endif + + /* Add the working vars back into context.state[] */ + state[0] += a; + state[1] += b; + state[2] += c; + state[3] += d; + state[4] += e; + + /* Wipe variables */ + a = b = c = d = e = 0; + /* Avoid compiler warnings */ + POST(a); POST(b); POST(c); POST(d); POST(e); +} + + +/*! + * isc_sha1_init - Initialize new context + */ +void +isc_sha1_init(isc_sha1_t *context) +{ + INSIST(context != NULL); + + /* SHA1 initialization constants */ + context->state[0] = 0x67452301; + context->state[1] = 0xEFCDAB89; + context->state[2] = 0x98BADCFE; + context->state[3] = 0x10325476; + context->state[4] = 0xC3D2E1F0; + context->count[0] = 0; + context->count[1] = 0; +} + +void +isc_sha1_invalidate(isc_sha1_t *context) { + memset(context, 0, sizeof(isc_sha1_t)); +} + +/*! + * Run your data through this. + */ +void +isc_sha1_update(isc_sha1_t *context, const unsigned char *data, + unsigned int len) +{ + unsigned int i, j; + + INSIST(context != 0); + INSIST(data != 0); + + j = context->count[0]; + if ((context->count[0] += len << 3) < j) + context->count[1] += (len >> 29) + 1; + j = (j >> 3) & 63; + if ((j + len) > 63) { + (void)memcpy(&context->buffer[j], data, (i = 64 - j)); + transform(context->state, context->buffer); + for (; i + 63 < len; i += 64) + transform(context->state, &data[i]); + j = 0; + } else { + i = 0; + } + + (void)memcpy(&context->buffer[j], &data[i], len - i); +} + + +/*! + * Add padding and return the message digest. + */ + +static const unsigned char final_200 = 128; +static const unsigned char final_0 = 0; + +void +isc_sha1_final(isc_sha1_t *context, unsigned char *digest) { + unsigned int i; + unsigned char finalcount[8]; + + INSIST(digest != 0); + INSIST(context != 0); + + for (i = 0; i < 8; i++) { + /* Endian independent */ + finalcount[i] = (unsigned char) + ((context->count[(i >= 4 ? 0 : 1)] + >> ((3 - (i & 3)) * 8)) & 255); + } + + isc_sha1_update(context, &final_200, 1); + while ((context->count[0] & 504) != 448) + isc_sha1_update(context, &final_0, 1); + /* The next Update should cause a transform() */ + isc_sha1_update(context, finalcount, 8); + + if (digest) { + for (i = 0; i < 20; i++) + digest[i] = (unsigned char) + ((context->state[i >> 2] + >> ((3 - (i & 3)) * 8)) & 255); + } + + memset(context, 0, sizeof(isc_sha1_t)); +} +#endif diff --git a/contrib/ntp/lib/isc/sha2.c b/contrib/ntp/lib/isc/sha2.c new file mode 100644 index 000000000..5a1d708fe --- /dev/null +++ b/contrib/ntp/lib/isc/sha2.c @@ -0,0 +1,1449 @@ +/* + * Copyright (C) 2005-2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* $FreeBSD: 258945 2013-12-04 21:33:17Z roberto $ */ +/* $KAME: sha2.c,v 1.8 2001/11/08 01:07:52 itojun Exp $ */ + +/* + * sha2.c + * + * Version 1.0.0beta1 + * + * Written by Aaron D. Gifford + * + * Copyright 2000 Aaron D. Gifford. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the copyright holder nor the names of contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) AND CONTRIBUTOR(S) ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR(S) OR CONTRIBUTOR(S) BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + */ + + +#include + +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_OPENSSLHASH + +void +isc_sha224_init(isc_sha224_t *context) { + if (context == (isc_sha224_t *)0) { + return; + } + EVP_DigestInit(context, EVP_sha224()); +} + +void +isc_sha224_invalidate(isc_sha224_t *context) { + EVP_MD_CTX_cleanup(context); +} + +void +isc_sha224_update(isc_sha224_t *context, const isc_uint8_t* data, size_t len) { + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha224_t *)0 && data != (isc_uint8_t*)0); + + EVP_DigestUpdate(context, (const void *) data, len); +} + +void +isc_sha224_final(isc_uint8_t digest[], isc_sha224_t *context) { + /* Sanity check: */ + REQUIRE(context != (isc_sha224_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + EVP_DigestFinal(context, digest, NULL); + } else { + EVP_MD_CTX_cleanup(context); + } +} + +void +isc_sha256_init(isc_sha256_t *context) { + if (context == (isc_sha256_t *)0) { + return; + } + EVP_DigestInit(context, EVP_sha256()); +} + +void +isc_sha256_invalidate(isc_sha256_t *context) { + EVP_MD_CTX_cleanup(context); +} + +void +isc_sha256_update(isc_sha256_t *context, const isc_uint8_t *data, size_t len) { + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0 && data != (isc_uint8_t*)0); + + EVP_DigestUpdate(context, (const void *) data, len); +} + +void +isc_sha256_final(isc_uint8_t digest[], isc_sha256_t *context) { + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + EVP_DigestFinal(context, digest, NULL); + } else { + EVP_MD_CTX_cleanup(context); + } +} + +void +isc_sha512_init(isc_sha512_t *context) { + if (context == (isc_sha512_t *)0) { + return; + } + EVP_DigestInit(context, EVP_sha512()); +} + +void +isc_sha512_invalidate(isc_sha512_t *context) { + EVP_MD_CTX_cleanup(context); +} + +void isc_sha512_update(isc_sha512_t *context, const isc_uint8_t *data, size_t len) { + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0 && data != (isc_uint8_t*)0); + + EVP_DigestUpdate(context, (const void *) data, len); +} + +void isc_sha512_final(isc_uint8_t digest[], isc_sha512_t *context) { + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + EVP_DigestFinal(context, digest, NULL); + } else { + EVP_MD_CTX_cleanup(context); + } +} + +void +isc_sha384_init(isc_sha384_t *context) { + if (context == (isc_sha384_t *)0) { + return; + } + EVP_DigestInit(context, EVP_sha384()); +} + +void +isc_sha384_invalidate(isc_sha384_t *context) { + EVP_MD_CTX_cleanup(context); +} + +void +isc_sha384_update(isc_sha384_t *context, const isc_uint8_t* data, size_t len) { + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0 && data != (isc_uint8_t*)0); + + EVP_DigestUpdate(context, (const void *) data, len); +} + +void +isc_sha384_final(isc_uint8_t digest[], isc_sha384_t *context) { + /* Sanity check: */ + REQUIRE(context != (isc_sha384_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + EVP_DigestFinal(context, digest, NULL); + } else { + EVP_MD_CTX_cleanup(context); + } +} + +#else + +/* + * UNROLLED TRANSFORM LOOP NOTE: + * You can define SHA2_UNROLL_TRANSFORM to use the unrolled transform + * loop version for the hash transform rounds (defined using macros + * later in this file). Either define on the command line, for example: + * + * cc -DISC_SHA2_UNROLL_TRANSFORM -o sha2 sha2.c sha2prog.c + * + * or define below: + * + * \#define ISC_SHA2_UNROLL_TRANSFORM + * + */ + +/*** SHA-256/384/512 Machine Architecture Definitions *****************/ +/* + * BYTE_ORDER NOTE: + * + * Please make sure that your system defines BYTE_ORDER. If your + * architecture is little-endian, make sure it also defines + * LITTLE_ENDIAN and that the two (BYTE_ORDER and LITTLE_ENDIAN) are + * equivalent. + * + * If your system does not define the above, then you can do so by + * hand like this: + * + * \#define LITTLE_ENDIAN 1234 + * \#define BIG_ENDIAN 4321 + * + * And for little-endian machines, add: + * + * \#define BYTE_ORDER LITTLE_ENDIAN + * + * Or for big-endian machines: + * + * \#define BYTE_ORDER BIG_ENDIAN + * + * The FreeBSD machine this was written on defines BYTE_ORDER + * appropriately by including (which in turn includes + * where the appropriate definitions are actually + * made). + */ +#if !defined(BYTE_ORDER) || (BYTE_ORDER != LITTLE_ENDIAN && BYTE_ORDER != BIG_ENDIAN) +#ifndef BYTE_ORDER +#ifndef BIG_ENDIAN +#define BIG_ENDIAN 4321 +#endif +#ifndef LITTLE_ENDIAN +#define LITTLE_ENDIAN 1234 +#endif +#ifdef WORDS_BIGENDIAN +#define BYTE_ORDER BIG_ENDIAN +#else +#define BYTE_ORDER LITTLE_ENDIAN +#endif +#else +#error Define BYTE_ORDER to be equal to either LITTLE_ENDIAN or BIG_ENDIAN +#endif +#endif + +/*** SHA-256/384/512 Various Length Definitions ***********************/ +/* NOTE: Most of these are in sha2.h */ +#define ISC_SHA256_SHORT_BLOCK_LENGTH (ISC_SHA256_BLOCK_LENGTH - 8) +#define ISC_SHA384_SHORT_BLOCK_LENGTH (ISC_SHA384_BLOCK_LENGTH - 16) +#define ISC_SHA512_SHORT_BLOCK_LENGTH (ISC_SHA512_BLOCK_LENGTH - 16) + + +/*** ENDIAN REVERSAL MACROS *******************************************/ +#if BYTE_ORDER == LITTLE_ENDIAN +#define REVERSE32(w,x) { \ + isc_uint32_t tmp = (w); \ + tmp = (tmp >> 16) | (tmp << 16); \ + (x) = ((tmp & 0xff00ff00UL) >> 8) | ((tmp & 0x00ff00ffUL) << 8); \ +} +#ifdef WIN32 +#define REVERSE64(w,x) { \ + isc_uint64_t tmp = (w); \ + tmp = (tmp >> 32) | (tmp << 32); \ + tmp = ((tmp & 0xff00ff00ff00ff00UL) >> 8) | \ + ((tmp & 0x00ff00ff00ff00ffUL) << 8); \ + (x) = ((tmp & 0xffff0000ffff0000UL) >> 16) | \ + ((tmp & 0x0000ffff0000ffffUL) << 16); \ +} +#else +#define REVERSE64(w,x) { \ + isc_uint64_t tmp = (w); \ + tmp = (tmp >> 32) | (tmp << 32); \ + tmp = ((tmp & 0xff00ff00ff00ff00ULL) >> 8) | \ + ((tmp & 0x00ff00ff00ff00ffULL) << 8); \ + (x) = ((tmp & 0xffff0000ffff0000ULL) >> 16) | \ + ((tmp & 0x0000ffff0000ffffULL) << 16); \ +} +#endif +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + +/* + * Macro for incrementally adding the unsigned 64-bit integer n to the + * unsigned 128-bit integer (represented using a two-element array of + * 64-bit words): + */ +#define ADDINC128(w,n) { \ + (w)[0] += (isc_uint64_t)(n); \ + if ((w)[0] < (n)) { \ + (w)[1]++; \ + } \ +} + +/*** THE SIX LOGICAL FUNCTIONS ****************************************/ +/* + * Bit shifting and rotation (used by the six SHA-XYZ logical functions: + * + * NOTE: The naming of R and S appears backwards here (R is a SHIFT and + * S is a ROTATION) because the SHA-256/384/512 description document + * (see http://csrc.nist.gov/cryptval/shs/sha256-384-512.pdf) uses this + * same "backwards" definition. + */ +/* Shift-right (used in SHA-256, SHA-384, and SHA-512): */ +#define R(b,x) ((x) >> (b)) +/* 32-bit Rotate-right (used in SHA-256): */ +#define S32(b,x) (((x) >> (b)) | ((x) << (32 - (b)))) +/* 64-bit Rotate-right (used in SHA-384 and SHA-512): */ +#define S64(b,x) (((x) >> (b)) | ((x) << (64 - (b)))) + +/* Two of six logical functions used in SHA-256, SHA-384, and SHA-512: */ +#define Ch(x,y,z) (((x) & (y)) ^ ((~(x)) & (z))) +#define Maj(x,y,z) (((x) & (y)) ^ ((x) & (z)) ^ ((y) & (z))) + +/* Four of six logical functions used in SHA-256: */ +#define Sigma0_256(x) (S32(2, (x)) ^ S32(13, (x)) ^ S32(22, (x))) +#define Sigma1_256(x) (S32(6, (x)) ^ S32(11, (x)) ^ S32(25, (x))) +#define sigma0_256(x) (S32(7, (x)) ^ S32(18, (x)) ^ R(3 , (x))) +#define sigma1_256(x) (S32(17, (x)) ^ S32(19, (x)) ^ R(10, (x))) + +/* Four of six logical functions used in SHA-384 and SHA-512: */ +#define Sigma0_512(x) (S64(28, (x)) ^ S64(34, (x)) ^ S64(39, (x))) +#define Sigma1_512(x) (S64(14, (x)) ^ S64(18, (x)) ^ S64(41, (x))) +#define sigma0_512(x) (S64( 1, (x)) ^ S64( 8, (x)) ^ R( 7, (x))) +#define sigma1_512(x) (S64(19, (x)) ^ S64(61, (x)) ^ R( 6, (x))) + +/*** INTERNAL FUNCTION PROTOTYPES *************************************/ +/* NOTE: These should not be accessed directly from outside this + * library -- they are intended for private internal visibility/use + * only. + */ +void isc_sha512_last(isc_sha512_t *); +void isc_sha256_transform(isc_sha256_t *, const isc_uint32_t*); +void isc_sha512_transform(isc_sha512_t *, const isc_uint64_t*); + + +/*** SHA-XYZ INITIAL HASH VALUES AND CONSTANTS ************************/ +/* Hash constant words K for SHA-224 and SHA-256: */ +static const isc_uint32_t K256[64] = { + 0x428a2f98UL, 0x71374491UL, 0xb5c0fbcfUL, 0xe9b5dba5UL, + 0x3956c25bUL, 0x59f111f1UL, 0x923f82a4UL, 0xab1c5ed5UL, + 0xd807aa98UL, 0x12835b01UL, 0x243185beUL, 0x550c7dc3UL, + 0x72be5d74UL, 0x80deb1feUL, 0x9bdc06a7UL, 0xc19bf174UL, + 0xe49b69c1UL, 0xefbe4786UL, 0x0fc19dc6UL, 0x240ca1ccUL, + 0x2de92c6fUL, 0x4a7484aaUL, 0x5cb0a9dcUL, 0x76f988daUL, + 0x983e5152UL, 0xa831c66dUL, 0xb00327c8UL, 0xbf597fc7UL, + 0xc6e00bf3UL, 0xd5a79147UL, 0x06ca6351UL, 0x14292967UL, + 0x27b70a85UL, 0x2e1b2138UL, 0x4d2c6dfcUL, 0x53380d13UL, + 0x650a7354UL, 0x766a0abbUL, 0x81c2c92eUL, 0x92722c85UL, + 0xa2bfe8a1UL, 0xa81a664bUL, 0xc24b8b70UL, 0xc76c51a3UL, + 0xd192e819UL, 0xd6990624UL, 0xf40e3585UL, 0x106aa070UL, + 0x19a4c116UL, 0x1e376c08UL, 0x2748774cUL, 0x34b0bcb5UL, + 0x391c0cb3UL, 0x4ed8aa4aUL, 0x5b9cca4fUL, 0x682e6ff3UL, + 0x748f82eeUL, 0x78a5636fUL, 0x84c87814UL, 0x8cc70208UL, + 0x90befffaUL, 0xa4506cebUL, 0xbef9a3f7UL, 0xc67178f2UL +}; + +/* Initial hash value H for SHA-224: */ +static const isc_uint32_t sha224_initial_hash_value[8] = { + 0xc1059ed8UL, + 0x367cd507UL, + 0x3070dd17UL, + 0xf70e5939UL, + 0xffc00b31UL, + 0x68581511UL, + 0x64f98fa7UL, + 0xbefa4fa4UL +}; + +/* Initial hash value H for SHA-256: */ +static const isc_uint32_t sha256_initial_hash_value[8] = { + 0x6a09e667UL, + 0xbb67ae85UL, + 0x3c6ef372UL, + 0xa54ff53aUL, + 0x510e527fUL, + 0x9b05688cUL, + 0x1f83d9abUL, + 0x5be0cd19UL +}; + +#ifdef WIN32 +/* Hash constant words K for SHA-384 and SHA-512: */ +static const isc_uint64_t K512[80] = { + 0x428a2f98d728ae22UL, 0x7137449123ef65cdUL, + 0xb5c0fbcfec4d3b2fUL, 0xe9b5dba58189dbbcUL, + 0x3956c25bf348b538UL, 0x59f111f1b605d019UL, + 0x923f82a4af194f9bUL, 0xab1c5ed5da6d8118UL, + 0xd807aa98a3030242UL, 0x12835b0145706fbeUL, + 0x243185be4ee4b28cUL, 0x550c7dc3d5ffb4e2UL, + 0x72be5d74f27b896fUL, 0x80deb1fe3b1696b1UL, + 0x9bdc06a725c71235UL, 0xc19bf174cf692694UL, + 0xe49b69c19ef14ad2UL, 0xefbe4786384f25e3UL, + 0x0fc19dc68b8cd5b5UL, 0x240ca1cc77ac9c65UL, + 0x2de92c6f592b0275UL, 0x4a7484aa6ea6e483UL, + 0x5cb0a9dcbd41fbd4UL, 0x76f988da831153b5UL, + 0x983e5152ee66dfabUL, 0xa831c66d2db43210UL, + 0xb00327c898fb213fUL, 0xbf597fc7beef0ee4UL, + 0xc6e00bf33da88fc2UL, 0xd5a79147930aa725UL, + 0x06ca6351e003826fUL, 0x142929670a0e6e70UL, + 0x27b70a8546d22ffcUL, 0x2e1b21385c26c926UL, + 0x4d2c6dfc5ac42aedUL, 0x53380d139d95b3dfUL, + 0x650a73548baf63deUL, 0x766a0abb3c77b2a8UL, + 0x81c2c92e47edaee6UL, 0x92722c851482353bUL, + 0xa2bfe8a14cf10364UL, 0xa81a664bbc423001UL, + 0xc24b8b70d0f89791UL, 0xc76c51a30654be30UL, + 0xd192e819d6ef5218UL, 0xd69906245565a910UL, + 0xf40e35855771202aUL, 0x106aa07032bbd1b8UL, + 0x19a4c116b8d2d0c8UL, 0x1e376c085141ab53UL, + 0x2748774cdf8eeb99UL, 0x34b0bcb5e19b48a8UL, + 0x391c0cb3c5c95a63UL, 0x4ed8aa4ae3418acbUL, + 0x5b9cca4f7763e373UL, 0x682e6ff3d6b2b8a3UL, + 0x748f82ee5defb2fcUL, 0x78a5636f43172f60UL, + 0x84c87814a1f0ab72UL, 0x8cc702081a6439ecUL, + 0x90befffa23631e28UL, 0xa4506cebde82bde9UL, + 0xbef9a3f7b2c67915UL, 0xc67178f2e372532bUL, + 0xca273eceea26619cUL, 0xd186b8c721c0c207UL, + 0xeada7dd6cde0eb1eUL, 0xf57d4f7fee6ed178UL, + 0x06f067aa72176fbaUL, 0x0a637dc5a2c898a6UL, + 0x113f9804bef90daeUL, 0x1b710b35131c471bUL, + 0x28db77f523047d84UL, 0x32caab7b40c72493UL, + 0x3c9ebe0a15c9bebcUL, 0x431d67c49c100d4cUL, + 0x4cc5d4becb3e42b6UL, 0x597f299cfc657e2aUL, + 0x5fcb6fab3ad6faecUL, 0x6c44198c4a475817UL +}; + +/* Initial hash value H for SHA-384: */ +static const isc_uint64_t sha384_initial_hash_value[8] = { + 0xcbbb9d5dc1059ed8UL, + 0x629a292a367cd507UL, + 0x9159015a3070dd17UL, + 0x152fecd8f70e5939UL, + 0x67332667ffc00b31UL, + 0x8eb44a8768581511UL, + 0xdb0c2e0d64f98fa7UL, + 0x47b5481dbefa4fa4UL +}; + +/* Initial hash value H for SHA-512: */ +static const isc_uint64_t sha512_initial_hash_value[8] = { + 0x6a09e667f3bcc908U, + 0xbb67ae8584caa73bUL, + 0x3c6ef372fe94f82bUL, + 0xa54ff53a5f1d36f1UL, + 0x510e527fade682d1UL, + 0x9b05688c2b3e6c1fUL, + 0x1f83d9abfb41bd6bUL, + 0x5be0cd19137e2179UL +}; +#else +/* Hash constant words K for SHA-384 and SHA-512: */ +static const isc_uint64_t K512[80] = { + 0x428a2f98d728ae22ULL, 0x7137449123ef65cdULL, + 0xb5c0fbcfec4d3b2fULL, 0xe9b5dba58189dbbcULL, + 0x3956c25bf348b538ULL, 0x59f111f1b605d019ULL, + 0x923f82a4af194f9bULL, 0xab1c5ed5da6d8118ULL, + 0xd807aa98a3030242ULL, 0x12835b0145706fbeULL, + 0x243185be4ee4b28cULL, 0x550c7dc3d5ffb4e2ULL, + 0x72be5d74f27b896fULL, 0x80deb1fe3b1696b1ULL, + 0x9bdc06a725c71235ULL, 0xc19bf174cf692694ULL, + 0xe49b69c19ef14ad2ULL, 0xefbe4786384f25e3ULL, + 0x0fc19dc68b8cd5b5ULL, 0x240ca1cc77ac9c65ULL, + 0x2de92c6f592b0275ULL, 0x4a7484aa6ea6e483ULL, + 0x5cb0a9dcbd41fbd4ULL, 0x76f988da831153b5ULL, + 0x983e5152ee66dfabULL, 0xa831c66d2db43210ULL, + 0xb00327c898fb213fULL, 0xbf597fc7beef0ee4ULL, + 0xc6e00bf33da88fc2ULL, 0xd5a79147930aa725ULL, + 0x06ca6351e003826fULL, 0x142929670a0e6e70ULL, + 0x27b70a8546d22ffcULL, 0x2e1b21385c26c926ULL, + 0x4d2c6dfc5ac42aedULL, 0x53380d139d95b3dfULL, + 0x650a73548baf63deULL, 0x766a0abb3c77b2a8ULL, + 0x81c2c92e47edaee6ULL, 0x92722c851482353bULL, + 0xa2bfe8a14cf10364ULL, 0xa81a664bbc423001ULL, + 0xc24b8b70d0f89791ULL, 0xc76c51a30654be30ULL, + 0xd192e819d6ef5218ULL, 0xd69906245565a910ULL, + 0xf40e35855771202aULL, 0x106aa07032bbd1b8ULL, + 0x19a4c116b8d2d0c8ULL, 0x1e376c085141ab53ULL, + 0x2748774cdf8eeb99ULL, 0x34b0bcb5e19b48a8ULL, + 0x391c0cb3c5c95a63ULL, 0x4ed8aa4ae3418acbULL, + 0x5b9cca4f7763e373ULL, 0x682e6ff3d6b2b8a3ULL, + 0x748f82ee5defb2fcULL, 0x78a5636f43172f60ULL, + 0x84c87814a1f0ab72ULL, 0x8cc702081a6439ecULL, + 0x90befffa23631e28ULL, 0xa4506cebde82bde9ULL, + 0xbef9a3f7b2c67915ULL, 0xc67178f2e372532bULL, + 0xca273eceea26619cULL, 0xd186b8c721c0c207ULL, + 0xeada7dd6cde0eb1eULL, 0xf57d4f7fee6ed178ULL, + 0x06f067aa72176fbaULL, 0x0a637dc5a2c898a6ULL, + 0x113f9804bef90daeULL, 0x1b710b35131c471bULL, + 0x28db77f523047d84ULL, 0x32caab7b40c72493ULL, + 0x3c9ebe0a15c9bebcULL, 0x431d67c49c100d4cULL, + 0x4cc5d4becb3e42b6ULL, 0x597f299cfc657e2aULL, + 0x5fcb6fab3ad6faecULL, 0x6c44198c4a475817ULL +}; + +/* Initial hash value H for SHA-384: */ +static const isc_uint64_t sha384_initial_hash_value[8] = { + 0xcbbb9d5dc1059ed8ULL, + 0x629a292a367cd507ULL, + 0x9159015a3070dd17ULL, + 0x152fecd8f70e5939ULL, + 0x67332667ffc00b31ULL, + 0x8eb44a8768581511ULL, + 0xdb0c2e0d64f98fa7ULL, + 0x47b5481dbefa4fa4ULL +}; + +/* Initial hash value H for SHA-512: */ +static const isc_uint64_t sha512_initial_hash_value[8] = { + 0x6a09e667f3bcc908ULL, + 0xbb67ae8584caa73bULL, + 0x3c6ef372fe94f82bULL, + 0xa54ff53a5f1d36f1ULL, + 0x510e527fade682d1ULL, + 0x9b05688c2b3e6c1fULL, + 0x1f83d9abfb41bd6bULL, + 0x5be0cd19137e2179ULL +}; +#endif + + +/*** SHA-224: *********************************************************/ +void +isc_sha224_init(isc_sha224_t *context) { + if (context == (isc_sha256_t *)0) { + return; + } + memcpy(context->state, sha224_initial_hash_value, + ISC_SHA256_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA256_BLOCK_LENGTH); + context->bitcount = 0; +} + +void +isc_sha224_invalidate(isc_sha224_t *context) { + memset(context, 0, sizeof(isc_sha224_t)); +} + +void +isc_sha224_update(isc_sha224_t *context, const isc_uint8_t* data, size_t len) { + isc_sha256_update((isc_sha256_t *)context, data, len); +} + +void +isc_sha224_final(isc_uint8_t digest[], isc_sha224_t *context) { + isc_uint8_t sha256_digest[ISC_SHA256_DIGESTLENGTH]; + isc_sha256_final(sha256_digest, (isc_sha256_t *)context); + memcpy(digest, sha256_digest, ISC_SHA224_DIGESTLENGTH); + memset(sha256_digest, 0, ISC_SHA256_DIGESTLENGTH); +} + +/*** SHA-256: *********************************************************/ +void +isc_sha256_init(isc_sha256_t *context) { + if (context == (isc_sha256_t *)0) { + return; + } + memcpy(context->state, sha256_initial_hash_value, + ISC_SHA256_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA256_BLOCK_LENGTH); + context->bitcount = 0; +} + +void +isc_sha256_invalidate(isc_sha256_t *context) { + memset(context, 0, sizeof(isc_sha256_t)); +} + +#ifdef ISC_SHA2_UNROLL_TRANSFORM + +/* Unrolled SHA-256 round macros: */ + +#if BYTE_ORDER == LITTLE_ENDIAN + +#define ROUND256_0_TO_15(a,b,c,d,e,f,g,h) \ + REVERSE32(*data++, W256[j]); \ + T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + \ + K256[j] + W256[j]; \ + (d) += T1; \ + (h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \ + j++ + + +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND256_0_TO_15(a,b,c,d,e,f,g,h) \ + T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + \ + K256[j] + (W256[j] = *data++); \ + (d) += T1; \ + (h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \ + j++ + +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND256(a,b,c,d,e,f,g,h) \ + s0 = W256[(j+1)&0x0f]; \ + s0 = sigma0_256(s0); \ + s1 = W256[(j+14)&0x0f]; \ + s1 = sigma1_256(s1); \ + T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + K256[j] + \ + (W256[j&0x0f] += s1 + W256[(j+9)&0x0f] + s0); \ + (d) += T1; \ + (h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \ + j++ + +void isc_sha256_transform(isc_sha256_t *context, const isc_uint32_t* data) { + isc_uint32_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint32_t T1, *W256; + int j; + + W256 = (isc_uint32_t*)context->buffer; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { + /* Rounds 0 to 15 (unrolled): */ + ROUND256_0_TO_15(a,b,c,d,e,f,g,h); + ROUND256_0_TO_15(h,a,b,c,d,e,f,g); + ROUND256_0_TO_15(g,h,a,b,c,d,e,f); + ROUND256_0_TO_15(f,g,h,a,b,c,d,e); + ROUND256_0_TO_15(e,f,g,h,a,b,c,d); + ROUND256_0_TO_15(d,e,f,g,h,a,b,c); + ROUND256_0_TO_15(c,d,e,f,g,h,a,b); + ROUND256_0_TO_15(b,c,d,e,f,g,h,a); + } while (j < 16); + + /* Now for the remaining rounds to 64: */ + do { + ROUND256(a,b,c,d,e,f,g,h); + ROUND256(h,a,b,c,d,e,f,g); + ROUND256(g,h,a,b,c,d,e,f); + ROUND256(f,g,h,a,b,c,d,e); + ROUND256(e,f,g,h,a,b,c,d); + ROUND256(d,e,f,g,h,a,b,c); + ROUND256(c,d,e,f,g,h,a,b); + ROUND256(b,c,d,e,f,g,h,a); + } while (j < 64); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = 0; + /* Avoid compiler warnings */ + POST(a); POST(b); POST(c); POST(d); POST(e); POST(f); + POST(g); POST(h); POST(T1); +} + +#else /* ISC_SHA2_UNROLL_TRANSFORM */ + +void +isc_sha256_transform(isc_sha256_t *context, const isc_uint32_t* data) { + isc_uint32_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint32_t T1, T2, *W256; + int j; + + W256 = (isc_uint32_t*)context->buffer; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { +#if BYTE_ORDER == LITTLE_ENDIAN + /* Copy data while converting to host byte order */ + REVERSE32(*data++,W256[j]); + /* Apply the SHA-256 compression function to update a..h */ + T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + W256[j]; +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + /* Apply the SHA-256 compression function to update a..h with copy */ + T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + (W256[j] = *data++); +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + T2 = Sigma0_256(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 16); + + do { + /* Part of the message block expansion: */ + s0 = W256[(j+1)&0x0f]; + s0 = sigma0_256(s0); + s1 = W256[(j+14)&0x0f]; + s1 = sigma1_256(s1); + + /* Apply the SHA-256 compression function to update a..h */ + T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + + (W256[j&0x0f] += s1 + W256[(j+9)&0x0f] + s0); + T2 = Sigma0_256(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 64); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = T2 = 0; + /* Avoid compiler warnings */ + POST(a); POST(b); POST(c); POST(d); POST(e); POST(f); + POST(g); POST(h); POST(T1); POST(T2); +} + +#endif /* ISC_SHA2_UNROLL_TRANSFORM */ + +void +isc_sha256_update(isc_sha256_t *context, const isc_uint8_t *data, size_t len) { + unsigned int freespace, usedspace; + + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0 && data != (isc_uint8_t*)0); + + usedspace = (unsigned int)((context->bitcount >> 3) % + ISC_SHA256_BLOCK_LENGTH); + if (usedspace > 0) { + /* Calculate how much free space is available in the buffer */ + freespace = ISC_SHA256_BLOCK_LENGTH - usedspace; + + if (len >= freespace) { + /* Fill the buffer completely and process it */ + memcpy(&context->buffer[usedspace], data, freespace); + context->bitcount += freespace << 3; + len -= freespace; + data += freespace; + isc_sha256_transform(context, + (isc_uint32_t*)context->buffer); + } else { + /* The buffer is not yet full */ + memcpy(&context->buffer[usedspace], data, len); + context->bitcount += len << 3; + /* Clean up: */ + usedspace = freespace = 0; + /* Avoid compiler warnings: */ + POST(usedspace); POST(freespace); + return; + } + } + while (len >= ISC_SHA256_BLOCK_LENGTH) { + /* Process as many complete blocks as we can */ + memcpy(context->buffer, data, ISC_SHA256_BLOCK_LENGTH); + isc_sha256_transform(context, (isc_uint32_t*)context->buffer); + context->bitcount += ISC_SHA256_BLOCK_LENGTH << 3; + len -= ISC_SHA256_BLOCK_LENGTH; + data += ISC_SHA256_BLOCK_LENGTH; + } + if (len > 0U) { + /* There's left-overs, so save 'em */ + memcpy(context->buffer, data, len); + context->bitcount += len << 3; + } + /* Clean up: */ + usedspace = freespace = 0; + /* Avoid compiler warnings: */ + POST(usedspace); POST(freespace); +} + +void +isc_sha256_final(isc_uint8_t digest[], isc_sha256_t *context) { + isc_uint32_t *d = (isc_uint32_t*)digest; + unsigned int usedspace; + + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + usedspace = (unsigned int)((context->bitcount >> 3) % + ISC_SHA256_BLOCK_LENGTH); +#if BYTE_ORDER == LITTLE_ENDIAN + /* Convert FROM host byte order */ + REVERSE64(context->bitcount,context->bitcount); +#endif + if (usedspace > 0) { + /* Begin padding with a 1 bit: */ + context->buffer[usedspace++] = 0x80; + + if (usedspace <= ISC_SHA256_SHORT_BLOCK_LENGTH) { + /* Set-up for the last transform: */ + memset(&context->buffer[usedspace], 0, + ISC_SHA256_SHORT_BLOCK_LENGTH - usedspace); + } else { + if (usedspace < ISC_SHA256_BLOCK_LENGTH) { + memset(&context->buffer[usedspace], 0, + ISC_SHA256_BLOCK_LENGTH - + usedspace); + } + /* Do second-to-last transform: */ + isc_sha256_transform(context, + (isc_uint32_t*)context->buffer); + + /* And set-up for the last transform: */ + memset(context->buffer, 0, + ISC_SHA256_SHORT_BLOCK_LENGTH); + } + } else { + /* Set-up for the last transform: */ + memset(context->buffer, 0, ISC_SHA256_SHORT_BLOCK_LENGTH); + + /* Begin padding with a 1 bit: */ + *context->buffer = 0x80; + } + /* Set the bit count: */ + *(isc_uint64_t*)&context->buffer[ISC_SHA256_SHORT_BLOCK_LENGTH] = context->bitcount; + + /* Final transform: */ + isc_sha256_transform(context, (isc_uint32_t*)context->buffer); + +#if BYTE_ORDER == LITTLE_ENDIAN + { + /* Convert TO host byte order */ + int j; + for (j = 0; j < 8; j++) { + REVERSE32(context->state[j],context->state[j]); + *d++ = context->state[j]; + } + } +#else + memcpy(d, context->state, ISC_SHA256_DIGESTLENGTH); +#endif + } + + /* Clean up state data: */ + memset(context, 0, sizeof(*context)); + usedspace = 0; + POST(usedspace); +} + +/*** SHA-512: *********************************************************/ +void +isc_sha512_init(isc_sha512_t *context) { + if (context == (isc_sha512_t *)0) { + return; + } + memcpy(context->state, sha512_initial_hash_value, + ISC_SHA512_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA512_BLOCK_LENGTH); + context->bitcount[0] = context->bitcount[1] = 0; +} + +void +isc_sha512_invalidate(isc_sha512_t *context) { + memset(context, 0, sizeof(isc_sha512_t)); +} + +#ifdef ISC_SHA2_UNROLL_TRANSFORM + +/* Unrolled SHA-512 round macros: */ +#if BYTE_ORDER == LITTLE_ENDIAN + +#define ROUND512_0_TO_15(a,b,c,d,e,f,g,h) \ + REVERSE64(*data++, W512[j]); \ + T1 = (h) + Sigma1_512(e) + Ch((e), (f), (g)) + \ + K512[j] + W512[j]; \ + (d) += T1, \ + (h) = T1 + Sigma0_512(a) + Maj((a), (b), (c)), \ + j++ + + +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND512_0_TO_15(a,b,c,d,e,f,g,h) \ + T1 = (h) + Sigma1_512(e) + Ch((e), (f), (g)) + \ + K512[j] + (W512[j] = *data++); \ + (d) += T1; \ + (h) = T1 + Sigma0_512(a) + Maj((a), (b), (c)); \ + j++ + +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + +#define ROUND512(a,b,c,d,e,f,g,h) \ + s0 = W512[(j+1)&0x0f]; \ + s0 = sigma0_512(s0); \ + s1 = W512[(j+14)&0x0f]; \ + s1 = sigma1_512(s1); \ + T1 = (h) + Sigma1_512(e) + Ch((e), (f), (g)) + K512[j] + \ + (W512[j&0x0f] += s1 + W512[(j+9)&0x0f] + s0); \ + (d) += T1; \ + (h) = T1 + Sigma0_512(a) + Maj((a), (b), (c)); \ + j++ + +void isc_sha512_transform(isc_sha512_t *context, const isc_uint64_t* data) { + isc_uint64_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint64_t T1, *W512 = (isc_uint64_t*)context->buffer; + int j; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { + ROUND512_0_TO_15(a,b,c,d,e,f,g,h); + ROUND512_0_TO_15(h,a,b,c,d,e,f,g); + ROUND512_0_TO_15(g,h,a,b,c,d,e,f); + ROUND512_0_TO_15(f,g,h,a,b,c,d,e); + ROUND512_0_TO_15(e,f,g,h,a,b,c,d); + ROUND512_0_TO_15(d,e,f,g,h,a,b,c); + ROUND512_0_TO_15(c,d,e,f,g,h,a,b); + ROUND512_0_TO_15(b,c,d,e,f,g,h,a); + } while (j < 16); + + /* Now for the remaining rounds up to 79: */ + do { + ROUND512(a,b,c,d,e,f,g,h); + ROUND512(h,a,b,c,d,e,f,g); + ROUND512(g,h,a,b,c,d,e,f); + ROUND512(f,g,h,a,b,c,d,e); + ROUND512(e,f,g,h,a,b,c,d); + ROUND512(d,e,f,g,h,a,b,c); + ROUND512(c,d,e,f,g,h,a,b); + ROUND512(b,c,d,e,f,g,h,a); + } while (j < 80); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = 0; + /* Avoid compiler warnings */ + POST(a); POST(b); POST(c); POST(d); POST(e); POST(f); + POST(g); POST(h); POST(T1); +} + +#else /* ISC_SHA2_UNROLL_TRANSFORM */ + +void +isc_sha512_transform(isc_sha512_t *context, const isc_uint64_t* data) { + isc_uint64_t a, b, c, d, e, f, g, h, s0, s1; + isc_uint64_t T1, T2, *W512 = (isc_uint64_t*)context->buffer; + int j; + + /* Initialize registers with the prev. intermediate value */ + a = context->state[0]; + b = context->state[1]; + c = context->state[2]; + d = context->state[3]; + e = context->state[4]; + f = context->state[5]; + g = context->state[6]; + h = context->state[7]; + + j = 0; + do { +#if BYTE_ORDER == LITTLE_ENDIAN + /* Convert TO host byte order */ + REVERSE64(*data++, W512[j]); + /* Apply the SHA-512 compression function to update a..h */ + T1 = h + Sigma1_512(e) + Ch(e, f, g) + K512[j] + W512[j]; +#else /* BYTE_ORDER == LITTLE_ENDIAN */ + /* Apply the SHA-512 compression function to update a..h with copy */ + T1 = h + Sigma1_512(e) + Ch(e, f, g) + K512[j] + (W512[j] = *data++); +#endif /* BYTE_ORDER == LITTLE_ENDIAN */ + T2 = Sigma0_512(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 16); + + do { + /* Part of the message block expansion: */ + s0 = W512[(j+1)&0x0f]; + s0 = sigma0_512(s0); + s1 = W512[(j+14)&0x0f]; + s1 = sigma1_512(s1); + + /* Apply the SHA-512 compression function to update a..h */ + T1 = h + Sigma1_512(e) + Ch(e, f, g) + K512[j] + + (W512[j&0x0f] += s1 + W512[(j+9)&0x0f] + s0); + T2 = Sigma0_512(a) + Maj(a, b, c); + h = g; + g = f; + f = e; + e = d + T1; + d = c; + c = b; + b = a; + a = T1 + T2; + + j++; + } while (j < 80); + + /* Compute the current intermediate hash value */ + context->state[0] += a; + context->state[1] += b; + context->state[2] += c; + context->state[3] += d; + context->state[4] += e; + context->state[5] += f; + context->state[6] += g; + context->state[7] += h; + + /* Clean up */ + a = b = c = d = e = f = g = h = T1 = T2 = 0; + /* Avoid compiler warnings */ + POST(a); POST(b); POST(c); POST(d); POST(e); POST(f); + POST(g); POST(h); POST(T1); POST(T2); +} + +#endif /* ISC_SHA2_UNROLL_TRANSFORM */ + +void isc_sha512_update(isc_sha512_t *context, const isc_uint8_t *data, size_t len) { + unsigned int freespace, usedspace; + + if (len == 0U) { + /* Calling with no data is valid - we do nothing */ + return; + } + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0 && data != (isc_uint8_t*)0); + + usedspace = (unsigned int)((context->bitcount[0] >> 3) % + ISC_SHA512_BLOCK_LENGTH); + if (usedspace > 0) { + /* Calculate how much free space is available in the buffer */ + freespace = ISC_SHA512_BLOCK_LENGTH - usedspace; + + if (len >= freespace) { + /* Fill the buffer completely and process it */ + memcpy(&context->buffer[usedspace], data, freespace); + ADDINC128(context->bitcount, freespace << 3); + len -= freespace; + data += freespace; + isc_sha512_transform(context, + (isc_uint64_t*)context->buffer); + } else { + /* The buffer is not yet full */ + memcpy(&context->buffer[usedspace], data, len); + ADDINC128(context->bitcount, len << 3); + /* Clean up: */ + usedspace = freespace = 0; + /* Avoid compiler warnings: */ + POST(usedspace); POST(freespace); + return; + } + } + while (len >= ISC_SHA512_BLOCK_LENGTH) { + /* Process as many complete blocks as we can */ + memcpy(context->buffer, data, ISC_SHA512_BLOCK_LENGTH); + isc_sha512_transform(context, (isc_uint64_t*)context->buffer); + ADDINC128(context->bitcount, ISC_SHA512_BLOCK_LENGTH << 3); + len -= ISC_SHA512_BLOCK_LENGTH; + data += ISC_SHA512_BLOCK_LENGTH; + } + if (len > 0U) { + /* There's left-overs, so save 'em */ + memcpy(context->buffer, data, len); + ADDINC128(context->bitcount, len << 3); + } + /* Clean up: */ + usedspace = freespace = 0; + /* Avoid compiler warnings: */ + POST(usedspace); POST(freespace); +} + +void isc_sha512_last(isc_sha512_t *context) { + unsigned int usedspace; + + usedspace = (unsigned int)((context->bitcount[0] >> 3) % + ISC_SHA512_BLOCK_LENGTH); +#if BYTE_ORDER == LITTLE_ENDIAN + /* Convert FROM host byte order */ + REVERSE64(context->bitcount[0],context->bitcount[0]); + REVERSE64(context->bitcount[1],context->bitcount[1]); +#endif + if (usedspace > 0) { + /* Begin padding with a 1 bit: */ + context->buffer[usedspace++] = 0x80; + + if (usedspace <= ISC_SHA512_SHORT_BLOCK_LENGTH) { + /* Set-up for the last transform: */ + memset(&context->buffer[usedspace], 0, + ISC_SHA512_SHORT_BLOCK_LENGTH - usedspace); + } else { + if (usedspace < ISC_SHA512_BLOCK_LENGTH) { + memset(&context->buffer[usedspace], 0, + ISC_SHA512_BLOCK_LENGTH - usedspace); + } + /* Do second-to-last transform: */ + isc_sha512_transform(context, + (isc_uint64_t*)context->buffer); + + /* And set-up for the last transform: */ + memset(context->buffer, 0, ISC_SHA512_BLOCK_LENGTH - 2); + } + } else { + /* Prepare for final transform: */ + memset(context->buffer, 0, ISC_SHA512_SHORT_BLOCK_LENGTH); + + /* Begin padding with a 1 bit: */ + *context->buffer = 0x80; + } + /* Store the length of input data (in bits): */ + *(isc_uint64_t*)&context->buffer[ISC_SHA512_SHORT_BLOCK_LENGTH] = context->bitcount[1]; + *(isc_uint64_t*)&context->buffer[ISC_SHA512_SHORT_BLOCK_LENGTH+8] = context->bitcount[0]; + + /* Final transform: */ + isc_sha512_transform(context, (isc_uint64_t*)context->buffer); +} + +void isc_sha512_final(isc_uint8_t digest[], isc_sha512_t *context) { + isc_uint64_t *d = (isc_uint64_t*)digest; + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + isc_sha512_last(context); + + /* Save the hash data for output: */ +#if BYTE_ORDER == LITTLE_ENDIAN + { + /* Convert TO host byte order */ + int j; + for (j = 0; j < 8; j++) { + REVERSE64(context->state[j],context->state[j]); + *d++ = context->state[j]; + } + } +#else + memcpy(d, context->state, ISC_SHA512_DIGESTLENGTH); +#endif + } + + /* Zero out state data */ + memset(context, 0, sizeof(*context)); +} + + +/*** SHA-384: *********************************************************/ +void +isc_sha384_init(isc_sha384_t *context) { + if (context == (isc_sha384_t *)0) { + return; + } + memcpy(context->state, sha384_initial_hash_value, + ISC_SHA512_DIGESTLENGTH); + memset(context->buffer, 0, ISC_SHA384_BLOCK_LENGTH); + context->bitcount[0] = context->bitcount[1] = 0; +} + +void +isc_sha384_invalidate(isc_sha384_t *context) { + memset(context, 0, sizeof(isc_sha384_t)); +} + +void +isc_sha384_update(isc_sha384_t *context, const isc_uint8_t* data, size_t len) { + isc_sha512_update((isc_sha512_t *)context, data, len); +} + +void +isc_sha384_final(isc_uint8_t digest[], isc_sha384_t *context) { + isc_uint64_t *d = (isc_uint64_t*)digest; + + /* Sanity check: */ + REQUIRE(context != (isc_sha384_t *)0); + + /* If no digest buffer is passed, we don't bother doing this: */ + if (digest != (isc_uint8_t*)0) { + isc_sha512_last((isc_sha512_t *)context); + + /* Save the hash data for output: */ +#if BYTE_ORDER == LITTLE_ENDIAN + { + /* Convert TO host byte order */ + int j; + for (j = 0; j < 6; j++) { + REVERSE64(context->state[j],context->state[j]); + *d++ = context->state[j]; + } + } +#else + memcpy(d, context->state, ISC_SHA384_DIGESTLENGTH); +#endif + } + + /* Zero out state data */ + memset(context, 0, sizeof(*context)); +} +#endif /* !ISC_PLATFORM_OPENSSLHASH */ + +/* + * Constant used by SHA256/384/512_End() functions for converting the + * digest to a readable hexadecimal character string: + */ +static const char *sha2_hex_digits = "0123456789abcdef"; + +char * +isc_sha224_end(isc_sha224_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA224_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha224_t *)0); + + if (buffer != (char*)0) { + isc_sha224_final(digest, context); + + for (i = 0; i < ISC_SHA224_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { +#ifdef ISC_PLATFORM_OPENSSLHASH + EVP_MD_CTX_cleanup(context); +#else + memset(context, 0, sizeof(*context)); +#endif + } + memset(digest, 0, ISC_SHA224_DIGESTLENGTH); + return buffer; +} + +char * +isc_sha224_data(const isc_uint8_t *data, size_t len, + char digest[ISC_SHA224_DIGESTSTRINGLENGTH]) +{ + isc_sha224_t context; + + isc_sha224_init(&context); + isc_sha224_update(&context, data, len); + return (isc_sha224_end(&context, digest)); +} + +char * +isc_sha256_end(isc_sha256_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA256_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha256_t *)0); + + if (buffer != (char*)0) { + isc_sha256_final(digest, context); + + for (i = 0; i < ISC_SHA256_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { +#ifdef ISC_PLATFORM_OPENSSLHASH + EVP_MD_CTX_cleanup(context); +#else + memset(context, 0, sizeof(*context)); +#endif + } + memset(digest, 0, ISC_SHA256_DIGESTLENGTH); + return buffer; +} + +char * +isc_sha256_data(const isc_uint8_t* data, size_t len, + char digest[ISC_SHA256_DIGESTSTRINGLENGTH]) +{ + isc_sha256_t context; + + isc_sha256_init(&context); + isc_sha256_update(&context, data, len); + return (isc_sha256_end(&context, digest)); +} + +char * +isc_sha512_end(isc_sha512_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA512_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha512_t *)0); + + if (buffer != (char*)0) { + isc_sha512_final(digest, context); + + for (i = 0; i < ISC_SHA512_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { +#ifdef ISC_PLATFORM_OPENSSLHASH + EVP_MD_CTX_cleanup(context); +#else + memset(context, 0, sizeof(*context)); +#endif + } + memset(digest, 0, ISC_SHA512_DIGESTLENGTH); + return buffer; +} + +char * +isc_sha512_data(const isc_uint8_t *data, size_t len, + char digest[ISC_SHA512_DIGESTSTRINGLENGTH]) +{ + isc_sha512_t context; + + isc_sha512_init(&context); + isc_sha512_update(&context, data, len); + return (isc_sha512_end(&context, digest)); +} + +char * +isc_sha384_end(isc_sha384_t *context, char buffer[]) { + isc_uint8_t digest[ISC_SHA384_DIGESTLENGTH], *d = digest; + unsigned int i; + + /* Sanity check: */ + REQUIRE(context != (isc_sha384_t *)0); + + if (buffer != (char*)0) { + isc_sha384_final(digest, context); + + for (i = 0; i < ISC_SHA384_DIGESTLENGTH; i++) { + *buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4]; + *buffer++ = sha2_hex_digits[*d & 0x0f]; + d++; + } + *buffer = (char)0; + } else { +#ifdef ISC_PLATFORM_OPENSSLHASH + EVP_MD_CTX_cleanup(context); +#else + memset(context, 0, sizeof(*context)); +#endif + } + memset(digest, 0, ISC_SHA384_DIGESTLENGTH); + return buffer; +} + +char * +isc_sha384_data(const isc_uint8_t *data, size_t len, + char digest[ISC_SHA384_DIGESTSTRINGLENGTH]) +{ + isc_sha384_t context; + + isc_sha384_init(&context); + isc_sha384_update(&context, data, len); + return (isc_sha384_end(&context, digest)); +} diff --git a/contrib/ntp/libisc/sockaddr.c b/contrib/ntp/lib/isc/sockaddr.c similarity index 77% rename from contrib/ntp/libisc/sockaddr.c rename to contrib/ntp/lib/isc/sockaddr.c index 33d7a1b91..1ae5e7c91 100644 --- a/contrib/ntp/libisc/sockaddr.c +++ b/contrib/ntp/lib/isc/sockaddr.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2007, 2010-2012 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,22 +15,16 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: sockaddr.c,v 1.48.2.1.2.10 2004/05/15 03:46:12 jinmei Exp $ */ +/* $Id$ */ -#include +/*! \file */ -#define ISC_ONLY_IPV6 +#include #include #include -/* - * We currently don't need hashing here - */ -#if 0 #include -#endif - #include #include #include @@ -41,6 +35,21 @@ isc_boolean_t isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { + return (isc_sockaddr_compare(a, b, ISC_SOCKADDR_CMPADDR| + ISC_SOCKADDR_CMPPORT| + ISC_SOCKADDR_CMPSCOPE)); +} + +isc_boolean_t +isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { + return (isc_sockaddr_compare(a, b, ISC_SOCKADDR_CMPADDR| + ISC_SOCKADDR_CMPSCOPE)); +} + +isc_boolean_t +isc_sockaddr_compare(const isc_sockaddr_t *a, const isc_sockaddr_t *b, + unsigned int flags) +{ REQUIRE(a != NULL && b != NULL); if (a->length != b->length) @@ -55,21 +64,33 @@ isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { return (ISC_FALSE); switch (a->type.sa.sa_family) { case AF_INET: - if (memcmp(&a->type.sin.sin_addr, &b->type.sin.sin_addr, + if ((flags & ISC_SOCKADDR_CMPADDR) != 0 && + memcmp(&a->type.sin.sin_addr, &b->type.sin.sin_addr, sizeof(a->type.sin.sin_addr)) != 0) return (ISC_FALSE); - if (a->type.sin.sin_port != b->type.sin.sin_port) + if ((flags & ISC_SOCKADDR_CMPPORT) != 0 && + a->type.sin.sin_port != b->type.sin.sin_port) return (ISC_FALSE); break; case AF_INET6: - if (memcmp(&a->type.sin6.sin6_addr, &b->type.sin6.sin6_addr, + if ((flags & ISC_SOCKADDR_CMPADDR) != 0 && + memcmp(&a->type.sin6.sin6_addr, &b->type.sin6.sin6_addr, sizeof(a->type.sin6.sin6_addr)) != 0) return (ISC_FALSE); #ifdef ISC_PLATFORM_HAVESCOPEID - if (a->type.sin6.sin6_scope_id != b->type.sin6.sin6_scope_id) + /* + * If ISC_SOCKADDR_CMPSCOPEZERO is set then don't return + * ISC_FALSE if one of the scopes in zero. + */ + if ((flags & ISC_SOCKADDR_CMPSCOPE) != 0 && + a->type.sin6.sin6_scope_id != b->type.sin6.sin6_scope_id && + ((flags & ISC_SOCKADDR_CMPSCOPEZERO) == 0 || + (a->type.sin6.sin6_scope_id != 0 && + b->type.sin6.sin6_scope_id != 0))) return (ISC_FALSE); #endif - if (a->type.sin6.sin6_port != b->type.sin6.sin6_port) + if ((flags & ISC_SOCKADDR_CMPPORT) != 0 && + a->type.sin6.sin6_port != b->type.sin6.sin6_port) return (ISC_FALSE); break; default: @@ -79,37 +100,6 @@ isc_sockaddr_equal(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { return (ISC_TRUE); } -isc_boolean_t -isc_sockaddr_eqaddr(const isc_sockaddr_t *a, const isc_sockaddr_t *b) { - REQUIRE(a != NULL && b != NULL); - - if (a->length != b->length) - return (ISC_FALSE); - - if (a->type.sa.sa_family != b->type.sa.sa_family) - return (ISC_FALSE); - switch (a->type.sa.sa_family) { - case AF_INET: - if (memcmp(&a->type.sin.sin_addr, &b->type.sin.sin_addr, - sizeof(a->type.sin.sin_addr)) != 0) - return (ISC_FALSE); - break; - case AF_INET6: - if (memcmp(&a->type.sin6.sin6_addr, &b->type.sin6.sin6_addr, - sizeof(a->type.sin6.sin6_addr)) != 0) - return (ISC_FALSE); -#ifdef ISC_PLATFORM_HAVESCOPEID - if (a->type.sin6.sin6_scope_id != b->type.sin6.sin6_scope_id) - return (ISC_FALSE); -#endif - break; - default: - if (memcmp(&a->type, &b->type, a->length) != 0) - return (ISC_FALSE); - } - return (ISC_TRUE); -} - isc_boolean_t isc_sockaddr_eqaddrprefix(const isc_sockaddr_t *a, const isc_sockaddr_t *b, unsigned int prefixlen) @@ -142,6 +132,23 @@ isc_sockaddr_totext(const isc_sockaddr_t *sockaddr, isc_buffer_t *target) { case AF_INET6: snprintf(pbuf, sizeof(pbuf), "%u", ntohs(sockaddr->type.sin6.sin6_port)); break; +#ifdef ISC_PLAFORM_HAVESYSUNH + case AF_UNIX: + plen = strlen(sockaddr->type.sunix.sun_path); + if (plen >= isc_buffer_availablelength(target)) + return (ISC_R_NOSPACE); + + isc_buffer_putmem(target, sockaddr->type.sunix.sun_path, plen); + + /* + * Null terminate after used region. + */ + isc_buffer_availableregion(target, &avail); + INSIST(avail.length >= 1); + avail.base[0] = '\0'; + + return (ISC_R_SUCCESS); +#endif default: return (ISC_R_FAILURE); } @@ -175,6 +182,9 @@ isc_sockaddr_format(const isc_sockaddr_t *sa, char *array, unsigned int size) { isc_result_t result; isc_buffer_t buf; + if (size == 0U) + return; + isc_buffer_init(&buf, array, size); result = isc_sockaddr_totext(sa, &buf); if (result != ISC_R_SUCCESS) { @@ -182,18 +192,15 @@ isc_sockaddr_format(const isc_sockaddr_t *sa, char *array, unsigned int size) { * The message is the same as in netaddr.c. */ snprintf(array, size, + "<%s %u>", isc_msgcat_get(isc_msgcat, ISC_MSGSET_NETADDR, ISC_MSG_UNKNOWNADDR, - ""), + "unknown address, family"), sa->type.sa.sa_family); array[size - 1] = '\0'; } } -#if 0 -/* - * We currently don't need hashing here - */ unsigned int isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only) { unsigned int length = 0; @@ -211,11 +218,10 @@ isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only) { p = ntohs(sockaddr->type.sin.sin_port); length = sizeof(sockaddr->type.sin.sin_addr.s_addr); break; -#if ISC_PLATFORM_HAVEIPV6 case AF_INET6: in6 = &sockaddr->type.sin6.sin6_addr; if (IN6_IS_ADDR_V4MAPPED(in6)) { - s = (const unsigned char *)&in6[12]; + s = (const unsigned char *)&in6 + 12; length = sizeof(sockaddr->type.sin.sin_addr.s_addr); } else { s = (const unsigned char *)in6; @@ -223,13 +229,13 @@ isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only) { } p = ntohs(sockaddr->type.sin6.sin6_port); break; -#endif default: UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s: %d", isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, ISC_MSG_UNKNOWNFAMILY, - "unknown address family: %d"), + "unknown address family"), (int)sockaddr->type.sa.sa_family); s = (const unsigned char *)&sockaddr->type; length = sockaddr->length; @@ -245,7 +251,6 @@ isc_sockaddr_hash(const isc_sockaddr_t *sockaddr, isc_boolean_t address_only) { return (h); } -#endif void isc_sockaddr_any(isc_sockaddr_t *sockaddr) @@ -264,7 +269,6 @@ isc_sockaddr_any(isc_sockaddr_t *sockaddr) void isc_sockaddr_any6(isc_sockaddr_t *sockaddr) { -#ifdef ISC_PLATFORM_HAVEIPV6 memset(sockaddr, 0, sizeof(*sockaddr)); sockaddr->type.sin6.sin6_family = AF_INET6; #ifdef ISC_PLATFORM_HAVESALEN @@ -274,7 +278,6 @@ isc_sockaddr_any6(isc_sockaddr_t *sockaddr) sockaddr->type.sin6.sin6_port = 0; sockaddr->length = sizeof(sockaddr->type.sin6); ISC_LINK_INIT(sockaddr, link); -#endif } void @@ -371,7 +374,7 @@ isc_sockaddr_fromnetaddr(isc_sockaddr_t *sockaddr, const isc_netaddr_t *na, in_port_t port) { memset(sockaddr, 0, sizeof(*sockaddr)); - sockaddr->type.sin.sin_family = na->family; + sockaddr->type.sin.sin_family = (short)na->family; switch (na->family) { case AF_INET: sockaddr->length = sizeof(sockaddr->type.sin); @@ -392,8 +395,8 @@ isc_sockaddr_fromnetaddr(isc_sockaddr_t *sockaddr, const isc_netaddr_t *na, #endif sockaddr->type.sin6.sin6_port = htons(port); break; - default: - INSIST(0); + default: + INSIST(0); } ISC_LINK_INIT(sockaddr, link); } @@ -409,15 +412,16 @@ isc_sockaddr_setport(isc_sockaddr_t *sockaddr, in_port_t port) { break; default: FATAL_ERROR(__FILE__, __LINE__, + "%s: %d", isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, ISC_MSG_UNKNOWNFAMILY, - "unknown address family: %d"), + "unknown address family"), (int)sockaddr->type.sa.sa_family); } } in_port_t -isc_sockaddr_getport(isc_sockaddr_t *sockaddr) { +isc_sockaddr_getport(const isc_sockaddr_t *sockaddr) { in_port_t port = 0; switch (sockaddr->type.sa.sa_family) { @@ -429,9 +433,10 @@ isc_sockaddr_getport(isc_sockaddr_t *sockaddr) { break; default: FATAL_ERROR(__FILE__, __LINE__, + "%s: %d", isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKADDR, ISC_MSG_UNKNOWNFAMILY, - "unknown address family: %d"), + "unknown address family"), (int)sockaddr->type.sa.sa_family); } @@ -439,15 +444,19 @@ isc_sockaddr_getport(isc_sockaddr_t *sockaddr) { } isc_boolean_t -isc_sockaddr_ismulticast(isc_sockaddr_t *sockaddr) { +isc_sockaddr_ismulticast(const isc_sockaddr_t *sockaddr) { isc_netaddr_t netaddr; - isc_netaddr_fromsockaddr(&netaddr, sockaddr); - return (isc_netaddr_ismulticast(&netaddr)); + if (sockaddr->type.sa.sa_family == AF_INET || + sockaddr->type.sa.sa_family == AF_INET6) { + isc_netaddr_fromsockaddr(&netaddr, sockaddr); + return (isc_netaddr_ismulticast(&netaddr)); + } + return (ISC_FALSE); } isc_boolean_t -isc_sockaddr_isexperimental(isc_sockaddr_t *sockaddr) { +isc_sockaddr_isexperimental(const isc_sockaddr_t *sockaddr) { isc_netaddr_t netaddr; if (sockaddr->type.sa.sa_family == AF_INET) { @@ -458,7 +467,7 @@ isc_sockaddr_isexperimental(isc_sockaddr_t *sockaddr) { } isc_boolean_t -isc_sockaddr_issitelocal(isc_sockaddr_t *sockaddr) { +isc_sockaddr_issitelocal(const isc_sockaddr_t *sockaddr) { isc_netaddr_t netaddr; if (sockaddr->type.sa.sa_family == AF_INET6) { @@ -469,7 +478,7 @@ isc_sockaddr_issitelocal(isc_sockaddr_t *sockaddr) { } isc_boolean_t -isc_sockaddr_islinklocal(isc_sockaddr_t *sockaddr) { +isc_sockaddr_islinklocal(const isc_sockaddr_t *sockaddr) { isc_netaddr_t netaddr; if (sockaddr->type.sa.sa_family == AF_INET6) { @@ -478,3 +487,24 @@ isc_sockaddr_islinklocal(isc_sockaddr_t *sockaddr) { } return (ISC_FALSE); } + +isc_result_t +isc_sockaddr_frompath(isc_sockaddr_t *sockaddr, const char *path) { +#ifdef ISC_PLATFORM_HAVESYSUNH + if (strlen(path) >= sizeof(sockaddr->type.sunix.sun_path)) + return (ISC_R_NOSPACE); + memset(sockaddr, 0, sizeof(*sockaddr)); + sockaddr->length = sizeof(sockaddr->type.sunix); + sockaddr->type.sunix.sun_family = AF_UNIX; +#ifdef ISC_PLATFORM_HAVESALEN + sockaddr->type.sunix.sun_len = + (unsigned char)sizeof(sockaddr->type.sunix); +#endif + strcpy(sockaddr->type.sunix.sun_path, path); + return (ISC_R_SUCCESS); +#else + UNUSED(sockaddr); + UNUSED(path); + return (ISC_R_NOTIMPLEMENTED); +#endif +} diff --git a/contrib/ntp/lib/isc/socket_api.c b/contrib/ntp/lib/isc/socket_api.c new file mode 100644 index 000000000..3394ce059 --- /dev/null +++ b/contrib/ntp/lib/isc/socket_api.c @@ -0,0 +1,231 @@ +/* + * Copyright (C) 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#include + +#include +#include +#include +#include +#include +#include + +static isc_mutex_t createlock; +static isc_once_t once = ISC_ONCE_INIT; +static isc_socketmgrcreatefunc_t socketmgr_createfunc = NULL; + +static void +initialize(void) { + RUNTIME_CHECK(isc_mutex_init(&createlock) == ISC_R_SUCCESS); +} + +isc_result_t +isc_socket_register(isc_socketmgrcreatefunc_t createfunc) { + isc_result_t result = ISC_R_SUCCESS; + + RUNTIME_CHECK(isc_once_do(&once, initialize) == ISC_R_SUCCESS); + + LOCK(&createlock); + if (socketmgr_createfunc == NULL) + socketmgr_createfunc = createfunc; + else + result = ISC_R_EXISTS; + UNLOCK(&createlock); + + return (result); +} + +isc_result_t +isc_socketmgr_createinctx(isc_mem_t *mctx, isc_appctx_t *actx, + isc_socketmgr_t **managerp) +{ + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(socketmgr_createfunc != NULL); + result = (*socketmgr_createfunc)(mctx, managerp); + + UNLOCK(&createlock); + + if (result == ISC_R_SUCCESS) + isc_appctx_setsocketmgr(actx, *managerp); + + return (result); +} + +isc_result_t +isc_socketmgr_create(isc_mem_t *mctx, isc_socketmgr_t **managerp) { + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(socketmgr_createfunc != NULL); + result = (*socketmgr_createfunc)(mctx, managerp); + + UNLOCK(&createlock); + + return (result); +} + +void +isc_socketmgr_destroy(isc_socketmgr_t **managerp) { + REQUIRE(managerp != NULL && ISCAPI_SOCKETMGR_VALID(*managerp)); + + (*managerp)->methods->destroy(managerp); + + ENSURE(*managerp == NULL); +} + +isc_result_t +isc_socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type, + isc_socket_t **socketp) +{ + REQUIRE(ISCAPI_SOCKETMGR_VALID(manager)); + + return (manager->methods->socketcreate(manager, pf, type, socketp)); +} + +void +isc_socket_attach(isc_socket_t *sock, isc_socket_t **socketp) { + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + REQUIRE(socketp != NULL && *socketp == NULL); + + sock->methods->attach(sock, socketp); + + ENSURE(*socketp == sock); +} + +void +isc_socket_detach(isc_socket_t **socketp) { + REQUIRE(socketp != NULL && ISCAPI_SOCKET_VALID(*socketp)); + + (*socketp)->methods->detach(socketp); + + ENSURE(*socketp == NULL); +} + +isc_result_t +isc_socket_bind(isc_socket_t *sock, isc_sockaddr_t *sockaddr, + unsigned int options) +{ + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return (sock->methods->bind(sock, sockaddr, options)); +} + +isc_result_t +isc_socket_sendto(isc_socket_t *sock, isc_region_t *region, isc_task_t *task, + isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo) +{ + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return (sock->methods->sendto(sock, region, task, action, arg, address, + pktinfo)); +} + +isc_result_t +isc_socket_connect(isc_socket_t *sock, isc_sockaddr_t *addr, isc_task_t *task, + isc_taskaction_t action, const void *arg) +{ + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return (sock->methods->connect(sock, addr, task, action, arg)); +} + +isc_result_t +isc_socket_recv(isc_socket_t *sock, isc_region_t *region, unsigned int minimum, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return (sock->methods->recv(sock, region, minimum, task, action, arg)); +} + +void +isc_socket_cancel(isc_socket_t *sock, isc_task_t *task, unsigned int how) { + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + sock->methods->cancel(sock, task, how); +} + +isc_result_t +isc_socket_getsockname(isc_socket_t *sock, isc_sockaddr_t *addressp) { + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return (sock->methods->getsockname(sock, addressp)); +} + +void +isc_socket_ipv6only(isc_socket_t *sock, isc_boolean_t yes) { + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + sock->methods->ipv6only(sock, yes); +} + +isc_sockettype_t +isc_socket_gettype(isc_socket_t *sock) { + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return (sock->methods->gettype(sock)); +} + +void +isc_socket_setname(isc_socket_t *socket, const char *name, void *tag) { + REQUIRE(ISCAPI_SOCKET_VALID(socket)); + + UNUSED(socket); /* in case REQUIRE() is empty */ + UNUSED(name); + UNUSED(tag); +} + +isc_result_t +isc_socket_fdwatchcreate(isc_socketmgr_t *manager, int fd, int flags, + isc_sockfdwatch_t callback, void *cbarg, + isc_task_t *task, isc_socket_t **socketp) +{ + REQUIRE(ISCAPI_SOCKETMGR_VALID(manager)); + + return (manager->methods->fdwatchcreate(manager, fd, flags, + callback, cbarg, task, + socketp)); +} + +isc_result_t +isc_socket_fdwatchpoke(isc_socket_t *sock, int flags) +{ + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return(sock->methods->fdwatchpoke(sock, flags)); +} + +isc_result_t +isc_socket_dup(isc_socket_t *sock, isc_socket_t **socketp) { + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + REQUIRE(socketp != NULL && *socketp == NULL); + + return(sock->methods->dup(sock, socketp)); +} + +int +isc_socket_getfd(isc_socket_t *sock) { + REQUIRE(ISCAPI_SOCKET_VALID(sock)); + + return(sock->methods->getfd(sock)); +} diff --git a/contrib/ntp/lib/isc/sparc64/include/isc/atomic.h b/contrib/ntp/lib/isc/sparc64/include/isc/atomic.h new file mode 100644 index 000000000..ab17de131 --- /dev/null +++ b/contrib/ntp/lib/isc/sparc64/include/isc/atomic.h @@ -0,0 +1,127 @@ +/* + * Copyright (C) 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.5 2007/06/19 23:47:18 tbox Exp $ */ + +/* + * This code was written based on FreeBSD's kernel source whose copyright + * follows: + */ + +/*- + * Copyright (c) 1998 Doug Rabson. + * Copyright (c) 2001 Jake Burkholder. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * from: FreeBSD: src/sys/i386/include/atomic.h,v 1.20 2001/02/11 + * $FreeBSD: 258945 2013-12-04 21:33:17Z roberto $ + */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#define ASI_P 0x80 /* Primary Address Space Identifier */ + +#ifdef ISC_PLATFORM_USEGCCASM + +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + */ +static inline isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t prev, swapped; + + for (prev = *(volatile isc_int32_t *)p; ; prev = swapped) { + swapped = prev + val; + __asm__ volatile( + "casa [%1] %2, %3, %0" + : "+r"(swapped) + : "r"(p), "n"(ASI_P), "r"(prev)); + if (swapped == prev) + break; + } + + return (prev); +} + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static inline void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + isc_int32_t prev, swapped; + + for (prev = *(volatile isc_int32_t *)p; ; prev = swapped) { + swapped = val; + __asm__ volatile( + "casa [%1] %2, %3, %0" + : "+r"(swapped) + : "r"(p), "n"(ASI_P), "r"(prev) + : "memory"); + if (swapped == prev) + break; + } +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static inline isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + isc_int32_t temp = val; + + __asm__ volatile( + "casa [%1] %2, %3, %0" + : "+r"(temp) + : "r"(p), "n"(ASI_P), "r"(cmpval)); + + return (temp); +} + +#else /* ISC_PLATFORM_USEGCCASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif /* ISC_PLATFORM_USEGCCASM */ + +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/lib/isc/stats.c b/contrib/ntp/lib/isc/stats.c new file mode 100644 index 000000000..8b624b2d4 --- /dev/null +++ b/contrib/ntp/lib/isc/stats.c @@ -0,0 +1,326 @@ +/* + * Copyright (C) 2009, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define ISC_STATS_MAGIC ISC_MAGIC('S', 't', 'a', 't') +#define ISC_STATS_VALID(x) ISC_MAGIC_VALID(x, ISC_STATS_MAGIC) + +#ifndef ISC_STATS_USEMULTIFIELDS +#if defined(ISC_RWLOCK_USEATOMIC) && defined(ISC_PLATFORM_HAVEXADD) && !defined(ISC_PLATFORM_HAVEXADDQ) +#define ISC_STATS_USEMULTIFIELDS 1 +#else +#define ISC_STATS_USEMULTIFIELDS 0 +#endif +#endif /* ISC_STATS_USEMULTIFIELDS */ + +#if ISC_STATS_USEMULTIFIELDS +typedef struct { + isc_uint32_t hi; + isc_uint32_t lo; +} isc_stat_t; +#else +typedef isc_uint64_t isc_stat_t; +#endif + +struct isc_stats { + /*% Unlocked */ + unsigned int magic; + isc_mem_t *mctx; + int ncounters; + + isc_mutex_t lock; + unsigned int references; /* locked by lock */ + + /*% + * Locked by counterlock or unlocked if efficient rwlock is not + * available. + */ +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_t counterlock; +#endif + isc_stat_t *counters; + + /*% + * We don't want to lock the counters while we are dumping, so we first + * copy the current counter values into a local array. This buffer + * will be used as the copy destination. It's allocated on creation + * of the stats structure so that the dump operation won't fail due + * to memory allocation failure. + * XXX: this approach is weird for non-threaded build because the + * additional memory and the copy overhead could be avoided. We prefer + * simplicity here, however, under the assumption that this function + * should be only rarely called. + */ + isc_uint64_t *copiedcounters; +}; + +static isc_result_t +create_stats(isc_mem_t *mctx, int ncounters, isc_stats_t **statsp) { + isc_stats_t *stats; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(statsp != NULL && *statsp == NULL); + + stats = isc_mem_get(mctx, sizeof(*stats)); + if (stats == NULL) + return (ISC_R_NOMEMORY); + + result = isc_mutex_init(&stats->lock); + if (result != ISC_R_SUCCESS) + goto clean_stats; + + stats->counters = isc_mem_get(mctx, sizeof(isc_stat_t) * ncounters); + if (stats->counters == NULL) { + result = ISC_R_NOMEMORY; + goto clean_mutex; + } + stats->copiedcounters = isc_mem_get(mctx, + sizeof(isc_uint64_t) * ncounters); + if (stats->copiedcounters == NULL) { + result = ISC_R_NOMEMORY; + goto clean_counters; + } + +#ifdef ISC_RWLOCK_USEATOMIC + result = isc_rwlock_init(&stats->counterlock, 0, 0); + if (result != ISC_R_SUCCESS) + goto clean_copiedcounters; +#endif + + stats->references = 1; + memset(stats->counters, 0, sizeof(isc_stat_t) * ncounters); + stats->mctx = NULL; + isc_mem_attach(mctx, &stats->mctx); + stats->ncounters = ncounters; + stats->magic = ISC_STATS_MAGIC; + + *statsp = stats; + + return (result); + +clean_counters: + isc_mem_put(mctx, stats->counters, sizeof(isc_stat_t) * ncounters); + +#ifdef ISC_RWLOCK_USEATOMIC +clean_copiedcounters: + isc_mem_put(mctx, stats->copiedcounters, + sizeof(isc_stat_t) * ncounters); +#endif + +clean_mutex: + DESTROYLOCK(&stats->lock); + +clean_stats: + isc_mem_put(mctx, stats, sizeof(*stats)); + + return (result); +} + +void +isc_stats_attach(isc_stats_t *stats, isc_stats_t **statsp) { + REQUIRE(ISC_STATS_VALID(stats)); + REQUIRE(statsp != NULL && *statsp == NULL); + + LOCK(&stats->lock); + stats->references++; + UNLOCK(&stats->lock); + + *statsp = stats; +} + +void +isc_stats_detach(isc_stats_t **statsp) { + isc_stats_t *stats; + + REQUIRE(statsp != NULL && ISC_STATS_VALID(*statsp)); + + stats = *statsp; + *statsp = NULL; + + LOCK(&stats->lock); + stats->references--; + UNLOCK(&stats->lock); + + if (stats->references == 0) { + isc_mem_put(stats->mctx, stats->copiedcounters, + sizeof(isc_stat_t) * stats->ncounters); + isc_mem_put(stats->mctx, stats->counters, + sizeof(isc_stat_t) * stats->ncounters); + DESTROYLOCK(&stats->lock); +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_destroy(&stats->counterlock); +#endif + isc_mem_putanddetach(&stats->mctx, stats, sizeof(*stats)); + } +} + +int +isc_stats_ncounters(isc_stats_t *stats) { + REQUIRE(ISC_STATS_VALID(stats)); + + return (stats->ncounters); +} + +static inline void +incrementcounter(isc_stats_t *stats, int counter) { + isc_int32_t prev; + +#ifdef ISC_RWLOCK_USEATOMIC + /* + * We use a "read" lock to prevent other threads from reading the + * counter while we "writing" a counter field. The write access itself + * is protected by the atomic operation. + */ + isc_rwlock_lock(&stats->counterlock, isc_rwlocktype_read); +#endif + +#if ISC_STATS_USEMULTIFIELDS + prev = isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].lo, 1); + /* + * If the lower 32-bit field overflows, increment the higher field. + * Note that it's *theoretically* possible that the lower field + * overlaps again before the higher field is incremented. It doesn't + * matter, however, because we don't read the value until + * isc_stats_copy() is called where the whole process is protected + * by the write (exclusive) lock. + */ + if (prev == (isc_int32_t)0xffffffff) + isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].hi, 1); +#elif defined(ISC_PLATFORM_HAVEXADDQ) + UNUSED(prev); + isc_atomic_xaddq((isc_int64_t *)&stats->counters[counter], 1); +#else + UNUSED(prev); + stats->counters[counter]++; +#endif + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_unlock(&stats->counterlock, isc_rwlocktype_read); +#endif +} + +static inline void +decrementcounter(isc_stats_t *stats, int counter) { + isc_int32_t prev; + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_lock(&stats->counterlock, isc_rwlocktype_read); +#endif + +#if ISC_STATS_USEMULTIFIELDS + prev = isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].lo, -1); + if (prev == 0) + isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].hi, + -1); +#elif defined(ISC_PLATFORM_HAVEXADDQ) + UNUSED(prev); + isc_atomic_xaddq((isc_int64_t *)&stats->counters[counter], -1); +#else + UNUSED(prev); + stats->counters[counter]--; +#endif + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_unlock(&stats->counterlock, isc_rwlocktype_read); +#endif +} + +static void +copy_counters(isc_stats_t *stats) { + int i; + +#ifdef ISC_RWLOCK_USEATOMIC + /* + * We use a "write" lock before "reading" the statistics counters as + * an exclusive lock. + */ + isc_rwlock_lock(&stats->counterlock, isc_rwlocktype_write); +#endif + +#if ISC_STATS_USEMULTIFIELDS + for (i = 0; i < stats->ncounters; i++) { + stats->copiedcounters[i] = + (isc_uint64_t)(stats->counters[i].hi) << 32 | + stats->counters[i].lo; + } +#else + UNUSED(i); + memcpy(stats->copiedcounters, stats->counters, + stats->ncounters * sizeof(isc_stat_t)); +#endif + +#ifdef ISC_RWLOCK_USEATOMIC + isc_rwlock_unlock(&stats->counterlock, isc_rwlocktype_write); +#endif +} + +isc_result_t +isc_stats_create(isc_mem_t *mctx, isc_stats_t **statsp, int ncounters) { + REQUIRE(statsp != NULL && *statsp == NULL); + + return (create_stats(mctx, ncounters, statsp)); +} + +void +isc_stats_increment(isc_stats_t *stats, isc_statscounter_t counter) { + REQUIRE(ISC_STATS_VALID(stats)); + REQUIRE(counter < stats->ncounters); + + incrementcounter(stats, (int)counter); +} + +void +isc_stats_decrement(isc_stats_t *stats, isc_statscounter_t counter) { + REQUIRE(ISC_STATS_VALID(stats)); + REQUIRE(counter < stats->ncounters); + + decrementcounter(stats, (int)counter); +} + +void +isc_stats_dump(isc_stats_t *stats, isc_stats_dumper_t dump_fn, + void *arg, unsigned int options) +{ + int i; + + REQUIRE(ISC_STATS_VALID(stats)); + + copy_counters(stats); + + for (i = 0; i < stats->ncounters; i++) { + if ((options & ISC_STATSDUMP_VERBOSE) == 0 && + stats->copiedcounters[i] == 0) + continue; + dump_fn((isc_statscounter_t)i, stats->copiedcounters[i], arg); + } +} diff --git a/contrib/ntp/lib/isc/string.c b/contrib/ntp/lib/isc/string.c new file mode 100644 index 000000000..cba517c56 --- /dev/null +++ b/contrib/ntp/lib/isc/string.c @@ -0,0 +1,271 @@ +/* + * Copyright (C) 2004-2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +static char digits[] = "0123456789abcdefghijklmnoprstuvwxyz"; + +isc_uint64_t +isc_string_touint64(char *source, char **end, int base) { + isc_uint64_t tmp; + isc_uint64_t overflow; + char *s = source; + char *o; + char c; + + if ((base < 0) || (base == 1) || (base > 36)) { + *end = source; + return (0); + } + + while (*s != 0 && isascii(*s&0xff) && isspace(*s&0xff)) + s++; + if (*s == '+' /* || *s == '-' */) + s++; + if (base == 0) { + if (*s == '0' && (*(s+1) == 'X' || *(s+1) == 'x')) { + s += 2; + base = 16; + } else if (*s == '0') + base = 8; + else + base = 10; + } + if (*s == 0) { + *end = source; + return (0); + } + overflow = ~0; + overflow /= base; + tmp = 0; + + while ((c = *s) != 0) { + c = tolower(c&0xff); + /* end ? */ + if ((o = strchr(digits, c)) == NULL) { + *end = s; + return (tmp); + } + /* end ? */ + if ((o - digits) >= base) { + *end = s; + return (tmp); + } + /* overflow ? */ + if (tmp > overflow) { + *end = source; + return (0); + } + tmp *= base; + /* overflow ? */ + if ((tmp + (o - digits)) < tmp) { + *end = source; + return (0); + } + tmp += o - digits; + s++; + } + *end = s; + return (tmp); +} + +isc_result_t +isc_string_copy(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + + if (strlcpy(target, source, size) >= size) { + memset(target, ISC_STRING_MAGIC, size); + return (ISC_R_NOSPACE); + } + + ENSURE(strlen(target) < size); + + return (ISC_R_SUCCESS); +} + +void +isc_string_copy_truncate(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + + strlcpy(target, source, size); + + ENSURE(strlen(target) < size); +} + +isc_result_t +isc_string_append(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + REQUIRE(strlen(target) < size); + + if (strlcat(target, source, size) >= size) { + memset(target, ISC_STRING_MAGIC, size); + return (ISC_R_NOSPACE); + } + + ENSURE(strlen(target) < size); + + return (ISC_R_SUCCESS); +} + +void +isc_string_append_truncate(char *target, size_t size, const char *source) { + REQUIRE(size > 0U); + REQUIRE(strlen(target) < size); + + strlcat(target, source, size); + + ENSURE(strlen(target) < size); +} + +isc_result_t +isc_string_printf(char *target, size_t size, const char *format, ...) { + va_list args; + size_t n; + + REQUIRE(size > 0U); + + va_start(args, format); + n = vsnprintf(target, size, format, args); + va_end(args); + + if (n >= size) { + memset(target, ISC_STRING_MAGIC, size); + return (ISC_R_NOSPACE); + } + + ENSURE(strlen(target) < size); + + return (ISC_R_SUCCESS); +} + +void +isc_string_printf_truncate(char *target, size_t size, const char *format, ...) +{ + va_list args; + + REQUIRE(size > 0U); + + va_start(args, format); + /* check return code? */ + (void)vsnprintf(target, size, format, args); + va_end(args); + + ENSURE(strlen(target) < size); +} + +char * +isc_string_regiondup(isc_mem_t *mctx, const isc_region_t *source) { + char *target; + + REQUIRE(mctx != NULL); + REQUIRE(source != NULL); + + target = (char *) isc_mem_allocate(mctx, source->length + 1); + if (target != NULL) { + memcpy(source->base, target, source->length); + target[source->length] = '\0'; + } + + return (target); +} + +char * +isc_string_separate(char **stringp, const char *delim) { + char *string = *stringp; + char *s; + const char *d; + char sc, dc; + + if (string == NULL) + return (NULL); + + for (s = string; (sc = *s) != '\0'; s++) + for (d = delim; (dc = *d) != '\0'; d++) + if (sc == dc) { + *s++ = '\0'; + *stringp = s; + return (string); + } + *stringp = NULL; + return (string); +} + +size_t +isc_string_strlcpy(char *dst, const char *src, size_t size) +{ + char *d = dst; + const char *s = src; + size_t n = size; + + /* Copy as many bytes as will fit */ + if (n != 0U && --n != 0U) { + do { + if ((*d++ = *s++) == 0) + break; + } while (--n != 0U); + } + + /* Not enough room in dst, add NUL and traverse rest of src */ + if (n == 0U) { + if (size != 0U) + *d = '\0'; /* NUL-terminate dst */ + while (*s++) + ; + } + + return(s - src - 1); /* count does not include NUL */ +} + +size_t +isc_string_strlcat(char *dst, const char *src, size_t size) +{ + char *d = dst; + const char *s = src; + size_t n = size; + size_t dlen; + + /* Find the end of dst and adjust bytes left but don't go past end */ + while (n-- != 0U && *d != '\0') + d++; + dlen = d - dst; + n = size - dlen; + + if (n == 0U) + return(dlen + strlen(s)); + while (*s != '\0') { + if (n != 1U) { + *d++ = *s; + n--; + } + s++; + } + *d = '\0'; + + return(dlen + (s - src)); /* count does not include NUL */ +} diff --git a/contrib/ntp/lib/isc/strtoul.c b/contrib/ntp/lib/isc/strtoul.c new file mode 100644 index 000000000..18d93e21c --- /dev/null +++ b/contrib/ntp/lib/isc/strtoul.c @@ -0,0 +1,129 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Copyright (c) 1990, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/*! \file */ +#if defined(LIBC_SCCS) && !defined(lint) +static char sccsid[] = "@(#)strtoul.c 8.1 (Berkeley) 6/4/93"; +#endif /* LIBC_SCCS and not lint */ + +/* $Id: strtoul.c,v 1.7 2007/06/19 23:47:17 tbox Exp $ */ + +#include + +#include +#include +#include + +#include +#include + +/*! + * Convert a string to an unsigned long integer. + * + * Ignores `locale' stuff. Assumes that the upper and lower case + * alphabets and digits are each contiguous. + */ +unsigned long +isc_strtoul(const char *nptr, char **endptr, int base) { + const char *s = nptr; + unsigned long acc; + unsigned char c; + unsigned long cutoff; + int neg = 0, any, cutlim; + + /* + * See strtol for comments as to the logic used. + */ + do { + c = *s++; + } while (isspace(c)); + if (c == '-') { + neg = 1; + c = *s++; + } else if (c == '+') + c = *s++; + if ((base == 0 || base == 16) && + c == '0' && (*s == 'x' || *s == 'X')) { + c = s[1]; + s += 2; + base = 16; + } + if (base == 0) + base = c == '0' ? 8 : 10; + cutoff = (unsigned long)ULONG_MAX / (unsigned long)base; + cutlim = (unsigned long)ULONG_MAX % (unsigned long)base; + for (acc = 0, any = 0;; c = *s++) { + if (!isascii(c)) + break; + if (isdigit(c)) + c -= '0'; + else if (isalpha(c)) + c -= isupper(c) ? 'A' - 10 : 'a' - 10; + else + break; + if (c >= base) + break; + if (any < 0 || acc > cutoff || (acc == cutoff && c > cutlim)) + any = -1; + else { + any = 1; + acc *= base; + acc += c; + } + } + if (any < 0) { + acc = ULONG_MAX; + errno = ERANGE; + } else if (neg) + acc = -acc; + if (endptr != 0) + DE_CONST(any ? s - 1 : nptr, *endptr); + return (acc); +} diff --git a/contrib/ntp/lib/isc/symtab.c b/contrib/ntp/lib/isc/symtab.c new file mode 100644 index 000000000..d4c1dccf0 --- /dev/null +++ b/contrib/ntp/lib/isc/symtab.c @@ -0,0 +1,301 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1996-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include + +typedef struct elt { + char * key; + unsigned int type; + isc_symvalue_t value; + LINK(struct elt) link; +} elt_t; + +typedef LIST(elt_t) eltlist_t; + +#define SYMTAB_MAGIC ISC_MAGIC('S', 'y', 'm', 'T') +#define VALID_SYMTAB(st) ISC_MAGIC_VALID(st, SYMTAB_MAGIC) + +struct isc_symtab { + /* Unlocked. */ + unsigned int magic; + isc_mem_t * mctx; + unsigned int size; + unsigned int count; + unsigned int maxload; + eltlist_t * table; + isc_symtabaction_t undefine_action; + void * undefine_arg; + isc_boolean_t case_sensitive; +}; + +isc_result_t +isc_symtab_create(isc_mem_t *mctx, unsigned int size, + isc_symtabaction_t undefine_action, + void *undefine_arg, + isc_boolean_t case_sensitive, + isc_symtab_t **symtabp) +{ + isc_symtab_t *symtab; + unsigned int i; + + REQUIRE(mctx != NULL); + REQUIRE(symtabp != NULL && *symtabp == NULL); + REQUIRE(size > 0); /* Should be prime. */ + + symtab = (isc_symtab_t *)isc_mem_get(mctx, sizeof(*symtab)); + if (symtab == NULL) + return (ISC_R_NOMEMORY); + symtab->table = (eltlist_t *)isc_mem_get(mctx, + size * sizeof(eltlist_t)); + if (symtab->table == NULL) { + isc_mem_put(mctx, symtab, sizeof(*symtab)); + return (ISC_R_NOMEMORY); + } + for (i = 0; i < size; i++) + INIT_LIST(symtab->table[i]); + symtab->mctx = mctx; + symtab->size = size; + symtab->count = 0; + symtab->maxload = size * 3 / 4; + symtab->undefine_action = undefine_action; + symtab->undefine_arg = undefine_arg; + symtab->case_sensitive = case_sensitive; + symtab->magic = SYMTAB_MAGIC; + + *symtabp = symtab; + + return (ISC_R_SUCCESS); +} + +void +isc_symtab_destroy(isc_symtab_t **symtabp) { + isc_symtab_t *symtab; + unsigned int i; + elt_t *elt, *nelt; + + REQUIRE(symtabp != NULL); + symtab = *symtabp; + REQUIRE(VALID_SYMTAB(symtab)); + + for (i = 0; i < symtab->size; i++) { + for (elt = HEAD(symtab->table[i]); elt != NULL; elt = nelt) { + nelt = NEXT(elt, link); + if (symtab->undefine_action != NULL) + (symtab->undefine_action)(elt->key, + elt->type, + elt->value, + symtab->undefine_arg); + isc_mem_put(symtab->mctx, elt, sizeof(*elt)); + } + } + isc_mem_put(symtab->mctx, symtab->table, + symtab->size * sizeof(eltlist_t)); + symtab->magic = 0; + isc_mem_put(symtab->mctx, symtab, sizeof(*symtab)); + + *symtabp = NULL; +} + +static inline unsigned int +hash(const char *key, isc_boolean_t case_sensitive) { + const char *s; + unsigned int h = 0; + int c; + + /* + * This hash function is similar to the one Ousterhout + * uses in Tcl. + */ + + if (case_sensitive) { + for (s = key; *s != '\0'; s++) { + h += (h << 3) + *s; + } + } else { + for (s = key; *s != '\0'; s++) { + c = *s; + c = tolower((unsigned char)c); + h += (h << 3) + c; + } + } + + return (h); +} + +#define FIND(s, k, t, b, e) \ + b = hash((k), (s)->case_sensitive) % (s)->size; \ + if ((s)->case_sensitive) { \ + for (e = HEAD((s)->table[b]); e != NULL; e = NEXT(e, link)) { \ + if (((t) == 0 || e->type == (t)) && \ + strcmp(e->key, (k)) == 0) \ + break; \ + } \ + } else { \ + for (e = HEAD((s)->table[b]); e != NULL; e = NEXT(e, link)) { \ + if (((t) == 0 || e->type == (t)) && \ + strcasecmp(e->key, (k)) == 0) \ + break; \ + } \ + } + +isc_result_t +isc_symtab_lookup(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t *value) +{ + unsigned int bucket; + elt_t *elt; + + REQUIRE(VALID_SYMTAB(symtab)); + REQUIRE(key != NULL); + + FIND(symtab, key, type, bucket, elt); + + if (elt == NULL) + return (ISC_R_NOTFOUND); + + if (value != NULL) + *value = elt->value; + + return (ISC_R_SUCCESS); +} + +static void +grow_table(isc_symtab_t *symtab) { + eltlist_t *newtable; + unsigned int i, newsize, newmax; + + REQUIRE(symtab != NULL); + + newsize = symtab->size * 2; + newmax = newsize * 3 / 4; + INSIST(newsize > 0U && newmax > 0U); + + newtable = isc_mem_get(symtab->mctx, newsize * sizeof(eltlist_t)); + if (newtable == NULL) + return; + + for (i = 0; i < newsize; i++) + INIT_LIST(newtable[i]); + + for (i = 0; i < symtab->size; i++) { + elt_t *elt, *nelt; + + for (elt = HEAD(symtab->table[i]); elt != NULL; elt = nelt) { + unsigned int hv; + + nelt = NEXT(elt, link); + + UNLINK(symtab->table[i], elt, link); + hv = hash(elt->key, symtab->case_sensitive); + APPEND(newtable[hv % newsize], elt, link); + } + } + + isc_mem_put(symtab->mctx, symtab->table, + symtab->size * sizeof(eltlist_t)); + + symtab->table = newtable; + symtab->size = newsize; + symtab->maxload = newmax; +} + +isc_result_t +isc_symtab_define(isc_symtab_t *symtab, const char *key, unsigned int type, + isc_symvalue_t value, isc_symexists_t exists_policy) +{ + unsigned int bucket; + elt_t *elt; + + REQUIRE(VALID_SYMTAB(symtab)); + REQUIRE(key != NULL); + REQUIRE(type != 0); + + FIND(symtab, key, type, bucket, elt); + + if (exists_policy != isc_symexists_add && elt != NULL) { + if (exists_policy == isc_symexists_reject) + return (ISC_R_EXISTS); + INSIST(exists_policy == isc_symexists_replace); + UNLINK(symtab->table[bucket], elt, link); + if (symtab->undefine_action != NULL) + (symtab->undefine_action)(elt->key, elt->type, + elt->value, + symtab->undefine_arg); + } else { + elt = (elt_t *)isc_mem_get(symtab->mctx, sizeof(*elt)); + if (elt == NULL) + return (ISC_R_NOMEMORY); + ISC_LINK_INIT(elt, link); + symtab->count++; + } + + /* + * Though the "key" can be const coming in, it is not stored as const + * so that the calling program can easily have writable access to + * it in its undefine_action function. In the event that it *was* + * truly const coming in and then the caller modified it anyway ... + * well, don't do that! + */ + DE_CONST(key, elt->key); + elt->type = type; + elt->value = value; + + /* + * We prepend so that the most recent definition will be found. + */ + PREPEND(symtab->table[bucket], elt, link); + + if (symtab->count > symtab->maxload) + grow_table(symtab); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_symtab_undefine(isc_symtab_t *symtab, const char *key, unsigned int type) { + unsigned int bucket; + elt_t *elt; + + REQUIRE(VALID_SYMTAB(symtab)); + REQUIRE(key != NULL); + + FIND(symtab, key, type, bucket, elt); + + if (elt == NULL) + return (ISC_R_NOTFOUND); + + if (symtab->undefine_action != NULL) + (symtab->undefine_action)(elt->key, elt->type, + elt->value, symtab->undefine_arg); + UNLINK(symtab->table[bucket], elt, link); + isc_mem_put(symtab->mctx, elt, sizeof(*elt)); + symtab->count--; + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/task.c b/contrib/ntp/lib/isc/task.c new file mode 100644 index 000000000..cd19d2d52 --- /dev/null +++ b/contrib/ntp/lib/isc/task.c @@ -0,0 +1,1813 @@ +/* + * Copyright (C) 2004-2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file + * \author Principal Author: Bob Halley + */ + +/* + * XXXRTH Need to document the states a task can be in, and the rules + * for changing states. + */ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef OPENSSL_LEAKS +#include +#endif + +/*% + * For BIND9 internal applications: + * when built with threads we use multiple worker threads shared by the whole + * application. + * when built without threads we share a single global task manager and use + * an integrated event loop for socket, timer, and other generic task events. + * For generic library: + * we don't use either of them: an application can have multiple task managers + * whether or not it's threaded, and if the application is threaded each thread + * is expected to have a separate manager; no "worker threads" are shared by + * the application threads. + */ +#ifdef BIND9 +#ifdef ISC_PLATFORM_USETHREADS +#define USE_WORKER_THREADS +#else +#define USE_SHARED_MANAGER +#endif /* ISC_PLATFORM_USETHREADS */ +#endif /* BIND9 */ + +#include "task_p.h" + +#ifdef ISC_TASK_TRACE +#define XTRACE(m) fprintf(stderr, "task %p thread %lu: %s\n", \ + task, isc_thread_self(), (m)) +#define XTTRACE(t, m) fprintf(stderr, "task %p thread %lu: %s\n", \ + (t), isc_thread_self(), (m)) +#define XTHREADTRACE(m) fprintf(stderr, "thread %lu: %s\n", \ + isc_thread_self(), (m)) +#else +#define XTRACE(m) +#define XTTRACE(t, m) +#define XTHREADTRACE(m) +#endif + +/*** + *** Types. + ***/ + +typedef enum { + task_state_idle, task_state_ready, task_state_running, + task_state_done +} task_state_t; + +#if defined(HAVE_LIBXML2) && defined(BIND9) +static const char *statenames[] = { + "idle", "ready", "running", "done", +}; +#endif + +#define TASK_MAGIC ISC_MAGIC('T', 'A', 'S', 'K') +#define VALID_TASK(t) ISC_MAGIC_VALID(t, TASK_MAGIC) + +typedef struct isc__task isc__task_t; +typedef struct isc__taskmgr isc__taskmgr_t; + +struct isc__task { + /* Not locked. */ + isc_task_t common; + isc__taskmgr_t * manager; + isc_mutex_t lock; + /* Locked by task lock. */ + task_state_t state; + unsigned int references; + isc_eventlist_t events; + isc_eventlist_t on_shutdown; + unsigned int quantum; + unsigned int flags; + isc_stdtime_t now; + char name[16]; + void * tag; + /* Locked by task manager lock. */ + LINK(isc__task_t) link; + LINK(isc__task_t) ready_link; + LINK(isc__task_t) ready_priority_link; +}; + +#define TASK_F_SHUTTINGDOWN 0x01 +#define TASK_F_PRIVILEGED 0x02 + +#define TASK_SHUTTINGDOWN(t) (((t)->flags & TASK_F_SHUTTINGDOWN) \ + != 0) + +#define TASK_MANAGER_MAGIC ISC_MAGIC('T', 'S', 'K', 'M') +#define VALID_MANAGER(m) ISC_MAGIC_VALID(m, TASK_MANAGER_MAGIC) + +typedef ISC_LIST(isc__task_t) isc__tasklist_t; + +struct isc__taskmgr { + /* Not locked. */ + isc_taskmgr_t common; + isc_mem_t * mctx; + isc_mutex_t lock; +#ifdef ISC_PLATFORM_USETHREADS + unsigned int workers; + isc_thread_t * threads; +#endif /* ISC_PLATFORM_USETHREADS */ + /* Locked by task manager lock. */ + unsigned int default_quantum; + LIST(isc__task_t) tasks; + isc__tasklist_t ready_tasks; + isc__tasklist_t ready_priority_tasks; + isc_taskmgrmode_t mode; +#ifdef ISC_PLATFORM_USETHREADS + isc_condition_t work_available; + isc_condition_t exclusive_granted; + isc_condition_t paused; +#endif /* ISC_PLATFORM_USETHREADS */ + unsigned int tasks_running; + isc_boolean_t pause_requested; + isc_boolean_t exclusive_requested; + isc_boolean_t exiting; +#ifdef USE_SHARED_MANAGER + unsigned int refs; +#endif /* ISC_PLATFORM_USETHREADS */ +}; + +#define DEFAULT_TASKMGR_QUANTUM 10 +#define DEFAULT_DEFAULT_QUANTUM 5 +#define FINISHED(m) ((m)->exiting && EMPTY((m)->tasks)) + +#ifdef USE_SHARED_MANAGER +static isc__taskmgr_t *taskmgr = NULL; +#endif /* USE_SHARED_MANAGER */ + +/*% + * The following can be either static or public, depending on build environment. + */ + +#ifdef BIND9 +#define ISC_TASKFUNC_SCOPE +#else +#define ISC_TASKFUNC_SCOPE static +#endif + +ISC_TASKFUNC_SCOPE isc_result_t +isc__task_create(isc_taskmgr_t *manager0, unsigned int quantum, + isc_task_t **taskp); +ISC_TASKFUNC_SCOPE void +isc__task_attach(isc_task_t *source0, isc_task_t **targetp); +ISC_TASKFUNC_SCOPE void +isc__task_detach(isc_task_t **taskp); +ISC_TASKFUNC_SCOPE void +isc__task_send(isc_task_t *task0, isc_event_t **eventp); +ISC_TASKFUNC_SCOPE void +isc__task_sendanddetach(isc_task_t **taskp, isc_event_t **eventp); +ISC_TASKFUNC_SCOPE unsigned int +isc__task_purgerange(isc_task_t *task0, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag); +ISC_TASKFUNC_SCOPE unsigned int +isc__task_purge(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag); +ISC_TASKFUNC_SCOPE isc_boolean_t +isc__task_purgeevent(isc_task_t *task0, isc_event_t *event); +ISC_TASKFUNC_SCOPE unsigned int +isc__task_unsendrange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag, + isc_eventlist_t *events); +ISC_TASKFUNC_SCOPE unsigned int +isc__task_unsend(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag, isc_eventlist_t *events); +ISC_TASKFUNC_SCOPE isc_result_t +isc__task_onshutdown(isc_task_t *task0, isc_taskaction_t action, + const void *arg); +ISC_TASKFUNC_SCOPE void +isc__task_shutdown(isc_task_t *task0); +ISC_TASKFUNC_SCOPE void +isc__task_destroy(isc_task_t **taskp); +ISC_TASKFUNC_SCOPE void +isc__task_setname(isc_task_t *task0, const char *name, void *tag); +ISC_TASKFUNC_SCOPE const char * +isc__task_getname(isc_task_t *task0); +ISC_TASKFUNC_SCOPE void * +isc__task_gettag(isc_task_t *task0); +ISC_TASKFUNC_SCOPE void +isc__task_getcurrenttime(isc_task_t *task0, isc_stdtime_t *t); +ISC_TASKFUNC_SCOPE isc_result_t +isc__taskmgr_create(isc_mem_t *mctx, unsigned int workers, + unsigned int default_quantum, isc_taskmgr_t **managerp); +ISC_TASKFUNC_SCOPE void +isc__taskmgr_destroy(isc_taskmgr_t **managerp); +ISC_TASKFUNC_SCOPE isc_result_t +isc__task_beginexclusive(isc_task_t *task); +ISC_TASKFUNC_SCOPE void +isc__task_endexclusive(isc_task_t *task0); +ISC_TASKFUNC_SCOPE void +isc__task_setprivilege(isc_task_t *task0, isc_boolean_t priv); +ISC_TASKFUNC_SCOPE isc_boolean_t +isc__task_privilege(isc_task_t *task0); +ISC_TASKFUNC_SCOPE void +isc__taskmgr_setmode(isc_taskmgr_t *manager0, isc_taskmgrmode_t mode); +ISC_TASKFUNC_SCOPE isc_taskmgrmode_t +isc__taskmgr_mode(isc_taskmgr_t *manager0); + +static inline isc_boolean_t +empty_readyq(isc__taskmgr_t *manager); + +static inline isc__task_t * +pop_readyq(isc__taskmgr_t *manager); + +static inline void +push_readyq(isc__taskmgr_t *manager, isc__task_t *task); + +static struct isc__taskmethods { + isc_taskmethods_t methods; + + /*% + * The following are defined just for avoiding unused static functions. + */ +#ifndef BIND9 + void *purgeevent, *unsendrange, *getname, *gettag, *getcurrenttime; +#endif +} taskmethods = { + { + isc__task_attach, + isc__task_detach, + isc__task_destroy, + isc__task_send, + isc__task_sendanddetach, + isc__task_unsend, + isc__task_onshutdown, + isc__task_shutdown, + isc__task_setname, + isc__task_purge, + isc__task_purgerange, + isc__task_beginexclusive, + isc__task_endexclusive, + isc__task_setprivilege, + isc__task_privilege + } +#ifndef BIND9 + , + (void *)isc__task_purgeevent, (void *)isc__task_unsendrange, + (void *)isc__task_getname, (void *)isc__task_gettag, + (void *)isc__task_getcurrenttime +#endif +}; + +static isc_taskmgrmethods_t taskmgrmethods = { + isc__taskmgr_destroy, + isc__taskmgr_setmode, + isc__taskmgr_mode, + isc__task_create +}; + +/*** + *** Tasks. + ***/ + +static void +task_finished(isc__task_t *task) { + isc__taskmgr_t *manager = task->manager; + + REQUIRE(EMPTY(task->events)); + REQUIRE(EMPTY(task->on_shutdown)); + REQUIRE(task->references == 0); + REQUIRE(task->state == task_state_done); + + XTRACE("task_finished"); + + LOCK(&manager->lock); + UNLINK(manager->tasks, task, link); +#ifdef USE_WORKER_THREADS + if (FINISHED(manager)) { + /* + * All tasks have completed and the + * task manager is exiting. Wake up + * any idle worker threads so they + * can exit. + */ + BROADCAST(&manager->work_available); + } +#endif /* USE_WORKER_THREADS */ + UNLOCK(&manager->lock); + + DESTROYLOCK(&task->lock); + task->common.impmagic = 0; + task->common.magic = 0; + isc_mem_put(manager->mctx, task, sizeof(*task)); +} + +ISC_TASKFUNC_SCOPE isc_result_t +isc__task_create(isc_taskmgr_t *manager0, unsigned int quantum, + isc_task_t **taskp) +{ + isc__taskmgr_t *manager = (isc__taskmgr_t *)manager0; + isc__task_t *task; + isc_boolean_t exiting; + isc_result_t result; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(taskp != NULL && *taskp == NULL); + + task = isc_mem_get(manager->mctx, sizeof(*task)); + if (task == NULL) + return (ISC_R_NOMEMORY); + XTRACE("isc_task_create"); + result = isc_mutex_init(&task->lock); + if (result != ISC_R_SUCCESS) { + isc_mem_put(manager->mctx, task, sizeof(*task)); + return (result); + } + LOCK(&manager->lock); + LOCK(&task->lock); /* helps coverity analysis noise ratio */ + task->manager = manager; + task->state = task_state_idle; + task->references = 1; + INIT_LIST(task->events); + INIT_LIST(task->on_shutdown); + task->quantum = quantum; + task->flags = 0; + task->now = 0; + memset(task->name, 0, sizeof(task->name)); + task->tag = NULL; + INIT_LINK(task, link); + INIT_LINK(task, ready_link); + INIT_LINK(task, ready_priority_link); + UNLOCK(&task->lock); + UNLOCK(&manager->lock); + + exiting = ISC_FALSE; + LOCK(&manager->lock); + if (!manager->exiting) { + if (task->quantum == 0) + task->quantum = manager->default_quantum; + APPEND(manager->tasks, task, link); + } else + exiting = ISC_TRUE; + UNLOCK(&manager->lock); + + if (exiting) { + DESTROYLOCK(&task->lock); + isc_mem_put(manager->mctx, task, sizeof(*task)); + return (ISC_R_SHUTTINGDOWN); + } + + task->common.methods = (isc_taskmethods_t *)&taskmethods; + task->common.magic = ISCAPI_TASK_MAGIC; + task->common.impmagic = TASK_MAGIC; + *taskp = (isc_task_t *)task; + + return (ISC_R_SUCCESS); +} + +ISC_TASKFUNC_SCOPE void +isc__task_attach(isc_task_t *source0, isc_task_t **targetp) { + isc__task_t *source = (isc__task_t *)source0; + + /* + * Attach *targetp to source. + */ + + REQUIRE(VALID_TASK(source)); + REQUIRE(targetp != NULL && *targetp == NULL); + + XTTRACE(source, "isc_task_attach"); + + LOCK(&source->lock); + source->references++; + UNLOCK(&source->lock); + + *targetp = (isc_task_t *)source; +} + +static inline isc_boolean_t +task_shutdown(isc__task_t *task) { + isc_boolean_t was_idle = ISC_FALSE; + isc_event_t *event, *prev; + + /* + * Caller must be holding the task's lock. + */ + + XTRACE("task_shutdown"); + + if (! TASK_SHUTTINGDOWN(task)) { + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_SHUTTINGDOWN, "shutting down")); + task->flags |= TASK_F_SHUTTINGDOWN; + if (task->state == task_state_idle) { + INSIST(EMPTY(task->events)); + task->state = task_state_ready; + was_idle = ISC_TRUE; + } + INSIST(task->state == task_state_ready || + task->state == task_state_running); + + /* + * Note that we post shutdown events LIFO. + */ + for (event = TAIL(task->on_shutdown); + event != NULL; + event = prev) { + prev = PREV(event, ev_link); + DEQUEUE(task->on_shutdown, event, ev_link); + ENQUEUE(task->events, event, ev_link); + } + } + + return (was_idle); +} + +/* + * Moves a task onto the appropriate run queue. + * + * Caller must NOT hold manager lock. + */ +static inline void +task_ready(isc__task_t *task) { + isc__taskmgr_t *manager = task->manager; +#ifdef USE_WORKER_THREADS + isc_boolean_t has_privilege = isc__task_privilege((isc_task_t *) task); +#endif /* USE_WORKER_THREADS */ + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(task->state == task_state_ready); + + XTRACE("task_ready"); + + LOCK(&manager->lock); + push_readyq(manager, task); +#ifdef USE_WORKER_THREADS + if (manager->mode == isc_taskmgrmode_normal || has_privilege) + SIGNAL(&manager->work_available); +#endif /* USE_WORKER_THREADS */ + UNLOCK(&manager->lock); +} + +static inline isc_boolean_t +task_detach(isc__task_t *task) { + + /* + * Caller must be holding the task lock. + */ + + REQUIRE(task->references > 0); + + XTRACE("detach"); + + task->references--; + if (task->references == 0 && task->state == task_state_idle) { + INSIST(EMPTY(task->events)); + /* + * There are no references to this task, and no + * pending events. We could try to optimize and + * either initiate shutdown or clean up the task, + * depending on its state, but it's easier to just + * make the task ready and allow run() or the event + * loop to deal with shutting down and termination. + */ + task->state = task_state_ready; + return (ISC_TRUE); + } + + return (ISC_FALSE); +} + +ISC_TASKFUNC_SCOPE void +isc__task_detach(isc_task_t **taskp) { + isc__task_t *task; + isc_boolean_t was_idle; + + /* + * Detach *taskp from its task. + */ + + REQUIRE(taskp != NULL); + task = (isc__task_t *)*taskp; + REQUIRE(VALID_TASK(task)); + + XTRACE("isc_task_detach"); + + LOCK(&task->lock); + was_idle = task_detach(task); + UNLOCK(&task->lock); + + if (was_idle) + task_ready(task); + + *taskp = NULL; +} + +static inline isc_boolean_t +task_send(isc__task_t *task, isc_event_t **eventp) { + isc_boolean_t was_idle = ISC_FALSE; + isc_event_t *event; + + /* + * Caller must be holding the task lock. + */ + + REQUIRE(eventp != NULL); + event = *eventp; + REQUIRE(event != NULL); + REQUIRE(event->ev_type > 0); + REQUIRE(task->state != task_state_done); + + XTRACE("task_send"); + + if (task->state == task_state_idle) { + was_idle = ISC_TRUE; + INSIST(EMPTY(task->events)); + task->state = task_state_ready; + } + INSIST(task->state == task_state_ready || + task->state == task_state_running); + ENQUEUE(task->events, event, ev_link); + *eventp = NULL; + + return (was_idle); +} + +ISC_TASKFUNC_SCOPE void +isc__task_send(isc_task_t *task0, isc_event_t **eventp) { + isc__task_t *task = (isc__task_t *)task0; + isc_boolean_t was_idle; + + /* + * Send '*event' to 'task'. + */ + + REQUIRE(VALID_TASK(task)); + + XTRACE("isc_task_send"); + + /* + * We're trying hard to hold locks for as short a time as possible. + * We're also trying to hold as few locks as possible. This is why + * some processing is deferred until after the lock is released. + */ + LOCK(&task->lock); + was_idle = task_send(task, eventp); + UNLOCK(&task->lock); + + if (was_idle) { + /* + * We need to add this task to the ready queue. + * + * We've waited until now to do it because making a task + * ready requires locking the manager. If we tried to do + * this while holding the task lock, we could deadlock. + * + * We've changed the state to ready, so no one else will + * be trying to add this task to the ready queue. The + * only way to leave the ready state is by executing the + * task. It thus doesn't matter if events are added, + * removed, or a shutdown is started in the interval + * between the time we released the task lock, and the time + * we add the task to the ready queue. + */ + task_ready(task); + } +} + +ISC_TASKFUNC_SCOPE void +isc__task_sendanddetach(isc_task_t **taskp, isc_event_t **eventp) { + isc_boolean_t idle1, idle2; + isc__task_t *task; + + /* + * Send '*event' to '*taskp' and then detach '*taskp' from its + * task. + */ + + REQUIRE(taskp != NULL); + task = (isc__task_t *)*taskp; + REQUIRE(VALID_TASK(task)); + + XTRACE("isc_task_sendanddetach"); + + LOCK(&task->lock); + idle1 = task_send(task, eventp); + idle2 = task_detach(task); + UNLOCK(&task->lock); + + /* + * If idle1, then idle2 shouldn't be true as well since we're holding + * the task lock, and thus the task cannot switch from ready back to + * idle. + */ + INSIST(!(idle1 && idle2)); + + if (idle1 || idle2) + task_ready(task); + + *taskp = NULL; +} + +#define PURGE_OK(event) (((event)->ev_attributes & ISC_EVENTATTR_NOPURGE) == 0) + +static unsigned int +dequeue_events(isc__task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag, + isc_eventlist_t *events, isc_boolean_t purging) +{ + isc_event_t *event, *next_event; + unsigned int count = 0; + + REQUIRE(VALID_TASK(task)); + REQUIRE(last >= first); + + XTRACE("dequeue_events"); + + /* + * Events matching 'sender', whose type is >= first and <= last, and + * whose tag is 'tag' will be dequeued. If 'purging', matching events + * which are marked as unpurgable will not be dequeued. + * + * sender == NULL means "any sender", and tag == NULL means "any tag". + */ + + LOCK(&task->lock); + + for (event = HEAD(task->events); event != NULL; event = next_event) { + next_event = NEXT(event, ev_link); + if (event->ev_type >= first && event->ev_type <= last && + (sender == NULL || event->ev_sender == sender) && + (tag == NULL || event->ev_tag == tag) && + (!purging || PURGE_OK(event))) { + DEQUEUE(task->events, event, ev_link); + ENQUEUE(*events, event, ev_link); + count++; + } + } + + UNLOCK(&task->lock); + + return (count); +} + +ISC_TASKFUNC_SCOPE unsigned int +isc__task_purgerange(isc_task_t *task0, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag) +{ + isc__task_t *task = (isc__task_t *)task0; + unsigned int count; + isc_eventlist_t events; + isc_event_t *event, *next_event; + + /* + * Purge events from a task's event queue. + */ + + XTRACE("isc_task_purgerange"); + + ISC_LIST_INIT(events); + + count = dequeue_events(task, sender, first, last, tag, &events, + ISC_TRUE); + + for (event = HEAD(events); event != NULL; event = next_event) { + next_event = NEXT(event, ev_link); + isc_event_free(&event); + } + + /* + * Note that purging never changes the state of the task. + */ + + return (count); +} + +ISC_TASKFUNC_SCOPE unsigned int +isc__task_purge(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag) +{ + /* + * Purge events from a task's event queue. + */ + + XTRACE("isc_task_purge"); + + return (isc__task_purgerange(task, sender, type, type, tag)); +} + +ISC_TASKFUNC_SCOPE isc_boolean_t +isc__task_purgeevent(isc_task_t *task0, isc_event_t *event) { + isc__task_t *task = (isc__task_t *)task0; + isc_event_t *curr_event, *next_event; + + /* + * Purge 'event' from a task's event queue. + * + * XXXRTH: WARNING: This method may be removed before beta. + */ + + REQUIRE(VALID_TASK(task)); + + /* + * If 'event' is on the task's event queue, it will be purged, + * unless it is marked as unpurgeable. 'event' does not have to be + * on the task's event queue; in fact, it can even be an invalid + * pointer. Purging only occurs if the event is actually on the task's + * event queue. + * + * Purging never changes the state of the task. + */ + + LOCK(&task->lock); + for (curr_event = HEAD(task->events); + curr_event != NULL; + curr_event = next_event) { + next_event = NEXT(curr_event, ev_link); + if (curr_event == event && PURGE_OK(event)) { + DEQUEUE(task->events, curr_event, ev_link); + break; + } + } + UNLOCK(&task->lock); + + if (curr_event == NULL) + return (ISC_FALSE); + + isc_event_free(&curr_event); + + return (ISC_TRUE); +} + +ISC_TASKFUNC_SCOPE unsigned int +isc__task_unsendrange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag, + isc_eventlist_t *events) +{ + /* + * Remove events from a task's event queue. + */ + + XTRACE("isc_task_unsendrange"); + + return (dequeue_events((isc__task_t *)task, sender, first, + last, tag, events, ISC_FALSE)); +} + +ISC_TASKFUNC_SCOPE unsigned int +isc__task_unsend(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag, isc_eventlist_t *events) +{ + /* + * Remove events from a task's event queue. + */ + + XTRACE("isc_task_unsend"); + + return (dequeue_events((isc__task_t *)task, sender, type, + type, tag, events, ISC_FALSE)); +} + +ISC_TASKFUNC_SCOPE isc_result_t +isc__task_onshutdown(isc_task_t *task0, isc_taskaction_t action, + const void *arg) +{ + isc__task_t *task = (isc__task_t *)task0; + isc_boolean_t disallowed = ISC_FALSE; + isc_result_t result = ISC_R_SUCCESS; + isc_event_t *event; + + /* + * Send a shutdown event with action 'action' and argument 'arg' when + * 'task' is shutdown. + */ + + REQUIRE(VALID_TASK(task)); + REQUIRE(action != NULL); + + event = isc_event_allocate(task->manager->mctx, + NULL, + ISC_TASKEVENT_SHUTDOWN, + action, + arg, + sizeof(*event)); + if (event == NULL) + return (ISC_R_NOMEMORY); + + LOCK(&task->lock); + if (TASK_SHUTTINGDOWN(task)) { + disallowed = ISC_TRUE; + result = ISC_R_SHUTTINGDOWN; + } else + ENQUEUE(task->on_shutdown, event, ev_link); + UNLOCK(&task->lock); + + if (disallowed) + isc_mem_put(task->manager->mctx, event, sizeof(*event)); + + return (result); +} + +ISC_TASKFUNC_SCOPE void +isc__task_shutdown(isc_task_t *task0) { + isc__task_t *task = (isc__task_t *)task0; + isc_boolean_t was_idle; + + /* + * Shutdown 'task'. + */ + + REQUIRE(VALID_TASK(task)); + + LOCK(&task->lock); + was_idle = task_shutdown(task); + UNLOCK(&task->lock); + + if (was_idle) + task_ready(task); +} + +ISC_TASKFUNC_SCOPE void +isc__task_destroy(isc_task_t **taskp) { + + /* + * Destroy '*taskp'. + */ + + REQUIRE(taskp != NULL); + + isc_task_shutdown(*taskp); + isc_task_detach(taskp); +} + +ISC_TASKFUNC_SCOPE void +isc__task_setname(isc_task_t *task0, const char *name, void *tag) { + isc__task_t *task = (isc__task_t *)task0; + + /* + * Name 'task'. + */ + + REQUIRE(VALID_TASK(task)); + + LOCK(&task->lock); + memset(task->name, 0, sizeof(task->name)); + strncpy(task->name, name, sizeof(task->name) - 1); + task->tag = tag; + UNLOCK(&task->lock); +} + +ISC_TASKFUNC_SCOPE const char * +isc__task_getname(isc_task_t *task0) { + isc__task_t *task = (isc__task_t *)task0; + + REQUIRE(VALID_TASK(task)); + + return (task->name); +} + +ISC_TASKFUNC_SCOPE void * +isc__task_gettag(isc_task_t *task0) { + isc__task_t *task = (isc__task_t *)task0; + + REQUIRE(VALID_TASK(task)); + + return (task->tag); +} + +ISC_TASKFUNC_SCOPE void +isc__task_getcurrenttime(isc_task_t *task0, isc_stdtime_t *t) { + isc__task_t *task = (isc__task_t *)task0; + + REQUIRE(VALID_TASK(task)); + REQUIRE(t != NULL); + + LOCK(&task->lock); + *t = task->now; + UNLOCK(&task->lock); +} + +/*** + *** Task Manager. + ***/ + +/* + * Return ISC_TRUE if the current ready list for the manager, which is + * either ready_tasks or the ready_priority_tasks, depending on whether + * the manager is currently in normal or privileged execution mode. + * + * Caller must hold the task manager lock. + */ +static inline isc_boolean_t +empty_readyq(isc__taskmgr_t *manager) { + isc__tasklist_t queue; + + if (manager->mode == isc_taskmgrmode_normal) + queue = manager->ready_tasks; + else + queue = manager->ready_priority_tasks; + + return (ISC_TF(EMPTY(queue))); +} + +/* + * Dequeue and return a pointer to the first task on the current ready + * list for the manager. + * If the task is privileged, dequeue it from the other ready list + * as well. + * + * Caller must hold the task manager lock. + */ +static inline isc__task_t * +pop_readyq(isc__taskmgr_t *manager) { + isc__task_t *task; + + if (manager->mode == isc_taskmgrmode_normal) + task = HEAD(manager->ready_tasks); + else + task = HEAD(manager->ready_priority_tasks); + + if (task != NULL) { + DEQUEUE(manager->ready_tasks, task, ready_link); + if (ISC_LINK_LINKED(task, ready_priority_link)) + DEQUEUE(manager->ready_priority_tasks, task, + ready_priority_link); + } + + return (task); +} + +/* + * Push 'task' onto the ready_tasks queue. If 'task' has the privilege + * flag set, then also push it onto the ready_priority_tasks queue. + * + * Caller must hold the task manager lock. + */ +static inline void +push_readyq(isc__taskmgr_t *manager, isc__task_t *task) { + ENQUEUE(manager->ready_tasks, task, ready_link); + if ((task->flags & TASK_F_PRIVILEGED) != 0) + ENQUEUE(manager->ready_priority_tasks, task, + ready_priority_link); +} + +static void +dispatch(isc__taskmgr_t *manager) { + isc__task_t *task; +#ifndef USE_WORKER_THREADS + unsigned int total_dispatch_count = 0; + isc__tasklist_t new_ready_tasks; + isc__tasklist_t new_priority_tasks; +#endif /* USE_WORKER_THREADS */ + + REQUIRE(VALID_MANAGER(manager)); + + /* + * Again we're trying to hold the lock for as short a time as possible + * and to do as little locking and unlocking as possible. + * + * In both while loops, the appropriate lock must be held before the + * while body starts. Code which acquired the lock at the top of + * the loop would be more readable, but would result in a lot of + * extra locking. Compare: + * + * Straightforward: + * + * LOCK(); + * ... + * UNLOCK(); + * while (expression) { + * LOCK(); + * ... + * UNLOCK(); + * + * Unlocked part here... + * + * LOCK(); + * ... + * UNLOCK(); + * } + * + * Note how if the loop continues we unlock and then immediately lock. + * For N iterations of the loop, this code does 2N+1 locks and 2N+1 + * unlocks. Also note that the lock is not held when the while + * condition is tested, which may or may not be important, depending + * on the expression. + * + * As written: + * + * LOCK(); + * while (expression) { + * ... + * UNLOCK(); + * + * Unlocked part here... + * + * LOCK(); + * ... + * } + * UNLOCK(); + * + * For N iterations of the loop, this code does N+1 locks and N+1 + * unlocks. The while expression is always protected by the lock. + */ + +#ifndef USE_WORKER_THREADS + ISC_LIST_INIT(new_ready_tasks); + ISC_LIST_INIT(new_priority_tasks); +#endif + LOCK(&manager->lock); + + while (!FINISHED(manager)) { +#ifdef USE_WORKER_THREADS + /* + * For reasons similar to those given in the comment in + * isc_task_send() above, it is safe for us to dequeue + * the task while only holding the manager lock, and then + * change the task to running state while only holding the + * task lock. + * + * If a pause has been requested, don't do any work + * until it's been released. + */ + while ((empty_readyq(manager) || manager->pause_requested || + manager->exclusive_requested) && !FINISHED(manager)) + { + XTHREADTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_WAIT, "wait")); + WAIT(&manager->work_available, &manager->lock); + XTHREADTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_AWAKE, "awake")); + } +#else /* USE_WORKER_THREADS */ + if (total_dispatch_count >= DEFAULT_TASKMGR_QUANTUM || + empty_readyq(manager)) + break; +#endif /* USE_WORKER_THREADS */ + XTHREADTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TASK, + ISC_MSG_WORKING, "working")); + + task = pop_readyq(manager); + if (task != NULL) { + unsigned int dispatch_count = 0; + isc_boolean_t done = ISC_FALSE; + isc_boolean_t requeue = ISC_FALSE; + isc_boolean_t finished = ISC_FALSE; + isc_event_t *event; + + INSIST(VALID_TASK(task)); + + /* + * Note we only unlock the manager lock if we actually + * have a task to do. We must reacquire the manager + * lock before exiting the 'if (task != NULL)' block. + */ + manager->tasks_running++; + UNLOCK(&manager->lock); + + LOCK(&task->lock); + INSIST(task->state == task_state_ready); + task->state = task_state_running; + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RUNNING, "running")); + isc_stdtime_get(&task->now); + do { + if (!EMPTY(task->events)) { + event = HEAD(task->events); + DEQUEUE(task->events, event, ev_link); + + /* + * Execute the event action. + */ + XTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_EXECUTE, + "execute action")); + if (event->ev_action != NULL) { + UNLOCK(&task->lock); + (event->ev_action)( + (isc_task_t *)task, + event); + LOCK(&task->lock); + } + dispatch_count++; +#ifndef USE_WORKER_THREADS + total_dispatch_count++; +#endif /* USE_WORKER_THREADS */ + } + + if (task->references == 0 && + EMPTY(task->events) && + !TASK_SHUTTINGDOWN(task)) { + isc_boolean_t was_idle; + + /* + * There are no references and no + * pending events for this task, + * which means it will not become + * runnable again via an external + * action (such as sending an event + * or detaching). + * + * We initiate shutdown to prevent + * it from becoming a zombie. + * + * We do this here instead of in + * the "if EMPTY(task->events)" block + * below because: + * + * If we post no shutdown events, + * we want the task to finish. + * + * If we did post shutdown events, + * will still want the task's + * quantum to be applied. + */ + was_idle = task_shutdown(task); + INSIST(!was_idle); + } + + if (EMPTY(task->events)) { + /* + * Nothing else to do for this task + * right now. + */ + XTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_EMPTY, + "empty")); + if (task->references == 0 && + TASK_SHUTTINGDOWN(task)) { + /* + * The task is done. + */ + XTRACE(isc_msgcat_get( + isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_DONE, + "done")); + finished = ISC_TRUE; + task->state = task_state_done; + } else + task->state = task_state_idle; + done = ISC_TRUE; + } else if (dispatch_count >= task->quantum) { + /* + * Our quantum has expired, but + * there is more work to be done. + * We'll requeue it to the ready + * queue later. + * + * We don't check quantum until + * dispatching at least one event, + * so the minimum quantum is one. + */ + XTRACE(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TASK, + ISC_MSG_QUANTUM, + "quantum")); + task->state = task_state_ready; + requeue = ISC_TRUE; + done = ISC_TRUE; + } + } while (!done); + UNLOCK(&task->lock); + + if (finished) + task_finished(task); + + LOCK(&manager->lock); + manager->tasks_running--; +#ifdef USE_WORKER_THREADS + if (manager->exclusive_requested && + manager->tasks_running == 1) { + SIGNAL(&manager->exclusive_granted); + } else if (manager->pause_requested && + manager->tasks_running == 0) { + SIGNAL(&manager->paused); + } +#endif /* USE_WORKER_THREADS */ + if (requeue) { + /* + * We know we're awake, so we don't have + * to wakeup any sleeping threads if the + * ready queue is empty before we requeue. + * + * A possible optimization if the queue is + * empty is to 'goto' the 'if (task != NULL)' + * block, avoiding the ENQUEUE of the task + * and the subsequent immediate DEQUEUE + * (since it is the only executable task). + * We don't do this because then we'd be + * skipping the exit_requested check. The + * cost of ENQUEUE is low anyway, especially + * when you consider that we'd have to do + * an extra EMPTY check to see if we could + * do the optimization. If the ready queue + * were usually nonempty, the 'optimization' + * might even hurt rather than help. + */ +#ifdef USE_WORKER_THREADS + push_readyq(manager, task); +#else + ENQUEUE(new_ready_tasks, task, ready_link); + if ((task->flags & TASK_F_PRIVILEGED) != 0) + ENQUEUE(new_priority_tasks, task, + ready_priority_link); +#endif + } + } + +#ifdef USE_WORKER_THREADS + /* + * If we are in privileged execution mode and there are no + * tasks remaining on the current ready queue, then + * we're stuck. Automatically drop privileges at that + * point and continue with the regular ready queue. + */ + if (manager->tasks_running == 0 && empty_readyq(manager)) { + manager->mode = isc_taskmgrmode_normal; + if (!empty_readyq(manager)) + BROADCAST(&manager->work_available); + } +#endif + } + +#ifndef USE_WORKER_THREADS + ISC_LIST_APPENDLIST(manager->ready_tasks, new_ready_tasks, ready_link); + ISC_LIST_APPENDLIST(manager->ready_priority_tasks, new_priority_tasks, + ready_priority_link); + if (empty_readyq(manager)) + manager->mode = isc_taskmgrmode_normal; +#endif + + UNLOCK(&manager->lock); +} + +#ifdef USE_WORKER_THREADS +static isc_threadresult_t +#ifdef _WIN32 +WINAPI +#endif +run(void *uap) { + isc__taskmgr_t *manager = uap; + + XTHREADTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_STARTING, "starting")); + + dispatch(manager); + + XTHREADTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_EXITING, "exiting")); + +#ifdef OPENSSL_LEAKS + ERR_remove_state(0); +#endif + + return ((isc_threadresult_t)0); +} +#endif /* USE_WORKER_THREADS */ + +static void +manager_free(isc__taskmgr_t *manager) { + isc_mem_t *mctx; + + LOCK(&manager->lock); +#ifdef USE_WORKER_THREADS + (void)isc_condition_destroy(&manager->exclusive_granted); + (void)isc_condition_destroy(&manager->work_available); + (void)isc_condition_destroy(&manager->paused); + isc_mem_free(manager->mctx, manager->threads); +#endif /* USE_WORKER_THREADS */ + manager->common.impmagic = 0; + manager->common.magic = 0; + mctx = manager->mctx; + UNLOCK(&manager->lock); + DESTROYLOCK(&manager->lock); + isc_mem_put(mctx, manager, sizeof(*manager)); + isc_mem_detach(&mctx); + +#ifdef USE_SHARED_MANAGER + taskmgr = NULL; +#endif /* USE_SHARED_MANAGER */ +} + +ISC_TASKFUNC_SCOPE isc_result_t +isc__taskmgr_create(isc_mem_t *mctx, unsigned int workers, + unsigned int default_quantum, isc_taskmgr_t **managerp) +{ + isc_result_t result; + unsigned int i, started = 0; + isc__taskmgr_t *manager; + + /* + * Create a new task manager. + */ + + REQUIRE(workers > 0); + REQUIRE(managerp != NULL && *managerp == NULL); + +#ifndef USE_WORKER_THREADS + UNUSED(i); + UNUSED(started); +#endif + +#ifdef USE_SHARED_MANAGER + if (taskmgr != NULL) { + if (taskmgr->refs == 0) + return (ISC_R_SHUTTINGDOWN); + taskmgr->refs++; + *managerp = (isc_taskmgr_t *)taskmgr; + return (ISC_R_SUCCESS); + } +#endif /* USE_SHARED_MANAGER */ + + manager = isc_mem_get(mctx, sizeof(*manager)); + if (manager == NULL) + return (ISC_R_NOMEMORY); + manager->common.methods = &taskmgrmethods; + manager->common.impmagic = TASK_MANAGER_MAGIC; + manager->common.magic = ISCAPI_TASKMGR_MAGIC; + manager->mode = isc_taskmgrmode_normal; + manager->mctx = NULL; + result = isc_mutex_init(&manager->lock); + if (result != ISC_R_SUCCESS) + goto cleanup_mgr; + LOCK(&manager->lock); + +#ifdef USE_WORKER_THREADS + manager->workers = 0; + manager->threads = isc_mem_allocate(mctx, + workers * sizeof(isc_thread_t)); + if (manager->threads == NULL) { + result = ISC_R_NOMEMORY; + goto cleanup_lock; + } + if (isc_condition_init(&manager->work_available) != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + result = ISC_R_UNEXPECTED; + goto cleanup_threads; + } + if (isc_condition_init(&manager->exclusive_granted) != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + result = ISC_R_UNEXPECTED; + goto cleanup_workavailable; + } + if (isc_condition_init(&manager->paused) != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + result = ISC_R_UNEXPECTED; + goto cleanup_exclusivegranted; + } +#endif /* USE_WORKER_THREADS */ + if (default_quantum == 0) + default_quantum = DEFAULT_DEFAULT_QUANTUM; + manager->default_quantum = default_quantum; + INIT_LIST(manager->tasks); + INIT_LIST(manager->ready_tasks); + INIT_LIST(manager->ready_priority_tasks); + manager->tasks_running = 0; + manager->exclusive_requested = ISC_FALSE; + manager->pause_requested = ISC_FALSE; + manager->exiting = ISC_FALSE; + + isc_mem_attach(mctx, &manager->mctx); + +#ifdef USE_WORKER_THREADS + /* + * Start workers. + */ + for (i = 0; i < workers; i++) { + if (isc_thread_create(run, manager, + &manager->threads[manager->workers]) == + ISC_R_SUCCESS) { + manager->workers++; + started++; + } + } + UNLOCK(&manager->lock); + + if (started == 0) { + manager_free(manager); + return (ISC_R_NOTHREADS); + } + isc_thread_setconcurrency(workers); +#endif /* USE_WORKER_THREADS */ +#ifdef USE_SHARED_MANAGER + manager->refs = 1; + UNLOCK(&manager->lock); + taskmgr = manager; +#endif /* USE_SHARED_MANAGER */ + + *managerp = (isc_taskmgr_t *)manager; + + return (ISC_R_SUCCESS); + +#ifdef USE_WORKER_THREADS + cleanup_exclusivegranted: + (void)isc_condition_destroy(&manager->exclusive_granted); + cleanup_workavailable: + (void)isc_condition_destroy(&manager->work_available); + cleanup_threads: + isc_mem_free(mctx, manager->threads); + cleanup_lock: + UNLOCK(&manager->lock); + DESTROYLOCK(&manager->lock); +#endif + cleanup_mgr: + isc_mem_put(mctx, manager, sizeof(*manager)); + return (result); +} + +ISC_TASKFUNC_SCOPE void +isc__taskmgr_destroy(isc_taskmgr_t **managerp) { + isc__taskmgr_t *manager; + isc__task_t *task; + unsigned int i; + + /* + * Destroy '*managerp'. + */ + + REQUIRE(managerp != NULL); + manager = (isc__taskmgr_t *)*managerp; + REQUIRE(VALID_MANAGER(manager)); + +#ifndef USE_WORKER_THREADS + UNUSED(i); +#endif /* USE_WORKER_THREADS */ + +#ifdef USE_SHARED_MANAGER + manager->refs--; + if (manager->refs > 0) { + *managerp = NULL; + return; + } +#endif + + XTHREADTRACE("isc_taskmgr_destroy"); + /* + * Only one non-worker thread may ever call this routine. + * If a worker thread wants to initiate shutdown of the + * task manager, it should ask some non-worker thread to call + * isc_taskmgr_destroy(), e.g. by signalling a condition variable + * that the startup thread is sleeping on. + */ + + /* + * Unlike elsewhere, we're going to hold this lock a long time. + * We need to do so, because otherwise the list of tasks could + * change while we were traversing it. + * + * This is also the only function where we will hold both the + * task manager lock and a task lock at the same time. + */ + + LOCK(&manager->lock); + + /* + * Make sure we only get called once. + */ + INSIST(!manager->exiting); + manager->exiting = ISC_TRUE; + + /* + * If privileged mode was on, turn it off. + */ + manager->mode = isc_taskmgrmode_normal; + + /* + * Post shutdown event(s) to every task (if they haven't already been + * posted). + */ + for (task = HEAD(manager->tasks); + task != NULL; + task = NEXT(task, link)) { + LOCK(&task->lock); + if (task_shutdown(task)) + push_readyq(manager, task); + UNLOCK(&task->lock); + } +#ifdef USE_WORKER_THREADS + /* + * Wake up any sleeping workers. This ensures we get work done if + * there's work left to do, and if there are already no tasks left + * it will cause the workers to see manager->exiting. + */ + BROADCAST(&manager->work_available); + UNLOCK(&manager->lock); + + /* + * Wait for all the worker threads to exit. + */ + for (i = 0; i < manager->workers; i++) + (void)isc_thread_join(manager->threads[i], NULL); +#else /* USE_WORKER_THREADS */ + /* + * Dispatch the shutdown events. + */ + UNLOCK(&manager->lock); + while (isc__taskmgr_ready((isc_taskmgr_t *)manager)) + (void)isc__taskmgr_dispatch((isc_taskmgr_t *)manager); +#ifdef BIND9 + if (!ISC_LIST_EMPTY(manager->tasks)) + isc_mem_printallactive(stderr); +#endif + INSIST(ISC_LIST_EMPTY(manager->tasks)); +#ifdef USE_SHARED_MANAGER + taskmgr = NULL; +#endif +#endif /* USE_WORKER_THREADS */ + + manager_free(manager); + + *managerp = NULL; +} + +ISC_TASKFUNC_SCOPE void +isc__taskmgr_setmode(isc_taskmgr_t *manager0, isc_taskmgrmode_t mode) { + isc__taskmgr_t *manager = (isc__taskmgr_t *)manager0; + + LOCK(&manager->lock); + manager->mode = mode; + UNLOCK(&manager->lock); +} + +ISC_TASKFUNC_SCOPE isc_taskmgrmode_t +isc__taskmgr_mode(isc_taskmgr_t *manager0) { + isc__taskmgr_t *manager = (isc__taskmgr_t *)manager0; + isc_taskmgrmode_t mode; + LOCK(&manager->lock); + mode = manager->mode; + UNLOCK(&manager->lock); + return (mode); +} + +#ifndef USE_WORKER_THREADS +isc_boolean_t +isc__taskmgr_ready(isc_taskmgr_t *manager0) { + isc__taskmgr_t *manager = (isc__taskmgr_t *)manager0; + isc_boolean_t is_ready; + +#ifdef USE_SHARED_MANAGER + if (manager == NULL) + manager = taskmgr; +#endif + if (manager == NULL) + return (ISC_FALSE); + + LOCK(&manager->lock); + is_ready = !empty_readyq(manager); + UNLOCK(&manager->lock); + + return (is_ready); +} + +isc_result_t +isc__taskmgr_dispatch(isc_taskmgr_t *manager0) { + isc__taskmgr_t *manager = (isc__taskmgr_t *)manager0; + +#ifdef USE_SHARED_MANAGER + if (manager == NULL) + manager = taskmgr; +#endif + if (manager == NULL) + return (ISC_R_NOTFOUND); + + dispatch(manager); + + return (ISC_R_SUCCESS); +} + +#else +ISC_TASKFUNC_SCOPE void +isc__taskmgr_pause(isc_taskmgr_t *manager0) { + isc__taskmgr_t *manager = (isc__taskmgr_t *)manager0; + LOCK(&manager->lock); + while (manager->tasks_running > 0) { + WAIT(&manager->paused, &manager->lock); + } + manager->pause_requested = ISC_TRUE; + UNLOCK(&manager->lock); +} + +ISC_TASKFUNC_SCOPE void +isc__taskmgr_resume(isc_taskmgr_t *manager0) { + isc__taskmgr_t *manager = (isc__taskmgr_t *)manager0; + + LOCK(&manager->lock); + if (manager->pause_requested) { + manager->pause_requested = ISC_FALSE; + BROADCAST(&manager->work_available); + } + UNLOCK(&manager->lock); +} +#endif /* USE_WORKER_THREADS */ + +ISC_TASKFUNC_SCOPE isc_result_t +isc__task_beginexclusive(isc_task_t *task0) { +#ifdef USE_WORKER_THREADS + isc__task_t *task = (isc__task_t *)task0; + isc__taskmgr_t *manager = task->manager; + REQUIRE(task->state == task_state_running); + LOCK(&manager->lock); + if (manager->exclusive_requested) { + UNLOCK(&manager->lock); + return (ISC_R_LOCKBUSY); + } + manager->exclusive_requested = ISC_TRUE; + while (manager->tasks_running > 1) { + WAIT(&manager->exclusive_granted, &manager->lock); + } + UNLOCK(&manager->lock); +#else + UNUSED(task0); +#endif + return (ISC_R_SUCCESS); +} + +ISC_TASKFUNC_SCOPE void +isc__task_endexclusive(isc_task_t *task0) { +#ifdef USE_WORKER_THREADS + isc__task_t *task = (isc__task_t *)task0; + isc__taskmgr_t *manager = task->manager; + + REQUIRE(task->state == task_state_running); + LOCK(&manager->lock); + REQUIRE(manager->exclusive_requested); + manager->exclusive_requested = ISC_FALSE; + BROADCAST(&manager->work_available); + UNLOCK(&manager->lock); +#else + UNUSED(task0); +#endif +} + +ISC_TASKFUNC_SCOPE void +isc__task_setprivilege(isc_task_t *task0, isc_boolean_t priv) { + isc__task_t *task = (isc__task_t *)task0; + isc__taskmgr_t *manager = task->manager; + isc_boolean_t oldpriv; + + LOCK(&task->lock); + oldpriv = ISC_TF((task->flags & TASK_F_PRIVILEGED) != 0); + if (priv) + task->flags |= TASK_F_PRIVILEGED; + else + task->flags &= ~TASK_F_PRIVILEGED; + UNLOCK(&task->lock); + + if (priv == oldpriv) + return; + + LOCK(&manager->lock); + if (priv && ISC_LINK_LINKED(task, ready_link)) + ENQUEUE(manager->ready_priority_tasks, task, + ready_priority_link); + else if (!priv && ISC_LINK_LINKED(task, ready_priority_link)) + DEQUEUE(manager->ready_priority_tasks, task, + ready_priority_link); + UNLOCK(&manager->lock); +} + +ISC_TASKFUNC_SCOPE isc_boolean_t +isc__task_privilege(isc_task_t *task0) { + isc__task_t *task = (isc__task_t *)task0; + isc_boolean_t priv; + + LOCK(&task->lock); + priv = ISC_TF((task->flags & TASK_F_PRIVILEGED) != 0); + UNLOCK(&task->lock); + return (priv); +} + +#ifdef USE_SOCKETIMPREGISTER +isc_result_t +isc__task_register() { + return (isc_task_register(isc__taskmgr_create)); +} +#endif + +isc_boolean_t +isc_task_exiting(isc_task_t *t) { + isc__task_t *task = (isc__task_t *)t; + + REQUIRE(VALID_TASK(task)); + return (TASK_SHUTTINGDOWN(task)); +} + + +#if defined(HAVE_LIBXML2) && defined(BIND9) +void +isc_taskmgr_renderxml(isc_taskmgr_t *mgr0, xmlTextWriterPtr writer) { + isc__taskmgr_t *mgr = (isc__taskmgr_t *)mgr0; + isc__task_t *task; + + LOCK(&mgr->lock); + + /* + * Write out the thread-model, and some details about each depending + * on which type is enabled. + */ + xmlTextWriterStartElement(writer, ISC_XMLCHAR "thread-model"); +#ifdef ISC_PLATFORM_USETHREADS + xmlTextWriterStartElement(writer, ISC_XMLCHAR "type"); + xmlTextWriterWriteString(writer, ISC_XMLCHAR "threaded"); + xmlTextWriterEndElement(writer); /* type */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "worker-threads"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->workers); + xmlTextWriterEndElement(writer); /* worker-threads */ +#else /* ISC_PLATFORM_USETHREADS */ + xmlTextWriterStartElement(writer, ISC_XMLCHAR "type"); + xmlTextWriterWriteString(writer, ISC_XMLCHAR "non-threaded"); + xmlTextWriterEndElement(writer); /* type */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->refs); + xmlTextWriterEndElement(writer); /* references */ +#endif /* ISC_PLATFORM_USETHREADS */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "default-quantum"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->default_quantum); + xmlTextWriterEndElement(writer); /* default-quantum */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "tasks-running"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->tasks_running); + xmlTextWriterEndElement(writer); /* tasks-running */ + + xmlTextWriterEndElement(writer); /* thread-model */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "tasks"); + task = ISC_LIST_HEAD(mgr->tasks); + while (task != NULL) { + LOCK(&task->lock); + xmlTextWriterStartElement(writer, ISC_XMLCHAR "task"); + + if (task->name[0] != 0) { + xmlTextWriterStartElement(writer, ISC_XMLCHAR "name"); + xmlTextWriterWriteFormatString(writer, "%s", + task->name); + xmlTextWriterEndElement(writer); /* name */ + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", task->references); + xmlTextWriterEndElement(writer); /* references */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "id"); + xmlTextWriterWriteFormatString(writer, "%p", task); + xmlTextWriterEndElement(writer); /* id */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "state"); + xmlTextWriterWriteFormatString(writer, "%s", + statenames[task->state]); + xmlTextWriterEndElement(writer); /* state */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "quantum"); + xmlTextWriterWriteFormatString(writer, "%d", task->quantum); + xmlTextWriterEndElement(writer); /* quantum */ + + xmlTextWriterEndElement(writer); + + UNLOCK(&task->lock); + task = ISC_LIST_NEXT(task, link); + } + xmlTextWriterEndElement(writer); /* tasks */ + + UNLOCK(&mgr->lock); +} +#endif /* HAVE_LIBXML2 && BIND9 */ diff --git a/contrib/ntp/lib/isc/task_api.c b/contrib/ntp/lib/isc/task_api.c new file mode 100644 index 000000000..34510ff64 --- /dev/null +++ b/contrib/ntp/lib/isc/task_api.c @@ -0,0 +1,244 @@ +/* + * Copyright (C) 2009-2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#include + +#include + +#include +#include +#include +#include +#include +#include + +static isc_mutex_t createlock; +static isc_once_t once = ISC_ONCE_INIT; +static isc_taskmgrcreatefunc_t taskmgr_createfunc = NULL; + +static void +initialize(void) { + RUNTIME_CHECK(isc_mutex_init(&createlock) == ISC_R_SUCCESS); +} + +isc_result_t +isc_task_register(isc_taskmgrcreatefunc_t createfunc) { + isc_result_t result = ISC_R_SUCCESS; + + RUNTIME_CHECK(isc_once_do(&once, initialize) == ISC_R_SUCCESS); + + LOCK(&createlock); + if (taskmgr_createfunc == NULL) + taskmgr_createfunc = createfunc; + else + result = ISC_R_EXISTS; + UNLOCK(&createlock); + + return (result); +} + +isc_result_t +isc_taskmgr_createinctx(isc_mem_t *mctx, isc_appctx_t *actx, + unsigned int workers, unsigned int default_quantum, + isc_taskmgr_t **managerp) +{ + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(taskmgr_createfunc != NULL); + result = (*taskmgr_createfunc)(mctx, workers, default_quantum, + managerp); + + UNLOCK(&createlock); + + if (result == ISC_R_SUCCESS) + isc_appctx_settaskmgr(actx, *managerp); + + return (result); +} + +isc_result_t +isc_taskmgr_create(isc_mem_t *mctx, unsigned int workers, + unsigned int default_quantum, isc_taskmgr_t **managerp) +{ + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(taskmgr_createfunc != NULL); + result = (*taskmgr_createfunc)(mctx, workers, default_quantum, + managerp); + + UNLOCK(&createlock); + + return (result); +} + +void +isc_taskmgr_destroy(isc_taskmgr_t **managerp) { + REQUIRE(managerp != NULL && ISCAPI_TASKMGR_VALID(*managerp)); + + (*managerp)->methods->destroy(managerp); + + ENSURE(*managerp == NULL); +} + +void +isc_taskmgr_setmode(isc_taskmgr_t *manager, isc_taskmgrmode_t mode) { + REQUIRE(ISCAPI_TASKMGR_VALID(manager)); + + manager->methods->setmode(manager, mode); +} + +isc_taskmgrmode_t +isc_taskmgr_mode(isc_taskmgr_t *manager) { + REQUIRE(ISCAPI_TASKMGR_VALID(manager)); + + return (manager->methods->mode(manager)); +} + +isc_result_t +isc_task_create(isc_taskmgr_t *manager, unsigned int quantum, + isc_task_t **taskp) +{ + REQUIRE(ISCAPI_TASKMGR_VALID(manager)); + REQUIRE(taskp != NULL && *taskp == NULL); + + return (manager->methods->taskcreate(manager, quantum, taskp)); +} + +void +isc_task_attach(isc_task_t *source, isc_task_t **targetp) { + REQUIRE(ISCAPI_TASK_VALID(source)); + REQUIRE(targetp != NULL && *targetp == NULL); + + source->methods->attach(source, targetp); + + ENSURE(*targetp == source); +} + +void +isc_task_detach(isc_task_t **taskp) { + REQUIRE(taskp != NULL && ISCAPI_TASK_VALID(*taskp)); + + (*taskp)->methods->detach(taskp); + + ENSURE(*taskp == NULL); +} + +void +isc_task_send(isc_task_t *task, isc_event_t **eventp) { + REQUIRE(ISCAPI_TASK_VALID(task)); + REQUIRE(eventp != NULL && *eventp != NULL); + + task->methods->send(task, eventp); + + ENSURE(*eventp == NULL); +} + +void +isc_task_sendanddetach(isc_task_t **taskp, isc_event_t **eventp) { + REQUIRE(taskp != NULL && ISCAPI_TASK_VALID(*taskp)); + REQUIRE(eventp != NULL && *eventp != NULL); + + (*taskp)->methods->sendanddetach(taskp, eventp); + + ENSURE(*taskp == NULL && *eventp == NULL); +} + +unsigned int +isc_task_unsend(isc_task_t *task, void *sender, isc_eventtype_t type, + void *tag, isc_eventlist_t *events) +{ + REQUIRE(ISCAPI_TASK_VALID(task)); + + return (task->methods->unsend(task, sender, type, tag, events)); +} + +isc_result_t +isc_task_onshutdown(isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + REQUIRE(ISCAPI_TASK_VALID(task)); + + return (task->methods->onshutdown(task, action, arg)); +} + +void +isc_task_shutdown(isc_task_t *task) { + REQUIRE(ISCAPI_TASK_VALID(task)); + + task->methods->shutdown(task); +} + +void +isc_task_setname(isc_task_t *task, const char *name, void *tag) { + REQUIRE(ISCAPI_TASK_VALID(task)); + + task->methods->setname(task, name, tag); +} + +unsigned int +isc_task_purge(isc_task_t *task, void *sender, isc_eventtype_t type, void *tag) +{ + REQUIRE(ISCAPI_TASK_VALID(task)); + + return (task->methods->purgeevents(task, sender, type, tag)); +} + +isc_result_t +isc_task_beginexclusive(isc_task_t *task) { + REQUIRE(ISCAPI_TASK_VALID(task)); + + return (task->methods->beginexclusive(task)); +} + +void +isc_task_endexclusive(isc_task_t *task) { + REQUIRE(ISCAPI_TASK_VALID(task)); + + task->methods->endexclusive(task); +} + +void +isc_task_setprivilege(isc_task_t *task, isc_boolean_t priv) { + REQUIRE(ISCAPI_TASK_VALID(task)); + + task->methods->setprivilege(task, priv); +} + +isc_boolean_t +isc_task_privilege(isc_task_t *task) { + REQUIRE(ISCAPI_TASK_VALID(task)); + + return (task->methods->privilege(task)); +} + + +/*% + * This is necessary for libisc's internal timer implementation. Other + * implementation might skip implementing this. + */ +unsigned int +isc_task_purgerange(isc_task_t *task, void *sender, isc_eventtype_t first, + isc_eventtype_t last, void *tag) +{ + REQUIRE(ISCAPI_TASK_VALID(task)); + + return (task->methods->purgerange(task, sender, first, last, tag)); +} diff --git a/contrib/ntp/lib/isc/task_p.h b/contrib/ntp/lib/isc/task_p.h new file mode 100644 index 000000000..8c1e4c52f --- /dev/null +++ b/contrib/ntp/lib/isc/task_p.h @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_TASK_P_H +#define ISC_TASK_P_H + +/*! \file */ + +#if defined(BIND9) && defined(ISC_PLATFORM_USETHREADS) +void +isc__taskmgr_pause(isc_taskmgr_t *taskmgr); + +void +isc__taskmgr_resume(isc_taskmgr_t *taskmgr); +#else +isc_boolean_t +isc__taskmgr_ready(isc_taskmgr_t *taskmgr); + +isc_result_t +isc__taskmgr_dispatch(isc_taskmgr_t *taskmgr); +#endif /* !BIND9 || !ISC_PLATFORM_USETHREADS */ + +#endif /* ISC_TASK_P_H */ diff --git a/contrib/ntp/lib/isc/taskpool.c b/contrib/ntp/lib/isc/taskpool.c new file mode 100644 index 000000000..25d951682 --- /dev/null +++ b/contrib/ntp/lib/isc/taskpool.c @@ -0,0 +1,185 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include +#include + +/*** + *** Types. + ***/ + +struct isc_taskpool { + isc_mem_t * mctx; + isc_taskmgr_t * tmgr; + unsigned int ntasks; + unsigned int quantum; + isc_task_t ** tasks; +}; + +/*** + *** Functions. + ***/ + +static isc_result_t +alloc_pool(isc_taskmgr_t *tmgr, isc_mem_t *mctx, unsigned int ntasks, + unsigned int quantum, isc_taskpool_t **poolp) +{ + isc_taskpool_t *pool; + unsigned int i; + + pool = isc_mem_get(mctx, sizeof(*pool)); + if (pool == NULL) + return (ISC_R_NOMEMORY); + pool->mctx = mctx; + pool->ntasks = ntasks; + pool->quantum = quantum; + pool->tmgr = tmgr; + pool->tasks = isc_mem_get(mctx, ntasks * sizeof(isc_task_t *)); + if (pool->tasks == NULL) { + isc_mem_put(mctx, pool, sizeof(*pool)); + return (ISC_R_NOMEMORY); + } + for (i = 0; i < ntasks; i++) + pool->tasks[i] = NULL; + + *poolp = pool; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_taskpool_create(isc_taskmgr_t *tmgr, isc_mem_t *mctx, + unsigned int ntasks, unsigned int quantum, + isc_taskpool_t **poolp) +{ + unsigned int i; + isc_taskpool_t *pool = NULL; + isc_result_t result; + + INSIST(ntasks > 0); + + /* Allocate the pool structure */ + result = alloc_pool(tmgr, mctx, ntasks, quantum, &pool); + if (result != ISC_R_SUCCESS) + return (result); + + /* Create the tasks */ + for (i = 0; i < ntasks; i++) { + result = isc_task_create(tmgr, quantum, &pool->tasks[i]); + if (result != ISC_R_SUCCESS) { + isc_taskpool_destroy(&pool); + return (result); + } + isc_task_setname(pool->tasks[i], "taskpool", NULL); + } + + *poolp = pool; + return (ISC_R_SUCCESS); +} + +void +isc_taskpool_gettask(isc_taskpool_t *pool, isc_task_t **targetp) { + isc_uint32_t i; + isc_random_get(&i); + isc_task_attach(pool->tasks[i % pool->ntasks], targetp); +} + +int +isc_taskpool_size(isc_taskpool_t *pool) { + REQUIRE(pool != NULL); + return (pool->ntasks); +} + +isc_result_t +isc_taskpool_expand(isc_taskpool_t **sourcep, unsigned int size, + isc_taskpool_t **targetp) +{ + isc_result_t result; + isc_taskpool_t *pool; + + REQUIRE(sourcep != NULL && *sourcep != NULL); + REQUIRE(targetp != NULL && *targetp == NULL); + + pool = *sourcep; + if (size > pool->ntasks) { + isc_taskpool_t *newpool = NULL; + unsigned int i; + + /* Allocate a new pool structure */ + result = alloc_pool(pool->tmgr, pool->mctx, size, + pool->quantum, &newpool); + if (result != ISC_R_SUCCESS) + return (result); + + /* Copy over the tasks from the old pool */ + for (i = 0; i < pool->ntasks; i++) { + newpool->tasks[i] = pool->tasks[i]; + pool->tasks[i] = NULL; + } + + /* Create new tasks */ + for (i = pool->ntasks; i < size; i++) { + result = isc_task_create(pool->tmgr, pool->quantum, + &newpool->tasks[i]); + if (result != ISC_R_SUCCESS) { + isc_taskpool_destroy(&newpool); + return (result); + } + isc_task_setname(newpool->tasks[i], "taskpool", NULL); + } + + isc_taskpool_destroy(&pool); + pool = newpool; + } + + *sourcep = NULL; + *targetp = pool; + return (ISC_R_SUCCESS); +} + +void +isc_taskpool_destroy(isc_taskpool_t **poolp) { + unsigned int i; + isc_taskpool_t *pool = *poolp; + for (i = 0; i < pool->ntasks; i++) { + if (pool->tasks[i] != NULL) + isc_task_detach(&pool->tasks[i]); + } + isc_mem_put(pool->mctx, pool->tasks, + pool->ntasks * sizeof(isc_task_t *)); + isc_mem_put(pool->mctx, pool, sizeof(*pool)); + *poolp = NULL; +} + +void +isc_taskpool_setprivilege(isc_taskpool_t *pool, isc_boolean_t priv) { + unsigned int i; + + REQUIRE(pool != NULL); + + for (i = 0; i < pool->ntasks; i++) { + if (pool->tasks[i] != NULL) + isc_task_setprivilege(pool->tasks[i], priv); + } +} diff --git a/contrib/ntp/lib/isc/tests/Atffile b/contrib/ntp/lib/isc/tests/Atffile new file mode 100644 index 000000000..c3e044f41 --- /dev/null +++ b/contrib/ntp/lib/isc/tests/Atffile @@ -0,0 +1,5 @@ +Content-Type: application/X-atf-atffile; version="1" + +prop: test-suite = bind9 + +tp-glob: *_test diff --git a/contrib/ntp/lib/isc/tests/hash_test.c b/contrib/ntp/lib/isc/tests/hash_test.c new file mode 100644 index 000000000..836d7b67a --- /dev/null +++ b/contrib/ntp/lib/isc/tests/hash_test.c @@ -0,0 +1,1805 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* ! \file */ + +#include + +#include + +#include +#include + +#include +#include +#include +#include +#include +#include + +/* + * Test data from RFC6234 + */ + +unsigned char digest[ISC_SHA512_DIGESTLENGTH]; +unsigned char buffer[1024]; +const char *s; +char str[ISC_SHA512_DIGESTLENGTH]; +unsigned char key[20]; +int i = 0; + +isc_result_t +tohexstr(unsigned char *d, unsigned int len, char *out); +/* + * Precondition: a hexadecimal number in *d, the length of that number in len, + * and a pointer to a character array to put the output (*out). + * Postcondition: A String representation of the given hexadecimal number is + * placed into the array *out + * + * 'out' MUST point to an array of at least len / 2 + 1 + * + * Return values: ISC_R_SUCCESS if the operation is sucessful + */ + +isc_result_t +tohexstr(unsigned char *d, unsigned int len, char *out) { + + out[0]='\0'; + char c_ret[] = "AA"; + unsigned int i; + strcat(out, "0x"); + for (i = 0; i < len; i++) { + sprintf(c_ret, "%02X", d[i]); + strcat(out, c_ret); + } + strcat(out, "\0"); + return (ISC_R_SUCCESS); +} + + +#define TEST_INPUT(x) (x), sizeof(x)-1 + +typedef struct hash_testcase { + const char *input; + size_t input_len; + const char *result; + int repeats; +} hash_testcase_t; + +typedef struct hash_test_key { + const char *key; + const int len; +} hash_test_key_t; + +/* non-hmac tests */ + +ATF_TC(isc_sha1); +ATF_TC_HEAD(isc_sha1, tc) { + atf_tc_set_md_var(tc, "descr", "sha1 examples from RFC4634"); +} +ATF_TC_BODY(isc_sha1, tc) { + isc_sha1_t sha1; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("abc"), + "0xA9993E364706816ABA3E25717850C26C9CD0D89D", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("abcdbcdecdefdefgefghfghighijhijkijk" + "ljklmklmnlmnomnopnopq"), + "0x84983E441C3BD26EBAAE4AA1F95129E5E54670F1", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("a") /* times 1000000 */, + "0x34AA973CD4C4DAA4F61EEB2BDBAD27316534016F", + 1000000 + }, + /* Test 4 -- exact multiple of 512 bits */ + { + TEST_INPUT("01234567012345670123456701234567"), + "0xDEA356A2CDDD90C7A7ECEDC5EBB563934F460452", + 20 /* 20 times */ + }, +#if 0 + /* Test 5 -- optional feature, not implemented */ + { + TEST_INPUT(""), + /* "extrabits": 0x98 , "numberextrabits": 5 */ + "0x29826B003B906E660EFF4027CE98AF3531AC75BA", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("\x5e"), + "0x5E6F80A34A9798CAFC6A5DB96CC57BA4C4DB59C2", + 1 + }, +#if 0 + /* Test 7 -- optional feature, not implemented */ + { + TEST_INPUT("\x49\xb2\xae\xc2\x59\x4b\xbe\x3a" + "\x3b\x11\x75\x42\xd9\x4a\xc8"), + /* "extrabits": 0x80, "numberextrabits": 3 */ + "0x6239781E03729919C01955B3FFA8ACB60B988340", 1 }, +#endif + /* Test 8 */ + { + TEST_INPUT("\x9a\x7d\xfd\xf1\xec\xea\xd0\x6e\xd6\x46" + "\xaa\x55\xfe\x75\x71\x46"), + "0x82ABFF6605DBE1C17DEF12A394FA22A82B544A35", + 1 + }, +#if 0 + /* Test 9 -- optional feature, not implemented */ + { + TEST_INPUT("\x65\xf9\x32\x99\x5b\xa4\xce\x2c\xb1\xb4" + "\xa2\xe7\x1a\xe7\x02\x20\xaa\xce\xc8\x96" + "\x2d\xd4\x49\x9c\xbd\x7c\x88\x7a\x94\xea" + "\xaa\x10\x1e\xa5\xaa\xbc\x52\x9b\x4e\x7e" + "\x43\x66\x5a\x5a\xf2\xcd\x03\xfe\x67\x8e" + "\xa6\xa5\x00\x5b\xba\x3b\x08\x22\x04\xc2" + "\x8b\x91\x09\xf4\x69\xda\xc9\x2a\xaa\xb3" + "\xaa\x7c\x11\xa1\xb3\x2a"), + /* "extrabits": 0xE0 , "numberextrabits": 3 */ + "0x8C5B2A5DDAE5A97FC7F9D85661C672ADBF7933D4", + 1 + }, +#endif + /* Test 10 */ + { + TEST_INPUT("\xf7\x8f\x92\x14\x1b\xcd\x17\x0a\xe8\x9b" + "\x4f\xba\x15\xa1\xd5\x9f\x3f\xd8\x4d\x22" + "\x3c\x92\x51\xbd\xac\xbb\xae\x61\xd0\x5e" + "\xd1\x15\xa0\x6a\x7c\xe1\x17\xb7\xbe\xea" + "\xd2\x44\x21\xde\xd9\xc3\x25\x92\xbd\x57" + "\xed\xea\xe3\x9c\x39\xfa\x1f\xe8\x94\x6a" + "\x84\xd0\xcf\x1f\x7b\xee\xad\x17\x13\xe2" + "\xe0\x95\x98\x97\x34\x7f\x67\xc8\x0b\x04" + "\x00\xc2\x09\x81\x5d\x6b\x10\xa6\x83\x83" + "\x6f\xd5\x56\x2a\x56\xca\xb1\xa2\x8e\x81" + "\xb6\x57\x66\x54\x63\x1c\xf1\x65\x66\xb8" + "\x6e\x3b\x33\xa1\x08\xb0\x53\x07\xc0\x0a" + "\xff\x14\xa7\x68\xed\x73\x50\x60\x6a\x0f" + "\x85\xe6\xa9\x1d\x39\x6f\x5b\x5c\xbe\x57" + "\x7f\x9b\x38\x80\x7c\x7d\x52\x3d\x6d\x79" + "\x2f\x6e\xbc\x24\xa4\xec\xf2\xb3\xa4\x27" + "\xcd\xbb\xfb"), + "0xCB0082C8F197D260991BA6A460E76E202BAD27B3", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + while (testcase->input != NULL && testcase->result != NULL) { + isc_sha1_init(&sha1); + for(i = 0; i < testcase->repeats; i++) { + isc_sha1_update(&sha1, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + } + isc_sha1_final(&sha1, digest); + tohexstr(digest, ISC_SHA1_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + } +} + + +ATF_TC(isc_sha224); +ATF_TC_HEAD(isc_sha224, tc) { + atf_tc_set_md_var(tc, "descr", "sha224 examples from RFC4634"); +} +ATF_TC_BODY(isc_sha224, tc) { + isc_sha224_t sha224; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("abc"), + "0x23097D223405D8228642A477BDA255B32AADBCE4BDA0B3F7" + "E36C9DA7", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("abcdbcdecdefdefgefghfghighijhijkijklj" + "klmklmnlmnomnopnopq"), + "0x75388B16512776CC5DBA5DA1FD890150B0C6455CB4F58B" + "1952522525", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("a"), + "0x20794655980C91D8BBB4C1EA97618A4BF03F42581948B2" + "EE4EE7AD67", + 1000000 + }, + /* Test 4 */ + { + TEST_INPUT("01234567012345670123456701234567"), + "0x567F69F168CD7844E65259CE658FE7AADFA25216E68ECA" + "0EB7AB8262", + 20 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("\x07"), + "0x00ECD5F138422B8AD74C9799FD826C531BAD2FCABC7450" + "BEE2AA8C2A", + 1 + }, +#if 0 + /* Test 7 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 8 */ + { + TEST_INPUT("\x18\x80\x40\x05\xdd\x4f\xbd\x15\x56\x29" + "\x9d\x6f\x9d\x93\xdf\x62"), + "0xDF90D78AA78821C99B40BA4C966921ACCD8FFB1E98AC38" + "8E56191DB1", + 1 + }, +#if 0 + /* Test 9 */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 10 */ + { + TEST_INPUT("\x55\xb2\x10\x07\x9c\x61\xb5\x3a\xdd\x52" + "\x06\x22\xd1\xac\x97\xd5\xcd\xbe\x8c\xb3" + "\x3a\xa0\xae\x34\x45\x17\xbe\xe4\xd7\xba" + "\x09\xab\xc8\x53\x3c\x52\x50\x88\x7a\x43" + "\xbe\xbb\xac\x90\x6c\x2e\x18\x37\xf2\x6b" + "\x36\xa5\x9a\xe3\xbe\x78\x14\xd5\x06\x89" + "\x6b\x71\x8b\x2a\x38\x3e\xcd\xac\x16\xb9" + "\x61\x25\x55\x3f\x41\x6f\xf3\x2c\x66\x74" + "\xc7\x45\x99\xa9\x00\x53\x86\xd9\xce\x11" + "\x12\x24\x5f\x48\xee\x47\x0d\x39\x6c\x1e" + "\xd6\x3b\x92\x67\x0c\xa5\x6e\xc8\x4d\xee" + "\xa8\x14\xb6\x13\x5e\xca\x54\x39\x2b\xde" + "\xdb\x94\x89\xbc\x9b\x87\x5a\x8b\xaf\x0d" + "\xc1\xae\x78\x57\x36\x91\x4a\xb7\xda\xa2" + "\x64\xbc\x07\x9d\x26\x9f\x2c\x0d\x7e\xdd" + "\xd8\x10\xa4\x26\x14\x5a\x07\x76\xf6\x7c" + "\x87\x82\x73"), + "0x0B31894EC8937AD9B91BDFBCBA294D9ADEFAA18E09305E" + "9F20D5C3A4", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + while (testcase->input != NULL && testcase->result != NULL) { + isc_sha224_init(&sha224); + for(i = 0; i < testcase->repeats; i++) { + isc_sha224_update(&sha224, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + } + isc_sha224_final(digest, &sha224); + /* + *API inconsistency BUG HERE + * in order to be consistant with the other isc_hash_final + * functions the call should be + * isc_sha224_final(&sha224, digest); + */ + tohexstr(digest, ISC_SHA224_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + } + +} + +ATF_TC(isc_sha256); +ATF_TC_HEAD(isc_sha256, tc) { + atf_tc_set_md_var(tc, "descr", "sha224 examples from RFC4634"); +} +ATF_TC_BODY(isc_sha256, tc) { + isc_sha256_t sha256; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("abc"), + "0xBA7816BF8F01CFEA414140DE5DAE2223B00361A396177A" + "9CB410FF61F20015AD", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("abcdbcdecdefdefgefghfghighijhijkijkljk" + "lmklmnlmnomnopnopq"), + "0x248D6A61D20638B8E5C026930C3E6039A33CE45964FF21" + "67F6ECEDD419DB06C1", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("a"), + "0xCDC76E5C9914FB9281A1C7E284D73E67F1809A48A49720" + "0E046D39CCC7112CD0", + 1000000 }, + /* Test 4 */ + { + TEST_INPUT("01234567012345670123456701234567"), + "0x594847328451BDFA85056225462CC1D867D877FB388DF0" + "CE35F25AB5562BFBB5", + 20 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("\x19"), + "0x68AA2E2EE5DFF96E3355E6C7EE373E3D6A4E17F75F9518" + "D843709C0C9BC3E3D4", + 1 + }, +#if 0 + /* Test 7 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 8 */ + { + TEST_INPUT("\xe3\xd7\x25\x70\xdc\xdd\x78\x7c\xe3" + "\x88\x7a\xb2\xcd\x68\x46\x52"), + "0x175EE69B02BA9B58E2B0A5FD13819CEA573F3940A94F82" + "5128CF4209BEABB4E8", + 1 + }, +#if 0 + /* Test 9 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 10 */ + { + TEST_INPUT("\x83\x26\x75\x4e\x22\x77\x37\x2f\x4f\xc1" + "\x2b\x20\x52\x7a\xfe\xf0\x4d\x8a\x05\x69" + "\x71\xb1\x1a\xd5\x71\x23\xa7\xc1\x37\x76" + "\x00\x00\xd7\xbe\xf6\xf3\xc1\xf7\xa9\x08" + "\x3a\xa3\x9d\x81\x0d\xb3\x10\x77\x7d\xab" + "\x8b\x1e\x7f\x02\xb8\x4a\x26\xc7\x73\x32" + "\x5f\x8b\x23\x74\xde\x7a\x4b\x5a\x58\xcb" + "\x5c\x5c\xf3\x5b\xce\xe6\xfb\x94\x6e\x5b" + "\xd6\x94\xfa\x59\x3a\x8b\xeb\x3f\x9d\x65" + "\x92\xec\xed\xaa\x66\xca\x82\xa2\x9d\x0c" + "\x51\xbc\xf9\x33\x62\x30\xe5\xd7\x84\xe4" + "\xc0\xa4\x3f\x8d\x79\xa3\x0a\x16\x5c\xba" + "\xbe\x45\x2b\x77\x4b\x9c\x71\x09\xa9\x7d" + "\x13\x8f\x12\x92\x28\x96\x6f\x6c\x0a\xdc" + "\x10\x6a\xad\x5a\x9f\xdd\x30\x82\x57\x69" + "\xb2\xc6\x71\xaf\x67\x59\xdf\x28\xeb\x39" + "\x3d\x54\xd6"), + "0x97DBCA7DF46D62C8A422C941DD7E835B8AD3361763F7E9" + "B2D95F4F0DA6E1CCBC", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + while (testcase->input != NULL && testcase->result != NULL) { + isc_sha256_init(&sha256); + for(i = 0; i < testcase->repeats; i++) { + isc_sha256_update(&sha256, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + } + isc_sha256_final(digest, &sha256); + /* + *API inconsistency BUG HERE + * in order to be consistant with the other isc_hash_final + * functions the call should be + * isc_sha224_final(&sha224, digest); + */ + tohexstr(digest, ISC_SHA256_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + } + +} + +ATF_TC(isc_sha384); +ATF_TC_HEAD(isc_sha384, tc) { + atf_tc_set_md_var(tc, "descr", "sha224 examples from RFC4634"); +} +ATF_TC_BODY(isc_sha384, tc) { + isc_sha384_t sha384; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("abc"), + "0xCB00753F45A35E8BB5A03D699AC65007272C32AB0EDED1" + "631A8B605A43FF5BED8086072BA1E7CC2358BAEC" + "A134C825A7", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("abcdefghbcdefghicdefghijdefghijkefghijkl" + "fghijklmghijklmnhijklmnoijklmnopjklmnopq" + "klmnopqrlmnopqrsmnopqrstnopqrstu"), + "0x09330C33F71147E83D192FC782CD1B4753111B173B3B05" + "D22FA08086E3B0F712FCC7C71A557E2DB966C3E9" + "FA91746039", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("a"), + "0x9D0E1809716474CB086E834E310A4A1CED149E9C00F248" + "527972CEC5704C2A5B07B8B3DC38ECC4EBAE97DD" + "D87F3D8985", + 1000000 + }, + /* Test 4 */ + { + TEST_INPUT("01234567012345670123456701234567"), + "0x2FC64A4F500DDB6828F6A3430B8DD72A368EB7F3A8322A" + "70BC84275B9C0B3AB00D27A5CC3C2D224AA6B61A" + "0D79FB4596", + 20 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 6 */ + { TEST_INPUT("\xb9"), + "0xBC8089A19007C0B14195F4ECC74094FEC64F01F9092928" + "2C2FB392881578208AD466828B1C6C283D2722CF" + "0AD1AB6938", + 1 + }, +#if 0 + /* Test 7 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 8 */ + { + TEST_INPUT("\xa4\x1c\x49\x77\x79\xc0\x37\x5f\xf1" + "\x0a\x7f\x4e\x08\x59\x17\x39"), + "0xC9A68443A005812256B8EC76B00516F0DBB74FAB26D665" + "913F194B6FFB0E91EA9967566B58109CBC675CC2" + "08E4C823F7", + 1 + }, +#if 0 + /* Test 9 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 10 */ + { + TEST_INPUT("\x39\x96\x69\xe2\x8f\x6b\x9c\x6d\xbc\xbb" + "\x69\x12\xec\x10\xff\xcf\x74\x79\x03\x49" + "\xb7\xdc\x8f\xbe\x4a\x8e\x7b\x3b\x56\x21" + "\xdb\x0f\x3e\x7d\xc8\x7f\x82\x32\x64\xbb" + "\xe4\x0d\x18\x11\xc9\xea\x20\x61\xe1\xc8" + "\x4a\xd1\x0a\x23\xfa\xc1\x72\x7e\x72\x02" + "\xfc\x3f\x50\x42\xe6\xbf\x58\xcb\xa8\xa2" + "\x74\x6e\x1f\x64\xf9\xb9\xea\x35\x2c\x71" + "\x15\x07\x05\x3c\xf4\xe5\x33\x9d\x52\x86" + "\x5f\x25\xcc\x22\xb5\xe8\x77\x84\xa1\x2f" + "\xc9\x61\xd6\x6c\xb6\xe8\x95\x73\x19\x9a" + "\x2c\xe6\x56\x5c\xbd\xf1\x3d\xca\x40\x38" + "\x32\xcf\xcb\x0e\x8b\x72\x11\xe8\x3a\xf3" + "\x2a\x11\xac\x17\x92\x9f\xf1\xc0\x73\xa5" + "\x1c\xc0\x27\xaa\xed\xef\xf8\x5a\xad\x7c" + "\x2b\x7c\x5a\x80\x3e\x24\x04\xd9\x6d\x2a" + "\x77\x35\x7b\xda\x1a\x6d\xae\xed\x17\x15" + "\x1c\xb9\xbc\x51\x25\xa4\x22\xe9\x41\xde" + "\x0c\xa0\xfc\x50\x11\xc2\x3e\xcf\xfe\xfd" + "\xd0\x96\x76\x71\x1c\xf3\xdb\x0a\x34\x40" + "\x72\x0e\x16\x15\xc1\xf2\x2f\xbc\x3c\x72" + "\x1d\xe5\x21\xe1\xb9\x9b\xa1\xbd\x55\x77" + "\x40\x86\x42\x14\x7e\xd0\x96"), + "0x4F440DB1E6EDD2899FA335F09515AA025EE177A79F4B4A" + "AF38E42B5C4DE660F5DE8FB2A5B2FBD2A3CBFFD2" + "0CFF1288C0", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + while (testcase->input != NULL && testcase->result != NULL) { + isc_sha384_init(&sha384); + for(i = 0; i < testcase->repeats; i++) { + isc_sha384_update(&sha384, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + } + isc_sha384_final(digest, &sha384); + /* + *API inconsistency BUG HERE + * in order to be consistant with the other isc_hash_final + * functions the call should be + * isc_sha224_final(&sha224, digest); + */ + tohexstr(digest, ISC_SHA384_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + } + +} + +ATF_TC(isc_sha512); +ATF_TC_HEAD(isc_sha512, tc) { + atf_tc_set_md_var(tc, "descr", "sha224 examples from RFC4634"); +} +ATF_TC_BODY(isc_sha512, tc) { + isc_sha512_t sha512; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("abc"), + "0xDDAF35A193617ABACC417349AE20413112E6FA4E89A97E" + "A20A9EEEE64B55D39A2192992A274FC1A836BA3C" + "23A3FEEBBD454D4423643CE80E2A9AC94FA54CA49F", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("abcdefghbcdefghicdefghijdefghijkefghijkl" + "fghijklmghijklmnhijklmnoijklmnopjklmnopq" + "klmnopqrlmnopqrsmnopqrstnopqrstu"), + "0x8E959B75DAE313DA8CF4F72814FC143F8F7779C6EB9F7F" + "A17299AEADB6889018501D289E4900F7E4331B99" + "DEC4B5433AC7D329EEB6DD26545E96E55B874BE909", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("a"), + "0xE718483D0CE769644E2E42C7BC15B4638E1F98B13B2044" + "285632A803AFA973EBDE0FF244877EA60A4CB043" + "2CE577C31BEB009C5C2C49AA2E4EADB217AD8CC09B", + 1000000 + }, + /* Test 4 */ + { + TEST_INPUT("01234567012345670123456701234567"), + "0x89D05BA632C699C31231DED4FFC127D5A894DAD412C0E0" + "24DB872D1ABD2BA8141A0F85072A9BE1E2AA04CF" + "33C765CB510813A39CD5A84C4ACAA64D3F3FB7BAE9", + 20 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("\xD0"), + "0x9992202938E882E73E20F6B69E68A0A7149090423D93C8" + "1BAB3F21678D4ACEEEE50E4E8CAFADA4C85A54EA" + "8306826C4AD6E74CECE9631BFA8A549B4AB3FBBA15", + 1 + }, +#if 0 + /* Test 7 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 8 */ + { + TEST_INPUT("\x8d\x4e\x3c\x0e\x38\x89\x19\x14\x91\x81" + "\x6e\x9d\x98\xbf\xf0\xa0"), + "0xCB0B67A4B8712CD73C9AABC0B199E9269B20844AFB75AC" + "BDD1C153C9828924C3DDEDAAFE669C5FDD0BC66F" + "630F6773988213EB1B16F517AD0DE4B2F0C95C90F8", + 1 + }, +#if 0 + /* Test 9 -- unimplemented optional functionality */ + { + TEST_INPUT(""), + "0xXXX", + 1 + }, +#endif + /* Test 10 */ + { + TEST_INPUT("\xa5\x5f\x20\xc4\x11\xaa\xd1\x32\x80\x7a" + "\x50\x2d\x65\x82\x4e\x31\xa2\x30\x54\x32" + "\xaa\x3d\x06\xd3\xe2\x82\xa8\xd8\x4e\x0d" + "\xe1\xde\x69\x74\xbf\x49\x54\x69\xfc\x7f" + "\x33\x8f\x80\x54\xd5\x8c\x26\xc4\x93\x60" + "\xc3\xe8\x7a\xf5\x65\x23\xac\xf6\xd8\x9d" + "\x03\xe5\x6f\xf2\xf8\x68\x00\x2b\xc3\xe4" + "\x31\xed\xc4\x4d\xf2\xf0\x22\x3d\x4b\xb3" + "\xb2\x43\x58\x6e\x1a\x7d\x92\x49\x36\x69" + "\x4f\xcb\xba\xf8\x8d\x95\x19\xe4\xeb\x50" + "\xa6\x44\xf8\xe4\xf9\x5e\xb0\xea\x95\xbc" + "\x44\x65\xc8\x82\x1a\xac\xd2\xfe\x15\xab" + "\x49\x81\x16\x4b\xbb\x6d\xc3\x2f\x96\x90" + "\x87\xa1\x45\xb0\xd9\xcc\x9c\x67\xc2\x2b" + "\x76\x32\x99\x41\x9c\xc4\x12\x8b\xe9\xa0" + "\x77\xb3\xac\xe6\x34\x06\x4e\x6d\x99\x28" + "\x35\x13\xdc\x06\xe7\x51\x5d\x0d\x73\x13" + "\x2e\x9a\x0d\xc6\xd3\xb1\xf8\xb2\x46\xf1" + "\xa9\x8a\x3f\xc7\x29\x41\xb1\xe3\xbb\x20" + "\x98\xe8\xbf\x16\xf2\x68\xd6\x4f\x0b\x0f" + "\x47\x07\xfe\x1e\xa1\xa1\x79\x1b\xa2\xf3" + "\xc0\xc7\x58\xe5\xf5\x51\x86\x3a\x96\xc9" + "\x49\xad\x47\xd7\xfb\x40\xd2"), + "0xC665BEFB36DA189D78822D10528CBF3B12B3EEF7260399" + "09C1A16A270D48719377966B957A878E72058477" + "9A62825C18DA26415E49A7176A894E7510FD1451F5", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + while (testcase->input != NULL && testcase->result != NULL) { + isc_sha512_init(&sha512); + for(i = 0; i < testcase->repeats; i++) { + isc_sha512_update(&sha512, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + } + isc_sha512_final(digest, &sha512); + /* + *API inconsistency BUG HERE + * in order to be consistant with the other isc_hash_final + * functions the call should be + * isc_sha224_final(&sha224, digest); + */ + tohexstr(digest, ISC_SHA512_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + } + +} + +ATF_TC(isc_md5); +ATF_TC_HEAD(isc_md5, tc) { + atf_tc_set_md_var(tc, "descr", "md5 example from RFC1321"); +} +ATF_TC_BODY(isc_md5, tc) { + isc_md5_t md5; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + { + TEST_INPUT(""), + "0xD41D8CD98F00B204E9800998ECF8427E", + 1 + }, + { + TEST_INPUT("a"), + "0x0CC175B9C0F1B6A831C399E269772661", + 1 + }, + { + TEST_INPUT("abc"), + "0x900150983CD24FB0D6963F7D28E17F72", + 1 + }, + { + TEST_INPUT("message digest"), + "0xF96B697D7CB7938D525A2F31AAF161D0", + 1 + }, + { + TEST_INPUT("abcdefghijklmnopqrstuvwxyz"), + "0xC3FCD3D76192E4007DFB496CCA67E13B", + 1 + }, + { + TEST_INPUT("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklm" + "nopqrstuvwxyz0123456789"), + "0xD174AB98D277D9F5A5611C2C9F419D9F", + 1 + }, + { + TEST_INPUT("123456789012345678901234567890123456789" + "01234567890123456789012345678901234567890"), + "0x57EDF4A22BE3C955AC49DA2E2107B67A", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + while (testcase->input != NULL && testcase->result != NULL) { + isc_md5_init(&md5); + for(i = 0; i < testcase->repeats; i++) { + isc_md5_update(&md5, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + } + isc_md5_final(&md5, digest); + tohexstr(digest, ISC_MD5_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + } +} + +/* HMAC-SHA1 test */ +ATF_TC(isc_hmacsha1); +ATF_TC_HEAD(isc_hmacsha1, tc) { + atf_tc_set_md_var(tc, "descr", "HMAC-SHA1 examples from RFC2104"); +} +ATF_TC_BODY(isc_hmacsha1, tc) { + isc_hmacsha1_t hmacsha1; + + UNUSED(tc); + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("\x48\x69\x20\x54\x68\x65\x72\x65"), + "0xB617318655057264E28BC0B6FB378C8EF146BE00", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("\x77\x68\x61\x74\x20\x64\x6f\x20\x79\x61" + "\x20\x77\x61\x6e\x74\x20\x66\x6f\x72\x20" + "\x6e\x6f\x74\x68\x69\x6e\x67\x3f"), + "0xEFFCDF6AE5EB2FA2D27416D5F184DF9C259A7C79", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD"), + "0x125D7342B9AC11CD91A39AF48AA17B4F63F175D3", + 1 + }, + /* Test 4 */ + { + TEST_INPUT("\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"), + "0x4C9007F4026250C6BC8414F9BF50C86C2D7235DA", + 1 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT("Test With Truncation"), + "0x4C1A03424B55E07FE7F27BE1", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key - " + "Hash Key First"), + "0xAA4AE5E15272D00E95705637CE8A3B55ED402112", 1 }, + /* Test 7 */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key and " + "Larger Than One Block-Size Data"), + "0xE8E99D0F45237D786D6BBAA7965C7808BBFF1A91", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + hash_test_key_t test_keys[] = { + /* Key 1 */ + { "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b" + "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b", 20 }, + /* Key 2 */ + { "Jefe", 4 }, + /* Key 3 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 20 }, + /* Key 4 */ + { "\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a" + "\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14" + "\x15\x16\x17\x18\x19", 25 }, +#if 0 + /* Key 5 */ + { "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c" + "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c", 20 }, +#endif + /* Key 6 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 80 }, + /* Key 7 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 80 }, + { "", 0 } + }; + + hash_test_key_t *test_key = test_keys; + + while (testcase->input != NULL && testcase->result != NULL) { + memcpy(buffer, test_key->key, test_key->len); + isc_hmacsha1_init(&hmacsha1, buffer, test_key->len); + isc_hmacsha1_update(&hmacsha1, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + isc_hmacsha1_sign(&hmacsha1, digest, ISC_SHA1_DIGESTLENGTH); + tohexstr(digest, ISC_SHA1_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + test_key++; + } +} + +/* HMAC-SHA224 test */ +ATF_TC(isc_hmacsha224); +ATF_TC_HEAD(isc_hmacsha224, tc) { + atf_tc_set_md_var(tc, "descr", "HMAC-SHA224 examples from RFC4634"); +} +ATF_TC_BODY(isc_hmacsha224, tc) { + isc_hmacsha224_t hmacsha224; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("\x48\x69\x20\x54\x68\x65\x72\x65"), + "0x896FB1128ABBDF196832107CD49DF33F47B4B1169912BA" + "4F53684B22", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("\x77\x68\x61\x74\x20\x64\x6f\x20\x79\x61" + "\x20\x77\x61\x6e\x74\x20\x66\x6f\x72\x20" + "\x6e\x6f\x74\x68\x69\x6e\x67\x3f"), + "0xA30E01098BC6DBBF45690F3A7E9E6D0F8BBEA2A39E61480" + "08FD05E44", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD"), + "0x7FB3CB3588C6C1F6FFA9694D7D6AD2649365B0C1F65D69" + "D1EC8333EA", + 1 + }, + /* Test 4 */ + { + TEST_INPUT("\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"), + "0x6C11506874013CAC6A2ABC1BB382627CEC6A90D86EFC01" + "2DE7AFEC5A", + 1 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT("Test With Truncation"), + "0x4C1A03424B55E07FE7F27BE1", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key - " + "Hash Key First"), + "0x95E9A0DB962095ADAEBE9B2D6F0DBCE2D499F112F2D2B7" + "273FA6870E", + 1 + }, + /* Test 7 */ + { + TEST_INPUT("\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20" + "\x74\x65\x73\x74\x20\x75\x73\x69\x6e\x67" + "\x20\x61\x20\x6c\x61\x72\x67\x65\x72\x20" + "\x74\x68\x61\x6e\x20\x62\x6c\x6f\x63\x6b" + "\x2d\x73\x69\x7a\x65\x20\x6b\x65\x79\x20" + "\x61\x6e\x64\x20\x61\x20\x6c\x61\x72\x67" + "\x65\x72\x20\x74\x68\x61\x6e\x20\x62\x6c" + "\x6f\x63\x6b\x2d\x73\x69\x7a\x65\x20\x64" + "\x61\x74\x61\x2e\x20\x54\x68\x65\x20\x6b" + "\x65\x79\x20\x6e\x65\x65\x64\x73\x20\x74" + "\x6f\x20\x62\x65\x20\x68\x61\x73\x68\x65" + "\x64\x20\x62\x65\x66\x6f\x72\x65\x20\x62" + "\x65\x69\x6e\x67\x20\x75\x73\x65\x64\x20" + "\x62\x79\x20\x74\x68\x65\x20\x48\x4d\x41" + "\x43\x20\x61\x6c\x67\x6f\x72\x69\x74\x68" + "\x6d\x2e"), + "0x3A854166AC5D9F023F54D517D0B39DBD946770DB9C2B95" + "C9F6F565D1", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + hash_test_key_t test_keys[] = { + /* Key 1 */ + { "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b" + "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b", 20 }, + /* Key 2 */ + { "Jefe", 4 }, + /* Key 3 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 20 }, + /* Key 4 */ + { "\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a" + "\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14" + "\x15\x16\x17\x18\x19", 25 }, +#if 0 + /* Key 5 */ + { "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c" + "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c", 20 }, +#endif + /* Key 6 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + /* Key 7 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + { "", 0 } + }; + + hash_test_key_t *test_key = test_keys; + + while (testcase->input != NULL && testcase->result != NULL) { + memcpy(buffer, test_key->key, test_key->len); + isc_hmacsha224_init(&hmacsha224, buffer, test_key->len); + isc_hmacsha224_update(&hmacsha224, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + isc_hmacsha224_sign(&hmacsha224, digest, ISC_SHA224_DIGESTLENGTH); + tohexstr(digest, ISC_SHA224_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + test_key++; + } +} + +/* HMAC-SHA256 test */ +ATF_TC(isc_hmacsha256); +ATF_TC_HEAD(isc_hmacsha256, tc) { + atf_tc_set_md_var(tc, "descr", "HMAC-SHA256 examples from RFC4634"); +} +ATF_TC_BODY(isc_hmacsha256, tc) { + isc_hmacsha256_t hmacsha256; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("\x48\x69\x20\x54\x68\x65\x72\x65"), + "0xB0344C61D8DB38535CA8AFCEAF0BF12B881DC200C9833D" + "A726E9376C2E32CFF7", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("\x77\x68\x61\x74\x20\x64\x6f\x20\x79\x61" + "\x20\x77\x61\x6e\x74\x20\x66\x6f\x72\x20" + "\x6e\x6f\x74\x68\x69\x6e\x67\x3f"), + "0x5BDCC146BF60754E6A042426089575C75A003F089D2739" + "839DEC58B964EC3843", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD"), + "0x773EA91E36800E46854DB8EBD09181A72959098B3EF8C1" + "22D9635514CED565FE", + 1 + }, + /* Test 4 */ + { + TEST_INPUT("\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"), + "0x82558A389A443C0EA4CC819899F2083A85F0FAA3E578F8" + "077A2E3FF46729665B", + 1 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT("Test With Truncation"), + "0x4C1A03424B55E07FE7F27BE1", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key - " + "Hash Key First"), + "0x60E431591EE0B67F0D8A26AACBF5B77F8E0BC6213728C5" + "140546040F0EE37F54", + 1 + }, + /* Test 7 */ + { + TEST_INPUT("\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20" + "\x74\x65\x73\x74\x20\x75\x73\x69\x6e\x67" + "\x20\x61\x20\x6c\x61\x72\x67\x65\x72\x20" + "\x74\x68\x61\x6e\x20\x62\x6c\x6f\x63\x6b" + "\x2d\x73\x69\x7a\x65\x20\x6b\x65\x79\x20" + "\x61\x6e\x64\x20\x61\x20\x6c\x61\x72\x67" + "\x65\x72\x20\x74\x68\x61\x6e\x20\x62\x6c" + "\x6f\x63\x6b\x2d\x73\x69\x7a\x65\x20\x64" + "\x61\x74\x61\x2e\x20\x54\x68\x65\x20\x6b" + "\x65\x79\x20\x6e\x65\x65\x64\x73\x20\x74" + "\x6f\x20\x62\x65\x20\x68\x61\x73\x68\x65" + "\x64\x20\x62\x65\x66\x6f\x72\x65\x20\x62" + "\x65\x69\x6e\x67\x20\x75\x73\x65\x64\x20" + "\x62\x79\x20\x74\x68\x65\x20\x48\x4d\x41" + "\x43\x20\x61\x6c\x67\x6f\x72\x69\x74\x68" + "\x6d\x2e"), + "0x9B09FFA71B942FCB27635FBCD5B0E944BFDC63644F0713" + "938A7F51535C3A35E2", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + hash_test_key_t test_keys[] = { + /* Key 1 */ + { "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b" + "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b", 20 }, + /* Key 2 */ + { "Jefe", 4 }, + /* Key 3 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 20 }, + /* Key 4 */ + { "\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a" + "\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14" + "\x15\x16\x17\x18\x19", 25 }, +#if 0 + /* Key 5 */ + { "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c" + "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c", 20 }, +#endif + /* Key 6 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + /* Key 7 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + { "", 0 } + }; + + hash_test_key_t *test_key = test_keys; + + while (testcase->input != NULL && testcase->result != NULL) { + memcpy(buffer, test_key->key, test_key->len); + isc_hmacsha256_init(&hmacsha256, buffer, test_key->len); + isc_hmacsha256_update(&hmacsha256, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + isc_hmacsha256_sign(&hmacsha256, digest, ISC_SHA256_DIGESTLENGTH); + tohexstr(digest, ISC_SHA256_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + test_key++; + } +} + +/* HMAC-SHA384 test */ +ATF_TC(isc_hmacsha384); +ATF_TC_HEAD(isc_hmacsha384, tc) { + atf_tc_set_md_var(tc, "descr", "HMAC-SHA384 examples from RFC4634"); +} +ATF_TC_BODY(isc_hmacsha384, tc) { + isc_hmacsha384_t hmacsha384; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("\x48\x69\x20\x54\x68\x65\x72\x65"), + "0xAFD03944D84895626B0825F4AB46907F15F9DADBE4101E" + "C682AA034C7CEBC59CFAEA9EA9076EDE7F4AF152" + "E8B2FA9CB6", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("\x77\x68\x61\x74\x20\x64\x6f\x20\x79\x61" + "\x20\x77\x61\x6e\x74\x20\x66\x6f\x72\x20" + "\x6e\x6f\x74\x68\x69\x6e\x67\x3f"), + "0xAF45D2E376484031617F78D2B58A6B1B9C7EF464F5A01B" + "47E42EC3736322445E8E2240CA5E69E2C78B3239" + "ECFAB21649", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD"), + "0x88062608D3E6AD8A0AA2ACE014C8A86F0AA635D947AC9F" + "EBE83EF4E55966144B2A5AB39DC13814B94E3AB6" + "E101A34F27", + 1 + }, + /* Test 4 */ + { + TEST_INPUT("\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"), + "0x3E8A69B7783C25851933AB6290AF6CA77A998148085000" + "9CC5577C6E1F573B4E6801DD23C4A7D679CCF8A3" + "86C674CFFB", + 1 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT("Test With Truncation"), + "0x4C1A03424B55E07FE7F27BE1", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key - " + "Hash Key First"), + "0x4ECE084485813E9088D2C63A041BC5B44F9EF1012A2B58" + "8F3CD11F05033AC4C60C2EF6AB4030FE8296248D" + "F163F44952", + 1 + }, + /* Test 7 */ + { + TEST_INPUT("\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20" + "\x74\x65\x73\x74\x20\x75\x73\x69\x6e\x67" + "\x20\x61\x20\x6c\x61\x72\x67\x65\x72\x20" + "\x74\x68\x61\x6e\x20\x62\x6c\x6f\x63\x6b" + "\x2d\x73\x69\x7a\x65\x20\x6b\x65\x79\x20" + "\x61\x6e\x64\x20\x61\x20\x6c\x61\x72\x67" + "\x65\x72\x20\x74\x68\x61\x6e\x20\x62\x6c" + "\x6f\x63\x6b\x2d\x73\x69\x7a\x65\x20\x64" + "\x61\x74\x61\x2e\x20\x54\x68\x65\x20\x6b" + "\x65\x79\x20\x6e\x65\x65\x64\x73\x20\x74" + "\x6f\x20\x62\x65\x20\x68\x61\x73\x68\x65" + "\x64\x20\x62\x65\x66\x6f\x72\x65\x20\x62" + "\x65\x69\x6e\x67\x20\x75\x73\x65\x64\x20" + "\x62\x79\x20\x74\x68\x65\x20\x48\x4d\x41" + "\x43\x20\x61\x6c\x67\x6f\x72\x69\x74\x68" + "\x6d\x2e"), + "0x6617178E941F020D351E2F254E8FD32C602420FEB0B8FB" + "9ADCCEBB82461E99C5A678CC31E799176D3860E6" + "110C46523E", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + hash_test_key_t test_keys[] = { + /* Key 1 */ + { "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b" + "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b", 20 }, + /* Key 2 */ + { "Jefe", 4 }, + /* Key 3 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 20 }, + /* Key 4 */ + { "\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a" + "\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14" + "\x15\x16\x17\x18\x19", 25 }, +#if 0 + /* Key 5 */ + { "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c" + "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c", 20 }, +#endif + /* Key 6 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + /* Key 7 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + { "", 0 } + }; + + hash_test_key_t *test_key = test_keys; + + while (testcase->input != NULL && testcase->result != NULL) { + memcpy(buffer, test_key->key, test_key->len); + isc_hmacsha384_init(&hmacsha384, buffer, test_key->len); + isc_hmacsha384_update(&hmacsha384, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + isc_hmacsha384_sign(&hmacsha384, digest, ISC_SHA384_DIGESTLENGTH); + tohexstr(digest, ISC_SHA384_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + test_key++; + } +} + +/* HMAC-SHA512 test */ +ATF_TC(isc_hmacsha512); +ATF_TC_HEAD(isc_hmacsha512, tc) { + atf_tc_set_md_var(tc, "descr", "HMAC-SHA512 examples from RFC4634"); +} +ATF_TC_BODY(isc_hmacsha512, tc) { + isc_hmacsha512_t hmacsha512; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("\x48\x69\x20\x54\x68\x65\x72\x65"), + "0x87AA7CDEA5EF619D4FF0B4241A1D6CB02379F4E2CE4EC2" + "787AD0B30545E17CDEDAA833B7D6B8A702038B27" + "4EAEA3F4E4BE9D914EEB61F1702E696C203A126854", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("\x77\x68\x61\x74\x20\x64\x6f\x20\x79\x61" + "\x20\x77\x61\x6e\x74\x20\x66\x6f\x72\x20" + "\x6e\x6f\x74\x68\x69\x6e\x67\x3f"), + "0x164B7A7BFCF819E2E395FBE73B56E0A387BD64222E831F" + "D610270CD7EA2505549758BF75C05A994A6D034F" + "65F8F0E6FDCAEAB1A34D4A6B4B636E070A38BCE737", + 1 + }, + /* Test 3 */ + { + TEST_INPUT("\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD"), + "0xFA73B0089D56A284EFB0F0756C890BE9B1B5DBDD8EE81A" + "3655F83E33B2279D39BF3E848279A722C806B485" + "A47E67C807B946A337BEE8942674278859E13292FB", + 1 + }, + /* Test 4 */ + { + TEST_INPUT("\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"), + "0xB0BA465637458C6990E5A8C5F61D4AF7E576D97FF94B87" + "2DE76F8050361EE3DBA91CA5C11AA25EB4D67927" + "5CC5788063A5F19741120C4F2DE2ADEBEB10A298DD", + 1 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT("Test With Truncation"), + "0x4C1A03424B55E07FE7F27BE1", + 1 + }, +#endif + /* Test 6 */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key - " + "Hash Key First"), + "0x80B24263C7C1A3EBB71493C1DD7BE8B49B46D1F41B4AEE" + "C1121B013783F8F3526B56D037E05F2598BD0FD2" + "215D6A1E5295E64F73F63F0AEC8B915A985D786598", + 1 + }, + /* Test 7 */ + { + TEST_INPUT("\x54\x68\x69\x73\x20\x69\x73\x20\x61\x20" + "\x74\x65\x73\x74\x20\x75\x73\x69\x6e\x67" + "\x20\x61\x20\x6c\x61\x72\x67\x65\x72\x20" + "\x74\x68\x61\x6e\x20\x62\x6c\x6f\x63\x6b" + "\x2d\x73\x69\x7a\x65\x20\x6b\x65\x79\x20" + "\x61\x6e\x64\x20\x61\x20\x6c\x61\x72\x67" + "\x65\x72\x20\x74\x68\x61\x6e\x20\x62\x6c" + "\x6f\x63\x6b\x2d\x73\x69\x7a\x65\x20\x64" + "\x61\x74\x61\x2e\x20\x54\x68\x65\x20\x6b" + "\x65\x79\x20\x6e\x65\x65\x64\x73\x20\x74" + "\x6f\x20\x62\x65\x20\x68\x61\x73\x68\x65" + "\x64\x20\x62\x65\x66\x6f\x72\x65\x20\x62" + "\x65\x69\x6e\x67\x20\x75\x73\x65\x64\x20" + "\x62\x79\x20\x74\x68\x65\x20\x48\x4d\x41" + "\x43\x20\x61\x6c\x67\x6f\x72\x69\x74\x68" + "\x6d\x2e"), + "0xE37B6A775DC87DBAA4DFA9F96E5E3FFDDEBD71F8867289" + "865DF5A32D20CDC944B6022CAC3C4982B10D5EEB" + "55C3E4DE15134676FB6DE0446065C97440FA8C6A58", + 1 + }, + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + hash_test_key_t test_keys[] = { + /* Key 1 */ + { "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b" + "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b", 20 }, + /* Key 2 */ + { "Jefe", 4 }, + /* Key 3 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 20 }, + /* Key 4 */ + { "\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a" + "\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14" + "\x15\x16\x17\x18\x19", 25 }, +#if 0 + /* Key 5 */ + { "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c" + "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c", 20 }, +#endif + /* Key 6 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + /* Key 7 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + { "", 0 } + }; + + hash_test_key_t *test_key = test_keys; + + while (testcase->input != NULL && testcase->result != NULL) { + memcpy(buffer, test_key->key, test_key->len); + isc_hmacsha512_init(&hmacsha512, buffer, test_key->len); + isc_hmacsha512_update(&hmacsha512, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + isc_hmacsha512_sign(&hmacsha512, digest, ISC_SHA512_DIGESTLENGTH); + tohexstr(digest, ISC_SHA512_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + test_key++; + } +} + + +/* HMAC-MD5 Test */ +ATF_TC(isc_hmacmd5); +ATF_TC_HEAD(isc_hmacmd5, tc) { + atf_tc_set_md_var(tc, "descr", "HMAC-MD5 examples from RFC2104"); +} +ATF_TC_BODY(isc_hmacmd5, tc) { + isc_hmacmd5_t hmacmd5; + + UNUSED(tc); + + /* + * These are the various test vectors. All of these are passed + * through the hash function and the results are compared to the + * result specified here. + */ + hash_testcase_t testcases[] = { + /* Test 1 */ + { + TEST_INPUT("\x48\x69\x20\x54\x68\x65\x72\x65"), + "0x9294727A3638BB1C13F48EF8158BFC9D", + 1 + }, + /* Test 2 */ + { + TEST_INPUT("\x77\x68\x61\x74\x20\x64\x6f\x20\x79" + "\x61\x20\x77\x61\x6e\x74\x20\x66\x6f" + "\x72\x20\x6e\x6f\x74\x68\x69\x6e\x67\x3f"), + "0x750C783E6AB0B503EAA86E310A5DB738", 1 + }, + /* Test 3 */ + { + TEST_INPUT("\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD" + "\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD\xDD"), + "0x56BE34521D144C88DBB8C733F0E8B3F6", + 1 + }, + /* Test 4 */ + { + TEST_INPUT("\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd" + "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"), + "0x697EAF0ACA3A3AEA3A75164746FFAA79", + 1 + }, +#if 0 + /* Test 5 -- unimplemented optional functionality */ + { + TEST_INPUT("Test With Truncation"), + "0x4C1A03424B55E07FE7F27BE1", + 1 + }, + /* Test 6 -- unimplemented optional functionality */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key - " + "Hash Key First"), + "0xAA4AE5E15272D00E95705637CE8A3B55ED402112", + 1 + }, + /* Test 7 -- unimplemented optional functionality */ + { + TEST_INPUT("Test Using Larger Than Block-Size Key and " + "Larger Than One Block-Size Data"), + "0xE8E99D0F45237D786D6BBAA7965C7808BBFF1A91", + 1 + }, +#endif + { NULL, 0, NULL, 1 } + }; + + hash_testcase_t *testcase = testcases; + + hash_test_key_t test_keys[] = { + /* Key 1 */ + { "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b" + "\x0b\x0b\x0b\x0b\x0b\x0b", 16 }, + /* Key 2 */ + { "Jefe", 4 }, + /* Key 3 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa", 16 }, + /* Key 4 */ + { "\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a" + "\x0b\x0c\x0d\x0e\x0f\x10\x11\x12\x13\x14" + "\x15\x16\x17\x18\x19", 25 }, +#if 0 + /* Key 5 */ + { "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c" + "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c", 20 }, + /* Key 6 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, + /* Key 7 */ + { "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa" + "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa", 131 }, +#endif + { "", 0 } + }; + + hash_test_key_t *test_key = test_keys; + + while (testcase->input != NULL && testcase->result != NULL) { + memcpy(buffer, test_key->key, test_key->len); + isc_hmacmd5_init(&hmacmd5, buffer, test_key->len); + isc_hmacmd5_update(&hmacmd5, + (const isc_uint8_t *) testcase->input, + testcase->input_len); + isc_hmacmd5_sign(&hmacmd5, digest); + tohexstr(digest, ISC_MD5_DIGESTLENGTH, str); + ATF_CHECK_STREQ(str, testcase->result); + + testcase++; + test_key++; + } +} + +/* + * Main + */ +ATF_TP_ADD_TCS(tp) { + ATF_TP_ADD_TC(tp, isc_hmacmd5); + ATF_TP_ADD_TC(tp, isc_hmacsha1); + ATF_TP_ADD_TC(tp, isc_hmacsha224); + ATF_TP_ADD_TC(tp, isc_hmacsha256); + ATF_TP_ADD_TC(tp, isc_hmacsha384); + ATF_TP_ADD_TC(tp, isc_hmacsha512); + ATF_TP_ADD_TC(tp, isc_md5); + ATF_TP_ADD_TC(tp, isc_sha1); + ATF_TP_ADD_TC(tp, isc_sha224); + ATF_TP_ADD_TC(tp, isc_sha256); + ATF_TP_ADD_TC(tp, isc_sha384); + ATF_TP_ADD_TC(tp, isc_sha512); + return (atf_no_error()); +} + diff --git a/contrib/ntp/lib/isc/tests/isctest.c b/contrib/ntp/lib/isc/tests/isctest.c new file mode 100644 index 000000000..e118bbf2a --- /dev/null +++ b/contrib/ntp/lib/isc/tests/isctest.c @@ -0,0 +1,178 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "isctest.h" + +isc_mem_t *mctx = NULL; +isc_entropy_t *ectx = NULL; +isc_log_t *lctx = NULL; +isc_taskmgr_t *taskmgr = NULL; +isc_timermgr_t *timermgr = NULL; +isc_socketmgr_t *socketmgr = NULL; +int ncpus; + +static isc_boolean_t hash_active = ISC_FALSE; + +/* + * Logging categories: this needs to match the list in bin/named/log.c. + */ +static isc_logcategory_t categories[] = { + { "", 0 }, + { "client", 0 }, + { "network", 0 }, + { "update", 0 }, + { "queries", 0 }, + { "unmatched", 0 }, + { "update-security", 0 }, + { "query-errors", 0 }, + { NULL, 0 } +}; + +static void +cleanup_managers() { + if (socketmgr != NULL) + isc_socketmgr_destroy(&socketmgr); + if (taskmgr != NULL) + isc_taskmgr_destroy(&taskmgr); + if (timermgr != NULL) + isc_timermgr_destroy(&timermgr); +} + +static isc_result_t +create_managers() { + isc_result_t result; +#ifdef ISC_PLATFORM_USETHREADS + ncpus = isc_os_ncpus(); +#else + ncpus = 1; +#endif + + CHECK(isc_taskmgr_create(mctx, ncpus, 0, &taskmgr)); + CHECK(isc_timermgr_create(mctx, &timermgr)); + CHECK(isc_socketmgr_create(mctx, &socketmgr)); + return (ISC_R_SUCCESS); + + cleanup: + cleanup_managers(); + return (result); +} + +isc_result_t +isc_test_begin(FILE *logfile, isc_boolean_t start_managers) { + isc_result_t result; + + isc_mem_debugging |= ISC_MEM_DEBUGRECORD; + CHECK(isc_mem_create(0, 0, &mctx)); + CHECK(isc_entropy_create(mctx, &ectx)); + + CHECK(isc_hash_create(mctx, ectx, 255)); + hash_active = ISC_TRUE; + + if (logfile != NULL) { + isc_logdestination_t destination; + isc_logconfig_t *logconfig = NULL; + + CHECK(isc_log_create(mctx, &lctx, &logconfig)); + isc_log_registercategories(lctx, categories); + isc_log_setcontext(lctx); + + destination.file.stream = logfile; + destination.file.name = NULL; + destination.file.versions = ISC_LOG_ROLLNEVER; + destination.file.maximum_size = 0; + CHECK(isc_log_createchannel(logconfig, "stderr", + ISC_LOG_TOFILEDESC, + ISC_LOG_DYNAMIC, + &destination, 0)); + CHECK(isc_log_usechannel(logconfig, "stderr", NULL, NULL)); + } + +#ifdef ISC_PLATFORM_USETHREADS + ncpus = isc_os_ncpus(); +#else + ncpus = 1; +#endif + + if (start_managers) + CHECK(create_managers()); + + return (ISC_R_SUCCESS); + + cleanup: + isc_test_end(); + return (result); +} + +void +isc_test_end() { + if (taskmgr != NULL) + isc_taskmgr_destroy(&taskmgr); + if (lctx != NULL) + isc_log_destroy(&lctx); + if (hash_active) { + isc_hash_destroy(); + hash_active = ISC_FALSE; + } + if (ectx != NULL) + isc_entropy_detach(&ectx); + + cleanup_managers(); + + if (mctx != NULL) + isc_mem_destroy(&mctx); +} + +/* + * Sleep for 'usec' microseconds. + */ +void +isc_test_nap(isc_uint32_t usec) { +#ifdef HAVE_NANOSLEEP + struct timespec ts; + + ts.tv_sec = usec / 1000000; + ts.tv_nsec = (usec % 1000000) * 1000; + nanosleep(&ts, NULL); +#elif HAVE_USLEEP + usleep(usec); +#else + /* + * No fractional-second sleep function is available, so we + * round up to the nearest second and sleep instead + */ + sleep((usec / 1000000) + 1); +#endif +} diff --git a/contrib/ntp/lib/isc/tests/isctest.h b/contrib/ntp/lib/isc/tests/isctest.h new file mode 100644 index 000000000..03423c807 --- /dev/null +++ b/contrib/ntp/lib/isc/tests/isctest.h @@ -0,0 +1,57 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define CHECK(r) \ + do { \ + result = (r); \ + if (result != ISC_R_SUCCESS) \ + goto cleanup; \ + } while (0) + +extern isc_mem_t *mctx; +extern isc_entropy_t *ectx; +extern isc_log_t *lctx; +extern isc_taskmgr_t *taskmgr; +isc_timermgr_t *timermgr; +isc_socketmgr_t *socketmgr; +extern int ncpus; + +isc_result_t +isc_test_begin(FILE *logfile, isc_boolean_t start_managers); + +void +isc_test_end(void); + +void +isc_test_nap(isc_uint32_t usec); diff --git a/contrib/ntp/lib/isc/tests/queue_test.c b/contrib/ntp/lib/isc/tests/queue_test.c new file mode 100644 index 000000000..74620fef4 --- /dev/null +++ b/contrib/ntp/lib/isc/tests/queue_test.c @@ -0,0 +1,144 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include +#include + +#include + +#include "isctest.h" + +typedef struct item { + int value; + ISC_QLINK(item_t) qlink; +} item_t; + +typedef ISC_QUEUE(item_t) item_queue_t; + +static void +item_init(item_t *item, int value) { + item->value = value; + ISC_QLINK_INIT(item, qlink); +} + +/* + * Individual unit tests + */ + +/* Test UDP sendto/recv (IPv4) */ +ATF_TC(queue_valid); +ATF_TC_HEAD(queue_valid, tc) { + atf_tc_set_md_var(tc, "descr", "Check queue validity"); +} +ATF_TC_BODY(queue_valid, tc) { + isc_result_t result; + item_queue_t queue; + item_t one, two, three, four, five; + item_t *p; + + UNUSED(tc); + + ISC_QUEUE_INIT(queue, qlink); + + item_init(&one, 1); + item_init(&two, 2); + item_init(&three, 3); + item_init(&four, 4); + item_init(&five, 5); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + ATF_CHECK(ISC_QUEUE_EMPTY(queue)); + + ISC_QUEUE_POP(queue, qlink, p); + ATF_CHECK(p == NULL); + + ATF_CHECK(! ISC_QLINK_LINKED(&one, qlink)); + ISC_QUEUE_PUSH(queue, &one, qlink); + ATF_CHECK(ISC_QLINK_LINKED(&one, qlink)); + + ATF_CHECK(! ISC_QUEUE_EMPTY(queue)); + + ISC_QUEUE_POP(queue, qlink, p); + ATF_REQUIRE(p != NULL); + ATF_CHECK_EQ(p->value, 1); + ATF_CHECK(ISC_QUEUE_EMPTY(queue)); + ATF_CHECK(! ISC_QLINK_LINKED(p, qlink)); + + ISC_QUEUE_PUSH(queue, p, qlink); + ATF_CHECK(! ISC_QUEUE_EMPTY(queue)); + ATF_CHECK(ISC_QLINK_LINKED(p, qlink)); + + ATF_CHECK(! ISC_QLINK_LINKED(&two, qlink)); + ISC_QUEUE_PUSH(queue, &two, qlink); + ATF_CHECK(ISC_QLINK_LINKED(&two, qlink)); + + ATF_CHECK(! ISC_QLINK_LINKED(&three, qlink)); + ISC_QUEUE_PUSH(queue, &three, qlink); + ATF_CHECK(ISC_QLINK_LINKED(&three, qlink)); + + ATF_CHECK(! ISC_QLINK_LINKED(&four, qlink)); + ISC_QUEUE_PUSH(queue, &four, qlink); + ATF_CHECK(ISC_QLINK_LINKED(&four, qlink)); + + ATF_CHECK(! ISC_QLINK_LINKED(&five, qlink)); + ISC_QUEUE_PUSH(queue, &five, qlink); + ATF_CHECK(ISC_QLINK_LINKED(&five, qlink)); + + ISC_QUEUE_POP(queue, qlink, p); + ATF_REQUIRE(p != NULL); + ATF_CHECK_EQ(p->value, 1); + + ISC_QUEUE_POP(queue, qlink, p); + ATF_REQUIRE(p != NULL); + ATF_CHECK_EQ(p->value, 2); + + ISC_QUEUE_POP(queue, qlink, p); + ATF_REQUIRE(p != NULL); + ATF_CHECK_EQ(p->value, 3); + + ISC_QUEUE_POP(queue, qlink, p); + ATF_REQUIRE(p != NULL); + ATF_CHECK_EQ(p->value, 4); + + ISC_QUEUE_POP(queue, qlink, p); + ATF_REQUIRE(p != NULL); + ATF_CHECK_EQ(p->value, 5); + + ATF_CHECK(ISC_QUEUE_EMPTY(queue)); + + ISC_QUEUE_DESTROY(queue); + isc_test_end(); +} + +/* + * Main + */ +ATF_TP_ADD_TCS(tp) { + ATF_TP_ADD_TC(tp, queue_valid); + + return (atf_no_error()); +} + diff --git a/contrib/ntp/lib/isc/tests/socket_test.c b/contrib/ntp/lib/isc/tests/socket_test.c new file mode 100644 index 000000000..724d79df2 --- /dev/null +++ b/contrib/ntp/lib/isc/tests/socket_test.c @@ -0,0 +1,255 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include +#include + +#include + +#include "../task_p.h" +#include "isctest.h" + +/* + * Helper functions + */ +typedef struct { + isc_boolean_t done; + isc_result_t result; +} completion_t; + +static void +completion_init(completion_t *completion) { + completion->done = ISC_FALSE; +} + +static void +event_done(isc_task_t *task, isc_event_t *event) { + isc_socketevent_t *dev; + completion_t *completion = event->ev_arg; + + UNUSED(task); + + dev = (isc_socketevent_t *) event; + completion->result = dev->result; + completion->done = ISC_TRUE; + isc_event_free(&event); +} + +static isc_result_t +waitfor(completion_t *completion) { + int i = 0; + while (!completion->done && i++ < 5000) { +#ifndef ISC_PLATFORM_USETHREADS + while (isc__taskmgr_ready(taskmgr)) + isc__taskmgr_dispatch(taskmgr); +#endif + isc_test_nap(1000); + } + if (completion->done) + return (ISC_R_SUCCESS); + return (ISC_R_FAILURE); +} + +/* + * Individual unit tests + */ + +/* Test UDP sendto/recv (IPv4) */ +ATF_TC(udp_sendto); +ATF_TC_HEAD(udp_sendto, tc) { + atf_tc_set_md_var(tc, "descr", "UDP sendto/recv"); +} +ATF_TC_BODY(udp_sendto, tc) { + isc_result_t result; + isc_sockaddr_t addr1, addr2; + struct in_addr in; + isc_socket_t *s1 = NULL, *s2 = NULL; + isc_task_t *task = NULL; + char sendbuf[BUFSIZ], recvbuf[BUFSIZ]; + completion_t completion; + isc_region_t r; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + /* + * Create two sockets: 127.0.0.1/5444 and 127.0.0.1/5445, talking to + * each other. + */ + in.s_addr = inet_addr("127.0.0.1"); + isc_sockaddr_fromin(&addr1, &in, 5444); + isc_sockaddr_fromin(&addr2, &in, 5445); + + result = isc_socket_create(socketmgr, PF_INET, isc_sockettype_udp, &s1); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + result = isc_socket_bind(s1, &addr1, ISC_SOCKET_REUSEADDRESS); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_socket_create(socketmgr, PF_INET, isc_sockettype_udp, &s2); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + result = isc_socket_bind(s2, &addr2, ISC_SOCKET_REUSEADDRESS); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_task_create(taskmgr, 0, &task); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + strcpy(sendbuf, "Hello"); + r.base = (void *) sendbuf; + r.length = strlen(sendbuf) + 1; + + completion_init(&completion); + result = isc_socket_sendto(s1, &r, task, event_done, &completion, + &addr2, NULL); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + waitfor(&completion); + ATF_CHECK(completion.done); + ATF_CHECK_EQ(completion.result, ISC_R_SUCCESS); + + r.base = (void *) recvbuf; + r.length = BUFSIZ; + completion_init(&completion); + result = isc_socket_recv(s2, &r, 1, task, event_done, &completion); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + waitfor(&completion); + ATF_CHECK(completion.done); + ATF_CHECK_EQ(completion.result, ISC_R_SUCCESS); + ATF_CHECK_STREQ(recvbuf, "Hello"); + + isc_task_detach(&task); + + isc_socket_detach(&s1); + isc_socket_detach(&s2); + + isc_test_end(); +} + +/* Test UDP sendto/recv with duplicated socket */ +ATF_TC(udp_dup); +ATF_TC_HEAD(udp_dup, tc) { + atf_tc_set_md_var(tc, "descr", "duplicated socket sendto/recv"); +} +ATF_TC_BODY(udp_dup, tc) { + isc_result_t result; + isc_sockaddr_t addr1, addr2; + struct in_addr in; + isc_socket_t *s1 = NULL, *s2 = NULL, *s3 = NULL; + isc_task_t *task = NULL; + char sendbuf[BUFSIZ], recvbuf[BUFSIZ]; + completion_t completion; + isc_region_t r; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + /* + * Create two sockets: 127.0.0.1/5444 and 127.0.0.1/5445, talking to + * each other. + */ + in.s_addr = inet_addr("127.0.0.1"); + isc_sockaddr_fromin(&addr1, &in, 5444); + isc_sockaddr_fromin(&addr2, &in, 5445); + + result = isc_socket_create(socketmgr, PF_INET, isc_sockettype_udp, &s1); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + result = isc_socket_bind(s1, &addr1, ISC_SOCKET_REUSEADDRESS); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_socket_create(socketmgr, PF_INET, isc_sockettype_udp, &s2); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + result = isc_socket_bind(s2, &addr2, ISC_SOCKET_REUSEADDRESS); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_socket_dup(s2, &s3); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_task_create(taskmgr, 0, &task); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + strcpy(sendbuf, "Hello"); + r.base = (void *) sendbuf; + r.length = strlen(sendbuf) + 1; + + completion_init(&completion); + result = isc_socket_sendto(s1, &r, task, event_done, &completion, + &addr2, NULL); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + waitfor(&completion); + ATF_CHECK(completion.done); + ATF_CHECK_EQ(completion.result, ISC_R_SUCCESS); + + strcpy(sendbuf, "World"); + r.base = (void *) sendbuf; + r.length = strlen(sendbuf) + 1; + + completion_init(&completion); + result = isc_socket_sendto(s1, &r, task, event_done, &completion, + &addr2, NULL); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + waitfor(&completion); + ATF_CHECK(completion.done); + ATF_CHECK_EQ(completion.result, ISC_R_SUCCESS); + + r.base = (void *) recvbuf; + r.length = BUFSIZ; + completion_init(&completion); + result = isc_socket_recv(s2, &r, 1, task, event_done, &completion); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + waitfor(&completion); + ATF_CHECK(completion.done); + ATF_CHECK_EQ(completion.result, ISC_R_SUCCESS); + ATF_CHECK_STREQ(recvbuf, "Hello"); + + r.base = (void *) recvbuf; + r.length = BUFSIZ; + completion_init(&completion); + result = isc_socket_recv(s3, &r, 1, task, event_done, &completion); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + waitfor(&completion); + ATF_CHECK(completion.done); + ATF_CHECK_EQ(completion.result, ISC_R_SUCCESS); + ATF_CHECK_STREQ(recvbuf, "World"); + + isc_task_detach(&task); + + isc_socket_detach(&s1); + isc_socket_detach(&s2); + isc_socket_detach(&s3); + + isc_test_end(); +} + +/* + * Main + */ +ATF_TP_ADD_TCS(tp) { + ATF_TP_ADD_TC(tp, udp_sendto); + ATF_TP_ADD_TC(tp, udp_dup); + + return (atf_no_error()); +} + diff --git a/contrib/ntp/lib/isc/tests/symtab_test.c b/contrib/ntp/lib/isc/tests/symtab_test.c new file mode 100644 index 000000000..21444b4c4 --- /dev/null +++ b/contrib/ntp/lib/isc/tests/symtab_test.c @@ -0,0 +1,147 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include + +#include +#include + +#include "isctest.h" + +static void +undefine(char *key, unsigned int type, isc_symvalue_t value, void *arg) { + UNUSED(arg); + + ATF_REQUIRE_EQ(type, 1); + isc_mem_free(mctx, key); + isc_mem_free(mctx, value.as_pointer); +} + +/* + * Individual unit tests + */ + +ATF_TC(symtab_grow); +ATF_TC_HEAD(symtab_grow, tc) { + atf_tc_set_md_var(tc, "descr", "symbol table growth"); +} +ATF_TC_BODY(symtab_grow, tc) { + isc_result_t result; + isc_symtab_t *st = NULL; + isc_symvalue_t value; + isc_symexists_t policy = isc_symexists_reject; + int i; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_symtab_create(mctx, 3, undefine, NULL, ISC_FALSE, &st); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE(st != NULL); + + /* Nothing should be in the table yet */ + + /* + * Put 1024 entries in the table (this should necessate + * regrowing the hash table several times + */ + for (i = 0; i < 1024; i++) { + char str[16], *key; + + snprintf(str, sizeof(str), "%04x", i); + key = isc_mem_strdup(mctx, str); + ATF_REQUIRE(key != NULL); + value.as_pointer = isc_mem_strdup(mctx, str); + ATF_REQUIRE(value.as_pointer != NULL); + result = isc_symtab_define(st, key, 1, value, policy); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + if (result != ISC_R_SUCCESS) + undefine(key, 1, value, NULL); + } + + /* + * Try to put them in again; this should fail + */ + for (i = 0; i < 1024; i++) { + char str[16], *key; + + snprintf(str, sizeof(str), "%04x", i); + key = isc_mem_strdup(mctx, str); + ATF_REQUIRE(key != NULL); + value.as_pointer = isc_mem_strdup(mctx, str); + ATF_REQUIRE(value.as_pointer != NULL); + result = isc_symtab_define(st, key, 1, value, policy); + ATF_CHECK_EQ(result, ISC_R_EXISTS); + undefine(key, 1, value, NULL); + } + + /* + * Retrieve them; this should succeed + */ + for (i = 0; i < 1024; i++) { + char str[16]; + + snprintf(str, sizeof(str), "%04x", i); + result = isc_symtab_lookup(st, str, 0, &value); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + ATF_CHECK_STREQ(str, value.as_pointer); + } + + /* + * Undefine them + */ + for (i = 0; i < 1024; i++) { + char str[16]; + + snprintf(str, sizeof(str), "%04x", i); + result = isc_symtab_undefine(st, str, 1); + ATF_CHECK_EQ(result, ISC_R_SUCCESS); + } + + /* + * Retrieve them again; this should fail + */ + for (i = 0; i < 1024; i++) { + char str[16]; + + snprintf(str, sizeof(str), "%04x", i); + result = isc_symtab_lookup(st, str, 0, &value); + ATF_CHECK_EQ(result, ISC_R_NOTFOUND); + } + + isc_symtab_destroy(&st); + isc_test_end(); +} + +/* + * Main + */ +ATF_TP_ADD_TCS(tp) { + ATF_TP_ADD_TC(tp, symtab_grow); + + return (atf_no_error()); +} + diff --git a/contrib/ntp/lib/isc/tests/task_test.c b/contrib/ntp/lib/isc/tests/task_test.c new file mode 100644 index 000000000..7294d861d --- /dev/null +++ b/contrib/ntp/lib/isc/tests/task_test.c @@ -0,0 +1,416 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include + +#include +#include + +#include "../task_p.h" +#include "isctest.h" + +/* + * Helper functions + */ + +/* task event handler, sets a boolean to true */ +int counter = 0; +isc_mutex_t set_lock; + +static void +set(isc_task_t *task, isc_event_t *event) { + int *value = (int *) event->ev_arg; + + UNUSED(task); + + isc_event_free(&event); + LOCK(&set_lock); + *value = counter++; + UNLOCK(&set_lock); +} + +static void +set_and_drop(isc_task_t *task, isc_event_t *event) { + int *value = (int *) event->ev_arg; + + UNUSED(task); + + isc_event_free(&event); + LOCK(&set_lock); + *value = (int) isc_taskmgr_mode(taskmgr); + counter++; + UNLOCK(&set_lock); + isc_taskmgr_setmode(taskmgr, isc_taskmgrmode_normal); +} + +/* + * Individual unit tests + */ + +/* Create a task */ +ATF_TC(create_task); +ATF_TC_HEAD(create_task, tc) { + atf_tc_set_md_var(tc, "descr", "create and destroy a task"); +} +ATF_TC_BODY(create_task, tc) { + isc_result_t result; + isc_task_t *task = NULL; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_task_create(taskmgr, 0, &task); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + isc_task_destroy(&task); + ATF_REQUIRE_EQ(task, NULL); + + isc_test_end(); +} + +/* Process events */ +ATF_TC(all_events); +ATF_TC_HEAD(all_events, tc) { + atf_tc_set_md_var(tc, "descr", "process task events"); +} +ATF_TC_BODY(all_events, tc) { + isc_result_t result; + isc_task_t *task = NULL; + isc_event_t *event; + int a = 0, b = 0; + int i = 0; + + UNUSED(tc); + + counter = 1; + + result = isc_mutex_init(&set_lock); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_task_create(taskmgr, 0, &task); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + /* First event */ + event = isc_event_allocate(mctx, task, ISC_TASKEVENT_TEST, + set, &a, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(a, 0); + isc_task_send(task, &event); + + event = isc_event_allocate(mctx, task, ISC_TASKEVENT_TEST, + set, &b, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(b, 0); + isc_task_send(task, &event); + + while ((a == 0 || b == 0) && i++ < 5000) { +#ifndef ISC_PLATFORM_USETHREADS + while (isc__taskmgr_ready(taskmgr)) + isc__taskmgr_dispatch(taskmgr); +#endif + isc_test_nap(1000); + } + + ATF_CHECK(a != 0); + ATF_CHECK(b != 0); + + isc_task_destroy(&task); + ATF_REQUIRE_EQ(task, NULL); + + isc_test_end(); +} + +/* Privileged events */ +ATF_TC(privileged_events); +ATF_TC_HEAD(privileged_events, tc) { + atf_tc_set_md_var(tc, "descr", "process privileged events"); +} +ATF_TC_BODY(privileged_events, tc) { + isc_result_t result; + isc_task_t *task1 = NULL, *task2 = NULL; + isc_event_t *event; + int a = 0, b = 0, c = 0, d = 0, e = 0; + int i = 0; + + UNUSED(tc); + + counter = 1; + result = isc_mutex_init(&set_lock); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + +#ifdef ISC_PLATFORM_USETHREADS + /* + * Pause the task manager so we can fill up the work queue + * without things happening while we do it. + */ + isc__taskmgr_pause(taskmgr); +#endif + + result = isc_task_create(taskmgr, 0, &task1); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + isc_task_setname(task1, "privileged", NULL); + ATF_CHECK(!isc_task_privilege(task1)); + isc_task_setprivilege(task1, ISC_TRUE); + ATF_CHECK(isc_task_privilege(task1)); + + result = isc_task_create(taskmgr, 0, &task2); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + isc_task_setname(task2, "normal", NULL); + ATF_CHECK(!isc_task_privilege(task2)); + + /* First event: privileged */ + event = isc_event_allocate(mctx, task1, ISC_TASKEVENT_TEST, + set, &a, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(a, 0); + isc_task_send(task1, &event); + + /* Second event: not privileged */ + event = isc_event_allocate(mctx, task2, ISC_TASKEVENT_TEST, + set, &b, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(b, 0); + isc_task_send(task2, &event); + + /* Third event: privileged */ + event = isc_event_allocate(mctx, task1, ISC_TASKEVENT_TEST, + set, &c, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(c, 0); + isc_task_send(task1, &event); + + /* Fourth event: privileged */ + event = isc_event_allocate(mctx, task1, ISC_TASKEVENT_TEST, + set, &d, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(d, 0); + isc_task_send(task1, &event); + + /* Fifth event: not privileged */ + event = isc_event_allocate(mctx, task2, ISC_TASKEVENT_TEST, + set, &e, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(e, 0); + isc_task_send(task2, &event); + + ATF_CHECK_EQ(isc_taskmgr_mode(taskmgr), isc_taskmgrmode_normal); + isc_taskmgr_setmode(taskmgr, isc_taskmgrmode_privileged); + ATF_CHECK_EQ(isc_taskmgr_mode(taskmgr), isc_taskmgrmode_privileged); + +#ifdef ISC_PLATFORM_USETHREADS + isc__taskmgr_resume(taskmgr); +#endif + + /* We're waiting for *all* variables to be set */ + while ((a == 0 || b == 0 || c == 0 || d == 0 || e == 0) && i++ < 5000) { +#ifndef ISC_PLATFORM_USETHREADS + while (isc__taskmgr_ready(taskmgr)) + isc__taskmgr_dispatch(taskmgr); +#endif + isc_test_nap(1000); + } + + /* + * We can't guarantee what order the events fire, but + * we do know the privileged tasks that set a, c, and d + * would have fired first. + */ + ATF_CHECK(a <= 3); + ATF_CHECK(c <= 3); + ATF_CHECK(d <= 3); + + /* ...and the non-privileged tasks that set b and e, last */ + ATF_CHECK(b >= 4); + ATF_CHECK(e >= 4); + + ATF_CHECK_EQ(counter, 6); + + isc_task_setprivilege(task1, ISC_FALSE); + ATF_CHECK(!isc_task_privilege(task1)); + + ATF_CHECK_EQ(isc_taskmgr_mode(taskmgr), isc_taskmgrmode_normal); + + isc_task_destroy(&task1); + ATF_REQUIRE_EQ(task1, NULL); + isc_task_destroy(&task2); + ATF_REQUIRE_EQ(task2, NULL); + + isc_test_end(); +} + +/* + * Edge case: this tests that the task manager behaves as expected when + * we explicitly set it into normal mode *while* running privileged. + */ +ATF_TC(privilege_drop); +ATF_TC_HEAD(privilege_drop, tc) { + atf_tc_set_md_var(tc, "descr", "process privileged events"); +} +ATF_TC_BODY(privilege_drop, tc) { + isc_result_t result; + isc_task_t *task1 = NULL, *task2 = NULL; + isc_event_t *event; + int a = -1, b = -1, c = -1, d = -1, e = -1; /* non valid states */ + int i = 0; + + UNUSED(tc); + + counter = 1; + result = isc_mutex_init(&set_lock); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + +#ifdef ISC_PLATFORM_USETHREADS + /* + * Pause the task manager so we can fill up the work queue + * without things happening while we do it. + */ + isc__taskmgr_pause(taskmgr); +#endif + + result = isc_task_create(taskmgr, 0, &task1); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + isc_task_setname(task1, "privileged", NULL); + ATF_CHECK(!isc_task_privilege(task1)); + isc_task_setprivilege(task1, ISC_TRUE); + ATF_CHECK(isc_task_privilege(task1)); + + result = isc_task_create(taskmgr, 0, &task2); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + isc_task_setname(task2, "normal", NULL); + ATF_CHECK(!isc_task_privilege(task2)); + + /* First event: privileged */ + event = isc_event_allocate(mctx, task1, ISC_TASKEVENT_TEST, + set_and_drop, &a, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(a, -1); + isc_task_send(task1, &event); + + /* Second event: not privileged */ + event = isc_event_allocate(mctx, task2, ISC_TASKEVENT_TEST, + set_and_drop, &b, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(b, -1); + isc_task_send(task2, &event); + + /* Third event: privileged */ + event = isc_event_allocate(mctx, task1, ISC_TASKEVENT_TEST, + set_and_drop, &c, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(c, -1); + isc_task_send(task1, &event); + + /* Fourth event: privileged */ + event = isc_event_allocate(mctx, task1, ISC_TASKEVENT_TEST, + set_and_drop, &d, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(d, -1); + isc_task_send(task1, &event); + + /* Fifth event: not privileged */ + event = isc_event_allocate(mctx, task2, ISC_TASKEVENT_TEST, + set_and_drop, &e, sizeof (isc_event_t)); + ATF_REQUIRE(event != NULL); + + ATF_CHECK_EQ(e, -1); + isc_task_send(task2, &event); + + ATF_CHECK_EQ(isc_taskmgr_mode(taskmgr), isc_taskmgrmode_normal); + isc_taskmgr_setmode(taskmgr, isc_taskmgrmode_privileged); + ATF_CHECK_EQ(isc_taskmgr_mode(taskmgr), isc_taskmgrmode_privileged); + +#ifdef ISC_PLATFORM_USETHREADS + isc__taskmgr_resume(taskmgr); +#endif + + /* We're waiting for all variables to be set. */ + while ((a == -1 || b == -1 || c == -1 || d == -1 || e == -1) && + i++ < 5000) { +#ifndef ISC_PLATFORM_USETHREADS + while (isc__taskmgr_ready(taskmgr)) + isc__taskmgr_dispatch(taskmgr); +#endif + isc_test_nap(1000); + } + + /* + * We can't guarantee what order the events fire, but + * we do know *exactly one* of the privileged tasks will + * have run in privileged mode... + */ + ATF_CHECK(a == isc_taskmgrmode_privileged || + c == isc_taskmgrmode_privileged || + d == isc_taskmgrmode_privileged); + ATF_CHECK(a + c + d == isc_taskmgrmode_privileged); + + /* ...and neither of the non-privileged tasks did... */ + ATF_CHECK(b == isc_taskmgrmode_normal || e == isc_taskmgrmode_normal); + + /* ...but all five of them did run. */ + ATF_CHECK_EQ(counter, 6); + + ATF_CHECK_EQ(isc_taskmgr_mode(taskmgr), isc_taskmgrmode_normal); + + isc_task_destroy(&task1); + ATF_REQUIRE_EQ(task1, NULL); + isc_task_destroy(&task2); + ATF_REQUIRE_EQ(task2, NULL); + + isc_test_end(); +} + +/* + * Main + */ +ATF_TP_ADD_TCS(tp) { + ATF_TP_ADD_TC(tp, create_task); + ATF_TP_ADD_TC(tp, all_events); + ATF_TP_ADD_TC(tp, privileged_events); + ATF_TP_ADD_TC(tp, privilege_drop); + + return (atf_no_error()); +} + diff --git a/contrib/ntp/lib/isc/tests/taskpool_test.c b/contrib/ntp/lib/isc/tests/taskpool_test.c new file mode 100644 index 000000000..aecb694f2 --- /dev/null +++ b/contrib/ntp/lib/isc/tests/taskpool_test.c @@ -0,0 +1,211 @@ +/* + * Copyright (C) 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include + +#include + +#include +#include + +#include "isctest.h" + +/* + * Individual unit tests + */ + +/* Create a taskpool */ +ATF_TC(create_pool); +ATF_TC_HEAD(create_pool, tc) { + atf_tc_set_md_var(tc, "descr", "create a taskpool"); +} +ATF_TC_BODY(create_pool, tc) { + isc_result_t result; + isc_taskpool_t *pool = NULL; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_taskpool_create(taskmgr, mctx, 8, 2, &pool); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE_EQ(isc_taskpool_size(pool), 8); + + isc_taskpool_destroy(&pool); + ATF_REQUIRE_EQ(pool, NULL); + + isc_test_end(); +} + +/* Resize a taskpool */ +ATF_TC(expand_pool); +ATF_TC_HEAD(expand_pool, tc) { + atf_tc_set_md_var(tc, "descr", "expand a taskpool"); +} +ATF_TC_BODY(expand_pool, tc) { + isc_result_t result; + isc_taskpool_t *pool1 = NULL, *pool2 = NULL, *hold = NULL; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_taskpool_create(taskmgr, mctx, 10, 2, &pool1); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE_EQ(isc_taskpool_size(pool1), 10); + + /* resizing to a smaller size should have no effect */ + hold = pool1; + result = isc_taskpool_expand(&pool1, 5, &pool2); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE_EQ(isc_taskpool_size(pool2), 10); + ATF_REQUIRE_EQ(pool2, hold); + ATF_REQUIRE_EQ(pool1, NULL); + pool1 = pool2; + pool2 = NULL; + + /* resizing to the same size should have no effect */ + hold = pool1; + result = isc_taskpool_expand(&pool1, 10, &pool2); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE_EQ(isc_taskpool_size(pool2), 10); + ATF_REQUIRE_EQ(pool2, hold); + ATF_REQUIRE_EQ(pool1, NULL); + pool1 = pool2; + pool2 = NULL; + + /* resizing to larger size should make a new pool */ + hold = pool1; + result = isc_taskpool_expand(&pool1, 20, &pool2); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE_EQ(isc_taskpool_size(pool2), 20); + ATF_REQUIRE(pool2 != hold); + ATF_REQUIRE_EQ(pool1, NULL); + + isc_taskpool_destroy(&pool2); + ATF_REQUIRE_EQ(pool2, NULL); + + isc_test_end(); +} + +/* Get tasks */ +ATF_TC(get_tasks); +ATF_TC_HEAD(get_tasks, tc) { + atf_tc_set_md_var(tc, "descr", "create a taskpool"); +} +ATF_TC_BODY(get_tasks, tc) { + isc_result_t result; + isc_taskpool_t *pool = NULL; + isc_task_t *task1 = NULL, *task2 = NULL, *task3 = NULL; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_taskpool_create(taskmgr, mctx, 2, 2, &pool); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE_EQ(isc_taskpool_size(pool), 2); + + /* two tasks in pool; make sure we can access them more than twice */ + isc_taskpool_gettask(pool, &task1); + ATF_REQUIRE(ISCAPI_TASK_VALID(task1)); + + isc_taskpool_gettask(pool, &task2); + ATF_REQUIRE(ISCAPI_TASK_VALID(task2)); + + isc_taskpool_gettask(pool, &task3); + ATF_REQUIRE(ISCAPI_TASK_VALID(task3)); + + isc_task_destroy(&task1); + isc_task_destroy(&task2); + isc_task_destroy(&task3); + + isc_taskpool_destroy(&pool); + ATF_REQUIRE_EQ(pool, NULL); + + isc_test_end(); +} + +/* Get tasks */ +ATF_TC(set_privilege); +ATF_TC_HEAD(set_privilege, tc) { + atf_tc_set_md_var(tc, "descr", "create a taskpool"); +} +ATF_TC_BODY(set_privilege, tc) { + isc_result_t result; + isc_taskpool_t *pool = NULL; + isc_task_t *task1 = NULL, *task2 = NULL, *task3 = NULL; + + UNUSED(tc); + + result = isc_test_begin(NULL, ISC_TRUE); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + + result = isc_taskpool_create(taskmgr, mctx, 2, 2, &pool); + ATF_REQUIRE_EQ(result, ISC_R_SUCCESS); + ATF_REQUIRE_EQ(isc_taskpool_size(pool), 2); + + isc_taskpool_setprivilege(pool, ISC_TRUE); + + isc_taskpool_gettask(pool, &task1); + isc_taskpool_gettask(pool, &task2); + isc_taskpool_gettask(pool, &task3); + + ATF_CHECK(ISCAPI_TASK_VALID(task1)); + ATF_CHECK(ISCAPI_TASK_VALID(task2)); + ATF_CHECK(ISCAPI_TASK_VALID(task3)); + + ATF_CHECK(isc_task_privilege(task1)); + ATF_CHECK(isc_task_privilege(task2)); + ATF_CHECK(isc_task_privilege(task3)); + + isc_taskpool_setprivilege(pool, ISC_FALSE); + + ATF_CHECK(!isc_task_privilege(task1)); + ATF_CHECK(!isc_task_privilege(task2)); + ATF_CHECK(!isc_task_privilege(task3)); + + isc_task_destroy(&task1); + isc_task_destroy(&task2); + isc_task_destroy(&task3); + + isc_taskpool_destroy(&pool); + ATF_REQUIRE_EQ(pool, NULL); + + isc_test_end(); +} + +/* + * Main + */ +ATF_TP_ADD_TCS(tp) { + ATF_TP_ADD_TC(tp, create_pool); + ATF_TP_ADD_TC(tp, expand_pool); + ATF_TP_ADD_TC(tp, get_tasks); + ATF_TP_ADD_TC(tp, set_privilege); + + return (atf_no_error()); +} + diff --git a/contrib/ntp/lib/isc/timer.c b/contrib/ntp/lib/isc/timer.c new file mode 100644 index 000000000..0da251f4c --- /dev/null +++ b/contrib/ntp/lib/isc/timer.c @@ -0,0 +1,1072 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef OPENSSL_LEAKS +#include +#endif + +/* See task.c about the following definition: */ +#ifdef BIND9 +#ifdef ISC_PLATFORM_USETHREADS +#define USE_TIMER_THREAD +#else +#define USE_SHARED_MANAGER +#endif /* ISC_PLATFORM_USETHREADS */ +#endif /* BIND9 */ + +#ifndef USE_TIMER_THREAD +#include "timer_p.h" +#endif /* USE_TIMER_THREAD */ + +#ifdef ISC_TIMER_TRACE +#define XTRACE(s) fprintf(stderr, "%s\n", (s)) +#define XTRACEID(s, t) fprintf(stderr, "%s %p\n", (s), (t)) +#define XTRACETIME(s, d) fprintf(stderr, "%s %u.%09u\n", (s), \ + (d).seconds, (d).nanoseconds) +#define XTRACETIME2(s, d, n) fprintf(stderr, "%s %u.%09u %u.%09u\n", (s), \ + (d).seconds, (d).nanoseconds, (n).seconds, (n).nanoseconds) +#define XTRACETIMER(s, t, d) fprintf(stderr, "%s %p %u.%09u\n", (s), (t), \ + (d).seconds, (d).nanoseconds) +#else +#define XTRACE(s) +#define XTRACEID(s, t) +#define XTRACETIME(s, d) +#define XTRACETIME2(s, d, n) +#define XTRACETIMER(s, t, d) +#endif /* ISC_TIMER_TRACE */ + +#define TIMER_MAGIC ISC_MAGIC('T', 'I', 'M', 'R') +#define VALID_TIMER(t) ISC_MAGIC_VALID(t, TIMER_MAGIC) + +typedef struct isc__timer isc__timer_t; +typedef struct isc__timermgr isc__timermgr_t; + +struct isc__timer { + /*! Not locked. */ + isc_timer_t common; + isc__timermgr_t * manager; + isc_mutex_t lock; + /*! Locked by timer lock. */ + unsigned int references; + isc_time_t idle; + /*! Locked by manager lock. */ + isc_timertype_t type; + isc_time_t expires; + isc_interval_t interval; + isc_task_t * task; + isc_taskaction_t action; + void * arg; + unsigned int index; + isc_time_t due; + LINK(isc__timer_t) link; +}; + +#define TIMER_MANAGER_MAGIC ISC_MAGIC('T', 'I', 'M', 'M') +#define VALID_MANAGER(m) ISC_MAGIC_VALID(m, TIMER_MANAGER_MAGIC) + +struct isc__timermgr { + /* Not locked. */ + isc_timermgr_t common; + isc_mem_t * mctx; + isc_mutex_t lock; + /* Locked by manager lock. */ + isc_boolean_t done; + LIST(isc__timer_t) timers; + unsigned int nscheduled; + isc_time_t due; +#ifdef USE_TIMER_THREAD + isc_condition_t wakeup; + isc_thread_t thread; +#endif /* USE_TIMER_THREAD */ +#ifdef USE_SHARED_MANAGER + unsigned int refs; +#endif /* USE_SHARED_MANAGER */ + isc_heap_t * heap; +}; + +/*% + * The followings can be either static or public, depending on build + * environment. + */ + +#ifdef BIND9 +#define ISC_TIMERFUNC_SCOPE +#else +#define ISC_TIMERFUNC_SCOPE static +#endif + +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timer_create(isc_timermgr_t *manager, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_timer_t **timerp); +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timer_reset(isc_timer_t *timer, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_boolean_t purge); +ISC_TIMERFUNC_SCOPE isc_timertype_t +isc__timer_gettype(isc_timer_t *timer); +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timer_touch(isc_timer_t *timer); +ISC_TIMERFUNC_SCOPE void +isc__timer_attach(isc_timer_t *timer0, isc_timer_t **timerp); +ISC_TIMERFUNC_SCOPE void +isc__timer_detach(isc_timer_t **timerp); +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timermgr_create(isc_mem_t *mctx, isc_timermgr_t **managerp); +ISC_TIMERFUNC_SCOPE void +isc__timermgr_poke(isc_timermgr_t *manager0); +ISC_TIMERFUNC_SCOPE void +isc__timermgr_destroy(isc_timermgr_t **managerp); + +static struct isc__timermethods { + isc_timermethods_t methods; + + /*% + * The following are defined just for avoiding unused static functions. + */ +#ifndef BIND9 + void *gettype; +#endif +} timermethods = { + { + isc__timer_attach, + isc__timer_detach, + isc__timer_reset, + isc__timer_touch + } +#ifndef BIND9 + , + (void *)isc__timer_gettype +#endif +}; + +static struct isc__timermgrmethods { + isc_timermgrmethods_t methods; +#ifndef BIND9 + void *poke; /* see above */ +#endif +} timermgrmethods = { + { + isc__timermgr_destroy, + isc__timer_create + } +#ifndef BIND9 + , + (void *)isc__timermgr_poke +#endif +}; + +#ifdef USE_SHARED_MANAGER +/*! + * If the manager is supposed to be shared, there can be only one. + */ +static isc__timermgr_t *timermgr = NULL; +#endif /* USE_SHARED_MANAGER */ + +static inline isc_result_t +schedule(isc__timer_t *timer, isc_time_t *now, isc_boolean_t signal_ok) { + isc_result_t result; + isc__timermgr_t *manager; + isc_time_t due; + int cmp; +#ifdef USE_TIMER_THREAD + isc_boolean_t timedwait; +#endif + + /*! + * Note: the caller must ensure locking. + */ + + REQUIRE(timer->type != isc_timertype_inactive); + +#ifndef USE_TIMER_THREAD + UNUSED(signal_ok); +#endif /* USE_TIMER_THREAD */ + + manager = timer->manager; + +#ifdef USE_TIMER_THREAD + /*! + * If the manager was timed wait, we may need to signal the + * manager to force a wakeup. + */ + timedwait = ISC_TF(manager->nscheduled > 0 && + isc_time_seconds(&manager->due) != 0); +#endif + + /* + * Compute the new due time. + */ + if (timer->type != isc_timertype_once) { + result = isc_time_add(now, &timer->interval, &due); + if (result != ISC_R_SUCCESS) + return (result); + if (timer->type == isc_timertype_limited && + isc_time_compare(&timer->expires, &due) < 0) + due = timer->expires; + } else { + if (isc_time_isepoch(&timer->idle)) + due = timer->expires; + else if (isc_time_isepoch(&timer->expires)) + due = timer->idle; + else if (isc_time_compare(&timer->idle, &timer->expires) < 0) + due = timer->idle; + else + due = timer->expires; + } + + /* + * Schedule the timer. + */ + + if (timer->index > 0) { + /* + * Already scheduled. + */ + cmp = isc_time_compare(&due, &timer->due); + timer->due = due; + switch (cmp) { + case -1: + isc_heap_increased(manager->heap, timer->index); + break; + case 1: + isc_heap_decreased(manager->heap, timer->index); + break; + case 0: + /* Nothing to do. */ + break; + } + } else { + timer->due = due; + result = isc_heap_insert(manager->heap, timer); + if (result != ISC_R_SUCCESS) { + INSIST(result == ISC_R_NOMEMORY); + return (ISC_R_NOMEMORY); + } + manager->nscheduled++; + } + + XTRACETIMER(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SCHEDULE, "schedule"), timer, due); + + /* + * If this timer is at the head of the queue, we need to ensure + * that we won't miss it if it has a more recent due time than + * the current "next" timer. We do this either by waking up the + * run thread, or explicitly setting the value in the manager. + */ +#ifdef USE_TIMER_THREAD + + /* + * This is a temporary (probably) hack to fix a bug on tru64 5.1 + * and 5.1a. Sometimes, pthread_cond_timedwait() doesn't actually + * return when the time expires, so here, we check to see if + * we're 15 seconds or more behind, and if we are, we signal + * the dispatcher. This isn't such a bad idea as a general purpose + * watchdog, so perhaps we should just leave it in here. + */ + if (signal_ok && timedwait) { + isc_interval_t fifteen; + isc_time_t then; + + isc_interval_set(&fifteen, 15, 0); + result = isc_time_add(&manager->due, &fifteen, &then); + + if (result == ISC_R_SUCCESS && + isc_time_compare(&then, now) < 0) { + SIGNAL(&manager->wakeup); + signal_ok = ISC_FALSE; + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_TIMER, ISC_LOG_WARNING, + "*** POKED TIMER ***"); + } + } + + if (timer->index == 1 && signal_ok) { + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SIGNALSCHED, + "signal (schedule)")); + SIGNAL(&manager->wakeup); + } +#else /* USE_TIMER_THREAD */ + if (timer->index == 1 && + isc_time_compare(&timer->due, &manager->due) < 0) + manager->due = timer->due; +#endif /* USE_TIMER_THREAD */ + + return (ISC_R_SUCCESS); +} + +static inline void +deschedule(isc__timer_t *timer) { +#ifdef USE_TIMER_THREAD + isc_boolean_t need_wakeup = ISC_FALSE; +#endif + isc__timermgr_t *manager; + + /* + * The caller must ensure locking. + */ + + manager = timer->manager; + if (timer->index > 0) { +#ifdef USE_TIMER_THREAD + if (timer->index == 1) + need_wakeup = ISC_TRUE; +#endif + isc_heap_delete(manager->heap, timer->index); + timer->index = 0; + INSIST(manager->nscheduled > 0); + manager->nscheduled--; +#ifdef USE_TIMER_THREAD + if (need_wakeup) { + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SIGNALDESCHED, + "signal (deschedule)")); + SIGNAL(&manager->wakeup); + } +#endif /* USE_TIMER_THREAD */ + } +} + +static void +destroy(isc__timer_t *timer) { + isc__timermgr_t *manager = timer->manager; + + /* + * The caller must ensure it is safe to destroy the timer. + */ + + LOCK(&manager->lock); + + (void)isc_task_purgerange(timer->task, + timer, + ISC_TIMEREVENT_FIRSTEVENT, + ISC_TIMEREVENT_LASTEVENT, + NULL); + deschedule(timer); + UNLINK(manager->timers, timer, link); + + UNLOCK(&manager->lock); + + isc_task_detach(&timer->task); + DESTROYLOCK(&timer->lock); + timer->common.impmagic = 0; + timer->common.magic = 0; + isc_mem_put(manager->mctx, timer, sizeof(*timer)); +} + +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timer_create(isc_timermgr_t *manager0, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_timer_t **timerp) +{ + isc__timermgr_t *manager = (isc__timermgr_t *)manager0; + isc__timer_t *timer; + isc_result_t result; + isc_time_t now; + + /* + * Create a new 'type' timer managed by 'manager'. The timers + * parameters are specified by 'expires' and 'interval'. Events + * will be posted to 'task' and when dispatched 'action' will be + * called with 'arg' as the arg value. The new timer is returned + * in 'timerp'. + */ + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + if (expires == NULL) + expires = isc_time_epoch; + if (interval == NULL) + interval = isc_interval_zero; + REQUIRE(type == isc_timertype_inactive || + !(isc_time_isepoch(expires) && isc_interval_iszero(interval))); + REQUIRE(timerp != NULL && *timerp == NULL); + REQUIRE(type != isc_timertype_limited || + !(isc_time_isepoch(expires) || isc_interval_iszero(interval))); + + /* + * Get current time. + */ + if (type != isc_timertype_inactive) { + TIME_NOW(&now); + } else { + /* + * We don't have to do this, but it keeps the compiler from + * complaining about "now" possibly being used without being + * set, even though it will never actually happen. + */ + isc_time_settoepoch(&now); + } + + + timer = isc_mem_get(manager->mctx, sizeof(*timer)); + if (timer == NULL) + return (ISC_R_NOMEMORY); + + timer->manager = manager; + timer->references = 1; + + if (type == isc_timertype_once && !isc_interval_iszero(interval)) { + result = isc_time_add(&now, interval, &timer->idle); + if (result != ISC_R_SUCCESS) { + isc_mem_put(manager->mctx, timer, sizeof(*timer)); + return (result); + } + } else + isc_time_settoepoch(&timer->idle); + + timer->type = type; + timer->expires = *expires; + timer->interval = *interval; + timer->task = NULL; + isc_task_attach(task, &timer->task); + timer->action = action; + /* + * Removing the const attribute from "arg" is the best of two + * evils here. If the timer->arg member is made const, then + * it affects a great many recipients of the timer event + * which did not pass in an "arg" that was truly const. + * Changing isc_timer_create() to not have "arg" prototyped as const, + * though, can cause compilers warnings for calls that *do* + * have a truly const arg. The caller will have to carefully + * keep track of whether arg started as a true const. + */ + DE_CONST(arg, timer->arg); + timer->index = 0; + result = isc_mutex_init(&timer->lock); + if (result != ISC_R_SUCCESS) { + isc_task_detach(&timer->task); + isc_mem_put(manager->mctx, timer, sizeof(*timer)); + return (result); + } + ISC_LINK_INIT(timer, link); + timer->common.impmagic = TIMER_MAGIC; + timer->common.magic = ISCAPI_TIMER_MAGIC; + timer->common.methods = (isc_timermethods_t *)&timermethods; + + LOCK(&manager->lock); + + /* + * Note we don't have to lock the timer like we normally would because + * there are no external references to it yet. + */ + + if (type != isc_timertype_inactive) + result = schedule(timer, &now, ISC_TRUE); + else + result = ISC_R_SUCCESS; + if (result == ISC_R_SUCCESS) + APPEND(manager->timers, timer, link); + + UNLOCK(&manager->lock); + + if (result != ISC_R_SUCCESS) { + timer->common.impmagic = 0; + timer->common.magic = 0; + DESTROYLOCK(&timer->lock); + isc_task_detach(&timer->task); + isc_mem_put(manager->mctx, timer, sizeof(*timer)); + return (result); + } + + *timerp = (isc_timer_t *)timer; + + return (ISC_R_SUCCESS); +} + +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timer_reset(isc_timer_t *timer0, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_boolean_t purge) +{ + isc__timer_t *timer = (isc__timer_t *)timer0; + isc_time_t now; + isc__timermgr_t *manager; + isc_result_t result; + + /* + * Change the timer's type, expires, and interval values to the given + * values. If 'purge' is ISC_TRUE, any pending events from this timer + * are purged from its task's event queue. + */ + + REQUIRE(VALID_TIMER(timer)); + manager = timer->manager; + REQUIRE(VALID_MANAGER(manager)); + + if (expires == NULL) + expires = isc_time_epoch; + if (interval == NULL) + interval = isc_interval_zero; + REQUIRE(type == isc_timertype_inactive || + !(isc_time_isepoch(expires) && isc_interval_iszero(interval))); + REQUIRE(type != isc_timertype_limited || + !(isc_time_isepoch(expires) || isc_interval_iszero(interval))); + + /* + * Get current time. + */ + if (type != isc_timertype_inactive) { + TIME_NOW(&now); + } else { + /* + * We don't have to do this, but it keeps the compiler from + * complaining about "now" possibly being used without being + * set, even though it will never actually happen. + */ + isc_time_settoepoch(&now); + } + + LOCK(&manager->lock); + LOCK(&timer->lock); + + if (purge) + (void)isc_task_purgerange(timer->task, + timer, + ISC_TIMEREVENT_FIRSTEVENT, + ISC_TIMEREVENT_LASTEVENT, + NULL); + timer->type = type; + timer->expires = *expires; + timer->interval = *interval; + if (type == isc_timertype_once && !isc_interval_iszero(interval)) { + result = isc_time_add(&now, interval, &timer->idle); + } else { + isc_time_settoepoch(&timer->idle); + result = ISC_R_SUCCESS; + } + + if (result == ISC_R_SUCCESS) { + if (type == isc_timertype_inactive) { + deschedule(timer); + result = ISC_R_SUCCESS; + } else + result = schedule(timer, &now, ISC_TRUE); + } + + UNLOCK(&timer->lock); + UNLOCK(&manager->lock); + + return (result); +} + +ISC_TIMERFUNC_SCOPE isc_timertype_t +isc__timer_gettype(isc_timer_t *timer0) { + isc__timer_t *timer = (isc__timer_t *)timer0; + isc_timertype_t t; + + REQUIRE(VALID_TIMER(timer)); + + LOCK(&timer->lock); + t = timer->type; + UNLOCK(&timer->lock); + + return (t); +} + +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timer_touch(isc_timer_t *timer0) { + isc__timer_t *timer = (isc__timer_t *)timer0; + isc_result_t result; + isc_time_t now; + + /* + * Set the last-touched time of 'timer' to the current time. + */ + + REQUIRE(VALID_TIMER(timer)); + + LOCK(&timer->lock); + + /* + * We'd like to + * + * REQUIRE(timer->type == isc_timertype_once); + * + * but we cannot without locking the manager lock too, which we + * don't want to do. + */ + + TIME_NOW(&now); + result = isc_time_add(&now, &timer->interval, &timer->idle); + + UNLOCK(&timer->lock); + + return (result); +} + +ISC_TIMERFUNC_SCOPE void +isc__timer_attach(isc_timer_t *timer0, isc_timer_t **timerp) { + isc__timer_t *timer = (isc__timer_t *)timer0; + + /* + * Attach *timerp to timer. + */ + + REQUIRE(VALID_TIMER(timer)); + REQUIRE(timerp != NULL && *timerp == NULL); + + LOCK(&timer->lock); + timer->references++; + UNLOCK(&timer->lock); + + *timerp = (isc_timer_t *)timer; +} + +ISC_TIMERFUNC_SCOPE void +isc__timer_detach(isc_timer_t **timerp) { + isc__timer_t *timer; + isc_boolean_t free_timer = ISC_FALSE; + + /* + * Detach *timerp from its timer. + */ + + REQUIRE(timerp != NULL); + timer = (isc__timer_t *)*timerp; + REQUIRE(VALID_TIMER(timer)); + + LOCK(&timer->lock); + REQUIRE(timer->references > 0); + timer->references--; + if (timer->references == 0) + free_timer = ISC_TRUE; + UNLOCK(&timer->lock); + + if (free_timer) + destroy(timer); + + *timerp = NULL; +} + +static void +dispatch(isc__timermgr_t *manager, isc_time_t *now) { + isc_boolean_t done = ISC_FALSE, post_event, need_schedule; + isc_timerevent_t *event; + isc_eventtype_t type = 0; + isc__timer_t *timer; + isc_result_t result; + isc_boolean_t idle; + + /*! + * The caller must be holding the manager lock. + */ + + while (manager->nscheduled > 0 && !done) { + timer = isc_heap_element(manager->heap, 1); + INSIST(timer->type != isc_timertype_inactive); + if (isc_time_compare(now, &timer->due) >= 0) { + if (timer->type == isc_timertype_ticker) { + type = ISC_TIMEREVENT_TICK; + post_event = ISC_TRUE; + need_schedule = ISC_TRUE; + } else if (timer->type == isc_timertype_limited) { + int cmp; + cmp = isc_time_compare(now, &timer->expires); + if (cmp >= 0) { + type = ISC_TIMEREVENT_LIFE; + post_event = ISC_TRUE; + need_schedule = ISC_FALSE; + } else { + type = ISC_TIMEREVENT_TICK; + post_event = ISC_TRUE; + need_schedule = ISC_TRUE; + } + } else if (!isc_time_isepoch(&timer->expires) && + isc_time_compare(now, + &timer->expires) >= 0) { + type = ISC_TIMEREVENT_LIFE; + post_event = ISC_TRUE; + need_schedule = ISC_FALSE; + } else { + idle = ISC_FALSE; + + LOCK(&timer->lock); + if (!isc_time_isepoch(&timer->idle) && + isc_time_compare(now, + &timer->idle) >= 0) { + idle = ISC_TRUE; + } + UNLOCK(&timer->lock); + if (idle) { + type = ISC_TIMEREVENT_IDLE; + post_event = ISC_TRUE; + need_schedule = ISC_FALSE; + } else { + /* + * Idle timer has been touched; + * reschedule. + */ + XTRACEID(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_IDLERESCHED, + "idle reschedule"), + timer); + post_event = ISC_FALSE; + need_schedule = ISC_TRUE; + } + } + + if (post_event) { + XTRACEID(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_POSTING, + "posting"), timer); + /* + * XXX We could preallocate this event. + */ + event = (isc_timerevent_t *)isc_event_allocate(manager->mctx, + timer, + type, + timer->action, + timer->arg, + sizeof(*event)); + + if (event != NULL) { + event->due = timer->due; + isc_task_send(timer->task, + ISC_EVENT_PTR(&event)); + } else + UNEXPECTED_ERROR(__FILE__, __LINE__, "%s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_EVENTNOTALLOC, + "couldn't " + "allocate event")); + } + + timer->index = 0; + isc_heap_delete(manager->heap, 1); + manager->nscheduled--; + + if (need_schedule) { + result = schedule(timer, now, ISC_FALSE); + if (result != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s: %u", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_TIMER, + ISC_MSG_SCHEDFAIL, + "couldn't schedule " + "timer"), + result); + } + } else { + manager->due = timer->due; + done = ISC_TRUE; + } + } +} + +#ifdef USE_TIMER_THREAD +static isc_threadresult_t +#ifdef _WIN32 /* XXXDCL */ +WINAPI +#endif +run(void *uap) { + isc__timermgr_t *manager = uap; + isc_time_t now; + isc_result_t result; + + LOCK(&manager->lock); + while (!manager->done) { + TIME_NOW(&now); + + XTRACETIME(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RUNNING, + "running"), now); + + dispatch(manager, &now); + + if (manager->nscheduled > 0) { + XTRACETIME2(isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_WAITUNTIL, + "waituntil"), + manager->due, now); + result = WAITUNTIL(&manager->wakeup, &manager->lock, &manager->due); + INSIST(result == ISC_R_SUCCESS || + result == ISC_R_TIMEDOUT); + } else { + XTRACETIME(isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_WAIT, "wait"), now); + WAIT(&manager->wakeup, &manager->lock); + } + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_WAKEUP, "wakeup")); + } + UNLOCK(&manager->lock); + +#ifdef OPENSSL_LEAKS + ERR_remove_state(0); +#endif + + return ((isc_threadresult_t)0); +} +#endif /* USE_TIMER_THREAD */ + +static isc_boolean_t +sooner(void *v1, void *v2) { + isc__timer_t *t1, *t2; + + t1 = v1; + t2 = v2; + REQUIRE(VALID_TIMER(t1)); + REQUIRE(VALID_TIMER(t2)); + + if (isc_time_compare(&t1->due, &t2->due) < 0) + return (ISC_TRUE); + return (ISC_FALSE); +} + +static void +set_index(void *what, unsigned int index) { + isc__timer_t *timer; + + timer = what; + REQUIRE(VALID_TIMER(timer)); + + timer->index = index; +} + +ISC_TIMERFUNC_SCOPE isc_result_t +isc__timermgr_create(isc_mem_t *mctx, isc_timermgr_t **managerp) { + isc__timermgr_t *manager; + isc_result_t result; + + /* + * Create a timer manager. + */ + + REQUIRE(managerp != NULL && *managerp == NULL); + +#ifdef USE_SHARED_MANAGER + if (timermgr != NULL) { + timermgr->refs++; + *managerp = (isc_timermgr_t *)timermgr; + return (ISC_R_SUCCESS); + } +#endif /* USE_SHARED_MANAGER */ + + manager = isc_mem_get(mctx, sizeof(*manager)); + if (manager == NULL) + return (ISC_R_NOMEMORY); + + manager->common.impmagic = TIMER_MANAGER_MAGIC; + manager->common.magic = ISCAPI_TIMERMGR_MAGIC; + manager->common.methods = (isc_timermgrmethods_t *)&timermgrmethods; + manager->mctx = NULL; + manager->done = ISC_FALSE; + INIT_LIST(manager->timers); + manager->nscheduled = 0; + isc_time_settoepoch(&manager->due); + manager->heap = NULL; + result = isc_heap_create(mctx, sooner, set_index, 0, &manager->heap); + if (result != ISC_R_SUCCESS) { + INSIST(result == ISC_R_NOMEMORY); + isc_mem_put(mctx, manager, sizeof(*manager)); + return (ISC_R_NOMEMORY); + } + result = isc_mutex_init(&manager->lock); + if (result != ISC_R_SUCCESS) { + isc_heap_destroy(&manager->heap); + isc_mem_put(mctx, manager, sizeof(*manager)); + return (result); + } + isc_mem_attach(mctx, &manager->mctx); +#ifdef USE_TIMER_THREAD + if (isc_condition_init(&manager->wakeup) != ISC_R_SUCCESS) { + isc_mem_detach(&manager->mctx); + DESTROYLOCK(&manager->lock); + isc_heap_destroy(&manager->heap); + isc_mem_put(mctx, manager, sizeof(*manager)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + return (ISC_R_UNEXPECTED); + } + if (isc_thread_create(run, manager, &manager->thread) != + ISC_R_SUCCESS) { + isc_mem_detach(&manager->mctx); + (void)isc_condition_destroy(&manager->wakeup); + DESTROYLOCK(&manager->lock); + isc_heap_destroy(&manager->heap); + isc_mem_put(mctx, manager, sizeof(*manager)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_create() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + return (ISC_R_UNEXPECTED); + } +#endif +#ifdef USE_SHARED_MANAGER + manager->refs = 1; + timermgr = manager; +#endif /* USE_SHARED_MANAGER */ + + *managerp = (isc_timermgr_t *)manager; + + return (ISC_R_SUCCESS); +} + +ISC_TIMERFUNC_SCOPE void +isc__timermgr_poke(isc_timermgr_t *manager0) { +#ifdef USE_TIMER_THREAD + isc__timermgr_t *manager = (isc__timermgr_t *)manager0; + + REQUIRE(VALID_MANAGER(manager)); + + SIGNAL(&manager->wakeup); +#else + UNUSED(manager0); +#endif +} + +ISC_TIMERFUNC_SCOPE void +isc__timermgr_destroy(isc_timermgr_t **managerp) { + isc__timermgr_t *manager; + isc_mem_t *mctx; + + /* + * Destroy a timer manager. + */ + + REQUIRE(managerp != NULL); + manager = (isc__timermgr_t *)*managerp; + REQUIRE(VALID_MANAGER(manager)); + + LOCK(&manager->lock); + +#ifdef USE_SHARED_MANAGER + manager->refs--; + if (manager->refs > 0) { + UNLOCK(&manager->lock); + *managerp = NULL; + return; + } + timermgr = NULL; +#endif /* USE_SHARED_MANAGER */ + +#ifndef USE_TIMER_THREAD + isc__timermgr_dispatch((isc_timermgr_t *)manager); +#endif + + REQUIRE(EMPTY(manager->timers)); + manager->done = ISC_TRUE; + +#ifdef USE_TIMER_THREAD + XTRACE(isc_msgcat_get(isc_msgcat, ISC_MSGSET_TIMER, + ISC_MSG_SIGNALDESTROY, "signal (destroy)")); + SIGNAL(&manager->wakeup); +#endif /* USE_TIMER_THREAD */ + + UNLOCK(&manager->lock); + +#ifdef USE_TIMER_THREAD + /* + * Wait for thread to exit. + */ + if (isc_thread_join(manager->thread, NULL) != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_join() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); +#endif /* USE_TIMER_THREAD */ + + /* + * Clean up. + */ +#ifdef USE_TIMER_THREAD + (void)isc_condition_destroy(&manager->wakeup); +#endif /* USE_TIMER_THREAD */ + DESTROYLOCK(&manager->lock); + isc_heap_destroy(&manager->heap); + manager->common.impmagic = 0; + manager->common.magic = 0; + mctx = manager->mctx; + isc_mem_put(mctx, manager, sizeof(*manager)); + isc_mem_detach(&mctx); + + *managerp = NULL; + +#ifdef USE_SHARED_MANAGER + timermgr = NULL; +#endif +} + +#ifndef USE_TIMER_THREAD +isc_result_t +isc__timermgr_nextevent(isc_timermgr_t *manager0, isc_time_t *when) { + isc__timermgr_t *manager = (isc__timermgr_t *)manager0; + +#ifdef USE_SHARED_MANAGER + if (manager == NULL) + manager = timermgr; +#endif + if (manager == NULL || manager->nscheduled == 0) + return (ISC_R_NOTFOUND); + *when = manager->due; + return (ISC_R_SUCCESS); +} + +void +isc__timermgr_dispatch(isc_timermgr_t *manager0) { + isc__timermgr_t *manager = (isc__timermgr_t *)manager0; + isc_time_t now; + +#ifdef USE_SHARED_MANAGER + if (manager == NULL) + manager = timermgr; +#endif + if (manager == NULL) + return; + TIME_NOW(&now); + dispatch(manager, &now); +} +#endif /* USE_TIMER_THREAD */ + +#ifdef USE_TIMERIMPREGISTER +isc_result_t +isc__timer_register() { + return (isc_timer_register(isc__timermgr_create)); +} +#endif diff --git a/contrib/ntp/lib/isc/timer_api.c b/contrib/ntp/lib/isc/timer_api.c new file mode 100644 index 000000000..97e62b3f0 --- /dev/null +++ b/contrib/ntp/lib/isc/timer_api.c @@ -0,0 +1,144 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: timer_api.c,v 1.4 2009/09/02 23:48:02 tbox Exp $ */ + +#include + +#include + +#include +#include +#include +#include +#include +#include + +static isc_mutex_t createlock; +static isc_once_t once = ISC_ONCE_INIT; +static isc_timermgrcreatefunc_t timermgr_createfunc = NULL; + +static void +initialize(void) { + RUNTIME_CHECK(isc_mutex_init(&createlock) == ISC_R_SUCCESS); +} + +isc_result_t +isc_timer_register(isc_timermgrcreatefunc_t createfunc) { + isc_result_t result = ISC_R_SUCCESS; + + RUNTIME_CHECK(isc_once_do(&once, initialize) == ISC_R_SUCCESS); + + LOCK(&createlock); + if (timermgr_createfunc == NULL) + timermgr_createfunc = createfunc; + else + result = ISC_R_EXISTS; + UNLOCK(&createlock); + + return (result); +} + +isc_result_t +isc_timermgr_createinctx(isc_mem_t *mctx, isc_appctx_t *actx, + isc_timermgr_t **managerp) +{ + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(timermgr_createfunc != NULL); + result = (*timermgr_createfunc)(mctx, managerp); + + UNLOCK(&createlock); + + if (result == ISC_R_SUCCESS) + isc_appctx_settimermgr(actx, *managerp); + + return (result); +} + +isc_result_t +isc_timermgr_create(isc_mem_t *mctx, isc_timermgr_t **managerp) { + isc_result_t result; + + LOCK(&createlock); + + REQUIRE(timermgr_createfunc != NULL); + result = (*timermgr_createfunc)(mctx, managerp); + + UNLOCK(&createlock); + + return (result); +} + +void +isc_timermgr_destroy(isc_timermgr_t **managerp) { + REQUIRE(*managerp != NULL && ISCAPI_TIMERMGR_VALID(*managerp)); + + (*managerp)->methods->destroy(managerp); + + ENSURE(*managerp == NULL); +} + +isc_result_t +isc_timer_create(isc_timermgr_t *manager, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_timer_t **timerp) +{ + REQUIRE(ISCAPI_TIMERMGR_VALID(manager)); + + return (manager->methods->timercreate(manager, type, expires, + interval, task, action, arg, + timerp)); +} + +void +isc_timer_attach(isc_timer_t *timer, isc_timer_t **timerp) { + REQUIRE(ISCAPI_TIMER_VALID(timer)); + REQUIRE(timerp != NULL && *timerp == NULL); + + timer->methods->attach(timer, timerp); + + ENSURE(*timerp == timer); +} + +void +isc_timer_detach(isc_timer_t **timerp) { + REQUIRE(timerp != NULL && ISCAPI_TIMER_VALID(*timerp)); + + (*timerp)->methods->detach(timerp); + + ENSURE(*timerp == NULL); +} + +isc_result_t +isc_timer_reset(isc_timer_t *timer, isc_timertype_t type, + isc_time_t *expires, isc_interval_t *interval, + isc_boolean_t purge) +{ + REQUIRE(ISCAPI_TIMER_VALID(timer)); + + return (timer->methods->reset(timer, type, expires, interval, purge)); +} + +isc_result_t +isc_timer_touch(isc_timer_t *timer) { + REQUIRE(ISCAPI_TIMER_VALID(timer)); + + return (timer->methods->touch(timer)); +} diff --git a/contrib/ntp/lib/isc/timer_p.h b/contrib/ntp/lib/isc/timer_p.h new file mode 100644 index 000000000..d6f7c996c --- /dev/null +++ b/contrib/ntp/lib/isc/timer_p.h @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: timer_p.h,v 1.12 2009/09/02 23:48:02 tbox Exp $ */ + +#ifndef ISC_TIMER_P_H +#define ISC_TIMER_P_H + +/*! \file */ + +isc_result_t +isc__timermgr_nextevent(isc_timermgr_t *timermgr, isc_time_t *when); + +void +isc__timermgr_dispatch(isc_timermgr_t *timermgr); + +#endif /* ISC_TIMER_P_H */ diff --git a/contrib/ntp/lib/isc/unix/app.c b/contrib/ntp/lib/isc/unix/app.c new file mode 100644 index 000000000..5393be942 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/app.c @@ -0,0 +1,946 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: app.c,v 1.64 2009/11/04 05:58:46 marka Exp $ */ + +/*! \file */ + +#include + +#include /* Openserver 5.0.6A and FD_SETSIZE */ +#include + +#include +#include +#include +#include +#include +#include +#ifdef HAVE_EPOLL +#include +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/*% + * For BIND9 internal applications built with threads, we use a single app + * context and let multiple worker, I/O, timer threads do actual jobs. + * For other cases (including BIND9 built without threads) an app context acts + * as an event loop dispatching various events. + */ +#if defined(ISC_PLATFORM_USETHREADS) && defined(BIND9) +#define USE_THREADS_SINGLECTX +#endif + +#ifdef ISC_PLATFORM_USETHREADS +#include +#endif + +#ifndef USE_THREADS_SINGLECTX +#include "../timer_p.h" +#include "../task_p.h" +#include "socket_p.h" +#endif /* USE_THREADS_SINGLECTX */ + +#ifdef ISC_PLATFORM_USETHREADS +static pthread_t blockedthread; +#endif /* ISC_PLATFORM_USETHREADS */ + +/*% + * The following can be either static or public, depending on build environment. + */ + +#ifdef BIND9 +#define ISC_APPFUNC_SCOPE +#else +#define ISC_APPFUNC_SCOPE static +#endif + +ISC_APPFUNC_SCOPE isc_result_t isc__app_start(void); +ISC_APPFUNC_SCOPE isc_result_t isc__app_ctxstart(isc_appctx_t *ctx); +ISC_APPFUNC_SCOPE isc_result_t isc__app_onrun(isc_mem_t *mctx, + isc_task_t *task, + isc_taskaction_t action, + void *arg); +ISC_APPFUNC_SCOPE isc_result_t isc__app_ctxrun(isc_appctx_t *ctx); +ISC_APPFUNC_SCOPE isc_result_t isc__app_run(void); +ISC_APPFUNC_SCOPE isc_result_t isc__app_ctxshutdown(isc_appctx_t *ctx); +ISC_APPFUNC_SCOPE isc_result_t isc__app_shutdown(void); +ISC_APPFUNC_SCOPE isc_result_t isc__app_reload(void); +ISC_APPFUNC_SCOPE isc_result_t isc__app_ctxsuspend(isc_appctx_t *ctx); +ISC_APPFUNC_SCOPE void isc__app_ctxfinish(isc_appctx_t *ctx); +ISC_APPFUNC_SCOPE void isc__app_finish(void); +ISC_APPFUNC_SCOPE void isc__app_block(void); +ISC_APPFUNC_SCOPE void isc__app_unblock(void); +ISC_APPFUNC_SCOPE isc_result_t isc__appctx_create(isc_mem_t *mctx, + isc_appctx_t **ctxp); +ISC_APPFUNC_SCOPE void isc__appctx_destroy(isc_appctx_t **ctxp); +ISC_APPFUNC_SCOPE void isc__appctx_settaskmgr(isc_appctx_t *ctx, + isc_taskmgr_t *taskmgr); +ISC_APPFUNC_SCOPE void isc__appctx_setsocketmgr(isc_appctx_t *ctx, + isc_socketmgr_t *socketmgr); +ISC_APPFUNC_SCOPE void isc__appctx_settimermgr(isc_appctx_t *ctx, + isc_timermgr_t *timermgr); + +/* + * The application context of this module. This implementation actually + * doesn't use it. (This may change in the future). + */ +#define APPCTX_MAGIC ISC_MAGIC('A', 'p', 'c', 'x') +#define VALID_APPCTX(c) ISC_MAGIC_VALID(c, APPCTX_MAGIC) + +typedef struct isc__appctx { + isc_appctx_t common; + isc_mem_t *mctx; + isc_mutex_t lock; + isc_eventlist_t on_run; + isc_boolean_t shutdown_requested; + isc_boolean_t running; + + /*! + * We assume that 'want_shutdown' can be read and written atomically. + */ + isc_boolean_t want_shutdown; + /* + * We assume that 'want_reload' can be read and written atomically. + */ + isc_boolean_t want_reload; + + isc_boolean_t blocked; + + isc_taskmgr_t *taskmgr; + isc_socketmgr_t *socketmgr; + isc_timermgr_t *timermgr; +} isc__appctx_t; + +static isc__appctx_t isc_g_appctx; + +static struct { + isc_appmethods_t methods; + + /*% + * The following are defined just for avoiding unused static functions. + */ +#ifndef BIND9 + void *run, *shutdown, *start, *onrun, *reload, *finish, + *block, *unblock; +#endif +} appmethods = { + { + isc__appctx_destroy, + isc__app_ctxstart, + isc__app_ctxrun, + isc__app_ctxsuspend, + isc__app_ctxshutdown, + isc__app_ctxfinish, + isc__appctx_settaskmgr, + isc__appctx_setsocketmgr, + isc__appctx_settimermgr + } +#ifndef BIND9 + , + (void *)isc__app_run, (void *)isc__app_shutdown, + (void *)isc__app_start, (void *)isc__app_onrun, (void *)isc__app_reload, + (void *)isc__app_finish, (void *)isc__app_block, + (void *)isc__app_unblock +#endif +}; + +#ifdef HAVE_LINUXTHREADS +/*! + * Linux has sigwait(), but it appears to prevent signal handlers from + * running, even if they're not in the set being waited for. This makes + * it impossible to get the default actions for SIGILL, SIGSEGV, etc. + * Instead of messing with it, we just use sigsuspend() instead. + */ +#undef HAVE_SIGWAIT +/*! + * We need to remember which thread is the main thread... + */ +static pthread_t main_thread; +#endif + +#ifndef HAVE_SIGWAIT +static void +exit_action(int arg) { + UNUSED(arg); + isc_g_appctx.want_shutdown = ISC_TRUE; +} + +static void +reload_action(int arg) { + UNUSED(arg); + isc_g_appctx.want_reload = ISC_TRUE; +} +#endif + +static isc_result_t +handle_signal(int sig, void (*handler)(int)) { + struct sigaction sa; + char strbuf[ISC_STRERRORSIZE]; + + memset(&sa, 0, sizeof(sa)); + sa.sa_handler = handler; + + if (sigfillset(&sa.sa_mask) != 0 || + sigaction(sig, &sa, NULL) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_APP, + ISC_MSG_SIGNALSETUP, + "handle_signal() %d setup: %s"), + sig, strbuf); + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_ctxstart(isc_appctx_t *ctx0) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + isc_result_t result; + + REQUIRE(VALID_APPCTX(ctx)); + + /* + * Start an ISC library application. + */ + +#ifdef NEED_PTHREAD_INIT + /* + * BSDI 3.1 seg faults in pthread_sigmask() if we don't do this. + */ + presult = pthread_init(); + if (presult != 0) { + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() pthread_init: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif + +#ifdef HAVE_LINUXTHREADS + main_thread = pthread_self(); +#endif + + result = isc_mutex_init(&ctx->lock); + if (result != ISC_R_SUCCESS) + return (result); + + ISC_LIST_INIT(ctx->on_run); + + ctx->shutdown_requested = ISC_FALSE; + ctx->running = ISC_FALSE; + ctx->want_shutdown = ISC_FALSE; + ctx->want_reload = ISC_FALSE; + ctx->blocked = ISC_FALSE; + + return (ISC_R_SUCCESS); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_start(void) { + isc_result_t result; + int presult; + sigset_t sset; + char strbuf[ISC_STRERRORSIZE]; + + isc_g_appctx.common.impmagic = APPCTX_MAGIC; + isc_g_appctx.common.magic = ISCAPI_APPCTX_MAGIC; + isc_g_appctx.common.methods = &appmethods.methods; + isc_g_appctx.mctx = NULL; + /* The remaining members will be initialized in ctxstart() */ + + result = isc__app_ctxstart((isc_appctx_t *)&isc_g_appctx); + if (result != ISC_R_SUCCESS) + return (result); + +#ifndef HAVE_SIGWAIT + /* + * Install do-nothing handlers for SIGINT and SIGTERM. + * + * We install them now because BSDI 3.1 won't block + * the default actions, regardless of what we do with + * pthread_sigmask(). + */ + result = handle_signal(SIGINT, exit_action); + if (result != ISC_R_SUCCESS) + return (result); + result = handle_signal(SIGTERM, exit_action); + if (result != ISC_R_SUCCESS) + return (result); +#endif + + /* + * Always ignore SIGPIPE. + */ + result = handle_signal(SIGPIPE, SIG_IGN); + if (result != ISC_R_SUCCESS) + return (result); + + /* + * On Solaris 2, delivery of a signal whose action is SIG_IGN + * will not cause sigwait() to return. We may have inherited + * unexpected actions for SIGHUP, SIGINT, and SIGTERM from our parent + * process (e.g, Solaris cron). Set an action of SIG_DFL to make + * sure sigwait() works as expected. Only do this for SIGTERM and + * SIGINT if we don't have sigwait(), since a different handler is + * installed above. + */ + result = handle_signal(SIGHUP, SIG_DFL); + if (result != ISC_R_SUCCESS) + return (result); + +#ifdef HAVE_SIGWAIT + result = handle_signal(SIGTERM, SIG_DFL); + if (result != ISC_R_SUCCESS) + return (result); + result = handle_signal(SIGINT, SIG_DFL); + if (result != ISC_R_SUCCESS) + return (result); +#endif + +#ifdef ISC_PLATFORM_USETHREADS + /* + * Block SIGHUP, SIGINT, SIGTERM. + * + * If isc_app_start() is called from the main thread before any other + * threads have been created, then the pthread_sigmask() call below + * will result in all threads having SIGHUP, SIGINT and SIGTERM + * blocked by default, ensuring that only the thread that calls + * sigwait() for them will get those signals. + */ + if (sigemptyset(&sset) != 0 || + sigaddset(&sset, SIGHUP) != 0 || + sigaddset(&sset, SIGINT) != 0 || + sigaddset(&sset, SIGTERM) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() sigsetops: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + presult = pthread_sigmask(SIG_BLOCK, &sset, NULL); + if (presult != 0) { + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() pthread_sigmask: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } +#else /* ISC_PLATFORM_USETHREADS */ + /* + * Unblock SIGHUP, SIGINT, SIGTERM. + * + * If we're not using threads, we need to make sure that SIGHUP, + * SIGINT and SIGTERM are not inherited as blocked from the parent + * process. + */ + if (sigemptyset(&sset) != 0 || + sigaddset(&sset, SIGHUP) != 0 || + sigaddset(&sset, SIGINT) != 0 || + sigaddset(&sset, SIGTERM) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() sigsetops: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + presult = sigprocmask(SIG_UNBLOCK, &sset, NULL); + if (presult != 0) { + isc__strerror(presult, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_start() sigprocmask: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif /* ISC_PLATFORM_USETHREADS */ + + return (ISC_R_SUCCESS); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_onrun(isc_mem_t *mctx, isc_task_t *task, isc_taskaction_t action, + void *arg) +{ + isc_event_t *event; + isc_task_t *cloned_task = NULL; + isc_result_t result; + + LOCK(&isc_g_appctx.lock); + + if (isc_g_appctx.running) { + result = ISC_R_ALREADYRUNNING; + goto unlock; + } + + /* + * Note that we store the task to which we're going to send the event + * in the event's "sender" field. + */ + isc_task_attach(task, &cloned_task); + event = isc_event_allocate(mctx, cloned_task, ISC_APPEVENT_SHUTDOWN, + action, arg, sizeof(*event)); + if (event == NULL) { + result = ISC_R_NOMEMORY; + goto unlock; + } + + ISC_LIST_APPEND(isc_g_appctx.on_run, event, ev_link); + + result = ISC_R_SUCCESS; + + unlock: + UNLOCK(&isc_g_appctx.lock); + + return (result); +} + +#ifndef USE_THREADS_SINGLECTX +/*! + * Event loop for nonthreaded programs. + */ +static isc_result_t +evloop(isc__appctx_t *ctx) { + isc_result_t result; + + while (!ctx->want_shutdown) { + int n; + isc_time_t when, now; + struct timeval tv, *tvp; + isc_socketwait_t *swait; + isc_boolean_t readytasks; + isc_boolean_t call_timer_dispatch = ISC_FALSE; + + /* + * Check the reload (or suspend) case first for exiting the + * loop as fast as possible in case: + * - the direct call to isc__taskmgr_dispatch() in + * isc__app_ctxrun() completes all the tasks so far, + * - there is thus currently no active task, and + * - there is a timer event + */ + if (ctx->want_reload) { + ctx->want_reload = ISC_FALSE; + return (ISC_R_RELOAD); + } + + readytasks = isc__taskmgr_ready(ctx->taskmgr); + if (readytasks) { + tv.tv_sec = 0; + tv.tv_usec = 0; + tvp = &tv; + call_timer_dispatch = ISC_TRUE; + } else { + result = isc__timermgr_nextevent(ctx->timermgr, &when); + if (result != ISC_R_SUCCESS) + tvp = NULL; + else { + isc_uint64_t us; + + TIME_NOW(&now); + us = isc_time_microdiff(&when, &now); + if (us == 0) + call_timer_dispatch = ISC_TRUE; + tv.tv_sec = us / 1000000; + tv.tv_usec = us % 1000000; + tvp = &tv; + } + } + + swait = NULL; + n = isc__socketmgr_waitevents(ctx->socketmgr, tvp, &swait); + + if (n == 0 || call_timer_dispatch) { + /* + * We call isc__timermgr_dispatch() only when + * necessary, in order to reduce overhead. If the + * select() call indicates a timeout, we need the + * dispatch. Even if not, if we set the 0-timeout + * for the select() call, we need to check the timer + * events. In the 'readytasks' case, there may be no + * timeout event actually, but there is no other way + * to reduce the overhead. + * Note that we do not have to worry about the case + * where a new timer is inserted during the select() + * call, since this loop only runs in the non-thread + * mode. + */ + isc__timermgr_dispatch(ctx->timermgr); + } + if (n > 0) + (void)isc__socketmgr_dispatch(ctx->socketmgr, swait); + (void)isc__taskmgr_dispatch(ctx->taskmgr); + } + return (ISC_R_SUCCESS); +} +#endif /* USE_THREADS_SINGLECTX */ + +#ifndef ISC_PLATFORM_USETHREADS +/* + * This is a gross hack to support waiting for condition + * variables in nonthreaded programs in a limited way; + * see lib/isc/nothreads/include/isc/condition.h. + * We implement isc_condition_wait() by entering the + * event loop recursively until the want_shutdown flag + * is set by isc_condition_signal(). + */ + +/*! + * \brief True if we are currently executing in the recursive + * event loop. + */ +static isc_boolean_t in_recursive_evloop = ISC_FALSE; + +/*! + * \brief True if we are exiting the event loop as the result of + * a call to isc_condition_signal() rather than a shutdown + * or reload. + */ +static isc_boolean_t signalled = ISC_FALSE; + +isc_result_t +isc__nothread_wait_hack(isc_condition_t *cp, isc_mutex_t *mp) { + isc_result_t result; + + UNUSED(cp); + UNUSED(mp); + + INSIST(!in_recursive_evloop); + in_recursive_evloop = ISC_TRUE; + + INSIST(*mp == 1); /* Mutex must be locked on entry. */ + --*mp; + + result = evloop(&isc_g_appctx); + if (result == ISC_R_RELOAD) + isc_g_appctx.want_reload = ISC_TRUE; + if (signalled) { + isc_g_appctx.want_shutdown = ISC_FALSE; + signalled = ISC_FALSE; + } + + ++*mp; + in_recursive_evloop = ISC_FALSE; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__nothread_signal_hack(isc_condition_t *cp) { + + UNUSED(cp); + + INSIST(in_recursive_evloop); + + isc_g_appctx.want_shutdown = ISC_TRUE; + signalled = ISC_TRUE; + return (ISC_R_SUCCESS); +} + +#endif /* ISC_PLATFORM_USETHREADS */ + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_ctxrun(isc_appctx_t *ctx0) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + int result; + isc_event_t *event, *next_event; + isc_task_t *task; +#ifdef USE_THREADS_SINGLECTX + sigset_t sset; + char strbuf[ISC_STRERRORSIZE]; +#ifdef HAVE_SIGWAIT + int sig; +#endif +#endif /* USE_THREADS_SINGLECTX */ + + REQUIRE(VALID_APPCTX(ctx)); + +#ifdef HAVE_LINUXTHREADS + REQUIRE(main_thread == pthread_self()); +#endif + + LOCK(&ctx->lock); + + if (!ctx->running) { + ctx->running = ISC_TRUE; + + /* + * Post any on-run events (in FIFO order). + */ + for (event = ISC_LIST_HEAD(ctx->on_run); + event != NULL; + event = next_event) { + next_event = ISC_LIST_NEXT(event, ev_link); + ISC_LIST_UNLINK(ctx->on_run, event, ev_link); + task = event->ev_sender; + event->ev_sender = NULL; + isc_task_sendanddetach(&task, &event); + } + + } + + UNLOCK(&ctx->lock); + +#ifndef HAVE_SIGWAIT + /* + * Catch SIGHUP. + * + * We do this here to ensure that the signal handler is installed + * (i.e. that it wasn't a "one-shot" handler). + */ + if (ctx == &isc_g_appctx) { + result = handle_signal(SIGHUP, reload_action); + if (result != ISC_R_SUCCESS) + return (ISC_R_SUCCESS); + } +#endif + +#ifdef USE_THREADS_SINGLECTX + /* + * When we are using multiple contexts, we don't rely on signals. + */ + if (ctx != &isc_g_appctx) + return (ISC_R_SUCCESS); + + /* + * There is no danger if isc_app_shutdown() is called before we wait + * for signals. Signals are blocked, so any such signal will simply + * be made pending and we will get it when we call sigwait(). + */ + + while (!ctx->want_shutdown) { +#ifdef HAVE_SIGWAIT + /* + * Wait for SIGHUP, SIGINT, or SIGTERM. + */ + if (sigemptyset(&sset) != 0 || + sigaddset(&sset, SIGHUP) != 0 || + sigaddset(&sset, SIGINT) != 0 || + sigaddset(&sset, SIGTERM) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_run() sigsetops: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + +#ifndef HAVE_UNIXWARE_SIGWAIT + result = sigwait(&sset, &sig); + if (result == 0) { + if (sig == SIGINT || sig == SIGTERM) + ctx->want_shutdown = ISC_TRUE; + else if (sig == SIGHUP) + ctx->want_reload = ISC_TRUE; + } + +#else /* Using UnixWare sigwait semantics. */ + sig = sigwait(&sset); + if (sig >= 0) { + if (sig == SIGINT || sig == SIGTERM) + ctx->want_shutdown = ISC_TRUE; + else if (sig == SIGHUP) + ctx->want_reload = ISC_TRUE; + } + +#endif /* HAVE_UNIXWARE_SIGWAIT */ +#else /* Don't have sigwait(). */ + /* + * Listen for all signals. + */ + if (sigemptyset(&sset) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_run() sigsetops: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } + result = sigsuspend(&sset); +#endif /* HAVE_SIGWAIT */ + + if (ctx->want_reload) { + ctx->want_reload = ISC_FALSE; + return (ISC_R_RELOAD); + } + + if (ctx->want_shutdown && ctx->blocked) + exit(1); + } + +#else /* USE_THREADS_SINGLECTX */ + + (void)isc__taskmgr_dispatch(ctx->taskmgr); + + result = evloop(ctx); + if (result != ISC_R_SUCCESS) + return (result); + +#endif /* USE_THREADS_SINGLECTX */ + + return (ISC_R_SUCCESS); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_run() { + return (isc__app_ctxrun((isc_appctx_t *)&isc_g_appctx)); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_ctxshutdown(isc_appctx_t *ctx0) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + isc_boolean_t want_kill = ISC_TRUE; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_APPCTX(ctx)); + + LOCK(&ctx->lock); + + REQUIRE(ctx->running); + + if (ctx->shutdown_requested) + want_kill = ISC_FALSE; + else + ctx->shutdown_requested = ISC_TRUE; + + UNLOCK(&ctx->lock); + + if (want_kill) { + if (ctx != &isc_g_appctx) + ctx->want_shutdown = ISC_TRUE; + else { +#ifdef HAVE_LINUXTHREADS + int result; + + result = pthread_kill(main_thread, SIGTERM); + if (result != 0) { + isc__strerror(result, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_shutdown() " + "pthread_kill: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } +#else + if (kill(getpid(), SIGTERM) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_shutdown() " + "kill: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif /* HAVE_LINUXTHREADS */ + } + } + + return (ISC_R_SUCCESS); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_shutdown() { + return (isc__app_ctxshutdown((isc_appctx_t *)&isc_g_appctx)); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_ctxsuspend(isc_appctx_t *ctx0) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + isc_boolean_t want_kill = ISC_TRUE; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_APPCTX(ctx)); + + LOCK(&ctx->lock); + + REQUIRE(ctx->running); + + /* + * Don't send the reload signal if we're shutting down. + */ + if (ctx->shutdown_requested) + want_kill = ISC_FALSE; + + UNLOCK(&ctx->lock); + + if (want_kill) { + if (ctx != &isc_g_appctx) + ctx->want_reload = ISC_TRUE; + else { +#ifdef HAVE_LINUXTHREADS + int result; + + result = pthread_kill(main_thread, SIGHUP); + if (result != 0) { + isc__strerror(result, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_reload() " + "pthread_kill: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } +#else + if (kill(getpid(), SIGHUP) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_app_reload() " + "kill: %s", strbuf); + return (ISC_R_UNEXPECTED); + } +#endif + } + } + + return (ISC_R_SUCCESS); +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__app_reload(void) { + return (isc__app_ctxsuspend((isc_appctx_t *)&isc_g_appctx)); +} + +ISC_APPFUNC_SCOPE void +isc__app_ctxfinish(isc_appctx_t *ctx0) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + + REQUIRE(VALID_APPCTX(ctx)); + + DESTROYLOCK(&ctx->lock); +} + +ISC_APPFUNC_SCOPE void +isc__app_finish(void) { + isc__app_ctxfinish((isc_appctx_t *)&isc_g_appctx); +} + +ISC_APPFUNC_SCOPE void +isc__app_block(void) { +#ifdef ISC_PLATFORM_USETHREADS + sigset_t sset; +#endif /* ISC_PLATFORM_USETHREADS */ + REQUIRE(isc_g_appctx.running); + REQUIRE(!isc_g_appctx.blocked); + + isc_g_appctx.blocked = ISC_TRUE; +#ifdef ISC_PLATFORM_USETHREADS + blockedthread = pthread_self(); + RUNTIME_CHECK(sigemptyset(&sset) == 0 && + sigaddset(&sset, SIGINT) == 0 && + sigaddset(&sset, SIGTERM) == 0); + RUNTIME_CHECK(pthread_sigmask(SIG_UNBLOCK, &sset, NULL) == 0); +#endif /* ISC_PLATFORM_USETHREADS */ +} + +ISC_APPFUNC_SCOPE void +isc__app_unblock(void) { +#ifdef ISC_PLATFORM_USETHREADS + sigset_t sset; +#endif /* ISC_PLATFORM_USETHREADS */ + + REQUIRE(isc_g_appctx.running); + REQUIRE(isc_g_appctx.blocked); + + isc_g_appctx.blocked = ISC_FALSE; + +#ifdef ISC_PLATFORM_USETHREADS + REQUIRE(blockedthread == pthread_self()); + + RUNTIME_CHECK(sigemptyset(&sset) == 0 && + sigaddset(&sset, SIGINT) == 0 && + sigaddset(&sset, SIGTERM) == 0); + RUNTIME_CHECK(pthread_sigmask(SIG_BLOCK, &sset, NULL) == 0); +#endif /* ISC_PLATFORM_USETHREADS */ +} + +ISC_APPFUNC_SCOPE isc_result_t +isc__appctx_create(isc_mem_t *mctx, isc_appctx_t **ctxp) { + isc__appctx_t *ctx; + + REQUIRE(mctx != NULL); + REQUIRE(ctxp != NULL && *ctxp == NULL); + + ctx = isc_mem_get(mctx, sizeof(*ctx)); + if (ctx == NULL) + return (ISC_R_NOMEMORY); + + ctx->common.impmagic = APPCTX_MAGIC; + ctx->common.magic = ISCAPI_APPCTX_MAGIC; + ctx->common.methods = &appmethods.methods; + + ctx->mctx = NULL; + isc_mem_attach(mctx, &ctx->mctx); + + ctx->taskmgr = NULL; + ctx->socketmgr = NULL; + ctx->timermgr = NULL; + + *ctxp = (isc_appctx_t *)ctx; + + return (ISC_R_SUCCESS); +} + +ISC_APPFUNC_SCOPE void +isc__appctx_destroy(isc_appctx_t **ctxp) { + isc__appctx_t *ctx; + + REQUIRE(ctxp != NULL); + ctx = (isc__appctx_t *)*ctxp; + REQUIRE(VALID_APPCTX(ctx)); + + isc_mem_putanddetach(&ctx->mctx, ctx, sizeof(*ctx)); + + *ctxp = NULL; +} + +ISC_APPFUNC_SCOPE void +isc__appctx_settaskmgr(isc_appctx_t *ctx0, isc_taskmgr_t *taskmgr) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + + REQUIRE(VALID_APPCTX(ctx)); + + ctx->taskmgr = taskmgr; +} + +ISC_APPFUNC_SCOPE void +isc__appctx_setsocketmgr(isc_appctx_t *ctx0, isc_socketmgr_t *socketmgr) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + + REQUIRE(VALID_APPCTX(ctx)); + + ctx->socketmgr = socketmgr; +} + +ISC_APPFUNC_SCOPE void +isc__appctx_settimermgr(isc_appctx_t *ctx0, isc_timermgr_t *timermgr) { + isc__appctx_t *ctx = (isc__appctx_t *)ctx0; + + REQUIRE(VALID_APPCTX(ctx)); + + ctx->timermgr = timermgr; +} + +#ifdef USE_APPIMPREGISTER +isc_result_t +isc__app_register() { + return (isc_app_register(isc__appctx_create)); +} +#endif diff --git a/contrib/ntp/lib/isc/unix/dir.c b/contrib/ntp/lib/isc/unix/dir.c new file mode 100644 index 000000000..613ee5630 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/dir.c @@ -0,0 +1,256 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file + * \author Principal Authors: DCL */ + +#include + +#include +#include + +#include +#include +#include + +#include +#include +#include +#include + +#include "errno2result.h" +#include "ntp_stdlib.h" /* NTP change for strlcpy, strlcat */ + +#define ISC_DIR_MAGIC ISC_MAGIC('D', 'I', 'R', '*') +#define VALID_DIR(dir) ISC_MAGIC_VALID(dir, ISC_DIR_MAGIC) + +void +isc_dir_init(isc_dir_t *dir) { + REQUIRE(dir != NULL); + + dir->entry.name[0] = '\0'; + dir->entry.length = 0; + + dir->handle = NULL; + + dir->magic = ISC_DIR_MAGIC; +} + +/*! + * \brief Allocate workspace and open directory stream. If either one fails, + * NULL will be returned. + */ +isc_result_t +isc_dir_open(isc_dir_t *dir, const char *dirname) { + char *p; + size_t octets; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(VALID_DIR(dir)); + REQUIRE(dirname != NULL); + + /* + * Copy directory name. Need to have enough space for the name, + * a possible path separator, the wildcard, and the final NUL. + */ + octets = strlen(dirname) + 1; + if (octets + 2 > sizeof(dir->dirname)) + /* XXXDCL ? */ + return (ISC_R_NOSPACE); + strlcpy(dir->dirname, dirname, octets); + + /* + * Append path separator, if needed, and "*". + */ + p = dir->dirname + strlen(dir->dirname); + if (dir->dirname < p && *(p - 1) != '/') + *p++ = '/'; + *p++ = '*'; + *p = '\0'; + + /* + * Open stream. + */ + dir->handle = opendir(dirname); + + if (dir->handle == NULL) + return isc__errno2result(errno); + + return (result); +} + +/*! + * \brief Return previously retrieved file or get next one. + + * Unix's dirent has + * separate open and read functions, but the Win32 and DOS interfaces open + * the dir stream and reads the first file in one operation. + */ +isc_result_t +isc_dir_read(isc_dir_t *dir) { + struct dirent *entry; + size_t octets; + + REQUIRE(VALID_DIR(dir) && dir->handle != NULL); + + /* + * Fetch next file in directory. + */ + entry = readdir(dir->handle); + + if (entry == NULL) + return (ISC_R_NOMORE); + + /* + * Make sure that the space for the name is long enough. + */ + octets = strlen(entry->d_name) + 1; + if (sizeof(dir->entry.name) < octets) + return (ISC_R_UNEXPECTED); + + strlcpy(dir->entry.name, entry->d_name, octets); + + /* + * Some dirents have d_namlen, but it is not portable. + */ + dir->entry.length = strlen(entry->d_name); + + return (ISC_R_SUCCESS); +} + +/*! + * \brief Close directory stream. + */ +void +isc_dir_close(isc_dir_t *dir) { + REQUIRE(VALID_DIR(dir) && dir->handle != NULL); + + (void)closedir(dir->handle); + dir->handle = NULL; +} + +/*! + * \brief Reposition directory stream at start. + */ +isc_result_t +isc_dir_reset(isc_dir_t *dir) { + REQUIRE(VALID_DIR(dir) && dir->handle != NULL); + + rewinddir(dir->handle); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_dir_chdir(const char *dirname) { + /*! + * \brief Change the current directory to 'dirname'. + */ + + REQUIRE(dirname != NULL); + + if (chdir(dirname) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_dir_chroot(const char *dirname) { + + REQUIRE(dirname != NULL); + +#ifdef HAVE_CHROOT + if (chroot(dirname) < 0 || chdir("/") < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +#else + return (ISC_R_NOTIMPLEMENTED); +#endif +} + +isc_result_t +isc_dir_createunique(char *templet) { + isc_result_t result; + char *x; + char *p; + int i; + int pid; + + REQUIRE(templet != NULL); + + /*! + * \brief mkdtemp is not portable, so this emulates it. + */ + + pid = getpid(); + + /* + * Replace trailing Xs with the process-id, zero-filled. + */ + for (x = templet + strlen(templet) - 1; *x == 'X' && x >= templet; + x--, pid /= 10) + *x = pid % 10 + '0'; + + x++; /* Set x to start of ex-Xs. */ + + do { + i = mkdir(templet, 0700); + if (i == 0 || errno != EEXIST) + break; + + /* + * The BSD algorithm. + */ + p = x; + while (*p != '\0') { + if (isdigit(*p & 0xff)) + *p = 'a'; + else if (*p != 'z') + ++*p; + else { + /* + * Reset character and move to next. + */ + *p++ = 'a'; + continue; + } + + break; + } + + if (*p == '\0') { + /* + * Tried all combinations. errno should already + * be EEXIST, but ensure it is anyway for + * isc__errno2result(). + */ + errno = EEXIST; + break; + } + } while (1); + + if (i == -1) + result = isc__errno2result(errno); + else + result = ISC_R_SUCCESS; + + return (result); +} diff --git a/contrib/ntp/lib/isc/unix/entropy.c b/contrib/ntp/lib/isc/unix/entropy.c new file mode 100644 index 000000000..ab53faf67 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/entropy.c @@ -0,0 +1,605 @@ +/* + * Copyright (C) 2004-2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: entropy.c,v 1.82 2008/12/01 23:47:45 tbox Exp $ */ + +/* \file unix/entropy.c + * \brief + * This is the system dependent part of the ISC entropy API. + */ + +#include + +#include /* Openserver 5.0.6A and FD_SETSIZE */ +#include +#include +#include +#include +#include + +#ifdef HAVE_NANOSLEEP +#include +#endif +#include + +#include +#include + +#ifdef ISC_PLATFORM_NEEDSYSSELECTH +#include +#endif + +#include "errno2result.h" + +/*% + * There is only one variable in the entropy data structures that is not + * system independent, but pulling the structure that uses it into this file + * ultimately means pulling several other independent structures here also to + * resolve their interdependencies. Thus only the problem variable's type + * is defined here. + */ +#define FILESOURCE_HANDLE_TYPE int + +typedef struct { + int handle; + enum { + isc_usocketsource_disconnected, + isc_usocketsource_connecting, + isc_usocketsource_connected, + isc_usocketsource_ndesired, + isc_usocketsource_wrote, + isc_usocketsource_reading + } status; + size_t sz_to_recv; +} isc_entropyusocketsource_t; + +#include "../entropy.c" + +static unsigned int +get_from_filesource(isc_entropysource_t *source, isc_uint32_t desired) { + isc_entropy_t *ent = source->ent; + unsigned char buf[128]; + int fd = source->sources.file.handle; + ssize_t n, ndesired; + unsigned int added; + + if (source->bad) + return (0); + + desired = desired / 8 + (((desired & 0x07) > 0) ? 1 : 0); + + added = 0; + while (desired > 0) { + ndesired = ISC_MIN(desired, sizeof(buf)); + n = read(fd, buf, ndesired); + if (n < 0) { + if (errno == EAGAIN || errno == EINTR) + goto out; + goto err; + } + if (n == 0) + goto err; + + entropypool_adddata(ent, buf, n, n * 8); + added += n * 8; + desired -= n; + } + goto out; + + err: + (void)close(fd); + source->sources.file.handle = -1; + source->bad = ISC_TRUE; + + out: + return (added); +} + +static unsigned int +get_from_usocketsource(isc_entropysource_t *source, isc_uint32_t desired) { + isc_entropy_t *ent = source->ent; + unsigned char buf[128]; + int fd = source->sources.usocket.handle; + ssize_t n = 0, ndesired; + unsigned int added; + size_t sz_to_recv = source->sources.usocket.sz_to_recv; + + if (source->bad) + return (0); + + desired = desired / 8 + (((desired & 0x07) > 0) ? 1 : 0); + + added = 0; + while (desired > 0) { + ndesired = ISC_MIN(desired, sizeof(buf)); + eagain_loop: + + switch ( source->sources.usocket.status ) { + case isc_usocketsource_ndesired: + buf[0] = ndesired; + if ((n = sendto(fd, buf, 1, 0, NULL, 0)) < 0) { + if (errno == EWOULDBLOCK || errno == EINTR || + errno == ECONNRESET) + goto out; + goto err; + } + INSIST(n == 1); + source->sources.usocket.status = + isc_usocketsource_wrote; + goto eagain_loop; + + case isc_usocketsource_connecting: + case isc_usocketsource_connected: + buf[0] = 1; + buf[1] = ndesired; + if ((n = sendto(fd, buf, 2, 0, NULL, 0)) < 0) { + if (errno == EWOULDBLOCK || errno == EINTR || + errno == ECONNRESET) + goto out; + goto err; + } + if (n == 1) { + source->sources.usocket.status = + isc_usocketsource_ndesired; + goto eagain_loop; + } + INSIST(n == 2); + source->sources.usocket.status = + isc_usocketsource_wrote; + /*FALLTHROUGH*/ + + case isc_usocketsource_wrote: + if (recvfrom(fd, buf, 1, 0, NULL, NULL) != 1) { + if (errno == EAGAIN) { + /* + * The problem of EAGAIN (try again + * later) is a major issue on HP-UX. + * Solaris actually tries the recvfrom + * call again, while HP-UX just dies. + * This code is an attempt to let the + * entropy pool fill back up (at least + * that's what I think the problem is.) + * We go to eagain_loop because if we + * just "break", then the "desired" + * amount gets borked. + */ +#ifdef HAVE_NANOSLEEP + struct timespec ts; + + ts.tv_sec = 0; + ts.tv_nsec = 1000000; + nanosleep(&ts, NULL); +#else + usleep(1000); +#endif + goto eagain_loop; + } + if (errno == EWOULDBLOCK || errno == EINTR) + goto out; + goto err; + } + source->sources.usocket.status = + isc_usocketsource_reading; + sz_to_recv = buf[0]; + source->sources.usocket.sz_to_recv = sz_to_recv; + if (sz_to_recv > sizeof(buf)) + goto err; + /*FALLTHROUGH*/ + + case isc_usocketsource_reading: + if (sz_to_recv != 0U) { + n = recv(fd, buf, sz_to_recv, 0); + if (n < 0) { + if (errno == EWOULDBLOCK || + errno == EINTR) + goto out; + goto err; + } + } else + n = 0; + break; + + default: + goto err; + } + + if ((size_t)n != sz_to_recv) + source->sources.usocket.sz_to_recv -= n; + else + source->sources.usocket.status = + isc_usocketsource_connected; + + if (n == 0) + goto out; + + entropypool_adddata(ent, buf, n, n * 8); + added += n * 8; + desired -= n; + } + goto out; + + err: + close(fd); + source->bad = ISC_TRUE; + source->sources.usocket.status = isc_usocketsource_disconnected; + source->sources.usocket.handle = -1; + + out: + return (added); +} + +/* + * Poll each source, trying to get data from it to stuff into the entropy + * pool. + */ +static void +fillpool(isc_entropy_t *ent, unsigned int desired, isc_boolean_t blocking) { + unsigned int added; + unsigned int remaining; + unsigned int needed; + unsigned int nsource; + isc_entropysource_t *source; + + REQUIRE(VALID_ENTROPY(ent)); + + needed = desired; + + /* + * This logic is a little strange, so an explanation is in order. + * + * If needed is 0, it means we are being asked to "fill to whatever + * we think is best." This means that if we have at least a + * partially full pool (say, > 1/4th of the pool) we probably don't + * need to add anything. + * + * Also, we will check to see if the "pseudo" count is too high. + * If it is, try to mix in better data. Too high is currently + * defined as 1/4th of the pool. + * + * Next, if we are asked to add a specific bit of entropy, make + * certain that we will do so. Clamp how much we try to add to + * (DIGEST_SIZE * 8 < needed < POOLBITS - entropy). + * + * Note that if we are in a blocking mode, we will only try to + * get as much data as we need, not as much as we might want + * to build up. + */ + if (needed == 0) { + REQUIRE(!blocking); + + if ((ent->pool.entropy >= RND_POOLBITS / 4) + && (ent->pool.pseudo <= RND_POOLBITS / 4)) + return; + + needed = THRESHOLD_BITS * 4; + } else { + needed = ISC_MAX(needed, THRESHOLD_BITS); + needed = ISC_MIN(needed, RND_POOLBITS); + } + + /* + * In any case, clamp how much we need to how much we can add. + */ + needed = ISC_MIN(needed, RND_POOLBITS - ent->pool.entropy); + + /* + * But wait! If we're not yet initialized, we need at least + * THRESHOLD_BITS + * of randomness. + */ + if (ent->initialized < THRESHOLD_BITS) + needed = ISC_MAX(needed, THRESHOLD_BITS - ent->initialized); + + /* + * Poll each file source to see if we can read anything useful from + * it. XXXMLG When where are multiple sources, we should keep a + * record of which one we last used so we can start from it (or the + * next one) to avoid letting some sources build up entropy while + * others are always drained. + */ + + added = 0; + remaining = needed; + if (ent->nextsource == NULL) { + ent->nextsource = ISC_LIST_HEAD(ent->sources); + if (ent->nextsource == NULL) + return; + } + source = ent->nextsource; + again_file: + for (nsource = 0; nsource < ent->nsources; nsource++) { + unsigned int got; + + if (remaining == 0) + break; + + got = 0; + + switch ( source->type ) { + case ENTROPY_SOURCETYPE_FILE: + got = get_from_filesource(source, remaining); + break; + + case ENTROPY_SOURCETYPE_USOCKET: + got = get_from_usocketsource(source, remaining); + break; + } + + added += got; + + remaining -= ISC_MIN(remaining, got); + + source = ISC_LIST_NEXT(source, link); + if (source == NULL) + source = ISC_LIST_HEAD(ent->sources); + } + ent->nextsource = source; + + if (blocking && remaining != 0) { + int fds; + + fds = wait_for_sources(ent); + if (fds > 0) + goto again_file; + } + + /* + * Here, if there are bits remaining to be had and we can block, + * check to see if we have a callback source. If so, call them. + */ + source = ISC_LIST_HEAD(ent->sources); + while ((remaining != 0) && (source != NULL)) { + unsigned int got; + + got = 0; + + if (source->type == ENTROPY_SOURCETYPE_CALLBACK) + got = get_from_callback(source, remaining, blocking); + + added += got; + remaining -= ISC_MIN(remaining, got); + + if (added >= needed) + break; + + source = ISC_LIST_NEXT(source, link); + } + + /* + * Mark as initialized if we've added enough data. + */ + if (ent->initialized < THRESHOLD_BITS) + ent->initialized += added; +} + +static int +wait_for_sources(isc_entropy_t *ent) { + isc_entropysource_t *source; + int maxfd, fd; + int cc; + fd_set reads; + fd_set writes; + + maxfd = -1; + FD_ZERO(&reads); + FD_ZERO(&writes); + + source = ISC_LIST_HEAD(ent->sources); + while (source != NULL) { + if (source->type == ENTROPY_SOURCETYPE_FILE) { + fd = source->sources.file.handle; + if (fd >= 0) { + maxfd = ISC_MAX(maxfd, fd); + FD_SET(fd, &reads); + } + } + if (source->type == ENTROPY_SOURCETYPE_USOCKET) { + fd = source->sources.usocket.handle; + if (fd >= 0) { + switch (source->sources.usocket.status) { + case isc_usocketsource_disconnected: + break; + case isc_usocketsource_connecting: + case isc_usocketsource_connected: + case isc_usocketsource_ndesired: + maxfd = ISC_MAX(maxfd, fd); + FD_SET(fd, &writes); + break; + case isc_usocketsource_wrote: + case isc_usocketsource_reading: + maxfd = ISC_MAX(maxfd, fd); + FD_SET(fd, &reads); + break; + } + } + } + source = ISC_LIST_NEXT(source, link); + } + + if (maxfd < 0) + return (-1); + + cc = select(maxfd + 1, &reads, &writes, NULL, NULL); + if (cc < 0) + return (-1); + + return (cc); +} + +static void +destroyfilesource(isc_entropyfilesource_t *source) { + (void)close(source->handle); +} + +static void +destroyusocketsource(isc_entropyusocketsource_t *source) { + close(source->handle); +} + +/* + * Make a fd non-blocking + */ +static isc_result_t +make_nonblock(int fd) { + int ret; + int flags; + char strbuf[ISC_STRERRORSIZE]; +#ifdef USE_FIONBIO_IOCTL + int on = 1; + + ret = ioctl(fd, FIONBIO, (char *)&on); +#else + flags = fcntl(fd, F_GETFL, 0); + flags |= PORT_NONBLOCK; + ret = fcntl(fd, F_SETFL, flags); +#endif + + if (ret == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, +#ifdef USE_FIONBIO_IOCTL + "ioctl(%d, FIONBIO, &on): %s", fd, +#else + "fcntl(%d, F_SETFL, %d): %s", fd, flags, +#endif + strbuf); + + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_entropy_createfilesource(isc_entropy_t *ent, const char *fname) { + int fd; + struct stat _stat; + isc_boolean_t is_usocket = ISC_FALSE; + isc_boolean_t is_connected = ISC_FALSE; + isc_result_t ret; + isc_entropysource_t *source; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(fname != NULL); + + LOCK(&ent->lock); + + if (stat(fname, &_stat) < 0) { + ret = isc__errno2result(errno); + goto errout; + } + /* + * Solaris 2.5.1 does not have support for sockets (S_IFSOCK), + * but it does return type S_IFIFO (the OS believes that + * the socket is a fifo). This may be an issue if we tell + * the program to look at an actual FIFO as its source of + * entropy. + */ +#if defined(S_ISSOCK) + if (S_ISSOCK(_stat.st_mode)) + is_usocket = ISC_TRUE; +#endif +#if defined(S_ISFIFO) && defined(sun) + if (S_ISFIFO(_stat.st_mode)) + is_usocket = ISC_TRUE; +#endif + if (is_usocket) + fd = socket(PF_UNIX, SOCK_STREAM, 0); + else + fd = open(fname, O_RDONLY | PORT_NONBLOCK, 0); + + if (fd < 0) { + ret = isc__errno2result(errno); + goto errout; + } + + ret = make_nonblock(fd); + if (ret != ISC_R_SUCCESS) + goto closefd; + + if (is_usocket) { + struct sockaddr_un sname; + + memset(&sname, 0, sizeof(sname)); + sname.sun_family = AF_UNIX; + strncpy(sname.sun_path, fname, sizeof(sname.sun_path)); + sname.sun_path[sizeof(sname.sun_path)-1] = '0'; +#ifdef ISC_PLATFORM_HAVESALEN +#if !defined(SUN_LEN) +#define SUN_LEN(su) \ + (sizeof(*(su)) - sizeof((su)->sun_path) + strlen((su)->sun_path)) +#endif + sname.sun_len = SUN_LEN(&sname); +#endif + + if (connect(fd, (struct sockaddr *) &sname, + sizeof(struct sockaddr_un)) < 0) { + if (errno != EINPROGRESS) { + ret = isc__errno2result(errno); + goto closefd; + } + } else + is_connected = ISC_TRUE; + } + + source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t)); + if (source == NULL) { + ret = ISC_R_NOMEMORY; + goto closefd; + } + + /* + * From here down, no failures can occur. + */ + source->magic = SOURCE_MAGIC; + source->ent = ent; + source->total = 0; + source->bad = ISC_FALSE; + memset(source->name, 0, sizeof(source->name)); + ISC_LINK_INIT(source, link); + if (is_usocket) { + source->sources.usocket.handle = fd; + if (is_connected) + source->sources.usocket.status = + isc_usocketsource_connected; + else + source->sources.usocket.status = + isc_usocketsource_connecting; + source->sources.usocket.sz_to_recv = 0; + source->type = ENTROPY_SOURCETYPE_USOCKET; + } else { + source->sources.file.handle = fd; + source->type = ENTROPY_SOURCETYPE_FILE; + } + + /* + * Hook it into the entropy system. + */ + ISC_LIST_APPEND(ent->sources, source, link); + ent->nsources++; + + UNLOCK(&ent->lock); + return (ISC_R_SUCCESS); + + closefd: + (void)close(fd); + + errout: + UNLOCK(&ent->lock); + + return (ret); +} diff --git a/contrib/ntp/lib/isc/unix/errno2result.c b/contrib/ntp/lib/isc/unix/errno2result.c new file mode 100644 index 000000000..f20aa295c --- /dev/null +++ b/contrib/ntp/lib/isc/unix/errno2result.c @@ -0,0 +1,122 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include + +#include "errno2result.h" + +/*% + * Convert a POSIX errno value into an isc_result_t. The + * list of supported errno values is not complete; new users + * of this function should add any expected errors that are + * not already there. + */ +isc_result_t +isc___errno2result(int posixerrno, const char *file, unsigned int line) { + char strbuf[ISC_STRERRORSIZE]; + + switch (posixerrno) { + case ENOTDIR: + case ELOOP: + case EINVAL: /* XXX sometimes this is not for files */ + case ENAMETOOLONG: + case EBADF: + return (ISC_R_INVALIDFILE); + case ENOENT: + return (ISC_R_FILENOTFOUND); + case EACCES: + case EPERM: + return (ISC_R_NOPERM); + case EEXIST: + return (ISC_R_FILEEXISTS); + case EIO: + return (ISC_R_IOERROR); + case ENOMEM: + return (ISC_R_NOMEMORY); + case ENFILE: + case EMFILE: + return (ISC_R_TOOMANYOPENFILES); + case EPIPE: +#ifdef ECONNRESET + case ECONNRESET: +#endif +#ifdef ECONNABORTED + case ECONNABORTED: +#endif + return (ISC_R_CONNECTIONRESET); +#ifdef ENOTCONN + case ENOTCONN: + return (ISC_R_NOTCONNECTED); +#endif +#ifdef ETIMEDOUT + case ETIMEDOUT: + return (ISC_R_TIMEDOUT); +#endif +#ifdef ENOBUFS + case ENOBUFS: + return (ISC_R_NORESOURCES); +#endif +#ifdef EAFNOSUPPORT + case EAFNOSUPPORT: + return (ISC_R_FAMILYNOSUPPORT); +#endif +#ifdef ENETDOWN + case ENETDOWN: + return (ISC_R_NETDOWN); +#endif +#ifdef EHOSTDOWN + case EHOSTDOWN: + return (ISC_R_HOSTDOWN); +#endif +#ifdef ENETUNREACH + case ENETUNREACH: + return (ISC_R_NETUNREACH); +#endif +#ifdef EHOSTUNREACH + case EHOSTUNREACH: + return (ISC_R_HOSTUNREACH); +#endif +#ifdef EADDRINUSE + case EADDRINUSE: + return (ISC_R_ADDRINUSE); +#endif + case EADDRNOTAVAIL: + return (ISC_R_ADDRNOTAVAIL); + case ECONNREFUSED: + return (ISC_R_CONNREFUSED); + default: + isc__strerror(posixerrno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(file, line, "unable to convert errno " + "to isc_result: %d: %s", + posixerrno, strbuf); + /* + * XXXDCL would be nice if perhaps this function could + * return the system's error string, so the caller + * might have something more descriptive than "unexpected + * error" to log with. + */ + return (ISC_R_UNEXPECTED); + } +} diff --git a/contrib/ntp/lib/isc/unix/errno2result.h b/contrib/ntp/lib/isc/unix/errno2result.h new file mode 100644 index 000000000..1e49ed1d6 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/errno2result.h @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef UNIX_ERRNO2RESULT_H +#define UNIX_ERRNO2RESULT_H 1 + +/*! \file */ + +/* XXXDCL this should be moved to lib/isc/include/isc/errno2result.h. */ + +#include /* Provides errno. */ + +#include +#include + +ISC_LANG_BEGINDECLS + +#define isc__errno2result(x) isc___errno2result(x, __FILE__, __LINE__) + +isc_result_t +isc___errno2result(int posixerrno, const char *file, unsigned int line); + +ISC_LANG_ENDDECLS + +#endif /* UNIX_ERRNO2RESULT_H */ diff --git a/contrib/ntp/lib/isc/unix/file.c b/contrib/ntp/lib/isc/unix/file.c new file mode 100644 index 000000000..9eda4a33b --- /dev/null +++ b/contrib/ntp/lib/isc/unix/file.c @@ -0,0 +1,544 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Portions Copyright (c) 1987, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include /* Required for utimes on some platforms. */ +#include /* Required for mkstemp on NetBSD. */ + + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "errno2result.h" +#include "ntp_stdlib.h" /* NTP change for strlcpy, strlcat */ + +/* + * XXXDCL As the API for accessing file statistics undoubtedly gets expanded, + * it might be good to provide a mechanism that allows for the results + * of a previous stat() to be used again without having to do another stat, + * such as perl's mechanism of using "_" in place of a file name to indicate + * that the results of the last stat should be used. But then you get into + * annoying MP issues. BTW, Win32 has stat(). + */ +static isc_result_t +file_stats(const char *file, struct stat *stats) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(file != NULL); + REQUIRE(stats != NULL); + + if (stat(file, stats) != 0) + result = isc__errno2result(errno); + + return (result); +} + +isc_result_t +isc_file_getmodtime(const char *file, isc_time_t *itime) { + isc_result_t result; + struct stat stats; + + REQUIRE(file != NULL); + REQUIRE(itime != NULL); + + result = file_stats(file, &stats); + + if (result == ISC_R_SUCCESS) + /* + * XXXDCL some operating systems provide nanoseconds, too, + * such as BSD/OS via st_mtimespec. + */ + isc_time_set(itime, stats.st_mtime, 0); + + return (result); +} + +isc_result_t +isc_file_settime(const char *file, isc_time_t *itime) { + struct timeval times[2]; + + REQUIRE(file != NULL && itime != NULL); + + /* + * tv_sec is at least a 32 bit quantity on all platforms we're + * dealing with, but it is signed on most (all?) of them, + * so we need to make sure the high bit isn't set. This unfortunately + * loses when either: + * * tv_sec becomes a signed 64 bit integer but long is 32 bits + * and isc_time_seconds > LONG_MAX, or + * * isc_time_seconds is changed to be > 32 bits but long is 32 bits + * and isc_time_seconds has at least 33 significant bits. + */ + times[0].tv_sec = times[1].tv_sec = (long)isc_time_seconds(itime); + + /* + * Here is the real check for the high bit being set. + */ + if ((times[0].tv_sec & + (1ULL << (sizeof(times[0].tv_sec) * CHAR_BIT - 1))) != 0) + return (ISC_R_RANGE); + + /* + * isc_time_nanoseconds guarantees a value that divided by 1000 will + * fit into the minimum possible size tv_usec field. Unfortunately, + * we don't know what that type is so can't cast directly ... but + * we can at least cast to signed so the IRIX compiler shuts up. + */ + times[0].tv_usec = times[1].tv_usec = + (isc_int32_t)(isc_time_nanoseconds(itime) / 1000); + + if (utimes(file, times) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} + +#undef TEMPLATE +#define TEMPLATE "tmp-XXXXXXXXXX" /*%< 14 characters. */ + +isc_result_t +isc_file_mktemplate(const char *path, char *buf, size_t buflen) { + return (isc_file_template(path, TEMPLATE, buf, buflen)); +} + +isc_result_t +isc_file_template(const char *path, const char *templet, char *buf, + size_t buflen) { + char *s; + + REQUIRE(path != NULL); + REQUIRE(templet != NULL); + REQUIRE(buf != NULL); + + s = strrchr(templet, '/'); + if (s != NULL) + templet = s + 1; + + s = strrchr(path, '/'); + + if (s != NULL) { + if ((s - path + 1 + strlen(templet) + 1) > buflen) + return (ISC_R_NOSPACE); + + strlcpy(buf, path, buflen); + buf[s - path + 1] = '\0'; + strlcat(buf, templet, buflen); + } else { + if ((strlen(templet) + 1) > buflen) + return (ISC_R_NOSPACE); + + strlcpy(buf, templet, buflen); + } + + return (ISC_R_SUCCESS); +} + +static char alphnum[] = + "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; + +isc_result_t +isc_file_renameunique(const char *file, char *templet) { + char *x; + char *cp; + isc_uint32_t which; + + REQUIRE(file != NULL); + REQUIRE(templet != NULL); + + cp = templet; + while (*cp != '\0') + cp++; + if (cp == templet) + return (ISC_R_FAILURE); + + x = cp--; + while (cp >= templet && *cp == 'X') { + isc_random_get(&which); + *cp = alphnum[which % (sizeof(alphnum) - 1)]; + x = cp--; + } + while (link(file, templet) == -1) { + if (errno != EEXIST) + return (isc__errno2result(errno)); + for (cp = x;;) { + char *t; + if (*cp == '\0') + return (ISC_R_FAILURE); + t = strchr(alphnum, *cp); + if (t == NULL || *++t == '\0') + *cp++ = alphnum[0]; + else { + *cp = *t; + break; + } + } + } + if (unlink(file) < 0) + if (errno != ENOENT) + return (isc__errno2result(errno)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_openunique(char *templet, FILE **fp) { + int mode = S_IWUSR|S_IRUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH; + return (isc_file_openuniquemode(templet, mode, fp)); +} + +isc_result_t +isc_file_openuniqueprivate(char *templet, FILE **fp) { + int mode = S_IWUSR|S_IRUSR; + return (isc_file_openuniquemode(templet, mode, fp)); +} + +isc_result_t +isc_file_openuniquemode(char *templet, int mode, FILE **fp) { + int fd; + FILE *f; + isc_result_t result = ISC_R_SUCCESS; + char *x; + char *cp; + isc_uint32_t which; + + REQUIRE(templet != NULL); + REQUIRE(fp != NULL && *fp == NULL); + + cp = templet; + while (*cp != '\0') + cp++; + if (cp == templet) + return (ISC_R_FAILURE); + + x = cp--; + while (cp >= templet && *cp == 'X') { + isc_random_get(&which); + *cp = alphnum[which % (sizeof(alphnum) - 1)]; + x = cp--; + } + + + while ((fd = open(templet, O_RDWR|O_CREAT|O_EXCL, mode)) == -1) { + if (errno != EEXIST) + return (isc__errno2result(errno)); + for (cp = x;;) { + char *t; + if (*cp == '\0') + return (ISC_R_FAILURE); + t = strchr(alphnum, *cp); + if (t == NULL || *++t == '\0') + *cp++ = alphnum[0]; + else { + *cp = *t; + break; + } + } + } + f = fdopen(fd, "w+"); + if (f == NULL) { + result = isc__errno2result(errno); + if (remove(templet) < 0) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_FILE, ISC_LOG_ERROR, + "remove '%s': failed", templet); + } + (void)close(fd); + } else + *fp = f; + + return (result); +} + +isc_result_t +isc_file_remove(const char *filename) { + int r; + + REQUIRE(filename != NULL); + + r = unlink(filename); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_file_rename(const char *oldname, const char *newname) { + int r; + + REQUIRE(oldname != NULL); + REQUIRE(newname != NULL); + + r = rename(oldname, newname); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_boolean_t +isc_file_exists(const char *pathname) { + struct stat stats; + + REQUIRE(pathname != NULL); + + return (ISC_TF(file_stats(pathname, &stats) == ISC_R_SUCCESS)); +} + +isc_result_t +isc_file_isplainfile(const char *filename) { + /* + * This function returns success if filename is a plain file. + */ + struct stat filestat; + memset(&filestat,0,sizeof(struct stat)); + + if ((stat(filename, &filestat)) == -1) + return(isc__errno2result(errno)); + + if(! S_ISREG(filestat.st_mode)) + return(ISC_R_INVALIDFILE); + + return(ISC_R_SUCCESS); +} + +isc_boolean_t +isc_file_isabsolute(const char *filename) { + REQUIRE(filename != NULL); + return (ISC_TF(filename[0] == '/')); +} + +isc_boolean_t +isc_file_iscurrentdir(const char *filename) { + REQUIRE(filename != NULL); + return (ISC_TF(filename[0] == '.' && filename[1] == '\0')); +} + +isc_boolean_t +isc_file_ischdiridempotent(const char *filename) { + REQUIRE(filename != NULL); + if (isc_file_isabsolute(filename)) + return (ISC_TRUE); + if (isc_file_iscurrentdir(filename)) + return (ISC_TRUE); + return (ISC_FALSE); +} + +const char * +isc_file_basename(const char *filename) { + char *s; + + REQUIRE(filename != NULL); + + s = strrchr(filename, '/'); + if (s == NULL) + return (filename); + + return (s + 1); +} + +isc_result_t +isc_file_progname(const char *filename, char *buf, size_t buflen) { + const char *base; + size_t len; + + REQUIRE(filename != NULL); + REQUIRE(buf != NULL); + + base = isc_file_basename(filename); + len = strlen(base) + 1; + + if (len > buflen) + return (ISC_R_NOSPACE); + memcpy(buf, base, len); + + return (ISC_R_SUCCESS); +} + +/* + * Put the absolute name of the current directory into 'dirname', which is + * a buffer of at least 'length' characters. End the string with the + * appropriate path separator, such that the final product could be + * concatenated with a relative pathname to make a valid pathname string. + */ +static isc_result_t +dir_current(char *dirname, size_t length) { + char *cwd; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(dirname != NULL); + REQUIRE(length > 0U); + + cwd = getcwd(dirname, length); + + if (cwd == NULL) { + if (errno == ERANGE) + result = ISC_R_NOSPACE; + else + result = isc__errno2result(errno); + } else { + if (strlen(dirname) + 1 == length) + result = ISC_R_NOSPACE; + else if (dirname[1] != '\0') + strlcat(dirname, "/", length); + } + + return (result); +} + +isc_result_t +isc_file_absolutepath(const char *filename, char *path, size_t pathlen) { + isc_result_t result; + result = dir_current(path, pathlen); + if (result != ISC_R_SUCCESS) + return (result); + if (strlen(path) + strlen(filename) + 1 > pathlen) + return (ISC_R_NOSPACE); + strlcat(path, filename, pathlen); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_truncate(const char *filename, isc_offset_t size) { + isc_result_t result = ISC_R_SUCCESS; + + if (truncate(filename, size) < 0) + result = isc__errno2result(errno); + return (result); +} + +isc_result_t +isc_file_safecreate(const char *filename, FILE **fp) { + isc_result_t result; + int flags; + struct stat sb; + FILE *f; + int fd; + + REQUIRE(filename != NULL); + REQUIRE(fp != NULL && *fp == NULL); + + result = file_stats(filename, &sb); + if (result == ISC_R_SUCCESS) { + if ((sb.st_mode & S_IFREG) == 0) + return (ISC_R_INVALIDFILE); + flags = O_WRONLY | O_TRUNC; + } else if (result == ISC_R_FILENOTFOUND) { + flags = O_WRONLY | O_CREAT | O_EXCL; + } else + return (result); + + fd = open(filename, flags, S_IRUSR | S_IWUSR); + if (fd == -1) + return (isc__errno2result(errno)); + + f = fdopen(fd, "w"); + if (f == NULL) { + result = isc__errno2result(errno); + close(fd); + return (result); + } + + *fp = f; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_splitpath(isc_mem_t *mctx, char *path, char **dirnam, char **basenam) +{ + char *dir, *file, *slash; + + REQUIRE(path != NULL); + + slash = strrchr(path, '/'); + + if (slash == path) { + file = ++slash; + dir = isc_mem_strdup(mctx, "/"); + } else if (slash != NULL) { + file = ++slash; + dir = isc_mem_allocate(mctx, slash - path); + if (dir != NULL) + strlcpy(dir, path, slash - path); + } else { + file = path; + dir = isc_mem_strdup(mctx, "."); + } + + if (dir == NULL) + return (ISC_R_NOMEMORY); + + if (*file == '\0') { + isc_mem_free(mctx, dir); + return (ISC_R_INVALIDFILE); + } + + *dirnam = dir; + *basenam = file; + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/unix/fsaccess.c b/contrib/ntp/lib/isc/unix/fsaccess.c new file mode 100644 index 000000000..a2bd89ad7 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/fsaccess.c @@ -0,0 +1,93 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: fsaccess.c,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include +#include + +#include + +#include "errno2result.h" + +/*! \file + * \brief + * The OS-independent part of the API is in lib/isc. + */ +#include "../fsaccess.c" + +isc_result_t +isc_fsaccess_set(const char *path, isc_fsaccess_t access) { + struct stat statb; + mode_t mode; + isc_boolean_t is_dir = ISC_FALSE; + isc_fsaccess_t bits; + isc_result_t result; + + if (stat(path, &statb) != 0) + return (isc__errno2result(errno)); + + if ((statb.st_mode & S_IFDIR) != 0) + is_dir = ISC_TRUE; + else if ((statb.st_mode & S_IFREG) == 0) + return (ISC_R_INVALIDFILE); + + result = check_bad_bits(access, is_dir); + if (result != ISC_R_SUCCESS) + return (result); + + /* + * Done with checking bad bits. Set mode_t. + */ + mode = 0; + +#define SET_AND_CLEAR1(modebit) \ + if ((access & bits) != 0) { \ + mode |= modebit; \ + access &= ~bits; \ + } +#define SET_AND_CLEAR(user, group, other) \ + SET_AND_CLEAR1(user); \ + bits <<= STEP; \ + SET_AND_CLEAR1(group); \ + bits <<= STEP; \ + SET_AND_CLEAR1(other); + + bits = ISC_FSACCESS_READ | ISC_FSACCESS_LISTDIRECTORY; + + SET_AND_CLEAR(S_IRUSR, S_IRGRP, S_IROTH); + + bits = ISC_FSACCESS_WRITE | + ISC_FSACCESS_CREATECHILD | + ISC_FSACCESS_DELETECHILD; + + SET_AND_CLEAR(S_IWUSR, S_IWGRP, S_IWOTH); + + bits = ISC_FSACCESS_EXECUTE | + ISC_FSACCESS_ACCESSCHILD; + + SET_AND_CLEAR(S_IXUSR, S_IXGRP, S_IXOTH); + + INSIST(access == 0); + + if (chmod(path, mode) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/libisc/ifiter_getifaddrs.c b/contrib/ntp/lib/isc/unix/ifiter_getifaddrs.c similarity index 60% rename from contrib/ntp/libisc/ifiter_getifaddrs.c rename to contrib/ntp/lib/isc/unix/ifiter_getifaddrs.c index f20c1b358..ad7c5f85c 100644 --- a/contrib/ntp/libisc/ifiter_getifaddrs.c +++ b/contrib/ntp/lib/isc/unix/ifiter_getifaddrs.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,26 +15,39 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: ifiter_getifaddrs.c,v 1.2.68.3 2004/03/06 08:14:59 marka Exp $ */ +/* $Id: ifiter_getifaddrs.c,v 1.13 2009/09/24 23:48:13 tbox Exp $ */ -/* +/*! \file + * \brief * Obtain the list of network interfaces using the getifaddrs(3) library. */ #include +/*% Iterator Magic */ #define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'G') +/*% Valid Iterator */ #define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) +#ifdef __linux +static isc_boolean_t seenv6 = ISC_FALSE; +#endif + +/*% Iterator structure */ struct isc_interfaceiter { - unsigned int magic; /* Magic number. */ + unsigned int magic; /*%< Magic number. */ isc_mem_t *mctx; - void *buf; /* (unused) */ - unsigned int bufsize; /* (always 0) */ - struct ifaddrs *ifaddrs; /* List of ifaddrs */ - struct ifaddrs *pos; /* Ptr to current ifaddr */ - isc_interface_t current; /* Current interface data. */ - isc_result_t result; /* Last result code. */ + void *buf; /*%< (unused) */ + unsigned int bufsize; /*%< (always 0) */ + struct ifaddrs *ifaddrs; /*%< List of ifaddrs */ + struct ifaddrs *pos; /*%< Ptr to current ifaddr */ + isc_interface_t current; /*%< Current interface data. */ + isc_result_t result; /*%< Last result code. */ +#ifdef __linux + FILE * proc; + char entry[ISC_IF_INET6_SZ]; + isc_result_t valid; +#endif }; isc_result_t @@ -42,7 +55,9 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { isc_interfaceiter_t *iter; isc_result_t result; char strbuf[ISC_STRERRORSIZE]; + int trys, ret; + REQUIRE(mctx != NULL); REQUIRE(iterp != NULL); REQUIRE(*iterp == NULL); @@ -54,15 +69,39 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { iter->buf = NULL; iter->bufsize = 0; iter->ifaddrs = NULL; +#ifdef __linux + /* + * Only open "/proc/net/if_inet6" if we have never seen a IPv6 + * address returned by getifaddrs(). + */ + if (!seenv6) { + iter->proc = fopen("/proc/net/if_inet6", "r"); + if (iter->proc == NULL) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "failed to open /proc/net/if_inet6"); + } + } else + iter->proc = NULL; + iter->valid = ISC_R_FAILURE; +#endif - if (getifaddrs(&iter->ifaddrs) < 0) { + /* If interrupted, try again */ + for (trys = 0; trys < 3; trys++) { + if ((ret = getifaddrs(&iter->ifaddrs)) >= 0) + break; + if (errno != EINTR) + break; + } + if (ret < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, + "getting interface addresses: %s: %s", isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERGETIFADDRS, ISC_MSG_GETIFADDRS, - "getting interface " - "addresses: getifaddrs: %s"), + "getifaddrs"), strbuf); result = ISC_R_UNEXPECTED; goto failure; @@ -80,6 +119,10 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { return (ISC_R_SUCCESS); failure: +#ifdef __linux + if (iter->proc != NULL) + fclose(iter->proc); +#endif if (iter->ifaddrs != NULL) /* just in case */ freeifaddrs(iter->ifaddrs); isc_mem_put(mctx, iter, sizeof(*iter)); @@ -103,14 +146,45 @@ internal_current(isc_interfaceiter_t *iter) { ifa = iter->pos; +#ifdef __linux + /* + * [Bug 2792] + * burnicki: iter->pos is usually never NULL here (anymore?), + * so linux_if_inet6_current(iter) is never called here. + * However, that routine would check (under Linux), if the + * interface is in a tentative state, e.g. if there's no link + * yet but an IPv6 address has already be assigned. + */ + if (iter->pos == NULL) + return (linux_if_inet6_current(iter)); +#endif + INSIST(ifa != NULL); INSIST(ifa->ifa_name != NULL); - INSIST(ifa->ifa_addr != NULL); + + +#ifdef IFF_RUNNING + /* + * [Bug 2792] + * burnicki: if the interface is not running then + * it may be in a tentative state. See above. + */ + if ((ifa->ifa_flags & IFF_RUNNING) == 0) + return (ISC_R_IGNORE); +#endif + + if (ifa->ifa_addr == NULL) + return (ISC_R_IGNORE); family = ifa->ifa_addr->sa_family; if (family != AF_INET && family != AF_INET6) return (ISC_R_IGNORE); +#ifdef __linux + if (family == AF_INET6) + seenv6 = ISC_TRUE; +#endif + memset(&iter->current, 0, sizeof(iter->current)); namelen = strlen(ifa->ifa_name); @@ -131,15 +205,14 @@ internal_current(isc_interfaceiter_t *iter) { if ((ifa->ifa_flags & IFF_LOOPBACK) != 0) iter->current.flags |= INTERFACE_F_LOOPBACK; - if ((ifa->ifa_flags & IFF_BROADCAST) != 0) { + if ((ifa->ifa_flags & IFF_BROADCAST) != 0) iter->current.flags |= INTERFACE_F_BROADCAST; - } #ifdef IFF_MULTICAST - if ((ifa->ifa_flags & IFF_MULTICAST) != 0) { + if ((ifa->ifa_flags & IFF_MULTICAST) != 0) iter->current.flags |= INTERFACE_F_MULTICAST; - } #endif + iter->current.af = family; get_addr(family, &iter->current.address, ifa->ifa_addr, ifa->ifa_name); @@ -158,6 +231,9 @@ internal_current(isc_interfaceiter_t *iter) { get_addr(family, &iter->current.broadcast, ifa->ifa_broadaddr, ifa->ifa_name); +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + iter->current.ifindex = if_nametoindex(iter->current.name); +#endif return (ISC_R_SUCCESS); } @@ -170,16 +246,28 @@ internal_current(isc_interfaceiter_t *iter) { */ static isc_result_t internal_next(isc_interfaceiter_t *iter) { - iter->pos = iter->pos->ifa_next; - if (iter->pos == NULL) + if (iter->pos != NULL) + iter->pos = iter->pos->ifa_next; + if (iter->pos == NULL) { +#ifdef __linux + if (!seenv6) + return (linux_if_inet6_next(iter)); +#endif return (ISC_R_NOMORE); + } return (ISC_R_SUCCESS); } static void internal_destroy(isc_interfaceiter_t *iter) { + +#ifdef __linux + if (iter->proc != NULL) + fclose(iter->proc); + iter->proc = NULL; +#endif if (iter->ifaddrs) freeifaddrs(iter->ifaddrs); iter->ifaddrs = NULL; @@ -187,5 +275,9 @@ internal_destroy(isc_interfaceiter_t *iter) { static void internal_first(isc_interfaceiter_t *iter) { + +#ifdef __linux + linux_if_inet6_first(iter); +#endif iter->pos = iter->ifaddrs; } diff --git a/contrib/ntp/libisc/ifiter_ioctl.c b/contrib/ntp/lib/isc/unix/ifiter_ioctl.c similarity index 81% rename from contrib/ntp/libisc/ifiter_ioctl.c rename to contrib/ntp/lib/isc/unix/ifiter_ioctl.c index e069560b0..c8e4970e6 100644 --- a/contrib/ntp/libisc/ifiter_ioctl.c +++ b/contrib/ntp/lib/isc/unix/ifiter_ioctl.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,9 +15,10 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: ifiter_ioctl.c,v 1.19.2.5.2.14 2004/06/22 04:40:23 marka Exp $ */ +/* $Id: ifiter_ioctl.c,v 1.62 2009/01/18 23:48:14 tbox Exp $ */ -/* +/*! \file + * \brief * Obtain the list of network interfaces using the SIOCGLIFCONF ioctl. * See netintro(4). */ @@ -51,9 +52,6 @@ #define IFITER_MAGIC ISC_MAGIC('I', 'F', 'I', 'T') #define VALID_IFITER(t) ISC_MAGIC_VALID(t, IFITER_MAGIC) -#define ISC_IF_INET6_SZ \ - sizeof("00000000000000000000000000000001 01 80 10 80 XXXXXXloXXXXXXXX\n") - struct isc_interfaceiter { unsigned int magic; /* Magic number. */ isc_mem_t *mctx; @@ -83,7 +81,6 @@ struct isc_interfaceiter { FILE * proc; char entry[ISC_IF_INET6_SZ]; isc_result_t valid; - isc_boolean_t first; #endif isc_interface_t current; /* Current interface data. */ isc_result_t result; /* Last result code. */ @@ -95,7 +92,7 @@ struct isc_interfaceiter { #endif -/* +/*% * Size of buffer for SIOCGLIFCONF, in bytes. We assume no sane system * will have more than a megabyte of interface configuration data. */ @@ -105,13 +102,32 @@ struct isc_interfaceiter { #ifdef __linux #ifndef IF_NAMESIZE # ifdef IFNAMSIZ -# define IF_NAMESIZE IFNAMSIZ +# define IF_NAMESIZE IFNAMSIZ # else # define IF_NAMESIZE 16 # endif #endif #endif +/* Silence a warning when this file is #included */ +int +isc_ioctl(int fildes, int req, char *arg); + +int +isc_ioctl(int fildes, int req, char *arg) { + int trys; + int ret; + + for (trys = 0; trys < 3; trys++) { + if ((ret = ioctl(fildes, req, arg)) < 0) { + if (errno == EINTR) + continue; + } + break; + } + return (ret); +} + static isc_result_t getbuf4(isc_interfaceiter_t *iter) { char strbuf[ISC_STRERRORSIZE]; @@ -131,7 +147,7 @@ getbuf4(isc_interfaceiter_t *iter) { * conversion". It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(iter->socket, SIOCGIFCONF, (char *)&iter->ifc) + if (isc_ioctl(iter->socket, SIOCGIFCONF, (char *)&iter->ifc) == -1) { if (errno != EINVAL) { isc__strerror(errno, strbuf, sizeof(strbuf)); @@ -211,7 +227,7 @@ getbuf6(isc_interfaceiter_t *iter) { * conversion". It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(iter->socket6, SIOCGLIFCONF, (char *)&iter->lifc) + if (isc_ioctl(iter->socket6, SIOCGLIFCONF, (char *)&iter->lifc) == -1) { #ifdef __hpux /* @@ -220,13 +236,15 @@ getbuf6(isc_interfaceiter_t *iter) { */ if (errno == ENOENT) { isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - isc_msgcat_get(isc_msgcat, + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, + ISC_LOG_DEBUG(1), + isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERIOCTL, ISC_MSG_GETIFCONFIG, "get interface " "configuration: %s"), - strbuf); + strbuf); result = ISC_R_FAILURE; goto cleanup; } @@ -294,6 +312,7 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { isc_result_t result; char strbuf[ISC_STRERRORSIZE]; + REQUIRE(mctx != NULL); REQUIRE(iterp != NULL); REQUIRE(*iterp == NULL); @@ -338,9 +357,8 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { result = ISC_R_UNEXPECTED; goto socket6_failure; } - iter->result6 = getbuf6(iter); - if (iter->result6 != ISC_R_NOTIMPLEMENTED && - iter->result6 != ISC_R_SUCCESS) + result = iter->result6 = getbuf6(iter); + if (result != ISC_R_NOTIMPLEMENTED && result != ISC_R_SUCCESS) goto ioctl6_failure; } #endif @@ -371,7 +389,6 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { #ifdef __linux iter->proc = fopen("/proc/net/if_inet6", "r"); iter->valid = ISC_R_FAILURE; - iter->first = ISC_FALSE; #endif iter->result = ISC_R_FAILURE; @@ -393,7 +410,7 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { (void) close(iter->socket6); socket6_failure: #endif - + isc_mem_put(mctx, iter, sizeof(*iter)); return (result); } @@ -421,124 +438,6 @@ internal_current_clusteralias(isc_interfaceiter_t *iter) { } #endif -#ifdef __linux -static isc_result_t -linux_if_inet6_next(isc_interfaceiter_t *iter) { - if (iter->proc != NULL && - fgets(iter->entry, sizeof(iter->entry), iter->proc) != NULL) - iter->valid = ISC_R_SUCCESS; - else - iter->valid = ISC_R_NOMORE; - return (iter->valid); -} - -static void -linux_if_inet6_first(isc_interfaceiter_t *iter) { - if (iter->proc != NULL) { - rewind(iter->proc); - (void)linux_if_inet6_next(iter); - } else - iter->valid = ISC_R_NOMORE; - iter->first = ISC_FALSE; -} - -static isc_result_t -linux_if_inet6_current(isc_interfaceiter_t *iter) { - char address[33]; - char name[IF_NAMESIZE+1]; - char strbuf[ISC_STRERRORSIZE]; - struct in6_addr addr6; - struct ifreq ifreq; - int ifindex, prefix, scope, flags; - int res; - unsigned int i; - - if (iter->valid != ISC_R_SUCCESS) - return (iter->valid); - if (iter->proc == NULL) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - "/proc/net/if_inet6:iter->proc == NULL"); - return (ISC_R_FAILURE); - } - - /* - * Format for /proc/net/if_inet6: - * (see iface_proc_info() in net/ipv6/addrconf.c) - * - */ - res = sscanf(iter->entry, "%32[a-f0-9] %x %x %x %x %16s\n", - address, &ifindex, &prefix, &scope, &flags, name); - if (res != 6) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - "/proc/net/if_inet6:sscanf() -> %d (expected 6)", - res); - return (ISC_R_FAILURE); - } - if (strlen(address) != 32) { - UNEXPECTED_ERROR(__FILE__, __LINE__, - "/proc/net/if_inet6:strlen(%s) != 32", address); - return (ISC_R_FAILURE); - } - for (i = 0; i < 16; i++) { - unsigned char byte; - static const char hex[] = "0123456789abcdef"; - byte = ((index(hex, address[i * 2]) - hex) << 4) | - (index(hex, address[i * 2 + 1]) - hex); - addr6.s6_addr[i] = byte; - } - iter->current.af = AF_INET6; - /* iter->current.ifindex = ifindex; */ - iter->current.flags = 0; - - memset(&ifreq, 0, sizeof(ifreq)); - INSIST(sizeof(ifreq.ifr_name) <= sizeof(iter->current.name)); - strncpy(ifreq.ifr_name, name, sizeof(ifreq.ifr_name)); - - if (ioctl(iter->socket, SIOCGIFFLAGS, (char *) &ifreq) < 0) { - isc__strerror(errno, strbuf, sizeof(strbuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, - "%s: getting interface flags: %s", - ifreq.ifr_name, strbuf); - return (ISC_R_IGNORE); - } - - if ((ifreq.ifr_flags & IFF_UP) != 0) - iter->current.flags |= INTERFACE_F_UP; -#ifdef IFF_POINTOPOINT - if ((ifreq.ifr_flags & IFF_POINTOPOINT) != 0) - iter->current.flags |= INTERFACE_F_POINTTOPOINT; -#endif - if ((ifreq.ifr_flags & IFF_LOOPBACK) != 0) - iter->current.flags |= INTERFACE_F_LOOPBACK; - if ((ifreq.ifr_flags & IFF_BROADCAST) != 0) - iter->current.flags |= INTERFACE_F_BROADCAST; -#ifdef IFF_MULTICAST - if ((ifreq.ifr_flags & IFF_MULTICAST) != 0) - iter->current.flags |= INTERFACE_F_MULTICAST; -#endif - - /* - * enable_multicast_if() requires scopeid for setsockopt, - * so associate address with their corresponding ifindex. - */ - isc_netaddr_fromin6(&iter->current.address, &addr6); - isc_netaddr_setzone(&iter->current.address, (isc_uint32_t)ifindex); - - for (i = 0; i < 16; i++) { - if (prefix > 8) { - addr6.s6_addr[i] = 0xff; - prefix -= 8; - } else { - addr6.s6_addr[i] = (0xff << (8 - prefix)) & 0xff; - prefix = 0; - } - } - isc_netaddr_fromin6(&iter->current.netmask, &addr6); - strncpy(iter->current.name, name, sizeof(iter->current.name)); - return (ISC_R_SUCCESS); -} -#endif - /* * Get information about the current interface to iter->current. * If successful, return ISC_R_SUCCESS. @@ -559,21 +458,21 @@ internal_current4(isc_interfaceiter_t *iter) { char sabuf[256]; #endif int i, bits, prefixlen; -#ifdef __linux - isc_result_t result; -#endif REQUIRE(VALID_IFITER(iter)); - REQUIRE (iter->pos < (unsigned int) iter->ifc.ifc_len); + if (iter->ifc.ifc_len == 0 || + iter->pos == (unsigned int)iter->ifc.ifc_len) { #ifdef __linux - result = linux_if_inet6_current(iter); - if (result != ISC_R_NOMORE) - return (result); - iter->first = ISC_TRUE; + return (linux_if_inet6_current(iter)); +#else + return (ISC_R_NOMORE); #endif + } - ifrp = (struct ifreq *)((char *) iter->ifc.ifc_req + iter->pos); + INSIST( iter->pos < (unsigned int) iter->ifc.ifc_len); + + ifrp = (void *)((char *) iter->ifc.ifc_req + iter->pos); memset(&ifreq, 0, sizeof(ifreq)); memcpy(&ifreq, ifrp, sizeof(ifreq)); @@ -604,13 +503,11 @@ internal_current4(isc_interfaceiter_t *iter) { if (iter->current.address.type.in.s_addr == htonl(INADDR_ANY)) return (ISC_R_IGNORE); break; -#ifdef ISC_PLATFORM_HAVEIPV6 case AF_INET6: if (memcmp(&iter->current.address.type.in6, &in6addr_any, sizeof(in6addr_any)) == 0) return (ISC_R_IGNORE); break; -#endif } /* @@ -624,7 +521,7 @@ internal_current4(isc_interfaceiter_t *iter) { * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(iter->socket, SIOCGIFFLAGS, (char *) &ifreq) < 0) { + if (isc_ioctl(iter->socket, SIOCGIFFLAGS, (char *) &ifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, "%s: getting interface flags: %s", @@ -643,14 +540,12 @@ internal_current4(isc_interfaceiter_t *iter) { if ((ifreq.ifr_flags & IFF_LOOPBACK) != 0) iter->current.flags |= INTERFACE_F_LOOPBACK; - if ((ifreq.ifr_flags & IFF_BROADCAST) != 0) { + if ((ifreq.ifr_flags & IFF_BROADCAST) != 0) iter->current.flags |= INTERFACE_F_BROADCAST; - } #ifdef IFF_MULTICAST - if ((ifreq.ifr_flags & IFF_MULTICAST) != 0) { + if ((ifreq.ifr_flags & IFF_MULTICAST) != 0) iter->current.flags |= INTERFACE_F_MULTICAST; - } #endif if (family == AF_INET) @@ -662,7 +557,7 @@ internal_current4(isc_interfaceiter_t *iter) { memcpy(&lifreq.lifr_addr, &iter->current.address.type.in6, sizeof(iter->current.address.type.in6)); - if (ioctl(iter->socket, SIOCGLIFADDR, &lifreq) < 0) { + if (isc_ioctl(iter->socket, SIOCGLIFADDR, &lifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, "%s: getting interface address: %s", @@ -672,7 +567,9 @@ internal_current4(isc_interfaceiter_t *iter) { prefixlen = lifreq.lifr_addrlen; #else isc_netaddr_format(&iter->current.address, sabuf, sizeof(sabuf)); - UNEXPECTED_ERROR(__FILE__, __LINE__, + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, + ISC_LOG_INFO, isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERIOCTL, ISC_MSG_GETIFCONFIG, @@ -695,6 +592,9 @@ internal_current4(isc_interfaceiter_t *iter) { } iter->current.netmask.type.in6.s6_addr[i] = (~0 << bits) & 0xff; } +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + iter->current.ifindex = if_nametoindex(iter->current.name); +#endif return (ISC_R_SUCCESS); inet: @@ -710,7 +610,7 @@ internal_current4(isc_interfaceiter_t *iter) { * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(iter->socket, SIOCGIFDSTADDR, (char *)&ifreq) + if (isc_ioctl(iter->socket, SIOCGIFDSTADDR, (char *)&ifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, @@ -726,19 +626,20 @@ internal_current4(isc_interfaceiter_t *iter) { (struct sockaddr *)&ifreq.ifr_dstaddr, ifreq.ifr_name); } #endif + if ((iter->current.flags & INTERFACE_F_BROADCAST) != 0) { /* * Ignore the HP/UX warning about "integer overflow during * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(iter->socket, SIOCGIFBRDADDR, (char *)&ifreq) + if (isc_ioctl(iter->socket, SIOCGIFBRDADDR, (char *)&ifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETDESTADDR, + ISC_MSG_GETBCSTADDR, "%s: getting " "broadcast address: %s"), ifreq.ifr_name, strbuf); @@ -758,7 +659,7 @@ internal_current4(isc_interfaceiter_t *iter) { * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(iter->socket, SIOCGIFNETMASK, (char *)&ifreq) < 0) { + if (isc_ioctl(iter->socket, SIOCGIFNETMASK, (char *)&ifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, isc_msgcat_get(isc_msgcat, @@ -770,6 +671,9 @@ internal_current4(isc_interfaceiter_t *iter) { } get_addr(family, &iter->current.netmask, (struct sockaddr *)&ifreq.ifr_addr, ifreq.ifr_name); +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + iter->current.ifindex = if_nametoindex(iter->current.name); +#endif return (ISC_R_SUCCESS); } @@ -787,7 +691,7 @@ internal_current6(isc_interfaceiter_t *iter) { return (iter->result6); REQUIRE(iter->pos6 < (unsigned int) iter->lifc.lifc_len); - ifrp = (struct LIFREQ *)((char *) iter->lifc.lifc_req + iter->pos6); + ifrp = (void *)((char *)iter->lifc.lifc_req + iter->pos6); memset(&lifreq, 0, sizeof(lifreq)); memcpy(&lifreq, ifrp, sizeof(lifreq)); @@ -810,6 +714,10 @@ internal_current6(isc_interfaceiter_t *iter) { get_addr(family, &iter->current.address, (struct sockaddr *)&lifreq.lifr_addr, lifreq.lifr_name); + if (isc_netaddr_islinklocal(&iter->current.address)) + isc_netaddr_setzone(&iter->current.address, + (isc_uint32_t)lifreq.lifr_index); + /* * If the interface does not have a address ignore it. */ @@ -818,13 +726,11 @@ internal_current6(isc_interfaceiter_t *iter) { if (iter->current.address.type.in.s_addr == htonl(INADDR_ANY)) return (ISC_R_IGNORE); break; -#ifdef ISC_PLATFORM_HAVEIPV6 case AF_INET6: if (memcmp(&iter->current.address.type.in6, &in6addr_any, sizeof(in6addr_any)) == 0) return (ISC_R_IGNORE); break; -#endif } /* @@ -843,7 +749,7 @@ internal_current6(isc_interfaceiter_t *iter) { * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(fd, SIOCGLIFFLAGS, (char *) &lifreq) < 0) { + if (isc_ioctl(fd, SIOCGLIFFLAGS, (char *) &lifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, "%s: getting interface flags: %s", @@ -878,11 +784,11 @@ internal_current6(isc_interfaceiter_t *iter) { */ if ((iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) { /* - * Ignore the HP/UX warning about "interger overflow during + * Ignore the HP/UX warning about "integer overflow during * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(fd, SIOCGLIFDSTADDR, (char *)&lifreq) + if (isc_ioctl(fd, SIOCGLIFDSTADDR, (char *)&lifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, @@ -907,13 +813,13 @@ internal_current6(isc_interfaceiter_t *iter) { * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(iter->socket, SIOCGLIFBRDADDR, (char *)&lifreq) + if (isc_ioctl(iter->socket, SIOCGLIFBRDADDR, (char *)&lifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERIOCTL, - ISC_MSG_GETDESTADDR, + ISC_MSG_GETBCSTADDR, "%s: getting " "broadcast address: %s"), lifreq.lifr_name, strbuf); @@ -947,7 +853,9 @@ internal_current6(isc_interfaceiter_t *iter) { iter->current.netmask.type.in6.s6_addr[i / 8] = (~0 << bits) & 0xff; } - +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + iter->current.ifindex = if_nametoindex(iter->current.name); +#endif return (ISC_R_SUCCESS); } #endif @@ -957,7 +865,7 @@ internal_current6(isc_interfaceiter_t *iter) { * conversion. It comes from its own macro definition, * and is really hard to shut up. */ - if (ioctl(fd, SIOCGLIFNETMASK, (char *)&lifreq) < 0) { + if (isc_ioctl(fd, SIOCGLIFNETMASK, (char *)&lifreq) < 0) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, isc_msgcat_get(isc_msgcat, @@ -970,6 +878,9 @@ internal_current6(isc_interfaceiter_t *iter) { get_addr(family, &iter->current.netmask, (struct sockaddr *)&lifreq.lifr_addr, lifreq.lifr_name); +#ifdef ISC_PLATFORM_HAVEIFNAMETOINDEX + iter->current.ifindex = if_nametoindex(iter->current.name); +#endif return (ISC_R_SUCCESS); } #endif @@ -999,49 +910,52 @@ internal_current(isc_interfaceiter_t *iter) { */ static isc_result_t internal_next4(isc_interfaceiter_t *iter) { +#ifdef ISC_PLATFORM_HAVESALEN struct ifreq *ifrp; - - REQUIRE (iter->pos < (unsigned int) iter->ifc.ifc_len); - -#ifdef __linux - if (linux_if_inet6_next(iter) == ISC_R_SUCCESS) - return (ISC_R_SUCCESS); - if (!iter->first) - return (ISC_R_SUCCESS); #endif - ifrp = (struct ifreq *)((char *) iter->ifc.ifc_req + iter->pos); + if (iter->pos < (unsigned int) iter->ifc.ifc_len) { #ifdef ISC_PLATFORM_HAVESALEN - if (ifrp->ifr_addr.sa_len > sizeof(struct sockaddr)) - iter->pos += sizeof(ifrp->ifr_name) + ifrp->ifr_addr.sa_len; - else + ifrp = (struct ifreq *)((char *) iter->ifc.ifc_req + iter->pos); + + if (ifrp->ifr_addr.sa_len > sizeof(struct sockaddr)) + iter->pos += sizeof(ifrp->ifr_name) + + ifrp->ifr_addr.sa_len; + else #endif - iter->pos += sizeof(*ifrp); + iter->pos += sizeof(struct ifreq); - if (iter->pos >= (unsigned int) iter->ifc.ifc_len) + } else { + INSIST(iter->pos == (unsigned int) iter->ifc.ifc_len); +#ifdef __linux + return (linux_if_inet6_next(iter)); +#else return (ISC_R_NOMORE); - +#endif + } return (ISC_R_SUCCESS); } #if defined(SIOCGLIFCONF) && defined(SIOCGLIFADDR) static isc_result_t internal_next6(isc_interfaceiter_t *iter) { +#ifdef ISC_PLATFORM_HAVESALEN struct LIFREQ *ifrp; - +#endif + if (iter->result6 != ISC_R_SUCCESS && iter->result6 != ISC_R_IGNORE) return (iter->result6); REQUIRE(iter->pos6 < (unsigned int) iter->lifc.lifc_len); +#ifdef ISC_PLATFORM_HAVESALEN ifrp = (struct LIFREQ *)((char *) iter->lifc.lifc_req + iter->pos6); -#ifdef ISC_PLATFORM_HAVESALEN if (ifrp->lifr_addr.sa_len > sizeof(struct sockaddr)) iter->pos6 += sizeof(ifrp->lifr_name) + ifrp->lifr_addr.sa_len; else #endif - iter->pos6 += sizeof(*ifrp); + iter->pos6 += sizeof(struct LIFREQ); if (iter->pos6 >= (unsigned int) iter->lifc.lifc_len) return (ISC_R_NOMORE); diff --git a/contrib/ntp/libisc/ifiter_sysctl.c b/contrib/ntp/lib/isc/unix/ifiter_sysctl.c similarity index 91% rename from contrib/ntp/libisc/ifiter_sysctl.c rename to contrib/ntp/lib/isc/unix/ifiter_sysctl.c index 6206e6e5f..0fbb3778e 100644 --- a/contrib/ntp/libisc/ifiter_sysctl.c +++ b/contrib/ntp/lib/isc/unix/ifiter_sysctl.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,9 +15,10 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: ifiter_sysctl.c,v 1.14.12.7 2004/03/08 09:04:56 marka Exp $ */ +/* $Id: ifiter_sysctl.c,v 1.25 2007/06/19 23:47:18 tbox Exp $ */ -/* +/*! \file + * \brief * Obtain the list of network interfaces using sysctl. * See TCP/IP Illustrated Volume 2, sections 19.8, 19.14, * and 19.16. @@ -71,6 +72,7 @@ isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { size_t bufused; char strbuf[ISC_STRERRORSIZE]; + REQUIRE(mctx != NULL); REQUIRE(iterp != NULL); REQUIRE(*iterp == NULL); @@ -157,6 +159,10 @@ internal_current(isc_interfaceiter_t *iter) { ifam = (struct ifa_msghdr *) ((char *) iter->buf + iter->pos); ifam_end = (struct ifa_msghdr *) ((char *) iter->buf + iter->bufused); + // Skip wrong RTM version headers + if (ifam->ifam_version != RTM_VERSION) + return (ISC_R_IGNORE); + if (ifam->ifam_type == RTM_IFINFO) { struct if_msghdr *ifm = (struct if_msghdr *) ifam; struct sockaddr_dl *sdl = (struct sockaddr_dl *) (ifm + 1); @@ -164,6 +170,7 @@ internal_current(isc_interfaceiter_t *iter) { memset(&iter->current, 0, sizeof(iter->current)); + iter->current.ifindex = sdl->sdl_index; namelen = sdl->sdl_nlen; if (namelen > sizeof(iter->current.name) - 1) namelen = sizeof(iter->current.name) - 1; @@ -182,13 +189,12 @@ internal_current(isc_interfaceiter_t *iter) { if ((ifam->ifam_flags & IFF_LOOPBACK) != 0) iter->current.flags |= INTERFACE_F_LOOPBACK; - if ((ifam->ifam_flags & IFF_BROADCAST) != 0) { + if ((ifam->ifam_flags & IFF_BROADCAST) != 0) iter->current.flags |= INTERFACE_F_BROADCAST; - } + #ifdef IFF_MULTICAST - if ((ifam->ifam_flags & IFF_MULTICAST) != 0) { + if ((ifam->ifam_flags & IFF_MULTICAST) != 0) iter->current.flags |= INTERFACE_F_MULTICAST; - } #endif /* @@ -268,13 +274,13 @@ internal_current(isc_interfaceiter_t *iter) { get_addr(family, &iter->current.broadcast, dst_sa, iter->current.name); - return (ISC_R_SUCCESS); } else { - printf(isc_msgcat_get(isc_msgcat, ISC_MSGSET_IFITERSYSCTL, - ISC_MSG_UNEXPECTEDTYPE, - "warning: unexpected interface list " - "message type\n")); + printf("%s", isc_msgcat_get(isc_msgcat, + ISC_MSGSET_IFITERSYSCTL, + ISC_MSG_UNEXPECTEDTYPE, + "warning: unexpected interface " + "list message type\n")); return (ISC_R_IGNORE); } } diff --git a/contrib/ntp/lib/isc/unix/include/isc/dir.h b/contrib/ntp/lib/isc/unix/include/isc/dir.h new file mode 100644 index 000000000..e4a2ad0fb --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/dir.h @@ -0,0 +1,94 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: dir.h,v 1.21 2007/06/19 23:47:19 tbox Exp $ */ + +/* Principal Authors: DCL */ + +#ifndef ISC_DIR_H +#define ISC_DIR_H 1 + +/*! \file */ + +#include /* Required on some systems. */ +#include + +#include +#include + +#define ISC_DIR_NAMEMAX 256 +#define ISC_DIR_PATHMAX 1024 + +/*% Directory Entry */ +typedef struct isc_direntry { + /*! + * Ideally, this should be NAME_MAX, but AIX does not define it by + * default and dynamically allocating the space based on pathconf() + * complicates things undesirably, as does adding special conditionals + * just for AIX. So a comfortably sized buffer is chosen instead. + */ + char name[ISC_DIR_NAMEMAX]; + unsigned int length; +} isc_direntry_t; + +/*% Directory */ +typedef struct isc_dir { + unsigned int magic; + /*! + * As with isc_direntry_t->name, making this "right" for all systems + * is slightly problematic because AIX does not define PATH_MAX. + */ + char dirname[ISC_DIR_PATHMAX]; + isc_direntry_t entry; + DIR * handle; +} isc_dir_t; + +ISC_LANG_BEGINDECLS + +void +isc_dir_init(isc_dir_t *dir); + +isc_result_t +isc_dir_open(isc_dir_t *dir, const char *dirname); + +isc_result_t +isc_dir_read(isc_dir_t *dir); + +isc_result_t +isc_dir_reset(isc_dir_t *dir); + +void +isc_dir_close(isc_dir_t *dir); + +isc_result_t +isc_dir_chdir(const char *dirname); + +isc_result_t +isc_dir_chroot(const char *dirname); + +isc_result_t +isc_dir_createunique(char *templet); +/*!< + * Use a templet (such as from isc_file_mktemplate()) to create a uniquely + * named, empty directory. The templet string is modified in place. + * If result == ISC_R_SUCCESS, it is the name of the directory that was + * created. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_DIR_H */ diff --git a/contrib/ntp/include/isc/int.h b/contrib/ntp/lib/isc/unix/include/isc/int.h similarity index 64% rename from contrib/ntp/include/isc/int.h rename to contrib/ntp/lib/isc/unix/include/isc/int.h index d30e6dcc6..73feb3b65 100644 --- a/contrib/ntp/include/isc/int.h +++ b/contrib/ntp/lib/isc/unix/include/isc/int.h @@ -1,25 +1,27 @@ /* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: int.h,v 1.11 2001/01/09 21:58:39 bwelling Exp $ */ +/* $Id: int.h,v 1.16 2007/06/19 23:47:19 tbox Exp $ */ #ifndef ISC_INT_H #define ISC_INT_H 1 +/*! \file */ + typedef char isc_int8_t; typedef unsigned char isc_uint8_t; typedef short isc_int16_t; @@ -37,7 +39,7 @@ typedef unsigned long long isc_uint64_t; #define ISC_INT16_MAX 32767 #define ISC_UINT16_MAX 65535 -/* +/*% * Note that "int" is 32 bits on all currently supported Unix-like operating * systems, but "long" can be either 32 bits or 64 bits, thus the 32 bit * constants are not qualified with "L". diff --git a/contrib/ntp/lib/isc/unix/include/isc/keyboard.h b/contrib/ntp/lib/isc/unix/include/isc/keyboard.h new file mode 100644 index 000000000..43f5e7eec --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/keyboard.h @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: keyboard.h,v 1.11 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_KEYBOARD_H +#define ISC_KEYBOARD_H 1 + +/*! \file */ + +#include + +#include +#include + +ISC_LANG_BEGINDECLS + +typedef struct { + int fd; + struct termios saved_mode; + isc_result_t result; +} isc_keyboard_t; + +isc_result_t +isc_keyboard_open(isc_keyboard_t *keyboard); + +isc_result_t +isc_keyboard_close(isc_keyboard_t *keyboard, unsigned int sleepseconds); + +isc_result_t +isc_keyboard_getchar(isc_keyboard_t *keyboard, unsigned char *cp); + +isc_boolean_t +isc_keyboard_canceled(isc_keyboard_t *keyboard); + +ISC_LANG_ENDDECLS + +#endif /* ISC_KEYBOARD_H */ diff --git a/contrib/ntp/include/isc/net.h b/contrib/ntp/lib/isc/unix/include/isc/net.h similarity index 74% rename from contrib/ntp/include/isc/net.h rename to contrib/ntp/lib/isc/unix/include/isc/net.h index dae59780b..37a0f3b81 100644 --- a/contrib/ntp/include/isc/net.h +++ b/contrib/ntp/lib/isc/unix/include/isc/net.h @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007, 2008, 2012 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,7 +15,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: net.h,v 1.31.2.2.10.8 2004/04/29 01:31:23 marka Exp $ */ +/* $Id$ */ #ifndef ISC_NET_H #define ISC_NET_H 1 @@ -24,19 +24,20 @@ ***** Module Info *****/ -/* +/*! \file + * \brief * Basic Networking Types * * This module is responsible for defining the following basic networking * types: * - * struct in_addr - * struct in6_addr - * struct in6_pktinfo - * struct sockaddr - * struct sockaddr_in - * struct sockaddr_in6 - * in_port_t + *\li struct in_addr + *\li struct in6_addr + *\li struct in6_pktinfo + *\li struct sockaddr + *\li struct sockaddr_in + *\li struct sockaddr_in6 + *\li in_port_t * * It ensures that the AF_ and PF_ macros are defined. * @@ -44,27 +45,27 @@ * * It declares inet_aton(), inet_ntop(), and inet_pton(). * - * It ensures that INADDR_LOOPBACK, INADDR_ANY, IN6ADDR_ANY_INIT, + * It ensures that #INADDR_LOOPBACK, #INADDR_ANY, #IN6ADDR_ANY_INIT, * in6addr_any, and in6addr_loopback are available. * * It ensures that IN_MULTICAST() is available to check for multicast * addresses. * * MP: - * No impact. + *\li No impact. * * Reliability: - * No anticipated impact. + *\li No anticipated impact. * * Resources: - * N/A. + *\li N/A. * * Security: - * No anticipated impact. + *\li No anticipated impact. * * Standards: - * BSD Socket API - * RFC 2553 + *\li BSD Socket API + *\li RFC2553 */ /*** @@ -94,19 +95,19 @@ #include #ifdef ISC_PLATFORM_HAVEINADDR6 -#define in6_addr in_addr6 /* Required for pre RFC2133 implementations. */ +#define in6_addr in_addr6 /*%< Required for pre RFC2133 implementations. */ #endif #ifdef ISC_PLATFORM_HAVEIPV6 -/* +#ifndef IN6ADDR_ANY_INIT +#ifdef s6_addr +/*% * Required for some pre RFC2133 implementations. * IN6ADDR_ANY_INIT and IN6ADDR_LOOPBACK_INIT were added in - * draft-ietf-ipngwg-bsd-api-04.txt or draft-ietf-ipngwg-bsd-api-05.txt. + * draft-ietf-ipngwg-bsd-api-04.txt or draft-ietf-ipngwg-bsd-api-05.txt. * If 's6_addr' is defined then assume that there is a union and three * levels otherwise assume two levels required. */ -#ifndef IN6ADDR_ANY_INIT -#ifdef s6_addr #define IN6ADDR_ANY_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } } #else #define IN6ADDR_ANY_INIT { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } @@ -115,6 +116,7 @@ #ifndef IN6ADDR_LOOPBACK_INIT #ifdef s6_addr +/*% IPv6 address loopback init */ #define IN6ADDR_LOOPBACK_INIT { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } } #else #define IN6ADDR_LOOPBACK_INIT { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 } } @@ -122,12 +124,14 @@ #endif #ifndef IN6_IS_ADDR_V4MAPPED +/*% Is IPv6 address V4 mapped? */ #define IN6_IS_ADDR_V4MAPPED(x) \ (memcmp((x)->s6_addr, in6addr_any.s6_addr, 10) == 0 && \ (x)->s6_addr[10] == 0xff && (x)->s6_addr[11] == 0xff) #endif #ifndef IN6_IS_ADDR_V4COMPAT +/*% Is IPv6 address V4 compatible? */ #define IN6_IS_ADDR_V4COMPAT(x) \ (memcmp((x)->s6_addr, in6addr_any.s6_addr, 12) == 0 && \ ((x)->s6_addr[12] != 0 || (x)->s6_addr[13] != 0 || \ @@ -136,52 +140,58 @@ #endif #ifndef IN6_IS_ADDR_MULTICAST +/*% Is IPv6 address multicast? */ #define IN6_IS_ADDR_MULTICAST(a) ((a)->s6_addr[0] == 0xff) #endif #ifndef IN6_IS_ADDR_LINKLOCAL +/*% Is IPv6 address linklocal? */ #define IN6_IS_ADDR_LINKLOCAL(a) \ (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0x80)) #endif #ifndef IN6_IS_ADDR_SITELOCAL +/*% is IPv6 address sitelocal? */ #define IN6_IS_ADDR_SITELOCAL(a) \ (((a)->s6_addr[0] == 0xfe) && (((a)->s6_addr[1] & 0xc0) == 0xc0)) #endif #ifndef IN6_IS_ADDR_LOOPBACK +/*% is IPv6 address loopback? */ #define IN6_IS_ADDR_LOOPBACK(x) \ (memcmp((x)->s6_addr, in6addr_loopback.s6_addr, 16) == 0) #endif #endif #ifndef AF_INET6 +/*% IPv6 */ #define AF_INET6 99 #endif #ifndef PF_INET6 +/*% IPv6 */ #define PF_INET6 AF_INET6 #endif #ifndef INADDR_LOOPBACK +/*% inaddr loopback */ #define INADDR_LOOPBACK 0x7f000001UL #endif -#if 0 #ifndef ISC_PLATFORM_HAVEIN6PKTINFO +/*% IPv6 packet info */ struct in6_pktinfo { - struct in6_addr ipi6_addr; /* src/dst IPv6 address */ - unsigned int ipi6_ifindex; /* send/recv interface index */ + struct in6_addr ipi6_addr; /*%< src/dst IPv6 address */ + unsigned int ipi6_ifindex; /*%< send/recv interface index */ }; #endif -#endif -/* +#if defined(ISC_PLATFORM_NEEDIN6ADDRANY) +extern const struct in6_addr isc_net_in6addrany; +/*% * Cope with a missing in6addr_any and in6addr_loopback. */ -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRANY) -extern const struct in6_addr isc_net_in6addrany; #define in6addr_any isc_net_in6addrany #endif @@ -190,11 +200,12 @@ extern const struct in6_addr isc_net_in6addrloop; #define in6addr_loopback isc_net_in6addrloop #endif -/* - * Fix UnixWare 7.1.1's broken IN6_IS_ADDR_* definitions. - */ #ifdef ISC_PLATFORM_FIXIN6ISADDR #undef IN6_IS_ADDR_GEOGRAPHIC +/*! + * \brief + * Fix UnixWare 7.1.1's broken IN6_IS_ADDR_* definitions. + */ #define IN6_IS_ADDR_GEOGRAPHIC(a) (((a)->S6_un.S6_l[0] & 0xE0) == 0x80) #undef IN6_IS_ADDR_IPX #define IN6_IS_ADDR_IPX(a) (((a)->S6_un.S6_l[0] & 0xFE) == 0x04) @@ -210,24 +221,26 @@ extern const struct in6_addr isc_net_in6addrloop; #define IN6_IS_ADDR_SITELOCAL(a) (((a)->S6_un.S6_l[0] & 0xC0FF) == 0xC0FE) #endif /* ISC_PLATFORM_FIXIN6ISADDR */ -/* +#ifdef ISC_PLATFORM_NEEDPORTT +/*% * Ensure type in_port_t is defined. */ -#ifdef ISC_PLATFORM_NEEDPORTT typedef isc_uint16_t in_port_t; #endif -/* +#ifndef MSG_TRUNC +/*% * If this system does not have MSG_TRUNC (as returned from recvmsg()) * ISC_PLATFORM_RECVOVERFLOW will be defined. This will enable the MSG_TRUNC * faking code in socket.c. */ -#ifndef MSG_TRUNC #define ISC_PLATFORM_RECVOVERFLOW #endif +/*% IP address. */ #define ISC__IPADDR(x) ((isc_uint32_t)htonl((isc_uint32_t)(x))) +/*% Is IP address multicast? */ #define ISC_IPADDR_ISMULTICAST(i) \ (((isc_uint32_t)(i) & ISC__IPADDR(0xf0000000)) \ == ISC__IPADDR(0xe0000000)) @@ -244,40 +257,40 @@ ISC_LANG_BEGINDECLS isc_result_t isc_net_probeipv4(void); -/* +/*%< * Check if the system's kernel supports IPv4. * * Returns: * - * ISC_R_SUCCESS IPv4 is supported. - * ISC_R_NOTFOUND IPv4 is not supported. - * ISC_R_DISABLED IPv4 is disabled. - * ISC_R_UNEXPECTED + *\li #ISC_R_SUCCESS IPv4 is supported. + *\li #ISC_R_NOTFOUND IPv4 is not supported. + *\li #ISC_R_DISABLED IPv4 is disabled. + *\li #ISC_R_UNEXPECTED */ isc_result_t isc_net_probeipv6(void); -/* +/*%< * Check if the system's kernel supports IPv6. * * Returns: * - * ISC_R_SUCCESS IPv6 is supported. - * ISC_R_NOTFOUND IPv6 is not supported. - * ISC_R_DISABLED IPv6 is disabled. - * ISC_R_UNEXPECTED + *\li #ISC_R_SUCCESS IPv6 is supported. + *\li #ISC_R_NOTFOUND IPv6 is not supported. + *\li #ISC_R_DISABLED IPv6 is disabled. + *\li #ISC_R_UNEXPECTED */ isc_result_t isc_net_probe_ipv6only(void); -/* +/*%< * Check if the system's kernel supports the IPV6_V6ONLY socket option. * * Returns: * - * ISC_R_SUCCESS the option is supported for both TCP and UDP. - * ISC_R_NOTFOUND IPv6 itself or the option is not supported. - * ISC_R_UNEXPECTED + *\li #ISC_R_SUCCESS the option is supported for both TCP and UDP. + *\li #ISC_R_NOTFOUND IPv6 itself or the option is not supported. + *\li #ISC_R_UNEXPECTED */ isc_result_t @@ -288,9 +301,9 @@ isc_net_probe_ipv6pktinfo(void); * * Returns: * - * ISC_R_SUCCESS the option is supported. - * ISC_R_NOTFOUND IPv6 itself or the option is not supported. - * ISC_R_UNEXPECTED + * \li #ISC_R_SUCCESS the option is supported. + * \li #ISC_R_NOTFOUND IPv6 itself or the option is not supported. + * \li #ISC_R_UNEXPECTED */ void @@ -305,6 +318,29 @@ isc_net_enableipv4(void); void isc_net_enableipv6(void); +isc_result_t +isc_net_probeunix(void); +/* + * Returns whether UNIX domain sockets are supported. + */ + +isc_result_t +isc_net_getudpportrange(int af, in_port_t *low, in_port_t *high); +/*%< + * Returns system's default range of ephemeral UDP ports, if defined. + * If the range is not available or unknown, ISC_NET_PORTRANGELOW and + * ISC_NET_PORTRANGEHIGH will be returned. + * + * Requires: + * + *\li 'low' and 'high' must be non NULL. + * + * Returns: + * + *\li *low and *high will be the ports specifying the low and high ends of + * the range. + */ + #ifdef ISC_PLATFORM_NEEDNTOP const char * isc_net_ntop(int af, const void *src, char *dst, size_t size); @@ -318,11 +354,10 @@ isc_net_pton(int af, const char *src, void *dst); #define inet_pton isc_net_pton #endif -#ifdef ISC_PLATFORM_NEEDATON int isc_net_aton(const char *cp, struct in_addr *addr); +#undef inet_aton #define inet_aton isc_net_aton -#endif ISC_LANG_ENDDECLS diff --git a/contrib/ntp/lib/isc/unix/include/isc/netdb.h b/contrib/ntp/lib/isc/unix/include/isc/netdb.h new file mode 100644 index 000000000..ff12a26e2 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/netdb.h @@ -0,0 +1,57 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: netdb.h,v 1.11 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_NETDB_H +#define ISC_NETDB_H 1 + +/***** + ***** Module Info + *****/ + +/*! \file + * \brief + * Portable netdb.h support. + * + * This module is responsible for defining the getby APIs. + * + * MP: + *\li No impact. + * + * Reliability: + *\li No anticipated impact. + * + * Resources: + *\li N/A. + * + * Security: + *\li No anticipated impact. + * + * Standards: + *\li BSD API + */ + +/*** + *** Imports. + ***/ + +#include + +#include + +#endif /* ISC_NETDB_H */ diff --git a/contrib/ntp/lib/isc/unix/include/isc/offset.h b/contrib/ntp/lib/isc/unix/include/isc/offset.h new file mode 100644 index 000000000..8bf377999 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/offset.h @@ -0,0 +1,46 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: offset.h,v 1.17 2008/12/01 23:47:45 tbox Exp $ */ + +#ifndef ISC_OFFSET_H +#define ISC_OFFSET_H 1 + +/*! \file + * \brief + * File offsets are operating-system dependent. + */ +#include /* Required for CHAR_BIT. */ +#include +#include /* For Linux Standard Base. */ + +typedef off_t isc_offset_t; + +/*% + * POSIX says "Additionally, blkcnt_t and off_t are extended signed integral + * types", so the maximum value is all 1s except for the high bit. + * This definition is more complex than it really needs to be because it was + * crafted to keep both the SunOS 5.6 and the HP/UX 11 compilers quiet about + * integer overflow. For example, though this is equivalent to just left + * shifting 1 to the high bit and then inverting the bits, the SunOS compiler + * is unhappy about shifting a positive "1" to negative in a signed integer. + */ +#define ISC_OFFSET_MAXIMUM \ + (~(((off_t)-1 >> (sizeof(off_t) * CHAR_BIT - 1)) \ + << (sizeof(off_t) * CHAR_BIT - 1))) + +#endif /* ISC_OFFSET_H */ diff --git a/contrib/ntp/lib/isc/unix/include/isc/stat.h b/contrib/ntp/lib/isc/unix/include/isc/stat.h new file mode 100644 index 000000000..b7a798649 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/stat.h @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stat.h,v 1.5 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_STAT_H +#define ISC_STAT_H 1 + +/***** + ***** Module Info + *****/ + +/* + * Portable netdb.h support. + * + * This module is responsible for defining S_IS??? macros. + * + * MP: + * No impact. + * + * Reliability: + * No anticipated impact. + * + * Resources: + * N/A. + * + * Security: + * No anticipated impact. + * + */ + +/*** + *** Imports. + ***/ + +#include +#include + +#endif /* ISC_STAT_H */ diff --git a/contrib/ntp/lib/isc/unix/include/isc/stdtime.h b/contrib/ntp/lib/isc/unix/include/isc/stdtime.h new file mode 100644 index 000000000..c4931bfe6 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/stdtime.h @@ -0,0 +1,64 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_STDTIME_H +#define ISC_STDTIME_H 1 + +/*! \file */ + +#include +#include + +/*% + * It's public information that 'isc_stdtime_t' is an unsigned integral type. + * Applications that want maximum portability should not assume anything + * about its size. + */ +typedef isc_uint32_t isc_stdtime_t; + +/* but this flag helps... */ +#define STDTIME_ON_32BITS 1 + +/* + * isc_stdtime32_t is a 32-bit version of isc_stdtime_t. A variable of this + * type should only be used as an opaque integer (e.g.,) to compare two + * time values. + */ +typedef isc_uint32_t isc_stdtime32_t; + +ISC_LANG_BEGINDECLS +/* */ +void +isc_stdtime_get(isc_stdtime_t *t); +/*%< + * Set 't' to the number of seconds since 00:00:00 UTC, January 1, 1970. + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +#define isc_stdtime_convert32(t, t32p) (*(t32p) = t) +/* + * Convert the standard time to its 32-bit version. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_STDTIME_H */ diff --git a/contrib/ntp/lib/isc/unix/include/isc/strerror.h b/contrib/ntp/lib/isc/unix/include/isc/strerror.h new file mode 100644 index 000000000..899043bbf --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/strerror.h @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: strerror.h,v 1.10 2008/12/01 23:47:45 tbox Exp $ */ + +#ifndef ISC_STRERROR_H +#define ISC_STRERROR_H + +/*! \file */ + +#include + +#include + +ISC_LANG_BEGINDECLS + +/*% String Error Size */ +#define ISC_STRERRORSIZE 128 + +/*% + * Provide a thread safe wrapper to strerror(). + * + * Requires: + * 'buf' to be non NULL. + */ +void +isc__strerror(int num, char *buf, size_t bufsize); + +ISC_LANG_ENDDECLS + +#endif /* ISC_STRERROR_H */ diff --git a/contrib/ntp/lib/isc/unix/include/isc/syslog.h b/contrib/ntp/lib/isc/unix/include/isc/syslog.h new file mode 100644 index 000000000..7e0c88cb3 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/syslog.h @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: syslog.h,v 1.7 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef ISC_SYSLOG_H +#define ISC_SYSLOG_H 1 + +/*! \file */ + +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_syslog_facilityfromstring(const char *str, int *facilityp); +/*%< + * Convert 'str' to the appropriate syslog facility constant. + * + * Requires: + * + *\li 'str' is not NULL + *\li 'facilityp' is not NULL + * + * Returns: + * \li #ISC_R_SUCCESS + * \li #ISC_R_NOTFOUND + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SYSLOG_H */ diff --git a/contrib/ntp/lib/isc/unix/include/isc/time.h b/contrib/ntp/lib/isc/unix/include/isc/time.h new file mode 100644 index 000000000..dc1cef9ad --- /dev/null +++ b/contrib/ntp/lib/isc/unix/include/isc/time.h @@ -0,0 +1,334 @@ +/* + * Copyright (C) 2004-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: time.h,v 1.40 2009/01/05 23:47:54 tbox Exp $ */ + +#ifndef ISC_TIME_H +#define ISC_TIME_H 1 + +/*! \file */ + +#include +#include + +/*** + *** Intervals + ***/ + +/*! + * \brief + * The contents of this structure are private, and MUST NOT be accessed + * directly by callers. + * + * The contents are exposed only to allow callers to avoid dynamic allocation. + */ +struct isc_interval { + unsigned int seconds; + unsigned int nanoseconds; +}; + +extern isc_interval_t *isc_interval_zero; + +ISC_LANG_BEGINDECLS + +void +isc_interval_set(isc_interval_t *i, + unsigned int seconds, unsigned int nanoseconds); +/*%< + * Set 'i' to a value representing an interval of 'seconds' seconds and + * 'nanoseconds' nanoseconds, suitable for use in isc_time_add() and + * isc_time_subtract(). + * + * Requires: + * + *\li 't' is a valid pointer. + *\li nanoseconds < 1000000000. + */ + +isc_boolean_t +isc_interval_iszero(const isc_interval_t *i); +/*%< + * Returns ISC_TRUE iff. 'i' is the zero interval. + * + * Requires: + * + *\li 'i' is a valid pointer. + */ + +/*** + *** Absolute Times + ***/ + +/*% + * The contents of this structure are private, and MUST NOT be accessed + * directly by callers. + * + * The contents are exposed only to allow callers to avoid dynamic allocation. + */ + +struct isc_time { + unsigned int seconds; + unsigned int nanoseconds; +}; + +extern isc_time_t *isc_time_epoch; + +void +isc_time_set(isc_time_t *t, unsigned int seconds, unsigned int nanoseconds); +/*%< + * Set 't' to a value which represents the given number of seconds and + * nanoseconds since 00:00:00 January 1, 1970, UTC. + * + * Notes: + *\li The Unix version of this call is equivalent to: + *\code + * isc_time_settoepoch(t); + * isc_interval_set(i, seconds, nanoseconds); + * isc_time_add(t, i, t); + *\endcode + * + * Requires: + *\li 't' is a valid pointer. + *\li nanoseconds < 1000000000. + */ + +void +isc_time_settoepoch(isc_time_t *t); +/*%< + * Set 't' to the time of the epoch. + * + * Notes: + *\li The date of the epoch is platform-dependent. + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +isc_boolean_t +isc_time_isepoch(const isc_time_t *t); +/*%< + * Returns ISC_TRUE iff. 't' is the epoch ("time zero"). + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +isc_result_t +isc_time_now(isc_time_t *t); +/*%< + * Set 't' to the current absolute time. + * + * Requires: + * + *\li 't' is a valid pointer. + * + * Returns: + * + *\li Success + *\li Unexpected error + * Getting the time from the system failed. + *\li Out of range + * The time from the system is too large to be represented + * in the current definition of isc_time_t. + */ + +isc_result_t +isc_time_nowplusinterval(isc_time_t *t, const isc_interval_t *i); +/*%< + * Set *t to the current absolute time + i. + * + * Note: + *\li This call is equivalent to: + * + *\code + * isc_time_now(t); + * isc_time_add(t, i, t); + *\endcode + * + * Requires: + * + *\li 't' and 'i' are valid pointers. + * + * Returns: + * + *\li Success + *\li Unexpected error + * Getting the time from the system failed. + *\li Out of range + * The interval added to the time from the system is too large to + * be represented in the current definition of isc_time_t. + */ + +int +isc_time_compare(const isc_time_t *t1, const isc_time_t *t2); +/*%< + * Compare the times referenced by 't1' and 't2' + * + * Requires: + * + *\li 't1' and 't2' are valid pointers. + * + * Returns: + * + *\li -1 t1 < t2 (comparing times, not pointers) + *\li 0 t1 = t2 + *\li 1 t1 > t2 + */ + +isc_result_t +isc_time_add(const isc_time_t *t, const isc_interval_t *i, isc_time_t *result); +/*%< + * Add 'i' to 't', storing the result in 'result'. + * + * Requires: + * + *\li 't', 'i', and 'result' are valid pointers. + * + * Returns: + *\li Success + *\li Out of range + * The interval added to the time is too large to + * be represented in the current definition of isc_time_t. + */ + +isc_result_t +isc_time_subtract(const isc_time_t *t, const isc_interval_t *i, + isc_time_t *result); +/*%< + * Subtract 'i' from 't', storing the result in 'result'. + * + * Requires: + * + *\li 't', 'i', and 'result' are valid pointers. + * + * Returns: + *\li Success + *\li Out of range + * The interval is larger than the time since the epoch. + */ + +isc_uint64_t +isc_time_microdiff(const isc_time_t *t1, const isc_time_t *t2); +/*%< + * Find the difference in microseconds between time t1 and time t2. + * t2 is the subtrahend of t1; ie, difference = t1 - t2. + * + * Requires: + * + *\li 't1' and 't2' are valid pointers. + * + * Returns: + *\li The difference of t1 - t2, or 0 if t1 <= t2. + */ + +isc_uint32_t +isc_time_seconds(const isc_time_t *t); +/*%< + * Return the number of seconds since the epoch stored in a time structure. + * + * Requires: + * + *\li 't' is a valid pointer. + */ + +isc_result_t +isc_time_secondsastimet(const isc_time_t *t, time_t *secondsp); +/*%< + * Ensure the number of seconds in an isc_time_t is representable by a time_t. + * + * Notes: + *\li The number of seconds stored in an isc_time_t might be larger + * than the number of seconds a time_t is able to handle. Since + * time_t is mostly opaque according to the ANSI/ISO standard + * (essentially, all you can be sure of is that it is an arithmetic type, + * not even necessarily integral), it can be tricky to ensure that + * the isc_time_t is in the range a time_t can handle. Use this + * function in place of isc_time_seconds() any time you need to set a + * time_t from an isc_time_t. + * + * Requires: + *\li 't' is a valid pointer. + * + * Returns: + *\li Success + *\li Out of range + */ + +isc_uint32_t +isc_time_nanoseconds(const isc_time_t *t); +/*%< + * Return the number of nanoseconds stored in a time structure. + * + * Notes: + *\li This is the number of nanoseconds in excess of the number + * of seconds since the epoch; it will always be less than one + * full second. + * + * Requires: + *\li 't' is a valid pointer. + * + * Ensures: + *\li The returned value is less than 1*10^9. + */ + +void +isc_time_formattimestamp(const isc_time_t *t, char *buf, unsigned int len); +/*%< + * Format the time 't' into the buffer 'buf' of length 'len', + * using a format like "30-Aug-2000 04:06:47.997" and the local time zone. + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + *\li 'len' > 0 + *\li 'buf' points to an array of at least len chars + * + */ + +void +isc_time_formathttptimestamp(const isc_time_t *t, char *buf, unsigned int len); +/*%< + * Format the time 't' into the buffer 'buf' of length 'len', + * using a format like "Mon, 30 Aug 2000 04:06:47 GMT" + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + *\li 'len' > 0 + *\li 'buf' points to an array of at least len chars + * + */ + +void +isc_time_formatISO8601(const isc_time_t *t, char *buf, unsigned int len); +/*%< + * Format the time 't' into the buffer 'buf' of length 'len', + * using the ISO8601 format: "yyyy-mm-ddThh:mm:ssZ" + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + *\li 'len' > 0 + *\li 'buf' points to an array of at least len chars + * + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_TIME_H */ diff --git a/contrib/ntp/libisc/interfaceiter.c b/contrib/ntp/lib/isc/unix/interfaceiter.c similarity index 60% rename from contrib/ntp/libisc/interfaceiter.c rename to contrib/ntp/lib/isc/unix/interfaceiter.c index 7e3197520..c42fa685c 100644 --- a/contrib/ntp/libisc/interfaceiter.c +++ b/contrib/ntp/lib/isc/unix/interfaceiter.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,11 +15,11 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: interfaceiter.c,v 1.22.2.1.10.14 2004/08/28 06:25:22 marka Exp $ */ +/* $Id: interfaceiter.c,v 1.45 2008/12/01 03:51:47 marka Exp $ */ -#include +/*! \file */ -#define ISC_ONLY_IPV6 +#include #include #include @@ -33,6 +33,7 @@ #include #include +#include #include #include #include @@ -48,12 +49,17 @@ #ifdef HAVE_NET_IF6_H #include #endif +#include + +#ifdef HAVE_LINUX_IF_ADDR_H +# include +#endif /* Common utility functions */ -/* +/*% * Extract the network address part from a "struct sockaddr". - * + * \brief * The address family is given explicitly * instead of using src->sa_family, because the latter does not work * for copying a network mask obtained by SIOCGIFNETMASK (it does @@ -78,11 +84,11 @@ get_addr(unsigned int family, isc_netaddr_t *dst, struct sockaddr *src, switch (family) { case AF_INET: memcpy(&dst->type.in, - &((struct sockaddr_in *) src)->sin_addr, + &((struct sockaddr_in *)(void *)src)->sin_addr, sizeof(struct in_addr)); break; case AF_INET6: - sa6 = (struct sockaddr_in6 *)src; + sa6 = (struct sockaddr_in6 *)(void *)src; memcpy(&dst->type.in6, &sa6->sin6_addr, sizeof(struct in6_addr)); #ifdef ISC_PLATFORM_HAVESCOPEID @@ -143,6 +149,14 @@ get_addr(unsigned int family, isc_netaddr_t *dst, struct sockaddr *src, * Include system-dependent code. */ +#ifdef __linux +#define ISC_IF_INET6_SZ \ + sizeof("00000000000000000000000000000001 01 80 10 80 XXXXXXloXXXXXXXX\n") +static isc_result_t linux_if_inet6_next(isc_interfaceiter_t *); +static isc_result_t linux_if_inet6_current(isc_interfaceiter_t *); +static void linux_if_inet6_first(isc_interfaceiter_t *iter); +#endif + #if HAVE_GETIFADDRS #include "ifiter_getifaddrs.c" #elif HAVE_IFLIST_SYSCTL @@ -151,6 +165,99 @@ get_addr(unsigned int family, isc_netaddr_t *dst, struct sockaddr *src, #include "ifiter_ioctl.c" #endif +#ifdef __linux +static void +linux_if_inet6_first(isc_interfaceiter_t *iter) { + if (iter->proc != NULL) { + rewind(iter->proc); + (void)linux_if_inet6_next(iter); + } else + iter->valid = ISC_R_NOMORE; +} + +static isc_result_t +linux_if_inet6_next(isc_interfaceiter_t *iter) { + if (iter->proc != NULL && + fgets(iter->entry, sizeof(iter->entry), iter->proc) != NULL) + iter->valid = ISC_R_SUCCESS; + else + iter->valid = ISC_R_NOMORE; + return (iter->valid); +} + +static isc_result_t +linux_if_inet6_current(isc_interfaceiter_t *iter) { + char address[33]; + char name[IF_NAMESIZE+1]; + struct in6_addr addr6; + unsigned int ifindex; + int prefix, scope, flags; + int res; + unsigned int i; + + if (iter->valid != ISC_R_SUCCESS) + return (iter->valid); + if (iter->proc == NULL) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, ISC_LOG_ERROR, + "/proc/net/if_inet6:iter->proc == NULL"); + return (ISC_R_FAILURE); + } + + res = sscanf(iter->entry, "%32[a-f0-9] %x %x %x %x %16s\n", + address, &ifindex, &prefix, &scope, &flags, name); + if (res != 6) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, ISC_LOG_ERROR, + "/proc/net/if_inet6:sscanf() -> %d (expected 6)", + res); + return (ISC_R_FAILURE); + } + if (strlen(address) != 32) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_INTERFACE, ISC_LOG_ERROR, + "/proc/net/if_inet6:strlen(%s) != 32", address); + return (ISC_R_FAILURE); + } + /* + ** Ignore DAD addresses -- + ** we can't bind to them until they are resolved + */ +#ifdef IFA_F_TENTATIVE + if (flags & IFA_F_TENTATIVE) + return (ISC_R_IGNORE); +#endif + + for (i = 0; i < 16; i++) { + unsigned char byte; + static const char hex[] = "0123456789abcdef"; + byte = ((strchr(hex, address[i * 2]) - hex) << 4) | + (strchr(hex, address[i * 2 + 1]) - hex); + addr6.s6_addr[i] = byte; + } + iter->current.af = AF_INET6; + iter->current.flags = INTERFACE_F_UP; + isc_netaddr_fromin6(&iter->current.address, &addr6); + iter->current.ifindex = ifindex; + if (isc_netaddr_islinklocal(&iter->current.address)) { + isc_netaddr_setzone(&iter->current.address, + (isc_uint32_t)ifindex); + } + for (i = 0; i < 16; i++) { + if (prefix > 8) { + addr6.s6_addr[i] = 0xff; + prefix -= 8; + } else { + addr6.s6_addr[i] = (0xff << (8 - prefix)) & 0xff; + prefix = 0; + } + } + isc_netaddr_fromin6(&iter->current.netmask, &addr6); + strncpy(iter->current.name, name, sizeof(iter->current.name)); + return (ISC_R_SUCCESS); +} +#endif + /* * The remaining code is common to the sysctl and ioctl case. */ diff --git a/contrib/ntp/lib/isc/unix/ipv6.c b/contrib/ntp/lib/isc/unix/ipv6.c new file mode 100644 index 000000000..61e984f09 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/ipv6.c @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2004-2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ipv6.c,v 1.14 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include + +const struct in6_addr in6addr_any = IN6ADDR_ANY_INIT; +const struct in6_addr in6addr_loopback = IN6ADDR_LOOPBACK_INIT; diff --git a/contrib/ntp/lib/isc/unix/keyboard.c b/contrib/ntp/lib/isc/unix/keyboard.c new file mode 100644 index 000000000..8ee62d3f5 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/keyboard.c @@ -0,0 +1,126 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: keyboard.c,v 1.13 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +#include +#include + +isc_result_t +isc_keyboard_open(isc_keyboard_t *keyboard) { + int fd; + isc_result_t ret; + struct termios current_mode; + + REQUIRE(keyboard != NULL); + + fd = open("/dev/tty", O_RDONLY, 0); + if (fd < 0) + return (ISC_R_IOERROR); + + keyboard->fd = fd; + + if (tcgetattr(fd, &keyboard->saved_mode) < 0) { + ret = ISC_R_IOERROR; + goto errout; + } + + current_mode = keyboard->saved_mode; + + current_mode.c_iflag &= + ~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON); + current_mode.c_oflag &= ~OPOST; + current_mode.c_lflag &= ~(ECHO|ECHONL|ICANON|ISIG|IEXTEN); + current_mode.c_cflag &= ~(CSIZE|PARENB); + current_mode.c_cflag |= CS8; + + current_mode.c_cc[VMIN] = 1; + current_mode.c_cc[VTIME] = 0; + if (tcsetattr(fd, TCSAFLUSH, ¤t_mode) < 0) { + ret = ISC_R_IOERROR; + goto errout; + } + + keyboard->result = ISC_R_SUCCESS; + + return (ISC_R_SUCCESS); + + errout: + close (fd); + + return (ret); +} + +isc_result_t +isc_keyboard_close(isc_keyboard_t *keyboard, unsigned int sleeptime) { + REQUIRE(keyboard != NULL); + + if (sleeptime > 0 && keyboard->result != ISC_R_CANCELED) + (void)sleep(sleeptime); + + (void)tcsetattr(keyboard->fd, TCSAFLUSH, &keyboard->saved_mode); + (void)close(keyboard->fd); + + keyboard->fd = -1; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_keyboard_getchar(isc_keyboard_t *keyboard, unsigned char *cp) { + ssize_t cc; + unsigned char c; + cc_t *controlchars; + + REQUIRE(keyboard != NULL); + REQUIRE(cp != NULL); + + cc = read(keyboard->fd, &c, 1); + if (cc < 0) { + keyboard->result = ISC_R_IOERROR; + return (keyboard->result); + } + + controlchars = keyboard->saved_mode.c_cc; + if (c == controlchars[VINTR] || c == controlchars[VQUIT]) { + keyboard->result = ISC_R_CANCELED; + return (keyboard->result); + } + + *cp = c; + + return (ISC_R_SUCCESS); +} + +isc_boolean_t +isc_keyboard_canceled(isc_keyboard_t *keyboard) { + return (ISC_TF(keyboard->result == ISC_R_CANCELED)); +} diff --git a/contrib/ntp/lib/isc/unix/net.c b/contrib/ntp/lib/isc/unix/net.c new file mode 100644 index 000000000..7056668ca --- /dev/null +++ b/contrib/ntp/lib/isc/unix/net.c @@ -0,0 +1,523 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#include + +#include + +#if defined(HAVE_SYS_SYSCTL_H) +#if defined(HAVE_SYS_PARAM_H) +#include +#endif +#include +#endif + +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +/*% + * Definitions about UDP port range specification. This is a total mess of + * portability variants: some use sysctl (but the sysctl names vary), some use + * system-specific interfaces, some have the same interface for IPv4 and IPv6, + * some separate them, etc... + */ + +/*% + * The last resort defaults: use all non well known port space + */ +#ifndef ISC_NET_PORTRANGELOW +#define ISC_NET_PORTRANGELOW 1024 +#endif /* ISC_NET_PORTRANGELOW */ +#ifndef ISC_NET_PORTRANGEHIGH +#define ISC_NET_PORTRANGEHIGH 65535 +#endif /* ISC_NET_PORTRANGEHIGH */ + +#ifdef HAVE_SYSCTLBYNAME + +/*% + * sysctl variants + */ +#if defined(__FreeBSD__) || defined(__APPLE__) || defined(__DragonFly__) +#define USE_SYSCTL_PORTRANGE +#define SYSCTL_V4PORTRANGE_LOW "net.inet.ip.portrange.hifirst" +#define SYSCTL_V4PORTRANGE_HIGH "net.inet.ip.portrange.hilast" +#define SYSCTL_V6PORTRANGE_LOW "net.inet.ip.portrange.hifirst" +#define SYSCTL_V6PORTRANGE_HIGH "net.inet.ip.portrange.hilast" +#endif + +#ifdef __NetBSD__ +#define USE_SYSCTL_PORTRANGE +#define SYSCTL_V4PORTRANGE_LOW "net.inet.ip.anonportmin" +#define SYSCTL_V4PORTRANGE_HIGH "net.inet.ip.anonportmax" +#define SYSCTL_V6PORTRANGE_LOW "net.inet6.ip6.anonportmin" +#define SYSCTL_V6PORTRANGE_HIGH "net.inet6.ip6.anonportmax" +#endif + +#else /* !HAVE_SYSCTLBYNAME */ + +#ifdef __OpenBSD__ +#define USE_SYSCTL_PORTRANGE +#define SYSCTL_V4PORTRANGE_LOW { CTL_NET, PF_INET, IPPROTO_IP, \ + IPCTL_IPPORT_HIFIRSTAUTO } +#define SYSCTL_V4PORTRANGE_HIGH { CTL_NET, PF_INET, IPPROTO_IP, \ + IPCTL_IPPORT_HILASTAUTO } +/* Same for IPv6 */ +#define SYSCTL_V6PORTRANGE_LOW SYSCTL_V4PORTRANGE_LOW +#define SYSCTL_V6PORTRANGE_HIGH SYSCTL_V4PORTRANGE_HIGH +#endif + +#endif /* HAVE_SYSCTLBYNAME */ + +#if defined(ISC_PLATFORM_NEEDIN6ADDRANY) +const struct in6_addr isc_net_in6addrany = IN6ADDR_ANY_INIT; +#endif + +#if defined(ISC_PLATFORM_HAVEIPV6) + +# if defined(ISC_PLATFORM_NEEDIN6ADDRLOOPBACK) +const struct in6_addr isc_net_in6addrloop = IN6ADDR_LOOPBACK_INIT; +# endif + +# if defined(WANT_IPV6) +static isc_once_t once_ipv6only = ISC_ONCE_INIT; +# endif + +# if defined(ISC_PLATFORM_HAVEIPV6) && \ + defined(WANT_IPV6) && defined(ISC_PLATFORM_HAVEIN6PKTINFO) +static isc_once_t once_ipv6pktinfo = ISC_ONCE_INIT; +# endif +#endif /* ISC_PLATFORM_HAVEIPV6 */ + +static isc_once_t once = ISC_ONCE_INIT; + +static isc_result_t ipv4_result = ISC_R_NOTFOUND; +static isc_result_t ipv6_result = ISC_R_NOTFOUND; +static isc_result_t unix_result = ISC_R_NOTFOUND; +static isc_result_t ipv6only_result = ISC_R_NOTFOUND; +static isc_result_t ipv6pktinfo_result = ISC_R_NOTFOUND; + +static isc_result_t +try_proto(int domain) { + int s; + isc_result_t result = ISC_R_SUCCESS; + char strbuf[ISC_STRERRORSIZE]; + + s = socket(domain, SOCK_STREAM, 0); + if (s == -1) { + switch (errno) { +#ifdef EAFNOSUPPORT + case EAFNOSUPPORT: +#endif +#ifdef EPROTONOSUPPORT + case EPROTONOSUPPORT: +#endif +#ifdef EINVAL + case EINVAL: +#endif + return (ISC_R_NOTFOUND); + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + return (ISC_R_UNEXPECTED); + } + } + +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + if (domain == PF_INET6) { + struct sockaddr_in6 sin6; + GETSOCKNAME_SOCKLEN_TYPE len; /* NTP local change */ + + /* + * Check to see if IPv6 is broken, as is common on Linux. + */ + len = sizeof(sin6); + if (getsockname(s, (struct sockaddr *)&sin6, &len) < 0) + { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "retrieving the address of an IPv6 " + "socket from the kernel failed."); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "IPv6 is not supported."); + result = ISC_R_NOTFOUND; + } else { + if (len == sizeof(struct sockaddr_in6)) + result = ISC_R_SUCCESS; + else { + isc_log_write(isc_lctx, + ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_ERROR, + "IPv6 structures in kernel and " + "user space do not match."); + isc_log_write(isc_lctx, + ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_ERROR, + "IPv6 is not supported."); + result = ISC_R_NOTFOUND; + } + } + } +#endif +#endif +#endif + + (void)close(s); + + return (result); +} + +static void +initialize_action(void) { + ipv4_result = try_proto(PF_INET); +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + ipv6_result = try_proto(PF_INET6); +#endif +#endif +#endif +#ifdef ISC_PLATFORM_HAVESYSUNH + unix_result = try_proto(PF_UNIX); +#endif +} + +static void +initialize(void) { + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); +} + +isc_result_t +isc_net_probeipv4(void) { + initialize(); + return (ipv4_result); +} + +isc_result_t +isc_net_probeipv6(void) { + initialize(); + return (ipv6_result); +} + +isc_result_t +isc_net_probeunix(void) { + initialize(); + return (unix_result); +} + +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 +static void +try_ipv6only(void) { +#ifdef IPV6_V6ONLY + int s, on; + char strbuf[ISC_STRERRORSIZE]; +#endif + isc_result_t result; + + result = isc_net_probeipv6(); + if (result != ISC_R_SUCCESS) { + ipv6only_result = result; + return; + } + +#ifndef IPV6_V6ONLY + ipv6only_result = ISC_R_NOTFOUND; + return; +#else + /* check for TCP sockets */ + s = socket(PF_INET6, SOCK_STREAM, 0); + if (s == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + ipv6only_result = ISC_R_UNEXPECTED; + return; + } + + on = 1; + if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { + ipv6only_result = ISC_R_NOTFOUND; + goto close; + } + + close(s); + + /* check for UDP sockets */ + s = socket(PF_INET6, SOCK_DGRAM, 0); + if (s == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + ipv6only_result = ISC_R_UNEXPECTED; + return; + } + + on = 1; + if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { + ipv6only_result = ISC_R_NOTFOUND; + goto close; + } + + ipv6only_result = ISC_R_SUCCESS; + +close: + close(s); + return; +#endif /* IPV6_V6ONLY */ +} + +static void +initialize_ipv6only(void) { + RUNTIME_CHECK(isc_once_do(&once_ipv6only, + try_ipv6only) == ISC_R_SUCCESS); +} + +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +static void +try_ipv6pktinfo(void) { + int s, on; + char strbuf[ISC_STRERRORSIZE]; + isc_result_t result; + int optname; + + result = isc_net_probeipv6(); + if (result != ISC_R_SUCCESS) { + ipv6pktinfo_result = result; + return; + } + + /* we only use this for UDP sockets */ + s = socket(PF_INET6, SOCK_DGRAM, IPPROTO_UDP); + if (s == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + ipv6pktinfo_result = ISC_R_UNEXPECTED; + return; + } + +#ifdef IPV6_RECVPKTINFO + optname = IPV6_RECVPKTINFO; +#else + optname = IPV6_PKTINFO; +#endif + on = 1; + if (setsockopt(s, IPPROTO_IPV6, optname, &on, sizeof(on)) < 0) { + ipv6pktinfo_result = ISC_R_NOTFOUND; + goto close; + } + + ipv6pktinfo_result = ISC_R_SUCCESS; + +close: + close(s); + return; +} + +static void +initialize_ipv6pktinfo(void) { + RUNTIME_CHECK(isc_once_do(&once_ipv6pktinfo, + try_ipv6pktinfo) == ISC_R_SUCCESS); +} +#endif /* ISC_PLATFORM_HAVEIN6PKTINFO */ +#endif /* WANT_IPV6 */ +#endif /* ISC_PLATFORM_HAVEIPV6 */ + +isc_result_t +isc_net_probe_ipv6only(void) { +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef WANT_IPV6 + initialize_ipv6only(); +#else + ipv6only_result = ISC_R_NOTFOUND; +#endif +#endif + return (ipv6only_result); +} + +isc_result_t +isc_net_probe_ipv6pktinfo(void) { +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +#ifdef WANT_IPV6 + initialize_ipv6pktinfo(); +#else + ipv6pktinfo_result = ISC_R_NOTFOUND; +#endif +#endif +#endif + return (ipv6pktinfo_result); +} + +#if defined(USE_SYSCTL_PORTRANGE) +#if defined(HAVE_SYSCTLBYNAME) +static isc_result_t +getudpportrange_sysctl(int af, in_port_t *low, in_port_t *high) { + int port_low, port_high; + size_t portlen; + const char *sysctlname_lowport, *sysctlname_hiport; + + if (af == AF_INET) { + sysctlname_lowport = SYSCTL_V4PORTRANGE_LOW; + sysctlname_hiport = SYSCTL_V4PORTRANGE_HIGH; + } else { + sysctlname_lowport = SYSCTL_V6PORTRANGE_LOW; + sysctlname_hiport = SYSCTL_V6PORTRANGE_HIGH; + } + portlen = sizeof(portlen); + if (sysctlbyname(sysctlname_lowport, &port_low, &portlen, + NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + portlen = sizeof(portlen); + if (sysctlbyname(sysctlname_hiport, &port_high, &portlen, + NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + if ((port_low & ~0xffff) != 0 || (port_high & ~0xffff) != 0) + return (ISC_R_RANGE); + + *low = (in_port_t)port_low; + *high = (in_port_t)port_high; + + return (ISC_R_SUCCESS); +} +#else /* !HAVE_SYSCTLBYNAME */ +static isc_result_t +getudpportrange_sysctl(int af, in_port_t *low, in_port_t *high) { + int mib_lo4[4] = SYSCTL_V4PORTRANGE_LOW; + int mib_hi4[4] = SYSCTL_V4PORTRANGE_HIGH; + int mib_lo6[4] = SYSCTL_V6PORTRANGE_LOW; + int mib_hi6[4] = SYSCTL_V6PORTRANGE_HIGH; + int *mib_lo, *mib_hi, miblen; + int port_low, port_high; + size_t portlen; + + if (af == AF_INET) { + mib_lo = mib_lo4; + mib_hi = mib_hi4; + miblen = sizeof(mib_lo4) / sizeof(mib_lo4[0]); + } else { + mib_lo = mib_lo6; + mib_hi = mib_hi6; + miblen = sizeof(mib_lo6) / sizeof(mib_lo6[0]); + } + + portlen = sizeof(portlen); + if (sysctl(mib_lo, miblen, &port_low, &portlen, NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + + portlen = sizeof(portlen); + if (sysctl(mib_hi, miblen, &port_high, &portlen, NULL, 0) < 0) { + return (ISC_R_FAILURE); + } + + if ((port_low & ~0xffff) != 0 || (port_high & ~0xffff) != 0) + return (ISC_R_RANGE); + + *low = (in_port_t) port_low; + *high = (in_port_t) port_high; + + return (ISC_R_SUCCESS); +} +#endif /* HAVE_SYSCTLBYNAME */ +#endif /* USE_SYSCTL_PORTRANGE */ + +isc_result_t +isc_net_getudpportrange(int af, in_port_t *low, in_port_t *high) { + int result = ISC_R_FAILURE; + + REQUIRE(low != NULL && high != NULL); + +#if defined(USE_SYSCTL_PORTRANGE) + result = getudpportrange_sysctl(af, low, high); +#else + UNUSED(af); +#endif + + if (result != ISC_R_SUCCESS) { + *low = ISC_NET_PORTRANGELOW; + *high = ISC_NET_PORTRANGEHIGH; + } + + return (ISC_R_SUCCESS); /* we currently never fail in this function */ +} + +void +isc_net_disableipv4(void) { + initialize(); + if (ipv4_result == ISC_R_SUCCESS) + ipv4_result = ISC_R_DISABLED; +} + +void +isc_net_disableipv6(void) { + initialize(); + if (ipv6_result == ISC_R_SUCCESS) + ipv6_result = ISC_R_DISABLED; +} + +void +isc_net_enableipv4(void) { + initialize(); + if (ipv4_result == ISC_R_DISABLED) + ipv4_result = ISC_R_SUCCESS; +} + +void +isc_net_enableipv6(void) { + initialize(); + if (ipv6_result == ISC_R_DISABLED) + ipv6_result = ISC_R_SUCCESS; +} diff --git a/contrib/ntp/lib/isc/unix/os.c b/contrib/ntp/lib/isc/unix/os.c new file mode 100644 index 000000000..c050d14c3 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/os.c @@ -0,0 +1,94 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: os.c,v 1.18 2007/06/19 23:47:18 tbox Exp $ */ + +#include + +#include + + +#ifdef HAVE_SYSCONF + +#include + +#ifndef __hpux +static inline long +sysconf_ncpus(void) { +#if defined(_SC_NPROCESSORS_ONLN) + return sysconf((_SC_NPROCESSORS_ONLN)); +#elif defined(_SC_NPROC_ONLN) + return sysconf((_SC_NPROC_ONLN)); +#else + return (0); +#endif +} +#endif +#endif /* HAVE_SYSCONF */ + + +#ifdef __hpux + +#include + +static inline int +hpux_ncpus(void) { + struct pst_dynamic psd; + if (pstat_getdynamic(&psd, sizeof(psd), 1, 0) != -1) + return (psd.psd_proc_cnt); + else + return (0); +} + +#endif /* __hpux */ + +#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_SYSCTLBYNAME) +#include /* for FreeBSD */ +#include /* for NetBSD */ +#include + +static int +sysctl_ncpus(void) { + int ncpu, result; + size_t len; + + len = sizeof(ncpu); + result = sysctlbyname("hw.ncpu", &ncpu, &len , 0, 0); + if (result != -1) + return (ncpu); + return (0); +} +#endif + +unsigned int +isc_os_ncpus(void) { + long ncpus = 0; + +#ifdef __hpux + ncpus = hpux_ncpus(); +#elif defined(HAVE_SYSCONF) + ncpus = sysconf_ncpus(); +#endif +#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_SYSCTLBYNAME) + if (ncpus <= 0) + ncpus = sysctl_ncpus(); +#endif + if (ncpus <= 0) + ncpus = 1; + + return ((unsigned int)ncpus); +} diff --git a/contrib/ntp/lib/isc/unix/resource.c b/contrib/ntp/lib/isc/unix/resource.c new file mode 100644 index 000000000..29596e2aa --- /dev/null +++ b/contrib/ntp/lib/isc/unix/resource.c @@ -0,0 +1,231 @@ +/* + * Copyright (C) 2004, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: resource.c,v 1.23 2009/02/13 23:48:14 tbox Exp $ */ + +#include + +#include +#include /* Required on some systems for . */ +#include + +#include +#include +#include +#include + +#ifdef __linux__ +#include /* To get the large NR_OPEN. */ +#endif + +#if defined(__hpux) && defined(HAVE_SYS_DYNTUNE_H) +#include +#endif + +#include "errno2result.h" + +static isc_result_t +resource2rlim(isc_resource_t resource, int *rlim_resource) { + isc_result_t result = ISC_R_SUCCESS; + + switch (resource) { + case isc_resource_coresize: + *rlim_resource = RLIMIT_CORE; + break; + case isc_resource_cputime: + *rlim_resource = RLIMIT_CPU; + break; + case isc_resource_datasize: + *rlim_resource = RLIMIT_DATA; + break; + case isc_resource_filesize: + *rlim_resource = RLIMIT_FSIZE; + break; + case isc_resource_lockedmemory: +#ifdef RLIMIT_MEMLOCK + *rlim_resource = RLIMIT_MEMLOCK; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_openfiles: +#ifdef RLIMIT_NOFILE + *rlim_resource = RLIMIT_NOFILE; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_processes: +#ifdef RLIMIT_NPROC + *rlim_resource = RLIMIT_NPROC; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_residentsize: +#ifdef RLIMIT_RSS + *rlim_resource = RLIMIT_RSS; +#else + result = ISC_R_NOTIMPLEMENTED; +#endif + break; + case isc_resource_stacksize: + *rlim_resource = RLIMIT_STACK; + break; + default: + /* + * This test is not very robust if isc_resource_t + * changes, but generates a clear assertion message. + */ + REQUIRE(resource >= isc_resource_coresize && + resource <= isc_resource_stacksize); + + result = ISC_R_RANGE; + break; + } + + return (result); +} + +isc_result_t +isc_resource_setlimit(isc_resource_t resource, isc_resourcevalue_t value) { + struct rlimit rl; + ISC_PLATFORM_RLIMITTYPE rlim_value; + int unixresult; + int unixresource; + isc_result_t result; + + result = resource2rlim(resource, &unixresource); + if (result != ISC_R_SUCCESS) + return (result); + + if (value == ISC_RESOURCE_UNLIMITED) + rlim_value = RLIM_INFINITY; + + else { + /* + * isc_resourcevalue_t was chosen as an unsigned 64 bit + * integer so that it could contain the maximum range of + * reasonable values. Unfortunately, this exceeds the typical + * range on Unix systems. Ensure the range of + * ISC_PLATFORM_RLIMITTYPE is not overflowed. + */ + isc_resourcevalue_t rlim_max; + isc_boolean_t rlim_t_is_signed = + ISC_TF(((double)(ISC_PLATFORM_RLIMITTYPE)-1) < 0); + + if (rlim_t_is_signed) + rlim_max = ~((ISC_PLATFORM_RLIMITTYPE)1 << + (sizeof(ISC_PLATFORM_RLIMITTYPE) * 8 - 1)); + else + rlim_max = (ISC_PLATFORM_RLIMITTYPE)-1; + + if (value > rlim_max) + value = rlim_max; + + rlim_value = value; + } + + rl.rlim_cur = rl.rlim_max = rlim_value; + unixresult = setrlimit(unixresource, &rl); + + if (unixresult == 0) + return (ISC_R_SUCCESS); + +#if defined(OPEN_MAX) && defined(__APPLE__) + /* + * The Darwin kernel doesn't accept RLIM_INFINITY for rlim_cur; the + * maximum possible value is OPEN_MAX. BIND8 used to use + * sysconf(_SC_OPEN_MAX) for such a case, but this value is much + * smaller than OPEN_MAX and is not really effective. + */ + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + rl.rlim_cur = OPEN_MAX; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } +#elif defined(__linux__) +#ifndef NR_OPEN +#define NR_OPEN (1024*1024) +#endif + + /* + * Some Linux kernels don't accept RLIM_INFINIT; the maximum + * possible value is the NR_OPEN defined in linux/fs.h. + */ + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + rl.rlim_cur = rl.rlim_max = NR_OPEN; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } +#elif defined(__hpux) && defined(HAVE_SYS_DYNTUNE_H) + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + uint64_t maxfiles; + if (gettune("maxfiles_lim", &maxfiles) == 0) { + rl.rlim_cur = rl.rlim_max = maxfiles; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } + } +#endif + if (resource == isc_resource_openfiles && rlim_value == RLIM_INFINITY) { + if (getrlimit(unixresource, &rl) == 0) { + rl.rlim_cur = rl.rlim_max; + unixresult = setrlimit(unixresource, &rl); + if (unixresult == 0) + return (ISC_R_SUCCESS); + } + } + return (isc__errno2result(errno)); +} + +isc_result_t +isc_resource_getlimit(isc_resource_t resource, isc_resourcevalue_t *value) { + int unixresult; + int unixresource; + struct rlimit rl; + isc_result_t result; + + result = resource2rlim(resource, &unixresource); + if (result == ISC_R_SUCCESS) { + unixresult = getrlimit(unixresource, &rl); + INSIST(unixresult == 0); + *value = rl.rlim_max; + } + + return (result); +} + +isc_result_t +isc_resource_getcurlimit(isc_resource_t resource, isc_resourcevalue_t *value) { + int unixresult; + int unixresource; + struct rlimit rl; + isc_result_t result; + + result = resource2rlim(resource, &unixresource); + if (result == ISC_R_SUCCESS) { + unixresult = getrlimit(unixresource, &rl); + INSIST(unixresult == 0); + *value = rl.rlim_cur; + } + + return (result); +} diff --git a/contrib/ntp/lib/isc/unix/socket.c b/contrib/ntp/lib/isc/unix/socket.c new file mode 100644 index 000000000..5fed888a1 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/socket.c @@ -0,0 +1,6011 @@ +/* + * Copyright (C) 2004-2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef ISC_PLATFORM_HAVESYSUNH +#include +#endif +#ifdef ISC_PLATFORM_HAVEKQUEUE +#include +#endif +#ifdef ISC_PLATFORM_HAVEEPOLL +#include +#endif +#ifdef ISC_PLATFORM_HAVEDEVPOLL +#if defined(HAVE_SYS_DEVPOLL_H) +#include +#elif defined(HAVE_DEVPOLL_H) +#include +#endif +#endif + +#include "errno2result.h" + +/* See task.c about the following definition: */ +#ifdef BIND9 +#ifdef ISC_PLATFORM_USETHREADS +#define USE_WATCHER_THREAD +#else +#define USE_SHARED_MANAGER +#endif /* ISC_PLATFORM_USETHREADS */ +#endif /* BIND9 */ + +#ifndef USE_WATCHER_THREAD +#include "socket_p.h" +#include "../task_p.h" +#endif /* USE_WATCHER_THREAD */ + +#if defined(SO_BSDCOMPAT) && defined(__linux__) +#include +#endif + +/*% + * Choose the most preferable multiplex method. + */ +#ifdef ISC_PLATFORM_HAVEKQUEUE +#define USE_KQUEUE +#elif defined (ISC_PLATFORM_HAVEEPOLL) +#define USE_EPOLL +#elif defined (ISC_PLATFORM_HAVEDEVPOLL) +#define USE_DEVPOLL +typedef struct { + unsigned int want_read : 1, + want_write : 1; +} pollinfo_t; +#else +#define USE_SELECT +#endif /* ISC_PLATFORM_HAVEKQUEUE */ + +#ifndef USE_WATCHER_THREAD +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) +struct isc_socketwait { + int nevents; +}; +#elif defined (USE_SELECT) +struct isc_socketwait { + fd_set *readset; + fd_set *writeset; + int nfds; + int maxfd; +}; +#endif /* USE_KQUEUE */ +#endif /* !USE_WATCHER_THREAD */ + +/*% + * Maximum number of allowable open sockets. This is also the maximum + * allowable socket file descriptor. + * + * Care should be taken before modifying this value for select(): + * The API standard doesn't ensure select() accept more than (the system default + * of) FD_SETSIZE descriptors, and the default size should in fact be fine in + * the vast majority of cases. This constant should therefore be increased only + * when absolutely necessary and possible, i.e., the server is exhausting all + * available file descriptors (up to FD_SETSIZE) and the select() function + * and FD_xxx macros support larger values than FD_SETSIZE (which may not + * always by true, but we keep using some of them to ensure as much + * portability as possible). Note also that overall server performance + * may be rather worsened with a larger value of this constant due to + * inherent scalability problems of select(). + * + * As a special note, this value shouldn't have to be touched if + * this is a build for an authoritative only DNS server. + */ +#ifndef ISC_SOCKET_MAXSOCKETS +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) +#define ISC_SOCKET_MAXSOCKETS 4096 +#elif defined(USE_SELECT) +#define ISC_SOCKET_MAXSOCKETS FD_SETSIZE +#endif /* USE_KQUEUE... */ +#endif /* ISC_SOCKET_MAXSOCKETS */ + +#ifdef USE_SELECT +/*% + * Mac OS X needs a special definition to support larger values in select(). + * We always define this because a larger value can be specified run-time. + */ +#ifdef __APPLE__ +#define _DARWIN_UNLIMITED_SELECT +#endif /* __APPLE__ */ +#endif /* USE_SELECT */ + +#ifdef ISC_SOCKET_USE_POLLWATCH +/*% + * If this macro is defined, enable workaround for a Solaris /dev/poll kernel + * bug: DP_POLL ioctl could keep sleeping even if socket I/O is possible for + * some of the specified FD. The idea is based on the observation that it's + * likely for a busy server to keep receiving packets. It specifically works + * as follows: the socket watcher is first initialized with the state of + * "poll_idle". While it's in the idle state it keeps sleeping until a socket + * event occurs. When it wakes up for a socket I/O event, it moves to the + * poll_active state, and sets the poll timeout to a short period + * (ISC_SOCKET_POLLWATCH_TIMEOUT msec). If timeout occurs in this state, the + * watcher goes to the poll_checking state with the same timeout period. + * In this state, the watcher tries to detect whether this is a break + * during intermittent events or the kernel bug is triggered. If the next + * polling reports an event within the short period, the previous timeout is + * likely to be a kernel bug, and so the watcher goes back to the active state. + * Otherwise, it moves to the idle state again. + * + * It's not clear whether this is a thread-related bug, but since we've only + * seen this with threads, this workaround is used only when enabling threads. + */ + +typedef enum { poll_idle, poll_active, poll_checking } pollstate_t; + +#ifndef ISC_SOCKET_POLLWATCH_TIMEOUT +#define ISC_SOCKET_POLLWATCH_TIMEOUT 10 +#endif /* ISC_SOCKET_POLLWATCH_TIMEOUT */ +#endif /* ISC_SOCKET_USE_POLLWATCH */ + +/*% + * Size of per-FD lock buckets. + */ +#ifdef ISC_PLATFORM_USETHREADS +#define FDLOCK_COUNT 1024 +#define FDLOCK_ID(fd) ((fd) % FDLOCK_COUNT) +#else +#define FDLOCK_COUNT 1 +#define FDLOCK_ID(fd) 0 +#endif /* ISC_PLATFORM_USETHREADS */ + +/*% + * Maximum number of events communicated with the kernel. There should normally + * be no need for having a large number. + */ +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) +#ifndef ISC_SOCKET_MAXEVENTS +#define ISC_SOCKET_MAXEVENTS 64 +#endif +#endif + +/*% + * Some systems define the socket length argument as an int, some as size_t, + * some as socklen_t. This is here so it can be easily changed if needed. + */ +#ifndef ISC_SOCKADDR_LEN_T +#define ISC_SOCKADDR_LEN_T unsigned int +#endif + +/*% + * Define what the possible "soft" errors can be. These are non-fatal returns + * of various network related functions, like recv() and so on. + * + * For some reason, BSDI (and perhaps others) will sometimes return <0 + * from recv() but will have errno==0. This is broken, but we have to + * work around it here. + */ +#define SOFT_ERROR(e) ((e) == EAGAIN || \ + (e) == EWOULDBLOCK || \ + (e) == EINTR || \ + (e) == 0) + +#define DLVL(x) ISC_LOGCATEGORY_GENERAL, ISC_LOGMODULE_SOCKET, ISC_LOG_DEBUG(x) + +/*!< + * DLVL(90) -- Function entry/exit and other tracing. + * DLVL(70) -- Socket "correctness" -- including returning of events, etc. + * DLVL(60) -- Socket data send/receive + * DLVL(50) -- Event tracing, including receiving/sending completion events. + * DLVL(20) -- Socket creation/destruction. + */ +#define TRACE_LEVEL 90 +#define CORRECTNESS_LEVEL 70 +#define IOEVENT_LEVEL 60 +#define EVENT_LEVEL 50 +#define CREATION_LEVEL 20 + +#define TRACE DLVL(TRACE_LEVEL) +#define CORRECTNESS DLVL(CORRECTNESS_LEVEL) +#define IOEVENT DLVL(IOEVENT_LEVEL) +#define EVENT DLVL(EVENT_LEVEL) +#define CREATION DLVL(CREATION_LEVEL) + +typedef isc_event_t intev_t; + +#define SOCKET_MAGIC ISC_MAGIC('I', 'O', 'i', 'o') +#define VALID_SOCKET(s) ISC_MAGIC_VALID(s, SOCKET_MAGIC) + +/*! + * IPv6 control information. If the socket is an IPv6 socket we want + * to collect the destination address and interface so the client can + * set them on outgoing packets. + */ +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +#ifndef USE_CMSG +#define USE_CMSG 1 +#endif +#endif + +/*% + * NetBSD and FreeBSD can timestamp packets. XXXMLG Should we have + * a setsockopt() like interface to request timestamps, and if the OS + * doesn't do it for us, call gettimeofday() on every UDP receive? + */ +#ifdef SO_TIMESTAMP +#ifndef USE_CMSG +#define USE_CMSG 1 +#endif +#endif + +/*% + * The size to raise the receive buffer to (from BIND 8). + */ +#define RCVBUFSIZE (32*1024) + +/*% + * The number of times a send operation is repeated if the result is EINTR. + */ +#define NRETRIES 10 + +typedef struct isc__socket isc__socket_t; +typedef struct isc__socketmgr isc__socketmgr_t; + +#define NEWCONNSOCK(ev) ((isc__socket_t *)(ev)->newsocket) + +struct isc__socket { + /* Not locked. */ + isc_socket_t common; + isc__socketmgr_t *manager; + isc_mutex_t lock; + isc_sockettype_t type; + const isc_statscounter_t *statsindex; + + /* Locked by socket lock. */ + ISC_LINK(isc__socket_t) link; + unsigned int references; + int fd; + int pf; + char name[16]; + void * tag; + + ISC_LIST(isc_socketevent_t) send_list; + ISC_LIST(isc_socketevent_t) recv_list; + ISC_LIST(isc_socket_newconnev_t) accept_list; + isc_socket_connev_t *connect_ev; + + /* + * Internal events. Posted when a descriptor is readable or + * writable. These are statically allocated and never freed. + * They will be set to non-purgable before use. + */ + intev_t readable_ev; + intev_t writable_ev; + + isc_sockaddr_t peer_address; /* remote address */ + + unsigned int pending_recv : 1, + pending_send : 1, + pending_accept : 1, + listener : 1, /* listener socket */ + connected : 1, + connecting : 1, /* connect pending */ + bound : 1, /* bound to local addr */ + dupped : 1; + +#ifdef ISC_NET_RECVOVERFLOW + unsigned char overflow; /* used for MSG_TRUNC fake */ +#endif + + char *recvcmsgbuf; + ISC_SOCKADDR_LEN_T recvcmsgbuflen; + char *sendcmsgbuf; + ISC_SOCKADDR_LEN_T sendcmsgbuflen; + + void *fdwatcharg; + isc_sockfdwatch_t fdwatchcb; + int fdwatchflags; + isc_task_t *fdwatchtask; +}; + +#define SOCKET_MANAGER_MAGIC ISC_MAGIC('I', 'O', 'm', 'g') +#define VALID_MANAGER(m) ISC_MAGIC_VALID(m, SOCKET_MANAGER_MAGIC) + +struct isc__socketmgr { + /* Not locked. */ + isc_socketmgr_t common; + isc_mem_t *mctx; + isc_mutex_t lock; + isc_mutex_t *fdlock; + isc_stats_t *stats; +#ifdef USE_KQUEUE + int kqueue_fd; + int nevents; + struct kevent *events; +#endif /* USE_KQUEUE */ +#ifdef USE_EPOLL + int epoll_fd; + int nevents; + struct epoll_event *events; +#endif /* USE_EPOLL */ +#ifdef USE_DEVPOLL + int devpoll_fd; + int nevents; + struct pollfd *events; +#endif /* USE_DEVPOLL */ +#ifdef USE_SELECT + int fd_bufsize; +#endif /* USE_SELECT */ + unsigned int maxsocks; +#ifdef ISC_PLATFORM_USETHREADS + int pipe_fds[2]; +#endif + + /* Locked by fdlock. */ + isc__socket_t **fds; + int *fdstate; +#ifdef USE_DEVPOLL + pollinfo_t *fdpollinfo; +#endif + + /* Locked by manager lock. */ + ISC_LIST(isc__socket_t) socklist; +#ifdef USE_SELECT + fd_set *read_fds; + fd_set *read_fds_copy; + fd_set *write_fds; + fd_set *write_fds_copy; + int maxfd; +#endif /* USE_SELECT */ + int reserved; /* unlocked */ +#ifdef USE_WATCHER_THREAD + isc_thread_t watcher; + isc_condition_t shutdown_ok; +#else /* USE_WATCHER_THREAD */ + unsigned int refs; +#endif /* USE_WATCHER_THREAD */ + int maxudp; +}; + +#ifdef USE_SHARED_MANAGER +static isc__socketmgr_t *socketmgr = NULL; +#endif /* USE_SHARED_MANAGER */ + +#define CLOSED 0 /* this one must be zero */ +#define MANAGED 1 +#define CLOSE_PENDING 2 + +/* + * send() and recv() iovec counts + */ +#define MAXSCATTERGATHER_SEND (ISC_SOCKET_MAXSCATTERGATHER) +#ifdef ISC_NET_RECVOVERFLOW +# define MAXSCATTERGATHER_RECV (ISC_SOCKET_MAXSCATTERGATHER + 1) +#else +# define MAXSCATTERGATHER_RECV (ISC_SOCKET_MAXSCATTERGATHER) +#endif + +static isc_result_t socket_create(isc_socketmgr_t *manager0, int pf, + isc_sockettype_t type, + isc_socket_t **socketp, + isc_socket_t *dup_socket); +static void send_recvdone_event(isc__socket_t *, isc_socketevent_t **); +static void send_senddone_event(isc__socket_t *, isc_socketevent_t **); +static void free_socket(isc__socket_t **); +static isc_result_t allocate_socket(isc__socketmgr_t *, isc_sockettype_t, + isc__socket_t **); +static void destroy(isc__socket_t **); +static void internal_accept(isc_task_t *, isc_event_t *); +static void internal_connect(isc_task_t *, isc_event_t *); +static void internal_recv(isc_task_t *, isc_event_t *); +static void internal_send(isc_task_t *, isc_event_t *); +static void internal_fdwatch_write(isc_task_t *, isc_event_t *); +static void internal_fdwatch_read(isc_task_t *, isc_event_t *); +static void process_cmsg(isc__socket_t *, struct msghdr *, isc_socketevent_t *); +static void build_msghdr_send(isc__socket_t *, isc_socketevent_t *, + struct msghdr *, struct iovec *, size_t *); +static void build_msghdr_recv(isc__socket_t *, isc_socketevent_t *, + struct msghdr *, struct iovec *, size_t *); +#ifdef USE_WATCHER_THREAD +static isc_boolean_t process_ctlfd(isc__socketmgr_t *manager); +#endif + +/*% + * The following can be either static or public, depending on build environment. + */ + +#ifdef BIND9 +#define ISC_SOCKETFUNC_SCOPE +#else +#define ISC_SOCKETFUNC_SCOPE static +#endif + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type, + isc_socket_t **socketp); +ISC_SOCKETFUNC_SCOPE void +isc__socket_attach(isc_socket_t *sock, isc_socket_t **socketp); +ISC_SOCKETFUNC_SCOPE void +isc__socket_detach(isc_socket_t **socketp); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socketmgr_create(isc_mem_t *mctx, isc_socketmgr_t **managerp); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socketmgr_create2(isc_mem_t *mctx, isc_socketmgr_t **managerp, + unsigned int maxsocks); +ISC_SOCKETFUNC_SCOPE void +isc__socketmgr_destroy(isc_socketmgr_t **managerp); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_recvv(isc_socket_t *sock, isc_bufferlist_t *buflist, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_recv(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_recv2(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_socketevent_t *event, unsigned int flags); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_send(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendto(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendv(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendtov(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendto2(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + isc_socketevent_t *event, unsigned int flags); +ISC_SOCKETFUNC_SCOPE void +isc__socket_cleanunix(isc_sockaddr_t *sockaddr, isc_boolean_t active); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_permunix(isc_sockaddr_t *sockaddr, isc_uint32_t perm, + isc_uint32_t owner, isc_uint32_t group); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_bind(isc_socket_t *sock, isc_sockaddr_t *sockaddr, + unsigned int options); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_filter(isc_socket_t *sock, const char *filter); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_listen(isc_socket_t *sock, unsigned int backlog); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_accept(isc_socket_t *sock, + isc_task_t *task, isc_taskaction_t action, const void *arg); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_connect(isc_socket_t *sock, isc_sockaddr_t *addr, + isc_task_t *task, isc_taskaction_t action, + const void *arg); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_getpeername(isc_socket_t *sock, isc_sockaddr_t *addressp); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_getsockname(isc_socket_t *sock, isc_sockaddr_t *addressp); +ISC_SOCKETFUNC_SCOPE void +isc__socket_cancel(isc_socket_t *sock, isc_task_t *task, unsigned int how); +ISC_SOCKETFUNC_SCOPE isc_sockettype_t +isc__socket_gettype(isc_socket_t *sock); +ISC_SOCKETFUNC_SCOPE isc_boolean_t +isc__socket_isbound(isc_socket_t *sock); +ISC_SOCKETFUNC_SCOPE void +isc__socket_ipv6only(isc_socket_t *sock, isc_boolean_t yes); +#if defined(HAVE_LIBXML2) && defined(BIND9) +ISC_SOCKETFUNC_SCOPE void +isc__socketmgr_renderxml(isc_socketmgr_t *mgr0, xmlTextWriterPtr writer); +#endif + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_fdwatchcreate(isc_socketmgr_t *manager, int fd, int flags, + isc_sockfdwatch_t callback, void *cbarg, + isc_task_t *task, isc_socket_t **socketp); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_fdwatchpoke(isc_socket_t *sock, int flags); +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_dup(isc_socket_t *sock, isc_socket_t **socketp); +ISC_SOCKETFUNC_SCOPE int +isc__socket_getfd(isc_socket_t *sock); + +static struct { + isc_socketmethods_t methods; + + /*% + * The following are defined just for avoiding unused static functions. + */ +#ifndef BIND9 + void *recvv, *send, *sendv, *sendto2, *cleanunix, *permunix, *filter, + *listen, *accept, *getpeername, *isbound; +#endif +} socketmethods = { + { + isc__socket_attach, + isc__socket_detach, + isc__socket_bind, + isc__socket_sendto, + isc__socket_connect, + isc__socket_recv, + isc__socket_cancel, + isc__socket_getsockname, + isc__socket_gettype, + isc__socket_ipv6only, + isc__socket_fdwatchpoke, + isc__socket_dup, + isc__socket_getfd + } +#ifndef BIND9 + , + (void *)isc__socket_recvv, (void *)isc__socket_send, + (void *)isc__socket_sendv, (void *)isc__socket_sendto2, + (void *)isc__socket_cleanunix, (void *)isc__socket_permunix, + (void *)isc__socket_filter, (void *)isc__socket_listen, + (void *)isc__socket_accept, (void *)isc__socket_getpeername, + (void *)isc__socket_isbound +#endif +}; + +static isc_socketmgrmethods_t socketmgrmethods = { + isc__socketmgr_destroy, + isc__socket_create, + isc__socket_fdwatchcreate +}; + +#define SELECT_POKE_SHUTDOWN (-1) +#define SELECT_POKE_NOTHING (-2) +#define SELECT_POKE_READ (-3) +#define SELECT_POKE_ACCEPT (-3) /*%< Same as _READ */ +#define SELECT_POKE_WRITE (-4) +#define SELECT_POKE_CONNECT (-4) /*%< Same as _WRITE */ +#define SELECT_POKE_CLOSE (-5) + +#define SOCK_DEAD(s) ((s)->references == 0) + +/*% + * Shortcut index arrays to get access to statistics counters. + */ +enum { + STATID_OPEN = 0, + STATID_OPENFAIL = 1, + STATID_CLOSE = 2, + STATID_BINDFAIL = 3, + STATID_CONNECTFAIL = 4, + STATID_CONNECT = 5, + STATID_ACCEPTFAIL = 6, + STATID_ACCEPT = 7, + STATID_SENDFAIL = 8, + STATID_RECVFAIL = 9 +}; +static const isc_statscounter_t upd4statsindex[] = { + isc_sockstatscounter_udp4open, + isc_sockstatscounter_udp4openfail, + isc_sockstatscounter_udp4close, + isc_sockstatscounter_udp4bindfail, + isc_sockstatscounter_udp4connectfail, + isc_sockstatscounter_udp4connect, + -1, + -1, + isc_sockstatscounter_udp4sendfail, + isc_sockstatscounter_udp4recvfail +}; +static const isc_statscounter_t upd6statsindex[] = { + isc_sockstatscounter_udp6open, + isc_sockstatscounter_udp6openfail, + isc_sockstatscounter_udp6close, + isc_sockstatscounter_udp6bindfail, + isc_sockstatscounter_udp6connectfail, + isc_sockstatscounter_udp6connect, + -1, + -1, + isc_sockstatscounter_udp6sendfail, + isc_sockstatscounter_udp6recvfail +}; +static const isc_statscounter_t tcp4statsindex[] = { + isc_sockstatscounter_tcp4open, + isc_sockstatscounter_tcp4openfail, + isc_sockstatscounter_tcp4close, + isc_sockstatscounter_tcp4bindfail, + isc_sockstatscounter_tcp4connectfail, + isc_sockstatscounter_tcp4connect, + isc_sockstatscounter_tcp4acceptfail, + isc_sockstatscounter_tcp4accept, + isc_sockstatscounter_tcp4sendfail, + isc_sockstatscounter_tcp4recvfail +}; +static const isc_statscounter_t tcp6statsindex[] = { + isc_sockstatscounter_tcp6open, + isc_sockstatscounter_tcp6openfail, + isc_sockstatscounter_tcp6close, + isc_sockstatscounter_tcp6bindfail, + isc_sockstatscounter_tcp6connectfail, + isc_sockstatscounter_tcp6connect, + isc_sockstatscounter_tcp6acceptfail, + isc_sockstatscounter_tcp6accept, + isc_sockstatscounter_tcp6sendfail, + isc_sockstatscounter_tcp6recvfail +}; +static const isc_statscounter_t unixstatsindex[] = { + isc_sockstatscounter_unixopen, + isc_sockstatscounter_unixopenfail, + isc_sockstatscounter_unixclose, + isc_sockstatscounter_unixbindfail, + isc_sockstatscounter_unixconnectfail, + isc_sockstatscounter_unixconnect, + isc_sockstatscounter_unixacceptfail, + isc_sockstatscounter_unixaccept, + isc_sockstatscounter_unixsendfail, + isc_sockstatscounter_unixrecvfail +}; +static const isc_statscounter_t fdwatchstatsindex[] = { + -1, + -1, + isc_sockstatscounter_fdwatchclose, + isc_sockstatscounter_fdwatchbindfail, + isc_sockstatscounter_fdwatchconnectfail, + isc_sockstatscounter_fdwatchconnect, + -1, + -1, + isc_sockstatscounter_fdwatchsendfail, + isc_sockstatscounter_fdwatchrecvfail +}; + +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) || \ + defined(USE_WATCHER_THREAD) +static void +manager_log(isc__socketmgr_t *sockmgr, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + const char *fmt, ...) ISC_FORMAT_PRINTF(5, 6); +static void +manager_log(isc__socketmgr_t *sockmgr, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + const char *fmt, ...) +{ + char msgbuf[2048]; + va_list ap; + + if (! isc_log_wouldlog(isc_lctx, level)) + return; + + va_start(ap, fmt); + vsnprintf(msgbuf, sizeof(msgbuf), fmt, ap); + va_end(ap); + + isc_log_write(isc_lctx, category, module, level, + "sockmgr %p: %s", sockmgr, msgbuf); +} +#endif + +static void +socket_log(isc__socket_t *sock, isc_sockaddr_t *address, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *fmt, ...) ISC_FORMAT_PRINTF(9, 10); +static void +socket_log(isc__socket_t *sock, isc_sockaddr_t *address, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *fmt, ...) +{ + char msgbuf[2048]; + char peerbuf[ISC_SOCKADDR_FORMATSIZE]; + va_list ap; + + if (! isc_log_wouldlog(isc_lctx, level)) + return; + + va_start(ap, fmt); + vsnprintf(msgbuf, sizeof(msgbuf), fmt, ap); + va_end(ap); + + if (address == NULL) { + isc_log_iwrite(isc_lctx, category, module, level, + msgcat, msgset, message, + "socket %p: %s", sock, msgbuf); + } else { + isc_sockaddr_format(address, peerbuf, sizeof(peerbuf)); + isc_log_iwrite(isc_lctx, category, module, level, + msgcat, msgset, message, + "socket %p %s: %s", sock, peerbuf, msgbuf); + } +} + +#if defined(_AIX) && defined(ISC_NET_BSD44MSGHDR) && \ + defined(USE_CMSG) && defined(IPV6_RECVPKTINFO) +/* + * AIX has a kernel bug where IPV6_RECVPKTINFO gets cleared by + * setting IPV6_V6ONLY. + */ +static void +FIX_IPV6_RECVPKTINFO(isc__socket_t *sock) +{ + char strbuf[ISC_STRERRORSIZE]; + int on = 1; + + if (sock->pf != AF_INET6 || sock->type != isc_sockettype_udp) + return; + + if (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_RECVPKTINFO, + (void *)&on, sizeof(on)) < 0) { + + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_RECVPKTINFO) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +} +#else +#define FIX_IPV6_RECVPKTINFO(sock) (void)0 +#endif + +/*% + * Increment socket-related statistics counters. + */ +static inline void +inc_stats(isc_stats_t *stats, isc_statscounter_t counterid) { + REQUIRE(counterid != -1); + + if (stats != NULL) + isc_stats_increment(stats, counterid); +} + +static inline isc_result_t +watch_fd(isc__socketmgr_t *manager, int fd, int msg) { + isc_result_t result = ISC_R_SUCCESS; + +#ifdef USE_KQUEUE + struct kevent evchange; + + memset(&evchange, 0, sizeof(evchange)); + if (msg == SELECT_POKE_READ) + evchange.filter = EVFILT_READ; + else + evchange.filter = EVFILT_WRITE; + evchange.flags = EV_ADD; + evchange.ident = fd; + if (kevent(manager->kqueue_fd, &evchange, 1, NULL, 0, NULL) != 0) + result = isc__errno2result(errno); + + return (result); +#elif defined(USE_EPOLL) + struct epoll_event event; + + if (msg == SELECT_POKE_READ) + event.events = EPOLLIN; + else + event.events = EPOLLOUT; + memset(&event.data, 0, sizeof(event.data)); + event.data.fd = fd; + if (epoll_ctl(manager->epoll_fd, EPOLL_CTL_ADD, fd, &event) == -1 && + errno != EEXIST) { + result = isc__errno2result(errno); + } + + return (result); +#elif defined(USE_DEVPOLL) + struct pollfd pfd; + int lockid = FDLOCK_ID(fd); + + memset(&pfd, 0, sizeof(pfd)); + if (msg == SELECT_POKE_READ) + pfd.events = POLLIN; + else + pfd.events = POLLOUT; + pfd.fd = fd; + pfd.revents = 0; + LOCK(&manager->fdlock[lockid]); + if (write(manager->devpoll_fd, &pfd, sizeof(pfd)) == -1) + result = isc__errno2result(errno); + else { + if (msg == SELECT_POKE_READ) + manager->fdpollinfo[fd].want_read = 1; + else + manager->fdpollinfo[fd].want_write = 1; + } + UNLOCK(&manager->fdlock[lockid]); + + return (result); +#elif defined(USE_SELECT) + LOCK(&manager->lock); + if (msg == SELECT_POKE_READ) + FD_SET(fd, manager->read_fds); + if (msg == SELECT_POKE_WRITE) + FD_SET(fd, manager->write_fds); + UNLOCK(&manager->lock); + + return (result); +#endif +} + +static inline isc_result_t +unwatch_fd(isc__socketmgr_t *manager, int fd, int msg) { + isc_result_t result = ISC_R_SUCCESS; + +#ifdef USE_KQUEUE + struct kevent evchange; + + memset(&evchange, 0, sizeof(evchange)); + if (msg == SELECT_POKE_READ) + evchange.filter = EVFILT_READ; + else + evchange.filter = EVFILT_WRITE; + evchange.flags = EV_DELETE; + evchange.ident = fd; + if (kevent(manager->kqueue_fd, &evchange, 1, NULL, 0, NULL) != 0) + result = isc__errno2result(errno); + + return (result); +#elif defined(USE_EPOLL) + struct epoll_event event; + + if (msg == SELECT_POKE_READ) + event.events = EPOLLIN; + else + event.events = EPOLLOUT; + memset(&event.data, 0, sizeof(event.data)); + event.data.fd = fd; + if (epoll_ctl(manager->epoll_fd, EPOLL_CTL_DEL, fd, &event) == -1 && + errno != ENOENT) { + char strbuf[ISC_STRERRORSIZE]; + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "epoll_ctl(DEL), %d: %s", fd, strbuf); + result = ISC_R_UNEXPECTED; + } + return (result); +#elif defined(USE_DEVPOLL) + struct pollfd pfds[2]; + size_t writelen = sizeof(pfds[0]); + int lockid = FDLOCK_ID(fd); + + memset(pfds, 0, sizeof(pfds)); + pfds[0].events = POLLREMOVE; + pfds[0].fd = fd; + + /* + * Canceling read or write polling via /dev/poll is tricky. Since it + * only provides a way of canceling per FD, we may need to re-poll the + * socket for the other operation. + */ + LOCK(&manager->fdlock[lockid]); + if (msg == SELECT_POKE_READ && + manager->fdpollinfo[fd].want_write == 1) { + pfds[1].events = POLLOUT; + pfds[1].fd = fd; + writelen += sizeof(pfds[1]); + } + if (msg == SELECT_POKE_WRITE && + manager->fdpollinfo[fd].want_read == 1) { + pfds[1].events = POLLIN; + pfds[1].fd = fd; + writelen += sizeof(pfds[1]); + } + + if (write(manager->devpoll_fd, pfds, writelen) == -1) + result = isc__errno2result(errno); + else { + if (msg == SELECT_POKE_READ) + manager->fdpollinfo[fd].want_read = 0; + else + manager->fdpollinfo[fd].want_write = 0; + } + UNLOCK(&manager->fdlock[lockid]); + + return (result); +#elif defined(USE_SELECT) + LOCK(&manager->lock); + if (msg == SELECT_POKE_READ) + FD_CLR(fd, manager->read_fds); + else if (msg == SELECT_POKE_WRITE) + FD_CLR(fd, manager->write_fds); + UNLOCK(&manager->lock); + + return (result); +#endif +} + +static void +wakeup_socket(isc__socketmgr_t *manager, int fd, int msg) { + isc_result_t result; + int lockid = FDLOCK_ID(fd); + + /* + * This is a wakeup on a socket. If the socket is not in the + * process of being closed, start watching it for either reads + * or writes. + */ + + INSIST(fd >= 0 && fd < (int)manager->maxsocks); + + if (msg == SELECT_POKE_CLOSE) { + /* No one should be updating fdstate, so no need to lock it */ + INSIST(manager->fdstate[fd] == CLOSE_PENDING); + manager->fdstate[fd] = CLOSED; + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + (void)close(fd); + return; + } + + LOCK(&manager->fdlock[lockid]); + if (manager->fdstate[fd] == CLOSE_PENDING) { + UNLOCK(&manager->fdlock[lockid]); + + /* + * We accept (and ignore) any error from unwatch_fd() as we are + * closing the socket, hoping it doesn't leave dangling state in + * the kernel. + * Note that unwatch_fd() must be called after releasing the + * fdlock; otherwise it could cause deadlock due to a lock order + * reversal. + */ + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + return; + } + if (manager->fdstate[fd] != MANAGED) { + UNLOCK(&manager->fdlock[lockid]); + return; + } + UNLOCK(&manager->fdlock[lockid]); + + /* + * Set requested bit. + */ + result = watch_fd(manager, fd, msg); + if (result != ISC_R_SUCCESS) { + /* + * XXXJT: what should we do? Ignoring the failure of watching + * a socket will make the application dysfunctional, but there + * seems to be no reasonable recovery process. + */ + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "failed to start watching FD (%d): %s", + fd, isc_result_totext(result)); + } +} + +#ifdef USE_WATCHER_THREAD +/* + * Poke the select loop when there is something for us to do. + * The write is required (by POSIX) to complete. That is, we + * will not get partial writes. + */ +static void +select_poke(isc__socketmgr_t *mgr, int fd, int msg) { + int cc; + int buf[2]; + char strbuf[ISC_STRERRORSIZE]; + + buf[0] = fd; + buf[1] = msg; + + do { + cc = write(mgr->pipe_fds[1], buf, sizeof(buf)); +#ifdef ENOSR + /* + * Treat ENOSR as EAGAIN but loop slowly as it is + * unlikely to clear fast. + */ + if (cc < 0 && errno == ENOSR) { + sleep(1); + errno = EAGAIN; + } +#endif + } while (cc < 0 && SOFT_ERROR(errno)); + + if (cc < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_WRITEFAILED, + "write() failed " + "during watcher poke: %s"), + strbuf); + } + + INSIST(cc == sizeof(buf)); +} + +/* + * Read a message on the internal fd. + */ +static void +select_readmsg(isc__socketmgr_t *mgr, int *fd, int *msg) { + int buf[2]; + int cc; + char strbuf[ISC_STRERRORSIZE]; + + cc = read(mgr->pipe_fds[0], buf, sizeof(buf)); + if (cc < 0) { + *msg = SELECT_POKE_NOTHING; + *fd = -1; /* Silence compiler. */ + if (SOFT_ERROR(errno)) + return; + + isc__strerror(errno, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_READFAILED, + "read() failed " + "during watcher poke: %s"), + strbuf); + + return; + } + INSIST(cc == sizeof(buf)); + + *fd = buf[0]; + *msg = buf[1]; +} +#else /* USE_WATCHER_THREAD */ +/* + * Update the state of the socketmgr when something changes. + */ +static void +select_poke(isc__socketmgr_t *manager, int fd, int msg) { + if (msg == SELECT_POKE_SHUTDOWN) + return; + else if (fd >= 0) + wakeup_socket(manager, fd, msg); + return; +} +#endif /* USE_WATCHER_THREAD */ + +/* + * Make a fd non-blocking. + */ +static isc_result_t +make_nonblock(int fd) { + int ret; + int flags; + char strbuf[ISC_STRERRORSIZE]; +#ifdef USE_FIONBIO_IOCTL + int on = 1; + + ret = ioctl(fd, FIONBIO, (char *)&on); +#else + flags = fcntl(fd, F_GETFL, 0); + flags |= PORT_NONBLOCK; + ret = fcntl(fd, F_SETFL, flags); +#endif + + if (ret == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, +#ifdef USE_FIONBIO_IOCTL + "ioctl(%d, FIONBIO, &on): %s", fd, +#else + "fcntl(%d, F_SETFL, %d): %s", fd, flags, +#endif + strbuf); + + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +#ifdef USE_CMSG +/* + * Not all OSes support advanced CMSG macros: CMSG_LEN and CMSG_SPACE. + * In order to ensure as much portability as possible, we provide wrapper + * functions of these macros. + * Note that cmsg_space() could run slow on OSes that do not have + * CMSG_SPACE. + */ +static inline ISC_SOCKADDR_LEN_T +cmsg_len(ISC_SOCKADDR_LEN_T len) { +#ifdef CMSG_LEN + return (CMSG_LEN(len)); +#else + ISC_SOCKADDR_LEN_T hdrlen; + + /* + * Cast NULL so that any pointer arithmetic performed by CMSG_DATA + * is correct. + */ + hdrlen = (ISC_SOCKADDR_LEN_T)CMSG_DATA(((struct cmsghdr *)NULL)); + return (hdrlen + len); +#endif +} + +static inline ISC_SOCKADDR_LEN_T +cmsg_space(ISC_SOCKADDR_LEN_T len) { +#ifdef CMSG_SPACE + return (CMSG_SPACE(len)); +#else + struct msghdr msg; + struct cmsghdr *cmsgp; + /* + * XXX: The buffer length is an ad-hoc value, but should be enough + * in a practical sense. + */ + char dummybuf[sizeof(struct cmsghdr) + 1024]; + + memset(&msg, 0, sizeof(msg)); + msg.msg_control = dummybuf; + msg.msg_controllen = sizeof(dummybuf); + + cmsgp = (struct cmsghdr *)dummybuf; + cmsgp->cmsg_len = cmsg_len(len); + + cmsgp = CMSG_NXTHDR(&msg, cmsgp); + if (cmsgp != NULL) + return ((char *)cmsgp - (char *)msg.msg_control); + else + return (0); +#endif +} +#endif /* USE_CMSG */ + +/* + * Process control messages received on a socket. + */ +static void +process_cmsg(isc__socket_t *sock, struct msghdr *msg, isc_socketevent_t *dev) { +#ifdef USE_CMSG + struct cmsghdr *cmsgp; +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + struct in6_pktinfo *pktinfop; +#endif +#ifdef SO_TIMESTAMP + struct timeval *timevalp; +#endif +#endif + + /* + * sock is used only when ISC_NET_BSD44MSGHDR and USE_CMSG are defined. + * msg and dev are used only when ISC_NET_BSD44MSGHDR is defined. + * They are all here, outside of the CPP tests, because it is + * more consistent with the usual ISC coding style. + */ + UNUSED(sock); + UNUSED(msg); + UNUSED(dev); + +#ifdef ISC_NET_BSD44MSGHDR + +#ifdef MSG_TRUNC + if ((msg->msg_flags & MSG_TRUNC) == MSG_TRUNC) + dev->attributes |= ISC_SOCKEVENTATTR_TRUNC; +#endif + +#ifdef MSG_CTRUNC + if ((msg->msg_flags & MSG_CTRUNC) == MSG_CTRUNC) + dev->attributes |= ISC_SOCKEVENTATTR_CTRUNC; +#endif + +#ifndef USE_CMSG + return; +#else + if (msg->msg_controllen == 0U || msg->msg_control == NULL) + return; + +#ifdef SO_TIMESTAMP + timevalp = NULL; +#endif +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + pktinfop = NULL; +#endif + + cmsgp = CMSG_FIRSTHDR(msg); + while (cmsgp != NULL) { + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_PROCESSCMSG, + "processing cmsg %p", cmsgp); + +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO + if (cmsgp->cmsg_level == IPPROTO_IPV6 + && cmsgp->cmsg_type == IPV6_PKTINFO) { + + pktinfop = (struct in6_pktinfo *)CMSG_DATA(cmsgp); + memcpy(&dev->pktinfo, pktinfop, + sizeof(struct in6_pktinfo)); + dev->attributes |= ISC_SOCKEVENTATTR_PKTINFO; + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_IFRECEIVED, + "interface received on ifindex %u", + dev->pktinfo.ipi6_ifindex); + if (IN6_IS_ADDR_MULTICAST(&pktinfop->ipi6_addr)) + dev->attributes |= ISC_SOCKEVENTATTR_MULTICAST; + goto next; + } +#endif + +#ifdef SO_TIMESTAMP + if (cmsgp->cmsg_level == SOL_SOCKET + && cmsgp->cmsg_type == SCM_TIMESTAMP) { + timevalp = (struct timeval *)CMSG_DATA(cmsgp); + dev->timestamp.seconds = timevalp->tv_sec; + dev->timestamp.nanoseconds = timevalp->tv_usec * 1000; + dev->attributes |= ISC_SOCKEVENTATTR_TIMESTAMP; + goto next; + } +#endif + + next: + cmsgp = CMSG_NXTHDR(msg, cmsgp); + } +#endif /* USE_CMSG */ + +#endif /* ISC_NET_BSD44MSGHDR */ +} + +/* + * Construct an iov array and attach it to the msghdr passed in. This is + * the SEND constructor, which will use the used region of the buffer + * (if using a buffer list) or will use the internal region (if a single + * buffer I/O is requested). + * + * Nothing can be NULL, and the done event must list at least one buffer + * on the buffer linked list for this function to be meaningful. + * + * If write_countp != NULL, *write_countp will hold the number of bytes + * this transaction can send. + */ +static void +build_msghdr_send(isc__socket_t *sock, isc_socketevent_t *dev, + struct msghdr *msg, struct iovec *iov, size_t *write_countp) +{ + unsigned int iovcount; + isc_buffer_t *buffer; + isc_region_t used; + size_t write_count; + size_t skip_count; + + memset(msg, 0, sizeof(*msg)); + + if (!sock->connected) { + msg->msg_name = (void *)&dev->address.type.sa; + msg->msg_namelen = dev->address.length; + } else { + msg->msg_name = NULL; + msg->msg_namelen = 0; + } + + buffer = ISC_LIST_HEAD(dev->bufferlist); + write_count = 0; + iovcount = 0; + + /* + * Single buffer I/O? Skip what we've done so far in this region. + */ + if (buffer == NULL) { + write_count = dev->region.length - dev->n; + iov[0].iov_base = (void *)(dev->region.base + dev->n); + iov[0].iov_len = write_count; + iovcount = 1; + + goto config; + } + + /* + * Multibuffer I/O. + * Skip the data in the buffer list that we have already written. + */ + skip_count = dev->n; + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (skip_count < isc_buffer_usedlength(buffer)) + break; + skip_count -= isc_buffer_usedlength(buffer); + buffer = ISC_LIST_NEXT(buffer, link); + } + + while (buffer != NULL) { + INSIST(iovcount < MAXSCATTERGATHER_SEND); + + isc_buffer_usedregion(buffer, &used); + + if (used.length > 0) { + iov[iovcount].iov_base = (void *)(used.base + + skip_count); + iov[iovcount].iov_len = used.length - skip_count; + write_count += (used.length - skip_count); + skip_count = 0; + iovcount++; + } + buffer = ISC_LIST_NEXT(buffer, link); + } + + INSIST(skip_count == 0U); + + config: + msg->msg_iov = iov; + msg->msg_iovlen = iovcount; + +#ifdef ISC_NET_BSD44MSGHDR + msg->msg_control = NULL; + msg->msg_controllen = 0; + msg->msg_flags = 0; +#if defined(USE_CMSG) && defined(ISC_PLATFORM_HAVEIN6PKTINFO) + if ((sock->type == isc_sockettype_udp) + && ((dev->attributes & ISC_SOCKEVENTATTR_PKTINFO) != 0)) { +#if defined(IPV6_USE_MIN_MTU) + int use_min_mtu = 1; /* -1, 0, 1 */ +#endif + struct cmsghdr *cmsgp; + struct in6_pktinfo *pktinfop; + + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_SENDTODATA, + "sendto pktinfo data, ifindex %u", + dev->pktinfo.ipi6_ifindex); + + msg->msg_controllen = cmsg_space(sizeof(struct in6_pktinfo)); + INSIST(msg->msg_controllen <= sock->sendcmsgbuflen); + msg->msg_control = (void *)sock->sendcmsgbuf; + + cmsgp = (struct cmsghdr *)sock->sendcmsgbuf; + cmsgp->cmsg_level = IPPROTO_IPV6; + cmsgp->cmsg_type = IPV6_PKTINFO; + cmsgp->cmsg_len = cmsg_len(sizeof(struct in6_pktinfo)); + pktinfop = (struct in6_pktinfo *)CMSG_DATA(cmsgp); + memcpy(pktinfop, &dev->pktinfo, sizeof(struct in6_pktinfo)); +#if defined(IPV6_USE_MIN_MTU) + /* + * Set IPV6_USE_MIN_MTU as a per packet option as FreeBSD + * ignores setsockopt(IPV6_USE_MIN_MTU) when IPV6_PKTINFO + * is used. + */ + cmsgp = (struct cmsghdr *)(sock->sendcmsgbuf + + msg->msg_controllen); + msg->msg_controllen += cmsg_space(sizeof(use_min_mtu)); + INSIST(msg->msg_controllen <= sock->sendcmsgbuflen); + + cmsgp->cmsg_level = IPPROTO_IPV6; + cmsgp->cmsg_type = IPV6_USE_MIN_MTU; + cmsgp->cmsg_len = cmsg_len(sizeof(use_min_mtu)); + memcpy(CMSG_DATA(cmsgp), &use_min_mtu, sizeof(use_min_mtu)); +#endif + } +#endif /* USE_CMSG && ISC_PLATFORM_HAVEIPV6 */ +#else /* ISC_NET_BSD44MSGHDR */ + msg->msg_accrights = NULL; + msg->msg_accrightslen = 0; +#endif /* ISC_NET_BSD44MSGHDR */ + + if (write_countp != NULL) + *write_countp = write_count; +} + +/* + * Construct an iov array and attach it to the msghdr passed in. This is + * the RECV constructor, which will use the available region of the buffer + * (if using a buffer list) or will use the internal region (if a single + * buffer I/O is requested). + * + * Nothing can be NULL, and the done event must list at least one buffer + * on the buffer linked list for this function to be meaningful. + * + * If read_countp != NULL, *read_countp will hold the number of bytes + * this transaction can receive. + */ +static void +build_msghdr_recv(isc__socket_t *sock, isc_socketevent_t *dev, + struct msghdr *msg, struct iovec *iov, size_t *read_countp) +{ + unsigned int iovcount; + isc_buffer_t *buffer; + isc_region_t available; + size_t read_count; + + memset(msg, 0, sizeof(struct msghdr)); + + if (sock->type == isc_sockettype_udp) { + memset(&dev->address, 0, sizeof(dev->address)); +#ifdef BROKEN_RECVMSG + if (sock->pf == AF_INET) { + msg->msg_name = (void *)&dev->address.type.sin; + msg->msg_namelen = sizeof(dev->address.type.sin6); + } else if (sock->pf == AF_INET6) { + msg->msg_name = (void *)&dev->address.type.sin6; + msg->msg_namelen = sizeof(dev->address.type.sin6); +#ifdef ISC_PLATFORM_HAVESYSUNH + } else if (sock->pf == AF_UNIX) { + msg->msg_name = (void *)&dev->address.type.sunix; + msg->msg_namelen = sizeof(dev->address.type.sunix); +#endif + } else { + msg->msg_name = (void *)&dev->address.type.sa; + msg->msg_namelen = sizeof(dev->address.type); + } +#else + msg->msg_name = (void *)&dev->address.type.sa; + msg->msg_namelen = sizeof(dev->address.type); +#endif +#ifdef ISC_NET_RECVOVERFLOW + /* If needed, steal one iovec for overflow detection. */ + maxiov--; +#endif + } else { /* TCP */ + msg->msg_name = NULL; + msg->msg_namelen = 0; + dev->address = sock->peer_address; + } + + buffer = ISC_LIST_HEAD(dev->bufferlist); + read_count = 0; + + /* + * Single buffer I/O? Skip what we've done so far in this region. + */ + if (buffer == NULL) { + read_count = dev->region.length - dev->n; + iov[0].iov_base = (void *)(dev->region.base + dev->n); + iov[0].iov_len = read_count; + iovcount = 1; + + goto config; + } + + /* + * Multibuffer I/O. + * Skip empty buffers. + */ + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (isc_buffer_availablelength(buffer) != 0) + break; + buffer = ISC_LIST_NEXT(buffer, link); + } + + iovcount = 0; + while (buffer != NULL) { + INSIST(iovcount < MAXSCATTERGATHER_RECV); + + isc_buffer_availableregion(buffer, &available); + + if (available.length > 0) { + iov[iovcount].iov_base = (void *)(available.base); + iov[iovcount].iov_len = available.length; + read_count += available.length; + iovcount++; + } + buffer = ISC_LIST_NEXT(buffer, link); + } + + config: + + /* + * If needed, set up to receive that one extra byte. Note that + * we know there is at least one iov left, since we stole it + * at the top of this function. + */ +#ifdef ISC_NET_RECVOVERFLOW + if (sock->type == isc_sockettype_udp) { + iov[iovcount].iov_base = (void *)(&sock->overflow); + iov[iovcount].iov_len = 1; + iovcount++; + } +#endif + + msg->msg_iov = iov; + msg->msg_iovlen = iovcount; + +#ifdef ISC_NET_BSD44MSGHDR + msg->msg_control = NULL; + msg->msg_controllen = 0; + msg->msg_flags = 0; +#if defined(USE_CMSG) + if (sock->type == isc_sockettype_udp) { + msg->msg_control = sock->recvcmsgbuf; + msg->msg_controllen = sock->recvcmsgbuflen; + } +#endif /* USE_CMSG */ +#else /* ISC_NET_BSD44MSGHDR */ + msg->msg_accrights = NULL; + msg->msg_accrightslen = 0; +#endif /* ISC_NET_BSD44MSGHDR */ + + if (read_countp != NULL) + *read_countp = read_count; +} + +static void +set_dev_address(isc_sockaddr_t *address, isc__socket_t *sock, + isc_socketevent_t *dev) +{ + if (sock->type == isc_sockettype_udp) { + if (address != NULL) + dev->address = *address; + else + dev->address = sock->peer_address; + } else if (sock->type == isc_sockettype_tcp) { + INSIST(address == NULL); + dev->address = sock->peer_address; + } +} + +static void +destroy_socketevent(isc_event_t *event) { + isc_socketevent_t *ev = (isc_socketevent_t *)event; + + INSIST(ISC_LIST_EMPTY(ev->bufferlist)); + + (ev->destroy)(event); +} + +static isc_socketevent_t * +allocate_socketevent(isc__socket_t *sock, isc_eventtype_t eventtype, + isc_taskaction_t action, const void *arg) +{ + isc_socketevent_t *ev; + + ev = (isc_socketevent_t *)isc_event_allocate(sock->manager->mctx, + sock, eventtype, + action, arg, + sizeof(*ev)); + + if (ev == NULL) + return (NULL); + + ev->result = ISC_R_UNSET; + ISC_LINK_INIT(ev, ev_link); + ISC_LIST_INIT(ev->bufferlist); + ev->region.base = NULL; + ev->n = 0; + ev->offset = 0; + ev->attributes = 0; + ev->destroy = ev->ev_destroy; + ev->ev_destroy = destroy_socketevent; + + return (ev); +} + +#if defined(ISC_SOCKET_DEBUG) +static void +dump_msg(struct msghdr *msg) { + unsigned int i; + + printf("MSGHDR %p\n", msg); + printf("\tname %p, namelen %ld\n", msg->msg_name, + (long) msg->msg_namelen); + printf("\tiov %p, iovlen %ld\n", msg->msg_iov, + (long) msg->msg_iovlen); + for (i = 0; i < (unsigned int)msg->msg_iovlen; i++) + printf("\t\t%d\tbase %p, len %ld\n", i, + msg->msg_iov[i].iov_base, + (long) msg->msg_iov[i].iov_len); +#ifdef ISC_NET_BSD44MSGHDR + printf("\tcontrol %p, controllen %ld\n", msg->msg_control, + (long) msg->msg_controllen); +#endif +} +#endif + +#define DOIO_SUCCESS 0 /* i/o ok, event sent */ +#define DOIO_SOFT 1 /* i/o ok, soft error, no event sent */ +#define DOIO_HARD 2 /* i/o error, event sent */ +#define DOIO_EOF 3 /* EOF, no event sent */ + +static int +doio_recv(isc__socket_t *sock, isc_socketevent_t *dev) { + int cc; + struct iovec iov[MAXSCATTERGATHER_RECV]; + size_t read_count; + size_t actual_count; + struct msghdr msghdr; + isc_buffer_t *buffer; + int recv_errno; + char strbuf[ISC_STRERRORSIZE]; + + build_msghdr_recv(sock, dev, &msghdr, iov, &read_count); + +#if defined(ISC_SOCKET_DEBUG) + dump_msg(&msghdr); +#endif + + cc = recvmsg(sock->fd, &msghdr, 0); + recv_errno = errno; + +#if defined(ISC_SOCKET_DEBUG) + dump_msg(&msghdr); +#endif + + if (cc < 0) { + if (SOFT_ERROR(recv_errno)) + return (DOIO_SOFT); + + if (isc_log_wouldlog(isc_lctx, IOEVENT_LEVEL)) { + isc__strerror(recv_errno, strbuf, sizeof(strbuf)); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_DOIORECV, + "doio_recv: recvmsg(%d) %d bytes, err %d/%s", + sock->fd, cc, recv_errno, strbuf); + } + +#define SOFT_OR_HARD(_system, _isc) \ + if (recv_errno == _system) { \ + if (sock->connected) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_RECVFAIL]); \ + return (DOIO_HARD); \ + } \ + return (DOIO_SOFT); \ + } +#define ALWAYS_HARD(_system, _isc) \ + if (recv_errno == _system) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_RECVFAIL]); \ + return (DOIO_HARD); \ + } + + SOFT_OR_HARD(ECONNREFUSED, ISC_R_CONNREFUSED); + SOFT_OR_HARD(ENETUNREACH, ISC_R_NETUNREACH); + SOFT_OR_HARD(EHOSTUNREACH, ISC_R_HOSTUNREACH); + SOFT_OR_HARD(EHOSTDOWN, ISC_R_HOSTDOWN); + /* HPUX 11.11 can return EADDRNOTAVAIL. */ + SOFT_OR_HARD(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ALWAYS_HARD(ENOBUFS, ISC_R_NORESOURCES); + /* + * HPUX returns EPROTO and EINVAL on receiving some ICMP/ICMPv6 + * errors. + */ +#ifdef EPROTO + SOFT_OR_HARD(EPROTO, ISC_R_HOSTUNREACH); +#endif + SOFT_OR_HARD(EINVAL, ISC_R_HOSTUNREACH); + +#undef SOFT_OR_HARD +#undef ALWAYS_HARD + + dev->result = isc__errno2result(recv_errno); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_RECVFAIL]); + return (DOIO_HARD); + } + + /* + * On TCP and UNIX sockets, zero length reads indicate EOF, + * while on UDP sockets, zero length reads are perfectly valid, + * although strange. + */ + switch (sock->type) { + case isc_sockettype_tcp: + case isc_sockettype_unix: + if (cc == 0) + return (DOIO_EOF); + break; + case isc_sockettype_udp: + break; + case isc_sockettype_fdwatch: + default: + INSIST(0); + } + + if (sock->type == isc_sockettype_udp) { + dev->address.length = msghdr.msg_namelen; + if (isc_sockaddr_getport(&dev->address) == 0) { + if (isc_log_wouldlog(isc_lctx, IOEVENT_LEVEL)) { + socket_log(sock, &dev->address, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_ZEROPORT, + "dropping source port zero packet"); + } + return (DOIO_SOFT); + } + /* + * Simulate a firewall blocking UDP responses bigger than + * 512 bytes. + */ + if (sock->manager->maxudp != 0 && cc > sock->manager->maxudp) + return (DOIO_SOFT); + } + + socket_log(sock, &dev->address, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_PKTRECV, + "packet received correctly"); + + /* + * Overflow bit detection. If we received MORE bytes than we should, + * this indicates an overflow situation. Set the flag in the + * dev entry and adjust how much we read by one. + */ +#ifdef ISC_NET_RECVOVERFLOW + if ((sock->type == isc_sockettype_udp) && ((size_t)cc > read_count)) { + dev->attributes |= ISC_SOCKEVENTATTR_TRUNC; + cc--; + } +#endif + + /* + * If there are control messages attached, run through them and pull + * out the interesting bits. + */ + if (sock->type == isc_sockettype_udp) + process_cmsg(sock, &msghdr, dev); + + /* + * update the buffers (if any) and the i/o count + */ + dev->n += cc; + actual_count = cc; + buffer = ISC_LIST_HEAD(dev->bufferlist); + while (buffer != NULL && actual_count > 0U) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (isc_buffer_availablelength(buffer) <= actual_count) { + actual_count -= isc_buffer_availablelength(buffer); + isc_buffer_add(buffer, + isc_buffer_availablelength(buffer)); + } else { + isc_buffer_add(buffer, actual_count); + actual_count = 0; + POST(actual_count); + break; + } + buffer = ISC_LIST_NEXT(buffer, link); + if (buffer == NULL) { + INSIST(actual_count == 0U); + } + } + + /* + * If we read less than we expected, update counters, + * and let the upper layer poke the descriptor. + */ + if (((size_t)cc != read_count) && (dev->n < dev->minimum)) + return (DOIO_SOFT); + + /* + * Full reads are posted, or partials if partials are ok. + */ + dev->result = ISC_R_SUCCESS; + return (DOIO_SUCCESS); +} + +/* + * Returns: + * DOIO_SUCCESS The operation succeeded. dev->result contains + * ISC_R_SUCCESS. + * + * DOIO_HARD A hard or unexpected I/O error was encountered. + * dev->result contains the appropriate error. + * + * DOIO_SOFT A soft I/O error was encountered. No senddone + * event was sent. The operation should be retried. + * + * No other return values are possible. + */ +static int +doio_send(isc__socket_t *sock, isc_socketevent_t *dev) { + int cc; + struct iovec iov[MAXSCATTERGATHER_SEND]; + size_t write_count; + struct msghdr msghdr; + char addrbuf[ISC_SOCKADDR_FORMATSIZE]; + int attempts = 0; + int send_errno; + char strbuf[ISC_STRERRORSIZE]; + + build_msghdr_send(sock, dev, &msghdr, iov, &write_count); + + resend: + cc = sendmsg(sock->fd, &msghdr, 0); + send_errno = errno; + + /* + * Check for error or block condition. + */ + if (cc < 0) { + if (send_errno == EINTR && ++attempts < NRETRIES) + goto resend; + + if (SOFT_ERROR(send_errno)) + return (DOIO_SOFT); + +#define SOFT_OR_HARD(_system, _isc) \ + if (send_errno == _system) { \ + if (sock->connected) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_SENDFAIL]); \ + return (DOIO_HARD); \ + } \ + return (DOIO_SOFT); \ + } +#define ALWAYS_HARD(_system, _isc) \ + if (send_errno == _system) { \ + dev->result = _isc; \ + inc_stats(sock->manager->stats, \ + sock->statsindex[STATID_SENDFAIL]); \ + return (DOIO_HARD); \ + } + + SOFT_OR_HARD(ECONNREFUSED, ISC_R_CONNREFUSED); + ALWAYS_HARD(EACCES, ISC_R_NOPERM); + ALWAYS_HARD(EAFNOSUPPORT, ISC_R_ADDRNOTAVAIL); + ALWAYS_HARD(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ALWAYS_HARD(EHOSTUNREACH, ISC_R_HOSTUNREACH); +#ifdef EHOSTDOWN + ALWAYS_HARD(EHOSTDOWN, ISC_R_HOSTUNREACH); +#endif + ALWAYS_HARD(ENETUNREACH, ISC_R_NETUNREACH); + ALWAYS_HARD(ENOBUFS, ISC_R_NORESOURCES); + ALWAYS_HARD(EPERM, ISC_R_HOSTUNREACH); + ALWAYS_HARD(EPIPE, ISC_R_NOTCONNECTED); + ALWAYS_HARD(ECONNRESET, ISC_R_CONNECTIONRESET); + +#undef SOFT_OR_HARD +#undef ALWAYS_HARD + + /* + * The other error types depend on whether or not the + * socket is UDP or TCP. If it is UDP, some errors + * that we expect to be fatal under TCP are merely + * annoying, and are really soft errors. + * + * However, these soft errors are still returned as + * a status. + */ + isc_sockaddr_format(&dev->address, addrbuf, sizeof(addrbuf)); + isc__strerror(send_errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "internal_send: %s: %s", + addrbuf, strbuf); + dev->result = isc__errno2result(send_errno); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_SENDFAIL]); + return (DOIO_HARD); + } + + if (cc == 0) { + inc_stats(sock->manager->stats, + sock->statsindex[STATID_SENDFAIL]); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "doio_send: send() %s 0", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_RETURNED, "returned")); + } + + /* + * If we write less than we expected, update counters, poke. + */ + dev->n += cc; + if ((size_t)cc != write_count) + return (DOIO_SOFT); + + /* + * Exactly what we wanted to write. We're done with this + * entry. Post its completion event. + */ + dev->result = ISC_R_SUCCESS; + return (DOIO_SUCCESS); +} + +/* + * Kill. + * + * Caller must ensure that the socket is not locked and no external + * references exist. + */ +static void +closesocket(isc__socketmgr_t *manager, isc__socket_t *sock, int fd) { + isc_sockettype_t type = sock->type; + int lockid = FDLOCK_ID(fd); + + /* + * No one has this socket open, so the watcher doesn't have to be + * poked, and the socket doesn't have to be locked. + */ + LOCK(&manager->fdlock[lockid]); + manager->fds[fd] = NULL; + if (type == isc_sockettype_fdwatch) + manager->fdstate[fd] = CLOSED; + else + manager->fdstate[fd] = CLOSE_PENDING; + UNLOCK(&manager->fdlock[lockid]); + if (type == isc_sockettype_fdwatch) { + /* + * The caller may close the socket once this function returns, + * and `fd' may be reassigned for a new socket. So we do + * unwatch_fd() here, rather than defer it via select_poke(). + * Note: this may complicate data protection among threads and + * may reduce performance due to additional locks. One way to + * solve this would be to dup() the watched descriptor, but we + * take a simpler approach at this moment. + */ + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + } else + select_poke(manager, fd, SELECT_POKE_CLOSE); + + inc_stats(manager->stats, sock->statsindex[STATID_CLOSE]); + + /* + * update manager->maxfd here (XXX: this should be implemented more + * efficiently) + */ +#ifdef USE_SELECT + LOCK(&manager->lock); + if (manager->maxfd == fd) { + int i; + + manager->maxfd = 0; + for (i = fd - 1; i >= 0; i--) { + lockid = FDLOCK_ID(i); + + LOCK(&manager->fdlock[lockid]); + if (manager->fdstate[i] == MANAGED) { + manager->maxfd = i; + UNLOCK(&manager->fdlock[lockid]); + break; + } + UNLOCK(&manager->fdlock[lockid]); + } +#ifdef ISC_PLATFORM_USETHREADS + if (manager->maxfd < manager->pipe_fds[0]) + manager->maxfd = manager->pipe_fds[0]; +#endif + } + UNLOCK(&manager->lock); +#endif /* USE_SELECT */ +} + +static void +destroy(isc__socket_t **sockp) { + int fd; + isc__socket_t *sock = *sockp; + isc__socketmgr_t *manager = sock->manager; + + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_DESTROYING, "destroying"); + + INSIST(ISC_LIST_EMPTY(sock->accept_list)); + INSIST(ISC_LIST_EMPTY(sock->recv_list)); + INSIST(ISC_LIST_EMPTY(sock->send_list)); + INSIST(sock->connect_ev == NULL); + REQUIRE(sock->fd == -1 || sock->fd < (int)manager->maxsocks); + + if (sock->fd >= 0) { + fd = sock->fd; + sock->fd = -1; + closesocket(manager, sock, fd); + } + + LOCK(&manager->lock); + + ISC_LIST_UNLINK(manager->socklist, sock, link); + +#ifdef USE_WATCHER_THREAD + if (ISC_LIST_EMPTY(manager->socklist)) + SIGNAL(&manager->shutdown_ok); +#endif /* USE_WATCHER_THREAD */ + + /* can't unlock manager as its memory context is still used */ + free_socket(sockp); + + UNLOCK(&manager->lock); +} + +static isc_result_t +allocate_socket(isc__socketmgr_t *manager, isc_sockettype_t type, + isc__socket_t **socketp) +{ + isc__socket_t *sock; + isc_result_t result; + ISC_SOCKADDR_LEN_T cmsgbuflen; + + sock = isc_mem_get(manager->mctx, sizeof(*sock)); + + if (sock == NULL) + return (ISC_R_NOMEMORY); + + sock->common.magic = 0; + sock->common.impmagic = 0; + sock->references = 0; + + sock->manager = manager; + sock->type = type; + sock->fd = -1; + sock->dupped = 0; + sock->statsindex = NULL; + + ISC_LINK_INIT(sock, link); + + sock->recvcmsgbuf = NULL; + sock->sendcmsgbuf = NULL; + + /* + * set up cmsg buffers + */ + cmsgbuflen = 0; +#if defined(USE_CMSG) && defined(ISC_PLATFORM_HAVEIN6PKTINFO) + cmsgbuflen += cmsg_space(sizeof(struct in6_pktinfo)); +#endif +#if defined(USE_CMSG) && defined(SO_TIMESTAMP) + cmsgbuflen += cmsg_space(sizeof(struct timeval)); +#endif + sock->recvcmsgbuflen = cmsgbuflen; + if (sock->recvcmsgbuflen != 0U) { + sock->recvcmsgbuf = isc_mem_get(manager->mctx, cmsgbuflen); + if (sock->recvcmsgbuf == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + } + + cmsgbuflen = 0; +#if defined(USE_CMSG) && defined(ISC_PLATFORM_HAVEIN6PKTINFO) + cmsgbuflen += cmsg_space(sizeof(struct in6_pktinfo)); +#if defined(IPV6_USE_MIN_MTU) + /* + * Provide space for working around FreeBSD's broken IPV6_USE_MIN_MTU + * support. + */ + cmsgbuflen += cmsg_space(sizeof(int)); +#endif +#endif + sock->sendcmsgbuflen = cmsgbuflen; + if (sock->sendcmsgbuflen != 0U) { + sock->sendcmsgbuf = isc_mem_get(manager->mctx, cmsgbuflen); + if (sock->sendcmsgbuf == NULL) { + result = ISC_R_NOMEMORY; + goto error; + } + } + + memset(sock->name, 0, sizeof(sock->name)); + sock->tag = NULL; + + /* + * set up list of readers and writers to be initially empty + */ + ISC_LIST_INIT(sock->recv_list); + ISC_LIST_INIT(sock->send_list); + ISC_LIST_INIT(sock->accept_list); + sock->connect_ev = NULL; + sock->pending_recv = 0; + sock->pending_send = 0; + sock->pending_accept = 0; + sock->listener = 0; + sock->connected = 0; + sock->connecting = 0; + sock->bound = 0; + + /* + * initialize the lock + */ + result = isc_mutex_init(&sock->lock); + if (result != ISC_R_SUCCESS) { + sock->common.magic = 0; + sock->common.impmagic = 0; + goto error; + } + + /* + * Initialize readable and writable events + */ + ISC_EVENT_INIT(&sock->readable_ev, sizeof(intev_t), + ISC_EVENTATTR_NOPURGE, NULL, ISC_SOCKEVENT_INTR, + NULL, sock, sock, NULL, NULL); + ISC_EVENT_INIT(&sock->writable_ev, sizeof(intev_t), + ISC_EVENTATTR_NOPURGE, NULL, ISC_SOCKEVENT_INTW, + NULL, sock, sock, NULL, NULL); + + sock->common.magic = ISCAPI_SOCKET_MAGIC; + sock->common.impmagic = SOCKET_MAGIC; + *socketp = sock; + + return (ISC_R_SUCCESS); + + error: + if (sock->recvcmsgbuf != NULL) + isc_mem_put(manager->mctx, sock->recvcmsgbuf, + sock->recvcmsgbuflen); + if (sock->sendcmsgbuf != NULL) + isc_mem_put(manager->mctx, sock->sendcmsgbuf, + sock->sendcmsgbuflen); + isc_mem_put(manager->mctx, sock, sizeof(*sock)); + + return (result); +} + +/* + * This event requires that the various lists be empty, that the reference + * count be 1, and that the magic number is valid. The other socket bits, + * like the lock, must be initialized as well. The fd associated must be + * marked as closed, by setting it to -1 on close, or this routine will + * also close the socket. + */ +static void +free_socket(isc__socket_t **socketp) { + isc__socket_t *sock = *socketp; + + INSIST(sock->references == 0); + INSIST(VALID_SOCKET(sock)); + INSIST(!sock->connecting); + INSIST(!sock->pending_recv); + INSIST(!sock->pending_send); + INSIST(!sock->pending_accept); + INSIST(ISC_LIST_EMPTY(sock->recv_list)); + INSIST(ISC_LIST_EMPTY(sock->send_list)); + INSIST(ISC_LIST_EMPTY(sock->accept_list)); + INSIST(!ISC_LINK_LINKED(sock, link)); + + if (sock->recvcmsgbuf != NULL) + isc_mem_put(sock->manager->mctx, sock->recvcmsgbuf, + sock->recvcmsgbuflen); + if (sock->sendcmsgbuf != NULL) + isc_mem_put(sock->manager->mctx, sock->sendcmsgbuf, + sock->sendcmsgbuflen); + + sock->common.magic = 0; + sock->common.impmagic = 0; + + DESTROYLOCK(&sock->lock); + + isc_mem_put(sock->manager->mctx, sock, sizeof(*sock)); + + *socketp = NULL; +} + +#ifdef SO_BSDCOMPAT +/* + * This really should not be necessary to do. Having to workout + * which kernel version we are on at run time so that we don't cause + * the kernel to issue a warning about us using a deprecated socket option. + * Such warnings should *never* be on by default in production kernels. + * + * We can't do this a build time because executables are moved between + * machines and hence kernels. + * + * We can't just not set SO_BSDCOMAT because some kernels require it. + */ + +static isc_once_t bsdcompat_once = ISC_ONCE_INIT; +isc_boolean_t bsdcompat = ISC_TRUE; + +static void +clear_bsdcompat(void) { +#ifdef __linux__ + struct utsname buf; + char *endp; + long int major; + long int minor; + + uname(&buf); /* Can only fail if buf is bad in Linux. */ + + /* Paranoia in parsing can be increased, but we trust uname(). */ + major = strtol(buf.release, &endp, 10); + if (*endp == '.') { + minor = strtol(endp+1, &endp, 10); + if ((major > 2) || ((major == 2) && (minor >= 4))) { + bsdcompat = ISC_FALSE; + } + } +#endif /* __linux __ */ +} +#endif + +static isc_result_t +opensocket(isc__socketmgr_t *manager, isc__socket_t *sock, + isc__socket_t *dup_socket) +{ + isc_result_t result; + char strbuf[ISC_STRERRORSIZE]; + const char *err = "socket"; + int tries = 0; +#if defined(USE_CMSG) || defined(SO_BSDCOMPAT) + int on = 1; +#endif +#if defined(SO_RCVBUF) + ISC_SOCKADDR_LEN_T optlen; + int size; +#endif + + again: + if (dup_socket == NULL) { + switch (sock->type) { + case isc_sockettype_udp: + sock->fd = socket(sock->pf, SOCK_DGRAM, IPPROTO_UDP); + break; + case isc_sockettype_tcp: + sock->fd = socket(sock->pf, SOCK_STREAM, IPPROTO_TCP); + break; + case isc_sockettype_unix: + sock->fd = socket(sock->pf, SOCK_STREAM, 0); + break; + case isc_sockettype_fdwatch: + /* + * We should not be called for isc_sockettype_fdwatch + * sockets. + */ + INSIST(0); + break; + } + } else { + sock->fd = dup(dup_socket->fd); + sock->dupped = 1; + sock->bound = dup_socket->bound; + } + if (sock->fd == -1 && errno == EINTR && tries++ < 42) + goto again; + +#ifdef F_DUPFD + /* + * Leave a space for stdio and TCP to work in. + */ + if (manager->reserved != 0 && sock->type == isc_sockettype_udp && + sock->fd >= 0 && sock->fd < manager->reserved) { + int new, tmp; + new = fcntl(sock->fd, F_DUPFD, manager->reserved); + tmp = errno; + (void)close(sock->fd); + errno = tmp; + sock->fd = new; + err = "isc_socket_create: fcntl/reserved"; + } else if (sock->fd >= 0 && sock->fd < 20) { + int new, tmp; + new = fcntl(sock->fd, F_DUPFD, 20); + tmp = errno; + (void)close(sock->fd); + errno = tmp; + sock->fd = new; + err = "isc_socket_create: fcntl"; + } +#endif + + if (sock->fd >= (int)manager->maxsocks) { + (void)close(sock->fd); + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "socket: file descriptor exceeds limit (%d/%u)", + sock->fd, manager->maxsocks); + return (ISC_R_NORESOURCES); + } + + if (sock->fd < 0) { + switch (errno) { + case EMFILE: + case ENFILE: + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "%s: %s", err, strbuf); + /* fallthrough */ + case ENOBUFS: + return (ISC_R_NORESOURCES); + + case EPROTONOSUPPORT: + case EPFNOSUPPORT: + case EAFNOSUPPORT: + /* + * Linux 2.2 (and maybe others) return EINVAL instead of + * EAFNOSUPPORT. + */ + case EINVAL: + return (ISC_R_FAMILYNOSUPPORT); + + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "%s() %s: %s", err, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + return (ISC_R_UNEXPECTED); + } + } + + if (dup_socket != NULL) + goto setup_done; + + result = make_nonblock(sock->fd); + if (result != ISC_R_SUCCESS) { + (void)close(sock->fd); + return (result); + } + +#ifdef SO_BSDCOMPAT + RUNTIME_CHECK(isc_once_do(&bsdcompat_once, + clear_bsdcompat) == ISC_R_SUCCESS); + if (sock->type != isc_sockettype_unix && bsdcompat && + setsockopt(sock->fd, SOL_SOCKET, SO_BSDCOMPAT, + (void *)&on, sizeof(on)) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_BSDCOMPAT) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + /* Press on... */ + } +#endif + +#ifdef SO_NOSIGPIPE + if (setsockopt(sock->fd, SOL_SOCKET, SO_NOSIGPIPE, + (void *)&on, sizeof(on)) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_NOSIGPIPE) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + /* Press on... */ + } +#endif + +#if defined(USE_CMSG) || defined(SO_RCVBUF) + if (sock->type == isc_sockettype_udp) { + +#if defined(USE_CMSG) +#if defined(SO_TIMESTAMP) + if (setsockopt(sock->fd, SOL_SOCKET, SO_TIMESTAMP, + (void *)&on, sizeof(on)) < 0 + && errno != ENOPROTOOPT) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_TIMESTAMP) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + /* Press on... */ + } +#endif /* SO_TIMESTAMP */ + +#if defined(ISC_PLATFORM_HAVEIPV6) + if (sock->pf == AF_INET6 && sock->recvcmsgbuflen == 0U) { + /* + * Warn explicitly because this anomaly can be hidden + * in usual operation (and unexpectedly appear later). + */ + UNEXPECTED_ERROR(__FILE__, __LINE__, + "No buffer available to receive " + "IPv6 destination"); + } +#ifdef ISC_PLATFORM_HAVEIN6PKTINFO +#ifdef IPV6_RECVPKTINFO + /* RFC 3542 */ + if ((sock->pf == AF_INET6) + && (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_RECVPKTINFO, + (void *)&on, sizeof(on)) < 0)) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_RECVPKTINFO) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +#else + /* RFC 2292 */ + if ((sock->pf == AF_INET6) + && (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_PKTINFO, + (void *)&on, sizeof(on)) < 0)) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_PKTINFO) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +#endif /* IPV6_RECVPKTINFO */ +#endif /* ISC_PLATFORM_HAVEIN6PKTINFO */ +#ifdef IPV6_USE_MIN_MTU /* RFC 3542, not too common yet*/ + /* use minimum MTU */ + if (sock->pf == AF_INET6 && + setsockopt(sock->fd, IPPROTO_IPV6, IPV6_USE_MIN_MTU, + (void *)&on, sizeof(on)) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_USE_MIN_MTU) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +#endif +#if defined(IPV6_MTU) + /* + * Use minimum MTU on IPv6 sockets. + */ + if (sock->pf == AF_INET6) { + int mtu = 1280; + (void)setsockopt(sock->fd, IPPROTO_IPV6, IPV6_MTU, + &mtu, sizeof(mtu)); + } +#endif +#if defined(IPV6_MTU_DISCOVER) && defined(IPV6_PMTUDISC_DONT) + /* + * Turn off Path MTU discovery on IPv6/UDP sockets. + */ + if (sock->pf == AF_INET6) { + int action = IPV6_PMTUDISC_DONT; + (void)setsockopt(sock->fd, IPPROTO_IPV6, + IPV6_MTU_DISCOVER, &action, + sizeof(action)); + } +#endif +#endif /* ISC_PLATFORM_HAVEIPV6 */ +#endif /* defined(USE_CMSG) */ + +#if defined(IP_MTU_DISCOVER) && defined(IP_PMTUDISC_DONT) + /* + * Turn off Path MTU discovery on IPv4/UDP sockets. + */ + if (sock->pf == AF_INET) { + int action = IP_PMTUDISC_DONT; + (void)setsockopt(sock->fd, IPPROTO_IP, IP_MTU_DISCOVER, + &action, sizeof(action)); + } +#endif +#if defined(IP_DONTFRAG) + /* + * Turn off Path MTU discovery on IPv4/UDP sockets. + */ + if (sock->pf == AF_INET) { + int off = 0; + (void)setsockopt(sock->fd, IPPROTO_IP, IP_DONTFRAG, + &off, sizeof(off)); + } +#endif + +#if defined(SO_RCVBUF) + optlen = sizeof(size); + if (getsockopt(sock->fd, SOL_SOCKET, SO_RCVBUF, + (void *)&size, &optlen) >= 0 && + size < RCVBUFSIZE) { + size = RCVBUFSIZE; + if (setsockopt(sock->fd, SOL_SOCKET, SO_RCVBUF, + (void *)&size, sizeof(size)) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, SO_RCVBUF, %d) %s: %s", + sock->fd, size, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } + } +#endif + } +#endif /* defined(USE_CMSG) || defined(SO_RCVBUF) */ + +setup_done: + inc_stats(manager->stats, sock->statsindex[STATID_OPEN]); + + return (ISC_R_SUCCESS); +} + +/* + * Create a 'type' socket or duplicate an existing socket, managed + * by 'manager'. Events will be posted to 'task' and when dispatched + * 'action' will be called with 'arg' as the arg value. The new + * socket is returned in 'socketp'. + */ +static isc_result_t +socket_create(isc_socketmgr_t *manager0, int pf, isc_sockettype_t type, + isc_socket_t **socketp, isc_socket_t *dup_socket) +{ + isc__socket_t *sock = NULL; + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + isc_result_t result; + int lockid; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(socketp != NULL && *socketp == NULL); + REQUIRE(type != isc_sockettype_fdwatch); + + result = allocate_socket(manager, type, &sock); + if (result != ISC_R_SUCCESS) + return (result); + + switch (sock->type) { + case isc_sockettype_udp: + sock->statsindex = + (pf == AF_INET) ? upd4statsindex : upd6statsindex; + break; + case isc_sockettype_tcp: + sock->statsindex = + (pf == AF_INET) ? tcp4statsindex : tcp6statsindex; + break; + case isc_sockettype_unix: + sock->statsindex = unixstatsindex; + break; + default: + INSIST(0); + } + + sock->pf = pf; + + result = opensocket(manager, sock, (isc__socket_t *)dup_socket); + if (result != ISC_R_SUCCESS) { + inc_stats(manager->stats, sock->statsindex[STATID_OPENFAIL]); + free_socket(&sock); + return (result); + } + + sock->common.methods = (isc_socketmethods_t *)&socketmethods; + sock->references = 1; + *socketp = (isc_socket_t *)sock; + + /* + * Note we don't have to lock the socket like we normally would because + * there are no external references to it yet. + */ + + lockid = FDLOCK_ID(sock->fd); + LOCK(&manager->fdlock[lockid]); + manager->fds[sock->fd] = sock; + manager->fdstate[sock->fd] = MANAGED; +#ifdef USE_DEVPOLL + INSIST(sock->manager->fdpollinfo[sock->fd].want_read == 0 && + sock->manager->fdpollinfo[sock->fd].want_write == 0); +#endif + UNLOCK(&manager->fdlock[lockid]); + + LOCK(&manager->lock); + ISC_LIST_APPEND(manager->socklist, sock, link); +#ifdef USE_SELECT + if (manager->maxfd < sock->fd) + manager->maxfd = sock->fd; +#endif + UNLOCK(&manager->lock); + + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_CREATED, dup_socket == NULL ? "dupped" : "created"); + + return (ISC_R_SUCCESS); +} + +/*% + * Create a new 'type' socket managed by 'manager'. Events + * will be posted to 'task' and when dispatched 'action' will be + * called with 'arg' as the arg value. The new socket is returned + * in 'socketp'. + */ +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_create(isc_socketmgr_t *manager0, int pf, isc_sockettype_t type, + isc_socket_t **socketp) +{ + return (socket_create(manager0, pf, type, socketp, NULL)); +} + +/*% + * Duplicate an existing socket. The new socket is returned + * in 'socketp'. + */ +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_dup(isc_socket_t *sock0, isc_socket_t **socketp) { + isc__socket_t *sock = (isc__socket_t *)sock0; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(socketp != NULL && *socketp == NULL); + + return (socket_create((isc_socketmgr_t *) sock->manager, + sock->pf, sock->type, socketp, + sock0)); +} + +#ifdef BIND9 +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_open(isc_socket_t *sock0) { + isc_result_t result; + isc__socket_t *sock = (isc__socket_t *)sock0; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + REQUIRE(sock->references == 1); + REQUIRE(sock->type != isc_sockettype_fdwatch); + UNLOCK(&sock->lock); + /* + * We don't need to retain the lock hereafter, since no one else has + * this socket. + */ + REQUIRE(sock->fd == -1); + + result = opensocket(sock->manager, sock, NULL); + if (result != ISC_R_SUCCESS) + sock->fd = -1; + + if (result == ISC_R_SUCCESS) { + int lockid = FDLOCK_ID(sock->fd); + + LOCK(&sock->manager->fdlock[lockid]); + sock->manager->fds[sock->fd] = sock; + sock->manager->fdstate[sock->fd] = MANAGED; +#ifdef USE_DEVPOLL + INSIST(sock->manager->fdpollinfo[sock->fd].want_read == 0 && + sock->manager->fdpollinfo[sock->fd].want_write == 0); +#endif + UNLOCK(&sock->manager->fdlock[lockid]); + +#ifdef USE_SELECT + LOCK(&sock->manager->lock); + if (sock->manager->maxfd < sock->fd) + sock->manager->maxfd = sock->fd; + UNLOCK(&sock->manager->lock); +#endif + } + + return (result); +} +#endif /* BIND9 */ + +/* + * Create a new 'type' socket managed by 'manager'. Events + * will be posted to 'task' and when dispatched 'action' will be + * called with 'arg' as the arg value. The new socket is returned + * in 'socketp'. + */ +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_fdwatchcreate(isc_socketmgr_t *manager0, int fd, int flags, + isc_sockfdwatch_t callback, void *cbarg, + isc_task_t *task, isc_socket_t **socketp) +{ + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + isc__socket_t *sock = NULL; + isc_result_t result; + int lockid; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(socketp != NULL && *socketp == NULL); + + result = allocate_socket(manager, isc_sockettype_fdwatch, &sock); + if (result != ISC_R_SUCCESS) + return (result); + + sock->fd = fd; + sock->fdwatcharg = cbarg; + sock->fdwatchcb = callback; + sock->fdwatchflags = flags; + sock->fdwatchtask = task; + sock->statsindex = fdwatchstatsindex; + + sock->common.methods = (isc_socketmethods_t *)&socketmethods; + sock->references = 1; + *socketp = (isc_socket_t *)sock; + + /* + * Note we don't have to lock the socket like we normally would because + * there are no external references to it yet. + */ + + lockid = FDLOCK_ID(sock->fd); + LOCK(&manager->fdlock[lockid]); + manager->fds[sock->fd] = sock; + manager->fdstate[sock->fd] = MANAGED; + UNLOCK(&manager->fdlock[lockid]); + + LOCK(&manager->lock); + ISC_LIST_APPEND(manager->socklist, sock, link); +#ifdef USE_SELECT + if (manager->maxfd < sock->fd) + manager->maxfd = sock->fd; +#endif + UNLOCK(&manager->lock); + + if (flags & ISC_SOCKFDWATCH_READ) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + if (flags & ISC_SOCKFDWATCH_WRITE) + select_poke(sock->manager, sock->fd, SELECT_POKE_WRITE); + + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_CREATED, "fdwatch-created"); + + return (ISC_R_SUCCESS); +} + +/* + * Indicate to the manager that it should watch the socket again. + * This can be used to restart watching if the previous event handler + * didn't indicate there was more data to be processed. Primarily + * it is for writing but could be used for reading if desired + */ + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_fdwatchpoke(isc_socket_t *sock0, int flags) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + + REQUIRE(VALID_SOCKET(sock)); + + /* + * We check both flags first to allow us to get the lock + * once but only if we need it. + */ + + if ((flags & (ISC_SOCKFDWATCH_READ | ISC_SOCKFDWATCH_WRITE)) != 0) { + LOCK(&sock->lock); + if (((flags & ISC_SOCKFDWATCH_READ) != 0) && + !sock->pending_recv) + select_poke(sock->manager, sock->fd, + SELECT_POKE_READ); + if (((flags & ISC_SOCKFDWATCH_WRITE) != 0) && + !sock->pending_send) + select_poke(sock->manager, sock->fd, + SELECT_POKE_WRITE); + UNLOCK(&sock->lock); + } + + socket_log(sock, NULL, TRACE, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_POKED, "fdwatch-poked flags: %d", flags); + + return (ISC_R_SUCCESS); +} + +/* + * Attach to a socket. Caller must explicitly detach when it is done. + */ +ISC_SOCKETFUNC_SCOPE void +isc__socket_attach(isc_socket_t *sock0, isc_socket_t **socketp) { + isc__socket_t *sock = (isc__socket_t *)sock0; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(socketp != NULL && *socketp == NULL); + + LOCK(&sock->lock); + sock->references++; + UNLOCK(&sock->lock); + + *socketp = (isc_socket_t *)sock; +} + +/* + * Dereference a socket. If this is the last reference to it, clean things + * up by destroying the socket. + */ +ISC_SOCKETFUNC_SCOPE void +isc__socket_detach(isc_socket_t **socketp) { + isc__socket_t *sock; + isc_boolean_t kill_socket = ISC_FALSE; + + REQUIRE(socketp != NULL); + sock = (isc__socket_t *)*socketp; + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + REQUIRE(sock->references > 0); + sock->references--; + if (sock->references == 0) + kill_socket = ISC_TRUE; + UNLOCK(&sock->lock); + + if (kill_socket) + destroy(&sock); + + *socketp = NULL; +} + +#ifdef BIND9 +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_close(isc_socket_t *sock0) { + isc__socket_t *sock = (isc__socket_t *)sock0; + int fd; + isc__socketmgr_t *manager; + + fflush(stdout); + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + REQUIRE(sock->references == 1); + REQUIRE(sock->type != isc_sockettype_fdwatch); + REQUIRE(sock->fd >= 0 && sock->fd < (int)sock->manager->maxsocks); + + INSIST(!sock->connecting); + INSIST(!sock->pending_recv); + INSIST(!sock->pending_send); + INSIST(!sock->pending_accept); + INSIST(ISC_LIST_EMPTY(sock->recv_list)); + INSIST(ISC_LIST_EMPTY(sock->send_list)); + INSIST(ISC_LIST_EMPTY(sock->accept_list)); + INSIST(sock->connect_ev == NULL); + + manager = sock->manager; + fd = sock->fd; + sock->fd = -1; + sock->dupped = 0; + memset(sock->name, 0, sizeof(sock->name)); + sock->tag = NULL; + sock->listener = 0; + sock->connected = 0; + sock->connecting = 0; + sock->bound = 0; + isc_sockaddr_any(&sock->peer_address); + + UNLOCK(&sock->lock); + + closesocket(manager, sock, fd); + + return (ISC_R_SUCCESS); +} +#endif /* BIND9 */ + +/* + * I/O is possible on a given socket. Schedule an event to this task that + * will call an internal function to do the I/O. This will charge the + * task with the I/O operation and let our select loop handler get back + * to doing something real as fast as possible. + * + * The socket and manager must be locked before calling this function. + */ +static void +dispatch_recv(isc__socket_t *sock) { + intev_t *iev; + isc_socketevent_t *ev; + isc_task_t *sender; + + INSIST(!sock->pending_recv); + + if (sock->type != isc_sockettype_fdwatch) { + ev = ISC_LIST_HEAD(sock->recv_list); + if (ev == NULL) + return; + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "dispatch_recv: event %p -> task %p", + ev, ev->ev_sender); + sender = ev->ev_sender; + } else { + sender = sock->fdwatchtask; + } + + sock->pending_recv = 1; + iev = &sock->readable_ev; + + sock->references++; + iev->ev_sender = sock; + if (sock->type == isc_sockettype_fdwatch) + iev->ev_action = internal_fdwatch_read; + else + iev->ev_action = internal_recv; + iev->ev_arg = sock; + + isc_task_send(sender, (isc_event_t **)&iev); +} + +static void +dispatch_send(isc__socket_t *sock) { + intev_t *iev; + isc_socketevent_t *ev; + isc_task_t *sender; + + INSIST(!sock->pending_send); + + if (sock->type != isc_sockettype_fdwatch) { + ev = ISC_LIST_HEAD(sock->send_list); + if (ev == NULL) + return; + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "dispatch_send: event %p -> task %p", + ev, ev->ev_sender); + sender = ev->ev_sender; + } else { + sender = sock->fdwatchtask; + } + + sock->pending_send = 1; + iev = &sock->writable_ev; + + sock->references++; + iev->ev_sender = sock; + if (sock->type == isc_sockettype_fdwatch) + iev->ev_action = internal_fdwatch_write; + else + iev->ev_action = internal_send; + iev->ev_arg = sock; + + isc_task_send(sender, (isc_event_t **)&iev); +} + +/* + * Dispatch an internal accept event. + */ +static void +dispatch_accept(isc__socket_t *sock) { + intev_t *iev; + isc_socket_newconnev_t *ev; + + INSIST(!sock->pending_accept); + + /* + * Are there any done events left, or were they all canceled + * before the manager got the socket lock? + */ + ev = ISC_LIST_HEAD(sock->accept_list); + if (ev == NULL) + return; + + sock->pending_accept = 1; + iev = &sock->readable_ev; + + sock->references++; /* keep socket around for this internal event */ + iev->ev_sender = sock; + iev->ev_action = internal_accept; + iev->ev_arg = sock; + + isc_task_send(ev->ev_sender, (isc_event_t **)&iev); +} + +static void +dispatch_connect(isc__socket_t *sock) { + intev_t *iev; + isc_socket_connev_t *ev; + + iev = &sock->writable_ev; + + ev = sock->connect_ev; + INSIST(ev != NULL); /* XXX */ + + INSIST(sock->connecting); + + sock->references++; /* keep socket around for this internal event */ + iev->ev_sender = sock; + iev->ev_action = internal_connect; + iev->ev_arg = sock; + + isc_task_send(ev->ev_sender, (isc_event_t **)&iev); +} + +/* + * Dequeue an item off the given socket's read queue, set the result code + * in the done event to the one provided, and send it to the task it was + * destined for. + * + * If the event to be sent is on a list, remove it before sending. If + * asked to, send and detach from the socket as well. + * + * Caller must have the socket locked if the event is attached to the socket. + */ +static void +send_recvdone_event(isc__socket_t *sock, isc_socketevent_t **dev) { + isc_task_t *task; + + task = (*dev)->ev_sender; + + (*dev)->ev_sender = sock; + + if (ISC_LINK_LINKED(*dev, ev_link)) + ISC_LIST_DEQUEUE(sock->recv_list, *dev, ev_link); + + if (((*dev)->attributes & ISC_SOCKEVENTATTR_ATTACHED) + == ISC_SOCKEVENTATTR_ATTACHED) + isc_task_sendanddetach(&task, (isc_event_t **)dev); + else + isc_task_send(task, (isc_event_t **)dev); +} + +/* + * See comments for send_recvdone_event() above. + * + * Caller must have the socket locked if the event is attached to the socket. + */ +static void +send_senddone_event(isc__socket_t *sock, isc_socketevent_t **dev) { + isc_task_t *task; + + INSIST(dev != NULL && *dev != NULL); + + task = (*dev)->ev_sender; + (*dev)->ev_sender = sock; + + if (ISC_LINK_LINKED(*dev, ev_link)) + ISC_LIST_DEQUEUE(sock->send_list, *dev, ev_link); + + if (((*dev)->attributes & ISC_SOCKEVENTATTR_ATTACHED) + == ISC_SOCKEVENTATTR_ATTACHED) + isc_task_sendanddetach(&task, (isc_event_t **)dev); + else + isc_task_send(task, (isc_event_t **)dev); +} + +/* + * Call accept() on a socket, to get the new file descriptor. The listen + * socket is used as a prototype to create a new isc_socket_t. The new + * socket has one outstanding reference. The task receiving the event + * will be detached from just after the event is delivered. + * + * On entry to this function, the event delivered is the internal + * readable event, and the first item on the accept_list should be + * the done event we want to send. If the list is empty, this is a no-op, + * so just unlock and return. + */ +static void +internal_accept(isc_task_t *me, isc_event_t *ev) { + isc__socket_t *sock; + isc__socketmgr_t *manager; + isc_socket_newconnev_t *dev; + isc_task_t *task; + ISC_SOCKADDR_LEN_T addrlen; + int fd; + isc_result_t result = ISC_R_SUCCESS; + char strbuf[ISC_STRERRORSIZE]; + const char *err = "accept"; + + UNUSED(me); + + sock = ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTLOCK, + "internal_accept called, locked socket"); + + manager = sock->manager; + INSIST(VALID_MANAGER(manager)); + + INSIST(sock->listener); + INSIST(sock->pending_accept == 1); + sock->pending_accept = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Get the first item off the accept list. + * If it is empty, unlock the socket and return. + */ + dev = ISC_LIST_HEAD(sock->accept_list); + if (dev == NULL) { + UNLOCK(&sock->lock); + return; + } + + /* + * Try to accept the new connection. If the accept fails with + * EAGAIN or EINTR, simply poke the watcher to watch this socket + * again. Also ignore ECONNRESET, which has been reported to + * be spuriously returned on Linux 2.2.19 although it is not + * a documented error for accept(). ECONNABORTED has been + * reported for Solaris 8. The rest are thrown in not because + * we have seen them but because they are ignored by other + * daemons such as BIND 8 and Apache. + */ + + addrlen = sizeof(NEWCONNSOCK(dev)->peer_address.type); + memset(&NEWCONNSOCK(dev)->peer_address.type, 0, addrlen); + fd = accept(sock->fd, &NEWCONNSOCK(dev)->peer_address.type.sa, + (void *)&addrlen); + +#ifdef F_DUPFD + /* + * Leave a space for stdio to work in. + */ + if (fd >= 0 && fd < 20) { + int new, tmp; + new = fcntl(fd, F_DUPFD, 20); + tmp = errno; + (void)close(fd); + errno = tmp; + fd = new; + err = "accept/fcntl"; + } +#endif + + if (fd < 0) { + if (SOFT_ERROR(errno)) + goto soft_error; + switch (errno) { + case ENFILE: + case EMFILE: + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "%s: too many open file descriptors", + err); + goto soft_error; + + case ENOBUFS: + case ENOMEM: + case ECONNRESET: + case ECONNABORTED: + case EHOSTUNREACH: + case EHOSTDOWN: + case ENETUNREACH: + case ENETDOWN: + case ECONNREFUSED: +#ifdef EPROTO + case EPROTO: +#endif +#ifdef ENONET + case ENONET: +#endif + goto soft_error; + default: + break; + } + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_accept: %s() %s: %s", err, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + fd = -1; + result = ISC_R_UNEXPECTED; + } else { + if (addrlen == 0U) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_accept(): " + "accept() failed to return " + "remote address"); + + (void)close(fd); + goto soft_error; + } else if (NEWCONNSOCK(dev)->peer_address.type.sa.sa_family != + sock->pf) + { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_accept(): " + "accept() returned peer address " + "family %u (expected %u)", + NEWCONNSOCK(dev)->peer_address. + type.sa.sa_family, + sock->pf); + (void)close(fd); + goto soft_error; + } else if (fd >= (int)manager->maxsocks) { + isc_log_iwrite(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYFDS, + "accept: " + "file descriptor exceeds limit (%d/%u)", + fd, manager->maxsocks); + (void)close(fd); + goto soft_error; + } + } + + if (fd != -1) { + NEWCONNSOCK(dev)->peer_address.length = addrlen; + NEWCONNSOCK(dev)->pf = sock->pf; + } + + /* + * Pull off the done event. + */ + ISC_LIST_UNLINK(sock->accept_list, dev, ev_link); + + /* + * Poke watcher if there are more pending accepts. + */ + if (!ISC_LIST_EMPTY(sock->accept_list)) + select_poke(sock->manager, sock->fd, SELECT_POKE_ACCEPT); + + UNLOCK(&sock->lock); + + if (fd != -1) { + result = make_nonblock(fd); + if (result != ISC_R_SUCCESS) { + (void)close(fd); + fd = -1; + } + } + + /* + * -1 means the new socket didn't happen. + */ + if (fd != -1) { + int lockid = FDLOCK_ID(fd); + + LOCK(&manager->fdlock[lockid]); + manager->fds[fd] = NEWCONNSOCK(dev); + manager->fdstate[fd] = MANAGED; + UNLOCK(&manager->fdlock[lockid]); + + LOCK(&manager->lock); + ISC_LIST_APPEND(manager->socklist, NEWCONNSOCK(dev), link); + + NEWCONNSOCK(dev)->fd = fd; + NEWCONNSOCK(dev)->bound = 1; + NEWCONNSOCK(dev)->connected = 1; + + /* + * Save away the remote address + */ + dev->address = NEWCONNSOCK(dev)->peer_address; + +#ifdef USE_SELECT + if (manager->maxfd < fd) + manager->maxfd = fd; +#endif + + socket_log(sock, &NEWCONNSOCK(dev)->peer_address, CREATION, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTEDCXN, + "accepted connection, new socket %p", + dev->newsocket); + + UNLOCK(&manager->lock); + + inc_stats(manager->stats, sock->statsindex[STATID_ACCEPT]); + } else { + inc_stats(manager->stats, sock->statsindex[STATID_ACCEPTFAIL]); + NEWCONNSOCK(dev)->references--; + free_socket((isc__socket_t **)&dev->newsocket); + } + + /* + * Fill in the done event details and send it off. + */ + dev->result = result; + task = dev->ev_sender; + dev->ev_sender = sock; + + isc_task_sendanddetach(&task, ISC_EVENT_PTR(&dev)); + return; + + soft_error: + select_poke(sock->manager, sock->fd, SELECT_POKE_ACCEPT); + UNLOCK(&sock->lock); + + inc_stats(manager->stats, sock->statsindex[STATID_ACCEPTFAIL]); + return; +} + +static void +internal_recv(isc_task_t *me, isc_event_t *ev) { + isc_socketevent_t *dev; + isc__socket_t *sock; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTR); + + sock = ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALRECV, + "internal_recv: task %p got event %p", me, ev); + + INSIST(sock->pending_recv == 1); + sock->pending_recv = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Try to do as much I/O as possible on this socket. There are no + * limits here, currently. + */ + dev = ISC_LIST_HEAD(sock->recv_list); + while (dev != NULL) { + switch (doio_recv(sock, dev)) { + case DOIO_SOFT: + goto poke; + + case DOIO_EOF: + /* + * read of 0 means the remote end was closed. + * Run through the event queue and dispatch all + * the events with an EOF result code. + */ + do { + dev->result = ISC_R_EOF; + send_recvdone_event(sock, &dev); + dev = ISC_LIST_HEAD(sock->recv_list); + } while (dev != NULL); + goto poke; + + case DOIO_SUCCESS: + case DOIO_HARD: + send_recvdone_event(sock, &dev); + break; + } + + dev = ISC_LIST_HEAD(sock->recv_list); + } + + poke: + if (!ISC_LIST_EMPTY(sock->recv_list)) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + + UNLOCK(&sock->lock); +} + +static void +internal_send(isc_task_t *me, isc_event_t *ev) { + isc_socketevent_t *dev; + isc__socket_t *sock; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTW); + + /* + * Find out what socket this is and lock it. + */ + sock = (isc__socket_t *)ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALSEND, + "internal_send: task %p got event %p", me, ev); + + INSIST(sock->pending_send == 1); + sock->pending_send = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Try to do as much I/O as possible on this socket. There are no + * limits here, currently. + */ + dev = ISC_LIST_HEAD(sock->send_list); + while (dev != NULL) { + switch (doio_send(sock, dev)) { + case DOIO_SOFT: + goto poke; + + case DOIO_HARD: + case DOIO_SUCCESS: + send_senddone_event(sock, &dev); + break; + } + + dev = ISC_LIST_HEAD(sock->send_list); + } + + poke: + if (!ISC_LIST_EMPTY(sock->send_list)) + select_poke(sock->manager, sock->fd, SELECT_POKE_WRITE); + + UNLOCK(&sock->lock); +} + +static void +internal_fdwatch_write(isc_task_t *me, isc_event_t *ev) { + isc__socket_t *sock; + int more_data; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTW); + + /* + * Find out what socket this is and lock it. + */ + sock = (isc__socket_t *)ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALSEND, + "internal_fdwatch_write: task %p got event %p", me, ev); + + INSIST(sock->pending_send == 1); + + UNLOCK(&sock->lock); + more_data = (sock->fdwatchcb)(me, (isc_socket_t *)sock, + sock->fdwatcharg, ISC_SOCKFDWATCH_WRITE); + LOCK(&sock->lock); + + sock->pending_send = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + if (more_data) + select_poke(sock->manager, sock->fd, SELECT_POKE_WRITE); + + UNLOCK(&sock->lock); +} + +static void +internal_fdwatch_read(isc_task_t *me, isc_event_t *ev) { + isc__socket_t *sock; + int more_data; + + INSIST(ev->ev_type == ISC_SOCKEVENT_INTR); + + /* + * Find out what socket this is and lock it. + */ + sock = (isc__socket_t *)ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + socket_log(sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALRECV, + "internal_fdwatch_read: task %p got event %p", me, ev); + + INSIST(sock->pending_recv == 1); + + UNLOCK(&sock->lock); + more_data = (sock->fdwatchcb)(me, (isc_socket_t *)sock, + sock->fdwatcharg, ISC_SOCKFDWATCH_READ); + LOCK(&sock->lock); + + sock->pending_recv = 0; + + INSIST(sock->references > 0); + sock->references--; /* the internal event is done with this socket */ + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + if (more_data) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + + UNLOCK(&sock->lock); +} + +/* + * Process read/writes on each fd here. Avoid locking + * and unlocking twice if both reads and writes are possible. + */ +static void +process_fd(isc__socketmgr_t *manager, int fd, isc_boolean_t readable, + isc_boolean_t writeable) +{ + isc__socket_t *sock; + isc_boolean_t unlock_sock; + isc_boolean_t unwatch_read = ISC_FALSE, unwatch_write = ISC_FALSE; + int lockid = FDLOCK_ID(fd); + + /* + * If the socket is going to be closed, don't do more I/O. + */ + LOCK(&manager->fdlock[lockid]); + if (manager->fdstate[fd] == CLOSE_PENDING) { + UNLOCK(&manager->fdlock[lockid]); + + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + return; + } + + sock = manager->fds[fd]; + unlock_sock = ISC_FALSE; + if (readable) { + if (sock == NULL) { + unwatch_read = ISC_TRUE; + goto check_write; + } + unlock_sock = ISC_TRUE; + LOCK(&sock->lock); + if (!SOCK_DEAD(sock)) { + if (sock->listener) + dispatch_accept(sock); + else + dispatch_recv(sock); + } + unwatch_read = ISC_TRUE; + } +check_write: + if (writeable) { + if (sock == NULL) { + unwatch_write = ISC_TRUE; + goto unlock_fd; + } + if (!unlock_sock) { + unlock_sock = ISC_TRUE; + LOCK(&sock->lock); + } + if (!SOCK_DEAD(sock)) { + if (sock->connecting) + dispatch_connect(sock); + else + dispatch_send(sock); + } + unwatch_write = ISC_TRUE; + } + if (unlock_sock) + UNLOCK(&sock->lock); + + unlock_fd: + UNLOCK(&manager->fdlock[lockid]); + if (unwatch_read) + (void)unwatch_fd(manager, fd, SELECT_POKE_READ); + if (unwatch_write) + (void)unwatch_fd(manager, fd, SELECT_POKE_WRITE); + +} + +#ifdef USE_KQUEUE +static isc_boolean_t +process_fds(isc__socketmgr_t *manager, struct kevent *events, int nevents) { + int i; + isc_boolean_t readable, writable; + isc_boolean_t done = ISC_FALSE; +#ifdef USE_WATCHER_THREAD + isc_boolean_t have_ctlevent = ISC_FALSE; +#endif + + if (nevents == manager->nevents) { + /* + * This is not an error, but something unexpected. If this + * happens, it may indicate the need for increasing + * ISC_SOCKET_MAXEVENTS. + */ + manager_log(manager, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_INFO, + "maximum number of FD events (%d) received", + nevents); + } + + for (i = 0; i < nevents; i++) { + REQUIRE(events[i].ident < manager->maxsocks); +#ifdef USE_WATCHER_THREAD + if (events[i].ident == (uintptr_t)manager->pipe_fds[0]) { + have_ctlevent = ISC_TRUE; + continue; + } +#endif + readable = ISC_TF(events[i].filter == EVFILT_READ); + writable = ISC_TF(events[i].filter == EVFILT_WRITE); + process_fd(manager, events[i].ident, readable, writable); + } + +#ifdef USE_WATCHER_THREAD + if (have_ctlevent) + done = process_ctlfd(manager); +#endif + + return (done); +} +#elif defined(USE_EPOLL) +static isc_boolean_t +process_fds(isc__socketmgr_t *manager, struct epoll_event *events, int nevents) +{ + int i; + isc_boolean_t done = ISC_FALSE; +#ifdef USE_WATCHER_THREAD + isc_boolean_t have_ctlevent = ISC_FALSE; +#endif + + if (nevents == manager->nevents) { + manager_log(manager, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_INFO, + "maximum number of FD events (%d) received", + nevents); + } + + for (i = 0; i < nevents; i++) { + REQUIRE(events[i].data.fd < (int)manager->maxsocks); +#ifdef USE_WATCHER_THREAD + if (events[i].data.fd == manager->pipe_fds[0]) { + have_ctlevent = ISC_TRUE; + continue; + } +#endif + if ((events[i].events & EPOLLERR) != 0 || + (events[i].events & EPOLLHUP) != 0) { + /* + * epoll does not set IN/OUT bits on an erroneous + * condition, so we need to try both anyway. This is a + * bit inefficient, but should be okay for such rare + * events. Note also that the read or write attempt + * won't block because we use non-blocking sockets. + */ + events[i].events |= (EPOLLIN | EPOLLOUT); + } + process_fd(manager, events[i].data.fd, + (events[i].events & EPOLLIN) != 0, + (events[i].events & EPOLLOUT) != 0); + } + +#ifdef USE_WATCHER_THREAD + if (have_ctlevent) + done = process_ctlfd(manager); +#endif + + return (done); +} +#elif defined(USE_DEVPOLL) +static isc_boolean_t +process_fds(isc__socketmgr_t *manager, struct pollfd *events, int nevents) { + int i; + isc_boolean_t done = ISC_FALSE; +#ifdef USE_WATCHER_THREAD + isc_boolean_t have_ctlevent = ISC_FALSE; +#endif + + if (nevents == manager->nevents) { + manager_log(manager, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_INFO, + "maximum number of FD events (%d) received", + nevents); + } + + for (i = 0; i < nevents; i++) { + REQUIRE(events[i].fd < (int)manager->maxsocks); +#ifdef USE_WATCHER_THREAD + if (events[i].fd == manager->pipe_fds[0]) { + have_ctlevent = ISC_TRUE; + continue; + } +#endif + process_fd(manager, events[i].fd, + (events[i].events & POLLIN) != 0, + (events[i].events & POLLOUT) != 0); + } + +#ifdef USE_WATCHER_THREAD + if (have_ctlevent) + done = process_ctlfd(manager); +#endif + + return (done); +} +#elif defined(USE_SELECT) +static void +process_fds(isc__socketmgr_t *manager, int maxfd, fd_set *readfds, + fd_set *writefds) +{ + int i; + + REQUIRE(maxfd <= (int)manager->maxsocks); + + for (i = 0; i < maxfd; i++) { +#ifdef USE_WATCHER_THREAD + if (i == manager->pipe_fds[0] || i == manager->pipe_fds[1]) + continue; +#endif /* USE_WATCHER_THREAD */ + process_fd(manager, i, FD_ISSET(i, readfds), + FD_ISSET(i, writefds)); + } +} +#endif + +#ifdef USE_WATCHER_THREAD +static isc_boolean_t +process_ctlfd(isc__socketmgr_t *manager) { + int msg, fd; + + for (;;) { + select_readmsg(manager, &fd, &msg); + + manager_log(manager, IOEVENT, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_WATCHERMSG, + "watcher got message %d " + "for socket %d"), msg, fd); + + /* + * Nothing to read? + */ + if (msg == SELECT_POKE_NOTHING) + break; + + /* + * Handle shutdown message. We really should + * jump out of this loop right away, but + * it doesn't matter if we have to do a little + * more work first. + */ + if (msg == SELECT_POKE_SHUTDOWN) + return (ISC_TRUE); + + /* + * This is a wakeup on a socket. Look + * at the event queue for both read and write, + * and decide if we need to watch on it now + * or not. + */ + wakeup_socket(manager, fd, msg); + } + + return (ISC_FALSE); +} + +/* + * This is the thread that will loop forever, always in a select or poll + * call. + * + * When select returns something to do, track down what thread gets to do + * this I/O and post the event to it. + */ +static isc_threadresult_t +watcher(void *uap) { + isc__socketmgr_t *manager = uap; + isc_boolean_t done; + int cc; +#ifdef USE_KQUEUE + const char *fnname = "kevent()"; +#elif defined (USE_EPOLL) + const char *fnname = "epoll_wait()"; +#elif defined(USE_DEVPOLL) + const char *fnname = "ioctl(DP_POLL)"; + struct dvpoll dvp; +#elif defined (USE_SELECT) + const char *fnname = "select()"; + int maxfd; + int ctlfd; +#endif + char strbuf[ISC_STRERRORSIZE]; +#ifdef ISC_SOCKET_USE_POLLWATCH + pollstate_t pollstate = poll_idle; +#endif + +#if defined (USE_SELECT) + /* + * Get the control fd here. This will never change. + */ + ctlfd = manager->pipe_fds[0]; +#endif + done = ISC_FALSE; + while (!done) { + do { +#ifdef USE_KQUEUE + cc = kevent(manager->kqueue_fd, NULL, 0, + manager->events, manager->nevents, NULL); +#elif defined(USE_EPOLL) + cc = epoll_wait(manager->epoll_fd, manager->events, + manager->nevents, -1); +#elif defined(USE_DEVPOLL) + dvp.dp_fds = manager->events; + dvp.dp_nfds = manager->nevents; +#ifndef ISC_SOCKET_USE_POLLWATCH + dvp.dp_timeout = -1; +#else + if (pollstate == poll_idle) + dvp.dp_timeout = -1; + else + dvp.dp_timeout = ISC_SOCKET_POLLWATCH_TIMEOUT; +#endif /* ISC_SOCKET_USE_POLLWATCH */ + cc = ioctl(manager->devpoll_fd, DP_POLL, &dvp); +#elif defined(USE_SELECT) + LOCK(&manager->lock); + memcpy(manager->read_fds_copy, manager->read_fds, + manager->fd_bufsize); + memcpy(manager->write_fds_copy, manager->write_fds, + manager->fd_bufsize); + maxfd = manager->maxfd + 1; + UNLOCK(&manager->lock); + + cc = select(maxfd, manager->read_fds_copy, + manager->write_fds_copy, NULL, NULL); +#endif /* USE_KQUEUE */ + + if (cc < 0 && !SOFT_ERROR(errno)) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + "%s %s: %s", fnname, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), strbuf); + } + +#if defined(USE_DEVPOLL) && defined(ISC_SOCKET_USE_POLLWATCH) + if (cc == 0) { + if (pollstate == poll_active) + pollstate = poll_checking; + else if (pollstate == poll_checking) + pollstate = poll_idle; + } else if (cc > 0) { + if (pollstate == poll_checking) { + /* + * XXX: We'd like to use a more + * verbose log level as it's actually an + * unexpected event, but the kernel bug + * reportedly happens pretty frequently + * (and it can also be a false positive) + * so it would be just too noisy. + */ + manager_log(manager, + ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_DEBUG(1), + "unexpected POLL timeout"); + } + pollstate = poll_active; + } +#endif + } while (cc < 0); + +#if defined(USE_KQUEUE) || defined (USE_EPOLL) || defined (USE_DEVPOLL) + done = process_fds(manager, manager->events, cc); +#elif defined(USE_SELECT) + process_fds(manager, maxfd, manager->read_fds_copy, + manager->write_fds_copy); + + /* + * Process reads on internal, control fd. + */ + if (FD_ISSET(ctlfd, manager->read_fds_copy)) + done = process_ctlfd(manager); +#endif + } + + manager_log(manager, TRACE, "%s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_EXITING, "watcher exiting")); + + return ((isc_threadresult_t)0); +} +#endif /* USE_WATCHER_THREAD */ + +#ifdef BIND9 +ISC_SOCKETFUNC_SCOPE void +isc__socketmgr_setreserved(isc_socketmgr_t *manager0, isc_uint32_t reserved) { + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + + REQUIRE(VALID_MANAGER(manager)); + + manager->reserved = reserved; +} + +ISC_SOCKETFUNC_SCOPE void +isc___socketmgr_maxudp(isc_socketmgr_t *manager0, int maxudp) { + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + + REQUIRE(VALID_MANAGER(manager)); + + manager->maxudp = maxudp; +} +#endif /* BIND9 */ + +/* + * Create a new socket manager. + */ + +static isc_result_t +setup_watcher(isc_mem_t *mctx, isc__socketmgr_t *manager) { + isc_result_t result; +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) + char strbuf[ISC_STRERRORSIZE]; +#endif + +#ifdef USE_KQUEUE + manager->nevents = ISC_SOCKET_MAXEVENTS; + manager->events = isc_mem_get(mctx, sizeof(struct kevent) * + manager->nevents); + if (manager->events == NULL) + return (ISC_R_NOMEMORY); + manager->kqueue_fd = kqueue(); + if (manager->kqueue_fd == -1) { + result = isc__errno2result(errno); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "kqueue %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + isc_mem_put(mctx, manager->events, + sizeof(struct kevent) * manager->nevents); + return (result); + } + +#ifdef USE_WATCHER_THREAD + result = watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + close(manager->kqueue_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct kevent) * manager->nevents); + return (result); + } +#endif /* USE_WATCHER_THREAD */ +#elif defined(USE_EPOLL) + manager->nevents = ISC_SOCKET_MAXEVENTS; + manager->events = isc_mem_get(mctx, sizeof(struct epoll_event) * + manager->nevents); + if (manager->events == NULL) + return (ISC_R_NOMEMORY); + manager->epoll_fd = epoll_create(manager->nevents); + if (manager->epoll_fd == -1) { + result = isc__errno2result(errno); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "epoll_create %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + isc_mem_put(mctx, manager->events, + sizeof(struct epoll_event) * manager->nevents); + return (result); + } +#ifdef USE_WATCHER_THREAD + result = watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + close(manager->epoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct epoll_event) * manager->nevents); + return (result); + } +#endif /* USE_WATCHER_THREAD */ +#elif defined(USE_DEVPOLL) + /* + * XXXJT: /dev/poll seems to reject large numbers of events, + * so we should be careful about redefining ISC_SOCKET_MAXEVENTS. + */ + manager->nevents = ISC_SOCKET_MAXEVENTS; + manager->events = isc_mem_get(mctx, sizeof(struct pollfd) * + manager->nevents); + if (manager->events == NULL) + return (ISC_R_NOMEMORY); + /* + * Note: fdpollinfo should be able to support all possible FDs, so + * it must have maxsocks entries (not nevents). + */ + manager->fdpollinfo = isc_mem_get(mctx, sizeof(pollinfo_t) * + manager->maxsocks); + if (manager->fdpollinfo == NULL) { + isc_mem_put(mctx, manager->events, + sizeof(struct pollfd) * manager->nevents); + return (ISC_R_NOMEMORY); + } + memset(manager->fdpollinfo, 0, sizeof(pollinfo_t) * manager->maxsocks); + manager->devpoll_fd = open("/dev/poll", O_RDWR); + if (manager->devpoll_fd == -1) { + result = isc__errno2result(errno); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "open(/dev/poll) %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + isc_mem_put(mctx, manager->events, + sizeof(struct pollfd) * manager->nevents); + isc_mem_put(mctx, manager->fdpollinfo, + sizeof(pollinfo_t) * manager->maxsocks); + return (result); + } +#ifdef USE_WATCHER_THREAD + result = watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + close(manager->devpoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct pollfd) * manager->nevents); + isc_mem_put(mctx, manager->fdpollinfo, + sizeof(pollinfo_t) * manager->maxsocks); + return (result); + } +#endif /* USE_WATCHER_THREAD */ +#elif defined(USE_SELECT) + UNUSED(result); + +#if ISC_SOCKET_MAXSOCKETS > FD_SETSIZE + /* + * Note: this code should also cover the case of MAXSOCKETS <= + * FD_SETSIZE, but we separate the cases to avoid possible portability + * issues regarding howmany() and the actual representation of fd_set. + */ + manager->fd_bufsize = howmany(manager->maxsocks, NFDBITS) * + sizeof(fd_mask); +#else + manager->fd_bufsize = sizeof(fd_set); +#endif + + manager->read_fds = NULL; + manager->read_fds_copy = NULL; + manager->write_fds = NULL; + manager->write_fds_copy = NULL; + + manager->read_fds = isc_mem_get(mctx, manager->fd_bufsize); + if (manager->read_fds != NULL) + manager->read_fds_copy = isc_mem_get(mctx, manager->fd_bufsize); + if (manager->read_fds_copy != NULL) + manager->write_fds = isc_mem_get(mctx, manager->fd_bufsize); + if (manager->write_fds != NULL) { + manager->write_fds_copy = isc_mem_get(mctx, + manager->fd_bufsize); + } + if (manager->write_fds_copy == NULL) { + if (manager->write_fds != NULL) { + isc_mem_put(mctx, manager->write_fds, + manager->fd_bufsize); + } + if (manager->read_fds_copy != NULL) { + isc_mem_put(mctx, manager->read_fds_copy, + manager->fd_bufsize); + } + if (manager->read_fds != NULL) { + isc_mem_put(mctx, manager->read_fds, + manager->fd_bufsize); + } + return (ISC_R_NOMEMORY); + } + memset(manager->read_fds, 0, manager->fd_bufsize); + memset(manager->write_fds, 0, manager->fd_bufsize); + +#ifdef USE_WATCHER_THREAD + (void)watch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + manager->maxfd = manager->pipe_fds[0]; +#else /* USE_WATCHER_THREAD */ + manager->maxfd = 0; +#endif /* USE_WATCHER_THREAD */ +#endif /* USE_KQUEUE */ + + return (ISC_R_SUCCESS); +} + +static void +cleanup_watcher(isc_mem_t *mctx, isc__socketmgr_t *manager) { +#ifdef USE_WATCHER_THREAD + isc_result_t result; + + result = unwatch_fd(manager, manager->pipe_fds[0], SELECT_POKE_READ); + if (result != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "epoll_ctl(DEL) %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + } +#endif /* USE_WATCHER_THREAD */ + +#ifdef USE_KQUEUE + close(manager->kqueue_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct kevent) * manager->nevents); +#elif defined(USE_EPOLL) + close(manager->epoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct epoll_event) * manager->nevents); +#elif defined(USE_DEVPOLL) + close(manager->devpoll_fd); + isc_mem_put(mctx, manager->events, + sizeof(struct pollfd) * manager->nevents); + isc_mem_put(mctx, manager->fdpollinfo, + sizeof(pollinfo_t) * manager->maxsocks); +#elif defined(USE_SELECT) + if (manager->read_fds != NULL) + isc_mem_put(mctx, manager->read_fds, manager->fd_bufsize); + if (manager->read_fds_copy != NULL) + isc_mem_put(mctx, manager->read_fds_copy, manager->fd_bufsize); + if (manager->write_fds != NULL) + isc_mem_put(mctx, manager->write_fds, manager->fd_bufsize); + if (manager->write_fds_copy != NULL) + isc_mem_put(mctx, manager->write_fds_copy, manager->fd_bufsize); +#endif /* USE_KQUEUE */ +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socketmgr_create(isc_mem_t *mctx, isc_socketmgr_t **managerp) { + return (isc__socketmgr_create2(mctx, managerp, 0)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socketmgr_create2(isc_mem_t *mctx, isc_socketmgr_t **managerp, + unsigned int maxsocks) +{ + int i; + isc__socketmgr_t *manager; +#ifdef USE_WATCHER_THREAD + char strbuf[ISC_STRERRORSIZE]; +#endif + isc_result_t result; + + REQUIRE(managerp != NULL && *managerp == NULL); + +#ifdef USE_SHARED_MANAGER + if (socketmgr != NULL) { + /* Don't allow maxsocks to be updated */ + if (maxsocks > 0 && socketmgr->maxsocks != maxsocks) + return (ISC_R_EXISTS); + + socketmgr->refs++; + *managerp = (isc_socketmgr_t *)socketmgr; + return (ISC_R_SUCCESS); + } +#endif /* USE_SHARED_MANAGER */ + + if (maxsocks == 0) + maxsocks = ISC_SOCKET_MAXSOCKETS; + + manager = isc_mem_get(mctx, sizeof(*manager)); + if (manager == NULL) + return (ISC_R_NOMEMORY); + + /* zero-clear so that necessary cleanup on failure will be easy */ + memset(manager, 0, sizeof(*manager)); + manager->maxsocks = maxsocks; + manager->reserved = 0; + manager->maxudp = 0; + manager->fds = isc_mem_get(mctx, + manager->maxsocks * sizeof(isc__socket_t *)); + if (manager->fds == NULL) { + result = ISC_R_NOMEMORY; + goto free_manager; + } + manager->fdstate = isc_mem_get(mctx, manager->maxsocks * sizeof(int)); + if (manager->fdstate == NULL) { + result = ISC_R_NOMEMORY; + goto free_manager; + } + manager->stats = NULL; + + manager->common.methods = &socketmgrmethods; + manager->common.magic = ISCAPI_SOCKETMGR_MAGIC; + manager->common.impmagic = SOCKET_MANAGER_MAGIC; + manager->mctx = NULL; + memset(manager->fds, 0, manager->maxsocks * sizeof(isc_socket_t *)); + ISC_LIST_INIT(manager->socklist); + result = isc_mutex_init(&manager->lock); + if (result != ISC_R_SUCCESS) + goto free_manager; + manager->fdlock = isc_mem_get(mctx, FDLOCK_COUNT * sizeof(isc_mutex_t)); + if (manager->fdlock == NULL) { + result = ISC_R_NOMEMORY; + goto cleanup_lock; + } + for (i = 0; i < FDLOCK_COUNT; i++) { + result = isc_mutex_init(&manager->fdlock[i]); + if (result != ISC_R_SUCCESS) { + while (--i >= 0) + DESTROYLOCK(&manager->fdlock[i]); + isc_mem_put(mctx, manager->fdlock, + FDLOCK_COUNT * sizeof(isc_mutex_t)); + manager->fdlock = NULL; + goto cleanup_lock; + } + } + +#ifdef USE_WATCHER_THREAD + if (isc_condition_init(&manager->shutdown_ok) != ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + result = ISC_R_UNEXPECTED; + goto cleanup_lock; + } + + /* + * Create the special fds that will be used to wake up the + * select/poll loop when something internal needs to be done. + */ + if (pipe(manager->pipe_fds) != 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "pipe() %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + result = ISC_R_UNEXPECTED; + goto cleanup_condition; + } + + RUNTIME_CHECK(make_nonblock(manager->pipe_fds[0]) == ISC_R_SUCCESS); +#if 0 + RUNTIME_CHECK(make_nonblock(manager->pipe_fds[1]) == ISC_R_SUCCESS); +#endif +#endif /* USE_WATCHER_THREAD */ + +#ifdef USE_SHARED_MANAGER + manager->refs = 1; +#endif /* USE_SHARED_MANAGER */ + + /* + * Set up initial state for the select loop + */ + result = setup_watcher(mctx, manager); + if (result != ISC_R_SUCCESS) + goto cleanup; + memset(manager->fdstate, 0, manager->maxsocks * sizeof(int)); +#ifdef USE_WATCHER_THREAD + /* + * Start up the select/poll thread. + */ + if (isc_thread_create(watcher, manager, &manager->watcher) != + ISC_R_SUCCESS) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_create() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + cleanup_watcher(mctx, manager); + result = ISC_R_UNEXPECTED; + goto cleanup; + } +#endif /* USE_WATCHER_THREAD */ + isc_mem_attach(mctx, &manager->mctx); + +#ifdef USE_SHARED_MANAGER + socketmgr = manager; +#endif /* USE_SHARED_MANAGER */ + *managerp = (isc_socketmgr_t *)manager; + + return (ISC_R_SUCCESS); + +cleanup: +#ifdef USE_WATCHER_THREAD + (void)close(manager->pipe_fds[0]); + (void)close(manager->pipe_fds[1]); +#endif /* USE_WATCHER_THREAD */ + +#ifdef USE_WATCHER_THREAD +cleanup_condition: + (void)isc_condition_destroy(&manager->shutdown_ok); +#endif /* USE_WATCHER_THREAD */ + + +cleanup_lock: + if (manager->fdlock != NULL) { + for (i = 0; i < FDLOCK_COUNT; i++) + DESTROYLOCK(&manager->fdlock[i]); + } + DESTROYLOCK(&manager->lock); + +free_manager: + if (manager->fdlock != NULL) { + isc_mem_put(mctx, manager->fdlock, + FDLOCK_COUNT * sizeof(isc_mutex_t)); + } + if (manager->fdstate != NULL) { + isc_mem_put(mctx, manager->fdstate, + manager->maxsocks * sizeof(int)); + } + if (manager->fds != NULL) { + isc_mem_put(mctx, manager->fds, + manager->maxsocks * sizeof(isc_socket_t *)); + } + isc_mem_put(mctx, manager, sizeof(*manager)); + + return (result); +} + +#ifdef BIND9 +isc_result_t +isc__socketmgr_getmaxsockets(isc_socketmgr_t *manager0, unsigned int *nsockp) { + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(nsockp != NULL); + + *nsockp = manager->maxsocks; + + return (ISC_R_SUCCESS); +} + +void +isc__socketmgr_setstats(isc_socketmgr_t *manager0, isc_stats_t *stats) { + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(ISC_LIST_EMPTY(manager->socklist)); + REQUIRE(manager->stats == NULL); + REQUIRE(isc_stats_ncounters(stats) == isc_sockstatscounter_max); + + isc_stats_attach(stats, &manager->stats); +} +#endif + +ISC_SOCKETFUNC_SCOPE void +isc__socketmgr_destroy(isc_socketmgr_t **managerp) { + isc__socketmgr_t *manager; + int i; + isc_mem_t *mctx; + + /* + * Destroy a socket manager. + */ + + REQUIRE(managerp != NULL); + manager = (isc__socketmgr_t *)*managerp; + REQUIRE(VALID_MANAGER(manager)); + +#ifdef USE_SHARED_MANAGER + manager->refs--; + if (manager->refs > 0) { + *managerp = NULL; + return; + } + socketmgr = NULL; +#endif /* USE_SHARED_MANAGER */ + + LOCK(&manager->lock); + + /* + * Wait for all sockets to be destroyed. + */ + while (!ISC_LIST_EMPTY(manager->socklist)) { +#ifdef USE_WATCHER_THREAD + manager_log(manager, CREATION, "%s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_SOCKETSREMAIN, + "sockets exist")); + WAIT(&manager->shutdown_ok, &manager->lock); +#else /* USE_WATCHER_THREAD */ + UNLOCK(&manager->lock); + isc__taskmgr_dispatch(NULL); + LOCK(&manager->lock); +#endif /* USE_WATCHER_THREAD */ + } + + UNLOCK(&manager->lock); + + /* + * Here, poke our select/poll thread. Do this by closing the write + * half of the pipe, which will send EOF to the read half. + * This is currently a no-op in the non-threaded case. + */ + select_poke(manager, 0, SELECT_POKE_SHUTDOWN); + +#ifdef USE_WATCHER_THREAD + /* + * Wait for thread to exit. + */ + if (isc_thread_join(manager->watcher, NULL) != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_join() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); +#endif /* USE_WATCHER_THREAD */ + + /* + * Clean up. + */ + cleanup_watcher(manager->mctx, manager); + +#ifdef USE_WATCHER_THREAD + (void)close(manager->pipe_fds[0]); + (void)close(manager->pipe_fds[1]); + (void)isc_condition_destroy(&manager->shutdown_ok); +#endif /* USE_WATCHER_THREAD */ + + for (i = 0; i < (int)manager->maxsocks; i++) + if (manager->fdstate[i] == CLOSE_PENDING) /* no need to lock */ + (void)close(i); + + isc_mem_put(manager->mctx, manager->fds, + manager->maxsocks * sizeof(isc__socket_t *)); + isc_mem_put(manager->mctx, manager->fdstate, + manager->maxsocks * sizeof(int)); + + if (manager->stats != NULL) + isc_stats_detach(&manager->stats); + + if (manager->fdlock != NULL) { + for (i = 0; i < FDLOCK_COUNT; i++) + DESTROYLOCK(&manager->fdlock[i]); + isc_mem_put(manager->mctx, manager->fdlock, + FDLOCK_COUNT * sizeof(isc_mutex_t)); + } + DESTROYLOCK(&manager->lock); + manager->common.magic = 0; + manager->common.impmagic = 0; + mctx= manager->mctx; + isc_mem_put(mctx, manager, sizeof(*manager)); + + isc_mem_detach(&mctx); + + *managerp = NULL; + +#ifdef USE_SHARED_MANAGER + socketmgr = NULL; +#endif +} + +static isc_result_t +socket_recv(isc__socket_t *sock, isc_socketevent_t *dev, isc_task_t *task, + unsigned int flags) +{ + int io_state; + isc_boolean_t have_lock = ISC_FALSE; + isc_task_t *ntask = NULL; + isc_result_t result = ISC_R_SUCCESS; + + dev->ev_sender = task; + + if (sock->type == isc_sockettype_udp) { + io_state = doio_recv(sock, dev); + } else { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + + if (ISC_LIST_EMPTY(sock->recv_list)) + io_state = doio_recv(sock, dev); + else + io_state = DOIO_SOFT; + } + + switch (io_state) { + case DOIO_SOFT: + /* + * We couldn't read all or part of the request right now, so + * queue it. + * + * Attach to socket and to task + */ + isc_task_attach(task, &ntask); + dev->attributes |= ISC_SOCKEVENTATTR_ATTACHED; + + if (!have_lock) { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + } + + /* + * Enqueue the request. If the socket was previously not being + * watched, poke the watcher to start paying attention to it. + */ + if (ISC_LIST_EMPTY(sock->recv_list) && !sock->pending_recv) + select_poke(sock->manager, sock->fd, SELECT_POKE_READ); + ISC_LIST_ENQUEUE(sock->recv_list, dev, ev_link); + + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "socket_recv: event %p -> task %p", + dev, ntask); + + if ((flags & ISC_SOCKFLAG_IMMEDIATE) != 0) + result = ISC_R_INPROGRESS; + break; + + case DOIO_EOF: + dev->result = ISC_R_EOF; + /* fallthrough */ + + case DOIO_HARD: + case DOIO_SUCCESS: + if ((flags & ISC_SOCKFLAG_IMMEDIATE) == 0) + send_recvdone_event(sock, &dev); + break; + } + + if (have_lock) + UNLOCK(&sock->lock); + + return (result); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_recvv(isc_socket_t *sock0, isc_bufferlist_t *buflist, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_socketevent_t *dev; + isc__socketmgr_t *manager; + unsigned int iocount; + isc_buffer_t *buffer; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(buflist != NULL); + REQUIRE(!ISC_LIST_EMPTY(*buflist)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + iocount = isc_bufferlist_availablecount(buflist); + REQUIRE(iocount > 0); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_RECVDONE, action, arg); + if (dev == NULL) + return (ISC_R_NOMEMORY); + + /* + * UDP sockets are always partial read + */ + if (sock->type == isc_sockettype_udp) + dev->minimum = 1; + else { + if (minimum == 0) + dev->minimum = iocount; + else + dev->minimum = minimum; + } + + /* + * Move each buffer from the passed in list to our internal one. + */ + buffer = ISC_LIST_HEAD(*buflist); + while (buffer != NULL) { + ISC_LIST_DEQUEUE(*buflist, buffer, link); + ISC_LIST_ENQUEUE(dev->bufferlist, buffer, link); + buffer = ISC_LIST_HEAD(*buflist); + } + + return (socket_recv(sock, dev, task, 0)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_recv(isc_socket_t *sock0, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_socketevent_t *dev; + isc__socketmgr_t *manager; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_RECVDONE, action, arg); + if (dev == NULL) + return (ISC_R_NOMEMORY); + + return (isc__socket_recv2(sock0, region, minimum, task, dev, 0)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_recv2(isc_socket_t *sock0, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_socketevent_t *event, unsigned int flags) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + + event->ev_sender = sock; + event->result = ISC_R_UNSET; + ISC_LIST_INIT(event->bufferlist); + event->region = *region; + event->n = 0; + event->offset = 0; + event->attributes = 0; + + /* + * UDP sockets are always partial read. + */ + if (sock->type == isc_sockettype_udp) + event->minimum = 1; + else { + if (minimum == 0) + event->minimum = region->length; + else + event->minimum = minimum; + } + + return (socket_recv(sock, event, task, flags)); +} + +static isc_result_t +socket_send(isc__socket_t *sock, isc_socketevent_t *dev, isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + unsigned int flags) +{ + int io_state; + isc_boolean_t have_lock = ISC_FALSE; + isc_task_t *ntask = NULL; + isc_result_t result = ISC_R_SUCCESS; + + dev->ev_sender = task; + + set_dev_address(address, sock, dev); + if (pktinfo != NULL) { + dev->attributes |= ISC_SOCKEVENTATTR_PKTINFO; + dev->pktinfo = *pktinfo; + + if (!isc_sockaddr_issitelocal(&dev->address) && + !isc_sockaddr_islinklocal(&dev->address)) { + socket_log(sock, NULL, TRACE, isc_msgcat, + ISC_MSGSET_SOCKET, ISC_MSG_PKTINFOPROVIDED, + "pktinfo structure provided, ifindex %u " + "(set to 0)", pktinfo->ipi6_ifindex); + + /* + * Set the pktinfo index to 0 here, to let the + * kernel decide what interface it should send on. + */ + dev->pktinfo.ipi6_ifindex = 0; + } + } + + if (sock->type == isc_sockettype_udp) + io_state = doio_send(sock, dev); + else { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + + if (ISC_LIST_EMPTY(sock->send_list)) + io_state = doio_send(sock, dev); + else + io_state = DOIO_SOFT; + } + + switch (io_state) { + case DOIO_SOFT: + /* + * We couldn't send all or part of the request right now, so + * queue it unless ISC_SOCKFLAG_NORETRY is set. + */ + if ((flags & ISC_SOCKFLAG_NORETRY) == 0) { + isc_task_attach(task, &ntask); + dev->attributes |= ISC_SOCKEVENTATTR_ATTACHED; + + if (!have_lock) { + LOCK(&sock->lock); + have_lock = ISC_TRUE; + } + + /* + * Enqueue the request. If the socket was previously + * not being watched, poke the watcher to start + * paying attention to it. + */ + if (ISC_LIST_EMPTY(sock->send_list) && + !sock->pending_send) + select_poke(sock->manager, sock->fd, + SELECT_POKE_WRITE); + ISC_LIST_ENQUEUE(sock->send_list, dev, ev_link); + + socket_log(sock, NULL, EVENT, NULL, 0, 0, + "socket_send: event %p -> task %p", + dev, ntask); + + if ((flags & ISC_SOCKFLAG_IMMEDIATE) != 0) + result = ISC_R_INPROGRESS; + break; + } + + case DOIO_HARD: + case DOIO_SUCCESS: + if ((flags & ISC_SOCKFLAG_IMMEDIATE) == 0) + send_senddone_event(sock, &dev); + break; + } + + if (have_lock) + UNLOCK(&sock->lock); + + return (result); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_send(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + /* + * REQUIRE() checking is performed in isc_socket_sendto(). + */ + return (isc__socket_sendto(sock, region, task, action, arg, NULL, + NULL)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendto(isc_socket_t *sock0, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_socketevent_t *dev; + isc__socketmgr_t *manager; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(region != NULL); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_SENDDONE, action, arg); + if (dev == NULL) + return (ISC_R_NOMEMORY); + + dev->region = *region; + + return (socket_send(sock, dev, task, address, pktinfo, 0)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendv(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + return (isc__socket_sendtov(sock, buflist, task, action, arg, NULL, + NULL)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendtov(isc_socket_t *sock0, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_socketevent_t *dev; + isc__socketmgr_t *manager; + unsigned int iocount; + isc_buffer_t *buffer; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(buflist != NULL); + REQUIRE(!ISC_LIST_EMPTY(*buflist)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + iocount = isc_bufferlist_usedcount(buflist); + REQUIRE(iocount > 0); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_SENDDONE, action, arg); + if (dev == NULL) + return (ISC_R_NOMEMORY); + + /* + * Move each buffer from the passed in list to our internal one. + */ + buffer = ISC_LIST_HEAD(*buflist); + while (buffer != NULL) { + ISC_LIST_DEQUEUE(*buflist, buffer, link); + ISC_LIST_ENQUEUE(dev->bufferlist, buffer, link); + buffer = ISC_LIST_HEAD(*buflist); + } + + return (socket_send(sock, dev, task, address, pktinfo, 0)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_sendto2(isc_socket_t *sock0, isc_region_t *region, + isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + isc_socketevent_t *event, unsigned int flags) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE((flags & ~(ISC_SOCKFLAG_IMMEDIATE|ISC_SOCKFLAG_NORETRY)) == 0); + if ((flags & ISC_SOCKFLAG_NORETRY) != 0) + REQUIRE(sock->type == isc_sockettype_udp); + event->ev_sender = sock; + event->result = ISC_R_UNSET; + ISC_LIST_INIT(event->bufferlist); + event->region = *region; + event->n = 0; + event->offset = 0; + event->attributes = 0; + + return (socket_send(sock, event, task, address, pktinfo, flags)); +} + +ISC_SOCKETFUNC_SCOPE void +isc__socket_cleanunix(isc_sockaddr_t *sockaddr, isc_boolean_t active) { +#ifdef ISC_PLATFORM_HAVESYSUNH + int s; + struct stat sb; + char strbuf[ISC_STRERRORSIZE]; + + if (sockaddr->type.sa.sa_family != AF_UNIX) + return; + +#ifndef S_ISSOCK +#if defined(S_IFMT) && defined(S_IFSOCK) +#define S_ISSOCK(mode) ((mode & S_IFMT)==S_IFSOCK) +#elif defined(_S_IFMT) && defined(S_IFSOCK) +#define S_ISSOCK(mode) ((mode & _S_IFMT)==S_IFSOCK) +#endif +#endif + +#ifndef S_ISFIFO +#if defined(S_IFMT) && defined(S_IFIFO) +#define S_ISFIFO(mode) ((mode & S_IFMT)==S_IFIFO) +#elif defined(_S_IFMT) && defined(S_IFIFO) +#define S_ISFIFO(mode) ((mode & _S_IFMT)==S_IFIFO) +#endif +#endif + +#if !defined(S_ISFIFO) && !defined(S_ISSOCK) +#error You need to define S_ISFIFO and S_ISSOCK as appropriate for your platform. See . +#endif + +#ifndef S_ISFIFO +#define S_ISFIFO(mode) 0 +#endif + +#ifndef S_ISSOCK +#define S_ISSOCK(mode) 0 +#endif + + if (active) { + if (stat(sockaddr->type.sunix.sun_path, &sb) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_cleanunix: stat(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + return; + } + if (!(S_ISSOCK(sb.st_mode) || S_ISFIFO(sb.st_mode))) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_cleanunix: %s: not a socket", + sockaddr->type.sunix.sun_path); + return; + } + if (unlink(sockaddr->type.sunix.sun_path) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_cleanunix: unlink(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + } + return; + } + + s = socket(AF_UNIX, SOCK_STREAM, 0); + if (s < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: socket(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + return; + } + + if (stat(sockaddr->type.sunix.sun_path, &sb) < 0) { + switch (errno) { + case ENOENT: /* We exited cleanly last time */ + break; + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: stat(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + break; + } + goto cleanup; + } + + if (!(S_ISSOCK(sb.st_mode) || S_ISFIFO(sb.st_mode))) { + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: %s: not a socket", + sockaddr->type.sunix.sun_path); + goto cleanup; + } + + if (connect(s, (struct sockaddr *)&sockaddr->type.sunix, + sizeof(sockaddr->type.sunix)) < 0) { + switch (errno) { + case ECONNREFUSED: + case ECONNRESET: + if (unlink(sockaddr->type.sunix.sun_path) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, + ISC_LOG_WARNING, + "isc_socket_cleanunix: " + "unlink(%s): %s", + sockaddr->type.sunix.sun_path, + strbuf); + } + break; + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_WARNING, + "isc_socket_cleanunix: connect(%s): %s", + sockaddr->type.sunix.sun_path, strbuf); + break; + } + } + cleanup: + close(s); +#else + UNUSED(sockaddr); + UNUSED(active); +#endif +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_permunix(isc_sockaddr_t *sockaddr, isc_uint32_t perm, + isc_uint32_t owner, isc_uint32_t group) +{ +#ifdef ISC_PLATFORM_HAVESYSUNH + isc_result_t result = ISC_R_SUCCESS; + char strbuf[ISC_STRERRORSIZE]; + char path[sizeof(sockaddr->type.sunix.sun_path)]; +#ifdef NEED_SECURE_DIRECTORY + char *slash; +#endif + + REQUIRE(sockaddr->type.sa.sa_family == AF_UNIX); + INSIST(strlen(sockaddr->type.sunix.sun_path) < sizeof(path)); + strcpy(path, sockaddr->type.sunix.sun_path); + +#ifdef NEED_SECURE_DIRECTORY + slash = strrchr(path, '/'); + if (slash != NULL) { + if (slash != path) + *slash = '\0'; + else + strcpy(path, "/"); + } else + strcpy(path, "."); +#endif + + if (chmod(path, perm) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_permunix: chmod(%s, %d): %s", + path, perm, strbuf); + result = ISC_R_FAILURE; + } + if (chown(path, owner, group) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_log_write(isc_lctx, ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + "isc_socket_permunix: chown(%s, %d, %d): %s", + path, owner, group, + strbuf); + result = ISC_R_FAILURE; + } + return (result); +#else + UNUSED(sockaddr); + UNUSED(perm); + UNUSED(owner); + UNUSED(group); + return (ISC_R_NOTIMPLEMENTED); +#endif +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_bind(isc_socket_t *sock0, isc_sockaddr_t *sockaddr, + unsigned int options) { + isc__socket_t *sock = (isc__socket_t *)sock0; + char strbuf[ISC_STRERRORSIZE]; + int on = 1; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + INSIST(!sock->bound); + INSIST(!sock->dupped); + + if (sock->pf != sockaddr->type.sa.sa_family) { + UNLOCK(&sock->lock); + return (ISC_R_FAMILYMISMATCH); + } + + /* + * Only set SO_REUSEADDR when we want a specific port. + */ +#ifdef AF_UNIX + if (sock->pf == AF_UNIX) + goto bind_socket; +#endif + if ((options & ISC_SOCKET_REUSEADDRESS) != 0 && + isc_sockaddr_getport(sockaddr) != (in_port_t)0 && + setsockopt(sock->fd, SOL_SOCKET, SO_REUSEADDR, (void *)&on, + sizeof(on)) < 0) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d) %s", sock->fd, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + /* Press on... */ + } +#ifdef AF_UNIX + bind_socket: +#endif + if (bind(sock->fd, &sockaddr->type.sa, sockaddr->length) < 0) { + inc_stats(sock->manager->stats, + sock->statsindex[STATID_BINDFAIL]); + + UNLOCK(&sock->lock); + switch (errno) { + case EACCES: + return (ISC_R_NOPERM); + case EADDRNOTAVAIL: + return (ISC_R_ADDRNOTAVAIL); + case EADDRINUSE: + return (ISC_R_ADDRINUSE); + case EINVAL: + return (ISC_R_BOUND); + default: + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "bind: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } + } + + socket_log(sock, sockaddr, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_BOUND, "bound"); + sock->bound = 1; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +/* + * Enable this only for specific OS versions, and only when they have repaired + * their problems with it. Until then, this is is broken and needs to be + * diabled by default. See RT22589 for details. + */ +#undef ENABLE_ACCEPTFILTER + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_filter(isc_socket_t *sock0, const char *filter) { + isc__socket_t *sock = (isc__socket_t *)sock0; +#if defined(SO_ACCEPTFILTER) && defined(ENABLE_ACCEPTFILTER) + char strbuf[ISC_STRERRORSIZE]; + struct accept_filter_arg afa; +#else + UNUSED(sock); + UNUSED(filter); +#endif + + REQUIRE(VALID_SOCKET(sock)); + +#if defined(SO_ACCEPTFILTER) && defined(ENABLE_ACCEPTFILTER) + bzero(&afa, sizeof(afa)); + strncpy(afa.af_name, filter, sizeof(afa.af_name)); + if (setsockopt(sock->fd, SOL_SOCKET, SO_ACCEPTFILTER, + &afa, sizeof(afa)) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + socket_log(sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FILTER, "setsockopt(SO_ACCEPTFILTER): %s", + strbuf); + return (ISC_R_FAILURE); + } + return (ISC_R_SUCCESS); +#else + return (ISC_R_NOTIMPLEMENTED); +#endif +} + +/* + * Set up to listen on a given socket. We do this by creating an internal + * event that will be dispatched when the socket has read activity. The + * watcher will send the internal event to the task when there is a new + * connection. + * + * Unlike in read, we don't preallocate a done event here. Every time there + * is a new connection we'll have to allocate a new one anyway, so we might + * as well keep things simple rather than having to track them. + */ +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_listen(isc_socket_t *sock0, unsigned int backlog) { + isc__socket_t *sock = (isc__socket_t *)sock0; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + REQUIRE(!sock->listener); + REQUIRE(sock->bound); + REQUIRE(sock->type == isc_sockettype_tcp || + sock->type == isc_sockettype_unix); + + if (backlog == 0) + backlog = SOMAXCONN; + + if (listen(sock->fd, (int)backlog) < 0) { + UNLOCK(&sock->lock); + isc__strerror(errno, strbuf, sizeof(strbuf)); + + UNEXPECTED_ERROR(__FILE__, __LINE__, "listen: %s", strbuf); + + return (ISC_R_UNEXPECTED); + } + + sock->listener = 1; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +/* + * This should try to do aggressive accept() XXXMLG + */ +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_accept(isc_socket_t *sock0, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_socket_newconnev_t *dev; + isc__socketmgr_t *manager; + isc_task_t *ntask = NULL; + isc__socket_t *nsock; + isc_result_t result; + isc_boolean_t do_poke = ISC_FALSE; + + REQUIRE(VALID_SOCKET(sock)); + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + LOCK(&sock->lock); + + REQUIRE(sock->listener); + + /* + * Sender field is overloaded here with the task we will be sending + * this event to. Just before the actual event is delivered the + * actual ev_sender will be touched up to be the socket. + */ + dev = (isc_socket_newconnev_t *) + isc_event_allocate(manager->mctx, task, ISC_SOCKEVENT_NEWCONN, + action, arg, sizeof(*dev)); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + ISC_LINK_INIT(dev, ev_link); + + result = allocate_socket(manager, sock->type, &nsock); + if (result != ISC_R_SUCCESS) { + isc_event_free(ISC_EVENT_PTR(&dev)); + UNLOCK(&sock->lock); + return (result); + } + + /* + * Attach to socket and to task. + */ + isc_task_attach(task, &ntask); + if (isc_task_exiting(ntask)) { + free_socket(&nsock); + isc_task_detach(&ntask); + isc_event_free(ISC_EVENT_PTR(&dev)); + UNLOCK(&sock->lock); + return (ISC_R_SHUTTINGDOWN); + } + nsock->references++; + nsock->statsindex = sock->statsindex; + + dev->ev_sender = ntask; + dev->newsocket = (isc_socket_t *)nsock; + + /* + * Poke watcher here. We still have the socket locked, so there + * is no race condition. We will keep the lock for such a short + * bit of time waking it up now or later won't matter all that much. + */ + if (ISC_LIST_EMPTY(sock->accept_list)) + do_poke = ISC_TRUE; + + ISC_LIST_ENQUEUE(sock->accept_list, dev, ev_link); + + if (do_poke) + select_poke(manager, sock->fd, SELECT_POKE_ACCEPT); + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_connect(isc_socket_t *sock0, isc_sockaddr_t *addr, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_socket_connev_t *dev; + isc_task_t *ntask = NULL; + isc__socketmgr_t *manager; + int cc; + char strbuf[ISC_STRERRORSIZE]; + char addrbuf[ISC_SOCKADDR_FORMATSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addr != NULL); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(addr != NULL); + + if (isc_sockaddr_ismulticast(addr)) + return (ISC_R_MULTICAST); + + LOCK(&sock->lock); + + REQUIRE(!sock->connecting); + + dev = (isc_socket_connev_t *)isc_event_allocate(manager->mctx, sock, + ISC_SOCKEVENT_CONNECT, + action, arg, + sizeof(*dev)); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + ISC_LINK_INIT(dev, ev_link); + + /* + * Try to do the connect right away, as there can be only one + * outstanding, and it might happen to complete. + */ + sock->peer_address = *addr; + cc = connect(sock->fd, &addr->type.sa, addr->length); + if (cc < 0) { + /* + * HP-UX "fails" to connect a UDP socket and sets errno to + * EINPROGRESS if it's non-blocking. We'd rather regard this as + * a success and let the user detect it if it's really an error + * at the time of sending a packet on the socket. + */ + if (sock->type == isc_sockettype_udp && errno == EINPROGRESS) { + cc = 0; + goto success; + } + if (SOFT_ERROR(errno) || errno == EINPROGRESS) + goto queue; + + switch (errno) { +#define ERROR_MATCH(a, b) case a: dev->result = b; goto err_exit; + ERROR_MATCH(EACCES, ISC_R_NOPERM); + ERROR_MATCH(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(EAFNOSUPPORT, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(ECONNREFUSED, ISC_R_CONNREFUSED); + ERROR_MATCH(EHOSTUNREACH, ISC_R_HOSTUNREACH); +#ifdef EHOSTDOWN + ERROR_MATCH(EHOSTDOWN, ISC_R_HOSTUNREACH); +#endif + ERROR_MATCH(ENETUNREACH, ISC_R_NETUNREACH); + ERROR_MATCH(ENOBUFS, ISC_R_NORESOURCES); + ERROR_MATCH(EPERM, ISC_R_HOSTUNREACH); + ERROR_MATCH(EPIPE, ISC_R_NOTCONNECTED); + ERROR_MATCH(ECONNRESET, ISC_R_CONNECTIONRESET); +#undef ERROR_MATCH + } + + sock->connected = 0; + + isc__strerror(errno, strbuf, sizeof(strbuf)); + isc_sockaddr_format(addr, addrbuf, sizeof(addrbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "connect(%s) %d/%s", + addrbuf, errno, strbuf); + + UNLOCK(&sock->lock); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECTFAIL]); + isc_event_free(ISC_EVENT_PTR(&dev)); + return (ISC_R_UNEXPECTED); + + err_exit: + sock->connected = 0; + isc_task_send(task, ISC_EVENT_PTR(&dev)); + + UNLOCK(&sock->lock); + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECTFAIL]); + return (ISC_R_SUCCESS); + } + + /* + * If connect completed, fire off the done event. + */ + success: + if (cc == 0) { + sock->connected = 1; + sock->bound = 1; + dev->result = ISC_R_SUCCESS; + isc_task_send(task, ISC_EVENT_PTR(&dev)); + + UNLOCK(&sock->lock); + + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECT]); + + return (ISC_R_SUCCESS); + } + + queue: + + /* + * Attach to task. + */ + isc_task_attach(task, &ntask); + + sock->connecting = 1; + + dev->ev_sender = ntask; + + /* + * Poke watcher here. We still have the socket locked, so there + * is no race condition. We will keep the lock for such a short + * bit of time waking it up now or later won't matter all that much. + */ + if (sock->connect_ev == NULL) + select_poke(manager, sock->fd, SELECT_POKE_CONNECT); + + sock->connect_ev = dev; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +/* + * Called when a socket with a pending connect() finishes. + */ +static void +internal_connect(isc_task_t *me, isc_event_t *ev) { + isc__socket_t *sock; + isc_socket_connev_t *dev; + isc_task_t *task; + int cc; + ISC_SOCKADDR_LEN_T optlen; + char strbuf[ISC_STRERRORSIZE]; + char peerbuf[ISC_SOCKADDR_FORMATSIZE]; + + UNUSED(me); + INSIST(ev->ev_type == ISC_SOCKEVENT_INTW); + + sock = ev->ev_sender; + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + /* + * When the internal event was sent the reference count was bumped + * to keep the socket around for us. Decrement the count here. + */ + INSIST(sock->references > 0); + sock->references--; + if (sock->references == 0) { + UNLOCK(&sock->lock); + destroy(&sock); + return; + } + + /* + * Has this event been canceled? + */ + dev = sock->connect_ev; + if (dev == NULL) { + INSIST(!sock->connecting); + UNLOCK(&sock->lock); + return; + } + + INSIST(sock->connecting); + sock->connecting = 0; + + /* + * Get any possible error status here. + */ + optlen = sizeof(cc); + if (getsockopt(sock->fd, SOL_SOCKET, SO_ERROR, + (void *)&cc, (void *)&optlen) < 0) + cc = errno; + else + errno = cc; + + if (errno != 0) { + /* + * If the error is EAGAIN, just re-select on this + * fd and pretend nothing strange happened. + */ + if (SOFT_ERROR(errno) || errno == EINPROGRESS) { + sock->connecting = 1; + select_poke(sock->manager, sock->fd, + SELECT_POKE_CONNECT); + UNLOCK(&sock->lock); + + return; + } + + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECTFAIL]); + + /* + * Translate other errors into ISC_R_* flavors. + */ + switch (errno) { +#define ERROR_MATCH(a, b) case a: dev->result = b; break; + ERROR_MATCH(EACCES, ISC_R_NOPERM); + ERROR_MATCH(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(EAFNOSUPPORT, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(ECONNREFUSED, ISC_R_CONNREFUSED); + ERROR_MATCH(EHOSTUNREACH, ISC_R_HOSTUNREACH); +#ifdef EHOSTDOWN + ERROR_MATCH(EHOSTDOWN, ISC_R_HOSTUNREACH); +#endif + ERROR_MATCH(ENETUNREACH, ISC_R_NETUNREACH); + ERROR_MATCH(ENOBUFS, ISC_R_NORESOURCES); + ERROR_MATCH(EPERM, ISC_R_HOSTUNREACH); + ERROR_MATCH(EPIPE, ISC_R_NOTCONNECTED); + ERROR_MATCH(ETIMEDOUT, ISC_R_TIMEDOUT); + ERROR_MATCH(ECONNRESET, ISC_R_CONNECTIONRESET); +#undef ERROR_MATCH + default: + dev->result = ISC_R_UNEXPECTED; + isc_sockaddr_format(&sock->peer_address, peerbuf, + sizeof(peerbuf)); + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_connect: connect(%s) %s", + peerbuf, strbuf); + } + } else { + inc_stats(sock->manager->stats, + sock->statsindex[STATID_CONNECT]); + dev->result = ISC_R_SUCCESS; + sock->connected = 1; + sock->bound = 1; + } + + sock->connect_ev = NULL; + + UNLOCK(&sock->lock); + + task = dev->ev_sender; + dev->ev_sender = sock; + isc_task_sendanddetach(&task, ISC_EVENT_PTR(&dev)); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_getpeername(isc_socket_t *sock0, isc_sockaddr_t *addressp) { + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_result_t result; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addressp != NULL); + + LOCK(&sock->lock); + + if (sock->connected) { + *addressp = sock->peer_address; + result = ISC_R_SUCCESS; + } else { + result = ISC_R_NOTCONNECTED; + } + + UNLOCK(&sock->lock); + + return (result); +} + +ISC_SOCKETFUNC_SCOPE isc_result_t +isc__socket_getsockname(isc_socket_t *sock0, isc_sockaddr_t *addressp) { + isc__socket_t *sock = (isc__socket_t *)sock0; + ISC_SOCKADDR_LEN_T len; + isc_result_t result; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addressp != NULL); + + LOCK(&sock->lock); + + if (!sock->bound) { + result = ISC_R_NOTBOUND; + goto out; + } + + result = ISC_R_SUCCESS; + + len = sizeof(addressp->type); + if (getsockname(sock->fd, &addressp->type.sa, (void *)&len) < 0) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "getsockname: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto out; + } + addressp->length = (unsigned int)len; + + out: + UNLOCK(&sock->lock); + + return (result); +} + +/* + * Run through the list of events on this socket, and cancel the ones + * queued for task "task" of type "how". "how" is a bitmask. + */ +ISC_SOCKETFUNC_SCOPE void +isc__socket_cancel(isc_socket_t *sock0, isc_task_t *task, unsigned int how) { + isc__socket_t *sock = (isc__socket_t *)sock0; + + REQUIRE(VALID_SOCKET(sock)); + + /* + * Quick exit if there is nothing to do. Don't even bother locking + * in this case. + */ + if (how == 0) + return; + + LOCK(&sock->lock); + + /* + * All of these do the same thing, more or less. + * Each will: + * o If the internal event is marked as "posted" try to + * remove it from the task's queue. If this fails, mark it + * as canceled instead, and let the task clean it up later. + * o For each I/O request for that task of that type, post + * its done event with status of "ISC_R_CANCELED". + * o Reset any state needed. + */ + if (((how & ISC_SOCKCANCEL_RECV) == ISC_SOCKCANCEL_RECV) + && !ISC_LIST_EMPTY(sock->recv_list)) { + isc_socketevent_t *dev; + isc_socketevent_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->recv_list); + + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + + if ((task == NULL) || (task == current_task)) { + dev->result = ISC_R_CANCELED; + send_recvdone_event(sock, &dev); + } + dev = next; + } + } + + if (((how & ISC_SOCKCANCEL_SEND) == ISC_SOCKCANCEL_SEND) + && !ISC_LIST_EMPTY(sock->send_list)) { + isc_socketevent_t *dev; + isc_socketevent_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->send_list); + + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + + if ((task == NULL) || (task == current_task)) { + dev->result = ISC_R_CANCELED; + send_senddone_event(sock, &dev); + } + dev = next; + } + } + + if (((how & ISC_SOCKCANCEL_ACCEPT) == ISC_SOCKCANCEL_ACCEPT) + && !ISC_LIST_EMPTY(sock->accept_list)) { + isc_socket_newconnev_t *dev; + isc_socket_newconnev_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->accept_list); + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + + if ((task == NULL) || (task == current_task)) { + + ISC_LIST_UNLINK(sock->accept_list, dev, + ev_link); + + NEWCONNSOCK(dev)->references--; + free_socket((isc__socket_t **)&dev->newsocket); + + dev->result = ISC_R_CANCELED; + dev->ev_sender = sock; + isc_task_sendanddetach(¤t_task, + ISC_EVENT_PTR(&dev)); + } + + dev = next; + } + } + + /* + * Connecting is not a list. + */ + if (((how & ISC_SOCKCANCEL_CONNECT) == ISC_SOCKCANCEL_CONNECT) + && sock->connect_ev != NULL) { + isc_socket_connev_t *dev; + isc_task_t *current_task; + + INSIST(sock->connecting); + sock->connecting = 0; + + dev = sock->connect_ev; + current_task = dev->ev_sender; + + if ((task == NULL) || (task == current_task)) { + sock->connect_ev = NULL; + + dev->result = ISC_R_CANCELED; + dev->ev_sender = sock; + isc_task_sendanddetach(¤t_task, + ISC_EVENT_PTR(&dev)); + } + } + + UNLOCK(&sock->lock); +} + +ISC_SOCKETFUNC_SCOPE isc_sockettype_t +isc__socket_gettype(isc_socket_t *sock0) { + isc__socket_t *sock = (isc__socket_t *)sock0; + + REQUIRE(VALID_SOCKET(sock)); + + return (sock->type); +} + +ISC_SOCKETFUNC_SCOPE isc_boolean_t +isc__socket_isbound(isc_socket_t *sock0) { + isc__socket_t *sock = (isc__socket_t *)sock0; + isc_boolean_t val; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + val = ((sock->bound) ? ISC_TRUE : ISC_FALSE); + UNLOCK(&sock->lock); + + return (val); +} + +ISC_SOCKETFUNC_SCOPE void +isc__socket_ipv6only(isc_socket_t *sock0, isc_boolean_t yes) { + isc__socket_t *sock = (isc__socket_t *)sock0; +#if defined(IPV6_V6ONLY) + int onoff = yes ? 1 : 0; +#else + UNUSED(yes); + UNUSED(sock); +#endif + + REQUIRE(VALID_SOCKET(sock)); + INSIST(!sock->dupped); + +#ifdef IPV6_V6ONLY + if (sock->pf == AF_INET6) { + if (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_V6ONLY, + (void *)&onoff, sizeof(int)) < 0) { + char strbuf[ISC_STRERRORSIZE]; + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_V6ONLY) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } + } + FIX_IPV6_RECVPKTINFO(sock); /* AIX */ +#endif +} + +#ifndef USE_WATCHER_THREAD +/* + * In our assumed scenario, we can simply use a single static object. + * XXX: this is not true if the application uses multiple threads with + * 'multi-context' mode. Fixing this is a future TODO item. + */ +static isc_socketwait_t swait_private; + +int +isc__socketmgr_waitevents(isc_socketmgr_t *manager0, struct timeval *tvp, + isc_socketwait_t **swaitp) +{ + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + + + int n; +#ifdef USE_KQUEUE + struct timespec ts, *tsp; +#endif +#ifdef USE_EPOLL + int timeout; +#endif +#ifdef USE_DEVPOLL + struct dvpoll dvp; +#endif + + REQUIRE(swaitp != NULL && *swaitp == NULL); + +#ifdef USE_SHARED_MANAGER + if (manager == NULL) + manager = socketmgr; +#endif + if (manager == NULL) + return (0); + +#ifdef USE_KQUEUE + if (tvp != NULL) { + ts.tv_sec = tvp->tv_sec; + ts.tv_nsec = tvp->tv_usec * 1000; + tsp = &ts; + } else + tsp = NULL; + swait_private.nevents = kevent(manager->kqueue_fd, NULL, 0, + manager->events, manager->nevents, + tsp); + n = swait_private.nevents; +#elif defined(USE_EPOLL) + if (tvp != NULL) + timeout = tvp->tv_sec * 1000 + (tvp->tv_usec + 999) / 1000; + else + timeout = -1; + swait_private.nevents = epoll_wait(manager->epoll_fd, + manager->events, + manager->nevents, timeout); + n = swait_private.nevents; +#elif defined(USE_DEVPOLL) + dvp.dp_fds = manager->events; + dvp.dp_nfds = manager->nevents; + if (tvp != NULL) { + dvp.dp_timeout = tvp->tv_sec * 1000 + + (tvp->tv_usec + 999) / 1000; + } else + dvp.dp_timeout = -1; + swait_private.nevents = ioctl(manager->devpoll_fd, DP_POLL, &dvp); + n = swait_private.nevents; +#elif defined(USE_SELECT) + memcpy(manager->read_fds_copy, manager->read_fds, manager->fd_bufsize); + memcpy(manager->write_fds_copy, manager->write_fds, + manager->fd_bufsize); + + swait_private.readset = manager->read_fds_copy; + swait_private.writeset = manager->write_fds_copy; + swait_private.maxfd = manager->maxfd + 1; + + n = select(swait_private.maxfd, swait_private.readset, + swait_private.writeset, NULL, tvp); +#endif + + *swaitp = &swait_private; + return (n); +} + +isc_result_t +isc__socketmgr_dispatch(isc_socketmgr_t *manager0, isc_socketwait_t *swait) { + isc__socketmgr_t *manager = (isc__socketmgr_t *)manager0; + + REQUIRE(swait == &swait_private); + +#ifdef USE_SHARED_MANAGER + if (manager == NULL) + manager = socketmgr; +#endif + if (manager == NULL) + return (ISC_R_NOTFOUND); + +#if defined(USE_KQUEUE) || defined(USE_EPOLL) || defined(USE_DEVPOLL) + (void)process_fds(manager, manager->events, swait->nevents); + return (ISC_R_SUCCESS); +#elif defined(USE_SELECT) + process_fds(manager, swait->maxfd, swait->readset, swait->writeset); + return (ISC_R_SUCCESS); +#endif +} +#endif /* USE_WATCHER_THREAD */ + +#ifdef BIND9 +void +isc__socket_setname(isc_socket_t *socket0, const char *name, void *tag) { + isc__socket_t *socket = (isc__socket_t *)socket0; + + /* + * Name 'socket'. + */ + + REQUIRE(VALID_SOCKET(socket)); + + LOCK(&socket->lock); + memset(socket->name, 0, sizeof(socket->name)); + strncpy(socket->name, name, sizeof(socket->name) - 1); + socket->tag = tag; + UNLOCK(&socket->lock); +} + +ISC_SOCKETFUNC_SCOPE const char * +isc__socket_getname(isc_socket_t *socket0) { + isc__socket_t *socket = (isc__socket_t *)socket0; + + return (socket->name); +} + +void * +isc__socket_gettag(isc_socket_t *socket0) { + isc__socket_t *socket = (isc__socket_t *)socket0; + + return (socket->tag); +} +#endif /* BIND9 */ + +#ifdef USE_SOCKETIMPREGISTER +isc_result_t +isc__socket_register() { + return (isc_socket_register(isc__socketmgr_create)); +} +#endif + +ISC_SOCKETFUNC_SCOPE int +isc__socket_getfd(isc_socket_t *socket0) { + isc__socket_t *socket = (isc__socket_t *)socket0; + + return ((short) socket->fd); +} + +#if defined(HAVE_LIBXML2) && defined(BIND9) + +static const char * +_socktype(isc_sockettype_t type) +{ + if (type == isc_sockettype_udp) + return ("udp"); + else if (type == isc_sockettype_tcp) + return ("tcp"); + else if (type == isc_sockettype_unix) + return ("unix"); + else if (type == isc_sockettype_fdwatch) + return ("fdwatch"); + else + return ("not-initialized"); +} + +ISC_SOCKETFUNC_SCOPE void +isc_socketmgr_renderxml(isc_socketmgr_t *mgr0, xmlTextWriterPtr writer) { + isc__socketmgr_t *mgr = (isc__socketmgr_t *)mgr0; + isc__socket_t *sock; + char peerbuf[ISC_SOCKADDR_FORMATSIZE]; + isc_sockaddr_t addr; + ISC_SOCKADDR_LEN_T len; + + LOCK(&mgr->lock); + +#ifdef USE_SHARED_MANAGER + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->refs); + xmlTextWriterEndElement(writer); +#endif /* USE_SHARED_MANAGER */ + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "sockets"); + sock = ISC_LIST_HEAD(mgr->socklist); + while (sock != NULL) { + LOCK(&sock->lock); + xmlTextWriterStartElement(writer, ISC_XMLCHAR "socket"); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "id"); + xmlTextWriterWriteFormatString(writer, "%p", sock); + xmlTextWriterEndElement(writer); + + if (sock->name[0] != 0) { + xmlTextWriterStartElement(writer, ISC_XMLCHAR "name"); + xmlTextWriterWriteFormatString(writer, "%s", + sock->name); + xmlTextWriterEndElement(writer); /* name */ + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", sock->references); + xmlTextWriterEndElement(writer); + + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "type", + ISC_XMLCHAR _socktype(sock->type)); + + if (sock->connected) { + isc_sockaddr_format(&sock->peer_address, peerbuf, + sizeof(peerbuf)); + xmlTextWriterWriteElement(writer, + ISC_XMLCHAR "peer-address", + ISC_XMLCHAR peerbuf); + } + + len = sizeof(addr); + if (getsockname(sock->fd, &addr.type.sa, (void *)&len) == 0) { + isc_sockaddr_format(&addr, peerbuf, sizeof(peerbuf)); + xmlTextWriterWriteElement(writer, + ISC_XMLCHAR "local-address", + ISC_XMLCHAR peerbuf); + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "states"); + if (sock->pending_recv) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending-receive"); + if (sock->pending_send) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending-send"); + if (sock->pending_accept) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending_accept"); + if (sock->listener) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "listener"); + if (sock->connected) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "connected"); + if (sock->connecting) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "connecting"); + if (sock->bound) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "bound"); + + xmlTextWriterEndElement(writer); /* states */ + + xmlTextWriterEndElement(writer); /* socket */ + + UNLOCK(&sock->lock); + sock = ISC_LIST_NEXT(sock, link); + } + xmlTextWriterEndElement(writer); /* sockets */ + + UNLOCK(&mgr->lock); +} +#endif /* HAVE_LIBXML2 */ diff --git a/contrib/ntp/lib/isc/unix/socket_p.h b/contrib/ntp/lib/isc/unix/socket_p.h new file mode 100644 index 000000000..131601173 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/socket_p.h @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: socket_p.h,v 1.15 2009/09/02 23:48:03 tbox Exp $ */ + +#ifndef ISC_SOCKET_P_H +#define ISC_SOCKET_P_H + +/*! \file */ + +#ifdef ISC_PLATFORM_NEEDSYSSELECTH +#include +#endif + +typedef struct isc_socketwait isc_socketwait_t; +int isc__socketmgr_waitevents(isc_socketmgr_t *, struct timeval *, + isc_socketwait_t **); +isc_result_t isc__socketmgr_dispatch(isc_socketmgr_t *, isc_socketwait_t *); +#endif /* ISC_SOCKET_P_H */ diff --git a/contrib/ntp/lib/isc/unix/stdio.c b/contrib/ntp/lib/isc/unix/stdio.c new file mode 100644 index 000000000..360c8c644 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/stdio.c @@ -0,0 +1,129 @@ +/* + * Copyright (C) 2004, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#include + +#include +#include + +#include +#include + +#include "errno2result.h" + +isc_result_t +isc_stdio_open(const char *filename, const char *mode, FILE **fp) { + FILE *f; + + f = fopen(filename, mode); + if (f == NULL) + return (isc__errno2result(errno)); + *fp = f; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_stdio_close(FILE *f) { + int r; + + r = fclose(f); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_seek(FILE *f, long offset, int whence) { + int r; + + r = fseek(f, offset, whence); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_read(void *ptr, size_t size, size_t nmemb, FILE *f, size_t *nret) { + isc_result_t result = ISC_R_SUCCESS; + size_t r; + + clearerr(f); + r = fread(ptr, size, nmemb, f); + if (r != nmemb) { + if (feof(f)) + result = ISC_R_EOF; + else + result = isc__errno2result(errno); + } + if (nret != NULL) + *nret = r; + return (result); +} + +isc_result_t +isc_stdio_write(const void *ptr, size_t size, size_t nmemb, FILE *f, + size_t *nret) +{ + isc_result_t result = ISC_R_SUCCESS; + size_t r; + + clearerr(f); + r = fwrite(ptr, size, nmemb, f); + if (r != nmemb) + result = isc__errno2result(errno); + if (nret != NULL) + *nret = r; + return (result); +} + +isc_result_t +isc_stdio_flush(FILE *f) { + int r; + + r = fflush(f); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +/* + * OpenBSD has deprecated ENOTSUP in favor of EOPNOTSUPP. + */ +#if defined(EOPNOTSUPP) && !defined(ENOTSUP) +#define ENOTSUP EOPNOTSUPP +#endif + +isc_result_t +isc_stdio_sync(FILE *f) { + int r; + + r = fsync(fileno(f)); + /* + * fsync is not supported on sockets and pipes which + * result in EINVAL / ENOTSUP. + */ + if (r == 0 || errno == EINVAL || errno == ENOTSUP) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + diff --git a/contrib/ntp/lib/isc/unix/stdtime.c b/contrib/ntp/lib/isc/unix/stdtime.c new file mode 100644 index 000000000..c5d0c47df --- /dev/null +++ b/contrib/ntp/lib/isc/unix/stdtime.c @@ -0,0 +1,86 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdtime.c,v 1.19 2007/06/19 23:47:18 tbox Exp $ */ + +/*! \file */ + +#include + +#include /* NULL */ +#include /* NULL */ +#include + +#include + +#include +#include + +#ifndef ISC_FIX_TV_USEC +#define ISC_FIX_TV_USEC 1 +#endif + +#define US_PER_S 1000000 + +#if ISC_FIX_TV_USEC +static inline void +fix_tv_usec(struct timeval *tv) { + isc_boolean_t fixed = ISC_FALSE; + + if (tv->tv_usec < 0) { + fixed = ISC_TRUE; + do { + tv->tv_sec -= 1; + tv->tv_usec += US_PER_S; + } while (tv->tv_usec < 0); + } else if (tv->tv_usec >= US_PER_S) { + fixed = ISC_TRUE; + do { + tv->tv_sec += 1; + tv->tv_usec -= US_PER_S; + } while (tv->tv_usec >=US_PER_S); + } + /* + * Call syslog directly as we are called from the logging functions. + */ + if (fixed) + (void)syslog(LOG_ERR, "gettimeofday returned bad tv_usec: corrected"); +} +#endif + +void +isc_stdtime_get(isc_stdtime_t *t) { + struct timeval tv; + + /* + * Set 't' to the number of seconds since 00:00:00 UTC, January 1, + * 1970. + */ + + REQUIRE(t != NULL); + + RUNTIME_CHECK(gettimeofday(&tv, NULL) != -1); + +#if ISC_FIX_TV_USEC + fix_tv_usec(&tv); + INSIST(tv.tv_usec >= 0); +#else + INSIST(tv.tv_usec >= 0 && tv.tv_usec < US_PER_S); +#endif + + *t = (unsigned int)tv.tv_sec; +} diff --git a/contrib/ntp/libisc/isc_strerror.c b/contrib/ntp/lib/isc/unix/strerror.c similarity index 62% rename from contrib/ntp/libisc/isc_strerror.c rename to contrib/ntp/lib/isc/unix/strerror.c index 9ec4a2f15..22780095b 100644 --- a/contrib/ntp/libisc/isc_strerror.c +++ b/contrib/ntp/lib/isc/unix/strerror.c @@ -1,21 +1,23 @@ /* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: strerror.c,v 1.3 2001/11/20 01:45:45 gson Exp $ */ +/* $Id: strerror.c,v 1.10 2009/02/16 23:48:04 tbox Exp $ */ + +/*! \file */ #include @@ -28,10 +30,10 @@ #include #include -#include "l_stdlib.h" +#include "l_stdlib.h" /* NTP local change */ #ifdef HAVE_STRERROR -/* +/*% * We need to do this this way for profiled locks. */ static isc_mutex_t isc_strerror_lock; @@ -47,7 +49,7 @@ void isc__strerror(int num, char *buf, size_t size) { #ifdef HAVE_STRERROR char *msg; - unsigned int unum = num; + unsigned int unum = (unsigned int)num; static isc_once_t once = ISC_ONCE_INIT; REQUIRE(buf != NULL); @@ -62,7 +64,7 @@ isc__strerror(int num, char *buf, size_t size) { snprintf(buf, size, "Unknown error: %u", unum); UNLOCK(&isc_strerror_lock); #else - unsigned int unum = num; + unsigned int unum = (unsigned int)num; REQUIRE(buf != NULL); diff --git a/contrib/ntp/lib/isc/unix/syslog.c b/contrib/ntp/lib/isc/unix/syslog.c new file mode 100644 index 000000000..997508e32 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/syslog.c @@ -0,0 +1,84 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: syslog.c,v 1.8 2007/09/13 04:45:18 each Exp $ */ + +/*! \file */ + +#include + +#include +#include + +#include +#include +#include +#include + +static struct dsn_c_pvt_sfnt { + int val; + const char *strval; +} facilities[] = { + { LOG_KERN, "kern" }, + { LOG_USER, "user" }, + { LOG_MAIL, "mail" }, + { LOG_DAEMON, "daemon" }, + { LOG_AUTH, "auth" }, + { LOG_SYSLOG, "syslog" }, + { LOG_LPR, "lpr" }, +#ifdef LOG_NEWS + { LOG_NEWS, "news" }, +#endif +#ifdef LOG_UUCP + { LOG_UUCP, "uucp" }, +#endif +#ifdef LOG_CRON + { LOG_CRON, "cron" }, +#endif +#ifdef LOG_AUTHPRIV + { LOG_AUTHPRIV, "authpriv" }, +#endif +#ifdef LOG_FTP + { LOG_FTP, "ftp" }, +#endif + { LOG_LOCAL0, "local0"}, + { LOG_LOCAL1, "local1"}, + { LOG_LOCAL2, "local2"}, + { LOG_LOCAL3, "local3"}, + { LOG_LOCAL4, "local4"}, + { LOG_LOCAL5, "local5"}, + { LOG_LOCAL6, "local6"}, + { LOG_LOCAL7, "local7"}, + { 0, NULL } +}; + +isc_result_t +isc_syslog_facilityfromstring(const char *str, int *facilityp) { + int i; + + REQUIRE(str != NULL); + REQUIRE(facilityp != NULL); + + for (i = 0; facilities[i].strval != NULL; i++) { + if (strcasecmp(facilities[i].strval, str) == 0) { + *facilityp = facilities[i].val; + return (ISC_R_SUCCESS); + } + } + return (ISC_R_NOTFOUND); + +} diff --git a/contrib/ntp/lib/isc/unix/time.c b/contrib/ntp/lib/isc/unix/time.c new file mode 100644 index 000000000..ac23ae092 --- /dev/null +++ b/contrib/ntp/lib/isc/unix/time.c @@ -0,0 +1,420 @@ +/* + * Copyright (C) 2004-2008, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/*! \file */ + +#include + +#include +#include +#include +#include + +#include /* Required for struct timeval on some platforms. */ + +#include +#include +#include +#include +#include +#include + +#define NS_PER_S 1000000000 /*%< Nanoseconds per second. */ +#define NS_PER_US 1000 /*%< Nanoseconds per microsecond. */ +#define US_PER_S 1000000 /*%< Microseconds per second. */ + +/* + * All of the INSIST()s checks of nanoseconds < NS_PER_S are for + * consistency checking of the type. In lieu of magic numbers, it + * is the best we've got. The check is only performed on functions which + * need an initialized type. + */ + +#ifndef ISC_FIX_TV_USEC +#define ISC_FIX_TV_USEC 1 +#endif + +/*% + *** Intervals + ***/ + +static isc_interval_t zero_interval = { 0, 0 }; +isc_interval_t *isc_interval_zero = &zero_interval; + +#if ISC_FIX_TV_USEC +static inline void +fix_tv_usec(struct timeval *tv) { + isc_boolean_t fixed = ISC_FALSE; + + if (tv->tv_usec < 0) { + fixed = ISC_TRUE; + do { + tv->tv_sec -= 1; + tv->tv_usec += US_PER_S; + } while (tv->tv_usec < 0); + } else if (tv->tv_usec >= US_PER_S) { + fixed = ISC_TRUE; + do { + tv->tv_sec += 1; + tv->tv_usec -= US_PER_S; + } while (tv->tv_usec >=US_PER_S); + } + /* + * Call syslog directly as was are called from the logging functions. + */ + if (fixed) + (void)syslog(LOG_ERR, "gettimeofday returned bad tv_usec: corrected"); +} +#endif + +void +isc_interval_set(isc_interval_t *i, + unsigned int seconds, unsigned int nanoseconds) +{ + REQUIRE(i != NULL); + REQUIRE(nanoseconds < NS_PER_S); + + i->seconds = seconds; + i->nanoseconds = nanoseconds; +} + +isc_boolean_t +isc_interval_iszero(const isc_interval_t *i) { + REQUIRE(i != NULL); + INSIST(i->nanoseconds < NS_PER_S); + + if (i->seconds == 0 && i->nanoseconds == 0) + return (ISC_TRUE); + + return (ISC_FALSE); +} + + +/*** + *** Absolute Times + ***/ + +static isc_time_t epoch = { 0, 0 }; +isc_time_t *isc_time_epoch = &epoch; + +void +isc_time_set(isc_time_t *t, unsigned int seconds, unsigned int nanoseconds) { + REQUIRE(t != NULL); + REQUIRE(nanoseconds < NS_PER_S); + + t->seconds = seconds; + t->nanoseconds = nanoseconds; +} + +void +isc_time_settoepoch(isc_time_t *t) { + REQUIRE(t != NULL); + + t->seconds = 0; + t->nanoseconds = 0; +} + +isc_boolean_t +isc_time_isepoch(const isc_time_t *t) { + REQUIRE(t != NULL); + INSIST(t->nanoseconds < NS_PER_S); + + if (t->seconds == 0 && t->nanoseconds == 0) + return (ISC_TRUE); + + return (ISC_FALSE); +} + + +isc_result_t +isc_time_now(isc_time_t *t) { + struct timeval tv; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(t != NULL); + + if (gettimeofday(&tv, NULL) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "%s", strbuf); + return (ISC_R_UNEXPECTED); + } + + /* + * Does POSIX guarantee the signedness of tv_sec and tv_usec? If not, + * then this test will generate warnings for platforms on which it is + * unsigned. In any event, the chances of any of these problems + * happening are pretty much zero, but since the libisc library ensures + * certain things to be true ... + */ +#if ISC_FIX_TV_USEC + fix_tv_usec(&tv); + if (tv.tv_sec < 0) + return (ISC_R_UNEXPECTED); +#else + if (tv.tv_sec < 0 || tv.tv_usec < 0 || tv.tv_usec >= US_PER_S) + return (ISC_R_UNEXPECTED); +#endif + + /* + * Ensure the tv_sec value fits in t->seconds. + */ + if (sizeof(tv.tv_sec) > sizeof(t->seconds) && + ((tv.tv_sec | (unsigned int)-1) ^ (unsigned int)-1) != 0U) + return (ISC_R_RANGE); + + t->seconds = tv.tv_sec; + t->nanoseconds = tv.tv_usec * NS_PER_US; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_time_nowplusinterval(isc_time_t *t, const isc_interval_t *i) { + struct timeval tv; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(t != NULL); + REQUIRE(i != NULL); + INSIST(i->nanoseconds < NS_PER_S); + + if (gettimeofday(&tv, NULL) == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "%s", strbuf); + return (ISC_R_UNEXPECTED); + } + + /* + * Does POSIX guarantee the signedness of tv_sec and tv_usec? If not, + * then this test will generate warnings for platforms on which it is + * unsigned. In any event, the chances of any of these problems + * happening are pretty much zero, but since the libisc library ensures + * certain things to be true ... + */ +#if ISC_FIX_TV_USEC + fix_tv_usec(&tv); + if (tv.tv_sec < 0) + return (ISC_R_UNEXPECTED); +#else + if (tv.tv_sec < 0 || tv.tv_usec < 0 || tv.tv_usec >= US_PER_S) + return (ISC_R_UNEXPECTED); +#endif + + /* + * Ensure the resulting seconds value fits in the size of an + * unsigned int. (It is written this way as a slight optimization; + * note that even if both values == INT_MAX, then when added + * and getting another 1 added below the result is UINT_MAX.) + */ + if ((tv.tv_sec > INT_MAX || i->seconds > INT_MAX) && + ((long long)tv.tv_sec + i->seconds > UINT_MAX)) + return (ISC_R_RANGE); + + t->seconds = tv.tv_sec + i->seconds; + t->nanoseconds = tv.tv_usec * NS_PER_US + i->nanoseconds; + if (t->nanoseconds >= NS_PER_S) { + t->seconds++; + t->nanoseconds -= NS_PER_S; + } + + return (ISC_R_SUCCESS); +} + +int +isc_time_compare(const isc_time_t *t1, const isc_time_t *t2) { + REQUIRE(t1 != NULL && t2 != NULL); + INSIST(t1->nanoseconds < NS_PER_S && t2->nanoseconds < NS_PER_S); + + if (t1->seconds < t2->seconds) + return (-1); + if (t1->seconds > t2->seconds) + return (1); + if (t1->nanoseconds < t2->nanoseconds) + return (-1); + if (t1->nanoseconds > t2->nanoseconds) + return (1); + return (0); +} + +isc_result_t +isc_time_add(const isc_time_t *t, const isc_interval_t *i, isc_time_t *result) +{ + REQUIRE(t != NULL && i != NULL && result != NULL); + INSIST(t->nanoseconds < NS_PER_S && i->nanoseconds < NS_PER_S); + + /* + * Ensure the resulting seconds value fits in the size of an + * unsigned int. (It is written this way as a slight optimization; + * note that even if both values == INT_MAX, then when added + * and getting another 1 added below the result is UINT_MAX.) + */ + if ((t->seconds > INT_MAX || i->seconds > INT_MAX) && + ((long long)t->seconds + i->seconds > UINT_MAX)) + return (ISC_R_RANGE); + + result->seconds = t->seconds + i->seconds; + result->nanoseconds = t->nanoseconds + i->nanoseconds; + if (result->nanoseconds >= NS_PER_S) { + result->seconds++; + result->nanoseconds -= NS_PER_S; + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_time_subtract(const isc_time_t *t, const isc_interval_t *i, + isc_time_t *result) +{ + REQUIRE(t != NULL && i != NULL && result != NULL); + INSIST(t->nanoseconds < NS_PER_S && i->nanoseconds < NS_PER_S); + + if ((unsigned int)t->seconds < i->seconds || + ((unsigned int)t->seconds == i->seconds && + t->nanoseconds < i->nanoseconds)) + return (ISC_R_RANGE); + + result->seconds = t->seconds - i->seconds; + if (t->nanoseconds >= i->nanoseconds) + result->nanoseconds = t->nanoseconds - i->nanoseconds; + else { + result->nanoseconds = NS_PER_S - i->nanoseconds + + t->nanoseconds; + result->seconds--; + } + + return (ISC_R_SUCCESS); +} + +isc_uint64_t +isc_time_microdiff(const isc_time_t *t1, const isc_time_t *t2) { + isc_uint64_t i1, i2, i3; + + REQUIRE(t1 != NULL && t2 != NULL); + INSIST(t1->nanoseconds < NS_PER_S && t2->nanoseconds < NS_PER_S); + + i1 = (isc_uint64_t)t1->seconds * NS_PER_S + t1->nanoseconds; + i2 = (isc_uint64_t)t2->seconds * NS_PER_S + t2->nanoseconds; + + if (i1 <= i2) + return (0); + + i3 = i1 - i2; + + /* + * Convert to microseconds. + */ + i3 /= NS_PER_US; + + return (i3); +} + +isc_uint32_t +isc_time_seconds(const isc_time_t *t) { + REQUIRE(t != NULL); + INSIST(t->nanoseconds < NS_PER_S); + + return ((isc_uint32_t)t->seconds); +} + +isc_result_t +isc_time_secondsastimet(const isc_time_t *t, time_t *secondsp) { + time_t seconds; + + REQUIRE(t != NULL); + INSIST(t->nanoseconds < NS_PER_S); + + /* + * Ensure that the number of seconds represented by t->seconds + * can be represented by a time_t. Since t->seconds is an unsigned + * int and since time_t is mostly opaque, this is trickier than + * it seems. (This standardized opaqueness of time_t is *very* + * frustrating; time_t is not even limited to being an integral + * type.) + * + * The mission, then, is to avoid generating any kind of warning + * about "signed versus unsigned" while trying to determine if the + * the unsigned int t->seconds is out range for tv_sec, which is + * pretty much only true if time_t is a signed integer of the same + * size as the return value of isc_time_seconds. + * + * If the paradox in the if clause below is true, t->seconds is out + * of range for time_t. + */ + seconds = (time_t)t->seconds; + + INSIST(sizeof(unsigned int) == sizeof(isc_uint32_t)); + INSIST(sizeof(time_t) >= sizeof(isc_uint32_t)); + + if (t->seconds > (~0U>>1) && seconds <= (time_t)(~0U>>1)) + return (ISC_R_RANGE); + + *secondsp = seconds; + + return (ISC_R_SUCCESS); +} + +isc_uint32_t +isc_time_nanoseconds(const isc_time_t *t) { + REQUIRE(t != NULL); + + ENSURE(t->nanoseconds < NS_PER_S); + + return ((isc_uint32_t)t->nanoseconds); +} + +void +isc_time_formattimestamp(const isc_time_t *t, char *buf, unsigned int len) { + time_t now; + unsigned int flen; + + REQUIRE(len > 0); + + now = (time_t) t->seconds; + flen = strftime(buf, len, "%d-%b-%Y %X", localtime(&now)); + INSIST(flen < len); + if (flen != 0) + snprintf(buf + flen, len - flen, + ".%03u", t->nanoseconds / 1000000); + else + snprintf(buf, len, "99-Bad-9999 99:99:99.999"); +} + +void +isc_time_formathttptimestamp(const isc_time_t *t, char *buf, unsigned int len) { + time_t now; + unsigned int flen; + + REQUIRE(len > 0); + + now = (time_t)t->seconds; + flen = strftime(buf, len, "%a, %d %b %Y %H:%M:%S GMT", gmtime(&now)); + INSIST(flen < len); +} + +void +isc_time_formatISO8601(const isc_time_t *t, char *buf, unsigned int len) { + time_t now; + unsigned int flen; + + REQUIRE(len > 0); + + now = (time_t)t->seconds; + flen = strftime(buf, len, "%Y-%m-%dT%H:%M:%SZ", gmtime(&now)); + INSIST(flen < len); +} diff --git a/contrib/ntp/lib/isc/version.c b/contrib/ntp/lib/isc/version.c new file mode 100644 index 000000000..bfe4d6d6e --- /dev/null +++ b/contrib/ntp/lib/isc/version.c @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: version.c,v 1.15 2007/06/19 23:47:17 tbox Exp $ */ + +/*! \file */ + +#include + +const char isc_version[] = VERSION; + +const unsigned int isc_libinterface = LIBINTERFACE; +const unsigned int isc_librevision = LIBREVISION; +const unsigned int isc_libage = LIBAGE; diff --git a/contrib/ntp/lib/isc/win32/DLLMain.c b/contrib/ntp/lib/isc/win32/DLLMain.c new file mode 100644 index 000000000..ed84fcf6c --- /dev/null +++ b/contrib/ntp/lib/isc/win32/DLLMain.c @@ -0,0 +1,58 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: DLLMain.c,v 1.7 2007/06/18 23:47:49 tbox Exp $ */ + +#include +#include + +/* + * Called when we enter the DLL + */ +__declspec(dllexport) BOOL WINAPI DllMain(HINSTANCE hinstDLL, + DWORD fdwReason, LPVOID lpvReserved) +{ + switch (fdwReason) + { + /* + * The DLL is loading due to process + * initialization or a call to LoadLibrary. + */ + case DLL_PROCESS_ATTACH: + break; + + /* The attached process creates a new thread. */ + case DLL_THREAD_ATTACH: + break; + + /* The thread of the attached process terminates. */ + case DLL_THREAD_DETACH: + break; + + /* + * The DLL is unloading from a process due to + * process termination or a call to FreeLibrary. + */ + case DLL_PROCESS_DETACH: + break; + + default: + break; + } + return (TRUE); +} + diff --git a/contrib/ntp/lib/isc/win32/app.c b/contrib/ntp/lib/isc/win32/app.c new file mode 100644 index 000000000..04b163878 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/app.c @@ -0,0 +1,260 @@ +/* + * Copyright (C) 2004, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: app.c,v 1.9 2009/09/02 23:48:03 tbox Exp $ */ + +#include + +#include + +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +static isc_eventlist_t on_run; +static isc_mutex_t lock; +static isc_boolean_t shutdown_requested = ISC_FALSE; +static isc_boolean_t running = ISC_FALSE; +/* + * We assume that 'want_shutdown' can be read and written atomically. + */ +static isc_boolean_t want_shutdown = ISC_FALSE; +/* + * We assume that 'want_reload' can be read and written atomically. + */ +static isc_boolean_t want_reload = ISC_FALSE; + +static isc_boolean_t blocked = ISC_FALSE; + +static isc_thread_t blockedthread; + +/* Events to wait for */ + +#define NUM_EVENTS 2 + +enum { + RELOAD_EVENT, + SHUTDOWN_EVENT +}; + +static HANDLE hEvents[NUM_EVENTS]; +DWORD dwWaitResult; + +/* + * We need to remember which thread is the main thread... + */ +static isc_thread_t main_thread; + +isc_result_t +isc__app_start(void) { + isc_result_t result; + + /* + * Start an ISC library application. + */ + + main_thread = GetCurrentThread(); + + result = isc_mutex_init(&lock); + if (result != ISC_R_SUCCESS) + return (result); + + /* Create the reload event in a non-signaled state */ + hEvents[RELOAD_EVENT] = CreateEvent(NULL, FALSE, FALSE, NULL); + + /* Create the shutdown event in a non-signaled state */ + hEvents[SHUTDOWN_EVENT] = CreateEvent(NULL, FALSE, FALSE, NULL); + + ISC_LIST_INIT(on_run); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__app_onrun(isc_mem_t *mctx, isc_task_t *task, isc_taskaction_t action, + void *arg) { + isc_event_t *event; + isc_task_t *cloned_task = NULL; + isc_result_t result; + + + LOCK(&lock); + if (running) { + result = ISC_R_ALREADYRUNNING; + goto unlock; + } + + /* + * Note that we store the task to which we're going to send the event + * in the event's "sender" field. + */ + isc_task_attach(task, &cloned_task); + event = isc_event_allocate(mctx, cloned_task, ISC_APPEVENT_SHUTDOWN, + action, arg, sizeof(*event)); + if (event == NULL) { + result = ISC_R_NOMEMORY; + goto unlock; + } + + ISC_LIST_APPEND(on_run, event, ev_link); + result = ISC_R_SUCCESS; + + unlock: + UNLOCK(&lock); + return (result); +} + +isc_result_t +isc__app_run(void) { + isc_event_t *event, *next_event; + isc_task_t *task; + HANDLE *pHandles = NULL; + + REQUIRE(main_thread == GetCurrentThread()); + LOCK(&lock); + if (!running) { + running = ISC_TRUE; + + /* + * Post any on-run events (in FIFO order). + */ + for (event = ISC_LIST_HEAD(on_run); + event != NULL; + event = next_event) { + next_event = ISC_LIST_NEXT(event, ev_link); + ISC_LIST_UNLINK(on_run, event, ev_link); + task = event->ev_sender; + event->ev_sender = NULL; + isc_task_sendanddetach(&task, &event); + } + + } + + UNLOCK(&lock); + + /* + * There is no danger if isc_app_shutdown() is called before we wait + * for events. + */ + + while (!want_shutdown) { + dwWaitResult = WaitForMultipleObjects(NUM_EVENTS, hEvents, + FALSE, INFINITE); + + /* See why we returned */ + + if (WaitSucceeded(dwWaitResult, NUM_EVENTS)) { + /* + * The return was due to one of the events + * being signaled + */ + switch (WaitSucceededIndex(dwWaitResult)) { + case RELOAD_EVENT: + want_reload = ISC_TRUE; + break; + + case SHUTDOWN_EVENT: + want_shutdown = ISC_TRUE; + break; + } + } + if (want_reload) { + want_reload = ISC_FALSE; + return (ISC_R_RELOAD); + } + + if (want_shutdown && blocked) + exit(-1); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__app_shutdown(void) { + isc_boolean_t want_kill = ISC_TRUE; + + LOCK(&lock); + REQUIRE(running); + + if (shutdown_requested) + want_kill = ISC_FALSE; /* We're only signaling once */ + else + shutdown_requested = ISC_TRUE; + + UNLOCK(&lock); + if (want_kill) + SetEvent(hEvents[SHUTDOWN_EVENT]); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__app_reload(void) { + isc_boolean_t want_reload = ISC_TRUE; + + LOCK(&lock); + REQUIRE(running); + + /* + * Don't send the reload signal if we're shutting down. + */ + if (shutdown_requested) + want_reload = ISC_FALSE; + + UNLOCK(&lock); + if (want_reload) + SetEvent(hEvents[RELOAD_EVENT]); + + return (ISC_R_SUCCESS); +} + +void +isc__app_finish(void) { + DESTROYLOCK(&lock); +} + +void +isc__app_block(void) { + REQUIRE(running); + REQUIRE(!blocked); + + blocked = ISC_TRUE; + blockedthread = GetCurrentThread(); +} + +void +isc__app_unblock(void) { + REQUIRE(running); + REQUIRE(blocked); + blocked = ISC_FALSE; + REQUIRE(blockedthread == GetCurrentThread()); +} diff --git a/contrib/ntp/lib/isc/win32/condition.c b/contrib/ntp/lib/isc/win32/condition.c new file mode 100644 index 000000000..27d4e7607 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/condition.c @@ -0,0 +1,258 @@ +/* + * Copyright (C) 2004, 2006, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.c,v 1.23 2007/06/18 23:47:49 tbox Exp $ */ + +#include + +#include +#include +#include +#include +#include + +#define LSIGNAL 0 +#define LBROADCAST 1 + +isc_result_t +isc_condition_init(isc_condition_t *cond) { + HANDLE h; + + REQUIRE(cond != NULL); + + cond->waiters = 0; + /* + * This handle is shared across all threads + */ + h = CreateEvent(NULL, FALSE, FALSE, NULL); + if (h == NULL) { + /* XXX */ + return (ISC_R_UNEXPECTED); + } + cond->events[LSIGNAL] = h; + + /* + * The threadlist will hold the actual events needed + * for the wait condition + */ + ISC_LIST_INIT(cond->threadlist); + + return (ISC_R_SUCCESS); +} + +/* + * Add the thread to the threadlist along with the required events + */ +static isc_result_t +register_thread(unsigned long thrd, isc_condition_t *gblcond, + isc_condition_thread_t **localcond) +{ + HANDLE hc; + isc_condition_thread_t *newthread; + + REQUIRE(localcond != NULL && *localcond == NULL); + + newthread = malloc(sizeof(isc_condition_thread_t)); + if (newthread == NULL) + return (ISC_R_NOMEMORY); + + /* + * Create the thread-specific handle + */ + hc = CreateEvent(NULL, FALSE, FALSE, NULL); + if (hc == NULL) { + free(newthread); + return (ISC_R_UNEXPECTED); + } + + /* + * Add the thread ID and handles to list of threads for broadcast + */ + newthread->handle[LSIGNAL] = gblcond->events[LSIGNAL]; + newthread->handle[LBROADCAST] = hc; + newthread->th = thrd; + + /* + * The thread is holding the manager lock so this is safe + */ + ISC_LIST_APPEND(gblcond->threadlist, newthread, link); + *localcond = newthread; + return (ISC_R_SUCCESS); +} + +static isc_result_t +find_thread_condition(unsigned long thrd, isc_condition_t *cond, + isc_condition_thread_t **threadcondp) +{ + isc_condition_thread_t *threadcond; + + REQUIRE(threadcondp != NULL && *threadcondp == NULL); + + /* + * Look for the thread ID. + */ + for (threadcond = ISC_LIST_HEAD(cond->threadlist); + threadcond != NULL; + threadcond = ISC_LIST_NEXT(threadcond, link)) { + + if (threadcond->th == thrd) { + *threadcondp = threadcond; + return (ISC_R_SUCCESS); + } + } + + /* + * Not found, so add it. + */ + return (register_thread(thrd, cond, threadcondp)); +} + +isc_result_t +isc_condition_signal(isc_condition_t *cond) { + + /* + * Unlike pthreads, the caller MUST hold the lock associated with + * the condition variable when calling us. + */ + REQUIRE(cond != NULL); + + if (!SetEvent(cond->events[LSIGNAL])) { + /* XXX */ + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_condition_broadcast(isc_condition_t *cond) { + + isc_condition_thread_t *threadcond; + isc_boolean_t failed = ISC_FALSE; + + /* + * Unlike pthreads, the caller MUST hold the lock associated with + * the condition variable when calling us. + */ + REQUIRE(cond != NULL); + + /* + * Notify every thread registered for this + */ + for (threadcond = ISC_LIST_HEAD(cond->threadlist); + threadcond != NULL; + threadcond = ISC_LIST_NEXT(threadcond, link)) { + + if (!SetEvent(threadcond->handle[LBROADCAST])) + failed = ISC_TRUE; + } + + if (failed) + return (ISC_R_UNEXPECTED); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_condition_destroy(isc_condition_t *cond) { + + isc_condition_thread_t *next, *threadcond; + + REQUIRE(cond != NULL); + REQUIRE(cond->waiters == 0); + + (void)CloseHandle(cond->events[LSIGNAL]); + + /* + * Delete the threadlist + */ + threadcond = ISC_LIST_HEAD(cond->threadlist); + + while (threadcond != NULL) { + next = ISC_LIST_NEXT(threadcond, link); + DEQUEUE(cond->threadlist, threadcond, link); + (void) CloseHandle(threadcond->handle[LBROADCAST]); + free(threadcond); + threadcond = next; + } + + return (ISC_R_SUCCESS); +} + +/* + * This is always called when the mutex (lock) is held, but because + * we are waiting we need to release it and reacquire it as soon as the wait + * is over. This allows other threads to make use of the object guarded + * by the mutex but it should never try to delete it as long as the + * number of waiters > 0. Always reacquire the mutex regardless of the + * result of the wait. Note that EnterCriticalSection will wait to acquire + * the mutex. + */ +static isc_result_t +wait(isc_condition_t *cond, isc_mutex_t *mutex, DWORD milliseconds) { + DWORD result; + isc_result_t tresult; + isc_condition_thread_t *threadcond = NULL; + + /* + * Get the thread events needed for the wait + */ + tresult = find_thread_condition(isc_thread_self(), cond, &threadcond); + if (tresult != ISC_R_SUCCESS) + return (tresult); + + cond->waiters++; + LeaveCriticalSection(mutex); + result = WaitForMultipleObjects(2, threadcond->handle, FALSE, + milliseconds); + EnterCriticalSection(mutex); + cond->waiters--; + if (result == WAIT_FAILED) { + /* XXX */ + return (ISC_R_UNEXPECTED); + } + if (result == WAIT_TIMEOUT) + return (ISC_R_TIMEDOUT); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_condition_wait(isc_condition_t *cond, isc_mutex_t *mutex) { + return (wait(cond, mutex, INFINITE)); +} + +isc_result_t +isc_condition_waituntil(isc_condition_t *cond, isc_mutex_t *mutex, + isc_time_t *t) { + DWORD milliseconds; + isc_uint64_t microseconds; + isc_time_t now; + + if (isc_time_now(&now) != ISC_R_SUCCESS) { + /* XXX */ + return (ISC_R_UNEXPECTED); + } + + microseconds = isc_time_microdiff(t, &now); + if (microseconds > 0xFFFFFFFFi64 * 1000) + milliseconds = 0xFFFFFFFF; + else + milliseconds = (DWORD)(microseconds / 1000); + + return (wait(cond, mutex, milliseconds)); +} diff --git a/contrib/ntp/lib/isc/win32/dir.c b/contrib/ntp/lib/isc/win32/dir.c new file mode 100644 index 000000000..14fadde46 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/dir.c @@ -0,0 +1,312 @@ +/* + * Copyright (C) 2004, 2007-2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* Principal Authors: DCL */ + +#include + +#include +#include +#include +#include + +#include + +#include +#include +#include +#include + +#include "errno2result.h" + +#define ISC_DIR_MAGIC ISC_MAGIC('D', 'I', 'R', '*') +#define VALID_DIR(dir) ISC_MAGIC_VALID(dir, ISC_DIR_MAGIC) + +static isc_result_t +start_directory(isc_dir_t *p); + +void +isc_dir_init(isc_dir_t *dir) { + REQUIRE(dir != NULL); + + dir->dirname[0] = '\0'; + + dir->entry.name[0] = '\0'; + dir->entry.length = 0; + memset(&(dir->entry.find_data), 0, sizeof(dir->entry.find_data)); + + dir->entry_filled = ISC_FALSE; + dir->search_handle = INVALID_HANDLE_VALUE; + + dir->magic = ISC_DIR_MAGIC; +} + +/* + * Allocate workspace and open directory stream. If either one fails, + * NULL will be returned. + */ +isc_result_t +isc_dir_open(isc_dir_t *dir, const char *dirname) { + char *p; + isc_result_t result; + + REQUIRE(dirname != NULL); + REQUIRE(VALID_DIR(dir) && dir->search_handle == INVALID_HANDLE_VALUE); + + /* + * Copy directory name. Need to have enough space for the name, + * a possible path separator, the wildcard, and the final NUL. + */ + if (strlen(dirname) + 3 > sizeof(dir->dirname)) + /* XXXDCL ? */ + return (ISC_R_NOSPACE); + strcpy(dir->dirname, dirname); + + /* + * Append path separator, if needed, and "*". + */ + p = dir->dirname + strlen(dir->dirname); + if (dir->dirname < p && *(p - 1) != '\\' && *(p - 1) != ':') + *p++ = '\\'; + *p++ = '*'; + *p = '\0'; + + /* + * Open stream. + */ + result = start_directory(dir); + + return (result); +} + +/* + * Return previously retrieved file or get next one. Unix's dirent has + * separate open and read functions, but the Win32 and DOS interfaces open + * the dir stream and reads the first file in one operation. + */ +isc_result_t +isc_dir_read(isc_dir_t *dir) { + REQUIRE(VALID_DIR(dir) && dir->search_handle != INVALID_HANDLE_VALUE); + + if (dir->entry_filled) + /* + * start_directory() already filled in the first entry. + */ + dir->entry_filled = ISC_FALSE; + + else { + /* + * Fetch next file in directory. + */ + if (FindNextFile(dir->search_handle, + &dir->entry.find_data) == FALSE) + /* + * Either the last file has been processed or + * an error has occurred. The former is not + * really an error, but the latter is. + */ + if (GetLastError() == ERROR_NO_MORE_FILES) + return (ISC_R_NOMORE); + else + return (ISC_R_UNEXPECTED); + } + + /* + * Make sure that the space for the name is long enough. + */ + strcpy(dir->entry.name, dir->entry.find_data.cFileName); + dir->entry.length = strlen(dir->entry.name); + + return (ISC_R_SUCCESS); +} + +/* + * Close directory stream. + */ +void +isc_dir_close(isc_dir_t *dir) { + REQUIRE(VALID_DIR(dir) && dir->search_handle != INVALID_HANDLE_VALUE); + + FindClose(dir->search_handle); + dir->search_handle = INVALID_HANDLE_VALUE; +} + +/* + * Reposition directory stream at start. + */ +isc_result_t +isc_dir_reset(isc_dir_t *dir) { + isc_result_t result; + + REQUIRE(VALID_DIR(dir) && dir->search_handle != INVALID_HANDLE_VALUE); + REQUIRE(dir->dirname != NULL); + + /* + * NT cannot reposition the seek pointer to the beginning of the + * the directory stream, but rather the directory needs to be + * closed and reopened. The latter might fail. + */ + + isc_dir_close(dir); + + result = start_directory(dir); + + return (result); +} + +/* + * Initialize isc_dir_t structure with new directory. The function + * returns 0 on failure and nonzero on success. + * + * Note: + * - Be sure to close previous stream before opening new one + */ +static isc_result_t +start_directory(isc_dir_t *dir) +{ + REQUIRE(VALID_DIR(dir)); + REQUIRE(dir->search_handle == INVALID_HANDLE_VALUE); + + dir->entry_filled = ISC_FALSE; + + /* + * Open stream and retrieve first file. + */ + dir->search_handle = FindFirstFile(dir->dirname, + &dir->entry.find_data); + + if (dir->search_handle == INVALID_HANDLE_VALUE) { + /* + * Something went wrong but we don't know what. GetLastError() + * could give us more information about the error, but the + * MSDN documentation is frustratingly thin about what + * possible errors could have resulted. (Score one for + * the Unix manual pages.) So there is just this lame error + * instead of being able to differentiate ISC_R_NOTFOUND + * from ISC_R_UNEXPECTED. + */ + return (ISC_R_FAILURE); + } + + /* + * Make sure that the space for the name is long enough. + */ + INSIST(sizeof(dir->entry.name) > + strlen(dir->entry.find_data.cFileName)); + + /* + * Fill in the data for the first entry of the directory. + */ + strcpy(dir->entry.name, dir->entry.find_data.cFileName); + dir->entry.length = strlen(dir->entry.name); + + dir->entry_filled = ISC_TRUE; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_dir_chdir(const char *dirname) { + /* + * Change the current directory to 'dirname'. + */ + + REQUIRE(dirname != NULL); + + if (chdir(dirname) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_dir_chroot(const char *dirname) { + return (ISC_R_NOTIMPLEMENTED); +} + +isc_result_t +isc_dir_createunique(char *templet) { + isc_result_t result; + char *x; + char *p; + int i; + int pid; + + REQUIRE(templet != NULL); + + /* + * mkdtemp is not portable, so this emulates it. + */ + + pid = getpid(); + + /* + * Replace trailing Xs with the process-id, zero-filled. + */ + for (x = templet + strlen(templet) - 1; *x == 'X' && x >= templet; + x--, pid /= 10) + *x = pid % 10 + '0'; + + x++; /* Set x to start of ex-Xs. */ + + do { + i = mkdir(templet); + i = chmod(templet, 0700); + + if (i == 0 || errno != EEXIST) + break; + + /* + * The BSD algorithm. + */ + p = x; + while (*p != '\0') { + if (isdigit(*p & 0xff)) + *p = 'a'; + else if (*p != 'z') + ++*p; + else { + /* + * Reset character and move to next. + */ + *p++ = 'a'; + continue; + } + + break; + } + + if (*p == '\0') { + /* + * Tried all combinations. errno should already + * be EEXIST, but ensure it is anyway for + * isc__errno2result(). + */ + errno = EEXIST; + break; + } + } while (1); + + if (i == -1) + result = isc__errno2result(errno); + else + result = ISC_R_SUCCESS; + + return (result); +} diff --git a/contrib/ntp/lib/isc/win32/entropy.c b/contrib/ntp/lib/isc/win32/entropy.c new file mode 100644 index 000000000..5a316e6e5 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/entropy.c @@ -0,0 +1,307 @@ +/* + * Copyright (C) 2004, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: entropy.c,v 1.10 2009/01/18 23:48:14 tbox Exp $ */ + +/* + * This is the system dependent part of the ISC entropy API. + */ + +#include + +#include +#include + +#include +#include +#include + +/* + * There is only one variable in the entropy data structures that is not + * system independent, but pulling the structure that uses it into this file + * ultimately means pulling several other independent structures here also to + * resolve their interdependencies. Thus only the problem variable's type + * is defined here. + */ +#define FILESOURCE_HANDLE_TYPE HCRYPTPROV + +typedef struct { + int dummy; +} isc_entropyusocketsource_t; + +#include "../entropy.c" + +static unsigned int +get_from_filesource(isc_entropysource_t *source, isc_uint32_t desired) { + isc_entropy_t *ent = source->ent; + unsigned char buf[128]; + HCRYPTPROV hcryptprov = source->sources.file.handle; + ssize_t ndesired; + unsigned int added; + + if (source->bad) + return (0); + + desired = desired / 8 + (((desired & 0x07) > 0) ? 1 : 0); + + added = 0; + while (desired > 0) { + ndesired = ISC_MIN(desired, sizeof(buf)); + if (!CryptGenRandom(hcryptprov, ndesired, buf)) { + CryptReleaseContext(hcryptprov, 0); + source->bad = ISC_TRUE; + goto out; + } + + entropypool_adddata(ent, buf, ndesired, ndesired * 8); + added += ndesired * 8; + desired -= ndesired; + } + + out: + return (added); +} + +/* + * Poll each source, trying to get data from it to stuff into the entropy + * pool. + */ +static void +fillpool(isc_entropy_t *ent, unsigned int desired, isc_boolean_t blocking) { + unsigned int added; + unsigned int remaining; + unsigned int needed; + unsigned int nsource; + isc_entropysource_t *source; + isc_entropysource_t *firstsource; + + REQUIRE(VALID_ENTROPY(ent)); + + needed = desired; + + /* + * This logic is a little strange, so an explanation is in order. + * + * If needed is 0, it means we are being asked to "fill to whatever + * we think is best." This means that if we have at least a + * partially full pool (say, > 1/4th of the pool) we probably don't + * need to add anything. + * + * Also, we will check to see if the "pseudo" count is too high. + * If it is, try to mix in better data. Too high is currently + * defined as 1/4th of the pool. + * + * Next, if we are asked to add a specific bit of entropy, make + * certain that we will do so. Clamp how much we try to add to + * (DIGEST_SIZE * 8 < needed < POOLBITS - entropy). + * + * Note that if we are in a blocking mode, we will only try to + * get as much data as we need, not as much as we might want + * to build up. + */ + if (needed == 0) { + REQUIRE(!blocking); + + if ((ent->pool.entropy >= RND_POOLBITS / 4) + && (ent->pool.pseudo <= RND_POOLBITS / 4)) + return; + + needed = THRESHOLD_BITS * 4; + } else { + needed = ISC_MAX(needed, THRESHOLD_BITS); + needed = ISC_MIN(needed, RND_POOLBITS); + } + + /* + * In any case, clamp how much we need to how much we can add. + */ + needed = ISC_MIN(needed, RND_POOLBITS - ent->pool.entropy); + + /* + * But wait! If we're not yet initialized, we need at least + * THRESHOLD_BITS + * of randomness. + */ + if (ent->initialized < THRESHOLD_BITS) + needed = ISC_MAX(needed, THRESHOLD_BITS - ent->initialized); + + /* + * Poll each file source to see if we can read anything useful from + * it. XXXMLG When where are multiple sources, we should keep a + * record of which one we last used so we can start from it (or the + * next one) to avoid letting some sources build up entropy while + * others are always drained. + */ + + added = 0; + remaining = needed; + if (ent->nextsource == NULL) { + ent->nextsource = ISC_LIST_HEAD(ent->sources); + if (ent->nextsource == NULL) + return; + } + source = ent->nextsource; + /* + * Remember the first source so we can break if we have looped back to + * the beginning and still have nothing + */ + firstsource = source; + again_file: + for (nsource = 0; nsource < ent->nsources; nsource++) { + unsigned int got; + + if (remaining == 0) + break; + + got = 0; + + if (source->type == ENTROPY_SOURCETYPE_FILE) + got = get_from_filesource(source, remaining); + + added += got; + + remaining -= ISC_MIN(remaining, got); + + source = ISC_LIST_NEXT(source, link); + if (source == NULL) + source = ISC_LIST_HEAD(ent->sources); + } + ent->nextsource = source; + + /* + * Go again only if there's been progress and we've not + * gone back to the beginning + */ + if (!(ent->nextsource == firstsource && added == 0)) { + if (blocking && remaining != 0) { + goto again_file; + } + } + + /* + * Here, if there are bits remaining to be had and we can block, + * check to see if we have a callback source. If so, call them. + */ + source = ISC_LIST_HEAD(ent->sources); + while ((remaining != 0) && (source != NULL)) { + unsigned int got; + + got = 0; + + if (source->type == ENTROPY_SOURCETYPE_CALLBACK) + got = get_from_callback(source, remaining, blocking); + + added += got; + remaining -= ISC_MIN(remaining, got); + + if (added >= needed) + break; + + source = ISC_LIST_NEXT(source, link); + } + + /* + * Mark as initialized if we've added enough data. + */ + if (ent->initialized < THRESHOLD_BITS) + ent->initialized += added; +} + + + +/* + * Requires "ent" be locked. + */ +static void +destroyfilesource(isc_entropyfilesource_t *source) { + CryptReleaseContext(source->handle, 0); +} + +static void +destroyusocketsource(isc_entropyusocketsource_t *source) { + UNUSED(source); +} + + +isc_result_t +isc_entropy_createfilesource(isc_entropy_t *ent, const char *fname) { + isc_result_t ret; + isc_entropysource_t *source; + HCRYPTPROV hcryptprov; + DWORD errval; + BOOL err; + + REQUIRE(VALID_ENTROPY(ent)); + REQUIRE(fname != NULL); + + LOCK(&ent->lock); + + source = NULL; + + /* + * The first time we just try to acquire the context + */ + err = CryptAcquireContext(&hcryptprov, NULL, NULL, PROV_RSA_FULL, + CRYPT_VERIFYCONTEXT); + if (!err){ + errval = GetLastError(); + ret = ISC_R_IOERROR; + goto errout; + } + + source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t)); + if (source == NULL) { + ret = ISC_R_NOMEMORY; + goto closecontext; + } + + /* + * From here down, no failures can occur. + */ + source->magic = SOURCE_MAGIC; + source->type = ENTROPY_SOURCETYPE_FILE; + source->ent = ent; + source->total = 0; + source->bad = ISC_FALSE; + memset(source->name, 0, sizeof(source->name)); + ISC_LINK_INIT(source, link); + source->sources.file.handle = hcryptprov; + + /* + * Hook it into the entropy system. + */ + ISC_LIST_APPEND(ent->sources, source, link); + ent->nsources++; + + UNLOCK(&ent->lock); + return (ISC_R_SUCCESS); + + closecontext: + CryptReleaseContext(hcryptprov, 0); + + errout: + if (source != NULL) + isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t)); + + UNLOCK(&ent->lock); + + return (ret); +} + + + + diff --git a/contrib/ntp/lib/isc/win32/errno2result.c b/contrib/ntp/lib/isc/win32/errno2result.c new file mode 100644 index 000000000..c3d54d632 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/errno2result.c @@ -0,0 +1,113 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: errno2result.c,v 1.17 2008/09/12 04:46:25 marka Exp $ */ + +#include + +#include +#include "errno2result.h" +#include +#include +#include + +/* + * Convert a POSIX errno value into an isc_result_t. The + * list of supported errno values is not complete; new users + * of this function should add any expected errors that are + * not already there. + */ +isc_result_t +isc__errno2resultx(int posixerrno, const char *file, int line) { + char strbuf[ISC_STRERRORSIZE]; + + switch (posixerrno) { + case ENOTDIR: + case WSAELOOP: + case WSAEINVAL: + case EINVAL: /* XXX sometimes this is not for files */ + case ENAMETOOLONG: + case WSAENAMETOOLONG: + case EBADF: + case WSAEBADF: + return (ISC_R_INVALIDFILE); + case ENOENT: + return (ISC_R_FILENOTFOUND); + case EACCES: + case WSAEACCES: + case EPERM: + return (ISC_R_NOPERM); + case EEXIST: + return (ISC_R_FILEEXISTS); + case EIO: + return (ISC_R_IOERROR); + case ENOMEM: + return (ISC_R_NOMEMORY); + case ENFILE: + case EMFILE: + case WSAEMFILE: + return (ISC_R_TOOMANYOPENFILES); + case ERROR_CANCELLED: + return (ISC_R_CANCELED); + case ERROR_CONNECTION_REFUSED: + case WSAECONNREFUSED: + return (ISC_R_CONNREFUSED); + case WSAENOTCONN: + case ERROR_CONNECTION_INVALID: + return (ISC_R_NOTCONNECTED); + case ERROR_HOST_UNREACHABLE: + case WSAEHOSTUNREACH: + return (ISC_R_HOSTUNREACH); + case ERROR_NETWORK_UNREACHABLE: + case WSAENETUNREACH: + return (ISC_R_NETUNREACH); + case ERROR_NO_NETWORK: + return (ISC_R_NETUNREACH); + case ERROR_PORT_UNREACHABLE: + return (ISC_R_HOSTUNREACH); + case ERROR_SEM_TIMEOUT: + return (ISC_R_TIMEDOUT); + case WSAECONNRESET: + case WSAENETRESET: + case WSAECONNABORTED: + case WSAEDISCON: + case ERROR_OPERATION_ABORTED: + case ERROR_CONNECTION_ABORTED: + case ERROR_REQUEST_ABORTED: + return (ISC_R_CONNECTIONRESET); + case WSAEADDRNOTAVAIL: + return (ISC_R_ADDRNOTAVAIL); + case ERROR_NETNAME_DELETED: + case WSAENETDOWN: + return (ISC_R_NETUNREACH); + case WSAEHOSTDOWN: + return (ISC_R_HOSTUNREACH); + case WSAENOBUFS: + return (ISC_R_NORESOURCES); + default: + isc__strerror(posixerrno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(file, line, "unable to convert errno " + "to isc_result: %d: %s", posixerrno, strbuf); + /* + * XXXDCL would be nice if perhaps this function could + * return the system's error string, so the caller + * might have something more descriptive than "unexpected + * error" to log with. + */ + return (ISC_R_UNEXPECTED); + } +} diff --git a/contrib/ntp/lib/isc/win32/errno2result.h b/contrib/ntp/lib/isc/win32/errno2result.h new file mode 100644 index 000000000..41682db39 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/errno2result.h @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: errno2result.h,v 1.10 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef UNIX_ERRNO2RESULT_H +#define UNIX_ERRNO2RESULT_H 1 + +/* XXXDCL this should be moved to lib/isc/include/isc/errno2result.h. */ + +#include /* Provides errno. */ + +#include +#include + +ISC_LANG_BEGINDECLS + +#define isc__errno2result(posixerrno) \ + isc__errno2resultx(posixerrno, __FILE__, __LINE__) + +isc_result_t +isc__errno2resultx(int posixerrno, const char *file, int line); + +ISC_LANG_ENDDECLS + +#endif /* UNIX_ERRNO2RESULT_H */ diff --git a/contrib/ntp/lib/isc/win32/file.c b/contrib/ntp/lib/isc/win32/file.c new file mode 100644 index 000000000..c6b9e4f56 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/file.c @@ -0,0 +1,619 @@ +/* + * Copyright (C) 2004, 2007, 2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#include + +#undef rename +#include +#include +#include +#include +#include + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include "errno2result.h" + +/* + * Emulate UNIX mkstemp, which returns an open FD to the new file + * + */ +static int +gettemp(char *path, int *doopen) { + char *start, *trv; + struct stat sbuf; + int pid; + + trv = strrchr(path, 'X'); + trv++; + pid = getpid(); + /* extra X's get set to 0's */ + while (*--trv == 'X') { + *trv = (pid % 10) + '0'; + pid /= 10; + } + /* + * check the target directory; if you have six X's and it + * doesn't exist this runs for a *very* long time. + */ + for (start = trv + 1;; --trv) { + if (trv <= path) + break; + if (*trv == '\\') { + *trv = '\0'; + if (stat(path, &sbuf)) + return (0); + if (!S_ISDIR(sbuf.st_mode)) { + errno = ENOTDIR; + return (0); + } + *trv = '\\'; + break; + } + } + + for (;;) { + if (doopen) { + if ((*doopen = + open(path, O_CREAT|O_EXCL|O_RDWR, + _S_IREAD | _S_IWRITE)) >= 0) + return (1); + if (errno != EEXIST) + return (0); + } else if (stat(path, &sbuf)) + return (errno == ENOENT ? 1 : 0); + + /* tricky little algorithm for backward compatibility */ + for (trv = start;;) { + if (!*trv) + return (0); + if (*trv == 'z') + *trv++ = 'a'; + else { + if (isdigit(*trv)) + *trv = 'a'; + else + ++*trv; + break; + } + } + } + /*NOTREACHED*/ +} + +static int +mkstemp(char *path) { + int fd; + + return (gettemp(path, &fd) ? fd : -1); +} + +/* + * XXXDCL As the API for accessing file statistics undoubtedly gets expanded, + * it might be good to provide a mechanism that allows for the results + * of a previous stat() to be used again without having to do another stat, + * such as perl's mechanism of using "_" in place of a file name to indicate + * that the results of the last stat should be used. But then you get into + * annoying MP issues. BTW, Win32 has stat(). + */ +static isc_result_t +file_stats(const char *file, struct stat *stats) { + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(file != NULL); + REQUIRE(stats != NULL); + + if (stat(file, stats) != 0) + result = isc__errno2result(errno); + + return (result); +} + +/* + * isc_file_safemovefile is needed to be defined here to ensure that + * any file with the new name is renamed to a backup name and then the + * rename is done. If all goes well then the backup can be deleted, + * otherwise it gets renamed back. + */ + +int +isc_file_safemovefile(const char *oldname, const char *newname) { + BOOL filestatus; + char buf[512]; + struct stat sbuf; + BOOL exists = FALSE; + int tmpfd; + + /* + * Make sure we have something to do + */ + if (stat(oldname, &sbuf) != 0) { + errno = ENOENT; + return (-1); + } + + /* + * Rename to a backup the new file if it still exists + */ + if (stat(newname, &sbuf) == 0) { + exists = TRUE; + strcpy(buf, newname); + strcat(buf, ".XXXXX"); + tmpfd = mkstemp(buf); + if (tmpfd > 0) + _close(tmpfd); + DeleteFile(buf); + _chmod(newname, _S_IREAD | _S_IWRITE); + + filestatus = MoveFile(newname, buf); + } + /* Now rename the file to the new name + */ + _chmod(oldname, _S_IREAD | _S_IWRITE); + + filestatus = MoveFile(oldname, newname); + if (filestatus == 0) { + /* + * Try to rename the backup back to the original name + * if the backup got created + */ + if (exists == TRUE) { + filestatus = MoveFile(buf, newname); + if (filestatus == 0) + errno = EACCES; + } + return (-1); + } + + /* + * Delete the backup file if it got created + */ + if (exists == TRUE) + filestatus = DeleteFile(buf); + return (0); +} + +isc_result_t +isc_file_getmodtime(const char *file, isc_time_t *time) { + int fh; + + REQUIRE(file != NULL); + REQUIRE(time != NULL); + + if ((fh = open(file, _O_RDONLY | _O_BINARY)) < 0) + return (isc__errno2result(errno)); + + if (!GetFileTime((HANDLE) _get_osfhandle(fh), + NULL, + NULL, + &time->absolute)) + { + close(fh); + errno = EINVAL; + return (isc__errno2result(errno)); + } + close(fh); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_settime(const char *file, isc_time_t *time) { + int fh; + + REQUIRE(file != NULL && time != NULL); + + if ((fh = open(file, _O_RDWR | _O_BINARY)) < 0) + return (isc__errno2result(errno)); + + /* + * Set the date via the filedate system call and return. Failing + * this call implies the new file times are not supported by the + * underlying file system. + */ + if (!SetFileTime((HANDLE) _get_osfhandle(fh), + NULL, + &time->absolute, + &time->absolute)) + { + close(fh); + errno = EINVAL; + return (isc__errno2result(errno)); + } + + close(fh); + return (ISC_R_SUCCESS); + +} + +#undef TEMPLATE +#define TEMPLATE "XXXXXXXXXX.tmp" /* 14 characters. */ + +isc_result_t +isc_file_mktemplate(const char *path, char *buf, size_t buflen) { + return (isc_file_template(path, TEMPLATE, buf, buflen)); +} + +isc_result_t +isc_file_template(const char *path, const char *templet, char *buf, + size_t buflen) { + char *s; + + REQUIRE(path != NULL); + REQUIRE(templet != NULL); + REQUIRE(buf != NULL); + + s = strrchr(templet, '\\'); + if (s != NULL) + templet = s + 1; + + s = strrchr(path, '\\'); + + if (s != NULL) { + if ((s - path + 1 + strlen(templet) + 1) > buflen) + return (ISC_R_NOSPACE); + + strncpy(buf, path, s - path + 1); + buf[s - path + 1] = '\0'; + strcat(buf, templet); + } else { + if ((strlen(templet) + 1) > buflen) + return (ISC_R_NOSPACE); + + strcpy(buf, templet); + } + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_renameunique(const char *file, char *templet) { + int fd = -1; + int res = 0; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(file != NULL); + REQUIRE(templet != NULL); + + fd = mkstemp(templet); + if (fd == -1) + result = isc__errno2result(errno); + else + close(fd); + + if (result == ISC_R_SUCCESS) { + res = isc_file_safemovefile(file, templet); + if (res != 0) { + result = isc__errno2result(errno); + (void)unlink(templet); + } + } + return (result); +} + +isc_result_t +isc_file_openuniqueprivate(char *templet, FILE **fp) { + int mode = _S_IREAD | _S_IWRITE; + return (isc_file_openuniquemode(templet, mode, fp)); +} + +isc_result_t +isc_file_openunique(char *templet, FILE **fp) { + int mode = _S_IREAD | _S_IWRITE; + return (isc_file_openuniquemode(templet, mode, fp)); +} + +isc_result_t +isc_file_openuniquemode(char *templet, int mode, FILE **fp) { + int fd; + FILE *f; + isc_result_t result = ISC_R_SUCCESS; + + REQUIRE(templet != NULL); + REQUIRE(fp != NULL && *fp == NULL); + + /* + * Win32 does not have mkstemp. Using emulation above. + */ + fd = mkstemp(templet); + + if (fd == -1) + result = isc__errno2result(errno); + if (result == ISC_R_SUCCESS) { +#if 1 + UNUSED(mode); +#else + (void)fchmod(fd, mode); +#endif + f = fdopen(fd, "w+"); + if (f == NULL) { + result = isc__errno2result(errno); + (void)remove(templet); + (void)close(fd); + } else + *fp = f; + } + + return (result); +} + +isc_result_t +isc_file_remove(const char *filename) { + int r; + + REQUIRE(filename != NULL); + + r = unlink(filename); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_file_rename(const char *oldname, const char *newname) { + int r; + + REQUIRE(oldname != NULL); + REQUIRE(newname != NULL); + + r = isc_file_safemovefile(oldname, newname); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_boolean_t +isc_file_exists(const char *pathname) { + struct stat stats; + + REQUIRE(pathname != NULL); + + return (ISC_TF(file_stats(pathname, &stats) == ISC_R_SUCCESS)); +} + +isc_result_t +isc_file_isplainfile(const char *filename) { + /* + * This function returns success if filename is a plain file. + */ + struct stat filestat; + memset(&filestat,0,sizeof(struct stat)); + + if ((stat(filename, &filestat)) == -1) + return(isc__errno2result(errno)); + + if(! S_ISREG(filestat.st_mode)) + return(ISC_R_INVALIDFILE); + + return(ISC_R_SUCCESS); +} + +isc_boolean_t +isc_file_isabsolute(const char *filename) { + REQUIRE(filename != NULL); + /* + * Look for c:\path\... style, c:/path/... or \\computer\shar\path... + * the UNC style file specs + */ + if ((filename[0] == '\\') && (filename[1] == '\\')) + return (ISC_TRUE); + if (isalpha(filename[0]) && filename[1] == ':' && filename[2] == '\\') + return (ISC_TRUE); + if (isalpha(filename[0]) && filename[1] == ':' && filename[2] == '/') + return (ISC_TRUE); + return (ISC_FALSE); +} + +isc_boolean_t +isc_file_iscurrentdir(const char *filename) { + REQUIRE(filename != NULL); + return (ISC_TF(filename[0] == '.' && filename[1] == '\0')); +} + +isc_boolean_t +isc_file_ischdiridempotent(const char *filename) { + REQUIRE(filename != NULL); + + if (isc_file_isabsolute(filename)) + return (ISC_TRUE); + if (filename[0] == '\\') + return (ISC_TRUE); + if (filename[0] == '/') + return (ISC_TRUE); + if (isc_file_iscurrentdir(filename)) + return (ISC_TRUE); + return (ISC_FALSE); +} + +const char * +isc_file_basename(const char *filename) { + char *s; + + REQUIRE(filename != NULL); + + s = strrchr(filename, '\\'); + if (s == NULL) + return (filename); + return (s + 1); +} + +isc_result_t +isc_file_progname(const char *filename, char *progname, size_t namelen) { + const char *s; + char *p; + size_t len; + + REQUIRE(filename != NULL); + REQUIRE(progname != NULL); + + /* + * Strip the path from the name + */ + s = isc_file_basename(filename); + if (s == NULL) { + return (ISC_R_NOSPACE); + } + + /* + * Strip any and all suffixes + */ + p = strchr(s, '.'); + if (p == NULL) { + if (namelen <= strlen(s)) + return (ISC_R_NOSPACE); + + strcpy(progname, s); + return (ISC_R_SUCCESS); + } + + /* + * Copy the result to the buffer + */ + len = p - s; + if (len >= namelen) + return (ISC_R_NOSPACE); + + strncpy(progname, s, len); + progname[len] = '\0'; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_absolutepath(const char *filename, char *path, size_t pathlen) { + char *ptrname; + DWORD retval; + + REQUIRE(filename != NULL); + REQUIRE(path != NULL); + + retval = GetFullPathName(filename, pathlen, path, &ptrname); + + /* Something went wrong in getting the path */ + if (retval == 0) + return (ISC_R_NOTFOUND); + /* Caller needs to provide a larger buffer to contain the string */ + if (retval >= pathlen) + return (ISC_R_NOSPACE); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_truncate(const char *filename, isc_offset_t size) { + int fh; + + REQUIRE(filename != NULL && size >= 0); + + if ((fh = open(filename, _O_RDWR | _O_BINARY)) < 0) + return (isc__errno2result(errno)); + + if(_chsize(fh, size) != 0) { + close(fh); + return (isc__errno2result(errno)); + } + close(fh); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_safecreate(const char *filename, FILE **fp) { + isc_result_t result; + int flags; + struct stat sb; + FILE *f; + int fd; + + REQUIRE(filename != NULL); + REQUIRE(fp != NULL && *fp == NULL); + + result = file_stats(filename, &sb); + if (result == ISC_R_SUCCESS) { + if ((sb.st_mode & S_IFREG) == 0) + return (ISC_R_INVALIDFILE); + flags = O_WRONLY | O_TRUNC; + } else if (result == ISC_R_FILENOTFOUND) { + flags = O_WRONLY | O_CREAT | O_EXCL; + } else + return (result); + + fd = open(filename, flags, S_IRUSR | S_IWUSR); + if (fd == -1) + return (isc__errno2result(errno)); + + f = fdopen(fd, "w"); + if (f == NULL) { + result = isc__errno2result(errno); + close(fd); + return (result); + } + + *fp = f; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_file_splitpath(isc_mem_t *mctx, char *path, char **dirname, char **basename) +{ + char *dir, *file, *slash; + char *backslash; + + slash = strrchr(path, '/'); + + backslash = strrchr(path, '\\'); + if ((slash != NULL && backslash != NULL && backslash > slash) || + (slash == NULL && backslash != NULL)) + slash = backslash; + + if (slash == path) { + file = ++slash; + dir = isc_mem_strdup(mctx, "/"); + } else if (slash != NULL) { + file = ++slash; + dir = isc_mem_allocate(mctx, slash - path); + if (dir != NULL) + strlcpy(dir, path, slash - path); + } else { + file = path; + dir = isc_mem_strdup(mctx, "."); + } + + if (dir == NULL) + return (ISC_R_NOMEMORY); + + if (*file == '\0') { + isc_mem_free(mctx, dir); + return (ISC_R_INVALIDFILE); + } + + *dirname = dir; + *basename = file; + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/win32/fsaccess.c b/contrib/ntp/lib/isc/win32/fsaccess.c new file mode 100644 index 000000000..8de793f0a --- /dev/null +++ b/contrib/ntp/lib/isc/win32/fsaccess.c @@ -0,0 +1,375 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: fsaccess.c,v 1.15 2007/06/19 23:47:19 tbox Exp $ */ + +/* + * Note that Win32 does not have the concept of files having access + * and ownership bits. The FAT File system only has a readonly flag + * for everyone and that's all. NTFS uses ACL's which is a totally + * different concept of controlling access. + * + * This code needs to be revisited to set up proper access control for + * NTFS file systems. Nothing can be done for FAT file systems. + */ + +#include + +#include + +#include +#include +#include +#include + +#include +#include + +#include "errno2result.h" + +/* + * The OS-independent part of the API is in lib/isc. + */ +#include "../fsaccess.c" + +/* Store the user account name locally */ +static char username[255] = "\0"; +static DWORD namelen = 0; + +/* + * In order to set or retrieve access information, we need to obtain + * the File System type. These could be UNC-type shares. + */ + +BOOL +is_ntfs(const char * file) { + + char drive[255]; + char FSType[20]; + char tmpbuf[256]; + char *machinename; + char *sharename; + char filename[1024]; + + REQUIRE(filename != NULL); + + if (isc_file_absolutepath(file, filename, + sizeof(filename)) != ISC_R_SUCCESS) { + return (FALSE); + } + + /* + * Look for c:\path\... style, c:/path/... or \\computer\shar\path... + * the UNC style file specs + */ + if (isalpha(filename[0]) && filename[1] == ':' && + (filename[2] == '\\' || filename[2] == '/')) { + strncpy(drive, filename, 3); + drive[3] = '\0'; + } + + else if ((filename[0] == '\\') && (filename[1] == '\\')) { + /* Find the machine and share name and rebuild the UNC */ + strcpy(tmpbuf, filename); + machinename = strtok(tmpbuf, "\\"); + sharename = strtok(NULL, "\\"); + strcpy(drive, "\\\\"); + strcat(drive, machinename); + strcat(drive, "\\"); + strcat(drive, sharename); + strcat(drive, "\\"); + + } + else /* Not determinable */ + return (FALSE); + + GetVolumeInformation(drive, NULL, 0, NULL, 0, NULL, FSType, + sizeof(FSType)); + if(strcmp(FSType,"NTFS") == 0) + return (TRUE); + else + return (FALSE); +} + +/* + * If it's not NTFS, we assume that it is FAT and proceed + * with almost nothing to do. Only the write flag can be set or + * cleared. + */ +isc_result_t +FAT_fsaccess_set(const char *path, isc_fsaccess_t access) { + int mode; + isc_fsaccess_t bits; + + /* + * Done with checking bad bits. Set mode_t. + */ + mode = 0; + +#define SET_AND_CLEAR1(modebit) \ + if ((access & bits) != 0) { \ + mode |= modebit; \ + access &= ~bits; \ + } +#define SET_AND_CLEAR(user, group, other) \ + SET_AND_CLEAR1(user); \ + bits <<= STEP; \ + SET_AND_CLEAR1(group); \ + bits <<= STEP; \ + SET_AND_CLEAR1(other); + + bits = ISC_FSACCESS_READ | ISC_FSACCESS_LISTDIRECTORY; + + SET_AND_CLEAR(S_IRUSR, S_IRGRP, S_IROTH); + + bits = ISC_FSACCESS_WRITE | + ISC_FSACCESS_CREATECHILD | + ISC_FSACCESS_DELETECHILD; + + SET_AND_CLEAR(S_IWUSR, S_IWGRP, S_IWOTH); + + INSIST(access == 0); + + if (_chmod(path, mode) < 0) + return (isc__errno2result(errno)); + + return (ISC_R_SUCCESS); +} + +isc_result_t +NTFS_Access_Control(const char *filename, const char *user, int access, + isc_boolean_t isdir) { + SECURITY_DESCRIPTOR sd; + BYTE aclBuffer[1024]; + PACL pacl=(PACL)&aclBuffer; + BYTE sidBuffer[100]; + PSID psid=(PSID) &sidBuffer; + DWORD sidBufferSize = sizeof(sidBuffer); + BYTE adminSidBuffer[100]; + PSID padminsid=(PSID) &adminSidBuffer; + DWORD adminSidBufferSize = sizeof(adminSidBuffer); + BYTE otherSidBuffer[100]; + PSID pothersid=(PSID) &otherSidBuffer; + DWORD otherSidBufferSize = sizeof(otherSidBuffer); + char domainBuffer[100]; + DWORD domainBufferSize = sizeof(domainBuffer); + SID_NAME_USE snu; + int errval; + DWORD NTFSbits; + int caccess; + + + /* Initialize an ACL */ + if (!InitializeSecurityDescriptor(&sd, SECURITY_DESCRIPTOR_REVISION)) + return (ISC_R_NOPERM); + if (!InitializeAcl(pacl, sizeof(aclBuffer), ACL_REVISION)) + return (ISC_R_NOPERM); + if (!LookupAccountName(0, user, psid, &sidBufferSize, domainBuffer, + &domainBufferSize, &snu)) + return (ISC_R_NOPERM); + domainBufferSize = sizeof(domainBuffer); + if (!LookupAccountName(0, "Administrators", padminsid, + &adminSidBufferSize, domainBuffer, &domainBufferSize, &snu)) { + errval = GetLastError(); + return (ISC_R_NOPERM); + } + domainBufferSize = sizeof(domainBuffer); + if (!LookupAccountName(0, "Everyone", pothersid, + &otherSidBufferSize, domainBuffer, &domainBufferSize, &snu)) { + errval = GetLastError(); + return (ISC_R_NOPERM); + } + + caccess = access; + /* Owner check */ + + NTFSbits = 0; + if (caccess & ISC_FSACCESS_READ) + NTFSbits |= FILE_GENERIC_READ; + if (caccess & ISC_FSACCESS_WRITE) + NTFSbits |= FILE_GENERIC_WRITE; + if (caccess & ISC_FSACCESS_EXECUTE) + NTFSbits |= FILE_GENERIC_EXECUTE; + + /* For directories check the directory-specific bits */ + if (isdir == ISC_TRUE) { + if (caccess & ISC_FSACCESS_CREATECHILD) + NTFSbits |= FILE_ADD_SUBDIRECTORY | FILE_ADD_FILE; + if (caccess & ISC_FSACCESS_DELETECHILD) + NTFSbits |= FILE_DELETE_CHILD; + if (caccess & ISC_FSACCESS_LISTDIRECTORY) + NTFSbits |= FILE_LIST_DIRECTORY; + if (caccess & ISC_FSACCESS_ACCESSCHILD) + NTFSbits |= FILE_TRAVERSE; + } + + if (NTFSbits == (FILE_GENERIC_READ | FILE_GENERIC_WRITE + | FILE_GENERIC_EXECUTE)) + NTFSbits |= FILE_ALL_ACCESS; + /* + * Owner and Administrator also get STANDARD_RIGHTS_ALL + * to ensure that they have full control + */ + + NTFSbits |= STANDARD_RIGHTS_ALL; + + /* Add the ACE to the ACL */ + if (!AddAccessAllowedAce(pacl, ACL_REVISION, NTFSbits, psid)) + return (ISC_R_NOPERM); + if (!AddAccessAllowedAce(pacl, ACL_REVISION, NTFSbits, padminsid)) + return (ISC_R_NOPERM); + + /* + * Group is ignored since we can be in multiple groups or no group + * and its meaning is not clear on Win32 + */ + + caccess = caccess >> STEP; + + /* + * Other check. We translate this to be the same as Everyone + */ + + caccess = caccess >> STEP; + + NTFSbits = 0; + if (caccess & ISC_FSACCESS_READ) + NTFSbits |= FILE_GENERIC_READ; + if (caccess & ISC_FSACCESS_WRITE) + NTFSbits |= FILE_GENERIC_WRITE; + if (caccess & ISC_FSACCESS_EXECUTE) + NTFSbits |= FILE_GENERIC_EXECUTE; + + /* For directories check the directory-specific bits */ + if (isdir == TRUE) { + if (caccess & ISC_FSACCESS_CREATECHILD) + NTFSbits |= FILE_ADD_SUBDIRECTORY | FILE_ADD_FILE; + if (caccess & ISC_FSACCESS_DELETECHILD) + NTFSbits |= FILE_DELETE_CHILD; + if (caccess & ISC_FSACCESS_LISTDIRECTORY) + NTFSbits |= FILE_LIST_DIRECTORY; + if (caccess & ISC_FSACCESS_ACCESSCHILD) + NTFSbits |= FILE_TRAVERSE; + } + /* Add the ACE to the ACL */ + if (!AddAccessAllowedAce(pacl, ACL_REVISION, NTFSbits, + pothersid)) + return (ISC_R_NOPERM); + + if (!SetSecurityDescriptorDacl(&sd, TRUE, pacl, FALSE)) + return (ISC_R_NOPERM); + if (!SetFileSecurity(filename, DACL_SECURITY_INFORMATION, &sd)) { + return (ISC_R_NOPERM); + } + + return(ISC_R_SUCCESS); +} + +isc_result_t +NTFS_fsaccess_set(const char *path, isc_fsaccess_t access, + isc_boolean_t isdir){ + + /* + * For NTFS we first need to get the name of the account under + * which BIND is running + */ + if (namelen <= 0) { + namelen = sizeof(username); + if (GetUserName(username, &namelen) == 0) + return (ISC_R_FAILURE); + } + return (NTFS_Access_Control(path, username, access, isdir)); +} + +isc_result_t +isc_fsaccess_set(const char *path, isc_fsaccess_t access) { + struct stat statb; + isc_boolean_t is_dir = ISC_FALSE; + isc_result_t result; + + if (stat(path, &statb) != 0) + return (isc__errno2result(errno)); + + if ((statb.st_mode & S_IFDIR) != 0) + is_dir = ISC_TRUE; + else if ((statb.st_mode & S_IFREG) == 0) + return (ISC_R_INVALIDFILE); + + result = check_bad_bits(access, is_dir); + if (result != ISC_R_SUCCESS) + return (result); + + /* + * Determine if this is a FAT or NTFS disk and + * call the appropriate function to set the permissions + */ + if (is_ntfs(path)) + return (NTFS_fsaccess_set(path, access, is_dir)); + else + return (FAT_fsaccess_set(path, access)); +} + +isc_result_t +isc_fsaccess_changeowner(const char *filename, const char *user) { + SECURITY_DESCRIPTOR psd; + BYTE sidBuffer[500]; + BYTE groupBuffer[500]; + PSID psid=(PSID) &sidBuffer; + DWORD sidBufferSize = sizeof(sidBuffer); + char domainBuffer[100]; + DWORD domainBufferSize = sizeof(domainBuffer); + SID_NAME_USE snu; + PSID pSidGroup = (PSID) &groupBuffer; + DWORD groupBufferSize = sizeof(groupBuffer); + + + /* + * Determine if this is a FAT or NTFS disk and + * call the appropriate function to set the ownership + * FAT disks do not have ownership attributes so it's + * a noop. + */ + if (is_ntfs(filename) == FALSE) + return (ISC_R_SUCCESS); + + if (!InitializeSecurityDescriptor(&psd, SECURITY_DESCRIPTOR_REVISION)) + return (ISC_R_NOPERM); + + if (!LookupAccountName(0, user, psid, &sidBufferSize, domainBuffer, + &domainBufferSize, &snu)) + return (ISC_R_NOPERM); + + /* Make sure administrators can get to it */ + domainBufferSize = sizeof(domainBuffer); + if (!LookupAccountName(0, "Administrators", pSidGroup, + &groupBufferSize, domainBuffer, &domainBufferSize, &snu)) + return (ISC_R_NOPERM); + + if (!SetSecurityDescriptorOwner(&psd, psid, FALSE)) + return (ISC_R_NOPERM); + + if (!SetSecurityDescriptorGroup(&psd, pSidGroup, FALSE)) + return (ISC_R_NOPERM); + + if (!SetFileSecurity(filename, + OWNER_SECURITY_INFORMATION | GROUP_SECURITY_INFORMATION, + &psd)) + return (ISC_R_NOPERM); + + return (ISC_R_SUCCESS); +} + diff --git a/contrib/ntp/lib/isc/win32/include/isc/bind_registry.h b/contrib/ntp/lib/isc/win32/include/isc/bind_registry.h new file mode 100644 index 000000000..c4dc8768d --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/bind_registry.h @@ -0,0 +1,50 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bind_registry.h,v 1.8 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_BINDREGISTRY_H +#define ISC_BINDREGISTRY_H + +/* + * BIND makes use of the following Registry keys in various places, especially + * during startup and installation + */ + +#define BIND_SUBKEY "Software\\ISC\\BIND" +#define BIND_SESSION "CurrentSession" +#define BIND_SESSION_SUBKEY "Software\\ISC\\BIND\\CurrentSession" +#define BIND_UNINSTALL_SUBKEY \ + "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\ISC BIND" + +#define EVENTLOG_APP_SUBKEY \ + "SYSTEM\\CurrentControlSet\\Services\\EventLog\\Application" +#define BIND_MESSAGE_SUBKEY \ + "SYSTEM\\CurrentControlSet\\Services\\EventLog\\Application\\named" +#define BIND_MESSAGE_NAME "named" + +#define BIND_SERVICE_SUBKEY \ + "SYSTEM\\CurrentControlSet\\Services\\named" + + +#define BIND_CONFIGFILE 0 +#define BIND_DEBUGLEVEL 1 +#define BIND_QUERYLOG 2 +#define BIND_FOREGROUND 3 +#define BIND_PORT 4 + +#endif /* ISC_BINDREGISTRY_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/bindevt.h b/contrib/ntp/lib/isc/win32/include/isc/bindevt.h new file mode 100644 index 000000000..72cf2d1fc --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/bindevt.h @@ -0,0 +1,91 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: bindevt.h,v 1.6 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_BINDEVT_H +#define ISC_BINDEVT_H 1 + +/* + * This is used for the event log for both logging the messages and + * later on by the event viewer when looking at the events + */ + +/* + * Values are 32 bit values layed out as follows: + * + * 3 3 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 1 1 1 1 + * 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 + * +---+-+-+-----------------------+-------------------------------+ + * |Sev|C|R| Facility | Code | + * +---+-+-+-----------------------+-------------------------------+ + * + * where + * + * Sev - is the severity code + * + * 00 - Success + * 01 - Informational + * 10 - Warning + * 11 - Error + * + * C - is the Customer code flag + * + * R - is a reserved bit + * + * Facility - is the facility code + * + * Code - is the facility's status code + * + * + * Define the facility codes + */ + + +/* + * Define the severity codes + */ + + +/* + * MessageId: BIND_ERR_MSG + * + * MessageText: + * + * %1 + */ +#define BIND_ERR_MSG ((DWORD)0xC0000001L) + +/* + * MessageId: BIND_WARN_MSG + * + * MessageText: + * + * %1 + */ +#define BIND_WARN_MSG ((DWORD)0x80000002L) + +/* + * MessageId: BIND_INFO_MSG + * + * MessageText: + * + * %1 + */ +#define BIND_INFO_MSG ((DWORD)0x40000003L) + +#endif /* ISC_BINDEVT_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/condition.h b/contrib/ntp/lib/isc/win32/include/isc/condition.h new file mode 100644 index 000000000..34015bc26 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/condition.h @@ -0,0 +1,67 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: condition.h,v 1.17 2007/06/18 23:47:49 tbox Exp $ */ + +#ifndef ISC_CONDITION_H +#define ISC_CONDITION_H 1 + +#include + +#include +#include +#include +#include + +typedef struct isc_condition_thread isc_condition_thread_t; + +struct isc_condition_thread { + unsigned long th; + HANDLE handle[2]; + ISC_LINK(isc_condition_thread_t) link; + +}; + +typedef struct isc_condition { + HANDLE events[2]; + unsigned int waiters; + ISC_LIST(isc_condition_thread_t) threadlist; +} isc_condition_t; + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_condition_init(isc_condition_t *); + +isc_result_t +isc_condition_wait(isc_condition_t *, isc_mutex_t *); + +isc_result_t +isc_condition_signal(isc_condition_t *); + +isc_result_t +isc_condition_broadcast(isc_condition_t *); + +isc_result_t +isc_condition_destroy(isc_condition_t *); + +isc_result_t +isc_condition_waituntil(isc_condition_t *, isc_mutex_t *, isc_time_t *); + +ISC_LANG_ENDDECLS + +#endif /* ISC_CONDITION_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/dir.h b/contrib/ntp/lib/isc/win32/include/isc/dir.h new file mode 100644 index 000000000..653427a97 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/dir.h @@ -0,0 +1,83 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: dir.h,v 1.15 2007/06/19 23:47:20 tbox Exp $ */ + +/* Principal Authors: DCL */ + +#ifndef ISC_DIR_H +#define ISC_DIR_H 1 + +#include +#include + +#include +#include +#include + +#define ISC_DIR_NAMEMAX _MAX_FNAME +#define ISC_DIR_PATHMAX _MAX_PATH + +typedef struct { + char name[ISC_DIR_NAMEMAX]; + unsigned int length; + WIN32_FIND_DATA find_data; +} isc_direntry_t; + +typedef struct { + unsigned int magic; + char dirname[ISC_DIR_PATHMAX]; + isc_direntry_t entry; + isc_boolean_t entry_filled; + HANDLE search_handle; +} isc_dir_t; + +ISC_LANG_BEGINDECLS + +void +isc_dir_init(isc_dir_t *dir); + +isc_result_t +isc_dir_open(isc_dir_t *dir, const char *dirname); + +isc_result_t +isc_dir_read(isc_dir_t *dir); + +isc_result_t +isc_dir_reset(isc_dir_t *dir); + +void +isc_dir_close(isc_dir_t *dir); + +isc_result_t +isc_dir_chdir(const char *dirname); + +isc_result_t +isc_dir_chroot(const char *dirname); + +isc_result_t +isc_dir_createunique(char *templet); +/* + * Use a templet (such as from isc_file_mktemplate()) to create a uniquely + * named, empty directory. The templet string is modified in place. + * If result == ISC_R_SUCCESS, it is the name of the directory that was + * created. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_DIR_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/int.h b/contrib/ntp/lib/isc/win32/include/isc/int.h new file mode 100644 index 000000000..2ee8bf96a --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/int.h @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: int.h,v 1.13 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_INT_H +#define ISC_INT_H 1 + +#define _INTEGRAL_MAX_BITS 64 +#include + +typedef __int8 isc_int8_t; +typedef unsigned __int8 isc_uint8_t; +typedef __int16 isc_int16_t; +typedef unsigned __int16 isc_uint16_t; +typedef __int32 isc_int32_t; +typedef unsigned __int32 isc_uint32_t; +typedef __int64 isc_int64_t; +typedef unsigned __int64 isc_uint64_t; + +#define ISC_INT8_MIN -128 +#define ISC_INT8_MAX 127 +#define ISC_UINT8_MAX 255 + +#define ISC_INT16_MIN -32768 +#define ISC_INT16_MAX 32767 +#define ISC_UINT16_MAX 65535 + +/* + * Note that "int" is 32 bits on all currently supported Unix-like operating + * systems, but "long" can be either 32 bits or 64 bits, thus the 32 bit + * constants are not qualified with "L". + */ +#define ISC_INT32_MIN _I32_MIN +#define ISC_INT32_MAX _I32_MAX +#define ISC_UINT32_MAX _UI32_MAX + +#define ISC_INT64_MIN _I64_MIN +#define ISC_INT64_MAX _I64_MAX +#define ISC_UINT64_MAX _UI64_MAX + +#endif /* ISC_INT_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/ipv6.h b/contrib/ntp/lib/isc/win32/include/isc/ipv6.h new file mode 100644 index 000000000..27384a355 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/ipv6.h @@ -0,0 +1,124 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_IPV6_H +#define ISC_IPV6_H 1 + +/***** + ***** Module Info + *****/ + +/* + * IPv6 definitions for systems which do not support IPv6. + * + * MP: + * No impact. + * + * Reliability: + * No anticipated impact. + * + * Resources: + * N/A. + * + * Security: + * No anticipated impact. + * + * Standards: + * RFC2553. + */ + +#if _MSC_VER < 1300 +#define in6_addr in_addr6 +#endif + +#ifndef IN6ADDR_ANY_INIT +#define IN6ADDR_ANY_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }} +#endif +#ifndef IN6ADDR_LOOPBACK_INIT +#define IN6ADDR_LOOPBACK_INIT {{ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1 }} +#endif + +LIBISC_EXTERNAL_DATA extern const struct in6_addr isc_net_in6addrany; +LIBISC_EXTERNAL_DATA extern const struct in6_addr isc_net_in6addrloop; + +/* + * Unspecified + */ +#ifndef IN6_IS_ADDR_UNSPECIFIED +#define IN6_IS_ADDR_UNSPECIFIED(a) (\ +*((u_long *)((a)->s6_addr) ) == 0 && \ +*((u_long *)((a)->s6_addr) + 1) == 0 && \ +*((u_long *)((a)->s6_addr) + 2) == 0 && \ +*((u_long *)((a)->s6_addr) + 3) == 0 \ +) +#endif + +/* + * Loopback + */ +#ifndef IN6_IS_ADDR_LOOPBACK +#define IN6_IS_ADDR_LOOPBACK(a) (\ +*((u_long *)((a)->s6_addr) ) == 0 && \ +*((u_long *)((a)->s6_addr) + 1) == 0 && \ +*((u_long *)((a)->s6_addr) + 2) == 0 && \ +*((u_long *)((a)->s6_addr) + 3) == htonl(1) \ +) +#endif + +/* + * IPv4 compatible + */ +#define IN6_IS_ADDR_V4COMPAT(a) (\ +*((u_long *)((a)->s6_addr) ) == 0 && \ +*((u_long *)((a)->s6_addr) + 1) == 0 && \ +*((u_long *)((a)->s6_addr) + 2) == 0 && \ +*((u_long *)((a)->s6_addr) + 3) != 0 && \ +*((u_long *)((a)->s6_addr) + 3) != htonl(1) \ +) + +/* + * Mapped + */ +#define IN6_IS_ADDR_V4MAPPED(a) (\ +*((u_long *)((a)->s6_addr) ) == 0 && \ +*((u_long *)((a)->s6_addr) + 1) == 0 && \ +*((u_long *)((a)->s6_addr) + 2) == htonl(0x0000ffff)) + +/* + * Multicast + */ +#define IN6_IS_ADDR_MULTICAST(a) \ + ((a)->s6_addr[0] == 0xffU) + +/* + * Unicast link / site local. + */ +#ifndef IN6_IS_ADDR_LINKLOCAL +#define IN6_IS_ADDR_LINKLOCAL(a) (\ + ((a)->s6_addr[0] == 0xfe) && \ + (((a)->s6_addr[1] & 0xc0) == 0x80)) +#endif + +#ifndef IN6_IS_ADDR_SITELOCAL +#define IN6_IS_ADDR_SITELOCAL(a) (\ + ((a)->s6_addr[0] == 0xfe) && \ + (((a)->s6_addr[1] & 0xc0) == 0xc0)) +#endif + +#endif /* ISC_IPV6_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/keyboard.h b/contrib/ntp/lib/isc/win32/include/isc/keyboard.h new file mode 100644 index 000000000..e781c5fa1 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/keyboard.h @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: keyboard.h,v 1.6 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_KEYBOARD_H +#define ISC_KEYBOARD_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +typedef struct { + int fd; + isc_result_t result; +} isc_keyboard_t; + +isc_result_t +isc_keyboard_open(isc_keyboard_t *keyboard); + +isc_result_t +isc_keyboard_close(isc_keyboard_t *keyboard, unsigned int sleepseconds); + +isc_result_t +isc_keyboard_getchar(isc_keyboard_t *keyboard, unsigned char *cp); + +isc_boolean_t +isc_keyboard_canceled(isc_keyboard_t *keyboard); + +ISC_LANG_ENDDECLS + +#endif /* ISC_KEYBOARD_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/mutex.h b/contrib/ntp/lib/isc/win32/include/isc/mutex.h new file mode 100644 index 000000000..5cf1bae1b --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/mutex.h @@ -0,0 +1,55 @@ +/* + * Copyright (C) 2004, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: mutex.h,v 1.22 2009/01/18 23:48:14 tbox Exp $ */ + +#ifndef ISC_MUTEX_H +#define ISC_MUTEX_H 1 + +#include +#include + +#include + +typedef CRITICAL_SECTION isc_mutex_t; + +/* + * This definition is here since some versions of WINBASE.H + * omits it for some reason. + */ +#if (_WIN32_WINNT < 0x0400) +WINBASEAPI BOOL WINAPI +TryEnterCriticalSection(LPCRITICAL_SECTION lpCriticalSection); +#endif /* _WIN32_WINNT < 0x0400 */ + +#define isc_mutex_init(mp) \ + (InitializeCriticalSection((mp)), ISC_R_SUCCESS) +#define isc_mutex_lock(mp) \ + (EnterCriticalSection((mp)), ISC_R_SUCCESS) +#define isc_mutex_unlock(mp) \ + (LeaveCriticalSection((mp)), ISC_R_SUCCESS) +#define isc_mutex_trylock(mp) \ + (TryEnterCriticalSection((mp)) ? ISC_R_SUCCESS : ISC_R_LOCKBUSY) +#define isc_mutex_destroy(mp) \ + (DeleteCriticalSection((mp)), ISC_R_SUCCESS) + +/* + * This is a placeholder for now since we are not keeping any mutex stats + */ +#define isc_mutex_stats(fp) do {} while (0) + +#endif /* ISC_MUTEX_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/net.h b/contrib/ntp/lib/isc/win32/include/isc/net.h new file mode 100644 index 000000000..10be85b44 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/net.h @@ -0,0 +1,374 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2008, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_NET_H +#define ISC_NET_H 1 + +#include + +/* + * Also define LWRES_IPV6_H to keep it from being included if liblwres is + * being used, or redefinition errors will occur. + */ +#define LWRES_IPV6_H 1 + + + +/***** + ***** Module Info + *****/ + +/* + * Basic Networking Types + * + * This module is responsible for defining the following basic networking + * types: + * + * struct in_addr + * struct in6_addr + * struct in6_pktinfo + * struct sockaddr + * struct sockaddr_in + * struct sockaddr_in6 + * in_port_t + * + * It ensures that the AF_ and PF_ macros are defined. + * + * It declares ntoh[sl]() and hton[sl](). + * + * It declares inet_aton(), inet_ntop(), and inet_pton(). + * + * It ensures that INADDR_ANY, IN6ADDR_ANY_INIT, in6addr_any, and + * in6addr_loopback are available. + * + * It ensures that IN_MULTICAST() is available to check for multicast + * addresses. + * + * MP: + * No impact. + * + * Reliability: + * No anticipated impact. + * + * Resources: + * N/A. + * + * Security: + * No anticipated impact. + * + * Standards: + * BSD Socket API + * RFC2553 + */ + +/*** + *** Imports. + ***/ +#include + +/* + * Because of some sort of problem in the MS header files, this cannot + * be simple "#include ", because winsock2.h tries to include + * windows.h, which then generates an error out of mswsock.h. _You_ + * figure it out. + */ +#ifndef _WINSOCKAPI_ +#define _WINSOCKAPI_ /* Prevent inclusion of winsock.h in windows.h */ +#endif + +#include + +#include + +#include +#include + +#include +#include + +/* + * This is here because named client, interfacemgr.c, etc. use the name as + * a variable + */ +#undef interface + +#ifndef INADDR_LOOPBACK +#define INADDR_LOOPBACK 0x7f000001UL +#endif + +#ifndef ISC_PLATFORM_HAVEIN6PKTINFO +struct in6_pktinfo { + struct in6_addr ipi6_addr; /* src/dst IPv6 address */ + unsigned int ipi6_ifindex; /* send/recv interface index */ +}; +#endif + +#if _MSC_VER < 1300 +#define in6addr_any isc_net_in6addrany +#define in6addr_loopback isc_net_in6addrloop +#endif + +/* + * Ensure type in_port_t is defined. + */ +#ifdef ISC_PLATFORM_NEEDPORTT +typedef isc_uint16_t in_port_t; +#endif + +/* + * If this system does not have MSG_TRUNC (as returned from recvmsg()) + * ISC_PLATFORM_RECVOVERFLOW will be defined. This will enable the MSG_TRUNC + * faking code in socket.c. + */ +#ifndef MSG_TRUNC +#define ISC_PLATFORM_RECVOVERFLOW +#endif + +#define ISC__IPADDR(x) ((isc_uint32_t)htonl((isc_uint32_t)(x))) + +#define ISC_IPADDR_ISMULTICAST(i) \ + (((isc_uint32_t)(i) & ISC__IPADDR(0xf0000000)) \ + == ISC__IPADDR(0xe0000000)) + +#define ISC_IPADDR_ISEXPERIMENTAL(i) \ + (((isc_uint32_t)(i) & ISC__IPADDR(0xf0000000)) \ + == ISC__IPADDR(0xf0000000)) + +/* + * Fix the FD_SET and FD_CLR Macros to properly cast + */ +#undef FD_CLR +#define FD_CLR(fd, set) do { \ + u_int __i; \ + for (__i = 0; __i < ((fd_set FAR *)(set))->fd_count; __i++) { \ + if (((fd_set FAR *)(set))->fd_array[__i] == (SOCKET) fd) { \ + while (__i < ((fd_set FAR *)(set))->fd_count-1) { \ + ((fd_set FAR *)(set))->fd_array[__i] = \ + ((fd_set FAR *)(set))->fd_array[__i+1]; \ + __i++; \ + } \ + ((fd_set FAR *)(set))->fd_count--; \ + break; \ + } \ + } \ +} while (0) + +#undef FD_SET +#define FD_SET(fd, set) do { \ + u_int __i; \ + for (__i = 0; __i < ((fd_set FAR *)(set))->fd_count; __i++) { \ + if (((fd_set FAR *)(set))->fd_array[__i] == (SOCKET)(fd)) { \ + break; \ + } \ + } \ + if (__i == ((fd_set FAR *)(set))->fd_count) { \ + if (((fd_set FAR *)(set))->fd_count < FD_SETSIZE) { \ + ((fd_set FAR *)(set))->fd_array[__i] = (SOCKET)(fd); \ + ((fd_set FAR *)(set))->fd_count++; \ + } \ + } \ +} while (0) + +/* + * Windows Sockets errors redefined as regular Berkeley error constants. + * These are usually commented out in Windows NT to avoid conflicts with errno.h. + * Use the WSA constants instead. + * Starting with VC9 (VC++ 2010) many of these are defined incompatibly + * by errno.h -- #undef the conflicting values, which are not relevant to + * Win32. + */ + +#undef EWOULDBLOCK +#define EWOULDBLOCK WSAEWOULDBLOCK +#undef EINPROGRESS +#define EINPROGRESS WSAEINPROGRESS +#undef EALREADY +#define EALREADY WSAEALREADY +#undef ENOTSOCK +#define ENOTSOCK WSAENOTSOCK +#undef EDESTADDRREQ +#define EDESTADDRREQ WSAEDESTADDRREQ +#undef EMSGSIZE +#define EMSGSIZE WSAEMSGSIZE +#undef EPROTOTYPE +#define EPROTOTYPE WSAEPROTOTYPE +#undef ENOPROTOOPT +#define ENOPROTOOPT WSAENOPROTOOPT +#undef EPROTONOSUPPORT +#define EPROTONOSUPPORT WSAEPROTONOSUPPORT +#define ESOCKTNOSUPPORT WSAESOCKTNOSUPPORT +#undef EOPNOTSUPP +#define EOPNOTSUPP WSAEOPNOTSUPP +#define EPFNOSUPPORT WSAEPFNOSUPPORT +#undef EAFNOSUPPORT +#define EAFNOSUPPORT WSAEAFNOSUPPORT +#undef EADDRINUSE +#define EADDRINUSE WSAEADDRINUSE +#undef EADDRNOTAVAIL +#define EADDRNOTAVAIL WSAEADDRNOTAVAIL +#undef ENETDOWN +#define ENETDOWN WSAENETDOWN +#undef ENETUNREACH +#define ENETUNREACH WSAENETUNREACH +#undef ENETRESET +#define ENETRESET WSAENETRESET +#undef ECONNABORTED +#define ECONNABORTED WSAECONNABORTED +#undef ECONNRESET +#define ECONNRESET WSAECONNRESET +#undef ENOBUFS +#define ENOBUFS WSAENOBUFS +#undef EISCONN +#define EISCONN WSAEISCONN +#undef ENOTCONN +#define ENOTCONN WSAENOTCONN +#define ESHUTDOWN WSAESHUTDOWN +#define ETOOMANYREFS WSAETOOMANYREFS +#undef ETIMEDOUT +#define ETIMEDOUT WSAETIMEDOUT +#undef ECONNREFUSED +#define ECONNREFUSED WSAECONNREFUSED +#undef ELOOP +#define ELOOP WSAELOOP +#define EHOSTDOWN WSAEHOSTDOWN +#undef EHOSTUNREACH +#define EHOSTUNREACH WSAEHOSTUNREACH +#define EPROCLIM WSAEPROCLIM +#define EUSERS WSAEUSERS +#define EDQUOT WSAEDQUOT +#define ESTALE WSAESTALE +#define EREMOTE WSAEREMOTE + + +/*** + *** Functions. + ***/ + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_net_probeipv4(void); +/* + * Check if the system's kernel supports IPv4. + * + * Returns: + * + * ISC_R_SUCCESS IPv4 is supported. + * ISC_R_NOTFOUND IPv4 is not supported. + * ISC_R_DISABLED IPv4 is disabled. + * ISC_R_UNEXPECTED + */ + +isc_result_t +isc_net_probeipv6(void); +/* + * Check if the system's kernel supports IPv6. + * + * Returns: + * + * ISC_R_SUCCESS IPv6 is supported. + * ISC_R_NOTFOUND IPv6 is not supported. + * ISC_R_DISABLED IPv6 is disabled. + * ISC_R_UNEXPECTED + */ + +isc_result_t +isc_net_probeunix(void); +/* + * Check if UNIX domain sockets are supported. + * + * Returns: + * + * ISC_R_SUCCESS + * ISC_R_NOTFOUND + */ + +isc_result_t +isc_net_probe_ipv6only(void); +/* + * Check if the system's kernel supports the IPV6_V6ONLY socket option. + * + * Returns: + * + * ISC_R_SUCCESS the option is supported for both TCP and UDP. + * ISC_R_NOTFOUND IPv6 itself or the option is not supported. + * ISC_R_UNEXPECTED + */ + +isc_result_t +isc_net_probe_ipv6pktinfo(void); +/* + * Check if the system's kernel supports the IPV6_(RECV)PKTINFO socket option + * for UDP sockets. + * + * Returns: + * + * ISC_R_SUCCESS the option is supported. + * ISC_R_NOTFOUND IPv6 itself or the option is not supported. + * ISC_R_UNEXPECTED + */ + +void +isc_net_disableipv4(void); + +void +isc_net_disableipv6(void); + +void +isc_net_enableipv4(void); + +void +isc_net_enableipv6(void); + +isc_result_t +isc_net_getudpportrange(int af, in_port_t *low, in_port_t *high); +/*%< + * Returns system's default range of ephemeral UDP ports, if defined. + * If the range is not available or unknown, ISC_NET_PORTRANGELOW and + * ISC_NET_PORTRANGEHIGH will be returned. + * + * Requires: + * + *\li 'low' and 'high' must be non NULL. + * + * Returns: + * + *\li *low and *high will be the ports specifying the low and high ends of + * the range. + */ + +#ifdef ISC_PLATFORM_NEEDNTOP +const char * +isc_net_ntop(int af, const void *src, char *dst, size_t size); +#define inet_ntop isc_net_ntop +#endif + +#ifdef ISC_PLATFORM_NEEDPTON +int +isc_net_pton(int af, const char *src, void *dst); +#define inet_pton isc_net_pton +#endif + +int +isc_net_aton(const char *cp, struct in_addr *addr); +#define inet_aton isc_net_aton + +ISC_LANG_ENDDECLS + +#endif /* ISC_NET_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/netdb.h b/contrib/ntp/lib/isc/win32/include/isc/netdb.h new file mode 100644 index 000000000..6625afdbd --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/netdb.h @@ -0,0 +1,54 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: netdb.h,v 1.9 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_NETDB_H +#define ISC_NETDB_H 1 + +/***** + ***** Module Info + *****/ + +/* + * Portable netdb.h support. + * + * This module is responsible for defining the getby APIs. + * + * MP: + * No impact. + * + * Reliability: + * No anticipated impact. + * + * Resources: + * N/A. + * + * Security: + * No anticipated impact. + * + * Standards: + * BSD API + */ + +/*** + *** Imports. + ***/ + +#include + +#endif /* ISC_NETDB_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/ntgroups.h b/contrib/ntp/lib/isc/win32/include/isc/ntgroups.h new file mode 100644 index 000000000..b4cd020e5 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/ntgroups.h @@ -0,0 +1,35 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ntgroups.h,v 1.5 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_NTGROUPS_H +#define ISC_NTGROUPS_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + + +isc_result_t +isc_ntsecurity_getaccountgroups(char *name, char **Groups, unsigned int maxgroups, + unsigned int *total); + +ISC_LANG_ENDDECLS + +#endif /* ISC_NTGROUPS_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/ntpaths.h b/contrib/ntp/lib/isc/win32/include/isc/ntpaths.h new file mode 100644 index 000000000..39bcb6276 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/ntpaths.h @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2004, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ntpaths.h,v 1.20 2009/07/14 22:54:57 each Exp $ */ + +/* + * Windows-specific path definitions + * These routines are used to set up and return system-specific path + * information about the files enumerated in NtPaths + */ + +#ifndef ISC_NTPATHS_H +#define ISC_NTPATHS_H + +#include + +/* + * Index of paths needed + */ +enum NtPaths { + NAMED_CONF_PATH, + LWRES_CONF_PATH, + RESOLV_CONF_PATH, + RNDC_CONF_PATH, + NAMED_PID_PATH, + LWRESD_PID_PATH, + LOCAL_STATE_DIR, + SYS_CONF_DIR, + RNDC_KEY_PATH, + SESSION_KEY_PATH +}; + +/* + * Define macros to get the path of the config files + */ +#define NAMED_CONFFILE isc_ntpaths_get(NAMED_CONF_PATH) +#define RNDC_CONFFILE isc_ntpaths_get(RNDC_CONF_PATH) +#define RNDC_KEYFILE isc_ntpaths_get(RNDC_KEY_PATH) +#define SESSION_KEYFILE isc_ntpaths_get(SESSION_KEY_PATH) +#define RESOLV_CONF isc_ntpaths_get(RESOLV_CONF_PATH) + +/* + * Information about where the files are on disk + */ +#define NS_LOCALSTATEDIR "/dns/bin" +#define NS_SYSCONFDIR "/dns/etc" + +ISC_LANG_BEGINDECLS + +void +isc_ntpaths_init(void); + +char * +isc_ntpaths_get(int); + +ISC_LANG_ENDDECLS + +#endif /* ISC_NTPATHS_H */ diff --git a/contrib/ntp/include/isc/offset.h b/contrib/ntp/lib/isc/win32/include/isc/offset.h similarity index 63% rename from contrib/ntp/include/isc/offset.h rename to contrib/ntp/lib/isc/win32/include/isc/offset.h index 709bde4e0..f22fdce0a 100644 --- a/contrib/ntp/include/isc/offset.h +++ b/contrib/ntp/lib/isc/win32/include/isc/offset.h @@ -1,21 +1,21 @@ /* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 2000, 2001 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: offset.h,v 1.10 2001/01/09 21:58:43 bwelling Exp $ */ +/* $Id: offset.h,v 1.6 2007/06/19 23:47:20 tbox Exp $ */ #ifndef ISC_OFFSET_H #define ISC_OFFSET_H 1 @@ -26,7 +26,7 @@ #include /* Required for CHAR_BIT. */ #include -typedef off_t isc_offset_t; +typedef _off_t isc_offset_t; /* * POSIX says "Additionally, blkcnt_t and off_t are extended signed integral diff --git a/contrib/ntp/lib/isc/win32/include/isc/once.h b/contrib/ntp/lib/isc/win32/include/isc/once.h new file mode 100644 index 000000000..0dc1686e4 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/once.h @@ -0,0 +1,43 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: once.h,v 1.9 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_ONCE_H +#define ISC_ONCE_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +typedef struct { + int status; + LONG counter; +} isc_once_t; + +#define ISC_ONCE_INIT_NEEDED 0 +#define ISC_ONCE_INIT_DONE 1 + +#define ISC_ONCE_INIT { ISC_ONCE_INIT_NEEDED, 1 } + +isc_result_t +isc_once_do(isc_once_t *controller, void(*function)(void)); + +ISC_LANG_ENDDECLS + +#endif /* ISC_ONCE_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/platform.h b/contrib/ntp/lib/isc/win32/include/isc/platform.h new file mode 100644 index 000000000..94b8ba508 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/platform.h @@ -0,0 +1,117 @@ +/* + * Copyright (C) 2004, 2005, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: platform.h,v 1.19 2009/09/29 23:48:04 tbox Exp $ */ + +#ifndef ISC_PLATFORM_H +#define ISC_PLATFORM_H 1 + +/***** + ***** Platform-dependent defines. + *****/ + +#define ISC_PLATFORM_USETHREADS + +/*** + *** Network. + ***/ + +#if _MSC_VER > 1200 +#define ISC_PLATFORM_HAVEIPV6 +#define ISC_PLATFORM_HAVEIN6PKTINFO +#define ISC_PLATFORM_HAVESCOPEID +#endif +#define ISC_PLATFORM_NEEDPORTT +#undef MSG_TRUNC +#define ISC_PLATFORM_NEEDNTOP +#define ISC_PLATFORM_NEEDPTON + +#ifndef ISC_PLATFORM_QUADFORMAT +#define ISC_PLATFORM_QUADFORMAT "I64" +#endif + +#define ISC_PLATFORM_NEEDSTRSEP +#define ISC_PLATFORM_NEEDSTRLCPY +#define ISC_PLATFORM_NEEDSTRLCAT +#define ISC_PLATFORM_NEEDSTRLCPY + +/* + * Used to control how extern data is linked; needed for Win32 platforms. + */ +#define ISC_PLATFORM_USEDECLSPEC 1 + +/* + * Define this here for now as winsock2.h defines h_errno + * and we don't want to redeclare it. + */ +#define ISC_PLATFORM_NONSTDHERRNO + +/* + * Define if the platform has . + */ +#undef ISC_PLATFORM_HAVESYSUNH + +/* + * Defines for the noreturn attribute. + */ +#define ISC_PLATFORM_NORETURN_PRE __declspec(noreturn) +#define ISC_PLATFORM_NORETURN_POST + +/* + * Set up a macro for importing and exporting from the DLL + * + * To build static libraries on win32, #define ISC_STATIC_WIN + */ +#ifndef ISC_STATIC_WIN +#define ISC_DLLEXP __declspec(dllexport) +#define ISC_DLLIMP __declspec(dllimport) +#else +#define ISC_DLLEXP +#define ISC_DLLIMP +#endif + +#ifdef LIBISC_EXPORTS +#define LIBISC_EXTERNAL_DATA ISC_DLLEXP +#else +#define LIBISC_EXTERNAL_DATA ISC_DLLIMP +#endif + +#ifdef LIBISCCFG_EXPORTS +#define LIBISCCFG_EXTERNAL_DATA ISC_DLLEXP +#else +#define LIBISCCFG_EXTERNAL_DATA ISC_DLLIMP +#endif + +#ifdef LIBISCCC_EXPORTS +#define LIBISCCC_EXTERNAL_DATA ISC_DLLEXP +#else +#define LIBISCCC_EXTERNAL_DATA ISC_DLLIMP +#endif + +#ifdef LIBDNS_EXPORTS +#define LIBDNS_EXTERNAL_DATA ISC_DLLEXP +#else +#define LIBDNS_EXTERNAL_DATA ISC_DLLIMP +#endif + +#ifdef LIBBIND9_EXPORTS +#define LIBBIND9_EXTERNAL_DATA ISC_DLLEXP +#else +#define LIBBIND9_EXTERNAL_DATA ISC_DLLIMP +#endif + +#endif /* ISC_PLATFORM_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/stat.h b/contrib/ntp/lib/isc/win32/include/isc/stat.h new file mode 100644 index 000000000..f95e3b0dd --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/stat.h @@ -0,0 +1,68 @@ +/* + * Copyright (C) 2004, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stat.h,v 1.9 2009/10/01 23:48:08 tbox Exp $ */ + +#ifndef ISC_STAT_H +#define ISC_STAT_H 1 + +#include + +/* open() under unix allows setting of read/write permissions + * at the owner, group and other levels. These don't exist in NT + * We'll just map them all to the NT equivalent + */ + +#define S_IREAD _S_IREAD /* read permission, owner */ +#define S_IWRITE _S_IWRITE /* write permission, owner */ +#define S_IEXEC _S_IEXEC /* execute/search permission, owner */ +#define S_IRUSR _S_IREAD /* Owner read permission */ +#define S_IWUSR _S_IWRITE /* Owner write permission */ +#define S_IRGRP _S_IREAD /* Group read permission */ +#define S_IWGRP _S_IWRITE /* Group write permission */ +#define S_IROTH _S_IREAD /* Other read permission */ +#define S_IWOTH _S_IWRITE /* Other write permission */ + +#ifndef S_IFMT +# define S_IFMT _S_IFMT +#endif +#ifndef S_IFDIR +# define S_IFDIR _S_IFDIR +#endif +#ifndef S_IFCHR +# define S_IFCHR _S_IFCHR +#endif +#ifndef S_IFREG +# define S_IFREG _S_IFREG +#endif + +#ifndef S_ISDIR +# define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR) +#endif +#ifndef S_ISREG +# define S_ISREG(m) (((m) & S_IFMT) == S_IFREG) +#endif + +#define O_RDONLY _O_RDONLY +#define O_WRONLY _O_WRONLY +#define O_RDWR _O_RDWR +#define O_APPEND _O_APPEND +#define O_CREAT _O_CREAT +#define O_TRUNC _O_TRUNC +#define O_EXCL _O_EXCL + +#endif /* ISC_STAT_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/stdtime.h b/contrib/ntp/lib/isc/win32/include/isc/stdtime.h new file mode 100644 index 000000000..abbbc16c1 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/stdtime.h @@ -0,0 +1,62 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +#ifndef ISC_STDTIME_H +#define ISC_STDTIME_H 1 + +#include +#include + +/* + * It's public information that 'isc_stdtime_t' is an unsigned integral type. + * Applications that want maximum portability should not assume anything + * about its size. + */ +typedef isc_uint32_t isc_stdtime_t; + +/* but this flag helps... */ +#define STDTIME_ON_32BITS 1 + +/* + * isc_stdtime32_t is a 32-bit version of isc_stdtime_t. A variable of this + * type should only be used as an opaque integer (e.g.,) to compare two + * time values. + */ +typedef isc_uint32_t isc_stdtime32_t; + +ISC_LANG_BEGINDECLS + +void +isc_stdtime_get(isc_stdtime_t *t); +/* + * Set 't' to the number of seconds since 00:00:00 UTC, January 1, 1970. + * + * Requires: + * + * 't' is a valid pointer. + */ + +#define isc_stdtime_convert32(t, t32p) (*(t32p) = t) +/* + * Convert the standard time to its 32-bit version. + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_STDTIME_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/strerror.h b/contrib/ntp/lib/isc/win32/include/isc/strerror.h new file mode 100644 index 000000000..38d2ef2b4 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/strerror.h @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: strerror.h,v 1.5 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_STRERROR_H +#define ISC_STRERROR_H + +#include + +#include + +ISC_LANG_BEGINDECLS + +#define ISC_STRERRORSIZE 128 + +/* + * Provide a thread safe wrapper to strerrror(). + * + * Requires: + * 'buf' to be non NULL. + */ +void +isc__strerror(int num, char *buf, size_t bufsize); + +ISC_LANG_ENDDECLS + +#endif /* ISC_STRERROR_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/syslog.h b/contrib/ntp/lib/isc/win32/include/isc/syslog.h new file mode 100644 index 000000000..765c0e532 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/syslog.h @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: syslog.h,v 1.5 2007/06/19 23:47:20 tbox Exp $ */ + +#ifndef ISC_SYSLOG_H +#define ISC_SYSLOG_H 1 + +#include +#include + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_syslog_facilityfromstring(const char *str, int *facilityp); +/* + * Convert 'str' to the appropriate syslog facility constant. + * + * Requires: + * + * 'str' is not NULL + * 'facilityp' is not NULL + * + * Returns: + * ISC_R_SUCCESS + * ISC_R_NOTFOUND + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_SYSLOG_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/thread.h b/contrib/ntp/lib/isc/win32/include/isc/thread.h new file mode 100644 index 000000000..2eb923b2e --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/thread.h @@ -0,0 +1,100 @@ +/* + * Copyright (C) 2004, 2005, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.h,v 1.25 2009/09/29 04:37:08 marka Exp $ */ + +#ifndef ISC_THREAD_H +#define ISC_THREAD_H 1 + +#include + +#include +#include + +/* + * Inlines to help with wait retrun checking + */ + +/* check handle for NULL and INVALID_HANDLE */ +inline BOOL IsValidHandle( HANDLE hHandle) { + return ((hHandle != NULL) && (hHandle != INVALID_HANDLE_VALUE)); +} + +/* validate wait return codes... */ +inline BOOL WaitSucceeded( DWORD dwWaitResult, DWORD dwHandleCount) { + return ((dwWaitResult >= WAIT_OBJECT_0) && + (dwWaitResult < WAIT_OBJECT_0 + dwHandleCount)); +} + +inline BOOL WaitAbandoned( DWORD dwWaitResult, DWORD dwHandleCount) { + return ((dwWaitResult >= WAIT_ABANDONED_0) && + (dwWaitResult < WAIT_ABANDONED_0 + dwHandleCount)); +} + +inline BOOL WaitTimeout( DWORD dwWaitResult) { + return (dwWaitResult == WAIT_TIMEOUT); +} + +inline BOOL WaitFailed( DWORD dwWaitResult) { + return (dwWaitResult == WAIT_FAILED); +} + +/* compute object indices for waits... */ +inline DWORD WaitSucceededIndex( DWORD dwWaitResult) { + return (dwWaitResult - WAIT_OBJECT_0); +} + +inline DWORD WaitAbandonedIndex( DWORD dwWaitResult) { + return (dwWaitResult - WAIT_ABANDONED_0); +} + + + +typedef HANDLE isc_thread_t; +typedef DWORD isc_threadresult_t; +typedef void * isc_threadarg_t; +typedef isc_threadresult_t (WINAPI *isc_threadfunc_t)(isc_threadarg_t); +typedef DWORD isc_thread_key_t; + +#define isc_thread_self (unsigned long)GetCurrentThreadId + +ISC_LANG_BEGINDECLS + +isc_result_t +isc_thread_create(isc_threadfunc_t, isc_threadarg_t, isc_thread_t *); + +isc_result_t +isc_thread_join(isc_thread_t, isc_threadresult_t *); + +void +isc_thread_setconcurrency(unsigned int level); + +int +isc_thread_key_create(isc_thread_key_t *key, void (*func)(void *)); + +int +isc_thread_key_delete(isc_thread_key_t key); + +void * +isc_thread_key_getspecific(isc_thread_key_t); + +int +isc_thread_key_setspecific(isc_thread_key_t key, void *value); + +ISC_LANG_ENDDECLS + +#endif /* ISC_THREAD_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/time.h b/contrib/ntp/lib/isc/win32/include/isc/time.h new file mode 100644 index 000000000..8ffb24b11 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/time.h @@ -0,0 +1,291 @@ +/* + * Copyright (C) 2004, 2006-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: time.h,v 1.35 2009/01/05 23:47:54 tbox Exp $ */ + +#ifndef ISC_TIME_H +#define ISC_TIME_H 1 + +#include + +#include +#include + +/*** + *** Intervals + ***/ + +/* + * The contents of this structure are private, and MUST NOT be accessed + * directly by callers. + * + * The contents are exposed only to allow callers to avoid dynamic allocation. + */ +struct isc_interval { + isc_int64_t interval; +}; + +LIBISC_EXTERNAL_DATA extern isc_interval_t *isc_interval_zero; + +ISC_LANG_BEGINDECLS + +void +isc_interval_set(isc_interval_t *i, + unsigned int seconds, unsigned int nanoseconds); +/* + * Set 'i' to a value representing an interval of 'seconds' seconds and + * 'nanoseconds' nanoseconds, suitable for use in isc_time_add() and + * isc_time_subtract(). + * + * Requires: + * + * 't' is a valid pointer. + * nanoseconds < 1000000000. + */ + +isc_boolean_t +isc_interval_iszero(const isc_interval_t *i); +/* + * Returns ISC_TRUE iff. 'i' is the zero interval. + * + * Requires: + * + * 'i' is a valid pointer. + */ + +/*** + *** Absolute Times + ***/ + +/* + * The contents of this structure are private, and MUST NOT be accessed + * directly by callers. + * + * The contents are exposed only to allow callers to avoid dynamic allocation. + */ + +struct isc_time { + FILETIME absolute; +}; + +LIBISC_EXTERNAL_DATA extern isc_time_t *isc_time_epoch; + +void +isc_time_set(isc_time_t *t, unsigned int seconds, unsigned int nanoseconds); +/*%< + * Set 't' to a value which represents the given number of seconds and + * nanoseconds since 00:00:00 January 1, 1970, UTC. + * + * Requires: + *\li 't' is a valid pointer. + *\li nanoseconds < 1000000000. + */ + +void +isc_time_settoepoch(isc_time_t *t); +/* + * Set 't' to the time of the epoch. + * + * Notes: + * The date of the epoch is platform-dependent. + * + * Requires: + * + * 't' is a valid pointer. + */ + +isc_boolean_t +isc_time_isepoch(const isc_time_t *t); +/* + * Returns ISC_TRUE iff. 't' is the epoch ("time zero"). + * + * Requires: + * + * 't' is a valid pointer. + */ + +isc_result_t +isc_time_now(isc_time_t *t); +/* + * Set 't' to the current absolute time. + * + * Requires: + * + * 't' is a valid pointer. + * + * Returns: + * + * Success + * Unexpected error + * Getting the time from the system failed. + * Out of range + * The time from the system is too large to be represented + * in the current definition of isc_time_t. + */ + +isc_result_t +isc_time_nowplusinterval(isc_time_t *t, const isc_interval_t *i); +/* + * Set *t to the current absolute time + i. + * + * Note: + * This call is equivalent to: + * + * isc_time_now(t); + * isc_time_add(t, i, t); + * + * Requires: + * + * 't' and 'i' are valid pointers. + * + * Returns: + * + * Success + * Unexpected error + * Getting the time from the system failed. + * Out of range + * The interval added to the time from the system is too large to + * be represented in the current definition of isc_time_t. + */ + +int +isc_time_compare(const isc_time_t *t1, const isc_time_t *t2); +/* + * Compare the times referenced by 't1' and 't2' + * + * Requires: + * + * 't1' and 't2' are valid pointers. + * + * Returns: + * + * -1 t1 < t2 (comparing times, not pointers) + * 0 t1 = t2 + * 1 t1 > t2 + */ + +isc_result_t +isc_time_add(const isc_time_t *t, const isc_interval_t *i, isc_time_t *result); +/* + * Add 'i' to 't', storing the result in 'result'. + * + * Requires: + * + * 't', 'i', and 'result' are valid pointers. + * + * Returns: + * Success + * Out of range + * The interval added to the time is too large to + * be represented in the current definition of isc_time_t. + */ + +isc_result_t +isc_time_subtract(const isc_time_t *t, const isc_interval_t *i, + isc_time_t *result); +/* + * Subtract 'i' from 't', storing the result in 'result'. + * + * Requires: + * + * 't', 'i', and 'result' are valid pointers. + * + * Returns: + * Success + * Out of range + * The interval is larger than the time since the epoch. + */ + +isc_uint64_t +isc_time_microdiff(const isc_time_t *t1, const isc_time_t *t2); +/* + * Find the difference in milliseconds between time t1 and time t2. + * t2 is the subtrahend of t1; ie, difference = t1 - t2. + * + * Requires: + * + * 't1' and 't2' are valid pointers. + * + * Returns: + * The difference of t1 - t2, or 0 if t1 <= t2. + */ + +isc_uint32_t +isc_time_nanoseconds(const isc_time_t *t); +/* + * Return the number of nanoseconds stored in a time structure. + * + * Notes: + * This is the number of nanoseconds in excess of the number + * of seconds since the epoch; it will always be less than one + * full second. + * + * Requires: + * 't' is a valid pointer. + * + * Ensures: + * The returned value is less than 1*10^9. + */ + +void +isc_time_formattimestamp(const isc_time_t *t, char *buf, unsigned int len); +/* + * Format the time 't' into the buffer 'buf' of length 'len', + * using a format like "30-Aug-2000 04:06:47.997" and the local time zone. + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + * 'len' > 0 + * 'buf' points to an array of at least len chars + * + */ + +void +isc_time_formathttptimestamp(const isc_time_t *t, char *buf, unsigned int len); +/* + * Format the time 't' into the buffer 'buf' of length 'len', + * using a format like "Mon, 30 Aug 2000 04:06:47 GMT" + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + * 'len' > 0 + * 'buf' points to an array of at least len chars + * + */ + +void +isc_time_formatISO8601(const isc_time_t *t, char *buf, unsigned int len); +/*%< + * Format the time 't' into the buffer 'buf' of length 'len', + * using the ISO8601 format: "yyyy-mm-ddThh:mm:ssZ" + * If the text does not fit in the buffer, the result is indeterminate, + * but is always guaranteed to be null terminated. + * + * Requires: + *\li 'len' > 0 + *\li 'buf' points to an array of at least len chars + * + */ + +isc_uint32_t +isc_time_seconds(const isc_time_t *t); + +ISC_LANG_ENDDECLS + +#endif /* ISC_TIME_H */ diff --git a/contrib/ntp/lib/isc/win32/include/isc/win32os.h b/contrib/ntp/lib/isc/win32/include/isc/win32os.h new file mode 100644 index 000000000..bd4039361 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/include/isc/win32os.h @@ -0,0 +1,71 @@ +/* + * Copyright (C) 2004, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: win32os.h,v 1.7 2009/06/25 23:48:02 tbox Exp $ */ + +#ifndef ISC_WIN32OS_H +#define ISC_WIN32OS_H 1 + +#include + +ISC_LANG_BEGINDECLS + +/* + * Return the number of CPUs available on the system, or 1 if this cannot + * be determined. + */ + +unsigned int +isc_win32os_majorversion(void); +/* + * Major Version of the O/S. + */ + +unsigned int +isc_win32os_minorversion(void); +/* + * Minor Version of the O/S. + */ + +unsigned int +isc_win32os_servicepackmajor(void); +/* + * Major Version of the Service Pack for O/S. + */ + +unsigned int +isc_win32os_servicepackminor(void); +/* + * Minor Version of the Service Pack for O/S. + */ + +int +isc_win32os_versioncheck(unsigned int major, unsigned int minor, + unsigned int updatemajor, unsigned int updateminor); + +/* + * Checks the current version of the operating system with the + * supplied version information. + * Returns: + * -1 if less than the version information supplied + * 0 if equal to all of the version information supplied + * +1 if greater than the version information supplied + */ + +ISC_LANG_ENDDECLS + +#endif /* ISC_WIN32OS_H */ diff --git a/contrib/ntp/lib/isc/win32/interfaceiter.c b/contrib/ntp/lib/isc/win32/interfaceiter.c new file mode 100644 index 000000000..8753aa8a9 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/interfaceiter.c @@ -0,0 +1,807 @@ +/* + * Copyright (C) 2004, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: interfaceiter.c,v 1.15 2009/01/18 23:48:14 tbox Exp $ */ + +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +void InitSockets(void); + + +#define IFITER_MAGIC 0x49464954U /* IFIT. */ +#define VALID_IFITER(t) ((t) != NULL && (t)->magic == IFITER_MAGIC) + +struct isc_interfaceiter { + unsigned int magic; /* Magic number. */ + /* common fields */ + isc_mem_t *mctx; + isc_interface_t current; /* Current interface data. */ + isc_result_t result; /* Last result code. */ + /* fields used if GetAdaptersAddresses is available at runtime */ + IP_ADAPTER_ADDRESSES * ipaa; /* GAA() result buffer */ + ULONG ipaasize; /* Bytes allocated */ + IP_ADAPTER_ADDRESSES * ipaaCur; /* enumeration position */ + IP_ADAPTER_UNICAST_ADDRESS *ipuaCur; /* enumeration subposition */ + /* fields used for the older address enumeration ioctls */ + int socket; + INTERFACE_INFO IFData; /* Current Interface Info */ + int numIF; /* Current Interface count */ + int v4IF; /* Number of IPv4 Interfaces */ + INTERFACE_INFO *buf4; /* Buffer for WSAIoctl data. */ + unsigned int buf4size; /* Bytes allocated. */ + INTERFACE_INFO *pos4; /* Current offset in IF List */ + SOCKET_ADDRESS_LIST *buf6; + unsigned int buf6size; /* Bytes allocated. */ + unsigned int pos6; /* buf6 index, counts down */ + struct in6_addr loop__1; /* ::1 node-scope localhost */ + struct in6_addr loopfe80__1; /* fe80::1 link-scope localhost */ +}; + +typedef ULONG (WINAPI *PGETADAPTERSADDRESSES)( + ULONG Family, + ULONG Flags, + PVOID Reserved, + PIP_ADAPTER_ADDRESSES AdapterAddresses, + PULONG SizePointer +); + +static isc_boolean_t use_GAA; +static isc_boolean_t use_GAA_determined; +static HMODULE hmod_iphlpapi; +static PGETADAPTERSADDRESSES pGAA; + + +/* + * Size of buffer for SIO_GET_INTERFACE_LIST, in number of interfaces. + * We assume no sane system will have more than than 1K of IP addresses on + * all of its adapters. + */ +#define IFCONF_SIZE_INITIAL 16 +#define IFCONF_SIZE_INCREMENT 64 +#define IFCONF_SIZE_MAX 1040 + + +/* Common utility functions */ + +/* + * Windows always provides 255.255.255.255 as the the broadcast + * address. ntpd needs to know the broadcast address which will target + * only that network interface, not all. Reconstruct it from the + * address and mask. + */ +static void +get_broadcastaddr(isc_netaddr_t *bcastaddr, isc_netaddr_t *addr, isc_netaddr_t *netmask) { + + isc_uint32_t * b; + isc_uint32_t a, n; + + b = (isc_uint32_t *)&bcastaddr->type.in; + a = *(isc_uint32_t *)&addr->type.in; + n = *(isc_uint32_t *)&netmask->type.in; + + *b = a | ~n; +} + +isc_result_t +isc_interfaceiter_create(isc_mem_t *mctx, isc_interfaceiter_t **iterp) { + char strbuf[ISC_STRERRORSIZE]; + isc_interfaceiter_t *iter; + isc_result_t result; + unsigned int major; + unsigned int minor; + unsigned int spmajor; + ULONG err; + int tries; + int error; + unsigned long bytesReturned = 0; + + REQUIRE(mctx != NULL); + REQUIRE(iterp != NULL); + REQUIRE(*iterp == NULL); + + iter = isc_mem_get(mctx, sizeof(*iter)); + if (iter == NULL) + return (ISC_R_NOMEMORY); + + InitSockets(); + + iter->mctx = mctx; + iter->ipaa = NULL; + iter->buf4 = NULL; + iter->buf6 = NULL; + iter->pos4 = NULL; + iter->ipaaCur = NULL; + iter->ipuaCur = NULL; + iter->ipaasize = 0; + iter->pos6 = 0; + iter->buf6size = 0; + iter->buf4size = 0; + iter->result = ISC_R_FAILURE; + iter->numIF = 0; + iter->v4IF = 0; + + /* + * Use GetAdaptersAddresses in preference to ioctls when running + * on Windows XP SP1 or later. Earlier GetAdaptersAddresses do + * not appear to provide enough information to associate unicast + * addresses with their prefixes. + */ + if (!use_GAA_determined) { + major = isc_win32os_majorversion(); + minor = isc_win32os_minorversion(); + spmajor = isc_win32os_servicepackmajor(); + if (major > 5 || (5 == major && + (minor > 1 || (1 == minor && spmajor >= 1)))) { + if (NULL == hmod_iphlpapi) + hmod_iphlpapi = LoadLibrary("iphlpapi"); + if (NULL != hmod_iphlpapi) + pGAA = (PGETADAPTERSADDRESSES) + GetProcAddress( + hmod_iphlpapi, + "GetAdaptersAddresses"); + if (NULL != pGAA) + use_GAA = ISC_TRUE; + } + use_GAA_determined = ISC_TRUE; + } + + if (!use_GAA) + goto use_ioctls; + + iter->ipaasize = 16 * 1024; + + for (tries = 0; tries < 5; tries++) { + iter->ipaa = isc_mem_reallocate(mctx, iter->ipaa, + iter->ipaasize); + if (NULL == iter->ipaa) { + result = ISC_R_NOMEMORY; + goto put_iter; + } + err = (*pGAA)( + AF_UNSPEC, + GAA_FLAG_INCLUDE_PREFIX | GAA_FLAG_SKIP_ANYCAST, + NULL, + iter->ipaa, + &iter->ipaasize); + if (NO_ERROR == err || ERROR_BUFFER_OVERFLOW != err) + break; + } + + if (NO_ERROR != err) { + isc__strerror(err, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "GetAdaptersAddresses: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto gaa_failure; + } + + iter->ipaaCur = iter->ipaa; + goto success; + + use_ioctls: + /* + * Create an unbound datagram socket to do the + * SIO_GET_INTERFACE_LIST WSAIoctl on. + */ + if ((iter->socket = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { + error = WSAGetLastError(); + if (error == WSAEAFNOSUPPORT) + goto inet6_only; + isc__strerror(error, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "making interface scan socket: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto put_iter; + } + + /* + * Get the interface configuration, allocating more memory if + * necessary. + */ + iter->buf4size = IFCONF_SIZE_INITIAL*sizeof(INTERFACE_INFO); + + for (;;) { + iter->buf4 = isc_mem_get(mctx, iter->buf4size); + if (iter->buf4 == NULL) { + result = ISC_R_NOMEMORY; + goto alloc_failure; + } + + if (WSAIoctl(iter->socket, SIO_GET_INTERFACE_LIST, + 0, 0, iter->buf4, iter->buf4size, + &bytesReturned, 0, 0) == SOCKET_ERROR) + { + error = WSAGetLastError(); + if (error != WSAEFAULT && error != WSAENOBUFS) { + errno = error; + isc__strerror(error, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "get interface configuration: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto ioctl_failure; + } + /* + * EINVAL. Retry with a bigger buffer. + */ + } else { + /* + * The WSAIoctl succeeded. + * If the number of the returned bytes is the same + * as the buffer size, we will grow it just in + * case and retry. + */ + if (bytesReturned > 0 && + (bytesReturned < iter->buf4size)) + break; + } + if (iter->buf4size >= IFCONF_SIZE_MAX*sizeof(INTERFACE_INFO)) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "get interface configuration: " + "maximum buffer size exceeded"); + result = ISC_R_UNEXPECTED; + goto ioctl_failure; + } + isc_mem_put(mctx, iter->buf4, iter->buf4size); + + iter->buf4size += IFCONF_SIZE_INCREMENT * + sizeof(INTERFACE_INFO); + } + + /* + * A newly created iterator has an undefined position + * until isc_interfaceiter_first() is called. + */ + iter->v4IF = bytesReturned/sizeof(INTERFACE_INFO); + + /* We don't need the socket any more, so close it */ + closesocket(iter->socket); + + inet6_only: + /* + * Create an unbound datagram socket to do the + * SIO_ADDRESS_LIST_QUERY WSAIoctl on. + */ + if ((iter->socket = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) { + error = WSAGetLastError(); + if (error == WSAEAFNOSUPPORT) + goto success; + isc__strerror(error, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "making interface scan socket: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto put_iter; + } + + /* + * Get the interface configuration, allocating more memory if + * necessary. + */ + iter->buf6size = sizeof(SOCKET_ADDRESS_LIST) + + IFCONF_SIZE_INITIAL*sizeof(SOCKET_ADDRESS); + + for (;;) { + iter->buf6 = isc_mem_get(mctx, iter->buf6size); + if (iter->buf6 == NULL) { + result = ISC_R_NOMEMORY; + goto ioctl_failure; + } + + if (WSAIoctl(iter->socket, SIO_ADDRESS_LIST_QUERY, + 0, 0, iter->buf6, iter->buf6size, + &bytesReturned, 0, 0) == SOCKET_ERROR) + { + error = WSAGetLastError(); + if (error != WSAEFAULT && error != WSAENOBUFS) { + errno = error; + isc__strerror(error, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "sio address list query: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto ioctl6_failure; + } + /* + * EINVAL. Retry with a bigger buffer. + */ + } else + break; + + if (iter->buf6size >= IFCONF_SIZE_MAX*sizeof(SOCKET_ADDRESS)) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "get interface configuration: " + "maximum buffer size exceeded"); + result = ISC_R_UNEXPECTED; + goto ioctl6_failure; + } + isc_mem_put(mctx, iter->buf6, iter->buf6size); + + iter->buf6size += IFCONF_SIZE_INCREMENT * + sizeof(SOCKET_ADDRESS); + } + + /* + * initialize loop__1 to [::1] and loopfe80__1 to [fe80::1]. + * used by internal_current6(). + */ + memset(&iter->loop__1, 0, sizeof(iter->loop__1)); + memset(&iter->loopfe80__1, 0, sizeof(iter->loopfe80__1)); + iter->loop__1.s6_addr[15] = 1; + iter->loopfe80__1.s6_addr[15] = 1; + iter->loopfe80__1.s6_addr[0] = 0xfe; + iter->loopfe80__1.s6_addr[1] = 0x80; + + closesocket(iter->socket); + + success: + iter->magic = IFITER_MAGIC; + *iterp = iter; + return (ISC_R_SUCCESS); + + gaa_failure: + isc_mem_put(mctx, iter->ipaa, iter->ipaasize); + goto put_iter; + + ioctl6_failure: + isc_mem_put(mctx, iter->buf6, iter->buf6size); + + ioctl_failure: + if (iter->buf4 != NULL) + isc_mem_put(mctx, iter->buf4, iter->buf4size); + + alloc_failure: + if (iter->socket >= 0) + (void) closesocket(iter->socket); + + put_iter: + isc_mem_put(mctx, iter, sizeof(*iter)); + return (result); +} + +static unsigned char +GAA_find_prefix(isc_interfaceiter_t *iter) { + IP_ADAPTER_PREFIX * ipap; + IP_ADAPTER_PREFIX * ipap_match; + int match_len; + int max_len; + isc_netaddr_t target; + u_short af; + isc_netaddr_t pfx; + int pfx_len; + size_t nbytes; + unsigned char nbits; + unsigned char * pbits; + unsigned int octets; + + match_len = 0; + ipap_match = NULL; + isc_netaddr_fromsockaddr(&target, + (isc_sockaddr_t *)iter->ipuaCur->Address.lpSockaddr); + af = (u_short)target.family; + INSIST(AF_INET == af || AF_INET6 == af); + max_len = (AF_INET6 == af) ? 128 : 32; + iter->current.netmask.family = af; + for (ipap = iter->ipaaCur->FirstPrefix; + ipap != NULL; + ipap = ipap->Next) { + if (ipap->Address.lpSockaddr->sa_family != af) + continue; + isc_netaddr_fromsockaddr(&pfx, + (isc_sockaddr_t *)ipap->Address.lpSockaddr); + pfx_len = ipap->PrefixLength; + INSIST(0 <= pfx_len && pfx_len <= max_len); + if (pfx_len > match_len && pfx_len < max_len && + isc_netaddr_eqprefix(&target, &pfx, pfx_len)) { + ipap_match = ipap; + match_len = pfx_len; + } + } + if (NULL == ipap_match) { + /* presume all-ones mask */ + if (AF_INET6 == af) + octets = sizeof(iter->current.netmask.type.in6); + else + octets = sizeof(iter->current.netmask.type.in); + memset(&iter->current.netmask.type, 0xFF, octets); + return (8 * (unsigned char)octets); + } + nbytes = match_len / 8; + nbits = match_len % 8; + memset(&iter->current.netmask.type.in6, 0xFF, nbytes); + pbits = (void *)&iter->current.netmask.type.in6; + pbits += nbytes; + *pbits |= 0xFF << (8 - nbits); + return ((unsigned char)match_len); +} + +static isc_result_t +internal_current_GAA(isc_interfaceiter_t *iter) { + IP_ADAPTER_ADDRESSES *adap; + IP_ADAPTER_UNICAST_ADDRESS *addr; + unsigned char prefix_len; + + REQUIRE(iter->ipaaCur != NULL); + REQUIRE(iter->ipuaCur != NULL); + adap = iter->ipaaCur; + addr = iter->ipuaCur; + if (IpDadStatePreferred != addr->DadState) + return (ISC_R_IGNORE); + memset(&iter->current, 0, sizeof(iter->current)); + iter->current.af = addr->Address.lpSockaddr->sa_family; + isc_netaddr_fromsockaddr(&iter->current.address, + (isc_sockaddr_t *)addr->Address.lpSockaddr); + if (AF_INET6 == iter->current.af) + iter->current.ifindex = adap->Ipv6IfIndex; + iter->current.name[0] = '\0'; + WideCharToMultiByte( + CP_ACP, + 0, + adap->FriendlyName, + -1, + iter->current.name, + sizeof(iter->current.name), + NULL, + NULL); + iter->current.name[sizeof(iter->current.name) - 1] = '\0'; + if (IfOperStatusUp == adap->OperStatus) + iter->current.flags |= INTERFACE_F_UP; + if (IF_TYPE_PPP == adap->IfType) + iter->current.flags |= INTERFACE_F_POINTTOPOINT; + else if (IF_TYPE_SOFTWARE_LOOPBACK == adap->IfType) + iter->current.flags |= INTERFACE_F_LOOPBACK; + if ((IP_ADAPTER_NO_MULTICAST & adap->Flags) == 0) + iter->current.flags |= INTERFACE_F_MULTICAST; + if (IpSuffixOriginRandom == addr->SuffixOrigin) + iter->current.flags |= INTERFACE_F_PRIVACY; + + prefix_len = GAA_find_prefix(iter); + /* I'm failing to see a broadcast flag via GAA */ + if (AF_INET == iter->current.af && prefix_len < 32 && + (INTERFACE_F_LOOPBACK & iter->current.flags) == 0) { + iter->current.flags |= INTERFACE_F_BROADCAST; + get_broadcastaddr(&iter->current.broadcast, + &iter->current.address, + &iter->current.netmask); + } + return (ISC_R_SUCCESS); +} + +/* + * Get information about the current interface to iter->current. + * If successful, return ISC_R_SUCCESS. + * If the interface has an unsupported address family, or if + * some operation on it fails, return ISC_R_IGNORE to make + * the higher-level iterator code ignore it. + */ + +static isc_result_t +internal_current(isc_interfaceiter_t *iter) { + BOOL ifNamed = FALSE; + unsigned long flags; + + REQUIRE(VALID_IFITER(iter)); + REQUIRE(iter->numIF >= 0); + + memset(&iter->current, 0, sizeof(iter->current)); + iter->current.af = AF_INET; + + isc_netaddr_fromsockaddr(&iter->current.address, + (isc_sockaddr_t *)&(iter->IFData.iiAddress)); + + /* + * Get interface flags. + */ + + iter->current.flags = 0; + flags = iter->IFData.iiFlags; + + if ((flags & IFF_UP) != 0) + iter->current.flags |= INTERFACE_F_UP; + + if ((flags & IFF_BROADCAST) != 0) + iter->current.flags |= INTERFACE_F_BROADCAST; + + if ((flags & IFF_MULTICAST) != 0) + iter->current.flags |= INTERFACE_F_MULTICAST; + + if ((flags & IFF_POINTTOPOINT) != 0) { + iter->current.flags |= INTERFACE_F_POINTTOPOINT; + snprintf(iter->current.name, sizeof(iter->current.name), + "PPP %d", iter->numIF); + ifNamed = TRUE; + } + + if ((flags & IFF_LOOPBACK) != 0) { + iter->current.flags |= INTERFACE_F_LOOPBACK; + snprintf(iter->current.name, sizeof(iter->current.name), + "v4loop %d", iter->numIF); + ifNamed = TRUE; + } + + /* + * If the interface is point-to-point, get the destination address. + */ + if ((iter->current.flags & INTERFACE_F_POINTTOPOINT) != 0) + isc_netaddr_fromsockaddr(&iter->current.dstaddress, + (isc_sockaddr_t *)&(iter->IFData.iiBroadcastAddress)); + + /* + * Get the network mask. + */ + isc_netaddr_fromsockaddr(&iter->current.netmask, + (isc_sockaddr_t *)&(iter->IFData.iiNetmask)); + + /* + * If the interface is broadcast, get the broadcast address, + * based on the unicast address and network mask. + */ + if ((iter->current.flags & INTERFACE_F_BROADCAST) != 0) + get_broadcastaddr(&iter->current.broadcast, + &iter->current.address, + &iter->current.netmask); + + if (ifNamed == FALSE) + snprintf(iter->current.name, sizeof(iter->current.name), + "IPv4 %d", iter->numIF); + + return (ISC_R_SUCCESS); +} + +static isc_result_t +internal_current6(isc_interfaceiter_t *iter) { + BOOL ifNamed = FALSE; + struct sockaddr_in6 *psa6; + BOOL localhostSeen; + int i; + + REQUIRE(VALID_IFITER(iter)); + REQUIRE(iter->pos6 >= 0); + REQUIRE(iter->buf6 != 0); + + memset(&iter->current, 0, sizeof(iter->current)); + iter->current.af = AF_INET6; + + /* + * synthesize localhost ::1 before returning the rest, if ::1 + * is not on the list. + */ + if (iter->pos6 >= (unsigned)iter->buf6->iAddressCount) { + localhostSeen = FALSE; + for (i = 0; i < iter->buf6->iAddressCount; i++) { + psa6 = (struct sockaddr_in6 *) + iter->buf6->Address[i].lpSockaddr; + if (!memcmp(&iter->loop__1, &psa6->sin6_addr, + sizeof(iter->loop__1))) { + localhostSeen = TRUE; + break; + } + } + if (localhostSeen) + iter->pos6 = iter->buf6->iAddressCount - 1; + } + + if (iter->pos6 < (unsigned)iter->buf6->iAddressCount) { + isc_netaddr_fromsockaddr(&iter->current.address, + (isc_sockaddr_t *)iter->buf6->Address[iter->pos6].lpSockaddr); + } else { + iter->current.address.family = AF_INET6; + memcpy(&iter->current.address.type.in6, &iter->loop__1, + sizeof(iter->current.address.type.in6)); + } + + /* + * Get interface flags. + */ + + iter->current.flags = INTERFACE_F_UP | INTERFACE_F_MULTICAST; + + if (!memcmp(&iter->current.address.type.in6, &iter->loop__1, + sizeof(iter->current.address.type.in6)) || + !memcmp(&iter->current.address.type.in6, &iter->loopfe80__1, + sizeof(iter->current.address.type.in6))) { + + iter->current.flags |= INTERFACE_F_LOOPBACK; + snprintf(iter->current.name, sizeof(iter->current.name), + "v6loop %d", + iter->buf6->iAddressCount - iter->pos6); + ifNamed = TRUE; + } + + if (ifNamed == FALSE) + snprintf(iter->current.name, sizeof(iter->current.name), + "IPv6 %d", + iter->buf6->iAddressCount - iter->pos6); + + memset(iter->current.netmask.type.in6.s6_addr, 0xff, + sizeof(iter->current.netmask.type.in6.s6_addr)); + iter->current.netmask.family = AF_INET6; + return (ISC_R_SUCCESS); +} + +static isc_result_t +internal_next_GAA(isc_interfaceiter_t *iter) { + REQUIRE(use_GAA); + if (NULL == iter->ipaaCur) + return (ISC_R_NOMORE); + if (NULL == iter->ipuaCur) + iter->ipuaCur = iter->ipaaCur->FirstUnicastAddress; + else + iter->ipuaCur = iter->ipuaCur->Next; + while (NULL == iter->ipuaCur) { + iter->ipaaCur = iter->ipaaCur->Next; + if (NULL == iter->ipaaCur) + return (ISC_R_NOMORE); + iter->ipuaCur = iter->ipaaCur->FirstUnicastAddress; + } + return (ISC_R_SUCCESS); +} + +/* + * Step the iterator to the next interface. Unlike + * isc_interfaceiter_next(), this may leave the iterator + * positioned on an interface that will ultimately + * be ignored. Return ISC_R_NOMORE if there are no more + * interfaces, otherwise ISC_R_SUCCESS. + */ +static isc_result_t +internal_next(isc_interfaceiter_t *iter) { + if (iter->numIF >= iter->v4IF) + return (ISC_R_NOMORE); + + /* + * The first one needs to be set up to point to the last + * Element of the array. Go to the end and back up + * Microsoft's implementation is peculiar for returning + * the list in reverse order + */ + + if (iter->numIF == 0) + iter->pos4 = (INTERFACE_INFO *)(iter->buf4 + (iter->v4IF)); + + iter->pos4--; + if (&(iter->pos4) < &(iter->buf4)) + return (ISC_R_NOMORE); + + memset(&(iter->IFData), 0, sizeof(INTERFACE_INFO)); + memcpy(&(iter->IFData), iter->pos4, sizeof(INTERFACE_INFO)); + iter->numIF++; + + return (ISC_R_SUCCESS); +} + +static isc_result_t +internal_next6(isc_interfaceiter_t *iter) { + if (iter->pos6 == 0) + return (ISC_R_NOMORE); + iter->pos6--; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_interfaceiter_current(isc_interfaceiter_t *iter, + isc_interface_t *ifdata) { + REQUIRE(iter->result == ISC_R_SUCCESS); + memcpy(ifdata, &iter->current, sizeof(*ifdata)); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_interfaceiter_first(isc_interfaceiter_t *iter) { + REQUIRE(VALID_IFITER(iter)); + REQUIRE(use_GAA_determined); + /* + * SIO_ADDRESS_LIST_QUERY (used to query IPv6 addresses) + * intentionally omits localhost addresses [::1] and [::fe80] in + * some cases. ntpd depends on enumerating [::1] to listen on + * it, and ntpq and ntpdc default to "localhost" as the target, + * so they will attempt to talk to [::1]:123 and fail. This + * means we need to synthesize ::1, which we will do first, + * hence iAddressCount + 1. internal_next6() will decrement + * it before the first use as an index, and internal_current6() + * will treat pos6 == iAddressCount as a sign to synthesize + * [::1] if needed. + */ + if (!use_GAA && iter->buf6 != NULL) + iter->pos6 = iter->buf6->iAddressCount + 1; + iter->result = ISC_R_SUCCESS; + return (isc_interfaceiter_next(iter)); +} + +isc_result_t +isc_interfaceiter_next(isc_interfaceiter_t *iter) { + isc_result_t result; + + REQUIRE(VALID_IFITER(iter)); + REQUIRE(iter->result == ISC_R_SUCCESS); + REQUIRE(use_GAA_determined); + + if (use_GAA) { + do { + result = internal_next_GAA(iter); + if (ISC_R_NOMORE == result) + goto set_result; + result = internal_current_GAA(iter); + } while (ISC_R_IGNORE == result); + goto set_result; + } + + for (;;) { + result = internal_next(iter); + if (result == ISC_R_NOMORE) { + result = internal_next6(iter); + if (result != ISC_R_SUCCESS) + break; + result = internal_current6(iter); + if (result != ISC_R_IGNORE) + break; + } else if (result != ISC_R_SUCCESS) + break; + result = internal_current(iter); + if (result != ISC_R_IGNORE) + break; + } + set_result: + iter->result = result; + return (result); +} + +void +isc_interfaceiter_destroy(isc_interfaceiter_t **iterp) { + isc_interfaceiter_t *iter; + + REQUIRE(iterp != NULL); + iter = *iterp; + REQUIRE(VALID_IFITER(iter)); + REQUIRE(use_GAA_determined); + + if (use_GAA) { + REQUIRE(NULL == iter->buf4); + REQUIRE(NULL == iter->buf4); + if (iter->ipaa != NULL) + isc_mem_put(iter->mctx, iter->ipaa, iter->ipaasize); + } else { + REQUIRE(NULL == iter->ipaa); + if (iter->buf4 != NULL) + isc_mem_put(iter->mctx, iter->buf4, iter->buf4size); + if (iter->buf6 != NULL) + isc_mem_put(iter->mctx, iter->buf6, iter->buf6size); + } + + iter->magic = 0; + isc_mem_put(iter->mctx, iter, sizeof(*iter)); + *iterp = NULL; +} diff --git a/contrib/ntp/lib/isc/win32/ipv6.c b/contrib/ntp/lib/isc/win32/ipv6.c new file mode 100644 index 000000000..511ae21f4 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/ipv6.c @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ipv6.c,v 1.8 2007/06/19 23:47:19 tbox Exp $ */ + +#include +#include + +LIBISC_EXTERNAL_DATA const struct in6_addr isc_in6addr_any = + IN6ADDR_ANY_INIT; + +LIBISC_EXTERNAL_DATA const struct in6_addr isc_in6addr_loopback = + IN6ADDR_LOOPBACK_INIT; diff --git a/contrib/ntp/lib/isc/win32/keyboard.c b/contrib/ntp/lib/isc/win32/keyboard.c new file mode 100644 index 000000000..d569e7ca8 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/keyboard.c @@ -0,0 +1,89 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: keyboard.c,v 1.7 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include + +#include + +#include +#include + +isc_result_t +isc_keyboard_open(isc_keyboard_t *keyboard) { + int fd; + + REQUIRE(keyboard != NULL); + + fd = _fileno(stdin); + if (fd < 0) + return (ISC_R_IOERROR); + + keyboard->fd = fd; + + keyboard->result = ISC_R_SUCCESS; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_keyboard_close(isc_keyboard_t *keyboard, unsigned int sleeptime) { + REQUIRE(keyboard != NULL); + + if (sleeptime > 0 && keyboard->result != ISC_R_CANCELED) + (void)Sleep(sleeptime*1000); + + keyboard->fd = -1; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_keyboard_getchar(isc_keyboard_t *keyboard, unsigned char *cp) { + ssize_t cc; + unsigned char c; + + REQUIRE(keyboard != NULL); + REQUIRE(cp != NULL); + + cc = read(keyboard->fd, &c, 1); + if (cc < 0) { + keyboard->result = ISC_R_IOERROR; + return (keyboard->result); + } + + *cp = c; + + return (ISC_R_SUCCESS); +} + +isc_boolean_t +isc_keyboard_canceled(isc_keyboard_t *keyboard) { + return (ISC_TF(keyboard->result == ISC_R_CANCELED)); +} + diff --git a/contrib/ntp/lib/isc/win32/libgen.h b/contrib/ntp/lib/isc/win32/libgen.h new file mode 100644 index 000000000..1c58a9569 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/libgen.h @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2009 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: libgen.h,v 1.3 2009/07/17 23:47:41 tbox Exp $ */ + +#ifndef LIBGEN_H +#define LIBGEN_H 1 + +char *basename(const char *); +char *dirname(const char *); + +#endif diff --git a/contrib/ntp/lib/isc/win32/libisc.def b/contrib/ntp/lib/isc/win32/libisc.def new file mode 100644 index 000000000..fb084103d --- /dev/null +++ b/contrib/ntp/lib/isc/win32/libisc.def @@ -0,0 +1,583 @@ +LIBRARY libisc + +; Exported Functions +EXPORTS + +NTReportError +closelog +isc___mem_allocate +isc___mem_free +isc___mem_get +isc___mem_put +isc___mem_putanddetach +isc___mem_reallocate +isc___mem_strdup +isc___mempool_get +isc___mempool_put +isc___socketmgr_maxudp +isc__app_block +isc__app_finish +isc__app_onrun +isc__app_reload +isc__app_run +isc__app_shutdown +isc__app_start +isc__app_unblock +isc__backtrace_nsymbols +isc__backtrace_symtable +isc__buffer_activeregion +isc__buffer_add +isc__buffer_availableregion +isc__buffer_back +isc__buffer_clear +isc__buffer_consumedregion +isc__buffer_first +isc__buffer_forward +isc__buffer_init +isc__buffer_invalidate +isc__buffer_putmem +isc__buffer_putstr +isc__buffer_putuint16 +isc__buffer_putuint32 +isc__buffer_putuint48 +isc__buffer_putuint8 +isc__buffer_region +isc__buffer_remainingregion +isc__buffer_setactive +isc__buffer_subtract +isc__buffer_usedregion +isc__mem_attach +isc__mem_checkdestroyed +isc__mem_create +isc__mem_create2 +isc__mem_createx +isc__mem_createx2 +isc__mem_destroy +isc__mem_detach +isc__mem_getname +isc__mem_getquota +isc__mem_gettag +isc__mem_inuse +isc__mem_isovermem +isc__mem_ondestroy +isc__mem_references +isc__mem_setdestroycheck +isc__mem_setname +isc__mem_setquota +isc__mem_setwater +isc__mem_stats +isc__mem_waterack +isc__mempool_associatelock +isc__mempool_create +isc__mempool_destroy +isc__mempool_getallocated +isc__mempool_getfillcount +isc__mempool_getfreecount +isc__mempool_getfreemax +isc__mempool_getmaxalloc +isc__mempool_setfillcount +isc__mempool_setfreemax +isc__mempool_setmaxalloc +isc__mempool_setname +isc__socket_accept +isc__socket_attach +isc__socket_bind +isc__socket_cancel +isc__socket_cleanunix +isc__socket_close +isc__socket_connect +isc__socket_create +isc__socket_detach +isc__socket_dup +isc__socket_filter +isc__socket_getfd +isc__socket_getname +isc__socket_getpeername +isc__socket_getsockname +isc__socket_gettag +isc__socket_gettype +isc__socket_ipv6only +isc__socket_isbound +isc__socket_listen +isc__socket_open +isc__socket_permunix +isc__socket_recv +isc__socket_recv2 +isc__socket_recvv +isc__socket_send +isc__socket_sendto +isc__socket_sendto2 +isc__socket_sendtov +isc__socket_sendv +isc__socket_setname +isc__socketmgr_create +isc__socketmgr_create2 +isc__socketmgr_destroy +isc__socketmgr_getmaxsockets +isc__socketmgr_setreserved +isc__socketmgr_setstats +isc__strerror +isc__task_attach +isc__task_beginexclusive +isc__task_create +isc__task_destroy +isc__task_detach +isc__task_endexclusive +isc__task_getcurrenttime +isc__task_getname +isc__task_gettag +isc__task_onshutdown +isc__task_privilege +isc__task_purge +isc__task_purgeevent +isc__task_purgerange +isc__task_send +isc__task_sendanddetach +isc__task_setname +isc__task_setprivilege +isc__task_shutdown +isc__task_unsend +isc__task_unsendrange +isc__taskmgr_create +isc__taskmgr_destroy +isc__taskmgr_mode +isc__taskmgr_setmode +isc__timer_attach +isc__timer_create +isc__timer_detach +isc__timer_reset +isc__timer_touch +isc__timermgr_create +isc__timermgr_destroy +isc__timermgr_poke +isc_assertion_failed +isc_assertion_setcallback +isc_assertion_typetotext +isc_backtrace_getsymbol +isc_backtrace_getsymbolfromindex +isc_backtrace_gettrace +isc_base32_decoderegion +isc_base32_decodestring +isc_base32_tobuffer +isc_base32_totext +isc_base32hex_decoderegion +isc_base32hex_decodestring +isc_base32hex_tobuffer +isc_base32hex_totext +isc_base64_decodestring +isc_base64_tobuffer +isc_base64_totext +isc_bitstring_copy +isc_bitstring_init +isc_bitstring_invalidate +isc_buffer_allocate +isc_buffer_compact +isc_buffer_copyregion +isc_buffer_free +isc_buffer_getuint16 +isc_buffer_getuint32 +isc_buffer_getuint8 +isc_buffer_reinit +isc_bufferlist_availablecount +isc_bufferlist_usedcount +isc_commandline_parse +isc_condition_broadcast +isc_condition_destroy +isc_condition_init +isc_condition_signal +isc_condition_wait +isc_condition_waituntil +isc_dir_chdir +isc_dir_chroot +isc_dir_close +isc_dir_init +isc_dir_open +isc_dir_read +isc_dir_reset +isc_entropy_addcallbacksample +isc_entropy_addsample +isc_entropy_attach +isc_entropy_create +isc_entropy_createcallbacksource +isc_entropy_createfilesource +isc_entropy_createsamplesource +isc_entropy_destroysource +isc_entropy_detach +isc_entropy_getdata +isc_entropy_putdata +isc_entropy_stats +isc_entropy_status +isc_entropy_stopcallbacksources +isc_entropy_usebestsource +isc_error_fatal +isc_error_runtimecheck +isc_error_setfatal +isc_error_setunexpected +isc_error_unexpected +isc_event_allocate +isc_event_free +isc_file_absolutepath +isc_file_basename +isc_file_exists +isc_file_getmodtime +isc_file_isabsolute +isc_file_ischdiridempotent +isc_file_iscurrentdir +isc_file_isplainfile +isc_file_mktemplate +isc_file_openunique +isc_file_openuniquemode +isc_file_openuniqueprivate +isc_file_progname +isc_file_remove +isc_file_rename +isc_file_renameunique +isc_file_safecreate +isc_file_safemovefile +isc_file_settime +isc_file_splitpath +isc_file_template +isc_file_truncate +isc_fsaccess_add +isc_fsaccess_changeowner +isc_fsaccess_remove +isc_fsaccess_set +isc_hash_calc +isc_hash_create +isc_hash_ctxattach +isc_hash_ctxcalc +isc_hash_ctxcreate +isc_hash_ctxdetach +isc_hash_ctxinit +isc_hash_destroy +isc_hash_init +isc_heap_create +isc_heap_decreased +isc_heap_delete +isc_heap_destroy +isc_heap_element +isc_heap_increased +isc_heap_insert +isc_hex_decodestring +isc_hex_tobuffer +isc_hex_totext +isc_hmacmd5_init +isc_hmacmd5_invalidate +isc_hmacmd5_sign +isc_hmacmd5_update +isc_hmacmd5_verify +isc_hmacmd5_verify2 +isc_hmacsha1_init +isc_hmacsha1_invalidate +isc_hmacsha1_sign +isc_hmacsha1_update +isc_hmacsha1_verify +isc_hmacsha224_init +isc_hmacsha224_invalidate +isc_hmacsha224_sign +isc_hmacsha224_update +isc_hmacsha224_verify +isc_hmacsha256_init +isc_hmacsha256_invalidate +isc_hmacsha256_sign +isc_hmacsha256_update +isc_hmacsha256_verify +isc_hmacsha384_init +isc_hmacsha384_invalidate +isc_hmacsha384_sign +isc_hmacsha384_update +isc_hmacsha384_verify +isc_hmacsha512_init +isc_hmacsha512_invalidate +isc_hmacsha512_sign +isc_hmacsha512_update +isc_hmacsha512_verify +isc_httpdmgr_addurl +isc_httpdmgr_create +isc_httpdmgr_shutdown +isc_interfaceiter_create +isc_interfaceiter_current +isc_interfaceiter_destroy +isc_interfaceiter_first +isc_interfaceiter_next +isc_interval_iszero +isc_interval_set +isc_iterated_hash +isc_keyboard_canceled +isc_keyboard_close +isc_keyboard_getchar +isc_keyboard_open +isc_lex_close +isc_lex_create +isc_lex_destroy +isc_lex_getcomments +isc_lex_getlasttokentext +isc_lex_getmastertoken +isc_lex_getoctaltoken +isc_lex_getsourceline +isc_lex_getsourcename +isc_lex_getspecials +isc_lex_gettoken +isc_lex_isfile +isc_lex_openbuffer +isc_lex_openfile +isc_lex_openstream +isc_lex_setcomments +isc_lex_setspecials +isc_lex_ungettoken +isc_lfsr_generate +isc_lfsr_generate32 +isc_lfsr_init +isc_lfsr_skip +isc_lib_initmsgcat +isc_log_categorybyname +isc_log_closefilelogs +isc_log_create +isc_log_createchannel +isc_log_destroy +isc_log_getdebuglevel +isc_log_getduplicateinterval +isc_log_gettag +isc_log_ivwrite +isc_log_ivwrite1 +isc_log_iwrite +isc_log_iwrite1 +isc_log_modulebyname +isc_log_opensyslog +isc_log_registercategories +isc_log_registermodules +isc_log_setcontext +isc_log_setdebuglevel +isc_log_setduplicateinterval +isc_log_settag +isc_log_usechannel +isc_log_vwrite +isc_log_vwrite1 +isc_log_wouldlog +isc_log_write +isc_log_write1 +isc_logconfig_create +isc_logconfig_destroy +isc_logconfig_get +isc_logconfig_use +isc_md5_final +isc_md5_init +isc_md5_invalidate +isc_md5_update +isc_mem_renderxml +isc_msgcat_close +isc_msgcat_get +isc_msgcat_open +isc_mutexblock_destroy +isc_mutexblock_init +isc_net_aton +isc_net_disableipv4 +isc_net_disableipv6 +isc_net_getudpportrange +isc_net_ntop +isc_net_probe_ipv6only +isc_net_probe_ipv6pktinfo +isc_net_probeipv4 +isc_net_probeipv6 +isc_net_probeunix +isc_net_pton +isc_netaddr_any +isc_netaddr_any6 +isc_netaddr_eqprefix +isc_netaddr_equal +isc_netaddr_format +isc_netaddr_fromin +isc_netaddr_fromin6 +isc_netaddr_frompath +isc_netaddr_fromsockaddr +isc_netaddr_fromv4mapped +isc_netaddr_getzone +isc_netaddr_ismulticast +isc_netaddr_masktoprefixlen +isc_netaddr_prefixok +isc_netaddr_setzone +isc_netaddr_totext +isc_netscope_pton +isc_ntpaths_get +isc_ntpaths_init +isc_once_do +isc_ondestroy_init +isc_ondestroy_notify +isc_ondestroy_register +isc_os_ncpus +isc_parse_uint16 +isc_parse_uint32 +isc_parse_uint8 +isc_portset_add +isc_portset_addrange +isc_portset_create +isc_portset_destroy +isc_portset_isset +isc_portset_nports +isc_portset_remove +isc_portset_removerange +isc_quota_attach +isc_quota_destroy +isc_quota_detach +isc_quota_init +isc_quota_max +isc_quota_release +isc_quota_reserve +isc_quota_soft +isc_radix_create +isc_radix_destroy +isc_radix_insert +isc_radix_process +isc_radix_remove +isc_radix_search +isc_random_get +isc_random_jitter +isc_random_seed +isc_ratelimiter_attach +isc_ratelimiter_create +isc_ratelimiter_detach +isc_ratelimiter_enqueue +isc_ratelimiter_setinterval +isc_ratelimiter_setpertic +isc_ratelimiter_shutdown +isc_refcount_init +isc_region_compare +isc_resource_getcurlimit +isc_resource_getlimit +isc_resource_setlimit +isc_result_register +isc_result_totext +isc_rwlock_destroy +isc_rwlock_downgrade +isc_rwlock_init +isc_rwlock_lock +isc_rwlock_trylock +isc_rwlock_tryupgrade +isc_rwlock_unlock +isc_serial_eq +isc_serial_ge +isc_serial_gt +isc_serial_le +isc_serial_lt +isc_serial_ne +isc_sha1_final +isc_sha1_init +isc_sha1_invalidate +isc_sha1_update +isc_sha224_final +isc_sha224_init +isc_sha224_invalidate +isc_sha224_update +isc_sha256_data +isc_sha256_final +isc_sha256_init +isc_sha256_invalidate +isc_sha256_update +isc_sha384_final +isc_sha384_init +isc_sha384_invalidate +isc_sha384_update +isc_sha512_final +isc_sha512_init +isc_sha512_invalidate +isc_sha512_update +isc_sockaddr_any +isc_sockaddr_any6 +isc_sockaddr_anyofpf +isc_sockaddr_compare +isc_sockaddr_eqaddr +isc_sockaddr_eqaddrprefix +isc_sockaddr_equal +isc_sockaddr_format +isc_sockaddr_fromin +isc_sockaddr_fromin6 +isc_sockaddr_fromnetaddr +isc_sockaddr_frompath +isc_sockaddr_getport +isc_sockaddr_hash +isc_sockaddr_isexperimental +isc_sockaddr_ismulticast +isc_sockaddr_pf +isc_sockaddr_setport +isc_sockaddr_totext +isc_sockaddr_v6fromin +isc_socketmgr_renderxml +isc_stats_attach +isc_stats_create +isc_stats_decrement +isc_stats_detach +isc_stats_dump +isc_stats_increment +isc_stats_ncounters +isc_stdio_close +isc_stdio_flush +isc_stdio_open +isc_stdio_read +isc_stdio_seek +isc_stdio_sync +isc_stdio_write +isc_stdtime_get +isc_string_append +isc_string_append_truncate +isc_string_copy +isc_string_copy_truncate +isc_string_printf +isc_string_printf_truncate +isc_string_regiondup +isc_string_separate +isc_string_strlcat +isc_string_strlcpy +isc_string_touint64 +isc_symtab_create +isc_symtab_define +isc_symtab_destroy +isc_symtab_lookup +isc_symtab_undefine +isc_syslog_facilityfromstring +isc_taskmgr_renderxml +isc_taskpool_create +isc_taskpool_destroy +isc_taskpool_expand +isc_taskpool_gettask +isc_taskpool_setprivilege +isc_taskpool_size +isc_thread_create +isc_thread_join +isc_thread_key_create +isc_thread_key_delete +isc_thread_key_getspecific +isc_thread_key_setspecific +isc_thread_setconcurrency +isc_time_add +isc_time_compare +isc_time_formatISO8601 +isc_time_formattimestamp +isc_time_isepoch +isc_time_microdiff +isc_time_nanoseconds +isc_time_now +isc_time_nowplusinterval +isc_time_seconds +isc_time_set +isc_time_settoepoch +isc_time_subtract +isc_win32os_majorversion +isc_win32os_minorversion +isc_win32os_servicepackmajor +isc_win32os_servicepackminor +isc_win32os_versioncheck +openlog +syslog + +; Exported Data + +EXPORTS + +isc_commandline_argument DATA +isc_commandline_errprint DATA +isc_commandline_index DATA +isc_commandline_option DATA +isc_commandline_progname DATA +isc_commandline_reset DATA +isc_mem_debugging DATA + diff --git a/contrib/ntp/lib/isc/win32/libisc.dsp b/contrib/ntp/lib/isc/win32/libisc.dsp new file mode 100644 index 000000000..8e4441c39 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/libisc.dsp @@ -0,0 +1,802 @@ +# Microsoft Developer Studio Project File - Name="libisc" - Package Owner=<4> +# Microsoft Developer Studio Generated Build File, Format Version 6.00 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 + +CFG=libisc - Win32 Debug +!MESSAGE This is not a valid makefile. To build this project using NMAKE, +!MESSAGE use the Export Makefile command and run +!MESSAGE +!MESSAGE NMAKE /f "libisc.mak". +!MESSAGE +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "libisc.mak" CFG="libisc - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "libisc - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE "libisc - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE + +# Begin Project +# PROP AllowPerConfigDependencies 0 +# PROP Scc_ProjName "" +# PROP Scc_LocalPath "" +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe + +!IF "$(CFG)" == "libisc - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "BIND9" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBISC_EXPORTS" /YX /FD /c +# ADD CPP /nologo /MD /W3 /GX /O2 /I "./" /I "../../../" /I "../../../../libxml2-2.7.3/include" /I "include" /I "../include" /I "../noatomic/include" /I "win32" /I "../../isccfg/include" /D "BIND9" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBISC_EXPORTS" /YX /FD /c +# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 +# ADD LINK32 ../../../../libxml2-2.7.3/win32/bin.msvc/libxml2.lib +# ADD LINK32 user32.lib advapi32.lib ws2_32.lib /nologo /dll /machine:I386 /out:"../../../Build/Release/libisc.dll" +# SUBTRACT LINK32 /pdb:none + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Ignore_Export_Lib 0 +# PROP Target_Dir "" +# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "BIND9" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBISC_EXPORTS" /YX /FD /GZ /c +# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../../libxml2-2.7.3/include" /I "include" /I "../include" /I "../noatomic/include" /I "win32" /I "../../isccfg/include" /D "BIND9" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "__STDC__" /D "_MBCS" /D "_USRDLL" /D "LIBISC_EXPORTS" /FR /YX /FD /GZ /c +# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept +# ADD LINK32 ../../../../libxml2-2.7.3/win32/bin.msvc/libxml2.lib +# ADD LINK32 user32.lib advapi32.lib ws2_32.lib /nologo /dll /map /debug /machine:I386 /out:"../../../Build/Debug/libisc.dll" /pdbtype:sept + +!ENDIF + +# Begin Target + +# Name "libisc - Win32 Release" +# Name "libisc - Win32 Debug" +# Begin Group "Source Files" + +# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" +# Begin Source File + +SOURCE=.\app.c +# End Source File +# Begin Source File + +SOURCE=.\condition.c +# End Source File +# Begin Source File + +SOURCE=.\dir.c +# End Source File +# Begin Source File + +SOURCE=.\DLLMain.c +# End Source File +# Begin Source File + +SOURCE=.\entropy.c +# End Source File +# Begin Source File + +SOURCE=.\errno2result.c +# End Source File +# Begin Source File + +SOURCE=.\file.c +# End Source File +# Begin Source File + +SOURCE=.\fsaccess.c +# End Source File +# Begin Source File + +SOURCE=.\interfaceiter.c +# End Source File +# Begin Source File + +SOURCE=.\ipv6.c +# End Source File +# Begin Source File + +SOURCE=..\iterated_hash.c +# End Source File +# Begin Source File + +SOURCE=.\keyboard.c +# End Source File +# Begin Source File + +SOURCE=.\net.c +# End Source File +# Begin Source File + +SOURCE=.\ntpaths.c +# End Source File +# Begin Source File + +SOURCE=.\once.c +# End Source File +# Begin Source File + +SOURCE=.\os.c +# End Source File +# Begin Source File + +SOURCE=.\resource.c +# End Source File +# Begin Source File + +SOURCE=.\socket.c +# End Source File +# Begin Source File + +SOURCE=.\strerror.c +# End Source File +# Begin Source File + +SOURCE=.\stdio.c +# End Source File +# Begin Source File + +SOURCE=.\stdtime.c +# End Source File +# Begin Source File + +SOURCE=.\syslog.c +# End Source File +# Begin Source File + +SOURCE=.\thread.c +# End Source File +# Begin Source File + +SOURCE=.\time.c +# End Source File +# Begin Source File + +SOURCE=.\version.c +# End Source File +# End Group +# Begin Group "Header Files" + +# PROP Default_Filter "h;hpp;hxx;hm;inl" +# Begin Source File + +SOURCE=.\include\isc\app.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\assertions.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\backtrace.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\backtrace-emptytbl.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\base32.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\base64.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\bind_registry.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\bindevt.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\bitstring.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\boolean.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\buffer.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\bufferlist.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\commandline.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\condition.h +# End Source File +# Begin Source File + +SOURCE=..\..\..\config.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\dir.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\entropy.h +# End Source File +# Begin Source File + +SOURCE=.\errno2result.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\error.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\event.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\eventclass.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\file.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\formatcheck.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\fsaccess.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\hash.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\heap.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\hex.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\hmacmd5.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\hmacsha.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\httpd.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\int.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\interfaceiter.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\ipv6.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\iterated_hash.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\keyboard.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\lang.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\lex.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\lfsr.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\lib.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\list.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\log.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\magic.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\md5.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\mem.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\msgcat.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\msioctl.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\mutex.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\mutexblock.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\net.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\netaddr.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\netscope.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\netdb.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\ntpaths.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\offset.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\once.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\ondestroy.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\parseint.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\portset.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\os.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\platform.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\print.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\quota.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\radix.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\random.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\ratelimiter.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\refcount.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\region.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\resource.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\result.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\resultclass.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\rwlock.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\serial.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\sha1.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\sha2.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\sockaddr.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\socket.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\stats.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\stdio.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\strerror.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\stdtime.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\string.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\symtab.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\syslog.h +# End Source File +# Begin Source File + +SOURCE=.\syslog.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\task.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\taskpool.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\thread.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\time.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\timer.h +# End Source File +# Begin Source File + +SOURCE=.\include\isc\win32os.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\types.h +# End Source File +# Begin Source File + +SOURCE=.\unistd.h +# End Source File +# Begin Source File + +SOURCE=..\include\isc\util.h +# End Source File +# Begin Source File + +SOURCE=..\..\..\versions.h +# End Source File +# End Group +# Begin Group "Resource Files" + +# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" +# End Group +# Begin Group "Main Isc Lib" + +# PROP Default_Filter "c" +# Begin Source File + +SOURCE=..\assertions.c +# End Source File +# Begin Source File + +SOURCE=..\backtrace.c +# End Source File +# Begin Source File + +SOURCE=..\backtrace-emptytbl.c +# End Source File +# Begin Source File + +SOURCE=..\base32.c +# End Source File +# Begin Source File + +SOURCE=..\base64.c +# End Source File +# Begin Source File + +SOURCE=..\bitstring.c +# End Source File +# Begin Source File + +SOURCE=..\buffer.c +# End Source File +# Begin Source File + +SOURCE=..\bufferlist.c +# End Source File +# Begin Source File + +SOURCE=..\commandline.c +# End Source File +# Begin Source File + +SOURCE=..\error.c +# End Source File +# Begin Source File + +SOURCE=..\event.c +# End Source File +# Begin Source File + +SOURCE=..\hash.c +# End Source File +# Begin Source File + +SOURCE=..\heap.c +# End Source File +# Begin Source File + +SOURCE=..\hex.c +# End Source File +# Begin Source File + +SOURCE=..\hmacmd5.c +# End Source File +# Begin Source File + +SOURCE=..\hmacsha.c +# End Source File +# Begin Source File + +SOURCE=..\httpd.c +# End Source File +# Begin Source File + +SOURCE=..\inet_aton.c +# End Source File +# Begin Source File + +SOURCE=..\inet_ntop.c +# End Source File +# Begin Source File + +SOURCE=..\inet_pton.c +# End Source File +# Begin Source File + +SOURCE=..\lex.c +# End Source File +# Begin Source File + +SOURCE=..\lfsr.c +# End Source File +# Begin Source File + +SOURCE=..\lib.c +# End Source File +# Begin Source File + +SOURCE=..\log.c +# End Source File +# Begin Source File + +SOURCE=..\md5.c +# End Source File +# Begin Source File + +SOURCE=..\mem.c +# End Source File +# Begin Source File + +SOURCE=..\nls\msgcat.c +# End Source File +# Begin Source File + +SOURCE=..\mutexblock.c +# End Source File +# Begin Source File + +SOURCE=..\netaddr.c +# End Source File +# Begin Source File + +SOURCE=..\netscope.c +# End Source File +# Begin Source File + +SOURCE=..\ondestroy.c +# End Source File +# Begin Source File + +SOURCE=..\parseint.c +# End Source File +# Begin Source File + +SOURCE=..\portset.c +# End Source File +# Begin Source File + +SOURCE=..\quota.c +# End Source File +# Begin Source File + +SOURCE=..\radix.c +# End Source File +# Begin Source File + +SOURCE=..\random.c +# End Source File +# Begin Source File + +SOURCE=..\ratelimiter.c +# End Source File +# Begin Source File + +SOURCE=..\refcount.c +# End Source File +# Begin Source File + +SOURCE=..\region.c +# End Source File +# Begin Source File + +SOURCE=..\result.c +# End Source File +# Begin Source File + +SOURCE=..\rwlock.c +# End Source File +# Begin Source File + +SOURCE=..\serial.c +# End Source File +# Begin Source File + +SOURCE=..\sha1.c +# End Source File +# Begin Source File + +SOURCE=..\sha2.c +# End Source File +# Begin Source File + +SOURCE=..\sockaddr.c +# End Source File +# Begin Source File + +SOURCE=..\stats.c +# End Source File +# Begin Source File + +SOURCE=..\string.c +# End Source File +# Begin Source File + +SOURCE=..\symtab.c +# End Source File +# Begin Source File + +SOURCE=..\task.c +# End Source File +# Begin Source File + +SOURCE=..\taskpool.c +# End Source File +# Begin Source File + +SOURCE=..\timer.c +# End Source File +# Begin Source File + +SOURCE=.\win32os.c +# End Source File +# End Group +# Begin Source File + +SOURCE=..\noatomic\include\atomic.h +# End Source File +# Begin Source File + +SOURCE=.\libisc.def +# End Source File +# End Target +# End Project diff --git a/contrib/ntp/lib/isc/win32/libisc.dsw b/contrib/ntp/lib/isc/win32/libisc.dsw new file mode 100644 index 000000000..c66c56e53 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/libisc.dsw @@ -0,0 +1,29 @@ +Microsoft Developer Studio Workspace File, Format Version 6.00 +# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE! + +############################################################################### + +Project: "libisc"=".\libisc.dsp" - Package Owner=<4> + +Package=<5> +{{{ +}}} + +Package=<4> +{{{ +}}} + +############################################################################### + +Global: + +Package=<5> +{{{ +}}} + +Package=<3> +{{{ +}}} + +############################################################################### + diff --git a/contrib/ntp/lib/isc/win32/libisc.mak b/contrib/ntp/lib/isc/win32/libisc.mak new file mode 100644 index 000000000..e15b46b3f --- /dev/null +++ b/contrib/ntp/lib/isc/win32/libisc.mak @@ -0,0 +1,2055 @@ +# Microsoft Developer Studio Generated NMAKE File, Based on libisc.dsp +!IF "$(CFG)" == "" +CFG=libisc - Win32 Debug +!MESSAGE No configuration specified. Defaulting to libisc - Win32 Debug. +!ENDIF + +!IF "$(CFG)" != "libisc - Win32 Release" && "$(CFG)" != "libisc - Win32 Debug" +!MESSAGE Invalid configuration "$(CFG)" specified. +!MESSAGE You can specify a configuration when running NMAKE +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "libisc.mak" CFG="libisc - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "libisc - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE "libisc - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") +!MESSAGE +!ERROR An invalid configuration is specified. +!ENDIF + +!IF "$(OS)" == "Windows_NT" +NULL= +!ELSE +NULL=nul +!ENDIF + +CPP=cl.exe +MTL=midl.exe +RSC=rc.exe +LIBXML=../../../../libxml2-2.7.3/win32/bin.msvc/libxml2.lib + +!IF "$(CFG)" == "libisc - Win32 Release" +_VC_MANIFEST_INC=0 +_VC_MANIFEST_BASENAME=__VC80 +!ELSE +_VC_MANIFEST_INC=1 +_VC_MANIFEST_BASENAME=__VC80.Debug +!ENDIF + +#################################################### +# Specifying name of temporary resource file used only in incremental builds: + +!if "$(_VC_MANIFEST_INC)" == "1" +_VC_MANIFEST_AUTO_RES=$(_VC_MANIFEST_BASENAME).auto.res +!else +_VC_MANIFEST_AUTO_RES= +!endif + +#################################################### +# _VC_MANIFEST_EMBED_EXE - command to embed manifest in EXE: + +!if "$(_VC_MANIFEST_INC)" == "1" + +#MT_SPECIAL_RETURN=1090650113 +#MT_SPECIAL_SWITCH=-notify_resource_update +MT_SPECIAL_RETURN=0 +MT_SPECIAL_SWITCH= +_VC_MANIFEST_EMBED_EXE= \ +if exist $@.manifest mt.exe -manifest $@.manifest -out:$(_VC_MANIFEST_BASENAME).auto.manifest $(MT_SPECIAL_SWITCH) & \ +if "%ERRORLEVEL%" == "$(MT_SPECIAL_RETURN)" \ +rc /r $(_VC_MANIFEST_BASENAME).auto.rc & \ +link $** /out:$@ $(LFLAGS) + +!else + +_VC_MANIFEST_EMBED_EXE= \ +if exist $@.manifest mt.exe -manifest $@.manifest -outputresource:$@;1 + +!endif + +#################################################### +# _VC_MANIFEST_EMBED_DLL - command to embed manifest in DLL: + +!if "$(_VC_MANIFEST_INC)" == "1" + +#MT_SPECIAL_RETURN=1090650113 +#MT_SPECIAL_SWITCH=-notify_resource_update +MT_SPECIAL_RETURN=0 +MT_SPECIAL_SWITCH= +_VC_MANIFEST_EMBED_EXE= \ +if exist $@.manifest mt.exe -manifest $@.manifest -out:$(_VC_MANIFEST_BASENAME).auto.manifest $(MT_SPECIAL_SWITCH) & \ +if "%ERRORLEVEL%" == "$(MT_SPECIAL_RETURN)" \ +rc /r $(_VC_MANIFEST_BASENAME).auto.rc & \ +link $** /out:$@ $(LFLAGS) + +!else + +_VC_MANIFEST_EMBED_EXE= \ +if exist $@.manifest mt.exe -manifest $@.manifest -outputresource:$@;2 + +!endif +#################################################### +# _VC_MANIFEST_CLEAN - command to clean resources files generated temporarily: + +!if "$(_VC_MANIFEST_INC)" == "1" + +_VC_MANIFEST_CLEAN=-del $(_VC_MANIFEST_BASENAME).auto.res \ + $(_VC_MANIFEST_BASENAME).auto.rc \ + $(_VC_MANIFEST_BASENAME).auto.manifest + +!else + +_VC_MANIFEST_CLEAN= + +!endif + +!IF "$(CFG)" == "libisc - Win32 Release" + +OUTDIR=.\Release +INTDIR=.\Release + +ALL : "..\..\..\Build\Release\libisc.dll" + + +CLEAN : + -@erase "$(INTDIR)\app.obj" + -@erase "$(INTDIR)\assertions.obj" + -@erase "$(INTDIR)\backtrace.obj" + -@erase "$(INTDIR)\backtrace-emptytbl.obj" + -@erase "$(INTDIR)\base32.obj" + -@erase "$(INTDIR)\base64.obj" + -@erase "$(INTDIR)\bitstring.obj" + -@erase "$(INTDIR)\buffer.obj" + -@erase "$(INTDIR)\bufferlist.obj" + -@erase "$(INTDIR)\commandline.obj" + -@erase "$(INTDIR)\condition.obj" + -@erase "$(INTDIR)\dir.obj" + -@erase "$(INTDIR)\DLLMain.obj" + -@erase "$(INTDIR)\entropy.obj" + -@erase "$(INTDIR)\errno2result.obj" + -@erase "$(INTDIR)\error.obj" + -@erase "$(INTDIR)\event.obj" + -@erase "$(INTDIR)\file.obj" + -@erase "$(INTDIR)\fsaccess.obj" + -@erase "$(INTDIR)\hash.obj" + -@erase "$(INTDIR)\heap.obj" + -@erase "$(INTDIR)\hex.obj" + -@erase "$(INTDIR)\hmacmd5.obj" + -@erase "$(INTDIR)\hmacsha.obj" + -@erase "$(INTDIR)\httpd.obj" + -@erase "$(INTDIR)\inet_aton.obj" + -@erase "$(INTDIR)\inet_ntop.obj" + -@erase "$(INTDIR)\inet_pton.obj" + -@erase "$(INTDIR)\interfaceiter.obj" + -@erase "$(INTDIR)\ipv6.obj" + -@erase "$(INTDIR)\iterated_hash.obj" + -@erase "$(INTDIR)\keyboard.obj" + -@erase "$(INTDIR)\lex.obj" + -@erase "$(INTDIR)\lfsr.obj" + -@erase "$(INTDIR)\lib.obj" + -@erase "$(INTDIR)\log.obj" + -@erase "$(INTDIR)\md5.obj" + -@erase "$(INTDIR)\mem.obj" + -@erase "$(INTDIR)\msgcat.obj" + -@erase "$(INTDIR)\mutexblock.obj" + -@erase "$(INTDIR)\net.obj" + -@erase "$(INTDIR)\netaddr.obj" + -@erase "$(INTDIR)\netscope.obj" + -@erase "$(INTDIR)\ntpaths.obj" + -@erase "$(INTDIR)\once.obj" + -@erase "$(INTDIR)\ondestroy.obj" + -@erase "$(INTDIR)\os.obj" + -@erase "$(INTDIR)\parseint.obj" + -@erase "$(INTDIR)\portset.obj" + -@erase "$(INTDIR)\quota.obj" + -@erase "$(INTDIR)\radix.obj" + -@erase "$(INTDIR)\random.obj" + -@erase "$(INTDIR)\ratelimiter.obj" + -@erase "$(INTDIR)\refcount.obj" + -@erase "$(INTDIR)\region.obj" + -@erase "$(INTDIR)\resource.obj" + -@erase "$(INTDIR)\result.obj" + -@erase "$(INTDIR)\rwlock.obj" + -@erase "$(INTDIR)\serial.obj" + -@erase "$(INTDIR)\sha1.obj" + -@erase "$(INTDIR)\sha2.obj" + -@erase "$(INTDIR)\sockaddr.obj" + -@erase "$(INTDIR)\socket.obj" + -@erase "$(INTDIR)\stats.obj" + -@erase "$(INTDIR)\stdio.obj" + -@erase "$(INTDIR)\stdtime.obj" + -@erase "$(INTDIR)\strerror.obj" + -@erase "$(INTDIR)\string.obj" + -@erase "$(INTDIR)\symtab.obj" + -@erase "$(INTDIR)\syslog.obj" + -@erase "$(INTDIR)\task.obj" + -@erase "$(INTDIR)\taskpool.obj" + -@erase "$(INTDIR)\thread.obj" + -@erase "$(INTDIR)\time.obj" + -@erase "$(INTDIR)\timer.obj" + -@erase "$(INTDIR)\vc60.idb" + -@erase "$(INTDIR)\version.obj" + -@erase "$(INTDIR)\win32os.obj" + -@erase "$(OUTDIR)\libisc.exp" + -@erase "$(OUTDIR)\libisc.lib" + -@erase "..\..\..\Build\Release\libisc.dll" + -@$(_VC_MANIFEST_CLEAN) + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "./" /I "../../../" /I "include" /I "../include" /I "../../../lib/isc/noatomic/include" /I "win32" /I "../../isccfg/include" /I "../../../../libxml2-2.7.3/include" /D "BIND9" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBISC_EXPORTS" /Fp"$(INTDIR)\libisc.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c +MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32 +BSC32=bscmake.exe +BSC32_FLAGS=/nologo /o"$(OUTDIR)\libisc.bsc" +BSC32_SBRS= \ + +LINK32=link.exe +LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib $(LIBXML) /nologo /dll /incremental:no /pdb:"$(OUTDIR)\libisc.pdb" /machine:I386 /def:".\libisc.def" /out:"../../../Build/Release/libisc.dll" /implib:"$(OUTDIR)\libisc.lib" +DEF_FILE= \ + ".\libisc.def" +LINK32_OBJS= \ + "$(INTDIR)\app.obj" \ + "$(INTDIR)\condition.obj" \ + "$(INTDIR)\dir.obj" \ + "$(INTDIR)\DLLMain.obj" \ + "$(INTDIR)\entropy.obj" \ + "$(INTDIR)\errno2result.obj" \ + "$(INTDIR)\file.obj" \ + "$(INTDIR)\fsaccess.obj" \ + "$(INTDIR)\interfaceiter.obj" \ + "$(INTDIR)\ipv6.obj" \ + "$(INTDIR)\iterated_hash.obj" \ + "$(INTDIR)\keyboard.obj" \ + "$(INTDIR)\net.obj" \ + "$(INTDIR)\ntpaths.obj" \ + "$(INTDIR)\once.obj" \ + "$(INTDIR)\os.obj" \ + "$(INTDIR)\resource.obj" \ + "$(INTDIR)\socket.obj" \ + "$(INTDIR)\stdio.obj" \ + "$(INTDIR)\stdtime.obj" \ + "$(INTDIR)\strerror.obj" \ + "$(INTDIR)\syslog.obj" \ + "$(INTDIR)\thread.obj" \ + "$(INTDIR)\time.obj" \ + "$(INTDIR)\version.obj" \ + "$(INTDIR)\win32os.obj" \ + "$(INTDIR)\assertions.obj" \ + "$(INTDIR)\backtrace.obj" \ + "$(INTDIR)\backtrace-emptytbl.obj" \ + "$(INTDIR)\base32.obj" \ + "$(INTDIR)\base64.obj" \ + "$(INTDIR)\bitstring.obj" \ + "$(INTDIR)\buffer.obj" \ + "$(INTDIR)\bufferlist.obj" \ + "$(INTDIR)\commandline.obj" \ + "$(INTDIR)\error.obj" \ + "$(INTDIR)\event.obj" \ + "$(INTDIR)\hash.obj" \ + "$(INTDIR)\heap.obj" \ + "$(INTDIR)\hex.obj" \ + "$(INTDIR)\hmacmd5.obj" \ + "$(INTDIR)\hmacsha.obj" \ + "$(INTDIR)\httpd.obj" \ + "$(INTDIR)\inet_aton.obj" \ + "$(INTDIR)\inet_ntop.obj" \ + "$(INTDIR)\inet_pton.obj" \ + "$(INTDIR)\lex.obj" \ + "$(INTDIR)\lfsr.obj" \ + "$(INTDIR)\lib.obj" \ + "$(INTDIR)\log.obj" \ + "$(INTDIR)\md5.obj" \ + "$(INTDIR)\mem.obj" \ + "$(INTDIR)\msgcat.obj" \ + "$(INTDIR)\mutexblock.obj" \ + "$(INTDIR)\netaddr.obj" \ + "$(INTDIR)\netscope.obj" \ + "$(INTDIR)\ondestroy.obj" \ + "$(INTDIR)\quota.obj" \ + "$(INTDIR)\radix.obj" \ + "$(INTDIR)\random.obj" \ + "$(INTDIR)\ratelimiter.obj" \ + "$(INTDIR)\refcount.obj" \ + "$(INTDIR)\result.obj" \ + "$(INTDIR)\rwlock.obj" \ + "$(INTDIR)\serial.obj" \ + "$(INTDIR)\sha1.obj" \ + "$(INTDIR)\sha2.obj" \ + "$(INTDIR)\sockaddr.obj" \ + "$(INTDIR)\stats.obj" \ + "$(INTDIR)\string.obj" \ + "$(INTDIR)\symtab.obj" \ + "$(INTDIR)\task.obj" \ + "$(INTDIR)\taskpool.obj" \ + "$(INTDIR)\timer.obj" \ + "$(INTDIR)\parseint.obj" \ + "$(INTDIR)\portset.obj" \ + "$(INTDIR)\region.obj" + +"..\..\..\Build\Release\libisc.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + $(_VC_MANIFEST_EMBED_DLL) + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + +OUTDIR=.\Debug +INTDIR=.\Debug +# Begin Custom Macros +OutDir=.\Debug +# End Custom Macros + +ALL : "..\..\..\Build\Debug\libisc.dll" "$(OUTDIR)\libisc.bsc" + + +CLEAN : + -@erase "$(INTDIR)\app.obj" + -@erase "$(INTDIR)\app.sbr" + -@erase "$(INTDIR)\assertions.obj" + -@erase "$(INTDIR)\assertions.sbr" + -@erase "$(INTDIR)\backtrace.obj" + -@erase "$(INTDIR)\backtrace-emptytbl.obj" + -@erase "$(INTDIR)\backtrace.sbr" + -@erase "$(INTDIR)\backtrace-emptytbl.sbr" + -@erase "$(INTDIR)\base32.obj" + -@erase "$(INTDIR)\base32.sbr" + -@erase "$(INTDIR)\base64.obj" + -@erase "$(INTDIR)\base64.sbr" + -@erase "$(INTDIR)\bitstring.obj" + -@erase "$(INTDIR)\bitstring.sbr" + -@erase "$(INTDIR)\buffer.obj" + -@erase "$(INTDIR)\buffer.sbr" + -@erase "$(INTDIR)\bufferlist.obj" + -@erase "$(INTDIR)\bufferlist.sbr" + -@erase "$(INTDIR)\commandline.obj" + -@erase "$(INTDIR)\commandline.sbr" + -@erase "$(INTDIR)\condition.obj" + -@erase "$(INTDIR)\condition.sbr" + -@erase "$(INTDIR)\dir.obj" + -@erase "$(INTDIR)\dir.sbr" + -@erase "$(INTDIR)\DLLMain.obj" + -@erase "$(INTDIR)\DLLMain.sbr" + -@erase "$(INTDIR)\entropy.obj" + -@erase "$(INTDIR)\entropy.sbr" + -@erase "$(INTDIR)\errno2result.obj" + -@erase "$(INTDIR)\errno2result.sbr" + -@erase "$(INTDIR)\error.obj" + -@erase "$(INTDIR)\error.sbr" + -@erase "$(INTDIR)\event.obj" + -@erase "$(INTDIR)\event.sbr" + -@erase "$(INTDIR)\file.obj" + -@erase "$(INTDIR)\file.sbr" + -@erase "$(INTDIR)\fsaccess.obj" + -@erase "$(INTDIR)\fsaccess.sbr" + -@erase "$(INTDIR)\hash.obj" + -@erase "$(INTDIR)\hash.sbr" + -@erase "$(INTDIR)\heap.obj" + -@erase "$(INTDIR)\heap.sbr" + -@erase "$(INTDIR)\hex.obj" + -@erase "$(INTDIR)\hex.sbr" + -@erase "$(INTDIR)\hmacmd5.obj" + -@erase "$(INTDIR)\hmacmd5.sbr" + -@erase "$(INTDIR)\hmacsha.obj" + -@erase "$(INTDIR)\hmacsha.sbr" + -@erase "$(INTDIR)\httpd.obj" + -@erase "$(INTDIR)\httpd.sbr" + -@erase "$(INTDIR)\inet_aton.obj" + -@erase "$(INTDIR)\inet_aton.sbr" + -@erase "$(INTDIR)\inet_ntop.obj" + -@erase "$(INTDIR)\inet_ntop.sbr" + -@erase "$(INTDIR)\inet_pton.obj" + -@erase "$(INTDIR)\inet_pton.sbr" + -@erase "$(INTDIR)\interfaceiter.obj" + -@erase "$(INTDIR)\interfaceiter.sbr" + -@erase "$(INTDIR)\ipv6.obj" + -@erase "$(INTDIR)\ipv6.sbr" + -@erase "$(INTDIR)\iterated_hash.obj" + -@erase "$(INTDIR)\iterated_hash.sbr" + -@erase "$(INTDIR)\keyboard.obj" + -@erase "$(INTDIR)\keyboard.sbr" + -@erase "$(INTDIR)\lex.obj" + -@erase "$(INTDIR)\lex.sbr" + -@erase "$(INTDIR)\lfsr.obj" + -@erase "$(INTDIR)\lfsr.sbr" + -@erase "$(INTDIR)\lib.obj" + -@erase "$(INTDIR)\lib.sbr" + -@erase "$(INTDIR)\log.obj" + -@erase "$(INTDIR)\log.sbr" + -@erase "$(INTDIR)\md5.obj" + -@erase "$(INTDIR)\md5.sbr" + -@erase "$(INTDIR)\mem.obj" + -@erase "$(INTDIR)\mem.sbr" + -@erase "$(INTDIR)\msgcat.obj" + -@erase "$(INTDIR)\msgcat.sbr" + -@erase "$(INTDIR)\mutexblock.obj" + -@erase "$(INTDIR)\mutexblock.sbr" + -@erase "$(INTDIR)\net.obj" + -@erase "$(INTDIR)\net.sbr" + -@erase "$(INTDIR)\netaddr.obj" + -@erase "$(INTDIR)\netaddr.sbr" + -@erase "$(INTDIR)\netscope.obj" + -@erase "$(INTDIR)\netscope.sbr" + -@erase "$(INTDIR)\ntpaths.obj" + -@erase "$(INTDIR)\ntpaths.sbr" + -@erase "$(INTDIR)\once.obj" + -@erase "$(INTDIR)\once.sbr" + -@erase "$(INTDIR)\ondestroy.obj" + -@erase "$(INTDIR)\ondestroy.sbr" + -@erase "$(INTDIR)\os.obj" + -@erase "$(INTDIR)\os.sbr" + -@erase "$(INTDIR)\parseint.obj" + -@erase "$(INTDIR)\parseint.sbr" + -@erase "$(INTDIR)\portset.obj" + -@erase "$(INTDIR)\portset.sbr" + -@erase "$(INTDIR)\quota.obj" + -@erase "$(INTDIR)\quota.sbr" + -@erase "$(INTDIR)\radix.obj" + -@erase "$(INTDIR)\radix.sbr" + -@erase "$(INTDIR)\random.obj" + -@erase "$(INTDIR)\random.sbr" + -@erase "$(INTDIR)\ratelimiter.obj" + -@erase "$(INTDIR)\ratelimiter.sbr" + -@erase "$(INTDIR)\refcount.obj" + -@erase "$(INTDIR)\refcount.sbr" + -@erase "$(INTDIR)\region.obj" + -@erase "$(INTDIR)\region.sbr" + -@erase "$(INTDIR)\resource.obj" + -@erase "$(INTDIR)\resource.sbr" + -@erase "$(INTDIR)\result.obj" + -@erase "$(INTDIR)\result.sbr" + -@erase "$(INTDIR)\rwlock.obj" + -@erase "$(INTDIR)\rwlock.sbr" + -@erase "$(INTDIR)\serial.obj" + -@erase "$(INTDIR)\serial.sbr" + -@erase "$(INTDIR)\sha1.obj" + -@erase "$(INTDIR)\sha1.sbr" + -@erase "$(INTDIR)\sha2.obj" + -@erase "$(INTDIR)\sha2.sbr" + -@erase "$(INTDIR)\sockaddr.obj" + -@erase "$(INTDIR)\sockaddr.sbr" + -@erase "$(INTDIR)\socket.obj" + -@erase "$(INTDIR)\socket.sbr" + -@erase "$(INTDIR)\stats.obj" + -@erase "$(INTDIR)\stats.sbr" + -@erase "$(INTDIR)\stdio.obj" + -@erase "$(INTDIR)\stdio.sbr" + -@erase "$(INTDIR)\stdtime.obj" + -@erase "$(INTDIR)\stdtime.sbr" + -@erase "$(INTDIR)\strerror.obj" + -@erase "$(INTDIR)\strerror.sbr" + -@erase "$(INTDIR)\string.obj" + -@erase "$(INTDIR)\string.sbr" + -@erase "$(INTDIR)\symtab.obj" + -@erase "$(INTDIR)\symtab.sbr" + -@erase "$(INTDIR)\syslog.obj" + -@erase "$(INTDIR)\syslog.sbr" + -@erase "$(INTDIR)\task.obj" + -@erase "$(INTDIR)\task.sbr" + -@erase "$(INTDIR)\taskpool.obj" + -@erase "$(INTDIR)\taskpool.sbr" + -@erase "$(INTDIR)\thread.obj" + -@erase "$(INTDIR)\thread.sbr" + -@erase "$(INTDIR)\time.obj" + -@erase "$(INTDIR)\time.sbr" + -@erase "$(INTDIR)\timer.obj" + -@erase "$(INTDIR)\timer.sbr" + -@erase "$(INTDIR)\vc60.idb" + -@erase "$(INTDIR)\vc60.pdb" + -@erase "$(INTDIR)\version.obj" + -@erase "$(INTDIR)\version.sbr" + -@erase "$(INTDIR)\win32os.obj" + -@erase "$(INTDIR)\win32os.sbr" + -@erase "$(OUTDIR)\libisc.bsc" + -@erase "$(OUTDIR)\libisc.exp" + -@erase "$(OUTDIR)\libisc.lib" + -@erase "$(OUTDIR)\libisc.map" + -@erase "$(OUTDIR)\libisc.pdb" + -@erase "..\..\..\Build\Debug\libisc.dll" + -@erase "..\..\..\Build\Debug\libisc.ilk" + -@$(_VC_MANIFEST_CLEAN) + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "include" /I "../include" /I "../../../lib/isc/noatomic/include" /I "win32" /I "../../isccfg/include" /I "../../../../libxml2-2.7.3/include" /D "BIND9" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "__STDC__" /D "_MBCS" /D "_USRDLL" /D "LIBISC_EXPORTS" /FR"$(INTDIR)\\" /Fp"$(INTDIR)\libisc.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c +MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32 +BSC32=bscmake.exe +BSC32_FLAGS=/nologo /o"$(OUTDIR)\libisc.bsc" +BSC32_SBRS= \ + "$(INTDIR)\app.sbr" \ + "$(INTDIR)\condition.sbr" \ + "$(INTDIR)\dir.sbr" \ + "$(INTDIR)\DLLMain.sbr" \ + "$(INTDIR)\entropy.sbr" \ + "$(INTDIR)\errno2result.sbr" \ + "$(INTDIR)\file.sbr" \ + "$(INTDIR)\fsaccess.sbr" \ + "$(INTDIR)\interfaceiter.sbr" \ + "$(INTDIR)\ipv6.sbr" \ + "$(INTDIR)\iterated_hash.sbr" \ + "$(INTDIR)\keyboard.sbr" \ + "$(INTDIR)\net.sbr" \ + "$(INTDIR)\ntpaths.sbr" \ + "$(INTDIR)\once.sbr" \ + "$(INTDIR)\os.sbr" \ + "$(INTDIR)\resource.sbr" \ + "$(INTDIR)\socket.sbr" \ + "$(INTDIR)\stdio.sbr" \ + "$(INTDIR)\stdtime.sbr" \ + "$(INTDIR)\strerror.sbr" \ + "$(INTDIR)\syslog.sbr" \ + "$(INTDIR)\thread.sbr" \ + "$(INTDIR)\time.sbr" \ + "$(INTDIR)\version.sbr" \ + "$(INTDIR)\win32os.sbr" \ + "$(INTDIR)\assertions.sbr" \ + "$(INTDIR)\backtrace.sbr" \ + "$(INTDIR)\backtrace-emptytbl.sbr" \ + "$(INTDIR)\base32.sbr" \ + "$(INTDIR)\base64.sbr" \ + "$(INTDIR)\bitstring.sbr" \ + "$(INTDIR)\buffer.sbr" \ + "$(INTDIR)\bufferlist.sbr" \ + "$(INTDIR)\commandline.sbr" \ + "$(INTDIR)\error.sbr" \ + "$(INTDIR)\event.sbr" \ + "$(INTDIR)\hash.sbr" \ + "$(INTDIR)\heap.sbr" \ + "$(INTDIR)\hex.sbr" \ + "$(INTDIR)\hmacmd5.sbr" \ + "$(INTDIR)\hmacsha.sbr" \ + "$(INTDIR)\httpd.sbr" \ + "$(INTDIR)\inet_aton.sbr" \ + "$(INTDIR)\inet_ntop.sbr" \ + "$(INTDIR)\inet_pton.sbr" \ + "$(INTDIR)\lex.sbr" \ + "$(INTDIR)\lfsr.sbr" \ + "$(INTDIR)\lib.sbr" \ + "$(INTDIR)\log.sbr" \ + "$(INTDIR)\md5.sbr" \ + "$(INTDIR)\mem.sbr" \ + "$(INTDIR)\msgcat.sbr" \ + "$(INTDIR)\mutexblock.sbr" \ + "$(INTDIR)\netaddr.sbr" \ + "$(INTDIR)\netscope.sbr" \ + "$(INTDIR)\ondestroy.sbr" \ + "$(INTDIR)\quota.sbr" \ + "$(INTDIR)\radix.sbr" \ + "$(INTDIR)\random.sbr" \ + "$(INTDIR)\ratelimiter.sbr" \ + "$(INTDIR)\refcount.sbr" \ + "$(INTDIR)\result.sbr" \ + "$(INTDIR)\rwlock.sbr" \ + "$(INTDIR)\serial.sbr" \ + "$(INTDIR)\sha1.sbr" \ + "$(INTDIR)\sha2.sbr" \ + "$(INTDIR)\sockaddr.sbr" \ + "$(INTDIR)\stats.sbr" \ + "$(INTDIR)\string.sbr" \ + "$(INTDIR)\symtab.sbr" \ + "$(INTDIR)\task.sbr" \ + "$(INTDIR)\taskpool.sbr" \ + "$(INTDIR)\timer.sbr" \ + "$(INTDIR)\parseint.sbr" \ + "$(INTDIR)\portset.sbr" \ + "$(INTDIR)\region.sbr" + +"$(OUTDIR)\libisc.bsc" : "$(OUTDIR)" $(BSC32_SBRS) + $(BSC32) @<< + $(BSC32_FLAGS) $(BSC32_SBRS) +<< + +LINK32=link.exe +LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib $(LIBXML) /nologo /dll /incremental:yes /pdb:"$(OUTDIR)\libisc.pdb" /map:"$(INTDIR)\libisc.map" /debug /machine:I386 /def:".\libisc.def" /out:"../../../Build/Debug/libisc.dll" /implib:"$(OUTDIR)\libisc.lib" /pdbtype:sept +DEF_FILE= \ + ".\libisc.def" +LINK32_OBJS= \ + "$(INTDIR)\app.obj" \ + "$(INTDIR)\condition.obj" \ + "$(INTDIR)\dir.obj" \ + "$(INTDIR)\DLLMain.obj" \ + "$(INTDIR)\entropy.obj" \ + "$(INTDIR)\errno2result.obj" \ + "$(INTDIR)\file.obj" \ + "$(INTDIR)\fsaccess.obj" \ + "$(INTDIR)\interfaceiter.obj" \ + "$(INTDIR)\ipv6.obj" \ + "$(INTDIR)\iterated_hash.obj" \ + "$(INTDIR)\keyboard.obj" \ + "$(INTDIR)\net.obj" \ + "$(INTDIR)\ntpaths.obj" \ + "$(INTDIR)\once.obj" \ + "$(INTDIR)\os.obj" \ + "$(INTDIR)\resource.obj" \ + "$(INTDIR)\socket.obj" \ + "$(INTDIR)\stdio.obj" \ + "$(INTDIR)\stdtime.obj" \ + "$(INTDIR)\strerror.obj" \ + "$(INTDIR)\syslog.obj" \ + "$(INTDIR)\thread.obj" \ + "$(INTDIR)\time.obj" \ + "$(INTDIR)\version.obj" \ + "$(INTDIR)\win32os.obj" \ + "$(INTDIR)\assertions.obj" \ + "$(INTDIR)\backtrace.obj" \ + "$(INTDIR)\backtrace-emptytbl.obj" \ + "$(INTDIR)\base32.obj" \ + "$(INTDIR)\base64.obj" \ + "$(INTDIR)\bitstring.obj" \ + "$(INTDIR)\buffer.obj" \ + "$(INTDIR)\bufferlist.obj" \ + "$(INTDIR)\commandline.obj" \ + "$(INTDIR)\error.obj" \ + "$(INTDIR)\event.obj" \ + "$(INTDIR)\hash.obj" \ + "$(INTDIR)\heap.obj" \ + "$(INTDIR)\hex.obj" \ + "$(INTDIR)\hmacmd5.obj" \ + "$(INTDIR)\hmacsha.obj" \ + "$(INTDIR)\httpd.obj" \ + "$(INTDIR)\inet_aton.obj" \ + "$(INTDIR)\inet_ntop.obj" \ + "$(INTDIR)\inet_pton.obj" \ + "$(INTDIR)\lex.obj" \ + "$(INTDIR)\lfsr.obj" \ + "$(INTDIR)\lib.obj" \ + "$(INTDIR)\log.obj" \ + "$(INTDIR)\md5.obj" \ + "$(INTDIR)\mem.obj" \ + "$(INTDIR)\msgcat.obj" \ + "$(INTDIR)\mutexblock.obj" \ + "$(INTDIR)\netaddr.obj" \ + "$(INTDIR)\netscope.obj" \ + "$(INTDIR)\ondestroy.obj" \ + "$(INTDIR)\quota.obj" \ + "$(INTDIR)\radix.obj" \ + "$(INTDIR)\random.obj" \ + "$(INTDIR)\ratelimiter.obj" \ + "$(INTDIR)\refcount.obj" \ + "$(INTDIR)\result.obj" \ + "$(INTDIR)\rwlock.obj" \ + "$(INTDIR)\serial.obj" \ + "$(INTDIR)\sha1.obj" \ + "$(INTDIR)\sha2.obj" \ + "$(INTDIR)\sockaddr.obj" \ + "$(INTDIR)\stats.obj" \ + "$(INTDIR)\string.obj" \ + "$(INTDIR)\symtab.obj" \ + "$(INTDIR)\task.obj" \ + "$(INTDIR)\taskpool.obj" \ + "$(INTDIR)\timer.obj" \ + "$(INTDIR)\parseint.obj" \ + "$(INTDIR)\portset.obj" \ + "$(INTDIR)\region.obj" + +"..\..\..\Build\Debug\libisc.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + $(_VC_MANIFEST_EMBED_DLL) + +!ENDIF + +.c{$(INTDIR)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(INTDIR)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(INTDIR)}.obj:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.c{$(INTDIR)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cpp{$(INTDIR)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + +.cxx{$(INTDIR)}.sbr:: + $(CPP) @<< + $(CPP_PROJ) $< +<< + + +!IF "$(NO_EXTERNAL_DEPS)" != "1" +!IF EXISTS("libisc.dep") +!INCLUDE "libisc.dep" +!ELSE +!MESSAGE Warning: cannot find "libisc.dep" +!ENDIF +!ENDIF + + +!IF "$(CFG)" == "libisc - Win32 Release" || "$(CFG)" == "libisc - Win32 Debug" +SOURCE=.\app.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\app.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\app.obj" "$(INTDIR)\app.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\condition.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\condition.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\condition.obj" "$(INTDIR)\condition.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\dir.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\dir.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\dir.obj" "$(INTDIR)\dir.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\DLLMain.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\DLLMain.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\DLLMain.obj" "$(INTDIR)\DLLMain.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\entropy.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\entropy.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\entropy.obj" "$(INTDIR)\entropy.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\errno2result.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\errno2result.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\errno2result.obj" "$(INTDIR)\errno2result.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\file.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\file.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\file.obj" "$(INTDIR)\file.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\fsaccess.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\fsaccess.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\fsaccess.obj" "$(INTDIR)\fsaccess.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\interfaceiter.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\interfaceiter.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\interfaceiter.obj" "$(INTDIR)\interfaceiter.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\ipv6.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\ipv6.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\ipv6.obj" "$(INTDIR)\ipv6.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + + +SOURCE=.\keyboard.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\keyboard.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\keyboard.obj" "$(INTDIR)\keyboard.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\net.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\net.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\net.obj" "$(INTDIR)\net.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\ntpaths.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\ntpaths.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\ntpaths.obj" "$(INTDIR)\ntpaths.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\once.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\once.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\once.obj" "$(INTDIR)\once.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\os.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\os.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\os.obj" "$(INTDIR)\os.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\resource.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\resource.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\resource.obj" "$(INTDIR)\resource.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\socket.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\socket.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\socket.obj" "$(INTDIR)\socket.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\stdio.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\stdio.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\stdio.obj" "$(INTDIR)\stdio.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\stdtime.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\stdtime.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\stdtime.obj" "$(INTDIR)\stdtime.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\strerror.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\strerror.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\strerror.obj" "$(INTDIR)\strerror.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\syslog.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\syslog.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\syslog.obj" "$(INTDIR)\syslog.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\thread.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\thread.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\thread.obj" "$(INTDIR)\thread.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\time.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\time.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\time.obj" "$(INTDIR)\time.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\version.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\version.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\version.obj" "$(INTDIR)\version.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=.\win32os.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\win32os.obj" : $(SOURCE) "$(INTDIR)" + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\win32os.obj" "$(INTDIR)\win32os.sbr" : $(SOURCE) "$(INTDIR)" + + +!ENDIF + +SOURCE=..\assertions.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\assertions.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\assertions.obj" "$(INTDIR)\assertions.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\backtrace.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\backtrace.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\backtrace.obj" "$(INTDIR)\backtrace.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\backtrace-emptytbl.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\backtrace-emptytbl.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\backtrace-emptytbl.obj" "$(INTDIR)\backtrace-emptytbl.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\base32.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\base32.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\base32.obj" "$(INTDIR)\base32.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\base64.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\base64.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\base64.obj" "$(INTDIR)\base64.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\bitstring.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\bitstring.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\bitstring.obj" "$(INTDIR)\bitstring.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\buffer.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\buffer.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\buffer.obj" "$(INTDIR)\buffer.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\bufferlist.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\bufferlist.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\bufferlist.obj" "$(INTDIR)\bufferlist.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\commandline.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\commandline.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\commandline.obj" "$(INTDIR)\commandline.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\error.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\error.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\error.obj" "$(INTDIR)\error.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\event.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\event.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\event.obj" "$(INTDIR)\event.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\hash.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\hash.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\hash.obj" "$(INTDIR)\hash.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\heap.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\heap.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\heap.obj" "$(INTDIR)\heap.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\hex.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\hex.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\hex.obj" "$(INTDIR)\hex.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\hmacmd5.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\hmacmd5.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\hmacmd5.obj" "$(INTDIR)\hmacmd5.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\hmacsha.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\hmacsha.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\hmacsha.obj" "$(INTDIR)\hmacsha.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\httpd.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\httpd.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\httpd.obj" "$(INTDIR)\httpd.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\inet_aton.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\inet_aton.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\inet_aton.obj" "$(INTDIR)\inet_aton.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\inet_ntop.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\inet_ntop.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\inet_ntop.obj" "$(INTDIR)\inet_ntop.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\inet_pton.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\inet_pton.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\inet_pton.obj" "$(INTDIR)\inet_pton.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\iterated_hash.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\iterated_hash.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\iterated_hash.obj" "$(INTDIR)\iterated_hash.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\lex.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\lex.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\lex.obj" "$(INTDIR)\lex.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\lfsr.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\lfsr.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\lfsr.obj" "$(INTDIR)\lfsr.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\lib.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\lib.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\lib.obj" "$(INTDIR)\lib.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\log.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\log.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\log.obj" "$(INTDIR)\log.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\md5.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\md5.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\md5.obj" "$(INTDIR)\md5.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\mem.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\mem.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\mem.obj" "$(INTDIR)\mem.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\nls\msgcat.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\msgcat.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\msgcat.obj" "$(INTDIR)\msgcat.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\mutexblock.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\mutexblock.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\mutexblock.obj" "$(INTDIR)\mutexblock.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\netaddr.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\netaddr.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\netaddr.obj" "$(INTDIR)\netaddr.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\netscope.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\netscope.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\netscope.obj" "$(INTDIR)\netscope.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\ondestroy.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\ondestroy.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\ondestroy.obj" "$(INTDIR)\ondestroy.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\parseint.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\parseint.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\parseint.obj" "$(INTDIR)\parseint.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\portset.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\portset.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\portset.obj" "$(INTDIR)\portset.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\quota.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\quota.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\quota.obj" "$(INTDIR)\quota.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\radix.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\radix.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\radix.obj" "$(INTDIR)\radix.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\random.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\random.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\random.obj" "$(INTDIR)\random.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\ratelimiter.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\ratelimiter.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\ratelimiter.obj" "$(INTDIR)\ratelimiter.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\refcount.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\refcount.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\refcount.obj" "$(INTDIR)\refcount.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\region.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\region.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\region.obj" "$(INTDIR)\region.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\result.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\result.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\result.obj" "$(INTDIR)\result.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\rwlock.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\rwlock.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\rwlock.obj" "$(INTDIR)\rwlock.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\serial.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\serial.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\serial.obj" "$(INTDIR)\serial.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\sha1.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\sha1.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\sha1.obj" "$(INTDIR)\sha1.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\sha2.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\sha2.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\sha2.obj" "$(INTDIR)\sha2.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\sockaddr.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\sockaddr.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\sockaddr.obj" "$(INTDIR)\sockaddr.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\stats.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\stats.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\stats.obj" "$(INTDIR)\stats.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\string.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\string.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\string.obj" "$(INTDIR)\string.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\symtab.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\symtab.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\symtab.obj" "$(INTDIR)\symtab.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\task.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\task.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\task.obj" "$(INTDIR)\task.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\taskpool.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\taskpool.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\taskpool.obj" "$(INTDIR)\taskpool.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + +SOURCE=..\timer.c + +!IF "$(CFG)" == "libisc - Win32 Release" + + +"$(INTDIR)\timer.obj" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ELSEIF "$(CFG)" == "libisc - Win32 Debug" + + +"$(INTDIR)\timer.obj" "$(INTDIR)\timer.sbr" : $(SOURCE) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +!ENDIF + + +!ENDIF + +#################################################### +# Commands to generate initial empty manifest file and the RC file +# that references it, and for generating the .res file: + +$(_VC_MANIFEST_BASENAME).auto.res : $(_VC_MANIFEST_BASENAME).auto.rc + +$(_VC_MANIFEST_BASENAME).auto.rc : $(_VC_MANIFEST_BASENAME).auto.manifest + type <<$@ +#include +1RT_MANIFEST"$(_VC_MANIFEST_BASENAME).auto.manifest" +<< KEEP + +$(_VC_MANIFEST_BASENAME).auto.manifest : + type <<$@ + + + +<< KEEP diff --git a/contrib/ntp/libisc/net.c b/contrib/ntp/lib/isc/win32/net.c similarity index 64% rename from contrib/ntp/libisc/net.c rename to contrib/ntp/lib/isc/win32/net.c index 3d4ab66e7..12876da2b 100644 --- a/contrib/ntp/libisc/net.c +++ b/contrib/ntp/lib/isc/win32/net.c @@ -1,8 +1,8 @@ /* - * Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2004, 2005, 2007-2009, 2011, 2012 Internet Systems Consortium, Inc. ("ISC") * Copyright (C) 1999-2003 Internet Software Consortium. * - * Permission to use, copy, modify, and distribute this software for any + * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * @@ -15,28 +15,48 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: net.c,v 1.22.2.2.10.7 2004/04/29 01:31:22 marka Exp $ */ +/* $Id$ */ #include #include #include +#include +#include #include #include #include #include #include -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRANY) +/*% + * Definitions about UDP port range specification. This is a total mess of + * portability variants: some use sysctl (but the sysctl names vary), some use + * system-specific interfaces, some have the same interface for IPv4 and IPv6, + * some separate them, etc... + */ + +/*% + * The last resort defaults: use all non well known port space + */ +#ifndef ISC_NET_PORTRANGELOW +#define ISC_NET_PORTRANGELOW 1024 +#endif /* ISC_NET_PORTRANGELOW */ +#ifndef ISC_NET_PORTRANGEHIGH +#define ISC_NET_PORTRANGEHIGH 65535 +#endif /* ISC_NET_PORTRANGEHIGH */ + +#if defined(ISC_PLATFORM_NEEDIN6ADDRANY) const struct in6_addr isc_net_in6addrany = IN6ADDR_ANY_INIT; #endif -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(ISC_PLATFORM_NEEDIN6ADDRLOOPBACK) +#if defined(ISC_PLATFORM_NEEDIN6ADDRLOOPBACK) const struct in6_addr isc_net_in6addrloop = IN6ADDR_LOOPBACK_INIT; #endif -static isc_boolean_t once = ISC_FALSE; + +static isc_once_t once = ISC_ONCE_INIT; static isc_once_t once_ipv6only = ISC_ONCE_INIT; static isc_once_t once_ipv6pktinfo = ISC_ONCE_INIT; static isc_result_t ipv4_result = ISC_R_NOTFOUND; @@ -44,67 +64,43 @@ static isc_result_t ipv6_result = ISC_R_NOTFOUND; static isc_result_t ipv6only_result = ISC_R_NOTFOUND; static isc_result_t ipv6pktinfo_result = ISC_R_NOTFOUND; +void InitSockets(void); + static isc_result_t try_proto(int domain) { - int s; - isc_result_t result = ISC_R_SUCCESS; + SOCKET s; char strbuf[ISC_STRERRORSIZE]; - - s = socket(domain, SOCK_STREAM, 0); - if (s == -1) { - switch (errno) { -#ifdef EAFNOSUPPORT - case EAFNOSUPPORT: -#endif -#ifdef EPROTONOSUPPORT - case EPROTONOSUPPORT: -#endif -#ifdef EINVAL - case EINVAL: -#endif + int errval; + + s = socket(domain, SOCK_STREAM, IPPROTO_TCP); + if (s == INVALID_SOCKET) { + errval = WSAGetLastError(); + switch (errval) { + case WSAEAFNOSUPPORT: + case WSAEPROTONOSUPPORT: + case WSAEINVAL: return (ISC_R_NOTFOUND); default: - isc__strerror(errno, strbuf, sizeof(strbuf)); + isc__strerror(errval, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), strbuf); return (ISC_R_UNEXPECTED); } } -#ifdef ISC_PLATFORM_HAVEIPV6 -#ifdef WANT_IPV6 -#ifdef ISC_PLATFORM_HAVEIN6PKTINFO - if (domain == PF_INET6) { - struct sockaddr_in6 sin6; - GETSOCKNAME_SOCKLEN_TYPE len; - - /* - * Check to see if IPv6 is broken, as is common on Linux. - */ - len = sizeof(sin6); - if (getsockname(s, (struct sockaddr *)&sin6, &len) < 0) - { - result = ISC_R_NOTFOUND; - } else { - if (len == sizeof(struct sockaddr_in6)) - result = ISC_R_SUCCESS; - else { - result = ISC_R_NOTFOUND; - } - } - } -#endif -#endif -#endif + closesocket(s); - (void)close(s); - - return (result); + return (ISC_R_SUCCESS); } static void initialize_action(void) { + InitSockets(); ipv4_result = try_proto(PF_INET); #ifdef ISC_PLATFORM_HAVEIPV6 #ifdef WANT_IPV6 @@ -117,10 +113,7 @@ initialize_action(void) { static void initialize(void) { - if(once == ISC_FALSE) { - initialize_action(); - once = ISC_TRUE; - } + RUNTIME_CHECK(isc_once_do(&once, initialize_action) == ISC_R_SUCCESS); } isc_result_t @@ -135,12 +128,18 @@ isc_net_probeipv6(void) { return (ipv6_result); } +isc_result_t +isc_net_probeunix(void) { + return (ISC_R_NOTFOUND); +} + #ifdef ISC_PLATFORM_HAVEIPV6 #ifdef WANT_IPV6 static void try_ipv6only(void) { #ifdef IPV6_V6ONLY - int s, on; + SOCKET s; + int on; char strbuf[ISC_STRERRORSIZE]; #endif isc_result_t result; @@ -157,46 +156,54 @@ try_ipv6only(void) { #else /* check for TCP sockets */ s = socket(PF_INET6, SOCK_STREAM, 0); - if (s == -1) { + if (s == INVALID_SOCKET) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), strbuf); ipv6only_result = ISC_R_UNEXPECTED; return; } on = 1; - if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { + if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, (const char *)&on, + sizeof(on)) < 0) { ipv6only_result = ISC_R_NOTFOUND; goto close; } - close(s); + closesocket(s); /* check for UDP sockets */ s = socket(PF_INET6, SOCK_DGRAM, 0); - if (s == -1) { + if (s == INVALID_SOCKET) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), strbuf); ipv6only_result = ISC_R_UNEXPECTED; return; } on = 1; - if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof(on)) < 0) { + if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, (const char *)&on, + sizeof(on)) < 0) { ipv6only_result = ISC_R_NOTFOUND; goto close; } - close(s); - ipv6only_result = ISC_R_SUCCESS; close: - close(s); + closesocket(s); return; #endif /* IPV6_V6ONLY */ } @@ -222,10 +229,14 @@ try_ipv6pktinfo(void) { /* we only use this for UDP sockets */ s = socket(PF_INET6, SOCK_DGRAM, IPPROTO_UDP); - if (s == -1) { + if (s == INVALID_SOCKET) { isc__strerror(errno, strbuf, sizeof(strbuf)); UNEXPECTED_ERROR(__FILE__, __LINE__, - "socket() failed: %s", + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), strbuf); ipv6pktinfo_result = ISC_R_UNEXPECTED; return; @@ -237,16 +248,16 @@ try_ipv6pktinfo(void) { optname = IPV6_PKTINFO; #endif on = 1; - if (setsockopt(s, IPPROTO_IPV6, optname, &on, sizeof(on)) < 0) { + if (setsockopt(s, IPPROTO_IPV6, optname, (const char *) &on, + sizeof(on)) < 0) { ipv6pktinfo_result = ISC_R_NOTFOUND; goto close; } - close(s); ipv6pktinfo_result = ISC_R_SUCCESS; close: - close(s); + closesocket(s); return; } @@ -282,6 +293,22 @@ isc_net_probe_ipv6pktinfo(void) { return (ipv6pktinfo_result); } +isc_result_t +isc_net_getudpportrange(int af, in_port_t *low, in_port_t *high) { + int result = ISC_R_FAILURE; + + REQUIRE(low != NULL && high != NULL); + + UNUSED(af); + + if (result != ISC_R_SUCCESS) { + *low = ISC_NET_PORTRANGELOW; + *high = ISC_NET_PORTRANGEHIGH; + } + + return (ISC_R_SUCCESS); /* we currently never fail in this function */ +} + void isc_net_disableipv4(void) { initialize(); diff --git a/contrib/ntp/lib/isc/win32/netdb.h b/contrib/ntp/lib/isc/win32/netdb.h new file mode 100644 index 000000000..f8d936a99 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/netdb.h @@ -0,0 +1,187 @@ +/* + * Copyright (C) 2004, 2006, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: netdb.h,v 1.9 2009/01/18 23:48:14 tbox Exp $ */ + +#ifndef NETDB_H +#define NETDB_H 1 + +#include +#include + +/* + * Define if does not declare struct addrinfo. + */ + +struct addrinfo { + int ai_flags; /* AI_PASSIVE, AI_CANONNAME */ + int ai_family; /* PF_xxx */ + int ai_socktype; /* SOCK_xxx */ + int ai_protocol; /* 0 or IPPROTO_xxx for IPv4 and IPv6 */ + size_t ai_addrlen; /* Length of ai_addr */ + char *ai_canonname; /* Canonical name for hostname */ + struct sockaddr *ai_addr; /* Binary address */ + struct addrinfo *ai_next; /* Next structure in linked list */ +}; + + +/* + * Undefine all \#defines we are interested in as may or may not have + * defined them. + */ + +/* + * Error return codes from gethostbyname() and gethostbyaddr() + * (left in extern int h_errno). + */ + +#undef NETDB_INTERNAL +#undef NETDB_SUCCESS +#undef HOST_NOT_FOUND +#undef TRY_AGAIN +#undef NO_RECOVERY +#undef NO_DATA +#undef NO_ADDRESS + +#define NETDB_INTERNAL -1 /* see errno */ +#define NETDB_SUCCESS 0 /* no problem */ +#define HOST_NOT_FOUND 1 /* Authoritative Answer Host not found */ +#define TRY_AGAIN 2 /* Non-Authoritative Host not found, or SERVERFAIL */ +#define NO_RECOVERY 3 /* Non recoverable errors, FORMERR, REFUSED, NOTIMP */ +#define NO_DATA 4 /* Valid name, no data record of requested type */ +#define NO_ADDRESS NO_DATA /* no address, look for MX record */ + +/* + * Error return codes from getaddrinfo() + */ + +#undef EAI_ADDRFAMILY +#undef EAI_AGAIN +#undef EAI_BADFLAGS +#undef EAI_FAIL +#undef EAI_FAMILY +#undef EAI_MEMORY +#undef EAI_NODATA +#undef EAI_NONAME +#undef EAI_SERVICE +#undef EAI_SOCKTYPE +#undef EAI_SYSTEM +#undef EAI_BADHINTS +#undef EAI_PROTOCOL +#undef EAI_MAX + +#define EAI_ADDRFAMILY 1 /* address family for hostname not supported */ +#define EAI_AGAIN 2 /* temporary failure in name resolution */ +#define EAI_BADFLAGS 3 /* invalid value for ai_flags */ +#define EAI_FAIL 4 /* non-recoverable failure in name resolution */ +#define EAI_FAMILY 5 /* ai_family not supported */ +#define EAI_MEMORY 6 /* memory allocation failure */ +#define EAI_NODATA 7 /* no address associated with hostname */ +#define EAI_NONAME 8 /* hostname nor servname provided, or not known */ +#define EAI_SERVICE 9 /* servname not supported for ai_socktype */ +#define EAI_SOCKTYPE 10 /* ai_socktype not supported */ +#define EAI_SYSTEM 11 /* system error returned in errno */ +#define EAI_BADHINTS 12 +#define EAI_PROTOCOL 13 +#define EAI_MAX 14 + +/* + * Flag values for getaddrinfo() + */ +#undef AI_PASSIVE +#undef AI_CANONNAME +#undef AI_NUMERICHOST + +#define AI_PASSIVE 0x00000001 +#define AI_CANONNAME 0x00000002 +#define AI_NUMERICHOST 0x00000004 + +/* + * Flag values for getipnodebyname() + */ +#undef AI_V4MAPPED +#undef AI_ALL +#undef AI_ADDRCONFIG +#undef AI_DEFAULT + +#define AI_V4MAPPED 0x00000008 +#define AI_ALL 0x00000010 +#define AI_ADDRCONFIG 0x00000020 +#define AI_DEFAULT (AI_V4MAPPED|AI_ADDRCONFIG) + +/* + * Constants for getnameinfo() + */ +#undef NI_MAXHOST +#undef NI_MAXSERV + +#define NI_MAXHOST 1025 +#define NI_MAXSERV 32 + +/* + * Flag values for getnameinfo() + */ +#undef NI_NOFQDN +#undef NI_NUMERICHOST +#undef NI_NAMEREQD +#undef NI_NUMERICSERV +#undef NI_DGRAM +#undef NI_NUMERICSCOPE + +#define NI_NOFQDN 0x00000001 +#define NI_NUMERICHOST 0x00000002 +#define NI_NAMEREQD 0x00000004 +#define NI_NUMERICSERV 0x00000008 +#define NI_DGRAM 0x00000010 +#define NI_NUMERICSCOPE 0x00000020 /*2553bis-00*/ + +/* + * Structures for getrrsetbyname() + */ +struct rdatainfo { + unsigned int rdi_length; + unsigned char *rdi_data; +}; + +struct rrsetinfo { + unsigned int rri_flags; + int rri_rdclass; + int rri_rdtype; + unsigned int rri_ttl; + unsigned int rri_nrdatas; + unsigned int rri_nsigs; + char *rri_name; + struct rdatainfo *rri_rdatas; + struct rdatainfo *rri_sigs; +}; + +/* + * Flags for getrrsetbyname() + */ +#define RRSET_VALIDATED 0x00000001 + /* Set was dnssec validated */ + +/* + * Return codes for getrrsetbyname() + */ +#define ERRSET_SUCCESS 0 +#define ERRSET_NOMEMORY 1 +#define ERRSET_FAIL 2 +#define ERRSET_INVAL 3 + + +#endif /* NETDB_H */ diff --git a/contrib/ntp/lib/isc/win32/ntgroups.c b/contrib/ntp/lib/isc/win32/ntgroups.c new file mode 100644 index 000000000..729cf07e7 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/ntgroups.c @@ -0,0 +1,186 @@ +/* + * Copyright (C) 2004, 2006, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ntgroups.c,v 1.12 2009/09/29 23:48:04 tbox Exp $ */ + +/* + * The NT Groups have two groups that are not well documented and are + * not normally seen: None and Everyone. A user account belongs to + * any number of groups, but if it is not a member of any group then + * it is a member of the None Group. The None group is not listed + * anywhere. You cannot remove an account from the none group except + * by making it a member of some other group, The second group is the + * Everyone group. All accounts, no matter how many groups that they + * belong to, also belong to the Everyone group. You cannot remove an + * account from the Everyone group. + */ + +#ifndef UNICODE +#define UNICODE +#endif /* UNICODE */ + +/* + * Silence warnings. + */ +#define _CRT_SECURE_NO_DEPRECATE 1 + +#include +#include +#include + +#include +#include + +#define MAX_NAME_LENGTH 256 + +isc_result_t +isc_ntsecurity_getaccountgroups(char *username, char **GroupList, + unsigned int maxgroups, + unsigned int *totalGroups) { + LPGROUP_USERS_INFO_0 pTmpBuf; + LPLOCALGROUP_USERS_INFO_0 pTmpLBuf; + DWORD i; + LPLOCALGROUP_USERS_INFO_0 pBuf = NULL; + LPGROUP_USERS_INFO_0 pgrpBuf = NULL; + DWORD dwLevel = 0; + DWORD dwFlags = LG_INCLUDE_INDIRECT; + DWORD dwPrefMaxLen = MAX_PREFERRED_LENGTH; + DWORD dwEntriesRead = 0; + DWORD dwTotalEntries = 0; + NET_API_STATUS nStatus; + DWORD dwTotalCount = 0; + size_t retlen; + wchar_t user[MAX_NAME_LENGTH]; + + retlen = mbstowcs(user, username, MAX_NAME_LENGTH); + + *totalGroups = 0; + /* + * Call the NetUserGetLocalGroups function + * specifying information level 0. + * + * The LG_INCLUDE_INDIRECT flag specifies that the + * function should also return the names of the local + * groups in which the user is indirectly a member. + */ + nStatus = NetUserGetLocalGroups(NULL, + user, + dwLevel, + dwFlags, + (LPBYTE *) &pBuf, + dwPrefMaxLen, + &dwEntriesRead, + &dwTotalEntries); + /* + * See if the call succeeds, + */ + if (nStatus != NERR_Success) { + if (nStatus == ERROR_ACCESS_DENIED) + return (ISC_R_NOPERM); + if (nStatus == ERROR_MORE_DATA) + return (ISC_R_NOSPACE); + if (nStatus == NERR_UserNotFound) + dwEntriesRead = 0; + } + + dwTotalCount = 0; + if (pBuf != NULL) { + pTmpLBuf = pBuf; + /* + * Loop through the entries + */ + for (i = 0; + (i < dwEntriesRead && *totalGroups < maxgroups); i++) { + assert(pTmpLBuf != NULL); + if (pTmpLBuf == NULL) + break; + retlen = wcslen(pTmpLBuf->lgrui0_name); + GroupList[*totalGroups] = (char *) malloc(retlen +1); + if (GroupList[*totalGroups] == NULL) + return (ISC_R_NOMEMORY); + + retlen = wcstombs(GroupList[*totalGroups], + pTmpLBuf->lgrui0_name, retlen); + GroupList[*totalGroups][retlen] = '\0'; + if (strcmp(GroupList[*totalGroups], "None") == 0) + free(GroupList[*totalGroups]); + else + (*totalGroups)++; + pTmpLBuf++; + } + } + /* Free the allocated memory. */ + if (pBuf != NULL) + NetApiBufferFree(pBuf); + + + /* + * Call the NetUserGetGroups function, specifying level 0. + */ + nStatus = NetUserGetGroups(NULL, + user, + dwLevel, + (LPBYTE*)&pgrpBuf, + dwPrefMaxLen, + &dwEntriesRead, + &dwTotalEntries); + /* + * See if the call succeeds, + */ + if (nStatus != NERR_Success) { + if (nStatus == ERROR_ACCESS_DENIED) + return (ISC_R_NOPERM); + if (nStatus == ERROR_MORE_DATA) + return (ISC_R_NOSPACE); + if (nStatus == NERR_UserNotFound) + dwEntriesRead = 0; + } + + if (pgrpBuf != NULL) { + pTmpBuf = pgrpBuf; + /* + * Loop through the entries + */ + for (i = 0; + (i < dwEntriesRead && *totalGroups < maxgroups); i++) { + assert(pTmpBuf != NULL); + + if (pTmpBuf == NULL) + break; + retlen = wcslen(pTmpBuf->grui0_name); + GroupList[*totalGroups] = (char *) malloc(retlen +1); + if (GroupList[*totalGroups] == NULL) + return (ISC_R_NOMEMORY); + + retlen = wcstombs(GroupList[*totalGroups], + pTmpBuf->grui0_name, retlen); + GroupList[*totalGroups][retlen] = '\0'; + if (strcmp(GroupList[*totalGroups], "None") == 0) + free(GroupList[*totalGroups]); + else + (*totalGroups)++; + pTmpBuf++; + } + } + /* + * Free the allocated memory. + */ + if (pgrpBuf != NULL) + NetApiBufferFree(pgrpBuf); + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/win32/ntpaths.c b/contrib/ntp/lib/isc/win32/ntpaths.c new file mode 100644 index 000000000..1ff8c5a9b --- /dev/null +++ b/contrib/ntp/lib/isc/win32/ntpaths.c @@ -0,0 +1,147 @@ +/* + * Copyright (C) 2004, 2007, 2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: ntpaths.c,v 1.15 2009/07/14 22:54:57 each Exp $ */ + +/* + * This module fetches the required path information that is specific + * to NT systems which can have its configuration and system files + * almost anywhere. It can be used to override whatever the application + * had previously assigned to the pointer. Basic information about the + * file locations are stored in the registry. + */ + +#include +#include +#include + +/* + * Module Variables + */ + +static char systemDir[MAX_PATH]; +static char namedBase[MAX_PATH]; +static char ns_confFile[MAX_PATH]; +static char lwresd_confFile[MAX_PATH]; +static char lwresd_resolvconfFile[MAX_PATH]; +static char rndc_confFile[MAX_PATH]; +static char ns_defaultpidfile[MAX_PATH]; +static char lwresd_defaultpidfile[MAX_PATH]; +static char local_state_dir[MAX_PATH]; +static char sys_conf_dir[MAX_PATH]; +static char rndc_keyFile[MAX_PATH]; +static char session_keyFile[MAX_PATH]; + +static DWORD baseLen = MAX_PATH; +static BOOL Initialized = FALSE; + +void +isc_ntpaths_init() { + HKEY hKey; + BOOL keyFound = TRUE; + + memset(namedBase, 0, MAX_PATH); + if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, BIND_SUBKEY, 0, KEY_READ, &hKey) + != ERROR_SUCCESS) + keyFound = FALSE; + + if (keyFound == TRUE) { + /* Get the named directory */ + if (RegQueryValueEx(hKey, "InstallDir", NULL, NULL, + (LPBYTE)namedBase, &baseLen) != ERROR_SUCCESS) + keyFound = FALSE; + RegCloseKey(hKey); + } + + GetSystemDirectory(systemDir, MAX_PATH); + + if (keyFound == FALSE) + /* Use the System Directory as a default */ + strcpy(namedBase, systemDir); + + strcpy(ns_confFile, namedBase); + strcat(ns_confFile, "\\etc\\named.conf"); + + strcpy(lwresd_confFile, namedBase); + strcat(lwresd_confFile, "\\etc\\lwresd.conf"); + + strcpy(lwresd_resolvconfFile, systemDir); + strcat(lwresd_resolvconfFile, "\\Drivers\\etc\\resolv.conf"); + + strcpy(rndc_keyFile, namedBase); + strcat(rndc_keyFile, "\\etc\\rndc.key"); + + strcpy(session_keyFile, namedBase); + strcat(session_keyFile, "\\etc\\session.key"); + + strcpy(rndc_confFile, namedBase); + strcat(rndc_confFile, "\\etc\\rndc.conf"); + strcpy(ns_defaultpidfile, namedBase); + strcat(ns_defaultpidfile, "\\etc\\named.pid"); + + strcpy(lwresd_defaultpidfile, namedBase); + strcat(lwresd_defaultpidfile, "\\etc\\lwresd.pid"); + + strcpy(local_state_dir, namedBase); + strcat(local_state_dir, "\\bin"); + + strcpy(sys_conf_dir, namedBase); + strcat(sys_conf_dir, "\\etc"); + + Initialized = TRUE; +} + +char * +isc_ntpaths_get(int ind) { + if (!Initialized) + isc_ntpaths_init(); + + switch (ind) { + case NAMED_CONF_PATH: + return (ns_confFile); + break; + case LWRES_CONF_PATH: + return (lwresd_confFile); + break; + case RESOLV_CONF_PATH: + return (lwresd_resolvconfFile); + break; + case RNDC_CONF_PATH: + return (rndc_confFile); + break; + case NAMED_PID_PATH: + return (ns_defaultpidfile); + break; + case LWRESD_PID_PATH: + return (lwresd_defaultpidfile); + break; + case LOCAL_STATE_DIR: + return (local_state_dir); + break; + case SYS_CONF_DIR: + return (sys_conf_dir); + break; + case RNDC_KEY_PATH: + return (rndc_keyFile); + break; + case SESSION_KEY_PATH: + return (session_keyFile); + break; + default: + return (NULL); + } +} diff --git a/contrib/ntp/lib/isc/win32/once.c b/contrib/ntp/lib/isc/win32/once.c new file mode 100644 index 000000000..b5047762a --- /dev/null +++ b/contrib/ntp/lib/isc/win32/once.c @@ -0,0 +1,54 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: once.c,v 1.12 2007/06/18 23:47:49 tbox Exp $ */ + +/* Principal Authors: DCL */ + +#include + +#include + +#include +#include +#include + +isc_result_t +isc_once_do(isc_once_t *controller, void(*function)(void)) { + REQUIRE(controller != NULL && function != NULL); + + if (controller->status == ISC_ONCE_INIT_NEEDED) { + + if (InterlockedDecrement(&controller->counter) == 0) { + if (controller->status == ISC_ONCE_INIT_NEEDED) { + function(); + controller->status = ISC_ONCE_INIT_DONE; + } + } else { + while (controller->status == ISC_ONCE_INIT_NEEDED) { + /* + * Sleep(0) indicates that this thread + * should be suspended to allow other + * waiting threads to execute. + */ + Sleep(0); + } + } + } + + return (ISC_R_SUCCESS); +} diff --git a/contrib/ntp/lib/isc/win32/os.c b/contrib/ntp/lib/isc/win32/os.c new file mode 100644 index 000000000..bbd5f1d6c --- /dev/null +++ b/contrib/ntp/lib/isc/win32/os.c @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: os.c,v 1.8 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include + +static BOOL bInit = FALSE; +static SYSTEM_INFO SystemInfo; + +static void +initialize_action(void) { + if (bInit) + return; + + GetSystemInfo(&SystemInfo); + bInit = TRUE; +} + +unsigned int +isc_os_ncpus(void) { + long ncpus = 1; + initialize_action(); + ncpus = SystemInfo.dwNumberOfProcessors; + if (ncpus <= 0) + ncpus = 1; + + return ((unsigned int)ncpus); +} diff --git a/contrib/ntp/lib/isc/win32/resource.c b/contrib/ntp/lib/isc/win32/resource.c new file mode 100644 index 000000000..e7e7cf414 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/resource.c @@ -0,0 +1,72 @@ +/* + * Copyright (C) 2004, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: resource.c,v 1.10 2008/07/11 23:47:09 tbox Exp $ */ + +#include + +#include + +#include +#include +#include +#include + +#include "errno2result.h" + +/* + * Windows limits the maximum number of open files to 2048 + */ + +#define WIN32_MAX_OPEN_FILES 2048 + +isc_result_t +isc_resource_setlimit(isc_resource_t resource, isc_resourcevalue_t value) { + isc_resourcevalue_t rlim_value; + int wresult; + + if (resource != isc_resource_openfiles) + return (ISC_R_NOTIMPLEMENTED); + + + if (value == ISC_RESOURCE_UNLIMITED) + rlim_value = WIN32_MAX_OPEN_FILES; + else + rlim_value = min(value, WIN32_MAX_OPEN_FILES); + + wresult = _setmaxstdio((int) rlim_value); + + if (wresult > 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_resource_getlimit(isc_resource_t resource, isc_resourcevalue_t *value) { + + if (resource != isc_resource_openfiles) + return (ISC_R_NOTIMPLEMENTED); + + *value = WIN32_MAX_OPEN_FILES; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_resource_getcurlimit(isc_resource_t resource, isc_resourcevalue_t *value) { + return (isc_resource_getlimit(resource, value)); +} diff --git a/contrib/ntp/lib/isc/win32/socket.c b/contrib/ntp/lib/isc/win32/socket.c new file mode 100644 index 000000000..ffcefb060 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/socket.c @@ -0,0 +1,3967 @@ +/* + * Copyright (C) 2004-2012 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id$ */ + +/* This code uses functions which are only available on Server 2003 and + * higher, and Windows XP and higher. + * + * This code is by nature multithreaded and takes advantage of various + * features to pass on information through the completion port for + * when I/O is completed. All sends, receives, accepts, and connects are + * completed through the completion port. + * + * The number of Completion Port Worker threads used is the total number + * of CPU's + 1. This increases the likelihood that a Worker Thread is + * available for processing a completed request. + * + * XXXPDM 5 August, 2002 + */ + +#define MAKE_EXTERNAL 1 +#include + +#include + +#ifndef _WINSOCKAPI_ +#define _WINSOCKAPI_ /* Prevent inclusion of winsock.h in windows.h */ +#endif + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include "errno2result.h" + +/* + * How in the world can Microsoft exist with APIs like this? + * We can't actually call this directly, because it turns out + * no library exports this function. Instead, we need to + * issue a runtime call to get the address. + */ +LPFN_CONNECTEX ISCConnectEx; +LPFN_ACCEPTEX ISCAcceptEx; +LPFN_GETACCEPTEXSOCKADDRS ISCGetAcceptExSockaddrs; + +/* + * Run expensive internal consistency checks. + */ +#ifdef ISC_SOCKET_CONSISTENCY_CHECKS +#define CONSISTENT(sock) consistent(sock) +#else +#define CONSISTENT(sock) do {} while (0) +#endif +static void consistent(isc_socket_t *sock); + +/* + * Define this macro to control the behavior of connection + * resets on UDP sockets. See Microsoft KnowledgeBase Article Q263823 + * for details. + * NOTE: This requires that Windows 2000 systems install Service Pack 2 + * or later. + */ +#ifndef SIO_UDP_CONNRESET +#define SIO_UDP_CONNRESET _WSAIOW(IOC_VENDOR,12) +#endif + +/* + * Some systems define the socket length argument as an int, some as size_t, + * some as socklen_t. This is here so it can be easily changed if needed. + */ +#ifndef ISC_SOCKADDR_LEN_T +#define ISC_SOCKADDR_LEN_T unsigned int +#endif + +/* + * Define what the possible "soft" errors can be. These are non-fatal returns + * of various network related functions, like recv() and so on. + */ +#define SOFT_ERROR(e) ((e) == WSAEINTR || \ + (e) == WSAEWOULDBLOCK || \ + (e) == EWOULDBLOCK || \ + (e) == EINTR || \ + (e) == EAGAIN || \ + (e) == 0) + +/* + * Pending errors are not really errors and should be + * kept separate + */ +#define PENDING_ERROR(e) ((e) == WSA_IO_PENDING || (e) == 0) + +#define DOIO_SUCCESS 0 /* i/o ok, event sent */ +#define DOIO_SOFT 1 /* i/o ok, soft error, no event sent */ +#define DOIO_HARD 2 /* i/o error, event sent */ +#define DOIO_EOF 3 /* EOF, no event sent */ +#define DOIO_PENDING 4 /* status when i/o is in process */ +#define DOIO_NEEDMORE 5 /* IO was processed, but we need more due to minimum */ + +#define DLVL(x) ISC_LOGCATEGORY_GENERAL, ISC_LOGMODULE_SOCKET, ISC_LOG_DEBUG(x) + +/* + * DLVL(90) -- Function entry/exit and other tracing. + * DLVL(70) -- Socket "correctness" -- including returning of events, etc. + * DLVL(60) -- Socket data send/receive + * DLVL(50) -- Event tracing, including receiving/sending completion events. + * DLVL(20) -- Socket creation/destruction. + */ +#define TRACE_LEVEL 90 +#define CORRECTNESS_LEVEL 70 +#define IOEVENT_LEVEL 60 +#define EVENT_LEVEL 50 +#define CREATION_LEVEL 20 + +#define TRACE DLVL(TRACE_LEVEL) +#define CORRECTNESS DLVL(CORRECTNESS_LEVEL) +#define IOEVENT DLVL(IOEVENT_LEVEL) +#define EVENT DLVL(EVENT_LEVEL) +#define CREATION DLVL(CREATION_LEVEL) + +typedef isc_event_t intev_t; + +/* + * Socket State + */ +enum { + SOCK_INITIALIZED, /* Socket Initialized */ + SOCK_OPEN, /* Socket opened but nothing yet to do */ + SOCK_DATA, /* Socket sending or receiving data */ + SOCK_LISTEN, /* TCP Socket listening for connects */ + SOCK_ACCEPT, /* TCP socket is waiting to accept */ + SOCK_CONNECT, /* TCP Socket connecting */ + SOCK_CLOSED, /* Socket has been closed */ +}; + +#define SOCKET_MAGIC ISC_MAGIC('I', 'O', 'i', 'o') +#define VALID_SOCKET(t) ISC_MAGIC_VALID(t, SOCKET_MAGIC) + +/* + * IPv6 control information. If the socket is an IPv6 socket we want + * to collect the destination address and interface so the client can + * set them on outgoing packets. + */ +#ifdef ISC_PLATFORM_HAVEIPV6 +#ifndef USE_CMSG +#define USE_CMSG 1 +#endif +#endif + +/* + * We really don't want to try and use these control messages. Win32 + * doesn't have this mechanism before XP. + */ +#undef USE_CMSG + +/* + * Message header for recvmsg and sendmsg calls. + * Used value-result for recvmsg, value only for sendmsg. + */ +struct msghdr { + SOCKADDR_STORAGE to_addr; /* UDP send/recv address */ + int to_addr_len; /* length of the address */ + WSABUF *msg_iov; /* scatter/gather array */ + u_int msg_iovlen; /* # elements in msg_iov */ + void *msg_control; /* ancillary data, see below */ + u_int msg_controllen; /* ancillary data buffer len */ + int msg_totallen; /* total length of this message */ +} msghdr; + +/* + * The size to raise the receive buffer to. + */ +#define RCVBUFSIZE (32*1024) + +/* + * The number of times a send operation is repeated if the result + * is WSAEINTR. + */ +#define NRETRIES 10 + +struct isc_socket { + /* Not locked. */ + unsigned int magic; + isc_socketmgr_t *manager; + isc_mutex_t lock; + isc_sockettype_t type; + + /* Pointers to scatter/gather buffers */ + WSABUF iov[ISC_SOCKET_MAXSCATTERGATHER]; + + /* Locked by socket lock. */ + ISC_LINK(isc_socket_t) link; + unsigned int references; /* EXTERNAL references */ + SOCKET fd; /* file handle */ + int pf; /* protocol family */ + char name[16]; + void * tag; + + /* + * Each recv() call uses this buffer. It is a per-socket receive + * buffer that allows us to decouple the system recv() from the + * recv_list done events. This means the items on the recv_list + * can be removed without having to cancel pending system recv() + * calls. It also allows us to read-ahead in some cases. + */ + struct { + SOCKADDR_STORAGE from_addr; // UDP send/recv address + int from_addr_len; // length of the address + char *base; // the base of the buffer + char *consume_position; // where to start copying data from next + unsigned int len; // the actual size of this buffer + unsigned int remaining; // the number of bytes remaining + } recvbuf; + + ISC_LIST(isc_socketevent_t) send_list; + ISC_LIST(isc_socketevent_t) recv_list; + ISC_LIST(isc_socket_newconnev_t) accept_list; + isc_socket_connev_t *connect_ev; + + isc_sockaddr_t address; /* remote address */ + + unsigned int listener : 1, /* listener socket */ + connected : 1, + pending_connect : 1, /* connect pending */ + bound : 1, /* bound to local addr */ + dupped : 1; /* created by isc_socket_dup() */ + unsigned int pending_iocp; /* Should equal the counters below. Debug. */ + unsigned int pending_recv; /* Number of outstanding recv() calls. */ + unsigned int pending_send; /* Number of outstanding send() calls. */ + unsigned int pending_accept; /* Number of outstanding accept() calls. */ + unsigned int state; /* Socket state. Debugging and consistency checking. */ + int state_lineno; /* line which last touched state */ +}; + +#define _set_state(sock, _state) do { (sock)->state = (_state); (sock)->state_lineno = __LINE__; } while (0) + +/* + * Buffer structure + */ +typedef struct buflist buflist_t; + +struct buflist { + void *buf; + unsigned int buflen; + ISC_LINK(buflist_t) link; +}; + +/* + * I/O Completion ports Info structures + */ + +static HANDLE hHeapHandle = NULL; +typedef struct IoCompletionInfo { + OVERLAPPED overlapped; + isc_socketevent_t *dev; /* send()/recv() done event */ + isc_socket_connev_t *cdev; /* connect() done event */ + isc_socket_newconnev_t *adev; /* accept() done event */ + void *acceptbuffer; + DWORD received_bytes; + int request_type; + struct msghdr messagehdr; + ISC_LIST(buflist_t) bufferlist; /*%< list of buffers */ +} IoCompletionInfo; + +/* + * Define a maximum number of I/O Completion Port worker threads + * to handle the load on the Completion Port. The actual number + * used is the number of CPU's + 1. + */ +#define MAX_IOCPTHREADS 20 + +#define SOCKET_MANAGER_MAGIC ISC_MAGIC('I', 'O', 'm', 'g') +#define VALID_MANAGER(m) ISC_MAGIC_VALID(m, SOCKET_MANAGER_MAGIC) + +struct isc_socketmgr { + /* Not locked. */ + unsigned int magic; + isc_mem_t *mctx; + isc_mutex_t lock; + isc_stats_t *stats; + + /* Locked by manager lock. */ + ISC_LIST(isc_socket_t) socklist; + isc_boolean_t bShutdown; + isc_condition_t shutdown_ok; + HANDLE hIoCompletionPort; + int maxIOCPThreads; + HANDLE hIOCPThreads[MAX_IOCPTHREADS]; + DWORD dwIOCPThreadIds[MAX_IOCPTHREADS]; + + /* + * Debugging. + * Modified by InterlockedIncrement() and InterlockedDecrement() + */ + LONG totalSockets; + LONG iocp_total; +}; + +enum { + SOCKET_RECV, + SOCKET_SEND, + SOCKET_ACCEPT, + SOCKET_CONNECT +}; + +/* + * send() and recv() iovec counts + */ +#define MAXSCATTERGATHER_SEND (ISC_SOCKET_MAXSCATTERGATHER) +#define MAXSCATTERGATHER_RECV (ISC_SOCKET_MAXSCATTERGATHER) + +static isc_result_t socket_create(isc_socketmgr_t *manager0, int pf, + isc_sockettype_t type, + isc_socket_t **socketp, + isc_socket_t *dup_socket); +static isc_threadresult_t WINAPI SocketIoThread(LPVOID ThreadContext); +static void maybe_free_socket(isc_socket_t **, int); +static void free_socket(isc_socket_t **, int); +static isc_boolean_t senddone_is_active(isc_socket_t *sock, isc_socketevent_t *dev); +static isc_boolean_t acceptdone_is_active(isc_socket_t *sock, isc_socket_newconnev_t *dev); +static isc_boolean_t connectdone_is_active(isc_socket_t *sock, isc_socket_connev_t *dev); +static void send_recvdone_event(isc_socket_t *sock, isc_socketevent_t **dev); +static void send_senddone_event(isc_socket_t *sock, isc_socketevent_t **dev); +static void send_acceptdone_event(isc_socket_t *sock, isc_socket_newconnev_t **adev); +static void send_connectdone_event(isc_socket_t *sock, isc_socket_connev_t **cdev); +static void send_recvdone_abort(isc_socket_t *sock, isc_result_t result); +static void queue_receive_event(isc_socket_t *sock, isc_task_t *task, isc_socketevent_t *dev); +static void queue_receive_request(isc_socket_t *sock); + +/* + * This is used to dump the contents of the sock structure + * You should make sure that the sock is locked before + * dumping it. Since the code uses simple printf() statements + * it should only be used interactively. + */ +void +sock_dump(isc_socket_t *sock) { + isc_socketevent_t *ldev; + isc_socket_newconnev_t *ndev; + +#if 0 + isc_sockaddr_t addr; + char socktext[256]; + + isc_socket_getpeername(sock, &addr); + isc_sockaddr_format(&addr, socktext, sizeof(socktext)); + printf("Remote Socket: %s\n", socktext); + isc_socket_getsockname(sock, &addr); + isc_sockaddr_format(&addr, socktext, sizeof(socktext)); + printf("This Socket: %s\n", socktext); +#endif + + printf("\n\t\tSock Dump\n"); + printf("\t\tfd: %u\n", sock->fd); + printf("\t\treferences: %d\n", sock->references); + printf("\t\tpending_accept: %d\n", sock->pending_accept); + printf("\t\tconnecting: %d\n", sock->pending_connect); + printf("\t\tconnected: %d\n", sock->connected); + printf("\t\tbound: %d\n", sock->bound); + printf("\t\tpending_iocp: %d\n", sock->pending_iocp); + printf("\t\tsocket type: %d\n", sock->type); + + printf("\n\t\tSock Recv List\n"); + ldev = ISC_LIST_HEAD(sock->recv_list); + while (ldev != NULL) { + printf("\t\tdev: %p\n", ldev); + ldev = ISC_LIST_NEXT(ldev, ev_link); + } + + printf("\n\t\tSock Send List\n"); + ldev = ISC_LIST_HEAD(sock->send_list); + while (ldev != NULL) { + printf("\t\tdev: %p\n", ldev); + ldev = ISC_LIST_NEXT(ldev, ev_link); + } + + printf("\n\t\tSock Accept List\n"); + ndev = ISC_LIST_HEAD(sock->accept_list); + while (ndev != NULL) { + printf("\t\tdev: %p\n", ldev); + ndev = ISC_LIST_NEXT(ndev, ev_link); + } +} + +static void +socket_log(int lineno, isc_socket_t *sock, isc_sockaddr_t *address, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *fmt, ...) ISC_FORMAT_PRINTF(9, 10); + +/* This function will add an entry to the I/O completion port + * that will signal the I/O thread to exit (gracefully) + */ +static void +signal_iocompletionport_exit(isc_socketmgr_t *manager) { + int i; + int errval; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_MANAGER(manager)); + for (i = 0; i < manager->maxIOCPThreads; i++) { + if (!PostQueuedCompletionStatus(manager->hIoCompletionPort, + 0, 0, 0)) { + errval = GetLastError(); + isc__strerror(errval, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FAILED, + "Can't request service thread to exit: %s"), + strbuf); + } + } +} + +/* + * Create the worker threads for the I/O Completion Port + */ +void +iocompletionport_createthreads(int total_threads, isc_socketmgr_t *manager) { + int errval; + char strbuf[ISC_STRERRORSIZE]; + int i; + + INSIST(total_threads > 0); + REQUIRE(VALID_MANAGER(manager)); + /* + * We need at least one + */ + for (i = 0; i < total_threads; i++) { + manager->hIOCPThreads[i] = CreateThread(NULL, 0, SocketIoThread, + manager, 0, + &manager->dwIOCPThreadIds[i]); + if (manager->hIOCPThreads[i] == NULL) { + errval = GetLastError(); + isc__strerror(errval, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FAILED, + "Can't create IOCP thread: %s"), + strbuf); + exit(1); + } + } +} + +/* + * Create/initialise the I/O completion port + */ +void +iocompletionport_init(isc_socketmgr_t *manager) { + int errval; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_MANAGER(manager)); + /* + * Create a private heap to handle the socket overlapped structure + * The minimum number of structures is 10, there is no maximum + */ + hHeapHandle = HeapCreate(0, 10 * sizeof(IoCompletionInfo), 0); + if (hHeapHandle == NULL) { + errval = GetLastError(); + isc__strerror(errval, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FAILED, + "HeapCreate() failed during " + "initialization: %s"), + strbuf); + exit(1); + } + + manager->maxIOCPThreads = min(isc_os_ncpus() + 1, MAX_IOCPTHREADS); + + /* Now Create the Completion Port */ + manager->hIoCompletionPort = CreateIoCompletionPort( + INVALID_HANDLE_VALUE, NULL, + 0, manager->maxIOCPThreads); + if (manager->hIoCompletionPort == NULL) { + errval = GetLastError(); + isc__strerror(errval, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FAILED, + "CreateIoCompletionPort() failed " + "during initialization: %s"), + strbuf); + exit(1); + } + + /* + * Worker threads for servicing the I/O + */ + iocompletionport_createthreads(manager->maxIOCPThreads, manager); +} + +/* + * Associate a socket with an IO Completion Port. This allows us to queue events for it + * and have our worker pool of threads process them. + */ +void +iocompletionport_update(isc_socket_t *sock) { + HANDLE hiocp; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + + hiocp = CreateIoCompletionPort((HANDLE)sock->fd, + sock->manager->hIoCompletionPort, (ULONG_PTR)sock, 0); + + if (hiocp == NULL) { + DWORD errval = GetLastError(); + isc__strerror(errval, strbuf, sizeof(strbuf)); + isc_log_iwrite(isc_lctx, + ISC_LOGCATEGORY_GENERAL, + ISC_LOGMODULE_SOCKET, ISC_LOG_ERROR, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_TOOMANYHANDLES, + "iocompletionport_update: failed to open" + " io completion port: %s", + strbuf); + + /* XXXMLG temporary hack to make failures detected. + * This function should return errors to the caller, not + * exit here. + */ + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FAILED, + "CreateIoCompletionPort() failed " + "during initialization: %s"), + strbuf); + exit(1); + } + + InterlockedIncrement(&sock->manager->iocp_total); +} + +/* + * Routine to cleanup and then close the socket. + * Only close the socket here if it is NOT associated + * with an event, otherwise the WSAWaitForMultipleEvents + * may fail due to the fact that the Wait should not + * be running while closing an event or a socket. + * The socket is locked before calling this function + */ +void +socket_close(isc_socket_t *sock) { + + REQUIRE(sock != NULL); + + if (sock->fd != INVALID_SOCKET) { + closesocket(sock->fd); + sock->fd = INVALID_SOCKET; + _set_state(sock, SOCK_CLOSED); + InterlockedDecrement(&sock->manager->totalSockets); + } +} + +static isc_once_t initialise_once = ISC_ONCE_INIT; +static isc_boolean_t initialised = ISC_FALSE; + +static void +initialise(void) { + WORD wVersionRequested; + WSADATA wsaData; + int err; + SOCKET sock; + GUID GUIDConnectEx = WSAID_CONNECTEX; + GUID GUIDAcceptEx = WSAID_ACCEPTEX; + GUID GUIDGetAcceptExSockaddrs = WSAID_GETACCEPTEXSOCKADDRS; + DWORD dwBytes; + + /* Need Winsock 2.2 or better */ + wVersionRequested = MAKEWORD(2, 2); + + err = WSAStartup(wVersionRequested, &wsaData); + if (err != 0) { + char strbuf[ISC_STRERRORSIZE]; + isc__strerror(err, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, "WSAStartup() %s: %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed"), + strbuf); + exit(1); + } + /* + * The following APIs do not exist as functions in a library, but we must + * ask winsock for them. They are "extensions" -- but why they cannot be + * actual functions is beyond me. So, ask winsock for the pointers to the + * functions we need. + */ + sock = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP); + INSIST(sock != INVALID_SOCKET); + err = WSAIoctl(sock, SIO_GET_EXTENSION_FUNCTION_POINTER, + &GUIDConnectEx, sizeof(GUIDConnectEx), + &ISCConnectEx, sizeof(ISCConnectEx), + &dwBytes, NULL, NULL); + INSIST(err == 0); + + err = WSAIoctl(sock, SIO_GET_EXTENSION_FUNCTION_POINTER, + &GUIDAcceptEx, sizeof(GUIDAcceptEx), + &ISCAcceptEx, sizeof(ISCAcceptEx), + &dwBytes, NULL, NULL); + INSIST(err == 0); + + err = WSAIoctl(sock, SIO_GET_EXTENSION_FUNCTION_POINTER, + &GUIDGetAcceptExSockaddrs, sizeof(GUIDGetAcceptExSockaddrs), + &ISCGetAcceptExSockaddrs, sizeof(ISCGetAcceptExSockaddrs), + &dwBytes, NULL, NULL); + INSIST(err == 0); + + closesocket(sock); + + initialised = ISC_TRUE; +} + +/* + * Initialize socket services + */ +void +InitSockets(void) { + RUNTIME_CHECK(isc_once_do(&initialise_once, + initialise) == ISC_R_SUCCESS); + if (!initialised) + exit(1); +} + +int +internal_sendmsg(isc_socket_t *sock, IoCompletionInfo *lpo, + struct msghdr *messagehdr, int flags, int *Error) +{ + int Result; + DWORD BytesSent; + DWORD Flags = flags; + int total_sent; + + *Error = 0; + Result = WSASendTo(sock->fd, messagehdr->msg_iov, + messagehdr->msg_iovlen, &BytesSent, + Flags, (SOCKADDR *)&messagehdr->to_addr, + messagehdr->to_addr_len, (LPWSAOVERLAPPED)lpo, + NULL); + + total_sent = (int)BytesSent; + + /* Check for errors.*/ + if (Result == SOCKET_ERROR) { + *Error = WSAGetLastError(); + + switch (*Error) { + case WSA_IO_INCOMPLETE: + case WSA_WAIT_IO_COMPLETION: + case WSA_IO_PENDING: + case NO_ERROR: /* Strange, but okay */ + sock->pending_iocp++; + sock->pending_send++; + break; + + default: + return (-1); + break; + } + } else { + sock->pending_iocp++; + sock->pending_send++; + } + + if (lpo != NULL) + return (0); + else + return (total_sent); +} + +static void +queue_receive_request(isc_socket_t *sock) { + DWORD Flags = 0; + DWORD NumBytes = 0; + int total_bytes = 0; + int Result; + int Error; + int need_retry; + WSABUF iov[1]; + IoCompletionInfo *lpo = NULL; + isc_result_t isc_result; + + retry: + need_retry = ISC_FALSE; + + /* + * If we already have a receive pending, do nothing. + */ + if (sock->pending_recv > 0) { + if (lpo != NULL) + HeapFree(hHeapHandle, 0, lpo); + return; + } + + /* + * If no one is waiting, do nothing. + */ + if (ISC_LIST_EMPTY(sock->recv_list)) { + if (lpo != NULL) + HeapFree(hHeapHandle, 0, lpo); + return; + } + + INSIST(sock->recvbuf.remaining == 0); + INSIST(sock->fd != INVALID_SOCKET); + + iov[0].len = sock->recvbuf.len; + iov[0].buf = sock->recvbuf.base; + + if (lpo == NULL) { + lpo = (IoCompletionInfo *)HeapAlloc(hHeapHandle, + HEAP_ZERO_MEMORY, + sizeof(IoCompletionInfo)); + RUNTIME_CHECK(lpo != NULL); + } else + ZeroMemory(lpo, sizeof(IoCompletionInfo)); + lpo->request_type = SOCKET_RECV; + + sock->recvbuf.from_addr_len = sizeof(sock->recvbuf.from_addr); + + Error = 0; + Result = WSARecvFrom((SOCKET)sock->fd, iov, 1, + &NumBytes, &Flags, + (SOCKADDR *)&sock->recvbuf.from_addr, + &sock->recvbuf.from_addr_len, + (LPWSAOVERLAPPED)lpo, NULL); + + /* Check for errors. */ + if (Result == SOCKET_ERROR) { + Error = WSAGetLastError(); + + switch (Error) { + case WSA_IO_PENDING: + sock->pending_iocp++; + sock->pending_recv++; + break; + + /* direct error: no completion event */ + case ERROR_HOST_UNREACHABLE: + case WSAENETRESET: + case WSAECONNRESET: + if (!sock->connected) { + /* soft error */ + need_retry = ISC_TRUE; + break; + } + /* FALLTHROUGH */ + + default: + isc_result = isc__errno2result(Error); + if (isc_result == ISC_R_UNEXPECTED) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "WSARecvFrom: Windows error code: %d, isc result %d", + Error, isc_result); + send_recvdone_abort(sock, isc_result); + HeapFree(hHeapHandle, 0, lpo); + lpo = NULL; + break; + } + } else { + /* + * The recv() finished immediately, but we will still get + * a completion event. Rather than duplicate code, let + * that thread handle sending the data along its way. + */ + sock->pending_iocp++; + sock->pending_recv++; + } + + socket_log(__LINE__, sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_DOIORECV, + "queue_io_request: fd %d result %d error %d", + sock->fd, Result, Error); + + CONSISTENT(sock); + + if (need_retry) + goto retry; +} + +static void +manager_log(isc_socketmgr_t *sockmgr, isc_logcategory_t *category, + isc_logmodule_t *module, int level, const char *fmt, ...) +{ + char msgbuf[2048]; + va_list ap; + + if (!isc_log_wouldlog(isc_lctx, level)) + return; + + va_start(ap, fmt); + vsnprintf(msgbuf, sizeof(msgbuf), fmt, ap); + va_end(ap); + + isc_log_write(isc_lctx, category, module, level, + "sockmgr %p: %s", sockmgr, msgbuf); +} + +static void +socket_log(int lineno, isc_socket_t *sock, isc_sockaddr_t *address, + isc_logcategory_t *category, isc_logmodule_t *module, int level, + isc_msgcat_t *msgcat, int msgset, int message, + const char *fmt, ...) +{ + char msgbuf[2048]; + char peerbuf[256]; + va_list ap; + + + if (!isc_log_wouldlog(isc_lctx, level)) + return; + + va_start(ap, fmt); + vsnprintf(msgbuf, sizeof(msgbuf), fmt, ap); + va_end(ap); + + if (address == NULL) { + isc_log_iwrite(isc_lctx, category, module, level, + msgcat, msgset, message, + "socket %p line %d: %s", sock, lineno, msgbuf); + } else { + isc_sockaddr_format(address, peerbuf, sizeof(peerbuf)); + isc_log_iwrite(isc_lctx, category, module, level, + msgcat, msgset, message, + "socket %p line %d peer %s: %s", sock, lineno, + peerbuf, msgbuf); + } + +} + +/* + * Make an fd SOCKET non-blocking. + */ +static isc_result_t +make_nonblock(SOCKET fd) { + int ret; + unsigned long flags = 1; + char strbuf[ISC_STRERRORSIZE]; + + /* Set the socket to non-blocking */ + ret = ioctlsocket(fd, FIONBIO, &flags); + + if (ret == -1) { + isc__strerror(errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "ioctlsocket(%d, FIOBIO, %d): %s", + fd, flags, strbuf); + + return (ISC_R_UNEXPECTED); + } + + return (ISC_R_SUCCESS); +} + +/* + * Windows 2000 systems incorrectly cause UDP sockets using WSARecvFrom + * to not work correctly, returning a WSACONNRESET error when a WSASendTo + * fails with an "ICMP port unreachable" response and preventing the + * socket from using the WSARecvFrom in subsequent operations. + * The function below fixes this, but requires that Windows 2000 + * Service Pack 2 or later be installed on the system. NT 4.0 + * systems are not affected by this and work correctly. + * See Microsoft Knowledge Base Article Q263823 for details of this. + */ +isc_result_t +connection_reset_fix(SOCKET fd) { + DWORD dwBytesReturned = 0; + BOOL bNewBehavior = FALSE; + DWORD status; + + if (isc_win32os_majorversion() < 5) + return (ISC_R_SUCCESS); /* NT 4.0 has no problem */ + + /* disable bad behavior using IOCTL: SIO_UDP_CONNRESET */ + status = WSAIoctl(fd, SIO_UDP_CONNRESET, &bNewBehavior, + sizeof(bNewBehavior), NULL, 0, + &dwBytesReturned, NULL, NULL); + if (status != SOCKET_ERROR) + return (ISC_R_SUCCESS); + else { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "WSAIoctl(SIO_UDP_CONNRESET, oldBehaviour) %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + return (ISC_R_UNEXPECTED); + } +} + +/* + * Construct an iov array and attach it to the msghdr passed in. This is + * the SEND constructor, which will use the used region of the buffer + * (if using a buffer list) or will use the internal region (if a single + * buffer I/O is requested). + * + * Nothing can be NULL, and the done event must list at least one buffer + * on the buffer linked list for this function to be meaningful. + */ +static void +build_msghdr_send(isc_socket_t *sock, isc_socketevent_t *dev, + struct msghdr *msg, char *cmsg, WSABUF *iov, + IoCompletionInfo *lpo) +{ + unsigned int iovcount; + isc_buffer_t *buffer; + buflist_t *cpbuffer; + isc_region_t used; + size_t write_count; + size_t skip_count; + + memset(msg, 0, sizeof(*msg)); + + memcpy(&msg->to_addr, &dev->address.type, dev->address.length); + msg->to_addr_len = dev->address.length; + + buffer = ISC_LIST_HEAD(dev->bufferlist); + write_count = 0; + iovcount = 0; + + /* + * Single buffer I/O? Skip what we've done so far in this region. + */ + if (buffer == NULL) { + write_count = dev->region.length - dev->n; + cpbuffer = HeapAlloc(hHeapHandle, HEAP_ZERO_MEMORY, sizeof(buflist_t)); + RUNTIME_CHECK(cpbuffer != NULL); + cpbuffer->buf = HeapAlloc(hHeapHandle, HEAP_ZERO_MEMORY, write_count); + RUNTIME_CHECK(cpbuffer->buf != NULL); + + socket_log(__LINE__, sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTLOCK, + "alloc_buffer %p %d %p %d", cpbuffer, sizeof(buflist_t), + cpbuffer->buf, write_count); + + memcpy(cpbuffer->buf,(dev->region.base + dev->n), write_count); + cpbuffer->buflen = write_count; + ISC_LIST_ENQUEUE(lpo->bufferlist, cpbuffer, link); + iov[0].buf = cpbuffer->buf; + iov[0].len = write_count; + iovcount = 1; + + goto config; + } + + /* + * Multibuffer I/O. + * Skip the data in the buffer list that we have already written. + */ + skip_count = dev->n; + while (buffer != NULL) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (skip_count < isc_buffer_usedlength(buffer)) + break; + skip_count -= isc_buffer_usedlength(buffer); + buffer = ISC_LIST_NEXT(buffer, link); + } + + while (buffer != NULL) { + INSIST(iovcount < MAXSCATTERGATHER_SEND); + + isc_buffer_usedregion(buffer, &used); + + if (used.length > 0) { + int uselen = used.length - skip_count; + cpbuffer = HeapAlloc(hHeapHandle, HEAP_ZERO_MEMORY, sizeof(buflist_t)); + RUNTIME_CHECK(cpbuffer != NULL); + cpbuffer->buf = HeapAlloc(hHeapHandle, HEAP_ZERO_MEMORY, uselen); + RUNTIME_CHECK(cpbuffer->buf != NULL); + + socket_log(__LINE__, sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTLOCK, + "alloc_buffer %p %d %p %d", cpbuffer, sizeof(buflist_t), + cpbuffer->buf, write_count); + + memcpy(cpbuffer->buf,(used.base + skip_count), uselen); + cpbuffer->buflen = uselen; + iov[iovcount].buf = cpbuffer->buf; + iov[iovcount].len = used.length - skip_count; + write_count += uselen; + skip_count = 0; + iovcount++; + } + buffer = ISC_LIST_NEXT(buffer, link); + } + + INSIST(skip_count == 0); + + config: + msg->msg_iov = iov; + msg->msg_iovlen = iovcount; + msg->msg_totallen = write_count; +} + +static void +set_dev_address(isc_sockaddr_t *address, isc_socket_t *sock, + isc_socketevent_t *dev) +{ + if (sock->type == isc_sockettype_udp) { + if (address != NULL) + dev->address = *address; + else + dev->address = sock->address; + } else if (sock->type == isc_sockettype_tcp) { + INSIST(address == NULL); + dev->address = sock->address; + } +} + +static void +destroy_socketevent(isc_event_t *event) { + isc_socketevent_t *ev = (isc_socketevent_t *)event; + + INSIST(ISC_LIST_EMPTY(ev->bufferlist)); + + (ev->destroy)(event); +} + +static isc_socketevent_t * +allocate_socketevent(isc_socket_t *sock, isc_eventtype_t eventtype, + isc_taskaction_t action, const void *arg) +{ + isc_socketevent_t *ev; + + ev = (isc_socketevent_t *)isc_event_allocate(sock->manager->mctx, + sock, eventtype, + action, arg, + sizeof(*ev)); + if (ev == NULL) + return (NULL); + + ev->result = ISC_R_IOERROR; // XXXMLG temporary change to detect failure to set + ISC_LINK_INIT(ev, ev_link); + ISC_LIST_INIT(ev->bufferlist); + ev->region.base = NULL; + ev->n = 0; + ev->offset = 0; + ev->attributes = 0; + ev->destroy = ev->ev_destroy; + ev->ev_destroy = destroy_socketevent; + + return (ev); +} + +#if defined(ISC_SOCKET_DEBUG) +static void +dump_msg(struct msghdr *msg, isc_socket_t *sock) { + unsigned int i; + + printf("MSGHDR %p, Socket #: %u\n", msg, sock->fd); + printf("\tname %p, namelen %d\n", msg->msg_name, msg->msg_namelen); + printf("\tiov %p, iovlen %d\n", msg->msg_iov, msg->msg_iovlen); + for (i = 0; i < (unsigned int)msg->msg_iovlen; i++) + printf("\t\t%d\tbase %p, len %d\n", i, + msg->msg_iov[i].buf, + msg->msg_iov[i].len); +} +#endif + +/* + * map the error code + */ +int +map_socket_error(isc_socket_t *sock, int windows_errno, int *isc_errno, + char *errorstring, size_t bufsize) { + + int doreturn; + switch (windows_errno) { + case WSAECONNREFUSED: + *isc_errno = ISC_R_CONNREFUSED; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case WSAENETUNREACH: + case ERROR_NETWORK_UNREACHABLE: + *isc_errno = ISC_R_NETUNREACH; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case ERROR_PORT_UNREACHABLE: + case ERROR_HOST_UNREACHABLE: + case WSAEHOSTUNREACH: + *isc_errno = ISC_R_HOSTUNREACH; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case WSAENETDOWN: + *isc_errno = ISC_R_NETDOWN; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case WSAEHOSTDOWN: + *isc_errno = ISC_R_HOSTDOWN; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case WSAEACCES: + *isc_errno = ISC_R_NOPERM; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case WSAECONNRESET: + case WSAENETRESET: + case WSAECONNABORTED: + case WSAEDISCON: + *isc_errno = ISC_R_CONNECTIONRESET; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case WSAENOTCONN: + *isc_errno = ISC_R_NOTCONNECTED; + if (sock->connected) + doreturn = DOIO_HARD; + else + doreturn = DOIO_SOFT; + break; + case ERROR_OPERATION_ABORTED: + case ERROR_CONNECTION_ABORTED: + case ERROR_REQUEST_ABORTED: + *isc_errno = ISC_R_CONNECTIONRESET; + doreturn = DOIO_HARD; + break; + case WSAENOBUFS: + *isc_errno = ISC_R_NORESOURCES; + doreturn = DOIO_HARD; + break; + case WSAEAFNOSUPPORT: + *isc_errno = ISC_R_FAMILYNOSUPPORT; + doreturn = DOIO_HARD; + break; + case WSAEADDRNOTAVAIL: + *isc_errno = ISC_R_ADDRNOTAVAIL; + doreturn = DOIO_HARD; + break; + case WSAEDESTADDRREQ: + *isc_errno = ISC_R_BADADDRESSFORM; + doreturn = DOIO_HARD; + break; + case ERROR_NETNAME_DELETED: + *isc_errno = ISC_R_NETDOWN; + doreturn = DOIO_HARD; + break; + default: + *isc_errno = ISC_R_IOERROR; + doreturn = DOIO_HARD; + break; + } + if (doreturn == DOIO_HARD) { + isc__strerror(windows_errno, errorstring, bufsize); + } + return (doreturn); +} + +static void +fill_recv(isc_socket_t *sock, isc_socketevent_t *dev) { + isc_region_t r; + int copylen; + isc_buffer_t *buffer; + + INSIST(dev->n < dev->minimum); + INSIST(sock->recvbuf.remaining > 0); + INSIST(sock->pending_recv == 0); + + if (sock->type == isc_sockettype_udp) { + dev->address.length = sock->recvbuf.from_addr_len; + memcpy(&dev->address.type, &sock->recvbuf.from_addr, + sock->recvbuf.from_addr_len); + if (isc_sockaddr_getport(&dev->address) == 0) { + if (isc_log_wouldlog(isc_lctx, IOEVENT_LEVEL)) { + socket_log(__LINE__, sock, &dev->address, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_ZEROPORT, + "dropping source port zero packet"); + } + sock->recvbuf.remaining = 0; + return; + } + } else if (sock->type == isc_sockettype_tcp) { + dev->address = sock->address; + } + + /* + * Run through the list of buffers we were given, and find the + * first one with space. Once it is found, loop through, filling + * the buffers as much as possible. + */ + buffer = ISC_LIST_HEAD(dev->bufferlist); + if (buffer != NULL) { // Multi-buffer receive + while (buffer != NULL && sock->recvbuf.remaining > 0) { + REQUIRE(ISC_BUFFER_VALID(buffer)); + if (isc_buffer_availablelength(buffer) > 0) { + isc_buffer_availableregion(buffer, &r); + copylen = min(r.length, sock->recvbuf.remaining); + memcpy(r.base, sock->recvbuf.consume_position, copylen); + sock->recvbuf.consume_position += copylen; + sock->recvbuf.remaining -= copylen; + isc_buffer_add(buffer, copylen); + dev->n += copylen; + } + buffer = ISC_LIST_NEXT(buffer, link); + } + } else { // Single-buffer receive + copylen = min(dev->region.length - dev->n, sock->recvbuf.remaining); + memcpy(dev->region.base + dev->n, sock->recvbuf.consume_position, copylen); + sock->recvbuf.consume_position += copylen; + sock->recvbuf.remaining -= copylen; + dev->n += copylen; + } + + /* + * UDP receives are all-consuming. That is, if we have 4k worth of + * data in our receive buffer, and the caller only gave us + * 1k of space, we will toss the remaining 3k of data. TCP + * will keep the extra data around and use it for later requests. + */ + if (sock->type == isc_sockettype_udp) + sock->recvbuf.remaining = 0; +} + +/* + * Copy out as much data from the internal buffer to done events. + * As each done event is filled, send it along its way. + */ +static void +completeio_recv(isc_socket_t *sock) +{ + isc_socketevent_t *dev; + + /* + * If we are in the process of filling our buffer, we cannot + * touch it yet, so don't. + */ + if (sock->pending_recv > 0) + return; + + while (sock->recvbuf.remaining > 0 && !ISC_LIST_EMPTY(sock->recv_list)) { + dev = ISC_LIST_HEAD(sock->recv_list); + + /* + * See if we have sufficient data in our receive buffer + * to handle this. If we do, copy out the data. + */ + fill_recv(sock, dev); + + /* + * Did we satisfy it? + */ + if (dev->n >= dev->minimum) { + dev->result = ISC_R_SUCCESS; + send_recvdone_event(sock, &dev); + } + } +} + +/* + * Returns: + * DOIO_SUCCESS The operation succeeded. dev->result contains + * ISC_R_SUCCESS. + * + * DOIO_HARD A hard or unexpected I/O error was encountered. + * dev->result contains the appropriate error. + * + * DOIO_SOFT A soft I/O error was encountered. No senddone + * event was sent. The operation should be retried. + * + * No other return values are possible. + */ +static int +completeio_send(isc_socket_t *sock, isc_socketevent_t *dev, + struct msghdr *messagehdr, int cc, int send_errno) +{ + char addrbuf[ISC_SOCKADDR_FORMATSIZE]; + char strbuf[ISC_STRERRORSIZE]; + + if (send_errno != 0) { + if (SOFT_ERROR(send_errno)) + return (DOIO_SOFT); + + return (map_socket_error(sock, send_errno, &dev->result, + strbuf, sizeof(strbuf))); + + /* + * The other error types depend on whether or not the + * socket is UDP or TCP. If it is UDP, some errors + * that we expect to be fatal under TCP are merely + * annoying, and are really soft errors. + * + * However, these soft errors are still returned as + * a status. + */ + isc_sockaddr_format(&dev->address, addrbuf, sizeof(addrbuf)); + isc__strerror(send_errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "completeio_send: %s: %s", + addrbuf, strbuf); + dev->result = isc__errno2result(send_errno); + return (DOIO_HARD); + } + + /* + * If we write less than we expected, update counters, poke. + */ + dev->n += cc; + if (cc != messagehdr->msg_totallen) + return (DOIO_SOFT); + + /* + * Exactly what we wanted to write. We're done with this + * entry. Post its completion event. + */ + dev->result = ISC_R_SUCCESS; + return (DOIO_SUCCESS); +} + +static int +startio_send(isc_socket_t *sock, isc_socketevent_t *dev, int *nbytes, + int *send_errno) +{ + char *cmsg = NULL; + char strbuf[ISC_STRERRORSIZE]; + IoCompletionInfo *lpo; + int status; + struct msghdr *msghdr; + + lpo = (IoCompletionInfo *)HeapAlloc(hHeapHandle, + HEAP_ZERO_MEMORY, + sizeof(IoCompletionInfo)); + RUNTIME_CHECK(lpo != NULL); + lpo->request_type = SOCKET_SEND; + lpo->dev = dev; + msghdr = &lpo->messagehdr; + memset(msghdr, 0, sizeof(struct msghdr)); + ISC_LIST_INIT(lpo->bufferlist); + + build_msghdr_send(sock, dev, msghdr, cmsg, sock->iov, lpo); + + *nbytes = internal_sendmsg(sock, lpo, msghdr, 0, send_errno); + + if (*nbytes < 0) { + /* + * I/O has been initiated + * completion will be through the completion port + */ + if (PENDING_ERROR(*send_errno)) { + status = DOIO_PENDING; + goto done; + } + + if (SOFT_ERROR(*send_errno)) { + status = DOIO_SOFT; + goto done; + } + + /* + * If we got this far then something is wrong + */ + if (isc_log_wouldlog(isc_lctx, IOEVENT_LEVEL)) { + isc__strerror(*send_errno, strbuf, sizeof(strbuf)); + socket_log(__LINE__, sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_INTERNALSEND, + "startio_send: internal_sendmsg(%d) %d " + "bytes, err %d/%s", + sock->fd, *nbytes, *send_errno, strbuf); + } + status = DOIO_HARD; + goto done; + } + dev->result = ISC_R_SUCCESS; + status = DOIO_SOFT; + done: + _set_state(sock, SOCK_DATA); + return (status); +} + +static isc_result_t +allocate_socket(isc_socketmgr_t *manager, isc_sockettype_t type, + isc_socket_t **socketp) { + isc_socket_t *sock; + isc_result_t result; + + sock = isc_mem_get(manager->mctx, sizeof(*sock)); + + if (sock == NULL) + return (ISC_R_NOMEMORY); + + sock->magic = 0; + sock->references = 0; + + sock->manager = manager; + sock->type = type; + sock->fd = INVALID_SOCKET; + + ISC_LINK_INIT(sock, link); + + /* + * set up list of readers and writers to be initially empty + */ + ISC_LIST_INIT(sock->recv_list); + ISC_LIST_INIT(sock->send_list); + ISC_LIST_INIT(sock->accept_list); + sock->connect_ev = NULL; + sock->pending_accept = 0; + sock->pending_recv = 0; + sock->pending_send = 0; + sock->pending_iocp = 0; + sock->listener = 0; + sock->connected = 0; + sock->pending_connect = 0; + sock->bound = 0; + sock->dupped = 0; + memset(sock->name, 0, sizeof(sock->name)); // zero the name field + _set_state(sock, SOCK_INITIALIZED); + + sock->recvbuf.len = 65536; + sock->recvbuf.consume_position = sock->recvbuf.base; + sock->recvbuf.remaining = 0; + sock->recvbuf.base = isc_mem_get(manager->mctx, sock->recvbuf.len); // max buffer size + if (sock->recvbuf.base == NULL) { + sock->magic = 0; + goto error; + } + + /* + * initialize the lock + */ + result = isc_mutex_init(&sock->lock); + if (result != ISC_R_SUCCESS) { + sock->magic = 0; + isc_mem_put(manager->mctx, sock->recvbuf.base, sock->recvbuf.len); + sock->recvbuf.base = NULL; + goto error; + } + + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "allocated"); + + sock->magic = SOCKET_MAGIC; + *socketp = sock; + + return (ISC_R_SUCCESS); + + error: + isc_mem_put(manager->mctx, sock, sizeof(*sock)); + + return (result); +} + +/* + * Verify that the socket state is consistent. + */ +static void +consistent(isc_socket_t *sock) { + + isc_socketevent_t *dev; + isc_socket_newconnev_t *nev; + unsigned int count; + char *crash_reason; + isc_boolean_t crash = ISC_FALSE; + + REQUIRE(sock->pending_iocp == sock->pending_recv + sock->pending_send + + sock->pending_accept + sock->pending_connect); + + dev = ISC_LIST_HEAD(sock->send_list); + count = 0; + while (dev != NULL) { + count++; + dev = ISC_LIST_NEXT(dev, ev_link); + } + if (count > sock->pending_send) { + crash = ISC_TRUE; + crash_reason = "send_list > sock->pending_send"; + } + + nev = ISC_LIST_HEAD(sock->accept_list); + count = 0; + while (nev != NULL) { + count++; + nev = ISC_LIST_NEXT(nev, ev_link); + } + if (count > sock->pending_accept) { + crash = ISC_TRUE; + crash_reason = "send_list > sock->pending_send"; + } + + if (crash) { + socket_log(__LINE__, sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_DESTROYING, "SOCKET INCONSISTENT: %s", + crash_reason); + sock_dump(sock); + INSIST(crash == ISC_FALSE); + } +} + +/* + * Maybe free the socket. + * + * This function will verify tht the socket is no longer in use in any way, + * either internally or externally. This is the only place where this + * check is to be made; if some bit of code believes that IT is done with + * the socket (e.g., some reference counter reaches zero), it should call + * this function. + * + * When calling this function, the socket must be locked, and the manager + * must be unlocked. + * + * When this function returns, *socketp will be NULL. No tricks to try + * to hold on to this pointer are allowed. + */ +static void +maybe_free_socket(isc_socket_t **socketp, int lineno) { + isc_socket_t *sock = *socketp; + *socketp = NULL; + + INSIST(VALID_SOCKET(sock)); + CONSISTENT(sock); + + if (sock->pending_iocp > 0 + || sock->pending_recv > 0 + || sock->pending_send > 0 + || sock->pending_accept > 0 + || sock->references > 0 + || sock->pending_connect == 1 + || !ISC_LIST_EMPTY(sock->recv_list) + || !ISC_LIST_EMPTY(sock->send_list) + || !ISC_LIST_EMPTY(sock->accept_list) + || sock->fd != INVALID_SOCKET) { + UNLOCK(&sock->lock); + return; + } + UNLOCK(&sock->lock); + + free_socket(&sock, lineno); +} + +void +free_socket(isc_socket_t **sockp, int lineno) { + isc_socketmgr_t *manager; + isc_socket_t *sock = *sockp; + *sockp = NULL; + + manager = sock->manager; + + /* + * Seems we can free the socket after all. + */ + manager = sock->manager; + socket_log(__LINE__, sock, NULL, CREATION, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_DESTROYING, "freeing socket line %d fd %d lock %p semaphore %p", + lineno, sock->fd, &sock->lock, sock->lock.LockSemaphore); + + sock->magic = 0; + DESTROYLOCK(&sock->lock); + + if (sock->recvbuf.base != NULL) + isc_mem_put(manager->mctx, sock->recvbuf.base, sock->recvbuf.len); + + LOCK(&manager->lock); + if (ISC_LINK_LINKED(sock, link)) + ISC_LIST_UNLINK(manager->socklist, sock, link); + isc_mem_put(manager->mctx, sock, sizeof(*sock)); + + if (ISC_LIST_EMPTY(manager->socklist)) + SIGNAL(&manager->shutdown_ok); + UNLOCK(&manager->lock); +} + +/* + * Create a new 'type' socket managed by 'manager'. Events + * will be posted to 'task' and when dispatched 'action' will be + * called with 'arg' as the arg value. The new socket is returned + * in 'socketp'. + */ +static isc_result_t +socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type, + isc_socket_t **socketp, isc_socket_t *dup_socket) +{ + isc_socket_t *sock = NULL; + isc_result_t result; +#if defined(USE_CMSG) + int on = 1; +#endif +#if defined(SO_RCVBUF) + ISC_SOCKADDR_LEN_T optlen; + int size; +#endif + int socket_errno; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(socketp != NULL && *socketp == NULL); + REQUIRE(type != isc_sockettype_fdwatch); + + if (dup_socket != NULL) + return (ISC_R_NOTIMPLEMENTED); + + result = allocate_socket(manager, type, &sock); + if (result != ISC_R_SUCCESS) + return (result); + + sock->pf = pf; +#if 0 + if (dup_socket == NULL) { +#endif + switch (type) { + case isc_sockettype_udp: + sock->fd = socket(pf, SOCK_DGRAM, IPPROTO_UDP); + if (sock->fd != INVALID_SOCKET) { + result = connection_reset_fix(sock->fd); + if (result != ISC_R_SUCCESS) { + socket_log(__LINE__, sock, + NULL, EVENT, NULL, 0, 0, + "closed %d %d %d " + "con_reset_fix_failed", + sock->pending_recv, + sock->pending_send, + sock->references); + closesocket(sock->fd); + _set_state(sock, SOCK_CLOSED); + sock->fd = INVALID_SOCKET; + free_socket(&sock, __LINE__); + return (result); + } + } + break; + case isc_sockettype_tcp: + sock->fd = socket(pf, SOCK_STREAM, IPPROTO_TCP); + break; + } +#if 0 + } else { + /* + * XXX: dup() is deprecated in windows, use _dup() + * instead. In future we may want to investigate + * WSADuplicateSocket(). + */ + sock->fd = _dup(dup_socket->fd); + sock->dupped = 1; + sock->bound = dup_socket->bound; + } +#endif + + if (sock->fd == INVALID_SOCKET) { + socket_errno = WSAGetLastError(); + free_socket(&sock, __LINE__); + + switch (socket_errno) { + case WSAEMFILE: + case WSAENOBUFS: + return (ISC_R_NORESOURCES); + + case WSAEPROTONOSUPPORT: + case WSAEPFNOSUPPORT: + case WSAEAFNOSUPPORT: + return (ISC_R_FAMILYNOSUPPORT); + + default: + isc__strerror(socket_errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "socket() %s: %s", + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + return (ISC_R_UNEXPECTED); + } + } + + result = make_nonblock(sock->fd); + if (result != ISC_R_SUCCESS) { + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "closed %d %d %d make_nonblock_failed", + sock->pending_recv, sock->pending_send, + sock->references); + closesocket(sock->fd); + sock->fd = INVALID_SOCKET; + free_socket(&sock, __LINE__); + return (result); + } + + +#if defined(USE_CMSG) || defined(SO_RCVBUF) + if (type == isc_sockettype_udp) { + +#if defined(USE_CMSG) +#if defined(ISC_PLATFORM_HAVEIPV6) +#ifdef IPV6_RECVPKTINFO + /* 2292bis */ + if ((pf == AF_INET6) + && (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_RECVPKTINFO, + (char *)&on, sizeof(on)) < 0)) { + isc__strerror(WSAGetLastError(), strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_RECVPKTINFO) " + "%s: %s", sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +#else + /* 2292 */ + if ((pf == AF_INET6) + && (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_PKTINFO, + (char *)&on, sizeof(on)) < 0)) { + isc__strerror(WSAGetLastError(), strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d, IPV6_PKTINFO) %s: %s", + sock->fd, + isc_msgcat_get(isc_msgcat, + ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, + "failed"), + strbuf); + } +#endif /* IPV6_RECVPKTINFO */ +#ifdef IPV6_USE_MIN_MTU /*2292bis, not too common yet*/ + /* use minimum MTU */ + if (pf == AF_INET6) { + (void)setsockopt(sock->fd, IPPROTO_IPV6, + IPV6_USE_MIN_MTU, + (char *)&on, sizeof(on)); + } +#endif +#endif /* ISC_PLATFORM_HAVEIPV6 */ +#endif /* defined(USE_CMSG) */ + +#if defined(SO_RCVBUF) + optlen = sizeof(size); + if (getsockopt(sock->fd, SOL_SOCKET, SO_RCVBUF, + (char *)&size, &optlen) >= 0 && + size < RCVBUFSIZE) { + size = RCVBUFSIZE; + (void)setsockopt(sock->fd, SOL_SOCKET, SO_RCVBUF, + (char *)&size, sizeof(size)); + } +#endif + + } +#endif /* defined(USE_CMSG) || defined(SO_RCVBUF) */ + + _set_state(sock, SOCK_OPEN); + sock->references = 1; + *socketp = sock; + + iocompletionport_update(sock); + + /* + * Note we don't have to lock the socket like we normally would because + * there are no external references to it yet. + */ + LOCK(&manager->lock); + ISC_LIST_APPEND(manager->socklist, sock, link); + InterlockedIncrement(&manager->totalSockets); + UNLOCK(&manager->lock); + + socket_log(__LINE__, sock, NULL, CREATION, isc_msgcat, + ISC_MSGSET_SOCKET, ISC_MSG_CREATED, + "created %u type %u", sock->fd, type); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type, + isc_socket_t **socketp) +{ + return (socket_create(manager, pf, type, socketp, NULL)); +} + +isc_result_t +isc__socket_dup(isc_socket_t *sock, isc_socket_t **socketp) { + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(socketp != NULL && *socketp == NULL); + +#if 1 + return (ISC_R_NOTIMPLEMENTED); +#else + return (socket_create(sock->manager, sock->pf, sock->type, + socketp, sock)); +#endif +} + +isc_result_t +isc_socket_open(isc_socket_t *sock) { + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(sock->type != isc_sockettype_fdwatch); + + return (ISC_R_NOTIMPLEMENTED); +} + +/* + * Attach to a socket. Caller must explicitly detach when it is done. + */ +void +isc__socket_attach(isc_socket_t *sock, isc_socket_t **socketp) { + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(socketp != NULL && *socketp == NULL); + + LOCK(&sock->lock); + CONSISTENT(sock); + sock->references++; + UNLOCK(&sock->lock); + + *socketp = sock; +} + +/* + * Dereference a socket. If this is the last reference to it, clean things + * up by destroying the socket. + */ +void +isc__socket_detach(isc_socket_t **socketp) { + isc_socket_t *sock; + isc_boolean_t kill_socket = ISC_FALSE; + + REQUIRE(socketp != NULL); + sock = *socketp; + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(sock->type != isc_sockettype_fdwatch); + + LOCK(&sock->lock); + CONSISTENT(sock); + REQUIRE(sock->references > 0); + sock->references--; + + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "detach_socket %d %d %d", + sock->pending_recv, sock->pending_send, + sock->references); + + if (sock->references == 0 && sock->fd != INVALID_SOCKET) { + closesocket(sock->fd); + sock->fd = INVALID_SOCKET; + _set_state(sock, SOCK_CLOSED); + } + + maybe_free_socket(&sock, __LINE__); + + *socketp = NULL; +} + +isc_result_t +isc_socket_close(isc_socket_t *sock) { + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(sock->type != isc_sockettype_fdwatch); + + return (ISC_R_NOTIMPLEMENTED); +} + +/* + * Dequeue an item off the given socket's read queue, set the result code + * in the done event to the one provided, and send it to the task it was + * destined for. + * + * If the event to be sent is on a list, remove it before sending. If + * asked to, send and detach from the task as well. + * + * Caller must have the socket locked if the event is attached to the socket. + */ +static void +send_recvdone_event(isc_socket_t *sock, isc_socketevent_t **dev) { + isc_task_t *task; + + task = (*dev)->ev_sender; + (*dev)->ev_sender = sock; + + if (ISC_LINK_LINKED(*dev, ev_link)) + ISC_LIST_DEQUEUE(sock->recv_list, *dev, ev_link); + + if (((*dev)->attributes & ISC_SOCKEVENTATTR_ATTACHED) + == ISC_SOCKEVENTATTR_ATTACHED) + isc_task_sendanddetach(&task, (isc_event_t **)dev); + else + isc_task_send(task, (isc_event_t **)dev); + + CONSISTENT(sock); +} + +/* + * See comments for send_recvdone_event() above. + */ +static void +send_senddone_event(isc_socket_t *sock, isc_socketevent_t **dev) { + isc_task_t *task; + + INSIST(dev != NULL && *dev != NULL); + + task = (*dev)->ev_sender; + (*dev)->ev_sender = sock; + + if (ISC_LINK_LINKED(*dev, ev_link)) + ISC_LIST_DEQUEUE(sock->send_list, *dev, ev_link); + + if (((*dev)->attributes & ISC_SOCKEVENTATTR_ATTACHED) + == ISC_SOCKEVENTATTR_ATTACHED) + isc_task_sendanddetach(&task, (isc_event_t **)dev); + else + isc_task_send(task, (isc_event_t **)dev); + + CONSISTENT(sock); +} + +/* + * See comments for send_recvdone_event() above. + */ +static void +send_acceptdone_event(isc_socket_t *sock, isc_socket_newconnev_t **adev) { + isc_task_t *task; + + INSIST(adev != NULL && *adev != NULL); + + task = (*adev)->ev_sender; + (*adev)->ev_sender = sock; + + if (ISC_LINK_LINKED(*adev, ev_link)) + ISC_LIST_DEQUEUE(sock->accept_list, *adev, ev_link); + + isc_task_sendanddetach(&task, (isc_event_t **)adev); + + CONSISTENT(sock); +} + +/* + * See comments for send_recvdone_event() above. + */ +static void +send_connectdone_event(isc_socket_t *sock, isc_socket_connev_t **cdev) { + isc_task_t *task; + + INSIST(cdev != NULL && *cdev != NULL); + + task = (*cdev)->ev_sender; + (*cdev)->ev_sender = sock; + + sock->connect_ev = NULL; + + isc_task_sendanddetach(&task, (isc_event_t **)cdev); + + CONSISTENT(sock); +} + +/* + * On entry to this function, the event delivered is the internal + * readable event, and the first item on the accept_list should be + * the done event we want to send. If the list is empty, this is a no-op, + * so just close the new connection, unlock, and return. + * + * Note the socket is locked before entering here + */ +static void +internal_accept(isc_socket_t *sock, IoCompletionInfo *lpo, int accept_errno) { + isc_socket_newconnev_t *adev; + isc_result_t result = ISC_R_SUCCESS; + isc_socket_t *nsock; + struct sockaddr *localaddr; + int localaddr_len = sizeof(*localaddr); + struct sockaddr *remoteaddr; + int remoteaddr_len = sizeof(*remoteaddr); + + INSIST(VALID_SOCKET(sock)); + LOCK(&sock->lock); + CONSISTENT(sock); + + socket_log(__LINE__, sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTLOCK, + "internal_accept called"); + + INSIST(sock->listener); + + INSIST(sock->pending_iocp > 0); + sock->pending_iocp--; + INSIST(sock->pending_accept > 0); + sock->pending_accept--; + + adev = lpo->adev; + + /* + * If the event is no longer in the list we can just return. + */ + if (!acceptdone_is_active(sock, adev)) + goto done; + + nsock = adev->newsocket; + + /* + * Pull off the done event. + */ + ISC_LIST_UNLINK(sock->accept_list, adev, ev_link); + + /* + * Extract the addresses from the socket, copy them into the structure, + * and return the new socket. + */ + ISCGetAcceptExSockaddrs(lpo->acceptbuffer, 0, + sizeof(SOCKADDR_STORAGE) + 16, sizeof(SOCKADDR_STORAGE) + 16, + (LPSOCKADDR *)&localaddr, &localaddr_len, + (LPSOCKADDR *)&remoteaddr, &remoteaddr_len); + memcpy(&adev->address.type, remoteaddr, remoteaddr_len); + adev->address.length = remoteaddr_len; + nsock->address = adev->address; + nsock->pf = adev->address.type.sa.sa_family; + + socket_log(__LINE__, nsock, &nsock->address, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTLOCK, + "internal_accept parent %p", sock); + + result = make_nonblock(adev->newsocket->fd); + INSIST(result == ISC_R_SUCCESS); + + INSIST(setsockopt(nsock->fd, SOL_SOCKET, SO_UPDATE_ACCEPT_CONTEXT, + (char *)&sock->fd, sizeof(sock->fd)) == 0); + + /* + * Hook it up into the manager. + */ + nsock->bound = 1; + nsock->connected = 1; + _set_state(nsock, SOCK_OPEN); + + LOCK(&nsock->manager->lock); + ISC_LIST_APPEND(nsock->manager->socklist, nsock, link); + InterlockedIncrement(&nsock->manager->totalSockets); + UNLOCK(&nsock->manager->lock); + + socket_log(__LINE__, sock, &nsock->address, CREATION, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTEDCXN, + "accepted_connection new_socket %p fd %d", + nsock, nsock->fd); + + adev->result = result; + send_acceptdone_event(sock, &adev); + +done: + CONSISTENT(sock); + UNLOCK(&sock->lock); + + HeapFree(hHeapHandle, 0, lpo->acceptbuffer); + lpo->acceptbuffer = NULL; +} + +/* + * Called when a socket with a pending connect() finishes. + * Note that the socket is locked before entering. + */ +static void +internal_connect(isc_socket_t *sock, IoCompletionInfo *lpo, int connect_errno) { + isc_socket_connev_t *cdev; + char strbuf[ISC_STRERRORSIZE]; + + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + INSIST(sock->pending_iocp > 0); + sock->pending_iocp--; + INSIST(sock->pending_connect == 1); + sock->pending_connect = 0; + + /* + * Has this event been canceled? + */ + cdev = lpo->cdev; + if (!connectdone_is_active(sock, cdev)) { + sock->pending_connect = 0; + if (sock->fd != INVALID_SOCKET) { + closesocket(sock->fd); + sock->fd = INVALID_SOCKET; + _set_state(sock, SOCK_CLOSED); + } + CONSISTENT(sock); + UNLOCK(&sock->lock); + return; + } + + /* + * Check possible Windows network event error status here. + */ + if (connect_errno != 0) { + /* + * If the error is SOFT, just try again on this + * fd and pretend nothing strange happened. + */ + if (SOFT_ERROR(connect_errno) || + connect_errno == WSAEINPROGRESS) { + sock->pending_connect = 1; + CONSISTENT(sock); + UNLOCK(&sock->lock); + return; + } + + /* + * Translate other errors into ISC_R_* flavors. + */ + switch (connect_errno) { +#define ERROR_MATCH(a, b) case a: cdev->result = b; break; + ERROR_MATCH(WSAEACCES, ISC_R_NOPERM); + ERROR_MATCH(WSAEADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(WSAEAFNOSUPPORT, ISC_R_ADDRNOTAVAIL); + ERROR_MATCH(WSAECONNREFUSED, ISC_R_CONNREFUSED); + ERROR_MATCH(WSAEHOSTUNREACH, ISC_R_HOSTUNREACH); + ERROR_MATCH(WSAEHOSTDOWN, ISC_R_HOSTDOWN); + ERROR_MATCH(WSAENETUNREACH, ISC_R_NETUNREACH); + ERROR_MATCH(WSAENETDOWN, ISC_R_NETDOWN); + ERROR_MATCH(WSAENOBUFS, ISC_R_NORESOURCES); + ERROR_MATCH(WSAECONNRESET, ISC_R_CONNECTIONRESET); + ERROR_MATCH(WSAECONNABORTED, ISC_R_CONNECTIONRESET); + ERROR_MATCH(WSAETIMEDOUT, ISC_R_TIMEDOUT); +#undef ERROR_MATCH + default: + cdev->result = ISC_R_UNEXPECTED; + isc__strerror(connect_errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "internal_connect: connect() %s", + strbuf); + } + } else { + INSIST(setsockopt(sock->fd, SOL_SOCKET, + SO_UPDATE_CONNECT_CONTEXT, NULL, 0) == 0); + cdev->result = ISC_R_SUCCESS; + sock->connected = 1; + socket_log(__LINE__, sock, &sock->address, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTEDCXN, + "internal_connect: success"); + } + + send_connectdone_event(sock, &cdev); + + UNLOCK(&sock->lock); +} + +/* + * Loop through the socket, returning ISC_R_EOF for each done event pending. + */ +static void +send_recvdone_abort(isc_socket_t *sock, isc_result_t result) { + isc_socketevent_t *dev; + + while (!ISC_LIST_EMPTY(sock->recv_list)) { + dev = ISC_LIST_HEAD(sock->recv_list); + dev->result = result; + send_recvdone_event(sock, &dev); + } +} + +/* + * Take the data we received in our private buffer, and if any recv() calls on + * our list are satisfied, send the corresponding done event. + * + * If we need more data (there are still items on the recv_list after we consume all + * our data) then arrange for another system recv() call to fill our buffers. + */ +static void +internal_recv(isc_socket_t *sock, int nbytes) +{ + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + CONSISTENT(sock); + + socket_log(__LINE__, sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALRECV, + "internal_recv: %d bytes received", nbytes); + + /* + * If we got here, the I/O operation succeeded. However, we might still have removed this + * event from our notification list (or never placed it on it due to immediate completion.) + * Handle the reference counting here, and handle the cancellation event just after. + */ + INSIST(sock->pending_iocp > 0); + sock->pending_iocp--; + INSIST(sock->pending_recv > 0); + sock->pending_recv--; + + /* + * The only way we could have gotten here is that our I/O has successfully completed. + * Update our pointers, and move on. The only odd case here is that we might not + * have received enough data on a TCP stream to satisfy the minimum requirements. If + * this is the case, we will re-issue the recv() call for what we need. + * + * We do check for a recv() of 0 bytes on a TCP stream. This means the remote end + * has closed. + */ + if (nbytes == 0 && sock->type == isc_sockettype_tcp) { + send_recvdone_abort(sock, ISC_R_EOF); + maybe_free_socket(&sock, __LINE__); + return; + } + sock->recvbuf.remaining = nbytes; + sock->recvbuf.consume_position = sock->recvbuf.base; + completeio_recv(sock); + + /* + * If there are more receivers waiting for data, queue another receive + * here. + */ + queue_receive_request(sock); + + /* + * Unlock and/or destroy if we are the last thing this socket has left to do. + */ + maybe_free_socket(&sock, __LINE__); +} + +static void +internal_send(isc_socket_t *sock, isc_socketevent_t *dev, + struct msghdr *messagehdr, int nbytes, int send_errno, IoCompletionInfo *lpo) +{ + buflist_t *buffer; + + /* + * Find out what socket this is and lock it. + */ + INSIST(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + CONSISTENT(sock); + + socket_log(__LINE__, sock, NULL, IOEVENT, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_INTERNALSEND, + "internal_send: task got socket event %p", dev); + + buffer = ISC_LIST_HEAD(lpo->bufferlist); + while (buffer != NULL) { + ISC_LIST_DEQUEUE(lpo->bufferlist, buffer, link); + + socket_log(__LINE__, sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_ACCEPTLOCK, + "free_buffer %p %p", buffer, buffer->buf); + + HeapFree(hHeapHandle, 0, buffer->buf); + HeapFree(hHeapHandle, 0, buffer); + buffer = ISC_LIST_HEAD(lpo->bufferlist); + } + + INSIST(sock->pending_iocp > 0); + sock->pending_iocp--; + INSIST(sock->pending_send > 0); + sock->pending_send--; + + /* If the event is no longer in the list we can just return */ + if (!senddone_is_active(sock, dev)) + goto done; + + /* + * Set the error code and send things on its way. + */ + switch (completeio_send(sock, dev, messagehdr, nbytes, send_errno)) { + case DOIO_SOFT: + break; + case DOIO_HARD: + case DOIO_SUCCESS: + send_senddone_event(sock, &dev); + break; + } + + done: + maybe_free_socket(&sock, __LINE__); +} + +/* + * These return if the done event passed in is on the list (or for connect, is + * the one we're waiting for. Using these ensures we will not double-send an + * event. + */ +static isc_boolean_t +senddone_is_active(isc_socket_t *sock, isc_socketevent_t *dev) +{ + isc_socketevent_t *ldev; + + ldev = ISC_LIST_HEAD(sock->send_list); + while (ldev != NULL && ldev != dev) + ldev = ISC_LIST_NEXT(ldev, ev_link); + + return (ldev == NULL ? ISC_FALSE : ISC_TRUE); +} + +static isc_boolean_t +acceptdone_is_active(isc_socket_t *sock, isc_socket_newconnev_t *dev) +{ + isc_socket_newconnev_t *ldev; + + ldev = ISC_LIST_HEAD(sock->accept_list); + while (ldev != NULL && ldev != dev) + ldev = ISC_LIST_NEXT(ldev, ev_link); + + return (ldev == NULL ? ISC_FALSE : ISC_TRUE); +} + +static isc_boolean_t +connectdone_is_active(isc_socket_t *sock, isc_socket_connev_t *dev) +{ + return (sock->connect_ev == dev ? ISC_TRUE : ISC_FALSE); +} + +// +// The Windows network stack seems to have two very distinct paths depending +// on what is installed. Specifically, if something is looking at network +// connections (like an anti-virus or anti-malware application, such as +// McAfee products) Windows may return additional error conditions which +// were not previously returned. +// +// One specific one is when a TCP SYN scan is used. In this situation, +// Windows responds with the SYN-ACK, but the scanner never responds with +// the 3rd packet, the ACK. Windows consiers this a partially open connection. +// Most Unix networking stacks, and Windows without McAfee installed, will +// not return this to the caller. However, with this product installed, +// Windows returns this as a failed status on the Accept() call. Here, we +// will just re-issue the ISCAcceptEx() call as if nothing had happened. +// +// This code should only be called when the listening socket has received +// such an error. Additionally, the "parent" socket must be locked. +// Additionally, the lpo argument is re-used here, and must not be freed +// by the caller. +// +static isc_result_t +restart_accept(isc_socket_t *parent, IoCompletionInfo *lpo) +{ + isc_socket_t *nsock = lpo->adev->newsocket; + SOCKET new_fd; + + /* + * AcceptEx() requires we pass in a socket. Note that we carefully + * do not close the previous socket in case of an error message returned by + * our new socket() call. If we return an error here, our caller will + * clean up. + */ + new_fd = socket(parent->pf, SOCK_STREAM, IPPROTO_TCP); + if (nsock->fd == INVALID_SOCKET) { + return (ISC_R_FAILURE); // parent will ask windows for error message + } + closesocket(nsock->fd); + nsock->fd = new_fd; + + memset(&lpo->overlapped, 0, sizeof(lpo->overlapped)); + + ISCAcceptEx(parent->fd, + nsock->fd, /* Accepted Socket */ + lpo->acceptbuffer, /* Buffer for initial Recv */ + 0, /* Length of Buffer */ + sizeof(SOCKADDR_STORAGE) + 16, /* Local address length + 16 */ + sizeof(SOCKADDR_STORAGE) + 16, /* Remote address lengh + 16 */ + (LPDWORD)&lpo->received_bytes, /* Bytes Recved */ + (LPOVERLAPPED)lpo /* Overlapped structure */ + ); + + InterlockedDecrement(&nsock->manager->iocp_total); + iocompletionport_update(nsock); + + return (ISC_R_SUCCESS); +} + +/* + * This is the I/O Completion Port Worker Function. It loops forever + * waiting for I/O to complete and then forwards them for further + * processing. There are a number of these in separate threads. + */ +static isc_threadresult_t WINAPI +SocketIoThread(LPVOID ThreadContext) { + isc_socketmgr_t *manager = ThreadContext; + BOOL bSuccess = FALSE; + DWORD nbytes; + IoCompletionInfo *lpo = NULL; + isc_socket_t *sock = NULL; + int request; + struct msghdr *messagehdr = NULL; + int errval; + char strbuf[ISC_STRERRORSIZE]; + int errstatus; + + REQUIRE(VALID_MANAGER(manager)); + + /* + * Set the thread priority high enough so I/O will + * preempt normal recv packet processing, but not + * higher than the timer sync thread. + */ + if (!SetThreadPriority(GetCurrentThread(), + THREAD_PRIORITY_ABOVE_NORMAL)) { + errval = GetLastError(); + isc__strerror(errval, strbuf, sizeof(strbuf)); + FATAL_ERROR(__FILE__, __LINE__, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_FAILED, + "Can't set thread priority: %s"), + strbuf); + } + + /* + * Loop forever waiting on I/O Completions and then processing them + */ + while (TRUE) { + wait_again: + bSuccess = GetQueuedCompletionStatus(manager->hIoCompletionPort, + &nbytes, (LPDWORD)&sock, + (LPWSAOVERLAPPED *)&lpo, + INFINITE); + if (lpo == NULL) /* Received request to exit */ + break; + + REQUIRE(VALID_SOCKET(sock)); + + request = lpo->request_type; + + errstatus = 0; + if (!bSuccess) { + isc_result_t isc_result; + + /* + * Did the I/O operation complete? + */ + errstatus = GetLastError(); + isc_result = isc__errno2resultx(errstatus, __FILE__, __LINE__); + + LOCK(&sock->lock); + CONSISTENT(sock); + switch (request) { + case SOCKET_RECV: + INSIST(sock->pending_iocp > 0); + sock->pending_iocp--; + INSIST(sock->pending_recv > 0); + sock->pending_recv--; + if (!sock->connected && + ((errstatus == ERROR_HOST_UNREACHABLE) || + (errstatus == WSAENETRESET) || + (errstatus == WSAECONNRESET))) { + /* ignore soft errors */ + queue_receive_request(sock); + break; + } + send_recvdone_abort(sock, isc_result); + if (isc_result == ISC_R_UNEXPECTED) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "SOCKET_RECV: Windows error code: %d, returning ISC error %d", + errstatus, isc_result); + } + break; + + case SOCKET_SEND: + INSIST(sock->pending_iocp > 0); + sock->pending_iocp--; + INSIST(sock->pending_send > 0); + sock->pending_send--; + if (senddone_is_active(sock, lpo->dev)) { + lpo->dev->result = isc_result; + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "canceled_send"); + send_senddone_event(sock, &lpo->dev); + } + break; + + case SOCKET_ACCEPT: + INSIST(sock->pending_iocp > 0); + INSIST(sock->pending_accept > 0); + + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "Accept: errstatus=%d isc_result=%d", errstatus, isc_result); + + if (acceptdone_is_active(sock, lpo->adev)) { + if (restart_accept(sock, lpo) == ISC_R_SUCCESS) { + UNLOCK(&sock->lock); + goto wait_again; + } else { + errstatus = GetLastError(); + isc_result = isc__errno2resultx(errstatus, __FILE__, __LINE__); + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "restart_accept() failed: errstatus=%d isc_result=%d", + errstatus, isc_result); + } + } + + sock->pending_iocp--; + sock->pending_accept--; + if (acceptdone_is_active(sock, lpo->adev)) { + closesocket(lpo->adev->newsocket->fd); + lpo->adev->newsocket->fd = INVALID_SOCKET; + lpo->adev->newsocket->references--; + free_socket(&lpo->adev->newsocket, __LINE__); + lpo->adev->result = isc_result; + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "canceled_accept"); + send_acceptdone_event(sock, &lpo->adev); + } + break; + + case SOCKET_CONNECT: + INSIST(sock->pending_iocp > 0); + sock->pending_iocp--; + INSIST(sock->pending_connect == 1); + sock->pending_connect = 0; + if (connectdone_is_active(sock, lpo->cdev)) { + lpo->cdev->result = isc_result; + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "canceled_connect"); + send_connectdone_event(sock, &lpo->cdev); + } + break; + } + maybe_free_socket(&sock, __LINE__); + + if (lpo != NULL) + HeapFree(hHeapHandle, 0, lpo); + continue; + } + + messagehdr = &lpo->messagehdr; + + switch (request) { + case SOCKET_RECV: + internal_recv(sock, nbytes); + break; + case SOCKET_SEND: + internal_send(sock, lpo->dev, messagehdr, nbytes, errstatus, lpo); + break; + case SOCKET_ACCEPT: + internal_accept(sock, lpo, errstatus); + break; + case SOCKET_CONNECT: + internal_connect(sock, lpo, errstatus); + break; + } + + if (lpo != NULL) + HeapFree(hHeapHandle, 0, lpo); + } + + /* + * Exit Completion Port Thread + */ + manager_log(manager, TRACE, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_EXITING, "SocketIoThread exiting")); + return ((isc_threadresult_t)0); +} + +/* + * Create a new socket manager. + */ +isc_result_t +isc__socketmgr_create(isc_mem_t *mctx, isc_socketmgr_t **managerp) { + return (isc_socketmgr_create2(mctx, managerp, 0)); +} + +isc_result_t +isc__socketmgr_create2(isc_mem_t *mctx, isc_socketmgr_t **managerp, + unsigned int maxsocks) +{ + isc_socketmgr_t *manager; + isc_result_t result; + + REQUIRE(managerp != NULL && *managerp == NULL); + + if (maxsocks != 0) + return (ISC_R_NOTIMPLEMENTED); + + manager = isc_mem_get(mctx, sizeof(*manager)); + if (manager == NULL) + return (ISC_R_NOMEMORY); + + InitSockets(); + + manager->magic = SOCKET_MANAGER_MAGIC; + manager->mctx = NULL; + manager->stats = NULL; + ISC_LIST_INIT(manager->socklist); + result = isc_mutex_init(&manager->lock); + if (result != ISC_R_SUCCESS) { + isc_mem_put(mctx, manager, sizeof(*manager)); + return (result); + } + if (isc_condition_init(&manager->shutdown_ok) != ISC_R_SUCCESS) { + DESTROYLOCK(&manager->lock); + isc_mem_put(mctx, manager, sizeof(*manager)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_condition_init() %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + return (ISC_R_UNEXPECTED); + } + + isc_mem_attach(mctx, &manager->mctx); + + iocompletionport_init(manager); /* Create the Completion Ports */ + + manager->bShutdown = ISC_FALSE; + manager->totalSockets = 0; + manager->iocp_total = 0; + + *managerp = manager; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__socketmgr_getmaxsockets(isc_socketmgr_t *manager, unsigned int *nsockp) { + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(nsockp != NULL); + + return (ISC_R_NOTIMPLEMENTED); +} + +void +isc__socketmgr_setstats(isc_socketmgr_t *manager, isc_stats_t *stats) { + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(ISC_LIST_EMPTY(manager->socklist)); + REQUIRE(manager->stats == NULL); + REQUIRE(isc_stats_ncounters(stats) == isc_sockstatscounter_max); + + isc_stats_attach(stats, &manager->stats); +} + +void +isc__socketmgr_destroy(isc_socketmgr_t **managerp) { + isc_socketmgr_t *manager; + int i; + isc_mem_t *mctx; + + /* + * Destroy a socket manager. + */ + + REQUIRE(managerp != NULL); + manager = *managerp; + REQUIRE(VALID_MANAGER(manager)); + + LOCK(&manager->lock); + + /* + * Wait for all sockets to be destroyed. + */ + while (!ISC_LIST_EMPTY(manager->socklist)) { + manager_log(manager, CREATION, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_SOCKETSREMAIN, + "sockets exist")); + WAIT(&manager->shutdown_ok, &manager->lock); + } + + UNLOCK(&manager->lock); + + /* + * Here, we need to had some wait code for the completion port + * thread. + */ + signal_iocompletionport_exit(manager); + manager->bShutdown = ISC_TRUE; + + /* + * Wait for threads to exit. + */ + for (i = 0; i < manager->maxIOCPThreads; i++) { + if (isc_thread_join((isc_thread_t) manager->hIOCPThreads[i], + NULL) != ISC_R_SUCCESS) + UNEXPECTED_ERROR(__FILE__, __LINE__, + "isc_thread_join() for Completion Port %s", + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + } + /* + * Clean up. + */ + + CloseHandle(manager->hIoCompletionPort); + + (void)isc_condition_destroy(&manager->shutdown_ok); + + DESTROYLOCK(&manager->lock); + if (manager->stats != NULL) + isc_stats_detach(&manager->stats); + manager->magic = 0; + mctx= manager->mctx; + isc_mem_put(mctx, manager, sizeof(*manager)); + + isc_mem_detach(&mctx); + + *managerp = NULL; +} + +static void +queue_receive_event(isc_socket_t *sock, isc_task_t *task, isc_socketevent_t *dev) +{ + isc_task_t *ntask = NULL; + + isc_task_attach(task, &ntask); + dev->attributes |= ISC_SOCKEVENTATTR_ATTACHED; + + /* + * Enqueue the request. + */ + INSIST(!ISC_LINK_LINKED(dev, ev_link)); + ISC_LIST_ENQUEUE(sock->recv_list, dev, ev_link); + + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "queue_receive_event: event %p -> task %p", + dev, ntask); +} + +/* + * Check the pending receive queue, and if we have data pending, give it to this + * caller. If we have none, queue an I/O request. If this caller is not the first + * on the list, then we will just queue this event and return. + * + * Caller must have the socket locked. + */ +static isc_result_t +socket_recv(isc_socket_t *sock, isc_socketevent_t *dev, isc_task_t *task, + unsigned int flags) +{ + int cc = 0; + isc_task_t *ntask = NULL; + isc_result_t result = ISC_R_SUCCESS; + int recv_errno = 0; + + dev->ev_sender = task; + + if (sock->fd == INVALID_SOCKET) + return (ISC_R_EOF); + + /* + * Queue our event on the list of things to do. Call our function to + * attempt to fill buffers as much as possible, and return done events. + * We are going to lie about our handling of the ISC_SOCKFLAG_IMMEDIATE + * here and tell our caller that we could not satisfy it immediately. + */ + queue_receive_event(sock, task, dev); + if ((flags & ISC_SOCKFLAG_IMMEDIATE) != 0) + result = ISC_R_INPROGRESS; + + completeio_recv(sock); + + /* + * If there are more receivers waiting for data, queue another receive + * here. If the + */ + queue_receive_request(sock); + + return (result); +} + +isc_result_t +isc__socket_recvv(isc_socket_t *sock, isc_bufferlist_t *buflist, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + unsigned int iocount; + isc_buffer_t *buffer; + isc_result_t ret; + + REQUIRE(VALID_SOCKET(sock)); + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * Make sure that the socket is not closed. XXXMLG change error here? + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + REQUIRE(buflist != NULL); + REQUIRE(!ISC_LIST_EMPTY(*buflist)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + iocount = isc_bufferlist_availablecount(buflist); + REQUIRE(iocount > 0); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_RECVDONE, action, arg); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + + /* + * UDP sockets are always partial read + */ + if (sock->type == isc_sockettype_udp) + dev->minimum = 1; + else { + if (minimum == 0) + dev->minimum = iocount; + else + dev->minimum = minimum; + } + + /* + * Move each buffer from the passed in list to our internal one. + */ + buffer = ISC_LIST_HEAD(*buflist); + while (buffer != NULL) { + ISC_LIST_DEQUEUE(*buflist, buffer, link); + ISC_LIST_ENQUEUE(dev->bufferlist, buffer, link); + buffer = ISC_LIST_HEAD(*buflist); + } + + ret = socket_recv(sock, dev, task, 0); + + UNLOCK(&sock->lock); + return (ret); +} + +isc_result_t +isc__socket_recv(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_taskaction_t action, const void *arg) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + isc_result_t ret; + + REQUIRE(VALID_SOCKET(sock)); + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_RECVDONE, action, arg); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + + ret = isc_socket_recv2(sock, region, minimum, task, dev, 0); + UNLOCK(&sock->lock); + return (ret); +} + +isc_result_t +isc__socket_recv2(isc_socket_t *sock, isc_region_t *region, + unsigned int minimum, isc_task_t *task, + isc_socketevent_t *event, unsigned int flags) +{ + isc_result_t ret; + + REQUIRE(VALID_SOCKET(sock)); + LOCK(&sock->lock); + CONSISTENT(sock); + + event->result = ISC_R_UNEXPECTED; + event->ev_sender = sock; + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + ISC_LIST_INIT(event->bufferlist); + event->region = *region; + event->n = 0; + event->offset = 0; + event->attributes = 0; + + /* + * UDP sockets are always partial read. + */ + if (sock->type == isc_sockettype_udp) + event->minimum = 1; + else { + if (minimum == 0) + event->minimum = region->length; + else + event->minimum = minimum; + } + + ret = socket_recv(sock, event, task, flags); + UNLOCK(&sock->lock); + return (ret); +} + +/* + * Caller must have the socket locked. + */ +static isc_result_t +socket_send(isc_socket_t *sock, isc_socketevent_t *dev, isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + unsigned int flags) +{ + int io_state; + int send_errno = 0; + int cc = 0; + isc_task_t *ntask = NULL; + isc_result_t result = ISC_R_SUCCESS; + + dev->ev_sender = task; + + set_dev_address(address, sock, dev); + if (pktinfo != NULL) { + socket_log(__LINE__, sock, NULL, TRACE, isc_msgcat, ISC_MSGSET_SOCKET, + ISC_MSG_PKTINFOPROVIDED, + "pktinfo structure provided, ifindex %u (set to 0)", + pktinfo->ipi6_ifindex); + + dev->attributes |= ISC_SOCKEVENTATTR_PKTINFO; + dev->pktinfo = *pktinfo; + /* + * Set the pktinfo index to 0 here, to let the kernel decide + * what interface it should send on. + */ + dev->pktinfo.ipi6_ifindex = 0; + } + + io_state = startio_send(sock, dev, &cc, &send_errno); + switch (io_state) { + case DOIO_PENDING: /* I/O started. Nothing more to do */ + case DOIO_SOFT: + /* + * We couldn't send all or part of the request right now, so + * queue it unless ISC_SOCKFLAG_NORETRY is set. + */ + if ((flags & ISC_SOCKFLAG_NORETRY) == 0) { + isc_task_attach(task, &ntask); + dev->attributes |= ISC_SOCKEVENTATTR_ATTACHED; + + /* + * Enqueue the request. + */ + INSIST(!ISC_LINK_LINKED(dev, ev_link)); + ISC_LIST_ENQUEUE(sock->send_list, dev, ev_link); + + socket_log(__LINE__, sock, NULL, EVENT, NULL, 0, 0, + "socket_send: event %p -> task %p", + dev, ntask); + + if ((flags & ISC_SOCKFLAG_IMMEDIATE) != 0) + result = ISC_R_INPROGRESS; + break; + } + + case DOIO_SUCCESS: + break; + } + + return (result); +} + +isc_result_t +isc__socket_send(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + /* + * REQUIRE() checking is performed in isc_socket_sendto(). + */ + return (isc_socket_sendto(sock, region, task, action, arg, NULL, + NULL)); +} + +isc_result_t +isc__socket_sendto(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + isc_result_t ret; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(sock->type != isc_sockettype_fdwatch); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + REQUIRE(region != NULL); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + INSIST(sock->bound); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_SENDDONE, action, arg); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + dev->region = *region; + + ret = socket_send(sock, dev, task, address, pktinfo, 0); + UNLOCK(&sock->lock); + return (ret); +} + +isc_result_t +isc__socket_sendv(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + return (isc_socket_sendtov(sock, buflist, task, action, arg, NULL, + NULL)); +} + +isc_result_t +isc__socket_sendtov(isc_socket_t *sock, isc_bufferlist_t *buflist, + isc_task_t *task, isc_taskaction_t action, const void *arg, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo) +{ + isc_socketevent_t *dev; + isc_socketmgr_t *manager; + unsigned int iocount; + isc_buffer_t *buffer; + isc_result_t ret; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + REQUIRE(buflist != NULL); + REQUIRE(!ISC_LIST_EMPTY(*buflist)); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + iocount = isc_bufferlist_usedcount(buflist); + REQUIRE(iocount > 0); + + dev = allocate_socketevent(sock, ISC_SOCKEVENT_SENDDONE, action, arg); + if (dev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + + /* + * Move each buffer from the passed in list to our internal one. + */ + buffer = ISC_LIST_HEAD(*buflist); + while (buffer != NULL) { + ISC_LIST_DEQUEUE(*buflist, buffer, link); + ISC_LIST_ENQUEUE(dev->bufferlist, buffer, link); + buffer = ISC_LIST_HEAD(*buflist); + } + + ret = socket_send(sock, dev, task, address, pktinfo, 0); + UNLOCK(&sock->lock); + return (ret); +} + +isc_result_t +isc__socket_sendto2(isc_socket_t *sock, isc_region_t *region, + isc_task_t *task, + isc_sockaddr_t *address, struct in6_pktinfo *pktinfo, + isc_socketevent_t *event, unsigned int flags) +{ + isc_result_t ret; + + REQUIRE(VALID_SOCKET(sock)); + LOCK(&sock->lock); + CONSISTENT(sock); + + REQUIRE((flags & ~(ISC_SOCKFLAG_IMMEDIATE|ISC_SOCKFLAG_NORETRY)) == 0); + if ((flags & ISC_SOCKFLAG_NORETRY) != 0) + REQUIRE(sock->type == isc_sockettype_udp); + event->ev_sender = sock; + event->result = ISC_R_UNEXPECTED; + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + ISC_LIST_INIT(event->bufferlist); + event->region = *region; + event->n = 0; + event->offset = 0; + event->attributes = 0; + + ret = socket_send(sock, event, task, address, pktinfo, flags); + UNLOCK(&sock->lock); + return (ret); +} + +isc_result_t +isc__socket_bind(isc_socket_t *sock, isc_sockaddr_t *sockaddr, + unsigned int options) { + int bind_errno; + char strbuf[ISC_STRERRORSIZE]; + int on = 1; + + REQUIRE(VALID_SOCKET(sock)); + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + INSIST(!sock->bound); + INSIST(!sock->dupped); + + if (sock->pf != sockaddr->type.sa.sa_family) { + UNLOCK(&sock->lock); + return (ISC_R_FAMILYMISMATCH); + } + /* + * Only set SO_REUSEADDR when we want a specific port. + */ + if ((options & ISC_SOCKET_REUSEADDRESS) != 0 && + isc_sockaddr_getport(sockaddr) != (in_port_t)0 && + setsockopt(sock->fd, SOL_SOCKET, SO_REUSEADDR, (char *)&on, + sizeof(on)) < 0) { + UNEXPECTED_ERROR(__FILE__, __LINE__, + "setsockopt(%d) %s", sock->fd, + isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, + ISC_MSG_FAILED, "failed")); + /* Press on... */ + } + if (bind(sock->fd, &sockaddr->type.sa, sockaddr->length) < 0) { + bind_errno = WSAGetLastError(); + UNLOCK(&sock->lock); + switch (bind_errno) { + case WSAEACCES: + return (ISC_R_NOPERM); + case WSAEADDRNOTAVAIL: + return (ISC_R_ADDRNOTAVAIL); + case WSAEADDRINUSE: + return (ISC_R_ADDRINUSE); + case WSAEINVAL: + return (ISC_R_BOUND); + default: + isc__strerror(bind_errno, strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "bind: %s", + strbuf); + return (ISC_R_UNEXPECTED); + } + } + + socket_log(__LINE__, sock, sockaddr, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_BOUND, "bound"); + sock->bound = 1; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__socket_filter(isc_socket_t *sock, const char *filter) { + UNUSED(sock); + UNUSED(filter); + + REQUIRE(VALID_SOCKET(sock)); + return (ISC_R_NOTIMPLEMENTED); +} + +/* + * Set up to listen on a given socket. We do this by creating an internal + * event that will be dispatched when the socket has read activity. The + * watcher will send the internal event to the task when there is a new + * connection. + * + * Unlike in read, we don't preallocate a done event here. Every time there + * is a new connection we'll have to allocate a new one anyway, so we might + * as well keep things simple rather than having to track them. + */ +isc_result_t +isc__socket_listen(isc_socket_t *sock, unsigned int backlog) { + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + REQUIRE(!sock->listener); + REQUIRE(sock->bound); + REQUIRE(sock->type == isc_sockettype_tcp); + + if (backlog == 0) + backlog = SOMAXCONN; + + if (listen(sock->fd, (int)backlog) < 0) { + UNLOCK(&sock->lock); + isc__strerror(WSAGetLastError(), strbuf, sizeof(strbuf)); + + UNEXPECTED_ERROR(__FILE__, __LINE__, "listen: %s", strbuf); + + return (ISC_R_UNEXPECTED); + } + + socket_log(__LINE__, sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_BOUND, "listening"); + sock->listener = 1; + _set_state(sock, SOCK_LISTEN); + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +/* + * This should try to do aggressive accept() XXXMLG + */ +isc_result_t +isc__socket_accept(isc_socket_t *sock, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + isc_socket_newconnev_t *adev; + isc_socketmgr_t *manager; + isc_task_t *ntask = NULL; + isc_socket_t *nsock; + isc_result_t result; + IoCompletionInfo *lpo; + + REQUIRE(VALID_SOCKET(sock)); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + REQUIRE(sock->listener); + + /* + * Sender field is overloaded here with the task we will be sending + * this event to. Just before the actual event is delivered the + * actual ev_sender will be touched up to be the socket. + */ + adev = (isc_socket_newconnev_t *) + isc_event_allocate(manager->mctx, task, ISC_SOCKEVENT_NEWCONN, + action, arg, sizeof(*adev)); + if (adev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + ISC_LINK_INIT(adev, ev_link); + + result = allocate_socket(manager, sock->type, &nsock); + if (result != ISC_R_SUCCESS) { + isc_event_free((isc_event_t **)&adev); + UNLOCK(&sock->lock); + return (result); + } + + /* + * AcceptEx() requires we pass in a socket. + */ + nsock->fd = socket(sock->pf, SOCK_STREAM, IPPROTO_TCP); + if (nsock->fd == INVALID_SOCKET) { + free_socket(&nsock, __LINE__); + isc_event_free((isc_event_t **)&adev); + UNLOCK(&sock->lock); + return (ISC_R_FAILURE); // XXXMLG need real error message + } + + /* + * Attach to socket and to task. + */ + isc_task_attach(task, &ntask); + if (isc_task_exiting(ntask)) { + free_socket(&nsock, __LINE__); + isc_task_detach(&ntask); + isc_event_free(ISC_EVENT_PTR(&adev)); + UNLOCK(&sock->lock); + return (ISC_R_SHUTTINGDOWN); + } + nsock->references++; + + adev->ev_sender = ntask; + adev->newsocket = nsock; + _set_state(nsock, SOCK_ACCEPT); + + /* + * Queue io completion for an accept(). + */ + lpo = (IoCompletionInfo *)HeapAlloc(hHeapHandle, + HEAP_ZERO_MEMORY, + sizeof(IoCompletionInfo)); + RUNTIME_CHECK(lpo != NULL); + lpo->acceptbuffer = (void *)HeapAlloc(hHeapHandle, HEAP_ZERO_MEMORY, + (sizeof(SOCKADDR_STORAGE) + 16) * 2); + RUNTIME_CHECK(lpo->acceptbuffer != NULL); + + lpo->adev = adev; + lpo->request_type = SOCKET_ACCEPT; + + ISCAcceptEx(sock->fd, + nsock->fd, /* Accepted Socket */ + lpo->acceptbuffer, /* Buffer for initial Recv */ + 0, /* Length of Buffer */ + sizeof(SOCKADDR_STORAGE) + 16, /* Local address length + 16 */ + sizeof(SOCKADDR_STORAGE) + 16, /* Remote address lengh + 16 */ + (LPDWORD)&lpo->received_bytes, /* Bytes Recved */ + (LPOVERLAPPED)lpo /* Overlapped structure */ + ); + iocompletionport_update(nsock); + + socket_log(__LINE__, sock, NULL, TRACE, + isc_msgcat, ISC_MSGSET_SOCKET, ISC_MSG_BOUND, + "accepting for nsock %p fd %d", nsock, nsock->fd); + + /* + * Enqueue the event + */ + ISC_LIST_ENQUEUE(sock->accept_list, adev, ev_link); + sock->pending_accept++; + sock->pending_iocp++; + + UNLOCK(&sock->lock); + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__socket_connect(isc_socket_t *sock, isc_sockaddr_t *addr, + isc_task_t *task, isc_taskaction_t action, const void *arg) +{ + char strbuf[ISC_STRERRORSIZE]; + isc_socket_connev_t *cdev; + isc_task_t *ntask = NULL; + isc_socketmgr_t *manager; + IoCompletionInfo *lpo; + int bind_errno; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addr != NULL); + REQUIRE(task != NULL); + REQUIRE(action != NULL); + + manager = sock->manager; + REQUIRE(VALID_MANAGER(manager)); + REQUIRE(addr != NULL); + + if (isc_sockaddr_ismulticast(addr)) + return (ISC_R_MULTICAST); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + /* + * Windows sockets won't connect unless the socket is bound. + */ + if (!sock->bound) { + isc_sockaddr_t any; + + isc_sockaddr_anyofpf(&any, isc_sockaddr_pf(addr)); + if (bind(sock->fd, &any.type.sa, any.length) < 0) { + bind_errno = WSAGetLastError(); + UNLOCK(&sock->lock); + switch (bind_errno) { + case WSAEACCES: + return (ISC_R_NOPERM); + case WSAEADDRNOTAVAIL: + return (ISC_R_ADDRNOTAVAIL); + case WSAEADDRINUSE: + return (ISC_R_ADDRINUSE); + case WSAEINVAL: + return (ISC_R_BOUND); + default: + isc__strerror(bind_errno, strbuf, + sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, + "bind: %s", strbuf); + return (ISC_R_UNEXPECTED); + } + } + sock->bound = 1; + } + + REQUIRE(!sock->pending_connect); + + cdev = (isc_socket_connev_t *)isc_event_allocate(manager->mctx, sock, + ISC_SOCKEVENT_CONNECT, + action, arg, + sizeof(*cdev)); + if (cdev == NULL) { + UNLOCK(&sock->lock); + return (ISC_R_NOMEMORY); + } + ISC_LINK_INIT(cdev, ev_link); + + if (sock->type == isc_sockettype_tcp) { + /* + * Queue io completion for an accept(). + */ + lpo = (IoCompletionInfo *)HeapAlloc(hHeapHandle, + HEAP_ZERO_MEMORY, + sizeof(IoCompletionInfo)); + lpo->cdev = cdev; + lpo->request_type = SOCKET_CONNECT; + + sock->address = *addr; + ISCConnectEx(sock->fd, &addr->type.sa, addr->length, + NULL, 0, NULL, (LPOVERLAPPED)lpo); + + /* + * Attach to task. + */ + isc_task_attach(task, &ntask); + cdev->ev_sender = ntask; + + sock->pending_connect = 1; + _set_state(sock, SOCK_CONNECT); + + /* + * Enqueue the request. + */ + sock->connect_ev = cdev; + sock->pending_iocp++; + } else { + WSAConnect(sock->fd, &addr->type.sa, addr->length, NULL, NULL, NULL, NULL); + cdev->result = ISC_R_SUCCESS; + isc_task_send(task, (isc_event_t **)&cdev); + } + CONSISTENT(sock); + UNLOCK(&sock->lock); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc__socket_getpeername(isc_socket_t *sock, isc_sockaddr_t *addressp) { + isc_result_t result; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addressp != NULL); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + if (sock->connected) { + *addressp = sock->address; + result = ISC_R_SUCCESS; + } else { + result = ISC_R_NOTCONNECTED; + } + + UNLOCK(&sock->lock); + + return (result); +} + +isc_result_t +isc__socket_getsockname(isc_socket_t *sock, isc_sockaddr_t *addressp) { + ISC_SOCKADDR_LEN_T len; + isc_result_t result; + char strbuf[ISC_STRERRORSIZE]; + + REQUIRE(VALID_SOCKET(sock)); + REQUIRE(addressp != NULL); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + if (!sock->bound) { + result = ISC_R_NOTBOUND; + goto out; + } + + result = ISC_R_SUCCESS; + + len = sizeof(addressp->type); + if (getsockname(sock->fd, &addressp->type.sa, (void *)&len) < 0) { + isc__strerror(WSAGetLastError(), strbuf, sizeof(strbuf)); + UNEXPECTED_ERROR(__FILE__, __LINE__, "getsockname: %s", + strbuf); + result = ISC_R_UNEXPECTED; + goto out; + } + addressp->length = (unsigned int)len; + + out: + UNLOCK(&sock->lock); + + return (result); +} + +/* + * Run through the list of events on this socket, and cancel the ones + * queued for task "task" of type "how". "how" is a bitmask. + */ +void +isc__socket_cancel(isc_socket_t *sock, isc_task_t *task, unsigned int how) { + + REQUIRE(VALID_SOCKET(sock)); + + /* + * Quick exit if there is nothing to do. Don't even bother locking + * in this case. + */ + if (how == 0) + return; + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return; + } + + /* + * All of these do the same thing, more or less. + * Each will: + * o If the internal event is marked as "posted" try to + * remove it from the task's queue. If this fails, mark it + * as canceled instead, and let the task clean it up later. + * o For each I/O request for that task of that type, post + * its done event with status of "ISC_R_CANCELED". + * o Reset any state needed. + */ + + if ((how & ISC_SOCKCANCEL_RECV) == ISC_SOCKCANCEL_RECV) { + isc_socketevent_t *dev; + isc_socketevent_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->recv_list); + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + if ((task == NULL) || (task == current_task)) { + dev->result = ISC_R_CANCELED; + send_recvdone_event(sock, &dev); + } + dev = next; + } + } + how &= ~ISC_SOCKCANCEL_RECV; + + if ((how & ISC_SOCKCANCEL_SEND) == ISC_SOCKCANCEL_SEND) { + isc_socketevent_t *dev; + isc_socketevent_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->send_list); + + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + if ((task == NULL) || (task == current_task)) { + dev->result = ISC_R_CANCELED; + send_senddone_event(sock, &dev); + } + dev = next; + } + } + how &= ~ISC_SOCKCANCEL_SEND; + + if (((how & ISC_SOCKCANCEL_ACCEPT) == ISC_SOCKCANCEL_ACCEPT) + && !ISC_LIST_EMPTY(sock->accept_list)) { + isc_socket_newconnev_t *dev; + isc_socket_newconnev_t *next; + isc_task_t *current_task; + + dev = ISC_LIST_HEAD(sock->accept_list); + while (dev != NULL) { + current_task = dev->ev_sender; + next = ISC_LIST_NEXT(dev, ev_link); + + if ((task == NULL) || (task == current_task)) { + + dev->newsocket->references--; + closesocket(dev->newsocket->fd); + dev->newsocket->fd = INVALID_SOCKET; + free_socket(&dev->newsocket, __LINE__); + + dev->result = ISC_R_CANCELED; + send_acceptdone_event(sock, &dev); + } + + dev = next; + } + } + how &= ~ISC_SOCKCANCEL_ACCEPT; + + /* + * Connecting is not a list. + */ + if (((how & ISC_SOCKCANCEL_CONNECT) == ISC_SOCKCANCEL_CONNECT) + && sock->connect_ev != NULL) { + isc_socket_connev_t *dev; + isc_task_t *current_task; + + INSIST(sock->pending_connect); + + dev = sock->connect_ev; + current_task = dev->ev_sender; + + if ((task == NULL) || (task == current_task)) { + closesocket(sock->fd); + sock->fd = INVALID_SOCKET; + _set_state(sock, SOCK_CLOSED); + + sock->connect_ev = NULL; + dev->result = ISC_R_CANCELED; + send_connectdone_event(sock, &dev); + } + } + how &= ~ISC_SOCKCANCEL_CONNECT; + + maybe_free_socket(&sock, __LINE__); +} + +isc_sockettype_t +isc__socket_gettype(isc_socket_t *sock) { + isc_sockettype_t type; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_R_CONNREFUSED); + } + + type = sock->type; + UNLOCK(&sock->lock); + return (type); +} + +isc_boolean_t +isc__socket_isbound(isc_socket_t *sock) { + isc_boolean_t val; + + REQUIRE(VALID_SOCKET(sock)); + + LOCK(&sock->lock); + CONSISTENT(sock); + + /* + * make sure that the socket's not closed + */ + if (sock->fd == INVALID_SOCKET) { + UNLOCK(&sock->lock); + return (ISC_FALSE); + } + + val = ((sock->bound) ? ISC_TRUE : ISC_FALSE); + UNLOCK(&sock->lock); + + return (val); +} + +void +isc__socket_ipv6only(isc_socket_t *sock, isc_boolean_t yes) { +#if defined(IPV6_V6ONLY) + int onoff = yes ? 1 : 0; +#else + UNUSED(yes); +#endif + + REQUIRE(VALID_SOCKET(sock)); + +#ifdef IPV6_V6ONLY + if (sock->pf == AF_INET6) { + (void)setsockopt(sock->fd, IPPROTO_IPV6, IPV6_V6ONLY, + (char *)&onoff, sizeof(onoff)); + } +#endif +} + +void +isc__socket_cleanunix(isc_sockaddr_t *addr, isc_boolean_t active) { + UNUSED(addr); + UNUSED(active); +} + +isc_result_t +isc__socket_permunix(isc_sockaddr_t *addr, isc_uint32_t perm, + isc_uint32_t owner, isc_uint32_t group) +{ + UNUSED(addr); + UNUSED(perm); + UNUSED(owner); + UNUSED(group); + return (ISC_R_NOTIMPLEMENTED); +} + +void +isc__socket_setname(isc_socket_t *socket, const char *name, void *tag) { + + /* + * Name 'socket'. + */ + + REQUIRE(VALID_SOCKET(socket)); + + LOCK(&socket->lock); + memset(socket->name, 0, sizeof(socket->name)); + strncpy(socket->name, name, sizeof(socket->name) - 1); + socket->tag = tag; + UNLOCK(&socket->lock); +} + +const char * +isc__socket_getname(isc_socket_t *socket) { + return (socket->name); +} + +void * +isc__socket_gettag(isc_socket_t *socket) { + return (socket->tag); +} + +int +isc__socket_getfd(isc_socket_t *socket) { + return ((short) socket->fd); +} + +void +isc__socketmgr_setreserved(isc_socketmgr_t *manager, isc_uint32_t reserved) { + UNUSED(manager); + UNUSED(reserved); +} + +void +isc___socketmgr_maxudp(isc_socketmgr_t *manager, int maxudp) { + + UNUSED(manager); + UNUSED(maxudp); +} + +#ifdef HAVE_LIBXML2 + +static const char * +_socktype(isc_sockettype_t type) +{ + if (type == isc_sockettype_udp) + return ("udp"); + else if (type == isc_sockettype_tcp) + return ("tcp"); + else if (type == isc_sockettype_unix) + return ("unix"); + else if (type == isc_sockettype_fdwatch) + return ("fdwatch"); + else + return ("not-initialized"); +} + +void +isc_socketmgr_renderxml(isc_socketmgr_t *mgr, xmlTextWriterPtr writer) +{ + isc_socket_t *sock; + char peerbuf[ISC_SOCKADDR_FORMATSIZE]; + isc_sockaddr_t addr; + ISC_SOCKADDR_LEN_T len; + + LOCK(&mgr->lock); + +#ifndef ISC_PLATFORM_USETHREADS + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", mgr->refs); + xmlTextWriterEndElement(writer); +#endif + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "sockets"); + sock = ISC_LIST_HEAD(mgr->socklist); + while (sock != NULL) { + LOCK(&sock->lock); + xmlTextWriterStartElement(writer, ISC_XMLCHAR "socket"); + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "id"); + xmlTextWriterWriteFormatString(writer, "%p", sock); + xmlTextWriterEndElement(writer); + + if (sock->name[0] != 0) { + xmlTextWriterStartElement(writer, ISC_XMLCHAR "name"); + xmlTextWriterWriteFormatString(writer, "%s", + sock->name); + xmlTextWriterEndElement(writer); /* name */ + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "references"); + xmlTextWriterWriteFormatString(writer, "%d", sock->references); + xmlTextWriterEndElement(writer); + + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "type", + ISC_XMLCHAR _socktype(sock->type)); + + if (sock->connected) { + isc_sockaddr_format(&sock->address, peerbuf, + sizeof(peerbuf)); + xmlTextWriterWriteElement(writer, + ISC_XMLCHAR "peer-address", + ISC_XMLCHAR peerbuf); + } + + len = sizeof(addr); + if (getsockname(sock->fd, &addr.type.sa, (void *)&len) == 0) { + isc_sockaddr_format(&addr, peerbuf, sizeof(peerbuf)); + xmlTextWriterWriteElement(writer, + ISC_XMLCHAR "local-address", + ISC_XMLCHAR peerbuf); + } + + xmlTextWriterStartElement(writer, ISC_XMLCHAR "states"); + if (sock->pending_recv) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending-receive"); + if (sock->pending_send) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending-send"); + if (sock->pending_accept) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "pending_accept"); + if (sock->listener) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "listener"); + if (sock->connected) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "connected"); + if (sock->pending_connect) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "connecting"); + if (sock->bound) + xmlTextWriterWriteElement(writer, ISC_XMLCHAR "state", + ISC_XMLCHAR "bound"); + + xmlTextWriterEndElement(writer); /* states */ + + xmlTextWriterEndElement(writer); /* socket */ + + UNLOCK(&sock->lock); + sock = ISC_LIST_NEXT(sock, link); + } + xmlTextWriterEndElement(writer); /* sockets */ + + UNLOCK(&mgr->lock); +} +#endif /* HAVE_LIBXML2 */ diff --git a/contrib/ntp/lib/isc/win32/stdio.c b/contrib/ntp/lib/isc/win32/stdio.c new file mode 100644 index 000000000..427a8e1e1 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/stdio.c @@ -0,0 +1,117 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdio.c,v 1.6 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include +#include + +#include + +#include "errno2result.h" + +isc_result_t +isc_stdio_open(const char *filename, const char *mode, FILE **fp) { + FILE *f; + + f = fopen(filename, mode); + if (f == NULL) + return (isc__errno2result(errno)); + *fp = f; + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_stdio_close(FILE *f) { + int r; + + r = fclose(f); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_seek(FILE *f, long offset, int whence) { + int r; + + r = fseek(f, offset, whence); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_read(void *ptr, size_t size, size_t nmemb, FILE *f, size_t *nret) { + isc_result_t result = ISC_R_SUCCESS; + size_t r; + + clearerr(f); + r = fread(ptr, size, nmemb, f); + if (r != nmemb) { + if (feof(f)) + result = ISC_R_EOF; + else + result = isc__errno2result(errno); + } + if (nret != NULL) + *nret = r; + return (result); +} + +isc_result_t +isc_stdio_write(const void *ptr, size_t size, size_t nmemb, FILE *f, + size_t *nret) +{ + isc_result_t result = ISC_R_SUCCESS; + size_t r; + + clearerr(f); + r = fwrite(ptr, size, nmemb, f); + if (r != nmemb) + result = isc__errno2result(errno); + if (nret != NULL) + *nret = r; + return (result); +} + +isc_result_t +isc_stdio_flush(FILE *f) { + int r; + + r = fflush(f); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + +isc_result_t +isc_stdio_sync(FILE *f) { + int r; + + r = _commit(_fileno(f)); + if (r == 0) + return (ISC_R_SUCCESS); + else + return (isc__errno2result(errno)); +} + diff --git a/contrib/ntp/lib/isc/win32/stdtime.c b/contrib/ntp/lib/isc/win32/stdtime.c new file mode 100644 index 000000000..ca462513c --- /dev/null +++ b/contrib/ntp/lib/isc/win32/stdtime.c @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1999-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: stdtime.c,v 1.12 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include + +#include +#include +#include + +void +isc_stdtime_get(isc_stdtime_t *t) { + /* + * Set 't' to the number of seconds past 00:00:00 UTC, January 1, 1970. + */ + + REQUIRE(t != NULL); + + (void)time((time_t *)t); +} diff --git a/contrib/ntp/lib/isc/win32/strerror.c b/contrib/ntp/lib/isc/win32/strerror.c new file mode 100644 index 000000000..41743328a --- /dev/null +++ b/contrib/ntp/lib/isc/win32/strerror.c @@ -0,0 +1,459 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001, 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: strerror.c,v 1.8 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include +#include +#include + +#include +#include +#include +#include +#include + +/* + * Forward declarations + */ + +char * +FormatError(int error); + +char * +GetWSAErrorMessage(int errval); + +char * +NTstrerror(int err, BOOL *bfreebuf); + +/* + * We need to do this this way for profiled locks. + */ + +static isc_mutex_t isc_strerror_lock; +static void init_lock(void) { + RUNTIME_CHECK(isc_mutex_init(&isc_strerror_lock) == ISC_R_SUCCESS); +} + +/* + * This routine needs to free up any buffer allocated by FormatMessage + * if that routine gets used. + */ + +void +isc__strerror(int num, char *buf, size_t size) { + char *msg; + BOOL freebuf; + unsigned int unum = num; + static isc_once_t once = ISC_ONCE_INIT; + + REQUIRE(buf != NULL); + + RUNTIME_CHECK(isc_once_do(&once, init_lock) == ISC_R_SUCCESS); + + LOCK(&isc_strerror_lock); + freebuf = FALSE; + msg = NTstrerror(num, &freebuf); + if (msg != NULL) + snprintf(buf, size, "%s", msg); + else + snprintf(buf, size, "Unknown error: %u", unum); + if(freebuf && msg != NULL) { + LocalFree(msg); + } + UNLOCK(&isc_strerror_lock); +} + +/* + * Note this will cause a memory leak unless the memory allocated here + * is freed by calling LocalFree. isc__strerror does this before unlocking. + * This only gets called if there is a system type of error and will likely + * be an unusual event. + */ +char * +FormatError(int error) { + LPVOID lpMsgBuf = NULL; + FormatMessage( + FORMAT_MESSAGE_ALLOCATE_BUFFER | + FORMAT_MESSAGE_FROM_SYSTEM | + FORMAT_MESSAGE_IGNORE_INSERTS, + NULL, + error, + /* Default language */ + MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), + (LPTSTR) &lpMsgBuf, + 0, + NULL); + + return (lpMsgBuf); +} + +/* + * This routine checks the error value and calls the WSA Windows Sockets + * Error message function GetWSAErrorMessage below if it's within that range + * since those messages are not available in the system error messages. + */ +char * +NTstrerror(int err, BOOL *bfreebuf) { + char *retmsg = NULL; + + /* Copy the error value first in case of other errors */ + DWORD errval = err; + + *bfreebuf = FALSE; + + /* Get the Winsock2 error messages */ + if (errval >= WSABASEERR && errval <= (WSABASEERR + 1015)) { + retmsg = GetWSAErrorMessage(errval); + if (retmsg != NULL) + return (retmsg); + } + /* + * If it's not one of the standard Unix error codes, + * try a system error message + */ + if (errval > (DWORD) _sys_nerr) { + *bfreebuf = TRUE; + return (FormatError(errval)); + } else { + return (strerror(errval)); + } +} + +/* + * This is a replacement for perror + */ +void __cdecl +NTperror(char *errmsg) { + /* Copy the error value first in case of other errors */ + int errval = errno; + BOOL bfreebuf = FALSE; + char *msg; + + msg = NTstrerror(errval, &bfreebuf); + fprintf(stderr, "%s: %s\n", errmsg, msg); + if(bfreebuf == TRUE) { + LocalFree(msg); + } + +} + +/* + * Return the error string related to Winsock2 errors. + * This function is necessary since FormatMessage knows nothing about them + * and there is no function to get them. + */ +char * +GetWSAErrorMessage(int errval) { + char *msg; + + switch (errval) { + + case WSAEINTR: + msg = "Interrupted system call"; + break; + + case WSAEBADF: + msg = "Bad file number"; + break; + + case WSAEACCES: + msg = "Permission denied"; + break; + + case WSAEFAULT: + msg = "Bad address"; + break; + + case WSAEINVAL: + msg = "Invalid argument"; + break; + + case WSAEMFILE: + msg = "Too many open sockets"; + break; + + case WSAEWOULDBLOCK: + msg = "Operation would block"; + break; + + case WSAEINPROGRESS: + msg = "Operation now in progress"; + break; + + case WSAEALREADY: + msg = "Operation already in progress"; + break; + + case WSAENOTSOCK: + msg = "Socket operation on non-socket"; + break; + + case WSAEDESTADDRREQ: + msg = "Destination address required"; + break; + + case WSAEMSGSIZE: + msg = "Message too long"; + break; + + case WSAEPROTOTYPE: + msg = "Protocol wrong type for socket"; + break; + + case WSAENOPROTOOPT: + msg = "Bad protocol option"; + break; + + case WSAEPROTONOSUPPORT: + msg = "Protocol not supported"; + break; + + case WSAESOCKTNOSUPPORT: + msg = "Socket type not supported"; + break; + + case WSAEOPNOTSUPP: + msg = "Operation not supported on socket"; + break; + + case WSAEPFNOSUPPORT: + msg = "Protocol family not supported"; + break; + + case WSAEAFNOSUPPORT: + msg = "Address family not supported"; + break; + + case WSAEADDRINUSE: + msg = "Address already in use"; + break; + + case WSAEADDRNOTAVAIL: + msg = "Can't assign requested address"; + break; + + case WSAENETDOWN: + msg = "Network is down"; + break; + + case WSAENETUNREACH: + msg = "Network is unreachable"; + break; + + case WSAENETRESET: + msg = "Net connection reset"; + break; + + case WSAECONNABORTED: + msg = "Software caused connection abort"; + break; + + case WSAECONNRESET: + msg = "Connection reset by peer"; + break; + + case WSAENOBUFS: + msg = "No buffer space available"; + break; + + case WSAEISCONN: + msg = "Socket is already connected"; + break; + + case WSAENOTCONN: + msg = "Socket is not connected"; + break; + + case WSAESHUTDOWN: + msg = "Can't send after socket shutdown"; + break; + + case WSAETOOMANYREFS: + msg = "Too many references: can't splice"; + break; + + case WSAETIMEDOUT: + msg = "Connection timed out"; + break; + + case WSAECONNREFUSED: + msg = "Connection refused"; + break; + + case WSAELOOP: + msg = "Too many levels of symbolic links"; + break; + + case WSAENAMETOOLONG: + msg = "File name too long"; + break; + + case WSAEHOSTDOWN: + msg = "Host is down"; + break; + + case WSAEHOSTUNREACH: + msg = "No route to host"; + break; + + case WSAENOTEMPTY: + msg = "Directory not empty"; + break; + + case WSAEPROCLIM: + msg = "Too many processes"; + break; + + case WSAEUSERS: + msg = "Too many users"; + break; + + case WSAEDQUOT: + msg = "Disc quota exceeded"; + break; + + case WSAESTALE: + msg = "Stale NFS file handle"; + break; + + case WSAEREMOTE: + msg = "Too many levels of remote in path"; + break; + + case WSASYSNOTREADY: + msg = "Network system is unavailable"; + break; + + case WSAVERNOTSUPPORTED: + msg = "Winsock version out of range"; + break; + + case WSANOTINITIALISED: + msg = "WSAStartup not yet called"; + break; + + case WSAEDISCON: + msg = "Graceful shutdown in progress"; + break; +/* + case WSAHOST_NOT_FOUND: + msg = "Host not found"; + break; + + case WSANO_DATA: + msg = "No host data of that type was found"; + break; +*/ + default: + msg = NULL; + break; + } + return (msg); +} + +/* + * These error messages are more informative about CryptAPI Errors than the + * standard error messages + */ + +char * +GetCryptErrorMessage(int errval) { + char *msg; + + switch (errval) { + + case NTE_BAD_FLAGS: + msg = "The dwFlags parameter has an illegal value."; + break; + case NTE_BAD_KEYSET: + msg = "The Registry entry for the key container " + "could not be opened and may not exist."; + break; + case NTE_BAD_KEYSET_PARAM: + msg = "The pszContainer or pszProvider parameter " + "is set to an illegal value."; + break; + case NTE_BAD_PROV_TYPE: + msg = "The value of the dwProvType parameter is out " + "of range. All provider types must be from " + "1 to 999, inclusive."; + break; + case NTE_BAD_SIGNATURE: + msg = "The provider DLL signature did not verify " + "correctly. Either the DLL or the digital " + "signature has been tampered with."; + break; + case NTE_EXISTS: + msg = "The dwFlags parameter is CRYPT_NEWKEYSET, but the key" + " container already exists."; + break; + case NTE_KEYSET_ENTRY_BAD: + msg = "The Registry entry for the pszContainer key container " + "was found (in the HKEY_CURRENT_USER window), but is " + "corrupt. See the section System Administration for " + " etails about CryptoAPI's Registry usage."; + break; + case NTE_KEYSET_NOT_DEF: + msg = "No Registry entry exists in the HKEY_CURRENT_USER " + "window for the key container specified by " + "pszContainer."; + break; + case NTE_NO_MEMORY: + msg = "The CSP ran out of memory during the operation."; + break; + case NTE_PROV_DLL_NOT_FOUND: + msg = "The provider DLL file does not exist or is not on the " + "current path."; + break; + case NTE_PROV_TYPE_ENTRY_BAD: + msg = "The Registry entry for the provider type specified by " + "dwProvType is corrupt. This error may relate to " + "either the user default CSP list or the machine " + "default CSP list. See the section System " + "Administration for details about CryptoAPI's " + "Registry usage."; + break; + case NTE_PROV_TYPE_NO_MATCH: + msg = "The provider type specified by dwProvType does not " + "match the provider type found in the Registry. Note " + "that this error can only occur when pszProvider " + "specifies an actual CSP name."; + break; + case NTE_PROV_TYPE_NOT_DEF: + msg = "No Registry entry exists for the provider type " + "specified by dwProvType."; + break; + case NTE_PROVIDER_DLL_FAIL: + msg = "The provider DLL file could not be loaded, and " + "may not exist. If it exists, then the file is " + "not a valid DLL."; + break; + case NTE_SIGNATURE_FILE_BAD: + msg = "An error occurred while loading the DLL file image, " + "prior to verifying its signature."; + break; + + default: + msg = NULL; + break; + } + return msg; +} + diff --git a/contrib/ntp/lib/isc/win32/syslog.c b/contrib/ntp/lib/isc/win32/syslog.c new file mode 100644 index 000000000..375784f47 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/syslog.c @@ -0,0 +1,181 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001-2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: syslog.c,v 1.10 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +static HANDLE hAppLog = NULL; +static FILE *log_stream; +static int debug_level = 0; + +static struct dsn_c_pvt_sfnt { + int val; + const char *strval; +} facilities[] = { + { LOG_KERN, "kern" }, + { LOG_USER, "user" }, + { LOG_MAIL, "mail" }, + { LOG_DAEMON, "daemon" }, + { LOG_AUTH, "auth" }, + { LOG_SYSLOG, "syslog" }, + { LOG_LPR, "lpr" }, +#ifdef LOG_NEWS + { LOG_NEWS, "news" }, +#endif +#ifdef LOG_UUCP + { LOG_UUCP, "uucp" }, +#endif +#ifdef LOG_CRON + { LOG_CRON, "cron" }, +#endif +#ifdef LOG_AUTHPRIV + { LOG_AUTHPRIV, "authpriv" }, +#endif +#ifdef LOG_FTP + { LOG_FTP, "ftp" }, +#endif + { LOG_LOCAL0, "local0"}, + { LOG_LOCAL1, "local1"}, + { LOG_LOCAL2, "local2"}, + { LOG_LOCAL3, "local3"}, + { LOG_LOCAL4, "local4"}, + { LOG_LOCAL5, "local5"}, + { LOG_LOCAL6, "local6"}, + { LOG_LOCAL7, "local7"}, + { 0, NULL } +}; + +isc_result_t +isc_syslog_facilityfromstring(const char *str, int *facilityp) { + int i; + + REQUIRE(str != NULL); + REQUIRE(facilityp != NULL); + + for (i = 0; facilities[i].strval != NULL; i++) { + if (strcasecmp(facilities[i].strval, str) == 0) { + *facilityp = facilities[i].val; + return (ISC_R_SUCCESS); + } + } + return (ISC_R_NOTFOUND); +} + +/* + * Log to the NT Event Log + */ +void +syslog(int level, const char *fmt, ...) { + va_list ap; + char buf[1024]; + char *str[1]; + + str[0] = buf; + + va_start(ap, fmt); + vsprintf(buf, fmt, ap); + va_end(ap); + + /* Make sure that the channel is open to write the event */ + if (hAppLog != NULL) { + switch (level) { + case LOG_INFO: + case LOG_NOTICE: + case LOG_DEBUG: + ReportEvent(hAppLog, EVENTLOG_INFORMATION_TYPE, 0, + BIND_INFO_MSG, NULL, 1, 0, str, NULL); + break; + case LOG_WARNING: + ReportEvent(hAppLog, EVENTLOG_WARNING_TYPE, 0, + BIND_WARN_MSG, NULL, 1, 0, str, NULL); + break; + default: + ReportEvent(hAppLog, EVENTLOG_ERROR_TYPE, 0, + BIND_ERR_MSG, NULL, 1, 0, str, NULL); + break; + } + } +} + +/* + * Initialize event logging + */ +void +openlog(const char *name, int flags, ...) { + /* Get a handle to the Application event log */ + hAppLog = RegisterEventSource(NULL, name); +} + +/* + * Close the Handle to the application Event Log + * We don't care whether or not we succeeded so ignore return values + * In fact if we failed then we would have nowhere to put the message + */ +void +closelog() { + DeregisterEventSource(hAppLog); +} + +/* + * Keep event logging synced with the current debug level + */ +void +ModifyLogLevel(int level) { + debug_level = level; +} + +/* + * Initialize logging for the port section of libbind. + * Piggyback onto stream given. + */ +void +InitNTLogging(FILE *stream, int debug) { + log_stream = stream; + ModifyLogLevel(debug); +} +/* + * This function is for reporting errors to the application + * event log in case the regular syslog is not available + * mainly during startup. It should not be used under normal + * circumstances. + */ +void +NTReportError(const char *name, const char *str) { + HANDLE hNTAppLog = NULL; + const char *buf[1]; + + buf[0] = str; + + hNTAppLog = RegisterEventSource(NULL, name); + + ReportEvent(hNTAppLog, EVENTLOG_ERROR_TYPE, 0, + BIND_ERR_MSG, NULL, 1, 0, buf, NULL); + + DeregisterEventSource(hNTAppLog); +} diff --git a/contrib/ntp/lib/isc/win32/syslog.h b/contrib/ntp/lib/isc/win32/syslog.h new file mode 100644 index 000000000..fd4b3a6bf --- /dev/null +++ b/contrib/ntp/lib/isc/win32/syslog.h @@ -0,0 +1,76 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2001, 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: syslog.h,v 1.7 2007/06/19 23:47:19 tbox Exp $ */ + +#ifndef _SYSLOG_H +#define _SYSLOG_H + +#include + +/* Constant definitions for openlog() */ +#define LOG_PID 1 +#define LOG_CONS 2 +/* NT event log does not support facility level */ +#define LOG_KERN 0 +#define LOG_USER 0 +#define LOG_MAIL 0 +#define LOG_DAEMON 0 +#define LOG_AUTH 0 +#define LOG_SYSLOG 0 +#define LOG_LPR 0 +#define LOG_LOCAL0 0 +#define LOG_LOCAL1 0 +#define LOG_LOCAL2 0 +#define LOG_LOCAL3 0 +#define LOG_LOCAL4 0 +#define LOG_LOCAL5 0 +#define LOG_LOCAL6 0 +#define LOG_LOCAL7 0 + +#define LOG_EMERG 0 /* system is unusable */ +#define LOG_ALERT 1 /* action must be taken immediately */ +#define LOG_CRIT 2 /* critical conditions */ +#define LOG_ERR 3 /* error conditions */ +#define LOG_WARNING 4 /* warning conditions */ +#define LOG_NOTICE 5 /* normal but signification condition */ +#define LOG_INFO 6 /* informational */ +#define LOG_DEBUG 7 /* debug-level messages */ + +void +syslog(int level, const char *fmt, ...); + +void +openlog(const char *, int, ...); + +void +closelog(void); + +void +ModifyLogLevel(int level); + +void +InitNTLogging(FILE *, int); + +void +NTReportError(const char *, const char *); +/* + * Include the event codes required for logging. + */ +#include + +#endif diff --git a/contrib/ntp/lib/isc/win32/thread.c b/contrib/ntp/lib/isc/win32/thread.c new file mode 100644 index 000000000..85ffef1e7 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/thread.c @@ -0,0 +1,94 @@ +/* + * Copyright (C) 2004, 2005, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: thread.c,v 1.24 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include + +#include + +isc_result_t +isc_thread_create(isc_threadfunc_t start, isc_threadarg_t arg, + isc_thread_t *threadp) +{ + isc_thread_t thread; + unsigned int id; + + thread = (isc_thread_t)_beginthreadex(NULL, 0, start, arg, 0, &id); + if (thread == NULL) { + /* XXX */ + return (ISC_R_UNEXPECTED); + } + + *threadp = thread; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_thread_join(isc_thread_t thread, isc_threadresult_t *rp) { + DWORD result; + DWORD threadrc; + + result = WaitForSingleObject(thread, INFINITE); + if (result != WAIT_OBJECT_0) { + /* XXX */ + return (ISC_R_UNEXPECTED); + } + if (rp != NULL) { + if(!GetExitCodeThread(thread, &threadrc)) { + /* XXX */ + return (ISC_R_UNEXPECTED); + } + *rp = threadrc; + } + (void)CloseHandle(thread); + + return (ISC_R_SUCCESS); +} + +void +isc_thread_setconcurrency(unsigned int level) { + /* + * This is unnecessary on Win32 systems, but is here so that the + * call exists + */ +} + +void * +isc_thread_key_getspecific(isc_thread_key_t key) { + return(TlsGetValue(key)); +} + +int +isc_thread_key_setspecific(isc_thread_key_t key, void *value) { + return (TlsSetValue(key, value) ? 0 : GetLastError()); +} + +int +isc_thread_key_create(isc_thread_key_t *key, void (*func)(void *)) { + *key = TlsAlloc(); + + return ((*key != -1) ? 0 : GetLastError()); +} + +int +isc_thread_key_delete(isc_thread_key_t key) { + return (TlsFree(key) ? 0 : GetLastError()); +} diff --git a/contrib/ntp/lib/isc/win32/time.c b/contrib/ntp/lib/isc/win32/time.c new file mode 100644 index 000000000..aafd70b12 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/time.c @@ -0,0 +1,320 @@ +/* + * Copyright (C) 2004, 2006-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001, 2003 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: time.c,v 1.52 2009/08/14 07:51:08 marka Exp $ */ + +#include + +#include +#include +#include +#include +#include +#include + +#include + +#include +#include +#include + +/* + * struct FILETIME uses "100-nanoseconds intervals". + * NS / S = 1000000000 (10^9). + * While it is reasonably obvious that this makes the needed + * conversion factor 10^7, it is coded this way for additional clarity. + */ +#define NS_PER_S 1000000000 +#define NS_INTERVAL 100 +#define INTERVALS_PER_S (NS_PER_S / NS_INTERVAL) +#define UINT64_MAX _UI64_MAX + +/*** + *** Absolute Times + ***/ + +static isc_time_t epoch = { { 0, 0 } }; +LIBISC_EXTERNAL_DATA isc_time_t *isc_time_epoch = &epoch; + +/*** + *** Intervals + ***/ + +static isc_interval_t zero_interval = { 0 }; +LIBISC_EXTERNAL_DATA isc_interval_t *isc_interval_zero = &zero_interval; + +void +isc_interval_set(isc_interval_t *i, unsigned int seconds, + unsigned int nanoseconds) +{ + REQUIRE(i != NULL); + REQUIRE(nanoseconds < NS_PER_S); + + /* + * This rounds nanoseconds up not down. + */ + i->interval = (LONGLONG)seconds * INTERVALS_PER_S + + (nanoseconds + NS_INTERVAL - 1) / NS_INTERVAL; +} + +isc_boolean_t +isc_interval_iszero(const isc_interval_t *i) { + REQUIRE(i != NULL); + if (i->interval == 0) + return (ISC_TRUE); + + return (ISC_FALSE); +} + +void +isc_time_set(isc_time_t *t, unsigned int seconds, unsigned int nanoseconds) { + SYSTEMTIME epoch = { 1970, 1, 4, 1, 0, 0, 0, 0 }; + FILETIME temp; + ULARGE_INTEGER i1; + + REQUIRE(t != NULL); + REQUIRE(nanoseconds < NS_PER_S); + + SystemTimeToFileTime(&epoch, &temp); + + i1.LowPart = t->absolute.dwLowDateTime; + i1.HighPart = t->absolute.dwHighDateTime; + + i1.QuadPart += (unsigned __int64)nanoseconds/100; + i1.QuadPart += (unsigned __int64)seconds*10000000; + + t->absolute.dwLowDateTime = i1.LowPart; + t->absolute.dwHighDateTime = i1.HighPart; +} + +void +isc_time_settoepoch(isc_time_t *t) { + REQUIRE(t != NULL); + + t->absolute.dwLowDateTime = 0; + t->absolute.dwHighDateTime = 0; +} + +isc_boolean_t +isc_time_isepoch(const isc_time_t *t) { + REQUIRE(t != NULL); + + if (t->absolute.dwLowDateTime == 0 && + t->absolute.dwHighDateTime == 0) + return (ISC_TRUE); + + return (ISC_FALSE); +} + +isc_result_t +isc_time_now(isc_time_t *t) { + REQUIRE(t != NULL); + + GetSystemTimeAsFileTime(&t->absolute); + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_time_nowplusinterval(isc_time_t *t, const isc_interval_t *i) { + ULARGE_INTEGER i1; + + REQUIRE(t != NULL); + REQUIRE(i != NULL); + + GetSystemTimeAsFileTime(&t->absolute); + + i1.LowPart = t->absolute.dwLowDateTime; + i1.HighPart = t->absolute.dwHighDateTime; + + if (UINT64_MAX - i1.QuadPart < (unsigned __int64)i->interval) + return (ISC_R_RANGE); + + i1.QuadPart += i->interval; + + t->absolute.dwLowDateTime = i1.LowPart; + t->absolute.dwHighDateTime = i1.HighPart; + + return (ISC_R_SUCCESS); +} + +int +isc_time_compare(const isc_time_t *t1, const isc_time_t *t2) { + REQUIRE(t1 != NULL && t2 != NULL); + + return ((int)CompareFileTime(&t1->absolute, &t2->absolute)); +} + +isc_result_t +isc_time_add(const isc_time_t *t, const isc_interval_t *i, isc_time_t *result) +{ + ULARGE_INTEGER i1; + + REQUIRE(t != NULL && i != NULL && result != NULL); + + i1.LowPart = t->absolute.dwLowDateTime; + i1.HighPart = t->absolute.dwHighDateTime; + + if (UINT64_MAX - i1.QuadPart < (unsigned __int64)i->interval) + return (ISC_R_RANGE); + + i1.QuadPart += i->interval; + + result->absolute.dwLowDateTime = i1.LowPart; + result->absolute.dwHighDateTime = i1.HighPart; + + return (ISC_R_SUCCESS); +} + +isc_result_t +isc_time_subtract(const isc_time_t *t, const isc_interval_t *i, + isc_time_t *result) { + ULARGE_INTEGER i1; + + REQUIRE(t != NULL && i != NULL && result != NULL); + + i1.LowPart = t->absolute.dwLowDateTime; + i1.HighPart = t->absolute.dwHighDateTime; + + if (i1.QuadPart < (unsigned __int64) i->interval) + return (ISC_R_RANGE); + + i1.QuadPart -= i->interval; + + result->absolute.dwLowDateTime = i1.LowPart; + result->absolute.dwHighDateTime = i1.HighPart; + + return (ISC_R_SUCCESS); +} + +isc_uint64_t +isc_time_microdiff(const isc_time_t *t1, const isc_time_t *t2) { + ULARGE_INTEGER i1, i2; + LONGLONG i3; + + REQUIRE(t1 != NULL && t2 != NULL); + + i1.LowPart = t1->absolute.dwLowDateTime; + i1.HighPart = t1->absolute.dwHighDateTime; + i2.LowPart = t2->absolute.dwLowDateTime; + i2.HighPart = t2->absolute.dwHighDateTime; + + if (i1.QuadPart <= i2.QuadPart) + return (0); + + /* + * Convert to microseconds. + */ + i3 = (i1.QuadPart - i2.QuadPart) / 10; + + return (i3); +} + +isc_uint32_t +isc_time_seconds(const isc_time_t *t) { + SYSTEMTIME epoch = { 1970, 1, 4, 1, 0, 0, 0, 0 }; + FILETIME temp; + ULARGE_INTEGER i1, i2; + LONGLONG i3; + + SystemTimeToFileTime(&epoch, &temp); + + i1.LowPart = t->absolute.dwLowDateTime; + i1.HighPart = t->absolute.dwHighDateTime; + i2.LowPart = temp.dwLowDateTime; + i2.HighPart = temp.dwHighDateTime; + + i3 = (i1.QuadPart - i2.QuadPart) / 10000000; + + return ((isc_uint32_t)i3); +} + +isc_uint32_t +isc_time_nanoseconds(const isc_time_t *t) { + ULARGE_INTEGER i; + + i.LowPart = t->absolute.dwLowDateTime; + i.HighPart = t->absolute.dwHighDateTime; + return ((isc_uint32_t)(i.QuadPart % 10000000) * 100); +} + +void +isc_time_formattimestamp(const isc_time_t *t, char *buf, unsigned int len) { + FILETIME localft; + SYSTEMTIME st; + char DateBuf[50]; + char TimeBuf[50]; + + static const char badtime[] = "99-Bad-9999 99:99:99.999"; + + REQUIRE(len > 0); + if (FileTimeToLocalFileTime(&t->absolute, &localft) && + FileTimeToSystemTime(&localft, &st)) { + GetDateFormat(LOCALE_USER_DEFAULT, 0, &st, "dd-MMM-yyyy", + DateBuf, 50); + GetTimeFormat(LOCALE_USER_DEFAULT, TIME_NOTIMEMARKER| + TIME_FORCE24HOURFORMAT, &st, NULL, TimeBuf, 50); + + snprintf(buf, len, "%s %s.%03u", DateBuf, TimeBuf, + st.wMilliseconds); + + } else + snprintf(buf, len, badtime); +} + +void +isc_time_formathttptimestamp(const isc_time_t *t, char *buf, unsigned int len) { + SYSTEMTIME st; + char DateBuf[50]; + char TimeBuf[50]; + +/* strftime() format: "%a, %d %b %Y %H:%M:%S GMT" */ + + REQUIRE(len > 0); + if (FileTimeToSystemTime(&t->absolute, &st)) { + GetDateFormat(LOCALE_USER_DEFAULT, 0, &st, + "ddd',', dd-MMM-yyyy", DateBuf, 50); + GetTimeFormat(LOCALE_USER_DEFAULT, + TIME_NOTIMEMARKER | TIME_FORCE24HOURFORMAT, + &st, "hh':'mm':'ss", TimeBuf, 50); + + snprintf(buf, len, "%s %s GMT", DateBuf, TimeBuf); + } else { + buf[0] = 0; + } +} + +void +isc_time_formatISO8601(const isc_time_t *t, char *buf, unsigned int len) { + SYSTEMTIME st; + char DateBuf[50]; + char TimeBuf[50]; + +/* strtime() format: "%Y-%m-%dT%H:%M:%SZ" */ + + REQUIRE(len > 0); + if (FileTimeToSystemTime(&t->absolute, &st)) { + GetDateFormat(LOCALE_NEUTRAL, 0, &st, "yyyy-MM-dd", + DateBuf, 50); + GetTimeFormat(LOCALE_NEUTRAL, + TIME_NOTIMEMARKER | TIME_FORCE24HOURFORMAT, + &st, "hh':'mm':'ss", TimeBuf, 50); + snprintf(buf, len, "%s%sZ", DateBuf, TimeBuf); + } else { + buf[0] = 0; + } +} diff --git a/contrib/ntp/lib/isc/win32/unistd.h b/contrib/ntp/lib/isc/win32/unistd.h new file mode 100644 index 000000000..bcb3b256d --- /dev/null +++ b/contrib/ntp/lib/isc/win32/unistd.h @@ -0,0 +1,60 @@ +/* + * Copyright (C) 2004, 2007-2009 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2000, 2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: unistd.h,v 1.10 2009/07/17 23:47:41 tbox Exp $ */ + +/* None of these are defined in NT, so define them for our use */ +#define O_NONBLOCK 1 +#define PORT_NONBLOCK O_NONBLOCK + +/* + * fcntl() commands + */ +#define F_SETFL 0 +#define F_GETFL 1 +#define F_SETFD 2 +#define F_GETFD 3 +/* + * Enough problems not having full fcntl() without worrying about this! + */ +#undef F_DUPFD + +int fcntl(int, int, ...); + +/* + * access() related definitions for winXP + */ +#include +#ifndef F_OK +#define F_OK 0 +#endif + +#ifndef X_OK +#define X_OK 1 +#endif + +#ifndef W_OK +#define W_OK 2 +#endif + +#ifndef R_OK +#define R_OK 4 +#endif + +#define access _access + +#include diff --git a/contrib/ntp/lib/isc/win32/version.c b/contrib/ntp/lib/isc/win32/version.c new file mode 100644 index 000000000..6d5c1fd92 --- /dev/null +++ b/contrib/ntp/lib/isc/win32/version.c @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 1998-2001 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: version.c,v 1.7 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include + +LIBISC_EXTERNAL_DATA const char isc_version[] = VERSION; + +LIBISC_EXTERNAL_DATA const unsigned int isc_libinterface = LIBINTERFACE; +LIBISC_EXTERNAL_DATA const unsigned int isc_librevision = LIBREVISION; +LIBISC_EXTERNAL_DATA const unsigned int isc_libage = LIBAGE; diff --git a/contrib/ntp/lib/isc/win32/win32os.c b/contrib/ntp/lib/isc/win32/win32os.c new file mode 100644 index 000000000..56498d0ad --- /dev/null +++ b/contrib/ntp/lib/isc/win32/win32os.c @@ -0,0 +1,101 @@ +/* + * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") + * Copyright (C) 2002 Internet Software Consortium. + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: win32os.c,v 1.5 2007/06/19 23:47:19 tbox Exp $ */ + +#include + +#include + +static BOOL bInit = FALSE; +static OSVERSIONINFOEX osVer; + +static void +initialize_action(void) { + BOOL bSuccess; + + if (bInit) + return; + /* + * NOTE: VC++ 6.0 gets this function declaration wrong + * so we compensate by casting the argument + */ + osVer.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEX); + bSuccess = GetVersionEx((OSVERSIONINFO *) &osVer); + + /* + * Versions of NT before NT4.0 SP6 did not return the + * extra info that the EX structure provides and returns + * a failure so we need to retry with the old structure. + */ + if(!bSuccess) { + osVer.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + bSuccess = GetVersionEx((OSVERSIONINFO *) &osVer); + } + bInit = TRUE; +} + +unsigned int +isc_win32os_majorversion(void) { + initialize_action(); + return ((unsigned int)osVer.dwMajorVersion); +} + +unsigned int +isc_win32os_minorversion(void) { + initialize_action(); + return ((unsigned int)osVer.dwMinorVersion); +} + +unsigned int +isc_win32os_servicepackmajor(void) { + initialize_action(); + return ((unsigned int)osVer.wServicePackMajor); +} + +unsigned int +isc_win32os_servicepackminor(void) { + initialize_action(); + return ((unsigned int)osVer.wServicePackMinor); +} + +int +isc_win32os_versioncheck(unsigned int major, unsigned int minor, + unsigned int spmajor, unsigned int spminor) { + + initialize_action(); + + if (major < isc_win32os_majorversion()) + return (1); + if (major > isc_win32os_majorversion()) + return (-1); + if (minor < isc_win32os_minorversion()) + return (1); + if (minor > isc_win32os_minorversion()) + return (-1); + if (spmajor < isc_win32os_servicepackmajor()) + return (1); + if (spmajor > isc_win32os_servicepackmajor()) + return (-1); + if (spminor < isc_win32os_servicepackminor()) + return (1); + if (spminor > isc_win32os_servicepackminor()) + return (-1); + + /* Exact */ + return (0); +} \ No newline at end of file diff --git a/contrib/ntp/lib/isc/x86_32/include/isc/atomic.h b/contrib/ntp/lib/isc/x86_32/include/isc/atomic.h new file mode 100644 index 000000000..bf2148cb3 --- /dev/null +++ b/contrib/ntp/lib/isc/x86_32/include/isc/atomic.h @@ -0,0 +1,176 @@ +/* + * Copyright (C) 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.10 2008/01/24 23:47:00 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM +/* + * This routine atomically increments the value stored in 'p' by 'val', and + * returns the previous value. + */ +static __inline__ isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + isc_int32_t prev = val; + + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xadd %0, %1" + :"=q"(prev) + :"m"(*p), "0"(prev) + :"memory", "cc"); + + return (prev); +} + +#ifdef ISC_PLATFORM_HAVEXADDQ +static __inline__ isc_int64_t +isc_atomic_xaddq(isc_int64_t *p, isc_int64_t val) { + isc_int64_t prev = val; + + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xaddq %0, %1" + :"=q"(prev) + :"m"(*p), "0"(prev) + :"memory", "cc"); + + return (prev); +} +#endif /* ISC_PLATFORM_HAVEXADDQ */ + +/* + * This routine atomically stores the value 'val' in 'p'. + */ +static __inline__ void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + /* + * xchg should automatically lock memory, but we add it + * explicitly just in case (it at least doesn't harm) + */ + "lock;" +#endif + + "xchgl %1, %0" + : + : "r"(val), "m"(*p) + : "memory"); +} + +/* + * This routine atomically replaces the value in 'p' with 'val', if the + * original value is equal to 'cmpval'. The original value is returned in any + * case. + */ +static __inline__ isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + __asm__ volatile( +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "cmpxchgl %1, %2" + : "=a"(cmpval) + : "r"(val), "m"(*p), "a"(cmpval) + : "memory"); + + return (cmpval); +} + +#elif defined(ISC_PLATFORM_USESTDASM) +/* + * The followings are "generic" assembly code which implements the same + * functionality in case the gcc extension cannot be used. It should be + * better to avoid inlining below, since we directly refer to specific + * positions of the stack frame, which would not actually point to the + * intended address in the embedded mnemonic. + */ +#include /* for 'UNUSED' macro */ + +static isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movl 8(%ebp), %ecx\n" + "movl 12(%ebp), %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xadd %edx, (%ecx)\n" + + /* + * set the return value directly in the register so that we + * can avoid guessing the correct position in the stack for a + * local variable. + */ + "movl %edx, %eax" + ); +} + +static void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movl 8(%ebp), %ecx\n" + "movl 12(%ebp), %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xchgl (%ecx), %edx\n" + ); +} + +static isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + UNUSED(p); + UNUSED(cmpval); + UNUSED(val); + + __asm ( + "movl 8(%ebp), %ecx\n" + "movl 12(%ebp), %eax\n" /* must be %eax for cmpxchgl */ + "movl 16(%ebp), %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + + /* + * If (%ecx) == %eax then (%ecx) := %edx. + % %eax is set to old (%ecx), which will be the return value. + */ + "cmpxchgl %edx, (%ecx)" + ); +} +#else /* !ISC_PLATFORM_USEGCCASM && !ISC_PLATFORM_USESTDASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/lib/isc/x86_64/include/isc/atomic.h b/contrib/ntp/lib/isc/x86_64/include/isc/atomic.h new file mode 100644 index 000000000..f57bd2a78 --- /dev/null +++ b/contrib/ntp/lib/isc/x86_64/include/isc/atomic.h @@ -0,0 +1,123 @@ +/* + * Copyright (C) 2005, 2007, 2008 Internet Systems Consortium, Inc. ("ISC") + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH + * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, + * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE + * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + * PERFORMANCE OF THIS SOFTWARE. + */ + +/* $Id: atomic.h,v 1.6 2008/01/24 23:47:00 tbox Exp $ */ + +#ifndef ISC_ATOMIC_H +#define ISC_ATOMIC_H 1 + +#include +#include + +#ifdef ISC_PLATFORM_USEGCCASM + +/* We share the gcc-version with x86_32 */ +#error "impossible case. check build configuration" + +#elif defined(ISC_PLATFORM_USESTDASM) +/* + * The followings are "generic" assembly code which implements the same + * functionality in case the gcc extension cannot be used. It should be + * better to avoid inlining below, since we directly refer to specific + * registers for arguments, which would not actually correspond to the + * intended address or value in the embedded mnemonic. + */ +#include /* for 'UNUSED' macro */ + +static isc_int32_t +isc_atomic_xadd(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movq %rdi, %rdx\n" + "movl %esi, %eax\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xadd %eax, (%rdx)\n" + /* + * XXX: assume %eax will be used as the return value. + */ + ); +} + +#ifdef ISC_PLATFORM_HAVEXADDQ +static isc_int64_t +isc_atomic_xaddq(isc_int64_t *p, isc_int64_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movq %rdi, %rdx\n" + "movq %rsi, %rax\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xaddq %rax, (%rdx)\n" + /* + * XXX: assume %rax will be used as the return value. + */ + ); +} +#endif + +static void +isc_atomic_store(isc_int32_t *p, isc_int32_t val) { + UNUSED(p); + UNUSED(val); + + __asm ( + "movq %rdi, %rax\n" + "movl %esi, %edx\n" +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + "xchgl (%rax), %edx\n" + /* + * XXX: assume %rax will be used as the return value. + */ + ); +} + +static isc_int32_t +isc_atomic_cmpxchg(isc_int32_t *p, isc_int32_t cmpval, isc_int32_t val) { + UNUSED(p); + UNUSED(cmpval); + UNUSED(val); + + __asm ( + "movl %edx, %ecx\n" + "movl %esi, %eax\n" + "movq %rdi, %rdx\n" + +#ifdef ISC_PLATFORM_USETHREADS + "lock;" +#endif + /* + * If (%rdi) == %eax then (%rdi) := %edx. + * %eax is set to old (%ecx), which will be the return value. + */ + "cmpxchgl %ecx, (%rdx)" + ); +} + +#else /* !ISC_PLATFORM_USEGCCASM && !ISC_PLATFORM_USESTDASM */ + +#error "unsupported compiler. disable atomic ops by --disable-atomic" + +#endif +#endif /* ISC_ATOMIC_H */ diff --git a/contrib/ntp/libisc/assertions.c b/contrib/ntp/libisc/assertions.c deleted file mode 100644 index 08dd5f3d5..000000000 --- a/contrib/ntp/libisc/assertions.c +++ /dev/null @@ -1,93 +0,0 @@ -/* - * Copyright (C) 1997-2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: assertions.c,v 1.16 2001/07/16 03:52:05 mayer Exp $ */ - -#include - -#include -#include - -#include -#include - -/* - * Forward. - */ - -static void -default_callback(const char *, int, isc_assertiontype_t, const char *); - -/* - * Public. - */ - -LIBISC_EXTERNAL_DATA isc_assertioncallback_t isc_assertion_failed = - default_callback; - -void -isc_assertion_setcallback(isc_assertioncallback_t cb) { - if (cb == NULL) - isc_assertion_failed = default_callback; - else - isc_assertion_failed = cb; -} - -const char * -isc_assertion_typetotext(isc_assertiontype_t type) { - const char *result; - - /* - * These strings have purposefully not been internationalized - * because they are considered to essentially be keywords of - * the ISC development environment. - */ - switch (type) { - case isc_assertiontype_require: - result = "REQUIRE"; - break; - case isc_assertiontype_ensure: - result = "ENSURE"; - break; - case isc_assertiontype_insist: - result = "INSIST"; - break; - case isc_assertiontype_invariant: - result = "INVARIANT"; - break; - default: - result = NULL; - } - return (result); -} - -/* - * Private. - */ - -static void -default_callback(const char *file, int line, isc_assertiontype_t type, - const char *cond) -{ - fprintf(stderr, "%s:%d: %s(%s) %s.\n", - file, line, isc_assertion_typetotext(type), cond, - isc_msgcat_get(isc_msgcat, ISC_MSGSET_GENERAL, - ISC_MSG_FAILED, "failed")); - fflush(stderr); - abort(); - /* NOTREACHED */ -} diff --git a/contrib/ntp/libisc/mem.c b/contrib/ntp/libisc/mem.c deleted file mode 100644 index 39f1e5c7c..000000000 --- a/contrib/ntp/libisc/mem.c +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (C) 1997-2002 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: mem.c,v 1.113 2002/05/23 04:32:30 marka Exp $ */ - -#include -#include -#include - -#include -#include - -void * -isc_mem_get(isc_mem_t *ctx, size_t size) { - UNUSED(ctx); - if(size == 0) - size = 1; - return (malloc(size)); -} - -void -isc_mem_put(isc_mem_t *ctx, void *ptr, size_t size) -{ - UNUSED(ctx); - UNUSED(size); - free(ptr); -} - diff --git a/contrib/ntp/libisc/strerror.c b/contrib/ntp/libisc/strerror.c deleted file mode 100644 index 4a0f8d80c..000000000 --- a/contrib/ntp/libisc/strerror.c +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright (C) 2001 Internet Software Consortium. - * - * Permission to use, copy, modify, and distribute this software for any - * purpose with or without fee is hereby granted, provided that the above - * copyright notice and this permission notice appear in all copies. - * - * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM - * DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL - * INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, - * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING - * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, - * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION - * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -/* $Id: strerror.c,v 1.3 2001/11/20 01:45:45 gson Exp $ */ - -#include - -#include -#include - -#include -#include -#include -#include -#include - -#ifdef HAVE_STRERROR -/* - * We need to do this this way for profiled locks. - */ -static isc_mutex_t isc_strerror_lock; -static void init_lock(void) { - RUNTIME_CHECK(isc_mutex_init(&isc_strerror_lock) == ISC_R_SUCCESS); -} -#else -extern const char * const sys_errlist[]; -extern const int sys_nerr; -#endif - -void -isc__strerror(int num, char *buf, size_t size) { -#ifdef HAVE_STRERROR - char *msg; - unsigned int unum = num; - static isc_once_t once = ISC_ONCE_INIT; - - REQUIRE(buf != NULL); - - RUNTIME_CHECK(isc_once_do(&once, init_lock) == ISC_R_SUCCESS); - - LOCK(&isc_strerror_lock); - msg = strerror(num); - if (msg != NULL) - snprintf(buf, size, "%s", msg); - else - snprintf(buf, size, "Unknown error: %u", unum); - UNLOCK(&isc_strerror_lock); -#else - unsigned int unum = num; - - REQUIRE(buf != NULL); - - if (num >= 0 && num < sys_nerr) - snprintf(buf, size, "%s", sys_errlist[num]); - else - snprintf(buf, size, "Unknown error: %u", unum); -#endif -} diff --git a/contrib/ntp/libjsmn/LICENSE b/contrib/ntp/libjsmn/LICENSE new file mode 100644 index 000000000..c84fb2e97 --- /dev/null +++ b/contrib/ntp/libjsmn/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2010 Serge A. Zaitsev + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + diff --git a/contrib/ntp/libjsmn/Makefile b/contrib/ntp/libjsmn/Makefile new file mode 100644 index 000000000..5e3e2a97f --- /dev/null +++ b/contrib/ntp/libjsmn/Makefile @@ -0,0 +1,35 @@ +# You can put your build options here +-include config.mk + +all: libjsmn.a + +libjsmn.a: jsmn.o + $(AR) rc $@ $^ + +%.o: %.c jsmn.h + $(CC) -c $(CFLAGS) $< -o $@ + +test: jsmn_test + ./jsmn_test + +jsmn_test: jsmn_test.o + $(CC) $(LDFLAGS) -L. -ljsmn $< -o $@ + +jsmn_test.o: jsmn_test.c libjsmn.a + +simple_example: example/simple.o libjsmn.a + $(CC) $(LDFLAGS) $^ -o $@ + +jsondump: example/jsondump.o libjsmn.a + $(CC) $(LDFLAGS) $^ -o $@ + +clean: + rm -f jsmn.o jsmn_test.o example/simple.o + rm -f jsmn_test + rm -f jsmn_test.exe + rm -f libjsmn.a + rm -f simple_example + rm -f jsondump + +.PHONY: all clean test + diff --git a/contrib/ntp/libjsmn/README.md b/contrib/ntp/libjsmn/README.md new file mode 100644 index 000000000..353af94a8 --- /dev/null +++ b/contrib/ntp/libjsmn/README.md @@ -0,0 +1,167 @@ + +JSMN +==== + +jsmn (pronounced like 'jasmine') is a minimalistic JSON parser in C. It can be +easily integrated into resource-limited or embedded projects. + +You can find more information about JSON format at [json.org][1] + +Library sources are available at [bitbucket.org/zserge/jsmn][2] + +The web page with some information about jsmn can be found at +[http://zserge.com/jsmn.html][3] + +Philosophy +---------- + +Most JSON parsers offer you a bunch of functions to load JSON data, parse it +and extract any value by its name. jsmn proves that checking the correctness of +every JSON packet or allocating temporary objects to store parsed JSON fields +often is an overkill. + +JSON format itself is extremely simple, so why should we complicate it? + +jsmn is designed to be **robust** (it should work fine even with erroneous +data), **fast** (it should parse data on the fly), **portable** (no superfluous +dependencies or non-standard C extensions). An of course, **simplicity** is a +key feature - simple code style, simple algorithm, simple integration into +other projects. + +Features +-------- + +* compatible with C89 +* no dependencies (even libc!) +* highly portable (tested on x86/amd64, ARM, AVR) +* about 200 lines of code +* extremely small code footprint +* API contains only 2 functions +* no dynamic memory allocation +* incremental single-pass parsing +* library code is covered with unit-tests + +Design +------ + +The rudimentary jsmn object is a **token**. Let's consider a JSON string: + + '{ "name" : "Jack", "age" : 27 }' + +It holds the following tokens: + +* Object: `{ "name" : "Jack", "age" : 27}` (the whole object) +* Strings: `"name"`, `"Jack"`, `"age"` (keys and some values) +* Number: `27` + +In jsmn, tokens do not hold any data, but point to token boundaries in JSON +string instead. In the example above jsmn will create tokens like: Object +[0..31], String [3..7], String [12..16], String [20..23], Number [27..29]. + +Every jsmn token has a type, which indicates the type of corresponding JSON +token. jsmn supports the following token types: + +* Object - a container of key-value pairs, e.g.: + `{ "foo":"bar", "x":0.3 }` +* Array - a sequence of values, e.g.: + `[ 1, 2, 3 ]` +* String - a quoted sequence of chars, e.g.: `"foo"` +* Primitive - a number, a boolean (`true`, `false`) or `null` + +Besides start/end positions, jsmn tokens for complex types (like arrays +or objects) also contain a number of child items, so you can easily follow +object hierarchy. + +This approach provides enough information for parsing any JSON data and makes +it possible to use zero-copy techniques. + +Install +------- + +To clone the repository you should have mercurial installed. Just run: + + $ hg clone http://bitbucket.org/zserge/jsmn jsmn + +Repository layout is simple: jsmn.c and jsmn.h are library files, tests are in +the jsmn\_test.c, you will also find README, LICENSE and Makefile files inside. + +To build the library, run `make`. It is also recommended to run `make test`. +Let me know, if some tests fail. + +If build was successful, you should get a `libjsmn.a` library. +The header file you should include is called `"jsmn.h"`. + +API +--- + +Token types are described by `jsmntype_t`: + + typedef enum { + JSMN_PRIMITIVE = 0, + JSMN_OBJECT = 1, + JSMN_ARRAY = 2, + JSMN_STRING = 3 + } jsmntype_t; + +**Note:** Unlike JSON data types, primitive tokens are not divided into +numbers, booleans and null, because one can easily tell the type using the +first character: + +* 't', 'f' - boolean +* 'n' - null +* '-', '0'..'9' - number + +Token is an object of `jsmntok_t` type: + + typedef struct { + jsmntype_t type; // Token type + int start; // Token start position + int end; // Token end position + int size; // Number of child (nested) tokens + } jsmntok_t; + +**Note:** string tokens point to the first character after +the opening quote and the previous symbol before final quote. This was made +to simplify string extraction from JSON data. + +All job is done by `jsmn_parser` object. You can initialize a new parser using: + + jsmn_parser parser; + jsmntok_t tokens[10]; + + jsmn_init(&parser); + + // js - pointer to JSON string + // tokens - an array of tokens available + // 10 - number of tokens available + jsmn_parse(&parser, js, tokens, 10); + +This will create a parser, and then it tries to parse up to 10 JSON tokens from +the `js` string. + +A non-negative reutrn value of `jsmn_parse` is the number of tokens actually +used by the parser. +Passing NULL instead of the tokens array would not store parsing results, but +instead the function will return the value of tokens needed to parse the given +string. This can be useful if you don't know yet how many tokens to allocate. + +If something goes wrong, you will get an error. Error will be one of these: + +* `JSMN_ERROR_INVAL` - bad token, JSON string is corrupted +* `JSMN_ERROR_NOMEM` - not enough tokens, JSON string is too large +* `JSMN_ERROR_PART` - JSON string is too short, expecting more JSON data + +If you get `JSON_ERROR_NOMEM`, you can re-allocate more tokens and call +`jsmn_parse` once more. If you read json data from the stream, you can +periodically call `jsmn_parse` and check if return value is `JSON_ERROR_PART`. +You will get this error until you reach the end of JSON data. + +Other info +---------- + +This software is distributed under [MIT license](http://www.opensource.org/licenses/mit-license.php), + so feel free to integrate it in your commercial products. + +[1]: http://www.json.org/ +[2]: https://bitbucket.org/zserge/jsmn/wiki/Home +[3]: http://zserge.com/jsmn.html diff --git a/contrib/ntp/libjsmn/example/jsondump.c b/contrib/ntp/libjsmn/example/jsondump.c new file mode 100644 index 000000000..3490bbf49 --- /dev/null +++ b/contrib/ntp/libjsmn/example/jsondump.c @@ -0,0 +1,112 @@ +#include +#include +#include +#include +#include "../jsmn.h" + +/* + * An example of reading JSON from stdin and printing its content to stdout. + * The output looks like YAML, but I'm not sure if it's really compatible. + */ + +static int dump(const char *js, jsmntok_t *t, size_t count, int indent) { + int i, j, k; + if (count == 0) { + return 0; + } + if (t->type == JSMN_PRIMITIVE) { + printf("%.*s", t->end - t->start, js+t->start); + return 1; + } else if (t->type == JSMN_STRING) { + printf("'%.*s'", t->end - t->start, js+t->start); + return 1; + } else if (t->type == JSMN_OBJECT) { + printf("\n"); + j = 0; + for (i = 0; i < t->size; i++) { + for (k = 0; k < indent; k++) printf(" "); + j += dump(js, t+1+j, count-j, indent+1); + printf(": "); + j += dump(js, t+1+j, count-j, indent+1); + printf("\n"); + } + return j+1; + } else if (t->type == JSMN_ARRAY) { + j = 0; + printf("\n"); + for (i = 0; i < t->size; i++) { + for (k = 0; k < indent-1; k++) printf(" "); + printf(" - "); + j += dump(js, t+1+j, count-j, indent+1); + printf("\n"); + } + return j+1; + } + return 0; +} + +int main() { + int r; + int eof_expected = 0; + char *js = NULL; + size_t jslen = 0; + char buf[BUFSIZ]; + + jsmn_parser p; + jsmntok_t *tok; + size_t tokcount = 2; + + /* Prepare parser */ + jsmn_init(&p); + + /* Allocate some tokens as a start */ + tok = malloc(sizeof(*tok) * tokcount); + if (tok == NULL) { + fprintf(stderr, "malloc(): errno=%d\n", errno); + return 3; + } + + for (;;) { + /* Read another chunk */ + r = fread(buf, 1, sizeof(buf), stdin); + if (r < 0) { + fprintf(stderr, "fread(): %d, errno=%d\n", r, errno); + return 1; + } + if (r == 0) { + if (eof_expected != 0) { + return 0; + } else { + fprintf(stderr, "fread(): unexpected EOF\n"); + return 2; + } + } + + js = realloc(js, jslen + r + 1); + if (js == NULL) { + fprintf(stderr, "realloc(): errno=%d\n", errno); + return 3; + } + strncpy(js + jslen, buf, r); + jslen = jslen + r; + +again: + r = jsmn_parse(&p, js, jslen, tok, tokcount); + if (r < 0) { + if (r == JSMN_ERROR_NOMEM) { + tokcount = tokcount * 2; + tok = realloc(tok, sizeof(*tok) * tokcount); + if (tok == NULL) { + fprintf(stderr, "realloc(): errno=%d\n", errno); + return 3; + } + goto again; + } + } else { + dump(js, tok, p.toknext, 0); + eof_expected = 1; + } + } + + return 0; +} diff --git a/contrib/ntp/libjsmn/example/simple.c b/contrib/ntp/libjsmn/example/simple.c new file mode 100644 index 000000000..a6f8e6a98 --- /dev/null +++ b/contrib/ntp/libjsmn/example/simple.c @@ -0,0 +1,75 @@ +#include +#include +#include "../jsmn.h" + +/* + * A small example of jsmn parsing when JSON structure is known and number of + * tokens is predictable. + */ + +const char *JSON_STRING = + "{\"user\": \"johndoe\", \"admin\": false, \"uid\": 1000,\n " + "\"groups\": [\"users\", \"wheel\", \"audio\", \"video\"]}"; + +static int jsoneq(const char *json, jsmntok_t *tok, const char *s) { + if (tok->type == JSMN_STRING && (int) strlen(s) == tok->end - tok->start && + strncmp(json + tok->start, s, tok->end - tok->start) == 0) { + return 0; + } + return -1; +} + +int main() { + int i; + int r; + jsmn_parser p; + jsmntok_t t[128]; /* We expect no more than 128 tokens */ + + jsmn_init(&p); + r = jsmn_parse(&p, JSON_STRING, strlen(JSON_STRING), t, sizeof(t)/sizeof(t[0])); + if (r < 0) { + printf("Failed to parse JSON: %d\n", r); + return 1; + } + + /* Assume the top-level element is an object */ + if (r < 1 || t[0].type != JSMN_OBJECT) { + printf("Object expected\n"); + return 1; + } + + /* Loop over all keys of the root object */ + for (i = 1; i < r; i++) { + if (jsoneq(JSON_STRING, &t[i], "user") == 0) { + /* We may use strndup() to fetch string value */ + printf("- User: %.*s\n", t[i+1].end-t[i+1].start, + JSON_STRING + t[i+1].start); + i++; + } else if (jsoneq(JSON_STRING, &t[i], "admin") == 0) { + /* We may additionally check if the value is either "true" or "false" */ + printf("- Admin: %.*s\n", t[i+1].end-t[i+1].start, + JSON_STRING + t[i+1].start); + i++; + } else if (jsoneq(JSON_STRING, &t[i], "uid") == 0) { + /* We may want to do strtol() here to get numeric value */ + printf("- UID: %.*s\n", t[i+1].end-t[i+1].start, + JSON_STRING + t[i+1].start); + i++; + } else if (jsoneq(JSON_STRING, &t[i], "groups") == 0) { + int j; + printf("- Groups:\n"); + if (t[i+1].type != JSMN_ARRAY) { + continue; /* We expect groups to be an array of strings */ + } + for (j = 0; j < t[i+1].size; j++) { + jsmntok_t *g = &t[i+j+2]; + printf(" * %.*s\n", g->end - g->start, JSON_STRING + g->start); + } + i += t[i+1].size + 1; + } else { + printf("Unexpected key: %.*s\n", t[i].end-t[i].start, + JSON_STRING + t[i].start); + } + } + return 0; +} diff --git a/contrib/ntp/libjsmn/jsmn.c b/contrib/ntp/libjsmn/jsmn.c new file mode 100644 index 000000000..2e88fe140 --- /dev/null +++ b/contrib/ntp/libjsmn/jsmn.c @@ -0,0 +1,312 @@ +#include + +#include "jsmn.h" + +/** + * Allocates a fresh unused token from the token pull. + */ +static jsmntok_t *jsmn_alloc_token(jsmn_parser *parser, + jsmntok_t *tokens, size_t num_tokens) { + jsmntok_t *tok; + if (parser->toknext >= num_tokens) { + return NULL; + } + tok = &tokens[parser->toknext++]; + tok->start = tok->end = -1; + tok->size = 0; +#ifdef JSMN_PARENT_LINKS + tok->parent = -1; +#endif + return tok; +} + +/** + * Fills token type and boundaries. + */ +static void jsmn_fill_token(jsmntok_t *token, jsmntype_t type, + int start, int end) { + token->type = type; + token->start = start; + token->end = end; + token->size = 0; +} + +/** + * Fills next available token with JSON primitive. + */ +static jsmnerr_t jsmn_parse_primitive(jsmn_parser *parser, const char *js, + size_t len, jsmntok_t *tokens, size_t num_tokens) { + jsmntok_t *token; + int start; + + start = parser->pos; + + for (; parser->pos < len && js[parser->pos] != '\0'; parser->pos++) { + switch (js[parser->pos]) { +#ifndef JSMN_STRICT + /* In strict mode primitive must be followed by "," or "}" or "]" */ + case ':': +#endif + case '\t' : case '\r' : case '\n' : case ' ' : + case ',' : case ']' : case '}' : + goto found; + } + if (js[parser->pos] < 32 || js[parser->pos] >= 127) { + parser->pos = start; + return JSMN_ERROR_INVAL; + } + } +#ifdef JSMN_STRICT + /* In strict mode primitive must be followed by a comma/object/array */ + parser->pos = start; + return JSMN_ERROR_PART; +#endif + +found: + if (tokens == NULL) { + parser->pos--; + return 0; + } + token = jsmn_alloc_token(parser, tokens, num_tokens); + if (token == NULL) { + parser->pos = start; + return JSMN_ERROR_NOMEM; + } + jsmn_fill_token(token, JSMN_PRIMITIVE, start, parser->pos); +#ifdef JSMN_PARENT_LINKS + token->parent = parser->toksuper; +#endif + parser->pos--; + return 0; +} + +/** + * Filsl next token with JSON string. + */ +static jsmnerr_t jsmn_parse_string(jsmn_parser *parser, const char *js, + size_t len, jsmntok_t *tokens, size_t num_tokens) { + jsmntok_t *token; + + int start = parser->pos; + + parser->pos++; + + /* Skip starting quote */ + for (; parser->pos < len && js[parser->pos] != '\0'; parser->pos++) { + char c = js[parser->pos]; + + /* Quote: end of string */ + if (c == '\"') { + if (tokens == NULL) { + return 0; + } + token = jsmn_alloc_token(parser, tokens, num_tokens); + if (token == NULL) { + parser->pos = start; + return JSMN_ERROR_NOMEM; + } + jsmn_fill_token(token, JSMN_STRING, start+1, parser->pos); +#ifdef JSMN_PARENT_LINKS + token->parent = parser->toksuper; +#endif + return 0; + } + + /* Backslash: Quoted symbol expected */ + if (c == '\\' && parser->pos + 1 < len) { + int i; + parser->pos++; + switch (js[parser->pos]) { + /* Allowed escaped symbols */ + case '\"': case '/' : case '\\' : case 'b' : + case 'f' : case 'r' : case 'n' : case 't' : + break; + /* Allows escaped symbol \uXXXX */ + case 'u': + parser->pos++; + for(i = 0; i < 4 && parser->pos < len && js[parser->pos] != '\0'; i++) { + /* If it isn't a hex character we have an error */ + if(!((js[parser->pos] >= 48 && js[parser->pos] <= 57) || /* 0-9 */ + (js[parser->pos] >= 65 && js[parser->pos] <= 70) || /* A-F */ + (js[parser->pos] >= 97 && js[parser->pos] <= 102))) { /* a-f */ + parser->pos = start; + return JSMN_ERROR_INVAL; + } + parser->pos++; + } + parser->pos--; + break; + /* Unexpected symbol */ + default: + parser->pos = start; + return JSMN_ERROR_INVAL; + } + } + } + parser->pos = start; + return JSMN_ERROR_PART; +} + +/** + * Parse JSON string and fill tokens. + */ +jsmnerr_t jsmn_parse(jsmn_parser *parser, const char *js, size_t len, + jsmntok_t *tokens, unsigned int num_tokens) { + jsmnerr_t r; + int i; + jsmntok_t *token; + int count = 0; + + for (; parser->pos < len && js[parser->pos] != '\0'; parser->pos++) { + char c; + jsmntype_t type; + + c = js[parser->pos]; + switch (c) { + case '{': case '[': + count++; + if (tokens == NULL) { + break; + } + token = jsmn_alloc_token(parser, tokens, num_tokens); + if (token == NULL) + return JSMN_ERROR_NOMEM; + if (parser->toksuper != -1) { + tokens[parser->toksuper].size++; +#ifdef JSMN_PARENT_LINKS + token->parent = parser->toksuper; +#endif + } + token->type = (c == '{' ? JSMN_OBJECT : JSMN_ARRAY); + token->start = parser->pos; + parser->toksuper = parser->toknext - 1; + break; + case '}': case ']': + if (tokens == NULL) + break; + type = (c == '}' ? JSMN_OBJECT : JSMN_ARRAY); +#ifdef JSMN_PARENT_LINKS + if (parser->toknext < 1) { + return JSMN_ERROR_INVAL; + } + token = &tokens[parser->toknext - 1]; + for (;;) { + if (token->start != -1 && token->end == -1) { + if (token->type != type) { + return JSMN_ERROR_INVAL; + } + token->end = parser->pos + 1; + parser->toksuper = token->parent; + break; + } + if (token->parent == -1) { + break; + } + token = &tokens[token->parent]; + } +#else + for (i = parser->toknext - 1; i >= 0; i--) { + token = &tokens[i]; + if (token->start != -1 && token->end == -1) { + if (token->type != type) { + return JSMN_ERROR_INVAL; + } + parser->toksuper = -1; + token->end = parser->pos + 1; + break; + } + } + /* Error if unmatched closing bracket */ + if (i == -1) return JSMN_ERROR_INVAL; + for (; i >= 0; i--) { + token = &tokens[i]; + if (token->start != -1 && token->end == -1) { + parser->toksuper = i; + break; + } + } +#endif + break; + case '\"': + r = jsmn_parse_string(parser, js, len, tokens, num_tokens); + if (r < 0) return r; + count++; + if (parser->toksuper != -1 && tokens != NULL) + tokens[parser->toksuper].size++; + break; + case '\t' : case '\r' : case '\n' : case ' ': + break; + case ':': + parser->toksuper = parser->toknext - 1; + break; + case ',': + if (tokens != NULL && + tokens[parser->toksuper].type != JSMN_ARRAY && + tokens[parser->toksuper].type != JSMN_OBJECT) { +#ifdef JSMN_PARENT_LINKS + parser->toksuper = tokens[parser->toksuper].parent; +#else + for (i = parser->toknext - 1; i >= 0; i--) { + if (tokens[i].type == JSMN_ARRAY || tokens[i].type == JSMN_OBJECT) { + if (tokens[i].start != -1 && tokens[i].end == -1) { + parser->toksuper = i; + break; + } + } + } +#endif + } + break; +#ifdef JSMN_STRICT + /* In strict mode primitives are: numbers and booleans */ + case '-': case '0': case '1' : case '2': case '3' : case '4': + case '5': case '6': case '7' : case '8': case '9': + case 't': case 'f': case 'n' : + /* And they must not be keys of the object */ + if (tokens != NULL) { + jsmntok_t *t = &tokens[parser->toksuper]; + if (t->type == JSMN_OBJECT || + (t->type == JSMN_STRING && t->size != 0)) { + return JSMN_ERROR_INVAL; + } + } +#else + /* In non-strict mode every unquoted value is a primitive */ + default: +#endif + r = jsmn_parse_primitive(parser, js, len, tokens, num_tokens); + if (r < 0) return r; + count++; + if (parser->toksuper != -1 && tokens != NULL) + tokens[parser->toksuper].size++; + break; + +#ifdef JSMN_STRICT + /* Unexpected char in strict mode */ + default: + return JSMN_ERROR_INVAL; +#endif + } + } + if (tokens != NULL) { + for (i = parser->toknext - 1; i >= 0; i--) { + /* Unmatched opened object or array */ + if (tokens[i].start != -1 && tokens[i].end == -1) { + return JSMN_ERROR_PART; + } + } + } + + return count; +} + +/** + * Creates a new parser based over a given buffer with an array of tokens + * available. + */ +void jsmn_init(jsmn_parser *parser) { + parser->pos = 0; + parser->toknext = 0; + parser->toksuper = -1; +} + diff --git a/contrib/ntp/libjsmn/jsmn.h b/contrib/ntp/libjsmn/jsmn.h new file mode 100644 index 000000000..95fb2cabd --- /dev/null +++ b/contrib/ntp/libjsmn/jsmn.h @@ -0,0 +1,75 @@ +#ifndef __JSMN_H_ +#define __JSMN_H_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * JSON type identifier. Basic types are: + * o Object + * o Array + * o String + * o Other primitive: number, boolean (true/false) or null + */ +typedef enum { + JSMN_PRIMITIVE = 0, + JSMN_OBJECT = 1, + JSMN_ARRAY = 2, + JSMN_STRING = 3 +} jsmntype_t; + +typedef enum { + /* Not enough tokens were provided */ + JSMN_ERROR_NOMEM = -1, + /* Invalid character inside JSON string */ + JSMN_ERROR_INVAL = -2, + /* The string is not a full JSON packet, more bytes expected */ + JSMN_ERROR_PART = -3 +} jsmnerr_t; + +/** + * JSON token description. + * @param type type (object, array, string etc.) + * @param start start position in JSON data string + * @param end end position in JSON data string + */ +typedef struct { + jsmntype_t type; + int start; + int end; + int size; +#ifdef JSMN_PARENT_LINKS + int parent; +#endif +} jsmntok_t; + +/** + * JSON parser. Contains an array of token blocks available. Also stores + * the string being parsed now and current position in that string + */ +typedef struct { + unsigned int pos; /* offset in the JSON string */ + unsigned int toknext; /* next token to allocate */ + int toksuper; /* superior token node, e.g parent object or array */ +} jsmn_parser; + +/** + * Create JSON parser over an array of tokens + */ +void jsmn_init(jsmn_parser *parser); + +/** + * Run JSON parser. It parses a JSON data string into and array of tokens, each describing + * a single JSON object. + */ +jsmnerr_t jsmn_parse(jsmn_parser *parser, const char *js, size_t len, + jsmntok_t *tokens, unsigned int num_tokens); + +#ifdef __cplusplus +} +#endif + +#endif /* __JSMN_H_ */ diff --git a/contrib/ntp/libjsmn/jsmn_test.c b/contrib/ntp/libjsmn/jsmn_test.c new file mode 100644 index 000000000..396885922 --- /dev/null +++ b/contrib/ntp/libjsmn/jsmn_test.c @@ -0,0 +1,608 @@ +#include +#include +#include + +static int test_passed = 0; +static int test_failed = 0; + +/* Terminate current test with error */ +#define fail() return __LINE__ + +/* Successfull end of the test case */ +#define done() return 0 + +/* Check single condition */ +#define check(cond) do { if (!(cond)) fail(); } while (0) + +/* Test runner */ +static void test(int (*func)(void), const char *name) { + int r = func(); + if (r == 0) { + test_passed++; + } else { + test_failed++; + printf("FAILED: %s (at line %d)\n", name, r); + } +} + +#define TOKEN_EQ(t, tok_start, tok_end, tok_type) \ + ((t).start == tok_start \ + && (t).end == tok_end \ + && (t).type == (tok_type)) + +#define TOKEN_STRING(js, t, s) \ + (strncmp(js+(t).start, s, (t).end - (t).start) == 0 \ + && strlen(s) == (t).end - (t).start) + +#define TOKEN_PRINT(t) \ + printf("start: %d, end: %d, type: %d, size: %d\n", \ + (t).start, (t).end, (t).type, (t).size) + +#define JSMN_STRICT +#include "jsmn.c" + +int test_empty() { + const char *js; + int r; + jsmn_parser p; + jsmntok_t t[10]; + + js = "{}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), t, 10); + check(r >= 0); + check(t[0].type == JSMN_OBJECT); + check(t[0].start == 0 && t[0].end == 2); + + js = "[]"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), t, 10); + check(r >= 0); + check(t[0].type == JSMN_ARRAY); + check(t[0].start == 0 && t[0].end == 2); + + js = "{\"a\":[]}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), t, 10); + check(r >= 0); + check(t[0].type == JSMN_OBJECT && t[0].start == 0 && t[0].end == 8); + check(t[1].type == JSMN_STRING && t[1].start == 2 && t[1].end == 3); + check(t[2].type == JSMN_ARRAY && t[2].start == 5 && t[2].end == 7); + + js = "[{},{}]"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), t, 10); + check(r >= 0); + check(t[0].type == JSMN_ARRAY && t[0].start == 0 && t[0].end == 7); + check(t[1].type == JSMN_OBJECT && t[1].start == 1 && t[1].end == 3); + check(t[2].type == JSMN_OBJECT && t[2].start == 4 && t[2].end == 6); + return 0; +} + +int test_simple() { + const char *js; + int r; + jsmn_parser p; + jsmntok_t tokens[10]; + + js = "{\"a\": 0}"; + + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + check(TOKEN_EQ(tokens[0], 0, 8, JSMN_OBJECT)); + check(TOKEN_EQ(tokens[1], 2, 3, JSMN_STRING)); + check(TOKEN_EQ(tokens[2], 6, 7, JSMN_PRIMITIVE)); + + check(TOKEN_STRING(js, tokens[0], js)); + check(TOKEN_STRING(js, tokens[1], "a")); + check(TOKEN_STRING(js, tokens[2], "0")); + + jsmn_init(&p); + js = "[\"a\":{},\"b\":{}]"; + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + jsmn_init(&p); + js = "{\n \"Day\": 26,\n \"Month\": 9,\n \"Year\": 12\n }"; + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + return 0; +} + +int test_primitive() { +#ifndef JSMN_STRICT + int r; + jsmn_parser p; + jsmntok_t tok[10]; + const char *js; + js = "\"boolVar\" : true"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_PRIMITIVE); + check(TOKEN_STRING(js, tok[0], "boolVar")); + check(TOKEN_STRING(js, tok[1], "true")); + + js = "\"boolVar\" : false"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_PRIMITIVE); + check(TOKEN_STRING(js, tok[0], "boolVar")); + check(TOKEN_STRING(js, tok[1], "false")); + + js = "\"intVar\" : 12345"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_PRIMITIVE); + check(TOKEN_STRING(js, tok[0], "intVar")); + check(TOKEN_STRING(js, tok[1], "12345")); + + js = "\"floatVar\" : 12.345"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_PRIMITIVE); + check(TOKEN_STRING(js, tok[0], "floatVar")); + check(TOKEN_STRING(js, tok[1], "12.345")); + + js = "\"nullVar\" : null"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_PRIMITIVE); + check(TOKEN_STRING(js, tok[0], "nullVar")); + check(TOKEN_STRING(js, tok[1], "null")); +#endif + return 0; +} + +int test_string() { + int r; + jsmn_parser p; + jsmntok_t tok[10]; + const char *js; + + js = "\"strVar\" : \"hello world\""; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_STRING); + check(TOKEN_STRING(js, tok[0], "strVar")); + check(TOKEN_STRING(js, tok[1], "hello world")); + + js = "\"strVar\" : \"escapes: \\/\\r\\n\\t\\b\\f\\\"\\\\\""; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_STRING); + check(TOKEN_STRING(js, tok[0], "strVar")); + check(TOKEN_STRING(js, tok[1], "escapes: \\/\\r\\n\\t\\b\\f\\\"\\\\")); + + js = "\"strVar\" : \"\""; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_STRING); + check(TOKEN_STRING(js, tok[0], "strVar")); + check(TOKEN_STRING(js, tok[1], "")); + + return 0; +} + +int test_partial_string() { + int r; + jsmn_parser p; + jsmntok_t tok[10]; + const char *js; + + jsmn_init(&p); + js = "\"x\": \"va"; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r == JSMN_ERROR_PART && tok[0].type == JSMN_STRING); + check(TOKEN_STRING(js, tok[0], "x")); + check(p.toknext == 1); + + jsmn_init(&p); + char js_slash[9] = "\"x\": \"va\\"; + r = jsmn_parse(&p, js_slash, sizeof(js_slash), tok, 10); + check(r == JSMN_ERROR_PART); + + jsmn_init(&p); + char js_unicode[10] = "\"x\": \"va\\u"; + r = jsmn_parse(&p, js_unicode, sizeof(js_unicode), tok, 10); + check(r == JSMN_ERROR_PART); + + js = "\"x\": \"valu"; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r == JSMN_ERROR_PART && tok[0].type == JSMN_STRING); + check(TOKEN_STRING(js, tok[0], "x")); + check(p.toknext == 1); + + js = "\"x\": \"value\""; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_STRING); + check(TOKEN_STRING(js, tok[0], "x")); + check(TOKEN_STRING(js, tok[1], "value")); + + js = "\"x\": \"value\", \"y\": \"value y\""; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_STRING + && tok[1].type == JSMN_STRING && tok[2].type == JSMN_STRING + && tok[3].type == JSMN_STRING); + check(TOKEN_STRING(js, tok[0], "x")); + check(TOKEN_STRING(js, tok[1], "value")); + check(TOKEN_STRING(js, tok[2], "y")); + check(TOKEN_STRING(js, tok[3], "value y")); + + return 0; +} + +int test_unquoted_keys() { +#ifndef JSMN_STRICT + int r; + jsmn_parser p; + jsmntok_t tok[10]; + const char *js; + + jsmn_init(&p); + js = "key1: \"value\"\nkey2 : 123"; + + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_PRIMITIVE + && tok[1].type == JSMN_STRING && tok[2].type == JSMN_PRIMITIVE + && tok[3].type == JSMN_PRIMITIVE); + check(TOKEN_STRING(js, tok[0], "key1")); + check(TOKEN_STRING(js, tok[1], "value")); + check(TOKEN_STRING(js, tok[2], "key2")); + check(TOKEN_STRING(js, tok[3], "123")); +#endif + return 0; +} + +int test_partial_array() { + int r; + jsmn_parser p; + jsmntok_t tok[10]; + const char *js; + + jsmn_init(&p); + js = " [ 1, true, "; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r == JSMN_ERROR_PART && tok[0].type == JSMN_ARRAY + && tok[1].type == JSMN_PRIMITIVE && tok[2].type == JSMN_PRIMITIVE); + + js = " [ 1, true, [123, \"hello"; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r == JSMN_ERROR_PART && tok[0].type == JSMN_ARRAY + && tok[1].type == JSMN_PRIMITIVE && tok[2].type == JSMN_PRIMITIVE + && tok[3].type == JSMN_ARRAY && tok[4].type == JSMN_PRIMITIVE); + + js = " [ 1, true, [123, \"hello\"]"; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r == JSMN_ERROR_PART && tok[0].type == JSMN_ARRAY + && tok[1].type == JSMN_PRIMITIVE && tok[2].type == JSMN_PRIMITIVE + && tok[3].type == JSMN_ARRAY && tok[4].type == JSMN_PRIMITIVE + && tok[5].type == JSMN_STRING); + /* check child nodes of the 2nd array */ + check(tok[3].size == 2); + + js = " [ 1, true, [123, \"hello\"]]"; + r = jsmn_parse(&p, js, strlen(js), tok, 10); + check(r >= 0 && tok[0].type == JSMN_ARRAY + && tok[1].type == JSMN_PRIMITIVE && tok[2].type == JSMN_PRIMITIVE + && tok[3].type == JSMN_ARRAY && tok[4].type == JSMN_PRIMITIVE + && tok[5].type == JSMN_STRING); + check(tok[3].size == 2); + check(tok[0].size == 3); + return 0; +} + +int test_array_nomem() { + int i; + int r; + jsmn_parser p; + jsmntok_t toksmall[10], toklarge[10]; + const char *js; + + js = " [ 1, true, [123, \"hello\"]]"; + + for (i = 0; i < 6; i++) { + jsmn_init(&p); + memset(toksmall, 0, sizeof(toksmall)); + memset(toklarge, 0, sizeof(toklarge)); + r = jsmn_parse(&p, js, strlen(js), toksmall, i); + check(r == JSMN_ERROR_NOMEM); + + memcpy(toklarge, toksmall, sizeof(toksmall)); + + r = jsmn_parse(&p, js, strlen(js), toklarge, 10); + check(r >= 0); + + check(toklarge[0].type == JSMN_ARRAY && toklarge[0].size == 3); + check(toklarge[3].type == JSMN_ARRAY && toklarge[3].size == 2); + } + return 0; +} + +int test_objects_arrays() { + int r; + jsmn_parser p; + jsmntok_t tokens[10]; + const char *js; + + js = "[10}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "[10]"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + js = "{\"a\": 1]"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "{\"a\": 1}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + return 0; +} + +int test_issue_22() { + int r; + jsmn_parser p; + jsmntok_t tokens[128]; + const char *js; + + js = "{ \"height\":10, \"layers\":[ { \"data\":[6,6], \"height\":10, " + "\"name\":\"Calque de Tile 1\", \"opacity\":1, \"type\":\"tilelayer\", " + "\"visible\":true, \"width\":10, \"x\":0, \"y\":0 }], " + "\"orientation\":\"orthogonal\", \"properties\": { }, \"tileheight\":32, " + "\"tilesets\":[ { \"firstgid\":1, \"image\":\"..\\/images\\/tiles.png\", " + "\"imageheight\":64, \"imagewidth\":160, \"margin\":0, \"name\":\"Tiles\", " + "\"properties\":{}, \"spacing\":0, \"tileheight\":32, \"tilewidth\":32 }], " + "\"tilewidth\":32, \"version\":1, \"width\":10 }"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 128); + check(r >= 0); +#if 0 + for (i = 1; tokens[i].end < tokens[0].end; i++) { + if (tokens[i].type == JSMN_STRING || tokens[i].type == JSMN_PRIMITIVE) { + printf("%.*s\n", tokens[i].end - tokens[i].start, js + tokens[i].start); + } else if (tokens[i].type == JSMN_ARRAY) { + printf("[%d elems]\n", tokens[i].size); + } else if (tokens[i].type == JSMN_OBJECT) { + printf("{%d elems}\n", tokens[i].size); + } else { + TOKEN_PRINT(tokens[i]); + } + } +#endif + return 0; +} + +int test_unicode_characters() { + jsmn_parser p; + jsmntok_t tokens[10]; + const char *js; + + int r; + js = "{\"a\":\"\\uAbcD\"}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + js = "{\"a\":\"str\\u0000\"}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + js = "{\"a\":\"\\uFFFFstr\"}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + js = "{\"a\":\"str\\uFFGFstr\"}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "{\"a\":\"str\\u@FfF\"}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "{\"a\":[\"\\u028\"]}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "{\"a\":[\"\\u0280\"]}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r >= 0); + + return 0; +} + +int test_input_length() { + const char *js; + int r; + jsmn_parser p; + jsmntok_t tokens[10]; + + js = "{\"a\": 0}garbage"; + + jsmn_init(&p); + r = jsmn_parse(&p, js, 8, tokens, 10); + check(r == 3); + check(TOKEN_STRING(js, tokens[0], "{\"a\": 0}")); + check(TOKEN_STRING(js, tokens[1], "a")); + check(TOKEN_STRING(js, tokens[2], "0")); + + return 0; +} + +int test_count() { + jsmn_parser p; + const char *js; + + js = "{}"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 1); + + js = "[]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 1); + + js = "[[]]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 2); + + js = "[[], []]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 3); + + js = "[[], []]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 3); + + js = "[[], [[]], [[], []]]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 7); + + js = "[\"a\", [[], []]]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 5); + + js = "[[], \"[], [[]]\", [[]]]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 5); + + js = "[1, 2, 3]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 4); + + js = "[1, 2, [3, \"a\"], null]"; + jsmn_init(&p); + check(jsmn_parse(&p, js, strlen(js), NULL, 0) == 7); + + return 0; +} + +int test_keyvalue() { + const char *js; + int r; + jsmn_parser p; + jsmntok_t tokens[10]; + + js = "{\"a\": 0, \"b\": \"c\"}"; + + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == 5); + check(tokens[0].size == 2); /* two keys */ + check(tokens[1].size == 1 && tokens[3].size == 1); /* one value per key */ + check(tokens[2].size == 0 && tokens[4].size == 0); /* values have zero size */ + + js = "{\"a\"\n0}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "{\"a\", 0}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "{\"a\": {2}}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + js = "{\"a\": {2: 3}}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + + + js = "{\"a\": {\"a\": 2 3}}"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == JSMN_ERROR_INVAL); + return 0; +} + +/** A huge redefinition of everything to include jsmn in non-script mode */ +#define jsmn_init jsmn_init_nonstrict +#define jsmn_parse jsmn_parse_nonstrict +#define jsmn_parser jsmn_parser_nonstrict +#define jsmn_alloc_token jsmn_alloc_token_nonstrict +#define jsmn_fill_token jsmn_fill_token_nonstrict +#define jsmn_parse_primitive jsmn_parse_primitive_nonstrict +#define jsmn_parse_string jsmn_parse_string_nonstrict +#define jsmntype_t jsmntype_nonstrict_t +#define jsmnerr_t jsmnerr_nonstrict_t +#define jsmntok_t jsmntok_nonstrict_t +#define JSMN_PRIMITIVE JSMN_PRIMITIVE_NONSTRICT +#define JSMN_OBJECT JSMN_OBJECT_NONSTRICT +#define JSMN_ARRAY JSMN_ARRAY_NONSTRICT +#define JSMN_STRING JSMN_STRING_NONSTRICT +#define JSMN_ERROR_NOMEM JSMN_ERROR_NOMEM_NONSTRICT +#define JSMN_ERROR_INVAL JSMN_ERROR_INVAL_NONSTRICT +#define JSMN_ERROR_PART JSMN_ERROR_PART_NONSTRICT +#undef __JSMN_H_ +#undef JSMN_STRICT +#include "jsmn.c" + +int test_nonstrict() { + const char *js; + int r; + jsmn_parser p; + jsmntok_t tokens[10]; + + js = "a: 0garbage"; + + jsmn_init(&p); + r = jsmn_parse(&p, js, 4, tokens, 10); + check(r == 2); + check(TOKEN_STRING(js, tokens[0], "a")); + check(TOKEN_STRING(js, tokens[1], "0")); + + js = "Day : 26\nMonth : Sep\n\nYear: 12"; + jsmn_init(&p); + r = jsmn_parse(&p, js, strlen(js), tokens, 10); + check(r == 6); + return 0; +} + +int main() { + test(test_empty, "general test for a empty JSON objects/arrays"); + test(test_simple, "general test for a simple JSON string"); + test(test_primitive, "test primitive JSON data types"); + test(test_string, "test string JSON data types"); + test(test_partial_string, "test partial JSON string parsing"); + test(test_partial_array, "test partial array reading"); + test(test_array_nomem, "test array reading with a smaller number of tokens"); + test(test_unquoted_keys, "test unquoted keys (like in JavaScript)"); + test(test_objects_arrays, "test objects and arrays"); + test(test_unicode_characters, "test unicode characters"); + test(test_input_length, "test strings that are not null-terminated"); + test(test_issue_22, "test issue #22"); + test(test_count, "test tokens count estimation"); + test(test_nonstrict, "test for non-strict mode"); + test(test_keyvalue, "test for keys/values"); + printf("\nPASSED: %d\nFAILED: %d\n", test_passed, test_failed); + return 0; +} + diff --git a/contrib/ntp/libntp/Makefile.am b/contrib/ntp/libntp/Makefile.am index 932f87b10..914badb5f 100644 --- a/contrib/ntp/libntp/Makefile.am +++ b/contrib/ntp/libntp/Makefile.am @@ -1,38 +1,127 @@ -#AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL= +BUILT_SOURCES = +CLEANFILES = noinst_LIBRARIES = libntp.a @MAKE_LIBNTPSIM@ EXTRA_LIBRARIES = libntpsim.a -libntp_a_SRCS = a_md5encrypt.c adjtime.c atoint.c atolfp.c atouint.c \ - audio.c authkeys.c authreadkeys.c authusekey.c buftvtots.c \ - caljulian.c caltontp.c calyearstart.c clocktime.c \ - clocktypes.c decodenetnum.c dofptoa.c dolfptoa.c emalloc.c \ - findconfig.c fptoa.c fptoms.c getopt.c hextoint.c \ - hextolfp.c humandate.c icom.c inttoa.c iosignal.c \ - lib_strbuf.c machines.c md5c.c memmove.c mfptoa.c \ - mfptoms.c mktime.c modetoa.c mstolfp.c msutotsf.c msyslog.c netof.c \ - ntp_rfc2553.c numtoa.c numtohost.c octtoint.c prettydate.c \ - ntp_random.c recvbuff.c refnumtoa.c snprintf.c socktoa.c socktohost.c \ - statestr.c strdup.c strerror.c strstr.c \ - syssignal.c tsftomsu.c tstotv.c tvtoa.c tvtots.c \ - uglydate.c uinttoa.c utvtoa.c ymd2yd.c \ - $(srcdir)/../libisc/assertions.c $(srcdir)/../libisc/error.c \ - $(srcdir)/../libisc/interfaceiter.c $(srcdir)/../libisc/lib.c \ - $(srcdir)/../libisc/mem.c $(srcdir)/../libisc/msgcat.c \ - $(srcdir)/../libisc/net.c $(srcdir)/../libisc/isc_strerror.c \ - $(srcdir)/../libisc/inet_ntop.c \ - $(srcdir)/../libisc/inet_pton.c \ - $(srcdir)/../libisc/netaddr.c $(srcdir)/../libisc/sockaddr.c \ - $(srcdir)/../libisc/netscope.c + +libisc_SRCS = \ + $(srcdir)/../lib/isc/assertions.c \ + $(srcdir)/../lib/isc/buffer.c \ + $(srcdir)/../lib/isc/backtrace-emptytbl.c \ + $(srcdir)/../lib/isc/backtrace.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c \ + $(srcdir)/../lib/isc/unix/dir.c \ + $(srcdir)/../lib/isc/error.c \ + $(srcdir)/../lib/isc/unix/errno2result.c \ + $(srcdir)/../lib/isc/event.c \ + $(srcdir)/../lib/isc/unix/file.c \ + $(srcdir)/../lib/isc/inet_ntop.c \ + $(srcdir)/../lib/isc/inet_pton.c \ + $(srcdir)/../lib/isc/unix/interfaceiter.c \ + $(srcdir)/../lib/isc/lib.c \ + $(srcdir)/../lib/isc/log.c \ + $(srcdir)/../lib/isc/md5.c \ + $(srcdir)/../lib/isc/nls/msgcat.c \ + $(srcdir)/../lib/isc/unix/net.c \ + $(srcdir)/../lib/isc/netaddr.c \ + $(srcdir)/../lib/isc/netscope.c \ + $(srcdir)/../lib/isc/ondestroy.c \ + $(srcdir)/../lib/isc/random.c \ + $(srcdir)/../lib/isc/result.c \ + $(srcdir)/../lib/isc/unix/stdio.c \ + $(srcdir)/../lib/isc/unix/stdtime.c \ + $(srcdir)/../lib/isc/unix/strerror.c \ + $(srcdir)/../lib/isc/task.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c \ + $(srcdir)/../lib/isc/unix/time.c \ + $(srcdir)/../lib/isc/sha1.c \ + $(srcdir)/../lib/isc/sockaddr.c \ + $(NULL) + +if PTHREADS +libisc_SRCS += $(srcdir)/../lib/isc/pthreads/mutex.c +endif + +libntp_a_SRCS = \ + a_md5encrypt.c \ + adjtime.c \ + atoint.c \ + atolfp.c \ + atouint.c \ + audio.c \ + authkeys.c \ + authreadkeys.c \ + authusekey.c \ + bsd_strerror.c \ + buftvtots.c \ + caljulian.c \ + caltontp.c \ + calyearstart.c \ + clocktime.c \ + clocktypes.c \ + decodenetnum.c \ + dofptoa.c \ + dolfptoa.c \ + emalloc.c \ + findconfig.c \ + getopt.c \ + hextoint.c \ + hextolfp.c \ + humandate.c \ + icom.c \ + iosignal.c \ + lib_strbuf.c \ + machines.c \ + mktime.c \ + modetoa.c \ + mstolfp.c \ + msyslog.c \ + netof.c \ + ntp_calendar.c \ + ntp_crypto_rnd.c \ + ntp_intres.c \ + ntp_libopts.c \ + ntp_lineedit.c \ + ntp_random.c \ + ntp_rfc2553.c \ + ntp_worker.c \ + numtoa.c \ + numtohost.c \ + octtoint.c \ + prettydate.c \ + refidsmear.c \ + recvbuff.c \ + refnumtoa.c \ + snprintf.c \ + socket.c \ + socktoa.c \ + socktohost.c \ + ssl_init.c \ + statestr.c \ + strdup.c \ + strl_obsd.c \ + syssignal.c \ + timetoa.c \ + timevalops.c \ + uglydate.c \ + vint64ops.c \ + work_fork.c \ + work_thread.c \ + ymd2yd.c \ + $(libisc_SRCS) \ + $(NULL) + libntp_a_SOURCES = systime.c $(libntp_a_SRCS) libntpsim_a_SOURCES = systime_s.c $(libntp_a_SRCS) EXTRA_libntp_a_SOURCES = adjtimex.c -INCLUDES = -I$(top_srcdir)/include -I../include -ETAGS_ARGS = Makefile.am -noinst_HEADERS = lib_strbuf.h +AM_CFLAGS = $(CFLAGS_NTP) -../include/des.h: - touch ../include/des.h +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(LIBOPTS_CFLAGS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) EXTRA_DIST = README +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/libntp/Makefile.in b/contrib/ntp/libntp/Makefile.in index 6b6c33677..6e40cd4cd 100644 --- a/contrib/ntp/libntp/Makefile.in +++ b/contrib/ntp/libntp/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -15,8 +14,62 @@ @SET_MAKE@ - VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -35,121 +88,324 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr +@PTHREADS_TRUE@am__append_1 = $(srcdir)/../lib/isc/pthreads/mutex.c subdir = libntp -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = LIBRARIES = $(noinst_LIBRARIES) ARFLAGS = @ARFLAGS@ +AM_V_AR = $(am__v_AR_@AM_V@) +am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@) +am__v_AR_0 = @echo " AR " $@; +am__v_AR_1 = libntp_a_AR = $(AR) $(ARFLAGS) libntp_a_LIBADD = -am__objects_1 = a_md5encrypt$U.$(OBJEXT) adjtime$U.$(OBJEXT) \ - atoint$U.$(OBJEXT) atolfp$U.$(OBJEXT) atouint$U.$(OBJEXT) \ - audio$U.$(OBJEXT) authkeys$U.$(OBJEXT) \ - authreadkeys$U.$(OBJEXT) authusekey$U.$(OBJEXT) \ - buftvtots$U.$(OBJEXT) caljulian$U.$(OBJEXT) \ - caltontp$U.$(OBJEXT) calyearstart$U.$(OBJEXT) \ - clocktime$U.$(OBJEXT) clocktypes$U.$(OBJEXT) \ - decodenetnum$U.$(OBJEXT) dofptoa$U.$(OBJEXT) \ - dolfptoa$U.$(OBJEXT) emalloc$U.$(OBJEXT) \ - findconfig$U.$(OBJEXT) fptoa$U.$(OBJEXT) fptoms$U.$(OBJEXT) \ - getopt$U.$(OBJEXT) hextoint$U.$(OBJEXT) hextolfp$U.$(OBJEXT) \ - humandate$U.$(OBJEXT) icom$U.$(OBJEXT) inttoa$U.$(OBJEXT) \ - iosignal$U.$(OBJEXT) lib_strbuf$U.$(OBJEXT) \ - machines$U.$(OBJEXT) md5c$U.$(OBJEXT) memmove$U.$(OBJEXT) \ - mfptoa$U.$(OBJEXT) mfptoms$U.$(OBJEXT) mktime$U.$(OBJEXT) \ - modetoa$U.$(OBJEXT) mstolfp$U.$(OBJEXT) msutotsf$U.$(OBJEXT) \ - msyslog$U.$(OBJEXT) netof$U.$(OBJEXT) ntp_rfc2553$U.$(OBJEXT) \ - numtoa$U.$(OBJEXT) numtohost$U.$(OBJEXT) octtoint$U.$(OBJEXT) \ - prettydate$U.$(OBJEXT) ntp_random$U.$(OBJEXT) \ - recvbuff$U.$(OBJEXT) refnumtoa$U.$(OBJEXT) \ - snprintf$U.$(OBJEXT) socktoa$U.$(OBJEXT) \ - socktohost$U.$(OBJEXT) statestr$U.$(OBJEXT) strdup$U.$(OBJEXT) \ - strerror$U.$(OBJEXT) strstr$U.$(OBJEXT) syssignal$U.$(OBJEXT) \ - tsftomsu$U.$(OBJEXT) tstotv$U.$(OBJEXT) tvtoa$U.$(OBJEXT) \ - tvtots$U.$(OBJEXT) uglydate$U.$(OBJEXT) uinttoa$U.$(OBJEXT) \ - utvtoa$U.$(OBJEXT) ymd2yd$U.$(OBJEXT) assertions$U.$(OBJEXT) \ - error$U.$(OBJEXT) interfaceiter$U.$(OBJEXT) lib$U.$(OBJEXT) \ - mem$U.$(OBJEXT) msgcat$U.$(OBJEXT) net$U.$(OBJEXT) \ - isc_strerror$U.$(OBJEXT) inet_ntop$U.$(OBJEXT) \ - inet_pton$U.$(OBJEXT) netaddr$U.$(OBJEXT) sockaddr$U.$(OBJEXT) \ - netscope$U.$(OBJEXT) -am_libntp_a_OBJECTS = systime$U.$(OBJEXT) $(am__objects_1) +am__libntp_a_SOURCES_DIST = systime.c a_md5encrypt.c adjtime.c \ + atoint.c atolfp.c atouint.c audio.c authkeys.c authreadkeys.c \ + authusekey.c bsd_strerror.c buftvtots.c caljulian.c caltontp.c \ + calyearstart.c clocktime.c clocktypes.c decodenetnum.c \ + dofptoa.c dolfptoa.c emalloc.c findconfig.c getopt.c \ + hextoint.c hextolfp.c humandate.c icom.c iosignal.c \ + lib_strbuf.c machines.c mktime.c modetoa.c mstolfp.c msyslog.c \ + netof.c ntp_calendar.c ntp_crypto_rnd.c ntp_intres.c \ + ntp_libopts.c ntp_lineedit.c ntp_random.c ntp_rfc2553.c \ + ntp_worker.c numtoa.c numtohost.c octtoint.c prettydate.c \ + refidsmear.c recvbuff.c refnumtoa.c snprintf.c socket.c \ + socktoa.c socktohost.c ssl_init.c statestr.c strdup.c \ + strl_obsd.c syssignal.c timetoa.c timevalops.c uglydate.c \ + vint64ops.c work_fork.c work_thread.c ymd2yd.c \ + $(srcdir)/../lib/isc/assertions.c \ + $(srcdir)/../lib/isc/buffer.c \ + $(srcdir)/../lib/isc/backtrace-emptytbl.c \ + $(srcdir)/../lib/isc/backtrace.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c \ + $(srcdir)/../lib/isc/unix/dir.c $(srcdir)/../lib/isc/error.c \ + $(srcdir)/../lib/isc/unix/errno2result.c \ + $(srcdir)/../lib/isc/event.c $(srcdir)/../lib/isc/unix/file.c \ + $(srcdir)/../lib/isc/inet_ntop.c \ + $(srcdir)/../lib/isc/inet_pton.c \ + $(srcdir)/../lib/isc/unix/interfaceiter.c \ + $(srcdir)/../lib/isc/lib.c $(srcdir)/../lib/isc/log.c \ + $(srcdir)/../lib/isc/md5.c $(srcdir)/../lib/isc/nls/msgcat.c \ + $(srcdir)/../lib/isc/unix/net.c $(srcdir)/../lib/isc/netaddr.c \ + $(srcdir)/../lib/isc/netscope.c \ + $(srcdir)/../lib/isc/ondestroy.c $(srcdir)/../lib/isc/random.c \ + $(srcdir)/../lib/isc/result.c \ + $(srcdir)/../lib/isc/unix/stdio.c \ + $(srcdir)/../lib/isc/unix/stdtime.c \ + $(srcdir)/../lib/isc/unix/strerror.c \ + $(srcdir)/../lib/isc/task.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c \ + $(srcdir)/../lib/isc/unix/time.c $(srcdir)/../lib/isc/sha1.c \ + $(srcdir)/../lib/isc/sockaddr.c \ + $(srcdir)/../lib/isc/pthreads/mutex.c +am__objects_1 = +@PTHREADS_TRUE@am__objects_2 = mutex.$(OBJEXT) +am__objects_3 = assertions.$(OBJEXT) buffer.$(OBJEXT) \ + backtrace-emptytbl.$(OBJEXT) backtrace.$(OBJEXT) \ + condition.$(OBJEXT) dir.$(OBJEXT) error.$(OBJEXT) \ + errno2result.$(OBJEXT) event.$(OBJEXT) file.$(OBJEXT) \ + inet_ntop.$(OBJEXT) inet_pton.$(OBJEXT) \ + interfaceiter.$(OBJEXT) lib.$(OBJEXT) log.$(OBJEXT) \ + md5.$(OBJEXT) msgcat.$(OBJEXT) net.$(OBJEXT) netaddr.$(OBJEXT) \ + netscope.$(OBJEXT) ondestroy.$(OBJEXT) random.$(OBJEXT) \ + result.$(OBJEXT) stdio.$(OBJEXT) stdtime.$(OBJEXT) \ + strerror.$(OBJEXT) task.$(OBJEXT) thread.$(OBJEXT) \ + time.$(OBJEXT) sha1.$(OBJEXT) sockaddr.$(OBJEXT) \ + $(am__objects_1) $(am__objects_2) +am__objects_4 = a_md5encrypt.$(OBJEXT) adjtime.$(OBJEXT) \ + atoint.$(OBJEXT) atolfp.$(OBJEXT) atouint.$(OBJEXT) \ + audio.$(OBJEXT) authkeys.$(OBJEXT) authreadkeys.$(OBJEXT) \ + authusekey.$(OBJEXT) bsd_strerror.$(OBJEXT) \ + buftvtots.$(OBJEXT) caljulian.$(OBJEXT) caltontp.$(OBJEXT) \ + calyearstart.$(OBJEXT) clocktime.$(OBJEXT) \ + clocktypes.$(OBJEXT) decodenetnum.$(OBJEXT) dofptoa.$(OBJEXT) \ + dolfptoa.$(OBJEXT) emalloc.$(OBJEXT) findconfig.$(OBJEXT) \ + getopt.$(OBJEXT) hextoint.$(OBJEXT) hextolfp.$(OBJEXT) \ + humandate.$(OBJEXT) icom.$(OBJEXT) iosignal.$(OBJEXT) \ + lib_strbuf.$(OBJEXT) machines.$(OBJEXT) mktime.$(OBJEXT) \ + modetoa.$(OBJEXT) mstolfp.$(OBJEXT) msyslog.$(OBJEXT) \ + netof.$(OBJEXT) ntp_calendar.$(OBJEXT) \ + ntp_crypto_rnd.$(OBJEXT) ntp_intres.$(OBJEXT) \ + ntp_libopts.$(OBJEXT) ntp_lineedit.$(OBJEXT) \ + ntp_random.$(OBJEXT) ntp_rfc2553.$(OBJEXT) \ + ntp_worker.$(OBJEXT) numtoa.$(OBJEXT) numtohost.$(OBJEXT) \ + octtoint.$(OBJEXT) prettydate.$(OBJEXT) refidsmear.$(OBJEXT) \ + recvbuff.$(OBJEXT) refnumtoa.$(OBJEXT) snprintf.$(OBJEXT) \ + socket.$(OBJEXT) socktoa.$(OBJEXT) socktohost.$(OBJEXT) \ + ssl_init.$(OBJEXT) statestr.$(OBJEXT) strdup.$(OBJEXT) \ + strl_obsd.$(OBJEXT) syssignal.$(OBJEXT) timetoa.$(OBJEXT) \ + timevalops.$(OBJEXT) uglydate.$(OBJEXT) vint64ops.$(OBJEXT) \ + work_fork.$(OBJEXT) work_thread.$(OBJEXT) ymd2yd.$(OBJEXT) \ + $(am__objects_3) $(am__objects_1) +am_libntp_a_OBJECTS = systime.$(OBJEXT) $(am__objects_4) libntp_a_OBJECTS = $(am_libntp_a_OBJECTS) libntpsim_a_AR = $(AR) $(ARFLAGS) libntpsim_a_LIBADD = -am_libntpsim_a_OBJECTS = systime_s$U.$(OBJEXT) $(am__objects_1) +am__libntpsim_a_SOURCES_DIST = systime_s.c a_md5encrypt.c adjtime.c \ + atoint.c atolfp.c atouint.c audio.c authkeys.c authreadkeys.c \ + authusekey.c bsd_strerror.c buftvtots.c caljulian.c caltontp.c \ + calyearstart.c clocktime.c clocktypes.c decodenetnum.c \ + dofptoa.c dolfptoa.c emalloc.c findconfig.c getopt.c \ + hextoint.c hextolfp.c humandate.c icom.c iosignal.c \ + lib_strbuf.c machines.c mktime.c modetoa.c mstolfp.c msyslog.c \ + netof.c ntp_calendar.c ntp_crypto_rnd.c ntp_intres.c \ + ntp_libopts.c ntp_lineedit.c ntp_random.c ntp_rfc2553.c \ + ntp_worker.c numtoa.c numtohost.c octtoint.c prettydate.c \ + refidsmear.c recvbuff.c refnumtoa.c snprintf.c socket.c \ + socktoa.c socktohost.c ssl_init.c statestr.c strdup.c \ + strl_obsd.c syssignal.c timetoa.c timevalops.c uglydate.c \ + vint64ops.c work_fork.c work_thread.c ymd2yd.c \ + $(srcdir)/../lib/isc/assertions.c \ + $(srcdir)/../lib/isc/buffer.c \ + $(srcdir)/../lib/isc/backtrace-emptytbl.c \ + $(srcdir)/../lib/isc/backtrace.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c \ + $(srcdir)/../lib/isc/unix/dir.c $(srcdir)/../lib/isc/error.c \ + $(srcdir)/../lib/isc/unix/errno2result.c \ + $(srcdir)/../lib/isc/event.c $(srcdir)/../lib/isc/unix/file.c \ + $(srcdir)/../lib/isc/inet_ntop.c \ + $(srcdir)/../lib/isc/inet_pton.c \ + $(srcdir)/../lib/isc/unix/interfaceiter.c \ + $(srcdir)/../lib/isc/lib.c $(srcdir)/../lib/isc/log.c \ + $(srcdir)/../lib/isc/md5.c $(srcdir)/../lib/isc/nls/msgcat.c \ + $(srcdir)/../lib/isc/unix/net.c $(srcdir)/../lib/isc/netaddr.c \ + $(srcdir)/../lib/isc/netscope.c \ + $(srcdir)/../lib/isc/ondestroy.c $(srcdir)/../lib/isc/random.c \ + $(srcdir)/../lib/isc/result.c \ + $(srcdir)/../lib/isc/unix/stdio.c \ + $(srcdir)/../lib/isc/unix/stdtime.c \ + $(srcdir)/../lib/isc/unix/strerror.c \ + $(srcdir)/../lib/isc/task.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c \ + $(srcdir)/../lib/isc/unix/time.c $(srcdir)/../lib/isc/sha1.c \ + $(srcdir)/../lib/isc/sockaddr.c \ + $(srcdir)/../lib/isc/pthreads/mutex.c +am_libntpsim_a_OBJECTS = systime_s.$(OBJEXT) $(am__objects_4) libntpsim_a_OBJECTS = $(am_libntpsim_a_OBJECTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = SOURCES = $(libntp_a_SOURCES) $(EXTRA_libntp_a_SOURCES) \ $(libntpsim_a_SOURCES) -DIST_SOURCES = $(libntp_a_SOURCES) $(EXTRA_libntp_a_SOURCES) \ - $(libntpsim_a_SOURCES) -HEADERS = $(noinst_HEADERS) +DIST_SOURCES = $(am__libntp_a_SOURCES_DIST) $(EXTRA_libntp_a_SOURCES) \ + $(am__libntpsim_a_SOURCES_DIST) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depsver.mf \ + $(top_srcdir)/includes.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -157,8 +413,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -168,15 +427,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -184,23 +504,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -247,45 +603,119 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +BUILT_SOURCES = .deps-ver +CLEANFILES = .deps-ver noinst_LIBRARIES = libntp.a @MAKE_LIBNTPSIM@ EXTRA_LIBRARIES = libntpsim.a -libntp_a_SRCS = a_md5encrypt.c adjtime.c atoint.c atolfp.c atouint.c \ - audio.c authkeys.c authreadkeys.c authusekey.c buftvtots.c \ - caljulian.c caltontp.c calyearstart.c clocktime.c \ - clocktypes.c decodenetnum.c dofptoa.c dolfptoa.c emalloc.c \ - findconfig.c fptoa.c fptoms.c getopt.c hextoint.c \ - hextolfp.c humandate.c icom.c inttoa.c iosignal.c \ - lib_strbuf.c machines.c md5c.c memmove.c mfptoa.c \ - mfptoms.c mktime.c modetoa.c mstolfp.c msutotsf.c msyslog.c netof.c \ - ntp_rfc2553.c numtoa.c numtohost.c octtoint.c prettydate.c \ - ntp_random.c recvbuff.c refnumtoa.c snprintf.c socktoa.c socktohost.c \ - statestr.c strdup.c strerror.c strstr.c \ - syssignal.c tsftomsu.c tstotv.c tvtoa.c tvtots.c \ - uglydate.c uinttoa.c utvtoa.c ymd2yd.c \ - $(srcdir)/../libisc/assertions.c $(srcdir)/../libisc/error.c \ - $(srcdir)/../libisc/interfaceiter.c $(srcdir)/../libisc/lib.c \ - $(srcdir)/../libisc/mem.c $(srcdir)/../libisc/msgcat.c \ - $(srcdir)/../libisc/net.c $(srcdir)/../libisc/isc_strerror.c \ - $(srcdir)/../libisc/inet_ntop.c \ - $(srcdir)/../libisc/inet_pton.c \ - $(srcdir)/../libisc/netaddr.c $(srcdir)/../libisc/sockaddr.c \ - $(srcdir)/../libisc/netscope.c +libisc_SRCS = $(srcdir)/../lib/isc/assertions.c \ + $(srcdir)/../lib/isc/buffer.c \ + $(srcdir)/../lib/isc/backtrace-emptytbl.c \ + $(srcdir)/../lib/isc/backtrace.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c \ + $(srcdir)/../lib/isc/unix/dir.c $(srcdir)/../lib/isc/error.c \ + $(srcdir)/../lib/isc/unix/errno2result.c \ + $(srcdir)/../lib/isc/event.c $(srcdir)/../lib/isc/unix/file.c \ + $(srcdir)/../lib/isc/inet_ntop.c \ + $(srcdir)/../lib/isc/inet_pton.c \ + $(srcdir)/../lib/isc/unix/interfaceiter.c \ + $(srcdir)/../lib/isc/lib.c $(srcdir)/../lib/isc/log.c \ + $(srcdir)/../lib/isc/md5.c $(srcdir)/../lib/isc/nls/msgcat.c \ + $(srcdir)/../lib/isc/unix/net.c $(srcdir)/../lib/isc/netaddr.c \ + $(srcdir)/../lib/isc/netscope.c \ + $(srcdir)/../lib/isc/ondestroy.c $(srcdir)/../lib/isc/random.c \ + $(srcdir)/../lib/isc/result.c \ + $(srcdir)/../lib/isc/unix/stdio.c \ + $(srcdir)/../lib/isc/unix/stdtime.c \ + $(srcdir)/../lib/isc/unix/strerror.c \ + $(srcdir)/../lib/isc/task.c \ + $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c \ + $(srcdir)/../lib/isc/unix/time.c $(srcdir)/../lib/isc/sha1.c \ + $(srcdir)/../lib/isc/sockaddr.c $(NULL) $(am__append_1) +libntp_a_SRCS = \ + a_md5encrypt.c \ + adjtime.c \ + atoint.c \ + atolfp.c \ + atouint.c \ + audio.c \ + authkeys.c \ + authreadkeys.c \ + authusekey.c \ + bsd_strerror.c \ + buftvtots.c \ + caljulian.c \ + caltontp.c \ + calyearstart.c \ + clocktime.c \ + clocktypes.c \ + decodenetnum.c \ + dofptoa.c \ + dolfptoa.c \ + emalloc.c \ + findconfig.c \ + getopt.c \ + hextoint.c \ + hextolfp.c \ + humandate.c \ + icom.c \ + iosignal.c \ + lib_strbuf.c \ + machines.c \ + mktime.c \ + modetoa.c \ + mstolfp.c \ + msyslog.c \ + netof.c \ + ntp_calendar.c \ + ntp_crypto_rnd.c \ + ntp_intres.c \ + ntp_libopts.c \ + ntp_lineedit.c \ + ntp_random.c \ + ntp_rfc2553.c \ + ntp_worker.c \ + numtoa.c \ + numtohost.c \ + octtoint.c \ + prettydate.c \ + refidsmear.c \ + recvbuff.c \ + refnumtoa.c \ + snprintf.c \ + socket.c \ + socktoa.c \ + socktohost.c \ + ssl_init.c \ + statestr.c \ + strdup.c \ + strl_obsd.c \ + syssignal.c \ + timetoa.c \ + timevalops.c \ + uglydate.c \ + vint64ops.c \ + work_fork.c \ + work_thread.c \ + ymd2yd.c \ + $(libisc_SRCS) \ + $(NULL) libntp_a_SOURCES = systime.c $(libntp_a_SRCS) libntpsim_a_SOURCES = systime_s.c $(libntp_a_SRCS) EXTRA_libntp_a_SOURCES = adjtimex.c -INCLUDES = -I$(top_srcdir)/include -I../include -ETAGS_ARGS = Makefile.am -noinst_HEADERS = lib_strbuf.h +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(LIBOPTS_CFLAGS) $(CPPFLAGS_NTP) EXTRA_DIST = README -all: all-am +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -297,7 +727,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign libntp/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign libntp/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -306,6 +735,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -318,696 +748,592 @@ $(am__aclocal_m4_deps): clean-noinstLIBRARIES: -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) -libntp.a: $(libntp_a_OBJECTS) $(libntp_a_DEPENDENCIES) - -rm -f libntp.a - $(libntp_a_AR) libntp.a $(libntp_a_OBJECTS) $(libntp_a_LIBADD) - $(RANLIB) libntp.a -libntpsim.a: $(libntpsim_a_OBJECTS) $(libntpsim_a_DEPENDENCIES) - -rm -f libntpsim.a - $(libntpsim_a_AR) libntpsim.a $(libntpsim_a_OBJECTS) $(libntpsim_a_LIBADD) - $(RANLIB) libntpsim.a + +libntp.a: $(libntp_a_OBJECTS) $(libntp_a_DEPENDENCIES) $(EXTRA_libntp_a_DEPENDENCIES) + $(AM_V_at)-rm -f libntp.a + $(AM_V_AR)$(libntp_a_AR) libntp.a $(libntp_a_OBJECTS) $(libntp_a_LIBADD) + $(AM_V_at)$(RANLIB) libntp.a + +libntpsim.a: $(libntpsim_a_OBJECTS) $(libntpsim_a_DEPENDENCIES) $(EXTRA_libntpsim_a_DEPENDENCIES) + $(AM_V_at)-rm -f libntpsim.a + $(AM_V_AR)$(libntpsim_a_AR) libntpsim.a $(libntpsim_a_OBJECTS) $(libntpsim_a_LIBADD) + $(AM_V_at)$(RANLIB) libntpsim.a mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/a_md5encrypt$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimex$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/assertions$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atoint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atouint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/audio$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authkeys$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authreadkeys$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authusekey$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buftvtots$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caljulian$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caltontp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/calyearstart$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktypes$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decodenetnum$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dofptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dolfptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/emalloc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/findconfig$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fptoms$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getopt$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextoint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/humandate$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/icom$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_ntop$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_pton$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/interfaceiter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inttoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/iosignal$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/isc_strerror$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib_strbuf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/machines$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/md5c$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mem$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/memmove$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfptoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfptoms$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mktime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/modetoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msgcat$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mstolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msutotsf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msyslog$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/net$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netaddr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netof$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netscope$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_random$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_rfc2553$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtohost$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/octtoint$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/prettydate$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/recvbuff$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refnumtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/snprintf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sockaddr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktohost$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/statestr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strdup$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strerror$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strstr$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syssignal$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime_s$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tsftomsu$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tstotv$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tvtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tvtots$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uglydate$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uinttoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/utvtoa$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ymd2yd$U.Po@am__quote@ + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/a_md5encrypt.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/adjtimex.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/assertions.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atoint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/atouint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/audio.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authkeys.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authreadkeys.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/authusekey.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/backtrace-emptytbl.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/backtrace.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bsd_strerror.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buffer.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buftvtots.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caljulian.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/caltontp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/calyearstart.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clocktypes.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/condition.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/decodenetnum.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dir.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dofptoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dolfptoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/emalloc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/errno2result.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/event.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/file.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/findconfig.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getopt.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextoint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hextolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/humandate.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/icom.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_ntop.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inet_pton.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/interfaceiter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/iosignal.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lib_strbuf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/machines.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/md5.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mktime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/modetoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msgcat.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mstolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msyslog.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mutex.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/net.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netaddr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netof.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netscope.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_calendar.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_crypto_rnd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_intres.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_libopts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_lineedit.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_random.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_rfc2553.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_worker.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numtohost.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/octtoint.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ondestroy.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/prettydate.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/random.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/recvbuff.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refidsmear.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refnumtoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/result.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sha1.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/snprintf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sockaddr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socket.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socktohost.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ssl_init.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/statestr.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stdio.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stdtime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strdup.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strerror.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strl_obsd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syssignal.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/systime_s.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/task.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/thread.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/time.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timetoa.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timevalops.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/uglydate.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vint64ops.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/work_fork.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/work_thread.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ymd2yd.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +assertions.o: $(srcdir)/../lib/isc/assertions.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.o -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.o `test -f '$(srcdir)/../lib/isc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/assertions.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/assertions.Tpo $(DEPDIR)/assertions.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/assertions.c' object='assertions.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.o `test -f '$(srcdir)/../lib/isc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/assertions.c + +assertions.obj: $(srcdir)/../lib/isc/assertions.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.obj -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.obj `if test -f '$(srcdir)/../lib/isc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/assertions.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/assertions.Tpo $(DEPDIR)/assertions.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/assertions.c' object='assertions.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.obj `if test -f '$(srcdir)/../lib/isc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/assertions.c'; fi` + +buffer.o: $(srcdir)/../lib/isc/buffer.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT buffer.o -MD -MP -MF $(DEPDIR)/buffer.Tpo -c -o buffer.o `test -f '$(srcdir)/../lib/isc/buffer.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/buffer.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/buffer.Tpo $(DEPDIR)/buffer.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/buffer.c' object='buffer.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o buffer.o `test -f '$(srcdir)/../lib/isc/buffer.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/buffer.c + +buffer.obj: $(srcdir)/../lib/isc/buffer.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT buffer.obj -MD -MP -MF $(DEPDIR)/buffer.Tpo -c -o buffer.obj `if test -f '$(srcdir)/../lib/isc/buffer.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/buffer.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/buffer.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/buffer.Tpo $(DEPDIR)/buffer.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/buffer.c' object='buffer.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o buffer.obj `if test -f '$(srcdir)/../lib/isc/buffer.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/buffer.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/buffer.c'; fi` -assertions_.o: assertions_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions_.o -MD -MP -MF $(DEPDIR)/assertions_.Tpo -c -o assertions_.o `test -f 'assertions_.c' || echo '$(srcdir)/'`assertions_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions_.Tpo $(DEPDIR)/assertions_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='assertions_.c' object='assertions_.o' libtool=no @AMDEPBACKSLASH@ +backtrace-emptytbl.o: $(srcdir)/../lib/isc/backtrace-emptytbl.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT backtrace-emptytbl.o -MD -MP -MF $(DEPDIR)/backtrace-emptytbl.Tpo -c -o backtrace-emptytbl.o `test -f '$(srcdir)/../lib/isc/backtrace-emptytbl.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/backtrace-emptytbl.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/backtrace-emptytbl.Tpo $(DEPDIR)/backtrace-emptytbl.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/backtrace-emptytbl.c' object='backtrace-emptytbl.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions_.o `test -f 'assertions_.c' || echo '$(srcdir)/'`assertions_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o backtrace-emptytbl.o `test -f '$(srcdir)/../lib/isc/backtrace-emptytbl.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/backtrace-emptytbl.c -assertions_.obj: assertions_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions_.obj -MD -MP -MF $(DEPDIR)/assertions_.Tpo -c -o assertions_.obj `if test -f 'assertions_.c'; then $(CYGPATH_W) 'assertions_.c'; else $(CYGPATH_W) '$(srcdir)/assertions_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions_.Tpo $(DEPDIR)/assertions_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='assertions_.c' object='assertions_.obj' libtool=no @AMDEPBACKSLASH@ +backtrace-emptytbl.obj: $(srcdir)/../lib/isc/backtrace-emptytbl.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT backtrace-emptytbl.obj -MD -MP -MF $(DEPDIR)/backtrace-emptytbl.Tpo -c -o backtrace-emptytbl.obj `if test -f '$(srcdir)/../lib/isc/backtrace-emptytbl.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/backtrace-emptytbl.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/backtrace-emptytbl.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/backtrace-emptytbl.Tpo $(DEPDIR)/backtrace-emptytbl.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/backtrace-emptytbl.c' object='backtrace-emptytbl.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions_.obj `if test -f 'assertions_.c'; then $(CYGPATH_W) 'assertions_.c'; else $(CYGPATH_W) '$(srcdir)/assertions_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o backtrace-emptytbl.obj `if test -f '$(srcdir)/../lib/isc/backtrace-emptytbl.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/backtrace-emptytbl.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/backtrace-emptytbl.c'; fi` -assertions.o: $(srcdir)/../libisc/assertions.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.o -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.o `test -f '$(srcdir)/../libisc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/assertions.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions.Tpo $(DEPDIR)/assertions.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/assertions.c' object='assertions.o' libtool=no @AMDEPBACKSLASH@ +backtrace.o: $(srcdir)/../lib/isc/backtrace.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT backtrace.o -MD -MP -MF $(DEPDIR)/backtrace.Tpo -c -o backtrace.o `test -f '$(srcdir)/../lib/isc/backtrace.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/backtrace.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/backtrace.Tpo $(DEPDIR)/backtrace.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/backtrace.c' object='backtrace.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.o `test -f '$(srcdir)/../libisc/assertions.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/assertions.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o backtrace.o `test -f '$(srcdir)/../lib/isc/backtrace.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/backtrace.c -assertions.obj: $(srcdir)/../libisc/assertions.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT assertions.obj -MD -MP -MF $(DEPDIR)/assertions.Tpo -c -o assertions.obj `if test -f '$(srcdir)/../libisc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/assertions.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/assertions.Tpo $(DEPDIR)/assertions.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/assertions.c' object='assertions.obj' libtool=no @AMDEPBACKSLASH@ +backtrace.obj: $(srcdir)/../lib/isc/backtrace.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT backtrace.obj -MD -MP -MF $(DEPDIR)/backtrace.Tpo -c -o backtrace.obj `if test -f '$(srcdir)/../lib/isc/backtrace.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/backtrace.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/backtrace.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/backtrace.Tpo $(DEPDIR)/backtrace.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/backtrace.c' object='backtrace.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o assertions.obj `if test -f '$(srcdir)/../libisc/assertions.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/assertions.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/assertions.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o backtrace.obj `if test -f '$(srcdir)/../lib/isc/backtrace.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/backtrace.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/backtrace.c'; fi` -error_.o: error_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error_.o -MD -MP -MF $(DEPDIR)/error_.Tpo -c -o error_.o `test -f 'error_.c' || echo '$(srcdir)/'`error_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error_.Tpo $(DEPDIR)/error_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='error_.c' object='error_.o' libtool=no @AMDEPBACKSLASH@ +condition.o: $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT condition.o -MD -MP -MF $(DEPDIR)/condition.Tpo -c -o condition.o `test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/condition.Tpo $(DEPDIR)/condition.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c' object='condition.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error_.o `test -f 'error_.c' || echo '$(srcdir)/'`error_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o condition.o `test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c -error_.obj: error_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error_.obj -MD -MP -MF $(DEPDIR)/error_.Tpo -c -o error_.obj `if test -f 'error_.c'; then $(CYGPATH_W) 'error_.c'; else $(CYGPATH_W) '$(srcdir)/error_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error_.Tpo $(DEPDIR)/error_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='error_.c' object='error_.obj' libtool=no @AMDEPBACKSLASH@ +condition.obj: $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT condition.obj -MD -MP -MF $(DEPDIR)/condition.Tpo -c -o condition.obj `if test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/condition.Tpo $(DEPDIR)/condition.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c' object='condition.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error_.obj `if test -f 'error_.c'; then $(CYGPATH_W) 'error_.c'; else $(CYGPATH_W) '$(srcdir)/error_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o condition.obj `if test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/condition.c'; fi` -error.o: $(srcdir)/../libisc/error.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.o -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.o `test -f '$(srcdir)/../libisc/error.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/error.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error.Tpo $(DEPDIR)/error.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/error.c' object='error.o' libtool=no @AMDEPBACKSLASH@ +dir.o: $(srcdir)/../lib/isc/unix/dir.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dir.o -MD -MP -MF $(DEPDIR)/dir.Tpo -c -o dir.o `test -f '$(srcdir)/../lib/isc/unix/dir.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/dir.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/dir.Tpo $(DEPDIR)/dir.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/dir.c' object='dir.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.o `test -f '$(srcdir)/../libisc/error.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/error.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dir.o `test -f '$(srcdir)/../lib/isc/unix/dir.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/dir.c -error.obj: $(srcdir)/../libisc/error.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.obj -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.obj `if test -f '$(srcdir)/../libisc/error.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/error.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/error.Tpo $(DEPDIR)/error.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/error.c' object='error.obj' libtool=no @AMDEPBACKSLASH@ +dir.obj: $(srcdir)/../lib/isc/unix/dir.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT dir.obj -MD -MP -MF $(DEPDIR)/dir.Tpo -c -o dir.obj `if test -f '$(srcdir)/../lib/isc/unix/dir.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/dir.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/dir.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/dir.Tpo $(DEPDIR)/dir.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/dir.c' object='dir.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.obj `if test -f '$(srcdir)/../libisc/error.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/error.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o dir.obj `if test -f '$(srcdir)/../lib/isc/unix/dir.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/dir.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/dir.c'; fi` -interfaceiter_.o: interfaceiter_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter_.o -MD -MP -MF $(DEPDIR)/interfaceiter_.Tpo -c -o interfaceiter_.o `test -f 'interfaceiter_.c' || echo '$(srcdir)/'`interfaceiter_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter_.Tpo $(DEPDIR)/interfaceiter_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='interfaceiter_.c' object='interfaceiter_.o' libtool=no @AMDEPBACKSLASH@ +error.o: $(srcdir)/../lib/isc/error.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.o -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.o `test -f '$(srcdir)/../lib/isc/error.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/error.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/error.Tpo $(DEPDIR)/error.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/error.c' object='error.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter_.o `test -f 'interfaceiter_.c' || echo '$(srcdir)/'`interfaceiter_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.o `test -f '$(srcdir)/../lib/isc/error.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/error.c -interfaceiter_.obj: interfaceiter_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter_.obj -MD -MP -MF $(DEPDIR)/interfaceiter_.Tpo -c -o interfaceiter_.obj `if test -f 'interfaceiter_.c'; then $(CYGPATH_W) 'interfaceiter_.c'; else $(CYGPATH_W) '$(srcdir)/interfaceiter_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter_.Tpo $(DEPDIR)/interfaceiter_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='interfaceiter_.c' object='interfaceiter_.obj' libtool=no @AMDEPBACKSLASH@ +error.obj: $(srcdir)/../lib/isc/error.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT error.obj -MD -MP -MF $(DEPDIR)/error.Tpo -c -o error.obj `if test -f '$(srcdir)/../lib/isc/error.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/error.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/error.Tpo $(DEPDIR)/error.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/error.c' object='error.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter_.obj `if test -f 'interfaceiter_.c'; then $(CYGPATH_W) 'interfaceiter_.c'; else $(CYGPATH_W) '$(srcdir)/interfaceiter_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o error.obj `if test -f '$(srcdir)/../lib/isc/error.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/error.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/error.c'; fi` -interfaceiter.o: $(srcdir)/../libisc/interfaceiter.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.o -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.o `test -f '$(srcdir)/../libisc/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/interfaceiter.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/interfaceiter.c' object='interfaceiter.o' libtool=no @AMDEPBACKSLASH@ +errno2result.o: $(srcdir)/../lib/isc/unix/errno2result.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT errno2result.o -MD -MP -MF $(DEPDIR)/errno2result.Tpo -c -o errno2result.o `test -f '$(srcdir)/../lib/isc/unix/errno2result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/errno2result.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/errno2result.Tpo $(DEPDIR)/errno2result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/errno2result.c' object='errno2result.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.o `test -f '$(srcdir)/../libisc/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/interfaceiter.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o errno2result.o `test -f '$(srcdir)/../lib/isc/unix/errno2result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/errno2result.c -interfaceiter.obj: $(srcdir)/../libisc/interfaceiter.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.obj -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.obj `if test -f '$(srcdir)/../libisc/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/interfaceiter.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/interfaceiter.c' object='interfaceiter.obj' libtool=no @AMDEPBACKSLASH@ +errno2result.obj: $(srcdir)/../lib/isc/unix/errno2result.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT errno2result.obj -MD -MP -MF $(DEPDIR)/errno2result.Tpo -c -o errno2result.obj `if test -f '$(srcdir)/../lib/isc/unix/errno2result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/errno2result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/errno2result.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/errno2result.Tpo $(DEPDIR)/errno2result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/errno2result.c' object='errno2result.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.obj `if test -f '$(srcdir)/../libisc/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/interfaceiter.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o errno2result.obj `if test -f '$(srcdir)/../lib/isc/unix/errno2result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/errno2result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/errno2result.c'; fi` -lib_.o: lib_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib_.o -MD -MP -MF $(DEPDIR)/lib_.Tpo -c -o lib_.o `test -f 'lib_.c' || echo '$(srcdir)/'`lib_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib_.Tpo $(DEPDIR)/lib_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='lib_.c' object='lib_.o' libtool=no @AMDEPBACKSLASH@ +event.o: $(srcdir)/../lib/isc/event.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT event.o -MD -MP -MF $(DEPDIR)/event.Tpo -c -o event.o `test -f '$(srcdir)/../lib/isc/event.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/event.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/event.Tpo $(DEPDIR)/event.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/event.c' object='event.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib_.o `test -f 'lib_.c' || echo '$(srcdir)/'`lib_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o event.o `test -f '$(srcdir)/../lib/isc/event.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/event.c -lib_.obj: lib_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib_.obj -MD -MP -MF $(DEPDIR)/lib_.Tpo -c -o lib_.obj `if test -f 'lib_.c'; then $(CYGPATH_W) 'lib_.c'; else $(CYGPATH_W) '$(srcdir)/lib_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib_.Tpo $(DEPDIR)/lib_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='lib_.c' object='lib_.obj' libtool=no @AMDEPBACKSLASH@ +event.obj: $(srcdir)/../lib/isc/event.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT event.obj -MD -MP -MF $(DEPDIR)/event.Tpo -c -o event.obj `if test -f '$(srcdir)/../lib/isc/event.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/event.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/event.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/event.Tpo $(DEPDIR)/event.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/event.c' object='event.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib_.obj `if test -f 'lib_.c'; then $(CYGPATH_W) 'lib_.c'; else $(CYGPATH_W) '$(srcdir)/lib_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o event.obj `if test -f '$(srcdir)/../lib/isc/event.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/event.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/event.c'; fi` -lib.o: $(srcdir)/../libisc/lib.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.o -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.o `test -f '$(srcdir)/../libisc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/lib.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/lib.c' object='lib.o' libtool=no @AMDEPBACKSLASH@ +file.o: $(srcdir)/../lib/isc/unix/file.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT file.o -MD -MP -MF $(DEPDIR)/file.Tpo -c -o file.o `test -f '$(srcdir)/../lib/isc/unix/file.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/file.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/file.Tpo $(DEPDIR)/file.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/file.c' object='file.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.o `test -f '$(srcdir)/../libisc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/lib.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o file.o `test -f '$(srcdir)/../lib/isc/unix/file.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/file.c -lib.obj: $(srcdir)/../libisc/lib.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.obj -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.obj `if test -f '$(srcdir)/../libisc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/lib.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/lib.c' object='lib.obj' libtool=no @AMDEPBACKSLASH@ +file.obj: $(srcdir)/../lib/isc/unix/file.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT file.obj -MD -MP -MF $(DEPDIR)/file.Tpo -c -o file.obj `if test -f '$(srcdir)/../lib/isc/unix/file.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/file.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/file.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/file.Tpo $(DEPDIR)/file.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/file.c' object='file.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.obj `if test -f '$(srcdir)/../libisc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/lib.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o file.obj `if test -f '$(srcdir)/../lib/isc/unix/file.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/file.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/file.c'; fi` -mem_.o: mem_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem_.o -MD -MP -MF $(DEPDIR)/mem_.Tpo -c -o mem_.o `test -f 'mem_.c' || echo '$(srcdir)/'`mem_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem_.Tpo $(DEPDIR)/mem_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mem_.c' object='mem_.o' libtool=no @AMDEPBACKSLASH@ +inet_ntop.o: $(srcdir)/../lib/isc/inet_ntop.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.o -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.o `test -f '$(srcdir)/../lib/isc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_ntop.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/inet_ntop.c' object='inet_ntop.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem_.o `test -f 'mem_.c' || echo '$(srcdir)/'`mem_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.o `test -f '$(srcdir)/../lib/isc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_ntop.c -mem_.obj: mem_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem_.obj -MD -MP -MF $(DEPDIR)/mem_.Tpo -c -o mem_.obj `if test -f 'mem_.c'; then $(CYGPATH_W) 'mem_.c'; else $(CYGPATH_W) '$(srcdir)/mem_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem_.Tpo $(DEPDIR)/mem_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mem_.c' object='mem_.obj' libtool=no @AMDEPBACKSLASH@ +inet_ntop.obj: $(srcdir)/../lib/isc/inet_ntop.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.obj -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.obj `if test -f '$(srcdir)/../lib/isc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_ntop.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/inet_ntop.c' object='inet_ntop.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem_.obj `if test -f 'mem_.c'; then $(CYGPATH_W) 'mem_.c'; else $(CYGPATH_W) '$(srcdir)/mem_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.obj `if test -f '$(srcdir)/../lib/isc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_ntop.c'; fi` -mem.o: $(srcdir)/../libisc/mem.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem.o -MD -MP -MF $(DEPDIR)/mem.Tpo -c -o mem.o `test -f '$(srcdir)/../libisc/mem.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/mem.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem.Tpo $(DEPDIR)/mem.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/mem.c' object='mem.o' libtool=no @AMDEPBACKSLASH@ +inet_pton.o: $(srcdir)/../lib/isc/inet_pton.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.o -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.o `test -f '$(srcdir)/../lib/isc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_pton.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/inet_pton.c' object='inet_pton.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem.o `test -f '$(srcdir)/../libisc/mem.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/mem.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.o `test -f '$(srcdir)/../lib/isc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/inet_pton.c -mem.obj: $(srcdir)/../libisc/mem.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mem.obj -MD -MP -MF $(DEPDIR)/mem.Tpo -c -o mem.obj `if test -f '$(srcdir)/../libisc/mem.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/mem.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/mem.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/mem.Tpo $(DEPDIR)/mem.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/mem.c' object='mem.obj' libtool=no @AMDEPBACKSLASH@ +inet_pton.obj: $(srcdir)/../lib/isc/inet_pton.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.obj -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.obj `if test -f '$(srcdir)/../lib/isc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_pton.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/inet_pton.c' object='inet_pton.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mem.obj `if test -f '$(srcdir)/../libisc/mem.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/mem.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/mem.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.obj `if test -f '$(srcdir)/../lib/isc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/inet_pton.c'; fi` -msgcat_.o: msgcat_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat_.o -MD -MP -MF $(DEPDIR)/msgcat_.Tpo -c -o msgcat_.o `test -f 'msgcat_.c' || echo '$(srcdir)/'`msgcat_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat_.Tpo $(DEPDIR)/msgcat_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='msgcat_.c' object='msgcat_.o' libtool=no @AMDEPBACKSLASH@ +interfaceiter.o: $(srcdir)/../lib/isc/unix/interfaceiter.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.o -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.o `test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/interfaceiter.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/interfaceiter.c' object='interfaceiter.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat_.o `test -f 'msgcat_.c' || echo '$(srcdir)/'`msgcat_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.o `test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/interfaceiter.c -msgcat_.obj: msgcat_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat_.obj -MD -MP -MF $(DEPDIR)/msgcat_.Tpo -c -o msgcat_.obj `if test -f 'msgcat_.c'; then $(CYGPATH_W) 'msgcat_.c'; else $(CYGPATH_W) '$(srcdir)/msgcat_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat_.Tpo $(DEPDIR)/msgcat_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='msgcat_.c' object='msgcat_.obj' libtool=no @AMDEPBACKSLASH@ +interfaceiter.obj: $(srcdir)/../lib/isc/unix/interfaceiter.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT interfaceiter.obj -MD -MP -MF $(DEPDIR)/interfaceiter.Tpo -c -o interfaceiter.obj `if test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/interfaceiter.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/interfaceiter.Tpo $(DEPDIR)/interfaceiter.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/interfaceiter.c' object='interfaceiter.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat_.obj `if test -f 'msgcat_.c'; then $(CYGPATH_W) 'msgcat_.c'; else $(CYGPATH_W) '$(srcdir)/msgcat_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o interfaceiter.obj `if test -f '$(srcdir)/../lib/isc/unix/interfaceiter.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/interfaceiter.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/interfaceiter.c'; fi` -msgcat.o: $(srcdir)/../libisc/msgcat.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.o -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.o `test -f '$(srcdir)/../libisc/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/msgcat.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/msgcat.c' object='msgcat.o' libtool=no @AMDEPBACKSLASH@ +lib.o: $(srcdir)/../lib/isc/lib.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.o -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.o `test -f '$(srcdir)/../lib/isc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/lib.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/lib.c' object='lib.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.o `test -f '$(srcdir)/../libisc/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/msgcat.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.o `test -f '$(srcdir)/../lib/isc/lib.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/lib.c -msgcat.obj: $(srcdir)/../libisc/msgcat.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.obj -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.obj `if test -f '$(srcdir)/../libisc/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/msgcat.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/msgcat.c' object='msgcat.obj' libtool=no @AMDEPBACKSLASH@ +lib.obj: $(srcdir)/../lib/isc/lib.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT lib.obj -MD -MP -MF $(DEPDIR)/lib.Tpo -c -o lib.obj `if test -f '$(srcdir)/../lib/isc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/lib.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lib.Tpo $(DEPDIR)/lib.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/lib.c' object='lib.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.obj `if test -f '$(srcdir)/../libisc/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/msgcat.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o lib.obj `if test -f '$(srcdir)/../lib/isc/lib.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/lib.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/lib.c'; fi` -net_.o: net_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net_.o -MD -MP -MF $(DEPDIR)/net_.Tpo -c -o net_.o `test -f 'net_.c' || echo '$(srcdir)/'`net_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net_.Tpo $(DEPDIR)/net_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='net_.c' object='net_.o' libtool=no @AMDEPBACKSLASH@ +log.o: $(srcdir)/../lib/isc/log.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT log.o -MD -MP -MF $(DEPDIR)/log.Tpo -c -o log.o `test -f '$(srcdir)/../lib/isc/log.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/log.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/log.Tpo $(DEPDIR)/log.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/log.c' object='log.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net_.o `test -f 'net_.c' || echo '$(srcdir)/'`net_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o log.o `test -f '$(srcdir)/../lib/isc/log.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/log.c -net_.obj: net_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net_.obj -MD -MP -MF $(DEPDIR)/net_.Tpo -c -o net_.obj `if test -f 'net_.c'; then $(CYGPATH_W) 'net_.c'; else $(CYGPATH_W) '$(srcdir)/net_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net_.Tpo $(DEPDIR)/net_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='net_.c' object='net_.obj' libtool=no @AMDEPBACKSLASH@ +log.obj: $(srcdir)/../lib/isc/log.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT log.obj -MD -MP -MF $(DEPDIR)/log.Tpo -c -o log.obj `if test -f '$(srcdir)/../lib/isc/log.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/log.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/log.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/log.Tpo $(DEPDIR)/log.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/log.c' object='log.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net_.obj `if test -f 'net_.c'; then $(CYGPATH_W) 'net_.c'; else $(CYGPATH_W) '$(srcdir)/net_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o log.obj `if test -f '$(srcdir)/../lib/isc/log.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/log.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/log.c'; fi` -net.o: $(srcdir)/../libisc/net.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.o -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.o `test -f '$(srcdir)/../libisc/net.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/net.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net.Tpo $(DEPDIR)/net.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/net.c' object='net.o' libtool=no @AMDEPBACKSLASH@ +md5.o: $(srcdir)/../lib/isc/md5.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT md5.o -MD -MP -MF $(DEPDIR)/md5.Tpo -c -o md5.o `test -f '$(srcdir)/../lib/isc/md5.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/md5.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/md5.Tpo $(DEPDIR)/md5.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/md5.c' object='md5.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.o `test -f '$(srcdir)/../libisc/net.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/net.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o md5.o `test -f '$(srcdir)/../lib/isc/md5.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/md5.c -net.obj: $(srcdir)/../libisc/net.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.obj -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.obj `if test -f '$(srcdir)/../libisc/net.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/net.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/net.Tpo $(DEPDIR)/net.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/net.c' object='net.obj' libtool=no @AMDEPBACKSLASH@ +md5.obj: $(srcdir)/../lib/isc/md5.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT md5.obj -MD -MP -MF $(DEPDIR)/md5.Tpo -c -o md5.obj `if test -f '$(srcdir)/../lib/isc/md5.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/md5.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/md5.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/md5.Tpo $(DEPDIR)/md5.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/md5.c' object='md5.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.obj `if test -f '$(srcdir)/../libisc/net.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/net.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o md5.obj `if test -f '$(srcdir)/../lib/isc/md5.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/md5.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/md5.c'; fi` -isc_strerror_.o: isc_strerror_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror_.o -MD -MP -MF $(DEPDIR)/isc_strerror_.Tpo -c -o isc_strerror_.o `test -f 'isc_strerror_.c' || echo '$(srcdir)/'`isc_strerror_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror_.Tpo $(DEPDIR)/isc_strerror_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='isc_strerror_.c' object='isc_strerror_.o' libtool=no @AMDEPBACKSLASH@ +msgcat.o: $(srcdir)/../lib/isc/nls/msgcat.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.o -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.o `test -f '$(srcdir)/../lib/isc/nls/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nls/msgcat.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/nls/msgcat.c' object='msgcat.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror_.o `test -f 'isc_strerror_.c' || echo '$(srcdir)/'`isc_strerror_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.o `test -f '$(srcdir)/../lib/isc/nls/msgcat.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/nls/msgcat.c -isc_strerror_.obj: isc_strerror_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror_.obj -MD -MP -MF $(DEPDIR)/isc_strerror_.Tpo -c -o isc_strerror_.obj `if test -f 'isc_strerror_.c'; then $(CYGPATH_W) 'isc_strerror_.c'; else $(CYGPATH_W) '$(srcdir)/isc_strerror_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror_.Tpo $(DEPDIR)/isc_strerror_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='isc_strerror_.c' object='isc_strerror_.obj' libtool=no @AMDEPBACKSLASH@ +msgcat.obj: $(srcdir)/../lib/isc/nls/msgcat.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT msgcat.obj -MD -MP -MF $(DEPDIR)/msgcat.Tpo -c -o msgcat.obj `if test -f '$(srcdir)/../lib/isc/nls/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nls/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nls/msgcat.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/msgcat.Tpo $(DEPDIR)/msgcat.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/nls/msgcat.c' object='msgcat.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror_.obj `if test -f 'isc_strerror_.c'; then $(CYGPATH_W) 'isc_strerror_.c'; else $(CYGPATH_W) '$(srcdir)/isc_strerror_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o msgcat.obj `if test -f '$(srcdir)/../lib/isc/nls/msgcat.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/nls/msgcat.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/nls/msgcat.c'; fi` -isc_strerror.o: $(srcdir)/../libisc/isc_strerror.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror.o -MD -MP -MF $(DEPDIR)/isc_strerror.Tpo -c -o isc_strerror.o `test -f '$(srcdir)/../libisc/isc_strerror.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/isc_strerror.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror.Tpo $(DEPDIR)/isc_strerror.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/isc_strerror.c' object='isc_strerror.o' libtool=no @AMDEPBACKSLASH@ +net.o: $(srcdir)/../lib/isc/unix/net.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.o -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.o `test -f '$(srcdir)/../lib/isc/unix/net.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/net.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/net.Tpo $(DEPDIR)/net.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/net.c' object='net.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror.o `test -f '$(srcdir)/../libisc/isc_strerror.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/isc_strerror.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.o `test -f '$(srcdir)/../lib/isc/unix/net.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/net.c -isc_strerror.obj: $(srcdir)/../libisc/isc_strerror.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT isc_strerror.obj -MD -MP -MF $(DEPDIR)/isc_strerror.Tpo -c -o isc_strerror.obj `if test -f '$(srcdir)/../libisc/isc_strerror.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/isc_strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/isc_strerror.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/isc_strerror.Tpo $(DEPDIR)/isc_strerror.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/isc_strerror.c' object='isc_strerror.obj' libtool=no @AMDEPBACKSLASH@ +net.obj: $(srcdir)/../lib/isc/unix/net.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT net.obj -MD -MP -MF $(DEPDIR)/net.Tpo -c -o net.obj `if test -f '$(srcdir)/../lib/isc/unix/net.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/net.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/net.Tpo $(DEPDIR)/net.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/net.c' object='net.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o isc_strerror.obj `if test -f '$(srcdir)/../libisc/isc_strerror.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/isc_strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/isc_strerror.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o net.obj `if test -f '$(srcdir)/../lib/isc/unix/net.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/net.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/net.c'; fi` -inet_ntop_.o: inet_ntop_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop_.o -MD -MP -MF $(DEPDIR)/inet_ntop_.Tpo -c -o inet_ntop_.o `test -f 'inet_ntop_.c' || echo '$(srcdir)/'`inet_ntop_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop_.Tpo $(DEPDIR)/inet_ntop_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_ntop_.c' object='inet_ntop_.o' libtool=no @AMDEPBACKSLASH@ +netaddr.o: $(srcdir)/../lib/isc/netaddr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.o -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.o `test -f '$(srcdir)/../lib/isc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netaddr.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/netaddr.c' object='netaddr.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop_.o `test -f 'inet_ntop_.c' || echo '$(srcdir)/'`inet_ntop_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.o `test -f '$(srcdir)/../lib/isc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netaddr.c -inet_ntop_.obj: inet_ntop_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop_.obj -MD -MP -MF $(DEPDIR)/inet_ntop_.Tpo -c -o inet_ntop_.obj `if test -f 'inet_ntop_.c'; then $(CYGPATH_W) 'inet_ntop_.c'; else $(CYGPATH_W) '$(srcdir)/inet_ntop_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop_.Tpo $(DEPDIR)/inet_ntop_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_ntop_.c' object='inet_ntop_.obj' libtool=no @AMDEPBACKSLASH@ +netaddr.obj: $(srcdir)/../lib/isc/netaddr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.obj -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.obj `if test -f '$(srcdir)/../lib/isc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netaddr.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/netaddr.c' object='netaddr.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop_.obj `if test -f 'inet_ntop_.c'; then $(CYGPATH_W) 'inet_ntop_.c'; else $(CYGPATH_W) '$(srcdir)/inet_ntop_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.obj `if test -f '$(srcdir)/../lib/isc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netaddr.c'; fi` -inet_ntop.o: $(srcdir)/../libisc/inet_ntop.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.o -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.o `test -f '$(srcdir)/../libisc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_ntop.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_ntop.c' object='inet_ntop.o' libtool=no @AMDEPBACKSLASH@ +netscope.o: $(srcdir)/../lib/isc/netscope.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.o -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.o `test -f '$(srcdir)/../lib/isc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netscope.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/netscope.c' object='netscope.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.o `test -f '$(srcdir)/../libisc/inet_ntop.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_ntop.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.o `test -f '$(srcdir)/../lib/isc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/netscope.c -inet_ntop.obj: $(srcdir)/../libisc/inet_ntop.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_ntop.obj -MD -MP -MF $(DEPDIR)/inet_ntop.Tpo -c -o inet_ntop.obj `if test -f '$(srcdir)/../libisc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_ntop.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_ntop.Tpo $(DEPDIR)/inet_ntop.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_ntop.c' object='inet_ntop.obj' libtool=no @AMDEPBACKSLASH@ +netscope.obj: $(srcdir)/../lib/isc/netscope.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.obj -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.obj `if test -f '$(srcdir)/../lib/isc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netscope.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/netscope.c' object='netscope.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_ntop.obj `if test -f '$(srcdir)/../libisc/inet_ntop.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_ntop.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_ntop.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.obj `if test -f '$(srcdir)/../lib/isc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/netscope.c'; fi` -inet_pton_.o: inet_pton_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton_.o -MD -MP -MF $(DEPDIR)/inet_pton_.Tpo -c -o inet_pton_.o `test -f 'inet_pton_.c' || echo '$(srcdir)/'`inet_pton_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton_.Tpo $(DEPDIR)/inet_pton_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_pton_.c' object='inet_pton_.o' libtool=no @AMDEPBACKSLASH@ +ondestroy.o: $(srcdir)/../lib/isc/ondestroy.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ondestroy.o -MD -MP -MF $(DEPDIR)/ondestroy.Tpo -c -o ondestroy.o `test -f '$(srcdir)/../lib/isc/ondestroy.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/ondestroy.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ondestroy.Tpo $(DEPDIR)/ondestroy.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/ondestroy.c' object='ondestroy.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton_.o `test -f 'inet_pton_.c' || echo '$(srcdir)/'`inet_pton_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ondestroy.o `test -f '$(srcdir)/../lib/isc/ondestroy.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/ondestroy.c -inet_pton_.obj: inet_pton_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton_.obj -MD -MP -MF $(DEPDIR)/inet_pton_.Tpo -c -o inet_pton_.obj `if test -f 'inet_pton_.c'; then $(CYGPATH_W) 'inet_pton_.c'; else $(CYGPATH_W) '$(srcdir)/inet_pton_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton_.Tpo $(DEPDIR)/inet_pton_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='inet_pton_.c' object='inet_pton_.obj' libtool=no @AMDEPBACKSLASH@ +ondestroy.obj: $(srcdir)/../lib/isc/ondestroy.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ondestroy.obj -MD -MP -MF $(DEPDIR)/ondestroy.Tpo -c -o ondestroy.obj `if test -f '$(srcdir)/../lib/isc/ondestroy.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/ondestroy.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/ondestroy.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ondestroy.Tpo $(DEPDIR)/ondestroy.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/ondestroy.c' object='ondestroy.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton_.obj `if test -f 'inet_pton_.c'; then $(CYGPATH_W) 'inet_pton_.c'; else $(CYGPATH_W) '$(srcdir)/inet_pton_.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ondestroy.obj `if test -f '$(srcdir)/../lib/isc/ondestroy.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/ondestroy.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/ondestroy.c'; fi` -inet_pton.o: $(srcdir)/../libisc/inet_pton.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.o -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.o `test -f '$(srcdir)/../libisc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_pton.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_pton.c' object='inet_pton.o' libtool=no @AMDEPBACKSLASH@ +random.o: $(srcdir)/../lib/isc/random.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT random.o -MD -MP -MF $(DEPDIR)/random.Tpo -c -o random.o `test -f '$(srcdir)/../lib/isc/random.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/random.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/random.Tpo $(DEPDIR)/random.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/random.c' object='random.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.o `test -f '$(srcdir)/../libisc/inet_pton.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/inet_pton.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o random.o `test -f '$(srcdir)/../lib/isc/random.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/random.c -inet_pton.obj: $(srcdir)/../libisc/inet_pton.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT inet_pton.obj -MD -MP -MF $(DEPDIR)/inet_pton.Tpo -c -o inet_pton.obj `if test -f '$(srcdir)/../libisc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_pton.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/inet_pton.Tpo $(DEPDIR)/inet_pton.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/inet_pton.c' object='inet_pton.obj' libtool=no @AMDEPBACKSLASH@ +random.obj: $(srcdir)/../lib/isc/random.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT random.obj -MD -MP -MF $(DEPDIR)/random.Tpo -c -o random.obj `if test -f '$(srcdir)/../lib/isc/random.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/random.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/random.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/random.Tpo $(DEPDIR)/random.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/random.c' object='random.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o inet_pton.obj `if test -f '$(srcdir)/../libisc/inet_pton.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/inet_pton.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/inet_pton.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o random.obj `if test -f '$(srcdir)/../lib/isc/random.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/random.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/random.c'; fi` -netaddr_.o: netaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr_.o -MD -MP -MF $(DEPDIR)/netaddr_.Tpo -c -o netaddr_.o `test -f 'netaddr_.c' || echo '$(srcdir)/'`netaddr_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr_.Tpo $(DEPDIR)/netaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netaddr_.c' object='netaddr_.o' libtool=no @AMDEPBACKSLASH@ +result.o: $(srcdir)/../lib/isc/result.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT result.o -MD -MP -MF $(DEPDIR)/result.Tpo -c -o result.o `test -f '$(srcdir)/../lib/isc/result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/result.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/result.Tpo $(DEPDIR)/result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/result.c' object='result.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr_.o `test -f 'netaddr_.c' || echo '$(srcdir)/'`netaddr_.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o result.o `test -f '$(srcdir)/../lib/isc/result.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/result.c -netaddr_.obj: netaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr_.obj -MD -MP -MF $(DEPDIR)/netaddr_.Tpo -c -o netaddr_.obj `if test -f 'netaddr_.c'; then $(CYGPATH_W) 'netaddr_.c'; else $(CYGPATH_W) '$(srcdir)/netaddr_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr_.Tpo $(DEPDIR)/netaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netaddr_.c' object='netaddr_.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr_.obj `if test -f 'netaddr_.c'; then $(CYGPATH_W) 'netaddr_.c'; else $(CYGPATH_W) '$(srcdir)/netaddr_.c'; fi` - -netaddr.o: $(srcdir)/../libisc/netaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.o -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.o `test -f '$(srcdir)/../libisc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netaddr.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netaddr.c' object='netaddr.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.o `test -f '$(srcdir)/../libisc/netaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netaddr.c - -netaddr.obj: $(srcdir)/../libisc/netaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netaddr.obj -MD -MP -MF $(DEPDIR)/netaddr.Tpo -c -o netaddr.obj `if test -f '$(srcdir)/../libisc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netaddr.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netaddr.Tpo $(DEPDIR)/netaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netaddr.c' object='netaddr.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netaddr.obj `if test -f '$(srcdir)/../libisc/netaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netaddr.c'; fi` - -sockaddr_.o: sockaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr_.o -MD -MP -MF $(DEPDIR)/sockaddr_.Tpo -c -o sockaddr_.o `test -f 'sockaddr_.c' || echo '$(srcdir)/'`sockaddr_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr_.Tpo $(DEPDIR)/sockaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='sockaddr_.c' object='sockaddr_.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr_.o `test -f 'sockaddr_.c' || echo '$(srcdir)/'`sockaddr_.c - -sockaddr_.obj: sockaddr_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr_.obj -MD -MP -MF $(DEPDIR)/sockaddr_.Tpo -c -o sockaddr_.obj `if test -f 'sockaddr_.c'; then $(CYGPATH_W) 'sockaddr_.c'; else $(CYGPATH_W) '$(srcdir)/sockaddr_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr_.Tpo $(DEPDIR)/sockaddr_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='sockaddr_.c' object='sockaddr_.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr_.obj `if test -f 'sockaddr_.c'; then $(CYGPATH_W) 'sockaddr_.c'; else $(CYGPATH_W) '$(srcdir)/sockaddr_.c'; fi` - -sockaddr.o: $(srcdir)/../libisc/sockaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.o -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.o `test -f '$(srcdir)/../libisc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/sockaddr.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/sockaddr.c' object='sockaddr.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.o `test -f '$(srcdir)/../libisc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/sockaddr.c - -sockaddr.obj: $(srcdir)/../libisc/sockaddr.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.obj -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.obj `if test -f '$(srcdir)/../libisc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/sockaddr.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/sockaddr.c' object='sockaddr.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.obj `if test -f '$(srcdir)/../libisc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/sockaddr.c'; fi` - -netscope_.o: netscope_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope_.o -MD -MP -MF $(DEPDIR)/netscope_.Tpo -c -o netscope_.o `test -f 'netscope_.c' || echo '$(srcdir)/'`netscope_.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope_.Tpo $(DEPDIR)/netscope_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netscope_.c' object='netscope_.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope_.o `test -f 'netscope_.c' || echo '$(srcdir)/'`netscope_.c - -netscope_.obj: netscope_.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope_.obj -MD -MP -MF $(DEPDIR)/netscope_.Tpo -c -o netscope_.obj `if test -f 'netscope_.c'; then $(CYGPATH_W) 'netscope_.c'; else $(CYGPATH_W) '$(srcdir)/netscope_.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope_.Tpo $(DEPDIR)/netscope_.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='netscope_.c' object='netscope_.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope_.obj `if test -f 'netscope_.c'; then $(CYGPATH_W) 'netscope_.c'; else $(CYGPATH_W) '$(srcdir)/netscope_.c'; fi` - -netscope.o: $(srcdir)/../libisc/netscope.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.o -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.o `test -f '$(srcdir)/../libisc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netscope.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netscope.c' object='netscope.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.o `test -f '$(srcdir)/../libisc/netscope.c' || echo '$(srcdir)/'`$(srcdir)/../libisc/netscope.c - -netscope.obj: $(srcdir)/../libisc/netscope.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT netscope.obj -MD -MP -MF $(DEPDIR)/netscope.Tpo -c -o netscope.obj `if test -f '$(srcdir)/../libisc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netscope.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/netscope.Tpo $(DEPDIR)/netscope.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/../libisc/netscope.c' object='netscope.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o netscope.obj `if test -f '$(srcdir)/../libisc/netscope.c'; then $(CYGPATH_W) '$(srcdir)/../libisc/netscope.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../libisc/netscope.c'; fi` -a_md5encrypt_.c: a_md5encrypt.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/a_md5encrypt.c; then echo $(srcdir)/a_md5encrypt.c; else echo a_md5encrypt.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -adjtime_.c: adjtime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/adjtime.c; then echo $(srcdir)/adjtime.c; else echo adjtime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -adjtimex_.c: adjtimex.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/adjtimex.c; then echo $(srcdir)/adjtimex.c; else echo adjtimex.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -assertions_.c: $(srcdir)/../libisc/assertions.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/assertions.c; then echo $(srcdir)/$(srcdir)/../libisc/assertions.c; else echo $(srcdir)/../libisc/assertions.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -atoint_.c: atoint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/atoint.c; then echo $(srcdir)/atoint.c; else echo atoint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -atolfp_.c: atolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/atolfp.c; then echo $(srcdir)/atolfp.c; else echo atolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -atouint_.c: atouint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/atouint.c; then echo $(srcdir)/atouint.c; else echo atouint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -audio_.c: audio.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/audio.c; then echo $(srcdir)/audio.c; else echo audio.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -authkeys_.c: authkeys.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/authkeys.c; then echo $(srcdir)/authkeys.c; else echo authkeys.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -authreadkeys_.c: authreadkeys.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/authreadkeys.c; then echo $(srcdir)/authreadkeys.c; else echo authreadkeys.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -authusekey_.c: authusekey.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/authusekey.c; then echo $(srcdir)/authusekey.c; else echo authusekey.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -buftvtots_.c: buftvtots.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/buftvtots.c; then echo $(srcdir)/buftvtots.c; else echo buftvtots.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -caljulian_.c: caljulian.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/caljulian.c; then echo $(srcdir)/caljulian.c; else echo caljulian.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -caltontp_.c: caltontp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/caltontp.c; then echo $(srcdir)/caltontp.c; else echo caltontp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -calyearstart_.c: calyearstart.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/calyearstart.c; then echo $(srcdir)/calyearstart.c; else echo calyearstart.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clocktime_.c: clocktime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clocktime.c; then echo $(srcdir)/clocktime.c; else echo clocktime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clocktypes_.c: clocktypes.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clocktypes.c; then echo $(srcdir)/clocktypes.c; else echo clocktypes.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -decodenetnum_.c: decodenetnum.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/decodenetnum.c; then echo $(srcdir)/decodenetnum.c; else echo decodenetnum.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -dofptoa_.c: dofptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/dofptoa.c; then echo $(srcdir)/dofptoa.c; else echo dofptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -dolfptoa_.c: dolfptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/dolfptoa.c; then echo $(srcdir)/dolfptoa.c; else echo dolfptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -emalloc_.c: emalloc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/emalloc.c; then echo $(srcdir)/emalloc.c; else echo emalloc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -error_.c: $(srcdir)/../libisc/error.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/error.c; then echo $(srcdir)/$(srcdir)/../libisc/error.c; else echo $(srcdir)/../libisc/error.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -findconfig_.c: findconfig.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/findconfig.c; then echo $(srcdir)/findconfig.c; else echo findconfig.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -fptoa_.c: fptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/fptoa.c; then echo $(srcdir)/fptoa.c; else echo fptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -fptoms_.c: fptoms.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/fptoms.c; then echo $(srcdir)/fptoms.c; else echo fptoms.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -getopt_.c: getopt.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/getopt.c; then echo $(srcdir)/getopt.c; else echo getopt.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -hextoint_.c: hextoint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/hextoint.c; then echo $(srcdir)/hextoint.c; else echo hextoint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -hextolfp_.c: hextolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/hextolfp.c; then echo $(srcdir)/hextolfp.c; else echo hextolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -humandate_.c: humandate.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/humandate.c; then echo $(srcdir)/humandate.c; else echo humandate.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -icom_.c: icom.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/icom.c; then echo $(srcdir)/icom.c; else echo icom.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -inet_ntop_.c: $(srcdir)/../libisc/inet_ntop.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/inet_ntop.c; then echo $(srcdir)/$(srcdir)/../libisc/inet_ntop.c; else echo $(srcdir)/../libisc/inet_ntop.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -inet_pton_.c: $(srcdir)/../libisc/inet_pton.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/inet_pton.c; then echo $(srcdir)/$(srcdir)/../libisc/inet_pton.c; else echo $(srcdir)/../libisc/inet_pton.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -interfaceiter_.c: $(srcdir)/../libisc/interfaceiter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/interfaceiter.c; then echo $(srcdir)/$(srcdir)/../libisc/interfaceiter.c; else echo $(srcdir)/../libisc/interfaceiter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -inttoa_.c: inttoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/inttoa.c; then echo $(srcdir)/inttoa.c; else echo inttoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -iosignal_.c: iosignal.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/iosignal.c; then echo $(srcdir)/iosignal.c; else echo iosignal.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -isc_strerror_.c: $(srcdir)/../libisc/isc_strerror.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/isc_strerror.c; then echo $(srcdir)/$(srcdir)/../libisc/isc_strerror.c; else echo $(srcdir)/../libisc/isc_strerror.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -lib_.c: $(srcdir)/../libisc/lib.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/lib.c; then echo $(srcdir)/$(srcdir)/../libisc/lib.c; else echo $(srcdir)/../libisc/lib.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -lib_strbuf_.c: lib_strbuf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/lib_strbuf.c; then echo $(srcdir)/lib_strbuf.c; else echo lib_strbuf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -machines_.c: machines.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/machines.c; then echo $(srcdir)/machines.c; else echo machines.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -md5c_.c: md5c.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/md5c.c; then echo $(srcdir)/md5c.c; else echo md5c.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mem_.c: $(srcdir)/../libisc/mem.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/mem.c; then echo $(srcdir)/$(srcdir)/../libisc/mem.c; else echo $(srcdir)/../libisc/mem.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -memmove_.c: memmove.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/memmove.c; then echo $(srcdir)/memmove.c; else echo memmove.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mfptoa_.c: mfptoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mfptoa.c; then echo $(srcdir)/mfptoa.c; else echo mfptoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mfptoms_.c: mfptoms.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mfptoms.c; then echo $(srcdir)/mfptoms.c; else echo mfptoms.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mktime_.c: mktime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mktime.c; then echo $(srcdir)/mktime.c; else echo mktime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -modetoa_.c: modetoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/modetoa.c; then echo $(srcdir)/modetoa.c; else echo modetoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -msgcat_.c: $(srcdir)/../libisc/msgcat.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/msgcat.c; then echo $(srcdir)/$(srcdir)/../libisc/msgcat.c; else echo $(srcdir)/../libisc/msgcat.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mstolfp_.c: mstolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mstolfp.c; then echo $(srcdir)/mstolfp.c; else echo mstolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -msutotsf_.c: msutotsf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/msutotsf.c; then echo $(srcdir)/msutotsf.c; else echo msutotsf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -msyslog_.c: msyslog.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/msyslog.c; then echo $(srcdir)/msyslog.c; else echo msyslog.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -net_.c: $(srcdir)/../libisc/net.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/net.c; then echo $(srcdir)/$(srcdir)/../libisc/net.c; else echo $(srcdir)/../libisc/net.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -netaddr_.c: $(srcdir)/../libisc/netaddr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/netaddr.c; then echo $(srcdir)/$(srcdir)/../libisc/netaddr.c; else echo $(srcdir)/../libisc/netaddr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -netof_.c: netof.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/netof.c; then echo $(srcdir)/netof.c; else echo netof.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -netscope_.c: $(srcdir)/../libisc/netscope.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/netscope.c; then echo $(srcdir)/$(srcdir)/../libisc/netscope.c; else echo $(srcdir)/../libisc/netscope.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_random_.c: ntp_random.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_random.c; then echo $(srcdir)/ntp_random.c; else echo ntp_random.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_rfc2553_.c: ntp_rfc2553.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_rfc2553.c; then echo $(srcdir)/ntp_rfc2553.c; else echo ntp_rfc2553.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -numtoa_.c: numtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/numtoa.c; then echo $(srcdir)/numtoa.c; else echo numtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -numtohost_.c: numtohost.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/numtohost.c; then echo $(srcdir)/numtohost.c; else echo numtohost.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -octtoint_.c: octtoint.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/octtoint.c; then echo $(srcdir)/octtoint.c; else echo octtoint.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -prettydate_.c: prettydate.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/prettydate.c; then echo $(srcdir)/prettydate.c; else echo prettydate.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -recvbuff_.c: recvbuff.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/recvbuff.c; then echo $(srcdir)/recvbuff.c; else echo recvbuff.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refnumtoa_.c: refnumtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refnumtoa.c; then echo $(srcdir)/refnumtoa.c; else echo refnumtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -snprintf_.c: snprintf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/snprintf.c; then echo $(srcdir)/snprintf.c; else echo snprintf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -sockaddr_.c: $(srcdir)/../libisc/sockaddr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/$(srcdir)/../libisc/sockaddr.c; then echo $(srcdir)/$(srcdir)/../libisc/sockaddr.c; else echo $(srcdir)/../libisc/sockaddr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -socktoa_.c: socktoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/socktoa.c; then echo $(srcdir)/socktoa.c; else echo socktoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -socktohost_.c: socktohost.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/socktohost.c; then echo $(srcdir)/socktohost.c; else echo socktohost.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -statestr_.c: statestr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/statestr.c; then echo $(srcdir)/statestr.c; else echo statestr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -strdup_.c: strdup.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/strdup.c; then echo $(srcdir)/strdup.c; else echo strdup.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -strerror_.c: strerror.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/strerror.c; then echo $(srcdir)/strerror.c; else echo strerror.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -strstr_.c: strstr.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/strstr.c; then echo $(srcdir)/strstr.c; else echo strstr.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -syssignal_.c: syssignal.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/syssignal.c; then echo $(srcdir)/syssignal.c; else echo syssignal.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -systime_.c: systime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/systime.c; then echo $(srcdir)/systime.c; else echo systime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -systime_s_.c: systime_s.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/systime_s.c; then echo $(srcdir)/systime_s.c; else echo systime_s.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tsftomsu_.c: tsftomsu.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tsftomsu.c; then echo $(srcdir)/tsftomsu.c; else echo tsftomsu.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tstotv_.c: tstotv.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tstotv.c; then echo $(srcdir)/tstotv.c; else echo tstotv.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tvtoa_.c: tvtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tvtoa.c; then echo $(srcdir)/tvtoa.c; else echo tvtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -tvtots_.c: tvtots.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/tvtots.c; then echo $(srcdir)/tvtots.c; else echo tvtots.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -uglydate_.c: uglydate.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/uglydate.c; then echo $(srcdir)/uglydate.c; else echo uglydate.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -uinttoa_.c: uinttoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/uinttoa.c; then echo $(srcdir)/uinttoa.c; else echo uinttoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -utvtoa_.c: utvtoa.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/utvtoa.c; then echo $(srcdir)/utvtoa.c; else echo utvtoa.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ymd2yd_.c: ymd2yd.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ymd2yd.c; then echo $(srcdir)/ymd2yd.c; else echo ymd2yd.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -a_md5encrypt_.$(OBJEXT) a_md5encrypt_.lo adjtime_.$(OBJEXT) \ -adjtime_.lo adjtimex_.$(OBJEXT) adjtimex_.lo assertions_.$(OBJEXT) \ -assertions_.lo atoint_.$(OBJEXT) atoint_.lo atolfp_.$(OBJEXT) \ -atolfp_.lo atouint_.$(OBJEXT) atouint_.lo audio_.$(OBJEXT) audio_.lo \ -authkeys_.$(OBJEXT) authkeys_.lo authreadkeys_.$(OBJEXT) \ -authreadkeys_.lo authusekey_.$(OBJEXT) authusekey_.lo \ -buftvtots_.$(OBJEXT) buftvtots_.lo caljulian_.$(OBJEXT) caljulian_.lo \ -caltontp_.$(OBJEXT) caltontp_.lo calyearstart_.$(OBJEXT) \ -calyearstart_.lo clocktime_.$(OBJEXT) clocktime_.lo \ -clocktypes_.$(OBJEXT) clocktypes_.lo decodenetnum_.$(OBJEXT) \ -decodenetnum_.lo dofptoa_.$(OBJEXT) dofptoa_.lo dolfptoa_.$(OBJEXT) \ -dolfptoa_.lo emalloc_.$(OBJEXT) emalloc_.lo error_.$(OBJEXT) error_.lo \ -findconfig_.$(OBJEXT) findconfig_.lo fptoa_.$(OBJEXT) fptoa_.lo \ -fptoms_.$(OBJEXT) fptoms_.lo getopt_.$(OBJEXT) getopt_.lo \ -hextoint_.$(OBJEXT) hextoint_.lo hextolfp_.$(OBJEXT) hextolfp_.lo \ -humandate_.$(OBJEXT) humandate_.lo icom_.$(OBJEXT) icom_.lo \ -inet_ntop_.$(OBJEXT) inet_ntop_.lo inet_pton_.$(OBJEXT) inet_pton_.lo \ -interfaceiter_.$(OBJEXT) interfaceiter_.lo inttoa_.$(OBJEXT) \ -inttoa_.lo iosignal_.$(OBJEXT) iosignal_.lo isc_strerror_.$(OBJEXT) \ -isc_strerror_.lo lib_.$(OBJEXT) lib_.lo lib_strbuf_.$(OBJEXT) \ -lib_strbuf_.lo machines_.$(OBJEXT) machines_.lo md5c_.$(OBJEXT) \ -md5c_.lo mem_.$(OBJEXT) mem_.lo memmove_.$(OBJEXT) memmove_.lo \ -mfptoa_.$(OBJEXT) mfptoa_.lo mfptoms_.$(OBJEXT) mfptoms_.lo \ -mktime_.$(OBJEXT) mktime_.lo modetoa_.$(OBJEXT) modetoa_.lo \ -msgcat_.$(OBJEXT) msgcat_.lo mstolfp_.$(OBJEXT) mstolfp_.lo \ -msutotsf_.$(OBJEXT) msutotsf_.lo msyslog_.$(OBJEXT) msyslog_.lo \ -net_.$(OBJEXT) net_.lo netaddr_.$(OBJEXT) netaddr_.lo netof_.$(OBJEXT) \ -netof_.lo netscope_.$(OBJEXT) netscope_.lo ntp_random_.$(OBJEXT) \ -ntp_random_.lo ntp_rfc2553_.$(OBJEXT) ntp_rfc2553_.lo \ -numtoa_.$(OBJEXT) numtoa_.lo numtohost_.$(OBJEXT) numtohost_.lo \ -octtoint_.$(OBJEXT) octtoint_.lo prettydate_.$(OBJEXT) prettydate_.lo \ -recvbuff_.$(OBJEXT) recvbuff_.lo refnumtoa_.$(OBJEXT) refnumtoa_.lo \ -snprintf_.$(OBJEXT) snprintf_.lo sockaddr_.$(OBJEXT) sockaddr_.lo \ -socktoa_.$(OBJEXT) socktoa_.lo socktohost_.$(OBJEXT) socktohost_.lo \ -statestr_.$(OBJEXT) statestr_.lo strdup_.$(OBJEXT) strdup_.lo \ -strerror_.$(OBJEXT) strerror_.lo strstr_.$(OBJEXT) strstr_.lo \ -syssignal_.$(OBJEXT) syssignal_.lo systime_.$(OBJEXT) systime_.lo \ -systime_s_.$(OBJEXT) systime_s_.lo tsftomsu_.$(OBJEXT) tsftomsu_.lo \ -tstotv_.$(OBJEXT) tstotv_.lo tvtoa_.$(OBJEXT) tvtoa_.lo \ -tvtots_.$(OBJEXT) tvtots_.lo uglydate_.$(OBJEXT) uglydate_.lo \ -uinttoa_.$(OBJEXT) uinttoa_.lo utvtoa_.$(OBJEXT) utvtoa_.lo \ -ymd2yd_.$(OBJEXT) ymd2yd_.lo : $(ANSI2KNR) +result.obj: $(srcdir)/../lib/isc/result.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT result.obj -MD -MP -MF $(DEPDIR)/result.Tpo -c -o result.obj `if test -f '$(srcdir)/../lib/isc/result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/result.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/result.Tpo $(DEPDIR)/result.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/result.c' object='result.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o result.obj `if test -f '$(srcdir)/../lib/isc/result.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/result.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/result.c'; fi` + +stdio.o: $(srcdir)/../lib/isc/unix/stdio.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdio.o -MD -MP -MF $(DEPDIR)/stdio.Tpo -c -o stdio.o `test -f '$(srcdir)/../lib/isc/unix/stdio.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdio.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/stdio.Tpo $(DEPDIR)/stdio.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/stdio.c' object='stdio.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdio.o `test -f '$(srcdir)/../lib/isc/unix/stdio.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdio.c + +stdio.obj: $(srcdir)/../lib/isc/unix/stdio.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdio.obj -MD -MP -MF $(DEPDIR)/stdio.Tpo -c -o stdio.obj `if test -f '$(srcdir)/../lib/isc/unix/stdio.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdio.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdio.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/stdio.Tpo $(DEPDIR)/stdio.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/stdio.c' object='stdio.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdio.obj `if test -f '$(srcdir)/../lib/isc/unix/stdio.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdio.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdio.c'; fi` + +stdtime.o: $(srcdir)/../lib/isc/unix/stdtime.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdtime.o -MD -MP -MF $(DEPDIR)/stdtime.Tpo -c -o stdtime.o `test -f '$(srcdir)/../lib/isc/unix/stdtime.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdtime.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/stdtime.Tpo $(DEPDIR)/stdtime.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/stdtime.c' object='stdtime.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdtime.o `test -f '$(srcdir)/../lib/isc/unix/stdtime.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/stdtime.c + +stdtime.obj: $(srcdir)/../lib/isc/unix/stdtime.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stdtime.obj -MD -MP -MF $(DEPDIR)/stdtime.Tpo -c -o stdtime.obj `if test -f '$(srcdir)/../lib/isc/unix/stdtime.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdtime.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdtime.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/stdtime.Tpo $(DEPDIR)/stdtime.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/stdtime.c' object='stdtime.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stdtime.obj `if test -f '$(srcdir)/../lib/isc/unix/stdtime.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/stdtime.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/stdtime.c'; fi` + +strerror.o: $(srcdir)/../lib/isc/unix/strerror.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT strerror.o -MD -MP -MF $(DEPDIR)/strerror.Tpo -c -o strerror.o `test -f '$(srcdir)/../lib/isc/unix/strerror.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/strerror.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/strerror.Tpo $(DEPDIR)/strerror.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/strerror.c' object='strerror.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o strerror.o `test -f '$(srcdir)/../lib/isc/unix/strerror.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/strerror.c + +strerror.obj: $(srcdir)/../lib/isc/unix/strerror.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT strerror.obj -MD -MP -MF $(DEPDIR)/strerror.Tpo -c -o strerror.obj `if test -f '$(srcdir)/../lib/isc/unix/strerror.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/strerror.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/strerror.Tpo $(DEPDIR)/strerror.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/strerror.c' object='strerror.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o strerror.obj `if test -f '$(srcdir)/../lib/isc/unix/strerror.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/strerror.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/strerror.c'; fi` + +task.o: $(srcdir)/../lib/isc/task.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task.o -MD -MP -MF $(DEPDIR)/task.Tpo -c -o task.o `test -f '$(srcdir)/../lib/isc/task.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/task.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/task.Tpo $(DEPDIR)/task.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/task.c' object='task.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task.o `test -f '$(srcdir)/../lib/isc/task.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/task.c + +task.obj: $(srcdir)/../lib/isc/task.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT task.obj -MD -MP -MF $(DEPDIR)/task.Tpo -c -o task.obj `if test -f '$(srcdir)/../lib/isc/task.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/task.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/task.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/task.Tpo $(DEPDIR)/task.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/task.c' object='task.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o task.obj `if test -f '$(srcdir)/../lib/isc/task.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/task.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/task.c'; fi` + +thread.o: $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT thread.o -MD -MP -MF $(DEPDIR)/thread.Tpo -c -o thread.o `test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/thread.Tpo $(DEPDIR)/thread.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c' object='thread.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o thread.o `test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c + +thread.obj: $(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT thread.obj -MD -MP -MF $(DEPDIR)/thread.Tpo -c -o thread.obj `if test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/thread.Tpo $(DEPDIR)/thread.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c' object='thread.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o thread.obj `if test -f '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/thread.c'; fi` + +time.o: $(srcdir)/../lib/isc/unix/time.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT time.o -MD -MP -MF $(DEPDIR)/time.Tpo -c -o time.o `test -f '$(srcdir)/../lib/isc/unix/time.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/time.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/time.Tpo $(DEPDIR)/time.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/time.c' object='time.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o time.o `test -f '$(srcdir)/../lib/isc/unix/time.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/unix/time.c + +time.obj: $(srcdir)/../lib/isc/unix/time.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT time.obj -MD -MP -MF $(DEPDIR)/time.Tpo -c -o time.obj `if test -f '$(srcdir)/../lib/isc/unix/time.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/time.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/time.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/time.Tpo $(DEPDIR)/time.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/unix/time.c' object='time.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o time.obj `if test -f '$(srcdir)/../lib/isc/unix/time.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/unix/time.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/unix/time.c'; fi` + +sha1.o: $(srcdir)/../lib/isc/sha1.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sha1.o -MD -MP -MF $(DEPDIR)/sha1.Tpo -c -o sha1.o `test -f '$(srcdir)/../lib/isc/sha1.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/sha1.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/sha1.Tpo $(DEPDIR)/sha1.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/sha1.c' object='sha1.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sha1.o `test -f '$(srcdir)/../lib/isc/sha1.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/sha1.c + +sha1.obj: $(srcdir)/../lib/isc/sha1.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sha1.obj -MD -MP -MF $(DEPDIR)/sha1.Tpo -c -o sha1.obj `if test -f '$(srcdir)/../lib/isc/sha1.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/sha1.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/sha1.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/sha1.Tpo $(DEPDIR)/sha1.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/sha1.c' object='sha1.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sha1.obj `if test -f '$(srcdir)/../lib/isc/sha1.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/sha1.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/sha1.c'; fi` + +sockaddr.o: $(srcdir)/../lib/isc/sockaddr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.o -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.o `test -f '$(srcdir)/../lib/isc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/sockaddr.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/sockaddr.c' object='sockaddr.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.o `test -f '$(srcdir)/../lib/isc/sockaddr.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/sockaddr.c + +sockaddr.obj: $(srcdir)/../lib/isc/sockaddr.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT sockaddr.obj -MD -MP -MF $(DEPDIR)/sockaddr.Tpo -c -o sockaddr.obj `if test -f '$(srcdir)/../lib/isc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/sockaddr.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/sockaddr.Tpo $(DEPDIR)/sockaddr.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/sockaddr.c' object='sockaddr.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sockaddr.obj `if test -f '$(srcdir)/../lib/isc/sockaddr.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/sockaddr.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/sockaddr.c'; fi` + +mutex.o: $(srcdir)/../lib/isc/pthreads/mutex.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mutex.o -MD -MP -MF $(DEPDIR)/mutex.Tpo -c -o mutex.o `test -f '$(srcdir)/../lib/isc/pthreads/mutex.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/pthreads/mutex.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/mutex.Tpo $(DEPDIR)/mutex.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/pthreads/mutex.c' object='mutex.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mutex.o `test -f '$(srcdir)/../lib/isc/pthreads/mutex.c' || echo '$(srcdir)/'`$(srcdir)/../lib/isc/pthreads/mutex.c + +mutex.obj: $(srcdir)/../lib/isc/pthreads/mutex.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mutex.obj -MD -MP -MF $(DEPDIR)/mutex.Tpo -c -o mutex.obj `if test -f '$(srcdir)/../lib/isc/pthreads/mutex.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/pthreads/mutex.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/pthreads/mutex.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/mutex.Tpo $(DEPDIR)/mutex.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$(srcdir)/../lib/isc/pthreads/mutex.c' object='mutex.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mutex.obj `if test -f '$(srcdir)/../lib/isc/pthreads/mutex.c'; then $(CYGPATH_W) '$(srcdir)/../lib/isc/pthreads/mutex.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/../lib/isc/pthreads/mutex.c'; fi` mostlyclean-libtool: -rm -f *.lo @@ -1015,26 +1341,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -1046,15 +1361,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -1063,6 +1374,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -1098,10 +1424,12 @@ distdir: $(DISTFILES) fi; \ done check-am: all-am -check: check-am -all-am: Makefile $(LIBRARIES) $(HEADERS) +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am +all-am: Makefile $(LIBRARIES) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -1111,13 +1439,19 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -1126,6 +1460,7 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \ @@ -1184,7 +1519,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -1197,25 +1532,81 @@ ps-am: uninstall-am: -.MAKE: ../util/ansi2knr install-am install-strip - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-libtool clean-noinstLIBRARIES ctags distclean \ - distclean-compile distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-kr \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am - - -../include/des.h: - touch ../include/des.h +.MAKE: all check install install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstLIBRARIES cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/contrib/ntp/libntp/a_md5encrypt.c b/contrib/ntp/libntp/a_md5encrypt.c index e1ea37c16..ffabc47c7 100644 --- a/contrib/ntp/libntp/a_md5encrypt.c +++ b/contrib/ntp/libntp/a_md5encrypt.c @@ -1,13 +1,6 @@ /* - * MD5 interface for rsaref2.0 - * - * These routines implement an interface for the RSA Laboratories - * implementation of the Message Digest 5 (MD5) algorithm. This - * algorithm is included in the rsaref2.0 package available from RSA in - * the US and foreign countries. Further information is available at - * www.rsa.com. + * digest support for NTP, MD5 and with OpenSSL more */ - #ifdef HAVE_CONFIG_H #include #endif @@ -15,90 +8,130 @@ #include "ntp_fp.h" #include "ntp_string.h" #include "ntp_stdlib.h" - -/* Disable the openssl md5 includes, because they'd clash with ours. */ -/* #define NO_MD5 */ -/* #define OPENSSL_NO_MD5 */ -#undef OPENSSL - #include "ntp.h" -#include "global.h" -#include "ntp_md5.h" +#include "ntp_md5.h" /* provides OpenSSL digest API */ /* - * MD5authencrypt - generate MD5 message authenticator + * MD5authencrypt - generate message digest * - * Returns length of authenticator field. + * Returns length of MAC including key ID and digest. */ int MD5authencrypt( - u_char *key, /* key pointer */ + int type, /* hash algorithm */ + u_char *key, /* key pointer */ u_int32 *pkt, /* packet pointer */ - int length /* packet length */ + int length /* packet length */ ) { - MD5_CTX md5; - u_char digest[16]; + u_char digest[EVP_MAX_MD_SIZE]; + u_int len; + EVP_MD_CTX ctx; /* - * MD5 with key identifier concatenated with packet. + * Compute digest of key concatenated with packet. Note: the + * key type and digest type have been verified when the key + * was creaded. */ - MD5Init(&md5); - MD5Update(&md5, key, (u_int)cache_keylen); - MD5Update(&md5, (u_char *)pkt, (u_int)length); - MD5Final(digest, &md5); - memmove((u_char *)pkt + length + 4, digest, 16); - return (16 + 4); + INIT_SSL(); +#if defined(OPENSSL) && OPENSSL_VERSION_NUMBER >= 0x0090700fL + if (!EVP_DigestInit(&ctx, EVP_get_digestbynid(type))) { + msyslog(LOG_ERR, + "MAC encrypt: digest init failed"); + return (0); + } +#else + EVP_DigestInit(&ctx, EVP_get_digestbynid(type)); +#endif + EVP_DigestUpdate(&ctx, key, cache_secretsize); + EVP_DigestUpdate(&ctx, (u_char *)pkt, (u_int)length); + EVP_DigestFinal(&ctx, digest, &len); + memmove((u_char *)pkt + length + 4, digest, len); + return (len + 4); } /* * MD5authdecrypt - verify MD5 message authenticator * - * Returns one if authenticator valid, zero if invalid. + * Returns one if digest valid, zero if invalid. */ int MD5authdecrypt( - u_char *key, /* key pointer */ - u_int32 *pkt, /* packet pointer */ - int length, /* packet length */ - int size /* MAC size */ + int type, /* hash algorithm */ + u_char *key, /* key pointer */ + u_int32 *pkt, /* packet pointer */ + int length, /* packet length */ + int size /* MAC size */ ) { - MD5_CTX md5; - u_char digest[16]; + u_char digest[EVP_MAX_MD_SIZE]; + u_int len; + EVP_MD_CTX ctx; /* - * MD5 with key identifier concatenated with packet. + * Compute digest of key concatenated with packet. Note: the + * key type and digest type have been verified when the key + * was created. */ - MD5Init(&md5); - MD5Update(&md5, key, (u_int)cache_keylen); - MD5Update(&md5, (u_char *)pkt, (u_int)length); - MD5Final(digest, &md5); - if (size != 16 + 4) + INIT_SSL(); +#if defined(OPENSSL) && OPENSSL_VERSION_NUMBER >= 0x0090700fL + if (!EVP_DigestInit(&ctx, EVP_get_digestbynid(type))) { + msyslog(LOG_ERR, + "MAC decrypt: digest init failed"); return (0); - return (!memcmp(digest, (char *)pkt + length + 4, 16)); + } +#else + EVP_DigestInit(&ctx, EVP_get_digestbynid(type)); +#endif + EVP_DigestUpdate(&ctx, key, cache_secretsize); + EVP_DigestUpdate(&ctx, (u_char *)pkt, (u_int)length); + EVP_DigestFinal(&ctx, digest, &len); + if ((u_int)size != len + 4) { + msyslog(LOG_ERR, + "MAC decrypt: MAC length error"); + return (0); + } + return !memcmp(digest, (char *)pkt + length + 4, len); } /* * Calculate the reference id from the address. If it is an IPv4 * address, use it as is. If it is an IPv6 address, do a md5 on * it and use the bottom 4 bytes. + * The result is in network byte order. */ u_int32 -addr2refid(struct sockaddr_storage *addr) +addr2refid(sockaddr_u *addr) { - MD5_CTX md5; - u_char digest[16]; - u_int32 addr_refid; + u_char digest[20]; + u_int32 addr_refid; + EVP_MD_CTX ctx; + u_int len; + + if (IS_IPV4(addr)) + return (NSRCADR(addr)); - if (addr->ss_family == AF_INET) - return (GET_INADDR(*addr)); + INIT_SSL(); + +#if defined(OPENSSL) && OPENSSL_VERSION_NUMBER >= 0x0090700fL + EVP_MD_CTX_init(&ctx); +#ifdef EVP_MD_CTX_FLAG_NON_FIPS_ALLOW + /* MD5 is not used as a crypto hash here. */ + EVP_MD_CTX_set_flags(&ctx, EVP_MD_CTX_FLAG_NON_FIPS_ALLOW); +#endif + if (!EVP_DigestInit_ex(&ctx, EVP_md5(), NULL)) { + msyslog(LOG_ERR, + "MD5 init failed"); + exit(1); + } +#else + EVP_DigestInit(&ctx, EVP_md5()); +#endif - MD5Init(&md5); - MD5Update(&md5, (u_char *)&GET_INADDR6(*addr), + EVP_DigestUpdate(&ctx, (u_char *)PSOCK_ADDR6(addr), sizeof(struct in6_addr)); - MD5Final(digest, &md5); - memcpy(&addr_refid, digest, 4); + EVP_DigestFinal(&ctx, digest, &len); + memcpy(&addr_refid, digest, sizeof(addr_refid)); return (addr_refid); } diff --git a/contrib/ntp/libntp/atoint.c b/contrib/ntp/libntp/atoint.c index 46cd96d19..9da8c13c3 100644 --- a/contrib/ntp/libntp/atoint.c +++ b/contrib/ntp/libntp/atoint.c @@ -1,6 +1,7 @@ /* * atoint - convert an ascii string to a signed long, with error checking */ +#include #include #include @@ -34,7 +35,7 @@ atoint( u = 0; while (*cp != '\0') { - if (!isdigit((int)*cp)) + if (!isdigit((unsigned char)*cp)) return 0; if (u > 214748364 || (u == 214748364 && *cp > oflow_digit)) return 0; /* overflow */ diff --git a/contrib/ntp/libntp/atolfp.c b/contrib/ntp/libntp/atolfp.c index ff50947f0..9a2f69178 100644 --- a/contrib/ntp/libntp/atolfp.c +++ b/contrib/ntp/libntp/atolfp.c @@ -1,11 +1,13 @@ /* * atolfp - convert an ascii string to an l_fp number */ +#include #include #include #include "ntp_fp.h" #include "ntp_string.h" +#include "ntp_assert.h" /* * Powers of 10 @@ -38,6 +40,8 @@ atolfp( int isneg; static const char *digits = "0123456789"; + REQUIRE(str != NULL); + isneg = 0; dec_i = dec_f = 0; ndec = 0; @@ -48,7 +52,7 @@ atolfp( * * [spaces][-|+][digits][.][digits][spaces|\n|\0] */ - while (isspace((int)*cp)) + while (isspace((unsigned char)*cp)) cp++; if (*cp == '-') { @@ -59,7 +63,7 @@ atolfp( if (*cp == '+') cp++; - if (*cp != '.' && !isdigit((int)*cp)) + if (*cp != '.' && !isdigit((unsigned char)*cp)) return 0; while (*cp != '\0' && (ind = strchr(digits, *cp)) != NULL) { @@ -68,7 +72,7 @@ atolfp( cp++; } - if (*cp != '\0' && !isspace((int)*cp)) { + if (*cp != '\0' && !isspace((unsigned char)*cp)) { if (*cp++ != '.') return 0; @@ -80,10 +84,10 @@ atolfp( cp++; } - while (isdigit((int)*cp)) + while (isdigit((unsigned char)*cp)) cp++; - if (*cp != '\0' && !isspace((int)*cp)) + if (*cp != '\0' && !isspace((unsigned char)*cp)) return 0; } diff --git a/contrib/ntp/libntp/atouint.c b/contrib/ntp/libntp/atouint.c index c25e3a0c5..0a6163907 100644 --- a/contrib/ntp/libntp/atouint.c +++ b/contrib/ntp/libntp/atouint.c @@ -1,33 +1,40 @@ -/* - * atouint - convert an ascii string to an unsigned long, with error checking - */ +#include #include #include #include "ntp_types.h" #include "ntp_stdlib.h" +/* + * atouint() - convert an ascii string representing a whole base 10 + * number to u_long *uval, returning TRUE if successful. + * Does not modify *uval and returns FALSE if str is not + * a positive base10 integer or is too large for a u_int32. + * this function uses u_long but should use u_int32, and + * probably be renamed. + */ int atouint( const char *str, u_long *uval ) { - register u_long u; - register const char *cp; + u_long u; + const char *cp; cp = str; - if (*cp == '\0') - return 0; + if ('\0' == *cp) + return 0; u = 0; - while (*cp != '\0') { - if (!isdigit((int)*cp)) - return 0; + while ('\0' != *cp) { + if (!isdigit((unsigned char)*cp)) + return 0; if (u > 429496729 || (u == 429496729 && *cp >= '6')) - return 0; /* overflow */ + return 0; /* overflow */ + /* hand-optimized u *= 10; */ u = (u << 3) + (u << 1); - u += *cp++ - '0'; /* ascii dependent */ + u += *cp++ - '0'; /* not '\0' */ } *uval = u; diff --git a/contrib/ntp/libntp/audio.c b/contrib/ntp/libntp/audio.c index 8d2f7c2ca..726dfa94d 100644 --- a/contrib/ntp/libntp/audio.c +++ b/contrib/ntp/libntp/audio.c @@ -67,8 +67,8 @@ static struct audio_info info; /* audio device info */ static int ctl_fd; /* audio control file descriptor */ #ifdef PCM_STYLE_SOUND -static void audio_config_read P((int, char **, char **)); -static int mixer_name P((const char *, int)); +static void audio_config_read (int, const char **, const char **); +static int mixer_name (const char *, int); int @@ -114,22 +114,25 @@ mixer_name( static void audio_config_read( int unit, - char **c_dev, /* Control device */ - char **i_dev /* input device */ + const char **c_dev, /* Control device */ + const char **i_dev /* input device */ ) { FILE *fd; char device[20], line[100], ab[100]; - sprintf(device, "%s%d", INIT_FILE, unit); + snprintf(device, sizeof(device), "%s%d", INIT_FILE, unit); if ((fd = fopen(device, "r")) == NULL) { printf("audio_config_read: <%s> NO\n", device); - sprintf(device, "%s.%d", INIT_FILE, unit); + snprintf(device, sizeof(device), "%s.%d", INIT_FILE, + unit); if ((fd = fopen(device, "r")) == NULL) { printf("audio_config_read: <%s> NO\n", device); - sprintf(device, "%s.%d", INIT_FILE, unit); + snprintf(device, sizeof(device), "%s", + INIT_FILE); if ((fd = fopen(device, "r")) == NULL) { - printf("audio_config_read: <%s> NO\n", device); + printf("audio_config_read: <%s> NO\n", + device); return; } } @@ -145,12 +148,12 @@ audio_config_read( /* Remove any trailing spaces */ for (i = strlen(line); - i > 0 && isascii((int)line[i - 1]) && isspace((int)line[i - 1]); + i > 0 && isascii((unsigned char)line[i - 1]) && isspace((unsigned char)line[i - 1]); ) line[--i] = '\0'; /* Remove leading space */ - for (cc = line; *cc && isascii((int)*cc) && isspace((int)*cc); cc++) + for (cc = line; *cc && isascii((unsigned char)*cc) && isspace((unsigned char)*cc); cc++) continue; /* Stop if nothing left */ @@ -159,33 +162,33 @@ audio_config_read( /* Uppercase the command and find the arg */ for (ca = cc; *ca; ca++) { - if (isascii((int)*ca)) { - if (islower((int)*ca)) { - *ca = toupper(*ca); - } else if (isspace((int)*ca) || (*ca == '=')) + if (isascii((unsigned char)*ca)) { + if (islower((unsigned char)*ca)) { + *ca = toupper((unsigned char)*ca); + } else if (isspace((unsigned char)*ca) || (*ca == '=')) break; } } /* Remove space (and possible =) leading the arg */ - for (; *ca && isascii((int)*ca) && (isspace((int)*ca) || (*ca == '=')); ca++) + for (; *ca && isascii((unsigned char)*ca) && (isspace((unsigned char)*ca) || (*ca == '=')); ca++) continue; - if (!strncmp(cc, "IDEV", (size_t) 4)) { - sscanf(ca, "%s", ab); - strcpy(cf_i_dev, ab); + if (!strncmp(cc, "IDEV", 4) && + 1 == sscanf(ca, "%99s", ab)) { + strlcpy(cf_i_dev, ab, sizeof(cf_i_dev)); printf("idev <%s>\n", ab); - } else if (!strncmp(cc, "CDEV", (size_t) 4)) { - sscanf(ca, "%s", ab); - strcpy(cf_c_dev, ab); + } else if (!strncmp(cc, "CDEV", 4) && + 1 == sscanf(ca, "%99s", ab)) { + strlcpy(cf_c_dev, ab, sizeof(cf_c_dev)); printf("cdev <%s>\n", ab); - } else if (!strncmp(cc, "AGC", (size_t) 3)) { - sscanf(ca, "%s", ab); - strcpy(cf_agc, ab); + } else if (!strncmp(cc, "AGC", 3) && + 1 == sscanf(ca, "%99s", ab)) { + strlcpy(cf_agc, ab, sizeof(cf_agc)); printf("agc <%s> %d\n", ab, i); - } else if (!strncmp(cc, "MONITOR", (size_t) 7)) { - sscanf(ca, "%s", ab); - strcpy(cf_monitor, ab); + } else if (!strncmp(cc, "MONITOR", 7) && + 1 == sscanf(ca, "%99s", ab)) { + strlcpy(cf_monitor, ab, sizeof(cf_monitor)); printf("monitor <%s> %d\n", ab, mixer_name(ab, -1)); } } @@ -207,7 +210,7 @@ audio_config_read( */ int audio_init( - char *dname, /* device name */ + const char *dname, /* device name */ int bufsiz, /* buffer size */ int unit /* device unit (0-3) */ ) @@ -224,7 +227,7 @@ audio_init( #endif int fd; int rval; - char *actl = + const char *actl = #ifdef PCM_STYLE_SOUND actl_dev #else @@ -233,7 +236,7 @@ audio_init( ; #ifdef PCM_STYLE_SOUND - (void)sprintf(actl_dev, ACTL_DEV, unit); + snprintf(actl_dev, sizeof(actl_dev), ACTL_DEV, unit); audio_config_read(unit, &actl, &dname); /* If we have values for cf_c_dev or cf_i_dev, use them. */ @@ -244,18 +247,21 @@ audio_init( #endif /* - * Open audio device. Do not complain if not there. + * Open audio device */ fd = open(dname, O_RDWR | O_NONBLOCK, 0777); - if (fd < 0) + if (fd < 0) { + msyslog(LOG_ERR, "audio_init: %s %m", dname); return (fd); + } /* * Open audio control device. */ ctl_fd = open(actl, O_RDWR); if (ctl_fd < 0) { - msyslog(LOG_ERR, "audio_init: invalid control device <%s>\n", actl); + msyslog(LOG_ERR, "audio_init: invalid control device <%s>", + actl); close(fd); return(ctl_fd); } @@ -310,10 +316,11 @@ audio_init( printf("SOUND_MIXER_READ_RECMASK: %s\n", strerror(errno)); /* validate and set any specified config file stuff */ - if (*cf_agc) { + if (cf_agc[0] != '\0') { int i; - i = mixer_name(cf_agc, devmask); + /* recmask */ + i = mixer_name(cf_agc, recmask); if (i >= 0) agc = MIXER_WRITE(i); else @@ -321,7 +328,7 @@ audio_init( cf_agc, recmask); } - if (*cf_monitor) { + if (cf_monitor[0] != '\0') { int i; /* devmask */ @@ -342,7 +349,7 @@ audio_init( # endif /* HAVE_SYS_AUDIOIO_H */ rval = ioctl(ctl_fd, (int)AUDIO_SETINFO, (char *)&info); if (rval < 0) { - msyslog(LOG_ERR, "audio: invalid control device parameters\n"); + msyslog(LOG_ERR, "audio: invalid control device parameters"); close(ctl_fd); close(fd); return(rval); @@ -370,28 +377,31 @@ audio_gain( #ifdef PCM_STYLE_SOUND int l, r; - rval = 0; +# ifdef GCC + rval = 0; /* GCC thinks rval is used uninitialized */ +# endif r = l = 100 * gain / 255; /* Normalize to 0-100 */ # ifdef DEBUG if (debug > 1) printf("audio_gain: gain %d/%d\n", gain, l); # endif +#if 0 /* not a good idea to do this; connector wiring dependency */ /* figure out what channel(s) to use. just nuke right for now. */ r = 0 ; /* setting to zero nicely mutes the channel */ - +#endif l |= r << 8; - if ( cf_agc ) - rval = ioctl(ctl_fd, agc, &l); - else - if (port == 2) { - rval = ioctl(ctl_fd, SOUND_MIXER_WRITE_LINE, &l); - } else { - rval = ioctl(ctl_fd, SOUND_MIXER_WRITE_MIC, &l); - } - if (rval == -1) { + if (cf_agc[0] != '\0') + rval = ioctl(ctl_fd, agc, &l); + else + rval = ioctl(ctl_fd + , (2 == port) + ? SOUND_MIXER_WRITE_LINE + : SOUND_MIXER_WRITE_MIC + , &l); + if (-1 == rval) { printf("audio_gain: agc write: %s\n", strerror(errno)); - return (rval); + return rval; } if (o_mongain != mongain) { @@ -401,11 +411,12 @@ audio_gain( printf("audio_gain: mongain %d/%d\n", mongain, l); # endif l |= r << 8; - if ( cf_monitor ) - rval = ioctl(ctl_fd, monitor, &l ); - else - rval = ioctl(ctl_fd, SOUND_MIXER_WRITE_VOLUME, &l); - if (rval == -1) { + if (cf_monitor[0] != '\0') + rval = ioctl(ctl_fd, monitor, &l ); + else + rval = ioctl(ctl_fd, SOUND_MIXER_WRITE_VOLUME, + &l); + if (-1 == rval) { printf("audio_gain: mongain write: %s\n", strerror(errno)); return (rval); diff --git a/contrib/ntp/libntp/authkeys.c b/contrib/ntp/libntp/authkeys.c index 1c9544468..667ca298b 100644 --- a/contrib/ntp/libntp/authkeys.c +++ b/contrib/ntp/libntp/authkeys.c @@ -1,17 +1,17 @@ /* * authkeys.c - routines to manage the storage of authentication keys */ - #ifdef HAVE_CONFIG_H # include #endif +#include #include -#include "ntp_types.h" -#include "ntp_fp.h" #include "ntp.h" +#include "ntp_fp.h" #include "ntpd.h" +#include "ntp_lists.h" #include "ntp_string.h" #include "ntp_malloc.h" #include "ntp_stdlib.h" @@ -19,30 +19,57 @@ /* * Structure to store keys in in the hash table. */ +typedef struct savekey symkey; + struct savekey { - struct savekey *next; - union { - long bogon; /* Make sure nonempty */ - u_char MD5_key[32]; /* MD5 key */ - } k; - keyid_t keyid; /* key identifier */ - u_short flags; /* flags that wave */ - u_long lifetime; /* remaining lifetime */ - int keylen; /* key length */ + symkey * hlink; /* next in hash bucket */ + DECL_DLIST_LINK(symkey, llink); /* for overall & free lists */ + u_char * secret; /* shared secret */ + u_long lifetime; /* remaining lifetime */ + keyid_t keyid; /* key identifier */ + u_short type; /* OpenSSL digest NID */ + u_short secretsize; /* secret octets */ + u_short flags; /* KEY_ flags that wave */ }; +/* define the payload region of symkey beyond the list pointers */ +#define symkey_payload secret + #define KEY_TRUSTED 0x001 /* this key is trusted */ -#define KEY_MD5 0x200 /* this is a MD5 type key */ +#ifdef DEBUG +typedef struct symkey_alloc_tag symkey_alloc; + +struct symkey_alloc_tag { + symkey_alloc * link; + void * mem; /* enable free() atexit */ +}; + +symkey_alloc * authallocs; +#endif /* DEBUG */ + +static inline u_short auth_log2(double x); +static void auth_resize_hashtable(void); +static void allocsymkey(symkey **, keyid_t, u_short, + u_short, u_long, u_short, u_char *); +static void freesymkey(symkey *, symkey **); +#ifdef DEBUG +static void free_auth_mem(void); +#endif + +symkey key_listhead; /* list of all in-use keys */; /* * The hash table. This is indexed by the low order bits of the * keyid. We make this fairly big for potentially busy servers. */ -#define HASHSIZE 64 -#define HASHMASK ((HASHSIZE)-1) -#define KEYHASH(keyid) ((keyid) & HASHMASK) +#define DEF_AUTHHASHSIZE 64 +//#define HASHMASK ((HASHSIZE)-1) +#define KEYHASH(keyid) ((keyid) & authhashmask) -struct savekey *key_hash[HASHSIZE]; +int authhashdisabled; +u_short authhashbuckets = DEF_AUTHHASHSIZE; +u_short authhashmask = DEF_AUTHHASHSIZE - 1; +symkey **key_hash; u_long authkeynotfound; /* keys not found */ u_long authkeylookups; /* calls to lookup keys */ @@ -54,20 +81,21 @@ u_long authencryptions; /* calls to encrypt */ u_long authdecryptions; /* calls to decrypt */ /* - * Storage for free key structures. We malloc() such things but + * Storage for free symkey structures. We malloc() such things but * never free them. */ -struct savekey *authfreekeys; +symkey *authfreekeys; int authnumfreekeys; -#define MEMINC 12 /* number of new free ones to get */ +#define MEMINC 16 /* number of new free ones to get */ /* * The key cache. We cache the last key we looked at here. */ keyid_t cache_keyid; /* key identifier */ -u_char *cache_key; /* key pointer */ -u_int cache_keylen; /* key length */ +u_char *cache_secret; /* secret */ +u_short cache_secretsize; /* secret length */ +int cache_type; /* OpenSSL digest NID */ u_short cache_flags; /* flags that wave */ @@ -77,10 +105,213 @@ u_short cache_flags; /* flags that wave */ void init_auth(void) { + size_t newalloc; + /* * Initialize hash table and free list */ - memset((char *)key_hash, 0, sizeof key_hash); + newalloc = authhashbuckets * sizeof(key_hash[0]); + + key_hash = erealloc(key_hash, newalloc); + memset(key_hash, '\0', newalloc); + + INIT_DLIST(key_listhead, llink); + +#ifdef DEBUG + atexit(&free_auth_mem); +#endif +} + + +/* + * free_auth_mem - assist in leak detection by freeing all dynamic + * allocations from this module. + */ +#ifdef DEBUG +static void +free_auth_mem(void) +{ + symkey * sk; + symkey_alloc * alloc; + symkey_alloc * next_alloc; + + while (NULL != (sk = HEAD_DLIST(key_listhead, llink))) { + freesymkey(sk, &key_hash[KEYHASH(sk->keyid)]); + } + free(key_hash); + key_hash = NULL; + cache_keyid = 0; + cache_flags = 0; + for (alloc = authallocs; alloc != NULL; alloc = next_alloc) { + next_alloc = alloc->link; + free(alloc->mem); + } + authfreekeys = NULL; + authnumfreekeys = 0; +} +#endif /* DEBUG */ + + +/* + * auth_moremem - get some more free key structures + */ +void +auth_moremem( + int keycount + ) +{ + symkey * sk; + int i; +#ifdef DEBUG + void * base; + symkey_alloc * allocrec; +# define MOREMEM_EXTRA_ALLOC (sizeof(*allocrec)) +#else +# define MOREMEM_EXTRA_ALLOC (0) +#endif + + i = (keycount > 0) + ? keycount + : MEMINC; + sk = emalloc_zero(i * sizeof(*sk) + MOREMEM_EXTRA_ALLOC); +#ifdef DEBUG + base = sk; +#endif + authnumfreekeys += i; + + for (; i > 0; i--, sk++) { + LINK_SLIST(authfreekeys, sk, llink.f); + } + +#ifdef DEBUG + allocrec = (void *)sk; + allocrec->mem = base; + LINK_SLIST(authallocs, allocrec, link); +#endif +} + + +/* + * auth_prealloc_symkeys + */ +void +auth_prealloc_symkeys( + int keycount + ) +{ + int allocated; + int additional; + + allocated = authnumkeys + authnumfreekeys; + additional = keycount - allocated; + if (additional > 0) + auth_moremem(additional); + auth_resize_hashtable(); +} + + +static inline u_short +auth_log2(double x) +{ + return (u_short)(log10(x) / log10(2)); +} + + +/* + * auth_resize_hashtable + * + * Size hash table to average 4 or fewer entries per bucket initially, + * within the bounds of at least 4 and no more than 15 bits for the hash + * table index. Populate the hash table. + */ +static void +auth_resize_hashtable(void) +{ + u_long totalkeys; + u_short hashbits; + u_short hash; + size_t newalloc; + symkey * sk; + + totalkeys = authnumkeys + authnumfreekeys; + hashbits = auth_log2(totalkeys / 4.0) + 1; + hashbits = max(4, hashbits); + hashbits = min(15, hashbits); + + authhashbuckets = 1 << hashbits; + authhashmask = authhashbuckets - 1; + newalloc = authhashbuckets * sizeof(key_hash[0]); + + key_hash = erealloc(key_hash, newalloc); + memset(key_hash, '\0', newalloc); + + ITER_DLIST_BEGIN(key_listhead, sk, llink, symkey) + hash = KEYHASH(sk->keyid); + LINK_SLIST(key_hash[hash], sk, hlink); + ITER_DLIST_END() +} + + +/* + * allocsymkey - common code to allocate and link in symkey + * + * secret must be allocated with a free-compatible allocator. It is + * owned by the referring symkey structure, and will be free()d by + * freesymkey(). + */ +static void +allocsymkey( + symkey ** bucket, + keyid_t id, + u_short flags, + u_short type, + u_long lifetime, + u_short secretsize, + u_char * secret + ) +{ + symkey * sk; + + if (authnumfreekeys < 1) + auth_moremem(-1); + UNLINK_HEAD_SLIST(sk, authfreekeys, llink.f); + DEBUG_ENSURE(sk != NULL); + sk->keyid = id; + sk->flags = flags; + sk->type = type; + sk->secretsize = secretsize; + sk->secret = secret; + sk->lifetime = lifetime; + LINK_SLIST(*bucket, sk, hlink); + LINK_TAIL_DLIST(key_listhead, sk, llink); + authnumfreekeys--; + authnumkeys++; +} + + +/* + * freesymkey - common code to remove a symkey and recycle its entry. + */ +static void +freesymkey( + symkey * sk, + symkey ** bucket + ) +{ + symkey * unlinked; + + if (sk->secret != NULL) { + memset(sk->secret, '\0', sk->secretsize); + free(sk->secret); + } + UNLINK_SLIST(unlinked, *bucket, sk, hlink, symkey); + DEBUG_ENSURE(sk == unlinked); + UNLINK_DLIST(sk, llink); + memset((char *)sk + offsetof(symkey, symkey_payload), '\0', + sizeof(*sk) - offsetof(symkey, symkey_payload)); + LINK_SLIST(authfreekeys, sk, llink.f); + authnumkeys--; + authnumfreekeys++; } @@ -89,104 +320,100 @@ init_auth(void) */ struct savekey * auth_findkey( - keyid_t keyno + keyid_t id ) { - struct savekey *sk; + symkey * sk; - sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { - if (keyno == sk->keyid) - return (sk); - - sk = sk->next; + for (sk = key_hash[KEYHASH(id)]; sk != NULL; sk = sk->hlink) { + if (id == sk->keyid) { + return sk; + } } - return (0); + + return NULL; } /* - * auth_havekey - return one if the key is known + * auth_havekey - return TRUE if the key id is zero or known */ int auth_havekey( - keyid_t keyno + keyid_t id ) { - struct savekey *sk; - - if (keyno == 0 || (keyno == cache_keyid)) - return (1); + symkey * sk; - sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { - if (keyno == sk->keyid) - return (1); + if (0 == id || cache_keyid == id) { + return TRUE; + } - sk = sk->next; + for (sk = key_hash[KEYHASH(id)]; sk != NULL; sk = sk->hlink) { + if (id == sk->keyid) { + return TRUE; + } } - return (0); + + return FALSE; } /* - * authhavekey - return one and cache the key, if known and trusted. + * authhavekey - return TRUE and cache the key, if zero or both known + * and trusted. */ int authhavekey( - keyid_t keyno + keyid_t id ) { - struct savekey *sk; + symkey * sk; authkeylookups++; - if (keyno == 0 || keyno == cache_keyid) - return (1); + if (0 == id || cache_keyid == id) { + return TRUE; + } + /* + * Seach the bin for the key. If found and the key type + * is zero, somebody marked it trusted without specifying + * a key or key type. In this case consider the key missing. + */ authkeyuncached++; - sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { - if (keyno == sk->keyid) - break; - sk = sk->next; + for (sk = key_hash[KEYHASH(id)]; sk != NULL; sk = sk->hlink) { + if (id == sk->keyid) { + if (0 == sk->type) { + authkeynotfound++; + return FALSE; + } + break; + } } - if (sk == 0) { + + /* + * If the key is not found, or if it is found but not trusted, + * the key is not considered found. + */ + if (NULL == sk) { authkeynotfound++; - return (0); - } else if (!(sk->flags & KEY_TRUSTED)) { + return FALSE; + } + if (!(KEY_TRUSTED & sk->flags)) { authnokey++; - return (0); + return FALSE; } + + /* + * The key is found and trusted. Initialize the key cache. + */ cache_keyid = sk->keyid; + cache_type = sk->type; cache_flags = sk->flags; - if (sk->flags & KEY_MD5) { - cache_key = sk->k.MD5_key; - cache_keylen = sk->keylen; - return (1); - } - return (0); -} + cache_secret = sk->secret; + cache_secretsize = sk->secretsize; - -/* - * auth_moremem - get some more free key structures - */ -int -auth_moremem(void) -{ - struct savekey *sk; - int i; - - sk = (struct savekey *)calloc(MEMINC, sizeof(struct savekey)); - if (sk == 0) - return (0); - - for (i = MEMINC; i > 0; i--) { - sk->next = authfreekeys; - authfreekeys = sk++; - } - authnumfreekeys += MEMINC; - return (authnumfreekeys); + return TRUE; } @@ -195,32 +422,41 @@ auth_moremem(void) */ void authtrust( - keyid_t keyno, - u_long trust + keyid_t id, + u_long trust ) { - struct savekey *sk; + symkey ** bucket; + symkey * sk; + u_long lifetime; -#ifdef DEBUG - if (debug > 2) - printf("authtrust: keyid %08x life %lu\n", keyno, trust); -#endif - sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { - if (keyno == sk->keyid) - break; - sk = sk->next; + /* + * Search bin for key; if it does not exist and is untrusted, + * forget it. + */ + bucket = &key_hash[KEYHASH(id)]; + for (sk = *bucket; sk != NULL; sk = sk->hlink) { + if (id == sk->keyid) + break; } - - if (sk == 0 && !trust) + if (!trust && NULL == sk) return; - - if (sk != 0) { - if (cache_keyid == keyno) { + + /* + * There are two conditions remaining. Either it does not + * exist and is to be trusted or it does exist and is or is + * not to be trusted. + */ + if (sk != NULL) { + if (cache_keyid == id) { cache_flags = 0; cache_keyid = 0; } + /* + * Key exists. If it is to be trusted, say so and + * update its lifetime. + */ if (trust > 0) { sk->flags |= KEY_TRUSTED; if (trust > 1) @@ -230,40 +466,21 @@ authtrust( return; } - sk->flags &= ~KEY_TRUSTED; { - struct savekey *skp; - - skp = key_hash[KEYHASH(keyno)]; - if (skp == sk) { - key_hash[KEYHASH(keyno)] = sk->next; - } else { - while (skp->next != sk) - skp = skp->next; - skp->next = sk->next; - } - authnumkeys--; - - sk->next = authfreekeys; - authfreekeys = sk; - authnumfreekeys++; - } + /* No longer trusted, return it to the free list. */ + freesymkey(sk, bucket); return; } - if (authnumfreekeys == 0) - if (auth_moremem() == 0) - return; - - sk = authfreekeys; - authfreekeys = sk->next; - authnumfreekeys--; - - sk->keyid = keyno; - sk->flags = KEY_TRUSTED; - sk->next = key_hash[KEYHASH(keyno)]; - key_hash[KEYHASH(keyno)] = sk; - authnumkeys++; - return; + /* + * keyid is not present, but the is to be trusted. We allocate + * a new key, but do not specify a key type or secret. + */ + if (trust > 1) { + lifetime = current_time + trust; + } else { + lifetime = 0; + } + allocsymkey(bucket, id, KEY_TRUSTED, 0, lifetime, 0, NULL); } @@ -272,157 +489,153 @@ authtrust( */ int authistrusted( - keyid_t keyno + keyid_t keyno ) { - struct savekey *sk; + symkey * sk; + symkey ** bucket; if (keyno == cache_keyid) - return ((cache_flags & KEY_TRUSTED) != 0); + return !!(KEY_TRUSTED & cache_flags); authkeyuncached++; - sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { + bucket = &key_hash[KEYHASH(keyno)]; + for (sk = *bucket; sk != NULL; sk = sk->hlink) { if (keyno == sk->keyid) - break; - sk = sk->next; + break; } - if (sk == 0) { + if (NULL == sk || !(KEY_TRUSTED & sk->flags)) { authkeynotfound++; - return (0); - } else if (!(sk->flags & KEY_TRUSTED)) { - authkeynotfound++; - return (0); + return FALSE; } - return (1); + return TRUE; } void MD5auth_setkey( keyid_t keyno, + int keytype, const u_char *key, - const int len + size_t len ) { - struct savekey *sk; + symkey * sk; + symkey ** bucket; + u_char * secret; + size_t secretsize; + DEBUG_ENSURE(keytype <= USHRT_MAX); + DEBUG_ENSURE(len < 4 * 1024); /* * See if we already have the key. If so just stick in the * new value. */ - sk = key_hash[KEYHASH(keyno)]; - while (sk != 0) { + bucket = &key_hash[KEYHASH(keyno)]; + for (sk = *bucket; sk != NULL; sk = sk->hlink) { if (keyno == sk->keyid) { - strncpy((char *)sk->k.MD5_key, (const char *)key, - sizeof(sk->k.MD5_key)); - if ((sk->keylen = len) > sizeof(sk->k.MD5_key)) - sk->keylen = sizeof(sk->k.MD5_key); - - sk->flags |= KEY_MD5; + /* TALOS-CAN-0054: make sure we have a new buffer! */ + if (NULL != sk->secret) { + memset(sk->secret, 0, sk->secretsize); + free(sk->secret); + } + sk->secret = emalloc(len); + sk->type = (u_short)keytype; + secretsize = len; + sk->secretsize = (u_short)secretsize; +#ifndef DISABLE_BUG1243_FIX + memcpy(sk->secret, key, secretsize); +#else + strlcpy((char *)sk->secret, (const char *)key, + secretsize); +#endif if (cache_keyid == keyno) { cache_flags = 0; cache_keyid = 0; } return; } - sk = sk->next; } /* * Need to allocate new structure. Do it. */ - if (authnumfreekeys == 0) { - if (auth_moremem() == 0) - return; - } - - sk = authfreekeys; - authfreekeys = sk->next; - authnumfreekeys--; + secretsize = len; + secret = emalloc(secretsize); +#ifndef DISABLE_BUG1243_FIX + memcpy(secret, key, secretsize); +#else + strlcpy((char *)secret, (const char *)key, secretsize); +#endif + allocsymkey(bucket, keyno, 0, (u_short)keytype, 0, + (u_short)secretsize, secret); +#ifdef DEBUG + if (debug >= 4) { + size_t j; + + printf("auth_setkey: key %d type %d len %d ", (int)keyno, + keytype, (int)secretsize); + for (j = 0; j < secretsize; j++) + printf("%02x", secret[j]); + printf("\n"); + } +#endif +} - strncpy((char *)sk->k.MD5_key, (const char *)key, - sizeof(sk->k.MD5_key)); - if ((sk->keylen = len) > sizeof(sk->k.MD5_key)) - sk->keylen = sizeof(sk->k.MD5_key); - sk->keyid = keyno; - sk->flags = KEY_MD5; - sk->lifetime = 0; - sk->next = key_hash[KEYHASH(keyno)]; - key_hash[KEYHASH(keyno)] = sk; - authnumkeys++; - return; -} - /* - * auth_delkeys - delete all known keys, in preparation for rereading - * the keys file (presumably) + * auth_delkeys - delete non-autokey untrusted keys, and clear all info + * except the trusted bit of non-autokey trusted keys, in + * preparation for rereading the keys file. */ void auth_delkeys(void) { - struct savekey *sk; - struct savekey **skp; - int i; + symkey * sk; + + ITER_DLIST_BEGIN(key_listhead, sk, llink, symkey) + if (sk->keyid > NTP_MAXKEY) { /* autokey */ + continue; + } - for (i = 0; i < HASHSIZE; i++) { - skp = &(key_hash[i]); - sk = key_hash[i]; /* - * Leave autokey keys alone. + * Don't lose info as to which keys are trusted. Make + * sure there are no dangling pointers! */ - while (sk != 0 && sk->keyid <= NTP_MAXKEY) { - /* - * Don't lose info as to which keys are trusted. - */ - if (sk->flags & KEY_TRUSTED) { - skp = &(sk->next); - memset(&sk->k, 0, sizeof(sk->k)); - sk->lifetime = 0; - sk->keylen = 0; - sk = sk->next; - } else { - *skp = sk->next; - authnumkeys--; - sk->next = authfreekeys; - authfreekeys = sk; - authnumfreekeys++; - sk = *skp; + if (KEY_TRUSTED & sk->flags) { + if (sk->secret != NULL) { + memset(sk->secret, 0, sk->secretsize); + free(sk->secret); + sk->secret = NULL; /* TALOS-CAN-0054 */ } + sk->secretsize = 0; + sk->lifetime = 0; + } else { + freesymkey(sk, &key_hash[KEYHASH(sk->keyid)]); } - } + ITER_DLIST_END() } + /* * auth_agekeys - delete keys whose lifetimes have expired */ void auth_agekeys(void) { - struct savekey *sk; - struct savekey *skp; - int i; - - for (i = 0; i < HASHSIZE; i++) { - sk = skp = key_hash[i]; - while (sk != 0) { - skp = sk->next; - if (sk->lifetime > 0 && current_time > - sk->lifetime) { - authtrust(sk->keyid, 0); - authkeyexpired++; - } - sk = skp; + symkey * sk; + + ITER_DLIST_BEGIN(key_listhead, sk, llink, symkey) + if (sk->lifetime > 0 && current_time > sk->lifetime) { + freesymkey(sk, &key_hash[KEYHASH(sk->keyid)]); + authkeyexpired++; } - } -#ifdef DEBUG - if (debug) - printf("auth_agekeys: at %lu keys %lu expired %lu\n", - current_time, authnumkeys, authkeyexpired); -#endif + ITER_DLIST_END() + DPRINTF(1, ("auth_agekeys: at %lu keys %lu expired %lu\n", + current_time, authnumkeys, authkeyexpired)); } + /* * authencrypt - generate message authenticator * @@ -430,12 +643,11 @@ auth_agekeys(void) */ int authencrypt( - keyid_t keyno, - u_int32 *pkt, - int length + keyid_t keyno, + u_int32 * pkt, + int length ) -{ - +{\ /* * A zero key identifier means the sender has not verified * the last message was correctly authenticated. The MAC @@ -443,46 +655,40 @@ authencrypt( */ authencryptions++; pkt[length / 4] = htonl(keyno); - if (keyno == 0) { - return (4); + if (0 == keyno) { + return 4; + } + if (!authhavekey(keyno)) { + return 0; } - if (!authhavekey(keyno)) - return (0); - - if (cache_flags & KEY_MD5) - return (MD5authencrypt(cache_key, pkt, length)); - return (0); + return MD5authencrypt(cache_type, cache_secret, pkt, length); } + /* * authdecrypt - verify message authenticator * - * Returns one if authenticator valid, zero if invalid or key not found. + * Returns TRUE if authenticator valid, FALSE if invalid or not found. */ int authdecrypt( - keyid_t keyno, - u_int32 *pkt, - int length, - int size + keyid_t keyno, + u_int32 * pkt, + int length, + int size ) { - /* * A zero key identifier means the sender has not verified - * the last message was correctly authenticated. Nevertheless, - * the authenticator itself is considered valid. + * the last message was correctly authenticated. For our + * purpose this is an invalid authenticator. */ authdecryptions++; - if (keyno == 0) - return (0); - - if (!authhavekey(keyno) || size < 4) - return (0); - - if (cache_flags & KEY_MD5) - return (MD5authdecrypt(cache_key, pkt, length, size)); + if (0 == keyno || !authhavekey(keyno) || size < 4) { + return FALSE; + } - return (0); + return MD5authdecrypt(cache_type, cache_secret, pkt, length, + size); } diff --git a/contrib/ntp/libntp/authreadkeys.c b/contrib/ntp/libntp/authreadkeys.c index 22020f3f8..1c4c07ca5 100644 --- a/contrib/ntp/libntp/authreadkeys.c +++ b/contrib/ntp/libntp/authreadkeys.c @@ -1,6 +1,7 @@ /* * authreadkeys.c - routines to support the reading of the key file */ +#include #include #include @@ -9,20 +10,20 @@ #include "ntp_syslog.h" #include "ntp_stdlib.h" -/* - * Arbitrary long string of ASCII characters. - */ -#define KEY_TYPE_MD5 4 +#ifdef OPENSSL +#include "openssl/objects.h" +#include "openssl/evp.h" +#endif /* OPENSSL */ /* Forwards */ -static char *nexttok P((char **)); +static char *nexttok (char **); /* * nexttok - basic internal tokenizing routine */ static char * nexttok( - char **str + char **str ) { register char *cp; @@ -34,7 +35,7 @@ nexttok( * Space past white space */ while (*cp == ' ' || *cp == '\t') - cp++; + cp++; /* * Save this and space to end of token @@ -42,25 +43,59 @@ nexttok( starttok = cp; while (*cp != '\0' && *cp != '\n' && *cp != ' ' && *cp != '\t' && *cp != '#') - cp++; + cp++; /* * If token length is zero return an error, else set end of * token to zero and return start. */ if (starttok == cp) - return 0; + return NULL; if (*cp == ' ' || *cp == '\t') - *cp++ = '\0'; + *cp++ = '\0'; else - *cp = '\0'; + *cp = '\0'; *str = cp; return starttok; } +/* TALOS-CAN-0055: possibly DoS attack by setting the key file to the + * log file. This is hard to prevent (it would need to check two files + * to be the same on the inode level, which will not work so easily with + * Windows or VMS) but we can avoid the self-amplification loop: We only + * log the first 5 errors, silently ignore the next 10 errors, and give + * up when when we have found more than 15 errors. + * + * This avoids the endless file iteration we will end up with otherwise, + * and also avoids overflowing the log file. + * + * Nevertheless, once this happens, the keys are gone since this would + * require a save/swap strategy that is not easy to apply due to the + * data on global/static level. + */ + +static const size_t nerr_loglimit = 5u; +static const size_t nerr_maxlimit = 15; + +static void log_maybe(size_t*, const char*, ...) NTP_PRINTF(2, 3); + +static void +log_maybe( + size_t *pnerr, + const char *fmt , + ...) +{ + va_list ap; + if (++(*pnerr) <= nerr_loglimit) { + va_start(ap, fmt); + mvsyslog(LOG_ERR, fmt, ap); + va_end(ap); + } +} + /* * authreadkeys - (re)read keys from a file. */ @@ -69,21 +104,26 @@ authreadkeys( const char *file ) { - FILE *fp; - char *line; - char *token; - u_long keyno; - int keytype; - char buf[512]; /* lots of room for line */ - + FILE *fp; + char *line; + char *token; + keyid_t keyno; + int keytype; + char buf[512]; /* lots of room for line */ + u_char keystr[32]; /* Bug 2537 */ + size_t len; + size_t j; + size_t nerr; /* * Open file. Complain and return if it can't be opened. */ fp = fopen(file, "r"); if (fp == NULL) { - msyslog(LOG_ERR, "can't open key file %s: %m", file); - return 0; + msyslog(LOG_ERR, "authreadkeys: file %s: %m", + file); + return (0); } + INIT_SSL(); /* * Remove all existing keys @@ -93,70 +133,128 @@ authreadkeys( /* * Now read lines from the file, looking for key entries */ + nerr = 0; while ((line = fgets(buf, sizeof buf, fp)) != NULL) { + if (nerr > nerr_maxlimit) + break; token = nexttok(&line); - if (token == 0) - continue; + if (token == NULL) + continue; /* * First is key number. See if it is okay. */ keyno = atoi(token); if (keyno == 0) { - msyslog(LOG_ERR, - "cannot change keyid 0, key entry `%s' ignored", - token); + log_maybe(&nerr, + "authreadkeys: cannot change key %s", + token); continue; } if (keyno > NTP_MAXKEY) { - msyslog(LOG_ERR, - "keyid's > %d reserved for autokey, key entry `%s' ignored", - NTP_MAXKEY, token); + log_maybe(&nerr, + "authreadkeys: key %s > %d reserved for Autokey", + token, NTP_MAXKEY); continue; } /* - * Next is keytype. See if that is all right. + * Next is keytype. See if that is all right. */ token = nexttok(&line); - if (token == 0) { - msyslog(LOG_ERR, - "no key type for key number %ld, entry ignored", - keyno); + if (token == NULL) { + log_maybe(&nerr, + "authreadkeys: no key type for key %d", + keyno); + continue; + } +#ifdef OPENSSL + /* + * The key type is the NID used by the message digest + * algorithm. There are a number of inconsistencies in + * the OpenSSL database. We attempt to discover them + * here and prevent use of inconsistent data later. + */ + keytype = keytype_from_text(token, NULL); + if (keytype == 0) { + log_maybe(&nerr, + "authreadkeys: invalid type for key %d", + keyno); continue; } - switch (*token) { - case 'M': - case 'm': - keytype = KEY_TYPE_MD5; break; - default: - msyslog(LOG_ERR, - "invalid key type for key number %ld, entry ignored", - keyno); + if (EVP_get_digestbynid(keytype) == NULL) { + log_maybe(&nerr, + "authreadkeys: no algorithm for key %d", + keyno); continue; } +#else /* !OPENSSL follows */ /* - * Finally, get key and insert it + * The key type is unused, but is required to be 'M' or + * 'm' for compatibility. + */ + if (!(*token == 'M' || *token == 'm')) { + log_maybe(&nerr, + "authreadkeys: invalid type for key %d", + keyno); + continue; + } + keytype = KEY_TYPE_MD5; +#endif /* !OPENSSL */ + + /* + * Finally, get key and insert it. If it is longer than 20 + * characters, it is a binary string encoded in hex; + * otherwise, it is a text string of printable ASCII + * characters. */ token = nexttok(&line); - if (token == 0) { - msyslog(LOG_ERR, - "no key for number %ld entry, entry ignored", - keyno); + if (token == NULL) { + log_maybe(&nerr, + "authreadkeys: no key for key %d", keyno); + continue; + } + len = strlen(token); + if (len <= 20) { /* Bug 2537 */ + MD5auth_setkey(keyno, keytype, (u_char *)token, len); } else { - switch(keytype) { - case KEY_TYPE_MD5: - if (!authusekey(keyno, keytype, - (u_char *)token)) - msyslog(LOG_ERR, - "format/parity error for MD5 key %ld, not used", - keyno); - break; + char hex[] = "0123456789abcdef"; + u_char temp; + char *ptr; + size_t jlim; + + jlim = min(len, 2 * sizeof(keystr)); + for (j = 0; j < jlim; j++) { + ptr = strchr(hex, tolower((unsigned char)token[j])); + if (ptr == NULL) + break; /* abort decoding */ + temp = (u_char)(ptr - hex); + if (j & 1) + keystr[j / 2] |= temp; + else + keystr[j / 2] = temp << 4; + } + if (j < jlim) { + log_maybe(&nerr, + "authreadkeys: invalid hex digit for key %d", + keyno); + continue; } + MD5auth_setkey(keyno, keytype, keystr, jlim / 2); } } - (void) fclose(fp); - return 1; + fclose(fp); + if (nerr > nerr_maxlimit) { + msyslog(LOG_ERR, + "authreadkeys: emergency break after %u errors", + nerr); + return (0); + } else if (nerr > nerr_loglimit) { + msyslog(LOG_ERR, + "authreadkeys: found %u more error(s)", + nerr - nerr_loglimit); + } + return (1); } diff --git a/contrib/ntp/libntp/authusekey.c b/contrib/ntp/libntp/authusekey.c index 40dd3737d..c1d08132c 100644 --- a/contrib/ntp/libntp/authusekey.c +++ b/contrib/ntp/libntp/authusekey.c @@ -1,6 +1,7 @@ /* * authusekey - decode a key from ascii and use it */ +#include #include #include @@ -15,9 +16,6 @@ * high order bit of each byte a parity bit. "Ascii" means a 1-to-8 * character string whose ascii representation is used as the key. */ - -#define KEY_TYPE_MD5 4 - int authusekey( keyid_t keyno, @@ -25,23 +23,12 @@ authusekey( const u_char *str ) { - const u_char *cp; int len; - cp = str; - len = strlen((const char *)cp); - if (len == 0) - return 0; - - switch(keytype) { - case KEY_TYPE_MD5: - MD5auth_setkey(keyno, str, (int)strlen((const char *)str)); - break; - - default: - /* Oh, well */ + len = strlen((const char *)str); + if (0 == len) return 0; - } + MD5auth_setkey(keyno, keytype, str, len); return 1; } diff --git a/contrib/ntp/libntp/strerror.c b/contrib/ntp/libntp/bsd_strerror.c similarity index 92% rename from contrib/ntp/libntp/strerror.c rename to contrib/ntp/libntp/bsd_strerror.c index 9d8ae8e4f..5ace9aa48 100644 --- a/contrib/ntp/libntp/strerror.c +++ b/contrib/ntp/libntp/bsd_strerror.c @@ -39,9 +39,10 @@ strerror( static char ebuf[20]; if ((unsigned int)errnum < sys_nerr) - return(sys_errlist[errnum]); - (void)sprintf(ebuf, "Unknown error: %d", errnum); - return(ebuf); + return sys_errlist[errnum]; + snprintf(ebuf, sizeof(ebuf), "Unknown error: %d", errnum); + + return ebuf; } #else int strerror_bs; diff --git a/contrib/ntp/libntp/buftvtots.c b/contrib/ntp/libntp/buftvtots.c index bfceb35da..a77e9f7c9 100644 --- a/contrib/ntp/libntp/buftvtots.c +++ b/contrib/ntp/libntp/buftvtots.c @@ -9,8 +9,9 @@ #endif #include "ntp_fp.h" #include "ntp_string.h" -#include "ntp_unixtime.h" +#include "timevalops.h" +#ifndef SYS_WINNT int buftvtots( const char *bufp, @@ -27,9 +28,11 @@ buftvtots( /* * and use it */ - ts->l_ui = tv.tv_sec + (u_long)JAN_1970; - if (tv.tv_usec > 999999) - return 0; - TVUTOTSF(tv.tv_usec, ts->l_uf); - return 1; + if (tv.tv_usec > MICROSECONDS - 1) + return FALSE; + + *ts = tval_stamp_to_lfp(tv); + + return TRUE; } +#endif /* !SYS_WINNT */ diff --git a/contrib/ntp/libntp/caljulian.c b/contrib/ntp/libntp/caljulian.c index 71123dfe2..4a306033a 100644 --- a/contrib/ntp/libntp/caljulian.c +++ b/contrib/ntp/libntp/caljulian.c @@ -1,146 +1,41 @@ /* * caljulian - determine the Julian date from an NTP time. + * + * (Note: since we use the GREGORIAN calendar, this should be renamed to + * 'calgregorian' eventually...) */ +#include #include #include "ntp_types.h" #include "ntp_calendar.h" -#include "ntp_stdlib.h" -#include "ntp_fp.h" -#if 0 -/* - * calmonthtab - days-in-the-month table - */ -static u_short calmonthtab[11] = { - JAN, - FEB, - MAR, - APR, - MAY, - JUN, - JUL, - AUG, - SEP, - OCT, - NOV -}; +#if !(defined(ISC_CHECK_ALL) || defined(ISC_CHECK_NONE) || \ + defined(ISC_CHECK_ENSURE) || defined(ISC_CHECK_INSIST) || \ + defined(ISC_CHECK_INVARIANT)) +# define ISC_CHECK_ALL +#endif + +#include "ntp_assert.h" void caljulian( - u_long ntptime, - register struct calendar *jt + uint32_t ntp, + struct calendar * jt ) { - u_long ntp_day; - u_long minutes; - /* - * Absolute, zero-adjusted Christian era day, starting from the - * mythical day 12/1/1 BC - */ - u_long acez_day; - - u_long d400; /* Days into a Gregorian cycle */ - u_long d100; /* Days into a normal century */ - u_long d4; /* Days into a 4-year cycle */ - u_long n400; /* # of Gregorian cycles */ - u_long n100; /* # of normal centuries */ - u_long n4; /* # of 4-year cycles */ - u_long n1; /* # of years into a leap year */ - /* cycle */ + vint64 vlong; + ntpcal_split split; + + + INSIST(NULL != jt); /* - * Do the easy stuff first: take care of hh:mm:ss, ignoring leap - * seconds + * Unfold ntp time around current time into NTP domain. Split + * into days and seconds, shift days into CE domain and + * process the parts. */ - jt->second = (u_char)(ntptime % SECSPERMIN); - minutes = ntptime / SECSPERMIN; - jt->minute = (u_char)(minutes % MINSPERHR); - jt->hour = (u_char)((minutes / MINSPERHR) % HRSPERDAY); - - /* - * Find the day past 1900/01/01 00:00 UTC - */ - ntp_day = ntptime / SECSPERDAY; - acez_day = DAY_NTP_STARTS + ntp_day - 1; - n400 = acez_day/GREGORIAN_CYCLE_DAYS; - d400 = acez_day%GREGORIAN_CYCLE_DAYS; - n100 = d400 / GREGORIAN_NORMAL_CENTURY_DAYS; - d100 = d400 % GREGORIAN_NORMAL_CENTURY_DAYS; - n4 = d100 / GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; - d4 = d100 % GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; - n1 = d4 / DAYSPERYEAR; - - /* - * Calculate the year and year-of-day - */ - jt->yearday = (u_short)(1 + d4%DAYSPERYEAR); - jt->year = (u_short)(400*n400 + 100*n100 + n4*4 + n1); - - if (n100 == 4 || n1 == 4) - { - /* - * If the cycle year ever comes out to 4, it must be December 31st - * of a leap year. - */ - jt->month = 12; - jt->monthday = 31; - jt->yearday = 366; - } - else - { - /* - * Else, search forwards through the months to get the right month - * and date. - */ - int monthday; - - jt->year++; - monthday = jt->yearday; - - for (jt->month=0;jt->month<11; jt->month++) - { - int t; - - t = monthday - calmonthtab[jt->month]; - if (jt->month == 1 && is_leapyear(jt->year)) - t--; - - if (t > 0) - monthday = t; - else - break; - } - jt->month++; - jt->monthday = (u_char) monthday; - } -} -#else - -/* Updated 2003-12-30 TMa - - Uses common code with the *prettydate functions to convert an ntp - seconds count into a calendar date. - Will handle ntp epoch wraparound as long as the underlying os/library - does so for the unix epoch, i.e. works after 2038. -*/ - -void -caljulian( - u_long ntptime, - register struct calendar *jt - ) -{ - struct tm *tm; - - tm = ntp2unix_tm(ntptime, 0); - - jt->hour = (u_char) tm->tm_hour; - jt->minute = (u_char) tm->tm_min; - jt->month = (u_char) (tm->tm_mon + 1); - jt->monthday = (u_char) tm->tm_mday; - jt->second = (u_char) tm->tm_sec; - jt->year = (u_short) (tm->tm_year + 1900); - jt->yearday = (u_short) (tm->tm_yday + 1); /* Assumes tm_yday starts with day 0! */ + vlong = ntpcal_ntp_to_ntp(ntp, NULL); + split = ntpcal_daysplit(&vlong); + ntpcal_daysplit_to_date(jt, &split, DAY_NTP_STARTS); } -#endif diff --git a/contrib/ntp/libntp/caltontp.c b/contrib/ntp/libntp/caltontp.c index 9ec106416..808c94c64 100644 --- a/contrib/ntp/libntp/caltontp.c +++ b/contrib/ntp/libntp/caltontp.c @@ -1,42 +1,68 @@ /* * caltontp - convert a date to an NTP time */ +#include #include #include "ntp_types.h" #include "ntp_calendar.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" +#include "ntp_unixtime.h" -u_long +/* + * Juergen Perlinger, 2008-11-12 + * Add support for full calendar calculatios. If the day-of-year is provided + * (that is, not zero) it will be used instead of month and day-of-month; + * otherwise a full turn through the calendar calculations will be taken. + * + * I know that Harlan Stenn likes to see assertions in production code, and I + * agree there, but it would be a tricky thing here. The algorithm is quite + * capable of producing sensible answers even to seemingly weird inputs: the + * date -03-00, the 0.th March of the year, will be automtically + * treated as the last day of February, no matter whether the year is a leap + * year or not. So adding constraints is merely for the benefit of the callers, + * because the only thing we can check for consistency is our input, produced + * by somebody else. + * + * BTW: A total roundtrip using 'caljulian' would be a quite shaky thing: + * Because of the truncation of the NTP time stamp to 32 bits and the epoch + * unfolding around the current time done by 'caljulian' the roundtrip does + * *not* necessarily reproduce the input, especially if the time spec is more + * than 68 years off from the current time... + */ + +uint32_t caltontp( - register const struct calendar *jt + const struct calendar *jt ) { - u_long ace_days; /* absolute Christian Era days */ - u_long ntp_days; - int prior_years; - u_long ntp_time; - - /* - * First convert today's date to absolute days past 12/1/1 BC - */ - prior_years = jt->year-1; - ace_days = jt->yearday /* days this year */ - +(DAYSPERYEAR*prior_years) /* plus days in previous years */ - +(prior_years/4) /* plus prior years's leap days */ - -(prior_years/100) /* minus leapless century years */ - +(prior_years/400); /* plus leapful Gregorian yrs */ + int32_t eraday; /* CE Rata Die number */ + vint64 ntptime;/* resulting NTP time */ + + REQUIRE(jt != NULL); - /* - * Subtract out 1/1/1900, the beginning of the NTP epoch - */ - ntp_days = ace_days - DAY_NTP_STARTS; + REQUIRE(jt->month <= 13); /* permit month 0..13! */ + REQUIRE(jt->monthday <= 32); + REQUIRE(jt->yearday <= 366); + REQUIRE(jt->hour <= 24); + REQUIRE(jt->minute <= MINSPERHR); + REQUIRE(jt->second <= SECSPERMIN); - /* - * Do the obvious: - */ - ntp_time = - ntp_days*SECSPERDAY+SECSPERMIN*(MINSPERHR*jt->hour + jt->minute); + /* + * First convert the date to he corresponding RataDie + * number. If yearday is not zero, assume that it contains a + * useable value and avoid all calculations involving month + * and day-of-month. Do a full evaluation otherwise. + */ + if (jt->yearday) + eraday = ntpcal_year_to_ystart(jt->year) + + jt->yearday - 1; + else + eraday = ntpcal_date_to_rd(jt); - return ntp_time; + ntptime = ntpcal_dayjoin(eraday - DAY_NTP_STARTS, + ntpcal_etime_to_seconds(jt->hour, jt->minute, + jt->second)); + return ntptime.d_s.lo; } diff --git a/contrib/ntp/libntp/calyearstart.c b/contrib/ntp/libntp/calyearstart.c index 0f7ca4f9d..9e3f58fb3 100644 --- a/contrib/ntp/libntp/calyearstart.c +++ b/contrib/ntp/libntp/calyearstart.c @@ -2,21 +2,87 @@ * calyearstart - determine the NTP time at midnight of January 1 in * the year of the given date. */ +#include #include #include "ntp_types.h" #include "ntp_calendar.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" -u_long -calyearstart(u_long ntp_time) +/* + * Juergen Perlinger, 2010-05-02 + * + * Redone in terms of the calendar functions. It's rather simple: + * - expand the NTP time stamp + * - split into days and seconds since midnight, dropping the partial day + * - get full number of days before year start in NTP epoch + * - convert to seconds, truncated to 32 bits. + */ +u_int32 +calyearstart(u_int32 ntptime, const time_t *pivot) +{ + u_int32 ndays; /* elapsed days since NTP starts */ + vint64 vlong; + ntpcal_split split; + + vlong = ntpcal_ntp_to_ntp(ntptime, pivot); + split = ntpcal_daysplit(&vlong); + ndays = ntpcal_rd_to_ystart(split.hi + DAY_NTP_STARTS) + - DAY_NTP_STARTS; + + return (u_int32)(ndays * SECSPERDAY); +} + +/* + * calmonthstart - get NTP time at midnight of the first day of the + * current month. + */ +u_int32 +calmonthstart(u_int32 ntptime, const time_t *pivot) +{ + u_int32 ndays; /* elapsed days since NTP starts */ + vint64 vlong; + ntpcal_split split; + + vlong = ntpcal_ntp_to_ntp(ntptime, pivot); + split = ntpcal_daysplit(&vlong); + ndays = ntpcal_rd_to_mstart(split.hi + DAY_NTP_STARTS) + - DAY_NTP_STARTS; + + return (u_int32)(ndays * SECSPERDAY); +} + +/* + * calweekstart - get NTP time at midnight of the last monday on or + * before the current date. + */ +u_int32 +calweekstart(u_int32 ntptime, const time_t *pivot) +{ + u_int32 ndays; /* elapsed days since NTP starts */ + vint64 vlong; + ntpcal_split split; + + vlong = ntpcal_ntp_to_ntp(ntptime, pivot); + split = ntpcal_daysplit(&vlong); + ndays = ntpcal_weekday_le(split.hi + DAY_NTP_STARTS, CAL_MONDAY) + - DAY_NTP_STARTS; + + return (u_int32)(ndays * SECSPERDAY); +} + +/* + * caldaystart - get NTP time at midnight of the current day. + */ +u_int32 +caldaystart(u_int32 ntptime, const time_t *pivot) { - struct calendar jt; - - caljulian(ntp_time,&jt); - jt.yearday = 1; - jt.monthday = 1; - jt.month = 1; - jt.hour = jt.minute = jt.second = 0; - return caltontp(&jt); + vint64 vlong; + ntpcal_split split; + + vlong = ntpcal_ntp_to_ntp(ntptime, pivot); + split = ntpcal_daysplit(&vlong); + + return ntptime - split.lo; } diff --git a/contrib/ntp/libntp/clocktime.c b/contrib/ntp/libntp/clocktime.c index 371859cda..c1a3ba09c 100644 --- a/contrib/ntp/libntp/clocktime.c +++ b/contrib/ntp/libntp/clocktime.c @@ -2,131 +2,148 @@ * clocktime - compute the NTP date from a day of year, hour, minute * and second. */ +#include #include "ntp_fp.h" #include "ntp_unixtime.h" #include "ntp_stdlib.h" +#include "ntp_calendar.h" /* - * Hacks to avoid excercising the multiplier. I have no pride. + * We check that the time be within CLOSETIME seconds of the receive + * time stamp. This is about 4 hours, which hopefully should be wide + * enough to collect most data, while close enough to keep things from + * getting confused. */ -#define MULBY10(x) (((x)<<3) + ((x)<<1)) -#define MULBY60(x) (((x)<<6) - ((x)<<2)) /* watch overflow */ -#define MULBY24(x) (((x)<<4) + ((x)<<3)) +#define CLOSETIME (4u*60u*60u) /* - * Two days, in seconds. + * Since we try to match years, the result of a full search will not + * change when we are already less than a half year from the receive + * time stamp. Since the length of a year is variable we use a + * slightly narrower limit; this might require a full evaluation near + * the edge, but will make sure we always get the correct result. */ -#define TWODAYS (2*24*60*60) +#define NEARTIME (182u * SECSPERDAY) /* - * We demand that the time be within CLOSETIME seconds of the receive - * time stamp. This is about 4 hours, which hopefully should be - * wide enough to collect most data, while close enough to keep things - * from getting confused. + * local calendar helpers */ -#define CLOSETIME (4*60*60) - +static int32 ntp_to_year(u_int32); +static u_int32 year_to_ntp(int32); +/* + * Take a time spec given as day-of-year, hour, minute and second as + * well as a GMT offset in hours and convert it to a NTP time stamp in + * '*ts_ui'. The value will be in the range (rec_ui-0.5yrs) to + * (rec_ui+0.5yrs). A hint for the current start-of-year will be + * read from '*yearstart'. + * + * On return '*ts_ui' will always the best matching solution, and + * '*yearstart' will receive the associated start-of-year. + * + * The function will tell if the result in 'ts_ui' is in CLOSETIME + * (+/-4hrs) around the receive time by returning a non-zero value. + * + * Note: The function puts no constraints on the value ranges for the + * time specification, but evaluates the effective seconds in + * 32-bit arithmetic. + */ int clocktime( - int yday, - int hour, - int minute, - int second, - int tzoff, - u_long rec_ui, - u_long *yearstart, - u_int32 *ts_ui - ) + int yday , /* day-of-year */ + int hour , /* hour of day */ + int minute , /* minute of hour */ + int second , /* second of minute */ + int tzoff , /* hours west of GMT */ + u_int32 rec_ui , /* pivot value */ + u_long *yearstart, /* cached start-of-year, should be fixed to u_int32 */ + u_int32 *ts_ui ) /* effective time stamp */ { - register long tmp; - register u_long date; - register u_long yst; - + u_int32 ystt[3]; /* year start */ + u_int32 test[3]; /* result time stamp */ + u_int32 diff[3]; /* abs difference to receive */ + int32 y, tmp, idx, min; + /* - * Compute the offset into the year in seconds. Note that + * Compute the offset into the year in seconds. Note that * this could come out to be a negative number. */ - tmp = (long)(MULBY24((yday-1)) + hour + tzoff); - tmp = MULBY60(tmp) + (long)minute; - tmp = MULBY60(tmp) + (long)second; - + tmp = ((int32)second + + SECSPERMIN * ((int32)minute + + MINSPERHR * ((int32)hour + (int32)tzoff + + HRSPERDAY * ((int32)yday - 1)))); /* - * Initialize yearstart, if necessary. + * Based on the cached year start, do a first attempt. Be + * happy and return if this gets us better than NEARTIME to + * the receive time stamp. Do this only if the cached year + * start is not zero, which will not happen after 1900 for the + * next few thousand years. */ - yst = *yearstart; - if (yst == 0) { - yst = calyearstart(rec_ui); - *yearstart = yst; + if (*yearstart) { + /* -- get time stamp of potential solution */ + test[0] = (u_int32)(*yearstart) + tmp; + /* -- calc absolute difference to receive time */ + diff[0] = test[0] - rec_ui; + if (diff[0] >= 0x80000000u) + diff[0] = ~diff[0] + 1; + /* -- can't get closer if diff < NEARTIME */ + if (diff[0] < NEARTIME) { + *ts_ui = test[0]; + return diff[0] < CLOSETIME; + } } /* - * Now the fun begins. We demand that the received clock time - * be within CLOSETIME of the receive timestamp, but - * there is uncertainty about the year the timestamp is in. - * Use the current year start for the first check, this should - * work most of the time. + * Now the dance begins. Based on the receive time stamp and + * the seconds offset in 'tmp', we make an educated guess + * about the year to start with. This takes us on the spot + * with a fuzz of +/-1 year. + * + * We calculate the effective timestamps for the three years + * around the guess and select the entry with the minimum + * absolute difference to the receive time stamp. */ - date = (u_long)(tmp + (long)yst); - if (date < (rec_ui + CLOSETIME) && - date > (rec_ui - CLOSETIME)) { - *ts_ui = date; - return 1; + y = ntp_to_year(rec_ui - tmp); + for (idx = 0; idx < 3; idx++) { + /* -- get year start of potential solution */ + ystt[idx] = year_to_ntp(y + idx - 1); + /* -- get time stamp of potential solution */ + test[idx] = ystt[idx] + tmp; + /* -- calc absolute difference to receive time */ + diff[idx] = test[idx] - rec_ui; + if (diff[idx] >= 0x80000000u) + diff[idx] = ~diff[idx] + 1; } + /* -*- assume current year fits best, then search best fit */ + for (min = 1, idx = 0; idx < 3; idx++) + if (diff[idx] < diff[min]) + min = idx; + /* -*- store results and update year start */ + *ts_ui = test[min]; + *yearstart = ystt[min]; - /* - * Trouble. Next check is to see if the year rolled over and, if - * so, try again with the new year's start. - */ - yst = calyearstart(rec_ui); - if (yst != *yearstart) { - date = (u_long)((long)yst + tmp); - *ts_ui = date; - if (date < (rec_ui + CLOSETIME) && - date > (rec_ui - CLOSETIME)) { - *yearstart = yst; - return 1; - } - } + /* -*- tell if we could get into CLOSETIME*/ + return diff[min] < CLOSETIME; +} - /* - * Here we know the year start matches the current system - * time. One remaining possibility is that the time code - * is in the year previous to that of the system time. This - * is only worth checking if the receive timestamp is less - * than a couple of days into the new year. - */ - if ((rec_ui - yst) < TWODAYS) { - yst = calyearstart(yst - TWODAYS); - if (yst != *yearstart) { - date = (u_long)(tmp + (long)yst); - if (date < (rec_ui + CLOSETIME) && - date > (rec_ui - CLOSETIME)) { - *yearstart = yst; - *ts_ui = date; - return 1; - } - } - } +static int32 +ntp_to_year( + u_int32 ntp) +{ + vint64 t; + ntpcal_split s; - /* - * One last possibility is that the time stamp is in the year - * following the year the system is in. Try this one before - * giving up. - */ - yst = calyearstart(rec_ui + TWODAYS); - if (yst != *yearstart) { - date = (u_long)((long)yst + tmp); - if (date < (rec_ui + CLOSETIME) && - date > (rec_ui - CLOSETIME)) { - *yearstart = yst; - *ts_ui = date; - return 1; - } - } + t = ntpcal_ntp_to_ntp(ntp, NULL); + s = ntpcal_daysplit(&t); + s = ntpcal_split_eradays(s.hi + DAY_NTP_STARTS - 1, NULL); + return s.hi + 1; +} - /* - * Give it up. - */ - return 0; +static u_int32 +year_to_ntp( + int32 year) +{ + u_int32 days; + days = ntpcal_days_in_years(year-1) - DAY_NTP_STARTS + 1; + return days * SECSPERDAY; } diff --git a/contrib/ntp/libntp/clocktypes.c b/contrib/ntp/libntp/clocktypes.c index d7dc4ee09..de7f6b4f3 100644 --- a/contrib/ntp/libntp/clocktypes.c +++ b/contrib/ntp/libntp/clocktypes.c @@ -1,6 +1,7 @@ /* * Data for pretty printing clock types */ +#include #include #include "ntp_fp.h" @@ -68,8 +69,8 @@ struct clktype clktypes[] = { "MSF_ARCRON" }, { REFCLK_SHM, "Clock attached thru shared Memory (28)", "SHM" }, - { REFCLK_PALISADE, "Trimble Navigation Palisade GPS (29)", - "GPS_PALISADE" }, + { REFCLK_PALISADE, "Trimble Navigation Palisade GPS (29)", + "GPS_PALISADE" }, { REFCLK_ONCORE, "Motorola UT Oncore GPS (30)", "GPS_ONCORE" }, { REFCLK_GPS_JUPITER, "Rockwell Jupiter GPS (31)", @@ -78,7 +79,7 @@ struct clktype clktypes[] = { "CHRONOLOG" }, { REFCLK_DUMBCLOCK, "Dumb generic hh:mm:ss local clock (33)", "DUMBCLOCK" }, - { REFCLK_ULINK, "Ultralink M320 WWVB receiver (34)", + { REFCLK_ULINK, "Ultralink M320 WWVB receiver (34)", "ULINK_M320"}, { REFCLK_PCF, "Conrad parallel port radio clock (35)", "PCF"}, @@ -100,6 +101,10 @@ struct clktype clktypes[] = { "GPS_RIPENCC" }, { REFCLK_NEOCLOCK4X, "NeoClock4X DCF77 / TDF receiver (44)", "NEOCLK4X"}, + { REFCLK_TSYNCPCI, "Spectracom TSYNC PCI timing board (45)", + "PCI_TSYNC"}, + { REFCLK_GPSDJSON, "GPSD JSON socket (46)", + "GPSD_JSON"}, { -1, "", "" } }; @@ -112,7 +117,7 @@ clockname( for (clk = clktypes; clk->code != -1; clk++) { if (num == clk->code) - return (clk->abbrev); + return (clk->abbrev); } return (NULL); } diff --git a/contrib/ntp/libntp/decodenetnum.c b/contrib/ntp/libntp/decodenetnum.c index 746c855d8..35b908f39 100644 --- a/contrib/ntp/libntp/decodenetnum.c +++ b/contrib/ntp/libntp/decodenetnum.c @@ -1,39 +1,86 @@ /* * decodenetnum - return a net number (this is crude, but careful) */ +#include #include #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif +#ifdef HAVE_NETINET_IN_H #include +#endif +#include "ntp.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" +/* + * decodenetnum convert text IP address and port to sockaddr_u + * + * Returns 0 for failure, 1 for success. + */ int decodenetnum( const char *num, - struct sockaddr_storage *netnum + sockaddr_u *netnum ) { struct addrinfo hints, *ai = NULL; - register int err, i; - register const char *cp; + int err; + u_short port; + const char *cp; + const char *port_str; + char *pp; + char *np; char name[80]; - cp = num; + REQUIRE(num != NULL); + + if (strlen(num) >= sizeof(name)) { + return 0; + } - if (*cp == '[') { - cp++; - for (i = 0; *cp != ']'; cp++, i++) - name[i] = *cp; - name[i] = '\0'; - num = name; + port_str = NULL; + if ('[' != num[0]) { + /* + * to distinguish IPv6 embedded colons from a port + * specification on an IPv4 address, assume all + * legal IPv6 addresses have at least two colons. + */ + pp = strchr(num, ':'); + if (NULL == pp) + cp = num; /* no colons */ + else if (NULL != strchr(pp + 1, ':')) + cp = num; /* two or more colons */ + else { /* one colon */ + strlcpy(name, num, sizeof(name)); + cp = name; + pp = strchr(cp, ':'); + *pp = '\0'; + port_str = pp + 1; + } + } else { + cp = num + 1; + np = name; + while (*cp && ']' != *cp) + *np++ = *cp++; + *np = 0; + if (']' == cp[0] && ':' == cp[1] && '\0' != cp[2]) + port_str = &cp[2]; + cp = name; } - memset(&hints, 0, sizeof(struct addrinfo)); - hints.ai_flags = AI_NUMERICHOST; - err = getaddrinfo(num, NULL, &hints, &ai); + ZERO(hints); + hints.ai_flags = Z_AI_NUMERICHOST; + err = getaddrinfo(cp, "ntp", &hints, &ai); if (err != 0) return 0; - memcpy(netnum, (struct sockaddr_storage *)ai->ai_addr, ai->ai_addrlen); + INSIST(ai->ai_addrlen <= sizeof(*netnum)); + ZERO(*netnum); + memcpy(netnum, ai->ai_addr, ai->ai_addrlen); freeaddrinfo(ai); + if (NULL == port_str || 1 != sscanf(port_str, "%hu", &port)) + port = NTP_PORT; + SET_PORT(netnum, port); return 1; } diff --git a/contrib/ntp/libntp/dofptoa.c b/contrib/ntp/libntp/dofptoa.c index 0f96909f1..758af2fd7 100644 --- a/contrib/ntp/libntp/dofptoa.c +++ b/contrib/ntp/libntp/dofptoa.c @@ -1,6 +1,7 @@ /* * dofptoa - do the grunge work to convert an fp number to ascii */ +#include #include #include "ntp_fp.h" @@ -32,7 +33,7 @@ dofptoa( /* * Zero out the buffer */ - memset((char *)cbuf, 0, sizeof cbuf); + ZERO(cbuf); /* * Set the pointers to point at the first @@ -116,3 +117,43 @@ dofptoa( *bp = '\0'; return buf; } + + +char * +fptoa( + s_fp fpv, + short ndec + ) +{ + u_fp plusfp; + int neg; + + neg = (fpv < 0); + if (neg) { + plusfp = (u_fp)(-fpv); + } else { + plusfp = (u_fp)fpv; + } + + return dofptoa(plusfp, neg, ndec, FALSE); +} + + +char * +fptoms( + s_fp fpv, + short ndec + ) +{ + u_fp plusfp; + int neg; + + neg = (fpv < 0); + if (neg) { + plusfp = (u_fp)(-fpv); + } else { + plusfp = (u_fp)fpv; + } + + return dofptoa(plusfp, neg, ndec, TRUE); +} diff --git a/contrib/ntp/libntp/dolfptoa.c b/contrib/ntp/libntp/dolfptoa.c index f68679cf0..07ead950f 100644 --- a/contrib/ntp/libntp/dolfptoa.c +++ b/contrib/ntp/libntp/dolfptoa.c @@ -1,6 +1,7 @@ /* * dolfptoa - do the grunge work of converting an l_fp number to decimal */ +#include #include #include "ntp_fp.h" @@ -10,20 +11,17 @@ char * dolfptoa( - u_long fpi, - u_long fpv, + u_int32 fpi, + u_int32 fpv, int neg, short ndec, int msec ) { - register u_char *cp, *cpend; - register u_long lwork; - register int dec; + u_char *cp, *cpend, *cpdec; + int dec; u_char cbuf[24]; - u_char *cpdec; - char *buf; - char *bp; + char *buf, *bp; /* * Get a string buffer before starting @@ -33,113 +31,81 @@ dolfptoa( /* * Zero the character buffer */ - memset((char *) cbuf, 0, sizeof(cbuf)); + ZERO(cbuf); /* - * safeguard against sign extensions and other mishaps on 64 bit platforms - * the code following is designed for and only for 32-bit inputs and - * only 32-bit worth of input are supplied. - */ - fpi &= 0xffffffff; - fpv &= 0xffffffff; - - /* - * Work on the integral part. This is biased by what I know - * compiles fairly well for a 68000. + * Work on the integral part. This should work reasonable on + * all machines with 32 bit arithmetic. Please note that 32 bits + * can *always* be represented with at most 10 decimal digits, + * including a possible rounding from the fractional part. */ - cp = cpend = &cbuf[10]; - lwork = fpi; - if (lwork & 0xffff0000) { - register u_long lten = 10; - register u_long ltmp; - - do { - ltmp = lwork; - lwork /= lten; - ltmp -= (lwork << 3) + (lwork << 1); - if (cp < cbuf) abort(); /* rather die a horrible death than trash the memory */ - *--cp = (u_char)ltmp; - } while (lwork & 0xffff0000); - } - if (lwork != 0) { - register u_short sten = 10; - register u_short stmp; - register u_short swork = (u_short)lwork; - - do { - stmp = swork; - swork = (u_short) (swork/sten); - stmp = (u_short)(stmp - ((swork<<3) + (swork<<1))); - if (cp < cbuf) abort(); /* rather die a horrible death than trash the memory */ - *--cp = (u_char)stmp; - } while (swork != 0); + cp = cpend = cpdec = &cbuf[10]; + for (dec = cp - cbuf; dec > 0 && fpi != 0; dec--) { + /* can add another digit */ + u_int32 digit; + + digit = fpi; + fpi /= 10U; + digit -= (fpi << 3) + (fpi << 1); /* i*10 */ + *--cp = (u_char)digit; } /* * Done that, now deal with the problem of the fraction. First * determine the number of decimal places. */ + dec = ndec; + if (dec < 0) + dec = 0; if (msec) { - dec = ndec + 3; - if (dec < 3) - dec = 3; - cpdec = &cbuf[13]; - } else { - dec = ndec; - if (dec < 0) - dec = 0; - cpdec = &cbuf[10]; + dec += 3; + cpdec += 3; } - if (dec > 12) - dec = 12; + if ((size_t)dec > sizeof(cbuf) - (cpend - cbuf)) + dec = sizeof(cbuf) - (cpend - cbuf); /* * If there's a fraction to deal with, do so. */ - if (fpv != 0) { - l_fp work; - - work.l_ui = 0; - work.l_uf = fpv; - while (dec > 0) { - l_fp ftmp; - - dec--; - /* - * The scheme here is to multiply the - * fraction (0.1234...) by ten. This moves - * a junk of BCD into the units part. - * record that and iterate. - */ - work.l_ui = 0; - L_LSHIFT(&work); - ftmp = work; - L_LSHIFT(&work); - L_LSHIFT(&work); - L_ADD(&work, &ftmp); - *cpend++ = (u_char)work.l_ui; - if (work.l_uf == 0) - break; - if (cpend > (cbuf + sizeof(cbuf))) abort(); /* rather die a horrible death than trash the memory */ - } - + for (/*NOP*/; dec > 0 && fpv != 0; dec--) { + u_int32 digit, tmph, tmpl; + /* - * Rounding is rotten + * The scheme here is to multiply the fraction + * (0.1234...) by ten. This moves a junk of BCD into + * the units part. record that and iterate. + * multiply by shift/add in two dwords. */ - if (work.l_uf & 0x80000000) { - register u_char *tp = cpend; + digit = 0; + M_LSHIFT(digit, fpv); + tmph = digit; + tmpl = fpv; + M_LSHIFT(digit, fpv); + M_LSHIFT(digit, fpv); + M_ADD(digit, fpv, tmph, tmpl); + *cpend++ = (u_char)digit; + } + + /* decide whether to round or simply extend by zeros */ + if (dec > 0) { + /* only '0' digits left -- just reposition end */ + cpend += dec; + } else { + /* some bits remain in 'fpv'; do round */ + u_char *tp = cpend; + int carry = ((fpv & 0x80000000) != 0); - *(--tp) += 1; - while (*tp >= 10) { + for (dec = tp - cbuf; carry && dec > 0; dec--) { + *--tp += 1; + if (*tp == 10) *tp = 0; - *(--tp) += 1; - }; - if (tp < cp) - cp = tp; + else + carry = FALSE; } - } - cpend += dec; + if (tp < cp) /* rounding from 999 to 1000 or similiar? */ + cp = tp; + } /* * We've now got the fraction in cbuf[], with cp pointing at @@ -148,21 +114,18 @@ dolfptoa( * Remove leading zeros, then format the number into the * buffer. */ - while (cp < cpdec) { - if (*cp != 0) - break; + while (cp < cpdec && *cp == 0) cp++; - } - if (cp == cpdec) - --cp; + if (cp >= cpdec) + cp = cpdec - 1; bp = buf; if (neg) - *bp++ = '-'; + *bp++ = '-'; while (cp < cpend) { if (cp == cpdec) - *bp++ = '.'; - *bp++ = (char)(*cp++ + '0'); /* ascii dependent? */ + *bp++ = '.'; + *bp++ = (char)(*cp++) + '0'; } *bp = '\0'; @@ -171,3 +134,41 @@ dolfptoa( */ return buf; } + + +char * +mfptoa( + u_int32 fpi, + u_int32 fpf, + short ndec + ) +{ + int isneg; + + isneg = M_ISNEG(fpi); + if (isneg) { + M_NEG(fpi, fpf); + } + + return dolfptoa(fpi, fpf, isneg, ndec, FALSE); +} + + +char * +mfptoms( + u_int32 fpi, + u_int32 fpf, + short ndec + ) +{ + int isneg; + + isneg = M_ISNEG(fpi); + if (isneg) { + M_NEG(fpi, fpf); + } + + return dolfptoa(fpi, fpf, isneg, ndec, TRUE); +} + + diff --git a/contrib/ntp/libntp/emalloc.c b/contrib/ntp/libntp/emalloc.c index 2fe4c3862..8b7ef990c 100644 --- a/contrib/ntp/libntp/emalloc.c +++ b/contrib/ntp/libntp/emalloc.c @@ -1,48 +1,149 @@ /* * emalloc - return new memory obtained from the system. Belch if none. */ +#include #include "ntp_types.h" #include "ntp_malloc.h" #include "ntp_syslog.h" #include "ntp_stdlib.h" -#if defined SYS_WINNT && defined DEBUG -#include -#endif -#if defined SYS_WINNT && defined DEBUG +/* + * When using the debug MS CRT allocator, each allocation stores the + * callsite __FILE__ and __LINE__, which is then displayed at process + * termination, to track down leaks. We don't want all of our + * allocations to show up as coming from emalloc.c, so we preserve the + * original callsite's source file and line using macros which pass + * __FILE__ and __LINE__ as parameters to these routines. + * Other debug malloc implementations can be used by defining + * EREALLOC_IMPL() as ports/winnt/include/config.h does. + */ void * -debug_emalloc( - u_int size, - char *filename, - int line +ereallocz( + void * ptr, + size_t newsz, + size_t priorsz, + int zero_init +#ifdef EREALLOC_CALLSITE /* ntp_malloc.h */ + , + const char * file, + int line +#endif ) { - char *mem; + char * mem; + size_t allocsz; + + if (0 == newsz) + allocsz = 1; + else + allocsz = newsz; - if ((mem = (char *)_malloc_dbg(size, _NORMAL_BLOCK, filename, line)) == 0) { - msyslog(LOG_ERR, "Exiting: No more memory!"); + mem = EREALLOC_IMPL(ptr, allocsz, file, line); + if (NULL == mem) { + msyslog_term = TRUE; +#ifndef EREALLOC_CALLSITE + msyslog(LOG_ERR, "fatal out of memory (%lu bytes)", + (u_long)newsz); +#else + msyslog(LOG_ERR, + "fatal out of memory %s line %d (%lu bytes)", + file, line, (u_long)newsz); +#endif exit(1); } + + if (zero_init && newsz > priorsz) + zero_mem(mem + priorsz, newsz - priorsz); + return mem; } -#else +/* oreallocarray.c is licensed under the following: + * Copyright (c) 2008 Otto Moerbeek + * + * Permission to use, copy, modify, and distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * This is sqrt(SIZE_MAX+1), as s1*s2 <= SIZE_MAX + * if both s1 < MUL_NO_OVERFLOW and s2 < MUL_NO_OVERFLOW + */ +#define MUL_NO_OVERFLOW ((size_t)1 << (sizeof(size_t) * 4)) void * -emalloc( - u_int size +oreallocarray( + void *optr, + size_t nmemb, + size_t size +#ifdef EREALLOC_CALLSITE /* ntp_malloc.h */ + , + const char * file, + int line +#endif ) { - char *mem; - - if ((mem = (char *)malloc(size)) == 0) { - msyslog(LOG_ERR, "Exiting: No more memory!"); + if ((nmemb >= MUL_NO_OVERFLOW || size >= MUL_NO_OVERFLOW) && + nmemb > 0 && SIZE_MAX / nmemb < size) { +#ifndef EREALLOC_CALLSITE + msyslog(LOG_ERR, "fatal allocation size overflow"); +#else + msyslog(LOG_ERR, + "fatal allocation size overflow %s line %d", + file, line); +#endif exit(1); } - return mem; +#ifndef EREALLOC_CALLSITE + return ereallocz(optr, (size * nmemb), 0, FALSE); +#else + return ereallocz(optr, (size * nmemb), 0, FALSE, file, line); +#endif } +char * +estrdup_impl( + const char * str +#ifdef EREALLOC_CALLSITE + , + const char * file, + int line +#endif + ) +{ + char * copy; + size_t bytes; + bytes = strlen(str) + 1; + copy = ereallocz(NULL, bytes, 0, FALSE +#ifdef EREALLOC_CALLSITE + , file, line #endif + ); + memcpy(copy, str, bytes); + + return copy; +} + + +#if 0 +#ifndef EREALLOC_CALLSITE +void * +emalloc(size_t newsz) +{ + return ereallocz(NULL, newsz, 0, FALSE); +} +#endif +#endif + diff --git a/contrib/ntp/libntp/findconfig.c b/contrib/ntp/libntp/findconfig.c index ecf6a4bc2..1785ff700 100644 --- a/contrib/ntp/libntp/findconfig.c +++ b/contrib/ntp/libntp/findconfig.c @@ -22,13 +22,13 @@ FindConfig( struct utsname unamebuf; /* All keyed by initial target being a directory */ - (void) strcpy(result, base); + strlcpy(result, base, sizeof(result)); if (stat(result, &sbuf) == 0) { if (S_ISDIR(sbuf.st_mode)) { /* First choice is my hostname */ if (gethostname(hostname, BUFSIZ) >= 0) { - (void) sprintf(result, "%s/%s", base, hostname); + snprintf(result, sizeof(result), "%s/%s", base, hostname); if (stat(result, &sbuf) == 0) { goto outahere; } else { @@ -39,17 +39,19 @@ FindConfig( cp = unamebuf.machine + 5; else cp = unamebuf.machine; - (void) sprintf(result, "%s/default.%s", base, cp); + snprintf(result, sizeof(result), "%s/default.%s", base, cp); if (stat(result, &sbuf) == 0) { goto outahere; } else { /* Last choice is just default */ - (void) sprintf(result, "%s/default", base); + snprintf(result, sizeof(result), "%s/default", base); if (stat(result, &sbuf) == 0) { goto outahere; } else { - (void) strcpy(result, "/not/found"); + strlcpy(result, + "/not/found", + sizeof(result)); } } } diff --git a/contrib/ntp/libntp/fptoa.c b/contrib/ntp/libntp/fptoa.c deleted file mode 100644 index 025ad21e5..000000000 --- a/contrib/ntp/libntp/fptoa.c +++ /dev/null @@ -1,25 +0,0 @@ -/* - * fptoa - return an asciized representation of an s_fp number - */ -#include "ntp_fp.h" -#include "ntp_stdlib.h" - -char * -fptoa( - s_fp fpv, - short ndec - ) -{ - u_fp plusfp; - int neg; - - if (fpv < 0) { - plusfp = (u_fp)(-fpv); - neg = 1; - } else { - plusfp = (u_fp)fpv; - neg = 0; - } - - return dofptoa(plusfp, neg, ndec, 0); -} diff --git a/contrib/ntp/libntp/fptoms.c b/contrib/ntp/libntp/fptoms.c deleted file mode 100644 index 0bfca5556..000000000 --- a/contrib/ntp/libntp/fptoms.c +++ /dev/null @@ -1,24 +0,0 @@ -/* - * fptoms - return an asciized s_fp number in milliseconds - */ -#include "ntp_fp.h" - -char * -fptoms( - s_fp fpv, - short ndec - ) -{ - u_fp plusfp; - int neg; - - if (fpv < 0) { - plusfp = (u_fp)(-fpv); - neg = 1; - } else { - plusfp = (u_fp)fpv; - neg = 0; - } - - return dofptoa(plusfp, neg, ndec, 1); -} diff --git a/contrib/ntp/libntp/getopt.c b/contrib/ntp/libntp/getopt.c index 7b344f0dc..63c82faa6 100644 --- a/contrib/ntp/libntp/getopt.c +++ b/contrib/ntp/libntp/getopt.c @@ -13,6 +13,7 @@ /*LINTLIBRARY*/ +#include #include #include "ntp_stdlib.h" diff --git a/contrib/ntp/libntp/hextoint.c b/contrib/ntp/libntp/hextoint.c index 0d774eb4e..980a43f9d 100644 --- a/contrib/ntp/libntp/hextoint.c +++ b/contrib/ntp/libntp/hextoint.c @@ -2,6 +2,7 @@ * hextoint - convert an ascii string in hex to an unsigned * long, with error checking */ +#include #include #include "ntp_stdlib.h" @@ -9,7 +10,7 @@ int hextoint( const char *str, - u_long *ival + u_long *pu ) { register u_long u; @@ -18,22 +19,24 @@ hextoint( cp = str; if (*cp == '\0') - return 0; + return 0; u = 0; while (*cp != '\0') { - if (!isxdigit((int)*cp)) - return 0; - if (u >= 0x10000000) - return 0; /* overflow */ + if (!isxdigit((unsigned char)*cp)) + return 0; + if (u & 0xF0000000) + return 0; /* overflow */ u <<= 4; - if (*cp <= '9') /* very ascii dependent */ - u += *cp++ - '0'; - else if (*cp >= 'a') - u += *cp++ - 'a' + 10; + if ('0' <= *cp && *cp <= '9') + u += *cp++ - '0'; + else if ('a' <= *cp && *cp <= 'f') + u += *cp++ - 'a' + 10; + else if ('A' <= *cp && *cp <= 'F') + u += *cp++ - 'A' + 10; else - u += *cp++ - 'A' + 10; + return 0; } - *ival = u; + *pu = u; return 1; } diff --git a/contrib/ntp/libntp/hextolfp.c b/contrib/ntp/libntp/hextolfp.c index d0b624340..2bff929dc 100644 --- a/contrib/ntp/libntp/hextolfp.c +++ b/contrib/ntp/libntp/hextolfp.c @@ -1,6 +1,7 @@ /* * hextolfp - convert an ascii hex string to an l_fp number */ +#include #include #include @@ -29,7 +30,7 @@ hextolfp( * * [spaces]8_hex_digits[.]8_hex_digits[spaces|\n|\0] */ - while (isspace((int)*cp)) + while (isspace((unsigned char)*cp)) cp++; cpstart = cp; @@ -58,7 +59,7 @@ hextolfp( if ((cp - cpstart) < 8 || ind == NULL) return 0; - if (*cp != '\0' && !isspace((int)*cp)) + if (*cp != '\0' && !isspace((unsigned char)*cp)) return 0; lfp->l_ui = dec_i; diff --git a/contrib/ntp/libntp/humandate.c b/contrib/ntp/libntp/humandate.c index 630c87133..d9d5e89df 100644 --- a/contrib/ntp/libntp/humandate.c +++ b/contrib/ntp/libntp/humandate.c @@ -1,62 +1,60 @@ /* - * humandate - convert an NTP (or the current) time to something readable + * humandate.c - convert an NTP (or the current) time to something readable */ +#include #include + #include "ntp_fp.h" #include "ntp_unixtime.h" /* includes and */ #include "lib_strbuf.h" #include "ntp_stdlib.h" -static const char *months[] = { - "Jan", "Feb", "Mar", "Apr", "May", "Jun", - "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" -}; -static const char *days[] = { - "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" -}; - -char * -humandate( - u_long ntptime - ) -{ - char *bp; - struct tm *tm; - tm = ntp2unix_tm(ntptime, 1); +/* This is used in msyslog.c; we don't want to clutter up the log with + the year and day of the week, etc.; just the minimal date and time. */ +const char * +humanlogtime(void) +{ + char * bp; + time_t cursec; + struct tm * tm; + + cursec = time(NULL); + tm = localtime(&cursec); if (!tm) - return "--- --- -- ---- --:--:--"; + return "-- --- --:--:--"; LIB_GETBUF(bp); - (void) sprintf(bp, "%s, %s %2d %4d %2d:%02d:%02d", - days[tm->tm_wday], months[tm->tm_mon], tm->tm_mday, - 1900+tm->tm_year, tm->tm_hour, tm->tm_min, tm->tm_sec); - + snprintf(bp, LIB_BUFLENGTH, "%2d %s %02d:%02d:%02d", + tm->tm_mday, months[tm->tm_mon], + tm->tm_hour, tm->tm_min, tm->tm_sec); + return bp; } -/* This is used in msyslog.c; we don't want to clutter up the log with - the year and day of the week, etc.; just the minimal date and time. */ - -char * -humanlogtime(void) +/* + * humantime() -- like humanlogtime() but without date, and with the + * time to display given as an argument. + */ +const char * +humantime( + time_t cursec + ) { - char *bp; - time_t cursec = time((time_t *) 0); - struct tm *tm; + char * bp; + struct tm * tm; tm = localtime(&cursec); if (!tm) - return "-- --- --:--:--"; + return "--:--:--"; LIB_GETBUF(bp); - (void) sprintf(bp, "%2d %s %02d:%02d:%02d", - tm->tm_mday, months[tm->tm_mon], - tm->tm_hour, tm->tm_min, tm->tm_sec); + snprintf(bp, LIB_BUFLENGTH, "%02d:%02d:%02d", + tm->tm_hour, tm->tm_min, tm->tm_sec); return bp; } diff --git a/contrib/ntp/libntp/icom.c b/contrib/ntp/libntp/icom.c index 280667eb4..2e95db5eb 100644 --- a/contrib/ntp/libntp/icom.c +++ b/contrib/ntp/libntp/icom.c @@ -5,67 +5,98 @@ * distribution. The only function provided is to load the radio * frequency. All other parameters must be manually set before use. */ -#include "icom.h" +#include +#include +#include +#include +#include + #include #include #include #include -#include "ntp_tty.h" -#include "l_stdlib.h" -/* - * Scraps - */ -#define BMAX 50 /* max command length */ -#define DICOM /dev/icom/ /* ICOM port link */ +#ifdef SYS_WINNT +#undef write /* ports/winnt/include/config.h: #define write _write */ +extern int async_write(int, const void *, unsigned int); +#define write(fd, data, octets) async_write(fd, data, octets) +#endif /* - * FSA definitions + * Packet routines + * + * These routines send a packet and receive the response. If an error + * (collision) occurs on transmit, the packet is resent. If an error + * occurs on receive (timeout), all input to the terminating FI is + * discarded and the packet is resent. If the maximum number of retries + * is not exceeded, the program returns the number of octets in the user + * buffer; otherwise, it returns zero. + * + * ICOM frame format + * + * Frames begin with a two-octet preamble PR-PR followyd by the + * transceiver address RE, controller address TX, control code CN, zero + * or more data octets DA (depending on command), and terminator FI. + * Since the bus is bidirectional, every octet output is echoed on + * input. Every valid frame sent is answered with a frame in the same + * format, but with the RE and TX fields interchanged. The CN field is + * set to NAK if an error has occurred. Otherwise, the data are returned + * in this and following DA octets. If no data are returned, the CN + * octet is set to ACK. + * + * +------+------+------+------+------+--//--+------+ + * | PR | PR | RE | TX | CN | DA | FI | + * +------+------+------+------+------+--//--+------+ */ -#define S_IDLE 0 /* idle */ -#define S_HDR 1 /* header */ -#define S_TX 2 /* address */ -#define S_DATA 3 /* data */ -#define S_ERROR 4 /* error */ - /* - * Local function prototypes + * Scraps */ -static void doublefreq P((double, u_char *, int)); -static int sndpkt P((int, int, u_char *, u_char *)); -static int sndoctet P((int, int)); -static int rcvoctet P((int)); +#define DICOM /dev/icom/ /* ICOM port link */ /* - * Local variables + * Local function prototypes */ -static int flags; /* trace flags */ -static int state; /* fsa state */ +static void doublefreq (double, u_char *, int); /* * icom_freq(fd, ident, freq) - load radio frequency + * + * returns: + * 0 (ok) + * -1 (error) + * 1 (short write to device) */ int -icom_freq( /* returns 0 (ok), EIO (error) */ +icom_freq( int fd, /* file descriptor */ int ident, /* ICOM radio identifier */ double freq /* frequency (MHz) */ ) { - u_char cmd[BMAX], rsp[BMAX]; + u_char cmd[] = {PAD, PR, PR, 0, TX, V_SFREQ, 0, 0, 0, 0, FI, + FI}; int temp; - cmd[0] = V_SFREQ; + int rc; + + cmd[3] = (char)ident; if (ident == IC735) temp = 4; else temp = 5; - doublefreq(freq * 1e6, &cmd[1], temp); - temp = sndpkt(fd, ident, cmd, rsp); - if (temp < 1 || rsp[0] != ACK) - return (EIO); - return (0); + doublefreq(freq * 1e6, &cmd[6], temp); + rc = write(fd, cmd, temp + 7); + if (rc == -1) { + msyslog(LOG_ERR, "icom_freq: write() failed: %m"); + return -1; + } else if (rc != temp + 7) { + msyslog(LOG_ERR, "icom_freq: only wrote %d of %d bytes.", + rc, temp+7); + return 1; + } + + return 0; } @@ -80,10 +111,10 @@ doublefreq( /* returns void */ ) { int i; - char s1[11]; + char s1[16]; char *y; - sprintf(s1, " %10.0f", freq); + snprintf(s1, sizeof(s1), " %10.0f", freq); y = s1 + 10; i = 0; while (*y != ' ') { @@ -91,40 +122,13 @@ doublefreq( /* returns void */ x[i] = x[i] | ((*y-- & 0x0f) << 4); i++; } - for (; i < len; i++) + for ( ; i < len; i++) x[i] = 0; x[i] = FI; } - -/* - * Packet routines - * - * These routines send a packet and receive the response. If an error - * (collision) occurs on transmit, the packet is resent. If an error - * occurs on receive (timeout), all input to the terminating FI is - * discarded and the packet is resent. If the maximum number of retries - * is not exceeded, the program returns the number of octets in the user - * buffer; otherwise, it returns zero. - * - * ICOM frame format - * - * Frames begin with a two-octet preamble PR-PR followyd by the - * transceiver address RE, controller address TX, control code CN, zero - * or more data octets DA (depending on command), and terminator FI. - * Since the bus is bidirectional, every octet output is echoed on - * input. Every valid frame sent is answered with a frame in the same - * format, but with the RE and TX fields interchanged. The CN field is - * set to NAK if an error has occurred. Otherwise, the data are returned - * in this and following DA octets. If no data are returned, the CN - * octet is set to ACK. - * - * +------+------+------+------+------+--//--+------+ - * | PR | PR | RE | TX | CN | DA | FI | - * +------+------+------+------+------+--//--+------+ - */ /* - * icom_open() - open and initialize serial interface + * icom_init() - open and initialize serial interface * * This routine opens the serial interface for raw transmission; that * is, character-at-a-time, no stripping, checking or monkeying with the @@ -133,193 +137,42 @@ doublefreq( /* returns void */ */ int icom_init( - char *device, /* device name/link */ + const char *device, /* device name/link */ int speed, /* line speed */ int trace /* trace flags */ ) { TTY ttyb; int fd; + int rc; + int saved_errno; - flags = trace; - fd = open(device, O_RDWR, 0777); + fd = tty_open(device, O_RDWR, 0777); if (fd < 0) - return (fd); - - tcgetattr(fd, &ttyb); + return -1; + + rc = tcgetattr(fd, &ttyb); + if (rc < 0) { + saved_errno = errno; + close(fd); + errno = saved_errno; + return -1; + } ttyb.c_iflag = 0; /* input modes */ ttyb.c_oflag = 0; /* output modes */ - ttyb.c_cflag = IBAUD|CS8|CREAD|CLOCAL; /* control modes */ + ttyb.c_cflag = IBAUD|CS8|CLOCAL; /* control modes (no read) */ ttyb.c_lflag = 0; /* local modes */ ttyb.c_cc[VMIN] = 0; /* min chars */ ttyb.c_cc[VTIME] = 5; /* receive timeout */ cfsetispeed(&ttyb, (u_int)speed); cfsetospeed(&ttyb, (u_int)speed); - tcsetattr(fd, TCSANOW, &ttyb); - return (fd); -} - - -/* - * sndpkt(r, x, y) - send packet and receive response - * - * This routine sends a command frame, which consists of all except the - * preamble octets PR-PR. It then listens for the response frame and - * returns the payload to the caller. The routine checks for correct - * response header format; that is, the length of the response vector - * returned to the caller must be at least 2 and the RE and TX octets - * must be interchanged; otherwise, the operation is retried up to - * the number of times specified in a global variable. - * - * The trace function, which is enabled by the P_TRACE bit of the global - * flags variable, prints all characters received or echoed on the bus - * preceded by a T (transmit) or R (receive). The P_ERMSG bit of the - * flags variable enables printing of bus error messages. - * - * Note that the first octet sent is a PAD in order to allow time for - * the radio to flush its receive buffer after sending the previous - * response. Even with this precaution, some of the older radios - * occasionally fail to receive a command and it has to be sent again. - */ -static int -sndpkt( /* returns octet count */ - int fd, /* file descriptor */ - int r, /* radio address */ - u_char *cmd, /* command vector */ - u_char *rsp /* response vector */ - ) -{ - int i, j, temp; - - (void)tcflush(fd, TCIOFLUSH); - for (i = 0; i < RETRY; i++) { - state = S_IDLE; - - /* - * Transmit packet. - */ - if (flags & P_TRACE) - printf("icom T:"); - sndoctet(fd, PAD); /* send header */ - sndoctet(fd, PR); - sndoctet(fd, PR); - sndoctet(fd, r); - sndoctet(fd, TX); - for (j = 0; j < BMAX; j++) { /* send body */ - if (sndoctet(fd, cmd[j]) == FI) - break; - } - while (rcvoctet(fd) != FI); /* purge echos */ - if (cmd[0] == V_FREQT || cmd[0] == V_MODET) - return (0); /* shortcut for broadcast */ - - /* - * Receive packet. First, delete all characters - * preceeding a PR, then discard all PRs. Check that the - * RE and TX fields are correctly interchanged, then - * copy the remaining data and FI to the user buffer. - */ - if (flags & P_TRACE) - printf("\nicom R:"); - j = 0; - while ((temp = rcvoctet(fd)) != FI) { - switch (state) { - - case S_IDLE: - if (temp != PR) - continue; - state = S_HDR; - break; - - case S_HDR: - if (temp == PR) { - continue; - } else if (temp != TX) { - if (flags & P_ERMSG) - printf( - "icom: TX error\n"); - state = S_ERROR; - } - state = S_TX; - break; - - case S_TX: - if (temp != r) { - if (flags & P_ERMSG) - printf( - "icom: RE error\n"); - state = S_ERROR; - } - state = S_DATA; - break; - - case S_DATA: - if (j >= BMAX ) { - if (flags & P_ERMSG) - printf( - "icom: buffer overrun\n"); - state = S_ERROR; - j = 0; - } - rsp[j++] = (u_char)temp; - break; - - case S_ERROR: - break; - } - } - if (flags & P_TRACE) - printf("\n"); - if (j > 0) { - rsp[j++] = FI; - return (j); - } + rc = tcsetattr(fd, TCSANOW, &ttyb); + if (rc < 0) { + saved_errno = errno; + close(fd); + errno = saved_errno; + return -1; } - if (flags & P_ERMSG) - printf("icom: retries exceeded\n"); - return (0); -} - - -/* - * Interface routines - * - * These routines read and write octets on the bus. In case of receive - * timeout a FI code is returned. In case of output collision (echo - * does not match octet sent), the remainder of the collision frame - * (including the trailing FI) is discarded. - */ -/* - * sndoctet(fd, x) - send octet - */ -static int -sndoctet( /* returns octet */ - int fd, /* file descriptor */ - int x /* octet */ - ) -{ - u_char y; - - y = (u_char)x; - write(fd, &y, 1); - return (x); -} - - -/* - * rcvoctet(fd) - receive octet - */ -static int -rcvoctet( /* returns octet */ - int fd /* file descriptor */ - ) -{ - u_char y; - - if (read(fd, &y, 1) < 1) - y = FI; /* come here if timeout */ - if (flags & P_TRACE && y != PAD) - printf(" %02x", y); - return (y); + return (fd); } /* end program */ diff --git a/contrib/ntp/libntp/inttoa.c b/contrib/ntp/libntp/inttoa.c deleted file mode 100644 index f27073339..000000000 --- a/contrib/ntp/libntp/inttoa.c +++ /dev/null @@ -1,20 +0,0 @@ -/* - * inttoa - return an asciized signed integer - */ -#include - -#include "lib_strbuf.h" -#include "ntp_stdlib.h" - -char * -inttoa( - long ival - ) -{ - register char *buf; - - LIB_GETBUF(buf); - - (void) sprintf(buf, "%ld", (long)ival); - return buf; -} diff --git a/contrib/ntp/libntp/iosignal.c b/contrib/ntp/libntp/iosignal.c index 19a6e96b7..8749a23b8 100644 --- a/contrib/ntp/libntp/iosignal.c +++ b/contrib/ntp/libntp/iosignal.c @@ -45,7 +45,14 @@ #include "iosignal.h" #if defined(HAVE_SIGNALED_IO) +static RETSIGTYPE sigio_handler (int); + +/* consistency safegurad to catch BLOCK/UNBLOCK oversights */ static int sigio_block_count = 0; + +/* main inputhandler to be called on SIGIO */ +static input_handler_t *input_handler_callback = NULL; + # if defined(HAVE_SIGACTION) /* * If sigaction() is used for signal handling and a signal is @@ -59,40 +66,11 @@ static int sigio_block_count = 0; */ static int sigio_handler_active = 0; # endif -extern void input_handler P((l_fp *)); /* * SIGPOLL and SIGIO ROUTINES. */ - /* - * Some systems (MOST) define SIGPOLL == SIGIO, others SIGIO == SIGPOLL, and - * a few have separate SIGIO and SIGPOLL signals. This code checks for the - * SIGIO == SIGPOLL case at compile time. - * Do not define USE_SIGPOLL or USE_SIGIO. - * these are interal only to iosignal.c! - */ -# if defined(USE_SIGPOLL) -# undef USE_SIGPOLL -# endif -# if defined(USE_SIGIO) -# undef USE_SIGIO -# endif - -# if defined(USE_TTY_SIGPOLL) || defined(USE_UDP_SIGPOLL) -# define USE_SIGPOLL -# endif - -# if !defined(USE_TTY_SIGPOLL) || !defined(USE_UDP_SIGPOLL) -# define USE_SIGIO -# endif - -# if defined(USE_SIGIO) && defined(USE_SIGPOLL) -# if SIGIO == SIGPOLL -# define USE_SIGIO -# undef USE_SIGPOLL -# endif /* SIGIO == SIGPOLL */ -# endif /* USE_SIGIO && USE_SIGIO */ /* @@ -128,7 +106,7 @@ init_clock_sig( pgrp = getpid(); if (ioctl(rio->fd, FIOSSAIOOWN, (char *)&pgrp) == -1) { - msyslog(LOG_ERR, "ioctl(FIOSSAIOOWN) fails for clock I/O: %m"); + msyslog(LOG_ERR, "ioctl(FIOSSAIOOWN) fails for clock I/O: %m - EXITING"); exit(1); /*NOTREACHED*/ } @@ -138,14 +116,14 @@ init_clock_sig( */ if (ioctl(rio->fd, FIOSNBIO, (char *)&on) == -1) { - msyslog(LOG_ERR, "ioctl(FIOSNBIO) fails for clock I/O: %m"); + msyslog(LOG_ERR, "ioctl(FIOSNBIO) fails for clock I/O: %m - EXITING"); exit(1); /*NOTREACHED*/ } if (ioctl(rio->fd, FIOSSAIOSTAT, (char *)&on) == -1) { - msyslog(LOG_ERR, "ioctl(FIOSSAIOSTAT) fails for clock I/O: %m"); + msyslog(LOG_ERR, "ioctl(FIOSSAIOSTAT) fails for clock I/O: %m - EXITING"); exit(1); /*NOTREACHED*/ } @@ -232,7 +210,7 @@ init_socket_sig( if (ioctl(fd, I_SETSIG, S_INPUT) < 0) { msyslog(LOG_ERR, - "init_socket_sig: ioctl(I_SETSIG, S_INPUT) failed: %m"); + "init_socket_sig: ioctl(I_SETSIG, S_INPUT) failed: %m - EXITING"); exit(1); } } @@ -246,7 +224,7 @@ init_socket_sig( # if defined(FIOASYNC) if (ioctl(fd, FIOASYNC, (char *)&on) == -1) { - msyslog(LOG_ERR, "ioctl(FIOASYNC) fails: %m"); + msyslog(LOG_ERR, "ioctl(FIOASYNC) fails: %m - EXITING"); exit(1); /*NOTREACHED*/ } @@ -256,13 +234,13 @@ init_socket_sig( if ((flags = fcntl(fd, F_GETFL, 0)) == -1) { - msyslog(LOG_ERR, "fcntl(F_GETFL) fails: %m"); + msyslog(LOG_ERR, "fcntl(F_GETFL) fails: %m - EXITING"); exit(1); /*NOTREACHED*/ } if (fcntl(fd, F_SETFL, flags|FASYNC) < 0) { - msyslog(LOG_ERR, "fcntl(...|FASYNC) fails: %m"); + msyslog(LOG_ERR, "fcntl(...|FASYNC) fails: %m - EXITING"); exit(1); /*NOTREACHED*/ } @@ -280,21 +258,21 @@ init_socket_sig( # if defined(SIOCSPGRP) if (ioctl(fd, SIOCSPGRP, (char *)&pgrp) == -1) { - msyslog(LOG_ERR, "ioctl(SIOCSPGRP) fails: %m"); + msyslog(LOG_ERR, "ioctl(SIOCSPGRP) fails: %m - EXITING"); exit(1); /*NOTREACHED*/ } # elif defined(FIOSETOWN) if (ioctl(fd, FIOSETOWN, (char*)&pgrp) == -1) { - msyslog(LOG_ERR, "ioctl(FIOSETOWN) fails: %m"); + msyslog(LOG_ERR, "ioctl(FIOSETOWN) fails: %m - EXITING"); exit(1); /*NOTREACHED*/ } # elif defined(F_SETOWN) if (fcntl(fd, F_SETOWN, pgrp) == -1) { - msyslog(LOG_ERR, "fcntl(F_SETOWN) fails: %m"); + msyslog(LOG_ERR, "fcntl(F_SETOWN) fails: %m - EXITING"); exit(1); /*NOTREACHED*/ } @@ -305,7 +283,7 @@ init_socket_sig( # endif /* USE_UDP_SIGPOLL */ } -RETSIGTYPE +static RETSIGTYPE sigio_handler( int sig ) @@ -321,7 +299,8 @@ sigio_handler( msyslog(LOG_ERR, "sigio_handler: sigio_handler_active != 1"); # endif - (void)input_handler(&ts); + INSIST(input_handler_callback != NULL); + (*input_handler_callback)(&ts); # if defined(HAVE_SIGACTION) sigio_handler_active--; @@ -337,8 +316,13 @@ sigio_handler( */ # ifdef HAVE_SIGACTION void -set_signal(void) +set_signal(input_handler_t *input) { + INSIST(input != NULL); + + input_handler_callback = input; + + using_sigio = TRUE; # ifdef USE_SIGIO (void) signal_no_reset(SIGIO, sigio_handler); # endif @@ -507,8 +491,13 @@ block_sigio(void) } void -set_signal(void) +set_signal(input_handler_t *input) { + INSIST(input != NULL); + + input_handler_callback = input; + + using_sigio = TRUE; (void) signal_no_reset(SIGIO, sigio_handler); } diff --git a/contrib/ntp/libntp/lib_strbuf.c b/contrib/ntp/libntp/lib_strbuf.c index 315070f3a..76f70163d 100644 --- a/contrib/ntp/libntp/lib_strbuf.c +++ b/contrib/ntp/libntp/lib_strbuf.c @@ -1,16 +1,28 @@ /* * lib_strbuf - library string storage */ +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include + +#include "ntp_fp.h" #include "ntp_stdlib.h" #include "lib_strbuf.h" + /* * Storage declarations */ -char lib_stringbuf[LIB_NUMBUFS][LIB_BUFLENGTH]; -int lib_nextbuf; -int lib_inited = 0; +int debug; +libbufstr lib_stringbuf[LIB_NUMBUF]; +int lib_nextbuf; +int ipv4_works; +int ipv6_works; +int lib_inited; + /* * initialization routine. Might be needed if the code is ROMized. @@ -18,6 +30,10 @@ int lib_inited = 0; void init_lib(void) { - lib_nextbuf = 0; - lib_inited = 1; + if (lib_inited) + return; + ipv4_works = (ISC_R_SUCCESS == isc_net_probeipv4()); + ipv6_works = (ISC_R_SUCCESS == isc_net_probeipv6()); + init_systime(); + lib_inited = TRUE; } diff --git a/contrib/ntp/libntp/lib_strbuf.h b/contrib/ntp/libntp/lib_strbuf.h deleted file mode 100644 index 5aa0eb0a6..000000000 --- a/contrib/ntp/libntp/lib_strbuf.h +++ /dev/null @@ -1,28 +0,0 @@ -/* - * lib_strbuf.h - definitions for routines which use the common string buffers - */ - -#include - -/* - * Sizes of things - */ -#define LIB_NUMBUFS 200 -#define LIB_BUFLENGTH 80 - -/* - * Macro to get a pointer to the next buffer - */ -#define LIB_GETBUF(buf) \ - do { \ - if (!lib_inited) \ - init_lib(); \ - buf = &lib_stringbuf[lib_nextbuf][0]; \ - if (++lib_nextbuf >= LIB_NUMBUFS) \ - lib_nextbuf = 0; \ - memset(buf, 0, LIB_BUFLENGTH); \ - } while (0) - -extern char lib_stringbuf[LIB_NUMBUFS][LIB_BUFLENGTH]; -extern int lib_nextbuf; -extern int lib_inited; diff --git a/contrib/ntp/libntp/machines.c b/contrib/ntp/libntp/machines.c index c8e4e07c9..7a29ac07e 100644 --- a/contrib/ntp/libntp/machines.c +++ b/contrib/ntp/libntp/machines.c @@ -8,10 +8,13 @@ #include "config.h" #endif +#include "ntp.h" #include "ntp_machine.h" #include "ntp_syslog.h" #include "ntp_stdlib.h" #include "ntp_unixtime.h" +#include "lib_strbuf.h" +#include "ntp_debug.h" #ifdef HAVE_UNISTD_H #include @@ -37,7 +40,7 @@ struct hostent *gethostbyname(char *name) { struct hostent *host1; h_errno = 0; /* we are always successful!!! */ - host1 = (struct hostent *) malloc (sizeof(struct hostent)); + host1 = (struct hostent *) emalloc (sizeof(struct hostent)); host1->h_name = name; host1->h_addrtype = AF_INET; host1->h_aliases = name; @@ -51,7 +54,7 @@ struct hostent *gethostbyaddr(char *name, int size, int addr_type) { struct hostent *host1; h_errno = 0; /* we are always successful!!! */ - host1 = (struct hostent *) malloc (sizeof(struct hostent)); + host1 = (struct hostent *) emalloc (sizeof(struct hostent)); host1->h_name = name; host1->h_addrtype = AF_INET; host1->h_aliases = name; @@ -63,7 +66,7 @@ struct hostent *gethostbyaddr(char *name, int size, int addr_type) struct servent *getservbyname (char *name, char *type) { struct servent *serv1; - serv1 = (struct servent *) malloc (sizeof(struct servent)); + serv1 = (struct servent *) emalloc (sizeof(struct servent)); serv1->s_name = "ntp"; /* official service name */ serv1->s_aliases = NULL; /* alias list */ serv1->s_port = 123; /* port # */ @@ -409,7 +412,20 @@ return 0; } #endif /* MPE */ -const char *set_tod_using = "UNKNOWN"; +#define SET_TOD_UNDETERMINED 0 +#define SET_TOD_CLOCK_SETTIME 1 +#define SET_TOD_SETTIMEOFDAY 2 +#define SET_TOD_STIME 3 + +const char * const set_tod_used[] = { + "undetermined", + "clock_settime", + "settimeofday", + "stime" +}; + +pset_tod_using set_tod_using = NULL; + int ntp_set_tod( @@ -417,37 +433,35 @@ ntp_set_tod( void *tzp ) { - int rc = -1; + static int tod; + int rc; + int saved_errno; -#ifdef DEBUG - if (debug) - printf("In ntp_set_tod\n"); -#endif + TRACE(1, ("In ntp_set_tod\n")); + rc = -1; + saved_errno = 0; #ifdef HAVE_CLOCK_SETTIME - if (rc) { + if (rc && (SET_TOD_CLOCK_SETTIME == tod || !tod)) { struct timespec ts; - set_tod_using = "clock_settime"; /* Convert timeval to timespec */ ts.tv_sec = tvp->tv_sec; ts.tv_nsec = 1000 * tvp->tv_usec; errno = 0; rc = clock_settime(CLOCK_REALTIME, &ts); -#ifdef DEBUG - if (debug) { - printf("ntp_set_tod: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); - } -#endif + saved_errno = errno; + TRACE(1, ("ntp_set_tod: clock_settime: %d %m\n", rc)); + if (!tod && !rc) + tod = SET_TOD_CLOCK_SETTIME; + } #endif /* HAVE_CLOCK_SETTIME */ #ifdef HAVE_SETTIMEOFDAY - if (rc) { + if (rc && (SET_TOD_SETTIMEOFDAY == tod || !tod)) { struct timeval adjtv; - set_tod_using = "settimeofday"; /* * Some broken systems don't reset adjtime() when the * clock is stepped. @@ -456,37 +470,39 @@ ntp_set_tod( adjtime(&adjtv, NULL); errno = 0; rc = SETTIMEOFDAY(tvp, tzp); -#ifdef DEBUG - if (debug) { - printf("ntp_set_tod: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); - } -#endif + saved_errno = errno; + TRACE(1, ("ntp_set_tod: settimeofday: %d %m\n", rc)); + if (!tod && !rc) + tod = SET_TOD_SETTIMEOFDAY; } #endif /* HAVE_SETTIMEOFDAY */ #ifdef HAVE_STIME - if (rc) { + if (rc && (SET_TOD_STIME == tod || !tod)) { long tp = tvp->tv_sec; - set_tod_using = "stime"; errno = 0; rc = stime(&tp); /* lie as bad as SysVR4 */ -#ifdef DEBUG - if (debug) { - printf("ntp_set_tod: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); - } -#endif + saved_errno = errno; + TRACE(1, ("ntp_set_tod: stime: %d %m\n", rc)); + if (!tod && !rc) + tod = SET_TOD_STIME; } #endif /* HAVE_STIME */ - if (rc) - set_tod_using = "Failed!"; -#ifdef DEBUG - if (debug) { - printf("ntp_set_tod: Final result: %s: %d: %s\n", - set_tod_using, rc, strerror(errno)); + + errno = saved_errno; /* for %m below */ + TRACE(1, ("ntp_set_tod: Final result: %s: %d %m\n", + set_tod_used[tod], rc)); + /* + * Say how we're setting the time of day + */ + if (!rc && NULL != set_tod_using) { + (*set_tod_using)(set_tod_used[tod]); + set_tod_using = NULL; } -#endif + + if (rc) + errno = saved_errno; + return rc; } @@ -509,19 +525,9 @@ getpass(const char * prompt) } password[i] = '\0'; + fputc('\n', stderr); + fflush(stderr); + return password; } #endif /* SYS_WINNT */ - -#if !defined(HAVE_MEMSET) -void -ntp_memset( - char *a, - int x, - int c - ) -{ - while (c-- > 0) - *a++ = (char) x; -} -#endif /*POSIX*/ diff --git a/contrib/ntp/libntp/md5c.c b/contrib/ntp/libntp/md5c.c deleted file mode 100644 index 07eec6c2f..000000000 --- a/contrib/ntp/libntp/md5c.c +++ /dev/null @@ -1,354 +0,0 @@ -/* MD5C.C - RSA Data Security, Inc., MD5 message-digest algorithm - */ - -/* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All - rights reserved. - - License to copy and use this software is granted provided that it - is identified as the "RSA Data Security, Inc. MD5 Message-Digest - Algorithm" in all material mentioning or referencing this software - or this function. - - License is also granted to make and use derivative works provided - that such works are identified as "derived from the RSA Data - Security, Inc. MD5 Message-Digest Algorithm" in all material - mentioning or referencing the derived work. - - RSA Data Security, Inc. makes no representations concerning either - the merchantability of this software or the suitability of this - software for any particular purpose. It is provided "as is" - without express or implied warranty of any kind. - - These notices must be retained in any copies of any part of this - documentation and/or software. - */ - -#include "global.h" -#ifndef HAVE_MD5INIT -#include "ntp_md5.h" - -/* Constants for MD5Transform routine. - */ -#define S11 7 -#define S12 12 -#define S13 17 -#define S14 22 -#define S21 5 -#define S22 9 -#define S23 14 -#define S24 20 -#define S31 4 -#define S32 11 -#define S33 16 -#define S34 23 -#define S41 6 -#define S42 10 -#define S43 15 -#define S44 21 - -static void MD5Transform PROTO_LIST ((UINT4 [4], unsigned char [64])); -static void Encode PROTO_LIST - ((unsigned char *, UINT4 *, unsigned int)); -static void Decode PROTO_LIST - ((UINT4 *, unsigned char *, unsigned int)); -static void MD5_memcpy PROTO_LIST ((POINTER, POINTER, unsigned int)); -static void MD5_memset PROTO_LIST ((POINTER, int, unsigned int)); - -static unsigned char PADDING[64] = { - 0x80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 -}; - -/* F, G, H and I are basic MD5 functions. - */ -#define F(x, y, z) (((x) & (y)) | ((~x) & (z))) -#define G(x, y, z) (((x) & (z)) | ((y) & (~z))) -#define H(x, y, z) ((x) ^ (y) ^ (z)) -#define I(x, y, z) ((y) ^ ((x) | (~z))) - -/* ROTATE_LEFT rotates x left n bits. - */ -#define ROTATE_LEFT(x, n) (((x) << (n)) | ((x) >> (32-(n)))) - -/* FF, GG, HH, and II transformations for rounds 1, 2, 3, and 4. - Rotation is separate from addition to prevent recomputation. - */ -#define FF(a, b, c, d, x, s, ac) { \ - (a) += F ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } -#define GG(a, b, c, d, x, s, ac) { \ - (a) += G ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } -#define HH(a, b, c, d, x, s, ac) { \ - (a) += H ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } -#define II(a, b, c, d, x, s, ac) { \ - (a) += I ((b), (c), (d)) + (x) + (UINT4)(ac); \ - (a) = ROTATE_LEFT ((a), (s)); \ - (a) += (b); \ - } - -/* MD5 initialization. Begins an MD5 operation, writing a new context. - */ -void -MD5Init( - MD5_CTX *context /* context */ - ) -{ - context->count[0] = context->count[1] = 0; - - /* Load magic initialization constants. - */ - context->state[0] = 0x67452301; - context->state[1] = 0xefcdab89; - context->state[2] = 0x98badcfe; - context->state[3] = 0x10325476; -} - -/* MD5 block update operation. Continues an MD5 message-digest - operation, processing another message block, and updating the - context. - */ -void -MD5Update ( - MD5_CTX *context, /* context */ - unsigned char *input, /* input block */ - unsigned int inputLen /* length of input block */ - ) -{ - unsigned int i, idx, partLen; - - /* Compute number of bytes mod 64 */ - idx = (unsigned int)((context->count[0] >> 3) & 0x3F); - - /* Update number of bits */ - if ((context->count[0] += ((UINT4)inputLen << 3)) - < ((UINT4)inputLen << 3)) - context->count[1]++; - context->count[1] += ((UINT4)inputLen >> 29); - - partLen = 64 - idx; - - /* Transform as many times as possible. - */ - if (inputLen >= partLen) { - MD5_memcpy - ((POINTER)&context->buffer[idx], (POINTER)input, partLen); - MD5Transform (context->state, context->buffer); - - for (i = partLen; i + 63 < inputLen; i += 64) - MD5Transform (context->state, &input[i]); - - idx = 0; - } - else - i = 0; - - /* Buffer remaining input */ - MD5_memcpy - ((POINTER)&context->buffer[idx], (POINTER)&input[i], - inputLen-i); -} - -/* MD5 finalization. Ends an MD5 message-digest operation, writing the - the message digest and zeroizing the context. - */ -void -MD5Final ( - unsigned char digest[16], /* message digest */ - MD5_CTX *context /* context */ - ) -{ - unsigned char bits[8]; - unsigned int idx, padLen; - - /* Save number of bits */ - Encode (bits, context->count, 8); - - /* Pad out to 56 mod 64. - */ - idx = (unsigned int)((context->count[0] >> 3) & 0x3f); - padLen = (idx < 56) ? (56 - idx) : (120 - idx); - MD5Update (context, PADDING, padLen); - - /* Append length (before padding) */ - MD5Update (context, bits, 8); - - /* Store state in digest */ - Encode (digest, context->state, 16); - - /* Zeroize sensitive information. - */ - MD5_memset ((POINTER)context, 0, sizeof (*context)); -} - -/* MD5 basic transformation. Transforms state based on block. - */ -static void -MD5Transform ( - UINT4 state[4], - unsigned char block[64] - ) -{ - UINT4 a = state[0], b = state[1], c = state[2], d = state[3], x[16]; - - Decode (x, block, 64); - - /* Round 1 */ - FF (a, b, c, d, x[ 0], S11, 0xd76aa478); /* 1 */ - FF (d, a, b, c, x[ 1], S12, 0xe8c7b756); /* 2 */ - FF (c, d, a, b, x[ 2], S13, 0x242070db); /* 3 */ - FF (b, c, d, a, x[ 3], S14, 0xc1bdceee); /* 4 */ - FF (a, b, c, d, x[ 4], S11, 0xf57c0faf); /* 5 */ - FF (d, a, b, c, x[ 5], S12, 0x4787c62a); /* 6 */ - FF (c, d, a, b, x[ 6], S13, 0xa8304613); /* 7 */ - FF (b, c, d, a, x[ 7], S14, 0xfd469501); /* 8 */ - FF (a, b, c, d, x[ 8], S11, 0x698098d8); /* 9 */ - FF (d, a, b, c, x[ 9], S12, 0x8b44f7af); /* 10 */ - FF (c, d, a, b, x[10], S13, 0xffff5bb1); /* 11 */ - FF (b, c, d, a, x[11], S14, 0x895cd7be); /* 12 */ - FF (a, b, c, d, x[12], S11, 0x6b901122); /* 13 */ - FF (d, a, b, c, x[13], S12, 0xfd987193); /* 14 */ - FF (c, d, a, b, x[14], S13, 0xa679438e); /* 15 */ - FF (b, c, d, a, x[15], S14, 0x49b40821); /* 16 */ - - /* Round 2 */ - GG (a, b, c, d, x[ 1], S21, 0xf61e2562); /* 17 */ - GG (d, a, b, c, x[ 6], S22, 0xc040b340); /* 18 */ - GG (c, d, a, b, x[11], S23, 0x265e5a51); /* 19 */ - GG (b, c, d, a, x[ 0], S24, 0xe9b6c7aa); /* 20 */ - GG (a, b, c, d, x[ 5], S21, 0xd62f105d); /* 21 */ - GG (d, a, b, c, x[10], S22, 0x2441453); /* 22 */ - GG (c, d, a, b, x[15], S23, 0xd8a1e681); /* 23 */ - GG (b, c, d, a, x[ 4], S24, 0xe7d3fbc8); /* 24 */ - GG (a, b, c, d, x[ 9], S21, 0x21e1cde6); /* 25 */ - GG (d, a, b, c, x[14], S22, 0xc33707d6); /* 26 */ - GG (c, d, a, b, x[ 3], S23, 0xf4d50d87); /* 27 */ - GG (b, c, d, a, x[ 8], S24, 0x455a14ed); /* 28 */ - GG (a, b, c, d, x[13], S21, 0xa9e3e905); /* 29 */ - GG (d, a, b, c, x[ 2], S22, 0xfcefa3f8); /* 30 */ - GG (c, d, a, b, x[ 7], S23, 0x676f02d9); /* 31 */ - GG (b, c, d, a, x[12], S24, 0x8d2a4c8a); /* 32 */ - - /* Round 3 */ - HH (a, b, c, d, x[ 5], S31, 0xfffa3942); /* 33 */ - HH (d, a, b, c, x[ 8], S32, 0x8771f681); /* 34 */ - HH (c, d, a, b, x[11], S33, 0x6d9d6122); /* 35 */ - HH (b, c, d, a, x[14], S34, 0xfde5380c); /* 36 */ - HH (a, b, c, d, x[ 1], S31, 0xa4beea44); /* 37 */ - HH (d, a, b, c, x[ 4], S32, 0x4bdecfa9); /* 38 */ - HH (c, d, a, b, x[ 7], S33, 0xf6bb4b60); /* 39 */ - HH (b, c, d, a, x[10], S34, 0xbebfbc70); /* 40 */ - HH (a, b, c, d, x[13], S31, 0x289b7ec6); /* 41 */ - HH (d, a, b, c, x[ 0], S32, 0xeaa127fa); /* 42 */ - HH (c, d, a, b, x[ 3], S33, 0xd4ef3085); /* 43 */ - HH (b, c, d, a, x[ 6], S34, 0x4881d05); /* 44 */ - HH (a, b, c, d, x[ 9], S31, 0xd9d4d039); /* 45 */ - HH (d, a, b, c, x[12], S32, 0xe6db99e5); /* 46 */ - HH (c, d, a, b, x[15], S33, 0x1fa27cf8); /* 47 */ - HH (b, c, d, a, x[ 2], S34, 0xc4ac5665); /* 48 */ - - /* Round 4 */ - II (a, b, c, d, x[ 0], S41, 0xf4292244); /* 49 */ - II (d, a, b, c, x[ 7], S42, 0x432aff97); /* 50 */ - II (c, d, a, b, x[14], S43, 0xab9423a7); /* 51 */ - II (b, c, d, a, x[ 5], S44, 0xfc93a039); /* 52 */ - II (a, b, c, d, x[12], S41, 0x655b59c3); /* 53 */ - II (d, a, b, c, x[ 3], S42, 0x8f0ccc92); /* 54 */ - II (c, d, a, b, x[10], S43, 0xffeff47d); /* 55 */ - II (b, c, d, a, x[ 1], S44, 0x85845dd1); /* 56 */ - II (a, b, c, d, x[ 8], S41, 0x6fa87e4f); /* 57 */ - II (d, a, b, c, x[15], S42, 0xfe2ce6e0); /* 58 */ - II (c, d, a, b, x[ 6], S43, 0xa3014314); /* 59 */ - II (b, c, d, a, x[13], S44, 0x4e0811a1); /* 60 */ - II (a, b, c, d, x[ 4], S41, 0xf7537e82); /* 61 */ - II (d, a, b, c, x[11], S42, 0xbd3af235); /* 62 */ - II (c, d, a, b, x[ 2], S43, 0x2ad7d2bb); /* 63 */ - II (b, c, d, a, x[ 9], S44, 0xeb86d391); /* 64 */ - - state[0] += a; - state[1] += b; - state[2] += c; - state[3] += d; - - /* Zeroize sensitive information. - */ - MD5_memset ((POINTER)x, 0, sizeof (x)); -} - -/* Encodes input (UINT4) into output (unsigned char). Assumes len is - a multiple of 4. - */ -static void -Encode ( - unsigned char *output, - UINT4 *input, - unsigned int len - ) -{ - unsigned int i, j; - - for (i = 0, j = 0; j < len; i++, j += 4) { - output[j] = (unsigned char)(input[i] & 0xff); - output[j+1] = (unsigned char)((input[i] >> 8) & 0xff); - output[j+2] = (unsigned char)((input[i] >> 16) & 0xff); - output[j+3] = (unsigned char)((input[i] >> 24) & 0xff); - } -} - -/* Decodes input (unsigned char) into output (UINT4). Assumes len is - a multiple of 4. - */ -static void -Decode ( - UINT4 *output, - unsigned char *input, - unsigned int len - ) -{ - unsigned int i, j; - - for (i = 0, j = 0; j < len; i++, j += 4) - output[i] = ((UINT4)input[j]) | (((UINT4)input[j+1]) << 8) | - (((UINT4)input[j+2]) << 16) | (((UINT4)input[j+3]) << 24); -} - -/* Note: Replace "for loop" with standard memcpy if possible. - */ -static void -MD5_memcpy ( - POINTER output, - POINTER input, - unsigned int len - ) -{ - unsigned int i; - - for (i = 0; i < len; i++) - output[i] = input[i]; -} - -/* Note: Replace "for loop" with standard memset if possible. - */ -static void -MD5_memset ( - POINTER output, - int value, - unsigned int len - ) -{ - unsigned int i; - - for (i = 0; i < len; i++) - ((char *)output)[i] = (char)value; -} -#else -int md5_bs; -#endif diff --git a/contrib/ntp/libntp/memmove.c b/contrib/ntp/libntp/memmove.c deleted file mode 100644 index 8ccc4b1bb..000000000 --- a/contrib/ntp/libntp/memmove.c +++ /dev/null @@ -1,140 +0,0 @@ -/*- - * Copyright (c) 1990, 1993 - * The Regents of the University of California. All rights reserved. - * - * This code is derived from software contributed to Berkeley by - * Chris Torek. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. - * 4. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)bcopy.c 8.1 (Berkeley) 6/4/93"; -#endif /* LIBC_SCCS and not lint */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#ifndef HAVE_MEMMOVE -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#include - -#include "l_stdlib.h" - -/* - * sizeof(word) MUST BE A POWER OF TWO - * SO THAT wmask BELOW IS ALL ONES - */ -typedef int word; /* "word" used for optimal copy speed */ - -#define wsize sizeof(word) -#define wmask (wsize - 1) - -/* - * Copy a block of memory, handling overlap. - * This is the routine that actually implements - * (the portable versions of) bcopy, memcpy, and memmove. - */ -void * -memmove( - void *dst0, - const void *src0, - register size_t length - ) -{ - register char *dst = dst0; - register const char *src = src0; - register size_t t; - - if (length == 0 || dst == src) /* nothing to do */ - goto done; - - /* - * Macros: loop-t-times; and loop-t-times, t>0 - */ -#define TLOOP(s) if (t) TLOOP1(s) -#define TLOOP1(s) do { s; } while (--t) - - if ((unsigned long)dst < (unsigned long)src) { - /* - * Copy forward. - */ - t = (int)src; /* only need low bits */ - if ((t | (int)dst) & wmask) { - /* - * Try to align operands. This cannot be done - * unless the low bits match. - */ - if ((t ^ (int)dst) & wmask || length < wsize) - t = length; - else - t = wsize - (t & wmask); - length -= t; - TLOOP1(*dst++ = *src++); - } - /* - * Copy whole words, then mop up any trailing bytes. - */ - t = length / wsize; - TLOOP(*(word *)dst = *(const word *)src; src += wsize; - dst += wsize); - t = length & wmask; - TLOOP(*dst++ = *src++); - } else { - /* - * Copy backwards. Otherwise essentially the same. - * Alignment works as before, except that it takes - * (t&wmask) bytes to align, not wsize-(t&wmask). - */ - src += length; - dst += length; - t = (int)src; - if ((t | (int)dst) & wmask) { - if ((t ^ (int)dst) & wmask || length <= wsize) - t = length; - else - t &= wmask; - length -= t; - TLOOP1(*--dst = *--src); - } - t = length / wsize; - TLOOP(src -= wsize; dst -= wsize; - *(word *)dst = *(const word *)src); - t = length & wmask; - TLOOP(*--dst = *--src); - } - done: - return (dst0); -} -#else -int memmove_bs; -#endif diff --git a/contrib/ntp/libntp/mfptoa.c b/contrib/ntp/libntp/mfptoa.c deleted file mode 100644 index 6450b2c13..000000000 --- a/contrib/ntp/libntp/mfptoa.c +++ /dev/null @@ -1,23 +0,0 @@ -/* - * mfptoa - Return an asciized representation of a signed long fp number - */ -#include "ntp_fp.h" -#include "ntp_stdlib.h" - -char * -mfptoa( - u_long fpi, - u_long fpf, - short ndec - ) -{ - int isneg; - - if (M_ISNEG(fpi, fpf)) { - isneg = 1; - M_NEG(fpi, fpf); - } else - isneg = 0; - - return dolfptoa(fpi, fpf, isneg, ndec, 0); -} diff --git a/contrib/ntp/libntp/mfptoms.c b/contrib/ntp/libntp/mfptoms.c deleted file mode 100644 index d2bfd71ee..000000000 --- a/contrib/ntp/libntp/mfptoms.c +++ /dev/null @@ -1,23 +0,0 @@ -/* - * mfptoms - Return an asciized signed long fp number in milliseconds - */ -#include "ntp_fp.h" -#include "ntp_stdlib.h" - -char * -mfptoms( - u_long fpi, - u_long fpf, - short ndec - ) -{ - int isneg; - - if (M_ISNEG(fpi, fpf)) { - isneg = 1; - M_NEG(fpi, fpf); - } else - isneg = 0; - - return dolfptoa(fpi, fpf, isneg, ndec, 1); -} diff --git a/contrib/ntp/libntp/mktime.c b/contrib/ntp/libntp/mktime.c index 91be60015..50d2a0810 100644 --- a/contrib/ntp/libntp/mktime.c +++ b/contrib/ntp/libntp/mktime.c @@ -59,9 +59,14 @@ * by hand. Sorry about that. */ +#include #include "ntp_machine.h" -#if !defined(HAVE_MKTIME) || !defined(HAVE_TIMEGM) +#if !defined(HAVE_MKTIME) || ( !defined(HAVE_TIMEGM) && defined(WANT_TIMEGM) ) + +#if SIZEOF_TIME_T >= 8 +#error libntp supplied mktime()/timegm() do not support 64-bit time_t +#endif #ifndef DSTMINUTES #define DSTMINUTES 60 @@ -226,9 +231,9 @@ time2( t = (t < 0) ? 0 : ((time_t) 1 << bits); for ( ; ; ) { if (usezn) - mytm = *localtime(&t); + mytm = *localtime(&t); else - mytm = *gmtime(&t); + mytm = *gmtime(&t); dir = tmcomp(&mytm, &yourtm); if (dir != 0) { if (bits-- < 0) @@ -284,6 +289,7 @@ mktime( } #endif /* !HAVE_MKTIME */ +#ifdef WANT_TIMEGM #ifndef HAVE_TIMEGM time_t timegm( @@ -301,3 +307,4 @@ timegm( return WRONG; } #endif /* !HAVE_TIMEGM */ +#endif /* WANT_TIMEGM */ diff --git a/contrib/ntp/libntp/modetoa.c b/contrib/ntp/libntp/modetoa.c index 405aef855..6f13d2058 100644 --- a/contrib/ntp/libntp/modetoa.c +++ b/contrib/ntp/libntp/modetoa.c @@ -1,6 +1,7 @@ /* * modetoa - return an asciized mode */ +#include #include #include "lib_strbuf.h" @@ -8,11 +9,11 @@ const char * modetoa( - int mode + size_t mode ) { char *bp; - static const char *modestrings[] = { + static const char * const modestrings[] = { "unspec", "sym_active", "sym_passive", @@ -24,9 +25,9 @@ modetoa( "bclient", }; - if (mode < 0 || mode >= (sizeof modestrings)/sizeof(char *)) { + if (mode >= COUNTOF(modestrings)) { LIB_GETBUF(bp); - (void)sprintf(bp, "mode#%d", mode); + snprintf(bp, LIB_BUFLENGTH, "mode#%zu", mode); return bp; } diff --git a/contrib/ntp/libntp/mstolfp.c b/contrib/ntp/libntp/mstolfp.c index e4e909df7..828b14cfb 100644 --- a/contrib/ntp/libntp/mstolfp.c +++ b/contrib/ntp/libntp/mstolfp.c @@ -1,6 +1,7 @@ /* * mstolfp - convert an ascii string in milliseconds to an l_fp number */ +#include #include #include @@ -31,7 +32,7 @@ mstolfp( */ bp = buf; cp = str; - while (isspace((int)*cp)) + while (isspace((unsigned char)*cp)) cp++; if (*cp == '-') { @@ -39,7 +40,7 @@ mstolfp( cp++; } - if (*cp != '.' && !isdigit((int)*cp)) + if (*cp != '.' && !isdigit((unsigned char)*cp)) return 0; @@ -47,7 +48,7 @@ mstolfp( * Search forward for the decimal point or the end of the string. */ cpdec = cp; - while (isdigit((int)*cpdec)) + while (isdigit((unsigned char)*cpdec)) cpdec++; /* @@ -85,7 +86,7 @@ mstolfp( if (*cp == '.') { cp++; - while (isdigit((int)*cp)) + while (isdigit((unsigned char)*cp)) *bp++ = (char)*cp++; } *bp = '\0'; @@ -94,7 +95,7 @@ mstolfp( * Check to make sure the string is properly terminated. If * so, give the buffer to the decoding routine. */ - if (*cp != '\0' && !isspace((int)*cp)) + if (*cp != '\0' && !isspace((unsigned char)*cp)) return 0; return atolfp(buf, lfp); } diff --git a/contrib/ntp/libntp/msutotsf.c b/contrib/ntp/libntp/msutotsf.c deleted file mode 100644 index eb3babe9c..000000000 --- a/contrib/ntp/libntp/msutotsf.c +++ /dev/null @@ -1,35 +0,0 @@ -/* - * msutotsf - tables for converting from a subsecond millisecond value - * to a time stamp fraction. - */ -#include - -#include "ntp_types.h" - -/* - * Index each of these tables with five bits of the (less than) 10 - * bit millisecond value. Note that the tables are rounded (not - * truncated). The error in the result will thus be +-1 low order - * bit in the time stamp fraction. - */ -u_long msutotsflo[32] = { - 0x00000000, 0x00418937, 0x0083126f, 0x00c49ba6, - 0x010624dd, 0x0147ae14, 0x0189374c, 0x01cac083, - 0x020c49ba, 0x024dd2f2, 0x028f5c29, 0x02d0e560, - 0x03126e98, 0x0353f7cf, 0x03958106, 0x03d70a3d, - 0x04189375, 0x045a1cac, 0x049ba5e3, 0x04dd2f1b, - 0x051eb852, 0x05604189, 0x05a1cac1, 0x05e353f8, - 0x0624dd2f, 0x06666666, 0x06a7ef9e, 0x06e978d5, - 0x072b020c, 0x076c8b44, 0x07ae147b, 0x07ef9db2 -}; - -u_long msutotsfhi[32] = { - 0x00000000, 0x083126e9, 0x10624dd3, 0x189374bc, - 0x20c49ba6, 0x28f5c28f, 0x3126e979, 0x39581062, - 0x4189374c, 0x49ba5e35, 0x51eb851f, 0x5a1cac08, - 0x624dd2f2, 0x6a7ef9db, 0x72b020c5, 0x7ae147ae, - 0x83126e98, 0x8b439581, 0x9374bc6a, 0x9ba5e354, - 0xa3d70a3d, 0xac083127, 0xb4395810, 0xbc6a7efa, - 0xc49ba5e3, 0xcccccccd, 0xd4fdf3b6, 0xdd2f1aa0, - 0xe5604189, 0xed916873, 0xf5c28f5c, 0xfdf3b646 -}; diff --git a/contrib/ntp/libntp/msyslog.c b/contrib/ntp/libntp/msyslog.c index fe4d979e1..cc8868f8e 100644 --- a/contrib/ntp/libntp/msyslog.c +++ b/contrib/ntp/libntp/msyslog.c @@ -9,198 +9,576 @@ # include #endif -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include #ifdef HAVE_UNISTD_H # include #endif - #include -#include "ntp_types.h" #include "ntp_string.h" +#include "ntp.h" +#include "ntp_debug.h" #include "ntp_syslog.h" -#include "ntp_stdlib.h" #ifdef SYS_WINNT # include # include "..\ports\winnt\libntp\messages.h" #endif -int syslogit = 1; -FILE *syslog_file = NULL; +int syslogit = TRUE; +int msyslog_term = FALSE; /* duplicate to stdout/err */ +int msyslog_term_pid = TRUE; +int msyslog_include_timestamp = TRUE; +FILE * syslog_file; +char * syslog_fname; +char * syslog_abs_fname; -u_long ntp_syslogmask = ~ (u_long) 0; +/* libntp default ntp_syslogmask is all bits lit */ +#define INIT_NTP_SYSLOGMASK ~(u_int32)0 +u_int32 ntp_syslogmask = INIT_NTP_SYSLOGMASK; -#ifdef SYS_WINNT -static char separator = '\\'; -#else -static char separator = '/'; -#endif /* SYS_WINNT */ -extern char *progname; +extern char const * progname; /* Declare the local functions */ -void addto_syslog P((int, char *)); -void format_errmsg P((char *, int, const char *, int)); - - -/* - * This routine adds the contents of a buffer to the log - */ -void -addto_syslog(int level, char * buf) -{ - char *prog; - FILE *out_file = syslog_file; +void addto_syslog (int, const char *); +#ifndef VSNPRINTF_PERCENT_M +void format_errmsg (char *, size_t, const char *, int); -#if !defined(VMS) && !defined (SYS_VXWORKS) - if (syslogit) - syslog(level, "%s", buf); - else -#endif /* VMS && SYS_VXWORKS*/ - { - out_file = syslog_file ? syslog_file: level <= LOG_ERR ? stderr : stdout; - /* syslog() provides the timestamp, so if we're not using - syslog, we must provide it. */ - prog = strrchr(progname, separator); - if (prog == NULL) - prog = progname; - else - prog++; - (void) fprintf(out_file, "%s ", humanlogtime ()); - (void) fprintf(out_file, "%s[%d]: %s", prog, (int)getpid(), buf); - fflush (out_file); - } -#if DEBUG - if (debug && out_file != stdout && out_file != stderr) - printf("addto_syslog: %s\n", buf); -#endif -} +/* format_errmsg() is under #ifndef VSNPRINTF_PERCENT_M above */ void -format_errmsg(char *nfmt, int lennfmt, const char *fmt, int errval) +format_errmsg( + char * nfmt, + size_t lennfmt, + const char * fmt, + int errval + ) { - register char c; - register char *n; - register const char *f; - - char *err; + char errmsg[256]; + char c; + char *n; + const char *f; + size_t len; n = nfmt; f = fmt; - while ((c = *f++) != '\0' && n < (nfmt+lennfmt - 2)) { + while ((c = *f++) != '\0' && n < (nfmt + lennfmt - 1)) { if (c != '%') { *n++ = c; continue; } if ((c = *f++) != 'm') { *n++ = '%'; + if ('\0' == c) + break; *n++ = c; continue; } - err = 0; - err = strerror(errval); + errno_to_str(errval, errmsg, sizeof(errmsg)); + len = strlen(errmsg); + /* Make sure we have enough space for the error message */ - if ((n + strlen(err)) < (nfmt + lennfmt -2)) { - strcpy(n, err); - n += strlen(err); + if ((n + len) < (nfmt + lennfmt - 1)) { + memcpy(n, errmsg, len); + n += len; } } -#if !defined(VMS) - if (!syslogit) -#endif /* VMS */ - *n++ = '\n'; *n = '\0'; } +#endif /* VSNPRINTF_PERCENT_M */ + /* - * The externally called functions are defined here - * but share the internal function above to fetch - * any error message strings, This is done so that we can - * have two different functions to perform the logging - * since Windows gets it's error information from different - * places depending on whether or not it's network I/O. - * msyslog() is for general use while netsyslog() is for - * network I/O functions. They are virtually identical - * in implementation. + * errno_to_str() - a thread-safe strerror() replacement. + * Hides the varied signatures of strerror_r(). + * For Windows, we have: + * #define errno_to_str isc_strerror */ +#ifndef errno_to_str +void +errno_to_str( + int err, + char * buf, + size_t bufsiz + ) +{ +# if defined(STRERROR_R_CHAR_P) || !HAVE_DECL_STRERROR_R + char * pstatic; + + buf[0] = '\0'; +# ifdef STRERROR_R_CHAR_P + pstatic = strerror_r(err, buf, bufsiz); +# else + pstatic = strerror(err); +# endif + if (NULL == pstatic && '\0' == buf[0]) + snprintf(buf, bufsiz, "%s(%d): errno %d", +# ifdef STRERROR_R_CHAR_P + "strerror_r", +# else + "strerror", +# endif + err, errno); + /* protect against believing an int return is a pointer */ + else if (pstatic != buf && pstatic > (char *)bufsiz) + strlcpy(buf, pstatic, bufsiz); +# else + int rc; + + rc = strerror_r(err, buf, bufsiz); + if (rc < 0) + snprintf(buf, bufsiz, "strerror_r(%d): errno %d", + err, errno); +# endif +} +#endif /* errno_to_str */ + + +/* + * addto_syslog() + * This routine adds the contents of a buffer to the syslog or an + * application-specific logfile. + */ +void +addto_syslog( + int level, + const char * msg + ) +{ + static char const * prevcall_progname; + static char const * prog; + const char nl[] = "\n"; + const char empty[] = ""; + FILE * term_file; + int log_to_term; + int log_to_file; + int pid; + const char * nl_or_empty; + const char * human_time; + + /* setup program basename static var prog if needed */ + if (progname != prevcall_progname) { + prevcall_progname = progname; + prog = strrchr(progname, DIR_SEP); + if (prog != NULL) + prog++; + else + prog = progname; + } + + log_to_term = msyslog_term; + log_to_file = FALSE; +#if !defined(VMS) && !defined(SYS_VXWORKS) + if (syslogit) + syslog(level, "%s", msg); + else +#endif + if (syslog_file != NULL) + log_to_file = TRUE; + else + log_to_term = TRUE; +#if DEBUG + if (debug > 0) + log_to_term = TRUE; +#endif + if (!(log_to_file || log_to_term)) + return; + + /* syslog() adds the timestamp, name, and pid */ + if (msyslog_include_timestamp) + human_time = humanlogtime(); + else /* suppress gcc pot. uninit. warning */ + human_time = NULL; + if (msyslog_term_pid || log_to_file) + pid = getpid(); + else /* suppress gcc pot. uninit. warning */ + pid = -1; + + /* syslog() adds trailing \n if not present */ + if ('\n' != msg[strlen(msg) - 1]) + nl_or_empty = nl; + else + nl_or_empty = empty; + + if (log_to_term) { + term_file = (level <= LOG_ERR) + ? stderr + : stdout; + if (msyslog_include_timestamp) + fprintf(term_file, "%s ", human_time); + if (msyslog_term_pid) + fprintf(term_file, "%s[%d]: ", prog, pid); + fprintf(term_file, "%s%s", msg, nl_or_empty); + fflush(term_file); + } + + if (log_to_file) { + if (msyslog_include_timestamp) + fprintf(syslog_file, "%s ", human_time); + fprintf(syslog_file, "%s[%d]: %s%s", prog, pid, msg, + nl_or_empty); + fflush(syslog_file); + } +} + -#if defined(__STDC__) || defined(HAVE_STDARG_H) -void msyslog(int level, const char *fmt, ...) -#else /* defined(__STDC__) || defined(HAVE_STDARG_H) */ - /*VARARGS*/ - void msyslog(va_alist) - va_dcl -#endif /* defined(__STDC__) || defined(HAVE_STDARG_H) */ +int +mvsnprintf( + char * buf, + size_t bufsiz, + const char * fmt, + va_list ap + ) { -#if defined(__STDC__) || defined(HAVE_STDARG_H) +#ifndef VSNPRINTF_PERCENT_M + char nfmt[256]; #else - int level; - const char *fmt; + const char * nfmt = fmt; #endif - va_list ap; - char buf[1025], nfmt[256]; + int errval; /* * Save the error value as soon as possible */ #ifdef SYS_WINNT - int errval = GetLastError(); -#else - int errval = errno; -#endif + errval = GetLastError(); + if (NO_ERROR == errval) +#endif /* SYS_WINNT */ + errval = errno; -#if defined(__STDC__) || defined(HAVE_STDARG_H) - va_start(ap, fmt); +#ifndef VSNPRINTF_PERCENT_M + format_errmsg(nfmt, sizeof(nfmt), fmt, errval); #else - va_start(ap); - - level = va_arg(ap, int); - fmt = va_arg(ap, char *); + errno = errval; #endif - format_errmsg(nfmt, sizeof(nfmt), fmt, errval); - - vsnprintf(buf, sizeof(buf), nfmt, ap); - addto_syslog(level, buf); - va_end(ap); + return vsnprintf(buf, bufsiz, nfmt, ap); } -#if defined(__STDC__) || defined(HAVE_STDARG_H) -void netsyslog(int level, const char *fmt, ...) -#else /* defined(__STDC__) || defined(HAVE_STDARG_H) */ - /*VARARGS*/ - void netsyslog(va_alist) - va_dcl -#endif /* defined(__STDC__) || defined(HAVE_STDARG_H) */ + + +int +mvfprintf( + FILE * fp, + const char * fmt, + va_list ap + ) { -#if defined(__STDC__) || defined(HAVE_STDARG_H) +#ifndef VSNPRINTF_PERCENT_M + char nfmt[256]; #else - int level; - const char *fmt; + const char * nfmt = fmt; #endif - va_list ap; - char buf[1025], nfmt[256]; + int errval; /* * Save the error value as soon as possible */ #ifdef SYS_WINNT - int errval = WSAGetLastError(); + errval = GetLastError(); + if (NO_ERROR == errval) +#endif /* SYS_WINNT */ + errval = errno; + +#ifndef VSNPRINTF_PERCENT_M + format_errmsg(nfmt, sizeof(nfmt), fmt, errval); #else - int errval = errno; + errno = errval; #endif + return vfprintf(fp, nfmt, ap); +} + + +int +mfprintf( + FILE * fp, + const char * fmt, + ... + ) +{ + va_list ap; + int rc; -#if defined(__STDC__) || defined(HAVE_STDARG_H) va_start(ap, fmt); -#else - va_start(ap); + rc = mvfprintf(fp, fmt, ap); + va_end(ap); - level = va_arg(ap, int); - fmt = va_arg(ap, char *); -#endif - format_errmsg(nfmt, sizeof(nfmt), fmt, errval); + return rc; +} - vsnprintf(buf, sizeof(buf), nfmt, ap); - addto_syslog(level, buf); + +int +mprintf( + const char * fmt, + ... + ) +{ + va_list ap; + int rc; + + va_start(ap, fmt); + rc = mvfprintf(stdout, fmt, ap); + va_end(ap); + + return rc; +} + + +int +msnprintf( + char * buf, + size_t bufsiz, + const char * fmt, + ... + ) +{ + va_list ap; + size_t rc; + + va_start(ap, fmt); + rc = mvsnprintf(buf, bufsiz, fmt, ap); + va_end(ap); + + return rc; +} + + +void +msyslog( + int level, + const char * fmt, + ... + ) +{ + char buf[1024]; + va_list ap; + + va_start(ap, fmt); + mvsnprintf(buf, sizeof(buf), fmt, ap); va_end(ap); + addto_syslog(level, buf); +} + +void +mvsyslog( + int level, + const char * fmt, + va_list ap + ) +{ + char buf[1024]; + mvsnprintf(buf, sizeof(buf), fmt, ap); + addto_syslog(level, buf); +} + + +/* + * Initialize the logging + * + * Called once per process, including forked children. + */ +void +init_logging( + const char * name, + u_int32 def_syslogmask, + int is_daemon + ) +{ + static int was_daemon; + char * cp; + const char * pname; + + /* + * ntpd defaults to only logging sync-category events, when + * NLOG() is used to conditionalize. Other libntp clients + * leave it alone so that all NLOG() conditionals will fire. + * This presumes all bits lit in ntp_syslogmask can't be + * configured via logconfig and all lit is thereby a sentinel + * that ntp_syslogmask is still at its default from libntp, + * keeping in mind this function is called in forked children + * where it has already been called in the parent earlier. + * Forked children pass 0 for def_syslogmask. + */ + if (INIT_NTP_SYSLOGMASK == ntp_syslogmask && + 0 != def_syslogmask) + ntp_syslogmask = def_syslogmask; /* set more via logconfig */ + + /* + * Logging. This may actually work on the gizmo board. Find a name + * to log with by using the basename + */ + cp = strrchr(name, DIR_SEP); + if (NULL == cp) + pname = name; + else + pname = 1 + cp; /* skip DIR_SEP */ + progname = estrdup(pname); +#ifdef SYS_WINNT /* strip ".exe" */ + cp = strrchr(progname, '.'); + if (NULL != cp && !strcasecmp(cp, ".exe")) + *cp = '\0'; +#endif + +#if !defined(VMS) + + if (is_daemon) + was_daemon = TRUE; +# ifndef LOG_DAEMON + openlog(progname, LOG_PID); +# else /* LOG_DAEMON */ + +# ifndef LOG_NTP +# define LOG_NTP LOG_DAEMON +# endif + openlog(progname, LOG_PID | LOG_NDELAY, (was_daemon) + ? LOG_NTP + : 0); +# ifdef DEBUG + if (debug) + setlogmask(LOG_UPTO(LOG_DEBUG)); + else +# endif /* DEBUG */ + setlogmask(LOG_UPTO(LOG_DEBUG)); /* @@@ was INFO */ +# endif /* LOG_DAEMON */ +#endif /* !VMS */ +} + + +/* + * change_logfile() + * + * Used to change from syslog to a logfile, or from one logfile to + * another, and to reopen logfiles after forking. On systems where + * ntpd forks, deals with converting relative logfile paths to + * absolute (root-based) because we reopen logfiles after the current + * directory has changed. + */ +int +change_logfile( + const char * fname, + int leave_crumbs + ) +{ + FILE * new_file; + const char * log_fname; + char * abs_fname; +#if !defined(SYS_WINNT) && !defined(SYS_VXWORKS) && !defined(VMS) + char curdir[512]; + size_t cd_octets; + size_t octets; +#endif /* POSIX */ + + REQUIRE(fname != NULL); + log_fname = fname; + + /* + * In a forked child of a parent which is logging to a file + * instead of syslog, syslog_file will be NULL and both + * syslog_fname and syslog_abs_fname will be non-NULL. + * If we are given the same filename previously opened + * and it's still open, there's nothing to do here. + */ + if (syslog_file != NULL && syslog_fname != NULL && + 0 == strcmp(syslog_fname, log_fname)) + return 0; + + if (0 == strcmp(log_fname, "stderr")) { + new_file = stderr; + abs_fname = estrdup(log_fname); + } else if (0 == strcmp(log_fname, "stdout")) { + new_file = stdout; + abs_fname = estrdup(log_fname); + } else { + if (syslog_fname != NULL && + 0 == strcmp(log_fname, syslog_fname)) + log_fname = syslog_abs_fname; +#if !defined(SYS_WINNT) && !defined(SYS_VXWORKS) && !defined(VMS) + if (log_fname != syslog_abs_fname && + DIR_SEP != log_fname[0] && + 0 != strcmp(log_fname, "stderr") && + 0 != strcmp(log_fname, "stdout") && + NULL != getcwd(curdir, sizeof(curdir))) { + cd_octets = strlen(curdir); + /* trim any trailing '/' */ + if (cd_octets > 1 && + DIR_SEP == curdir[cd_octets - 1]) + cd_octets--; + octets = cd_octets; + octets += 1; /* separator '/' */ + octets += strlen(log_fname); + octets += 1; /* NUL terminator */ + abs_fname = emalloc(octets); + snprintf(abs_fname, octets, "%.*s%c%s", + (int)cd_octets, curdir, DIR_SEP, + log_fname); + } else +#endif + abs_fname = estrdup(log_fname); + TRACE(1, ("attempting to open log %s\n", abs_fname)); + new_file = fopen(abs_fname, "a"); + } + + if (NULL == new_file) { + free(abs_fname); + return -1; + } + + /* leave a pointer in the old log */ + if (leave_crumbs && (syslogit || log_fname != syslog_abs_fname)) + msyslog(LOG_NOTICE, "switching logging to file %s", + abs_fname); + + if (syslog_file != NULL && + syslog_file != stderr && syslog_file != stdout && + fileno(syslog_file) != fileno(new_file)) + fclose(syslog_file); + syslog_file = new_file; + if (log_fname == syslog_abs_fname) { + free(abs_fname); + } else { + if (syslog_abs_fname != NULL && + syslog_abs_fname != syslog_fname) + free(syslog_abs_fname); + if (syslog_fname != NULL) + free(syslog_fname); + syslog_fname = estrdup(log_fname); + syslog_abs_fname = abs_fname; + } + syslogit = FALSE; + + return 0; +} + + +/* + * setup_logfile() + * + * Redirect logging to a file if requested with -l/--logfile or via + * ntp.conf logfile directive. + * + * This routine is invoked three different times in the sequence of a + * typical daemon ntpd with DNS lookups to do. First it is invoked in + * the original ntpd process, then again in the daemon after closing + * all descriptors. In both of those cases, ntp.conf has not been + * processed, so only -l/--logfile will trigger logfile redirection in + * those invocations. Finally, if DNS names are resolved, the worker + * child invokes this routine after its fork and close of all + * descriptors. In this case, ntp.conf has been processed and any + * "logfile" directive needs to be honored in the child as well. + */ +void +setup_logfile( + const char * name + ) +{ + if (NULL == syslog_fname && NULL != name) { + if (-1 == change_logfile(name, TRUE)) + msyslog(LOG_ERR, "Cannot open log file %s, %m", + name); + return ; + } + if (NULL == syslog_fname) + return; + + if (-1 == change_logfile(syslog_fname, FALSE)) + msyslog(LOG_ERR, "Cannot reopen log file %s, %m", + syslog_fname); } diff --git a/contrib/ntp/libntp/netof.c b/contrib/ntp/libntp/netof.c index fd57568d3..c8831c3dd 100644 --- a/contrib/ntp/libntp/netof.c +++ b/contrib/ntp/libntp/netof.c @@ -2,47 +2,54 @@ * netof - return the net address part of an ip address in a sockaddr_storage structure * (zero out host part) */ +#include #include +#include #include "ntp_fp.h" +#include "ntp_net.h" #include "ntp_stdlib.h" #include "ntp.h" -#define NUM_NETOF_BUFS 10 -static struct sockaddr_storage ssbuf[NUM_NETOF_BUFS]; -static int next_ssbuf = 0; - -struct sockaddr_storage* +sockaddr_u * netof( - struct sockaddr_storage* hostaddr + sockaddr_u *hostaddr ) { - register u_int32 netnum; - struct sockaddr_storage *netaddr; + static sockaddr_u netofbuf[8]; + static int next_netofbuf; + u_int32 netnum; + sockaddr_u * netaddr; + + netaddr = &netofbuf[next_netofbuf]; + next_netofbuf = (next_netofbuf + 1) % COUNTOF(netofbuf); - netaddr = &ssbuf[next_ssbuf++]; - if (next_ssbuf == NUM_NETOF_BUFS) - next_ssbuf = 0; - memcpy(netaddr, hostaddr, sizeof(struct sockaddr_storage)); + memcpy(netaddr, hostaddr, sizeof(*netaddr)); - if(netaddr->ss_family == AF_INET) { - netnum = ((struct sockaddr_in*)netaddr)->sin_addr.s_addr; + if (IS_IPV4(netaddr)) { + netnum = SRCADR(netaddr); /* * We live in a modern CIDR world where the basement nets, which * used to be class A, are now probably associated with each * host address. So, for class-A nets, all bits are significant. */ - if(IN_CLASSC(netnum)) - netnum &= IN_CLASSC_NET; + if (IN_CLASSC(netnum)) + netnum &= IN_CLASSC_NET; else if (IN_CLASSB(netnum)) - netnum &= IN_CLASSB_NET; - ((struct sockaddr_in*)netaddr)->sin_addr.s_addr = netnum; - } - else if(netaddr->ss_family == AF_INET6) { - /* Here we put 0 at the local link address so we get net address */ - memset(&((struct sockaddr_in6*)netaddr)->sin6_addr.s6_addr[8], 0, 8*sizeof(u_char)); - } - - return netaddr; + netnum &= IN_CLASSB_NET; + + SET_ADDR4(netaddr, netnum); + + } else if (IS_IPV6(netaddr)) + /* assume the typical /64 subnet size */ + zero_mem(&NSRCADR6(netaddr)[8], 8); +#ifdef DEBUG + else { + msyslog(LOG_ERR, "netof unknown AF %d", AF(netaddr)); + exit(1); + } +#endif + + return netaddr; } diff --git a/contrib/ntp/libntp/ntp_calendar.c b/contrib/ntp/libntp/ntp_calendar.c new file mode 100644 index 000000000..ff6ead364 --- /dev/null +++ b/contrib/ntp/libntp/ntp_calendar.c @@ -0,0 +1,1801 @@ +/* + * ntp_calendar.c - calendar and helper functions + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * + * -------------------------------------------------------------------- + * Some notes on the implementation: + * + * Calendar algorithms thrive on the division operation, which is one of + * the slowest numerical operations in any CPU. What saves us here from + * abysmal performance is the fact that all divisions are divisions by + * constant numbers, and most compilers can do this by a multiplication + * operation. But this might not work when using the div/ldiv/lldiv + * function family, because many compilers are not able to do inline + * expansion of the code with following optimisation for the + * constant-divider case. + * + * Also div/ldiv/lldiv are defined in terms of int/long/longlong, which + * are inherently target dependent. Nothing that could not be cured with + * autoconf, but still a mess... + * + * Furthermore, we need floor division in many places. C either leaves + * the division behaviour undefined (< C99) or demands truncation to + * zero (>= C99), so additional steps are required to make sure the + * algorithms work. The {l,ll}div function family is requested to + * truncate towards zero, which is also the wrong direction for our + * purpose. + * + * For all this, all divisions by constant are coded manually, even when + * there is a joined div/mod operation: The optimiser should sort that + * out, if possible. Most of the calculations are done with unsigned + * types, explicitely using two's complement arithmetics where + * necessary. This minimises the dependecies to compiler and target, + * while still giving reasonable to good performance. + * + * The implementation uses a few tricks that exploit properties of the + * two's complement: Floor division on negative dividents can be + * executed by using the one's complement of the divident. One's + * complement can be easily created using XOR and a mask. + * + * Finally, check for overflow conditions is minimal. There are only two + * calculation steps in the whole calendar that suffer from an internal + * overflow, and these conditions are checked: errno is set to EDOM and + * the results are clamped/saturated in this case. All other functions + * do not suffer from internal overflow and simply return the result + * truncated to 32 bits. + * + * This is a sacrifice made for execution speed. Since a 32-bit day + * counter covers +/- 5,879,610 years and the clamp limits the effective + * range to +/-2.9 million years, this should not pose a problem here. + * + */ + +#include +#include + +#include "ntp_types.h" +#include "ntp_calendar.h" +#include "ntp_stdlib.h" +#include "ntp_fp.h" +#include "ntp_unixtime.h" + +/* For now, let's take the conservative approach: if the target property + * macros are not defined, check a few well-known compiler/architecture + * settings. Default is to assume that the representation of signed + * integers is unknown and shift-arithmetic-right is not available. + */ +#ifndef TARGET_HAS_2CPL +# if defined(__GNUC__) +# if defined(__i386__) || defined(__x86_64__) || defined(__arm__) +# define TARGET_HAS_2CPL 1 +# else +# define TARGET_HAS_2CPL 0 +# endif +# elif defined(_MSC_VER) +# if defined(_M_IX86) || defined(_M_X64) || defined(_M_ARM) +# define TARGET_HAS_2CPL 1 +# else +# define TARGET_HAS_2CPL 0 +# endif +# else +# define TARGET_HAS_2CPL 0 +# endif +#endif + +#ifndef TARGET_HAS_SAR +# define TARGET_HAS_SAR 0 +#endif + +/* + *--------------------------------------------------------------------- + * replacing the 'time()' function + * -------------------------------------------------------------------- + */ + +static systime_func_ptr systime_func = &time; +static inline time_t now(void); + + +systime_func_ptr +ntpcal_set_timefunc( + systime_func_ptr nfunc + ) +{ + systime_func_ptr res; + + res = systime_func; + if (NULL == nfunc) + nfunc = &time; + systime_func = nfunc; + + return res; +} + + +static inline time_t +now(void) +{ + return (*systime_func)(NULL); +} + +/* + *--------------------------------------------------------------------- + * Get sign extension mask and unsigned 2cpl rep for a signed integer + *--------------------------------------------------------------------- + */ + +static inline uint32_t +int32_sflag( + const int32_t v) +{ +# if TARGET_HAS_2CPL && TARGET_HAS_SAR && SIZEOF_INT >= 4 + + /* Let's assume that shift is the fastest way to get the sign + * extension of of a signed integer. This might not always be + * true, though -- On 8bit CPUs or machines without barrel + * shifter this will kill the performance. So we make sure + * we do this only if 'int' has at least 4 bytes. + */ + return (uint32_t)(v >> 31); + +# else + + /* This should be a rather generic approach for getting a sign + * extension mask... + */ + return UINT32_C(0) - (uint32_t)(v < 0); + +# endif +} + +static inline uint32_t +int32_to_uint32_2cpl( + const int32_t v) +{ + uint32_t vu; + +# if TARGET_HAS_2CPL + + /* Just copy through the 32 bits from the signed value if we're + * on a two's complement target. + */ + vu = (uint32_t)v; + +# else + + /* Convert from signed int to unsigned int two's complement. Do + * not make any assumptions about the representation of signed + * integers, but make sure signed integer overflow cannot happen + * here. A compiler on a two's complement target *might* find + * out that this is just a complicated cast (as above), but your + * mileage might vary. + */ + if (v < 0) + vu = ~(uint32_t)(-(v + 1)); + else + vu = (uint32_t)v; + +# endif + + return vu; +} + +static inline int32_t +uint32_2cpl_to_int32( + const uint32_t vu) +{ + int32_t v; + +# if TARGET_HAS_2CPL + + /* Just copy through the 32 bits from the unsigned value if + * we're on a two's complement target. + */ + v = (int32_t)vu; + +# else + + /* Convert to signed integer, making sure signed integer + * overflow cannot happen. Again, the optimiser might or might + * not find out that this is just a copy of 32 bits on a target + * with two's complement representation for signed integers. + */ + if (vu > INT32_MAX) + v = -(int32_t)(~vu) - 1; + else + v = (int32_t)vu; + +# endif + + return v; +} + +/* Some of the calculations need to multiply the input by 4 before doing + * a division. This can cause overflow and strange results. Therefore we + * clamp / saturate the input operand. And since we do the calculations + * in unsigned int with an extra sign flag/mask, we only loose one bit + * of the input value range. + */ +static inline uint32_t +uint32_saturate( + uint32_t vu, + uint32_t mu) +{ + static const uint32_t limit = UINT32_MAX/4u; + if ((mu ^ vu) > limit) { + vu = mu ^ limit; + errno = EDOM; + } + return vu; +} + +/* + *--------------------------------------------------------------------- + * Convert between 'time_t' and 'vint64' + *--------------------------------------------------------------------- + */ +vint64 +time_to_vint64( + const time_t * ptt + ) +{ + vint64 res; + time_t tt; + + tt = *ptt; + +# if SIZEOF_TIME_T <= 4 + + res.D_s.hi = 0; + if (tt < 0) { + res.D_s.lo = (uint32_t)-tt; + M_NEG(res.D_s.hi, res.D_s.lo); + } else { + res.D_s.lo = (uint32_t)tt; + } + +# elif defined(HAVE_INT64) + + res.q_s = tt; + +# else + /* + * shifting negative signed quantities is compiler-dependent, so + * we better avoid it and do it all manually. And shifting more + * than the width of a quantity is undefined. Also a don't do! + */ + if (tt < 0) { + tt = -tt; + res.D_s.lo = (uint32_t)tt; + res.D_s.hi = (uint32_t)(tt >> 32); + M_NEG(res.D_s.hi, res.D_s.lo); + } else { + res.D_s.lo = (uint32_t)tt; + res.D_s.hi = (uint32_t)(tt >> 32); + } + +# endif + + return res; +} + + +time_t +vint64_to_time( + const vint64 *tv + ) +{ + time_t res; + +# if SIZEOF_TIME_T <= 4 + + res = (time_t)tv->D_s.lo; + +# elif defined(HAVE_INT64) + + res = (time_t)tv->q_s; + +# else + + res = ((time_t)tv->d_s.hi << 32) | tv->D_s.lo; + +# endif + + return res; +} + +/* + *--------------------------------------------------------------------- + * Get the build date & time + *--------------------------------------------------------------------- + */ +int +ntpcal_get_build_date( + struct calendar * jd + ) +{ + /* The C standard tells us the format of '__DATE__': + * + * __DATE__ The date of translation of the preprocessing + * translation unit: a character string literal of the form "Mmm + * dd yyyy", where the names of the months are the same as those + * generated by the asctime function, and the first character of + * dd is a space character if the value is less than 10. If the + * date of translation is not available, an + * implementation-defined valid date shall be supplied. + * + * __TIME__ The time of translation of the preprocessing + * translation unit: a character string literal of the form + * "hh:mm:ss" as in the time generated by the asctime + * function. If the time of translation is not available, an + * implementation-defined valid time shall be supplied. + * + * Note that MSVC declares DATE and TIME to be in the local time + * zone, while neither the C standard nor the GCC docs make any + * statement about this. As a result, we may be +/-12hrs off + * UTC. But for practical purposes, this should not be a + * problem. + * + */ +# ifdef MKREPRO_DATE + static const char build[] = MKREPRO_TIME "/" MKREPRO_DATE; +# else + static const char build[] = __TIME__ "/" __DATE__; +# endif + static const char mlist[] = "JanFebMarAprMayJunJulAugSepOctNovDec"; + + char monstr[4]; + const char * cp; + unsigned short hour, minute, second, day, year; + /* Note: The above quantities are used for sscanf 'hu' format, + * so using 'uint16_t' is contra-indicated! + */ + +# ifdef DEBUG + static int ignore = 0; +# endif + + ZERO(*jd); + jd->year = 1970; + jd->month = 1; + jd->monthday = 1; + +# ifdef DEBUG + /* check environment if build date should be ignored */ + if (0 == ignore) { + const char * envstr; + envstr = getenv("NTPD_IGNORE_BUILD_DATE"); + ignore = 1 + (envstr && (!*envstr || !strcasecmp(envstr, "yes"))); + } + if (ignore > 1) + return FALSE; +# endif + + if (6 == sscanf(build, "%hu:%hu:%hu/%3s %hu %hu", + &hour, &minute, &second, monstr, &day, &year)) { + cp = strstr(mlist, monstr); + if (NULL != cp) { + jd->year = year; + jd->month = (uint8_t)((cp - mlist) / 3 + 1); + jd->monthday = (uint8_t)day; + jd->hour = (uint8_t)hour; + jd->minute = (uint8_t)minute; + jd->second = (uint8_t)second; + + return TRUE; + } + } + + return FALSE; +} + + +/* + *--------------------------------------------------------------------- + * basic calendar stuff + * -------------------------------------------------------------------- + */ + +/* month table for a year starting with March,1st */ +static const uint16_t shift_month_table[13] = { + 0, 31, 61, 92, 122, 153, 184, 214, 245, 275, 306, 337, 366 +}; + +/* month tables for years starting with January,1st; regular & leap */ +static const uint16_t real_month_table[2][13] = { + /* -*- table for regular years -*- */ + { 0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365 }, + /* -*- table for leap years -*- */ + { 0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366 } +}; + +/* + * Some notes on the terminology: + * + * We use the proleptic Gregorian calendar, which is the Gregorian + * calendar extended in both directions ad infinitum. This totally + * disregards the fact that this calendar was invented in 1582, and + * was adopted at various dates over the world; sometimes even after + * the start of the NTP epoch. + * + * Normally date parts are given as current cycles, while time parts + * are given as elapsed cycles: + * + * 1970-01-01/03:04:05 means 'IN the 1970st. year, IN the first month, + * ON the first day, with 3hrs, 4minutes and 5 seconds elapsed. + * + * The basic calculations for this calendar implementation deal with + * ELAPSED date units, which is the number of full years, full months + * and full days before a date: 1970-01-01 would be (1969, 0, 0) in + * that notation. + * + * To ease the numeric computations, month and day values outside the + * normal range are acceptable: 2001-03-00 will be treated as the day + * before 2001-03-01, 2000-13-32 will give the same result as + * 2001-02-01 and so on. + * + * 'rd' or 'RD' is used as an abbreviation for the latin 'rata die' + * (day number). This is the number of days elapsed since 0000-12-31 + * in the proleptic Gregorian calendar. The begin of the Christian Era + * (0001-01-01) is RD(1). + */ + +/* + * ================================================================== + * + * General algorithmic stuff + * + * ================================================================== + */ + +/* + *--------------------------------------------------------------------- + * Do a periodic extension of 'value' around 'pivot' with a period of + * 'cycle'. + * + * The result 'res' is a number that holds to the following properties: + * + * 1) res MOD cycle == value MOD cycle + * 2) pivot <= res < pivot + cycle + * (replace />= for negative cycles) + * + * where 'MOD' denotes the modulo operator for FLOOR DIVISION, which + * is not the same as the '%' operator in C: C requires division to be + * a truncated division, where remainder and dividend have the same + * sign if the remainder is not zero, whereas floor division requires + * divider and modulus to have the same sign for a non-zero modulus. + * + * This function has some useful applications: + * + * + let Y be a calendar year and V a truncated 2-digit year: then + * periodic_extend(Y-50, V, 100) + * is the closest expansion of the truncated year with respect to + * the full year, that is a 4-digit year with a difference of less + * than 50 years to the year Y. ("century unfolding") + * + * + let T be a UN*X time stamp and V be seconds-of-day: then + * perodic_extend(T-43200, V, 86400) + * is a time stamp that has the same seconds-of-day as the input + * value, with an absolute difference to T of <= 12hrs. ("day + * unfolding") + * + * + Wherever you have a truncated periodic value and a non-truncated + * base value and you want to match them somehow... + * + * Basically, the function delivers 'pivot + (value - pivot) % cycle', + * but the implementation takes some pains to avoid internal signed + * integer overflows in the '(value - pivot) % cycle' part and adheres + * to the floor division convention. + * + * If 64bit scalars where available on all intended platforms, writing a + * version that uses 64 bit ops would be easy; writing a general + * division routine for 64bit ops on a platform that can only do + * 32/16bit divisions and is still performant is a bit more + * difficult. Since most usecases can be coded in a way that does only + * require the 32-bit version a 64bit version is NOT provided here. + * --------------------------------------------------------------------- + */ +int32_t +ntpcal_periodic_extend( + int32_t pivot, + int32_t value, + int32_t cycle + ) +{ + uint32_t diff; + char cpl = 0; /* modulo complement flag */ + char neg = 0; /* sign change flag */ + + /* make the cycle positive and adjust the flags */ + if (cycle < 0) { + cycle = - cycle; + neg ^= 1; + cpl ^= 1; + } + /* guard against div by zero or one */ + if (cycle > 1) { + /* + * Get absolute difference as unsigned quantity and + * the complement flag. This is done by always + * subtracting the smaller value from the bigger + * one. + */ + if (value >= pivot) { + diff = int32_to_uint32_2cpl(value) + - int32_to_uint32_2cpl(pivot); + } else { + diff = int32_to_uint32_2cpl(pivot) + - int32_to_uint32_2cpl(value); + cpl ^= 1; + } + diff %= (uint32_t)cycle; + if (diff) { + if (cpl) + diff = (uint32_t)cycle - diff; + if (neg) + diff = ~diff + 1; + pivot += uint32_2cpl_to_int32(diff); + } + } + return pivot; +} + +/* + *------------------------------------------------------------------- + * Convert a timestamp in NTP scale to a 64bit seconds value in the UN*X + * scale with proper epoch unfolding around a given pivot or the current + * system time. This function happily accepts negative pivot values as + * timestamps befor 1970-01-01, so be aware of possible trouble on + * platforms with 32bit 'time_t'! + * + * This is also a periodic extension, but since the cycle is 2^32 and + * the shift is 2^31, we can do some *very* fast math without explicit + * divisions. + *------------------------------------------------------------------- + */ +vint64 +ntpcal_ntp_to_time( + uint32_t ntp, + const time_t * pivot + ) +{ + vint64 res; + +# if defined(HAVE_INT64) + + res.q_s = (pivot != NULL) + ? *pivot + : now(); + res.Q_s -= 0x80000000; /* unshift of half range */ + ntp -= (uint32_t)JAN_1970; /* warp into UN*X domain */ + ntp -= res.D_s.lo; /* cycle difference */ + res.Q_s += (uint64_t)ntp; /* get expanded time */ + +# else /* no 64bit scalars */ + + time_t tmp; + + tmp = (pivot != NULL) + ? *pivot + : now(); + res = time_to_vint64(&tmp); + M_SUB(res.D_s.hi, res.D_s.lo, 0, 0x80000000); + ntp -= (uint32_t)JAN_1970; /* warp into UN*X domain */ + ntp -= res.D_s.lo; /* cycle difference */ + M_ADD(res.D_s.hi, res.D_s.lo, 0, ntp); + +# endif /* no 64bit scalars */ + + return res; +} + +/* + *------------------------------------------------------------------- + * Convert a timestamp in NTP scale to a 64bit seconds value in the NTP + * scale with proper epoch unfolding around a given pivot or the current + * system time. + * + * Note: The pivot must be given in the UN*X time domain! + * + * This is also a periodic extension, but since the cycle is 2^32 and + * the shift is 2^31, we can do some *very* fast math without explicit + * divisions. + *------------------------------------------------------------------- + */ +vint64 +ntpcal_ntp_to_ntp( + uint32_t ntp, + const time_t *pivot + ) +{ + vint64 res; + +# if defined(HAVE_INT64) + + res.q_s = (pivot) + ? *pivot + : now(); + res.Q_s -= 0x80000000; /* unshift of half range */ + res.Q_s += (uint32_t)JAN_1970; /* warp into NTP domain */ + ntp -= res.D_s.lo; /* cycle difference */ + res.Q_s += (uint64_t)ntp; /* get expanded time */ + +# else /* no 64bit scalars */ + + time_t tmp; + + tmp = (pivot) + ? *pivot + : now(); + res = time_to_vint64(&tmp); + M_SUB(res.D_s.hi, res.D_s.lo, 0, 0x80000000u); + M_ADD(res.D_s.hi, res.D_s.lo, 0, (uint32_t)JAN_1970);/*into NTP */ + ntp -= res.D_s.lo; /* cycle difference */ + M_ADD(res.D_s.hi, res.D_s.lo, 0, ntp); + +# endif /* no 64bit scalars */ + + return res; +} + + +/* + * ================================================================== + * + * Splitting values to composite entities + * + * ================================================================== + */ + +/* + *------------------------------------------------------------------- + * Split a 64bit seconds value into elapsed days in 'res.hi' and + * elapsed seconds since midnight in 'res.lo' using explicit floor + * division. This function happily accepts negative time values as + * timestamps before the respective epoch start. + * ------------------------------------------------------------------- + */ +ntpcal_split +ntpcal_daysplit( + const vint64 *ts + ) +{ + ntpcal_split res; + uint32_t Q; + +# if defined(HAVE_INT64) + + /* Manual floor division by SECSPERDAY. This uses the one's + * complement trick, too, but without an extra flag value: The + * flag would be 64bit, and that's a bit of overkill on a 32bit + * target that has to use a register pair for a 64bit number. + */ + if (ts->q_s < 0) + Q = ~(uint32_t)(~ts->Q_s / SECSPERDAY); + else + Q = (uint32_t)(ts->Q_s / SECSPERDAY); + +# else + + uint32_t ah, al, sflag, A; + + /* get operand into ah/al (either ts or ts' one's complement, + * for later floor division) + */ + sflag = int32_sflag(ts->d_s.hi); + ah = sflag ^ ts->D_s.hi; + al = sflag ^ ts->D_s.lo; + + /* Since 86400 == 128*675 we can drop the least 7 bits and + * divide by 675 instead of 86400. Then the maximum remainder + * after each devision step is 674, and we need 10 bits for + * that. So in the next step we can shift in 22 bits from the + * numerator. + * + * Therefore we load the accu with the top 13 bits (51..63) in + * the first shot. We don't have to remember the quotient -- it + * would be shifted out anyway. + */ + A = ah >> 19; + if (A >= 675) + A = (A % 675u); + + /* Now assemble the remainder with bits 29..50 from the + * numerator and divide. This creates the upper ten bits of the + * quotient. (Well, the top 22 bits of a 44bit result. But that + * will be truncated to 32 bits anyway.) + */ + A = (A << 19) | (ah & 0x0007FFFFu); + A = (A << 3) | (al >> 29); + Q = A / 675u; + A = A % 675u; + + /* Now assemble the remainder with bits 7..28 from the numerator + * and do a final division step. + */ + A = (A << 22) | ((al >> 7) & 0x003FFFFFu); + Q = (Q << 22) | (A / 675u); + + /* The last 7 bits get simply dropped, as they have no affect on + * the quotient when dividing by 86400. + */ + + /* apply sign correction and calculate the true floor + * remainder. + */ + Q ^= sflag; + +# endif + + res.hi = uint32_2cpl_to_int32(Q); + res.lo = ts->D_s.lo - Q * SECSPERDAY; + + return res; +} + +/* + *------------------------------------------------------------------- + * Split a 32bit seconds value into h/m/s and excessive days. This + * function happily accepts negative time values as timestamps before + * midnight. + * ------------------------------------------------------------------- + */ +static int32_t +priv_timesplit( + int32_t split[3], + int32_t ts + ) +{ + /* Do 3 chained floor divisions by positive constants, using the + * one's complement trick and factoring out the intermediate XOR + * ops to reduce the number of operations. + */ + uint32_t us, um, uh, ud, sflag; + + sflag = int32_sflag(ts); + us = int32_to_uint32_2cpl(ts); + + um = (sflag ^ us) / SECSPERMIN; + uh = um / MINSPERHR; + ud = uh / HRSPERDAY; + + um ^= sflag; + uh ^= sflag; + ud ^= sflag; + + split[0] = (int32_t)(uh - ud * HRSPERDAY ); + split[1] = (int32_t)(um - uh * MINSPERHR ); + split[2] = (int32_t)(us - um * SECSPERMIN); + + return uint32_2cpl_to_int32(ud); +} + +/* + * --------------------------------------------------------------------- + * Given the number of elapsed days in the calendar era, split this + * number into the number of elapsed years in 'res.hi' and the number + * of elapsed days of that year in 'res.lo'. + * + * if 'isleapyear' is not NULL, it will receive an integer that is 0 for + * regular years and a non-zero value for leap years. + *--------------------------------------------------------------------- + */ +ntpcal_split +ntpcal_split_eradays( + int32_t days, + int *isleapyear + ) +{ + /* Use the fast cyclesplit algorithm here, to calculate the + * centuries and years in a century with one division each. This + * reduces the number of division operations to two, but is + * susceptible to internal range overflow. We make sure the + * input operands are in the safe range; this still gives us + * approx +/-2.9 million years. + */ + ntpcal_split res; + int32_t n100, n001; /* calendar year cycles */ + uint32_t uday, Q, sflag; + + /* split off centuries first */ + sflag = int32_sflag(days); + uday = uint32_saturate(int32_to_uint32_2cpl(days), sflag); + uday = (4u * uday) | 3u; + Q = sflag ^ ((sflag ^ uday) / GREGORIAN_CYCLE_DAYS); + uday = uday - Q * GREGORIAN_CYCLE_DAYS; + n100 = uint32_2cpl_to_int32(Q); + + /* Split off years in century -- days >= 0 here, and we're far + * away from integer overflow trouble now. */ + uday |= 3; + n001 = uday / GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; + uday = uday % GREGORIAN_NORMAL_LEAP_CYCLE_DAYS; + + /* Assemble the year and day in year */ + res.hi = n100 * 100 + n001; + res.lo = uday / 4u; + + /* Eventually set the leap year flag. Note: 0 <= n001 <= 99 and + * Q is still the two's complement representation of the + * centuries: The modulo 4 ops can be done with masking here. + * We also shift the year and the century by one, so the tests + * can be done against zero instead of 3. + */ + if (isleapyear) + *isleapyear = !((n001+1) & 3) + && ((n001 != 99) || !((Q+1) & 3)); + + return res; +} + +/* + *--------------------------------------------------------------------- + * Given a number of elapsed days in a year and a leap year indicator, + * split the number of elapsed days into the number of elapsed months in + * 'res.hi' and the number of elapsed days of that month in 'res.lo'. + * + * This function will fail and return {-1,-1} if the number of elapsed + * days is not in the valid range! + *--------------------------------------------------------------------- + */ +ntpcal_split +ntpcal_split_yeardays( + int32_t eyd, + int isleapyear + ) +{ + ntpcal_split res; + const uint16_t *lt; /* month length table */ + + /* check leap year flag and select proper table */ + lt = real_month_table[(isleapyear != 0)]; + if (0 <= eyd && eyd < lt[12]) { + /* get zero-based month by approximation & correction step */ + res.hi = eyd >> 5; /* approx month; might be 1 too low */ + if (lt[res.hi + 1] <= eyd) /* fixup approximative month value */ + res.hi += 1; + res.lo = eyd - lt[res.hi]; + } else { + res.lo = res.hi = -1; + } + + return res; +} + +/* + *--------------------------------------------------------------------- + * Convert a RD into the date part of a 'struct calendar'. + *--------------------------------------------------------------------- + */ +int +ntpcal_rd_to_date( + struct calendar *jd, + int32_t rd + ) +{ + ntpcal_split split; + int leapy; + u_int ymask; + + /* Get day-of-week first. Since rd is signed, the remainder can + * be in the range [-6..+6], but the assignment to an unsigned + * variable maps the negative values to positive values >=7. + * This makes the sign correction look strange, but adding 7 + * causes the needed wrap-around into the desired value range of + * zero to six, both inclusive. + */ + jd->weekday = rd % DAYSPERWEEK; + if (jd->weekday >= DAYSPERWEEK) /* weekday is unsigned! */ + jd->weekday += DAYSPERWEEK; + + split = ntpcal_split_eradays(rd - 1, &leapy); + /* Get year and day-of-year, with overflow check. If any of the + * upper 16 bits is set after shifting to unity-based years, we + * will have an overflow when converting to an unsigned 16bit + * year. Shifting to the right is OK here, since it does not + * matter if the shift is logic or arithmetic. + */ + split.hi += 1; + ymask = 0u - ((split.hi >> 16) == 0); + jd->year = (uint16_t)(split.hi & ymask); + jd->yearday = (uint16_t)split.lo + 1; + + /* convert to month and mday */ + split = ntpcal_split_yeardays(split.lo, leapy); + jd->month = (uint8_t)split.hi + 1; + jd->monthday = (uint8_t)split.lo + 1; + + return ymask ? leapy : -1; +} + +/* + *--------------------------------------------------------------------- + * Convert a RD into the date part of a 'struct tm'. + *--------------------------------------------------------------------- + */ +int +ntpcal_rd_to_tm( + struct tm *utm, + int32_t rd + ) +{ + ntpcal_split split; + int leapy; + + /* get day-of-week first */ + utm->tm_wday = rd % DAYSPERWEEK; + if (utm->tm_wday < 0) + utm->tm_wday += DAYSPERWEEK; + + /* get year and day-of-year */ + split = ntpcal_split_eradays(rd - 1, &leapy); + utm->tm_year = split.hi - 1899; + utm->tm_yday = split.lo; /* 0-based */ + + /* convert to month and mday */ + split = ntpcal_split_yeardays(split.lo, leapy); + utm->tm_mon = split.hi; /* 0-based */ + utm->tm_mday = split.lo + 1; /* 1-based */ + + return leapy; +} + +/* + *--------------------------------------------------------------------- + * Take a value of seconds since midnight and split it into hhmmss in a + * 'struct calendar'. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_daysec_to_date( + struct calendar *jd, + int32_t sec + ) +{ + int32_t days; + int ts[3]; + + days = priv_timesplit(ts, sec); + jd->hour = (uint8_t)ts[0]; + jd->minute = (uint8_t)ts[1]; + jd->second = (uint8_t)ts[2]; + + return days; +} + +/* + *--------------------------------------------------------------------- + * Take a value of seconds since midnight and split it into hhmmss in a + * 'struct tm'. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_daysec_to_tm( + struct tm *utm, + int32_t sec + ) +{ + int32_t days; + int32_t ts[3]; + + days = priv_timesplit(ts, sec); + utm->tm_hour = ts[0]; + utm->tm_min = ts[1]; + utm->tm_sec = ts[2]; + + return days; +} + +/* + *--------------------------------------------------------------------- + * take a split representation for day/second-of-day and day offset + * and convert it to a 'struct calendar'. The seconds will be normalised + * into the range of a day, and the day will be adjusted accordingly. + * + * returns >0 if the result is in a leap year, 0 if in a regular + * year and <0 if the result did not fit into the calendar struct. + *--------------------------------------------------------------------- + */ +int +ntpcal_daysplit_to_date( + struct calendar *jd, + const ntpcal_split *ds, + int32_t dof + ) +{ + dof += ntpcal_daysec_to_date(jd, ds->lo); + return ntpcal_rd_to_date(jd, ds->hi + dof); +} + +/* + *--------------------------------------------------------------------- + * take a split representation for day/second-of-day and day offset + * and convert it to a 'struct tm'. The seconds will be normalised + * into the range of a day, and the day will be adjusted accordingly. + * + * returns 1 if the result is in a leap year and zero if in a regular + * year. + *--------------------------------------------------------------------- + */ +int +ntpcal_daysplit_to_tm( + struct tm *utm, + const ntpcal_split *ds , + int32_t dof + ) +{ + dof += ntpcal_daysec_to_tm(utm, ds->lo); + + return ntpcal_rd_to_tm(utm, ds->hi + dof); +} + +/* + *--------------------------------------------------------------------- + * Take a UN*X time and convert to a calendar structure. + *--------------------------------------------------------------------- + */ +int +ntpcal_time_to_date( + struct calendar *jd, + const vint64 *ts + ) +{ + ntpcal_split ds; + + ds = ntpcal_daysplit(ts); + ds.hi += ntpcal_daysec_to_date(jd, ds.lo); + ds.hi += DAY_UNIX_STARTS; + + return ntpcal_rd_to_date(jd, ds.hi); +} + + +/* + * ================================================================== + * + * merging composite entities + * + * ================================================================== + */ + +/* + *--------------------------------------------------------------------- + * Merge a number of days and a number of seconds into seconds, + * expressed in 64 bits to avoid overflow. + *--------------------------------------------------------------------- + */ +vint64 +ntpcal_dayjoin( + int32_t days, + int32_t secs + ) +{ + vint64 res; + +# if defined(HAVE_INT64) + + res.q_s = days; + res.q_s *= SECSPERDAY; + res.q_s += secs; + +# else + + uint32_t p1, p2; + int isneg; + + /* + * res = days *86400 + secs, using manual 16/32 bit + * multiplications and shifts. + */ + isneg = (days < 0); + if (isneg) + days = -days; + + /* assemble days * 675 */ + res.D_s.lo = (days & 0xFFFF) * 675u; + res.D_s.hi = 0; + p1 = (days >> 16) * 675u; + p2 = p1 >> 16; + p1 = p1 << 16; + M_ADD(res.D_s.hi, res.D_s.lo, p2, p1); + + /* mul by 128, using shift */ + res.D_s.hi = (res.D_s.hi << 7) | (res.D_s.lo >> 25); + res.D_s.lo = (res.D_s.lo << 7); + + /* fix sign */ + if (isneg) + M_NEG(res.D_s.hi, res.D_s.lo); + + /* properly add seconds */ + p2 = 0; + if (secs < 0) { + p1 = (uint32_t)-secs; + M_NEG(p2, p1); + } else { + p1 = (uint32_t)secs; + } + M_ADD(res.D_s.hi, res.D_s.lo, p2, p1); + +# endif + + return res; +} + +/* + *--------------------------------------------------------------------- + * get leap years since epoch in elapsed years + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_leapyears_in_years( + int32_t years + ) +{ + /* We use the in-out-in algorithm here, using the one's + * complement division trick for negative numbers. The chained + * division sequence by 4/25/4 gives the compiler the chance to + * get away with only one true division and doing shifts otherwise. + */ + + uint32_t sflag, sum, uyear; + + sflag = int32_sflag(years); + uyear = int32_to_uint32_2cpl(years); + uyear ^= sflag; + + sum = (uyear /= 4u); /* 4yr rule --> IN */ + sum -= (uyear /= 25u); /* 100yr rule --> OUT */ + sum += (uyear /= 4u); /* 400yr rule --> IN */ + + /* Thanks to the alternation of IN/OUT/IN we can do the sum + * directly and have a single one's complement operation + * here. (Only if the years are negative, of course.) Otherwise + * the one's complement would have to be done when + * adding/subtracting the terms. + */ + return uint32_2cpl_to_int32(sflag ^ sum); +} + +/* + *--------------------------------------------------------------------- + * Convert elapsed years in Era into elapsed days in Era. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_days_in_years( + int32_t years + ) +{ + return years * DAYSPERYEAR + ntpcal_leapyears_in_years(years); +} + +/* + *--------------------------------------------------------------------- + * Convert a number of elapsed month in a year into elapsed days in year. + * + * The month will be normalized, and 'res.hi' will contain the + * excessive years that must be considered when converting the years, + * while 'res.lo' will contain the number of elapsed days since start + * of the year. + * + * This code uses the shifted-month-approach to convert month to days, + * because then there is no need to have explicit leap year + * information. The slight disadvantage is that for most month values + * the result is a negative value, and the year excess is one; the + * conversion is then simply based on the start of the following year. + *--------------------------------------------------------------------- + */ +ntpcal_split +ntpcal_days_in_months( + int32_t m + ) +{ + ntpcal_split res; + + /* Add ten months and correct if needed. (It likely is...) */ + res.lo = m + 10; + res.hi = (res.lo >= 12); + if (res.hi) + res.lo -= 12; + + /* if still out of range, normalise by floor division ... */ + if (res.lo < 0 || res.lo >= 12) { + uint32_t mu, Q, sflag; + sflag = int32_sflag(res.lo); + mu = int32_to_uint32_2cpl(res.lo); + Q = sflag ^ ((sflag ^ mu) / 12u); + res.hi += uint32_2cpl_to_int32(Q); + res.lo = mu - Q * 12u; + } + + /* get cummulated days in year with unshift */ + res.lo = shift_month_table[res.lo] - 306; + + return res; +} + +/* + *--------------------------------------------------------------------- + * Convert ELAPSED years/months/days of gregorian calendar to elapsed + * days in Gregorian epoch. + * + * If you want to convert years and days-of-year, just give a month of + * zero. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_edate_to_eradays( + int32_t years, + int32_t mons, + int32_t mdays + ) +{ + ntpcal_split tmp; + int32_t res; + + if (mons) { + tmp = ntpcal_days_in_months(mons); + res = ntpcal_days_in_years(years + tmp.hi) + tmp.lo; + } else + res = ntpcal_days_in_years(years); + res += mdays; + + return res; +} + +/* + *--------------------------------------------------------------------- + * Convert ELAPSED years/months/days of gregorian calendar to elapsed + * days in year. + * + * Note: This will give the true difference to the start of the given year, + * even if months & days are off-scale. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_edate_to_yeardays( + int32_t years, + int32_t mons, + int32_t mdays + ) +{ + ntpcal_split tmp; + + if (0 <= mons && mons < 12) { + years += 1; + mdays += real_month_table[is_leapyear(years)][mons]; + } else { + tmp = ntpcal_days_in_months(mons); + mdays += tmp.lo + + ntpcal_days_in_years(years + tmp.hi) + - ntpcal_days_in_years(years); + } + + return mdays; +} + +/* + *--------------------------------------------------------------------- + * Convert elapsed days and the hour/minute/second information into + * total seconds. + * + * If 'isvalid' is not NULL, do a range check on the time specification + * and tell if the time input is in the normal range, permitting for a + * single leapsecond. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_etime_to_seconds( + int32_t hours, + int32_t minutes, + int32_t seconds + ) +{ + int32_t res; + + res = (hours * MINSPERHR + minutes) * SECSPERMIN + seconds; + + return res; +} + +/* + *--------------------------------------------------------------------- + * Convert the date part of a 'struct tm' (that is, year, month, + * day-of-month) into the RD of that day. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_tm_to_rd( + const struct tm *utm + ) +{ + return ntpcal_edate_to_eradays(utm->tm_year + 1899, + utm->tm_mon, + utm->tm_mday - 1) + 1; +} + +/* + *--------------------------------------------------------------------- + * Convert the date part of a 'struct calendar' (that is, year, month, + * day-of-month) into the RD of that day. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_date_to_rd( + const struct calendar *jd + ) +{ + return ntpcal_edate_to_eradays((int32_t)jd->year - 1, + (int32_t)jd->month - 1, + (int32_t)jd->monthday - 1) + 1; +} + +/* + *--------------------------------------------------------------------- + * convert a year number to rata die of year start + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_year_to_ystart( + int32_t year + ) +{ + return ntpcal_days_in_years(year - 1) + 1; +} + +/* + *--------------------------------------------------------------------- + * For a given RD, get the RD of the associated year start, + * that is, the RD of the last January,1st on or before that day. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_rd_to_ystart( + int32_t rd + ) +{ + /* + * Rather simple exercise: split the day number into elapsed + * years and elapsed days, then remove the elapsed days from the + * input value. Nice'n sweet... + */ + return rd - ntpcal_split_eradays(rd - 1, NULL).lo; +} + +/* + *--------------------------------------------------------------------- + * For a given RD, get the RD of the associated month start. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_rd_to_mstart( + int32_t rd + ) +{ + ntpcal_split split; + int leaps; + + split = ntpcal_split_eradays(rd - 1, &leaps); + split = ntpcal_split_yeardays(split.lo, leaps); + + return rd - split.lo; +} + +/* + *--------------------------------------------------------------------- + * take a 'struct calendar' and get the seconds-of-day from it. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_date_to_daysec( + const struct calendar *jd + ) +{ + return ntpcal_etime_to_seconds(jd->hour, jd->minute, + jd->second); +} + +/* + *--------------------------------------------------------------------- + * take a 'struct tm' and get the seconds-of-day from it. + *--------------------------------------------------------------------- + */ +int32_t +ntpcal_tm_to_daysec( + const struct tm *utm + ) +{ + return ntpcal_etime_to_seconds(utm->tm_hour, utm->tm_min, + utm->tm_sec); +} + +/* + *--------------------------------------------------------------------- + * take a 'struct calendar' and convert it to a 'time_t' + *--------------------------------------------------------------------- + */ +time_t +ntpcal_date_to_time( + const struct calendar *jd + ) +{ + vint64 join; + int32_t days, secs; + + days = ntpcal_date_to_rd(jd) - DAY_UNIX_STARTS; + secs = ntpcal_date_to_daysec(jd); + join = ntpcal_dayjoin(days, secs); + + return vint64_to_time(&join); +} + + +/* + * ================================================================== + * + * extended and unchecked variants of caljulian/caltontp + * + * ================================================================== + */ +int +ntpcal_ntp64_to_date( + struct calendar *jd, + const vint64 *ntp + ) +{ + ntpcal_split ds; + + ds = ntpcal_daysplit(ntp); + ds.hi += ntpcal_daysec_to_date(jd, ds.lo); + + return ntpcal_rd_to_date(jd, ds.hi + DAY_NTP_STARTS); +} + +int +ntpcal_ntp_to_date( + struct calendar *jd, + uint32_t ntp, + const time_t *piv + ) +{ + vint64 ntp64; + + /* + * Unfold ntp time around current time into NTP domain. Split + * into days and seconds, shift days into CE domain and + * process the parts. + */ + ntp64 = ntpcal_ntp_to_ntp(ntp, piv); + return ntpcal_ntp64_to_date(jd, &ntp64); +} + + +vint64 +ntpcal_date_to_ntp64( + const struct calendar *jd + ) +{ + /* + * Convert date to NTP. Ignore yearday, use d/m/y only. + */ + return ntpcal_dayjoin(ntpcal_date_to_rd(jd) - DAY_NTP_STARTS, + ntpcal_date_to_daysec(jd)); +} + + +uint32_t +ntpcal_date_to_ntp( + const struct calendar *jd + ) +{ + /* + * Get lower half of 64-bit NTP timestamp from date/time. + */ + return ntpcal_date_to_ntp64(jd).d_s.lo; +} + + + +/* + * ================================================================== + * + * day-of-week calculations + * + * ================================================================== + */ +/* + * Given a RataDie and a day-of-week, calculate a RDN that is reater-than, + * greater-or equal, closest, less-or-equal or less-than the given RDN + * and denotes the given day-of-week + */ +int32_t +ntpcal_weekday_gt( + int32_t rdn, + int32_t dow + ) +{ + return ntpcal_periodic_extend(rdn+1, dow, 7); +} + +int32_t +ntpcal_weekday_ge( + int32_t rdn, + int32_t dow + ) +{ + return ntpcal_periodic_extend(rdn, dow, 7); +} + +int32_t +ntpcal_weekday_close( + int32_t rdn, + int32_t dow + ) +{ + return ntpcal_periodic_extend(rdn-3, dow, 7); +} + +int32_t +ntpcal_weekday_le( + int32_t rdn, + int32_t dow + ) +{ + return ntpcal_periodic_extend(rdn, dow, -7); +} + +int32_t +ntpcal_weekday_lt( + int32_t rdn, + int32_t dow + ) +{ + return ntpcal_periodic_extend(rdn-1, dow, -7); +} + +/* + * ================================================================== + * + * ISO week-calendar conversions + * + * The ISO8601 calendar defines a calendar of years, weeks and weekdays. + * It is related to the Gregorian calendar, and a ISO year starts at the + * Monday closest to Jan,1st of the corresponding Gregorian year. A ISO + * calendar year has always 52 or 53 weeks, and like the Grogrian + * calendar the ISO8601 calendar repeats itself every 400 years, or + * 146097 days, or 20871 weeks. + * + * While it is possible to write ISO calendar functions based on the + * Gregorian calendar functions, the following implementation takes a + * different approach, based directly on years and weeks. + * + * Analysis of the tabulated data shows that it is not possible to + * interpolate from years to weeks over a full 400 year range; cyclic + * shifts over 400 years do not provide a solution here. But it *is* + * possible to interpolate over every single century of the 400-year + * cycle. (The centennial leap year rule seems to be the culprit here.) + * + * It can be shown that a conversion from years to weeks can be done + * using a linear transformation of the form + * + * w = floor( y * a + b ) + * + * where the slope a must hold to + * + * 52.1780821918 <= a < 52.1791044776 + * + * and b must be chosen according to the selected slope and the number + * of the century in a 400-year period. + * + * The inverse calculation can also be done in this way. Careful scaling + * provides an unlimited set of integer coefficients a,k,b that enable + * us to write the calulation in the form + * + * w = (y * a + b ) / k + * y = (w * a' + b') / k' + * + * In this implementation the values of k and k' are chosen to be + * smallest possible powers of two, so the division can be implemented + * as shifts if the optimiser chooses to do so. + * + * ================================================================== + */ + +/* + * Given a number of elapsed (ISO-)years since the begin of the + * christian era, return the number of elapsed weeks corresponding to + * the number of years. + */ +int32_t +isocal_weeks_in_years( + int32_t years + ) +{ + /* + * use: w = (y * 53431 + b[c]) / 1024 as interpolation + */ + static const uint16_t bctab[4] = { 157, 449, 597, 889 }; + + int32_t cs, cw; + uint32_t cc, ci, yu, sflag; + + sflag = int32_sflag(years); + yu = int32_to_uint32_2cpl(years); + + /* split off centuries, using floor division */ + cc = sflag ^ ((sflag ^ yu) / 100u); + yu -= cc * 100u; + + /* calculate century cycles shift and cycle index: + * Assuming a century is 5217 weeks, we have to add a cycle + * shift that is 3 for every 4 centuries, because 3 of the four + * centuries have 5218 weeks. So '(cc*3 + 1) / 4' is the actual + * correction, and the second century is the defective one. + * + * Needs floor division by 4, which is done with masking and + * shifting. + */ + ci = cc * 3u + 1; + cs = uint32_2cpl_to_int32(sflag ^ ((sflag ^ ci) / 4u)); + ci = ci % 4u; + + /* Get weeks in century. Can use plain division here as all ops + * are >= 0, and let the compiler sort out the possible + * optimisations. + */ + cw = (yu * 53431u + bctab[ci]) / 1024u; + + return uint32_2cpl_to_int32(cc) * 5217 + cs + cw; +} + +/* + * Given a number of elapsed weeks since the begin of the christian + * era, split this number into the number of elapsed years in res.hi + * and the excessive number of weeks in res.lo. (That is, res.lo is + * the number of elapsed weeks in the remaining partial year.) + */ +ntpcal_split +isocal_split_eraweeks( + int32_t weeks + ) +{ + /* + * use: y = (w * 157 + b[c]) / 8192 as interpolation + */ + + static const uint16_t bctab[4] = { 85, 130, 17, 62 }; + + ntpcal_split res; + int32_t cc, ci; + uint32_t sw, cy, Q, sflag; + + /* Use two fast cycle-split divisions here. This is again + * susceptible to internal overflow, so we check the range. This + * still permits more than +/-20 million years, so this is + * likely a pure academical problem. + * + * We want to execute '(weeks * 4 + 2) /% 20871' under floor + * division rules in the first step. + */ + sflag = int32_sflag(weeks); + sw = uint32_saturate(int32_to_uint32_2cpl(weeks), sflag); + sw = 4u * sw + 2; + Q = sflag ^ ((sflag ^ sw) / GREGORIAN_CYCLE_WEEKS); + sw -= Q * GREGORIAN_CYCLE_WEEKS; + ci = Q % 4u; + cc = uint32_2cpl_to_int32(Q); + + /* Split off years; sw >= 0 here! The scaled weeks in the years + * are scaled up by 157 afterwards. + */ + sw = (sw / 4u) * 157u + bctab[ci]; + cy = sw / 8192u; /* ws >> 13 , let the compiler sort it out */ + sw = sw % 8192u; /* ws & 8191, let the compiler sort it out */ + + /* assemble elapsed years and downscale the elapsed weeks in + * the year. + */ + res.hi = 100*cc + cy; + res.lo = sw / 157u; + + return res; +} + +/* + * Given a second in the NTP time scale and a pivot, expand the NTP + * time stamp around the pivot and convert into an ISO calendar time + * stamp. + */ +int +isocal_ntp64_to_date( + struct isodate *id, + const vint64 *ntp + ) +{ + ntpcal_split ds; + int32_t ts[3]; + uint32_t uw, ud, sflag; + + /* + * Split NTP time into days and seconds, shift days into CE + * domain and process the parts. + */ + ds = ntpcal_daysplit(ntp); + + /* split time part */ + ds.hi += priv_timesplit(ts, ds.lo); + id->hour = (uint8_t)ts[0]; + id->minute = (uint8_t)ts[1]; + id->second = (uint8_t)ts[2]; + + /* split days into days and weeks, using floor division in unsigned */ + ds.hi += DAY_NTP_STARTS - 1; /* shift from NTP to RDN */ + sflag = int32_sflag(ds.hi); + ud = int32_to_uint32_2cpl(ds.hi); + uw = sflag ^ ((sflag ^ ud) / DAYSPERWEEK); + ud -= uw * DAYSPERWEEK; + ds.hi = uint32_2cpl_to_int32(uw); + ds.lo = ud; + + id->weekday = (uint8_t)ds.lo + 1; /* weekday result */ + + /* get year and week in year */ + ds = isocal_split_eraweeks(ds.hi); /* elapsed years&week*/ + id->year = (uint16_t)ds.hi + 1; /* shift to current */ + id->week = (uint8_t )ds.lo + 1; + + return (ds.hi >= 0 && ds.hi < 0x0000FFFF); +} + +int +isocal_ntp_to_date( + struct isodate *id, + uint32_t ntp, + const time_t *piv + ) +{ + vint64 ntp64; + + /* + * Unfold ntp time around current time into NTP domain, then + * convert the full time stamp. + */ + ntp64 = ntpcal_ntp_to_ntp(ntp, piv); + return isocal_ntp64_to_date(id, &ntp64); +} + +/* + * Convert a ISO date spec into a second in the NTP time scale, + * properly truncated to 32 bit. + */ +vint64 +isocal_date_to_ntp64( + const struct isodate *id + ) +{ + int32_t weeks, days, secs; + + weeks = isocal_weeks_in_years((int32_t)id->year - 1) + + (int32_t)id->week - 1; + days = weeks * 7 + (int32_t)id->weekday; + /* days is RDN of ISO date now */ + secs = ntpcal_etime_to_seconds(id->hour, id->minute, id->second); + + return ntpcal_dayjoin(days - DAY_NTP_STARTS, secs); +} + +uint32_t +isocal_date_to_ntp( + const struct isodate *id + ) +{ + /* + * Get lower half of 64-bit NTP timestamp from date/time. + */ + return isocal_date_to_ntp64(id).d_s.lo; +} + +/* -*-EOF-*- */ diff --git a/contrib/ntp/libntp/ntp_crypto_rnd.c b/contrib/ntp/libntp/ntp_crypto_rnd.c new file mode 100644 index 000000000..96348f2e8 --- /dev/null +++ b/contrib/ntp/libntp/ntp_crypto_rnd.c @@ -0,0 +1,113 @@ +/* + * Crypto-quality random number functions + * + * Author: Harlan Stenn, 2014 + * + * This file is Copyright (c) 2014 by Network Time Foundation. + * BSD terms apply: see the file COPYRIGHT in the distribution root for details. + */ + +#include "config.h" +#include +#ifdef HAVE_UNISTD_H +# include +#endif +#include + +#include +#include + +#ifdef USE_OPENSSL_CRYPTO_RAND +#include +#include + +int crypto_rand_init = 0; +#else + +# ifndef HAVE_ARC4RANDOM_BUF +static void +arc4random_buf(void *buf, size_t nbytes); + +void +evutil_secure_rng_get_bytes(void *buf, size_t nbytes); + +static void +arc4random_buf(void *buf, size_t nbytes) +{ + evutil_secure_rng_get_bytes(buf, nbytes); + return; +} +# endif +#endif + +/* + * As of late 2014, here's how we plan to provide cryptographic-quality + * random numbers: + * + * - If we are building with OpenSSL, use RAND_poll() and RAND_bytes(). + * - Otherwise, use arc4random(). + * + * Use of arc4random() can be forced using configure --disable-openssl-random + * + * We can count on arc4random existing, thru the OS or thru libevent. + * The quality of arc4random depends on the implementor. + * + * RAND_poll() doesn't show up until XXX. If it's not present, we + * need to either provide our own or use arc4random(). + */ + +/* + * ntp_crypto_srandom: + * + * Initialize the random number generator, if needed by the underlying + * crypto random number generation mechanism. + */ + +void +ntp_crypto_srandom( + void + ) +{ +#ifdef USE_OPENSSL_CRYPTO_RAND + if (!crypto_rand_init) { + RAND_poll(); + crypto_rand_init = 1; + } +#else + /* No initialization needed for arc4random() */ +#endif +} + + +/* + * ntp_crypto_random_buf: + * + * Returns 0 on success, -1 on error. + */ +int +ntp_crypto_random_buf( + void *buf, + size_t nbytes + ) +{ +#ifdef USE_OPENSSL_CRYPTO_RAND + int rc; + + rc = RAND_bytes(buf, nbytes); + if (1 != rc) { + unsigned long err; + char *err_str; + + err = ERR_get_error(); + err_str = ERR_error_string(err, NULL); + /* XXX: Log the error */ + (void)&err_str; + + return -1; + } + return 0; +#else + arc4random_buf(buf, nbytes); + return 0; +#endif +} diff --git a/contrib/ntp/libntp/ntp_intres.c b/contrib/ntp/libntp/ntp_intres.c new file mode 100644 index 000000000..b0f562036 --- /dev/null +++ b/contrib/ntp/libntp/ntp_intres.c @@ -0,0 +1,1128 @@ +/* + * ntp_intres.c - Implements a generic blocking worker child or thread, + * initially to provide a nonblocking solution for DNS + * name to address lookups available with getaddrinfo(). + * + * This is a new implementation as of 2009 sharing the filename and + * very little else with the prior implementation, which used a + * temporary file to receive a single set of requests from the parent, + * and a NTP mode 7 authenticated request to push back responses. + * + * A primary goal in rewriting this code was the need to support the + * pool configuration directive's requirement to retrieve multiple + * addresses resolving a single name, which has previously been + * satisfied with blocking resolver calls from the ntpd mainline code. + * + * A secondary goal is to provide a generic mechanism for other + * blocking operations to be delegated to a worker using a common + * model for both Unix and Windows ntpd. ntp_worker.c, work_fork.c, + * and work_thread.c implement the generic mechanism. This file + * implements the two current consumers, getaddrinfo_sometime() and the + * presently unused getnameinfo_sometime(). + * + * Both routines deliver results to a callback and manage memory + * allocation, meaning there is no freeaddrinfo_sometime(). + * + * The initial implementation for Unix uses a pair of unidirectional + * pipes, one each for requests and responses, connecting the forked + * blocking child worker with the ntpd mainline. The threaded code + * uses arrays of pointers to queue requests and responses. + * + * The parent drives the process, including scheduling sleeps between + * retries. + * + * Memory is managed differently for a child process, which mallocs + * request buffers to read from the pipe into, whereas the threaded + * code mallocs a copy of the request to hand off to the worker via + * the queueing array. The resulting request buffer is free()d by + * platform-independent code. A wrinkle is the request needs to be + * available to the requestor during response processing. + * + * Response memory allocation is also platform-dependent. With a + * separate process and pipes, the response is free()d after being + * written to the pipe. With threads, the same memory is handed + * over and the requestor frees it after processing is completed. + * + * The code should be generalized to support threads on Unix using + * much of the same code used for Windows initially. + * + */ +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "ntp_workimpl.h" + +#ifdef WORKER + +#include +#include +#include + +/**/ +#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_NETINET_IN_H +#include +#endif +#include +/**/ +#ifdef HAVE_SYS_PARAM_H +# include +#endif + +#if !defined(HAVE_RES_INIT) && defined(HAVE___RES_INIT) +# define HAVE_RES_INIT +#endif + +#if defined(HAVE_RESOLV_H) && defined(HAVE_RES_INIT) +# ifdef HAVE_ARPA_NAMESER_H +# include /* DNS HEADER struct */ +# endif +# ifdef HAVE_NETDB_H +# include +# endif +# include +# ifdef HAVE_INT32_ONLY_WITH_DNS +# define HAVE_INT32 +# endif +# ifdef HAVE_U_INT32_ONLY_WITH_DNS +# define HAVE_U_INT32 +# endif +#endif + +#include "ntp.h" +#include "ntp_debug.h" +#include "ntp_malloc.h" +#include "ntp_syslog.h" +#include "ntp_unixtime.h" +#include "ntp_intres.h" +#include "intreswork.h" + + +/* + * Following are implementations of getaddrinfo_sometime() and + * getnameinfo_sometime(). Each is implemented in three routines: + * + * getaddrinfo_sometime() getnameinfo_sometime() + * blocking_getaddrinfo() blocking_getnameinfo() + * getaddrinfo_sometime_complete() getnameinfo_sometime_complete() + * + * The first runs in the parent and marshalls (or serializes) request + * parameters into a request blob which is processed in the child by + * the second routine, blocking_*(), which serializes the results into + * a response blob unpacked by the third routine, *_complete(), which + * calls the callback routine provided with the request and frees + * _request_ memory allocated by the first routine. Response memory + * is managed by the code which calls the *_complete routines. + */ + +/* === typedefs === */ +typedef struct blocking_gai_req_tag { /* marshalled args */ + size_t octets; + u_int dns_idx; + time_t scheduled; + time_t earliest; + struct addrinfo hints; + int retry; + gai_sometime_callback callback; + void * context; + size_t nodesize; + size_t servsize; +} blocking_gai_req; + +typedef struct blocking_gai_resp_tag { + size_t octets; + int retcode; + int retry; + int gai_errno; /* for EAI_SYSTEM case */ + int ai_count; + /* + * Followed by ai_count struct addrinfo and then ai_count + * sockaddr_u and finally the canonical name strings. + */ +} blocking_gai_resp; + +typedef struct blocking_gni_req_tag { + size_t octets; + u_int dns_idx; + time_t scheduled; + time_t earliest; + int retry; + size_t hostoctets; + size_t servoctets; + int flags; + gni_sometime_callback callback; + void * context; + sockaddr_u socku; +} blocking_gni_req; + +typedef struct blocking_gni_resp_tag { + size_t octets; + int retcode; + int gni_errno; /* for EAI_SYSTEM case */ + int retry; + size_t hostoctets; + size_t servoctets; + /* + * Followed by hostoctets bytes of null-terminated host, + * then servoctets bytes of null-terminated service. + */ +} blocking_gni_resp; + +/* per-DNS-worker state in parent */ +typedef struct dnschild_ctx_tag { + u_int index; + time_t next_dns_timeslot; +} dnschild_ctx; + +/* per-DNS-worker state in worker */ +typedef struct dnsworker_ctx_tag { + blocking_child * c; + time_t ignore_scheduled_before; +#ifdef HAVE_RES_INIT + time_t next_res_init; +#endif +} dnsworker_ctx; + + +/* === variables === */ +dnschild_ctx ** dnschild_contexts; /* parent */ +u_int dnschild_contexts_alloc; +dnsworker_ctx ** dnsworker_contexts; /* child */ +u_int dnsworker_contexts_alloc; + +#ifdef HAVE_RES_INIT +static time_t next_res_init; +#endif + + +/* === forward declarations === */ +static u_int reserve_dnschild_ctx(void); +static u_int get_dnschild_ctx(void); +static void alloc_dnsworker_context(u_int); +/* static void free_dnsworker_context(u_int); */ +static dnsworker_ctx * get_worker_context(blocking_child *, u_int); +static void scheduled_sleep(time_t, time_t, + dnsworker_ctx *); +static void manage_dns_retry_interval(time_t *, time_t *, + int *, + time_t *); +static int should_retry_dns(int, int); +#ifdef HAVE_RES_INIT +static void reload_resolv_conf(dnsworker_ctx *); +#else +# define reload_resolv_conf(wc) \ + do { \ + (void)(wc); \ + } while (FALSE) +#endif +static void getaddrinfo_sometime_complete(blocking_work_req, + void *, size_t, + void *); +static void getnameinfo_sometime_complete(blocking_work_req, + void *, size_t, + void *); + + +/* === functions === */ +/* + * getaddrinfo_sometime - uses blocking child to call getaddrinfo then + * invokes provided callback completion function. + */ +int +getaddrinfo_sometime( + const char * node, + const char * service, + const struct addrinfo * hints, + int retry, + gai_sometime_callback callback, + void * context + ) +{ + blocking_gai_req * gai_req; + u_int idx; + dnschild_ctx * child_ctx; + size_t req_size; + size_t nodesize; + size_t servsize; + time_t now; + + REQUIRE(NULL != node); + if (NULL != hints) { + REQUIRE(0 == hints->ai_addrlen); + REQUIRE(NULL == hints->ai_addr); + REQUIRE(NULL == hints->ai_canonname); + REQUIRE(NULL == hints->ai_next); + } + + idx = get_dnschild_ctx(); + child_ctx = dnschild_contexts[idx]; + + nodesize = strlen(node) + 1; + servsize = strlen(service) + 1; + req_size = sizeof(*gai_req) + nodesize + servsize; + + gai_req = emalloc_zero(req_size); + + gai_req->octets = req_size; + gai_req->dns_idx = idx; + now = time(NULL); + gai_req->scheduled = now; + gai_req->earliest = max(now, child_ctx->next_dns_timeslot); + child_ctx->next_dns_timeslot = gai_req->earliest; + if (hints != NULL) + gai_req->hints = *hints; + gai_req->retry = retry; + gai_req->callback = callback; + gai_req->context = context; + gai_req->nodesize = nodesize; + gai_req->servsize = servsize; + + memcpy((char *)gai_req + sizeof(*gai_req), node, nodesize); + memcpy((char *)gai_req + sizeof(*gai_req) + nodesize, service, + servsize); + + if (queue_blocking_request( + BLOCKING_GETADDRINFO, + gai_req, + req_size, + &getaddrinfo_sometime_complete, + gai_req)) { + + msyslog(LOG_ERR, "unable to queue getaddrinfo request"); + errno = EFAULT; + return -1; + } + + return 0; +} + +int +blocking_getaddrinfo( + blocking_child * c, + blocking_pipe_header * req + ) +{ + blocking_gai_req * gai_req; + dnsworker_ctx * worker_ctx; + blocking_pipe_header * resp; + blocking_gai_resp * gai_resp; + char * node; + char * service; + struct addrinfo * ai_res; + struct addrinfo * ai; + struct addrinfo * serialized_ai; + size_t canons_octets; + size_t this_octets; + size_t resp_octets; + char * cp; + time_t time_now; + + gai_req = (void *)((char *)req + sizeof(*req)); + node = (char *)gai_req + sizeof(*gai_req); + service = node + gai_req->nodesize; + + worker_ctx = get_worker_context(c, gai_req->dns_idx); + scheduled_sleep(gai_req->scheduled, gai_req->earliest, + worker_ctx); + reload_resolv_conf(worker_ctx); + + /* + * Take a shot at the final size, better to overestimate + * at first and then realloc to a smaller size. + */ + + resp_octets = sizeof(*resp) + sizeof(*gai_resp) + + 16 * (sizeof(struct addrinfo) + + sizeof(sockaddr_u)) + + 256; + resp = emalloc_zero(resp_octets); + gai_resp = (void *)(resp + 1); + + TRACE(2, ("blocking_getaddrinfo given node %s serv %s fam %d flags %x\n", + node, service, gai_req->hints.ai_family, + gai_req->hints.ai_flags)); +#ifdef DEBUG + if (debug >= 2) + fflush(stdout); +#endif + ai_res = NULL; + gai_resp->retcode = getaddrinfo(node, service, &gai_req->hints, + &ai_res); + gai_resp->retry = gai_req->retry; +#ifdef EAI_SYSTEM + if (EAI_SYSTEM == gai_resp->retcode) + gai_resp->gai_errno = errno; +#endif + canons_octets = 0; + + if (0 == gai_resp->retcode) { + ai = ai_res; + while (NULL != ai) { + gai_resp->ai_count++; + if (ai->ai_canonname) + canons_octets += strlen(ai->ai_canonname) + 1; + ai = ai->ai_next; + } + /* + * If this query succeeded only after retrying, DNS may have + * just become responsive. Ignore previously-scheduled + * retry sleeps once for each pending request, similar to + * the way scheduled_sleep() does when its worker_sleep() + * is interrupted. + */ + if (gai_resp->retry > INITIAL_DNS_RETRY) { + time_now = time(NULL); + worker_ctx->ignore_scheduled_before = time_now; + TRACE(1, ("DNS success after retry, ignoring sleeps scheduled before now (%s)\n", + humantime(time_now))); + } + } + + /* + * Our response consists of a header, followed by ai_count + * addrinfo structs followed by ai_count sockaddr_storage + * structs followed by the canonical names. + */ + gai_resp->octets = sizeof(*gai_resp) + + gai_resp->ai_count + * (sizeof(gai_req->hints) + + sizeof(sockaddr_u)) + + canons_octets; + + resp_octets = sizeof(*resp) + gai_resp->octets; + resp = erealloc(resp, resp_octets); + gai_resp = (void *)(resp + 1); + + /* cp serves as our current pointer while serializing */ + cp = (void *)(gai_resp + 1); + canons_octets = 0; + + if (0 == gai_resp->retcode) { + ai = ai_res; + while (NULL != ai) { + memcpy(cp, ai, sizeof(*ai)); + serialized_ai = (void *)cp; + cp += sizeof(*ai); + + /* transform ai_canonname into offset */ + if (NULL != serialized_ai->ai_canonname) { + serialized_ai->ai_canonname = (char *)canons_octets; + canons_octets += strlen(ai->ai_canonname) + 1; + } + + /* leave fixup of ai_addr pointer for receiver */ + + ai = ai->ai_next; + } + + ai = ai_res; + while (NULL != ai) { + INSIST(ai->ai_addrlen <= sizeof(sockaddr_u)); + memcpy(cp, ai->ai_addr, ai->ai_addrlen); + cp += sizeof(sockaddr_u); + + ai = ai->ai_next; + } + + ai = ai_res; + while (NULL != ai) { + if (NULL != ai->ai_canonname) { + this_octets = strlen(ai->ai_canonname) + 1; + memcpy(cp, ai->ai_canonname, this_octets); + cp += this_octets; + } + + ai = ai->ai_next; + } + freeaddrinfo(ai_res); + } + + /* + * make sure our walk and earlier calc match + */ + DEBUG_INSIST((size_t)(cp - (char *)resp) == resp_octets); + + if (queue_blocking_response(c, resp, resp_octets, req)) { + msyslog(LOG_ERR, "blocking_getaddrinfo can not queue response"); + return -1; + } + + return 0; +} + + +static void +getaddrinfo_sometime_complete( + blocking_work_req rtype, + void * context, + size_t respsize, + void * resp + ) +{ + blocking_gai_req * gai_req; + blocking_gai_resp * gai_resp; + dnschild_ctx * child_ctx; + struct addrinfo * ai; + struct addrinfo * next_ai; + sockaddr_u * psau; + char * node; + char * service; + char * canon_start; + time_t time_now; + int again; + int af; + const char * fam_spec; + int i; + + gai_req = context; + gai_resp = resp; + + DEBUG_REQUIRE(BLOCKING_GETADDRINFO == rtype); + DEBUG_REQUIRE(respsize == gai_resp->octets); + + node = (char *)gai_req + sizeof(*gai_req); + service = node + gai_req->nodesize; + + child_ctx = dnschild_contexts[gai_req->dns_idx]; + + if (0 == gai_resp->retcode) { + /* + * If this query succeeded only after retrying, DNS may have + * just become responsive. + */ + if (gai_resp->retry > INITIAL_DNS_RETRY) { + time_now = time(NULL); + child_ctx->next_dns_timeslot = time_now; + TRACE(1, ("DNS success after retry, %u next_dns_timeslot reset (%s)\n", + gai_req->dns_idx, humantime(time_now))); + } + } else { + again = should_retry_dns(gai_resp->retcode, + gai_resp->gai_errno); + /* + * exponential backoff of DNS retries to 64s + */ + if (gai_req->retry > 0 && again) { + /* log the first retry only */ + if (INITIAL_DNS_RETRY == gai_req->retry) + NLOG(NLOG_SYSINFO) { + af = gai_req->hints.ai_family; + fam_spec = (AF_INET6 == af) + ? " (AAAA)" + : (AF_INET == af) + ? " (A)" + : ""; +#ifdef EAI_SYSTEM + if (EAI_SYSTEM == gai_resp->retcode) { + errno = gai_resp->gai_errno; + msyslog(LOG_INFO, + "retrying DNS %s%s: EAI_SYSTEM %d: %m", + node, fam_spec, + gai_resp->gai_errno); + } else +#endif + msyslog(LOG_INFO, + "retrying DNS %s%s: %s (%d)", + node, fam_spec, + gai_strerror(gai_resp->retcode), + gai_resp->retcode); + } + manage_dns_retry_interval(&gai_req->scheduled, + &gai_req->earliest, &gai_req->retry, + &child_ctx->next_dns_timeslot); + if (!queue_blocking_request( + BLOCKING_GETADDRINFO, + gai_req, + gai_req->octets, + &getaddrinfo_sometime_complete, + gai_req)) + return; + else + msyslog(LOG_ERR, + "unable to retry hostname %s", + node); + } + } + + /* + * fixup pointers in returned addrinfo array + */ + ai = (void *)((char *)gai_resp + sizeof(*gai_resp)); + next_ai = NULL; + for (i = gai_resp->ai_count - 1; i >= 0; i--) { + ai[i].ai_next = next_ai; + next_ai = &ai[i]; + } + + psau = (void *)((char *)ai + gai_resp->ai_count * sizeof(*ai)); + canon_start = (char *)psau + gai_resp->ai_count * sizeof(*psau); + + for (i = 0; i < gai_resp->ai_count; i++) { + if (NULL != ai[i].ai_addr) + ai[i].ai_addr = &psau->sa; + psau++; + if (NULL != ai[i].ai_canonname) + ai[i].ai_canonname += (size_t)canon_start; + } + + ENSURE((char *)psau == canon_start); + + if (!gai_resp->ai_count) + ai = NULL; + + (*gai_req->callback)(gai_resp->retcode, gai_resp->gai_errno, + gai_req->context, node, service, + &gai_req->hints, ai); + + free(gai_req); + /* gai_resp is part of block freed by process_blocking_resp() */ +} + + +#ifdef TEST_BLOCKING_WORKER +void gai_test_callback(int rescode, int gai_errno, void *context, const char *name, const char *service, const struct addrinfo *hints, const struct addrinfo *ai_res) +{ + sockaddr_u addr; + + if (rescode) { + TRACE(1, ("gai_test_callback context %p error rescode %d %s serv %s\n", + context, rescode, name, service)); + return; + } + while (!rescode && NULL != ai_res) { + ZERO_SOCK(&addr); + memcpy(&addr, ai_res->ai_addr, ai_res->ai_addrlen); + TRACE(1, ("ctx %p fam %d addr %s canon '%s' type %s at %p ai_addr %p ai_next %p\n", + context, + AF(&addr), + stoa(&addr), + (ai_res->ai_canonname) + ? ai_res->ai_canonname + : "", + (SOCK_DGRAM == ai_res->ai_socktype) + ? "DGRAM" + : (SOCK_STREAM == ai_res->ai_socktype) + ? "STREAM" + : "(other)", + ai_res, + ai_res->ai_addr, + ai_res->ai_next)); + + getnameinfo_sometime((sockaddr_u *)ai_res->ai_addr, 128, 32, 0, gni_test_callback, context); + + ai_res = ai_res->ai_next; + } +} +#endif /* TEST_BLOCKING_WORKER */ + + +int +getnameinfo_sometime( + sockaddr_u * psau, + size_t hostoctets, + size_t servoctets, + int flags, + gni_sometime_callback callback, + void * context + ) +{ + blocking_gni_req * gni_req; + u_int idx; + dnschild_ctx * child_ctx; + time_t time_now; + + REQUIRE(hostoctets); + REQUIRE(hostoctets + servoctets < 1024); + + idx = get_dnschild_ctx(); + child_ctx = dnschild_contexts[idx]; + + gni_req = emalloc_zero(sizeof(*gni_req)); + + gni_req->octets = sizeof(*gni_req); + gni_req->dns_idx = idx; + time_now = time(NULL); + gni_req->scheduled = time_now; + gni_req->earliest = max(time_now, child_ctx->next_dns_timeslot); + child_ctx->next_dns_timeslot = gni_req->earliest; + memcpy(&gni_req->socku, psau, SOCKLEN(psau)); + gni_req->hostoctets = hostoctets; + gni_req->servoctets = servoctets; + gni_req->flags = flags; + gni_req->retry = INITIAL_DNS_RETRY; + gni_req->callback = callback; + gni_req->context = context; + + if (queue_blocking_request( + BLOCKING_GETNAMEINFO, + gni_req, + sizeof(*gni_req), + &getnameinfo_sometime_complete, + gni_req)) { + + msyslog(LOG_ERR, "unable to queue getnameinfo request"); + errno = EFAULT; + return -1; + } + + return 0; +} + + +int +blocking_getnameinfo( + blocking_child * c, + blocking_pipe_header * req + ) +{ + blocking_gni_req * gni_req; + dnsworker_ctx * worker_ctx; + blocking_pipe_header * resp; + blocking_gni_resp * gni_resp; + size_t octets; + size_t resp_octets; + char * service; + char * cp; + int rc; + time_t time_now; + char host[1024]; + + gni_req = (void *)((char *)req + sizeof(*req)); + + octets = gni_req->hostoctets + gni_req->servoctets; + + /* + * Some alloca() implementations are fragile regarding + * large allocations. We only need room for the host + * and service names. + */ + REQUIRE(octets < sizeof(host)); + service = host + gni_req->hostoctets; + + worker_ctx = get_worker_context(c, gni_req->dns_idx); + scheduled_sleep(gni_req->scheduled, gni_req->earliest, + worker_ctx); + reload_resolv_conf(worker_ctx); + + /* + * Take a shot at the final size, better to overestimate + * then realloc to a smaller size. + */ + + resp_octets = sizeof(*resp) + sizeof(*gni_resp) + octets; + resp = emalloc_zero(resp_octets); + gni_resp = (void *)((char *)resp + sizeof(*resp)); + + TRACE(2, ("blocking_getnameinfo given addr %s flags 0x%x hostlen %lu servlen %lu\n", + stoa(&gni_req->socku), gni_req->flags, + (u_long)gni_req->hostoctets, (u_long)gni_req->servoctets)); + + gni_resp->retcode = getnameinfo(&gni_req->socku.sa, + SOCKLEN(&gni_req->socku), + host, + gni_req->hostoctets, + service, + gni_req->servoctets, + gni_req->flags); + gni_resp->retry = gni_req->retry; +#ifdef EAI_SYSTEM + if (EAI_SYSTEM == gni_resp->retcode) + gni_resp->gni_errno = errno; +#endif + + if (0 != gni_resp->retcode) { + gni_resp->hostoctets = 0; + gni_resp->servoctets = 0; + } else { + gni_resp->hostoctets = strlen(host) + 1; + gni_resp->servoctets = strlen(service) + 1; + /* + * If this query succeeded only after retrying, DNS may have + * just become responsive. Ignore previously-scheduled + * retry sleeps once for each pending request, similar to + * the way scheduled_sleep() does when its worker_sleep() + * is interrupted. + */ + if (gni_req->retry > INITIAL_DNS_RETRY) { + time_now = time(NULL); + worker_ctx->ignore_scheduled_before = time_now; + TRACE(1, ("DNS success after retrying, ignoring sleeps scheduled before now (%s)\n", + humantime(time_now))); + } + } + octets = gni_resp->hostoctets + gni_resp->servoctets; + /* + * Our response consists of a header, followed by the host and + * service strings, each null-terminated. + */ + resp_octets = sizeof(*resp) + sizeof(*gni_resp) + octets; + + resp = erealloc(resp, resp_octets); + gni_resp = (void *)(resp + 1); + + gni_resp->octets = sizeof(*gni_resp) + octets; + + /* cp serves as our current pointer while serializing */ + cp = (void *)(gni_resp + 1); + + if (0 == gni_resp->retcode) { + memcpy(cp, host, gni_resp->hostoctets); + cp += gni_resp->hostoctets; + memcpy(cp, service, gni_resp->servoctets); + cp += gni_resp->servoctets; + } + + INSIST((size_t)(cp - (char *)resp) == resp_octets); + INSIST(resp_octets - sizeof(*resp) == gni_resp->octets); + + rc = queue_blocking_response(c, resp, resp_octets, req); + if (rc) + msyslog(LOG_ERR, "blocking_getnameinfo unable to queue response"); + return rc; +} + + +static void +getnameinfo_sometime_complete( + blocking_work_req rtype, + void * context, + size_t respsize, + void * resp + ) +{ + blocking_gni_req * gni_req; + blocking_gni_resp * gni_resp; + dnschild_ctx * child_ctx; + char * host; + char * service; + time_t time_now; + int again; + + gni_req = context; + gni_resp = resp; + + DEBUG_REQUIRE(BLOCKING_GETNAMEINFO == rtype); + DEBUG_REQUIRE(respsize == gni_resp->octets); + + child_ctx = dnschild_contexts[gni_req->dns_idx]; + + if (0 == gni_resp->retcode) { + /* + * If this query succeeded only after retrying, DNS may have + * just become responsive. + */ + if (gni_resp->retry > INITIAL_DNS_RETRY) { + time_now = time(NULL); + child_ctx->next_dns_timeslot = time_now; + TRACE(1, ("DNS success after retry, %u next_dns_timeslot reset (%s)\n", + gni_req->dns_idx, humantime(time_now))); + } + } else { + again = should_retry_dns(gni_resp->retcode, gni_resp->gni_errno); + /* + * exponential backoff of DNS retries to 64s + */ + if (gni_req->retry > 0) + manage_dns_retry_interval(&gni_req->scheduled, + &gni_req->earliest, &gni_req->retry, + &child_ctx->next_dns_timeslot); + + if (gni_req->retry > 0 && again) { + if (!queue_blocking_request( + BLOCKING_GETNAMEINFO, + gni_req, + gni_req->octets, + &getnameinfo_sometime_complete, + gni_req)) + return; + + msyslog(LOG_ERR, "unable to retry reverse lookup of %s", stoa(&gni_req->socku)); + } + } + + if (!gni_resp->hostoctets) { + host = NULL; + service = NULL; + } else { + host = (char *)gni_resp + sizeof(*gni_resp); + service = (gni_resp->servoctets) + ? host + gni_resp->hostoctets + : NULL; + } + + (*gni_req->callback)(gni_resp->retcode, gni_resp->gni_errno, + &gni_req->socku, gni_req->flags, host, + service, gni_req->context); + + free(gni_req); + /* gni_resp is part of block freed by process_blocking_resp() */ +} + + +#ifdef TEST_BLOCKING_WORKER +void gni_test_callback(int rescode, int gni_errno, sockaddr_u *psau, int flags, const char *host, const char *service, void *context) +{ + if (!rescode) + TRACE(1, ("gni_test_callback got host '%s' serv '%s' for addr %s context %p\n", + host, service, stoa(psau), context)); + else + TRACE(1, ("gni_test_callback context %p rescode %d gni_errno %d flags 0x%x addr %s\n", + context, rescode, gni_errno, flags, stoa(psau))); +} +#endif /* TEST_BLOCKING_WORKER */ + + +#ifdef HAVE_RES_INIT +static void +reload_resolv_conf( + dnsworker_ctx * worker_ctx + ) +{ + time_t time_now; + + /* + * This is ad-hoc. Reload /etc/resolv.conf once per minute + * to pick up on changes from the DHCP client. [Bug 1226] + * When using threads for the workers, this needs to happen + * only once per minute process-wide. + */ + time_now = time(NULL); +# ifdef WORK_THREAD + worker_ctx->next_res_init = next_res_init; +# endif + if (worker_ctx->next_res_init <= time_now) { + if (worker_ctx->next_res_init != 0) + res_init(); + worker_ctx->next_res_init = time_now + 60; +# ifdef WORK_THREAD + next_res_init = worker_ctx->next_res_init; +# endif + } +} +#endif /* HAVE_RES_INIT */ + + +static u_int +reserve_dnschild_ctx(void) +{ + const size_t ps = sizeof(dnschild_contexts[0]); + const size_t cs = sizeof(*dnschild_contexts[0]); + u_int c; + u_int new_alloc; + size_t octets; + size_t new_octets; + + c = 0; + while (TRUE) { + for ( ; c < dnschild_contexts_alloc; c++) { + if (NULL == dnschild_contexts[c]) { + dnschild_contexts[c] = emalloc_zero(cs); + + return c; + } + } + new_alloc = dnschild_contexts_alloc + 20; + new_octets = new_alloc * ps; + octets = dnschild_contexts_alloc * ps; + dnschild_contexts = erealloc_zero(dnschild_contexts, + new_octets, octets); + dnschild_contexts_alloc = new_alloc; + } +} + + +static u_int +get_dnschild_ctx(void) +{ + static u_int shared_ctx = UINT_MAX; + + if (worker_per_query) + return reserve_dnschild_ctx(); + + if (UINT_MAX == shared_ctx) + shared_ctx = reserve_dnschild_ctx(); + + return shared_ctx; +} + + +static void +alloc_dnsworker_context( + u_int idx + ) +{ + const size_t worker_context_sz = sizeof(*dnsworker_contexts[0]); + + REQUIRE(NULL == dnsworker_contexts[idx]); + dnsworker_contexts[idx] = emalloc_zero(worker_context_sz); +} + + +static dnsworker_ctx * +get_worker_context( + blocking_child * c, + u_int idx + ) +{ + static size_t ps = sizeof(dnsworker_contexts[0]); + u_int min_new_alloc; + u_int new_alloc; + size_t octets; + size_t new_octets; + + if (dnsworker_contexts_alloc <= idx) { + min_new_alloc = 1 + idx; + /* round new_alloc up to nearest multiple of 4 */ + new_alloc = (min_new_alloc + 4) & ~(4 - 1); + new_octets = new_alloc * ps; + octets = dnsworker_contexts_alloc * ps; + dnsworker_contexts = erealloc_zero(dnsworker_contexts, + new_octets, octets); + dnsworker_contexts_alloc = new_alloc; + } + + if (NULL == dnsworker_contexts[idx]) + alloc_dnsworker_context(idx); + ZERO(*dnsworker_contexts[idx]); + dnsworker_contexts[idx]->c = c; + + return dnsworker_contexts[idx]; +} + + +static void +scheduled_sleep( + time_t scheduled, + time_t earliest, + dnsworker_ctx * worker_ctx + ) +{ + time_t now; + + if (scheduled < worker_ctx->ignore_scheduled_before) { + TRACE(1, ("ignoring sleep until %s scheduled at %s (before %s)\n", + humantime(earliest), humantime(scheduled), + humantime(worker_ctx->ignore_scheduled_before))); + return; + } + + now = time(NULL); + + if (now < earliest) { + TRACE(1, ("sleep until %s scheduled at %s (>= %s)\n", + humantime(earliest), humantime(scheduled), + humantime(worker_ctx->ignore_scheduled_before))); + if (-1 == worker_sleep(worker_ctx->c, earliest - now)) { + /* our sleep was interrupted */ + now = time(NULL); + worker_ctx->ignore_scheduled_before = now; +#ifdef HAVE_RES_INIT + worker_ctx->next_res_init = now + 60; + next_res_init = worker_ctx->next_res_init; + res_init(); +#endif + TRACE(1, ("sleep interrupted by daemon, ignoring sleeps scheduled before now (%s)\n", + humantime(worker_ctx->ignore_scheduled_before))); + } + } +} + + +/* + * manage_dns_retry_interval is a helper used by + * getaddrinfo_sometime_complete and getnameinfo_sometime_complete + * to calculate the new retry interval and schedule the next query. + */ +static void +manage_dns_retry_interval( + time_t * pscheduled, + time_t * pwhen, + int * pretry, + time_t * pnext_timeslot + ) +{ + time_t now; + time_t when; + int retry; + + now = time(NULL); + retry = *pretry; + when = max(now + retry, *pnext_timeslot); + *pnext_timeslot = when; + retry = min(64, retry << 1); + + *pscheduled = now; + *pwhen = when; + *pretry = retry; +} + +/* + * should_retry_dns is a helper used by getaddrinfo_sometime_complete + * and getnameinfo_sometime_complete which implements ntpd's DNS retry + * policy. + */ +static int +should_retry_dns( + int rescode, + int res_errno + ) +{ + static int eai_again_seen; + int again; +#if defined (EAI_SYSTEM) && defined(DEBUG) + char msg[256]; +#endif + + /* + * If the resolver failed, see if the failure is + * temporary. If so, return success. + */ + again = 0; + + switch (rescode) { + + case EAI_FAIL: + again = 1; + break; + + case EAI_AGAIN: + again = 1; + eai_again_seen = 1; /* [Bug 1178] */ + break; + + case EAI_NONAME: +#if defined(EAI_NODATA) && (EAI_NODATA != EAI_NONAME) + case EAI_NODATA: +#endif + again = !eai_again_seen; /* [Bug 1178] */ + break; + +#ifdef EAI_SYSTEM + case EAI_SYSTEM: + /* + * EAI_SYSTEM means the real error is in errno. We should be more + * discriminating about which errno values require retrying, but + * this matches existing behavior. + */ + again = 1; +# ifdef DEBUG + errno_to_str(res_errno, msg, sizeof(msg)); + TRACE(1, ("intres: EAI_SYSTEM errno %d (%s) means try again, right?\n", + res_errno, msg)); +# endif + break; +#endif + } + + TRACE(2, ("intres: resolver returned: %s (%d), %sretrying\n", + gai_strerror(rescode), rescode, again ? "" : "not ")); + + return again; +} + +#else /* !WORKER follows */ +int ntp_intres_nonempty_compilation_unit; +#endif diff --git a/contrib/ntp/libntp/ntp_libopts.c b/contrib/ntp/libntp/ntp_libopts.c new file mode 100644 index 000000000..c504f8bf1 --- /dev/null +++ b/contrib/ntp/libntp/ntp_libopts.c @@ -0,0 +1,58 @@ +/* + * ntp_libopts.c + * + * Common code interfacing with Autogen's libopts command-line option + * processing. + */ +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include "ntp_libopts.h" +#include "ntp_stdlib.h" + +extern const char *Version; /* version.c for each program */ + + +/* + * ntpOptionProcess() was a clone of libopts' optionProcess which + * overrode the --version output, appending detail from version.c + * which was not available at Autogen time. This is now done via + * AutoOpts' version-proc = override in copyright.def, so this + * routine is a straightforward wrapper of optionProcess(). + */ +int +ntpOptionProcess( + tOptions * pOpts, + int argc, + char ** argv + ) +{ + return optionProcess(pOpts, argc, argv); +} + + +/* + * ntpOptionPrintVersion() replaces the stock optionPrintVersion() via + * version-proc = ntpOptionPrintVersion; in copyright.def. It differs + * from the stock function by displaying the complete version string, + * including compile time which was unknown when Autogen ran. + * + * Like optionPrintVersion() this function must exit(0) rather than + * return. + */ +void +ntpOptionPrintVersion( + tOptions * pOpts, + tOptDesc * pOD + ) +{ + UNUSED_ARG(pOpts); + UNUSED_ARG(pOD); + + printf("%s\n", Version); + fflush(stdout); + exit(EXIT_SUCCESS); +} diff --git a/contrib/ntp/libntp/ntp_lineedit.c b/contrib/ntp/libntp/ntp_lineedit.c new file mode 100644 index 000000000..a2b2d2934 --- /dev/null +++ b/contrib/ntp/libntp/ntp_lineedit.c @@ -0,0 +1,245 @@ +/* + * ntp_lineedit.c - generic interface to various line editing libs + */ +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include +#include + +#if defined(HAVE_READLINE_HISTORY) && \ + (!defined(HAVE_READLINE_HISTORY_H) || \ + !defined(HAVE_READLINE_READLINE_H)) +# undef HAVE_READLINE_HISTORY +#endif +#if defined(HAVE_READLINE_HISTORY) +# include +# include +# define LE_READLINE +#elif defined(HAVE_HISTEDIT_H) +# include +# define LE_EDITLINE +#else +# define LE_NONE +#endif + +#include "ntp.h" +#include "ntp_stdlib.h" +#include "ntp_lineedit.h" + +#define MAXEDITLINE 512 + +/* + * external references + */ + +extern char const * progname; + +/* + * globals, private prototypes + */ + +static int ntp_readline_initted; +static char * lineedit_prompt; + + +#ifdef LE_EDITLINE +# ifndef H_SETSIZE +# define H_SETSIZE H_EVENT +# endif +static EditLine * ntp_el; +static History * ntp_hist; +static HistEvent hev; + +char * ntp_prompt_callback(EditLine *); +#endif /* LE_EDITLINE */ + + +/* + * ntp_readline_init - setup, set or reset prompt string + */ +int +ntp_readline_init( + const char * prompt + ) +{ + int success; + + success = 1; + + if (prompt) { + if (lineedit_prompt) + free(lineedit_prompt); + lineedit_prompt = estrdup(prompt); + } + +#ifdef LE_EDITLINE + if (NULL == ntp_el) { + +# if 4 == EL_INIT_ARGS + ntp_el = el_init(progname, stdin, stdout, stderr); +# else + ntp_el = el_init(progname, stdin, stdout); +# endif + if (ntp_el) { + + el_set(ntp_el, EL_PROMPT, ntp_prompt_callback); + el_set(ntp_el, EL_EDITOR, "emacs"); + + ntp_hist = history_init(); + + if (NULL == ntp_hist) { + + mfprintf(stderr, "history_init(): %m\n"); + fflush(stderr); + + el_end(ntp_el); + ntp_el = NULL; + + success = 0; + + } else { + ZERO(hev); +#ifdef H_SETSIZE + history(ntp_hist, &hev, H_SETSIZE, 128); +#endif + el_set(ntp_el, EL_HIST, history, + ntp_hist); + /* use any .editrc */ + el_source(ntp_el, NULL); + } + } else + success = 0; + } +#endif /* LE_EDITLINE */ + + ntp_readline_initted = success; + + return success; +} + + +/* + * ntp_readline_uninit - release resources + */ +void +ntp_readline_uninit( + void + ) +{ +#ifdef LE_EDITLINE + if (ntp_el) { + el_end(ntp_el); + ntp_el = NULL; + + history_end(ntp_hist); + ntp_hist = NULL; + } +#endif /* LE_EDITLINE */ + + if (lineedit_prompt) { + free(lineedit_prompt); + lineedit_prompt = NULL; + } + + ntp_readline_initted = 0; +} + + +/* + * ntp_readline - read a line with the line editor available + * + * The string returned must be released with free() + */ + +char * +ntp_readline( + int * pcount + ) +{ + char * line; +#ifdef LE_NONE + char line_buf[MAXEDITLINE]; +#endif +#ifdef LE_EDITLINE + const char * cline; +#endif + + if (!ntp_readline_initted) + return NULL; + + *pcount = 0; + +#ifdef LE_READLINE + line = readline(lineedit_prompt ? lineedit_prompt : ""); + if (NULL != line) { + if (*line) { + add_history(line); + } + *pcount = strlen(line); + } +#endif /* LE_READLINE */ + +#ifdef LE_EDITLINE + cline = el_gets(ntp_el, pcount); + + if (NULL != cline) { + history(ntp_hist, &hev, H_ENTER, cline); + line = estrdup(cline); + } else if (*pcount == -1) { + line = NULL; + } else { + line = estrdup(""); + } +#endif /* LE_EDITLINE */ + +#ifdef LE_NONE + /* stone hammers */ + if (lineedit_prompt) { +# ifdef VMS + /* + * work around problem mixing + * stdout & stderr + */ + fputs("", stdout); +# endif /* VMS */ + + fputs(lineedit_prompt, stderr); + fflush(stderr); + } + + line = fgets(line_buf, sizeof(line_buf), stdin); + if (NULL != line && *line) { + *pcount = strlen(line); + line = estrdup(line); + } else + line = NULL; + +#endif /* LE_NONE */ + + + if (!line) /* EOF */ + fputs("\n", stderr); + + return line; +} + + +#ifdef LE_EDITLINE +/* + * ntp_prompt_callback - return prompt string to el_gets() + */ +char * +ntp_prompt_callback( + EditLine *el + ) +{ + UNUSED_ARG(el); + + return lineedit_prompt; +} +#endif /* LE_EDITLINE */ + diff --git a/contrib/ntp/libntp/ntp_random.c b/contrib/ntp/libntp/ntp_random.c index 700b4ee65..0ada44f25 100644 --- a/contrib/ntp/libntp/ntp_random.c +++ b/contrib/ntp/libntp/ntp_random.c @@ -39,15 +39,13 @@ static char sccsid[] = "@(#)random.c 8.2 (Berkeley) 5/19/95"; #endif /* LIBC_SCCS and not lint */ #include "config.h" -#ifdef HAVE_SYS_TYPES_H -# include -#endif +#include #ifdef HAVE_UNISTD_H # include #endif #include -#include +#include #include #include @@ -142,15 +140,8 @@ static char sccsid[] = "@(#)random.c 8.2 (Berkeley) 5/19/95"; #define DEG_4 63 #define SEP_4 1 -/* - * Array versions of the above information to make code run faster -- - * relies on fact that TYPE_i == i. - */ #define MAX_TYPES 5 /* max number of types above */ -static long degrees[MAX_TYPES] = { DEG_0, DEG_1, DEG_2, DEG_3, DEG_4 }; -static long seps [MAX_TYPES] = { SEP_0, SEP_1, SEP_2, SEP_3, SEP_4 }; - /* * Initially, everything is set up as if from: * @@ -165,7 +156,7 @@ static long seps [MAX_TYPES] = { SEP_0, SEP_1, SEP_2, SEP_3, SEP_4 }; * MAX_TYPES * (rptr - state) + TYPE_3 == TYPE_3. */ -static long randtbl[DEG_3 + 1] = { +static unsigned long randtbl[DEG_3 + 1] = { TYPE_3, #ifdef USE_WEAK_SEEDING /* Historic implementation compatibility */ @@ -200,8 +191,8 @@ static long randtbl[DEG_3 + 1] = { * in the initialization of randtbl) because the state table pointer is set * to point to randtbl[1] (as explained below). */ -static long *fptr = &randtbl[SEP_3 + 1]; -static long *rptr = &randtbl[1]; +static unsigned long *fptr = &randtbl[SEP_3 + 1]; +static unsigned long *rptr = &randtbl[1]; /* * The following things are the pointer to the state information table, the @@ -213,13 +204,13 @@ static long *rptr = &randtbl[1]; * this is more efficient than indexing every time to find the address of * the last element to see if the front and rear pointers have wrapped. */ -static long *state = &randtbl[1]; +static unsigned long *state = &randtbl[1]; static long rand_type = TYPE_3; static long rand_deg = DEG_3; static long rand_sep = SEP_3; -static long *end_ptr = &randtbl[DEG_3 + 1]; +static unsigned long *end_ptr = &randtbl[DEG_3 + 1]; -static inline long good_rand P((long)); +static inline long good_rand (long); static inline long good_rand ( @@ -270,19 +261,22 @@ ntp_srandom( unsigned long x ) { - register long i; + long i; - if (rand_type == TYPE_0) + if (rand_type == TYPE_0) { state[0] = x; - else { + } else { state[0] = x; for (i = 1; i < rand_deg; i++) state[i] = good_rand(state[i - 1]); fptr = &state[rand_sep]; rptr = &state[0]; for (i = 0; i < 10 * rand_deg; i++) - (void)ntp_random(); + x = ntp_random(); } + + /* seed the likely faster (and poorer) rand() as well */ + srand((u_int)x); } /* @@ -309,6 +303,24 @@ ntp_srandomdev( void ) } #endif + +/* + * ntp_initstate() and ntp_setstate() are unused in our codebase and + * trigger warnings due to casting to a more-strictly-aligned pointer + * on alignment-sensitive platforms. #ifdef them away to save noise, + * build time, and binary space, but retain the code in case we find a + * use. + */ +#ifdef COMPILE_UNUSED_FUNCTIONS +/* + * Array versions of the above information to make code run faster -- + * relies on fact that TYPE_i == i. + */ +#define MAX_TYPES 5 /* max number of types above */ + +static long degrees[MAX_TYPES] = { DEG_0, DEG_1, DEG_2, DEG_3, DEG_4 }; +static long seps [MAX_TYPES] = { SEP_0, SEP_1, SEP_2, SEP_3, SEP_4 }; + /* * initstate: * @@ -372,7 +384,7 @@ ntp_initstate( rand_deg = DEG_4; rand_sep = SEP_4; } - state = (long *) (long_arg_state + 1); /* first location */ + state = (unsigned long *) (long_arg_state + 1); /* first location */ end_ptr = &state[rand_deg]; /* must set end_ptr before srandom */ ntp_srandom(seed); if (rand_type == TYPE_0) @@ -406,7 +418,7 @@ ntp_setstate( char *arg_state /* pointer to state array */ ) { - register long *new_state = (long *) arg_state; + register unsigned long *new_state = (unsigned long *) arg_state; register long type = new_state[0] % MAX_TYPES; register long rear = new_state[0] / MAX_TYPES; char *ostate = (char *)(&state[-1]); @@ -429,7 +441,7 @@ ntp_setstate( (void)fprintf(stderr, "random: state info corrupted; not changed.\n"); } - state = (long *) (new_state + 1); + state = (new_state + 1); if (rand_type != TYPE_0) { rptr = &state[rear]; fptr = &state[(rear + rand_sep) % rand_deg]; @@ -437,6 +449,8 @@ ntp_setstate( end_ptr = &state[rand_deg]; /* set end_ptr too */ return(ostate); } +#endif /* COMPILE_UNUSED_FUNCTIONS */ + /* * random: @@ -459,7 +473,7 @@ long ntp_random( void ) { register long i; - register long *f, *r; + register unsigned long *f, *r; if (rand_type == TYPE_0) { i = state[0]; diff --git a/contrib/ntp/libntp/ntp_rfc2553.c b/contrib/ntp/libntp/ntp_rfc2553.c index 017ef832b..a9ebb4b35 100644 --- a/contrib/ntp/libntp/ntp_rfc2553.c +++ b/contrib/ntp/libntp/ntp_rfc2553.c @@ -69,7 +69,9 @@ #include #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif #include #ifdef HAVE_NETINET_IN_H #include @@ -78,8 +80,152 @@ #include "ntpd.h" #include "ntp_malloc.h" -#include "ntp_stdlib.h" #include "ntp_string.h" +#include "ntp_debug.h" + + +/* + * copy_addrinfo() - copy a single addrinfo to malloc()'d block. + * copy_addrinfo_list() - copy an addrinfo list to malloc()'d block. + * + * Copies an addrinfo list and its associated data to a contiguous block + * of storage from emalloc(). Callback routines invoked via + * getaddrinfo_sometime() have access to the resulting addrinfo list + * only until they return. This routine provides an easy way to make a + * persistent copy. Although the list provided to gai_sometime_callback + * routines is similarly contiguous, to keep this code usable in any + * context where we might want to duplicate an addrinfo list, it does + * not require the input list be contiguous. + * + * The returned list head pointer is passed to free() to release the + * entire list. + * + * In keeping with the rest of the NTP distribution, sockaddr_u is used + * in preference to struct sockaddr_storage, which is a member of the + * former union and so compatible. + * + * The rest of ntp_rfc2553.c is conditioned on ISC_PLATFORM_HAVEIPV6 + * not being defined, copy_addrinfo_*() are exceptions. + */ +struct addrinfo * copy_addrinfo_common(const struct addrinfo *, int +#ifdef EREALLOC_CALLSITE + , + const char *, int +#endif + ); + + +struct addrinfo * +copy_addrinfo_impl( + const struct addrinfo * src +#ifdef EREALLOC_CALLSITE + , + const char * caller_file, + int caller_line +#endif + ) +{ + return copy_addrinfo_common(src, TRUE +#ifdef EREALLOC_CALLSITE + , + caller_file, caller_line +#endif + ); +} + + +struct addrinfo * +copy_addrinfo_list_impl( + const struct addrinfo * src +#ifdef EREALLOC_CALLSITE + , + const char * caller_file, + int caller_line +#endif + ) +{ + return copy_addrinfo_common(src, FALSE +#ifdef EREALLOC_CALLSITE + , + caller_file, caller_line +#endif + ); +} + + +struct addrinfo * +copy_addrinfo_common( + const struct addrinfo * src, + int just_one +#ifdef EREALLOC_CALLSITE + , + const char * caller_file, + int caller_line +#endif + ) +{ + const struct addrinfo * ai_src; + const struct addrinfo * ai_nxt; + struct addrinfo * ai_cpy; + struct addrinfo * dst; + sockaddr_u * psau; + char * pcanon; + u_int elements; + size_t octets; + size_t canons_octets; + size_t str_octets; + + elements = 0; + canons_octets = 0; + + for (ai_src = src; NULL != ai_src; ai_src = ai_nxt) { + if (just_one) + ai_nxt = NULL; + else + ai_nxt = ai_src->ai_next; + ++elements; + if (NULL != ai_src->ai_canonname) + canons_octets += 1 + strlen(ai_src->ai_canonname); + } + + octets = elements * (sizeof(*ai_cpy) + sizeof(*psau)); + octets += canons_octets; + + dst = erealloczsite(NULL, octets, 0, TRUE, caller_file, + caller_line); + ai_cpy = dst; + psau = (void *)(ai_cpy + elements); + pcanon = (void *)(psau + elements); + + for (ai_src = src; NULL != ai_src; ai_src = ai_nxt) { + if (just_one) + ai_nxt = NULL; + else + ai_nxt = ai_src->ai_next; + *ai_cpy = *ai_src; + REQUIRE(ai_src->ai_addrlen <= sizeof(sockaddr_u)); + memcpy(psau, ai_src->ai_addr, ai_src->ai_addrlen); + ai_cpy->ai_addr = &psau->sa; + ++psau; + if (NULL != ai_cpy->ai_canonname) { + ai_cpy->ai_canonname = pcanon; + str_octets = 1 + strlen(ai_src->ai_canonname); + memcpy(pcanon, ai_src->ai_canonname, str_octets); + pcanon += str_octets; + } + if (NULL != ai_cpy->ai_next) { + if (just_one) + ai_cpy->ai_next = NULL; + else + ai_cpy->ai_next = ai_cpy + 1; + } + ++ai_cpy; + } + ENSURE(pcanon == ((char *)dst + octets)); + + return dst; +} + #ifndef ISC_PLATFORM_HAVEIPV6 @@ -127,8 +273,8 @@ DNSlookup_name( } #endif -static int do_nodename P((const char *nodename, struct addrinfo *ai, - const struct addrinfo *hints)); +static int do_nodename (const char *nodename, struct addrinfo *ai, + const struct addrinfo *hints); int getaddrinfo (const char *nodename, const char *servname, @@ -288,7 +434,6 @@ getnameinfo (const struct sockaddr *sa, u_int salen, char *host, size_t hostlen, char *serv, size_t servlen, int flags) { struct hostent *hp; - int namelen; if (sa->sa_family != AF_INET) return (EAI_FAMILY); @@ -301,16 +446,8 @@ getnameinfo (const struct sockaddr *sa, u_int salen, char *host, else return (EAI_FAIL); } - if (host != NULL && hostlen > 0) { - /* - * Don't exceed buffer - */ - namelen = min(strlen(hp->h_name), hostlen - 1); - if (namelen > 0) { - strncpy(host, hp->h_name, namelen); - host[namelen] = '\0'; - } - } + if (host != NULL && hostlen > 0) + strlcpy(host, hp->h_name, hostlen); return (0); } @@ -362,7 +499,7 @@ do_nodename( sockin6->sin6_addr = in6addr_any; */ } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +#ifdef ISC_PLATFORM_HAVESALEN ai->ai_addr->sa_len = SOCKLEN(ai->ai_addr); #endif @@ -428,15 +565,11 @@ do_nodename( sockin = (struct sockaddr_in *)ai->ai_addr; memcpy(&sockin->sin_addr, hp->h_addr, hp->h_length); ai->ai_addr->sa_family = hp->h_addrtype; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR +#ifdef ISC_PLATFORM_HAVESALEN ai->ai_addr->sa_len = sizeof(struct sockaddr); #endif - if (hints != NULL && hints->ai_flags & AI_CANONNAME) { - ai->ai_canonname = malloc(strlen(hp->h_name) + 1); - if (ai->ai_canonname == NULL) - return (EAI_MEMORY); - strcpy(ai->ai_canonname, hp->h_name); - } + if (hints != NULL && (hints->ai_flags & AI_CANONNAME)) + ai->ai_canonname = estrdup(hp->h_name); return (0); } diff --git a/contrib/ntp/libntp/ntp_worker.c b/contrib/ntp/libntp/ntp_worker.c new file mode 100644 index 000000000..32970da0d --- /dev/null +++ b/contrib/ntp/libntp/ntp_worker.c @@ -0,0 +1,340 @@ +/* + * ntp_worker.c + */ +#include +#include "ntp_workimpl.h" + +#ifdef WORKER + +#include +#include +#include + +#include "iosignal.h" +#include "ntp_stdlib.h" +#include "ntp_malloc.h" +#include "ntp_syslog.h" +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_assert.h" +#include "ntp_unixtime.h" +#include "intreswork.h" + + +#define CHILD_MAX_IDLE (3 * 60) /* seconds, idle worker limit */ + +blocking_child ** blocking_children; +size_t blocking_children_alloc; +int worker_per_query; /* boolean */ +int intres_req_pending; + + +#ifndef HAVE_IO_COMPLETION_PORT +/* + * pipe_socketpair() + * + * Provides an AF_UNIX socketpair on systems which have them, otherwise + * pair of unidirectional pipes. + */ +int +pipe_socketpair( + int caller_fds[2], + int * is_pipe + ) +{ + int rc; + int fds[2]; + int called_pipe; + +#ifdef HAVE_SOCKETPAIR + rc = socketpair(AF_UNIX, SOCK_STREAM, 0, &fds[0]); +#else + rc = -1; +#endif + + if (-1 == rc) { + rc = pipe(&fds[0]); + called_pipe = TRUE; + } else { + called_pipe = FALSE; + } + + if (-1 == rc) + return rc; + + caller_fds[0] = fds[0]; + caller_fds[1] = fds[1]; + if (is_pipe != NULL) + *is_pipe = called_pipe; + + return 0; +} + + +/* + * close_all_except() + * + * Close all file descriptors except the given keep_fd. + */ +void +close_all_except( + int keep_fd + ) +{ + int fd; + + for (fd = 0; fd < keep_fd; fd++) + close(fd); + + close_all_beyond(keep_fd); +} + + +/* + * close_all_beyond() + * + * Close all file descriptors after the given keep_fd, which is the + * highest fd to keep open. + */ +void +close_all_beyond( + int keep_fd + ) +{ +# ifdef HAVE_CLOSEFROM + closefrom(keep_fd + 1); +# elif defined(F_CLOSEM) + /* + * From 'Writing Reliable AIX Daemons,' SG24-4946-00, + * by Eric Agar (saves us from doing 32767 system + * calls) + */ + if (fcntl(keep_fd + 1, F_CLOSEM, 0) == -1) + msyslog(LOG_ERR, "F_CLOSEM(%d): %m", keep_fd + 1); +# else /* !HAVE_CLOSEFROM && !F_CLOSEM follows */ + int fd; + int max_fd; + + max_fd = GETDTABLESIZE(); + for (fd = keep_fd + 1; fd < max_fd; fd++) + close(fd); +# endif /* !HAVE_CLOSEFROM && !F_CLOSEM */ +} +#endif /* HAVE_IO_COMPLETION_PORT */ + + +u_int +available_blocking_child_slot(void) +{ + const size_t each = sizeof(blocking_children[0]); + u_int slot; + size_t prev_alloc; + size_t new_alloc; + size_t prev_octets; + size_t octets; + + for (slot = 0; slot < blocking_children_alloc; slot++) { + if (NULL == blocking_children[slot]) + return slot; + if (blocking_children[slot]->reusable) { + blocking_children[slot]->reusable = FALSE; + return slot; + } + } + + prev_alloc = blocking_children_alloc; + prev_octets = prev_alloc * each; + new_alloc = blocking_children_alloc + 4; + octets = new_alloc * each; + blocking_children = erealloc_zero(blocking_children, octets, + prev_octets); + blocking_children_alloc = new_alloc; + + return prev_alloc; +} + + +int +queue_blocking_request( + blocking_work_req rtype, + void * req, + size_t reqsize, + blocking_work_callback done_func, + void * context + ) +{ + static u_int intres_slot = UINT_MAX; + u_int child_slot; + blocking_child * c; + blocking_pipe_header req_hdr; + + req_hdr.octets = sizeof(req_hdr) + reqsize; + req_hdr.magic_sig = BLOCKING_REQ_MAGIC; + req_hdr.rtype = rtype; + req_hdr.done_func = done_func; + req_hdr.context = context; + + child_slot = UINT_MAX; + if (worker_per_query || UINT_MAX == intres_slot || + blocking_children[intres_slot]->reusable) + child_slot = available_blocking_child_slot(); + if (!worker_per_query) { + if (UINT_MAX == intres_slot) + intres_slot = child_slot; + else + child_slot = intres_slot; + if (0 == intres_req_pending) + intres_timeout_req(0); + } + intres_req_pending++; + INSIST(UINT_MAX != child_slot); + c = blocking_children[child_slot]; + if (NULL == c) { + c = emalloc_zero(sizeof(*c)); +#ifdef WORK_FORK + c->req_read_pipe = -1; + c->req_write_pipe = -1; +#endif +#ifdef WORK_PIPE + c->resp_read_pipe = -1; + c->resp_write_pipe = -1; +#endif + blocking_children[child_slot] = c; + } + req_hdr.child_idx = child_slot; + + return send_blocking_req_internal(c, &req_hdr, req); +} + + +int queue_blocking_response( + blocking_child * c, + blocking_pipe_header * resp, + size_t respsize, + const blocking_pipe_header * req + ) +{ + resp->octets = respsize; + resp->magic_sig = BLOCKING_RESP_MAGIC; + resp->rtype = req->rtype; + resp->context = req->context; + resp->done_func = req->done_func; + + return send_blocking_resp_internal(c, resp); +} + + +void +process_blocking_resp( + blocking_child * c + ) +{ + blocking_pipe_header * resp; + void * data; + + /* + * On Windows send_blocking_resp_internal() may signal the + * blocking_response_ready event multiple times while we're + * processing a response, so always consume all available + * responses before returning to test the event again. + */ +#ifdef WORK_THREAD + do { +#endif + resp = receive_blocking_resp_internal(c); + if (NULL != resp) { + DEBUG_REQUIRE(BLOCKING_RESP_MAGIC == + resp->magic_sig); + data = (char *)resp + sizeof(*resp); + intres_req_pending--; + (*resp->done_func)(resp->rtype, resp->context, + resp->octets - sizeof(*resp), + data); + free(resp); + } +#ifdef WORK_THREAD + } while (NULL != resp); +#endif + if (!worker_per_query && 0 == intres_req_pending) + intres_timeout_req(CHILD_MAX_IDLE); + else if (worker_per_query) + req_child_exit(c); +} + + +/* + * blocking_child_common runs as a forked child or a thread + */ +int +blocking_child_common( + blocking_child *c + ) +{ + int say_bye; + blocking_pipe_header *req; + + say_bye = FALSE; + while (!say_bye) { + req = receive_blocking_req_internal(c); + if (NULL == req) { + say_bye = TRUE; + continue; + } + + DEBUG_REQUIRE(BLOCKING_REQ_MAGIC == req->magic_sig); + + switch (req->rtype) { + case BLOCKING_GETADDRINFO: + if (blocking_getaddrinfo(c, req)) + say_bye = TRUE; + break; + + case BLOCKING_GETNAMEINFO: + if (blocking_getnameinfo(c, req)) + say_bye = TRUE; + break; + + default: + msyslog(LOG_ERR, "unknown req %d to blocking worker", req->rtype); + say_bye = TRUE; + } + + free(req); + } + + return 0; +} + + +/* + * worker_idle_timer_fired() + * + * The parent starts this timer when the last pending response has been + * received from the child, making it idle, and clears the timer when a + * request is dispatched to the child. Once the timer expires, the + * child is sent packing. + * + * This is called when worker_idle_timer is nonzero and less than or + * equal to current_time. + */ +void +worker_idle_timer_fired(void) +{ + u_int idx; + blocking_child * c; + + DEBUG_REQUIRE(0 == intres_req_pending); + + intres_timeout_req(0); + for (idx = 0; idx < blocking_children_alloc; idx++) { + c = blocking_children[idx]; + if (NULL == c) + continue; + req_child_exit(c); + } +} + + +#else /* !WORKER follows */ +int ntp_worker_nonempty_compilation_unit; +#endif diff --git a/contrib/ntp/libntp/numtoa.c b/contrib/ntp/libntp/numtoa.c index de95118af..5efbe942e 100644 --- a/contrib/ntp/libntp/numtoa.c +++ b/contrib/ntp/libntp/numtoa.c @@ -1,6 +1,13 @@ /* * numtoa - return asciized network numbers store in local array space */ +#include + +#include +#ifdef HAVE_NETINET_IN_H +#include /* ntohl */ +#endif + #include #include "ntp_fp.h" @@ -17,8 +24,36 @@ numtoa( netnum = ntohl(num); LIB_GETBUF(buf); - (void) sprintf(buf, "%lu.%lu.%lu.%lu", ((u_long)netnum >> 24) & 0xff, - ((u_long)netnum >> 16) & 0xff, ((u_long)netnum >> 8) & 0xff, - (u_long)netnum & 0xff); + snprintf(buf, LIB_BUFLENGTH, "%lu.%lu.%lu.%lu", + ((u_long)netnum >> 24) & 0xff, + ((u_long)netnum >> 16) & 0xff, + ((u_long)netnum >> 8) & 0xff, + (u_long)netnum & 0xff); return buf; } + + +/* Convert a refid & stratum to a string */ +const char * +refid_str( + u_int32 refid, + int stratum + ) +{ + char * text; + size_t tlen; + + if (stratum > 1) + return numtoa(refid); + + LIB_GETBUF(text); + text[0] = '.'; + memcpy(&text[1], &refid, sizeof(refid)); + text[1 + sizeof(refid)] = '\0'; + tlen = strlen(text); + text[tlen] = '.'; + text[tlen + 1] = '\0'; + + return text; +} + diff --git a/contrib/ntp/libntp/numtohost.c b/contrib/ntp/libntp/numtohost.c index dd51c5d01..6b250d602 100644 --- a/contrib/ntp/libntp/numtohost.c +++ b/contrib/ntp/libntp/numtohost.c @@ -1,6 +1,12 @@ /* * numtohost - convert network number to host name. */ +#include + +#include +#ifdef HAVE_NETINET_IN_H +#include /* ntohl */ +#endif #include "ntp_fp.h" #include "ntp_stdlib.h" @@ -31,8 +37,7 @@ numtohost( return numtoa(netnum); LIB_GETBUF(bp); - - bp[LIB_BUFLENGTH-1] = '\0'; - (void) strncpy(bp, hp->h_name, LIB_BUFLENGTH-1); + strlcpy(bp, hp->h_name, LIB_BUFLENGTH); + return bp; } diff --git a/contrib/ntp/libntp/octtoint.c b/contrib/ntp/libntp/octtoint.c index f792b2bd6..e519601d0 100644 --- a/contrib/ntp/libntp/octtoint.c +++ b/contrib/ntp/libntp/octtoint.c @@ -2,6 +2,7 @@ * octtoint - convert an ascii string in octal to an unsigned * long, with error checking */ +#include #include #include @@ -23,7 +24,7 @@ octtoint( u = 0; while (*cp != '\0') { - if (!isdigit((int)*cp) || *cp == '8' || *cp == '9') + if (!isdigit((unsigned char)*cp) || *cp == '8' || *cp == '9') return 0; if (u >= 0x20000000) return 0; /* overflow */ diff --git a/contrib/ntp/libntp/prettydate.c b/contrib/ntp/libntp/prettydate.c index 55adf64ae..25b085ef2 100644 --- a/contrib/ntp/libntp/prettydate.c +++ b/contrib/ntp/libntp/prettydate.c @@ -1,132 +1,231 @@ /* * prettydate - convert a time stamp to something readable */ +#include #include #include "ntp_fp.h" #include "ntp_unixtime.h" /* includes */ #include "lib_strbuf.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" +#include "ntp_calendar.h" -static const char *months[] = { +#if SIZEOF_TIME_T < 4 +# error sizeof(time_t) < 4 -- this will not work! +#endif + +static char *common_prettydate(l_fp *, int); + +const char * const months[12] = { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" }; -static const char *days[] = { +const char * const daynames[7] = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" }; /* Helper function to handle possible wraparound of the ntp epoch. + * + * Works by periodic extension of the ntp time stamp in the UN*X epoch. + * If the 'time_t' is 32 bit, use solar cycle warping to get the value + * in a suitable range. Also uses solar cycle warping to work around + * really buggy implementations of 'gmtime()' / 'localtime()' that + * cannot work with a negative time value, that is, times before + * 1970-01-01. (MSVCRT...) + * + * Apart from that we're assuming that the localtime/gmtime library + * functions have been updated so that they work... + * + * An explanation: The julian calendar repeats ever 28 years, because + * it's the LCM of 7 and 1461, the week and leap year cycles. This is + * called a 'solar cycle'. The gregorian calendar does the same as + * long as no centennial year (divisible by 100, but not 400) goes in + * the way. So between 1901 and 2099 (inclusive) we can warp time + * stamps by 28 years to make them suitable for localtime() and + * gmtime() if we have trouble. Of course this will play hubbubb with + * the DST zone switches, so we should do it only if necessary; but as + * we NEED a proper conversion to dates via gmtime() we should try to + * cope with as many idiosyncrasies as possible. + * + */ - Works by assuming that the localtime/gmtime library functions - have been updated so that they work -*/ - -#define MAX_EPOCH_NR 1000 - -struct tm * -ntp2unix_tm( - u_long ntp, int local - ) +/* + * solar cycle in unsigned secs and years, and the cycle limits. + */ +#define SOLAR_CYCLE_SECS 0x34AADC80UL /* 7*1461*86400*/ +#define SOLAR_CYCLE_YEARS 28 +#define MINFOLD -3 +#define MAXFOLD 3 + +static struct tm * +get_struct_tm( + const vint64 *stamp, + int local) { - time_t t, curr; - struct tm *tm; - int curr_year, epoch_nr; - - /* First get the current year: */ - curr = time(NULL); - tm = local ? localtime(&curr) : gmtime(&curr); - if (!tm) return NULL; + struct tm *tm = NULL; + int32 folds = 0; + time_t ts; + +#ifdef HAVE_INT64 + + int64 tl; + ts = tl = stamp->q_s; + + /* + * If there is chance of truncation, try to fix it. Let the + * compiler find out if this can happen at all. + */ + while (ts != tl) { /* truncation? */ + if (tl < 0) { + if (--folds < MINFOLD) + return NULL; + tl += SOLAR_CYCLE_SECS; + } else { + if (++folds > MAXFOLD) + return NULL; + tl -= SOLAR_CYCLE_SECS; + } + ts = tl; /* next try... */ + } +#else + + /* + * since we do not have 64-bit scalars, it's not likely we have + * 64-bit time_t. Assume 32 bits and properly reduce the value. + */ + u_int32 hi, lo; + + hi = stamp->D_s.hi; + lo = stamp->D_s.lo; + + while ((hi && ~hi) || ((hi ^ lo) & 0x80000000u)) { + if (M_ISNEG(hi, lo)) { + if (--folds < MINFOLD) + return NULL; + M_ADD(hi, lo, 0, SOLAR_CYCLE_SECS); + } else { + if (++folds > MAXFOLD) + return NULL; + M_SUB(hi, lo, 0, SOLAR_CYCLE_SECS); + } + } + ts = (int32)lo; - curr_year = 1900 + tm->tm_year; +#endif - /* Convert the ntp timestamp to a unix utc seconds count: */ - t = (time_t) ntp - JAN_1970; + /* + * 'ts' should be a suitable value by now. Just go ahead, but + * with care: + * + * There are some pathological implementations of 'gmtime()' + * and 'localtime()' out there. No matter if we have 32-bit or + * 64-bit 'time_t', try to fix this by solar cycle warping + * again... + * + * At least the MSDN says that the (Microsoft) Windoze + * versions of 'gmtime()' and 'localtime()' will bark on time + * stamps < 0. + */ + while ((tm = (*(local ? localtime : gmtime))(&ts)) == NULL) + if (ts < 0) { + if (--folds < MINFOLD) + return NULL; + ts += SOLAR_CYCLE_SECS; + } else if (ts >= (time_t)SOLAR_CYCLE_SECS) { + if (++folds > MAXFOLD) + return NULL; + ts -= SOLAR_CYCLE_SECS; + } else + return NULL; /* That's truly pathological! */ + + /* 'tm' surely not NULL here! */ + INSIST(tm != NULL); + if (folds != 0) { + tm->tm_year += folds * SOLAR_CYCLE_YEARS; + if (tm->tm_year <= 0 || tm->tm_year >= 200) + return NULL; /* left warp range... can't help here! */ + } - /* Check that the ntp timestamp is not before a 136 year window centered - around the current year: + return tm; +} - Failsafe in case of an infinite loop: - Allow up to 1000 epochs of 136 years each! - */ - for (epoch_nr = 0; epoch_nr < MAX_EPOCH_NR; epoch_nr++) { - tm = local ? localtime(&t) : gmtime(&t); +static char * +common_prettydate( + l_fp *ts, + int local + ) +{ + static const char pfmt0[] = + "%08lx.%08lx %s, %s %2d %4d %2d:%02d:%02d.%03u"; + static const char pfmt1[] = + "%08lx.%08lx [%s, %s %2d %4d %2d:%02d:%02d.%03u UTC]"; -#if SIZEOF_TIME_T < 4 -# include "Bletch: sizeof(time_t) < 4!" -#endif + char *bp; + struct tm *tm; + u_int msec; + u_int32 ntps; + vint64 sec; -#if SIZEOF_TIME_T == 4 - /* If 32 bits, then year is 1970-2038, so no sense looking */ - epoch_nr = MAX_EPOCH_NR; -#else /* SIZEOF_TIME_T > 4 */ - /* Check that the resulting year is in the correct epoch: */ - if (1900 + tm->tm_year > curr_year - 68) break; + LIB_GETBUF(bp); - /* Epoch wraparound: Add 2^32 seconds! */ - t += (time_t) 65536 << 16; -#endif /* SIZEOF_TIME_T > 4 */ + /* get & fix milliseconds */ + ntps = ts->l_ui; + msec = ts->l_uf / 4294967; /* fract / (2 ** 32 / 1000) */ + if (msec >= 1000u) { + msec -= 1000u; + ntps++; } - return tm; + sec = ntpcal_ntp_to_time(ntps, NULL); + tm = get_struct_tm(&sec, local); + if (!tm) { + /* + * get a replacement, but always in UTC, using + * ntpcal_time_to_date() + */ + struct calendar jd; + ntpcal_time_to_date(&jd, &sec); + snprintf(bp, LIB_BUFLENGTH, local ? pfmt1 : pfmt0, + (u_long)ts->l_ui, (u_long)ts->l_uf, + daynames[jd.weekday], months[jd.month-1], + jd.monthday, jd.year, jd.hour, + jd.minute, jd.second, msec); + } else + snprintf(bp, LIB_BUFLENGTH, pfmt0, + (u_long)ts->l_ui, (u_long)ts->l_uf, + daynames[tm->tm_wday], months[tm->tm_mon], + tm->tm_mday, 1900 + tm->tm_year, tm->tm_hour, + tm->tm_min, tm->tm_sec, msec); + return bp; } + char * prettydate( l_fp *ts ) { - char *bp; - struct tm *tm; - time_t sec; - u_long msec; - - LIB_GETBUF(bp); - - sec = ts->l_ui; - msec = ts->l_uf / 4294967; /* fract / (2 ** 32 / 1000) */ - - tm = ntp2unix_tm(sec, 1); - if (!tm) { - (void) sprintf(bp, "%08lx.%08lx --- --- -- ---- --:--:--", - (u_long)ts->l_ui, (u_long)ts->l_uf); - } - else { - (void) sprintf(bp, "%08lx.%08lx %s, %s %2d %4d %2d:%02d:%02d.%03lu", - (u_long)ts->l_ui, (u_long)ts->l_uf, days[tm->tm_wday], - months[tm->tm_mon], tm->tm_mday, 1900 + tm->tm_year, - tm->tm_hour,tm->tm_min, tm->tm_sec, msec); - } - - return bp; + return common_prettydate(ts, 1); } + char * gmprettydate( l_fp *ts ) { - char *bp; - struct tm *tm; - time_t sec; - u_long msec; - - LIB_GETBUF(bp); - - sec = ts->l_ui; - msec = ts->l_uf / 4294967; /* fract / (2 ** 32 / 1000) */ + return common_prettydate(ts, 0); +} - tm = ntp2unix_tm(sec, 0); - if (!tm) { - (void) sprintf(bp, "%08lx.%08lx --- --- -- ---- --:--:--", - (u_long)ts->l_ui, (u_long)ts->l_uf); - } - else { - (void) sprintf(bp, "%08lx.%08lx %s, %s %2d %4d %2d:%02d:%02d.%03lu", - (u_long)ts->l_ui, (u_long)ts->l_uf, days[tm->tm_wday], - months[tm->tm_mon], tm->tm_mday, 1900 + tm->tm_year, - tm->tm_hour,tm->tm_min, tm->tm_sec, msec); - } - return bp; +struct tm * +ntp2unix_tm( + u_int32 ntp, int local + ) +{ + vint64 vl; + vl = ntpcal_ntp_to_time(ntp, NULL); + return get_struct_tm(&vl, local); } + diff --git a/contrib/ntp/libntp/recvbuff.c b/contrib/ntp/libntp/recvbuff.c index 6665686fe..73ebe886d 100644 --- a/contrib/ntp/libntp/recvbuff.c +++ b/contrib/ntp/libntp/recvbuff.c @@ -3,27 +3,27 @@ #endif #include -#include "ntp_machine.h" -#include "ntp_fp.h" + +#include "ntp_assert.h" #include "ntp_syslog.h" #include "ntp_stdlib.h" -#include "ntp_io.h" +#include "ntp_lists.h" #include "recvbuff.h" #include "iosignal.h" -#include + /* * Memory allocation */ -static u_long volatile full_recvbufs; /* number of recvbufs on fulllist */ -static u_long volatile free_recvbufs; /* number of recvbufs on freelist */ +static u_long volatile full_recvbufs; /* recvbufs on full_recv_fifo */ +static u_long volatile free_recvbufs; /* recvbufs on free_recv_list */ static u_long volatile total_recvbufs; /* total recvbufs currently in use */ static u_long volatile lowater_adds; /* number of times we have added memory */ static u_long volatile buffer_shortfall;/* number of missed free receive buffers - between replenishments */ + between replenishments */ -static ISC_LIST(recvbuf_t) full_recv_list; /* Currently used recv buffers */ -static ISC_LIST(recvbuf_t) free_recv_list; /* Currently unused buffers */ +static DECL_FIFO_ANCHOR(recvbuf_t) full_recv_fifo; +static recvbuf_t * free_recv_list; #if defined(SYS_WINNT) @@ -36,10 +36,15 @@ static CRITICAL_SECTION RecvLock; # define LOCK() EnterCriticalSection(&RecvLock) # define UNLOCK() LeaveCriticalSection(&RecvLock) #else -# define LOCK() -# define UNLOCK() +# define LOCK() do {} while (FALSE) +# define UNLOCK() do {} while (FALSE) +#endif + +#ifdef DEBUG +static void uninit_recvbuff(void); #endif + u_long free_recvbuffs (void) { @@ -64,15 +69,10 @@ lowater_additions(void) return lowater_adds; } -static void +static inline void initialise_buffer(recvbuf_t *buff) { - memset((char *) buff, 0, sizeof(recvbuf_t)); - -#if defined SYS_WINNT - buff->wsabuff.len = RX_BUFF_SIZE; - buff->wsabuff.buf = (char *) buff->recv_buffer; -#endif + ZERO(*buff); } static void @@ -84,12 +84,20 @@ create_buffers(int nbufs) abuf = nbufs + buffer_shortfall; buffer_shortfall = 0; - bufp = (recvbuf_t *) emalloc(abuf*sizeof(recvbuf_t)); +#ifndef DEBUG + bufp = emalloc_zero(abuf * sizeof(*bufp)); +#endif - for (i = 0; i < abuf; i++) - { - memset((char *) bufp, 0, sizeof(recvbuf_t)); - ISC_LIST_APPEND(free_recv_list, bufp, link); + for (i = 0; i < abuf; i++) { +#ifdef DEBUG + /* + * Allocate each buffer individually so they can be + * free()d during ntpd shutdown on DEBUG builds to + * keep them out of heap leak reports. + */ + bufp = emalloc_zero(sizeof(*bufp)); +#endif + LINK_SLIST(free_recv_list, bufp, link); bufp++; free_recvbufs++; total_recvbufs++; @@ -104,8 +112,6 @@ init_recvbuff(int nbufs) /* * Init buffer free list and stat counters */ - ISC_LIST_INIT(full_recv_list); - ISC_LIST_INIT(free_recv_list); free_recvbufs = total_recvbufs = 0; full_recvbufs = lowater_adds = 0; @@ -115,7 +121,34 @@ init_recvbuff(int nbufs) InitializeCriticalSection(&RecvLock); #endif +#ifdef DEBUG + atexit(&uninit_recvbuff); +#endif +} + + +#ifdef DEBUG +static void +uninit_recvbuff(void) +{ + recvbuf_t *rbunlinked; + + for (;;) { + UNLINK_FIFO(rbunlinked, full_recv_fifo, link); + if (rbunlinked == NULL) + break; + free(rbunlinked); + } + + for (;;) { + UNLINK_HEAD_SLIST(rbunlinked, free_recv_list, link); + if (rbunlinked == NULL) + break; + free(rbunlinked); + } } +#endif /* DEBUG */ + /* * freerecvbuf - make a single recvbuf available for reuse @@ -129,14 +162,10 @@ freerecvbuf(recvbuf_t *rb) } LOCK(); - (rb->used)--; + rb->used--; if (rb->used != 0) msyslog(LOG_ERR, "******** freerecvbuff non-zero usage: %d *******", rb->used); - ISC_LIST_APPEND(free_recv_list, rb, link); -#if defined SYS_WINNT - rb->wsabuff.len = RX_BUFF_SIZE; - rb->wsabuff.buf = (char *) rb->recv_buffer; -#endif + LINK_SLIST(free_recv_list, rb, link); free_recvbufs++; UNLOCK(); } @@ -150,63 +179,66 @@ add_full_recv_buffer(recvbuf_t *rb) return; } LOCK(); - ISC_LIST_APPEND(full_recv_list, rb, link); + LINK_FIFO(full_recv_fifo, rb, link); full_recvbufs++; UNLOCK(); } + recvbuf_t * get_free_recv_buffer(void) { - recvbuf_t * buffer = NULL; + recvbuf_t *buffer; + LOCK(); - buffer = ISC_LIST_HEAD(free_recv_list); - if (buffer != NULL) - { - ISC_LIST_DEQUEUE(free_recv_list, buffer, link); + UNLINK_HEAD_SLIST(buffer, free_recv_list, link); + if (buffer != NULL) { free_recvbufs--; initialise_buffer(buffer); - (buffer->used)++; - } - else - { + buffer->used++; + } else { buffer_shortfall++; } UNLOCK(); - return (buffer); + + return buffer; } + #ifdef HAVE_IO_COMPLETION_PORT recvbuf_t * get_free_recv_buffer_alloc(void) { - recvbuf_t * buffer = get_free_recv_buffer(); - if (buffer == NULL) - { + recvbuf_t *buffer; + + buffer = get_free_recv_buffer(); + if (NULL == buffer) { create_buffers(RECV_INC); buffer = get_free_recv_buffer(); } + ENSURE(buffer != NULL); return (buffer); } #endif + recvbuf_t * get_full_recv_buffer(void) { - recvbuf_t *rbuf; + recvbuf_t * rbuf; + LOCK(); #ifdef HAVE_SIGNALED_IO /* * make sure there are free buffers when we - * wander off to do lengthy paket processing with + * wander off to do lengthy packet processing with * any buffer we grab from the full list. * * fixes malloc() interrupted by SIGIO risk * (Bug 889) */ - rbuf = ISC_LIST_HEAD(free_recv_list); - if (rbuf == NULL || buffer_shortfall > 0) { + if (NULL == free_recv_list || buffer_shortfall > 0) { /* * try to get us some more buffers */ @@ -217,30 +249,78 @@ get_full_recv_buffer(void) /* * try to grab a full buffer */ - rbuf = ISC_LIST_HEAD(full_recv_list); + UNLINK_FIFO(rbuf, full_recv_fifo, link); if (rbuf != NULL) - { - ISC_LIST_DEQUEUE(full_recv_list, rbuf, link); - --full_recvbufs; - } - else - { - /* - * Make sure we reset the full count to 0 - */ - full_recvbufs = 0; + full_recvbufs--; + UNLOCK(); + + return rbuf; +} + + +/* + * purge_recv_buffers_for_fd() - purges any previously-received input + * from a given file descriptor. + */ +void +purge_recv_buffers_for_fd( + SOCKET fd + ) +{ + recvbuf_t *rbufp; + recvbuf_t *next; + recvbuf_t *punlinked; + + LOCK(); + + for (rbufp = HEAD_FIFO(full_recv_fifo); + rbufp != NULL; + rbufp = next) { + next = rbufp->link; + if (rbufp->fd == fd) { + UNLINK_MID_FIFO(punlinked, full_recv_fifo, + rbufp, link, recvbuf_t); + INSIST(punlinked == rbufp); + full_recvbufs--; + freerecvbuf(rbufp); + } } + UNLOCK(); - return (rbuf); } + /* * Checks to see if there are buffers to process */ isc_boolean_t has_full_recv_buffer(void) { - if (ISC_LIST_HEAD(full_recv_list) != NULL) + if (HEAD_FIFO(full_recv_fifo) != NULL) return (ISC_TRUE); else return (ISC_FALSE); } + + +#ifdef NTP_DEBUG_LISTS_H +void +check_gen_fifo_consistency(void *fifo) +{ + gen_fifo *pf; + gen_node *pthis; + gen_node **pptail; + + pf = fifo; + REQUIRE((NULL == pf->phead && NULL == pf->pptail) || + (NULL != pf->phead && NULL != pf->pptail)); + + pptail = &pf->phead; + for (pthis = pf->phead; + pthis != NULL; + pthis = pthis->link) + if (NULL != pthis->link) + pptail = &pthis->link; + + REQUIRE(NULL == pf->pptail || pptail == pf->pptail); +} +#endif /* NTP_DEBUG_LISTS_H */ diff --git a/contrib/ntp/libntp/refidsmear.c b/contrib/ntp/libntp/refidsmear.c new file mode 100644 index 000000000..fef428e8a --- /dev/null +++ b/contrib/ntp/libntp/refidsmear.c @@ -0,0 +1,58 @@ +#include + +#include +#include +#include + +/* + * we want to test a refid format of: + * 254.x.y.x + * + * where x.y.z are 24 bits containing 2 (signed) integer bits + * and 22 fractional bits. + * + */ + + +l_fp +convertRefIDToLFP(uint32_t r) +{ + l_fp temp; + + r = ntohl(r); + + // printf("%03d %08x: ", (r >> 24) & 0xFF, (r & 0x00FFFFFF) ); + + temp.l_uf = (r << 10); /* 22 fractional bits */ + + temp.l_ui = (r >> 22) & 0x3; + temp.l_ui |= ~(temp.l_ui & 2) + 1; + + return temp; +} + + +uint32_t +convertLFPToRefID(l_fp num) +{ + uint32_t temp; + + /* round the input with the highest bit to shift out from the + * fraction, then keep just two bits from the integral part. + * + * TODO: check for overflows; should we clamp/saturate or just + * complain? + */ + L_ADDUF(&num, 0x200); + num.l_ui &= 3; + + /* combine integral and fractional part to 24 bits */ + temp = (num.l_ui << 22) | (num.l_uf >> 10); + + /* put in the leading 254.0.0.0 */ + temp |= UINT32_C(0xFE000000); + + // printf("%03d %08x: ", (temp >> 24) & 0xFF, (temp & 0x00FFFFFF) ); + + return htonl(temp); +} diff --git a/contrib/ntp/libntp/refnumtoa.c b/contrib/ntp/libntp/refnumtoa.c index 7c5d96e1e..e6ca55aef 100644 --- a/contrib/ntp/libntp/refnumtoa.c +++ b/contrib/ntp/libntp/refnumtoa.c @@ -1,36 +1,36 @@ /* * refnumtoa - return asciized refclock addresses stored in local array space */ +#include #include -#include "ntp_fp.h" +#include "ntp_net.h" #include "lib_strbuf.h" #include "ntp_stdlib.h" -char * +const char * refnumtoa( - struct sockaddr_storage* num + sockaddr_u *num ) { - register u_int32 netnum; - register char *buf; - register const char *rclock; + u_int32 netnum; + char *buf; + const char *rclock; - LIB_GETBUF(buf); + if (!ISREFCLOCKADR(num)) + return socktoa(num); - if(num->ss_family == AF_INET) { - netnum = ntohl(((struct sockaddr_in*)num)->sin_addr.s_addr); - rclock = clockname((int)((u_long)netnum >> 8) & 0xff); + LIB_GETBUF(buf); + netnum = SRCADR(num); + rclock = clockname((int)((u_long)netnum >> 8) & 0xff); - if (rclock != NULL) - (void)sprintf(buf, "%s(%lu)", rclock, (u_long)netnum & 0xff); - else - (void)sprintf(buf, "REFCLK(%lu,%lu)", - ((u_long)netnum >> 8) & 0xff, (u_long)netnum & 0xff); + if (rclock != NULL) + snprintf(buf, LIB_BUFLENGTH, "%s(%lu)", + rclock, (u_long)netnum & 0xff); + else + snprintf(buf, LIB_BUFLENGTH, "REFCLK(%lu,%lu)", + ((u_long)netnum >> 8) & 0xff, + (u_long)netnum & 0xff); - } - else { - (void)sprintf(buf, "refclock address type not implemented yet, use IPv4 refclock address."); - } return buf; } diff --git a/contrib/ntp/libntp/snprintf.c b/contrib/ntp/libntp/snprintf.c index 7588b8483..2b6a37473 100644 --- a/contrib/ntp/libntp/snprintf.c +++ b/contrib/ntp/libntp/snprintf.c @@ -1,62 +1,2132 @@ +/* + * Modified by Dave Hart for integration into NTP 4.2.7 + * + * Changed in a backwards-incompatible way to separate HAVE_SNPRINTF + * from HW_WANT_RPL_SNPRINTF, etc. for each of the four replaced + * functions. + * + * Changed to honor hw_force_rpl_snprintf=yes, etc. This is used by NTP + * to test rpl_snprintf() and rpl_vsnprintf() on platforms which provide + * C99-compliant implementations. + */ + +/* $Id: snprintf.c,v 1.9 2008/01/20 14:02:00 holger Exp $ */ + +/* + * Copyright (c) 1995 Patrick Powell. + * + * This code is based on code written by Patrick Powell . + * It may be used for any purpose as long as this notice remains intact on all + * source code distributions. + */ + +/* + * Copyright (c) 2008 Holger Weiss. + * + * This version of the code is maintained by Holger Weiss . + * My changes to the code may freely be used, modified and/or redistributed for + * any purpose. It would be nice if additions and fixes to this file (including + * trivial code cleanups) would be sent back in order to let me include them in + * the version available at . + * However, this is not a requirement for using or redistributing (possibly + * modified) versions of this file, nor is leaving this notice intact mandatory. + */ + +/* + * History + * + * 2008-01-20 Holger Weiss for C99-snprintf 1.1: + * + * Fixed the detection of infinite floating point values on IRIX (and + * possibly other systems) and applied another few minor cleanups. + * + * 2008-01-06 Holger Weiss for C99-snprintf 1.0: + * + * Added a lot of new features, fixed many bugs, and incorporated various + * improvements done by Andrew Tridgell , Russ Allbery + * , Hrvoje Niksic , Damien Miller + * , and others for the Samba, INN, Wget, and OpenSSH + * projects. The additions include: support the "e", "E", "g", "G", and + * "F" conversion specifiers (and use conversion style "f" or "F" for the + * still unsupported "a" and "A" specifiers); support the "hh", "ll", "j", + * "t", and "z" length modifiers; support the "#" flag and the (non-C99) + * "'" flag; use localeconv(3) (if available) to get both the current + * locale's decimal point character and the separator between groups of + * digits; fix the handling of various corner cases of field width and + * precision specifications; fix various floating point conversion bugs; + * handle infinite and NaN floating point values; don't attempt to write to + * the output buffer (which may be NULL) if a size of zero was specified; + * check for integer overflow of the field width, precision, and return + * values and during the floating point conversion; use the OUTCHAR() macro + * instead of a function for better performance; provide asprintf(3) and + * vasprintf(3) functions; add new test cases. The replacement functions + * have been renamed to use an "rpl_" prefix, the function calls in the + * main project (and in this file) must be redefined accordingly for each + * replacement function which is needed (by using Autoconf or other means). + * Various other minor improvements have been applied and the coding style + * was cleaned up for consistency. + * + * 2007-07-23 Holger Weiss for Mutt 1.5.13: + * + * C99 compliant snprintf(3) and vsnprintf(3) functions return the number + * of characters that would have been written to a sufficiently sized + * buffer (excluding the '\0'). The original code simply returned the + * length of the resulting output string, so that's been fixed. + * + * 1998-03-05 Michael Elkins for Mutt 0.90.8: + * + * The original code assumed that both snprintf(3) and vsnprintf(3) were + * missing. Some systems only have snprintf(3) but not vsnprintf(3), so + * the code is now broken down under HAVE_SNPRINTF and HAVE_VSNPRINTF. + * + * 1998-01-27 Thomas Roessler for Mutt 0.89i: + * + * The PGP code was using unsigned hexadecimal formats. Unfortunately, + * unsigned formats simply didn't work. + * + * 1997-10-22 Brandon Long for Mutt 0.87.1: + * + * Ok, added some minimal floating point support, which means this probably + * requires libm on most operating systems. Don't yet support the exponent + * (e,E) and sigfig (g,G). Also, fmtint() was pretty badly broken, it just + * wasn't being exercised in ways which showed it, so that's been fixed. + * Also, formatted the code to Mutt conventions, and removed dead code left + * over from the original. Also, there is now a builtin-test, run with: + * gcc -DTEST_SNPRINTF -o snprintf snprintf.c -lm && ./snprintf + * + * 2996-09-15 Brandon Long for Mutt 0.43: + * + * This was ugly. It is still ugly. I opted out of floating point + * numbers, but the formatter understands just about everything from the + * normal C string format, at least as far as I can tell from the Solaris + * 2.5 printf(3S) man page. + */ + +/* + * ToDo + * + * - Add wide character support. + * - Add support for "%a" and "%A" conversions. + * - Create test routines which predefine the expected results. Our test cases + * usually expose bugs in system implementations rather than in ours :-) + */ + +/* + * Usage + * + * 1) The following preprocessor macros should be defined to 1 if the feature or + * file in question is available on the target system (by using Autoconf or + * other means), though basic functionality should be available as long as + * HAVE_STDARG_H and HAVE_STDLIB_H are defined correctly: + * + * HW_WANT_RPL_VSNPRINTF + * HW_WANT_RPL_SNPRINTF + * HW_WANT_RPL_VASPRINTF + * HW_WANT_RPL_ASPRINTF + * HAVE_VSNPRINTF // define to 1 #if HW_WANT_RPL_VSNPRINTF + * HAVE_SNPRINTF // define to 1 #if HW_WANT_RPL_SNPRINTF + * HAVE_VASPRINTF // define to 1 #if HW_WANT_RPL_VASPRINTF + * HAVE_ASPRINTF // define to 1 #if HW_WANT_RPL_ASPRINTF + * HAVE_STDARG_H + * HAVE_STDDEF_H + * HAVE_STDINT_H + * HAVE_STDLIB_H + * HAVE_INTTYPES_H + * HAVE_LOCALE_H + * HAVE_LOCALECONV + * HAVE_LCONV_DECIMAL_POINT + * HAVE_LCONV_THOUSANDS_SEP + * HAVE_LONG_DOUBLE + * HAVE_LONG_LONG_INT + * HAVE_UNSIGNED_LONG_LONG_INT + * HAVE_INTMAX_T + * HAVE_UINTMAX_T + * HAVE_UINTPTR_T + * HAVE_PTRDIFF_T + * HAVE_VA_COPY + * HAVE___VA_COPY + * + * 2) The calls to the functions which should be replaced must be redefined + * throughout the project files (by using Autoconf or other means): + * + * #if HW_WANT_RPL_VSNPRINTF + * #define vsnprintf rpl_vsnprintf + * #endif + * #if HW_WANT_RPL_SNPRINTF + * #define snprintf rpl_snprintf + * #endif + * #if HW_WANT_RPL_VASPRINTF + * #define vasprintf rpl_vasprintf + * #endif + * #if HW_WANT_RPL_ASPRINTF + * #define asprintf rpl_asprintf + * #endif + * + * 3) The required replacement functions should be declared in some header file + * included throughout the project files: + * + * #if HAVE_CONFIG_H + * #include + * #endif + * #if HAVE_STDARG_H + * #include + * #if HW_WANT_RPL_VSNPRINTF + * int rpl_vsnprintf(char *, size_t, const char *, va_list); + * #endif + * #if HW_WANT_RPL_SNPRINTF + * int rpl_snprintf(char *, size_t, const char *, ...); + * #endif + * #if HW_WANT_RPL_VASPRINTF + * int rpl_vasprintf(char **, const char *, va_list); + * #endif + * #if HW_WANT_RPL_ASPRINTF + * int rpl_asprintf(char **, const char *, ...); + * #endif + * #endif + * + * Autoconf macros for handling step 1 and step 2 are available at + * . + */ + +#if HAVE_CONFIG_H #include +#endif /* HAVE_CONFIG_H */ -#if !HAVE_SNPRINTF -#include +#if TEST_SNPRINTF +#include /* For pow(3), NAN, and INFINITY. */ +#include /* For strcmp(3). */ +#if defined(__NetBSD__) || \ + defined(__FreeBSD__) || \ + defined(__OpenBSD__) || \ + defined(__NeXT__) || \ + defined(__bsd__) +#define OS_BSD 1 +#elif defined(sgi) || defined(__sgi) +#ifndef __c99 +#define __c99 /* Force C99 mode to get included on IRIX 6.5.30. */ +#endif /* !defined(__c99) */ +#define OS_IRIX 1 +#define OS_SYSV 1 +#elif defined(__svr4__) +#define OS_SYSV 1 +#elif defined(__linux__) +#define OS_LINUX 1 +#endif /* defined(__NetBSD__) || defined(__FreeBSD__) || [...] */ +#if HAVE_CONFIG_H /* Undefine definitions possibly done in config.h. */ +#ifdef HAVE_SNPRINTF +#undef HAVE_SNPRINTF +#endif /* defined(HAVE_SNPRINTF) */ +#ifdef HAVE_VSNPRINTF +#undef HAVE_VSNPRINTF +#endif /* defined(HAVE_VSNPRINTF) */ +#ifdef HAVE_ASPRINTF +#undef HAVE_ASPRINTF +#endif /* defined(HAVE_ASPRINTF) */ +#ifdef HAVE_VASPRINTF +#undef HAVE_VASPRINTF +#endif /* defined(HAVE_VASPRINTF) */ +#ifdef snprintf +#undef snprintf +#endif /* defined(snprintf) */ +#ifdef vsnprintf +#undef vsnprintf +#endif /* defined(vsnprintf) */ +#ifdef asprintf +#undef asprintf +#endif /* defined(asprintf) */ +#ifdef vasprintf +#undef vasprintf +#endif /* defined(vasprintf) */ +#else /* By default, we assume a modern system for testing. */ +#ifndef HAVE_STDARG_H +#define HAVE_STDARG_H 1 +#endif /* HAVE_STDARG_H */ +#ifndef HAVE_STDDEF_H +#define HAVE_STDDEF_H 1 +#endif /* HAVE_STDDEF_H */ +#ifndef HAVE_STDINT_H +#define HAVE_STDINT_H 1 +#endif /* HAVE_STDINT_H */ +#ifndef HAVE_STDLIB_H +#define HAVE_STDLIB_H 1 +#endif /* HAVE_STDLIB_H */ +#ifndef HAVE_INTTYPES_H +#define HAVE_INTTYPES_H 1 +#endif /* HAVE_INTTYPES_H */ +#ifndef HAVE_LOCALE_H +#define HAVE_LOCALE_H 1 +#endif /* HAVE_LOCALE_H */ +#ifndef HAVE_LOCALECONV +#define HAVE_LOCALECONV 1 +#endif /* !defined(HAVE_LOCALECONV) */ +#ifndef HAVE_LCONV_DECIMAL_POINT +#define HAVE_LCONV_DECIMAL_POINT 1 +#endif /* HAVE_LCONV_DECIMAL_POINT */ +#ifndef HAVE_LCONV_THOUSANDS_SEP +#define HAVE_LCONV_THOUSANDS_SEP 1 +#endif /* HAVE_LCONV_THOUSANDS_SEP */ +#ifndef HAVE_LONG_DOUBLE +#define HAVE_LONG_DOUBLE 1 +#endif /* !defined(HAVE_LONG_DOUBLE) */ +#ifndef HAVE_LONG_LONG_INT +#define HAVE_LONG_LONG_INT 1 +#endif /* !defined(HAVE_LONG_LONG_INT) */ +#ifndef HAVE_UNSIGNED_LONG_LONG_INT +#define HAVE_UNSIGNED_LONG_LONG_INT 1 +#endif /* !defined(HAVE_UNSIGNED_LONG_LONG_INT) */ +#ifndef HAVE_INTMAX_T +#define HAVE_INTMAX_T 1 +#endif /* !defined(HAVE_INTMAX_T) */ +#ifndef HAVE_UINTMAX_T +#define HAVE_UINTMAX_T 1 +#endif /* !defined(HAVE_UINTMAX_T) */ +#ifndef HAVE_UINTPTR_T +#define HAVE_UINTPTR_T 1 +#endif /* !defined(HAVE_UINTPTR_T) */ +#ifndef HAVE_PTRDIFF_T +#define HAVE_PTRDIFF_T 1 +#endif /* !defined(HAVE_PTRDIFF_T) */ +#ifndef HAVE_VA_COPY +#define HAVE_VA_COPY 1 +#endif /* !defined(HAVE_VA_COPY) */ +#ifndef HAVE___VA_COPY +#define HAVE___VA_COPY 1 +#endif /* !defined(HAVE___VA_COPY) */ +#endif /* HAVE_CONFIG_H */ +#define snprintf rpl_snprintf +#define vsnprintf rpl_vsnprintf +#define asprintf rpl_asprintf +#define vasprintf rpl_vasprintf +#endif /* TEST_SNPRINTF */ -#ifdef __STDC__ +#if HW_WANT_RPL_SNPRINTF || HW_WANT_RPL_VSNPRINTF || HW_WANT_RPL_ASPRINTF || HW_WANT_RPL_VASPRINTF +#include /* For NULL, size_t, vsnprintf(3), and vasprintf(3). */ +#ifdef VA_START +#undef VA_START +#endif /* defined(VA_START) */ +#ifdef VA_SHIFT +#undef VA_SHIFT +#endif /* defined(VA_SHIFT) */ +#if HAVE_STDARG_H #include -#else +#define VA_START(ap, last) va_start(ap, last) +#define VA_SHIFT(ap, value, type) /* No-op for ANSI C. */ +#else /* Assume is available. */ #include -#endif -#include +#define VA_START(ap, last) va_start(ap) /* "last" is ignored. */ +#define VA_SHIFT(ap, value, type) value = va_arg(ap, type) +#endif /* HAVE_STDARG_H */ + +#if HW_WANT_RPL_VASPRINTF +#if HAVE_STDLIB_H +#include /* For malloc(3). */ +#endif /* HAVE_STDLIB_H */ +#ifdef VA_COPY +#undef VA_COPY +#endif /* defined(VA_COPY) */ +#ifdef VA_END_COPY +#undef VA_END_COPY +#endif /* defined(VA_END_COPY) */ +#if HAVE_VA_COPY +#define VA_COPY(dest, src) va_copy(dest, src) +#define VA_END_COPY(ap) va_end(ap) +#elif HAVE___VA_COPY +#define VA_COPY(dest, src) __va_copy(dest, src) +#define VA_END_COPY(ap) va_end(ap) +#else +#define VA_COPY(dest, src) (void)mymemcpy(&dest, &src, sizeof(va_list)) +#define VA_END_COPY(ap) /* No-op. */ +#define NEED_MYMEMCPY 1 +static void *mymemcpy(void *, void *, size_t); +#endif /* HAVE_VA_COPY */ +#endif /* HW_WANT_RPL_VASPRINTF */ -#include "l_stdlib.h" +#if HW_WANT_RPL_VSNPRINTF +#include /* For ERANGE and errno. */ +#include /* For *_MAX. */ +#if HAVE_INTTYPES_H +#include /* For intmax_t (if not defined in ). */ +#endif /* HAVE_INTTYPES_H */ +#if HAVE_LOCALE_H +#include /* For localeconv(3). */ +#endif /* HAVE_LOCALE_H */ +#if HAVE_STDDEF_H +#include /* For ptrdiff_t. */ +#endif /* HAVE_STDDEF_H */ +#if HAVE_STDINT_H +#include /* For intmax_t. */ +#endif /* HAVE_STDINT_H */ -#ifdef __STDC__ -int snprintf(char *str, size_t n, const char *fmt, ...) +/* Support for unsigned long long int. We may also need ULLONG_MAX. */ +#ifndef ULONG_MAX /* We may need ULONG_MAX as a fallback. */ +#ifdef UINT_MAX +#define ULONG_MAX UINT_MAX #else -int snprintf(str, n, fmt, va_alist) - char *str; - size_t n; - const char *fmt; - va_dcl -#endif +#define ULONG_MAX INT_MAX +#endif /* defined(UINT_MAX) */ +#endif /* !defined(ULONG_MAX) */ +#ifdef ULLONG +#undef ULLONG +#endif /* defined(ULLONG) */ +#if HAVE_UNSIGNED_LONG_LONG_INT +#define ULLONG unsigned long long int +#ifndef ULLONG_MAX +#define ULLONG_MAX ULONG_MAX +#endif /* !defined(ULLONG_MAX) */ +#else +#define ULLONG unsigned long int +#ifdef ULLONG_MAX +#undef ULLONG_MAX +#endif /* defined(ULLONG_MAX) */ +#define ULLONG_MAX ULONG_MAX +#endif /* HAVE_LONG_LONG_INT */ + +/* Support for uintmax_t. We also need UINTMAX_MAX. */ +#ifdef UINTMAX_T +#undef UINTMAX_T +#endif /* defined(UINTMAX_T) */ +#if HAVE_UINTMAX_T || defined(uintmax_t) +#define UINTMAX_T uintmax_t +#ifndef UINTMAX_MAX +#define UINTMAX_MAX ULLONG_MAX +#endif /* !defined(UINTMAX_MAX) */ +#else +#define UINTMAX_T ULLONG +#ifdef UINTMAX_MAX +#undef UINTMAX_MAX +#endif /* defined(UINTMAX_MAX) */ +#define UINTMAX_MAX ULLONG_MAX +#endif /* HAVE_UINTMAX_T || defined(uintmax_t) */ + +/* Support for long double. */ +#ifndef LDOUBLE +#if HAVE_LONG_DOUBLE +#define LDOUBLE long double +#else +#define LDOUBLE double +#endif /* HAVE_LONG_DOUBLE */ +#endif /* !defined(LDOUBLE) */ + +/* Support for long long int. */ +#ifndef LLONG +#if HAVE_LONG_LONG_INT +#define LLONG long long int +#else +#define LLONG long int +#endif /* HAVE_LONG_LONG_INT */ +#endif /* !defined(LLONG) */ + +/* Support for intmax_t. */ +#ifndef INTMAX_T +#if HAVE_INTMAX_T || defined(intmax_t) +#define INTMAX_T intmax_t +#else +#define INTMAX_T LLONG +#endif /* HAVE_INTMAX_T || defined(intmax_t) */ +#endif /* !defined(INTMAX_T) */ + +/* Support for uintptr_t. */ +#ifndef UINTPTR_T +#if HAVE_UINTPTR_T || defined(uintptr_t) +#define UINTPTR_T uintptr_t +#else +#define UINTPTR_T unsigned long int +#endif /* HAVE_UINTPTR_T || defined(uintptr_t) */ +#endif /* !defined(UINTPTR_T) */ + +/* Support for ptrdiff_t. */ +#ifndef PTRDIFF_T +#if HAVE_PTRDIFF_T || defined(ptrdiff_t) +#define PTRDIFF_T ptrdiff_t +#else +#define PTRDIFF_T long int +#endif /* HAVE_PTRDIFF_T || defined(ptrdiff_t) */ +#endif /* !defined(PTRDIFF_T) */ + +/* + * We need an unsigned integer type corresponding to ptrdiff_t (cf. C99: + * 7.19.6.1, 7). However, we'll simply use PTRDIFF_T and convert it to an + * unsigned type if necessary. This should work just fine in practice. + */ +#ifndef UPTRDIFF_T +#define UPTRDIFF_T PTRDIFF_T +#endif /* !defined(UPTRDIFF_T) */ + +/* + * We need a signed integer type corresponding to size_t (cf. C99: 7.19.6.1, 7). + * However, we'll simply use size_t and convert it to a signed type if + * necessary. This should work just fine in practice. + */ +#ifndef SSIZE_T +#define SSIZE_T size_t +#endif /* !defined(SSIZE_T) */ + +/* Either ERANGE or E2BIG should be available everywhere. */ +#ifndef ERANGE +#define ERANGE E2BIG +#endif /* !defined(ERANGE) */ +#ifndef EOVERFLOW +#define EOVERFLOW ERANGE +#endif /* !defined(EOVERFLOW) */ + +/* + * Buffer size to hold the octal string representation of UINT128_MAX without + * nul-termination ("3777777777777777777777777777777777777777777"). + */ +#ifdef MAX_CONVERT_LENGTH +#undef MAX_CONVERT_LENGTH +#endif /* defined(MAX_CONVERT_LENGTH) */ +#define MAX_CONVERT_LENGTH 43 + +/* Format read states. */ +#define PRINT_S_DEFAULT 0 +#define PRINT_S_FLAGS 1 +#define PRINT_S_WIDTH 2 +#define PRINT_S_DOT 3 +#define PRINT_S_PRECISION 4 +#define PRINT_S_MOD 5 +#define PRINT_S_CONV 6 + +/* Format flags. */ +#define PRINT_F_MINUS (1 << 0) +#define PRINT_F_PLUS (1 << 1) +#define PRINT_F_SPACE (1 << 2) +#define PRINT_F_NUM (1 << 3) +#define PRINT_F_ZERO (1 << 4) +#define PRINT_F_QUOTE (1 << 5) +#define PRINT_F_UP (1 << 6) +#define PRINT_F_UNSIGNED (1 << 7) +#define PRINT_F_TYPE_G (1 << 8) +#define PRINT_F_TYPE_E (1 << 9) + +/* Conversion flags. */ +#define PRINT_C_CHAR 1 +#define PRINT_C_SHORT 2 +#define PRINT_C_LONG 3 +#define PRINT_C_LLONG 4 +#define PRINT_C_LDOUBLE 5 +#define PRINT_C_SIZE 6 +#define PRINT_C_PTRDIFF 7 +#define PRINT_C_INTMAX 8 + +#ifndef MAX +#define MAX(x, y) ((x >= y) ? x : y) +#endif /* !defined(MAX) */ +#ifndef CHARTOINT +#define CHARTOINT(ch) (ch - '0') +#endif /* !defined(CHARTOINT) */ +#ifndef ISDIGIT +#define ISDIGIT(ch) ('0' <= (unsigned char)ch && (unsigned char)ch <= '9') +#endif /* !defined(ISDIGIT) */ +#ifndef ISNAN +#define ISNAN(x) (x != x) +#endif /* !defined(ISNAN) */ +#ifndef ISINF +#define ISINF(x) (x != 0.0 && x + x == x) +#endif /* !defined(ISINF) */ + +#ifdef OUTCHAR +#undef OUTCHAR +#endif /* defined(OUTCHAR) */ +#define OUTCHAR(str, len, size, ch) \ +do { \ + if (len + 1 < size) \ + str[len] = ch; \ + (len)++; \ +} while (/* CONSTCOND */ 0) + +static void fmtstr(char *, size_t *, size_t, const char *, int, int, int); +static void fmtint(char *, size_t *, size_t, INTMAX_T, int, int, int, int); +static void fmtflt(char *, size_t *, size_t, LDOUBLE, int, int, int, int *); +static void printsep(char *, size_t *, size_t); +static int getnumsep(int); +static int getexponent(LDOUBLE); +static int convert(UINTMAX_T, char *, size_t, int, int); +static UINTMAX_T cast(LDOUBLE); +static UINTMAX_T myround(LDOUBLE); +static LDOUBLE mypow10(int); + +int +rpl_vsnprintf(char *str, size_t size, const char *format, va_list args); + +int +rpl_vsnprintf(char *str, size_t size, const char *format, va_list args) +{ + LDOUBLE fvalue; + INTMAX_T value; + unsigned char cvalue; + const char *strvalue; + INTMAX_T *intmaxptr; + PTRDIFF_T *ptrdiffptr; + SSIZE_T *sizeptr; + LLONG *llongptr; + long int *longptr; + int *intptr; + short int *shortptr; + signed char *charptr; + size_t len = 0; + int overflow = 0; + int base = 0; + int cflags = 0; + int flags = 0; + int width = 0; + int precision = -1; + int state = PRINT_S_DEFAULT; + char ch = *format++; + + /* + * C99 says: "If `n' is zero, nothing is written, and `s' may be a null + * pointer." (7.19.6.5, 2) We're forgiving and allow a NULL pointer + * even if a size larger than zero was specified. At least NetBSD's + * snprintf(3) does the same, as well as other versions of this file. + * (Though some of these versions will write to a non-NULL buffer even + * if a size of zero was specified, which violates the standard.) + */ + if (str == NULL && size != 0) + size = 0; + + while (ch != '\0') + switch (state) { + case PRINT_S_DEFAULT: + if (ch == '%') + state = PRINT_S_FLAGS; + else + OUTCHAR(str, len, size, ch); + ch = *format++; + break; + case PRINT_S_FLAGS: + switch (ch) { + case '-': + flags |= PRINT_F_MINUS; + ch = *format++; + break; + case '+': + flags |= PRINT_F_PLUS; + ch = *format++; + break; + case ' ': + flags |= PRINT_F_SPACE; + ch = *format++; + break; + case '#': + flags |= PRINT_F_NUM; + ch = *format++; + break; + case '0': + flags |= PRINT_F_ZERO; + ch = *format++; + break; + case '\'': /* SUSv2 flag (not in C99). */ + flags |= PRINT_F_QUOTE; + ch = *format++; + break; + default: + state = PRINT_S_WIDTH; + break; + } + break; + case PRINT_S_WIDTH: + if (ISDIGIT(ch)) { + ch = CHARTOINT(ch); + if (width > (INT_MAX - ch) / 10) { + overflow = 1; + goto out; + } + width = 10 * width + ch; + ch = *format++; + } else if (ch == '*') { + /* + * C99 says: "A negative field width argument is + * taken as a `-' flag followed by a positive + * field width." (7.19.6.1, 5) + */ + if ((width = va_arg(args, int)) < 0) { + flags |= PRINT_F_MINUS; + width = -width; + } + ch = *format++; + state = PRINT_S_DOT; + } else + state = PRINT_S_DOT; + break; + case PRINT_S_DOT: + if (ch == '.') { + state = PRINT_S_PRECISION; + ch = *format++; + } else + state = PRINT_S_MOD; + break; + case PRINT_S_PRECISION: + if (precision == -1) + precision = 0; + if (ISDIGIT(ch)) { + ch = CHARTOINT(ch); + if (precision > (INT_MAX - ch) / 10) { + overflow = 1; + goto out; + } + precision = 10 * precision + ch; + ch = *format++; + } else if (ch == '*') { + /* + * C99 says: "A negative precision argument is + * taken as if the precision were omitted." + * (7.19.6.1, 5) + */ + if ((precision = va_arg(args, int)) < 0) + precision = -1; + ch = *format++; + state = PRINT_S_MOD; + } else + state = PRINT_S_MOD; + break; + case PRINT_S_MOD: + switch (ch) { + case 'h': + ch = *format++; + if (ch == 'h') { /* It's a char. */ + ch = *format++; + cflags = PRINT_C_CHAR; + } else + cflags = PRINT_C_SHORT; + break; + case 'l': + ch = *format++; + if (ch == 'l') { /* It's a long long. */ + ch = *format++; + cflags = PRINT_C_LLONG; + } else + cflags = PRINT_C_LONG; + break; + case 'L': + cflags = PRINT_C_LDOUBLE; + ch = *format++; + break; + case 'j': + cflags = PRINT_C_INTMAX; + ch = *format++; + break; + case 't': + cflags = PRINT_C_PTRDIFF; + ch = *format++; + break; + case 'z': + cflags = PRINT_C_SIZE; + ch = *format++; + break; + } + state = PRINT_S_CONV; + break; + case PRINT_S_CONV: + switch (ch) { + case 'd': + /* FALLTHROUGH */ + case 'i': + switch (cflags) { + case PRINT_C_CHAR: + value = (signed char)va_arg(args, int); + break; + case PRINT_C_SHORT: + value = (short int)va_arg(args, int); + break; + case PRINT_C_LONG: + value = va_arg(args, long int); + break; + case PRINT_C_LLONG: + value = va_arg(args, LLONG); + break; + case PRINT_C_SIZE: + value = va_arg(args, SSIZE_T); + break; + case PRINT_C_INTMAX: + value = va_arg(args, INTMAX_T); + break; + case PRINT_C_PTRDIFF: + value = va_arg(args, PTRDIFF_T); + break; + default: + value = va_arg(args, int); + break; + } + fmtint(str, &len, size, value, 10, width, + precision, flags); + break; + case 'X': + flags |= PRINT_F_UP; + /* FALLTHROUGH */ + case 'x': + base = 16; + /* FALLTHROUGH */ + case 'o': + if (base == 0) + base = 8; + /* FALLTHROUGH */ + case 'u': + if (base == 0) + base = 10; + flags |= PRINT_F_UNSIGNED; + switch (cflags) { + case PRINT_C_CHAR: + value = (unsigned char)va_arg(args, + unsigned int); + break; + case PRINT_C_SHORT: + value = (unsigned short int)va_arg(args, + unsigned int); + break; + case PRINT_C_LONG: + value = va_arg(args, unsigned long int); + break; + case PRINT_C_LLONG: + value = va_arg(args, ULLONG); + break; + case PRINT_C_SIZE: + value = va_arg(args, size_t); + break; + case PRINT_C_INTMAX: + value = va_arg(args, UINTMAX_T); + break; + case PRINT_C_PTRDIFF: + value = va_arg(args, UPTRDIFF_T); + break; + default: + value = va_arg(args, unsigned int); + break; + } + fmtint(str, &len, size, value, base, width, + precision, flags); + break; + case 'A': + /* Not yet supported, we'll use "%F". */ + /* FALLTHROUGH */ + case 'F': + flags |= PRINT_F_UP; + /* FALLTHROUGH */ + case 'a': + /* Not yet supported, we'll use "%f". */ + /* FALLTHROUGH */ + case 'f': + if (cflags == PRINT_C_LDOUBLE) + fvalue = va_arg(args, LDOUBLE); + else + fvalue = va_arg(args, double); + fmtflt(str, &len, size, fvalue, width, + precision, flags, &overflow); + if (overflow) + goto out; + break; + case 'E': + flags |= PRINT_F_UP; + /* FALLTHROUGH */ + case 'e': + flags |= PRINT_F_TYPE_E; + if (cflags == PRINT_C_LDOUBLE) + fvalue = va_arg(args, LDOUBLE); + else + fvalue = va_arg(args, double); + fmtflt(str, &len, size, fvalue, width, + precision, flags, &overflow); + if (overflow) + goto out; + break; + case 'G': + flags |= PRINT_F_UP; + /* FALLTHROUGH */ + case 'g': + flags |= PRINT_F_TYPE_G; + if (cflags == PRINT_C_LDOUBLE) + fvalue = va_arg(args, LDOUBLE); + else + fvalue = va_arg(args, double); + /* + * If the precision is zero, it is treated as + * one (cf. C99: 7.19.6.1, 8). + */ + if (precision == 0) + precision = 1; + fmtflt(str, &len, size, fvalue, width, + precision, flags, &overflow); + if (overflow) + goto out; + break; + case 'c': + cvalue = va_arg(args, int); + OUTCHAR(str, len, size, cvalue); + break; + case 's': + strvalue = va_arg(args, char *); + fmtstr(str, &len, size, strvalue, width, + precision, flags); + break; + case 'p': + /* + * C99 says: "The value of the pointer is + * converted to a sequence of printing + * characters, in an implementation-defined + * manner." (C99: 7.19.6.1, 8) + */ + if ((strvalue = va_arg(args, void *)) == NULL) + /* + * We use the glibc format. BSD prints + * "0x0", SysV "0". + */ + fmtstr(str, &len, size, "(nil)", width, + -1, flags); + else { + /* + * We use the BSD/glibc format. SysV + * omits the "0x" prefix (which we emit + * using the PRINT_F_NUM flag). + */ + flags |= PRINT_F_NUM; + flags |= PRINT_F_UNSIGNED; + fmtint(str, &len, size, + (UINTPTR_T)strvalue, 16, width, + precision, flags); + } + break; + case 'n': + switch (cflags) { + case PRINT_C_CHAR: + charptr = va_arg(args, signed char *); + *charptr = len; + break; + case PRINT_C_SHORT: + shortptr = va_arg(args, short int *); + *shortptr = len; + break; + case PRINT_C_LONG: + longptr = va_arg(args, long int *); + *longptr = len; + break; + case PRINT_C_LLONG: + llongptr = va_arg(args, LLONG *); + *llongptr = len; + break; + case PRINT_C_SIZE: + /* + * C99 says that with the "z" length + * modifier, "a following `n' conversion + * specifier applies to a pointer to a + * signed integer type corresponding to + * size_t argument." (7.19.6.1, 7) + */ + sizeptr = va_arg(args, SSIZE_T *); + *sizeptr = len; + break; + case PRINT_C_INTMAX: + intmaxptr = va_arg(args, INTMAX_T *); + *intmaxptr = len; + break; + case PRINT_C_PTRDIFF: + ptrdiffptr = va_arg(args, PTRDIFF_T *); + *ptrdiffptr = len; + break; + default: + intptr = va_arg(args, int *); + *intptr = len; + break; + } + break; + case '%': /* Print a "%" character verbatim. */ + OUTCHAR(str, len, size, ch); + break; + default: /* Skip other characters. */ + break; + } + ch = *format++; + state = PRINT_S_DEFAULT; + base = cflags = flags = width = 0; + precision = -1; + break; + } +out: + if (len < size) + str[len] = '\0'; + else if (size > 0) + str[size - 1] = '\0'; + + if (overflow || len >= INT_MAX) { + errno = overflow ? EOVERFLOW : ERANGE; + return -1; + } + return (int)len; +} + +static void +fmtstr(char *str, size_t *len, size_t size, const char *value, int width, + int precision, int flags) +{ + int padlen, strln; /* Amount to pad. */ + int noprecision = (precision == -1); + + if (value == NULL) /* We're forgiving. */ + value = "(null)"; + + /* If a precision was specified, don't read the string past it. */ + for (strln = 0; value[strln] != '\0' && + (noprecision || strln < precision); strln++) + continue; + + if ((padlen = width - strln) < 0) + padlen = 0; + if (flags & PRINT_F_MINUS) /* Left justify. */ + padlen = -padlen; + + while (padlen > 0) { /* Leading spaces. */ + OUTCHAR(str, *len, size, ' '); + padlen--; + } + while (*value != '\0' && (noprecision || precision-- > 0)) { + OUTCHAR(str, *len, size, *value); + value++; + } + while (padlen < 0) { /* Trailing spaces. */ + OUTCHAR(str, *len, size, ' '); + padlen++; + } +} + +static void +fmtint(char *str, size_t *len, size_t size, INTMAX_T value, int base, int width, + int precision, int flags) +{ + UINTMAX_T uvalue; + char iconvert[MAX_CONVERT_LENGTH]; + char sign = 0; + char hexprefix = 0; + int spadlen = 0; /* Amount to space pad. */ + int zpadlen = 0; /* Amount to zero pad. */ + int pos; + int separators = (flags & PRINT_F_QUOTE); + int noprecision = (precision == -1); + + if (flags & PRINT_F_UNSIGNED) + uvalue = value; + else { + uvalue = (value >= 0) ? value : -value; + if (value < 0) + sign = '-'; + else if (flags & PRINT_F_PLUS) /* Do a sign. */ + sign = '+'; + else if (flags & PRINT_F_SPACE) + sign = ' '; + } + + pos = convert(uvalue, iconvert, sizeof(iconvert), base, + flags & PRINT_F_UP); + + if (flags & PRINT_F_NUM && uvalue != 0) { + /* + * C99 says: "The result is converted to an `alternative form'. + * For `o' conversion, it increases the precision, if and only + * if necessary, to force the first digit of the result to be a + * zero (if the value and precision are both 0, a single 0 is + * printed). For `x' (or `X') conversion, a nonzero result has + * `0x' (or `0X') prefixed to it." (7.19.6.1, 6) + */ + switch (base) { + case 8: + if (precision <= pos) + precision = pos + 1; + break; + case 16: + hexprefix = (flags & PRINT_F_UP) ? 'X' : 'x'; + break; + } + } + + if (separators) /* Get the number of group separators we'll print. */ + separators = getnumsep(pos); + + zpadlen = precision - pos - separators; + spadlen = width /* Minimum field width. */ + - separators /* Number of separators. */ + - MAX(precision, pos) /* Number of integer digits. */ + - ((sign != 0) ? 1 : 0) /* Will we print a sign? */ + - ((hexprefix != 0) ? 2 : 0); /* Will we print a prefix? */ + + if (zpadlen < 0) + zpadlen = 0; + if (spadlen < 0) + spadlen = 0; + + /* + * C99 says: "If the `0' and `-' flags both appear, the `0' flag is + * ignored. For `d', `i', `o', `u', `x', and `X' conversions, if a + * precision is specified, the `0' flag is ignored." (7.19.6.1, 6) + */ + if (flags & PRINT_F_MINUS) /* Left justify. */ + spadlen = -spadlen; + else if (flags & PRINT_F_ZERO && noprecision) { + zpadlen += spadlen; + spadlen = 0; + } + while (spadlen > 0) { /* Leading spaces. */ + OUTCHAR(str, *len, size, ' '); + spadlen--; + } + if (sign != 0) /* Sign. */ + OUTCHAR(str, *len, size, sign); + if (hexprefix != 0) { /* A "0x" or "0X" prefix. */ + OUTCHAR(str, *len, size, '0'); + OUTCHAR(str, *len, size, hexprefix); + } + while (zpadlen > 0) { /* Leading zeros. */ + OUTCHAR(str, *len, size, '0'); + zpadlen--; + } + while (pos > 0) { /* The actual digits. */ + pos--; + OUTCHAR(str, *len, size, iconvert[pos]); + if (separators > 0 && pos > 0 && pos % 3 == 0) + printsep(str, len, size); + } + while (spadlen < 0) { /* Trailing spaces. */ + OUTCHAR(str, *len, size, ' '); + spadlen++; + } +} + +static void +fmtflt(char *str, size_t *len, size_t size, LDOUBLE fvalue, int width, + int precision, int flags, int *overflow) +{ + LDOUBLE ufvalue; + UINTMAX_T intpart; + UINTMAX_T fracpart; + UINTMAX_T mask; + const char *infnan = NULL; + char iconvert[MAX_CONVERT_LENGTH]; + char fconvert[MAX_CONVERT_LENGTH]; + char econvert[4]; /* "e-12" (without nul-termination). */ + char esign = 0; + char sign = 0; + int leadfraczeros = 0; + int exponent = 0; + int emitpoint = 0; + int omitzeros = 0; + int omitcount = 0; + int padlen = 0; + int epos = 0; + int fpos = 0; + int ipos = 0; + int separators = (flags & PRINT_F_QUOTE); + int estyle = (flags & PRINT_F_TYPE_E); +#if HAVE_LOCALECONV && HAVE_LCONV_DECIMAL_POINT + struct lconv *lc = localeconv(); +#endif /* HAVE_LOCALECONV && HAVE_LCONV_DECIMAL_POINT */ + + /* + * AIX' man page says the default is 0, but C99 and at least Solaris' + * and NetBSD's man pages say the default is 6, and sprintf(3) on AIX + * defaults to 6. + */ + if (precision == -1) + precision = 6; + + if (fvalue < 0.0) + sign = '-'; + else if (flags & PRINT_F_PLUS) /* Do a sign. */ + sign = '+'; + else if (flags & PRINT_F_SPACE) + sign = ' '; + + if (ISNAN(fvalue)) + infnan = (flags & PRINT_F_UP) ? "NAN" : "nan"; + else if (ISINF(fvalue)) + infnan = (flags & PRINT_F_UP) ? "INF" : "inf"; + + if (infnan != NULL) { + if (sign != 0) + iconvert[ipos++] = sign; + while (*infnan != '\0') + iconvert[ipos++] = *infnan++; + fmtstr(str, len, size, iconvert, width, ipos, flags); + return; + } + + /* "%e" (or "%E") or "%g" (or "%G") conversion. */ + if (flags & PRINT_F_TYPE_E || flags & PRINT_F_TYPE_G) { + if (flags & PRINT_F_TYPE_G) { + /* + * For "%g" (and "%G") conversions, the precision + * specifies the number of significant digits, which + * includes the digits in the integer part. The + * conversion will or will not be using "e-style" (like + * "%e" or "%E" conversions) depending on the precision + * and on the exponent. However, the exponent can be + * affected by rounding the converted value, so we'll + * leave this decision for later. Until then, we'll + * assume that we're going to do an "e-style" conversion + * (in order to get the exponent calculated). For + * "e-style", the precision must be decremented by one. + */ + precision--; + /* + * For "%g" (and "%G") conversions, trailing zeros are + * removed from the fractional portion of the result + * unless the "#" flag was specified. + */ + if (!(flags & PRINT_F_NUM)) + omitzeros = 1; + } + exponent = getexponent(fvalue); + estyle = 1; + } + +again: + /* + * Sorry, we only support 9, 19, or 38 digits (that is, the number of + * digits of the 32-bit, the 64-bit, or the 128-bit UINTMAX_MAX value + * minus one) past the decimal point due to our conversion method. + */ + switch (sizeof(UINTMAX_T)) { + case 16: + if (precision > 38) + precision = 38; + break; + case 8: + if (precision > 19) + precision = 19; + break; + default: + if (precision > 9) + precision = 9; + break; + } + + ufvalue = (fvalue >= 0.0) ? fvalue : -fvalue; + if (estyle) /* We want exactly one integer digit. */ + ufvalue /= mypow10(exponent); + + if ((intpart = cast(ufvalue)) == UINTMAX_MAX) { + *overflow = 1; + return; + } + + /* + * Factor of ten with the number of digits needed for the fractional + * part. For example, if the precision is 3, the mask will be 1000. + */ + mask = mypow10(precision); + /* + * We "cheat" by converting the fractional part to integer by + * multiplying by a factor of ten. + */ + if ((fracpart = myround(mask * (ufvalue - intpart))) >= mask) { + /* + * For example, ufvalue = 2.99962, intpart = 2, and mask = 1000 + * (because precision = 3). Now, myround(1000 * 0.99962) will + * return 1000. So, the integer part must be incremented by one + * and the fractional part must be set to zero. + */ + intpart++; + fracpart = 0; + if (estyle && intpart == 10) { + /* + * The value was rounded up to ten, but we only want one + * integer digit if using "e-style". So, the integer + * part must be set to one and the exponent must be + * incremented by one. + */ + intpart = 1; + exponent++; + } + } + + /* + * Now that we know the real exponent, we can check whether or not to + * use "e-style" for "%g" (and "%G") conversions. If we don't need + * "e-style", the precision must be adjusted and the integer and + * fractional parts must be recalculated from the original value. + * + * C99 says: "Let P equal the precision if nonzero, 6 if the precision + * is omitted, or 1 if the precision is zero. Then, if a conversion + * with style `E' would have an exponent of X: + * + * - if P > X >= -4, the conversion is with style `f' (or `F') and + * precision P - (X + 1). + * + * - otherwise, the conversion is with style `e' (or `E') and precision + * P - 1." (7.19.6.1, 8) + * + * Note that we had decremented the precision by one. + */ + if (flags & PRINT_F_TYPE_G && estyle && + precision + 1 > exponent && exponent >= -4) { + precision -= exponent; + estyle = 0; + goto again; + } + + if (estyle) { + if (exponent < 0) { + exponent = -exponent; + esign = '-'; + } else + esign = '+'; + + /* + * Convert the exponent. The sizeof(econvert) is 4. So, the + * econvert buffer can hold e.g. "e+99" and "e-99". We don't + * support an exponent which contains more than two digits. + * Therefore, the following stores are safe. + */ + epos = convert(exponent, econvert, 2, 10, 0); + /* + * C99 says: "The exponent always contains at least two digits, + * and only as many more digits as necessary to represent the + * exponent." (7.19.6.1, 8) + */ + if (epos == 1) + econvert[epos++] = '0'; + econvert[epos++] = esign; + econvert[epos++] = (flags & PRINT_F_UP) ? 'E' : 'e'; + } + + /* Convert the integer part and the fractional part. */ + ipos = convert(intpart, iconvert, sizeof(iconvert), 10, 0); + if (fracpart != 0) /* convert() would return 1 if fracpart == 0. */ + fpos = convert(fracpart, fconvert, sizeof(fconvert), 10, 0); + + leadfraczeros = precision - fpos; + + if (omitzeros) { + if (fpos > 0) /* Omit trailing fractional part zeros. */ + while (omitcount < fpos && fconvert[omitcount] == '0') + omitcount++; + else { /* The fractional part is zero, omit it completely. */ + omitcount = precision; + leadfraczeros = 0; + } + precision -= omitcount; + } + + /* + * Print a decimal point if either the fractional part is non-zero + * and/or the "#" flag was specified. + */ + if (precision > 0 || flags & PRINT_F_NUM) + emitpoint = 1; + if (separators) /* Get the number of group separators we'll print. */ + separators = getnumsep(ipos); + + padlen = width /* Minimum field width. */ + - ipos /* Number of integer digits. */ + - epos /* Number of exponent characters. */ + - precision /* Number of fractional digits. */ + - separators /* Number of group separators. */ + - (emitpoint ? 1 : 0) /* Will we print a decimal point? */ + - ((sign != 0) ? 1 : 0); /* Will we print a sign character? */ + + if (padlen < 0) + padlen = 0; + + /* + * C99 says: "If the `0' and `-' flags both appear, the `0' flag is + * ignored." (7.19.6.1, 6) + */ + if (flags & PRINT_F_MINUS) /* Left justifty. */ + padlen = -padlen; + else if (flags & PRINT_F_ZERO && padlen > 0) { + if (sign != 0) { /* Sign. */ + OUTCHAR(str, *len, size, sign); + sign = 0; + } + while (padlen > 0) { /* Leading zeros. */ + OUTCHAR(str, *len, size, '0'); + padlen--; + } + } + while (padlen > 0) { /* Leading spaces. */ + OUTCHAR(str, *len, size, ' '); + padlen--; + } + if (sign != 0) /* Sign. */ + OUTCHAR(str, *len, size, sign); + while (ipos > 0) { /* Integer part. */ + ipos--; + OUTCHAR(str, *len, size, iconvert[ipos]); + if (separators > 0 && ipos > 0 && ipos % 3 == 0) + printsep(str, len, size); + } + if (emitpoint) { /* Decimal point. */ +#if HAVE_LOCALECONV && HAVE_LCONV_DECIMAL_POINT + if (lc->decimal_point != NULL && *lc->decimal_point != '\0') + OUTCHAR(str, *len, size, *lc->decimal_point); + else /* We'll always print some decimal point character. */ +#endif /* HAVE_LOCALECONV && HAVE_LCONV_DECIMAL_POINT */ + OUTCHAR(str, *len, size, '.'); + } + while (leadfraczeros > 0) { /* Leading fractional part zeros. */ + OUTCHAR(str, *len, size, '0'); + leadfraczeros--; + } + while (fpos > omitcount) { /* The remaining fractional part. */ + fpos--; + OUTCHAR(str, *len, size, fconvert[fpos]); + } + while (epos > 0) { /* Exponent. */ + epos--; + OUTCHAR(str, *len, size, econvert[epos]); + } + while (padlen < 0) { /* Trailing spaces. */ + OUTCHAR(str, *len, size, ' '); + padlen++; + } +} + +static void +printsep(char *str, size_t *len, size_t size) +{ +#if HAVE_LOCALECONV && HAVE_LCONV_THOUSANDS_SEP + struct lconv *lc = localeconv(); + int i; + + if (lc->thousands_sep != NULL) + for (i = 0; lc->thousands_sep[i] != '\0'; i++) + OUTCHAR(str, *len, size, lc->thousands_sep[i]); + else +#endif /* HAVE_LOCALECONV && HAVE_LCONV_THOUSANDS_SEP */ + OUTCHAR(str, *len, size, ','); +} + +static int +getnumsep(int digits) +{ + int separators = (digits - ((digits % 3 == 0) ? 1 : 0)) / 3; +#if HAVE_LOCALECONV && HAVE_LCONV_THOUSANDS_SEP + int strln; + struct lconv *lc = localeconv(); + + /* We support an arbitrary separator length (including zero). */ + if (lc->thousands_sep != NULL) { + for (strln = 0; lc->thousands_sep[strln] != '\0'; strln++) + continue; + separators *= strln; + } +#endif /* HAVE_LOCALECONV && HAVE_LCONV_THOUSANDS_SEP */ + return separators; +} + +static int +getexponent(LDOUBLE value) +{ + LDOUBLE tmp = (value >= 0.0) ? value : -value; + int exponent = 0; + + /* + * We check for 99 > exponent > -99 in order to work around possible + * endless loops which could happen (at least) in the second loop (at + * least) if we're called with an infinite value. However, we checked + * for infinity before calling this function using our ISINF() macro, so + * this might be somewhat paranoid. + */ + while (tmp < 1.0 && tmp > 0.0 && --exponent > -99) + tmp *= 10; + while (tmp >= 10.0 && ++exponent < 99) + tmp /= 10; + + return exponent; +} + +static int +convert(UINTMAX_T value, char *buf, size_t size, int base, int caps) +{ + const char *digits = caps ? "0123456789ABCDEF" : "0123456789abcdef"; + size_t pos = 0; + + /* We return an unterminated buffer with the digits in reverse order. */ + do { + buf[pos++] = digits[value % base]; + value /= base; + } while (value != 0 && pos < size); + + return (int)pos; +} + +static UINTMAX_T +cast(LDOUBLE value) +{ + UINTMAX_T result; + + /* + * We check for ">=" and not for ">" because if UINTMAX_MAX cannot be + * represented exactly as an LDOUBLE value (but is less than LDBL_MAX), + * it may be increased to the nearest higher representable value for the + * comparison (cf. C99: 6.3.1.4, 2). It might then equal the LDOUBLE + * value although converting the latter to UINTMAX_T would overflow. + */ + if (value >= UINTMAX_MAX) + return UINTMAX_MAX; + + result = value; + /* + * At least on NetBSD/sparc64 3.0.2 and 4.99.30, casting long double to + * an integer type converts e.g. 1.9 to 2 instead of 1 (which violates + * the standard). Sigh. + */ + return (result <= value) ? result : result - 1; +} + +static UINTMAX_T +myround(LDOUBLE value) +{ + UINTMAX_T intpart = cast(value); + + return ((value -= intpart) < 0.5) ? intpart : intpart + 1; +} + +static LDOUBLE +mypow10(int exponent) +{ + LDOUBLE result = 1; + + while (exponent > 0) { + result *= 10; + exponent--; + } + while (exponent < 0) { + result /= 10; + exponent++; + } + return result; +} +#endif /* HW_WANT_RPL_VSNPRINTF */ + +#if HW_WANT_RPL_VASPRINTF +#if NEED_MYMEMCPY +void * +mymemcpy(void *dst, void *src, size_t len) +{ + const char *from = src; + char *to = dst; + + /* No need for optimization, we use this only to replace va_copy(3). */ + while (len-- > 0) + *to++ = *from++; + return dst; +} +#endif /* NEED_MYMEMCPY */ + +int +rpl_vasprintf(char **ret, const char *format, va_list ap); + +int +rpl_vasprintf(char **ret, const char *format, va_list ap) +{ + size_t size; + int len; + va_list aq; + + VA_COPY(aq, ap); + len = vsnprintf(NULL, 0, format, aq); + VA_END_COPY(aq); + if (len < 0 || (*ret = malloc(size = len + 1)) == NULL) + return -1; + return vsnprintf(*ret, size, format, ap); +} +#endif /* HW_WANT_RPL_VASPRINTF */ + +#if HW_WANT_RPL_SNPRINTF +#if HAVE_STDARG_H +int +rpl_snprintf(char *str, size_t size, const char *format, ...); + +int +rpl_snprintf(char *str, size_t size, const char *format, ...) +#else +int +rpl_snprintf(va_alist) va_dcl +#endif /* HAVE_STDARG_H */ { +#if !HAVE_STDARG_H + char *str; + size_t size; + char *format; +#endif /* HAVE_STDARG_H */ va_list ap; - int rval; -#ifdef VSPRINTF_CHARSTAR - char *rp; -#endif -#ifdef __STDC__ - va_start(ap, fmt); -#else - va_start(ap); -#endif -#ifdef VSPRINTF_CHARSTAR - rp = vsprintf(str, fmt, ap); + int len; + + VA_START(ap, format); + VA_SHIFT(ap, str, char *); + VA_SHIFT(ap, size, size_t); + VA_SHIFT(ap, format, const char *); + len = vsnprintf(str, size, format, ap); va_end(ap); - return (strlen(rp)); + return len; +} +#endif /* HW_WANT_RPL_SNPRINTF */ + +#if HW_WANT_RPL_ASPRINTF +#if HAVE_STDARG_H +int +rpl_asprintf(char **ret, const char *format, ...); + +int +rpl_asprintf(char **ret, const char *format, ...) #else - rval = vsprintf(str, fmt, ap); +int +rpl_asprintf(va_alist) va_dcl +#endif /* HAVE_STDARG_H */ +{ +#if !HAVE_STDARG_H + char **ret; + char *format; +#endif /* HAVE_STDARG_H */ + va_list ap; + int len; + + VA_START(ap, format); + VA_SHIFT(ap, ret, char **); + VA_SHIFT(ap, format, const char *); + len = vasprintf(ret, format, ap); va_end(ap); - return (rval); -#endif + return len; } +#endif /* HW_WANT_RPL_ASPRINTF */ +#else /* Dummy declaration to avoid empty translation unit warnings. */ +int main(void); +#endif /* HW_WANT_RPL_SNPRINTF || HW_WANT_RPL_VSNPRINTF || HW_WANT_RPL_ASPRINTF || [...] */ +#if TEST_SNPRINTF int -vsnprintf( - char *str, - size_t n, - const char *fmt, - va_list ap - ) +main(void) { -#ifdef VSPRINTF_CHARSTAR - return (strlen(vsprintf(str, fmt, ap))); -#else - return (vsprintf(str, fmt, ap)); -#endif + const char *float_fmt[] = { + /* "%E" and "%e" formats. */ +#if HAVE_LONG_LONG_INT && !OS_BSD && !OS_IRIX + "%.16e", + "%22.16e", + "%022.16e", + "%-22.16e", + "%#+'022.16e", +#endif /* HAVE_LONG_LONG_INT && !OS_BSD && !OS_IRIX */ + "foo|%#+0123.9E|bar", + "%-123.9e", + "%123.9e", + "%+23.9e", + "%+05.8e", + "%-05.8e", + "%05.8e", + "%+5.8e", + "%-5.8e", + "% 5.8e", + "%5.8e", + "%+4.9e", +#if !OS_LINUX /* glibc sometimes gets these wrong. */ + "%+#010.0e", + "%#10.1e", + "%10.5e", + "% 10.5e", + "%5.0e", + "%5.e", + "%#5.0e", + "%#5.e", + "%3.2e", + "%3.1e", + "%-1.5e", + "%1.5e", + "%01.3e", + "%1.e", + "%.1e", + "%#.0e", + "%+.0e", + "% .0e", + "%.0e", + "%#.e", + "%+.e", + "% .e", + "%.e", + "%4e", + "%e", + "%E", +#endif /* !OS_LINUX */ + /* "%F" and "%f" formats. */ +#if !OS_BSD && !OS_IRIX + "% '022f", + "%+'022f", + "%-'22f", + "%'22f", +#if HAVE_LONG_LONG_INT + "%.16f", + "%22.16f", + "%022.16f", + "%-22.16f", + "%#+'022.16f", +#endif /* HAVE_LONG_LONG_INT */ +#endif /* !OS_BSD && !OS_IRIX */ + "foo|%#+0123.9F|bar", + "%-123.9f", + "%123.9f", + "%+23.9f", + "%+#010.0f", + "%#10.1f", + "%10.5f", + "% 10.5f", + "%+05.8f", + "%-05.8f", + "%05.8f", + "%+5.8f", + "%-5.8f", + "% 5.8f", + "%5.8f", + "%5.0f", + "%5.f", + "%#5.0f", + "%#5.f", + "%+4.9f", + "%3.2f", + "%3.1f", + "%-1.5f", + "%1.5f", + "%01.3f", + "%1.f", + "%.1f", + "%#.0f", + "%+.0f", + "% .0f", + "%.0f", + "%#.f", + "%+.f", + "% .f", + "%.f", + "%4f", + "%f", + "%F", + /* "%G" and "%g" formats. */ +#if !OS_BSD && !OS_IRIX && !OS_LINUX + "% '022g", + "%+'022g", + "%-'22g", + "%'22g", +#if HAVE_LONG_LONG_INT + "%.16g", + "%22.16g", + "%022.16g", + "%-22.16g", + "%#+'022.16g", +#endif /* HAVE_LONG_LONG_INT */ +#endif /* !OS_BSD && !OS_IRIX && !OS_LINUX */ + "foo|%#+0123.9G|bar", + "%-123.9g", + "%123.9g", + "%+23.9g", + "%+05.8g", + "%-05.8g", + "%05.8g", + "%+5.8g", + "%-5.8g", + "% 5.8g", + "%5.8g", + "%+4.9g", +#if !OS_LINUX /* glibc sometimes gets these wrong. */ + "%+#010.0g", + "%#10.1g", + "%10.5g", + "% 10.5g", + "%5.0g", + "%5.g", + "%#5.0g", + "%#5.g", + "%3.2g", + "%3.1g", + "%-1.5g", + "%1.5g", + "%01.3g", + "%1.g", + "%.1g", + "%#.0g", + "%+.0g", + "% .0g", + "%.0g", + "%#.g", + "%+.g", + "% .g", + "%.g", + "%4g", + "%g", + "%G", +#endif /* !OS_LINUX */ + NULL + }; + double float_val[] = { + -4.136, + -134.52, + -5.04030201, + -3410.01234, + -999999.999999, + -913450.29876, + -913450.2, + -91345.2, + -9134.2, + -913.2, + -91.2, + -9.2, + -9.9, + 4.136, + 134.52, + 5.04030201, + 3410.01234, + 999999.999999, + 913450.29876, + 913450.2, + 91345.2, + 9134.2, + 913.2, + 91.2, + 9.2, + 9.9, + 9.96, + 9.996, + 9.9996, + 9.99996, + 9.999996, + 9.9999996, + 9.99999996, + 0.99999996, + 0.99999999, + 0.09999999, + 0.00999999, + 0.00099999, + 0.00009999, + 0.00000999, + 0.00000099, + 0.00000009, + 0.00000001, + 0.0000001, + 0.000001, + 0.00001, + 0.0001, + 0.001, + 0.01, + 0.1, + 1.0, + 1.5, + -1.5, + -1.0, + -0.1, +#if !OS_BSD /* BSD sometimes gets these wrong. */ +#ifdef INFINITY + INFINITY, + -INFINITY, +#endif /* defined(INFINITY) */ +#ifdef NAN + NAN, +#endif /* defined(NAN) */ +#endif /* !OS_BSD */ + 0 + }; + const char *long_fmt[] = { + "foo|%0123ld|bar", +#if !OS_IRIX + "% '0123ld", + "%+'0123ld", + "%-'123ld", + "%'123ld", +#endif /* !OS_IRiX */ + "%123.9ld", + "% 123.9ld", + "%+123.9ld", + "%-123.9ld", + "%0123ld", + "% 0123ld", + "%+0123ld", + "%-0123ld", + "%10.5ld", + "% 10.5ld", + "%+10.5ld", + "%-10.5ld", + "%010ld", + "% 010ld", + "%+010ld", + "%-010ld", + "%4.2ld", + "% 4.2ld", + "%+4.2ld", + "%-4.2ld", + "%04ld", + "% 04ld", + "%+04ld", + "%-04ld", + "%5.5ld", + "%+22.33ld", + "%01.3ld", + "%1.5ld", + "%-1.5ld", + "%44ld", + "%4ld", + "%4.0ld", + "%4.ld", + "%.44ld", + "%.4ld", + "%.0ld", + "%.ld", + "%ld", + NULL + }; + long int long_val[] = { +#ifdef LONG_MAX + LONG_MAX, +#endif /* LONG_MAX */ +#ifdef LONG_MIN + LONG_MIN, +#endif /* LONG_MIN */ + -91340, + 91340, + 341, + 134, + 0203, + -1, + 1, + 0 + }; + const char *ulong_fmt[] = { + /* "%u" formats. */ + "foo|%0123lu|bar", +#if !OS_IRIX + "% '0123lu", + "%+'0123lu", + "%-'123lu", + "%'123lu", +#endif /* !OS_IRiX */ + "%123.9lu", + "% 123.9lu", + "%+123.9lu", + "%-123.9lu", + "%0123lu", + "% 0123lu", + "%+0123lu", + "%-0123lu", + "%5.5lu", + "%+22.33lu", + "%01.3lu", + "%1.5lu", + "%-1.5lu", + "%44lu", + "%lu", + /* "%o" formats. */ + "foo|%#0123lo|bar", + "%#123.9lo", + "%# 123.9lo", + "%#+123.9lo", + "%#-123.9lo", + "%#0123lo", + "%# 0123lo", + "%#+0123lo", + "%#-0123lo", + "%#5.5lo", + "%#+22.33lo", + "%#01.3lo", + "%#1.5lo", + "%#-1.5lo", + "%#44lo", + "%#lo", + "%123.9lo", + "% 123.9lo", + "%+123.9lo", + "%-123.9lo", + "%0123lo", + "% 0123lo", + "%+0123lo", + "%-0123lo", + "%5.5lo", + "%+22.33lo", + "%01.3lo", + "%1.5lo", + "%-1.5lo", + "%44lo", + "%lo", + /* "%X" and "%x" formats. */ + "foo|%#0123lX|bar", + "%#123.9lx", + "%# 123.9lx", + "%#+123.9lx", + "%#-123.9lx", + "%#0123lx", + "%# 0123lx", + "%#+0123lx", + "%#-0123lx", + "%#5.5lx", + "%#+22.33lx", + "%#01.3lx", + "%#1.5lx", + "%#-1.5lx", + "%#44lx", + "%#lx", + "%#lX", + "%123.9lx", + "% 123.9lx", + "%+123.9lx", + "%-123.9lx", + "%0123lx", + "% 0123lx", + "%+0123lx", + "%-0123lx", + "%5.5lx", + "%+22.33lx", + "%01.3lx", + "%1.5lx", + "%-1.5lx", + "%44lx", + "%lx", + "%lX", + NULL + }; + unsigned long int ulong_val[] = { +#ifdef ULONG_MAX + ULONG_MAX, +#endif /* ULONG_MAX */ + 91340, + 341, + 134, + 0203, + 1, + 0 + }; + const char *llong_fmt[] = { + "foo|%0123lld|bar", + "%123.9lld", + "% 123.9lld", + "%+123.9lld", + "%-123.9lld", + "%0123lld", + "% 0123lld", + "%+0123lld", + "%-0123lld", + "%5.5lld", + "%+22.33lld", + "%01.3lld", + "%1.5lld", + "%-1.5lld", + "%44lld", + "%lld", + NULL + }; + LLONG llong_val[] = { +#ifdef LLONG_MAX + LLONG_MAX, +#endif /* LLONG_MAX */ +#ifdef LLONG_MIN + LLONG_MIN, +#endif /* LLONG_MIN */ + -91340, + 91340, + 341, + 134, + 0203, + -1, + 1, + 0 + }; + const char *string_fmt[] = { + "foo|%10.10s|bar", + "%-10.10s", + "%10.10s", + "%10.5s", + "%5.10s", + "%10.1s", + "%1.10s", + "%10.0s", + "%0.10s", + "%-42.5s", + "%2.s", + "%.10s", + "%.1s", + "%.0s", + "%.s", + "%4s", + "%s", + NULL + }; + const char *string_val[] = { + "Hello", + "Hello, world!", + "Sound check: One, two, three.", + "This string is a little longer than the other strings.", + "1", + "", + NULL + }; +#if !OS_SYSV /* SysV uses a different format than we do. */ + const char *pointer_fmt[] = { + "foo|%p|bar", + "%42p", + "%p", + NULL + }; + const char *pointer_val[] = { + *pointer_fmt, + *string_fmt, + *string_val, + NULL + }; +#endif /* !OS_SYSV */ + char buf1[1024], buf2[1024]; + double value, digits = 9.123456789012345678901234567890123456789; + int i, j, r1, r2, failed = 0, num = 0; + +/* + * Use -DTEST_NILS in order to also test the conversion of nil values. Might + * segfault on systems which don't support converting a NULL pointer with "%s" + * and lets some test cases fail against BSD and glibc due to bugs in their + * implementations. + */ +#ifndef TEST_NILS +#define TEST_NILS 0 +#elif TEST_NILS +#undef TEST_NILS +#define TEST_NILS 1 +#endif /* !defined(TEST_NILS) */ +#ifdef TEST +#undef TEST +#endif /* defined(TEST) */ +#define TEST(fmt, val) \ +do { \ + for (i = 0; fmt[i] != NULL; i++) \ + for (j = 0; j == 0 || val[j - TEST_NILS] != 0; j++) { \ + r1 = sprintf(buf1, fmt[i], val[j]); \ + r2 = snprintf(buf2, sizeof(buf2), fmt[i], val[j]); \ + if (strcmp(buf1, buf2) != 0 || r1 != r2) { \ + (void)printf("Results don't match, " \ + "format string: %s\n" \ + "\t sprintf(3): [%s] (%d)\n" \ + "\tsnprintf(3): [%s] (%d)\n", \ + fmt[i], buf1, r1, buf2, r2); \ + failed++; \ + } \ + num++; \ + } \ +} while (/* CONSTCOND */ 0) + +#if HAVE_LOCALE_H + (void)setlocale(LC_ALL, ""); +#endif /* HAVE_LOCALE_H */ + + (void)puts("Testing our snprintf(3) against your system's sprintf(3)."); + TEST(float_fmt, float_val); + TEST(long_fmt, long_val); + TEST(ulong_fmt, ulong_val); + TEST(llong_fmt, llong_val); + TEST(string_fmt, string_val); +#if !OS_SYSV /* SysV uses a different format than we do. */ + TEST(pointer_fmt, pointer_val); +#endif /* !OS_SYSV */ + (void)printf("Result: %d out of %d tests failed.\n", failed, num); + + (void)fputs("Checking how many digits we support: ", stdout); + for (i = 0; i < 100; i++) { + value = pow(10, i) * digits; + (void)sprintf(buf1, "%.1f", value); + (void)snprintf(buf2, sizeof(buf2), "%.1f", value); + if (strcmp(buf1, buf2) != 0) { + (void)printf("apparently %d.\n", i); + break; + } + } + return (failed == 0) ? 0 : 1; } -#else -int snprintf_bs; -#endif +#endif /* TEST_SNPRINTF */ + +/* vim: set joinspaces textwidth=80: */ diff --git a/contrib/ntp/libntp/socket.c b/contrib/ntp/libntp/socket.c new file mode 100644 index 000000000..11fb00469 --- /dev/null +++ b/contrib/ntp/libntp/socket.c @@ -0,0 +1,218 @@ +/* + * socket.c - low-level socket operations + */ + +#ifdef HAVE_CONFIG_H +# include +#endif + +#include + +#include "ntp.h" +#include "ntp_io.h" +#include "ntp_net.h" +#include "ntp_debug.h" + +/* + * Windows C runtime ioctl() can't deal properly with sockets, + * map to ioctlsocket for this source file. + */ +#ifdef SYS_WINNT +#define ioctl(fd, opt, val) ioctlsocket(fd, opt, (u_long *)(val)) +#endif + +/* + * on Unix systems the stdio library typically + * makes use of file descriptors in the lower + * integer range. stdio usually will make use + * of the file descriptors in the range of + * [0..FOPEN_MAX) + * in order to keep this range clean, for socket + * file descriptors we attempt to move them above + * FOPEN_MAX. This is not as easy as it sounds as + * FOPEN_MAX changes from implementation to implementation + * and may exceed to current file decriptor limits. + * We are using following strategy: + * - keep a current socket fd boundary initialized with + * max(0, min(GETDTABLESIZE() - FD_CHUNK, FOPEN_MAX)) + * - attempt to move the descriptor to the boundary or + * above. + * - if that fails and boundary > 0 set boundary + * to min(0, socket_fd_boundary - FD_CHUNK) + * -> retry + * if failure and boundary == 0 return old fd + * - on success close old fd return new fd + * + * effects: + * - fds will be moved above the socket fd boundary + * if at all possible. + * - the socket boundary will be reduced until + * allocation is possible or 0 is reached - at this + * point the algrithm will be disabled + */ +SOCKET +move_fd( + SOCKET fd + ) +{ +#if !defined(SYS_WINNT) && defined(F_DUPFD) +#ifndef FD_CHUNK +#define FD_CHUNK 10 +#endif +#ifndef FOPEN_MAX +#define FOPEN_MAX 20 +#endif +/* + * number of fds we would like to have for + * stdio FILE* available. + * we can pick a "low" number as our use of + * FILE* is limited to log files and temporarily + * to data and config files. Except for log files + * we don't keep the other FILE* open beyond the + * scope of the function that opened it. + */ +#ifndef FD_PREFERRED_SOCKBOUNDARY +#define FD_PREFERRED_SOCKBOUNDARY 48 +#endif + + static SOCKET socket_boundary = -1; + SOCKET newfd; + + REQUIRE((int)fd >= 0); + + /* + * check whether boundary has be set up + * already + */ + if (socket_boundary == -1) { + socket_boundary = max(0, min(GETDTABLESIZE() - FD_CHUNK, + min(FOPEN_MAX, FD_PREFERRED_SOCKBOUNDARY))); + TRACE(1, ("move_fd: estimated max descriptors: %d, " + "initial socket boundary: %d\n", + GETDTABLESIZE(), socket_boundary)); + } + + /* + * Leave a space for stdio to work in. potentially moving the + * socket_boundary lower until allocation succeeds. + */ + do { + if (fd >= 0 && fd < socket_boundary) { + /* inside reserved range: attempt to move fd */ + newfd = fcntl(fd, F_DUPFD, socket_boundary); + + if (newfd != -1) { + /* success: drop the old one - return the new one */ + close(fd); + return newfd; + } + } else { + /* outside reserved range: no work - return the original one */ + return fd; + } + socket_boundary = max(0, socket_boundary - FD_CHUNK); + TRACE(1, ("move_fd: selecting new socket boundary: %d\n", + socket_boundary)); + } while (socket_boundary > 0); +#else + ENSURE((int)fd >= 0); +#endif /* !defined(SYS_WINNT) && defined(F_DUPFD) */ + return fd; +} + + +/* + * make_socket_nonblocking() - set up descriptor to be non blocking + */ +void +make_socket_nonblocking( + SOCKET fd + ) +{ + /* + * set non-blocking, + */ + +#ifdef USE_FIONBIO + /* in vxWorks we use FIONBIO, but the others are defined for old + * systems, so all hell breaks loose if we leave them defined + */ +#undef O_NONBLOCK +#undef FNDELAY +#undef O_NDELAY +#endif + +#if defined(O_NONBLOCK) /* POSIX */ + if (fcntl(fd, F_SETFL, O_NONBLOCK) < 0) { + msyslog(LOG_ERR, + "fcntl(O_NONBLOCK) fails on fd #%d: %m", fd); + exit(1); + } +#elif defined(FNDELAY) + if (fcntl(fd, F_SETFL, FNDELAY) < 0) { + msyslog(LOG_ERR, "fcntl(FNDELAY) fails on fd #%d: %m", + fd); + exit(1); + } +#elif defined(O_NDELAY) /* generally the same as FNDELAY */ + if (fcntl(fd, F_SETFL, O_NDELAY) < 0) { + msyslog(LOG_ERR, "fcntl(O_NDELAY) fails on fd #%d: %m", + fd); + exit(1); + } +#elif defined(FIONBIO) + { + int on = 1; + + if (ioctl(fd, FIONBIO, &on) < 0) { + msyslog(LOG_ERR, + "ioctl(FIONBIO) fails on fd #%d: %m", + fd); + exit(1); + } + } +#elif defined(FIOSNBIO) + if (ioctl(fd, FIOSNBIO, &on) < 0) { + msyslog(LOG_ERR, + "ioctl(FIOSNBIO) fails on fd #%d: %m", fd); + exit(1); + } +#else +# include "Bletch: Need non-blocking I/O!" +#endif +} + +#if 0 + +/* The following subroutines should probably be moved here */ + +static SOCKET +open_socket( + sockaddr_u * addr, + int bcast, + int turn_off_reuse, + endpt * interf + ) +void +sendpkt( + sockaddr_u * dest, + struct interface * ep, + int ttl, + struct pkt * pkt, + int len + ) + +static inline int +read_refclock_packet(SOCKET fd, struct refclockio *rp, l_fp ts) + +static inline int +read_network_packet( + SOCKET fd, + struct interface * itf, + l_fp ts + ) + +void +kill_asyncio(int startfd) + +#endif /* 0 */ diff --git a/contrib/ntp/libntp/socktoa.c b/contrib/ntp/libntp/socktoa.c index fb41b22a0..98abe7c42 100644 --- a/contrib/ntp/libntp/socktoa.c +++ b/contrib/ntp/libntp/socktoa.c @@ -1,56 +1,170 @@ /* - * socktoa - return a numeric host name from a sockaddr_storage structure + * socktoa.c socktoa(), sockporttoa(), and sock_hash() */ +#ifdef HAVE_CONFIG_H #include +#endif #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif +#ifdef HAVE_NETINET_IN_H #include - -#include - -#ifdef ISC_PLATFORM_NEEDNTOP -#include #endif #include +#include +#include +#include +#include #include "ntp_fp.h" #include "lib_strbuf.h" #include "ntp_stdlib.h" #include "ntp.h" -char * +/* + * socktoa - return a numeric host name from a sockaddr_storage structure + */ +const char * socktoa( - struct sockaddr_storage* sock + const sockaddr_u *sock ) { - register char *buffer; + int saved_errno; + char * res; + char * addr; + u_long scope; - LIB_GETBUF(buffer); + saved_errno = socket_errno(); + LIB_GETBUF(res); - if (sock == NULL) - strcpy(buffer, "null"); - else - { + if (NULL == sock) { + strlcpy(res, "(null)", LIB_BUFLENGTH); + } else { + switch(AF(sock)) { - switch(sock->ss_family) { + case AF_INET: + case AF_UNSPEC: + inet_ntop(AF_INET, PSOCK_ADDR4(sock), res, + LIB_BUFLENGTH); + break; - default: - case AF_INET : - inet_ntop(AF_INET, &GET_INADDR(*sock), buffer, - LIB_BUFLENGTH); + case AF_INET6: + inet_ntop(AF_INET6, PSOCK_ADDR6(sock), res, + LIB_BUFLENGTH); + scope = SCOPE_VAR(sock); + if (0 != scope && !strchr(res, '%')) { + addr = res; + LIB_GETBUF(res); + snprintf(res, LIB_BUFLENGTH, "%s%%%lu", + addr, scope); + res[LIB_BUFLENGTH - 1] = '\0'; + } break; - case AF_INET6 : - inet_ntop(AF_INET6, &GET_INADDR6(*sock), buffer, - LIB_BUFLENGTH); -#if 0 default: - strcpy(buffer, "unknown"); -#endif + snprintf(res, LIB_BUFLENGTH, + "(socktoa unknown family %d)", + AF(sock)); } } - return buffer; + errno = saved_errno; + + return res; +} + + +const char * +sockporttoa( + const sockaddr_u *sock + ) +{ + int saved_errno; + const char * atext; + char * buf; + + saved_errno = socket_errno(); + atext = socktoa(sock); + LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, + (IS_IPV6(sock)) + ? "[%s]:%hu" + : "%s:%hu", + atext, SRCPORT(sock)); + errno = saved_errno; + + return buf; +} + + +/* + * sock_hash - hash a sockaddr_u structure + */ +u_short +sock_hash( + const sockaddr_u *addr + ) +{ + u_int hashVal; + u_int j; + size_t len; + const u_char *pch; + + hashVal = 0; + len = 0; + + /* + * We can't just hash the whole thing because there are hidden + * fields in sockaddr_in6 that might be filled in by recvfrom(), + * so just use the family, port and address. + */ + pch = (const void *)&AF(addr); + hashVal = 37 * hashVal + *pch; + if (sizeof(AF(addr)) > 1) { + pch++; + hashVal = 37 * hashVal + *pch; + } + switch(AF(addr)) { + case AF_INET: + pch = (const void *)&SOCK_ADDR4(addr); + len = sizeof(SOCK_ADDR4(addr)); + break; + + case AF_INET6: + pch = (const void *)&SOCK_ADDR6(addr); + len = sizeof(SOCK_ADDR6(addr)); + break; + } + + for (j = 0; j < len ; j++) + hashVal = 37 * hashVal + pch[j]; + + return (u_short)(hashVal & USHRT_MAX); +} + + +int +sockaddr_masktoprefixlen( + const sockaddr_u * psa + ) +{ + isc_netaddr_t isc_na; + isc_sockaddr_t isc_sa; + u_int pfxlen; + isc_result_t result; + int rc; + + ZERO(isc_sa); + memcpy(&isc_sa.type, psa, + min(sizeof(isc_sa.type), sizeof(*psa))); + isc_netaddr_fromsockaddr(&isc_na, &isc_sa); + result = isc_netaddr_masktoprefixlen(&isc_na, &pfxlen); + rc = (ISC_R_SUCCESS == result) + ? (int)pfxlen + : -1; + + return rc; } diff --git a/contrib/ntp/libntp/socktohost.c b/contrib/ntp/libntp/socktohost.c index 7aafdc710..3d9ab960e 100644 --- a/contrib/ntp/libntp/socktohost.c +++ b/contrib/ntp/libntp/socktohost.c @@ -1,9 +1,14 @@ /* * socktoa - return a numeric host name from a sockaddr_storage structure */ +#include #include +#ifdef HAVE_SYS_SOCKET_H #include +#endif +#ifdef HAVE_NETINET_IN_H #include +#endif #include @@ -13,19 +18,93 @@ #include "lib_strbuf.h" #include "ntp_stdlib.h" #include "ntp.h" +#include "ntp_debug.h" -char * +const char * socktohost( - struct sockaddr_storage* sock + const sockaddr_u *sock ) { - register char *buffer; + const char svc[] = "ntp"; + char * pbuf; + char * pliar; + int gni_flags; + struct addrinfo hints; + struct addrinfo * alist; + struct addrinfo * ai; + sockaddr_u addr; + size_t octets; + int a_info; - LIB_GETBUF(buffer); - if (getnameinfo((struct sockaddr *)sock, SOCKLEN(sock), buffer, - LIB_BUFLENGTH /* NI_MAXHOST*/, NULL, 0, 0)) - return stoa(sock); + /* reverse the address to purported DNS name */ + LIB_GETBUF(pbuf); + gni_flags = NI_DGRAM | NI_NAMEREQD; + if (getnameinfo(&sock->sa, SOCKLEN(sock), pbuf, LIB_BUFLENGTH, + NULL, 0, gni_flags)) + return stoa(sock); /* use address */ - return buffer; + TRACE(1, ("%s reversed to %s\n", stoa(sock), pbuf)); + + /* + * Resolve the reversed name and make sure the reversed address + * is among the results. + */ + ZERO(hints); + hints.ai_family = AF(sock); + hints.ai_protocol = IPPROTO_UDP; + hints.ai_socktype = SOCK_DGRAM; + hints.ai_flags = 0; + alist = NULL; + + a_info = getaddrinfo(pbuf, svc, &hints, &alist); + if (a_info == EAI_NONAME +#ifdef EAI_NODATA + || a_info == EAI_NODATA +#endif + ) { + hints.ai_flags = AI_CANONNAME; +#ifdef AI_ADDRCONFIG + hints.ai_flags |= AI_ADDRCONFIG; +#endif + a_info = getaddrinfo(pbuf, svc, &hints, &alist); + } +#ifdef AI_ADDRCONFIG + /* Some older implementations don't like AI_ADDRCONFIG. */ + if (a_info == EAI_BADFLAGS) { + hints.ai_flags &= ~AI_ADDRCONFIG; + a_info = getaddrinfo(pbuf, svc, &hints, &alist); + } +#endif + if (a_info) + goto forward_fail; + + INSIST(alist != NULL); + + for (ai = alist; ai != NULL; ai = ai->ai_next) { + /* + * Make a convenience sockaddr_u copy from ai->ai_addr + * because casting from sockaddr * to sockaddr_u * is + * risking alignment problems on platforms where + * sockaddr_u has stricter alignment than sockaddr, + * such as sparc. + */ + ZERO_SOCK(&addr); + octets = min(sizeof(addr), ai->ai_addrlen); + memcpy(&addr, ai->ai_addr, octets); + if (SOCK_EQ(sock, &addr)) + break; + } + freeaddrinfo(alist); + + if (ai != NULL) + return pbuf; /* forward check passed */ + + forward_fail: + TRACE(1, ("%s forward check lookup fail: %s\n", pbuf, + gai_strerror(a_info))); + LIB_GETBUF(pliar); + snprintf(pliar, LIB_BUFLENGTH, "%s (%s)", stoa(sock), pbuf); + + return pliar; } diff --git a/contrib/ntp/libntp/ssl_init.c b/contrib/ntp/libntp/ssl_init.c new file mode 100644 index 000000000..a9d1d546d --- /dev/null +++ b/contrib/ntp/libntp/ssl_init.c @@ -0,0 +1,187 @@ +/* + * ssl_init.c Common OpenSSL initialization code for the various + * programs which use it. + * + * Moved from ntpd/ntp_crypto.c crypto_setup() + */ +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include +#include +#include + +#ifdef OPENSSL +#include "openssl/err.h" +#include "openssl/evp.h" + +void atexit_ssl_cleanup(void); + +int ssl_init_done; + +void +ssl_init(void) +{ + init_lib(); + + if (ssl_init_done) + return; + + ERR_load_crypto_strings(); + OpenSSL_add_all_algorithms(); + atexit(&atexit_ssl_cleanup); + + ssl_init_done = TRUE; +} + + +void +atexit_ssl_cleanup(void) +{ + if (!ssl_init_done) + return; + + ssl_init_done = FALSE; + EVP_cleanup(); + ERR_free_strings(); +} + + +void +ssl_check_version(void) +{ + if ((SSLeay() ^ OPENSSL_VERSION_NUMBER) & ~0xff0L) { + msyslog(LOG_WARNING, + "OpenSSL version mismatch. Built against %lx, you have %lx", + (u_long)OPENSSL_VERSION_NUMBER, SSLeay()); + fprintf(stderr, + "OpenSSL version mismatch. Built against %lx, you have %lx\n", + (u_long)OPENSSL_VERSION_NUMBER, SSLeay()); + } + + INIT_SSL(); +} +#endif /* OPENSSL */ + + +/* + * keytype_from_text returns OpenSSL NID for digest by name, and + * optionally the associated digest length. + * + * Used by ntpd authreadkeys(), ntpq and ntpdc keytype() + */ +int +keytype_from_text( + const char *text, + size_t *pdigest_len + ) +{ + int key_type; + u_int digest_len; +#ifdef OPENSSL + const u_long max_digest_len = MAX_MAC_LEN - sizeof(keyid_t); + u_char digest[EVP_MAX_MD_SIZE]; + char * upcased; + char * pch; + EVP_MD_CTX ctx; + + /* + * OpenSSL digest short names are capitalized, so uppercase the + * digest name before passing to OBJ_sn2nid(). If it is not + * recognized but begins with 'M' use NID_md5 to be consistent + * with past behavior. + */ + INIT_SSL(); + LIB_GETBUF(upcased); + strlcpy(upcased, text, LIB_BUFLENGTH); + for (pch = upcased; '\0' != *pch; pch++) + *pch = (char)toupper((unsigned char)*pch); + key_type = OBJ_sn2nid(upcased); +#else + key_type = 0; +#endif + + if (!key_type && 'm' == tolower((unsigned char)text[0])) + key_type = NID_md5; + + if (!key_type) + return 0; + + if (NULL != pdigest_len) { +#ifdef OPENSSL + EVP_DigestInit(&ctx, EVP_get_digestbynid(key_type)); + EVP_DigestFinal(&ctx, digest, &digest_len); + if (digest_len > max_digest_len) { + fprintf(stderr, + "key type %s %u octet digests are too big, max %lu\n", + keytype_name(key_type), digest_len, + max_digest_len); + msyslog(LOG_ERR, + "key type %s %u octet digests are too big, max %lu", + keytype_name(key_type), digest_len, + max_digest_len); + return 0; + } +#else + digest_len = 16; +#endif + *pdigest_len = digest_len; + } + + return key_type; +} + + +/* + * keytype_name returns OpenSSL short name for digest by NID. + * + * Used by ntpq and ntpdc keytype() + */ +const char * +keytype_name( + int nid + ) +{ + static const char unknown_type[] = "(unknown key type)"; + const char *name; + +#ifdef OPENSSL + INIT_SSL(); + name = OBJ_nid2sn(nid); + if (NULL == name) + name = unknown_type; +#else /* !OPENSSL follows */ + if (NID_md5 == nid) + name = "MD5"; + else + name = unknown_type; +#endif + return name; +} + + +/* + * Use getpassphrase() if configure.ac detected it, as Suns that + * have it truncate the password in getpass() to 8 characters. + */ +#ifdef HAVE_GETPASSPHRASE +# define getpass(str) getpassphrase(str) +#endif + +/* + * getpass_keytype() -- shared between ntpq and ntpdc, only vaguely + * related to the rest of ssl_init.c. + */ +char * +getpass_keytype( + int keytype + ) +{ + char pass_prompt[64 + 11 + 1]; /* 11 for " Password: " */ + + snprintf(pass_prompt, sizeof(pass_prompt), + "%.64s Password: ", keytype_name(keytype)); + + return getpass(pass_prompt); +} diff --git a/contrib/ntp/libntp/statestr.c b/contrib/ntp/libntp/statestr.c index 85552b3ab..313cd46be 100644 --- a/contrib/ntp/libntp/statestr.c +++ b/contrib/ntp/libntp/statestr.c @@ -12,118 +12,191 @@ #include "ntp_refclock.h" #include "ntp_control.h" #include "ntp_string.h" +#ifdef KERNEL_PLL +# include "ntp_syscall.h" +#endif + /* * Structure for turning various constants into a readable string. */ struct codestring { int code; - const char *string; + const char * const string; }; /* - * Leap values + * Leap status (leap) */ -static -struct codestring leap_codes[] = { +static const struct codestring leap_codes[] = { { LEAP_NOWARNING, "leap_none" }, { LEAP_ADDSECOND, "leap_add_sec" }, { LEAP_DELSECOND, "leap_del_sec" }, - { LEAP_NOTINSYNC, "sync_alarm" }, - { -1, "leap" } + { LEAP_NOTINSYNC, "leap_alarm" }, + { -1, "leap" } }; /* - * Clock source + * Clock source status (sync) */ -static -struct codestring sync_codes[] = { +static const struct codestring sync_codes[] = { { CTL_SST_TS_UNSPEC, "sync_unspec" }, - { CTL_SST_TS_ATOM, "sync_atomic" }, - { CTL_SST_TS_LF, "sync_lf_clock" }, - { CTL_SST_TS_HF, "sync_hf_clock" }, - { CTL_SST_TS_UHF, "sync_uhf_clock" }, - { CTL_SST_TS_LOCAL, "sync_local_proto" }, + { CTL_SST_TS_ATOM, "sync_pps" }, + { CTL_SST_TS_LF, "sync_lf_radio" }, + { CTL_SST_TS_HF, "sync_hf_radio" }, + { CTL_SST_TS_UHF, "sync_uhf_radio" }, + { CTL_SST_TS_LOCAL, "sync_local" }, { CTL_SST_TS_NTP, "sync_ntp" }, - { CTL_SST_TS_UDPTIME, "sync_udp/time" }, + { CTL_SST_TS_UDPTIME, "sync_other" }, { CTL_SST_TS_WRSTWTCH, "sync_wristwatch" }, { CTL_SST_TS_TELEPHONE, "sync_telephone" }, { -1, "sync" } }; - /* - * Peer selection + * Peer selection status (sel) */ -static -struct codestring select_codes[] = { - { CTL_PST_SEL_REJECT, "selreject" }, +static const struct codestring select_codes[] = { + { CTL_PST_SEL_REJECT, "sel_reject" }, { CTL_PST_SEL_SANE, "sel_falsetick" }, { CTL_PST_SEL_CORRECT, "sel_excess" }, - { CTL_PST_SEL_SELCAND, "sel_outlyer" }, - { CTL_PST_SEL_SYNCCAND, "sel_candidat" }, - { CTL_PST_SEL_DISTSYSPEER, "sel_selected" }, + { CTL_PST_SEL_SELCAND, "sel_outlier" }, + { CTL_PST_SEL_SYNCCAND, "sel_candidate" }, + { CTL_PST_SEL_EXCESS, "sel_backup" }, { CTL_PST_SEL_SYSPEER, "sel_sys.peer" }, { CTL_PST_SEL_PPS, "sel_pps.peer" }, { -1, "sel" } }; - /* - * Clock status + * Clock status (clk) */ -static -struct codestring clock_codes[] = { - { CTL_CLK_OKAY, "clk_okay" }, - { CTL_CLK_NOREPLY, "clk_noreply" }, - { CTL_CLK_BADFORMAT, "clk_badformat" }, +static const struct codestring clock_codes[] = { + { CTL_CLK_OKAY, "clk_unspec" }, + { CTL_CLK_NOREPLY, "clk_no_reply" }, + { CTL_CLK_BADFORMAT, "clk_bad_format" }, { CTL_CLK_FAULT, "clk_fault" }, - { CTL_CLK_PROPAGATION, "clk_badsignal" }, - { CTL_CLK_BADDATE, "clk_baddate" }, - { CTL_CLK_BADTIME, "clk_badtime" }, + { CTL_CLK_PROPAGATION, "clk_bad_signal" }, + { CTL_CLK_BADDATE, "clk_bad_date" }, + { CTL_CLK_BADTIME, "clk_bad_time" }, { -1, "clk" } }; +#ifdef FLASH_CODES_UNUSED +/* + * Flash bits -- see ntpq.c tstflags & tstflagnames + */ +static const struct codestring flash_codes[] = { + { TEST1, "pkt_dup" }, + { TEST2, "pkt_bogus" }, + { TEST3, "pkt_unsync" }, + { TEST4, "pkt_denied" }, + { TEST5, "pkt_auth" }, + { TEST6, "pkt_stratum" }, + { TEST7, "pkt_header" }, + { TEST8, "pkt_autokey" }, + { TEST9, "pkt_crypto" }, + { TEST10, "peer_stratum" }, + { TEST11, "peer_dist" }, + { TEST12, "peer_loop" }, + { TEST13, "peer_unreach" }, + { -1, "flash" } +}; +#endif + + /* - * System Events + * System events (sys) */ -static -struct codestring sys_codes[] = { - { EVNT_UNSPEC, "event_unspec" }, - { EVNT_SYSRESTART, "event_restart" }, - { EVNT_SYSFAULT, "event_fault" }, - { EVNT_SYNCCHG, "event_sync_chg" }, - { EVNT_PEERSTCHG, "event_peer/strat_chg" }, - { EVNT_CLOCKRESET, "event_clock_reset" }, - { EVNT_BADDATETIM, "event_bad_date" }, - { EVNT_CLOCKEXCPT, "event_clock_excptn" }, - { -1, "event" } +static const struct codestring sys_codes[] = { + { EVNT_UNSPEC, "unspecified" }, + { EVNT_NSET, "freq_not_set" }, + { EVNT_FSET, "freq_set" }, + { EVNT_SPIK, "spike_detect" }, + { EVNT_FREQ, "freq_mode" }, + { EVNT_SYNC, "clock_sync" }, + { EVNT_SYSRESTART, "restart" }, + { EVNT_SYSFAULT, "panic_stop" }, + { EVNT_NOPEER, "no_sys_peer" }, + { EVNT_ARMED, "leap_armed" }, + { EVNT_DISARMED, "leap_disarmed" }, + { EVNT_LEAP, "leap_event" }, + { EVNT_CLOCKRESET, "clock_step" }, + { EVNT_KERN, "kern" }, + { EVNT_TAI, "TAI" }, + { EVNT_LEAPVAL, "stale_leapsecond_values" }, + { -1, "" } }; /* - * Peer events + * Peer events (peer) */ -static -struct codestring peer_codes[] = { - { EVNT_UNSPEC, "event_unspec" }, - { EVNT_PEERIPERR & ~PEER_EVENT, "event_ip_err" }, - { EVNT_PEERAUTH & ~PEER_EVENT, "event_authen" }, - { EVNT_UNREACH & ~PEER_EVENT, "event_unreach" }, - { EVNT_REACH & ~PEER_EVENT, "event_reach" }, - { EVNT_PEERCLOCK & ~PEER_EVENT, "event_peer_clock" }, -#if 0 - { EVNT_PEERSTRAT & ~PEER_EVENT, "event_stratum_chg" }, -#endif - { -1, "event" } +static const struct codestring peer_codes[] = { + { PEVNT_MOBIL & ~PEER_EVENT, "mobilize" }, + { PEVNT_DEMOBIL & ~PEER_EVENT, "demobilize" }, + { PEVNT_UNREACH & ~PEER_EVENT, "unreachable" }, + { PEVNT_REACH & ~PEER_EVENT, "reachable" }, + { PEVNT_RESTART & ~PEER_EVENT, "restart" }, + { PEVNT_REPLY & ~PEER_EVENT, "no_reply" }, + { PEVNT_RATE & ~PEER_EVENT, "rate_exceeded" }, + { PEVNT_DENY & ~PEER_EVENT, "access_denied" }, + { PEVNT_ARMED & ~PEER_EVENT, "leap_armed" }, + { PEVNT_NEWPEER & ~PEER_EVENT, "sys_peer" }, + { PEVNT_CLOCK & ~PEER_EVENT, "clock_event" }, + { PEVNT_AUTH & ~PEER_EVENT, "bad_auth" }, + { PEVNT_POPCORN & ~PEER_EVENT, "popcorn" }, + { PEVNT_XLEAVE & ~PEER_EVENT, "interleave_mode" }, + { PEVNT_XERR & ~PEER_EVENT, "interleave_error" }, + { -1, "" } +}; + +/* + * Peer status bits + */ +static const struct codestring peer_st_bits[] = { + { CTL_PST_CONFIG, "conf" }, + { CTL_PST_AUTHENABLE, "authenb" }, + { CTL_PST_AUTHENTIC, "auth" }, + { CTL_PST_REACH, "reach" }, + { CTL_PST_BCAST, "bcast" }, + /* not used with getcode(), no terminating entry needed */ +}; + +/* + * Restriction match bits + */ +static const struct codestring res_match_bits[] = { + { RESM_NTPONLY, "ntpport" }, + { RESM_INTERFACE, "interface" }, + { RESM_SOURCE, "source" }, + /* not used with getcode(), no terminating entry needed */ +}; + +/* + * Restriction access bits + */ +static const struct codestring res_access_bits[] = { + { RES_IGNORE, "ignore" }, + { RES_DONTSERVE, "noserve" }, + { RES_DONTTRUST, "notrust" }, + { RES_NOQUERY, "noquery" }, + { RES_NOMODIFY, "nomodify" }, + { RES_NOPEER, "nopeer" }, + { RES_NOTRAP, "notrap" }, + { RES_LPTRAP, "lptrap" }, + { RES_LIMITED, "limited" }, + { RES_VERSION, "version" }, + { RES_KOD, "kod" }, + { RES_FLAKE, "flake" }, + /* not used with getcode(), no terminating entry needed */ }; -#ifdef OPENSSL +#ifdef AUTOKEY /* - * Crypto events + * Crypto events (cryp) */ -static -struct codestring crypto_codes[] = { +static const struct codestring crypto_codes[] = { { XEVNT_OK & ~CRPT_EVENT, "success" }, { XEVNT_LEN & ~CRPT_EVENT, "bad_field_format_or_length" }, { XEVNT_TSP & ~CRPT_EVENT, "bad_timestamp" }, @@ -134,38 +207,98 @@ struct codestring crypto_codes[] = { { XEVNT_SGL & ~CRPT_EVENT, "bad_signature_length" }, { XEVNT_SIG & ~CRPT_EVENT, "signature_not_verified" }, { XEVNT_VFY & ~CRPT_EVENT, "certificate_not_verified" }, - { XEVNT_PER & ~CRPT_EVENT, "host certificate_expired" }, + { XEVNT_PER & ~CRPT_EVENT, "host_certificate_expired" }, { XEVNT_CKY & ~CRPT_EVENT, "bad_or_missing_cookie" }, - { XEVNT_DAT & ~CRPT_EVENT, "bad_or_missing_leapsecond_table" }, + { XEVNT_DAT & ~CRPT_EVENT, "bad_or_missing_leapseconds" }, { XEVNT_CRT & ~CRPT_EVENT, "bad_or_missing_certificate" }, - { XEVNT_ID & ~CRPT_EVENT, "bad_or_missing_group_key" }, + { XEVNT_ID & ~CRPT_EVENT, "bad_or_missing_group key" }, { XEVNT_ERR & ~CRPT_EVENT, "protocol_error" }, - { XEVNT_SRV & ~CRPT_EVENT, "server certificate expired" }, - { -1, "crypto" } + { -1, "" } +}; +#endif /* AUTOKEY */ + +#ifdef KERNEL_PLL +/* + * kernel discipline status bits + */ +static const struct codestring k_st_bits[] = { +# ifdef STA_PLL + { STA_PLL, "pll" }, +# endif +# ifdef STA_PPSFREQ + { STA_PPSFREQ, "ppsfreq" }, +# endif +# ifdef STA_PPSTIME + { STA_PPSTIME, "ppstime" }, +# endif +# ifdef STA_FLL + { STA_FLL, "fll" }, +# endif +# ifdef STA_INS + { STA_INS, "ins" }, +# endif +# ifdef STA_DEL + { STA_DEL, "del" }, +# endif +# ifdef STA_UNSYNC + { STA_UNSYNC, "unsync" }, +# endif +# ifdef STA_FREQHOLD + { STA_FREQHOLD, "freqhold" }, +# endif +# ifdef STA_PPSSIGNAL + { STA_PPSSIGNAL, "ppssignal" }, +# endif +# ifdef STA_PPSJITTER + { STA_PPSJITTER, "ppsjitter" }, +# endif +# ifdef STA_PPSWANDER + { STA_PPSWANDER, "ppswander" }, +# endif +# ifdef STA_PPSERROR + { STA_PPSERROR, "ppserror" }, +# endif +# ifdef STA_CLOCKERR + { STA_CLOCKERR, "clockerr" }, +# endif +# ifdef STA_NANO + { STA_NANO, "nano" }, +# endif +# ifdef STA_MODE + { STA_MODE, "mode=fll" }, +# endif +# ifdef STA_CLK + { STA_CLK, "src=B" }, +# endif + /* not used with getcode(), no terminating entry needed */ }; -#endif /* OPENSSL */ +#endif /* KERNEL_PLL */ /* Forwards */ -static const char *getcode P((int, struct codestring *)); -static const char *getevents P((int)); +static const char * getcode(int, const struct codestring *); +static const char * getevents(int); +static const char * peer_st_flags(u_char pst); /* * getcode - return string corresponding to code */ static const char * getcode( - int code, - struct codestring *codetab + int code, + const struct codestring * codetab ) { - static char buf[30]; + char * buf; while (codetab->code != -1) { if (codetab->code == code) - return codetab->string; + return codetab->string; codetab++; } - (void) sprintf(buf, "%s_%d", codetab->string, code); + + LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%s_%d", codetab->string, code); + return buf; } @@ -177,14 +310,124 @@ getevents( int cnt ) { - static char buf[20]; + char * buf; if (cnt == 0) - return "no events"; - (void) sprintf(buf, "%d event%s", cnt, (cnt==1) ? "" : "s"); + return "no events"; + + LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%d event%s", cnt, + (1 == cnt) + ? "" + : "s"); + + return buf; +} + + +/* + * decode_bitflags() + * + * returns a human-readable string with a keyword from tab for each bit + * set in bits, separating multiple entries with text of sep2. + */ +static const char * +decode_bitflags( + int bits, + const char * sep2, + const struct codestring * tab, + size_t tab_ct + ) +{ + const char * sep; + char * buf; + char * pch; + char * lim; + size_t b; + int rc; + int saved_errno; /* for use in DPRINTF with %m */ + + saved_errno = errno; + LIB_GETBUF(buf); + pch = buf; + lim = buf + LIB_BUFLENGTH; + sep = ""; + + for (b = 0; b < tab_ct; b++) { + if (tab[b].code & bits) { + rc = snprintf(pch, (lim - pch), "%s%s", sep, + tab[b].string); + if (rc < 0) + goto toosmall; + pch += (u_int)rc; + if (pch >= lim) + goto toosmall; + sep = sep2; + } + } + + return buf; + + toosmall: + snprintf(buf, LIB_BUFLENGTH, + "decode_bitflags(%s) can't decode 0x%x in %d bytes", + (tab == peer_st_bits) + ? "peer_st" + : +#ifdef KERNEL_PLL + (tab == k_st_bits) + ? "kern_st" + : +#endif + "", + bits, (int)LIB_BUFLENGTH); + errno = saved_errno; + return buf; } + +static const char * +peer_st_flags( + u_char pst + ) +{ + return decode_bitflags(pst, ", ", peer_st_bits, + COUNTOF(peer_st_bits)); +} + + +const char * +res_match_flags( + u_short mf + ) +{ + return decode_bitflags(mf, " ", res_match_bits, + COUNTOF(res_match_bits)); +} + + +const char * +res_access_flags( + u_short af + ) +{ + return decode_bitflags(af, " ", res_access_bits, + COUNTOF(res_access_bits)); +} + + +#ifdef KERNEL_PLL +const char * +k_st_flags( + u_int32 st + ) +{ + return decode_bitflags(st, " ", k_st_bits, COUNTOF(k_st_bits)); +} +#endif /* KERNEL_PLL */ + + /* * statustoa - return a descriptive string for a peer status */ @@ -194,66 +437,43 @@ statustoa( int st ) { - char *cb; - u_char pst; + char * cb; + char * cc; + u_char pst; LIB_GETBUF(cb); switch (type) { - case TYPE_SYS: - (void)strcpy(cb, getcode(CTL_SYS_LI(st), leap_codes)); - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(CTL_SYS_SOURCE(st) & ~CTL_SST_TS_PPS, sync_codes)); - if (CTL_SYS_SOURCE(st) & CTL_SST_TS_PPS) - (void)strcat(cb, "/PPS"); - (void)strcat(cb, ", "); - (void)strcat(cb, getevents(CTL_SYS_NEVNT(st))); - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(CTL_SYS_EVENT(st), sys_codes)); + + case TYPE_SYS: + snprintf(cb, LIB_BUFLENGTH, "%s, %s, %s, %s", + getcode(CTL_SYS_LI(st), leap_codes), + getcode(CTL_SYS_SOURCE(st), sync_codes), + getevents(CTL_SYS_NEVNT(st)), + getcode(CTL_SYS_EVENT(st), sys_codes)); break; - case TYPE_PEER: - /* - * Handcraft the bits - */ - pst = (u_char) CTL_PEER_STATVAL(st); - if (!(pst & CTL_PST_REACH)) { - (void)strcpy(cb, "unreach"); - } else { - (void)strcpy(cb, "reach"); - - } - if (pst & CTL_PST_CONFIG) - (void)strcat(cb, ", conf"); - if (pst & CTL_PST_AUTHENABLE) { - if (!(pst & CTL_PST_REACH) || (pst & CTL_PST_AUTHENTIC)) - (void)strcat(cb, ", auth"); - else - (void)strcat(cb, ", unauth"); - } - - /* - * Now the codes - */ - if ((pst & 0x7) != CTL_PST_SEL_REJECT) { - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(pst & 0x7, select_codes)); - } - (void)strcat(cb, ", "); - (void)strcat(cb, getevents(CTL_PEER_NEVNT(st))); + case TYPE_PEER: + pst = (u_char)CTL_PEER_STATVAL(st); + snprintf(cb, LIB_BUFLENGTH, "%s, %s, %s", + peer_st_flags(pst), + getcode(pst & 0x7, select_codes), + getevents(CTL_PEER_NEVNT(st))); if (CTL_PEER_EVENT(st) != EVNT_UNSPEC) { - (void)strcat(cb, ", "); - (void)strcat(cb, getcode(CTL_PEER_EVENT(st), - peer_codes)); + cc = cb + strlen(cb); + snprintf(cc, LIB_BUFLENGTH - (cc - cb), ", %s", + getcode(CTL_PEER_EVENT(st), + peer_codes)); } break; - case TYPE_CLOCK: - (void)strcpy(cb, getcode(((st)>>8) & 0xff, clock_codes)); - (void)strcat(cb, ", last_"); - (void)strcat(cb, getcode((st) & 0xff, clock_codes)); + case TYPE_CLOCK: + snprintf(cb, LIB_BUFLENGTH, "%s, %s", + getevents(CTL_SYS_NEVNT(st)), + getcode((st) & 0xf, clock_codes)); break; } + return cb; } @@ -264,10 +484,10 @@ eventstr( { if (num & PEER_EVENT) return (getcode(num & ~PEER_EVENT, peer_codes)); -#ifdef OPENSSL +#ifdef AUTOKEY else if (num & CRPT_EVENT) return (getcode(num & ~CRPT_EVENT, crypto_codes)); -#endif /* OPENSSL */ +#endif /* AUTOKEY */ else return (getcode(num, sys_codes)); } @@ -279,27 +499,3 @@ ceventstr( { return getcode(num, clock_codes); } - -const char * -sysstatstr( - int status - ) -{ - return statustoa(TYPE_SYS, status); -} - -const char * -peerstatstr( - int status - ) -{ - return statustoa(TYPE_PEER, status); -} - -const char * -clockstatstr( - int status - ) -{ - return statustoa(TYPE_CLOCK, status); -} diff --git a/contrib/ntp/libntp/strdup.c b/contrib/ntp/libntp/strdup.c index 2e26ba7a5..62d5a16d4 100644 --- a/contrib/ntp/libntp/strdup.c +++ b/contrib/ntp/libntp/strdup.c @@ -1,8 +1,10 @@ -#include "ntp_malloc.h" +#include -#if !HAVE_STRDUP +#include +#include "ntp_malloc.h" +#include -#define NULL 0 +#ifndef HAVE_STRDUP char *strdup(const char *s); @@ -11,18 +13,17 @@ strdup( const char *s ) { - char *cp; + size_t octets; + char * cp; + + REQUIRE(s); + octets = strlen(s) + 1; + if ((cp = malloc(octets)) == NULL) + return NULL; + memcpy(cp, s, octets); - if (s) { - cp = (char *) malloc((unsigned) (strlen(s)+1)); - if (cp) { - (void) strcpy(cp, s); - } - } else { - cp = (char *) NULL; - } - return(cp); + return cp; } #else -int strdup_bs; +int strdup_c_nonempty_compilation_unit; #endif diff --git a/contrib/ntp/libntp/strl_obsd.c b/contrib/ntp/libntp/strl_obsd.c new file mode 100644 index 000000000..cb8d4f359 --- /dev/null +++ b/contrib/ntp/libntp/strl_obsd.c @@ -0,0 +1,123 @@ +/* + * Why use strlcpy()/strlcat() instead of standard strncpy()/strncat()? + * To reduce likelihood of bugs and avoid wasteful zero fills. See: + * http://www.gratisoft.us/todd/papers/strlcpy.html + */ + +/* $OpenBSD: strlcpy.c,v 1.11 2006/05/05 15:27:38 millert Exp $ */ + +/* + * Copyright (c) 1998 Todd C. Miller + * + * Permission to use, copy, modify, and distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include /* + marks local changes */ +#ifdef HAVE_SYS_TYPES_H /* + */ +#include +#endif /* + */ +#include + +#include "ntp_stdlib.h" /* + strlcpy, strlcat prototypes */ + +#ifndef HAVE_STRLCPY /* + */ +/* + * Copy src to string dst of size siz. At most siz-1 characters + * will be copied. Always NUL terminates (unless siz == 0). + * Returns strlen(src); if retval >= siz, truncation occurred. + */ +size_t +strlcpy(char *dst, const char *src, size_t siz) +{ + char *d = dst; + const char *s = src; + size_t n = siz; + + /* Copy as many bytes as will fit */ + if (n != 0) { + while (--n != 0) { + if ((*d++ = *s++) == '\0') + break; + } + } + + /* Not enough room in dst, add NUL and traverse rest of src */ + if (n == 0) { + if (siz != 0) + *d = '\0'; /* NUL-terminate dst */ + while (*s++) + ; + } + + return(s - src - 1); /* count does not include NUL */ +} +#endif /* + */ + + +/* $OpenBSD: strlcat.c,v 1.13 2005/08/08 08:05:37 espie Exp $ */ + +/* + * Copyright (c) 1998 Todd C. Miller + * + * Permission to use, copy, modify, and distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +/* #include */ /* + */ +/* #include */ /* + */ + +#ifndef HAVE_STRLCAT /* + */ +/* + * Appends src to string dst of size siz (unlike strncat, siz is the + * full size of dst, not space left). At most siz-1 characters + * will be copied. Always NUL terminates (unless siz <= strlen(dst)). + * Returns strlen(src) + MIN(siz, strlen(initial dst)). + * If retval >= siz, truncation occurred. + */ +size_t +strlcat(char *dst, const char *src, size_t siz) +{ + char *d = dst; + const char *s = src; + size_t n = siz; + size_t dlen; + + /* Find the end of dst and adjust bytes left but don't go past end */ + while (n-- != 0 && *d != '\0') + d++; + dlen = d - dst; + n = siz - dlen; + + if (n == 0) + return(dlen + strlen(s)); + while (*s != '\0') { + if (n != 1) { + *d++ = *s; + n--; + } + s++; + } + *d = '\0'; + + return(dlen + (s - src)); /* count does not include NUL */ +} +#endif /* + */ diff --git a/contrib/ntp/libntp/strstr.c b/contrib/ntp/libntp/strstr.c deleted file mode 100644 index a4deb8701..000000000 --- a/contrib/ntp/libntp/strstr.c +++ /dev/null @@ -1,52 +0,0 @@ -#include - -#if !HAVE_STRSTR - -/* - * Amanda, The Advanced Maryland Automatic Network Disk Archiver - * Copyright (c) 1991-1998 University of Maryland at College Park - * All Rights Reserved. - * - * Permission to use, copy, modify, distribute, and sell this software and its - * documentation for any purpose is hereby granted without fee, provided that - * the above copyright notice appear in all copies and that both that - * copyright notice and this permission notice appear in supporting - * documentation, and that the name of U.M. not be used in advertising or - * publicity pertaining to distribution of the software without specific, - * written prior permission. U.M. makes no representations about the - * suitability of this software for any purpose. It is provided "as is" - * without express or implied warranty. - * - * U.M. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL U.M. - * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES - * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION - * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN - * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - * - * Author: James da Silva, Systems Design and Analysis Group - * Computer Science Department - * University of Maryland at College Park - */ -/* - * $Id$ - * - * replacement for missing ANSI-C strstr function - */ - -char *strstr(a, b) -char *a, *b; -{ - int alen, blen, i; - - alen = strlen(a); - blen = strlen(b); - - for(i=0; i <= alen-blen; i++, a++) - if(strncmp(a, b, blen) == 0) return a; - - return NULL; -} -#else -int strstr_bs; -#endif diff --git a/contrib/ntp/libntp/syssignal.c b/contrib/ntp/libntp/syssignal.c index 6ec4c4c16..5e496a95f 100644 --- a/contrib/ntp/libntp/syssignal.c +++ b/contrib/ntp/libntp/syssignal.c @@ -9,64 +9,50 @@ #include "ntp_syslog.h" #include "ntp_stdlib.h" +static ctrl_c_fn ctrl_c_hook; +#ifndef SYS_WINNT +RETSIGTYPE sigint_handler(int); +#else +BOOL WINAPI console_event_handler(DWORD); +#endif + + #ifdef HAVE_SIGACTION +# ifdef SA_RESTART +# define Z_SA_RESTART SA_RESTART +# else +# define Z_SA_RESTART 0 +# endif + void signal_no_reset( -#if defined(__STDC__) || defined(HAVE_STDARG_H) int sig, - void (*func) (int) -#else - sig, func -#endif + void (*func)(int) ) -#if defined(__STDC__) || defined(HAVE_STDARG_H) -#else - int sig; - void (*func) P((int)); -#endif { int n; struct sigaction vec; + struct sigaction ovec; - vec.sa_handler = func; + ZERO(vec); sigemptyset(&vec.sa_mask); -#if 0 -#ifdef SA_RESTART - vec.sa_flags = SA_RESTART; -#else - vec.sa_flags = 0; -#endif -#else - vec.sa_flags = 0; -#endif + vec.sa_handler = func; -#ifdef SA_RESTART -/* Added for PPS clocks on Solaris 7 which get EINTR errors */ + /* Added for PPS clocks on Solaris 7 which get EINTR errors */ # ifdef SIGPOLL - if (sig == SIGPOLL) vec.sa_flags = SA_RESTART; + if (SIGPOLL == sig) + vec.sa_flags = Z_SA_RESTART; # endif # ifdef SIGIO - if (sig == SIGIO) vec.sa_flags = SA_RESTART; + if (SIGIO == sig) + vec.sa_flags = Z_SA_RESTART; # endif -#endif - - while (1) - { - struct sigaction ovec; + do n = sigaction(sig, &vec, &ovec); - if (n == -1 && errno == EINTR) continue; - if (ovec.sa_flags -#ifdef SA_RESTART - && ovec.sa_flags != SA_RESTART -#endif - ) - msyslog(LOG_DEBUG, "signal_no_reset: signal %d had flags %x", - sig, ovec.sa_flags); - break; - } - if (n == -1) { + while (-1 == n && EINTR == errno); + if (-1 == n) { perror("sigaction"); exit(1); } @@ -77,16 +63,16 @@ signal_no_reset( void signal_no_reset( int sig, - RETSIGTYPE (*func) (int) + RETSIGTYPE (*func)(int) ) { struct sigvec sv; int n; - bzero((char *) &sv, sizeof(sv)); + ZERO(sv); sv.sv_handler = func; n = sigvec(sig, &sv, (struct sigvec *)NULL); - if (n == -1) { + if (-1 == n) { perror("sigvec"); exit(1); } @@ -97,13 +83,13 @@ signal_no_reset( void signal_no_reset( int sig, - RETSIGTYPE (*func) (int) + RETSIGTYPE (*func)(int) ) { int n; n = sigset(sig, func); - if (n == -1) { + if (-1 == n) { perror("sigset"); exit(1); } @@ -115,19 +101,88 @@ signal_no_reset( void signal_no_reset( int sig, - RETSIGTYPE (*func) (int) + RETSIGTYPE (*func)(int) ) { -#ifdef SIG_ERR - if (SIG_ERR == signal(sig, func)) { -#else - int n; - n = signal(sig, func); - if (n == -1) { +#ifndef SIG_ERR +# define SIG_ERR (-1) #endif + if (SIG_ERR == signal(sig, func)) { perror("signal"); exit(1); } } #endif + +#ifndef SYS_WINNT +/* + * POSIX implementation of set_ctrl_c_hook() + */ +RETSIGTYPE +sigint_handler( + int signum + ) +{ + UNUSED_ARG(signum); + if (ctrl_c_hook != NULL) + (*ctrl_c_hook)(); +} + +void +set_ctrl_c_hook( + ctrl_c_fn c_hook + ) +{ + RETSIGTYPE (*handler)(int); + + if (NULL == c_hook) { + handler = SIG_DFL; + ctrl_c_hook = NULL; + } else { + handler = &sigint_handler; + ctrl_c_hook = c_hook; + } + signal_no_reset(SIGINT, handler); +} +#else /* SYS_WINNT follows */ +/* + * Windows implementation of set_ctrl_c_hook() + */ +BOOL WINAPI +console_event_handler( + DWORD dwCtrlType + ) +{ + BOOL handled; + + if (CTRL_C_EVENT == dwCtrlType && ctrl_c_hook != NULL) { + (*ctrl_c_hook)(); + handled = TRUE; + } else { + handled = FALSE; + } + + return handled; +} +void +set_ctrl_c_hook( + ctrl_c_fn c_hook + ) +{ + BOOL install; + + if (NULL == c_hook) { + ctrl_c_hook = NULL; + install = FALSE; + } else { + ctrl_c_hook = c_hook; + install = TRUE; + } + if (!SetConsoleCtrlHandler(&console_event_handler, install)) + msyslog(LOG_ERR, "Can't %s console control handler: %m", + (install) + ? "add" + : "remove"); +} +#endif /* SYS_WINNT */ diff --git a/contrib/ntp/libntp/systime.c b/contrib/ntp/libntp/systime.c index 4539b5fec..f5eabcd1c 100644 --- a/contrib/ntp/libntp/systime.c +++ b/contrib/ntp/libntp/systime.c @@ -4,17 +4,16 @@ * ATTENTION: Get approval from Dave Mills on all changes to this file! * */ -#include "ntp_machine.h" -#include "ntp_fp.h" +#include + +#include "ntp.h" #include "ntp_syslog.h" -#include "ntp_unixtime.h" #include "ntp_stdlib.h" #include "ntp_random.h" -#include "ntpd.h" /* for sys_precision */ - -#ifdef SIM -# include "ntpsim.h" -#endif /*SIM */ +#include "iosignal.h" +#include "timevalops.h" +#include "timespecops.h" +#include "ntp_calendar.h" #ifdef HAVE_SYS_PARAM_H # include @@ -26,27 +25,135 @@ # include #endif /* HAVE_UTMPX_H */ + +#ifndef USE_COMPILETIME_PIVOT +# define USE_COMPILETIME_PIVOT 1 +#endif + /* * These routines (get_systime, step_systime, adj_systime) implement an * interface between the system independent NTP clock and the Unix - * system clock in various architectures and operating systems. + * system clock in various architectures and operating systems. Time is + * a precious quantity in these routines and every effort is made to + * minimize errors by unbiased rounding and amortizing adjustment + * residues. + * + * In order to improve the apparent resolution, provide unbiased + * rounding and most importantly ensure that the readings cannot be + * predicted, the low-order unused portion of the time below the minimum + * time to read the clock is filled with an unbiased random fuzz. * - * Time is a precious quantity in these routines and every effort is - * made to minimize errors by always rounding toward zero and amortizing - * adjustment residues. By default the adjustment quantum is 1 us for - * the usual Unix tickadj() system call, but this can be increased if - * necessary by the tick configuration command. For instance, when the - * adjtime() quantum is a clock tick for a 100-Hz clock, the quantum - * should be 10 ms. + * The sys_tick variable specifies the system clock tick interval in + * seconds, for stepping clocks, defined as those which return times + * less than MINSTEP greater than the previous reading. For systems that + * use a high-resolution counter such that each clock reading is always + * at least MINSTEP greater than the prior, sys_tick is the time to read + * the system clock. + * + * The sys_fuzz variable measures the minimum time to read the system + * clock, regardless of its precision. When reading the system clock + * using get_systime() after sys_tick and sys_fuzz have been determined, + * ntpd ensures each unprocessed clock reading is no less than sys_fuzz + * later than the prior unprocessed reading, and then fuzzes the bits + * below sys_fuzz in the timestamp returned, ensuring each of its + * resulting readings is strictly later than the previous. + * + * When slewing the system clock using adj_systime() (with the kernel + * loop discipline unavailable or disabled), adjtime() offsets are + * quantized to sys_tick, if sys_tick is greater than sys_fuzz, which + * is to say if the OS presents a stepping clock. Otherwise, offsets + * are quantized to the microsecond resolution of adjtime()'s timeval + * input. The remaining correction sys_residual is carried into the + * next adjtime() and meanwhile is also factored into get_systime() + * readings. */ -#if defined RELIANTUNIX_CLOCK || defined SCO5_CLOCK -double sys_tick = 10e-3; /* 10 ms tickadj() */ -#else -double sys_tick = 1e-6; /* 1 us tickadj() */ -#endif +double sys_tick = 0; /* tick size or time to read (s) */ +double sys_fuzz = 0; /* min. time to read the clock (s) */ +long sys_fuzz_nsec = 0; /* min. time to read the clock (ns) */ +double measured_tick; /* non-overridable sys_tick (s) */ double sys_residual = 0; /* adjustment residue (s) */ +int trunc_os_clock; /* sys_tick > measured_tick */ +time_stepped_callback step_callback; #ifndef SIM +/* perlinger@ntp.org: As 'get_sysime()' does it's own check for clock + * backstepping, this could probably become a local variable in + * 'get_systime()' and the cruft associated with communicating via a + * static value could be removed after the v4.2.8 release. + */ +static int lamport_violated; /* clock was stepped back */ +#endif /* !SIM */ + +#ifdef DEBUG +static int systime_init_done; +# define DONE_SYSTIME_INIT() systime_init_done = TRUE +#else +# define DONE_SYSTIME_INIT() do {} while (FALSE) +#endif + +#ifdef HAVE_SIGNALED_IO +int using_sigio; +#endif + +#ifdef SYS_WINNT +CRITICAL_SECTION get_systime_cs; +#endif + + +void +set_sys_fuzz( + double fuzz_val + ) +{ + sys_fuzz = fuzz_val; + INSIST(sys_fuzz >= 0); + INSIST(sys_fuzz <= 1.0); + sys_fuzz_nsec = (long)(sys_fuzz * 1e9 + 0.5); +} + + +void +init_systime(void) +{ + INIT_GET_SYSTIME_CRITSEC(); + INIT_WIN_PRECISE_TIME(); + DONE_SYSTIME_INIT(); +} + + +#ifndef SIM /* ntpsim.c has get_systime() and friends for sim */ + +static inline void +get_ostime( + struct timespec * tsp + ) +{ + int rc; + long ticks; + +#if defined(HAVE_CLOCK_GETTIME) + rc = clock_gettime(CLOCK_REALTIME, tsp); +#elif defined(HAVE_GETCLOCK) + rc = getclock(TIMEOFDAY, tsp); +#else + struct timeval tv; + + rc = GETTIMEOFDAY(&tv, NULL); + tsp->tv_sec = tv.tv_sec; + tsp->tv_nsec = tv.tv_usec * 1000; +#endif + if (rc < 0) { + msyslog(LOG_ERR, "read system clock failed: %m (%d)", + errno); + exit(1); + } + + if (trunc_os_clock) { + ticks = (long)((tsp->tv_nsec * 1e-9) / sys_tick); + tsp->tv_nsec = (long)(ticks * 1e9 * sys_tick); + } +} + /* * get_systime - return system time in NTP timestamp format. @@ -56,59 +163,110 @@ get_systime( l_fp *now /* system time */ ) { - double dtemp; - -#if defined(HAVE_CLOCK_GETTIME) || defined(HAVE_GETCLOCK) + static struct timespec ts_last; /* last sampled os time */ + static struct timespec ts_prev; /* prior os time */ + static l_fp lfp_prev; /* prior result */ + static double dfuzz_prev; /* prior fuzz */ struct timespec ts; /* seconds and nanoseconds */ + struct timespec ts_min; /* earliest permissible */ + struct timespec ts_lam; /* lamport fictional increment */ + struct timespec ts_prev_log; /* for msyslog only */ + double dfuzz; + double ddelta; + l_fp result; + l_fp lfpfuzz; + l_fp lfpdelta; + + get_ostime(&ts); + DEBUG_REQUIRE(systime_init_done); + ENTER_GET_SYSTIME_CRITSEC(); + + /* First check if here was a Lamport violation, that is, two + * successive calls to 'get_ostime()' resulted in negative + * time difference. Use a few milliseconds of permissible + * tolerance -- being too sharp can hurt here. (This is intented + * for the Win32 target, where the HPC interpolation might + * introduce small steps backward. It should not be an issue on + * systems where get_ostime() results in a true syscall.) + */ + if (cmp_tspec(add_tspec_ns(ts, 50000000), ts_last) < 0) + lamport_violated = 1; + ts_last = ts; /* - * Convert Unix clock from seconds and nanoseconds to seconds. - * The bottom is only two bits down, so no need for fuzz. - * Some systems don't have that level of precision, however... + * After default_get_precision() has set a nonzero sys_fuzz, + * ensure every reading of the OS clock advances by at least + * sys_fuzz over the prior reading, thereby assuring each + * fuzzed result is strictly later than the prior. Limit the + * necessary fiction to 1 second. */ -# ifdef HAVE_CLOCK_GETTIME - clock_gettime(CLOCK_REALTIME, &ts); -# else - getclock(TIMEOFDAY, &ts); -# endif - now->l_i = ts.tv_sec + JAN_1970; - dtemp = ts.tv_nsec / 1e9; + if (!USING_SIGIO()) { + ts_min = add_tspec_ns(ts_prev, sys_fuzz_nsec); + if (cmp_tspec(ts, ts_min) < 0) { + ts_lam = sub_tspec(ts_min, ts); + if (ts_lam.tv_sec > 0 && !lamport_violated) { + msyslog(LOG_ERR, + "get_systime Lamport advance exceeds one second (%.9f)", + ts_lam.tv_sec + + 1e-9 * ts_lam.tv_nsec); + exit(1); + } + if (!lamport_violated) + ts = ts_min; + } + ts_prev_log = ts_prev; + ts_prev = ts; + } else { + /* + * Quiet "ts_prev_log.tv_sec may be used uninitialized" + * warning from x86 gcc 4.5.2. + */ + ZERO(ts_prev_log); + } -#else /* HAVE_CLOCK_GETTIME || HAVE_GETCLOCK */ - struct timeval tv; /* seconds and microseconds */ + /* convert from timespec to l_fp fixed-point */ + result = tspec_stamp_to_lfp(ts); /* - * Convert Unix clock from seconds and microseconds to seconds. - * Add in unbiased random fuzz beneath the microsecond. + * Add in the fuzz. */ - GETTIMEOFDAY(&tv, NULL); - now->l_i = tv.tv_sec + JAN_1970; - dtemp = tv.tv_usec / 1e6; - -#endif /* HAVE_CLOCK_GETTIME || HAVE_GETCLOCK */ + dfuzz = ntp_random() * 2. / FRAC * sys_fuzz; + DTOLFP(dfuzz, &lfpfuzz); + L_ADD(&result, &lfpfuzz); /* - * ntp_random() produces 31 bits (always nonnegative). - * This bit is done only after the precision has been + * Ensure result is strictly greater than prior result (ignoring + * sys_residual's effect for now) once sys_fuzz has been * determined. */ - if (sys_precision != 0) - dtemp += (ntp_random() / FRAC - .5) / (1 << - -sys_precision); - - /* - * Renormalize to seconds past 1900 and fraction. - */ - dtemp += sys_residual; - if (dtemp >= 1) { - dtemp -= 1; - now->l_i++; - } else if (dtemp < 0) { - dtemp += 1; - now->l_i--; + if (!USING_SIGIO()) { + if (!L_ISZERO(&lfp_prev) && !lamport_violated) { + if (!L_ISGTU(&result, &lfp_prev) && + sys_fuzz > 0.) { + msyslog(LOG_ERR, "ts_prev %s ts_min %s", + tspectoa(ts_prev_log), + tspectoa(ts_min)); + msyslog(LOG_ERR, "ts %s", tspectoa(ts)); + msyslog(LOG_ERR, "sys_fuzz %ld nsec, prior fuzz %.9f", + sys_fuzz_nsec, dfuzz_prev); + msyslog(LOG_ERR, "this fuzz %.9f", + dfuzz); + lfpdelta = lfp_prev; + L_SUB(&lfpdelta, &result); + LFPTOD(&lfpdelta, ddelta); + msyslog(LOG_ERR, + "prev get_systime 0x%x.%08x is %.9f later than 0x%x.%08x", + lfp_prev.l_ui, lfp_prev.l_uf, + ddelta, result.l_ui, result.l_uf); + } + } + lfp_prev = result; + dfuzz_prev = dfuzz; + if (lamport_violated) + lamport_violated = FALSE; } - dtemp *= FRAC; - now->l_uf = (u_int32)dtemp; + LEAVE_GET_SYSTIME_CRITSEC(); + *now = result; } @@ -123,10 +281,23 @@ adj_systime( { struct timeval adjtv; /* new adjustment */ struct timeval oadjtv; /* residual adjustment */ + double quant; /* quantize to multiples of */ double dtemp; long ticks; int isneg = 0; + /* + * The Windows port adj_systime() depends on being called each + * second even when there's no additional correction, to allow + * emulation of adjtime() behavior on top of an API that simply + * sets the current rate. This POSIX implementation needs to + * ignore invocations with zero correction, otherwise ongoing + * EVNT_NSET adjtime() can be aborted by a tiny adjtime() + * triggered by sys_residual. + */ + if (0. == now) + return TRUE; + /* * Most Unix adjtime() implementations adjust the system clock * in microsecond quanta, but some adjust in 10-ms quanta. We @@ -140,8 +311,12 @@ adj_systime( } adjtv.tv_sec = (long)dtemp; dtemp -= adjtv.tv_sec; - ticks = (long)(dtemp / sys_tick + .5); - adjtv.tv_usec = (long)(ticks * sys_tick * 1e6); + if (sys_tick > sys_fuzz) + quant = sys_tick; + else + quant = 1e-6; + ticks = (long)(dtemp / quant + .5); + adjtv.tv_usec = (long)(ticks * quant * 1e6); dtemp -= adjtv.tv_usec / 1e6; sys_residual = dtemp; @@ -158,10 +333,10 @@ adj_systime( if (adjtv.tv_sec != 0 || adjtv.tv_usec != 0) { if (adjtime(&adjtv, &oadjtv) < 0) { msyslog(LOG_ERR, "adj_systime: %m"); - return (0); + return FALSE; } } - return (1); + return TRUE; } #endif @@ -169,68 +344,90 @@ adj_systime( /* * step_systime - step the system clock. */ + int step_systime( - double now + double step ) { - struct timeval timetv, adjtv, oldtimetv; - int isneg = 0; - double dtemp; -#if defined(HAVE_CLOCK_GETTIME) || defined(HAVE_GETCLOCK) - struct timespec ts; -#endif + time_t pivot; /* for ntp era unfolding */ + struct timeval timetv, tvlast, tvdiff; + struct timespec timets; + struct calendar jd; + l_fp fp_ofs, fp_sys; /* offset and target system time in FP */ - dtemp = sys_residual + now; - if (dtemp < 0) { - isneg = 1; - dtemp = - dtemp; - adjtv.tv_sec = (int32)dtemp; - adjtv.tv_usec = (u_int32)((dtemp - - (double)adjtv.tv_sec) * 1e6 + .5); + /* + * Get pivot time for NTP era unfolding. Since we don't step + * very often, we can afford to do the whole calculation from + * scratch. And we're not in the time-critical path yet. + */ +#if SIZEOF_TIME_T > 4 + /* + * This code makes sure the resulting time stamp for the new + * system time is in the 2^32 seconds starting at 1970-01-01, + * 00:00:00 UTC. + */ + pivot = 0x80000000; +#if USE_COMPILETIME_PIVOT + /* + * Add the compile time minus 10 years to get a possible target + * area of (compile time - 10 years) to (compile time + 126 + * years). This should be sufficient for a given binary of + * NTPD. + */ + if (ntpcal_get_build_date(&jd)) { + jd.year -= 10; + pivot += ntpcal_date_to_time(&jd); } else { - adjtv.tv_sec = (int32)dtemp; - adjtv.tv_usec = (u_int32)((dtemp - - (double)adjtv.tv_sec) * 1e6 + .5); + msyslog(LOG_ERR, + "step-systime: assume 1970-01-01 as build date"); } -#if defined(HAVE_CLOCK_GETTIME) || defined(HAVE_GETCLOCK) -# ifdef HAVE_CLOCK_GETTIME - (void) clock_gettime(CLOCK_REALTIME, &ts); -# else - (void) getclock(TIMEOFDAY, &ts); -# endif - timetv.tv_sec = ts.tv_sec; - timetv.tv_usec = ts.tv_nsec / 1000; -#else /* not HAVE_GETCLOCK */ - (void) GETTIMEOFDAY(&timetv, (struct timezone *)0); -#endif /* not HAVE_GETCLOCK */ - - oldtimetv = timetv; - -#ifdef DEBUG - if (debug) - printf("step_systime: step %.6f residual %.6f\n", now, sys_residual); +#else + UNUSED_LOCAL(jd); +#endif /* USE_COMPILETIME_PIVOT */ +#else + UNUSED_LOCAL(jd); + /* This makes sure the resulting time stamp is on or after + * 1969-12-31/23:59:59 UTC and gives us additional two years, + * from the change of NTP era in 2036 to the UNIX rollover in + * 2038. (Minus one second, but that won't hurt.) We *really* + * need a longer 'time_t' after that! Or a different baseline, + * but that would cause other serious trouble, too. + */ + pivot = 0x7FFFFFFF; #endif - if (isneg) { - timetv.tv_sec -= adjtv.tv_sec; - timetv.tv_usec -= adjtv.tv_usec; - if (timetv.tv_usec < 0) { - timetv.tv_sec--; - timetv.tv_usec += 1000000; - } - } else { - timetv.tv_sec += adjtv.tv_sec; - timetv.tv_usec += adjtv.tv_usec; - if (timetv.tv_usec >= 1000000) { - timetv.tv_sec++; - timetv.tv_usec -= 1000000; - } - } + + /* get the complete jump distance as l_fp */ + DTOLFP(sys_residual, &fp_sys); + DTOLFP(step, &fp_ofs); + L_ADD(&fp_ofs, &fp_sys); + + /* ---> time-critical path starts ---> */ + + /* get the current time as l_fp (without fuzz) and as struct timeval */ + get_ostime(&timets); + fp_sys = tspec_stamp_to_lfp(timets); + tvlast.tv_sec = timets.tv_sec; + tvlast.tv_usec = (timets.tv_nsec + 500) / 1000; + + /* get the target time as l_fp */ + L_ADD(&fp_sys, &fp_ofs); + + /* unfold the new system time */ + timetv = lfp_stamp_to_tval(fp_sys, &pivot); + + /* now set new system time */ if (ntp_set_tod(&timetv, NULL) != 0) { msyslog(LOG_ERR, "step-systime: %m"); - return (0); + return FALSE; } + + /* <--- time-critical path ended with 'ntp_set_tod()' <--- */ + sys_residual = 0; + lamport_violated = (step < 0); + if (step_callback) + (*step_callback)(); #ifdef NEED_HPUX_ADJTIME /* @@ -260,8 +457,8 @@ step_systime( * * This might become even Uglier... */ - if (oldtimetv.tv_sec != timetv.tv_sec) - { + tvdiff = abs_tval(sub_tval(timetv, tvlast)); + if (tvdiff.tv_sec > 0) { #ifdef HAVE_UTMP_H struct utmp ut; #endif @@ -270,24 +467,29 @@ step_systime( #endif #ifdef HAVE_UTMP_H - memset((char *)&ut, 0, sizeof(ut)); + ZERO(ut); #endif #ifdef HAVE_UTMPX_H - memset((char *)&utx, 0, sizeof(utx)); + ZERO(utx); #endif /* UTMP */ #ifdef UPDATE_UTMP # ifdef HAVE_PUTUTLINE +# ifndef _PATH_UTMP +# define _PATH_UTMP UTMP_FILE +# endif + utmpname(_PATH_UTMP); ut.ut_type = OLD_TIME; - (void)strcpy(ut.ut_line, OTIME_MSG); - ut.ut_time = oldtimetv.tv_sec; - pututline(&ut); + strlcpy(ut.ut_line, OTIME_MSG, sizeof(ut.ut_line)); + ut.ut_time = tvlast.tv_sec; setutent(); + pututline(&ut); ut.ut_type = NEW_TIME; - (void)strcpy(ut.ut_line, NTIME_MSG); + strlcpy(ut.ut_line, NTIME_MSG, sizeof(ut.ut_line)); ut.ut_time = timetv.tv_sec; + setutent(); pututline(&ut); endutent(); # else /* not HAVE_PUTUTLINE */ @@ -299,13 +501,14 @@ step_systime( #ifdef UPDATE_UTMPX # ifdef HAVE_PUTUTXLINE utx.ut_type = OLD_TIME; - (void)strcpy(utx.ut_line, OTIME_MSG); - utx.ut_tv = oldtimetv; - pututxline(&utx); + strlcpy(utx.ut_line, OTIME_MSG, sizeof(utx.ut_line)); + utx.ut_tv = tvlast; setutxent(); + pututxline(&utx); utx.ut_type = NEW_TIME; - (void)strcpy(utx.ut_line, NTIME_MSG); + strlcpy(utx.ut_line, NTIME_MSG, sizeof(utx.ut_line)); utx.ut_tv = timetv; + setutxent(); pututxline(&utx); endutxent(); # else /* not HAVE_PUTUTXLINE */ @@ -316,14 +519,19 @@ step_systime( #ifdef UPDATE_WTMP # ifdef HAVE_PUTUTLINE - utmpname(WTMP_FILE); +# ifndef _PATH_WTMP +# define _PATH_WTMP WTMP_FILE +# endif + utmpname(_PATH_WTMP); ut.ut_type = OLD_TIME; - (void)strcpy(ut.ut_line, OTIME_MSG); - ut.ut_time = oldtimetv.tv_sec; + strlcpy(ut.ut_line, OTIME_MSG, sizeof(ut.ut_line)); + ut.ut_time = tvlast.tv_sec; + setutent(); pututline(&ut); ut.ut_type = NEW_TIME; - (void)strcpy(ut.ut_line, NTIME_MSG); + strlcpy(ut.ut_line, NTIME_MSG, sizeof(ut.ut_line)); ut.ut_time = timetv.tv_sec; + setutent(); pututline(&ut); endutent(); # else /* not HAVE_PUTUTLINE */ @@ -335,8 +543,8 @@ step_systime( #ifdef UPDATE_WTMPX # ifdef HAVE_PUTUTXLINE utx.ut_type = OLD_TIME; - utx.ut_tv = oldtimetv; - (void)strcpy(utx.ut_line, OTIME_MSG); + utx.ut_tv = tvlast; + strlcpy(utx.ut_line, OTIME_MSG, sizeof(utx.ut_line)); # ifdef HAVE_UPDWTMPX updwtmpx(WTMPX_FILE, &utx); # else /* not HAVE_UPDWTMPX */ @@ -346,7 +554,7 @@ step_systime( # ifdef HAVE_PUTUTXLINE utx.ut_type = NEW_TIME; utx.ut_tv = timetv; - (void)strcpy(utx.ut_line, NTIME_MSG); + strlcpy(utx.ut_line, NTIME_MSG, sizeof(utx.ut_line)); # ifdef HAVE_UPDWTMPX updwtmpx(WTMPX_FILE, &utx); # else /* not HAVE_UPDWTMPX */ @@ -356,187 +564,7 @@ step_systime( #endif /* UPDATE_WTMPX */ } - return (1); -} - -#else /* SIM */ -/* - * Clock routines for the simulator - Harish Nair, with help - */ -/* - * get_systime - return the system time in NTP timestamp format - */ -void -get_systime( - l_fp *now /* current system time in l_fp */ ) -{ - /* - * To fool the code that determines the local clock precision, - * we advance the clock a minimum of 200 nanoseconds on every - * clock read. This is appropriate for a typical modern machine - * with nanosecond clocks. Note we make no attempt here to - * simulate reading error, since the error is so small. This may - * change when the need comes to implement picosecond clocks. - */ - if (ntp_node.ntp_time == ntp_node.last_time) - ntp_node.ntp_time += 200e-9; - ntp_node.last_time = ntp_node.ntp_time; - DTOLFP(ntp_node.ntp_time, now); -} - - -/* - * adj_systime - advance or retard the system clock exactly like the - * real thng. - */ -int /* always succeeds */ -adj_systime( - double now /* time adjustment (s) */ - ) -{ - struct timeval adjtv; /* new adjustment */ - double dtemp; - long ticks; - int isneg = 0; - - /* - * Most Unix adjtime() implementations adjust the system clock - * in microsecond quanta, but some adjust in 10-ms quanta. We - * carefully round the adjustment to the nearest quantum, then - * adjust in quanta and keep the residue for later. - */ - dtemp = now + sys_residual; - if (dtemp < 0) { - isneg = 1; - dtemp = -dtemp; - } - adjtv.tv_sec = (long)dtemp; - dtemp -= adjtv.tv_sec; - ticks = (long)(dtemp / sys_tick + .5); - adjtv.tv_usec = (long)(ticks * sys_tick * 1e6); - dtemp -= adjtv.tv_usec / 1e6; - sys_residual = dtemp; - - /* - * Convert to signed seconds and microseconds for the Unix - * adjtime() system call. Note we purposely lose the adjtime() - * leftover. - */ - if (isneg) { - adjtv.tv_sec = -adjtv.tv_sec; - adjtv.tv_usec = -adjtv.tv_usec; - sys_residual = -sys_residual; - } - ntp_node.adj = now; - return (1); -} - - -/* - * step_systime - step the system clock. We are religious here. - */ -int /* always succeeds */ -step_systime( - double now /* step adjustment (s) */ - ) -{ -#ifdef DEBUG - if (debug) - printf("step_systime: time %.6f adj %.6f\n", - ntp_node.ntp_time, now); -#endif - ntp_node.ntp_time += now; - return (1); -} - -/* - * node_clock - update the clocks - */ -int /* always succeeds */ -node_clock( - Node *n, /* global node pointer */ - double t /* node time */ - ) -{ - double dtemp; - - /* - * Advance client clock (ntp_time). Advance server clock - * (clk_time) adjusted for systematic and random frequency - * errors. The random error is a random walk computed as the - * integral of samples from a Gaussian distribution. - */ - dtemp = t - n->ntp_time; - n->time = t; - n->ntp_time += dtemp; - n->ferr += gauss(0, dtemp * n->fnse); - n->clk_time += dtemp * (1 + n->ferr); - - /* - * Perform the adjtime() function. If the adjustment completed - * in the previous interval, amortize the entire amount; if not, - * carry the leftover to the next interval. - */ - dtemp *= n->slew; - if (dtemp < fabs(n->adj)) { - if (n->adj < 0) { - n->adj += dtemp; - n->ntp_time -= dtemp; - } else { - n->adj -= dtemp; - n->ntp_time += dtemp; - } - } else { - n->ntp_time += n->adj; - n->adj = 0; - } - return (0); -} - - -/* - * gauss() - returns samples from a gaussion distribution - */ -double /* Gaussian sample */ -gauss( - double m, /* sample mean */ - double s /* sample standard deviation (sigma) */ - ) -{ - double q1, q2; - - /* - * Roll a sample from a Gaussian distribution with mean m and - * standard deviation s. For m = 0, s = 1, mean(y) = 0, - * std(y) = 1. - */ - if (s == 0) - return (m); - while ((q1 = drand48()) == 0); - q2 = drand48(); - return (m + s * sqrt(-2. * log(q1)) * cos(2. * PI * q2)); + return TRUE; } - -/* - * poisson() - returns samples from a network delay distribution - */ -double /* delay sample (s) */ -poisson( - double m, /* fixed propagation delay (s) */ - double s /* exponential parameter (mu) */ - ) -{ - double q1; - - /* - * Roll a sample from a composite distribution with propagation - * delay m and exponential distribution time with parameter s. - * For m = 0, s = 1, mean(y) = std(y) = 1. - */ - if (s == 0) - return (m); - while ((q1 = drand48()) == 0); - return (m - s * log(q1 * s)); -} -#endif /* SIM */ +#endif /* !SIM */ diff --git a/contrib/ntp/libntp/timetoa.c b/contrib/ntp/libntp/timetoa.c new file mode 100644 index 000000000..f294e1610 --- /dev/null +++ b/contrib/ntp/libntp/timetoa.c @@ -0,0 +1,106 @@ +/* + * timetoa.c -- time_t related string formatting + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * + * Printing a 'time_t' has a lot of portability pitfalls, due to it's + * opaque base type. The only requirement imposed by the standard is + * that it must be a numeric type. For all practical purposes it's a + * signed int, and 32 bits are common. + * + * Since the UN*X time epoch will cause a signed integer overflow for + * 32-bit signed int in the year 2038, implementations slowly move to + * 64bit base types for time_t, even in 32-bit environments. + * + * As the printf() family has no standardised type specifier for time_t, + * guessing the right output format specifier is a bit troublesome and + * best done with the help of the preprocessor and "config.h". + */ + +#include "config.h" + +#include +#include + +#include "timetoa.h" +#include "ntp_assert.h" +#include "lib_strbuf.h" + +/* + * Formatting to string needs at max 40 bytes (even with 64 bit time_t), + * so we check LIB_BUFLENGTH is big enough for our purpose. + */ +#if LIB_BUFLENGTH < 40 +# include "GRONK: LIB_BUFLENGTH is not sufficient" +#endif + +/* + * general fractional timestamp formatting + * + * Many pieces of ntpd require a machine with two's complement + * representation of signed integers, so we don't go through the whole + * rigamarole of creating fully portable code here. But we have to stay + * away from signed integer overflow, as this might cause trouble even + * with two's complement representation. + */ +const char * +format_time_fraction( + time_t secs, + long frac, + int prec + ) +{ + char * cp; + u_int prec_u; + u_time secs_u; + u_int u; + long fraclimit; + int notneg; /* flag for non-negative value */ + ldiv_t qr; + + DEBUG_REQUIRE(prec != 0); + + LIB_GETBUF(cp); + secs_u = (u_time)secs; + + /* check if we need signed or unsigned mode */ + notneg = (prec < 0); + prec_u = abs(prec); + /* fraclimit = (long)pow(10, prec_u); */ + for (fraclimit = 10, u = 1; u < prec_u; u++) { + DEBUG_INSIST(fraclimit < fraclimit * 10); + fraclimit *= 10; + } + + /* + * Since conversion to string uses lots of divisions anyway, + * there's no big extra penalty for normalisation. We do it for + * consistency. + */ + if (frac < 0 || frac >= fraclimit) { + qr = ldiv(frac, fraclimit); + if (qr.rem < 0) { + qr.quot--; + qr.rem += fraclimit; + } + secs_u += (time_t)qr.quot; + frac = qr.rem; + } + + /* Get the absolute value of the split representation time. */ + notneg = notneg || ((time_t)secs_u >= 0); + if (!notneg) { + secs_u = ~secs_u; + if (0 == frac) + secs_u++; + else + frac = fraclimit - frac; + } + + /* finally format the data and return the result */ + snprintf(cp, LIB_BUFLENGTH, "%s%" UTIME_FORMAT ".%0*ld", + notneg? "" : "-", secs_u, prec_u, frac); + + return cp; +} diff --git a/contrib/ntp/libntp/timevalops.c b/contrib/ntp/libntp/timevalops.c new file mode 100644 index 000000000..55f7bb573 --- /dev/null +++ b/contrib/ntp/libntp/timevalops.c @@ -0,0 +1,297 @@ +/* + * timevalops.c -- calculations on 'struct timeval' values + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + */ + +#include + +#include "timevalops.h" + +#ifdef USE_TSF_USEC_TABLES +/* + * Tables to calculate time stamp fractions from usecs. The entries + * in these tables are offset into using each of the two low order + * bytes plus the next 4 bits in a usec value (from a struct timeval). + * These are summed to produce the time stamp fraction. + * + * Note that these tables are rounded (not truncated) to the nearest + * low order bit in the fraction. The timestamp computed should be + * +- 1.5 low order bits. + */ + +const u_int32 ustotslo[256] = { + 0x00000000, 0x000010c7, 0x0000218e, 0x00003255, + 0x0000431c, 0x000053e3, 0x000064aa, 0x00007571, + 0x00008638, 0x000096ff, 0x0000a7c6, 0x0000b88d, + 0x0000c954, 0x0000da1b, 0x0000eae2, 0x0000fba9, + 0x00010c6f, 0x00011d36, 0x00012dfd, 0x00013ec4, + 0x00014f8b, 0x00016052, 0x00017119, 0x000181e0, + 0x000192a7, 0x0001a36e, 0x0001b435, 0x0001c4fc, + 0x0001d5c3, 0x0001e68a, 0x0001f751, 0x00020818, + 0x000218df, 0x000229a6, 0x00023a6d, 0x00024b34, + 0x00025bfb, 0x00026cc2, 0x00027d89, 0x00028e50, + 0x00029f17, 0x0002afde, 0x0002c0a5, 0x0002d16c, + 0x0002e233, 0x0002f2fa, 0x000303c0, 0x00031487, + 0x0003254e, 0x00033615, 0x000346dc, 0x000357a3, + 0x0003686a, 0x00037931, 0x000389f8, 0x00039abf, + 0x0003ab86, 0x0003bc4d, 0x0003cd14, 0x0003dddb, + 0x0003eea2, 0x0003ff69, 0x00041030, 0x000420f7, + 0x000431be, 0x00044285, 0x0004534c, 0x00046413, + 0x000474da, 0x000485a1, 0x00049668, 0x0004a72f, + 0x0004b7f6, 0x0004c8bd, 0x0004d984, 0x0004ea4b, + 0x0004fb12, 0x00050bd8, 0x00051c9f, 0x00052d66, + 0x00053e2d, 0x00054ef4, 0x00055fbb, 0x00057082, + 0x00058149, 0x00059210, 0x0005a2d7, 0x0005b39e, + 0x0005c465, 0x0005d52c, 0x0005e5f3, 0x0005f6ba, + 0x00060781, 0x00061848, 0x0006290f, 0x000639d6, + 0x00064a9d, 0x00065b64, 0x00066c2b, 0x00067cf2, + 0x00068db9, 0x00069e80, 0x0006af47, 0x0006c00e, + 0x0006d0d5, 0x0006e19c, 0x0006f263, 0x0007032a, + 0x000713f0, 0x000724b7, 0x0007357e, 0x00074645, + 0x0007570c, 0x000767d3, 0x0007789a, 0x00078961, + 0x00079a28, 0x0007aaef, 0x0007bbb6, 0x0007cc7d, + 0x0007dd44, 0x0007ee0b, 0x0007fed2, 0x00080f99, + 0x00082060, 0x00083127, 0x000841ee, 0x000852b5, + 0x0008637c, 0x00087443, 0x0008850a, 0x000895d1, + 0x0008a698, 0x0008b75f, 0x0008c826, 0x0008d8ed, + 0x0008e9b4, 0x0008fa7b, 0x00090b41, 0x00091c08, + 0x00092ccf, 0x00093d96, 0x00094e5d, 0x00095f24, + 0x00096feb, 0x000980b2, 0x00099179, 0x0009a240, + 0x0009b307, 0x0009c3ce, 0x0009d495, 0x0009e55c, + 0x0009f623, 0x000a06ea, 0x000a17b1, 0x000a2878, + 0x000a393f, 0x000a4a06, 0x000a5acd, 0x000a6b94, + 0x000a7c5b, 0x000a8d22, 0x000a9de9, 0x000aaeb0, + 0x000abf77, 0x000ad03e, 0x000ae105, 0x000af1cc, + 0x000b0293, 0x000b1359, 0x000b2420, 0x000b34e7, + 0x000b45ae, 0x000b5675, 0x000b673c, 0x000b7803, + 0x000b88ca, 0x000b9991, 0x000baa58, 0x000bbb1f, + 0x000bcbe6, 0x000bdcad, 0x000bed74, 0x000bfe3b, + 0x000c0f02, 0x000c1fc9, 0x000c3090, 0x000c4157, + 0x000c521e, 0x000c62e5, 0x000c73ac, 0x000c8473, + 0x000c953a, 0x000ca601, 0x000cb6c8, 0x000cc78f, + 0x000cd856, 0x000ce91d, 0x000cf9e4, 0x000d0aaa, + 0x000d1b71, 0x000d2c38, 0x000d3cff, 0x000d4dc6, + 0x000d5e8d, 0x000d6f54, 0x000d801b, 0x000d90e2, + 0x000da1a9, 0x000db270, 0x000dc337, 0x000dd3fe, + 0x000de4c5, 0x000df58c, 0x000e0653, 0x000e171a, + 0x000e27e1, 0x000e38a8, 0x000e496f, 0x000e5a36, + 0x000e6afd, 0x000e7bc4, 0x000e8c8b, 0x000e9d52, + 0x000eae19, 0x000ebee0, 0x000ecfa7, 0x000ee06e, + 0x000ef135, 0x000f01fc, 0x000f12c2, 0x000f2389, + 0x000f3450, 0x000f4517, 0x000f55de, 0x000f66a5, + 0x000f776c, 0x000f8833, 0x000f98fa, 0x000fa9c1, + 0x000fba88, 0x000fcb4f, 0x000fdc16, 0x000fecdd, + 0x000ffda4, 0x00100e6b, 0x00101f32, 0x00102ff9, + 0x001040c0, 0x00105187, 0x0010624e, 0x00107315, + 0x001083dc, 0x001094a3, 0x0010a56a, 0x0010b631 +}; + +const u_int32 ustotsmid[256] = { + 0x00000000, 0x0010c6f8, 0x00218def, 0x003254e7, + 0x00431bdf, 0x0053e2d6, 0x0064a9ce, 0x007570c5, + 0x008637bd, 0x0096feb5, 0x00a7c5ac, 0x00b88ca4, + 0x00c9539c, 0x00da1a93, 0x00eae18b, 0x00fba882, + 0x010c6f7a, 0x011d3672, 0x012dfd69, 0x013ec461, + 0x014f8b59, 0x01605250, 0x01711948, 0x0181e03f, + 0x0192a737, 0x01a36e2f, 0x01b43526, 0x01c4fc1e, + 0x01d5c316, 0x01e68a0d, 0x01f75105, 0x020817fc, + 0x0218def4, 0x0229a5ec, 0x023a6ce3, 0x024b33db, + 0x025bfad3, 0x026cc1ca, 0x027d88c2, 0x028e4fb9, + 0x029f16b1, 0x02afdda9, 0x02c0a4a0, 0x02d16b98, + 0x02e23290, 0x02f2f987, 0x0303c07f, 0x03148777, + 0x03254e6e, 0x03361566, 0x0346dc5d, 0x0357a355, + 0x03686a4d, 0x03793144, 0x0389f83c, 0x039abf34, + 0x03ab862b, 0x03bc4d23, 0x03cd141a, 0x03dddb12, + 0x03eea20a, 0x03ff6901, 0x04102ff9, 0x0420f6f1, + 0x0431bde8, 0x044284e0, 0x04534bd7, 0x046412cf, + 0x0474d9c7, 0x0485a0be, 0x049667b6, 0x04a72eae, + 0x04b7f5a5, 0x04c8bc9d, 0x04d98394, 0x04ea4a8c, + 0x04fb1184, 0x050bd87b, 0x051c9f73, 0x052d666b, + 0x053e2d62, 0x054ef45a, 0x055fbb51, 0x05708249, + 0x05814941, 0x05921038, 0x05a2d730, 0x05b39e28, + 0x05c4651f, 0x05d52c17, 0x05e5f30e, 0x05f6ba06, + 0x060780fe, 0x061847f5, 0x06290eed, 0x0639d5e5, + 0x064a9cdc, 0x065b63d4, 0x066c2acc, 0x067cf1c3, + 0x068db8bb, 0x069e7fb2, 0x06af46aa, 0x06c00da2, + 0x06d0d499, 0x06e19b91, 0x06f26289, 0x07032980, + 0x0713f078, 0x0724b76f, 0x07357e67, 0x0746455f, + 0x07570c56, 0x0767d34e, 0x07789a46, 0x0789613d, + 0x079a2835, 0x07aaef2c, 0x07bbb624, 0x07cc7d1c, + 0x07dd4413, 0x07ee0b0b, 0x07fed203, 0x080f98fa, + 0x08205ff2, 0x083126e9, 0x0841ede1, 0x0852b4d9, + 0x08637bd0, 0x087442c8, 0x088509c0, 0x0895d0b7, + 0x08a697af, 0x08b75ea6, 0x08c8259e, 0x08d8ec96, + 0x08e9b38d, 0x08fa7a85, 0x090b417d, 0x091c0874, + 0x092ccf6c, 0x093d9664, 0x094e5d5b, 0x095f2453, + 0x096feb4a, 0x0980b242, 0x0991793a, 0x09a24031, + 0x09b30729, 0x09c3ce21, 0x09d49518, 0x09e55c10, + 0x09f62307, 0x0a06e9ff, 0x0a17b0f7, 0x0a2877ee, + 0x0a393ee6, 0x0a4a05de, 0x0a5accd5, 0x0a6b93cd, + 0x0a7c5ac4, 0x0a8d21bc, 0x0a9de8b4, 0x0aaeafab, + 0x0abf76a3, 0x0ad03d9b, 0x0ae10492, 0x0af1cb8a, + 0x0b029281, 0x0b135979, 0x0b242071, 0x0b34e768, + 0x0b45ae60, 0x0b567558, 0x0b673c4f, 0x0b780347, + 0x0b88ca3e, 0x0b999136, 0x0baa582e, 0x0bbb1f25, + 0x0bcbe61d, 0x0bdcad15, 0x0bed740c, 0x0bfe3b04, + 0x0c0f01fc, 0x0c1fc8f3, 0x0c308feb, 0x0c4156e2, + 0x0c521dda, 0x0c62e4d2, 0x0c73abc9, 0x0c8472c1, + 0x0c9539b9, 0x0ca600b0, 0x0cb6c7a8, 0x0cc78e9f, + 0x0cd85597, 0x0ce91c8f, 0x0cf9e386, 0x0d0aaa7e, + 0x0d1b7176, 0x0d2c386d, 0x0d3cff65, 0x0d4dc65c, + 0x0d5e8d54, 0x0d6f544c, 0x0d801b43, 0x0d90e23b, + 0x0da1a933, 0x0db2702a, 0x0dc33722, 0x0dd3fe19, + 0x0de4c511, 0x0df58c09, 0x0e065300, 0x0e1719f8, + 0x0e27e0f0, 0x0e38a7e7, 0x0e496edf, 0x0e5a35d6, + 0x0e6afcce, 0x0e7bc3c6, 0x0e8c8abd, 0x0e9d51b5, + 0x0eae18ad, 0x0ebedfa4, 0x0ecfa69c, 0x0ee06d94, + 0x0ef1348b, 0x0f01fb83, 0x0f12c27a, 0x0f238972, + 0x0f34506a, 0x0f451761, 0x0f55de59, 0x0f66a551, + 0x0f776c48, 0x0f883340, 0x0f98fa37, 0x0fa9c12f, + 0x0fba8827, 0x0fcb4f1e, 0x0fdc1616, 0x0fecdd0e, + 0x0ffda405, 0x100e6afd, 0x101f31f4, 0x102ff8ec, + 0x1040bfe4, 0x105186db, 0x10624dd3, 0x107314cb, + 0x1083dbc2, 0x1094a2ba, 0x10a569b1, 0x10b630a9 +}; + +const u_int32 ustotshi[16] = { + 0x00000000, 0x10c6f7a1, 0x218def41, 0x3254e6e2, + 0x431bde83, 0x53e2d624, 0x64a9cdc4, 0x7570c565, + 0x8637bd06, 0x96feb4a6, 0xa7c5ac47, 0xb88ca3e8, + 0xc9539b89, 0xda1a9329, 0xeae18aca, 0xfba8826b +}; + +/* + * Tables to convert from a time stamp fraction to usecs. Note that + * the units of these tables are actually (usec<<3). We carry three + * guard bits so that the result can be properly truncated (or rounded) + * to be correct to the least significant bit. + * + * These tables are rounded. + */ + +const u_int32 tstoushi[256] = { + 0x000000, 0x007a12, 0x00f424, 0x016e36, + 0x01e848, 0x02625a, 0x02dc6c, 0x03567e, + 0x03d090, 0x044aa2, 0x04c4b4, 0x053ec6, + 0x05b8d8, 0x0632ea, 0x06acfc, 0x07270e, + 0x07a120, 0x081b32, 0x089544, 0x090f56, + 0x098968, 0x0a037a, 0x0a7d8c, 0x0af79e, + 0x0b71b0, 0x0bebc2, 0x0c65d4, 0x0cdfe6, + 0x0d59f8, 0x0dd40a, 0x0e4e1c, 0x0ec82e, + 0x0f4240, 0x0fbc52, 0x103664, 0x10b076, + 0x112a88, 0x11a49a, 0x121eac, 0x1298be, + 0x1312d0, 0x138ce2, 0x1406f4, 0x148106, + 0x14fb18, 0x15752a, 0x15ef3c, 0x16694e, + 0x16e360, 0x175d72, 0x17d784, 0x185196, + 0x18cba8, 0x1945ba, 0x19bfcc, 0x1a39de, + 0x1ab3f0, 0x1b2e02, 0x1ba814, 0x1c2226, + 0x1c9c38, 0x1d164a, 0x1d905c, 0x1e0a6e, + 0x1e8480, 0x1efe92, 0x1f78a4, 0x1ff2b6, + 0x206cc8, 0x20e6da, 0x2160ec, 0x21dafe, + 0x225510, 0x22cf22, 0x234934, 0x23c346, + 0x243d58, 0x24b76a, 0x25317c, 0x25ab8e, + 0x2625a0, 0x269fb2, 0x2719c4, 0x2793d6, + 0x280de8, 0x2887fa, 0x29020c, 0x297c1e, + 0x29f630, 0x2a7042, 0x2aea54, 0x2b6466, + 0x2bde78, 0x2c588a, 0x2cd29c, 0x2d4cae, + 0x2dc6c0, 0x2e40d2, 0x2ebae4, 0x2f34f6, + 0x2faf08, 0x30291a, 0x30a32c, 0x311d3e, + 0x319750, 0x321162, 0x328b74, 0x330586, + 0x337f98, 0x33f9aa, 0x3473bc, 0x34edce, + 0x3567e0, 0x35e1f2, 0x365c04, 0x36d616, + 0x375028, 0x37ca3a, 0x38444c, 0x38be5e, + 0x393870, 0x39b282, 0x3a2c94, 0x3aa6a6, + 0x3b20b8, 0x3b9aca, 0x3c14dc, 0x3c8eee, + 0x3d0900, 0x3d8312, 0x3dfd24, 0x3e7736, + 0x3ef148, 0x3f6b5a, 0x3fe56c, 0x405f7e, + 0x40d990, 0x4153a2, 0x41cdb4, 0x4247c6, + 0x42c1d8, 0x433bea, 0x43b5fc, 0x44300e, + 0x44aa20, 0x452432, 0x459e44, 0x461856, + 0x469268, 0x470c7a, 0x47868c, 0x48009e, + 0x487ab0, 0x48f4c2, 0x496ed4, 0x49e8e6, + 0x4a62f8, 0x4add0a, 0x4b571c, 0x4bd12e, + 0x4c4b40, 0x4cc552, 0x4d3f64, 0x4db976, + 0x4e3388, 0x4ead9a, 0x4f27ac, 0x4fa1be, + 0x501bd0, 0x5095e2, 0x510ff4, 0x518a06, + 0x520418, 0x527e2a, 0x52f83c, 0x53724e, + 0x53ec60, 0x546672, 0x54e084, 0x555a96, + 0x55d4a8, 0x564eba, 0x56c8cc, 0x5742de, + 0x57bcf0, 0x583702, 0x58b114, 0x592b26, + 0x59a538, 0x5a1f4a, 0x5a995c, 0x5b136e, + 0x5b8d80, 0x5c0792, 0x5c81a4, 0x5cfbb6, + 0x5d75c8, 0x5defda, 0x5e69ec, 0x5ee3fe, + 0x5f5e10, 0x5fd822, 0x605234, 0x60cc46, + 0x614658, 0x61c06a, 0x623a7c, 0x62b48e, + 0x632ea0, 0x63a8b2, 0x6422c4, 0x649cd6, + 0x6516e8, 0x6590fa, 0x660b0c, 0x66851e, + 0x66ff30, 0x677942, 0x67f354, 0x686d66, + 0x68e778, 0x69618a, 0x69db9c, 0x6a55ae, + 0x6acfc0, 0x6b49d2, 0x6bc3e4, 0x6c3df6, + 0x6cb808, 0x6d321a, 0x6dac2c, 0x6e263e, + 0x6ea050, 0x6f1a62, 0x6f9474, 0x700e86, + 0x708898, 0x7102aa, 0x717cbc, 0x71f6ce, + 0x7270e0, 0x72eaf2, 0x736504, 0x73df16, + 0x745928, 0x74d33a, 0x754d4c, 0x75c75e, + 0x764170, 0x76bb82, 0x773594, 0x77afa6, + 0x7829b8, 0x78a3ca, 0x791ddc, 0x7997ee +}; + +const u_int32 tstousmid[256] = { + 0x0000, 0x007a, 0x00f4, 0x016e, 0x01e8, 0x0262, 0x02dc, 0x0356, + 0x03d1, 0x044b, 0x04c5, 0x053f, 0x05b9, 0x0633, 0x06ad, 0x0727, + 0x07a1, 0x081b, 0x0895, 0x090f, 0x0989, 0x0a03, 0x0a7e, 0x0af8, + 0x0b72, 0x0bec, 0x0c66, 0x0ce0, 0x0d5a, 0x0dd4, 0x0e4e, 0x0ec8, + 0x0f42, 0x0fbc, 0x1036, 0x10b0, 0x112b, 0x11a5, 0x121f, 0x1299, + 0x1313, 0x138d, 0x1407, 0x1481, 0x14fb, 0x1575, 0x15ef, 0x1669, + 0x16e3, 0x175d, 0x17d8, 0x1852, 0x18cc, 0x1946, 0x19c0, 0x1a3a, + 0x1ab4, 0x1b2e, 0x1ba8, 0x1c22, 0x1c9c, 0x1d16, 0x1d90, 0x1e0a, + 0x1e84, 0x1eff, 0x1f79, 0x1ff3, 0x206d, 0x20e7, 0x2161, 0x21db, + 0x2255, 0x22cf, 0x2349, 0x23c3, 0x243d, 0x24b7, 0x2531, 0x25ac, + 0x2626, 0x26a0, 0x271a, 0x2794, 0x280e, 0x2888, 0x2902, 0x297c, + 0x29f6, 0x2a70, 0x2aea, 0x2b64, 0x2bde, 0x2c59, 0x2cd3, 0x2d4d, + 0x2dc7, 0x2e41, 0x2ebb, 0x2f35, 0x2faf, 0x3029, 0x30a3, 0x311d, + 0x3197, 0x3211, 0x328b, 0x3306, 0x3380, 0x33fa, 0x3474, 0x34ee, + 0x3568, 0x35e2, 0x365c, 0x36d6, 0x3750, 0x37ca, 0x3844, 0x38be, + 0x3938, 0x39b3, 0x3a2d, 0x3aa7, 0x3b21, 0x3b9b, 0x3c15, 0x3c8f, + 0x3d09, 0x3d83, 0x3dfd, 0x3e77, 0x3ef1, 0x3f6b, 0x3fe5, 0x405f, + 0x40da, 0x4154, 0x41ce, 0x4248, 0x42c2, 0x433c, 0x43b6, 0x4430, + 0x44aa, 0x4524, 0x459e, 0x4618, 0x4692, 0x470c, 0x4787, 0x4801, + 0x487b, 0x48f5, 0x496f, 0x49e9, 0x4a63, 0x4add, 0x4b57, 0x4bd1, + 0x4c4b, 0x4cc5, 0x4d3f, 0x4db9, 0x4e34, 0x4eae, 0x4f28, 0x4fa2, + 0x501c, 0x5096, 0x5110, 0x518a, 0x5204, 0x527e, 0x52f8, 0x5372, + 0x53ec, 0x5466, 0x54e1, 0x555b, 0x55d5, 0x564f, 0x56c9, 0x5743, + 0x57bd, 0x5837, 0x58b1, 0x592b, 0x59a5, 0x5a1f, 0x5a99, 0x5b13, + 0x5b8d, 0x5c08, 0x5c82, 0x5cfc, 0x5d76, 0x5df0, 0x5e6a, 0x5ee4, + 0x5f5e, 0x5fd8, 0x6052, 0x60cc, 0x6146, 0x61c0, 0x623a, 0x62b5, + 0x632f, 0x63a9, 0x6423, 0x649d, 0x6517, 0x6591, 0x660b, 0x6685, + 0x66ff, 0x6779, 0x67f3, 0x686d, 0x68e7, 0x6962, 0x69dc, 0x6a56, + 0x6ad0, 0x6b4a, 0x6bc4, 0x6c3e, 0x6cb8, 0x6d32, 0x6dac, 0x6e26, + 0x6ea0, 0x6f1a, 0x6f94, 0x700f, 0x7089, 0x7103, 0x717d, 0x71f7, + 0x7271, 0x72eb, 0x7365, 0x73df, 0x7459, 0x74d3, 0x754d, 0x75c7, + 0x7641, 0x76bc, 0x7736, 0x77b0, 0x782a, 0x78a4, 0x791e, 0x7998 +}; + +const u_int32 tstouslo[128] = { + 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, + 0x08, 0x09, 0x0a, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, + 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, + 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, + 0x1f, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, + 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, + 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x33, 0x34, + 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, + 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, + 0x45, 0x46, 0x47, 0x48, 0x48, 0x49, 0x4a, 0x4b, + 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, + 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, + 0x5c, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, + 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, + 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x71, + 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79 +}; +#else /* !USE_TSF_USEC_TABLES follows */ +NONEMPTY_TRANSLATION_UNIT +#endif /* !USE_TSF_USEC_TABLES */ +/* -*- EOF -*- */ diff --git a/contrib/ntp/libntp/tsftomsu.c b/contrib/ntp/libntp/tsftomsu.c deleted file mode 100644 index 5926aabc7..000000000 --- a/contrib/ntp/libntp/tsftomsu.c +++ /dev/null @@ -1,38 +0,0 @@ -/* - * tsftomsu - convert from a time stamp fraction to milliseconds - */ -#include "ntp_fp.h" -#include "ntp_stdlib.h" - -int -tsftomsu( - u_long tsf, - int round - ) -{ - register long val_ui, val_uf; - register long tmp_ui, tmp_uf; - register int i; - - /* - * Essentially, multiply by 10 three times in l_fp form. - * The integral part is the milliseconds. - */ - val_ui = 0; - val_uf = tsf; - for (i = 3; i > 0; i--) { - M_LSHIFT(val_ui, val_uf); - tmp_ui = val_ui; - tmp_uf = val_uf; - M_LSHIFT(val_ui, val_uf); - M_LSHIFT(val_ui, val_uf); - M_ADD(val_ui, val_uf, tmp_ui, tmp_uf); - } - - /* - * Round the value if need be, then return it. - */ - if (round && (val_uf & 0x80000000)) - val_ui++; - return (int)val_ui; -} diff --git a/contrib/ntp/libntp/tstotv.c b/contrib/ntp/libntp/tstotv.c deleted file mode 100644 index be4bdd441..000000000 --- a/contrib/ntp/libntp/tstotv.c +++ /dev/null @@ -1,135 +0,0 @@ -/* - * tstotv - tables for converting from NTP time stamps to struct timeval - */ - -#include "ntp_types.h" - -/* - * Tables to convert from a time stamp fraction to usecs. Note that - * the units of these tables are actually (usec<<3). We carry three - * guard bits so that the result can be properly truncated (or rounded) - * to be correct to the least significant bit. - * - * These tables are rounded. - */ - -long tstoushi[256] = { - 0x000000, 0x007a12, 0x00f424, 0x016e36, - 0x01e848, 0x02625a, 0x02dc6c, 0x03567e, - 0x03d090, 0x044aa2, 0x04c4b4, 0x053ec6, - 0x05b8d8, 0x0632ea, 0x06acfc, 0x07270e, - 0x07a120, 0x081b32, 0x089544, 0x090f56, - 0x098968, 0x0a037a, 0x0a7d8c, 0x0af79e, - 0x0b71b0, 0x0bebc2, 0x0c65d4, 0x0cdfe6, - 0x0d59f8, 0x0dd40a, 0x0e4e1c, 0x0ec82e, - 0x0f4240, 0x0fbc52, 0x103664, 0x10b076, - 0x112a88, 0x11a49a, 0x121eac, 0x1298be, - 0x1312d0, 0x138ce2, 0x1406f4, 0x148106, - 0x14fb18, 0x15752a, 0x15ef3c, 0x16694e, - 0x16e360, 0x175d72, 0x17d784, 0x185196, - 0x18cba8, 0x1945ba, 0x19bfcc, 0x1a39de, - 0x1ab3f0, 0x1b2e02, 0x1ba814, 0x1c2226, - 0x1c9c38, 0x1d164a, 0x1d905c, 0x1e0a6e, - 0x1e8480, 0x1efe92, 0x1f78a4, 0x1ff2b6, - 0x206cc8, 0x20e6da, 0x2160ec, 0x21dafe, - 0x225510, 0x22cf22, 0x234934, 0x23c346, - 0x243d58, 0x24b76a, 0x25317c, 0x25ab8e, - 0x2625a0, 0x269fb2, 0x2719c4, 0x2793d6, - 0x280de8, 0x2887fa, 0x29020c, 0x297c1e, - 0x29f630, 0x2a7042, 0x2aea54, 0x2b6466, - 0x2bde78, 0x2c588a, 0x2cd29c, 0x2d4cae, - 0x2dc6c0, 0x2e40d2, 0x2ebae4, 0x2f34f6, - 0x2faf08, 0x30291a, 0x30a32c, 0x311d3e, - 0x319750, 0x321162, 0x328b74, 0x330586, - 0x337f98, 0x33f9aa, 0x3473bc, 0x34edce, - 0x3567e0, 0x35e1f2, 0x365c04, 0x36d616, - 0x375028, 0x37ca3a, 0x38444c, 0x38be5e, - 0x393870, 0x39b282, 0x3a2c94, 0x3aa6a6, - 0x3b20b8, 0x3b9aca, 0x3c14dc, 0x3c8eee, - 0x3d0900, 0x3d8312, 0x3dfd24, 0x3e7736, - 0x3ef148, 0x3f6b5a, 0x3fe56c, 0x405f7e, - 0x40d990, 0x4153a2, 0x41cdb4, 0x4247c6, - 0x42c1d8, 0x433bea, 0x43b5fc, 0x44300e, - 0x44aa20, 0x452432, 0x459e44, 0x461856, - 0x469268, 0x470c7a, 0x47868c, 0x48009e, - 0x487ab0, 0x48f4c2, 0x496ed4, 0x49e8e6, - 0x4a62f8, 0x4add0a, 0x4b571c, 0x4bd12e, - 0x4c4b40, 0x4cc552, 0x4d3f64, 0x4db976, - 0x4e3388, 0x4ead9a, 0x4f27ac, 0x4fa1be, - 0x501bd0, 0x5095e2, 0x510ff4, 0x518a06, - 0x520418, 0x527e2a, 0x52f83c, 0x53724e, - 0x53ec60, 0x546672, 0x54e084, 0x555a96, - 0x55d4a8, 0x564eba, 0x56c8cc, 0x5742de, - 0x57bcf0, 0x583702, 0x58b114, 0x592b26, - 0x59a538, 0x5a1f4a, 0x5a995c, 0x5b136e, - 0x5b8d80, 0x5c0792, 0x5c81a4, 0x5cfbb6, - 0x5d75c8, 0x5defda, 0x5e69ec, 0x5ee3fe, - 0x5f5e10, 0x5fd822, 0x605234, 0x60cc46, - 0x614658, 0x61c06a, 0x623a7c, 0x62b48e, - 0x632ea0, 0x63a8b2, 0x6422c4, 0x649cd6, - 0x6516e8, 0x6590fa, 0x660b0c, 0x66851e, - 0x66ff30, 0x677942, 0x67f354, 0x686d66, - 0x68e778, 0x69618a, 0x69db9c, 0x6a55ae, - 0x6acfc0, 0x6b49d2, 0x6bc3e4, 0x6c3df6, - 0x6cb808, 0x6d321a, 0x6dac2c, 0x6e263e, - 0x6ea050, 0x6f1a62, 0x6f9474, 0x700e86, - 0x708898, 0x7102aa, 0x717cbc, 0x71f6ce, - 0x7270e0, 0x72eaf2, 0x736504, 0x73df16, - 0x745928, 0x74d33a, 0x754d4c, 0x75c75e, - 0x764170, 0x76bb82, 0x773594, 0x77afa6, - 0x7829b8, 0x78a3ca, 0x791ddc, 0x7997ee -}; - -long tstousmid[256] = { - 0x0000, 0x007a, 0x00f4, 0x016e, 0x01e8, 0x0262, 0x02dc, 0x0356, - 0x03d1, 0x044b, 0x04c5, 0x053f, 0x05b9, 0x0633, 0x06ad, 0x0727, - 0x07a1, 0x081b, 0x0895, 0x090f, 0x0989, 0x0a03, 0x0a7e, 0x0af8, - 0x0b72, 0x0bec, 0x0c66, 0x0ce0, 0x0d5a, 0x0dd4, 0x0e4e, 0x0ec8, - 0x0f42, 0x0fbc, 0x1036, 0x10b0, 0x112b, 0x11a5, 0x121f, 0x1299, - 0x1313, 0x138d, 0x1407, 0x1481, 0x14fb, 0x1575, 0x15ef, 0x1669, - 0x16e3, 0x175d, 0x17d8, 0x1852, 0x18cc, 0x1946, 0x19c0, 0x1a3a, - 0x1ab4, 0x1b2e, 0x1ba8, 0x1c22, 0x1c9c, 0x1d16, 0x1d90, 0x1e0a, - 0x1e84, 0x1eff, 0x1f79, 0x1ff3, 0x206d, 0x20e7, 0x2161, 0x21db, - 0x2255, 0x22cf, 0x2349, 0x23c3, 0x243d, 0x24b7, 0x2531, 0x25ac, - 0x2626, 0x26a0, 0x271a, 0x2794, 0x280e, 0x2888, 0x2902, 0x297c, - 0x29f6, 0x2a70, 0x2aea, 0x2b64, 0x2bde, 0x2c59, 0x2cd3, 0x2d4d, - 0x2dc7, 0x2e41, 0x2ebb, 0x2f35, 0x2faf, 0x3029, 0x30a3, 0x311d, - 0x3197, 0x3211, 0x328b, 0x3306, 0x3380, 0x33fa, 0x3474, 0x34ee, - 0x3568, 0x35e2, 0x365c, 0x36d6, 0x3750, 0x37ca, 0x3844, 0x38be, - 0x3938, 0x39b3, 0x3a2d, 0x3aa7, 0x3b21, 0x3b9b, 0x3c15, 0x3c8f, - 0x3d09, 0x3d83, 0x3dfd, 0x3e77, 0x3ef1, 0x3f6b, 0x3fe5, 0x405f, - 0x40da, 0x4154, 0x41ce, 0x4248, 0x42c2, 0x433c, 0x43b6, 0x4430, - 0x44aa, 0x4524, 0x459e, 0x4618, 0x4692, 0x470c, 0x4787, 0x4801, - 0x487b, 0x48f5, 0x496f, 0x49e9, 0x4a63, 0x4add, 0x4b57, 0x4bd1, - 0x4c4b, 0x4cc5, 0x4d3f, 0x4db9, 0x4e34, 0x4eae, 0x4f28, 0x4fa2, - 0x501c, 0x5096, 0x5110, 0x518a, 0x5204, 0x527e, 0x52f8, 0x5372, - 0x53ec, 0x5466, 0x54e1, 0x555b, 0x55d5, 0x564f, 0x56c9, 0x5743, - 0x57bd, 0x5837, 0x58b1, 0x592b, 0x59a5, 0x5a1f, 0x5a99, 0x5b13, - 0x5b8d, 0x5c08, 0x5c82, 0x5cfc, 0x5d76, 0x5df0, 0x5e6a, 0x5ee4, - 0x5f5e, 0x5fd8, 0x6052, 0x60cc, 0x6146, 0x61c0, 0x623a, 0x62b5, - 0x632f, 0x63a9, 0x6423, 0x649d, 0x6517, 0x6591, 0x660b, 0x6685, - 0x66ff, 0x6779, 0x67f3, 0x686d, 0x68e7, 0x6962, 0x69dc, 0x6a56, - 0x6ad0, 0x6b4a, 0x6bc4, 0x6c3e, 0x6cb8, 0x6d32, 0x6dac, 0x6e26, - 0x6ea0, 0x6f1a, 0x6f94, 0x700f, 0x7089, 0x7103, 0x717d, 0x71f7, - 0x7271, 0x72eb, 0x7365, 0x73df, 0x7459, 0x74d3, 0x754d, 0x75c7, - 0x7641, 0x76bc, 0x7736, 0x77b0, 0x782a, 0x78a4, 0x791e, 0x7998 -}; - -long tstouslo[128] = { - 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, - 0x08, 0x09, 0x0a, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, - 0x0f, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, - 0x17, 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, - 0x1f, 0x1f, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, - 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d, - 0x2e, 0x2f, 0x30, 0x31, 0x32, 0x33, 0x33, 0x34, - 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, - 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43, 0x44, - 0x45, 0x46, 0x47, 0x48, 0x48, 0x49, 0x4a, 0x4b, - 0x4c, 0x4d, 0x4e, 0x4f, 0x50, 0x51, 0x52, 0x53, - 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5a, 0x5b, - 0x5c, 0x5c, 0x5d, 0x5e, 0x5f, 0x60, 0x61, 0x62, - 0x63, 0x64, 0x65, 0x66, 0x67, 0x68, 0x69, 0x6a, - 0x6b, 0x6c, 0x6d, 0x6e, 0x6f, 0x70, 0x71, 0x71, - 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79 -}; diff --git a/contrib/ntp/libntp/tvtoa.c b/contrib/ntp/libntp/tvtoa.c deleted file mode 100644 index 19d4a94ed..000000000 --- a/contrib/ntp/libntp/tvtoa.c +++ /dev/null @@ -1,39 +0,0 @@ -/* - * tvtoa - return an asciized representation of a struct timeval - */ - -#include "lib_strbuf.h" - -#if defined(VMS) -# include "ntp_fp.h" -#endif /* VMS */ -#include "ntp_stdlib.h" -#include "ntp_unixtime.h" - -#include - -char * -tvtoa( - const struct timeval *tv - ) -{ - register char *buf; - register u_long sec; - register u_long usec; - register int isneg; - - if (tv->tv_sec < 0 || tv->tv_usec < 0) { - sec = -tv->tv_sec; - usec = -tv->tv_usec; - isneg = 1; - } else { - sec = tv->tv_sec; - usec = tv->tv_usec; - isneg = 0; - } - - LIB_GETBUF(buf); - - (void) sprintf(buf, "%s%lu.%06lu", (isneg?"-":""), sec, usec); - return buf; -} diff --git a/contrib/ntp/libntp/tvtots.c b/contrib/ntp/libntp/tvtots.c deleted file mode 100644 index 0bd2b6911..000000000 --- a/contrib/ntp/libntp/tvtots.c +++ /dev/null @@ -1,159 +0,0 @@ -/* - * tvtots - tables for converting from Unix struct timeval's to - * NTP time stamp format. - */ -#include - -#include "ntp_types.h" - -/* - * Tables to calculate time stamp fractions from usecs. The entries - * in these tables are offset into using each of the two low order - * bytes plus the next 4 bits in a usec value (from a struct timeval). - * These are summed to produce the time stamp fraction. - * - * Note that these tables are rounded (not truncated) to the nearest - * low order bit in the fraction. The timestamp computed should be - * +- 1.5 low order bits. - */ - -u_long ustotslo[256] = { - 0x00000000, 0x000010c7, 0x0000218e, 0x00003255, - 0x0000431c, 0x000053e3, 0x000064aa, 0x00007571, - 0x00008638, 0x000096ff, 0x0000a7c6, 0x0000b88d, - 0x0000c954, 0x0000da1b, 0x0000eae2, 0x0000fba9, - 0x00010c6f, 0x00011d36, 0x00012dfd, 0x00013ec4, - 0x00014f8b, 0x00016052, 0x00017119, 0x000181e0, - 0x000192a7, 0x0001a36e, 0x0001b435, 0x0001c4fc, - 0x0001d5c3, 0x0001e68a, 0x0001f751, 0x00020818, - 0x000218df, 0x000229a6, 0x00023a6d, 0x00024b34, - 0x00025bfb, 0x00026cc2, 0x00027d89, 0x00028e50, - 0x00029f17, 0x0002afde, 0x0002c0a5, 0x0002d16c, - 0x0002e233, 0x0002f2fa, 0x000303c0, 0x00031487, - 0x0003254e, 0x00033615, 0x000346dc, 0x000357a3, - 0x0003686a, 0x00037931, 0x000389f8, 0x00039abf, - 0x0003ab86, 0x0003bc4d, 0x0003cd14, 0x0003dddb, - 0x0003eea2, 0x0003ff69, 0x00041030, 0x000420f7, - 0x000431be, 0x00044285, 0x0004534c, 0x00046413, - 0x000474da, 0x000485a1, 0x00049668, 0x0004a72f, - 0x0004b7f6, 0x0004c8bd, 0x0004d984, 0x0004ea4b, - 0x0004fb12, 0x00050bd8, 0x00051c9f, 0x00052d66, - 0x00053e2d, 0x00054ef4, 0x00055fbb, 0x00057082, - 0x00058149, 0x00059210, 0x0005a2d7, 0x0005b39e, - 0x0005c465, 0x0005d52c, 0x0005e5f3, 0x0005f6ba, - 0x00060781, 0x00061848, 0x0006290f, 0x000639d6, - 0x00064a9d, 0x00065b64, 0x00066c2b, 0x00067cf2, - 0x00068db9, 0x00069e80, 0x0006af47, 0x0006c00e, - 0x0006d0d5, 0x0006e19c, 0x0006f263, 0x00070329, - 0x000713f0, 0x000724b7, 0x0007357e, 0x00074645, - 0x0007570c, 0x000767d3, 0x0007789a, 0x00078961, - 0x00079a28, 0x0007aaef, 0x0007bbb6, 0x0007cc7d, - 0x0007dd44, 0x0007ee0b, 0x0007fed2, 0x00080f99, - 0x00082060, 0x00083127, 0x000841ee, 0x000852b5, - 0x0008637c, 0x00087443, 0x0008850a, 0x000895d1, - 0x0008a698, 0x0008b75f, 0x0008c826, 0x0008d8ed, - 0x0008e9b4, 0x0008fa7b, 0x00090b41, 0x00091c08, - 0x00092ccf, 0x00093d96, 0x00094e5d, 0x00095f24, - 0x00096feb, 0x000980b2, 0x00099179, 0x0009a240, - 0x0009b307, 0x0009c3ce, 0x0009d495, 0x0009e55c, - 0x0009f623, 0x000a06ea, 0x000a17b1, 0x000a2878, - 0x000a393f, 0x000a4a06, 0x000a5acd, 0x000a6b94, - 0x000a7c5b, 0x000a8d22, 0x000a9de9, 0x000aaeb0, - 0x000abf77, 0x000ad03e, 0x000ae105, 0x000af1cc, - 0x000b0292, 0x000b1359, 0x000b2420, 0x000b34e7, - 0x000b45ae, 0x000b5675, 0x000b673c, 0x000b7803, - 0x000b88ca, 0x000b9991, 0x000baa58, 0x000bbb1f, - 0x000bcbe6, 0x000bdcad, 0x000bed74, 0x000bfe3b, - 0x000c0f02, 0x000c1fc9, 0x000c3090, 0x000c4157, - 0x000c521e, 0x000c62e5, 0x000c73ac, 0x000c8473, - 0x000c953a, 0x000ca601, 0x000cb6c8, 0x000cc78f, - 0x000cd856, 0x000ce91d, 0x000cf9e4, 0x000d0aaa, - 0x000d1b71, 0x000d2c38, 0x000d3cff, 0x000d4dc6, - 0x000d5e8d, 0x000d6f54, 0x000d801b, 0x000d90e2, - 0x000da1a9, 0x000db270, 0x000dc337, 0x000dd3fe, - 0x000de4c5, 0x000df58c, 0x000e0653, 0x000e171a, - 0x000e27e1, 0x000e38a8, 0x000e496f, 0x000e5a36, - 0x000e6afd, 0x000e7bc4, 0x000e8c8b, 0x000e9d52, - 0x000eae19, 0x000ebee0, 0x000ecfa7, 0x000ee06e, - 0x000ef135, 0x000f01fb, 0x000f12c2, 0x000f2389, - 0x000f3450, 0x000f4517, 0x000f55de, 0x000f66a5, - 0x000f776c, 0x000f8833, 0x000f98fa, 0x000fa9c1, - 0x000fba88, 0x000fcb4f, 0x000fdc16, 0x000fecdd, - 0x000ffda4, 0x00100e6b, 0x00101f32, 0x00102ff9, - 0x001040c0, 0x00105187, 0x0010624e, 0x00107315, - 0x001083dc, 0x001094a3, 0x0010a56a, 0x0010b631, -}; - -u_long ustotsmid[256] = { - 0x00000000, 0x0010c6f8, 0x00218def, 0x003254e7, - 0x00431bde, 0x0053e2d6, 0x0064a9ce, 0x007570c5, - 0x008637bd, 0x0096feb4, 0x00a7c5ac, 0x00b88ca4, - 0x00c9539b, 0x00da1a93, 0x00eae18a, 0x00fba882, - 0x010c6f7a, 0x011d3671, 0x012dfd69, 0x013ec460, - 0x014f8b58, 0x01605250, 0x01711947, 0x0181e03f, - 0x0192a736, 0x01a36e2e, 0x01b43526, 0x01c4fc1d, - 0x01d5c315, 0x01e68a0c, 0x01f75104, 0x020817fc, - 0x0218def3, 0x0229a5eb, 0x023a6ce3, 0x024b33da, - 0x025bfad2, 0x026cc1c9, 0x027d88c1, 0x028e4fb9, - 0x029f16b0, 0x02afdda8, 0x02c0a49f, 0x02d16b97, - 0x02e2328f, 0x02f2f986, 0x0303c07e, 0x03148775, - 0x03254e6d, 0x03361565, 0x0346dc5c, 0x0357a354, - 0x03686a4b, 0x03793143, 0x0389f83b, 0x039abf32, - 0x03ab862a, 0x03bc4d21, 0x03cd1419, 0x03dddb11, - 0x03eea208, 0x03ff6900, 0x04102ff7, 0x0420f6ef, - 0x0431bde7, 0x044284de, 0x04534bd6, 0x046412cd, - 0x0474d9c5, 0x0485a0bd, 0x049667b4, 0x04a72eac, - 0x04b7f5a3, 0x04c8bc9b, 0x04d98393, 0x04ea4a8a, - 0x04fb1182, 0x050bd879, 0x051c9f71, 0x052d6669, - 0x053e2d60, 0x054ef458, 0x055fbb4f, 0x05708247, - 0x0581493f, 0x05921036, 0x05a2d72e, 0x05b39e25, - 0x05c4651d, 0x05d52c15, 0x05e5f30c, 0x05f6ba04, - 0x060780fb, 0x061847f3, 0x06290eeb, 0x0639d5e2, - 0x064a9cda, 0x065b63d2, 0x066c2ac9, 0x067cf1c1, - 0x068db8b8, 0x069e7fb0, 0x06af46a8, 0x06c00d9f, - 0x06d0d497, 0x06e19b8e, 0x06f26286, 0x0703297e, - 0x0713f075, 0x0724b76d, 0x07357e64, 0x0746455c, - 0x07570c54, 0x0767d34b, 0x07789a43, 0x0789613a, - 0x079a2832, 0x07aaef2a, 0x07bbb621, 0x07cc7d19, - 0x07dd4410, 0x07ee0b08, 0x07fed200, 0x080f98f7, - 0x08205fef, 0x083126e6, 0x0841edde, 0x0852b4d6, - 0x08637bcd, 0x087442c5, 0x088509bc, 0x0895d0b4, - 0x08a697ac, 0x08b75ea3, 0x08c8259b, 0x08d8ec92, - 0x08e9b38a, 0x08fa7a82, 0x090b4179, 0x091c0871, - 0x092ccf68, 0x093d9660, 0x094e5d58, 0x095f244f, - 0x096feb47, 0x0980b23e, 0x09917936, 0x09a2402e, - 0x09b30725, 0x09c3ce1d, 0x09d49514, 0x09e55c0c, - 0x09f62304, 0x0a06e9fb, 0x0a17b0f3, 0x0a2877ea, - 0x0a393ee2, 0x0a4a05da, 0x0a5accd1, 0x0a6b93c9, - 0x0a7c5ac1, 0x0a8d21b8, 0x0a9de8b0, 0x0aaeafa7, - 0x0abf769f, 0x0ad03d97, 0x0ae1048e, 0x0af1cb86, - 0x0b02927d, 0x0b135975, 0x0b24206d, 0x0b34e764, - 0x0b45ae5c, 0x0b567553, 0x0b673c4b, 0x0b780343, - 0x0b88ca3a, 0x0b999132, 0x0baa5829, 0x0bbb1f21, - 0x0bcbe619, 0x0bdcad10, 0x0bed7408, 0x0bfe3aff, - 0x0c0f01f7, 0x0c1fc8ef, 0x0c308fe6, 0x0c4156de, - 0x0c521dd5, 0x0c62e4cd, 0x0c73abc5, 0x0c8472bc, - 0x0c9539b4, 0x0ca600ab, 0x0cb6c7a3, 0x0cc78e9b, - 0x0cd85592, 0x0ce91c8a, 0x0cf9e381, 0x0d0aaa79, - 0x0d1b7171, 0x0d2c3868, 0x0d3cff60, 0x0d4dc657, - 0x0d5e8d4f, 0x0d6f5447, 0x0d801b3e, 0x0d90e236, - 0x0da1a92d, 0x0db27025, 0x0dc3371d, 0x0dd3fe14, - 0x0de4c50c, 0x0df58c03, 0x0e0652fb, 0x0e1719f3, - 0x0e27e0ea, 0x0e38a7e2, 0x0e496ed9, 0x0e5a35d1, - 0x0e6afcc9, 0x0e7bc3c0, 0x0e8c8ab8, 0x0e9d51b0, - 0x0eae18a7, 0x0ebedf9f, 0x0ecfa696, 0x0ee06d8e, - 0x0ef13486, 0x0f01fb7d, 0x0f12c275, 0x0f23896c, - 0x0f345064, 0x0f45175c, 0x0f55de53, 0x0f66a54b, - 0x0f776c42, 0x0f88333a, 0x0f98fa32, 0x0fa9c129, - 0x0fba8821, 0x0fcb4f18, 0x0fdc1610, 0x0fecdd08, - 0x0ffda3ff, 0x100e6af7, 0x101f31ee, 0x102ff8e6, - 0x1040bfde, 0x105186d5, 0x10624dcd, 0x107314c4, - 0x1083dbbc, 0x1094a2b4, 0x10a569ab, 0x10b630a3, -}; - -u_long ustotshi[16] = { - 0x00000000, 0x10c6f79a, 0x218def35, 0x3254e6cf, - 0x431bde6a, 0x53e2d604, 0x64a9cd9f, 0x7570c539, - 0x8637bcd3, 0x96feb46e, 0xa7c5ac08, 0xb88ca3a3, - 0xc9539b3d, 0xda1a92d7, 0xeae18a72, 0xfba8820c, -}; diff --git a/contrib/ntp/libntp/uglydate.c b/contrib/ntp/libntp/uglydate.c index 676a5fdde..66b513909 100644 --- a/contrib/ntp/libntp/uglydate.c +++ b/contrib/ntp/libntp/uglydate.c @@ -2,6 +2,7 @@ * uglydate - convert a time stamp to something barely readable * The string returned is 37 characters long. */ +#include #include #include "ntp_fp.h" @@ -41,8 +42,10 @@ uglydate( while (year >= 100) year -= 100; } - (void) sprintf(bp, "%17s %02d:%03d:%02d:%02d:%02d.%03ld", - timep, year, tm->tm_yday, tm->tm_hour, tm->tm_min, - tm->tm_sec, msec); + snprintf(bp, LIB_BUFLENGTH, + "%17s %02d:%03d:%02d:%02d:%02d.%03ld", timep, year, + tm->tm_yday, tm->tm_hour, tm->tm_min, tm->tm_sec, + msec); + return bp; } diff --git a/contrib/ntp/libntp/uinttoa.c b/contrib/ntp/libntp/uinttoa.c deleted file mode 100644 index be48ea514..000000000 --- a/contrib/ntp/libntp/uinttoa.c +++ /dev/null @@ -1,20 +0,0 @@ -/* - * uinttoa - return an asciized unsigned integer - */ -#include - -#include "lib_strbuf.h" -#include "ntp_stdlib.h" - -char * -uinttoa( - u_long uval - ) -{ - register char *buf; - - LIB_GETBUF(buf); - - (void) sprintf(buf, "%lu", (u_long)uval); - return buf; -} diff --git a/contrib/ntp/libntp/utvtoa.c b/contrib/ntp/libntp/utvtoa.c deleted file mode 100644 index a441c4910..000000000 --- a/contrib/ntp/libntp/utvtoa.c +++ /dev/null @@ -1,26 +0,0 @@ -/* - * utvtoa - return an asciized representation of an unsigned struct timeval - */ -#include - -#include "lib_strbuf.h" - -#if defined(VMS) -# include "ntp_fp.h" -#endif -#include "ntp_stdlib.h" -#include "ntp_unixtime.h" - -char * -utvtoa( - const struct timeval *tv - ) -{ - register char *buf; - - LIB_GETBUF(buf); - - (void) sprintf(buf, "%lu.%06lu", (u_long)tv->tv_sec, - (u_long)tv->tv_usec); - return buf; -} diff --git a/contrib/ntp/libntp/vint64ops.c b/contrib/ntp/libntp/vint64ops.c new file mode 100644 index 000000000..5adbebbb5 --- /dev/null +++ b/contrib/ntp/libntp/vint64ops.c @@ -0,0 +1,284 @@ +/* + * vint64ops.c - operations on 'vint64' values + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * ---------------------------------------------------------------------- + * This is an attempt to get the vint64 calculations stuff centralised. + */ + +#include +#include +#include +#include +#include + +#include "ntp_types.h" +#include "ntp_fp.h" +#include "vint64ops.h" + +/* --------------------------------------------------------------------- + * GCC is rather sticky with its 'const' attribute. We have to do it more + * explicit than with a cast if we want to get rid of a CONST qualifier. + * Greetings from the PASCAL world, where casting was only possible via + * untagged unions... + */ +static inline void* +noconst( + const void* ptr + ) +{ + union { + const void * cp; + void * vp; + } tmp; + tmp.cp = ptr; + return tmp.vp; +} + +/* -------------------------------------------------------------------------*/ + +vint64 +strtouv64( + const char * begp, + char ** endp, + int base + ) +{ + vint64 res; + u_char digit; + int sig, num; + const u_char *src; + + num = sig = 0; + src = (const u_char*)begp; + while (isspace(*src)) + src++; + + if (*src == '-') { + src++; + sig = 1; + } else if (*src == '+') { + src++; + } + + if (base == 0) { + base = 10; + if (*src == '0') { + base = 8; + if (toupper(*++src) == 'X') { + src++; + base = 16; + } + } + } else if (base == 16) { /* remove optional leading '0x' or '0X' */ + if (src[0] == '0' && toupper(src[1]) == 'X') + src += 2; + } else if (base <= 2 || base > 36) { + memset(&res, 0xFF, sizeof(res)); + errno = ERANGE; + return res; + } + + memset(&res, 0, sizeof(res)); + while (*src) { + if (isdigit(*src)) + digit = *src - '0'; + else if (isupper(*src)) + digit = *src - 'A' + 10; + else if (islower(*src)) + digit = *src - 'a' + 10; + else + break; + if (digit >= base) + break; + num = 1; +#if defined(HAVE_INT64) + res.Q_s = res.Q_s * base + digit; +#else + /* res *= base, using 16x16->32 bit + * multiplication. Slow but portable. + */ + { + uint32_t accu; + accu = (uint32_t)res.W_s.ll * base; + res.W_s.ll = (uint16_t)accu; + accu = (accu >> 16) + + (uint32_t)res.W_s.lh * base; + res.W_s.lh = (uint16_t)accu; + /* the upper bits can be done in one step: */ + res.D_s.hi = res.D_s.hi * base + (accu >> 16); + } + M_ADD(res.D_s.hi, res.D_s.lo, 0, digit); +#endif + src++; + } + if (!num) + errno = EINVAL; + if (endp) + *endp = (char*)noconst(src); + if (sig) + M_NEG(res.D_s.hi, res.D_s.lo); + return res; +} + +/* -------------------------------------------------------------------------*/ + +int +icmpv64( + const vint64 * lhs, + const vint64 * rhs + ) +{ + int res; + +#if defined(HAVE_INT64) + res = (lhs->q_s > rhs->q_s) + - (lhs->q_s < rhs->q_s); +#else + res = (lhs->d_s.hi > rhs->d_s.hi) + - (lhs->d_s.hi < rhs->d_s.hi); + if ( ! res ) + res = (lhs->D_s.lo > rhs->D_s.lo) + - (lhs->D_s.lo < rhs->D_s.lo); +#endif + + return res; +} + +/* -------------------------------------------------------------------------*/ + +int +ucmpv64( + const vint64 * lhs, + const vint64 * rhs + ) +{ + int res; + +#if defined(HAVE_INT64) + res = (lhs->Q_s > rhs->Q_s) + - (lhs->Q_s < rhs->Q_s); +#else + res = (lhs->D_s.hi > rhs->D_s.hi) + - (lhs->D_s.hi < rhs->D_s.hi); + if ( ! res ) + res = (lhs->D_s.lo > rhs->D_s.lo) + - (lhs->D_s.lo < rhs->D_s.lo); +#endif + return res; +} + +/* -------------------------------------------------------------------------*/ + +vint64 +addv64( + const vint64 *lhs, + const vint64 *rhs + ) +{ + vint64 res; + +#if defined(HAVE_INT64) + res.Q_s = lhs->Q_s + rhs->Q_s; +#else + res = *lhs; + M_ADD(res.D_s.hi, res.D_s.lo, rhs->D_s.hi, rhs->D_s.lo); +#endif + return res; +} + +/* -------------------------------------------------------------------------*/ + +vint64 +subv64( + const vint64 *lhs, + const vint64 *rhs + ) +{ + vint64 res; + +#if defined(HAVE_INT64) + res.Q_s = lhs->Q_s - rhs->Q_s; +#else + res = *lhs; + M_SUB(res.D_s.hi, res.D_s.lo, rhs->D_s.hi, rhs->D_s.lo); +#endif + return res; +} + +/* -------------------------------------------------------------------------*/ + +vint64 +addv64i32( + const vint64 * lhs, + int32_t rhs + ) +{ + vint64 res; + + res = *lhs; +#if defined(HAVE_INT64) + res.q_s += rhs; +#else + M_ADD(res.D_s.hi, res.D_s.lo, -(rhs < 0), rhs); +#endif + return res; +} + +/* -------------------------------------------------------------------------*/ + +vint64 +subv64i32( + const vint64 * lhs, + int32_t rhs + ) +{ + vint64 res; + + res = *lhs; +#if defined(HAVE_INT64) + res.q_s -= rhs; +#else + M_SUB(res.D_s.hi, res.D_s.lo, -(rhs < 0), rhs); +#endif + return res; +} + +/* -------------------------------------------------------------------------*/ + +vint64 +addv64u32( + const vint64 * lhs, + uint32_t rhs + ) +{ + vint64 res; + + res = *lhs; +#if defined(HAVE_INT64) + res.Q_s += rhs; +#else + M_ADD(res.D_s.hi, res.D_s.lo, 0, rhs); +#endif + return res; +} + +/* -------------------------------------------------------------------------*/ + +vint64 +subv64u32( + const vint64 * lhs, + uint32_t rhs + ) +{ + vint64 res; + + res = *lhs; +#if defined(HAVE_INT64) + res.Q_s -= rhs; +#else + M_SUB(res.D_s.hi, res.D_s.lo, 0, rhs); +#endif + return res; +} diff --git a/contrib/ntp/libntp/work_fork.c b/contrib/ntp/libntp/work_fork.c new file mode 100644 index 000000000..96c550e98 --- /dev/null +++ b/contrib/ntp/libntp/work_fork.c @@ -0,0 +1,545 @@ +/* + * work_fork.c - fork implementation for blocking worker child. + */ +#include +#include "ntp_workimpl.h" + +#ifdef WORK_FORK +#include +#include +#include +#include + +#include "iosignal.h" +#include "ntp_stdlib.h" +#include "ntp_malloc.h" +#include "ntp_syslog.h" +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_assert.h" +#include "ntp_unixtime.h" +#include "ntp_worker.h" + +/* === variables === */ + int worker_process; + addremove_io_fd_func addremove_io_fd; +static volatile int worker_sighup_received; + +/* === function prototypes === */ +static void fork_blocking_child(blocking_child *); +static RETSIGTYPE worker_sighup(int); +static void send_worker_home_atexit(void); +static void cleanup_after_child(blocking_child *); + +/* === functions === */ +/* + * exit_worker() + * + * On some systems _exit() is preferred to exit() for forked children. + * For example, http://netbsd.gw.com/cgi-bin/man-cgi?fork++NetBSD-5.0 + * recommends _exit() to avoid double-flushing C runtime stream buffers + * and also to avoid calling the parent's atexit() routines in the + * child. On those systems WORKER_CHILD_EXIT is _exit. Since _exit + * bypasses CRT cleanup, fflush() files we know might have output + * buffered. + */ +void +exit_worker( + int exitcode + ) +{ + if (syslog_file != NULL) + fflush(syslog_file); + fflush(stdout); + fflush(stderr); + WORKER_CHILD_EXIT (exitcode); /* space before ( required */ +} + + +static RETSIGTYPE +worker_sighup( + int sig + ) +{ + if (SIGHUP == sig) + worker_sighup_received = 1; +} + + +int +worker_sleep( + blocking_child * c, + time_t seconds + ) +{ + u_int sleep_remain; + + sleep_remain = (u_int)seconds; + do { + if (!worker_sighup_received) + sleep_remain = sleep(sleep_remain); + if (worker_sighup_received) { + TRACE(1, ("worker SIGHUP with %us left to sleep", + sleep_remain)); + worker_sighup_received = 0; + return -1; + } + } while (sleep_remain); + + return 0; +} + + +void +interrupt_worker_sleep(void) +{ + u_int idx; + blocking_child * c; + int rc; + + for (idx = 0; idx < blocking_children_alloc; idx++) { + c = blocking_children[idx]; + + if (NULL == c || c->reusable == TRUE) + continue; + + rc = kill(c->pid, SIGHUP); + if (rc < 0) + msyslog(LOG_ERR, + "Unable to signal HUP to wake child pid %d: %m", + c->pid); + } +} + + +/* + * harvest_child_status() runs in the parent. + */ +static void +harvest_child_status( + blocking_child * c + ) +{ + if (c->pid) + { + /* Wait on the child so it can finish terminating */ + if (waitpid(c->pid, NULL, 0) == c->pid) + TRACE(4, ("harvested child %d\n", c->pid)); + else msyslog(LOG_ERR, "error waiting on child %d: %m", c->pid); + } +} + +/* + * req_child_exit() runs in the parent. + */ +int +req_child_exit( + blocking_child * c + ) +{ + if (-1 != c->req_write_pipe) { + close(c->req_write_pipe); + c->req_write_pipe = -1; + return 0; + } + /* Closing the pipe forces the child to exit */ + harvest_child_status(c); + return -1; +} + + +/* + * cleanup_after_child() runs in parent. + */ +static void +cleanup_after_child( + blocking_child * c + ) +{ + harvest_child_status(c); + if (-1 != c->resp_read_pipe) { + (*addremove_io_fd)(c->resp_read_pipe, c->ispipe, TRUE); + close(c->resp_read_pipe); + c->resp_read_pipe = -1; + } + c->pid = 0; + c->resp_read_ctx = NULL; + DEBUG_INSIST(-1 == c->req_read_pipe); + DEBUG_INSIST(-1 == c->resp_write_pipe); + c->reusable = TRUE; +} + + +static void +send_worker_home_atexit(void) +{ + u_int idx; + blocking_child * c; + + if (worker_process) + return; + + for (idx = 0; idx < blocking_children_alloc; idx++) { + c = blocking_children[idx]; + if (NULL == c) + continue; + req_child_exit(c); + } +} + + +int +send_blocking_req_internal( + blocking_child * c, + blocking_pipe_header * hdr, + void * data + ) +{ + int octets; + int rc; + + DEBUG_REQUIRE(hdr != NULL); + DEBUG_REQUIRE(data != NULL); + DEBUG_REQUIRE(BLOCKING_REQ_MAGIC == hdr->magic_sig); + + if (-1 == c->req_write_pipe) { + fork_blocking_child(c); + DEBUG_INSIST(-1 != c->req_write_pipe); + } + + octets = sizeof(*hdr); + rc = write(c->req_write_pipe, hdr, octets); + + if (rc == octets) { + octets = hdr->octets - sizeof(*hdr); + rc = write(c->req_write_pipe, data, octets); + + if (rc == octets) + return 0; + } + + if (rc < 0) + msyslog(LOG_ERR, + "send_blocking_req_internal: pipe write: %m"); + else + msyslog(LOG_ERR, + "send_blocking_req_internal: short write %d of %d", + rc, octets); + + /* Fatal error. Clean up the child process. */ + req_child_exit(c); + exit(1); /* otherwise would be return -1 */ +} + + +blocking_pipe_header * +receive_blocking_req_internal( + blocking_child * c + ) +{ + blocking_pipe_header hdr; + blocking_pipe_header * req; + int rc; + long octets; + + DEBUG_REQUIRE(-1 != c->req_read_pipe); + + req = NULL; + + do { + rc = read(c->req_read_pipe, &hdr, sizeof(hdr)); + } while (rc < 0 && EINTR == errno); + + if (rc < 0) { + msyslog(LOG_ERR, + "receive_blocking_req_internal: pipe read %m"); + } else if (0 == rc) { + TRACE(4, ("parent closed request pipe, child %d terminating\n", + c->pid)); + } else if (rc != sizeof(hdr)) { + msyslog(LOG_ERR, + "receive_blocking_req_internal: short header read %d of %lu", + rc, (u_long)sizeof(hdr)); + } else { + INSIST(sizeof(hdr) < hdr.octets && hdr.octets < 4 * 1024); + req = emalloc(hdr.octets); + memcpy(req, &hdr, sizeof(*req)); + octets = hdr.octets - sizeof(hdr); + rc = read(c->req_read_pipe, (char *)req + sizeof(*req), + octets); + + if (rc < 0) + msyslog(LOG_ERR, + "receive_blocking_req_internal: pipe data read %m"); + else if (rc != octets) + msyslog(LOG_ERR, + "receive_blocking_req_internal: short read %d of %ld", + rc, octets); + else if (BLOCKING_REQ_MAGIC != req->magic_sig) + msyslog(LOG_ERR, + "receive_blocking_req_internal: packet header mismatch (0x%x)", + req->magic_sig); + else + return req; + } + + if (req != NULL) + free(req); + + return NULL; +} + + +int +send_blocking_resp_internal( + blocking_child * c, + blocking_pipe_header * resp + ) +{ + long octets; + int rc; + + DEBUG_REQUIRE(-1 != c->resp_write_pipe); + + octets = resp->octets; + rc = write(c->resp_write_pipe, resp, octets); + free(resp); + + if (octets == rc) + return 0; + + if (rc < 0) + TRACE(1, ("send_blocking_resp_internal: pipe write %m\n")); + else + TRACE(1, ("send_blocking_resp_internal: short write %d of %ld\n", + rc, octets)); + + return -1; +} + + +blocking_pipe_header * +receive_blocking_resp_internal( + blocking_child * c + ) +{ + blocking_pipe_header hdr; + blocking_pipe_header * resp; + int rc; + long octets; + + DEBUG_REQUIRE(c->resp_read_pipe != -1); + + resp = NULL; + rc = read(c->resp_read_pipe, &hdr, sizeof(hdr)); + + if (rc < 0) { + TRACE(1, ("receive_blocking_resp_internal: pipe read %m\n")); + } else if (0 == rc) { + /* this is the normal child exited indication */ + } else if (rc != sizeof(hdr)) { + TRACE(1, ("receive_blocking_resp_internal: short header read %d of %lu\n", + rc, (u_long)sizeof(hdr))); + } else if (BLOCKING_RESP_MAGIC != hdr.magic_sig) { + TRACE(1, ("receive_blocking_resp_internal: header mismatch (0x%x)\n", + hdr.magic_sig)); + } else { + INSIST(sizeof(hdr) < hdr.octets && + hdr.octets < 16 * 1024); + resp = emalloc(hdr.octets); + memcpy(resp, &hdr, sizeof(*resp)); + octets = hdr.octets - sizeof(hdr); + rc = read(c->resp_read_pipe, + (char *)resp + sizeof(*resp), + octets); + + if (rc < 0) + TRACE(1, ("receive_blocking_resp_internal: pipe data read %m\n")); + else if (rc < octets) + TRACE(1, ("receive_blocking_resp_internal: short read %d of %ld\n", + rc, octets)); + else + return resp; + } + + cleanup_after_child(c); + + if (resp != NULL) + free(resp); + + return NULL; +} + + +#if defined(HAVE_DROPROOT) && defined(WORK_FORK) +void +fork_deferred_worker(void) +{ + u_int idx; + blocking_child * c; + + REQUIRE(droproot && root_dropped); + + for (idx = 0; idx < blocking_children_alloc; idx++) { + c = blocking_children[idx]; + if (NULL == c) + continue; + if (-1 != c->req_write_pipe && 0 == c->pid) + fork_blocking_child(c); + } +} +#endif + + +static void +fork_blocking_child( + blocking_child * c + ) +{ + static int atexit_installed; + static int blocking_pipes[4] = { -1, -1, -1, -1 }; + int rc; + int was_pipe; + int is_pipe; + int saved_errno = 0; + int childpid; + int keep_fd; + int fd; + + /* + * parent and child communicate via a pair of pipes. + * + * 0 child read request + * 1 parent write request + * 2 parent read response + * 3 child write response + */ + if (-1 == c->req_write_pipe) { + rc = pipe_socketpair(&blocking_pipes[0], &was_pipe); + if (0 != rc) { + saved_errno = errno; + } else { + rc = pipe_socketpair(&blocking_pipes[2], &is_pipe); + if (0 != rc) { + saved_errno = errno; + close(blocking_pipes[0]); + close(blocking_pipes[1]); + } else { + INSIST(was_pipe == is_pipe); + } + } + if (0 != rc) { + errno = saved_errno; + msyslog(LOG_ERR, "unable to create worker pipes: %m"); + exit(1); + } + + /* + * Move the descriptors the parent will keep open out of the + * low descriptors preferred by C runtime buffered FILE *. + */ + c->req_write_pipe = move_fd(blocking_pipes[1]); + c->resp_read_pipe = move_fd(blocking_pipes[2]); + /* + * wake any worker child on orderly shutdown of the + * daemon so that it can notice the broken pipes and + * go away promptly. + */ + if (!atexit_installed) { + atexit(&send_worker_home_atexit); + atexit_installed = TRUE; + } + } + +#ifdef HAVE_DROPROOT + /* defer the fork until after root is dropped */ + if (droproot && !root_dropped) + return; +#endif + if (syslog_file != NULL) + fflush(syslog_file); + fflush(stdout); + fflush(stderr); + + signal_no_reset(SIGCHLD, SIG_IGN); + + childpid = fork(); + if (-1 == childpid) { + msyslog(LOG_ERR, "unable to fork worker: %m"); + exit(1); + } + + if (childpid) { + /* this is the parent */ + TRACE(1, ("forked worker child (pid %d)\n", childpid)); + c->pid = childpid; + c->ispipe = is_pipe; + + /* close the child's pipe descriptors. */ + close(blocking_pipes[0]); + close(blocking_pipes[3]); + + memset(blocking_pipes, -1, sizeof(blocking_pipes)); + + /* wire into I/O loop */ + (*addremove_io_fd)(c->resp_read_pipe, is_pipe, FALSE); + + return; /* parent returns */ + } + + /* + * The parent gets the child pid as the return value of fork(). + * The child must work for it. + */ + c->pid = getpid(); + worker_process = TRUE; + + /* + * In the child, close all files except stdin, stdout, stderr, + * and the two child ends of the pipes. + */ + DEBUG_INSIST(-1 == c->req_read_pipe); + DEBUG_INSIST(-1 == c->resp_write_pipe); + c->req_read_pipe = blocking_pipes[0]; + c->resp_write_pipe = blocking_pipes[3]; + + kill_asyncio(0); + closelog(); + if (syslog_file != NULL) { + fclose(syslog_file); + syslog_file = NULL; + syslogit = TRUE; + } + keep_fd = max(c->req_read_pipe, c->resp_write_pipe); + for (fd = 3; fd < keep_fd; fd++) + if (fd != c->req_read_pipe && + fd != c->resp_write_pipe) + close(fd); + close_all_beyond(keep_fd); + /* + * We get signals from refclock serial I/O on NetBSD in the + * worker if we do not reset SIGIO's handler to the default. + * It is not conditionalized for NetBSD alone because on + * systems where it is not needed, it is harmless, and that + * allows us to handle unknown others with NetBSD behavior. + * [Bug 1386] + */ +#if defined(USE_SIGIO) + signal_no_reset(SIGIO, SIG_DFL); +#elif defined(USE_SIGPOLL) + signal_no_reset(SIGPOLL, SIG_DFL); +#endif + signal_no_reset(SIGHUP, worker_sighup); + init_logging("ntp_intres", 0, FALSE); + setup_logfile(NULL); + + /* + * And now back to the portable code + */ + exit_worker(blocking_child_common(c)); +} + + +#else /* !WORK_FORK follows */ +char work_fork_nonempty_compilation_unit; +#endif diff --git a/contrib/ntp/libntp/work_thread.c b/contrib/ntp/libntp/work_thread.c new file mode 100644 index 000000000..38d87470f --- /dev/null +++ b/contrib/ntp/libntp/work_thread.c @@ -0,0 +1,726 @@ +/* + * work_thread.c - threads implementation for blocking worker child. + */ +#include +#include "ntp_workimpl.h" + +#ifdef WORK_THREAD + +#include +#include +#include +#ifndef SYS_WINNT +#include +#endif + +#include "ntp_stdlib.h" +#include "ntp_malloc.h" +#include "ntp_syslog.h" +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_assert.h" +#include "ntp_unixtime.h" +#include "timespecops.h" +#include "ntp_worker.h" + +#define CHILD_EXIT_REQ ((blocking_pipe_header *)(intptr_t)-1) +#define CHILD_GONE_RESP CHILD_EXIT_REQ +#define WORKITEMS_ALLOC_INC 16 +#define RESPONSES_ALLOC_INC 4 + +#ifndef THREAD_MINSTACKSIZE +#define THREAD_MINSTACKSIZE (64U * 1024) +#endif + +#ifndef DEVOLATILE +#define DEVOLATILE(type, var) ((type)(uintptr_t)(volatile void *)(var)) +#endif + +#ifdef SYS_WINNT +# define thread_exit(c) _endthreadex(c) +# define tickle_sem SetEvent +#else +# define thread_exit(c) pthread_exit((void*)(size_t)(c)) +# define tickle_sem sem_post +#endif + +#ifdef WORK_PIPE +addremove_io_fd_func addremove_io_fd; +#else +addremove_io_semaphore_func addremove_io_semaphore; +#endif + +static void start_blocking_thread(blocking_child *); +static void start_blocking_thread_internal(blocking_child *); +static void prepare_child_sems(blocking_child *); +static int wait_for_sem(sem_ref, struct timespec *); +static void ensure_workitems_empty_slot(blocking_child *); +static void ensure_workresp_empty_slot(blocking_child *); +static int queue_req_pointer(blocking_child *, blocking_pipe_header *); +static void cleanup_after_child(blocking_child *); +#ifdef SYS_WINNT +u_int WINAPI blocking_thread(void *); +#else +void * blocking_thread(void *); +#endif +#ifndef SYS_WINNT +static void block_thread_signals(sigset_t *); +#endif + + +void +exit_worker( + int exitcode + ) +{ + thread_exit(exitcode); /* see #define thread_exit */ +} + + +int +worker_sleep( + blocking_child * c, + time_t seconds + ) +{ + struct timespec until; + int rc; + +# ifdef HAVE_CLOCK_GETTIME + if (0 != clock_gettime(CLOCK_REALTIME, &until)) { + msyslog(LOG_ERR, "worker_sleep: clock_gettime() failed: %m"); + return -1; + } +# else + if (0 != getclock(TIMEOFDAY, &until)) { + msyslog(LOG_ERR, "worker_sleep: getclock() failed: %m"); + return -1; + } +# endif + until.tv_sec += seconds; + do { + rc = wait_for_sem(c->wake_scheduled_sleep, &until); + } while (-1 == rc && EINTR == errno); + if (0 == rc) + return -1; + if (-1 == rc && ETIMEDOUT == errno) + return 0; + msyslog(LOG_ERR, "worker_sleep: sem_timedwait: %m"); + return -1; +} + + +void +interrupt_worker_sleep(void) +{ + u_int idx; + blocking_child * c; + + for (idx = 0; idx < blocking_children_alloc; idx++) { + c = blocking_children[idx]; + if (NULL == c || NULL == c->wake_scheduled_sleep) + continue; + tickle_sem(c->wake_scheduled_sleep); + } +} + + +static void +ensure_workitems_empty_slot( + blocking_child *c + ) +{ + const size_t each = sizeof(blocking_children[0]->workitems[0]); + size_t new_alloc; + size_t old_octets; + size_t new_octets; + void * nonvol_workitems; + + + if (c->workitems != NULL && + NULL == c->workitems[c->next_workitem]) + return; + + new_alloc = c->workitems_alloc + WORKITEMS_ALLOC_INC; + old_octets = c->workitems_alloc * each; + new_octets = new_alloc * each; + nonvol_workitems = DEVOLATILE(void *, c->workitems); + c->workitems = erealloc_zero(nonvol_workitems, new_octets, + old_octets); + if (0 == c->next_workitem) + c->next_workitem = c->workitems_alloc; + c->workitems_alloc = new_alloc; +} + + +static void +ensure_workresp_empty_slot( + blocking_child *c + ) +{ + const size_t each = sizeof(blocking_children[0]->responses[0]); + size_t new_alloc; + size_t old_octets; + size_t new_octets; + void * nonvol_responses; + + if (c->responses != NULL && + NULL == c->responses[c->next_response]) + return; + + new_alloc = c->responses_alloc + RESPONSES_ALLOC_INC; + old_octets = c->responses_alloc * each; + new_octets = new_alloc * each; + nonvol_responses = DEVOLATILE(void *, c->responses); + c->responses = erealloc_zero(nonvol_responses, new_octets, + old_octets); + if (0 == c->next_response) + c->next_response = c->responses_alloc; + c->responses_alloc = new_alloc; +} + + +/* + * queue_req_pointer() - append a work item or idle exit request to + * blocking_workitems[]. + */ +static int +queue_req_pointer( + blocking_child * c, + blocking_pipe_header * hdr + ) +{ + c->workitems[c->next_workitem] = hdr; + c->next_workitem = (1 + c->next_workitem) % c->workitems_alloc; + + /* + * We only want to signal the wakeup event if the child is + * blocking on it, which is indicated by setting the blocking + * event. Wait with zero timeout to test. + */ + /* !!!! if (WAIT_OBJECT_0 == WaitForSingleObject(c->child_is_blocking, 0)) */ + tickle_sem(c->blocking_req_ready); + + return 0; +} + + +int +send_blocking_req_internal( + blocking_child * c, + blocking_pipe_header * hdr, + void * data + ) +{ + blocking_pipe_header * threadcopy; + size_t payload_octets; + + REQUIRE(hdr != NULL); + REQUIRE(data != NULL); + DEBUG_REQUIRE(BLOCKING_REQ_MAGIC == hdr->magic_sig); + + if (hdr->octets <= sizeof(*hdr)) + return 1; /* failure */ + payload_octets = hdr->octets - sizeof(*hdr); + + ensure_workitems_empty_slot(c); + if (NULL == c->thread_ref) { + ensure_workresp_empty_slot(c); + start_blocking_thread(c); + } + + threadcopy = emalloc(hdr->octets); + memcpy(threadcopy, hdr, sizeof(*hdr)); + memcpy((char *)threadcopy + sizeof(*hdr), data, payload_octets); + + return queue_req_pointer(c, threadcopy); +} + + +blocking_pipe_header * +receive_blocking_req_internal( + blocking_child * c + ) +{ + blocking_pipe_header * req; + int rc; + + /* + * Child blocks here when idle. SysV semaphores maintain a + * count and release from sem_wait() only when it reaches 0. + * Windows auto-reset events are simpler, and multiple SetEvent + * calls before any thread waits result in a single wakeup. + * On Windows, the child drains all workitems each wakeup, while + * with SysV semaphores wait_sem() is used before each item. + */ +#ifdef SYS_WINNT + while (NULL == c->workitems[c->next_workeritem]) { + /* !!!! SetEvent(c->child_is_blocking); */ + rc = wait_for_sem(c->blocking_req_ready, NULL); + INSIST(0 == rc); + /* !!!! ResetEvent(c->child_is_blocking); */ + } +#else + do { + rc = wait_for_sem(c->blocking_req_ready, NULL); + } while (-1 == rc && EINTR == errno); + INSIST(0 == rc); +#endif + + req = c->workitems[c->next_workeritem]; + INSIST(NULL != req); + c->workitems[c->next_workeritem] = NULL; + c->next_workeritem = (1 + c->next_workeritem) % + c->workitems_alloc; + + if (CHILD_EXIT_REQ == req) { /* idled out */ + send_blocking_resp_internal(c, CHILD_GONE_RESP); + req = NULL; + } + + return req; +} + + +int +send_blocking_resp_internal( + blocking_child * c, + blocking_pipe_header * resp + ) +{ + ensure_workresp_empty_slot(c); + + c->responses[c->next_response] = resp; + c->next_response = (1 + c->next_response) % c->responses_alloc; + +#ifdef WORK_PIPE + write(c->resp_write_pipe, "", 1); +#else + tickle_sem(c->blocking_response_ready); +#endif + + return 0; +} + + +#ifndef WORK_PIPE +void +handle_blocking_resp_sem( + void * context + ) +{ + HANDLE ready; + blocking_child * c; + u_int idx; + + ready = (HANDLE)context; + c = NULL; + for (idx = 0; idx < blocking_children_alloc; idx++) { + c = blocking_children[idx]; + if (c != NULL && c->thread_ref != NULL && + ready == c->blocking_response_ready) + break; + } + if (idx < blocking_children_alloc) + process_blocking_resp(c); +} +#endif /* !WORK_PIPE */ + + +blocking_pipe_header * +receive_blocking_resp_internal( + blocking_child * c + ) +{ + blocking_pipe_header * removed; +#ifdef WORK_PIPE + int rc; + char scratch[32]; + + do { + rc = read(c->resp_read_pipe, scratch, sizeof(scratch)); + } while (-1 == rc && EINTR == errno); +#endif + removed = c->responses[c->next_workresp]; + if (NULL != removed) { + c->responses[c->next_workresp] = NULL; + c->next_workresp = (1 + c->next_workresp) % + c->responses_alloc; + DEBUG_ENSURE(CHILD_GONE_RESP == removed || + BLOCKING_RESP_MAGIC == removed->magic_sig); + } + if (CHILD_GONE_RESP == removed) { + cleanup_after_child(c); + removed = NULL; + } + + return removed; +} + + +static void +start_blocking_thread( + blocking_child * c + ) +{ + + DEBUG_INSIST(!c->reusable); + + prepare_child_sems(c); + start_blocking_thread_internal(c); +} + + +static void +start_blocking_thread_internal( + blocking_child * c + ) +#ifdef SYS_WINNT +{ + thr_ref blocking_child_thread; + u_int blocking_thread_id; + BOOL resumed; + + (*addremove_io_semaphore)(c->blocking_response_ready, FALSE); + blocking_child_thread = + (HANDLE)_beginthreadex( + NULL, + 0, + &blocking_thread, + c, + CREATE_SUSPENDED, + &blocking_thread_id); + + if (NULL == blocking_child_thread) { + msyslog(LOG_ERR, "start blocking thread failed: %m"); + exit(-1); + } + c->thread_id = blocking_thread_id; + c->thread_ref = blocking_child_thread; + /* remember the thread priority is only within the process class */ + if (!SetThreadPriority(blocking_child_thread, + THREAD_PRIORITY_BELOW_NORMAL)) + msyslog(LOG_ERR, "Error lowering blocking thread priority: %m"); + + resumed = ResumeThread(blocking_child_thread); + DEBUG_INSIST(resumed); +} +#else /* pthreads start_blocking_thread_internal() follows */ +{ +# ifdef NEED_PTHREAD_INIT + static int pthread_init_called; +# endif + pthread_attr_t thr_attr; + int rc; + int saved_errno; + int pipe_ends[2]; /* read then write */ + int is_pipe; + int flags; + size_t stacksize; + sigset_t saved_sig_mask; + +# ifdef NEED_PTHREAD_INIT + /* + * from lib/isc/unix/app.c: + * BSDI 3.1 seg faults in pthread_sigmask() if we don't do this. + */ + if (!pthread_init_called) { + pthread_init(); + pthread_init_called = TRUE; + } +# endif + + rc = pipe_socketpair(&pipe_ends[0], &is_pipe); + if (0 != rc) { + msyslog(LOG_ERR, "start_blocking_thread: pipe_socketpair() %m"); + exit(1); + } + c->resp_read_pipe = move_fd(pipe_ends[0]); + c->resp_write_pipe = move_fd(pipe_ends[1]); + c->ispipe = is_pipe; + flags = fcntl(c->resp_read_pipe, F_GETFL, 0); + if (-1 == flags) { + msyslog(LOG_ERR, "start_blocking_thread: fcntl(F_GETFL) %m"); + exit(1); + } + rc = fcntl(c->resp_read_pipe, F_SETFL, O_NONBLOCK | flags); + if (-1 == rc) { + msyslog(LOG_ERR, + "start_blocking_thread: fcntl(F_SETFL, O_NONBLOCK) %m"); + exit(1); + } + (*addremove_io_fd)(c->resp_read_pipe, c->ispipe, FALSE); + pthread_attr_init(&thr_attr); + pthread_attr_setdetachstate(&thr_attr, PTHREAD_CREATE_DETACHED); +#if defined(HAVE_PTHREAD_ATTR_GETSTACKSIZE) && \ + defined(HAVE_PTHREAD_ATTR_SETSTACKSIZE) + rc = pthread_attr_getstacksize(&thr_attr, &stacksize); + if (-1 == rc) { + msyslog(LOG_ERR, + "start_blocking_thread: pthread_attr_getstacksize %m"); + } else if (stacksize < THREAD_MINSTACKSIZE) { + rc = pthread_attr_setstacksize(&thr_attr, + THREAD_MINSTACKSIZE); + if (-1 == rc) + msyslog(LOG_ERR, + "start_blocking_thread: pthread_attr_setstacksize(0x%lx -> 0x%lx) %m", + (u_long)stacksize, + (u_long)THREAD_MINSTACKSIZE); + } +#else + UNUSED_ARG(stacksize); +#endif +#if defined(PTHREAD_SCOPE_SYSTEM) && defined(NEED_PTHREAD_SCOPE_SYSTEM) + pthread_attr_setscope(&thr_attr, PTHREAD_SCOPE_SYSTEM); +#endif + c->thread_ref = emalloc_zero(sizeof(*c->thread_ref)); + block_thread_signals(&saved_sig_mask); + rc = pthread_create(c->thread_ref, &thr_attr, + &blocking_thread, c); + saved_errno = errno; + pthread_sigmask(SIG_SETMASK, &saved_sig_mask, NULL); + pthread_attr_destroy(&thr_attr); + if (0 != rc) { + errno = saved_errno; + msyslog(LOG_ERR, "pthread_create() blocking child: %m"); + exit(1); + } +} +#endif + + +/* + * block_thread_signals() + * + * Temporarily block signals used by ntpd main thread, so that signal + * mask inherited by child threads leaves them blocked. Returns prior + * active signal mask via pmask, to be restored by the main thread + * after pthread_create(). + */ +#ifndef SYS_WINNT +void +block_thread_signals( + sigset_t * pmask + ) +{ + sigset_t block; + + sigemptyset(&block); +# ifdef HAVE_SIGNALED_IO +# ifdef SIGIO + sigaddset(&block, SIGIO); +# endif +# ifdef SIGPOLL + sigaddset(&block, SIGPOLL); +# endif +# endif /* HAVE_SIGNALED_IO */ + sigaddset(&block, SIGALRM); + sigaddset(&block, MOREDEBUGSIG); + sigaddset(&block, LESSDEBUGSIG); +# ifdef SIGDIE1 + sigaddset(&block, SIGDIE1); +# endif +# ifdef SIGDIE2 + sigaddset(&block, SIGDIE2); +# endif +# ifdef SIGDIE3 + sigaddset(&block, SIGDIE3); +# endif +# ifdef SIGDIE4 + sigaddset(&block, SIGDIE4); +# endif +# ifdef SIGBUS + sigaddset(&block, SIGBUS); +# endif + sigemptyset(pmask); + pthread_sigmask(SIG_BLOCK, &block, pmask); +} +#endif /* !SYS_WINNT */ + + +/* + * prepare_child_sems() + * + * create sync events (semaphores) + * child_is_blocking initially unset + * blocking_req_ready initially unset + * + * Child waits for blocking_req_ready to be set after + * setting child_is_blocking. blocking_req_ready and + * blocking_response_ready are auto-reset, so wake one + * waiter and become unset (unsignalled) in one operation. + */ +static void +prepare_child_sems( + blocking_child *c + ) +#ifdef SYS_WINNT +{ + if (NULL == c->blocking_req_ready) { + /* manual reset using ResetEvent() */ + /* !!!! c->child_is_blocking = CreateEvent(NULL, TRUE, FALSE, NULL); */ + /* auto reset - one thread released from wait each set */ + c->blocking_req_ready = CreateEvent(NULL, FALSE, FALSE, NULL); + c->blocking_response_ready = CreateEvent(NULL, FALSE, FALSE, NULL); + c->wake_scheduled_sleep = CreateEvent(NULL, FALSE, FALSE, NULL); + } else { + /* !!!! ResetEvent(c->child_is_blocking); */ + /* ResetEvent(c->blocking_req_ready); */ + /* ResetEvent(c->blocking_response_ready); */ + /* ResetEvent(c->wake_scheduled_sleep); */ + } +} +#else /* pthreads prepare_child_sems() follows */ +{ + size_t octets; + + if (NULL == c->blocking_req_ready) { + octets = sizeof(*c->blocking_req_ready); + octets += sizeof(*c->wake_scheduled_sleep); + /* !!!! octets += sizeof(*c->child_is_blocking); */ + c->blocking_req_ready = emalloc_zero(octets);; + c->wake_scheduled_sleep = 1 + c->blocking_req_ready; + /* !!!! c->child_is_blocking = 1 + c->wake_scheduled_sleep; */ + } else { + sem_destroy(c->blocking_req_ready); + sem_destroy(c->wake_scheduled_sleep); + /* !!!! sem_destroy(c->child_is_blocking); */ + } + sem_init(c->blocking_req_ready, FALSE, 0); + sem_init(c->wake_scheduled_sleep, FALSE, 0); + /* !!!! sem_init(c->child_is_blocking, FALSE, 0); */ +} +#endif + + +static int +wait_for_sem( + sem_ref sem, + struct timespec * timeout /* wall-clock */ + ) +#ifdef SYS_WINNT +{ + struct timespec now; + struct timespec delta; + DWORD msec; + DWORD rc; + + if (NULL == timeout) { + msec = INFINITE; + } else { + getclock(TIMEOFDAY, &now); + delta = sub_tspec(*timeout, now); + if (delta.tv_sec < 0) { + msec = 0; + } else if ((delta.tv_sec + 1) >= (MAXDWORD / 1000)) { + msec = INFINITE; + } else { + msec = 1000 * (DWORD)delta.tv_sec; + msec += delta.tv_nsec / (1000 * 1000); + } + } + rc = WaitForSingleObject(sem, msec); + if (WAIT_OBJECT_0 == rc) + return 0; + if (WAIT_TIMEOUT == rc) { + errno = ETIMEDOUT; + return -1; + } + msyslog(LOG_ERR, "WaitForSingleObject unexpected 0x%x", rc); + errno = EFAULT; + return -1; +} +#else /* pthreads wait_for_sem() follows */ +{ + int rc; + + if (NULL == timeout) + rc = sem_wait(sem); + else + rc = sem_timedwait(sem, timeout); + + return rc; +} +#endif + + +/* + * blocking_thread - thread functions have WINAPI calling convention + */ +#ifdef SYS_WINNT +u_int +WINAPI +#else +void * +#endif +blocking_thread( + void * ThreadArg + ) +{ + blocking_child *c; + + c = ThreadArg; + exit_worker(blocking_child_common(c)); + + /* NOTREACHED */ + return 0; +} + + +/* + * req_child_exit() runs in the parent. + */ +int +req_child_exit( + blocking_child *c + ) +{ + return queue_req_pointer(c, CHILD_EXIT_REQ); +} + + +/* + * cleanup_after_child() runs in parent. + */ +static void +cleanup_after_child( + blocking_child * c + ) +{ + u_int idx; + + DEBUG_INSIST(!c->reusable); +#ifdef SYS_WINNT + INSIST(CloseHandle(c->thread_ref)); +#else + free(c->thread_ref); +#endif + c->thread_ref = NULL; + c->thread_id = 0; +#ifdef WORK_PIPE + DEBUG_INSIST(-1 != c->resp_read_pipe); + DEBUG_INSIST(-1 != c->resp_write_pipe); + (*addremove_io_fd)(c->resp_read_pipe, c->ispipe, TRUE); + close(c->resp_write_pipe); + close(c->resp_read_pipe); + c->resp_write_pipe = -1; + c->resp_read_pipe = -1; +#else + DEBUG_INSIST(NULL != c->blocking_response_ready); + (*addremove_io_semaphore)(c->blocking_response_ready, TRUE); +#endif + for (idx = 0; idx < c->workitems_alloc; idx++) + c->workitems[idx] = NULL; + c->next_workitem = 0; + c->next_workeritem = 0; + for (idx = 0; idx < c->responses_alloc; idx++) + c->responses[idx] = NULL; + c->next_response = 0; + c->next_workresp = 0; + c->reusable = TRUE; +} + + +#else /* !WORK_THREAD follows */ +char work_thread_nonempty_compilation_unit; +#endif diff --git a/contrib/ntp/libntp/ymd2yd.c b/contrib/ntp/libntp/ymd2yd.c index 796ce4094..c6b3a0cad 100644 --- a/contrib/ntp/libntp/ymd2yd.c +++ b/contrib/ntp/libntp/ymd2yd.c @@ -1,37 +1,26 @@ /* * ymd2yd - compute the date in the year from y/m/d + * + * A thin wrapper around a more general calendar function. */ -#include "ntp_fp.h" -#include "ntp_unixtime.h" +#include #include "ntp_stdlib.h" - -/* - * Tables to compute the day of year from yyyymmdd timecode. - * Viva la leap. - */ -static int day1tab[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; -static int day2tab[] = {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; +#include "ntp_calendar.h" int ymd2yd( int y, int m, - int d - ) + int d) { - int i, *t; - - if (m < 1 || m > 12 || d < 1) - return (-1); - - if (((y%4 == 0) && (y%100 != 0)) || (y%400 == 0)) - t = day2tab; /* leap year */ - else - t = day1tab; /* not a leap year */ - if (d > t[m - 1]) - return (-1); - for (i = 0; i < m - 1; i++) - d += t[i]; - return d; + /* + * convert y/m/d to elapsed calendar units, convert that to + * elapsed days since the start of the given year and convert + * back to unity-based day in year. + * + * This does no further error checking, since the underlying + * function is assumed to work out how to handle the data. + */ + return ntpcal_edate_to_yeardays(y-1, m-1, d-1) + 1; } diff --git a/contrib/ntp/libopts/COPYING.lgpl b/contrib/ntp/libopts/COPYING.lgpl deleted file mode 100644 index 129c5de4f..000000000 --- a/contrib/ntp/libopts/COPYING.lgpl +++ /dev/null @@ -1,502 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Libraries - - If you develop a new library, and you want it to be of the greatest -possible use to the public, we recommend making it free software that -everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms of the -ordinary General Public License). - - To apply these terms, attach the following notices to the library. It is -safest to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least the -"copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - -Also add information on how to contact you by electronic and paper mail. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the library, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James Random Hacker. - - , 1 April 1990 - Ty Coon, President of Vice - -That's all there is to it! diff --git a/contrib/ntp/libopts/COPYING.mbsd b/contrib/ntp/libopts/COPYING.mbsd deleted file mode 100644 index 8a7042719..000000000 --- a/contrib/ntp/libopts/COPYING.mbsd +++ /dev/null @@ -1,26 +0,0 @@ -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - 2. Redistributions in binary form must reproduce the above - copyright notice, this list of conditions and the following - disclaimer in the documentation and/or other materials provided - with the distribution. - - 3. The name of the author may not be used to endorse or promote - products derived from this software without specific prior - written permission. - -THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR -IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, -INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING -IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -POSSIBILITY OF SUCH DAMAGE. diff --git a/contrib/ntp/libopts/Makefile.am b/contrib/ntp/libopts/Makefile.am deleted file mode 100644 index 5f1386144..000000000 --- a/contrib/ntp/libopts/Makefile.am +++ /dev/null @@ -1,24 +0,0 @@ -## LIBOPTS Makefile -MAINTAINERCLEANFILES = Makefile.in -if INSTALL_LIBOPTS -lib_LTLIBRARIES = libopts.la -else -noinst_LTLIBRARIES = libopts.la -endif -libopts_la_SOURCES = libopts.c -libopts_la_CPPFLAGS = -I$(top_srcdir) -libopts_la_LDFLAGS = -version-info 29:0:4 -EXTRA_DIST = \ - COPYING.lgpl COPYING.mbsd MakeDefs.inc \ - README autoopts/options.h autoopts/usage-txt.h \ - autoopts.c autoopts.h boolean.c \ - compat/windows-config.h compat/compat.h compat/pathfind.c \ - compat/snprintf.c compat/strdup.c compat/strchr.c \ - configfile.c cook.c enumeration.c \ - environment.c genshell.c genshell.h \ - load.c m4/libopts.m4 m4/liboptschk.m4 \ - makeshell.c nested.c numeric.c \ - pgusage.c proto.h putshell.c \ - restore.c save.c sort.c \ - stack.c streqvcmp.c text_mmap.c \ - tokenize.c usage.c version.c diff --git a/contrib/ntp/libopts/Makefile.in b/contrib/ntp/libopts/Makefile.in deleted file mode 100644 index 6a4d03e36..000000000 --- a/contrib/ntp/libopts/Makefile.in +++ /dev/null @@ -1,579 +0,0 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = libopts -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__installdirs = "$(DESTDIR)$(libdir)" -LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES) -libopts_la_LIBADD = -am_libopts_la_OBJECTS = libopts_la-libopts.lo -libopts_la_OBJECTS = $(am_libopts_la_OBJECTS) -libopts_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(libopts_la_LDFLAGS) $(LDFLAGS) -o $@ -@INSTALL_LIBOPTS_FALSE@am_libopts_la_rpath = -@INSTALL_LIBOPTS_TRUE@am_libopts_la_rpath = -rpath $(libdir) -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ -SOURCES = $(libopts_la_SOURCES) -DIST_SOURCES = $(libopts_la_SOURCES) -ETAGS = etags -CTAGS = ctags -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DCFD = @DCFD@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -ECHO = @ECHO@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -GREP = @GREP@ -HAVE_INLINE = @HAVE_INLINE@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ -LIBOPTS_DIR = @LIBOPTS_DIR@ -LIBOPTS_LDADD = @LIBOPTS_LDADD@ -LIBPARSE = @LIBPARSE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LN_S = @LN_S@ -LSCF = @LSCF@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MAKE_ADJTIMED = @MAKE_ADJTIMED@ -MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ -MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ -MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ -MAKE_LIBPARSE = @MAKE_LIBPARSE@ -MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ -MAKE_NTPDSIM = @MAKE_NTPDSIM@ -MAKE_NTPTIME = @MAKE_NTPTIME@ -MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ -MAKE_TICKADJ = @MAKE_TICKADJ@ -MAKE_TIMETRIM = @MAKE_TIMETRIM@ -MKDIR_P = @MKDIR_P@ -OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_PERL = @PATH_PERL@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ -PROPDELAY = @PROPDELAY@ -RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -TESTDCF = @TESTDCF@ -U = @U@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_CC = @ac_ct_CC@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -subdirs = @subdirs@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -MAINTAINERCLEANFILES = Makefile.in -@INSTALL_LIBOPTS_TRUE@lib_LTLIBRARIES = libopts.la -@INSTALL_LIBOPTS_FALSE@noinst_LTLIBRARIES = libopts.la -libopts_la_SOURCES = libopts.c -libopts_la_CPPFLAGS = -I$(top_srcdir) -libopts_la_LDFLAGS = -version-info 29:0:4 -EXTRA_DIST = \ - COPYING.lgpl COPYING.mbsd MakeDefs.inc \ - README autoopts/options.h autoopts/usage-txt.h \ - autoopts.c autoopts.h boolean.c \ - compat/windows-config.h compat/compat.h compat/pathfind.c \ - compat/snprintf.c compat/strdup.c compat/strchr.c \ - configfile.c cook.c enumeration.c \ - environment.c genshell.c genshell.h \ - load.c m4/libopts.m4 m4/liboptschk.m4 \ - makeshell.c nested.c numeric.c \ - pgusage.c proto.h putshell.c \ - restore.c save.c sort.c \ - stack.c streqvcmp.c text_mmap.c \ - tokenize.c usage.c version.c - -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign libopts/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign libopts/Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): -install-libLTLIBRARIES: $(lib_LTLIBRARIES) - @$(NORMAL_INSTALL) - test -z "$(libdir)" || $(MKDIR_P) "$(DESTDIR)$(libdir)" - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ - } - -uninstall-libLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ - done - -clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) - @list='$(lib_LTLIBRARIES)'; for p in $$list; do \ - dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ - test "$$dir" != "$$p" || dir=.; \ - echo "rm -f \"$${dir}/so_locations\""; \ - rm -f "$${dir}/so_locations"; \ - done - -clean-noinstLTLIBRARIES: - -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) - @list='$(noinst_LTLIBRARIES)'; for p in $$list; do \ - dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ - test "$$dir" != "$$p" || dir=.; \ - echo "rm -f \"$${dir}/so_locations\""; \ - rm -f "$${dir}/so_locations"; \ - done -libopts.la: $(libopts_la_OBJECTS) $(libopts_la_DEPENDENCIES) - $(libopts_la_LINK) $(am_libopts_la_rpath) $(libopts_la_OBJECTS) $(libopts_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libopts_la-libopts.Plo@am__quote@ - -.c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< - -.c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< - -libopts_la-libopts.lo: libopts.c -@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libopts_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libopts_la-libopts.lo -MD -MP -MF $(DEPDIR)/libopts_la-libopts.Tpo -c -o libopts_la-libopts.lo `test -f 'libopts.c' || echo '$(srcdir)/'`libopts.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/libopts_la-libopts.Tpo $(DEPDIR)/libopts_la-libopts.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='libopts.c' object='libopts_la-libopts.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libopts_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libopts_la-libopts.lo `test -f 'libopts.c' || echo '$(srcdir)/'`libopts.c - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - set x; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(LTLIBRARIES) -installdirs: - for dir in "$(DESTDIR)$(libdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." - -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) -clean: clean-am - -clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ - clean-noinstLTLIBRARIES mostlyclean-am - -distclean: distclean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: install-libLTLIBRARIES - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-libLTLIBRARIES - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-libLTLIBRARIES clean-libtool clean-noinstLTLIBRARIES \ - ctags distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-libLTLIBRARIES install-man install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags uninstall uninstall-am uninstall-libLTLIBRARIES - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/contrib/ntp/libopts/README b/contrib/ntp/libopts/README deleted file mode 100644 index 7cbe0b044..000000000 --- a/contrib/ntp/libopts/README +++ /dev/null @@ -1,93 +0,0 @@ - THIS TARBALL IS NOT A FULL DISTRIBUTION. - -The contents of this tarball is designed to be incorporated into -software packages that utilize the AutoOpts option automation -package and are intended to be installed on systems that may not -have libopts installed. It is redistributable under the terms -of either the LGPL (see COPYING.lgpl) or under the terms of -the advertising clause free BSD license (see COPYING.mbsd). - -Usage Instructions for autoconf/automake/libtoolized projects: - -1. Install the unrolled tarball into your package source tree, - copying ``libopts.m4'' to your autoconf macro directory. - - In your bootstrap (pre-configure) script, you can do this: - - rm -rf libopts libopts-* - gunzip -c `autoopts-config libsrc` | tar -xvf - - mv -f libopts-*.*.* libopts - cp -fp libopts/m4/*.m4 m4/. - - I tend to put my configure auxiliary files in "m4". - Whatever directory you choose, if it is not ".", then - be sure to tell autoconf about it with: - - AC_CONFIG_AUX_DIR(m4) - - This is one macro where you *MUST* remember to *NOT* quote - the argument. If you do, automake will get lost. - -2. Add the following to your ``configure.ac'' file: - - LIBOPTS_CHECK - - or: - - LIBOPTS_CHECK([relative/path/to/libopts]) - - This macro will automatically invoke - - AC_CONFIG_FILES( [relative/path/to/libopts/Makefile] ) - - The default ``relative/path/to/libopts'' is simply - ``libopts''. - -3. Add the following to your top level ``Makefile.am'' file: - - if NEED_LIBOPTS - SUBDIRS += $(LIBOPTS_DIR) - endif - - where ``<...>'' can be whatever other files or directories - you may need. The SUBDIRS must be properly ordered. - *PLEASE NOTE* it is crucial that the SUBDIRS be set under the - control of an automake conditional. To work correctly, - automake has to know the range of possible values of SUBDIRS. - It's a magical name with magical properties. ``NEED_LIBOPTS'' - will be correctly set by the ``LIBOPTS_CHECK'' macro, above. - -4. Add ``$(LIBOPTS_CFLAGS)'' to relevant compiler flags and - ``$(LIBOPTS_LDADD)'' to relevant link options whereever - you need them in your build tree. - -5. Make sure your object files explicitly depend upon the - generated options header file. e.g.: - - $(prog_OBJECTS) : prog-opts.h - prog-opts.h : prog-opts.c - prog-opts.c : prog-opts.def - autogen prog-opts.def - -6. *OPTIONAL* -- - If you are creating man pages and texi documentation from - the program options, you will need these rules somewhere, too: - - man_MANS = prog.1 - prog.1 : prog-opts.def - autogen -Tagman1.tpl -bprog prog-opts.def - - prog-invoke.texi : prog-opts.def - autogen -Taginfo.tpl -bprog-invoke prog-opts.def - -If your package does not utilize the auto* tools, then you -will need to hand craft the rules for building the library. - -LICENSING: - -This material is copyright 1993-2007 by Bruce Korb. -You are licensed to use this under the terms of either -the GNU Lesser General Public License (see: COPYING.lgpl), or, -at your option, the modified Berkeley Software Distribution -License (see: COPYING.mbsd). Both of these files should be -included with this tarball. diff --git a/contrib/ntp/libopts/autoopts.c b/contrib/ntp/libopts/autoopts.c deleted file mode 100644 index 139841bbb..000000000 --- a/contrib/ntp/libopts/autoopts.c +++ /dev/null @@ -1,1120 +0,0 @@ - -/* - * $Id: autoopts.c,v 4.25 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:10:40 bkorb" - * - * This file contains all of the routines that must be linked into - * an executable to use the generated option processing. The optional - * routines are in separately compiled modules so that they will not - * necessarily be linked in. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -static char const zNil[] = ""; - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static tSuccess -findOptDesc( tOptions* pOpts, tOptState* pOptState ); - -static tSuccess -nextOption( tOptions* pOpts, tOptState* pOptState ); - -static tSuccess -doPresets( tOptions* pOpts ); - -static int -checkConsistency( tOptions* pOpts ); -/* = = = END-STATIC-FORWARD = = = */ - -LOCAL void * -ao_malloc( size_t sz ) -{ - void * res = malloc(sz); - if (res == NULL) { - fprintf( stderr, "malloc of %d bytes failed\n", (int)sz ); - exit( EXIT_FAILURE ); - } - return res; -} -#undef malloc -#define malloc(_s) ao_malloc(_s) - -LOCAL void * -ao_realloc( void *p, size_t sz ) -{ - void * res = realloc(p, sz); - if (res == NULL) { - fprintf( stderr, "realloc of %d bytes at 0x%p failed\n", (int)sz, p ); - exit( EXIT_FAILURE ); - } - return res; -} -#undef realloc -#define realloc(_p,_s) ao_realloc(_p,_s) - - -LOCAL void -ao_free( void *p ) -{ - if (p != NULL) - free(p); -} -#undef free -#define free(_p) ao_free(_p) - - -LOCAL char * -ao_strdup( char const *str ) -{ - char * res = strdup(str); - if (res == NULL) { - fprintf( stderr, "strdup of %d byte string failed\n", (int)strlen(str) ); - exit( EXIT_FAILURE ); - } - return res; -} -#undef strdup -#define strdup(_p) ao_strdup(_p) - -#ifndef HAVE_PATHFIND -# include "compat/pathfind.c" -#endif - -#ifndef HAVE_SNPRINTF -# include "compat/snprintf.c" -#endif - -#ifndef HAVE_STRDUP -# include "compat/strdup.c" -#endif - -#ifndef HAVE_STRCHR -# include "compat/strchr.c" -#endif - -/* - * handleOption - * - * This routine handles equivalencing, sets the option state flags and - * invokes the handler procedure, if any. - */ -LOCAL tSuccess -handleOption( tOptions* pOpts, tOptState* pOptState ) -{ - /* - * Save a copy of the option procedure pointer. - * If this is an equivalence class option, we still want this proc. - */ - tOptDesc* pOD = pOptState->pOD; - tOptProc* pOP = pOD->pOptProc; - if (pOD->fOptState & OPTST_ALLOC_ARG) - AGFREE(pOD->optArg.argString); - - pOD->optArg.argString = pOptState->pzOptArg; - - /* - * IF we are presetting options, then we will ignore any un-presettable - * options. They are the ones either marked as such. - */ - if ( ((pOpts->fOptSet & OPTPROC_PRESETTING) != 0) - && ((pOD->fOptState & OPTST_NO_INIT) != 0) - ) - return PROBLEM; - - /* - * IF this is an equivalence class option, - * THEN - * Save the option value that got us to this option - * entry. (It may not be pOD->optChar[0], if this is an - * equivalence entry.) - * set the pointer to the equivalence class base - */ - if (pOD->optEquivIndex != NO_EQUIVALENT) { - tOptDesc* p = pOpts->pOptDesc + pOD->optEquivIndex; - - /* - * IF the current option state has not been defined (set on the - * command line), THEN we will allow continued resetting of - * the value. Once "defined", then it must not change. - */ - if ((pOD->fOptState & OPTST_DEFINED) != 0) { - /* - * The equivalenced-to option has been found on the command - * line before. Make sure new occurrences are the same type. - * - * IF this option has been previously equivalenced and - * it was not the same equivalenced-to option, - * THEN we have a usage problem. - */ - if (p->optActualIndex != pOD->optIndex) { - fprintf( stderr, (char*)zMultiEquiv, p->pz_Name, pOD->pz_Name, - (pOpts->pOptDesc + p->optActualIndex)->pz_Name); - return FAILURE; - } - } else { - /* - * Set the equivalenced-to actual option index to no-equivalent - * so that we set all the entries below. This option may either - * never have been selected before, or else it was selected by - * some sort of "presetting" mechanism. - */ - p->optActualIndex = NO_EQUIVALENT; - } - - if (p->optActualIndex != pOD->optIndex) { - /* - * First time through, copy over the state - * and add in the equivalence flag - */ - p->optActualValue = pOD->optValue; - p->optActualIndex = pOD->optIndex; - pOptState->flags |= OPTST_EQUIVALENCE; - } - - /* - * Copy the most recent option argument. set membership state - * is kept in ``p->optCookie''. Do not overwrite. - */ - p->optArg.argString = pOD->optArg.argString; - pOD = p; - - } else { - pOD->optActualValue = pOD->optValue; - pOD->optActualIndex = pOD->optIndex; - } - - pOD->fOptState &= OPTST_PERSISTENT_MASK; - pOD->fOptState |= (pOptState->flags & ~OPTST_PERSISTENT_MASK); - - /* - * Keep track of count only for DEFINED (command line) options. - * IF we have too many, build up an error message and bail. - */ - if ( (pOD->fOptState & OPTST_DEFINED) - && (++pOD->optOccCt > pOD->optMaxCt) ) { - - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) { - char const * pzEqv = - (pOD->optEquivIndex != NO_EQUIVALENT) ? zEquiv : zNil; - - fputs( zErrOnly, stderr ); - - if (pOD->optMaxCt > 1) - fprintf(stderr, zAtMost, pOD->optMaxCt, pOD->pz_Name, pzEqv); - else - fprintf(stderr, zOnlyOne, pOD->pz_Name, pzEqv); - } - - return FAILURE; - } - - /* - * If provided a procedure to call, call it - */ - if (pOP != (tpOptProc)NULL) - (*pOP)( pOpts, pOD ); - - return SUCCESS; -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * HUNT FOR OPTIONS IN THE ARGUMENT LIST - * - * The next four procedures are "private" to nextOption(). - * nextOption() uses findOptDesc() to find the next descriptor and it, in - * turn, uses longOptionFind() and shortOptionFind() to actually do the hunt. - * - * longOptionFind - * - * Find the long option descriptor for the current option - */ -LOCAL tSuccess -longOptionFind( tOptions* pOpts, char* pzOptName, tOptState* pOptState ) -{ - ag_bool disable = AG_FALSE; - char* pzEq = strchr( pzOptName, '=' ); - tOptDesc* pOD = pOpts->pOptDesc; - int idx = 0; - int idxLim = pOpts->optCt; - int matchCt = 0; - int matchIdx = 0; - int nameLen; - - /* - * IF the value is attached to the name, - * THEN clip it off. - * Either way, figure out how long our name is - */ - if (pzEq != NULL) { - nameLen = (int)(pzEq - pzOptName); - *pzEq = NUL; - } else nameLen = strlen( pzOptName ); - - do { - if (SKIP_OPT(pOD)) - continue; - - if (strneqvcmp( pzOptName, pOD->pz_Name, nameLen ) == 0) { - /* - * IF we have a complete match - * THEN it takes priority over any already located partial - */ - if (pOD->pz_Name[ nameLen ] == NUL) { - matchCt = 1; - matchIdx = idx; - break; - } - } - - /* - * IF there is a disable name - * *AND* no argument value has been supplied - * (disabled options may have no argument) - * *AND* the option name matches the disable name - * THEN ... - */ - else if ( (pOD->pz_DisableName != NULL) - && (strneqvcmp(pzOptName, pOD->pz_DisableName, nameLen) == 0) - ) { - disable = AG_TRUE; - - /* - * IF we have a complete match - * THEN it takes priority over any already located partial - */ - if (pOD->pz_DisableName[ nameLen ] == NUL) { - matchCt = 1; - matchIdx = idx; - break; - } - } - - else - continue; - - /* - * We found a partial match, either regular or disabling. - * Remember the index for later. - */ - matchIdx = idx; - - if (++matchCt > 1) - break; - - } while (pOD++, (++idx < idxLim)); - - if (pzEq != NULL) - *(pzEq++) = '='; - - /* - * Make sure we either found an exact match or found only one partial - */ - if (matchCt == 1) { - /* - * IF we found a disablement name, - * THEN set the bit in the callers' flag word - */ - if (disable) - pOptState->flags |= OPTST_DISABLED; - - pOptState->pOD = pOpts->pOptDesc + matchIdx; - pOptState->pzOptArg = pzEq; - pOptState->optType = TOPT_LONG; - return SUCCESS; - } - - /* - * IF there is no equal sign - * *AND* we are using named arguments - * *AND* there is a default named option, - * THEN return that option. - */ - if ( (pzEq == NULL) - && NAMED_OPTS(pOpts) - && (pOpts->specOptIdx.default_opt != NO_EQUIVALENT)) { - pOptState->pOD = pOpts->pOptDesc + pOpts->specOptIdx.default_opt; - - pOptState->pzOptArg = pzOptName; - pOptState->optType = TOPT_DEFAULT; - return SUCCESS; - } - - /* - * IF we are to stop on errors (the default, actually) - * THEN call the usage procedure. - */ - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) { - fprintf( stderr, zIllOptStr, pOpts->pzProgPath, - (matchCt == 0) ? zIllegal : zAmbiguous, pzOptName ); - (*pOpts->pUsageProc)( pOpts, EXIT_FAILURE ); - } - - return FAILURE; -} - - -/* - * shortOptionFind - * - * Find the short option descriptor for the current option - */ -LOCAL tSuccess -shortOptionFind( tOptions* pOpts, uint_t optValue, tOptState* pOptState ) -{ - tOptDesc* pRes = pOpts->pOptDesc; - int ct = pOpts->optCt; - - /* - * Search the option list - */ - for (;;) { - /* - * IF the values match, - * THEN we stop here - */ - if ((! SKIP_OPT(pRes)) && (optValue == pRes->optValue)) { - pOptState->pOD = pRes; - pOptState->optType = TOPT_SHORT; - return SUCCESS; - } - - /* - * Advance to next option description - */ - pRes++; - - /* - * IF we have searched everything, ... - */ - if (--ct <= 0) - break; - } - - /* - * IF the character value is a digit - * AND there is a special number option ("-n") - * THEN the result is the "option" itself and the - * option is the specially marked "number" option. - */ - if ( isdigit( optValue ) - && (pOpts->specOptIdx.number_option != NO_EQUIVALENT) ) { - pOptState->pOD = \ - pRes = pOpts->pOptDesc + pOpts->specOptIdx.number_option; - (pOpts->pzCurOpt)--; - pOptState->optType = TOPT_SHORT; - return SUCCESS; - } - - /* - * IF we are to stop on errors (the default, actually) - * THEN call the usage procedure. - */ - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) { - fprintf( stderr, zIllOptChr, pOpts->pzProgPath, optValue ); - (*pOpts->pUsageProc)( pOpts, EXIT_FAILURE ); - } - - return FAILURE; -} - - -/* - * findOptDesc - * - * Find the option descriptor for the current option - */ -static tSuccess -findOptDesc( tOptions* pOpts, tOptState* pOptState ) -{ - /* - * IF we are continuing a short option list (e.g. -xyz...) - * THEN continue a single flag option. - * OTHERWISE see if there is room to advance and then do so. - */ - if ((pOpts->pzCurOpt != NULL) && (*pOpts->pzCurOpt != NUL)) - return shortOptionFind( pOpts, (tAoUC)*(pOpts->pzCurOpt), pOptState ); - - if (pOpts->curOptIdx >= pOpts->origArgCt) - return PROBLEM; /* NORMAL COMPLETION */ - - pOpts->pzCurOpt = pOpts->origArgVect[ pOpts->curOptIdx ]; - - /* - * IF all arguments must be named options, ... - */ - if (NAMED_OPTS(pOpts)) { - char* pz = pOpts->pzCurOpt; - pOpts->curOptIdx++; - - /* - * Skip over any flag/option markers. - * In this mode, they are not required. - */ - while (*pz == '-') pz++; - - return longOptionFind( pOpts, pz, pOptState ); - } - - /* - * Note the kind of flag/option marker - */ - if (*((pOpts->pzCurOpt)++) != '-') - return PROBLEM; /* NORMAL COMPLETION - this + rest are operands */ - - /* - * Special hack for a hyphen by itself - */ - if (*(pOpts->pzCurOpt) == NUL) - return PROBLEM; /* NORMAL COMPLETION - this + rest are operands */ - - /* - * The current argument is to be processed as an option argument - */ - pOpts->curOptIdx++; - - /* - * We have an option marker. - * Test the next character for long option indication - */ - if (pOpts->pzCurOpt[0] == '-') { - if (*++(pOpts->pzCurOpt) == NUL) - /* - * NORMAL COMPLETION - NOT this arg, but rest are operands - */ - return PROBLEM; - - /* - * We do not allow the hyphen to be used as a flag value. - * Therefore, if long options are not to be accepted, we punt. - */ - if ((pOpts->fOptSet & OPTPROC_LONGOPT) == 0) { - fprintf( stderr, zIllOptStr, pOpts->pzProgPath, - zIllegal, pOpts->pzCurOpt-2 ); - return FAILURE; - } - - return longOptionFind( pOpts, pOpts->pzCurOpt, pOptState ); - } - - /* - * If short options are not allowed, then do long - * option processing. Otherwise the character must be a - * short (i.e. single character) option. - */ - if ((pOpts->fOptSet & OPTPROC_SHORTOPT) != 0) - return shortOptionFind( pOpts, (tAoUC)*(pOpts->pzCurOpt), pOptState ); - - return longOptionFind( pOpts, pOpts->pzCurOpt, pOptState ); -} - - -/* - * nextOption - * - * Find the option descriptor and option argument (if any) for the - * next command line argument. DO NOT modify the descriptor. Put - * all the state in the state argument so that the option can be skipped - * without consequence (side effect). - */ -static tSuccess -nextOption( tOptions* pOpts, tOptState* pOptState ) -{ - tSuccess res; - enum { ARG_NONE, ARG_MAY, ARG_MUST } arg_type = ARG_NONE; - teOptArgType at; - - res = findOptDesc( pOpts, pOptState ); - if (! SUCCESSFUL( res )) - return res; - pOptState->flags |= (pOptState->pOD->fOptState & OPTST_PERSISTENT_MASK); - at = OPTST_GET_ARGTYPE(pOptState->flags); - - /* - * Figure out what to do about option arguments. An argument may be - * required, not associated with the option, or be optional. We detect the - * latter by examining for an option marker on the next possible argument. - * Disabled mode option selection also disables option arguments. - */ - if ((pOptState->flags & OPTST_DISABLED) != 0) - arg_type = ARG_NONE; - else if (at == OPARG_TYPE_NONE) - arg_type = ARG_NONE; - else if (pOptState->flags & OPTST_ARG_OPTIONAL) - arg_type = ARG_MAY; - else - arg_type = ARG_MUST; - - switch (arg_type) { - case ARG_MUST: - /* - * An option argument is required. Long options can either have - * a separate command line argument, or an argument attached by - * the '=' character. Figure out which. - */ - switch (pOptState->optType) { - case TOPT_SHORT: - /* - * See if an arg string follows the flag character - */ - if (*++(pOpts->pzCurOpt) == NUL) - pOpts->pzCurOpt = pOpts->origArgVect[ pOpts->curOptIdx++ ]; - pOptState->pzOptArg = pOpts->pzCurOpt; - break; - - case TOPT_LONG: - /* - * See if an arg string has already been assigned (glued on - * with an `=' character) - */ - if (pOptState->pzOptArg == NULL) - pOptState->pzOptArg = pOpts->origArgVect[ pOpts->curOptIdx++ ]; - break; - - default: -#ifdef DEBUG - fputs( "AutoOpts lib error: option type not selected\n", - stderr ); - exit( EXIT_FAILURE ); -#endif - - case TOPT_DEFAULT: - /* - * The option was selected by default. The current token is - * the option argument. - */ - break; - } - - /* - * Make sure we did not overflow the argument list. - */ - if (pOpts->curOptIdx > pOpts->origArgCt) { - fprintf( stderr, zMisArg, pOpts->pzProgPath, - pOptState->pOD->pz_Name ); - return FAILURE; - } - - pOpts->pzCurOpt = NULL; /* next time advance to next arg */ - break; - - case ARG_MAY: - /* - * An option argument is optional. - */ - switch (pOptState->optType) { - case TOPT_SHORT: - if (*++pOpts->pzCurOpt != NUL) - pOptState->pzOptArg = pOpts->pzCurOpt; - else { - char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - - /* - * BECAUSE it is optional, we must make sure - * we did not find another flag and that there - * is such an argument. - */ - if ((pzLA == NULL) || (*pzLA == '-')) - pOptState->pzOptArg = NULL; - else { - pOpts->curOptIdx++; /* argument found */ - pOptState->pzOptArg = pzLA; - } - } - break; - - case TOPT_LONG: - /* - * Look for an argument if we don't already have one (glued on - * with a `=' character) *AND* we are not in named argument mode - */ - if ( (pOptState->pzOptArg == NULL) - && (! NAMED_OPTS(pOpts))) { - char* pzLA = pOpts->origArgVect[ pOpts->curOptIdx ]; - - /* - * BECAUSE it is optional, we must make sure - * we did not find another flag and that there - * is such an argument. - */ - if ((pzLA == NULL) || (*pzLA == '-')) - pOptState->pzOptArg = NULL; - else { - pOpts->curOptIdx++; /* argument found */ - pOptState->pzOptArg = pzLA; - } - } - break; - - default: - case TOPT_DEFAULT: - fputs( "AutoOpts lib error: defaulted to option with optional arg\n", - stderr ); - exit( EX_SOFTWARE ); - } - - /* - * After an option with an optional argument, we will - * *always* start with the next option because if there - * were any characters following the option name/flag, - * they would be interpreted as the argument. - */ - pOpts->pzCurOpt = NULL; - break; - - default: /* CANNOT */ - /* - * No option argument. Make sure next time around we find - * the correct option flag character for short options - */ - if (pOptState->optType == TOPT_SHORT) - (pOpts->pzCurOpt)++; - - /* - * It is a long option. Make sure there was no ``=xxx'' argument - */ - else if (pOptState->pzOptArg != NULL) { - fprintf( stderr, zNoArg, pOpts->pzProgPath, - pOptState->pOD->pz_Name ); - return FAILURE; - } - - /* - * It is a long option. Advance to next command line argument. - */ - else - pOpts->pzCurOpt = NULL; - } - - return SUCCESS; -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * DO PRESETS - * - * The next several routines do the immediate action pass on the command - * line options, then the environment variables, then the config files in - * reverse order. Once done with that, the order is reversed and all - * the config files and environment variables are processed again, this - * time only processing the non-immediate action options. doPresets() - * will then return for optionProcess() to do the final pass on the command - * line arguments. - */ - -/* - * doImmediateOpts - scan the command line for immediate action options - */ -LOCAL tSuccess -doImmediateOpts( tOptions* pOpts ) -{ - pOpts->curOptIdx = 1; /* start by skipping program name */ - pOpts->pzCurOpt = NULL; - - /* - * Examine all the options from the start. We process any options that - * are marked for immediate processing. - */ - for (;;) { - tOptState optState = OPTSTATE_INITIALIZER(PRESET); - - switch (nextOption( pOpts, &optState )) { - case FAILURE: goto optionsDone; - case PROBLEM: return SUCCESS; /* no more args */ - case SUCCESS: break; - } - - /* - * IF this *is* an immediate-attribute option, then do it. - */ - if (! DO_IMMEDIATELY(optState.flags)) - continue; - - if (! SUCCESSFUL( handleOption( pOpts, &optState ))) - break; - } optionsDone:; - - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) - (*pOpts->pUsageProc)( pOpts, EXIT_FAILURE ); - return FAILURE; -} - - -LOCAL tSuccess -doRegularOpts( tOptions* pOpts ) -{ - /* - * Now, process all the options from our current position onward. - * (This allows interspersed options and arguments for the few - * non-standard programs that require it.) - */ - for (;;) { - tOptState optState = OPTSTATE_INITIALIZER(DEFINED); - - switch (nextOption( pOpts, &optState )) { - case FAILURE: goto optionsDone; - case PROBLEM: return SUCCESS; /* no more args */ - case SUCCESS: break; - } - - /* - * IF this is not being processed normally (i.e. is immediate action) - * THEN skip it (unless we are supposed to do it a second time). - */ - if (! DO_NORMALLY(optState.flags)) { - if (! DO_SECOND_TIME(optState.flags)) - continue; - optState.pOD->optOccCt--; /* don't count last time */ - } - - if (! SUCCESSFUL( handleOption( pOpts, &optState ))) - break; - } optionsDone:; - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) - (*pOpts->pUsageProc)( pOpts, EXIT_FAILURE ); - return FAILURE; -} - - -/* - * doPresets - check for preset values from a config file or the envrionment - */ -static tSuccess -doPresets( tOptions* pOpts ) -{ - tOptDesc * pOD = NULL; - - if (! SUCCESSFUL( doImmediateOpts( pOpts ))) - return FAILURE; - - /* - * IF this option set has a --save-opts option, then it also - * has a --load-opts option. See if a command line option has disabled - * option presetting. - */ - if (pOpts->specOptIdx.save_opts != 0) { - pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts + 1; - if (DISABLED_OPT(pOD)) - return SUCCESS; - } - - /* - * Until we return from this procedure, disable non-presettable opts - */ - pOpts->fOptSet |= OPTPROC_PRESETTING; - /* - * IF there are no config files, - * THEN do any environment presets and leave. - */ - if (pOpts->papzHomeList == NULL) { - doEnvPresets( pOpts, ENV_ALL ); - } - else { - doEnvPresets( pOpts, ENV_IMM ); - - /* - * Check to see if environment variables have disabled presetting. - */ - if ((pOD != NULL) && ! DISABLED_OPT(pOD)) - internalFileLoad( pOpts ); - - /* - * ${PROGRAM_LOAD_OPTS} value of "no" cannot disable other environment - * variable options. Only the loading of .rc files. - */ - doEnvPresets( pOpts, ENV_NON_IMM ); - } - pOpts->fOptSet &= ~OPTPROC_PRESETTING; - - return SUCCESS; -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * VERIFY OPTION CONSISTENCY - * - * Make sure that the argument list passes our consistency tests. - */ -static int -checkConsistency( tOptions* pOpts ) -{ - int errCt = 0; - tOptDesc* pOD = pOpts->pOptDesc; - int oCt = pOpts->presetOptCt; - - /* - * FOR each of "oCt" options, ... - */ - for (;;) { - const int* pMust = pOD->pOptMust; - const int* pCant = pOD->pOptCant; - - /* - * IF the current option was provided on the command line - * THEN ensure that any "MUST" requirements are not - * "DEFAULT" (unspecified) *AND* ensure that any - * "CANT" options have not been SET or DEFINED. - */ - if (SELECTED_OPT(pOD)) { - if (pMust != NULL) for (;;) { - tOptDesc* p = pOpts->pOptDesc + *(pMust++); - if (UNUSED_OPT(p)) { - const tOptDesc* pN = pOpts->pOptDesc + pMust[-1]; - errCt++; - fprintf( stderr, zReqFmt, pOD->pz_Name, pN->pz_Name ); - } - - if (*pMust == NO_EQUIVALENT) - break; - } - - if (pCant != NULL) for (;;) { - tOptDesc* p = pOpts->pOptDesc + *(pCant++); - if (SELECTED_OPT(p)) { - const tOptDesc* pN = pOpts->pOptDesc + pCant[-1]; - errCt++; - fprintf( stderr, zCantFmt, pOD->pz_Name, pN->pz_Name ); - } - - if (*pCant == NO_EQUIVALENT) - break; - } - } - - /* - * IF this option is not equivalenced to another, - * OR it is equivalenced to itself (is the equiv. root) - * THEN we need to make sure it occurs often enough. - */ - if ( (pOD->optEquivIndex == NO_EQUIVALENT) - || (pOD->optEquivIndex == pOD->optIndex) ) do { - /* - * IF the occurrence counts have been satisfied, - * THEN there is no problem. - */ - if (pOD->optOccCt >= pOD->optMinCt) - break; - - /* - * IF MUST_SET means SET and PRESET are okay, - * so min occurrence count doesn't count - */ - if ( (pOD->fOptState & OPTST_MUST_SET) - && (pOD->fOptState & (OPTST_PRESET | OPTST_SET)) ) - break; - - errCt++; - if (pOD->optMinCt > 1) - fprintf( stderr, zNotEnough, pOD->pz_Name, pOD->optMinCt ); - else fprintf( stderr, zNeedOne, pOD->pz_Name ); - } while (0); - - if (--oCt <= 0) - break; - pOD++; - } - - /* - * IF we are stopping on errors, check to see if any remaining - * arguments are required to be there or prohibited from being there. - */ - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) { - - /* - * Check for prohibition - */ - if ((pOpts->fOptSet & OPTPROC_NO_ARGS) != 0) { - if (pOpts->origArgCt > pOpts->curOptIdx) { - fprintf( stderr, zNoArgs, pOpts->pzProgName ); - ++errCt; - } - } - - /* - * ELSE not prohibited, check for being required - */ - else if ((pOpts->fOptSet & OPTPROC_ARGS_REQ) != 0) { - if (pOpts->origArgCt <= pOpts->curOptIdx) { - fprintf( stderr, zArgsMust, pOpts->pzProgName ); - ++errCt; - } - } - } - - return errCt; -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * THESE ROUTINES ARE CALLABLE FROM THE GENERATED OPTION PROCESSING CODE - */ -/*=--subblock=arg=arg_type,arg_name,arg_desc =*/ -/*=* - * library: opts - * header: your-opts.h - * - * lib_description: - * - * These are the routines that libopts users may call directly from their - * code. There are several other routines that can be called by code - * generated by the libopts option templates, but they are not to be - * called from any other user code. The @file{options.h} header is - * fairly clear about this, too. -=*/ - -/*=export_func optionProcess - * - * what: this is the main option processing routine - * - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + int + argc + program arg count + - * arg: + char** + argv + program arg vector + - * - * ret_type: int - * ret_desc: the count of the arguments processed - * - * doc: - * - * This is the main entry point for processing options. It is intended - * that this procedure be called once at the beginning of the execution of - * a program. Depending on options selected earlier, it is sometimes - * necessary to stop and restart option processing, or to select completely - * different sets of options. This can be done easily, but you generally - * do not want to do this. - * - * The number of arguments processed always includes the program name. - * If one of the arguments is "--", then it is counted and the processing - * stops. If an error was encountered and errors are to be tolerated, then - * the returned value is the index of the argument causing the error. - * A hyphen by itself ("-") will also cause processing to stop and will - * @emph{not} be counted among the processed arguments. A hyphen by itself - * is treated as an operand. Encountering an operand stops option - * processing. - * - * err: Errors will cause diagnostics to be printed. @code{exit(3)} may - * or may not be called. It depends upon whether or not the options - * were generated with the "allow-errors" attribute, or if the - * ERRSKIP_OPTERR or ERRSTOP_OPTERR macros were invoked. -=*/ -int -optionProcess( - tOptions* pOpts, - int argCt, - char** argVect ) -{ - if (! SUCCESSFUL( validateOptionsStruct( pOpts, argVect[0] ))) - exit( EX_SOFTWARE ); - - /* - * Establish the real program name, the program full path, - * and do all the presetting the first time thru only. - */ - if ((pOpts->fOptSet & OPTPROC_INITDONE) == 0) { - pOpts->origArgCt = argCt; - pOpts->origArgVect = argVect; - pOpts->fOptSet |= OPTPROC_INITDONE; - - if (! SUCCESSFUL( doPresets( pOpts ))) - return 0; - - if ((pOpts->fOptSet & OPTPROC_REORDER) != 0) - optionSort( pOpts ); - - pOpts->curOptIdx = 1; - pOpts->pzCurOpt = NULL; - } - - /* - * IF we are (re)starting, - * THEN reset option location - */ - else if (pOpts->curOptIdx <= 0) { - pOpts->curOptIdx = 1; - pOpts->pzCurOpt = NULL; - } - - if (! SUCCESSFUL( doRegularOpts( pOpts ))) - return pOpts->origArgCt; - - /* - * IF there were no errors - * AND we have RC/INI files - * AND there is a request to save the files - * THEN do that now before testing for conflicts. - * (conflicts are ignored in preset options) - */ - if (pOpts->specOptIdx.save_opts != 0) { - tOptDesc* pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts; - - if (SELECTED_OPT( pOD )) { - optionSaveFile( pOpts ); - exit( EXIT_SUCCESS ); - } - } - - /* - * IF we are checking for errors, - * THEN look for too few occurrences of required options - */ - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) != 0) { - if (checkConsistency( pOpts ) != 0) - (*pOpts->pUsageProc)( pOpts, EXIT_FAILURE ); - } - - return pOpts->curOptIdx; -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/autoopts.c */ diff --git a/contrib/ntp/libopts/autoopts.h b/contrib/ntp/libopts/autoopts.h deleted file mode 100644 index 2645757ea..000000000 --- a/contrib/ntp/libopts/autoopts.h +++ /dev/null @@ -1,387 +0,0 @@ - -/* - * Time-stamp: "2007-04-15 09:59:39 bkorb" - * - * autoopts.h $Id: autoopts.h,v 4.23 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2005-02-14 05:59:50 bkorb" - * - * This file defines all the global structures and special values - * used in the automated option processing library. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -#ifndef AUTOGEN_AUTOOPTS_H -#define AUTOGEN_AUTOOPTS_H - -#include "compat/compat.h" - -#define AO_NAME_LIMIT 127 -#define AO_NAME_SIZE ((size_t)(AO_NAME_LIMIT + 1)) - -#ifndef AG_PATH_MAX -# ifdef PATH_MAX -# define AG_PATH_MAX ((size_t)PATH_MAX) -# else -# define AG_PATH_MAX ((size_t)4096) -# endif -#else -# if defined(PATH_MAX) && (PATH_MAX > MAXPATHLEN) -# undef AG_PATH_MAX -# define AG_PATH_MAX ((size_t)PATH_MAX) -# endif -#endif - -#undef EXPORT -#define EXPORT - -#if defined(_WIN32) && !defined(__CYGWIN__) -# define DIRCH '\\' -#else -# define DIRCH '/' -#endif - -#ifndef EX_NOINPUT -# define EX_NOINPUT 66 -#endif -#ifndef EX_SOFTWARE -# define EX_SOFTWARE 70 -#endif -#ifndef EX_CONFIG -# define EX_CONFIG 78 -#endif - -/* - * Convert the number to a list usable in a printf call - */ -#define NUM_TO_VER(n) ((n) >> 12), ((n) >> 7) & 0x001F, (n) & 0x007F - -#define NAMED_OPTS(po) \ - (((po)->fOptSet & (OPTPROC_SHORTOPT | OPTPROC_LONGOPT)) == 0) - -#define SKIP_OPT(p) (((p)->fOptState & (OPTST_DOCUMENT|OPTST_OMITTED)) != 0) - -typedef int tDirection; -#define DIRECTION_PRESET -1 -#define DIRECTION_PROCESS 1 -#define DIRECTION_CALLED 0 - -#define PROCESSING(d) ((d)>0) -#define PRESETTING(d) ((d)<0) - -#define ISNAMECHAR( c ) (isalnum(c) || ((c) == '_') || ((c) == '-')) - -/* - * Procedure success codes - * - * USAGE: define procedures to return "tSuccess". Test their results - * with the SUCCEEDED, FAILED and HADGLITCH macros. - * - * Microsoft sticks its nose into user space here, so for Windows' sake, - * make sure all of these are undefined. - */ -#undef SUCCESS -#undef FAILURE -#undef PROBLEM -#undef SUCCEEDED -#undef SUCCESSFUL -#undef FAILED -#undef HADGLITCH - -#define SUCCESS ((tSuccess) 0) -#define FAILURE ((tSuccess)-1) -#define PROBLEM ((tSuccess) 1) - -typedef int tSuccess; - -#define SUCCEEDED( p ) ((p) == SUCCESS) -#define SUCCESSFUL( p ) SUCCEEDED( p ) -#define FAILED( p ) ((p) < SUCCESS) -#define HADGLITCH( p ) ((p) > SUCCESS) - -/* - * When loading a line (or block) of text as an option, the value can - * be processed in any of several modes: - * - * @table @samp - * @item keep - * Every part of the value between the delimiters is saved. - * - * @item uncooked - * Even if the value begins with quote characters, do not do quote processing. - * - * @item cooked - * If the value looks like a quoted string, then process it. - * Double quoted strings are processed the way strings are in "C" programs, - * except they are treated as regular characters if the following character - * is not a well-established escape sequence. - * Single quoted strings (quoted with apostrophies) are handled the way - * strings are handled in shell scripts, *except* that backslash escapes - * are honored before backslash escapes and apostrophies. - * @end table - */ -typedef enum { - OPTION_LOAD_COOKED, - OPTION_LOAD_UNCOOKED, - OPTION_LOAD_KEEP -} tOptionLoadMode; - -extern tOptionLoadMode option_load_mode; - -/* - * The pager state is used by optionPagedUsage() procedure. - * When it runs, it sets itself up to be called again on exit. - * If, however, a routine needs a child process to do some work - * before it is done, then 'pagerState' must be set to - * 'PAGER_STATE_CHILD' so that optionPagedUsage() will not try - * to run the pager program before its time. - */ -typedef enum { - PAGER_STATE_INITIAL, - PAGER_STATE_READY, - PAGER_STATE_CHILD -} tePagerState; - -extern tePagerState pagerState; - -typedef enum { - ENV_ALL, - ENV_IMM, - ENV_NON_IMM -} teEnvPresetType; - -typedef enum { - TOPT_UNDEFINED = 0, - TOPT_SHORT, - TOPT_LONG, - TOPT_DEFAULT -} teOptType; - -typedef struct { - tOptDesc* pOD; - tCC* pzOptArg; - tAoUL flags; - teOptType optType; -} tOptState; -#define OPTSTATE_INITIALIZER(st) \ - { NULL, NULL, OPTST_ ## st, TOPT_UNDEFINED } - -#define TEXTTO_TABLE \ - _TT_( LONGUSAGE ) \ - _TT_( USAGE ) \ - _TT_( VERSION ) -#define _TT_(n) \ - TT_ ## n , - -typedef enum { TEXTTO_TABLE COUNT_TT } teTextTo; - -#undef _TT_ - -typedef struct { - tCC* pzStr; - tCC* pzReq; - tCC* pzNum; - tCC* pzKey; - tCC* pzKeyL; - tCC* pzBool; - tCC* pzNest; - tCC* pzOpt; - tCC* pzNo; - tCC* pzBrk; - tCC* pzNoF; - tCC* pzSpc; - tCC* pzOptFmt; -} arg_types_t; - -#define AGALOC( c, w ) ao_malloc((size_t)c) -#define AGREALOC( p, c, w ) ao_realloc((void*)p, (size_t)c) -#define AGFREE( p ) ao_free((void*)p) -#define AGDUPSTR( p, s, w ) (p = ao_strdup(s)) - -static void * -ao_malloc( size_t sz ); - -static void * -ao_realloc( void *p, size_t sz ); - -static void -ao_free( void *p ); - -static char * -ao_strdup( char const *str ); - -#define TAGMEM( m, t ) - -/* - * DO option handling? - * - * Options are examined at two times: at immediate handling time and at - * normal handling time. If an option is disabled, the timing may be - * different from the handling of the undisabled option. The OPTST_DIABLED - * bit indicates the state of the currently discovered option. - * So, here's how it works: - * - * A) handling at "immediate" time, either 1 or 2: - * - * 1. OPTST_DISABLED is not set: - * IMM must be set - * DISABLE_IMM don't care - * TWICE don't care - * DISABLE_TWICE don't care - * 0 -and- 1 x x x - * - * 2. OPTST_DISABLED is set: - * IMM don't care - * DISABLE_IMM must be set - * TWICE don't care - * DISABLE_TWICE don't care - * 1 -and- x 1 x x - */ -#define DO_IMMEDIATELY(_flg) \ - ( (((_flg) & (OPTST_DISABLED|OPTST_IMM)) == OPTST_IMM) \ - || ( ((_flg) & (OPTST_DISABLED|OPTST_DISABLE_IMM)) \ - == (OPTST_DISABLED|OPTST_DISABLE_IMM) )) - -/* B) handling at "regular" time because it was not immediate - * - * 1. OPTST_DISABLED is not set: - * IMM must *NOT* be set - * DISABLE_IMM don't care - * TWICE don't care - * DISABLE_TWICE don't care - * 0 -and- 0 x x x - * - * 2. OPTST_DISABLED is set: - * IMM don't care - * DISABLE_IMM don't care - * TWICE must be set - * DISABLE_TWICE don't care - * 1 -and- x x 1 x - */ -#define DO_NORMALLY(_flg) ( \ - (((_flg) & (OPTST_DISABLED|OPTST_IMM)) == 0) \ - || (((_flg) & (OPTST_DISABLED|OPTST_DISABLE_IMM)) == \ - OPTST_DISABLED) ) - -/* C) handling at "regular" time because it is to be handled twice. - * The immediate bit was already tested and found to be set: - * - * 3. OPTST_DISABLED is not set: - * IMM is set (but don't care) - * DISABLE_IMM don't care - * TWICE must be set - * DISABLE_TWICE don't care - * 0 -and- ? x 1 x - * - * 4. OPTST_DISABLED is set: - * IMM don't care - * DISABLE_IMM is set (but don't care) - * TWICE don't care - * DISABLE_TWICE must be set - * 1 -and- x ? x 1 - */ -#define DO_SECOND_TIME(_flg) ( \ - (((_flg) & (OPTST_DISABLED|OPTST_TWICE)) == \ - OPTST_TWICE) \ - || (((_flg) & (OPTST_DISABLED|OPTST_DISABLE_TWICE)) == \ - (OPTST_DISABLED|OPTST_DISABLE_TWICE) )) - -/* - * text_mmap structure. Only active on platforms with mmap(2). - */ -#ifdef HAVE_SYS_MMAN_H -# include -#else -# ifndef PROT_READ -# define PROT_READ 0x01 -# endif -# ifndef PROT_WRITE -# define PROT_WRITE 0x02 -# endif -# ifndef MAP_SHARED -# define MAP_SHARED 0x01 -# endif -# ifndef MAP_PRIVATE -# define MAP_PRIVATE 0x02 -# endif -#endif - -#ifndef MAP_FAILED -# define MAP_FAILED ((void*)-1) -#endif - -#ifndef _SC_PAGESIZE -# ifdef _SC_PAGE_SIZE -# define _SC_PAGESIZE _SC_PAGE_SIZE -# endif -#endif - -#ifndef HAVE_STRCHR -extern char* strchr( char const *s, int c); -extern char* strrchr( char const *s, int c); -#endif - -/* - * Define and initialize all the user visible strings. - * We do not do translations. If translations are to be done, then - * the client will provide a callback for that purpose. - */ -#undef DO_TRANSLATIONS -#include "autoopts/usage-txt.h" - -/* - * File pointer for usage output - */ -extern FILE* option_usage_fp; - -extern tOptProc optionPrintVersion, optionPagedUsage, optionLoadOpt; - -#endif /* AUTOGEN_AUTOOPTS_H */ -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/autoopts.h */ diff --git a/contrib/ntp/libopts/autoopts/options.h b/contrib/ntp/libopts/autoopts/options.h deleted file mode 100644 index c2ceeb3db..000000000 --- a/contrib/ntp/libopts/autoopts/options.h +++ /dev/null @@ -1,977 +0,0 @@ -/* -*- buffer-read-only: t -*- vi: set ro: - * - * DO NOT EDIT THIS FILE (options.h) - * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:34 PM PDT - * From the definitions funcs.def - * and the template file options_h - * - * This file defines all the global structures and special values - * used in the automated option processing library. - * - * Automated Options copyright 1992-Y Bruce Korb - * - * AutoOpts is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * AutoOpts is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with AutoOpts. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. - */ -#ifndef AUTOOPTS_OPTIONS_H_GUARD -#define AUTOOPTS_OPTIONS_H_GUARD -#include - -#if defined(HAVE_STDINT_H) -# include -#elif defined(HAVE_INTTYPES_H) -# include -#endif /* HAVE_STDINT/INTTYPES_H */ - -#if defined(HAVE_LIMITS_H) -# include -#elif defined(HAVE_SYS_LIMITS_H) -# include -#endif /* HAVE_LIMITS/SYS_LIMITS_H */ - -#if defined(HAVE_SYSEXITS_H) -# include -#endif /* HAVE_SYSEXITS_H */ - -#ifndef EX_USAGE -# define EX_USAGE 64 -#endif - -/* - * PUBLIC DEFINES - * - * The following defines may be used in applications that need to test the - * state of an option. To test against these masks and values, a pointer - * to an option descriptor must be obtained. There are two ways: - * - * 1. inside an option processing procedure, it is the second argument, - * conventionally "tOptDesc* pOD". - * - * 2. Outside of an option procedure (or to reference a different option - * descriptor), use either "&DESC( opt_name )" or "&pfx_DESC( opt_name )". - * - * See the relevant generated header file to determine which and what - * values for "opt_name" are available. - */ - -#define OPTIONS_STRUCT_VERSION 118784 -#define OPTIONS_VERSION_STRING "29:0:4" -#define OPTIONS_MINIMUM_VERSION 102400 -#define OPTIONS_MIN_VER_STRING "25:0:0" - -typedef enum { - OPARG_TYPE_NONE = 0, - OPARG_TYPE_STRING = 1, /* default type/ vanilla string */ - OPARG_TYPE_ENUMERATION = 2, /* opt arg is an enum (keyword list) */ - OPARG_TYPE_BOOLEAN = 3, /* opt arg is boolean-valued */ - OPARG_TYPE_MEMBERSHIP = 4, /* opt arg sets set membership bits */ - OPARG_TYPE_NUMERIC = 5, /* opt arg has numeric value */ - OPARG_TYPE_HIERARCHY = 6 /* option arg is hierarchical value */ -} teOptArgType; - -typedef struct optionValue { - teOptArgType valType; - char* pzName; - union { - char strVal[1]; /* OPARG_TYPE_STRING */ - unsigned int enumVal; /* OPARG_TYPE_ENUMERATION */ - unsigned int boolVal; /* OPARG_TYPE_BOOLEAN */ - unsigned long setVal; /* OPARG_TYPE_MEMBERSHIP */ - long longVal; /* OPARG_TYPE_NUMERIC */ - void* nestVal; /* OPARG_TYPE_HIERARCHY */ - } v; -} tOptionValue; - -/* - * Bits in the fOptState option descriptor field. - */ -typedef enum { - OPTST_SET_ID = 0, /* Set via the "SET_OPT()" macro */ - OPTST_PRESET_ID = 1, /* Set via an RC/INI file */ - OPTST_DEFINED_ID = 2, /* Set via a command line option */ - OPTST_EQUIVALENCE_ID = 4, /* selected by equiv'ed option */ - OPTST_DISABLED_ID = 5, /* option is in disabled state */ - OPTST_ALLOC_ARG_ID = 6, /* pzOptArg was allocated */ - OPTST_NO_INIT_ID = 8, /* option cannot be preset */ - OPTST_NUMBER_OPT_ID = 9, /* opt value (flag) is any digit */ - OPTST_STACKED_ID = 10, /* opt uses optionStackArg proc */ - OPTST_INITENABLED_ID = 11, /* option defaults to enabled */ - OPTST_ARG_TYPE_1_ID = 12, /* bit 1 of arg type enum */ - OPTST_ARG_TYPE_2_ID = 13, /* bit 2 of arg type enum */ - OPTST_ARG_TYPE_3_ID = 14, /* bit 3 of arg type enum */ - OPTST_ARG_TYPE_4_ID = 15, /* bit 4 of arg type enum */ - OPTST_ARG_OPTIONAL_ID = 16, /* the option arg not required */ - OPTST_IMM_ID = 17, /* process opt on first pass */ - OPTST_DISABLE_IMM_ID = 18, /* process disablement immed. */ - OPTST_OMITTED_ID = 19, /* compiled out of program */ - OPTST_MUST_SET_ID = 20, /* must be set or pre-set */ - OPTST_DOCUMENT_ID = 21, /* opt is for doc only */ - OPTST_TWICE_ID = 22, /* process opt twice - imm + reg */ - OPTST_DISABLE_TWICE_ID = 23 /* process disabled option twice */ -} opt_state_enum_t; - -#define OPTST_INIT 0U -#define OPTST_SET (1U << OPTST_SET_ID) -#define OPTST_PRESET (1U << OPTST_PRESET_ID) -#define OPTST_DEFINED (1U << OPTST_DEFINED_ID) -#define OPTST_EQUIVALENCE (1U << OPTST_EQUIVALENCE_ID) -#define OPTST_DISABLED (1U << OPTST_DISABLED_ID) -#define OPTST_ALLOC_ARG (1U << OPTST_ALLOC_ARG_ID) -#define OPTST_NO_INIT (1U << OPTST_NO_INIT_ID) -#define OPTST_NUMBER_OPT (1U << OPTST_NUMBER_OPT_ID) -#define OPTST_STACKED (1U << OPTST_STACKED_ID) -#define OPTST_INITENABLED (1U << OPTST_INITENABLED_ID) -#define OPTST_ARG_TYPE_1 (1U << OPTST_ARG_TYPE_1_ID) -#define OPTST_ARG_TYPE_2 (1U << OPTST_ARG_TYPE_2_ID) -#define OPTST_ARG_TYPE_3 (1U << OPTST_ARG_TYPE_3_ID) -#define OPTST_ARG_TYPE_4 (1U << OPTST_ARG_TYPE_4_ID) -#define OPTST_ARG_OPTIONAL (1U << OPTST_ARG_OPTIONAL_ID) -#define OPTST_IMM (1U << OPTST_IMM_ID) -#define OPTST_DISABLE_IMM (1U << OPTST_DISABLE_IMM_ID) -#define OPTST_OMITTED (1U << OPTST_OMITTED_ID) -#define OPTST_MUST_SET (1U << OPTST_MUST_SET_ID) -#define OPTST_DOCUMENT (1U << OPTST_DOCUMENT_ID) -#define OPTST_TWICE (1U << OPTST_TWICE_ID) -#define OPTST_DISABLE_TWICE (1U << OPTST_DISABLE_TWICE_ID) -#define OPT_STATE_MASK 0x00FFFF77U - -#define OPTST_SET_MASK ( \ - OPTST_SET | \ - OPTST_PRESET | \ - OPTST_DEFINED ) - -#define OPTST_MUTABLE_MASK ( \ - OPTST_SET | \ - OPTST_PRESET | \ - OPTST_DEFINED | \ - OPTST_EQUIVALENCE | \ - OPTST_DISABLED | \ - OPTST_ALLOC_ARG ) - -#define OPTST_SELECTED_MASK ( \ - OPTST_SET | \ - OPTST_DEFINED ) - -#define OPTST_ARG_TYPE_MASK ( \ - OPTST_ARG_TYPE_1 | \ - OPTST_ARG_TYPE_2 | \ - OPTST_ARG_TYPE_3 | \ - OPTST_ARG_TYPE_4 ) - -#ifdef NO_OPTIONAL_OPT_ARGS -# undef OPTST_ARG_OPTIONAL -# define OPTST_ARG_OPTIONAL 0 -#endif - -#define OPTST_PERSISTENT_MASK (~OPTST_MUTABLE_MASK) - -#define SELECTED_OPT( pod ) ((pod)->fOptState & OPTST_SELECTED_MASK) -#define UNUSED_OPT( pod ) (((pod)->fOptState & OPTST_SET_MASK) == 0) -#define DISABLED_OPT( pod ) ((pod)->fOptState & OPTST_DISABLED) -#define OPTION_STATE( pod ) ((pod)->fOptState) - -#define OPTST_SET_ARGTYPE(n) ((n) << OPTST_ARG_TYPE_1_ID) -#define OPTST_GET_ARGTYPE(f) (((f) & OPTST_ARG_TYPE_MASK)>>OPTST_ARG_TYPE_1_ID) - -/* - * PRIVATE INTERFACES - * - * The following values are used in the generated code to communicate - * with the option library procedures. They are not for public use - * and may be subject to change. - */ - -/* - * Define the processing state flags - */ -typedef enum { - OPTPROC_LONGOPT_ID = 0, /* Process long style options */ - OPTPROC_SHORTOPT_ID = 1, /* Process short style "flags" */ - OPTPROC_ERRSTOP_ID = 2, /* Stop on argument errors */ - OPTPROC_DISABLEDOPT_ID = 3, /* Current option is disabled */ - OPTPROC_NO_REQ_OPT_ID = 4, /* no options are required */ - OPTPROC_NUM_OPT_ID = 5, /* there is a number option */ - OPTPROC_INITDONE_ID = 6, /* have initializations been done? */ - OPTPROC_NEGATIONS_ID = 7, /* any negation options? */ - OPTPROC_ENVIRON_ID = 8, /* check environment? */ - OPTPROC_NO_ARGS_ID = 9, /* Disallow remaining arguments */ - OPTPROC_ARGS_REQ_ID = 10, /* Require arguments after options */ - OPTPROC_REORDER_ID = 11, /* reorder operands after options */ - OPTPROC_GNUUSAGE_ID = 12, /* emit usage in GNU style */ - OPTPROC_TRANSLATE_ID = 13, /* Translate strings in tOptions */ - OPTPROC_HAS_IMMED_ID = 14, /* program defines immed options */ - OPTPROC_PRESETTING_ID = 19 /* opt processing in preset state */ -} optproc_state_enum_t; - -#define OPTPROC_NONE 0U -#define OPTPROC_LONGOPT (1U << OPTPROC_LONGOPT_ID) -#define OPTPROC_SHORTOPT (1U << OPTPROC_SHORTOPT_ID) -#define OPTPROC_ERRSTOP (1U << OPTPROC_ERRSTOP_ID) -#define OPTPROC_DISABLEDOPT (1U << OPTPROC_DISABLEDOPT_ID) -#define OPTPROC_NO_REQ_OPT (1U << OPTPROC_NO_REQ_OPT_ID) -#define OPTPROC_NUM_OPT (1U << OPTPROC_NUM_OPT_ID) -#define OPTPROC_INITDONE (1U << OPTPROC_INITDONE_ID) -#define OPTPROC_NEGATIONS (1U << OPTPROC_NEGATIONS_ID) -#define OPTPROC_ENVIRON (1U << OPTPROC_ENVIRON_ID) -#define OPTPROC_NO_ARGS (1U << OPTPROC_NO_ARGS_ID) -#define OPTPROC_ARGS_REQ (1U << OPTPROC_ARGS_REQ_ID) -#define OPTPROC_REORDER (1U << OPTPROC_REORDER_ID) -#define OPTPROC_GNUUSAGE (1U << OPTPROC_GNUUSAGE_ID) -#define OPTPROC_TRANSLATE (1U << OPTPROC_TRANSLATE_ID) -#define OPTPROC_HAS_IMMED (1U << OPTPROC_HAS_IMMED_ID) -#define OPTPROC_PRESETTING (1U << OPTPROC_PRESETTING_ID) -#define OPTPROC_STATE_MASK 0x00087FFFU - -#define STMTS(s) do { s; } while (0) - -/* - * The following must be #defined instead of typedef-ed - * because "static const" cannot both be applied to a type, - * tho each individually can...so they all are - */ -#define tSCC static char const -#define tCC char const -#define tAoSC static char -#define tAoUC unsigned char -#define tAoUI unsigned int -#define tAoUL unsigned long -#define tAoUS unsigned short - -/* - * It is so disgusting that there must be so many ways - * of specifying TRUE and FALSE. - */ -typedef enum { AG_FALSE = 0, AG_TRUE } ag_bool; - -/* - * Define a structure that describes each option and - * a pointer to the procedure that handles it. - * The argument is the count of this flag previously seen. - */ -typedef struct options tOptions; -typedef struct optDesc tOptDesc; -typedef struct optNames tOptNames; - -/* - * The option procedures do the special processing for each - * option flag that needs it. - */ -typedef void (tOptProc)( tOptions* pOpts, tOptDesc* pOptDesc ); -typedef tOptProc* tpOptProc; - -/* - * The usage procedure will never return. It calls "exit(2)" - * with the "exitCode" argument passed to it. - */ -typedef void (tUsageProc)( tOptions* pOpts, int exitCode ); -typedef tUsageProc* tpUsageProc; - -/* - * Special definitions. "NOLIMIT" is the 'max' value to use when - * a flag may appear multiple times without limit. "NO_EQUIVALENT" - * is an illegal value for 'optIndex' (option description index). - */ -#define NOLIMIT USHRT_MAX -#define OPTION_LIMIT SHRT_MAX -#define NO_EQUIVALENT (OPTION_LIMIT+1) - -/* - * Special values for optValue. It must not be generatable from the - * computation "optIndex +96". Since "optIndex" is limited to 100, ... - */ -#define NUMBER_OPTION '#' - -typedef struct argList tArgList; -#define MIN_ARG_ALLOC_CT 6 -#define INCR_ARG_ALLOC_CT 8 -struct argList { - int useCt; - int allocCt; - tCC* apzArgs[ MIN_ARG_ALLOC_CT ]; -}; - -typedef union { - char const * argString; - uintptr_t argEnum; - uintptr_t argIntptr; - long argInt; - unsigned long argUint; - unsigned int argBool; -} optArgBucket_t; - -/* - * Descriptor structure for each option. - * Only the fields marked "PUBLIC" are for public use. - */ -struct optDesc { - tAoUS const optIndex; /* PUBLIC */ - tAoUS const optValue; /* PUBLIC */ - tAoUS optActualIndex; /* PUBLIC */ - tAoUS optActualValue; /* PUBLIC */ - - tAoUS const optEquivIndex; /* PUBLIC */ - tAoUS const optMinCt; - tAoUS const optMaxCt; - tAoUS optOccCt; /* PUBLIC */ - - tAoUI fOptState; /* PUBLIC */ - tAoUI reserved; - optArgBucket_t optArg; /* PUBLIC */ -# define pzLastArg optArg.argString - void* optCookie; /* PUBLIC */ - - const int * pOptMust; - const int * pOptCant; - tpOptProc pOptProc; - char const* pzText; - - char const* pz_NAME; - char const* pz_Name; - char const* pz_DisableName; - char const* pz_DisablePfx; -}; - -/* - * Some options need special processing, so we store their - * indexes in a known place: - */ -typedef struct optSpecIndex tOptSpecIndex; -struct optSpecIndex { - const tAoUS more_help; - const tAoUS save_opts; - const tAoUS number_option; - const tAoUS default_opt; -}; - -/* - * The procedure generated for translating option text - */ -typedef void (tOptionXlateProc)(void); - -struct options { - int const structVersion; - int origArgCt; - char** origArgVect; - unsigned int fOptSet; - unsigned int curOptIdx; - char* pzCurOpt; - - char const* pzProgPath; - char const* pzProgName; - char const* const pzPROGNAME; - char const* const pzRcName; - char const* const pzCopyright; - char const* const pzCopyNotice; - char const* const pzFullVersion; - char const* const* const papzHomeList; - char const* const pzUsageTitle; - char const* const pzExplain; - char const* const pzDetail; - tOptDesc* const pOptDesc; - char const* const pzBugAddr; - - void* pExtensions; - void* pSavedState; - - tpUsageProc pUsageProc; - tOptionXlateProc* pTransProc; - - tOptSpecIndex specOptIdx; - int const optCt; - int const presetOptCt; -}; - -/* - * "token list" structure returned by "string_tokenize()" - */ -typedef struct { - unsigned long tkn_ct; - unsigned char* tkn_list[1]; -} token_list_t; - -/* - * Hide the interface - it pollutes a POSIX claim, but leave it for - * anyone #include-ing this header - */ -#define strneqvcmp option_strneqvcmp -#define streqvcmp option_streqvcmp -#define streqvmap option_streqvmap -#define strequate option_strequate -#define strtransform option_strtransform - -/* - * This is an output only structure used by text_mmap and text_munmap. - * Clients must not alter the contents and must provide it to both - * the text_mmap and text_munmap procedures. BE ADVISED: if you are - * mapping the file with PROT_WRITE the NUL byte at the end MIGHT NOT - * BE WRITABLE. In any event, that byte is not be written back - * to the source file. ALSO: if "txt_data" is valid and "txt_errno" - * is not zero, then there *may* not be a terminating NUL. - */ -typedef struct { - void* txt_data; /* text file data */ - size_t txt_size; /* actual file size */ - size_t txt_full_size; /* mmaped mem size */ - int txt_fd; /* file descriptor */ - int txt_zero_fd; /* fd for /dev/zero */ - int txt_errno; /* warning code */ - int txt_prot; /* "prot" flags */ - int txt_flags; /* mapping type */ - int txt_alloc; /* if we malloced memory */ -} tmap_info_t; - -#define TEXT_MMAP_FAILED_ADDR(a) ((void*)(a) == (void*)MAP_FAILED) - -#ifdef __cplusplus -extern "C" { -#define CPLUSPLUS_CLOSER } -#else -#define CPLUSPLUS_CLOSER -#endif - -/* - * The following routines may be coded into AutoOpts client code: - */ - -/* From: tokenize.c line 115 - * - * ao_string_tokenize - tokenize an input string - * - * Arguments: - * string string to be tokenized - * - * Returns: token_list_t* - pointer to a structure that lists each token - * - * This function will convert one input string into a list of strings. - * The list of strings is derived by separating the input based on - * white space separation. However, if the input contains either single - * or double quote characters, then the text after that character up to - * a matching quote will become the string in the list. - * - * The returned pointer should be deallocated with @code{free(3C)} when - * are done using the data. The data are placed in a single block of - * allocated memory. Do not deallocate individual token/strings. - * - * The structure pointed to will contain at least these two fields: - * @table @samp - * @item tkn_ct - * The number of tokens found in the input string. - * @item tok_list - * An array of @code{tkn_ct + 1} pointers to substring tokens, with - * the last pointer set to NULL. - * @end table - * - * There are two types of quoted strings: single quoted (@code{'}) and - * double quoted (@code{"}). Singly quoted strings are fairly raw in that - * escape characters (@code{\\}) are simply another character, except when - * preceding the following characters: - * @example - * @code{\\} double backslashes reduce to one - * @code{'} incorporates the single quote into the string - * @code{\n} suppresses both the backslash and newline character - * @end example - * - * Double quote strings are formed according to the rules of string - * constants in ANSI-C programs. - */ -extern token_list_t* ao_string_tokenize( char const* ); - - -/* From: configfile.c line 113 - * - * configFileLoad - parse a configuration file - * - * Arguments: - * pzFile the file to load - * - * Returns: const tOptionValue* - An allocated, compound value structure - * - * This routine will load a named configuration file and parse the - * text as a hierarchically valued option. The option descriptor - * created from an option definition file is not used via this interface. - * The returned value is "named" with the input file name and is of - * type "@code{OPARG_TYPE_HIERARCHY}". It may be used in calls to - * @code{optionGetValue()}, @code{optionNextValue()} and - * @code{optionUnloadNested()}. - */ -extern const tOptionValue* configFileLoad( char const* ); - - -/* From: configfile.c line 883 - * - * optionFileLoad - Load the locatable config files, in order - * - * Arguments: - * pOpts program options descriptor - * pzProg program name - * - * Returns: int - 0 -> SUCCESS, -1 -> FAILURE - * - * This function looks in all the specified directories for a configuration - * file ("rc" file or "ini" file) and processes any found twice. The first - * time through, they are processed in reverse order (last file first). At - * that time, only "immediate action" configurables are processed. For - * example, if the last named file specifies not processing any more - * configuration files, then no more configuration files will be processed. - * Such an option in the @strong{first} named directory will have no effect. - * - * Once the immediate action configurables have been handled, then the - * directories are handled in normal, forward order. In that way, later - * config files can override the settings of earlier config files. - * - * See the AutoOpts documentation for a thorough discussion of the - * config file format. - * - * Configuration files not found or not decipherable are simply ignored. - */ -extern int optionFileLoad( tOptions*, char const* ); - - -/* From: configfile.c line 245 - * - * optionFindNextValue - find a hierarcicaly valued option instance - * - * Arguments: - * pOptDesc an option with a nested arg type - * pPrevVal the last entry - * name name of value to find - * value the matching value - * - * Returns: const tOptionValue* - a compound value structure - * - * This routine will find the next entry in a nested value option or - * configurable. It will search through the list and return the next entry - * that matches the criteria. - */ -extern const tOptionValue* optionFindNextValue( const tOptDesc*, const tOptionValue*, char const*, char const* ); - - -/* From: configfile.c line 171 - * - * optionFindValue - find a hierarcicaly valued option instance - * - * Arguments: - * pOptDesc an option with a nested arg type - * name name of value to find - * value the matching value - * - * Returns: const tOptionValue* - a compound value structure - * - * This routine will find an entry in a nested value option or configurable. - * It will search through the list and return a matching entry. - */ -extern const tOptionValue* optionFindValue( const tOptDesc*, char const*, char const* ); - - -/* From: restore.c line 188 - * - * optionFree - free allocated option processing memory - * - * Arguments: - * pOpts program options descriptor - * - * AutoOpts sometimes allocates memory and puts pointers to it in the - * option state structures. This routine deallocates all such memory. - */ -extern void optionFree( tOptions* ); - - -/* From: configfile.c line 314 - * - * optionGetValue - get a specific value from a hierarcical list - * - * Arguments: - * pOptValue a hierarchcal value - * valueName name of value to get - * - * Returns: const tOptionValue* - a compound value structure - * - * This routine will find an entry in a nested value option or configurable. - * If "valueName" is NULL, then the first entry is returned. Otherwise, - * the first entry with a name that exactly matches the argument will be - * returned. - */ -extern const tOptionValue* optionGetValue( const tOptionValue*, char const* ); - - -/* From: load.c line 521 - * - * optionLoadLine - process a string for an option name and value - * - * Arguments: - * pOpts program options descriptor - * pzLine NUL-terminated text - * - * This is a client program callable routine for setting options from, for - * example, the contents of a file that they read in. Only one option may - * appear in the text. It will be treated as a normal (non-preset) option. - * - * When passed a pointer to the option struct and a string, it will find - * the option named by the first token on the string and set the option - * argument to the remainder of the string. The caller must NUL terminate - * the string. Any embedded new lines will be included in the option - * argument. If the input looks like one or more quoted strings, then the - * input will be "cooked". The "cooking" is identical to the string - * formation used in AutoGen definition files (@pxref{basic expression}), - * except that you may not use backquotes. - */ -extern void optionLoadLine( tOptions*, char const* ); - - -/* From: configfile.c line 373 - * - * optionNextValue - get the next value from a hierarchical list - * - * Arguments: - * pOptValue a hierarchcal list value - * pOldValue a value from this list - * - * Returns: const tOptionValue* - a compound value structure - * - * This routine will return the next entry after the entry passed in. At the - * end of the list, NULL will be returned. If the entry is not found on the - * list, NULL will be returned and "@var{errno}" will be set to EINVAL. - * The "@var{pOldValue}" must have been gotten from a prior call to this - * routine or to "@code{opitonGetValue()}". - */ -extern const tOptionValue* optionNextValue( const tOptionValue*, const tOptionValue* ); - - -/* From: usage.c line 128 - * - * optionOnlyUsage - Print usage text for just the options - * - * Arguments: - * pOpts program options descriptor - * ex_code exit code for calling exit(3) - * - * This routine will print only the usage for each option. - * This function may be used when the emitted usage must incorporate - * information not available to AutoOpts. - */ -extern void optionOnlyUsage( tOptions*, int ); - - -/* From: autoopts.c line 1012 - * - * optionProcess - this is the main option processing routine - * - * Arguments: - * pOpts program options descriptor - * argc program arg count - * argv program arg vector - * - * Returns: int - the count of the arguments processed - * - * This is the main entry point for processing options. It is intended - * that this procedure be called once at the beginning of the execution of - * a program. Depending on options selected earlier, it is sometimes - * necessary to stop and restart option processing, or to select completely - * different sets of options. This can be done easily, but you generally - * do not want to do this. - * - * The number of arguments processed always includes the program name. - * If one of the arguments is "--", then it is counted and the processing - * stops. If an error was encountered and errors are to be tolerated, then - * the returned value is the index of the argument causing the error. - * A hyphen by itself ("-") will also cause processing to stop and will - * @emph{not} be counted among the processed arguments. A hyphen by itself - * is treated as an operand. Encountering an operand stops option - * processing. - */ -extern int optionProcess( tOptions*, int, char** ); - - -/* From: restore.c line 145 - * - * optionRestore - restore option state from memory copy - * - * Arguments: - * pOpts program options descriptor - * - * Copy back the option state from saved memory. - * The allocated memory is left intact, so this routine can be - * called repeatedly without having to call optionSaveState again. - * If you are restoring a state that was saved before the first call - * to optionProcess(3AO), then you may change the contents of the - * argc/argv parameters to optionProcess. - */ -extern void optionRestore( tOptions* ); - - -/* From: save.c line 334 - * - * optionSaveFile - saves the option state to a file - * - * Arguments: - * pOpts program options descriptor - * - * This routine will save the state of option processing to a file. The name - * of that file can be specified with the argument to the @code{--save-opts} - * option, or by appending the @code{rcfile} attribute to the last - * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it - * will default to @code{.@i{programname}rc}. If you wish to specify another - * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. - */ -extern void optionSaveFile( tOptions* ); - - -/* From: restore.c line 93 - * - * optionSaveState - saves the option state to memory - * - * Arguments: - * pOpts program options descriptor - * - * This routine will allocate enough memory to save the current option - * processing state. If this routine has been called before, that memory - * will be reused. You may only save one copy of the option state. This - * routine may be called before optionProcess(3AO). If you do call it - * before the first call to optionProcess, then you may also change the - * contents of argc/argv after you call optionRestore(3AO) - * - * In fact, more strongly put: it is safest to only use this function - * before having processed any options. In particular, the saving and - * restoring of stacked string arguments and hierarchical values is - * disabled. The values are not saved. - */ -extern void optionSaveState( tOptions* ); - - -/* From: nested.c line 559 - * - * optionUnloadNested - Deallocate the memory for a nested value - * - * Arguments: - * pOptVal the hierarchical value - * - * A nested value needs to be deallocated. The pointer passed in should - * have been gotten from a call to @code{configFileLoad()} (See - * @pxref{libopts-configFileLoad}). - */ -extern void optionUnloadNested( tOptionValue const * ); - - -/* From: version.c line 58 - * - * optionVersion - return the compiled AutoOpts version number - * - * Returns: char const* - the version string in constant memory - * - * Returns the full version string compiled into the library. - * The returned string cannot be modified. - */ -extern char const* optionVersion( void ); - - -/* From: ../compat/pathfind.c line 34 - * - * pathfind - fild a file in a list of directories - * - * Arguments: - * path colon separated list of search directories - * file the name of the file to look for - * mode the mode bits that must be set to match - * - * Returns: char* - the path to the located file - * - * the pathfind function is available only if HAVE_PATHFIND is not defined - * - * pathfind looks for a a file with name "FILE" and "MODE" access - * along colon delimited "PATH", and returns the full pathname as a - * string, or NULL if not found. If "FILE" contains a slash, then - * it is treated as a relative or absolute path and "PATH" is ignored. - * - * @strong{NOTE}: this function is compiled into @file{libopts} only if - * it is not natively supplied. - * - * The "MODE" argument is a string of option letters chosen from the - * list below: - * @example - * Letter Meaning - * r readable - * w writable - * x executable - * f normal file (NOT IMPLEMENTED) - * b block special (NOT IMPLEMENTED) - * c character special (NOT IMPLEMENTED) - * d directory (NOT IMPLEMENTED) - * p FIFO (pipe) (NOT IMPLEMENTED) - * u set user ID bit (NOT IMPLEMENTED) - * g set group ID bit (NOT IMPLEMENTED) - * k sticky bit (NOT IMPLEMENTED) - * s size nonzero (NOT IMPLEMENTED) - * @end example - */ -#ifndef HAVE_PATHFIND -extern char* pathfind( char const*, char const*, char const* ); -#endif /* HAVE_PATHFIND */ - - -/* From: streqvcmp.c line 233 - * - * strequate - map a list of characters to the same value - * - * Arguments: - * ch_list characters to equivalence - * - * Each character in the input string get mapped to the first character - * in the string. - * This function name is mapped to option_strequate so as to not conflict - * with the POSIX name space. - */ -extern void strequate( char const* ); - - -/* From: streqvcmp.c line 143 - * - * streqvcmp - compare two strings with an equivalence mapping - * - * Arguments: - * str1 first string - * str2 second string - * - * Returns: int - the difference between two differing characters - * - * Using a character mapping, two strings are compared for "equivalence". - * Each input character is mapped to a comparison character and the - * mapped-to characters are compared for the two NUL terminated input strings. - * This function name is mapped to option_streqvcmp so as to not conflict - * with the POSIX name space. - */ -extern int streqvcmp( char const*, char const* ); - - -/* From: streqvcmp.c line 180 - * - * streqvmap - Set the character mappings for the streqv functions - * - * Arguments: - * From Input character - * To Mapped-to character - * ct compare length - * - * Set the character mapping. If the count (@code{ct}) is set to zero, then - * the map is cleared by setting all entries in the map to their index - * value. Otherwise, the "@code{From}" character is mapped to the "@code{To}" - * character. If @code{ct} is greater than 1, then @code{From} and @code{To} - * are incremented and the process repeated until @code{ct} entries have been - * set. For example, - * @example - * streqvmap( 'a', 'A', 26 ); - * @end example - * @noindent - * will alter the mapping so that all English lower case letters - * will map to upper case. - * - * This function name is mapped to option_streqvmap so as to not conflict - * with the POSIX name space. - */ -extern void streqvmap( char, char, int ); - - -/* From: streqvcmp.c line 102 - * - * strneqvcmp - compare two strings with an equivalence mapping - * - * Arguments: - * str1 first string - * str2 second string - * ct compare length - * - * Returns: int - the difference between two differing characters - * - * Using a character mapping, two strings are compared for "equivalence". - * Each input character is mapped to a comparison character and the - * mapped-to characters are compared for the two NUL terminated input strings. - * The comparison is limited to @code{ct} bytes. - * This function name is mapped to option_strneqvcmp so as to not conflict - * with the POSIX name space. - */ -extern int strneqvcmp( char const*, char const*, int ); - - -/* From: streqvcmp.c line 259 - * - * strtransform - convert a string into its mapped-to value - * - * Arguments: - * dest output string - * src input string - * - * Each character in the input string is mapped and the mapped-to - * character is put into the output. - * This function name is mapped to option_strtransform so as to not conflict - * with the POSIX name space. - */ -extern void strtransform( char*, char const* ); - -/* AutoOpts PRIVATE FUNCTIONS: */ -tOptProc optionStackArg, optionUnstackArg, optionBooleanVal, optionNumericVal; - -extern char* ao_string_cook( char*, int* ); - -extern unsigned int ao_string_cook_escape_char( char const*, char*, unsigned int ); - -extern void export_options_to_guile( tOptions* ); - -extern void genshelloptUsage( tOptions*, int ); - -extern void optionBooleanVal( tOptions*, tOptDesc* ); - -extern uintptr_t optionEnumerationVal( tOptions*, tOptDesc*, char const * const *, unsigned int ); - -extern char const* optionKeywordName( tOptDesc*, unsigned int ); - -extern void optionLoadOpt( tOptions*, tOptDesc* ); - -extern ag_bool optionMakePath( char*, int, char const*, char const* ); - -extern void optionNestedVal( tOptions*, tOptDesc* ); - -extern void optionNumericVal( tOptions*, tOptDesc* ); - -extern void optionPagedUsage( tOptions*, tOptDesc* ); - -extern void optionParseShell( tOptions* ); - -extern void optionPrintVersion( tOptions*, tOptDesc* ); - -extern void optionPutShell( tOptions* ); - -extern void optionSetMembers( tOptions*, tOptDesc*, char const * const *, unsigned int ); - -extern void optionStackArg( tOptions*, tOptDesc* ); - -extern void optionUnstackArg( tOptions*, tOptDesc* ); - -extern void optionUsage( tOptions*, int ); - -extern void optionVersionStderr( tOptions*, tOptDesc* ); - -extern void* text_mmap( char const*, int, int, tmap_info_t* ); - -extern int text_munmap( tmap_info_t* ); - -CPLUSPLUS_CLOSER -#endif /* AUTOOPTS_OPTIONS_H_GUARD */ -/* - * Local Variables: - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * options.h ends here */ diff --git a/contrib/ntp/libopts/autoopts/usage-txt.h b/contrib/ntp/libopts/autoopts/usage-txt.h deleted file mode 100644 index 5aaaa01a6..000000000 --- a/contrib/ntp/libopts/autoopts/usage-txt.h +++ /dev/null @@ -1,355 +0,0 @@ -/* -*- buffer-read-only: t -*- vi: set ro: - * - * DO NOT EDIT THIS FILE (usage-txt.h) - * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:33 PM PDT - * From the definitions usage-txt.def - * and the template file usage-txt.tpl - * - * This file handles all the bookkeeping required for tracking all the little - * tiny strings used by the AutoOpts library. There are 113 - * of them. This is not versioned because it is entirely internal to the - * library and accessed by client code only in a very well-controlled way: - * they may substitute translated strings using a procedure that steps through - * all the string pointers. - * - * AutoOpts is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * AutoOpts is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with AutoOpts. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. - */ -#ifndef AUTOOPTS_USAGE_TXT_H_GUARD -#define AUTOOPTS_USAGE_TXT_H_GUARD - -#undef cch_t -#define cch_t char const - -/* - * One structure to hold all the pointers to all the stringlets. - */ -typedef struct { - int field_ct; - char* utpz_GnuBoolArg; - char* utpz_GnuKeyArg; - char* utpz_GnuKeyLArg; - char* utpz_GnuNumArg; - char* utpz_GnuStrArg; - cch_t* apz_str[ 108 ]; -} usage_text_t; - -/* - * Declare the global structure with all the pointers to translated - * strings. This is then used by the usage generation procedure. - */ -extern usage_text_t option_usage_text; - -#if defined(AUTOOPTS_INTERNAL) /* DEFINE ALL THE STRINGS = = = = = */ -/* - * Provide a mapping from a short name to fields in this structure. - */ -#define zAO_Bad (option_usage_text.apz_str[ 0]) -#define zAO_Big (option_usage_text.apz_str[ 1]) -#define zAO_Err (option_usage_text.apz_str[ 2]) -#define zAO_Sml (option_usage_text.apz_str[ 3]) -#define zAll (option_usage_text.apz_str[ 4]) -#define zAlt (option_usage_text.apz_str[ 5]) -#define zAmbigKey (option_usage_text.apz_str[ 6]) -#define zAmbiguous (option_usage_text.apz_str[ 7]) -#define zArgsMust (option_usage_text.apz_str[ 8]) -#define zAtMost (option_usage_text.apz_str[ 9]) -#define zAuto (option_usage_text.apz_str[ 10]) -#define zBadPipe (option_usage_text.apz_str[ 11]) -#define zBadVerArg (option_usage_text.apz_str[ 12]) -#define zCantFmt (option_usage_text.apz_str[ 13]) -#define zCantSave (option_usage_text.apz_str[ 14]) -#define zDefaultOpt (option_usage_text.apz_str[ 15]) -#define zDis (option_usage_text.apz_str[ 16]) -#define zEnab (option_usage_text.apz_str[ 17]) -#define zEquiv (option_usage_text.apz_str[ 18]) -#define zErrOnly (option_usage_text.apz_str[ 19]) -#define zExamineFmt (option_usage_text.apz_str[ 20]) -#define zFiveSpaces (option_usage_text.apz_str[ 21]) -#define zFlagOkay (option_usage_text.apz_str[ 22]) -#define zFmtFmt (option_usage_text.apz_str[ 23]) -#define zForkFail (option_usage_text.apz_str[ 24]) -#define zFSErrOptLoad (option_usage_text.apz_str[ 25]) -#define zFSErrReadFile (option_usage_text.apz_str[ 26]) -#define zGenshell (option_usage_text.apz_str[ 27]) -#define zGnuBoolArg (option_usage_text.utpz_GnuBoolArg) -#define zGnuBreak (option_usage_text.apz_str[ 28]) -#define zGnuKeyArg (option_usage_text.utpz_GnuKeyArg) -#define zGnuKeyLArg (option_usage_text.utpz_GnuKeyLArg) -#define zGnuNestArg (option_usage_text.apz_str[ 29]) -#define zGnuNumArg (option_usage_text.utpz_GnuNumArg) -#define zGnuOptArg (option_usage_text.apz_str[ 30]) -#define zGnuOptFmt (option_usage_text.apz_str[ 31]) -#define zGnuStrArg (option_usage_text.utpz_GnuStrArg) -#define zIllOptChr (option_usage_text.apz_str[ 32]) -#define zIllOptStr (option_usage_text.apz_str[ 33]) -#define zIllegal (option_usage_text.apz_str[ 34]) -#define zInvalOptDesc (option_usage_text.apz_str[ 35]) -#define zKeyWords (option_usage_text.apz_str[ 36]) -#define zLoadCooked (option_usage_text.apz_str[ 37]) -#define zLoadKeep (option_usage_text.apz_str[ 38]) -#define zLoadType (option_usage_text.apz_str[ 39]) -#define zLoadUncooked (option_usage_text.apz_str[ 40]) -#define zLtypeInteger (option_usage_text.apz_str[ 41]) -#define zLtypeNest (option_usage_text.apz_str[ 42]) -#define zLtypeString (option_usage_text.apz_str[ 43]) -#define zLtypeBool (option_usage_text.apz_str[ 44]) -#define zLtypeKeyword (option_usage_text.apz_str[ 45]) -#define zLtypeSetMembership (option_usage_text.apz_str[ 46]) -#define zMembers (option_usage_text.apz_str[ 47]) -#define zMisArg (option_usage_text.apz_str[ 48]) -#define zMultiEquiv (option_usage_text.apz_str[ 49]) -#define zMust (option_usage_text.apz_str[ 50]) -#define zNeedOne (option_usage_text.apz_str[ 51]) -#define zNoArg (option_usage_text.apz_str[ 52]) -#define zNoArgs (option_usage_text.apz_str[ 53]) -#define zNoCreat (option_usage_text.apz_str[ 54]) -#define zNoFlags (option_usage_text.apz_str[ 55]) -#define zNoKey (option_usage_text.apz_str[ 56]) -#define zNoLim (option_usage_text.apz_str[ 57]) -#define zNoPreset (option_usage_text.apz_str[ 58]) -#define zNoRq_NoShrtTtl (option_usage_text.apz_str[ 59]) -#define zNoRq_ShrtTtl (option_usage_text.apz_str[ 60]) -#define zNoStat (option_usage_text.apz_str[ 61]) -#define zNoState (option_usage_text.apz_str[ 62]) -#define zNone (option_usage_text.apz_str[ 63]) -#define zNotDef (option_usage_text.apz_str[ 64]) -#define zNotEnough (option_usage_text.apz_str[ 65]) -#define zNotFile (option_usage_text.apz_str[ 66]) -#define zNotNumber (option_usage_text.apz_str[ 67]) -#define zNrmOptFmt (option_usage_text.apz_str[ 68]) -#define zNumberOpt (option_usage_text.apz_str[ 69]) -#define zOneSpace (option_usage_text.apz_str[ 70]) -#define zOnlyOne (option_usage_text.apz_str[ 71]) -#define zOptsOnly (option_usage_text.apz_str[ 72]) -#define zPathFmt (option_usage_text.apz_str[ 73]) -#define zPlsSendBugs (option_usage_text.apz_str[ 74]) -#define zPreset (option_usage_text.apz_str[ 75]) -#define zPresetFile (option_usage_text.apz_str[ 76]) -#define zPresetIntro (option_usage_text.apz_str[ 77]) -#define zProg (option_usage_text.apz_str[ 78]) -#define zProhib (option_usage_text.apz_str[ 79]) -#define zReorder (option_usage_text.apz_str[ 80]) -#define zReqFmt (option_usage_text.apz_str[ 81]) -#define zReqOptFmt (option_usage_text.apz_str[ 82]) -#define zReqThese (option_usage_text.apz_str[ 83]) -#define zReq_NoShrtTtl (option_usage_text.apz_str[ 84]) -#define zReq_ShrtTtl (option_usage_text.apz_str[ 85]) -#define zSepChars (option_usage_text.apz_str[ 86]) -#define zSetMembers (option_usage_text.apz_str[ 87]) -#define zSetMemberSettings (option_usage_text.apz_str[ 88]) -#define zShrtGnuOptFmt (option_usage_text.apz_str[ 89]) -#define zSixSpaces (option_usage_text.apz_str[ 90]) -#define zStdBoolArg (option_usage_text.apz_str[ 91]) -#define zStdBreak (option_usage_text.apz_str[ 92]) -#define zStdKeyArg (option_usage_text.apz_str[ 93]) -#define zStdKeyLArg (option_usage_text.apz_str[ 94]) -#define zStdNestArg (option_usage_text.apz_str[ 95]) -#define zStdNoArg (option_usage_text.apz_str[ 96]) -#define zStdNumArg (option_usage_text.apz_str[ 97]) -#define zStdOptArg (option_usage_text.apz_str[ 98]) -#define zStdReqArg (option_usage_text.apz_str[ 99]) -#define zStdStrArg (option_usage_text.apz_str[100]) -#define zTabHyp (option_usage_text.apz_str[101]) -#define zTabHypAnd (option_usage_text.apz_str[102]) -#define zTabout (option_usage_text.apz_str[103]) -#define zThreeSpaces (option_usage_text.apz_str[104]) -#define zTwoSpaces (option_usage_text.apz_str[105]) -#define zUpTo (option_usage_text.apz_str[106]) -#define zValidKeys (option_usage_text.apz_str[107]) - - /* - * First, set up the strings. Some of these are writable. These are all in - * English. This gets compiled into libopts and is distributed here so that - * xgettext (or equivalents) can extract these strings for translation. - */ - - static char eng_zGnuBoolArg[] = "=T/F"; - static char eng_zGnuKeyArg[] = "=KWd"; - static char eng_zGnuKeyLArg[] = "=Mbr"; - static char eng_zGnuNumArg[] = "=num"; - static char eng_zGnuStrArg[] = "=str"; -static char const usage_txt[3208] = - "AutoOpts function called without option descriptor\n\0" - "\tThis exceeds the compiled library version: \0" - "Automated Options Processing Error!\n" - "\t%s called AutoOpts function with structure version %d:%d:%d.\n\0" - "\tThis is less than the minimum library version: \0" - "all\0" - "\t\t\t\t- an alternate for %s\n\0" - "%s error: the keyword `%s' is ambiguous for %s\n\0" - "ambiguous\0" - "%s: Command line arguments required\n\0" - "%d %s%s options allowed\n\0" - "version and help options:\0" - "Error %d (%s) from the pipe(2) syscall\n\0" - "ERROR: version option argument '%c' invalid. Use:\n" - "\t'v' - version only\n" - "\t'c' - version and copyright\n" - "\t'n' - version and copyright notice\n\0" - "ERROR: %s option conflicts with the %s option\n\0" - "%s(optionSaveState): error: cannot allocate %d bytes\n\0" - "\t\t\t\t- default option for unnamed options\n\0" - "\t\t\t\t- disabled as --%s\n\0" - "\t\t\t\t- enabled by default\n\0" - "-equivalence\0" - "ERROR: only \0" - " - examining environment variables named %s_*\n\0" - " \0" - "Options are specified by doubled hyphens and their name\n" - "or by a single hyphen and the flag character.\n\0" - "%%-%ds %%s\n\0" - "fs error %d (%s) on fork - cannot obtain %s usage\n\0" - "File error %d (%s) opening %s for loading options\n\0" - "fs error %d (%s) reading file %s\n\0" - "\n" - "= = = = = = = =\n\n" - "This incarnation of genshell will produce\n" - "a shell script to parse the options for %s:\n\n\0" - "\n" - "%s\n\n\0" - "=Cplx\0" - "[=arg]\0" - "--%2$s%1$s\0" - "%s: illegal option -- %c\n\0" - "%s: %s option -- %s\n\0" - "illegal\0" - "AutoOpts ERROR: invalid option descriptor for %s\n\0" - "words=\0" - "cooked\0" - "keep\0" - "type=\0" - "uncooked\0" - "integer\0" - "nested\0" - "string\0" - "bool\0" - "keyword\0" - "set\0" - "\t\t\t\t- is a set membership option\n\0" - "%s: option `%s' requires an argument\n\0" - "Equivalenced option '%s' was equivalenced to both\n" - "\t'%s' and '%s'\0" - "\t\t\t\t- must appear between %d and %d times\n\0" - "ERROR: The %s option is required\n\0" - "%s: option `%s' cannot have an argument\n\0" - "%s: Command line arguments not allowed\n\0" - "error %d (%s) creating %s\n\0" - "Options are specified by single or double hyphens and their name.\n\0" - "%s error: `%s' does not match any %s keywords\n\0" - "\t\t\t\t- may appear multiple times\n\0" - "\t\t\t\t- may not be preset\n\0" - " Arg Option-Name Description\n\0" - " Flg Arg Option-Name Description\n\0" - "error %d (%s) stat-ing %s\n\0" - "%s(optionRestore): error: no saved option state\n\0" - "none\0" - "'%s' not defined\n\0" - "ERROR: The %s option must appear %d times\n\0" - "error: cannot load options from non-regular file %s\n\0" - "%s error: `%s' is not a recognizable number\n\0" - " %3s %s\0" - "The '-#' option may omit the hash char\n\0" - " \0" - "one %s%s option allowed\n\0" - "All arguments are named options.\n\0" - " - reading file %s\0" - "\n" - "please send bug reports to: %s\n\0" - "\t\t\t\t- may NOT appear - preset only\n\0" - "# preset/initialization file\n" - "# %s#\n\0" - "\n" - "The following option preset mechanisms are supported:\n\0" - "program\0" - "prohibits these options:\n\0" - "Operands and options may be intermixed. They will be reordered.\n\0" - "ERROR: %s option requires the %s option\n\0" - " %3s %-14s %s\0" - "requires these options:\n\0" - " Arg Option-Name Req? Description\n\0" - " Flg Arg Option-Name Req? Description\n\0" - "-_^\0" - "members=\0" - "or you may use a numeric representation. Preceding these with a '!' will\n" - "clear the bits, specifying 'none' will clear all bits, and 'all' will set them\n" - "all. Multiple entries may be passed as an option argument list.\n\0" - "%s\0" - " \0" - "T/F\0" - "\n" - "%s\n\n" - "%s\0" - "KWd\0" - "Mbr\0" - "Cpx\0" - "no \0" - "Num\0" - "opt\0" - "YES\0" - "Str\0" - "\t\t\t\t- \0" - "\t\t\t\t-- and \0" - "\t\t\t\t%s\n\0" - " \0" - " \0" - "\t\t\t\t- may appear up to %d times\n\0" - "The valid \"%s\" option keywords are:\n\0"; - - - /* - * Now, define (and initialize) the structure that contains - * the pointers to all these strings. - * Aren't you glad you don't maintain this by hand? - */ - usage_text_t option_usage_text = { - 113, - eng_zGnuBoolArg, eng_zGnuKeyArg, eng_zGnuKeyLArg, eng_zGnuNumArg, - eng_zGnuStrArg, - { - usage_txt + 0, usage_txt + 52, usage_txt + 98, usage_txt + 197, - usage_txt + 247, usage_txt + 251, usage_txt + 278, usage_txt + 327, - usage_txt + 337, usage_txt + 374, usage_txt + 399, usage_txt + 425, - usage_txt + 465, usage_txt + 602, usage_txt + 650, usage_txt + 704, - usage_txt + 746, usage_txt + 770, usage_txt + 796, usage_txt + 809, - usage_txt + 823, usage_txt + 870, usage_txt + 876, usage_txt + 979, - usage_txt + 991, usage_txt +1042, usage_txt +1093, usage_txt +1127, - usage_txt +1233, usage_txt +1239, usage_txt +1245, usage_txt +1252, - usage_txt +1263, usage_txt +1289, usage_txt +1310, usage_txt +1318, - usage_txt +1369, usage_txt +1376, usage_txt +1383, usage_txt +1388, - usage_txt +1394, usage_txt +1403, usage_txt +1411, usage_txt +1418, - usage_txt +1425, usage_txt +1430, usage_txt +1438, usage_txt +1442, - usage_txt +1476, usage_txt +1514, usage_txt +1579, usage_txt +1622, - usage_txt +1657, usage_txt +1698, usage_txt +1738, usage_txt +1765, - usage_txt +1832, usage_txt +1880, usage_txt +1913, usage_txt +1938, - usage_txt +1973, usage_txt +2011, usage_txt +2038, usage_txt +2087, - usage_txt +2092, usage_txt +2110, usage_txt +2154, usage_txt +2208, - usage_txt +2254, usage_txt +2262, usage_txt +2310, usage_txt +2312, - usage_txt +2337, usage_txt +2371, usage_txt +2390, usage_txt +2424, - usage_txt +2460, usage_txt +2498, usage_txt +2554, usage_txt +2562, - usage_txt +2588, usage_txt +2654, usage_txt +2696, usage_txt +2710, - usage_txt +2735, usage_txt +2775, usage_txt +2818, usage_txt +2822, - usage_txt +2831, usage_txt +3050, usage_txt +3053, usage_txt +3060, - usage_txt +3064, usage_txt +3072, usage_txt +3076, usage_txt +3080, - usage_txt +3084, usage_txt +3088, usage_txt +3092, usage_txt +3096, - usage_txt +3100, usage_txt +3104, usage_txt +3111, usage_txt +3123, - usage_txt +3131, usage_txt +3135, usage_txt +3138, usage_txt +3171 - } - }; - -#endif /* DO_TRANSLATIONS */ -#endif /* AUTOOPTS_USAGE_TXT_H_GUARD */ diff --git a/contrib/ntp/libopts/boolean.c b/contrib/ntp/libopts/boolean.c deleted file mode 100644 index 37148a9cc..000000000 --- a/contrib/ntp/libopts/boolean.c +++ /dev/null @@ -1,106 +0,0 @@ - -/* - * $Id: boolean.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:10:39 bkorb" - * - * Automated Options Paged Usage module. - * - * This routine will run run-on options through a pager so the - * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/*=export_func optionBooleanVal - * private: - * - * what: Decipher a boolean value - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * Decipher a true or false value for a boolean valued option argument. - * The value is true, unless it starts with 'n' or 'f' or "#f" or - * it is an empty string or it is a number that evaluates to zero. -=*/ -void -optionBooleanVal( tOptions* pOpts, tOptDesc* pOD ) -{ - char* pz; - ag_bool res = AG_TRUE; - - switch (*(pOD->optArg.argString)) { - case '0': - { - long val = strtol( pOD->optArg.argString, &pz, 0 ); - if ((val != 0) || (*pz != NUL)) - break; - /* FALLTHROUGH */ - } - case 'N': - case 'n': - case 'F': - case 'f': - case NUL: - res = AG_FALSE; - break; - case '#': - if (pOD->optArg.argString[1] != 'f') - break; - res = AG_FALSE; - } - - if (pOD->fOptState & OPTST_ALLOC_ARG) { - AGFREE(pOD->optArg.argString); - pOD->fOptState &= ~OPTST_ALLOC_ARG; - } - pOD->optArg.argBool = res; -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/boolean.c */ diff --git a/contrib/ntp/libopts/compat/compat.h b/contrib/ntp/libopts/compat/compat.h deleted file mode 100644 index b3bd58ff4..000000000 --- a/contrib/ntp/libopts/compat/compat.h +++ /dev/null @@ -1,319 +0,0 @@ -/* -*- Mode: C -*- */ - -/* --- fake the preprocessor into handlng portability */ -/* - * Time-stamp: "2007-02-03 17:41:06 bkorb" - * - * Author: Gary V Vaughan - * Created: Mon Jun 30 15:54:46 1997 - * - * $Id: compat.h,v 4.16 2007/04/27 01:10:47 bkorb Exp $ - */ -#ifndef COMPAT_H_GUARD -#define COMPAT_H_GUARD 1 - -#if defined(HAVE_CONFIG_H) -# include - -#elif defined(_WIN32) && !defined(__CYGWIN__) -# include "windows-config.h" - -#else -# error "compat.h" requires "config.h" - choke me. -#endif - - -#ifndef HAVE_STRSIGNAL - char * strsignal( int signo ); -#endif - -#define _GNU_SOURCE 1 /* for strsignal in GNU's libc */ -#define __USE_GNU 1 /* exact same thing as above */ -#define __EXTENSIONS__ 1 /* and another way to call for it */ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * SYSTEM HEADERS: - */ -#include -#ifdef HAVE_SYS_MMAN_H -# include -#endif -#include -#if HAVE_SYS_PROCSET_H -# include -#endif -#include -#include - -#if defined( HAVE_SOLARIS_SYSINFO ) -# include -#elif defined( HAVE_UNAME_SYSCALL ) -# include -#endif - -#ifdef DAEMON_ENABLED -# if HAVE_SYS_STROPTS_H -# include -# endif - -# if HAVE_SYS_SOCKET_H -# include -# endif - -# if ! defined(HAVE_SYS_POLL_H) && ! defined(HAVE_SYS_SELECT_H) -# error This system cannot support daemon processing - Choke Me. -# endif - -# if HAVE_SYS_POLL_H -# include -# endif - -# if HAVE_SYS_SELECT_H -# include -# endif - -# if HAVE_NETINET_IN_H -# include -# endif - -# if HAVE_SYS_UN_H -# include -# endif -#endif - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * USER HEADERS: - */ -#include -#include -#include - -/* - * Directory opening stuff: - */ -# if defined (_POSIX_SOURCE) -/* Posix does not require that the d_ino field be present, and some - systems do not provide it. */ -# define REAL_DIR_ENTRY(dp) 1 -# else /* !_POSIX_SOURCE */ -# define REAL_DIR_ENTRY(dp) (dp->d_ino != 0) -# endif /* !_POSIX_SOURCE */ - -# if defined (HAVE_DIRENT_H) -# include -# define D_NAMLEN(dirent) strlen((dirent)->d_name) -# else /* !HAVE_DIRENT_H */ -# define dirent direct -# define D_NAMLEN(dirent) (dirent)->d_namlen -# if defined (HAVE_SYS_NDIR_H) -# include -# endif /* HAVE_SYS_NDIR_H */ -# if defined (HAVE_SYS_DIR_H) -# include -# endif /* HAVE_SYS_DIR_H */ -# if defined (HAVE_NDIR_H) -# include -# endif /* HAVE_NDIR_H */ -# endif /* !HAVE_DIRENT_H */ - -#include -#ifdef HAVE_FCNTL_H -# include -#endif -#ifndef O_NONBLOCK -# define O_NONBLOCK FNDELAY -#endif - -#if defined(HAVE_LIBGEN) && defined(HAVE_LIBGEN_H) -# include -#endif - -#if defined(HAVE_LIMITS_H) /* this is also in options.h */ -# include -#elif defined(HAVE_SYS_LIMITS_H) -# include -#endif /* HAVE_LIMITS/SYS_LIMITS_H */ - -#include -#include -#include - -#if defined( HAVE_STDINT_H ) -# include -#elif defined( HAVE_INTTYPES_H ) -# include -#endif - -#include -#include - -#include - -#ifdef HAVE_UTIME_H -# include -#endif - -#ifdef HAVE_UNISTD_H -# include -#endif - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * FIXUPS and CONVIENCE STUFF: - */ -#ifdef __cplusplus -# define EXTERN extern "C" -#else -# define EXTERN extern -#endif - -/* some systems #def errno! and others do not declare it!! */ -#ifndef errno - extern int errno; -#endif - -/* Some machines forget this! */ - -# ifndef EXIT_FAILURE -# define EXIT_SUCCESS 0 -# define EXIT_FAILURE 1 -# endif - -#ifndef NUL -# define NUL '\0' -#endif - -#ifndef NULL -# define NULL 0 -#endif - -#if !defined (MAXPATHLEN) && defined (HAVE_SYS_PARAM_H) -# include -#endif /* !MAXPATHLEN && HAVE_SYS_PARAM_H */ - -#if !defined (MAXPATHLEN) && defined (PATH_MAX) -# define MAXPATHLEN PATH_MAX -#endif /* !MAXPATHLEN && PATH_MAX */ - -#if !defined (MAXPATHLEN) && defined(_MAX_PATH) -# define PATH_MAX _MAX_PATH -# define MAXPATHLEN _MAX_PATH -#endif - -#if !defined (MAXPATHLEN) -# define MAXPATHLEN ((size_t)4096) -#endif /* MAXPATHLEN */ - -#define AG_PATH_MAX ((size_t)MAXPATHLEN) - -#ifndef LONG_MAX -# define LONG_MAX ~(1L << (8*sizeof(long) -1)) -# define INT_MAX ~(1 << (8*sizeof(int) -1)) -#endif - -#ifndef ULONG_MAX -# define ULONG_MAX ~(OUL) -# define UINT_MAX ~(OU) -#endif - -#ifndef SHORT_MAX -# define SHORT_MAX ~(1 << (8*sizeof(short) -1)) -#else -# define USHORT_MAX ~(OUS) -#endif - -#ifndef HAVE_INT8_T - typedef signed char int8_t; -#endif -#ifndef HAVE_UINT8_T - typedef unsigned char uint8_t; -#endif -#ifndef HAVE_INT16_T - typedef signed short int16_t; -#endif -#ifndef HAVE_UINT16_T - typedef unsigned short uint16_t; -#endif -#ifndef HAVE_UINT_T - typedef unsigned int uint_t; -#endif - -#ifndef HAVE_INT32_T -# if SIZEOF_INT == 4 - typedef signed int int32_t; -# elif SIZEOF_LONG == 4 - typedef signed long int32_t; -# endif -#endif - -#ifndef HAVE_UINT32_T -# if SIZEOF_INT == 4 - typedef unsigned int uint32_t; -# elif SIZEOF_LONG == 4 - typedef unsigned long uint32_t; -# else -# error Cannot create a uint32_t type. - Choke Me. -# endif -#endif - -#ifndef HAVE_INTPTR_T - typedef signed long intptr_t; -#endif -#ifndef HAVE_UINTPTR_T - typedef unsigned long uintptr_t; -#endif - -/* redefine these for BSD style string libraries */ -#ifndef HAVE_STRCHR -# define strchr index -# define strrchr rindex -#endif - -#ifdef USE_FOPEN_BINARY -# ifndef FOPEN_BINARY_FLAG -# define FOPEN_BINARY_FLAG "b" -# endif -# ifndef FOPEN_TEXT_FLAG -# define FOPEN_TEXT_FLAG "t" -# endif -#else -# ifndef FOPEN_BINARY_FLAG -# define FOPEN_BINARY_FLAG -# endif -# ifndef FOPEN_TEXT_FLAG -# define FOPEN_TEXT_FLAG -# endif -#endif - -#ifndef STR -# define _STR(s) #s -# define STR(s) _STR(s) -#endif - -/* ##### Pointer sized word ##### */ - -/* FIXME: the MAX stuff in here is broken! */ -#if SIZEOF_CHARP > SIZEOF_INT - typedef long t_word; - #define WORD_MAX LONG_MAX - #define WORD_MIN LONG_MIN -#else /* SIZEOF_CHARP <= SIZEOF_INT */ - typedef int t_word; - #define WORD_MAX INT_MAX - #define WORD_MIN INT_MIN -#endif - -#endif /* COMPAT_H_GUARD */ - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of compat/compat.h */ diff --git a/contrib/ntp/libopts/compat/pathfind.c b/contrib/ntp/libopts/compat/pathfind.c deleted file mode 100644 index 96eb77129..000000000 --- a/contrib/ntp/libopts/compat/pathfind.c +++ /dev/null @@ -1,339 +0,0 @@ -/* -*- Mode: C -*- */ - -/* pathfind.c --- find a FILE MODE along PATH */ - -/* - * Author: Gary V Vaughan - * Time-stamp: "2006-09-23 19:46:16 bkorb" - * Created: Tue Jun 24 15:07:31 1997 - * Last Modified: $Date: 2006/11/27 01:52:23 $ - * by: bkorb - * - * $Id: pathfind.c,v 4.10 2006/11/27 01:52:23 bkorb Exp $ - */ - -/* Code: */ - -#include "compat.h" -#ifndef HAVE_PATHFIND -#if defined(__windows__) && !defined(__CYGWIN__) -char* -pathfind( char const* path, - char const* fileName, - char const* mode ) -{ - return NULL; -} -#else - -static char* make_absolute( char const *string, char const *dot_path ); -static char* canonicalize_pathname( char *path ); -static char* extract_colon_unit( char* dir, char const *string, int *p_index ); - - -/*=export_func pathfind - * - * what: fild a file in a list of directories - * - * ifndef: HAVE_PATHFIND - * - * arg: + char const* + path + colon separated list of search directories + - * arg: + char const* + file + the name of the file to look for + - * arg: + char const* + mode + the mode bits that must be set to match + - * - * ret_type: char* - * ret_desc: the path to the located file - * - * doc: - * - * pathfind looks for a a file with name "FILE" and "MODE" access - * along colon delimited "PATH", and returns the full pathname as a - * string, or NULL if not found. If "FILE" contains a slash, then - * it is treated as a relative or absolute path and "PATH" is ignored. - * - * @strong{NOTE}: this function is compiled into @file{libopts} only if - * it is not natively supplied. - * - * The "MODE" argument is a string of option letters chosen from the - * list below: - * @example - * Letter Meaning - * r readable - * w writable - * x executable - * f normal file (NOT IMPLEMENTED) - * b block special (NOT IMPLEMENTED) - * c character special (NOT IMPLEMENTED) - * d directory (NOT IMPLEMENTED) - * p FIFO (pipe) (NOT IMPLEMENTED) - * u set user ID bit (NOT IMPLEMENTED) - * g set group ID bit (NOT IMPLEMENTED) - * k sticky bit (NOT IMPLEMENTED) - * s size nonzero (NOT IMPLEMENTED) - * @end example - * - * example: - * To find the "ls" command using the "PATH" environment variable: - * @example - * #include - * char* pz_ls = pathfind( getenv("PATH"), "ls", "rx" ); - * <> - * free( pz_ls ); - * @end example - * The path is allocated with @code{malloc(3C)}, so you must @code{free(3C)} - * the result. Also, do not use unimplemented file modes. :-) - * - * err: returns NULL if the file is not found. -=*/ -char* -pathfind( char const* path, - char const* fileName, - char const* mode ) -{ - int p_index = 0; - int mode_bits = 0; - char* pathName = NULL; - char zPath[ AG_PATH_MAX + 1 ]; - - if (strchr( mode, 'r' )) mode_bits |= R_OK; - if (strchr( mode, 'w' )) mode_bits |= W_OK; - if (strchr( mode, 'x' )) mode_bits |= X_OK; - - /* - * FOR each non-null entry in the colon-separated path, DO ... - */ - for (;;) { - DIR* dirP; - char* colon_unit = extract_colon_unit( zPath, path, &p_index ); - - /* - * IF no more entries, THEN quit - */ - if (colon_unit == NULL) - break; - - dirP = opendir( colon_unit ); - - /* - * IF the directory is inaccessable, THEN next directory - */ - if (dirP == NULL) - continue; - - /* - * FOR every entry in the given directory, ... - */ - for (;;) { - struct dirent *entP = readdir( dirP ); - - if (entP == (struct dirent*)NULL) - break; - - /* - * IF the file name matches the one we are looking for, ... - */ - if (strcmp( entP->d_name, fileName ) == 0) { - char* pzFullName = make_absolute( fileName, colon_unit); - - /* - * Make sure we can access it in the way we want - */ - if (access( pzFullName, mode_bits ) >= 0) { - /* - * We can, so normalize the name and return it below - */ - pathName = canonicalize_pathname( pzFullName ); - } - - free( (void*)pzFullName ); - break; - } - } - - closedir( dirP ); - - if (pathName != NULL) - break; - } - - return pathName; -} - -/* - * Turn STRING (a pathname) into an absolute pathname, assuming that - * DOT_PATH contains the symbolic location of `.'. This always returns - * a new string, even if STRING was an absolute pathname to begin with. - */ -static char* -make_absolute( char const *string, char const *dot_path ) -{ - char *result; - int result_len; - - if (!dot_path || *string == '/') { - result = strdup( string ); - } else { - if (dot_path && dot_path[0]) { - result = malloc( 2 + strlen( dot_path ) + strlen( string ) ); - strcpy( result, dot_path ); - result_len = strlen( result ); - if (result[result_len - 1] != '/') { - result[result_len++] = '/'; - result[result_len] = '\0'; - } - } else { - result = malloc( 3 + strlen( string ) ); - result[0] = '.'; result[1] = '/'; result[2] = '\0'; - result_len = 2; - } - - strcpy( result + result_len, string ); - } - - return result; -} - -/* - * Canonicalize PATH, and return a new path. The new path differs from - * PATH in that: - * - * Multiple `/'s are collapsed to a single `/'. - * Leading `./'s are removed. - * Trailing `/.'s are removed. - * Trailing `/'s are removed. - * Non-leading `../'s and trailing `..'s are handled by removing - * portions of the path. - */ -static char* -canonicalize_pathname( char *path ) -{ - int i, start; - char stub_char, *result; - - /* The result cannot be larger than the input PATH. */ - result = strdup( path ); - - stub_char = (*path == '/') ? '/' : '.'; - - /* Walk along RESULT looking for things to compact. */ - i = 0; - while (result[i]) { - while (result[i] != '\0' && result[i] != '/') - i++; - - start = i++; - - /* If we didn't find any slashes, then there is nothing left to - * do. - */ - if (!result[start]) - break; - - /* Handle multiple `/'s in a row. */ - while (result[i] == '/') - i++; - -#if !defined (apollo) - if ((start + 1) != i) -#else - if ((start + 1) != i && (start != 0 || i != 2)) -#endif /* apollo */ - { - strcpy( result + start + 1, result + i ); - i = start + 1; - } - - /* Handle backquoted `/'. */ - if (start > 0 && result[start - 1] == '\\') - continue; - - /* Check for trailing `/', and `.' by itself. */ - if ((start && !result[i]) - || (result[i] == '.' && !result[i+1])) { - result[--i] = '\0'; - break; - } - - /* Check for `../', `./' or trailing `.' by itself. */ - if (result[i] == '.') { - /* Handle `./'. */ - if (result[i + 1] == '/') { - strcpy( result + i, result + i + 1 ); - i = (start < 0) ? 0 : start; - continue; - } - - /* Handle `../' or trailing `..' by itself. */ - if (result[i + 1] == '.' && - (result[i + 2] == '/' || !result[i + 2])) { - while (--start > -1 && result[start] != '/') - ; - strcpy( result + start + 1, result + i + 2 ); - i = (start < 0) ? 0 : start; - continue; - } - } - } - - if (!*result) { - *result = stub_char; - result[1] = '\0'; - } - - return result; -} - -/* - * Given a string containing units of information separated by colons, - * return the next one pointed to by (P_INDEX), or NULL if there are no - * more. Advance (P_INDEX) to the character after the colon. - */ -static char* -extract_colon_unit( char* pzDir, char const *string, int *p_index ) -{ - char* pzDest = pzDir; - int ix = *p_index; - - if (string == NULL) - return NULL; - - if ((unsigned)ix >= strlen( string )) - return NULL; - - { - char const* pzSrc = string + ix; - - while (*pzSrc == ':') pzSrc++; - - for (;;) { - char ch = (*(pzDest++) = *(pzSrc++)); - switch (ch) { - case ':': - pzDest[-1] = NUL; - case NUL: - goto copy_done; - } - - if ((pzDest - pzDir) >= AG_PATH_MAX) - break; - } copy_done:; - - ix = pzSrc - string; - } - - if (*pzDir == NUL) - return NULL; - - *p_index = ix; - return pzDir; -} -#endif /* __windows__ / __CYGWIN__ */ -#endif /* HAVE_PATHFIND */ - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of compat/pathfind.c */ diff --git a/contrib/ntp/libopts/compat/snprintf.c b/contrib/ntp/libopts/compat/snprintf.c deleted file mode 100644 index fc91d63a9..000000000 --- a/contrib/ntp/libopts/compat/snprintf.c +++ /dev/null @@ -1,60 +0,0 @@ - -#ifndef HAVE_VPRINTF -#include "choke-me: no vprintf and no snprintf" -#endif - -#if defined(HAVE_STDARG_H) -# include -# ifndef VA_START -# define VA_START(a, f) va_start(a, f) -# define VA_END(a) va_end(a) -# endif /* VA_START */ -# define SNV_USING_STDARG_H - -#elif defined(HAVE_VARARGS_H) -# include -# ifndef VA_START -# define VA_START(a, f) va_start(a) -# define VA_END(a) va_end(a) -# endif /* VA_START */ -# undef SNV_USING_STDARG_H - -#else -# include "must-have-stdarg-or-varargs" -#endif - -static int -snprintf(char *str, size_t n, char const *fmt, ...) -{ - va_list ap; - int rval; - -#ifdef VSPRINTF_CHARSTAR - char *rp; - VA_START(ap, fmt); - rp = vsprintf(str, fmt, ap); - VA_END(ap); - rval = strlen(rp); - -#else - VA_START(ap, fmt); - rval = vsprintf(str, fmt, ap); - VA_END(ap); -#endif - - if (rval > n) { - fprintf(stderr, "snprintf buffer overrun %d > %d\n", rval, (int)n); - abort(); - } - return rval; -} - -static int -vsnprintf( char *str, size_t n, char const *fmt, va_list ap ) -{ -#ifdef VSPRINTF_CHARSTAR - return (strlen(vsprintf(str, fmt, ap))); -#else - return (vsprintf(str, fmt, ap)); -#endif -} diff --git a/contrib/ntp/libopts/compat/strchr.c b/contrib/ntp/libopts/compat/strchr.c deleted file mode 100644 index 413f999ff..000000000 --- a/contrib/ntp/libopts/compat/strchr.c +++ /dev/null @@ -1,60 +0,0 @@ -/* - SYNOPSIS - #include - - char *strchr(char const *s, int c); - - char *strrchr(char const *s, int c); - - DESCRIPTION - The strchr() function returns a pointer to the first occurrence of the - character c in the string s. - - The strrchr() function returns a pointer to the last occurrence of the - character c in the string s. - - Here "character" means "byte" - these functions do not work with wide - or multi-byte characters. - - RETURN VALUE - The strchr() and strrchr() functions return a pointer to the matched - character or NULL if the character is not found. - - CONFORMING TO - SVID 3, POSIX, BSD 4.3, ISO 9899 -*/ - -char* -strchr( char const *s, int c) -{ - do { - if ((unsigned)*s == (unsigned)c) - return s; - - } while (*(++s) != NUL); - - return NULL; -} - -char* -strrchr( char const *s, int c) -{ - char const *e = s + strlen(s); - - for (;;) { - if (--e < s) - break; - - if ((unsigned)*e == (unsigned)c) - return e; - } - return NULL; -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of compat/strsignal.c */ diff --git a/contrib/ntp/libopts/compat/strdup.c b/contrib/ntp/libopts/compat/strdup.c deleted file mode 100644 index e2933a8af..000000000 --- a/contrib/ntp/libopts/compat/strdup.c +++ /dev/null @@ -1,19 +0,0 @@ -/* - * Platforms without strdup ?!?!?! - */ - -static char * -strdup( char const *s ) -{ - char *cp; - - if (s == NULL) - return NULL; - - cp = (char *) AGALOC((unsigned) (strlen(s)+1), "strdup"); - - if (cp != NULL) - (void) strcpy(cp, s); - - return cp; -} diff --git a/contrib/ntp/libopts/compat/windows-config.h b/contrib/ntp/libopts/compat/windows-config.h deleted file mode 100644 index 2612980bf..000000000 --- a/contrib/ntp/libopts/compat/windows-config.h +++ /dev/null @@ -1,130 +0,0 @@ - -/* - * Time-stamp: "2006-10-14 14:55:09 bkorb" - * by: bkorb - * Last Committed: $Date: 2007/04/28 22:19:23 $ - */ -#ifndef WINDOWS_CONFIG_HACKERY -#define WINDOWS_CONFIG_HACKERY 1 - -/* - * The definitions below have been stolen from NTP's config.h for Windows. - * However, they may be kept here in order to keep libopts independent from - * the NTP project. - */ -#ifndef __windows__ -# define __windows__ 4 -#endif - -/* - * Miscellaneous functions that Microsoft maps - * to other names - * - * #define inline __inline - * #define vsnprintf _vsnprintf - */ -#define snprintf _snprintf -/* - * #define stricmp _stricmp - * #define strcasecmp _stricmp - * #define isascii __isascii - * #define finite _finite - * #define random rand - * #define srandom srand - */ - -#define SIZEOF_INT 4 -#define SIZEOF_CHARP 4 -#define SIZEOF_LONG 4 -#define SIZEOF_SHORT 2 - -typedef unsigned long uintptr_t; - -/* - * # define HAVE_NET_IF_H - * # define QSORT_USES_VOID_P - * # define HAVE_SETVBUF - * # define HAVE_VSPRINTF - * # define HAVE_SNPRINTF - * # define HAVE_VSNPRINTF - * # define HAVE_PROTOTYPES /* from ntpq.mak * / - * # define HAVE_MEMMOVE - * # define HAVE_TERMIOS_H - * # define HAVE_ERRNO_H - * # define HAVE_STDARG_H - * # define HAVE_NO_NICE - * # define HAVE_MKTIME - * # define TIME_WITH_SYS_TIME - * # define HAVE_IO_COMPLETION_PORT - * # define ISC_PLATFORM_NEEDNTOP - * # define ISC_PLATFORM_NEEDPTON - * # define NEED_S_CHAR_TYPEDEF - * # define USE_PROTOTYPES /* for ntp_types.h * / - * - * #define ULONG_CONST(a) a ## UL - */ - -#define HAVE_LIMITS_H 1 -#define HAVE_STRDUP 1 -#define HAVE_STRCHR 1 -#define HAVE_FCNTL_H 1 - -/* - * VS.NET's version of wspiapi.h has a bug in it - * where it assigns a value to a variable inside - * an if statement. It should be comparing them. - * We prevent inclusion since we are not using this - * code so we don't have to see the warning messages - */ -#ifndef _WSPIAPI_H_ -#define _WSPIAPI_H_ -#endif - -/* Prevent inclusion of winsock.h in windows.h */ -#ifndef _WINSOCKAPI_ -#define _WINSOCKAPI_ -#endif - -#ifndef __RPCASYNC_H__ -#define __RPCASYNC_H__ -#endif - -/* Include Windows headers */ -#include -#include -#include - -/* - * Compatibility declarations for Windows, assuming SYS_WINNT - * has been defined. - */ -#define strdup _strdup -#define stat _stat /* struct stat from */ -#define unlink _unlink -#define fchmod( _x, _y ); -#define ssize_t SSIZE_T - -#include -#define open _open -#define close _close -#define read _read -#define write _write -#define lseek _lseek -#define pipe _pipe -#define dup2 _dup2 - -#define O_RDWR _O_RDWR -#define O_RDONLY _O_RDONLY -#define O_EXCL _O_EXCL - -#ifndef S_ISREG -# define S_IFREG _S_IFREG -# define S_ISREG(mode) (((mode) & S_IFREG) == S_IFREG) -#endif - -#ifndef S_ISDIR -# define S_IFDIR _S_IFDIR -# define S_ISDIR(mode) (((mode) & S_IFDIR) == S_IFDIR) -#endif - -#endif /* WINDOWS_CONFIG_HACKERY */ diff --git a/contrib/ntp/libopts/configfile.c b/contrib/ntp/libopts/configfile.c deleted file mode 100644 index e0b8a7487..000000000 --- a/contrib/ntp/libopts/configfile.c +++ /dev/null @@ -1,1290 +0,0 @@ -/* - * $Id: configfile.c,v 1.21 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:22:46 bkorb" - * - * configuration/rc/ini file handling. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -filePreset( - tOptions* pOpts, - char const* pzFileName, - int direction ); - -static char* -handleComment( char* pzText ); - -static char* -handleConfig( - tOptions* pOpts, - tOptState* pOS, - char* pzText, - int direction ); - -static char* -handleDirective( - tOptions* pOpts, - char* pzText ); - -static char* -handleProgramSection( - tOptions* pOpts, - char* pzText ); - -static char* -handleStructure( - tOptions* pOpts, - tOptState* pOS, - char* pzText, - int direction ); - -static char* -parseKeyWordType( - tOptions* pOpts, - char* pzText, - tOptionValue* pType ); - -static char* -parseLoadMode( - char* pzText, - tOptionLoadMode* pMode ); - -static char* -parseSetMemType( - tOptions* pOpts, - char* pzText, - tOptionValue* pType ); - -static char* -parseValueType( - char* pzText, - tOptionValue* pType ); - -static char* -skipUnknown( char* pzText ); -/* = = = END-STATIC-FORWARD = = = */ - - -/*=export_func configFileLoad - * - * what: parse a configuration file - * arg: + char const* + pzFile + the file to load + - * - * ret_type: const tOptionValue* - * ret_desc: An allocated, compound value structure - * - * doc: - * This routine will load a named configuration file and parse the - * text as a hierarchically valued option. The option descriptor - * created from an option definition file is not used via this interface. - * The returned value is "named" with the input file name and is of - * type "@code{OPARG_TYPE_HIERARCHY}". It may be used in calls to - * @code{optionGetValue()}, @code{optionNextValue()} and - * @code{optionUnloadNested()}. - * - * err: - * If the file cannot be loaded or processed, @code{NULL} is returned and - * @var{errno} is set. It may be set by a call to either @code{open(2)} - * @code{mmap(2)} or other file system calls, or it may be: - * @itemize @bullet - * @item - * @code{ENOENT} - the file was empty. - * @item - * @code{EINVAL} - the file contents are invalid -- not properly formed. - * @item - * @code{ENOMEM} - not enough memory to allocate the needed structures. - * @end itemize -=*/ -const tOptionValue* -configFileLoad( char const* pzFile ) -{ - tmap_info_t cfgfile; - tOptionValue* pRes = NULL; - tOptionLoadMode save_mode = option_load_mode; - - char* pzText = - text_mmap( pzFile, PROT_READ, MAP_PRIVATE, &cfgfile ); - - if (TEXT_MMAP_FAILED_ADDR(pzText)) - return NULL; /* errno is set */ - - option_load_mode = OPTION_LOAD_COOKED; - pRes = optionLoadNested(pzText, pzFile, strlen(pzFile)); - - if (pRes == NULL) { - int err = errno; - text_munmap( &cfgfile ); - errno = err; - } else - text_munmap( &cfgfile ); - - option_load_mode = save_mode; - return pRes; -} - - -/*=export_func optionFindValue - * - * what: find a hierarcicaly valued option instance - * arg: + const tOptDesc* + pOptDesc + an option with a nested arg type + - * arg: + char const* + name + name of value to find + - * arg: + char const* + value + the matching value + - * - * ret_type: const tOptionValue* - * ret_desc: a compound value structure - * - * doc: - * This routine will find an entry in a nested value option or configurable. - * It will search through the list and return a matching entry. - * - * err: - * The returned result is NULL and errno is set: - * @itemize @bullet - * @item - * @code{EINVAL} - the @code{pOptValue} does not point to a valid - * hierarchical option value. - * @item - * @code{ENOENT} - no entry matched the given name. - * @end itemize -=*/ -const tOptionValue* -optionFindValue( const tOptDesc* pOptDesc, - char const* pzName, char const* pzVal ) -{ - const tOptionValue* pRes = NULL; - - if ( (pOptDesc == NULL) - || (OPTST_GET_ARGTYPE(pOptDesc->fOptState) != OPARG_TYPE_HIERARCHY)) { - errno = EINVAL; - } - - else if (pOptDesc->optCookie == NULL) { - errno = ENOENT; - } - - else do { - tArgList* pAL = pOptDesc->optCookie; - int ct = pAL->useCt; - void** ppOV = (void**)(pAL->apzArgs); - - if (ct == 0) { - errno = ENOENT; - break; - } - - if (pzName == NULL) { - pRes = (tOptionValue*)*ppOV; - break; - } - - while (--ct >= 0) { - const tOptionValue* pOV = *(ppOV++); - const tOptionValue* pRV = optionGetValue( pOV, pzName ); - - if (pRV == NULL) - continue; - - if (pzVal == NULL) { - pRes = pOV; - break; - } - } - if (pRes == NULL) - errno = ENOENT; - } while (0); - - return pRes; -} - - -/*=export_func optionFindNextValue - * - * what: find a hierarcicaly valued option instance - * arg: + const tOptDesc* + pOptDesc + an option with a nested arg type + - * arg: + const tOptionValue* + pPrevVal + the last entry + - * arg: + char const* + name + name of value to find + - * arg: + char const* + value + the matching value + - * - * ret_type: const tOptionValue* - * ret_desc: a compound value structure - * - * doc: - * This routine will find the next entry in a nested value option or - * configurable. It will search through the list and return the next entry - * that matches the criteria. - * - * err: - * The returned result is NULL and errno is set: - * @itemize @bullet - * @item - * @code{EINVAL} - the @code{pOptValue} does not point to a valid - * hierarchical option value. - * @item - * @code{ENOENT} - no entry matched the given name. - * @end itemize -=*/ -const tOptionValue* -optionFindNextValue( const tOptDesc* pOptDesc, const tOptionValue* pPrevVal, - char const* pzName, char const* pzVal ) -{ - int foundOldVal = 0; - tOptionValue* pRes = NULL; - - if ( (pOptDesc == NULL) - || (OPTST_GET_ARGTYPE(pOptDesc->fOptState) != OPARG_TYPE_HIERARCHY)) { - errno = EINVAL; - } - - else if (pOptDesc->optCookie == NULL) { - errno = ENOENT; - } - - else do { - tArgList* pAL = pOptDesc->optCookie; - int ct = pAL->useCt; - void** ppOV = (void**)pAL->apzArgs; - - if (ct == 0) { - errno = ENOENT; - break; - } - - while (--ct >= 0) { - tOptionValue* pOV = *(ppOV++); - if (foundOldVal) { - pRes = pOV; - break; - } - if (pOV == pPrevVal) - foundOldVal = 1; - } - if (pRes == NULL) - errno = ENOENT; - } while (0); - - return pRes; -} - - -/*=export_func optionGetValue - * - * what: get a specific value from a hierarcical list - * arg: + const tOptionValue* + pOptValue + a hierarchcal value + - * arg: + char const* + valueName + name of value to get + - * - * ret_type: const tOptionValue* - * ret_desc: a compound value structure - * - * doc: - * This routine will find an entry in a nested value option or configurable. - * If "valueName" is NULL, then the first entry is returned. Otherwise, - * the first entry with a name that exactly matches the argument will be - * returned. - * - * err: - * The returned result is NULL and errno is set: - * @itemize @bullet - * @item - * @code{EINVAL} - the @code{pOptValue} does not point to a valid - * hierarchical option value. - * @item - * @code{ENOENT} - no entry matched the given name. - * @end itemize -=*/ -const tOptionValue* -optionGetValue( const tOptionValue* pOld, char const* pzValName ) -{ - tArgList* pAL; - tOptionValue* pRes = NULL; - - if ((pOld == NULL) || (pOld->valType != OPARG_TYPE_HIERARCHY)) { - errno = EINVAL; - return NULL; - } - pAL = pOld->v.nestVal; - - if (pAL->useCt > 0) { - int ct = pAL->useCt; - void** papOV = (void**)(pAL->apzArgs); - - if (pzValName == NULL) { - pRes = (tOptionValue*)*papOV; - } - - else do { - tOptionValue* pOV = *(papOV++); - if (strcmp( pOV->pzName, pzValName ) == 0) { - pRes = pOV; - break; - } - } while (--ct > 0); - } - if (pRes == NULL) - errno = ENOENT; - return pRes; -} - - -/*=export_func optionNextValue - * - * what: get the next value from a hierarchical list - * arg: + const tOptionValue* + pOptValue + a hierarchcal list value + - * arg: + const tOptionValue* + pOldValue + a value from this list + - * - * ret_type: const tOptionValue* - * ret_desc: a compound value structure - * - * doc: - * This routine will return the next entry after the entry passed in. At the - * end of the list, NULL will be returned. If the entry is not found on the - * list, NULL will be returned and "@var{errno}" will be set to EINVAL. - * The "@var{pOldValue}" must have been gotten from a prior call to this - * routine or to "@code{opitonGetValue()}". - * - * err: - * The returned result is NULL and errno is set: - * @itemize @bullet - * @item - * @code{EINVAL} - the @code{pOptValue} does not point to a valid - * hierarchical option value or @code{pOldValue} does not point to a - * member of that option value. - * @item - * @code{ENOENT} - the supplied @code{pOldValue} pointed to the last entry. - * @end itemize -=*/ -tOptionValue const * -optionNextValue(tOptionValue const * pOVList,tOptionValue const * pOldOV ) -{ - tArgList* pAL; - tOptionValue* pRes = NULL; - int err = EINVAL; - - if ((pOVList == NULL) || (pOVList->valType != OPARG_TYPE_HIERARCHY)) { - errno = EINVAL; - return NULL; - } - pAL = pOVList->v.nestVal; - { - int ct = pAL->useCt; - void** papNV = (void**)(pAL->apzArgs); - - while (ct-- > 0) { - tOptionValue* pNV = *(papNV++); - if (pNV == pOldOV) { - if (ct == 0) { - err = ENOENT; - - } else { - err = 0; - pRes = (tOptionValue*)*papNV; - } - break; - } - } - } - if (err != 0) - errno = err; - return pRes; -} - - -/* filePreset - * - * Load a file containing presetting information (a configuration file). - */ -static void -filePreset( - tOptions* pOpts, - char const* pzFileName, - int direction ) -{ - tmap_info_t cfgfile; - tOptState st = OPTSTATE_INITIALIZER(PRESET); - char* pzFileText = - text_mmap( pzFileName, PROT_READ|PROT_WRITE, MAP_PRIVATE, &cfgfile ); - - if (TEXT_MMAP_FAILED_ADDR(pzFileText)) - return; - - if (direction == DIRECTION_CALLED) { - st.flags = OPTST_DEFINED; - direction = DIRECTION_PROCESS; - } - - /* - * IF this is called via "optionProcess", then we are presetting. - * This is the default and the PRESETTING bit will be set. - * If this is called via "optionFileLoad", then the bit is not set - * and we consider stuff set herein to be "set" by the client program. - */ - if ((pOpts->fOptSet & OPTPROC_PRESETTING) == 0) - st.flags = OPTST_SET; - - do { - while (isspace( (int)*pzFileText )) pzFileText++; - - if (isalpha( (int)*pzFileText )) { - pzFileText = handleConfig( pOpts, &st, pzFileText, direction ); - - } else switch (*pzFileText) { - case '<': - if (isalpha( (int)pzFileText[1] )) - pzFileText = handleStructure(pOpts, &st, pzFileText, direction); - - else switch (pzFileText[1]) { - case '?': - pzFileText = handleDirective( pOpts, pzFileText ); - break; - - case '!': - pzFileText = handleComment( pzFileText ); - break; - - case '/': - pzFileText = strchr( pzFileText+2, '>' ); - if (pzFileText++ != NULL) - break; - - default: - goto all_done; - } - break; - - case '[': - pzFileText = handleProgramSection( pOpts, pzFileText ); - break; - - case '#': - pzFileText = strchr( pzFileText+1, '\n' ); - break; - - default: - goto all_done; /* invalid format */ - } - } while (pzFileText != NULL); - - all_done: - text_munmap( &cfgfile ); -} - - -/* handleComment - * - * "pzText" points to a "". - */ -static char* -handleComment( char* pzText ) -{ - char* pz = strstr( pzText, "-->" ); - if (pz != NULL) - pz += 3; - return pz; -} - - -/* handleConfig - * - * "pzText" points to the start of some value name. - * The end of the entry is the end of the line that is not preceded by - * a backslash escape character. The string value is always processed - * in "cooked" mode. - */ -static char* -handleConfig( - tOptions* pOpts, - tOptState* pOS, - char* pzText, - int direction ) -{ - char* pzName = pzText++; - char* pzEnd = strchr( pzText, '\n' ); - - if (pzEnd == NULL) - return pzText + strlen(pzText); - - while (ISNAMECHAR( (int)*pzText )) pzText++; - while (isspace( (int)*pzText )) pzText++; - if (pzText > pzEnd) { - name_only: - *pzEnd++ = NUL; - loadOptionLine( pOpts, pOS, pzName, direction, OPTION_LOAD_UNCOOKED ); - return pzEnd; - } - - /* - * Either the first character after the name is a ':' or '=', - * or else we must have skipped over white space. Anything else - * is an invalid format and we give up parsing the text. - */ - if ((*pzText == '=') || (*pzText == ':')) { - while (isspace( (int)*++pzText )) ; - if (pzText > pzEnd) - goto name_only; - } else if (! isspace((int)pzText[-1])) - return NULL; - - /* - * IF the value is continued, remove the backslash escape and push "pzEnd" - * on to a newline *not* preceded by a backslash. - */ - if (pzEnd[-1] == '\\') { - char* pcD = pzEnd-1; - char* pcS = pzEnd; - - for (;;) { - char ch = *(pcS++); - switch (ch) { - case NUL: - pcS = NULL; - - case '\n': - *pcD = NUL; - pzEnd = pcS; - goto copy_done; - - case '\\': - if (*pcS == '\n') { - ch = *(pcS++); - } - /* FALLTHROUGH */ - default: - *(pcD++) = ch; - } - } copy_done:; - - } else { - /* - * The newline was not preceded by a backslash. NUL it out - */ - *(pzEnd++) = NUL; - } - - /* - * "pzName" points to what looks like text for one option/configurable. - * It is NUL terminated. Process it. - */ - loadOptionLine( pOpts, pOS, pzName, direction, OPTION_LOAD_UNCOOKED ); - - return pzEnd; -} - - -/* handleDirective - * - * "pzText" points to a "' ); - if (pzText != NULL) - pzText++; - return pzText; - } - - name_len = strlen( pOpts->pzProgName ); - strcpy( ztitle+2, zProg ); - title_len += 2; - - do { - pzText += title_len; - - if (isspace((int)*pzText)) { - while (isspace((int)*pzText)) pzText++; - if ( (strneqvcmp( pzText, pOpts->pzProgName, (int)name_len) == 0) - && (pzText[name_len] == '>')) { - pzText += name_len + 1; - break; - } - } - - pzText = strstr( pzText, ztitle ); - } while (pzText != NULL); - - return pzText; -} - - -/* handleProgramSection - * - * "pzText" points to a '[' character. - * The "traditional" [PROG_NAME] segmentation of the config file. - * Do not ever mix with the "" variation. - */ -static char* -handleProgramSection( - tOptions* pOpts, - char* pzText ) -{ - size_t len = strlen( pOpts->pzPROGNAME ); - if ( (strncmp( pzText+1, pOpts->pzPROGNAME, len ) == 0) - && (pzText[len+1] == ']')) - return strchr( pzText + len + 2, '\n' ); - - if (len > 16) - return NULL; - - { - char z[24]; - sprintf( z, "[%s]", pOpts->pzPROGNAME ); - pzText = strstr( pzText, z ); - } - - if (pzText != NULL) - pzText = strchr( pzText, '\n' ); - return pzText; -} - - -/* handleStructure - * - * "pzText" points to a '<' character, followed by an alpha. - * The end of the entry is either the "/>" following the name, or else a - * "" string. - */ -static char* -handleStructure( - tOptions* pOpts, - tOptState* pOS, - char* pzText, - int direction ) -{ - tOptionLoadMode mode = option_load_mode; - tOptionValue valu; - - char* pzName = ++pzText; - char* pzData; - char* pcNulPoint; - - while (ISNAMECHAR( *pzText )) pzText++; - pcNulPoint = pzText; - valu.valType = OPARG_TYPE_STRING; - - switch (*pzText) { - case ' ': - case '\t': - pzText = parseAttributes( pOpts, pzText, &mode, &valu ); - if (*pzText == '>') - break; - if (*pzText != '/') - return NULL; - /* FALLTHROUGH */ - - case '/': - if (pzText[1] != '>') - return NULL; - *pzText = NUL; - pzText += 2; - loadOptionLine( pOpts, pOS, pzName, direction, mode ); - return pzText; - - case '>': - break; - - default: - pzText = strchr( pzText, '>'); - if (pzText != NULL) - pzText++; - return pzText; - } - - /* - * If we are here, we have a value. "pzText" points to a closing angle - * bracket. Separate the name from the value for a moment. - */ - *pcNulPoint = NUL; - pzData = ++pzText; - - /* - * Find the end of the option text and NUL terminate it - */ - { - char z[64], *pz = z; - size_t len = strlen(pzName) + 4; - if (len > sizeof(z)) - pz = AGALOC(len, "scan name"); - - sprintf( pz, "", pzName ); - *pzText = ' '; - pzText = strstr( pzText, pz ); - if (pz != z) AGFREE(pz); - - if (pzText == NULL) - return pzText; - - *pzText = NUL; - - pzText += len-1; - } - - /* - * Rejoin the name and value for parsing by "loadOptionLine()". - * Erase any attributes parsed by "parseAttributes()". - */ - memset(pcNulPoint, ' ', pzData - pcNulPoint); - - /* - * "pzName" points to what looks like text for one option/configurable. - * It is NUL terminated. Process it. - */ - loadOptionLine( pOpts, pOS, pzName, direction, mode ); - - return pzText; -} - - -/* internalFileLoad - * - * Load a configuration file. This may be invoked either from - * scanning the "homerc" list, or from a specific file request. - * (see "optionFileLoad()", the implementation for --load-opts) - */ -LOCAL void -internalFileLoad( tOptions* pOpts ) -{ - int idx; - int inc = DIRECTION_PRESET; - char zFileName[ AG_PATH_MAX+1 ]; - - if (pOpts->papzHomeList == NULL) - return; - - /* - * Find the last RC entry (highest priority entry) - */ - for (idx = 0; pOpts->papzHomeList[ idx+1 ] != NULL; ++idx) ; - - /* - * For every path in the home list, ... *TWICE* We start at the last - * (highest priority) entry, work our way down to the lowest priority, - * handling the immediate options. - * Then we go back up, doing the normal options. - */ - for (;;) { - struct stat StatBuf; - cch_t* pzPath; - - /* - * IF we've reached the bottom end, change direction - */ - if (idx < 0) { - inc = DIRECTION_PROCESS; - idx = 0; - } - - pzPath = pOpts->papzHomeList[ idx ]; - - /* - * IF we've reached the top end, bail out - */ - if (pzPath == NULL) - break; - - idx += inc; - - if (! optionMakePath( zFileName, (int)sizeof(zFileName), - pzPath, pOpts->pzProgPath )) - continue; - - /* - * IF the file name we constructed is a directory, - * THEN append the Resource Configuration file name - * ELSE we must have the complete file name - */ - if (stat( zFileName, &StatBuf ) != 0) - continue; /* bogus name - skip the home list entry */ - - if (S_ISDIR( StatBuf.st_mode )) { - size_t len = strlen( zFileName ); - char* pz; - - if (len + 1 + strlen( pOpts->pzRcName ) >= sizeof( zFileName )) - continue; - - pz = zFileName + len; - if (pz[-1] != DIRCH) - *(pz++) = DIRCH; - strcpy( pz, pOpts->pzRcName ); - } - - filePreset( pOpts, zFileName, inc ); - - /* - * IF we are now to skip config files AND we are presetting, - * THEN change direction. We must go the other way. - */ - { - tOptDesc * pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts+1; - if (DISABLED_OPT(pOD) && PRESETTING(inc)) { - idx -= inc; /* go back and reprocess current file */ - inc = DIRECTION_PROCESS; - } - } - } /* twice for every path in the home list, ... */ -} - - -/*=export_func optionFileLoad - * - * what: Load the locatable config files, in order - * - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + char const* + pzProg + program name + - * - * ret_type: int - * ret_desc: 0 -> SUCCESS, -1 -> FAILURE - * - * doc: - * - * This function looks in all the specified directories for a configuration - * file ("rc" file or "ini" file) and processes any found twice. The first - * time through, they are processed in reverse order (last file first). At - * that time, only "immediate action" configurables are processed. For - * example, if the last named file specifies not processing any more - * configuration files, then no more configuration files will be processed. - * Such an option in the @strong{first} named directory will have no effect. - * - * Once the immediate action configurables have been handled, then the - * directories are handled in normal, forward order. In that way, later - * config files can override the settings of earlier config files. - * - * See the AutoOpts documentation for a thorough discussion of the - * config file format. - * - * Configuration files not found or not decipherable are simply ignored. - * - * err: Returns the value, "-1" if the program options descriptor - * is out of date or indecipherable. Otherwise, the value "0" will - * always be returned. -=*/ -int -optionFileLoad( tOptions* pOpts, char const* pzProgram ) -{ - if (! SUCCESSFUL( validateOptionsStruct( pOpts, pzProgram ))) - return -1; - - pOpts->pzProgName = pzProgram; - internalFileLoad( pOpts ); - return 0; -} - - -/*=export_func optionLoadOpt - * private: - * - * what: Load an option rc/ini file - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * Processes the options found in the file named with - * pOptDesc->optArg.argString. -=*/ -void -optionLoadOpt( tOptions* pOpts, tOptDesc* pOptDesc ) -{ - /* - * IF the option is not being disabled, THEN load the file. There must - * be a file. (If it is being disabled, then the disablement processing - * already took place. It must be done to suppress preloading of ini/rc - * files.) - */ - if (! DISABLED_OPT( pOptDesc )) { - struct stat sb; - if (stat( pOptDesc->optArg.argString, &sb ) != 0) { - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) - return; - - fprintf( stderr, zFSErrOptLoad, errno, strerror( errno ), - pOptDesc->optArg.argString ); - exit(EX_NOINPUT); - /* NOT REACHED */ - } - - if (! S_ISREG( sb.st_mode )) { - if ((pOpts->fOptSet & OPTPROC_ERRSTOP) == 0) - return; - - fprintf( stderr, zNotFile, pOptDesc->optArg.argString ); - exit(EX_NOINPUT); - /* NOT REACHED */ - } - - filePreset(pOpts, pOptDesc->optArg.argString, DIRECTION_CALLED); - } -} - - -/* parseAttributes - * - * Parse the various attributes of an XML-styled config file entry - */ -LOCAL char* -parseAttributes( - tOptions* pOpts, - char* pzText, - tOptionLoadMode* pMode, - tOptionValue* pType ) -{ - size_t lenLoadType = strlen( zLoadType ); - size_t lenKeyWords = strlen( zKeyWords ); - size_t lenSetMem = strlen( zSetMembers ); - - do { - switch (*pzText) { - case '/': pType->valType = OPARG_TYPE_NONE; - case '>': return pzText; - - default: - case NUL: return NULL; - - case ' ': - case '\t': - case '\n': - case '\f': - case '\r': - case '\v': - break; - } - - while (isspace( (int)*++pzText )) ; - - if (strncmp( pzText, zLoadType, lenLoadType ) == 0) { - pzText = parseValueType( pzText+lenLoadType, pType ); - continue; - } - - if (strncmp( pzText, zKeyWords, lenKeyWords ) == 0) { - pzText = parseKeyWordType( pOpts, pzText+lenKeyWords, pType ); - continue; - } - - if (strncmp( pzText, zSetMembers, lenSetMem ) == 0) { - pzText = parseSetMemType( pOpts, pzText+lenSetMem, pType ); - continue; - } - - pzText = parseLoadMode( pzText, pMode ); - } while (pzText != NULL); - - return pzText; -} - - -/* parseKeyWordType - * - * "pzText" points to the character after "words=". - * What should follow is a name of a keyword (enumeration) list. - */ -static char* -parseKeyWordType( - tOptions* pOpts, - char* pzText, - tOptionValue* pType ) -{ - return skipUnknown( pzText ); -} - - -/* parseLoadMode - * - * "pzText" points to some name character. We check for "cooked" or - * "uncooked" or "keep". This function should handle any attribute - * that does not have an associated value. - */ -static char* -parseLoadMode( - char* pzText, - tOptionLoadMode* pMode ) -{ - { - size_t len = strlen(zLoadCooked); - if (strncmp( pzText, zLoadCooked, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_COOKED; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLoadUncooked); - if (strncmp( pzText, zLoadUncooked, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_UNCOOKED; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLoadKeep); - if (strncmp( pzText, zLoadKeep, len ) == 0) { - if ( (pzText[len] == '>') - || (pzText[len] == '/') - || isspace((int)pzText[len])) { - *pMode = OPTION_LOAD_KEEP; - return pzText + len; - } - goto unknown; - } - } - - unknown: - return skipUnknown( pzText ); -} - - -/* parseSetMemType - * - * "pzText" points to the character after "members=" - * What should follow is a name of a "set membership". - * A collection of bit flags. - */ -static char* -parseSetMemType( - tOptions* pOpts, - char* pzText, - tOptionValue* pType ) -{ - return skipUnknown( pzText ); -} - - -/* parseValueType - * - * "pzText" points to the character after "type=" - */ -static char* -parseValueType( - char* pzText, - tOptionValue* pType ) -{ - { - size_t len = strlen(zLtypeString); - if (strncmp( pzText, zLtypeString, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_STRING; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLtypeInteger); - if (strncmp( pzText, zLtypeInteger, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_NUMERIC; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLtypeBool); - if (strncmp( pzText, zLtypeBool, len ) == 0) { - if ((pzText[len] == '>') || isspace(pzText[len])) { - pType->valType = OPARG_TYPE_BOOLEAN; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLtypeKeyword); - if (strncmp( pzText, zLtypeKeyword, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_ENUMERATION; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLtypeSetMembership); - if (strncmp( pzText, zLtypeSetMembership, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_MEMBERSHIP; - return pzText + len; - } - goto unknown; - } - } - - { - size_t len = strlen(zLtypeNest); - if (strncmp( pzText, zLtypeNest, len ) == 0) { - if ((pzText[len] == '>') || isspace((int)pzText[len])) { - pType->valType = OPARG_TYPE_HIERARCHY; - return pzText + len; - } - goto unknown; - } - } - - unknown: - pType->valType = OPARG_TYPE_NONE; - return skipUnknown( pzText ); -} - - -/* skipUnknown - * - * Skip over some unknown attribute - */ -static char* -skipUnknown( char* pzText ) -{ - for (;; pzText++) { - if (isspace( (int)*pzText )) return pzText; - switch (*pzText) { - case NUL: return NULL; - case '/': - case '>': return pzText; - } - } -} - - -/* validateOptionsStruct - * - * Make sure the option descriptor is there and that we understand it. - * This should be called from any user entry point where one needs to - * worry about validity. (Some entry points are free to assume that - * the call is not the first to the library and, thus, that this has - * already been called.) - */ -LOCAL tSuccess -validateOptionsStruct( tOptions* pOpts, char const* pzProgram ) -{ - if (pOpts == NULL) { - fputs( zAO_Bad, stderr ); - exit( EX_CONFIG ); - } - - /* - * IF the client has enabled translation and the translation procedure - * is available, then go do it. - */ - if ( ((pOpts->fOptSet & OPTPROC_TRANSLATE) != 0) - && (pOpts->pTransProc != 0) ) { - (*pOpts->pTransProc)(); - pOpts->fOptSet &= ~OPTPROC_TRANSLATE; - } - - /* - * IF the struct version is not the current, and also - * either too large (?!) or too small, - * THEN emit error message and fail-exit - */ - if ( ( pOpts->structVersion != OPTIONS_STRUCT_VERSION ) - && ( (pOpts->structVersion > OPTIONS_STRUCT_VERSION ) - || (pOpts->structVersion < OPTIONS_MINIMUM_VERSION ) - ) ) { - - fprintf( stderr, zAO_Err, pOpts->origArgVect[0], - NUM_TO_VER( pOpts->structVersion )); - if (pOpts->structVersion > OPTIONS_STRUCT_VERSION ) - fputs( zAO_Big, stderr ); - else - fputs( zAO_Sml, stderr ); - - return FAILURE; - } - - /* - * If the program name hasn't been set, then set the name and the path - * and the set of equivalent characters. - */ - if (pOpts->pzProgName == NULL) { - char const* pz = strrchr( pzProgram, DIRCH ); - - if (pz == NULL) - pOpts->pzProgName = pzProgram; - else pOpts->pzProgName = pz+1; - - pOpts->pzProgPath = pzProgram; - - /* - * when comparing long names, these are equivalent - */ - strequate( zSepChars ); - } - - return SUCCESS; -} - - -/** - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/configfile.c */ diff --git a/contrib/ntp/libopts/cook.c b/contrib/ntp/libopts/cook.c deleted file mode 100644 index bebd123fc..000000000 --- a/contrib/ntp/libopts/cook.c +++ /dev/null @@ -1,354 +0,0 @@ - -/* - * $Id: cook.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2006-09-24 15:21:02 bkorb" - * - * This file contains the routines that deal with processing quoted strings - * into an internal format. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -/* = = = END-STATIC-FORWARD = = = */ - -/*=export_func ao_string_cook_escape_char - * private: - * - * what: escape-process a string fragment - * arg: + char const* + pzScan + points to character after the escape + - * arg: + char* + pRes + Where to put the result byte + - * arg: + unsigned int + nl_ch + replacement char if scanned char is \n + - * - * ret-type: unsigned int - * ret-desc: The number of bytes consumed processing the escaped character. - * - * doc: - * - * This function converts "t" into "\t" and all your other favorite - * escapes, including numeric ones: hex and ocatal, too. - * The returned result tells the caller how far to advance the - * scan pointer (passed in). The default is to just pass through the - * escaped character and advance the scan by one. - * - * Some applications need to keep an escaped newline, others need to - * suppress it. This is accomplished by supplying a '\n' replacement - * character that is different from \n, if need be. For example, use - * 0x7F and never emit a 0x7F. - * - * err: @code{NULL} is returned if the string is mal-formed. -=*/ -unsigned int -ao_string_cook_escape_char( char const* pzIn, char* pRes, u_int nl ) -{ - unsigned int res = 1; - - switch (*pRes = *pzIn++) { - case NUL: /* NUL - end of input string */ - return 0; - case '\r': - if (*pzIn != '\n') - return 1; - res++; - /* FALLTHROUGH */ - case '\n': /* NL - emit newline */ - *pRes = (char)nl; - return res; - - case 'a': *pRes = '\a'; break; - case 'b': *pRes = '\b'; break; - case 'f': *pRes = '\f'; break; - case 'n': *pRes = '\n'; break; - case 'r': *pRes = '\r'; break; - case 't': *pRes = '\t'; break; - case 'v': *pRes = '\v'; break; - - case 'x': /* HEX Escape */ - if (isxdigit( (int)*pzIn )) { - unsigned int val; - unsigned char ch = *pzIn++; - - if ((ch >= 'A') && (ch <= 'F')) - val = 10 + (ch - 'A'); - else if ((ch >= 'a') && (ch <= 'f')) - val = 10 + (ch - 'a'); - else val = ch - '0'; - - ch = *pzIn; - - if (! isxdigit( ch )) { - *pRes = val; - res = 2; - break; - } - val <<= 4; - if ((ch >= 'A') && (ch <= 'F')) - val += 10 + (ch - 'A'); - else if ((ch >= 'a') && (ch <= 'f')) - val += 10 + (ch - 'a'); - else val += ch - '0'; - - res = 3; - *pRes = val; - } - break; - - default: - /* - * IF the character copied was an octal digit, - * THEN set the output character to an octal value - */ - if (isdigit( (int)*pRes ) && (*pRes < '8')) { - unsigned int val = *pRes - '0'; - unsigned char ch = *pzIn++; - - /* - * IF the second character is *not* an octal digit, - * THEN save the value and bail - */ - if ((ch < '0') || (ch > '7')) { - *pRes = val; - break; - } - - val = (val<<3) + (ch - '0'); - ch = *pzIn; - res = 2; - - /* - * IF the THIRD character is *not* an octal digit, - * THEN save the value and bail - */ - if ((ch < '0') || (ch > '7')) { - *pRes = val; - break; - } - - /* - * IF the new value would not be too large, - * THEN add on the third and last character value - */ - if ((val<<3) < 0xFF) { - val = (val<<3) + (ch - '0'); - res = 3; - } - - *pRes = val; - break; - } - } - - return res; -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * A quoted string has been found. - * Find the end of it and compress any escape sequences. - */ -/*=export_func ao_string_cook - * private: - * - * what: concatenate and escape-process strings - * arg: + char* + pzScan + The *MODIFIABLE* input buffer + - * arg: + int* + pLineCt + The (possibly NULL) pointer to a line count + - * - * ret-type: char* - * ret-desc: The address of the text following the processed strings. - * The return value is NULL if the strings are ill-formed. - * - * doc: - * - * A series of one or more quoted strings are concatenated together. - * If they are quoted with double quotes (@code{"}), then backslash - * escapes are processed per the C programming language. If they are - * single quote strings, then the backslashes are honored only when they - * precede another backslash or a single quote character. - * - * err: @code{NULL} is returned if the string(s) is/are mal-formed. -=*/ -char* -ao_string_cook( char* pzScan, int* pLineCt ) -{ - int l = 0; - char q = *pzScan; - - /* - * It is a quoted string. Process the escape sequence characters - * (in the set "abfnrtv") and make sure we find a closing quote. - */ - char* pzD = pzScan++; - char* pzS = pzScan; - - if (pLineCt == NULL) - pLineCt = &l; - - for (;;) { - /* - * IF the next character is the quote character, THEN we may end the - * string. We end it unless the next non-blank character *after* the - * string happens to also be a quote. If it is, then we will change - * our quote character to the new quote character and continue - * condensing text. - */ - while (*pzS == q) { - *pzD = NUL; /* This is probably the end of the line */ - pzS++; - - scan_for_quote: - while (isspace((int)*pzS)) - if (*(pzS++) == '\n') - (*pLineCt)++; - - /* - * IF the next character is a quote character, - * THEN we will concatenate the strings. - */ - switch (*pzS) { - case '"': - case '\'': - break; - - case '/': - /* - * Allow for a comment embedded in the concatenated string. - */ - switch (pzS[1]) { - default: return NULL; - case '/': - /* - * Skip to end of line - */ - pzS = strchr( pzS, '\n' ); - if (pzS == NULL) - return NULL; - (*pLineCt)++; - break; - - case '*': - { - char* p = strstr( pzS+2, "*/" ); - /* - * Skip to terminating star slash - */ - if (p == NULL) - return NULL; - while (pzS < p) { - if (*(pzS++) == '\n') - (*pLineCt)++; - } - - pzS = p + 2; - } - } - goto scan_for_quote; - - default: - /* - * The next non-whitespace character is not a quote. - * The series of quoted strings has come to an end. - */ - return pzS; - } - - q = *(pzS++); /* assign new quote character and advance scan */ - } - - /* - * We are inside a quoted string. Copy text. - */ - switch (*(pzD++) = *(pzS++)) { - case NUL: - return NULL; - - case '\n': - (*pLineCt)++; - break; - - case '\\': - /* - * IF we are escaping a new line, - * THEN drop both the escape and the newline from - * the result string. - */ - if (*pzS == '\n') { - pzS++; - pzD--; - (*pLineCt)++; - } - - /* - * ELSE IF the quote character is '"' or '`', - * THEN we do the full escape character processing - */ - else if (q != '\'') { - int ct = ao_string_cook_escape_char( pzS, pzD-1, (u_int)'\n' ); - if (ct == 0) - return NULL; - - pzS += ct; - } /* if (q != '\'') */ - - /* - * OTHERWISE, we only process "\\", "\'" and "\#" sequences. - * The latter only to easily hide preprocessing directives. - */ - else switch (*pzS) { - case '\\': - case '\'': - case '#': - pzD[-1] = *pzS++; - } - } /* switch (*(pzD++) = *(pzS++)) */ - } /* for (;;) */ -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/cook.c */ diff --git a/contrib/ntp/libopts/enumeration.c b/contrib/ntp/libopts/enumeration.c deleted file mode 100644 index 67dd4f47e..000000000 --- a/contrib/ntp/libopts/enumeration.c +++ /dev/null @@ -1,498 +0,0 @@ - -/* - * $Id: enumeration.c,v 4.17 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:22:35 bkorb" - * - * Automated Options Paged Usage module. - * - * This routine will run run-on options through a pager so the - * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -tSCC* pz_enum_err_fmt; - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -enumError( - tOptions* pOpts, - tOptDesc* pOD, - tCC* const * paz_names, - int name_ct ); - -static uintptr_t -findName( - tCC* pzName, - tOptions* pOpts, - tOptDesc* pOD, - tCC* const * paz_names, - unsigned int name_ct ); -/* = = = END-STATIC-FORWARD = = = */ - -static void -enumError( - tOptions* pOpts, - tOptDesc* pOD, - tCC* const * paz_names, - int name_ct ) -{ - size_t max_len = 0; - size_t ttl_len = 0; - - if (pOpts != NULL) - fprintf( option_usage_fp, pz_enum_err_fmt, pOpts->pzProgName, - pOD->optArg.argString, pOD->pz_Name ); - - fprintf( option_usage_fp, zValidKeys, pOD->pz_Name ); - - if (**paz_names == 0x7F) { - paz_names++; - name_ct--; - } - - /* - * Figure out the maximum length of any name, plus the total length - * of all the names. - */ - { - tCC * const * paz = paz_names; - int ct = name_ct; - - do { - size_t len = strlen( *(paz++) ) + 1; - if (len > max_len) - max_len = len; - ttl_len += len; - } while (--ct > 0); - } - - /* - * IF any one entry is about 1/2 line or longer, print one per line - */ - if (max_len > 35) { - do { - fprintf( option_usage_fp, " %s\n", *(paz_names++) ); - } while (--name_ct > 0); - } - - /* - * ELSE IF they all fit on one line, then do so. - */ - else if (ttl_len < 76) { - fputc( ' ', option_usage_fp ); - do { - fputc( ' ', option_usage_fp ); - fputs( *(paz_names++), option_usage_fp ); - } while (--name_ct > 0); - fputc( '\n', option_usage_fp ); - } - - /* - * Otherwise, columnize the output - */ - else { - int ent_no = 0; - char zFmt[16]; /* format for all-but-last entries on a line */ - - sprintf( zFmt, "%%-%ds", (int)max_len ); - max_len = 78 / max_len; /* max_len is now max entries on a line */ - fputs( " ", option_usage_fp ); - - /* - * Loop through all but the last entry - */ - while (--name_ct > 0) { - if (++ent_no == max_len) { - /* - * Last entry on a line. Start next line, too. - */ - fprintf( option_usage_fp, "%s\n ", *(paz_names++) ); - ent_no = 0; - } - - else - fprintf( option_usage_fp, zFmt, *(paz_names++) ); - } - fprintf( option_usage_fp, "%s\n", *paz_names ); - } - - /* - * IF we do not have a pOpts pointer, then this output is being requested - * by the usage procedure. Let's not re-invoke it recursively. - */ - if (pOpts != NULL) - (*(pOpts->pUsageProc))( pOpts, EXIT_FAILURE ); - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_MEMBERSHIP) - fputs( zSetMemberSettings, option_usage_fp ); -} - - -static uintptr_t -findName( - tCC* pzName, - tOptions* pOpts, - tOptDesc* pOD, - tCC* const * paz_names, - unsigned int name_ct ) -{ - uintptr_t res = name_ct; - size_t len = strlen( (char*)pzName ); - uintptr_t idx; - /* - * Look for an exact match, but remember any partial matches. - * Multiple partial matches means we have an ambiguous match. - */ - for (idx = 0; idx < name_ct; idx++) { - if (strncmp( (char*)paz_names[idx], (char*)pzName, len) == 0) { - if (paz_names[idx][len] == NUL) - return idx; /* full match */ - - if (res != name_ct) { - pz_enum_err_fmt = zAmbigKey; - option_usage_fp = stderr; - enumError( pOpts, pOD, paz_names, (int)name_ct ); - } - res = idx; /* save partial match */ - } - } - - /* - * no partial match -> error - */ - if (res == name_ct) { - pz_enum_err_fmt = zNoKey; - option_usage_fp = stderr; - enumError( pOpts, pOD, paz_names, (int)name_ct ); - } - - /* - * Return the matching index as a char* pointer. - * The result gets stashed in a char* pointer, so it will have to fit. - */ - return res; -} - - -/*=export_func optionKeywordName - * what: Convert between enumeration values and strings - * private: - * - * arg: tOptDesc*, pOD, enumeration option description - * arg: unsigned int, enum_val, the enumeration value to map - * - * ret_type: char const* - * ret_desc: the enumeration name from const memory - * - * doc: This converts an enumeration value into the matching string. -=*/ -char const* -optionKeywordName( - tOptDesc* pOD, - unsigned int enum_val ) -{ - tOptDesc od; - - od.optArg.argEnum = enum_val; - (*(pOD->pOptProc))( (void*)(2UL), &od ); - return od.optArg.argString; -} - - -/*=export_func optionEnumerationVal - * what: Convert from a string to an enumeration value - * private: - * - * arg: tOptions*, pOpts, the program options descriptor - * arg: tOptDesc*, pOD, enumeration option description - * arg: char const * const *, paz_names, list of enumeration names - * arg: unsigned int, name_ct, number of names in list - * - * ret_type: uintptr_t - * ret_desc: the enumeration value - * - * doc: This converts the optArg.argString string from the option description - * into the index corresponding to an entry in the name list. - * This will match the generated enumeration value. - * Full matches are always accepted. Partial matches are accepted - * if there is only one partial match. -=*/ -uintptr_t -optionEnumerationVal( - tOptions* pOpts, - tOptDesc* pOD, - tCC * const * paz_names, - unsigned int name_ct ) -{ - uintptr_t res = 0UL; - - /* - * IF the program option descriptor pointer is invalid, - * then it is some sort of special request. - */ - switch ((uintptr_t)pOpts) { - case 0UL: - /* - * print the list of enumeration names. - */ - enumError( pOpts, pOD, paz_names, (int)name_ct ); - break; - - case 1UL: - { - unsigned int ix = pOD->optArg.argEnum; - /* - * print the name string. - */ - if (ix >= name_ct) - printf( "INVALID-%d", ix ); - else - fputs( paz_names[ ix ], stdout ); - - break; - } - - case 2UL: - { - tSCC zInval[] = "*INVALID*"; - unsigned int ix = pOD->optArg.argEnum; - /* - * Replace the enumeration value with the name string. - */ - if (ix >= name_ct) - return (uintptr_t)zInval; - - res = (uintptr_t)paz_names[ ix ]; - break; - } - - default: - res = findName( pOD->optArg.argString, pOpts, pOD, paz_names, name_ct ); - - if (pOD->fOptState & OPTST_ALLOC_ARG) { - AGFREE(pOD->optArg.argString); - pOD->fOptState &= ~OPTST_ALLOC_ARG; - pOD->optArg.argString = NULL; - } - } - - return res; -} - - -/*=export_func optionSetMembers - * what: Convert between bit flag values and strings - * private: - * - * arg: tOptions*, pOpts, the program options descriptor - * arg: tOptDesc*, pOD, enumeration option description - * arg: char const * const *, - * paz_names, list of enumeration names - * arg: unsigned int, name_ct, number of names in list - * - * doc: This converts the optArg.argString string from the option description - * into the index corresponding to an entry in the name list. - * This will match the generated enumeration value. - * Full matches are always accepted. Partial matches are accepted - * if there is only one partial match. -=*/ -void -optionSetMembers( - tOptions* pOpts, - tOptDesc* pOD, - tCC* const * paz_names, - unsigned int name_ct ) -{ - /* - * IF the program option descriptor pointer is invalid, - * then it is some sort of special request. - */ - switch ((uintptr_t)pOpts) { - case 0UL: - /* - * print the list of enumeration names. - */ - enumError( pOpts, pOD, paz_names, (int)name_ct ); - return; - - case 1UL: - { - /* - * print the name string. - */ - uintptr_t bits = (uintptr_t)pOD->optCookie; - uintptr_t res = 0; - size_t len = 0; - - while (bits != 0) { - if (bits & 1) { - if (len++ > 0) fputs( " | ", stdout ); - fputs( paz_names[ res ], stdout ); - } - if (++res >= name_ct) break; - bits >>= 1; - } - return; - } - - case 2UL: - { - char* pz; - uintptr_t bits = (uintptr_t)pOD->optCookie; - uintptr_t res = 0; - size_t len = 0; - - /* - * Replace the enumeration value with the name string. - * First, determine the needed length, then allocate and fill in. - */ - while (bits != 0) { - if (bits & 1) - len += strlen( paz_names[ res ]) + 8; - if (++res >= name_ct) break; - bits >>= 1; - } - - pOD->optArg.argString = pz = AGALOC( len, "enum name" ); - - /* - * Start by clearing all the bits. We want to turn off any defaults - * because we will be restoring to current state, not adding to - * the default set of bits. - */ - strcpy( pz, "none" ); - pz += 4; - bits = (uintptr_t)pOD->optCookie; - res = 0; - while (bits != 0) { - if (bits & 1) { - strcpy( pz, " + " ); - strcpy( pz+3, paz_names[ res ]); - pz += strlen( paz_names[ res ]) + 3; - } - if (++res >= name_ct) break; - bits >>= 1; - } - return; - } - - default: - break; - } - - { - tCC* pzArg = pOD->optArg.argString; - uintptr_t res; - if ((pzArg == NULL) || (*pzArg == NUL)) { - pOD->optCookie = (void*)0; - return; - } - - res = (uintptr_t)pOD->optCookie; - for (;;) { - tSCC zSpn[] = " ,|+\t\r\f\n"; - int iv, len; - - pzArg += strspn( pzArg, zSpn ); - iv = (*pzArg == '!'); - if (iv) - pzArg += strspn( pzArg+1, zSpn ) + 1; - - len = strcspn( pzArg, zSpn ); - if (len == 0) - break; - - if ((len == 3) && (strncmp(pzArg, zAll, (size_t)3) == 0)) { - if (iv) - res = 0; - else res = ~0UL; - } - else if ((len == 4) && (strncmp(pzArg, zNone, (size_t)4) == 0)) { - if (! iv) - res = 0; - } - else do { - char* pz; - uintptr_t bit = strtoul( pzArg, &pz, 0 ); - - if (pz != pzArg + len) { - char z[ AO_NAME_SIZE ]; - tCC* p; - if (*pz != NUL) { - if (len >= AO_NAME_LIMIT) - break; - strncpy( z, pzArg, (size_t)len ); - z[len] = NUL; - p = z; - } else { - p = pzArg; - } - - bit = 1UL << findName(p, pOpts, pOD, paz_names, name_ct); - } - if (iv) - res &= ~bit; - else res |= bit; - } while (0); - - if (pzArg[len] == NUL) - break; - pzArg += len + 1; - } - if (name_ct < (8 * sizeof( uintptr_t ))) { - res &= (1UL << name_ct) - 1UL; - } - - pOD->optCookie = (void*)res; - } -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/enumeration.c */ diff --git a/contrib/ntp/libopts/environment.c b/contrib/ntp/libopts/environment.c deleted file mode 100644 index 9fb155011..000000000 --- a/contrib/ntp/libopts/environment.c +++ /dev/null @@ -1,279 +0,0 @@ - -/* - * $Id: environment.c,v 4.13 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:50:35 bkorb" - * - * This file contains all of the routines that must be linked into - * an executable to use the generated option processing. The optional - * routines are in separately compiled modules so that they will not - * necessarily be linked in. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -checkEnvOpt(tOptState * os, char * env_name, - tOptions* pOpts, teEnvPresetType type); -/* = = = END-STATIC-FORWARD = = = */ - -/* - * doPrognameEnv - check for preset values from the ${PROGNAME} - * environment variable. This is accomplished by parsing the text into - * tokens, temporarily replacing the arg vector and calling - * doImmediateOpts and/or doRegularOpts. - */ -LOCAL void -doPrognameEnv( tOptions* pOpts, teEnvPresetType type ) -{ - char const* pczOptStr = getenv( pOpts->pzPROGNAME ); - token_list_t* pTL; - int sv_argc; - tAoUI sv_flag; - char** sv_argv; - - /* - * IF there is no such environment variable - * *or* there is, but we are doing immediate opts and there are - * no immediate opts to do (--help inside $PROGNAME is silly, - * but --no-load-defs is not, so that is marked) - * THEN bail out now. ( - */ - if ( (pczOptStr == NULL) - || ( (type == ENV_IMM) - && ((pOpts->fOptSet & OPTPROC_HAS_IMMED) == 0) ) ) - return; - - /* - * Tokenize the string. If there's nothing of interest, we'll bail - * here immediately. - */ - pTL = ao_string_tokenize( pczOptStr ); - if (pTL == NULL) - return; - - /* - * Substitute our $PROGNAME argument list for the real one - */ - sv_argc = pOpts->origArgCt; - sv_argv = pOpts->origArgVect; - sv_flag = pOpts->fOptSet; - - /* - * We add a bogus pointer to the start of the list. The program name - * has already been pulled from "argv", so it won't get dereferenced. - * The option scanning code will skip the "program name" at the start - * of this list of tokens, so we accommodate this way .... - */ - pOpts->origArgVect = (char**)(pTL->tkn_list - 1); - pOpts->origArgCt = pTL->tkn_ct + 1; - pOpts->fOptSet &= ~OPTPROC_ERRSTOP; - - pOpts->curOptIdx = 1; - pOpts->pzCurOpt = NULL; - - switch (type) { - case ENV_IMM: - /* - * We know the OPTPROC_HAS_IMMED bit is set. - */ - (void)doImmediateOpts( pOpts ); - break; - - case ENV_NON_IMM: - (void)doRegularOpts( pOpts ); - break; - - default: - /* - * Only to immediate opts if the OPTPROC_HAS_IMMED bit is set. - */ - if (pOpts->fOptSet & OPTPROC_HAS_IMMED) { - (void)doImmediateOpts( pOpts ); - pOpts->curOptIdx = 1; - pOpts->pzCurOpt = NULL; - } - (void)doRegularOpts( pOpts ); - break; - } - - /* - * Free up the temporary arg vector and restore the original program args. - */ - free( pTL ); - pOpts->origArgVect = sv_argv; - pOpts->origArgCt = sv_argc; - pOpts->fOptSet = sv_flag; -} - -static void -checkEnvOpt(tOptState * os, char * env_name, - tOptions* pOpts, teEnvPresetType type) -{ - os->pzOptArg = getenv( env_name ); - if (os->pzOptArg == NULL) - return; - - os->flags = OPTST_PRESET | OPTST_ALLOC_ARG | os->pOD->fOptState; - os->optType = TOPT_UNDEFINED; - - if ( (os->pOD->pz_DisablePfx != NULL) - && (streqvcmp( os->pzOptArg, os->pOD->pz_DisablePfx ) == 0)) { - os->flags |= OPTST_DISABLED; - os->pzOptArg = NULL; - } - - switch (type) { - case ENV_IMM: - /* - * Process only immediate actions - */ - if (DO_IMMEDIATELY(os->flags)) - break; - return; - - case ENV_NON_IMM: - /* - * Process only NON immediate actions - */ - if (DO_NORMALLY(os->flags) || DO_SECOND_TIME(os->flags)) - break; - return; - - default: /* process everything */ - break; - } - - /* - * Make sure the option value string is persistent and consistent. - * - * The interpretation of the option value depends - * on the type of value argument the option takes - */ - if (os->pzOptArg != NULL) { - if (OPTST_GET_ARGTYPE(os->pOD->fOptState) == OPARG_TYPE_NONE) { - os->pzOptArg = NULL; - } else if ( (os->pOD->fOptState & OPTST_ARG_OPTIONAL) - && (*os->pzOptArg == NUL)) { - os->pzOptArg = NULL; - } else if (*os->pzOptArg == NUL) { - os->pzOptArg = zNil; - } else { - AGDUPSTR( os->pzOptArg, os->pzOptArg, "option argument" ); - os->flags |= OPTST_ALLOC_ARG; - } - } - - handleOption( pOpts, os ); -} - -/* - * doEnvPresets - check for preset values from the envrionment - * This routine should process in all, immediate or normal modes.... - */ -LOCAL void -doEnvPresets( tOptions* pOpts, teEnvPresetType type ) -{ - int ct; - tOptState st; - char* pzFlagName; - size_t spaceLeft; - char zEnvName[ AO_NAME_SIZE ]; - - /* - * Finally, see if we are to look at the environment - * variables for initial values. - */ - if ((pOpts->fOptSet & OPTPROC_ENVIRON) == 0) - return; - - doPrognameEnv( pOpts, type ); - - ct = pOpts->presetOptCt; - st.pOD = pOpts->pOptDesc; - - pzFlagName = zEnvName - + snprintf( zEnvName, sizeof( zEnvName ), "%s_", pOpts->pzPROGNAME ); - spaceLeft = AO_NAME_SIZE - (pzFlagName - zEnvName) - 1; - - for (;ct-- > 0; st.pOD++) { - /* - * If presetting is disallowed, then skip this entry - */ - if ( ((st.pOD->fOptState & OPTST_NO_INIT) != 0) - || (st.pOD->optEquivIndex != NO_EQUIVALENT) ) - continue; - - /* - * IF there is no such environment variable, - * THEN skip this entry, too. - */ - if (strlen( st.pOD->pz_NAME ) >= spaceLeft) - continue; - - /* - * Set up the option state - */ - strcpy( pzFlagName, st.pOD->pz_NAME ); - checkEnvOpt(&st, zEnvName, pOpts, type); - } - - /* - * Special handling for ${PROGNAME_LOAD_OPTS} - */ - if (pOpts->specOptIdx.save_opts != 0) { - st.pOD = pOpts->pOptDesc + pOpts->specOptIdx.save_opts + 1; - strcpy( pzFlagName, st.pOD->pz_NAME ); - checkEnvOpt(&st, zEnvName, pOpts, type); - } -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/environment.c */ diff --git a/contrib/ntp/libopts/genshell.c b/contrib/ntp/libopts/genshell.c deleted file mode 100644 index de098a565..000000000 --- a/contrib/ntp/libopts/genshell.c +++ /dev/null @@ -1,354 +0,0 @@ -/* -*- buffer-read-only: t -*- vi: set ro: - * - * DO NOT EDIT THIS FILE (genshell.c) - * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:35 PM PDT - * From the definitions genshell.def - * and the template file options - * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This source file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * genshellopt author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. - * - * This source file is copyrighted and licensed under the following terms: - * - * genshellopt copyright 1999-2007 Bruce Korb - all rights reserved - * - * genshellopt is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * genshellopt is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with genshellopt. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. - */ - - -#include - -#define OPTION_CODE_COMPILE 1 -#include "genshell.h" - -#ifdef __cplusplus -extern "C" { -#endif -tSCC zCopyright[] = - "genshellopt copyright (c) 1999-2007 Bruce Korb, all rights reserved"; -tSCC zCopyrightNotice[] = - "genshellopt is free software; you can redistribute it and/or\n\ -modify it under the terms of the GNU Lesser General Public\n\ -License as published by the Free Software Foundation; either\n\ -version 2.1 of the License, or (at your option) any later version.\n\n\ -genshellopt is distributed in the hope that it will be useful,\n\ -but WITHOUT ANY WARRANTY; without even the implied warranty of\n\ -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\n\ -Lesser General Public License for more details.\n\n\ -You should have received a copy of the GNU Lesser General Public\n\ -License along with genshellopt. If not, write to:\n\ -\tThe Free Software Foundation, Inc.,\n\ -\t51 Franklin Street, Fifth Floor\n\ -\tBoston, MA 02110-1301, USA."; -extern tUsageProc genshelloptUsage; - -#ifndef NULL -# define NULL 0 -#endif -#ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -#endif -#ifndef EXIT_FAILURE -# define EXIT_FAILURE 1 -#endif -/* - * Script option description: - */ -tSCC zScriptText[] = - "Output Script File"; -tSCC zScript_NAME[] = "SCRIPT"; -tSCC zScript_Name[] = "script"; -#define SCRIPT_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Shell option description: - */ -tSCC zShellText[] = - "Shell name (follows \"#!\" magic)"; -tSCC zShell_NAME[] = "SHELL"; -tSCC zNotShell_Name[] = "no-shell"; -tSCC zNotShell_Pfx[] = "no"; -#define zShell_Name (zNotShell_Name + 3) -#define SHELL_FLAGS (OPTST_INITENABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Help/More_Help/Version option descriptions: - */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; -/* - * Declare option callback procedures - */ -extern tOptProc - optionPagedUsage, optionPrintVersion; -static tOptProc - doUsageOpt; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Genshellopt Option Descriptions. - */ -static tOptDesc optDesc[ OPTION_CT ] = { - { /* entry idx, value */ 0, VALUE_OPT_SCRIPT, - /* equiv idx, value */ 0, VALUE_OPT_SCRIPT, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SCRIPT_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zScriptText, zScript_NAME, zScript_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 1, VALUE_OPT_SHELL, - /* equiv idx, value */ 1, VALUE_OPT_SHELL, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SHELL_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zShellText, zShell_NAME, zShell_Name, - /* disablement strs */ zNotShell_Name, zNotShell_Pfx }, - -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionPrintVersion, - /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, - /* disablement strs */ NULL, NULL }, - -#undef VERSION_OPT_FLAGS - - - { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ doUsageOpt, - /* desc, NAME, name */ zHelpText, NULL, zHelp_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionPagedUsage, - /* desc, NAME, name */ zMore_HelpText, NULL, zMore_Help_Name, - /* disablement strs */ NULL, NULL } -}; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Genshellopt Option Environment - */ -tSCC zPROGNAME[] = "GENSHELLOPT"; -tSCC zUsageTitle[] = -"genshellopt - Generate Shell Option Processing Script - Ver. 1\n\ -USAGE: %s [ - [] | --[{=| }] ]...\n"; -#define zRcName NULL -#define apzHomeList NULL - -tSCC zBugsAddr[] = "autogen-users@lists.sourceforge.net"; -tSCC zExplain[] = "\n\ -Note that `shell' is only useful if the output file does not already\n\ -exist. If it does, then the shell name and optional first argument\n\ -will be extracted from the script file.\n"; -tSCC zDetail[] = "\n\ -If the script file already exists and contains Automated Option Processing\n\ -text, the second line of the file through the ending tag will be replaced\n\ -by the newly generated text. The first `#!' line will be regenerated.\n"; -tSCC zFullVersion[] = GENSHELLOPT_FULL_VERSION; -/* extracted from optcode.tpl near line 408 */ - -#if defined(ENABLE_NLS) -# define OPTPROC_BASE OPTPROC_TRANSLATE - static tOptionXlateProc translate_option_strings; -#else -# define OPTPROC_BASE OPTPROC_NONE -# define translate_option_strings NULL -#endif /* ENABLE_NLS */ - -tOptions genshelloptOptions = { - OPTIONS_STRUCT_VERSION, - 0, NULL, /* original argc + argv */ - ( OPTPROC_BASE - + OPTPROC_ERRSTOP - + OPTPROC_SHORTOPT - + OPTPROC_LONGOPT - + OPTPROC_NO_REQ_OPT - + OPTPROC_NEGATIONS - + OPTPROC_NO_ARGS ), - 0, NULL, /* current option index, current option */ - NULL, NULL, zPROGNAME, - zRcName, zCopyright, zCopyrightNotice, - zFullVersion, apzHomeList, zUsageTitle, - zExplain, zDetail, optDesc, - zBugsAddr, /* address to send bugs to */ - NULL, NULL, /* extensions/saved state */ - genshelloptUsage, /* usage procedure */ - translate_option_strings, /* translation procedure */ - /* - * Indexes to special options - */ - { INDEX_OPT_MORE_HELP, - 0 /* no option state saving */, - NO_EQUIVALENT /* index of '-#' option */, - NO_EQUIVALENT /* index of default opt */ - }, - 5 /* full option count */, 2 /* user option count */ -}; - -/* - * Create the static procedure(s) declared above. - */ -static void -doUsageOpt( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - USAGE( EXIT_SUCCESS ); -} -/* extracted from optcode.tpl near line 514 */ - -#if ENABLE_NLS -#include -#include -#include -#include -#include - -static char* AO_gettext( char const* pz ); -static void coerce_it(void** s); - -static char* -AO_gettext( char const* pz ) -{ - char* pzRes; - if (pz == NULL) - return NULL; - pzRes = _(pz); - if (pzRes == pz) - return pzRes; - pzRes = strdup( pzRes ); - if (pzRes == NULL) { - fputs( _("No memory for duping translated strings\n"), stderr ); - exit( EXIT_FAILURE ); - } - return pzRes; -} - -static void coerce_it(void** s) { *s = AO_gettext(*s); } -#define COERSION(_f) \ - coerce_it((void*)&(genshelloptOptions._f)) - -/* - * This invokes the translation code (e.g. gettext(3)). - */ -static void -translate_option_strings( void ) -{ - /* - * Guard against re-translation. It won't work. The strings will have - * been changed by the first pass through this code. One shot only. - */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; - - do { - ppz++; - *ppz = AO_gettext(*ppz); - } while (--ix > 0); - } - option_usage_text.field_ct = 0; - - { - tOptDesc* pOD = genshelloptOptions.pOptDesc; - int ix = genshelloptOptions.optCt; - - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; - } - } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); -} - -#endif /* ENABLE_NLS */ - -#ifdef __cplusplus -} -#endif -/* genshell.c ends here */ diff --git a/contrib/ntp/libopts/genshell.h b/contrib/ntp/libopts/genshell.h deleted file mode 100644 index b57677dce..000000000 --- a/contrib/ntp/libopts/genshell.h +++ /dev/null @@ -1,149 +0,0 @@ -/* -*- buffer-read-only: t -*- vi: set ro: - * - * DO NOT EDIT THIS FILE (genshell.h) - * - * It has been AutoGen-ed Saturday May 5, 2007 at 12:02:35 PM PDT - * From the definitions genshell.def - * and the template file options - * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This header file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * genshellopt author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. - * - * This source file is copyrighted and licensed under the following terms: - * - * genshellopt copyright 1999-2007 Bruce Korb - all rights reserved - * - * genshellopt is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * genshellopt is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with genshellopt. If not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor - * Boston, MA 02110-1301, USA. - */ -/* - * This file contains the programmatic interface to the Automated - * Options generated for the genshellopt program. - * These macros are documented in the AutoGen info file in the - * "AutoOpts" chapter. Please refer to that doc for usage help. - */ -#ifndef AUTOOPTS_GENSHELL_H_GUARD -#define AUTOOPTS_GENSHELL_H_GUARD -#include - -/* - * Ensure that the library used for compiling this generated header is at - * least as new as the version current when the header template was released - * (not counting patch version increments). Also ensure that the oldest - * tolerable version is at least as old as what was current when the header - * template was released. - */ -#define AO_TEMPLATE_VERSION 118784 -#if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ - || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) -# error option template version mismatches autoopts/options.h header - Choke Me. -#endif - -/* - * Enumeration of each option: - */ -typedef enum { - INDEX_OPT_SCRIPT = 0, - INDEX_OPT_SHELL = 1, - INDEX_OPT_VERSION = 2, - INDEX_OPT_HELP = 3, - INDEX_OPT_MORE_HELP = 4 -} teOptIndex; - -#define OPTION_CT 5 -#define GENSHELLOPT_VERSION "1" -#define GENSHELLOPT_FULL_VERSION "genshellopt - Generate Shell Option Processing Script - Ver. 1" - -/* - * Interface defines for all options. Replace "n" with the UPPER_CASED - * option name (as in the teOptIndex enumeration above). - * e.g. HAVE_OPT( SCRIPT ) - */ -#define DESC(n) (genshelloptOptions.pOptDesc[INDEX_OPT_## n]) -#define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) -#define OPT_ARG(n) (DESC(n).optArg.argString) -#define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) -#define COUNT_OPT(n) (DESC(n).optOccCt) -#define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) -#define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) -#define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) -#define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) -#define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) -#define CLEAR_OPT(n) STMTS( \ - DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ - if ( (DESC(n).fOptState & OPTST_INITENABLED) == 0) \ - DESC(n).fOptState |= OPTST_DISABLED; \ - DESC(n).optCookie = NULL ) - -/* - * Interface defines for specific options. - */ -#define VALUE_OPT_SCRIPT 'o' -#define VALUE_OPT_SHELL 's' - -#define VALUE_OPT_VERSION 'v' -#define VALUE_OPT_HELP '?' -#define VALUE_OPT_MORE_HELP '!' -/* - * Interface defines not associated with particular options - */ -#define ERRSKIP_OPTERR STMTS( genshelloptOptions.fOptSet &= ~OPTPROC_ERRSTOP ) -#define ERRSTOP_OPTERR STMTS( genshelloptOptions.fOptSet |= OPTPROC_ERRSTOP ) -#define RESTART_OPT(n) STMTS( \ - genshelloptOptions.curOptIdx = (n); \ - genshelloptOptions.pzCurOpt = NULL ) -#define START_OPT RESTART_OPT(1) -#define USAGE(c) (*genshelloptOptions.pUsageProc)( &genshelloptOptions, c ) -/* extracted from opthead.tpl near line 360 */ - -/* * * * * * - * - * Declare the genshellopt option descriptor. - */ -#ifdef __cplusplus -extern "C" { -#endif - -extern tOptions genshelloptOptions; - -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif - -#ifdef __cplusplus -} -#endif -#endif /* AUTOOPTS_GENSHELL_H_GUARD */ -/* genshell.h ends here */ diff --git a/contrib/ntp/libopts/libopts.c b/contrib/ntp/libopts/libopts.c deleted file mode 100644 index feb7557dc..000000000 --- a/contrib/ntp/libopts/libopts.c +++ /dev/null @@ -1,30 +0,0 @@ -#define AUTOOPTS_INTERNAL -#include "compat/compat.h" -#define LOCAL static -#include "autoopts/options.h" -#include "autoopts/usage-txt.h" -#include "genshell.h" -#include "autoopts.h" -#include "proto.h" -#include "autoopts.c" -#include "boolean.c" -#include "configfile.c" -#include "cook.c" -#include "enumeration.c" -#include "environment.c" -#include "genshell.c" -#include "load.c" -#include "makeshell.c" -#include "nested.c" -#include "numeric.c" -#include "pgusage.c" -#include "putshell.c" -#include "restore.c" -#include "save.c" -#include "sort.c" -#include "stack.c" -#include "streqvcmp.c" -#include "text_mmap.c" -#include "tokenize.c" -#include "usage.c" -#include "version.c" diff --git a/contrib/ntp/libopts/load.c b/contrib/ntp/libopts/load.c deleted file mode 100644 index eeeb125cc..000000000 --- a/contrib/ntp/libopts/load.c +++ /dev/null @@ -1,563 +0,0 @@ - -/* - * $Id: load.c,v 4.20 2007/02/04 22:17:39 bkorb Exp $ - * Time-stamp: "2007-02-04 11:54:57 bkorb" - * - * This file contains the routines that deal with processing text strings - * for options, either from a NUL-terminated string passed in or from an - * rc/ini file. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -tOptionLoadMode option_load_mode = OPTION_LOAD_UNCOOKED; - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static ag_bool -insertProgramPath( - char* pzBuf, - int bufSize, - tCC* pzName, - tCC* pzProgPath ); - -static ag_bool -insertEnvVal( - char* pzBuf, - int bufSize, - tCC* pzName, - tCC* pzProgPath ); - -static char* -assembleArgValue( char* pzTxt, tOptionLoadMode mode ); -/* = = = END-STATIC-FORWARD = = = */ - -/*=export_func optionMakePath - * private: - * - * what: translate and construct a path - * arg: + char* + pzBuf + The result buffer + - * arg: + int + bufSize + The size of this buffer + - * arg: + char const* + pzName + The input name + - * arg: + char const* + pzProgPath + The full path of the current program + - * - * ret-type: ag_bool - * ret-desc: AG_TRUE if the name was handled, otherwise AG_FALSE. - * If the name does not start with ``$'', then it is handled - * simply by copying the input name to the output buffer and - * resolving the name with either @code{canonicalize_file_name(3GLIBC)} - * or @code{realpath(3C)}. - * - * doc: - * - * This routine will copy the @code{pzName} input name into the @code{pzBuf} - * output buffer, carefully not exceeding @code{bufSize} bytes. If the - * first character of the input name is a @code{'$'} character, then there - * is special handling: - * @* - * @code{$$} is replaced with the directory name of the @code{pzProgPath}, - * searching @code{$PATH} if necessary. - * @* - * @code{$@} is replaced with the AutoGen package data installation directory - * (aka @code{pkgdatadir}). - * @* - * @code{$NAME} is replaced by the contents of the @code{NAME} environment - * variable. If not found, the search fails. - * - * Please note: both @code{$$} and @code{$NAME} must be at the start of the - * @code{pzName} string and must either be the entire string or be followed - * by the @code{'/'} (backslash on windows) character. - * - * err: @code{AG_FALSE} is returned if: - * @* - * @bullet{} The input name exceeds @code{bufSize} bytes. - * @* - * @bullet{} @code{$$}, @code{$@@} or @code{$NAME} is not the full string - * and the next character is not '/'. - * @* - * @bullet{} libopts was built without PKGDATADIR defined and @code{$@@} - * was specified. - * @* - * @bullet{} @code{NAME} is not a known environment variable - * @* - * @bullet{} @code{canonicalize_file_name} or @code{realpath} return - * errors (cannot resolve the resulting path). -=*/ -ag_bool -optionMakePath( - char* pzBuf, - int bufSize, - tCC* pzName, - tCC* pzProgPath ) -{ - size_t name_len = strlen( pzName ); - -# ifndef PKGDATADIR -# define PKGDATADIR "" -# endif - - tSCC pkgdatadir[] = PKGDATADIR; - - ag_bool res = AG_TRUE; - - if (bufSize <= name_len) - return AG_FALSE; - - /* - * IF not an environment variable, just copy the data - */ - if (*pzName != '$') { - tCC* pzS = pzName; - char* pzD = pzBuf; - int ct = bufSize; - - for (;;) { - if ( (*(pzD++) = *(pzS++)) == NUL) - break; - if (--ct <= 0) - return AG_FALSE; - } - } - - /* - * IF the name starts with "$$", then it must be "$$" or - * it must start with "$$/". In either event, replace the "$$" - * with the path to the executable and append a "/" character. - */ - else switch (pzName[1]) { - case NUL: - return AG_FALSE; - - case '$': - res = insertProgramPath( pzBuf, bufSize, pzName, pzProgPath ); - break; - - case '@': - if (pkgdatadir[0] == NUL) - return AG_FALSE; - - if (name_len + sizeof (pkgdatadir) > bufSize) - return AG_FALSE; - - strcpy(pzBuf, pkgdatadir); - strcpy(pzBuf + sizeof(pkgdatadir) - 1, pzName + 2); - break; - - default: - res = insertEnvVal( pzBuf, bufSize, pzName, pzProgPath ); - } - - if (! res) - return AG_FALSE; - -#if defined(HAVE_CANONICALIZE_FILE_NAME) - { - char* pz = canonicalize_file_name(pzBuf); - if (pz == NULL) - return AG_FALSE; - if (strlen(pz) < bufSize) - strcpy(pzBuf, pz); - free(pz); - } - -#elif defined(HAVE_REALPATH) - { - char z[ PATH_MAX+1 ]; - - if (realpath( pzBuf, z ) == NULL) - return AG_FALSE; - - if (strlen(z) < bufSize) - strcpy( pzBuf, z ); - } -#endif - - return AG_TRUE; -} - - -static ag_bool -insertProgramPath( - char* pzBuf, - int bufSize, - tCC* pzName, - tCC* pzProgPath ) -{ - tCC* pzPath; - tCC* pz; - int skip = 2; - - switch (pzName[2]) { - case DIRCH: - skip = 3; - case NUL: - break; - default: - return AG_FALSE; - } - - /* - * See if the path is included in the program name. - * If it is, we're done. Otherwise, we have to hunt - * for the program using "pathfind". - */ - if (strchr( pzProgPath, DIRCH ) != NULL) - pzPath = pzProgPath; - else { - pzPath = pathfind( getenv( "PATH" ), (char*)pzProgPath, "rx" ); - - if (pzPath == NULL) - return AG_FALSE; - } - - pz = strrchr( pzPath, DIRCH ); - - /* - * IF we cannot find a directory name separator, - * THEN we do not have a path name to our executable file. - */ - if (pz == NULL) - return AG_FALSE; - - pzName += skip; - - /* - * Concatenate the file name to the end of the executable path. - * The result may be either a file or a directory. - */ - if ((pz - pzPath)+1 + strlen(pzName) >= bufSize) - return AG_FALSE; - - memcpy( pzBuf, pzPath, (size_t)((pz - pzPath)+1) ); - strcpy( pzBuf + (pz - pzPath) + 1, pzName ); - - /* - * If the "pzPath" path was gotten from "pathfind()", then it was - * allocated and we need to deallocate it. - */ - if (pzPath != pzProgPath) - free( (void*)pzPath ); - return AG_TRUE; -} - - -static ag_bool -insertEnvVal( - char* pzBuf, - int bufSize, - tCC* pzName, - tCC* pzProgPath ) -{ - char* pzDir = pzBuf; - - for (;;) { - int ch = (int)*++pzName; - if (! ISNAMECHAR( ch )) - break; - *(pzDir++) = (char)ch; - } - - if (pzDir == pzBuf) - return AG_FALSE; - - *pzDir = NUL; - - pzDir = getenv( pzBuf ); - - /* - * Environment value not found -- skip the home list entry - */ - if (pzDir == NULL) - return AG_FALSE; - - if (strlen( pzDir ) + 1 + strlen( pzName ) >= bufSize) - return AG_FALSE; - - sprintf( pzBuf, "%s%s", pzDir, pzName ); - return AG_TRUE; -} - - -LOCAL void -mungeString( char* pzTxt, tOptionLoadMode mode ) -{ - char* pzE; - - if (mode == OPTION_LOAD_KEEP) - return; - - if (isspace( (int)*pzTxt )) { - char* pzS = pzTxt; - char* pzD = pzTxt; - while (isspace( (int)*++pzS )) ; - while ((*(pzD++) = *(pzS++)) != NUL) ; - pzE = pzD-1; - } else - pzE = pzTxt + strlen( pzTxt ); - - while ((pzE > pzTxt) && isspace( (int)pzE[-1] )) pzE--; - *pzE = NUL; - - if (mode == OPTION_LOAD_UNCOOKED) - return; - - switch (*pzTxt) { - default: return; - case '"': - case '\'': break; - } - - switch (pzE[-1]) { - default: return; - case '"': - case '\'': break; - } - - (void)ao_string_cook( pzTxt, NULL ); -} - - -static char* -assembleArgValue( char* pzTxt, tOptionLoadMode mode ) -{ - tSCC zBrk[] = " \t:="; - char* pzEnd = strpbrk( pzTxt, zBrk ); - int space_break; - - /* - * Not having an argument to a configurable name is okay. - */ - if (pzEnd == NULL) - return pzTxt + strlen(pzTxt); - - /* - * If we are keeping all whitespace, then the modevalue starts with the - * character that follows the end of the configurable name, regardless - * of which character caused it. - */ - if (mode == OPTION_LOAD_KEEP) { - *(pzEnd++) = NUL; - return pzEnd; - } - - /* - * If the name ended on a white space character, remember that - * because we'll have to skip over an immediately following ':' or '=' - * (and the white space following *that*). - */ - space_break = isspace((int)*pzEnd); - *(pzEnd++) = NUL; - while (isspace((int)*pzEnd)) pzEnd++; - if (space_break && ((*pzEnd == ':') || (*pzEnd == '='))) - while (isspace((int)*++pzEnd)) ; - - return pzEnd; -} - - -/* - * Load an option from a block of text. The text must start with the - * configurable/option name and be followed by its associated value. - * That value may be processed in any of several ways. See "tOptionLoadMode" - * in autoopts.h. - */ -LOCAL void -loadOptionLine( - tOptions* pOpts, - tOptState* pOS, - char* pzLine, - tDirection direction, - tOptionLoadMode load_mode ) -{ - while (isspace( (int)*pzLine )) pzLine++; - - { - char* pzArg = assembleArgValue( pzLine, load_mode ); - - if (! SUCCESSFUL( longOptionFind( pOpts, pzLine, pOS ))) - return; - if (pOS->flags & OPTST_NO_INIT) - return; - pOS->pzOptArg = pzArg; - } - - switch (pOS->flags & (OPTST_IMM|OPTST_DISABLE_IMM)) { - case 0: - /* - * The selected option has no immediate action. - * THEREFORE, if the direction is PRESETTING - * THEN we skip this option. - */ - if (PRESETTING(direction)) - return; - break; - - case OPTST_IMM: - if (PRESETTING(direction)) { - /* - * We are in the presetting direction with an option we handle - * immediately for enablement, but normally for disablement. - * Therefore, skip if disabled. - */ - if ((pOS->flags & OPTST_DISABLED) == 0) - return; - } else { - /* - * We are in the processing direction with an option we handle - * immediately for enablement, but normally for disablement. - * Therefore, skip if NOT disabled. - */ - if ((pOS->flags & OPTST_DISABLED) != 0) - return; - } - break; - - case OPTST_DISABLE_IMM: - if (PRESETTING(direction)) { - /* - * We are in the presetting direction with an option we handle - * immediately for disablement, but normally for disablement. - * Therefore, skip if NOT disabled. - */ - if ((pOS->flags & OPTST_DISABLED) != 0) - return; - } else { - /* - * We are in the processing direction with an option we handle - * immediately for disablement, but normally for disablement. - * Therefore, skip if disabled. - */ - if ((pOS->flags & OPTST_DISABLED) == 0) - return; - } - break; - - case OPTST_IMM|OPTST_DISABLE_IMM: - /* - * The selected option is always for immediate action. - * THEREFORE, if the direction is PROCESSING - * THEN we skip this option. - */ - if (PROCESSING(direction)) - return; - break; - } - - /* - * Fix up the args. - */ - if (OPTST_GET_ARGTYPE(pOS->pOD->fOptState) == OPARG_TYPE_NONE) { - if (*pOS->pzOptArg != NUL) - return; - pOS->pzOptArg = NULL; - - } else if (pOS->pOD->fOptState & OPTST_ARG_OPTIONAL) { - if (*pOS->pzOptArg == NUL) - pOS->pzOptArg = NULL; - else { - AGDUPSTR( pOS->pzOptArg, pOS->pzOptArg, "option argument" ); - pOS->flags |= OPTST_ALLOC_ARG; - } - - } else { - if (*pOS->pzOptArg == NUL) - pOS->pzOptArg = zNil; - else { - AGDUPSTR( pOS->pzOptArg, pOS->pzOptArg, "option argument" ); - pOS->flags |= OPTST_ALLOC_ARG; - } - } - - { - tOptionLoadMode sv = option_load_mode; - option_load_mode = load_mode; - handleOption( pOpts, pOS ); - option_load_mode = sv; - } -} - - -/*=export_func optionLoadLine - * - * what: process a string for an option name and value - * - * arg: tOptions*, pOpts, program options descriptor - * arg: char const*, pzLine, NUL-terminated text - * - * doc: - * - * This is a client program callable routine for setting options from, for - * example, the contents of a file that they read in. Only one option may - * appear in the text. It will be treated as a normal (non-preset) option. - * - * When passed a pointer to the option struct and a string, it will find - * the option named by the first token on the string and set the option - * argument to the remainder of the string. The caller must NUL terminate - * the string. Any embedded new lines will be included in the option - * argument. If the input looks like one or more quoted strings, then the - * input will be "cooked". The "cooking" is identical to the string - * formation used in AutoGen definition files (@pxref{basic expression}), - * except that you may not use backquotes. - * - * err: Invalid options are silently ignored. Invalid option arguments - * will cause a warning to print, but the function should return. -=*/ -void -optionLoadLine( - tOptions* pOpts, - tCC* pzLine ) -{ - tOptState st = OPTSTATE_INITIALIZER(SET); - char* pz; - AGDUPSTR( pz, pzLine, "user option line" ); - loadOptionLine( pOpts, &st, pz, DIRECTION_PROCESS, OPTION_LOAD_COOKED ); - AGFREE( pz ); -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/load.c */ diff --git a/contrib/ntp/libopts/m4/libopts.m4 b/contrib/ntp/libopts/m4/libopts.m4 deleted file mode 100644 index adc3235d2..000000000 --- a/contrib/ntp/libopts/m4/libopts.m4 +++ /dev/null @@ -1,509 +0,0 @@ -dnl -*- buffer-read-only: t -*- vi: set ro: -dnl -dnl DO NOT EDIT THIS FILE (libopts.m4) -dnl -dnl It has been AutoGen-ed Saturday May 5, 2007 at 12:02:37 PM PDT -dnl From the definitions libopts.def -dnl and the template file conftest.tpl -dnl -dnl do always before generated macros: -dnl -AC_DEFUN([INVOKE_LIBOPTS_MACROS_FIRST],[ -[if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then] - # ================= - # AC_HEADER_STDC - # ================= - AC_HEADER_STDC - # ================= - # AC_HEADER_DIRENT - # ================= - AC_HEADER_DIRENT - - # ================= - # AC_CHECK_HEADERS - # ================= - AC_CHECK_HEADERS(dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ - setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ - sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ - utime.h sysexits.h) - - # -------------------------------------------- - # Verify certain entries from AC_CHECK_HEADERS - # -------------------------------------------- - [for f in sys_types sys_mman sys_param sys_stat sys_wait \ - string errno stdlib memory setjmp - do eval as_ac_var=\${ac_cv_header_${f}_h+set} - test "${as_ac_var}" = set] || \ - AC_MSG_ERROR([You must have ${f}.h on your system]) - done - - # ================================================ - # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise - # if varargs.h is present define HAVE_VARARGS_H. - # ================================================ - AC_CHECK_HEADERS(stdarg.h varargs.h, break) - [if test `eval echo '${'$as_ac_Header'}'` != yes; then] - AC_MSG_ERROR([You must have stdarg.h or varargs.h on your system]) - fi - - # ================================================ - # Similarly for the string.h and strings.h headers - # ================================================ - AC_CHECK_HEADERS(string.h strings.h, break) - [if test `eval echo '${'$as_ac_Header'}'` != yes; then] - AC_MSG_ERROR([You must have string.h or strings.h on your system]) - fi - - # ===================== - # ...and limits headers - # ===================== - AC_CHECK_HEADERS(limits.h sys/limits.h values.h, break) - [if test `eval echo '${'$as_ac_Header'}'` != yes; then] - AC_MSG_ERROR([You must have one of limits.h, sys/limits.h or values.h]) - fi - - # ======================== - # ...and int types headers - # ======================== - AC_CHECK_HEADERS(stdint.h inttypes.h, break) - AC_CHECK_TYPES([int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, - intptr_t, uint_t]) - - # ==================== - # uintptr type & sizes - # ==================== - AC_CHECK_TYPES([uintptr_t], , - [AC_DEFINE([uintptr_t], unsigned long, - [Alternate uintptr_t for systems without it.])]) - AC_CHECK_SIZEOF(char*, 4) - AC_CHECK_SIZEOF(int, 4) - AC_CHECK_SIZEOF(long, 4) - AC_CHECK_SIZEOF(short, 2) - - # ---------------------------------------------------------------------- - # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. - # ---------------------------------------------------------------------- - AC_CHECK_LIB(gen, pathfind) - AC_FUNC_VPRINTF - AC_CHECK_FUNCS([mmap canonicalize_file_name snprintf strdup strchr strrchr]) -[ INVOKE_LIBOPTS_MACROS_FIRST_done=yes -fi]]) - -dnl -dnl @synopsis INVOKE_LIBOPTS_MACROS -dnl -dnl This macro will invoke the AutoConf macros specified in libopts.def -dnl that have not been disabled with "omit-invocation". -dnl -AC_DEFUN([LIBOPTS_WITH_REGEX_HEADER],[ - AC_ARG_WITH([regex-header], - AC_HELP_STRING([--with-regex-header], [a reg expr header is specified]), - [libopts_cv_with_regex_header=${with_regex_header}], - AC_CACHE_CHECK([whether a reg expr header is specified], libopts_cv_with_regex_header, - libopts_cv_with_regex_header=no) - ) # end of AC_ARG_WITH - - if test "X${libopts_cv_with_regex_header}" != Xno - then - AC_DEFINE_UNQUOTED([REGEX_HEADER],[<${libopts_cv_with_regex_header}>]) - else - AC_DEFINE([REGEX_HEADER],[],[name of regex header file]) - fi - -]) # end of AC_DEFUN of LIBOPTS_WITH_REGEX_HEADER - - -AC_DEFUN([LIBOPTS_WITHLIB_REGEX],[ - AC_ARG_WITH([libregex], - AC_HELP_STRING([--with-libregex], [libregex installation prefix]), - [libopts_cv_with_libregex_root=${with_libregex}], - AC_CACHE_CHECK([whether with-libregex was specified], libopts_cv_with_libregex_root, - libopts_cv_with_libregex_root=no) - ) # end of AC_ARG_WITH libregex - - if test "${with_libguile+set}" = set && \ - test "${withval}" = no - then ## disabled by request - libopts_cv_with_libregex_root=no - libopts_cv_with_libregex_cflags=no - libopts_cv_with_libregex_libs=no - else - - AC_ARG_WITH([libregex-cflags], - AC_HELP_STRING([--with-libregex-cflags], [libregex compile flags]), - [libopts_cv_with_libregex_cflags=${with_regex_cflags}], - AC_CACHE_CHECK([whether with-libregex-cflags was specified], libopts_cv_with_libregex_cflags, - libopts_cv_with_libregex_cflags=no) - ) # end of AC_ARG_WITH libregex-cflags - - AC_ARG_WITH([libregex-libs], - AC_HELP_STRING([--with-libregex-libs], [libregex link command arguments]), - [libopts_cv_with_libregex_libs=${with_regex_libs}], - AC_CACHE_CHECK([whether with-libregex-libs was specified], libopts_cv_with_libregex_libs, - libopts_cv_with_libregex_libs=no) - ) # end of AC_ARG_WITH libregex-libs - - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;; - * ) libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;; - esac - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;; - * ) libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex";; - esac - esac - libopts_save_CPPFLAGS="${CPPFLAGS}" - libopts_save_LIBS="${LIBS}" - fi ## disabled by request - - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_cflags="" ;; - * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;; - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_libs="" ;; - * ) - LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;; - esac - LIBREGEX_CFLAGS="" - LIBREGEX_LIBS="" - AC_MSG_CHECKING([whether libregex functions properly]) - AC_CACHE_VAL([libopts_cv_with_libregex],[ - AC_TRY_RUN([@%:@include -@%:@include -@%:@include -@%:@include REGEX_HEADER -static regex_t re; -void comp_re( char const* pzPat ) { - int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE ); - if (res == 0) return; - exit( res ); } -int main() { - regmatch_t m@<:@2@:>@; - comp_re( "^.*\@S|@" ); - comp_re( "()|no.*" ); - comp_re( "." ); - if (regexec( &re, "X", 2, m, 0 ) != 0) return 1; - if ((m@<:@0@:>@.rm_so != 0) || (m@<:@0@:>@.rm_eo != 1)) { - fputs( "error: regex -->.<-- did not match\n", stderr ); - return 1; - } - return 0; }], - [libopts_cv_with_libregex=yes], [libopts_cv_with_libregex=no], - [libopts_cv_with_libregex=no]) # end of AC_TRY_RUN - ]) # end of AC_CACHE_VAL for libopts_cv_with_libregex - AC_MSG_RESULT([${libopts_cv_with_libregex}]) - - if test "X${libopts_cv_with_libregex}" != Xno - then - AC_DEFINE([WITH_LIBREGEX],[1], - [Define this if a working libregex can be found]) - else - CPPFLAGS="${libopts_save_CPPFLAGS}" - LIBS="${libopts_save_LIBS}" - fi - -]) # end of AC_DEFUN of LIBOPTS_WITHLIB_REGEX - - -AC_DEFUN([LIBOPTS_RUN_PATHFIND],[ - AC_MSG_CHECKING([whether pathfind(3) works]) - AC_CACHE_VAL([libopts_cv_run_pathfind],[ - AC_TRY_RUN([@%:@include -@%:@include -int main (int argc, char** argv) { - char* pz = pathfind( getenv( "PATH" ), "sh", "x" ); - return (pz == 0) ? 1 : 0; -}], - [libopts_cv_run_pathfind=yes],[libopts_cv_run_pathfind=no],[libopts_cv_run_pathfind=no] - ) # end of TRY_RUN - ]) # end of AC_CACHE_VAL for libopts_cv_run_pathfind - AC_MSG_RESULT([${libopts_cv_run_pathfind}]) - - if test "X${libopts_cv_run_pathfind}" != Xno - then - AC_DEFINE([HAVE_PATHFIND],[1], - [Define this if pathfind(3) works]) - fi - -]) # end of AC_DEFUN of LIBOPTS_RUN_PATHFIND - - -AC_DEFUN([LIBOPTS_TEST_DEV_ZERO],[ - AC_MSG_CHECKING([whether /dev/zero is readable device]) - AC_CACHE_VAL([libopts_cv_test_dev_zero],[ - libopts_cv_test_dev_zero=`exec 2> /dev/null -dzero=\`ls -lL /dev/zero | egrep ^c......r\` -test -z "${dzero}" && exit 1 -echo ${dzero}` - if test $? -ne 0 - then libopts_cv_test_dev_zero=no - elif test -z "$libopts_cv_test_dev_zero" - then libopts_cv_test_dev_zero=no - fi - ]) # end of CACHE_VAL of libopts_cv_test_dev_zero - AC_MSG_RESULT([${libopts_cv_test_dev_zero}]) - - if test "X${libopts_cv_test_dev_zero}" != Xno - then - AC_DEFINE([HAVE_DEV_ZERO],[1], - [Define this if /dev/zero is readable device]) - fi - -]) # end of AC_DEFUN of LIBOPTS_TEST_DEV_ZERO - - -AC_DEFUN([LIBOPTS_RUN_REALPATH],[ - AC_MSG_CHECKING([whether we have a functional realpath(3C)]) - AC_CACHE_VAL([libopts_cv_run_realpath],[ - AC_TRY_RUN([@%:@include -@%:@include -int main (int argc, char** argv) { -@%:@ifndef PATH_MAX -choke me!! -@%:@else - char zPath@<:@PATH_MAX+1@:>@; -@%:@endif - char *pz = realpath(argv@<:@0@:>@, zPath); - return (pz == zPath) ? 0 : 1; -}], - [libopts_cv_run_realpath=yes],[libopts_cv_run_realpath=no],[libopts_cv_run_realpath=no] - ) # end of TRY_RUN - ]) # end of AC_CACHE_VAL for libopts_cv_run_realpath - AC_MSG_RESULT([${libopts_cv_run_realpath}]) - - if test "X${libopts_cv_run_realpath}" != Xno - then - AC_DEFINE([HAVE_REALPATH],[1], - [Define this if we have a functional realpath(3C)]) - fi - -]) # end of AC_DEFUN of LIBOPTS_RUN_REALPATH - - -AC_DEFUN([LIBOPTS_RUN_STRFTIME],[ - AC_MSG_CHECKING([whether strftime() works]) - AC_CACHE_VAL([libopts_cv_run_strftime],[ - AC_TRY_RUN([@%:@include -@%:@include -char t_buf@<:@ 64 @:>@; -int main() { - static char const z@<:@@:>@ = "Thursday Aug 28 240"; - struct tm tm; - tm.tm_sec = 36; /* seconds after the minute @<:@0, 61@:>@ */ - tm.tm_min = 44; /* minutes after the hour @<:@0, 59@:>@ */ - tm.tm_hour = 12; /* hour since midnight @<:@0, 23@:>@ */ - tm.tm_mday = 28; /* day of the month @<:@1, 31@:>@ */ - tm.tm_mon = 7; /* months since January @<:@0, 11@:>@ */ - tm.tm_year = 86; /* years since 1900 */ - tm.tm_wday = 4; /* days since Sunday @<:@0, 6@:>@ */ - tm.tm_yday = 239; /* days since January 1 @<:@0, 365@:>@ */ - tm.tm_isdst = 1; /* flag for daylight savings time */ - strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm ); - return (strcmp( t_buf, z ) != 0); }], - [libopts_cv_run_strftime=yes],[libopts_cv_run_strftime=no],[libopts_cv_run_strftime=no] - ) # end of TRY_RUN - ]) # end of AC_CACHE_VAL for libopts_cv_run_strftime - AC_MSG_RESULT([${libopts_cv_run_strftime}]) - - if test "X${libopts_cv_run_strftime}" != Xno - then - AC_DEFINE([HAVE_STRFTIME],[1], - [Define this if strftime() works]) - fi - -]) # end of AC_DEFUN of LIBOPTS_RUN_STRFTIME - - -AC_DEFUN([LIBOPTS_RUN_FOPEN_BINARY],[ - AC_MSG_CHECKING([whether fopen accepts "b" mode]) - AC_CACHE_VAL([libopts_cv_run_fopen_binary],[ - AC_TRY_RUN([@%:@include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.@S|@ac_ext", "rb"); -return (fp == NULL) ? 1 : fclose(fp); }], - [libopts_cv_run_fopen_binary=yes],[libopts_cv_run_fopen_binary=no],[libopts_cv_run_fopen_binary=no] - ) # end of TRY_RUN - ]) # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary - AC_MSG_RESULT([${libopts_cv_run_fopen_binary}]) - - if test "X${libopts_cv_run_fopen_binary}" != Xno - then - AC_DEFINE([FOPEN_BINARY_FLAG],"b", - [fopen(3) accepts a 'b' in the mode flag]) - else - AC_DEFINE([FOPEN_BINARY_FLAG],"", - [fopen(3) accepts a 'b' in the mode flag]) - fi - -]) # end of AC_DEFUN of LIBOPTS_RUN_FOPEN_BINARY - - -AC_DEFUN([LIBOPTS_RUN_FOPEN_TEXT],[ - AC_MSG_CHECKING([whether fopen accepts "t" mode]) - AC_CACHE_VAL([libopts_cv_run_fopen_text],[ - AC_TRY_RUN([@%:@include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.@S|@ac_ext", "rt"); -return (fp == NULL) ? 1 : fclose(fp); }], - [libopts_cv_run_fopen_text=yes],[libopts_cv_run_fopen_text=no],[libopts_cv_run_fopen_text=no] - ) # end of TRY_RUN - ]) # end of AC_CACHE_VAL for libopts_cv_run_fopen_text - AC_MSG_RESULT([${libopts_cv_run_fopen_text}]) - - if test "X${libopts_cv_run_fopen_text}" != Xno - then - AC_DEFINE([FOPEN_TEXT_FLAG],"t", - [fopen(3) accepts a 't' in the mode flag]) - else - AC_DEFINE([FOPEN_TEXT_FLAG],"", - [fopen(3) accepts a 't' in the mode flag]) - fi - -]) # end of AC_DEFUN of LIBOPTS_RUN_FOPEN_TEXT - - -AC_DEFUN([LIBOPTS_DISABLE_OPTIONAL_ARGS],[ - AC_ARG_ENABLE([optional-args], - AC_HELP_STRING([--disable-optional-args], [not wanting optional option args]), - [libopts_cv_enable_optional_args=${enable_optional_args}], - AC_CACHE_CHECK([whether not wanting optional option args], libopts_cv_enable_optional_args, - libopts_cv_enable_optional_args=yes) - ) # end of AC_ARG_ENABLE - - if test "X${libopts_cv_enable_optional_args}" = Xno - then - AC_DEFINE([NO_OPTIONAL_OPT_ARGS], [1], - [Define this if optional arguments are disallowed]) - fi - -]) # end of AC_DEFUN of LIBOPTS_DISABLE_OPTIONAL_ARGS - - -AC_DEFUN([INVOKE_LIBOPTS_MACROS],[ - INVOKE_LIBOPTS_MACROS_FIRST - # Check to see if a reg expr header is specified. - LIBOPTS_WITH_REGEX_HEADER - - # Check to see if a working libregex can be found. - LIBOPTS_WITHLIB_REGEX - - # Check to see if pathfind(3) works. - LIBOPTS_RUN_PATHFIND - - # Check to see if /dev/zero is readable device. - LIBOPTS_TEST_DEV_ZERO - - # Check to see if we have a functional realpath(3C). - LIBOPTS_RUN_REALPATH - - # Check to see if strftime() works. - LIBOPTS_RUN_STRFTIME - - # Check to see if fopen accepts "b" mode. - LIBOPTS_RUN_FOPEN_BINARY - - # Check to see if fopen accepts "t" mode. - LIBOPTS_RUN_FOPEN_TEXT - - # Check to see if not wanting optional option args. - LIBOPTS_DISABLE_OPTIONAL_ARGS - -]) # end AC_DEFUN of INVOKE_LIBOPTS_MACROS - -dnl @synopsis LIBOPTS_CHECK -dnl -dnl Time-stamp: "2006-09-23 19:36:24 bkorb" -dnl Last Committed: $Date: 2006/09/24 02:59:00 $ -dnl -dnl If autoopts-config works, add the linking information to LIBS. -dnl Otherwise, add ``libopts-${ao_rev}'' to SUBDIRS and run all -dnl the config tests that the library needs. Invoke the -dnl "INVOKE_LIBOPTS_MACROS" macro iff we are building libopts. -dnl -dnl Default to system libopts -dnl -AC_DEFUN([LIBOPTS_CHECK],[ - [NEED_LIBOPTS_DIR=''] - m4_pushdef([AO_Libopts_Dir], - [ifelse($1, , [libopts], [$1])]) - AC_SUBST(LIBOPTS_DIR, AO_Libopts_Dir) - AC_ARG_ENABLE([local-libopts], - AC_HELP_STRING([--enable-local-libopts], - [Force using the supplied libopts tearoff code]),[ - if test x$enableval = xyes ; then - AC_MSG_NOTICE([Using supplied libopts tearoff]) - LIBOPTS_LDADD='$(top_builddir)/AO_Libopts_Dir/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/AO_Libopts_Dir' - NEED_LIBOPTS_DIR=true - fi]) - - AC_ARG_ENABLE([libopts-install], - AC_HELP_STRING([--disable-libopts-install], - [Do not install libopts with client installation])) - AM_CONDITIONAL([INSTALL_LIBOPTS],[test "X${enable_libopts_install}" != Xno]) - - [if test -z "${NEED_LIBOPTS_DIR}" ; then] - AC_MSG_CHECKING([whether autoopts-config can be found]) - AC_ARG_WITH([autoopts-config], - AC_HELP_STRING([--with-autoopts-config], - [specify the config-info script]), - [lo_cv_with_autoopts_config=${with_autoopts_config}], - AC_CACHE_CHECK([whether autoopts-config is specified], - [lo_cv_with_autoopts_config], - [if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=no ; fi]) - ) # end of AC_ARG_WITH - - AC_CACHE_VAL([lo_cv_test_autoopts],[ - if test -z "${lo_cv_with_autoopts_config}" \ - -o X"${lo_cv_with_autoopts_config}" = Xno - then - if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=false ; fi - fi - lo_cv_test_autoopts=` - ${lo_cv_with_autoopts_config} --libs` 2> /dev/null - if test $? -ne 0 -o -z "${lo_cv_test_autoopts}" - then lo_cv_test_autoopts=no ; fi - ]) # end of CACHE_VAL - AC_MSG_RESULT([${lo_cv_test_autoopts}]) - - [if test "X${lo_cv_test_autoopts}" != Xno - then - LIBOPTS_LDADD="${lo_cv_test_autoopts}" - LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`" - else - LIBOPTS_LDADD='$(top_builddir)/]AO_Libopts_Dir[/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/]AO_Libopts_Dir[' - NEED_LIBOPTS_DIR=true - fi - fi # end of if test -z "${NEED_LIBOPTS_DIR}"] - - AM_CONDITIONAL([NEED_LIBOPTS], [test -n "${NEED_LIBOPTS_DIR}"]) - AC_SUBST(LIBOPTS_LDADD) - AC_SUBST(LIBOPTS_CFLAGS) - AC_SUBST(LIBOPTS_DIR, AO_Libopts_Dir) - AC_CONFIG_FILES(AO_Libopts_Dir/Makefile) - m4_popdef([AO_Libopts_Dir]) - - [if test -n "${NEED_LIBOPTS_DIR}" ; then] - INVOKE_LIBOPTS_MACROS - else - INVOKE_LIBOPTS_MACROS_FIRST - [fi -# end of AC_DEFUN of LIBOPTS_CHECK] -]) diff --git a/contrib/ntp/libopts/m4/liboptschk.m4 b/contrib/ntp/libopts/m4/liboptschk.m4 deleted file mode 100644 index 14e7f27c8..000000000 --- a/contrib/ntp/libopts/m4/liboptschk.m4 +++ /dev/null @@ -1,42 +0,0 @@ -# liboptschk.m4 serial 1 (autogen - 5.7.3) -dnl Copyright (C) 2005 Free Software Foundation, Inc. -dnl This file is free software; the Free Software Foundation -dnl gives unlimited permission to copy and/or distribute it, -dnl with or without modifications, as long as this notice is preserved. - -dnl Time-stamp: "2006-09-23 19:42:31 bkorb" -dnl Last Committed: $Date: 2006/09/24 02:59:00 $ - -dnl This file can can be used in projects which are not available under -dnl the GNU General Public License or the GNU Library General Public -dnl License but which still want to provide support for the GNU gettext -dnl functionality. -dnl Please note that the actual code of the GNU gettext library is covered -dnl by the GNU Library General Public License, and the rest of the GNU -dnl gettext package package is covered by the GNU General Public License. -dnl They are *not* in the public domain. - -dnl Authors: -dnl Ulrich Drepper , 1995-2000. -dnl Bruno Haible , 2000-2003. - -AC_PREREQ(2.50) - -AC_DEFUN([ag_FIND_LIBOPTS], - [if test "X${ac_cv_header_autoopts_options_h}" == Xno - then - : - else - f=`autoopts-config cflags` 2>/dev/null - test X"${f}" = X && f=`libopts-config cflags` 2>/dev/null - if test X"${f}" = X - then - : - else - AC_DEFINE([HAVE_LIBOPTS],[1],[define if we can find libopts]) - CFLAGS="${CFLAGS} ${f}" - f=`autoopts-config ldflags` 2>/dev/null - test X"${f}" = X && f=`libopts-config ldflags` 2>/dev/null - LIBS="${LIBS} ${f}" - fi - fi]) diff --git a/contrib/ntp/libopts/makeshell.c b/contrib/ntp/libopts/makeshell.c deleted file mode 100644 index 8447d454b..000000000 --- a/contrib/ntp/libopts/makeshell.c +++ /dev/null @@ -1,1122 +0,0 @@ - -/* - * $Id: makeshell.c,v 4.20 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-27 06:05:45 bkorb" - * - * This module will interpret the options set in the tOptions - * structure and create a Bourne shell script capable of parsing them. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -tOptions* pShellParseOptions = NULL; - -/* * * * * * * * * * * * * * * * * * * * * - * - * Setup Format Strings - */ -tSCC zStartMarker[] = -"# # # # # # # # # # -- do not modify this marker --\n#\n" -"# DO NOT EDIT THIS SECTION"; - -tSCC zPreamble[] = -"%s OF %s\n#\n" -"# From here to the next `-- do not modify this marker --',\n" -"# the text has been generated %s\n"; - -tSCC zEndPreamble[] = -"# From the %s option definitions\n#\n"; - -tSCC zMultiDef[] = "\n" -"if test -z \"${%1$s_%2$s}\"\n" -"then\n" -" %1$s_%2$s_CT=0\n" -"else\n" -" %1$s_%2$s_CT=1\n" -" %1$s_%2$s_1=\"${%1$s_%2$s}\"\n" -"fi\n" -"export %1$s_%2$s_CT"; - -tSCC zSingleDef[] = "\n" -"%1$s_%2$s=\"${%1$s_%2$s-'%3$s'}\"\n" -"%1$s_%2$s_set=false\n" -"export %1$s_%2$s\n"; - -tSCC zSingleNoDef[] = "\n" -"%1$s_%2$s=\"${%1$s_%2$s}\"\n" -"%1$s_%2$s_set=false\n" -"export %1$s_%2$s\n"; - -/* * * * * * * * * * * * * * * * * * * * * - * - * LOOP START - * - * The loop may run in either of two modes: - * all options are named options (loop only) - * regular, marked option processing. - */ -tSCC zLoopCase[] = "\n" -"OPT_PROCESS=true\n" -"OPT_ARG=\"$1\"\n\n" -"while ${OPT_PROCESS} && [ $# -gt 0 ]\ndo\n" -" OPT_ELEMENT=''\n" -" OPT_ARG_VAL=''\n\n" - /* - * 'OPT_ARG' may or may not match the current $1 - */ -" case \"${OPT_ARG}\" in\n" -" -- )\n" -" OPT_PROCESS=false\n" -" shift\n" -" ;;\n\n"; - -tSCC zLoopOnly[] = "\n" -"OPT_ARG=\"$1\"\n\n" -"while [ $# -gt 0 ]\ndo\n" -" OPT_ELEMENT=''\n" -" OPT_ARG_VAL=''\n\n" -" OPT_ARG=\"${1}\"\n"; - -/* * * * * * * * * * * * * * * * - * - * CASE SELECTORS - * - * If the loop runs as a regular option loop, - * then we must have selectors for each acceptable option - * type (long option, flag character and non-option) - */ -tSCC zLongSelection[] = -" --* )\n"; - -tSCC zFlagSelection[] = -" -* )\n"; - -tSCC zEndSelection[] = -" ;;\n\n"; - -tSCC zNoSelection[] = -" * )\n" -" OPT_PROCESS=false\n" -" ;;\n" -" esac\n\n"; - -/* * * * * * * * * * * * * * * * - * - * LOOP END - */ -tSCC zLoopEnd[] = -" if [ -n \"${OPT_ARG_VAL}\" ]\n" -" then\n" -" eval %1$s_${OPT_NAME}${OPT_ELEMENT}=\"'${OPT_ARG_VAL}'\"\n" -" export %1$s_${OPT_NAME}${OPT_ELEMENT}\n" -" fi\n" -"done\n\n" -"unset OPT_PROCESS || :\n" -"unset OPT_ELEMENT || :\n" -"unset OPT_ARG || :\n" -"unset OPT_ARG_NEEDED || :\n" -"unset OPT_NAME || :\n" -"unset OPT_CODE || :\n" -"unset OPT_ARG_VAL || :\n%2$s"; - -tSCC zTrailerMarker[] = "\n" -"# # # # # # # # # #\n#\n" -"# END OF AUTOMATED OPTION PROCESSING\n" -"#\n# # # # # # # # # # -- do not modify this marker --\n"; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * OPTION SELECTION - */ -tSCC zOptionCase[] = -" case \"${OPT_CODE}\" in\n"; - -tSCC zOptionPartName[] = -" '%s' | \\\n"; - -tSCC zOptionFullName[] = -" '%s' )\n"; - -tSCC zOptionFlag[] = -" '%c' )\n"; - -tSCC zOptionEndSelect[] = -" ;;\n\n"; - -tSCC zOptionUnknown[] = -" * )\n" -" echo Unknown %s: \"${OPT_CODE}\" >&2\n" -" echo \"$%s_USAGE_TEXT\"\n" -" exit 1\n" -" ;;\n" -" esac\n\n"; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * OPTION PROCESSING - * - * Formats for emitting the text for handling particular options - */ -tSCC zTextExit[] = -" echo \"$%s_%s_TEXT\"\n" -" exit 0\n"; - -tSCC zPagedUsageExit[] = -" echo \"$%s_LONGUSAGE_TEXT\" | ${PAGER-more}\n" -" exit 0\n"; - -tSCC zCmdFmt[] = -" %s\n"; - -tSCC zCountTest[] = -" if [ $%1$s_%2$s_CT -ge %3$d ] ; then\n" -" echo Error: more than %3$d %2$s options >&2\n" -" echo \"$%1$s_USAGE_TEXT\"\n" -" exit 1 ; fi\n"; - -tSCC zMultiArg[] = -" %1$s_%2$s_CT=`expr ${%1$s_%2$s_CT} + 1`\n" -" OPT_ELEMENT=\"_${%1$s_%2$s_CT}\"\n" -" OPT_NAME='%2$s'\n"; - -tSCC zSingleArg[] = -" if [ -n \"${%1$s_%2$s}\" ] && ${%1$s_%2$s_set} ; then\n" -" echo Error: duplicate %2$s option >&2\n" -" echo \"$%1$s_USAGE_TEXT\"\n" -" exit 1 ; fi\n" -" %1$s_%2$s_set=true\n" -" OPT_NAME='%2$s'\n"; - -tSCC zNoMultiArg[] = -" %1$s_%2$s_CT=0\n" -" OPT_ELEMENT=''\n" -" %1$s_%2$s='%3$s'\n" -" export %1$s_%2$s\n" -" OPT_NAME='%2$s'\n"; - -tSCC zNoSingleArg[] = -" if [ -n \"${%1$s_%2$s}\" ] && ${%1$s_%2$s_set} ; then\n" -" echo Error: duplicate %2$s option >&2\n" -" echo \"$%1$s_USAGE_TEXT\"\n" -" exit 1 ; fi\n" -" %1$s_%2$s_set=true\n" -" %1$s_%2$s='%3$s'\n" -" export %1$s_%2$s\n" -" OPT_NAME='%2$s'\n"; - -tSCC zMayArg[] = -" eval %1$s_%2$s${OPT_ELEMENT}=true\n" -" export %1$s_%2$s${OPT_ELEMENT}\n" -" OPT_ARG_NEEDED=OK\n"; - -tSCC zMustArg[] = -" OPT_ARG_NEEDED=YES\n"; - -tSCC zCantArg[] = -" eval %1$s_%2$s${OPT_ELEMENT}=true\n" -" export %1$s_%2$s${OPT_ELEMENT}\n" -" OPT_ARG_NEEDED=NO\n"; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * LONG OPTION PROCESSING - * - * Formats for emitting the text for handling long option types - */ -tSCC zLongOptInit[] = -" OPT_CODE=`echo \"X${OPT_ARG}\"|sed 's/^X-*//'`\n" -" shift\n" -" OPT_ARG=\"$1\"\n\n" -" case \"${OPT_CODE}\" in *=* )\n" -" OPT_ARG_VAL=`echo \"${OPT_CODE}\"|sed 's/^[^=]*=//'`\n" -" OPT_CODE=`echo \"${OPT_CODE}\"|sed 's/=.*$//'` ;; esac\n\n"; - -tSCC zLongOptArg[] = -" case \"${OPT_ARG_NEEDED}\" in\n" -" NO )\n" -" OPT_ARG_VAL=''\n" -" ;;\n\n" -" YES )\n" -" if [ -z \"${OPT_ARG_VAL}\" ]\n" -" then\n" -" if [ $# -eq 0 ]\n" -" then\n" -" echo No argument provided for ${OPT_NAME} option >&2\n" -" echo \"$%s_USAGE_TEXT\"\n" -" exit 1\n" -" fi\n\n" -" OPT_ARG_VAL=\"${OPT_ARG}\"\n" -" shift\n" -" OPT_ARG=\"$1\"\n" -" fi\n" -" ;;\n\n" -" OK )\n" -" if [ -z \"${OPT_ARG_VAL}\" ] && [ $# -gt 0 ]\n" -" then\n" -" case \"${OPT_ARG}\" in -* ) ;; * )\n" -" OPT_ARG_VAL=\"${OPT_ARG}\"\n" -" shift\n" -" OPT_ARG=\"$1\" ;; esac\n" -" fi\n" -" ;;\n" -" esac\n"; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * FLAG OPTION PROCESSING - * - * Formats for emitting the text for handling flag option types - */ -tSCC zFlagOptInit[] = -" OPT_CODE=`echo \"X${OPT_ARG}\" | sed 's/X-\\(.\\).*/\\1/'`\n" -" OPT_ARG=` echo \"X${OPT_ARG}\" | sed 's/X-.//'`\n\n"; - -tSCC zFlagOptArg[] = -" case \"${OPT_ARG_NEEDED}\" in\n" -" NO )\n" -" if [ -n \"${OPT_ARG}\" ]\n" -" then\n" -" OPT_ARG=-\"${OPT_ARG}\"\n" -" else\n" -" shift\n" -" OPT_ARG=\"$1\"\n" -" fi\n" -" ;;\n\n" -" YES )\n" -" if [ -n \"${OPT_ARG}\" ]\n" -" then\n" -" OPT_ARG_VAL=\"${OPT_ARG}\"\n\n" -" else\n" -" if [ $# -eq 0 ]\n" -" then\n" -" echo No argument provided for ${OPT_NAME} option >&2\n" -" echo \"$%s_USAGE_TEXT\"\n" -" exit 1\n" -" fi\n" -" shift\n" -" OPT_ARG_VAL=\"$1\"\n" -" fi\n\n" -" shift\n" -" OPT_ARG=\"$1\"\n" -" ;;\n\n" -" OK )\n" -" if [ -n \"${OPT_ARG}\" ]\n" -" then\n" -" OPT_ARG_VAL=\"${OPT_ARG}\"\n" -" shift\n" -" OPT_ARG=\"$1\"\n\n" -" else\n" -" shift\n" -" if [ $# -gt 0 ]\n" -" then\n" -" case \"$1\" in -* ) ;; * )\n" -" OPT_ARG_VAL=\"$1\"\n" -" shift ;; esac\n" -" OPT_ARG=\"$1\"\n" -" fi\n" -" fi\n" -" ;;\n" -" esac\n"; - -tSCC* pzShell = NULL; -static char* pzLeader = NULL; -static char* pzTrailer = NULL; - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -textToVariable( tOptions* pOpts, teTextTo whichVar, tOptDesc* pOD ); - -static void -emitUsage( tOptions* pOpts ); - -static void -emitSetup( tOptions* pOpts ); - -static void -printOptionAction( tOptions* pOpts, tOptDesc* pOptDesc ); - -static void -printOptionInaction( tOptions* pOpts, tOptDesc* pOptDesc ); - -static void -emitFlag( tOptions* pOpts ); - -static void -emitMatchExpr( tCC* pzMatchName, tOptDesc* pCurOpt, tOptions* pOpts ); - -static void -emitLong( tOptions* pOpts ); - -static void -openOutput( char const* pzFile ); -/* = = = END-STATIC-FORWARD = = = */ - -/*=export_func optionParseShell - * private: - * - * what: Decipher a boolean value - * arg: + tOptions* + pOpts + program options descriptor + - * - * doc: - * Emit a shell script that will parse the command line options. -=*/ -void -optionParseShell( tOptions* pOpts ) -{ - /* - * Check for our SHELL option now. - * IF the output file contains the "#!" magic marker, - * it will override anything we do here. - */ - if (HAVE_OPT( SHELL )) - pzShell = OPT_ARG( SHELL ); - - else if (! ENABLED_OPT( SHELL )) - pzShell = NULL; - - else if ((pzShell = getenv( "SHELL" )), - pzShell == NULL) - - pzShell = "/bin/sh"; - - /* - * Check for a specified output file - */ - if (HAVE_OPT( SCRIPT )) - openOutput( OPT_ARG( SCRIPT )); - - emitUsage( pOpts ); - emitSetup( pOpts ); - - /* - * There are four modes of option processing. - */ - switch (pOpts->fOptSet & (OPTPROC_LONGOPT|OPTPROC_SHORTOPT)) { - case OPTPROC_LONGOPT: - fputs( zLoopCase, stdout ); - - fputs( zLongSelection, stdout ); - fputs( zLongOptInit, stdout ); - emitLong( pOpts ); - printf( zLongOptArg, pOpts->pzPROGNAME ); - fputs( zEndSelection, stdout ); - - fputs( zNoSelection, stdout ); - break; - - case 0: - fputs( zLoopOnly, stdout ); - fputs( zLongOptInit, stdout ); - emitLong( pOpts ); - printf( zLongOptArg, pOpts->pzPROGNAME ); - break; - - case OPTPROC_SHORTOPT: - fputs( zLoopCase, stdout ); - - fputs( zFlagSelection, stdout ); - fputs( zFlagOptInit, stdout ); - emitFlag( pOpts ); - printf( zFlagOptArg, pOpts->pzPROGNAME ); - fputs( zEndSelection, stdout ); - - fputs( zNoSelection, stdout ); - break; - - case OPTPROC_LONGOPT|OPTPROC_SHORTOPT: - fputs( zLoopCase, stdout ); - - fputs( zLongSelection, stdout ); - fputs( zLongOptInit, stdout ); - emitLong( pOpts ); - printf( zLongOptArg, pOpts->pzPROGNAME ); - fputs( zEndSelection, stdout ); - - fputs( zFlagSelection, stdout ); - fputs( zFlagOptInit, stdout ); - emitFlag( pOpts ); - printf( zFlagOptArg, pOpts->pzPROGNAME ); - fputs( zEndSelection, stdout ); - - fputs( zNoSelection, stdout ); - break; - } - - printf( zLoopEnd, pOpts->pzPROGNAME, zTrailerMarker ); - if ((pzTrailer != NULL) && (*pzTrailer != '\0')) - fputs( pzTrailer, stdout ); - else if (ENABLED_OPT( SHELL )) - printf( "\nenv | grep '^%s_'\n", pOpts->pzPROGNAME ); - - fflush( stdout ); - fchmod( STDOUT_FILENO, 0755 ); - fclose( stdout ); -} - - -static void -textToVariable( tOptions* pOpts, teTextTo whichVar, tOptDesc* pOD ) -{ -# define _TT_(n) tSCC z ## n [] = #n; - TEXTTO_TABLE -# undef _TT_ -# define _TT_(n) z ## n , - static char const* apzTTNames[] = { TEXTTO_TABLE }; -# undef _TT_ - -#if defined(__windows__) && !defined(__CYGWIN__) - printf( "%1$s_%2$s_TEXT='no %2$s text'\n", - pOpts->pzPROGNAME, apzTTNames[ whichVar ]); -#else - int nlHoldCt = 0; - int pipeFd[2]; - FILE* fp; - - printf( "%s_%s_TEXT='", pOpts->pzPROGNAME, apzTTNames[ whichVar ]); - fflush( stdout ); - - if (pipe( pipeFd ) != 0) { - fprintf( stderr, zBadPipe, errno, strerror( errno )); - exit( EXIT_FAILURE ); - } - - switch (fork()) { - case -1: - fprintf( stderr, zForkFail, errno, strerror(errno), pOpts->pzProgName); - exit( EXIT_FAILURE ); - break; - - case 0: - dup2( pipeFd[1], STDERR_FILENO ); - dup2( pipeFd[1], STDOUT_FILENO ); - close( pipeFd[0] ); - - switch (whichVar) { - case TT_LONGUSAGE: - (*(pOpts->pUsageProc))( pOpts, EXIT_SUCCESS ); - /* NOTREACHED */ - exit( EXIT_FAILURE ); - - case TT_USAGE: - (*(pOpts->pUsageProc))( pOpts, EXIT_FAILURE ); - /* NOTREACHED */ - exit( EXIT_FAILURE ); - - case TT_VERSION: - if (pOD->fOptState & OPTST_ALLOC_ARG) { - AGFREE(pOD->optArg.argString); - pOD->fOptState &= ~OPTST_ALLOC_ARG; - } - pOD->optArg.argString = "c"; - optionPrintVersion( pOpts, pOD ); - /* NOTREACHED */ - - default: - exit( EXIT_FAILURE ); - } - - default: - close( pipeFd[1] ); - fp = fdopen( pipeFd[0], "r" FOPEN_BINARY_FLAG ); - } - - for (;;) { - int ch = fgetc( fp ); - switch (ch) { - - case '\n': - nlHoldCt++; - break; - - case '\'': - while (nlHoldCt > 0) { - fputc( '\n', stdout ); - nlHoldCt--; - } - fputs( "'\\''", stdout ); - break; - - case EOF: - goto endCharLoop; - - default: - while (nlHoldCt > 0) { - fputc( '\n', stdout ); - nlHoldCt--; - } - fputc( ch, stdout ); - break; - } - } endCharLoop:; - - fputs( "'\n\n", stdout ); - close( pipeFd[0] ); -#endif -} - - -static void -emitUsage( tOptions* pOpts ) -{ - char zTimeBuf[ AO_NAME_SIZE ]; - - /* - * First, switch stdout to the output file name. - * Then, change the program name to the one defined - * by the definitions (rather than the current - * executable name). Down case the upper cased name. - */ - if (pzLeader != NULL) - fputs( pzLeader, stdout ); - - { - tSCC zStdout[] = "stdout"; - tCC* pzOutName; - - { - time_t curTime = time( NULL ); - struct tm* pTime = localtime( &curTime ); - strftime(zTimeBuf, AO_NAME_SIZE, "%A %B %e, %Y at %r %Z", pTime ); - } - - if (HAVE_OPT( SCRIPT )) - pzOutName = OPT_ARG( SCRIPT ); - else pzOutName = zStdout; - - if ((pzLeader == NULL) && (pzShell != NULL)) - printf( "#! %s\n", pzShell ); - - printf( zPreamble, zStartMarker, pzOutName, zTimeBuf ); - } - - /* - * Get a copy of the original program name in lower case - */ - { - char* pzPN = zTimeBuf; - tCC* pz = pOpts->pzPROGNAME; - for (;;) { - if ((*pzPN++ = tolower( *pz++ )) == '\0') - break; - } - } - - printf( zEndPreamble, pOpts->pzPROGNAME ); - - pOpts->pzProgPath = pOpts->pzProgName = zTimeBuf; - textToVariable( pOpts, TT_LONGUSAGE, NULL ); - textToVariable( pOpts, TT_USAGE, NULL ); - - { - tOptDesc* pOptDesc = pOpts->pOptDesc; - int optionCt = pOpts->optCt; - - for (;;) { - if (pOptDesc->pOptProc == optionPrintVersion) { - textToVariable( pOpts, TT_VERSION, pOptDesc ); - break; - } - - if (--optionCt <= 0) - break; - pOptDesc++; - } - } -} - - -static void -emitSetup( tOptions* pOpts ) -{ - tOptDesc* pOptDesc = pOpts->pOptDesc; - int optionCt = pOpts->presetOptCt; - char const* pzFmt; - char const* pzDefault; - - for (;optionCt > 0; pOptDesc++, --optionCt) { - char zVal[16]; - - /* - * Options that are either usage documentation or are compiled out - * are not to be processed. - */ - if (SKIP_OPT(pOptDesc) || (pOptDesc->pz_NAME == NULL)) - continue; - - if (pOptDesc->optMaxCt > 1) - pzFmt = zMultiDef; - else pzFmt = zSingleDef; - - /* - * IF this is an enumeration/bitmask option, then convert the value - * to a string before printing the default value. - */ - switch (OPTST_GET_ARGTYPE(pOptDesc->fOptState)) { - case OPARG_TYPE_ENUMERATION: - (*(pOptDesc->pOptProc))( (tOptions*)2UL, pOptDesc ); - pzDefault = pOptDesc->optArg.argString; - break; - - /* - * Numeric and membership bit options are just printed as a number. - */ - case OPARG_TYPE_NUMERIC: - snprintf( zVal, sizeof( zVal ), "%d", - (int)pOptDesc->optArg.argInt ); - pzDefault = zVal; - break; - - case OPARG_TYPE_MEMBERSHIP: - snprintf( zVal, sizeof( zVal ), "%lu", - (unsigned long)pOptDesc->optArg.argIntptr ); - pzDefault = zVal; - break; - - case OPARG_TYPE_BOOLEAN: - pzDefault = (pOptDesc->optArg.argBool) ? "true" : "false"; - break; - - default: - if (pOptDesc->optArg.argString == NULL) { - if (pzFmt == zSingleDef) - pzFmt = zSingleNoDef; - pzDefault = NULL; - } - else - pzDefault = pOptDesc->optArg.argString; - } - - printf( pzFmt, pOpts->pzPROGNAME, pOptDesc->pz_NAME, pzDefault ); - } -} - - -static void -printOptionAction( tOptions* pOpts, tOptDesc* pOptDesc ) -{ - if (pOptDesc->pOptProc == optionPrintVersion) - printf( zTextExit, pOpts->pzPROGNAME, "VERSION" ); - - else if (pOptDesc->pOptProc == optionPagedUsage) - printf( zPagedUsageExit, pOpts->pzPROGNAME ); - - else if (pOptDesc->pOptProc == optionLoadOpt) { - printf( zCmdFmt, "echo 'Warning: Cannot load options files' >&2" ); - printf( zCmdFmt, "OPT_ARG_NEEDED=YES" ); - - } else if (pOptDesc->pz_NAME == NULL) { - - if (pOptDesc->pOptProc == NULL) { - printf( zCmdFmt, "echo 'Warning: Cannot save options files' " - ">&2" ); - printf( zCmdFmt, "OPT_ARG_NEEDED=OK" ); - } else - printf( zTextExit, pOpts->pzPROGNAME, "LONGUSAGE" ); - - } else { - if (pOptDesc->optMaxCt == 1) - printf( zSingleArg, pOpts->pzPROGNAME, pOptDesc->pz_NAME ); - else { - if ((unsigned)pOptDesc->optMaxCt < NOLIMIT) - printf( zCountTest, pOpts->pzPROGNAME, - pOptDesc->pz_NAME, pOptDesc->optMaxCt ); - - printf( zMultiArg, pOpts->pzPROGNAME, pOptDesc->pz_NAME ); - } - - /* - * Fix up the args. - */ - if (OPTST_GET_ARGTYPE(pOptDesc->fOptState) == OPARG_TYPE_NONE) { - printf( zCantArg, pOpts->pzPROGNAME, pOptDesc->pz_NAME ); - - } else if (pOptDesc->fOptState & OPTST_ARG_OPTIONAL) { - printf( zMayArg, pOpts->pzPROGNAME, pOptDesc->pz_NAME ); - - } else { - fputs( zMustArg, stdout ); - } - } - fputs( zOptionEndSelect, stdout ); -} - - -static void -printOptionInaction( tOptions* pOpts, tOptDesc* pOptDesc ) -{ - if (pOptDesc->pOptProc == optionLoadOpt) { - printf( zCmdFmt, "echo 'Warning: Cannot suppress the loading of " - "options files' >&2" ); - - } else if (pOptDesc->optMaxCt == 1) - printf( zNoSingleArg, pOpts->pzPROGNAME, - pOptDesc->pz_NAME, pOptDesc->pz_DisablePfx ); - else - printf( zNoMultiArg, pOpts->pzPROGNAME, - pOptDesc->pz_NAME, pOptDesc->pz_DisablePfx ); - - printf( zCmdFmt, "OPT_ARG_NEEDED=NO" ); - fputs( zOptionEndSelect, stdout ); -} - - -static void -emitFlag( tOptions* pOpts ) -{ - tOptDesc* pOptDesc = pOpts->pOptDesc; - int optionCt = pOpts->optCt; - - fputs( zOptionCase, stdout ); - - for (;optionCt > 0; pOptDesc++, --optionCt) { - - if (SKIP_OPT(pOptDesc)) - continue; - - if (isprint( pOptDesc->optValue )) { - printf( zOptionFlag, pOptDesc->optValue ); - printOptionAction( pOpts, pOptDesc ); - } - } - printf( zOptionUnknown, "flag", pOpts->pzPROGNAME ); -} - - -/* - * Emit the match text for a long option - */ -static void -emitMatchExpr( tCC* pzMatchName, tOptDesc* pCurOpt, tOptions* pOpts ) -{ - tOptDesc* pOD = pOpts->pOptDesc; - int oCt = pOpts->optCt; - int min = 1; - char zName[ 256 ]; - char* pz = zName; - - for (;;) { - int matchCt = 0; - - /* - * Omit the current option, Documentation opts and compiled out opts. - */ - if ((pOD == pCurOpt) || SKIP_OPT(pOD)){ - if (--oCt <= 0) - break; - pOD++; - continue; - } - - /* - * Check each character of the name case insensitively. - * They must not be the same. They cannot be, because it would - * not compile correctly if they were. - */ - while ( toupper( pOD->pz_Name[matchCt] ) - == toupper( pzMatchName[matchCt] )) - matchCt++; - - if (matchCt > min) - min = matchCt; - - /* - * Check the disablement name, too. - */ - if (pOD->pz_DisableName != NULL) { - matchCt = 0; - while ( toupper( pOD->pz_DisableName[matchCt] ) - == toupper( pzMatchName[matchCt] )) - matchCt++; - if (matchCt > min) - min = matchCt; - } - if (--oCt <= 0) - break; - pOD++; - } - - /* - * IF the 'min' is all or one short of the name length, - * THEN the entire string must be matched. - */ - if ( (pzMatchName[min ] == NUL) - || (pzMatchName[min+1] == NUL) ) - printf( zOptionFullName, pzMatchName ); - - else { - int matchCt = 0; - for (; matchCt <= min; matchCt++) - *pz++ = pzMatchName[matchCt]; - - for (;;) { - *pz = NUL; - printf( zOptionPartName, zName ); - *pz++ = pzMatchName[matchCt++]; - if (pzMatchName[matchCt] == NUL) { - *pz = NUL; - printf( zOptionFullName, zName ); - break; - } - } - } -} - - -/* - * Emit GNU-standard long option handling code - */ -static void -emitLong( tOptions* pOpts ) -{ - tOptDesc* pOD = pOpts->pOptDesc; - int ct = pOpts->optCt; - - fputs( zOptionCase, stdout ); - - /* - * do each option, ... - */ - do { - /* - * Documentation & compiled-out options - */ - if (SKIP_OPT(pOD)) - continue; - - emitMatchExpr( pOD->pz_Name, pOD, pOpts ); - printOptionAction( pOpts, pOD ); - - /* - * Now, do the same thing for the disablement version of the option. - */ - if (pOD->pz_DisableName != NULL) { - emitMatchExpr( pOD->pz_DisableName, pOD, pOpts ); - printOptionInaction( pOpts, pOD ); - } - } while (pOD++, --ct > 0); - - printf( zOptionUnknown, "option", pOpts->pzPROGNAME ); -} - - -static void -openOutput( char const* pzFile ) -{ - FILE* fp; - char* pzData = NULL; - struct stat stbf; - - do { - char* pzScan; - size_t sizeLeft; - - /* - * IF we cannot stat the file, - * THEN assume we are creating a new file. - * Skip the loading of the old data. - */ - if (stat( pzFile, &stbf ) != 0) - break; - - /* - * The file must be a regular file - */ - if (! S_ISREG( stbf.st_mode )) { - fprintf( stderr, zNotFile, pzFile ); - exit( EXIT_FAILURE ); - } - - pzData = AGALOC(stbf.st_size + 1, "file data"); - fp = fopen( pzFile, "r" FOPEN_BINARY_FLAG ); - - sizeLeft = (unsigned)stbf.st_size; - pzScan = pzData; - - /* - * Read in all the data as fast as our OS will let us. - */ - for (;;) { - int inct = fread( (void*)pzScan, (size_t)1, sizeLeft, fp); - if (inct == 0) - break; - - pzScan += inct; - sizeLeft -= inct; - - if (sizeLeft == 0) - break; - } - - /* - * NUL-terminate the leader and look for the trailer - */ - *pzScan = '\0'; - fclose( fp ); - pzScan = strstr( pzData, zStartMarker ); - if (pzScan == NULL) { - pzTrailer = pzData; - break; - } - - *(pzScan++) = NUL; - pzScan = strstr( pzScan, zTrailerMarker ); - if (pzScan == NULL) { - pzTrailer = pzData; - break; - } - - /* - * Check to see if the data contains - * our marker. If it does, then we will skip over it - */ - pzTrailer = pzScan + sizeof( zTrailerMarker ) - 1; - pzLeader = pzData; - } while (AG_FALSE); - - freopen( pzFile, "w" FOPEN_BINARY_FLAG, stdout ); -} - - -/*=export_func genshelloptUsage - * private: - * what: The usage function for the genshellopt generated program - * - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + int + exitCode + usage text type to produce + - * - * doc: - * This function is used to create the usage strings for the option - * processing shell script code. Two child processes are spawned - * each emitting the usage text in either the short (error exit) - * style or the long style. The generated program will capture this - * and create shell script variables containing the two types of text. -=*/ -void -genshelloptUsage( tOptions* pOpts, int exitCode ) -{ -#if defined(__windows__) && !defined(__CYGWIN__) - optionUsage( pOpts, exitCode ); -#else - /* - * IF not EXIT_SUCCESS, - * THEN emit the short form of usage. - */ - if (exitCode != EXIT_SUCCESS) - optionUsage( pOpts, exitCode ); - fflush( stderr ); - fflush( stdout ); - - option_usage_fp = stdout; - - /* - * First, print our usage - */ - switch (fork()) { - case -1: - optionUsage( pOpts, EXIT_FAILURE ); - /*NOTREACHED*/ - _exit( EXIT_FAILURE ); - - case 0: - pagerState = PAGER_STATE_CHILD; - optionUsage( pOpts, EXIT_SUCCESS ); - /*NOTREACHED*/ - _exit( EXIT_FAILURE ); - - default: - { - int sts; - wait( &sts ); - } - } - - /* - * Generate the pzProgName, since optionProcess() normally - * gets it from the command line - */ - { - char* pz; - AGDUPSTR( pz, pShellParseOptions->pzPROGNAME, "program name" ); - pShellParseOptions->pzProgName = pz; - while (*pz != NUL) { - *pz = tolower( *pz ); - pz++; - } - } - - /* - * Separate the makeshell usage from the client usage - */ - fprintf( option_usage_fp, zGenshell, pShellParseOptions->pzProgName ); - fflush( option_usage_fp ); - - /* - * Now, print the client usage. - */ - switch (fork()) { - case 0: - pagerState = PAGER_STATE_CHILD; - /*FALLTHROUGH*/ - case -1: - optionUsage( pShellParseOptions, EXIT_FAILURE ); - - default: - { - int sts; - wait( &sts ); - } - } - - exit( EXIT_SUCCESS ); -#endif -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/makeshell.c */ diff --git a/contrib/ntp/libopts/nested.c b/contrib/ntp/libopts/nested.c deleted file mode 100644 index b39f8d1fa..000000000 --- a/contrib/ntp/libopts/nested.c +++ /dev/null @@ -1,733 +0,0 @@ - -/* - * $Id: nested.c,v 4.14 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-26 11:04:35 bkorb" - * - * Automated Options Nested Values module. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -removeBackslashes( char* pzSrc ); - -static char const* -scanQuotedString( char const* pzTxt ); - -static tOptionValue* -addStringValue( void** pp, char const* pzName, size_t nameLen, - char const* pzValue, size_t dataLen ); - -static tOptionValue* -addBoolValue( void** pp, char const* pzName, size_t nameLen, - char const* pzValue, size_t dataLen ); - -static tOptionValue* -addNumberValue( void** pp, char const* pzName, size_t nameLen, - char const* pzValue, size_t dataLen ); - -static tOptionValue* -addNestedValue( void** pp, char const* pzName, size_t nameLen, - char* pzValue, size_t dataLen ); - -static char const* -scanNameEntry(char const* pzName, tOptionValue* pRes); - -static char const* -scanXmlEntry( char const* pzName, tOptionValue* pRes ); - -static void -unloadNestedArglist( tArgList* pAL ); - -static void -sortNestedList( tArgList* pAL ); -/* = = = END-STATIC-FORWARD = = = */ - -/* removeBackslashes - * - * This function assumes that all newline characters were preceeded by - * backslashes that need removal. - */ -static void -removeBackslashes( char* pzSrc ) -{ - char* pzD = strchr(pzSrc, '\n'); - - if (pzD == NULL) - return; - *--pzD = '\n'; - - for (;;) { - char ch = ((*pzD++) = *(pzSrc++)); - switch (ch) { - case '\n': *--pzD = ch; break; - case NUL: return; - default: - ; - } - } -} - - -/* scanQuotedString - * - * Find the end of a quoted string, skipping escaped quote characters. - */ -static char const* -scanQuotedString( char const* pzTxt ) -{ - char q = *(pzTxt++); /* remember the type of quote */ - - for (;;) { - char ch = *(pzTxt++); - if (ch == NUL) - return pzTxt-1; - - if (ch == q) - return pzTxt; - - if (ch == '\\') { - ch = *(pzTxt++); - /* - * IF the next character is NUL, drop the backslash, too. - */ - if (ch == NUL) - return pzTxt - 2; - - /* - * IF the quote character or the escape character were escaped, - * then skip both, as long as the string does not end. - */ - if ((ch == q) || (ch == '\\')) { - if (*(pzTxt++) == NUL) - return pzTxt-1; - } - } - } -} - - -/* addStringValue - * - * Associate a name with either a string or no value. - */ -static tOptionValue* -addStringValue( void** pp, char const* pzName, size_t nameLen, - char const* pzValue, size_t dataLen ) -{ - tOptionValue* pNV; - size_t sz = nameLen + dataLen + sizeof(*pNV); - - pNV = AGALOC( sz, "option name/str value pair" ); - if (pNV == NULL) - return NULL; - - if (pzValue == NULL) { - pNV->valType = OPARG_TYPE_NONE; - pNV->pzName = pNV->v.strVal; - - } else { - pNV->valType = OPARG_TYPE_STRING; - if (dataLen > 0) - memcpy( pNV->v.strVal, pzValue, dataLen ); - pNV->v.strVal[dataLen] = NUL; - pNV->pzName = pNV->v.strVal + dataLen + 1; - } - - memcpy( pNV->pzName, pzName, nameLen ); - pNV->pzName[ nameLen ] = NUL; - addArgListEntry( pp, pNV ); - return pNV; -} - - -/* addBoolValue - * - * Associate a name with either a string or no value. - */ -static tOptionValue* -addBoolValue( void** pp, char const* pzName, size_t nameLen, - char const* pzValue, size_t dataLen ) -{ - tOptionValue* pNV; - size_t sz = nameLen + sizeof(*pNV) + 1; - - pNV = AGALOC( sz, "option name/bool value pair" ); - if (pNV == NULL) - return NULL; - while (isspace( (int)*pzValue ) && (dataLen > 0)) { - dataLen--; pzValue++; - } - if (dataLen == 0) - pNV->v.boolVal = 0; - else if (isdigit( (int)*pzValue )) - pNV->v.boolVal = atoi( pzValue ); - else switch (*pzValue) { - case 'f': - case 'F': - case 'n': - case 'N': - pNV->v.boolVal = 0; break; - default: - pNV->v.boolVal = 1; - } - - pNV->valType = OPARG_TYPE_BOOLEAN; - pNV->pzName = (char*)(pNV + 1); - memcpy( pNV->pzName, pzName, nameLen ); - pNV->pzName[ nameLen ] = NUL; - addArgListEntry( pp, pNV ); - return pNV; -} - - -/* addNumberValue - * - * Associate a name with either a string or no value. - */ -static tOptionValue* -addNumberValue( void** pp, char const* pzName, size_t nameLen, - char const* pzValue, size_t dataLen ) -{ - tOptionValue* pNV; - size_t sz = nameLen + sizeof(*pNV) + 1; - - pNV = AGALOC( sz, "option name/bool value pair" ); - if (pNV == NULL) - return NULL; - while (isspace( (int)*pzValue ) && (dataLen > 0)) { - dataLen--; pzValue++; - } - if (dataLen == 0) - pNV->v.boolVal = 0; - else - pNV->v.boolVal = atoi( pzValue ); - - pNV->valType = OPARG_TYPE_NUMERIC; - pNV->pzName = (char*)(pNV + 1); - memcpy( pNV->pzName, pzName, nameLen ); - pNV->pzName[ nameLen ] = NUL; - addArgListEntry( pp, pNV ); - return pNV; -} - - -/* addNestedValue - * - * Associate a name with either a string or no value. - */ -static tOptionValue* -addNestedValue( void** pp, char const* pzName, size_t nameLen, - char* pzValue, size_t dataLen ) -{ - tOptionValue* pNV; - - if (dataLen == 0) { - size_t sz = nameLen + sizeof(*pNV) + 1; - pNV = AGALOC( sz, "empty nested value pair" ); - if (pNV == NULL) - return NULL; - pNV->v.nestVal = NULL; - pNV->valType = OPARG_TYPE_HIERARCHY; - pNV->pzName = (char*)(pNV + 1); - memcpy( pNV->pzName, pzName, nameLen ); - pNV->pzName[ nameLen ] = NUL; - - } else { - pNV = optionLoadNested( pzValue, pzName, nameLen ); - } - - if (pNV != NULL) - addArgListEntry( pp, pNV ); - - return pNV; -} - - -/* scanNameEntry - * - * We have an entry that starts with a name. Find the end of it, cook it - * (if called for) and create the name/value association. - */ -static char const* -scanNameEntry(char const* pzName, tOptionValue* pRes) -{ - tOptionValue* pNV; - char const * pzScan = pzName+1; - char const * pzVal; - size_t nameLen = 1; - size_t dataLen = 0; - - while (ISNAMECHAR( (int)*pzScan )) { pzScan++; nameLen++; } - - while (isspace( (int)*pzScan )) { - char ch = *(pzScan++); - if ((ch == '\n') || (ch == ',')) { - addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL,(size_t)0); - return pzScan - 1; - } - } - - switch (*pzScan) { - case '=': - case ':': - while (isspace( (int)*++pzScan )) ; - switch (*pzScan) { - case ',': goto comma_char; - case '"': - case '\'': goto quote_char; - case NUL: goto nul_byte; - default: goto default_char; - } - - case ',': - comma_char: - pzScan++; - /* FALLTHROUGH */ - - case NUL: - nul_byte: - addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL, (size_t)0); - break; - - case '"': - case '\'': - quote_char: - pzVal = pzScan; - pzScan = scanQuotedString( pzScan ); - dataLen = pzScan - pzVal; - pNV = addStringValue( &(pRes->v.nestVal), pzName, nameLen, pzVal, - dataLen ); - if ((pNV != NULL) && (option_load_mode == OPTION_LOAD_COOKED)) - ao_string_cook( pNV->v.strVal, NULL ); - break; - - default: - default_char: - /* - * We have found some strange text value. It ends with a newline - * or a comma. - */ - pzVal = pzScan; - for (;;) { - char ch = *(pzScan++); - switch (ch) { - case NUL: - pzScan--; - dataLen = pzScan - pzVal; - goto string_done; - /* FALLTHROUGH */ - - case '\n': - if ( (pzScan > pzVal + 2) - && (pzScan[-2] == '\\') - && (pzScan[ 0] != NUL)) - continue; - /* FALLTHROUGH */ - - case ',': - dataLen = (pzScan - pzVal) - 1; - string_done: - pNV = addStringValue( &(pRes->v.nestVal), pzName, nameLen, - pzVal, dataLen ); - if (pNV != NULL) - removeBackslashes( pNV->v.strVal ); - goto leave_scan_name; - } - } - break; - } leave_scan_name:; - - return pzScan; -} - - -/* scanXmlEntry - * - * We've found a '<' character. We ignore this if it is a comment or a - * directive. If it is something else, then whatever it is we are looking - * at is bogus. Returning NULL stops processing. - */ -static char const* -scanXmlEntry( char const* pzName, tOptionValue* pRes ) -{ - size_t nameLen = 1, valLen = 0; - char const* pzScan = ++pzName; - char const* pzVal; - tOptionValue valu; - tOptionValue* pNewVal; - tOptionLoadMode save_mode = option_load_mode; - - if (! isalpha((int)*pzName)) { - switch (*pzName) { - default: - pzName = NULL; - break; - - case '!': - pzName = strstr( pzName, "-->" ); - if (pzName != NULL) - pzName += 3; - break; - - case '?': - pzName = strchr( pzName, '>' ); - if (pzName != NULL) - pzName++; - break; - } - return pzName; - } - - while (isalpha( (int)*++pzScan )) nameLen++; - if (nameLen > 64) - return NULL; - valu.valType = OPARG_TYPE_STRING; - - switch (*pzScan) { - case ' ': - case '\t': - pzScan = parseAttributes( - NULL, (char*)pzScan, &option_load_mode, &valu ); - if (*pzScan == '>') { - pzScan++; - break; - } - - if (*pzScan != '/') { - option_load_mode = save_mode; - return NULL; - } - /* FALLTHROUGH */ - - case '/': - if (*++pzScan != '>') { - option_load_mode = save_mode; - return NULL; - } - addStringValue(&(pRes->v.nestVal), pzName, nameLen, NULL, (size_t)0); - option_load_mode = save_mode; - return pzScan+2; - - default: - option_load_mode = save_mode; - return NULL; - - case '>': - pzScan++; - break; - } - - pzVal = pzScan; - - { - char z[68]; - char* pzD = z; - int ct = nameLen; - char const* pzS = pzName; - - *(pzD++) = '<'; - *(pzD++) = '/'; - - do { - *(pzD++) = *(pzS++); - } while (--ct > 0); - *(pzD++) = '>'; - *pzD = NUL; - - pzScan = strstr( pzScan, z ); - if (pzScan == NULL) { - option_load_mode = save_mode; - return NULL; - } - valLen = (pzScan - pzVal); - pzScan += nameLen + 3; - while (isspace( (int)*pzScan )) pzScan++; - } - - switch (valu.valType) { - case OPARG_TYPE_NONE: - addStringValue( &(pRes->v.nestVal), pzName, nameLen, NULL, (size_t)0); - break; - - case OPARG_TYPE_STRING: - pNewVal = addStringValue( - &(pRes->v.nestVal), pzName, nameLen, pzVal, valLen); - - if (option_load_mode == OPTION_LOAD_KEEP) - break; - mungeString( pNewVal->v.strVal, option_load_mode ); - break; - - case OPARG_TYPE_BOOLEAN: - addBoolValue( &(pRes->v.nestVal), pzName, nameLen, pzVal, valLen ); - break; - - case OPARG_TYPE_NUMERIC: - addNumberValue( &(pRes->v.nestVal), pzName, nameLen, pzVal, valLen ); - break; - - case OPARG_TYPE_HIERARCHY: - { - char* pz = AGALOC( valLen+1, "hierarchical scan" ); - if (pz == NULL) - break; - memcpy( pz, pzVal, valLen ); - pz[valLen] = NUL; - addNestedValue( &(pRes->v.nestVal), pzName, nameLen, pz, valLen ); - AGFREE(pz); - break; - } - - case OPARG_TYPE_ENUMERATION: - case OPARG_TYPE_MEMBERSHIP: - default: - break; - } - - option_load_mode = save_mode; - return pzScan; -} - - -/* unloadNestedArglist - * - * Deallocate a list of option arguments. This must have been gotten from - * a hierarchical option argument, not a stacked list of strings. It is - * an internal call, so it is not validated. The caller is responsible for - * knowing what they are doing. - */ -static void -unloadNestedArglist( tArgList* pAL ) -{ - int ct = pAL->useCt; - tCC** ppNV = pAL->apzArgs; - - while (ct-- > 0) { - tOptionValue* pNV = (tOptionValue*)(void*)*(ppNV++); - if (pNV->valType == OPARG_TYPE_HIERARCHY) - unloadNestedArglist( pNV->v.nestVal ); - AGFREE( pNV ); - } - - AGFREE( (void*)pAL ); -} - - -/*=export_func optionUnloadNested - * - * what: Deallocate the memory for a nested value - * arg: + tOptionValue const * + pOptVal + the hierarchical value + - * - * doc: - * A nested value needs to be deallocated. The pointer passed in should - * have been gotten from a call to @code{configFileLoad()} (See - * @pxref{libopts-configFileLoad}). -=*/ -void -optionUnloadNested( tOptionValue const * pOV ) -{ - if (pOV == NULL) return; - if (pOV->valType != OPARG_TYPE_HIERARCHY) { - errno = EINVAL; - return; - } - - unloadNestedArglist( pOV->v.nestVal ); - - AGFREE( (void*)pOV ); -} - - -/* sortNestedList - * - * This is a _stable_ sort. The entries are sorted alphabetically, - * but within entries of the same name the ordering is unchanged. - * Typically, we also hope the input is sorted. - */ -static void -sortNestedList( tArgList* pAL ) -{ - int ix; - int lm = pAL->useCt; - - /* - * This loop iterates "useCt" - 1 times. - */ - for (ix = 0; ++ix < lm;) { - int iy = ix-1; - tOptionValue* pNewNV = (tOptionValue*)(void*)(pAL->apzArgs[ix]); - tOptionValue* pOldNV = (tOptionValue*)(void*)(pAL->apzArgs[iy]); - - /* - * For as long as the new entry precedes the "old" entry, - * move the old pointer. Stop before trying to extract the - * "-1" entry. - */ - while (strcmp( pOldNV->pzName, pNewNV->pzName ) > 0) { - pAL->apzArgs[iy+1] = (void*)pOldNV; - pOldNV = (tOptionValue*)(void*)(pAL->apzArgs[--iy]); - if (iy < 0) - break; - } - - /* - * Always store the pointer. Sometimes it is redundant, - * but the redundancy is cheaper than a test and branch sequence. - */ - pAL->apzArgs[iy+1] = (void*)pNewNV; - } -} - - -/* optionLoadNested - * private: - * - * what: parse a hierarchical option argument - * arg: + char const* + pzTxt + the text to scan + - * arg: + char const* + pzName + the name for the text + - * arg: + size_t + nameLen + the length of "name" + - * - * ret_type: tOptionValue* - * ret_desc: An allocated, compound value structure - * - * doc: - * A block of text represents a series of values. It may be an - * entire configuration file, or it may be an argument to an - * option that takes a hierarchical value. - */ -LOCAL tOptionValue* -optionLoadNested(char const* pzTxt, char const* pzName, size_t nameLen) -{ - tOptionValue* pRes; - tArgList* pAL; - - /* - * Make sure we have some data and we have space to put what we find. - */ - if (pzTxt == NULL) { - errno = EINVAL; - return NULL; - } - while (isspace( (int)*pzTxt )) pzTxt++; - if (*pzTxt == NUL) { - errno = ENOENT; - return NULL; - } - pRes = AGALOC( sizeof(*pRes) + nameLen + 1, "nested args" ); - if (pRes == NULL) { - errno = ENOMEM; - return NULL; - } - pRes->valType = OPARG_TYPE_HIERARCHY; - pRes->pzName = (char*)(pRes + 1); - memcpy( pRes->pzName, pzName, nameLen ); - pRes->pzName[ nameLen ] = NUL; - - pAL = AGALOC( sizeof(*pAL), "nested arg list" ); - if (pAL == NULL) { - AGFREE( pRes ); - return NULL; - } - pRes->v.nestVal = pAL; - pAL->useCt = 0; - pAL->allocCt = MIN_ARG_ALLOC_CT; - - /* - * Scan until we hit a NUL. - */ - do { - while (isspace( (int)*pzTxt )) pzTxt++; - if (isalpha( (int)*pzTxt )) { - pzTxt = scanNameEntry( pzTxt, pRes ); - } - else switch (*pzTxt) { - case NUL: goto scan_done; - case '<': pzTxt = scanXmlEntry( pzTxt, pRes ); - if (*pzTxt == ',') pzTxt++; break; - case '#': pzTxt = strchr( pzTxt, '\n' ); break; - default: goto woops; - } - } while (pzTxt != NULL); scan_done:; - - pAL = pRes->v.nestVal; - if (pAL->useCt != 0) { - sortNestedList( pAL ); - return pRes; - } - - woops: - AGFREE( pRes->v.nestVal ); - AGFREE( pRes ); - return NULL; -} - - -/*=export_func optionNestedVal - * private: - * - * what: parse a hierarchical option argument - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * Nested value was found on the command line -=*/ -void -optionNestedVal( tOptions* pOpts, tOptDesc* pOD ) -{ - tOptionValue* pOV = optionLoadNested( - pOD->optArg.argString, pOD->pz_Name, strlen(pOD->pz_Name)); - - if (pOV != NULL) - addArgListEntry( &(pOD->optCookie), (void*)pOV ); -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/nested.c */ diff --git a/contrib/ntp/libopts/numeric.c b/contrib/ntp/libopts/numeric.c deleted file mode 100644 index 05ee9b573..000000000 --- a/contrib/ntp/libopts/numeric.c +++ /dev/null @@ -1,93 +0,0 @@ - -/* - * $Id: numeric.c,v 4.11 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:28:20 bkorb" - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/*=export_func optionNumericVal - * private: - * - * what: Decipher a boolean value - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * Decipher a numeric value. -=*/ -void -optionNumericVal( tOptions* pOpts, tOptDesc* pOD ) -{ - char* pz; - long val; - - /* - * Numeric options may have a range associated with it. - * If it does, the usage procedure requests that it be - * emitted by passing a NULL pOD pointer. - */ - if ((pOD == NULL) || (pOD->optArg.argString == NULL)) - return; - - val = strtol( pOD->optArg.argString, &pz, 0 ); - if (*pz != NUL) { - fprintf( stderr, zNotNumber, pOpts->pzProgName, pOD->optArg.argString ); - (*(pOpts->pUsageProc))(pOpts, EXIT_FAILURE); - } - - if (pOD->fOptState & OPTST_ALLOC_ARG) { - AGFREE(pOD->optArg.argString); - pOD->fOptState &= ~OPTST_ALLOC_ARG; - } - - pOD->optArg.argInt = val; -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/numeric.c */ diff --git a/contrib/ntp/libopts/pgusage.c b/contrib/ntp/libopts/pgusage.c deleted file mode 100644 index c417c63d5..000000000 --- a/contrib/ntp/libopts/pgusage.c +++ /dev/null @@ -1,157 +0,0 @@ - -/* - * $Id: pgusage.c,v 4.12 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-07-16 08:13:26 bkorb" - * - * Automated Options Paged Usage module. - * - * This routine will run run-on options through a pager so the - * user may examine, print or edit them at their leisure. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -tePagerState pagerState = PAGER_STATE_INITIAL; - -/*=export_func optionPagedUsage - * private: - * - * what: Decipher a boolean value - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * Run the usage output through a pager. - * This is very handy if it is very long. -=*/ -void -optionPagedUsage( tOptions* pOptions, tOptDesc* pOD ) -{ -#if defined(__windows__) && !defined(__CYGWIN__) - (*pOptions->pUsageProc)( pOptions, EXIT_SUCCESS ); -#else - static pid_t my_pid; - char zPageUsage[ 1024 ]; - - /* - * IF we are being called after the usage proc is done - * (and thus has called "exit(2)") - * THEN invoke the pager to page through the usage file we created. - */ - switch (pagerState) { - case PAGER_STATE_INITIAL: - { - my_pid = getpid(); -#ifdef HAVE_SNPRINTF - snprintf(zPageUsage, sizeof(zPageUsage), "/tmp/use.%lu", (tAoUL)my_pid); -#else - sprintf( zPageUsage, "/tmp/use.%lu", (tAoUL)my_pid ); -#endif - unlink( zPageUsage ); - - /* - * Set usage output to this temporary file - */ - option_usage_fp = fopen( zPageUsage, "w" FOPEN_BINARY_FLAG ); - if (option_usage_fp == NULL) - _exit( EXIT_FAILURE ); - - pagerState = PAGER_STATE_READY; - - /* - * Set up so this routine gets called during the exit logic - */ - atexit( (void(*)(void))optionPagedUsage ); - - /* - * The usage procedure will now put the usage information into - * the temporary file we created above. - */ - (*pOptions->pUsageProc)( pOptions, EXIT_SUCCESS ); - - /*NOTREACHED*/ - _exit( EXIT_FAILURE ); - } - - case PAGER_STATE_READY: - { - tSCC zPage[] = "%1$s /tmp/use.%2$lu ; rm -f /tmp/use.%2$lu"; - tCC* pzPager = (tCC*)getenv( "PAGER" ); - - /* - * Use the "more(1)" program if "PAGER" has not been defined - */ - if (pzPager == NULL) - pzPager = "more"; - - /* - * Page the file and remove it when done. - */ -#ifdef HAVE_SNPRINTF - snprintf(zPageUsage, sizeof(zPageUsage), zPage, pzPager, (tAoUL)my_pid); -#else - sprintf( zPageUsage, zPage, pzPager, (tAoUL)my_pid ); -#endif - fclose( stderr ); - dup2( STDOUT_FILENO, STDERR_FILENO ); - - (void)system( zPageUsage ); - } - - case PAGER_STATE_CHILD: - /* - * This is a child process used in creating shell script usage. - */ - break; - } -#endif -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/pgusage.c */ diff --git a/contrib/ntp/libopts/proto.h b/contrib/ntp/libopts/proto.h deleted file mode 100644 index e87ab87bd..000000000 --- a/contrib/ntp/libopts/proto.h +++ /dev/null @@ -1,91 +0,0 @@ -/* -*- buffer-read-only: t -*- vi: set ro: - * - * Prototypes for autoopts - * Generated Sat May 5 12:02:36 PDT 2007 - */ -#ifndef AUTOOPTS_PROTO_H_GUARD -#define AUTOOPTS_PROTO_H_GUARD 1 -#ifndef LOCAL -# define LOCAL extern -# define REDEF_LOCAL 1 -#else -# undef REDEF_LOCAL -#endif -/*\n * Extracted from autoopts.c\n */ -LOCAL void * -ao_malloc( size_t sz ); - -LOCAL void * -ao_realloc( void *p, size_t sz ); - -LOCAL void -ao_free( void *p ); - -LOCAL char * -ao_strdup( char const *str ); - -LOCAL tSuccess -handleOption( tOptions* pOpts, tOptState* pOptState ); - -LOCAL tSuccess -longOptionFind( tOptions* pOpts, char* pzOptName, tOptState* pOptState ); - -LOCAL tSuccess -shortOptionFind( tOptions* pOpts, uint_t optValue, tOptState* pOptState ); - -LOCAL tSuccess -doImmediateOpts( tOptions* pOpts ); - -LOCAL tSuccess -doRegularOpts( tOptions* pOpts ); - -/*\n * Extracted from configfile.c\n */ -LOCAL void -internalFileLoad( tOptions* pOpts ); - -LOCAL char* -parseAttributes( - tOptions* pOpts, - char* pzText, - tOptionLoadMode* pMode, - tOptionValue* pType ); - -LOCAL tSuccess -validateOptionsStruct( tOptions* pOpts, char const* pzProgram ); - -/*\n * Extracted from environment.c\n */ -LOCAL void -doPrognameEnv( tOptions* pOpts, teEnvPresetType type ); - -LOCAL void -doEnvPresets( tOptions* pOpts, teEnvPresetType type ); - -/*\n * Extracted from load.c\n */ -LOCAL void -mungeString( char* pzTxt, tOptionLoadMode mode ); - -LOCAL void -loadOptionLine( - tOptions* pOpts, - tOptState* pOS, - char* pzLine, - tDirection direction, - tOptionLoadMode load_mode ); - -/*\n * Extracted from nested.c\n */ -LOCAL tOptionValue* -optionLoadNested(char const* pzTxt, char const* pzName, size_t nameLen); - -/*\n * Extracted from sort.c\n */ -LOCAL void -optionSort( tOptions* pOpts ); - -/*\n * Extracted from stack.c\n */ -LOCAL void -addArgListEntry( void** ppAL, void* entry ); - -#ifdef REDEF_LOCAL -# undef LOCAL -# define LOCAL -#endif -#endif /* AUTOOPTS_PROTO_H_GUARD */ diff --git a/contrib/ntp/libopts/putshell.c b/contrib/ntp/libopts/putshell.c deleted file mode 100644 index 93d9ef5f1..000000000 --- a/contrib/ntp/libopts/putshell.c +++ /dev/null @@ -1,335 +0,0 @@ - -/* - * $Id: putshell.c,v 4.18 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:29:39 bkorb" - * - * This module will interpret the options set in the tOptions - * structure and print them to standard out in a fashion that - * will allow them to be interpreted by the Bourne or Korn shells. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -putQuotedStr( tCC* pzStr ); -/* = = = END-STATIC-FORWARD = = = */ - -/* - * Make sure embedded single quotes come out okay. The initial quote has - * been emitted and the closing quote will be upon return. - */ -static void -putQuotedStr( tCC* pzStr ) -{ - /* - * Handle empty strings to make the rest of the logic simpler. - */ - if ((pzStr == NULL) || (*pzStr == NUL)) { - fputs( "''", stdout ); - return; - } - - /* - * Emit any single quotes/apostrophes at the start of the string and - * bail if that is all we need to do. - */ - while (*pzStr == '\'') { - fputs( "\\'", stdout ); - pzStr++; - } - if (*pzStr == NUL) - return; - - /* - * Start the single quote string - */ - fputc( '\'', stdout ); - for (;;) { - tCC* pz = strchr( pzStr, '\'' ); - if (pz == NULL) - break; - - /* - * Emit the string up to the single quote (apostrophe) we just found. - */ - (void)fwrite( pzStr, (size_t)(pz - pzStr), (size_t)1, stdout ); - fputc( '\'', stdout ); - pzStr = pz; - - /* - * Emit an escaped apostrophe for every one we find. - * If that ends the string, do not re-open the single quotes. - */ - while (*++pzStr == '\'') fputs( "\\'", stdout ); - if (*pzStr == NUL) - return; - - fputc( '\'', stdout ); - } - - /* - * If we broke out of the loop, we must still emit the remaining text - * and then close the single quote string. - */ - fputs( pzStr, stdout ); - fputc( '\'', stdout ); -} - - -/*=export_func optionPutShell - * what: write a portable shell script to parse options - * private: - * arg: tOptions*, pOpts, the program options descriptor - * doc: This routine will emit portable shell script text for parsing - * the options described in the option definitions. -=*/ -void -optionPutShell( tOptions* pOpts ) -{ - int optIx = 0; - tSCC zOptCtFmt[] = "OPTION_CT=%d\nexport OPTION_CT\n"; - tSCC zOptNumFmt[] = "%1$s_%2$s=%3$d # 0x%3$X\nexport %1$s_%2$s\n"; - tSCC zOptDisabl[] = "%1$s_%2$s=%3$s\nexport %1$s_%2$s\n"; - tSCC zOptValFmt[] = "%s_%s="; - tSCC zOptEnd[] = "\nexport %s_%s\n"; - tSCC zFullOptFmt[]= "%1$s_%2$s='%3$s'\nexport %1$s_%2$s\n"; - tSCC zEquivMode[] = "%1$s_%2$s_MODE='%3$s'\nexport %1$s_%2$s_MODE\n"; - - printf( zOptCtFmt, pOpts->curOptIdx-1 ); - - do { - tOptDesc* pOD = pOpts->pOptDesc + optIx; - - if (SKIP_OPT(pOD)) - continue; - - /* - * Equivalence classes are hard to deal with. Where the - * option data wind up kind of squishes around. For the purposes - * of emitting shell state, they are not recommended, but we'll - * do something. I guess we'll emit the equivalenced-to option - * at the point in time when the base option is found. - */ - if (pOD->optEquivIndex != NO_EQUIVALENT) - continue; /* equivalence to a different option */ - - /* - * Equivalenced to a different option. Process the current option - * as the equivalenced-to option. Keep the persistent state bits, - * but copy over the set-state bits. - */ - if (pOD->optActualIndex != optIx) { - tOptDesc* p = pOpts->pOptDesc + pOD->optActualIndex; - p->optArg = pOD->optArg; - p->fOptState &= OPTST_PERSISTENT_MASK; - p->fOptState |= pOD->fOptState & ~OPTST_PERSISTENT_MASK; - printf( zEquivMode, pOpts->pzPROGNAME, pOD->pz_NAME, p->pz_NAME ); - pOD = p; - } - - /* - * If the argument type is a set membership bitmask, then we always - * emit the thing. We do this because it will always have some sort - * of bitmask value and we need to emit the bit values. - */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_MEMBERSHIP) { - char const * pz; - uintptr_t val = 1; - printf( zOptNumFmt, pOpts->pzPROGNAME, pOD->pz_NAME, - (int)(uintptr_t)(pOD->optCookie) ); - pOD->optCookie = (void*)(uintptr_t)~0UL; - (*(pOD->pOptProc))( (tOptions*)2UL, pOD ); - - /* - * We are building the typeset list. The list returned starts with - * 'none + ' for use by option saving stuff. We must ignore that. - */ - pz = pOD->optArg.argString + 7; - while (*pz != NUL) { - printf( "typeset -x -i %s_", pOD->pz_NAME ); - pz += strspn( pz, " +\t\n\f" ); - for (;;) { - int ch = *(pz++); - if (islower( ch )) fputc( toupper( ch ), stdout ); - else if (isalnum( ch )) fputc( ch, stdout ); - else if (isspace( ch ) - || (ch == '+')) goto name_done; - else if (ch == NUL) { pz--; goto name_done; } - else fputc( '_', stdout ); - } name_done:; - printf( "=%1$lu # 0x%1$lX\n", (unsigned long)val ); - val <<= 1; - } - - AGFREE(pOD->optArg.argString); - pOD->optArg.argString = NULL; - pOD->fOptState &= ~OPTST_ALLOC_ARG; - continue; - } - - /* - * IF the option was either specified or it wakes up enabled, - * then we will emit information. Otherwise, skip it. - * The idea is that if someone defines an option to initialize - * enabled, we should tell our shell script that it is enabled. - */ - if (UNUSED_OPT( pOD ) && DISABLED_OPT( pOD )) - continue; - - /* - * Handle stacked arguments - */ - if ( (pOD->fOptState & OPTST_STACKED) - && (pOD->optCookie != NULL) ) { - tSCC zOptCookieCt[] = "%1$s_%2$s_CT=%3$d\nexport %1$s_%2$s_CT\n"; - - tArgList* pAL = (tArgList*)pOD->optCookie; - tCC** ppz = pAL->apzArgs; - int ct = pAL->useCt; - - printf( zOptCookieCt, pOpts->pzPROGNAME, pOD->pz_NAME, ct ); - - while (--ct >= 0) { - tSCC numarg_z[] = "%s_%s_%d="; - tSCC end_z[] = "\nexport %s_%s_%d\n"; - - printf( numarg_z, pOpts->pzPROGNAME, pOD->pz_NAME, - pAL->useCt - ct ); - putQuotedStr( *(ppz++) ); - printf( end_z, pOpts->pzPROGNAME, pOD->pz_NAME, - pAL->useCt - ct ); - } - } - - /* - * If the argument has been disabled, - * Then set its value to the disablement string - */ - else if ((pOD->fOptState & OPTST_DISABLED) != 0) - printf( zOptDisabl, pOpts->pzPROGNAME, pOD->pz_NAME, - (pOD->pz_DisablePfx != NULL) - ? pOD->pz_DisablePfx : "false" ); - - /* - * If the argument type is numeric, the last arg pointer - * is really the VALUE of the string that was pointed to. - */ - else if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NUMERIC) - printf( zOptNumFmt, pOpts->pzPROGNAME, pOD->pz_NAME, - (int)pOD->optArg.argInt ); - - /* - * If the argument type is an enumeration, then it is much - * like a text value, except we call the callback function - * to emit the value corresponding to the "optArg" number. - */ - else if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_ENUMERATION) { - printf( zOptValFmt, pOpts->pzPROGNAME, pOD->pz_NAME ); - fputc( '\'', stdout ); - (*(pOD->pOptProc))( (tOptions*)1UL, pOD ); - fputc( '\'', stdout ); - printf( zOptEnd, pOpts->pzPROGNAME, pOD->pz_NAME ); - } - - /* - * If the argument type is numeric, the last arg pointer - * is really the VALUE of the string that was pointed to. - */ - else if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_BOOLEAN) - printf( zFullOptFmt, pOpts->pzPROGNAME, pOD->pz_NAME, - (pOD->optArg.argBool == 0) ? "false" : "true" ); - - /* - * IF the option has an empty value, - * THEN we set the argument to the occurrence count. - */ - else if ( (pOD->optArg.argString == NULL) - || (pOD->optArg.argString[0] == NUL) ) - - printf( zOptNumFmt, pOpts->pzPROGNAME, pOD->pz_NAME, - pOD->optOccCt ); - - /* - * This option has a text value - */ - else { - printf( zOptValFmt, pOpts->pzPROGNAME, pOD->pz_NAME ); - putQuotedStr( pOD->optArg.argString ); - printf( zOptEnd, pOpts->pzPROGNAME, pOD->pz_NAME ); - } - } while (++optIx < pOpts->presetOptCt ); - - if ( ((pOpts->fOptSet & OPTPROC_REORDER) != 0) - && (pOpts->curOptIdx < pOpts->origArgCt)) { - fputs( "set --", stdout ); - for (optIx = pOpts->curOptIdx; optIx < pOpts->origArgCt; optIx++) { - char* pzArg = pOpts->origArgVect[ optIx ]; - if (strchr( pzArg, '\'' ) == NULL) - printf( " '%s'", pzArg ); - else { - fputs( " '", stdout ); - for (;;) { - char ch = *(pzArg++); - switch (ch) { - case '\'': fputs( "'\\''", stdout ); break; - case NUL: goto arg_done; - default: fputc( ch, stdout ); break; - } - } arg_done:; - fputc( '\'', stdout ); - } - } - fputs( "\nOPTION_CT=0\n", stdout ); - } -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/putshell.c */ diff --git a/contrib/ntp/libopts/restore.c b/contrib/ntp/libopts/restore.c deleted file mode 100644 index 91eac0804..000000000 --- a/contrib/ntp/libopts/restore.c +++ /dev/null @@ -1,250 +0,0 @@ - -/* - * restore.c $Id: restore.c,v 4.10 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 14:13:17 bkorb" - * - * This module's routines will save the current option state to memory - * and restore it. If saved prior to the initial optionProcess call, - * then the initial state will be restored. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* - * optionFixupSavedOpts Really, it just wipes out option state for - * options that are troublesome to copy. viz., stacked strings and - * hierarcicaly valued option args. We do duplicate string args that - * have been marked as allocated though. - */ -static void -fixupSavedOptionArgs(tOptions* pOpts) -{ - tOptions* p = pOpts->pSavedState; - tOptDesc* pOD = pOpts->pOptDesc; - int ct = pOpts->optCt; - - /* - * Make sure that allocated stuff is only referenced in the - * archived copy of the data. - */ - for (; ct-- > 0; pOD++) { - switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { - case OPARG_TYPE_STRING: - if (pOD->fOptState & OPTST_STACKED) { - tOptDesc* q = p->pOptDesc + (pOD - pOpts->pOptDesc); - q->optCookie = NULL; - } - if (pOD->fOptState & OPTST_ALLOC_ARG) { - tOptDesc* q = p->pOptDesc + (pOD - pOpts->pOptDesc); - AGDUPSTR(q->optArg.argString, pOD->optArg.argString, "arg"); - } - break; - - case OPARG_TYPE_HIERARCHY: - { - tOptDesc* q = p->pOptDesc + (pOD - pOpts->pOptDesc); - q->optCookie = NULL; - } - } - } -} - -/*=export_func optionSaveState - * - * what: saves the option state to memory - * arg: tOptions*, pOpts, program options descriptor - * - * doc: - * - * This routine will allocate enough memory to save the current option - * processing state. If this routine has been called before, that memory - * will be reused. You may only save one copy of the option state. This - * routine may be called before optionProcess(3AO). If you do call it - * before the first call to optionProcess, then you may also change the - * contents of argc/argv after you call optionRestore(3AO) - * - * In fact, more strongly put: it is safest to only use this function - * before having processed any options. In particular, the saving and - * restoring of stacked string arguments and hierarchical values is - * disabled. The values are not saved. - * - * err: If it fails to allocate the memory, - * it will print a message to stderr and exit. - * Otherwise, it will always succeed. -=*/ -void -optionSaveState(tOptions* pOpts) -{ - tOptions* p = (tOptions*)pOpts->pSavedState; - - if (p == NULL) { - size_t sz = sizeof( *pOpts ) + (pOpts->optCt * sizeof( tOptDesc )); - p = AGALOC( sz, "saved option state" ); - if (p == NULL) { - tCC* pzName = pOpts->pzProgName; - if (pzName == NULL) { - pzName = pOpts->pzPROGNAME; - if (pzName == NULL) - pzName = zNil; - } - fprintf( stderr, zCantSave, pzName, sz ); - exit( EXIT_FAILURE ); - } - - pOpts->pSavedState = p; - } - - memcpy( p, pOpts, sizeof( *p )); - memcpy( p + 1, pOpts->pOptDesc, p->optCt * sizeof( tOptDesc )); - - fixupSavedOptionArgs(pOpts); -} - - -/*=export_func optionRestore - * - * what: restore option state from memory copy - * arg: tOptions*, pOpts, program options descriptor - * - * doc: Copy back the option state from saved memory. - * The allocated memory is left intact, so this routine can be - * called repeatedly without having to call optionSaveState again. - * If you are restoring a state that was saved before the first call - * to optionProcess(3AO), then you may change the contents of the - * argc/argv parameters to optionProcess. - * - * err: If you have not called @code{optionSaveState} before, a diagnostic is - * printed to @code{stderr} and exit is called. -=*/ -void -optionRestore( tOptions* pOpts ) -{ - tOptions* p = (tOptions*)pOpts->pSavedState; - - if (p == NULL) { - tCC* pzName = pOpts->pzProgName; - if (pzName == NULL) { - pzName = pOpts->pzPROGNAME; - if (pzName == NULL) - pzName = zNil; - } - fprintf( stderr, zNoState, pzName ); - exit( EXIT_FAILURE ); - } - - pOpts->pSavedState = NULL; - optionFree(pOpts); - - memcpy( pOpts, p, sizeof( *p )); - memcpy( pOpts->pOptDesc, p+1, p->optCt * sizeof( tOptDesc )); - pOpts->pSavedState = p; - - fixupSavedOptionArgs(pOpts); -} - -/* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */ - -/*=export_func optionFree - * - * what: free allocated option processing memory - * arg: tOptions*, pOpts, program options descriptor - * - * doc: AutoOpts sometimes allocates memory and puts pointers to it in the - * option state structures. This routine deallocates all such memory. - * - * err: As long as memory has not been corrupted, - * this routine is always successful. -=*/ -void -optionFree( tOptions* pOpts ) -{ - free_saved_state: - { - tOptDesc* p = pOpts->pOptDesc; - int ct = pOpts->optCt; - do { - if (p->fOptState & OPTST_ALLOC_ARG) { - AGFREE(p->optArg.argString); - p->optArg.argString = NULL; - p->fOptState &= ~OPTST_ALLOC_ARG; - } - - switch (OPTST_GET_ARGTYPE(p->fOptState)) { - case OPARG_TYPE_STRING: -#ifdef WITH_LIBREGEX - if ( (p->fOptState & OPTST_STACKED) - && (p->optCookie != NULL)) { - p->optArg.argString = ".*"; - optionUnstackArg(pOpts, p); - } -#else - /* leak memory */; -#endif - break; - - case OPARG_TYPE_HIERARCHY: - if (p->optCookie != NULL) - unloadNestedArglist(p->optCookie); - break; - } - - p->optCookie = NULL; - } while (p++, --ct > 0); - } - if (pOpts->pSavedState != NULL) { - tOptions * p = (tOptions*)pOpts->pSavedState; - memcpy( pOpts, p, sizeof( *p )); - memcpy( pOpts->pOptDesc, p+1, p->optCt * sizeof( tOptDesc )); - AGFREE( pOpts->pSavedState ); - pOpts->pSavedState = NULL; - goto free_saved_state; - } -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/restore.c */ diff --git a/contrib/ntp/libopts/save.c b/contrib/ntp/libopts/save.c deleted file mode 100644 index c88952075..000000000 --- a/contrib/ntp/libopts/save.c +++ /dev/null @@ -1,521 +0,0 @@ - -/* - * save.c $Id: save.c,v 4.18 2007/04/15 19:01:18 bkorb Exp $ - * Time-stamp: "2007-04-15 11:11:10 bkorb" - * - * This module's routines will take the currently set options and - * store them into an ".rc" file for re-interpretation the next - * time the invoking program is run. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -tSCC zWarn[] = "%s WARNING: cannot save options - "; - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static tCC* -findDirName( tOptions* pOpts, int* p_free ); - -static tCC* -findFileName( tOptions* pOpts, int* p_free_name ); - -static void -printEntry( - FILE * fp, - tOptDesc * p, - tCC* pzLA ); -/* = = = END-STATIC-FORWARD = = = */ - -static tCC* -findDirName( tOptions* pOpts, int* p_free ) -{ - tCC* pzDir; - - if (pOpts->specOptIdx.save_opts == 0) - return NULL; - - pzDir = pOpts->pOptDesc[ pOpts->specOptIdx.save_opts ].optArg.argString; - if ((pzDir != NULL) && (*pzDir != NUL)) - return pzDir; - - /* - * This function only works if there is a directory where - * we can stash the RC (INI) file. - */ - { - tCC* const* papz = pOpts->papzHomeList; - if (papz == NULL) - return NULL; - - while (papz[1] != NULL) papz++; - pzDir = *papz; - } - - /* - * IF it does not require deciphering an env value, then just copy it - */ - if (*pzDir != '$') - return pzDir; - - { - tCC* pzEndDir = strchr( ++pzDir, DIRCH ); - char* pzFileName; - char* pzEnv; - - if (pzEndDir != NULL) { - char z[ AO_NAME_SIZE ]; - if ((pzEndDir - pzDir) > AO_NAME_LIMIT ) - return NULL; - strncpy( z, pzDir, (size_t)(pzEndDir - pzDir) ); - z[ (pzEndDir - pzDir) ] = NUL; - pzEnv = getenv( z ); - } else { - - /* - * Make sure we can get the env value (after stripping off - * any trailing directory or file names) - */ - pzEnv = getenv( pzDir ); - } - - if (pzEnv == NULL) { - fprintf( stderr, zWarn, pOpts->pzProgName ); - fprintf( stderr, zNotDef, pzDir ); - return NULL; - } - - if (pzEndDir == NULL) - return pzEnv; - - { - size_t sz = strlen( pzEnv ) + strlen( pzEndDir ) + 2; - pzFileName = (char*)AGALOC( sz, "dir name" ); - } - - if (pzFileName == NULL) - return NULL; - - *p_free = 1; - /* - * Glue together the full name into the allocated memory. - * FIXME: We lose track of this memory. - */ - sprintf( pzFileName, "%s/%s", pzEnv, pzEndDir ); - return pzFileName; - } -} - - -static tCC* -findFileName( tOptions* pOpts, int* p_free_name ) -{ - tCC* pzDir; - struct stat stBuf; - int free_dir_name = 0; - - pzDir = findDirName( pOpts, &free_dir_name ); - if (pzDir == NULL) - return NULL; - - /* - * See if we can find the specified directory. We use a once-only loop - * structure so we can bail out early. - */ - if (stat( pzDir, &stBuf ) != 0) do { - - /* - * IF we could not, check to see if we got a full - * path to a file name that has not been created yet. - */ - if (errno == ENOENT) { - char z[AG_PATH_MAX]; - - /* - * Strip off the last component, stat the remaining string and - * that string must name a directory - */ - char* pzDirCh = strrchr( pzDir, DIRCH ); - if (pzDirCh == NULL) { - stBuf.st_mode = S_IFREG; - continue; /* bail out of error condition */ - } - - strncpy( z, pzDir, (size_t)(pzDirCh - pzDir)); - z[ pzDirCh - pzDir ] = NUL; - - if ( (stat( z, &stBuf ) == 0) - && S_ISDIR( stBuf.st_mode )) { - - /* - * We found the directory. Restore the file name and - * mark the full name as a regular file - */ - stBuf.st_mode = S_IFREG; - continue; /* bail out of error condition */ - } - } - - /* - * We got a bogus name. - */ - fprintf( stderr, zWarn, pOpts->pzProgName ); - fprintf( stderr, zNoStat, errno, strerror( errno ), pzDir ); - if (free_dir_name) - AGFREE( (void*)pzDir ); - return NULL; - } while (0); - - /* - * IF what we found was a directory, - * THEN tack on the config file name - */ - if (S_ISDIR( stBuf.st_mode )) { - size_t sz = strlen( pzDir ) + strlen( pOpts->pzRcName ) + 2; - - { - char* pzPath = (char*)AGALOC( sz, "file name" ); -#ifdef HAVE_SNPRINTF - snprintf( pzPath, sz, "%s/%s", pzDir, pOpts->pzRcName ); -#else - sprintf( pzPath, "%s/%s", pzDir, pOpts->pzRcName ); -#endif - if (free_dir_name) - AGFREE( (void*)pzDir ); - pzDir = pzPath; - free_dir_name = 1; - } - - /* - * IF we cannot stat the object for any reason other than - * it does not exist, then we bail out - */ - if (stat( pzDir, &stBuf ) != 0) { - if (errno != ENOENT) { - fprintf( stderr, zWarn, pOpts->pzProgName ); - fprintf( stderr, zNoStat, errno, strerror( errno ), - pzDir ); - AGFREE( (void*)pzDir ); - return NULL; - } - - /* - * It does not exist yet, but it will be a regular file - */ - stBuf.st_mode = S_IFREG; - } - } - - /* - * Make sure that whatever we ultimately found, that it either is - * or will soon be a file. - */ - if (! S_ISREG( stBuf.st_mode )) { - fprintf( stderr, zWarn, pOpts->pzProgName ); - fprintf( stderr, zNotFile, pzDir ); - if (free_dir_name) - AGFREE( (void*)pzDir ); - return NULL; - } - - /* - * Get rid of the old file - */ - unlink( pzDir ); - *p_free_name = free_dir_name; - return pzDir; -} - - -static void -printEntry( - FILE * fp, - tOptDesc * p, - tCC* pzLA ) -{ - /* - * There is an argument. Pad the name so values line up. - * Not disabled *OR* this got equivalenced to another opt, - * then use current option name. - * Otherwise, there must be a disablement name. - */ - { - char const * pz; - if (! DISABLED_OPT(p) || (p->optEquivIndex != NO_EQUIVALENT)) - pz = p->pz_Name; - else - pz = p->pz_DisableName; - - fprintf(fp, "%-18s", pz); - } - /* - * IF the option is numeric only, - * THEN the char pointer is really the number - */ - if (OPTST_GET_ARGTYPE(p->fOptState) == OPARG_TYPE_NUMERIC) - fprintf( fp, " %d\n", (int)(t_word)pzLA ); - - /* - * OTHERWISE, FOR each line of the value text, ... - */ - else if (pzLA == NULL) - fputc( '\n', fp ); - - else { - fputc( ' ', fp ); fputc( ' ', fp ); - for (;;) { - tCC* pzNl = strchr( pzLA, '\n' ); - - /* - * IF this is the last line - * THEN bail and print it - */ - if (pzNl == NULL) - break; - - /* - * Print the continuation and the text from the current line - */ - (void)fwrite( pzLA, (size_t)(pzNl - pzLA), (size_t)1, fp ); - pzLA = pzNl+1; /* advance the Last Arg pointer */ - fputs( "\\\n", fp ); - } - - /* - * Terminate the entry - */ - fputs( pzLA, fp ); - fputc( '\n', fp ); - } -} - - -/*=export_func optionSaveFile - * - * what: saves the option state to a file - * - * arg: tOptions*, pOpts, program options descriptor - * - * doc: - * - * This routine will save the state of option processing to a file. The name - * of that file can be specified with the argument to the @code{--save-opts} - * option, or by appending the @code{rcfile} attribute to the last - * @code{homerc} attribute. If no @code{rcfile} attribute was specified, it - * will default to @code{.@i{programname}rc}. If you wish to specify another - * file, you should invoke the @code{SET_OPT_SAVE_OPTS( @i{filename} )} macro. - * - * err: - * - * If no @code{homerc} file was specified, this routine will silently return - * and do nothing. If the output file cannot be created or updated, a message - * will be printed to @code{stderr} and the routine will return. -=*/ -void -optionSaveFile( tOptions* pOpts ) -{ - tOptDesc* pOD; - int ct; - FILE* fp; - - { - int free_name = 0; - tCC* pzFName = findFileName( pOpts, &free_name ); - if (pzFName == NULL) - return; - - fp = fopen( pzFName, "w" FOPEN_BINARY_FLAG ); - if (fp == NULL) { - fprintf( stderr, zWarn, pOpts->pzProgName ); - fprintf( stderr, zNoCreat, errno, strerror( errno ), pzFName ); - if (free_name) - AGFREE((void*) pzFName ); - return; - } - - if (free_name) - AGFREE( (void*)pzFName ); - } - - { - char const* pz = pOpts->pzUsageTitle; - fputs( "# ", fp ); - do { fputc( *pz, fp ); } while (*(pz++) != '\n'); - } - - { - time_t timeVal = time( NULL ); - char* pzTime = ctime( &timeVal ); - - fprintf( fp, zPresetFile, pzTime ); -#ifdef HAVE_ALLOCATED_CTIME - /* - * The return values for ctime(), localtime(), and gmtime() - * normally point to static data that is overwritten by each call. - * The test to detect allocated ctime, so we leak the memory. - */ - AGFREE( (void*)pzTime ); -#endif - } - - /* - * FOR each of the defined options, ... - */ - ct = pOpts->presetOptCt; - pOD = pOpts->pOptDesc; - do { - int arg_state; - tOptDesc* p; - - /* - * IF the option has not been defined - * OR it does not take an initialization value - * OR it is equivalenced to another option - * THEN continue (ignore it) - */ - if (UNUSED_OPT( pOD )) - continue; - - if ((pOD->fOptState & (OPTST_NO_INIT|OPTST_DOCUMENT|OPTST_OMITTED)) - != 0) - continue; - - if ( (pOD->optEquivIndex != NO_EQUIVALENT) - && (pOD->optEquivIndex != pOD->optIndex)) - continue; - - /* - * Set a temporary pointer to the real option description - * (i.e. account for equivalencing) - */ - p = ((pOD->fOptState & OPTST_EQUIVALENCE) != 0) - ? (pOpts->pOptDesc + pOD->optActualIndex) : pOD; - - /* - * IF no arguments are allowed - * THEN just print the name and continue - */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NONE) { - char const * pznm = - (DISABLED_OPT( p )) ? p->pz_DisableName : p->pz_Name; - /* - * If the option was disabled and the disablement name is NULL, - * then the disablement was caused by aliasing. - * Use the name as the string to emit. - */ - if (pznm == NULL) - pznm = p->pz_Name; - - fprintf(fp, "%s\n", pznm); - continue; - } - - arg_state = OPTST_GET_ARGTYPE(p->fOptState); - switch (arg_state) { - case 0: - case OPARG_TYPE_NUMERIC: - printEntry( fp, p, (void*)(p->optArg.argInt)); - break; - - case OPARG_TYPE_STRING: - if (p->fOptState & OPTST_STACKED) { - tArgList* pAL = (tArgList*)p->optCookie; - int uct = pAL->useCt; - tCC** ppz = pAL->apzArgs; - - /* - * Disallow multiple copies of disabled options. - */ - if (uct > 1) - p->fOptState &= ~OPTST_DISABLED; - - while (uct-- > 0) - printEntry( fp, p, *(ppz++) ); - } else { - printEntry( fp, p, p->optArg.argString ); - } - break; - - case OPARG_TYPE_ENUMERATION: - case OPARG_TYPE_MEMBERSHIP: - { - uintptr_t val = p->optArg.argEnum; - /* - * This is a magic incantation that will convert the - * bit flag values back into a string suitable for printing. - */ - (*(p->pOptProc))( (tOptions*)2UL, p ); - printEntry( fp, p, (void*)(p->optArg.argString)); - - if ( (p->optArg.argString != NULL) - && (arg_state != OPARG_TYPE_ENUMERATION)) { - /* - * set membership strings get allocated - */ - AGFREE( (void*)p->optArg.argString ); - p->fOptState &= ~OPTST_ALLOC_ARG; - } - - p->optArg.argEnum = val; - break; - } - - case OPARG_TYPE_BOOLEAN: - printEntry( fp, p, p->optArg.argBool ? "true" : "false" ); - break; - - default: - break; /* cannot handle - skip it */ - } - } while ( (pOD++), (--ct > 0)); - - fclose( fp ); -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/save.c */ diff --git a/contrib/ntp/libopts/sort.c b/contrib/ntp/libopts/sort.c deleted file mode 100644 index ead713372..000000000 --- a/contrib/ntp/libopts/sort.c +++ /dev/null @@ -1,359 +0,0 @@ - -/* - * sort.c $Id: sort.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-10-18 11:29:04 bkorb" - * - * This module implements argument sorting. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static tSuccess -mustHandleArg( tOptions* pOpts, char* pzArg, tOptState* pOS, - char** ppzOpts, int* pOptsIdx ); - -static tSuccess -mayHandleArg( tOptions* pOpts, char* pzArg, tOptState* pOS, - char** ppzOpts, int* pOptsIdx ); - -static tSuccess -checkShortOpts( tOptions* pOpts, char* pzArg, tOptState* pOS, - char** ppzOpts, int* pOptsIdx ); -/* = = = END-STATIC-FORWARD = = = */ - -/* - * "mustHandleArg" and "mayHandleArg" are really similar. The biggest - * difference is that "may" will consume the next argument only if it - * does not start with a hyphen and "must" will consume it, hyphen or not. - */ -static tSuccess -mustHandleArg( tOptions* pOpts, char* pzArg, tOptState* pOS, - char** ppzOpts, int* pOptsIdx ) -{ - /* - * An option argument is required. Long options can either have - * a separate command line argument, or an argument attached by - * the '=' character. Figure out which. - */ - switch (pOS->optType) { - case TOPT_SHORT: - /* - * See if an arg string follows the flag character. If not, - * the next arg must be the option argument. - */ - if (*pzArg != NUL) - return SUCCESS; - break; - - case TOPT_LONG: - /* - * See if an arg string has already been assigned (glued on - * with an `=' character). If not, the next is the opt arg. - */ - if (pOS->pzOptArg != NULL) - return SUCCESS; - break; - - default: - return FAILURE; - } - if (pOpts->curOptIdx >= pOpts->origArgCt) - return FAILURE; - - ppzOpts[ (*pOptsIdx)++ ] = pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - return SUCCESS; -} - -static tSuccess -mayHandleArg( tOptions* pOpts, char* pzArg, tOptState* pOS, - char** ppzOpts, int* pOptsIdx ) -{ - /* - * An option argument is optional. - */ - switch (pOS->optType) { - case TOPT_SHORT: - /* - * IF nothing is glued on after the current flag character, - * THEN see if there is another argument. If so and if it - * does *NOT* start with a hyphen, then it is the option arg. - */ - if (*pzArg != NUL) - return SUCCESS; - break; - - case TOPT_LONG: - /* - * Look for an argument if we don't already have one (glued on - * with a `=' character) - */ - if (pOS->pzOptArg != NULL) - return SUCCESS; - break; - - default: - return FAILURE; - } - if (pOpts->curOptIdx >= pOpts->origArgCt) - return PROBLEM; - - pzArg = pOpts->origArgVect[ pOpts->curOptIdx ]; - if (*pzArg != '-') - ppzOpts[ (*pOptsIdx)++ ] = pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - return SUCCESS; -} - -/* - * Process a string of short options glued together. If the last one - * does or may take an argument, the do the argument processing and leave. - */ -static tSuccess -checkShortOpts( tOptions* pOpts, char* pzArg, tOptState* pOS, - char** ppzOpts, int* pOptsIdx ) -{ - while (*pzArg != NUL) { - if (FAILED( shortOptionFind( pOpts, (tAoUC)*pzArg, pOS ))) - return FAILURE; - - /* - * See if we can have an arg. - */ - if (OPTST_GET_ARGTYPE(pOS->pOD->fOptState) == OPARG_TYPE_NONE) { - pzArg++; - - } else if (pOS->pOD->fOptState & OPTST_ARG_OPTIONAL) { - /* - * Take an argument if it is not attached and it does not - * start with a hyphen. - */ - if (pzArg[1] != NUL) - return SUCCESS; - - pzArg = pOpts->origArgVect[ pOpts->curOptIdx ]; - if (*pzArg != '-') - ppzOpts[ (*pOptsIdx)++ ] = - pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - return SUCCESS; - - } else { - /* - * IF we need another argument, be sure it is there and - * take it. - */ - if (pzArg[1] == NUL) { - if (pOpts->curOptIdx >= pOpts->origArgCt) - return FAILURE; - ppzOpts[ (*pOptsIdx)++ ] = - pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - } - return SUCCESS; - } - } - return SUCCESS; -} - -/* - * If the program wants sorted options (separated operands and options), - * then this routine will to the trick. - */ -LOCAL void -optionSort( tOptions* pOpts ) -{ - char** ppzOpts; - char** ppzOpds; - int optsIdx = 0; - int opdsIdx = 0; - - tOptState os = OPTSTATE_INITIALIZER(DEFINED); - - /* - * Disable for POSIX conformance, or if there are no operands. - */ - if ( (getenv( "POSIXLY_CORRECT" ) != NULL) - || NAMED_OPTS(pOpts)) - return; - - /* - * Make sure we can allocate two full-sized arg vectors. - */ - ppzOpts = malloc( pOpts->origArgCt * sizeof( char* )); - if (ppzOpts == NULL) - goto exit_no_mem; - - ppzOpds = malloc( pOpts->origArgCt * sizeof( char* )); - if (ppzOpds == NULL) { - free( ppzOpts ); - goto exit_no_mem; - } - - pOpts->curOptIdx = 1; - pOpts->pzCurOpt = NULL; - - /* - * Now, process all the options from our current position onward. - * (This allows interspersed options and arguments for the few - * non-standard programs that require it.) - */ - for (;;) { - char* pzArg; - tSuccess res; - - /* - * If we're out of arguments, we're done. Join the option and - * operand lists into the original argument vector. - */ - if (pOpts->curOptIdx >= pOpts->origArgCt) { - errno = 0; - goto joinLists; - } - - pzArg = pOpts->origArgVect[ pOpts->curOptIdx ]; - if (*pzArg != '-') { - ppzOpds[ opdsIdx++ ] = pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - continue; - } - - switch (pzArg[1]) { - case NUL: - /* - * A single hyphen is an operand. - */ - ppzOpds[ opdsIdx++ ] = pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - continue; - - case '-': - /* - * Two consecutive hypens. Put them on the options list and then - * _always_ force the remainder of the arguments to be operands. - */ - if (pzArg[2] == NUL) { - ppzOpts[ optsIdx++ ] = - pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - goto restOperands; - } - res = longOptionFind( pOpts, pzArg+2, &os ); - break; - - default: - /* - * If short options are not allowed, then do long - * option processing. Otherwise the character must be a - * short (i.e. single character) option. - */ - if ((pOpts->fOptSet & OPTPROC_SHORTOPT) == 0) { - res = longOptionFind( pOpts, pzArg+1, &os ); - } else { - res = shortOptionFind( pOpts, (tAoUC)pzArg[1], &os ); - } - break; - } - if (FAILED( res )) { - errno = EINVAL; - goto freeTemps; - } - - /* - * We've found an option. Add the argument to the option list. - * Next, we have to see if we need to pull another argument to be - * used as the option argument. - */ - ppzOpts[ optsIdx++ ] = pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - - if (OPTST_GET_ARGTYPE(os.pOD->fOptState) == OPARG_TYPE_NONE) { - /* - * No option argument. If we have a short option here, - * then scan for short options until we get to the end - * of the argument string. - */ - if ( (os.optType == TOPT_SHORT) - && FAILED( checkShortOpts( pOpts, pzArg+2, &os, - ppzOpts, &optsIdx )) ) { - errno = EINVAL; - goto freeTemps; - } - - } else if (os.pOD->fOptState & OPTST_ARG_OPTIONAL) { - switch (mayHandleArg( pOpts, pzArg+2, &os, ppzOpts, &optsIdx )) { - case FAILURE: errno = EIO; goto freeTemps; - case PROBLEM: errno = 0; goto joinLists; - } - - } else { - switch (mustHandleArg( pOpts, pzArg+2, &os, ppzOpts, &optsIdx )) { - case PROBLEM: - case FAILURE: errno = EIO; goto freeTemps; - } - } - } /* for (;;) */ - - restOperands: - while (pOpts->curOptIdx < pOpts->origArgCt) - ppzOpds[ opdsIdx++ ] = pOpts->origArgVect[ (pOpts->curOptIdx)++ ]; - - joinLists: - if (optsIdx > 0) - memcpy( pOpts->origArgVect + 1, ppzOpts, optsIdx * sizeof( char* )); - if (opdsIdx > 0) - memcpy( pOpts->origArgVect + 1 + optsIdx, - ppzOpds, opdsIdx * sizeof( char* )); - - freeTemps: - free( ppzOpts ); - free( ppzOpds ); - return; - - exit_no_mem: - errno = ENOMEM; - return; -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/sort.c */ diff --git a/contrib/ntp/libopts/stack.c b/contrib/ntp/libopts/stack.c deleted file mode 100644 index 6d77f72e5..000000000 --- a/contrib/ntp/libopts/stack.c +++ /dev/null @@ -1,269 +0,0 @@ - -/* - * stack.c - * $Id: stack.c,v 4.13 2007/02/04 17:44:12 bkorb Exp $ - * Time-stamp: "2007-01-13 10:43:21 bkorb" - * - * This is a special option processing routine that will save the - * argument to an option in a FIFO queue. - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -#ifdef WITH_LIBREGEX -# include REGEX_HEADER -#endif - -/*=export_func optionUnstackArg - * private: - * - * what: Remove option args from a stack - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * Invoked for options that are equivalenced to stacked options. -=*/ -void -optionUnstackArg( - tOptions* pOpts, - tOptDesc* pOptDesc ) -{ - int res; - - tArgList* pAL = (tArgList*)pOptDesc->optCookie; - /* - * IF we don't have any stacked options, - * THEN indicate that we don't have any of these options - */ - if (pAL == NULL) { - pOptDesc->fOptState &= OPTST_PERSISTENT_MASK; - if ( (pOptDesc->fOptState & OPTST_INITENABLED) == 0) - pOptDesc->fOptState |= OPTST_DISABLED; - return; - } - -#ifdef WITH_LIBREGEX - { - regex_t re; - int i, ct, dIdx; - - if (regcomp( &re, pOptDesc->optArg.argString, REG_NOSUB ) != 0) - return; - - /* - * search the list for the entry(s) to remove. Entries that - * are removed are *not* copied into the result. The source - * index is incremented every time. The destination only when - * we are keeping a define. - */ - for (i = 0, dIdx = 0, ct = pAL->useCt; --ct >= 0; i++) { - tCC* pzSrc = pAL->apzArgs[ i ]; - char* pzEq = strchr( pzSrc, '=' ); - - if (pzEq != NULL) - *pzEq = NUL; - - res = regexec( &re, pzSrc, (size_t)0, NULL, 0 ); - switch (res) { - case 0: - /* - * Remove this entry by reducing the in-use count - * and *not* putting the string pointer back into - * the list. - */ - AGFREE(pzSrc); - pAL->useCt--; - break; - - default: - case REG_NOMATCH: - if (pzEq != NULL) - *pzEq = '='; - - /* - * IF we have dropped an entry - * THEN we have to move the current one. - */ - if (dIdx != i) - pAL->apzArgs[ dIdx ] = pzSrc; - dIdx++; - } - } - - regfree( &re ); - } -#else /* not WITH_LIBREGEX */ - { - int i, ct, dIdx; - - /* - * search the list for the entry(s) to remove. Entries that - * are removed are *not* copied into the result. The source - * index is incremented every time. The destination only when - * we are keeping a define. - */ - for (i = 0, dIdx = 0, ct = pAL->useCt; --ct >= 0; i++) { - tCC* pzSrc = pAL->apzArgs[ i ]; - char* pzEq = strchr( pzSrc, '=' ); - - if (pzEq != NULL) - *pzEq = NUL; - - if (strcmp( pzSrc, pOptDesc->optArg.argString ) == 0) { - /* - * Remove this entry by reducing the in-use count - * and *not* putting the string pointer back into - * the list. - */ - AGFREE(pzSrc); - pAL->useCt--; - } else { - if (pzEq != NULL) - *pzEq = '='; - - /* - * IF we have dropped an entry - * THEN we have to move the current one. - */ - if (dIdx != i) - pAL->apzArgs[ dIdx ] = pzSrc; - dIdx++; - } - } - } -#endif /* WITH_LIBREGEX */ - /* - * IF we have unstacked everything, - * THEN indicate that we don't have any of these options - */ - if (pAL->useCt == 0) { - pOptDesc->fOptState &= OPTST_PERSISTENT_MASK; - if ( (pOptDesc->fOptState & OPTST_INITENABLED) == 0) - pOptDesc->fOptState |= OPTST_DISABLED; - AGFREE( (void*)pAL ); - pOptDesc->optCookie = NULL; - } -} - - -/* - * Put an entry into an argument list. The first argument points to - * a pointer to the argument list structure. It gets passed around - * as an opaque address. - */ -LOCAL void -addArgListEntry( void** ppAL, void* entry ) -{ - tArgList* pAL = *(void**)ppAL; - - /* - * IF we have never allocated one of these, - * THEN allocate one now - */ - if (pAL == NULL) { - pAL = (tArgList*)AGALOC( sizeof( *pAL ), "new option arg stack" ); - if (pAL == NULL) - return; - pAL->useCt = 0; - pAL->allocCt = MIN_ARG_ALLOC_CT; - *ppAL = (void*)pAL; - } - - /* - * ELSE if we are out of room - * THEN make it bigger - */ - else if (pAL->useCt >= pAL->allocCt) { - size_t sz = sizeof( *pAL ); - pAL->allocCt += INCR_ARG_ALLOC_CT; - - /* - * The base structure contains space for MIN_ARG_ALLOC_CT - * pointers. We subtract it off to find our augment size. - */ - sz += sizeof(char*) * (pAL->allocCt - MIN_ARG_ALLOC_CT); - pAL = (tArgList*)AGREALOC( (void*)pAL, sz, "expanded opt arg stack" ); - if (pAL == NULL) - return; - *ppAL = (void*)pAL; - } - - /* - * Insert the new argument into the list - */ - pAL->apzArgs[ (pAL->useCt)++ ] = entry; -} - - -/*=export_func optionStackArg - * private: - * - * what: put option args on a stack - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * Keep an entry-ordered list of option arguments. -=*/ -void -optionStackArg( - tOptions* pOpts, - tOptDesc* pOD ) -{ - char * pz; - - if (pOD->optArg.argString == NULL) - return; - - AGDUPSTR(pz, pOD->optArg.argString, "stack arg"); - addArgListEntry( &(pOD->optCookie), (void*)pz ); -} -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/stack.c */ diff --git a/contrib/ntp/libopts/streqvcmp.c b/contrib/ntp/libopts/streqvcmp.c deleted file mode 100644 index 8249794e0..000000000 --- a/contrib/ntp/libopts/streqvcmp.c +++ /dev/null @@ -1,289 +0,0 @@ - -/* - * $Id: streqvcmp.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2006-07-26 18:25:53 bkorb" - * - * String Equivalence Comparison - * - * These routines allow any character to be mapped to any other - * character before comparison. In processing long option names, - * the characters "-", "_" and "^" all need to be equivalent - * (because they are treated so by different development environments). - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* - * This array is designed for mapping upper and lower case letter - * together for a case independent comparison. The mappings are - * based upon ascii character sequences. - */ -static unsigned char charmap[] = { - 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, '\a', - '\b', '\t', '\n', '\v', '\f', '\r', 0x0E, 0x0F, - 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, - 0x18, 0x19, 0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x1F, - - ' ', '!', '"', '#', '$', '%', '&', '\'', - '(', ')', '*', '+', ',', '-', '.', '/', - '0', '1', '2', '3', '4', '5', '6', '7', - '8', '9', ':', ';', '<', '=', '>', '?', - - '@', 'a', 'b', 'c', 'd', 'e', 'f', 'g', - 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', - 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', - 'x', 'y', 'z', '[', '\\', ']', '^', '_', - '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g', - 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', - 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', - 'x', 'y', 'z', '{', '|', '}', '~', 0x7f, - - 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, - 0x88, 0x89, 0x8A, 0x8B, 0x8C, 0x8D, 0x8E, 0x8F, - 0x90, 0x91, 0x92, 0x93, 0x94, 0x95, 0x96, 0x97, - 0x98, 0x99, 0x9A, 0x9B, 0x9C, 0x9D, 0x9E, 0x9F, - 0xA0, 0xA1, 0xA2, 0xA3, 0xA4, 0xA5, 0xA6, 0xA7, - 0xA8, 0xA9, 0xAA, 0xAB, 0xAC, 0xAD, 0xAE, 0xAF, - 0xB0, 0xB1, 0xB2, 0xB3, 0xB4, 0xB5, 0xB6, 0xB7, - 0xB8, 0xB9, 0xBA, 0xBB, 0xBC, 0xBD, 0xBE, 0xBF, - - 0xC0, 0xC1, 0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, - 0xC8, 0xC9, 0xCA, 0xCB, 0xCC, 0xCD, 0xCE, 0xCF, - 0xD0, 0xD1, 0xD2, 0xD3, 0xD4, 0xD5, 0xD6, 0xD7, - 0xD8, 0xD9, 0xDA, 0xDB, 0xDC, 0xDD, 0xDE, 0xDF, - 0xE0, 0xE1, 0xE2, 0xE3, 0xE4, 0xE5, 0xE6, 0xE7, - 0xE8, 0xE9, 0xEA, 0xEB, 0xEC, 0xED, 0xEE, 0xEF, - 0xF0, 0xF1, 0xF2, 0xF3, 0xF4, 0xF5, 0xF6, 0xF7, - 0xF8, 0xF9, 0xFA, 0xFB, 0xFC, 0xFD, 0xFE, 0xFF, -}; - - -/*=export_func strneqvcmp - * - * what: compare two strings with an equivalence mapping - * - * arg: + char const* + str1 + first string + - * arg: + char const* + str2 + second string + - * arg: + int + ct + compare length + - * - * ret_type: int - * ret_desc: the difference between two differing characters - * - * doc: - * - * Using a character mapping, two strings are compared for "equivalence". - * Each input character is mapped to a comparison character and the - * mapped-to characters are compared for the two NUL terminated input strings. - * The comparison is limited to @code{ct} bytes. - * This function name is mapped to option_strneqvcmp so as to not conflict - * with the POSIX name space. - * - * err: none checked. Caller responsible for seg faults. -=*/ -int -strneqvcmp( tCC* s1, tCC* s2, int ct ) -{ - for (; ct > 0; --ct) { - unsigned char u1 = (unsigned char) *s1++; - unsigned char u2 = (unsigned char) *s2++; - int dif = charmap[ u1 ] - charmap[ u2 ]; - - if (dif != 0) - return dif; - - if (u1 == NUL) - return 0; - } - - return 0; -} - - -/*=export_func streqvcmp - * - * what: compare two strings with an equivalence mapping - * - * arg: + char const* + str1 + first string + - * arg: + char const* + str2 + second string + - * - * ret_type: int - * ret_desc: the difference between two differing characters - * - * doc: - * - * Using a character mapping, two strings are compared for "equivalence". - * Each input character is mapped to a comparison character and the - * mapped-to characters are compared for the two NUL terminated input strings. - * This function name is mapped to option_streqvcmp so as to not conflict - * with the POSIX name space. - * - * err: none checked. Caller responsible for seg faults. -=*/ -int -streqvcmp( tCC* s1, tCC* s2 ) -{ - for (;;) { - unsigned char u1 = (unsigned char) *s1++; - unsigned char u2 = (unsigned char) *s2++; - int dif = charmap[ u1 ] - charmap[ u2 ]; - - if (dif != 0) - return dif; - - if (u1 == NUL) - return 0; - } -} - - -/*=export_func streqvmap - * - * what: Set the character mappings for the streqv functions - * - * arg: + char + From + Input character + - * arg: + char + To + Mapped-to character + - * arg: + int + ct + compare length + - * - * doc: - * - * Set the character mapping. If the count (@code{ct}) is set to zero, then - * the map is cleared by setting all entries in the map to their index - * value. Otherwise, the "@code{From}" character is mapped to the "@code{To}" - * character. If @code{ct} is greater than 1, then @code{From} and @code{To} - * are incremented and the process repeated until @code{ct} entries have been - * set. For example, - * @example - * streqvmap( 'a', 'A', 26 ); - * @end example - * @noindent - * will alter the mapping so that all English lower case letters - * will map to upper case. - * - * This function name is mapped to option_streqvmap so as to not conflict - * with the POSIX name space. - * - * err: none. -=*/ -void -streqvmap( char From, char To, int ct ) -{ - if (ct == 0) { - ct = sizeof( charmap ) - 1; - do { - charmap[ ct ] = ct; - } while (--ct >= 0); - } - - else { - int chTo = (int)To & 0xFF; - int chFrom = (int)From & 0xFF; - - do { - charmap[ chFrom ] = (unsigned)chTo; - chFrom++; - chTo++; - if ((chFrom >= sizeof( charmap )) || (chTo >= sizeof( charmap ))) - break; - } while (--ct > 0); - } -} - - -/*=export_func strequate - * - * what: map a list of characters to the same value - * - * arg: + char const* + ch_list + characters to equivalence + - * - * doc: - * - * Each character in the input string get mapped to the first character - * in the string. - * This function name is mapped to option_strequate so as to not conflict - * with the POSIX name space. - * - * err: none. -=*/ -void -strequate( char const* s ) -{ - if ((s != NULL) && (*s != NUL)) { - unsigned char equiv = (unsigned)*s; - while (*s != NUL) - charmap[ (unsigned)*(s++) ] = equiv; - } -} - - -/*=export_func strtransform - * - * what: convert a string into its mapped-to value - * - * arg: + char* + dest + output string + - * arg: + char const* + src + input string + - * - * doc: - * - * Each character in the input string is mapped and the mapped-to - * character is put into the output. - * This function name is mapped to option_strtransform so as to not conflict - * with the POSIX name space. - * - * err: none. -=*/ -void -strtransform( char* d, char const* s ) -{ - do { - *(d++) = (char)charmap[ (unsigned)*s ]; - } while (*(s++) != NUL); -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/streqvcmp.c */ diff --git a/contrib/ntp/libopts/text_mmap.c b/contrib/ntp/libopts/text_mmap.c deleted file mode 100644 index ced2977c5..000000000 --- a/contrib/ntp/libopts/text_mmap.c +++ /dev/null @@ -1,363 +0,0 @@ -/* - * $Id: text_mmap.c,v 4.15 2006/11/27 01:52:23 bkorb Exp $ - * - * Time-stamp: "2006-09-10 14:50:04 bkorb" - */ - -#ifndef MAP_ANONYMOUS -# ifdef MAP_ANON -# define MAP_ANONYMOUS MAP_ANON -# endif -#endif - -/* - * Some weird systems require that a specifically invalid FD number - * get passed in as an argument value. Which value is that? Well, - * as everybody knows, if open(2) fails, it returns -1, so that must - * be the value. :) - */ -#define AO_INVALID_FD -1 - -#define FILE_WRITABLE(_prt,_flg) \ - ( (_prt & PROT_WRITE) \ - && ((_flg & (MAP_SHARED|MAP_PRIVATE)) == MAP_SHARED)) -#define MAP_FAILED_PTR ((void*)MAP_FAILED) - -/*=export_func text_mmap - * private: - * - * what: map a text file with terminating NUL - * - * arg: char const*, pzFile, name of the file to map - * arg: int, prot, mmap protections (see mmap(2)) - * arg: int, flags, mmap flags (see mmap(2)) - * arg: tmap_info_t*, mapinfo, returned info about the mapping - * - * ret-type: void* - * ret-desc: The mmaped data address - * - * doc: - * - * This routine will mmap a file into memory ensuring that there is at least - * one @file{NUL} character following the file data. It will return the - * address where the file contents have been mapped into memory. If there is a - * problem, then it will return @code{MAP_FAILED} and set @file{errno} - * appropriately. - * - * The named file does not exist, @code{stat(2)} will set @file{errno} as it - * will. If the file is not a regular file, @file{errno} will be - * @code{EINVAL}. At that point, @code{open(2)} is attempted with the access - * bits set appropriately for the requested @code{mmap(2)} protections and flag - * bits. On failure, @file{errno} will be set according to the documentation - * for @code{open(2)}. If @code{mmap(2)} fails, @file{errno} will be set as - * that routine sets it. If @code{text_mmap} works to this point, a valid - * address will be returned, but there may still be ``issues''. - * - * If the file size is not an even multiple of the system page size, then - * @code{text_map} will return at this point and @file{errno} will be zero. - * Otherwise, an anonymous map is attempted. If not available, then an attempt - * is made to @code{mmap(2)} @file{/dev/zero}. If any of these fail, the - * address of the file's data is returned, bug @code{no} @file{NUL} characters - * are mapped after the end of the data. - * - * see: mmap(2), open(2), stat(2) - * - * err: Any error code issued by mmap(2), open(2), stat(2) is possible. - * Additionally, if the specified file is not a regular file, then - * errno will be set to @code{EINVAL}. - * - * example: - * #include - * tmap_info_t mi; - * int no_nul; - * void* data = text_mmap( "file", PROT_WRITE, MAP_PRIVATE, &mi ); - * if (data == MAP_FAILED) return; - * no_nul = (mi.txt_size == mi.txt_full_size); - * << use the data >> - * text_munmap( &mi ); -=*/ -void* -text_mmap( char const* pzFile, int prot, int flags, tmap_info_t* pMI ) -{ - memset( pMI, 0, sizeof(*pMI) ); -#ifdef HAVE_MMAP - pMI->txt_zero_fd = -1; -#endif - pMI->txt_fd = -1; - - /* - * Make sure we can stat the regular file. Save the file size. - */ - { - struct stat sb; - if (stat( pzFile, &sb ) != 0) { - pMI->txt_errno = errno; - return MAP_FAILED_PTR; - } - - if (! S_ISREG( sb.st_mode )) { - pMI->txt_errno = errno = EINVAL; - return MAP_FAILED_PTR; - } - - pMI->txt_size = sb.st_size; - } - - /* - * Map mmap flags and protections into open flags and do the open. - */ - { - int o_flag; - /* - * See if we will be updating the file. If we can alter the memory - * and if we share the data and we are *not* copy-on-writing the data, - * then our updates will show in the file, so we must open with - * write access. - */ - if (FILE_WRITABLE(prot,flags)) - o_flag = O_RDWR; - else - o_flag = O_RDONLY; - - /* - * If you're not sharing the file and you are writing to it, - * then don't let anyone else have access to the file. - */ - if (((flags & MAP_SHARED) == 0) && (prot & PROT_WRITE)) - o_flag |= O_EXCL; - - pMI->txt_fd = open( pzFile, o_flag ); - } - - if (pMI->txt_fd == AO_INVALID_FD) { - pMI->txt_errno = errno; - return MAP_FAILED_PTR; - } - -#ifdef HAVE_MMAP /* * * * * WITH MMAP * * * * * */ - /* - * do the mmap. If we fail, then preserve errno, close the file and - * return the failure. - */ - pMI->txt_data = - mmap(NULL, pMI->txt_size+1, prot, flags, pMI->txt_fd, (size_t)0); - if (pMI->txt_data == MAP_FAILED_PTR) { - pMI->txt_errno = errno; - goto fail_return; - } - - /* - * Most likely, everything will turn out fine now. The only difficult - * part at this point is coping with files with sizes that are a multiple - * of the page size. Handling that is what this whole thing is about. - */ - pMI->txt_zero_fd = -1; - pMI->txt_errno = 0; - - { - void* pNuls; -#ifdef _SC_PAGESIZE - size_t pgsz = sysconf(_SC_PAGESIZE); -#else - size_t pgsz = getpagesize(); -#endif - /* - * Compute the pagesize rounded mapped memory size. - * IF this is not the same as the file size, then there are NUL's - * at the end of the file mapping and all is okay. - */ - pMI->txt_full_size = (pMI->txt_size + (pgsz - 1)) & ~(pgsz - 1); - if (pMI->txt_size != pMI->txt_full_size) - return pMI->txt_data; - - /* - * Still here? We have to remap the trailing inaccessible page - * either anonymously or to /dev/zero. - */ - pMI->txt_full_size += pgsz; -#if defined(MAP_ANONYMOUS) - pNuls = mmap( - (void*)(((char*)pMI->txt_data) + pMI->txt_size), - pgsz, PROT_READ|PROT_WRITE, - MAP_ANONYMOUS|MAP_FIXED|MAP_PRIVATE, AO_INVALID_FD, (size_t)0); - - if (pNuls != MAP_FAILED_PTR) - return pMI->txt_data; - - pMI->txt_errno = errno; - -#elif defined(HAVE_DEV_ZERO) - pMI->txt_zero_fd = open( "/dev/zero", O_RDONLY ); - - if (pMI->txt_zero_fd == AO_INVALID_FD) { - pMI->txt_errno = errno; - - } else { - pNuls = mmap( - (void*)(((char*)pMI->txt_data) + pMI->txt_size), pgsz, - PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, - pMI->txt_zero_fd, 0 ); - - if (pNuls != MAP_FAILED_PTR) - return pMI->txt_data; - - pMI->txt_errno = errno; - close( pMI->txt_zero_fd ); - pMI->txt_zero_fd = -1; - } -#endif - - pMI->txt_full_size = pMI->txt_size; - } - - { - void* p = AGALOC( pMI->txt_size+1, "file text" ); - memcpy( p, pMI->txt_data, pMI->txt_size ); - ((char*)p)[pMI->txt_size] = NUL; - munmap(pMI->txt_data, pMI->txt_size ); - pMI->txt_data = p; - } - pMI->txt_alloc = 1; - return pMI->txt_data; - -#else /* * * * * * no HAVE_MMAP * * * * * */ - - pMI->txt_data = AGALOC( pMI->txt_size+1, "file text" ); - if (pMI->txt_data == NULL) { - pMI->txt_errno = ENOMEM; - goto fail_return; - } - - { - size_t sz = pMI->txt_size; - char* pz = pMI->txt_data; - - while (sz > 0) { - ssize_t rdct = read( pMI->txt_fd, pz, sz ); - if (rdct <= 0) { - pMI->txt_errno = errno; - fprintf( stderr, zFSErrReadFile, - errno, strerror( errno ), pzFile ); - free( pMI->txt_data ); - goto fail_return; - } - - pz += rdct; - sz -= rdct; - } - - *pz = NUL; - } - - /* - * We never need a dummy page mapped in - */ - pMI->txt_zero_fd = -1; - pMI->txt_errno = 0; - - return pMI->txt_data; - -#endif /* * * * * * no HAVE_MMAP * * * * * */ - - fail_return: - if (pMI->txt_fd >= 0) { - close( pMI->txt_fd ); - pMI->txt_fd = -1; - } - errno = pMI->txt_errno; - pMI->txt_data = MAP_FAILED_PTR; - return pMI->txt_data; -} - - -/*=export_func text_munmap - * private: - * - * what: unmap the data mapped in by text_mmap - * - * arg: tmap_info_t*, mapinfo, info about the mapping - * - * ret-type: int - * ret-desc: -1 or 0. @file{errno} will have the error code. - * - * doc: - * - * This routine will unmap the data mapped in with @code{text_mmap} and close - * the associated file descriptors opened by that function. - * - * see: munmap(2), close(2) - * - * err: Any error code issued by munmap(2) or close(2) is possible. -=*/ -int -text_munmap( tmap_info_t* pMI ) -{ -#ifdef HAVE_MMAP - int res = 0; - if (pMI->txt_alloc) { - /* - * IF the user has write permission and the text is not mapped private, - * then write back any changes. Hopefully, nobody else has modified - * the file in the mean time. - */ - if ( ((pMI->txt_prot & PROT_WRITE) != 0) - && ((pMI->txt_flags & MAP_PRIVATE) == 0)) { - - if (lseek(pMI->txt_fd, (size_t)0, SEEK_SET) != 0) - goto error_return; - - res = (write( pMI->txt_fd, pMI->txt_data, pMI->txt_size ) < 0) - ? errno : 0; - } - - AGFREE( pMI->txt_data ); - errno = res; - } else { - res = munmap( pMI->txt_data, pMI->txt_full_size ); - } - if (res != 0) - goto error_return; - - res = close( pMI->txt_fd ); - if (res != 0) - goto error_return; - - pMI->txt_fd = -1; - errno = 0; - if (pMI->txt_zero_fd != -1) { - res = close( pMI->txt_zero_fd ); - pMI->txt_zero_fd = -1; - } - - error_return: - pMI->txt_errno = errno; - return res; -#else /* HAVE_MMAP */ - - errno = 0; - /* - * IF the memory is writable *AND* it is not private (copy-on-write) - * *AND* the memory is "sharable" (seen by other processes) - * THEN rewrite the data. - */ - if ( FILE_WRITABLE(pMI->txt_prot, pMI->txt_flags) - && (lseek( pMI->txt_fd, 0, SEEK_SET ) >= 0) ) { - write( pMI->txt_fd, pMI->txt_data, pMI->txt_size ); - } - - close( pMI->txt_fd ); - pMI->txt_fd = -1; - pMI->txt_errno = errno; - free( pMI->txt_data ); - - return pMI->txt_errno; -#endif /* HAVE_MMAP */ -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/text_mmap.c */ diff --git a/contrib/ntp/libopts/tokenize.c b/contrib/ntp/libopts/tokenize.c deleted file mode 100644 index 0e576ce26..000000000 --- a/contrib/ntp/libopts/tokenize.c +++ /dev/null @@ -1,321 +0,0 @@ -/* - * This file defines the string_tokenize interface - * Time-stamp: "2006-06-24 15:27:49 bkorb" - * - * string_tokenize copyright 2005 Bruce Korb - * - * string_tokenize is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * string_tokenize is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with string_tokenize; if not, write to: - * The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - */ -#include -#include -#include - -#define cc_t const unsigned char -#define ch_t unsigned char - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -copy_cooked( ch_t** ppDest, char const ** ppSrc ); - -static void -copy_raw( ch_t** ppDest, char const ** ppSrc ); -/* = = = END-STATIC-FORWARD = = = */ - -static void -copy_cooked( ch_t** ppDest, char const ** ppSrc ) -{ - ch_t* pDest = (ch_t*)*ppDest; - const ch_t* pSrc = (const ch_t*)(*ppSrc + 1); - - for (;;) { - ch_t ch = *(pSrc++); - switch (ch) { - case NUL: *ppSrc = NULL; return; - case '"': goto done; - case '\\': - pSrc += ao_string_cook_escape_char( (char*)pSrc, (char*)&ch, 0x7F ); - if (ch == 0x7F) - break; - /* FALLTHROUGH */ - - default: - *(pDest++) = ch; - } - } - - done: - *ppDest = (ch_t*)pDest; /* next spot for storing character */ - *ppSrc = (char const *)pSrc; /* char following closing quote */ -} - - -static void -copy_raw( ch_t** ppDest, char const ** ppSrc ) -{ - ch_t* pDest = *ppDest; - cc_t* pSrc = (cc_t*) (*ppSrc + 1); - - for (;;) { - ch_t ch = *(pSrc++); - switch (ch) { - case NUL: *ppSrc = NULL; return; - case '\'': goto done; - case '\\': - /* - * *Four* escapes are handled: newline removal, escape char - * quoting and apostrophe quoting - */ - switch (*pSrc) { - case NUL: *ppSrc = NULL; return; - case '\r': - if (*(++pSrc) == '\n') - ++pSrc; - continue; - - case '\n': - ++pSrc; - continue; - - case '\'': - ch = '\''; - /* FALLTHROUGH */ - - case '\\': - ++pSrc; - break; - } - /* FALLTHROUGH */ - - default: - *(pDest++) = ch; - } - } - - done: - *ppDest = pDest; /* next spot for storing character */ - *ppSrc = (char const *) pSrc; /* char following closing quote */ -} - - -/*=export_func ao_string_tokenize - * - * what: tokenize an input string - * - * arg: + char const* + string + string to be tokenized + - * - * ret_type: token_list_t* - * ret_desc: pointer to a structure that lists each token - * - * doc: - * - * This function will convert one input string into a list of strings. - * The list of strings is derived by separating the input based on - * white space separation. However, if the input contains either single - * or double quote characters, then the text after that character up to - * a matching quote will become the string in the list. - * - * The returned pointer should be deallocated with @code{free(3C)} when - * are done using the data. The data are placed in a single block of - * allocated memory. Do not deallocate individual token/strings. - * - * The structure pointed to will contain at least these two fields: - * @table @samp - * @item tkn_ct - * The number of tokens found in the input string. - * @item tok_list - * An array of @code{tkn_ct + 1} pointers to substring tokens, with - * the last pointer set to NULL. - * @end table - * - * There are two types of quoted strings: single quoted (@code{'}) and - * double quoted (@code{"}). Singly quoted strings are fairly raw in that - * escape characters (@code{\\}) are simply another character, except when - * preceding the following characters: - * @example - * @code{\\} double backslashes reduce to one - * @code{'} incorporates the single quote into the string - * @code{\n} suppresses both the backslash and newline character - * @end example - * - * Double quote strings are formed according to the rules of string - * constants in ANSI-C programs. - * - * example: - * @example - * #include - * int ix; - * token_list_t* ptl = ao_string_tokenize( some_string ) - * for (ix = 0; ix < ptl->tkn_ct; ix++) - * do_something_with_tkn( ptl->tkn_list[ix] ); - * free( ptl ); - * @end example - * Note that everything is freed with the one call to @code{free(3C)}. - * - * err: - * NULL is returned and @code{errno} will be set to indicate the problem: - * @itemize @bullet - * @item - * @code{EINVAL} - There was an unterminated quoted string. - * @item - * @code{ENOENT} - The input string was empty. - * @item - * @code{ENOMEM} - There is not enough memory. - * @end itemize -=*/ -token_list_t* -ao_string_tokenize( char const* str ) -{ - int max_token_ct = 1; /* allow for trailing NUL on string */ - token_list_t* res; - - if (str == NULL) goto bogus_str; - - /* - * Trim leading white space. Use "ENOENT" and a NULL return to indicate - * an empty string was passed. - */ - while (isspace( (ch_t)*str )) str++; - if (*str == NUL) { - bogus_str: - errno = ENOENT; - return NULL; - } - - /* - * Take an approximate count of tokens. If no quoted strings are used, - * it will be accurate. If quoted strings are used, it will be a little - * high and we'll squander the space for a few extra pointers. - */ - { - cc_t* pz = (cc_t*)str; - - do { - max_token_ct++; - while (! isspace( *++pz )) - if (*pz == NUL) goto found_nul; - while (isspace( *pz )) pz++; - } while (*pz != NUL); - - found_nul: - ; - } - - res = malloc( sizeof(*res) + strlen(str) + (max_token_ct * sizeof(ch_t*)) ); - if (res == NULL) { - errno = ENOMEM; - return res; - } - - /* - * Now copy each token into the output buffer. - */ - { - ch_t* pzDest = (ch_t*)(res->tkn_list + (max_token_ct + 1)); - res->tkn_ct = 0; - - do { - res->tkn_list[ res->tkn_ct++ ] = pzDest; - for (;;) { - int ch = (ch_t)*str; - if (isspace( ch )) { - found_white_space: - while (isspace( (ch_t)*++str )) ; - break; - } - - switch (ch) { - case '"': - copy_cooked( &pzDest, &str ); - if (str == NULL) { - free(res); - errno = EINVAL; - return NULL; - } - if (isspace( (ch_t)*str )) - goto found_white_space; - break; - - case '\'': - copy_raw( &pzDest, &str ); - if (str == NULL) { - free(res); - errno = EINVAL; - return NULL; - } - if (isspace( (ch_t)*str )) - goto found_white_space; - break; - - case NUL: - goto copy_done; - - default: - str++; - *(pzDest++) = ch; - } - } copy_done:; - - /* - * NUL terminate the last token and see if we have any more tokens. - */ - *(pzDest++) = NUL; - } while (*str != NUL); - - res->tkn_list[ res->tkn_ct ] = NULL; - } - - return res; -} - -#ifdef TEST -#include -#include - -int -main( int argc, char** argv ) -{ - if (argc == 1) { - printf("USAGE: %s arg [ ... ]\n", *argv); - return 1; - } - while (--argc > 0) { - char* arg = *(++argv); - token_list_t* p = ao_string_tokenize( arg ); - if (p == NULL) { - printf( "Parsing string ``%s'' failed:\n\terrno %d (%s)\n", - arg, errno, strerror( errno )); - } else { - int ix = 0; - printf( "Parsed string ``%s''\ninto %d tokens:\n", arg, p->tkn_ct ); - do { - printf( " %3d: ``%s''\n", ix+1, p->tkn_list[ix] ); - } while (++ix < p->tkn_ct); - free(p); - } - } - return 0; -} -#endif - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/tokenize.c */ diff --git a/contrib/ntp/libopts/usage.c b/contrib/ntp/libopts/usage.c deleted file mode 100644 index 960339b63..000000000 --- a/contrib/ntp/libopts/usage.c +++ /dev/null @@ -1,740 +0,0 @@ - -/* - * usage.c $Id: usage.c,v 4.15 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2007-04-15 11:02:46 bkorb" - * - * This module implements the default usage procedure for - * Automated Options. It may be overridden, of course. - * - * Sort options: - --start=END-[S]TATIC-FORWARD --patt='^/\*($|[^:])' \ - --out=xx.c key='^[a-zA-Z0-9_]+\(' --trail='^/\*:' \ - --spac=2 --input=usage.c - */ - -/* - * Automated Options copyright 1992-2007 Bruce Korb - * - * Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -#define OPTPROC_L_N_S (OPTPROC_LONGOPT | OPTPROC_SHORTOPT) - -static arg_types_t argTypes; - -FILE* option_usage_fp = NULL; -static char zOptFmtLine[ 16 ]; -static ag_bool displayEnum; - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static ag_bool -checkGNUUsage( tOptions* pOpts ); - -static void -printExtendedUsage( - tOptions* pOptions, - tOptDesc* pOD, - arg_types_t* pAT ); - -static void -printInitList( - tCC* const* papz, - ag_bool* pInitIntro, - tCC* pzRc, - tCC* pzPN ); - -static void -printOneUsage( - tOptions* pOptions, - tOptDesc* pOD, - arg_types_t* pAT ); - -static void -printOptionUsage( - tOptions* pOpts, - int ex_code, - tCC* pOptTitle ); - -static void -printProgramDetails( tOptions* pOptions ); - -static int -setGnuOptFmts( tOptions* pOpts, tCC** ppT ); - -static int -setStdOptFmts( tOptions* pOpts, tCC** ppT ); -/* = = = END-STATIC-FORWARD = = = */ - - -/* - * Figure out if we should try to format usage text sort-of like - * the way many GNU programs do. - */ -static ag_bool -checkGNUUsage( tOptions* pOpts ) -{ - char* pz = getenv( "AUTOOPTS_USAGE" ); - if (pz == NULL) - ; - - else if (streqvcmp( pz, "gnu" ) == 0) - pOpts->fOptSet |= OPTPROC_GNUUSAGE; - - else if (streqvcmp( pz, "autoopts" ) == 0) - pOpts->fOptSet &= ~OPTPROC_GNUUSAGE; - - return (pOpts->fOptSet & OPTPROC_GNUUSAGE) ? AG_TRUE : AG_FALSE; -} - - -/*=export_func optionOnlyUsage - * - * what: Print usage text for just the options - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + int + ex_code + exit code for calling exit(3) + - * - * doc: - * This routine will print only the usage for each option. - * This function may be used when the emitted usage must incorporate - * information not available to AutoOpts. -=*/ -void -optionOnlyUsage( - tOptions* pOpts, - int ex_code ) -{ - tCC* pOptTitle = NULL; - - /* - * Determine which header and which option formatting strings to use - */ - if (checkGNUUsage(pOpts)) { - (void)setGnuOptFmts( pOpts, &pOptTitle ); - } - else { - (void)setStdOptFmts( pOpts, &pOptTitle ); - } - - printOptionUsage( pOpts, ex_code, pOptTitle ); -} - - -/*=export_func optionUsage - * private: - * - * what: Print usage text - * arg: + tOptions* + pOptions + program options descriptor + - * arg: + int + exitCode + exit code for calling exit(3) + - * - * doc: - * This routine will print usage in both GNU-standard and AutoOpts-expanded - * formats. The descriptor specifies the default, but AUTOOPTS_USAGE will - * over-ride this, providing the value of it is set to either "gnu" or - * "autoopts". This routine will @strong{not} return. - * - * If "exitCode" is "EX_USAGE" (normally 64), then output will to to stdout - * and the actual exit code will be "EXIT_SUCCESS". -=*/ -void -optionUsage( - tOptions* pOptions, - int usage_exit_code ) -{ - int actual_exit_code = - (usage_exit_code == EX_USAGE) ? EXIT_SUCCESS : usage_exit_code; - - displayEnum = AG_FALSE; - - /* - * Paged usage will preset option_usage_fp to an output file. - * If it hasn't already been set, then set it to standard output - * on successful exit (help was requested), otherwise error out. - */ - if (option_usage_fp == NULL) - option_usage_fp = (actual_exit_code != EXIT_SUCCESS) ? stderr : stdout; - - fprintf( option_usage_fp, pOptions->pzUsageTitle, pOptions->pzProgName ); - - { - tCC* pOptTitle = NULL; - - /* - * Determine which header and which option formatting strings to use - */ - if (checkGNUUsage(pOptions)) { - int flen = setGnuOptFmts( pOptions, &pOptTitle ); - sprintf( zOptFmtLine, zFmtFmt, flen ); - fputc( '\n', option_usage_fp ); - } - else { - int flen = setStdOptFmts( pOptions, &pOptTitle ); - sprintf( zOptFmtLine, zFmtFmt, flen ); - - /* - * When we exit with EXIT_SUCCESS and the first option is a doc - * option, we do *NOT* want to emit the column headers. - * Otherwise, we do. - */ - if ( (usage_exit_code != EXIT_SUCCESS) - || ((pOptions->pOptDesc->fOptState & OPTST_DOCUMENT) == 0) ) - - fputs( pOptTitle, option_usage_fp ); - } - - printOptionUsage( pOptions, usage_exit_code, pOptTitle ); - } - - /* - * Describe the mechanics of denoting the options - */ - switch (pOptions->fOptSet & OPTPROC_L_N_S) { - case OPTPROC_L_N_S: fputs( zFlagOkay, option_usage_fp ); break; - case OPTPROC_SHORTOPT: break; - case OPTPROC_LONGOPT: fputs( zNoFlags, option_usage_fp ); break; - case 0: fputs( zOptsOnly, option_usage_fp ); break; - } - - if ((pOptions->fOptSet & OPTPROC_NUM_OPT) != 0) { - fputs( zNumberOpt, option_usage_fp ); - } - - if ((pOptions->fOptSet & OPTPROC_REORDER) != 0) { - fputs( zReorder, option_usage_fp ); - } - - if (pOptions->pzExplain != NULL) - fputs( pOptions->pzExplain, option_usage_fp ); - - /* - * IF the user is asking for help (thus exiting with SUCCESS), - * THEN see what additional information we can provide. - */ - if (usage_exit_code == EXIT_SUCCESS) - printProgramDetails( pOptions ); - - if (pOptions->pzBugAddr != NULL) - fprintf( option_usage_fp, zPlsSendBugs, pOptions->pzBugAddr ); - fflush( option_usage_fp ); - - exit( actual_exit_code ); -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * PER OPTION TYPE USAGE INFORMATION - */ -static void -printExtendedUsage( - tOptions* pOptions, - tOptDesc* pOD, - arg_types_t* pAT ) -{ - /* - * IF there are option conflicts or dependencies, - * THEN print them here. - */ - if ( (pOD->pOptMust != NULL) - || (pOD->pOptCant != NULL) ) { - - fputs( zTabHyp, option_usage_fp ); - - /* - * DEPENDENCIES: - */ - if (pOD->pOptMust != NULL) { - const int* pOptNo = pOD->pOptMust; - - fputs( zReqThese, option_usage_fp ); - for (;;) { - fprintf( option_usage_fp, zTabout, pOptions->pOptDesc[ - *pOptNo ].pz_Name ); - if (*++pOptNo == NO_EQUIVALENT) - break; - } - - if (pOD->pOptCant != NULL) - fputs( zTabHypAnd, option_usage_fp ); - } - - /* - * CONFLICTS: - */ - if (pOD->pOptCant != NULL) { - const int* pOptNo = pOD->pOptCant; - - fputs( zProhib, option_usage_fp ); - for (;;) { - fprintf( option_usage_fp, zTabout, pOptions->pOptDesc[ - *pOptNo ].pz_Name ); - if (*++pOptNo == NO_EQUIVALENT) - break; - } - } - } - - /* - * IF there is a disablement string - * THEN print the disablement info - */ - if (pOD->pz_DisableName != NULL ) - fprintf( option_usage_fp, zDis, pOD->pz_DisableName ); - - /* - * IF the numeric option has a special callback, - * THEN call it, requesting the range or other special info - */ - if ( (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NUMERIC) - && (pOD->pOptProc != NULL) - && (pOD->pOptProc != optionNumericVal) ) { - (*(pOD->pOptProc))( pOptions, NULL ); - } - - /* - * IF the option defaults to being enabled, - * THEN print that out - */ - if (pOD->fOptState & OPTST_INITENABLED) - fputs( zEnab, option_usage_fp ); - - /* - * IF the option is in an equivalence class - * AND not the designated lead - * THEN print equivalence and leave it at that. - */ - if ( (pOD->optEquivIndex != NO_EQUIVALENT) - && (pOD->optEquivIndex != pOD->optActualIndex ) ) { - fprintf( option_usage_fp, zAlt, - pOptions->pOptDesc[ pOD->optEquivIndex ].pz_Name ); - return; - } - - /* - * IF this particular option can NOT be preset - * AND some form of presetting IS allowed, - * AND it is not an auto-managed option (e.g. --help, et al.) - * THEN advise that this option may not be preset. - */ - if ( ((pOD->fOptState & OPTST_NO_INIT) != 0) - && ( (pOptions->papzHomeList != NULL) - || (pOptions->pzPROGNAME != NULL) - ) - && (pOD->optIndex < pOptions->presetOptCt) - ) - - fputs( zNoPreset, option_usage_fp ); - - /* - * Print the appearance requirements. - */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_MEMBERSHIP) - fputs( zMembers, option_usage_fp ); - - else switch (pOD->optMinCt) { - case 1: - case 0: - switch (pOD->optMaxCt) { - case 0: fputs( zPreset, option_usage_fp ); break; - case NOLIMIT: fputs( zNoLim, option_usage_fp ); break; - case 1: break; - /* - * IF the max is more than one but limited, print "UP TO" message - */ - default: fprintf( option_usage_fp, zUpTo, pOD->optMaxCt ); break; - } - break; - - default: - /* - * More than one is required. Print the range. - */ - fprintf( option_usage_fp, zMust, pOD->optMinCt, pOD->optMaxCt ); - } - - if ( NAMED_OPTS( pOptions ) - && (pOptions->specOptIdx.default_opt == pOD->optIndex)) - fputs( zDefaultOpt, option_usage_fp ); -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Figure out where all the initialization files might live. - * This requires translating some environment variables and - * testing to see if a name is a directory or a file. It's - * squishy, but important to tell users how to find these files. - */ -static void -printInitList( - tCC* const* papz, - ag_bool* pInitIntro, - tCC* pzRc, - tCC* pzPN ) -{ - char zPath[ AG_PATH_MAX+1 ]; - - if (papz == NULL) - return; - - fputs( zPresetIntro, option_usage_fp ); - *pInitIntro = AG_FALSE; - - for (;;) { - char const* pzPath = *(papz++); - - if (pzPath == NULL) - break; - - if (optionMakePath(zPath, (int)sizeof( zPath ), pzPath, pzPN)) - pzPath = zPath; - - /* - * Print the name of the "homerc" file. If the "rcfile" name is - * not empty, we may or may not print that, too... - */ - fprintf( option_usage_fp, zPathFmt, pzPath ); - if (*pzRc != NUL) { - struct stat sb; - - /* - * IF the "homerc" file is a directory, - * then append the "rcfile" name. - */ - if ( (stat( pzPath, &sb ) == 0) - && S_ISDIR( sb.st_mode ) ) { - fputc( DIRCH, option_usage_fp ); - fputs( pzRc, option_usage_fp ); - } - } - - fputc( '\n', option_usage_fp ); - } -} - - -/* - * Print the usage information for a single option. - */ -static void -printOneUsage( - tOptions* pOptions, - tOptDesc* pOD, - arg_types_t* pAT ) -{ - /* - * Flag prefix: IF no flags at all, then omit it. If not printable - * (not allowed for this option), then blank, else print it. - * Follow it with a comma if we are doing GNU usage and long - * opts are to be printed too. - */ - if ((pOptions->fOptSet & OPTPROC_SHORTOPT) == 0) - fputs( pAT->pzSpc, option_usage_fp ); - else if (! isgraph( pOD->optValue)) { - if ( (pOptions->fOptSet & (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) - == (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) - fputc( ' ', option_usage_fp ); - fputs( pAT->pzNoF, option_usage_fp ); - } else { - fprintf( option_usage_fp, " -%c", pOD->optValue ); - if ( (pOptions->fOptSet & (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) - == (OPTPROC_GNUUSAGE|OPTPROC_LONGOPT)) - fputs( ", ", option_usage_fp ); - } - - { - char z[ 80 ]; - tCC* pzArgType; - /* - * Determine the argument type string first on its usage, then, - * when the option argument is required, base the type string on the - * argument type. - */ - if (OPTST_GET_ARGTYPE(pOD->fOptState) == OPARG_TYPE_NONE) { - pzArgType = pAT->pzNo; - - } else if (pOD->fOptState & OPTST_ARG_OPTIONAL) { - pzArgType = pAT->pzOpt; - - } else switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { - case OPARG_TYPE_ENUMERATION: pzArgType = pAT->pzKey; break; - case OPARG_TYPE_MEMBERSHIP: pzArgType = pAT->pzKeyL; break; - case OPARG_TYPE_BOOLEAN: pzArgType = pAT->pzBool; break; - case OPARG_TYPE_NUMERIC: pzArgType = pAT->pzNum; break; - case OPARG_TYPE_HIERARCHY: pzArgType = pAT->pzNest; break; - case OPARG_TYPE_STRING: pzArgType = pAT->pzStr; break; - default: goto bogus_desc; break; - } - - snprintf( z, sizeof(z), pAT->pzOptFmt, pzArgType, pOD->pz_Name, - (pOD->optMinCt != 0) ? pAT->pzReq : pAT->pzOpt ); - - fprintf( option_usage_fp, zOptFmtLine, z, pOD->pzText ); - - switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { - case OPARG_TYPE_ENUMERATION: - case OPARG_TYPE_MEMBERSHIP: - displayEnum = (pOD->pOptProc != NULL) ? AG_TRUE : displayEnum; - } - } - return; - - bogus_desc: - fprintf( stderr, zInvalOptDesc, pOD->pz_Name ); - exit( EX_SOFTWARE ); -} - - -/* - * Print out the usage information for just the options. - */ -static void -printOptionUsage( - tOptions* pOpts, - int ex_code, - tCC* pOptTitle ) -{ - int ct = pOpts->optCt; - int optNo = 0; - tOptDesc* pOD = pOpts->pOptDesc; - int docCt = 0; - - do { - if ((pOD->fOptState & OPTST_OMITTED) != 0) - continue; - - if ((pOD->fOptState & OPTST_DOCUMENT) != 0) { - if (ex_code == EXIT_SUCCESS) { - fprintf(option_usage_fp, argTypes.pzBrk, pOD->pzText, - pOptTitle); - docCt++; - } - - continue; - } - - /* - * IF this is the first auto-opt maintained option - * *AND* we are doing a full help - * *AND* there are documentation options - * *AND* the last one was not a doc option, - * THEN document that the remaining options are not user opts - */ - if ( (pOpts->presetOptCt == optNo) - && (ex_code == EXIT_SUCCESS) - && (docCt > 0) - && ((pOD[-1].fOptState & OPTST_DOCUMENT) == 0) ) - fprintf( option_usage_fp, argTypes.pzBrk, zAuto, pOptTitle ); - - printOneUsage( pOpts, pOD, &argTypes ); - - /* - * IF we were invoked because of the --help option, - * THEN print all the extra info - */ - if (ex_code == EXIT_SUCCESS) - printExtendedUsage( pOpts, pOD, &argTypes ); - - } while (pOD++, optNo++, (--ct > 0)); - - fputc( '\n', option_usage_fp ); -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * PROGRAM DETAILS - */ -static void -printProgramDetails( tOptions* pOptions ) -{ - ag_bool initIntro = AG_TRUE; - - /* - * Display all the places we look for config files - */ - printInitList( pOptions->papzHomeList, &initIntro, - pOptions->pzRcName, pOptions->pzProgPath ); - - /* - * Let the user know about environment variable settings - */ - if ((pOptions->fOptSet & OPTPROC_ENVIRON) != 0) { - if (initIntro) - fputs( zPresetIntro, option_usage_fp ); - - fprintf( option_usage_fp, zExamineFmt, pOptions->pzPROGNAME ); - } - - /* - * IF we found an enumeration, - * THEN hunt for it again. Call the handler proc with a NULL - * option struct pointer. That tells it to display the keywords. - */ - if (displayEnum) { - int ct = pOptions->optCt; - int optNo = 0; - tOptDesc* pOD = pOptions->pOptDesc; - - fputc( '\n', option_usage_fp ); - fflush( option_usage_fp ); - do { - switch (OPTST_GET_ARGTYPE(pOD->fOptState)) { - case OPARG_TYPE_ENUMERATION: - case OPARG_TYPE_MEMBERSHIP: - (*(pOD->pOptProc))( NULL, pOD ); - } - } while (pOD++, optNo++, (--ct > 0)); - } - - /* - * If there is a detail string, now is the time for that. - */ - if (pOptions->pzDetail != NULL) - fputs( pOptions->pzDetail, option_usage_fp ); -} - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * OPTION LINE FORMATTING SETUP - * - * The "OptFmt" formats receive three arguments: - * 1. the type of the option's argument - * 2. the long name of the option - * 3. "YES" or "no ", depending on whether or not the option must appear - * on the command line. - * These formats are used immediately after the option flag (if used) has - * been printed. - * - * Set up the formatting for GNU-style output - */ -static int -setGnuOptFmts( tOptions* pOpts, tCC** ppT ) -{ - int flen = 22; - *ppT = zNoRq_ShrtTtl; - - argTypes.pzStr = zGnuStrArg; - argTypes.pzReq = zOneSpace; - argTypes.pzNum = zGnuNumArg; - argTypes.pzKey = zGnuKeyArg; - argTypes.pzKeyL = zGnuKeyLArg; - argTypes.pzBool = zGnuBoolArg; - argTypes.pzNest = zGnuNestArg; - argTypes.pzOpt = zGnuOptArg; - argTypes.pzNo = zOneSpace; - argTypes.pzBrk = zGnuBreak; - argTypes.pzNoF = zSixSpaces; - argTypes.pzSpc = zThreeSpaces; - - switch (pOpts->fOptSet & OPTPROC_L_N_S) { - case OPTPROC_L_N_S: argTypes.pzOptFmt = zGnuOptFmt; break; - case OPTPROC_LONGOPT: argTypes.pzOptFmt = zGnuOptFmt; break; - case 0: argTypes.pzOptFmt = zGnuOptFmt + 2; break; - case OPTPROC_SHORTOPT: - argTypes.pzOptFmt = zShrtGnuOptFmt; - zGnuStrArg[0] = zGnuNumArg[0] = zGnuKeyArg[0] = zGnuBoolArg[0] = ' '; - argTypes.pzOpt = " [arg]"; - flen = 8; - break; - } - - return flen; -} - - -/* - * Standard (AutoOpts normal) option line formatting - */ -static int -setStdOptFmts( tOptions* pOpts, tCC** ppT ) -{ - int flen = 0; - - argTypes.pzStr = zStdStrArg; - argTypes.pzReq = zStdReqArg; - argTypes.pzNum = zStdNumArg; - argTypes.pzKey = zStdKeyArg; - argTypes.pzKeyL = zStdKeyLArg; - argTypes.pzBool = zStdBoolArg; - argTypes.pzNest = zStdNestArg; - argTypes.pzOpt = zStdOptArg; - argTypes.pzNo = zStdNoArg; - argTypes.pzBrk = zStdBreak; - argTypes.pzNoF = zFiveSpaces; - argTypes.pzSpc = zTwoSpaces; - - switch (pOpts->fOptSet & (OPTPROC_NO_REQ_OPT | OPTPROC_SHORTOPT)) { - case (OPTPROC_NO_REQ_OPT | OPTPROC_SHORTOPT): - *ppT = zNoRq_ShrtTtl; - argTypes.pzOptFmt = zNrmOptFmt; - flen = 19; - break; - - case OPTPROC_NO_REQ_OPT: - *ppT = zNoRq_NoShrtTtl; - argTypes.pzOptFmt = zNrmOptFmt; - flen = 19; - break; - - case OPTPROC_SHORTOPT: - *ppT = zReq_ShrtTtl; - argTypes.pzOptFmt = zReqOptFmt; - flen = 24; - break; - - case 0: - *ppT = zReq_NoShrtTtl; - argTypes.pzOptFmt = zReqOptFmt; - flen = 24; - } - - return flen; -} - - -/*: - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/usage.c */ diff --git a/contrib/ntp/libopts/version.c b/contrib/ntp/libopts/version.c deleted file mode 100644 index 85949d5d3..000000000 --- a/contrib/ntp/libopts/version.c +++ /dev/null @@ -1,178 +0,0 @@ - -/* $Id: version.c,v 4.10 2007/04/28 22:19:23 bkorb Exp $ - * Time-stamp: "2007-04-28 10:08:34 bkorb" - * - * This module implements the default usage procedure for - * Automated Options. It may be overridden, of course. - */ - -static char const zAOV[] = - "Automated Options version %s, copyright (c) 1999-2007 Bruce Korb\n"; - -/* Automated Options is free software. - * You may redistribute it and/or modify it under the terms of the - * GNU General Public License, as published by the Free Software - * Foundation; either version 2, or (at your option) any later version. - * - * Automated Options is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Automated Options. See the file "COPYING". If not, - * write to: The Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301, USA. - * - * As a special exception, Bruce Korb gives permission for additional - * uses of the text contained in his release of AutoOpts. - * - * The exception is that, if you link the AutoOpts library with other - * files to produce an executable, this does not by itself cause the - * resulting executable to be covered by the GNU General Public License. - * Your use of that executable is in no way restricted on account of - * linking the AutoOpts library code into it. - * - * This exception does not however invalidate any other reasons why - * the executable file might be covered by the GNU General Public License. - * - * This exception applies only to the code released by Bruce Korb under - * the name AutoOpts. If you copy code from other sources under the - * General Public License into a copy of AutoOpts, as the General Public - * License permits, the exception does not apply to the code that you add - * in this way. To avoid misleading anyone as to the status of such - * modified files, you must delete this exception notice from them. - * - * If you write modifications of your own for AutoOpts, it is your choice - * whether to permit this exception to apply to your modifications. - * If you do not wish that, delete this exception notice. - */ - -/* = = = START-STATIC-FORWARD = = = */ -/* static forward declarations maintained by :mkfwd */ -static void -printVersion( tOptions* pOpts, tOptDesc* pOD, FILE* fp ); -/* = = = END-STATIC-FORWARD = = = */ - -/*=export_func optionVersion - * - * what: return the compiled AutoOpts version number - * ret_type: char const* - * ret_desc: the version string in constant memory - * doc: - * Returns the full version string compiled into the library. - * The returned string cannot be modified. -=*/ -char const* -optionVersion( void ) -{ - static char const zVersion[] = - STR( AO_CURRENT.AO_REVISION ); - - return zVersion; -} - - -static void -printVersion( tOptions* pOpts, tOptDesc* pOD, FILE* fp ) -{ - char swCh; - - /* - * IF the optional argument flag is off, or the argument is not provided, - * then just print the version. - */ - if ( ((pOD->fOptState & OPTST_ARG_OPTIONAL) == 0) - || (pOD->optArg.argString == NULL)) - swCh = 'v'; - else swCh = tolower(pOD->optArg.argString[0]); - - if (pOpts->pzFullVersion != NULL) { - fputs( pOpts->pzFullVersion, fp ); - fputc( '\n', fp ); - - } else { - char const *pz = pOpts->pzUsageTitle; - do { fputc(*pz, fp); } while (*(pz++) != '\n'); - } - - switch (swCh) { - case NUL: /* arg provided, but empty */ - case 'v': - break; - - case 'c': - if (pOpts->pzCopyright != NULL) { - fputs( pOpts->pzCopyright, fp ); - fputc( '\n', fp ); - } - fprintf( fp, zAOV, optionVersion() ); - if (pOpts->pzBugAddr != NULL) - fprintf( fp, zPlsSendBugs, pOpts->pzBugAddr ); - break; - - case 'n': - if (pOpts->pzCopyright != NULL) { - fputs( pOpts->pzCopyright, fp ); - fputc( '\n', fp ); - fputc( '\n', fp ); - } - - if (pOpts->pzCopyNotice != NULL) { - fputs( pOpts->pzCopyNotice, fp ); - fputc( '\n', fp ); - } - - fprintf( fp, zAOV, optionVersion() ); - if (pOpts->pzBugAddr != NULL) - fprintf( fp, zPlsSendBugs, pOpts->pzBugAddr ); - break; - - default: - fprintf( stderr, zBadVerArg, swCh ); - exit( EXIT_FAILURE ); - } - - exit( EXIT_SUCCESS ); -} - -/*=export_func optionPrintVersion - * private: - * - * what: Print the program version - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * This routine will print the version to stdout. -=*/ -void -optionPrintVersion( tOptions* pOpts, tOptDesc* pOD ) -{ - printVersion( pOpts, pOD, stdout ); -} - -/*=export_func optionVersionStderr - * private: - * - * what: Print the program version to stderr - * arg: + tOptions* + pOpts + program options descriptor + - * arg: + tOptDesc* + pOptDesc + the descriptor for this arg + - * - * doc: - * This routine will print the version to stderr. -=*/ -void -optionVersionStderr( tOptions* pOpts, tOptDesc* pOD ) -{ - printVersion( pOpts, pOD, stderr ); -} - -/* - * Local Variables: - * mode: C - * c-file-style: "stroustrup" - * indent-tabs-mode: nil - * End: - * end of autoopts/version.c */ diff --git a/contrib/ntp/libparse/Makefile.am b/contrib/ntp/libparse/Makefile.am index 8e21463b2..2988e08e2 100644 --- a/contrib/ntp/libparse/Makefile.am +++ b/contrib/ntp/libparse/Makefile.am @@ -1,168 +1,173 @@ -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL= +BUILT_SOURCES = $(VPHACK) info_trimble.c $(VPHACK_AFTER) +CLEANFILES = noinst_LIBRARIES = @MAKE_LIBPARSE@ @MAKE_LIBPARSE_KERNEL@ EXTRA_LIBRARIES = libparse.a libparse_kernel.a EXTRA_PROGRAMS = parsestreams parsesolaris noinst_PROGRAMS = @MAKE_PARSEKMODULE@ -CLEANFILES = libparse.a libparse_kernel.a K_CFLAGS = -DPARSESTREAM -DNTP_NEED_BOPS +# info_trimble.c was mistakenly created in the build directory +# previously. It is located in $(srcdir) and any updates must +# end up there. + +# +# VPHACK and VPHACK_AFTER are enabled on non-GNU makes (such as +# BSD make) to work around build/dependency issues where we want +# built source files to live in srcdir, as opposed to builddir. +# + +if VPATH_HACK +VPHACK= vphack +VPHACK_AFTER= vphack_after +else +VPHACK= +VPHACK_AFTER= +endif + +vphack: + test -e info_trimble.c || ln -s $(srcdir)/info_trimble.c . + +vphack_after: + test -L info_trimble.c || ( \ + mv info_trimble.c $(srcdir)/info_trimble.c && \ + ln -s $(srcdir)/info_trimble.c . \ + ) + libparse_a_SOURCES = parse.c \ - parse_conf.c \ - clk_meinberg.c \ - clk_schmid.c \ + parse_conf.c \ + clk_meinberg.c \ + clk_schmid.c \ clk_rawdcf.c \ clk_trimtsip.c \ - clk_dcf7000.c \ - clk_trimtaip.c \ - clk_rcc8000.c \ - clk_hopf6021.c \ - clk_computime.c \ + clk_dcf7000.c \ + clk_trimtaip.c \ + clk_rcc8000.c \ + clk_hopf6021.c \ + clk_computime.c \ clk_wharton.c \ clk_varitext.c \ - data_mbg.c \ + clk_sel240x.c \ + data_mbg.c \ info_trimble.c \ trim_info.c \ binio.c \ ieee754io.c \ mfp_mul.c \ - gpstolfp.c + gpstolfp.c \ + $(NULL) libparse_kernel_a_SOURCES = -libparse_kernel_a_LIBADD = kparse$U.o \ - kparse_conf$U.o \ - kclk_computime$U.o \ - kclk_dcf7000$U.o \ - kclk_hopf6021$U.o \ - kclk_meinberg$U.o \ - kclk_rawdcf$U.o \ - kclk_rcc8000$U.o \ - kclk_schmid$U.o \ - kclk_trimtaip$U.o \ - kclk_trimtsip$U.o \ - kclk_varitext$U.o \ - kclk_wharton$U.o \ - kbinio$U.o \ - kieee754io$U.o \ - kmfp_mul$U.o \ - kgpstolfp$U.o - - -INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/kernel -ETAGS_ARGS = Makefile.am +libparse_kernel_a_LIBADD = \ + kparse.o \ + kparse_conf.o \ + kclk_computime.o \ + kclk_dcf7000.o \ + kclk_hopf6021.o \ + kclk_meinberg.o \ + kclk_rawdcf.o \ + kclk_rcc8000.o \ + kclk_schmid.o \ + kclk_trimtaip.o \ + kclk_trimtsip.o \ + kclk_varitext.o \ + kclk_wharton.o \ + kclk_sel240x.o \ + kbinio.o \ + kieee754io.o \ + kmfp_mul.o \ + kgpstolfp.o \ + $(NULL) + +AM_CFLAGS = $(CFLAGS_NTP) + +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += -I$(top_srcdir)/kernel +AM_CPPFLAGS += $(CPPFLAGS_NTP) EXTRA_DIST = parsesolaris.c parsestreams.c mkinfo_scmd.sed mkinfo_rcmd.sed info_trimble.c -# -# create info_trimble.c -# -info_trimble.c: $(top_srcdir)/include/trimble.h mkinfo_rcmd.sed mkinfo_scmd.sed - @rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.c || rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.c || rm -f info_trimble.c +info_trimble.c: $(top_srcdir)/include/trimble.h $(srcdir)/Makefile.am $(srcdir)/mkinfo_scmd.sed $(srcdir)/mkinfo_rcmd.sed + sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.new + sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.new + mv -f info_trimble.new $@ + +#$(srcdir)/info_trimble.c: $(top_srcdir)/include/trimble.h $(srcdir)/Makefile.am $(srcdir)/mkinfo_scmd.sed $(srcdir)/mkinfo_rcmd.sed +# sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.new +# sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.new +# mv -f info_trimble.new $@ -kieee754io.o: ieee754io.c +kieee754io.o: $(srcdir)/ieee754io.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/ieee754io.c -o $@ -kmfp_mul.o: mfp_mul.c +kmfp_mul.o: $(srcdir)/mfp_mul.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/mfp_mul.c -o $@ -kgpstolfp.o: gpstolfp.c +kgpstolfp.o: $(srcdir)/gpstolfp.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/gpstolfp.c -o $@ -kbinio.o: binio.c +kbinio.o: $(srcdir)/binio.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/binio.c -o $@ -kclk_computime.o: clk_computime.c +kclk_computime.o: $(srcdir)/clk_computime.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_computime.c -o $@ -kclk_computime_.o: clk_computime_.c - $(COMPILE) $(K_CFLAGS) -c clk_computime_.c -o $@ - -kclk_dcf7000.o: clk_dcf7000.c +kclk_dcf7000.o: $(srcdir)/clk_dcf7000.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_dcf7000.c -o $@ -kclk_dcf7000_.o: clk_dcf7000_.c - $(COMPILE) $(K_CFLAGS) -c clk_dcf7000_.c -o $@ - -kclk_hopf6021.o: clk_hopf6021.c +kclk_hopf6021.o: $(srcdir)/clk_hopf6021.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_hopf6021.c -o $@ -kclk_hopf6021_.o: clk_hopf6021_.c - $(COMPILE) $(K_CFLAGS) -c clk_hopf6021_.c -o $@ - -kclk_meinberg.o: clk_meinberg.c +kclk_meinberg.o: $(srcdir)/clk_meinberg.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_meinberg.c -o $@ -kclk_meinberg_.o: clk_meinberg_.c - $(COMPILE) $(K_CFLAGS) -c clk_meinberg_.c -o $@ - -kclk_rawdcf.o: clk_rawdcf.c +kclk_rawdcf.o: $(srcdir)/clk_rawdcf.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_rawdcf.c -o $@ -kclk_rawdcf_.o: clk_rawdcf_.c - $(COMPILE) $(K_CFLAGS) -c clk_rawdcf_.c -o $@ - -kclk_rcc8000.o: clk_rcc8000.c +kclk_rcc8000.o: $(srcdir)/clk_rcc8000.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_rcc8000.c -o $@ -kclk_rcc8000_.o: clk_rcc8000_.c - $(COMPILE) $(K_CFLAGS) -c clk_rcc8000_.c -o $@ - -kclk_schmid.o: clk_schmid.c +kclk_schmid.o: $(srcdir)/clk_schmid.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_schmid.c -o $@ -kclk_schmid_.o: clk_schmid_.c - $(COMPILE) $(K_CFLAGS) -c clk_schmid_.c -o $@ - -kclk_trimtaip.o: clk_trimtaip.c +kclk_trimtaip.o: $(srcdir)/clk_trimtaip.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_trimtaip.c -o $@ -kclk_trimtaip_.o: clk_trimtaip_.c - $(COMPILE) $(K_CFLAGS) -c clk_trimtaip_.c -o $@ - -kclk_trimtsip.o: clk_trimtsip.c +kclk_trimtsip.o: $(srcdir)/clk_trimtsip.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_trimtsip.c -o $@ -kclk_trimtsip_.o: clk_trimtsip_.c - $(COMPILE) $(K_CFLAGS) -c clk_trimtsip_.c -o $@ - -kclk_varitext.o: clk_varitext.c +kclk_varitext.o: $(srcdir)/clk_varitext.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_varitext.c -o $@ -kclk_varitext_.o: clk_varitext_.c - $(COMPILE) $(K_CFLAGS) -c clk_varitext_.c -o $@ - -kclk_wharton.o: clk_wharton.c +kclk_wharton.o: $(srcdir)/clk_wharton.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_wharton.c -o $@ -kclk_wharton_.o: clk_wharton_.c - $(COMPILE) $(K_CFLAGS) -c clk_wharton_.c -o $@ +kclk_sel240x.o: $(srcdir)/clk_sel240x.c + $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_sel240x.c -o $@ -kparse.o: parse.c +kparse.o: $(srcdir)/parse.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/parse.c -o $@ -kparse_.o: parse_.c - $(COMPILE) $(K_CFLAGS) -c parse_.c -o $@ - -kparse_conf.o: parse_conf.c +kparse_conf.o: $(srcdir)/parse_conf.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/parse_conf.c -o $@ -kparse_conf_.o: parse_conf_.c - $(COMPILE) $(K_CFLAGS) -c parse_conf_.c -o $@ - parsestreams.loadable_module.o: $(parsestreams_OBJECTS) libparse_kernel.a ../libntp/libntp.a $(LD) -r -o $@ $(parsestreams_OBJECTS) libparse_kernel.a ../libntp/libntp.a parse: $(parsesolaris_OBJECTS) libparse_kernel.a ../libntp/libntp.a $(LD) -r -o $@ $(parsesolaris_OBJECTS) libparse_kernel.a ../libntp/libntp.a -../libntp/libntp.a: - cd ../libntp && $(MAKE) - parsesolaris.o: sys/systm.h sys/systm.h: - mkdir sys && \ + -mkdir sys sed -e '/ffs(.*)/d' < /usr/include/sys/systm.h > sys/systm.h + +## check-libparse is invoked by ntpd/Makefile.am +check-libparse: $(noinst_LIBRARIES) + @: do-nothing action to avoid default SCCS get + +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/libparse/Makefile.in b/contrib/ntp/libparse/Makefile.in index 7307c151b..2f13e1f47 100644 --- a/contrib/ntp/libparse/Makefile.in +++ b/contrib/ntp/libparse/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -17,6 +16,61 @@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -35,110 +89,230 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr EXTRA_PROGRAMS = parsestreams$(EXEEXT) parsesolaris$(EXEEXT) subdir = libparse -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = LIBRARIES = $(noinst_LIBRARIES) ARFLAGS ?= cru +AM_V_AR = $(am__v_AR_@AM_V@) +am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@) +am__v_AR_0 = @echo " AR " $@; +am__v_AR_1 = libparse_a_AR = $(AR) $(ARFLAGS) libparse_a_LIBADD = -am_libparse_a_OBJECTS = parse$U.$(OBJEXT) parse_conf$U.$(OBJEXT) \ - clk_meinberg$U.$(OBJEXT) clk_schmid$U.$(OBJEXT) \ - clk_rawdcf$U.$(OBJEXT) clk_trimtsip$U.$(OBJEXT) \ - clk_dcf7000$U.$(OBJEXT) clk_trimtaip$U.$(OBJEXT) \ - clk_rcc8000$U.$(OBJEXT) clk_hopf6021$U.$(OBJEXT) \ - clk_computime$U.$(OBJEXT) clk_wharton$U.$(OBJEXT) \ - clk_varitext$U.$(OBJEXT) data_mbg$U.$(OBJEXT) \ - info_trimble$U.$(OBJEXT) trim_info$U.$(OBJEXT) \ - binio$U.$(OBJEXT) ieee754io$U.$(OBJEXT) mfp_mul$U.$(OBJEXT) \ - gpstolfp$U.$(OBJEXT) +am__objects_1 = +am_libparse_a_OBJECTS = parse.$(OBJEXT) parse_conf.$(OBJEXT) \ + clk_meinberg.$(OBJEXT) clk_schmid.$(OBJEXT) \ + clk_rawdcf.$(OBJEXT) clk_trimtsip.$(OBJEXT) \ + clk_dcf7000.$(OBJEXT) clk_trimtaip.$(OBJEXT) \ + clk_rcc8000.$(OBJEXT) clk_hopf6021.$(OBJEXT) \ + clk_computime.$(OBJEXT) clk_wharton.$(OBJEXT) \ + clk_varitext.$(OBJEXT) clk_sel240x.$(OBJEXT) \ + data_mbg.$(OBJEXT) info_trimble.$(OBJEXT) trim_info.$(OBJEXT) \ + binio.$(OBJEXT) ieee754io.$(OBJEXT) mfp_mul.$(OBJEXT) \ + gpstolfp.$(OBJEXT) $(am__objects_1) libparse_a_OBJECTS = $(am_libparse_a_OBJECTS) libparse_kernel_a_AR = $(AR) $(ARFLAGS) -libparse_kernel_a_DEPENDENCIES = kparse$U.o kparse_conf$U.o \ - kclk_computime$U.o kclk_dcf7000$U.o kclk_hopf6021$U.o \ - kclk_meinberg$U.o kclk_rawdcf$U.o kclk_rcc8000$U.o \ - kclk_schmid$U.o kclk_trimtaip$U.o kclk_trimtsip$U.o \ - kclk_varitext$U.o kclk_wharton$U.o kbinio$U.o kieee754io$U.o \ - kmfp_mul$U.o kgpstolfp$U.o +am__DEPENDENCIES_1 = +libparse_kernel_a_DEPENDENCIES = kparse.o kparse_conf.o \ + kclk_computime.o kclk_dcf7000.o kclk_hopf6021.o \ + kclk_meinberg.o kclk_rawdcf.o kclk_rcc8000.o kclk_schmid.o \ + kclk_trimtaip.o kclk_trimtsip.o kclk_varitext.o kclk_wharton.o \ + kclk_sel240x.o kbinio.o kieee754io.o kmfp_mul.o kgpstolfp.o \ + $(am__DEPENDENCIES_1) am_libparse_kernel_a_OBJECTS = libparse_kernel_a_OBJECTS = $(am_libparse_kernel_a_OBJECTS) PROGRAMS = $(noinst_PROGRAMS) parsesolaris_SOURCES = parsesolaris.c -parsesolaris_OBJECTS = parsesolaris$U.$(OBJEXT) +parsesolaris_OBJECTS = parsesolaris.$(OBJEXT) parsesolaris_LDADD = $(LDADD) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = parsestreams_SOURCES = parsestreams.c -parsestreams_OBJECTS = parsestreams$U.$(OBJEXT) +parsestreams_OBJECTS = parsestreams.$(OBJEXT) parsestreams_LDADD = $(LDADD) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = SOURCES = $(libparse_a_SOURCES) $(libparse_kernel_a_SOURCES) \ parsesolaris.c parsestreams.c DIST_SOURCES = $(libparse_a_SOURCES) $(libparse_kernel_a_SOURCES) \ parsesolaris.c parsestreams.c +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depsver.mf \ + $(top_srcdir)/includes.mf $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -146,8 +320,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -157,15 +334,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -173,23 +411,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -236,62 +510,85 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +BUILT_SOURCES = $(VPHACK) info_trimble.c $(VPHACK_AFTER) check-libntp \ + .deps-ver +CLEANFILES = check-libntp .deps-ver noinst_LIBRARIES = @MAKE_LIBPARSE@ @MAKE_LIBPARSE_KERNEL@ EXTRA_LIBRARIES = libparse.a libparse_kernel.a noinst_PROGRAMS = @MAKE_PARSEKMODULE@ -CLEANFILES = libparse.a libparse_kernel.a K_CFLAGS = -DPARSESTREAM -DNTP_NEED_BOPS +@VPATH_HACK_FALSE@VPHACK = + +# info_trimble.c was mistakenly created in the build directory +# previously. It is located in $(srcdir) and any updates must +# end up there. + +# +# VPHACK and VPHACK_AFTER are enabled on non-GNU makes (such as +# BSD make) to work around build/dependency issues where we want +# built source files to live in srcdir, as opposed to builddir. +# +@VPATH_HACK_TRUE@VPHACK = vphack +@VPATH_HACK_FALSE@VPHACK_AFTER = +@VPATH_HACK_TRUE@VPHACK_AFTER = vphack_after libparse_a_SOURCES = parse.c \ - parse_conf.c \ - clk_meinberg.c \ - clk_schmid.c \ + parse_conf.c \ + clk_meinberg.c \ + clk_schmid.c \ clk_rawdcf.c \ clk_trimtsip.c \ - clk_dcf7000.c \ - clk_trimtaip.c \ - clk_rcc8000.c \ - clk_hopf6021.c \ - clk_computime.c \ + clk_dcf7000.c \ + clk_trimtaip.c \ + clk_rcc8000.c \ + clk_hopf6021.c \ + clk_computime.c \ clk_wharton.c \ clk_varitext.c \ - data_mbg.c \ + clk_sel240x.c \ + data_mbg.c \ info_trimble.c \ trim_info.c \ binio.c \ ieee754io.c \ mfp_mul.c \ - gpstolfp.c + gpstolfp.c \ + $(NULL) libparse_kernel_a_SOURCES = -libparse_kernel_a_LIBADD = kparse$U.o \ - kparse_conf$U.o \ - kclk_computime$U.o \ - kclk_dcf7000$U.o \ - kclk_hopf6021$U.o \ - kclk_meinberg$U.o \ - kclk_rawdcf$U.o \ - kclk_rcc8000$U.o \ - kclk_schmid$U.o \ - kclk_trimtaip$U.o \ - kclk_trimtsip$U.o \ - kclk_varitext$U.o \ - kclk_wharton$U.o \ - kbinio$U.o \ - kieee754io$U.o \ - kmfp_mul$U.o \ - kgpstolfp$U.o - -INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/kernel -ETAGS_ARGS = Makefile.am +libparse_kernel_a_LIBADD = \ + kparse.o \ + kparse_conf.o \ + kclk_computime.o \ + kclk_dcf7000.o \ + kclk_hopf6021.o \ + kclk_meinberg.o \ + kclk_rawdcf.o \ + kclk_rcc8000.o \ + kclk_schmid.o \ + kclk_trimtaip.o \ + kclk_trimtsip.o \ + kclk_varitext.o \ + kclk_wharton.o \ + kclk_sel240x.o \ + kbinio.o \ + kieee754io.o \ + kmfp_mul.o \ + kgpstolfp.o \ + $(NULL) + +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) -I$(top_srcdir)/kernel $(CPPFLAGS_NTP) EXTRA_DIST = parsesolaris.c parsestreams.c mkinfo_scmd.sed mkinfo_rcmd.sed info_trimble.c -all: all-am +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -303,7 +600,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign libparse/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign libparse/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -312,6 +608,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -324,14 +621,16 @@ $(am__aclocal_m4_deps): clean-noinstLIBRARIES: -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) -libparse.a: $(libparse_a_OBJECTS) $(libparse_a_DEPENDENCIES) - -rm -f libparse.a - $(libparse_a_AR) libparse.a $(libparse_a_OBJECTS) $(libparse_a_LIBADD) - $(RANLIB) libparse.a -libparse_kernel.a: $(libparse_kernel_a_OBJECTS) $(libparse_kernel_a_DEPENDENCIES) - -rm -f libparse_kernel.a - $(libparse_kernel_a_AR) libparse_kernel.a $(libparse_kernel_a_OBJECTS) $(libparse_kernel_a_LIBADD) - $(RANLIB) libparse_kernel.a + +libparse.a: $(libparse_a_OBJECTS) $(libparse_a_DEPENDENCIES) $(EXTRA_libparse_a_DEPENDENCIES) + $(AM_V_at)-rm -f libparse.a + $(AM_V_AR)$(libparse_a_AR) libparse.a $(libparse_a_OBJECTS) $(libparse_a_LIBADD) + $(AM_V_at)$(RANLIB) libparse.a + +libparse_kernel.a: $(libparse_kernel_a_OBJECTS) $(libparse_kernel_a_DEPENDENCIES) $(EXTRA_libparse_kernel_a_DEPENDENCIES) + $(AM_V_at)-rm -f libparse_kernel.a + $(AM_V_AR)$(libparse_kernel_a_AR) libparse_kernel.a $(libparse_kernel_a_OBJECTS) $(libparse_kernel_a_LIBADD) + $(AM_V_at)$(RANLIB) libparse_kernel.a clean-noinstPROGRAMS: @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \ @@ -341,125 +640,65 @@ clean-noinstPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -parsesolaris$(EXEEXT): $(parsesolaris_OBJECTS) $(parsesolaris_DEPENDENCIES) + +parsesolaris$(EXEEXT): $(parsesolaris_OBJECTS) $(parsesolaris_DEPENDENCIES) $(EXTRA_parsesolaris_DEPENDENCIES) @rm -f parsesolaris$(EXEEXT) - $(LINK) $(parsesolaris_OBJECTS) $(parsesolaris_LDADD) $(LIBS) -parsestreams$(EXEEXT): $(parsestreams_OBJECTS) $(parsestreams_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(parsesolaris_OBJECTS) $(parsesolaris_LDADD) $(LIBS) + +parsestreams$(EXEEXT): $(parsestreams_OBJECTS) $(parsestreams_DEPENDENCIES) $(EXTRA_parsestreams_DEPENDENCIES) @rm -f parsestreams$(EXEEXT) - $(LINK) $(parsestreams_OBJECTS) $(parsestreams_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(parsestreams_OBJECTS) $(parsestreams_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/binio$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_computime$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_dcf7000$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_hopf6021$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_meinberg$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rawdcf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rcc8000$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_schmid$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtaip$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtsip$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_varitext$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_wharton$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data_mbg$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpstolfp$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ieee754io$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/info_trimble$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfp_mul$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse_conf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsesolaris$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsestreams$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trim_info$U.Po@am__quote@ + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/binio.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_computime.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_dcf7000.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_hopf6021.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_meinberg.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rawdcf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_rcc8000.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_schmid.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_sel240x.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtaip.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_trimtsip.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_varitext.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/clk_wharton.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/data_mbg.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpstolfp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ieee754io.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/info_trimble.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mfp_mul.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse_conf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsesolaris.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsestreams.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trim_info.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -binio_.c: binio.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/binio.c; then echo $(srcdir)/binio.c; else echo binio.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_computime_.c: clk_computime.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_computime.c; then echo $(srcdir)/clk_computime.c; else echo clk_computime.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_dcf7000_.c: clk_dcf7000.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_dcf7000.c; then echo $(srcdir)/clk_dcf7000.c; else echo clk_dcf7000.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_hopf6021_.c: clk_hopf6021.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_hopf6021.c; then echo $(srcdir)/clk_hopf6021.c; else echo clk_hopf6021.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_meinberg_.c: clk_meinberg.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_meinberg.c; then echo $(srcdir)/clk_meinberg.c; else echo clk_meinberg.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_rawdcf_.c: clk_rawdcf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_rawdcf.c; then echo $(srcdir)/clk_rawdcf.c; else echo clk_rawdcf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_rcc8000_.c: clk_rcc8000.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_rcc8000.c; then echo $(srcdir)/clk_rcc8000.c; else echo clk_rcc8000.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_schmid_.c: clk_schmid.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_schmid.c; then echo $(srcdir)/clk_schmid.c; else echo clk_schmid.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_trimtaip_.c: clk_trimtaip.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_trimtaip.c; then echo $(srcdir)/clk_trimtaip.c; else echo clk_trimtaip.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_trimtsip_.c: clk_trimtsip.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_trimtsip.c; then echo $(srcdir)/clk_trimtsip.c; else echo clk_trimtsip.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_varitext_.c: clk_varitext.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_varitext.c; then echo $(srcdir)/clk_varitext.c; else echo clk_varitext.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -clk_wharton_.c: clk_wharton.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/clk_wharton.c; then echo $(srcdir)/clk_wharton.c; else echo clk_wharton.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -data_mbg_.c: data_mbg.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/data_mbg.c; then echo $(srcdir)/data_mbg.c; else echo data_mbg.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -gpstolfp_.c: gpstolfp.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/gpstolfp.c; then echo $(srcdir)/gpstolfp.c; else echo gpstolfp.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ieee754io_.c: ieee754io.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ieee754io.c; then echo $(srcdir)/ieee754io.c; else echo ieee754io.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -info_trimble_.c: info_trimble.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/info_trimble.c; then echo $(srcdir)/info_trimble.c; else echo info_trimble.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -mfp_mul_.c: mfp_mul.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/mfp_mul.c; then echo $(srcdir)/mfp_mul.c; else echo mfp_mul.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parse_.c: parse.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parse.c; then echo $(srcdir)/parse.c; else echo parse.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parse_conf_.c: parse_conf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parse_conf.c; then echo $(srcdir)/parse_conf.c; else echo parse_conf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parsesolaris_.c: parsesolaris.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parsesolaris.c; then echo $(srcdir)/parsesolaris.c; else echo parsesolaris.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -parsestreams_.c: parsestreams.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parsestreams.c; then echo $(srcdir)/parsestreams.c; else echo parsestreams.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -trim_info_.c: trim_info.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/trim_info.c; then echo $(srcdir)/trim_info.c; else echo trim_info.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -binio_.$(OBJEXT) binio_.lo clk_computime_.$(OBJEXT) clk_computime_.lo \ -clk_dcf7000_.$(OBJEXT) clk_dcf7000_.lo clk_hopf6021_.$(OBJEXT) \ -clk_hopf6021_.lo clk_meinberg_.$(OBJEXT) clk_meinberg_.lo \ -clk_rawdcf_.$(OBJEXT) clk_rawdcf_.lo clk_rcc8000_.$(OBJEXT) \ -clk_rcc8000_.lo clk_schmid_.$(OBJEXT) clk_schmid_.lo \ -clk_trimtaip_.$(OBJEXT) clk_trimtaip_.lo clk_trimtsip_.$(OBJEXT) \ -clk_trimtsip_.lo clk_varitext_.$(OBJEXT) clk_varitext_.lo \ -clk_wharton_.$(OBJEXT) clk_wharton_.lo data_mbg_.$(OBJEXT) \ -data_mbg_.lo gpstolfp_.$(OBJEXT) gpstolfp_.lo ieee754io_.$(OBJEXT) \ -ieee754io_.lo info_trimble_.$(OBJEXT) info_trimble_.lo \ -mfp_mul_.$(OBJEXT) mfp_mul_.lo parse_.$(OBJEXT) parse_.lo \ -parse_conf_.$(OBJEXT) parse_conf_.lo parsesolaris_.$(OBJEXT) \ -parsesolaris_.lo parsestreams_.$(OBJEXT) parsestreams_.lo \ -trim_info_.$(OBJEXT) trim_info_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo @@ -467,26 +706,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -498,15 +726,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -515,6 +739,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -550,10 +789,12 @@ distdir: $(DISTFILES) fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(LIBRARIES) $(PROGRAMS) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -563,10 +804,15 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: @@ -579,6 +825,7 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \ @@ -637,7 +884,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -650,136 +897,176 @@ ps-am: uninstall-am: -.MAKE: ../util/ansi2knr install-am install-strip - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-libtool clean-noinstLIBRARIES clean-noinstPROGRAMS ctags \ - distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ +.MAKE: all check install install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstLIBRARIES clean-noinstPROGRAMS \ + cscopelist-am ctags ctags-am distclean distclean-compile \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-kr mostlyclean-libtool pdf \ - pdf-am ps ps-am tags uninstall uninstall-am + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am +.PRECIOUS: Makefile -# -# create info_trimble.c -# -info_trimble.c: $(top_srcdir)/include/trimble.h mkinfo_rcmd.sed mkinfo_scmd.sed - @rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.c || rm -f info_trimble.c - sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.c || rm -f info_trimble.c -kieee754io.o: ieee754io.c +vphack: + test -e info_trimble.c || ln -s $(srcdir)/info_trimble.c . + +vphack_after: + test -L info_trimble.c || ( \ + mv info_trimble.c $(srcdir)/info_trimble.c && \ + ln -s $(srcdir)/info_trimble.c . \ + ) + +info_trimble.c: $(top_srcdir)/include/trimble.h $(srcdir)/Makefile.am $(srcdir)/mkinfo_scmd.sed $(srcdir)/mkinfo_rcmd.sed + sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.new + sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.new + mv -f info_trimble.new $@ + +#$(srcdir)/info_trimble.c: $(top_srcdir)/include/trimble.h $(srcdir)/Makefile.am $(srcdir)/mkinfo_scmd.sed $(srcdir)/mkinfo_rcmd.sed +# sed -n -f $(srcdir)/mkinfo_scmd.sed $(top_srcdir)/include/trimble.h > info_trimble.new +# sed -n -f $(srcdir)/mkinfo_rcmd.sed $(top_srcdir)/include/trimble.h >> info_trimble.new +# mv -f info_trimble.new $@ + +kieee754io.o: $(srcdir)/ieee754io.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/ieee754io.c -o $@ -kmfp_mul.o: mfp_mul.c +kmfp_mul.o: $(srcdir)/mfp_mul.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/mfp_mul.c -o $@ -kgpstolfp.o: gpstolfp.c +kgpstolfp.o: $(srcdir)/gpstolfp.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/gpstolfp.c -o $@ -kbinio.o: binio.c +kbinio.o: $(srcdir)/binio.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/binio.c -o $@ -kclk_computime.o: clk_computime.c +kclk_computime.o: $(srcdir)/clk_computime.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_computime.c -o $@ -kclk_computime_.o: clk_computime_.c - $(COMPILE) $(K_CFLAGS) -c clk_computime_.c -o $@ - -kclk_dcf7000.o: clk_dcf7000.c +kclk_dcf7000.o: $(srcdir)/clk_dcf7000.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_dcf7000.c -o $@ -kclk_dcf7000_.o: clk_dcf7000_.c - $(COMPILE) $(K_CFLAGS) -c clk_dcf7000_.c -o $@ - -kclk_hopf6021.o: clk_hopf6021.c +kclk_hopf6021.o: $(srcdir)/clk_hopf6021.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_hopf6021.c -o $@ -kclk_hopf6021_.o: clk_hopf6021_.c - $(COMPILE) $(K_CFLAGS) -c clk_hopf6021_.c -o $@ - -kclk_meinberg.o: clk_meinberg.c +kclk_meinberg.o: $(srcdir)/clk_meinberg.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_meinberg.c -o $@ -kclk_meinberg_.o: clk_meinberg_.c - $(COMPILE) $(K_CFLAGS) -c clk_meinberg_.c -o $@ - -kclk_rawdcf.o: clk_rawdcf.c +kclk_rawdcf.o: $(srcdir)/clk_rawdcf.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_rawdcf.c -o $@ -kclk_rawdcf_.o: clk_rawdcf_.c - $(COMPILE) $(K_CFLAGS) -c clk_rawdcf_.c -o $@ - -kclk_rcc8000.o: clk_rcc8000.c +kclk_rcc8000.o: $(srcdir)/clk_rcc8000.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_rcc8000.c -o $@ -kclk_rcc8000_.o: clk_rcc8000_.c - $(COMPILE) $(K_CFLAGS) -c clk_rcc8000_.c -o $@ - -kclk_schmid.o: clk_schmid.c +kclk_schmid.o: $(srcdir)/clk_schmid.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_schmid.c -o $@ -kclk_schmid_.o: clk_schmid_.c - $(COMPILE) $(K_CFLAGS) -c clk_schmid_.c -o $@ - -kclk_trimtaip.o: clk_trimtaip.c +kclk_trimtaip.o: $(srcdir)/clk_trimtaip.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_trimtaip.c -o $@ -kclk_trimtaip_.o: clk_trimtaip_.c - $(COMPILE) $(K_CFLAGS) -c clk_trimtaip_.c -o $@ - -kclk_trimtsip.o: clk_trimtsip.c +kclk_trimtsip.o: $(srcdir)/clk_trimtsip.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_trimtsip.c -o $@ -kclk_trimtsip_.o: clk_trimtsip_.c - $(COMPILE) $(K_CFLAGS) -c clk_trimtsip_.c -o $@ - -kclk_varitext.o: clk_varitext.c +kclk_varitext.o: $(srcdir)/clk_varitext.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_varitext.c -o $@ -kclk_varitext_.o: clk_varitext_.c - $(COMPILE) $(K_CFLAGS) -c clk_varitext_.c -o $@ - -kclk_wharton.o: clk_wharton.c +kclk_wharton.o: $(srcdir)/clk_wharton.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_wharton.c -o $@ -kclk_wharton_.o: clk_wharton_.c - $(COMPILE) $(K_CFLAGS) -c clk_wharton_.c -o $@ +kclk_sel240x.o: $(srcdir)/clk_sel240x.c + $(COMPILE) $(K_CFLAGS) -c $(srcdir)/clk_sel240x.c -o $@ -kparse.o: parse.c +kparse.o: $(srcdir)/parse.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/parse.c -o $@ -kparse_.o: parse_.c - $(COMPILE) $(K_CFLAGS) -c parse_.c -o $@ - -kparse_conf.o: parse_conf.c +kparse_conf.o: $(srcdir)/parse_conf.c $(COMPILE) $(K_CFLAGS) -c $(srcdir)/parse_conf.c -o $@ -kparse_conf_.o: parse_conf_.c - $(COMPILE) $(K_CFLAGS) -c parse_conf_.c -o $@ - parsestreams.loadable_module.o: $(parsestreams_OBJECTS) libparse_kernel.a ../libntp/libntp.a $(LD) -r -o $@ $(parsestreams_OBJECTS) libparse_kernel.a ../libntp/libntp.a parse: $(parsesolaris_OBJECTS) libparse_kernel.a ../libntp/libntp.a $(LD) -r -o $@ $(parsesolaris_OBJECTS) libparse_kernel.a ../libntp/libntp.a -../libntp/libntp.a: - cd ../libntp && $(MAKE) - parsesolaris.o: sys/systm.h sys/systm.h: - mkdir sys && \ + -mkdir sys sed -e '/ffs(.*)/d' < /usr/include/sys/systm.h > sys/systm.h +check-libparse: $(noinst_LIBRARIES) + @: do-nothing action to avoid default SCCS get + +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/contrib/ntp/libparse/binio.c b/contrib/ntp/libparse/binio.c index 2f8546b4a..24aa28687 100644 --- a/contrib/ntp/libparse/binio.c +++ b/contrib/ntp/libparse/binio.c @@ -33,6 +33,7 @@ * */ +#include #include "binio.h" long @@ -68,7 +69,7 @@ get_lsb_long( retval = *((*bufpp)++); retval |= *((*bufpp)++) << 8; retval |= *((*bufpp)++) << 16; - retval |= *((*bufpp)++) << 24; + retval |= (u_long)*((*bufpp)++) << 24; return retval; } @@ -115,7 +116,7 @@ get_msb_long( { long retval; - retval = *((*bufpp)++) << 24; + retval = (u_long)*((*bufpp)++) << 24; retval |= *((*bufpp)++) << 16; retval |= *((*bufpp)++) << 8; retval |= *((*bufpp)++); diff --git a/contrib/ntp/libparse/clk_computime.c b/contrib/ntp/libparse/clk_computime.c index d0db6a9f2..5026232ea 100644 --- a/contrib/ntp/libparse/clk_computime.c +++ b/contrib/ntp/libparse/clk_computime.c @@ -7,15 +7,15 @@ * /src/NTP/ntp4-dev/libparse/clk_computime.c,v 4.10 2005/04/16 17:32:10 kardel RELEASE_20050508_A * * clk_computime.c,v 4.10 2005/04/16 17:32:10 kardel RELEASE_20050508_A - * + * * Supports Diem's Computime Radio Clock - * + * * Used the Meinberg clock as a template for Diem's Computime Radio Clock * * adapted by Alois Camenzind - * + * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -54,27 +54,27 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* * The Computime receiver sends a datagram in the following format every minute - * - * Timestamp T:YY:MM:MD:WD:HH:MM:SSCRLF + * + * Timestamp T:YY:MM:MD:WD:HH:MM:SSCRLF * Pos 0123456789012345678901 2 3 * 0000000000111111111122 2 2 * Parse T: : : : : : : rn - * - * T Startcharacter "T" specifies start of the timestamp - * YY Year MM Month 1-12 - * MD Day of the month - * WD Day of week - * HH Hour - * MM Minute + * + * T Startcharacter "T" specifies start of the timestamp + * YY Year MM Month 1-12 + * MD Day of the month + * WD Day of week + * HH Hour + * MM Minute * SS Second - * CR Carriage return + * CR Carriage return * LF Linefeed - * + * */ static struct format computime_fmt = @@ -88,10 +88,10 @@ static struct format computime_fmt = 0 }; -static u_long cvt_computime P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_computime P((parse_t *, unsigned int, timestamp_t *)); +static parse_cvt_fnc_t cvt_computime; +static parse_inp_fnc_t inp_computime; -clockformat_t clock_computime = +clockformat_t clock_computime = { inp_computime, /* Computime input handling */ cvt_computime, /* Computime conversion */ @@ -99,15 +99,15 @@ clockformat_t clock_computime = (void *)&computime_fmt, /* conversion configuration */ "Diem's Computime Radio Clock", /* Computime Radio Clock */ 24, /* string buffer */ - 0 /* no private data (complete pakets) */ + 0 /* no private data (complete packets) */ }; /* - * cvt_computime - * + * parse_cvt_fnc_t cvt_computime + * * convert simple type format */ -static u_long +static u_long cvt_computime( unsigned char *buffer, int size, @@ -117,7 +117,7 @@ cvt_computime( ) { - if (!Strok(buffer, format->fixed_string)) { + if (!Strok(buffer, format->fixed_string)) { return CVT_NONE; } else { if (Stoi(&buffer[format->field_offsets[O_DAY].offset], &clock_time->day, @@ -131,7 +131,7 @@ cvt_computime( Stoi(&buffer[format->field_offsets[O_MIN].offset], &clock_time->minute, format->field_offsets[O_MIN].length) || Stoi(&buffer[format->field_offsets[O_SEC].offset], &clock_time->second, - format->field_offsets[O_SEC].length)) { + format->field_offsets[O_SEC].length)) { return CVT_FAIL | CVT_BADFMT; } else { @@ -144,31 +144,31 @@ cvt_computime( } /* - * inp_computime + * parse_inp_fnc_t inp_computime * - * grep data from input stream + * grab data from input stream */ static u_long inp_computime( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { unsigned int rtc; - + parseprintf(DD_PARSE, ("inp_computime(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - + switch (ch) { case 'T': parseprintf(DD_PARSE, ("inp_computime: START seen\n")); - + parseio->parse_index = 1; parseio->parse_data[0] = ch; parseio->parse_dtime.parse_stime = *tstamp; /* collect timestamp */ return PARSE_INP_SKIP; - + case '\n': parseprintf(DD_PARSE, ("inp_computime: END seen\n")); if ((rtc = parse_addchar(parseio, ch)) == PARSE_INP_SKIP) diff --git a/contrib/ntp/libparse/clk_dcf7000.c b/contrib/ntp/libparse/clk_dcf7000.c index e48173170..f1da9ef84 100644 --- a/contrib/ntp/libparse/clk_dcf7000.c +++ b/contrib/ntp/libparse/clk_dcf7000.c @@ -1,12 +1,12 @@ /* * /src/NTP/ntp4-dev/libparse/clk_dcf7000.c,v 4.10 2005/04/16 17:32:10 kardel RELEASE_20050508_A - * + * * clk_dcf7000.c,v 4.10 2005/04/16 17:32:10 kardel RELEASE_20050508_A * * ELV DCF7000 module * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -51,7 +51,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif static struct format dcf7000_fmt = @@ -63,9 +63,10 @@ static struct format dcf7000_fmt = }, (const unsigned char *)" - - - - - - - \r", 0 -}; -static u_long cvt_dcf7000 P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_dcf7000 P((parse_t *, unsigned int, timestamp_t *)); +}; + +static parse_cvt_fnc_t cvt_dcf7000; +static parse_inp_fnc_t inp_dcf7000; clockformat_t clock_dcf7000 = { @@ -75,11 +76,11 @@ clockformat_t clock_dcf7000 = (void *)&dcf7000_fmt, /* conversion configuration */ "ELV DCF7000", /* ELV clock */ 24, /* string buffer */ - 0 /* no private data (complete pakets) */ + 0 /* no private data (complete packets) */ }; /* - * cvt_dcf7000 + * parse_cvt_fnc_t cvt_dcf7000 * * convert dcf7000 type format */ @@ -117,7 +118,7 @@ cvt_dcf7000( { unsigned char *f = &buffer[format->field_offsets[O_FLAGS].offset]; long flags; - + clock_time->flags = 0; clock_time->usecond = 0; @@ -144,21 +145,21 @@ cvt_dcf7000( } /* - * inp_dcf700 + * parse_inp_fnc_t inp_dcf700 * - * grep data from input stream + * grab data from input stream */ static u_long inp_dcf7000( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { unsigned int rtc; - + parseprintf(DD_PARSE, ("inp_dcf7000(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - + switch (ch) { case '\r': diff --git a/contrib/ntp/libparse/clk_hopf6021.c b/contrib/ntp/libparse/clk_hopf6021.c index 426ea48b3..357ac2ec0 100644 --- a/contrib/ntp/libparse/clk_hopf6021.c +++ b/contrib/ntp/libparse/clk_hopf6021.c @@ -34,13 +34,13 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif -/* - * hopf Funkuhr 6021 +/* + * hopf Funkuhr 6021 * used with 9600,8N1, - * UTC ueber serielle Schnittstelle + * UTC ueber serielle Schnittstelle * Sekundenvorlauf ON * ETX zum Sekundenvorlauf ON * Datenstring 6021 @@ -71,7 +71,7 @@ extern void printf P((const char *, ...)); * x x 0 x - Wintertime * x x 1 x - Summertime * 0 0 x x - Time/Date invalid - * 0 1 x x - Internal clock used + * 0 1 x x - Internal clock used * 1 0 x x - Radio clock * 1 1 x x - Radio clock highprecision * @@ -90,10 +90,10 @@ extern void printf P((const char *, ...)); #define HOPF_DSTWARN 0x01 /* DST switch warning */ #define HOPF_DST 0x02 /* DST in effect */ -#define HOPF_MODE 0x0C /* operation mode mask */ +#define HOPF_MODE 0x0C /* operation mode mask */ #define HOPF_INVALID 0x00 /* no time code available */ #define HOPF_INTERNAL 0x04 /* internal clock */ -#define HOPF_RADIO 0x08 /* radio clock */ +#define HOPF_RADIO 0x08 /* radio clock */ #define HOPF_RADIOHP 0x0C /* high precision radio clock */ #define HOPF_UTC 0x08 /* time code in UTC */ @@ -102,13 +102,13 @@ extern void printf P((const char *, ...)); static struct format hopf6021_fmt = { { - { 9, 2 }, {11, 2}, { 13, 2}, /* Day, Month, Year */ - { 3, 2 }, { 5, 2}, { 7, 2}, /* Hour, Minute, Second */ + { 9, 2 }, {11, 2}, { 13, 2}, /* Day, Month, Year */ + { 3, 2 }, { 5, 2}, { 7, 2}, /* Hour, Minute, Second */ { 2, 1 }, { 1, 1}, { 0, 0}, /* Weekday, Flags, Zone */ /* ... */ }, (const unsigned char *)"\002 \n\r\003", - 0 + 0 }; #define OFFS(x) format->field_offsets[(x)].offset @@ -118,8 +118,8 @@ static struct format hopf6021_fmt = ('A' <= (x) && (x) <= 'F') ? (x) - 'A' + 10 : \ -1) -static unsigned long cvt_hopf6021 P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_hopf6021 P((parse_t *, unsigned int, timestamp_t *)); +static parse_cvt_fnc_t cvt_hopf6021; +static parse_inp_fnc_t inp_hopf6021; clockformat_t clock_hopf6021 = { @@ -132,7 +132,8 @@ clockformat_t clock_hopf6021 = 0 /* private data length, no private data */ }; -static unsigned long +/* parse_cvt_fnc_t cvt_hopf6021 */ +static u_long cvt_hopf6021( unsigned char *buffer, int size, @@ -162,8 +163,8 @@ cvt_hopf6021( clock_time->usecond = 0; clock_time->utcoffset = 0; - status = hexval(buffer[OFFS(O_FLAGS)]); - weekday= hexval(buffer[OFFS(O_WDAY)]); + status = (u_char) hexval(buffer[OFFS(O_FLAGS)]); + weekday= (u_char) hexval(buffer[OFFS(O_WDAY)]); if ((status == 0xFF) || (weekday == 0xFF)) { @@ -213,21 +214,21 @@ cvt_hopf6021( } /* - * inp_hopf6021 + * parse_inp_fnc_t inp_hopf6021 * - * grep data from input stream + * grab data from input stream */ static u_long inp_hopf6021( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { unsigned int rtc; - + parseprintf(DD_PARSE, ("inp_hopf6021(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - + switch (ch) { case ETX: diff --git a/contrib/ntp/libparse/clk_meinberg.c b/contrib/ntp/libparse/clk_meinberg.c index 90bb8865d..9d2b67638 100644 --- a/contrib/ntp/libparse/clk_meinberg.c +++ b/contrib/ntp/libparse/clk_meinberg.c @@ -1,12 +1,12 @@ /* * /src/NTP/REPOSITORY/ntp4-dev/libparse/clk_meinberg.c,v 4.12.2.1 2005/09/25 10:22:35 kardel RELEASE_20050925_A - * + * * clk_meinberg.c,v 4.12.2.1 2005/09/25 10:22:35 kardel RELEASE_20050925_A * * Meinberg clock support * - * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2015 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -65,7 +65,7 @@ /* * The Meinberg receiver every second sends a datagram of the following form * (Standard Format) - * + * * D:
      ..;T:;U:::; * pos: 0 00 00 0 00 0 11 111 1 111 12 2 22 2 22 2 2 2 3 3 3 * 1 23 45 6 78 9 01 234 5 678 90 1 23 4 56 7 8 9 0 1 2 @@ -105,12 +105,14 @@ * = '!' during the hour preceeding an daylight saving time * start/end change * = 'A' LEAP second announcement - * = 'R' alternate antenna + * = 'R' "call bit" used to signalize irregularities in the control facilities, + * usually ' ', until 2003 indicated transmission via alternate antenna * - * Meinberg GPS166 receiver + * Meinberg GPS receivers * - * You must get the Uni-Erlangen firmware for the GPS receiver support + * For very old devices you must get the Uni-Erlangen firmware for the GPS receiver support * to work to full satisfaction ! + * With newer GPS receiver types the Uni Erlangen string format can be configured at the device. * *
      ..; ; ::; <+/-><00:00>; ; * @@ -118,7 +120,7 @@ * 123456789012345678901234567890123456789012345678901234567890123456 * \x0209.07.93; 5; 08:48:26; +00:00; #*S!A L; 49.5736N 11.0280E 373m\x03 * - * + * * = '\002' ASCII start of text * = '\003' ASCII end of text *
      ,, = day, month, year(2 digits!!) @@ -131,8 +133,10 @@ * = '!' during the hour preceeding an daylight saving time * start/end change * = 'A' LEAP second announcement - * = 'R' alternate antenna (reminiscent of PZF535) usually ' ' - * = 'L' on 23:59:60 + * = 'R' "call bit" used to signalize irregularities in the control facilities, + * usually ' ', until 2003 indicated transmission via alternate antenna + * (reminiscent of PZF receivers) + * = 'L' on 23:59:60 * * Binary messages have a lead in for a fixed header of SOH */ @@ -150,19 +154,20 @@ /* Ret val: the checksum */ /*+-------------------------------------------------------------*/ -unsigned long +CSUM mbg_csum( unsigned char *p, unsigned int n ) { - unsigned long sum = 0; - short i; - + unsigned int sum = 0; + unsigned int i; + for ( i = 0; i < n; i++ ) sum += *p++; - - return( sum ); + + return (CSUM) sum; + } /* csum */ void @@ -171,10 +176,10 @@ get_mbg_header( GPS_MSG_HDR *headerp ) { - headerp->gps_cmd = get_lsb_short(bufpp); - headerp->gps_len = get_lsb_short(bufpp); - headerp->gps_data_csum = get_lsb_short(bufpp); - headerp->gps_hdr_csum = get_lsb_short(bufpp); + headerp->cmd = (GPS_CMD) get_lsb_short(bufpp); + headerp->len = get_lsb_uint16(bufpp); + headerp->data_csum = (CSUM) get_lsb_short(bufpp); + headerp->hdr_csum = (CSUM) get_lsb_short(bufpp); } static struct format meinberg_fmt[] = @@ -209,10 +214,10 @@ static struct format meinberg_fmt[] = } }; -static u_long cvt_meinberg P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long cvt_mgps P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long mbg_input P((parse_t *, unsigned int, timestamp_t *)); -static u_long gps_input P((parse_t *, unsigned int, timestamp_t *)); +static parse_cvt_fnc_t cvt_meinberg; +static parse_cvt_fnc_t cvt_mgps; +static parse_inp_fnc_t mbg_input; +static parse_inp_fnc_t gps_input; struct msg_buf { @@ -224,7 +229,7 @@ struct msg_buf #define MBG_HEADER 1 /* receiving header */ #define MBG_DATA 2 /* receiving data */ #define MBG_STRING 3 /* receiving standard data message */ - + clockformat_t clock_meinberg[] = { { @@ -234,7 +239,7 @@ clockformat_t clock_meinberg[] = 0, /* conversion configuration */ "Meinberg Standard", /* Meinberg simple format - beware */ 32, /* string buffer */ - 0 /* no private data (complete pakets) */ + 0 /* no private data (complete packets) */ }, { mbg_input, /* normal input handling */ @@ -243,21 +248,21 @@ clockformat_t clock_meinberg[] = 0, /* conversion configuration */ "Meinberg Extended", /* Meinberg enhanced format */ 32, /* string buffer */ - 0 /* no private data (complete pakets) */ + 0 /* no private data (complete packets) */ }, { gps_input, /* no input handling */ - cvt_mgps, /* Meinberg GPS166 conversion */ + cvt_mgps, /* Meinberg GPS receiver conversion */ pps_one, /* easy PPS monitoring */ (void *)&meinberg_fmt[2], /* conversion configuration */ - "Meinberg GPS Extended", /* Meinberg FAU GPS format */ + "Meinberg GPS Extended", /* Meinberg FAU GPS format */ 512, /* string buffer */ - sizeof(struct msg_buf) /* no private data (complete pakets) */ + sizeof(struct msg_buf) /* no private data (complete packets) */ } }; /* - * cvt_meinberg + * parse_cvt_fnc_t cvt_meinberg * * convert simple type format */ @@ -271,7 +276,7 @@ cvt_meinberg( ) { struct format *format; - + /* * select automagically correct data format */ @@ -312,7 +317,7 @@ cvt_meinberg( else { unsigned char *f = &buffer[format->field_offsets[O_FLAGS].offset]; - + clock_time->usecond = 0; clock_time->flags = PARSEB_S_LEAP; @@ -348,7 +353,7 @@ cvt_meinberg( case ' ': clock_time->utcoffset = -1*60*60; /* MET */ break; - + case 'S': clock_time->utcoffset = -2*60*60; /* MED */ break; @@ -360,27 +365,27 @@ cvt_meinberg( clock_time->utcoffset = 0; /* UTC */ clock_time->flags |= PARSEB_UTC; break; - + default: return CVT_FAIL|CVT_BADFMT; } } - + /* * gather status flags */ if (buffer[format->field_offsets[O_ZONE].offset] == 'S') clock_time->flags |= PARSEB_DST; - + if (f[0] == '#') clock_time->flags |= PARSEB_POWERUP; - + if (f[1] == '*') clock_time->flags |= PARSEB_NOSYNC; - + if (f[3] == '!') clock_time->flags |= PARSEB_ANNOUNCE; - + /* * oncoming leap second * 'a' code not confirmed - earth is not @@ -388,27 +393,27 @@ cvt_meinberg( */ if (f[3] == 'A') clock_time->flags |= PARSEB_LEAPADD; - + if (f[3] == 'a') clock_time->flags |= PARSEB_LEAPDEL; - - + + if (format->flags & MBG_EXTENDED) { - clock_time->flags |= PARSEB_S_ANTENNA; - + clock_time->flags |= PARSEB_S_CALLBIT; + /* * DCF77 does not encode the direction - * so we take the current default - * earth slowing down */ clock_time->flags &= ~PARSEB_LEAPDEL; - + if (f[4] == 'A') clock_time->flags |= PARSEB_LEAPADD; - + if (f[5] == 'R') - clock_time->flags |= PARSEB_ALTERNATE; + clock_time->flags |= PARSEB_CALLBIT; } return CVT_OK; } @@ -416,31 +421,31 @@ cvt_meinberg( /* - * mbg_input + * parse_inp_fnc_t mbg_input * - * grep data from input stream + * grab data from input stream */ static u_long mbg_input( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { unsigned int rtc; - + parseprintf(DD_PARSE, ("mbg_input(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - + switch (ch) { case STX: parseprintf(DD_PARSE, ("mbg_input: STX seen\n")); - + parseio->parse_index = 1; parseio->parse_data[0] = ch; parseio->parse_dtime.parse_stime = *tstamp; /* collect timestamp */ return PARSE_INP_SKIP; - + case ETX: parseprintf(DD_PARSE, ("mbg_input: ETX seen\n")); if ((rtc = parse_addchar(parseio, ch)) == PARSE_INP_SKIP) @@ -455,7 +460,7 @@ mbg_input( /* - * cvt_mgps + * parse_cvt_fnc_t cvt_mgps * * convert Meinberg GPS format */ @@ -493,9 +498,9 @@ cvt_mgps( { long h; unsigned char *f = &buffer[format->field_offsets[O_FLAGS].offset]; - + clock_time->flags = PARSEB_S_LEAP|PARSEB_S_POSITION; - + clock_time->usecond = 0; /* @@ -522,22 +527,22 @@ cvt_mgps( clock_time->utcoffset = -clock_time->utcoffset; } } - + /* * gather status flags */ if (buffer[format->field_offsets[O_ZONE].offset] == 'S') clock_time->flags |= PARSEB_DST; - + if (clock_time->utcoffset == 0) clock_time->flags |= PARSEB_UTC; - + /* * no sv's seen - no time & position */ if (f[0] == '#') clock_time->flags |= PARSEB_POWERUP; - + /* * at least one sv seen - time (for last position) */ @@ -546,13 +551,13 @@ cvt_mgps( else if (!(clock_time->flags & PARSEB_POWERUP)) clock_time->flags |= PARSEB_POSITION; - + /* * oncoming zone switch */ if (f[3] == '!') clock_time->flags |= PARSEB_ANNOUNCE; - + /* * oncoming leap second * 'a' code not confirmed - earth is not @@ -560,14 +565,14 @@ cvt_mgps( */ if (f[4] == 'A') clock_time->flags |= PARSEB_LEAPADD; - + if (f[4] == 'a') clock_time->flags |= PARSEB_LEAPDEL; /* * f[5] == ' ' */ - + /* * this is the leap second */ @@ -580,35 +585,35 @@ cvt_mgps( } /* - * gps_input + * parse_inp_fnc_t gps_input * * grep binary data from input stream */ static u_long gps_input( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { CSUM calc_csum; /* used to compare the incoming csums */ GPS_MSG_HDR header; struct msg_buf *msg_buf; - + msg_buf = (struct msg_buf *)parseio->parse_pdata; parseprintf(DD_PARSE, ("gps_input(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); if (!msg_buf) return PARSE_INP_SKIP; - + if ( msg_buf->phase == MBG_NONE ) { /* not receiving yet */ switch (ch) { case SOH: parseprintf(DD_PARSE, ("gps_input: SOH seen\n")); - + msg_buf->len = sizeof( header ); /* prepare to receive msg header */ msg_buf->phase = MBG_HEADER; /* receiving header */ break; @@ -621,7 +626,7 @@ gps_input( parseio->parse_index = 1; parseio->parse_data[0] = ch; break; - + default: return PARSE_INP_SKIP; /* keep searching */ } @@ -638,7 +643,7 @@ gps_input( if ((msg_buf->phase == MBG_STRING) && (parseio->parse_index < parseio->parse_dsize)) parseio->parse_data[parseio->parse_index++] = ch; - + parseio->parse_dtime.parse_msg[parseio->parse_dtime.parse_msglen++] = ch; if (parseio->parse_dtime.parse_msglen > sizeof(parseio->parse_dtime.parse_msg)) @@ -649,7 +654,7 @@ gps_input( parseio->parse_ldsize = parseio->parse_index; return PARSE_INP_DATA; } - + switch (msg_buf->phase) { case MBG_HEADER: @@ -685,41 +690,41 @@ gps_input( if ( msg_buf->phase == MBG_HEADER ) { /* header complete now */ unsigned char *datap = parseio->parse_dtime.parse_msg + 1; - + get_mbg_header(&datap, &header); - + parseprintf(DD_PARSE, ("gps_input: header: cmd 0x%x, len %d, dcsum 0x%x, hcsum 0x%x\n", - (int)header.gps_cmd, (int)header.gps_len, (int)header.gps_data_csum, - (int)header.gps_hdr_csum)); - + (int)header.cmd, (int)header.len, (int)header.data_csum, + (int)header.hdr_csum)); + calc_csum = mbg_csum( (unsigned char *) parseio->parse_dtime.parse_msg + 1, (unsigned short)6 ); - if ( calc_csum != header.gps_hdr_csum ) + if ( calc_csum != header.hdr_csum ) { parseprintf(DD_PARSE, ("gps_input: header checksum mismatch expected 0x%x, got 0x%x\n", (int)calc_csum, (int)mbg_csum( (unsigned char *) parseio->parse_dtime.parse_msg, (unsigned short)6 ))); - + msg_buf->phase = MBG_NONE; /* back to hunting mode */ return PARSE_INP_DATA; /* invalid header checksum received - pass up for detection */ } - if ((header.gps_len == 0) || /* no data to wait for */ - (header.gps_len >= (sizeof (parseio->parse_dtime.parse_msg) - sizeof(header) - 1))) /* blows anything we have space for */ + if ((header.len == 0) || /* no data to wait for */ + (header.len >= (sizeof (parseio->parse_dtime.parse_msg) - sizeof(header) - 1))) /* blows anything we have space for */ { msg_buf->phase = MBG_NONE; /* back to hunting mode */ - return (header.gps_len == 0) ? PARSE_INP_DATA : PARSE_INP_SKIP; /* message complete/throwaway */ + return (header.len == 0) ? PARSE_INP_DATA : PARSE_INP_SKIP; /* message complete/throwaway */ } - - parseprintf(DD_PARSE, ("gps_input: expecting %d bytes of data message\n", (int)header.gps_len)); - - msg_buf->len = header.gps_len;/* save number of bytes to wait for */ + + parseprintf(DD_PARSE, ("gps_input: expecting %d bytes of data message\n", (int)header.len)); + + msg_buf->len = header.len;/* save number of bytes to wait for */ msg_buf->phase = MBG_DATA; /* flag header already complete */ return PARSE_INP_SKIP; } parseprintf(DD_PARSE, ("gps_input: message data complete\n")); - + /* Header and data have been received. The header checksum has been */ /* checked */ diff --git a/contrib/ntp/libparse/clk_rawdcf.c b/contrib/ntp/libparse/clk_rawdcf.c index 3ef36c43e..ca4326336 100644 --- a/contrib/ntp/libparse/clk_rawdcf.c +++ b/contrib/ntp/libparse/clk_rawdcf.c @@ -1,12 +1,12 @@ /* * /src/NTP/REPOSITORY/ntp4-dev/libparse/clk_rawdcf.c,v 4.18 2006/06/22 18:40:01 kardel RELEASE_20060622_A - * + * * clk_rawdcf.c,v 4.18 2006/06/22 18:40:01 kardel RELEASE_20060622_A * * Raw DCF77 pulse clock support * - * Copyright (c) 1995-2006 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2015 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -41,6 +41,7 @@ #if defined(REFCLOCK) && defined(CLOCK_PARSE) && defined(CLOCK_RAWDCF) #include "ntp_fp.h" +#include "timevalops.h" #include "ntp_unixtime.h" #include "ntp_calendar.h" @@ -75,7 +76,8 @@ * Second Contents * 0 - 10 AM: free, FM: 0 * 11 - 14 free - * 15 R - alternate antenna + * 15 R - "call bit" used to signalize irregularities in the control facilities + * (until 2003 indicated transmission via alternate antenna) * 16 A1 - expect zone change (1 hour before) * 17 - 18 Z1,Z2 - time zone * 0 0 illegal @@ -101,12 +103,14 @@ * 59 - usually missing (minute indication), except for leap insertion */ -static u_long pps_rawdcf P((parse_t *, int, timestamp_t *)); -static u_long cvt_rawdcf P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long inp_rawdcf P((parse_t *, unsigned int, timestamp_t *)); +static parse_pps_fnc_t pps_rawdcf; +static parse_cvt_fnc_t cvt_rawdcf; +static parse_inp_fnc_t inp_rawdcf; typedef struct last_tcode { - time_t tcode; /* last converted time code */ + time_t tcode; /* last converted time code */ + timestamp_t tminute; /* sample time for minute start */ + timestamp_t timeout; /* last timeout timestamp */ } last_tcode_t; #define BUFFER_MAX 61 @@ -125,15 +129,15 @@ clockformat_t clock_rawdcf = static struct dcfparam { - unsigned char *onebits; - unsigned char *zerobits; -} dcfparameter = + const unsigned char *onebits; + const unsigned char *zerobits; +} dcfparameter = { - (unsigned char *)"###############RADMLS1248124P124812P1248121241248112481248P??", /* 'ONE' representation */ - (unsigned char *)"--------------------s-------p------p----------------------p__" /* 'ZERO' representation */ + (const unsigned char *)"###############RADMLS1248124P124812P1248121241248112481248P??", /* 'ONE' representation */ + (const unsigned char *)"--------------------s-------p------p----------------------p__" /* 'ZERO' representation */ }; -static struct rawdcfcode +static struct rawdcfcode { char offset; /* start bit */ } rawdcfcode[] = @@ -182,14 +186,14 @@ static u_long ext_bf( unsigned char *buf, int idx, - unsigned char *zero + const unsigned char *zero ) { u_long sum = 0; int i, first; first = rawdcfcode[idx].offset; - + for (i = rawdcfcode[idx+1].offset - 1; i >= first; i--) { sum <<= 1; @@ -202,7 +206,7 @@ static unsigned pcheck( unsigned char *buf, int idx, - unsigned char *zero + const unsigned char *zero ) { int i,last; @@ -225,20 +229,20 @@ convert_rawdcf( ) { unsigned char *s = buffer; - unsigned char *b = dcfprm->onebits; - unsigned char *c = dcfprm->zerobits; + const unsigned char *b = dcfprm->onebits; + const unsigned char *c = dcfprm->zerobits; int i; - parseprintf(DD_RAWDCF,("parse: convert_rawdcf: \"%s\"\n", buffer)); + parseprintf(DD_RAWDCF,("parse: convert_rawdcf: \"%.*s\"\n", size, buffer)); if (size < 57) { #ifndef PARSEKERNEL - msyslog(LOG_ERR, "parse: convert_rawdcf: INCOMPLETE DATA - time code only has %d bits\n", size); + msyslog(LOG_ERR, "parse: convert_rawdcf: INCOMPLETE DATA - time code only has %d bits", size); #endif - return CVT_NONE; + return CVT_FAIL|CVT_BADFMT; } - + for (i = 0; i < size; i++) { if ((*s != *b) && (*s != *c)) @@ -249,7 +253,7 @@ convert_rawdcf( #ifndef PARSEKERNEL msyslog(LOG_ERR, "parse: convert_rawdcf: BAD DATA - no conversion"); #endif - return CVT_NONE; + return CVT_FAIL|CVT_BADFMT; } if (*b) b++; if (*c) c++; @@ -269,7 +273,7 @@ convert_rawdcf( */ parseprintf(DD_RAWDCF,("parse: convert_rawdcf: parity check passed\n")); - clock_time->flags = PARSEB_S_ANTENNA|PARSEB_S_LEAP; + clock_time->flags = PARSEB_S_CALLBIT|PARSEB_S_LEAP; clock_time->utctime= 0; clock_time->usecond= 0; clock_time->second = 0; @@ -307,9 +311,9 @@ convert_rawdcf( clock_time->flags |= PARSEB_LEAPADD; /* default: DCF77 data format deficiency */ if (ext_bf(buffer, DCF_R, dcfprm->zerobits)) - clock_time->flags |= PARSEB_ALTERNATE; + clock_time->flags |= PARSEB_CALLBIT; - parseprintf(DD_RAWDCF,("parse: convert_rawdcf: TIME CODE OK: %d:%d, %d.%d.%d, flags 0x%lx\n", + parseprintf(DD_RAWDCF,("parse: convert_rawdcf: TIME CODE OK: %02d:%02d, %02d.%02d.%02d, flags 0x%lx\n", (int)clock_time->hour, (int)clock_time->minute, (int)clock_time->day, (int)clock_time->month,(int) clock_time->year, (u_long)clock_time->flags)); return CVT_OK; @@ -320,13 +324,14 @@ convert_rawdcf( * bad format - not for us */ #ifndef PARSEKERNEL - msyslog(LOG_ERR, "parse: convert_rawdcf: parity check FAILED for \"%s\"\n", buffer); + msyslog(LOG_ERR, "parse: convert_rawdcf: start bit / parity check FAILED for \"%.*s\"", size, buffer); #endif return CVT_FAIL|CVT_BADFMT; } } /* + * parse_cvt_fnc_t cvt_rawdcf * raw dcf input routine - needs to fix up 50 baud * characters for 1/0 decision */ @@ -342,8 +347,8 @@ cvt_rawdcf( last_tcode_t *t = (last_tcode_t *)local; unsigned char *s = (unsigned char *)buffer; unsigned char *e = s + size; - unsigned char *b = dcfparameter.onebits; - unsigned char *c = dcfparameter.zerobits; + const unsigned char *b = dcfparameter.onebits; + const unsigned char *c = dcfparameter.zerobits; u_long rtc = CVT_NONE; unsigned int i, lowmax, highmax, cutoff, span; #define BITS 9 @@ -379,7 +384,7 @@ cvt_rawdcf( ch >>= 1; } - *s = i; + *s = (unsigned char) i; histbuf[i]++; cutoff += i; lowmax++; @@ -482,6 +487,8 @@ cvt_rawdcf( if (*c) c++; } + *s = '\0'; + if (rtc == CVT_NONE) { rtc = convert_rawdcf(buffer, size, &dcfparameter, clock_time); @@ -492,24 +499,26 @@ cvt_rawdcf( newtime = parse_to_unixtime(clock_time, &rtc); if ((rtc == CVT_OK) && t) { - if ((newtime - t->tcode) == 60) /* guard against multi bit errors */ + if ((newtime - t->tcode) <= 600) /* require a successful telegram within last 10 minutes */ { + parseprintf(DD_RAWDCF,("parse: cvt_rawdcf: recent timestamp check OK\n")); clock_time->utctime = newtime; } else { - rtc = CVT_FAIL|CVT_BADTIME; + parseprintf(DD_RAWDCF,("parse: cvt_rawdcf: recent timestamp check FAIL - ignore timestamp\n")); + rtc = CVT_SKIP; } t->tcode = newtime; } } } - + return rtc; } /* - * pps_rawdcf + * parse_pps_fnc_t pps_rawdcf * * currently a very stupid version - should be extended to decode * also ones and zeros (which is easy) @@ -531,13 +540,63 @@ pps_rawdcf( return CVT_NONE; } +static long +calc_usecdiff( + timestamp_t *ref, + timestamp_t *base, + long offset + ) +{ + struct timeval delta; + long delta_usec = 0; + +#ifdef PARSEKERNEL + delta.tv_sec = ref->tv.tv_sec - offset - base->tv.tv_sec; + delta.tv_usec = ref->tv.tv_usec - base->tv.tv_usec; + if (delta.tv_usec < 0) + { + delta.tv_sec -= 1; + delta.tv_usec += 1000000; + } +#else + l_fp delt; + + delt = ref->fp; + delt.l_i -= offset; + L_SUB(&delt, &base->fp); + TSTOTV(&delt, &delta); +#endif + + delta_usec = 1000000 * (int32_t)delta.tv_sec + delta.tv_usec; + return delta_usec; +} + static u_long snt_rawdcf( parse_t *parseio, timestamp_t *ptime ) { - if ((parseio->parse_dtime.parse_status & CVT_MASK) == CVT_OK) + /* + * only synthesize if all of following conditions are met: + * - CVT_OK parse_status (we have a time stamp base) + * - ABS(ptime - tminute - (parse_index - 1) sec) < 500ms (spaced by 1 sec +- 500ms) + * - minute marker is available (confirms minute raster as base) + */ + last_tcode_t *t = (last_tcode_t *)parseio->parse_pdata; + long delta_usec = -1; + + if (t != NULL && t->tminute.tv.tv_sec != 0) { + delta_usec = calc_usecdiff(ptime, &t->tminute, parseio->parse_index - 1); + if (delta_usec < 0) + delta_usec = -delta_usec; + } + + parseprintf(DD_RAWDCF,("parse: snt_rawdcf: synth for offset %d seconds - absolute usec error %ld\n", + parseio->parse_index - 1, delta_usec)); + + if (((parseio->parse_dtime.parse_status & CVT_MASK) == CVT_OK) && + (delta_usec < 500000 && delta_usec >= 0)) /* only if minute marker is available */ { parseio->parse_dtime.parse_stime = *ptime; @@ -546,44 +605,77 @@ snt_rawdcf( #else parseio->parse_dtime.parse_time.fp.l_ui++; #endif - + parseprintf(DD_RAWDCF,("parse: snt_rawdcf: time stamp synthesized offset %d seconds\n", parseio->parse_index - 1)); - + return updatetimeinfo(parseio, parseio->parse_lstate); } return CVT_NONE; } /* - * inp_rawdcf + * parse_inp_fnc_t inp_rawdcf * * grab DCF77 data from input stream */ static u_long inp_rawdcf( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { static struct timeval timeout = { 1, 500000 }; /* 1.5 secongs denote second #60 */ - + parseprintf(DD_PARSE, ("inp_rawdcf(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - + parseio->parse_dtime.parse_stime = *tstamp; /* collect timestamp */ if (parse_timedout(parseio, tstamp, &timeout)) { - parseprintf(DD_PARSE, ("inp_rawdcf: time out seen\n")); - + last_tcode_t *t = (last_tcode_t *)parseio->parse_pdata; + long delta_usec; + + parseprintf(DD_RAWDCF, ("inp_rawdcf: time out seen\n")); + /* finish collection */ (void) parse_end(parseio); + + if (t != NULL) + { + /* remember minute start sample time if timeouts occur in minute raster */ + if (t->timeout.tv.tv_sec != 0) + { + delta_usec = calc_usecdiff(tstamp, &t->timeout, 60); + if (delta_usec < 0) + delta_usec = -delta_usec; + } + else + { + delta_usec = -1; + } + + if (delta_usec < 500000 && delta_usec >= 0) + { + parseprintf(DD_RAWDCF, ("inp_rawdcf: timeout time difference %ld usec - minute marker set\n", delta_usec)); + /* collect minute markers only if spaced by 60 seconds */ + t->tminute = *tstamp; + } + else + { + parseprintf(DD_RAWDCF, ("inp_rawdcf: timeout time difference %ld usec - minute marker cleared\n", delta_usec)); + memset((char *)&t->tminute, 0, sizeof(t->tminute)); + } + t->timeout = *tstamp; + } (void) parse_addchar(parseio, ch); + + /* pass up to higher layers */ return PARSE_INP_TIME; } else { unsigned int rtc; - + rtc = parse_addchar(parseio, ch); if (rtc == PARSE_INP_SKIP) { diff --git a/contrib/ntp/libparse/clk_rcc8000.c b/contrib/ntp/libparse/clk_rcc8000.c index 9ce270d43..a690e588b 100644 --- a/contrib/ntp/libparse/clk_rcc8000.c +++ b/contrib/ntp/libparse/clk_rcc8000.c @@ -1,6 +1,6 @@ /* * /src/NTP/ntp4-dev/libparse/clk_rcc8000.c,v 4.9 2004/11/14 15:29:41 kardel RELEASE_20050508_A - * + * * clk_rcc8000.c,v 4.9 2004/11/14 15:29:41 kardel RELEASE_20050508_A * * Radiocode Clocks Ltd RCC 8000 Intelligent Off-Air Master Clock support @@ -30,7 +30,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* Type II Serial Output format @@ -49,16 +49,16 @@ extern void printf P((const char *, ...)); #define O_USEC O_WDAY static struct format rcc8000_fmt = -{ { { 13, 2 }, {16, 2}, { 19, 2}, /* Day, Month, Year */ - { 0, 2 }, { 3, 2}, { 6, 2}, /* Hour, Minute, Second */ +{ { { 13, 2 }, {16, 2}, { 19, 2}, /* Day, Month, Year */ + { 0, 2 }, { 3, 2}, { 6, 2}, /* Hour, Minute, Second */ { 9, 3 }, {28, 1}, { 0, 0}, /* uSec, Status (Valid,Reject,BST,Leapyear) */ }, - (const unsigned char *)" : : . / / \r\n", + (const unsigned char *)" : : . / / \r\n", /*"15:50:36.534 30/09/94 273 5 A\x0d\x0a" */ - 0 + 0 }; -static unsigned long cvt_rcc8000 P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_rcc8000 P((parse_t *, unsigned int, timestamp_t *)); +static parse_cvt_fnc_t cvt_rcc8000; +static parse_inp_fnc_t inp_rcc8000; clockformat_t clock_rcc8000 = { @@ -71,7 +71,8 @@ clockformat_t clock_rcc8000 = 0 /* no private data */ }; -static unsigned long +/* parse_cvt_fnc_t cvt_rcc8000 */ +static u_long cvt_rcc8000( unsigned char *buffer, int size, @@ -121,27 +122,27 @@ cvt_rcc8000( clock_time->flags |= PARSEB_POWERUP; clock_time->flags |= PARSEB_UTC; /* British special - guess why 8-) */ - + /* other flags not used */ } return CVT_OK; } /* - * inp_rcc8000 + * parse_inp_fnc_t inp_rcc8000 * - * grep data from input stream + * grab data from input stream */ static u_long inp_rcc8000( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { unsigned int rtc; - + parseprintf(DD_PARSE, ("inp_rcc8000(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - + switch (ch) { case '\n': @@ -150,7 +151,7 @@ inp_rcc8000( return parse_end(parseio); else return rtc; - + default: if (parseio->parse_index == 0) /* take sample at start of message */ diff --git a/contrib/ntp/libparse/clk_schmid.c b/contrib/ntp/libparse/clk_schmid.c index 4f4820147..c4f02b07a 100644 --- a/contrib/ntp/libparse/clk_schmid.c +++ b/contrib/ntp/libparse/clk_schmid.c @@ -1,13 +1,13 @@ /* * /src/NTP/ntp4-dev/libparse/clk_schmid.c,v 4.9 2005/04/16 17:32:10 kardel RELEASE_20050508_A - * + * * clk_schmid.c,v 4.9 2005/04/16 17:32:10 kardel RELEASE_20050508_A * * Schmid clock support * based on information and testing from Adam W. Feigin et. al (Swisstime iis.ethz.ch) * - * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2015 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -52,7 +52,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* @@ -61,7 +61,7 @@ extern void printf P((const char *, ...)); * The command to Schmid's DCF77 clock is a single byte; each bit * allows the user to select some part of the time string, as follows (the * output for the lsb is sent first). - * + * * Bit 0: time in MEZ, 4 bytes *binary, not BCD*; hh.mm.ss.tenths * Bit 1: date 3 bytes *binary, not BCD: dd.mm.yy * Bit 2: week day, 1 byte (unused here) @@ -82,15 +82,15 @@ extern void printf P((const char *, ...)); #define WS_TIME 0x01 #define WS_SIGNAL 0x02 -#define WS_ALTERNATE 0x01 +#define WS_CALLBIT 0x01 /* "call bit" used to signalize irregularities in the control facilities */ #define WS_ANNOUNCE 0x02 #define WS_TZ 0x0c #define WS_MET 0x08 #define WS_MEST 0x04 #define WS_LEAP 0x10 -static u_long cvt_schmid P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_schmid P((parse_t *, unsigned int, timestamp_t *)); +static parse_cvt_fnc_t cvt_schmid; +static parse_inp_fnc_t inp_schmid; clockformat_t clock_schmid = { @@ -103,7 +103,7 @@ clockformat_t clock_schmid = 0, /* no private data (complete messages) */ }; - +/* parse_cvt_fnc_t */ static u_long cvt_schmid( unsigned char *buffer, @@ -155,7 +155,7 @@ cvt_schmid( default: return CVT_FAIL|CVT_BADFMT; } - + if (!(buffer[7] & WS_TIME)) { clock_time->flags |= PARSEB_POWERUP; @@ -168,9 +168,9 @@ cvt_schmid( if (buffer[7] & WS_SIGNAL) { - if (buffer[8] & WS_ALTERNATE) + if (buffer[8] & WS_CALLBIT) { - clock_time->flags |= PARSEB_ALTERNATE; + clock_time->flags |= PARSEB_CALLBIT; } if (buffer[8] & WS_ANNOUNCE) @@ -184,33 +184,33 @@ cvt_schmid( } } - clock_time->flags |= PARSEB_S_LEAP|PARSEB_S_ANTENNA; - + clock_time->flags |= PARSEB_S_LEAP|PARSEB_S_CALLBIT; + return CVT_OK; } } } /* - * inp_schmid + * parse_inp_fnc_t inp_schmid * - * grep data from input stream + * grab data from input stream */ static u_long inp_schmid( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { unsigned int rtc; - + parseprintf(DD_PARSE, ("inp_schmid(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - - switch (ch) + + switch ((uint8_t)ch) { case 0xFD: /* */ - parseprintf(DD_PARSE, ("mbg_input: ETX seen\n")); + parseprintf(DD_PARSE, ("inp_schmid: 0xFD seen\n")); if ((rtc = parse_addchar(parseio, ch)) == PARSE_INP_SKIP) return parse_end(parseio); else diff --git a/contrib/ntp/libparse/clk_sel240x.c b/contrib/ntp/libparse/clk_sel240x.c new file mode 100644 index 000000000..b1390b4ce --- /dev/null +++ b/contrib/ntp/libparse/clk_sel240x.c @@ -0,0 +1,172 @@ +////////////////////////////////////////////////////////////////////////////// +// Copyright (c) 2009,2012 - +// Schweitzer Engineering Laboratories, Inc. +////////////////////////////////////////////////////////////////////////////// + +// Need to have _XOPEN_SOURCE defined for time.h to give the +// correct strptime signature. As per feature_test_macros(7), +// define this before including any header files. + +// #ifndef _XOPEN_SOURCE +// #define _XOPEN_SOURCE +// #endif + +#ifdef HAVE_CONFIG_H +# include +#endif + +#if defined(REFCLOCK) && defined(CLOCK_PARSE) && defined(CLOCK_SEL240X) + +#include "ntp_syslog.h" +#include "ntp_types.h" +#include "ntp_fp.h" +#include "ntp_unixtime.h" +#include "ntp_calendar.h" +#include "ntp_machine.h" +#include "ntp_stdlib.h" + +#include "parse.h" + +#ifndef PARSESTREAM +# include +#else +# include "sys/parsestreams.h" +#endif + +#include + +////////////////////////////////////////////////////////////////////////////// +// The B8 output has the following format B8 = '\x01YYYY:ddd:hh:mm:ssq\r\n' +// where q = ' ' locked +// '.' <1 us +// '*' <10 us +// '#' <100 us +// '?' >100 us +// +// Based on this we need to recored the stime when we receive the +// character and end it when we see the \n. +// +// The q or quality character indicates satellite lock and sync. For the +// purposes of NTP we are going to call it valid when we receive anything but +// a '?'. But we are only going to call it synced when we receive a ' ' +////////////////////////////////////////////////////////////////////////////// + +static parse_inp_fnc_t inp_sel240x; +static parse_cvt_fnc_t cvt_sel240x; + +// Parse clock format structure describing the message above +static struct format sel240x_fmt = +{ { { 6, 3 }, + { 0, 0 }, + { 1, 4 }, + { 10, 2 }, + { 13, 2 }, + { 16, 2 }, + { 0, 0 }, + { 0, 0 }, + { 0, 0 }, + { 0, 0 }, + { 0, 0 }, + { 0, 0 } + }, + (const unsigned char *)"\x01 : : : : \x0d\x0a", + 0 +}; + +// Structure desctibing the parser +clockformat_t clock_sel240x = +{ + inp_sel240x, + cvt_sel240x, + pps_one, + (void*)&sel240x_fmt, + "SEL B8", + 25, + 0 +}; + +////////////////////////////////////////////////////////////////////////////// +static unsigned long +inp_sel240x( parse_t *parseio, + char ch, + timestamp_t *tstamp + ) +{ + unsigned long rc; + + parseprintf( DD_PARSE, + ("inp_sel240x(0x%lx, 0x%x, ...)\n",(long)parseio, ch)); + + switch( ch ) + { + case '\x01': + parseio->parse_index = 1; + parseio->parse_data[0] = ch; + parseio->parse_dtime.parse_stime = *tstamp; + rc = PARSE_INP_SKIP; + break; + case '\n': + if( (rc = parse_addchar(parseio, ch)) == PARSE_INP_SKIP ) + { + rc = parse_end( parseio ); + } + break; + default: + rc = parse_addchar( parseio, ch ); + } + + return rc; +} + +////////////////////////////////////////////////////////////////////////////// +static unsigned long +cvt_sel240x( unsigned char *buffer, + int size, + struct format *format, + clocktime_t *clock_time, + void *local + ) +{ + unsigned long rc = CVT_NONE; + + if( Strok(buffer, format->fixed_string) ) + { + struct tm ptime; + buffer++; + buffer = (unsigned char *) strptime( + (const char *)buffer, "%Y:%j:%H:%M:%S", &ptime ); + if( *(buffer+1) != '\x0d' ) + { + rc = CVT_FAIL | CVT_BADFMT; + } + else + { + clock_time->day = ptime.tm_mday; + clock_time->month = ptime.tm_mon + 1; + clock_time->year = ptime.tm_year + 1900; + clock_time->hour = ptime.tm_hour; + clock_time->minute = ptime.tm_min; + clock_time->second = ptime.tm_sec; + clock_time->usecond = 0; + clock_time->utcoffset = 0; + clock_time->flags = PARSEB_UTC; + + if( *buffer == '?' ) + { + clock_time->flags |= PARSEB_POWERUP; + } + else if( *buffer != ' ' ) + { + clock_time->flags |= PARSEB_NOSYNC; + } + + rc = CVT_OK; + } + } + + return rc; +} + +#else /* not (REFCLOCK && CLOCK_PARSE && CLOCK_SEL240X) */ +int clk_sel240x_bs; +#endif /* not (REFCLOCK && CLOCK_PARSE && CLOCK_SEL240X) */ diff --git a/contrib/ntp/libparse/clk_trimtaip.c b/contrib/ntp/libparse/clk_trimtaip.c index 67db47144..426e897be 100644 --- a/contrib/ntp/libparse/clk_trimtaip.c +++ b/contrib/ntp/libparse/clk_trimtaip.c @@ -6,7 +6,7 @@ * Trimble SV6 clock support - several collected codepieces * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -51,7 +51,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif /* 0000000000111111111122222222223333333 / char @@ -78,8 +78,8 @@ extern void printf P((const char *, ...)); 0 }; -static unsigned long cvt_trimtaip P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static unsigned long inp_trimtaip P((parse_t *, unsigned int, timestamp_t *)); +static parse_cvt_fnc_t cvt_trimtaip; +static parse_inp_fnc_t inp_trimtaip; clockformat_t clock_trimtaip = { @@ -92,7 +92,8 @@ clockformat_t clock_trimtaip = 0 /* no private data */ }; -static unsigned long +/* parse_cvt_fnc_t cvt_trimtaip */ +static u_long cvt_trimtaip( unsigned char *buffer, int size, @@ -141,31 +142,31 @@ cvt_trimtaip( } /* - * inp_trimtaip + * parse_inp_fnc_t inp_trimtaip * - * grep data from input stream + * grab data from input stream */ static u_long inp_trimtaip( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { unsigned int rtc; - + parseprintf(DD_PARSE, ("inp_trimtaip(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - + switch (ch) { case '>': parseprintf(DD_PARSE, ("inp_trimptaip: START seen\n")); - + parseio->parse_index = 1; parseio->parse_data[0] = ch; parseio->parse_dtime.parse_stime = *tstamp; /* collect timestamp */ return PARSE_INP_SKIP; - + case '<': parseprintf(DD_PARSE, ("inp_trimtaip: END seen\n")); if ((rtc = parse_addchar(parseio, ch)) == PARSE_INP_SKIP) diff --git a/contrib/ntp/libparse/clk_trimtsip.c b/contrib/ntp/libparse/clk_trimtsip.c index be97b74f0..6c71d7562 100644 --- a/contrib/ntp/libparse/clk_trimtsip.c +++ b/contrib/ntp/libparse/clk_trimtsip.c @@ -1,13 +1,13 @@ /* - * /src/NTP/ntp4-dev/libparse/clk_trimtsip.c,v 4.17 2005/04/16 17:32:10 kardel RELEASE_20050508_A + * /src/NTP/REPOSITORY/ntp4-dev/libparse/clk_trimtsip.c,v 4.19 2009/11/01 10:47:49 kardel RELEASE_20091101_A * - * clk_trimtsip.c,v 4.17 2005/04/16 17:32:10 kardel RELEASE_20050508_A + * clk_trimtsip.c,v 4.19 2009/11/01 10:47:49 kardel RELEASE_20091101_A * * Trimble TSIP support * Thanks to Sven Dietrich for providing test hardware * - * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2009 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -44,7 +44,7 @@ #include "ntp_syslog.h" #include "ntp_types.h" #include "ntp_fp.h" -#include "ntp_unixtime.h" +#include "timevalops.h" #include "ntp_calendar.h" #include "ntp_machine.h" #include "ntp_stdlib.h" @@ -116,8 +116,8 @@ struct trimble #define STATUS_UNSAFE 1 /* not enough receivers for full precision */ #define STATUS_SYNC 2 /* enough information for good operation */ -static unsigned long inp_tsip P((parse_t *, unsigned int, timestamp_t *)); -static unsigned long cvt_trimtsip P((unsigned char *, int, struct format *, clocktime_t *, void *)); +static unsigned long inp_tsip (parse_t *, char, timestamp_t *); +static unsigned long cvt_trimtsip (unsigned char *, int, struct format *, clocktime_t *, void *); struct clockformat clock_trimtsip = { @@ -136,7 +136,7 @@ struct clockformat clock_trimtsip = static unsigned long inp_tsip( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { @@ -183,13 +183,14 @@ inp_tsip( /* DLE,ETX -> end of packet */ parseio->parse_data[parseio->parse_index++] = DLE; parseio->parse_data[parseio->parse_index] = ch; - parseio->parse_ldsize = parseio->parse_index+1; + parseio->parse_ldsize = (u_short) (parseio->parse_index + 1); memcpy(parseio->parse_ldata, parseio->parse_data, parseio->parse_ldsize); parseio->parse_dtime.parse_msg[parseio->parse_dtime.parse_msglen++] = DLE; parseio->parse_dtime.parse_msg[parseio->parse_dtime.parse_msglen++] = ch; t->t_in_pkt = t->t_dle = 0; return PARSE_INP_TIME|PARSE_INP_DATA; } + /*FALLTHROUGH*/ default: /* collect data */ t->t_dle = 0; @@ -199,13 +200,13 @@ inp_tsip( return PARSE_INP_SKIP; } - -static int + +static short getshort( unsigned char *p ) { - return get_msb_short(&p); + return (short) get_msb_short(&p); } /* @@ -244,7 +245,7 @@ cvt_trimtsip( { unsigned char *bp; cmd = buffer[1]; - + switch(cmd) { case CMD_RCURTIME: @@ -257,15 +258,15 @@ cvt_trimtsip( bp = &mb(0); if (fetch_ieee754(&bp, IEEE_SINGLE, &secs, trim_offsets) != IEEE_OK) return CVT_FAIL|CVT_BADFMT; - + if ((secs.l_i <= 0) || (t->t_utcknown == 0)) { clock_time->flags = PARSEB_POWERUP; return CVT_OK; } - if (week < 990) { - week += 1024; + if (week < GPSWRAP) { + week += GPSWEEKS; } /* time OK */ @@ -274,7 +275,7 @@ cvt_trimtsip( bp = &mb(6); if (fetch_ieee754(&bp, IEEE_SINGLE, &utcoffset, trim_offsets) != IEEE_OK) return CVT_FAIL|CVT_BADFMT; - + L_SUB(&secs, &utcoffset); /* adjust GPS time to UTC time */ gpstolfp((unsigned short)week, (unsigned short)0, @@ -288,10 +289,10 @@ cvt_trimtsip( if (t->t_leap == ADDSECOND) clock_time->flags |= PARSEB_LEAPADD; - + if (t->t_leap == DELSECOND) clock_time->flags |= PARSEB_LEAPDEL; - + switch (t->t_operable) { case STATUS_SYNC: @@ -306,12 +307,12 @@ cvt_trimtsip( clock_time->flags |= PARSEB_NOSYNC|PARSEB_POWERUP; break; } - + if (t->t_mode == 0) clock_time->flags |= PARSEB_POSITION; - + clock_time->flags |= PARSEB_S_LEAP|PARSEB_S_POSITION; - + return CVT_OK; } /* case 0x41 */ @@ -345,26 +346,26 @@ cvt_trimtsip( { l_fp t0t; unsigned char *lbp; - + /* UTC correction data - derive a leap warning */ - int tls = t->t_gpsutc = getshort((unsigned char *)&mb(12)); /* current leap correction (GPS-UTC) */ - int tlsf = t->t_gpsutcleap = getshort((unsigned char *)&mb(24)); /* new leap correction */ - - t->t_weekleap = getshort((unsigned char *)&mb(20)); /* week no of leap correction */ - if (t->t_weekleap < 990) - t->t_weekleap += 1024; - - t->t_dayleap = getshort((unsigned char *)&mb(22)); /* day in week of leap correction */ - t->t_week = getshort((unsigned char *)&mb(18)); /* current week no */ - if (t->t_week < 990) - t->t_week += 1024; - + int tls = t->t_gpsutc = (u_short) getshort((unsigned char *)&mb(12)); /* current leap correction (GPS-UTC) */ + int tlsf = t->t_gpsutcleap = (u_short) getshort((unsigned char *)&mb(24)); /* new leap correction */ + + t->t_weekleap = (u_short) getshort((unsigned char *)&mb(20)); /* week no of leap correction */ + if (t->t_weekleap < GPSWRAP) + t->t_weekleap = (u_short)(t->t_weekleap + GPSWEEKS); + + t->t_dayleap = (u_short) getshort((unsigned char *)&mb(22)); /* day in week of leap correction */ + t->t_week = (u_short) getshort((unsigned char *)&mb(18)); /* current week no */ + if (t->t_week < GPSWRAP) + t->t_week = (u_short)(t->t_weekleap + GPSWEEKS); + lbp = (unsigned char *)&mb(14); /* last update time */ if (fetch_ieee754(&lbp, IEEE_SINGLE, &t0t, trim_offsets) != IEEE_OK) return CVT_FAIL|CVT_BADFMT; t->t_utcknown = t0t.l_ui != 0; - + if ((t->t_utcknown) && /* got UTC information */ (tlsf != tls) && /* something will change */ ((t->t_weekleap - t->t_week) < 5)) /* and close in the future */ @@ -398,6 +399,12 @@ int clk_trimtsip_bs; * History: * * clk_trimtsip.c,v + * Revision 4.19 2009/11/01 10:47:49 kardel + * de-P() + * + * Revision 4.18 2009/11/01 08:46:46 kardel + * clarify case FALLTHROUGH + * * Revision 4.17 2005/04/16 17:32:10 kardel * update copyright * diff --git a/contrib/ntp/libparse/clk_varitext.c b/contrib/ntp/libparse/clk_varitext.c index 01b871985..022549e82 100644 --- a/contrib/ntp/libparse/clk_varitext.c +++ b/contrib/ntp/libparse/clk_varitext.c @@ -9,14 +9,14 @@ * clk_varitext.c,v 1.5 2005/04/16 17:32:10 kardel RELEASE_20050508_A * * Varitext code variant by A.McConnell 1997/01/19 - * + * * Supports Varitext's Radio Clock - * + * * Used the Meinberg/Computime clock as a template for Varitext Radio Clock * * Codebase: * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -55,7 +55,7 @@ # include #else # include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern int printf (const char *, ...); #endif static const u_char VT_INITIALISED = 0x01; @@ -67,31 +67,31 @@ static const u_char VT_LAST_TELEGRAM_OK = 0x20; /* * The Varitext receiver sends a datagram in the following format every minute - * - * Timestamp T:YY:MM:MD:WD:HH:MM:SSCRLFSTXXX + * + * Timestamp T:YY:MM:MD:WD:HH:MM:SSCRLFSTXXX * Pos 0123456789012345678901 2 3 4567 * 0000000000111111111122 2 2 2222 - * Parse T: : : : : : : \r\n - * - * T Startcharacter "T" specifies start of the timestamp - * YY Year MM Month 1-12 - * MD Day of the month - * WD Day of week - * HH Hour - * MM Minute - * SS Second - * CR Carriage return - * LF Linefeed + * Parse T: : : : : : : \r\n + * + * T Startcharacter "T" specifies start of the timestamp + * YY Year MM Month 1-12 + * MD Day of the month + * WD Day of week + * HH Hour + * MM Minute + * SS Second + * CR Carriage return + * LF Linefeed * ST Status character * Bit 0 - Set= Initialised; Reset=Time Invalid (DO NOT USE) - * Bit 1 - Set= Synchronised; Reset= Unsynchronised - * Bit 2 - Set= Alarm state; Reset= No alarm - * Bit 3 - Set= BST; Reset= GMT - * Bit 4 - Set= Seasonal change in approx hour; Reset= No seasonal change expected + * Bit 1 - Set= Synchronised; Reset= Unsynchronised + * Bit 2 - Set= Alarm state; Reset= No alarm + * Bit 3 - Set= BST; Reset= GMT + * Bit 4 - Set= Seasonal change in approx hour; Reset= No seasonal change expected * Bit 5 - Set= Last MSF telegram was OK; Reset= Last telegram was in error; - * Bit 6 - Always set + * Bit 6 - Always set * Bit 7 - Unused - * XXX Checksum calculated using Fletcher's method (ignored for now). + * XXX Checksum calculated using Fletcher's method (ignored for now). */ static struct format varitext_fmt = @@ -105,8 +105,8 @@ static struct format varitext_fmt = 0 }; -static u_long cvt_varitext P((unsigned char *, int, struct format *, clocktime_t *, void *)); -static u_long inp_varitext P((parse_t *, unsigned int, timestamp_t *)); +static parse_cvt_fnc_t cvt_varitext; +static parse_inp_fnc_t inp_varitext; struct varitext { unsigned char start_found; @@ -128,11 +128,11 @@ clockformat_t clock_varitext = }; /* - * cvt_varitext - * + * parse_cvt_fnc_t cvt_varitext + * * convert simple type format */ -static u_long +static u_long cvt_varitext( unsigned char *buffer, int size, @@ -142,7 +142,7 @@ cvt_varitext( ) { - if (!Strok(buffer, format->fixed_string)) { + if (!Strok(buffer, format->fixed_string)) { return CVT_NONE; } else { if (Stoi(&buffer[format->field_offsets[O_DAY].offset], &clock_time->day, @@ -156,7 +156,7 @@ cvt_varitext( Stoi(&buffer[format->field_offsets[O_MIN].offset], &clock_time->minute, format->field_offsets[O_MIN].length) || Stoi(&buffer[format->field_offsets[O_SEC].offset], &clock_time->second, - format->field_offsets[O_SEC].length)) { + format->field_offsets[O_SEC].length)) { return CVT_FAIL | CVT_BADFMT; } else { u_char *f = (u_char*) &buffer[format->field_offsets[O_FLAGS].offset]; @@ -170,24 +170,25 @@ cvt_varitext( clock_time->flags |= PARSEB_DST; } /* - if (!((*f) & VT_INITIALISED)) Clock not initialised + if (!((*f) & VT_INITIALISED)) Clock not initialised clock_time->flags |= PARSEB_POWERUP; - - if (!((*f) & VT_SYNCHRONISED)) Clock not synchronised + + if (!((*f) & VT_SYNCHRONISED)) Clock not synchronised clock_time->flags |= PARSEB_NOSYNC; - - if (((*f) & VT_SEASON_CHANGE)) Seasonal change expected in the next hour + + if (((*f) & VT_SEASON_CHANGE)) Seasonal change expected in the next hour clock_time->flags |= PARSEB_ANNOUNCE; */ - return CVT_OK; + return CVT_OK; } } } -static u_long +/* parse_inp_fnc_t inp_varitext */ +static u_long inp_varitext( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { @@ -196,10 +197,10 @@ inp_varitext( parseprintf(DD_PARSE, ("inp_varitext(0x%lx, 0x%x, ...)\n", (long)parseio, ch)); - if (!t) + if (!t) return PARSE_INP_SKIP; /* local data not allocated - sigh! */ - if (ch == 'T') + if (ch == 'T') t->tstamp = *tstamp; if ((t->previous_ch == 'T') && (ch == ':')) @@ -224,7 +225,7 @@ inp_varitext( return rtc; } - if (t->end_found) + if (t->end_found) { if (++(t->end_count) == 4) /* Finally found the end of the message */ { @@ -235,16 +236,16 @@ inp_varitext( return parse_end(parseio); else return rtc; - } + } } - if ((t->previous_ch == '\r') && (ch == '\n')) + if ((t->previous_ch == '\r') && (ch == '\n')) { t->end_found = 1; } } - + t->previous_ch = ch; return PARSE_INP_SKIP; diff --git a/contrib/ntp/libparse/clk_wharton.c b/contrib/ntp/libparse/clk_wharton.c index b4332fbcd..a65bc5386 100644 --- a/contrib/ntp/libparse/clk_wharton.c +++ b/contrib/ntp/libparse/clk_wharton.c @@ -30,7 +30,7 @@ #include #else #include "sys/parsestreams.h" -extern void printf P((const char *, ...)); +extern void printf (const char *, ...); #endif /* @@ -74,8 +74,11 @@ extern void printf P((const char *, ...)); * */ +static parse_cvt_fnc_t cvt_wharton_400a; +static parse_inp_fnc_t inp_wharton_400a; + /* - * cvt_wharton_400a + * parse_cvt_fnc_t cvt_wharton_400a * * convert simple type format */ @@ -91,7 +94,7 @@ cvt_wharton_400a( int i; /* The given `size' includes a terminating null-character. */ - if (size != 16 || buffer[0] != STX || buffer[14] != ETX + if (size != 15 || buffer[0] != STX || buffer[14] != ETX || buffer[13] < '0' || buffer[13] > ('0' + 0xf)) return CVT_NONE; for (i = 1; i < 13; i += 1) @@ -121,14 +124,14 @@ cvt_wharton_400a( } /* - * inp_wharton_400a + * parse_inp_fnc_t inp_wharton_400a * - * grep data from input stream + * grab data from input stream */ static u_long inp_wharton_400a( parse_t *parseio, - unsigned int ch, + char ch, timestamp_t *tstamp ) { @@ -166,7 +169,7 @@ clockformat_t clock_wharton_400a = 0, /* conversion configuration */ "WHARTON 400A Series clock Output Format 1", /* String format name */ 15, /* string buffer */ - 0 /* no private data (complete pakets) */ + 0 /* no private data (complete packets) */ }; #else /* not (REFCLOCK && CLOCK_PARSE && CLOCK_WHARTON_400A) */ diff --git a/contrib/ntp/libparse/data_mbg.c b/contrib/ntp/libparse/data_mbg.c index 9b6f1aae2..0b3808c8b 100644 --- a/contrib/ntp/libparse/data_mbg.c +++ b/contrib/ntp/libparse/data_mbg.c @@ -33,6 +33,7 @@ * */ +#include #ifdef PARSESTREAM #define NEED_BOPS #include "ntp_string.h" @@ -42,12 +43,13 @@ #include "ntp_types.h" #include "ntp_stdlib.h" #include "ntp_fp.h" +#include "ntp_calendar.h" #include "mbg_gps166.h" #include "binio.h" #include "ieee754io.h" -static void get_mbg_tzname P((unsigned char **, char *)); -static void mbg_time_status_str P((char **, unsigned int, int)); +static void get_mbg_tzname (unsigned char **, char *); +static void mbg_time_status_str (char **, unsigned int, int); #if 0 /* no actual floats on Meinberg binary interface */ static offsets_t mbg_float = { 1, 0, 3, 2, 0, 0, 0, 0 }; /* byte order for meinberg floats */ @@ -62,10 +64,10 @@ put_mbg_header( GPS_MSG_HDR *headerp ) { - put_lsb_short(bufpp, headerp->gps_cmd); - put_lsb_short(bufpp, headerp->gps_len); - put_lsb_short(bufpp, headerp->gps_data_csum); - put_lsb_short(bufpp, headerp->gps_hdr_csum); + put_lsb_short(bufpp, headerp->cmd); + put_lsb_short(bufpp, headerp->len); + put_lsb_short(bufpp, headerp->data_csum); + put_lsb_short(bufpp, headerp->hdr_csum); } void @@ -74,7 +76,7 @@ get_mbg_sw_rev( SW_REV *sw_revp ) { - sw_revp->code = get_lsb_short(bufpp); + sw_revp->code = get_lsb_uint16(bufpp); memcpy(sw_revp->name, *bufpp, sizeof(sw_revp->name)); *bufpp += sizeof(sw_revp->name); } @@ -85,8 +87,8 @@ get_mbg_ascii_msg( ASCII_MSG *ascii_msgp ) { - ascii_msgp->csum = get_lsb_short(bufpp); - ascii_msgp->valid = get_lsb_short(bufpp); + ascii_msgp->csum = (CSUM) get_lsb_short(bufpp); + ascii_msgp->valid = get_lsb_int16(bufpp); memcpy(ascii_msgp->s, *bufpp, sizeof(ascii_msgp->s)); *bufpp += sizeof(ascii_msgp->s); } @@ -97,7 +99,7 @@ get_mbg_svno( SVNO *svnop ) { - *svnop = get_lsb_short(bufpp); + *svnop = (SVNO) get_lsb_short(bufpp); } void @@ -106,7 +108,7 @@ get_mbg_health( HEALTH *healthp ) { - *healthp = get_lsb_short(bufpp); + *healthp = (HEALTH) get_lsb_short(bufpp); } void @@ -115,7 +117,7 @@ get_mbg_cfg( CFG *cfgp ) { - *cfgp = get_lsb_short(bufpp); + *cfgp = (CFG) get_lsb_short(bufpp); } void @@ -124,7 +126,7 @@ get_mbg_tgps( T_GPS *tgpsp ) { - tgpsp->wn = get_lsb_short(bufpp); + tgpsp->wn = get_lsb_uint16(bufpp); tgpsp->sec = get_lsb_long(bufpp); tgpsp->tick = get_lsb_long(bufpp); } @@ -132,20 +134,20 @@ get_mbg_tgps( void get_mbg_tm( unsigned char **buffpp, - TM *tmp + TM_GPS *tmp ) { - tmp->year = get_lsb_short(buffpp); + tmp->year = get_lsb_int16(buffpp); tmp->month = *(*buffpp)++; - tmp->mday = *(*buffpp)++; - tmp->yday = get_lsb_short(buffpp); - tmp->wday = *(*buffpp)++; - tmp->hour = *(*buffpp)++; - tmp->minute = *(*buffpp)++; - tmp->second = *(*buffpp)++; - tmp->frac = get_lsb_long(buffpp); + tmp->mday = *(*buffpp)++; + tmp->yday = get_lsb_int16(buffpp); + tmp->wday = *(*buffpp)++; + tmp->hour = *(*buffpp)++; + tmp->min = *(*buffpp)++; + tmp->sec = *(*buffpp)++; + tmp->frac = get_lsb_long(buffpp); tmp->offs_from_utc = get_lsb_long(buffpp); - tmp->status= get_lsb_short(buffpp); + tmp->status = get_lsb_uint16(buffpp); } void @@ -154,7 +156,7 @@ get_mbg_ttm( TTM *ttmp ) { - ttmp->channel = get_lsb_short(buffpp); + ttmp->channel = get_lsb_int16(buffpp); get_mbg_tgps(buffpp, &ttmp->t); get_mbg_tm(buffpp, &ttmp->tm); } @@ -165,9 +167,9 @@ get_mbg_synth( SYNTH *synthp ) { - synthp->freq = get_lsb_short(buffpp); - synthp->range = get_lsb_short(buffpp); - synthp->phase = get_lsb_short(buffpp); + synthp->freq = get_lsb_int16(buffpp); + synthp->range = get_lsb_int16(buffpp); + synthp->phase = get_lsb_int16(buffpp); } static void @@ -176,7 +178,7 @@ get_mbg_tzname( char *tznamep ) { - strncpy(tznamep, (char *)*buffpp, sizeof(TZ_NAME)); + strlcpy(tznamep, (char *)*buffpp, sizeof(TZ_NAME)); *buffpp += sizeof(TZ_NAME); } @@ -200,7 +202,7 @@ get_mbg_antinfo( ANT_INFO *antinfop ) { - antinfop->status = get_lsb_short(buffpp); + antinfop->status = get_lsb_int16(buffpp); get_mbg_tm(buffpp, &antinfop->tm_disconn); get_mbg_tm(buffpp, &antinfop->tm_reconn); antinfop->delta_t = get_lsb_long(buffpp); @@ -215,8 +217,8 @@ mbg_time_status_str( { static struct state { - int flag; /* bit flag */ - const char *string; /* bit name */ + int flag; /* bit flag */ + const char *string; /* bit name */ } states[] = { { TM_UTC, "UTC CORR" }, @@ -232,7 +234,7 @@ mbg_time_status_str( { char *start, *p; struct state *s; - + start = p = *buffpp; for (s = states; s->flag; s++) @@ -241,35 +243,37 @@ mbg_time_status_str( { if (p != *buffpp) { - strncpy(p, ", ", size - (p - start)); + strlcpy(p, ", ", size - (p - start)); p += 2; } - strncpy(p, s->string, size - (p - start)); + strlcpy(p, s->string, size - (p - start)); p += strlen(p); } } *buffpp = p; } } - + void mbg_tm_str( char **buffpp, - TM *tmp, - int size + TM_GPS *tmp, + int size, + int print_status ) { char *s = *buffpp; snprintf(*buffpp, size, "%04d-%02d-%02d %02d:%02d:%02d.%07ld (%c%02d%02d) ", tmp->year, tmp->month, tmp->mday, - tmp->hour, tmp->minute, tmp->second, tmp->frac, + tmp->hour, tmp->min, tmp->sec, (long) tmp->frac, (tmp->offs_from_utc < 0) ? '-' : '+', - abs(tmp->offs_from_utc) / 3600, - (abs(tmp->offs_from_utc) / 60) % 60); + abs((int)tmp->offs_from_utc) / 3600, + (abs((int)tmp->offs_from_utc) / 60) % 60); *buffpp += strlen(*buffpp); - mbg_time_status_str(buffpp, tmp->status, size - (*buffpp - s)); + if (print_status) + mbg_time_status_str(buffpp, tmp->status, size - (*buffpp - s)); } void @@ -280,8 +284,8 @@ mbg_tgps_str( ) { snprintf(*buffpp, size, "week %d + %ld days + %ld.%07ld sec", - tgpsp->wn, tgpsp->sec / 86400, - tgpsp->sec % 86400, tgpsp->tick); + tgpsp->wn, (long) tgpsp->sec / SECSPERDAY, + (long) tgpsp->sec % SECSPERDAY, (long) tgpsp->tick); *buffpp += strlen(*buffpp); } @@ -292,19 +296,19 @@ get_mbg_cfgh( ) { int i; - - cfghp->csum = get_lsb_short(buffpp); - cfghp->valid = get_lsb_short(buffpp); + + cfghp->csum = (CSUM) get_lsb_short(buffpp); + cfghp->valid = get_lsb_int16(buffpp); get_mbg_tgps(buffpp, &cfghp->tot_51); get_mbg_tgps(buffpp, &cfghp->tot_63); get_mbg_tgps(buffpp, &cfghp->t0a); - for (i = MIN_SVNO; i <= MAX_SVNO; i++) + for (i = 0; i < N_SVNO_GPS; i++) { get_mbg_cfg(buffpp, &cfghp->cfg[i]); } - - for (i = MIN_SVNO; i <= MAX_SVNO; i++) + + for (i = 0; i < N_SVNO_GPS; i++) { get_mbg_health(buffpp, &cfghp->health[i]); } @@ -316,23 +320,23 @@ get_mbg_utc( UTC *utcp ) { - utcp->csum = get_lsb_short(buffpp); - utcp->valid = get_lsb_short(buffpp); + utcp->csum = (CSUM) get_lsb_short(buffpp); + utcp->valid = get_lsb_int16(buffpp); get_mbg_tgps(buffpp, &utcp->t0t); - + if (fetch_ieee754(buffpp, IEEE_DOUBLE, &utcp->A0, mbg_double) != IEEE_OK) { L_CLR(&utcp->A0); } - + if (fetch_ieee754(buffpp, IEEE_DOUBLE, &utcp->A1, mbg_double) != IEEE_OK) { L_CLR(&utcp->A1); } - utcp->WNlsf = get_lsb_short(buffpp); - utcp->DNt = get_lsb_short(buffpp); + utcp->WNlsf = get_lsb_uint16(buffpp); + utcp->DNt = get_lsb_int16(buffpp); utcp->delta_tls = *(*buffpp)++; utcp->delta_tlsf = *(*buffpp)++; } @@ -344,7 +348,7 @@ get_mbg_lla( ) { int i; - + for (i = LAT; i <= ALT; i++) { if (fetch_ieee754(buffpp, IEEE_DOUBLE, &lla[i], mbg_double) != IEEE_OK) @@ -366,7 +370,7 @@ get_mbg_xyz( ) { int i; - + for (i = XP; i <= ZP; i++) { if (fetch_ieee754(buffpp, IEEE_DOUBLE, &xyz[i], mbg_double) != IEEE_OK) @@ -382,14 +386,14 @@ get_mbg_comparam( COM_PARM *comparamp ) { - int i; - + size_t i; + comparamp->baud_rate = get_lsb_long(buffpp); for (i = 0; i < sizeof(comparamp->framing); i++) { comparamp->framing[i] = *(*buffpp)++; } - comparamp->handshake = get_lsb_short(buffpp); + comparamp->handshake = get_lsb_int16(buffpp); } void @@ -399,12 +403,12 @@ get_mbg_portparam( ) { int i; - - for (i = 0; i < N_COM; i++) + + for (i = 0; i < DEFAULT_N_COM; i++) { get_mbg_comparam(buffpp, &portparamp->com[i]); } - for (i = 0; i < N_COM; i++) + for (i = 0; i < DEFAULT_N_COM; i++) { portparamp->mode[i] = *(*buffpp)++; } @@ -415,20 +419,20 @@ get_mbg_portparam( { \ L_CLR(addr); \ } - + void get_mbg_eph( unsigned char ** buffpp, EPH *ephp ) { - ephp->csum = get_lsb_short(buffpp); - ephp->valid = get_lsb_short(buffpp); - - ephp->health = get_lsb_short(buffpp); - ephp->IODC = get_lsb_short(buffpp); - ephp->IODE2 = get_lsb_short(buffpp); - ephp->IODE3 = get_lsb_short(buffpp); + ephp->csum = (CSUM) get_lsb_short(buffpp); + ephp->valid = get_lsb_int16(buffpp); + + ephp->health = (HEALTH) get_lsb_short(buffpp); + ephp->IODC = (IOD) get_lsb_short(buffpp); + ephp->IODE2 = (IOD) get_lsb_short(buffpp); + ephp->IODE3 = (IOD) get_lsb_short(buffpp); get_mbg_tgps(buffpp, &ephp->tt); get_mbg_tgps(buffpp, &ephp->t0c); @@ -455,7 +459,7 @@ get_mbg_eph( FETCH_DOUBLE(buffpp, &ephp->af2); FETCH_DOUBLE(buffpp, &ephp->tgd); - ephp->URA = get_lsb_short(buffpp); + ephp->URA = get_lsb_uint16(buffpp); ephp->L2code = *(*buffpp)++; ephp->L2flag = *(*buffpp)++; @@ -467,10 +471,10 @@ get_mbg_alm( ALM *almp ) { - almp->csum = get_lsb_short(buffpp); - almp->valid = get_lsb_short(buffpp); - - almp->health = get_lsb_short(buffpp); + almp->csum = (CSUM) get_lsb_short(buffpp); + almp->valid = get_lsb_int16(buffpp); + + almp->health = (HEALTH) get_lsb_short(buffpp); get_mbg_tgps(buffpp, &almp->t0a); @@ -492,8 +496,8 @@ get_mbg_iono( IONO *ionop ) { - ionop->csum = get_lsb_short(buffpp); - ionop->valid = get_lsb_short(buffpp); + ionop->csum = (CSUM) get_lsb_short(buffpp); + ionop->valid = get_lsb_int16(buffpp); FETCH_DOUBLE(buffpp, &ionop->alpha_0); FETCH_DOUBLE(buffpp, &ionop->alpha_1); diff --git a/contrib/ntp/libparse/gpstolfp.c b/contrib/ntp/libparse/gpstolfp.c index fd7be3124..c162429ed 100644 --- a/contrib/ntp/libparse/gpstolfp.c +++ b/contrib/ntp/libparse/gpstolfp.c @@ -32,11 +32,10 @@ * SUCH DAMAGE. * */ +#include #include "ntp_fp.h" - -#define GPSORIGIN ULONG_CONST(2524953600) /* NTP origin - GPS origin in seconds */ -#define SECSPERWEEK (unsigned)(604800) /* seconds per week - GPS tells us about weeks */ -#define GPSWRAP 990 /* assume week count less than this in the previous epoch */ +#include "ntp_calendar.h" +#include "parse.h" void gpstolfp( @@ -48,10 +47,10 @@ gpstolfp( { if (weeks < GPSWRAP) { - weeks += 1024; + weeks += GPSWEEKS; } - lfp->l_ui = weeks * SECSPERWEEK + days * 86400 + seconds + GPSORIGIN; /* convert to NTP time */ + lfp->l_ui = (uint32_t)(weeks * SECSPERWEEK + days * SECSPERDAY + seconds + GPSORIGIN); /* convert to NTP time */ lfp->l_uf = 0; } diff --git a/contrib/ntp/libparse/ieee754io.c b/contrib/ntp/libparse/ieee754io.c index 27c65255e..61bc8533b 100644 --- a/contrib/ntp/libparse/ieee754io.c +++ b/contrib/ntp/libparse/ieee754io.c @@ -43,9 +43,9 @@ #include "ntp_fp.h" #include "ieee754io.h" -static unsigned char get_byte P((unsigned char *, offsets_t, int *)); +static unsigned char get_byte (unsigned char *, offsets_t, int *); #ifdef __not_yet__ -static void put_byte P((unsigned char *, offsets_t, int *, unsigned char)); +static void put_byte (unsigned char *, offsets_t, int *, unsigned char); #endif #ifdef LIBDEBUG @@ -89,14 +89,15 @@ fmt_flt( unsigned long ch ) { - char *buf; + char *buf; - LIB_GETBUF(buf); - sprintf(buf, "%c %s %s %s", sign ? '-' : '+', - fmt_blong(ch, 11), - fmt_blong(mh, 20), - fmt_blong(ml, 32)); - return buf; + LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%c %s %s %s", sign ? '-' : '+', + fmt_blong(ch, 11), + fmt_blong(mh, 20), + fmt_blong(ml, 32)); + + return buf; } static char * @@ -105,15 +106,18 @@ fmt_hex( int length ) { - char *buf; - int i; + char * buf; + char hex[4]; + int i; + + LIB_GETBUF(buf); + buf[0] = '\0'; + for (i = 0; i < length; i++) { + snprintf(hex, sizeof(hex), "%02x", bufp[i]); + strlcat(buf, hex, LIB_BUFLENGTH); + } - LIB_GETBUF(buf); - for (i = 0; i < length; i++) - { - sprintf(buf+i*2, "%02x", bufp[i]); - } - return buf; + return buf; } #endif @@ -217,7 +221,7 @@ fetch_ieee754( mantissa_high = 0; mantissa_low = (val &0x7F) << 16; - mantissa_low |= get_byte(bufp, offsets, &fieldindex) << 8; + mantissa_low |= (u_long)get_byte(bufp, offsets, &fieldindex) << 8; mantissa_low |= get_byte(bufp, offsets, &fieldindex); break; @@ -226,12 +230,12 @@ fetch_ieee754( characteristic |= (val & 0xF0) >> 4; /* grab lower characteristic bits */ mantissa_high = (val & 0x0F) << 16; - mantissa_high |= get_byte(bufp, offsets, &fieldindex) << 8; + mantissa_high |= (u_long)get_byte(bufp, offsets, &fieldindex) << 8; mantissa_high |= get_byte(bufp, offsets, &fieldindex); - mantissa_low = get_byte(bufp, offsets, &fieldindex) << 24; - mantissa_low |= get_byte(bufp, offsets, &fieldindex) << 16; - mantissa_low |= get_byte(bufp, offsets, &fieldindex) << 8; + mantissa_low = (u_long)get_byte(bufp, offsets, &fieldindex) << 24; + mantissa_low |= (u_long)get_byte(bufp, offsets, &fieldindex) << 16; + mantissa_low |= (u_long)get_byte(bufp, offsets, &fieldindex) << 8; mantissa_low |= get_byte(bufp, offsets, &fieldindex); break; diff --git a/contrib/ntp/libparse/info_trimble.c b/contrib/ntp/libparse/info_trimble.c index eea6cbd3f..53b2e32c1 100644 --- a/contrib/ntp/libparse/info_trimble.c +++ b/contrib/ntp/libparse/info_trimble.c @@ -2,6 +2,7 @@ * Automatically generated - do not modify */ +#include #include "ntp_types.h" #include "ntpd.h" #include "trimble.h" @@ -47,7 +48,7 @@ cmd_info_t trimble_scmds[] = { { CMD_CHIGH8CNT, "CMD_CHIGH8CNT", "high-8 (best 4) / high-6 (overdetermined) control (0x75)", "", 0 }, { CMD_CMAXDGPSCOR, "CMD_CMAXDGPSCOR", "maximum rate of DGPS corrections (0x77)", "", 0 }, { CMD_CSUPER, "CMD_CSUPER", "super paket (0x8E)", "", 0 }, - { 0xFF, "", "" } + { 0xFF, "", "", "", 0 } }; @@ -89,6 +90,5 @@ cmd_info_t trimble_rcmds[] = { { CMD_RDOUBLELLA, "CMD_RDOUBLELLA", "double precision LLA (0x84)", "gps_position_ext(LLA)", RO|DEF }, { CMD_RDGPSSTAT, "CMD_RDGPSSTAT", "differential correction status (0x85)", "trimble_dgpsstatus", RO }, { CMD_RSUPER, "CMD_RSUPER", "super paket (0x8F)", "", 0 }, - { 0xFF, "", "" } + { 0xFF, "", "", "", 0 } }; - diff --git a/contrib/ntp/libparse/mfp_mul.c b/contrib/ntp/libparse/mfp_mul.c index 677ed181f..43c1e39fa 100644 --- a/contrib/ntp/libparse/mfp_mul.c +++ b/contrib/ntp/libparse/mfp_mul.c @@ -32,6 +32,7 @@ * SUCH DAMAGE. * */ +#include #include #include "ntp_stdlib.h" #include "ntp_types.h" diff --git a/contrib/ntp/libparse/mkinfo_rcmd.sed b/contrib/ntp/libparse/mkinfo_rcmd.sed index 570c7a0b8..b8ed6232e 100644 --- a/contrib/ntp/libparse/mkinfo_rcmd.sed +++ b/contrib/ntp/libparse/mkinfo_rcmd.sed @@ -1,8 +1,8 @@ 1i\ \ +\ cmd_info_t trimble_rcmds[] = { -s!^#define[ ][ ]*\(CMD_R[^ ]*\)[ ][ ]*\([^ ]*\)[ ][ ]*/\*[ ][ ]*\(.*\)[ ]*:\([^:]*\):\([^:]*\)[ ][ ]*\*/! { \1, "\1", "\3 (\2)", "\4", \5 },!p +s!^#define[ \ ][ \ ]*\(CMD_R[^ \ ]*\)[ \ ][ \ ]*\([^ \ ]*\)[ \ ][ \ ]*/\*[ \ ][ \ ]*\(.*\)[ \ ]*:\([^:]*\):\([^:]*\)[ \ ][ \ ]*\*/!\ { \1, "\1", "\3 (\2)", "\4", \5 },!p $a\ - { 0xFF, "", "" }\ -};\ - +\ { 0xFF, "", "", "", 0 }\ +}; diff --git a/contrib/ntp/libparse/mkinfo_scmd.sed b/contrib/ntp/libparse/mkinfo_scmd.sed index cabe06545..fb58d32db 100644 --- a/contrib/ntp/libparse/mkinfo_scmd.sed +++ b/contrib/ntp/libparse/mkinfo_scmd.sed @@ -1,8 +1,9 @@ 1i\ /*\ - * Automatically generated - do not modify\ - */\ +\ * Automatically generated - do not modify\ +\ */\ \ +#include \ #include "ntp_types.h"\ #include "ntpd.h"\ #include "trimble.h"\ @@ -10,7 +11,5 @@ cmd_info_t trimble_scmds[] = { s!^#define[ ][ ]*\(CMD_C[^ ]*\)[ ][ ]*\([^ ]*\)[ ][ ]*/\*[ ][ ]*\(.*\)[ ][ ]*\*/! { \1, "\1", "\3 (\2)", "", 0 },!p $a\ - { 0xFF, "", "" }\ -};\ - - +\ { 0xFF, "", "", "", 0 }\ +}; diff --git a/contrib/ntp/libparse/parse.c b/contrib/ntp/libparse/parse.c index dfbbaa608..64167f152 100644 --- a/contrib/ntp/libparse/parse.c +++ b/contrib/ntp/libparse/parse.c @@ -1,6 +1,6 @@ /* * /src/NTP/ntp4-dev/libparse/parse.c,v 4.20 2005/08/06 17:39:40 kardel RELEASE_20050806_A - * + * * parse.c,v 4.20 2005/08/06 17:39:40 kardel RELEASE_20050806_A * * Parser module for reference clock @@ -12,7 +12,7 @@ * when PARSEKERNEL is not defined NTP time stamps will be used. * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -51,7 +51,7 @@ static char rcsid[] = "parse.c,v 4.20 2005/08/06 17:39:40 kardel RELEASE_2005080 #endif #include "ntp_fp.h" -#include "ntp_unixtime.h" +#include "timevalops.h" #include "ntp_calendar.h" #include "ntp_stdlib.h" #include "ntp_machine.h" @@ -68,7 +68,7 @@ static char rcsid[] = "parse.c,v 4.20 2005/08/06 17:39:40 kardel RELEASE_2005080 extern clockformat_t *clockformats[]; extern unsigned short nformats; -static u_long timepacket P((parse_t *)); +static u_long timepacket (parse_t *); /* * strings support usually not in kernel - duplicated, but what the heck @@ -106,7 +106,7 @@ Strcmp( while (!(c = *s++ - *t++) && *s && *t) /* empty loop */; - + return c; } @@ -128,10 +128,6 @@ parse_timedout( delta.tv_usec += 1000000; } #else - extern long tstouslo[]; - extern long tstousmid[]; - extern long tstoushi[]; - l_fp delt; delt = tstamp->fp; @@ -158,10 +154,10 @@ parse_ioinit( ) { parseprintf(DD_PARSE, ("parse_iostart\n")); - + parseio->parse_plen = 0; parseio->parse_pdata = (void *)0; - + parseio->parse_data = 0; parseio->parse_ldata = 0; parseio->parse_dsize = 0; @@ -170,7 +166,7 @@ parse_ioinit( parseio->parse_ioflags = PARSE_IO_CS7; /* usual unix default */ parseio->parse_index = 0; parseio->parse_ldsize = 0; - + return 1; } @@ -192,15 +188,15 @@ parse_ioend( unsigned int parse_restart( parse_t *parseio, - unsigned int ch + char ch ) { unsigned int updated = PARSE_INP_SKIP; - + /* * re-start packet - timeout - overflow - start symbol */ - + if (parseio->parse_index) { /* @@ -212,17 +208,17 @@ parse_restart( parseio->parse_ldsize = parseio->parse_index; updated = PARSE_INP_TIME; } - + parseio->parse_index = 1; parseio->parse_data[0] = ch; parseprintf(DD_PARSE, ("parse: parse_restart: buffer start (updated = %x)\n", updated)); return updated; } - + unsigned int parse_addchar( parse_t *parseio, - unsigned int ch + char ch ) { /* @@ -234,7 +230,7 @@ parse_addchar( * collect into buffer */ parseprintf(DD_PARSE, ("parse: parse_addchar: buffer[%d] = 0x%x\n", parseio->parse_index, ch)); - parseio->parse_data[parseio->parse_index++] = ch; + parseio->parse_data[parseio->parse_index++] = (char)ch; return PARSE_INP_SKIP; } else @@ -243,7 +239,7 @@ parse_addchar( */ return parse_restart(parseio, ch); } - + unsigned int parse_end( parse_t *parseio @@ -264,11 +260,11 @@ parse_end( int parse_ioread( register parse_t *parseio, - register unsigned int ch, + register char ch, register timestamp_t *tstamp ) { - register unsigned updated = CVT_NONE; + register u_int updated = CVT_NONE; /* * within STREAMS CSx (x < 8) chars still have the upper bits set * so we normalize the characters by masking unecessary bits off. @@ -286,9 +282,9 @@ parse_ioread( case PARSE_IO_CS7: ch &= 0x7F; break; - + case PARSE_IO_CS8: - ch &= 0xFF; + ch &= (char) 0xFFU; break; } @@ -310,18 +306,18 @@ parse_ioread( { updated = CVT_OK; } - + if (input_status & PARSE_INP_TIME) /* time sample is available */ { - updated = timepacket(parseio); + updated = (u_int) timepacket(parseio); } - + if (input_status & PARSE_INP_DATA) /* got additional data */ { updated |= CVT_ADDITIONAL; } } - + /* * remember last character time @@ -357,7 +353,7 @@ parse_iopps( register timestamp_t *ptime ) { - register unsigned updated = CVT_NONE; + register u_int updated = CVT_NONE; /* * PPS pulse information will only be delivered to ONE clock format @@ -368,7 +364,7 @@ parse_iopps( if (clockformats[parseio->parse_lformat]->syncpps) { - updated = clockformats[parseio->parse_lformat]->syncpps(parseio, status == SYNC_ONE, ptime); + updated = (u_int) clockformats[parseio->parse_lformat]->syncpps(parseio, status == SYNC_ONE, ptime); parseprintf(DD_PARSE, ("parse_iopps: updated = 0x%x\n", updated)); } @@ -407,13 +403,13 @@ parse_to_unixtime( ) { #define SETRTC(_X_) { if (cvtrtc) *cvtrtc = (_X_); } - static int days_of_month[] = + static int days_of_month[] = { 0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }; register int i; time_t t; - + if (clock_time->utctime) return clock_time->utctime; /* if the conversion routine gets it right away - why not */ @@ -427,12 +423,12 @@ parse_to_unixtime( SETRTC(CVT_FAIL|CVT_BADDATE); return -1; } - + /* * sorry, slow section here - but it's not time critical anyway */ t = julian0(clock_time->year) - julian0(1970); /* Y2kFixes */ - /* month */ + /* month */ if (clock_time->month <= 0 || clock_time->month > 12) { SETRTC(CVT_FAIL|CVT_BADDATE); @@ -470,7 +466,7 @@ parse_to_unixtime( t = TIMES24(t) + clock_time->hour; - /* min */ + /* min */ if (clock_time->minute < 0 || clock_time->minute > 59) { SETRTC(CVT_FAIL|CVT_BADTIME); @@ -479,7 +475,7 @@ parse_to_unixtime( t = TIMES60(t) + clock_time->minute; /* sec */ - + if (clock_time->second < 0 || clock_time->second > 60) /* allow for LEAPs */ { SETRTC(CVT_FAIL|CVT_BADTIME); @@ -514,7 +510,7 @@ Stoi( while(*s == ' ') s++; - + if (*s == '-') { s++; @@ -523,7 +519,7 @@ Stoi( else if (*s == '+') s++; - + for(;;) { c = *s++; @@ -577,16 +573,16 @@ updatetimeinfo( { int s = splhigh(); #endif - + parseio->parse_lstate = parseio->parse_dtime.parse_state | flags | PARSEB_TIMECODE; - + parseio->parse_dtime.parse_state = parseio->parse_lstate; #ifdef PARSEKERNEL (void)splx((unsigned int)s); } #endif - + #ifdef PARSEKERNEL parseprintf(DD_PARSE, ("updatetimeinfo status=0x%x, time=%x\n", parseio->parse_dtime.parse_state, @@ -595,7 +591,7 @@ updatetimeinfo( parseprintf(DD_PARSE, ("updatetimeinfo status=0x%lx, time=%x\n", (long)parseio->parse_dtime.parse_state, parseio->parse_dtime.parse_time.fp.l_ui)); #endif - + return CVT_OK; /* everything fine and dandy... */ } @@ -618,7 +614,7 @@ syn_simple( } /* - * pps_simple + * parse_pps_fnc_t pps_simple * * handle a pps time stamp */ @@ -632,12 +628,12 @@ pps_simple( { parseio->parse_dtime.parse_ptime = *ptime; parseio->parse_dtime.parse_state |= PARSEB_PPS|PARSEB_S_PPS; - + return CVT_NONE; } /* - * pps_one + * parse_pps_fnc_t pps_one * * handle a pps time stamp in ONE edge */ @@ -651,12 +647,12 @@ pps_one( { if (status) return pps_simple(parseio, status, ptime); - + return CVT_NONE; } /* - * pps_zero + * parse_pps_fnc_t pps_zero * * handle a pps time stamp in ZERO edge */ @@ -670,7 +666,7 @@ pps_zero( { if (!status) return pps_simple(parseio, status, ptime); - + return CVT_NONE; } @@ -688,39 +684,39 @@ timepacket( register time_t t; u_long cvtrtc; /* current conversion result */ clocktime_t clock_time; - + memset((char *)&clock_time, 0, sizeof clock_time); format = parseio->parse_lformat; if (format == (unsigned short)~0) return CVT_NONE; - + switch ((cvtrtc = clockformats[format]->convert ? clockformats[format]->convert((unsigned char *)parseio->parse_ldata, parseio->parse_ldsize, (struct format *)(clockformats[format]->data), &clock_time, parseio->parse_pdata) : CVT_NONE) & CVT_MASK) { case CVT_FAIL: parseio->parse_badformat++; - break; - + return cvtrtc; + case CVT_NONE: /* * too bad - pretend bad format */ parseio->parse_badformat++; - break; - + return CVT_NONE; + case CVT_OK: break; - + case CVT_SKIP: return CVT_NONE; default: /* shouldn't happen */ #ifndef PARSEKERNEL - msyslog(LOG_WARNING, "parse: INTERNAL error: bad return code of convert routine \"%s\"\n", clockformats[format]->name); -#endif + msyslog(LOG_WARNING, "parse: INTERNAL error: bad return code of convert routine \"%s\"", clockformats[format]->name); +#endif return CVT_FAIL|cvtrtc; } @@ -728,7 +724,7 @@ timepacket( { return CVT_FAIL|cvtrtc; } - + /* * time stamp */ @@ -736,7 +732,7 @@ timepacket( parseio->parse_dtime.parse_time.tv.tv_sec = t; parseio->parse_dtime.parse_time.tv.tv_usec = clock_time.usecond; #else - parseio->parse_dtime.parse_time.fp.l_ui = t + JAN_1970; + parseio->parse_dtime.parse_time.fp.l_ui = (uint32_t) (t + JAN_1970); TVUTOTSF(clock_time.usecond, parseio->parse_dtime.parse_time.fp.l_uf); #endif @@ -762,7 +758,7 @@ parse_timecode( */ dct->parsegettc.parse_badformat = parse->parse_badformat; parse->parse_badformat = 0; - + if (parse->parse_ldsize <= PARSE_TCMAX) { dct->parsegettc.parse_count = parse->parse_ldsize; @@ -775,7 +771,7 @@ parse_timecode( } } - + /*ARGSUSED*/ int parse_setfmt( @@ -796,7 +792,7 @@ parse_setfmt( if (parse->parse_pdata) FREE(parse->parse_pdata, parse->parse_plen); parse->parse_pdata = 0; - + parse->parse_plen = clockformats[i]->plen; if (parse->parse_plen) @@ -813,9 +809,9 @@ parse_setfmt( if (parse->parse_data) FREE(parse->parse_data, (unsigned)(parse->parse_dsize * 2 + 2)); parse->parse_ldata = parse->parse_data = 0; - + parse->parse_dsize = clockformats[i]->length; - + if (parse->parse_dsize) { parse->parse_data = (char*)MALLOC((unsigned)(parse->parse_dsize * 2 + 2)); @@ -824,20 +820,20 @@ parse_setfmt( if (parse->parse_pdata) FREE(parse->parse_pdata, parse->parse_plen); parse->parse_pdata = 0; - + parseprintf(DD_PARSE, ("init failed: malloc for data area failed\n")); return 0; } } - + /* * leave room for '\0' */ parse->parse_ldata = parse->parse_data + parse->parse_dsize + 1; - + parse->parse_lformat = i; - + return 1; } } @@ -856,7 +852,7 @@ parse_getfmt( if (dct->parseformat.parse_format < nformats && Strlen(clockformats[dct->parseformat.parse_format]->name) <= PARSE_TCMAX) { - dct->parseformat.parse_count = Strlen(clockformats[dct->parseformat.parse_format]->name)+1; + dct->parseformat.parse_count = (unsigned short) (Strlen(clockformats[dct->parseformat.parse_format]->name) + 1); memcpy(dct->parseformat.parse_buffer, clockformats[dct->parseformat.parse_format]->name, dct->parseformat.parse_count); return 1; } @@ -874,7 +870,7 @@ parse_setcs( ) { parse->parse_ioflags &= ~PARSE_IO_CSIZE; - parse->parse_ioflags |= dct->parsesetcs.parse_cs & PARSE_IO_CSIZE; + parse->parse_ioflags |= (int) (dct->parsesetcs.parse_cs & PARSE_IO_CSIZE); return 1; } diff --git a/contrib/ntp/libparse/parse_conf.c b/contrib/ntp/libparse/parse_conf.c index b5451cff1..37871c9de 100644 --- a/contrib/ntp/libparse/parse_conf.c +++ b/contrib/ntp/libparse/parse_conf.c @@ -1,6 +1,6 @@ /* * /src/NTP/ntp4-dev/libparse/parse_conf.c,v 4.9 2005/04/16 17:32:10 kardel RELEASE_20050508_A - * + * * parse_conf.c,v 4.9 2005/04/16 17:32:10 kardel RELEASE_20050508_A * * Parser configuration module for reference clocks @@ -12,7 +12,7 @@ * when STREAM is not defined NTP time stamps will be used. * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -96,6 +96,10 @@ extern clockformat_t clock_wharton_400a; extern clockformat_t clock_varitext; #endif +#ifdef CLOCK_SEL240X +extern clockformat_t clock_sel240x; +#endif + /* * format definitions */ @@ -135,6 +139,9 @@ clockformat_t *clockformats[] = #endif #ifdef CLOCK_VARITEXT &clock_varitext, +#endif +#ifdef CLOCK_SEL240X + &clock_sel240x, #endif 0}; diff --git a/contrib/ntp/libparse/parsesolaris.c b/contrib/ntp/libparse/parsesolaris.c index c023ad84a..8c91257b4 100644 --- a/contrib/ntp/libparse/parsesolaris.c +++ b/contrib/ntp/libparse/parsesolaris.c @@ -1,12 +1,12 @@ /* * /src/NTP/ntp4-dev/libparse/parsesolaris.c,v 4.11 2005/04/16 17:32:10 kardel RELEASE_20050508_A - * + * * parsesolaris.c,v 4.11 2005/04/16 17:32:10 kardel RELEASE_20050508_A * * STREAMS module for reference clocks * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -40,6 +40,7 @@ static char rcsid[] = "parsesolaris.c,v 4.11 2005/04/16 17:32:10 kardel RELEASE_20050508_A"; #endif +#include #include #include #include @@ -73,7 +74,7 @@ static struct fmodsw fmod_templ = extern struct mod_ops mod_strmodops; -static struct modlstrmod modlstrmod = +static struct modlstrmod modlstrmod = { &mod_strmodops, /* a STREAMS module */ "PARSE - NTP reference", /* name this baby - keep room for revision number */ @@ -99,13 +100,13 @@ _init( ) { static char revision[] = "4.6"; - char *s, *S; + char *s, *S; char *t; - + #ifndef lint t = rcsid; #endif - + /* * copy RCS revision into Drv_name * @@ -124,25 +125,25 @@ _init( } if (*s == ' ') s++; } - - t = modlstrmod.strmod_linkinfo; + + t = modlstrmod.strmod_linkinfo; while (*t && (*t != ' ')) { t++; } if (*t == ' ') t++; - + S = s; while (*S && (((*S >= '0') && (*S <= '9')) || (*S == '.'))) { S++; } - + if (*s && *t && (S > s)) { if (strlen(t) >= (S - s)) { - (void) strncpy(t, s, (unsigned)(S - s)); + strlcpy(t, s, (unsigned)(S - s)); } } return (mod_install(&modlinkage)); @@ -173,11 +174,11 @@ _fini( /*--------------- stream module definition ----------------------------*/ -static int parseopen P((queue_t *, dev_t *, int, int, cred_t *)); -static int parseclose P((queue_t *, int)); -static int parsewput P((queue_t *, mblk_t *)); -static int parserput P((queue_t *, mblk_t *)); -static int parsersvc P((queue_t *)); +static int parseopen (queue_t *, dev_t *, int, int, cred_t *); +static int parseclose (queue_t *, int); +static int parsewput (queue_t *, mblk_t *); +static int parserput (queue_t *, mblk_t *); +static int parsersvc (queue_t *); static struct module_info driverinfo = { @@ -244,8 +245,8 @@ int parsedebug = 0; }\ } while (0) -static int init_linemon P((queue_t *)); -static void close_linemon P((queue_t *, queue_t *)); +static int init_linemon (queue_t *); +static void close_linemon (queue_t *, queue_t *); #define M_PARSE 0x0001 #define M_NOPARSE 0x0002 @@ -264,7 +265,7 @@ ntp_memset( static void pprintf( int lev, - const char *form, + char *form, ... ) { @@ -273,7 +274,7 @@ pprintf( va_start(ap, form); if (lev & parsedebug) - vcmn_err(CE_CONT, (char *)form, ap); + vcmn_err(CE_CONT, form, ap); va_end(ap); } @@ -291,7 +292,7 @@ setup_stream( mp = allocb(sizeof(struct stroptions), BPRI_MED); if (mp) { - struct stroptions *str = (struct stroptions *)mp->b_wptr; + struct stroptions *str = (void *)mp->b_wptr; str->so_flags = SO_READOPT|SO_HIWAT|SO_LOWAT|SO_ISNTTY; str->so_readopt = (mode == M_PARSE) ? RMSGD : RNORM; @@ -307,7 +308,7 @@ setup_stream( } else { - pprintf(DD_OPEN, "parse: setup_stream - FAILED - no MEMORY for allocb\n"); + pprintf(DD_OPEN, "parse: setup_stream - FAILED - no MEMORY for allocb\n"); return 0; } } @@ -324,18 +325,18 @@ parseopen( { register parsestream_t *parse; static int notice = 0; - - pprintf(DD_OPEN, "parse: OPEN - q=%x\n", q); - + + pprintf(DD_OPEN, "parse: OPEN - q=%x\n", q); + if (sflag != MODOPEN) { /* open only for modules */ - pprintf(DD_OPEN, "parse: OPEN - FAILED - not MODOPEN\n"); + pprintf(DD_OPEN, "parse: OPEN - FAILED - not MODOPEN\n"); return EIO; } if (q->q_ptr != (caddr_t)NULL) { - pprintf(DD_OPEN, "parse: OPEN - FAILED - EXCLUSIVE ONLY\n"); + pprintf(DD_OPEN, "parse: OPEN - FAILED - EXCLUSIVE ONLY\n"); return EBUSY; } @@ -345,10 +346,10 @@ parseopen( return ENOMEM; } - pprintf(DD_OPEN, "parse: OPEN - parse area q=%x, q->q_ptr=%x\n", q, q->q_ptr); + pprintf(DD_OPEN, "parse: OPEN - parse area q=%x, q->q_ptr=%x\n", q, q->q_ptr); WR(q)->q_ptr = q->q_ptr; - pprintf(DD_OPEN, "parse: OPEN - WQ parse area q=%x, q->q_ptr=%x\n", WR(q), WR(q)->q_ptr); - + pprintf(DD_OPEN, "parse: OPEN - WQ parse area q=%x, q->q_ptr=%x\n", WR(q), WR(q)->q_ptr); + parse = (parsestream_t *) q->q_ptr; bzero((caddr_t)parse, sizeof(*parse)); parse->parse_queue = q; @@ -359,7 +360,7 @@ parseopen( qprocson(q); - pprintf(DD_OPEN, "parse: OPEN - initializing io subsystem q=%x\n", q); + pprintf(DD_OPEN, "parse: OPEN - initializing io subsystem q=%x\n", q); if (!parse_ioinit(&parse->parse_io)) { @@ -373,12 +374,12 @@ parseopen( return EIO; } - pprintf(DD_OPEN, "parse: OPEN - initializing stream q=%x\n", q); + pprintf(DD_OPEN, "parse: OPEN - initializing stream q=%x\n", q); if (setup_stream(q, M_PARSE)) { (void) init_linemon(q); /* hook up PPS ISR routines if possible */ - pprintf(DD_OPEN, "parse: OPEN - SUCCEEDED\n"); + pprintf(DD_OPEN, "parse: OPEN - SUCCEEDED\n"); /* * I know that you know the delete key, but you didn't write this @@ -411,19 +412,19 @@ parseclose( { register parsestream_t *parse = (parsestream_t *)q->q_ptr; register unsigned long s; - + pprintf(DD_CLOSE, "parse: CLOSE\n"); - + qprocsoff(q); s = splhigh(); - + if (parse->parse_dqueue) close_linemon(parse->parse_dqueue, q); parse->parse_dqueue = (queue_t *)0; (void) splx(s); - + parse_ioend(&parse->parse_io); kmem_free((caddr_t)parse, sizeof(parsestream_t)); @@ -443,7 +444,7 @@ parsersvc( ) { mblk_t *mp; - + while ((mp = getq(q))) { if (canputnext(q) || (mp->b_datap->db_type > QPCTL)) @@ -476,17 +477,17 @@ parsewput( register mblk_t *datap; register struct iocblk *iocp; parsestream_t *parse = (parsestream_t *)q->q_ptr; - + pprintf(DD_WPUT, "parse: parsewput\n"); - + switch (mp->b_datap->db_type) { default: putnext(q, mp); break; - + case M_IOCTL: - iocp = (struct iocblk *)mp->b_rptr; + iocp = (void *)mp->b_rptr; switch (iocp->ioc_cmd) { default: @@ -510,14 +511,15 @@ parsewput( } mp->b_cont = datap; - *(struct ppsclockev *)datap->b_wptr = parse->parse_ppsclockev; + /* (void *) quiets cast alignment warning */ + *(struct ppsclockev *)(void *)datap->b_wptr = parse->parse_ppsclockev; datap->b_wptr += sizeof(struct ppsclockev) / sizeof(*datap->b_wptr); mp->b_datap->db_type = M_IOCACK; iocp->ioc_count = sizeof(struct ppsclockev); qreply(q, mp); break; - + case PARSEIOC_ENABLE: case PARSEIOC_DISABLE: { @@ -535,7 +537,7 @@ parsewput( } qreply(q, mp); break; - } + } case PARSEIOC_TIMECODE: case PARSEIOC_SETFMT: @@ -543,7 +545,7 @@ parsewput( case PARSEIOC_SETCS: if (iocp->ioc_count == sizeof(parsectl_t)) { - parsectl_t *dct = (parsectl_t *)mp->b_cont->b_rptr; + parsectl_t *dct = (void *)mp->b_cont->b_rptr; switch (iocp->ioc_cmd) { @@ -551,7 +553,7 @@ parsewput( pprintf(DD_WPUT, "parse: parsewput - PARSEIOC_TIMECODE\n"); ok = parse_timecode(dct, &parse->parse_io); break; - + case PARSEIOC_SETFMT: pprintf(DD_WPUT, "parse: parsewput - PARSEIOC_SETFMT\n"); ok = parse_setfmt(dct, &parse->parse_io); @@ -598,7 +600,7 @@ rdchar( else { register mblk_t *mmp = *mp; - + *mp = (*mp)->b_cont; freeb(mmp); } @@ -617,7 +619,7 @@ parserput( { register unsigned char type; mblk_t *mp = imp; - + switch (type = mp->b_datap->db_type) { default: @@ -634,22 +636,22 @@ parserput( else putq(q, mp); break; - + case M_BREAK: case M_DATA: { register parsestream_t * parse = (parsestream_t *)q->q_ptr; register mblk_t *nmp; register unsigned long ch; - timestamp_t ctime; + timestamp_t c_time; timespec_t hres_time; /* * get time on packet delivery */ gethrestime(&hres_time); - ctime.tv.tv_sec = hres_time.tv_sec; - ctime.tv.tv_usec = hres_time.tv_nsec / 1000; + c_time.tv.tv_sec = hres_time.tv_sec; + c_time.tv.tv_usec = hres_time.tv_nsec / 1000; if (!(parse->parse_status & PARSE_ENABLE)) { @@ -672,7 +674,7 @@ parserput( while (mp != (mblk_t *)NULL) { ch = rdchar(&mp); - if (ch != ~0 && parse_ioread(&parse->parse_io, (unsigned int)ch, &ctime)) + if (ch != ~0 && parse_ioread(&parse->parse_io, (unsigned int)ch, &c_time)) { /* * up up and away (hopefully ...) @@ -689,11 +691,11 @@ parserput( if (nmp) freemsg(nmp); parse_iodone(&parse->parse_io); } - } + } } else { - if (parse_ioread(&parse->parse_io, (unsigned int)0, &ctime)) + if (parse_ioread(&parse->parse_io, (unsigned int)0, &c_time)) { /* * up up and away (hopefully ...) @@ -723,19 +725,19 @@ parserput( case M_UNHANGUP: { register parsestream_t * parse = (parsestream_t *)q->q_ptr; - timestamp_t ctime; + timestamp_t c_time; timespec_t hres_time; register mblk_t *nmp; register int status = cd_invert ^ (type == M_UNHANGUP); gethrestime(&hres_time); - ctime.tv.tv_sec = hres_time.tv_sec; - ctime.tv.tv_usec = hres_time.tv_nsec / 1000; - + c_time.tv.tv_sec = hres_time.tv_sec; + c_time.tv.tv_usec = hres_time.tv_nsec / 1000; + pprintf(DD_RPUT, "parse: parserput - M_%sHANGUP\n", (type == M_HANGUP) ? "" : "UN"); if ((parse->parse_status & PARSE_ENABLE) && - parse_iopps(&parse->parse_io, status ? SYNC_ONE : SYNC_ZERO, &ctime)) + parse_iopps(&parse->parse_io, status ? SYNC_ONE : SYNC_ZERO, &c_time)) { nmp = (mblk_t *)NULL; if (canputnext(parse->parse_queue) && (nmp = allocb(sizeof(parsetime_t), BPRI_MED))) @@ -756,10 +758,10 @@ parserput( } else putq(q, mp); - + if (status) { - parse->parse_ppsclockev.tv = ctime.tv; + parse->parse_ppsclockev.tv = c_time.tv; ++(parse->parse_ppsclockev.serial); } } @@ -767,8 +769,8 @@ parserput( return 0; } -static int init_zs_linemon P((queue_t *, queue_t *)); /* handle line monitor for "zs" driver */ -static void close_zs_linemon P((queue_t *, queue_t *)); +static int init_zs_linemon (queue_t *, queue_t *); /* handle line monitor for "zs" driver */ +static void close_zs_linemon (queue_t *, queue_t *); /*-------------------- CD isr status monitor ---------------*/ @@ -778,7 +780,7 @@ init_linemon( ) { register queue_t *dq; - + dq = WR(q); /* * we ARE doing very bad things down here (basically stealing ISR @@ -849,7 +851,7 @@ close_linemon( #include #include -static void zs_xsisr P((struct zscom *)); /* zs external status interupt handler */ +static void zs_xsisr (struct zscom *); /* zs external status interupt handler */ /* * there should be some docs telling how to get to @@ -911,17 +913,17 @@ init_zs_linemon( parsestream->parse_dqueue = q; /* remember driver */ szs->zsops = *zs->zs_ops; - szs->zsops.zsop_xsint = (void (*) P((struct zscom *)))zs_xsisr; /* place our bastard */ + szs->zsops.zsop_xsint = (void (*) (struct zscom *))zs_xsisr; /* place our bastard */ szs->oldzsops = zs->zs_ops; emergencyzs = zs->zs_ops; - + zs->zs_ops = &szs->zsops; /* hook it up */ /* - * XXX: this is usually done via zsopinit() + * XXX: this is usually done via zsopinit() * - have yet to find a way to call that routine */ - zs->zs_xsint = (void (*) P((struct zscom *)))zs_xsisr; - + zs->zs_xsint = (void (*) (struct zscom *))zs_xsisr; + mutex_exit(zs->zs_excl); pprintf(DD_INSTALL, "init_zs_linemon: CD monitor installed\n"); @@ -932,7 +934,7 @@ init_zs_linemon( } /* - * unregister our ISR routine - must call under splhigh() (or + * unregister our ISR routine - must call under splhigh() (or * whatever block ZS status interrupts) */ static void @@ -968,7 +970,7 @@ close_zs_linemon( mutex_exit(zs->zs_excl); kmem_free((caddr_t)szs, sizeof (struct savedzsops)); - + pprintf(DD_INSTALL, "close_zs_linemon: CD monitor deleted\n"); return; } @@ -986,7 +988,7 @@ zs_xsisr( struct zscom *zs ) { - register struct asyncline *za = (struct asyncline *)zs->zs_priv; + register struct asyncline *za = (void *)zs->zs_priv; register queue_t *q; register unsigned char zsstatus; register int loopcheck; @@ -1003,7 +1005,7 @@ zs_xsisr( { timestamp_t cdevent; register int status; - + /* * time stamp */ @@ -1022,7 +1024,7 @@ zs_xsisr( * ok - now the hard part - find ourself */ loopcheck = MAXDEPTH; - + while (q) { if (q->q_qinfo && q->q_qinfo->qi_minfo) @@ -1050,7 +1052,7 @@ zs_xsisr( */ parse_iodone(&((parsestream_t *)q->q_ptr)->parse_io); } - + if (status) { ((parsestream_t *)q->q_ptr)->parse_ppsclockev.tv = cdevent.tv; @@ -1089,9 +1091,9 @@ zs_xsisr( SCC_WRITE0(ZSWR0_RESET_STATUS); /* might kill other conditions here */ return; } - } + } - pprintf(DD_ISR, "zs_xsisr: non CD event 0x%x for \"%s\"\n", + pprintf(DD_ISR, "zs_xsisr: non CD event 0x%x for \"%s\"\n", (za->za_rr0 ^ zsstatus) & ~ZSRR0_CD,dname); /* * we are now gathered here to process some unusual external status @@ -1106,7 +1108,7 @@ zs_xsisr( q = za->za_ttycommon.t_readq; loopcheck = MAXDEPTH; - + /* * the real thing for everything else ... */ @@ -1117,8 +1119,8 @@ zs_xsisr( dname = q->q_qinfo->qi_minfo->mi_idname; if (!strcmp(dname, parseinfo.st_rdinit->qi_minfo->mi_idname)) { - register void (*zsisr) P((struct zscom *)); - + register void (*zsisr) (struct zscom *); + /* * back home - phew (hopping along stream queues might * prove dangerous to your health) @@ -1127,7 +1129,7 @@ zs_xsisr( zsisr(zs); else panic("zs_xsisr: unable to locate original ISR"); - + pprintf(DD_ISR, "zs_xsisr: non CD event was processed for \"%s\"\n", dname); /* * now back to our program ... @@ -1149,7 +1151,7 @@ zs_xsisr( * corrupted TTY structures */ printf("zs_zsisr: looking for \"%s\" - found \"%s\" - taking EMERGENCY path\n", parseinfo.st_rdinit->qi_minfo->mi_idname, dname ? dname : "-NIL-"); - + if (emergencyzs && emergencyzs->zsop_xsint) emergencyzs->zsop_xsint(zs); else diff --git a/contrib/ntp/libparse/parsestreams.c b/contrib/ntp/libparse/parsestreams.c index 7df354292..6cd9d8ff9 100644 --- a/contrib/ntp/libparse/parsestreams.c +++ b/contrib/ntp/libparse/parsestreams.c @@ -1,13 +1,13 @@ /* * /src/NTP/ntp4-dev/libparse/parsestreams.c,v 4.11 2005/04/16 17:32:10 kardel RELEASE_20050508_A - * + * * parsestreams.c,v 4.11 2005/04/16 17:32:10 kardel RELEASE_20050508_A * * STREAMS module for reference clocks * (SunOS4.x) * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -77,15 +77,15 @@ static char rcsid[] = "parsestreams.c,v 4.11 2005/04/16 17:32:10 kardel RELEASE_ /* * just make checking compilers more silent */ -extern int printf P((const char *, ...)); -extern int putctl1 P((queue_t *, int, int)); -extern int canput P((queue_t *)); -extern void putbq P((queue_t *, mblk_t *)); -extern void freeb P((mblk_t *)); -extern void qreply P((queue_t *, mblk_t *)); -extern void freemsg P((mblk_t *)); -extern void panic P((const char *, ...)); -extern void usec_delay P((int)); +extern int printf (const char *, ...); +extern int putctl1 (queue_t *, int, int); +extern int canput (queue_t *); +extern void putbq (queue_t *, mblk_t *); +extern void freeb (mblk_t *); +extern void qreply (queue_t *, mblk_t *); +extern void freemsg (mblk_t *); +extern void panic (const char *, ...); +extern void usec_delay (int); #include "parse.h" #include "sys/parsestreams.h" @@ -110,7 +110,7 @@ static char mnam[] = "PARSEPPS "; /* name this baby - keep room for revision #else static char mnam[] = "PARSE "; /* name this baby - keep room for revision number */ #endif -struct vdldrv parsesync_vd = +struct vdldrv parsesync_vd = { VDMAGIC_PSEUDO, /* nothing like a real driver - a STREAMS module */ mnam, @@ -166,7 +166,7 @@ Strcmp( while (!(c = *s++ - *t++) && *s && *t) /* empty loop */; - + return c; } @@ -186,10 +186,10 @@ Strncmp( while (n-- && !(c = *s++ - *t++) && *s && *t) /* empty loop */; - + return c; } - + void ntp_memset( char *a, @@ -217,12 +217,12 @@ xxxinit( { extern struct fmodsw fmodsw[]; extern int fmodcnt; - + struct fmodsw *fm = fmodsw; struct fmodsw *fmend = &fmodsw[fmodcnt]; struct fmodsw *ifm = (struct fmodsw *)0; char *mname = parseinfo.st_rdinit->qi_minfo->mi_idname; - + switch (fc) { case VDLOAD: @@ -233,13 +233,13 @@ xxxinit( */ while (fm <= fmend) { - if (!Strncmp(fm->f_name, mname, FMNAMESZ)) + if (!Strncmp(fm->f_name, mname, FMNAMESZ)) { printf("vddrinit[%s]: STREAMS module already loaded.\n", mname); return(EBUSY); } else - if ((ifm == (struct fmodsw *)0) && + if ((ifm == (struct fmodsw *)0) && (fm->f_name[0] == '\0') && (fm->f_str == (struct streamtab *)0)) { @@ -261,7 +261,7 @@ xxxinit( { static char revision[] = "4.7"; char *s, *S, *t; - + s = rcsid; /* NOOP - keep compilers happy */ Strncpy(ifm->f_name, mname, FMNAMESZ); @@ -285,20 +285,20 @@ xxxinit( } if (*s == ' ') s++; } - - t = parsesync_vd.Drv_name; + + t = parsesync_vd.Drv_name; while (*t && (*t != ' ')) { t++; } if (*t == ' ') t++; - + S = s; while (*S && (((*S >= '0') && (*S <= '9')) || (*S == '.'))) { S++; } - + if (*s && *t && (S > s)) { if (Strlen(t) >= (S - s)) @@ -307,9 +307,9 @@ xxxinit( } } return (0); - } + } break; - + case VDUNLOAD: if (parsebusy > 0) { @@ -328,7 +328,7 @@ xxxinit( fm->f_name[0] = '\0'; fm->f_str = (struct streamtab *)0; fm++; - + break; } fm++; @@ -341,14 +341,14 @@ xxxinit( else return (0); } - + case VDSTAT: return (0); default: return (EIO); - + } return EIO; } @@ -357,11 +357,11 @@ xxxinit( /*--------------- stream module definition ----------------------------*/ -static int parseopen P((queue_t *, dev_t, int, int)); -static int parseclose P((queue_t *, int)); -static int parsewput P((queue_t *, mblk_t *)); -static int parserput P((queue_t *, mblk_t *)); -static int parsersvc P((queue_t *)); +static int parseopen (queue_t *, dev_t, int, int); +static int parseclose (queue_t *, int); +static int parsewput (queue_t *, mblk_t *); +static int parserput (queue_t *, mblk_t *); +static int parsersvc (queue_t *); static char mn[] = "parse"; @@ -416,7 +416,7 @@ int cd_invert = 1; /* invert status of CD line - PPS support via CD input */ int parsedebug = ~0; -extern void uniqtime P((struct timeval *)); +extern void uniqtime (struct timeval *); /*--------------- module implementation -----------------------------*/ @@ -429,8 +429,8 @@ extern void uniqtime P((struct timeval *)); }\ } while (0) -static int init_linemon P((queue_t *)); -static void close_linemon P((queue_t *, queue_t *)); +static int init_linemon (queue_t *); +static void close_linemon (queue_t *, queue_t *); #define M_PARSE 0x0001 #define M_NOPARSE 0x0002 @@ -460,7 +460,7 @@ setup_stream( } else { - parseprintf(DD_OPEN,("parse: setup_stream - FAILED - no MEMORY for allocb\n")); + parseprintf(DD_OPEN,("parse: setup_stream - FAILED - no MEMORY for allocb\n")); return 0; } } @@ -476,37 +476,37 @@ parseopen( { register parsestream_t *parse; static int notice = 0; - - parseprintf(DD_OPEN,("parse: OPEN\n")); - + + parseprintf(DD_OPEN,("parse: OPEN\n")); + if (sflag != MODOPEN) { /* open only for modules */ - parseprintf(DD_OPEN,("parse: OPEN - FAILED - not MODOPEN\n")); + parseprintf(DD_OPEN,("parse: OPEN - FAILED - not MODOPEN\n")); return OPENFAIL; } if (q->q_ptr != (caddr_t)NULL) { u.u_error = EBUSY; - parseprintf(DD_OPEN,("parse: OPEN - FAILED - EXCLUSIVE ONLY\n")); + parseprintf(DD_OPEN,("parse: OPEN - FAILED - EXCLUSIVE ONLY\n")); return OPENFAIL; } #ifdef VDDRV parsebusy++; #endif - + q->q_ptr = (caddr_t)kmem_alloc(sizeof(parsestream_t)); if (q->q_ptr == (caddr_t)0) { - parseprintf(DD_OPEN,("parse: OPEN - FAILED - no memory\n")); + parseprintf(DD_OPEN,("parse: OPEN - FAILED - no memory\n")); #ifdef VDDRV parsebusy--; #endif return OPENFAIL; } WR(q)->q_ptr = q->q_ptr; - + parse = (parsestream_t *)(void *)q->q_ptr; bzero((caddr_t)parse, sizeof(*parse)); parse->parse_queue = q; @@ -531,7 +531,7 @@ parseopen( { (void) init_linemon(q); /* hook up PPS ISR routines if possible */ - parseprintf(DD_OPEN,("parse: OPEN - SUCCEEDED\n")); + parseprintf(DD_OPEN,("parse: OPEN - SUCCEEDED\n")); /* * I know that you know the delete key, but you didn't write this @@ -569,17 +569,17 @@ parseclose( { register parsestream_t *parse = (parsestream_t *)(void *)q->q_ptr; register unsigned long s; - + parseprintf(DD_CLOSE,("parse: CLOSE\n")); - + s = splhigh(); - + if (parse->parse_dqueue) close_linemon(parse->parse_dqueue, q); parse->parse_dqueue = (queue_t *)0; (void) splx(s); - + parse_ioend(&parse->parse_io); kmem_free((caddr_t)parse, sizeof(parsestream_t)); @@ -602,7 +602,7 @@ parsersvc( ) { mblk_t *mp; - + while ((mp = getq(q))) { if (canput(q->q_next) || (mp->b_datap->db_type > QPCTL)) @@ -635,15 +635,15 @@ parsewput( register mblk_t *datap; register struct iocblk *iocp; parsestream_t *parse = (parsestream_t *)(void *)q->q_ptr; - + parseprintf(DD_WPUT,("parse: parsewput\n")); - + switch (mp->b_datap->db_type) { default: putnext(q, mp); break; - + case M_IOCTL: iocp = (struct iocblk *)(void *)mp->b_rptr; switch (iocp->ioc_cmd) @@ -676,7 +676,7 @@ parsewput( iocp->ioc_count = sizeof(struct ppsclockev); qreply(q, mp); break; - + case PARSEIOC_ENABLE: case PARSEIOC_DISABLE: { @@ -694,7 +694,7 @@ parsewput( } qreply(q, mp); break; - } + } case PARSEIOC_TIMECODE: case PARSEIOC_SETFMT: @@ -710,7 +710,7 @@ parsewput( parseprintf(DD_WPUT,("parse: parsewput - PARSEIOC_TIMECODE\n")); ok = parse_timecode(dct, &parse->parse_io); break; - + case PARSEIOC_SETFMT: parseprintf(DD_WPUT,("parse: parsewput - PARSEIOC_SETFMT\n")); ok = parse_setfmt(dct, &parse->parse_io); @@ -757,7 +757,7 @@ rdchar( else { register mblk_t *mmp = *mp; - + *mp = (*mp)->b_cont; freeb(mmp); } @@ -775,7 +775,7 @@ parserput( ) { unsigned char type; - + switch (type = mp->b_datap->db_type) { default: @@ -791,7 +791,7 @@ parserput( else putq(q, mp); break; - + case M_BREAK: case M_DATA: { @@ -844,7 +844,7 @@ parserput( if (nmp) freemsg(nmp); parse_iodone(&parse->parse_io); } - } + } } else { @@ -883,7 +883,7 @@ parserput( register int status = cd_invert ^ (type == M_UNHANGUP); uniqtime(&ctime.tv); - + parseprintf(DD_RPUT,("parse: parserput - M_%sHANGUP\n", (type == M_HANGUP) ? "" : "UN")); if ((parse->parse_status & PARSE_ENABLE) && @@ -908,7 +908,7 @@ parserput( } else putq(q, mp); - + if (status) { parse->parse_ppsclockev.tv = ctime.tv; @@ -919,8 +919,8 @@ parserput( return 0; } -static int init_zs_linemon P((queue_t *, queue_t *)); /* handle line monitor for "zs" driver */ -static void close_zs_linemon P((queue_t *, queue_t *)); +static int init_zs_linemon (queue_t *, queue_t *); /* handle line monitor for "zs" driver */ +static void close_zs_linemon (queue_t *, queue_t *); /*-------------------- CD isr status monitor ---------------*/ @@ -930,7 +930,7 @@ init_linemon( ) { register queue_t *dq; - + dq = WR(q); /* * we ARE doing very bad things down here (basically stealing ISR @@ -1010,8 +1010,8 @@ struct savedzsops }; struct zsops *emergencyzs; -extern void zsopinit P((struct zscom *, struct zsops *)); -static int zs_xsisr P((struct zscom *)); /* zs external status interupt handler */ +extern void zsopinit (struct zscom *, struct zsops *); +static int zs_xsisr (struct zscom *); /* zs external status interupt handler */ static int init_zs_linemon( @@ -1038,7 +1038,7 @@ init_zs_linemon( else { unsigned long s; - + /* * we do a direct replacement, in case others fiddle also * if somebody else grabs our hook and we disconnect @@ -1064,9 +1064,9 @@ init_zs_linemon( szs->zsops.zsop_xsint = zs_xsisr; /* place our bastard */ szs->oldzsops = zs->zs_ops; emergencyzs = zs->zs_ops; - + zsopinit(zs, &szs->zsops); /* hook it up */ - + (void) splx(s); parseprintf(DD_INSTALL, ("init_zs_linemon: CD monitor installed\n")); @@ -1099,11 +1099,11 @@ close_zs_linemon( else { register struct savedzsops *szs = (struct savedzsops *)parsestream->parse_data; - + zsopinit(zs, szs->oldzsops); /* reset to previous handler functions */ kmem_free((caddr_t)szs, sizeof (struct savedzsops)); - + parseprintf(DD_INSTALL, ("close_zs_linemon: CD monitor deleted\n")); return; } @@ -1112,7 +1112,7 @@ close_zs_linemon( #define MAXDEPTH 50 /* maximum allowed stream crawl */ #ifdef PPS_SYNC -extern void hardpps P((struct timeval *, long)); +extern void hardpps (struct timeval *, long); #ifdef PPS_NEW extern struct timeval timestamp; #else @@ -1148,7 +1148,7 @@ zs_xsisr( { timestamp_t cdevent; register int status; - + za->za_rr0 = (za->za_rr0 & ~(cdmask)) | (zsstatus & (cdmask)); #ifdef PPS_SYNC @@ -1163,7 +1163,7 @@ zs_xsisr( * time stamp */ uniqtime(&cdevent.tv); - + #ifdef PPS_SYNC (void)splx(s); #endif @@ -1190,7 +1190,7 @@ zs_xsisr( * ok - now the hard part - find ourself */ loopcheck = MAXDEPTH; - + while (q) { if (q->q_qinfo && q->q_qinfo->qi_minfo) @@ -1218,7 +1218,7 @@ zs_xsisr( */ parse_iodone(&((parsestream_t *)(void *)q->q_ptr)->parse_io); } - + if (status) { ((parsestream_t *)(void *)q->q_ptr)->parse_ppsclockev.tv = cdevent.tv; @@ -1251,13 +1251,13 @@ zs_xsisr( zsaddr->zscc_control = ZSWR0_RESET_STATUS; /* might kill other conditions here */ return 0; } - } + } if (zsstatus & cdmask) /* fake CARRIER status */ za->za_flags |= ZAS_CARR_ON; else za->za_flags &= ~ZAS_CARR_ON; - + /* * we are now gathered here to process some unusual external status * interrupts. @@ -1271,7 +1271,7 @@ zs_xsisr( q = za->za_ttycommon.t_readq; loopcheck = MAXDEPTH; - + /* * the real thing for everything else ... */ @@ -1282,8 +1282,8 @@ zs_xsisr( dname = q->q_qinfo->qi_minfo->mi_idname; if (!Strcmp(dname, parseinfo.st_rdinit->qi_minfo->mi_idname)) { - register int (*zsisr) P((struct zscom *)); - + register int (*zsisr) (struct zscom *); + /* * back home - phew (hopping along stream queues might * prove dangerous to your health) @@ -1292,7 +1292,7 @@ zs_xsisr( return zsisr(zs); else panic("zs_xsisr: unable to locate original ISR"); - + parseprintf(DD_ISR, ("zs_xsisr: non CD event was processed for \"%s\"\n", dname)); /* * now back to our program ... @@ -1314,7 +1314,7 @@ zs_xsisr( * corrupted TTY structures */ printf("zs_zsisr: looking for \"%s\" - found \"%s\" - taking EMERGENCY path\n", parseinfo.st_rdinit->qi_minfo->mi_idname, dname ? dname : "-NIL-"); - + if (emergencyzs && emergencyzs->zsop_xsint) emergencyzs->zsop_xsint(zs); else diff --git a/contrib/ntp/libparse/trim_info.c b/contrib/ntp/libparse/trim_info.c index 8fdc4f61e..4178209e5 100644 --- a/contrib/ntp/libparse/trim_info.c +++ b/contrib/ntp/libparse/trim_info.c @@ -6,7 +6,7 @@ * $Created: Sun Aug 2 20:20:34 1998 $ * * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -33,6 +33,7 @@ * SUCH DAMAGE. * */ +#include #include "ntp_types.h" #include "trimble.h" diff --git a/contrib/ntp/ltmain.sh b/contrib/ntp/ltmain.sh index 06823e057..3061e3c5a 100644 --- a/contrib/ntp/ltmain.sh +++ b/contrib/ntp/ltmain.sh @@ -1,30 +1,129 @@ -# ltmain.sh - Provide generalized library-building support services. -# NOTE: Changing this file will not affect anything until you rerun configure. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005 -# Free Software Foundation, Inc. -# Originally by Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify + +# libtool (GNU libtool) 2.4 +# Written by Gordon Matzigkeit , 1996 + +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, +# 2007, 2008, 2009, 2010 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # -# This program is distributed in the hope that it will be useful, but +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, +# or obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +# Usage: $progname [OPTION]... [MODE-ARG]... +# +# Provide generalized library-building support services. # -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. +# --config show all configuration variables +# --debug enable verbose shell tracing +# -n, --dry-run display commands without modifying any files +# --features display basic configuration information and exit +# --mode=MODE use operation mode MODE +# --preserve-dup-deps don't remove duplicate dependency libraries +# --quiet, --silent don't print informational messages +# --no-quiet, --no-silent +# print informational messages (default) +# --tag=TAG use configuration variables from tag TAG +# -v, --verbose print more informational messages than default +# --no-verbose don't print the extra informational messages +# --version print version information +# -h, --help, --help-all print short, long, or detailed help message +# +# MODE must be one of the following: +# +# clean remove files from the build directory +# compile compile a source file into a libtool object +# execute automatically set library path, then run a program +# finish complete the installation of libtool libraries +# install install libraries or executables +# link create a library or an executable +# uninstall remove libraries from an installed directory +# +# MODE-ARGS vary depending on the MODE. When passed as first option, +# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that. +# Try `$progname --help --mode=MODE' for a more detailed description of MODE. +# +# When reporting a bug, please describe a test case to reproduce it and +# include the following information: +# +# host-triplet: $host +# shell: $SHELL +# compiler: $LTCC +# compiler flags: $LTCFLAGS +# linker: $LD (gnu? $with_gnu_ld) +# $progname: (GNU libtool) 2.4 +# automake: $automake_version +# autoconf: $autoconf_version +# +# Report bugs to . +# GNU libtool home page: . +# General help using GNU software: . + +PROGRAM=libtool +PACKAGE=libtool +VERSION=2.4 +TIMESTAMP="" +package_revision=1.3293 + +# Be Bourne compatible +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' +} + +# NLS nuisances: We save the old values to restore during execute mode. +lt_user_locale= +lt_safe_locale= +for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES +do + eval "if test \"\${$lt_var+set}\" = set; then + save_$lt_var=\$$lt_var + $lt_var=C + export $lt_var + lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\" + lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" + fi" +done +LC_ALL=C +LANGUAGE=C +export LANGUAGE LC_ALL + +$lt_unset CDPATH -basename="s,^.*/,,g" # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh # is ksh but when the shell is invoked as "sh" and the current value of @@ -33,113 +132,427 @@ basename="s,^.*/,,g" # function. progpath="$0" -# The name of this program: -progname=`echo "$progpath" | $SED $basename` -modename="$progname" + + +: ${CP="cp -f"} +test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'} +: ${EGREP="grep -E"} +: ${FGREP="grep -F"} +: ${GREP="grep"} +: ${LN_S="ln -s"} +: ${MAKE="make"} +: ${MKDIR="mkdir"} +: ${MV="mv -f"} +: ${RM="rm -f"} +: ${SED="sed"} +: ${SHELL="${CONFIG_SHELL-/bin/sh}"} +: ${Xsed="$SED -e 1s/^X//"} # Global variables: EXIT_SUCCESS=0 EXIT_FAILURE=1 +EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. +EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. -PROGRAM=ltmain.sh -PACKAGE=libtool -VERSION=1.5.22 -TIMESTAMP=" (1.1220.2.365 2005/12/18 22:14:06)" +exit_status=$EXIT_SUCCESS -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes. -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi +# Make sure IFS has a sensible default +lt_nl=' +' +IFS=" $lt_nl" -# Check that we have a working $echo. -if test "X$1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X$1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then - # Yippee, $echo works! - : -else - # Restart under the correct shell, and then maybe $echo will work. - exec $SHELL "$progpath" --no-reexec ${1+"$@"} -fi +dirname="s,/[^/]*$,," +basename="s,^.*/,," -if test "X$1" = X--fallback-echo; then - # used as fallback echo - shift - cat <&2 - $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 - exit $EXIT_FAILURE -fi +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + +# func_error arg... +# Echo program name prefixed message to standard error. +func_error () +{ + $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2 +} + +# func_warning arg... +# Echo program name prefixed warning message to standard error. +func_warning () +{ + $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 + + # bash bug again: + : +} + +# func_fatal_error arg... +# Echo program name prefixed message to standard error, and exit. +func_fatal_error () +{ + func_error ${1+"$@"} + exit $EXIT_FAILURE +} + +# func_fatal_help arg... +# Echo program name prefixed message to standard error, followed by +# a help hint, and exit. +func_fatal_help () +{ + func_error ${1+"$@"} + func_fatal_error "$help" +} +help="Try \`$progname --help' for more information." ## default -# Global variables. -mode=$default_mode -nonopt= -prev= -prevopt= -run= -show="$echo" -show_help= -execute_dlfiles= -duplicate_deps=no -preserve_args= -lo2o="s/\\.lo\$/.${objext}/" -o2lo="s/\\.${objext}\$/.lo/" -##################################### -# Shell function definitions: -# This seems to be the best place for them +# func_grep expression filename +# Check whether EXPRESSION matches any line of FILENAME, without output. +func_grep () +{ + $GREP "$1" "$2" >/dev/null 2>&1 +} + + +# func_mkdir_p directory-path +# Make sure the entire path to DIRECTORY-PATH is available. +func_mkdir_p () +{ + my_directory_path="$1" + my_dir_list= + + if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then + + # Protect directory names starting with `-' + case $my_directory_path in + -*) my_directory_path="./$my_directory_path" ;; + esac + + # While some portion of DIR does not yet exist... + while test ! -d "$my_directory_path"; do + # ...make a list in topmost first order. Use a colon delimited + # list incase some portion of path contains whitespace. + my_dir_list="$my_directory_path:$my_dir_list" + + # If the last portion added has no slash in it, the list is done + case $my_directory_path in */*) ;; *) break ;; esac + + # ...otherwise throw away the child directory and loop + my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"` + done + my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'` + + save_mkdir_p_IFS="$IFS"; IFS=':' + for my_dir in $my_dir_list; do + IFS="$save_mkdir_p_IFS" + # mkdir can fail with a `File exist' error if two processes + # try to create one of the directories concurrently. Don't + # stop in that case! + $MKDIR "$my_dir" 2>/dev/null || : + done + IFS="$save_mkdir_p_IFS" + + # Bail out if we (or some other process) failed to create a directory. + test -d "$my_directory_path" || \ + func_fatal_error "Failed to create \`$1'" + fi +} + # func_mktempdir [string] # Make a temporary directory that won't clash with other running @@ -149,7 +562,7 @@ func_mktempdir () { my_template="${TMPDIR-/tmp}/${1-$progname}" - if test "$run" = ":"; then + if test "$opt_dry_run" = ":"; then # Return a directory name, but don't create it in dry-run mode my_tmpdir="${my_template}-$$" else @@ -158,4758 +571,3642 @@ func_mktempdir () my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` if test ! -d "$my_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - my_tmpdir="${my_template}-${RANDOM-0}$$" + # Failing that, at least try and use $RANDOM to avoid a race + my_tmpdir="${my_template}-${RANDOM-0}$$" - save_mktempdir_umask=`umask` - umask 0077 - $mkdir "$my_tmpdir" - umask $save_mktempdir_umask + save_mktempdir_umask=`umask` + umask 0077 + $MKDIR "$my_tmpdir" + umask $save_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure - test -d "$my_tmpdir" || { - $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2 - exit $EXIT_FAILURE - } + test -d "$my_tmpdir" || \ + func_fatal_error "cannot create temporary directory \`$my_tmpdir'" fi - $echo "X$my_tmpdir" | $Xsed + $ECHO "$my_tmpdir" } -# func_win32_libid arg -# return the library type of file 'arg' -# -# Need a lot of goo to handle *both* DLLs and import libs -# Has to be a shell function in order to 'eat' the argument -# that is supplied when $file_magic_command is called. -func_win32_libid () +# func_quote_for_eval arg +# Aesthetically quote ARG to be evaled later. +# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT +# is double-quoted, suitable for a subsequent eval, whereas +# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters +# which are still active within double quotes backslashified. +func_quote_for_eval () { - win32_libid_type="unknown" - win32_fileres=`file -L $1 2>/dev/null` - case $win32_fileres in - *ar\ archive\ import\ library*) # definitely import - win32_libid_type="x86 archive import" - ;; - *ar\ archive*) # could be an import, or static - if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \ - $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then - win32_nmres=`eval $NM -f posix -A $1 | \ - $SED -n -e '1,100{/ I /{s,.*,import,;p;q;};}'` - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac - fi - ;; - *DLL*) - win32_libid_type="x86 DLL" - ;; - *executable*) # but shell scripts are "executable" too... - case $win32_fileres in - *MS\ Windows\ PE\ Intel*) - win32_libid_type="x86 DLL" - ;; + case $1 in + *[\\\`\"\$]*) + func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;; + *) + func_quote_for_eval_unquoted_result="$1" ;; + esac + + case $func_quote_for_eval_unquoted_result in + # Double-quote args containing shell metacharacters to delay + # word splitting, command substitution and and variable + # expansion for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\"" + ;; + *) + func_quote_for_eval_result="$func_quote_for_eval_unquoted_result" esac - ;; - esac - $echo $win32_libid_type } -# func_infer_tag arg -# Infer tagged configuration to use if any are available and -# if one wasn't chosen via the "--tag" command line option. -# Only attempt this if the compiler in the base compile -# command doesn't match the default compiler. -# arg is usually of the form 'gcc ...' -func_infer_tag () +# func_quote_for_expand arg +# Aesthetically quote ARG to be evaled later; same as above, +# but do not quote variable references. +func_quote_for_expand () { - if test -n "$available_tags" && test -z "$tagname"; then - CC_quoted= - for arg in $CC; do - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac - CC_quoted="$CC_quoted $arg" - done - case $@ in - # Blanks in the command may have been stripped by the calling shell, - # but not from the CC environment variable when configure was run. - " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) ;; - # Blanks at the start of $base_compile will cause this to fail - # if we don't check for them as well. + case $1 in + *[\\\`\"]*) + my_arg=`$ECHO "$1" | $SED \ + -e "$double_quote_subst" -e "$sed_double_backslash"` ;; *) - for z in $available_tags; do - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then - # Evaluate the configuration. - eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" - CC_quoted= - for arg in $CC; do - # Double-quote args containing other shell metacharacters. - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac - CC_quoted="$CC_quoted $arg" - done - case "$@ " in - " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) - # The compiler in the base compile command matches - # the one in the tagged configuration. - # Assume this is the tagged configuration we want. - tagname=$z - break - ;; - esac - fi - done - # If $tagname still isn't set, then no tagged configuration - # was found and let the user know that the "--tag" command - # line option must be used. - if test -z "$tagname"; then - $echo "$modename: unable to infer tagged configuration" - $echo "$modename: specify a tag with \`--tag'" 1>&2 - exit $EXIT_FAILURE -# else -# $echo "$modename: using $tagname tagged configuration" - fi - ;; - esac + my_arg="$1" ;; + esac + + case $my_arg in + # Double-quote args containing shell metacharacters to delay + # word splitting and command substitution for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + my_arg="\"$my_arg\"" + ;; + esac + + func_quote_for_expand_result="$my_arg" +} + + +# func_show_eval cmd [fail_exp] +# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. +func_show_eval () +{ + my_cmd="$1" + my_fail_exp="${2-:}" + + ${opt_silent-false} || { + func_quote_for_expand "$my_cmd" + eval "func_echo $func_quote_for_expand_result" + } + + if ${opt_dry_run-false}; then :; else + eval "$my_cmd" + my_status=$? + if test "$my_status" -eq 0; then :; else + eval "(exit $my_status); $my_fail_exp" + fi fi } -# func_extract_an_archive dir oldlib -func_extract_an_archive () +# func_show_eval_locale cmd [fail_exp] +# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. Use the saved locale for evaluation. +func_show_eval_locale () { - f_ex_an_ar_dir="$1"; shift - f_ex_an_ar_oldlib="$1" + my_cmd="$1" + my_fail_exp="${2-:}" - $show "(cd $f_ex_an_ar_dir && $AR x $f_ex_an_ar_oldlib)" - $run eval "(cd \$f_ex_an_ar_dir && $AR x \$f_ex_an_ar_oldlib)" || exit $? - if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then - : - else - $echo "$modename: ERROR: object name conflicts: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" 1>&2 - exit $EXIT_FAILURE + ${opt_silent-false} || { + func_quote_for_expand "$my_cmd" + eval "func_echo $func_quote_for_expand_result" + } + + if ${opt_dry_run-false}; then :; else + eval "$lt_user_locale + $my_cmd" + my_status=$? + eval "$lt_safe_locale" + if test "$my_status" -eq 0; then :; else + eval "(exit $my_status); $my_fail_exp" + fi fi } -# func_extract_archives gentop oldlib ... -func_extract_archives () +# func_tr_sh +# Turn $1 into a string suitable for a shell variable name. +# Result is stored in $func_tr_sh_result. All characters +# not in the set a-zA-Z0-9_ are replaced with '_'. Further, +# if $1 begins with a digit, a '_' is prepended as well. +func_tr_sh () { - my_gentop="$1"; shift - my_oldlibs=${1+"$@"} - my_oldobjs="" - my_xlib="" - my_xabs="" - my_xdir="" - my_status="" - - $show "${rm}r $my_gentop" - $run ${rm}r "$my_gentop" - $show "$mkdir $my_gentop" - $run $mkdir "$my_gentop" - my_status=$? - if test "$my_status" -ne 0 && test ! -d "$my_gentop"; then - exit $my_status - fi - - for my_xlib in $my_oldlibs; do - # Extract the objects. - case $my_xlib in - [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; - *) my_xabs=`pwd`"/$my_xlib" ;; - esac - my_xlib=`$echo "X$my_xlib" | $Xsed -e 's%^.*/%%'` - my_xdir="$my_gentop/$my_xlib" - - $show "${rm}r $my_xdir" - $run ${rm}r "$my_xdir" - $show "$mkdir $my_xdir" - $run $mkdir "$my_xdir" - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then - exit $exit_status - fi - case $host in - *-darwin*) - $show "Extracting $my_xabs" - # Do not bother doing anything if just a dry run - if test -z "$run"; then - darwin_orig_dir=`pwd` - cd $my_xdir || exit $? - darwin_archive=$my_xabs - darwin_curdir=`pwd` - darwin_base_archive=`$echo "X$darwin_archive" | $Xsed -e 's%^.*/%%'` - darwin_arches=`lipo -info "$darwin_archive" 2>/dev/null | $EGREP Architectures 2>/dev/null` - if test -n "$darwin_arches"; then - darwin_arches=`echo "$darwin_arches" | $SED -e 's/.*are://'` - darwin_arch= - $show "$darwin_base_archive has multiple architectures $darwin_arches" - for darwin_arch in $darwin_arches ; do - mkdir -p "unfat-$$/${darwin_base_archive}-${darwin_arch}" - lipo -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" - cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" - func_extract_an_archive "`pwd`" "${darwin_base_archive}" - cd "$darwin_curdir" - $rm "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" - done # $darwin_arches - ## Okay now we have a bunch of thin objects, gotta fatten them up :) - darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print| xargs basename | sort -u | $NL2SP` - darwin_file= - darwin_files= - for darwin_file in $darwin_filelist; do - darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP` - lipo -create -output "$darwin_file" $darwin_files - done # $darwin_filelist - ${rm}r unfat-$$ - cd "$darwin_orig_dir" - else - cd "$darwin_orig_dir" - func_extract_an_archive "$my_xdir" "$my_xabs" - fi # $darwin_arches - fi # $run - ;; - *) - func_extract_an_archive "$my_xdir" "$my_xabs" - ;; - esac - my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` - done - func_extract_archives_result="$my_oldobjs" -} -# End of Shell function definitions -##################################### - -# Darwin sucks -eval std_shrext=\"$shrext_cmds\" - -disable_libs=no - -# Parse our command line options once, thoroughly. -while test "$#" -gt 0 -do - arg="$1" - shift - - case $arg in - -*=*) optarg=`$echo "X$arg" | $Xsed -e 's/[-_a-zA-Z0-9]*=//'` ;; - *) optarg= ;; + case $1 in + [0-9]* | *[!a-zA-Z0-9_]*) + func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` + ;; + * ) + func_tr_sh_result=$1 + ;; esac +} - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - case $prev in - execute_dlfiles) - execute_dlfiles="$execute_dlfiles $arg" - ;; - tag) - tagname="$arg" - preserve_args="${preserve_args}=$arg" - - # Check whether tagname contains only valid characters - case $tagname in - *[!-_A-Za-z0-9,/]*) - $echo "$progname: invalid tag name: $tagname" 1>&2 - exit $EXIT_FAILURE - ;; - esac - case $tagname in - CC) - # Don't test for the "default" C tag, as we know, it's there, but - # not specially marked. - ;; - *) - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "$progpath" > /dev/null; then - taglist="$taglist $tagname" - # Evaluate the configuration. - eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$tagname'$/,/^# ### END LIBTOOL TAG CONFIG: '$tagname'$/p' < $progpath`" - else - $echo "$progname: ignoring unknown tag $tagname" 1>&2 - fi - ;; - esac - ;; - *) - eval "$prev=\$arg" - ;; - esac +# func_version +# Echo version message to standard output and exit. +func_version () +{ + $opt_debug + + $SED -n '/(C)/!b go + :more + /\./!{ + N + s/\n# / / + b more + } + :go + /^# '$PROGRAM' (GNU /,/# warranty; / { + s/^# // + s/^# *$// + s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ + p + }' < "$progpath" + exit $? +} - prev= - prevopt= - continue - fi +# func_usage +# Echo short help message to standard output and exit. +func_usage () +{ + $opt_debug + + $SED -n '/^# Usage:/,/^# *.*--help/ { + s/^# // + s/^# *$// + s/\$progname/'$progname'/ + p + }' < "$progpath" + echo + $ECHO "run \`$progname --help | more' for full usage" + exit $? +} - # Have we seen a non-optional argument yet? - case $arg in - --help) - show_help=yes - ;; +# func_help [NOEXIT] +# Echo long help message to standard output and exit, +# unless 'noexit' is passed as argument. +func_help () +{ + $opt_debug + + $SED -n '/^# Usage:/,/# Report bugs to/ { + :print + s/^# // + s/^# *$// + s*\$progname*'$progname'* + s*\$host*'"$host"'* + s*\$SHELL*'"$SHELL"'* + s*\$LTCC*'"$LTCC"'* + s*\$LTCFLAGS*'"$LTCFLAGS"'* + s*\$LD*'"$LD"'* + s/\$with_gnu_ld/'"$with_gnu_ld"'/ + s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/ + s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/ + p + d + } + /^# .* home page:/b print + /^# General help using/b print + ' < "$progpath" + ret=$? + if test -z "$1"; then + exit $ret + fi +} - --version) - $echo "$PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP" - $echo - $echo "Copyright (C) 2005 Free Software Foundation, Inc." - $echo "This is free software; see the source for copying conditions. There is NO" - $echo "warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - exit $? - ;; +# func_missing_arg argname +# Echo program name prefixed message to standard error and set global +# exit_cmd. +func_missing_arg () +{ + $opt_debug - --config) - ${SED} -e '1,/^# ### BEGIN LIBTOOL CONFIG/d' -e '/^# ### END LIBTOOL CONFIG/,$d' $progpath - # Now print the configurations for the tags. - for tagname in $taglist; do - ${SED} -n -e "/^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$/,/^# ### END LIBTOOL TAG CONFIG: $tagname$/p" < "$progpath" - done - exit $? - ;; + func_error "missing argument for $1." + exit_cmd=exit +} - --debug) - $echo "$progname: enabling shell trace mode" - set -x - preserve_args="$preserve_args $arg" - ;; - --dry-run | -n) - run=: - ;; +# func_split_short_opt shortopt +# Set func_split_short_opt_name and func_split_short_opt_arg shell +# variables after splitting SHORTOPT after the 2nd character. +func_split_short_opt () +{ + my_sed_short_opt='1s/^\(..\).*$/\1/;q' + my_sed_short_rest='1s/^..\(.*\)$/\1/;q' - --features) - $echo "host: $host" - if test "$build_libtool_libs" = yes; then - $echo "enable shared libraries" - else - $echo "disable shared libraries" - fi - if test "$build_old_libs" = yes; then - $echo "enable static libraries" - else - $echo "disable static libraries" - fi - exit $? - ;; + func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` + func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` +} # func_split_short_opt may be replaced by extended shell implementation - --finish) mode="finish" ;; - --mode) prevopt="--mode" prev=mode ;; - --mode=*) mode="$optarg" ;; +# func_split_long_opt longopt +# Set func_split_long_opt_name and func_split_long_opt_arg shell +# variables after splitting LONGOPT at the `=' sign. +func_split_long_opt () +{ + my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' + my_sed_long_arg='1s/^--[^=]*=//' - --preserve-dup-deps) duplicate_deps="yes" ;; + func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` + func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` +} # func_split_long_opt may be replaced by extended shell implementation - --quiet | --silent) - show=: - preserve_args="$preserve_args $arg" - ;; +exit_cmd=: - --tag) - prevopt="--tag" - prev=tag - preserve_args="$preserve_args --tag" - ;; - --tag=*) - set tag "$optarg" ${1+"$@"} - shift - prev=tag - preserve_args="$preserve_args --tag" - ;; - -dlopen) - prevopt="-dlopen" - prev=execute_dlfiles - ;; - -*) - $echo "$modename: unrecognized option \`$arg'" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - ;; - *) - nonopt="$arg" - break - ;; - esac -done -if test -n "$prevopt"; then - $echo "$modename: option \`$prevopt' requires an argument" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE -fi +magic="%%%MAGIC variable%%%" +magic_exe="%%%MAGIC EXE variable%%%" -case $disable_libs in -no) - ;; -shared) - build_libtool_libs=no - build_old_libs=yes - ;; -static) - build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` - ;; -esac +# Global variables. +nonopt= +preserve_args= +lo2o="s/\\.lo\$/.${objext}/" +o2lo="s/\\.${objext}\$/.lo/" +extracted_archives= +extracted_serial=0 # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. exec_cmd= -if test -z "$show_help"; then +# func_append var value +# Append VALUE to the end of shell variable VAR. +func_append () +{ + eval "${1}=\$${1}\${2}" +} # func_append may be replaced by extended shell implementation - # Infer the operation mode. - if test -z "$mode"; then - $echo "*** Warning: inferring the mode of operation is deprecated." 1>&2 - $echo "*** Future versions of Libtool will require --mode=MODE be specified." 1>&2 - case $nonopt in - *cc | cc* | *++ | gcc* | *-gcc* | g++* | xlc*) - mode=link - for arg - do - case $arg in - -c) - mode=compile - break - ;; - esac - done - ;; - *db | *dbx | *strace | *truss) - mode=execute - ;; - *install*|cp|mv) - mode=install - ;; - *rm) - mode=uninstall - ;; - *) - # If we have no mode, but dlfiles were specified, then do execute mode. - test -n "$execute_dlfiles" && mode=execute +# func_append_quoted var value +# Quote VALUE and append to the end of shell variable VAR, separated +# by a space. +func_append_quoted () +{ + func_quote_for_eval "${2}" + eval "${1}=\$${1}\\ \$func_quote_for_eval_result" +} # func_append_quoted may be replaced by extended shell implementation - # Just use the default operation mode. - if test -z "$mode"; then - if test -n "$nonopt"; then - $echo "$modename: warning: cannot infer operation mode from \`$nonopt'" 1>&2 - else - $echo "$modename: warning: cannot infer operation mode without MODE-ARGS" 1>&2 - fi - fi - ;; - esac - fi - # Only execute mode is allowed to have -dlopen flags. - if test -n "$execute_dlfiles" && test "$mode" != execute; then - $echo "$modename: unrecognized option \`-dlopen'" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi +# func_arith arithmetic-term... +func_arith () +{ + func_arith_result=`expr "${@}"` +} # func_arith may be replaced by extended shell implementation - # Change the help message to a mode-specific one. - generic_help="$help" - help="Try \`$modename --help --mode=$mode' for more information." - # These modes are in order of execution frequency so that they run quickly. - case $mode in - # libtool compile mode - compile) - modename="$modename: compile" - # Get the compilation command and the source file. - base_compile= - srcfile="$nonopt" # always keep a non-empty value in "srcfile" - suppress_opt=yes - suppress_output= - arg_mode=normal - libobj= - later= +# func_len string +# STRING may not start with a hyphen. +func_len () +{ + func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len` +} # func_len may be replaced by extended shell implementation - for arg - do - case $arg_mode in - arg ) - # do not "continue". Instead, add this to base_compile - lastarg="$arg" - arg_mode=normal - ;; - target ) - libobj="$arg" - arg_mode=normal - continue - ;; +# func_lo2o object +func_lo2o () +{ + func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` +} # func_lo2o may be replaced by extended shell implementation - normal ) - # Accept any command-line options. - case $arg in - -o) - if test -n "$libobj" ; then - $echo "$modename: you cannot specify \`-o' more than once" 1>&2 - exit $EXIT_FAILURE - fi - arg_mode=target - continue - ;; - -static | -prefer-pic | -prefer-non-pic) - later="$later $arg" - continue - ;; +# func_xform libobj-or-source +func_xform () +{ + func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` +} # func_xform may be replaced by extended shell implementation - -no-suppress) - suppress_opt=no - continue - ;; - -Xcompiler) - arg_mode=arg # the next one goes into the "base_compile" arg list - continue # The current "srcfile" will either be retained or - ;; # replaced later. I would guess that would be a bug. +# func_fatal_configuration arg... +# Echo program name prefixed message to standard error, followed by +# a configuration failure hint, and exit. +func_fatal_configuration () +{ + func_error ${1+"$@"} + func_error "See the $PACKAGE documentation for more information." + func_fatal_error "Fatal configuration error." +} - -Wc,*) - args=`$echo "X$arg" | $Xsed -e "s/^-Wc,//"` - lastarg= - save_ifs="$IFS"; IFS=',' - for arg in $args; do - IFS="$save_ifs" - # Double-quote args containing other shell metacharacters. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac - lastarg="$lastarg $arg" - done - IFS="$save_ifs" - lastarg=`$echo "X$lastarg" | $Xsed -e "s/^ //"` +# func_config +# Display the configuration for all the tags in this script. +func_config () +{ + re_begincf='^# ### BEGIN LIBTOOL' + re_endcf='^# ### END LIBTOOL' - # Add the arguments to base_compile. - base_compile="$base_compile $lastarg" - continue - ;; + # Default configuration. + $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" - * ) - # Accept the current argument as the source file. - # The previous "srcfile" becomes the current argument. - # - lastarg="$srcfile" - srcfile="$arg" - ;; - esac # case $arg - ;; - esac # case $arg_mode + # Now print the configurations for the tags. + for tagname in $taglist; do + $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" + done - # Aesthetically quote the previous argument. - lastarg=`$echo "X$lastarg" | $Xsed -e "$sed_quote_subst"` + exit $? +} - case $lastarg in - # Double-quote args containing other shell metacharacters. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, and some SunOS ksh mistreat backslash-escaping - # in scan sets (worked around with variable expansion), - # and furthermore cannot handle '|' '&' '(' ')' in scan sets - # at all, so we specify them separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - lastarg="\"$lastarg\"" - ;; - esac +# func_features +# Display the features supported by this script. +func_features () +{ + echo "host: $host" + if test "$build_libtool_libs" = yes; then + echo "enable shared libraries" + else + echo "disable shared libraries" + fi + if test "$build_old_libs" = yes; then + echo "enable static libraries" + else + echo "disable static libraries" + fi - base_compile="$base_compile $lastarg" - done # for arg + exit $? +} - case $arg_mode in - arg) - $echo "$modename: you must specify an argument for -Xcompile" - exit $EXIT_FAILURE - ;; - target) - $echo "$modename: you must specify a target with \`-o'" 1>&2 - exit $EXIT_FAILURE - ;; - *) - # Get the name of the library object. - [ -z "$libobj" ] && libobj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%'` - ;; - esac +# func_enable_tag tagname +# Verify that TAGNAME is valid, and either flag an error and exit, or +# enable the TAGNAME tag. We also add TAGNAME to the global $taglist +# variable here. +func_enable_tag () +{ + # Global variable: + tagname="$1" - # Recognize several different file suffixes. - # If the user specifies -o file.o, it is replaced with file.lo - xform='[cCFSifmso]' - case $libobj in - *.ada) xform=ada ;; - *.adb) xform=adb ;; - *.ads) xform=ads ;; - *.asm) xform=asm ;; - *.c++) xform=c++ ;; - *.cc) xform=cc ;; - *.ii) xform=ii ;; - *.class) xform=class ;; - *.cpp) xform=cpp ;; - *.cxx) xform=cxx ;; - *.f90) xform=f90 ;; - *.for) xform=for ;; - *.java) xform=java ;; - esac + re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" + re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" + sed_extractcf="/$re_begincf/,/$re_endcf/p" - libobj=`$echo "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"` + # Validate tagname. + case $tagname in + *[!-_A-Za-z0-9,/]*) + func_fatal_error "invalid tag name: $tagname" + ;; + esac - case $libobj in - *.lo) obj=`$echo "X$libobj" | $Xsed -e "$lo2o"` ;; + # Don't test for the "default" C tag, as we know it's + # there but not specially marked. + case $tagname in + CC) ;; *) - $echo "$modename: cannot determine name of library object from \`$libobj'" 1>&2 - exit $EXIT_FAILURE + if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then + taglist="$taglist $tagname" + + # Evaluate the configuration. Be careful to quote the path + # and the sed script, to avoid splitting on whitespace, but + # also don't use non-portable quotes within backquotes within + # quotes we have to do it in 2 steps: + extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` + eval "$extractedcf" + else + func_error "ignoring unknown tag $tagname" + fi ;; - esac - - func_infer_tag $base_compile + esac +} - for arg in $later; do - case $arg in - -static) - build_old_libs=yes - continue - ;; - - -prefer-pic) - pic_mode=yes - continue - ;; - - -prefer-non-pic) - pic_mode=no - continue - ;; - esac - done - - qlibobj=`$echo "X$libobj" | $Xsed -e "$sed_quote_subst"` - case $qlibobj in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - qlibobj="\"$qlibobj\"" ;; - esac - test "X$libobj" != "X$qlibobj" \ - && $echo "X$libobj" | grep '[]~#^*{};<>?"'"'"' &()|`$[]' \ - && $echo "$modename: libobj name \`$libobj' may not contain shell special characters." - objname=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` - xdir=`$echo "X$obj" | $Xsed -e 's%/[^/]*$%%'` - if test "X$xdir" = "X$obj"; then - xdir= +# func_check_version_match +# Ensure that we are using m4 macros, and libtool script from the same +# release of libtool. +func_check_version_match () +{ + if test "$package_revision" != "$macro_revision"; then + if test "$VERSION" != "$macro_version"; then + if test -z "$macro_version"; then + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from an older release. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + else + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + fi else - xdir=$xdir/ - fi - lobj=${xdir}$objdir/$objname - - if test -z "$base_compile"; then - $echo "$modename: you must specify a compilation command" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, +$progname: but the definition of this LT_INIT comes from revision $macro_revision. +$progname: You should recreate aclocal.m4 with macros from revision $package_revision +$progname: of $PACKAGE $VERSION and run autoconf again. +_LT_EOF fi - # Delete any leftover library objects. - if test "$build_old_libs" = yes; then - removelist="$obj $lobj $libobj ${libobj}T" - else - removelist="$lobj $libobj ${libobj}T" - fi + exit $EXIT_MISMATCH + fi +} - $run $rm $removelist - trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 - # On Cygwin there's no "real" PIC flag so we must build both object types - case $host_os in - cygwin* | mingw* | pw32* | os2*) - pic_mode=default - ;; - esac - if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then - # non-PIC code in shared libraries is not supported - pic_mode=default - fi +# Shorthand for --mode=foo, only valid as the first argument +case $1 in +clean|clea|cle|cl) + shift; set dummy --mode clean ${1+"$@"}; shift + ;; +compile|compil|compi|comp|com|co|c) + shift; set dummy --mode compile ${1+"$@"}; shift + ;; +execute|execut|execu|exec|exe|ex|e) + shift; set dummy --mode execute ${1+"$@"}; shift + ;; +finish|finis|fini|fin|fi|f) + shift; set dummy --mode finish ${1+"$@"}; shift + ;; +install|instal|insta|inst|ins|in|i) + shift; set dummy --mode install ${1+"$@"}; shift + ;; +link|lin|li|l) + shift; set dummy --mode link ${1+"$@"}; shift + ;; +uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) + shift; set dummy --mode uninstall ${1+"$@"}; shift + ;; +esac - # Calculate the filename of the output object if compiler does - # not support -o with -c - if test "$compiler_c_o" = no; then - output_obj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext} - lockfile="$output_obj.lock" - removelist="$removelist $output_obj $lockfile" - trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 - else - output_obj= - need_locks=no - lockfile= - fi - # Lock this critical section if it is needed - # We use this script file to make the link, it avoids creating a new file - if test "$need_locks" = yes; then - until $run ln "$progpath" "$lockfile" 2>/dev/null; do - $show "Waiting for $lockfile to be removed" - sleep 2 - done - elif test "$need_locks" = warn; then - if test -f "$lockfile"; then - $echo "\ -*** ERROR, $lockfile exists and contains: -`cat $lockfile 2>/dev/null` -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." +# Option defaults: +opt_debug=: +opt_dry_run=false +opt_config=false +opt_preserve_dup_deps=false +opt_features=false +opt_finish=false +opt_help=false +opt_help_all=false +opt_silent=: +opt_verbose=: +opt_silent=false +opt_verbose=false - $run $rm $removelist - exit $EXIT_FAILURE - fi - $echo "$srcfile" > "$lockfile" - fi - if test -n "$fix_srcfile_path"; then - eval srcfile=\"$fix_srcfile_path\" - fi - qsrcfile=`$echo "X$srcfile" | $Xsed -e "$sed_quote_subst"` - case $qsrcfile in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - qsrcfile="\"$qsrcfile\"" ;; - esac +# Parse options once, thoroughly. This comes as soon as possible in the +# script to make things like `--version' happen as quickly as we can. +{ + # this just eases exit handling + while test $# -gt 0; do + opt="$1" + shift + case $opt in + --debug|-x) opt_debug='set -x' + func_echo "enabling shell trace mode" + $opt_debug + ;; + --dry-run|--dryrun|-n) + opt_dry_run=: + ;; + --config) + opt_config=: +func_config + ;; + --dlopen|-dlopen) + optarg="$1" + opt_dlopen="${opt_dlopen+$opt_dlopen +}$optarg" + shift + ;; + --preserve-dup-deps) + opt_preserve_dup_deps=: + ;; + --features) + opt_features=: +func_features + ;; + --finish) + opt_finish=: +set dummy --mode finish ${1+"$@"}; shift + ;; + --help) + opt_help=: + ;; + --help-all) + opt_help_all=: +opt_help=': help-all' + ;; + --mode) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_mode="$optarg" +case $optarg in + # Valid mode arguments: + clean|compile|execute|finish|install|link|relink|uninstall) ;; + + # Catch anything else as an error + *) func_error "invalid argument for $opt" + exit_cmd=exit + break + ;; +esac + shift + ;; + --no-silent|--no-quiet) + opt_silent=false +func_append preserve_args " $opt" + ;; + --no-verbose) + opt_verbose=false +func_append preserve_args " $opt" + ;; + --silent|--quiet) + opt_silent=: +func_append preserve_args " $opt" + opt_verbose=false + ;; + --verbose|-v) + opt_verbose=: +func_append preserve_args " $opt" +opt_silent=false + ;; + --tag) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_tag="$optarg" +func_append preserve_args " $opt $optarg" +func_enable_tag "$optarg" + shift + ;; - $run $rm "$libobj" "${libobj}T" + -\?|-h) func_usage ;; + --help) func_help ;; + --version) func_version ;; - # Create a libtool object file (analogous to a ".la" file), - # but don't create it if we're doing a dry run. - test -z "$run" && cat > ${libobj}T </dev/null`" != "X$srcfile"; then - $echo "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` + if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then + func_fatal_configuration "not configured to build any kind of library" + fi -but it should contain: -$srcfile + # Darwin sucks + eval std_shrext=\"$shrext_cmds\" -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." + # Only execute mode is allowed to have -dlopen flags. + if test -n "$opt_dlopen" && test "$opt_mode" != execute; then + func_error "unrecognized option \`-dlopen'" + $ECHO "$help" 1>&2 + exit $EXIT_FAILURE + fi - $run $rm $removelist - exit $EXIT_FAILURE - fi + # Change the help message to a mode-specific one. + generic_help="$help" + help="Try \`$progname --help --mode=$opt_mode' for more information." + } - # Just move the object if needed, then go on to compile the next one - if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then - $show "$mv $output_obj $lobj" - if $run $mv $output_obj $lobj; then : - else - error=$? - $run $rm $removelist - exit $error - fi - fi - # Append the name of the PIC object to the libtool object file. - test -z "$run" && cat >> ${libobj}T <> ${libobj}T </dev/null \ + | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 +} - if test "$need_locks" = warn && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $echo "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` +# func_lalib_unsafe_p file +# True iff FILE is a libtool `.la' library or `.lo' object file. +# This function implements the same check as func_lalib_p without +# resorting to external programs. To this end, it redirects stdin and +# closes it afterwards, without saving the original file descriptor. +# As a safety measure, use it only where a negative result would be +# fatal anyway. Works if `file' does not exist. +func_lalib_unsafe_p () +{ + lalib_p=no + if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then + for lalib_p_l in 1 2 3 4 + do + read lalib_p_line + case "$lalib_p_line" in + \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; + esac + done + exec 0<&5 5<&- + fi + test "$lalib_p" = yes +} -but it should contain: -$srcfile +# func_ltwrapper_script_p file +# True iff FILE is a libtool wrapper script +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_script_p () +{ + func_lalib_p "$1" +} -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support \`-c' and \`-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." +# func_ltwrapper_executable_p file +# True iff FILE is a libtool wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_executable_p () +{ + func_ltwrapper_exec_suffix= + case $1 in + *.exe) ;; + *) func_ltwrapper_exec_suffix=.exe ;; + esac + $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 +} - $run $rm $removelist - exit $EXIT_FAILURE - fi +# func_ltwrapper_scriptname file +# Assumes file is an ltwrapper_executable +# uses $file to determine the appropriate filename for a +# temporary ltwrapper_script. +func_ltwrapper_scriptname () +{ + func_dirname_and_basename "$1" "" "." + func_stripname '' '.exe' "$func_basename_result" + func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" +} - # Just move the object if needed - if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then - $show "$mv $output_obj $obj" - if $run $mv $output_obj $obj; then : - else - error=$? - $run $rm $removelist - exit $error - fi - fi +# func_ltwrapper_p file +# True iff FILE is a libtool wrapper script or wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_p () +{ + func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" +} - # Append the name of the non-PIC object the libtool object file. - # Only append if the libtool object file exists. - test -z "$run" && cat >> ${libobj}T <> ${libobj}T <&2 - fi - if test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - else - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static +# func_infer_tag arg +# Infer tagged configuration to use if any are available and +# if one wasn't chosen via the "--tag" command line option. +# Only attempt this if the compiler in the base compile +# command doesn't match the default compiler. +# arg is usually of the form 'gcc ...' +func_infer_tag () +{ + $opt_debug + if test -n "$available_tags" && test -z "$tagname"; then + CC_quoted= + for arg in $CC; do + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case $@ in + # Blanks in the command may have been stripped by the calling shell, + # but not from the CC environment variable when configure was run. + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; + # Blanks at the start of $base_compile will cause this to fail + # if we don't check for them as well. + *) + for z in $available_tags; do + if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then + # Evaluate the configuration. + eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" + CC_quoted= + for arg in $CC; do + # Double-quote args containing other shell metacharacters. + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case "$@ " in + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) + # The compiler in the base compile command matches + # the one in the tagged configuration. + # Assume this is the tagged configuration we want. + tagname=$z + break + ;; + esac fi - prefer_static_libs=built + done + # If $tagname still isn't set, then no tagged configuration + # was found and let the user know that the "--tag" command + # line option must be used. + if test -z "$tagname"; then + func_echo "unable to infer tagged configuration" + func_fatal_error "specify a tag with \`--tag'" +# else +# func_verbose "using $tagname tagged configuration" fi - build_libtool_libs=no - build_old_libs=yes - break ;; esac - done - - # See if our shared archives depend on static archives. - test -n "$old_archive_from_new_cmds" && build_old_libs=yes + fi +} - # Go through the arguments, transforming them on the way. - while test "$#" -gt 0; do - arg="$1" - shift - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - qarg=\"`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`\" ### testsuite: skip nested quoting test - ;; - *) qarg=$arg ;; - esac - libtool_args="$libtool_args $qarg" - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - case $prev in - output) - compile_command="$compile_command @OUTPUT@" - finalize_command="$finalize_command @OUTPUT@" - ;; - esac - case $prev in - dlfiles|dlprefiles) - if test "$preload" = no; then - # Add the symbol object into the linking commands. - compile_command="$compile_command @SYMFILE@" - finalize_command="$finalize_command @SYMFILE@" - preload=yes - fi - case $arg in - *.la | *.lo) ;; # We handle these cases below. - force) - if test "$dlself" = no; then - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - self) - if test "$prev" = dlprefiles; then - dlself=yes - elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then - dlself=yes - else - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - *) - if test "$prev" = dlfiles; then - dlfiles="$dlfiles $arg" - else - dlprefiles="$dlprefiles $arg" - fi - prev= - continue - ;; - esac - ;; - expsyms) - export_symbols="$arg" - if test ! -f "$arg"; then - $echo "$modename: symbol file \`$arg' does not exist" - exit $EXIT_FAILURE - fi - prev= - continue - ;; - expsyms_regex) - export_symbols_regex="$arg" - prev= - continue - ;; - inst_prefix) - inst_prefix_dir="$arg" - prev= - continue - ;; - precious_regex) - precious_files_regex="$arg" - prev= - continue - ;; - release) - release="-$arg" - prev= - continue - ;; - objectlist) - if test -f "$arg"; then - save_arg=$arg - moreargs= - for fil in `cat $save_arg` - do -# moreargs="$moreargs $fil" - arg=$fil - # A libtool-controlled object. +# func_write_libtool_object output_name pic_name nonpic_name +# Create a libtool object file (analogous to a ".la" file), +# but don't create it if we're doing a dry run. +func_write_libtool_object () +{ + write_libobj=${1} + if test "$build_libtool_libs" = yes; then + write_lobj=\'${2}\' + else + write_lobj=none + fi - # Check to see that this really is a libtool object. - if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then - pic_object= - non_pic_object= + if test "$build_old_libs" = yes; then + write_oldobj=\'${3}\' + else + write_oldobj=none + fi - # Read the .lo file - # If there is no directory component, then add one. - case $arg in - */* | *\\*) . $arg ;; - *) . ./$arg ;; - esac + $opt_dry_run || { + cat >${write_libobj}T <&2 - exit $EXIT_FAILURE - fi +# Name of the PIC object. +pic_object=$write_lobj - # Extract subdirectory from the argument. - xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` - if test "X$xdir" = "X$arg"; then - xdir= - else - xdir="$xdir/" - fi +# Name of the non-PIC object +non_pic_object=$write_oldobj - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" +EOF + $MV "${write_libobj}T" "${write_libobj}" + } +} - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - dlfiles="$dlfiles $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - dlprefiles="$dlprefiles $pic_object" - prev= - fi +################################################## +# FILE NAME AND PATH CONVERSION HELPER FUNCTIONS # +################################################## - # A PIC object. - libobjs="$libobjs $pic_object" - arg="$pic_object" - fi +# func_convert_core_file_wine_to_w32 ARG +# Helper function used by file name conversion functions when $build is *nix, +# and $host is mingw, cygwin, or some other w32 environment. Relies on a +# correctly configured wine environment available, with the winepath program +# in $build's $PATH. +# +# ARG is the $build file name to be converted to w32 format. +# Result is available in $func_convert_core_file_wine_to_w32_result, and will +# be empty on error (or when ARG is empty) +func_convert_core_file_wine_to_w32 () +{ + $opt_debug + func_convert_core_file_wine_to_w32_result="$1" + if test -n "$1"; then + # Unfortunately, winepath does not exit with a non-zero error code, so we + # are forced to check the contents of stdout. On the other hand, if the + # command is not found, the shell will set an exit code of 127 and print + # *an error message* to stdout. So we must check for both error code of + # zero AND non-empty stdout, which explains the odd construction: + func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null` + if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then + func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | + $SED -e "$lt_sed_naive_backslashify"` + else + func_convert_core_file_wine_to_w32_result= + fi + fi +} +# end: func_convert_core_file_wine_to_w32 - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" - # A standard non-PIC object - non_pic_objects="$non_pic_objects $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if test -z "$run"; then - $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 - exit $EXIT_FAILURE - else - # Dry-run case. +# func_convert_core_path_wine_to_w32 ARG +# Helper function used by path conversion functions when $build is *nix, and +# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly +# configured wine environment available, with the winepath program in $build's +# $PATH. Assumes ARG has no leading or trailing path separator characters. +# +# ARG is path to be converted from $build format to win32. +# Result is available in $func_convert_core_path_wine_to_w32_result. +# Unconvertible file (directory) names in ARG are skipped; if no directory names +# are convertible, then the result may be empty. +func_convert_core_path_wine_to_w32 () +{ + $opt_debug + # unfortunately, winepath doesn't convert paths, only file names + func_convert_core_path_wine_to_w32_result="" + if test -n "$1"; then + oldIFS=$IFS + IFS=: + for func_convert_core_path_wine_to_w32_f in $1; do + IFS=$oldIFS + func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" + if test -n "$func_convert_core_file_wine_to_w32_result" ; then + if test -z "$func_convert_core_path_wine_to_w32_result"; then + func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" + else + func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" + fi + fi + done + IFS=$oldIFS + fi +} +# end: func_convert_core_path_wine_to_w32 + + +# func_cygpath ARGS... +# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when +# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) +# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or +# (2), returns the Cygwin file name or path in func_cygpath_result (input +# file name or path is assumed to be in w32 format, as previously converted +# from $build's *nix or MSYS format). In case (3), returns the w32 file name +# or path in func_cygpath_result (input file name or path is assumed to be in +# Cygwin format). Returns an empty string on error. +# +# ARGS are passed to cygpath, with the last one being the file name or path to +# be converted. +# +# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH +# environment variable; do not put it in $PATH. +func_cygpath () +{ + $opt_debug + if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then + func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` + if test "$?" -ne 0; then + # on failure, ensure result is empty + func_cygpath_result= + fi + else + func_cygpath_result= + func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" + fi +} +#end: func_cygpath - # Extract subdirectory from the argument. - xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` - if test "X$xdir" = "X$arg"; then - xdir= - else - xdir="$xdir/" - fi - pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` - non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` - libobjs="$libobjs $pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" - fi - fi - done - else - $echo "$modename: link input file \`$save_arg' does not exist" - exit $EXIT_FAILURE - fi - arg=$save_arg - prev= - continue - ;; - rpath | xrpath) - # We need an absolute path. - case $arg in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - $echo "$modename: only absolute run-paths are allowed" 1>&2 - exit $EXIT_FAILURE - ;; - esac - if test "$prev" = rpath; then - case "$rpath " in - *" $arg "*) ;; - *) rpath="$rpath $arg" ;; - esac - else - case "$xrpath " in - *" $arg "*) ;; - *) xrpath="$xrpath $arg" ;; - esac - fi - prev= - continue - ;; - xcompiler) - compiler_flags="$compiler_flags $qarg" - prev= - compile_command="$compile_command $qarg" - finalize_command="$finalize_command $qarg" - continue - ;; - xlinker) - linker_flags="$linker_flags $qarg" - compiler_flags="$compiler_flags $wl$qarg" - prev= - compile_command="$compile_command $wl$qarg" - finalize_command="$finalize_command $wl$qarg" - continue - ;; - xcclinker) - linker_flags="$linker_flags $qarg" - compiler_flags="$compiler_flags $qarg" - prev= - compile_command="$compile_command $qarg" - finalize_command="$finalize_command $qarg" - continue - ;; - shrext) - shrext_cmds="$arg" - prev= - continue - ;; - darwin_framework|darwin_framework_skip) - test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg" - compile_command="$compile_command $arg" - finalize_command="$finalize_command $arg" - prev= - continue - ;; - *) - eval "$prev=\"\$arg\"" - prev= - continue - ;; - esac - fi # test -n "$prev" +# func_convert_core_msys_to_w32 ARG +# Convert file name or path ARG from MSYS format to w32 format. Return +# result in func_convert_core_msys_to_w32_result. +func_convert_core_msys_to_w32 () +{ + $opt_debug + # awkward: cmd appends spaces to result + func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | + $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` +} +#end: func_convert_core_msys_to_w32 - prevarg="$arg" - case $arg in - -all-static) - if test -n "$link_static_flag"; then - compile_command="$compile_command $link_static_flag" - finalize_command="$finalize_command $link_static_flag" - fi - continue - ;; +# func_convert_file_check ARG1 ARG2 +# Verify that ARG1 (a file name in $build format) was converted to $host +# format in ARG2. Otherwise, emit an error message, but continue (resetting +# func_to_host_file_result to ARG1). +func_convert_file_check () +{ + $opt_debug + if test -z "$2" && test -n "$1" ; then + func_error "Could not determine host file name corresponding to" + func_error " \`$1'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback: + func_to_host_file_result="$1" + fi +} +# end func_convert_file_check - -allow-undefined) - # FIXME: remove this flag sometime in the future. - $echo "$modename: \`-allow-undefined' is deprecated because it is the default" 1>&2 - continue - ;; - -avoid-version) - avoid_version=yes - continue - ;; +# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH +# Verify that FROM_PATH (a path in $build format) was converted to $host +# format in TO_PATH. Otherwise, emit an error message, but continue, resetting +# func_to_host_file_result to a simplistic fallback value (see below). +func_convert_path_check () +{ + $opt_debug + if test -z "$4" && test -n "$3"; then + func_error "Could not determine the host path corresponding to" + func_error " \`$3'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback. This is a deliberately simplistic "conversion" and + # should not be "improved". See libtool.info. + if test "x$1" != "x$2"; then + lt_replace_pathsep_chars="s|$1|$2|g" + func_to_host_path_result=`echo "$3" | + $SED -e "$lt_replace_pathsep_chars"` + else + func_to_host_path_result="$3" + fi + fi +} +# end func_convert_path_check - -dlopen) - prev=dlfiles - continue - ;; - -dlpreopen) - prev=dlprefiles - continue - ;; +# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG +# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT +# and appending REPL if ORIG matches BACKPAT. +func_convert_path_front_back_pathsep () +{ + $opt_debug + case $4 in + $1 ) func_to_host_path_result="$3$func_to_host_path_result" + ;; + esac + case $4 in + $2 ) func_append func_to_host_path_result "$3" + ;; + esac +} +# end func_convert_path_front_back_pathsep - -export-dynamic) - export_dynamic=yes - continue - ;; - -export-symbols | -export-symbols-regex) - if test -n "$export_symbols" || test -n "$export_symbols_regex"; then - $echo "$modename: more than one -exported-symbols argument is not allowed" - exit $EXIT_FAILURE - fi - if test "X$arg" = "X-export-symbols"; then - prev=expsyms - else - prev=expsyms_regex - fi - continue - ;; +################################################## +# $build to $host FILE NAME CONVERSION FUNCTIONS # +################################################## +# invoked via `$to_host_file_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# Result will be available in $func_to_host_file_result. - -framework|-arch|-isysroot) - case " $CC " in - *" ${arg} ${1} "* | *" ${arg} ${1} "*) - prev=darwin_framework_skip ;; - *) compiler_flags="$compiler_flags $arg" - prev=darwin_framework ;; - esac - compile_command="$compile_command $arg" - finalize_command="$finalize_command $arg" - continue - ;; - -inst-prefix-dir) - prev=inst_prefix - continue - ;; +# func_to_host_file ARG +# Converts the file name ARG from $build format to $host format. Return result +# in func_to_host_file_result. +func_to_host_file () +{ + $opt_debug + $to_host_file_cmd "$1" +} +# end func_to_host_file - # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* - # so, if we see these flags be careful not to treat them like -L - -L[A-Z][A-Z]*:*) - case $with_gcc/$host in - no/*-*-irix* | /*-*-irix*) - compile_command="$compile_command $arg" - finalize_command="$finalize_command $arg" - ;; - esac - continue - ;; - -L*) - dir=`$echo "X$arg" | $Xsed -e 's/^-L//'` - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - absdir=`cd "$dir" && pwd` - if test -z "$absdir"; then - $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2 - absdir="$dir" - notinst_path="$notinst_path $dir" - fi - dir="$absdir" - ;; - esac - case "$deplibs " in - *" -L$dir "*) ;; - *) - deplibs="$deplibs -L$dir" - lib_search_path="$lib_search_path $dir" - ;; - esac - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$dir:"*) ;; - *) dllsearchpath="$dllsearchpath:$dir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; - esac - ;; - esac - continue - ;; +# func_to_tool_file ARG LAZY +# converts the file name ARG from $build format to toolchain format. Return +# result in func_to_tool_file_result. If the conversion in use is listed +# in (the comma separated) LAZY, no conversion takes place. +func_to_tool_file () +{ + $opt_debug + case ,$2, in + *,"$to_tool_file_cmd",*) + func_to_tool_file_result=$1 + ;; + *) + $to_tool_file_cmd "$1" + func_to_tool_file_result=$func_to_host_file_result + ;; + esac +} +# end func_to_tool_file - -l*) - if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) - # These systems don't actually have a C or math library (as such) - continue - ;; - *-*-os2*) - # These systems don't actually have a C library (as such) - test "X$arg" = "X-lc" && continue - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - test "X$arg" = "X-lc" && continue - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C and math libraries are in the System framework - deplibs="$deplibs -framework System" - continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test "X$arg" = "X-lc" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test "X$arg" = "X-lc" && continue - ;; - esac - elif test "X$arg" = "X-lc_r"; then - case $host in - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc_r directly, use -pthread flag. - continue - ;; - esac - fi - deplibs="$deplibs $arg" - continue - ;; - # Tru64 UNIX uses -model [arg] to determine the layout of C++ - # classes, name mangling, and exception handling. - -model) - compile_command="$compile_command $arg" - compiler_flags="$compiler_flags $arg" - finalize_command="$finalize_command $arg" - prev=xcompiler - continue - ;; +# func_convert_file_noop ARG +# Copy ARG to func_to_host_file_result. +func_convert_file_noop () +{ + func_to_host_file_result="$1" +} +# end func_convert_file_noop - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe) - compiler_flags="$compiler_flags $arg" - compile_command="$compile_command $arg" - finalize_command="$finalize_command $arg" - continue - ;; - -module) - module=yes - continue - ;; +# func_convert_file_msys_to_w32 ARG +# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_file_result. +func_convert_file_msys_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_to_host_file_result="$func_convert_core_msys_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_w32 - # -64, -mips[0-9] enable 64-bit mode on the SGI compiler - # -r[0-9][0-9]* specifies the processor on the SGI compiler - # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler - # +DA*, +DD* enable 64-bit mode on the HP compiler - # -q* pass through compiler args for the IBM compiler - # -m* pass through architecture-specific compiler args for GCC - # -m*, -t[45]*, -txscale* pass through architecture-specific - # compiler args for GCC - # -pg pass through profiling flag for GCC - # @file GCC response files - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*|-pg| \ - -t[45]*|-txscale*|@*) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac - compile_command="$compile_command $arg" - finalize_command="$finalize_command $arg" - compiler_flags="$compiler_flags $arg" - continue - ;; +# func_convert_file_cygwin_to_w32 ARG +# Convert file name ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_file_cygwin_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # because $build is cygwin, we call "the" cygpath in $PATH; no need to use + # LT_CYGPATH in this case. + func_to_host_file_result=`cygpath -m "$1"` + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_cygwin_to_w32 - -shrext) - prev=shrext - continue - ;; - -no-fast-install) - fast_install=no - continue - ;; +# func_convert_file_nix_to_w32 ARG +# Convert file name ARG from *nix to w32 format. Requires a wine environment +# and a working winepath. Returns result in func_to_host_file_result. +func_convert_file_nix_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_file_wine_to_w32 "$1" + func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_w32 - -no-install) - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - # The PATH hackery in wrapper scripts is required on Windows - # in order for the loader to find any dlls it needs. - $echo "$modename: warning: \`-no-install' is ignored for $host" 1>&2 - $echo "$modename: warning: assuming \`-no-fast-install' instead" 1>&2 - fast_install=no - ;; - *) no_install=yes ;; - esac - continue - ;; - -no-undefined) - allow_undefined=no - continue - ;; +# func_convert_file_msys_to_cygwin ARG +# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_file_msys_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_cygpath -u "$func_convert_core_msys_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_cygwin - -objectlist) - prev=objectlist - continue - ;; - -o) prev=output ;; +# func_convert_file_nix_to_cygwin ARG +# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed +# in a wine environment, working winepath, and LT_CYGPATH set. Returns result +# in func_to_host_file_result. +func_convert_file_nix_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. + func_convert_core_file_wine_to_w32 "$1" + func_cygpath -u "$func_convert_core_file_wine_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_cygwin - -precious-files-regex) - prev=precious_regex - continue - ;; - -release) - prev=release - continue - ;; +############################################# +# $build to $host PATH CONVERSION FUNCTIONS # +############################################# +# invoked via `$to_host_path_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# The result will be available in $func_to_host_path_result. +# +# Path separators are also converted from $build format to $host format. If +# ARG begins or ends with a path separator character, it is preserved (but +# converted to $host format) on output. +# +# All path conversion functions are named using the following convention: +# file name conversion function : func_convert_file_X_to_Y () +# path conversion function : func_convert_path_X_to_Y () +# where, for any given $build/$host combination the 'X_to_Y' value is the +# same. If conversion functions are added for new $build/$host combinations, +# the two new functions must follow this pattern, or func_init_to_host_path_cmd +# will break. + + +# func_init_to_host_path_cmd +# Ensures that function "pointer" variable $to_host_path_cmd is set to the +# appropriate value, based on the value of $to_host_file_cmd. +to_host_path_cmd= +func_init_to_host_path_cmd () +{ + $opt_debug + if test -z "$to_host_path_cmd"; then + func_stripname 'func_convert_file_' '' "$to_host_file_cmd" + to_host_path_cmd="func_convert_path_${func_stripname_result}" + fi +} - -rpath) - prev=rpath - continue + +# func_to_host_path ARG +# Converts the path ARG from $build format to $host format. Return result +# in func_to_host_path_result. +func_to_host_path () +{ + $opt_debug + func_init_to_host_path_cmd + $to_host_path_cmd "$1" +} +# end func_to_host_path + + +# func_convert_path_noop ARG +# Copy ARG to func_to_host_path_result. +func_convert_path_noop () +{ + func_to_host_path_result="$1" +} +# end func_convert_path_noop + + +# func_convert_path_msys_to_w32 ARG +# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_path_result. +func_convert_path_msys_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # Remove leading and trailing path separator characters from ARG. MSYS + # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; + # and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result="$func_convert_core_msys_to_w32_result" + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_msys_to_w32 + + +# func_convert_path_cygwin_to_w32 ARG +# Convert path ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_path_cygwin_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_cygwin_to_w32 + + +# func_convert_path_nix_to_w32 ARG +# Convert path ARG from *nix to w32 format. Requires a wine environment and +# a working winepath. Returns result in func_to_host_file_result. +func_convert_path_nix_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result="$func_convert_core_path_wine_to_w32_result" + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_nix_to_w32 + + +# func_convert_path_msys_to_cygwin ARG +# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_path_msys_to_cygwin () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_msys_to_w32_result" + func_to_host_path_result="$func_cygpath_result" + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_msys_to_cygwin + + +# func_convert_path_nix_to_cygwin ARG +# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a +# a wine environment, working winepath, and LT_CYGPATH set. Returns result in +# func_to_host_file_result. +func_convert_path_nix_to_cygwin () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # Remove leading and trailing path separator characters from + # ARG. msys behavior is inconsistent here, cygpath turns them + # into '.;' and ';.', and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" + func_to_host_path_result="$func_cygpath_result" + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_nix_to_cygwin + + +# func_mode_compile arg... +func_mode_compile () +{ + $opt_debug + # Get the compilation command and the source file. + base_compile= + srcfile="$nonopt" # always keep a non-empty value in "srcfile" + suppress_opt=yes + suppress_output= + arg_mode=normal + libobj= + later= + pie_flag= + + for arg + do + case $arg_mode in + arg ) + # do not "continue". Instead, add this to base_compile + lastarg="$arg" + arg_mode=normal ;; - -R) - prev=xrpath + target ) + libobj="$arg" + arg_mode=normal continue ;; - -R*) - dir=`$echo "X$arg" | $Xsed -e 's/^-R//'` - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - $echo "$modename: only absolute run-paths are allowed" 1>&2 - exit $EXIT_FAILURE + normal ) + # Accept any command-line options. + case $arg in + -o) + test -n "$libobj" && \ + func_fatal_error "you cannot specify \`-o' more than once" + arg_mode=target + continue ;; - esac - case "$xrpath " in - *" $dir "*) ;; - *) xrpath="$xrpath $dir" ;; - esac - continue - ;; - -static) - # The effects of -static are defined in a previous loop. - # We used to do the same as -all-static on platforms that - # didn't have a PIC flag, but the assumption that the effects - # would be equivalent was wrong. It would break on at least - # Digital Unix and AIX. - continue - ;; + -pie | -fpie | -fPIE) + func_append pie_flag " $arg" + continue + ;; - -thread-safe) - thread_safe=yes - continue - ;; + -shared | -static | -prefer-pic | -prefer-non-pic) + func_append later " $arg" + continue + ;; - -version-info) - prev=vinfo - continue - ;; - -version-number) - prev=vinfo - vinfo_number=yes - continue - ;; + -no-suppress) + suppress_opt=no + continue + ;; - -Wc,*) - args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wc,//'` - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - case $flag in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - flag="\"$flag\"" - ;; - esac - arg="$arg $wl$flag" - compiler_flags="$compiler_flags $flag" - done - IFS="$save_ifs" - arg=`$echo "X$arg" | $Xsed -e "s/^ //"` - ;; + -Xcompiler) + arg_mode=arg # the next one goes into the "base_compile" arg list + continue # The current "srcfile" will either be retained or + ;; # replaced later. I would guess that would be a bug. - -Wl,*) - args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wl,//'` - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + lastarg= + save_ifs="$IFS"; IFS=',' + for arg in $args; do + IFS="$save_ifs" + func_append_quoted lastarg "$arg" + done IFS="$save_ifs" - case $flag in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - flag="\"$flag\"" - ;; - esac - arg="$arg $wl$flag" - compiler_flags="$compiler_flags $wl$flag" - linker_flags="$linker_flags $flag" - done - IFS="$save_ifs" - arg=`$echo "X$arg" | $Xsed -e "s/^ //"` + func_stripname ' ' '' "$lastarg" + lastarg=$func_stripname_result + + # Add the arguments to base_compile. + func_append base_compile " $lastarg" + continue + ;; + + *) + # Accept the current argument as the source file. + # The previous "srcfile" becomes the current argument. + # + lastarg="$srcfile" + srcfile="$arg" + ;; + esac # case $arg ;; + esac # case $arg_mode - -Xcompiler) - prev=xcompiler + # Aesthetically quote the previous argument. + func_append_quoted base_compile "$lastarg" + done # for arg + + case $arg_mode in + arg) + func_fatal_error "you must specify an argument for -Xcompile" + ;; + target) + func_fatal_error "you must specify a target with \`-o'" + ;; + *) + # Get the name of the library object. + test -z "$libobj" && { + func_basename "$srcfile" + libobj="$func_basename_result" + } + ;; + esac + + # Recognize several different file suffixes. + # If the user specifies -o file.o, it is replaced with file.lo + case $libobj in + *.[cCFSifmso] | \ + *.ada | *.adb | *.ads | *.asm | \ + *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ + *.[fF][09]? | *.for | *.java | *.obj | *.sx | *.cu | *.cup) + func_xform "$libobj" + libobj=$func_xform_result + ;; + esac + + case $libobj in + *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; + *) + func_fatal_error "cannot determine name of library object from \`$libobj'" + ;; + esac + + func_infer_tag $base_compile + + for arg in $later; do + case $arg in + -shared) + test "$build_libtool_libs" != yes && \ + func_fatal_configuration "can not build a shared library" + build_old_libs=no continue ;; - -Xlinker) - prev=xlinker + -static) + build_libtool_libs=no + build_old_libs=yes continue ;; - -XCClinker) - prev=xcclinker + -prefer-pic) + pic_mode=yes continue ;; - # Some other compiler flag. - -* | +*) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac + -prefer-non-pic) + pic_mode=no + continue ;; + esac + done - *.$objext) - # A standard object. - objs="$objs $arg" - ;; + func_quote_for_eval "$libobj" + test "X$libobj" != "X$func_quote_for_eval_result" \ + && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ + && func_warning "libobj name \`$libobj' may not contain shell special characters." + func_dirname_and_basename "$obj" "/" "" + objname="$func_basename_result" + xdir="$func_dirname_result" + lobj=${xdir}$objdir/$objname - *.lo) - # A libtool-controlled object. + test -z "$base_compile" && \ + func_fatal_help "you must specify a compilation command" - # Check to see that this really is a libtool object. - if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then - pic_object= - non_pic_object= + # Delete any leftover library objects. + if test "$build_old_libs" = yes; then + removelist="$obj $lobj $libobj ${libobj}T" + else + removelist="$lobj $libobj ${libobj}T" + fi - # Read the .lo file - # If there is no directory component, then add one. - case $arg in - */* | *\\*) . $arg ;; - *) . ./$arg ;; - esac + # On Cygwin there's no "real" PIC flag so we must build both object types + case $host_os in + cygwin* | mingw* | pw32* | os2* | cegcc*) + pic_mode=default + ;; + esac + if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then + # non-PIC code in shared libraries is not supported + pic_mode=default + fi - if test -z "$pic_object" || \ - test -z "$non_pic_object" || - test "$pic_object" = none && \ - test "$non_pic_object" = none; then - $echo "$modename: cannot find name of object for \`$arg'" 1>&2 - exit $EXIT_FAILURE - fi + # Calculate the filename of the output object if compiler does + # not support -o with -c + if test "$compiler_c_o" = no; then + output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext} + lockfile="$output_obj.lock" + else + output_obj= + need_locks=no + lockfile= + fi - # Extract subdirectory from the argument. - xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` - if test "X$xdir" = "X$arg"; then - xdir= - else - xdir="$xdir/" - fi + # Lock this critical section if it is needed + # We use this script file to make the link, it avoids creating a new file + if test "$need_locks" = yes; then + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + elif test "$need_locks" = warn; then + if test -f "$lockfile"; then + $ECHO "\ +*** ERROR, $lockfile exists and contains: +`cat $lockfile 2>/dev/null` - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - dlfiles="$dlfiles $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + func_append removelist " $output_obj" + $ECHO "$srcfile" > "$lockfile" + fi - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - dlprefiles="$dlprefiles $pic_object" - prev= - fi + $opt_dry_run || $RM $removelist + func_append removelist " $lockfile" + trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 - # A PIC object. - libobjs="$libobjs $pic_object" - arg="$pic_object" - fi + func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 + srcfile=$func_to_tool_file_result + func_quote_for_eval "$srcfile" + qsrcfile=$func_quote_for_eval_result - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" + # Only build a PIC object if we are building libtool libraries. + if test "$build_libtool_libs" = yes; then + # Without this assignment, base_compile gets emptied. + fbsd_hideous_sh_bug=$base_compile - # A standard non-PIC object - non_pic_objects="$non_pic_objects $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if test -z "$run"; then - $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 - exit $EXIT_FAILURE - else - # Dry-run case. + if test "$pic_mode" != no; then + command="$base_compile $qsrcfile $pic_flag" + else + # Don't build PIC code + command="$base_compile $qsrcfile" + fi - # Extract subdirectory from the argument. - xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` - if test "X$xdir" = "X$arg"; then - xdir= - else - xdir="$xdir/" - fi + func_mkdir_p "$xdir$objdir" - pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` - non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` - libobjs="$libobjs $pic_object" - non_pic_objects="$non_pic_objects $non_pic_object" - fi - fi - ;; + if test -z "$output_obj"; then + # Place PIC objects in $objdir + func_append command " -o $lobj" + fi - *.$libext) - # An archive. - deplibs="$deplibs $arg" - old_deplibs="$old_deplibs $arg" - continue - ;; + func_show_eval_locale "$command" \ + 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' - *.la) - # A libtool-controlled library. + if test "$need_locks" = warn && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` - if test "$prev" = dlfiles; then - # This library was specified with -dlopen. - dlfiles="$dlfiles $arg" - prev= - elif test "$prev" = dlprefiles; then - # The library was specified with -dlpreopen. - dlprefiles="$dlprefiles $arg" - prev= - else - deplibs="$deplibs $arg" - fi - continue - ;; +but it should contain: +$srcfile - # Some other compiler argument. - *) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac - ;; - esac # arg +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." - # Now actually substitute the argument into the commands. - if test -n "$arg"; then - compile_command="$compile_command $arg" - finalize_command="$finalize_command $arg" + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE fi - done # argument parsing loop - if test -n "$prev"; then - $echo "$modename: the \`$prevarg' option requires an argument" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi + # Just move the object if needed, then go on to compile the next one + if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then + func_show_eval '$MV "$output_obj" "$lobj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + fi - if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then - eval arg=\"$export_dynamic_flag_spec\" - compile_command="$compile_command $arg" - finalize_command="$finalize_command $arg" + # Allow error messages only from the first compilation. + if test "$suppress_opt" = yes; then + suppress_output=' >/dev/null 2>&1' + fi fi - oldlibs= - # calculate the name of the file, without its directory - outputname=`$echo "X$output" | $Xsed -e 's%^.*/%%'` - libobjs_save="$libobjs" + # Only build a position-dependent object if we build old libraries. + if test "$build_old_libs" = yes; then + if test "$pic_mode" != yes; then + # Don't build PIC code + command="$base_compile $qsrcfile$pie_flag" + else + command="$base_compile $qsrcfile $pic_flag" + fi + if test "$compiler_c_o" = yes; then + func_append command " -o $obj" + fi - if test -n "$shlibpath_var"; then - # get the directories listed in $shlibpath_var - eval shlib_search_path=\`\$echo \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\` - else - shlib_search_path= - fi - eval sys_lib_search_path=\"$sys_lib_search_path_spec\" - eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" + # Suppress compiler output if we already did a PIC compilation. + func_append command "$suppress_output" + func_show_eval_locale "$command" \ + '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' - output_objdir=`$echo "X$output" | $Xsed -e 's%/[^/]*$%%'` - if test "X$output_objdir" = "X$output"; then - output_objdir="$objdir" - else - output_objdir="$output_objdir/$objdir" - fi - # Create the object directory. - if test ! -d "$output_objdir"; then - $show "$mkdir $output_objdir" - $run $mkdir $output_objdir - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then - exit $exit_status - fi - fi + if test "$need_locks" = warn && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` - # Determine the type of output - case $output in - "") - $echo "$modename: you must specify an output file" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - ;; - *.$libext) linkmode=oldlib ;; - *.lo | *.$objext) linkmode=obj ;; - *.la) linkmode=lib ;; - *) linkmode=prog ;; # Anything else should be a program. - esac +but it should contain: +$srcfile - case $host in - *cygwin* | *mingw* | *pw32*) - # don't eliminate duplications in $postdeps and $predeps - duplicate_compiler_generated_deps=yes - ;; - *) - duplicate_compiler_generated_deps=$duplicate_deps - ;; - esac - specialdeplibs= +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." - libs= - # Find all interdependent deplibs by searching for libraries - # that are linked more than once (e.g. -la -lb -la) - for deplib in $deplibs; do - if test "X$duplicate_deps" = "Xyes" ; then - case "$libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE fi - libs="$libs $deplib" - done - - if test "$linkmode" = lib; then - libs="$predeps $libs $compiler_lib_search_path $postdeps" - # Compute libraries that are listed more than once in $predeps - # $postdeps and mark them as special (i.e., whose duplicates are - # not to be eliminated). - pre_post_deps= - if test "X$duplicate_compiler_generated_deps" = "Xyes" ; then - for pre_post_dep in $predeps $postdeps; do - case "$pre_post_deps " in - *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;; - esac - pre_post_deps="$pre_post_deps $pre_post_dep" - done + # Just move the object if needed + if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then + func_show_eval '$MV "$output_obj" "$obj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' fi - pre_post_deps= fi - deplibs= - newdependency_libs= - newlib_search_path= - need_relink=no # whether we're linking any uninstalled libtool libraries - notinst_deplibs= # not-installed libtool libraries - case $linkmode in - lib) - passes="conv link" - for file in $dlfiles $dlprefiles; do - case $file in - *.la) ;; - *) - $echo "$modename: libraries can \`-dlopen' only libtool libraries: $file" 1>&2 - exit $EXIT_FAILURE - ;; - esac - done - ;; - prog) - compile_deplibs= - finalize_deplibs= - alldeplibs=no - newdlfiles= - newdlprefiles= - passes="conv scan dlopen dlpreopen link" - ;; - *) passes="conv" - ;; - esac - for pass in $passes; do - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan"; then - libs="$deplibs" - deplibs= - fi - if test "$linkmode" = prog; then - case $pass in - dlopen) libs="$dlfiles" ;; - dlpreopen) libs="$dlprefiles" ;; - link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; - esac + $opt_dry_run || { + func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" + + # Unlock the critical section if it was locked + if test "$need_locks" != no; then + removelist=$lockfile + $RM "$lockfile" fi - if test "$pass" = dlopen; then - # Collect dlpreopened libraries - save_deplibs="$deplibs" - deplibs= - fi - for deplib in $libs; do - lib= - found=no - case $deplib in - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - compiler_flags="$compiler_flags $deplib" - fi - continue - ;; - -l*) - if test "$linkmode" != lib && test "$linkmode" != prog; then - $echo "$modename: warning: \`-l' is ignored for archives/objects" 1>&2 - continue - fi - name=`$echo "X$deplib" | $Xsed -e 's/^-l//'` - for searchdir in $newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path; do - for search_ext in .la $std_shrext .so .a; do - # Search the libtool library - lib="$searchdir/lib${name}${search_ext}" - if test -f "$lib"; then - if test "$search_ext" = ".la"; then - found=yes - else - found=no - fi - break 2 - fi - done - done - if test "$found" != yes; then - # deplib doesn't seem to be a libtool library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - else # deplib is a libtool library - # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, - # We need to do some special things here, and not later. - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $deplib "*) - if (${SED} -e '2q' $lib | - grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then - library_names= - old_library= - case $lib in - */* | *\\*) . $lib ;; - *) . ./$lib ;; - esac - for l in $old_library $library_names; do - ll="$l" - done - if test "X$ll" = "X$old_library" ; then # only static version available - found=no - ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` - test "X$ladir" = "X$lib" && ladir="." - lib=$ladir/$old_library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - fi - fi - ;; - *) ;; - esac - fi - fi - ;; # -l - -L*) - case $linkmode in - lib) - deplibs="$deplib $deplibs" - test "$pass" = conv && continue - newdependency_libs="$deplib $newdependency_libs" - newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` - ;; - prog) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - if test "$pass" = scan; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` - ;; - *) - $echo "$modename: warning: \`-L' is ignored for archives/objects" 1>&2 - ;; - esac # linkmode - continue - ;; # -L - -R*) - if test "$pass" = link; then - dir=`$echo "X$deplib" | $Xsed -e 's/^-R//'` - # Make sure the xrpath contains only unique directories. - case "$xrpath " in - *" $dir "*) ;; - *) xrpath="$xrpath $dir" ;; - esac - fi - deplibs="$deplib $deplibs" - continue - ;; - *.la) lib="$deplib" ;; - *.$libext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - case $linkmode in - lib) - valid_a_lib=no - case $deplibs_check_method in - match_pattern*) - set dummy $deplibs_check_method - match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` - if eval $echo \"$deplib\" 2>/dev/null \ - | $SED 10q \ - | $EGREP "$match_pattern_regex" > /dev/null; then - valid_a_lib=yes - fi - ;; - pass_all) - valid_a_lib=yes - ;; - esac - if test "$valid_a_lib" != yes; then - $echo - $echo "*** Warning: Trying to link with static lib archive $deplib." - $echo "*** I have the capability to make that library automatically link in when" - $echo "*** you link to this library. But I can only do this if you have a" - $echo "*** shared version of the library, which you do not appear to have" - $echo "*** because the file extensions .$libext of this argument makes me believe" - $echo "*** that it is just a static archive that I should not used here." - else - $echo - $echo "*** Warning: Linking the shared library $output against the" - $echo "*** static library $deplib is not portable!" - deplibs="$deplib $deplibs" - fi - continue - ;; - prog) - if test "$pass" != link; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - continue - ;; - esac # linkmode - ;; # *.$libext - *.lo | *.$objext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - elif test "$linkmode" = prog; then - if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then - # If there is no dlopen support or we're linking statically, - # we need to preload. - newdlprefiles="$newdlprefiles $deplib" - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - newdlfiles="$newdlfiles $deplib" - fi - fi - continue - ;; - %DEPLIBS%) - alldeplibs=yes - continue - ;; - esac # case $deplib - if test "$found" = yes || test -f "$lib"; then : - else - $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2 - exit $EXIT_FAILURE - fi + } - # Check to see that this really is a libtool archive. - if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : - else - $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 - exit $EXIT_FAILURE - fi + exit $EXIT_SUCCESS +} - ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` - test "X$ladir" = "X$lib" && ladir="." +$opt_help || { + test "$opt_mode" = compile && func_mode_compile ${1+"$@"} +} - dlname= - dlopen= - dlpreopen= - libdir= - library_names= - old_library= - # If the library was installed with an old release of libtool, - # it will not redefine variables installed, or shouldnotlink - installed=yes - shouldnotlink=no - avoidtemprpath= +func_mode_help () +{ + # We need to display help for each of the modes. + case $opt_mode in + "") + # Generic help is extracted from the usage comments + # at the start of this file. + func_help + ;; + clean) + $ECHO \ +"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... - # Read the .la file - case $lib in - */* | *\\*) . $lib ;; - *) . ./$lib ;; - esac +Remove files from the build directory. - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan" || - { test "$linkmode" != prog && test "$linkmode" != lib; }; then - test -n "$dlopen" && dlfiles="$dlfiles $dlopen" - test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen" - fi +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. - if test "$pass" = conv; then - # Only check for convenience libraries - deplibs="$lib $deplibs" - if test -z "$libdir"; then - if test -z "$old_library"; then - $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 - exit $EXIT_FAILURE - fi - # It is a libtool convenience library, so add in its objects. - convenience="$convenience $ladir/$objdir/$old_library" - old_convenience="$old_convenience $ladir/$objdir/$old_library" - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if test "X$duplicate_deps" = "Xyes" ; then - case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac - fi - tmp_libs="$tmp_libs $deplib" - done - elif test "$linkmode" != prog && test "$linkmode" != lib; then - $echo "$modename: \`$lib' is not a convenience library" 1>&2 - exit $EXIT_FAILURE - fi - continue - fi # $pass = conv +If FILE is a libtool library, object or program, all the files associated +with it are deleted. Otherwise, only FILE itself is deleted using RM." + ;; + compile) + $ECHO \ +"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE - # Get the name of the library we link against. - linklib= - for l in $old_library $library_names; do - linklib="$l" - done - if test -z "$linklib"; then - $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 - exit $EXIT_FAILURE - fi +Compile a source file into a libtool library object. - # This library was specified with -dlopen. - if test "$pass" = dlopen; then - if test -z "$libdir"; then - $echo "$modename: cannot -dlopen a convenience library: \`$lib'" 1>&2 - exit $EXIT_FAILURE - fi - if test -z "$dlname" || - test "$dlopen_support" != yes || - test "$build_libtool_libs" = no; then - # If there is no dlname, no dlopen support or we're linking - # statically, we need to preload. We also need to preload any - # dependent libraries so libltdl's deplib preloader doesn't - # bomb out in the load deplibs phase. - dlprefiles="$dlprefiles $lib $dependency_libs" - else - newdlfiles="$newdlfiles $lib" - fi - continue - fi # $pass = dlopen +This mode accepts the following additional options: - # We need an absolute path. - case $ladir in - [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; - *) - abs_ladir=`cd "$ladir" && pwd` - if test -z "$abs_ladir"; then - $echo "$modename: warning: cannot determine absolute directory name of \`$ladir'" 1>&2 - $echo "$modename: passing it literally to the linker, although it might fail" 1>&2 - abs_ladir="$ladir" - fi - ;; - esac - laname=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` + -o OUTPUT-FILE set the output file name to OUTPUT-FILE + -no-suppress do not suppress compiler output for multiple passes + -prefer-pic try to build PIC objects only + -prefer-non-pic try to build non-PIC objects only + -shared do not build a \`.o' file suitable for static linking + -static only build a \`.o' file suitable for static linking + -Wc,FLAG pass FLAG directly to the compiler - # Find the relevant object directory and library name. - if test "X$installed" = Xyes; then - if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then - $echo "$modename: warning: library \`$lib' was moved." 1>&2 - dir="$ladir" - absdir="$abs_ladir" - libdir="$abs_ladir" - else - dir="$libdir" - absdir="$libdir" - fi - test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes - else - if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then - dir="$ladir" - absdir="$abs_ladir" - # Remove this search path later - notinst_path="$notinst_path $abs_ladir" - else - dir="$ladir/$objdir" - absdir="$abs_ladir/$objdir" - # Remove this search path later - notinst_path="$notinst_path $abs_ladir" - fi - fi # $installed = yes - name=`$echo "X$laname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` +COMPILE-COMMAND is a command to be used in creating a \`standard' object file +from the given SOURCEFILE. - # This library was specified with -dlpreopen. - if test "$pass" = dlpreopen; then - if test -z "$libdir"; then - $echo "$modename: cannot -dlpreopen a convenience library: \`$lib'" 1>&2 - exit $EXIT_FAILURE - fi - # Prefer using a static library (so that no silly _DYNAMIC symbols - # are required to link). - if test -n "$old_library"; then - newdlprefiles="$newdlprefiles $dir/$old_library" - # Otherwise, use the dlname, so that lt_dlopen finds it. - elif test -n "$dlname"; then - newdlprefiles="$newdlprefiles $dir/$dlname" - else - newdlprefiles="$newdlprefiles $dir/$linklib" - fi - fi # $pass = dlpreopen +The output file name is determined by removing the directory component from +SOURCEFILE, then substituting the C source code suffix \`.c' with the +library object suffix, \`.lo'." + ;; - if test -z "$libdir"; then - # Link the convenience library - if test "$linkmode" = lib; then - deplibs="$dir/$old_library $deplibs" - elif test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$dir/$old_library $compile_deplibs" - finalize_deplibs="$dir/$old_library $finalize_deplibs" - else - deplibs="$lib $deplibs" # used for prog,scan pass - fi - continue - fi + execute) + $ECHO \ +"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... +Automatically set library path, then run a program. - if test "$linkmode" = prog && test "$pass" != link; then - newlib_search_path="$newlib_search_path $ladir" - deplibs="$lib $deplibs" +This mode accepts the following additional options: - linkalldeplibs=no - if test "$link_all_deplibs" != no || test -z "$library_names" || - test "$build_libtool_libs" = no; then - linkalldeplibs=yes - fi + -dlopen FILE add the directory containing FILE to the library path - tmp_libs= - for deplib in $dependency_libs; do - case $deplib in - -L*) newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'`;; ### testsuite: skip nested quoting test - esac - # Need to link against all dependency_libs? - if test "$linkalldeplibs" = yes; then - deplibs="$deplib $deplibs" - else - # Need to hardcode shared library paths - # or/and link against static libraries - newdependency_libs="$deplib $newdependency_libs" - fi - if test "X$duplicate_deps" = "Xyes" ; then - case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac - fi - tmp_libs="$tmp_libs $deplib" - done # for deplib - continue - fi # $linkmode = prog... +This mode sets the library path environment variable according to \`-dlopen' +flags. - if test "$linkmode,$pass" = "prog,link"; then - if test -n "$library_names" && - { test "$prefer_static_libs" = no || test -z "$old_library"; }; then - # We need to hardcode the library path - if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then - # Make sure the rpath contains only unique directories. - case "$temp_rpath " in - *" $dir "*) ;; - *" $absdir "*) ;; - *) temp_rpath="$temp_rpath $absdir" ;; - esac - fi +If any of the ARGS are libtool executable wrappers, then they are translated +into their corresponding uninstalled binary, and any of their required library +directories are added to the library path. - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) compile_rpath="$compile_rpath $absdir" - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" - esac - ;; - esac - fi # $linkmode,$pass = prog,link... +Then, COMMAND is executed, with ARGS as arguments." + ;; - if test "$alldeplibs" = yes && - { test "$deplibs_check_method" = pass_all || - { test "$build_libtool_libs" = yes && - test -n "$library_names"; }; }; then - # We only need to search for static libraries - continue - fi - fi + finish) + $ECHO \ +"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... - link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test "$use_static_libs" = built && test "$installed" = yes ; then - use_static_libs=no - fi - if test -n "$library_names" && - { test "$use_static_libs" = no || test -z "$old_library"; }; then - if test "$installed" = no; then - notinst_deplibs="$notinst_deplibs $lib" - need_relink=yes - fi - # This is a shared library +Complete the installation of libtool libraries. - # Warn about portability, can't link against -module's on - # some systems (darwin) - if test "$shouldnotlink" = yes && test "$pass" = link ; then - $echo - if test "$linkmode" = prog; then - $echo "*** Warning: Linking the executable $output against the loadable module" - else - $echo "*** Warning: Linking the shared library $output against the loadable module" - fi - $echo "*** $linklib is not portable!" - fi - if test "$linkmode" = lib && - test "$hardcode_into_libs" = yes; then - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) compile_rpath="$compile_rpath $absdir" - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" - esac - ;; - esac - fi +Each LIBDIR is a directory that contains libtool libraries. - if test -n "$old_archive_from_expsyms_cmds"; then - # figure out the soname - set dummy $library_names - realname="$2" - shift; shift - libname=`eval \\$echo \"$libname_spec\"` - # use dlname if we got it. it's perfectly good, no? - if test -n "$dlname"; then - soname="$dlname" - elif test -n "$soname_spec"; then - # bleh windows - case $host in - *cygwin* | mingw*) - major=`expr $current - $age` - versuffix="-$major" - ;; - esac - eval soname=\"$soname_spec\" - else - soname="$realname" - fi +The commands that this mode executes may require superuser privileges. Use +the \`--dry-run' option if you just want to see what would be executed." + ;; - # Make a new name for the extract_expsyms_cmds to use - soroot="$soname" - soname=`$echo $soroot | ${SED} -e 's/^.*\///'` - newlib="libimp-`$echo $soname | ${SED} 's/^lib//;s/\.dll$//'`.a" + install) + $ECHO \ +"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... - # If the library has no export list, then create one now - if test -f "$output_objdir/$soname-def"; then : - else - $show "extracting exported symbol list from \`$soname'" - save_ifs="$IFS"; IFS='~' - cmds=$extract_expsyms_cmds - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || exit $? - done - IFS="$save_ifs" - fi +Install executables or libraries. - # Create $newlib - if test -f "$output_objdir/$newlib"; then :; else - $show "generating import library for \`$soname'" - save_ifs="$IFS"; IFS='~' - cmds=$old_archive_from_expsyms_cmds - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || exit $? - done - IFS="$save_ifs" - fi - # make sure the library variables are pointing to the new library - dir=$output_objdir - linklib=$newlib - fi # test -n "$old_archive_from_expsyms_cmds" +INSTALL-COMMAND is the installation command. The first component should be +either the \`install' or \`cp' program. - if test "$linkmode" = prog || test "$mode" != relink; then - add_shlibpath= - add_dir= - add= - lib_linked=yes - case $hardcode_action in - immediate | unsupported) - if test "$hardcode_direct" = no; then - add="$dir/$linklib" - case $host in - *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; - *-*-sysv4*uw2*) add_dir="-L$dir" ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir="-L$dir" ;; - *-*-darwin* ) - # if the lib is a module then we can not link against - # it, someone is ignoring the new warnings I added - if /usr/bin/file -L $add 2> /dev/null | - $EGREP ": [^:]* bundle" >/dev/null ; then - $echo "** Warning, lib $linklib is a module, not a shared library" - if test -z "$old_library" ; then - $echo - $echo "** And there doesn't seem to be a static archive available" - $echo "** The link will probably fail, sorry" - else - add="$dir/$old_library" - fi - fi - esac - elif test "$hardcode_minus_L" = no; then - case $host in - *-*-sunos*) add_shlibpath="$dir" ;; - esac - add_dir="-L$dir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = no; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - relink) - if test "$hardcode_direct" = yes; then - add="$dir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$dir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - add_dir="$add_dir -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - *) lib_linked=no ;; - esac +The following components of INSTALL-COMMAND are treated specially: - if test "$lib_linked" != yes; then - $echo "$modename: configuration error: unsupported hardcode properties" - exit $EXIT_FAILURE - fi + -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation - if test -n "$add_shlibpath"; then - case :$compile_shlibpath: in - *":$add_shlibpath:"*) ;; - *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; - esac - fi - if test "$linkmode" = prog; then - test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" - test -n "$add" && compile_deplibs="$add $compile_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - if test "$hardcode_direct" != yes && \ - test "$hardcode_minus_L" != yes && \ - test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; - esac - fi - fi - fi +The rest of the components are interpreted as arguments to that command (only +BSD-compatible install options are recognized)." + ;; - if test "$linkmode" = prog || test "$mode" = relink; then - add_shlibpath= - add_dir= - add= - # Finalize command for both is simple: just hardcode it. - if test "$hardcode_direct" = yes; then - add="$libdir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$libdir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; - esac - add="-l$name" - elif test "$hardcode_automatic" = yes; then - if test -n "$inst_prefix_dir" && - test -f "$inst_prefix_dir$libdir/$linklib" ; then - add="$inst_prefix_dir$libdir/$linklib" - else - add="$libdir/$linklib" - fi - else - # We cannot seem to hardcode it, guess we'll fake it. - add_dir="-L$libdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - add_dir="$add_dir -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - fi + link) + $ECHO \ +"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... - if test "$linkmode" = prog; then - test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" - test -n "$add" && finalize_deplibs="$add $finalize_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - fi - fi - elif test "$linkmode" = prog; then - # Here we assume that one of hardcode_direct or hardcode_minus_L - # is not unsupported. This is valid on all known static and - # shared platforms. - if test "$hardcode_direct" != unsupported; then - test -n "$old_library" && linklib="$old_library" - compile_deplibs="$dir/$linklib $compile_deplibs" - finalize_deplibs="$dir/$linklib $finalize_deplibs" - else - compile_deplibs="-l$name -L$dir $compile_deplibs" - finalize_deplibs="-l$name -L$dir $finalize_deplibs" - fi - elif test "$build_libtool_libs" = yes; then - # Not a shared library - if test "$deplibs_check_method" != pass_all; then - # We're trying link a shared library against a static one - # but the system doesn't support it. +Link object files or libraries together to form another library, or to +create an executable program. - # Just print a warning and add the library to dependency_libs so - # that the program can be linked against the static library. - $echo - $echo "*** Warning: This system can not link to static lib archive $lib." - $echo "*** I have the capability to make that library automatically link in when" - $echo "*** you link to this library. But I can only do this if you have a" - $echo "*** shared version of the library, which you do not appear to have." - if test "$module" = yes; then - $echo "*** But as you try to build a module library, libtool will still create " - $echo "*** a static module, that should work as long as the dlopening application" - $echo "*** is linked with the -dlopen flag to resolve symbols at runtime." - if test -z "$global_symbol_pipe"; then - $echo - $echo "*** However, this would only work if libtool was able to extract symbol" - $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - $echo "*** not find such a program. So, this module is probably useless." - $echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - else - deplibs="$dir/$old_library $deplibs" - link_static=yes - fi - fi # link shared/static library? +LINK-COMMAND is a command using the C compiler that you would use to create +a program from several object files. - if test "$linkmode" = lib; then - if test -n "$dependency_libs" && - { test "$hardcode_into_libs" != yes || - test "$build_old_libs" = yes || - test "$link_static" = yes; }; then - # Extract -R from dependency_libs - temp_deplibs= - for libdir in $dependency_libs; do - case $libdir in - -R*) temp_xrpath=`$echo "X$libdir" | $Xsed -e 's/^-R//'` - case " $xrpath " in - *" $temp_xrpath "*) ;; - *) xrpath="$xrpath $temp_xrpath";; - esac;; - *) temp_deplibs="$temp_deplibs $libdir";; - esac - done - dependency_libs="$temp_deplibs" - fi +The following components of LINK-COMMAND are treated specially: - newlib_search_path="$newlib_search_path $absdir" - # Link against this library - test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" - # ... and its dependency_libs - tmp_libs= - for deplib in $dependency_libs; do - newdependency_libs="$deplib $newdependency_libs" - if test "X$duplicate_deps" = "Xyes" ; then - case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac - fi - tmp_libs="$tmp_libs $deplib" - done + -all-static do not do any dynamic linking at all + -avoid-version do not add a version suffix if possible + -bindir BINDIR specify path to binaries directory (for systems where + libraries must be found in the PATH setting at runtime) + -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime + -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols + -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) + -export-symbols SYMFILE + try to export only the symbols listed in SYMFILE + -export-symbols-regex REGEX + try to export only the symbols matching REGEX + -LLIBDIR search LIBDIR for required installed libraries + -lNAME OUTPUT-FILE requires the installed library libNAME + -module build a library that can dlopened + -no-fast-install disable the fast-install mode + -no-install link a not-installable executable + -no-undefined declare that a library does not refer to external symbols + -o OUTPUT-FILE create OUTPUT-FILE from the specified objects + -objectlist FILE Use a list of object files found in FILE to specify objects + -precious-files-regex REGEX + don't remove output files matching REGEX + -release RELEASE specify package release information + -rpath LIBDIR the created library will eventually be installed in LIBDIR + -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries + -shared only do dynamic linking of libtool libraries + -shrext SUFFIX override the standard shared library file extension + -static do not do any dynamic linking of uninstalled libtool libraries + -static-libtool-libs + do not do any dynamic linking of libtool libraries + -version-info CURRENT[:REVISION[:AGE]] + specify library version info [each variable defaults to 0] + -weak LIBNAME declare that the target provides the LIBNAME interface + -Wc,FLAG + -Xcompiler FLAG pass linker-specific FLAG directly to the compiler + -Wl,FLAG + -Xlinker FLAG pass linker-specific FLAG directly to the linker + -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) - if test "$link_all_deplibs" != no; then - # Add the search paths of all dependency libraries - for deplib in $dependency_libs; do - case $deplib in - -L*) path="$deplib" ;; - *.la) - dir=`$echo "X$deplib" | $Xsed -e 's%/[^/]*$%%'` - test "X$dir" = "X$deplib" && dir="." - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; - *) - absdir=`cd "$dir" && pwd` - if test -z "$absdir"; then - $echo "$modename: warning: cannot determine absolute directory name of \`$dir'" 1>&2 - absdir="$dir" - fi - ;; - esac - if grep "^installed=no" $deplib > /dev/null; then - path="$absdir/$objdir" - else - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - if test -z "$libdir"; then - $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 - exit $EXIT_FAILURE - fi - if test "$absdir" != "$libdir"; then - $echo "$modename: warning: \`$deplib' seems to be moved" 1>&2 - fi - path="$absdir" - fi - depdepl= - case $host in - *-*-darwin*) - # we do not want to link against static libs, - # but need to link against shared - eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` - if test -n "$deplibrary_names" ; then - for tmp in $deplibrary_names ; do - depdepl=$tmp - done - if test -f "$path/$depdepl" ; then - depdepl="$path/$depdepl" - fi - # do not add paths which are already there - case " $newlib_search_path " in - *" $path "*) ;; - *) newlib_search_path="$newlib_search_path $path";; - esac - fi - path="" - ;; - *) - path="-L$path" - ;; - esac - ;; - -l*) - case $host in - *-*-darwin*) - # Again, we only want to link against shared libraries - eval tmp_libs=`$echo "X$deplib" | $Xsed -e "s,^\-l,,"` - for tmp in $newlib_search_path ; do - if test -f "$tmp/lib$tmp_libs.dylib" ; then - eval depdepl="$tmp/lib$tmp_libs.dylib" - break - fi - done - path="" - ;; - *) continue ;; - esac - ;; - *) continue ;; - esac - case " $deplibs " in - *" $path "*) ;; - *) deplibs="$path $deplibs" ;; - esac - case " $deplibs " in - *" $depdepl "*) ;; - *) deplibs="$depdepl $deplibs" ;; - esac - done - fi # link_all_deplibs != no - fi # linkmode = lib - done # for deplib in $libs - dependency_libs="$newdependency_libs" - if test "$pass" = dlpreopen; then - # Link the dlpreopened libraries before other libraries - for deplib in $save_deplibs; do - deplibs="$deplib $deplibs" - done - fi - if test "$pass" != dlopen; then - if test "$pass" != conv; then - # Make sure lib_search_path contains only unique directories. - lib_search_path= - for dir in $newlib_search_path; do - case "$lib_search_path " in - *" $dir "*) ;; - *) lib_search_path="$lib_search_path $dir" ;; - esac - done - newlib_search_path= +All other options (arguments beginning with \`-') are ignored. + +Every other argument is treated as a filename. Files ending in \`.la' are +treated as uninstalled libtool libraries, other files are standard or library +object files. + +If the OUTPUT-FILE ends in \`.la', then a libtool library is created, +only library objects (\`.lo' files) may be specified, and \`-rpath' is +required, except when creating a convenience library. + +If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created +using \`ar' and \`ranlib', or on Windows using \`lib'. + +If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file +is created, otherwise an executable program is created." + ;; + + uninstall) + $ECHO \ +"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... + +Remove libraries from an installation directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. + +If FILE is a libtool library, all the files associated with it are deleted. +Otherwise, only FILE itself is deleted using RM." + ;; + + *) + func_fatal_help "invalid operation mode \`$opt_mode'" + ;; + esac + + echo + $ECHO "Try \`$progname --help' for more information about other modes." +} + +# Now that we've collected a possible --mode arg, show help if necessary +if $opt_help; then + if test "$opt_help" = :; then + func_mode_help + else + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + func_mode_help + done + } | sed -n '1p; 2,$s/^Usage:/ or: /p' + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + echo + func_mode_help + done + } | + sed '1d + /^When reporting/,/^Report/{ + H + d + } + $x + /information about other modes/d + /more detailed .*MODE/d + s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' + fi + exit $? +fi + + +# func_mode_execute arg... +func_mode_execute () +{ + $opt_debug + # The first argument is the command name. + cmd="$nonopt" + test -z "$cmd" && \ + func_fatal_help "you must specify a COMMAND" + + # Handle -dlopen flags immediately. + for file in $opt_dlopen; do + test -f "$file" \ + || func_fatal_help "\`$file' is not a file" + + dir= + case $file in + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "\`$lib' is not a valid libtool archive" + + # Read the libtool library. + dlname= + library_names= + func_source "$file" + + # Skip this library if it cannot be dlopened. + if test -z "$dlname"; then + # Warn if it was a shared library. + test -n "$library_names" && \ + func_warning "\`$file' was not linked with \`-export-dynamic'" + continue fi - if test "$linkmode,$pass" != "prog,link"; then - vars="deplibs" + func_dirname "$file" "" "." + dir="$func_dirname_result" + + if test -f "$dir/$objdir/$dlname"; then + func_append dir "/$objdir" else - vars="compile_deplibs finalize_deplibs" + if test ! -f "$dir/$dlname"; then + func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" + fi fi - for var in $vars dependency_libs; do - # Add libraries to $var in reverse order - eval tmp_libs=\"\$$var\" - new_libs= - for deplib in $tmp_libs; do - # FIXME: Pedantically, this is the right thing to do, so - # that some nasty dependency loop isn't accidentally - # broken: - #new_libs="$deplib $new_libs" - # Pragmatically, this seems to cause very few problems in - # practice: - case $deplib in - -L*) new_libs="$deplib $new_libs" ;; - -R*) ;; - *) - # And here is the reason: when a library appears more - # than once as an explicit dependence of a library, or - # is implicitly linked in more than once by the - # compiler, it is considered special, and multiple - # occurrences thereof are not removed. Compare this - # with having the same library being listed as a - # dependency of multiple other libraries: in this case, - # we know (pedantically, we assume) the library does not - # need to be listed more than once, so we keep only the - # last copy. This is not always right, but it is rare - # enough that we require users that really mean to play - # such unportable linking tricks to link the library - # using -Wl,-lname, so that libtool does not consider it - # for duplicate removal. - case " $specialdeplibs " in - *" $deplib "*) new_libs="$deplib $new_libs" ;; - *) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$deplib $new_libs" ;; - esac - ;; - esac - ;; - esac - done - tmp_libs= - for deplib in $new_libs; do - case $deplib in - -L*) - case " $tmp_libs " in - *" $deplib "*) ;; - *) tmp_libs="$tmp_libs $deplib" ;; - esac - ;; - *) tmp_libs="$tmp_libs $deplib" ;; - esac - done - eval $var=\"$tmp_libs\" - done # for var - fi - # Last step: remove runtime libs from dependency_libs - # (they stay in deplibs) - tmp_libs= - for i in $dependency_libs ; do - case " $predeps $postdeps $compiler_lib_search_path " in - *" $i "*) - i="" - ;; - esac - if test -n "$i" ; then - tmp_libs="$tmp_libs $i" - fi - done - dependency_libs=$tmp_libs - done # for pass - if test "$linkmode" = prog; then - dlfiles="$newdlfiles" - dlprefiles="$newdlprefiles" - fi + ;; - case $linkmode in - oldlib) - if test -n "$deplibs"; then - $echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2 - fi + *.lo) + # Just add the directory containing the .lo file. + func_dirname "$file" "" "." + dir="$func_dirname_result" + ;; - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - $echo "$modename: warning: \`-dlopen' is ignored for archives" 1>&2 - fi + *) + func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" + continue + ;; + esac - if test -n "$rpath"; then - $echo "$modename: warning: \`-rpath' is ignored for archives" 1>&2 - fi + # Get the absolute pathname. + absdir=`cd "$dir" && pwd` + test -n "$absdir" && dir="$absdir" - if test -n "$xrpath"; then - $echo "$modename: warning: \`-R' is ignored for archives" 1>&2 + # Now add the directory to shlibpath_var. + if eval "test -z \"\$$shlibpath_var\""; then + eval "$shlibpath_var=\"\$dir\"" + else + eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" fi + done - if test -n "$vinfo"; then - $echo "$modename: warning: \`-version-info/-version-number' is ignored for archives" 1>&2 - fi + # This variable tells wrapper scripts just to set shlibpath_var + # rather than running their programs. + libtool_execute_magic="$magic" + + # Check if any of the arguments is a wrapper script. + args= + for file + do + case $file in + -* | *.la | *.lo ) ;; + *) + # Do a test to see if this is really a libtool program. + if func_ltwrapper_script_p "$file"; then + func_source "$file" + # Transform arg to wrapped name. + file="$progdir/$program" + elif func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + func_source "$func_ltwrapper_scriptname_result" + # Transform arg to wrapped name. + file="$progdir/$program" + fi + ;; + esac + # Quote arguments (to preserve shell metacharacters). + func_append_quoted args "$file" + done - if test -n "$release"; then - $echo "$modename: warning: \`-release' is ignored for archives" 1>&2 + if test "X$opt_dry_run" = Xfalse; then + if test -n "$shlibpath_var"; then + # Export the shlibpath_var. + eval "export $shlibpath_var" fi - if test -n "$export_symbols" || test -n "$export_symbols_regex"; then - $echo "$modename: warning: \`-export-symbols' is ignored for archives" 1>&2 + # Restore saved environment variables + for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES + do + eval "if test \"\${save_$lt_var+set}\" = set; then + $lt_var=\$save_$lt_var; export $lt_var + else + $lt_unset $lt_var + fi" + done + + # Now prepare to actually exec the command. + exec_cmd="\$cmd$args" + else + # Display what would be done. + if test -n "$shlibpath_var"; then + eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" + echo "export $shlibpath_var" fi + $ECHO "$cmd$args" + exit $EXIT_SUCCESS + fi +} - # Now set the variables for building old libraries. - build_libtool_libs=no - oldlibs="$output" - objs="$objs$old_deplibs" - ;; +test "$opt_mode" = execute && func_mode_execute ${1+"$@"} - lib) - # Make sure we only generate libraries of the form `libNAME.la'. - case $outputname in - lib*) - name=`$echo "X$outputname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - ;; - *) - if test "$module" = no; then - $echo "$modename: libtool library \`$output' must begin with \`lib'" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi - if test "$need_lib_prefix" != no; then - # Add the "lib" prefix for modules if required - name=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - else - libname=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` - fi - ;; - esac - if test -n "$objs"; then - if test "$deplibs_check_method" != pass_all; then - $echo "$modename: cannot build libtool library \`$output' from non-libtool objects on this host:$objs" 2>&1 - exit $EXIT_FAILURE +# func_mode_finish arg... +func_mode_finish () +{ + $opt_debug + libs= + libdirs= + admincmds= + + for opt in "$nonopt" ${1+"$@"} + do + if test -d "$opt"; then + func_append libdirs " $opt" + + elif test -f "$opt"; then + if func_lalib_unsafe_p "$opt"; then + func_append libs " $opt" else - $echo - $echo "*** Warning: Linking the shared library $output against the non-libtool" - $echo "*** objects $objs is not portable!" - libobjs="$libobjs $objs" + func_warning "\`$opt' is not a valid libtool archive" fi - fi - if test "$dlself" != no; then - $echo "$modename: warning: \`-dlopen self' is ignored for libtool libraries" 1>&2 + else + func_fatal_error "invalid argument \`$opt'" fi + done - set dummy $rpath - if test "$#" -gt 2; then - $echo "$modename: warning: ignoring multiple \`-rpath's for a libtool library" 1>&2 + if test -n "$libs"; then + if test -n "$lt_sysroot"; then + sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` + sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" + else + sysroot_cmd= fi - install_libdir="$2" - oldlibs= - if test -z "$rpath"; then - if test "$build_libtool_libs" = yes; then - # Building a libtool convenience library. - # Some compilers have problems with a `.al' extension so - # convenience libraries should have the same extension an - # archive normally would. - oldlibs="$output_objdir/$libname.$libext $oldlibs" - build_libtool_libs=convenience - build_old_libs=yes - fi + # Remove sysroot references + if $opt_dry_run; then + for lib in $libs; do + echo "removing references to $lt_sysroot and \`=' prefixes from $lib" + done + else + tmpdir=`func_mktempdir` + for lib in $libs; do + sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ + > $tmpdir/tmp-la + mv -f $tmpdir/tmp-la $lib + done + ${RM}r "$tmpdir" + fi + fi - if test -n "$vinfo"; then - $echo "$modename: warning: \`-version-info/-version-number' is ignored for convenience libraries" 1>&2 + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + for libdir in $libdirs; do + if test -n "$finish_cmds"; then + # Do each command in the finish commands. + func_execute_cmds "$finish_cmds" 'admincmds="$admincmds +'"$cmd"'"' fi - - if test -n "$release"; then - $echo "$modename: warning: \`-release' is ignored for convenience libraries" 1>&2 + if test -n "$finish_eval"; then + # Do the single finish_eval. + eval cmds=\"$finish_eval\" + $opt_dry_run || eval "$cmds" || func_append admincmds " + $cmds" fi - else + done + fi - # Parse the version information argument. - save_ifs="$IFS"; IFS=':' - set dummy $vinfo 0 0 0 - IFS="$save_ifs" + # Exit here if they wanted silent mode. + $opt_silent && exit $EXIT_SUCCESS - if test -n "$8"; then - $echo "$modename: too many parameters to \`-version-info'" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + echo "----------------------------------------------------------------------" + echo "Libraries have been installed in:" + for libdir in $libdirs; do + $ECHO " $libdir" + done + echo + echo "If you ever happen to want to link against installed libraries" + echo "in a given directory, LIBDIR, you must either use libtool, and" + echo "specify the full pathname of the library, or use the \`-LLIBDIR'" + echo "flag during linking and do at least one of the following:" + if test -n "$shlibpath_var"; then + echo " - add LIBDIR to the \`$shlibpath_var' environment variable" + echo " during execution" + fi + if test -n "$runpath_var"; then + echo " - add LIBDIR to the \`$runpath_var' environment variable" + echo " during linking" + fi + if test -n "$hardcode_libdir_flag_spec"; then + libdir=LIBDIR + eval flag=\"$hardcode_libdir_flag_spec\" - # convert absolute version numbers to libtool ages - # this retains compatibility with .la files and attempts - # to make the code below a bit more comprehensible + $ECHO " - use the \`$flag' linker flag" + fi + if test -n "$admincmds"; then + $ECHO " - have your system administrator run these commands:$admincmds" + fi + if test -f /etc/ld.so.conf; then + echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" + fi + echo - case $vinfo_number in - yes) - number_major="$2" - number_minor="$3" - number_revision="$4" - # - # There are really only two kinds -- those that - # use the current revision as the major version - # and those that subtract age and use age as - # a minor version. But, then there is irix - # which has an extra 1 added just for fun - # - case $version_type in - darwin|linux|osf|windows) - current=`expr $number_major + $number_minor` - age="$number_minor" - revision="$number_revision" - ;; - freebsd-aout|freebsd-elf|sunos) - current="$number_major" - revision="$number_minor" - age="0" - ;; - irix|nonstopux) - current=`expr $number_major + $number_minor - 1` - age="$number_minor" - revision="$number_minor" - ;; - esac - ;; - no) - current="$2" - revision="$3" - age="$4" + echo "See any operating system documentation about shared libraries for" + case $host in + solaris2.[6789]|solaris2.1[0-9]) + echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" + echo "pages." ;; - esac - - # Check that each of the things are valid numbers. - case $current in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) - $echo "$modename: CURRENT \`$current' must be a nonnegative integer" 1>&2 - $echo "$modename: \`$vinfo' is not valid version information" 1>&2 - exit $EXIT_FAILURE + echo "more information, such as the ld(1) and ld.so(8) manual pages." ;; - esac + esac + echo "----------------------------------------------------------------------" + fi + exit $EXIT_SUCCESS +} - case $revision in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - $echo "$modename: REVISION \`$revision' must be a nonnegative integer" 1>&2 - $echo "$modename: \`$vinfo' is not valid version information" 1>&2 - exit $EXIT_FAILURE - ;; - esac +test "$opt_mode" = finish && func_mode_finish ${1+"$@"} - case $age in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - $echo "$modename: AGE \`$age' must be a nonnegative integer" 1>&2 - $echo "$modename: \`$vinfo' is not valid version information" 1>&2 - exit $EXIT_FAILURE - ;; - esac - if test "$age" -gt "$current"; then - $echo "$modename: AGE \`$age' is greater than the current interface number \`$current'" 1>&2 - $echo "$modename: \`$vinfo' is not valid version information" 1>&2 - exit $EXIT_FAILURE - fi +# func_mode_install arg... +func_mode_install () +{ + $opt_debug + # There may be an optional sh(1) argument at the beginning of + # install_prog (especially on Windows NT). + if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || + # Allow the use of GNU shtool's install command. + case $nonopt in *shtool*) :;; *) false;; esac; then + # Aesthetically quote it. + func_quote_for_eval "$nonopt" + install_prog="$func_quote_for_eval_result " + arg=$1 + shift + else + install_prog= + arg=$nonopt + fi - # Calculate the version variables. - major= - versuffix= - verstring= - case $version_type in - none) ;; + # The real first argument should be the name of the installation program. + # Aesthetically quote it. + func_quote_for_eval "$arg" + func_append install_prog "$func_quote_for_eval_result" + install_shared_prog=$install_prog + case " $install_prog " in + *[\\\ /]cp\ *) install_cp=: ;; + *) install_cp=false ;; + esac - darwin) - # Like Linux, but with the current version available in - # verstring for coding it into the library header - major=.`expr $current - $age` - versuffix="$major.$age.$revision" - # Darwin ld doesn't like 0 for these options... - minor_current=`expr $current + 1` - verstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" - ;; + # We need to accept at least all the BSD install flags. + dest= + files= + opts= + prev= + install_type= + isdir=no + stripme= + no_mode=: + for arg + do + arg2= + if test -n "$dest"; then + func_append files " $dest" + dest=$arg + continue + fi - freebsd-aout) - major=".$current" - versuffix=".$current.$revision"; - ;; + case $arg in + -d) isdir=yes ;; + -f) + if $install_cp; then :; else + prev=$arg + fi + ;; + -g | -m | -o) + prev=$arg + ;; + -s) + stripme=" -s" + continue + ;; + -*) + ;; + *) + # If the previous option needed an argument, then skip it. + if test -n "$prev"; then + if test "x$prev" = x-m && test -n "$install_override_mode"; then + arg2=$install_override_mode + no_mode=false + fi + prev= + else + dest=$arg + continue + fi + ;; + esac - freebsd-elf) - major=".$current" - versuffix=".$current"; - ;; + # Aesthetically quote the argument. + func_quote_for_eval "$arg" + func_append install_prog " $func_quote_for_eval_result" + if test -n "$arg2"; then + func_quote_for_eval "$arg2" + fi + func_append install_shared_prog " $func_quote_for_eval_result" + done - irix | nonstopux) - major=`expr $current - $age + 1` + test -z "$install_prog" && \ + func_fatal_help "you must specify an install program" - case $version_type in - nonstopux) verstring_prefix=nonstopux ;; - *) verstring_prefix=sgi ;; - esac - verstring="$verstring_prefix$major.$revision" + test -n "$prev" && \ + func_fatal_help "the \`$prev' option requires an argument" - # Add in all the interfaces that we are compatible with. - loop=$revision - while test "$loop" -ne 0; do - iface=`expr $revision - $loop` - loop=`expr $loop - 1` - verstring="$verstring_prefix$major.$iface:$verstring" - done + if test -n "$install_override_mode" && $no_mode; then + if $install_cp; then :; else + func_quote_for_eval "$install_override_mode" + func_append install_shared_prog " -m $func_quote_for_eval_result" + fi + fi - # Before this point, $major must not contain `.'. - major=.$major - versuffix="$major.$revision" - ;; + if test -z "$files"; then + if test -z "$dest"; then + func_fatal_help "no file or destination specified" + else + func_fatal_help "you must specify a destination" + fi + fi - linux) - major=.`expr $current - $age` - versuffix="$major.$age.$revision" + # Strip any trailing slash from the destination. + func_stripname '' '/' "$dest" + dest=$func_stripname_result + + # Check to see that the destination is a directory. + test -d "$dest" && isdir=yes + if test "$isdir" = yes; then + destdir="$dest" + destname= + else + func_dirname_and_basename "$dest" "" "." + destdir="$func_dirname_result" + destname="$func_basename_result" + + # Not a directory, so check to see that there is only one file specified. + set dummy $files; shift + test "$#" -gt 1 && \ + func_fatal_help "\`$dest' is not a directory" + fi + case $destdir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + for file in $files; do + case $file in + *.lo) ;; + *) + func_fatal_help "\`$destdir' must be an absolute directory name" ;; + esac + done + ;; + esac - osf) - major=.`expr $current - $age` - versuffix=".$current.$age.$revision" - verstring="$current.$age.$revision" + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic="$magic" - # Add in all the interfaces that we are compatible with. - loop=$age - while test "$loop" -ne 0; do - iface=`expr $current - $loop` - loop=`expr $loop - 1` - verstring="$verstring:${iface}.0" - done + staticlibs= + future_libdirs= + current_libdirs= + for file in $files; do - # Make executables depend on our current version. - verstring="$verstring:${current}.0" - ;; + # Do each installation. + case $file in + *.$libext) + # Do the static libraries later. + func_append staticlibs " $file" + ;; - sunos) - major=".$current" - versuffix=".$current.$revision" - ;; + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result - windows) - # Use '-' rather than '.', since we only want one - # extension on DOS 8.3 filesystems. - major=`expr $current - $age` - versuffix="-$major" - ;; + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "\`$file' is not a valid libtool archive" - *) - $echo "$modename: unknown library version type \`$version_type'" 1>&2 - $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 - exit $EXIT_FAILURE - ;; - esac + library_names= + old_library= + relink_command= + func_source "$file" - # Clear the version info if we defaulted, and they specified a release. - if test -z "$vinfo" && test -n "$release"; then - major= - case $version_type in - darwin) - # we can't check for "0.0" in archive_cmds due to quoting - # problems, so we reset it completely - verstring= - ;; - *) - verstring="0.0" - ;; + # Add the libdir to current_libdirs if it is the destination. + if test "X$destdir" = "X$libdir"; then + case "$current_libdirs " in + *" $libdir "*) ;; + *) func_append current_libdirs " $libdir" ;; + esac + else + # Note the libdir as a future libdir. + case "$future_libdirs " in + *" $libdir "*) ;; + *) func_append future_libdirs " $libdir" ;; esac - if test "$need_version" = no; then - versuffix= - else - versuffix=".0.0" - fi fi - # Remove version info from name if versioning should be avoided - if test "$avoid_version" = yes && test "$need_version" = no; then - major= - versuffix= - verstring="" - fi + func_dirname "$file" "/" "" + dir="$func_dirname_result" + func_append dir "$objdir" - # Check to see if the archive will have undefined symbols. - if test "$allow_undefined" = yes; then - if test "$allow_undefined_flag" = unsupported; then - $echo "$modename: warning: undefined symbols not allowed in $host shared libraries" 1>&2 - build_libtool_libs=no - build_old_libs=yes + if test -n "$relink_command"; then + # Determine the prefix the user has applied to our future dir. + inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` + + # Don't allow the user to place us outside of our expected + # location b/c this prevents finding dependent libraries that + # are installed to the same prefix. + # At present, this check doesn't affect windows .dll's that + # are installed into $libdir/../bin (currently, that works fine) + # but it's something to keep an eye on. + test "$inst_prefix_dir" = "$destdir" && \ + func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir" + + if test -n "$inst_prefix_dir"; then + # Stick the inst_prefix_dir data into the link command. + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` + else + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` fi - else - # Don't allow undefined symbols. - allow_undefined_flag="$no_undefined_flag" - fi - fi - if test "$mode" != relink; then - # Remove our outputs, but don't remove object files since they - # may have been created when compiling PIC objects. - removelist= - tempremovelist=`$echo "$output_objdir/*"` - for p in $tempremovelist; do - case $p in - *.$objext) - ;; - $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) - if test "X$precious_files_regex" != "X"; then - if echo $p | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 - then - continue - fi - fi - removelist="$removelist $p" - ;; - *) ;; - esac - done - if test -n "$removelist"; then - $show "${rm}r $removelist" - $run ${rm}r $removelist + func_warning "relinking \`$file'" + func_show_eval "$relink_command" \ + 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' fi - fi - # Now set the variables for building old libraries. - if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then - oldlibs="$oldlibs $output_objdir/$libname.$libext" - - # Transform .lo files to .o files. - oldobjs="$objs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP` - fi + # See the names of the shared library. + set dummy $library_names; shift + if test -n "$1"; then + realname="$1" + shift - # Eliminate all temporary directories. - for path in $notinst_path; do - lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"` - deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"` - dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"` - done + srcname="$realname" + test -n "$relink_command" && srcname="$realname"T - if test -n "$xrpath"; then - # If the user specified any rpath flags, then add them. - temp_xrpath= - for libdir in $xrpath; do - temp_xrpath="$temp_xrpath -R$libdir" - case "$finalize_rpath " in - *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" ;; + # Install the shared library and build the symlinks. + func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ + 'exit $?' + tstripme="$stripme" + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + case $realname in + *.dll.a) + tstripme="" + ;; + esac + ;; esac - done - if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then - dependency_libs="$temp_xrpath $dependency_libs" + if test -n "$tstripme" && test -n "$striplib"; then + func_show_eval "$striplib $destdir/$realname" 'exit $?' + fi + + if test "$#" -gt 0; then + # Delete the old symlinks, and create new ones. + # Try `ln -sf' first, because the `ln' binary might depend on + # the symlink we replace! Solaris /bin/ln does not understand -f, + # so we also need to try rm && ln -s. + for linkname + do + test "$linkname" != "$realname" \ + && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" + done + fi + + # Do each command in the postinstall commands. + lib="$destdir/$realname" + func_execute_cmds "$postinstall_cmds" 'exit $?' fi - fi - # Make sure dlfiles contains only unique files that won't be dlpreopened - old_dlfiles="$dlfiles" - dlfiles= - for lib in $old_dlfiles; do - case " $dlprefiles $dlfiles " in - *" $lib "*) ;; - *) dlfiles="$dlfiles $lib" ;; - esac - done + # Install the pseudo-library for information purposes. + func_basename "$file" + name="$func_basename_result" + instname="$dir/$name"i + func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' - # Make sure dlprefiles contains only unique files - old_dlprefiles="$dlprefiles" - dlprefiles= - for lib in $old_dlprefiles; do - case "$dlprefiles " in - *" $lib "*) ;; - *) dlprefiles="$dlprefiles $lib" ;; + # Maybe install the static library, too. + test -n "$old_library" && func_append staticlibs " $dir/$old_library" + ;; + + *.lo) + # Install (i.e. copy) a libtool object. + + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" + else + func_basename "$file" + destfile="$func_basename_result" + destfile="$destdir/$destfile" + fi + + # Deduce the name of the destination old-style object file. + case $destfile in + *.lo) + func_lo2o "$destfile" + staticdest=$func_lo2o_result + ;; + *.$objext) + staticdest="$destfile" + destfile= + ;; + *) + func_fatal_help "cannot copy a libtool object to \`$destfile'" + ;; esac - done - if test "$build_libtool_libs" = yes; then - if test -n "$rpath"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*) - # these systems don't actually have a c library (as such)! - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C library is in the System framework - deplibs="$deplibs -framework System" - ;; - *-*-netbsd*) - # Don't link with libc until the a.out ld.so is fixed. - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. + # Install the libtool object if requested. + test -n "$destfile" && \ + func_show_eval "$install_prog $file $destfile" 'exit $?' + + # Install the old object if enabled. + if test "$build_old_libs" = yes; then + # Deduce the name of the old-style object file. + func_lo2o "$file" + staticobj=$func_lo2o_result + func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' + fi + exit $EXIT_SUCCESS + ;; + + *) + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" + else + func_basename "$file" + destfile="$func_basename_result" + destfile="$destdir/$destfile" + fi + + # If the file is missing, and there is a .exe on the end, strip it + # because it is most likely a libtool script we actually want to + # install + stripped_ext="" + case $file in + *.exe) + if test ! -f "$file"; then + func_stripname '' '.exe' "$file" + file=$func_stripname_result + stripped_ext=".exe" + fi ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype + esac + + # Do a test to see if this is really a libtool program. + case $host in + *cygwin* | *mingw*) + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + wrapper=$func_ltwrapper_scriptname_result + else + func_stripname '' '.exe' "$file" + wrapper=$func_stripname_result + fi ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work + *) + wrapper=$file ;; - *) - # Add libc to deplibs on all other systems if necessary. - if test "$build_libtool_need_lc" = "yes"; then - deplibs="$deplibs -lc" + esac + if func_ltwrapper_script_p "$wrapper"; then + notinst_deplibs= + relink_command= + + func_source "$wrapper" + + # Check the variables that should have been set. + test -z "$generated_by_libtool_version" && \ + func_fatal_error "invalid libtool wrapper script \`$wrapper'" + + finalize=yes + for lib in $notinst_deplibs; do + # Check to see that each library is installed. + libdir= + if test -f "$lib"; then + func_source "$lib" fi - ;; - esac - fi + libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test + if test -n "$libdir" && test ! -f "$libfile"; then + func_warning "\`$lib' has not been installed in \`$libdir'" + finalize=no + fi + done - # Transform deplibs into only deplibs that can be linked in shared. - name_save=$name - libname_save=$libname - release_save=$release - versuffix_save=$versuffix - major_save=$major - # I'm not sure if I'm treating the release correctly. I think - # release should show up in the -l (ie -lgmp5) so we don't want to - # add it in twice. Is that correct? - release="" - versuffix="" - major="" - newdeplibs= - droppeddeps=no - case $deplibs_check_method in - pass_all) - # Don't check for shared/static. Everything works. - # This might be a little naive. We might want to check - # whether the library exists or not. But this is on - # osf3 & osf4 and I'm not really sure... Just - # implementing what was already the behavior. - newdeplibs=$deplibs - ;; - test_compile) - # This code stresses the "libraries are programs" paradigm to its - # limits. Maybe even breaks it. We compile a program, linking it - # against the deplibs as a proxy for the library. Then we can check - # whether they linked in statically or dynamically with ldd. - $rm conftest.c - cat > conftest.c </dev/null` - for potent_lib in $potential_libs; do - # Follow soft links. - if ls -lLd "$potent_lib" 2>/dev/null \ - | grep " -> " >/dev/null; then - continue - fi - # The statement above tries to avoid entering an - # endless loop below, in case of cyclic links. - # We might still enter an endless loop, since a link - # loop can be closed while we follow links, - # but so what? - potlib="$potent_lib" - while test -h "$potlib" 2>/dev/null; do - potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` - case $potliblink in - [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; - *) potlib=`$echo "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";; - esac - done - if eval $file_magic_cmd \"\$potlib\" 2>/dev/null \ - | ${SED} 10q \ - | $EGREP "$file_magic_regex" > /dev/null; then - newdeplibs="$newdeplibs $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - $echo - $echo "*** Warning: linker path does not have real file for library $a_deplib." - $echo "*** I have the capability to make that library automatically link in when" - $echo "*** you link to this library. But I can only do this if you have a" - $echo "*** shared version of the library, which you do not appear to have" - $echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $echo "*** with $libname but no candidates were found. (...for file magic test)" - else - $echo "*** with $libname and none of the candidates passed a file format test" - $echo "*** using a file magic. Last file checked: $potlib" - fi - fi - else - # Add a -L argument. - newdeplibs="$newdeplibs $a_deplib" - fi - done # Gone through all deplibs. - ;; - match_pattern*) - set dummy $deplibs_check_method - match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` - for a_deplib in $deplibs; do - name=`expr $a_deplib : '-l\(.*\)'` - # If $name is empty we are operating on a -L argument. - if test -n "$name" && test "$name" != "0"; then - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $a_deplib "*) - newdeplibs="$newdeplibs $a_deplib" - a_deplib="" - ;; - esac - fi - if test -n "$a_deplib" ; then - libname=`eval \\$echo \"$libname_spec\"` - for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do - potential_libs=`ls $i/$libname[.-]* 2>/dev/null` - for potent_lib in $potential_libs; do - potlib="$potent_lib" # see symlink-check above in file_magic test - if eval $echo \"$potent_lib\" 2>/dev/null \ - | ${SED} 10q \ - | $EGREP "$match_pattern_regex" > /dev/null; then - newdeplibs="$newdeplibs $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - $echo - $echo "*** Warning: linker path does not have real file for library $a_deplib." - $echo "*** I have the capability to make that library automatically link in when" - $echo "*** you link to this library. But I can only do this if you have a" - $echo "*** shared version of the library, which you do not appear to have" - $echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $echo "*** with $libname but no candidates were found. (...for regex pattern test)" - else - $echo "*** with $libname and none of the candidates passed a file format test" - $echo "*** using a regex pattern. Last file checked: $potlib" - fi - fi - else - # Add a -L argument. - newdeplibs="$newdeplibs $a_deplib" - fi - done # Gone through all deplibs. - ;; - none | unknown | *) - newdeplibs="" - tmp_deplibs=`$echo "X $deplibs" | $Xsed -e 's/ -lc$//' \ - -e 's/ -[LR][^ ]*//g'` - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - for i in $predeps $postdeps ; do - # can't use Xsed below, because $i might contain '/' - tmp_deplibs=`$echo "X $tmp_deplibs" | ${SED} -e "1s,^X,," -e "s,$i,,"` - done - fi - if $echo "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' \ - | grep . >/dev/null; then - $echo - if test "X$deplibs_check_method" = "Xnone"; then - $echo "*** Warning: inter-library dependencies are not supported in this platform." - else - $echo "*** Warning: inter-library dependencies are not known to be supported." - fi - $echo "*** All declared inter-library dependencies are being dropped." - droppeddeps=yes + # Install the binary that we compiled earlier. + file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` fi + fi + + # remove .exe since cygwin /usr/bin/install will append another + # one anyway + case $install_prog,$host in + */usr/bin/install*,*cygwin*) + case $file:$destfile in + *.exe:*.exe) + # this is ok + ;; + *.exe:*) + destfile=$destfile.exe + ;; + *:*.exe) + func_stripname '' '.exe' "$destfile" + destfile=$func_stripname_result + ;; + esac ;; esac - versuffix=$versuffix_save - major=$major_save - release=$release_save - libname=$libname_save - name=$name_save + func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' + $opt_dry_run || if test -n "$outputname"; then + ${RM}r "$tmpdir" + fi + ;; + esac + done - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library is the System framework - newdeplibs=`$echo "X $newdeplibs" | $Xsed -e 's/ -lc / -framework System /'` - ;; - esac + for file in $staticlibs; do + func_basename "$file" + name="$func_basename_result" - if test "$droppeddeps" = yes; then - if test "$module" = yes; then - $echo - $echo "*** Warning: libtool could not satisfy all declared inter-library" - $echo "*** dependencies of module $libname. Therefore, libtool will create" - $echo "*** a static module, that should work as long as the dlopening" - $echo "*** application is linked with the -dlopen flag." - if test -z "$global_symbol_pipe"; then - $echo - $echo "*** However, this would only work if libtool was able to extract symbol" - $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" - $echo "*** not find such a program. So, this module is probably useless." - $echo "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - else - $echo "*** The inter-library dependencies that have been dropped here will be" - $echo "*** automatically added whenever a program is linked with this library" - $echo "*** or is declared to -dlopen it." + # Set up the ranlib parameters. + oldlib="$destdir/$name" - if test "$allow_undefined" = no; then - $echo - $echo "*** Since this library must not contain undefined symbols," - $echo "*** because either the platform does not support them or" - $echo "*** it was explicitly requested with -no-undefined," - $echo "*** libtool will only create a static version of it." - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - fi - fi - # Done checking deplibs! - deplibs=$newdeplibs + func_show_eval "$install_prog \$file \$oldlib" 'exit $?' + + if test -n "$stripme" && test -n "$old_striplib"; then + func_show_eval "$old_striplib $oldlib" 'exit $?' fi + # Do each command in the postinstall commands. + func_execute_cmds "$old_postinstall_cmds" 'exit $?' + done - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac - ;; - *) new_libs="$new_libs $deplib" ;; - esac - done - deplibs="$new_libs" + test -n "$future_libdirs" && \ + func_warning "remember to run \`$progname --finish$future_libdirs'" + if test -n "$current_libdirs"; then + # Maybe just do a dry run. + $opt_dry_run && current_libdirs=" -n$current_libdirs" + exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' + else + exit $EXIT_SUCCESS + fi +} - # All the library-specific variables (install_libdir is set above). - library_names= - old_library= - dlname= +test "$opt_mode" = install && func_mode_install ${1+"$@"} - # Test again, we may have decided not to build it any more - if test "$build_libtool_libs" = yes; then - if test "$hardcode_into_libs" = yes; then - # Hardcode the library paths - hardcode_libdirs= - dep_rpath= - rpath="$finalize_rpath" - test "$mode" != relink && rpath="$compile_rpath$rpath" - for libdir in $rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - dep_rpath="$dep_rpath $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) perm_rpath="$perm_rpath $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - if test -n "$hardcode_libdir_flag_spec_ld"; then - eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" - else - eval dep_rpath=\"$hardcode_libdir_flag_spec\" - fi - fi - if test -n "$runpath_var" && test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - rpath="$rpath$dir:" - done - eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" - fi - test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" - fi - shlibpath="$finalize_shlibpath" - test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" - if test -n "$shlibpath"; then - eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" - fi +# func_generate_dlsyms outputname originator pic_p +# Extract symbols from dlprefiles and create ${outputname}S.o with +# a dlpreopen symbol table. +func_generate_dlsyms () +{ + $opt_debug + my_outputname="$1" + my_originator="$2" + my_pic_p="${3-no}" + my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'` + my_dlsyms= + + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + if test -n "$NM" && test -n "$global_symbol_pipe"; then + my_dlsyms="${my_outputname}S.c" + else + func_error "not configured to extract global symbols from dlpreopened files" + fi + fi - # Get the real and link names of the library. - eval shared_ext=\"$shrext_cmds\" - eval library_names=\"$library_names_spec\" - set dummy $library_names - realname="$2" - shift; shift + if test -n "$my_dlsyms"; then + case $my_dlsyms in + "") ;; + *.c) + # Discover the nlist of each of the dlfiles. + nlist="$output_objdir/${my_outputname}.nm" - if test -n "$soname_spec"; then - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - if test -z "$dlname"; then - dlname=$soname - fi + func_show_eval "$RM $nlist ${nlist}S ${nlist}T" - lib="$output_objdir/$realname" - linknames= - for link - do - linknames="$linknames $link" - done + # Parse the name list into a source file. + func_verbose "creating $output_objdir/$my_dlsyms" - # Use standard objects if they are pic - test -z "$pic_flag" && libobjs=`$echo "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` + $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ +/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */ +/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */ - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then - $show "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $run $rm $export_symbols - cmds=$export_symbols_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - if len=`expr "X$cmd" : ".*"` && - test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then - $show "$cmd" - $run eval "$cmd" || exit $? - skipped_export=false - else - # The command line is too long to execute in one step. - $show "using reloadable object file for export list..." - skipped_export=: - # Break out early, otherwise skipped_export may be - # set to false by a later but shorter cmd. - break - fi - done - IFS="$save_ifs" - if test -n "$export_symbols_regex"; then - $show "$EGREP -e \"$export_symbols_regex\" \"$export_symbols\" > \"${export_symbols}T\"" - $run eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - $show "$mv \"${export_symbols}T\" \"$export_symbols\"" - $run eval '$mv "${export_symbols}T" "$export_symbols"' - fi - fi - fi +#ifdef __cplusplus +extern \"C\" { +#endif - if test -n "$export_symbols" && test -n "$include_expsyms"; then - $run eval '$echo "X$include_expsyms" | $SP2NL >> "$export_symbols"' - fi +#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) +#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" +#endif - tmp_deplibs= - for test_deplib in $deplibs; do - case " $convenience " in - *" $test_deplib "*) ;; - *) - tmp_deplibs="$tmp_deplibs $test_deplib" - ;; - esac - done - deplibs="$tmp_deplibs" +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - else - gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" +/* External symbol declarations for the compiler. */\ +" - func_extract_archives $gentop $convenience - libobjs="$libobjs $func_extract_archives_result" - fi - fi - - if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then - eval flag=\"$thread_safe_flag_spec\" - linker_flags="$linker_flags $flag" - fi + if test "$dlself" = yes; then + func_verbose "generating symbol list for \`$output'" - # Make a backup of the uninstalled library when relinking - if test "$mode" = relink; then - $run eval '(cd $output_objdir && $rm ${realname}U && $mv $realname ${realname}U)' || exit $? - fi + $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - eval test_cmds=\"$module_expsym_cmds\" - cmds=$module_expsym_cmds - else - eval test_cmds=\"$module_cmds\" - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - eval test_cmds=\"$archive_expsym_cmds\" - cmds=$archive_expsym_cmds - else - eval test_cmds=\"$archive_cmds\" - cmds=$archive_cmds - fi - fi - - if test "X$skipped_export" != "X:" && - len=`expr "X$test_cmds" : ".*" 2>/dev/null` && - test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then - : - else - # The command line is too long to link in one step, link piecewise. - $echo "creating reloadable object files..." - - # Save the value of $output and $libobjs because we want to - # use them later. If we have whole_archive_flag_spec, we - # want to use save_libobjs as it was before - # whole_archive_flag_spec was expanded, because we can't - # assume the linker understands whole_archive_flag_spec. - # This may have to be revisited, in case too many - # convenience libraries get linked in and end up exceeding - # the spec. - if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - fi - save_output=$output - output_la=`$echo "X$output" | $Xsed -e "$basename"` - - # Clear the reloadable object creation command queue and - # initialize k to one. - test_cmds= - concat_cmds= - objlist= - delfiles= - last_robj= - k=1 - output=$output_objdir/$output_la-${k}.$objext - # Loop over the list of objects to be linked. - for obj in $save_libobjs - do - eval test_cmds=\"$reload_cmds $objlist $last_robj\" - if test "X$objlist" = X || - { len=`expr "X$test_cmds" : ".*" 2>/dev/null` && - test "$len" -le "$max_cmd_len"; }; then - objlist="$objlist $obj" - else - # The command $test_cmds is almost too long, add a - # command to the queue. - if test "$k" -eq 1 ; then - # The first file doesn't have a previous command to add. - eval concat_cmds=\"$reload_cmds $objlist $last_robj\" - else - # All subsequent reloadable object files will link in - # the last one created. - eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj\" - fi - last_robj=$output_objdir/$output_la-${k}.$objext - k=`expr $k + 1` - output=$output_objdir/$output_la-${k}.$objext - objlist=$obj - len=1 - fi - done - # Handle the remaining objects by creating one last - # reloadable object file. All subsequent reloadable object - # files will link in the last one created. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\" - - if ${skipped_export-false}; then - $show "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $run $rm $export_symbols - libobjs=$output - # Append the command to create the export file. - eval concat_cmds=\"\$concat_cmds~$export_symbols_cmds\" - fi - - # Set up a command to remove the reloadable object files - # after they are used. - i=0 - while test "$i" -lt "$k" - do - i=`expr $i + 1` - delfiles="$delfiles $output_objdir/$output_la-${i}.$objext" - done - - $echo "creating a temporary reloadable object file: $output" - - # Loop through the commands generated above and execute them. - save_ifs="$IFS"; IFS='~' - for cmd in $concat_cmds; do - IFS="$save_ifs" - $show "$cmd" - $run eval "$cmd" || exit $? + # Add our own program objects to the symbol list. + progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` + for progfile in $progfiles; do + func_to_tool_file "$progfile" func_convert_file_msys_to_w32 + func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" + $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" done - IFS="$save_ifs" - libobjs=$output - # Restore the value of output. - output=$save_output + if test -n "$exclude_expsyms"; then + $opt_dry_run || { + eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } + fi - if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + if test -n "$export_symbols_regex"; then + $opt_dry_run || { + eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } fi - # Expand the library linking commands again to reset the - # value of $libobjs for piecewise linking. - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - cmds=$module_expsym_cmds - else - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - cmds=$archive_expsym_cmds + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + export_symbols="$output_objdir/$outputname.exp" + $opt_dry_run || { + $RM $export_symbols + eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' + ;; + esac + } else - cmds=$archive_cmds - fi + $opt_dry_run || { + eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' + eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' + ;; + esac + } fi - - # Append the command to remove the reloadable object files - # to the just-reset $cmds. - eval cmds=\"\$cmds~\$rm $delfiles\" fi - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || { - lt_exit=$? - # Restore the uninstalled library and exit - if test "$mode" = relink; then - $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' - fi - - exit $lt_exit - } + for dlprefile in $dlprefiles; do + func_verbose "extracting global C symbols from \`$dlprefile'" + func_basename "$dlprefile" + name="$func_basename_result" + case $host in + *cygwin* | *mingw* | *cegcc* ) + # if an import library, we need to obtain dlname + if func_win32_import_lib_p "$dlprefile"; then + func_tr_sh "$dlprefile" + eval "curr_lafile=\$libfile_$func_tr_sh_result" + dlprefile_dlbasename="" + if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then + # Use subshell, to avoid clobbering current variable values + dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` + if test -n "$dlprefile_dlname" ; then + func_basename "$dlprefile_dlname" + dlprefile_dlbasename="$func_basename_result" + else + # no lafile. user explicitly requested -dlpreopen . + $sharedlib_from_linklib_cmd "$dlprefile" + dlprefile_dlbasename=$sharedlib_from_linklib_result + fi + fi + $opt_dry_run || { + if test -n "$dlprefile_dlbasename" ; then + eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' + else + func_warning "Could not compute DLL name from $name" + eval '$ECHO ": $name " >> "$nlist"' + fi + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | + $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" + } + else # not an import lib + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + fi + ;; + *) + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + ;; + esac done - IFS="$save_ifs" - # Restore the uninstalled library and exit - if test "$mode" = relink; then - $run eval '(cd $output_objdir && $rm ${realname}T && $mv $realname ${realname}T && $mv "$realname"U $realname)' || exit $? + $opt_dry_run || { + # Make sure we have at least an empty file. + test -f "$nlist" || : > "$nlist" - if test -n "$convenience"; then - if test -z "$whole_archive_flag_spec"; then - $show "${rm}r $gentop" - $run ${rm}r "$gentop" - fi + if test -n "$exclude_expsyms"; then + $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T + $MV "$nlist"T "$nlist" fi - exit $EXIT_SUCCESS - fi + # Try sorting and uniquifying the output. + if $GREP -v "^: " < "$nlist" | + if sort -k 3 /dev/null 2>&1; then + sort -k 3 + else + sort +2 + fi | + uniq > "$nlist"S; then + : + else + $GREP -v "^: " < "$nlist" > "$nlist"S + fi - # Create links to the real library. - for linkname in $linknames; do - if test "$realname" != "$linkname"; then - $show "(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)" - $run eval '(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)' || exit $? + if test -f "$nlist"S; then + eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' + else + echo '/* NONE */' >> "$output_objdir/$my_dlsyms" fi - done - # If -module or -export-dynamic was specified, set the dlname. - if test "$module" = yes || test "$export_dynamic" = yes; then - # On all known operating systems, these are identical. - dlname="$soname" - fi - fi - ;; + echo >> "$output_objdir/$my_dlsyms" "\ - obj) - if test -n "$deplibs"; then - $echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2 - fi +/* The mapping between symbol names and symbols. */ +typedef struct { + const char *name; + void *address; +} lt_dlsymlist; +extern LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[]; +LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[] = +{\ + { \"$my_originator\", (void *) 0 }," - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - $echo "$modename: warning: \`-dlopen' is ignored for objects" 1>&2 - fi + case $need_lib_prefix in + no) + eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + *) + eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + esac + echo >> "$output_objdir/$my_dlsyms" "\ + {0, (void *) 0} +}; - if test -n "$rpath"; then - $echo "$modename: warning: \`-rpath' is ignored for objects" 1>&2 - fi +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt_${my_prefix}_LTX_preloaded_symbols; +} +#endif - if test -n "$xrpath"; then - $echo "$modename: warning: \`-R' is ignored for objects" 1>&2 - fi +#ifdef __cplusplus +} +#endif\ +" + } # !$opt_dry_run - if test -n "$vinfo"; then - $echo "$modename: warning: \`-version-info' is ignored for objects" 1>&2 - fi + pic_flag_for_symtable= + case "$compile_command " in + *" -static "*) ;; + *) + case $host in + # compiling the symbol table file with pic_flag works around + # a FreeBSD bug that causes programs to crash when -lm is + # linked before any other PIC object. But we must not use + # pic_flag when linking with -static. The problem exists in + # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. + *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) + pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; + *-*-hpux*) + pic_flag_for_symtable=" $pic_flag" ;; + *) + if test "X$my_pic_p" != Xno; then + pic_flag_for_symtable=" $pic_flag" + fi + ;; + esac + ;; + esac + symtab_cflags= + for arg in $LTCFLAGS; do + case $arg in + -pie | -fpie | -fPIE) ;; + *) func_append symtab_cflags " $arg" ;; + esac + done - if test -n "$release"; then - $echo "$modename: warning: \`-release' is ignored for objects" 1>&2 - fi + # Now compile the dynamic symbol file. + func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' - case $output in - *.lo) - if test -n "$objs$old_deplibs"; then - $echo "$modename: cannot build library object \`$output' from non-libtool objects" 1>&2 - exit $EXIT_FAILURE - fi - libobj="$output" - obj=`$echo "X$output" | $Xsed -e "$lo2o"` + # Clean up the generated files. + func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"' + + # Transform the symbol file into the correct name. + symfileobj="$output_objdir/${my_outputname}S.$objext" + case $host in + *cygwin* | *mingw* | *cegcc* ) + if test -f "$output_objdir/$my_outputname.def"; then + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + else + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + fi + ;; + *) + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + ;; + esac ;; *) - libobj= - obj="$output" + func_fatal_error "unknown suffix for \`$my_dlsyms'" ;; esac + else + # We keep going just in case the user didn't refer to + # lt_preloaded_symbols. The linker will fail if global_symbol_pipe + # really was required. - # Delete the old objects. - $run $rm $obj $libobj + # Nullify the symbol file. + compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` + fi +} - # Objects from convenience libraries. This assumes - # single-version convenience libraries. Whenever we create - # different ones for PIC/non-PIC, this we'll have to duplicate - # the extraction. - reload_conv_objs= - gentop= - # reload_cmds runs $LD directly, so let us get rid of - # -Wl from whole_archive_flag_spec - wl= +# func_win32_libid arg +# return the library type of file 'arg' +# +# Need a lot of goo to handle *both* DLLs and import libs +# Has to be a shell function in order to 'eat' the argument +# that is supplied when $file_magic_command is called. +# Despite the name, also deal with 64 bit binaries. +func_win32_libid () +{ + $opt_debug + win32_libid_type="unknown" + win32_fileres=`file -L $1 2>/dev/null` + case $win32_fileres in + *ar\ archive\ import\ library*) # definitely import + win32_libid_type="x86 archive import" + ;; + *ar\ archive*) # could be an import, or static + # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. + if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | + $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then + func_to_tool_file "$1" func_convert_file_msys_to_w32 + win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | + $SED -n -e ' + 1,100{ + / I /{ + s,.*,import, + p + q + } + }'` + case $win32_nmres in + import*) win32_libid_type="x86 archive import";; + *) win32_libid_type="x86 archive static";; + esac + fi + ;; + *DLL*) + win32_libid_type="x86 DLL" + ;; + *executable*) # but shell scripts are "executable" too... + case $win32_fileres in + *MS\ Windows\ PE\ Intel*) + win32_libid_type="x86 DLL" + ;; + esac + ;; + esac + $ECHO "$win32_libid_type" +} - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec"; then - eval reload_conv_objs=\"\$reload_objs $whole_archive_flag_spec\" - else - gentop="$output_objdir/${obj}x" - generated="$generated $gentop" +# func_cygming_dll_for_implib ARG +# +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib () +{ + $opt_debug + sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` +} - func_extract_archives $gentop $convenience - reload_conv_objs="$reload_objs $func_extract_archives_result" - fi - fi +# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs +# +# The is the core of a fallback implementation of a +# platform-specific function to extract the name of the +# DLL associated with the specified import library LIBNAME. +# +# SECTION_NAME is either .idata$6 or .idata$7, depending +# on the platform and compiler that created the implib. +# +# Echos the name of the DLL associated with the +# specified import library. +func_cygming_dll_for_implib_fallback_core () +{ + $opt_debug + match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` + $OBJDUMP -s --section "$1" "$2" 2>/dev/null | + $SED '/^Contents of section '"$match_literal"':/{ + # Place marker at beginning of archive member dllname section + s/.*/====MARK====/ + p + d + } + # These lines can sometimes be longer than 43 characters, but + # are always uninteresting + /:[ ]*file format pe[i]\{,1\}-/d + /^In archive [^:]*:/d + # Ensure marker is printed + /^====MARK====/p + # Remove all lines with less than 43 characters + /^.\{43\}/!d + # From remaining lines, remove first 43 characters + s/^.\{43\}//' | + $SED -n ' + # Join marker and all lines until next marker into a single line + /^====MARK====/ b para + H + $ b para + b + :para + x + s/\n//g + # Remove the marker + s/^====MARK====// + # Remove trailing dots and whitespace + s/[\. \t]*$// + # Print + /./p' | + # we now have a list, one entry per line, of the stringified + # contents of the appropriate section of all members of the + # archive which possess that section. Heuristic: eliminate + # all those which have a first or second character that is + # a '.' (that is, objdump's representation of an unprintable + # character.) This should work for all archives with less than + # 0x302f exports -- but will fail for DLLs whose name actually + # begins with a literal '.' or a single character followed by + # a '.'. + # + # Of those that remain, print the first one. + $SED -e '/^\./d;/^.\./d;q' +} - # Create the old-style object. - reload_objs="$objs$old_deplibs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test +# func_cygming_gnu_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is a GNU/binutils-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_gnu_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` + test -n "$func_cygming_gnu_implib_tmp" +} - output="$obj" - cmds=$reload_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || exit $? - done - IFS="$save_ifs" +# func_cygming_ms_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is an MS-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_ms_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` + test -n "$func_cygming_ms_implib_tmp" +} - # Exit if we aren't doing a library object file. - if test -z "$libobj"; then - if test -n "$gentop"; then - $show "${rm}r $gentop" - $run ${rm}r $gentop - fi +# func_cygming_dll_for_implib_fallback ARG +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# +# This fallback implementation is for use when $DLLTOOL +# does not support the --identify-strict option. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib_fallback () +{ + $opt_debug + if func_cygming_gnu_implib_p "$1" ; then + # binutils import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` + elif func_cygming_ms_implib_p "$1" ; then + # ms-generated import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` + else + # unknown + sharedlib_from_linklib_result="" + fi +} - exit $EXIT_SUCCESS - fi - if test "$build_libtool_libs" != yes; then - if test -n "$gentop"; then - $show "${rm}r $gentop" - $run ${rm}r $gentop - fi - - # Create an invalid libtool object if no PIC, so that we don't - # accidentally link it into a program. - # $show "echo timestamp > $libobj" - # $run eval "echo timestamp > $libobj" || exit $? - exit $EXIT_SUCCESS - fi - - if test -n "$pic_flag" || test "$pic_mode" != default; then - # Only do commands if we really have different PIC objects. - reload_objs="$libobjs $reload_conv_objs" - output="$libobj" - cmds=$reload_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || exit $? - done - IFS="$save_ifs" - fi +# func_extract_an_archive dir oldlib +func_extract_an_archive () +{ + $opt_debug + f_ex_an_ar_dir="$1"; shift + f_ex_an_ar_oldlib="$1" + if test "$lock_old_archive_extraction" = yes; then + lockfile=$f_ex_an_ar_oldlib.lock + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + fi + func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ + 'stat=$?; rm -f "$lockfile"; exit $stat' + if test "$lock_old_archive_extraction" = yes; then + $opt_dry_run || rm -f "$lockfile" + fi + if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then + : + else + func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" + fi +} - if test -n "$gentop"; then - $show "${rm}r $gentop" - $run ${rm}r $gentop - fi - exit $EXIT_SUCCESS - ;; +# func_extract_archives gentop oldlib ... +func_extract_archives () +{ + $opt_debug + my_gentop="$1"; shift + my_oldlibs=${1+"$@"} + my_oldobjs="" + my_xlib="" + my_xabs="" + my_xdir="" - prog) - case $host in - *cygwin*) output=`$echo $output | ${SED} -e 's,.exe$,,;s,$,.exe,'` ;; + for my_xlib in $my_oldlibs; do + # Extract the objects. + case $my_xlib in + [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; + *) my_xabs=`pwd`"/$my_xlib" ;; esac - if test -n "$vinfo"; then - $echo "$modename: warning: \`-version-info' is ignored for programs" 1>&2 - fi - - if test -n "$release"; then - $echo "$modename: warning: \`-release' is ignored for programs" 1>&2 - fi + func_basename "$my_xlib" + my_xlib="$func_basename_result" + my_xlib_u=$my_xlib + while :; do + case " $extracted_archives " in + *" $my_xlib_u "*) + func_arith $extracted_serial + 1 + extracted_serial=$func_arith_result + my_xlib_u=lt$extracted_serial-$my_xlib ;; + *) break ;; + esac + done + extracted_archives="$extracted_archives $my_xlib_u" + my_xdir="$my_gentop/$my_xlib_u" - if test "$preload" = yes; then - if test "$dlopen_support" = unknown && test "$dlopen_self" = unknown && - test "$dlopen_self_static" = unknown; then - $echo "$modename: warning: \`AC_LIBTOOL_DLOPEN' not used. Assuming no dlopen support." - fi - fi + func_mkdir_p "$my_xdir" case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library is the System framework - compile_deplibs=`$echo "X $compile_deplibs" | $Xsed -e 's/ -lc / -framework System /'` - finalize_deplibs=`$echo "X $finalize_deplibs" | $Xsed -e 's/ -lc / -framework System /'` + *-darwin*) + func_verbose "Extracting $my_xabs" + # Do not bother doing anything if just a dry run + $opt_dry_run || { + darwin_orig_dir=`pwd` + cd $my_xdir || exit $? + darwin_archive=$my_xabs + darwin_curdir=`pwd` + darwin_base_archive=`basename "$darwin_archive"` + darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` + if test -n "$darwin_arches"; then + darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` + darwin_arch= + func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" + for darwin_arch in $darwin_arches ; do + func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}" + $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" + cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" + func_extract_an_archive "`pwd`" "${darwin_base_archive}" + cd "$darwin_curdir" + $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" + done # $darwin_arches + ## Okay now we've a bunch of thin objects, gotta fatten them up :) + darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u` + darwin_file= + darwin_files= + for darwin_file in $darwin_filelist; do + darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` + $LIPO -create -output "$darwin_file" $darwin_files + done # $darwin_filelist + $RM -rf unfat-$$ + cd "$darwin_orig_dir" + else + cd $darwin_orig_dir + func_extract_an_archive "$my_xdir" "$my_xabs" + fi # $darwin_arches + } # !$opt_dry_run + ;; + *) + func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac + my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` + done - case $host in - *darwin*) - # Don't allow lazy linking, it breaks C++ global constructors - if test "$tagname" = CXX ; then - compile_command="$compile_command ${wl}-bind_at_load" - finalize_command="$finalize_command ${wl}-bind_at_load" - fi - ;; - esac - + func_extract_archives_result="$my_oldobjs" +} - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac - ;; - *) new_libs="$new_libs $deplib" ;; - esac - done - compile_deplibs="$new_libs" +# func_emit_wrapper [arg=no] +# +# Emit a libtool wrapper script on stdout. +# Don't directly open a file because we may want to +# incorporate the script contents within a cygwin/mingw +# wrapper executable. Must ONLY be called from within +# func_mode_link because it depends on a number of variables +# set therein. +# +# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR +# variable will take. If 'yes', then the emitted script +# will assume that the directory in which it is stored is +# the $objdir directory. This is a cygwin/mingw-specific +# behavior. +func_emit_wrapper () +{ + func_emit_wrapper_arg1=${1-no} - compile_command="$compile_command $compile_deplibs" - finalize_command="$finalize_command $finalize_deplibs" + $ECHO "\ +#! $SHELL - if test -n "$rpath$xrpath"; then - # If the user specified any rpath flags, then add them. - for libdir in $rpath $xrpath; do - # This is the magic to use -rpath. - case "$finalize_rpath " in - *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" ;; - esac - done - fi +# $output - temporary wrapper script for $objdir/$outputname +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION +# +# The $output program cannot be directly executed until all the libtool +# libraries that it depends on are installed. +# +# This wrapper script should never be moved out of the build directory. +# If it is, it will not operate correctly. - # Now hardcode the library paths - rpath= - hardcode_libdirs= - for libdir in $compile_rpath $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - rpath="$rpath $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) perm_rpath="$perm_rpath $libdir" ;; - esac - fi - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$libdir:"*) ;; - *) dllsearchpath="$dllsearchpath:$libdir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; - esac - ;; - esac - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - compile_rpath="$rpath" +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +sed_quote_subst='$sed_quote_subst' - rpath= - hardcode_libdirs= - for libdir in $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - rpath="$rpath $flag" - fi - elif test -n "$runpath_var"; then - case "$finalize_perm_rpath " in - *" $libdir "*) ;; - *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - finalize_rpath="$rpath" +# Be Bourne compatible +if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh - if test -n "$libobjs" && test "$build_old_libs" = yes; then - # Transform all the library objects into standard objects. - compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - fi +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - dlsyms= - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - if test -n "$NM" && test -n "$global_symbol_pipe"; then - dlsyms="${outputname}S.c" - else - $echo "$modename: not configured to extract global symbols from dlpreopened files" 1>&2 - fi - fi +relink_command=\"$relink_command\" - if test -n "$dlsyms"; then - case $dlsyms in - "") ;; - *.c) - # Discover the nlist of each of the dlfiles. - nlist="$output_objdir/${outputname}.nm" +# This environment variable determines our operation mode. +if test \"\$libtool_install_magic\" = \"$magic\"; then + # install mode needs the following variables: + generated_by_libtool_version='$macro_version' + notinst_deplibs='$notinst_deplibs' +else + # When we are sourced in execute mode, \$file and \$ECHO are already set. + if test \"\$libtool_execute_magic\" != \"$magic\"; then + file=\"\$0\"" - $show "$rm $nlist ${nlist}S ${nlist}T" - $run $rm "$nlist" "${nlist}S" "${nlist}T" + qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` + $ECHO "\ - # Parse the name list into a source file. - $show "creating $output_objdir/$dlsyms" +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + ECHO=\"$qECHO\" + fi - test -z "$run" && $echo > "$output_objdir/$dlsyms" "\ -/* $dlsyms - symbol resolution table for \`$outputname' dlsym emulation. */ -/* Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP */ +# Very basic option parsing. These options are (a) specific to +# the libtool wrapper, (b) are identical between the wrapper +# /script/ and the wrapper /executable/ which is used only on +# windows platforms, and (c) all begin with the string "--lt-" +# (application programs are unlikely to have options which match +# this pattern). +# +# There are only two supported options: --lt-debug and +# --lt-dump-script. There is, deliberately, no --lt-help. +# +# The first argument to this parsing function should be the +# script's $0 value, followed by "$@". +lt_option_debug= +func_parse_lt_options () +{ + lt_script_arg0=\$0 + shift + for lt_opt + do + case \"\$lt_opt\" in + --lt-debug) lt_option_debug=1 ;; + --lt-dump-script) + lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` + test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. + lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` + cat \"\$lt_dump_D/\$lt_dump_F\" + exit 0 + ;; + --lt-*) + \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 + exit 1 + ;; + esac + done -#ifdef __cplusplus -extern \"C\" { -#endif + # Print the debug banner immediately: + if test -n \"\$lt_option_debug\"; then + echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2 + fi +} -/* Prevent the only kind of declaration conflicts we can make. */ -#define lt_preloaded_symbols some_other_symbol +# Used when --lt-debug. Prints its arguments to stdout +# (redirection is the responsibility of the caller) +func_lt_dump_args () +{ + lt_dump_args_N=1; + for lt_arg + do + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\" + lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` + done +} -/* External symbol declarations for the compiler. */\ +# Core function for launching the target application +func_exec_program_core () +{ " - - if test "$dlself" = yes; then - $show "generating symbol list for \`$output'" - - test -z "$run" && $echo ': @PROGRAM@ ' > "$nlist" - - # Add our own program objects to the symbol list. - progfiles=`$echo "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - for arg in $progfiles; do - $show "extracting global C symbols from \`$arg'" - $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" - done - - if test -n "$exclude_expsyms"; then - $run eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' - $run eval '$mv "$nlist"T "$nlist"' - fi - - if test -n "$export_symbols_regex"; then - $run eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' - $run eval '$mv "$nlist"T "$nlist"' - fi - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - export_symbols="$output_objdir/$outputname.exp" - $run $rm $export_symbols - $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* ) - $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - $run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac - else - $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' - $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' - $run eval 'mv "$nlist"T "$nlist"' - case $host in - *cygwin* | *mingw* ) - $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - $run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac - fi - fi - - for arg in $dlprefiles; do - $show "extracting global C symbols from \`$arg'" - name=`$echo "$arg" | ${SED} -e 's%^.*/%%'` - $run eval '$echo ": $name " >> "$nlist"' - $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" - done - - if test -z "$run"; then - # Make sure we have at least an empty file. - test -f "$nlist" || : > "$nlist" - - if test -n "$exclude_expsyms"; then - $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T - $mv "$nlist"T "$nlist" - fi - - # Try sorting and uniquifying the output. - if grep -v "^: " < "$nlist" | - if sort -k 3 /dev/null 2>&1; then - sort -k 3 - else - sort +2 - fi | - uniq > "$nlist"S; then - : - else - grep -v "^: " < "$nlist" > "$nlist"S - fi - - if test -f "$nlist"S; then - eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$dlsyms"' - else - $echo '/* NONE */' >> "$output_objdir/$dlsyms" - fi - - $echo >> "$output_objdir/$dlsyms" "\ - -#undef lt_preloaded_symbols - -#if defined (__STDC__) && __STDC__ -# define lt_ptr void * -#else -# define lt_ptr char * -# define const -#endif - -/* The mapping between symbol names and symbols. */ -" - - case $host in - *cygwin* | *mingw* ) - $echo >> "$output_objdir/$dlsyms" "\ -/* DATA imports from DLLs on WIN32 can't be const, because - runtime relocations are performed -- see ld's documentation - on pseudo-relocs */ -struct { -" - ;; - * ) - $echo >> "$output_objdir/$dlsyms" "\ -const struct { + case $host in + # Backslashes separate directories on plain windows + *-*-mingw | *-*-os2* | *-cegcc*) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} " - ;; - esac - + ;; - $echo >> "$output_objdir/$dlsyms" "\ - const char *name; - lt_ptr address; -} -lt_preloaded_symbols[] = -{\ + *) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir/\$program\" \${1+\"\$@\"} " - - eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$dlsyms" - - $echo >> "$output_objdir/$dlsyms" "\ - {0, (lt_ptr) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt_preloaded_symbols; + ;; + esac + $ECHO "\ + \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 + exit 1 } -#endif -#ifdef __cplusplus +# A function to encapsulate launching the target application +# Strips options in the --lt-* namespace from \$@ and +# launches target application with the remaining arguments. +func_exec_program () +{ + for lt_wr_arg + do + case \$lt_wr_arg in + --lt-*) ;; + *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; + esac + shift + done + func_exec_program_core \${1+\"\$@\"} } -#endif\ -" - fi - pic_flag_for_symtable= - case $host in - # compiling the symbol table file with pic_flag works around - # a FreeBSD bug that causes programs to crash when -lm is - # linked before any other PIC object. But we must not use - # pic_flag when linking with -static. The problem exists in - # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. - *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) - case "$compile_command " in - *" -static "*) ;; - *) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND";; - esac;; - *-*-hpux*) - case "$compile_command " in - *" -static "*) ;; - *) pic_flag_for_symtable=" $pic_flag";; - esac - esac + # Parse options + func_parse_lt_options \"\$0\" \${1+\"\$@\"} - # Now compile the dynamic symbol file. - $show "(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" - $run eval '(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? + # Find the directory that this script lives in. + thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` + test \"x\$thisdir\" = \"x\$file\" && thisdir=. - # Clean up the generated files. - $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T" - $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T" + # Follow symbolic links until we get to the real thisdir. + file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` + while test -n \"\$file\"; do + destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` - # Transform the symbol file into the correct name. - case $host in - *cygwin* | *mingw* ) - if test -f "$output_objdir/${outputname}.def" ; then - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%"` - else - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - fi - ;; - * ) - compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` - ;; - esac - ;; - *) - $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2 - exit $EXIT_FAILURE - ;; - esac - else - # We keep going just in case the user didn't refer to - # lt_preloaded_symbols. The linker will fail if global_symbol_pipe - # really was required. + # If there was a directory component, then change thisdir. + if test \"x\$destdir\" != \"x\$file\"; then + case \"\$destdir\" in + [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; + *) thisdir=\"\$thisdir/\$destdir\" ;; + esac + fi - # Nullify the symbol file. - compile_command=`$echo "X$compile_command" | $Xsed -e "s% @SYMFILE@%%"` - finalize_command=`$echo "X$finalize_command" | $Xsed -e "s% @SYMFILE@%%"` - fi + file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` + file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` + done - if test "$need_relink" = no || test "$build_libtool_libs" != yes; then - # Replace the output file specification. - compile_command=`$echo "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` - link_command="$compile_command$compile_rpath" + # Usually 'no', except on cygwin/mingw when embedded into + # the cwrapper. + WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 + if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then + # special case for '.' + if test \"\$thisdir\" = \".\"; then + thisdir=\`pwd\` + fi + # remove .libs from thisdir + case \"\$thisdir\" in + *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; + $objdir ) thisdir=. ;; + esac + fi - # We have no uninstalled library dependencies, so finalize right now. - $show "$link_command" - $run eval "$link_command" - exit_status=$? + # Try to get the absolute directory name. + absdir=\`cd \"\$thisdir\" && pwd\` + test -n \"\$absdir\" && thisdir=\"\$absdir\" +" - # Delete the generated files. - if test -n "$dlsyms"; then - $show "$rm $output_objdir/${outputname}S.${objext}" - $run $rm "$output_objdir/${outputname}S.${objext}" - fi + if test "$fast_install" = yes; then + $ECHO "\ + program=lt-'$outputname'$exeext + progdir=\"\$thisdir/$objdir\" - exit $exit_status - fi + if test ! -f \"\$progdir/\$program\" || + { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ + test \"X\$file\" != \"X\$progdir/\$program\"; }; then - if test -n "$shlibpath_var"; then - # We should set the shlibpath_var - rpath= - for dir in $temp_rpath; do - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) - # Absolute path. - rpath="$rpath$dir:" - ;; - *) - # Relative path: add a thisdir entry. - rpath="$rpath\$thisdir/$dir:" - ;; - esac - done - temp_rpath="$rpath" - fi + file=\"\$\$-\$program\" - if test -n "$compile_shlibpath$finalize_shlibpath"; then - compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" - fi - if test -n "$finalize_shlibpath"; then - finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" - fi + if test ! -d \"\$progdir\"; then + $MKDIR \"\$progdir\" + else + $RM \"\$progdir/\$file\" + fi" - compile_var= - finalize_var= - if test -n "$runpath_var"; then - if test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - rpath="$rpath$dir:" - done - compile_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - if test -n "$finalize_perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $finalize_perm_rpath; do - rpath="$rpath$dir:" - done - finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - fi + $ECHO "\ - if test "$no_install" = yes; then - # We don't need to create a wrapper script. - link_command="$compile_var$compile_command$compile_rpath" - # Replace the output file specification. - link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` - # Delete the old output file. - $run $rm $output - # Link the executable and exit - $show "$link_command" - $run eval "$link_command" || exit $? - exit $EXIT_SUCCESS + # relink executable if necessary + if test -n \"\$relink_command\"; then + if relink_command_output=\`eval \$relink_command 2>&1\`; then : + else + $ECHO \"\$relink_command_output\" >&2 + $RM \"\$progdir/\$file\" + exit 1 fi + fi - if test "$hardcode_action" = relink; then - # Fast installation is not supported - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" - - $echo "$modename: warning: this platform does not like uninstalled shared libraries" 1>&2 - $echo "$modename: \`$output' will be relinked during installation" 1>&2 - else - if test "$fast_install" != no; then - link_command="$finalize_var$compile_command$finalize_rpath" - if test "$fast_install" = yes; then - relink_command=`$echo "X$compile_var$compile_command$compile_rpath" | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g'` - else - # fast_install is set to needless - relink_command= - fi + $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || + { $RM \"\$progdir/\$program\"; + $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } + $RM \"\$progdir/\$file\" + fi" else - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" + $ECHO "\ + program='$outputname' + progdir=\"\$thisdir/$objdir\" +" fi - fi - # Replace the output file specification. - link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` + $ECHO "\ - # Delete the old output files. - $run $rm $output $output_objdir/$outputname $output_objdir/lt-$outputname + if test -f \"\$progdir/\$program\"; then" - $show "$link_command" - $run eval "$link_command" || exit $? + # fixup the dll searchpath if we need to. + # + # Fix the DLL searchpath if we need to. Do this before prepending + # to shlibpath, because on Windows, both are PATH and uninstalled + # libraries must come first. + if test -n "$dllsearchpath"; then + $ECHO "\ + # Add the dll search path components to the executable PATH + PATH=$dllsearchpath:\$PATH +" + fi - # Now create the wrapper script. - $show "creating $output" + # Export our shlibpath_var if we have one. + if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then + $ECHO "\ + # Add our own library path to $shlibpath_var + $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" - # Quote the relink command for shipping. - if test -n "$relink_command"; then - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` - relink_command="$var=\"$var_value\"; export $var; $relink_command" - fi - done - relink_command="(cd `pwd`; $relink_command)" - relink_command=`$echo "X$relink_command" | $Xsed -e "$sed_quote_subst"` - fi + # Some systems cannot cope with colon-terminated $shlibpath_var + # The second colon is a workaround for a bug in BeOS R4 sed + $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` - # Quote $echo for shipping. - if test "X$echo" = "X$SHELL $progpath --fallback-echo"; then - case $progpath in - [\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";; - *) qecho="$SHELL `pwd`/$progpath --fallback-echo";; - esac - qecho=`$echo "X$qecho" | $Xsed -e "$sed_quote_subst"` - else - qecho=`$echo "X$echo" | $Xsed -e "$sed_quote_subst"` - fi + export $shlibpath_var +" + fi + + $ECHO "\ + if test \"\$libtool_execute_magic\" != \"$magic\"; then + # Run the actual program with our arguments. + func_exec_program \${1+\"\$@\"} + fi + else + # The program doesn't exist. + \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 + \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 + \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 + exit 1 + fi +fi\ +" +} - # Only actually do things if our run command is non-null. - if test -z "$run"; then - # win32 will think the script is a binary if it has - # a .exe suffix, so we strip it off here. - case $output in - *.exe) output=`$echo $output|${SED} 's,.exe$,,'` ;; - esac - # test for cygwin because mv fails w/o .exe extensions - case $host in - *cygwin*) - exeext=.exe - outputname=`$echo $outputname|${SED} 's,.exe$,,'` ;; - *) exeext= ;; - esac - case $host in - *cygwin* | *mingw* ) - output_name=`basename $output` - output_path=`dirname $output` - cwrappersource="$output_path/$objdir/lt-$output_name.c" - cwrapper="$output_path/$output_name.exe" - $rm $cwrappersource $cwrapper - trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 - cat > $cwrappersource <> $cwrappersource<<"EOF" + cat <<"EOF" +#ifdef _MSC_VER +# define _CRT_SECURE_NO_DEPRECATE 1 +#endif #include #include -#include +#ifdef _MSC_VER +# include +# include +# include +#else +# include +# include +# ifdef __CYGWIN__ +# include +# endif +#endif #include #include #include #include #include +#include +#include #include +/* declarations of non-ANSI functions */ +#if defined(__MINGW32__) +# ifdef __STRICT_ANSI__ +int _putenv (const char *); +# endif +#elif defined(__CYGWIN__) +# ifdef __STRICT_ANSI__ +char *realpath (const char *, char *); +int putenv (char *); +int setenv (const char *, const char *, int); +# endif +/* #elif defined (other platforms) ... */ +#endif + +/* portability defines, excluding path handling macros */ +#if defined(_MSC_VER) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +# define S_IXUSR _S_IEXEC +# ifndef _INTPTR_T_DEFINED +# define _INTPTR_T_DEFINED +# define intptr_t int +# endif +#elif defined(__MINGW32__) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +#elif defined(__CYGWIN__) +# define HAVE_SETENV +# define FOPEN_WB "wb" +/* #elif defined (other platforms) ... */ +#endif + #if defined(PATH_MAX) # define LT_PATHMAX PATH_MAX #elif defined(MAXPATHLEN) @@ -4918,6 +4215,14 @@ EOF # define LT_PATHMAX 1024 #endif +#ifndef S_IXOTH +# define S_IXOTH 0 +#endif +#ifndef S_IXGRP +# define S_IXGRP 0 +#endif + +/* path handling portability macros */ #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' @@ -4926,6 +4231,7 @@ EOF #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ defined (__OS2__) # define HAVE_DOS_BASED_FILE_SYSTEM +# define FOPEN_WB "wb" # ifndef DIR_SEPARATOR_2 # define DIR_SEPARATOR_2 '\\' # endif @@ -4938,7 +4244,7 @@ EOF # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) #else /* DIR_SEPARATOR_2 */ # define IS_DIR_SEPARATOR(ch) \ - (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) + (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ #ifndef PATH_SEPARATOR_2 @@ -4947,88 +4253,300 @@ EOF # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) #endif /* PATH_SEPARATOR_2 */ +#ifndef FOPEN_WB +# define FOPEN_WB "w" +#endif +#ifndef _O_BINARY +# define _O_BINARY 0 +#endif + #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) -/* -DDEBUG is fairly common in CFLAGS. */ -#undef DEBUG -#if defined DEBUGWRAPPER -# define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__) +#if defined(LT_DEBUGWRAPPER) +static int lt_debug = 1; #else -# define DEBUG(format, ...) +static int lt_debug = 0; #endif -const char *program_name = NULL; +const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ + +void *xmalloc (size_t num); +char *xstrdup (const char *string); +const char *base_name (const char *name); +char *find_executable (const char *wrapper); +char *chase_symlinks (const char *pathspec); +int make_executable (const char *path); +int check_executable (const char *path); +char *strendzap (char *str, const char *pat); +void lt_debugprintf (const char *file, int line, const char *fmt, ...); +void lt_fatal (const char *file, int line, const char *message, ...); +static const char *nonnull (const char *s); +static const char *nonempty (const char *s); +void lt_setenv (const char *name, const char *value); +char *lt_extend_str (const char *orig_value, const char *add, int to_end); +void lt_update_exe_path (const char *name, const char *value); +void lt_update_lib_path (const char *name, const char *value); +char **prepare_spawn (char **argv); +void lt_dump_script (FILE *f); +EOF -void * xmalloc (size_t num); -char * xstrdup (const char *string); -const char * base_name (const char *name); -char * find_executable(const char *wrapper); -int check_executable(const char *path); -char * strendzap(char *str, const char *pat); -void lt_fatal (const char *message, ...); + cat <> $cwrappersource <> $cwrappersource <<"EOF" - newargz[1] = find_executable(argv[0]); - if (newargz[1] == NULL) - lt_fatal("Couldn't find %s", argv[0]); - DEBUG("(main) found exe at : %s\n",newargz[1]); - /* we know the script has the same name, without the .exe */ - /* so make sure newargz[1] doesn't end in .exe */ - strendzap(newargz[1],".exe"); - for (i = 1; i < argc; i++) - newargz[i+1] = xstrdup(argv[i]); - newargz[argc+1] = NULL; + cat <<"EOF" + /* stop here, and copy so we don't have to do this twice */ + tmp_pathspec = xstrdup (newargz[0]); + + /* do NOT want the lt- prefix here, so use actual_cwrapper_name */ + strcat (newargz[0], actual_cwrapper_name); - for (i=0; i> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" - return 127; + cat <<"EOF" } void * xmalloc (size_t num) { - void * p = (void *) malloc (num); + void *p = (void *) malloc (num); if (!p) - lt_fatal ("Memory exhausted"); + lt_fatal (__FILE__, __LINE__, "memory exhausted"); return p; } @@ -5036,8 +4554,8 @@ xmalloc (size_t num) char * xstrdup (const char *string) { - return string ? strcpy ((char *) xmalloc (strlen (string) + 1), string) : NULL -; + return string ? strcpy ((char *) xmalloc (strlen (string) + 1), + string) : NULL; } const char * @@ -5047,7 +4565,7 @@ base_name (const char *name) #if defined (HAVE_DOS_BASED_FILE_SYSTEM) /* Skip over the disk name in MSDOS pathnames. */ - if (isalpha ((unsigned char)name[0]) && name[1] == ':') + if (isalpha ((unsigned char) name[0]) && name[1] == ':') name += 2; #endif @@ -5058,157 +4576,247 @@ base_name (const char *name) } int -check_executable(const char * path) +check_executable (const char *path) { struct stat st; - DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!"); + lt_debugprintf (__FILE__, __LINE__, "(check_executable): %s\n", + nonempty (path)); if ((!path) || (!*path)) return 0; - if ((stat (path, &st) >= 0) && - ( - /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */ -#if defined (S_IXOTH) - ((st.st_mode & S_IXOTH) == S_IXOTH) || -#endif -#if defined (S_IXGRP) - ((st.st_mode & S_IXGRP) == S_IXGRP) || -#endif - ((st.st_mode & S_IXUSR) == S_IXUSR)) - ) + if ((stat (path, &st) >= 0) + && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) return 1; else return 0; } +int +make_executable (const char *path) +{ + int rval = 0; + struct stat st; + + lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", + nonempty (path)); + if ((!path) || (!*path)) + return 0; + + if (stat (path, &st) >= 0) + { + rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); + } + return rval; +} + /* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise */ + newly allocated full path name if found, NULL otherwise + Does not chase symlinks, even on platforms that support them. +*/ char * -find_executable (const char* wrapper) +find_executable (const char *wrapper) { int has_slash = 0; - const char* p; - const char* p_next; + const char *p; + const char *p_next; /* static buffer for getcwd */ char tmp[LT_PATHMAX + 1]; int tmp_len; - char* concat_name; + char *concat_name; - DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"); + lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", + nonempty (wrapper)); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* Absolute path? */ #if defined (HAVE_DOS_BASED_FILE_SYSTEM) - if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) + if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') { concat_name = xstrdup (wrapper); - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); } + else + { +#endif + if (IS_DIR_SEPARATOR (wrapper[0])) + { + concat_name = xstrdup (wrapper); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } #if defined (HAVE_DOS_BASED_FILE_SYSTEM) - } + } #endif for (p = wrapper; *p; p++) if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char* path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) { - const char* q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR(*q)) - break; - p_len = q - p; - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal ("getcwd failed"); - tmp_len = strlen(tmp); - concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable(concat_name)) - return concat_name; - XFREE(concat_name); + has_slash = 1; + break; } + if (!has_slash) + { + /* no slashes; search PATH */ + const char *path = getenv ("PATH"); + if (path != NULL) + { + for (p = path; *p; p = p_next) + { + const char *q; + size_t p_len; + for (q = p; *q; q++) + if (IS_PATH_SEPARATOR (*q)) + break; + p_len = q - p; + p_next = (*q == '\0' ? q : q + 1); + if (p_len == 0) + { + /* empty path: current directory */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = + XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + } + else + { + concat_name = + XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, p, p_len); + concat_name[p_len] = '/'; + strcpy (concat_name + p_len + 1, wrapper); + } + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } + } + /* not found in PATH; assume curdir */ } - /* not found in PATH; assume curdir */ - } /* Relative path | not found in path: prepend cwd */ if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal ("getcwd failed"); - tmp_len = strlen(tmp); - concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); - if (check_executable(concat_name)) + if (check_executable (concat_name)) return concat_name; - XFREE(concat_name); + XFREE (concat_name); return NULL; } char * -strendzap(char *str, const char *pat) +chase_symlinks (const char *pathspec) +{ +#ifndef S_ISLNK + return xstrdup (pathspec); +#else + char buf[LT_PATHMAX]; + struct stat s; + char *tmp_pathspec = xstrdup (pathspec); + char *p; + int has_symlinks = 0; + while (strlen (tmp_pathspec) && !has_symlinks) + { + lt_debugprintf (__FILE__, __LINE__, + "checking path component for symlinks: %s\n", + tmp_pathspec); + if (lstat (tmp_pathspec, &s) == 0) + { + if (S_ISLNK (s.st_mode) != 0) + { + has_symlinks = 1; + break; + } + + /* search backwards for last DIR_SEPARATOR */ + p = tmp_pathspec + strlen (tmp_pathspec) - 1; + while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + p--; + if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + { + /* no more DIR_SEPARATORS left */ + break; + } + *p = '\0'; + } + else + { + lt_fatal (__FILE__, __LINE__, + "error accessing file \"%s\": %s", + tmp_pathspec, nonnull (strerror (errno))); + } + } + XFREE (tmp_pathspec); + + if (!has_symlinks) + { + return xstrdup (pathspec); + } + + tmp_pathspec = realpath (pathspec, buf); + if (tmp_pathspec == 0) + { + lt_fatal (__FILE__, __LINE__, + "could not follow symlinks for %s", pathspec); + } + return xstrdup (tmp_pathspec); +#endif +} + +char * +strendzap (char *str, const char *pat) { size_t len, patlen; - assert(str != NULL); - assert(pat != NULL); + assert (str != NULL); + assert (pat != NULL); - len = strlen(str); - patlen = strlen(pat); + len = strlen (str); + patlen = strlen (pat); if (patlen <= len) - { - str += len - patlen; - if (strcmp(str, pat) == 0) - *str = '\0'; - } + { + str += len - patlen; + if (strcmp (str, pat) == 0) + *str = '\0'; + } return str; } +void +lt_debugprintf (const char *file, int line, const char *fmt, ...) +{ + va_list args; + if (lt_debug) + { + (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); + va_start (args, fmt); + (void) vfprintf (stderr, fmt, args); + va_end (args); + } +} + static void -lt_error_core (int exit_status, const char * mode, - const char * message, va_list ap) +lt_error_core (int exit_status, const char *file, + int line, const char *mode, + const char *message, va_list ap) { - fprintf (stderr, "%s: %s: ", program_name, mode); + fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); vfprintf (stderr, message, ap); fprintf (stderr, ".\n"); @@ -5217,1226 +4825,4605 @@ lt_error_core (int exit_status, const char * mode, } void -lt_fatal (const char *message, ...) +lt_fatal (const char *file, int line, const char *message, ...) { va_list ap; va_start (ap, message); - lt_error_core (EXIT_FAILURE, "FATAL", message, ap); + lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); va_end (ap); } + +static const char * +nonnull (const char *s) +{ + return s ? s : "(null)"; +} + +static const char * +nonempty (const char *s) +{ + return (s && !*s) ? "(empty)" : nonnull (s); +} + +void +lt_setenv (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_setenv) setting '%s' to '%s'\n", + nonnull (name), nonnull (value)); + { +#ifdef HAVE_SETENV + /* always make a copy, for consistency with !HAVE_SETENV */ + char *str = xstrdup (value); + setenv (name, str, 1); +#else + int len = strlen (name) + 1 + strlen (value) + 1; + char *str = XMALLOC (char, len); + sprintf (str, "%s=%s", name, value); + if (putenv (str) != EXIT_SUCCESS) + { + XFREE (str); + } +#endif + } +} + +char * +lt_extend_str (const char *orig_value, const char *add, int to_end) +{ + char *new_value; + if (orig_value && *orig_value) + { + int orig_value_len = strlen (orig_value); + int add_len = strlen (add); + new_value = XMALLOC (char, add_len + orig_value_len + 1); + if (to_end) + { + strcpy (new_value, orig_value); + strcpy (new_value + orig_value_len, add); + } + else + { + strcpy (new_value, add); + strcpy (new_value + add_len, orig_value); + } + } + else + { + new_value = xstrdup (add); + } + return new_value; +} + +void +lt_update_exe_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + /* some systems can't cope with a ':'-terminated path #' */ + int len = strlen (new_value); + while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1])) + { + new_value[len-1] = '\0'; + } + lt_setenv (name, new_value); + XFREE (new_value); + } +} + +void +lt_update_lib_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + lt_setenv (name, new_value); + XFREE (new_value); + } +} + EOF - # we should really use a build-platform specific compiler - # here, but OTOH, the wrappers (shell script and this C one) - # are only useful if you want to execute the "real" binary. - # Since the "real" binary is built for $host, then this - # wrapper might as well be built for $host, too. - $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource - ;; - esac - $rm $output - trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 - - $echo > $output "\ -#! $SHELL + case $host_os in + mingw*) + cat <<"EOF" + +/* Prepares an argument vector before calling spawn(). + Note that spawn() does not by itself call the command interpreter + (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : + ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + GetVersionEx(&v); + v.dwPlatformId == VER_PLATFORM_WIN32_NT; + }) ? "cmd.exe" : "command.com"). + Instead it simply concatenates the arguments, separated by ' ', and calls + CreateProcess(). We must quote the arguments since Win32 CreateProcess() + interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a + special way: + - Space and tab are interpreted as delimiters. They are not treated as + delimiters if they are surrounded by double quotes: "...". + - Unescaped double quotes are removed from the input. Their only effect is + that within double quotes, space and tab are treated like normal + characters. + - Backslashes not followed by double quotes are not special. + - But 2*n+1 backslashes followed by a double quote become + n backslashes followed by a double quote (n >= 0): + \" -> " + \\\" -> \" + \\\\\" -> \\" + */ +#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +char ** +prepare_spawn (char **argv) +{ + size_t argc; + char **new_argv; + size_t i; -# $output - temporary wrapper script for $objdir/$outputname -# Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP -# -# The $output program cannot be directly executed until all the libtool -# libraries that it depends on are installed. -# -# This wrapper script should never be moved out of the build directory. -# If it is, it will not operate correctly. + /* Count number of arguments. */ + for (argc = 0; argv[argc] != NULL; argc++) + ; -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='${SED} -e 1s/^X//' -sed_quote_subst='$sed_quote_subst' + /* Allocate new argument vector. */ + new_argv = XMALLOC (char *, argc + 1); -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + /* Put quoted arguments into the new argument vector. */ + for (i = 0; i < argc; i++) + { + const char *string = argv[i]; + + if (string[0] == '\0') + new_argv[i] = xstrdup ("\"\""); + else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) + { + int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); + size_t length; + unsigned int backslashes; + const char *s; + char *quoted_string; + char *p; + + length = 0; + backslashes = 0; + if (quote_around) + length++; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + length += backslashes + 1; + length++; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + length += backslashes + 1; + + quoted_string = XMALLOC (char, length + 1); + + p = quoted_string; + backslashes = 0; + if (quote_around) + *p++ = '"'; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + { + unsigned int j; + for (j = backslashes + 1; j > 0; j--) + *p++ = '\\'; + } + *p++ = c; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + { + unsigned int j; + for (j = backslashes; j > 0; j--) + *p++ = '\\'; + *p++ = '"'; + } + *p = '\0'; -relink_command=\"$relink_command\" + new_argv[i] = quoted_string; + } + else + new_argv[i] = (char *) string; + } + new_argv[argc] = NULL; -# This environment variable determines our operation mode. -if test \"\$libtool_install_magic\" = \"$magic\"; then - # install mode needs the following variable: - notinst_deplibs='$notinst_deplibs' -else - # When we are sourced in execute mode, \$file and \$echo are already set. - if test \"\$libtool_execute_magic\" != \"$magic\"; then - echo=\"$qecho\" - file=\"\$0\" - # Make sure echo works. - if test \"X\$1\" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift - elif test \"X\`(\$echo '\t') 2>/dev/null\`\" = 'X\t'; then - # Yippee, \$echo works! - : - else - # Restart under the correct shell, and then maybe \$echo will work. - exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"} - fi - fi\ -" - $echo >> $output "\ + return new_argv; +} +EOF + ;; + esac - # Find the directory that this script lives in. - thisdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` - test \"x\$thisdir\" = \"x\$file\" && thisdir=. + cat <<"EOF" +void lt_dump_script (FILE* f) +{ +EOF + func_emit_wrapper yes | + $SED -e 's/\([\\"]\)/\\\1/g' \ + -e 's/^/ fputs ("/' -e 's/$/\\n", f);/' - # Follow symbolic links until we get to the real thisdir. - file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\` - while test -n \"\$file\"; do - destdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\` + cat <<"EOF" +} +EOF +} +# end: func_emit_cwrapperexe_src - # If there was a directory component, then change thisdir. - if test \"x\$destdir\" != \"x\$file\"; then - case \"\$destdir\" in - [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; - *) thisdir=\"\$thisdir/\$destdir\" ;; - esac - fi +# func_win32_import_lib_p ARG +# True if ARG is an import lib, as indicated by $file_magic_cmd +func_win32_import_lib_p () +{ + $opt_debug + case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in + *import*) : ;; + *) false ;; + esac +} - file=\`\$echo \"X\$file\" | \$Xsed -e 's%^.*/%%'\` - file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` - done +# func_mode_link arg... +func_mode_link () +{ + $opt_debug + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + # It is impossible to link a dll without this setting, and + # we shouldn't force the makefile maintainer to figure out + # which system we are compiling for in order to pass an extra + # flag for every libtool invocation. + # allow_undefined=no - # Try to get the absolute directory name. - absdir=\`cd \"\$thisdir\" && pwd\` - test -n \"\$absdir\" && thisdir=\"\$absdir\" -" + # FIXME: Unfortunately, there are problems with the above when trying + # to make a dll which has undefined symbols, in which case not + # even a static library is built. For now, we need to specify + # -no-undefined on the libtool link line when we can be certain + # that all symbols are satisfied, otherwise we get a static library. + allow_undefined=yes + ;; + *) + allow_undefined=yes + ;; + esac + libtool_args=$nonopt + base_compile="$nonopt $@" + compile_command=$nonopt + finalize_command=$nonopt - if test "$fast_install" = yes; then - $echo >> $output "\ - program=lt-'$outputname'$exeext - progdir=\"\$thisdir/$objdir\" + compile_rpath= + finalize_rpath= + compile_shlibpath= + finalize_shlibpath= + convenience= + old_convenience= + deplibs= + old_deplibs= + compiler_flags= + linker_flags= + dllsearchpath= + lib_search_path=`pwd` + inst_prefix_dir= + new_inherited_linker_flags= + + avoid_version=no + bindir= + dlfiles= + dlprefiles= + dlself=no + export_dynamic=no + export_symbols= + export_symbols_regex= + generated= + libobjs= + ltlibs= + module=no + no_install=no + objs= + non_pic_objects= + precious_files_regex= + prefer_static_libs=no + preload=no + prev= + prevarg= + release= + rpath= + xrpath= + perm_rpath= + temp_rpath= + thread_safe=no + vinfo= + vinfo_number=no + weak_libs= + single_module="${wl}-single_module" + func_infer_tag $base_compile + + # We need to know -static, to get the right output filenames. + for arg + do + case $arg in + -shared) + test "$build_libtool_libs" != yes && \ + func_fatal_configuration "can not build a shared library" + build_old_libs=no + break + ;; + -all-static | -static | -static-libtool-libs) + case $arg in + -all-static) + if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then + func_warning "complete static linking is impossible in this configuration" + fi + if test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + -static) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=built + ;; + -static-libtool-libs) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + esac + build_libtool_libs=no + build_old_libs=yes + break + ;; + esac + done + + # See if our shared archives depend on static archives. + test -n "$old_archive_from_new_cmds" && build_old_libs=yes + + # Go through the arguments, transforming them on the way. + while test "$#" -gt 0; do + arg="$1" + shift + func_quote_for_eval "$arg" + qarg=$func_quote_for_eval_unquoted_result + func_append libtool_args " $func_quote_for_eval_result" + + # If the previous option needs an argument, assign it. + if test -n "$prev"; then + case $prev in + output) + func_append compile_command " @OUTPUT@" + func_append finalize_command " @OUTPUT@" + ;; + esac + + case $prev in + bindir) + bindir="$arg" + prev= + continue + ;; + dlfiles|dlprefiles) + if test "$preload" = no; then + # Add the symbol object into the linking commands. + func_append compile_command " @SYMFILE@" + func_append finalize_command " @SYMFILE@" + preload=yes + fi + case $arg in + *.la | *.lo) ;; # We handle these cases below. + force) + if test "$dlself" = no; then + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + self) + if test "$prev" = dlprefiles; then + dlself=yes + elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then + dlself=yes + else + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + *) + if test "$prev" = dlfiles; then + func_append dlfiles " $arg" + else + func_append dlprefiles " $arg" + fi + prev= + continue + ;; + esac + ;; + expsyms) + export_symbols="$arg" + test -f "$arg" \ + || func_fatal_error "symbol file \`$arg' does not exist" + prev= + continue + ;; + expsyms_regex) + export_symbols_regex="$arg" + prev= + continue + ;; + framework) + case $host in + *-*-darwin*) + case "$deplibs " in + *" $qarg.ltframework "*) ;; + *) func_append deplibs " $qarg.ltframework" # this is fixed later + ;; + esac + ;; + esac + prev= + continue + ;; + inst_prefix) + inst_prefix_dir="$arg" + prev= + continue + ;; + objectlist) + if test -f "$arg"; then + save_arg=$arg + moreargs= + for fil in `cat "$save_arg"` + do +# func_append moreargs " $fil" + arg=$fil + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test "$pic_object" = none && + test "$non_pic_object" = none; then + func_fatal_error "cannot find name of object for \`$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" + + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg="$pic_object" + fi + + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "\`$arg' is not a valid libtool object" + fi + fi + done + else + func_fatal_error "link input file \`$arg' does not exist" + fi + arg=$save_arg + prev= + continue + ;; + precious_regex) + precious_files_regex="$arg" + prev= + continue + ;; + release) + release="-$arg" + prev= + continue + ;; + rpath | xrpath) + # We need an absolute path. + case $arg in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + if test "$prev" = rpath; then + case "$rpath " in + *" $arg "*) ;; + *) func_append rpath " $arg" ;; + esac + else + case "$xrpath " in + *" $arg "*) ;; + *) func_append xrpath " $arg" ;; + esac + fi + prev= + continue + ;; + shrext) + shrext_cmds="$arg" + prev= + continue + ;; + weak) + func_append weak_libs " $arg" + prev= + continue + ;; + xcclinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xcompiler) + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xlinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $wl$qarg" + prev= + func_append compile_command " $wl$qarg" + func_append finalize_command " $wl$qarg" + continue + ;; + *) + eval "$prev=\"\$arg\"" + prev= + continue + ;; + esac + fi # test -n "$prev" + + prevarg="$arg" + + case $arg in + -all-static) + if test -n "$link_static_flag"; then + # See comment for -static flag below, for more details. + func_append compile_command " $link_static_flag" + func_append finalize_command " $link_static_flag" + fi + continue + ;; + + -allow-undefined) + # FIXME: remove this flag sometime in the future. + func_fatal_error "\`-allow-undefined' must not be used because it is the default" + ;; + + -avoid-version) + avoid_version=yes + continue + ;; + + -bindir) + prev=bindir + continue + ;; + + -dlopen) + prev=dlfiles + continue + ;; + + -dlpreopen) + prev=dlprefiles + continue + ;; + + -export-dynamic) + export_dynamic=yes + continue + ;; + + -export-symbols | -export-symbols-regex) + if test -n "$export_symbols" || test -n "$export_symbols_regex"; then + func_fatal_error "more than one -exported-symbols argument is not allowed" + fi + if test "X$arg" = "X-export-symbols"; then + prev=expsyms + else + prev=expsyms_regex + fi + continue + ;; + + -framework) + prev=framework + continue + ;; + + -inst-prefix-dir) + prev=inst_prefix + continue + ;; + + # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* + # so, if we see these flags be careful not to treat them like -L + -L[A-Z][A-Z]*:*) + case $with_gcc/$host in + no/*-*-irix* | /*-*-irix*) + func_append compile_command " $arg" + func_append finalize_command " $arg" + ;; + esac + continue + ;; + + -L*) + func_stripname "-L" '' "$arg" + if test -z "$func_stripname_result"; then + if test "$#" -gt 0; then + func_fatal_error "require no space between \`-L' and \`$1'" + else + func_fatal_error "need path for \`-L' option" + fi + fi + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + absdir=`cd "$dir" && pwd` + test -z "$absdir" && \ + func_fatal_error "cannot determine absolute directory name of \`$dir'" + dir="$absdir" + ;; + esac + case "$deplibs " in + *" -L$dir "* | *" $arg "*) + # Will only happen for absolute or sysroot arguments + ;; + *) + # Preserve sysroot, but never include relative directories + case $dir in + [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; + *) func_append deplibs " -L$dir" ;; + esac + func_append lib_search_path " $dir" + ;; + esac + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$dir:"*) ;; + ::) dllsearchpath=$dir;; + *) func_append dllsearchpath ":$dir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + continue + ;; + + -l*) + if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) + # These systems don't actually have a C or math library (as such) + continue + ;; + *-*-os2*) + # These systems don't actually have a C library (as such) + test "X$arg" = "X-lc" && continue + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + test "X$arg" = "X-lc" && continue + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C and math libraries are in the System framework + func_append deplibs " System.ltframework" + continue + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + test "X$arg" = "X-lc" && continue + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + test "X$arg" = "X-lc" && continue + ;; + esac + elif test "X$arg" = "X-lc_r"; then + case $host in + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc_r directly, use -pthread flag. + continue + ;; + esac + fi + func_append deplibs " $arg" + continue + ;; + + -module) + module=yes + continue + ;; + + # Tru64 UNIX uses -model [arg] to determine the layout of C++ + # classes, name mangling, and exception handling. + # Darwin uses the -arch flag to determine output architecture. + -model|-arch|-isysroot|--sysroot) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + prev=xcompiler + continue + ;; + + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + case "$new_inherited_linker_flags " in + *" $arg "*) ;; + * ) func_append new_inherited_linker_flags " $arg" ;; + esac + continue + ;; + + -multi_module) + single_module="${wl}-multi_module" + continue + ;; + + -no-fast-install) + fast_install=no + continue + ;; + + -no-install) + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) + # The PATH hackery in wrapper scripts is required on Windows + # and Darwin in order for the loader to find any dlls it needs. + func_warning "\`-no-install' is ignored for $host" + func_warning "assuming \`-no-fast-install' instead" + fast_install=no + ;; + *) no_install=yes ;; + esac + continue + ;; + + -no-undefined) + allow_undefined=no + continue + ;; + + -objectlist) + prev=objectlist + continue + ;; + + -o) prev=output ;; + + -precious-files-regex) + prev=precious_regex + continue + ;; + + -release) + prev=release + continue + ;; + + -rpath) + prev=rpath + continue + ;; + + -R) + prev=xrpath + continue + ;; + + -R*) + func_stripname '-R' '' "$arg" + dir=$func_stripname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + =*) + func_stripname '=' '' "$dir" + dir=$lt_sysroot$func_stripname_result + ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + continue + ;; + + -shared) + # The effects of -shared are defined in a previous loop. + continue + ;; + + -shrext) + prev=shrext + continue + ;; + + -static | -static-libtool-libs) + # The effects of -static are defined in a previous loop. + # We used to do the same as -all-static on platforms that + # didn't have a PIC flag, but the assumption that the effects + # would be equivalent was wrong. It would break on at least + # Digital Unix and AIX. + continue + ;; + + -thread-safe) + thread_safe=yes + continue + ;; + + -version-info) + prev=vinfo + continue + ;; + + -version-number) + prev=vinfo + vinfo_number=yes + continue + ;; + + -weak) + prev=weak + continue + ;; + + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + func_quote_for_eval "$flag" + func_append arg " $func_quote_for_eval_result" + func_append compiler_flags " $func_quote_for_eval_result" + done + IFS="$save_ifs" + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Wl,*) + func_stripname '-Wl,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + func_quote_for_eval "$flag" + func_append arg " $wl$func_quote_for_eval_result" + func_append compiler_flags " $wl$func_quote_for_eval_result" + func_append linker_flags " $func_quote_for_eval_result" + done + IFS="$save_ifs" + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Xcompiler) + prev=xcompiler + continue + ;; + + -Xlinker) + prev=xlinker + continue + ;; + + -XCClinker) + prev=xcclinker + continue + ;; + + # -msg_* for osf cc + -msg_*) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + + # Flags to be passed through unchanged, with rationale: + # -64, -mips[0-9] enable 64-bit mode for the SGI compiler + # -r[0-9][0-9]* specify processor for the SGI compiler + # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler + # +DA*, +DD* enable 64-bit mode for the HP compiler + # -q* compiler args for the IBM compiler + # -m*, -t[45]*, -txscale* architecture-specific flags for GCC + # -F/path path to uninstalled frameworks, gcc on darwin + # -p, -pg, --coverage, -fprofile-* profiling flags for GCC + # @file GCC response files + # -tp=* Portland pgcc target processor selection + # --sysroot=* for sysroot support + # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ + -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ + -O*|-flto*|-fwhopr*|-fuse-linker-plugin) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + func_append compile_command " $arg" + func_append finalize_command " $arg" + func_append compiler_flags " $arg" + continue + ;; + + # Some other compiler flag. + -* | +*) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + + *.$objext) + # A standard object. + func_append objs " $arg" + ;; + + *.lo) + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test "$pic_object" = none && + test "$non_pic_object" = none; then + func_fatal_error "cannot find name of object for \`$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" + + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg="$pic_object" + fi + + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "\`$arg' is not a valid libtool object" + fi + fi + ;; + + *.$libext) + # An archive. + func_append deplibs " $arg" + func_append old_deplibs " $arg" + continue + ;; + + *.la) + # A libtool-controlled library. + + func_resolve_sysroot "$arg" + if test "$prev" = dlfiles; then + # This library was specified with -dlopen. + func_append dlfiles " $func_resolve_sysroot_result" + prev= + elif test "$prev" = dlprefiles; then + # The library was specified with -dlpreopen. + func_append dlprefiles " $func_resolve_sysroot_result" + prev= + else + func_append deplibs " $func_resolve_sysroot_result" + fi + continue + ;; + + # Some other compiler argument. + *) + # Unknown arguments in both finalize_command and compile_command need + # to be aesthetically quoted because they are evaled later. + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + esac # arg + + # Now actually substitute the argument into the commands. + if test -n "$arg"; then + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + done # argument parsing loop + + test -n "$prev" && \ + func_fatal_help "the \`$prevarg' option requires an argument" + + if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then + eval arg=\"$export_dynamic_flag_spec\" + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + + oldlibs= + # calculate the name of the file, without its directory + func_basename "$output" + outputname="$func_basename_result" + libobjs_save="$libobjs" + + if test -n "$shlibpath_var"; then + # get the directories listed in $shlibpath_var + eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\` + else + shlib_search_path= + fi + eval sys_lib_search_path=\"$sys_lib_search_path_spec\" + eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" + + func_dirname "$output" "/" "" + output_objdir="$func_dirname_result$objdir" + func_to_tool_file "$output_objdir/" + tool_output_objdir=$func_to_tool_file_result + # Create the object directory. + func_mkdir_p "$output_objdir" + + # Determine the type of output + case $output in + "") + func_fatal_help "you must specify an output file" + ;; + *.$libext) linkmode=oldlib ;; + *.lo | *.$objext) linkmode=obj ;; + *.la) linkmode=lib ;; + *) linkmode=prog ;; # Anything else should be a program. + esac + + specialdeplibs= + + libs= + # Find all interdependent deplibs by searching for libraries + # that are linked more than once (e.g. -la -lb -la) + for deplib in $deplibs; do + if $opt_preserve_dup_deps ; then + case "$libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append libs " $deplib" + done + + if test "$linkmode" = lib; then + libs="$predeps $libs $compiler_lib_search_path $postdeps" + + # Compute libraries that are listed more than once in $predeps + # $postdeps and mark them as special (i.e., whose duplicates are + # not to be eliminated). + pre_post_deps= + if $opt_duplicate_compiler_generated_deps; then + for pre_post_dep in $predeps $postdeps; do + case "$pre_post_deps " in + *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; + esac + func_append pre_post_deps " $pre_post_dep" + done + fi + pre_post_deps= + fi + + deplibs= + newdependency_libs= + newlib_search_path= + need_relink=no # whether we're linking any uninstalled libtool libraries + notinst_deplibs= # not-installed libtool libraries + notinst_path= # paths that contain not-installed libtool libraries + + case $linkmode in + lib) + passes="conv dlpreopen link" + for file in $dlfiles $dlprefiles; do + case $file in + *.la) ;; + *) + func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file" + ;; + esac + done + ;; + prog) + compile_deplibs= + finalize_deplibs= + alldeplibs=no + newdlfiles= + newdlprefiles= + passes="conv scan dlopen dlpreopen link" + ;; + *) passes="conv" + ;; + esac + + for pass in $passes; do + # The preopen pass in lib mode reverses $deplibs; put it back here + # so that -L comes before libs that need it for instance... + if test "$linkmode,$pass" = "lib,link"; then + ## FIXME: Find the place where the list is rebuilt in the wrong + ## order, and fix it there properly + tmp_deplibs= + for deplib in $deplibs; do + tmp_deplibs="$deplib $tmp_deplibs" + done + deplibs="$tmp_deplibs" + fi + + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan"; then + libs="$deplibs" + deplibs= + fi + if test "$linkmode" = prog; then + case $pass in + dlopen) libs="$dlfiles" ;; + dlpreopen) libs="$dlprefiles" ;; + link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; + esac + fi + if test "$linkmode,$pass" = "lib,dlpreopen"; then + # Collect and forward deplibs of preopened libtool libs + for lib in $dlprefiles; do + # Ignore non-libtool-libs + dependency_libs= + func_resolve_sysroot "$lib" + case $lib in + *.la) func_source "$func_resolve_sysroot_result" ;; + esac + + # Collect preopened libtool deplibs, except any this library + # has declared as weak libs + for deplib in $dependency_libs; do + func_basename "$deplib" + deplib_base=$func_basename_result + case " $weak_libs " in + *" $deplib_base "*) ;; + *) func_append deplibs " $deplib" ;; + esac + done + done + libs="$dlprefiles" + fi + if test "$pass" = dlopen; then + # Collect dlpreopened libraries + save_deplibs="$deplibs" + deplibs= + fi + + for deplib in $libs; do + lib= + found=no + case $deplib in + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append compiler_flags " $deplib" + if test "$linkmode" = lib ; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -l*) + if test "$linkmode" != lib && test "$linkmode" != prog; then + func_warning "\`-l' is ignored for archives/objects" + continue + fi + func_stripname '-l' '' "$deplib" + name=$func_stripname_result + if test "$linkmode" = lib; then + searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" + else + searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" + fi + for searchdir in $searchdirs; do + for search_ext in .la $std_shrext .so .a; do + # Search the libtool library + lib="$searchdir/lib${name}${search_ext}" + if test -f "$lib"; then + if test "$search_ext" = ".la"; then + found=yes + else + found=no + fi + break 2 + fi + done + done + if test "$found" != yes; then + # deplib doesn't seem to be a libtool library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + else # deplib is a libtool library + # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, + # We need to do some special things here, and not later. + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $deplib "*) + if func_lalib_p "$lib"; then + library_names= + old_library= + func_source "$lib" + for l in $old_library $library_names; do + ll="$l" + done + if test "X$ll" = "X$old_library" ; then # only static version available + found=no + func_dirname "$lib" "" "." + ladir="$func_dirname_result" + lib=$ladir/$old_library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + fi + fi + ;; + *) ;; + esac + fi + fi + ;; # -l + *.ltframework) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + if test "$linkmode" = lib ; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -L*) + case $linkmode in + lib) + deplibs="$deplib $deplibs" + test "$pass" = conv && continue + newdependency_libs="$deplib $newdependency_libs" + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + prog) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + if test "$pass" = scan; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + *) + func_warning "\`-L' is ignored for archives/objects" + ;; + esac # linkmode + continue + ;; # -L + -R*) + if test "$pass" = link; then + func_stripname '-R' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # Make sure the xrpath contains only unique directories. + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + fi + deplibs="$deplib $deplibs" + continue + ;; + *.la) + func_resolve_sysroot "$deplib" + lib=$func_resolve_sysroot_result + ;; + *.$libext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + case $linkmode in + lib) + # Linking convenience modules into shared libraries is allowed, + # but linking other static libraries is non-portable. + case " $dlpreconveniencelibs " in + *" $deplib "*) ;; + *) + valid_a_lib=no + case $deplibs_check_method in + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ + | $EGREP "$match_pattern_regex" > /dev/null; then + valid_a_lib=yes + fi + ;; + pass_all) + valid_a_lib=yes + ;; + esac + if test "$valid_a_lib" != yes; then + echo + $ECHO "*** Warning: Trying to link with static lib archive $deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because the file extensions .$libext of this argument makes me believe" + echo "*** that it is just a static archive that I should not use here." + else + echo + $ECHO "*** Warning: Linking the shared library $output against the" + $ECHO "*** static library $deplib is not portable!" + deplibs="$deplib $deplibs" + fi + ;; + esac + continue + ;; + prog) + if test "$pass" != link; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + continue + ;; + esac # linkmode + ;; # *.$libext + *.lo | *.$objext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + elif test "$linkmode" = prog; then + if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then + # If there is no dlopen support or we're linking statically, + # we need to preload. + func_append newdlprefiles " $deplib" + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append newdlfiles " $deplib" + fi + fi + continue + ;; + %DEPLIBS%) + alldeplibs=yes + continue + ;; + esac # case $deplib + + if test "$found" = yes || test -f "$lib"; then : + else + func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'" + fi + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$lib" \ + || func_fatal_error "\`$lib' is not a valid libtool archive" + + func_dirname "$lib" "" "." + ladir="$func_dirname_result" + + dlname= + dlopen= + dlpreopen= + libdir= + library_names= + old_library= + inherited_linker_flags= + # If the library was installed with an old release of libtool, + # it will not redefine variables installed, or shouldnotlink + installed=yes + shouldnotlink=no + avoidtemprpath= + + + # Read the .la file + func_source "$lib" + + # Convert "-framework foo" to "foo.ltframework" + if test -n "$inherited_linker_flags"; then + tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` + for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do + case " $new_inherited_linker_flags " in + *" $tmp_inherited_linker_flag "*) ;; + *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; + esac + done + fi + dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan" || + { test "$linkmode" != prog && test "$linkmode" != lib; }; then + test -n "$dlopen" && func_append dlfiles " $dlopen" + test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" + fi + + if test "$pass" = conv; then + # Only check for convenience libraries + deplibs="$lib $deplibs" + if test -z "$libdir"; then + if test -z "$old_library"; then + func_fatal_error "cannot find name of link library for \`$lib'" + fi + # It is a libtool convenience library, so add in its objects. + func_append convenience " $ladir/$objdir/$old_library" + func_append old_convenience " $ladir/$objdir/$old_library" + elif test "$linkmode" != prog && test "$linkmode" != lib; then + func_fatal_error "\`$lib' is not a convenience library" + fi + tmp_libs= + for deplib in $dependency_libs; do + deplibs="$deplib $deplibs" + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done + continue + fi # $pass = conv + + + # Get the name of the library we link against. + linklib= + if test -n "$old_library" && + { test "$prefer_static_libs" = yes || + test "$prefer_static_libs,$installed" = "built,no"; }; then + linklib=$old_library + else + for l in $old_library $library_names; do + linklib="$l" + done + fi + if test -z "$linklib"; then + func_fatal_error "cannot find name of link library for \`$lib'" + fi + + # This library was specified with -dlopen. + if test "$pass" = dlopen; then + if test -z "$libdir"; then + func_fatal_error "cannot -dlopen a convenience library: \`$lib'" + fi + if test -z "$dlname" || + test "$dlopen_support" != yes || + test "$build_libtool_libs" = no; then + # If there is no dlname, no dlopen support or we're linking + # statically, we need to preload. We also need to preload any + # dependent libraries so libltdl's deplib preloader doesn't + # bomb out in the load deplibs phase. + func_append dlprefiles " $lib $dependency_libs" + else + func_append newdlfiles " $lib" + fi + continue + fi # $pass = dlopen + + # We need an absolute path. + case $ladir in + [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; + *) + abs_ladir=`cd "$ladir" && pwd` + if test -z "$abs_ladir"; then + func_warning "cannot determine absolute directory name of \`$ladir'" + func_warning "passing it literally to the linker, although it might fail" + abs_ladir="$ladir" + fi + ;; + esac + func_basename "$lib" + laname="$func_basename_result" + + # Find the relevant object directory and library name. + if test "X$installed" = Xyes; then + if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then + func_warning "library \`$lib' was moved." + dir="$ladir" + absdir="$abs_ladir" + libdir="$abs_ladir" + else + dir="$lt_sysroot$libdir" + absdir="$lt_sysroot$libdir" + fi + test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes + else + if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then + dir="$ladir" + absdir="$abs_ladir" + # Remove this search path later + func_append notinst_path " $abs_ladir" + else + dir="$ladir/$objdir" + absdir="$abs_ladir/$objdir" + # Remove this search path later + func_append notinst_path " $abs_ladir" + fi + fi # $installed = yes + func_stripname 'lib' '.la' "$laname" + name=$func_stripname_result + + # This library was specified with -dlpreopen. + if test "$pass" = dlpreopen; then + if test -z "$libdir" && test "$linkmode" = prog; then + func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" + fi + case "$host" in + # special handling for platforms with PE-DLLs. + *cygwin* | *mingw* | *cegcc* ) + # Linker will automatically link against shared library if both + # static and shared are present. Therefore, ensure we extract + # symbols from the import library if a shared library is present + # (otherwise, the dlopen module name will be incorrect). We do + # this by putting the import library name into $newdlprefiles. + # We recover the dlopen module name by 'saving' the la file + # name in a special purpose variable, and (later) extracting the + # dlname from the la file. + if test -n "$dlname"; then + func_tr_sh "$dir/$linklib" + eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" + func_append newdlprefiles " $dir/$linklib" + else + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + fi + ;; + * ) + # Prefer using a static library (so that no silly _DYNAMIC symbols + # are required to link). + if test -n "$old_library"; then + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + # Otherwise, use the dlname, so that lt_dlopen finds it. + elif test -n "$dlname"; then + func_append newdlprefiles " $dir/$dlname" + else + func_append newdlprefiles " $dir/$linklib" + fi + ;; + esac + fi # $pass = dlpreopen + + if test -z "$libdir"; then + # Link the convenience library + if test "$linkmode" = lib; then + deplibs="$dir/$old_library $deplibs" + elif test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$dir/$old_library $compile_deplibs" + finalize_deplibs="$dir/$old_library $finalize_deplibs" + else + deplibs="$lib $deplibs" # used for prog,scan pass + fi + continue + fi + + + if test "$linkmode" = prog && test "$pass" != link; then + func_append newlib_search_path " $ladir" + deplibs="$lib $deplibs" + + linkalldeplibs=no + if test "$link_all_deplibs" != no || test -z "$library_names" || + test "$build_libtool_libs" = no; then + linkalldeplibs=yes + fi + + tmp_libs= + for deplib in $dependency_libs; do + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + esac + # Need to link against all dependency_libs? + if test "$linkalldeplibs" = yes; then + deplibs="$deplib $deplibs" + else + # Need to hardcode shared library paths + # or/and link against static libraries + newdependency_libs="$deplib $newdependency_libs" + fi + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done # for deplib + continue + fi # $linkmode = prog... + + if test "$linkmode,$pass" = "prog,link"; then + if test -n "$library_names" && + { { test "$prefer_static_libs" = no || + test "$prefer_static_libs,$installed" = "built,yes"; } || + test -z "$old_library"; }; then + # We need to hardcode the library path + if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then + # Make sure the rpath contains only unique directories. + case "$temp_rpath:" in + *"$absdir:"*) ;; + *) func_append temp_rpath "$absdir:" ;; + esac + fi + + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi # $linkmode,$pass = prog,link... + + if test "$alldeplibs" = yes && + { test "$deplibs_check_method" = pass_all || + { test "$build_libtool_libs" = yes && + test -n "$library_names"; }; }; then + # We only need to search for static libraries + continue + fi + fi + + link_static=no # Whether the deplib will be linked statically + use_static_libs=$prefer_static_libs + if test "$use_static_libs" = built && test "$installed" = yes; then + use_static_libs=no + fi + if test -n "$library_names" && + { test "$use_static_libs" = no || test -z "$old_library"; }; then + case $host in + *cygwin* | *mingw* | *cegcc*) + # No point in relinking DLLs because paths are not encoded + func_append notinst_deplibs " $lib" + need_relink=no + ;; + *) + if test "$installed" = no; then + func_append notinst_deplibs " $lib" + need_relink=yes + fi + ;; + esac + # This is a shared library + + # Warn about portability, can't link against -module's on some + # systems (darwin). Don't bleat about dlopened modules though! + dlopenmodule="" + for dlpremoduletest in $dlprefiles; do + if test "X$dlpremoduletest" = "X$lib"; then + dlopenmodule="$dlpremoduletest" + break + fi + done + if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then + echo + if test "$linkmode" = prog; then + $ECHO "*** Warning: Linking the executable $output against the loadable module" + else + $ECHO "*** Warning: Linking the shared library $output against the loadable module" + fi + $ECHO "*** $linklib is not portable!" + fi + if test "$linkmode" = lib && + test "$hardcode_into_libs" = yes; then + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi + + if test -n "$old_archive_from_expsyms_cmds"; then + # figure out the soname + set dummy $library_names + shift + realname="$1" + shift + libname=`eval "\\$ECHO \"$libname_spec\""` + # use dlname if we got it. it's perfectly good, no? + if test -n "$dlname"; then + soname="$dlname" + elif test -n "$soname_spec"; then + # bleh windows + case $host in + *cygwin* | mingw* | *cegcc*) + func_arith $current - $age + major=$func_arith_result + versuffix="-$major" + ;; + esac + eval soname=\"$soname_spec\" + else + soname="$realname" + fi + + # Make a new name for the extract_expsyms_cmds to use + soroot="$soname" + func_basename "$soroot" + soname="$func_basename_result" + func_stripname 'lib' '.dll' "$soname" + newlib=libimp-$func_stripname_result.a + + # If the library has no export list, then create one now + if test -f "$output_objdir/$soname-def"; then : + else + func_verbose "extracting exported symbol list from \`$soname'" + func_execute_cmds "$extract_expsyms_cmds" 'exit $?' + fi + + # Create $newlib + if test -f "$output_objdir/$newlib"; then :; else + func_verbose "generating import library for \`$soname'" + func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' + fi + # make sure the library variables are pointing to the new library + dir=$output_objdir + linklib=$newlib + fi # test -n "$old_archive_from_expsyms_cmds" + + if test "$linkmode" = prog || test "$opt_mode" != relink; then + add_shlibpath= + add_dir= + add= + lib_linked=yes + case $hardcode_action in + immediate | unsupported) + if test "$hardcode_direct" = no; then + add="$dir/$linklib" + case $host in + *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; + *-*-sysv4*uw2*) add_dir="-L$dir" ;; + *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ + *-*-unixware7*) add_dir="-L$dir" ;; + *-*-darwin* ) + # if the lib is a (non-dlopened) module then we can not + # link against it, someone is ignoring the earlier warnings + if /usr/bin/file -L $add 2> /dev/null | + $GREP ": [^:]* bundle" >/dev/null ; then + if test "X$dlopenmodule" != "X$lib"; then + $ECHO "*** Warning: lib $linklib is a module, not a shared library" + if test -z "$old_library" ; then + echo + echo "*** And there doesn't seem to be a static archive available" + echo "*** The link will probably fail, sorry" + else + add="$dir/$old_library" + fi + elif test -n "$old_library"; then + add="$dir/$old_library" + fi + fi + esac + elif test "$hardcode_minus_L" = no; then + case $host in + *-*-sunos*) add_shlibpath="$dir" ;; + esac + add_dir="-L$dir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = no; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + relink) + if test "$hardcode_direct" = yes && + test "$hardcode_direct_absolute" = no; then + add="$dir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$dir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + *) lib_linked=no ;; + esac + + if test "$lib_linked" != yes; then + func_fatal_configuration "unsupported hardcode properties" + fi + + if test -n "$add_shlibpath"; then + case :$compile_shlibpath: in + *":$add_shlibpath:"*) ;; + *) func_append compile_shlibpath "$add_shlibpath:" ;; + esac + fi + if test "$linkmode" = prog; then + test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" + test -n "$add" && compile_deplibs="$add $compile_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + if test "$hardcode_direct" != yes && + test "$hardcode_minus_L" != yes && + test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + fi + fi + fi + + if test "$linkmode" = prog || test "$opt_mode" = relink; then + add_shlibpath= + add_dir= + add= + # Finalize command for both is simple: just hardcode it. + if test "$hardcode_direct" = yes && + test "$hardcode_direct_absolute" = no; then + add="$libdir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$libdir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + add="-l$name" + elif test "$hardcode_automatic" = yes; then + if test -n "$inst_prefix_dir" && + test -f "$inst_prefix_dir$libdir/$linklib" ; then + add="$inst_prefix_dir$libdir/$linklib" + else + add="$libdir/$linklib" + fi + else + # We cannot seem to hardcode it, guess we'll fake it. + add_dir="-L$libdir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + fi + + if test "$linkmode" = prog; then + test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" + test -n "$add" && finalize_deplibs="$add $finalize_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + fi + fi + elif test "$linkmode" = prog; then + # Here we assume that one of hardcode_direct or hardcode_minus_L + # is not unsupported. This is valid on all known static and + # shared platforms. + if test "$hardcode_direct" != unsupported; then + test -n "$old_library" && linklib="$old_library" + compile_deplibs="$dir/$linklib $compile_deplibs" + finalize_deplibs="$dir/$linklib $finalize_deplibs" + else + compile_deplibs="-l$name -L$dir $compile_deplibs" + finalize_deplibs="-l$name -L$dir $finalize_deplibs" + fi + elif test "$build_libtool_libs" = yes; then + # Not a shared library + if test "$deplibs_check_method" != pass_all; then + # We're trying link a shared library against a static one + # but the system doesn't support it. + + # Just print a warning and add the library to dependency_libs so + # that the program can be linked against the static library. + echo + $ECHO "*** Warning: This system can not link to static lib archive $lib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have." + if test "$module" = yes; then + echo "*** But as you try to build a module library, libtool will still create " + echo "*** a static module, that should work as long as the dlopening application" + echo "*** is linked with the -dlopen flag to resolve symbols at runtime." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + else + deplibs="$dir/$old_library $deplibs" + link_static=yes + fi + fi # link shared/static library? + + if test "$linkmode" = lib; then + if test -n "$dependency_libs" && + { test "$hardcode_into_libs" != yes || + test "$build_old_libs" = yes || + test "$link_static" = yes; }; then + # Extract -R from dependency_libs + temp_deplibs= + for libdir in $dependency_libs; do + case $libdir in + -R*) func_stripname '-R' '' "$libdir" + temp_xrpath=$func_stripname_result + case " $xrpath " in + *" $temp_xrpath "*) ;; + *) func_append xrpath " $temp_xrpath";; + esac;; + *) func_append temp_deplibs " $libdir";; + esac + done + dependency_libs="$temp_deplibs" + fi + + func_append newlib_search_path " $absdir" + # Link against this library + test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" + # ... and its dependency_libs + tmp_libs= + for deplib in $dependency_libs; do + newdependency_libs="$deplib $newdependency_libs" + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result";; + *) func_resolve_sysroot "$deplib" ;; + esac + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $func_resolve_sysroot_result "*) + func_append specialdeplibs " $func_resolve_sysroot_result" ;; + esac + fi + func_append tmp_libs " $func_resolve_sysroot_result" + done + + if test "$link_all_deplibs" != no; then + # Add the search paths of all dependency libraries + for deplib in $dependency_libs; do + path= + case $deplib in + -L*) path="$deplib" ;; + *.la) + func_resolve_sysroot "$deplib" + deplib=$func_resolve_sysroot_result + func_dirname "$deplib" "" "." + dir=$func_dirname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; + *) + absdir=`cd "$dir" && pwd` + if test -z "$absdir"; then + func_warning "cannot determine absolute directory name of \`$dir'" + absdir="$dir" + fi + ;; + esac + if $GREP "^installed=no" $deplib > /dev/null; then + case $host in + *-*-darwin*) + depdepl= + eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` + if test -n "$deplibrary_names" ; then + for tmp in $deplibrary_names ; do + depdepl=$tmp + done + if test -f "$absdir/$objdir/$depdepl" ; then + depdepl="$absdir/$objdir/$depdepl" + darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + if test -z "$darwin_install_name"; then + darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + fi + func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" + func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" + path= + fi + fi + ;; + *) + path="-L$absdir/$objdir" + ;; + esac + else + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + test -z "$libdir" && \ + func_fatal_error "\`$deplib' is not a valid libtool archive" + test "$absdir" != "$libdir" && \ + func_warning "\`$deplib' seems to be moved" + + path="-L$absdir" + fi + ;; + esac + case " $deplibs " in + *" $path "*) ;; + *) deplibs="$path $deplibs" ;; + esac + done + fi # link_all_deplibs != no + fi # linkmode = lib + done # for deplib in $libs + if test "$pass" = link; then + if test "$linkmode" = "prog"; then + compile_deplibs="$new_inherited_linker_flags $compile_deplibs" + finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" + else + compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + fi + fi + dependency_libs="$newdependency_libs" + if test "$pass" = dlpreopen; then + # Link the dlpreopened libraries before other libraries + for deplib in $save_deplibs; do + deplibs="$deplib $deplibs" + done + fi + if test "$pass" != dlopen; then + if test "$pass" != conv; then + # Make sure lib_search_path contains only unique directories. + lib_search_path= + for dir in $newlib_search_path; do + case "$lib_search_path " in + *" $dir "*) ;; + *) func_append lib_search_path " $dir" ;; + esac + done + newlib_search_path= + fi + + if test "$linkmode,$pass" != "prog,link"; then + vars="deplibs" + else + vars="compile_deplibs finalize_deplibs" + fi + for var in $vars dependency_libs; do + # Add libraries to $var in reverse order + eval tmp_libs=\"\$$var\" + new_libs= + for deplib in $tmp_libs; do + # FIXME: Pedantically, this is the right thing to do, so + # that some nasty dependency loop isn't accidentally + # broken: + #new_libs="$deplib $new_libs" + # Pragmatically, this seems to cause very few problems in + # practice: + case $deplib in + -L*) new_libs="$deplib $new_libs" ;; + -R*) ;; + *) + # And here is the reason: when a library appears more + # than once as an explicit dependence of a library, or + # is implicitly linked in more than once by the + # compiler, it is considered special, and multiple + # occurrences thereof are not removed. Compare this + # with having the same library being listed as a + # dependency of multiple other libraries: in this case, + # we know (pedantically, we assume) the library does not + # need to be listed more than once, so we keep only the + # last copy. This is not always right, but it is rare + # enough that we require users that really mean to play + # such unportable linking tricks to link the library + # using -Wl,-lname, so that libtool does not consider it + # for duplicate removal. + case " $specialdeplibs " in + *" $deplib "*) new_libs="$deplib $new_libs" ;; + *) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$deplib $new_libs" ;; + esac + ;; + esac + ;; + esac + done + tmp_libs= + for deplib in $new_libs; do + case $deplib in + -L*) + case " $tmp_libs " in + *" $deplib "*) ;; + *) func_append tmp_libs " $deplib" ;; + esac + ;; + *) func_append tmp_libs " $deplib" ;; + esac + done + eval $var=\"$tmp_libs\" + done # for var + fi + # Last step: remove runtime libs from dependency_libs + # (they stay in deplibs) + tmp_libs= + for i in $dependency_libs ; do + case " $predeps $postdeps $compiler_lib_search_path " in + *" $i "*) + i="" + ;; + esac + if test -n "$i" ; then + func_append tmp_libs " $i" + fi + done + dependency_libs=$tmp_libs + done # for pass + if test "$linkmode" = prog; then + dlfiles="$newdlfiles" + fi + if test "$linkmode" = prog || test "$linkmode" = lib; then + dlprefiles="$newdlprefiles" + fi + + case $linkmode in + oldlib) + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + func_warning "\`-dlopen' is ignored for archives" + fi + + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "\`-l' and \`-L' are ignored for archives" ;; + esac + + test -n "$rpath" && \ + func_warning "\`-rpath' is ignored for archives" + + test -n "$xrpath" && \ + func_warning "\`-R' is ignored for archives" + + test -n "$vinfo" && \ + func_warning "\`-version-info/-version-number' is ignored for archives" + + test -n "$release" && \ + func_warning "\`-release' is ignored for archives" + + test -n "$export_symbols$export_symbols_regex" && \ + func_warning "\`-export-symbols' is ignored for archives" + + # Now set the variables for building old libraries. + build_libtool_libs=no + oldlibs="$output" + func_append objs "$old_deplibs" + ;; + + lib) + # Make sure we only generate libraries of the form `libNAME.la'. + case $outputname in + lib*) + func_stripname 'lib' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + ;; + *) + test "$module" = no && \ + func_fatal_help "libtool library \`$output' must begin with \`lib'" + + if test "$need_lib_prefix" != no; then + # Add the "lib" prefix for modules if required + func_stripname '' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + else + func_stripname '' '.la' "$outputname" + libname=$func_stripname_result + fi + ;; + esac + + if test -n "$objs"; then + if test "$deplibs_check_method" != pass_all; then + func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs" + else + echo + $ECHO "*** Warning: Linking the shared library $output against the non-libtool" + $ECHO "*** objects $objs is not portable!" + func_append libobjs " $objs" + fi + fi + + test "$dlself" != no && \ + func_warning "\`-dlopen self' is ignored for libtool libraries" + + set dummy $rpath + shift + test "$#" -gt 1 && \ + func_warning "ignoring multiple \`-rpath's for a libtool library" + + install_libdir="$1" + + oldlibs= + if test -z "$rpath"; then + if test "$build_libtool_libs" = yes; then + # Building a libtool convenience library. + # Some compilers have problems with a `.al' extension so + # convenience libraries should have the same extension an + # archive normally would. + oldlibs="$output_objdir/$libname.$libext $oldlibs" + build_libtool_libs=convenience + build_old_libs=yes + fi + + test -n "$vinfo" && \ + func_warning "\`-version-info/-version-number' is ignored for convenience libraries" + + test -n "$release" && \ + func_warning "\`-release' is ignored for convenience libraries" + else + + # Parse the version information argument. + save_ifs="$IFS"; IFS=':' + set dummy $vinfo 0 0 0 + shift + IFS="$save_ifs" + + test -n "$7" && \ + func_fatal_help "too many parameters to \`-version-info'" + + # convert absolute version numbers to libtool ages + # this retains compatibility with .la files and attempts + # to make the code below a bit more comprehensible + + case $vinfo_number in + yes) + number_major="$1" + number_minor="$2" + number_revision="$3" + # + # There are really only two kinds -- those that + # use the current revision as the major version + # and those that subtract age and use age as + # a minor version. But, then there is irix + # which has an extra 1 added just for fun + # + case $version_type in + darwin|linux|osf|windows|none) + func_arith $number_major + $number_minor + current=$func_arith_result + age="$number_minor" + revision="$number_revision" + ;; + freebsd-aout|freebsd-elf|qnx|sunos) + current="$number_major" + revision="$number_minor" + age="0" + ;; + irix|nonstopux) + func_arith $number_major + $number_minor + current=$func_arith_result + age="$number_minor" + revision="$number_minor" + lt_irix_increment=no + ;; + esac + ;; + no) + current="$1" + revision="$2" + age="$3" + ;; + esac + + # Check that each of the things are valid numbers. + case $current in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "CURRENT \`$current' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + case $revision in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "REVISION \`$revision' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + case $age in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "AGE \`$age' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + if test "$age" -gt "$current"; then + func_error "AGE \`$age' is greater than the current interface number \`$current'" + func_fatal_error "\`$vinfo' is not valid version information" + fi + + # Calculate the version variables. + major= + versuffix= + verstring= + case $version_type in + none) ;; + + darwin) + # Like Linux, but with the current version available in + # verstring for coding it into the library header + func_arith $current - $age + major=.$func_arith_result + versuffix="$major.$age.$revision" + # Darwin ld doesn't like 0 for these options... + func_arith $current + 1 + minor_current=$func_arith_result + xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" + verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" + ;; + + freebsd-aout) + major=".$current" + versuffix=".$current.$revision"; + ;; + + freebsd-elf) + major=".$current" + versuffix=".$current" + ;; + + irix | nonstopux) + if test "X$lt_irix_increment" = "Xno"; then + func_arith $current - $age + else + func_arith $current - $age + 1 + fi + major=$func_arith_result + + case $version_type in + nonstopux) verstring_prefix=nonstopux ;; + *) verstring_prefix=sgi ;; + esac + verstring="$verstring_prefix$major.$revision" + + # Add in all the interfaces that we are compatible with. + loop=$revision + while test "$loop" -ne 0; do + func_arith $revision - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring="$verstring_prefix$major.$iface:$verstring" + done + + # Before this point, $major must not contain `.'. + major=.$major + versuffix="$major.$revision" + ;; + + linux) + func_arith $current - $age + major=.$func_arith_result + versuffix="$major.$age.$revision" + ;; + + osf) + func_arith $current - $age + major=.$func_arith_result + versuffix=".$current.$age.$revision" + verstring="$current.$age.$revision" + + # Add in all the interfaces that we are compatible with. + loop=$age + while test "$loop" -ne 0; do + func_arith $current - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring="$verstring:${iface}.0" + done + + # Make executables depend on our current version. + func_append verstring ":${current}.0" + ;; + + qnx) + major=".$current" + versuffix=".$current" + ;; + + sunos) + major=".$current" + versuffix=".$current.$revision" + ;; + + windows) + # Use '-' rather than '.', since we only want one + # extension on DOS 8.3 filesystems. + func_arith $current - $age + major=$func_arith_result + versuffix="-$major" + ;; + + *) + func_fatal_configuration "unknown library version type \`$version_type'" + ;; + esac + + # Clear the version info if we defaulted, and they specified a release. + if test -z "$vinfo" && test -n "$release"; then + major= + case $version_type in + darwin) + # we can't check for "0.0" in archive_cmds due to quoting + # problems, so we reset it completely + verstring= + ;; + *) + verstring="0.0" + ;; + esac + if test "$need_version" = no; then + versuffix= + else + versuffix=".0.0" + fi + fi + + # Remove version info from name if versioning should be avoided + if test "$avoid_version" = yes && test "$need_version" = no; then + major= + versuffix= + verstring="" + fi + + # Check to see if the archive will have undefined symbols. + if test "$allow_undefined" = yes; then + if test "$allow_undefined_flag" = unsupported; then + func_warning "undefined symbols not allowed in $host shared libraries" + build_libtool_libs=no + build_old_libs=yes + fi + else + # Don't allow undefined symbols. + allow_undefined_flag="$no_undefined_flag" + fi + + fi + + func_generate_dlsyms "$libname" "$libname" "yes" + func_append libobjs " $symfileobj" + test "X$libobjs" = "X " && libobjs= + + if test "$opt_mode" != relink; then + # Remove our outputs, but don't remove object files since they + # may have been created when compiling PIC objects. + removelist= + tempremovelist=`$ECHO "$output_objdir/*"` + for p in $tempremovelist; do + case $p in + *.$objext | *.gcno) + ;; + $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) + if test "X$precious_files_regex" != "X"; then + if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 + then + continue + fi + fi + func_append removelist " $p" + ;; + *) ;; + esac + done + test -n "$removelist" && \ + func_show_eval "${RM}r \$removelist" + fi + + # Now set the variables for building old libraries. + if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then + func_append oldlibs " $output_objdir/$libname.$libext" + + # Transform .lo files to .o files. + oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP` + fi + + # Eliminate all temporary directories. + #for path in $notinst_path; do + # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` + # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` + # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` + #done + + if test -n "$xrpath"; then + # If the user specified any rpath flags, then add them. + temp_xrpath= + for libdir in $xrpath; do + func_replace_sysroot "$libdir" + func_append temp_xrpath " -R$func_replace_sysroot_result" + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + done + if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then + dependency_libs="$temp_xrpath $dependency_libs" + fi + fi + + # Make sure dlfiles contains only unique files that won't be dlpreopened + old_dlfiles="$dlfiles" + dlfiles= + for lib in $old_dlfiles; do + case " $dlprefiles $dlfiles " in + *" $lib "*) ;; + *) func_append dlfiles " $lib" ;; + esac + done + + # Make sure dlprefiles contains only unique files + old_dlprefiles="$dlprefiles" + dlprefiles= + for lib in $old_dlprefiles; do + case "$dlprefiles " in + *" $lib "*) ;; + *) func_append dlprefiles " $lib" ;; + esac + done + + if test "$build_libtool_libs" = yes; then + if test -n "$rpath"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) + # these systems don't actually have a c library (as such)! + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C library is in the System framework + func_append deplibs " System.ltframework" + ;; + *-*-netbsd*) + # Don't link with libc until the a.out ld.so is fixed. + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + ;; + *) + # Add libc to deplibs on all other systems if necessary. + if test "$build_libtool_need_lc" = "yes"; then + func_append deplibs " -lc" + fi + ;; + esac + fi + + # Transform deplibs into only deplibs that can be linked in shared. + name_save=$name + libname_save=$libname + release_save=$release + versuffix_save=$versuffix + major_save=$major + # I'm not sure if I'm treating the release correctly. I think + # release should show up in the -l (ie -lgmp5) so we don't want to + # add it in twice. Is that correct? + release="" + versuffix="" + major="" + newdeplibs= + droppeddeps=no + case $deplibs_check_method in + pass_all) + # Don't check for shared/static. Everything works. + # This might be a little naive. We might want to check + # whether the library exists or not. But this is on + # osf3 & osf4 and I'm not really sure... Just + # implementing what was already the behavior. + newdeplibs=$deplibs + ;; + test_compile) + # This code stresses the "libraries are programs" paradigm to its + # limits. Maybe even breaks it. We compile a program, linking it + # against the deplibs as a proxy for the library. Then we can check + # whether they linked in statically or dynamically with ldd. + $opt_dry_run || $RM conftest.c + cat > conftest.c </dev/null` + $nocaseglob + else + potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` + fi + for potent_lib in $potential_libs; do + # Follow soft links. + if ls -lLd "$potent_lib" 2>/dev/null | + $GREP " -> " >/dev/null; then + continue + fi + # The statement above tries to avoid entering an + # endless loop below, in case of cyclic links. + # We might still enter an endless loop, since a link + # loop can be closed while we follow links, + # but so what? + potlib="$potent_lib" + while test -h "$potlib" 2>/dev/null; do + potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` + case $potliblink in + [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; + *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";; + esac + done + if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | + $SED -e 10q | + $EGREP "$file_magic_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $ECHO "*** with $libname but no candidates were found. (...for file magic test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a file magic. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + for a_deplib in $deplibs; do + case $a_deplib in + -l*) + func_stripname -l '' "$a_deplib" + name=$func_stripname_result + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $a_deplib "*) + func_append newdeplibs " $a_deplib" + a_deplib="" + ;; + esac + fi + if test -n "$a_deplib" ; then + libname=`eval "\\$ECHO \"$libname_spec\""` + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do + potential_libs=`ls $i/$libname[.-]* 2>/dev/null` + for potent_lib in $potential_libs; do + potlib="$potent_lib" # see symlink-check above in file_magic test + if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ + $EGREP "$match_pattern_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a regex pattern. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + none | unknown | *) + newdeplibs="" + tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + for i in $predeps $postdeps ; do + # can't use Xsed below, because $i might contain '/' + tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"` + done + fi + case $tmp_deplibs in + *[!\ \ ]*) + echo + if test "X$deplibs_check_method" = "Xnone"; then + echo "*** Warning: inter-library dependencies are not supported in this platform." + else + echo "*** Warning: inter-library dependencies are not known to be supported." + fi + echo "*** All declared inter-library dependencies are being dropped." + droppeddeps=yes + ;; + esac + ;; + esac + versuffix=$versuffix_save + major=$major_save + release=$release_save + libname=$libname_save + name=$name_save - if test ! -f \"\$progdir/\$program\" || \\ - { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ - test \"X\$file\" != \"X\$progdir/\$program\"; }; then + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library with the System framework + newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` + ;; + esac - file=\"\$\$-\$program\" + if test "$droppeddeps" = yes; then + if test "$module" = yes; then + echo + echo "*** Warning: libtool could not satisfy all declared inter-library" + $ECHO "*** dependencies of module $libname. Therefore, libtool will create" + echo "*** a static module, that should work as long as the dlopening" + echo "*** application is linked with the -dlopen flag." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + else + echo "*** The inter-library dependencies that have been dropped here will be" + echo "*** automatically added whenever a program is linked with this library" + echo "*** or is declared to -dlopen it." - if test ! -d \"\$progdir\"; then - $mkdir \"\$progdir\" - else - $rm \"\$progdir/\$file\" - fi" + if test "$allow_undefined" = no; then + echo + echo "*** Since this library must not contain undefined symbols," + echo "*** because either the platform does not support them or" + echo "*** it was explicitly requested with -no-undefined," + echo "*** libtool will only create a static version of it." + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + fi + fi + # Done checking deplibs! + deplibs=$newdeplibs + fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + case $host in + *-*-darwin*) + newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac - $echo >> $output "\ + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; + esac + done + deplibs="$new_libs" - # relink executable if necessary - if test -n \"\$relink_command\"; then - if relink_command_output=\`eval \$relink_command 2>&1\`; then : - else - $echo \"\$relink_command_output\" >&2 - $rm \"\$progdir/\$file\" - exit $EXIT_FAILURE - fi - fi + # All the library-specific variables (install_libdir is set above). + library_names= + old_library= + dlname= - $mv \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || - { $rm \"\$progdir/\$program\"; - $mv \"\$progdir/\$file\" \"\$progdir/\$program\"; } - $rm \"\$progdir/\$file\" - fi" - else - $echo >> $output "\ - program='$outputname' - progdir=\"\$thisdir/$objdir\" -" + # Test again, we may have decided not to build it any more + if test "$build_libtool_libs" = yes; then + if test "$hardcode_into_libs" = yes; then + # Hardcode the library paths + hardcode_libdirs= + dep_rpath= + rpath="$finalize_rpath" + test "$opt_mode" != relink && rpath="$compile_rpath$rpath" + for libdir in $rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + func_replace_sysroot "$libdir" + libdir=$func_replace_sysroot_result + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append dep_rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) func_apped perm_rpath " $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + if test -n "$hardcode_libdir_flag_spec_ld"; then + eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" + else + eval dep_rpath=\"$hardcode_libdir_flag_spec\" + fi + fi + if test -n "$runpath_var" && test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" + fi + test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" fi - $echo >> $output "\ + shlibpath="$finalize_shlibpath" + test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" + if test -n "$shlibpath"; then + eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" + fi - if test -f \"\$progdir/\$program\"; then" + # Get the real and link names of the library. + eval shared_ext=\"$shrext_cmds\" + eval library_names=\"$library_names_spec\" + set dummy $library_names + shift + realname="$1" + shift - # Export our shlibpath_var if we have one. - if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then - $echo >> $output "\ - # Add our own library path to $shlibpath_var - $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" + if test -n "$soname_spec"; then + eval soname=\"$soname_spec\" + else + soname="$realname" + fi + if test -z "$dlname"; then + dlname=$soname + fi - # Some systems cannot cope with colon-terminated $shlibpath_var - # The second colon is a workaround for a bug in BeOS R4 sed - $shlibpath_var=\`\$echo \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\` + lib="$output_objdir/$realname" + linknames= + for link + do + func_append linknames " $link" + done - export $shlibpath_var -" - fi + # Use standard objects if they are pic + test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` + test "X$libobjs" = "X " && libobjs= - # fixup the dll searchpath if we need to. - if test -n "$dllsearchpath"; then - $echo >> $output "\ - # Add the dll search path components to the executable PATH - PATH=$dllsearchpath:\$PATH -" + delfiles= + if test -n "$export_symbols" && test -n "$include_expsyms"; then + $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" + export_symbols="$output_objdir/$libname.uexp" + func_append delfiles " $export_symbols" fi - $echo >> $output "\ - if test \"\$libtool_execute_magic\" != \"$magic\"; then - # Run the actual program with our arguments. -" - case $host in - # Backslashes separate directories on plain windows - *-*-mingw | *-*-os2*) - $echo >> $output "\ - exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} -" - ;; - - *) - $echo >> $output "\ - exec \"\$progdir/\$program\" \${1+\"\$@\"} -" + orig_export_symbols= + case $host_os in + cygwin* | mingw* | cegcc*) + if test -n "$export_symbols" && test -z "$export_symbols_regex"; then + # exporting using user supplied symfile + if test "x`$SED 1q $export_symbols`" != xEXPORTS; then + # and it's NOT already a .def file. Must figure out + # which of the given symbols are data symbols and tag + # them as such. So, trigger use of export_symbols_cmds. + # export_symbols gets reassigned inside the "prepare + # the list of exported symbols" if statement, so the + # include_expsyms logic still works. + orig_export_symbols="$export_symbols" + export_symbols= + always_export_symbols=yes + fi + fi ;; esac - $echo >> $output "\ - \$echo \"\$0: cannot exec \$program \${1+\"\$@\"}\" - exit $EXIT_FAILURE - fi - else - # The program doesn't exist. - \$echo \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 - \$echo \"This script is just a wrapper for \$program.\" 1>&2 - $echo \"See the $PACKAGE documentation for more information.\" 1>&2 - exit $EXIT_FAILURE - fi -fi\ -" - chmod +x $output - fi - exit $EXIT_SUCCESS - ;; - esac - - # See if we need to build an old-fashioned archive. - for oldlib in $oldlibs; do - if test "$build_libtool_libs" = convenience; then - oldobjs="$libobjs_save" - addlibs="$convenience" - build_libtool_libs=no - else - if test "$build_libtool_libs" = module; then - oldobjs="$libobjs_save" - build_libtool_libs=no - else - oldobjs="$old_deplibs $non_pic_objects" + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then + func_verbose "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $opt_dry_run || $RM $export_symbols + cmds=$export_symbols_cmds + save_ifs="$IFS"; IFS='~' + for cmd1 in $cmds; do + IFS="$save_ifs" + # Take the normal branch if the nm_file_list_spec branch + # doesn't work or if tool conversion is not needed. + case $nm_file_list_spec~$to_tool_file_cmd in + *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) + try_normal_branch=yes + eval cmd=\"$cmd1\" + func_len " $cmd" + len=$func_len_result + ;; + *) + try_normal_branch=no + ;; + esac + if test "$try_normal_branch" = yes \ + && { test "$len" -lt "$max_cmd_len" \ + || test "$max_cmd_len" -le -1; } + then + func_show_eval "$cmd" 'exit $?' + skipped_export=false + elif test -n "$nm_file_list_spec"; then + func_basename "$output" + output_la=$func_basename_result + save_libobjs=$libobjs + save_output=$output + output=${output_objdir}/${output_la}.nm + func_to_tool_file "$output" + libobjs=$nm_file_list_spec$func_to_tool_file_result + func_append delfiles " $output" + func_verbose "creating $NM input file list: $output" + for obj in $save_libobjs; do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > "$output" + eval cmd=\"$cmd1\" + func_show_eval "$cmd" 'exit $?' + output=$save_output + libobjs=$save_libobjs + skipped_export=false + else + # The command line is too long to execute in one step. + func_verbose "using reloadable object file for export list..." + skipped_export=: + # Break out early, otherwise skipped_export may be + # set to false by a later but shorter cmd. + break + fi + done + IFS="$save_ifs" + if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi fi - addlibs="$old_convenience" - fi - if test -n "$addlibs"; then - gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols="$export_symbols" + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi - func_extract_archives $gentop $addlibs - oldobjs="$oldobjs $func_extract_archives_result" - fi + if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi - # Do each command in the archive commands. - if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then - cmds=$old_archive_from_new_cmds - else - # POSIX demands no paths to be encoded in archives. We have - # to avoid creating archives with duplicate basenames if we - # might have to extract them afterwards, e.g., when creating a - # static archive out of a convenience library, or when linking - # the entirety of a libtool archive into another (currently - # not supported by libtool). - if (for obj in $oldobjs - do - $echo "X$obj" | $Xsed -e 's%^.*/%%' - done | sort | sort -uc >/dev/null 2>&1); then - : - else - $echo "copying selected object files to avoid basename conflicts..." + tmp_deplibs= + for test_deplib in $deplibs; do + case " $convenience " in + *" $test_deplib "*) ;; + *) + func_append tmp_deplibs " $test_deplib" + ;; + esac + done + deplibs="$tmp_deplibs" - if test -z "$gentop"; then + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec" && + test "$compiler_needs_object" = yes && + test -z "$libobjs"; then + # extract the archives, so we have objects to list. + # TODO: could optimize this to just extract one archive. + whole_archive_flag_spec= + fi + if test -n "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + else gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" - - $show "${rm}r $gentop" - $run ${rm}r "$gentop" - $show "$mkdir $gentop" - $run $mkdir "$gentop" - exit_status=$? - if test "$exit_status" -ne 0 && test ! -d "$gentop"; then - exit $exit_status - fi + func_append generated " $gentop" + + func_extract_archives $gentop $convenience + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= fi + fi - save_oldobjs=$oldobjs - oldobjs= - counter=1 - for obj in $save_oldobjs - do - objbase=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` - case " $oldobjs " in - " ") oldobjs=$obj ;; - *[\ /]"$objbase "*) - while :; do - # Make sure we don't pick an alternate name that also - # overlaps. - newobj=lt$counter-$objbase - counter=`expr $counter + 1` - case " $oldobjs " in - *[\ /]"$newobj "*) ;; - *) if test ! -f "$gentop/$newobj"; then break; fi ;; - esac - done - $show "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" - $run ln "$obj" "$gentop/$newobj" || - $run cp "$obj" "$gentop/$newobj" - oldobjs="$oldobjs $gentop/$newobj" - ;; - *) oldobjs="$oldobjs $obj" ;; - esac - done + if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then + eval flag=\"$thread_safe_flag_spec\" + func_append linker_flags " $flag" fi - eval cmds=\"$old_archive_cmds\" + # Make a backup of the uninstalled library when relinking + if test "$opt_mode" = relink; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? + fi - if len=`expr "X$cmds" : ".*"` && - test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then - cmds=$old_archive_cmds + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + eval test_cmds=\"$module_expsym_cmds\" + cmds=$module_expsym_cmds + else + eval test_cmds=\"$module_cmds\" + cmds=$module_cmds + fi else - # the command line is too long to link in one step, link in parts - $echo "using piecewise archive linking..." - save_RANLIB=$RANLIB - RANLIB=: - objlist= - concat_cmds= - save_oldobjs=$oldobjs - - # Is there a better way of finding the last object in the list? - for obj in $save_oldobjs - do - last_oldobj=$obj - done - for obj in $save_oldobjs - do - oldobjs="$objlist $obj" - objlist="$objlist $obj" - eval test_cmds=\"$old_archive_cmds\" - if len=`expr "X$test_cmds" : ".*" 2>/dev/null` && - test "$len" -le "$max_cmd_len"; then - : - else - # the above command should be used before it gets too long - oldobjs=$objlist - if test "$obj" = "$last_oldobj" ; then - RANLIB=$save_RANLIB - fi - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" - objlist= - fi - done - RANLIB=$save_RANLIB - oldobjs=$objlist - if test "X$oldobjs" = "X" ; then - eval cmds=\"\$concat_cmds\" + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + eval test_cmds=\"$archive_expsym_cmds\" + cmds=$archive_expsym_cmds else - eval cmds=\"\$concat_cmds~\$old_archive_cmds\" + eval test_cmds=\"$archive_cmds\" + cmds=$archive_cmds fi fi - fi - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - eval cmd=\"$cmd\" - IFS="$save_ifs" - $show "$cmd" - $run eval "$cmd" || exit $? - done - IFS="$save_ifs" - done - - if test -n "$generated"; then - $show "${rm}r$generated" - $run ${rm}r$generated - fi - - # Now create the libtool archive. - case $output in - *.la) - old_library= - test "$build_old_libs" = yes && old_library="$libname.$libext" - $show "creating $output" - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" + if test "X$skipped_export" != "X:" && + func_len " $test_cmds" && + len=$func_len_result && + test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + : else - var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` - relink_command="$var=\"$var_value\"; export $var; $relink_command" - fi - done - # Quote the link command for shipping. - relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" - relink_command=`$echo "X$relink_command" | $Xsed -e "$sed_quote_subst"` - if test "$hardcode_automatic" = yes ; then - relink_command= - fi + # The command line is too long to link in one step, link piecewise + # or, if using GNU ld and skipped_export is not :, use a linker + # script. + # Save the value of $output and $libobjs because we want to + # use them later. If we have whole_archive_flag_spec, we + # want to use save_libobjs as it was before + # whole_archive_flag_spec was expanded, because we can't + # assume the linker understands whole_archive_flag_spec. + # This may have to be revisited, in case too many + # convenience libraries get linked in and end up exceeding + # the spec. + if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + fi + save_output=$output + func_basename "$output" + output_la=$func_basename_result - # Only create the output if not a dry run. - if test -z "$run"; then - for installed in no yes; do - if test "$installed" = yes; then - if test -z "$install_libdir"; then - break + # Clear the reloadable object creation command queue and + # initialize k to one. + test_cmds= + concat_cmds= + objlist= + last_robj= + k=1 + + if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then + output=${output_objdir}/${output_la}.lnkscript + func_verbose "creating GNU ld script: $output" + echo 'INPUT (' > $output + for obj in $save_libobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + echo ')' >> $output + func_append delfiles " $output" + func_to_tool_file "$output" + output=$func_to_tool_file_result + elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then + output=${output_objdir}/${output_la}.lnk + func_verbose "creating linker input file list: $output" + : > $output + set x $save_libobjs + shift + firstobj= + if test "$compiler_needs_object" = yes; then + firstobj="$1 " + shift fi - output="$output_objdir/$outputname"i - # Replace all uninstalled libtool libraries with the installed ones - newdependency_libs= - for deplib in $dependency_libs; do - case $deplib in - *.la) - name=`$echo "X$deplib" | $Xsed -e 's%^.*/%%'` - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - if test -z "$libdir"; then - $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 - exit $EXIT_FAILURE - fi - newdependency_libs="$newdependency_libs $libdir/$name" - ;; - *) newdependency_libs="$newdependency_libs $deplib" ;; - esac + for obj + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output done - dependency_libs="$newdependency_libs" - newdlfiles= - for lib in $dlfiles; do - name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - if test -z "$libdir"; then - $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 - exit $EXIT_FAILURE + func_append delfiles " $output" + func_to_tool_file "$output" + output=$firstobj\"$file_list_spec$func_to_tool_file_result\" + else + if test -n "$save_libobjs"; then + func_verbose "creating reloadable object files..." + output=$output_objdir/$output_la-${k}.$objext + eval test_cmds=\"$reload_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + + # Loop over the list of objects to be linked. + for obj in $save_libobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + if test "X$objlist" = X || + test "$len" -lt "$max_cmd_len"; then + func_append objlist " $obj" + else + # The command $test_cmds is almost too long, add a + # command to the queue. + if test "$k" -eq 1 ; then + # The first file doesn't have a previous command to add. + reload_objs=$objlist + eval concat_cmds=\"$reload_cmds\" + else + # All subsequent reloadable object files will link in + # the last one created. + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" + fi + last_robj=$output_objdir/$output_la-${k}.$objext + func_arith $k + 1 + k=$func_arith_result + output=$output_objdir/$output_la-${k}.$objext + objlist=" $obj" + func_len " $last_robj" + func_arith $len0 + $func_len_result + len=$func_arith_result + fi + done + # Handle the remaining objects by creating one last + # reloadable object file. All subsequent reloadable object + # files will link in the last one created. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\${concat_cmds}$reload_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" fi - newdlfiles="$newdlfiles $libdir/$name" - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - if test -z "$libdir"; then - $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 - exit $EXIT_FAILURE + func_append delfiles " $output" + + else + output= + fi + + if ${skipped_export-false}; then + func_verbose "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $opt_dry_run || $RM $export_symbols + libobjs=$output + # Append the command to create the export file. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" fi - newdlprefiles="$newdlprefiles $libdir/$name" + fi + + test -n "$save_libobjs" && + func_verbose "creating a temporary reloadable object file: $output" + + # Loop through the commands generated above and execute them. + save_ifs="$IFS"; IFS='~' + for cmd in $concat_cmds; do + IFS="$save_ifs" + $opt_silent || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi + + exit $lt_exit + } done - dlprefiles="$newdlprefiles" + IFS="$save_ifs" + + if test -n "$export_symbols_regex" && ${skipped_export-false}; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi + + if ${skipped_export-false}; then + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols="$export_symbols" + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi + + if test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi + fi + + libobjs=$output + # Restore the value of output. + output=$save_output + + if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + fi + # Expand the library linking commands again to reset the + # value of $libobjs for piecewise linking. + + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + cmds=$module_expsym_cmds + else + cmds=$module_cmds + fi else - newdlfiles= - for lib in $dlfiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - newdlfiles="$newdlfiles $abs" - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - newdlprefiles="$newdlprefiles $abs" - done - dlprefiles="$newdlprefiles" + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + cmds=$archive_expsym_cmds + else + cmds=$archive_cmds + fi fi - $rm $output - # place dlname in correct position for cygwin - tdlname=$dlname - case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;; - esac - $echo > $output "\ -# $outputname - a libtool library file -# Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP -# -# Please DO NOT delete this file! -# It is necessary for linking the library. + fi -# The name that we can dlopen(3). -dlname='$tdlname' + if test -n "$delfiles"; then + # Append the command to remove temporary files to $cmds. + eval cmds=\"\$cmds~\$RM $delfiles\" + fi -# Names of this library. -library_names='$library_names' + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" -# The name of the static archive. -old_library='$old_library' + func_extract_archives $gentop $dlprefiles + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= + fi -# Libraries that this one depends upon. -dependency_libs='$dependency_libs' + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $opt_silent || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? -# Version information for $libname. -current=$current -age=$age -revision=$revision + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi -# Is this an already installed library? -installed=$installed + exit $lt_exit + } + done + IFS="$save_ifs" -# Should we warn about portability when linking against -modules? -shouldnotlink=$module + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? -# Files to dlopen/dlpreopen -dlopen='$dlfiles' -dlpreopen='$dlprefiles' + if test -n "$convenience"; then + if test -z "$whole_archive_flag_spec"; then + func_show_eval '${RM}r "$gentop"' + fi + fi -# Directory that this library needs to be installed in: -libdir='$install_libdir'" - if test "$installed" = no && test "$need_relink" = yes; then - $echo >> $output "\ -relink_command=\"$relink_command\"" + exit $EXIT_SUCCESS + fi + + # Create links to the real library. + for linkname in $linknames; do + if test "$realname" != "$linkname"; then + func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' fi done - fi - # Do a symbolic link so that the libtool archive can be found in - # LD_LIBRARY_PATH before the program is installed. - $show "(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)" - $run eval '(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)' || exit $? + # If -module or -export-dynamic was specified, set the dlname. + if test "$module" = yes || test "$export_dynamic" = yes; then + # On all known operating systems, these are identical. + dlname="$soname" + fi + fi ;; - esac - exit $EXIT_SUCCESS - ;; - # libtool install mode - install) - modename="$modename: install" + obj) + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + func_warning "\`-dlopen' is ignored for objects" + fi - # There may be an optional sh(1) argument at the beginning of - # install_prog (especially on Windows NT). - if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || - # Allow the use of GNU shtool's install command. - $echo "X$nonopt" | grep shtool > /dev/null; then - # Aesthetically quote it. - arg=`$echo "X$nonopt" | $Xsed -e "$sed_quote_subst"` - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "\`-l' and \`-L' are ignored for objects" ;; esac - install_prog="$arg " - arg="$1" - shift - else - install_prog= - arg=$nonopt - fi - # The real first argument should be the name of the installation program. - # Aesthetically quote it. - arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac - install_prog="$install_prog$arg" + test -n "$rpath" && \ + func_warning "\`-rpath' is ignored for objects" - # We need to accept at least all the BSD install flags. - dest= - files= - opts= - prev= - install_type= - isdir=no - stripme= - for arg - do - if test -n "$dest"; then - files="$files $dest" - dest=$arg - continue - fi + test -n "$xrpath" && \ + func_warning "\`-R' is ignored for objects" - case $arg in - -d) isdir=yes ;; - -f) - case " $install_prog " in - *[\\\ /]cp\ *) ;; - *) prev=$arg ;; - esac - ;; - -g | -m | -o) prev=$arg ;; - -s) - stripme=" -s" - continue - ;; - -*) + test -n "$vinfo" && \ + func_warning "\`-version-info' is ignored for objects" + + test -n "$release" && \ + func_warning "\`-release' is ignored for objects" + + case $output in + *.lo) + test -n "$objs$old_deplibs" && \ + func_fatal_error "cannot build library object \`$output' from non-libtool objects" + + libobj=$output + func_lo2o "$libobj" + obj=$func_lo2o_result ;; *) - # If the previous option needed an argument, then skip it. - if test -n "$prev"; then - prev= - else - dest=$arg - continue - fi + libobj= + obj="$output" ;; esac - # Aesthetically quote the argument. - arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` - case $arg in - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - arg="\"$arg\"" - ;; - esac - install_prog="$install_prog $arg" - done + # Delete the old objects. + $opt_dry_run || $RM $obj $libobj - if test -z "$install_prog"; then - $echo "$modename: you must specify an install program" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi + # Objects from convenience libraries. This assumes + # single-version convenience libraries. Whenever we create + # different ones for PIC/non-PIC, this we'll have to duplicate + # the extraction. + reload_conv_objs= + gentop= + # reload_cmds runs $LD directly, so let us get rid of + # -Wl from whole_archive_flag_spec and hope we can get by with + # turning comma into space.. + wl= - if test -n "$prev"; then - $echo "$modename: the \`$prev' option requires an argument" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec"; then + eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" + reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` + else + gentop="$output_objdir/${obj}x" + func_append generated " $gentop" - if test -z "$files"; then - if test -z "$dest"; then - $echo "$modename: no file or destination specified" 1>&2 - else - $echo "$modename: you must specify a destination" 1>&2 + func_extract_archives $gentop $convenience + reload_conv_objs="$reload_objs $func_extract_archives_result" + fi fi - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi - # Strip any trailing slash from the destination. - dest=`$echo "X$dest" | $Xsed -e 's%/$%%'` + # If we're not building shared, we need to use non_pic_objs + test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" - # Check to see that the destination is a directory. - test -d "$dest" && isdir=yes - if test "$isdir" = yes; then - destdir="$dest" - destname= - else - destdir=`$echo "X$dest" | $Xsed -e 's%/[^/]*$%%'` - test "X$destdir" = "X$dest" && destdir=. - destname=`$echo "X$dest" | $Xsed -e 's%^.*/%%'` + # Create the old-style object. + reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test - # Not a directory, so check to see that there is only one file specified. - set dummy $files - if test "$#" -gt 2; then - $echo "$modename: \`$dest' is not a directory" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE + output="$obj" + func_execute_cmds "$reload_cmds" 'exit $?' + + # Exit if we aren't doing a library object file. + if test -z "$libobj"; then + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS fi - fi - case $destdir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - for file in $files; do - case $file in - *.lo) ;; - *) - $echo "$modename: \`$destdir' must be an absolute directory name" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - ;; - esac - done + + if test "$build_libtool_libs" != yes; then + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + # Create an invalid libtool object if no PIC, so that we don't + # accidentally link it into a program. + # $show "echo timestamp > $libobj" + # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? + exit $EXIT_SUCCESS + fi + + if test -n "$pic_flag" || test "$pic_mode" != default; then + # Only do commands if we really have different PIC objects. + reload_objs="$libobjs $reload_conv_objs" + output="$libobj" + func_execute_cmds "$reload_cmds" 'exit $?' + fi + + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS ;; - esac - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" + prog) + case $host in + *cygwin*) func_stripname '' '.exe' "$output" + output=$func_stripname_result.exe;; + esac + test -n "$vinfo" && \ + func_warning "\`-version-info' is ignored for programs" - staticlibs= - future_libdirs= - current_libdirs= - for file in $files; do + test -n "$release" && \ + func_warning "\`-release' is ignored for programs" - # Do each installation. - case $file in - *.$libext) - # Do the static libraries later. - staticlibs="$staticlibs $file" + test "$preload" = yes \ + && test "$dlopen_support" = unknown \ + && test "$dlopen_self" = unknown \ + && test "$dlopen_self_static" = unknown && \ + func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support." + + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library is the System framework + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` ;; + esac - *.la) - # Check to see that this really is a libtool archive. - if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : - else - $echo "$modename: \`$file' is not a valid libtool archive" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE + case $host in + *-*-darwin*) + # Don't allow lazy linking, it breaks C++ global constructors + # But is supposedly fixed on 10.4 or later (yay!). + if test "$tagname" = CXX ; then + case ${MACOSX_DEPLOYMENT_TARGET-10.0} in + 10.[0123]) + func_append compile_command " ${wl}-bind_at_load" + func_append finalize_command " ${wl}-bind_at_load" + ;; + esac fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac - library_names= - old_library= - relink_command= - # If there is no directory component, then add one. - case $file in - */* | *\\*) . $file ;; - *) . ./$file ;; + + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $compile_deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $compile_deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; esac + done + compile_deplibs="$new_libs" - # Add the libdir to current_libdirs if it is the destination. - if test "X$destdir" = "X$libdir"; then - case "$current_libdirs " in + + func_append compile_command " $compile_deplibs" + func_append finalize_command " $finalize_deplibs" + + if test -n "$rpath$xrpath"; then + # If the user specified any rpath flags, then add them. + for libdir in $rpath $xrpath; do + # This is the magic to use -rpath. + case "$finalize_rpath " in *" $libdir "*) ;; - *) current_libdirs="$current_libdirs $libdir" ;; + *) func_append finalize_rpath " $libdir" ;; esac - else - # Note the libdir as a future libdir. - case "$future_libdirs " in + done + fi + + # Now hardcode the library paths + rpath= + hardcode_libdirs= + for libdir in $compile_rpath $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in *" $libdir "*) ;; - *) future_libdirs="$future_libdirs $libdir" ;; + *) func_append perm_rpath " $libdir" ;; esac fi + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$libdir:"*) ;; + ::) dllsearchpath=$libdir;; + *) func_append dllsearchpath ":$libdir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + compile_rpath="$rpath" - dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'`/ - test "X$dir" = "X$file/" && dir= - dir="$dir$objdir" - - if test -n "$relink_command"; then - # Determine the prefix the user has applied to our future dir. - inst_prefix_dir=`$echo "$destdir" | $SED "s%$libdir\$%%"` - - # Don't allow the user to place us outside of our expected - # location b/c this prevents finding dependent libraries that - # are installed to the same prefix. - # At present, this check doesn't affect windows .dll's that - # are installed into $libdir/../bin (currently, that works fine) - # but it's something to keep an eye on. - if test "$inst_prefix_dir" = "$destdir"; then - $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2 - exit $EXIT_FAILURE - fi - - if test -n "$inst_prefix_dir"; then - # Stick the inst_prefix_dir data into the link command. - relink_command=`$echo "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` - else - relink_command=`$echo "$relink_command" | $SED "s%@inst_prefix_dir@%%"` - fi - - $echo "$modename: warning: relinking \`$file'" 1>&2 - $show "$relink_command" - if $run eval "$relink_command"; then : + rpath= + hardcode_libdirs= + for libdir in $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi else - $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 - exit $EXIT_FAILURE + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" fi + elif test -n "$runpath_var"; then + case "$finalize_perm_rpath " in + *" $libdir "*) ;; + *) func_append finalize_perm_rpath " $libdir" ;; + esac fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + finalize_rpath="$rpath" - # See the names of the shared library. - set dummy $library_names - if test -n "$2"; then - realname="$2" - shift - shift + if test -n "$libobjs" && test "$build_old_libs" = yes; then + # Transform all the library objects into standard objects. + compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + fi - srcname="$realname" - test -n "$relink_command" && srcname="$realname"T + func_generate_dlsyms "$outputname" "@PROGRAM@" "no" - # Install the shared library and build the symlinks. - $show "$install_prog $dir/$srcname $destdir/$realname" - $run eval "$install_prog $dir/$srcname $destdir/$realname" || exit $? - if test -n "$stripme" && test -n "$striplib"; then - $show "$striplib $destdir/$realname" - $run eval "$striplib $destdir/$realname" || exit $? - fi + # template prelinking step + if test -n "$prelink_cmds"; then + func_execute_cmds "$prelink_cmds" 'exit $?' + fi - if test "$#" -gt 0; then - # Delete the old symlinks, and create new ones. - # Try `ln -sf' first, because the `ln' binary might depend on - # the symlink we replace! Solaris /bin/ln does not understand -f, - # so we also need to try rm && ln -s. - for linkname - do - if test "$linkname" != "$realname"; then - $show "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" - $run eval "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" - fi - done - fi + wrappers_required=yes + case $host in + *cegcc* | *mingw32ce*) + # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. + wrappers_required=no + ;; + *cygwin* | *mingw* ) + if test "$build_libtool_libs" != yes; then + wrappers_required=no + fi + ;; + *) + if test "$need_relink" = no || test "$build_libtool_libs" != yes; then + wrappers_required=no + fi + ;; + esac + if test "$wrappers_required" = no; then + # Replace the output file specification. + compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + link_command="$compile_command$compile_rpath" - # Do each command in the postinstall commands. - lib="$destdir/$realname" - cmds=$postinstall_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$mode" = relink; then - $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' - fi + # We have no uninstalled library dependencies, so finalize right now. + exit_status=0 + func_show_eval "$link_command" 'exit_status=$?' - exit $lt_exit - } - done - IFS="$save_ifs" + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' fi - # Install the pseudo-library for information purposes. - name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` - instname="$dir/$name"i - $show "$install_prog $instname $destdir/$name" - $run eval "$install_prog $instname $destdir/$name" || exit $? + # Delete the generated files. + if test -f "$output_objdir/${outputname}S.${objext}"; then + func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' + fi - # Maybe install the static library, too. - test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" - ;; + exit $exit_status + fi - *.lo) - # Install (i.e. copy) a libtool object. + if test -n "$compile_shlibpath$finalize_shlibpath"; then + compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" + fi + if test -n "$finalize_shlibpath"; then + finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" + fi - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` - destfile="$destdir/$destfile" + compile_var= + finalize_var= + if test -n "$runpath_var"; then + if test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi - - # Deduce the name of the destination old-style object file. - case $destfile in - *.lo) - staticdest=`$echo "X$destfile" | $Xsed -e "$lo2o"` - ;; - *.$objext) - staticdest="$destfile" - destfile= - ;; - *) - $echo "$modename: cannot copy a libtool object to \`$destfile'" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - ;; - esac - - # Install the libtool object if requested. - if test -n "$destfile"; then - $show "$install_prog $file $destfile" - $run eval "$install_prog $file $destfile" || exit $? + if test -n "$finalize_perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $finalize_perm_rpath; do + func_append rpath "$dir:" + done + finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi + fi - # Install the old object if enabled. - if test "$build_old_libs" = yes; then - # Deduce the name of the old-style object file. - staticobj=`$echo "X$file" | $Xsed -e "$lo2o"` + if test "$no_install" = yes; then + # We don't need to create a wrapper script. + link_command="$compile_var$compile_command$compile_rpath" + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + # Delete the old output file. + $opt_dry_run || $RM $output + # Link the executable and exit + func_show_eval "$link_command" 'exit $?' - $show "$install_prog $staticobj $staticdest" - $run eval "$install_prog \$staticobj \$staticdest" || exit $? + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' fi + exit $EXIT_SUCCESS - ;; + fi - *) - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" + if test "$hardcode_action" = relink; then + # Fast installation is not supported + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" + + func_warning "this platform does not like uninstalled shared libraries" + func_warning "\`$output' will be relinked during installation" + else + if test "$fast_install" != no; then + link_command="$finalize_var$compile_command$finalize_rpath" + if test "$fast_install" = yes; then + relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` + else + # fast_install is set to needless + relink_command= + fi else - destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` - destfile="$destdir/$destfile" + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" fi + fi - # If the file is missing, and there is a .exe on the end, strip it - # because it is most likely a libtool script we actually want to - # install - stripped_ext="" - case $file in - *.exe) - if test ! -f "$file"; then - file=`$echo $file|${SED} 's,.exe$,,'` - stripped_ext=".exe" - fi - ;; - esac + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` - # Do a test to see if this is really a libtool program. - case $host in - *cygwin*|*mingw*) - wrapper=`$echo $file | ${SED} -e 's,.exe$,,'` - ;; - *) - wrapper=$file - ;; - esac - if (${SED} -e '4q' $wrapper | grep "^# Generated by .*$PACKAGE")>/dev/null 2>&1; then - notinst_deplibs= - relink_command= + # Delete the old output files. + $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname - # Note that it is not necessary on cygwin/mingw to append a dot to - # foo even if both foo and FILE.exe exist: automatic-append-.exe - # behavior happens only for exec(3), not for open(2)! Also, sourcing - # `FILE.' does not work on cygwin managed mounts. - # - # If there is no directory component, then add one. - case $wrapper in - */* | *\\*) . ${wrapper} ;; - *) . ./${wrapper} ;; - esac + func_show_eval "$link_command" 'exit $?' - # Check the variables that should have been set. - if test -z "$notinst_deplibs"; then - $echo "$modename: invalid libtool wrapper script \`$wrapper'" 1>&2 - exit $EXIT_FAILURE - fi + if test -n "$postlink_cmds"; then + func_to_tool_file "$output_objdir/$outputname" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi - finalize=yes - for lib in $notinst_deplibs; do - # Check to see that each library is installed. - libdir= - if test -f "$lib"; then - # If there is no directory component, then add one. - case $lib in - */* | *\\*) . $lib ;; - *) . ./$lib ;; - esac - fi - libfile="$libdir/"`$echo "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test - if test -n "$libdir" && test ! -f "$libfile"; then - $echo "$modename: warning: \`$lib' has not been installed in \`$libdir'" 1>&2 - finalize=no - fi - done + # Now create the wrapper script. + func_verbose "creating $output" - relink_command= - # Note that it is not necessary on cygwin/mingw to append a dot to - # foo even if both foo and FILE.exe exist: automatic-append-.exe - # behavior happens only for exec(3), not for open(2)! Also, sourcing - # `FILE.' does not work on cygwin managed mounts. - # - # If there is no directory component, then add one. - case $wrapper in - */* | *\\*) . ${wrapper} ;; - *) . ./${wrapper} ;; - esac + # Quote the relink command for shipping. + if test -n "$relink_command"; then + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + fi + done + relink_command="(cd `pwd`; $relink_command)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + fi + + # Only actually do things if not in dry run mode. + $opt_dry_run || { + # win32 will think the script is a binary if it has + # a .exe suffix, so we strip it off here. + case $output in + *.exe) func_stripname '' '.exe' "$output" + output=$func_stripname_result ;; + esac + # test for cygwin because mv fails w/o .exe extensions + case $host in + *cygwin*) + exeext=.exe + func_stripname '' '.exe' "$outputname" + outputname=$func_stripname_result ;; + *) exeext= ;; + esac + case $host in + *cygwin* | *mingw* ) + func_dirname_and_basename "$output" "" "." + output_name=$func_basename_result + output_path=$func_dirname_result + cwrappersource="$output_path/$objdir/lt-$output_name.c" + cwrapper="$output_path/$output_name.exe" + $RM $cwrappersource $cwrapper + trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 + + func_emit_cwrapperexe_src > $cwrappersource + + # The wrapper executable is built using the $host compiler, + # because it contains $host paths and files. If cross- + # compiling, it, like the target executable, must be + # executed on the $host or under an emulation environment. + $opt_dry_run || { + $LTCC $LTCFLAGS -o $cwrapper $cwrappersource + $STRIP $cwrapper + } - outputname= - if test "$fast_install" = no && test -n "$relink_command"; then - if test "$finalize" = yes && test -z "$run"; then - tmpdir=`func_mktempdir` - file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` - outputname="$tmpdir/$file" - # Replace the output file specification. - relink_command=`$echo "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'` - - $show "$relink_command" - if $run eval "$relink_command"; then : + # Now, create the wrapper script for func_source use: + func_ltwrapper_scriptname $cwrapper + $RM $func_ltwrapper_scriptname_result + trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 + $opt_dry_run || { + # note: this script will not be executed, so do not chmod. + if test "x$build" = "x$host" ; then + $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result else - $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 - ${rm}r "$tmpdir" - continue + func_emit_wrapper no > $func_ltwrapper_scriptname_result fi - file="$outputname" - else - $echo "$modename: warning: cannot relink \`$file'" 1>&2 - fi - else - # Install the binary that we compiled earlier. - file=`$echo "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"` - fi - fi + } + ;; + * ) + $RM $output + trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 - # remove .exe since cygwin /usr/bin/install will append another - # one anyway - case $install_prog,$host in - */usr/bin/install*,*cygwin*) - case $file:$destfile in - *.exe:*.exe) - # this is ok - ;; - *.exe:*) - destfile=$destfile.exe - ;; - *:*.exe) - destfile=`$echo $destfile | ${SED} -e 's,.exe$,,'` - ;; - esac + func_emit_wrapper no > $output + chmod +x $output ;; esac - $show "$install_prog$stripme $file $destfile" - $run eval "$install_prog\$stripme \$file \$destfile" || exit $? - test -n "$outputname" && ${rm}r "$tmpdir" - ;; - esac - done - - for file in $staticlibs; do - name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` - - # Set up the ranlib parameters. - oldlib="$destdir/$name" + } + exit $EXIT_SUCCESS + ;; + esac - $show "$install_prog $file $oldlib" - $run eval "$install_prog \$file \$oldlib" || exit $? + # See if we need to build an old-fashioned archive. + for oldlib in $oldlibs; do - if test -n "$stripme" && test -n "$old_striplib"; then - $show "$old_striplib $oldlib" - $run eval "$old_striplib $oldlib" || exit $? + if test "$build_libtool_libs" = convenience; then + oldobjs="$libobjs_save $symfileobj" + addlibs="$convenience" + build_libtool_libs=no + else + if test "$build_libtool_libs" = module; then + oldobjs="$libobjs_save" + build_libtool_libs=no + else + oldobjs="$old_deplibs $non_pic_objects" + if test "$preload" = yes && test -f "$symfileobj"; then + func_append oldobjs " $symfileobj" + fi + fi + addlibs="$old_convenience" fi - # Do each command in the postinstall commands. - cmds=$old_postinstall_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || exit $? - done - IFS="$save_ifs" - done + if test -n "$addlibs"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" - if test -n "$future_libdirs"; then - $echo "$modename: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2 - fi + func_extract_archives $gentop $addlibs + func_append oldobjs " $func_extract_archives_result" + fi - if test -n "$current_libdirs"; then - # Maybe just do a dry run. - test -n "$run" && current_libdirs=" -n$current_libdirs" - exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' - else - exit $EXIT_SUCCESS - fi - ;; + # Do each command in the archive commands. + if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then + cmds=$old_archive_from_new_cmds + else - # libtool finish mode - finish) - modename="$modename: finish" - libdirs="$nonopt" - admincmds= + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - for dir - do - libdirs="$libdirs $dir" - done + func_extract_archives $gentop $dlprefiles + func_append oldobjs " $func_extract_archives_result" + fi - for libdir in $libdirs; do - if test -n "$finish_cmds"; then - # Do each command in the finish commands. - cmds=$finish_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" || admincmds="$admincmds - $cmd" + # POSIX demands no paths to be encoded in archives. We have + # to avoid creating archives with duplicate basenames if we + # might have to extract them afterwards, e.g., when creating a + # static archive out of a convenience library, or when linking + # the entirety of a libtool archive into another (currently + # not supported by libtool). + if (for obj in $oldobjs + do + func_basename "$obj" + $ECHO "$func_basename_result" + done | sort | sort -uc >/dev/null 2>&1); then + : + else + echo "copying selected object files to avoid basename conflicts..." + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + func_mkdir_p "$gentop" + save_oldobjs=$oldobjs + oldobjs= + counter=1 + for obj in $save_oldobjs + do + func_basename "$obj" + objbase="$func_basename_result" + case " $oldobjs " in + " ") oldobjs=$obj ;; + *[\ /]"$objbase "*) + while :; do + # Make sure we don't pick an alternate name that also + # overlaps. + newobj=lt$counter-$objbase + func_arith $counter + 1 + counter=$func_arith_result + case " $oldobjs " in + *[\ /]"$newobj "*) ;; + *) if test ! -f "$gentop/$newobj"; then break; fi ;; + esac + done + func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" + func_append oldobjs " $gentop/$newobj" + ;; + *) func_append oldobjs " $obj" ;; + esac done - IFS="$save_ifs" - fi - if test -n "$finish_eval"; then - # Do the single finish_eval. - eval cmds=\"$finish_eval\" - $run eval "$cmds" || admincmds="$admincmds - $cmds" fi - done - fi - - # Exit here if they wanted silent mode. - test "$show" = : && exit $EXIT_SUCCESS + eval cmds=\"$old_archive_cmds\" - $echo "X----------------------------------------------------------------------" | $Xsed - $echo "Libraries have been installed in:" - for libdir in $libdirs; do - $echo " $libdir" + func_len " $cmds" + len=$func_len_result + if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + cmds=$old_archive_cmds + elif test -n "$archiver_list_spec"; then + func_verbose "using command file archive linking..." + for obj in $oldobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > $output_objdir/$libname.libcmd + func_to_tool_file "$output_objdir/$libname.libcmd" + oldobjs=" $archiver_list_spec$func_to_tool_file_result" + cmds=$old_archive_cmds + else + # the command line is too long to link in one step, link in parts + func_verbose "using piecewise archive linking..." + save_RANLIB=$RANLIB + RANLIB=: + objlist= + concat_cmds= + save_oldobjs=$oldobjs + oldobjs= + # Is there a better way of finding the last object in the list? + for obj in $save_oldobjs + do + last_oldobj=$obj + done + eval test_cmds=\"$old_archive_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + for obj in $save_oldobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + func_append objlist " $obj" + if test "$len" -lt "$max_cmd_len"; then + : + else + # the above command should be used before it gets too long + oldobjs=$objlist + if test "$obj" = "$last_oldobj" ; then + RANLIB=$save_RANLIB + fi + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" + objlist= + len=$len0 + fi + done + RANLIB=$save_RANLIB + oldobjs=$objlist + if test "X$oldobjs" = "X" ; then + eval cmds=\"\$concat_cmds\" + else + eval cmds=\"\$concat_cmds~\$old_archive_cmds\" + fi + fi + fi + func_execute_cmds "$cmds" 'exit $?' done - $echo - $echo "If you ever happen to want to link against installed libraries" - $echo "in a given directory, LIBDIR, you must either use libtool, and" - $echo "specify the full pathname of the library, or use the \`-LLIBDIR'" - $echo "flag during linking and do at least one of the following:" - if test -n "$shlibpath_var"; then - $echo " - add LIBDIR to the \`$shlibpath_var' environment variable" - $echo " during execution" - fi - if test -n "$runpath_var"; then - $echo " - add LIBDIR to the \`$runpath_var' environment variable" - $echo " during linking" - fi - if test -n "$hardcode_libdir_flag_spec"; then - libdir=LIBDIR - eval flag=\"$hardcode_libdir_flag_spec\" - - $echo " - use the \`$flag' linker flag" - fi - if test -n "$admincmds"; then - $echo " - have your system administrator run these commands:$admincmds" - fi - if test -f /etc/ld.so.conf; then - $echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" - fi - $echo - $echo "See any operating system documentation about shared libraries for" - $echo "more information, such as the ld(1) and ld.so(8) manual pages." - $echo "X----------------------------------------------------------------------" | $Xsed - exit $EXIT_SUCCESS - ;; - # libtool execute mode - execute) - modename="$modename: execute" - - # The first argument is the command name. - cmd="$nonopt" - if test -z "$cmd"; then - $echo "$modename: you must specify a COMMAND" 1>&2 - $echo "$help" - exit $EXIT_FAILURE - fi + test -n "$generated" && \ + func_show_eval "${RM}r$generated" - # Handle -dlopen flags immediately. - for file in $execute_dlfiles; do - if test ! -f "$file"; then - $echo "$modename: \`$file' is not a file" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi + # Now create the libtool archive. + case $output in + *.la) + old_library= + test "$build_old_libs" = yes && old_library="$libname.$libext" + func_verbose "creating $output" - dir= - case $file in - *.la) - # Check to see that this really is a libtool archive. - if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" else - $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" fi + done + # Quote the link command for shipping. + relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + if test "$hardcode_automatic" = yes ; then + relink_command= + fi - # Read the libtool library. - dlname= - library_names= + # Only create the output if not a dry run. + $opt_dry_run || { + for installed in no yes; do + if test "$installed" = yes; then + if test -z "$install_libdir"; then + break + fi + output="$output_objdir/$outputname"i + # Replace all uninstalled libtool libraries with the installed ones + newdependency_libs= + for deplib in $dependency_libs; do + case $deplib in + *.la) + func_basename "$deplib" + name="$func_basename_result" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + test -z "$libdir" && \ + func_fatal_error "\`$deplib' is not a valid libtool archive" + func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" + ;; + -L*) + func_stripname -L '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -L$func_replace_sysroot_result" + ;; + -R*) + func_stripname -R '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -R$func_replace_sysroot_result" + ;; + *) func_append newdependency_libs " $deplib" ;; + esac + done + dependency_libs="$newdependency_libs" + newdlfiles= + + for lib in $dlfiles; do + case $lib in + *.la) + func_basename "$lib" + name="$func_basename_result" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "\`$lib' is not a valid libtool archive" + func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" + ;; + *) func_append newdlfiles " $lib" ;; + esac + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + *.la) + # Only pass preopened files to the pseudo-archive (for + # eventual linking with the app. that links it) if we + # didn't already link the preopened objects directly into + # the library: + func_basename "$lib" + name="$func_basename_result" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "\`$lib' is not a valid libtool archive" + func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" + ;; + esac + done + dlprefiles="$newdlprefiles" + else + newdlfiles= + for lib in $dlfiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlfiles " $abs" + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlprefiles " $abs" + done + dlprefiles="$newdlprefiles" + fi + $RM $output + # place dlname in correct position for cygwin + # In fact, it would be nice if we could use this code for all target + # systems that can't hard-code library paths into their executables + # and that have no shared library path variable independent of PATH, + # but it turns out we can't easily determine that from inspecting + # libtool variables, so we have to hard-code the OSs to which it + # applies here; at the moment, that means platforms that use the PE + # object format with DLL files. See the long comment at the top of + # tests/bindir.at for full details. + tdlname=$dlname + case $host,$output,$installed,$module,$dlname in + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) + # If a -bindir argument was supplied, place the dll there. + if test "x$bindir" != x ; + then + func_relative_path "$install_libdir" "$bindir" + tdlname=$func_relative_path_result$dlname + else + # Otherwise fall back on heuristic. + tdlname=../bin/$dlname + fi + ;; + esac + $ECHO > $output "\ +# $outputname - a libtool library file +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION +# +# Please DO NOT delete this file! +# It is necessary for linking the library. - # If there is no directory component, then add one. - case $file in - */* | *\\*) . $file ;; - *) . ./$file ;; - esac +# The name that we can dlopen(3). +dlname='$tdlname' - # Skip this library if it cannot be dlopened. - if test -z "$dlname"; then - # Warn if it was a shared library. - test -n "$library_names" && $echo "$modename: warning: \`$file' was not linked with \`-export-dynamic'" - continue - fi +# Names of this library. +library_names='$library_names' - dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` - test "X$dir" = "X$file" && dir=. +# The name of the static archive. +old_library='$old_library' - if test -f "$dir/$objdir/$dlname"; then - dir="$dir/$objdir" - else - $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2 - exit $EXIT_FAILURE - fi - ;; +# Linker flags that can not go in dependency_libs. +inherited_linker_flags='$new_inherited_linker_flags' - *.lo) - # Just add the directory containing the .lo file. - dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` - test "X$dir" = "X$file" && dir=. - ;; +# Libraries that this one depends upon. +dependency_libs='$dependency_libs' - *) - $echo "$modename: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2 - continue - ;; - esac +# Names of additional weak libraries provided by this library +weak_library_names='$weak_libs' - # Get the absolute pathname. - absdir=`cd "$dir" && pwd` - test -n "$absdir" && dir="$absdir" +# Version information for $libname. +current=$current +age=$age +revision=$revision - # Now add the directory to shlibpath_var. - if eval "test -z \"\$$shlibpath_var\""; then - eval "$shlibpath_var=\"\$dir\"" - else - eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" - fi - done +# Is this an already installed library? +installed=$installed - # This variable tells wrapper scripts just to set shlibpath_var - # rather than running their programs. - libtool_execute_magic="$magic" +# Should we warn about portability when linking against -modules? +shouldnotlink=$module - # Check if any of the arguments is a wrapper script. - args= - for file - do - case $file in - -*) ;; - *) - # Do a test to see if this is really a libtool program. - if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then - # If there is no directory component, then add one. - case $file in - */* | *\\*) . $file ;; - *) . ./$file ;; - esac +# Files to dlopen/dlpreopen +dlopen='$dlfiles' +dlpreopen='$dlprefiles' - # Transform arg to wrapped name. - file="$progdir/$program" - fi - ;; - esac - # Quote arguments (to preserve shell metacharacters). - file=`$echo "X$file" | $Xsed -e "$sed_quote_subst"` - args="$args \"$file\"" - done +# Directory that this library needs to be installed in: +libdir='$install_libdir'" + if test "$installed" = no && test "$need_relink" = yes; then + $ECHO >> $output "\ +relink_command=\"$relink_command\"" + fi + done + } - if test -z "$run"; then - if test -n "$shlibpath_var"; then - # Export the shlibpath_var. - eval "export $shlibpath_var" - fi + # Do a symbolic link so that the libtool archive can be found in + # LD_LIBRARY_PATH before the program is installed. + func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' + ;; + esac + exit $EXIT_SUCCESS +} - # Restore saved environment variables - if test "${save_LC_ALL+set}" = set; then - LC_ALL="$save_LC_ALL"; export LC_ALL - fi - if test "${save_LANG+set}" = set; then - LANG="$save_LANG"; export LANG - fi +{ test "$opt_mode" = link || test "$opt_mode" = relink; } && + func_mode_link ${1+"$@"} - # Now prepare to actually exec the command. - exec_cmd="\$cmd$args" - else - # Display what would be done. - if test -n "$shlibpath_var"; then - eval "\$echo \"\$shlibpath_var=\$$shlibpath_var\"" - $echo "export $shlibpath_var" - fi - $echo "$cmd$args" - exit $EXIT_SUCCESS - fi - ;; - # libtool clean and uninstall mode - clean | uninstall) - modename="$modename: $mode" - rm="$nonopt" +# func_mode_uninstall arg... +func_mode_uninstall () +{ + $opt_debug + RM="$nonopt" files= rmforce= exit_status=0 @@ -6448,44 +9435,41 @@ relink_command=\"$relink_command\"" for arg do case $arg in - -f) rm="$rm $arg"; rmforce=yes ;; - -*) rm="$rm $arg" ;; - *) files="$files $arg" ;; + -f) func_append RM " $arg"; rmforce=yes ;; + -*) func_append RM " $arg" ;; + *) func_append files " $arg" ;; esac done - if test -z "$rm"; then - $echo "$modename: you must specify an RM program" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - fi + test -z "$RM" && \ + func_fatal_help "you must specify an RM program" rmdirs= - origobjdir="$objdir" for file in $files; do - dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` - if test "X$dir" = "X$file"; then - dir=. - objdir="$origobjdir" + func_dirname "$file" "" "." + dir="$func_dirname_result" + if test "X$dir" = X.; then + odir="$objdir" else - objdir="$dir/$origobjdir" + odir="$dir/$objdir" fi - name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` - test "$mode" = uninstall && objdir="$dir" + func_basename "$file" + name="$func_basename_result" + test "$opt_mode" = uninstall && odir="$dir" - # Remember objdir for removal later, being careful to avoid duplicates - if test "$mode" = clean; then + # Remember odir for removal later, being careful to avoid duplicates + if test "$opt_mode" = clean; then case " $rmdirs " in - *" $objdir "*) ;; - *) rmdirs="$rmdirs $objdir" ;; + *" $odir "*) ;; + *) func_append rmdirs " $odir" ;; esac fi # Don't error if the file doesn't exist and rm -f was used. - if (test -L "$file") >/dev/null 2>&1 \ - || (test -h "$file") >/dev/null 2>&1 \ - || test -f "$file"; then + if { test -L "$file"; } >/dev/null 2>&1 || + { test -h "$file"; } >/dev/null 2>&1 || + test -f "$file"; then : elif test -d "$file"; then exit_status=1 @@ -6499,55 +9483,32 @@ relink_command=\"$relink_command\"" case $name in *.la) # Possibly a libtool archive, so verify it. - if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then - . $dir/$name + if func_lalib_p "$file"; then + func_source $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do - rmfiles="$rmfiles $objdir/$n" + func_append rmfiles " $odir/$n" done - test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" + test -n "$old_library" && func_append rmfiles " $odir/$old_library" - case "$mode" in + case "$opt_mode" in clean) - case " $library_names " in - # " " in the beginning catches empty $dlname + case " $library_names " in *" $dlname "*) ;; - *) rmfiles="$rmfiles $objdir/$dlname" ;; + *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; esac - test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" + test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. - cmds=$postuninstall_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" - if test "$?" -ne 0 && test "$rmforce" != yes; then - exit_status=1 - fi - done - IFS="$save_ifs" + func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. - cmds=$old_postuninstall_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $show "$cmd" - $run eval "$cmd" - if test "$?" -ne 0 && test "$rmforce" != yes; then - exit_status=1 - fi - done - IFS="$save_ifs" + func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' fi # FIXME: should reinstall the best remaining shared library. ;; @@ -6557,286 +9518,95 @@ relink_command=\"$relink_command\"" *.lo) # Possibly a libtool object, so verify it. - if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then + if func_lalib_p "$file"; then # Read the .lo file - . $dir/$name + func_source $dir/$name # Add PIC object to the list of files to remove. - if test -n "$pic_object" \ - && test "$pic_object" != none; then - rmfiles="$rmfiles $dir/$pic_object" + if test -n "$pic_object" && + test "$pic_object" != none; then + func_append rmfiles " $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. - if test -n "$non_pic_object" \ - && test "$non_pic_object" != none; then - rmfiles="$rmfiles $dir/$non_pic_object" + if test -n "$non_pic_object" && + test "$non_pic_object" != none; then + func_append rmfiles " $dir/$non_pic_object" fi fi ;; *) - if test "$mode" = clean ; then + if test "$opt_mode" = clean ; then noexename=$name case $file in *.exe) - file=`$echo $file|${SED} 's,.exe$,,'` - noexename=`$echo $name|${SED} 's,.exe$,,'` + func_stripname '' '.exe' "$file" + file=$func_stripname_result + func_stripname '' '.exe' "$name" + noexename=$func_stripname_result # $file with .exe has already been added to rmfiles, # add $file without .exe - rmfiles="$rmfiles $file" + func_append rmfiles " $file" ;; esac # Do a test to see if this is a libtool program. - if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then - relink_command= - . $dir/$noexename + if func_ltwrapper_p "$file"; then + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + relink_command= + func_source $func_ltwrapper_scriptname_result + func_append rmfiles " $func_ltwrapper_scriptname_result" + else + relink_command= + func_source $dir/$noexename + fi # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles - rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}" + func_append rmfiles " $odir/$name $odir/${name}S.${objext}" if test "$fast_install" = yes && test -n "$relink_command"; then - rmfiles="$rmfiles $objdir/lt-$name" + func_append rmfiles " $odir/lt-$name" fi if test "X$noexename" != "X$name" ; then - rmfiles="$rmfiles $objdir/lt-${noexename}.c" + func_append rmfiles " $odir/lt-${noexename}.c" fi fi fi ;; esac - $show "$rm $rmfiles" - $run $rm $rmfiles || exit_status=1 + func_show_eval "$RM $rmfiles" 'exit_status=1' done - objdir="$origobjdir" # Try to remove the ${objdir}s in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then - $show "rmdir $dir" - $run rmdir $dir >/dev/null 2>&1 + func_show_eval "rmdir $dir >/dev/null 2>&1" fi done exit $exit_status - ;; +} - "") - $echo "$modename: you must specify a MODE" 1>&2 - $echo "$generic_help" 1>&2 - exit $EXIT_FAILURE - ;; - esac +{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && + func_mode_uninstall ${1+"$@"} - if test -z "$exec_cmd"; then - $echo "$modename: invalid operation mode \`$mode'" 1>&2 - $echo "$generic_help" 1>&2 - exit $EXIT_FAILURE - fi -fi # test -z "$show_help" +test -z "$opt_mode" && { + help="$generic_help" + func_fatal_help "you must specify a MODE" +} + +test -z "$exec_cmd" && \ + func_fatal_help "invalid operation mode \`$opt_mode'" if test -n "$exec_cmd"; then - eval exec $exec_cmd + eval exec "$exec_cmd" exit $EXIT_FAILURE fi -# We need to display help for each of the modes. -case $mode in -"") $echo \ -"Usage: $modename [OPTION]... [MODE-ARG]... - -Provide generalized library-building support services. - - --config show all configuration variables - --debug enable verbose shell tracing --n, --dry-run display commands without modifying any files - --features display basic configuration information and exit - --finish same as \`--mode=finish' - --help display this help message and exit - --mode=MODE use operation mode MODE [default=inferred from MODE-ARGS] - --quiet same as \`--silent' - --silent don't print informational messages - --tag=TAG use configuration variables from tag TAG - --version print version information - -MODE must be one of the following: - - clean remove files from the build directory - compile compile a source file into a libtool object - execute automatically set library path, then run a program - finish complete the installation of libtool libraries - install install libraries or executables - link create a library or an executable - uninstall remove libraries from an installed directory - -MODE-ARGS vary depending on the MODE. Try \`$modename --help --mode=MODE' for -a more detailed description of MODE. - -Report bugs to ." - exit $EXIT_SUCCESS - ;; - -clean) - $echo \ -"Usage: $modename [OPTION]... --mode=clean RM [RM-OPTION]... FILE... - -Remove files from the build directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, object or program, all the files associated -with it are deleted. Otherwise, only FILE itself is deleted using RM." - ;; - -compile) - $echo \ -"Usage: $modename [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE - -Compile a source file into a libtool library object. - -This mode accepts the following additional options: - - -o OUTPUT-FILE set the output file name to OUTPUT-FILE - -prefer-pic try to building PIC objects only - -prefer-non-pic try to building non-PIC objects only - -static always build a \`.o' file suitable for static linking - -COMPILE-COMMAND is a command to be used in creating a \`standard' object file -from the given SOURCEFILE. - -The output file name is determined by removing the directory component from -SOURCEFILE, then substituting the C source code suffix \`.c' with the -library object suffix, \`.lo'." - ;; - -execute) - $echo \ -"Usage: $modename [OPTION]... --mode=execute COMMAND [ARGS]... - -Automatically set library path, then run a program. - -This mode accepts the following additional options: - - -dlopen FILE add the directory containing FILE to the library path - -This mode sets the library path environment variable according to \`-dlopen' -flags. - -If any of the ARGS are libtool executable wrappers, then they are translated -into their corresponding uninstalled binary, and any of their required library -directories are added to the library path. - -Then, COMMAND is executed, with ARGS as arguments." - ;; - -finish) - $echo \ -"Usage: $modename [OPTION]... --mode=finish [LIBDIR]... - -Complete the installation of libtool libraries. - -Each LIBDIR is a directory that contains libtool libraries. - -The commands that this mode executes may require superuser privileges. Use -the \`--dry-run' option if you just want to see what would be executed." - ;; - -install) - $echo \ -"Usage: $modename [OPTION]... --mode=install INSTALL-COMMAND... - -Install executables or libraries. - -INSTALL-COMMAND is the installation command. The first component should be -either the \`install' or \`cp' program. - -The rest of the components are interpreted as arguments to that command (only -BSD-compatible install options are recognized)." - ;; - -link) - $echo \ -"Usage: $modename [OPTION]... --mode=link LINK-COMMAND... +exit $exit_status -Link object files or libraries together to form another library, or to -create an executable program. - -LINK-COMMAND is a command using the C compiler that you would use to create -a program from several object files. - -The following components of LINK-COMMAND are treated specially: - - -all-static do not do any dynamic linking at all - -avoid-version do not add a version suffix if possible - -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime - -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols - -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) - -export-symbols SYMFILE - try to export only the symbols listed in SYMFILE - -export-symbols-regex REGEX - try to export only the symbols matching REGEX - -LLIBDIR search LIBDIR for required installed libraries - -lNAME OUTPUT-FILE requires the installed library libNAME - -module build a library that can dlopened - -no-fast-install disable the fast-install mode - -no-install link a not-installable executable - -no-undefined declare that a library does not refer to external symbols - -o OUTPUT-FILE create OUTPUT-FILE from the specified objects - -objectlist FILE Use a list of object files found in FILE to specify objects - -precious-files-regex REGEX - don't remove output files matching REGEX - -release RELEASE specify package release information - -rpath LIBDIR the created library will eventually be installed in LIBDIR - -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries - -static do not do any dynamic linking of libtool libraries - -version-info CURRENT[:REVISION[:AGE]] - specify library version info [each variable defaults to 0] - -All other options (arguments beginning with \`-') are ignored. - -Every other argument is treated as a filename. Files ending in \`.la' are -treated as uninstalled libtool libraries, other files are standard or library -object files. - -If the OUTPUT-FILE ends in \`.la', then a libtool library is created, -only library objects (\`.lo' files) may be specified, and \`-rpath' is -required, except when creating a convenience library. - -If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created -using \`ar' and \`ranlib', or on Windows using \`lib'. - -If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file -is created, otherwise an executable program is created." - ;; - -uninstall) - $echo \ -"Usage: $modename [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... - -Remove libraries from an installation directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. - -If FILE is a libtool library, all the files associated with it are deleted. -Otherwise, only FILE itself is deleted using RM." - ;; - -*) - $echo "$modename: invalid operation mode \`$mode'" 1>&2 - $echo "$help" 1>&2 - exit $EXIT_FAILURE - ;; -esac - -$echo -$echo "Try \`$modename --help' for more information about other modes." - -exit $? # The TAGs below are defined such that we never get into a situation # in which we disable both kinds of libraries. Given conflicting @@ -6850,14 +9620,17 @@ exit $? # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared -disable_libs=shared +build_libtool_libs=no +build_old_libs=yes # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static -disable_libs=static +build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: +# vi:sw=2 + diff --git a/contrib/ntp/m4/define_dir.m4 b/contrib/ntp/m4/define_dir.m4 deleted file mode 100644 index 48771760a..000000000 --- a/contrib/ntp/m4/define_dir.m4 +++ /dev/null @@ -1,26 +0,0 @@ -dnl @synopsis AC_DEFINE_DIR(VARNAME, DIR [, DESCRIPTION]) -dnl -dnl This macro defines (with AC_DEFINE) VARNAME to the expansion of the DIR -dnl variable, taking care of fixing up ${prefix} and such. -dnl -dnl Note that the 3 argument form is only supported with autoconf 2.13 and -dnl later (i.e. only where AC_DEFINE supports 3 arguments). -dnl -dnl Examples: -dnl -dnl AC_DEFINE_DIR(DATADIR, datadir) -dnl AC_DEFINE_DIR(PROG_PATH, bindir, [Location of installed binaries]) -dnl -dnl @version $Id: acinclude.m4,v 1.3 2000/08/04 03:26:22 stenn Exp $ -dnl @author Alexandre Oliva - -AC_DEFUN([AC_DEFINE_DIR], [ - ac_expanded=`( - test "x$prefix" = xNONE && prefix="$ac_default_prefix" - test "x$exec_prefix" = xNONE && exec_prefix="${prefix}" - eval echo \""[$]$2"\" - )` - ifelse($3, , - AC_DEFINE_UNQUOTED($1, "$ac_expanded"), - AC_DEFINE_UNQUOTED($1, "$ac_expanded", $3)) -]) diff --git a/contrib/ntp/m4/hs_ulong_const.m4 b/contrib/ntp/m4/hs_ulong_const.m4 deleted file mode 100644 index b137cfdad..000000000 --- a/contrib/ntp/m4/hs_ulong_const.m4 +++ /dev/null @@ -1,11 +0,0 @@ -AC_DEFUN([hs_ULONG_CONST], -[ AH_TEMPLATE(ULONG_CONST, [How do we create unsigned long constants?]) -AC_EGREP_CPP(Circus, - [#define ACAT(a,b)a ## b -ACAT(Cir,cus) -], AC_DEFINE([ULONG_CONST(a)], [a ## UL]), - AC_EGREP_CPP(Reiser, -[#define RCAT(a,b)a/**/b -RCAT(Rei,ser) -], AC_DEFINE([ULONG_CONST(a)], [a/**/L]), - AC_MSG_ERROR([How do we create an unsigned long constant?])))]) diff --git a/contrib/ntp/m4/os_cflags.m4 b/contrib/ntp/m4/os_cflags.m4 deleted file mode 100644 index 35efa44b3..000000000 --- a/contrib/ntp/m4/os_cflags.m4 +++ /dev/null @@ -1,87 +0,0 @@ -dnl ###################################################################### -dnl Specify additional compile options based on the OS and the compiler -dnl From Erez Zadok , http://www.am-utils.org -AC_DEFUN([AMU_OS_CFLAGS], -[ -AC_CACHE_CHECK(additional compiler flags, -ac_cv_os_cflags, -[ -case "${host_os}" in - irix6* ) - case "${CC}" in - cc ) - # do not use 64-bit compiler - ac_cv_os_cflags="-n32 -mips3 -Wl,-woff,84" - ;; - esac - ;; -# HMS: am-utils needed this but we don't (apparently) -# osf[[1-3]]* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN -D_NO_PROTO" -# ;; -# esac -# ;; -# osf* ) -# # get the right version of struct sockaddr -# case "${CC}" in -# cc ) -# ac_cv_os_cflags="-std -D_SOCKADDR_LEN" -# ;; -# * ) -# ac_cv_os_cflags="-D_SOCKADDR_LEN" -# ;; -# esac -# ;; - aix[[1-3]]* ) - ac_cv_os_cflags="" ;; - aix4.[[0-2]]* ) - # turn on additional headers - ac_cv_os_cflags="-D_XOPEN_EXTENDED_SOURCE" - ;; - aix* ) - # avoid circular dependencies in yp headers - ac_cv_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" - ;; - OFF-sunos4* ) - # make sure passing whole structures is handled in gcc - case "${CC}" in - gcc ) - ac_cv_os_cflags="-fpcc-struct-return" - ;; - esac - ;; - sunos[[34]]* | solaris1* | solaris2.[[0-5]]* | sunos5.[[0-5]]* ) - ac_cv_os_cflags="" ;; - solaris* | sunos* ) - # turn on 64-bit file offset interface - case "${CC}" in - * ) - ac_cv_os_cflags="-D_LARGEFILE64_SOURCE" - ;; - esac - ;; - hpux* ) - # use Ansi compiler on HPUX - case "${CC}" in - cc ) - ac_cv_os_cflags="-Ae" - ;; - esac - ;; - darwin* | rhapsody* ) - ac_cv_os_cflags="-D_P1003_1B_VISIBLE" - ;; - * ) - ac_cv_os_cflags="" - ;; -esac -]) -CFLAGS="$CFLAGS $ac_cv_os_cflags" -]) -dnl ====================================================================== diff --git a/contrib/ntp/ntpd/Makefile.am b/contrib/ntp/ntpd/Makefile.am index 6896b4564..a5690b70d 100644 --- a/contrib/ntp/ntpd/Makefile.am +++ b/contrib/ntp/ntpd/Makefile.am @@ -1,108 +1,442 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr +NULL= -bindir= ${exec_prefix}/${BINSUBDIR} - -bin_PROGRAMS= ntpd @MAKE_NTPDSIM@ +bin_PROGRAMS= $(NTPD_DB) $(NTPDSIM_DB) +libexec_PROGRAMS= $(NTPD_DL) $(NTPDSIM_DL) +sbin_PROGRAMS= $(NTPD_DS) $(NTPDSIM_DS) noinst_LIBRARIES= libntpd.a -AM_CPPFLAGS= -I$(top_srcdir)/include -I../include $(LIBOPTS_CFLAGS) +AM_CFLAGS = $(CFLAGS_NTP) + +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(LIBOPTS_CFLAGS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +AM_LDFLAGS = $(LDFLAGS_NTP) + # LDADD might need RESLIB and ADJLIB. -LDADD= version.o libntpd.a @LIBPARSE@ - -BUILT_SOURCES= ntpd-opts.c ntpd-opts.h ntpd.1 ntpd-opts.texi ntpd-opts.menu -man_MANS= ntpd.1 - -BUILT_SOURCES+= ntpdsim-opts.c ntpdsim-opts.h ntpdsim.1 ntpdsim-opts.texi ntpdsim-opts.menu -man_MANS+= ntpdsim.1 - -# ntpd may need: -# log10 refclock_wwv.o -# sqrt ntp_control.o -# floor refclock_wwv.o -# which are (usually) provided by -lm. -ntpd_LDADD = $(LDADD) -lm @LCRYPTO@ $(LIBOPTS_LDADD) ../libntp/libntp.a -ntpdsim_LDADD = $(LDADD) ../libntp/libntpsim.a -lm @LCRYPTO@ $(LIBOPTS_LDADD) -ntpdsim_CFLAGS = $(CFLAGS) -DSIM -check_y2k_LDADD = $(LDADD) ../libntp/libntp.a -DISTCLEANFILES = .version version.c -EXTRA_DIST = ntpd-opts.def ntpdbase-opts.def ntpdsim-opts.def \ +LDADD = version.o libntpd.a $(LIBPARSE) +AM_YFLAGS = -d -t -r all + +if SAVECONFIG_ENABLED +if NTP_CROSSCOMPILE +CHECK_SAVECONFIG= +else +CHECK_SAVECONFIG= check-saveconfig +endif +else !SAVECONFIG_ENABLED +CHECK_SAVECONFIG= +endif + +# +# VPHACK and VPHACK_AFTER are enabled on non-GNU makes (such as +# BSD make) to work around issues specific to compiling +# ntp_parser.y into ntp_parser.h and ntp_parser.c in a VPATH +# configuration where we would like (for a change) the output +# files ntp_parser.[ch] to be placed in the source directory, +# as opposed to the build directory. This allows a single +# host of a flock configured with Bison to update ntp_parser.[ch] +# used by the rest. +# + +if VPATH_HACK +VPHACK= vphack +VPHACK_AFTER= vphack_after +else +VPHACK= +VPHACK_AFTER= +endif + +vphack: + test -e ntp_parser.c || ln -s $(srcdir)/ntp_parser.c . + test -e ntp_parser.h || ln -s $(srcdir)/ntp_parser.h . + +# +# ylwrap script which invokes Bison replaces ntp_parser.h +# symlink with the updated file, when ntp_parser.h changes. +# vphack_after detects this and copies the updated file to srcdir +# and re-creates the ntp_parser.h symlink in its place. +# + +vphack_after: + test -L ntp_parser.h || ( \ + mv ntp_parser.h $(srcdir)/ntp_parser.h && \ + ln -s $(srcdir)/ntp_parser.h . \ + ) + +# BUILT_SOURCES which should also be in EXTRA_DIST +B_S_DIST= \ + $(srcdir)/ntpd-opts.c \ + $(srcdir)/ntpd-opts.h \ + $(NULL) + +BUILT_SOURCES= \ + $(VPHACK) \ + $(LIBPARSE) \ + ntp_parser.c \ + ntp_parser.h \ + $(VPHACK_AFTER) \ + $(B_S_DIST) \ + $(NULL) + +man1_MANS= +man5_MANS= ntp.conf.5 ntp.keys.5 +man8_MANS= +man_MANS= ntpd.$(NTPD_MS) + +# ntpdsim.1 is a remnant along with all the ntpdsim-opts.* files, the +# simulator currently uses ntpd-opts.[ch]. This also means there is no +# longer a reason to have ntpdbase-opts.def split off of ntpd-opts.def. + +LDADD_NTPD_COMMON = $(LDADD_LIBNTP) $(LIBOPTS_LDADD) $(PTHREAD_LIBS) +LDADD_NTPD_COMMON += $(LIBM) $(LDADD_NTP) $(LSCF) +ntpd_LDADD = $(LDADD) ../libntp/libntp.a $(LDADD_NTPD_COMMON) $(LDADD_LIBUTIL) +ntpdsim_LDADD = $(LDADD) ../libntp/libntpsim.a $(LDADD_NTPD_COMMON) +ntpdsim_CPPFLAGS = $(AM_CPPFLAGS) -DSIM +check_y2k_LDADD = $(LDADD) ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(LDADD_LIBNTP) $(PTHREAD_LIBS) +## we don't want $(LDADD) in keyword_gen_LDADD +keyword_gen_LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) + +DISTCLEANFILES = \ + keyword-gen \ + .version \ + version.c \ + config.log \ + $(man5_MANS) \ + $(man_MANS) \ + $(NULL) + +CLEANFILES = \ + check-saveconfig \ + compsave.conf \ + k-g-u-submake \ + $(EXTRA_PROGRAMS) \ + $(NULL) + +EXTRA_DIST = \ + complete.conf.in \ + invoke-ntp.conf.menu \ + invoke-ntp.conf.texi \ + invoke-ntp.keys.menu \ + invoke-ntp.keys.texi \ + invoke-ntpd.menu \ + invoke-ntpd.texi \ + keyword-gen-utd \ + ntp.conf.5man \ + ntp.conf.5mdoc \ + ntp.conf.def \ + ntp.conf.man.in \ + ntp.conf.mdoc.in \ + ntp.conf.html \ + ntp.conf.texi \ + ntp.keys.5man \ + ntp.keys.5mdoc \ + ntp.keys.def \ + ntp.keys.man.in \ + ntp.keys.mdoc.in \ + ntp.keys.html \ + ntp.keys.texi \ + ntpd-opts.def \ + ntpd.1ntpdman \ + ntpd.1ntpdmdoc \ + ntpd.man.in \ + ntpd.mdoc.in \ + ntpd.html \ + ntpd.texi \ + ntpdbase-opts.def \ refclock_msfees.c \ - refclock_trak.c \ - $(BUILT_SOURCES) -ETAGS_ARGS = Makefile.am + $(B_S_DIST) \ + $(NULL) + ### Y2Kfixes check_PROGRAMS = @MAKE_CHECK_Y2K@ -EXTRA_PROGRAMS = check_y2k ntpdsim -run_ag = cd $(srcdir) && autogen -L ../include --writable -std_def_list= $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ - $(top_srcdir)/include/copyright.def \ - $(top_srcdir)/include/version.def - -check-local: @MAKE_CHECK_Y2K@ - test -z "@MAKE_CHECK_Y2K@" || ./@MAKE_CHECK_Y2K@ - -# SIM: cmd_args.c ntp_config.c ntp_io.c ntpd.c + ntpsim.c (include/ntpsim.h) -# ntp_resolver.c is presently unused... -ntpd_SOURCES = cmd_args.c ntp_config.c ntp_io.c ntpd.c ntpd-opts.c ntpd-opts.h -ntpdsim_SOURCES = $(ntpd_SOURCES) ntpsim.c ntpdsim-opts.c ntpdsim-opts.h -libntpd_a_SOURCES = jupiter.h ntp_control.c \ - ntp_crypto.c ntp_filegen.c \ - ntp_intres.c ntp_loopfilter.c ntp_monitor.c ntp_peer.c \ - ntp_proto.c ntp_refclock.c ntp_request.c \ - ntp_restrict.c ntp_timer.c ntp_util.c \ - ppsapi_timepps.h \ - refclock_acts.c refclock_arbiter.c refclock_arc.c refclock_as2201.c \ - refclock_atom.c refclock_bancomm.c refclock_chronolog.c \ - refclock_chu.c refclock_conf.c refclock_datum.c refclock_dumbclock.c \ - refclock_fg.c refclock_gpsvme.c refclock_heath.c refclock_hopfser.c \ - refclock_hopfpci.c refclock_hpgps.c refclock_irig.c refclock_jjy.c \ - refclock_jupiter.c refclock_leitch.c refclock_local.c \ - refclock_mx4200.c refclock_neoclock4x.c \ - refclock_nmea.c refclock_oncore.c refclock_palisade.c \ - refclock_palisade.h refclock_parse.c \ - refclock_pcf.c refclock_pst.c refclock_ripencc.c refclock_shm.c \ - refclock_tpro.c refclock_true.c refclock_tt560.c \ - refclock_ulink.c refclock_wwv.c refclock_wwvb.c \ - refclock_zyfer.c +EXTRA_PROGRAMS = check_y2k keyword-gen ntpd ntpdsim + +html_DATA= \ + $(srcdir)/ntp.conf.html \ + $(srcdir)/ntp.keys.html \ + $(srcdir)/ntpd.html \ + $(NULL) + +noinst_DATA = \ + $(srcdir)/invoke-ntp.conf.menu \ + $(srcdir)/invoke-ntp.conf.texi \ + $(srcdir)/invoke-ntp.keys.menu \ + $(srcdir)/invoke-ntp.keys.texi \ + $(srcdir)/invoke-ntpd.menu \ + $(srcdir)/invoke-ntpd.texi \ + $(srcdir)/ntp.conf.man.in \ + $(srcdir)/ntp.conf.mdoc.in \ + $(srcdir)/ntp.keys.man.in \ + $(srcdir)/ntp.keys.mdoc.in \ + $(srcdir)/ntpd.man.in \ + $(srcdir)/ntpd.mdoc.in \ + $(NULL) + +noinst_HEADERS = \ + declcond.h \ + ntp_leapsec.h \ + $(NULL) + +install-data-local: install-html + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +check-local: $(MAKE_CHECK_Y2K) $(CHECK_SAVECONFIG) + test -z "$(MAKE_CHECK_Y2K)" || ./$(MAKE_CHECK_Y2K) + +ntpd_SOURCES = \ + ntp_config.c \ + ntp_keyword.h \ + ntp_io.c \ + ntp_parser.y \ + ntp_scanner.c \ + ntp_scanner.h \ + ntpd.c \ + ntpd-opts.c \ + ntpd-opts.h \ + $(NULL) + +ntpdsim_SOURCES = \ + $(ntpd_SOURCES) \ + ntp_prio_q.c \ + ntpsim.c \ + $(NULL) + +# libntpd_a_SOURCES do not use #ifdef SIM + +libntpd_a_SOURCES = \ + cmd_args.c \ + jupiter.h \ + ntp_control.c \ + ntp_crypto.c \ + ntp_filegen.c \ + ntp_leapsec.c \ + ntp_loopfilter.c \ + ntp_monitor.c \ + ntp_peer.c \ + ntp_proto.c \ + ntp_refclock.c \ + ntp_request.c \ + ntp_restrict.c \ + ntp_signd.c \ + ntp_timer.c \ + ntp_util.c \ + ppsapi_timepps.h \ + rc_cmdlength.c \ + refclock_acts.c \ + refclock_arbiter.c \ + refclock_arc.c \ + refclock_as2201.c \ + refclock_atom.c \ + refclock_bancomm.c \ + refclock_chronolog.c \ + refclock_chu.c \ + refclock_conf.c \ + refclock_datum.c \ + refclock_dumbclock.c \ + refclock_fg.c \ + refclock_gpsdjson.c \ + refclock_gpsvme.c \ + refclock_heath.c \ + refclock_hopfser.c \ + refclock_hopfpci.c \ + refclock_hpgps.c \ + refclock_irig.c \ + refclock_jjy.c \ + refclock_jupiter.c \ + refclock_leitch.c \ + refclock_local.c \ + refclock_mx4200.c \ + refclock_neoclock4x.c \ + refclock_nmea.c \ + refclock_oncore.c \ + refclock_palisade.c \ + refclock_palisade.h \ + refclock_parse.c \ + refclock_pcf.c \ + refclock_pst.c \ + refclock_ripencc.c \ + refclock_shm.c \ + refclock_tpro.c \ + refclock_true.c \ + refclock_tt560.c \ + refclock_ulink.c \ + refclock_wwv.c \ + refclock_wwvb.c \ + refclock_zyfer.c \ + refclock_tsyncpci.c \ + $(NULL) + +k-g-u-submake: keyword-gen + ./keyword-gen $(srcdir)/ntp_parser.h > k-g.out + @grep -v diff_ignore_line < k-g.out > cmp1 + @grep -v diff_ignore_line < $(srcdir)/ntp_keyword.h > cmp2 + @cmp cmp1 cmp2 > /dev/null || \ + { mv -f k-g.out $(srcdir)/ntp_keyword.h && \ + echo 'Generated changed ntp_keyword.h.' ;} + @[ ! -f k-g.out ] || \ + { rm k-g.out && echo 'ntp_keyword.h is up to date.' ;} + @rm cmp1 cmp2 + @echo 'keyword-gen and ntp_keyword.h are up to date.' > $@ + +$(srcdir)/keyword-gen-utd: $(srcdir)/keyword-gen.c $(srcdir)/ntp_parser.h + $(MAKE) $(AM_MAKEFLAGS) k-g-u-submake # avoid explicit dependency + grep diff_ignore_line $(srcdir)/ntp_keyword.h > k-g-u + mv -f k-g-u $@ + +$(srcdir)/ntp_keyword.h: $(srcdir)/keyword-gen-utd + @: do-nothing action to avoid default SCCS get + @: .h updated if needed by k-g-u-submake rule $(srcdir)/ntpd-opts.h: $(srcdir)/ntpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpd-opts.c: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) ntpd-opts.def -$(srcdir)/ntpd.1: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) - $(run_ag) -Tagman1.tpl -bntpd ntpd-opts.def +### -$(srcdir)/ntpd-opts.texi $(srcdir)/ntpd-opts.menu: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpd-opts.def +$(srcdir)/ntpd.1ntpdman: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdman -Tagman-cmd.tpl ntpd-opts.def -$(srcdir)/ntpdsim-opts.h: $(srcdir)/ntpdsim-opts.c -$(srcdir)/ntpdsim-opts.c: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) ntpdsim-opts.def +$(srcdir)/ntpd.man.in: $(srcdir)/ntpd.1ntpdman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpd.1ntpdman > $(srcdir)/ntpd.man.in+ + mv $(srcdir)/ntpd.man.in+ $(srcdir)/ntpd.man.in -$(srcdir)/ntpdsim.1: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Tagman1.tpl -bntpdsim ntpdsim-opts.def +### -$(srcdir)/ntpdsim-opts.texi $(srcdir)/ntpdsim-opts.menu: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdsim-opts.def +$(srcdir)/ntpd.1ntpdmdoc: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdmdoc -Tagmdoc-cmd.tpl ntpd-opts.def + +$(srcdir)/ntpd.mdoc.in: $(srcdir)/ntpd.1ntpdmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpd.1ntpdmdoc > $(srcdir)/ntpd.mdoc.in+ + mv $(srcdir)/ntpd.mdoc.in+ $(srcdir)/ntpd.mdoc.in + +### + +ntpd.$(NTPD_MS): $(srcdir)/ntpd.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpd.$(NTPD_MS)+:$(srcdir)/ntpd.$(MANTAGFMT).in + mv ntpd.$(NTPD_MS)+ ntpd.$(NTPD_MS) + +### + +$(srcdir)/invoke-ntp.conf.menu: $(srcdir)/invoke-ntp.conf.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntp.conf.texi: $(srcdir)/ntp.conf.def $(std_def_list) + $(run_ag) -Tagtexi-file.tpl -DLEVEL=section ntp.conf.def + +$(srcdir)/invoke-ntp.keys.menu: $(srcdir)/invoke-ntp.keys.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntp.keys.texi: $(srcdir)/ntp.keys.def $(std_def_list) + $(run_ag) -Tagtexi-file.tpl -DLEVEL=section ntp.keys.def + +$(srcdir)/ntp.conf.html: $(srcdir)/ntp.conf.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntp.conf.html ntp.conf.texi || true ) + +$(srcdir)/ntp.keys.html: $(srcdir)/ntp.keys.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntp.keys.html ntp.keys.texi || true ) + +$(srcdir)/ntpd.html: $(srcdir)/ntpd.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntpd.html ntpd.texi || true ) + +### + +$(srcdir)/ntp.conf.5man: $(srcdir)/ntp.conf.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5man -Tagman-cmd.tpl ntp.conf.def + +$(srcdir)/ntp.conf.man.in: $(srcdir)/ntp.conf.5man $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.conf.5man > $(srcdir)/ntp.conf.man.in+ + mv $(srcdir)/ntp.conf.man.in+ $(srcdir)/ntp.conf.man.in + +### + +$(srcdir)/ntp.conf.5mdoc: $(srcdir)/ntp.conf.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5mdoc -Tagmdoc-cmd.tpl ntp.conf.def + +$(srcdir)/ntp.conf.mdoc.in: $(srcdir)/ntp.conf.5mdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.conf.5mdoc > $(srcdir)/ntp.conf.mdoc.in+ + mv $(srcdir)/ntp.conf.mdoc.in+ $(srcdir)/ntp.conf.mdoc.in + +### + +ntp.conf.5: $(srcdir)/ntp.conf.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntp.conf.5+:$(srcdir)/ntp.conf.$(MANTAGFMT).in + mv ntp.conf.5+ ntp.conf.5 + +### + +$(srcdir)/ntp.keys.5man: $(srcdir)/ntp.keys.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5man -Tagman-file.tpl ntp.keys.def + +$(srcdir)/ntp.keys.man.in: $(srcdir)/ntp.keys.5man $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.keys.5man > $(srcdir)/ntp.keys.man.in+ + mv $(srcdir)/ntp.keys.man.in+ $(srcdir)/ntp.keys.man.in + +### + +$(srcdir)/ntp.keys.5mdoc: $(srcdir)/ntp.keys.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5mdoc -Tagmdoc-file.tpl ntp.keys.def + +$(srcdir)/ntp.keys.mdoc.in: $(srcdir)/ntp.keys.5mdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.keys.5mdoc > $(srcdir)/ntp.keys.mdoc.in+ + mv $(srcdir)/ntp.keys.mdoc.in+ $(srcdir)/ntp.keys.mdoc.in + +### + +ntp.keys.5: $(srcdir)/ntp.keys.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntp.keys.5+:$(srcdir)/ntp.keys.$(MANTAGFMT).in + mv ntp.keys.5+ ntp.keys.5 + +### + +$(srcdir)/invoke-ntpd.menu: $(srcdir)/invoke-ntpd.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpd.texi: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpd-opts.def + $(top_srcdir)/scripts/build/check--help $@ $(PROGRAMS): $(LDADD) -../libntp/libntp.a: - cd ../libntp && $(MAKE) libntp.a +compsave.conf: ntpd complete.conf + ./ntpd --configfile complete.conf --saveconfigquit $@ + +check-saveconfig: complete.conf compsave.conf + -diff -u complete.conf compsave.conf + cmp complete.conf compsave.conf && echo stamp > $@ ../libntp/libntpsim.a: - cd ../libntp && $(MAKE) libntpsim.a + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntpsim.a ../libparse/libparse.a: - cd ../libparse && $(MAKE) + cd ../libparse && $(MAKE) $(AM_MAKEFLAGS) check-libparse + +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev + +version.c: $(ntpd_OBJECTS) ../libntp/libntp.a @LIBPARSE@ Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpd -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o -version.o: $(ntpd_OBJECTS) ../libntp/libntp.a @LIBPARSE@ Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpd - $(COMPILE) -c version.c +$(srcdir)/Makefile.am: + @: do-nothing -include ../bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/check-libopts.mf +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/ntpd/Makefile.in b/contrib/ntp/ntpd/Makefile.in index 6ccb13bf8..2304e33d1 100644 --- a/contrib/ntp/ntpd/Makefile.in +++ b/contrib/ntp/ntpd/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -20,7 +19,64 @@ # subdir to warn folks if there is another version there. + + VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -39,95 +95,185 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr -bin_PROGRAMS = ntpd$(EXEEXT) @MAKE_NTPDSIM@ -EXTRA_PROGRAMS = check_y2k$(EXEEXT) ntpdsim$(EXEEXT) -DIST_COMMON = $(srcdir)/../bincheck.mf $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in +EXTRA_PROGRAMS = check_y2k$(EXEEXT) keyword-gen$(EXEEXT) ntpd$(EXEEXT) \ + ntpdsim$(EXEEXT) subdir = ntpd ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = +CONFIG_CLEAN_FILES = complete.conf CONFIG_CLEAN_VPATH_FILES = LIBRARIES = $(noinst_LIBRARIES) ARFLAGS = @ARFLAGS@ +AM_V_AR = $(am__v_AR_@AM_V@) +am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@) +am__v_AR_0 = @echo " AR " $@; +am__v_AR_1 = libntpd_a_AR = $(AR) $(ARFLAGS) libntpd_a_LIBADD = -am_libntpd_a_OBJECTS = ntp_control$U.$(OBJEXT) ntp_crypto$U.$(OBJEXT) \ - ntp_filegen$U.$(OBJEXT) ntp_intres$U.$(OBJEXT) \ - ntp_loopfilter$U.$(OBJEXT) ntp_monitor$U.$(OBJEXT) \ - ntp_peer$U.$(OBJEXT) ntp_proto$U.$(OBJEXT) \ - ntp_refclock$U.$(OBJEXT) ntp_request$U.$(OBJEXT) \ - ntp_restrict$U.$(OBJEXT) ntp_timer$U.$(OBJEXT) \ - ntp_util$U.$(OBJEXT) refclock_acts$U.$(OBJEXT) \ - refclock_arbiter$U.$(OBJEXT) refclock_arc$U.$(OBJEXT) \ - refclock_as2201$U.$(OBJEXT) refclock_atom$U.$(OBJEXT) \ - refclock_bancomm$U.$(OBJEXT) refclock_chronolog$U.$(OBJEXT) \ - refclock_chu$U.$(OBJEXT) refclock_conf$U.$(OBJEXT) \ - refclock_datum$U.$(OBJEXT) refclock_dumbclock$U.$(OBJEXT) \ - refclock_fg$U.$(OBJEXT) refclock_gpsvme$U.$(OBJEXT) \ - refclock_heath$U.$(OBJEXT) refclock_hopfser$U.$(OBJEXT) \ - refclock_hopfpci$U.$(OBJEXT) refclock_hpgps$U.$(OBJEXT) \ - refclock_irig$U.$(OBJEXT) refclock_jjy$U.$(OBJEXT) \ - refclock_jupiter$U.$(OBJEXT) refclock_leitch$U.$(OBJEXT) \ - refclock_local$U.$(OBJEXT) refclock_mx4200$U.$(OBJEXT) \ - refclock_neoclock4x$U.$(OBJEXT) refclock_nmea$U.$(OBJEXT) \ - refclock_oncore$U.$(OBJEXT) refclock_palisade$U.$(OBJEXT) \ - refclock_parse$U.$(OBJEXT) refclock_pcf$U.$(OBJEXT) \ - refclock_pst$U.$(OBJEXT) refclock_ripencc$U.$(OBJEXT) \ - refclock_shm$U.$(OBJEXT) refclock_tpro$U.$(OBJEXT) \ - refclock_true$U.$(OBJEXT) refclock_tt560$U.$(OBJEXT) \ - refclock_ulink$U.$(OBJEXT) refclock_wwv$U.$(OBJEXT) \ - refclock_wwvb$U.$(OBJEXT) refclock_zyfer$U.$(OBJEXT) +am__objects_1 = +am_libntpd_a_OBJECTS = cmd_args.$(OBJEXT) ntp_control.$(OBJEXT) \ + ntp_crypto.$(OBJEXT) ntp_filegen.$(OBJEXT) \ + ntp_leapsec.$(OBJEXT) ntp_loopfilter.$(OBJEXT) \ + ntp_monitor.$(OBJEXT) ntp_peer.$(OBJEXT) ntp_proto.$(OBJEXT) \ + ntp_refclock.$(OBJEXT) ntp_request.$(OBJEXT) \ + ntp_restrict.$(OBJEXT) ntp_signd.$(OBJEXT) ntp_timer.$(OBJEXT) \ + ntp_util.$(OBJEXT) rc_cmdlength.$(OBJEXT) \ + refclock_acts.$(OBJEXT) refclock_arbiter.$(OBJEXT) \ + refclock_arc.$(OBJEXT) refclock_as2201.$(OBJEXT) \ + refclock_atom.$(OBJEXT) refclock_bancomm.$(OBJEXT) \ + refclock_chronolog.$(OBJEXT) refclock_chu.$(OBJEXT) \ + refclock_conf.$(OBJEXT) refclock_datum.$(OBJEXT) \ + refclock_dumbclock.$(OBJEXT) refclock_fg.$(OBJEXT) \ + refclock_gpsdjson.$(OBJEXT) refclock_gpsvme.$(OBJEXT) \ + refclock_heath.$(OBJEXT) refclock_hopfser.$(OBJEXT) \ + refclock_hopfpci.$(OBJEXT) refclock_hpgps.$(OBJEXT) \ + refclock_irig.$(OBJEXT) refclock_jjy.$(OBJEXT) \ + refclock_jupiter.$(OBJEXT) refclock_leitch.$(OBJEXT) \ + refclock_local.$(OBJEXT) refclock_mx4200.$(OBJEXT) \ + refclock_neoclock4x.$(OBJEXT) refclock_nmea.$(OBJEXT) \ + refclock_oncore.$(OBJEXT) refclock_palisade.$(OBJEXT) \ + refclock_parse.$(OBJEXT) refclock_pcf.$(OBJEXT) \ + refclock_pst.$(OBJEXT) refclock_ripencc.$(OBJEXT) \ + refclock_shm.$(OBJEXT) refclock_tpro.$(OBJEXT) \ + refclock_true.$(OBJEXT) refclock_tt560.$(OBJEXT) \ + refclock_ulink.$(OBJEXT) refclock_wwv.$(OBJEXT) \ + refclock_wwvb.$(OBJEXT) refclock_zyfer.$(OBJEXT) \ + refclock_tsyncpci.$(OBJEXT) $(am__objects_1) libntpd_a_OBJECTS = $(am_libntpd_a_OBJECTS) -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)" \ + "$(DESTDIR)$(htmldir)" +PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(sbin_PROGRAMS) check_y2k_SOURCES = check_y2k.c -check_y2k_OBJECTS = check_y2k$U.$(OBJEXT) -am__DEPENDENCIES_1 = version.o libntpd.a -check_y2k_DEPENDENCIES = $(am__DEPENDENCIES_1) ../libntp/libntp.a -am_ntpd_OBJECTS = cmd_args$U.$(OBJEXT) ntp_config$U.$(OBJEXT) \ - ntp_io$U.$(OBJEXT) ntpd$U.$(OBJEXT) ntpd-opts$U.$(OBJEXT) +check_y2k_OBJECTS = check_y2k.$(OBJEXT) +am__DEPENDENCIES_1 = +am__DEPENDENCIES_2 = version.o libntpd.a $(am__DEPENDENCIES_1) +check_y2k_DEPENDENCIES = $(am__DEPENDENCIES_2) ../libntp/libntp.a \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +keyword_gen_SOURCES = keyword-gen.c +keyword_gen_OBJECTS = keyword-gen.$(OBJEXT) +keyword_gen_DEPENDENCIES = ../libntp/libntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +am_ntpd_OBJECTS = ntp_config.$(OBJEXT) ntp_io.$(OBJEXT) \ + ntp_parser.$(OBJEXT) ntp_scanner.$(OBJEXT) ntpd.$(OBJEXT) \ + ntpd-opts.$(OBJEXT) $(am__objects_1) ntpd_OBJECTS = $(am_ntpd_OBJECTS) -am__DEPENDENCIES_2 = -ntpd_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2) \ - ../libntp/libntp.a -am__objects_1 = ntpdsim-cmd_args$U.$(OBJEXT) \ - ntpdsim-ntp_config$U.$(OBJEXT) ntpdsim-ntp_io$U.$(OBJEXT) \ - ntpdsim-ntpd$U.$(OBJEXT) ntpdsim-ntpd-opts$U.$(OBJEXT) -am_ntpdsim_OBJECTS = $(am__objects_1) ntpdsim-ntpsim$U.$(OBJEXT) \ - ntpdsim-ntpdsim-opts$U.$(OBJEXT) +am__DEPENDENCIES_3 = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +ntpd_DEPENDENCIES = $(am__DEPENDENCIES_2) ../libntp/libntp.a \ + $(am__DEPENDENCIES_3) $(am__DEPENDENCIES_1) +am__objects_2 = ntpdsim-ntp_config.$(OBJEXT) ntpdsim-ntp_io.$(OBJEXT) \ + ntpdsim-ntp_parser.$(OBJEXT) ntpdsim-ntp_scanner.$(OBJEXT) \ + ntpdsim-ntpd.$(OBJEXT) ntpdsim-ntpd-opts.$(OBJEXT) \ + $(am__objects_1) +am_ntpdsim_OBJECTS = $(am__objects_2) ntpdsim-ntp_prio_q.$(OBJEXT) \ + ntpdsim-ntpsim.$(OBJEXT) $(am__objects_1) ntpdsim_OBJECTS = $(am_ntpdsim_OBJECTS) -ntpdsim_DEPENDENCIES = $(am__DEPENDENCIES_1) ../libntp/libntpsim.a \ - $(am__DEPENDENCIES_2) -ntpdsim_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(ntpdsim_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ +ntpdsim_DEPENDENCIES = $(am__DEPENDENCIES_2) ../libntp/libntpsim.a \ + $(am__DEPENDENCIES_3) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ -SOURCES = $(libntpd_a_SOURCES) check_y2k.c $(ntpd_SOURCES) \ - $(ntpdsim_SOURCES) -DIST_SOURCES = $(libntpd_a_SOURCES) check_y2k.c $(ntpd_SOURCES) \ - $(ntpdsim_SOURCES) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +am__yacc_c2h = sed -e s/cc$$/hh/ -e s/cpp$$/hpp/ -e s/cxx$$/hxx/ \ + -e s/c++$$/h++/ -e s/c$$/h/ +YACCCOMPILE = $(YACC) $(AM_YFLAGS) $(YFLAGS) +LTYACCCOMPILE = $(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(YACC) $(AM_YFLAGS) $(YFLAGS) +AM_V_YACC = $(am__v_YACC_@AM_V@) +am__v_YACC_ = $(am__v_YACC_@AM_DEFAULT_V@) +am__v_YACC_0 = @echo " YACC " $@; +am__v_YACC_1 = +YLWRAP = $(top_srcdir)/sntp/libevent/build-aux/ylwrap +SOURCES = $(libntpd_a_SOURCES) check_y2k.c keyword-gen.c \ + $(ntpd_SOURCES) $(ntpdsim_SOURCES) +DIST_SOURCES = $(libntpd_a_SOURCES) check_y2k.c keyword-gen.c \ + $(ntpd_SOURCES) $(ntpdsim_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -149,49 +295,115 @@ am__nobase_list = $(am__nobase_strip_setup); \ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } man1dir = $(mandir)/man1 +man5dir = $(mandir)/man5 +man8dir = $(mandir)/man8 NROFF = nroff -MANS = $(man_MANS) +MANS = $(man1_MANS) $(man5_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) +HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/complete.conf.in \ + $(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf \ + $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf \ + $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp \ + $(top_srcdir)/sntp/libevent/build-aux/ylwrap ntp_parser.c \ + ntp_parser.h DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -199,8 +411,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -210,15 +425,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -226,29 +502,65 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -289,71 +601,240 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +bin_PROGRAMS = $(NTPD_DB) $(NTPDSIM_DB) +libexec_PROGRAMS = $(NTPD_DL) $(NTPDSIM_DL) +sbin_PROGRAMS = $(NTPD_DS) $(NTPDSIM_DS) noinst_LIBRARIES = libntpd.a -AM_CPPFLAGS = -I$(top_srcdir)/include -I../include $(LIBOPTS_CFLAGS) +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(LIBOPTS_CFLAGS) $(CPPFLAGS_NTP) +AM_LDFLAGS = $(LDFLAGS_NTP) + # LDADD might need RESLIB and ADJLIB. -LDADD = version.o libntpd.a @LIBPARSE@ -BUILT_SOURCES = ntpd-opts.c ntpd-opts.h ntpd.1 ntpd-opts.texi \ - ntpd-opts.menu ntpdsim-opts.c ntpdsim-opts.h ntpdsim.1 \ - ntpdsim-opts.texi ntpdsim-opts.menu -man_MANS = ntpd.1 ntpdsim.1 - -# ntpd may need: -# log10 refclock_wwv.o -# sqrt ntp_control.o -# floor refclock_wwv.o -# which are (usually) provided by -lm. -ntpd_LDADD = $(LDADD) -lm @LCRYPTO@ $(LIBOPTS_LDADD) ../libntp/libntp.a -ntpdsim_LDADD = $(LDADD) ../libntp/libntpsim.a -lm @LCRYPTO@ $(LIBOPTS_LDADD) -ntpdsim_CFLAGS = $(CFLAGS) -DSIM -check_y2k_LDADD = $(LDADD) ../libntp/libntp.a -DISTCLEANFILES = .version version.c -EXTRA_DIST = ntpd-opts.def ntpdbase-opts.def ntpdsim-opts.def \ +LDADD = version.o libntpd.a $(LIBPARSE) +AM_YFLAGS = -d -t -r all +@NTP_CROSSCOMPILE_FALSE@@SAVECONFIG_ENABLED_TRUE@CHECK_SAVECONFIG = check-saveconfig +@NTP_CROSSCOMPILE_TRUE@@SAVECONFIG_ENABLED_TRUE@CHECK_SAVECONFIG = +@SAVECONFIG_ENABLED_FALSE@CHECK_SAVECONFIG = +@VPATH_HACK_FALSE@VPHACK = + +# +# VPHACK and VPHACK_AFTER are enabled on non-GNU makes (such as +# BSD make) to work around issues specific to compiling +# ntp_parser.y into ntp_parser.h and ntp_parser.c in a VPATH +# configuration where we would like (for a change) the output +# files ntp_parser.[ch] to be placed in the source directory, +# as opposed to the build directory. This allows a single +# host of a flock configured with Bison to update ntp_parser.[ch] +# used by the rest. +# +@VPATH_HACK_TRUE@VPHACK = vphack +@VPATH_HACK_FALSE@VPHACK_AFTER = +@VPATH_HACK_TRUE@VPHACK_AFTER = vphack_after + +# BUILT_SOURCES which should also be in EXTRA_DIST +B_S_DIST = \ + $(srcdir)/ntpd-opts.c \ + $(srcdir)/ntpd-opts.h \ + $(NULL) + +BUILT_SOURCES = $(VPHACK) $(LIBPARSE) ntp_parser.c ntp_parser.h \ + $(VPHACK_AFTER) $(B_S_DIST) $(NULL) check-libopts check-libntp \ + .deps-ver +man1_MANS = +man5_MANS = ntp.conf.5 ntp.keys.5 +man8_MANS = +man_MANS = ntpd.$(NTPD_MS) + +# ntpdsim.1 is a remnant along with all the ntpdsim-opts.* files, the +# simulator currently uses ntpd-opts.[ch]. This also means there is no +# longer a reason to have ntpdbase-opts.def split off of ntpd-opts.def. +LDADD_NTPD_COMMON = $(LDADD_LIBNTP) $(LIBOPTS_LDADD) $(PTHREAD_LIBS) \ + $(LIBM) $(LDADD_NTP) $(LSCF) +ntpd_LDADD = $(LDADD) ../libntp/libntp.a $(LDADD_NTPD_COMMON) $(LDADD_LIBUTIL) +ntpdsim_LDADD = $(LDADD) ../libntp/libntpsim.a $(LDADD_NTPD_COMMON) +ntpdsim_CPPFLAGS = $(AM_CPPFLAGS) -DSIM +check_y2k_LDADD = $(LDADD) ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(LDADD_LIBNTP) $(PTHREAD_LIBS) +keyword_gen_LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) +DISTCLEANFILES = \ + keyword-gen \ + .version \ + version.c \ + config.log \ + $(man5_MANS) \ + $(man_MANS) \ + $(NULL) + +CLEANFILES = check-saveconfig compsave.conf k-g-u-submake \ + $(EXTRA_PROGRAMS) $(NULL) check-libopts check-libntp .deps-ver +EXTRA_DIST = \ + complete.conf.in \ + invoke-ntp.conf.menu \ + invoke-ntp.conf.texi \ + invoke-ntp.keys.menu \ + invoke-ntp.keys.texi \ + invoke-ntpd.menu \ + invoke-ntpd.texi \ + keyword-gen-utd \ + ntp.conf.5man \ + ntp.conf.5mdoc \ + ntp.conf.def \ + ntp.conf.man.in \ + ntp.conf.mdoc.in \ + ntp.conf.html \ + ntp.conf.texi \ + ntp.keys.5man \ + ntp.keys.5mdoc \ + ntp.keys.def \ + ntp.keys.man.in \ + ntp.keys.mdoc.in \ + ntp.keys.html \ + ntp.keys.texi \ + ntpd-opts.def \ + ntpd.1ntpdman \ + ntpd.1ntpdmdoc \ + ntpd.man.in \ + ntpd.mdoc.in \ + ntpd.html \ + ntpd.texi \ + ntpdbase-opts.def \ refclock_msfees.c \ - refclock_trak.c \ - $(BUILT_SOURCES) + $(B_S_DIST) \ + $(NULL) + -ETAGS_ARGS = Makefile.am ### Y2Kfixes check_PROGRAMS = @MAKE_CHECK_Y2K@ -run_ag = cd $(srcdir) && autogen -L ../include --writable -std_def_list = $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ - $(top_srcdir)/include/copyright.def \ - $(top_srcdir)/include/version.def - - -# SIM: cmd_args.c ntp_config.c ntp_io.c ntpd.c + ntpsim.c (include/ntpsim.h) -# ntp_resolver.c is presently unused... -ntpd_SOURCES = cmd_args.c ntp_config.c ntp_io.c ntpd.c ntpd-opts.c ntpd-opts.h -ntpdsim_SOURCES = $(ntpd_SOURCES) ntpsim.c ntpdsim-opts.c ntpdsim-opts.h -libntpd_a_SOURCES = jupiter.h ntp_control.c \ - ntp_crypto.c ntp_filegen.c \ - ntp_intres.c ntp_loopfilter.c ntp_monitor.c ntp_peer.c \ - ntp_proto.c ntp_refclock.c ntp_request.c \ - ntp_restrict.c ntp_timer.c ntp_util.c \ - ppsapi_timepps.h \ - refclock_acts.c refclock_arbiter.c refclock_arc.c refclock_as2201.c \ - refclock_atom.c refclock_bancomm.c refclock_chronolog.c \ - refclock_chu.c refclock_conf.c refclock_datum.c refclock_dumbclock.c \ - refclock_fg.c refclock_gpsvme.c refclock_heath.c refclock_hopfser.c \ - refclock_hopfpci.c refclock_hpgps.c refclock_irig.c refclock_jjy.c \ - refclock_jupiter.c refclock_leitch.c refclock_local.c \ - refclock_mx4200.c refclock_neoclock4x.c \ - refclock_nmea.c refclock_oncore.c refclock_palisade.c \ - refclock_palisade.h refclock_parse.c \ - refclock_pcf.c refclock_pst.c refclock_ripencc.c refclock_shm.c \ - refclock_tpro.c refclock_true.c refclock_tt560.c \ - refclock_ulink.c refclock_wwv.c refclock_wwvb.c \ - refclock_zyfer.c - +html_DATA = \ + $(srcdir)/ntp.conf.html \ + $(srcdir)/ntp.keys.html \ + $(srcdir)/ntpd.html \ + $(NULL) + +noinst_DATA = \ + $(srcdir)/invoke-ntp.conf.menu \ + $(srcdir)/invoke-ntp.conf.texi \ + $(srcdir)/invoke-ntp.keys.menu \ + $(srcdir)/invoke-ntp.keys.texi \ + $(srcdir)/invoke-ntpd.menu \ + $(srcdir)/invoke-ntpd.texi \ + $(srcdir)/ntp.conf.man.in \ + $(srcdir)/ntp.conf.mdoc.in \ + $(srcdir)/ntp.keys.man.in \ + $(srcdir)/ntp.keys.mdoc.in \ + $(srcdir)/ntpd.man.in \ + $(srcdir)/ntpd.mdoc.in \ + $(NULL) + +noinst_HEADERS = \ + declcond.h \ + ntp_leapsec.h \ + $(NULL) + +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +ntpd_SOURCES = \ + ntp_config.c \ + ntp_keyword.h \ + ntp_io.c \ + ntp_parser.y \ + ntp_scanner.c \ + ntp_scanner.h \ + ntpd.c \ + ntpd-opts.c \ + ntpd-opts.h \ + $(NULL) + +ntpdsim_SOURCES = \ + $(ntpd_SOURCES) \ + ntp_prio_q.c \ + ntpsim.c \ + $(NULL) + + +# libntpd_a_SOURCES do not use #ifdef SIM +libntpd_a_SOURCES = \ + cmd_args.c \ + jupiter.h \ + ntp_control.c \ + ntp_crypto.c \ + ntp_filegen.c \ + ntp_leapsec.c \ + ntp_loopfilter.c \ + ntp_monitor.c \ + ntp_peer.c \ + ntp_proto.c \ + ntp_refclock.c \ + ntp_request.c \ + ntp_restrict.c \ + ntp_signd.c \ + ntp_timer.c \ + ntp_util.c \ + ppsapi_timepps.h \ + rc_cmdlength.c \ + refclock_acts.c \ + refclock_arbiter.c \ + refclock_arc.c \ + refclock_as2201.c \ + refclock_atom.c \ + refclock_bancomm.c \ + refclock_chronolog.c \ + refclock_chu.c \ + refclock_conf.c \ + refclock_datum.c \ + refclock_dumbclock.c \ + refclock_fg.c \ + refclock_gpsdjson.c \ + refclock_gpsvme.c \ + refclock_heath.c \ + refclock_hopfser.c \ + refclock_hopfpci.c \ + refclock_hpgps.c \ + refclock_irig.c \ + refclock_jjy.c \ + refclock_jupiter.c \ + refclock_leitch.c \ + refclock_local.c \ + refclock_mx4200.c \ + refclock_neoclock4x.c \ + refclock_nmea.c \ + refclock_oncore.c \ + refclock_palisade.c \ + refclock_palisade.h \ + refclock_parse.c \ + refclock_pcf.c \ + refclock_pst.c \ + refclock_ripencc.c \ + refclock_shm.c \ + refclock_tpro.c \ + refclock_true.c \ + refclock_tt560.c \ + refclock_ulink.c \ + refclock_wwv.c \ + refclock_wwvb.c \ + refclock_zyfer.c \ + refclock_tsyncpci.c \ + $(NULL) + +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include all: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +.SUFFIXES: .c .lo .o .obj .y +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -365,7 +846,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__con echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ntpd/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign ntpd/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -374,6 +854,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -383,23 +864,31 @@ $(top_srcdir)/configure: $(am__configure_deps) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): +complete.conf: $(top_builddir)/config.status $(srcdir)/complete.conf.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ clean-noinstLIBRARIES: -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) -libntpd.a: $(libntpd_a_OBJECTS) $(libntpd_a_DEPENDENCIES) - -rm -f libntpd.a - $(libntpd_a_AR) libntpd.a $(libntpd_a_OBJECTS) $(libntpd_a_LIBADD) - $(RANLIB) libntpd.a + +libntpd.a: $(libntpd_a_OBJECTS) $(libntpd_a_DEPENDENCIES) $(EXTRA_libntpd_a_DEPENDENCIES) + $(AM_V_at)-rm -f libntpd.a + $(AM_V_AR)$(libntpd_a_AR) libntpd.a $(libntpd_a_OBJECTS) $(libntpd_a_LIBADD) + $(AM_V_at)$(RANLIB) libntpd.a install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p || test -f $$p1; \ - then echo "$$p"; echo "$$p"; else :; fi; \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ - sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ @@ -420,7 +909,8 @@ uninstall-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' `; \ + -e 's/$$/$(EXEEXT)/' \ + `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files @@ -442,387 +932,359 @@ clean-checkPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -check_y2k$(EXEEXT): $(check_y2k_OBJECTS) $(check_y2k_DEPENDENCIES) +install-libexecPROGRAMS: $(libexec_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(libexecdir)" && rm -f $$files + +clean-libexecPROGRAMS: + @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +check_y2k$(EXEEXT): $(check_y2k_OBJECTS) $(check_y2k_DEPENDENCIES) $(EXTRA_check_y2k_DEPENDENCIES) @rm -f check_y2k$(EXEEXT) - $(LINK) $(check_y2k_OBJECTS) $(check_y2k_LDADD) $(LIBS) -ntpd$(EXEEXT): $(ntpd_OBJECTS) $(ntpd_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(check_y2k_OBJECTS) $(check_y2k_LDADD) $(LIBS) + +keyword-gen$(EXEEXT): $(keyword_gen_OBJECTS) $(keyword_gen_DEPENDENCIES) $(EXTRA_keyword_gen_DEPENDENCIES) + @rm -f keyword-gen$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(keyword_gen_OBJECTS) $(keyword_gen_LDADD) $(LIBS) +ntp_parser.h: ntp_parser.c + @if test ! -f $@; then rm -f ntp_parser.c; else :; fi + @if test ! -f $@; then $(MAKE) $(AM_MAKEFLAGS) ntp_parser.c; else :; fi + +ntpd$(EXEEXT): $(ntpd_OBJECTS) $(ntpd_DEPENDENCIES) $(EXTRA_ntpd_DEPENDENCIES) @rm -f ntpd$(EXEEXT) - $(LINK) $(ntpd_OBJECTS) $(ntpd_LDADD) $(LIBS) -ntpdsim$(EXEEXT): $(ntpdsim_OBJECTS) $(ntpdsim_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(ntpd_OBJECTS) $(ntpd_LDADD) $(LIBS) + +ntpdsim$(EXEEXT): $(ntpdsim_OBJECTS) $(ntpdsim_DEPENDENCIES) $(EXTRA_ntpdsim_DEPENDENCIES) @rm -f ntpdsim$(EXEEXT) - $(ntpdsim_LINK) $(ntpdsim_OBJECTS) $(ntpdsim_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(ntpdsim_OBJECTS) $(ntpdsim_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check_y2k$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmd_args$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_config$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_control$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_crypto$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_filegen$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_intres$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_io$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_loopfilter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_monitor$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_peer$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_proto$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_refclock$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_request$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_restrict$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_timer$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_util$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-cmd_args$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_config$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_io$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpdsim-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpsim$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_acts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arbiter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_as2201$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_atom$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_bancomm$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chronolog$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chu$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_conf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_datum$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_dumbclock$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_fg$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_gpsvme$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_heath$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfpci$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfser$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hpgps$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_irig$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jjy$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jupiter$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_leitch$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_local$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_mx4200$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_neoclock4x$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_nmea$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_oncore$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_palisade$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_parse$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pcf$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pst$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ripencc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_shm$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tpro$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_true$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tt560$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ulink$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwv$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwvb$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_zyfer$U.Po@am__quote@ + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check_y2k.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmd_args.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keyword-gen.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_config.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_control.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_crypto.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_filegen.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_io.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_leapsec.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_loopfilter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_monitor.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_parser.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_peer.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_proto.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_refclock.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_request.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_restrict.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_scanner.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_signd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_timer.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntp_util.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_config.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_io.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_parser.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_prio_q.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntp_scanner.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdsim-ntpsim.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rc_cmdlength.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_acts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arbiter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_arc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_as2201.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_atom.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_bancomm.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chronolog.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_chu.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_conf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_datum.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_dumbclock.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_fg.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_gpsdjson.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_gpsvme.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_heath.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfpci.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hopfser.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_hpgps.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_irig.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jjy.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_jupiter.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_leitch.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_local.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_mx4200.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_neoclock4x.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_nmea.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_oncore.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_palisade.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_parse.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pcf.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_pst.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ripencc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_shm.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tpro.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_true.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tsyncpci.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_tt560.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_ulink.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwv.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_wwvb.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/refclock_zyfer.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +ntpdsim-ntp_config.o: ntp_config.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config.Tpo -c -o ntpdsim-ntp_config.o `test -f 'ntp_config.c' || echo '$(srcdir)/'`ntp_config.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_config.Tpo $(DEPDIR)/ntpdsim-ntp_config.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_config.c' object='ntpdsim-ntp_config.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config.o `test -f 'ntp_config.c' || echo '$(srcdir)/'`ntp_config.c + +ntpdsim-ntp_config.obj: ntp_config.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config.Tpo -c -o ntpdsim-ntp_config.obj `if test -f 'ntp_config.c'; then $(CYGPATH_W) 'ntp_config.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_config.Tpo $(DEPDIR)/ntpdsim-ntp_config.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_config.c' object='ntpdsim-ntp_config.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config.obj `if test -f 'ntp_config.c'; then $(CYGPATH_W) 'ntp_config.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config.c'; fi` -ntpdsim-cmd_args$U.o: cmd_args$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-cmd_args$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-cmd_args$U.Tpo -c -o ntpdsim-cmd_args$U.o `test -f 'cmd_args$U.c' || echo '$(srcdir)/'`cmd_args$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-cmd_args$U.Tpo $(DEPDIR)/ntpdsim-cmd_args$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='cmd_args$U.c' object='ntpdsim-cmd_args$U.o' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_io.o: ntp_io.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io.Tpo -c -o ntpdsim-ntp_io.o `test -f 'ntp_io.c' || echo '$(srcdir)/'`ntp_io.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_io.Tpo $(DEPDIR)/ntpdsim-ntp_io.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_io.c' object='ntpdsim-ntp_io.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-cmd_args$U.o `test -f 'cmd_args$U.c' || echo '$(srcdir)/'`cmd_args$U.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io.o `test -f 'ntp_io.c' || echo '$(srcdir)/'`ntp_io.c -ntpdsim-cmd_args$U.obj: cmd_args$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-cmd_args$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-cmd_args$U.Tpo -c -o ntpdsim-cmd_args$U.obj `if test -f 'cmd_args$U.c'; then $(CYGPATH_W) 'cmd_args$U.c'; else $(CYGPATH_W) '$(srcdir)/cmd_args$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-cmd_args$U.Tpo $(DEPDIR)/ntpdsim-cmd_args$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='cmd_args$U.c' object='ntpdsim-cmd_args$U.obj' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_io.obj: ntp_io.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io.Tpo -c -o ntpdsim-ntp_io.obj `if test -f 'ntp_io.c'; then $(CYGPATH_W) 'ntp_io.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_io.Tpo $(DEPDIR)/ntpdsim-ntp_io.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_io.c' object='ntpdsim-ntp_io.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-cmd_args$U.obj `if test -f 'cmd_args$U.c'; then $(CYGPATH_W) 'cmd_args$U.c'; else $(CYGPATH_W) '$(srcdir)/cmd_args$U.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io.obj `if test -f 'ntp_io.c'; then $(CYGPATH_W) 'ntp_io.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io.c'; fi` -ntpdsim-ntp_config$U.o: ntp_config$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config$U.Tpo -c -o ntpdsim-ntp_config$U.o `test -f 'ntp_config$U.c' || echo '$(srcdir)/'`ntp_config$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_config$U.Tpo $(DEPDIR)/ntpdsim-ntp_config$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_config$U.c' object='ntpdsim-ntp_config$U.o' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_parser.o: ntp_parser.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_parser.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_parser.Tpo -c -o ntpdsim-ntp_parser.o `test -f 'ntp_parser.c' || echo '$(srcdir)/'`ntp_parser.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_parser.Tpo $(DEPDIR)/ntpdsim-ntp_parser.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_parser.c' object='ntpdsim-ntp_parser.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config$U.o `test -f 'ntp_config$U.c' || echo '$(srcdir)/'`ntp_config$U.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_parser.o `test -f 'ntp_parser.c' || echo '$(srcdir)/'`ntp_parser.c -ntpdsim-ntp_config$U.obj: ntp_config$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_config$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_config$U.Tpo -c -o ntpdsim-ntp_config$U.obj `if test -f 'ntp_config$U.c'; then $(CYGPATH_W) 'ntp_config$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_config$U.Tpo $(DEPDIR)/ntpdsim-ntp_config$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_config$U.c' object='ntpdsim-ntp_config$U.obj' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_parser.obj: ntp_parser.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_parser.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_parser.Tpo -c -o ntpdsim-ntp_parser.obj `if test -f 'ntp_parser.c'; then $(CYGPATH_W) 'ntp_parser.c'; else $(CYGPATH_W) '$(srcdir)/ntp_parser.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_parser.Tpo $(DEPDIR)/ntpdsim-ntp_parser.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_parser.c' object='ntpdsim-ntp_parser.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_config$U.obj `if test -f 'ntp_config$U.c'; then $(CYGPATH_W) 'ntp_config$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_config$U.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_parser.obj `if test -f 'ntp_parser.c'; then $(CYGPATH_W) 'ntp_parser.c'; else $(CYGPATH_W) '$(srcdir)/ntp_parser.c'; fi` -ntpdsim-ntp_io$U.o: ntp_io$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io$U.Tpo -c -o ntpdsim-ntp_io$U.o `test -f 'ntp_io$U.c' || echo '$(srcdir)/'`ntp_io$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_io$U.Tpo $(DEPDIR)/ntpdsim-ntp_io$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_io$U.c' object='ntpdsim-ntp_io$U.o' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_scanner.o: ntp_scanner.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_scanner.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_scanner.Tpo -c -o ntpdsim-ntp_scanner.o `test -f 'ntp_scanner.c' || echo '$(srcdir)/'`ntp_scanner.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_scanner.Tpo $(DEPDIR)/ntpdsim-ntp_scanner.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_scanner.c' object='ntpdsim-ntp_scanner.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io$U.o `test -f 'ntp_io$U.c' || echo '$(srcdir)/'`ntp_io$U.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_scanner.o `test -f 'ntp_scanner.c' || echo '$(srcdir)/'`ntp_scanner.c -ntpdsim-ntp_io$U.obj: ntp_io$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_io$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_io$U.Tpo -c -o ntpdsim-ntp_io$U.obj `if test -f 'ntp_io$U.c'; then $(CYGPATH_W) 'ntp_io$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntp_io$U.Tpo $(DEPDIR)/ntpdsim-ntp_io$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntp_io$U.c' object='ntpdsim-ntp_io$U.obj' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_scanner.obj: ntp_scanner.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_scanner.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_scanner.Tpo -c -o ntpdsim-ntp_scanner.obj `if test -f 'ntp_scanner.c'; then $(CYGPATH_W) 'ntp_scanner.c'; else $(CYGPATH_W) '$(srcdir)/ntp_scanner.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_scanner.Tpo $(DEPDIR)/ntpdsim-ntp_scanner.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_scanner.c' object='ntpdsim-ntp_scanner.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_io$U.obj `if test -f 'ntp_io$U.c'; then $(CYGPATH_W) 'ntp_io$U.c'; else $(CYGPATH_W) '$(srcdir)/ntp_io$U.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_scanner.obj `if test -f 'ntp_scanner.c'; then $(CYGPATH_W) 'ntp_scanner.c'; else $(CYGPATH_W) '$(srcdir)/ntp_scanner.c'; fi` -ntpdsim-ntpd$U.o: ntpd$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd$U.Tpo -c -o ntpdsim-ntpd$U.o `test -f 'ntpd$U.c' || echo '$(srcdir)/'`ntpd$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd$U.Tpo $(DEPDIR)/ntpdsim-ntpd$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd$U.c' object='ntpdsim-ntpd$U.o' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntpd.o: ntpd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd.Tpo -c -o ntpdsim-ntpd.o `test -f 'ntpd.c' || echo '$(srcdir)/'`ntpd.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntpd.Tpo $(DEPDIR)/ntpdsim-ntpd.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntpd.c' object='ntpdsim-ntpd.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd$U.o `test -f 'ntpd$U.c' || echo '$(srcdir)/'`ntpd$U.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd.o `test -f 'ntpd.c' || echo '$(srcdir)/'`ntpd.c -ntpdsim-ntpd$U.obj: ntpd$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd$U.Tpo -c -o ntpdsim-ntpd$U.obj `if test -f 'ntpd$U.c'; then $(CYGPATH_W) 'ntpd$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd$U.Tpo $(DEPDIR)/ntpdsim-ntpd$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd$U.c' object='ntpdsim-ntpd$U.obj' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntpd.obj: ntpd.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd.Tpo -c -o ntpdsim-ntpd.obj `if test -f 'ntpd.c'; then $(CYGPATH_W) 'ntpd.c'; else $(CYGPATH_W) '$(srcdir)/ntpd.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntpd.Tpo $(DEPDIR)/ntpdsim-ntpd.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntpd.c' object='ntpdsim-ntpd.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd$U.obj `if test -f 'ntpd$U.c'; then $(CYGPATH_W) 'ntpd$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd$U.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd.obj `if test -f 'ntpd.c'; then $(CYGPATH_W) 'ntpd.c'; else $(CYGPATH_W) '$(srcdir)/ntpd.c'; fi` -ntpdsim-ntpd-opts$U.o: ntpd-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo -c -o ntpdsim-ntpd-opts$U.o `test -f 'ntpd-opts$U.c' || echo '$(srcdir)/'`ntpd-opts$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpd-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd-opts$U.c' object='ntpdsim-ntpd-opts$U.o' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntpd-opts.o: ntpd-opts.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts.Tpo -c -o ntpdsim-ntpd-opts.o `test -f 'ntpd-opts.c' || echo '$(srcdir)/'`ntpd-opts.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts.Tpo $(DEPDIR)/ntpdsim-ntpd-opts.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntpd-opts.c' object='ntpdsim-ntpd-opts.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts$U.o `test -f 'ntpd-opts$U.c' || echo '$(srcdir)/'`ntpd-opts$U.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts.o `test -f 'ntpd-opts.c' || echo '$(srcdir)/'`ntpd-opts.c -ntpdsim-ntpd-opts$U.obj: ntpd-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo -c -o ntpdsim-ntpd-opts$U.obj `if test -f 'ntpd-opts$U.c'; then $(CYGPATH_W) 'ntpd-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpd-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpd-opts$U.c' object='ntpdsim-ntpd-opts$U.obj' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntpd-opts.obj: ntpd-opts.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpd-opts.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpd-opts.Tpo -c -o ntpdsim-ntpd-opts.obj `if test -f 'ntpd-opts.c'; then $(CYGPATH_W) 'ntpd-opts.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntpd-opts.Tpo $(DEPDIR)/ntpdsim-ntpd-opts.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntpd-opts.c' object='ntpdsim-ntpd-opts.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts$U.obj `if test -f 'ntpd-opts$U.c'; then $(CYGPATH_W) 'ntpd-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts$U.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpd-opts.obj `if test -f 'ntpd-opts.c'; then $(CYGPATH_W) 'ntpd-opts.c'; else $(CYGPATH_W) '$(srcdir)/ntpd-opts.c'; fi` -ntpdsim-ntpsim$U.o: ntpsim$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim$U.Tpo -c -o ntpdsim-ntpsim$U.o `test -f 'ntpsim$U.c' || echo '$(srcdir)/'`ntpsim$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpsim$U.Tpo $(DEPDIR)/ntpdsim-ntpsim$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpsim$U.c' object='ntpdsim-ntpsim$U.o' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_prio_q.o: ntp_prio_q.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_prio_q.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_prio_q.Tpo -c -o ntpdsim-ntp_prio_q.o `test -f 'ntp_prio_q.c' || echo '$(srcdir)/'`ntp_prio_q.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_prio_q.Tpo $(DEPDIR)/ntpdsim-ntp_prio_q.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_prio_q.c' object='ntpdsim-ntp_prio_q.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim$U.o `test -f 'ntpsim$U.c' || echo '$(srcdir)/'`ntpsim$U.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_prio_q.o `test -f 'ntp_prio_q.c' || echo '$(srcdir)/'`ntp_prio_q.c -ntpdsim-ntpsim$U.obj: ntpsim$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim$U.Tpo -c -o ntpdsim-ntpsim$U.obj `if test -f 'ntpsim$U.c'; then $(CYGPATH_W) 'ntpsim$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpsim$U.Tpo $(DEPDIR)/ntpdsim-ntpsim$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpsim$U.c' object='ntpdsim-ntpsim$U.obj' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntp_prio_q.obj: ntp_prio_q.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntp_prio_q.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntp_prio_q.Tpo -c -o ntpdsim-ntp_prio_q.obj `if test -f 'ntp_prio_q.c'; then $(CYGPATH_W) 'ntp_prio_q.c'; else $(CYGPATH_W) '$(srcdir)/ntp_prio_q.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntp_prio_q.Tpo $(DEPDIR)/ntpdsim-ntp_prio_q.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntp_prio_q.c' object='ntpdsim-ntp_prio_q.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim$U.obj `if test -f 'ntpsim$U.c'; then $(CYGPATH_W) 'ntpsim$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim$U.c'; fi` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntp_prio_q.obj `if test -f 'ntp_prio_q.c'; then $(CYGPATH_W) 'ntp_prio_q.c'; else $(CYGPATH_W) '$(srcdir)/ntp_prio_q.c'; fi` -ntpdsim-ntpdsim-opts$U.o: ntpdsim-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpdsim-opts$U.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo -c -o ntpdsim-ntpdsim-opts$U.o `test -f 'ntpdsim-opts$U.c' || echo '$(srcdir)/'`ntpdsim-opts$U.c -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpdsim-opts$U.c' object='ntpdsim-ntpdsim-opts$U.o' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntpsim.o: ntpsim.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim.o -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim.Tpo -c -o ntpdsim-ntpsim.o `test -f 'ntpsim.c' || echo '$(srcdir)/'`ntpsim.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntpsim.Tpo $(DEPDIR)/ntpdsim-ntpsim.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntpsim.c' object='ntpdsim-ntpsim.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpdsim-opts$U.o `test -f 'ntpdsim-opts$U.c' || echo '$(srcdir)/'`ntpdsim-opts$U.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim.o `test -f 'ntpsim.c' || echo '$(srcdir)/'`ntpsim.c -ntpdsim-ntpdsim-opts$U.obj: ntpdsim-opts$U.c -@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpdsim-opts$U.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo -c -o ntpdsim-ntpdsim-opts$U.obj `if test -f 'ntpdsim-opts$U.c'; then $(CYGPATH_W) 'ntpdsim-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpdsim-opts$U.c'; fi` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Tpo $(DEPDIR)/ntpdsim-ntpdsim-opts$U.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='ntpdsim-opts$U.c' object='ntpdsim-ntpdsim-opts$U.obj' libtool=no @AMDEPBACKSLASH@ +ntpdsim-ntpsim.obj: ntpsim.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT ntpdsim-ntpsim.obj -MD -MP -MF $(DEPDIR)/ntpdsim-ntpsim.Tpo -c -o ntpdsim-ntpsim.obj `if test -f 'ntpsim.c'; then $(CYGPATH_W) 'ntpsim.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/ntpdsim-ntpsim.Tpo $(DEPDIR)/ntpdsim-ntpsim.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='ntpsim.c' object='ntpdsim-ntpsim.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ntpdsim_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpdsim-opts$U.obj `if test -f 'ntpdsim-opts$U.c'; then $(CYGPATH_W) 'ntpdsim-opts$U.c'; else $(CYGPATH_W) '$(srcdir)/ntpdsim-opts$U.c'; fi` -check_y2k_.c: check_y2k.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/check_y2k.c; then echo $(srcdir)/check_y2k.c; else echo check_y2k.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -cmd_args_.c: cmd_args.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/cmd_args.c; then echo $(srcdir)/cmd_args.c; else echo cmd_args.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_config_.c: ntp_config.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_config.c; then echo $(srcdir)/ntp_config.c; else echo ntp_config.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_control_.c: ntp_control.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_control.c; then echo $(srcdir)/ntp_control.c; else echo ntp_control.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_crypto_.c: ntp_crypto.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_crypto.c; then echo $(srcdir)/ntp_crypto.c; else echo ntp_crypto.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_filegen_.c: ntp_filegen.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_filegen.c; then echo $(srcdir)/ntp_filegen.c; else echo ntp_filegen.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_intres_.c: ntp_intres.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_intres.c; then echo $(srcdir)/ntp_intres.c; else echo ntp_intres.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_io_.c: ntp_io.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_io.c; then echo $(srcdir)/ntp_io.c; else echo ntp_io.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_loopfilter_.c: ntp_loopfilter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_loopfilter.c; then echo $(srcdir)/ntp_loopfilter.c; else echo ntp_loopfilter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_monitor_.c: ntp_monitor.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_monitor.c; then echo $(srcdir)/ntp_monitor.c; else echo ntp_monitor.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_peer_.c: ntp_peer.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_peer.c; then echo $(srcdir)/ntp_peer.c; else echo ntp_peer.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_proto_.c: ntp_proto.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_proto.c; then echo $(srcdir)/ntp_proto.c; else echo ntp_proto.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_refclock_.c: ntp_refclock.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_refclock.c; then echo $(srcdir)/ntp_refclock.c; else echo ntp_refclock.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_request_.c: ntp_request.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_request.c; then echo $(srcdir)/ntp_request.c; else echo ntp_request.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_restrict_.c: ntp_restrict.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_restrict.c; then echo $(srcdir)/ntp_restrict.c; else echo ntp_restrict.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_timer_.c: ntp_timer.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_timer.c; then echo $(srcdir)/ntp_timer.c; else echo ntp_timer.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntp_util_.c: ntp_util.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntp_util.c; then echo $(srcdir)/ntp_util.c; else echo ntp_util.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpd_.c: ntpd.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpd.c; then echo $(srcdir)/ntpd.c; else echo ntpd.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpd-opts_.c: ntpd-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpd-opts.c; then echo $(srcdir)/ntpd-opts.c; else echo ntpd-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdsim-opts_.c: ntpdsim-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdsim-opts.c; then echo $(srcdir)/ntpdsim-opts.c; else echo ntpdsim-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpsim_.c: ntpsim.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpsim.c; then echo $(srcdir)/ntpsim.c; else echo ntpsim.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_acts_.c: refclock_acts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_acts.c; then echo $(srcdir)/refclock_acts.c; else echo refclock_acts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_arbiter_.c: refclock_arbiter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_arbiter.c; then echo $(srcdir)/refclock_arbiter.c; else echo refclock_arbiter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_arc_.c: refclock_arc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_arc.c; then echo $(srcdir)/refclock_arc.c; else echo refclock_arc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_as2201_.c: refclock_as2201.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_as2201.c; then echo $(srcdir)/refclock_as2201.c; else echo refclock_as2201.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_atom_.c: refclock_atom.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_atom.c; then echo $(srcdir)/refclock_atom.c; else echo refclock_atom.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_bancomm_.c: refclock_bancomm.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_bancomm.c; then echo $(srcdir)/refclock_bancomm.c; else echo refclock_bancomm.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_chronolog_.c: refclock_chronolog.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_chronolog.c; then echo $(srcdir)/refclock_chronolog.c; else echo refclock_chronolog.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_chu_.c: refclock_chu.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_chu.c; then echo $(srcdir)/refclock_chu.c; else echo refclock_chu.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_conf_.c: refclock_conf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_conf.c; then echo $(srcdir)/refclock_conf.c; else echo refclock_conf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_datum_.c: refclock_datum.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_datum.c; then echo $(srcdir)/refclock_datum.c; else echo refclock_datum.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_dumbclock_.c: refclock_dumbclock.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_dumbclock.c; then echo $(srcdir)/refclock_dumbclock.c; else echo refclock_dumbclock.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_fg_.c: refclock_fg.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_fg.c; then echo $(srcdir)/refclock_fg.c; else echo refclock_fg.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_gpsvme_.c: refclock_gpsvme.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_gpsvme.c; then echo $(srcdir)/refclock_gpsvme.c; else echo refclock_gpsvme.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_heath_.c: refclock_heath.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_heath.c; then echo $(srcdir)/refclock_heath.c; else echo refclock_heath.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_hopfpci_.c: refclock_hopfpci.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_hopfpci.c; then echo $(srcdir)/refclock_hopfpci.c; else echo refclock_hopfpci.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_hopfser_.c: refclock_hopfser.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_hopfser.c; then echo $(srcdir)/refclock_hopfser.c; else echo refclock_hopfser.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_hpgps_.c: refclock_hpgps.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_hpgps.c; then echo $(srcdir)/refclock_hpgps.c; else echo refclock_hpgps.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_irig_.c: refclock_irig.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_irig.c; then echo $(srcdir)/refclock_irig.c; else echo refclock_irig.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_jjy_.c: refclock_jjy.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_jjy.c; then echo $(srcdir)/refclock_jjy.c; else echo refclock_jjy.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_jupiter_.c: refclock_jupiter.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_jupiter.c; then echo $(srcdir)/refclock_jupiter.c; else echo refclock_jupiter.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_leitch_.c: refclock_leitch.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_leitch.c; then echo $(srcdir)/refclock_leitch.c; else echo refclock_leitch.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_local_.c: refclock_local.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_local.c; then echo $(srcdir)/refclock_local.c; else echo refclock_local.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_mx4200_.c: refclock_mx4200.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_mx4200.c; then echo $(srcdir)/refclock_mx4200.c; else echo refclock_mx4200.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_neoclock4x_.c: refclock_neoclock4x.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_neoclock4x.c; then echo $(srcdir)/refclock_neoclock4x.c; else echo refclock_neoclock4x.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_nmea_.c: refclock_nmea.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_nmea.c; then echo $(srcdir)/refclock_nmea.c; else echo refclock_nmea.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_oncore_.c: refclock_oncore.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_oncore.c; then echo $(srcdir)/refclock_oncore.c; else echo refclock_oncore.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_palisade_.c: refclock_palisade.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_palisade.c; then echo $(srcdir)/refclock_palisade.c; else echo refclock_palisade.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_parse_.c: refclock_parse.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_parse.c; then echo $(srcdir)/refclock_parse.c; else echo refclock_parse.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_pcf_.c: refclock_pcf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_pcf.c; then echo $(srcdir)/refclock_pcf.c; else echo refclock_pcf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_pst_.c: refclock_pst.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_pst.c; then echo $(srcdir)/refclock_pst.c; else echo refclock_pst.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_ripencc_.c: refclock_ripencc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_ripencc.c; then echo $(srcdir)/refclock_ripencc.c; else echo refclock_ripencc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_shm_.c: refclock_shm.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_shm.c; then echo $(srcdir)/refclock_shm.c; else echo refclock_shm.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_tpro_.c: refclock_tpro.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_tpro.c; then echo $(srcdir)/refclock_tpro.c; else echo refclock_tpro.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_true_.c: refclock_true.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_true.c; then echo $(srcdir)/refclock_true.c; else echo refclock_true.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_tt560_.c: refclock_tt560.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_tt560.c; then echo $(srcdir)/refclock_tt560.c; else echo refclock_tt560.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_ulink_.c: refclock_ulink.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_ulink.c; then echo $(srcdir)/refclock_ulink.c; else echo refclock_ulink.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_wwv_.c: refclock_wwv.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_wwv.c; then echo $(srcdir)/refclock_wwv.c; else echo refclock_wwv.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_wwvb_.c: refclock_wwvb.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_wwvb.c; then echo $(srcdir)/refclock_wwvb.c; else echo refclock_wwvb.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -refclock_zyfer_.c: refclock_zyfer.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/refclock_zyfer.c; then echo $(srcdir)/refclock_zyfer.c; else echo refclock_zyfer.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -check_y2k_.$(OBJEXT) check_y2k_.lo cmd_args_.$(OBJEXT) cmd_args_.lo \ -ntp_config_.$(OBJEXT) ntp_config_.lo ntp_control_.$(OBJEXT) \ -ntp_control_.lo ntp_crypto_.$(OBJEXT) ntp_crypto_.lo \ -ntp_filegen_.$(OBJEXT) ntp_filegen_.lo ntp_intres_.$(OBJEXT) \ -ntp_intres_.lo ntp_io_.$(OBJEXT) ntp_io_.lo ntp_loopfilter_.$(OBJEXT) \ -ntp_loopfilter_.lo ntp_monitor_.$(OBJEXT) ntp_monitor_.lo \ -ntp_peer_.$(OBJEXT) ntp_peer_.lo ntp_proto_.$(OBJEXT) ntp_proto_.lo \ -ntp_refclock_.$(OBJEXT) ntp_refclock_.lo ntp_request_.$(OBJEXT) \ -ntp_request_.lo ntp_restrict_.$(OBJEXT) ntp_restrict_.lo \ -ntp_timer_.$(OBJEXT) ntp_timer_.lo ntp_util_.$(OBJEXT) ntp_util_.lo \ -ntpd_.$(OBJEXT) ntpd_.lo ntpd-opts_.$(OBJEXT) ntpd-opts_.lo \ -ntpdsim-opts_.$(OBJEXT) ntpdsim-opts_.lo ntpsim_.$(OBJEXT) ntpsim_.lo \ -refclock_acts_.$(OBJEXT) refclock_acts_.lo refclock_arbiter_.$(OBJEXT) \ -refclock_arbiter_.lo refclock_arc_.$(OBJEXT) refclock_arc_.lo \ -refclock_as2201_.$(OBJEXT) refclock_as2201_.lo \ -refclock_atom_.$(OBJEXT) refclock_atom_.lo refclock_bancomm_.$(OBJEXT) \ -refclock_bancomm_.lo refclock_chronolog_.$(OBJEXT) \ -refclock_chronolog_.lo refclock_chu_.$(OBJEXT) refclock_chu_.lo \ -refclock_conf_.$(OBJEXT) refclock_conf_.lo refclock_datum_.$(OBJEXT) \ -refclock_datum_.lo refclock_dumbclock_.$(OBJEXT) \ -refclock_dumbclock_.lo refclock_fg_.$(OBJEXT) refclock_fg_.lo \ -refclock_gpsvme_.$(OBJEXT) refclock_gpsvme_.lo \ -refclock_heath_.$(OBJEXT) refclock_heath_.lo \ -refclock_hopfpci_.$(OBJEXT) refclock_hopfpci_.lo \ -refclock_hopfser_.$(OBJEXT) refclock_hopfser_.lo \ -refclock_hpgps_.$(OBJEXT) refclock_hpgps_.lo refclock_irig_.$(OBJEXT) \ -refclock_irig_.lo refclock_jjy_.$(OBJEXT) refclock_jjy_.lo \ -refclock_jupiter_.$(OBJEXT) refclock_jupiter_.lo \ -refclock_leitch_.$(OBJEXT) refclock_leitch_.lo \ -refclock_local_.$(OBJEXT) refclock_local_.lo \ -refclock_mx4200_.$(OBJEXT) refclock_mx4200_.lo \ -refclock_neoclock4x_.$(OBJEXT) refclock_neoclock4x_.lo \ -refclock_nmea_.$(OBJEXT) refclock_nmea_.lo refclock_oncore_.$(OBJEXT) \ -refclock_oncore_.lo refclock_palisade_.$(OBJEXT) refclock_palisade_.lo \ -refclock_parse_.$(OBJEXT) refclock_parse_.lo refclock_pcf_.$(OBJEXT) \ -refclock_pcf_.lo refclock_pst_.$(OBJEXT) refclock_pst_.lo \ -refclock_ripencc_.$(OBJEXT) refclock_ripencc_.lo \ -refclock_shm_.$(OBJEXT) refclock_shm_.lo refclock_tpro_.$(OBJEXT) \ -refclock_tpro_.lo refclock_true_.$(OBJEXT) refclock_true_.lo \ -refclock_tt560_.$(OBJEXT) refclock_tt560_.lo refclock_ulink_.$(OBJEXT) \ -refclock_ulink_.lo refclock_wwv_.$(OBJEXT) refclock_wwv_.lo \ -refclock_wwvb_.$(OBJEXT) refclock_wwvb_.lo refclock_zyfer_.$(OBJEXT) \ -refclock_zyfer_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(ntpdsim_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o ntpdsim-ntpsim.obj `if test -f 'ntpsim.c'; then $(CYGPATH_W) 'ntpsim.c'; else $(CYGPATH_W) '$(srcdir)/ntpsim.c'; fi` + +.y.c: + $(AM_V_YACC)$(am__skipyacc) $(SHELL) $(YLWRAP) $< y.tab.c $@ y.tab.h `echo $@ | $(am__yacc_c2h)` y.output $*.output -- $(YACCCOMPILE) mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs -install-man1: $(man_MANS) +install-man1: $(man1_MANS) $(man_MANS) @$(NORMAL_INSTALL) - test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" - @list=''; test -n "$(man1dir)" || exit 0; \ - { for i in $$list; do echo "$$i"; done; \ - l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ - sed -n '/\.1[a-z]*$$/p'; \ + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ } | while read p; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; echo "$$p"; \ @@ -845,36 +1307,130 @@ install-man1: $(man_MANS) uninstall-man1: @$(NORMAL_UNINSTALL) - @list=''; test -n "$(man1dir)" || exit 0; \ + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ files=`{ for i in $$list; do echo "$$i"; done; \ l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ - test -z "$$files" || { \ - echo " ( cd '$(DESTDIR)$(man1dir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(man1dir)" && rm -f $$files; } - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man5: $(man5_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man5_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man5dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man5dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man5dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.5[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man5dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man5dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man5dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man5dir)" || exit $$?; }; \ + done; } + +uninstall-man5: + @$(NORMAL_UNINSTALL) + @list='$(man5_MANS)'; test -n "$(man5dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.5[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man5dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -886,15 +1442,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -903,24 +1455,26 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) - @list='$(MANS)'; if test -n "$$list"; then \ - list=`for p in $$list; do \ - if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ - if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \ - if test -n "$$list" && \ - grep 'ab help2man is required to generate this page' $$list >/dev/null; then \ - echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \ - grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \ - echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \ - echo " typically \`make maintainer-clean' will remove them" >&2; \ - exit 1; \ - else :; fi; \ - else :; fi @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -955,9 +1509,9 @@ check-am: all-am $(MAKE) $(AM_MAKEFLAGS) check-local check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am -all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(MANS) +all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -971,13 +1525,19 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -987,11 +1547,14 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -rm -f ntp_parser.c + -rm -f ntp_parser.h -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-binPROGRAMS clean-checkPROGRAMS clean-generic \ - clean-libtool clean-noinstLIBRARIES mostlyclean-am + clean-libexecPROGRAMS clean-libtool clean-noinstLIBRARIES \ + clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -1011,13 +1574,14 @@ info: info-am info-am: -install-data-am: install-man +install-data-am: install-data-local install-htmlDATA install-man install-dvi: install-dvi-am install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-libexecPROGRAMS \ + install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -1028,7 +1592,7 @@ install-info: install-info-am install-info-am: -install-man: install-man1 +install-man: install-man1 install-man5 install-man8 install-pdf: install-pdf-am @@ -1047,7 +1611,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -1058,84 +1622,301 @@ ps: ps-am ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-htmlDATA \ + uninstall-libexecPROGRAMS uninstall-man uninstall-sbinPROGRAMS -uninstall-man: uninstall-man1 +uninstall-man: uninstall-man1 uninstall-man5 uninstall-man8 -.MAKE: ../util/ansi2knr all check check-am install install-am \ - install-exec-am install-strip +.MAKE: all check check-am install install-am install-exec-am \ + install-strip -.PHONY: CTAGS GTAGS all all-am check check-am check-local clean \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am check-local clean \ clean-binPROGRAMS clean-checkPROGRAMS clean-generic \ - clean-libtool clean-noinstLIBRARIES ctags distclean \ + clean-libexecPROGRAMS clean-libtool clean-noinstLIBRARIES \ + clean-sbinPROGRAMS cscopelist-am ctags ctags-am distclean \ distclean-compile distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am html html-am info info-am \ install install-am install-binPROGRAMS install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-exec-hook install-html install-html-am \ - install-info install-info-am install-man install-man1 \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-kr \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am uninstall-binPROGRAMS uninstall-man \ - uninstall-man1 + install-data-am install-data-local install-dvi install-dvi-am \ + install-exec install-exec-am install-exec-hook install-html \ + install-html-am install-htmlDATA install-info install-info-am \ + install-libexecPROGRAMS install-man install-man1 install-man5 \ + install-man8 install-pdf install-pdf-am install-ps \ + install-ps-am install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-htmlDATA uninstall-libexecPROGRAMS uninstall-man \ + uninstall-man1 uninstall-man5 uninstall-man8 \ + uninstall-sbinPROGRAMS + +.PRECIOUS: Makefile -check-local: @MAKE_CHECK_Y2K@ - test -z "@MAKE_CHECK_Y2K@" || ./@MAKE_CHECK_Y2K@ +vphack: + test -e ntp_parser.c || ln -s $(srcdir)/ntp_parser.c . + test -e ntp_parser.h || ln -s $(srcdir)/ntp_parser.h . + +# +# ylwrap script which invokes Bison replaces ntp_parser.h +# symlink with the updated file, when ntp_parser.h changes. +# vphack_after detects this and copies the updated file to srcdir +# and re-creates the ntp_parser.h symlink in its place. +# + +vphack_after: + test -L ntp_parser.h || ( \ + mv ntp_parser.h $(srcdir)/ntp_parser.h && \ + ln -s $(srcdir)/ntp_parser.h . \ + ) + +install-data-local: install-html + +check-local: $(MAKE_CHECK_Y2K) $(CHECK_SAVECONFIG) + test -z "$(MAKE_CHECK_Y2K)" || ./$(MAKE_CHECK_Y2K) + +k-g-u-submake: keyword-gen + ./keyword-gen $(srcdir)/ntp_parser.h > k-g.out + @grep -v diff_ignore_line < k-g.out > cmp1 + @grep -v diff_ignore_line < $(srcdir)/ntp_keyword.h > cmp2 + @cmp cmp1 cmp2 > /dev/null || \ + { mv -f k-g.out $(srcdir)/ntp_keyword.h && \ + echo 'Generated changed ntp_keyword.h.' ;} + @[ ! -f k-g.out ] || \ + { rm k-g.out && echo 'ntp_keyword.h is up to date.' ;} + @rm cmp1 cmp2 + @echo 'keyword-gen and ntp_keyword.h are up to date.' > $@ + +$(srcdir)/keyword-gen-utd: $(srcdir)/keyword-gen.c $(srcdir)/ntp_parser.h + $(MAKE) $(AM_MAKEFLAGS) k-g-u-submake # avoid explicit dependency + grep diff_ignore_line $(srcdir)/ntp_keyword.h > k-g-u + mv -f k-g-u $@ + +$(srcdir)/ntp_keyword.h: $(srcdir)/keyword-gen-utd + @: do-nothing action to avoid default SCCS get + @: .h updated if needed by k-g-u-submake rule $(srcdir)/ntpd-opts.h: $(srcdir)/ntpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpd-opts.c: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(run_ag) ntpd-opts.def -$(srcdir)/ntpd.1: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) - $(run_ag) -Tagman1.tpl -bntpd ntpd-opts.def +### + +$(srcdir)/ntpd.1ntpdman: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdman -Tagman-cmd.tpl ntpd-opts.def -$(srcdir)/ntpd-opts.texi $(srcdir)/ntpd-opts.menu: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpd-opts.def +$(srcdir)/ntpd.man.in: $(srcdir)/ntpd.1ntpdman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpd.1ntpdman > $(srcdir)/ntpd.man.in+ + mv $(srcdir)/ntpd.man.in+ $(srcdir)/ntpd.man.in -$(srcdir)/ntpdsim-opts.h: $(srcdir)/ntpdsim-opts.c -$(srcdir)/ntpdsim-opts.c: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) ntpdsim-opts.def +### -$(srcdir)/ntpdsim.1: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Tagman1.tpl -bntpdsim ntpdsim-opts.def +$(srcdir)/ntpd.1ntpdmdoc: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdmdoc -Tagmdoc-cmd.tpl ntpd-opts.def -$(srcdir)/ntpdsim-opts.texi $(srcdir)/ntpdsim-opts.menu: $(srcdir)/ntpdsim-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) $(top_srcdir)/include/homerc.def - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdsim-opts.def +$(srcdir)/ntpd.mdoc.in: $(srcdir)/ntpd.1ntpdmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpd.1ntpdmdoc > $(srcdir)/ntpd.mdoc.in+ + mv $(srcdir)/ntpd.mdoc.in+ $(srcdir)/ntpd.mdoc.in + +### + +ntpd.$(NTPD_MS): $(srcdir)/ntpd.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpd.$(NTPD_MS)+:$(srcdir)/ntpd.$(MANTAGFMT).in + mv ntpd.$(NTPD_MS)+ ntpd.$(NTPD_MS) + +### + +$(srcdir)/invoke-ntp.conf.menu: $(srcdir)/invoke-ntp.conf.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntp.conf.texi: $(srcdir)/ntp.conf.def $(std_def_list) + $(run_ag) -Tagtexi-file.tpl -DLEVEL=section ntp.conf.def + +$(srcdir)/invoke-ntp.keys.menu: $(srcdir)/invoke-ntp.keys.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntp.keys.texi: $(srcdir)/ntp.keys.def $(std_def_list) + $(run_ag) -Tagtexi-file.tpl -DLEVEL=section ntp.keys.def + +$(srcdir)/ntp.conf.html: $(srcdir)/ntp.conf.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntp.conf.html ntp.conf.texi || true ) + +$(srcdir)/ntp.keys.html: $(srcdir)/ntp.keys.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntp.keys.html ntp.keys.texi || true ) + +$(srcdir)/ntpd.html: $(srcdir)/ntpd.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntpd.html ntpd.texi || true ) + +### + +$(srcdir)/ntp.conf.5man: $(srcdir)/ntp.conf.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5man -Tagman-cmd.tpl ntp.conf.def + +$(srcdir)/ntp.conf.man.in: $(srcdir)/ntp.conf.5man $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.conf.5man > $(srcdir)/ntp.conf.man.in+ + mv $(srcdir)/ntp.conf.man.in+ $(srcdir)/ntp.conf.man.in + +### + +$(srcdir)/ntp.conf.5mdoc: $(srcdir)/ntp.conf.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5mdoc -Tagmdoc-cmd.tpl ntp.conf.def + +$(srcdir)/ntp.conf.mdoc.in: $(srcdir)/ntp.conf.5mdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.conf.5mdoc > $(srcdir)/ntp.conf.mdoc.in+ + mv $(srcdir)/ntp.conf.mdoc.in+ $(srcdir)/ntp.conf.mdoc.in + +### + +ntp.conf.5: $(srcdir)/ntp.conf.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntp.conf.5+:$(srcdir)/ntp.conf.$(MANTAGFMT).in + mv ntp.conf.5+ ntp.conf.5 + +### + +$(srcdir)/ntp.keys.5man: $(srcdir)/ntp.keys.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5man -Tagman-file.tpl ntp.keys.def + +$(srcdir)/ntp.keys.man.in: $(srcdir)/ntp.keys.5man $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.keys.5man > $(srcdir)/ntp.keys.man.in+ + mv $(srcdir)/ntp.keys.man.in+ $(srcdir)/ntp.keys.man.in + +### + +$(srcdir)/ntp.keys.5mdoc: $(srcdir)/ntp.keys.def $(std_def_list) + $(run_ag) -DMAN_SECTION=5mdoc -Tagmdoc-file.tpl ntp.keys.def + +$(srcdir)/ntp.keys.mdoc.in: $(srcdir)/ntp.keys.5mdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp.keys.5mdoc > $(srcdir)/ntp.keys.mdoc.in+ + mv $(srcdir)/ntp.keys.mdoc.in+ $(srcdir)/ntp.keys.mdoc.in + +### + +ntp.keys.5: $(srcdir)/ntp.keys.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntp.keys.5+:$(srcdir)/ntp.keys.$(MANTAGFMT).in + mv ntp.keys.5+ ntp.keys.5 + +### + +$(srcdir)/invoke-ntpd.menu: $(srcdir)/invoke-ntpd.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpd.texi: $(srcdir)/ntpd-opts.def $(srcdir)/ntpdbase-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpd-opts.def + $(top_srcdir)/scripts/build/check--help $@ $(PROGRAMS): $(LDADD) -../libntp/libntp.a: - cd ../libntp && $(MAKE) libntp.a +compsave.conf: ntpd complete.conf + ./ntpd --configfile complete.conf --saveconfigquit $@ + +check-saveconfig: complete.conf compsave.conf + -diff -u complete.conf compsave.conf + cmp complete.conf compsave.conf && echo stamp > $@ ../libntp/libntpsim.a: - cd ../libntp && $(MAKE) libntpsim.a + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntpsim.a ../libparse/libparse.a: - cd ../libparse && $(MAKE) + cd ../libparse && $(MAKE) $(AM_MAKEFLAGS) check-libparse + +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +version.c: $(ntpd_OBJECTS) ../libntp/libntp.a @LIBPARSE@ Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpd -version.o: $(ntpd_OBJECTS) ../libntp/libntp.a @LIBPARSE@ Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpd - $(COMPILE) -c version.c +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o + +$(srcdir)/Makefile.am: + @: do-nothing install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ - || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ - test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ + done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ done # +check-libopts: ../sntp/libopts/libopts.la + @echo stamp > $@ + +../sntp/libopts/libopts.la: + -cd ../sntp/libopts && $(MAKE) $(AM_MAKEFLAGS) libopts.la + +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/contrib/ntp/ntpd/check_y2k.c b/contrib/ntp/ntpd/check_y2k.c index 6b8311502..12d1a592b 100644 --- a/contrib/ntp/ntpd/check_y2k.c +++ b/contrib/ntp/ntpd/check_y2k.c @@ -104,7 +104,6 @@ #define GoodLeap(Year) (((Year)%4 || (!((Year)%100) && (Year)%400)) ? 0 : 13 ) -volatile int debug = 0; /* debugging requests for parse stuff */ char const *progname = "check_y2k"; long diff --git a/contrib/ntp/ntpd/cmd_args.c b/contrib/ntp/ntpd/cmd_args.c index 7843bc317..14e86f7e8 100644 --- a/contrib/ntp/ntpd/cmd_args.c +++ b/contrib/ntp/ntpd/cmd_args.c @@ -7,23 +7,15 @@ #include "ntpd.h" #include "ntp_stdlib.h" +#include "ntp_config.h" #include "ntp_cmdargs.h" -#ifdef SIM -# include "ntpsim.h" -# include "ntpdsim-opts.h" -# define OPTSTRUCT ntpdsimOptions -#else -# include "ntpd-opts.h" -# define OPTSTRUCT ntpdOptions -#endif /* SIM */ +#include "ntpd-opts.h" /* * Definitions of things either imported from or exported to outside */ extern char const *progname; -extern const char *specific_interface; -extern short default_ai_family; #ifdef HAVE_NETINFO extern int check_netinfo; @@ -31,39 +23,41 @@ extern int check_netinfo; /* - * getCmdOpts - get command line options + * getCmdOpts - apply most command line options + * + * A few options are examined earlier in ntpd.c ntpdmain() and + * ports/winnt/ntpd/ntservice.c main(). */ void getCmdOpts( - int argc, - char *argv[] + int argc, + char ** argv ) { extern const char *config_file; int errflg; - tOptions *myOptions = &OPTSTRUCT; /* * Initialize, initialize */ errflg = 0; - switch (WHICH_IDX_IPV4) { - case INDEX_OPT_IPV4: - default_ai_family = AF_INET; - break; - case INDEX_OPT_IPV6: - default_ai_family = AF_INET6; - break; - default: - /* ai_fam_templ = ai_fam_default; */ - break; - } + if (ipv4_works && ipv6_works) { + if (HAVE_OPT( IPV4 )) + ipv6_works = 0; + else if (HAVE_OPT( IPV6 )) + ipv4_works = 0; + } else if (!ipv4_works && !ipv6_works) { + msyslog(LOG_ERR, "Neither IPv4 nor IPv6 networking detected, fatal."); + exit(1); + } else if (HAVE_OPT( IPV4 ) && !ipv4_works) + msyslog(LOG_WARNING, "-4/--ipv4 ignored, IPv4 networking not found."); + else if (HAVE_OPT( IPV6 ) && !ipv6_works) + msyslog(LOG_WARNING, "-6/--ipv6 ignored, IPv6 networking not found."); if (HAVE_OPT( AUTHREQ )) proto_config(PROTO_AUTHENTICATE, 1, 0., NULL); - - if (HAVE_OPT( AUTHNOREQ )) + else if (HAVE_OPT( AUTHNOREQ )) proto_config(PROTO_AUTHENTICATE, 0, 0., NULL); if (HAVE_OPT( BCASTSYNC )) @@ -82,24 +76,15 @@ getCmdOpts( if (HAVE_OPT( PANICGATE )) allow_panic = TRUE; - if (HAVE_OPT( JAILDIR )) { + if (HAVE_OPT( FORCE_STEP_ONCE )) + force_step_once = TRUE; + #ifdef HAVE_DROPROOT - droproot = 1; - chrootdir = OPT_ARG( JAILDIR ); -#else - fprintf(stderr, - "command line -i option (jaildir) is not supported by this binary" -# ifndef SYS_WINNT - ",\n" "can not drop root privileges. See configure options\n" - "--enable-clockctl and --enable-linuxcaps.\n"); -# else - ".\n"); -# endif - msyslog(LOG_ERR, - "command line -i option (jaildir) is not supported by this binary."); - errflg++; -#endif + if (HAVE_OPT( JAILDIR )) { + droproot = 1; + chrootdir = OPT_ARG( JAILDIR ); } +#endif if (HAVE_OPT( KEYFILE )) getauthkeys(OPT_ARG( KEYFILE )); @@ -146,40 +131,33 @@ getCmdOpts( } while (--ct > 0); } - if (HAVE_OPT( USER )) { #ifdef HAVE_DROPROOT - char *ntp_optarg = OPT_ARG( USER ); - + if (HAVE_OPT( USER )) { droproot = 1; - user = emalloc(strlen(ntp_optarg) + 1); - (void)strncpy(user, ntp_optarg, strlen(ntp_optarg) + 1); - group = rindex(user, ':'); - if (group) + user = estrdup(OPT_ARG( USER )); + group = strrchr(user, ':'); + if (group != NULL) { + size_t len; + *group++ = '\0'; /* get rid of the ':' */ -#else - fprintf(stderr, - "command line -u/--user option is not supported by this binary" -# ifndef SYS_WINNT - ",\n" "can not drop root privileges. See configure options\n" - "--enable-clockctl and --enable-linuxcaps.\n"); -# else - ".\n"); -# endif - msyslog(LOG_ERR, - "command line -u/--user option is not supported by this binary."); - errflg++; -#endif + len = group - user; + group = estrdup(group); + user = erealloc(user, len); + } } +#endif if (HAVE_OPT( VAR )) { - int ct = STACKCT_OPT( VAR ); - const char** pp = STACKLST_OPT( VAR ); + int ct; + const char ** pp; + const char * v_assign; - do { - const char* my_ntp_optarg = *pp++; + ct = STACKCT_OPT( VAR ); + pp = STACKLST_OPT( VAR ); - set_sys_var(my_ntp_optarg, strlen(my_ntp_optarg)+1, - (u_short) (RW)); + do { + v_assign = *pp++; + set_sys_var(v_assign, strlen(v_assign) + 1, RW); } while (--ct > 0); } @@ -196,57 +174,32 @@ getCmdOpts( } if (HAVE_OPT( SLEW )) - clock_max = 600; + loop_config(LOOP_MAX, 600); if (HAVE_OPT( UPDATEINTERVAL )) { long val = OPT_VALUE_UPDATEINTERVAL; - + if (val >= 0) interface_interval = val; else { - fprintf(stderr, + fprintf(stderr, "command line interface update interval %ld must not be negative\n", val); - msyslog(LOG_ERR, + msyslog(LOG_ERR, "command line interface update interval %ld must not be negative", val); errflg++; } } -#ifdef SIM - if (HAVE_OPT( SIMBROADCASTDELAY )) - sscanf(OPT_ARG( SIMBROADCASTDELAY ), "%lf", &ntp_node.bdly); - - if (HAVE_OPT( PHASENOISE )) - sscanf(OPT_ARG( PHASENOISE ), "%lf", &ntp_node.snse); - - if (HAVE_OPT( SIMSLEW )) - sscanf(OPT_ARG( SIMSLEW ), "%lf", &ntp_node.slew); - if (HAVE_OPT( SERVERTIME )) - sscanf(OPT_ARG( SERVERTIME ), "%lf", &ntp_node.clk_time); - if (HAVE_OPT( ENDSIMTIME )) - sscanf(OPT_ARG( ENDSIMTIME ), "%lf", &ntp_node.sim_time); - - if (HAVE_OPT( FREQERR )) - sscanf(OPT_ARG( FREQERR ), "%lf", &ntp_node.ferr); - - if (HAVE_OPT( WALKNOISE )) - sscanf(OPT_ARG( WALKNOISE ), "%lf", &ntp_node.fnse); - - if (HAVE_OPT( NDELAY )) - sscanf(OPT_ARG( NDELAY ), "%lf", &ntp_node.ndly); - - if (HAVE_OPT( PDELAY )) - sscanf(OPT_ARG( PDELAY ), "%lf", &ntp_node.pdly); - -#endif /* SIM */ - - if (errflg || argc) { - if (argc) - fprintf(stderr, "argc after processing is <%d>\n", argc); - optionUsage(myOptions, 2); + /* save list of servers from cmd line for config_peers() use */ + if (argc > 0) { + cmdline_server_count = argc; + cmdline_servers = argv; } - return; + + /* display usage & exit with any option processing errors */ + if (errflg) + optionUsage(&ntpdOptions, 2); /* does not return */ } diff --git a/contrib/ntp/ntpd/complete.conf.in b/contrib/ntp/ntpd/complete.conf.in new file mode 100644 index 000000000..747a48f2f --- /dev/null +++ b/contrib/ntp/ntpd/complete.conf.in @@ -0,0 +1,69 @@ +saveconfigdir "/etc/ntp/conf" +driftfile "/etc/ntp.drift" 1e-7 +logfile "/var/log/ntp.log" +leapfile "/etc/ntp.leapseconds" +@HAVE_LEAPSMEARINTERVAL@ +nonvolatile 1e-7 +ident "udent" +dscp 46 +logconfig =allall -allinfo -allevents -allstatistics -allstatus +allall -clockinfo -clockevents -clockstatistics -clockstatus +clockall -syncinfo -syncevents -syncstatistics -syncstatus +syncall -sysinfo -sysevents -sysstatistics -sysstatus +sysall +statsdir "/etc/ntp/stats" +statistics clockstats cryptostats loopstats peerstats protostats rawstats sysstats timingstats +filegen clockstats file clockstats type none enable +filegen cryptostats file cryptostats type pid link disable +filegen loopstats file loopstats type day nolink enable +filegen peerstats file peerstats type week enable +filegen protostats file stats type month enable +filegen rawstats file rawstats type year nolink enable +filegen sysstats file sysstats type age enable +filegen timingstats file timingstats type none disable +crypto digest md5 host myhostname ident wedent pw cryptopass randfile /.rnd +revoke 10 +keysdir "/etc/ntp/keys" +keys "/etc/ntp.keys" +trustedkey 1 2 3 4 5 6 7 8 9 10 11 12 (14 ... 16) 18 (32768 ... 65534) +controlkey 12 +requestkey 12 +enable auth ntp monitor stats +disable bclient calibrate kernel mode7 +tos beacon 3600 ceiling 16 cohort 0 floor 1 maxclock 10 maxdist 1.5 minclock 3 mindist 0.001 minsane 1 orphan 16 orphanwait 300 +rlimit@HAVE_RLIMIT_MEMLOCK@@HAVE_RLIMIT_STACK@ +tinker allan 1500 dispersion 15 freq 0 huffpuff 7200 panic 1000 step 0.128 stepout 900 tick 0.01 +broadcastclient +server 127.127.1.0 mode 4294967295 prefer true +fudge 127.127.1.0 time1 0 time2 1.1 stratum 7 refid Abcd +pool 0.north-america.pool.ntp.org. iburst preempt +server 1.north-america.pool.ntp.org. iburst +server -4 2.north-america.pool.ntp.org. minpoll 6 maxpoll 10 iburst +server -6 ntp.davehart.net. minpoll 6 maxpoll 10 version 5 burst iburst +peer -6 davehart.broker.freenet6.net. ident "autokey-group" xleave autokey +peer -4 192.168.192.168 key 1 noselect +server [fe80::123%1] +broadcast 192.168.192.255 +manycastclient 224.0.1.1 +manycastclient ff05::101 +manycastserver 224.0.1.1 ff05::101 +multicastclient 224.0.1.1 ff05::101 +mru maxage 64 mindepth 600 initalloc 600 initmem 16 incalloc 99 incmem 4 maxdepth 1024 maxmem 4096 +discard minimum 1 average 3 monitor 3000 +restrict default +restrict default nomodify limited kod noserve nomrulist +restrict source +restrict source nomodify limited kod +restrict trusted.host.name.example.com. nomodify +restrict [fe80::1] mask [ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff] +restrict 127.0.0.1 mask 255.255.255.255 +restrict ::1 +interface drop ipv6 +interface ignore ipv4 +interface drop wildcard +interface listen eth0 +interface listen ipv6 +interface listen 192.168.192.0/24 +interface listen 192.168.193.1 +phone "ATDT13034944774" "ATDT12027621594" +setvar varnondef = "this variable does not have default after the value" +setvar vanity = "name plate" default +trap 127.0.0.1 interface 127.0.0.1 port 1234 +trap 127.0.0.2 +reset allpeers auth ctl io mem sys timer diff --git a/contrib/ntp/ntpd/declcond.h b/contrib/ntp/ntpd/declcond.h new file mode 100644 index 000000000..870e5a729 --- /dev/null +++ b/contrib/ntp/ntpd/declcond.h @@ -0,0 +1,21 @@ +/* + * declcond.h - declarations conditionalized for ntpd + * + * The NTP reference implementation distribution includes two distinct + * declcond.h files, one in ntpd/ used only by ntpd, and another in + * include/ used by libntp and utilities. This relies on the source + * file's directory being ahead of include/ in the include search. + * + * The ntpd variant of declcond.h declares "debug" only #ifdef DEBUG, + * as the --disable-debugging version of ntpd should not reference + * "debug". The libntp and utilities variant always declares debug, + * as it is used in those codebases even without DEBUG defined. + */ +#ifndef DECLCOND_H +#define DECLCOND_H + +#ifdef DEBUG /* uncommented in ntpd/declcond.h */ +extern int debug; +#endif /* uncommented in ntpd/declcond.h */ + +#endif /* DECLCOND_H */ diff --git a/contrib/ntp/ntpd/invoke-ntp.conf.menu b/contrib/ntp/ntpd/invoke-ntp.conf.menu new file mode 100644 index 000000000..e5c6ef353 --- /dev/null +++ b/contrib/ntp/ntpd/invoke-ntp.conf.menu @@ -0,0 +1 @@ +* ntp.conf Notes:: Notes about ntp.conf diff --git a/contrib/ntp/ntpd/invoke-ntp.conf.texi b/contrib/ntp/ntpd/invoke-ntp.conf.texi new file mode 100644 index 000000000..37427d679 --- /dev/null +++ b/contrib/ntp/ntpd/invoke-ntp.conf.texi @@ -0,0 +1,2680 @@ +@node ntp.conf Notes +@section Notes about ntp.conf +@pindex ntp.conf +@cindex Network Time Protocol (NTP) daemon configuration file format +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntp.conf.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:38:16 PM by AutoGen 5.18.5 +# From the definitions ntp.conf.def +# and the template file agtexi-file.tpl +@end ignore + + + +The +@code{ntp.conf} +configuration file is read at initial startup by the +@code{ntpd(1ntpdmdoc)} +daemon in order to specify the synchronization sources, +modes and other related information. +Usually, it is installed in the +@file{/etc} +directory, +but could be installed elsewhere +(see the daemon's +@code{-c} +command line option). + +The file format is similar to other +@sc{unix} +configuration files. +Comments begin with a +@quoteleft{}#@quoteright{} +character and extend to the end of the line; +blank lines are ignored. +Configuration commands consist of an initial keyword +followed by a list of arguments, +some of which may be optional, separated by whitespace. +Commands may not be continued over multiple lines. +Arguments may be host names, +host addresses written in numeric, dotted-quad form, +integers, floating point numbers (when specifying times in seconds) +and text strings. + +The rest of this page describes the configuration and control options. +The +"Notes on Configuring NTP and Setting up an NTP Subnet" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}) +contains an extended discussion of these options. +In addition to the discussion of general +@ref{Configuration Options}, +there are sections describing the following supported functionality +and the options used to control it: +@itemize @bullet +@item +@ref{Authentication Support} +@item +@ref{Monitoring Support} +@item +@ref{Access Control Support} +@item +@ref{Automatic NTP Configuration Options} +@item +@ref{Reference Clock Support} +@item +@ref{Miscellaneous Options} +@end itemize + +Following these is a section describing +@ref{Miscellaneous Options}. +While there is a rich set of options available, +the only required option is one or more +@code{pool}, +@code{server}, +@code{peer}, +@code{broadcast} +or +@code{manycastclient} +commands. +@node Configuration Support +@subsection Configuration Support +Following is a description of the configuration commands in +NTPv4. +These commands have the same basic functions as in NTPv3 and +in some cases new functions and new arguments. +There are two +classes of commands, configuration commands that configure a +persistent association with a remote server or peer or reference +clock, and auxiliary commands that specify environmental variables +that control various related operations. +@subsubsection Configuration Commands +The various modes are determined by the command keyword and the +type of the required IP address. +Addresses are classed by type as +(s) a remote server or peer (IPv4 class A, B and C), (b) the +broadcast address of a local interface, (m) a multicast address (IPv4 +class D), or (r) a reference clock address (127.127.x.x). +Note that +only those options applicable to each command are listed below. +Use +of options not listed may not be caught as an error, but may result +in some weird and even destructive behavior. + +If the Basic Socket Interface Extensions for IPv6 (RFC-2553) +is detected, support for the IPv6 address family is generated +in addition to the default support of the IPv4 address family. +In a few cases, including the reslist billboard generated +by ntpdc, IPv6 addresses are automatically generated. +IPv6 addresses can be identified by the presence of colons +@quotedblleft{}:@quotedblright{} +in the address field. +IPv6 addresses can be used almost everywhere where +IPv4 addresses can be used, +with the exception of reference clock addresses, +which are always IPv4. + +Note that in contexts where a host name is expected, a +@code{-4} +qualifier preceding +the host name forces DNS resolution to the IPv4 namespace, +while a +@code{-6} +qualifier forces DNS resolution to the IPv6 namespace. +See IPv6 references for the +equivalent classes for that address family. +@table @asis +@item @code{pool} @kbd{address} @code{[@code{burst}]} @code{[@code{iburst}]} @code{[@code{version} @kbd{version}]} @code{[@code{prefer}]} @code{[@code{minpoll} @kbd{minpoll}]} @code{[@code{maxpoll} @kbd{maxpoll}]} +@item @code{server} @kbd{address} @code{[@code{key} @kbd{key} @kbd{|} @code{autokey}]} @code{[@code{burst}]} @code{[@code{iburst}]} @code{[@code{version} @kbd{version}]} @code{[@code{prefer}]} @code{[@code{minpoll} @kbd{minpoll}]} @code{[@code{maxpoll} @kbd{maxpoll}]} +@item @code{peer} @kbd{address} @code{[@code{key} @kbd{key} @kbd{|} @code{autokey}]} @code{[@code{version} @kbd{version}]} @code{[@code{prefer}]} @code{[@code{minpoll} @kbd{minpoll}]} @code{[@code{maxpoll} @kbd{maxpoll}]} +@item @code{broadcast} @kbd{address} @code{[@code{key} @kbd{key} @kbd{|} @code{autokey}]} @code{[@code{version} @kbd{version}]} @code{[@code{prefer}]} @code{[@code{minpoll} @kbd{minpoll}]} @code{[@code{ttl} @kbd{ttl}]} +@item @code{manycastclient} @kbd{address} @code{[@code{key} @kbd{key} @kbd{|} @code{autokey}]} @code{[@code{version} @kbd{version}]} @code{[@code{prefer}]} @code{[@code{minpoll} @kbd{minpoll}]} @code{[@code{maxpoll} @kbd{maxpoll}]} @code{[@code{ttl} @kbd{ttl}]} +@end table + +These five commands specify the time server name or address to +be used and the mode in which to operate. +The +@kbd{address} +can be +either a DNS name or an IP address in dotted-quad notation. +Additional information on association behavior can be found in the +"Association Management" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). +@table @asis +@item @code{pool} +For type s addresses, this command mobilizes a persistent +client mode association with a number of remote servers. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +@item @code{server} +For type s and r addresses, this command mobilizes a persistent +client mode association with the specified remote server or local +radio clock. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +This command should +@emph{not} +be used for type +b or m addresses. +@item @code{peer} +For type s addresses (only), this command mobilizes a +persistent symmetric-active mode association with the specified +remote peer. +In this mode the local clock can be synchronized to +the remote peer or the remote peer can be synchronized to the local +clock. +This is useful in a network of servers where, depending on +various failure scenarios, either the local or remote peer may be +the better source of time. +This command should NOT be used for type +b, m or r addresses. +@item @code{broadcast} +For type b and m addresses (only), this +command mobilizes a persistent broadcast mode association. +Multiple +commands can be used to specify multiple local broadcast interfaces +(subnets) and/or multiple multicast groups. +Note that local +broadcast messages go only to the interface associated with the +subnet specified, but multicast messages go to all interfaces. +In broadcast mode the local server sends periodic broadcast +messages to a client population at the +@kbd{address} +specified, which is usually the broadcast address on (one of) the +local network(s) or a multicast address assigned to NTP. +The IANA +has assigned the multicast group address IPv4 224.0.1.1 and +IPv6 ff05::101 (site local) exclusively to +NTP, but other nonconflicting addresses can be used to contain the +messages within administrative boundaries. +Ordinarily, this +specification applies only to the local server operating as a +sender; for operation as a broadcast client, see the +@code{broadcastclient} +or +@code{multicastclient} +commands +below. +@item @code{manycastclient} +For type m addresses (only), this command mobilizes a +manycast client mode association for the multicast address +specified. +In this case a specific address must be supplied which +matches the address used on the +@code{manycastserver} +command for +the designated manycast servers. +The NTP multicast address +224.0.1.1 assigned by the IANA should NOT be used, unless specific +means are taken to avoid spraying large areas of the Internet with +these messages and causing a possibly massive implosion of replies +at the sender. +The +@code{manycastserver} +command specifies that the local server +is to operate in client mode with the remote servers that are +discovered as the result of broadcast/multicast messages. +The +client broadcasts a request message to the group address associated +with the specified +@kbd{address} +and specifically enabled +servers respond to these messages. +The client selects the servers +providing the best time and continues as with the +@code{server} +command. +The remaining servers are discarded as if never +heard. +@end table + +Options: +@table @asis +@item @code{autokey} +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the autokey scheme +described in +@ref{Authentication Options}. +@item @code{burst} +when the server is reachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first and second packets +can be changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to improve timekeeping quality +with the +@code{server} +command and s addresses. +@item @code{iburst} +When the server is unreachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first two packets can be +changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to speed the initial synchronization +acquisition with the +@code{server} +command and s addresses and when +@code{ntpd(1ntpdmdoc)} +is started with the +@code{-q} +option. +@item @code{key} @kbd{key} +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the specified +@kbd{key} +identifier with values from 1 to 65534, inclusive. +The +default is to include no encryption field. +@item @code{minpoll} @kbd{minpoll} +@item @code{maxpoll} @kbd{maxpoll} +These options specify the minimum and maximum poll intervals +for NTP messages, as a power of 2 in seconds +The maximum poll +interval defaults to 10 (1,024 s), but can be increased by the +@code{maxpoll} +option to an upper limit of 17 (36.4 h). +The +minimum poll interval defaults to 6 (64 s), but can be decreased by +the +@code{minpoll} +option to a lower limit of 4 (16 s). +@item @code{noselect} +Marks the server as unused, except for display purposes. +The server is discarded by the selection algroithm. +@item @code{prefer} +Marks the server as preferred. +All other things being equal, +this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}) +for further information. +@item @code{ttl} @kbd{ttl} +This option is used only with broadcast server and manycast +client modes. +It specifies the time-to-live +@kbd{ttl} +to +use on broadcast server and multicast server and the maximum +@kbd{ttl} +for the expanding ring search with manycast +client packets. +Selection of the proper value, which defaults to +127, is something of a black art and should be coordinated with the +network administrator. +@item @code{version} @kbd{version} +Specifies the version number to be used for outgoing NTP +packets. +Versions 1-4 are the choices, with version 4 the +default. +@end table +@subsubsection Auxiliary Commands +@table @asis +@item @code{broadcastclient} +This command enables reception of broadcast server messages to +any local interface (type b) address. +Upon receiving a message for +the first time, the broadcast client measures the nominal server +propagation delay using a brief client/server exchange with the +server, then enters the broadcast client mode, in which it +synchronizes to succeeding broadcast messages. +Note that, in order +to avoid accidental or malicious disruption in this mode, both the +server and client should operate using symmetric-key or public-key +authentication as described in +@ref{Authentication Options}. +@item @code{manycastserver} @kbd{address} @kbd{...} +This command enables reception of manycast client messages to +the multicast group address(es) (type m) specified. +At least one +address is required, but the NTP multicast address 224.0.1.1 +assigned by the IANA should NOT be used, unless specific means are +taken to limit the span of the reply and avoid a possibly massive +implosion at the original sender. +Note that, in order to avoid +accidental or malicious disruption in this mode, both the server +and client should operate using symmetric-key or public-key +authentication as described in +@ref{Authentication Options}. +@item @code{multicastclient} @kbd{address} @kbd{...} +This command enables reception of multicast server messages to +the multicast group address(es) (type m) specified. +Upon receiving +a message for the first time, the multicast client measures the +nominal server propagation delay using a brief client/server +exchange with the server, then enters the broadcast client mode, in +which it synchronizes to succeeding multicast messages. +Note that, +in order to avoid accidental or malicious disruption in this mode, +both the server and client should operate using symmetric-key or +public-key authentication as described in +@ref{Authentication Options}. +@item @code{mdnstries} @kbd{number} +If we are participating in mDNS, +after we have synched for the first time +we attempt to register with the mDNS system. +If that registration attempt fails, +we try again at one minute intervals for up to +@code{mdnstries} +times. +After all, +@code{ntpd} +may be starting before mDNS. +The default value for +@code{mdnstries} +is 5. +@end table +@node Authentication Support +@subsection Authentication Support +Authentication support allows the NTP client to verify that the +server is in fact known and trusted and not an intruder intending +accidentally or on purpose to masquerade as that server. +The NTPv3 +specification RFC-1305 defines a scheme which provides +cryptographic authentication of received NTP packets. +Originally, +this was done using the Data Encryption Standard (DES) algorithm +operating in Cipher Block Chaining (CBC) mode, commonly called +DES-CBC. +Subsequently, this was replaced by the RSA Message Digest +5 (MD5) algorithm using a private key, commonly called keyed-MD5. +Either algorithm computes a message digest, or one-way hash, which +can be used to verify the server has the correct private key and +key identifier. + +NTPv4 retains the NTPv3 scheme, properly described as symmetric key +cryptography and, in addition, provides a new Autokey scheme +based on public key cryptography. +Public key cryptography is generally considered more secure +than symmetric key cryptography, since the security is based +on a private value which is generated by each server and +never revealed. +With Autokey all key distribution and +management functions involve only public values, which +considerably simplifies key distribution and storage. +Public key management is based on X.509 certificates, +which can be provided by commercial services or +produced by utility programs in the OpenSSL software library +or the NTPv4 distribution. + +While the algorithms for symmetric key cryptography are +included in the NTPv4 distribution, public key cryptography +requires the OpenSSL software library to be installed +before building the NTP distribution. +Directions for doing that +are on the Building and Installing the Distribution page. + +Authentication is configured separately for each association +using the +@code{key} +or +@code{autokey} +subcommand on the +@code{peer}, +@code{server}, +@code{broadcast} +and +@code{manycastclient} +configuration commands as described in +@ref{Configuration Options} +page. +The authentication +options described below specify the locations of the key files, +if other than default, which symmetric keys are trusted +and the interval between various operations, if other than default. + +Authentication is always enabled, +although ineffective if not configured as +described below. +If a NTP packet arrives +including a message authentication +code (MAC), it is accepted only if it +passes all cryptographic checks. +The +checks require correct key ID, key value +and message digest. +If the packet has +been modified in any way or replayed +by an intruder, it will fail one or more +of these checks and be discarded. +Furthermore, the Autokey scheme requires a +preliminary protocol exchange to obtain +the server certificate, verify its +credentials and initialize the protocol + +The +@code{auth} +flag controls whether new associations or +remote configuration commands require cryptographic authentication. +This flag can be set or reset by the +@code{enable} +and +@code{disable} +commands and also by remote +configuration commands sent by a +@code{ntpdc(1ntpdcmdoc)} +program running in +another machine. +If this flag is enabled, which is the default +case, new broadcast client and symmetric passive associations and +remote configuration commands must be cryptographically +authenticated using either symmetric key or public key cryptography. +If this +flag is disabled, these operations are effective +even if not cryptographic +authenticated. +It should be understood +that operating with the +@code{auth} +flag disabled invites a significant vulnerability +where a rogue hacker can +masquerade as a falseticker and seriously +disrupt system timekeeping. +It is +important to note that this flag has no purpose +other than to allow or disallow +a new association in response to new broadcast +and symmetric active messages +and remote configuration commands and, in particular, +the flag has no effect on +the authentication process itself. + +An attractive alternative where multicast support is available +is manycast mode, in which clients periodically troll +for servers as described in the +@ref{Automatic NTP Configuration Options} +page. +Either symmetric key or public key +cryptographic authentication can be used in this mode. +The principle advantage +of manycast mode is that potential servers need not be +configured in advance, +since the client finds them during regular operation, +and the configuration +files for all clients can be identical. + +The security model and protocol schemes for +both symmetric key and public key +cryptography are summarized below; +further details are in the briefings, papers +and reports at the NTP project page linked from +@code{http://www.ntp.org/}. +@subsubsection Symmetric-Key Cryptography +The original RFC-1305 specification allows any one of possibly +65,534 keys, each distinguished by a 32-bit key identifier, to +authenticate an association. +The servers and clients involved must +agree on the key and key identifier to +authenticate NTP packets. +Keys and +related information are specified in a key +file, usually called +@file{ntp.keys}, +which must be distributed and stored using +secure means beyond the scope of the NTP protocol itself. +Besides the keys used +for ordinary NTP associations, +additional keys can be used as passwords for the +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +utility programs. + +When +@code{ntpd(1ntpdmdoc)} +is first started, it reads the key file specified in the +@code{keys} +configuration command and installs the keys +in the key cache. +However, +individual keys must be activated with the +@code{trusted} +command before use. +This +allows, for instance, the installation of possibly +several batches of keys and +then activating or deactivating each batch +remotely using +@code{ntpdc(1ntpdcmdoc)}. +This also provides a revocation capability that can be used +if a key becomes compromised. +The +@code{requestkey} +command selects the key used as the password for the +@code{ntpdc(1ntpdcmdoc)} +utility, while the +@code{controlkey} +command selects the key used as the password for the +@code{ntpq(1ntpqmdoc)} +utility. +@subsubsection Public Key Cryptography +NTPv4 supports the original NTPv3 symmetric key scheme +described in RFC-1305 and in addition the Autokey protocol, +which is based on public key cryptography. +The Autokey Version 2 protocol described on the Autokey Protocol +page verifies packet integrity using MD5 message digests +and verifies the source with digital signatures and any of several +digest/signature schemes. +Optional identity schemes described on the Identity Schemes +page and based on cryptographic challenge/response algorithms +are also available. +Using all of these schemes provides strong security against +replay with or without modification, spoofing, masquerade +and most forms of clogging attacks. + +The Autokey protocol has several modes of operation +corresponding to the various NTP modes supported. +Most modes use a special cookie which can be +computed independently by the client and server, +but encrypted in transmission. +All modes use in addition a variant of the S-KEY scheme, +in which a pseudo-random key list is generated and used +in reverse order. +These schemes are described along with an executive summary, +current status, briefing slides and reading list on the +@ref{Autonomous Authentication} +page. + +The specific cryptographic environment used by Autokey servers +and clients is determined by a set of files +and soft links generated by the +@code{ntp-keygen(1ntpkeygenmdoc)} +program. +This includes a required host key file, +required certificate file and optional sign key file, +leapsecond file and identity scheme files. +The +digest/signature scheme is specified in the X.509 certificate +along with the matching sign key. +There are several schemes +available in the OpenSSL software library, each identified +by a specific string such as +@code{md5WithRSAEncryption}, +which stands for the MD5 message digest with RSA +encryption scheme. +The current NTP distribution supports +all the schemes in the OpenSSL library, including +those based on RSA and DSA digital signatures. + +NTP secure groups can be used to define cryptographic compartments +and security hierarchies. +It is important that every host +in the group be able to construct a certificate trail to one +or more trusted hosts in the same group. +Each group +host runs the Autokey protocol to obtain the certificates +for all hosts along the trail to one or more trusted hosts. +This requires the configuration file in all hosts to be +engineered so that, even under anticipated failure conditions, +the NTP subnet will form such that every group host can find +a trail to at least one trusted host. +@subsubsection Naming and Addressing +It is important to note that Autokey does not use DNS to +resolve addresses, since DNS can't be completely trusted +until the name servers have synchronized clocks. +The cryptographic name used by Autokey to bind the host identity +credentials and cryptographic values must be independent +of interface, network and any other naming convention. +The name appears in the host certificate in either or both +the subject and issuer fields, so protection against +DNS compromise is essential. + +By convention, the name of an Autokey host is the name returned +by the Unix +@code{gethostname(2)} +system call or equivalent in other systems. +By the system design +model, there are no provisions to allow alternate names or aliases. +However, this is not to say that DNS aliases, different names +for each interface, etc., are constrained in any way. + +It is also important to note that Autokey verifies authenticity +using the host name, network address and public keys, +all of which are bound together by the protocol specifically +to deflect masquerade attacks. +For this reason Autokey +includes the source and destinatino IP addresses in message digest +computations and so the same addresses must be available +at both the server and client. +For this reason operation +with network address translation schemes is not possible. +This reflects the intended robust security model where government +and corporate NTP servers are operated outside firewall perimeters. +@subsubsection Operation +A specific combination of authentication scheme (none, +symmetric key, public key) and identity scheme is called +a cryptotype, although not all combinations are compatible. +There may be management configurations where the clients, +servers and peers may not all support the same cryptotypes. +A secure NTPv4 subnet can be configured in many ways while +keeping in mind the principles explained above and +in this section. +Note however that some cryptotype +combinations may successfully interoperate with each other, +but may not represent good security practice. + +The cryptotype of an association is determined at the time +of mobilization, either at configuration time or some time +later when a message of appropriate cryptotype arrives. +When mobilized by a +@code{server} +or +@code{peer} +configuration command and no +@code{key} +or +@code{autokey} +subcommands are present, the association is not +authenticated; if the +@code{key} +subcommand is present, the association is authenticated +using the symmetric key ID specified; if the +@code{autokey} +subcommand is present, the association is authenticated +using Autokey. + +When multiple identity schemes are supported in the Autokey +protocol, the first message exchange determines which one is used. +The client request message contains bits corresponding +to which schemes it has available. +The server response message +contains bits corresponding to which schemes it has available. +Both server and client match the received bits with their own +and select a common scheme. + +Following the principle that time is a public value, +a server responds to any client packet that matches +its cryptotype capabilities. +Thus, a server receiving +an unauthenticated packet will respond with an unauthenticated +packet, while the same server receiving a packet of a cryptotype +it supports will respond with packets of that cryptotype. +However, unconfigured broadcast or manycast client +associations or symmetric passive associations will not be +mobilized unless the server supports a cryptotype compatible +with the first packet received. +By default, unauthenticated associations will not be mobilized +unless overridden in a decidedly dangerous way. + +Some examples may help to reduce confusion. +Client Alice has no specific cryptotype selected. +Server Bob has both a symmetric key file and minimal Autokey files. +Alice's unauthenticated messages arrive at Bob, who replies with +unauthenticated messages. +Cathy has a copy of Bob's symmetric +key file and has selected key ID 4 in messages to Bob. +Bob verifies the message with his key ID 4. +If it's the +same key and the message is verified, Bob sends Cathy a reply +authenticated with that key. +If verification fails, +Bob sends Cathy a thing called a crypto-NAK, which tells her +something broke. +She can see the evidence using the +@code{ntpq(1ntpqmdoc)} +program. + +Denise has rolled her own host key and certificate. +She also uses one of the identity schemes as Bob. +She sends the first Autokey message to Bob and they +both dance the protocol authentication and identity steps. +If all comes out okay, Denise and Bob continue as described above. + +It should be clear from the above that Bob can support +all the girls at the same time, as long as he has compatible +authentication and identity credentials. +Now, Bob can act just like the girls in his own choice of servers; +he can run multiple configured associations with multiple different +servers (or the same server, although that might not be useful). +But, wise security policy might preclude some cryptotype +combinations; for instance, running an identity scheme +with one server and no authentication with another might not be wise. +@subsubsection Key Management +The cryptographic values used by the Autokey protocol are +incorporated as a set of files generated by the +@code{ntp-keygen(1ntpkeygenmdoc)} +utility program, including symmetric key, host key and +public certificate files, as well as sign key, identity parameters +and leapseconds files. +Alternatively, host and sign keys and +certificate files can be generated by the OpenSSL utilities +and certificates can be imported from public certificate +authorities. +Note that symmetric keys are necessary for the +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +utility programs. +The remaining files are necessary only for the +Autokey protocol. + +Certificates imported from OpenSSL or public certificate +authorities have certian limitations. +The certificate should be in ASN.1 syntax, X.509 Version 3 +format and encoded in PEM, which is the same format +used by OpenSSL. +The overall length of the certificate encoded +in ASN.1 must not exceed 1024 bytes. +The subject distinguished +name field (CN) is the fully qualified name of the host +on which it is used; the remaining subject fields are ignored. +The certificate extension fields must not contain either +a subject key identifier or a issuer key identifier field; +however, an extended key usage field for a trusted host must +contain the value +@code{trustRoot};. +Other extension fields are ignored. +@subsubsection Authentication Commands +@table @asis +@item @code{autokey} @code{[@kbd{logsec}]} +Specifies the interval between regenerations of the session key +list used with the Autokey protocol. +Note that the size of the key +list for each association depends on this interval and the current +poll interval. +The default value is 12 (4096 s or about 1.1 hours). +For poll intervals above the specified interval, a session key list +with a single entry will be regenerated for every message +sent. +@item @code{controlkey} @kbd{key} +Specifies the key identifier to use with the +@code{ntpq(1ntpqmdoc)} +utility, which uses the standard +protocol defined in RFC-1305. +The +@kbd{key} +argument is +the key identifier for a trusted key, where the value can be in the +range 1 to 65,534, inclusive. +@item @code{crypto} @code{[@code{cert} @kbd{file}]} @code{[@code{leap} @kbd{file}]} @code{[@code{randfile} @kbd{file}]} @code{[@code{host} @kbd{file}]} @code{[@code{sign} @kbd{file}]} @code{[@code{gq} @kbd{file}]} @code{[@code{gqpar} @kbd{file}]} @code{[@code{iffpar} @kbd{file}]} @code{[@code{mvpar} @kbd{file}]} @code{[@code{pw} @kbd{password}]} +This command requires the OpenSSL library. +It activates public key +cryptography, selects the message digest and signature +encryption scheme and loads the required private and public +values described above. +If one or more files are left unspecified, +the default names are used as described above. +Unless the complete path and name of the file are specified, the +location of a file is relative to the keys directory specified +in the +@code{keysdir} +command or default +@file{/usr/local/etc}. +Following are the subcommands: +@table @asis +@item @code{cert} @kbd{file} +Specifies the location of the required host public certificate file. +This overrides the link +@file{ntpkey_cert_}@kbd{hostname} +in the keys directory. +@item @code{gqpar} @kbd{file} +Specifies the location of the optional GQ parameters file. +This +overrides the link +@file{ntpkey_gq_}@kbd{hostname} +in the keys directory. +@item @code{host} @kbd{file} +Specifies the location of the required host key file. +This overrides +the link +@file{ntpkey_key_}@kbd{hostname} +in the keys directory. +@item @code{iffpar} @kbd{file} +Specifies the location of the optional IFF parameters file.This +overrides the link +@file{ntpkey_iff_}@kbd{hostname} +in the keys directory. +@item @code{leap} @kbd{file} +Specifies the location of the optional leapsecond file. +This overrides the link +@file{ntpkey_leap} +in the keys directory. +@item @code{mvpar} @kbd{file} +Specifies the location of the optional MV parameters file. +This +overrides the link +@file{ntpkey_mv_}@kbd{hostname} +in the keys directory. +@item @code{pw} @kbd{password} +Specifies the password to decrypt files containing private keys and +identity parameters. +This is required only if these files have been +encrypted. +@item @code{randfile} @kbd{file} +Specifies the location of the random seed file used by the OpenSSL +library. +The defaults are described in the main text above. +@item @code{sign} @kbd{file} +Specifies the location of the optional sign key file. +This overrides +the link +@file{ntpkey_sign_}@kbd{hostname} +in the keys directory. +If this file is +not found, the host key is also the sign key. +@end table +@item @code{keys} @kbd{keyfile} +Specifies the complete path and location of the MD5 key file +containing the keys and key identifiers used by +@code{ntpd(1ntpdmdoc)}, +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +when operating with symmetric key cryptography. +This is the same operation as the +@code{-k} +command line option. +@item @code{keysdir} @kbd{path} +This command specifies the default directory path for +cryptographic keys, parameters and certificates. +The default is +@file{/usr/local/etc/}. +@item @code{requestkey} @kbd{key} +Specifies the key identifier to use with the +@code{ntpdc(1ntpdcmdoc)} +utility program, which uses a +proprietary protocol specific to this implementation of +@code{ntpd(1ntpdmdoc)}. +The +@kbd{key} +argument is a key identifier +for the trusted key, where the value can be in the range 1 to +65,534, inclusive. +@item @code{revoke} @kbd{logsec} +Specifies the interval between re-randomization of certain +cryptographic values used by the Autokey scheme, as a power of 2 in +seconds. +These values need to be updated frequently in order to +deflect brute-force attacks on the algorithms of the scheme; +however, updating some values is a relatively expensive operation. +The default interval is 16 (65,536 s or about 18 hours). +For poll +intervals above the specified interval, the values will be updated +for every message sent. +@item @code{trustedkey} @kbd{key} @kbd{...} +Specifies the key identifiers which are trusted for the +purposes of authenticating peers with symmetric key cryptography, +as well as keys used by the +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +programs. +The authentication procedures require that both the local +and remote servers share the same key and key identifier for this +purpose, although different keys can be used with different +servers. +The +@kbd{key} +arguments are 32-bit unsigned +integers with values from 1 to 65,534. +@end table +@subsubsection Error Codes +The following error codes are reported via the NTP control +and monitoring protocol trap mechanism. +@table @asis +@item 101 +(bad field format or length) +The packet has invalid version, length or format. +@item 102 +(bad timestamp) +The packet timestamp is the same or older than the most recent received. +This could be due to a replay or a server clock time step. +@item 103 +(bad filestamp) +The packet filestamp is the same or older than the most recent received. +This could be due to a replay or a key file generation error. +@item 104 +(bad or missing public key) +The public key is missing, has incorrect format or is an unsupported type. +@item 105 +(unsupported digest type) +The server requires an unsupported digest/signature scheme. +@item 106 +(mismatched digest types) +Not used. +@item 107 +(bad signature length) +The signature length does not match the current public key. +@item 108 +(signature not verified) +The message fails the signature check. +It could be bogus or signed by a +different private key. +@item 109 +(certificate not verified) +The certificate is invalid or signed with the wrong key. +@item 110 +(certificate not verified) +The certificate is not yet valid or has expired or the signature could not +be verified. +@item 111 +(bad or missing cookie) +The cookie is missing, corrupted or bogus. +@item 112 +(bad or missing leapseconds table) +The leapseconds table is missing, corrupted or bogus. +@item 113 +(bad or missing certificate) +The certificate is missing, corrupted or bogus. +@item 114 +(bad or missing identity) +The identity key is missing, corrupt or bogus. +@end table +@node Monitoring Support +@subsection Monitoring Support +@code{ntpd(1ntpdmdoc)} +includes a comprehensive monitoring facility suitable +for continuous, long term recording of server and client +timekeeping performance. +See the +@code{statistics} +command below +for a listing and example of each type of statistics currently +supported. +Statistic files are managed using file generation sets +and scripts in the +@file{./scripts} +directory of this distribution. +Using +these facilities and +@sc{unix} +@code{cron(8)} +jobs, the data can be +automatically summarized and archived for retrospective analysis. +@subsubsection Monitoring Commands +@table @asis +@item @code{statistics} @kbd{name} @kbd{...} +Enables writing of statistics records. +Currently, eight kinds of +@kbd{name} +statistics are supported. +@table @asis +@item @code{clockstats} +Enables recording of clock driver statistics information. +Each update +received from a clock driver appends a line of the following form to +the file generation set named +@code{clockstats}: +@verbatim +49213 525.624 127.127.4.1 93 226 00:08:29.606 D +@end verbatim + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the +clock address in dotted-quad notation. +The final field shows the last +timecode received from the clock in decoded ASCII format, where +meaningful. +In some clock drivers a good deal of additional information +can be gathered and displayed as well. +See information specific to each +clock for further details. +@item @code{cryptostats} +This option requires the OpenSSL cryptographic software library. +It +enables recording of cryptographic public key protocol information. +Each message received by the protocol module appends a line of the +following form to the file generation set named +@code{cryptostats}: +@verbatim +49213 525.624 127.127.4.1 message +@end verbatim + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the peer +address in dotted-quad notation, The final message field includes the +message type and certain ancillary information. +See the +@ref{Authentication Options} +section for further information. +@item @code{loopstats} +Enables recording of loop filter statistics information. +Each +update of the local clock outputs a line of the following form to +the file generation set named +@code{loopstats}: +@verbatim +50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 +@end verbatim + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next five fields +show time offset (seconds), frequency offset (parts per million - +PPM), RMS jitter (seconds), Allan deviation (PPM) and clock +discipline time constant. +@item @code{peerstats} +Enables recording of peer statistics information. +This includes +statistics records of all peers of a NTP server and of special +signals, where present and configured. +Each valid update appends a +line of the following form to the current element of a file +generation set named +@code{peerstats}: +@verbatim +48773 10847.650 127.127.4.1 9714 -0.001605376 0.000000000 0.001424877 0.000958674 +@end verbatim + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the peer address in dotted-quad notation and status, +respectively. +The status field is encoded in hex in the format +described in Appendix A of the NTP specification RFC 1305. +The final four fields show the offset, +delay, dispersion and RMS jitter, all in seconds. +@item @code{rawstats} +Enables recording of raw-timestamp statistics information. +This +includes statistics records of all peers of a NTP server and of +special signals, where present and configured. +Each NTP message +received from a peer or clock driver appends a line of the +following form to the file generation set named +@code{rawstats}: +@verbatim +50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 +@end verbatim + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the remote peer or clock address followed by the local address +in dotted-quad notation. +The final four fields show the originate, +receive, transmit and final NTP timestamps in order. +The timestamp +values are as received and before processing by the various data +smoothing and mitigation algorithms. +@item @code{sysstats} +Enables recording of ntpd statistics counters on a periodic basis. +Each +hour a line of the following form is appended to the file generation +set named +@code{sysstats}: +@verbatim +50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 +@end verbatim + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The remaining ten fields show +the statistics counter values accumulated since the last generated +line. +@table @asis +@item Time since restart @code{36000} +Time in hours since the system was last rebooted. +@item Packets received @code{81965} +Total number of packets received. +@item Packets processed @code{0} +Number of packets received in response to previous packets sent +@item Current version @code{9546} +Number of packets matching the current NTP version. +@item Previous version @code{56} +Number of packets matching the previous NTP version. +@item Bad version @code{71793} +Number of packets matching neither NTP version. +@item Access denied @code{512} +Number of packets denied access for any reason. +@item Bad length or format @code{540} +Number of packets with invalid length, format or port number. +@item Bad authentication @code{10} +Number of packets not verified as authentic. +@item Rate exceeded @code{147} +Number of packets discarded due to rate limitation. +@end table +@item @code{statsdir} @kbd{directory_path} +Indicates the full path of a directory where statistics files +should be created (see below). +This keyword allows +the (otherwise constant) +@code{filegen} +filename prefix to be modified for file generation sets, which +is useful for handling statistics logs. +@item @code{filegen} @kbd{name} @code{[@code{file} @kbd{filename}]} @code{[@code{type} @kbd{typename}]} @code{[@code{link} | @code{nolink}]} @code{[@code{enable} | @code{disable}]} +Configures setting of generation file set name. +Generation +file sets provide a means for handling files that are +continuously growing during the lifetime of a server. +Server statistics are a typical example for such files. +Generation file sets provide access to a set of files used +to store the actual data. +At any time at most one element +of the set is being written to. +The type given specifies +when and how data will be directed to a new element of the set. +This way, information stored in elements of a file set +that are currently unused are available for administrational +operations without the risk of disturbing the operation of ntpd. +(Most important: they can be removed to free space for new data +produced.) + +Note that this command can be sent from the +@code{ntpdc(1ntpdcmdoc)} +program running at a remote location. +@table @asis +@item @code{name} +This is the type of the statistics records, as shown in the +@code{statistics} +command. +@item @code{file} @kbd{filename} +This is the file name for the statistics records. +Filenames of set +members are built from three concatenated elements +@code{prefix}, +@code{filename} +and +@code{suffix}: +@table @asis +@item @code{prefix} +This is a constant filename path. +It is not subject to +modifications via the +@kbd{filegen} +option. +It is defined by the +server, usually specified as a compile-time constant. +It may, +however, be configurable for individual file generation sets +via other commands. +For example, the prefix used with +@kbd{loopstats} +and +@kbd{peerstats} +generation can be configured using the +@kbd{statsdir} +option explained above. +@item @code{filename} +This string is directly concatenated to the prefix mentioned +above (no intervening +@quoteleft{}/@quoteright{}). +This can be modified using +the file argument to the +@kbd{filegen} +statement. +No +@file{..} +elements are +allowed in this component to prevent filenames referring to +parts outside the filesystem hierarchy denoted by +@kbd{prefix}. +@item @code{suffix} +This part is reflects individual elements of a file set. +It is +generated according to the type of a file set. +@end table +@item @code{type} @kbd{typename} +A file generation set is characterized by its type. +The following +types are supported: +@table @asis +@item @code{none} +The file set is actually a single plain file. +@item @code{pid} +One element of file set is used per incarnation of a ntpd +server. +This type does not perform any changes to file set +members during runtime, however it provides an easy way of +separating files belonging to different +@code{ntpd(1ntpdmdoc)} +server incarnations. +The set member filename is built by appending a +@quoteleft{}.@quoteright{} +to concatenated +@kbd{prefix} +and +@kbd{filename} +strings, and +appending the decimal representation of the process ID of the +@code{ntpd(1ntpdmdoc)} +server process. +@item @code{day} +One file generation set element is created per day. +A day is +defined as the period between 00:00 and 24:00 UTC. +The file set +member suffix consists of a +@quoteleft{}.@quoteright{} +and a day specification in +the form +@code{YYYYMMdd}. +@code{YYYY} +is a 4-digit year number (e.g., 1992). +@code{MM} +is a two digit month number. +@code{dd} +is a two digit day number. +Thus, all information written at 10 December 1992 would end up +in a file named +@kbd{prefix} +@kbd{filename}.19921210. +@item @code{week} +Any file set member contains data related to a certain week of +a year. +The term week is defined by computing day-of-year +modulo 7. +Elements of such a file generation set are +distinguished by appending the following suffix to the file set +filename base: A dot, a 4-digit year number, the letter +@code{W}, +and a 2-digit week number. +For example, information from January, +10th 1992 would end up in a file with suffix +.No . Ns Ar 1992W1 . +@item @code{month} +One generation file set element is generated per month. +The +file name suffix consists of a dot, a 4-digit year number, and +a 2-digit month. +@item @code{year} +One generation file element is generated per year. +The filename +suffix consists of a dot and a 4 digit year number. +@item @code{age} +This type of file generation sets changes to a new element of +the file set every 24 hours of server operation. +The filename +suffix consists of a dot, the letter +@code{a}, +and an 8-digit number. +This number is taken to be the number of seconds the server is +running at the start of the corresponding 24-hour period. +Information is only written to a file generation by specifying +@code{enable}; +output is prevented by specifying +@code{disable}. +@end table +@item @code{link} | @code{nolink} +It is convenient to be able to access the current element of a file +generation set by a fixed name. +This feature is enabled by +specifying +@code{link} +and disabled using +@code{nolink}. +If link is specified, a +hard link from the current file set element to a file without +suffix is created. +When there is already a file with this name and +the number of links of this file is one, it is renamed appending a +dot, the letter +@code{C}, +and the pid of the ntpd server process. +When the +number of links is greater than one, the file is unlinked. +This +allows the current file to be accessed by a constant name. +@item @code{enable} @code{|} @code{disable} +Enables or disables the recording function. +@end table +@end table +@end table +@node Access Control Support +@subsection Access Control Support +The +@code{ntpd(1ntpdmdoc)} +daemon implements a general purpose address/mask based restriction +list. +The list contains address/match entries sorted first +by increasing address values and and then by increasing mask values. +A match occurs when the bitwise AND of the mask and the packet +source address is equal to the bitwise AND of the mask and +address in the list. +The list is searched in order with the +last match found defining the restriction flags associated +with the entry. +Additional information and examples can be found in the +"Notes on Configuring NTP and Setting up a NTP Subnet" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). + +The restriction facility was implemented in conformance +with the access policies for the original NSFnet backbone +time servers. +Later the facility was expanded to deflect +cryptographic and clogging attacks. +While this facility may +be useful for keeping unwanted or broken or malicious clients +from congesting innocent servers, it should not be considered +an alternative to the NTP authentication facilities. +Source address based restrictions are easily circumvented +by a determined cracker. + +Clients can be denied service because they are explicitly +included in the restrict list created by the restrict command +or implicitly as the result of cryptographic or rate limit +violations. +Cryptographic violations include certificate +or identity verification failure; rate limit violations generally +result from defective NTP implementations that send packets +at abusive rates. +Some violations cause denied service +only for the offending packet, others cause denied service +for a timed period and others cause the denied service for +an indefinate period. +When a client or network is denied access +for an indefinate period, the only way at present to remove +the restrictions is by restarting the server. +@subsubsection The Kiss-of-Death Packet +Ordinarily, packets denied service are simply dropped with no +further action except incrementing statistics counters. +Sometimes a +more proactive response is needed, such as a server message that +explicitly requests the client to stop sending and leave a message +for the system operator. +A special packet format has been created +for this purpose called the "kiss-of-death" (KoD) packet. +KoD packets have the leap bits set unsynchronized and stratum set +to zero and the reference identifier field set to a four-byte +ASCII code. +If the +@code{noserve} +or +@code{notrust} +flag of the matching restrict list entry is set, +the code is "DENY"; if the +@code{limited} +flag is set and the rate limit +is exceeded, the code is "RATE". +Finally, if a cryptographic violation occurs, the code is "CRYP". + +A client receiving a KoD performs a set of sanity checks to +minimize security exposure, then updates the stratum and +reference identifier peer variables, sets the access +denied (TEST4) bit in the peer flash variable and sends +a message to the log. +As long as the TEST4 bit is set, +the client will send no further packets to the server. +The only way at present to recover from this condition is +to restart the protocol at both the client and server. +This +happens automatically at the client when the association times out. +It will happen at the server only if the server operator cooperates. +@subsubsection Access Control Commands +@table @asis +@item @code{discard} @code{[@code{average} @kbd{avg}]} @code{[@code{minimum} @kbd{min}]} @code{[@code{monitor} @kbd{prob}]} +Set the parameters of the +@code{limited} +facility which protects the server from +client abuse. +The +@code{average} +subcommand specifies the minimum average packet +spacing, while the +@code{minimum} +subcommand specifies the minimum packet spacing. +Packets that violate these minima are discarded +and a kiss-o'-death packet returned if enabled. +The default +minimum average and minimum are 5 and 2, respectively. +The monitor subcommand specifies the probability of discard +for packets that overflow the rate-control window. +@item @code{restrict} @code{address} @code{[@code{mask} @kbd{mask}]} @code{[@kbd{flag} @kbd{...}]} +The +@kbd{address} +argument expressed in +dotted-quad form is the address of a host or network. +Alternatively, the +@kbd{address} +argument can be a valid host DNS name. +The +@kbd{mask} +argument expressed in dotted-quad form defaults to +@code{255.255.255.255}, +meaning that the +@kbd{address} +is treated as the address of an individual host. +A default entry (address +@code{0.0.0.0}, +mask +@code{0.0.0.0}) +is always included and is always the first entry in the list. +Note that text string +@code{default}, +with no mask option, may +be used to indicate the default entry. +In the current implementation, +@code{flag} +always +restricts access, i.e., an entry with no flags indicates that free +access to the server is to be given. +The flags are not orthogonal, +in that more restrictive flags will often make less restrictive +ones redundant. +The flags can generally be classed into two +categories, those which restrict time service and those which +restrict informational queries and attempts to do run-time +reconfiguration of the server. +One or more of the following flags +may be specified: +@table @asis +@item @code{ignore} +Deny packets of all kinds, including +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +queries. +@item @code{kod} +If this flag is set when an access violation occurs, a kiss-o'-death +(KoD) packet is sent. +KoD packets are rate limited to no more than one +per second. +If another KoD packet occurs within one second after the +last one, the packet is dropped. +@item @code{limited} +Deny service if the packet spacing violates the lower limits specified +in the discard command. +A history of clients is kept using the +monitoring capability of +@code{ntpd(1ntpdmdoc)}. +Thus, monitoring is always active as +long as there is a restriction entry with the +@code{limited} +flag. +@item @code{lowpriotrap} +Declare traps set by matching hosts to be low priority. +The +number of traps a server can maintain is limited (the current limit +is 3). +Traps are usually assigned on a first come, first served +basis, with later trap requestors being denied service. +This flag +modifies the assignment algorithm by allowing low priority traps to +be overridden by later requests for normal priority traps. +@item @code{nomodify} +Deny +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +queries which attempt to modify the state of the +server (i.e., run time reconfiguration). +Queries which return +information are permitted. +@item @code{noquery} +Deny +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +queries. +Time service is not affected. +@item @code{nopeer} +Deny packets which would result in mobilizing a new association. +This +includes broadcast and symmetric active packets when a configured +association does not exist. +It also includes +@code{pool} +associations, so if you want to use servers from a +@code{pool} +directive and also want to use +@code{nopeer} +by default, you'll want a +@code{restrict source ...} @code{line} @code{as} @code{well} @code{that} @code{does} +@item not +include the +@code{nopeer} +directive. +@item @code{noserve} +Deny all packets except +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +queries. +@item @code{notrap} +Decline to provide mode 6 control message trap service to matching +hosts. +The trap service is a subsystem of the ntpdq control message +protocol which is intended for use by remote event logging programs. +@item @code{notrust} +Deny service unless the packet is cryptographically authenticated. +@item @code{ntpport} +This is actually a match algorithm modifier, rather than a +restriction flag. +Its presence causes the restriction entry to be +matched only if the source port in the packet is the standard NTP +UDP port (123). +Both +@code{ntpport} +and +@code{non-ntpport} +may +be specified. +The +@code{ntpport} +is considered more specific and +is sorted later in the list. +@item @code{version} +Deny packets that do not match the current NTP version. +@end table + +Default restriction list entries with the flags ignore, interface, +ntpport, for each of the local host's interface addresses are +inserted into the table at startup to prevent the server +from attempting to synchronize to its own time. +A default entry is also always present, though if it is +otherwise unconfigured; no flags are associated +with the default entry (i.e., everything besides your own +NTP server is unrestricted). +@end table +@node Automatic NTP Configuration Options +@subsection Automatic NTP Configuration Options +@subsubsection Manycasting +Manycasting is a automatic discovery and configuration paradigm +new to NTPv4. +It is intended as a means for a multicast client +to troll the nearby network neighborhood to find cooperating +manycast servers, validate them using cryptographic means +and evaluate their time values with respect to other servers +that might be lurking in the vicinity. +The intended result is that each manycast client mobilizes +client associations with some number of the "best" +of the nearby manycast servers, yet automatically reconfigures +to sustain this number of servers should one or another fail. + +Note that the manycasting paradigm does not coincide +with the anycast paradigm described in RFC-1546, +which is designed to find a single server from a clique +of servers providing the same service. +The manycast paradigm is designed to find a plurality +of redundant servers satisfying defined optimality criteria. + +Manycasting can be used with either symmetric key +or public key cryptography. +The public key infrastructure (PKI) +offers the best protection against compromised keys +and is generally considered stronger, at least with relatively +large key sizes. +It is implemented using the Autokey protocol and +the OpenSSL cryptographic library available from +@code{http://www.openssl.org/}. +The library can also be used with other NTPv4 modes +as well and is highly recommended, especially for broadcast modes. + +A persistent manycast client association is configured +using the manycastclient command, which is similar to the +server command but with a multicast (IPv4 class +@code{D} +or IPv6 prefix +@code{FF}) +group address. +The IANA has designated IPv4 address 224.1.1.1 +and IPv6 address FF05::101 (site local) for NTP. +When more servers are needed, it broadcasts manycast +client messages to this address at the minimum feasible rate +and minimum feasible time-to-live (TTL) hops, depending +on how many servers have already been found. +There can be as many manycast client associations +as different group address, each one serving as a template +for a future ephemeral unicast client/server association. + +Manycast servers configured with the +@code{manycastserver} +command listen on the specified group address for manycast +client messages. +Note the distinction between manycast client, +which actively broadcasts messages, and manycast server, +which passively responds to them. +If a manycast server is +in scope of the current TTL and is itself synchronized +to a valid source and operating at a stratum level equal +to or lower than the manycast client, it replies to the +manycast client message with an ordinary unicast server message. + +The manycast client receiving this message mobilizes +an ephemeral client/server association according to the +matching manycast client template, but only if cryptographically +authenticated and the server stratum is less than or equal +to the client stratum. +Authentication is explicitly required +and either symmetric key or public key (Autokey) can be used. +Then, the client polls the server at its unicast address +in burst mode in order to reliably set the host clock +and validate the source. +This normally results +in a volley of eight client/server at 2-s intervals +during which both the synchronization and cryptographic +protocols run concurrently. +Following the volley, +the client runs the NTP intersection and clustering +algorithms, which act to discard all but the "best" +associations according to stratum and synchronization +distance. +The surviving associations then continue +in ordinary client/server mode. + +The manycast client polling strategy is designed to reduce +as much as possible the volume of manycast client messages +and the effects of implosion due to near-simultaneous +arrival of manycast server messages. +The strategy is determined by the +@code{manycastclient}, +@code{tos} +and +@code{ttl} +configuration commands. +The manycast poll interval is +normally eight times the system poll interval, +which starts out at the +@code{minpoll} +value specified in the +@code{manycastclient}, +command and, under normal circumstances, increments to the +@code{maxpolll} +value specified in this command. +Initially, the TTL is +set at the minimum hops specified by the ttl command. +At each retransmission the TTL is increased until reaching +the maximum hops specified by this command or a sufficient +number client associations have been found. +Further retransmissions use the same TTL. + +The quality and reliability of the suite of associations +discovered by the manycast client is determined by the NTP +mitigation algorithms and the +@code{minclock} +and +@code{minsane} +values specified in the +@code{tos} +configuration command. +At least +@code{minsane} +candidate servers must be available and the mitigation +algorithms produce at least +@code{minclock} +survivors in order to synchronize the clock. +Byzantine agreement principles require at least four +candidates in order to correctly discard a single falseticker. +For legacy purposes, +@code{minsane} +defaults to 1 and +@code{minclock} +defaults to 3. +For manycast service +@code{minsane} +should be explicitly set to 4, assuming at least that +number of servers are available. + +If at least +@code{minclock} +servers are found, the manycast poll interval is immediately +set to eight times +@code{maxpoll}. +If less than +@code{minclock} +servers are found when the TTL has reached the maximum hops, +the manycast poll interval is doubled. +For each transmission +after that, the poll interval is doubled again until +reaching the maximum of eight times +@code{maxpoll}. +Further transmissions use the same poll interval and +TTL values. +Note that while all this is going on, +each client/server association found is operating normally +it the system poll interval. + +Administratively scoped multicast boundaries are normally +specified by the network router configuration and, +in the case of IPv6, the link/site scope prefix. +By default, the increment for TTL hops is 32 starting +from 31; however, the +@code{ttl} +configuration command can be +used to modify the values to match the scope rules. + +It is often useful to narrow the range of acceptable +servers which can be found by manycast client associations. +Because manycast servers respond only when the client +stratum is equal to or greater than the server stratum, +primary (stratum 1) servers fill find only primary servers +in TTL range, which is probably the most common objective. +However, unless configured otherwise, all manycast clients +in TTL range will eventually find all primary servers +in TTL range, which is probably not the most common +objective in large networks. +The +@code{tos} +command can be used to modify this behavior. +Servers with stratum below +@code{floor} +or above +@code{ceiling} +specified in the +@code{tos} +command are strongly discouraged during the selection +process; however, these servers may be temporally +accepted if the number of servers within TTL range is +less than +@code{minclock}. + +The above actions occur for each manycast client message, +which repeats at the designated poll interval. +However, once the ephemeral client association is mobilized, +subsequent manycast server replies are discarded, +since that would result in a duplicate association. +If during a poll interval the number of client associations +falls below +@code{minclock}, +all manycast client prototype associations are reset +to the initial poll interval and TTL hops and operation +resumes from the beginning. +It is important to avoid +frequent manycast client messages, since each one requires +all manycast servers in TTL range to respond. +The result could well be an implosion, either minor or major, +depending on the number of servers in range. +The recommended value for +@code{maxpoll} +is 12 (4,096 s). + +It is possible and frequently useful to configure a host +as both manycast client and manycast server. +A number of hosts configured this way and sharing a common +group address will automatically organize themselves +in an optimum configuration based on stratum and +synchronization distance. +For example, consider an NTP +subnet of two primary servers and a hundred or more +dependent clients. +With two exceptions, all servers +and clients have identical configuration files including both +@code{multicastclient} +and +@code{multicastserver} +commands using, for instance, multicast group address +239.1.1.1. +The only exception is that each primary server +configuration file must include commands for the primary +reference source such as a GPS receiver. + +The remaining configuration files for all secondary +servers and clients have the same contents, except for the +@code{tos} +command, which is specific for each stratum level. +For stratum 1 and stratum 2 servers, that command is +not necessary. +For stratum 3 and above servers the +@code{floor} +value is set to the intended stratum number. +Thus, all stratum 3 configuration files are identical, +all stratum 4 files are identical and so forth. + +Once operations have stabilized in this scenario, +the primary servers will find the primary reference source +and each other, since they both operate at the same +stratum (1), but not with any secondary server or client, +since these operate at a higher stratum. +The secondary +servers will find the servers at the same stratum level. +If one of the primary servers loses its GPS receiver, +it will continue to operate as a client and other clients +will time out the corresponding association and +re-associate accordingly. + +Some administrators prefer to avoid running +@code{ntpd(1ntpdmdoc)} +continuously and run either +@code{sntp(1sntpmdoc)} +or +@code{ntpd(1ntpdmdoc)} +@code{-q} +as a cron job. +In either case the servers must be +configured in advance and the program fails if none are +available when the cron job runs. +A really slick +application of manycast is with +@code{ntpd(1ntpdmdoc)} +@code{-q}. +The program wakes up, scans the local landscape looking +for the usual suspects, selects the best from among +the rascals, sets the clock and then departs. +Servers do not have to be configured in advance and +all clients throughout the network can have the same +configuration file. +@subsubsection Manycast Interactions with Autokey +Each time a manycast client sends a client mode packet +to a multicast group address, all manycast servers +in scope generate a reply including the host name +and status word. +The manycast clients then run +the Autokey protocol, which collects and verifies +all certificates involved. +Following the burst interval +all but three survivors are cast off, +but the certificates remain in the local cache. +It often happens that several complete signing trails +from the client to the primary servers are collected in this way. + +About once an hour or less often if the poll interval +exceeds this, the client regenerates the Autokey key list. +This is in general transparent in client/server mode. +However, about once per day the server private value +used to generate cookies is refreshed along with all +manycast client associations. +In this case all +cryptographic values including certificates is refreshed. +If a new certificate has been generated since +the last refresh epoch, it will automatically revoke +all prior certificates that happen to be in the +certificate cache. +At the same time, the manycast +scheme starts all over from the beginning and +the expanding ring shrinks to the minimum and increments +from there while collecting all servers in scope. +@subsubsection Manycast Options +@table @asis +@item @code{tos} @code{[@code{ceiling} @kbd{ceiling} | @code{cohort} @code{@{} @code{0} | @code{1} @code{@}} | @code{floor} @kbd{floor} | @code{minclock} @kbd{minclock} | @code{minsane} @kbd{minsane}]} +This command affects the clock selection and clustering +algorithms. +It can be used to select the quality and +quantity of peers used to synchronize the system clock +and is most useful in manycast mode. +The variables operate +as follows: +@table @asis +@item @code{ceiling} @kbd{ceiling} +Peers with strata above +@code{ceiling} +will be discarded if there are at least +@code{minclock} +peers remaining. +This value defaults to 15, but can be changed +to any number from 1 to 15. +@item @code{cohort} @code{@{0 | 1@}} +This is a binary flag which enables (0) or disables (1) +manycast server replies to manycast clients with the same +stratum level. +This is useful to reduce implosions where +large numbers of clients with the same stratum level +are present. +The default is to enable these replies. +@item @code{floor} @kbd{floor} +Peers with strata below +@code{floor} +will be discarded if there are at least +@code{minclock} +peers remaining. +This value defaults to 1, but can be changed +to any number from 1 to 15. +@item @code{minclock} @kbd{minclock} +The clustering algorithm repeatedly casts out outlier +associations until no more than +@code{minclock} +associations remain. +This value defaults to 3, +but can be changed to any number from 1 to the number of +configured sources. +@item @code{minsane} @kbd{minsane} +This is the minimum number of candidates available +to the clock selection algorithm in order to produce +one or more truechimers for the clustering algorithm. +If fewer than this number are available, the clock is +undisciplined and allowed to run free. +The default is 1 +for legacy purposes. +However, according to principles of +Byzantine agreement, +@code{minsane} +should be at least 4 in order to detect and discard +a single falseticker. +@end table +@item @code{ttl} @kbd{hop} @kbd{...} +This command specifies a list of TTL values in increasing +order, up to 8 values can be specified. +In manycast mode these values are used in turn +in an expanding-ring search. +The default is eight +multiples of 32 starting at 31. +@end table +@node Reference Clock Support +@subsection Reference Clock Support +The NTP Version 4 daemon supports some three dozen different radio, +satellite and modem reference clocks plus a special pseudo-clock +used for backup or when no other clock source is available. +Detailed descriptions of individual device drivers and options can +be found in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). +Additional information can be found in the pages linked +there, including the +"Debugging Hints for Reference Clock Drivers" +and +"How To Write a Reference Clock Driver" +pages +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). +In addition, support for a PPS +signal is available as described in the +"Pulse-per-second (PPS) Signal Interfacing" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). +Many +drivers support special line discipline/streams modules which can +significantly improve the accuracy using the driver. +These are +described in the +"Line Disciplines and Streams Drivers" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). + +A reference clock will generally (though not always) be a radio +timecode receiver which is synchronized to a source of standard +time such as the services offered by the NRC in Canada and NIST and +USNO in the US. +The interface between the computer and the timecode +receiver is device dependent, but is usually a serial port. +A +device driver specific to each reference clock must be selected and +compiled in the distribution; however, most common radio, satellite +and modem clocks are included by default. +Note that an attempt to +configure a reference clock when the driver has not been compiled +or the hardware port has not been appropriately configured results +in a scalding remark to the system log file, but is otherwise non +hazardous. + +For the purposes of configuration, +@code{ntpd(1ntpdmdoc)} +treats +reference clocks in a manner analogous to normal NTP peers as much +as possible. +Reference clocks are identified by a syntactically +correct but invalid IP address, in order to distinguish them from +normal NTP peers. +Reference clock addresses are of the form +@code{127.127.}@kbd{t}.@kbd{u}, +where +@kbd{t} +is an integer +denoting the clock type and +@kbd{u} +indicates the unit +number in the range 0-3. +While it may seem overkill, it is in fact +sometimes useful to configure multiple reference clocks of the same +type, in which case the unit numbers must be unique. + +The +@code{server} +command is used to configure a reference +clock, where the +@kbd{address} +argument in that command +is the clock address. +The +@code{key}, +@code{version} +and +@code{ttl} +options are not used for reference clock support. +The +@code{mode} +option is added for reference clock support, as +described below. +The +@code{prefer} +option can be useful to +persuade the server to cherish a reference clock with somewhat more +enthusiasm than other reference clocks or peers. +Further +information on this option can be found in the +"Mitigation Rules and the prefer Keyword" +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}) +page. +The +@code{minpoll} +and +@code{maxpoll} +options have +meaning only for selected clock drivers. +See the individual clock +driver document pages for additional information. + +The +@code{fudge} +command is used to provide additional +information for individual clock drivers and normally follows +immediately after the +@code{server} +command. +The +@kbd{address} +argument specifies the clock address. +The +@code{refid} +and +@code{stratum} +options can be used to +override the defaults for the device. +There are two optional +device-dependent time offsets and four flags that can be included +in the +@code{fudge} +command as well. + +The stratum number of a reference clock is by default zero. +Since the +@code{ntpd(1ntpdmdoc)} +daemon adds one to the stratum of each +peer, a primary server ordinarily displays an external stratum of +one. +In order to provide engineered backups, it is often useful to +specify the reference clock stratum as greater than zero. +The +@code{stratum} +option is used for this purpose. +Also, in cases +involving both a reference clock and a pulse-per-second (PPS) +discipline signal, it is useful to specify the reference clock +identifier as other than the default, depending on the driver. +The +@code{refid} +option is used for this purpose. +Except where noted, +these options apply to all clock drivers. +@subsubsection Reference Clock Commands +@table @asis +@item @code{server} @code{127.127.}@kbd{t}.@kbd{u} @code{[@code{prefer}]} @code{[@code{mode} @kbd{int}]} @code{[@code{minpoll} @kbd{int}]} @code{[@code{maxpoll} @kbd{int}]} +This command can be used to configure reference clocks in +special ways. +The options are interpreted as follows: +@table @asis +@item @code{prefer} +Marks the reference clock as preferred. +All other things being +equal, this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}) +for further information. +@item @code{mode} @kbd{int} +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +@item @code{minpoll} @kbd{int} +@item @code{maxpoll} @kbd{int} +These options specify the minimum and maximum polling interval +for reference clock messages, as a power of 2 in seconds +For +most directly connected reference clocks, both +@code{minpoll} +and +@code{maxpoll} +default to 6 (64 s). +For modem reference clocks, +@code{minpoll} +defaults to 10 (17.1 m) and +@code{maxpoll} +defaults to 14 (4.5 h). +The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. +@end table +@item @code{fudge} @code{127.127.}@kbd{t}.@kbd{u} @code{[@code{time1} @kbd{sec}]} @code{[@code{time2} @kbd{sec}]} @code{[@code{stratum} @kbd{int}]} @code{[@code{refid} @kbd{string}]} @code{[@code{mode} @kbd{int}]} @code{[@code{flag1} @code{0} @code{|} @code{1}]} @code{[@code{flag2} @code{0} @code{|} @code{1}]} @code{[@code{flag3} @code{0} @code{|} @code{1}]} @code{[@code{flag4} @code{0} @code{|} @code{1}]} +This command can be used to configure reference clocks in +special ways. +It must immediately follow the +@code{server} +command which configures the driver. +Note that the same capability +is possible at run time using the +@code{ntpdc(1ntpdcmdoc)} +program. +The options are interpreted as +follows: +@table @asis +@item @code{time1} @kbd{sec} +Specifies a constant to be added to the time offset produced by +the driver, a fixed-point decimal number in seconds. +This is used +as a calibration constant to adjust the nominal time offset of a +particular clock to agree with an external standard, such as a +precision PPS signal. +It also provides a way to correct a +systematic error or bias due to serial port or operating system +latencies, different cable lengths or receiver internal delay. +The +specified offset is in addition to the propagation delay provided +by other means, such as internal DIPswitches. +Where a calibration +for an individual system and driver is available, an approximate +correction is noted in the driver documentation pages. +Note: in order to facilitate calibration when more than one +radio clock or PPS signal is supported, a special calibration +feature is available. +It takes the form of an argument to the +@code{enable} +command described in +@ref{Miscellaneous Options} +page and operates as described in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). +@item @code{time2} @kbd{secs} +Specifies a fixed-point decimal number in seconds, which is +interpreted in a driver-dependent way. +See the descriptions of +specific drivers in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +@file{/usr/share/doc/ntp}). +@item @code{stratum} @kbd{int} +Specifies the stratum number assigned to the driver, an integer +between 0 and 15. +This number overrides the default stratum number +ordinarily assigned by the driver itself, usually zero. +@item @code{refid} @kbd{string} +Specifies an ASCII string of from one to four characters which +defines the reference identifier used by the driver. +This string +overrides the default identifier ordinarily assigned by the driver +itself. +@item @code{mode} @kbd{int} +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +@item @code{flag1} @code{0} @code{|} @code{1} +@item @code{flag2} @code{0} @code{|} @code{1} +@item @code{flag3} @code{0} @code{|} @code{1} +@item @code{flag4} @code{0} @code{|} @code{1} +These four flags are used for customizing the clock driver. +The +interpretation of these values, and whether they are used at all, +is a function of the particular clock driver. +However, by +convention +@code{flag4} +is used to enable recording monitoring +data to the +@code{clockstats} +file configured with the +@code{filegen} +command. +Further information on the +@code{filegen} +command can be found in +@ref{Monitoring Options}. +@end table +@end table +@node Miscellaneous Options +@subsection Miscellaneous Options +@table @asis +@item @code{broadcastdelay} @kbd{seconds} +The broadcast and multicast modes require a special calibration +to determine the network delay between the local and remote +servers. +Ordinarily, this is done automatically by the initial +protocol exchanges between the client and server. +In some cases, +the calibration procedure may fail due to network or server access +controls, for example. +This command specifies the default delay to +be used under these circumstances. +Typically (for Ethernet), a +number between 0.003 and 0.007 seconds is appropriate. +The default +when this command is not used is 0.004 seconds. +@item @code{calldelay} @kbd{delay} +This option controls the delay in seconds between the first and second +packets sent in burst or iburst mode to allow additional time for a modem +or ISDN call to complete. +@item @code{driftfile} @kbd{driftfile} +This command specifies the complete path and name of the file used to +record the frequency of the local clock oscillator. +This is the same +operation as the +@code{-f} +command line option. +If the file exists, it is read at +startup in order to set the initial frequency and then updated once per +hour with the current frequency computed by the daemon. +If the file name is +specified, but the file itself does not exist, the starts with an initial +frequency of zero and creates the file when writing it for the first time. +If this command is not given, the daemon will always start with an initial +frequency of zero. + +The file format consists of a single line containing a single +floating point number, which records the frequency offset measured +in parts-per-million (PPM). +The file is updated by first writing +the current drift value into a temporary file and then renaming +this file to replace the old version. +This implies that +@code{ntpd(1ntpdmdoc)} +must have write permission for the directory the +drift file is located in, and that file system links, symbolic or +otherwise, should be avoided. +@item @code{dscp} @kbd{value} +This option specifies the Differentiated Services Control Point (DSCP) value, +a 6-bit code. The default value is 46, signifying Expedited Forwarding. +@item @code{enable} @code{[@code{auth} | @code{bclient} | @code{calibrate} | @code{kernel} | @code{mode7} | @code{monitor} | @code{ntp} | @code{stats}]} +@item @code{disable} @code{[@code{auth} | @code{bclient} | @code{calibrate} | @code{kernel} | @code{mode7} | @code{monitor} | @code{ntp} | @code{stats}]} +Provides a way to enable or disable various server options. +Flags not mentioned are unaffected. +Note that all of these flags +can be controlled remotely using the +@code{ntpdc(1ntpdcmdoc)} +utility program. +@table @asis +@item @code{auth} +Enables the server to synchronize with unconfigured peers only if the +peer has been correctly authenticated using either public key or +private key cryptography. +The default for this flag is +@code{enable}. +@item @code{bclient} +Enables the server to listen for a message from a broadcast or +multicast server, as in the +@code{multicastclient} +command with default +address. +The default for this flag is +@code{disable}. +@item @code{calibrate} +Enables the calibrate feature for reference clocks. +The default for +this flag is +@code{disable}. +@item @code{kernel} +Enables the kernel time discipline, if available. +The default for this +flag is +@code{enable} +if support is available, otherwise +@code{disable}. +@item @code{mode7} +Enables processing of NTP mode 7 implementation-specific requests +which are used by the deprecated +@code{ntpdc(1ntpdcmdoc)} +program. +The default for this flag is disable. +This flag is excluded from runtime configuration using +@code{ntpq(1ntpqmdoc)}. +The +@code{ntpq(1ntpqmdoc)} +program provides the same capabilities as +@code{ntpdc(1ntpdcmdoc)} +using standard mode 6 requests. +@item @code{monitor} +Enables the monitoring facility. +See the +@code{ntpdc(1ntpdcmdoc)} +program +and the +@code{monlist} +command or further information. +The +default for this flag is +@code{enable}. +@item @code{ntp} +Enables time and frequency discipline. +In effect, this switch opens and +closes the feedback loop, which is useful for testing. +The default for +this flag is +@code{enable}. +@item @code{stats} +Enables the statistics facility. +See the +@ref{Monitoring Options} +section for further information. +The default for this flag is +@code{disable}. +@end table +@item @code{includefile} @kbd{includefile} +This command allows additional configuration commands +to be included from a separate file. +Include files may +be nested to a depth of five; upon reaching the end of any +include file, command processing resumes in the previous +configuration file. +This option is useful for sites that run +@code{ntpd(1ntpdmdoc)} +on multiple hosts, with (mostly) common options (e.g., a +restriction list). +@item @code{leapsmearinterval} @kbd{seconds} +This EXPERIMENTAL option is only available if +@code{ntpd(1ntpdmdoc)} +was built with the +@code{--enable-leap-smear} +option to the +@code{configure} +script. +It specifies the interval over which a leap second correction will be applied. +Recommended values for this option are between +7200 (2 hours) and 86400 (24 hours). +.Sy DO NOT USE THIS OPTION ON PUBLIC-ACCESS SERVERS! +See http://bugs.ntp.org/2855 for more information. +@item @code{logconfig} @kbd{configkeyword} +This command controls the amount and type of output written to +the system +@code{syslog(3)} +facility or the alternate +@code{logfile} +log file. +By default, all output is turned on. +All +@kbd{configkeyword} +keywords can be prefixed with +@quoteleft{}=@quoteright{}, +@quoteleft{}+@quoteright{} +and +@quoteleft{}-@quoteright{}, +where +@quoteleft{}=@quoteright{} +sets the +@code{syslog(3)} +priority mask, +@quoteleft{}+@quoteright{} +adds and +@quoteleft{}-@quoteright{} +removes +messages. +@code{syslog(3)} +messages can be controlled in four +classes +(@code{clock}, @code{peer}, @code{sys} and @code{sync}). +Within these classes four types of messages can be +controlled: informational messages +(@code{info}), +event messages +(@code{events}), +statistics messages +(@code{statistics}) +and +status messages +(@code{status}). + +Configuration keywords are formed by concatenating the message class with +the event class. +The +@code{all} +prefix can be used instead of a message class. +A +message class may also be followed by the +@code{all} +keyword to enable/disable all +messages of the respective message class.Thus, a minimal log configuration +could look like this: +@verbatim +logconfig =syncstatus +sysevents +@end verbatim + +This would just list the synchronizations state of +@code{ntpd(1ntpdmdoc)} +and the major system events. +For a simple reference server, the +following minimum message configuration could be useful: +@verbatim +logconfig =syncall +clockall +@end verbatim + +This configuration will list all clock information and +synchronization information. +All other events and messages about +peers, system events and so on is suppressed. +@item @code{logfile} @kbd{logfile} +This command specifies the location of an alternate log file to +be used instead of the default system +@code{syslog(3)} +facility. +This is the same operation as the -l command line option. +@item @code{setvar} @kbd{variable} @code{[@code{default}]} +This command adds an additional system variable. +These +variables can be used to distribute additional information such as +the access policy. +If the variable of the form +@code{name}@code{=}@kbd{value} +is followed by the +@code{default} +keyword, the +variable will be listed as part of the default system variables +(@code{rv} command)). +These additional variables serve +informational purposes only. +They are not related to the protocol +other that they can be listed. +The known protocol variables will +always override any variables defined via the +@code{setvar} +mechanism. +There are three special variables that contain the names +of all variable of the same group. +The +@code{sys_var_list} +holds +the names of all system variables. +The +@code{peer_var_list} +holds +the names of all peer variables and the +@code{clock_var_list} +holds the names of the reference clock variables. +@item @code{tinker} @code{[@code{allan} @kbd{allan} | @code{dispersion} @kbd{dispersion} | @code{freq} @kbd{freq} | @code{huffpuff} @kbd{huffpuff} | @code{panic} @kbd{panic} | @code{step} @kbd{step} | @code{stepback} @kbd{stepback} | @code{stepfwd} @kbd{stepfwd} | @code{stepout} @kbd{stepout}]} +This command can be used to alter several system variables in +very exceptional circumstances. +It should occur in the +configuration file before any other configuration options. +The +default values of these variables have been carefully optimized for +a wide range of network speeds and reliability expectations. +In +general, they interact in intricate ways that are hard to predict +and some combinations can result in some very nasty behavior. +Very +rarely is it necessary to change the default values; but, some +folks cannot resist twisting the knobs anyway and this command is +for them. +Emphasis added: twisters are on their own and can expect +no help from the support group. + +The variables operate as follows: +@table @asis +@item @code{allan} @kbd{allan} +The argument becomes the new value for the minimum Allan +intercept, which is a parameter of the PLL/FLL clock discipline +algorithm. +The value in log2 seconds defaults to 7 (1024 s), which is also the lower +limit. +@item @code{dispersion} @kbd{dispersion} +The argument becomes the new value for the dispersion increase rate, +normally .000015 s/s. +@item @code{freq} @kbd{freq} +The argument becomes the initial value of the frequency offset in +parts-per-million. +This overrides the value in the frequency file, if +present, and avoids the initial training state if it is not. +@item @code{huffpuff} @kbd{huffpuff} +The argument becomes the new value for the experimental +huff-n'-puff filter span, which determines the most recent interval +the algorithm will search for a minimum delay. +The lower limit is +900 s (15 m), but a more reasonable value is 7200 (2 hours). +There +is no default, since the filter is not enabled unless this command +is given. +@item @code{panic} @kbd{panic} +The argument is the panic threshold, normally 1000 s. +If set to zero, +the panic sanity check is disabled and a clock offset of any value will +be accepted. +@item @code{step} @kbd{step} +The argument is the step threshold, which by default is 0.128 s. +It can +be set to any positive number in seconds. +If set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if the step threshold is set to zero or greater than the +default. +@item @code{stepback} @kbd{stepback} +The argument is the step threshold for the backward direction, +which by default is 0.128 s. +It can +be set to any positive number in seconds. +If both the forward and backward step thresholds are set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if +each direction of step threshold are either +set to zero or greater than .5 second. +@item @code{stepfwd} @kbd{stepfwd} +As for stepback, but for the forward direction. +@item @code{stepout} @kbd{stepout} +The argument is the stepout timeout, which by default is 900 s. +It can +be set to any positive number in seconds. +If set to zero, the stepout +pulses will not be suppressed. +@end table +@item @code{rlimit} @code{[@code{memlock} @kbd{Nmegabytes} | @code{stacksize} @kbd{N4kPages} @code{filenum} @kbd{Nfiledescriptors}]} +@table @asis +@item @code{memlock} @kbd{Nmegabytes} +Specify the number of megabytes of memory that should be +allocated and locked. +Probably only available under Linux, this option may be useful +when dropping root (the +@code{-i} +option). +The default is 32 megabytes on non-Linux machines, and -1 under Linux. +-1 means "do not lock the process into memory". +0 means "lock whatever memory the process wants into memory". +@item @code{stacksize} @kbd{N4kPages} +Specifies the maximum size of the process stack on systems with the +@code{mlockall()} +function. +Defaults to 50 4k pages (200 4k pages in OpenBSD). +@item @code{filenum} @kbd{Nfiledescriptors} +Specifies the maximum number of file descriptors ntpd may have open at once. Defaults to the system default. +@end table +@item @code{trap} @kbd{host_address} @code{[@code{port} @kbd{port_number}]} @code{[@code{interface} @kbd{interface_address}]} +This command configures a trap receiver at the given host +address and port number for sending messages with the specified +local interface address. +If the port number is unspecified, a value +of 18447 is used. +If the interface address is not specified, the +message is sent with a source address of the local interface the +message is sent through. +Note that on a multihomed host the +interface used may vary from time to time with routing changes. + +The trap receiver will generally log event messages and other +information from the server in a log file. +While such monitor +programs may also request their own trap dynamically, configuring a +trap receiver will ensure that no messages are lost when the server +is started. +@item @code{hop} @kbd{...} +This command specifies a list of TTL values in increasing order, up to 8 +values can be specified. +In manycast mode these values are used in turn in +an expanding-ring search. +The default is eight multiples of 32 starting at +31. +@end table + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntp.conf} program. +This software is released under the NTP license, . + +@menu +* ntp.conf Files:: Files +* ntp.conf See Also:: See Also +* ntp.conf Bugs:: Bugs +* ntp.conf Notes:: Notes +@end menu + +@node ntp.conf Files +@subsection ntp.conf Files +@table @asis +@item @file{/etc/ntp.conf} +the default name of the configuration file +@item @file{ntp.keys} +private MD5 keys +@item @file{ntpkey} +RSA private key +@item @file{ntpkey_}@kbd{host} +RSA public key +@item @file{ntp_dh} +Diffie-Hellman agreement parameters +@end table +@node ntp.conf See Also +@subsection ntp.conf See Also +@code{ntpd(1ntpdmdoc)}, +@code{ntpdc(1ntpdcmdoc)}, +@code{ntpq(1ntpqmdoc)} + +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +@code{http://www.ntp.org/}. +A snapshot of this documentation is available in HTML format in +@file{/usr/share/doc/ntp}. +@* + +@* +David L. Mills, @emph{Network Time Protocol (Version 4)}, RFC5905 +@node ntp.conf Bugs +@subsection ntp.conf Bugs +The syntax checking is not picky; some combinations of +ridiculous and even hilarious options and modes may not be +detected. + +The +@file{ntpkey_}@kbd{host} +files are really digital +certificates. +These should be obtained via secure directory +services when they become universally available. +@node ntp.conf Notes +@subsection ntp.conf Notes +This document was derived from FreeBSD. diff --git a/contrib/ntp/ntpd/invoke-ntp.keys.menu b/contrib/ntp/ntpd/invoke-ntp.keys.menu new file mode 100644 index 000000000..2185e4bd5 --- /dev/null +++ b/contrib/ntp/ntpd/invoke-ntp.keys.menu @@ -0,0 +1 @@ +* ntp.keys Notes:: Notes about ntp.keys diff --git a/contrib/ntp/ntpd/invoke-ntp.keys.texi b/contrib/ntp/ntpd/invoke-ntp.keys.texi new file mode 100644 index 000000000..33fdb8938 --- /dev/null +++ b/contrib/ntp/ntpd/invoke-ntp.keys.texi @@ -0,0 +1,125 @@ +@node ntp.keys Notes +@section Notes about ntp.keys +@pindex ntp.keys +@cindex NTP symmetric key file format +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntp.keys.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:38:19 PM by AutoGen 5.18.5 +# From the definitions ntp.keys.def +# and the template file agtexi-file.tpl +@end ignore + + + +This document describes the format of an NTP symmetric key file. +For a description of the use of this type of file, see the +"Authentication Support" +section of the +@code{ntp.conf(5)} +page. + +@code{ntpd(8)} +reads its keys from a file specified using the +@code{-k} +command line option or the +@code{keys} +statement in the configuration file. +While key number 0 is fixed by the NTP standard +(as 56 zero bits) +and may not be changed, +one or more keys numbered between 1 and 65534 +may be arbitrarily set in the keys file. + +The key file uses the same comment conventions +as the configuration file. +Key entries use a fixed format of the form + +@example +@kbd{keyno} @kbd{type} @kbd{key} +@end example + +where +@kbd{keyno} +is a positive integer (between 1 and 65534), +@kbd{type} +is the message digest algorithm, +and +@kbd{key} +is the key itself. + +The +@kbd{key} +may be given in a format +controlled by the +@kbd{type} +field. +The +@kbd{type} +@code{MD5} +is always supported. +If +@code{ntpd} +was built with the OpenSSL library +then any digest library supported by that library may be specified. +However, if compliance with FIPS 140-2 is required the +@kbd{type} +must be either +@code{SHA} +or +@code{SHA1}. + +What follows are some key types, and corresponding formats: + +@table @asis +@item @code{MD5} +The key is 1 to 16 printable characters terminated by +an EOL, +whitespace, +or +a +@code{#} +(which is the "start of comment" character). + +@item @code{SHA} +@item @code{SHA1} +@item @code{RMD160} +The key is a hex-encoded ASCII string of 40 characters, +which is truncated as necessary. +@end table + +Note that the keys used by the +@code{ntpq(8)} +and +@code{ntpdc(8)} +programs are checked against passwords +requested by the programs and entered by hand, +so it is generally appropriate to specify these keys in ASCII format. + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntp.keys} program. +This software is released under the NTP license, . + +@menu +* ntp.keys Files:: Files +* ntp.keys See Also:: See Also +* ntp.keys Notes:: Notes +@end menu + +@node ntp.keys Files +@subsection ntp.keys Files +@table @asis +@item @file{/etc/ntp.keys} +the default name of the configuration file +@end table +@node ntp.keys See Also +@subsection ntp.keys See Also +@code{ntp.conf(5)}, +@code{ntpd(1ntpdmdoc)}, +@code{ntpdate(1ntpdatemdoc)}, +@code{ntpdc(1ntpdcmdoc)}, +@code{sntp(1sntpmdoc)} +@node ntp.keys Notes +@subsection ntp.keys Notes +This document was derived from FreeBSD. diff --git a/contrib/ntp/ntpd/ntpd-opts.menu b/contrib/ntp/ntpd/invoke-ntpd.menu similarity index 100% rename from contrib/ntp/ntpd/ntpd-opts.menu rename to contrib/ntp/ntpd/invoke-ntpd.menu diff --git a/contrib/ntp/ntpd/invoke-ntpd.texi b/contrib/ntp/ntpd/invoke-ntpd.texi new file mode 100644 index 000000000..a781b2668 --- /dev/null +++ b/contrib/ntp/ntpd/invoke-ntpd.texi @@ -0,0 +1,719 @@ +@node ntpd Invocation +@section Invoking ntpd +@pindex ntpd +@cindex NTP daemon program +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntpd.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:38:21 PM by AutoGen 5.18.5 +# From the definitions ntpd-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + + +The +@code{ntpd} +utility is an operating system daemon which sets +and maintains the system time of day in synchronism with Internet +standard time servers. +It is a complete implementation of the +Network Time Protocol (NTP) version 4, as defined by RFC-5905, +but also retains compatibility with +version 3, as defined by RFC-1305, and versions 1 +and 2, as defined by RFC-1059 and RFC-1119, respectively. + +The +@code{ntpd} +utility does most computations in 64-bit floating point +arithmetic and does relatively clumsy 64-bit fixed point operations +only when necessary to preserve the ultimate precision, about 232 +picoseconds. +While the ultimate precision is not achievable with +ordinary workstations and networks of today, it may be required +with future gigahertz CPU clocks and gigabit LANs. + +Ordinarily, +@code{ntpd} +reads the +@code{ntp.conf(5)} +configuration file at startup time in order to determine the +synchronization sources and operating modes. +It is also possible to +specify a working, although limited, configuration entirely on the +command line, obviating the need for a configuration file. +This may +be particularly useful when the local host is to be configured as a +broadcast/multicast client, with all peers being determined by +listening to broadcasts at run time. + +If NetInfo support is built into +@code{ntpd} +then +@code{ntpd} +will attempt to read its configuration from the +NetInfo if the default +@code{ntp.conf(5)} +file cannot be read and no file is +specified by the +@code{-c} +option. + +Various internal +@code{ntpd} +variables can be displayed and +configuration options altered while the +@code{ntpd} +is running +using the +@code{ntpq(1ntpqmdoc)} +and +@code{ntpdc(1ntpdcmdoc)} +utility programs. + +When +@code{ntpd} +starts it looks at the value of +@code{umask(2)}, +and if zero +@code{ntpd} +will set the +@code{umask(2)} +to 022. + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntpd} program. +This software is released under the NTP license, . + +@menu +* ntpd usage:: ntpd help/usage (@option{--help}) +* ntpd ipv4:: ipv4 option (-4) +* ntpd ipv6:: ipv6 option (-6) +* ntpd authreq:: authreq option (-a) +* ntpd authnoreq:: authnoreq option (-A) +* ntpd configfile:: configfile option (-c) +* ntpd driftfile:: driftfile option (-f) +* ntpd panicgate:: panicgate option (-g) +* ntpd force-step-once:: force-step-once option (-G) +* ntpd jaildir:: jaildir option (-i) +* ntpd interface:: interface option (-I) +* ntpd keyfile:: keyfile option (-k) +* ntpd logfile:: logfile option (-l) +* ntpd novirtualips:: novirtualips option (-L) +* ntpd modifymmtimer:: modifymmtimer option (-M) +* ntpd nice:: nice option (-N) +* ntpd pidfile:: pidfile option (-p) +* ntpd priority:: priority option (-P) +* ntpd quit:: quit option (-q) +* ntpd propagationdelay:: propagationdelay option (-r) +* ntpd saveconfigquit:: saveconfigquit option +* ntpd statsdir:: statsdir option (-s) +* ntpd trustedkey:: trustedkey option (-t) +* ntpd user:: user option (-u) +* ntpd updateinterval:: updateinterval option (-U) +* ntpd wait-sync:: wait-sync option (-w) +* ntpd slew:: slew option (-x) +* ntpd usepcc:: usepcc option +* ntpd pccfreq:: pccfreq option +* ntpd mdns:: mdns option (-m) +* ntpd config:: presetting/configuring ntpd +* ntpd exit status:: exit status +* ntpd Usage:: Usage +* ntpd Files:: Files +* ntpd See Also:: See Also +* ntpd Bugs:: Bugs +* ntpd Notes:: Notes +@end menu + +@node ntpd usage +@subsection ntpd help/usage (@option{--help}) +@cindex ntpd help + +This is the automatically generated usage text for ntpd. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +ntpd - NTP daemon program - Ver. 4.2.8p4 +Usage: ntpd [ - [] | --[@{=| @}] ]... \ + [ ... ] + Flg Arg Option-Name Description + -4 no ipv4 Force IPv4 DNS name resolution + - prohibits the option 'ipv6' + -6 no ipv6 Force IPv6 DNS name resolution + - prohibits the option 'ipv4' + -a no authreq Require crypto authentication + - prohibits the option 'authnoreq' + -A no authnoreq Do not require crypto authentication + - prohibits the option 'authreq' + -b no bcastsync Allow us to sync to broadcast servers + -c Str configfile configuration file name + -d no debug-level Increase debug verbosity level + - may appear multiple times + -D Num set-debug-level Set the debug verbosity level + - may appear multiple times + -f Str driftfile frequency drift file name + -g no panicgate Allow the first adjustment to be Big + - may appear multiple times + -G no force-step-once Step any initial offset correction. + -i Str jaildir Jail directory + -I Str interface Listen on an interface name or address + - may appear multiple times + -k Str keyfile path to symmetric keys + -l Str logfile path to the log file + -L no novirtualips Do not listen to virtual interfaces + -n no nofork Do not fork + - prohibits the option 'wait-sync' + -N no nice Run at high priority + -p Str pidfile path to the PID file + -P Num priority Process priority + -q no quit Set the time and quit + - prohibits these options: + saveconfigquit + wait-sync + -r Str propagationdelay Broadcast/propagation delay + Str saveconfigquit Save parsed configuration and quit + - prohibits these options: + quit + wait-sync + -s Str statsdir Statistics file location + -t Str trustedkey Trusted key number + - may appear multiple times + -u Str user Run as userid (or userid:groupid) + -U Num updateinterval interval in seconds between scans for new or dropped interfaces + Str var make ARG an ntp variable (RW) + - may appear multiple times + Str dvar make ARG an ntp variable (RW|DEF) + - may appear multiple times + -w Num wait-sync Seconds to wait for first clock sync + - prohibits these options: + nofork + quit + saveconfigquit + -x no slew Slew up to 600 seconds + opt version output version information and exit + -? no help display extended usage information and exit + -! no more-help extended usage information passed thru pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. + + +The following option preset mechanisms are supported: + - examining environment variables named NTPD_* + +Please send bug reports to: +@end example +@exampleindent 4 + +@node ntpd ipv4 +@subsection ipv4 option (-4) +@cindex ntpd-ipv4 + +This is the ``force ipv4 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv6. +@end itemize + +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +@node ntpd ipv6 +@subsection ipv6 option (-6) +@cindex ntpd-ipv6 + +This is the ``force ipv6 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv4. +@end itemize + +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +@node ntpd authreq +@subsection authreq option (-a) +@cindex ntpd-authreq + +This is the ``require crypto authentication'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +authnoreq. +@end itemize + +Require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is the default. +@node ntpd authnoreq +@subsection authnoreq option (-A) +@cindex ntpd-authnoreq + +This is the ``do not require crypto authentication'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +authreq. +@end itemize + +Do not require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is almost never a good idea. +@node ntpd configfile +@subsection configfile option (-c) +@cindex ntpd-configfile + +This is the ``configuration file name'' option. +This option takes a string argument. +The name and path of the configuration file, +@file{/etc/ntp.conf} +by default. +@node ntpd driftfile +@subsection driftfile option (-f) +@cindex ntpd-driftfile + +This is the ``frequency drift file name'' option. +This option takes a string argument. +The name and path of the frequency file, +@file{/etc/ntp.drift} +by default. +This is the same operation as the +@code{driftfile} @kbd{driftfile} +configuration specification in the +@file{/etc/ntp.conf} +file. +@node ntpd panicgate +@subsection panicgate option (-g) +@cindex ntpd-panicgate + +This is the ``allow the first adjustment to be big'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + +Normally, +@code{ntpd} +exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, +@code{ntpd} +will exit with a message to the system log. This option can be used with the +@code{-q} +and +@code{-x} +options. +See the +@code{tinker} +configuration file directive for other options. +@node ntpd force-step-once +@subsection force-step-once option (-G) +@cindex ntpd-force-step-once + +This is the ``step any initial offset correction.'' option. +Normally, +@code{ntpd} +steps the time if the time offset exceeds the step threshold, +which is 128 ms by default, and otherwise slews the time. +This option forces the initial offset correction to be stepped, +so the highest time accuracy can be achieved quickly. +However, this may also cause the time to be stepped back +so this option must not be used if +applications requiring monotonic time are running. +See the @code{tinker} configuration file directive for other options. +@node ntpd jaildir +@subsection jaildir option (-i) +@cindex ntpd-jaildir + +This is the ``jail directory'' option. +This option takes a string argument. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{HAVE_DROPROOT} during the compilation. +@end itemize + +Chroot the server to the directory +@kbd{jaildir} +. +This option also implies that the server attempts to drop root privileges at startup. +You may need to also specify a +@code{-u} +option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +@code{--enable-clockctl}) or Linux (configure with +@code{--enable-linuxcaps}) or Solaris (configure with @code{--enable-solarisprivs}). +@node ntpd interface +@subsection interface option (-I) +@cindex ntpd-interface + +This is the ``listen on an interface name or address'' option. +This option takes a string argument @file{iface}. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + +Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +@code{interface} command, which is more versatile. +@node ntpd keyfile +@subsection keyfile option (-k) +@cindex ntpd-keyfile + +This is the ``path to symmetric keys'' option. +This option takes a string argument. +Specify the name and path of the symmetric key file. +@file{/etc/ntp.keys} +is the default. +This is the same operation as the +@code{keys} @kbd{keyfile} +configuration file directive. +@node ntpd logfile +@subsection logfile option (-l) +@cindex ntpd-logfile + +This is the ``path to the log file'' option. +This option takes a string argument. +Specify the name and path of the log file. +The default is the system log file. +This is the same operation as the +@code{logfile} @kbd{logfile} +configuration file directive. +@node ntpd novirtualips +@subsection novirtualips option (-L) +@cindex ntpd-novirtualips + +This is the ``do not listen to virtual interfaces'' option. +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file @code{interface} command, which +is more versatile. +@node ntpd modifymmtimer +@subsection modifymmtimer option (-M) +@cindex ntpd-modifymmtimer + +This is the ``modify multimedia timer (windows only)'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{SYS_WINNT} during the compilation. +@end itemize + +Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. +@node ntpd nice +@subsection nice option (-N) +@cindex ntpd-nice + +This is the ``run at high priority'' option. +To the extent permitted by the operating system, run +@code{ntpd} +at the highest priority. +@node ntpd pidfile +@subsection pidfile option (-p) +@cindex ntpd-pidfile + +This is the ``path to the pid file'' option. +This option takes a string argument. +Specify the name and path of the file used to record +@code{ntpd}'s +process ID. +This is the same operation as the +@code{pidfile} @kbd{pidfile} +configuration file directive. +@node ntpd priority +@subsection priority option (-P) +@cindex ntpd-priority + +This is the ``process priority'' option. +This option takes a number argument. +To the extent permitted by the operating system, run +@code{ntpd} +at the specified +@code{sched_setscheduler(SCHED_FIFO)} +priority. +@node ntpd quit +@subsection quit option (-q) +@cindex ntpd-quit + +This is the ``set the time and quit'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +saveconfigquit, wait-sync. +@end itemize + +@code{ntpd} +will not daemonize and will exit after the clock is first +synchronized. This behavior mimics that of the +@code{ntpdate} +program, which will soon be replaced with a shell script. +The +@code{-g} +and +@code{-x} +options can be used with this option. +Note: The kernel time discipline is disabled with this option. +@node ntpd propagationdelay +@subsection propagationdelay option (-r) +@cindex ntpd-propagationdelay + +This is the ``broadcast/propagation delay'' option. +This option takes a string argument. +Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. +@node ntpd saveconfigquit +@subsection saveconfigquit option +@cindex ntpd-saveconfigquit + +This is the ``save parsed configuration and quit'' option. +This option takes a string argument. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{SAVECONFIG} during the compilation. +@item +must not appear in combination with any of the following options: +quit, wait-sync. +@end itemize + +Cause @code{ntpd} to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. +@node ntpd statsdir +@subsection statsdir option (-s) +@cindex ntpd-statsdir + +This is the ``statistics file location'' option. +This option takes a string argument. +Specify the directory path for files created by the statistics facility. +This is the same operation as the +@code{statsdir} @kbd{statsdir} +configuration file directive. +@node ntpd trustedkey +@subsection trustedkey option (-t) +@cindex ntpd-trustedkey + +This is the ``trusted key number'' option. +This option takes a string argument @file{tkey}. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + +Add the specified key number to the trusted key list. +@node ntpd user +@subsection user option (-u) +@cindex ntpd-user + +This is the ``run as userid (or userid:groupid)'' option. +This option takes a string argument. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{HAVE_DROPROOT} during the compilation. +@end itemize + +Specify a user, and optionally a group, to switch to. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +@code{--enable-clockctl}) or Linux (configure with +@code{--enable-linuxcaps}) or Solaris (configure with @code{--enable-solarisprivs}). +@node ntpd updateinterval +@subsection updateinterval option (-U) +@cindex ntpd-updateinterval + +This is the ``interval in seconds between scans for new or dropped interfaces'' option. +This option takes a number argument. +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. +@node ntpd wait-sync +@subsection wait-sync option (-w) +@cindex ntpd-wait-sync + +This is the ``seconds to wait for first clock sync'' option. +This option takes a number argument. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{HAVE_WORKING_FORK} during the compilation. +@item +must not appear in combination with any of the following options: +nofork, quit, saveconfigquit. +@end itemize + +If greater than zero, alters @code{ntpd}'s behavior when forking to +daemonize. Instead of exiting with status 0 immediately after +the fork, the parent waits up to the specified number of +seconds for the child to first synchronize the clock. The exit +status is zero (success) if the clock was synchronized, +otherwise it is @code{ETIMEDOUT}. +This provides the option for a script starting @code{ntpd} to easily +wait for the first set of the clock before proceeding. +@node ntpd slew +@subsection slew option (-x) +@cindex ntpd-slew + +This is the ``slew up to 600 seconds'' option. +Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. +This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. +Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. +Thus, an adjustment as much as 600 s will take almost 14 days to complete. +This option can be used with the +@code{-g} +and +@code{-q} +options. +See the +@code{tinker} +configuration file directive for other options. +Note: The kernel time discipline is disabled with this option. +@node ntpd usepcc +@subsection usepcc option +@cindex ntpd-usepcc + +This is the ``use cpu cycle counter (windows only)'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{SYS_WINNT} during the compilation. +@end itemize + +Attempt to substitute the CPU counter for @code{QueryPerformanceCounter}. +The CPU counter and @code{QueryPerformanceCounter} are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. +@node ntpd pccfreq +@subsection pccfreq option +@cindex ntpd-pccfreq + +This is the ``force cpu cycle counter use (windows only)'' option. +This option takes a string argument. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{SYS_WINNT} during the compilation. +@end itemize + +Force substitution the CPU counter for @code{QueryPerformanceCounter}. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). +@node ntpd mdns +@subsection mdns option (-m) +@cindex ntpd-mdns + +This is the ``register with mdns as a ntp server'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must be compiled in by defining @code{HAVE_DNSREGISTRATION} during the compilation. +@end itemize + +Registers as an NTP server with the local mDNS server which allows +the server to be discovered via mDNS client lookup. + + +@node ntpd config +@subsection presetting/configuring ntpd + +Any option that is not marked as @i{not presettable} may be preset by +loading values from environment variables named @code{NTPD} and @code{NTPD_}. @code{} must be one of +the options listed above in upper case and segmented with underscores. +The @code{NTPD} variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + + +The command line options relating to configuration and/or usage help are: + +@subsubheading version (-) + +Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +@table @samp +@item version +Only print the version. This is the default. +@item copyright +Name the copyright usage licensing terms. +@item verbose +Print the full copyright usage licensing terms. +@end table + +@node ntpd exit status +@subsection ntpd exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table +@node ntpd Usage +@subsection ntpd Usage +@node ntpd Files +@subsection ntpd Files +@node ntpd See Also +@subsection ntpd See Also +@node ntpd Bugs +@subsection ntpd Bugs +@node ntpd Notes +@subsection ntpd Notes diff --git a/contrib/ntp/ntpd/keyword-gen-utd b/contrib/ntp/ntpd/keyword-gen-utd new file mode 100644 index 000000000..467351b65 --- /dev/null +++ b/contrib/ntp/ntpd/keyword-gen-utd @@ -0,0 +1 @@ + * Generated 2015-06-25 03:57:00 UTC diff_ignore_line diff --git a/contrib/ntp/ntpd/keyword-gen.c b/contrib/ntp/ntpd/keyword-gen.c new file mode 100644 index 000000000..42e94973f --- /dev/null +++ b/contrib/ntp/ntpd/keyword-gen.c @@ -0,0 +1,755 @@ +/* + * keyword-gen.c -- generate keyword scanner finite state machine and + * keyword_text array. + * + * This program is run to generate ntp_keyword.h + * After making a change here, two output files should be committed at + * the same time as keyword-gen.c: + * ntp_keyword.h + * keyword-gen-utd + * + * keyword-gen-utd is a sentinel used by Makefile.am to avoid compiling + * keyword_gen.c and generating ntp_keyword.h if the input keyword-gen.c + * has not changed. This is not solely an optimization, it also breaks + * a dependency chain that otherwise would cause programs to be compiled + * when running "make dist" or "make distdir". We want these to package + * the existing source without building anything but a tarball. See + * [Bug 1470]. + */ +#include +#include +#include +#include + +#include +#include +#include +#include "ntp_scanner.h" +#include "ntp_parser.h" + + +/* Define a structure to hold a (keyword, token) pair */ +struct key_tok { + char * key; /* Keyword */ + u_short token; /* Associated Token */ + follby followedby; /* nonzero indicates the next token(s) + forced to be string(s) */ +}; + +struct key_tok ntp_keywords[] = { +{ "...", T_Ellipsis, FOLLBY_TOKEN }, +{ "allpeers", T_Allpeers, FOLLBY_TOKEN }, +{ "automax", T_Automax, FOLLBY_TOKEN }, +{ "broadcast", T_Broadcast, FOLLBY_STRING }, +{ "broadcastclient", T_Broadcastclient, FOLLBY_TOKEN }, +{ "broadcastdelay", T_Broadcastdelay, FOLLBY_TOKEN }, +{ "ctl", T_Ctl, FOLLBY_TOKEN }, +{ "disable", T_Disable, FOLLBY_TOKEN }, +{ "driftfile", T_Driftfile, FOLLBY_STRING }, +{ "dscp", T_Dscp, FOLLBY_TOKEN }, +{ "enable", T_Enable, FOLLBY_TOKEN }, +{ "end", T_End, FOLLBY_TOKEN }, +{ "filegen", T_Filegen, FOLLBY_TOKEN }, +{ "fudge", T_Fudge, FOLLBY_STRING }, +{ "io", T_Io, FOLLBY_TOKEN }, +{ "includefile", T_Includefile, FOLLBY_STRING }, +{ "leapfile", T_Leapfile, FOLLBY_STRING }, +{ "leapsmearinterval", T_Leapsmearinterval, FOLLBY_TOKEN }, +{ "logconfig", T_Logconfig, FOLLBY_STRINGS_TO_EOC }, +{ "logfile", T_Logfile, FOLLBY_STRING }, +{ "manycastclient", T_Manycastclient, FOLLBY_STRING }, +{ "manycastserver", T_Manycastserver, FOLLBY_STRINGS_TO_EOC }, +{ "mem", T_Mem, FOLLBY_TOKEN }, +{ "multicastclient", T_Multicastclient, FOLLBY_STRINGS_TO_EOC }, +{ "peer", T_Peer, FOLLBY_STRING }, +{ "phone", T_Phone, FOLLBY_STRINGS_TO_EOC }, +{ "pidfile", T_Pidfile, FOLLBY_STRING }, +{ "pool", T_Pool, FOLLBY_STRING }, +{ "discard", T_Discard, FOLLBY_TOKEN }, +{ "reset", T_Reset, FOLLBY_TOKEN }, +{ "restrict", T_Restrict, FOLLBY_TOKEN }, +{ "rlimit", T_Rlimit, FOLLBY_TOKEN }, +{ "server", T_Server, FOLLBY_STRING }, +{ "setvar", T_Setvar, FOLLBY_STRING }, +{ "statistics", T_Statistics, FOLLBY_TOKEN }, +{ "statsdir", T_Statsdir, FOLLBY_STRING }, +{ "sys", T_Sys, FOLLBY_TOKEN }, +{ "tick", T_Tick, FOLLBY_TOKEN }, +{ "timer", T_Timer, FOLLBY_TOKEN }, +{ "tinker", T_Tinker, FOLLBY_TOKEN }, +{ "tos", T_Tos, FOLLBY_TOKEN }, +{ "trap", T_Trap, FOLLBY_STRING }, +{ "unconfig", T_Unconfig, FOLLBY_STRING }, +{ "unpeer", T_Unpeer, FOLLBY_STRING }, +/* authentication_command */ +{ "controlkey", T_ControlKey, FOLLBY_TOKEN }, +{ "crypto", T_Crypto, FOLLBY_TOKEN }, +{ "keys", T_Keys, FOLLBY_STRING }, +{ "keysdir", T_Keysdir, FOLLBY_STRING }, +{ "ntpsigndsocket", T_NtpSignDsocket, FOLLBY_STRING }, +{ "requestkey", T_Requestkey, FOLLBY_TOKEN }, +{ "revoke", T_Revoke, FOLLBY_TOKEN }, +{ "trustedkey", T_Trustedkey, FOLLBY_TOKEN }, +/* IPv4/IPv6 protocol override flag */ +{ "-4", T_Ipv4_flag, FOLLBY_TOKEN }, +{ "-6", T_Ipv6_flag, FOLLBY_TOKEN }, +/* option */ +{ "autokey", T_Autokey, FOLLBY_TOKEN }, +{ "burst", T_Burst, FOLLBY_TOKEN }, +{ "iburst", T_Iburst, FOLLBY_TOKEN }, +{ "key", T_Key, FOLLBY_TOKEN }, +{ "maxpoll", T_Maxpoll, FOLLBY_TOKEN }, +{ "mdnstries", T_Mdnstries, FOLLBY_TOKEN }, +{ "minpoll", T_Minpoll, FOLLBY_TOKEN }, +{ "mode", T_Mode, FOLLBY_TOKEN }, +{ "noselect", T_Noselect, FOLLBY_TOKEN }, +{ "preempt", T_Preempt, FOLLBY_TOKEN }, +{ "true", T_True, FOLLBY_TOKEN }, +{ "prefer", T_Prefer, FOLLBY_TOKEN }, +{ "ttl", T_Ttl, FOLLBY_TOKEN }, +{ "version", T_Version, FOLLBY_TOKEN }, +{ "xleave", T_Xleave, FOLLBY_TOKEN }, +/* crypto_command */ +{ "host", T_Host, FOLLBY_STRING }, +{ "ident", T_Ident, FOLLBY_STRING }, +{ "pw", T_Pw, FOLLBY_STRING }, +{ "randfile", T_Randfile, FOLLBY_STRING }, +{ "digest", T_Digest, FOLLBY_STRING }, +/*** MONITORING COMMANDS ***/ +/* stat */ +{ "clockstats", T_Clockstats, FOLLBY_TOKEN }, +{ "cryptostats", T_Cryptostats, FOLLBY_TOKEN }, +{ "loopstats", T_Loopstats, FOLLBY_TOKEN }, +{ "peerstats", T_Peerstats, FOLLBY_TOKEN }, +{ "rawstats", T_Rawstats, FOLLBY_TOKEN }, +{ "sysstats", T_Sysstats, FOLLBY_TOKEN }, +{ "protostats", T_Protostats, FOLLBY_TOKEN }, +{ "timingstats", T_Timingstats, FOLLBY_TOKEN }, +/* filegen_option */ +{ "file", T_File, FOLLBY_STRING }, +{ "link", T_Link, FOLLBY_TOKEN }, +{ "nolink", T_Nolink, FOLLBY_TOKEN }, +{ "type", T_Type, FOLLBY_TOKEN }, +/* filegen_type */ +{ "age", T_Age, FOLLBY_TOKEN }, +{ "day", T_Day, FOLLBY_TOKEN }, +{ "month", T_Month, FOLLBY_TOKEN }, +{ "none", T_None, FOLLBY_TOKEN }, +{ "pid", T_Pid, FOLLBY_TOKEN }, +{ "week", T_Week, FOLLBY_TOKEN }, +{ "year", T_Year, FOLLBY_TOKEN }, +/*** ORPHAN MODE COMMANDS ***/ +/* tos_option */ +{ "minclock", T_Minclock, FOLLBY_TOKEN }, +{ "maxclock", T_Maxclock, FOLLBY_TOKEN }, +{ "minsane", T_Minsane, FOLLBY_TOKEN }, +{ "floor", T_Floor, FOLLBY_TOKEN }, +{ "ceiling", T_Ceiling, FOLLBY_TOKEN }, +{ "cohort", T_Cohort, FOLLBY_TOKEN }, +{ "mindist", T_Mindist, FOLLBY_TOKEN }, +{ "maxdist", T_Maxdist, FOLLBY_TOKEN }, +{ "beacon", T_Beacon, FOLLBY_TOKEN }, +{ "orphan", T_Orphan, FOLLBY_TOKEN }, +{ "orphanwait", T_Orphanwait, FOLLBY_TOKEN }, +{ "nonvolatile", T_Nonvolatile, FOLLBY_TOKEN }, +/* access_control_flag */ +{ "default", T_Default, FOLLBY_TOKEN }, +{ "source", T_Source, FOLLBY_TOKEN }, +{ "flake", T_Flake, FOLLBY_TOKEN }, +{ "ignore", T_Ignore, FOLLBY_TOKEN }, +{ "limited", T_Limited, FOLLBY_TOKEN }, +{ "mssntp", T_Mssntp, FOLLBY_TOKEN }, +{ "kod", T_Kod, FOLLBY_TOKEN }, +{ "lowpriotrap", T_Lowpriotrap, FOLLBY_TOKEN }, +{ "mask", T_Mask, FOLLBY_TOKEN }, +{ "nomodify", T_Nomodify, FOLLBY_TOKEN }, +{ "nomrulist", T_Nomrulist, FOLLBY_TOKEN }, +{ "nopeer", T_Nopeer, FOLLBY_TOKEN }, +{ "noquery", T_Noquery, FOLLBY_TOKEN }, +{ "noserve", T_Noserve, FOLLBY_TOKEN }, +{ "notrap", T_Notrap, FOLLBY_TOKEN }, +{ "notrust", T_Notrust, FOLLBY_TOKEN }, +{ "ntpport", T_Ntpport, FOLLBY_TOKEN }, +/* discard_option */ +{ "average", T_Average, FOLLBY_TOKEN }, +{ "minimum", T_Minimum, FOLLBY_TOKEN }, +{ "monitor", T_Monitor, FOLLBY_TOKEN }, +/* mru_option */ +{ "incalloc", T_Incalloc, FOLLBY_TOKEN }, +{ "incmem", T_Incmem, FOLLBY_TOKEN }, +{ "initalloc", T_Initalloc, FOLLBY_TOKEN }, +{ "initmem", T_Initmem, FOLLBY_TOKEN }, +{ "mindepth", T_Mindepth, FOLLBY_TOKEN }, +{ "maxage", T_Maxage, FOLLBY_TOKEN }, +{ "maxdepth", T_Maxdepth, FOLLBY_TOKEN }, +{ "maxmem", T_Maxmem, FOLLBY_TOKEN }, +{ "mru", T_Mru, FOLLBY_TOKEN }, +/* fudge_factor */ +{ "abbrev", T_Abbrev, FOLLBY_STRING }, +{ "flag1", T_Flag1, FOLLBY_TOKEN }, +{ "flag2", T_Flag2, FOLLBY_TOKEN }, +{ "flag3", T_Flag3, FOLLBY_TOKEN }, +{ "flag4", T_Flag4, FOLLBY_TOKEN }, +{ "refid", T_Refid, FOLLBY_STRING }, +{ "stratum", T_Stratum, FOLLBY_TOKEN }, +{ "time1", T_Time1, FOLLBY_TOKEN }, +{ "time2", T_Time2, FOLLBY_TOKEN }, +/* system_option */ +{ "auth", T_Auth, FOLLBY_TOKEN }, +{ "bclient", T_Bclient, FOLLBY_TOKEN }, +{ "calibrate", T_Calibrate, FOLLBY_TOKEN }, +{ "kernel", T_Kernel, FOLLBY_TOKEN }, +{ "ntp", T_Ntp, FOLLBY_TOKEN }, +{ "mode7", T_Mode7, FOLLBY_TOKEN }, +{ "stats", T_Stats, FOLLBY_TOKEN }, +/* rlimit_option */ +{ "memlock", T_Memlock, FOLLBY_TOKEN }, +{ "stacksize", T_Stacksize, FOLLBY_TOKEN }, +{ "filenum", T_Filenum, FOLLBY_TOKEN }, +/* tinker_option */ +{ "step", T_Step, FOLLBY_TOKEN }, +{ "stepback", T_Stepback, FOLLBY_TOKEN }, +{ "stepfwd", T_Stepfwd, FOLLBY_TOKEN }, +{ "panic", T_Panic, FOLLBY_TOKEN }, +{ "dispersion", T_Dispersion, FOLLBY_TOKEN }, +{ "stepout", T_Stepout, FOLLBY_TOKEN }, +{ "allan", T_Allan, FOLLBY_TOKEN }, +{ "huffpuff", T_Huffpuff, FOLLBY_TOKEN }, +{ "freq", T_Freq, FOLLBY_TOKEN }, +/* miscellaneous_command */ +{ "port", T_Port, FOLLBY_TOKEN }, +{ "interface", T_Interface, FOLLBY_TOKEN }, +{ "saveconfigdir", T_Saveconfigdir, FOLLBY_STRING }, +/* interface_command (ignore and interface already defined) */ +{ "nic", T_Nic, FOLLBY_TOKEN }, +{ "all", T_All, FOLLBY_TOKEN }, +{ "ipv4", T_Ipv4, FOLLBY_TOKEN }, +{ "ipv6", T_Ipv6, FOLLBY_TOKEN }, +{ "wildcard", T_Wildcard, FOLLBY_TOKEN }, +{ "listen", T_Listen, FOLLBY_TOKEN }, +{ "drop", T_Drop, FOLLBY_TOKEN }, +/* simulator commands */ +{ "simulate", T_Simulate, FOLLBY_TOKEN }, +{ "simulation_duration",T_Sim_Duration, FOLLBY_TOKEN }, +{ "beep_delay", T_Beep_Delay, FOLLBY_TOKEN }, +{ "duration", T_Duration, FOLLBY_TOKEN }, +{ "server_offset", T_Server_Offset, FOLLBY_TOKEN }, +{ "freq_offset", T_Freq_Offset, FOLLBY_TOKEN }, +{ "wander", T_Wander, FOLLBY_TOKEN }, +{ "jitter", T_Jitter, FOLLBY_TOKEN }, +{ "prop_delay", T_Prop_Delay, FOLLBY_TOKEN }, +{ "proc_delay", T_Proc_Delay, FOLLBY_TOKEN }, +}; + +typedef struct big_scan_state_tag { + char ch; /* Character this state matches on */ + char followedby; /* Forces next token(s) to T_String */ + u_short finishes_token; /* nonzero ID if last keyword char */ + u_short match_next_s; /* next state to check matching ch */ + u_short other_next_s; /* next state to check if not ch */ +} big_scan_state; + +/* + * Note: to increase MAXSTATES beyond 2048, be aware it is currently + * crammed into 11 bits in scan_state form. Raising to 4096 would be + * relatively easy by storing the followedby value in a separate + * array with one entry per token, and shrinking the char value to + * 7 bits to free a bit for accepting/non-accepting. More than 4096 + * states will require expanding scan_state beyond 32 bits each. + */ +#define MAXSTATES 2048 +#define MAX_TOK_LEN 63 + +const char * current_keyword;/* for error reporting */ +big_scan_state sst[MAXSTATES]; /* scanner FSM state entries */ +u_short sst_highwater; /* next entry index to consider */ +char * symb[1024]; /* map token ID to symbolic name */ + +/* for libntp */ +const char * progname = "keyword-gen"; + +int main (int, char **); +static void generate_preamble (void); +static void generate_fsm (void); +static void generate_token_text (void); +static u_short create_keyword_scanner (void); +static u_short create_scan_states (char *, u_short, follby, u_short); +int compare_key_tok_id (const void *, const void *); +int compare_key_tok_text (const void *, const void *); +void populate_symb (char *); +const char * symbname (u_short); + + +int main(int argc, char **argv) +{ + if (argc < 2) { + fprintf(stderr, "Usage:\n%s t_header.h\n", argv[0]); + exit(1); + } + debug = 1; + + populate_symb(argv[1]); + + generate_preamble(); + generate_token_text(); + generate_fsm(); + + return 0; +} + + +static void +generate_preamble(void) +{ + time_t now; + char timestamp[128]; + char preamble[] = +"/*\n" +" * ntp_keyword.h\n" +" * \n" +" * NOTE: edit this file with caution, it is generated by keyword-gen.c\n" +" *\t Generated %s UTC diff_ignore_line\n" +" *\n" +" */\n" +"#include \"ntp_scanner.h\"\n" +"#include \"ntp_parser.h\"\n" +"\n"; + + time(&now); + if (!strftime(timestamp, sizeof(timestamp), + "%Y-%m-%d %H:%M:%S", gmtime(&now))) + timestamp[0] = '\0'; + + printf(preamble, timestamp); +} + + +static void +generate_fsm(void) +{ + char rprefix[MAX_TOK_LEN + 1]; + char prefix[MAX_TOK_LEN + 1]; + char token_id_comment[16 + MAX_TOK_LEN + 1]; + size_t prefix_len; + char *p; + char *r; + u_short initial_state; + u_short this_state; + u_short state; + u_short i; + u_short token; + + /* + * Sort ntp_keywords in alphabetical keyword order. This is + * not necessary, but minimizes nonfunctional changes in the + * generated finite state machine when keywords are modified. + */ + qsort(ntp_keywords, COUNTOF(ntp_keywords), + sizeof(ntp_keywords[0]), compare_key_tok_text); + + /* + * To save space, reserve the state array entry matching each + * token number for its terminal state, so the token identifier + * does not need to be stored in each state, but can be + * recovered trivially. To mark the entry reserved, + * finishes_token is nonzero. + */ + + for (i = 0; i < COUNTOF(ntp_keywords); i++) { + token = ntp_keywords[i].token; + if (1 > token || token >= COUNTOF(sst)) { + fprintf(stderr, + "keyword-gen sst[%u] too small " + "for keyword '%s' id %d\n", + (int)COUNTOF(sst), + ntp_keywords[i].key, + token); + exit(4); + } + sst[token].finishes_token = token; + } + + initial_state = create_keyword_scanner(); + + fprintf(stderr, + "%d keywords consumed %d states of %d max.\n", + (int)COUNTOF(ntp_keywords), + sst_highwater - 1, + (int)COUNTOF(sst) - 1); + + printf("#define SCANNER_INIT_S %d\n\n", initial_state); + + printf("const scan_state sst[%d] = {\n" + "/*SS_T( ch,\tf-by, match, other ),\t\t\t\t */\n" + " 0,\t\t\t\t /* %5d %-17s */\n", + sst_highwater, + 0, ""); + + for (i = 1; i < sst_highwater; i++) { + + /* verify fields will fit */ + if (sst[i].followedby & ~0x3) { + fprintf(stderr, + "keyword-gen internal error " + "sst[%d].followedby %d too big\n", + i, sst[i].followedby); + exit(7); + } + + if (sst_highwater <= sst[i].match_next_s + || sst[i].match_next_s & ~0x7ff) { + fprintf(stderr, + "keyword-gen internal error " + "sst[%d].match_next_s %d too big\n", + i, sst[i].match_next_s); + exit(8); + } + + if (sst_highwater <= sst[i].other_next_s + || sst[i].other_next_s & ~0x7ff) { + fprintf(stderr, + "keyword-gen internal error " + "sst[%d].other_next_s %d too big\n", + i, sst[i].other_next_s); + exit(9); + } + + if (sst[i].finishes_token) { + snprintf(token_id_comment, + sizeof(token_id_comment), "%5d %-17s", + i, symbname(sst[i].finishes_token)); + if (i != sst[i].finishes_token) { + fprintf(stderr, + "keyword-gen internal error " + "entry %d finishes token %d\n", + i, sst[i].finishes_token); + exit(5); + } + } else { + /* + * Determine the keyword prefix that leads to this + * state. This is expensive but keyword-gen is run + * only when it changes. Distributing keyword-gen-utd + * achieves that, which is why it must be committed + * at the same time as keyword-gen.c and ntp_keyword.h. + * + * Scan the state array iteratively looking for a state + * which leads to the current one, collecting matching + * characters along the way. There is only one such + * path back to the starting state given the way our + * scanner state machine is built and the practice of + * using the spelling of the keyword as its T_* token + * identifier, which results in never having two + * spellings result in the same T_* value. + */ + prefix_len = 0; + this_state = i; + do { + for (state = 1; state < sst_highwater; state++) + if (sst[state].other_next_s == this_state) { + this_state = state; + break; + } else if (sst[state].match_next_s == this_state) { + this_state = state; + rprefix[prefix_len] = sst[state].ch; + prefix_len++; + break; + } + } while (this_state != initial_state); + + if (prefix_len) { + /* reverse rprefix into prefix */ + p = prefix + prefix_len; + r = rprefix; + while (r < rprefix + prefix_len) + *--p = *r++; + } + prefix[prefix_len] = '\0'; + + snprintf(token_id_comment, + sizeof(token_id_comment), "%5d %-17s", + i, (initial_state == i) + ? "[initial state]" + : prefix); + } + + printf(" S_ST( '%c',\t%d, %5u, %5u )%s /* %s */\n", + sst[i].ch, + sst[i].followedby, + sst[i].match_next_s, + sst[i].other_next_s, + (i + 1 < sst_highwater) + ? "," + : " ", + token_id_comment); + } + + printf("};\n\n"); +} + + +/* Define a function to create the states of the scanner. This function + * is used by the create_keyword_scanner function below. + * + * This function takes a suffix of a keyword, the token to be returned on + * recognizing the complete keyword, and any pre-existing state that exists + * for some other keyword that has the same prefix as the current one. + */ +static u_short +create_scan_states( + char * text, + u_short token, + follby followedby, + u_short prev_state + ) +{ + u_short my_state; + u_short return_state; + u_short prev_char_s; + u_short curr_char_s; + + return_state = prev_state; + curr_char_s = prev_state; + prev_char_s = 0; + + /* Find the correct position to insert the state. + * All states should be in alphabetical order + */ + while (curr_char_s && (text[0] < sst[curr_char_s].ch)) { + prev_char_s = curr_char_s; + curr_char_s = sst[curr_char_s].other_next_s; + } + + /* + * Check if a previously seen keyword has the same prefix as + * the current keyword. If so, simply use the state for that + * keyword as my_state, otherwise, allocate a new state. + */ + if (curr_char_s && (text[0] == sst[curr_char_s].ch)) { + my_state = curr_char_s; + if ('\0' == text[1]) { + fprintf(stderr, + "Duplicate entries for keyword '%s' in" + " keyword_gen.c ntp_keywords[].\n", + current_keyword); + exit(2); + } + } else { + do + my_state = sst_highwater++; + while (my_state < COUNTOF(sst) + && sst[my_state].finishes_token); + if (my_state >= COUNTOF(sst)) { + fprintf(stderr, + "fatal, keyword scanner state array " + "sst[%d] is too small, modify\n" + "keyword-gen.c to increase.\n", + (int)COUNTOF(sst)); + exit(3); + } + /* Store the next character of the keyword */ + sst[my_state].ch = text[0]; + sst[my_state].other_next_s = curr_char_s; + sst[my_state].followedby = FOLLBY_NON_ACCEPTING; + + if (prev_char_s) + sst[prev_char_s].other_next_s = my_state; + else + return_state = my_state; + } + + /* Check if the next character is '\0'. + * If yes, we are done with the recognition and this is an accepting + * state. + * If not, we need to continue scanning + */ + if ('\0' == text[1]) { + sst[my_state].finishes_token = (u_short)token; + sst[my_state].followedby = (char)followedby; + + if (sst[token].finishes_token != (u_short)token) { + fprintf(stderr, + "fatal, sst[%d] not reserved for %s.\n", + token, symbname(token)); + exit(6); + } + /* relocate so token id is sst[] index */ + if (my_state != token) { + sst[token] = sst[my_state]; + ZERO(sst[my_state]); + do + sst_highwater--; + while (sst[sst_highwater].finishes_token); + my_state = token; + if (prev_char_s) + sst[prev_char_s].other_next_s = my_state; + else + return_state = my_state; + } + } else + sst[my_state].match_next_s = + create_scan_states( + &text[1], + token, + followedby, + sst[my_state].match_next_s); + + return return_state; +} + + +/* Define a function that takes a list of (keyword, token) values and + * creates a keywords scanner out of it. + */ + +static u_short +create_keyword_scanner(void) +{ + u_short scanner; + u_short i; + + sst_highwater = 1; /* index 0 invalid, unused */ + scanner = 0; + + for (i = 0; i < COUNTOF(ntp_keywords); i++) { + current_keyword = ntp_keywords[i].key; + scanner = + create_scan_states( + ntp_keywords[i].key, + ntp_keywords[i].token, + ntp_keywords[i].followedby, + scanner); + } + + return scanner; +} + + +static void +generate_token_text(void) +{ + u_short lowest_id; + u_short highest_id; + u_short id_count; + u_short id; + u_short i; + + /* sort ntp_keywords in token ID order */ + qsort(ntp_keywords, COUNTOF(ntp_keywords), + sizeof(ntp_keywords[0]), compare_key_tok_id); + + lowest_id = ntp_keywords[0].token; + highest_id = ntp_keywords[COUNTOF(ntp_keywords) - 1].token; + id_count = highest_id - lowest_id + 1; + + printf("#define LOWEST_KEYWORD_ID %d\n\n", lowest_id); + + printf("const char * const keyword_text[%d] = {", id_count); + + id = lowest_id; + i = 0; + while (i < COUNTOF(ntp_keywords)) { + while (id < ntp_keywords[i].token) { + printf(",\n\t/* %-5d %5d %20s */\tNULL", + id - lowest_id, id, symbname(id)); + id++; + } + if (i > 0) + printf(","); + printf("\n\t/* %-5d %5d %20s */\t\"%s\"", + id - lowest_id, id, symbname(id), + ntp_keywords[i].key); + i++; + id++; + } + + printf("\n};\n\n"); +} + + +int +compare_key_tok_id( + const void *a1, + const void *a2 + ) +{ + const struct key_tok *p1 = a1; + const struct key_tok *p2 = a2; + + if (p1->token == p2->token) + return 0; + + if (p1->token < p2->token) + return -1; + else + return 1; +} + + +int +compare_key_tok_text( + const void *a1, + const void *a2 + ) +{ + const struct key_tok *p1 = a1; + const struct key_tok *p2 = a2; + + return strcmp(p1->key, p2->key); +} + + +/* + * populate_symb() - populate symb[] lookup array with symbolic token + * names such that symb[T_Age] == "T_Age", etc. + */ +void +populate_symb( + char *header_file + ) +{ + FILE * yh; + char line[2 * MAX_TOK_LEN]; + char name[2 * MAX_TOK_LEN]; + int token; + + yh = fopen(header_file, "r"); + if (NULL == yh) { + perror("unable to open yacc/bison header file"); + exit(4); + } + + while (NULL != fgets(line, sizeof(line), yh)) + if (2 == sscanf(line, "#define %s %d", name, &token) + && 'T' == name[0] && '_' == name[1] && token >= 0 + && token < COUNTOF(symb)) { + + symb[token] = estrdup(name); + if (strlen(name) > MAX_TOK_LEN) { + fprintf(stderr, + "MAX_TOK_LEN %d too small for '%s'\n" + "Edit keyword-gen.c to raise.\n", + MAX_TOK_LEN, name); + exit(10); + } + } + fclose(yh); +} + + +const char * +symbname( + u_short token + ) +{ + char *name; + + if (token < COUNTOF(symb) && symb[token] != NULL) { + name = symb[token]; + } else { + LIB_GETBUF(name); + snprintf(name, LIB_BUFLENGTH, "%d", token); + } + + return name; +} diff --git a/contrib/ntp/ntpd/ntp.conf.5man b/contrib/ntp/ntpd/ntp.conf.5man new file mode 100644 index 000000000..ee457df4c --- /dev/null +++ b/contrib/ntp/ntpd/ntp.conf.5man @@ -0,0 +1,3055 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntp.conf 5man "21 Oct 2015" "4.2.8p4" "File Formats" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-9oaqYI/ag-OpaiXI) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:01 PM by AutoGen 5.18.5 +.\" From the definitions ntp.conf.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntp.conf\fP +\- Network Time Protocol (NTP) daemon configuration file format +.SH SYNOPSIS +\f\*[B-Font]ntp.conf\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The +\f\*[B-Font]ntp.conf\fP +configuration file is read at initial startup by the +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +daemon in order to specify the synchronization sources, +modes and other related information. +Usually, it is installed in the +\fI/etc\f[] +directory, +but could be installed elsewhere +(see the daemon's +\f\*[B-Font]\-c\f[] +command line option). +.sp \n(Ppu +.ne 2 + +The file format is similar to other +UNIX +configuration files. +Comments begin with a +\[oq]#\[cq] +character and extend to the end of the line; +blank lines are ignored. +Configuration commands consist of an initial keyword +followed by a list of arguments, +some of which may be optional, separated by whitespace. +Commands may not be continued over multiple lines. +Arguments may be host names, +host addresses written in numeric, dotted-quad form, +integers, floating point numbers (when specifying times in seconds) +and text strings. +.sp \n(Ppu +.ne 2 + +The rest of this page describes the configuration and control options. +The +"Notes on Configuring NTP and Setting up an NTP Subnet" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +contains an extended discussion of these options. +In addition to the discussion of general +\fIConfiguration\f[] \fIOptions\f[], +there are sections describing the following supported functionality +and the options used to control it: +.IP \fB\(bu\fP 2 +\fIAuthentication\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIMonitoring\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIAccess\f[] \fIControl\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIAutomatic\f[] \fINTP\f[] \fIConfiguration\f[] \fIOptions\f[] +.IP \fB\(bu\fP 2 +\fIReference\f[] \fIClock\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIMiscellaneous\f[] \fIOptions\f[] +.PP +.sp \n(Ppu +.ne 2 + +Following these is a section describing +\fIMiscellaneous\f[] \fIOptions\f[]. +While there is a rich set of options available, +the only required option is one or more +\f\*[B-Font]pool\f[], +\f\*[B-Font]server\f[], +\f\*[B-Font]peer\f[], +\f\*[B-Font]broadcast\f[] +or +\f\*[B-Font]manycastclient\f[] +commands. +.SH Configuration Support +Following is a description of the configuration commands in +NTPv4. +These commands have the same basic functions as in NTPv3 and +in some cases new functions and new arguments. +There are two +classes of commands, configuration commands that configure a +persistent association with a remote server or peer or reference +clock, and auxiliary commands that specify environmental variables +that control various related operations. +.SS Configuration Commands +The various modes are determined by the command keyword and the +type of the required IP address. +Addresses are classed by type as +(s) a remote server or peer (IPv4 class A, B and C), (b) the +broadcast address of a local interface, (m) a multicast address (IPv4 +class D), or (r) a reference clock address (127.127.x.x). +Note that +only those options applicable to each command are listed below. +Use +of options not listed may not be caught as an error, but may result +in some weird and even destructive behavior. +.sp \n(Ppu +.ne 2 + +If the Basic Socket Interface Extensions for IPv6 (RFC-2553) +is detected, support for the IPv6 address family is generated +in addition to the default support of the IPv4 address family. +In a few cases, including the reslist billboard generated +by ntpdc, IPv6 addresses are automatically generated. +IPv6 addresses can be identified by the presence of colons +\*[Lq]\&:\*[Rq] +in the address field. +IPv6 addresses can be used almost everywhere where +IPv4 addresses can be used, +with the exception of reference clock addresses, +which are always IPv4. +.sp \n(Ppu +.ne 2 + +Note that in contexts where a host name is expected, a +\f\*[B-Font]\-4\f[] +qualifier preceding +the host name forces DNS resolution to the IPv4 namespace, +while a +\f\*[B-Font]\-6\f[] +qualifier forces DNS resolution to the IPv6 namespace. +See IPv6 references for the +equivalent classes for that address family. +.TP 7 +.NOP \f\*[B-Font]pool\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]burst\f[]] [\f\*[B-Font]iburst\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] +.TP 7 +.NOP \f\*[B-Font]server\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]burst\f[]] [\f\*[B-Font]iburst\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] +.TP 7 +.NOP \f\*[B-Font]peer\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] +.TP 7 +.NOP \f\*[B-Font]broadcast\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]ttl\f[] \f\*[I-Font]ttl\f[]] +.TP 7 +.NOP \f\*[B-Font]manycastclient\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] [\f\*[B-Font]ttl\f[] \f\*[I-Font]ttl\f[]] +.PP +.sp \n(Ppu +.ne 2 + +These five commands specify the time server name or address to +be used and the mode in which to operate. +The +\f\*[I-Font]address\f[] +can be +either a DNS name or an IP address in dotted-quad notation. +Additional information on association behavior can be found in the +"Association Management" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.TP 7 +.NOP \f\*[B-Font]pool\f[] +For type s addresses, this command mobilizes a persistent +client mode association with a number of remote servers. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +.TP 7 +.NOP \f\*[B-Font]server\f[] +For type s and r addresses, this command mobilizes a persistent +client mode association with the specified remote server or local +radio clock. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +This command should +\fInot\f[] +be used for type +b or m addresses. +.TP 7 +.NOP \f\*[B-Font]peer\f[] +For type s addresses (only), this command mobilizes a +persistent symmetric-active mode association with the specified +remote peer. +In this mode the local clock can be synchronized to +the remote peer or the remote peer can be synchronized to the local +clock. +This is useful in a network of servers where, depending on +various failure scenarios, either the local or remote peer may be +the better source of time. +This command should NOT be used for type +b, m or r addresses. +.TP 7 +.NOP \f\*[B-Font]broadcast\f[] +For type b and m addresses (only), this +command mobilizes a persistent broadcast mode association. +Multiple +commands can be used to specify multiple local broadcast interfaces +(subnets) and/or multiple multicast groups. +Note that local +broadcast messages go only to the interface associated with the +subnet specified, but multicast messages go to all interfaces. +In broadcast mode the local server sends periodic broadcast +messages to a client population at the +\f\*[I-Font]address\f[] +specified, which is usually the broadcast address on (one of) the +local network(s) or a multicast address assigned to NTP. +The IANA +has assigned the multicast group address IPv4 224.0.1.1 and +IPv6 ff05::101 (site local) exclusively to +NTP, but other nonconflicting addresses can be used to contain the +messages within administrative boundaries. +Ordinarily, this +specification applies only to the local server operating as a +sender; for operation as a broadcast client, see the +\f\*[B-Font]broadcastclient\f[] +or +\f\*[B-Font]multicastclient\f[] +commands +below. +.TP 7 +.NOP \f\*[B-Font]manycastclient\f[] +For type m addresses (only), this command mobilizes a +manycast client mode association for the multicast address +specified. +In this case a specific address must be supplied which +matches the address used on the +\f\*[B-Font]manycastserver\f[] +command for +the designated manycast servers. +The NTP multicast address +224.0.1.1 assigned by the IANA should NOT be used, unless specific +means are taken to avoid spraying large areas of the Internet with +these messages and causing a possibly massive implosion of replies +at the sender. +The +\f\*[B-Font]manycastserver\f[] +command specifies that the local server +is to operate in client mode with the remote servers that are +discovered as the result of broadcast/multicast messages. +The +client broadcasts a request message to the group address associated +with the specified +\f\*[I-Font]address\f[] +and specifically enabled +servers respond to these messages. +The client selects the servers +providing the best time and continues as with the +\f\*[B-Font]server\f[] +command. +The remaining servers are discarded as if never +heard. +.PP +.sp \n(Ppu +.ne 2 + +Options: +.TP 7 +.NOP \f\*[B-Font]autokey\f[] +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the autokey scheme +described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]burst\f[] +when the server is reachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first and second packets +can be changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to improve timekeeping quality +with the +\f\*[B-Font]server\f[] +command and s addresses. +.TP 7 +.NOP \f\*[B-Font]iburst\f[] +When the server is unreachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first two packets can be +changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to speed the initial synchronization +acquisition with the +\f\*[B-Font]server\f[] +command and s addresses and when +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +is started with the +\f\*[B-Font]\-q\f[] +option. +.TP 7 +.NOP \f\*[B-Font]key\f[] \f\*[I-Font]key\f[] +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the specified +\f\*[I-Font]key\f[] +identifier with values from 1 to 65534, inclusive. +The +default is to include no encryption field. +.TP 7 +.NOP \f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[] +.TP 7 +.NOP \f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[] +These options specify the minimum and maximum poll intervals +for NTP messages, as a power of 2 in seconds +The maximum poll +interval defaults to 10 (1,024 s), but can be increased by the +\f\*[B-Font]maxpoll\f[] +option to an upper limit of 17 (36.4 h). +The +minimum poll interval defaults to 6 (64 s), but can be decreased by +the +\f\*[B-Font]minpoll\f[] +option to a lower limit of 4 (16 s). +.TP 7 +.NOP \f\*[B-Font]noselect\f[] +Marks the server as unused, except for display purposes. +The server is discarded by the selection algroithm. +.TP 7 +.NOP \f\*[B-Font]prefer\f[] +Marks the server as preferred. +All other things being equal, +this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +for further information. +.TP 7 +.NOP \f\*[B-Font]ttl\f[] \f\*[I-Font]ttl\f[] +This option is used only with broadcast server and manycast +client modes. +It specifies the time-to-live +\f\*[I-Font]ttl\f[] +to +use on broadcast server and multicast server and the maximum +\f\*[I-Font]ttl\f[] +for the expanding ring search with manycast +client packets. +Selection of the proper value, which defaults to +127, is something of a black art and should be coordinated with the +network administrator. +.TP 7 +.NOP \f\*[B-Font]version\f[] \f\*[I-Font]version\f[] +Specifies the version number to be used for outgoing NTP +packets. +Versions 1-4 are the choices, with version 4 the +default. +.PP +.SS Auxiliary Commands +.TP 7 +.NOP \f\*[B-Font]broadcastclient\f[] +This command enables reception of broadcast server messages to +any local interface (type b) address. +Upon receiving a message for +the first time, the broadcast client measures the nominal server +propagation delay using a brief client/server exchange with the +server, then enters the broadcast client mode, in which it +synchronizes to succeeding broadcast messages. +Note that, in order +to avoid accidental or malicious disruption in this mode, both the +server and client should operate using symmetric-key or public-key +authentication as described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]manycastserver\f[] \f\*[I-Font]address\f[] \f\*[I-Font]...\f[] +This command enables reception of manycast client messages to +the multicast group address(es) (type m) specified. +At least one +address is required, but the NTP multicast address 224.0.1.1 +assigned by the IANA should NOT be used, unless specific means are +taken to limit the span of the reply and avoid a possibly massive +implosion at the original sender. +Note that, in order to avoid +accidental or malicious disruption in this mode, both the server +and client should operate using symmetric-key or public-key +authentication as described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]multicastclient\f[] \f\*[I-Font]address\f[] \f\*[I-Font]...\f[] +This command enables reception of multicast server messages to +the multicast group address(es) (type m) specified. +Upon receiving +a message for the first time, the multicast client measures the +nominal server propagation delay using a brief client/server +exchange with the server, then enters the broadcast client mode, in +which it synchronizes to succeeding multicast messages. +Note that, +in order to avoid accidental or malicious disruption in this mode, +both the server and client should operate using symmetric-key or +public-key authentication as described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]mdnstries\f[] \f\*[I-Font]number\f[] +If we are participating in mDNS, +after we have synched for the first time +we attempt to register with the mDNS system. +If that registration attempt fails, +we try again at one minute intervals for up to +\f\*[B-Font]mdnstries\f[] +times. +After all, +\f\*[B-Font]ntpd\f[] +may be starting before mDNS. +The default value for +\f\*[B-Font]mdnstries\f[] +is 5. +.PP +.SH Authentication Support +Authentication support allows the NTP client to verify that the +server is in fact known and trusted and not an intruder intending +accidentally or on purpose to masquerade as that server. +The NTPv3 +specification RFC-1305 defines a scheme which provides +cryptographic authentication of received NTP packets. +Originally, +this was done using the Data Encryption Standard (DES) algorithm +operating in Cipher Block Chaining (CBC) mode, commonly called +DES-CBC. +Subsequently, this was replaced by the RSA Message Digest +5 (MD5) algorithm using a private key, commonly called keyed-MD5. +Either algorithm computes a message digest, or one-way hash, which +can be used to verify the server has the correct private key and +key identifier. +.sp \n(Ppu +.ne 2 + +NTPv4 retains the NTPv3 scheme, properly described as symmetric key +cryptography and, in addition, provides a new Autokey scheme +based on public key cryptography. +Public key cryptography is generally considered more secure +than symmetric key cryptography, since the security is based +on a private value which is generated by each server and +never revealed. +With Autokey all key distribution and +management functions involve only public values, which +considerably simplifies key distribution and storage. +Public key management is based on X.509 certificates, +which can be provided by commercial services or +produced by utility programs in the OpenSSL software library +or the NTPv4 distribution. +.sp \n(Ppu +.ne 2 + +While the algorithms for symmetric key cryptography are +included in the NTPv4 distribution, public key cryptography +requires the OpenSSL software library to be installed +before building the NTP distribution. +Directions for doing that +are on the Building and Installing the Distribution page. +.sp \n(Ppu +.ne 2 + +Authentication is configured separately for each association +using the +\f\*[B-Font]key\f[] +or +\f\*[B-Font]autokey\f[] +subcommand on the +\f\*[B-Font]peer\f[], +\f\*[B-Font]server\f[], +\f\*[B-Font]broadcast\f[] +and +\f\*[B-Font]manycastclient\f[] +configuration commands as described in +\fIConfiguration\f[] \fIOptions\f[] +page. +The authentication +options described below specify the locations of the key files, +if other than default, which symmetric keys are trusted +and the interval between various operations, if other than default. +.sp \n(Ppu +.ne 2 + +Authentication is always enabled, +although ineffective if not configured as +described below. +If a NTP packet arrives +including a message authentication +code (MAC), it is accepted only if it +passes all cryptographic checks. +The +checks require correct key ID, key value +and message digest. +If the packet has +been modified in any way or replayed +by an intruder, it will fail one or more +of these checks and be discarded. +Furthermore, the Autokey scheme requires a +preliminary protocol exchange to obtain +the server certificate, verify its +credentials and initialize the protocol +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]auth\f[] +flag controls whether new associations or +remote configuration commands require cryptographic authentication. +This flag can be set or reset by the +\f\*[B-Font]enable\f[] +and +\f\*[B-Font]disable\f[] +commands and also by remote +configuration commands sent by a +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +program running in +another machine. +If this flag is enabled, which is the default +case, new broadcast client and symmetric passive associations and +remote configuration commands must be cryptographically +authenticated using either symmetric key or public key cryptography. +If this +flag is disabled, these operations are effective +even if not cryptographic +authenticated. +It should be understood +that operating with the +\f\*[B-Font]auth\f[] +flag disabled invites a significant vulnerability +where a rogue hacker can +masquerade as a falseticker and seriously +disrupt system timekeeping. +It is +important to note that this flag has no purpose +other than to allow or disallow +a new association in response to new broadcast +and symmetric active messages +and remote configuration commands and, in particular, +the flag has no effect on +the authentication process itself. +.sp \n(Ppu +.ne 2 + +An attractive alternative where multicast support is available +is manycast mode, in which clients periodically troll +for servers as described in the +\fIAutomatic\f[] \fINTP\f[] \fIConfiguration\f[] \fIOptions\f[] +page. +Either symmetric key or public key +cryptographic authentication can be used in this mode. +The principle advantage +of manycast mode is that potential servers need not be +configured in advance, +since the client finds them during regular operation, +and the configuration +files for all clients can be identical. +.sp \n(Ppu +.ne 2 + +The security model and protocol schemes for +both symmetric key and public key +cryptography are summarized below; +further details are in the briefings, papers +and reports at the NTP project page linked from +\f[C]http://www.ntp.org/\f[]. +.SS Symmetric-Key Cryptography +The original RFC-1305 specification allows any one of possibly +65,534 keys, each distinguished by a 32-bit key identifier, to +authenticate an association. +The servers and clients involved must +agree on the key and key identifier to +authenticate NTP packets. +Keys and +related information are specified in a key +file, usually called +\fIntp.keys\f[], +which must be distributed and stored using +secure means beyond the scope of the NTP protocol itself. +Besides the keys used +for ordinary NTP associations, +additional keys can be used as passwords for the +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +utility programs. +.sp \n(Ppu +.ne 2 + +When +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +is first started, it reads the key file specified in the +\f\*[B-Font]keys\f[] +configuration command and installs the keys +in the key cache. +However, +individual keys must be activated with the +\f\*[B-Font]trusted\f[] +command before use. +This +allows, for instance, the installation of possibly +several batches of keys and +then activating or deactivating each batch +remotely using +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[]. +This also provides a revocation capability that can be used +if a key becomes compromised. +The +\f\*[B-Font]requestkey\f[] +command selects the key used as the password for the +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +utility, while the +\f\*[B-Font]controlkey\f[] +command selects the key used as the password for the +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +utility. +.SS Public Key Cryptography +NTPv4 supports the original NTPv3 symmetric key scheme +described in RFC-1305 and in addition the Autokey protocol, +which is based on public key cryptography. +The Autokey Version 2 protocol described on the Autokey Protocol +page verifies packet integrity using MD5 message digests +and verifies the source with digital signatures and any of several +digest/signature schemes. +Optional identity schemes described on the Identity Schemes +page and based on cryptographic challenge/response algorithms +are also available. +Using all of these schemes provides strong security against +replay with or without modification, spoofing, masquerade +and most forms of clogging attacks. +.\" .Pp +.\" The cryptographic means necessary for all Autokey operations +.\" is provided by the OpenSSL software library. +.\" This library is available from http://www.openssl.org/ +.\" and can be installed using the procedures outlined +.\" in the Building and Installing the Distribution page. +.\" Once installed, +.\" the configure and build +.\" process automatically detects the library and links +.\" the library routines required. +.sp \n(Ppu +.ne 2 + +The Autokey protocol has several modes of operation +corresponding to the various NTP modes supported. +Most modes use a special cookie which can be +computed independently by the client and server, +but encrypted in transmission. +All modes use in addition a variant of the S-KEY scheme, +in which a pseudo-random key list is generated and used +in reverse order. +These schemes are described along with an executive summary, +current status, briefing slides and reading list on the +\fIAutonomous\f[] \fIAuthentication\f[] +page. +.sp \n(Ppu +.ne 2 + +The specific cryptographic environment used by Autokey servers +and clients is determined by a set of files +and soft links generated by the +\fCntp-keygen\f[]\fR(1ntpkeygenmdoc)\f[] +program. +This includes a required host key file, +required certificate file and optional sign key file, +leapsecond file and identity scheme files. +The +digest/signature scheme is specified in the X.509 certificate +along with the matching sign key. +There are several schemes +available in the OpenSSL software library, each identified +by a specific string such as +\f\*[B-Font]md5WithRSAEncryption\f[], +which stands for the MD5 message digest with RSA +encryption scheme. +The current NTP distribution supports +all the schemes in the OpenSSL library, including +those based on RSA and DSA digital signatures. +.sp \n(Ppu +.ne 2 + +NTP secure groups can be used to define cryptographic compartments +and security hierarchies. +It is important that every host +in the group be able to construct a certificate trail to one +or more trusted hosts in the same group. +Each group +host runs the Autokey protocol to obtain the certificates +for all hosts along the trail to one or more trusted hosts. +This requires the configuration file in all hosts to be +engineered so that, even under anticipated failure conditions, +the NTP subnet will form such that every group host can find +a trail to at least one trusted host. +.SS Naming and Addressing +It is important to note that Autokey does not use DNS to +resolve addresses, since DNS can't be completely trusted +until the name servers have synchronized clocks. +The cryptographic name used by Autokey to bind the host identity +credentials and cryptographic values must be independent +of interface, network and any other naming convention. +The name appears in the host certificate in either or both +the subject and issuer fields, so protection against +DNS compromise is essential. +.sp \n(Ppu +.ne 2 + +By convention, the name of an Autokey host is the name returned +by the Unix +\fCgethostname\f[]\fR(2)\f[] +system call or equivalent in other systems. +By the system design +model, there are no provisions to allow alternate names or aliases. +However, this is not to say that DNS aliases, different names +for each interface, etc., are constrained in any way. +.sp \n(Ppu +.ne 2 + +It is also important to note that Autokey verifies authenticity +using the host name, network address and public keys, +all of which are bound together by the protocol specifically +to deflect masquerade attacks. +For this reason Autokey +includes the source and destinatino IP addresses in message digest +computations and so the same addresses must be available +at both the server and client. +For this reason operation +with network address translation schemes is not possible. +This reflects the intended robust security model where government +and corporate NTP servers are operated outside firewall perimeters. +.SS Operation +A specific combination of authentication scheme (none, +symmetric key, public key) and identity scheme is called +a cryptotype, although not all combinations are compatible. +There may be management configurations where the clients, +servers and peers may not all support the same cryptotypes. +A secure NTPv4 subnet can be configured in many ways while +keeping in mind the principles explained above and +in this section. +Note however that some cryptotype +combinations may successfully interoperate with each other, +but may not represent good security practice. +.sp \n(Ppu +.ne 2 + +The cryptotype of an association is determined at the time +of mobilization, either at configuration time or some time +later when a message of appropriate cryptotype arrives. +When mobilized by a +\f\*[B-Font]server\f[] +or +\f\*[B-Font]peer\f[] +configuration command and no +\f\*[B-Font]key\f[] +or +\f\*[B-Font]autokey\f[] +subcommands are present, the association is not +authenticated; if the +\f\*[B-Font]key\f[] +subcommand is present, the association is authenticated +using the symmetric key ID specified; if the +\f\*[B-Font]autokey\f[] +subcommand is present, the association is authenticated +using Autokey. +.sp \n(Ppu +.ne 2 + +When multiple identity schemes are supported in the Autokey +protocol, the first message exchange determines which one is used. +The client request message contains bits corresponding +to which schemes it has available. +The server response message +contains bits corresponding to which schemes it has available. +Both server and client match the received bits with their own +and select a common scheme. +.sp \n(Ppu +.ne 2 + +Following the principle that time is a public value, +a server responds to any client packet that matches +its cryptotype capabilities. +Thus, a server receiving +an unauthenticated packet will respond with an unauthenticated +packet, while the same server receiving a packet of a cryptotype +it supports will respond with packets of that cryptotype. +However, unconfigured broadcast or manycast client +associations or symmetric passive associations will not be +mobilized unless the server supports a cryptotype compatible +with the first packet received. +By default, unauthenticated associations will not be mobilized +unless overridden in a decidedly dangerous way. +.sp \n(Ppu +.ne 2 + +Some examples may help to reduce confusion. +Client Alice has no specific cryptotype selected. +Server Bob has both a symmetric key file and minimal Autokey files. +Alice's unauthenticated messages arrive at Bob, who replies with +unauthenticated messages. +Cathy has a copy of Bob's symmetric +key file and has selected key ID 4 in messages to Bob. +Bob verifies the message with his key ID 4. +If it's the +same key and the message is verified, Bob sends Cathy a reply +authenticated with that key. +If verification fails, +Bob sends Cathy a thing called a crypto-NAK, which tells her +something broke. +She can see the evidence using the +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +program. +.sp \n(Ppu +.ne 2 + +Denise has rolled her own host key and certificate. +She also uses one of the identity schemes as Bob. +She sends the first Autokey message to Bob and they +both dance the protocol authentication and identity steps. +If all comes out okay, Denise and Bob continue as described above. +.sp \n(Ppu +.ne 2 + +It should be clear from the above that Bob can support +all the girls at the same time, as long as he has compatible +authentication and identity credentials. +Now, Bob can act just like the girls in his own choice of servers; +he can run multiple configured associations with multiple different +servers (or the same server, although that might not be useful). +But, wise security policy might preclude some cryptotype +combinations; for instance, running an identity scheme +with one server and no authentication with another might not be wise. +.SS Key Management +The cryptographic values used by the Autokey protocol are +incorporated as a set of files generated by the +\fCntp-keygen\f[]\fR(1ntpkeygenmdoc)\f[] +utility program, including symmetric key, host key and +public certificate files, as well as sign key, identity parameters +and leapseconds files. +Alternatively, host and sign keys and +certificate files can be generated by the OpenSSL utilities +and certificates can be imported from public certificate +authorities. +Note that symmetric keys are necessary for the +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +utility programs. +The remaining files are necessary only for the +Autokey protocol. +.sp \n(Ppu +.ne 2 + +Certificates imported from OpenSSL or public certificate +authorities have certian limitations. +The certificate should be in ASN.1 syntax, X.509 Version 3 +format and encoded in PEM, which is the same format +used by OpenSSL. +The overall length of the certificate encoded +in ASN.1 must not exceed 1024 bytes. +The subject distinguished +name field (CN) is the fully qualified name of the host +on which it is used; the remaining subject fields are ignored. +The certificate extension fields must not contain either +a subject key identifier or a issuer key identifier field; +however, an extended key usage field for a trusted host must +contain the value +\f\*[B-Font]trustRoot\f[];. +Other extension fields are ignored. +.SS Authentication Commands +.TP 7 +.NOP \f\*[B-Font]autokey\f[] [\f\*[I-Font]logsec\f[]] +Specifies the interval between regenerations of the session key +list used with the Autokey protocol. +Note that the size of the key +list for each association depends on this interval and the current +poll interval. +The default value is 12 (4096 s or about 1.1 hours). +For poll intervals above the specified interval, a session key list +with a single entry will be regenerated for every message +sent. +.TP 7 +.NOP \f\*[B-Font]controlkey\f[] \f\*[I-Font]key\f[] +Specifies the key identifier to use with the +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +utility, which uses the standard +protocol defined in RFC-1305. +The +\f\*[I-Font]key\f[] +argument is +the key identifier for a trusted key, where the value can be in the +range 1 to 65,534, inclusive. +.TP 7 +.NOP \f\*[B-Font]crypto\f[] [\f\*[B-Font]cert\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]leap\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]randfile\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]host\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]sign\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]gq\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]gqpar\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]iffpar\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]mvpar\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]pw\f[] \f\*[I-Font]password\f[]] +This command requires the OpenSSL library. +It activates public key +cryptography, selects the message digest and signature +encryption scheme and loads the required private and public +values described above. +If one or more files are left unspecified, +the default names are used as described above. +Unless the complete path and name of the file are specified, the +location of a file is relative to the keys directory specified +in the +\f\*[B-Font]keysdir\f[] +command or default +\fI/usr/local/etc\f[]. +Following are the subcommands: +.RS +.TP 7 +.NOP \f\*[B-Font]cert\f[] \f\*[I-Font]file\f[] +Specifies the location of the required host public certificate file. +This overrides the link +\fIntpkey_cert_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]gqpar\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional GQ parameters file. +This +overrides the link +\fIntpkey_gq_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]host\f[] \f\*[I-Font]file\f[] +Specifies the location of the required host key file. +This overrides +the link +\fIntpkey_key_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]iffpar\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional IFF parameters file.This +overrides the link +\fIntpkey_iff_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]leap\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional leapsecond file. +This overrides the link +\fIntpkey_leap\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]mvpar\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional MV parameters file. +This +overrides the link +\fIntpkey_mv_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]pw\f[] \f\*[I-Font]password\f[] +Specifies the password to decrypt files containing private keys and +identity parameters. +This is required only if these files have been +encrypted. +.TP 7 +.NOP \f\*[B-Font]randfile\f[] \f\*[I-Font]file\f[] +Specifies the location of the random seed file used by the OpenSSL +library. +The defaults are described in the main text above. +.TP 7 +.NOP \f\*[B-Font]sign\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional sign key file. +This overrides +the link +\fIntpkey_sign_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +If this file is +not found, the host key is also the sign key. +.RE +.TP 7 +.NOP \f\*[B-Font]keys\f[] \f\*[I-Font]keyfile\f[] +Specifies the complete path and location of the MD5 key file +containing the keys and key identifiers used by +\fCntpd\f[]\fR(1ntpdmdoc)\f[], +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +when operating with symmetric key cryptography. +This is the same operation as the +\f\*[B-Font]\-k\f[] +command line option. +.TP 7 +.NOP \f\*[B-Font]keysdir\f[] \f\*[I-Font]path\f[] +This command specifies the default directory path for +cryptographic keys, parameters and certificates. +The default is +\fI/usr/local/etc/\f[]. +.TP 7 +.NOP \f\*[B-Font]requestkey\f[] \f\*[I-Font]key\f[] +Specifies the key identifier to use with the +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +utility program, which uses a +proprietary protocol specific to this implementation of +\fCntpd\f[]\fR(1ntpdmdoc)\f[]. +The +\f\*[I-Font]key\f[] +argument is a key identifier +for the trusted key, where the value can be in the range 1 to +65,534, inclusive. +.TP 7 +.NOP \f\*[B-Font]revoke\f[] \f\*[I-Font]logsec\f[] +Specifies the interval between re-randomization of certain +cryptographic values used by the Autokey scheme, as a power of 2 in +seconds. +These values need to be updated frequently in order to +deflect brute-force attacks on the algorithms of the scheme; +however, updating some values is a relatively expensive operation. +The default interval is 16 (65,536 s or about 18 hours). +For poll +intervals above the specified interval, the values will be updated +for every message sent. +.TP 7 +.NOP \f\*[B-Font]trustedkey\f[] \f\*[I-Font]key\f[] \f\*[I-Font]...\f[] +Specifies the key identifiers which are trusted for the +purposes of authenticating peers with symmetric key cryptography, +as well as keys used by the +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +programs. +The authentication procedures require that both the local +and remote servers share the same key and key identifier for this +purpose, although different keys can be used with different +servers. +The +\f\*[I-Font]key\f[] +arguments are 32-bit unsigned +integers with values from 1 to 65,534. +.PP +.SS Error Codes +The following error codes are reported via the NTP control +and monitoring protocol trap mechanism. +.TP 7 +.NOP 101 +(bad field format or length) +The packet has invalid version, length or format. +.TP 7 +.NOP 102 +(bad timestamp) +The packet timestamp is the same or older than the most recent received. +This could be due to a replay or a server clock time step. +.TP 7 +.NOP 103 +(bad filestamp) +The packet filestamp is the same or older than the most recent received. +This could be due to a replay or a key file generation error. +.TP 7 +.NOP 104 +(bad or missing public key) +The public key is missing, has incorrect format or is an unsupported type. +.TP 7 +.NOP 105 +(unsupported digest type) +The server requires an unsupported digest/signature scheme. +.TP 7 +.NOP 106 +(mismatched digest types) +Not used. +.TP 7 +.NOP 107 +(bad signature length) +The signature length does not match the current public key. +.TP 7 +.NOP 108 +(signature not verified) +The message fails the signature check. +It could be bogus or signed by a +different private key. +.TP 7 +.NOP 109 +(certificate not verified) +The certificate is invalid or signed with the wrong key. +.TP 7 +.NOP 110 +(certificate not verified) +The certificate is not yet valid or has expired or the signature could not +be verified. +.TP 7 +.NOP 111 +(bad or missing cookie) +The cookie is missing, corrupted or bogus. +.TP 7 +.NOP 112 +(bad or missing leapseconds table) +The leapseconds table is missing, corrupted or bogus. +.TP 7 +.NOP 113 +(bad or missing certificate) +The certificate is missing, corrupted or bogus. +.TP 7 +.NOP 114 +(bad or missing identity) +The identity key is missing, corrupt or bogus. +.PP +.SH Monitoring Support +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +includes a comprehensive monitoring facility suitable +for continuous, long term recording of server and client +timekeeping performance. +See the +\f\*[B-Font]statistics\f[] +command below +for a listing and example of each type of statistics currently +supported. +Statistic files are managed using file generation sets +and scripts in the +\fI./scripts\f[] +directory of this distribution. +Using +these facilities and +UNIX +\fCcron\f[]\fR(8)\f[] +jobs, the data can be +automatically summarized and archived for retrospective analysis. +.SS Monitoring Commands +.TP 7 +.NOP \f\*[B-Font]statistics\f[] \f\*[I-Font]name\f[] \f\*[I-Font]...\f[] +Enables writing of statistics records. +Currently, eight kinds of +\f\*[I-Font]name\f[] +statistics are supported. +.RS +.TP 7 +.NOP \f\*[B-Font]clockstats\f[] +Enables recording of clock driver statistics information. +Each update +received from a clock driver appends a line of the following form to +the file generation set named +\f\*[B-Font]clockstats\f[]: +.br +.in +4 +.nf +49213 525.624 127.127.4.1 93 226 00:08:29.606 D +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the +clock address in dotted-quad notation. +The final field shows the last +timecode received from the clock in decoded ASCII format, where +meaningful. +In some clock drivers a good deal of additional information +can be gathered and displayed as well. +See information specific to each +clock for further details. +.TP 7 +.NOP \f\*[B-Font]cryptostats\f[] +This option requires the OpenSSL cryptographic software library. +It +enables recording of cryptographic public key protocol information. +Each message received by the protocol module appends a line of the +following form to the file generation set named +\f\*[B-Font]cryptostats\f[]: +.br +.in +4 +.nf +49213 525.624 127.127.4.1 message +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the peer +address in dotted-quad notation, The final message field includes the +message type and certain ancillary information. +See the +\fIAuthentication\f[] \fIOptions\f[] +section for further information. +.TP 7 +.NOP \f\*[B-Font]loopstats\f[] +Enables recording of loop filter statistics information. +Each +update of the local clock outputs a line of the following form to +the file generation set named +\f\*[B-Font]loopstats\f[]: +.br +.in +4 +.nf +50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next five fields +show time offset (seconds), frequency offset (parts per million \- +PPM), RMS jitter (seconds), Allan deviation (PPM) and clock +discipline time constant. +.TP 7 +.NOP \f\*[B-Font]peerstats\f[] +Enables recording of peer statistics information. +This includes +statistics records of all peers of a NTP server and of special +signals, where present and configured. +Each valid update appends a +line of the following form to the current element of a file +generation set named +\f\*[B-Font]peerstats\f[]: +.br +.in +4 +.nf +48773 10847.650 127.127.4.1 9714 \-0.001605376 0.000000000 0.001424877 0.000958674 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the peer address in dotted-quad notation and status, +respectively. +The status field is encoded in hex in the format +described in Appendix A of the NTP specification RFC 1305. +The final four fields show the offset, +delay, dispersion and RMS jitter, all in seconds. +.TP 7 +.NOP \f\*[B-Font]rawstats\f[] +Enables recording of raw-timestamp statistics information. +This +includes statistics records of all peers of a NTP server and of +special signals, where present and configured. +Each NTP message +received from a peer or clock driver appends a line of the +following form to the file generation set named +\f\*[B-Font]rawstats\f[]: +.br +.in +4 +.nf +50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the remote peer or clock address followed by the local address +in dotted-quad notation. +The final four fields show the originate, +receive, transmit and final NTP timestamps in order. +The timestamp +values are as received and before processing by the various data +smoothing and mitigation algorithms. +.TP 7 +.NOP \f\*[B-Font]sysstats\f[] +Enables recording of ntpd statistics counters on a periodic basis. +Each +hour a line of the following form is appended to the file generation +set named +\f\*[B-Font]sysstats\f[]: +.br +.in +4 +.nf +50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The remaining ten fields show +the statistics counter values accumulated since the last generated +line. +.RS +.TP 7 +.NOP Time since restart \f\*[B-Font]36000\f[] +Time in hours since the system was last rebooted. +.TP 7 +.NOP Packets received \f\*[B-Font]81965\f[] +Total number of packets received. +.TP 7 +.NOP Packets processed \f\*[B-Font]0\f[] +Number of packets received in response to previous packets sent +.TP 7 +.NOP Current version \f\*[B-Font]9546\f[] +Number of packets matching the current NTP version. +.TP 7 +.NOP Previous version \f\*[B-Font]56\f[] +Number of packets matching the previous NTP version. +.TP 7 +.NOP Bad version \f\*[B-Font]71793\f[] +Number of packets matching neither NTP version. +.TP 7 +.NOP Access denied \f\*[B-Font]512\f[] +Number of packets denied access for any reason. +.TP 7 +.NOP Bad length or format \f\*[B-Font]540\f[] +Number of packets with invalid length, format or port number. +.TP 7 +.NOP Bad authentication \f\*[B-Font]10\f[] +Number of packets not verified as authentic. +.TP 7 +.NOP Rate exceeded \f\*[B-Font]147\f[] +Number of packets discarded due to rate limitation. +.RE +.TP 7 +.NOP \f\*[B-Font]statsdir\f[] \f\*[I-Font]directory_path\f[] +Indicates the full path of a directory where statistics files +should be created (see below). +This keyword allows +the (otherwise constant) +\f\*[B-Font]filegen\f[] +filename prefix to be modified for file generation sets, which +is useful for handling statistics logs. +.TP 7 +.NOP \f\*[B-Font]filegen\f[] \f\*[I-Font]name\f[] [\f\*[B-Font]file\f[] \f\*[I-Font]filename\f[]] [\f\*[B-Font]type\f[] \f\*[I-Font]typename\f[]] [\f\*[B-Font]link\f[] | \f\*[B-Font]nolink\f[]] [\f\*[B-Font]enable\f[] | \f\*[B-Font]disable\f[]] +Configures setting of generation file set name. +Generation +file sets provide a means for handling files that are +continuously growing during the lifetime of a server. +Server statistics are a typical example for such files. +Generation file sets provide access to a set of files used +to store the actual data. +At any time at most one element +of the set is being written to. +The type given specifies +when and how data will be directed to a new element of the set. +This way, information stored in elements of a file set +that are currently unused are available for administrational +operations without the risk of disturbing the operation of ntpd. +(Most important: they can be removed to free space for new data +produced.) +.sp \n(Ppu +.ne 2 + +Note that this command can be sent from the +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +program running at a remote location. +.RS +.TP 7 +.NOP \f\*[B-Font]name\f[] +This is the type of the statistics records, as shown in the +\f\*[B-Font]statistics\f[] +command. +.TP 7 +.NOP \f\*[B-Font]file\f[] \f\*[I-Font]filename\f[] +This is the file name for the statistics records. +Filenames of set +members are built from three concatenated elements +\f\*[B-Font]prefix\f[], +\f\*[B-Font]filename\f[] +and +\f\*[B-Font]suffix\f[]: +.RS +.TP 7 +.NOP \f\*[B-Font]prefix\f[] +This is a constant filename path. +It is not subject to +modifications via the +\f\*[I-Font]filegen\f[] +option. +It is defined by the +server, usually specified as a compile-time constant. +It may, +however, be configurable for individual file generation sets +via other commands. +For example, the prefix used with +\f\*[I-Font]loopstats\f[] +and +\f\*[I-Font]peerstats\f[] +generation can be configured using the +\f\*[I-Font]statsdir\f[] +option explained above. +.TP 7 +.NOP \f\*[B-Font]filename\f[] +This string is directly concatenated to the prefix mentioned +above (no intervening +\[oq]/\[cq]). +This can be modified using +the file argument to the +\f\*[I-Font]filegen\f[] +statement. +No +\fI..\f[] +elements are +allowed in this component to prevent filenames referring to +parts outside the filesystem hierarchy denoted by +\f\*[I-Font]prefix\f[]. +.TP 7 +.NOP \f\*[B-Font]suffix\f[] +This part is reflects individual elements of a file set. +It is +generated according to the type of a file set. +.RE +.TP 7 +.NOP \f\*[B-Font]type\f[] \f\*[I-Font]typename\f[] +A file generation set is characterized by its type. +The following +types are supported: +.RS +.TP 7 +.NOP \f\*[B-Font]none\f[] +The file set is actually a single plain file. +.TP 7 +.NOP \f\*[B-Font]pid\f[] +One element of file set is used per incarnation of a ntpd +server. +This type does not perform any changes to file set +members during runtime, however it provides an easy way of +separating files belonging to different +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +server incarnations. +The set member filename is built by appending a +\[oq]\&.\[cq] +to concatenated +\f\*[I-Font]prefix\f[] +and +\f\*[I-Font]filename\f[] +strings, and +appending the decimal representation of the process ID of the +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +server process. +.TP 7 +.NOP \f\*[B-Font]day\f[] +One file generation set element is created per day. +A day is +defined as the period between 00:00 and 24:00 UTC. +The file set +member suffix consists of a +\[oq]\&.\[cq] +and a day specification in +the form +\f\*[B-Font]YYYYMMdd\f[]. +\f\*[B-Font]YYYY\f[] +is a 4-digit year number (e.g., 1992). +\f\*[B-Font]MM\f[] +is a two digit month number. +\f\*[B-Font]dd\f[] +is a two digit day number. +Thus, all information written at 10 December 1992 would end up +in a file named +\f\*[I-Font]prefix\f[] +\f\*[I-Font]filename\f[].19921210. +.TP 7 +.NOP \f\*[B-Font]week\f[] +Any file set member contains data related to a certain week of +a year. +The term week is defined by computing day-of-year +modulo 7. +Elements of such a file generation set are +distinguished by appending the following suffix to the file set +filename base: A dot, a 4-digit year number, the letter +\f\*[B-Font]W\f[], +and a 2-digit week number. +For example, information from January, +10th 1992 would end up in a file with suffix +.NOP. \f\*[I-Font]1992W1\f[]. +.TP 7 +.NOP \f\*[B-Font]month\f[] +One generation file set element is generated per month. +The +file name suffix consists of a dot, a 4-digit year number, and +a 2-digit month. +.TP 7 +.NOP \f\*[B-Font]year\f[] +One generation file element is generated per year. +The filename +suffix consists of a dot and a 4 digit year number. +.TP 7 +.NOP \f\*[B-Font]age\f[] +This type of file generation sets changes to a new element of +the file set every 24 hours of server operation. +The filename +suffix consists of a dot, the letter +\f\*[B-Font]a\f[], +and an 8-digit number. +This number is taken to be the number of seconds the server is +running at the start of the corresponding 24-hour period. +Information is only written to a file generation by specifying +\f\*[B-Font]enable\f[]; +output is prevented by specifying +\f\*[B-Font]disable\f[]. +.RE +.TP 7 +.NOP \f\*[B-Font]link\f[] | \f\*[B-Font]nolink\f[] +It is convenient to be able to access the current element of a file +generation set by a fixed name. +This feature is enabled by +specifying +\f\*[B-Font]link\f[] +and disabled using +\f\*[B-Font]nolink\f[]. +If link is specified, a +hard link from the current file set element to a file without +suffix is created. +When there is already a file with this name and +the number of links of this file is one, it is renamed appending a +dot, the letter +\f\*[B-Font]C\f[], +and the pid of the ntpd server process. +When the +number of links is greater than one, the file is unlinked. +This +allows the current file to be accessed by a constant name. +.TP 7 +.NOP \f\*[B-Font]enable\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]disable\f[] +Enables or disables the recording function. +.RE +.RE +.PP +.SH Access Control Support +The +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +daemon implements a general purpose address/mask based restriction +list. +The list contains address/match entries sorted first +by increasing address values and and then by increasing mask values. +A match occurs when the bitwise AND of the mask and the packet +source address is equal to the bitwise AND of the mask and +address in the list. +The list is searched in order with the +last match found defining the restriction flags associated +with the entry. +Additional information and examples can be found in the +"Notes on Configuring NTP and Setting up a NTP Subnet" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.sp \n(Ppu +.ne 2 + +The restriction facility was implemented in conformance +with the access policies for the original NSFnet backbone +time servers. +Later the facility was expanded to deflect +cryptographic and clogging attacks. +While this facility may +be useful for keeping unwanted or broken or malicious clients +from congesting innocent servers, it should not be considered +an alternative to the NTP authentication facilities. +Source address based restrictions are easily circumvented +by a determined cracker. +.sp \n(Ppu +.ne 2 + +Clients can be denied service because they are explicitly +included in the restrict list created by the restrict command +or implicitly as the result of cryptographic or rate limit +violations. +Cryptographic violations include certificate +or identity verification failure; rate limit violations generally +result from defective NTP implementations that send packets +at abusive rates. +Some violations cause denied service +only for the offending packet, others cause denied service +for a timed period and others cause the denied service for +an indefinate period. +When a client or network is denied access +for an indefinate period, the only way at present to remove +the restrictions is by restarting the server. +.SS The Kiss-of-Death Packet +Ordinarily, packets denied service are simply dropped with no +further action except incrementing statistics counters. +Sometimes a +more proactive response is needed, such as a server message that +explicitly requests the client to stop sending and leave a message +for the system operator. +A special packet format has been created +for this purpose called the "kiss-of-death" (KoD) packet. +KoD packets have the leap bits set unsynchronized and stratum set +to zero and the reference identifier field set to a four-byte +ASCII code. +If the +\f\*[B-Font]noserve\f[] +or +\f\*[B-Font]notrust\f[] +flag of the matching restrict list entry is set, +the code is "DENY"; if the +\f\*[B-Font]limited\f[] +flag is set and the rate limit +is exceeded, the code is "RATE". +Finally, if a cryptographic violation occurs, the code is "CRYP". +.sp \n(Ppu +.ne 2 + +A client receiving a KoD performs a set of sanity checks to +minimize security exposure, then updates the stratum and +reference identifier peer variables, sets the access +denied (TEST4) bit in the peer flash variable and sends +a message to the log. +As long as the TEST4 bit is set, +the client will send no further packets to the server. +The only way at present to recover from this condition is +to restart the protocol at both the client and server. +This +happens automatically at the client when the association times out. +It will happen at the server only if the server operator cooperates. +.SS Access Control Commands +.TP 7 +.NOP \f\*[B-Font]discard\f[] [\f\*[B-Font]average\f[] \f\*[I-Font]avg\f[]] [\f\*[B-Font]minimum\f[] \f\*[I-Font]min\f[]] [\f\*[B-Font]monitor\f[] \f\*[I-Font]prob\f[]] +Set the parameters of the +\f\*[B-Font]limited\f[] +facility which protects the server from +client abuse. +The +\f\*[B-Font]average\f[] +subcommand specifies the minimum average packet +spacing, while the +\f\*[B-Font]minimum\f[] +subcommand specifies the minimum packet spacing. +Packets that violate these minima are discarded +and a kiss-o'-death packet returned if enabled. +The default +minimum average and minimum are 5 and 2, respectively. +The monitor subcommand specifies the probability of discard +for packets that overflow the rate-control window. +.TP 7 +.NOP \f\*[B-Font]restrict\f[] \f\*[B-Font]address\f[] [\f\*[B-Font]mask\f[] \f\*[I-Font]mask\f[]] [\f\*[I-Font]flag\f[] \f\*[I-Font]...\f[]] +The +\f\*[I-Font]address\f[] +argument expressed in +dotted-quad form is the address of a host or network. +Alternatively, the +\f\*[I-Font]address\f[] +argument can be a valid host DNS name. +The +\f\*[I-Font]mask\f[] +argument expressed in dotted-quad form defaults to +\f\*[B-Font]255.255.255.255\f[], +meaning that the +\f\*[I-Font]address\f[] +is treated as the address of an individual host. +A default entry (address +\f\*[B-Font]0.0.0.0\f[], +mask +\f\*[B-Font]0.0.0.0\f[]) +is always included and is always the first entry in the list. +Note that text string +\f\*[B-Font]default\f[], +with no mask option, may +be used to indicate the default entry. +In the current implementation, +\f\*[B-Font]flag\f[] +always +restricts access, i.e., an entry with no flags indicates that free +access to the server is to be given. +The flags are not orthogonal, +in that more restrictive flags will often make less restrictive +ones redundant. +The flags can generally be classed into two +categories, those which restrict time service and those which +restrict informational queries and attempts to do run-time +reconfiguration of the server. +One or more of the following flags +may be specified: +.RS +.TP 7 +.NOP \f\*[B-Font]ignore\f[] +Deny packets of all kinds, including +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +queries. +.TP 7 +.NOP \f\*[B-Font]kod\f[] +If this flag is set when an access violation occurs, a kiss-o'-death +(KoD) packet is sent. +KoD packets are rate limited to no more than one +per second. +If another KoD packet occurs within one second after the +last one, the packet is dropped. +.TP 7 +.NOP \f\*[B-Font]limited\f[] +Deny service if the packet spacing violates the lower limits specified +in the discard command. +A history of clients is kept using the +monitoring capability of +\fCntpd\f[]\fR(1ntpdmdoc)\f[]. +Thus, monitoring is always active as +long as there is a restriction entry with the +\f\*[B-Font]limited\f[] +flag. +.TP 7 +.NOP \f\*[B-Font]lowpriotrap\f[] +Declare traps set by matching hosts to be low priority. +The +number of traps a server can maintain is limited (the current limit +is 3). +Traps are usually assigned on a first come, first served +basis, with later trap requestors being denied service. +This flag +modifies the assignment algorithm by allowing low priority traps to +be overridden by later requests for normal priority traps. +.TP 7 +.NOP \f\*[B-Font]nomodify\f[] +Deny +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +queries which attempt to modify the state of the +server (i.e., run time reconfiguration). +Queries which return +information are permitted. +.TP 7 +.NOP \f\*[B-Font]noquery\f[] +Deny +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +queries. +Time service is not affected. +.TP 7 +.NOP \f\*[B-Font]nopeer\f[] +Deny packets which would result in mobilizing a new association. +This +includes broadcast and symmetric active packets when a configured +association does not exist. +It also includes +\f\*[B-Font]pool\f[] +associations, so if you want to use servers from a +\f\*[B-Font]pool\f[] +directive and also want to use +\f\*[B-Font]nopeer\f[] +by default, you'll want a +\f\*[B-Font]restrict source ...\f[] \f\*[B-Font]line\f[] \f\*[B-Font]as\f[] \f\*[B-Font]well\f[] \f\*[B-Font]that\f[] \f\*[B-Font]does\f[] +.TP 7 +.NOP not +include the +\f\*[B-Font]nopeer\f[] +directive. +.TP 7 +.NOP \f\*[B-Font]noserve\f[] +Deny all packets except +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +queries. +.TP 7 +.NOP \f\*[B-Font]notrap\f[] +Decline to provide mode 6 control message trap service to matching +hosts. +The trap service is a subsystem of the ntpdq control message +protocol which is intended for use by remote event logging programs. +.TP 7 +.NOP \f\*[B-Font]notrust\f[] +Deny service unless the packet is cryptographically authenticated. +.TP 7 +.NOP \f\*[B-Font]ntpport\f[] +This is actually a match algorithm modifier, rather than a +restriction flag. +Its presence causes the restriction entry to be +matched only if the source port in the packet is the standard NTP +UDP port (123). +Both +\f\*[B-Font]ntpport\f[] +and +\f\*[B-Font]non-ntpport\f[] +may +be specified. +The +\f\*[B-Font]ntpport\f[] +is considered more specific and +is sorted later in the list. +.TP 7 +.NOP \f\*[B-Font]version\f[] +Deny packets that do not match the current NTP version. +.RE +.sp \n(Ppu +.ne 2 + +Default restriction list entries with the flags ignore, interface, +ntpport, for each of the local host's interface addresses are +inserted into the table at startup to prevent the server +from attempting to synchronize to its own time. +A default entry is also always present, though if it is +otherwise unconfigured; no flags are associated +with the default entry (i.e., everything besides your own +NTP server is unrestricted). +.PP +.SH Automatic NTP Configuration Options +.SS Manycasting +Manycasting is a automatic discovery and configuration paradigm +new to NTPv4. +It is intended as a means for a multicast client +to troll the nearby network neighborhood to find cooperating +manycast servers, validate them using cryptographic means +and evaluate their time values with respect to other servers +that might be lurking in the vicinity. +The intended result is that each manycast client mobilizes +client associations with some number of the "best" +of the nearby manycast servers, yet automatically reconfigures +to sustain this number of servers should one or another fail. +.sp \n(Ppu +.ne 2 + +Note that the manycasting paradigm does not coincide +with the anycast paradigm described in RFC-1546, +which is designed to find a single server from a clique +of servers providing the same service. +The manycast paradigm is designed to find a plurality +of redundant servers satisfying defined optimality criteria. +.sp \n(Ppu +.ne 2 + +Manycasting can be used with either symmetric key +or public key cryptography. +The public key infrastructure (PKI) +offers the best protection against compromised keys +and is generally considered stronger, at least with relatively +large key sizes. +It is implemented using the Autokey protocol and +the OpenSSL cryptographic library available from +\f[C]http://www.openssl.org/\f[]. +The library can also be used with other NTPv4 modes +as well and is highly recommended, especially for broadcast modes. +.sp \n(Ppu +.ne 2 + +A persistent manycast client association is configured +using the manycastclient command, which is similar to the +server command but with a multicast (IPv4 class +\f\*[B-Font]D\f[] +or IPv6 prefix +\f\*[B-Font]FF\f[]) +group address. +The IANA has designated IPv4 address 224.1.1.1 +and IPv6 address FF05::101 (site local) for NTP. +When more servers are needed, it broadcasts manycast +client messages to this address at the minimum feasible rate +and minimum feasible time-to-live (TTL) hops, depending +on how many servers have already been found. +There can be as many manycast client associations +as different group address, each one serving as a template +for a future ephemeral unicast client/server association. +.sp \n(Ppu +.ne 2 + +Manycast servers configured with the +\f\*[B-Font]manycastserver\f[] +command listen on the specified group address for manycast +client messages. +Note the distinction between manycast client, +which actively broadcasts messages, and manycast server, +which passively responds to them. +If a manycast server is +in scope of the current TTL and is itself synchronized +to a valid source and operating at a stratum level equal +to or lower than the manycast client, it replies to the +manycast client message with an ordinary unicast server message. +.sp \n(Ppu +.ne 2 + +The manycast client receiving this message mobilizes +an ephemeral client/server association according to the +matching manycast client template, but only if cryptographically +authenticated and the server stratum is less than or equal +to the client stratum. +Authentication is explicitly required +and either symmetric key or public key (Autokey) can be used. +Then, the client polls the server at its unicast address +in burst mode in order to reliably set the host clock +and validate the source. +This normally results +in a volley of eight client/server at 2-s intervals +during which both the synchronization and cryptographic +protocols run concurrently. +Following the volley, +the client runs the NTP intersection and clustering +algorithms, which act to discard all but the "best" +associations according to stratum and synchronization +distance. +The surviving associations then continue +in ordinary client/server mode. +.sp \n(Ppu +.ne 2 + +The manycast client polling strategy is designed to reduce +as much as possible the volume of manycast client messages +and the effects of implosion due to near-simultaneous +arrival of manycast server messages. +The strategy is determined by the +\f\*[B-Font]manycastclient\f[], +\f\*[B-Font]tos\f[] +and +\f\*[B-Font]ttl\f[] +configuration commands. +The manycast poll interval is +normally eight times the system poll interval, +which starts out at the +\f\*[B-Font]minpoll\f[] +value specified in the +\f\*[B-Font]manycastclient\f[], +command and, under normal circumstances, increments to the +\f\*[B-Font]maxpolll\f[] +value specified in this command. +Initially, the TTL is +set at the minimum hops specified by the ttl command. +At each retransmission the TTL is increased until reaching +the maximum hops specified by this command or a sufficient +number client associations have been found. +Further retransmissions use the same TTL. +.sp \n(Ppu +.ne 2 + +The quality and reliability of the suite of associations +discovered by the manycast client is determined by the NTP +mitigation algorithms and the +\f\*[B-Font]minclock\f[] +and +\f\*[B-Font]minsane\f[] +values specified in the +\f\*[B-Font]tos\f[] +configuration command. +At least +\f\*[B-Font]minsane\f[] +candidate servers must be available and the mitigation +algorithms produce at least +\f\*[B-Font]minclock\f[] +survivors in order to synchronize the clock. +Byzantine agreement principles require at least four +candidates in order to correctly discard a single falseticker. +For legacy purposes, +\f\*[B-Font]minsane\f[] +defaults to 1 and +\f\*[B-Font]minclock\f[] +defaults to 3. +For manycast service +\f\*[B-Font]minsane\f[] +should be explicitly set to 4, assuming at least that +number of servers are available. +.sp \n(Ppu +.ne 2 + +If at least +\f\*[B-Font]minclock\f[] +servers are found, the manycast poll interval is immediately +set to eight times +\f\*[B-Font]maxpoll\f[]. +If less than +\f\*[B-Font]minclock\f[] +servers are found when the TTL has reached the maximum hops, +the manycast poll interval is doubled. +For each transmission +after that, the poll interval is doubled again until +reaching the maximum of eight times +\f\*[B-Font]maxpoll\f[]. +Further transmissions use the same poll interval and +TTL values. +Note that while all this is going on, +each client/server association found is operating normally +it the system poll interval. +.sp \n(Ppu +.ne 2 + +Administratively scoped multicast boundaries are normally +specified by the network router configuration and, +in the case of IPv6, the link/site scope prefix. +By default, the increment for TTL hops is 32 starting +from 31; however, the +\f\*[B-Font]ttl\f[] +configuration command can be +used to modify the values to match the scope rules. +.sp \n(Ppu +.ne 2 + +It is often useful to narrow the range of acceptable +servers which can be found by manycast client associations. +Because manycast servers respond only when the client +stratum is equal to or greater than the server stratum, +primary (stratum 1) servers fill find only primary servers +in TTL range, which is probably the most common objective. +However, unless configured otherwise, all manycast clients +in TTL range will eventually find all primary servers +in TTL range, which is probably not the most common +objective in large networks. +The +\f\*[B-Font]tos\f[] +command can be used to modify this behavior. +Servers with stratum below +\f\*[B-Font]floor\f[] +or above +\f\*[B-Font]ceiling\f[] +specified in the +\f\*[B-Font]tos\f[] +command are strongly discouraged during the selection +process; however, these servers may be temporally +accepted if the number of servers within TTL range is +less than +\f\*[B-Font]minclock\f[]. +.sp \n(Ppu +.ne 2 + +The above actions occur for each manycast client message, +which repeats at the designated poll interval. +However, once the ephemeral client association is mobilized, +subsequent manycast server replies are discarded, +since that would result in a duplicate association. +If during a poll interval the number of client associations +falls below +\f\*[B-Font]minclock\f[], +all manycast client prototype associations are reset +to the initial poll interval and TTL hops and operation +resumes from the beginning. +It is important to avoid +frequent manycast client messages, since each one requires +all manycast servers in TTL range to respond. +The result could well be an implosion, either minor or major, +depending on the number of servers in range. +The recommended value for +\f\*[B-Font]maxpoll\f[] +is 12 (4,096 s). +.sp \n(Ppu +.ne 2 + +It is possible and frequently useful to configure a host +as both manycast client and manycast server. +A number of hosts configured this way and sharing a common +group address will automatically organize themselves +in an optimum configuration based on stratum and +synchronization distance. +For example, consider an NTP +subnet of two primary servers and a hundred or more +dependent clients. +With two exceptions, all servers +and clients have identical configuration files including both +\f\*[B-Font]multicastclient\f[] +and +\f\*[B-Font]multicastserver\f[] +commands using, for instance, multicast group address +239.1.1.1. +The only exception is that each primary server +configuration file must include commands for the primary +reference source such as a GPS receiver. +.sp \n(Ppu +.ne 2 + +The remaining configuration files for all secondary +servers and clients have the same contents, except for the +\f\*[B-Font]tos\f[] +command, which is specific for each stratum level. +For stratum 1 and stratum 2 servers, that command is +not necessary. +For stratum 3 and above servers the +\f\*[B-Font]floor\f[] +value is set to the intended stratum number. +Thus, all stratum 3 configuration files are identical, +all stratum 4 files are identical and so forth. +.sp \n(Ppu +.ne 2 + +Once operations have stabilized in this scenario, +the primary servers will find the primary reference source +and each other, since they both operate at the same +stratum (1), but not with any secondary server or client, +since these operate at a higher stratum. +The secondary +servers will find the servers at the same stratum level. +If one of the primary servers loses its GPS receiver, +it will continue to operate as a client and other clients +will time out the corresponding association and +re-associate accordingly. +.sp \n(Ppu +.ne 2 + +Some administrators prefer to avoid running +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +continuously and run either +\fCsntp\f[]\fR(1sntpmdoc)\f[] +or +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +\f\*[B-Font]\-q\f[] +as a cron job. +In either case the servers must be +configured in advance and the program fails if none are +available when the cron job runs. +A really slick +application of manycast is with +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +\f\*[B-Font]\-q\f[]. +The program wakes up, scans the local landscape looking +for the usual suspects, selects the best from among +the rascals, sets the clock and then departs. +Servers do not have to be configured in advance and +all clients throughout the network can have the same +configuration file. +.SS Manycast Interactions with Autokey +Each time a manycast client sends a client mode packet +to a multicast group address, all manycast servers +in scope generate a reply including the host name +and status word. +The manycast clients then run +the Autokey protocol, which collects and verifies +all certificates involved. +Following the burst interval +all but three survivors are cast off, +but the certificates remain in the local cache. +It often happens that several complete signing trails +from the client to the primary servers are collected in this way. +.sp \n(Ppu +.ne 2 + +About once an hour or less often if the poll interval +exceeds this, the client regenerates the Autokey key list. +This is in general transparent in client/server mode. +However, about once per day the server private value +used to generate cookies is refreshed along with all +manycast client associations. +In this case all +cryptographic values including certificates is refreshed. +If a new certificate has been generated since +the last refresh epoch, it will automatically revoke +all prior certificates that happen to be in the +certificate cache. +At the same time, the manycast +scheme starts all over from the beginning and +the expanding ring shrinks to the minimum and increments +from there while collecting all servers in scope. +.SS Manycast Options +.TP 7 +.NOP \f\*[B-Font]tos\f[] [\f\*[B-Font]ceiling\f[] \f\*[I-Font]ceiling\f[] | \f\*[B-Font]cohort\f[] { \f\*[B-Font]0\f[] | \f\*[B-Font]1\f[] } | \f\*[B-Font]floor\f[] \f\*[I-Font]floor\f[] | \f\*[B-Font]minclock\f[] \f\*[I-Font]minclock\f[] | \f\*[B-Font]minsane\f[] \f\*[I-Font]minsane\f[]] +This command affects the clock selection and clustering +algorithms. +It can be used to select the quality and +quantity of peers used to synchronize the system clock +and is most useful in manycast mode. +The variables operate +as follows: +.RS +.TP 7 +.NOP \f\*[B-Font]ceiling\f[] \f\*[I-Font]ceiling\f[] +Peers with strata above +\f\*[B-Font]ceiling\f[] +will be discarded if there are at least +\f\*[B-Font]minclock\f[] +peers remaining. +This value defaults to 15, but can be changed +to any number from 1 to 15. +.TP 7 +.NOP \f\*[B-Font]cohort\f[] {0 | 1 } +This is a binary flag which enables (0) or disables (1) +manycast server replies to manycast clients with the same +stratum level. +This is useful to reduce implosions where +large numbers of clients with the same stratum level +are present. +The default is to enable these replies. +.TP 7 +.NOP \f\*[B-Font]floor\f[] \f\*[I-Font]floor\f[] +Peers with strata below +\f\*[B-Font]floor\f[] +will be discarded if there are at least +\f\*[B-Font]minclock\f[] +peers remaining. +This value defaults to 1, but can be changed +to any number from 1 to 15. +.TP 7 +.NOP \f\*[B-Font]minclock\f[] \f\*[I-Font]minclock\f[] +The clustering algorithm repeatedly casts out outlier +associations until no more than +\f\*[B-Font]minclock\f[] +associations remain. +This value defaults to 3, +but can be changed to any number from 1 to the number of +configured sources. +.TP 7 +.NOP \f\*[B-Font]minsane\f[] \f\*[I-Font]minsane\f[] +This is the minimum number of candidates available +to the clock selection algorithm in order to produce +one or more truechimers for the clustering algorithm. +If fewer than this number are available, the clock is +undisciplined and allowed to run free. +The default is 1 +for legacy purposes. +However, according to principles of +Byzantine agreement, +\f\*[B-Font]minsane\f[] +should be at least 4 in order to detect and discard +a single falseticker. +.RE +.TP 7 +.NOP \f\*[B-Font]ttl\f[] \f\*[I-Font]hop\f[] \f\*[I-Font]...\f[] +This command specifies a list of TTL values in increasing +order, up to 8 values can be specified. +In manycast mode these values are used in turn +in an expanding-ring search. +The default is eight +multiples of 32 starting at 31. +.PP +.SH Reference Clock Support +The NTP Version 4 daemon supports some three dozen different radio, +satellite and modem reference clocks plus a special pseudo-clock +used for backup or when no other clock source is available. +Detailed descriptions of individual device drivers and options can +be found in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +Additional information can be found in the pages linked +there, including the +"Debugging Hints for Reference Clock Drivers" +and +"How To Write a Reference Clock Driver" +pages +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +In addition, support for a PPS +signal is available as described in the +"Pulse-per-second (PPS) Signal Interfacing" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +Many +drivers support special line discipline/streams modules which can +significantly improve the accuracy using the driver. +These are +described in the +"Line Disciplines and Streams Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.sp \n(Ppu +.ne 2 + +A reference clock will generally (though not always) be a radio +timecode receiver which is synchronized to a source of standard +time such as the services offered by the NRC in Canada and NIST and +USNO in the US. +The interface between the computer and the timecode +receiver is device dependent, but is usually a serial port. +A +device driver specific to each reference clock must be selected and +compiled in the distribution; however, most common radio, satellite +and modem clocks are included by default. +Note that an attempt to +configure a reference clock when the driver has not been compiled +or the hardware port has not been appropriately configured results +in a scalding remark to the system log file, but is otherwise non +hazardous. +.sp \n(Ppu +.ne 2 + +For the purposes of configuration, +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +treats +reference clocks in a manner analogous to normal NTP peers as much +as possible. +Reference clocks are identified by a syntactically +correct but invalid IP address, in order to distinguish them from +normal NTP peers. +Reference clock addresses are of the form +\f[C]127.127.\f[]\f\*[I-Font]t\f[].\f\*[I-Font]u\f[], +where +\f\*[I-Font]t\f[] +is an integer +denoting the clock type and +\f\*[I-Font]u\f[] +indicates the unit +number in the range 0-3. +While it may seem overkill, it is in fact +sometimes useful to configure multiple reference clocks of the same +type, in which case the unit numbers must be unique. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]server\f[] +command is used to configure a reference +clock, where the +\f\*[I-Font]address\f[] +argument in that command +is the clock address. +The +\f\*[B-Font]key\f[], +\f\*[B-Font]version\f[] +and +\f\*[B-Font]ttl\f[] +options are not used for reference clock support. +The +\f\*[B-Font]mode\f[] +option is added for reference clock support, as +described below. +The +\f\*[B-Font]prefer\f[] +option can be useful to +persuade the server to cherish a reference clock with somewhat more +enthusiasm than other reference clocks or peers. +Further +information on this option can be found in the +"Mitigation Rules and the prefer Keyword" +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +page. +The +\f\*[B-Font]minpoll\f[] +and +\f\*[B-Font]maxpoll\f[] +options have +meaning only for selected clock drivers. +See the individual clock +driver document pages for additional information. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]fudge\f[] +command is used to provide additional +information for individual clock drivers and normally follows +immediately after the +\f\*[B-Font]server\f[] +command. +The +\f\*[I-Font]address\f[] +argument specifies the clock address. +The +\f\*[B-Font]refid\f[] +and +\f\*[B-Font]stratum\f[] +options can be used to +override the defaults for the device. +There are two optional +device-dependent time offsets and four flags that can be included +in the +\f\*[B-Font]fudge\f[] +command as well. +.sp \n(Ppu +.ne 2 + +The stratum number of a reference clock is by default zero. +Since the +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +daemon adds one to the stratum of each +peer, a primary server ordinarily displays an external stratum of +one. +In order to provide engineered backups, it is often useful to +specify the reference clock stratum as greater than zero. +The +\f\*[B-Font]stratum\f[] +option is used for this purpose. +Also, in cases +involving both a reference clock and a pulse-per-second (PPS) +discipline signal, it is useful to specify the reference clock +identifier as other than the default, depending on the driver. +The +\f\*[B-Font]refid\f[] +option is used for this purpose. +Except where noted, +these options apply to all clock drivers. +.SS Reference Clock Commands +.TP 7 +.NOP \f\*[B-Font]server\f[] \f[C]127.127.\f[]\f\*[I-Font]t\f[].\f\*[I-Font]u\f[] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]mode\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]int\f[]] +This command can be used to configure reference clocks in +special ways. +The options are interpreted as follows: +.RS +.TP 7 +.NOP \f\*[B-Font]prefer\f[] +Marks the reference clock as preferred. +All other things being +equal, this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +for further information. +.TP 7 +.NOP \f\*[B-Font]mode\f[] \f\*[I-Font]int\f[] +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.TP 7 +.NOP \f\*[B-Font]minpoll\f[] \f\*[I-Font]int\f[] +.TP 7 +.NOP \f\*[B-Font]maxpoll\f[] \f\*[I-Font]int\f[] +These options specify the minimum and maximum polling interval +for reference clock messages, as a power of 2 in seconds +For +most directly connected reference clocks, both +\f\*[B-Font]minpoll\f[] +and +\f\*[B-Font]maxpoll\f[] +default to 6 (64 s). +For modem reference clocks, +\f\*[B-Font]minpoll\f[] +defaults to 10 (17.1 m) and +\f\*[B-Font]maxpoll\f[] +defaults to 14 (4.5 h). +The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. +.RE +.TP 7 +.NOP \f\*[B-Font]fudge\f[] \f[C]127.127.\f[]\f\*[I-Font]t\f[].\f\*[I-Font]u\f[] [\f\*[B-Font]time1\f[] \f\*[I-Font]sec\f[]] [\f\*[B-Font]time2\f[] \f\*[I-Font]sec\f[]] [\f\*[B-Font]stratum\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]refid\f[] \f\*[I-Font]string\f[]] [\f\*[B-Font]mode\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]flag1\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] [\f\*[B-Font]flag2\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] [\f\*[B-Font]flag3\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] [\f\*[B-Font]flag4\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] +This command can be used to configure reference clocks in +special ways. +It must immediately follow the +\f\*[B-Font]server\f[] +command which configures the driver. +Note that the same capability +is possible at run time using the +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +program. +The options are interpreted as +follows: +.RS +.TP 7 +.NOP \f\*[B-Font]time1\f[] \f\*[I-Font]sec\f[] +Specifies a constant to be added to the time offset produced by +the driver, a fixed-point decimal number in seconds. +This is used +as a calibration constant to adjust the nominal time offset of a +particular clock to agree with an external standard, such as a +precision PPS signal. +It also provides a way to correct a +systematic error or bias due to serial port or operating system +latencies, different cable lengths or receiver internal delay. +The +specified offset is in addition to the propagation delay provided +by other means, such as internal DIPswitches. +Where a calibration +for an individual system and driver is available, an approximate +correction is noted in the driver documentation pages. +Note: in order to facilitate calibration when more than one +radio clock or PPS signal is supported, a special calibration +feature is available. +It takes the form of an argument to the +\f\*[B-Font]enable\f[] +command described in +\fIMiscellaneous\f[] \fIOptions\f[] +page and operates as described in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.TP 7 +.NOP \f\*[B-Font]time2\f[] \f\*[I-Font]secs\f[] +Specifies a fixed-point decimal number in seconds, which is +interpreted in a driver-dependent way. +See the descriptions of +specific drivers in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.TP 7 +.NOP \f\*[B-Font]stratum\f[] \f\*[I-Font]int\f[] +Specifies the stratum number assigned to the driver, an integer +between 0 and 15. +This number overrides the default stratum number +ordinarily assigned by the driver itself, usually zero. +.TP 7 +.NOP \f\*[B-Font]refid\f[] \f\*[I-Font]string\f[] +Specifies an ASCII string of from one to four characters which +defines the reference identifier used by the driver. +This string +overrides the default identifier ordinarily assigned by the driver +itself. +.TP 7 +.NOP \f\*[B-Font]mode\f[] \f\*[I-Font]int\f[] +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.TP 7 +.NOP \f\*[B-Font]flag1\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +.TP 7 +.NOP \f\*[B-Font]flag2\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +.TP 7 +.NOP \f\*[B-Font]flag3\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +.TP 7 +.NOP \f\*[B-Font]flag4\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +These four flags are used for customizing the clock driver. +The +interpretation of these values, and whether they are used at all, +is a function of the particular clock driver. +However, by +convention +\f\*[B-Font]flag4\f[] +is used to enable recording monitoring +data to the +\f\*[B-Font]clockstats\f[] +file configured with the +\f\*[B-Font]filegen\f[] +command. +Further information on the +\f\*[B-Font]filegen\f[] +command can be found in +\fIMonitoring\f[] \fIOptions\f[]. +.RE +.PP +.SH Miscellaneous Options +.TP 7 +.NOP \f\*[B-Font]broadcastdelay\f[] \f\*[I-Font]seconds\f[] +The broadcast and multicast modes require a special calibration +to determine the network delay between the local and remote +servers. +Ordinarily, this is done automatically by the initial +protocol exchanges between the client and server. +In some cases, +the calibration procedure may fail due to network or server access +controls, for example. +This command specifies the default delay to +be used under these circumstances. +Typically (for Ethernet), a +number between 0.003 and 0.007 seconds is appropriate. +The default +when this command is not used is 0.004 seconds. +.TP 7 +.NOP \f\*[B-Font]calldelay\f[] \f\*[I-Font]delay\f[] +This option controls the delay in seconds between the first and second +packets sent in burst or iburst mode to allow additional time for a modem +or ISDN call to complete. +.TP 7 +.NOP \f\*[B-Font]driftfile\f[] \f\*[I-Font]driftfile\f[] +This command specifies the complete path and name of the file used to +record the frequency of the local clock oscillator. +This is the same +operation as the +\f\*[B-Font]\-f\f[] +command line option. +If the file exists, it is read at +startup in order to set the initial frequency and then updated once per +hour with the current frequency computed by the daemon. +If the file name is +specified, but the file itself does not exist, the starts with an initial +frequency of zero and creates the file when writing it for the first time. +If this command is not given, the daemon will always start with an initial +frequency of zero. +.sp \n(Ppu +.ne 2 + +The file format consists of a single line containing a single +floating point number, which records the frequency offset measured +in parts-per-million (PPM). +The file is updated by first writing +the current drift value into a temporary file and then renaming +this file to replace the old version. +This implies that +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +must have write permission for the directory the +drift file is located in, and that file system links, symbolic or +otherwise, should be avoided. +.TP 7 +.NOP \f\*[B-Font]dscp\f[] \f\*[I-Font]value\f[] +This option specifies the Differentiated Services Control Point (DSCP) value, +a 6-bit code. The default value is 46, signifying Expedited Forwarding. +.TP 7 +.NOP \f\*[B-Font]enable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]mode7\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]stats\f[]] +.TP 7 +.NOP \f\*[B-Font]disable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]mode7\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]stats\f[]] +Provides a way to enable or disable various server options. +Flags not mentioned are unaffected. +Note that all of these flags +can be controlled remotely using the +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +utility program. +.RS +.TP 7 +.NOP \f\*[B-Font]auth\f[] +Enables the server to synchronize with unconfigured peers only if the +peer has been correctly authenticated using either public key or +private key cryptography. +The default for this flag is +\f\*[B-Font]enable\f[]. +.TP 7 +.NOP \f\*[B-Font]bclient\f[] +Enables the server to listen for a message from a broadcast or +multicast server, as in the +\f\*[B-Font]multicastclient\f[] +command with default +address. +The default for this flag is +\f\*[B-Font]disable\f[]. +.TP 7 +.NOP \f\*[B-Font]calibrate\f[] +Enables the calibrate feature for reference clocks. +The default for +this flag is +\f\*[B-Font]disable\f[]. +.TP 7 +.NOP \f\*[B-Font]kernel\f[] +Enables the kernel time discipline, if available. +The default for this +flag is +\f\*[B-Font]enable\f[] +if support is available, otherwise +\f\*[B-Font]disable\f[]. +.TP 7 +.NOP \f\*[B-Font]mode7\f[] +Enables processing of NTP mode 7 implementation-specific requests +which are used by the deprecated +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +program. +The default for this flag is disable. +This flag is excluded from runtime configuration using +\fCntpq\f[]\fR(1ntpqmdoc)\f[]. +The +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +program provides the same capabilities as +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +using standard mode 6 requests. +.TP 7 +.NOP \f\*[B-Font]monitor\f[] +Enables the monitoring facility. +See the +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +program +and the +\f\*[B-Font]monlist\f[] +command or further information. +The +default for this flag is +\f\*[B-Font]enable\f[]. +.TP 7 +.NOP \f\*[B-Font]ntp\f[] +Enables time and frequency discipline. +In effect, this switch opens and +closes the feedback loop, which is useful for testing. +The default for +this flag is +\f\*[B-Font]enable\f[]. +.TP 7 +.NOP \f\*[B-Font]stats\f[] +Enables the statistics facility. +See the +\fIMonitoring\f[] \fIOptions\f[] +section for further information. +The default for this flag is +\f\*[B-Font]disable\f[]. +.RE +.TP 7 +.NOP \f\*[B-Font]includefile\f[] \f\*[I-Font]includefile\f[] +This command allows additional configuration commands +to be included from a separate file. +Include files may +be nested to a depth of five; upon reaching the end of any +include file, command processing resumes in the previous +configuration file. +This option is useful for sites that run +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +on multiple hosts, with (mostly) common options (e.g., a +restriction list). +.TP 7 +.NOP \f\*[B-Font]leapsmearinterval\f[] \f\*[I-Font]seconds\f[] +This EXPERIMENTAL option is only available if +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +was built with the +\f\*[B-Font]\--enable-leap-smear\f[] +option to the +\f\*[B-Font]configure\f[] +script. +It specifies the interval over which a leap second correction will be applied. +Recommended values for this option are between +7200 (2 hours) and 86400 (24 hours). +.Sy DO NOT USE THIS OPTION ON PUBLIC-ACCESS SERVERS! +See http://bugs.ntp.org/2855 for more information. +.TP 7 +.NOP \f\*[B-Font]logconfig\f[] \f\*[I-Font]configkeyword\f[] +This command controls the amount and type of output written to +the system +\fCsyslog\f[]\fR(3)\f[] +facility or the alternate +\f\*[B-Font]logfile\f[] +log file. +By default, all output is turned on. +All +\f\*[I-Font]configkeyword\f[] +keywords can be prefixed with +\[oq]=\[cq], +\[oq]+\[cq] +and +\[oq]\-\[cq], +where +\[oq]=\[cq] +sets the +\fCsyslog\f[]\fR(3)\f[] +priority mask, +\[oq]+\[cq] +adds and +\[oq]\-\[cq] +removes +messages. +\fCsyslog\f[]\fR(3)\f[] +messages can be controlled in four +classes +(\f\*[B-Font]clock\f[], \f\*[B-Font]peer\f[], \f\*[B-Font]sys\f[] and \f\*[B-Font]sync\f[]). +Within these classes four types of messages can be +controlled: informational messages +(\f\*[B-Font]info\f[]), +event messages +(\f\*[B-Font]events\f[]), +statistics messages +(\f\*[B-Font]statistics\f[]) +and +status messages +(\f\*[B-Font]status\f[]). +.sp \n(Ppu +.ne 2 + +Configuration keywords are formed by concatenating the message class with +the event class. +The +\f\*[B-Font]all\f[] +prefix can be used instead of a message class. +A +message class may also be followed by the +\f\*[B-Font]all\f[] +keyword to enable/disable all +messages of the respective message class.Thus, a minimal log configuration +could look like this: +.br +.in +4 +.nf +logconfig =syncstatus +sysevents +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +This would just list the synchronizations state of +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +and the major system events. +For a simple reference server, the +following minimum message configuration could be useful: +.br +.in +4 +.nf +logconfig =syncall +clockall +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +This configuration will list all clock information and +synchronization information. +All other events and messages about +peers, system events and so on is suppressed. +.TP 7 +.NOP \f\*[B-Font]logfile\f[] \f\*[I-Font]logfile\f[] +This command specifies the location of an alternate log file to +be used instead of the default system +\fCsyslog\f[]\fR(3)\f[] +facility. +This is the same operation as the \-l command line option. +.TP 7 +.NOP \f\*[B-Font]setvar\f[] \f\*[I-Font]variable\f[] [\f\*[B-Font]default\f[]] +This command adds an additional system variable. +These +variables can be used to distribute additional information such as +the access policy. +If the variable of the form +\fIname\f[]\fI=\f[]\f\*[I-Font]value\f[] +is followed by the +\f\*[B-Font]default\f[] +keyword, the +variable will be listed as part of the default system variables +(\fCntpq\f[]\fR(1ntpqmdoc)\f[] \f\*[B-Font]rv\f[] command)). +These additional variables serve +informational purposes only. +They are not related to the protocol +other that they can be listed. +The known protocol variables will +always override any variables defined via the +\f\*[B-Font]setvar\f[] +mechanism. +There are three special variables that contain the names +of all variable of the same group. +The +\fIsys_var_list\f[] +holds +the names of all system variables. +The +\fIpeer_var_list\f[] +holds +the names of all peer variables and the +\fIclock_var_list\f[] +holds the names of the reference clock variables. +.TP 7 +.NOP \f\*[B-Font]tinker\f[] [\f\*[B-Font]allan\f[] \f\*[I-Font]allan\f[] | \f\*[B-Font]dispersion\f[] \f\*[I-Font]dispersion\f[] | \f\*[B-Font]freq\f[] \f\*[I-Font]freq\f[] | \f\*[B-Font]huffpuff\f[] \f\*[I-Font]huffpuff\f[] | \f\*[B-Font]panic\f[] \f\*[I-Font]panic\f[] | \f\*[B-Font]step\f[] \f\*[I-Font]step\f[] | \f\*[B-Font]stepback\f[] \f\*[I-Font]stepback\f[] | \f\*[B-Font]stepfwd\f[] \f\*[I-Font]stepfwd\f[] | \f\*[B-Font]stepout\f[] \f\*[I-Font]stepout\f[]] +This command can be used to alter several system variables in +very exceptional circumstances. +It should occur in the +configuration file before any other configuration options. +The +default values of these variables have been carefully optimized for +a wide range of network speeds and reliability expectations. +In +general, they interact in intricate ways that are hard to predict +and some combinations can result in some very nasty behavior. +Very +rarely is it necessary to change the default values; but, some +folks cannot resist twisting the knobs anyway and this command is +for them. +Emphasis added: twisters are on their own and can expect +no help from the support group. +.sp \n(Ppu +.ne 2 + +The variables operate as follows: +.RS +.TP 7 +.NOP \f\*[B-Font]allan\f[] \f\*[I-Font]allan\f[] +The argument becomes the new value for the minimum Allan +intercept, which is a parameter of the PLL/FLL clock discipline +algorithm. +The value in log2 seconds defaults to 7 (1024 s), which is also the lower +limit. +.TP 7 +.NOP \f\*[B-Font]dispersion\f[] \f\*[I-Font]dispersion\f[] +The argument becomes the new value for the dispersion increase rate, +normally .000015 s/s. +.TP 7 +.NOP \f\*[B-Font]freq\f[] \f\*[I-Font]freq\f[] +The argument becomes the initial value of the frequency offset in +parts-per-million. +This overrides the value in the frequency file, if +present, and avoids the initial training state if it is not. +.TP 7 +.NOP \f\*[B-Font]huffpuff\f[] \f\*[I-Font]huffpuff\f[] +The argument becomes the new value for the experimental +huff-n'-puff filter span, which determines the most recent interval +the algorithm will search for a minimum delay. +The lower limit is +900 s (15 m), but a more reasonable value is 7200 (2 hours). +There +is no default, since the filter is not enabled unless this command +is given. +.TP 7 +.NOP \f\*[B-Font]panic\f[] \f\*[I-Font]panic\f[] +The argument is the panic threshold, normally 1000 s. +If set to zero, +the panic sanity check is disabled and a clock offset of any value will +be accepted. +.TP 7 +.NOP \f\*[B-Font]step\f[] \f\*[I-Font]step\f[] +The argument is the step threshold, which by default is 0.128 s. +It can +be set to any positive number in seconds. +If set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if the step threshold is set to zero or greater than the +default. +.TP 7 +.NOP \f\*[B-Font]stepback\f[] \f\*[I-Font]stepback\f[] +The argument is the step threshold for the backward direction, +which by default is 0.128 s. +It can +be set to any positive number in seconds. +If both the forward and backward step thresholds are set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if +each direction of step threshold are either +set to zero or greater than .5 second. +.TP 7 +.NOP \f\*[B-Font]stepfwd\f[] \f\*[I-Font]stepfwd\f[] +As for stepback, but for the forward direction. +.TP 7 +.NOP \f\*[B-Font]stepout\f[] \f\*[I-Font]stepout\f[] +The argument is the stepout timeout, which by default is 900 s. +It can +be set to any positive number in seconds. +If set to zero, the stepout +pulses will not be suppressed. +.RE +.TP 7 +.NOP \f\*[B-Font]rlimit\f[] [\f\*[B-Font]memlock\f[] \f\*[I-Font]Nmegabytes\f[] | \f\*[B-Font]stacksize\f[] \f\*[I-Font]N4kPages\f[] \f\*[B-Font]filenum\f[] \f\*[I-Font]Nfiledescriptors\f[]] +.RS +.TP 7 +.NOP \f\*[B-Font]memlock\f[] \f\*[I-Font]Nmegabytes\f[] +Specify the number of megabytes of memory that should be +allocated and locked. +Probably only available under Linux, this option may be useful +when dropping root (the +\f\*[B-Font]\-i\f[] +option). +The default is 32 megabytes on non-Linux machines, and \-1 under Linux. +-1 means "do not lock the process into memory". +0 means "lock whatever memory the process wants into memory". +.TP 7 +.NOP \f\*[B-Font]stacksize\f[] \f\*[I-Font]N4kPages\f[] +Specifies the maximum size of the process stack on systems with the +\fBmlockall\f[]\fR()\f[] +function. +Defaults to 50 4k pages (200 4k pages in OpenBSD). +.TP 7 +.NOP \f\*[B-Font]filenum\f[] \f\*[I-Font]Nfiledescriptors\f[] +Specifies the maximum number of file descriptors ntpd may have open at once. Defaults to the system default. +.RE +.TP 7 +.NOP \f\*[B-Font]trap\f[] \f\*[I-Font]host_address\f[] [\f\*[B-Font]port\f[] \f\*[I-Font]port_number\f[]] [\f\*[B-Font]interface\f[] \f\*[I-Font]interface_address\f[]] +This command configures a trap receiver at the given host +address and port number for sending messages with the specified +local interface address. +If the port number is unspecified, a value +of 18447 is used. +If the interface address is not specified, the +message is sent with a source address of the local interface the +message is sent through. +Note that on a multihomed host the +interface used may vary from time to time with routing changes. +.sp \n(Ppu +.ne 2 + +The trap receiver will generally log event messages and other +information from the server in a log file. +While such monitor +programs may also request their own trap dynamically, configuring a +trap receiver will ensure that no messages are lost when the server +is started. +.TP 7 +.NOP \f\*[B-Font]hop\f[] \f\*[I-Font]...\f[] +This command specifies a list of TTL values in increasing order, up to 8 +values can be specified. +In manycast mode these values are used in turn in +an expanding-ring search. +The default is eight multiples of 32 starting at +31. +.PP +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTP_CONF_\fP or \fBNTP_CONF\fP +.fi +.ad +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH FILES +.TP 15 +.NOP \fI/etc/ntp.conf\f[] +the default name of the configuration file +.br +.ns +.TP 15 +.NOP \fIntp.keys\f[] +private MD5 keys +.br +.ns +.TP 15 +.NOP \fIntpkey\f[] +RSA private key +.br +.ns +.TP 15 +.NOP \fIntpkey_\f[]\f\*[I-Font]host\f[] +RSA public key +.br +.ns +.TP 15 +.NOP \fIntp_dh\f[] +Diffie-Hellman agreement parameters +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "SEE ALSO" +\fCntpd\f[]\fR(1ntpdmdoc)\f[], +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[], +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +.sp \n(Ppu +.ne 2 + +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +\f[C]http://www.ntp.org/\f[]. +A snapshot of this documentation is available in HTML format in +\fI/usr/share/doc/ntp\f[]. +David L. Mills, +\fINetwork Time Protocol (Version 4)\fR, +RFC5905 +.PP + +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH BUGS +The syntax checking is not picky; some combinations of +ridiculous and even hilarious options and modes may not be +detected. +.sp \n(Ppu +.ne 2 + +The +\fIntpkey_\f[]\f\*[I-Font]host\f[] +files are really digital +certificates. +These should be obtained via secure directory +services when they become universally available. +.sp \n(Ppu +.ne 2 + +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +This document was derived from FreeBSD. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntp.conf\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.conf.5mdoc b/contrib/ntp/ntpd/ntp.conf.5mdoc new file mode 100644 index 000000000..a883aabaa --- /dev/null +++ b/contrib/ntp/ntpd/ntp.conf.5mdoc @@ -0,0 +1,2856 @@ +.Dd October 21 2015 +.Dt NTP_CONF 5mdoc File Formats +.Os +.\" EDIT THIS FILE WITH CAUTION (ntp.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:24 PM by AutoGen 5.18.5 +.\" From the definitions ntp.conf.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntp.conf +.Nd Network Time Protocol (NTP) daemon configuration file format +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +The +.Nm +configuration file is read at initial startup by the +.Xr ntpd 1ntpdmdoc +daemon in order to specify the synchronization sources, +modes and other related information. +Usually, it is installed in the +.Pa /etc +directory, +but could be installed elsewhere +(see the daemon's +.Fl c +command line option). +.Pp +The file format is similar to other +.Ux +configuration files. +Comments begin with a +.Ql # +character and extend to the end of the line; +blank lines are ignored. +Configuration commands consist of an initial keyword +followed by a list of arguments, +some of which may be optional, separated by whitespace. +Commands may not be continued over multiple lines. +Arguments may be host names, +host addresses written in numeric, dotted\-quad form, +integers, floating point numbers (when specifying times in seconds) +and text strings. +.Pp +The rest of this page describes the configuration and control options. +The +.Qq Notes on Configuring NTP and Setting up an NTP Subnet +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +contains an extended discussion of these options. +In addition to the discussion of general +.Sx Configuration Options , +there are sections describing the following supported functionality +and the options used to control it: +.Bl -bullet -offset indent +.It +.Sx Authentication Support +.It +.Sx Monitoring Support +.It +.Sx Access Control Support +.It +.Sx Automatic NTP Configuration Options +.It +.Sx Reference Clock Support +.It +.Sx Miscellaneous Options +.El +.Pp +Following these is a section describing +.Sx Miscellaneous Options . +While there is a rich set of options available, +the only required option is one or more +.Ic pool , +.Ic server , +.Ic peer , +.Ic broadcast +or +.Ic manycastclient +commands. +.Sh Configuration Support +Following is a description of the configuration commands in +NTPv4. +These commands have the same basic functions as in NTPv3 and +in some cases new functions and new arguments. +There are two +classes of commands, configuration commands that configure a +persistent association with a remote server or peer or reference +clock, and auxiliary commands that specify environmental variables +that control various related operations. +.Ss Configuration Commands +The various modes are determined by the command keyword and the +type of the required IP address. +Addresses are classed by type as +(s) a remote server or peer (IPv4 class A, B and C), (b) the +broadcast address of a local interface, (m) a multicast address (IPv4 +class D), or (r) a reference clock address (127.127.x.x). +Note that +only those options applicable to each command are listed below. +Use +of options not listed may not be caught as an error, but may result +in some weird and even destructive behavior. +.Pp +If the Basic Socket Interface Extensions for IPv6 (RFC\-2553) +is detected, support for the IPv6 address family is generated +in addition to the default support of the IPv4 address family. +In a few cases, including the reslist billboard generated +by ntpdc, IPv6 addresses are automatically generated. +IPv6 addresses can be identified by the presence of colons +.Dq \&: +in the address field. +IPv6 addresses can be used almost everywhere where +IPv4 addresses can be used, +with the exception of reference clock addresses, +which are always IPv4. +.Pp +Note that in contexts where a host name is expected, a +.Fl 4 +qualifier preceding +the host name forces DNS resolution to the IPv4 namespace, +while a +.Fl 6 +qualifier forces DNS resolution to the IPv6 namespace. +See IPv6 references for the +equivalent classes for that address family. +.Bl -tag -width indent +.It Xo Ic pool Ar address +.Op Cm burst +.Op Cm iburst +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic server Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm burst +.Op Cm iburst +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic peer Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic broadcast Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm ttl Ar ttl +.Xc +.It Xo Ic manycastclient Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Op Cm ttl Ar ttl +.Xc +.El +.Pp +These five commands specify the time server name or address to +be used and the mode in which to operate. +The +.Ar address +can be +either a DNS name or an IP address in dotted\-quad notation. +Additional information on association behavior can be found in the +.Qq Association Management +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Bl -tag -width indent +.It Ic pool +For type s addresses, this command mobilizes a persistent +client mode association with a number of remote servers. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +.It Ic server +For type s and r addresses, this command mobilizes a persistent +client mode association with the specified remote server or local +radio clock. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +This command should +.Em not +be used for type +b or m addresses. +.It Ic peer +For type s addresses (only), this command mobilizes a +persistent symmetric\-active mode association with the specified +remote peer. +In this mode the local clock can be synchronized to +the remote peer or the remote peer can be synchronized to the local +clock. +This is useful in a network of servers where, depending on +various failure scenarios, either the local or remote peer may be +the better source of time. +This command should NOT be used for type +b, m or r addresses. +.It Ic broadcast +For type b and m addresses (only), this +command mobilizes a persistent broadcast mode association. +Multiple +commands can be used to specify multiple local broadcast interfaces +(subnets) and/or multiple multicast groups. +Note that local +broadcast messages go only to the interface associated with the +subnet specified, but multicast messages go to all interfaces. +In broadcast mode the local server sends periodic broadcast +messages to a client population at the +.Ar address +specified, which is usually the broadcast address on (one of) the +local network(s) or a multicast address assigned to NTP. +The IANA +has assigned the multicast group address IPv4 224.0.1.1 and +IPv6 ff05::101 (site local) exclusively to +NTP, but other nonconflicting addresses can be used to contain the +messages within administrative boundaries. +Ordinarily, this +specification applies only to the local server operating as a +sender; for operation as a broadcast client, see the +.Ic broadcastclient +or +.Ic multicastclient +commands +below. +.It Ic manycastclient +For type m addresses (only), this command mobilizes a +manycast client mode association for the multicast address +specified. +In this case a specific address must be supplied which +matches the address used on the +.Ic manycastserver +command for +the designated manycast servers. +The NTP multicast address +224.0.1.1 assigned by the IANA should NOT be used, unless specific +means are taken to avoid spraying large areas of the Internet with +these messages and causing a possibly massive implosion of replies +at the sender. +The +.Ic manycastserver +command specifies that the local server +is to operate in client mode with the remote servers that are +discovered as the result of broadcast/multicast messages. +The +client broadcasts a request message to the group address associated +with the specified +.Ar address +and specifically enabled +servers respond to these messages. +The client selects the servers +providing the best time and continues as with the +.Ic server +command. +The remaining servers are discarded as if never +heard. +.El +.Pp +Options: +.Bl -tag -width indent +.It Cm autokey +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the autokey scheme +described in +.Sx Authentication Options . +.It Cm burst +when the server is reachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first and second packets +can be changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to improve timekeeping quality +with the +.Ic server +command and s addresses. +.It Cm iburst +When the server is unreachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first two packets can be +changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to speed the initial synchronization +acquisition with the +.Ic server +command and s addresses and when +.Xr ntpd 1ntpdmdoc +is started with the +.Fl q +option. +.It Cm key Ar key +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the specified +.Ar key +identifier with values from 1 to 65534, inclusive. +The +default is to include no encryption field. +.It Cm minpoll Ar minpoll +.It Cm maxpoll Ar maxpoll +These options specify the minimum and maximum poll intervals +for NTP messages, as a power of 2 in seconds +The maximum poll +interval defaults to 10 (1,024 s), but can be increased by the +.Cm maxpoll +option to an upper limit of 17 (36.4 h). +The +minimum poll interval defaults to 6 (64 s), but can be decreased by +the +.Cm minpoll +option to a lower limit of 4 (16 s). +.It Cm noselect +Marks the server as unused, except for display purposes. +The server is discarded by the selection algroithm. +.It Cm prefer +Marks the server as preferred. +All other things being equal, +this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +.Qq Mitigation Rules and the prefer Keyword +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +for further information. +.It Cm ttl Ar ttl +This option is used only with broadcast server and manycast +client modes. +It specifies the time\-to\-live +.Ar ttl +to +use on broadcast server and multicast server and the maximum +.Ar ttl +for the expanding ring search with manycast +client packets. +Selection of the proper value, which defaults to +127, is something of a black art and should be coordinated with the +network administrator. +.It Cm version Ar version +Specifies the version number to be used for outgoing NTP +packets. +Versions 1\-4 are the choices, with version 4 the +default. +.El +.Ss Auxiliary Commands +.Bl -tag -width indent +.It Ic broadcastclient +This command enables reception of broadcast server messages to +any local interface (type b) address. +Upon receiving a message for +the first time, the broadcast client measures the nominal server +propagation delay using a brief client/server exchange with the +server, then enters the broadcast client mode, in which it +synchronizes to succeeding broadcast messages. +Note that, in order +to avoid accidental or malicious disruption in this mode, both the +server and client should operate using symmetric\-key or public\-key +authentication as described in +.Sx Authentication Options . +.It Ic manycastserver Ar address ... +This command enables reception of manycast client messages to +the multicast group address(es) (type m) specified. +At least one +address is required, but the NTP multicast address 224.0.1.1 +assigned by the IANA should NOT be used, unless specific means are +taken to limit the span of the reply and avoid a possibly massive +implosion at the original sender. +Note that, in order to avoid +accidental or malicious disruption in this mode, both the server +and client should operate using symmetric\-key or public\-key +authentication as described in +.Sx Authentication Options . +.It Ic multicastclient Ar address ... +This command enables reception of multicast server messages to +the multicast group address(es) (type m) specified. +Upon receiving +a message for the first time, the multicast client measures the +nominal server propagation delay using a brief client/server +exchange with the server, then enters the broadcast client mode, in +which it synchronizes to succeeding multicast messages. +Note that, +in order to avoid accidental or malicious disruption in this mode, +both the server and client should operate using symmetric\-key or +public\-key authentication as described in +.Sx Authentication Options . +.It Ic mdnstries Ar number +If we are participating in mDNS, +after we have synched for the first time +we attempt to register with the mDNS system. +If that registration attempt fails, +we try again at one minute intervals for up to +.Ic mdnstries +times. +After all, +.Ic ntpd +may be starting before mDNS. +The default value for +.Ic mdnstries +is 5. +.El +.Sh Authentication Support +Authentication support allows the NTP client to verify that the +server is in fact known and trusted and not an intruder intending +accidentally or on purpose to masquerade as that server. +The NTPv3 +specification RFC\-1305 defines a scheme which provides +cryptographic authentication of received NTP packets. +Originally, +this was done using the Data Encryption Standard (DES) algorithm +operating in Cipher Block Chaining (CBC) mode, commonly called +DES\-CBC. +Subsequently, this was replaced by the RSA Message Digest +5 (MD5) algorithm using a private key, commonly called keyed\-MD5. +Either algorithm computes a message digest, or one\-way hash, which +can be used to verify the server has the correct private key and +key identifier. +.Pp +NTPv4 retains the NTPv3 scheme, properly described as symmetric key +cryptography and, in addition, provides a new Autokey scheme +based on public key cryptography. +Public key cryptography is generally considered more secure +than symmetric key cryptography, since the security is based +on a private value which is generated by each server and +never revealed. +With Autokey all key distribution and +management functions involve only public values, which +considerably simplifies key distribution and storage. +Public key management is based on X.509 certificates, +which can be provided by commercial services or +produced by utility programs in the OpenSSL software library +or the NTPv4 distribution. +.Pp +While the algorithms for symmetric key cryptography are +included in the NTPv4 distribution, public key cryptography +requires the OpenSSL software library to be installed +before building the NTP distribution. +Directions for doing that +are on the Building and Installing the Distribution page. +.Pp +Authentication is configured separately for each association +using the +.Cm key +or +.Cm autokey +subcommand on the +.Ic peer , +.Ic server , +.Ic broadcast +and +.Ic manycastclient +configuration commands as described in +.Sx Configuration Options +page. +The authentication +options described below specify the locations of the key files, +if other than default, which symmetric keys are trusted +and the interval between various operations, if other than default. +.Pp +Authentication is always enabled, +although ineffective if not configured as +described below. +If a NTP packet arrives +including a message authentication +code (MAC), it is accepted only if it +passes all cryptographic checks. +The +checks require correct key ID, key value +and message digest. +If the packet has +been modified in any way or replayed +by an intruder, it will fail one or more +of these checks and be discarded. +Furthermore, the Autokey scheme requires a +preliminary protocol exchange to obtain +the server certificate, verify its +credentials and initialize the protocol +.Pp +The +.Cm auth +flag controls whether new associations or +remote configuration commands require cryptographic authentication. +This flag can be set or reset by the +.Ic enable +and +.Ic disable +commands and also by remote +configuration commands sent by a +.Xr ntpdc 1ntpdcmdoc +program running in +another machine. +If this flag is enabled, which is the default +case, new broadcast client and symmetric passive associations and +remote configuration commands must be cryptographically +authenticated using either symmetric key or public key cryptography. +If this +flag is disabled, these operations are effective +even if not cryptographic +authenticated. +It should be understood +that operating with the +.Ic auth +flag disabled invites a significant vulnerability +where a rogue hacker can +masquerade as a falseticker and seriously +disrupt system timekeeping. +It is +important to note that this flag has no purpose +other than to allow or disallow +a new association in response to new broadcast +and symmetric active messages +and remote configuration commands and, in particular, +the flag has no effect on +the authentication process itself. +.Pp +An attractive alternative where multicast support is available +is manycast mode, in which clients periodically troll +for servers as described in the +.Sx Automatic NTP Configuration Options +page. +Either symmetric key or public key +cryptographic authentication can be used in this mode. +The principle advantage +of manycast mode is that potential servers need not be +configured in advance, +since the client finds them during regular operation, +and the configuration +files for all clients can be identical. +.Pp +The security model and protocol schemes for +both symmetric key and public key +cryptography are summarized below; +further details are in the briefings, papers +and reports at the NTP project page linked from +.Li http://www.ntp.org/ . +.Ss Symmetric\-Key Cryptography +The original RFC\-1305 specification allows any one of possibly +65,534 keys, each distinguished by a 32\-bit key identifier, to +authenticate an association. +The servers and clients involved must +agree on the key and key identifier to +authenticate NTP packets. +Keys and +related information are specified in a key +file, usually called +.Pa ntp.keys , +which must be distributed and stored using +secure means beyond the scope of the NTP protocol itself. +Besides the keys used +for ordinary NTP associations, +additional keys can be used as passwords for the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +utility programs. +.Pp +When +.Xr ntpd 1ntpdmdoc +is first started, it reads the key file specified in the +.Ic keys +configuration command and installs the keys +in the key cache. +However, +individual keys must be activated with the +.Ic trusted +command before use. +This +allows, for instance, the installation of possibly +several batches of keys and +then activating or deactivating each batch +remotely using +.Xr ntpdc 1ntpdcmdoc . +This also provides a revocation capability that can be used +if a key becomes compromised. +The +.Ic requestkey +command selects the key used as the password for the +.Xr ntpdc 1ntpdcmdoc +utility, while the +.Ic controlkey +command selects the key used as the password for the +.Xr ntpq 1ntpqmdoc +utility. +.Ss Public Key Cryptography +NTPv4 supports the original NTPv3 symmetric key scheme +described in RFC\-1305 and in addition the Autokey protocol, +which is based on public key cryptography. +The Autokey Version 2 protocol described on the Autokey Protocol +page verifies packet integrity using MD5 message digests +and verifies the source with digital signatures and any of several +digest/signature schemes. +Optional identity schemes described on the Identity Schemes +page and based on cryptographic challenge/response algorithms +are also available. +Using all of these schemes provides strong security against +replay with or without modification, spoofing, masquerade +and most forms of clogging attacks. +.\" .Pp +.\" The cryptographic means necessary for all Autokey operations +.\" is provided by the OpenSSL software library. +.\" This library is available from http://www.openssl.org/ +.\" and can be installed using the procedures outlined +.\" in the Building and Installing the Distribution page. +.\" Once installed, +.\" the configure and build +.\" process automatically detects the library and links +.\" the library routines required. +.Pp +The Autokey protocol has several modes of operation +corresponding to the various NTP modes supported. +Most modes use a special cookie which can be +computed independently by the client and server, +but encrypted in transmission. +All modes use in addition a variant of the S\-KEY scheme, +in which a pseudo\-random key list is generated and used +in reverse order. +These schemes are described along with an executive summary, +current status, briefing slides and reading list on the +.Sx Autonomous Authentication +page. +.Pp +The specific cryptographic environment used by Autokey servers +and clients is determined by a set of files +and soft links generated by the +.Xr ntp\-keygen 1ntpkeygenmdoc +program. +This includes a required host key file, +required certificate file and optional sign key file, +leapsecond file and identity scheme files. +The +digest/signature scheme is specified in the X.509 certificate +along with the matching sign key. +There are several schemes +available in the OpenSSL software library, each identified +by a specific string such as +.Cm md5WithRSAEncryption , +which stands for the MD5 message digest with RSA +encryption scheme. +The current NTP distribution supports +all the schemes in the OpenSSL library, including +those based on RSA and DSA digital signatures. +.Pp +NTP secure groups can be used to define cryptographic compartments +and security hierarchies. +It is important that every host +in the group be able to construct a certificate trail to one +or more trusted hosts in the same group. +Each group +host runs the Autokey protocol to obtain the certificates +for all hosts along the trail to one or more trusted hosts. +This requires the configuration file in all hosts to be +engineered so that, even under anticipated failure conditions, +the NTP subnet will form such that every group host can find +a trail to at least one trusted host. +.Ss Naming and Addressing +It is important to note that Autokey does not use DNS to +resolve addresses, since DNS can't be completely trusted +until the name servers have synchronized clocks. +The cryptographic name used by Autokey to bind the host identity +credentials and cryptographic values must be independent +of interface, network and any other naming convention. +The name appears in the host certificate in either or both +the subject and issuer fields, so protection against +DNS compromise is essential. +.Pp +By convention, the name of an Autokey host is the name returned +by the Unix +.Xr gethostname 2 +system call or equivalent in other systems. +By the system design +model, there are no provisions to allow alternate names or aliases. +However, this is not to say that DNS aliases, different names +for each interface, etc., are constrained in any way. +.Pp +It is also important to note that Autokey verifies authenticity +using the host name, network address and public keys, +all of which are bound together by the protocol specifically +to deflect masquerade attacks. +For this reason Autokey +includes the source and destinatino IP addresses in message digest +computations and so the same addresses must be available +at both the server and client. +For this reason operation +with network address translation schemes is not possible. +This reflects the intended robust security model where government +and corporate NTP servers are operated outside firewall perimeters. +.Ss Operation +A specific combination of authentication scheme (none, +symmetric key, public key) and identity scheme is called +a cryptotype, although not all combinations are compatible. +There may be management configurations where the clients, +servers and peers may not all support the same cryptotypes. +A secure NTPv4 subnet can be configured in many ways while +keeping in mind the principles explained above and +in this section. +Note however that some cryptotype +combinations may successfully interoperate with each other, +but may not represent good security practice. +.Pp +The cryptotype of an association is determined at the time +of mobilization, either at configuration time or some time +later when a message of appropriate cryptotype arrives. +When mobilized by a +.Ic server +or +.Ic peer +configuration command and no +.Ic key +or +.Ic autokey +subcommands are present, the association is not +authenticated; if the +.Ic key +subcommand is present, the association is authenticated +using the symmetric key ID specified; if the +.Ic autokey +subcommand is present, the association is authenticated +using Autokey. +.Pp +When multiple identity schemes are supported in the Autokey +protocol, the first message exchange determines which one is used. +The client request message contains bits corresponding +to which schemes it has available. +The server response message +contains bits corresponding to which schemes it has available. +Both server and client match the received bits with their own +and select a common scheme. +.Pp +Following the principle that time is a public value, +a server responds to any client packet that matches +its cryptotype capabilities. +Thus, a server receiving +an unauthenticated packet will respond with an unauthenticated +packet, while the same server receiving a packet of a cryptotype +it supports will respond with packets of that cryptotype. +However, unconfigured broadcast or manycast client +associations or symmetric passive associations will not be +mobilized unless the server supports a cryptotype compatible +with the first packet received. +By default, unauthenticated associations will not be mobilized +unless overridden in a decidedly dangerous way. +.Pp +Some examples may help to reduce confusion. +Client Alice has no specific cryptotype selected. +Server Bob has both a symmetric key file and minimal Autokey files. +Alice's unauthenticated messages arrive at Bob, who replies with +unauthenticated messages. +Cathy has a copy of Bob's symmetric +key file and has selected key ID 4 in messages to Bob. +Bob verifies the message with his key ID 4. +If it's the +same key and the message is verified, Bob sends Cathy a reply +authenticated with that key. +If verification fails, +Bob sends Cathy a thing called a crypto\-NAK, which tells her +something broke. +She can see the evidence using the +.Xr ntpq 1ntpqmdoc +program. +.Pp +Denise has rolled her own host key and certificate. +She also uses one of the identity schemes as Bob. +She sends the first Autokey message to Bob and they +both dance the protocol authentication and identity steps. +If all comes out okay, Denise and Bob continue as described above. +.Pp +It should be clear from the above that Bob can support +all the girls at the same time, as long as he has compatible +authentication and identity credentials. +Now, Bob can act just like the girls in his own choice of servers; +he can run multiple configured associations with multiple different +servers (or the same server, although that might not be useful). +But, wise security policy might preclude some cryptotype +combinations; for instance, running an identity scheme +with one server and no authentication with another might not be wise. +.Ss Key Management +The cryptographic values used by the Autokey protocol are +incorporated as a set of files generated by the +.Xr ntp\-keygen 1ntpkeygenmdoc +utility program, including symmetric key, host key and +public certificate files, as well as sign key, identity parameters +and leapseconds files. +Alternatively, host and sign keys and +certificate files can be generated by the OpenSSL utilities +and certificates can be imported from public certificate +authorities. +Note that symmetric keys are necessary for the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +utility programs. +The remaining files are necessary only for the +Autokey protocol. +.Pp +Certificates imported from OpenSSL or public certificate +authorities have certian limitations. +The certificate should be in ASN.1 syntax, X.509 Version 3 +format and encoded in PEM, which is the same format +used by OpenSSL. +The overall length of the certificate encoded +in ASN.1 must not exceed 1024 bytes. +The subject distinguished +name field (CN) is the fully qualified name of the host +on which it is used; the remaining subject fields are ignored. +The certificate extension fields must not contain either +a subject key identifier or a issuer key identifier field; +however, an extended key usage field for a trusted host must +contain the value +.Cm trustRoot ; . +Other extension fields are ignored. +.Ss Authentication Commands +.Bl -tag -width indent +.It Ic autokey Op Ar logsec +Specifies the interval between regenerations of the session key +list used with the Autokey protocol. +Note that the size of the key +list for each association depends on this interval and the current +poll interval. +The default value is 12 (4096 s or about 1.1 hours). +For poll intervals above the specified interval, a session key list +with a single entry will be regenerated for every message +sent. +.It Ic controlkey Ar key +Specifies the key identifier to use with the +.Xr ntpq 1ntpqmdoc +utility, which uses the standard +protocol defined in RFC\-1305. +The +.Ar key +argument is +the key identifier for a trusted key, where the value can be in the +range 1 to 65,534, inclusive. +.It Xo Ic crypto +.Op Cm cert Ar file +.Op Cm leap Ar file +.Op Cm randfile Ar file +.Op Cm host Ar file +.Op Cm sign Ar file +.Op Cm gq Ar file +.Op Cm gqpar Ar file +.Op Cm iffpar Ar file +.Op Cm mvpar Ar file +.Op Cm pw Ar password +.Xc +This command requires the OpenSSL library. +It activates public key +cryptography, selects the message digest and signature +encryption scheme and loads the required private and public +values described above. +If one or more files are left unspecified, +the default names are used as described above. +Unless the complete path and name of the file are specified, the +location of a file is relative to the keys directory specified +in the +.Ic keysdir +command or default +.Pa /usr/local/etc . +Following are the subcommands: +.Bl -tag -width indent +.It Cm cert Ar file +Specifies the location of the required host public certificate file. +This overrides the link +.Pa ntpkey_cert_ Ns Ar hostname +in the keys directory. +.It Cm gqpar Ar file +Specifies the location of the optional GQ parameters file. +This +overrides the link +.Pa ntpkey_gq_ Ns Ar hostname +in the keys directory. +.It Cm host Ar file +Specifies the location of the required host key file. +This overrides +the link +.Pa ntpkey_key_ Ns Ar hostname +in the keys directory. +.It Cm iffpar Ar file +Specifies the location of the optional IFF parameters file.This +overrides the link +.Pa ntpkey_iff_ Ns Ar hostname +in the keys directory. +.It Cm leap Ar file +Specifies the location of the optional leapsecond file. +This overrides the link +.Pa ntpkey_leap +in the keys directory. +.It Cm mvpar Ar file +Specifies the location of the optional MV parameters file. +This +overrides the link +.Pa ntpkey_mv_ Ns Ar hostname +in the keys directory. +.It Cm pw Ar password +Specifies the password to decrypt files containing private keys and +identity parameters. +This is required only if these files have been +encrypted. +.It Cm randfile Ar file +Specifies the location of the random seed file used by the OpenSSL +library. +The defaults are described in the main text above. +.It Cm sign Ar file +Specifies the location of the optional sign key file. +This overrides +the link +.Pa ntpkey_sign_ Ns Ar hostname +in the keys directory. +If this file is +not found, the host key is also the sign key. +.El +.It Ic keys Ar keyfile +Specifies the complete path and location of the MD5 key file +containing the keys and key identifiers used by +.Xr ntpd 1ntpdmdoc , +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +when operating with symmetric key cryptography. +This is the same operation as the +.Fl k +command line option. +.It Ic keysdir Ar path +This command specifies the default directory path for +cryptographic keys, parameters and certificates. +The default is +.Pa /usr/local/etc/ . +.It Ic requestkey Ar key +Specifies the key identifier to use with the +.Xr ntpdc 1ntpdcmdoc +utility program, which uses a +proprietary protocol specific to this implementation of +.Xr ntpd 1ntpdmdoc . +The +.Ar key +argument is a key identifier +for the trusted key, where the value can be in the range 1 to +65,534, inclusive. +.It Ic revoke Ar logsec +Specifies the interval between re\-randomization of certain +cryptographic values used by the Autokey scheme, as a power of 2 in +seconds. +These values need to be updated frequently in order to +deflect brute\-force attacks on the algorithms of the scheme; +however, updating some values is a relatively expensive operation. +The default interval is 16 (65,536 s or about 18 hours). +For poll +intervals above the specified interval, the values will be updated +for every message sent. +.It Ic trustedkey Ar key ... +Specifies the key identifiers which are trusted for the +purposes of authenticating peers with symmetric key cryptography, +as well as keys used by the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +programs. +The authentication procedures require that both the local +and remote servers share the same key and key identifier for this +purpose, although different keys can be used with different +servers. +The +.Ar key +arguments are 32\-bit unsigned +integers with values from 1 to 65,534. +.El +.Ss Error Codes +The following error codes are reported via the NTP control +and monitoring protocol trap mechanism. +.Bl -tag -width indent +.It 101 +.Pq bad field format or length +The packet has invalid version, length or format. +.It 102 +.Pq bad timestamp +The packet timestamp is the same or older than the most recent received. +This could be due to a replay or a server clock time step. +.It 103 +.Pq bad filestamp +The packet filestamp is the same or older than the most recent received. +This could be due to a replay or a key file generation error. +.It 104 +.Pq bad or missing public key +The public key is missing, has incorrect format or is an unsupported type. +.It 105 +.Pq unsupported digest type +The server requires an unsupported digest/signature scheme. +.It 106 +.Pq mismatched digest types +Not used. +.It 107 +.Pq bad signature length +The signature length does not match the current public key. +.It 108 +.Pq signature not verified +The message fails the signature check. +It could be bogus or signed by a +different private key. +.It 109 +.Pq certificate not verified +The certificate is invalid or signed with the wrong key. +.It 110 +.Pq certificate not verified +The certificate is not yet valid or has expired or the signature could not +be verified. +.It 111 +.Pq bad or missing cookie +The cookie is missing, corrupted or bogus. +.It 112 +.Pq bad or missing leapseconds table +The leapseconds table is missing, corrupted or bogus. +.It 113 +.Pq bad or missing certificate +The certificate is missing, corrupted or bogus. +.It 114 +.Pq bad or missing identity +The identity key is missing, corrupt or bogus. +.El +.Sh Monitoring Support +.Xr ntpd 1ntpdmdoc +includes a comprehensive monitoring facility suitable +for continuous, long term recording of server and client +timekeeping performance. +See the +.Ic statistics +command below +for a listing and example of each type of statistics currently +supported. +Statistic files are managed using file generation sets +and scripts in the +.Pa ./scripts +directory of this distribution. +Using +these facilities and +.Ux +.Xr cron 8 +jobs, the data can be +automatically summarized and archived for retrospective analysis. +.Ss Monitoring Commands +.Bl -tag -width indent +.It Ic statistics Ar name ... +Enables writing of statistics records. +Currently, eight kinds of +.Ar name +statistics are supported. +.Bl -tag -width indent +.It Cm clockstats +Enables recording of clock driver statistics information. +Each update +received from a clock driver appends a line of the following form to +the file generation set named +.Cm clockstats : +.Bd -literal +49213 525.624 127.127.4.1 93 226 00:08:29.606 D +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the +clock address in dotted\-quad notation. +The final field shows the last +timecode received from the clock in decoded ASCII format, where +meaningful. +In some clock drivers a good deal of additional information +can be gathered and displayed as well. +See information specific to each +clock for further details. +.It Cm cryptostats +This option requires the OpenSSL cryptographic software library. +It +enables recording of cryptographic public key protocol information. +Each message received by the protocol module appends a line of the +following form to the file generation set named +.Cm cryptostats : +.Bd -literal +49213 525.624 127.127.4.1 message +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the peer +address in dotted\-quad notation, The final message field includes the +message type and certain ancillary information. +See the +.Sx Authentication Options +section for further information. +.It Cm loopstats +Enables recording of loop filter statistics information. +Each +update of the local clock outputs a line of the following form to +the file generation set named +.Cm loopstats : +.Bd -literal +50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next five fields +show time offset (seconds), frequency offset (parts per million \- +PPM), RMS jitter (seconds), Allan deviation (PPM) and clock +discipline time constant. +.It Cm peerstats +Enables recording of peer statistics information. +This includes +statistics records of all peers of a NTP server and of special +signals, where present and configured. +Each valid update appends a +line of the following form to the current element of a file +generation set named +.Cm peerstats : +.Bd -literal +48773 10847.650 127.127.4.1 9714 \-0.001605376 0.000000000 0.001424877 0.000958674 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the peer address in dotted\-quad notation and status, +respectively. +The status field is encoded in hex in the format +described in Appendix A of the NTP specification RFC 1305. +The final four fields show the offset, +delay, dispersion and RMS jitter, all in seconds. +.It Cm rawstats +Enables recording of raw\-timestamp statistics information. +This +includes statistics records of all peers of a NTP server and of +special signals, where present and configured. +Each NTP message +received from a peer or clock driver appends a line of the +following form to the file generation set named +.Cm rawstats : +.Bd -literal +50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the remote peer or clock address followed by the local address +in dotted\-quad notation. +The final four fields show the originate, +receive, transmit and final NTP timestamps in order. +The timestamp +values are as received and before processing by the various data +smoothing and mitigation algorithms. +.It Cm sysstats +Enables recording of ntpd statistics counters on a periodic basis. +Each +hour a line of the following form is appended to the file generation +set named +.Cm sysstats : +.Bd -literal +50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The remaining ten fields show +the statistics counter values accumulated since the last generated +line. +.Bl -tag -width indent +.It Time since restart Cm 36000 +Time in hours since the system was last rebooted. +.It Packets received Cm 81965 +Total number of packets received. +.It Packets processed Cm 0 +Number of packets received in response to previous packets sent +.It Current version Cm 9546 +Number of packets matching the current NTP version. +.It Previous version Cm 56 +Number of packets matching the previous NTP version. +.It Bad version Cm 71793 +Number of packets matching neither NTP version. +.It Access denied Cm 512 +Number of packets denied access for any reason. +.It Bad length or format Cm 540 +Number of packets with invalid length, format or port number. +.It Bad authentication Cm 10 +Number of packets not verified as authentic. +.It Rate exceeded Cm 147 +Number of packets discarded due to rate limitation. +.El +.It Cm statsdir Ar directory_path +Indicates the full path of a directory where statistics files +should be created (see below). +This keyword allows +the (otherwise constant) +.Cm filegen +filename prefix to be modified for file generation sets, which +is useful for handling statistics logs. +.It Cm filegen Ar name Xo +.Op Cm file Ar filename +.Op Cm type Ar typename +.Op Cm link | nolink +.Op Cm enable | disable +.Xc +Configures setting of generation file set name. +Generation +file sets provide a means for handling files that are +continuously growing during the lifetime of a server. +Server statistics are a typical example for such files. +Generation file sets provide access to a set of files used +to store the actual data. +At any time at most one element +of the set is being written to. +The type given specifies +when and how data will be directed to a new element of the set. +This way, information stored in elements of a file set +that are currently unused are available for administrational +operations without the risk of disturbing the operation of ntpd. +(Most important: they can be removed to free space for new data +produced.) +.Pp +Note that this command can be sent from the +.Xr ntpdc 1ntpdcmdoc +program running at a remote location. +.Bl -tag -width indent +.It Cm name +This is the type of the statistics records, as shown in the +.Cm statistics +command. +.It Cm file Ar filename +This is the file name for the statistics records. +Filenames of set +members are built from three concatenated elements +.Ar Cm prefix , +.Ar Cm filename +and +.Ar Cm suffix : +.Bl -tag -width indent +.It Cm prefix +This is a constant filename path. +It is not subject to +modifications via the +.Ar filegen +option. +It is defined by the +server, usually specified as a compile\-time constant. +It may, +however, be configurable for individual file generation sets +via other commands. +For example, the prefix used with +.Ar loopstats +and +.Ar peerstats +generation can be configured using the +.Ar statsdir +option explained above. +.It Cm filename +This string is directly concatenated to the prefix mentioned +above (no intervening +.Ql / ) . +This can be modified using +the file argument to the +.Ar filegen +statement. +No +.Pa .. +elements are +allowed in this component to prevent filenames referring to +parts outside the filesystem hierarchy denoted by +.Ar prefix . +.It Cm suffix +This part is reflects individual elements of a file set. +It is +generated according to the type of a file set. +.El +.It Cm type Ar typename +A file generation set is characterized by its type. +The following +types are supported: +.Bl -tag -width indent +.It Cm none +The file set is actually a single plain file. +.It Cm pid +One element of file set is used per incarnation of a ntpd +server. +This type does not perform any changes to file set +members during runtime, however it provides an easy way of +separating files belonging to different +.Xr ntpd 1ntpdmdoc +server incarnations. +The set member filename is built by appending a +.Ql \&. +to concatenated +.Ar prefix +and +.Ar filename +strings, and +appending the decimal representation of the process ID of the +.Xr ntpd 1ntpdmdoc +server process. +.It Cm day +One file generation set element is created per day. +A day is +defined as the period between 00:00 and 24:00 UTC. +The file set +member suffix consists of a +.Ql \&. +and a day specification in +the form +.Cm YYYYMMdd . +.Cm YYYY +is a 4\-digit year number (e.g., 1992). +.Cm MM +is a two digit month number. +.Cm dd +is a two digit day number. +Thus, all information written at 10 December 1992 would end up +in a file named +.Ar prefix +.Ar filename Ns .19921210 . +.It Cm week +Any file set member contains data related to a certain week of +a year. +The term week is defined by computing day\-of\-year +modulo 7. +Elements of such a file generation set are +distinguished by appending the following suffix to the file set +filename base: A dot, a 4\-digit year number, the letter +.Cm W , +and a 2\-digit week number. +For example, information from January, +10th 1992 would end up in a file with suffix +.No . Ns Ar 1992W1 . +.It Cm month +One generation file set element is generated per month. +The +file name suffix consists of a dot, a 4\-digit year number, and +a 2\-digit month. +.It Cm year +One generation file element is generated per year. +The filename +suffix consists of a dot and a 4 digit year number. +.It Cm age +This type of file generation sets changes to a new element of +the file set every 24 hours of server operation. +The filename +suffix consists of a dot, the letter +.Cm a , +and an 8\-digit number. +This number is taken to be the number of seconds the server is +running at the start of the corresponding 24\-hour period. +Information is only written to a file generation by specifying +.Cm enable ; +output is prevented by specifying +.Cm disable . +.El +.It Cm link | nolink +It is convenient to be able to access the current element of a file +generation set by a fixed name. +This feature is enabled by +specifying +.Cm link +and disabled using +.Cm nolink . +If link is specified, a +hard link from the current file set element to a file without +suffix is created. +When there is already a file with this name and +the number of links of this file is one, it is renamed appending a +dot, the letter +.Cm C , +and the pid of the ntpd server process. +When the +number of links is greater than one, the file is unlinked. +This +allows the current file to be accessed by a constant name. +.It Cm enable \&| Cm disable +Enables or disables the recording function. +.El +.El +.El +.Sh Access Control Support +The +.Xr ntpd 1ntpdmdoc +daemon implements a general purpose address/mask based restriction +list. +The list contains address/match entries sorted first +by increasing address values and and then by increasing mask values. +A match occurs when the bitwise AND of the mask and the packet +source address is equal to the bitwise AND of the mask and +address in the list. +The list is searched in order with the +last match found defining the restriction flags associated +with the entry. +Additional information and examples can be found in the +.Qq Notes on Configuring NTP and Setting up a NTP Subnet +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Pp +The restriction facility was implemented in conformance +with the access policies for the original NSFnet backbone +time servers. +Later the facility was expanded to deflect +cryptographic and clogging attacks. +While this facility may +be useful for keeping unwanted or broken or malicious clients +from congesting innocent servers, it should not be considered +an alternative to the NTP authentication facilities. +Source address based restrictions are easily circumvented +by a determined cracker. +.Pp +Clients can be denied service because they are explicitly +included in the restrict list created by the restrict command +or implicitly as the result of cryptographic or rate limit +violations. +Cryptographic violations include certificate +or identity verification failure; rate limit violations generally +result from defective NTP implementations that send packets +at abusive rates. +Some violations cause denied service +only for the offending packet, others cause denied service +for a timed period and others cause the denied service for +an indefinate period. +When a client or network is denied access +for an indefinate period, the only way at present to remove +the restrictions is by restarting the server. +.Ss The Kiss\-of\-Death Packet +Ordinarily, packets denied service are simply dropped with no +further action except incrementing statistics counters. +Sometimes a +more proactive response is needed, such as a server message that +explicitly requests the client to stop sending and leave a message +for the system operator. +A special packet format has been created +for this purpose called the "kiss\-of\-death" (KoD) packet. +KoD packets have the leap bits set unsynchronized and stratum set +to zero and the reference identifier field set to a four\-byte +ASCII code. +If the +.Cm noserve +or +.Cm notrust +flag of the matching restrict list entry is set, +the code is "DENY"; if the +.Cm limited +flag is set and the rate limit +is exceeded, the code is "RATE". +Finally, if a cryptographic violation occurs, the code is "CRYP". +.Pp +A client receiving a KoD performs a set of sanity checks to +minimize security exposure, then updates the stratum and +reference identifier peer variables, sets the access +denied (TEST4) bit in the peer flash variable and sends +a message to the log. +As long as the TEST4 bit is set, +the client will send no further packets to the server. +The only way at present to recover from this condition is +to restart the protocol at both the client and server. +This +happens automatically at the client when the association times out. +It will happen at the server only if the server operator cooperates. +.Ss Access Control Commands +.Bl -tag -width indent +.It Xo Ic discard +.Op Cm average Ar avg +.Op Cm minimum Ar min +.Op Cm monitor Ar prob +.Xc +Set the parameters of the +.Cm limited +facility which protects the server from +client abuse. +The +.Cm average +subcommand specifies the minimum average packet +spacing, while the +.Cm minimum +subcommand specifies the minimum packet spacing. +Packets that violate these minima are discarded +and a kiss\-o'\-death packet returned if enabled. +The default +minimum average and minimum are 5 and 2, respectively. +The monitor subcommand specifies the probability of discard +for packets that overflow the rate\-control window. +.It Xo Ic restrict address +.Op Cm mask Ar mask +.Op Ar flag ... +.Xc +The +.Ar address +argument expressed in +dotted\-quad form is the address of a host or network. +Alternatively, the +.Ar address +argument can be a valid host DNS name. +The +.Ar mask +argument expressed in dotted\-quad form defaults to +.Cm 255.255.255.255 , +meaning that the +.Ar address +is treated as the address of an individual host. +A default entry (address +.Cm 0.0.0.0 , +mask +.Cm 0.0.0.0 ) +is always included and is always the first entry in the list. +Note that text string +.Cm default , +with no mask option, may +be used to indicate the default entry. +In the current implementation, +.Cm flag +always +restricts access, i.e., an entry with no flags indicates that free +access to the server is to be given. +The flags are not orthogonal, +in that more restrictive flags will often make less restrictive +ones redundant. +The flags can generally be classed into two +categories, those which restrict time service and those which +restrict informational queries and attempts to do run\-time +reconfiguration of the server. +One or more of the following flags +may be specified: +.Bl -tag -width indent +.It Cm ignore +Deny packets of all kinds, including +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries. +.It Cm kod +If this flag is set when an access violation occurs, a kiss\-o'\-death +(KoD) packet is sent. +KoD packets are rate limited to no more than one +per second. +If another KoD packet occurs within one second after the +last one, the packet is dropped. +.It Cm limited +Deny service if the packet spacing violates the lower limits specified +in the discard command. +A history of clients is kept using the +monitoring capability of +.Xr ntpd 1ntpdmdoc . +Thus, monitoring is always active as +long as there is a restriction entry with the +.Cm limited +flag. +.It Cm lowpriotrap +Declare traps set by matching hosts to be low priority. +The +number of traps a server can maintain is limited (the current limit +is 3). +Traps are usually assigned on a first come, first served +basis, with later trap requestors being denied service. +This flag +modifies the assignment algorithm by allowing low priority traps to +be overridden by later requests for normal priority traps. +.It Cm nomodify +Deny +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries which attempt to modify the state of the +server (i.e., run time reconfiguration). +Queries which return +information are permitted. +.It Cm noquery +Deny +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries. +Time service is not affected. +.It Cm nopeer +Deny packets which would result in mobilizing a new association. +This +includes broadcast and symmetric active packets when a configured +association does not exist. +It also includes +.Cm pool +associations, so if you want to use servers from a +.Cm pool +directive and also want to use +.Cm nopeer +by default, you'll want a +.Cm "restrict source ..." line as well that does +.It not +include the +.Cm nopeer +directive. +.It Cm noserve +Deny all packets except +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries. +.It Cm notrap +Decline to provide mode 6 control message trap service to matching +hosts. +The trap service is a subsystem of the ntpdq control message +protocol which is intended for use by remote event logging programs. +.It Cm notrust +Deny service unless the packet is cryptographically authenticated. +.It Cm ntpport +This is actually a match algorithm modifier, rather than a +restriction flag. +Its presence causes the restriction entry to be +matched only if the source port in the packet is the standard NTP +UDP port (123). +Both +.Cm ntpport +and +.Cm non\-ntpport +may +be specified. +The +.Cm ntpport +is considered more specific and +is sorted later in the list. +.It Cm version +Deny packets that do not match the current NTP version. +.El +.Pp +Default restriction list entries with the flags ignore, interface, +ntpport, for each of the local host's interface addresses are +inserted into the table at startup to prevent the server +from attempting to synchronize to its own time. +A default entry is also always present, though if it is +otherwise unconfigured; no flags are associated +with the default entry (i.e., everything besides your own +NTP server is unrestricted). +.El +.Sh Automatic NTP Configuration Options +.Ss Manycasting +Manycasting is a automatic discovery and configuration paradigm +new to NTPv4. +It is intended as a means for a multicast client +to troll the nearby network neighborhood to find cooperating +manycast servers, validate them using cryptographic means +and evaluate their time values with respect to other servers +that might be lurking in the vicinity. +The intended result is that each manycast client mobilizes +client associations with some number of the "best" +of the nearby manycast servers, yet automatically reconfigures +to sustain this number of servers should one or another fail. +.Pp +Note that the manycasting paradigm does not coincide +with the anycast paradigm described in RFC\-1546, +which is designed to find a single server from a clique +of servers providing the same service. +The manycast paradigm is designed to find a plurality +of redundant servers satisfying defined optimality criteria. +.Pp +Manycasting can be used with either symmetric key +or public key cryptography. +The public key infrastructure (PKI) +offers the best protection against compromised keys +and is generally considered stronger, at least with relatively +large key sizes. +It is implemented using the Autokey protocol and +the OpenSSL cryptographic library available from +.Li http://www.openssl.org/ . +The library can also be used with other NTPv4 modes +as well and is highly recommended, especially for broadcast modes. +.Pp +A persistent manycast client association is configured +using the manycastclient command, which is similar to the +server command but with a multicast (IPv4 class +.Cm D +or IPv6 prefix +.Cm FF ) +group address. +The IANA has designated IPv4 address 224.1.1.1 +and IPv6 address FF05::101 (site local) for NTP. +When more servers are needed, it broadcasts manycast +client messages to this address at the minimum feasible rate +and minimum feasible time\-to\-live (TTL) hops, depending +on how many servers have already been found. +There can be as many manycast client associations +as different group address, each one serving as a template +for a future ephemeral unicast client/server association. +.Pp +Manycast servers configured with the +.Ic manycastserver +command listen on the specified group address for manycast +client messages. +Note the distinction between manycast client, +which actively broadcasts messages, and manycast server, +which passively responds to them. +If a manycast server is +in scope of the current TTL and is itself synchronized +to a valid source and operating at a stratum level equal +to or lower than the manycast client, it replies to the +manycast client message with an ordinary unicast server message. +.Pp +The manycast client receiving this message mobilizes +an ephemeral client/server association according to the +matching manycast client template, but only if cryptographically +authenticated and the server stratum is less than or equal +to the client stratum. +Authentication is explicitly required +and either symmetric key or public key (Autokey) can be used. +Then, the client polls the server at its unicast address +in burst mode in order to reliably set the host clock +and validate the source. +This normally results +in a volley of eight client/server at 2\-s intervals +during which both the synchronization and cryptographic +protocols run concurrently. +Following the volley, +the client runs the NTP intersection and clustering +algorithms, which act to discard all but the "best" +associations according to stratum and synchronization +distance. +The surviving associations then continue +in ordinary client/server mode. +.Pp +The manycast client polling strategy is designed to reduce +as much as possible the volume of manycast client messages +and the effects of implosion due to near\-simultaneous +arrival of manycast server messages. +The strategy is determined by the +.Ic manycastclient , +.Ic tos +and +.Ic ttl +configuration commands. +The manycast poll interval is +normally eight times the system poll interval, +which starts out at the +.Cm minpoll +value specified in the +.Ic manycastclient , +command and, under normal circumstances, increments to the +.Cm maxpolll +value specified in this command. +Initially, the TTL is +set at the minimum hops specified by the ttl command. +At each retransmission the TTL is increased until reaching +the maximum hops specified by this command or a sufficient +number client associations have been found. +Further retransmissions use the same TTL. +.Pp +The quality and reliability of the suite of associations +discovered by the manycast client is determined by the NTP +mitigation algorithms and the +.Cm minclock +and +.Cm minsane +values specified in the +.Ic tos +configuration command. +At least +.Cm minsane +candidate servers must be available and the mitigation +algorithms produce at least +.Cm minclock +survivors in order to synchronize the clock. +Byzantine agreement principles require at least four +candidates in order to correctly discard a single falseticker. +For legacy purposes, +.Cm minsane +defaults to 1 and +.Cm minclock +defaults to 3. +For manycast service +.Cm minsane +should be explicitly set to 4, assuming at least that +number of servers are available. +.Pp +If at least +.Cm minclock +servers are found, the manycast poll interval is immediately +set to eight times +.Cm maxpoll . +If less than +.Cm minclock +servers are found when the TTL has reached the maximum hops, +the manycast poll interval is doubled. +For each transmission +after that, the poll interval is doubled again until +reaching the maximum of eight times +.Cm maxpoll . +Further transmissions use the same poll interval and +TTL values. +Note that while all this is going on, +each client/server association found is operating normally +it the system poll interval. +.Pp +Administratively scoped multicast boundaries are normally +specified by the network router configuration and, +in the case of IPv6, the link/site scope prefix. +By default, the increment for TTL hops is 32 starting +from 31; however, the +.Ic ttl +configuration command can be +used to modify the values to match the scope rules. +.Pp +It is often useful to narrow the range of acceptable +servers which can be found by manycast client associations. +Because manycast servers respond only when the client +stratum is equal to or greater than the server stratum, +primary (stratum 1) servers fill find only primary servers +in TTL range, which is probably the most common objective. +However, unless configured otherwise, all manycast clients +in TTL range will eventually find all primary servers +in TTL range, which is probably not the most common +objective in large networks. +The +.Ic tos +command can be used to modify this behavior. +Servers with stratum below +.Cm floor +or above +.Cm ceiling +specified in the +.Ic tos +command are strongly discouraged during the selection +process; however, these servers may be temporally +accepted if the number of servers within TTL range is +less than +.Cm minclock . +.Pp +The above actions occur for each manycast client message, +which repeats at the designated poll interval. +However, once the ephemeral client association is mobilized, +subsequent manycast server replies are discarded, +since that would result in a duplicate association. +If during a poll interval the number of client associations +falls below +.Cm minclock , +all manycast client prototype associations are reset +to the initial poll interval and TTL hops and operation +resumes from the beginning. +It is important to avoid +frequent manycast client messages, since each one requires +all manycast servers in TTL range to respond. +The result could well be an implosion, either minor or major, +depending on the number of servers in range. +The recommended value for +.Cm maxpoll +is 12 (4,096 s). +.Pp +It is possible and frequently useful to configure a host +as both manycast client and manycast server. +A number of hosts configured this way and sharing a common +group address will automatically organize themselves +in an optimum configuration based on stratum and +synchronization distance. +For example, consider an NTP +subnet of two primary servers and a hundred or more +dependent clients. +With two exceptions, all servers +and clients have identical configuration files including both +.Ic multicastclient +and +.Ic multicastserver +commands using, for instance, multicast group address +239.1.1.1. +The only exception is that each primary server +configuration file must include commands for the primary +reference source such as a GPS receiver. +.Pp +The remaining configuration files for all secondary +servers and clients have the same contents, except for the +.Ic tos +command, which is specific for each stratum level. +For stratum 1 and stratum 2 servers, that command is +not necessary. +For stratum 3 and above servers the +.Cm floor +value is set to the intended stratum number. +Thus, all stratum 3 configuration files are identical, +all stratum 4 files are identical and so forth. +.Pp +Once operations have stabilized in this scenario, +the primary servers will find the primary reference source +and each other, since they both operate at the same +stratum (1), but not with any secondary server or client, +since these operate at a higher stratum. +The secondary +servers will find the servers at the same stratum level. +If one of the primary servers loses its GPS receiver, +it will continue to operate as a client and other clients +will time out the corresponding association and +re\-associate accordingly. +.Pp +Some administrators prefer to avoid running +.Xr ntpd 1ntpdmdoc +continuously and run either +.Xr sntp 1sntpmdoc +or +.Xr ntpd 1ntpdmdoc +.Fl q +as a cron job. +In either case the servers must be +configured in advance and the program fails if none are +available when the cron job runs. +A really slick +application of manycast is with +.Xr ntpd 1ntpdmdoc +.Fl q . +The program wakes up, scans the local landscape looking +for the usual suspects, selects the best from among +the rascals, sets the clock and then departs. +Servers do not have to be configured in advance and +all clients throughout the network can have the same +configuration file. +.Ss Manycast Interactions with Autokey +Each time a manycast client sends a client mode packet +to a multicast group address, all manycast servers +in scope generate a reply including the host name +and status word. +The manycast clients then run +the Autokey protocol, which collects and verifies +all certificates involved. +Following the burst interval +all but three survivors are cast off, +but the certificates remain in the local cache. +It often happens that several complete signing trails +from the client to the primary servers are collected in this way. +.Pp +About once an hour or less often if the poll interval +exceeds this, the client regenerates the Autokey key list. +This is in general transparent in client/server mode. +However, about once per day the server private value +used to generate cookies is refreshed along with all +manycast client associations. +In this case all +cryptographic values including certificates is refreshed. +If a new certificate has been generated since +the last refresh epoch, it will automatically revoke +all prior certificates that happen to be in the +certificate cache. +At the same time, the manycast +scheme starts all over from the beginning and +the expanding ring shrinks to the minimum and increments +from there while collecting all servers in scope. +.Ss Manycast Options +.Bl -tag -width indent +.It Xo Ic tos +.Oo +.Cm ceiling Ar ceiling | +.Cm cohort { 0 | 1 } | +.Cm floor Ar floor | +.Cm minclock Ar minclock | +.Cm minsane Ar minsane +.Oc +.Xc +This command affects the clock selection and clustering +algorithms. +It can be used to select the quality and +quantity of peers used to synchronize the system clock +and is most useful in manycast mode. +The variables operate +as follows: +.Bl -tag -width indent +.It Cm ceiling Ar ceiling +Peers with strata above +.Cm ceiling +will be discarded if there are at least +.Cm minclock +peers remaining. +This value defaults to 15, but can be changed +to any number from 1 to 15. +.It Cm cohort Bro 0 | 1 Brc +This is a binary flag which enables (0) or disables (1) +manycast server replies to manycast clients with the same +stratum level. +This is useful to reduce implosions where +large numbers of clients with the same stratum level +are present. +The default is to enable these replies. +.It Cm floor Ar floor +Peers with strata below +.Cm floor +will be discarded if there are at least +.Cm minclock +peers remaining. +This value defaults to 1, but can be changed +to any number from 1 to 15. +.It Cm minclock Ar minclock +The clustering algorithm repeatedly casts out outlier +associations until no more than +.Cm minclock +associations remain. +This value defaults to 3, +but can be changed to any number from 1 to the number of +configured sources. +.It Cm minsane Ar minsane +This is the minimum number of candidates available +to the clock selection algorithm in order to produce +one or more truechimers for the clustering algorithm. +If fewer than this number are available, the clock is +undisciplined and allowed to run free. +The default is 1 +for legacy purposes. +However, according to principles of +Byzantine agreement, +.Cm minsane +should be at least 4 in order to detect and discard +a single falseticker. +.El +.It Cm ttl Ar hop ... +This command specifies a list of TTL values in increasing +order, up to 8 values can be specified. +In manycast mode these values are used in turn +in an expanding\-ring search. +The default is eight +multiples of 32 starting at 31. +.El +.Sh Reference Clock Support +The NTP Version 4 daemon supports some three dozen different radio, +satellite and modem reference clocks plus a special pseudo\-clock +used for backup or when no other clock source is available. +Detailed descriptions of individual device drivers and options can +be found in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +Additional information can be found in the pages linked +there, including the +.Qq Debugging Hints for Reference Clock Drivers +and +.Qq How To Write a Reference Clock Driver +pages +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +In addition, support for a PPS +signal is available as described in the +.Qq Pulse\-per\-second (PPS) Signal Interfacing +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +Many +drivers support special line discipline/streams modules which can +significantly improve the accuracy using the driver. +These are +described in the +.Qq Line Disciplines and Streams Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Pp +A reference clock will generally (though not always) be a radio +timecode receiver which is synchronized to a source of standard +time such as the services offered by the NRC in Canada and NIST and +USNO in the US. +The interface between the computer and the timecode +receiver is device dependent, but is usually a serial port. +A +device driver specific to each reference clock must be selected and +compiled in the distribution; however, most common radio, satellite +and modem clocks are included by default. +Note that an attempt to +configure a reference clock when the driver has not been compiled +or the hardware port has not been appropriately configured results +in a scalding remark to the system log file, but is otherwise non +hazardous. +.Pp +For the purposes of configuration, +.Xr ntpd 1ntpdmdoc +treats +reference clocks in a manner analogous to normal NTP peers as much +as possible. +Reference clocks are identified by a syntactically +correct but invalid IP address, in order to distinguish them from +normal NTP peers. +Reference clock addresses are of the form +.Sm off +.Li 127.127. Ar t . Ar u , +.Sm on +where +.Ar t +is an integer +denoting the clock type and +.Ar u +indicates the unit +number in the range 0\-3. +While it may seem overkill, it is in fact +sometimes useful to configure multiple reference clocks of the same +type, in which case the unit numbers must be unique. +.Pp +The +.Ic server +command is used to configure a reference +clock, where the +.Ar address +argument in that command +is the clock address. +The +.Cm key , +.Cm version +and +.Cm ttl +options are not used for reference clock support. +The +.Cm mode +option is added for reference clock support, as +described below. +The +.Cm prefer +option can be useful to +persuade the server to cherish a reference clock with somewhat more +enthusiasm than other reference clocks or peers. +Further +information on this option can be found in the +.Qq Mitigation Rules and the prefer Keyword +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +page. +The +.Cm minpoll +and +.Cm maxpoll +options have +meaning only for selected clock drivers. +See the individual clock +driver document pages for additional information. +.Pp +The +.Ic fudge +command is used to provide additional +information for individual clock drivers and normally follows +immediately after the +.Ic server +command. +The +.Ar address +argument specifies the clock address. +The +.Cm refid +and +.Cm stratum +options can be used to +override the defaults for the device. +There are two optional +device\-dependent time offsets and four flags that can be included +in the +.Ic fudge +command as well. +.Pp +The stratum number of a reference clock is by default zero. +Since the +.Xr ntpd 1ntpdmdoc +daemon adds one to the stratum of each +peer, a primary server ordinarily displays an external stratum of +one. +In order to provide engineered backups, it is often useful to +specify the reference clock stratum as greater than zero. +The +.Cm stratum +option is used for this purpose. +Also, in cases +involving both a reference clock and a pulse\-per\-second (PPS) +discipline signal, it is useful to specify the reference clock +identifier as other than the default, depending on the driver. +The +.Cm refid +option is used for this purpose. +Except where noted, +these options apply to all clock drivers. +.Ss Reference Clock Commands +.Bl -tag -width indent +.It Xo Ic server +.Sm off +.Li 127.127. Ar t . Ar u +.Sm on +.Op Cm prefer +.Op Cm mode Ar int +.Op Cm minpoll Ar int +.Op Cm maxpoll Ar int +.Xc +This command can be used to configure reference clocks in +special ways. +The options are interpreted as follows: +.Bl -tag -width indent +.It Cm prefer +Marks the reference clock as preferred. +All other things being +equal, this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +.Qq Mitigation Rules and the prefer Keyword +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +for further information. +.It Cm mode Ar int +Specifies a mode number which is interpreted in a +device\-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.It Cm minpoll Ar int +.It Cm maxpoll Ar int +These options specify the minimum and maximum polling interval +for reference clock messages, as a power of 2 in seconds +For +most directly connected reference clocks, both +.Cm minpoll +and +.Cm maxpoll +default to 6 (64 s). +For modem reference clocks, +.Cm minpoll +defaults to 10 (17.1 m) and +.Cm maxpoll +defaults to 14 (4.5 h). +The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. +.El +.It Xo Ic fudge +.Sm off +.Li 127.127. Ar t . Ar u +.Sm on +.Op Cm time1 Ar sec +.Op Cm time2 Ar sec +.Op Cm stratum Ar int +.Op Cm refid Ar string +.Op Cm mode Ar int +.Op Cm flag1 Cm 0 \&| Cm 1 +.Op Cm flag2 Cm 0 \&| Cm 1 +.Op Cm flag3 Cm 0 \&| Cm 1 +.Op Cm flag4 Cm 0 \&| Cm 1 +.Xc +This command can be used to configure reference clocks in +special ways. +It must immediately follow the +.Ic server +command which configures the driver. +Note that the same capability +is possible at run time using the +.Xr ntpdc 1ntpdcmdoc +program. +The options are interpreted as +follows: +.Bl -tag -width indent +.It Cm time1 Ar sec +Specifies a constant to be added to the time offset produced by +the driver, a fixed\-point decimal number in seconds. +This is used +as a calibration constant to adjust the nominal time offset of a +particular clock to agree with an external standard, such as a +precision PPS signal. +It also provides a way to correct a +systematic error or bias due to serial port or operating system +latencies, different cable lengths or receiver internal delay. +The +specified offset is in addition to the propagation delay provided +by other means, such as internal DIPswitches. +Where a calibration +for an individual system and driver is available, an approximate +correction is noted in the driver documentation pages. +Note: in order to facilitate calibration when more than one +radio clock or PPS signal is supported, a special calibration +feature is available. +It takes the form of an argument to the +.Ic enable +command described in +.Sx Miscellaneous Options +page and operates as described in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.It Cm time2 Ar secs +Specifies a fixed\-point decimal number in seconds, which is +interpreted in a driver\-dependent way. +See the descriptions of +specific drivers in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.It Cm stratum Ar int +Specifies the stratum number assigned to the driver, an integer +between 0 and 15. +This number overrides the default stratum number +ordinarily assigned by the driver itself, usually zero. +.It Cm refid Ar string +Specifies an ASCII string of from one to four characters which +defines the reference identifier used by the driver. +This string +overrides the default identifier ordinarily assigned by the driver +itself. +.It Cm mode Ar int +Specifies a mode number which is interpreted in a +device\-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.It Cm flag1 Cm 0 \&| Cm 1 +.It Cm flag2 Cm 0 \&| Cm 1 +.It Cm flag3 Cm 0 \&| Cm 1 +.It Cm flag4 Cm 0 \&| Cm 1 +These four flags are used for customizing the clock driver. +The +interpretation of these values, and whether they are used at all, +is a function of the particular clock driver. +However, by +convention +.Cm flag4 +is used to enable recording monitoring +data to the +.Cm clockstats +file configured with the +.Ic filegen +command. +Further information on the +.Ic filegen +command can be found in +.Sx Monitoring Options . +.El +.El +.Sh Miscellaneous Options +.Bl -tag -width indent +.It Ic broadcastdelay Ar seconds +The broadcast and multicast modes require a special calibration +to determine the network delay between the local and remote +servers. +Ordinarily, this is done automatically by the initial +protocol exchanges between the client and server. +In some cases, +the calibration procedure may fail due to network or server access +controls, for example. +This command specifies the default delay to +be used under these circumstances. +Typically (for Ethernet), a +number between 0.003 and 0.007 seconds is appropriate. +The default +when this command is not used is 0.004 seconds. +.It Ic calldelay Ar delay +This option controls the delay in seconds between the first and second +packets sent in burst or iburst mode to allow additional time for a modem +or ISDN call to complete. +.It Ic driftfile Ar driftfile +This command specifies the complete path and name of the file used to +record the frequency of the local clock oscillator. +This is the same +operation as the +.Fl f +command line option. +If the file exists, it is read at +startup in order to set the initial frequency and then updated once per +hour with the current frequency computed by the daemon. +If the file name is +specified, but the file itself does not exist, the starts with an initial +frequency of zero and creates the file when writing it for the first time. +If this command is not given, the daemon will always start with an initial +frequency of zero. +.Pp +The file format consists of a single line containing a single +floating point number, which records the frequency offset measured +in parts\-per\-million (PPM). +The file is updated by first writing +the current drift value into a temporary file and then renaming +this file to replace the old version. +This implies that +.Xr ntpd 1ntpdmdoc +must have write permission for the directory the +drift file is located in, and that file system links, symbolic or +otherwise, should be avoided. +.It Ic dscp Ar value +This option specifies the Differentiated Services Control Point (DSCP) value, +a 6\-bit code. The default value is 46, signifying Expedited Forwarding. +.It Xo Ic enable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm mode7 | monitor | +.Cm ntp | Cm stats +.Oc +.Xc +.It Xo Ic disable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm mode7 | monitor | +.Cm ntp | Cm stats +.Oc +.Xc +Provides a way to enable or disable various server options. +Flags not mentioned are unaffected. +Note that all of these flags +can be controlled remotely using the +.Xr ntpdc 1ntpdcmdoc +utility program. +.Bl -tag -width indent +.It Cm auth +Enables the server to synchronize with unconfigured peers only if the +peer has been correctly authenticated using either public key or +private key cryptography. +The default for this flag is +.Ic enable . +.It Cm bclient +Enables the server to listen for a message from a broadcast or +multicast server, as in the +.Ic multicastclient +command with default +address. +The default for this flag is +.Ic disable . +.It Cm calibrate +Enables the calibrate feature for reference clocks. +The default for +this flag is +.Ic disable . +.It Cm kernel +Enables the kernel time discipline, if available. +The default for this +flag is +.Ic enable +if support is available, otherwise +.Ic disable . +.It Cm mode7 +Enables processing of NTP mode 7 implementation\-specific requests +which are used by the deprecated +.Xr ntpdc 1ntpdcmdoc +program. +The default for this flag is disable. +This flag is excluded from runtime configuration using +.Xr ntpq 1ntpqmdoc . +The +.Xr ntpq 1ntpqmdoc +program provides the same capabilities as +.Xr ntpdc 1ntpdcmdoc +using standard mode 6 requests. +.It Cm monitor +Enables the monitoring facility. +See the +.Xr ntpdc 1ntpdcmdoc +program +and the +.Ic monlist +command or further information. +The +default for this flag is +.Ic enable . +.It Cm ntp +Enables time and frequency discipline. +In effect, this switch opens and +closes the feedback loop, which is useful for testing. +The default for +this flag is +.Ic enable . +.It Cm stats +Enables the statistics facility. +See the +.Sx Monitoring Options +section for further information. +The default for this flag is +.Ic disable . +.El +.It Ic includefile Ar includefile +This command allows additional configuration commands +to be included from a separate file. +Include files may +be nested to a depth of five; upon reaching the end of any +include file, command processing resumes in the previous +configuration file. +This option is useful for sites that run +.Xr ntpd 1ntpdmdoc +on multiple hosts, with (mostly) common options (e.g., a +restriction list). +.It Ic leapsmearinterval Ar seconds +This EXPERIMENTAL option is only available if +.Xr ntpd 1ntpdmdoc +was built with the +.Cm \-\-enable\-leap\-smear +option to the +.Cm configure +script. +It specifies the interval over which a leap second correction will be applied. +Recommended values for this option are between +7200 (2 hours) and 86400 (24 hours). +.Sy DO NOT USE THIS OPTION ON PUBLIC\-ACCESS SERVERS! +See http://bugs.ntp.org/2855 for more information. +.It Ic logconfig Ar configkeyword +This command controls the amount and type of output written to +the system +.Xr syslog 3 +facility or the alternate +.Ic logfile +log file. +By default, all output is turned on. +All +.Ar configkeyword +keywords can be prefixed with +.Ql = , +.Ql + +and +.Ql \- , +where +.Ql = +sets the +.Xr syslog 3 +priority mask, +.Ql + +adds and +.Ql \- +removes +messages. +.Xr syslog 3 +messages can be controlled in four +classes +.Po +.Cm clock , +.Cm peer , +.Cm sys +and +.Cm sync +.Pc . +Within these classes four types of messages can be +controlled: informational messages +.Po +.Cm info +.Pc , +event messages +.Po +.Cm events +.Pc , +statistics messages +.Po +.Cm statistics +.Pc +and +status messages +.Po +.Cm status +.Pc . +.Pp +Configuration keywords are formed by concatenating the message class with +the event class. +The +.Cm all +prefix can be used instead of a message class. +A +message class may also be followed by the +.Cm all +keyword to enable/disable all +messages of the respective message class.Thus, a minimal log configuration +could look like this: +.Bd -literal +logconfig =syncstatus +sysevents +.Ed +.Pp +This would just list the synchronizations state of +.Xr ntpd 1ntpdmdoc +and the major system events. +For a simple reference server, the +following minimum message configuration could be useful: +.Bd -literal +logconfig =syncall +clockall +.Ed +.Pp +This configuration will list all clock information and +synchronization information. +All other events and messages about +peers, system events and so on is suppressed. +.It Ic logfile Ar logfile +This command specifies the location of an alternate log file to +be used instead of the default system +.Xr syslog 3 +facility. +This is the same operation as the \-l command line option. +.It Ic setvar Ar variable Op Cm default +This command adds an additional system variable. +These +variables can be used to distribute additional information such as +the access policy. +If the variable of the form +.Sm off +.Va name = Ar value +.Sm on +is followed by the +.Cm default +keyword, the +variable will be listed as part of the default system variables +.Po +.Xr ntpq 1ntpqmdoc +.Ic rv +command +.Pc ) . +These additional variables serve +informational purposes only. +They are not related to the protocol +other that they can be listed. +The known protocol variables will +always override any variables defined via the +.Ic setvar +mechanism. +There are three special variables that contain the names +of all variable of the same group. +The +.Va sys_var_list +holds +the names of all system variables. +The +.Va peer_var_list +holds +the names of all peer variables and the +.Va clock_var_list +holds the names of the reference clock variables. +.It Xo Ic tinker +.Oo +.Cm allan Ar allan | +.Cm dispersion Ar dispersion | +.Cm freq Ar freq | +.Cm huffpuff Ar huffpuff | +.Cm panic Ar panic | +.Cm step Ar step | +.Cm stepback Ar stepback | +.Cm stepfwd Ar stepfwd | +.Cm stepout Ar stepout +.Oc +.Xc +This command can be used to alter several system variables in +very exceptional circumstances. +It should occur in the +configuration file before any other configuration options. +The +default values of these variables have been carefully optimized for +a wide range of network speeds and reliability expectations. +In +general, they interact in intricate ways that are hard to predict +and some combinations can result in some very nasty behavior. +Very +rarely is it necessary to change the default values; but, some +folks cannot resist twisting the knobs anyway and this command is +for them. +Emphasis added: twisters are on their own and can expect +no help from the support group. +.Pp +The variables operate as follows: +.Bl -tag -width indent +.It Cm allan Ar allan +The argument becomes the new value for the minimum Allan +intercept, which is a parameter of the PLL/FLL clock discipline +algorithm. +The value in log2 seconds defaults to 7 (1024 s), which is also the lower +limit. +.It Cm dispersion Ar dispersion +The argument becomes the new value for the dispersion increase rate, +normally .000015 s/s. +.It Cm freq Ar freq +The argument becomes the initial value of the frequency offset in +parts\-per\-million. +This overrides the value in the frequency file, if +present, and avoids the initial training state if it is not. +.It Cm huffpuff Ar huffpuff +The argument becomes the new value for the experimental +huff\-n'\-puff filter span, which determines the most recent interval +the algorithm will search for a minimum delay. +The lower limit is +900 s (15 m), but a more reasonable value is 7200 (2 hours). +There +is no default, since the filter is not enabled unless this command +is given. +.It Cm panic Ar panic +The argument is the panic threshold, normally 1000 s. +If set to zero, +the panic sanity check is disabled and a clock offset of any value will +be accepted. +.It Cm step Ar step +The argument is the step threshold, which by default is 0.128 s. +It can +be set to any positive number in seconds. +If set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if the step threshold is set to zero or greater than the +default. +.It Cm stepback Ar stepback +The argument is the step threshold for the backward direction, +which by default is 0.128 s. +It can +be set to any positive number in seconds. +If both the forward and backward step thresholds are set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if +each direction of step threshold are either +set to zero or greater than .5 second. +.It Cm stepfwd Ar stepfwd +As for stepback, but for the forward direction. +.It Cm stepout Ar stepout +The argument is the stepout timeout, which by default is 900 s. +It can +be set to any positive number in seconds. +If set to zero, the stepout +pulses will not be suppressed. +.El +.It Xo Ic rlimit +.Oo +.Cm memlock Ar Nmegabytes | +.Cm stacksize Ar N4kPages +.Cm filenum Ar Nfiledescriptors +.Oc +.Xc +.Bl -tag -width indent +.It Cm memlock Ar Nmegabytes +Specify the number of megabytes of memory that should be +allocated and locked. +Probably only available under Linux, this option may be useful +when dropping root (the +.Fl i +option). +The default is 32 megabytes on non\-Linux machines, and \-1 under Linux. +-1 means "do not lock the process into memory". +0 means "lock whatever memory the process wants into memory". +.It Cm stacksize Ar N4kPages +Specifies the maximum size of the process stack on systems with the +.Fn mlockall +function. +Defaults to 50 4k pages (200 4k pages in OpenBSD). +.It Cm filenum Ar Nfiledescriptors +Specifies the maximum number of file descriptors ntpd may have open at once. Defaults to the system default. +.El +.It Xo Ic trap Ar host_address +.Op Cm port Ar port_number +.Op Cm interface Ar interface_address +.Xc +This command configures a trap receiver at the given host +address and port number for sending messages with the specified +local interface address. +If the port number is unspecified, a value +of 18447 is used. +If the interface address is not specified, the +message is sent with a source address of the local interface the +message is sent through. +Note that on a multihomed host the +interface used may vary from time to time with routing changes. +.Pp +The trap receiver will generally log event messages and other +information from the server in a log file. +While such monitor +programs may also request their own trap dynamically, configuring a +trap receiver will ensure that no messages are lost when the server +is started. +.It Cm hop Ar ... +This command specifies a list of TTL values in increasing order, up to 8 +values can be specified. +In manycast mode these values are used in turn in +an expanding\-ring search. +The default is eight multiples of 32 starting at +31. +.El +.Sh "OPTIONS" +.Bl -tag +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTP_CONF_\fP or \fBNTP_CONF\fP +.fi +.ad +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh FILES +.Bl -tag -width /etc/ntp.drift -compact +.It Pa /etc/ntp.conf +the default name of the configuration file +.It Pa ntp.keys +private MD5 keys +.It Pa ntpkey +RSA private key +.It Pa ntpkey_ Ns Ar host +RSA public key +.It Pa ntp_dh +Diffie\-Hellman agreement parameters +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntpd 1ntpdmdoc , +.Xr ntpdc 1ntpdcmdoc , +.Xr ntpq 1ntpqmdoc +.Pp +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +.Li http://www.ntp.org/ . +A snapshot of this documentation is available in HTML format in +.Pa /usr/share/doc/ntp . +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 4) +.%O RFC5905 +.Re +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh BUGS +The syntax checking is not picky; some combinations of +ridiculous and even hilarious options and modes may not be +detected. +.Pp +The +.Pa ntpkey_ Ns Ar host +files are really digital +certificates. +These should be obtained via secure directory +services when they become universally available. +.Pp +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +This document was derived from FreeBSD. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntp.conf\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.conf.def b/contrib/ntp/ntpd/ntp.conf.def new file mode 100644 index 000000000..43835bc76 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.conf.def @@ -0,0 +1,2843 @@ +/* -*- Mode: Text -*- */ + +autogen definitions options; + +#include copyright.def + +// We want the synopsis to be "/etc/ntp.conf" but we need the prog-name +// to be ntp.conf - the latter is also how autogen produces the output +// file name. +prog-name = "ntp.conf"; +file-path = "/etc/ntp.conf"; +prog-title = "Network Time Protocol (NTP) daemon configuration file format"; + +/* explain: Additional information whenever the usage routine is invoked */ +explain = <<- _END_EXPLAIN + _END_EXPLAIN; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +The +.Nm +configuration file is read at initial startup by the +.Xr ntpd 1ntpdmdoc +daemon in order to specify the synchronization sources, +modes and other related information. +Usually, it is installed in the +.Pa /etc +directory, +but could be installed elsewhere +(see the daemon's +.Fl c +command line option). +.Pp +The file format is similar to other +.Ux +configuration files. +Comments begin with a +.Ql # +character and extend to the end of the line; +blank lines are ignored. +Configuration commands consist of an initial keyword +followed by a list of arguments, +some of which may be optional, separated by whitespace. +Commands may not be continued over multiple lines. +Arguments may be host names, +host addresses written in numeric, dotted-quad form, +integers, floating point numbers (when specifying times in seconds) +and text strings. +.Pp +The rest of this page describes the configuration and control options. +The +.Qq Notes on Configuring NTP and Setting up an NTP Subnet +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +contains an extended discussion of these options. +In addition to the discussion of general +.Sx Configuration Options , +there are sections describing the following supported functionality +and the options used to control it: +.Bl -bullet -offset indent +.It +.Sx Authentication Support +.It +.Sx Monitoring Support +.It +.Sx Access Control Support +.It +.Sx Automatic NTP Configuration Options +.It +.Sx Reference Clock Support +.It +.Sx Miscellaneous Options +.El +.Pp +Following these is a section describing +.Sx Miscellaneous Options . +While there is a rich set of options available, +the only required option is one or more +.Ic pool , +.Ic server , +.Ic peer , +.Ic broadcast +or +.Ic manycastclient +commands. +.Sh Configuration Support +Following is a description of the configuration commands in +NTPv4. +These commands have the same basic functions as in NTPv3 and +in some cases new functions and new arguments. +There are two +classes of commands, configuration commands that configure a +persistent association with a remote server or peer or reference +clock, and auxiliary commands that specify environmental variables +that control various related operations. +.Ss Configuration Commands +The various modes are determined by the command keyword and the +type of the required IP address. +Addresses are classed by type as +(s) a remote server or peer (IPv4 class A, B and C), (b) the +broadcast address of a local interface, (m) a multicast address (IPv4 +class D), or (r) a reference clock address (127.127.x.x). +Note that +only those options applicable to each command are listed below. +Use +of options not listed may not be caught as an error, but may result +in some weird and even destructive behavior. +.Pp +If the Basic Socket Interface Extensions for IPv6 (RFC-2553) +is detected, support for the IPv6 address family is generated +in addition to the default support of the IPv4 address family. +In a few cases, including the reslist billboard generated +by ntpdc, IPv6 addresses are automatically generated. +IPv6 addresses can be identified by the presence of colons +.Dq \&: +in the address field. +IPv6 addresses can be used almost everywhere where +IPv4 addresses can be used, +with the exception of reference clock addresses, +which are always IPv4. +.Pp +Note that in contexts where a host name is expected, a +.Fl 4 +qualifier preceding +the host name forces DNS resolution to the IPv4 namespace, +while a +.Fl 6 +qualifier forces DNS resolution to the IPv6 namespace. +See IPv6 references for the +equivalent classes for that address family. +.Bl -tag -width indent +.It Xo Ic pool Ar address +.Op Cm burst +.Op Cm iburst +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic server Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm burst +.Op Cm iburst +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic peer Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic broadcast Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm ttl Ar ttl +.Xc +.It Xo Ic manycastclient Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Op Cm ttl Ar ttl +.Xc +.El +.Pp +These five commands specify the time server name or address to +be used and the mode in which to operate. +The +.Ar address +can be +either a DNS name or an IP address in dotted-quad notation. +Additional information on association behavior can be found in the +.Qq Association Management +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Bl -tag -width indent +.It Ic pool +For type s addresses, this command mobilizes a persistent +client mode association with a number of remote servers. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +.It Ic server +For type s and r addresses, this command mobilizes a persistent +client mode association with the specified remote server or local +radio clock. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +This command should +.Em not +be used for type +b or m addresses. +.It Ic peer +For type s addresses (only), this command mobilizes a +persistent symmetric-active mode association with the specified +remote peer. +In this mode the local clock can be synchronized to +the remote peer or the remote peer can be synchronized to the local +clock. +This is useful in a network of servers where, depending on +various failure scenarios, either the local or remote peer may be +the better source of time. +This command should NOT be used for type +b, m or r addresses. +.It Ic broadcast +For type b and m addresses (only), this +command mobilizes a persistent broadcast mode association. +Multiple +commands can be used to specify multiple local broadcast interfaces +(subnets) and/or multiple multicast groups. +Note that local +broadcast messages go only to the interface associated with the +subnet specified, but multicast messages go to all interfaces. +In broadcast mode the local server sends periodic broadcast +messages to a client population at the +.Ar address +specified, which is usually the broadcast address on (one of) the +local network(s) or a multicast address assigned to NTP. +The IANA +has assigned the multicast group address IPv4 224.0.1.1 and +IPv6 ff05::101 (site local) exclusively to +NTP, but other nonconflicting addresses can be used to contain the +messages within administrative boundaries. +Ordinarily, this +specification applies only to the local server operating as a +sender; for operation as a broadcast client, see the +.Ic broadcastclient +or +.Ic multicastclient +commands +below. +.It Ic manycastclient +For type m addresses (only), this command mobilizes a +manycast client mode association for the multicast address +specified. +In this case a specific address must be supplied which +matches the address used on the +.Ic manycastserver +command for +the designated manycast servers. +The NTP multicast address +224.0.1.1 assigned by the IANA should NOT be used, unless specific +means are taken to avoid spraying large areas of the Internet with +these messages and causing a possibly massive implosion of replies +at the sender. +The +.Ic manycastserver +command specifies that the local server +is to operate in client mode with the remote servers that are +discovered as the result of broadcast/multicast messages. +The +client broadcasts a request message to the group address associated +with the specified +.Ar address +and specifically enabled +servers respond to these messages. +The client selects the servers +providing the best time and continues as with the +.Ic server +command. +The remaining servers are discarded as if never +heard. +.El +.Pp +Options: +.Bl -tag -width indent +.It Cm autokey +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the autokey scheme +described in +.Sx Authentication Options . +.It Cm burst +when the server is reachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first and second packets +can be changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to improve timekeeping quality +with the +.Ic server +command and s addresses. +.It Cm iburst +When the server is unreachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first two packets can be +changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to speed the initial synchronization +acquisition with the +.Ic server +command and s addresses and when +.Xr ntpd 1ntpdmdoc +is started with the +.Fl q +option. +.It Cm key Ar key +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the specified +.Ar key +identifier with values from 1 to 65534, inclusive. +The +default is to include no encryption field. +.It Cm minpoll Ar minpoll +.It Cm maxpoll Ar maxpoll +These options specify the minimum and maximum poll intervals +for NTP messages, as a power of 2 in seconds +The maximum poll +interval defaults to 10 (1,024 s), but can be increased by the +.Cm maxpoll +option to an upper limit of 17 (36.4 h). +The +minimum poll interval defaults to 6 (64 s), but can be decreased by +the +.Cm minpoll +option to a lower limit of 4 (16 s). +.It Cm noselect +Marks the server as unused, except for display purposes. +The server is discarded by the selection algroithm. +.It Cm prefer +Marks the server as preferred. +All other things being equal, +this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +.Qq Mitigation Rules and the prefer Keyword +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +for further information. +.It Cm ttl Ar ttl +This option is used only with broadcast server and manycast +client modes. +It specifies the time-to-live +.Ar ttl +to +use on broadcast server and multicast server and the maximum +.Ar ttl +for the expanding ring search with manycast +client packets. +Selection of the proper value, which defaults to +127, is something of a black art and should be coordinated with the +network administrator. +.It Cm version Ar version +Specifies the version number to be used for outgoing NTP +packets. +Versions 1-4 are the choices, with version 4 the +default. +.El +.Ss Auxiliary Commands +.Bl -tag -width indent +.It Ic broadcastclient +This command enables reception of broadcast server messages to +any local interface (type b) address. +Upon receiving a message for +the first time, the broadcast client measures the nominal server +propagation delay using a brief client/server exchange with the +server, then enters the broadcast client mode, in which it +synchronizes to succeeding broadcast messages. +Note that, in order +to avoid accidental or malicious disruption in this mode, both the +server and client should operate using symmetric-key or public-key +authentication as described in +.Sx Authentication Options . +.It Ic manycastserver Ar address ... +This command enables reception of manycast client messages to +the multicast group address(es) (type m) specified. +At least one +address is required, but the NTP multicast address 224.0.1.1 +assigned by the IANA should NOT be used, unless specific means are +taken to limit the span of the reply and avoid a possibly massive +implosion at the original sender. +Note that, in order to avoid +accidental or malicious disruption in this mode, both the server +and client should operate using symmetric-key or public-key +authentication as described in +.Sx Authentication Options . +.It Ic multicastclient Ar address ... +This command enables reception of multicast server messages to +the multicast group address(es) (type m) specified. +Upon receiving +a message for the first time, the multicast client measures the +nominal server propagation delay using a brief client/server +exchange with the server, then enters the broadcast client mode, in +which it synchronizes to succeeding multicast messages. +Note that, +in order to avoid accidental or malicious disruption in this mode, +both the server and client should operate using symmetric-key or +public-key authentication as described in +.Sx Authentication Options . +.It Ic mdnstries Ar number +If we are participating in mDNS, +after we have synched for the first time +we attempt to register with the mDNS system. +If that registration attempt fails, +we try again at one minute intervals for up to +.Ic mdnstries +times. +After all, +.Ic ntpd +may be starting before mDNS. +The default value for +.Ic mdnstries +is 5. +.El +.Sh Authentication Support +Authentication support allows the NTP client to verify that the +server is in fact known and trusted and not an intruder intending +accidentally or on purpose to masquerade as that server. +The NTPv3 +specification RFC-1305 defines a scheme which provides +cryptographic authentication of received NTP packets. +Originally, +this was done using the Data Encryption Standard (DES) algorithm +operating in Cipher Block Chaining (CBC) mode, commonly called +DES-CBC. +Subsequently, this was replaced by the RSA Message Digest +5 (MD5) algorithm using a private key, commonly called keyed-MD5. +Either algorithm computes a message digest, or one-way hash, which +can be used to verify the server has the correct private key and +key identifier. +.Pp +NTPv4 retains the NTPv3 scheme, properly described as symmetric key +cryptography and, in addition, provides a new Autokey scheme +based on public key cryptography. +Public key cryptography is generally considered more secure +than symmetric key cryptography, since the security is based +on a private value which is generated by each server and +never revealed. +With Autokey all key distribution and +management functions involve only public values, which +considerably simplifies key distribution and storage. +Public key management is based on X.509 certificates, +which can be provided by commercial services or +produced by utility programs in the OpenSSL software library +or the NTPv4 distribution. +.Pp +While the algorithms for symmetric key cryptography are +included in the NTPv4 distribution, public key cryptography +requires the OpenSSL software library to be installed +before building the NTP distribution. +Directions for doing that +are on the Building and Installing the Distribution page. +.Pp +Authentication is configured separately for each association +using the +.Cm key +or +.Cm autokey +subcommand on the +.Ic peer , +.Ic server , +.Ic broadcast +and +.Ic manycastclient +configuration commands as described in +.Sx Configuration Options +page. +The authentication +options described below specify the locations of the key files, +if other than default, which symmetric keys are trusted +and the interval between various operations, if other than default. +.Pp +Authentication is always enabled, +although ineffective if not configured as +described below. +If a NTP packet arrives +including a message authentication +code (MAC), it is accepted only if it +passes all cryptographic checks. +The +checks require correct key ID, key value +and message digest. +If the packet has +been modified in any way or replayed +by an intruder, it will fail one or more +of these checks and be discarded. +Furthermore, the Autokey scheme requires a +preliminary protocol exchange to obtain +the server certificate, verify its +credentials and initialize the protocol +.Pp +The +.Cm auth +flag controls whether new associations or +remote configuration commands require cryptographic authentication. +This flag can be set or reset by the +.Ic enable +and +.Ic disable +commands and also by remote +configuration commands sent by a +.Xr ntpdc 1ntpdcmdoc +program running in +another machine. +If this flag is enabled, which is the default +case, new broadcast client and symmetric passive associations and +remote configuration commands must be cryptographically +authenticated using either symmetric key or public key cryptography. +If this +flag is disabled, these operations are effective +even if not cryptographic +authenticated. +It should be understood +that operating with the +.Ic auth +flag disabled invites a significant vulnerability +where a rogue hacker can +masquerade as a falseticker and seriously +disrupt system timekeeping. +It is +important to note that this flag has no purpose +other than to allow or disallow +a new association in response to new broadcast +and symmetric active messages +and remote configuration commands and, in particular, +the flag has no effect on +the authentication process itself. +.Pp +An attractive alternative where multicast support is available +is manycast mode, in which clients periodically troll +for servers as described in the +.Sx Automatic NTP Configuration Options +page. +Either symmetric key or public key +cryptographic authentication can be used in this mode. +The principle advantage +of manycast mode is that potential servers need not be +configured in advance, +since the client finds them during regular operation, +and the configuration +files for all clients can be identical. +.Pp +The security model and protocol schemes for +both symmetric key and public key +cryptography are summarized below; +further details are in the briefings, papers +and reports at the NTP project page linked from +.Li http://www.ntp.org/ . +.Ss Symmetric-Key Cryptography +The original RFC-1305 specification allows any one of possibly +65,534 keys, each distinguished by a 32-bit key identifier, to +authenticate an association. +The servers and clients involved must +agree on the key and key identifier to +authenticate NTP packets. +Keys and +related information are specified in a key +file, usually called +.Pa ntp.keys , +which must be distributed and stored using +secure means beyond the scope of the NTP protocol itself. +Besides the keys used +for ordinary NTP associations, +additional keys can be used as passwords for the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +utility programs. +.Pp +When +.Xr ntpd 1ntpdmdoc +is first started, it reads the key file specified in the +.Ic keys +configuration command and installs the keys +in the key cache. +However, +individual keys must be activated with the +.Ic trusted +command before use. +This +allows, for instance, the installation of possibly +several batches of keys and +then activating or deactivating each batch +remotely using +.Xr ntpdc 1ntpdcmdoc . +This also provides a revocation capability that can be used +if a key becomes compromised. +The +.Ic requestkey +command selects the key used as the password for the +.Xr ntpdc 1ntpdcmdoc +utility, while the +.Ic controlkey +command selects the key used as the password for the +.Xr ntpq 1ntpqmdoc +utility. +.Ss Public Key Cryptography +NTPv4 supports the original NTPv3 symmetric key scheme +described in RFC-1305 and in addition the Autokey protocol, +which is based on public key cryptography. +The Autokey Version 2 protocol described on the Autokey Protocol +page verifies packet integrity using MD5 message digests +and verifies the source with digital signatures and any of several +digest/signature schemes. +Optional identity schemes described on the Identity Schemes +page and based on cryptographic challenge/response algorithms +are also available. +Using all of these schemes provides strong security against +replay with or without modification, spoofing, masquerade +and most forms of clogging attacks. +.\" .Pp +.\" The cryptographic means necessary for all Autokey operations +.\" is provided by the OpenSSL software library. +.\" This library is available from http://www.openssl.org/ +.\" and can be installed using the procedures outlined +.\" in the Building and Installing the Distribution page. +.\" Once installed, +.\" the configure and build +.\" process automatically detects the library and links +.\" the library routines required. +.Pp +The Autokey protocol has several modes of operation +corresponding to the various NTP modes supported. +Most modes use a special cookie which can be +computed independently by the client and server, +but encrypted in transmission. +All modes use in addition a variant of the S-KEY scheme, +in which a pseudo-random key list is generated and used +in reverse order. +These schemes are described along with an executive summary, +current status, briefing slides and reading list on the +.Sx Autonomous Authentication +page. +.Pp +The specific cryptographic environment used by Autokey servers +and clients is determined by a set of files +and soft links generated by the +.Xr ntp-keygen 1ntpkeygenmdoc +program. +This includes a required host key file, +required certificate file and optional sign key file, +leapsecond file and identity scheme files. +The +digest/signature scheme is specified in the X.509 certificate +along with the matching sign key. +There are several schemes +available in the OpenSSL software library, each identified +by a specific string such as +.Cm md5WithRSAEncryption , +which stands for the MD5 message digest with RSA +encryption scheme. +The current NTP distribution supports +all the schemes in the OpenSSL library, including +those based on RSA and DSA digital signatures. +.Pp +NTP secure groups can be used to define cryptographic compartments +and security hierarchies. +It is important that every host +in the group be able to construct a certificate trail to one +or more trusted hosts in the same group. +Each group +host runs the Autokey protocol to obtain the certificates +for all hosts along the trail to one or more trusted hosts. +This requires the configuration file in all hosts to be +engineered so that, even under anticipated failure conditions, +the NTP subnet will form such that every group host can find +a trail to at least one trusted host. +.Ss Naming and Addressing +It is important to note that Autokey does not use DNS to +resolve addresses, since DNS can't be completely trusted +until the name servers have synchronized clocks. +The cryptographic name used by Autokey to bind the host identity +credentials and cryptographic values must be independent +of interface, network and any other naming convention. +The name appears in the host certificate in either or both +the subject and issuer fields, so protection against +DNS compromise is essential. +.Pp +By convention, the name of an Autokey host is the name returned +by the Unix +.Xr gethostname 2 +system call or equivalent in other systems. +By the system design +model, there are no provisions to allow alternate names or aliases. +However, this is not to say that DNS aliases, different names +for each interface, etc., are constrained in any way. +.Pp +It is also important to note that Autokey verifies authenticity +using the host name, network address and public keys, +all of which are bound together by the protocol specifically +to deflect masquerade attacks. +For this reason Autokey +includes the source and destinatino IP addresses in message digest +computations and so the same addresses must be available +at both the server and client. +For this reason operation +with network address translation schemes is not possible. +This reflects the intended robust security model where government +and corporate NTP servers are operated outside firewall perimeters. +.Ss Operation +A specific combination of authentication scheme (none, +symmetric key, public key) and identity scheme is called +a cryptotype, although not all combinations are compatible. +There may be management configurations where the clients, +servers and peers may not all support the same cryptotypes. +A secure NTPv4 subnet can be configured in many ways while +keeping in mind the principles explained above and +in this section. +Note however that some cryptotype +combinations may successfully interoperate with each other, +but may not represent good security practice. +.Pp +The cryptotype of an association is determined at the time +of mobilization, either at configuration time or some time +later when a message of appropriate cryptotype arrives. +When mobilized by a +.Ic server +or +.Ic peer +configuration command and no +.Ic key +or +.Ic autokey +subcommands are present, the association is not +authenticated; if the +.Ic key +subcommand is present, the association is authenticated +using the symmetric key ID specified; if the +.Ic autokey +subcommand is present, the association is authenticated +using Autokey. +.Pp +When multiple identity schemes are supported in the Autokey +protocol, the first message exchange determines which one is used. +The client request message contains bits corresponding +to which schemes it has available. +The server response message +contains bits corresponding to which schemes it has available. +Both server and client match the received bits with their own +and select a common scheme. +.Pp +Following the principle that time is a public value, +a server responds to any client packet that matches +its cryptotype capabilities. +Thus, a server receiving +an unauthenticated packet will respond with an unauthenticated +packet, while the same server receiving a packet of a cryptotype +it supports will respond with packets of that cryptotype. +However, unconfigured broadcast or manycast client +associations or symmetric passive associations will not be +mobilized unless the server supports a cryptotype compatible +with the first packet received. +By default, unauthenticated associations will not be mobilized +unless overridden in a decidedly dangerous way. +.Pp +Some examples may help to reduce confusion. +Client Alice has no specific cryptotype selected. +Server Bob has both a symmetric key file and minimal Autokey files. +Alice's unauthenticated messages arrive at Bob, who replies with +unauthenticated messages. +Cathy has a copy of Bob's symmetric +key file and has selected key ID 4 in messages to Bob. +Bob verifies the message with his key ID 4. +If it's the +same key and the message is verified, Bob sends Cathy a reply +authenticated with that key. +If verification fails, +Bob sends Cathy a thing called a crypto-NAK, which tells her +something broke. +She can see the evidence using the +.Xr ntpq 1ntpqmdoc +program. +.Pp +Denise has rolled her own host key and certificate. +She also uses one of the identity schemes as Bob. +She sends the first Autokey message to Bob and they +both dance the protocol authentication and identity steps. +If all comes out okay, Denise and Bob continue as described above. +.Pp +It should be clear from the above that Bob can support +all the girls at the same time, as long as he has compatible +authentication and identity credentials. +Now, Bob can act just like the girls in his own choice of servers; +he can run multiple configured associations with multiple different +servers (or the same server, although that might not be useful). +But, wise security policy might preclude some cryptotype +combinations; for instance, running an identity scheme +with one server and no authentication with another might not be wise. +.Ss Key Management +The cryptographic values used by the Autokey protocol are +incorporated as a set of files generated by the +.Xr ntp-keygen 1ntpkeygenmdoc +utility program, including symmetric key, host key and +public certificate files, as well as sign key, identity parameters +and leapseconds files. +Alternatively, host and sign keys and +certificate files can be generated by the OpenSSL utilities +and certificates can be imported from public certificate +authorities. +Note that symmetric keys are necessary for the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +utility programs. +The remaining files are necessary only for the +Autokey protocol. +.Pp +Certificates imported from OpenSSL or public certificate +authorities have certian limitations. +The certificate should be in ASN.1 syntax, X.509 Version 3 +format and encoded in PEM, which is the same format +used by OpenSSL. +The overall length of the certificate encoded +in ASN.1 must not exceed 1024 bytes. +The subject distinguished +name field (CN) is the fully qualified name of the host +on which it is used; the remaining subject fields are ignored. +The certificate extension fields must not contain either +a subject key identifier or a issuer key identifier field; +however, an extended key usage field for a trusted host must +contain the value +.Cm trustRoot ; . +Other extension fields are ignored. +.Ss Authentication Commands +.Bl -tag -width indent +.It Ic autokey Op Ar logsec +Specifies the interval between regenerations of the session key +list used with the Autokey protocol. +Note that the size of the key +list for each association depends on this interval and the current +poll interval. +The default value is 12 (4096 s or about 1.1 hours). +For poll intervals above the specified interval, a session key list +with a single entry will be regenerated for every message +sent. +.It Ic controlkey Ar key +Specifies the key identifier to use with the +.Xr ntpq 1ntpqmdoc +utility, which uses the standard +protocol defined in RFC-1305. +The +.Ar key +argument is +the key identifier for a trusted key, where the value can be in the +range 1 to 65,534, inclusive. +.It Xo Ic crypto +.Op Cm cert Ar file +.Op Cm leap Ar file +.Op Cm randfile Ar file +.Op Cm host Ar file +.Op Cm sign Ar file +.Op Cm gq Ar file +.Op Cm gqpar Ar file +.Op Cm iffpar Ar file +.Op Cm mvpar Ar file +.Op Cm pw Ar password +.Xc +This command requires the OpenSSL library. +It activates public key +cryptography, selects the message digest and signature +encryption scheme and loads the required private and public +values described above. +If one or more files are left unspecified, +the default names are used as described above. +Unless the complete path and name of the file are specified, the +location of a file is relative to the keys directory specified +in the +.Ic keysdir +command or default +.Pa /usr/local/etc . +Following are the subcommands: +.Bl -tag -width indent +.It Cm cert Ar file +Specifies the location of the required host public certificate file. +This overrides the link +.Pa ntpkey_cert_ Ns Ar hostname +in the keys directory. +.It Cm gqpar Ar file +Specifies the location of the optional GQ parameters file. +This +overrides the link +.Pa ntpkey_gq_ Ns Ar hostname +in the keys directory. +.It Cm host Ar file +Specifies the location of the required host key file. +This overrides +the link +.Pa ntpkey_key_ Ns Ar hostname +in the keys directory. +.It Cm iffpar Ar file +Specifies the location of the optional IFF parameters file.This +overrides the link +.Pa ntpkey_iff_ Ns Ar hostname +in the keys directory. +.It Cm leap Ar file +Specifies the location of the optional leapsecond file. +This overrides the link +.Pa ntpkey_leap +in the keys directory. +.It Cm mvpar Ar file +Specifies the location of the optional MV parameters file. +This +overrides the link +.Pa ntpkey_mv_ Ns Ar hostname +in the keys directory. +.It Cm pw Ar password +Specifies the password to decrypt files containing private keys and +identity parameters. +This is required only if these files have been +encrypted. +.It Cm randfile Ar file +Specifies the location of the random seed file used by the OpenSSL +library. +The defaults are described in the main text above. +.It Cm sign Ar file +Specifies the location of the optional sign key file. +This overrides +the link +.Pa ntpkey_sign_ Ns Ar hostname +in the keys directory. +If this file is +not found, the host key is also the sign key. +.El +.It Ic keys Ar keyfile +Specifies the complete path and location of the MD5 key file +containing the keys and key identifiers used by +.Xr ntpd 1ntpdmdoc , +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +when operating with symmetric key cryptography. +This is the same operation as the +.Fl k +command line option. +.It Ic keysdir Ar path +This command specifies the default directory path for +cryptographic keys, parameters and certificates. +The default is +.Pa /usr/local/etc/ . +.It Ic requestkey Ar key +Specifies the key identifier to use with the +.Xr ntpdc 1ntpdcmdoc +utility program, which uses a +proprietary protocol specific to this implementation of +.Xr ntpd 1ntpdmdoc . +The +.Ar key +argument is a key identifier +for the trusted key, where the value can be in the range 1 to +65,534, inclusive. +.It Ic revoke Ar logsec +Specifies the interval between re-randomization of certain +cryptographic values used by the Autokey scheme, as a power of 2 in +seconds. +These values need to be updated frequently in order to +deflect brute-force attacks on the algorithms of the scheme; +however, updating some values is a relatively expensive operation. +The default interval is 16 (65,536 s or about 18 hours). +For poll +intervals above the specified interval, the values will be updated +for every message sent. +.It Ic trustedkey Ar key ... +Specifies the key identifiers which are trusted for the +purposes of authenticating peers with symmetric key cryptography, +as well as keys used by the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +programs. +The authentication procedures require that both the local +and remote servers share the same key and key identifier for this +purpose, although different keys can be used with different +servers. +The +.Ar key +arguments are 32-bit unsigned +integers with values from 1 to 65,534. +.El +.Ss Error Codes +The following error codes are reported via the NTP control +and monitoring protocol trap mechanism. +.Bl -tag -width indent +.It 101 +.Pq bad field format or length +The packet has invalid version, length or format. +.It 102 +.Pq bad timestamp +The packet timestamp is the same or older than the most recent received. +This could be due to a replay or a server clock time step. +.It 103 +.Pq bad filestamp +The packet filestamp is the same or older than the most recent received. +This could be due to a replay or a key file generation error. +.It 104 +.Pq bad or missing public key +The public key is missing, has incorrect format or is an unsupported type. +.It 105 +.Pq unsupported digest type +The server requires an unsupported digest/signature scheme. +.It 106 +.Pq mismatched digest types +Not used. +.It 107 +.Pq bad signature length +The signature length does not match the current public key. +.It 108 +.Pq signature not verified +The message fails the signature check. +It could be bogus or signed by a +different private key. +.It 109 +.Pq certificate not verified +The certificate is invalid or signed with the wrong key. +.It 110 +.Pq certificate not verified +The certificate is not yet valid or has expired or the signature could not +be verified. +.It 111 +.Pq bad or missing cookie +The cookie is missing, corrupted or bogus. +.It 112 +.Pq bad or missing leapseconds table +The leapseconds table is missing, corrupted or bogus. +.It 113 +.Pq bad or missing certificate +The certificate is missing, corrupted or bogus. +.It 114 +.Pq bad or missing identity +The identity key is missing, corrupt or bogus. +.El +.Sh Monitoring Support +.Xr ntpd 1ntpdmdoc +includes a comprehensive monitoring facility suitable +for continuous, long term recording of server and client +timekeeping performance. +See the +.Ic statistics +command below +for a listing and example of each type of statistics currently +supported. +Statistic files are managed using file generation sets +and scripts in the +.Pa ./scripts +directory of this distribution. +Using +these facilities and +.Ux +.Xr cron 8 +jobs, the data can be +automatically summarized and archived for retrospective analysis. +.Ss Monitoring Commands +.Bl -tag -width indent +.It Ic statistics Ar name ... +Enables writing of statistics records. +Currently, eight kinds of +.Ar name +statistics are supported. +.Bl -tag -width indent +.It Cm clockstats +Enables recording of clock driver statistics information. +Each update +received from a clock driver appends a line of the following form to +the file generation set named +.Cm clockstats : +.Bd -literal +49213 525.624 127.127.4.1 93 226 00:08:29.606 D +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the +clock address in dotted-quad notation. +The final field shows the last +timecode received from the clock in decoded ASCII format, where +meaningful. +In some clock drivers a good deal of additional information +can be gathered and displayed as well. +See information specific to each +clock for further details. +.It Cm cryptostats +This option requires the OpenSSL cryptographic software library. +It +enables recording of cryptographic public key protocol information. +Each message received by the protocol module appends a line of the +following form to the file generation set named +.Cm cryptostats : +.Bd -literal +49213 525.624 127.127.4.1 message +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the peer +address in dotted-quad notation, The final message field includes the +message type and certain ancillary information. +See the +.Sx Authentication Options +section for further information. +.It Cm loopstats +Enables recording of loop filter statistics information. +Each +update of the local clock outputs a line of the following form to +the file generation set named +.Cm loopstats : +.Bd -literal +50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next five fields +show time offset (seconds), frequency offset (parts per million - +PPM), RMS jitter (seconds), Allan deviation (PPM) and clock +discipline time constant. +.It Cm peerstats +Enables recording of peer statistics information. +This includes +statistics records of all peers of a NTP server and of special +signals, where present and configured. +Each valid update appends a +line of the following form to the current element of a file +generation set named +.Cm peerstats : +.Bd -literal +48773 10847.650 127.127.4.1 9714 -0.001605376 0.000000000 0.001424877 0.000958674 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the peer address in dotted-quad notation and status, +respectively. +The status field is encoded in hex in the format +described in Appendix A of the NTP specification RFC 1305. +The final four fields show the offset, +delay, dispersion and RMS jitter, all in seconds. +.It Cm rawstats +Enables recording of raw-timestamp statistics information. +This +includes statistics records of all peers of a NTP server and of +special signals, where present and configured. +Each NTP message +received from a peer or clock driver appends a line of the +following form to the file generation set named +.Cm rawstats : +.Bd -literal +50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the remote peer or clock address followed by the local address +in dotted-quad notation. +The final four fields show the originate, +receive, transmit and final NTP timestamps in order. +The timestamp +values are as received and before processing by the various data +smoothing and mitigation algorithms. +.It Cm sysstats +Enables recording of ntpd statistics counters on a periodic basis. +Each +hour a line of the following form is appended to the file generation +set named +.Cm sysstats : +.Bd -literal +50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The remaining ten fields show +the statistics counter values accumulated since the last generated +line. +.Bl -tag -width indent +.It Time since restart Cm 36000 +Time in hours since the system was last rebooted. +.It Packets received Cm 81965 +Total number of packets received. +.It Packets processed Cm 0 +Number of packets received in response to previous packets sent +.It Current version Cm 9546 +Number of packets matching the current NTP version. +.It Previous version Cm 56 +Number of packets matching the previous NTP version. +.It Bad version Cm 71793 +Number of packets matching neither NTP version. +.It Access denied Cm 512 +Number of packets denied access for any reason. +.It Bad length or format Cm 540 +Number of packets with invalid length, format or port number. +.It Bad authentication Cm 10 +Number of packets not verified as authentic. +.It Rate exceeded Cm 147 +Number of packets discarded due to rate limitation. +.El +.It Cm statsdir Ar directory_path +Indicates the full path of a directory where statistics files +should be created (see below). +This keyword allows +the (otherwise constant) +.Cm filegen +filename prefix to be modified for file generation sets, which +is useful for handling statistics logs. +.It Cm filegen Ar name Xo +.Op Cm file Ar filename +.Op Cm type Ar typename +.Op Cm link | nolink +.Op Cm enable | disable +.Xc +Configures setting of generation file set name. +Generation +file sets provide a means for handling files that are +continuously growing during the lifetime of a server. +Server statistics are a typical example for such files. +Generation file sets provide access to a set of files used +to store the actual data. +At any time at most one element +of the set is being written to. +The type given specifies +when and how data will be directed to a new element of the set. +This way, information stored in elements of a file set +that are currently unused are available for administrational +operations without the risk of disturbing the operation of ntpd. +(Most important: they can be removed to free space for new data +produced.) +.Pp +Note that this command can be sent from the +.Xr ntpdc 1ntpdcmdoc +program running at a remote location. +.Bl -tag -width indent +.It Cm name +This is the type of the statistics records, as shown in the +.Cm statistics +command. +.It Cm file Ar filename +This is the file name for the statistics records. +Filenames of set +members are built from three concatenated elements +.Ar Cm prefix , +.Ar Cm filename +and +.Ar Cm suffix : +.Bl -tag -width indent +.It Cm prefix +This is a constant filename path. +It is not subject to +modifications via the +.Ar filegen +option. +It is defined by the +server, usually specified as a compile-time constant. +It may, +however, be configurable for individual file generation sets +via other commands. +For example, the prefix used with +.Ar loopstats +and +.Ar peerstats +generation can be configured using the +.Ar statsdir +option explained above. +.It Cm filename +This string is directly concatenated to the prefix mentioned +above (no intervening +.Ql / ) . +This can be modified using +the file argument to the +.Ar filegen +statement. +No +.Pa .. +elements are +allowed in this component to prevent filenames referring to +parts outside the filesystem hierarchy denoted by +.Ar prefix . +.It Cm suffix +This part is reflects individual elements of a file set. +It is +generated according to the type of a file set. +.El +.It Cm type Ar typename +A file generation set is characterized by its type. +The following +types are supported: +.Bl -tag -width indent +.It Cm none +The file set is actually a single plain file. +.It Cm pid +One element of file set is used per incarnation of a ntpd +server. +This type does not perform any changes to file set +members during runtime, however it provides an easy way of +separating files belonging to different +.Xr ntpd 1ntpdmdoc +server incarnations. +The set member filename is built by appending a +.Ql \&. +to concatenated +.Ar prefix +and +.Ar filename +strings, and +appending the decimal representation of the process ID of the +.Xr ntpd 1ntpdmdoc +server process. +.It Cm day +One file generation set element is created per day. +A day is +defined as the period between 00:00 and 24:00 UTC. +The file set +member suffix consists of a +.Ql \&. +and a day specification in +the form +.Cm YYYYMMdd . +.Cm YYYY +is a 4-digit year number (e.g., 1992). +.Cm MM +is a two digit month number. +.Cm dd +is a two digit day number. +Thus, all information written at 10 December 1992 would end up +in a file named +.Ar prefix +.Ar filename Ns .19921210 . +.It Cm week +Any file set member contains data related to a certain week of +a year. +The term week is defined by computing day-of-year +modulo 7. +Elements of such a file generation set are +distinguished by appending the following suffix to the file set +filename base: A dot, a 4-digit year number, the letter +.Cm W , +and a 2-digit week number. +For example, information from January, +10th 1992 would end up in a file with suffix +.No . Ns Ar 1992W1 . +.It Cm month +One generation file set element is generated per month. +The +file name suffix consists of a dot, a 4-digit year number, and +a 2-digit month. +.It Cm year +One generation file element is generated per year. +The filename +suffix consists of a dot and a 4 digit year number. +.It Cm age +This type of file generation sets changes to a new element of +the file set every 24 hours of server operation. +The filename +suffix consists of a dot, the letter +.Cm a , +and an 8-digit number. +This number is taken to be the number of seconds the server is +running at the start of the corresponding 24-hour period. +Information is only written to a file generation by specifying +.Cm enable ; +output is prevented by specifying +.Cm disable . +.El +.It Cm link | nolink +It is convenient to be able to access the current element of a file +generation set by a fixed name. +This feature is enabled by +specifying +.Cm link +and disabled using +.Cm nolink . +If link is specified, a +hard link from the current file set element to a file without +suffix is created. +When there is already a file with this name and +the number of links of this file is one, it is renamed appending a +dot, the letter +.Cm C , +and the pid of the ntpd server process. +When the +number of links is greater than one, the file is unlinked. +This +allows the current file to be accessed by a constant name. +.It Cm enable \&| Cm disable +Enables or disables the recording function. +.El +.El +.El +.Sh Access Control Support +The +.Xr ntpd 1ntpdmdoc +daemon implements a general purpose address/mask based restriction +list. +The list contains address/match entries sorted first +by increasing address values and and then by increasing mask values. +A match occurs when the bitwise AND of the mask and the packet +source address is equal to the bitwise AND of the mask and +address in the list. +The list is searched in order with the +last match found defining the restriction flags associated +with the entry. +Additional information and examples can be found in the +.Qq Notes on Configuring NTP and Setting up a NTP Subnet +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Pp +The restriction facility was implemented in conformance +with the access policies for the original NSFnet backbone +time servers. +Later the facility was expanded to deflect +cryptographic and clogging attacks. +While this facility may +be useful for keeping unwanted or broken or malicious clients +from congesting innocent servers, it should not be considered +an alternative to the NTP authentication facilities. +Source address based restrictions are easily circumvented +by a determined cracker. +.Pp +Clients can be denied service because they are explicitly +included in the restrict list created by the restrict command +or implicitly as the result of cryptographic or rate limit +violations. +Cryptographic violations include certificate +or identity verification failure; rate limit violations generally +result from defective NTP implementations that send packets +at abusive rates. +Some violations cause denied service +only for the offending packet, others cause denied service +for a timed period and others cause the denied service for +an indefinate period. +When a client or network is denied access +for an indefinate period, the only way at present to remove +the restrictions is by restarting the server. +.Ss The Kiss-of-Death Packet +Ordinarily, packets denied service are simply dropped with no +further action except incrementing statistics counters. +Sometimes a +more proactive response is needed, such as a server message that +explicitly requests the client to stop sending and leave a message +for the system operator. +A special packet format has been created +for this purpose called the "kiss-of-death" (KoD) packet. +KoD packets have the leap bits set unsynchronized and stratum set +to zero and the reference identifier field set to a four-byte +ASCII code. +If the +.Cm noserve +or +.Cm notrust +flag of the matching restrict list entry is set, +the code is "DENY"; if the +.Cm limited +flag is set and the rate limit +is exceeded, the code is "RATE". +Finally, if a cryptographic violation occurs, the code is "CRYP". +.Pp +A client receiving a KoD performs a set of sanity checks to +minimize security exposure, then updates the stratum and +reference identifier peer variables, sets the access +denied (TEST4) bit in the peer flash variable and sends +a message to the log. +As long as the TEST4 bit is set, +the client will send no further packets to the server. +The only way at present to recover from this condition is +to restart the protocol at both the client and server. +This +happens automatically at the client when the association times out. +It will happen at the server only if the server operator cooperates. +.Ss Access Control Commands +.Bl -tag -width indent +.It Xo Ic discard +.Op Cm average Ar avg +.Op Cm minimum Ar min +.Op Cm monitor Ar prob +.Xc +Set the parameters of the +.Cm limited +facility which protects the server from +client abuse. +The +.Cm average +subcommand specifies the minimum average packet +spacing, while the +.Cm minimum +subcommand specifies the minimum packet spacing. +Packets that violate these minima are discarded +and a kiss-o'-death packet returned if enabled. +The default +minimum average and minimum are 5 and 2, respectively. +The monitor subcommand specifies the probability of discard +for packets that overflow the rate-control window. +.It Xo Ic restrict address +.Op Cm mask Ar mask +.Op Ar flag ... +.Xc +The +.Ar address +argument expressed in +dotted-quad form is the address of a host or network. +Alternatively, the +.Ar address +argument can be a valid host DNS name. +The +.Ar mask +argument expressed in dotted-quad form defaults to +.Cm 255.255.255.255 , +meaning that the +.Ar address +is treated as the address of an individual host. +A default entry (address +.Cm 0.0.0.0 , +mask +.Cm 0.0.0.0 ) +is always included and is always the first entry in the list. +Note that text string +.Cm default , +with no mask option, may +be used to indicate the default entry. +In the current implementation, +.Cm flag +always +restricts access, i.e., an entry with no flags indicates that free +access to the server is to be given. +The flags are not orthogonal, +in that more restrictive flags will often make less restrictive +ones redundant. +The flags can generally be classed into two +categories, those which restrict time service and those which +restrict informational queries and attempts to do run-time +reconfiguration of the server. +One or more of the following flags +may be specified: +.Bl -tag -width indent +.It Cm ignore +Deny packets of all kinds, including +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries. +.It Cm kod +If this flag is set when an access violation occurs, a kiss-o'-death +(KoD) packet is sent. +KoD packets are rate limited to no more than one +per second. +If another KoD packet occurs within one second after the +last one, the packet is dropped. +.It Cm limited +Deny service if the packet spacing violates the lower limits specified +in the discard command. +A history of clients is kept using the +monitoring capability of +.Xr ntpd 1ntpdmdoc . +Thus, monitoring is always active as +long as there is a restriction entry with the +.Cm limited +flag. +.It Cm lowpriotrap +Declare traps set by matching hosts to be low priority. +The +number of traps a server can maintain is limited (the current limit +is 3). +Traps are usually assigned on a first come, first served +basis, with later trap requestors being denied service. +This flag +modifies the assignment algorithm by allowing low priority traps to +be overridden by later requests for normal priority traps. +.It Cm nomodify +Deny +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries which attempt to modify the state of the +server (i.e., run time reconfiguration). +Queries which return +information are permitted. +.It Cm noquery +Deny +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries. +Time service is not affected. +.It Cm nopeer +Deny packets which would result in mobilizing a new association. +This +includes broadcast and symmetric active packets when a configured +association does not exist. +It also includes +.Cm pool +associations, so if you want to use servers from a +.Cm pool +directive and also want to use +.Cm nopeer +by default, you'll want a +.Cm "restrict source ..." line as well that does +.It not +include the +.Cm nopeer +directive. +.It Cm noserve +Deny all packets except +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +queries. +.It Cm notrap +Decline to provide mode 6 control message trap service to matching +hosts. +The trap service is a subsystem of the ntpdq control message +protocol which is intended for use by remote event logging programs. +.It Cm notrust +Deny service unless the packet is cryptographically authenticated. +.It Cm ntpport +This is actually a match algorithm modifier, rather than a +restriction flag. +Its presence causes the restriction entry to be +matched only if the source port in the packet is the standard NTP +UDP port (123). +Both +.Cm ntpport +and +.Cm non-ntpport +may +be specified. +The +.Cm ntpport +is considered more specific and +is sorted later in the list. +.It Cm version +Deny packets that do not match the current NTP version. +.El +.Pp +Default restriction list entries with the flags ignore, interface, +ntpport, for each of the local host's interface addresses are +inserted into the table at startup to prevent the server +from attempting to synchronize to its own time. +A default entry is also always present, though if it is +otherwise unconfigured; no flags are associated +with the default entry (i.e., everything besides your own +NTP server is unrestricted). +.El +.Sh Automatic NTP Configuration Options +.Ss Manycasting +Manycasting is a automatic discovery and configuration paradigm +new to NTPv4. +It is intended as a means for a multicast client +to troll the nearby network neighborhood to find cooperating +manycast servers, validate them using cryptographic means +and evaluate their time values with respect to other servers +that might be lurking in the vicinity. +The intended result is that each manycast client mobilizes +client associations with some number of the "best" +of the nearby manycast servers, yet automatically reconfigures +to sustain this number of servers should one or another fail. +.Pp +Note that the manycasting paradigm does not coincide +with the anycast paradigm described in RFC-1546, +which is designed to find a single server from a clique +of servers providing the same service. +The manycast paradigm is designed to find a plurality +of redundant servers satisfying defined optimality criteria. +.Pp +Manycasting can be used with either symmetric key +or public key cryptography. +The public key infrastructure (PKI) +offers the best protection against compromised keys +and is generally considered stronger, at least with relatively +large key sizes. +It is implemented using the Autokey protocol and +the OpenSSL cryptographic library available from +.Li http://www.openssl.org/ . +The library can also be used with other NTPv4 modes +as well and is highly recommended, especially for broadcast modes. +.Pp +A persistent manycast client association is configured +using the manycastclient command, which is similar to the +server command but with a multicast (IPv4 class +.Cm D +or IPv6 prefix +.Cm FF ) +group address. +The IANA has designated IPv4 address 224.1.1.1 +and IPv6 address FF05::101 (site local) for NTP. +When more servers are needed, it broadcasts manycast +client messages to this address at the minimum feasible rate +and minimum feasible time-to-live (TTL) hops, depending +on how many servers have already been found. +There can be as many manycast client associations +as different group address, each one serving as a template +for a future ephemeral unicast client/server association. +.Pp +Manycast servers configured with the +.Ic manycastserver +command listen on the specified group address for manycast +client messages. +Note the distinction between manycast client, +which actively broadcasts messages, and manycast server, +which passively responds to them. +If a manycast server is +in scope of the current TTL and is itself synchronized +to a valid source and operating at a stratum level equal +to or lower than the manycast client, it replies to the +manycast client message with an ordinary unicast server message. +.Pp +The manycast client receiving this message mobilizes +an ephemeral client/server association according to the +matching manycast client template, but only if cryptographically +authenticated and the server stratum is less than or equal +to the client stratum. +Authentication is explicitly required +and either symmetric key or public key (Autokey) can be used. +Then, the client polls the server at its unicast address +in burst mode in order to reliably set the host clock +and validate the source. +This normally results +in a volley of eight client/server at 2-s intervals +during which both the synchronization and cryptographic +protocols run concurrently. +Following the volley, +the client runs the NTP intersection and clustering +algorithms, which act to discard all but the "best" +associations according to stratum and synchronization +distance. +The surviving associations then continue +in ordinary client/server mode. +.Pp +The manycast client polling strategy is designed to reduce +as much as possible the volume of manycast client messages +and the effects of implosion due to near-simultaneous +arrival of manycast server messages. +The strategy is determined by the +.Ic manycastclient , +.Ic tos +and +.Ic ttl +configuration commands. +The manycast poll interval is +normally eight times the system poll interval, +which starts out at the +.Cm minpoll +value specified in the +.Ic manycastclient , +command and, under normal circumstances, increments to the +.Cm maxpolll +value specified in this command. +Initially, the TTL is +set at the minimum hops specified by the ttl command. +At each retransmission the TTL is increased until reaching +the maximum hops specified by this command or a sufficient +number client associations have been found. +Further retransmissions use the same TTL. +.Pp +The quality and reliability of the suite of associations +discovered by the manycast client is determined by the NTP +mitigation algorithms and the +.Cm minclock +and +.Cm minsane +values specified in the +.Ic tos +configuration command. +At least +.Cm minsane +candidate servers must be available and the mitigation +algorithms produce at least +.Cm minclock +survivors in order to synchronize the clock. +Byzantine agreement principles require at least four +candidates in order to correctly discard a single falseticker. +For legacy purposes, +.Cm minsane +defaults to 1 and +.Cm minclock +defaults to 3. +For manycast service +.Cm minsane +should be explicitly set to 4, assuming at least that +number of servers are available. +.Pp +If at least +.Cm minclock +servers are found, the manycast poll interval is immediately +set to eight times +.Cm maxpoll . +If less than +.Cm minclock +servers are found when the TTL has reached the maximum hops, +the manycast poll interval is doubled. +For each transmission +after that, the poll interval is doubled again until +reaching the maximum of eight times +.Cm maxpoll . +Further transmissions use the same poll interval and +TTL values. +Note that while all this is going on, +each client/server association found is operating normally +it the system poll interval. +.Pp +Administratively scoped multicast boundaries are normally +specified by the network router configuration and, +in the case of IPv6, the link/site scope prefix. +By default, the increment for TTL hops is 32 starting +from 31; however, the +.Ic ttl +configuration command can be +used to modify the values to match the scope rules. +.Pp +It is often useful to narrow the range of acceptable +servers which can be found by manycast client associations. +Because manycast servers respond only when the client +stratum is equal to or greater than the server stratum, +primary (stratum 1) servers fill find only primary servers +in TTL range, which is probably the most common objective. +However, unless configured otherwise, all manycast clients +in TTL range will eventually find all primary servers +in TTL range, which is probably not the most common +objective in large networks. +The +.Ic tos +command can be used to modify this behavior. +Servers with stratum below +.Cm floor +or above +.Cm ceiling +specified in the +.Ic tos +command are strongly discouraged during the selection +process; however, these servers may be temporally +accepted if the number of servers within TTL range is +less than +.Cm minclock . +.Pp +The above actions occur for each manycast client message, +which repeats at the designated poll interval. +However, once the ephemeral client association is mobilized, +subsequent manycast server replies are discarded, +since that would result in a duplicate association. +If during a poll interval the number of client associations +falls below +.Cm minclock , +all manycast client prototype associations are reset +to the initial poll interval and TTL hops and operation +resumes from the beginning. +It is important to avoid +frequent manycast client messages, since each one requires +all manycast servers in TTL range to respond. +The result could well be an implosion, either minor or major, +depending on the number of servers in range. +The recommended value for +.Cm maxpoll +is 12 (4,096 s). +.Pp +It is possible and frequently useful to configure a host +as both manycast client and manycast server. +A number of hosts configured this way and sharing a common +group address will automatically organize themselves +in an optimum configuration based on stratum and +synchronization distance. +For example, consider an NTP +subnet of two primary servers and a hundred or more +dependent clients. +With two exceptions, all servers +and clients have identical configuration files including both +.Ic multicastclient +and +.Ic multicastserver +commands using, for instance, multicast group address +239.1.1.1. +The only exception is that each primary server +configuration file must include commands for the primary +reference source such as a GPS receiver. +.Pp +The remaining configuration files for all secondary +servers and clients have the same contents, except for the +.Ic tos +command, which is specific for each stratum level. +For stratum 1 and stratum 2 servers, that command is +not necessary. +For stratum 3 and above servers the +.Cm floor +value is set to the intended stratum number. +Thus, all stratum 3 configuration files are identical, +all stratum 4 files are identical and so forth. +.Pp +Once operations have stabilized in this scenario, +the primary servers will find the primary reference source +and each other, since they both operate at the same +stratum (1), but not with any secondary server or client, +since these operate at a higher stratum. +The secondary +servers will find the servers at the same stratum level. +If one of the primary servers loses its GPS receiver, +it will continue to operate as a client and other clients +will time out the corresponding association and +re-associate accordingly. +.Pp +Some administrators prefer to avoid running +.Xr ntpd 1ntpdmdoc +continuously and run either +.Xr sntp 1sntpmdoc +or +.Xr ntpd 1ntpdmdoc +.Fl q +as a cron job. +In either case the servers must be +configured in advance and the program fails if none are +available when the cron job runs. +A really slick +application of manycast is with +.Xr ntpd 1ntpdmdoc +.Fl q . +The program wakes up, scans the local landscape looking +for the usual suspects, selects the best from among +the rascals, sets the clock and then departs. +Servers do not have to be configured in advance and +all clients throughout the network can have the same +configuration file. +.Ss Manycast Interactions with Autokey +Each time a manycast client sends a client mode packet +to a multicast group address, all manycast servers +in scope generate a reply including the host name +and status word. +The manycast clients then run +the Autokey protocol, which collects and verifies +all certificates involved. +Following the burst interval +all but three survivors are cast off, +but the certificates remain in the local cache. +It often happens that several complete signing trails +from the client to the primary servers are collected in this way. +.Pp +About once an hour or less often if the poll interval +exceeds this, the client regenerates the Autokey key list. +This is in general transparent in client/server mode. +However, about once per day the server private value +used to generate cookies is refreshed along with all +manycast client associations. +In this case all +cryptographic values including certificates is refreshed. +If a new certificate has been generated since +the last refresh epoch, it will automatically revoke +all prior certificates that happen to be in the +certificate cache. +At the same time, the manycast +scheme starts all over from the beginning and +the expanding ring shrinks to the minimum and increments +from there while collecting all servers in scope. +.Ss Manycast Options +.Bl -tag -width indent +.It Xo Ic tos +.Oo +.Cm ceiling Ar ceiling | +.Cm cohort { 0 | 1 } | +.Cm floor Ar floor | +.Cm minclock Ar minclock | +.Cm minsane Ar minsane +.Oc +.Xc +This command affects the clock selection and clustering +algorithms. +It can be used to select the quality and +quantity of peers used to synchronize the system clock +and is most useful in manycast mode. +The variables operate +as follows: +.Bl -tag -width indent +.It Cm ceiling Ar ceiling +Peers with strata above +.Cm ceiling +will be discarded if there are at least +.Cm minclock +peers remaining. +This value defaults to 15, but can be changed +to any number from 1 to 15. +.It Cm cohort Bro 0 | 1 Brc +This is a binary flag which enables (0) or disables (1) +manycast server replies to manycast clients with the same +stratum level. +This is useful to reduce implosions where +large numbers of clients with the same stratum level +are present. +The default is to enable these replies. +.It Cm floor Ar floor +Peers with strata below +.Cm floor +will be discarded if there are at least +.Cm minclock +peers remaining. +This value defaults to 1, but can be changed +to any number from 1 to 15. +.It Cm minclock Ar minclock +The clustering algorithm repeatedly casts out outlier +associations until no more than +.Cm minclock +associations remain. +This value defaults to 3, +but can be changed to any number from 1 to the number of +configured sources. +.It Cm minsane Ar minsane +This is the minimum number of candidates available +to the clock selection algorithm in order to produce +one or more truechimers for the clustering algorithm. +If fewer than this number are available, the clock is +undisciplined and allowed to run free. +The default is 1 +for legacy purposes. +However, according to principles of +Byzantine agreement, +.Cm minsane +should be at least 4 in order to detect and discard +a single falseticker. +.El +.It Cm ttl Ar hop ... +This command specifies a list of TTL values in increasing +order, up to 8 values can be specified. +In manycast mode these values are used in turn +in an expanding-ring search. +The default is eight +multiples of 32 starting at 31. +.El +.Sh Reference Clock Support +The NTP Version 4 daemon supports some three dozen different radio, +satellite and modem reference clocks plus a special pseudo-clock +used for backup or when no other clock source is available. +Detailed descriptions of individual device drivers and options can +be found in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +Additional information can be found in the pages linked +there, including the +.Qq Debugging Hints for Reference Clock Drivers +and +.Qq How To Write a Reference Clock Driver +pages +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +In addition, support for a PPS +signal is available as described in the +.Qq Pulse-per-second (PPS) Signal Interfacing +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +Many +drivers support special line discipline/streams modules which can +significantly improve the accuracy using the driver. +These are +described in the +.Qq Line Disciplines and Streams Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Pp +A reference clock will generally (though not always) be a radio +timecode receiver which is synchronized to a source of standard +time such as the services offered by the NRC in Canada and NIST and +USNO in the US. +The interface between the computer and the timecode +receiver is device dependent, but is usually a serial port. +A +device driver specific to each reference clock must be selected and +compiled in the distribution; however, most common radio, satellite +and modem clocks are included by default. +Note that an attempt to +configure a reference clock when the driver has not been compiled +or the hardware port has not been appropriately configured results +in a scalding remark to the system log file, but is otherwise non +hazardous. +.Pp +For the purposes of configuration, +.Xr ntpd 1ntpdmdoc +treats +reference clocks in a manner analogous to normal NTP peers as much +as possible. +Reference clocks are identified by a syntactically +correct but invalid IP address, in order to distinguish them from +normal NTP peers. +Reference clock addresses are of the form +.Sm off +.Li 127.127. Ar t . Ar u , +.Sm on +where +.Ar t +is an integer +denoting the clock type and +.Ar u +indicates the unit +number in the range 0-3. +While it may seem overkill, it is in fact +sometimes useful to configure multiple reference clocks of the same +type, in which case the unit numbers must be unique. +.Pp +The +.Ic server +command is used to configure a reference +clock, where the +.Ar address +argument in that command +is the clock address. +The +.Cm key , +.Cm version +and +.Cm ttl +options are not used for reference clock support. +The +.Cm mode +option is added for reference clock support, as +described below. +The +.Cm prefer +option can be useful to +persuade the server to cherish a reference clock with somewhat more +enthusiasm than other reference clocks or peers. +Further +information on this option can be found in the +.Qq Mitigation Rules and the prefer Keyword +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +page. +The +.Cm minpoll +and +.Cm maxpoll +options have +meaning only for selected clock drivers. +See the individual clock +driver document pages for additional information. +.Pp +The +.Ic fudge +command is used to provide additional +information for individual clock drivers and normally follows +immediately after the +.Ic server +command. +The +.Ar address +argument specifies the clock address. +The +.Cm refid +and +.Cm stratum +options can be used to +override the defaults for the device. +There are two optional +device-dependent time offsets and four flags that can be included +in the +.Ic fudge +command as well. +.Pp +The stratum number of a reference clock is by default zero. +Since the +.Xr ntpd 1ntpdmdoc +daemon adds one to the stratum of each +peer, a primary server ordinarily displays an external stratum of +one. +In order to provide engineered backups, it is often useful to +specify the reference clock stratum as greater than zero. +The +.Cm stratum +option is used for this purpose. +Also, in cases +involving both a reference clock and a pulse-per-second (PPS) +discipline signal, it is useful to specify the reference clock +identifier as other than the default, depending on the driver. +The +.Cm refid +option is used for this purpose. +Except where noted, +these options apply to all clock drivers. +.Ss Reference Clock Commands +.Bl -tag -width indent +.It Xo Ic server +.Sm off +.Li 127.127. Ar t . Ar u +.Sm on +.Op Cm prefer +.Op Cm mode Ar int +.Op Cm minpoll Ar int +.Op Cm maxpoll Ar int +.Xc +This command can be used to configure reference clocks in +special ways. +The options are interpreted as follows: +.Bl -tag -width indent +.It Cm prefer +Marks the reference clock as preferred. +All other things being +equal, this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +.Qq Mitigation Rules and the prefer Keyword +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +for further information. +.It Cm mode Ar int +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.It Cm minpoll Ar int +.It Cm maxpoll Ar int +These options specify the minimum and maximum polling interval +for reference clock messages, as a power of 2 in seconds +For +most directly connected reference clocks, both +.Cm minpoll +and +.Cm maxpoll +default to 6 (64 s). +For modem reference clocks, +.Cm minpoll +defaults to 10 (17.1 m) and +.Cm maxpoll +defaults to 14 (4.5 h). +The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. +.El +.It Xo Ic fudge +.Sm off +.Li 127.127. Ar t . Ar u +.Sm on +.Op Cm time1 Ar sec +.Op Cm time2 Ar sec +.Op Cm stratum Ar int +.Op Cm refid Ar string +.Op Cm mode Ar int +.Op Cm flag1 Cm 0 \&| Cm 1 +.Op Cm flag2 Cm 0 \&| Cm 1 +.Op Cm flag3 Cm 0 \&| Cm 1 +.Op Cm flag4 Cm 0 \&| Cm 1 +.Xc +This command can be used to configure reference clocks in +special ways. +It must immediately follow the +.Ic server +command which configures the driver. +Note that the same capability +is possible at run time using the +.Xr ntpdc 1ntpdcmdoc +program. +The options are interpreted as +follows: +.Bl -tag -width indent +.It Cm time1 Ar sec +Specifies a constant to be added to the time offset produced by +the driver, a fixed-point decimal number in seconds. +This is used +as a calibration constant to adjust the nominal time offset of a +particular clock to agree with an external standard, such as a +precision PPS signal. +It also provides a way to correct a +systematic error or bias due to serial port or operating system +latencies, different cable lengths or receiver internal delay. +The +specified offset is in addition to the propagation delay provided +by other means, such as internal DIPswitches. +Where a calibration +for an individual system and driver is available, an approximate +correction is noted in the driver documentation pages. +Note: in order to facilitate calibration when more than one +radio clock or PPS signal is supported, a special calibration +feature is available. +It takes the form of an argument to the +.Ic enable +command described in +.Sx Miscellaneous Options +page and operates as described in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.It Cm time2 Ar secs +Specifies a fixed-point decimal number in seconds, which is +interpreted in a driver-dependent way. +See the descriptions of +specific drivers in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.It Cm stratum Ar int +Specifies the stratum number assigned to the driver, an integer +between 0 and 15. +This number overrides the default stratum number +ordinarily assigned by the driver itself, usually zero. +.It Cm refid Ar string +Specifies an ASCII string of from one to four characters which +defines the reference identifier used by the driver. +This string +overrides the default identifier ordinarily assigned by the driver +itself. +.It Cm mode Ar int +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.It Cm flag1 Cm 0 \&| Cm 1 +.It Cm flag2 Cm 0 \&| Cm 1 +.It Cm flag3 Cm 0 \&| Cm 1 +.It Cm flag4 Cm 0 \&| Cm 1 +These four flags are used for customizing the clock driver. +The +interpretation of these values, and whether they are used at all, +is a function of the particular clock driver. +However, by +convention +.Cm flag4 +is used to enable recording monitoring +data to the +.Cm clockstats +file configured with the +.Ic filegen +command. +Further information on the +.Ic filegen +command can be found in +.Sx Monitoring Options . +.El +.El +.Sh Miscellaneous Options +.Bl -tag -width indent +.It Ic broadcastdelay Ar seconds +The broadcast and multicast modes require a special calibration +to determine the network delay between the local and remote +servers. +Ordinarily, this is done automatically by the initial +protocol exchanges between the client and server. +In some cases, +the calibration procedure may fail due to network or server access +controls, for example. +This command specifies the default delay to +be used under these circumstances. +Typically (for Ethernet), a +number between 0.003 and 0.007 seconds is appropriate. +The default +when this command is not used is 0.004 seconds. +.It Ic calldelay Ar delay +This option controls the delay in seconds between the first and second +packets sent in burst or iburst mode to allow additional time for a modem +or ISDN call to complete. +.It Ic driftfile Ar driftfile +This command specifies the complete path and name of the file used to +record the frequency of the local clock oscillator. +This is the same +operation as the +.Fl f +command line option. +If the file exists, it is read at +startup in order to set the initial frequency and then updated once per +hour with the current frequency computed by the daemon. +If the file name is +specified, but the file itself does not exist, the starts with an initial +frequency of zero and creates the file when writing it for the first time. +If this command is not given, the daemon will always start with an initial +frequency of zero. +.Pp +The file format consists of a single line containing a single +floating point number, which records the frequency offset measured +in parts-per-million (PPM). +The file is updated by first writing +the current drift value into a temporary file and then renaming +this file to replace the old version. +This implies that +.Xr ntpd 1ntpdmdoc +must have write permission for the directory the +drift file is located in, and that file system links, symbolic or +otherwise, should be avoided. +.It Ic dscp Ar value +This option specifies the Differentiated Services Control Point (DSCP) value, +a 6-bit code. The default value is 46, signifying Expedited Forwarding. +.It Xo Ic enable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm mode7 | monitor | +.Cm ntp | Cm stats +.Oc +.Xc +.It Xo Ic disable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm mode7 | monitor | +.Cm ntp | Cm stats +.Oc +.Xc +Provides a way to enable or disable various server options. +Flags not mentioned are unaffected. +Note that all of these flags +can be controlled remotely using the +.Xr ntpdc 1ntpdcmdoc +utility program. +.Bl -tag -width indent +.It Cm auth +Enables the server to synchronize with unconfigured peers only if the +peer has been correctly authenticated using either public key or +private key cryptography. +The default for this flag is +.Ic enable . +.It Cm bclient +Enables the server to listen for a message from a broadcast or +multicast server, as in the +.Ic multicastclient +command with default +address. +The default for this flag is +.Ic disable . +.It Cm calibrate +Enables the calibrate feature for reference clocks. +The default for +this flag is +.Ic disable . +.It Cm kernel +Enables the kernel time discipline, if available. +The default for this +flag is +.Ic enable +if support is available, otherwise +.Ic disable . +.It Cm mode7 +Enables processing of NTP mode 7 implementation-specific requests +which are used by the deprecated +.Xr ntpdc 1ntpdcmdoc +program. +The default for this flag is disable. +This flag is excluded from runtime configuration using +.Xr ntpq 1ntpqmdoc . +The +.Xr ntpq 1ntpqmdoc +program provides the same capabilities as +.Xr ntpdc 1ntpdcmdoc +using standard mode 6 requests. +.It Cm monitor +Enables the monitoring facility. +See the +.Xr ntpdc 1ntpdcmdoc +program +and the +.Ic monlist +command or further information. +The +default for this flag is +.Ic enable . +.It Cm ntp +Enables time and frequency discipline. +In effect, this switch opens and +closes the feedback loop, which is useful for testing. +The default for +this flag is +.Ic enable . +.It Cm stats +Enables the statistics facility. +See the +.Sx Monitoring Options +section for further information. +The default for this flag is +.Ic disable . +.El +.It Ic includefile Ar includefile +This command allows additional configuration commands +to be included from a separate file. +Include files may +be nested to a depth of five; upon reaching the end of any +include file, command processing resumes in the previous +configuration file. +This option is useful for sites that run +.Xr ntpd 1ntpdmdoc +on multiple hosts, with (mostly) common options (e.g., a +restriction list). +.It Ic leapsmearinterval Ar seconds +This EXPERIMENTAL option is only available if +.Xr ntpd 1ntpdmdoc +was built with the +.Cm --enable-leap-smear +option to the +.Cm configure +script. +It specifies the interval over which a leap second correction will be applied. +Recommended values for this option are between +7200 (2 hours) and 86400 (24 hours). +.Sy DO NOT USE THIS OPTION ON PUBLIC-ACCESS SERVERS! +See http://bugs.ntp.org/2855 for more information. +.It Ic logconfig Ar configkeyword +This command controls the amount and type of output written to +the system +.Xr syslog 3 +facility or the alternate +.Ic logfile +log file. +By default, all output is turned on. +All +.Ar configkeyword +keywords can be prefixed with +.Ql = , +.Ql + +and +.Ql - , +where +.Ql = +sets the +.Xr syslog 3 +priority mask, +.Ql + +adds and +.Ql - +removes +messages. +.Xr syslog 3 +messages can be controlled in four +classes +.Po +.Cm clock , +.Cm peer , +.Cm sys +and +.Cm sync +.Pc . +Within these classes four types of messages can be +controlled: informational messages +.Po +.Cm info +.Pc , +event messages +.Po +.Cm events +.Pc , +statistics messages +.Po +.Cm statistics +.Pc +and +status messages +.Po +.Cm status +.Pc . +.Pp +Configuration keywords are formed by concatenating the message class with +the event class. +The +.Cm all +prefix can be used instead of a message class. +A +message class may also be followed by the +.Cm all +keyword to enable/disable all +messages of the respective message class.Thus, a minimal log configuration +could look like this: +.Bd -literal +logconfig =syncstatus +sysevents +.Ed +.Pp +This would just list the synchronizations state of +.Xr ntpd 1ntpdmdoc +and the major system events. +For a simple reference server, the +following minimum message configuration could be useful: +.Bd -literal +logconfig =syncall +clockall +.Ed +.Pp +This configuration will list all clock information and +synchronization information. +All other events and messages about +peers, system events and so on is suppressed. +.It Ic logfile Ar logfile +This command specifies the location of an alternate log file to +be used instead of the default system +.Xr syslog 3 +facility. +This is the same operation as the -l command line option. +.It Ic setvar Ar variable Op Cm default +This command adds an additional system variable. +These +variables can be used to distribute additional information such as +the access policy. +If the variable of the form +.Sm off +.Va name = Ar value +.Sm on +is followed by the +.Cm default +keyword, the +variable will be listed as part of the default system variables +.Po +.Xr ntpq 1ntpqmdoc +.Ic rv +command +.Pc ) . +These additional variables serve +informational purposes only. +They are not related to the protocol +other that they can be listed. +The known protocol variables will +always override any variables defined via the +.Ic setvar +mechanism. +There are three special variables that contain the names +of all variable of the same group. +The +.Va sys_var_list +holds +the names of all system variables. +The +.Va peer_var_list +holds +the names of all peer variables and the +.Va clock_var_list +holds the names of the reference clock variables. +.It Xo Ic tinker +.Oo +.Cm allan Ar allan | +.Cm dispersion Ar dispersion | +.Cm freq Ar freq | +.Cm huffpuff Ar huffpuff | +.Cm panic Ar panic | +.Cm step Ar step | +.Cm stepback Ar stepback | +.Cm stepfwd Ar stepfwd | +.Cm stepout Ar stepout +.Oc +.Xc +This command can be used to alter several system variables in +very exceptional circumstances. +It should occur in the +configuration file before any other configuration options. +The +default values of these variables have been carefully optimized for +a wide range of network speeds and reliability expectations. +In +general, they interact in intricate ways that are hard to predict +and some combinations can result in some very nasty behavior. +Very +rarely is it necessary to change the default values; but, some +folks cannot resist twisting the knobs anyway and this command is +for them. +Emphasis added: twisters are on their own and can expect +no help from the support group. +.Pp +The variables operate as follows: +.Bl -tag -width indent +.It Cm allan Ar allan +The argument becomes the new value for the minimum Allan +intercept, which is a parameter of the PLL/FLL clock discipline +algorithm. +The value in log2 seconds defaults to 7 (1024 s), which is also the lower +limit. +.It Cm dispersion Ar dispersion +The argument becomes the new value for the dispersion increase rate, +normally .000015 s/s. +.It Cm freq Ar freq +The argument becomes the initial value of the frequency offset in +parts-per-million. +This overrides the value in the frequency file, if +present, and avoids the initial training state if it is not. +.It Cm huffpuff Ar huffpuff +The argument becomes the new value for the experimental +huff-n'-puff filter span, which determines the most recent interval +the algorithm will search for a minimum delay. +The lower limit is +900 s (15 m), but a more reasonable value is 7200 (2 hours). +There +is no default, since the filter is not enabled unless this command +is given. +.It Cm panic Ar panic +The argument is the panic threshold, normally 1000 s. +If set to zero, +the panic sanity check is disabled and a clock offset of any value will +be accepted. +.It Cm step Ar step +The argument is the step threshold, which by default is 0.128 s. +It can +be set to any positive number in seconds. +If set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if the step threshold is set to zero or greater than the +default. +.It Cm stepback Ar stepback +The argument is the step threshold for the backward direction, +which by default is 0.128 s. +It can +be set to any positive number in seconds. +If both the forward and backward step thresholds are set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if +each direction of step threshold are either +set to zero or greater than .5 second. +.It Cm stepfwd Ar stepfwd +As for stepback, but for the forward direction. +.It Cm stepout Ar stepout +The argument is the stepout timeout, which by default is 900 s. +It can +be set to any positive number in seconds. +If set to zero, the stepout +pulses will not be suppressed. +.El +.It Xo Ic rlimit +.Oo +.Cm memlock Ar Nmegabytes | +.Cm stacksize Ar N4kPages +.Cm filenum Ar Nfiledescriptors +.Oc +.Xc +.Bl -tag -width indent +.It Cm memlock Ar Nmegabytes +Specify the number of megabytes of memory that should be +allocated and locked. +Probably only available under Linux, this option may be useful +when dropping root (the +.Fl i +option). +The default is 32 megabytes on non-Linux machines, and -1 under Linux. +-1 means "do not lock the process into memory". +0 means "lock whatever memory the process wants into memory". +.It Cm stacksize Ar N4kPages +Specifies the maximum size of the process stack on systems with the +.Fn mlockall +function. +Defaults to 50 4k pages (200 4k pages in OpenBSD). +.It Cm filenum Ar Nfiledescriptors +Specifies the maximum number of file descriptors ntpd may have open at once. Defaults to the system default. +.El +.It Xo Ic trap Ar host_address +.Op Cm port Ar port_number +.Op Cm interface Ar interface_address +.Xc +This command configures a trap receiver at the given host +address and port number for sending messages with the specified +local interface address. +If the port number is unspecified, a value +of 18447 is used. +If the interface address is not specified, the +message is sent with a source address of the local interface the +message is sent through. +Note that on a multihomed host the +interface used may vary from time to time with routing changes. +.Pp +The trap receiver will generally log event messages and other +information from the server in a log file. +While such monitor +programs may also request their own trap dynamically, configuring a +trap receiver will ensure that no messages are lost when the server +is started. +.It Cm hop Ar ... +This command specifies a list of TTL values in increasing order, up to 8 +values can be specified. +In manycast mode these values are used in turn in +an expanding-ring search. +The default is eight multiples of 32 starting at +31. +.El + _END_PROG_MDOC_DESCRIP; +}; + +doc-section = { + ds-type = 'FILES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_FILES +.Bl -tag -width /etc/ntp.drift -compact +.It Pa /etc/ntp.conf +the default name of the configuration file +.It Pa ntp.keys +private MD5 keys +.It Pa ntpkey +RSA private key +.It Pa ntpkey_ Ns Ar host +RSA public key +.It Pa ntp_dh +Diffie-Hellman agreement parameters +.El + _END_MDOC_FILES; +}; + +doc-section = { + ds-type = 'SEE ALSO'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_SEE_ALSO +.Xr ntpd 1ntpdmdoc , +.Xr ntpdc 1ntpdcmdoc , +.Xr ntpq 1ntpqmdoc +.Pp +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +.Li http://www.ntp.org/ . +A snapshot of this documentation is available in HTML format in +.Pa /usr/share/doc/ntp . +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 4) +.%O RFC5905 +.Re + _END_MDOC_SEE_ALSO; +}; + +doc-section = { + ds-type = 'BUGS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_BUGS +The syntax checking is not picky; some combinations of +ridiculous and even hilarious options and modes may not be +detected. +.Pp +The +.Pa ntpkey_ Ns Ar host +files are really digital +certificates. +These should be obtained via secure directory +services when they become universally available. + _END_MDOC_BUGS; +}; + +doc-section = { + ds-type = 'NOTES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_NOTES +This document was derived from FreeBSD. + _END_MDOC_NOTES; +}; diff --git a/contrib/ntp/ntpd/ntp.conf.html b/contrib/ntp/ntpd/ntp.conf.html new file mode 100644 index 000000000..1f0c81908 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.conf.html @@ -0,0 +1,2666 @@ + + +NTP Configuration File User's Manual + + + + + + + + + +

      NTP Configuration File User's Manual

      +
      +


      +
      Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      NTP's Configuration File User Manual

      + +

      This document describes the configuration file for the NTP Project's +ntpd program. + +

      This document applies to version 4.2.8p4 of ntp.conf. + +

      +

      Short Contents

      + +
      + + + +
      +


      +Previous: Top, +Up: Top +
      +
      + + +

      Description

      + +

      The behavior of ntpd can be changed by a configuration file, +by default ntp.conf. + +

      +


      + +
      +
      + +

      Notes about ntp.conf

      + +

      + +

      The +ntp.conf +configuration file is read at initial startup by the +ntpd(1ntpdmdoc) +daemon in order to specify the synchronization sources, +modes and other related information. +Usually, it is installed in the +/etc +directory, +but could be installed elsewhere +(see the daemon's +-c +command line option). + +

      The file format is similar to other +unix +configuration files. +Comments begin with a +# +character and extend to the end of the line; +blank lines are ignored. +Configuration commands consist of an initial keyword +followed by a list of arguments, +some of which may be optional, separated by whitespace. +Commands may not be continued over multiple lines. +Arguments may be host names, +host addresses written in numeric, dotted-quad form, +integers, floating point numbers (when specifying times in seconds) +and text strings. + +

      The rest of this page describes the configuration and control options. +The +"Notes on Configuring NTP and Setting up an NTP Subnet" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp) +contains an extended discussion of these options. +In addition to the discussion of general +Configuration Options, +there are sections describing the following supported functionality +and the options used to control it: +

      + +

      Following these is a section describing +Miscellaneous Options. +While there is a rich set of options available, +the only required option is one or more +pool, +server, +peer, +broadcast +or +manycastclient +commands. +

      +


      + +
      +
      + +

      Configuration Support

      + +

      Following is a description of the configuration commands in +NTPv4. +These commands have the same basic functions as in NTPv3 and +in some cases new functions and new arguments. +There are two +classes of commands, configuration commands that configure a +persistent association with a remote server or peer or reference +clock, and auxiliary commands that specify environmental variables +that control various related operations. + +

      Configuration Commands
      + +

      The various modes are determined by the command keyword and the +type of the required IP address. +Addresses are classed by type as +(s) a remote server or peer (IPv4 class A, B and C), (b) the +broadcast address of a local interface, (m) a multicast address (IPv4 +class D), or (r) a reference clock address (127.127.x.x). +Note that +only those options applicable to each command are listed below. +Use +of options not listed may not be caught as an error, but may result +in some weird and even destructive behavior. + +

      If the Basic Socket Interface Extensions for IPv6 (RFC-2553) +is detected, support for the IPv6 address family is generated +in addition to the default support of the IPv4 address family. +In a few cases, including the reslist billboard generated +by ntpdc, IPv6 addresses are automatically generated. +IPv6 addresses can be identified by the presence of colons +: +in the address field. +IPv6 addresses can be used almost everywhere where +IPv4 addresses can be used, +with the exception of reference clock addresses, +which are always IPv4. + +

      Note that in contexts where a host name is expected, a +-4 +qualifier preceding +the host name forces DNS resolution to the IPv4 namespace, +while a +-6 +qualifier forces DNS resolution to the IPv6 namespace. +See IPv6 references for the +equivalent classes for that address family. +

      +
      pool address [burst] [iburst] [version version] [prefer] [minpoll minpoll] [maxpoll maxpoll]
      server address [key key | autokey] [burst] [iburst] [version version] [prefer] [minpoll minpoll] [maxpoll maxpoll]
      peer address [key key | autokey] [version version] [prefer] [minpoll minpoll] [maxpoll maxpoll]
      broadcast address [key key | autokey] [version version] [prefer] [minpoll minpoll] [ttl ttl]
      manycastclient address [key key | autokey] [version version] [prefer] [minpoll minpoll] [maxpoll maxpoll] [ttl ttl]
      + +

      These five commands specify the time server name or address to +be used and the mode in which to operate. +The +address +can be +either a DNS name or an IP address in dotted-quad notation. +Additional information on association behavior can be found in the +"Association Management" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). +

      +
      pool
      For type s addresses, this command mobilizes a persistent +client mode association with a number of remote servers. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +
      server
      For type s and r addresses, this command mobilizes a persistent +client mode association with the specified remote server or local +radio clock. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +This command should +not +be used for type +b or m addresses. +
      peer
      For type s addresses (only), this command mobilizes a +persistent symmetric-active mode association with the specified +remote peer. +In this mode the local clock can be synchronized to +the remote peer or the remote peer can be synchronized to the local +clock. +This is useful in a network of servers where, depending on +various failure scenarios, either the local or remote peer may be +the better source of time. +This command should NOT be used for type +b, m or r addresses. +
      broadcast
      For type b and m addresses (only), this +command mobilizes a persistent broadcast mode association. +Multiple +commands can be used to specify multiple local broadcast interfaces +(subnets) and/or multiple multicast groups. +Note that local +broadcast messages go only to the interface associated with the +subnet specified, but multicast messages go to all interfaces. +In broadcast mode the local server sends periodic broadcast +messages to a client population at the +address +specified, which is usually the broadcast address on (one of) the +local network(s) or a multicast address assigned to NTP. +The IANA +has assigned the multicast group address IPv4 224.0.1.1 and +IPv6 ff05::101 (site local) exclusively to +NTP, but other nonconflicting addresses can be used to contain the +messages within administrative boundaries. +Ordinarily, this +specification applies only to the local server operating as a +sender; for operation as a broadcast client, see the +broadcastclient +or +multicastclient +commands +below. +
      manycastclient
      For type m addresses (only), this command mobilizes a +manycast client mode association for the multicast address +specified. +In this case a specific address must be supplied which +matches the address used on the +manycastserver +command for +the designated manycast servers. +The NTP multicast address +224.0.1.1 assigned by the IANA should NOT be used, unless specific +means are taken to avoid spraying large areas of the Internet with +these messages and causing a possibly massive implosion of replies +at the sender. +The +manycastserver +command specifies that the local server +is to operate in client mode with the remote servers that are +discovered as the result of broadcast/multicast messages. +The +client broadcasts a request message to the group address associated +with the specified +address +and specifically enabled +servers respond to these messages. +The client selects the servers +providing the best time and continues as with the +server +command. +The remaining servers are discarded as if never +heard. +
      + +

      Options: +

      +
      autokey
      All packets sent to and received from the server or peer are to +include authentication fields encrypted using the autokey scheme +described in +Authentication Options. +
      burst
      when the server is reachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first and second packets +can be changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to improve timekeeping quality +with the +server +command and s addresses. +
      iburst
      When the server is unreachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first two packets can be +changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to speed the initial synchronization +acquisition with the +server +command and s addresses and when +ntpd(1ntpdmdoc) +is started with the +-q +option. +
      key key
      All packets sent to and received from the server or peer are to +include authentication fields encrypted using the specified +key +identifier with values from 1 to 65534, inclusive. +The +default is to include no encryption field. +
      minpoll minpoll
      maxpoll maxpoll
      These options specify the minimum and maximum poll intervals +for NTP messages, as a power of 2 in seconds +The maximum poll +interval defaults to 10 (1,024 s), but can be increased by the +maxpoll +option to an upper limit of 17 (36.4 h). +The +minimum poll interval defaults to 6 (64 s), but can be decreased by +the +minpoll +option to a lower limit of 4 (16 s). +
      noselect
      Marks the server as unused, except for display purposes. +The server is discarded by the selection algroithm. +
      prefer
      Marks the server as preferred. +All other things being equal, +this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp) +for further information. +
      ttl ttl
      This option is used only with broadcast server and manycast +client modes. +It specifies the time-to-live +ttl +to +use on broadcast server and multicast server and the maximum +ttl +for the expanding ring search with manycast +client packets. +Selection of the proper value, which defaults to +127, is something of a black art and should be coordinated with the +network administrator. +
      version version
      Specifies the version number to be used for outgoing NTP +packets. +Versions 1-4 are the choices, with version 4 the +default. +
      + +
      Auxiliary Commands
      + +
      +
      broadcastclient
      This command enables reception of broadcast server messages to +any local interface (type b) address. +Upon receiving a message for +the first time, the broadcast client measures the nominal server +propagation delay using a brief client/server exchange with the +server, then enters the broadcast client mode, in which it +synchronizes to succeeding broadcast messages. +Note that, in order +to avoid accidental or malicious disruption in this mode, both the +server and client should operate using symmetric-key or public-key +authentication as described in +Authentication Options. +
      manycastserver address ...
      This command enables reception of manycast client messages to +the multicast group address(es) (type m) specified. +At least one +address is required, but the NTP multicast address 224.0.1.1 +assigned by the IANA should NOT be used, unless specific means are +taken to limit the span of the reply and avoid a possibly massive +implosion at the original sender. +Note that, in order to avoid +accidental or malicious disruption in this mode, both the server +and client should operate using symmetric-key or public-key +authentication as described in +Authentication Options. +
      multicastclient address ...
      This command enables reception of multicast server messages to +the multicast group address(es) (type m) specified. +Upon receiving +a message for the first time, the multicast client measures the +nominal server propagation delay using a brief client/server +exchange with the server, then enters the broadcast client mode, in +which it synchronizes to succeeding multicast messages. +Note that, +in order to avoid accidental or malicious disruption in this mode, +both the server and client should operate using symmetric-key or +public-key authentication as described in +Authentication Options. +
      mdnstries number
      If we are participating in mDNS, +after we have synched for the first time +we attempt to register with the mDNS system. +If that registration attempt fails, +we try again at one minute intervals for up to +mdnstries +times. +After all, +ntpd +may be starting before mDNS. +The default value for +mdnstries +is 5. +
      +
      +


      + +
      +
      + +

      Authentication Support

      + +

      Authentication support allows the NTP client to verify that the +server is in fact known and trusted and not an intruder intending +accidentally or on purpose to masquerade as that server. +The NTPv3 +specification RFC-1305 defines a scheme which provides +cryptographic authentication of received NTP packets. +Originally, +this was done using the Data Encryption Standard (DES) algorithm +operating in Cipher Block Chaining (CBC) mode, commonly called +DES-CBC. +Subsequently, this was replaced by the RSA Message Digest +5 (MD5) algorithm using a private key, commonly called keyed-MD5. +Either algorithm computes a message digest, or one-way hash, which +can be used to verify the server has the correct private key and +key identifier. + +

      NTPv4 retains the NTPv3 scheme, properly described as symmetric key +cryptography and, in addition, provides a new Autokey scheme +based on public key cryptography. +Public key cryptography is generally considered more secure +than symmetric key cryptography, since the security is based +on a private value which is generated by each server and +never revealed. +With Autokey all key distribution and +management functions involve only public values, which +considerably simplifies key distribution and storage. +Public key management is based on X.509 certificates, +which can be provided by commercial services or +produced by utility programs in the OpenSSL software library +or the NTPv4 distribution. + +

      While the algorithms for symmetric key cryptography are +included in the NTPv4 distribution, public key cryptography +requires the OpenSSL software library to be installed +before building the NTP distribution. +Directions for doing that +are on the Building and Installing the Distribution page. + +

      Authentication is configured separately for each association +using the +key +or +autokey +subcommand on the +peer, +server, +broadcast +and +manycastclient +configuration commands as described in +Configuration Options +page. +The authentication +options described below specify the locations of the key files, +if other than default, which symmetric keys are trusted +and the interval between various operations, if other than default. + +

      Authentication is always enabled, +although ineffective if not configured as +described below. +If a NTP packet arrives +including a message authentication +code (MAC), it is accepted only if it +passes all cryptographic checks. +The +checks require correct key ID, key value +and message digest. +If the packet has +been modified in any way or replayed +by an intruder, it will fail one or more +of these checks and be discarded. +Furthermore, the Autokey scheme requires a +preliminary protocol exchange to obtain +the server certificate, verify its +credentials and initialize the protocol + +

      The +auth +flag controls whether new associations or +remote configuration commands require cryptographic authentication. +This flag can be set or reset by the +enable +and +disable +commands and also by remote +configuration commands sent by a +ntpdc(1ntpdcmdoc) +program running in +another machine. +If this flag is enabled, which is the default +case, new broadcast client and symmetric passive associations and +remote configuration commands must be cryptographically +authenticated using either symmetric key or public key cryptography. +If this +flag is disabled, these operations are effective +even if not cryptographic +authenticated. +It should be understood +that operating with the +auth +flag disabled invites a significant vulnerability +where a rogue hacker can +masquerade as a falseticker and seriously +disrupt system timekeeping. +It is +important to note that this flag has no purpose +other than to allow or disallow +a new association in response to new broadcast +and symmetric active messages +and remote configuration commands and, in particular, +the flag has no effect on +the authentication process itself. + +

      An attractive alternative where multicast support is available +is manycast mode, in which clients periodically troll +for servers as described in the +Automatic NTP Configuration Options +page. +Either symmetric key or public key +cryptographic authentication can be used in this mode. +The principle advantage +of manycast mode is that potential servers need not be +configured in advance, +since the client finds them during regular operation, +and the configuration +files for all clients can be identical. + +

      The security model and protocol schemes for +both symmetric key and public key +cryptography are summarized below; +further details are in the briefings, papers +and reports at the NTP project page linked from +http://www.ntp.org/. + +

      Symmetric-Key Cryptography
      + +

      The original RFC-1305 specification allows any one of possibly +65,534 keys, each distinguished by a 32-bit key identifier, to +authenticate an association. +The servers and clients involved must +agree on the key and key identifier to +authenticate NTP packets. +Keys and +related information are specified in a key +file, usually called +ntp.keys, +which must be distributed and stored using +secure means beyond the scope of the NTP protocol itself. +Besides the keys used +for ordinary NTP associations, +additional keys can be used as passwords for the +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +utility programs. + +

      When +ntpd(1ntpdmdoc) +is first started, it reads the key file specified in the +keys +configuration command and installs the keys +in the key cache. +However, +individual keys must be activated with the +trusted +command before use. +This +allows, for instance, the installation of possibly +several batches of keys and +then activating or deactivating each batch +remotely using +ntpdc(1ntpdcmdoc). +This also provides a revocation capability that can be used +if a key becomes compromised. +The +requestkey +command selects the key used as the password for the +ntpdc(1ntpdcmdoc) +utility, while the +controlkey +command selects the key used as the password for the +ntpq(1ntpqmdoc) +utility. + +

      Public Key Cryptography
      + +

      NTPv4 supports the original NTPv3 symmetric key scheme +described in RFC-1305 and in addition the Autokey protocol, +which is based on public key cryptography. +The Autokey Version 2 protocol described on the Autokey Protocol +page verifies packet integrity using MD5 message digests +and verifies the source with digital signatures and any of several +digest/signature schemes. +Optional identity schemes described on the Identity Schemes +page and based on cryptographic challenge/response algorithms +are also available. +Using all of these schemes provides strong security against +replay with or without modification, spoofing, masquerade +and most forms of clogging attacks. + +

      The Autokey protocol has several modes of operation +corresponding to the various NTP modes supported. +Most modes use a special cookie which can be +computed independently by the client and server, +but encrypted in transmission. +All modes use in addition a variant of the S-KEY scheme, +in which a pseudo-random key list is generated and used +in reverse order. +These schemes are described along with an executive summary, +current status, briefing slides and reading list on the +Autonomous Authentication +page. + +

      The specific cryptographic environment used by Autokey servers +and clients is determined by a set of files +and soft links generated by the +ntp-keygen(1ntpkeygenmdoc) +program. +This includes a required host key file, +required certificate file and optional sign key file, +leapsecond file and identity scheme files. +The +digest/signature scheme is specified in the X.509 certificate +along with the matching sign key. +There are several schemes +available in the OpenSSL software library, each identified +by a specific string such as +md5WithRSAEncryption, +which stands for the MD5 message digest with RSA +encryption scheme. +The current NTP distribution supports +all the schemes in the OpenSSL library, including +those based on RSA and DSA digital signatures. + +

      NTP secure groups can be used to define cryptographic compartments +and security hierarchies. +It is important that every host +in the group be able to construct a certificate trail to one +or more trusted hosts in the same group. +Each group +host runs the Autokey protocol to obtain the certificates +for all hosts along the trail to one or more trusted hosts. +This requires the configuration file in all hosts to be +engineered so that, even under anticipated failure conditions, +the NTP subnet will form such that every group host can find +a trail to at least one trusted host. + +

      Naming and Addressing
      + +

      It is important to note that Autokey does not use DNS to +resolve addresses, since DNS can't be completely trusted +until the name servers have synchronized clocks. +The cryptographic name used by Autokey to bind the host identity +credentials and cryptographic values must be independent +of interface, network and any other naming convention. +The name appears in the host certificate in either or both +the subject and issuer fields, so protection against +DNS compromise is essential. + +

      By convention, the name of an Autokey host is the name returned +by the Unix +gethostname(2) +system call or equivalent in other systems. +By the system design +model, there are no provisions to allow alternate names or aliases. +However, this is not to say that DNS aliases, different names +for each interface, etc., are constrained in any way. + +

      It is also important to note that Autokey verifies authenticity +using the host name, network address and public keys, +all of which are bound together by the protocol specifically +to deflect masquerade attacks. +For this reason Autokey +includes the source and destinatino IP addresses in message digest +computations and so the same addresses must be available +at both the server and client. +For this reason operation +with network address translation schemes is not possible. +This reflects the intended robust security model where government +and corporate NTP servers are operated outside firewall perimeters. + +

      Operation
      + +

      A specific combination of authentication scheme (none, +symmetric key, public key) and identity scheme is called +a cryptotype, although not all combinations are compatible. +There may be management configurations where the clients, +servers and peers may not all support the same cryptotypes. +A secure NTPv4 subnet can be configured in many ways while +keeping in mind the principles explained above and +in this section. +Note however that some cryptotype +combinations may successfully interoperate with each other, +but may not represent good security practice. + +

      The cryptotype of an association is determined at the time +of mobilization, either at configuration time or some time +later when a message of appropriate cryptotype arrives. +When mobilized by a +server +or +peer +configuration command and no +key +or +autokey +subcommands are present, the association is not +authenticated; if the +key +subcommand is present, the association is authenticated +using the symmetric key ID specified; if the +autokey +subcommand is present, the association is authenticated +using Autokey. + +

      When multiple identity schemes are supported in the Autokey +protocol, the first message exchange determines which one is used. +The client request message contains bits corresponding +to which schemes it has available. +The server response message +contains bits corresponding to which schemes it has available. +Both server and client match the received bits with their own +and select a common scheme. + +

      Following the principle that time is a public value, +a server responds to any client packet that matches +its cryptotype capabilities. +Thus, a server receiving +an unauthenticated packet will respond with an unauthenticated +packet, while the same server receiving a packet of a cryptotype +it supports will respond with packets of that cryptotype. +However, unconfigured broadcast or manycast client +associations or symmetric passive associations will not be +mobilized unless the server supports a cryptotype compatible +with the first packet received. +By default, unauthenticated associations will not be mobilized +unless overridden in a decidedly dangerous way. + +

      Some examples may help to reduce confusion. +Client Alice has no specific cryptotype selected. +Server Bob has both a symmetric key file and minimal Autokey files. +Alice's unauthenticated messages arrive at Bob, who replies with +unauthenticated messages. +Cathy has a copy of Bob's symmetric +key file and has selected key ID 4 in messages to Bob. +Bob verifies the message with his key ID 4. +If it's the +same key and the message is verified, Bob sends Cathy a reply +authenticated with that key. +If verification fails, +Bob sends Cathy a thing called a crypto-NAK, which tells her +something broke. +She can see the evidence using the +ntpq(1ntpqmdoc) +program. + +

      Denise has rolled her own host key and certificate. +She also uses one of the identity schemes as Bob. +She sends the first Autokey message to Bob and they +both dance the protocol authentication and identity steps. +If all comes out okay, Denise and Bob continue as described above. + +

      It should be clear from the above that Bob can support +all the girls at the same time, as long as he has compatible +authentication and identity credentials. +Now, Bob can act just like the girls in his own choice of servers; +he can run multiple configured associations with multiple different +servers (or the same server, although that might not be useful). +But, wise security policy might preclude some cryptotype +combinations; for instance, running an identity scheme +with one server and no authentication with another might not be wise. + +

      Key Management
      + +

      The cryptographic values used by the Autokey protocol are +incorporated as a set of files generated by the +ntp-keygen(1ntpkeygenmdoc) +utility program, including symmetric key, host key and +public certificate files, as well as sign key, identity parameters +and leapseconds files. +Alternatively, host and sign keys and +certificate files can be generated by the OpenSSL utilities +and certificates can be imported from public certificate +authorities. +Note that symmetric keys are necessary for the +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +utility programs. +The remaining files are necessary only for the +Autokey protocol. + +

      Certificates imported from OpenSSL or public certificate +authorities have certian limitations. +The certificate should be in ASN.1 syntax, X.509 Version 3 +format and encoded in PEM, which is the same format +used by OpenSSL. +The overall length of the certificate encoded +in ASN.1 must not exceed 1024 bytes. +The subject distinguished +name field (CN) is the fully qualified name of the host +on which it is used; the remaining subject fields are ignored. +The certificate extension fields must not contain either +a subject key identifier or a issuer key identifier field; +however, an extended key usage field for a trusted host must +contain the value +trustRoot;. +Other extension fields are ignored. + +

      Authentication Commands
      + +
      +
      autokey [logsec]
      Specifies the interval between regenerations of the session key +list used with the Autokey protocol. +Note that the size of the key +list for each association depends on this interval and the current +poll interval. +The default value is 12 (4096 s or about 1.1 hours). +For poll intervals above the specified interval, a session key list +with a single entry will be regenerated for every message +sent. +
      controlkey key
      Specifies the key identifier to use with the +ntpq(1ntpqmdoc) +utility, which uses the standard +protocol defined in RFC-1305. +The +key +argument is +the key identifier for a trusted key, where the value can be in the +range 1 to 65,534, inclusive. +
      crypto [cert file] [leap file] [randfile file] [host file] [sign file] [gq file] [gqpar file] [iffpar file] [mvpar file] [pw password]
      This command requires the OpenSSL library. +It activates public key +cryptography, selects the message digest and signature +encryption scheme and loads the required private and public +values described above. +If one or more files are left unspecified, +the default names are used as described above. +Unless the complete path and name of the file are specified, the +location of a file is relative to the keys directory specified +in the +keysdir +command or default +/usr/local/etc. +Following are the subcommands: +
      +
      cert file
      Specifies the location of the required host public certificate file. +This overrides the link +ntpkey_cert_hostname +in the keys directory. +
      gqpar file
      Specifies the location of the optional GQ parameters file. +This +overrides the link +ntpkey_gq_hostname +in the keys directory. +
      host file
      Specifies the location of the required host key file. +This overrides +the link +ntpkey_key_hostname +in the keys directory. +
      iffpar file
      Specifies the location of the optional IFF parameters file.This +overrides the link +ntpkey_iff_hostname +in the keys directory. +
      leap file
      Specifies the location of the optional leapsecond file. +This overrides the link +ntpkey_leap +in the keys directory. +
      mvpar file
      Specifies the location of the optional MV parameters file. +This +overrides the link +ntpkey_mv_hostname +in the keys directory. +
      pw password
      Specifies the password to decrypt files containing private keys and +identity parameters. +This is required only if these files have been +encrypted. +
      randfile file
      Specifies the location of the random seed file used by the OpenSSL +library. +The defaults are described in the main text above. +
      sign file
      Specifies the location of the optional sign key file. +This overrides +the link +ntpkey_sign_hostname +in the keys directory. +If this file is +not found, the host key is also the sign key. +
      +
      keys keyfile
      Specifies the complete path and location of the MD5 key file +containing the keys and key identifiers used by +ntpd(1ntpdmdoc), +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +when operating with symmetric key cryptography. +This is the same operation as the +-k +command line option. +
      keysdir path
      This command specifies the default directory path for +cryptographic keys, parameters and certificates. +The default is +/usr/local/etc/. +
      requestkey key
      Specifies the key identifier to use with the +ntpdc(1ntpdcmdoc) +utility program, which uses a +proprietary protocol specific to this implementation of +ntpd(1ntpdmdoc). +The +key +argument is a key identifier +for the trusted key, where the value can be in the range 1 to +65,534, inclusive. +
      revoke logsec
      Specifies the interval between re-randomization of certain +cryptographic values used by the Autokey scheme, as a power of 2 in +seconds. +These values need to be updated frequently in order to +deflect brute-force attacks on the algorithms of the scheme; +however, updating some values is a relatively expensive operation. +The default interval is 16 (65,536 s or about 18 hours). +For poll +intervals above the specified interval, the values will be updated +for every message sent. +
      trustedkey key ...
      Specifies the key identifiers which are trusted for the +purposes of authenticating peers with symmetric key cryptography, +as well as keys used by the +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +programs. +The authentication procedures require that both the local +and remote servers share the same key and key identifier for this +purpose, although different keys can be used with different +servers. +The +key +arguments are 32-bit unsigned +integers with values from 1 to 65,534. +
      + +
      Error Codes
      + +

      The following error codes are reported via the NTP control +and monitoring protocol trap mechanism. +

      +
      101
      (bad field format or length) +The packet has invalid version, length or format. +
      102
      (bad timestamp) +The packet timestamp is the same or older than the most recent received. +This could be due to a replay or a server clock time step. +
      103
      (bad filestamp) +The packet filestamp is the same or older than the most recent received. +This could be due to a replay or a key file generation error. +
      104
      (bad or missing public key) +The public key is missing, has incorrect format or is an unsupported type. +
      105
      (unsupported digest type) +The server requires an unsupported digest/signature scheme. +
      106
      (mismatched digest types) +Not used. +
      107
      (bad signature length) +The signature length does not match the current public key. +
      108
      (signature not verified) +The message fails the signature check. +It could be bogus or signed by a +different private key. +
      109
      (certificate not verified) +The certificate is invalid or signed with the wrong key. +
      110
      (certificate not verified) +The certificate is not yet valid or has expired or the signature could not +be verified. +
      111
      (bad or missing cookie) +The cookie is missing, corrupted or bogus. +
      112
      (bad or missing leapseconds table) +The leapseconds table is missing, corrupted or bogus. +
      113
      (bad or missing certificate) +The certificate is missing, corrupted or bogus. +
      114
      (bad or missing identity) +The identity key is missing, corrupt or bogus. +
      +
      +


      + +
      +
      + +

      Monitoring Support

      + +

      ntpd(1ntpdmdoc) +includes a comprehensive monitoring facility suitable +for continuous, long term recording of server and client +timekeeping performance. +See the +statistics +command below +for a listing and example of each type of statistics currently +supported. +Statistic files are managed using file generation sets +and scripts in the +./scripts +directory of this distribution. +Using +these facilities and +unix +cron(8) +jobs, the data can be +automatically summarized and archived for retrospective analysis. + +

      Monitoring Commands
      + +
      +
      statistics name ...
      Enables writing of statistics records. +Currently, eight kinds of +name +statistics are supported. +
      +
      clockstats
      Enables recording of clock driver statistics information. +Each update +received from a clock driver appends a line of the following form to +the file generation set named +clockstats: +
                
      +          49213 525.624 127.127.4.1 93 226 00:08:29.606 D
      +     
      + +

      The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the +clock address in dotted-quad notation. +The final field shows the last +timecode received from the clock in decoded ASCII format, where +meaningful. +In some clock drivers a good deal of additional information +can be gathered and displayed as well. +See information specific to each +clock for further details. +

      cryptostats
      This option requires the OpenSSL cryptographic software library. +It +enables recording of cryptographic public key protocol information. +Each message received by the protocol module appends a line of the +following form to the file generation set named +cryptostats: +
                
      +          49213 525.624 127.127.4.1 message
      +     
      + +

      The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the peer +address in dotted-quad notation, The final message field includes the +message type and certain ancillary information. +See the +Authentication Options +section for further information. +

      loopstats
      Enables recording of loop filter statistics information. +Each +update of the local clock outputs a line of the following form to +the file generation set named +loopstats: +
                
      +          50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806
      +     
      + +

      The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next five fields +show time offset (seconds), frequency offset (parts per million - +PPM), RMS jitter (seconds), Allan deviation (PPM) and clock +discipline time constant. +

      peerstats
      Enables recording of peer statistics information. +This includes +statistics records of all peers of a NTP server and of special +signals, where present and configured. +Each valid update appends a +line of the following form to the current element of a file +generation set named +peerstats: +
                
      +          48773 10847.650 127.127.4.1 9714 -0.001605376 0.000000000 0.001424877 0.000958674
      +     
      + +

      The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the peer address in dotted-quad notation and status, +respectively. +The status field is encoded in hex in the format +described in Appendix A of the NTP specification RFC 1305. +The final four fields show the offset, +delay, dispersion and RMS jitter, all in seconds. +

      rawstats
      Enables recording of raw-timestamp statistics information. +This +includes statistics records of all peers of a NTP server and of +special signals, where present and configured. +Each NTP message +received from a peer or clock driver appends a line of the +following form to the file generation set named +rawstats: +
                
      +          50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000
      +     
      + +

      The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the remote peer or clock address followed by the local address +in dotted-quad notation. +The final four fields show the originate, +receive, transmit and final NTP timestamps in order. +The timestamp +values are as received and before processing by the various data +smoothing and mitigation algorithms. +

      sysstats
      Enables recording of ntpd statistics counters on a periodic basis. +Each +hour a line of the following form is appended to the file generation +set named +sysstats: +
                
      +          50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147
      +     
      + +

      The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The remaining ten fields show +the statistics counter values accumulated since the last generated +line. +

      +
      Time since restart 36000
      Time in hours since the system was last rebooted. +
      Packets received 81965
      Total number of packets received. +
      Packets processed 0
      Number of packets received in response to previous packets sent +
      Current version 9546
      Number of packets matching the current NTP version. +
      Previous version 56
      Number of packets matching the previous NTP version. +
      Bad version 71793
      Number of packets matching neither NTP version. +
      Access denied 512
      Number of packets denied access for any reason. +
      Bad length or format 540
      Number of packets with invalid length, format or port number. +
      Bad authentication 10
      Number of packets not verified as authentic. +
      Rate exceeded 147
      Number of packets discarded due to rate limitation. +
      +
      statsdir directory_path
      Indicates the full path of a directory where statistics files +should be created (see below). +This keyword allows +the (otherwise constant) +filegen +filename prefix to be modified for file generation sets, which +is useful for handling statistics logs. +
      filegen name [file filename] [type typename] [link | nolink] [enable | disable]
      Configures setting of generation file set name. +Generation +file sets provide a means for handling files that are +continuously growing during the lifetime of a server. +Server statistics are a typical example for such files. +Generation file sets provide access to a set of files used +to store the actual data. +At any time at most one element +of the set is being written to. +The type given specifies +when and how data will be directed to a new element of the set. +This way, information stored in elements of a file set +that are currently unused are available for administrational +operations without the risk of disturbing the operation of ntpd. +(Most important: they can be removed to free space for new data +produced.) + +

      Note that this command can be sent from the +ntpdc(1ntpdcmdoc) +program running at a remote location. +

      +
      name
      This is the type of the statistics records, as shown in the +statistics +command. +
      file filename
      This is the file name for the statistics records. +Filenames of set +members are built from three concatenated elements +prefix, +filename +and +suffix: +
      +
      prefix
      This is a constant filename path. +It is not subject to +modifications via the +filegen +option. +It is defined by the +server, usually specified as a compile-time constant. +It may, +however, be configurable for individual file generation sets +via other commands. +For example, the prefix used with +loopstats +and +peerstats +generation can be configured using the +statsdir +option explained above. +
      filename
      This string is directly concatenated to the prefix mentioned +above (no intervening +/). +This can be modified using +the file argument to the +filegen +statement. +No +.. +elements are +allowed in this component to prevent filenames referring to +parts outside the filesystem hierarchy denoted by +prefix. +
      suffix
      This part is reflects individual elements of a file set. +It is +generated according to the type of a file set. +
      +
      type typename
      A file generation set is characterized by its type. +The following +types are supported: +
      +
      none
      The file set is actually a single plain file. +
      pid
      One element of file set is used per incarnation of a ntpd +server. +This type does not perform any changes to file set +members during runtime, however it provides an easy way of +separating files belonging to different +ntpd(1ntpdmdoc) +server incarnations. +The set member filename is built by appending a +. +to concatenated +prefix +and +filename +strings, and +appending the decimal representation of the process ID of the +ntpd(1ntpdmdoc) +server process. +
      day
      One file generation set element is created per day. +A day is +defined as the period between 00:00 and 24:00 UTC. +The file set +member suffix consists of a +. +and a day specification in +the form +YYYYMMdd. +YYYY +is a 4-digit year number (e.g., 1992). +MM +is a two digit month number. +dd +is a two digit day number. +Thus, all information written at 10 December 1992 would end up +in a file named +prefix +filename.19921210. +
      week
      Any file set member contains data related to a certain week of +a year. +The term week is defined by computing day-of-year +modulo 7. +Elements of such a file generation set are +distinguished by appending the following suffix to the file set +filename base: A dot, a 4-digit year number, the letter +W, +and a 2-digit week number. +For example, information from January, +10th 1992 would end up in a file with suffix +.No . Ns Ar 1992W1 . +
      month
      One generation file set element is generated per month. +The +file name suffix consists of a dot, a 4-digit year number, and +a 2-digit month. +
      year
      One generation file element is generated per year. +The filename +suffix consists of a dot and a 4 digit year number. +
      age
      This type of file generation sets changes to a new element of +the file set every 24 hours of server operation. +The filename +suffix consists of a dot, the letter +a, +and an 8-digit number. +This number is taken to be the number of seconds the server is +running at the start of the corresponding 24-hour period. +Information is only written to a file generation by specifying +enable; +output is prevented by specifying +disable. +
      +
      link | nolink
      It is convenient to be able to access the current element of a file +generation set by a fixed name. +This feature is enabled by +specifying +link +and disabled using +nolink. +If link is specified, a +hard link from the current file set element to a file without +suffix is created. +When there is already a file with this name and +the number of links of this file is one, it is renamed appending a +dot, the letter +C, +and the pid of the ntpd server process. +When the +number of links is greater than one, the file is unlinked. +This +allows the current file to be accessed by a constant name. +
      enable | disable
      Enables or disables the recording function. +
      +
      +
      +
      +


      + +
      +
      + +

      Access Control Support

      + +

      The +ntpd(1ntpdmdoc) +daemon implements a general purpose address/mask based restriction +list. +The list contains address/match entries sorted first +by increasing address values and and then by increasing mask values. +A match occurs when the bitwise AND of the mask and the packet +source address is equal to the bitwise AND of the mask and +address in the list. +The list is searched in order with the +last match found defining the restriction flags associated +with the entry. +Additional information and examples can be found in the +"Notes on Configuring NTP and Setting up a NTP Subnet" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). + +

      The restriction facility was implemented in conformance +with the access policies for the original NSFnet backbone +time servers. +Later the facility was expanded to deflect +cryptographic and clogging attacks. +While this facility may +be useful for keeping unwanted or broken or malicious clients +from congesting innocent servers, it should not be considered +an alternative to the NTP authentication facilities. +Source address based restrictions are easily circumvented +by a determined cracker. + +

      Clients can be denied service because they are explicitly +included in the restrict list created by the restrict command +or implicitly as the result of cryptographic or rate limit +violations. +Cryptographic violations include certificate +or identity verification failure; rate limit violations generally +result from defective NTP implementations that send packets +at abusive rates. +Some violations cause denied service +only for the offending packet, others cause denied service +for a timed period and others cause the denied service for +an indefinate period. +When a client or network is denied access +for an indefinate period, the only way at present to remove +the restrictions is by restarting the server. + +

      The Kiss-of-Death Packet
      + +

      Ordinarily, packets denied service are simply dropped with no +further action except incrementing statistics counters. +Sometimes a +more proactive response is needed, such as a server message that +explicitly requests the client to stop sending and leave a message +for the system operator. +A special packet format has been created +for this purpose called the "kiss-of-death" (KoD) packet. +KoD packets have the leap bits set unsynchronized and stratum set +to zero and the reference identifier field set to a four-byte +ASCII code. +If the +noserve +or +notrust +flag of the matching restrict list entry is set, +the code is "DENY"; if the +limited +flag is set and the rate limit +is exceeded, the code is "RATE". +Finally, if a cryptographic violation occurs, the code is "CRYP". + +

      A client receiving a KoD performs a set of sanity checks to +minimize security exposure, then updates the stratum and +reference identifier peer variables, sets the access +denied (TEST4) bit in the peer flash variable and sends +a message to the log. +As long as the TEST4 bit is set, +the client will send no further packets to the server. +The only way at present to recover from this condition is +to restart the protocol at both the client and server. +This +happens automatically at the client when the association times out. +It will happen at the server only if the server operator cooperates. + +

      Access Control Commands
      + +
      +
      discard [average avg] [minimum min] [monitor prob]
      Set the parameters of the +limited +facility which protects the server from +client abuse. +The +average +subcommand specifies the minimum average packet +spacing, while the +minimum +subcommand specifies the minimum packet spacing. +Packets that violate these minima are discarded +and a kiss-o'-death packet returned if enabled. +The default +minimum average and minimum are 5 and 2, respectively. +The monitor subcommand specifies the probability of discard +for packets that overflow the rate-control window. +
      restrict address [mask mask] [flag ...]
      The +address +argument expressed in +dotted-quad form is the address of a host or network. +Alternatively, the +address +argument can be a valid host DNS name. +The +mask +argument expressed in dotted-quad form defaults to +255.255.255.255, +meaning that the +address +is treated as the address of an individual host. +A default entry (address +0.0.0.0, +mask +0.0.0.0) +is always included and is always the first entry in the list. +Note that text string +default, +with no mask option, may +be used to indicate the default entry. +In the current implementation, +flag +always +restricts access, i.e., an entry with no flags indicates that free +access to the server is to be given. +The flags are not orthogonal, +in that more restrictive flags will often make less restrictive +ones redundant. +The flags can generally be classed into two +categories, those which restrict time service and those which +restrict informational queries and attempts to do run-time +reconfiguration of the server. +One or more of the following flags +may be specified: +
      +
      ignore
      Deny packets of all kinds, including +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +queries. +
      kod
      If this flag is set when an access violation occurs, a kiss-o'-death +(KoD) packet is sent. +KoD packets are rate limited to no more than one +per second. +If another KoD packet occurs within one second after the +last one, the packet is dropped. +
      limited
      Deny service if the packet spacing violates the lower limits specified +in the discard command. +A history of clients is kept using the +monitoring capability of +ntpd(1ntpdmdoc). +Thus, monitoring is always active as +long as there is a restriction entry with the +limited +flag. +
      lowpriotrap
      Declare traps set by matching hosts to be low priority. +The +number of traps a server can maintain is limited (the current limit +is 3). +Traps are usually assigned on a first come, first served +basis, with later trap requestors being denied service. +This flag +modifies the assignment algorithm by allowing low priority traps to +be overridden by later requests for normal priority traps. +
      nomodify
      Deny +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +queries which attempt to modify the state of the +server (i.e., run time reconfiguration). +Queries which return +information are permitted. +
      noquery
      Deny +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +queries. +Time service is not affected. +
      nopeer
      Deny packets which would result in mobilizing a new association. +This +includes broadcast and symmetric active packets when a configured +association does not exist. +It also includes +pool +associations, so if you want to use servers from a +pool +directive and also want to use +nopeer +by default, you'll want a +restrict source ... line as well that does +
      not
      include the +nopeer +directive. +
      noserve
      Deny all packets except +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +queries. +
      notrap
      Decline to provide mode 6 control message trap service to matching +hosts. +The trap service is a subsystem of the ntpdq control message +protocol which is intended for use by remote event logging programs. +
      notrust
      Deny service unless the packet is cryptographically authenticated. +
      ntpport
      This is actually a match algorithm modifier, rather than a +restriction flag. +Its presence causes the restriction entry to be +matched only if the source port in the packet is the standard NTP +UDP port (123). +Both +ntpport +and +non-ntpport +may +be specified. +The +ntpport +is considered more specific and +is sorted later in the list. +
      version
      Deny packets that do not match the current NTP version. +
      + +

      Default restriction list entries with the flags ignore, interface, +ntpport, for each of the local host's interface addresses are +inserted into the table at startup to prevent the server +from attempting to synchronize to its own time. +A default entry is also always present, though if it is +otherwise unconfigured; no flags are associated +with the default entry (i.e., everything besides your own +NTP server is unrestricted). +

      +
      +


      + +
      +
      + +

      Automatic NTP Configuration Options

      + +
      Manycasting
      + +

      Manycasting is a automatic discovery and configuration paradigm +new to NTPv4. +It is intended as a means for a multicast client +to troll the nearby network neighborhood to find cooperating +manycast servers, validate them using cryptographic means +and evaluate their time values with respect to other servers +that might be lurking in the vicinity. +The intended result is that each manycast client mobilizes +client associations with some number of the "best" +of the nearby manycast servers, yet automatically reconfigures +to sustain this number of servers should one or another fail. + +

      Note that the manycasting paradigm does not coincide +with the anycast paradigm described in RFC-1546, +which is designed to find a single server from a clique +of servers providing the same service. +The manycast paradigm is designed to find a plurality +of redundant servers satisfying defined optimality criteria. + +

      Manycasting can be used with either symmetric key +or public key cryptography. +The public key infrastructure (PKI) +offers the best protection against compromised keys +and is generally considered stronger, at least with relatively +large key sizes. +It is implemented using the Autokey protocol and +the OpenSSL cryptographic library available from +http://www.openssl.org/. +The library can also be used with other NTPv4 modes +as well and is highly recommended, especially for broadcast modes. + +

      A persistent manycast client association is configured +using the manycastclient command, which is similar to the +server command but with a multicast (IPv4 class +D +or IPv6 prefix +FF) +group address. +The IANA has designated IPv4 address 224.1.1.1 +and IPv6 address FF05::101 (site local) for NTP. +When more servers are needed, it broadcasts manycast +client messages to this address at the minimum feasible rate +and minimum feasible time-to-live (TTL) hops, depending +on how many servers have already been found. +There can be as many manycast client associations +as different group address, each one serving as a template +for a future ephemeral unicast client/server association. + +

      Manycast servers configured with the +manycastserver +command listen on the specified group address for manycast +client messages. +Note the distinction between manycast client, +which actively broadcasts messages, and manycast server, +which passively responds to them. +If a manycast server is +in scope of the current TTL and is itself synchronized +to a valid source and operating at a stratum level equal +to or lower than the manycast client, it replies to the +manycast client message with an ordinary unicast server message. + +

      The manycast client receiving this message mobilizes +an ephemeral client/server association according to the +matching manycast client template, but only if cryptographically +authenticated and the server stratum is less than or equal +to the client stratum. +Authentication is explicitly required +and either symmetric key or public key (Autokey) can be used. +Then, the client polls the server at its unicast address +in burst mode in order to reliably set the host clock +and validate the source. +This normally results +in a volley of eight client/server at 2-s intervals +during which both the synchronization and cryptographic +protocols run concurrently. +Following the volley, +the client runs the NTP intersection and clustering +algorithms, which act to discard all but the "best" +associations according to stratum and synchronization +distance. +The surviving associations then continue +in ordinary client/server mode. + +

      The manycast client polling strategy is designed to reduce +as much as possible the volume of manycast client messages +and the effects of implosion due to near-simultaneous +arrival of manycast server messages. +The strategy is determined by the +manycastclient, +tos +and +ttl +configuration commands. +The manycast poll interval is +normally eight times the system poll interval, +which starts out at the +minpoll +value specified in the +manycastclient, +command and, under normal circumstances, increments to the +maxpolll +value specified in this command. +Initially, the TTL is +set at the minimum hops specified by the ttl command. +At each retransmission the TTL is increased until reaching +the maximum hops specified by this command or a sufficient +number client associations have been found. +Further retransmissions use the same TTL. + +

      The quality and reliability of the suite of associations +discovered by the manycast client is determined by the NTP +mitigation algorithms and the +minclock +and +minsane +values specified in the +tos +configuration command. +At least +minsane +candidate servers must be available and the mitigation +algorithms produce at least +minclock +survivors in order to synchronize the clock. +Byzantine agreement principles require at least four +candidates in order to correctly discard a single falseticker. +For legacy purposes, +minsane +defaults to 1 and +minclock +defaults to 3. +For manycast service +minsane +should be explicitly set to 4, assuming at least that +number of servers are available. + +

      If at least +minclock +servers are found, the manycast poll interval is immediately +set to eight times +maxpoll. +If less than +minclock +servers are found when the TTL has reached the maximum hops, +the manycast poll interval is doubled. +For each transmission +after that, the poll interval is doubled again until +reaching the maximum of eight times +maxpoll. +Further transmissions use the same poll interval and +TTL values. +Note that while all this is going on, +each client/server association found is operating normally +it the system poll interval. + +

      Administratively scoped multicast boundaries are normally +specified by the network router configuration and, +in the case of IPv6, the link/site scope prefix. +By default, the increment for TTL hops is 32 starting +from 31; however, the +ttl +configuration command can be +used to modify the values to match the scope rules. + +

      It is often useful to narrow the range of acceptable +servers which can be found by manycast client associations. +Because manycast servers respond only when the client +stratum is equal to or greater than the server stratum, +primary (stratum 1) servers fill find only primary servers +in TTL range, which is probably the most common objective. +However, unless configured otherwise, all manycast clients +in TTL range will eventually find all primary servers +in TTL range, which is probably not the most common +objective in large networks. +The +tos +command can be used to modify this behavior. +Servers with stratum below +floor +or above +ceiling +specified in the +tos +command are strongly discouraged during the selection +process; however, these servers may be temporally +accepted if the number of servers within TTL range is +less than +minclock. + +

      The above actions occur for each manycast client message, +which repeats at the designated poll interval. +However, once the ephemeral client association is mobilized, +subsequent manycast server replies are discarded, +since that would result in a duplicate association. +If during a poll interval the number of client associations +falls below +minclock, +all manycast client prototype associations are reset +to the initial poll interval and TTL hops and operation +resumes from the beginning. +It is important to avoid +frequent manycast client messages, since each one requires +all manycast servers in TTL range to respond. +The result could well be an implosion, either minor or major, +depending on the number of servers in range. +The recommended value for +maxpoll +is 12 (4,096 s). + +

      It is possible and frequently useful to configure a host +as both manycast client and manycast server. +A number of hosts configured this way and sharing a common +group address will automatically organize themselves +in an optimum configuration based on stratum and +synchronization distance. +For example, consider an NTP +subnet of two primary servers and a hundred or more +dependent clients. +With two exceptions, all servers +and clients have identical configuration files including both +multicastclient +and +multicastserver +commands using, for instance, multicast group address +239.1.1.1. +The only exception is that each primary server +configuration file must include commands for the primary +reference source such as a GPS receiver. + +

      The remaining configuration files for all secondary +servers and clients have the same contents, except for the +tos +command, which is specific for each stratum level. +For stratum 1 and stratum 2 servers, that command is +not necessary. +For stratum 3 and above servers the +floor +value is set to the intended stratum number. +Thus, all stratum 3 configuration files are identical, +all stratum 4 files are identical and so forth. + +

      Once operations have stabilized in this scenario, +the primary servers will find the primary reference source +and each other, since they both operate at the same +stratum (1), but not with any secondary server or client, +since these operate at a higher stratum. +The secondary +servers will find the servers at the same stratum level. +If one of the primary servers loses its GPS receiver, +it will continue to operate as a client and other clients +will time out the corresponding association and +re-associate accordingly. + +

      Some administrators prefer to avoid running +ntpd(1ntpdmdoc) +continuously and run either +sntp(1sntpmdoc) +or +ntpd(1ntpdmdoc) +-q +as a cron job. +In either case the servers must be +configured in advance and the program fails if none are +available when the cron job runs. +A really slick +application of manycast is with +ntpd(1ntpdmdoc) +-q. +The program wakes up, scans the local landscape looking +for the usual suspects, selects the best from among +the rascals, sets the clock and then departs. +Servers do not have to be configured in advance and +all clients throughout the network can have the same +configuration file. + +

      Manycast Interactions with Autokey
      + +

      Each time a manycast client sends a client mode packet +to a multicast group address, all manycast servers +in scope generate a reply including the host name +and status word. +The manycast clients then run +the Autokey protocol, which collects and verifies +all certificates involved. +Following the burst interval +all but three survivors are cast off, +but the certificates remain in the local cache. +It often happens that several complete signing trails +from the client to the primary servers are collected in this way. + +

      About once an hour or less often if the poll interval +exceeds this, the client regenerates the Autokey key list. +This is in general transparent in client/server mode. +However, about once per day the server private value +used to generate cookies is refreshed along with all +manycast client associations. +In this case all +cryptographic values including certificates is refreshed. +If a new certificate has been generated since +the last refresh epoch, it will automatically revoke +all prior certificates that happen to be in the +certificate cache. +At the same time, the manycast +scheme starts all over from the beginning and +the expanding ring shrinks to the minimum and increments +from there while collecting all servers in scope. + +

      Manycast Options
      + +
      +
      tos [ceiling ceiling | cohort { 0 | 1 } | floor floor | minclock minclock | minsane minsane]
      This command affects the clock selection and clustering +algorithms. +It can be used to select the quality and +quantity of peers used to synchronize the system clock +and is most useful in manycast mode. +The variables operate +as follows: +
      +
      ceiling ceiling
      Peers with strata above +ceiling +will be discarded if there are at least +minclock +peers remaining. +This value defaults to 15, but can be changed +to any number from 1 to 15. +
      cohort {0 | 1}
      This is a binary flag which enables (0) or disables (1) +manycast server replies to manycast clients with the same +stratum level. +This is useful to reduce implosions where +large numbers of clients with the same stratum level +are present. +The default is to enable these replies. +
      floor floor
      Peers with strata below +floor +will be discarded if there are at least +minclock +peers remaining. +This value defaults to 1, but can be changed +to any number from 1 to 15. +
      minclock minclock
      The clustering algorithm repeatedly casts out outlier +associations until no more than +minclock +associations remain. +This value defaults to 3, +but can be changed to any number from 1 to the number of +configured sources. +
      minsane minsane
      This is the minimum number of candidates available +to the clock selection algorithm in order to produce +one or more truechimers for the clustering algorithm. +If fewer than this number are available, the clock is +undisciplined and allowed to run free. +The default is 1 +for legacy purposes. +However, according to principles of +Byzantine agreement, +minsane +should be at least 4 in order to detect and discard +a single falseticker. +
      +
      ttl hop ...
      This command specifies a list of TTL values in increasing +order, up to 8 values can be specified. +In manycast mode these values are used in turn +in an expanding-ring search. +The default is eight +multiples of 32 starting at 31. +
      +
      +


      + +
      +
      + +

      Reference Clock Support

      + +

      The NTP Version 4 daemon supports some three dozen different radio, +satellite and modem reference clocks plus a special pseudo-clock +used for backup or when no other clock source is available. +Detailed descriptions of individual device drivers and options can +be found in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). +Additional information can be found in the pages linked +there, including the +"Debugging Hints for Reference Clock Drivers" +and +"How To Write a Reference Clock Driver" +pages +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). +In addition, support for a PPS +signal is available as described in the +"Pulse-per-second (PPS) Signal Interfacing" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). +Many +drivers support special line discipline/streams modules which can +significantly improve the accuracy using the driver. +These are +described in the +"Line Disciplines and Streams Drivers" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). + +

      A reference clock will generally (though not always) be a radio +timecode receiver which is synchronized to a source of standard +time such as the services offered by the NRC in Canada and NIST and +USNO in the US. +The interface between the computer and the timecode +receiver is device dependent, but is usually a serial port. +A +device driver specific to each reference clock must be selected and +compiled in the distribution; however, most common radio, satellite +and modem clocks are included by default. +Note that an attempt to +configure a reference clock when the driver has not been compiled +or the hardware port has not been appropriately configured results +in a scalding remark to the system log file, but is otherwise non +hazardous. + +

      For the purposes of configuration, +ntpd(1ntpdmdoc) +treats +reference clocks in a manner analogous to normal NTP peers as much +as possible. +Reference clocks are identified by a syntactically +correct but invalid IP address, in order to distinguish them from +normal NTP peers. +Reference clock addresses are of the form +127.127.t.u, +where +t +is an integer +denoting the clock type and +u +indicates the unit +number in the range 0-3. +While it may seem overkill, it is in fact +sometimes useful to configure multiple reference clocks of the same +type, in which case the unit numbers must be unique. + +

      The +server +command is used to configure a reference +clock, where the +address +argument in that command +is the clock address. +The +key, +version +and +ttl +options are not used for reference clock support. +The +mode +option is added for reference clock support, as +described below. +The +prefer +option can be useful to +persuade the server to cherish a reference clock with somewhat more +enthusiasm than other reference clocks or peers. +Further +information on this option can be found in the +"Mitigation Rules and the prefer Keyword" +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp) +page. +The +minpoll +and +maxpoll +options have +meaning only for selected clock drivers. +See the individual clock +driver document pages for additional information. + +

      The +fudge +command is used to provide additional +information for individual clock drivers and normally follows +immediately after the +server +command. +The +address +argument specifies the clock address. +The +refid +and +stratum +options can be used to +override the defaults for the device. +There are two optional +device-dependent time offsets and four flags that can be included +in the +fudge +command as well. + +

      The stratum number of a reference clock is by default zero. +Since the +ntpd(1ntpdmdoc) +daemon adds one to the stratum of each +peer, a primary server ordinarily displays an external stratum of +one. +In order to provide engineered backups, it is often useful to +specify the reference clock stratum as greater than zero. +The +stratum +option is used for this purpose. +Also, in cases +involving both a reference clock and a pulse-per-second (PPS) +discipline signal, it is useful to specify the reference clock +identifier as other than the default, depending on the driver. +The +refid +option is used for this purpose. +Except where noted, +these options apply to all clock drivers. + +

      Reference Clock Commands
      + +
      +
      server 127.127.t.u [prefer] [mode int] [minpoll int] [maxpoll int]
      This command can be used to configure reference clocks in +special ways. +The options are interpreted as follows: +
      +
      prefer
      Marks the reference clock as preferred. +All other things being +equal, this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp) +for further information. +
      mode int
      Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +
      minpoll int
      maxpoll int
      These options specify the minimum and maximum polling interval +for reference clock messages, as a power of 2 in seconds +For +most directly connected reference clocks, both +minpoll +and +maxpoll +default to 6 (64 s). +For modem reference clocks, +minpoll +defaults to 10 (17.1 m) and +maxpoll +defaults to 14 (4.5 h). +The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. +
      +
      fudge 127.127.t.u [time1 sec] [time2 sec] [stratum int] [refid string] [mode int] [flag1 0 | 1] [flag2 0 | 1] [flag3 0 | 1] [flag4 0 | 1]
      This command can be used to configure reference clocks in +special ways. +It must immediately follow the +server +command which configures the driver. +Note that the same capability +is possible at run time using the +ntpdc(1ntpdcmdoc) +program. +The options are interpreted as +follows: +
      +
      time1 sec
      Specifies a constant to be added to the time offset produced by +the driver, a fixed-point decimal number in seconds. +This is used +as a calibration constant to adjust the nominal time offset of a +particular clock to agree with an external standard, such as a +precision PPS signal. +It also provides a way to correct a +systematic error or bias due to serial port or operating system +latencies, different cable lengths or receiver internal delay. +The +specified offset is in addition to the propagation delay provided +by other means, such as internal DIPswitches. +Where a calibration +for an individual system and driver is available, an approximate +correction is noted in the driver documentation pages. +Note: in order to facilitate calibration when more than one +radio clock or PPS signal is supported, a special calibration +feature is available. +It takes the form of an argument to the +enable +command described in +Miscellaneous Options +page and operates as described in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). +
      time2 secs
      Specifies a fixed-point decimal number in seconds, which is +interpreted in a driver-dependent way. +See the descriptions of +specific drivers in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +/usr/share/doc/ntp). +
      stratum int
      Specifies the stratum number assigned to the driver, an integer +between 0 and 15. +This number overrides the default stratum number +ordinarily assigned by the driver itself, usually zero. +
      refid string
      Specifies an ASCII string of from one to four characters which +defines the reference identifier used by the driver. +This string +overrides the default identifier ordinarily assigned by the driver +itself. +
      mode int
      Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +
      flag1 0 | 1
      flag2 0 | 1
      flag3 0 | 1
      flag4 0 | 1
      These four flags are used for customizing the clock driver. +The +interpretation of these values, and whether they are used at all, +is a function of the particular clock driver. +However, by +convention +flag4 +is used to enable recording monitoring +data to the +clockstats +file configured with the +filegen +command. +Further information on the +filegen +command can be found in +Monitoring Options. +
      +
      +
      +


      + +
      +
      + +

      Miscellaneous Options

      + +
      +
      broadcastdelay seconds
      The broadcast and multicast modes require a special calibration +to determine the network delay between the local and remote +servers. +Ordinarily, this is done automatically by the initial +protocol exchanges between the client and server. +In some cases, +the calibration procedure may fail due to network or server access +controls, for example. +This command specifies the default delay to +be used under these circumstances. +Typically (for Ethernet), a +number between 0.003 and 0.007 seconds is appropriate. +The default +when this command is not used is 0.004 seconds. +
      calldelay delay
      This option controls the delay in seconds between the first and second +packets sent in burst or iburst mode to allow additional time for a modem +or ISDN call to complete. +
      driftfile driftfile
      This command specifies the complete path and name of the file used to +record the frequency of the local clock oscillator. +This is the same +operation as the +-f +command line option. +If the file exists, it is read at +startup in order to set the initial frequency and then updated once per +hour with the current frequency computed by the daemon. +If the file name is +specified, but the file itself does not exist, the starts with an initial +frequency of zero and creates the file when writing it for the first time. +If this command is not given, the daemon will always start with an initial +frequency of zero. + +

      The file format consists of a single line containing a single +floating point number, which records the frequency offset measured +in parts-per-million (PPM). +The file is updated by first writing +the current drift value into a temporary file and then renaming +this file to replace the old version. +This implies that +ntpd(1ntpdmdoc) +must have write permission for the directory the +drift file is located in, and that file system links, symbolic or +otherwise, should be avoided. +

      dscp value
      This option specifies the Differentiated Services Control Point (DSCP) value, +a 6-bit code. The default value is 46, signifying Expedited Forwarding. +
      enable [auth | bclient | calibrate | kernel | mode7 | monitor | ntp | stats]
      disable [auth | bclient | calibrate | kernel | mode7 | monitor | ntp | stats]
      Provides a way to enable or disable various server options. +Flags not mentioned are unaffected. +Note that all of these flags +can be controlled remotely using the +ntpdc(1ntpdcmdoc) +utility program. +
      +
      auth
      Enables the server to synchronize with unconfigured peers only if the +peer has been correctly authenticated using either public key or +private key cryptography. +The default for this flag is +enable. +
      bclient
      Enables the server to listen for a message from a broadcast or +multicast server, as in the +multicastclient +command with default +address. +The default for this flag is +disable. +
      calibrate
      Enables the calibrate feature for reference clocks. +The default for +this flag is +disable. +
      kernel
      Enables the kernel time discipline, if available. +The default for this +flag is +enable +if support is available, otherwise +disable. +
      mode7
      Enables processing of NTP mode 7 implementation-specific requests +which are used by the deprecated +ntpdc(1ntpdcmdoc) +program. +The default for this flag is disable. +This flag is excluded from runtime configuration using +ntpq(1ntpqmdoc). +The +ntpq(1ntpqmdoc) +program provides the same capabilities as +ntpdc(1ntpdcmdoc) +using standard mode 6 requests. +
      monitor
      Enables the monitoring facility. +See the +ntpdc(1ntpdcmdoc) +program +and the +monlist +command or further information. +The +default for this flag is +enable. +
      ntp
      Enables time and frequency discipline. +In effect, this switch opens and +closes the feedback loop, which is useful for testing. +The default for +this flag is +enable. +
      stats
      Enables the statistics facility. +See the +Monitoring Options +section for further information. +The default for this flag is +disable. +
      +
      includefile includefile
      This command allows additional configuration commands +to be included from a separate file. +Include files may +be nested to a depth of five; upon reaching the end of any +include file, command processing resumes in the previous +configuration file. +This option is useful for sites that run +ntpd(1ntpdmdoc) +on multiple hosts, with (mostly) common options (e.g., a +restriction list). +
      leapsmearinterval seconds
      This EXPERIMENTAL option is only available if +ntpd(1ntpdmdoc) +was built with the +--enable-leap-smear +option to the +configure +script. +It specifies the interval over which a leap second correction will be applied. +Recommended values for this option are between +7200 (2 hours) and 86400 (24 hours). +.Sy DO NOT USE THIS OPTION ON PUBLIC-ACCESS SERVERS! +See http://bugs.ntp.org/2855 for more information. +
      logconfig configkeyword
      This command controls the amount and type of output written to +the system +syslog(3) +facility or the alternate +logfile +log file. +By default, all output is turned on. +All +configkeyword +keywords can be prefixed with +=, ++ +and +-, +where += +sets the +syslog(3) +priority mask, ++ +adds and +- +removes +messages. +syslog(3) +messages can be controlled in four +classes +(clock, peer, sys and sync). +Within these classes four types of messages can be +controlled: informational messages +(info), +event messages +(events), +statistics messages +(statistics) +and +status messages +(status). + +

      Configuration keywords are formed by concatenating the message class with +the event class. +The +all +prefix can be used instead of a message class. +A +message class may also be followed by the +all +keyword to enable/disable all +messages of the respective message class.Thus, a minimal log configuration +could look like this: +

           
      +     logconfig =syncstatus +sysevents
      +
      + +

      This would just list the synchronizations state of +ntpd(1ntpdmdoc) +and the major system events. +For a simple reference server, the +following minimum message configuration could be useful: +

           
      +     logconfig =syncall +clockall
      +
      + +

      This configuration will list all clock information and +synchronization information. +All other events and messages about +peers, system events and so on is suppressed. +

      logfile logfile
      This command specifies the location of an alternate log file to +be used instead of the default system +syslog(3) +facility. +This is the same operation as the -l command line option. +
      setvar variable [default]
      This command adds an additional system variable. +These +variables can be used to distribute additional information such as +the access policy. +If the variable of the form +name=value +is followed by the +default +keyword, the +variable will be listed as part of the default system variables +(rv command)). +These additional variables serve +informational purposes only. +They are not related to the protocol +other that they can be listed. +The known protocol variables will +always override any variables defined via the +setvar +mechanism. +There are three special variables that contain the names +of all variable of the same group. +The +sys_var_list +holds +the names of all system variables. +The +peer_var_list +holds +the names of all peer variables and the +clock_var_list +holds the names of the reference clock variables. +
      tinker [allan allan | dispersion dispersion | freq freq | huffpuff huffpuff | panic panic | step step | stepback stepback | stepfwd stepfwd | stepout stepout]
      This command can be used to alter several system variables in +very exceptional circumstances. +It should occur in the +configuration file before any other configuration options. +The +default values of these variables have been carefully optimized for +a wide range of network speeds and reliability expectations. +In +general, they interact in intricate ways that are hard to predict +and some combinations can result in some very nasty behavior. +Very +rarely is it necessary to change the default values; but, some +folks cannot resist twisting the knobs anyway and this command is +for them. +Emphasis added: twisters are on their own and can expect +no help from the support group. + +

      The variables operate as follows: +

      +
      allan allan
      The argument becomes the new value for the minimum Allan +intercept, which is a parameter of the PLL/FLL clock discipline +algorithm. +The value in log2 seconds defaults to 7 (1024 s), which is also the lower +limit. +
      dispersion dispersion
      The argument becomes the new value for the dispersion increase rate, +normally .000015 s/s. +
      freq freq
      The argument becomes the initial value of the frequency offset in +parts-per-million. +This overrides the value in the frequency file, if +present, and avoids the initial training state if it is not. +
      huffpuff huffpuff
      The argument becomes the new value for the experimental +huff-n'-puff filter span, which determines the most recent interval +the algorithm will search for a minimum delay. +The lower limit is +900 s (15 m), but a more reasonable value is 7200 (2 hours). +There +is no default, since the filter is not enabled unless this command +is given. +
      panic panic
      The argument is the panic threshold, normally 1000 s. +If set to zero, +the panic sanity check is disabled and a clock offset of any value will +be accepted. +
      step step
      The argument is the step threshold, which by default is 0.128 s. +It can +be set to any positive number in seconds. +If set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if the step threshold is set to zero or greater than the +default. +
      stepback stepback
      The argument is the step threshold for the backward direction, +which by default is 0.128 s. +It can +be set to any positive number in seconds. +If both the forward and backward step thresholds are set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if +each direction of step threshold are either +set to zero or greater than .5 second. +
      stepfwd stepfwd
      As for stepback, but for the forward direction. +
      stepout stepout
      The argument is the stepout timeout, which by default is 900 s. +It can +be set to any positive number in seconds. +If set to zero, the stepout +pulses will not be suppressed. +
      +
      rlimit [memlock Nmegabytes | stacksize N4kPages filenum Nfiledescriptors]
      +
      +
      memlock Nmegabytes
      Specify the number of megabytes of memory that should be +allocated and locked. +Probably only available under Linux, this option may be useful +when dropping root (the +-i +option). +The default is 32 megabytes on non-Linux machines, and -1 under Linux. +-1 means "do not lock the process into memory". +0 means "lock whatever memory the process wants into memory". +
      stacksize N4kPages
      Specifies the maximum size of the process stack on systems with the +mlockall() +function. +Defaults to 50 4k pages (200 4k pages in OpenBSD). +
      filenum Nfiledescriptors
      Specifies the maximum number of file descriptors ntpd may have open at once. Defaults to the system default. +
      +
      trap host_address [port port_number] [interface interface_address]
      This command configures a trap receiver at the given host +address and port number for sending messages with the specified +local interface address. +If the port number is unspecified, a value +of 18447 is used. +If the interface address is not specified, the +message is sent with a source address of the local interface the +message is sent through. +Note that on a multihomed host the +interface used may vary from time to time with routing changes. + +

      The trap receiver will generally log event messages and other +information from the server in a log file. +While such monitor +programs may also request their own trap dynamically, configuring a +trap receiver will ensure that no messages are lost when the server +is started. +

      hop ...
      This command specifies a list of TTL values in increasing order, up to 8 +values can be specified. +In manycast mode these values are used in turn in +an expanding-ring search. +The default is eight multiples of 32 starting at +31. +
      + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntp.conf program. +This software is released under the NTP license, <http://ntp.org/license>. + +

      + +
      +


      + +
      +
      + +

      ntp.conf Files

      + +
      +
      /etc/ntp.conf
      the default name of the configuration file +
      ntp.keys
      private MD5 keys +
      ntpkey
      RSA private key +
      ntpkey_host
      RSA public key +
      ntp_dh
      Diffie-Hellman agreement parameters +
      +
      +


      + +
      +
      + +

      ntp.conf See Also

      + +

      ntpd(1ntpdmdoc), +ntpdc(1ntpdcmdoc), +ntpq(1ntpqmdoc) + +

      In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +http://www.ntp.org/. +A snapshot of this documentation is available in HTML format in +/usr/share/doc/ntp. +
      + +


      +David L. Mills, Network Time Protocol (Version 4), RFC5905 +

      +


      + +
      +
      + +

      ntp.conf Bugs

      + +

      The syntax checking is not picky; some combinations of +ridiculous and even hilarious options and modes may not be +detected. + +

      The +ntpkey_host +files are really digital +certificates. +These should be obtained via secure directory +services when they become universally available. +

      +


      + +
      +
      + +

      ntp.conf Notes

      + +

      This document was derived from FreeBSD. + + + diff --git a/contrib/ntp/ntpd/ntp.conf.man.in b/contrib/ntp/ntpd/ntp.conf.man.in new file mode 100644 index 000000000..7c8a39f46 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.conf.man.in @@ -0,0 +1,3055 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntp.conf 5 "21 Oct 2015" "4.2.8p4" "File Formats" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-9oaqYI/ag-OpaiXI) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:01 PM by AutoGen 5.18.5 +.\" From the definitions ntp.conf.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntp.conf\fP +\- Network Time Protocol (NTP) daemon configuration file format +.SH SYNOPSIS +\f\*[B-Font]ntp.conf\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The +\f\*[B-Font]ntp.conf\fP +configuration file is read at initial startup by the +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +daemon in order to specify the synchronization sources, +modes and other related information. +Usually, it is installed in the +\fI/etc\f[] +directory, +but could be installed elsewhere +(see the daemon's +\f\*[B-Font]\-c\f[] +command line option). +.sp \n(Ppu +.ne 2 + +The file format is similar to other +UNIX +configuration files. +Comments begin with a +\[oq]#\[cq] +character and extend to the end of the line; +blank lines are ignored. +Configuration commands consist of an initial keyword +followed by a list of arguments, +some of which may be optional, separated by whitespace. +Commands may not be continued over multiple lines. +Arguments may be host names, +host addresses written in numeric, dotted-quad form, +integers, floating point numbers (when specifying times in seconds) +and text strings. +.sp \n(Ppu +.ne 2 + +The rest of this page describes the configuration and control options. +The +"Notes on Configuring NTP and Setting up an NTP Subnet" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +contains an extended discussion of these options. +In addition to the discussion of general +\fIConfiguration\f[] \fIOptions\f[], +there are sections describing the following supported functionality +and the options used to control it: +.IP \fB\(bu\fP 2 +\fIAuthentication\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIMonitoring\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIAccess\f[] \fIControl\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIAutomatic\f[] \fINTP\f[] \fIConfiguration\f[] \fIOptions\f[] +.IP \fB\(bu\fP 2 +\fIReference\f[] \fIClock\f[] \fISupport\f[] +.IP \fB\(bu\fP 2 +\fIMiscellaneous\f[] \fIOptions\f[] +.PP +.sp \n(Ppu +.ne 2 + +Following these is a section describing +\fIMiscellaneous\f[] \fIOptions\f[]. +While there is a rich set of options available, +the only required option is one or more +\f\*[B-Font]pool\f[], +\f\*[B-Font]server\f[], +\f\*[B-Font]peer\f[], +\f\*[B-Font]broadcast\f[] +or +\f\*[B-Font]manycastclient\f[] +commands. +.SH Configuration Support +Following is a description of the configuration commands in +NTPv4. +These commands have the same basic functions as in NTPv3 and +in some cases new functions and new arguments. +There are two +classes of commands, configuration commands that configure a +persistent association with a remote server or peer or reference +clock, and auxiliary commands that specify environmental variables +that control various related operations. +.SS Configuration Commands +The various modes are determined by the command keyword and the +type of the required IP address. +Addresses are classed by type as +(s) a remote server or peer (IPv4 class A, B and C), (b) the +broadcast address of a local interface, (m) a multicast address (IPv4 +class D), or (r) a reference clock address (127.127.x.x). +Note that +only those options applicable to each command are listed below. +Use +of options not listed may not be caught as an error, but may result +in some weird and even destructive behavior. +.sp \n(Ppu +.ne 2 + +If the Basic Socket Interface Extensions for IPv6 (RFC-2553) +is detected, support for the IPv6 address family is generated +in addition to the default support of the IPv4 address family. +In a few cases, including the reslist billboard generated +by ntpdc, IPv6 addresses are automatically generated. +IPv6 addresses can be identified by the presence of colons +\*[Lq]\&:\*[Rq] +in the address field. +IPv6 addresses can be used almost everywhere where +IPv4 addresses can be used, +with the exception of reference clock addresses, +which are always IPv4. +.sp \n(Ppu +.ne 2 + +Note that in contexts where a host name is expected, a +\f\*[B-Font]\-4\f[] +qualifier preceding +the host name forces DNS resolution to the IPv4 namespace, +while a +\f\*[B-Font]\-6\f[] +qualifier forces DNS resolution to the IPv6 namespace. +See IPv6 references for the +equivalent classes for that address family. +.TP 7 +.NOP \f\*[B-Font]pool\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]burst\f[]] [\f\*[B-Font]iburst\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] +.TP 7 +.NOP \f\*[B-Font]server\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]burst\f[]] [\f\*[B-Font]iburst\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] +.TP 7 +.NOP \f\*[B-Font]peer\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] +.TP 7 +.NOP \f\*[B-Font]broadcast\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]ttl\f[] \f\*[I-Font]ttl\f[]] +.TP 7 +.NOP \f\*[B-Font]manycastclient\f[] \f\*[I-Font]address\f[] [\f\*[B-Font]key\f[] \f\*[I-Font]key\f[] \f\*[I-Font]\&|\f[] \f\*[B-Font]autokey\f[]] [\f\*[B-Font]version\f[] \f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[]] [\f\*[B-Font]ttl\f[] \f\*[I-Font]ttl\f[]] +.PP +.sp \n(Ppu +.ne 2 + +These five commands specify the time server name or address to +be used and the mode in which to operate. +The +\f\*[I-Font]address\f[] +can be +either a DNS name or an IP address in dotted-quad notation. +Additional information on association behavior can be found in the +"Association Management" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.TP 7 +.NOP \f\*[B-Font]pool\f[] +For type s addresses, this command mobilizes a persistent +client mode association with a number of remote servers. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +.TP 7 +.NOP \f\*[B-Font]server\f[] +For type s and r addresses, this command mobilizes a persistent +client mode association with the specified remote server or local +radio clock. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +This command should +\fInot\f[] +be used for type +b or m addresses. +.TP 7 +.NOP \f\*[B-Font]peer\f[] +For type s addresses (only), this command mobilizes a +persistent symmetric-active mode association with the specified +remote peer. +In this mode the local clock can be synchronized to +the remote peer or the remote peer can be synchronized to the local +clock. +This is useful in a network of servers where, depending on +various failure scenarios, either the local or remote peer may be +the better source of time. +This command should NOT be used for type +b, m or r addresses. +.TP 7 +.NOP \f\*[B-Font]broadcast\f[] +For type b and m addresses (only), this +command mobilizes a persistent broadcast mode association. +Multiple +commands can be used to specify multiple local broadcast interfaces +(subnets) and/or multiple multicast groups. +Note that local +broadcast messages go only to the interface associated with the +subnet specified, but multicast messages go to all interfaces. +In broadcast mode the local server sends periodic broadcast +messages to a client population at the +\f\*[I-Font]address\f[] +specified, which is usually the broadcast address on (one of) the +local network(s) or a multicast address assigned to NTP. +The IANA +has assigned the multicast group address IPv4 224.0.1.1 and +IPv6 ff05::101 (site local) exclusively to +NTP, but other nonconflicting addresses can be used to contain the +messages within administrative boundaries. +Ordinarily, this +specification applies only to the local server operating as a +sender; for operation as a broadcast client, see the +\f\*[B-Font]broadcastclient\f[] +or +\f\*[B-Font]multicastclient\f[] +commands +below. +.TP 7 +.NOP \f\*[B-Font]manycastclient\f[] +For type m addresses (only), this command mobilizes a +manycast client mode association for the multicast address +specified. +In this case a specific address must be supplied which +matches the address used on the +\f\*[B-Font]manycastserver\f[] +command for +the designated manycast servers. +The NTP multicast address +224.0.1.1 assigned by the IANA should NOT be used, unless specific +means are taken to avoid spraying large areas of the Internet with +these messages and causing a possibly massive implosion of replies +at the sender. +The +\f\*[B-Font]manycastserver\f[] +command specifies that the local server +is to operate in client mode with the remote servers that are +discovered as the result of broadcast/multicast messages. +The +client broadcasts a request message to the group address associated +with the specified +\f\*[I-Font]address\f[] +and specifically enabled +servers respond to these messages. +The client selects the servers +providing the best time and continues as with the +\f\*[B-Font]server\f[] +command. +The remaining servers are discarded as if never +heard. +.PP +.sp \n(Ppu +.ne 2 + +Options: +.TP 7 +.NOP \f\*[B-Font]autokey\f[] +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the autokey scheme +described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]burst\f[] +when the server is reachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first and second packets +can be changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to improve timekeeping quality +with the +\f\*[B-Font]server\f[] +command and s addresses. +.TP 7 +.NOP \f\*[B-Font]iburst\f[] +When the server is unreachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first two packets can be +changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to speed the initial synchronization +acquisition with the +\f\*[B-Font]server\f[] +command and s addresses and when +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +is started with the +\f\*[B-Font]\-q\f[] +option. +.TP 7 +.NOP \f\*[B-Font]key\f[] \f\*[I-Font]key\f[] +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the specified +\f\*[I-Font]key\f[] +identifier with values from 1 to 65534, inclusive. +The +default is to include no encryption field. +.TP 7 +.NOP \f\*[B-Font]minpoll\f[] \f\*[I-Font]minpoll\f[] +.TP 7 +.NOP \f\*[B-Font]maxpoll\f[] \f\*[I-Font]maxpoll\f[] +These options specify the minimum and maximum poll intervals +for NTP messages, as a power of 2 in seconds +The maximum poll +interval defaults to 10 (1,024 s), but can be increased by the +\f\*[B-Font]maxpoll\f[] +option to an upper limit of 17 (36.4 h). +The +minimum poll interval defaults to 6 (64 s), but can be decreased by +the +\f\*[B-Font]minpoll\f[] +option to a lower limit of 4 (16 s). +.TP 7 +.NOP \f\*[B-Font]noselect\f[] +Marks the server as unused, except for display purposes. +The server is discarded by the selection algroithm. +.TP 7 +.NOP \f\*[B-Font]prefer\f[] +Marks the server as preferred. +All other things being equal, +this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +for further information. +.TP 7 +.NOP \f\*[B-Font]ttl\f[] \f\*[I-Font]ttl\f[] +This option is used only with broadcast server and manycast +client modes. +It specifies the time-to-live +\f\*[I-Font]ttl\f[] +to +use on broadcast server and multicast server and the maximum +\f\*[I-Font]ttl\f[] +for the expanding ring search with manycast +client packets. +Selection of the proper value, which defaults to +127, is something of a black art and should be coordinated with the +network administrator. +.TP 7 +.NOP \f\*[B-Font]version\f[] \f\*[I-Font]version\f[] +Specifies the version number to be used for outgoing NTP +packets. +Versions 1-4 are the choices, with version 4 the +default. +.PP +.SS Auxiliary Commands +.TP 7 +.NOP \f\*[B-Font]broadcastclient\f[] +This command enables reception of broadcast server messages to +any local interface (type b) address. +Upon receiving a message for +the first time, the broadcast client measures the nominal server +propagation delay using a brief client/server exchange with the +server, then enters the broadcast client mode, in which it +synchronizes to succeeding broadcast messages. +Note that, in order +to avoid accidental or malicious disruption in this mode, both the +server and client should operate using symmetric-key or public-key +authentication as described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]manycastserver\f[] \f\*[I-Font]address\f[] \f\*[I-Font]...\f[] +This command enables reception of manycast client messages to +the multicast group address(es) (type m) specified. +At least one +address is required, but the NTP multicast address 224.0.1.1 +assigned by the IANA should NOT be used, unless specific means are +taken to limit the span of the reply and avoid a possibly massive +implosion at the original sender. +Note that, in order to avoid +accidental or malicious disruption in this mode, both the server +and client should operate using symmetric-key or public-key +authentication as described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]multicastclient\f[] \f\*[I-Font]address\f[] \f\*[I-Font]...\f[] +This command enables reception of multicast server messages to +the multicast group address(es) (type m) specified. +Upon receiving +a message for the first time, the multicast client measures the +nominal server propagation delay using a brief client/server +exchange with the server, then enters the broadcast client mode, in +which it synchronizes to succeeding multicast messages. +Note that, +in order to avoid accidental or malicious disruption in this mode, +both the server and client should operate using symmetric-key or +public-key authentication as described in +\fIAuthentication\f[] \fIOptions\f[]. +.TP 7 +.NOP \f\*[B-Font]mdnstries\f[] \f\*[I-Font]number\f[] +If we are participating in mDNS, +after we have synched for the first time +we attempt to register with the mDNS system. +If that registration attempt fails, +we try again at one minute intervals for up to +\f\*[B-Font]mdnstries\f[] +times. +After all, +\f\*[B-Font]ntpd\f[] +may be starting before mDNS. +The default value for +\f\*[B-Font]mdnstries\f[] +is 5. +.PP +.SH Authentication Support +Authentication support allows the NTP client to verify that the +server is in fact known and trusted and not an intruder intending +accidentally or on purpose to masquerade as that server. +The NTPv3 +specification RFC-1305 defines a scheme which provides +cryptographic authentication of received NTP packets. +Originally, +this was done using the Data Encryption Standard (DES) algorithm +operating in Cipher Block Chaining (CBC) mode, commonly called +DES-CBC. +Subsequently, this was replaced by the RSA Message Digest +5 (MD5) algorithm using a private key, commonly called keyed-MD5. +Either algorithm computes a message digest, or one-way hash, which +can be used to verify the server has the correct private key and +key identifier. +.sp \n(Ppu +.ne 2 + +NTPv4 retains the NTPv3 scheme, properly described as symmetric key +cryptography and, in addition, provides a new Autokey scheme +based on public key cryptography. +Public key cryptography is generally considered more secure +than symmetric key cryptography, since the security is based +on a private value which is generated by each server and +never revealed. +With Autokey all key distribution and +management functions involve only public values, which +considerably simplifies key distribution and storage. +Public key management is based on X.509 certificates, +which can be provided by commercial services or +produced by utility programs in the OpenSSL software library +or the NTPv4 distribution. +.sp \n(Ppu +.ne 2 + +While the algorithms for symmetric key cryptography are +included in the NTPv4 distribution, public key cryptography +requires the OpenSSL software library to be installed +before building the NTP distribution. +Directions for doing that +are on the Building and Installing the Distribution page. +.sp \n(Ppu +.ne 2 + +Authentication is configured separately for each association +using the +\f\*[B-Font]key\f[] +or +\f\*[B-Font]autokey\f[] +subcommand on the +\f\*[B-Font]peer\f[], +\f\*[B-Font]server\f[], +\f\*[B-Font]broadcast\f[] +and +\f\*[B-Font]manycastclient\f[] +configuration commands as described in +\fIConfiguration\f[] \fIOptions\f[] +page. +The authentication +options described below specify the locations of the key files, +if other than default, which symmetric keys are trusted +and the interval between various operations, if other than default. +.sp \n(Ppu +.ne 2 + +Authentication is always enabled, +although ineffective if not configured as +described below. +If a NTP packet arrives +including a message authentication +code (MAC), it is accepted only if it +passes all cryptographic checks. +The +checks require correct key ID, key value +and message digest. +If the packet has +been modified in any way or replayed +by an intruder, it will fail one or more +of these checks and be discarded. +Furthermore, the Autokey scheme requires a +preliminary protocol exchange to obtain +the server certificate, verify its +credentials and initialize the protocol +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]auth\f[] +flag controls whether new associations or +remote configuration commands require cryptographic authentication. +This flag can be set or reset by the +\f\*[B-Font]enable\f[] +and +\f\*[B-Font]disable\f[] +commands and also by remote +configuration commands sent by a +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +program running in +another machine. +If this flag is enabled, which is the default +case, new broadcast client and symmetric passive associations and +remote configuration commands must be cryptographically +authenticated using either symmetric key or public key cryptography. +If this +flag is disabled, these operations are effective +even if not cryptographic +authenticated. +It should be understood +that operating with the +\f\*[B-Font]auth\f[] +flag disabled invites a significant vulnerability +where a rogue hacker can +masquerade as a falseticker and seriously +disrupt system timekeeping. +It is +important to note that this flag has no purpose +other than to allow or disallow +a new association in response to new broadcast +and symmetric active messages +and remote configuration commands and, in particular, +the flag has no effect on +the authentication process itself. +.sp \n(Ppu +.ne 2 + +An attractive alternative where multicast support is available +is manycast mode, in which clients periodically troll +for servers as described in the +\fIAutomatic\f[] \fINTP\f[] \fIConfiguration\f[] \fIOptions\f[] +page. +Either symmetric key or public key +cryptographic authentication can be used in this mode. +The principle advantage +of manycast mode is that potential servers need not be +configured in advance, +since the client finds them during regular operation, +and the configuration +files for all clients can be identical. +.sp \n(Ppu +.ne 2 + +The security model and protocol schemes for +both symmetric key and public key +cryptography are summarized below; +further details are in the briefings, papers +and reports at the NTP project page linked from +\f[C]http://www.ntp.org/\f[]. +.SS Symmetric-Key Cryptography +The original RFC-1305 specification allows any one of possibly +65,534 keys, each distinguished by a 32-bit key identifier, to +authenticate an association. +The servers and clients involved must +agree on the key and key identifier to +authenticate NTP packets. +Keys and +related information are specified in a key +file, usually called +\fIntp.keys\f[], +which must be distributed and stored using +secure means beyond the scope of the NTP protocol itself. +Besides the keys used +for ordinary NTP associations, +additional keys can be used as passwords for the +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +utility programs. +.sp \n(Ppu +.ne 2 + +When +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +is first started, it reads the key file specified in the +\f\*[B-Font]keys\f[] +configuration command and installs the keys +in the key cache. +However, +individual keys must be activated with the +\f\*[B-Font]trusted\f[] +command before use. +This +allows, for instance, the installation of possibly +several batches of keys and +then activating or deactivating each batch +remotely using +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[]. +This also provides a revocation capability that can be used +if a key becomes compromised. +The +\f\*[B-Font]requestkey\f[] +command selects the key used as the password for the +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +utility, while the +\f\*[B-Font]controlkey\f[] +command selects the key used as the password for the +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +utility. +.SS Public Key Cryptography +NTPv4 supports the original NTPv3 symmetric key scheme +described in RFC-1305 and in addition the Autokey protocol, +which is based on public key cryptography. +The Autokey Version 2 protocol described on the Autokey Protocol +page verifies packet integrity using MD5 message digests +and verifies the source with digital signatures and any of several +digest/signature schemes. +Optional identity schemes described on the Identity Schemes +page and based on cryptographic challenge/response algorithms +are also available. +Using all of these schemes provides strong security against +replay with or without modification, spoofing, masquerade +and most forms of clogging attacks. +.\" .Pp +.\" The cryptographic means necessary for all Autokey operations +.\" is provided by the OpenSSL software library. +.\" This library is available from http://www.openssl.org/ +.\" and can be installed using the procedures outlined +.\" in the Building and Installing the Distribution page. +.\" Once installed, +.\" the configure and build +.\" process automatically detects the library and links +.\" the library routines required. +.sp \n(Ppu +.ne 2 + +The Autokey protocol has several modes of operation +corresponding to the various NTP modes supported. +Most modes use a special cookie which can be +computed independently by the client and server, +but encrypted in transmission. +All modes use in addition a variant of the S-KEY scheme, +in which a pseudo-random key list is generated and used +in reverse order. +These schemes are described along with an executive summary, +current status, briefing slides and reading list on the +\fIAutonomous\f[] \fIAuthentication\f[] +page. +.sp \n(Ppu +.ne 2 + +The specific cryptographic environment used by Autokey servers +and clients is determined by a set of files +and soft links generated by the +\fCntp-keygen\f[]\fR(1ntpkeygenmdoc)\f[] +program. +This includes a required host key file, +required certificate file and optional sign key file, +leapsecond file and identity scheme files. +The +digest/signature scheme is specified in the X.509 certificate +along with the matching sign key. +There are several schemes +available in the OpenSSL software library, each identified +by a specific string such as +\f\*[B-Font]md5WithRSAEncryption\f[], +which stands for the MD5 message digest with RSA +encryption scheme. +The current NTP distribution supports +all the schemes in the OpenSSL library, including +those based on RSA and DSA digital signatures. +.sp \n(Ppu +.ne 2 + +NTP secure groups can be used to define cryptographic compartments +and security hierarchies. +It is important that every host +in the group be able to construct a certificate trail to one +or more trusted hosts in the same group. +Each group +host runs the Autokey protocol to obtain the certificates +for all hosts along the trail to one or more trusted hosts. +This requires the configuration file in all hosts to be +engineered so that, even under anticipated failure conditions, +the NTP subnet will form such that every group host can find +a trail to at least one trusted host. +.SS Naming and Addressing +It is important to note that Autokey does not use DNS to +resolve addresses, since DNS can't be completely trusted +until the name servers have synchronized clocks. +The cryptographic name used by Autokey to bind the host identity +credentials and cryptographic values must be independent +of interface, network and any other naming convention. +The name appears in the host certificate in either or both +the subject and issuer fields, so protection against +DNS compromise is essential. +.sp \n(Ppu +.ne 2 + +By convention, the name of an Autokey host is the name returned +by the Unix +\fCgethostname\f[]\fR(2)\f[] +system call or equivalent in other systems. +By the system design +model, there are no provisions to allow alternate names or aliases. +However, this is not to say that DNS aliases, different names +for each interface, etc., are constrained in any way. +.sp \n(Ppu +.ne 2 + +It is also important to note that Autokey verifies authenticity +using the host name, network address and public keys, +all of which are bound together by the protocol specifically +to deflect masquerade attacks. +For this reason Autokey +includes the source and destinatino IP addresses in message digest +computations and so the same addresses must be available +at both the server and client. +For this reason operation +with network address translation schemes is not possible. +This reflects the intended robust security model where government +and corporate NTP servers are operated outside firewall perimeters. +.SS Operation +A specific combination of authentication scheme (none, +symmetric key, public key) and identity scheme is called +a cryptotype, although not all combinations are compatible. +There may be management configurations where the clients, +servers and peers may not all support the same cryptotypes. +A secure NTPv4 subnet can be configured in many ways while +keeping in mind the principles explained above and +in this section. +Note however that some cryptotype +combinations may successfully interoperate with each other, +but may not represent good security practice. +.sp \n(Ppu +.ne 2 + +The cryptotype of an association is determined at the time +of mobilization, either at configuration time or some time +later when a message of appropriate cryptotype arrives. +When mobilized by a +\f\*[B-Font]server\f[] +or +\f\*[B-Font]peer\f[] +configuration command and no +\f\*[B-Font]key\f[] +or +\f\*[B-Font]autokey\f[] +subcommands are present, the association is not +authenticated; if the +\f\*[B-Font]key\f[] +subcommand is present, the association is authenticated +using the symmetric key ID specified; if the +\f\*[B-Font]autokey\f[] +subcommand is present, the association is authenticated +using Autokey. +.sp \n(Ppu +.ne 2 + +When multiple identity schemes are supported in the Autokey +protocol, the first message exchange determines which one is used. +The client request message contains bits corresponding +to which schemes it has available. +The server response message +contains bits corresponding to which schemes it has available. +Both server and client match the received bits with their own +and select a common scheme. +.sp \n(Ppu +.ne 2 + +Following the principle that time is a public value, +a server responds to any client packet that matches +its cryptotype capabilities. +Thus, a server receiving +an unauthenticated packet will respond with an unauthenticated +packet, while the same server receiving a packet of a cryptotype +it supports will respond with packets of that cryptotype. +However, unconfigured broadcast or manycast client +associations or symmetric passive associations will not be +mobilized unless the server supports a cryptotype compatible +with the first packet received. +By default, unauthenticated associations will not be mobilized +unless overridden in a decidedly dangerous way. +.sp \n(Ppu +.ne 2 + +Some examples may help to reduce confusion. +Client Alice has no specific cryptotype selected. +Server Bob has both a symmetric key file and minimal Autokey files. +Alice's unauthenticated messages arrive at Bob, who replies with +unauthenticated messages. +Cathy has a copy of Bob's symmetric +key file and has selected key ID 4 in messages to Bob. +Bob verifies the message with his key ID 4. +If it's the +same key and the message is verified, Bob sends Cathy a reply +authenticated with that key. +If verification fails, +Bob sends Cathy a thing called a crypto-NAK, which tells her +something broke. +She can see the evidence using the +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +program. +.sp \n(Ppu +.ne 2 + +Denise has rolled her own host key and certificate. +She also uses one of the identity schemes as Bob. +She sends the first Autokey message to Bob and they +both dance the protocol authentication and identity steps. +If all comes out okay, Denise and Bob continue as described above. +.sp \n(Ppu +.ne 2 + +It should be clear from the above that Bob can support +all the girls at the same time, as long as he has compatible +authentication and identity credentials. +Now, Bob can act just like the girls in his own choice of servers; +he can run multiple configured associations with multiple different +servers (or the same server, although that might not be useful). +But, wise security policy might preclude some cryptotype +combinations; for instance, running an identity scheme +with one server and no authentication with another might not be wise. +.SS Key Management +The cryptographic values used by the Autokey protocol are +incorporated as a set of files generated by the +\fCntp-keygen\f[]\fR(1ntpkeygenmdoc)\f[] +utility program, including symmetric key, host key and +public certificate files, as well as sign key, identity parameters +and leapseconds files. +Alternatively, host and sign keys and +certificate files can be generated by the OpenSSL utilities +and certificates can be imported from public certificate +authorities. +Note that symmetric keys are necessary for the +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +utility programs. +The remaining files are necessary only for the +Autokey protocol. +.sp \n(Ppu +.ne 2 + +Certificates imported from OpenSSL or public certificate +authorities have certian limitations. +The certificate should be in ASN.1 syntax, X.509 Version 3 +format and encoded in PEM, which is the same format +used by OpenSSL. +The overall length of the certificate encoded +in ASN.1 must not exceed 1024 bytes. +The subject distinguished +name field (CN) is the fully qualified name of the host +on which it is used; the remaining subject fields are ignored. +The certificate extension fields must not contain either +a subject key identifier or a issuer key identifier field; +however, an extended key usage field for a trusted host must +contain the value +\f\*[B-Font]trustRoot\f[];. +Other extension fields are ignored. +.SS Authentication Commands +.TP 7 +.NOP \f\*[B-Font]autokey\f[] [\f\*[I-Font]logsec\f[]] +Specifies the interval between regenerations of the session key +list used with the Autokey protocol. +Note that the size of the key +list for each association depends on this interval and the current +poll interval. +The default value is 12 (4096 s or about 1.1 hours). +For poll intervals above the specified interval, a session key list +with a single entry will be regenerated for every message +sent. +.TP 7 +.NOP \f\*[B-Font]controlkey\f[] \f\*[I-Font]key\f[] +Specifies the key identifier to use with the +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +utility, which uses the standard +protocol defined in RFC-1305. +The +\f\*[I-Font]key\f[] +argument is +the key identifier for a trusted key, where the value can be in the +range 1 to 65,534, inclusive. +.TP 7 +.NOP \f\*[B-Font]crypto\f[] [\f\*[B-Font]cert\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]leap\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]randfile\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]host\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]sign\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]gq\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]gqpar\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]iffpar\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]mvpar\f[] \f\*[I-Font]file\f[]] [\f\*[B-Font]pw\f[] \f\*[I-Font]password\f[]] +This command requires the OpenSSL library. +It activates public key +cryptography, selects the message digest and signature +encryption scheme and loads the required private and public +values described above. +If one or more files are left unspecified, +the default names are used as described above. +Unless the complete path and name of the file are specified, the +location of a file is relative to the keys directory specified +in the +\f\*[B-Font]keysdir\f[] +command or default +\fI/usr/local/etc\f[]. +Following are the subcommands: +.RS +.TP 7 +.NOP \f\*[B-Font]cert\f[] \f\*[I-Font]file\f[] +Specifies the location of the required host public certificate file. +This overrides the link +\fIntpkey_cert_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]gqpar\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional GQ parameters file. +This +overrides the link +\fIntpkey_gq_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]host\f[] \f\*[I-Font]file\f[] +Specifies the location of the required host key file. +This overrides +the link +\fIntpkey_key_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]iffpar\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional IFF parameters file.This +overrides the link +\fIntpkey_iff_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]leap\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional leapsecond file. +This overrides the link +\fIntpkey_leap\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]mvpar\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional MV parameters file. +This +overrides the link +\fIntpkey_mv_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +.TP 7 +.NOP \f\*[B-Font]pw\f[] \f\*[I-Font]password\f[] +Specifies the password to decrypt files containing private keys and +identity parameters. +This is required only if these files have been +encrypted. +.TP 7 +.NOP \f\*[B-Font]randfile\f[] \f\*[I-Font]file\f[] +Specifies the location of the random seed file used by the OpenSSL +library. +The defaults are described in the main text above. +.TP 7 +.NOP \f\*[B-Font]sign\f[] \f\*[I-Font]file\f[] +Specifies the location of the optional sign key file. +This overrides +the link +\fIntpkey_sign_\f[]\f\*[I-Font]hostname\f[] +in the keys directory. +If this file is +not found, the host key is also the sign key. +.RE +.TP 7 +.NOP \f\*[B-Font]keys\f[] \f\*[I-Font]keyfile\f[] +Specifies the complete path and location of the MD5 key file +containing the keys and key identifiers used by +\fCntpd\f[]\fR(@NTPD_MS@)\f[], +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +when operating with symmetric key cryptography. +This is the same operation as the +\f\*[B-Font]\-k\f[] +command line option. +.TP 7 +.NOP \f\*[B-Font]keysdir\f[] \f\*[I-Font]path\f[] +This command specifies the default directory path for +cryptographic keys, parameters and certificates. +The default is +\fI/usr/local/etc/\f[]. +.TP 7 +.NOP \f\*[B-Font]requestkey\f[] \f\*[I-Font]key\f[] +Specifies the key identifier to use with the +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +utility program, which uses a +proprietary protocol specific to this implementation of +\fCntpd\f[]\fR(@NTPD_MS@)\f[]. +The +\f\*[I-Font]key\f[] +argument is a key identifier +for the trusted key, where the value can be in the range 1 to +65,534, inclusive. +.TP 7 +.NOP \f\*[B-Font]revoke\f[] \f\*[I-Font]logsec\f[] +Specifies the interval between re-randomization of certain +cryptographic values used by the Autokey scheme, as a power of 2 in +seconds. +These values need to be updated frequently in order to +deflect brute-force attacks on the algorithms of the scheme; +however, updating some values is a relatively expensive operation. +The default interval is 16 (65,536 s or about 18 hours). +For poll +intervals above the specified interval, the values will be updated +for every message sent. +.TP 7 +.NOP \f\*[B-Font]trustedkey\f[] \f\*[I-Font]key\f[] \f\*[I-Font]...\f[] +Specifies the key identifiers which are trusted for the +purposes of authenticating peers with symmetric key cryptography, +as well as keys used by the +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +programs. +The authentication procedures require that both the local +and remote servers share the same key and key identifier for this +purpose, although different keys can be used with different +servers. +The +\f\*[I-Font]key\f[] +arguments are 32-bit unsigned +integers with values from 1 to 65,534. +.PP +.SS Error Codes +The following error codes are reported via the NTP control +and monitoring protocol trap mechanism. +.TP 7 +.NOP 101 +(bad field format or length) +The packet has invalid version, length or format. +.TP 7 +.NOP 102 +(bad timestamp) +The packet timestamp is the same or older than the most recent received. +This could be due to a replay or a server clock time step. +.TP 7 +.NOP 103 +(bad filestamp) +The packet filestamp is the same or older than the most recent received. +This could be due to a replay or a key file generation error. +.TP 7 +.NOP 104 +(bad or missing public key) +The public key is missing, has incorrect format or is an unsupported type. +.TP 7 +.NOP 105 +(unsupported digest type) +The server requires an unsupported digest/signature scheme. +.TP 7 +.NOP 106 +(mismatched digest types) +Not used. +.TP 7 +.NOP 107 +(bad signature length) +The signature length does not match the current public key. +.TP 7 +.NOP 108 +(signature not verified) +The message fails the signature check. +It could be bogus or signed by a +different private key. +.TP 7 +.NOP 109 +(certificate not verified) +The certificate is invalid or signed with the wrong key. +.TP 7 +.NOP 110 +(certificate not verified) +The certificate is not yet valid or has expired or the signature could not +be verified. +.TP 7 +.NOP 111 +(bad or missing cookie) +The cookie is missing, corrupted or bogus. +.TP 7 +.NOP 112 +(bad or missing leapseconds table) +The leapseconds table is missing, corrupted or bogus. +.TP 7 +.NOP 113 +(bad or missing certificate) +The certificate is missing, corrupted or bogus. +.TP 7 +.NOP 114 +(bad or missing identity) +The identity key is missing, corrupt or bogus. +.PP +.SH Monitoring Support +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +includes a comprehensive monitoring facility suitable +for continuous, long term recording of server and client +timekeeping performance. +See the +\f\*[B-Font]statistics\f[] +command below +for a listing and example of each type of statistics currently +supported. +Statistic files are managed using file generation sets +and scripts in the +\fI./scripts\f[] +directory of this distribution. +Using +these facilities and +UNIX +\fCcron\f[]\fR(8)\f[] +jobs, the data can be +automatically summarized and archived for retrospective analysis. +.SS Monitoring Commands +.TP 7 +.NOP \f\*[B-Font]statistics\f[] \f\*[I-Font]name\f[] \f\*[I-Font]...\f[] +Enables writing of statistics records. +Currently, eight kinds of +\f\*[I-Font]name\f[] +statistics are supported. +.RS +.TP 7 +.NOP \f\*[B-Font]clockstats\f[] +Enables recording of clock driver statistics information. +Each update +received from a clock driver appends a line of the following form to +the file generation set named +\f\*[B-Font]clockstats\f[]: +.br +.in +4 +.nf +49213 525.624 127.127.4.1 93 226 00:08:29.606 D +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the +clock address in dotted-quad notation. +The final field shows the last +timecode received from the clock in decoded ASCII format, where +meaningful. +In some clock drivers a good deal of additional information +can be gathered and displayed as well. +See information specific to each +clock for further details. +.TP 7 +.NOP \f\*[B-Font]cryptostats\f[] +This option requires the OpenSSL cryptographic software library. +It +enables recording of cryptographic public key protocol information. +Each message received by the protocol module appends a line of the +following form to the file generation set named +\f\*[B-Font]cryptostats\f[]: +.br +.in +4 +.nf +49213 525.624 127.127.4.1 message +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the peer +address in dotted-quad notation, The final message field includes the +message type and certain ancillary information. +See the +\fIAuthentication\f[] \fIOptions\f[] +section for further information. +.TP 7 +.NOP \f\*[B-Font]loopstats\f[] +Enables recording of loop filter statistics information. +Each +update of the local clock outputs a line of the following form to +the file generation set named +\f\*[B-Font]loopstats\f[]: +.br +.in +4 +.nf +50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next five fields +show time offset (seconds), frequency offset (parts per million \- +PPM), RMS jitter (seconds), Allan deviation (PPM) and clock +discipline time constant. +.TP 7 +.NOP \f\*[B-Font]peerstats\f[] +Enables recording of peer statistics information. +This includes +statistics records of all peers of a NTP server and of special +signals, where present and configured. +Each valid update appends a +line of the following form to the current element of a file +generation set named +\f\*[B-Font]peerstats\f[]: +.br +.in +4 +.nf +48773 10847.650 127.127.4.1 9714 \-0.001605376 0.000000000 0.001424877 0.000958674 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the peer address in dotted-quad notation and status, +respectively. +The status field is encoded in hex in the format +described in Appendix A of the NTP specification RFC 1305. +The final four fields show the offset, +delay, dispersion and RMS jitter, all in seconds. +.TP 7 +.NOP \f\*[B-Font]rawstats\f[] +Enables recording of raw-timestamp statistics information. +This +includes statistics records of all peers of a NTP server and of +special signals, where present and configured. +Each NTP message +received from a peer or clock driver appends a line of the +following form to the file generation set named +\f\*[B-Font]rawstats\f[]: +.br +.in +4 +.nf +50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the remote peer or clock address followed by the local address +in dotted-quad notation. +The final four fields show the originate, +receive, transmit and final NTP timestamps in order. +The timestamp +values are as received and before processing by the various data +smoothing and mitigation algorithms. +.TP 7 +.NOP \f\*[B-Font]sysstats\f[] +Enables recording of ntpd statistics counters on a periodic basis. +Each +hour a line of the following form is appended to the file generation +set named +\f\*[B-Font]sysstats\f[]: +.br +.in +4 +.nf +50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The remaining ten fields show +the statistics counter values accumulated since the last generated +line. +.RS +.TP 7 +.NOP Time since restart \f\*[B-Font]36000\f[] +Time in hours since the system was last rebooted. +.TP 7 +.NOP Packets received \f\*[B-Font]81965\f[] +Total number of packets received. +.TP 7 +.NOP Packets processed \f\*[B-Font]0\f[] +Number of packets received in response to previous packets sent +.TP 7 +.NOP Current version \f\*[B-Font]9546\f[] +Number of packets matching the current NTP version. +.TP 7 +.NOP Previous version \f\*[B-Font]56\f[] +Number of packets matching the previous NTP version. +.TP 7 +.NOP Bad version \f\*[B-Font]71793\f[] +Number of packets matching neither NTP version. +.TP 7 +.NOP Access denied \f\*[B-Font]512\f[] +Number of packets denied access for any reason. +.TP 7 +.NOP Bad length or format \f\*[B-Font]540\f[] +Number of packets with invalid length, format or port number. +.TP 7 +.NOP Bad authentication \f\*[B-Font]10\f[] +Number of packets not verified as authentic. +.TP 7 +.NOP Rate exceeded \f\*[B-Font]147\f[] +Number of packets discarded due to rate limitation. +.RE +.TP 7 +.NOP \f\*[B-Font]statsdir\f[] \f\*[I-Font]directory_path\f[] +Indicates the full path of a directory where statistics files +should be created (see below). +This keyword allows +the (otherwise constant) +\f\*[B-Font]filegen\f[] +filename prefix to be modified for file generation sets, which +is useful for handling statistics logs. +.TP 7 +.NOP \f\*[B-Font]filegen\f[] \f\*[I-Font]name\f[] [\f\*[B-Font]file\f[] \f\*[I-Font]filename\f[]] [\f\*[B-Font]type\f[] \f\*[I-Font]typename\f[]] [\f\*[B-Font]link\f[] | \f\*[B-Font]nolink\f[]] [\f\*[B-Font]enable\f[] | \f\*[B-Font]disable\f[]] +Configures setting of generation file set name. +Generation +file sets provide a means for handling files that are +continuously growing during the lifetime of a server. +Server statistics are a typical example for such files. +Generation file sets provide access to a set of files used +to store the actual data. +At any time at most one element +of the set is being written to. +The type given specifies +when and how data will be directed to a new element of the set. +This way, information stored in elements of a file set +that are currently unused are available for administrational +operations without the risk of disturbing the operation of ntpd. +(Most important: they can be removed to free space for new data +produced.) +.sp \n(Ppu +.ne 2 + +Note that this command can be sent from the +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +program running at a remote location. +.RS +.TP 7 +.NOP \f\*[B-Font]name\f[] +This is the type of the statistics records, as shown in the +\f\*[B-Font]statistics\f[] +command. +.TP 7 +.NOP \f\*[B-Font]file\f[] \f\*[I-Font]filename\f[] +This is the file name for the statistics records. +Filenames of set +members are built from three concatenated elements +\f\*[B-Font]prefix\f[], +\f\*[B-Font]filename\f[] +and +\f\*[B-Font]suffix\f[]: +.RS +.TP 7 +.NOP \f\*[B-Font]prefix\f[] +This is a constant filename path. +It is not subject to +modifications via the +\f\*[I-Font]filegen\f[] +option. +It is defined by the +server, usually specified as a compile-time constant. +It may, +however, be configurable for individual file generation sets +via other commands. +For example, the prefix used with +\f\*[I-Font]loopstats\f[] +and +\f\*[I-Font]peerstats\f[] +generation can be configured using the +\f\*[I-Font]statsdir\f[] +option explained above. +.TP 7 +.NOP \f\*[B-Font]filename\f[] +This string is directly concatenated to the prefix mentioned +above (no intervening +\[oq]/\[cq]). +This can be modified using +the file argument to the +\f\*[I-Font]filegen\f[] +statement. +No +\fI..\f[] +elements are +allowed in this component to prevent filenames referring to +parts outside the filesystem hierarchy denoted by +\f\*[I-Font]prefix\f[]. +.TP 7 +.NOP \f\*[B-Font]suffix\f[] +This part is reflects individual elements of a file set. +It is +generated according to the type of a file set. +.RE +.TP 7 +.NOP \f\*[B-Font]type\f[] \f\*[I-Font]typename\f[] +A file generation set is characterized by its type. +The following +types are supported: +.RS +.TP 7 +.NOP \f\*[B-Font]none\f[] +The file set is actually a single plain file. +.TP 7 +.NOP \f\*[B-Font]pid\f[] +One element of file set is used per incarnation of a ntpd +server. +This type does not perform any changes to file set +members during runtime, however it provides an easy way of +separating files belonging to different +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +server incarnations. +The set member filename is built by appending a +\[oq]\&.\[cq] +to concatenated +\f\*[I-Font]prefix\f[] +and +\f\*[I-Font]filename\f[] +strings, and +appending the decimal representation of the process ID of the +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +server process. +.TP 7 +.NOP \f\*[B-Font]day\f[] +One file generation set element is created per day. +A day is +defined as the period between 00:00 and 24:00 UTC. +The file set +member suffix consists of a +\[oq]\&.\[cq] +and a day specification in +the form +\f\*[B-Font]YYYYMMdd\f[]. +\f\*[B-Font]YYYY\f[] +is a 4-digit year number (e.g., 1992). +\f\*[B-Font]MM\f[] +is a two digit month number. +\f\*[B-Font]dd\f[] +is a two digit day number. +Thus, all information written at 10 December 1992 would end up +in a file named +\f\*[I-Font]prefix\f[] +\f\*[I-Font]filename\f[].19921210. +.TP 7 +.NOP \f\*[B-Font]week\f[] +Any file set member contains data related to a certain week of +a year. +The term week is defined by computing day-of-year +modulo 7. +Elements of such a file generation set are +distinguished by appending the following suffix to the file set +filename base: A dot, a 4-digit year number, the letter +\f\*[B-Font]W\f[], +and a 2-digit week number. +For example, information from January, +10th 1992 would end up in a file with suffix +.NOP. \f\*[I-Font]1992W1\f[]. +.TP 7 +.NOP \f\*[B-Font]month\f[] +One generation file set element is generated per month. +The +file name suffix consists of a dot, a 4-digit year number, and +a 2-digit month. +.TP 7 +.NOP \f\*[B-Font]year\f[] +One generation file element is generated per year. +The filename +suffix consists of a dot and a 4 digit year number. +.TP 7 +.NOP \f\*[B-Font]age\f[] +This type of file generation sets changes to a new element of +the file set every 24 hours of server operation. +The filename +suffix consists of a dot, the letter +\f\*[B-Font]a\f[], +and an 8-digit number. +This number is taken to be the number of seconds the server is +running at the start of the corresponding 24-hour period. +Information is only written to a file generation by specifying +\f\*[B-Font]enable\f[]; +output is prevented by specifying +\f\*[B-Font]disable\f[]. +.RE +.TP 7 +.NOP \f\*[B-Font]link\f[] | \f\*[B-Font]nolink\f[] +It is convenient to be able to access the current element of a file +generation set by a fixed name. +This feature is enabled by +specifying +\f\*[B-Font]link\f[] +and disabled using +\f\*[B-Font]nolink\f[]. +If link is specified, a +hard link from the current file set element to a file without +suffix is created. +When there is already a file with this name and +the number of links of this file is one, it is renamed appending a +dot, the letter +\f\*[B-Font]C\f[], +and the pid of the ntpd server process. +When the +number of links is greater than one, the file is unlinked. +This +allows the current file to be accessed by a constant name. +.TP 7 +.NOP \f\*[B-Font]enable\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]disable\f[] +Enables or disables the recording function. +.RE +.RE +.PP +.SH Access Control Support +The +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +daemon implements a general purpose address/mask based restriction +list. +The list contains address/match entries sorted first +by increasing address values and and then by increasing mask values. +A match occurs when the bitwise AND of the mask and the packet +source address is equal to the bitwise AND of the mask and +address in the list. +The list is searched in order with the +last match found defining the restriction flags associated +with the entry. +Additional information and examples can be found in the +"Notes on Configuring NTP and Setting up a NTP Subnet" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.sp \n(Ppu +.ne 2 + +The restriction facility was implemented in conformance +with the access policies for the original NSFnet backbone +time servers. +Later the facility was expanded to deflect +cryptographic and clogging attacks. +While this facility may +be useful for keeping unwanted or broken or malicious clients +from congesting innocent servers, it should not be considered +an alternative to the NTP authentication facilities. +Source address based restrictions are easily circumvented +by a determined cracker. +.sp \n(Ppu +.ne 2 + +Clients can be denied service because they are explicitly +included in the restrict list created by the restrict command +or implicitly as the result of cryptographic or rate limit +violations. +Cryptographic violations include certificate +or identity verification failure; rate limit violations generally +result from defective NTP implementations that send packets +at abusive rates. +Some violations cause denied service +only for the offending packet, others cause denied service +for a timed period and others cause the denied service for +an indefinate period. +When a client or network is denied access +for an indefinate period, the only way at present to remove +the restrictions is by restarting the server. +.SS The Kiss-of-Death Packet +Ordinarily, packets denied service are simply dropped with no +further action except incrementing statistics counters. +Sometimes a +more proactive response is needed, such as a server message that +explicitly requests the client to stop sending and leave a message +for the system operator. +A special packet format has been created +for this purpose called the "kiss-of-death" (KoD) packet. +KoD packets have the leap bits set unsynchronized and stratum set +to zero and the reference identifier field set to a four-byte +ASCII code. +If the +\f\*[B-Font]noserve\f[] +or +\f\*[B-Font]notrust\f[] +flag of the matching restrict list entry is set, +the code is "DENY"; if the +\f\*[B-Font]limited\f[] +flag is set and the rate limit +is exceeded, the code is "RATE". +Finally, if a cryptographic violation occurs, the code is "CRYP". +.sp \n(Ppu +.ne 2 + +A client receiving a KoD performs a set of sanity checks to +minimize security exposure, then updates the stratum and +reference identifier peer variables, sets the access +denied (TEST4) bit in the peer flash variable and sends +a message to the log. +As long as the TEST4 bit is set, +the client will send no further packets to the server. +The only way at present to recover from this condition is +to restart the protocol at both the client and server. +This +happens automatically at the client when the association times out. +It will happen at the server only if the server operator cooperates. +.SS Access Control Commands +.TP 7 +.NOP \f\*[B-Font]discard\f[] [\f\*[B-Font]average\f[] \f\*[I-Font]avg\f[]] [\f\*[B-Font]minimum\f[] \f\*[I-Font]min\f[]] [\f\*[B-Font]monitor\f[] \f\*[I-Font]prob\f[]] +Set the parameters of the +\f\*[B-Font]limited\f[] +facility which protects the server from +client abuse. +The +\f\*[B-Font]average\f[] +subcommand specifies the minimum average packet +spacing, while the +\f\*[B-Font]minimum\f[] +subcommand specifies the minimum packet spacing. +Packets that violate these minima are discarded +and a kiss-o'-death packet returned if enabled. +The default +minimum average and minimum are 5 and 2, respectively. +The monitor subcommand specifies the probability of discard +for packets that overflow the rate-control window. +.TP 7 +.NOP \f\*[B-Font]restrict\f[] \f\*[B-Font]address\f[] [\f\*[B-Font]mask\f[] \f\*[I-Font]mask\f[]] [\f\*[I-Font]flag\f[] \f\*[I-Font]...\f[]] +The +\f\*[I-Font]address\f[] +argument expressed in +dotted-quad form is the address of a host or network. +Alternatively, the +\f\*[I-Font]address\f[] +argument can be a valid host DNS name. +The +\f\*[I-Font]mask\f[] +argument expressed in dotted-quad form defaults to +\f\*[B-Font]255.255.255.255\f[], +meaning that the +\f\*[I-Font]address\f[] +is treated as the address of an individual host. +A default entry (address +\f\*[B-Font]0.0.0.0\f[], +mask +\f\*[B-Font]0.0.0.0\f[]) +is always included and is always the first entry in the list. +Note that text string +\f\*[B-Font]default\f[], +with no mask option, may +be used to indicate the default entry. +In the current implementation, +\f\*[B-Font]flag\f[] +always +restricts access, i.e., an entry with no flags indicates that free +access to the server is to be given. +The flags are not orthogonal, +in that more restrictive flags will often make less restrictive +ones redundant. +The flags can generally be classed into two +categories, those which restrict time service and those which +restrict informational queries and attempts to do run-time +reconfiguration of the server. +One or more of the following flags +may be specified: +.RS +.TP 7 +.NOP \f\*[B-Font]ignore\f[] +Deny packets of all kinds, including +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +queries. +.TP 7 +.NOP \f\*[B-Font]kod\f[] +If this flag is set when an access violation occurs, a kiss-o'-death +(KoD) packet is sent. +KoD packets are rate limited to no more than one +per second. +If another KoD packet occurs within one second after the +last one, the packet is dropped. +.TP 7 +.NOP \f\*[B-Font]limited\f[] +Deny service if the packet spacing violates the lower limits specified +in the discard command. +A history of clients is kept using the +monitoring capability of +\fCntpd\f[]\fR(@NTPD_MS@)\f[]. +Thus, monitoring is always active as +long as there is a restriction entry with the +\f\*[B-Font]limited\f[] +flag. +.TP 7 +.NOP \f\*[B-Font]lowpriotrap\f[] +Declare traps set by matching hosts to be low priority. +The +number of traps a server can maintain is limited (the current limit +is 3). +Traps are usually assigned on a first come, first served +basis, with later trap requestors being denied service. +This flag +modifies the assignment algorithm by allowing low priority traps to +be overridden by later requests for normal priority traps. +.TP 7 +.NOP \f\*[B-Font]nomodify\f[] +Deny +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +queries which attempt to modify the state of the +server (i.e., run time reconfiguration). +Queries which return +information are permitted. +.TP 7 +.NOP \f\*[B-Font]noquery\f[] +Deny +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +queries. +Time service is not affected. +.TP 7 +.NOP \f\*[B-Font]nopeer\f[] +Deny packets which would result in mobilizing a new association. +This +includes broadcast and symmetric active packets when a configured +association does not exist. +It also includes +\f\*[B-Font]pool\f[] +associations, so if you want to use servers from a +\f\*[B-Font]pool\f[] +directive and also want to use +\f\*[B-Font]nopeer\f[] +by default, you'll want a +\f\*[B-Font]restrict source ...\f[] \f\*[B-Font]line\f[] \f\*[B-Font]as\f[] \f\*[B-Font]well\f[] \f\*[B-Font]that\f[] \f\*[B-Font]does\f[] +.TP 7 +.NOP not +include the +\f\*[B-Font]nopeer\f[] +directive. +.TP 7 +.NOP \f\*[B-Font]noserve\f[] +Deny all packets except +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +queries. +.TP 7 +.NOP \f\*[B-Font]notrap\f[] +Decline to provide mode 6 control message trap service to matching +hosts. +The trap service is a subsystem of the ntpdq control message +protocol which is intended for use by remote event logging programs. +.TP 7 +.NOP \f\*[B-Font]notrust\f[] +Deny service unless the packet is cryptographically authenticated. +.TP 7 +.NOP \f\*[B-Font]ntpport\f[] +This is actually a match algorithm modifier, rather than a +restriction flag. +Its presence causes the restriction entry to be +matched only if the source port in the packet is the standard NTP +UDP port (123). +Both +\f\*[B-Font]ntpport\f[] +and +\f\*[B-Font]non-ntpport\f[] +may +be specified. +The +\f\*[B-Font]ntpport\f[] +is considered more specific and +is sorted later in the list. +.TP 7 +.NOP \f\*[B-Font]version\f[] +Deny packets that do not match the current NTP version. +.RE +.sp \n(Ppu +.ne 2 + +Default restriction list entries with the flags ignore, interface, +ntpport, for each of the local host's interface addresses are +inserted into the table at startup to prevent the server +from attempting to synchronize to its own time. +A default entry is also always present, though if it is +otherwise unconfigured; no flags are associated +with the default entry (i.e., everything besides your own +NTP server is unrestricted). +.PP +.SH Automatic NTP Configuration Options +.SS Manycasting +Manycasting is a automatic discovery and configuration paradigm +new to NTPv4. +It is intended as a means for a multicast client +to troll the nearby network neighborhood to find cooperating +manycast servers, validate them using cryptographic means +and evaluate their time values with respect to other servers +that might be lurking in the vicinity. +The intended result is that each manycast client mobilizes +client associations with some number of the "best" +of the nearby manycast servers, yet automatically reconfigures +to sustain this number of servers should one or another fail. +.sp \n(Ppu +.ne 2 + +Note that the manycasting paradigm does not coincide +with the anycast paradigm described in RFC-1546, +which is designed to find a single server from a clique +of servers providing the same service. +The manycast paradigm is designed to find a plurality +of redundant servers satisfying defined optimality criteria. +.sp \n(Ppu +.ne 2 + +Manycasting can be used with either symmetric key +or public key cryptography. +The public key infrastructure (PKI) +offers the best protection against compromised keys +and is generally considered stronger, at least with relatively +large key sizes. +It is implemented using the Autokey protocol and +the OpenSSL cryptographic library available from +\f[C]http://www.openssl.org/\f[]. +The library can also be used with other NTPv4 modes +as well and is highly recommended, especially for broadcast modes. +.sp \n(Ppu +.ne 2 + +A persistent manycast client association is configured +using the manycastclient command, which is similar to the +server command but with a multicast (IPv4 class +\f\*[B-Font]D\f[] +or IPv6 prefix +\f\*[B-Font]FF\f[]) +group address. +The IANA has designated IPv4 address 224.1.1.1 +and IPv6 address FF05::101 (site local) for NTP. +When more servers are needed, it broadcasts manycast +client messages to this address at the minimum feasible rate +and minimum feasible time-to-live (TTL) hops, depending +on how many servers have already been found. +There can be as many manycast client associations +as different group address, each one serving as a template +for a future ephemeral unicast client/server association. +.sp \n(Ppu +.ne 2 + +Manycast servers configured with the +\f\*[B-Font]manycastserver\f[] +command listen on the specified group address for manycast +client messages. +Note the distinction between manycast client, +which actively broadcasts messages, and manycast server, +which passively responds to them. +If a manycast server is +in scope of the current TTL and is itself synchronized +to a valid source and operating at a stratum level equal +to or lower than the manycast client, it replies to the +manycast client message with an ordinary unicast server message. +.sp \n(Ppu +.ne 2 + +The manycast client receiving this message mobilizes +an ephemeral client/server association according to the +matching manycast client template, but only if cryptographically +authenticated and the server stratum is less than or equal +to the client stratum. +Authentication is explicitly required +and either symmetric key or public key (Autokey) can be used. +Then, the client polls the server at its unicast address +in burst mode in order to reliably set the host clock +and validate the source. +This normally results +in a volley of eight client/server at 2-s intervals +during which both the synchronization and cryptographic +protocols run concurrently. +Following the volley, +the client runs the NTP intersection and clustering +algorithms, which act to discard all but the "best" +associations according to stratum and synchronization +distance. +The surviving associations then continue +in ordinary client/server mode. +.sp \n(Ppu +.ne 2 + +The manycast client polling strategy is designed to reduce +as much as possible the volume of manycast client messages +and the effects of implosion due to near-simultaneous +arrival of manycast server messages. +The strategy is determined by the +\f\*[B-Font]manycastclient\f[], +\f\*[B-Font]tos\f[] +and +\f\*[B-Font]ttl\f[] +configuration commands. +The manycast poll interval is +normally eight times the system poll interval, +which starts out at the +\f\*[B-Font]minpoll\f[] +value specified in the +\f\*[B-Font]manycastclient\f[], +command and, under normal circumstances, increments to the +\f\*[B-Font]maxpolll\f[] +value specified in this command. +Initially, the TTL is +set at the minimum hops specified by the ttl command. +At each retransmission the TTL is increased until reaching +the maximum hops specified by this command or a sufficient +number client associations have been found. +Further retransmissions use the same TTL. +.sp \n(Ppu +.ne 2 + +The quality and reliability of the suite of associations +discovered by the manycast client is determined by the NTP +mitigation algorithms and the +\f\*[B-Font]minclock\f[] +and +\f\*[B-Font]minsane\f[] +values specified in the +\f\*[B-Font]tos\f[] +configuration command. +At least +\f\*[B-Font]minsane\f[] +candidate servers must be available and the mitigation +algorithms produce at least +\f\*[B-Font]minclock\f[] +survivors in order to synchronize the clock. +Byzantine agreement principles require at least four +candidates in order to correctly discard a single falseticker. +For legacy purposes, +\f\*[B-Font]minsane\f[] +defaults to 1 and +\f\*[B-Font]minclock\f[] +defaults to 3. +For manycast service +\f\*[B-Font]minsane\f[] +should be explicitly set to 4, assuming at least that +number of servers are available. +.sp \n(Ppu +.ne 2 + +If at least +\f\*[B-Font]minclock\f[] +servers are found, the manycast poll interval is immediately +set to eight times +\f\*[B-Font]maxpoll\f[]. +If less than +\f\*[B-Font]minclock\f[] +servers are found when the TTL has reached the maximum hops, +the manycast poll interval is doubled. +For each transmission +after that, the poll interval is doubled again until +reaching the maximum of eight times +\f\*[B-Font]maxpoll\f[]. +Further transmissions use the same poll interval and +TTL values. +Note that while all this is going on, +each client/server association found is operating normally +it the system poll interval. +.sp \n(Ppu +.ne 2 + +Administratively scoped multicast boundaries are normally +specified by the network router configuration and, +in the case of IPv6, the link/site scope prefix. +By default, the increment for TTL hops is 32 starting +from 31; however, the +\f\*[B-Font]ttl\f[] +configuration command can be +used to modify the values to match the scope rules. +.sp \n(Ppu +.ne 2 + +It is often useful to narrow the range of acceptable +servers which can be found by manycast client associations. +Because manycast servers respond only when the client +stratum is equal to or greater than the server stratum, +primary (stratum 1) servers fill find only primary servers +in TTL range, which is probably the most common objective. +However, unless configured otherwise, all manycast clients +in TTL range will eventually find all primary servers +in TTL range, which is probably not the most common +objective in large networks. +The +\f\*[B-Font]tos\f[] +command can be used to modify this behavior. +Servers with stratum below +\f\*[B-Font]floor\f[] +or above +\f\*[B-Font]ceiling\f[] +specified in the +\f\*[B-Font]tos\f[] +command are strongly discouraged during the selection +process; however, these servers may be temporally +accepted if the number of servers within TTL range is +less than +\f\*[B-Font]minclock\f[]. +.sp \n(Ppu +.ne 2 + +The above actions occur for each manycast client message, +which repeats at the designated poll interval. +However, once the ephemeral client association is mobilized, +subsequent manycast server replies are discarded, +since that would result in a duplicate association. +If during a poll interval the number of client associations +falls below +\f\*[B-Font]minclock\f[], +all manycast client prototype associations are reset +to the initial poll interval and TTL hops and operation +resumes from the beginning. +It is important to avoid +frequent manycast client messages, since each one requires +all manycast servers in TTL range to respond. +The result could well be an implosion, either minor or major, +depending on the number of servers in range. +The recommended value for +\f\*[B-Font]maxpoll\f[] +is 12 (4,096 s). +.sp \n(Ppu +.ne 2 + +It is possible and frequently useful to configure a host +as both manycast client and manycast server. +A number of hosts configured this way and sharing a common +group address will automatically organize themselves +in an optimum configuration based on stratum and +synchronization distance. +For example, consider an NTP +subnet of two primary servers and a hundred or more +dependent clients. +With two exceptions, all servers +and clients have identical configuration files including both +\f\*[B-Font]multicastclient\f[] +and +\f\*[B-Font]multicastserver\f[] +commands using, for instance, multicast group address +239.1.1.1. +The only exception is that each primary server +configuration file must include commands for the primary +reference source such as a GPS receiver. +.sp \n(Ppu +.ne 2 + +The remaining configuration files for all secondary +servers and clients have the same contents, except for the +\f\*[B-Font]tos\f[] +command, which is specific for each stratum level. +For stratum 1 and stratum 2 servers, that command is +not necessary. +For stratum 3 and above servers the +\f\*[B-Font]floor\f[] +value is set to the intended stratum number. +Thus, all stratum 3 configuration files are identical, +all stratum 4 files are identical and so forth. +.sp \n(Ppu +.ne 2 + +Once operations have stabilized in this scenario, +the primary servers will find the primary reference source +and each other, since they both operate at the same +stratum (1), but not with any secondary server or client, +since these operate at a higher stratum. +The secondary +servers will find the servers at the same stratum level. +If one of the primary servers loses its GPS receiver, +it will continue to operate as a client and other clients +will time out the corresponding association and +re-associate accordingly. +.sp \n(Ppu +.ne 2 + +Some administrators prefer to avoid running +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +continuously and run either +\fCsntp\f[]\fR(@SNTP_MS@)\f[] +or +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +\f\*[B-Font]\-q\f[] +as a cron job. +In either case the servers must be +configured in advance and the program fails if none are +available when the cron job runs. +A really slick +application of manycast is with +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +\f\*[B-Font]\-q\f[]. +The program wakes up, scans the local landscape looking +for the usual suspects, selects the best from among +the rascals, sets the clock and then departs. +Servers do not have to be configured in advance and +all clients throughout the network can have the same +configuration file. +.SS Manycast Interactions with Autokey +Each time a manycast client sends a client mode packet +to a multicast group address, all manycast servers +in scope generate a reply including the host name +and status word. +The manycast clients then run +the Autokey protocol, which collects and verifies +all certificates involved. +Following the burst interval +all but three survivors are cast off, +but the certificates remain in the local cache. +It often happens that several complete signing trails +from the client to the primary servers are collected in this way. +.sp \n(Ppu +.ne 2 + +About once an hour or less often if the poll interval +exceeds this, the client regenerates the Autokey key list. +This is in general transparent in client/server mode. +However, about once per day the server private value +used to generate cookies is refreshed along with all +manycast client associations. +In this case all +cryptographic values including certificates is refreshed. +If a new certificate has been generated since +the last refresh epoch, it will automatically revoke +all prior certificates that happen to be in the +certificate cache. +At the same time, the manycast +scheme starts all over from the beginning and +the expanding ring shrinks to the minimum and increments +from there while collecting all servers in scope. +.SS Manycast Options +.TP 7 +.NOP \f\*[B-Font]tos\f[] [\f\*[B-Font]ceiling\f[] \f\*[I-Font]ceiling\f[] | \f\*[B-Font]cohort\f[] { \f\*[B-Font]0\f[] | \f\*[B-Font]1\f[] } | \f\*[B-Font]floor\f[] \f\*[I-Font]floor\f[] | \f\*[B-Font]minclock\f[] \f\*[I-Font]minclock\f[] | \f\*[B-Font]minsane\f[] \f\*[I-Font]minsane\f[]] +This command affects the clock selection and clustering +algorithms. +It can be used to select the quality and +quantity of peers used to synchronize the system clock +and is most useful in manycast mode. +The variables operate +as follows: +.RS +.TP 7 +.NOP \f\*[B-Font]ceiling\f[] \f\*[I-Font]ceiling\f[] +Peers with strata above +\f\*[B-Font]ceiling\f[] +will be discarded if there are at least +\f\*[B-Font]minclock\f[] +peers remaining. +This value defaults to 15, but can be changed +to any number from 1 to 15. +.TP 7 +.NOP \f\*[B-Font]cohort\f[] {0 | 1 } +This is a binary flag which enables (0) or disables (1) +manycast server replies to manycast clients with the same +stratum level. +This is useful to reduce implosions where +large numbers of clients with the same stratum level +are present. +The default is to enable these replies. +.TP 7 +.NOP \f\*[B-Font]floor\f[] \f\*[I-Font]floor\f[] +Peers with strata below +\f\*[B-Font]floor\f[] +will be discarded if there are at least +\f\*[B-Font]minclock\f[] +peers remaining. +This value defaults to 1, but can be changed +to any number from 1 to 15. +.TP 7 +.NOP \f\*[B-Font]minclock\f[] \f\*[I-Font]minclock\f[] +The clustering algorithm repeatedly casts out outlier +associations until no more than +\f\*[B-Font]minclock\f[] +associations remain. +This value defaults to 3, +but can be changed to any number from 1 to the number of +configured sources. +.TP 7 +.NOP \f\*[B-Font]minsane\f[] \f\*[I-Font]minsane\f[] +This is the minimum number of candidates available +to the clock selection algorithm in order to produce +one or more truechimers for the clustering algorithm. +If fewer than this number are available, the clock is +undisciplined and allowed to run free. +The default is 1 +for legacy purposes. +However, according to principles of +Byzantine agreement, +\f\*[B-Font]minsane\f[] +should be at least 4 in order to detect and discard +a single falseticker. +.RE +.TP 7 +.NOP \f\*[B-Font]ttl\f[] \f\*[I-Font]hop\f[] \f\*[I-Font]...\f[] +This command specifies a list of TTL values in increasing +order, up to 8 values can be specified. +In manycast mode these values are used in turn +in an expanding-ring search. +The default is eight +multiples of 32 starting at 31. +.PP +.SH Reference Clock Support +The NTP Version 4 daemon supports some three dozen different radio, +satellite and modem reference clocks plus a special pseudo-clock +used for backup or when no other clock source is available. +Detailed descriptions of individual device drivers and options can +be found in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +Additional information can be found in the pages linked +there, including the +"Debugging Hints for Reference Clock Drivers" +and +"How To Write a Reference Clock Driver" +pages +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +In addition, support for a PPS +signal is available as described in the +"Pulse-per-second (PPS) Signal Interfacing" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +Many +drivers support special line discipline/streams modules which can +significantly improve the accuracy using the driver. +These are +described in the +"Line Disciplines and Streams Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.sp \n(Ppu +.ne 2 + +A reference clock will generally (though not always) be a radio +timecode receiver which is synchronized to a source of standard +time such as the services offered by the NRC in Canada and NIST and +USNO in the US. +The interface between the computer and the timecode +receiver is device dependent, but is usually a serial port. +A +device driver specific to each reference clock must be selected and +compiled in the distribution; however, most common radio, satellite +and modem clocks are included by default. +Note that an attempt to +configure a reference clock when the driver has not been compiled +or the hardware port has not been appropriately configured results +in a scalding remark to the system log file, but is otherwise non +hazardous. +.sp \n(Ppu +.ne 2 + +For the purposes of configuration, +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +treats +reference clocks in a manner analogous to normal NTP peers as much +as possible. +Reference clocks are identified by a syntactically +correct but invalid IP address, in order to distinguish them from +normal NTP peers. +Reference clock addresses are of the form +\f[C]127.127.\f[]\f\*[I-Font]t\f[].\f\*[I-Font]u\f[], +where +\f\*[I-Font]t\f[] +is an integer +denoting the clock type and +\f\*[I-Font]u\f[] +indicates the unit +number in the range 0-3. +While it may seem overkill, it is in fact +sometimes useful to configure multiple reference clocks of the same +type, in which case the unit numbers must be unique. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]server\f[] +command is used to configure a reference +clock, where the +\f\*[I-Font]address\f[] +argument in that command +is the clock address. +The +\f\*[B-Font]key\f[], +\f\*[B-Font]version\f[] +and +\f\*[B-Font]ttl\f[] +options are not used for reference clock support. +The +\f\*[B-Font]mode\f[] +option is added for reference clock support, as +described below. +The +\f\*[B-Font]prefer\f[] +option can be useful to +persuade the server to cherish a reference clock with somewhat more +enthusiasm than other reference clocks or peers. +Further +information on this option can be found in the +"Mitigation Rules and the prefer Keyword" +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +page. +The +\f\*[B-Font]minpoll\f[] +and +\f\*[B-Font]maxpoll\f[] +options have +meaning only for selected clock drivers. +See the individual clock +driver document pages for additional information. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]fudge\f[] +command is used to provide additional +information for individual clock drivers and normally follows +immediately after the +\f\*[B-Font]server\f[] +command. +The +\f\*[I-Font]address\f[] +argument specifies the clock address. +The +\f\*[B-Font]refid\f[] +and +\f\*[B-Font]stratum\f[] +options can be used to +override the defaults for the device. +There are two optional +device-dependent time offsets and four flags that can be included +in the +\f\*[B-Font]fudge\f[] +command as well. +.sp \n(Ppu +.ne 2 + +The stratum number of a reference clock is by default zero. +Since the +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +daemon adds one to the stratum of each +peer, a primary server ordinarily displays an external stratum of +one. +In order to provide engineered backups, it is often useful to +specify the reference clock stratum as greater than zero. +The +\f\*[B-Font]stratum\f[] +option is used for this purpose. +Also, in cases +involving both a reference clock and a pulse-per-second (PPS) +discipline signal, it is useful to specify the reference clock +identifier as other than the default, depending on the driver. +The +\f\*[B-Font]refid\f[] +option is used for this purpose. +Except where noted, +these options apply to all clock drivers. +.SS Reference Clock Commands +.TP 7 +.NOP \f\*[B-Font]server\f[] \f[C]127.127.\f[]\f\*[I-Font]t\f[].\f\*[I-Font]u\f[] [\f\*[B-Font]prefer\f[]] [\f\*[B-Font]mode\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]minpoll\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]maxpoll\f[] \f\*[I-Font]int\f[]] +This command can be used to configure reference clocks in +special ways. +The options are interpreted as follows: +.RS +.TP 7 +.NOP \f\*[B-Font]prefer\f[] +Marks the reference clock as preferred. +All other things being +equal, this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +"Mitigation Rules and the prefer Keyword" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +for further information. +.TP 7 +.NOP \f\*[B-Font]mode\f[] \f\*[I-Font]int\f[] +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.TP 7 +.NOP \f\*[B-Font]minpoll\f[] \f\*[I-Font]int\f[] +.TP 7 +.NOP \f\*[B-Font]maxpoll\f[] \f\*[I-Font]int\f[] +These options specify the minimum and maximum polling interval +for reference clock messages, as a power of 2 in seconds +For +most directly connected reference clocks, both +\f\*[B-Font]minpoll\f[] +and +\f\*[B-Font]maxpoll\f[] +default to 6 (64 s). +For modem reference clocks, +\f\*[B-Font]minpoll\f[] +defaults to 10 (17.1 m) and +\f\*[B-Font]maxpoll\f[] +defaults to 14 (4.5 h). +The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. +.RE +.TP 7 +.NOP \f\*[B-Font]fudge\f[] \f[C]127.127.\f[]\f\*[I-Font]t\f[].\f\*[I-Font]u\f[] [\f\*[B-Font]time1\f[] \f\*[I-Font]sec\f[]] [\f\*[B-Font]time2\f[] \f\*[I-Font]sec\f[]] [\f\*[B-Font]stratum\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]refid\f[] \f\*[I-Font]string\f[]] [\f\*[B-Font]mode\f[] \f\*[I-Font]int\f[]] [\f\*[B-Font]flag1\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] [\f\*[B-Font]flag2\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] [\f\*[B-Font]flag3\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] [\f\*[B-Font]flag4\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[]] +This command can be used to configure reference clocks in +special ways. +It must immediately follow the +\f\*[B-Font]server\f[] +command which configures the driver. +Note that the same capability +is possible at run time using the +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +program. +The options are interpreted as +follows: +.RS +.TP 7 +.NOP \f\*[B-Font]time1\f[] \f\*[I-Font]sec\f[] +Specifies a constant to be added to the time offset produced by +the driver, a fixed-point decimal number in seconds. +This is used +as a calibration constant to adjust the nominal time offset of a +particular clock to agree with an external standard, such as a +precision PPS signal. +It also provides a way to correct a +systematic error or bias due to serial port or operating system +latencies, different cable lengths or receiver internal delay. +The +specified offset is in addition to the propagation delay provided +by other means, such as internal DIPswitches. +Where a calibration +for an individual system and driver is available, an approximate +correction is noted in the driver documentation pages. +Note: in order to facilitate calibration when more than one +radio clock or PPS signal is supported, a special calibration +feature is available. +It takes the form of an argument to the +\f\*[B-Font]enable\f[] +command described in +\fIMiscellaneous\f[] \fIOptions\f[] +page and operates as described in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.TP 7 +.NOP \f\*[B-Font]time2\f[] \f\*[I-Font]secs\f[] +Specifies a fixed-point decimal number in seconds, which is +interpreted in a driver-dependent way. +See the descriptions of +specific drivers in the +"Reference Clock Drivers" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +.TP 7 +.NOP \f\*[B-Font]stratum\f[] \f\*[I-Font]int\f[] +Specifies the stratum number assigned to the driver, an integer +between 0 and 15. +This number overrides the default stratum number +ordinarily assigned by the driver itself, usually zero. +.TP 7 +.NOP \f\*[B-Font]refid\f[] \f\*[I-Font]string\f[] +Specifies an ASCII string of from one to four characters which +defines the reference identifier used by the driver. +This string +overrides the default identifier ordinarily assigned by the driver +itself. +.TP 7 +.NOP \f\*[B-Font]mode\f[] \f\*[I-Font]int\f[] +Specifies a mode number which is interpreted in a +device-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.TP 7 +.NOP \f\*[B-Font]flag1\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +.TP 7 +.NOP \f\*[B-Font]flag2\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +.TP 7 +.NOP \f\*[B-Font]flag3\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +.TP 7 +.NOP \f\*[B-Font]flag4\f[] \f\*[B-Font]0\f[] \f\*[B-Font]\&|\f[] \f\*[B-Font]1\f[] +These four flags are used for customizing the clock driver. +The +interpretation of these values, and whether they are used at all, +is a function of the particular clock driver. +However, by +convention +\f\*[B-Font]flag4\f[] +is used to enable recording monitoring +data to the +\f\*[B-Font]clockstats\f[] +file configured with the +\f\*[B-Font]filegen\f[] +command. +Further information on the +\f\*[B-Font]filegen\f[] +command can be found in +\fIMonitoring\f[] \fIOptions\f[]. +.RE +.PP +.SH Miscellaneous Options +.TP 7 +.NOP \f\*[B-Font]broadcastdelay\f[] \f\*[I-Font]seconds\f[] +The broadcast and multicast modes require a special calibration +to determine the network delay between the local and remote +servers. +Ordinarily, this is done automatically by the initial +protocol exchanges between the client and server. +In some cases, +the calibration procedure may fail due to network or server access +controls, for example. +This command specifies the default delay to +be used under these circumstances. +Typically (for Ethernet), a +number between 0.003 and 0.007 seconds is appropriate. +The default +when this command is not used is 0.004 seconds. +.TP 7 +.NOP \f\*[B-Font]calldelay\f[] \f\*[I-Font]delay\f[] +This option controls the delay in seconds between the first and second +packets sent in burst or iburst mode to allow additional time for a modem +or ISDN call to complete. +.TP 7 +.NOP \f\*[B-Font]driftfile\f[] \f\*[I-Font]driftfile\f[] +This command specifies the complete path and name of the file used to +record the frequency of the local clock oscillator. +This is the same +operation as the +\f\*[B-Font]\-f\f[] +command line option. +If the file exists, it is read at +startup in order to set the initial frequency and then updated once per +hour with the current frequency computed by the daemon. +If the file name is +specified, but the file itself does not exist, the starts with an initial +frequency of zero and creates the file when writing it for the first time. +If this command is not given, the daemon will always start with an initial +frequency of zero. +.sp \n(Ppu +.ne 2 + +The file format consists of a single line containing a single +floating point number, which records the frequency offset measured +in parts-per-million (PPM). +The file is updated by first writing +the current drift value into a temporary file and then renaming +this file to replace the old version. +This implies that +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +must have write permission for the directory the +drift file is located in, and that file system links, symbolic or +otherwise, should be avoided. +.TP 7 +.NOP \f\*[B-Font]dscp\f[] \f\*[I-Font]value\f[] +This option specifies the Differentiated Services Control Point (DSCP) value, +a 6-bit code. The default value is 46, signifying Expedited Forwarding. +.TP 7 +.NOP \f\*[B-Font]enable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]mode7\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]stats\f[]] +.TP 7 +.NOP \f\*[B-Font]disable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]mode7\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]stats\f[]] +Provides a way to enable or disable various server options. +Flags not mentioned are unaffected. +Note that all of these flags +can be controlled remotely using the +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +utility program. +.RS +.TP 7 +.NOP \f\*[B-Font]auth\f[] +Enables the server to synchronize with unconfigured peers only if the +peer has been correctly authenticated using either public key or +private key cryptography. +The default for this flag is +\f\*[B-Font]enable\f[]. +.TP 7 +.NOP \f\*[B-Font]bclient\f[] +Enables the server to listen for a message from a broadcast or +multicast server, as in the +\f\*[B-Font]multicastclient\f[] +command with default +address. +The default for this flag is +\f\*[B-Font]disable\f[]. +.TP 7 +.NOP \f\*[B-Font]calibrate\f[] +Enables the calibrate feature for reference clocks. +The default for +this flag is +\f\*[B-Font]disable\f[]. +.TP 7 +.NOP \f\*[B-Font]kernel\f[] +Enables the kernel time discipline, if available. +The default for this +flag is +\f\*[B-Font]enable\f[] +if support is available, otherwise +\f\*[B-Font]disable\f[]. +.TP 7 +.NOP \f\*[B-Font]mode7\f[] +Enables processing of NTP mode 7 implementation-specific requests +which are used by the deprecated +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +program. +The default for this flag is disable. +This flag is excluded from runtime configuration using +\fCntpq\f[]\fR(@NTPQ_MS@)\f[]. +The +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +program provides the same capabilities as +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +using standard mode 6 requests. +.TP 7 +.NOP \f\*[B-Font]monitor\f[] +Enables the monitoring facility. +See the +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +program +and the +\f\*[B-Font]monlist\f[] +command or further information. +The +default for this flag is +\f\*[B-Font]enable\f[]. +.TP 7 +.NOP \f\*[B-Font]ntp\f[] +Enables time and frequency discipline. +In effect, this switch opens and +closes the feedback loop, which is useful for testing. +The default for +this flag is +\f\*[B-Font]enable\f[]. +.TP 7 +.NOP \f\*[B-Font]stats\f[] +Enables the statistics facility. +See the +\fIMonitoring\f[] \fIOptions\f[] +section for further information. +The default for this flag is +\f\*[B-Font]disable\f[]. +.RE +.TP 7 +.NOP \f\*[B-Font]includefile\f[] \f\*[I-Font]includefile\f[] +This command allows additional configuration commands +to be included from a separate file. +Include files may +be nested to a depth of five; upon reaching the end of any +include file, command processing resumes in the previous +configuration file. +This option is useful for sites that run +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +on multiple hosts, with (mostly) common options (e.g., a +restriction list). +.TP 7 +.NOP \f\*[B-Font]leapsmearinterval\f[] \f\*[I-Font]seconds\f[] +This EXPERIMENTAL option is only available if +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +was built with the +\f\*[B-Font]\--enable-leap-smear\f[] +option to the +\f\*[B-Font]configure\f[] +script. +It specifies the interval over which a leap second correction will be applied. +Recommended values for this option are between +7200 (2 hours) and 86400 (24 hours). +.Sy DO NOT USE THIS OPTION ON PUBLIC-ACCESS SERVERS! +See http://bugs.ntp.org/2855 for more information. +.TP 7 +.NOP \f\*[B-Font]logconfig\f[] \f\*[I-Font]configkeyword\f[] +This command controls the amount and type of output written to +the system +\fCsyslog\f[]\fR(3)\f[] +facility or the alternate +\f\*[B-Font]logfile\f[] +log file. +By default, all output is turned on. +All +\f\*[I-Font]configkeyword\f[] +keywords can be prefixed with +\[oq]=\[cq], +\[oq]+\[cq] +and +\[oq]\-\[cq], +where +\[oq]=\[cq] +sets the +\fCsyslog\f[]\fR(3)\f[] +priority mask, +\[oq]+\[cq] +adds and +\[oq]\-\[cq] +removes +messages. +\fCsyslog\f[]\fR(3)\f[] +messages can be controlled in four +classes +(\f\*[B-Font]clock\f[], \f\*[B-Font]peer\f[], \f\*[B-Font]sys\f[] and \f\*[B-Font]sync\f[]). +Within these classes four types of messages can be +controlled: informational messages +(\f\*[B-Font]info\f[]), +event messages +(\f\*[B-Font]events\f[]), +statistics messages +(\f\*[B-Font]statistics\f[]) +and +status messages +(\f\*[B-Font]status\f[]). +.sp \n(Ppu +.ne 2 + +Configuration keywords are formed by concatenating the message class with +the event class. +The +\f\*[B-Font]all\f[] +prefix can be used instead of a message class. +A +message class may also be followed by the +\f\*[B-Font]all\f[] +keyword to enable/disable all +messages of the respective message class.Thus, a minimal log configuration +could look like this: +.br +.in +4 +.nf +logconfig =syncstatus +sysevents +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +This would just list the synchronizations state of +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +and the major system events. +For a simple reference server, the +following minimum message configuration could be useful: +.br +.in +4 +.nf +logconfig =syncall +clockall +.in -4 +.fi +.sp \n(Ppu +.ne 2 + +This configuration will list all clock information and +synchronization information. +All other events and messages about +peers, system events and so on is suppressed. +.TP 7 +.NOP \f\*[B-Font]logfile\f[] \f\*[I-Font]logfile\f[] +This command specifies the location of an alternate log file to +be used instead of the default system +\fCsyslog\f[]\fR(3)\f[] +facility. +This is the same operation as the \-l command line option. +.TP 7 +.NOP \f\*[B-Font]setvar\f[] \f\*[I-Font]variable\f[] [\f\*[B-Font]default\f[]] +This command adds an additional system variable. +These +variables can be used to distribute additional information such as +the access policy. +If the variable of the form +\fIname\f[]\fI=\f[]\f\*[I-Font]value\f[] +is followed by the +\f\*[B-Font]default\f[] +keyword, the +variable will be listed as part of the default system variables +(\fCntpq\f[]\fR(@NTPQ_MS@)\f[] \f\*[B-Font]rv\f[] command)). +These additional variables serve +informational purposes only. +They are not related to the protocol +other that they can be listed. +The known protocol variables will +always override any variables defined via the +\f\*[B-Font]setvar\f[] +mechanism. +There are three special variables that contain the names +of all variable of the same group. +The +\fIsys_var_list\f[] +holds +the names of all system variables. +The +\fIpeer_var_list\f[] +holds +the names of all peer variables and the +\fIclock_var_list\f[] +holds the names of the reference clock variables. +.TP 7 +.NOP \f\*[B-Font]tinker\f[] [\f\*[B-Font]allan\f[] \f\*[I-Font]allan\f[] | \f\*[B-Font]dispersion\f[] \f\*[I-Font]dispersion\f[] | \f\*[B-Font]freq\f[] \f\*[I-Font]freq\f[] | \f\*[B-Font]huffpuff\f[] \f\*[I-Font]huffpuff\f[] | \f\*[B-Font]panic\f[] \f\*[I-Font]panic\f[] | \f\*[B-Font]step\f[] \f\*[I-Font]step\f[] | \f\*[B-Font]stepback\f[] \f\*[I-Font]stepback\f[] | \f\*[B-Font]stepfwd\f[] \f\*[I-Font]stepfwd\f[] | \f\*[B-Font]stepout\f[] \f\*[I-Font]stepout\f[]] +This command can be used to alter several system variables in +very exceptional circumstances. +It should occur in the +configuration file before any other configuration options. +The +default values of these variables have been carefully optimized for +a wide range of network speeds and reliability expectations. +In +general, they interact in intricate ways that are hard to predict +and some combinations can result in some very nasty behavior. +Very +rarely is it necessary to change the default values; but, some +folks cannot resist twisting the knobs anyway and this command is +for them. +Emphasis added: twisters are on their own and can expect +no help from the support group. +.sp \n(Ppu +.ne 2 + +The variables operate as follows: +.RS +.TP 7 +.NOP \f\*[B-Font]allan\f[] \f\*[I-Font]allan\f[] +The argument becomes the new value for the minimum Allan +intercept, which is a parameter of the PLL/FLL clock discipline +algorithm. +The value in log2 seconds defaults to 7 (1024 s), which is also the lower +limit. +.TP 7 +.NOP \f\*[B-Font]dispersion\f[] \f\*[I-Font]dispersion\f[] +The argument becomes the new value for the dispersion increase rate, +normally .000015 s/s. +.TP 7 +.NOP \f\*[B-Font]freq\f[] \f\*[I-Font]freq\f[] +The argument becomes the initial value of the frequency offset in +parts-per-million. +This overrides the value in the frequency file, if +present, and avoids the initial training state if it is not. +.TP 7 +.NOP \f\*[B-Font]huffpuff\f[] \f\*[I-Font]huffpuff\f[] +The argument becomes the new value for the experimental +huff-n'-puff filter span, which determines the most recent interval +the algorithm will search for a minimum delay. +The lower limit is +900 s (15 m), but a more reasonable value is 7200 (2 hours). +There +is no default, since the filter is not enabled unless this command +is given. +.TP 7 +.NOP \f\*[B-Font]panic\f[] \f\*[I-Font]panic\f[] +The argument is the panic threshold, normally 1000 s. +If set to zero, +the panic sanity check is disabled and a clock offset of any value will +be accepted. +.TP 7 +.NOP \f\*[B-Font]step\f[] \f\*[I-Font]step\f[] +The argument is the step threshold, which by default is 0.128 s. +It can +be set to any positive number in seconds. +If set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if the step threshold is set to zero or greater than the +default. +.TP 7 +.NOP \f\*[B-Font]stepback\f[] \f\*[I-Font]stepback\f[] +The argument is the step threshold for the backward direction, +which by default is 0.128 s. +It can +be set to any positive number in seconds. +If both the forward and backward step thresholds are set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if +each direction of step threshold are either +set to zero or greater than .5 second. +.TP 7 +.NOP \f\*[B-Font]stepfwd\f[] \f\*[I-Font]stepfwd\f[] +As for stepback, but for the forward direction. +.TP 7 +.NOP \f\*[B-Font]stepout\f[] \f\*[I-Font]stepout\f[] +The argument is the stepout timeout, which by default is 900 s. +It can +be set to any positive number in seconds. +If set to zero, the stepout +pulses will not be suppressed. +.RE +.TP 7 +.NOP \f\*[B-Font]rlimit\f[] [\f\*[B-Font]memlock\f[] \f\*[I-Font]Nmegabytes\f[] | \f\*[B-Font]stacksize\f[] \f\*[I-Font]N4kPages\f[] \f\*[B-Font]filenum\f[] \f\*[I-Font]Nfiledescriptors\f[]] +.RS +.TP 7 +.NOP \f\*[B-Font]memlock\f[] \f\*[I-Font]Nmegabytes\f[] +Specify the number of megabytes of memory that should be +allocated and locked. +Probably only available under Linux, this option may be useful +when dropping root (the +\f\*[B-Font]\-i\f[] +option). +The default is 32 megabytes on non-Linux machines, and \-1 under Linux. +-1 means "do not lock the process into memory". +0 means "lock whatever memory the process wants into memory". +.TP 7 +.NOP \f\*[B-Font]stacksize\f[] \f\*[I-Font]N4kPages\f[] +Specifies the maximum size of the process stack on systems with the +\fBmlockall\f[]\fR()\f[] +function. +Defaults to 50 4k pages (200 4k pages in OpenBSD). +.TP 7 +.NOP \f\*[B-Font]filenum\f[] \f\*[I-Font]Nfiledescriptors\f[] +Specifies the maximum number of file descriptors ntpd may have open at once. Defaults to the system default. +.RE +.TP 7 +.NOP \f\*[B-Font]trap\f[] \f\*[I-Font]host_address\f[] [\f\*[B-Font]port\f[] \f\*[I-Font]port_number\f[]] [\f\*[B-Font]interface\f[] \f\*[I-Font]interface_address\f[]] +This command configures a trap receiver at the given host +address and port number for sending messages with the specified +local interface address. +If the port number is unspecified, a value +of 18447 is used. +If the interface address is not specified, the +message is sent with a source address of the local interface the +message is sent through. +Note that on a multihomed host the +interface used may vary from time to time with routing changes. +.sp \n(Ppu +.ne 2 + +The trap receiver will generally log event messages and other +information from the server in a log file. +While such monitor +programs may also request their own trap dynamically, configuring a +trap receiver will ensure that no messages are lost when the server +is started. +.TP 7 +.NOP \f\*[B-Font]hop\f[] \f\*[I-Font]...\f[] +This command specifies a list of TTL values in increasing order, up to 8 +values can be specified. +In manycast mode these values are used in turn in +an expanding-ring search. +The default is eight multiples of 32 starting at +31. +.PP +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTP_CONF_\fP or \fBNTP_CONF\fP +.fi +.ad +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH FILES +.TP 15 +.NOP \fI/etc/ntp.conf\f[] +the default name of the configuration file +.br +.ns +.TP 15 +.NOP \fIntp.keys\f[] +private MD5 keys +.br +.ns +.TP 15 +.NOP \fIntpkey\f[] +RSA private key +.br +.ns +.TP 15 +.NOP \fIntpkey_\f[]\f\*[I-Font]host\f[] +RSA public key +.br +.ns +.TP 15 +.NOP \fIntp_dh\f[] +Diffie-Hellman agreement parameters +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "SEE ALSO" +\fCntpd\f[]\fR(@NTPD_MS@)\f[], +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[], +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +.sp \n(Ppu +.ne 2 + +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +\f[C]http://www.ntp.org/\f[]. +A snapshot of this documentation is available in HTML format in +\fI/usr/share/doc/ntp\f[]. +David L. Mills, +\fINetwork Time Protocol (Version 4)\fR, +RFC5905 +.PP + +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH BUGS +The syntax checking is not picky; some combinations of +ridiculous and even hilarious options and modes may not be +detected. +.sp \n(Ppu +.ne 2 + +The +\fIntpkey_\f[]\f\*[I-Font]host\f[] +files are really digital +certificates. +These should be obtained via secure directory +services when they become universally available. +.sp \n(Ppu +.ne 2 + +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +This document was derived from FreeBSD. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntp.conf\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.conf.mdoc.in b/contrib/ntp/ntpd/ntp.conf.mdoc.in new file mode 100644 index 000000000..613ee7a84 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.conf.mdoc.in @@ -0,0 +1,2856 @@ +.Dd October 21 2015 +.Dt NTP_CONF 5 File Formats +.Os +.\" EDIT THIS FILE WITH CAUTION (ntp.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:24 PM by AutoGen 5.18.5 +.\" From the definitions ntp.conf.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntp.conf +.Nd Network Time Protocol (NTP) daemon configuration file format +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +The +.Nm +configuration file is read at initial startup by the +.Xr ntpd @NTPD_MS@ +daemon in order to specify the synchronization sources, +modes and other related information. +Usually, it is installed in the +.Pa /etc +directory, +but could be installed elsewhere +(see the daemon's +.Fl c +command line option). +.Pp +The file format is similar to other +.Ux +configuration files. +Comments begin with a +.Ql # +character and extend to the end of the line; +blank lines are ignored. +Configuration commands consist of an initial keyword +followed by a list of arguments, +some of which may be optional, separated by whitespace. +Commands may not be continued over multiple lines. +Arguments may be host names, +host addresses written in numeric, dotted\-quad form, +integers, floating point numbers (when specifying times in seconds) +and text strings. +.Pp +The rest of this page describes the configuration and control options. +The +.Qq Notes on Configuring NTP and Setting up an NTP Subnet +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +contains an extended discussion of these options. +In addition to the discussion of general +.Sx Configuration Options , +there are sections describing the following supported functionality +and the options used to control it: +.Bl -bullet -offset indent +.It +.Sx Authentication Support +.It +.Sx Monitoring Support +.It +.Sx Access Control Support +.It +.Sx Automatic NTP Configuration Options +.It +.Sx Reference Clock Support +.It +.Sx Miscellaneous Options +.El +.Pp +Following these is a section describing +.Sx Miscellaneous Options . +While there is a rich set of options available, +the only required option is one or more +.Ic pool , +.Ic server , +.Ic peer , +.Ic broadcast +or +.Ic manycastclient +commands. +.Sh Configuration Support +Following is a description of the configuration commands in +NTPv4. +These commands have the same basic functions as in NTPv3 and +in some cases new functions and new arguments. +There are two +classes of commands, configuration commands that configure a +persistent association with a remote server or peer or reference +clock, and auxiliary commands that specify environmental variables +that control various related operations. +.Ss Configuration Commands +The various modes are determined by the command keyword and the +type of the required IP address. +Addresses are classed by type as +(s) a remote server or peer (IPv4 class A, B and C), (b) the +broadcast address of a local interface, (m) a multicast address (IPv4 +class D), or (r) a reference clock address (127.127.x.x). +Note that +only those options applicable to each command are listed below. +Use +of options not listed may not be caught as an error, but may result +in some weird and even destructive behavior. +.Pp +If the Basic Socket Interface Extensions for IPv6 (RFC\-2553) +is detected, support for the IPv6 address family is generated +in addition to the default support of the IPv4 address family. +In a few cases, including the reslist billboard generated +by ntpdc, IPv6 addresses are automatically generated. +IPv6 addresses can be identified by the presence of colons +.Dq \&: +in the address field. +IPv6 addresses can be used almost everywhere where +IPv4 addresses can be used, +with the exception of reference clock addresses, +which are always IPv4. +.Pp +Note that in contexts where a host name is expected, a +.Fl 4 +qualifier preceding +the host name forces DNS resolution to the IPv4 namespace, +while a +.Fl 6 +qualifier forces DNS resolution to the IPv6 namespace. +See IPv6 references for the +equivalent classes for that address family. +.Bl -tag -width indent +.It Xo Ic pool Ar address +.Op Cm burst +.Op Cm iburst +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic server Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm burst +.Op Cm iburst +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic peer Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Xc +.It Xo Ic broadcast Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm ttl Ar ttl +.Xc +.It Xo Ic manycastclient Ar address +.Op Cm key Ar key \&| Cm autokey +.Op Cm version Ar version +.Op Cm prefer +.Op Cm minpoll Ar minpoll +.Op Cm maxpoll Ar maxpoll +.Op Cm ttl Ar ttl +.Xc +.El +.Pp +These five commands specify the time server name or address to +be used and the mode in which to operate. +The +.Ar address +can be +either a DNS name or an IP address in dotted\-quad notation. +Additional information on association behavior can be found in the +.Qq Association Management +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Bl -tag -width indent +.It Ic pool +For type s addresses, this command mobilizes a persistent +client mode association with a number of remote servers. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +.It Ic server +For type s and r addresses, this command mobilizes a persistent +client mode association with the specified remote server or local +radio clock. +In this mode the local clock can synchronized to the +remote server, but the remote server can never be synchronized to +the local clock. +This command should +.Em not +be used for type +b or m addresses. +.It Ic peer +For type s addresses (only), this command mobilizes a +persistent symmetric\-active mode association with the specified +remote peer. +In this mode the local clock can be synchronized to +the remote peer or the remote peer can be synchronized to the local +clock. +This is useful in a network of servers where, depending on +various failure scenarios, either the local or remote peer may be +the better source of time. +This command should NOT be used for type +b, m or r addresses. +.It Ic broadcast +For type b and m addresses (only), this +command mobilizes a persistent broadcast mode association. +Multiple +commands can be used to specify multiple local broadcast interfaces +(subnets) and/or multiple multicast groups. +Note that local +broadcast messages go only to the interface associated with the +subnet specified, but multicast messages go to all interfaces. +In broadcast mode the local server sends periodic broadcast +messages to a client population at the +.Ar address +specified, which is usually the broadcast address on (one of) the +local network(s) or a multicast address assigned to NTP. +The IANA +has assigned the multicast group address IPv4 224.0.1.1 and +IPv6 ff05::101 (site local) exclusively to +NTP, but other nonconflicting addresses can be used to contain the +messages within administrative boundaries. +Ordinarily, this +specification applies only to the local server operating as a +sender; for operation as a broadcast client, see the +.Ic broadcastclient +or +.Ic multicastclient +commands +below. +.It Ic manycastclient +For type m addresses (only), this command mobilizes a +manycast client mode association for the multicast address +specified. +In this case a specific address must be supplied which +matches the address used on the +.Ic manycastserver +command for +the designated manycast servers. +The NTP multicast address +224.0.1.1 assigned by the IANA should NOT be used, unless specific +means are taken to avoid spraying large areas of the Internet with +these messages and causing a possibly massive implosion of replies +at the sender. +The +.Ic manycastserver +command specifies that the local server +is to operate in client mode with the remote servers that are +discovered as the result of broadcast/multicast messages. +The +client broadcasts a request message to the group address associated +with the specified +.Ar address +and specifically enabled +servers respond to these messages. +The client selects the servers +providing the best time and continues as with the +.Ic server +command. +The remaining servers are discarded as if never +heard. +.El +.Pp +Options: +.Bl -tag -width indent +.It Cm autokey +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the autokey scheme +described in +.Sx Authentication Options . +.It Cm burst +when the server is reachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first and second packets +can be changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to improve timekeeping quality +with the +.Ic server +command and s addresses. +.It Cm iburst +When the server is unreachable, send a burst of eight packets +instead of the usual one. +The packet spacing is normally 2 s; +however, the spacing between the first two packets can be +changed with the calldelay command to allow +additional time for a modem or ISDN call to complete. +This is designed to speed the initial synchronization +acquisition with the +.Ic server +command and s addresses and when +.Xr ntpd @NTPD_MS@ +is started with the +.Fl q +option. +.It Cm key Ar key +All packets sent to and received from the server or peer are to +include authentication fields encrypted using the specified +.Ar key +identifier with values from 1 to 65534, inclusive. +The +default is to include no encryption field. +.It Cm minpoll Ar minpoll +.It Cm maxpoll Ar maxpoll +These options specify the minimum and maximum poll intervals +for NTP messages, as a power of 2 in seconds +The maximum poll +interval defaults to 10 (1,024 s), but can be increased by the +.Cm maxpoll +option to an upper limit of 17 (36.4 h). +The +minimum poll interval defaults to 6 (64 s), but can be decreased by +the +.Cm minpoll +option to a lower limit of 4 (16 s). +.It Cm noselect +Marks the server as unused, except for display purposes. +The server is discarded by the selection algroithm. +.It Cm prefer +Marks the server as preferred. +All other things being equal, +this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +.Qq Mitigation Rules and the prefer Keyword +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +for further information. +.It Cm ttl Ar ttl +This option is used only with broadcast server and manycast +client modes. +It specifies the time\-to\-live +.Ar ttl +to +use on broadcast server and multicast server and the maximum +.Ar ttl +for the expanding ring search with manycast +client packets. +Selection of the proper value, which defaults to +127, is something of a black art and should be coordinated with the +network administrator. +.It Cm version Ar version +Specifies the version number to be used for outgoing NTP +packets. +Versions 1\-4 are the choices, with version 4 the +default. +.El +.Ss Auxiliary Commands +.Bl -tag -width indent +.It Ic broadcastclient +This command enables reception of broadcast server messages to +any local interface (type b) address. +Upon receiving a message for +the first time, the broadcast client measures the nominal server +propagation delay using a brief client/server exchange with the +server, then enters the broadcast client mode, in which it +synchronizes to succeeding broadcast messages. +Note that, in order +to avoid accidental or malicious disruption in this mode, both the +server and client should operate using symmetric\-key or public\-key +authentication as described in +.Sx Authentication Options . +.It Ic manycastserver Ar address ... +This command enables reception of manycast client messages to +the multicast group address(es) (type m) specified. +At least one +address is required, but the NTP multicast address 224.0.1.1 +assigned by the IANA should NOT be used, unless specific means are +taken to limit the span of the reply and avoid a possibly massive +implosion at the original sender. +Note that, in order to avoid +accidental or malicious disruption in this mode, both the server +and client should operate using symmetric\-key or public\-key +authentication as described in +.Sx Authentication Options . +.It Ic multicastclient Ar address ... +This command enables reception of multicast server messages to +the multicast group address(es) (type m) specified. +Upon receiving +a message for the first time, the multicast client measures the +nominal server propagation delay using a brief client/server +exchange with the server, then enters the broadcast client mode, in +which it synchronizes to succeeding multicast messages. +Note that, +in order to avoid accidental or malicious disruption in this mode, +both the server and client should operate using symmetric\-key or +public\-key authentication as described in +.Sx Authentication Options . +.It Ic mdnstries Ar number +If we are participating in mDNS, +after we have synched for the first time +we attempt to register with the mDNS system. +If that registration attempt fails, +we try again at one minute intervals for up to +.Ic mdnstries +times. +After all, +.Ic ntpd +may be starting before mDNS. +The default value for +.Ic mdnstries +is 5. +.El +.Sh Authentication Support +Authentication support allows the NTP client to verify that the +server is in fact known and trusted and not an intruder intending +accidentally or on purpose to masquerade as that server. +The NTPv3 +specification RFC\-1305 defines a scheme which provides +cryptographic authentication of received NTP packets. +Originally, +this was done using the Data Encryption Standard (DES) algorithm +operating in Cipher Block Chaining (CBC) mode, commonly called +DES\-CBC. +Subsequently, this was replaced by the RSA Message Digest +5 (MD5) algorithm using a private key, commonly called keyed\-MD5. +Either algorithm computes a message digest, or one\-way hash, which +can be used to verify the server has the correct private key and +key identifier. +.Pp +NTPv4 retains the NTPv3 scheme, properly described as symmetric key +cryptography and, in addition, provides a new Autokey scheme +based on public key cryptography. +Public key cryptography is generally considered more secure +than symmetric key cryptography, since the security is based +on a private value which is generated by each server and +never revealed. +With Autokey all key distribution and +management functions involve only public values, which +considerably simplifies key distribution and storage. +Public key management is based on X.509 certificates, +which can be provided by commercial services or +produced by utility programs in the OpenSSL software library +or the NTPv4 distribution. +.Pp +While the algorithms for symmetric key cryptography are +included in the NTPv4 distribution, public key cryptography +requires the OpenSSL software library to be installed +before building the NTP distribution. +Directions for doing that +are on the Building and Installing the Distribution page. +.Pp +Authentication is configured separately for each association +using the +.Cm key +or +.Cm autokey +subcommand on the +.Ic peer , +.Ic server , +.Ic broadcast +and +.Ic manycastclient +configuration commands as described in +.Sx Configuration Options +page. +The authentication +options described below specify the locations of the key files, +if other than default, which symmetric keys are trusted +and the interval between various operations, if other than default. +.Pp +Authentication is always enabled, +although ineffective if not configured as +described below. +If a NTP packet arrives +including a message authentication +code (MAC), it is accepted only if it +passes all cryptographic checks. +The +checks require correct key ID, key value +and message digest. +If the packet has +been modified in any way or replayed +by an intruder, it will fail one or more +of these checks and be discarded. +Furthermore, the Autokey scheme requires a +preliminary protocol exchange to obtain +the server certificate, verify its +credentials and initialize the protocol +.Pp +The +.Cm auth +flag controls whether new associations or +remote configuration commands require cryptographic authentication. +This flag can be set or reset by the +.Ic enable +and +.Ic disable +commands and also by remote +configuration commands sent by a +.Xr ntpdc @NTPDC_MS@ +program running in +another machine. +If this flag is enabled, which is the default +case, new broadcast client and symmetric passive associations and +remote configuration commands must be cryptographically +authenticated using either symmetric key or public key cryptography. +If this +flag is disabled, these operations are effective +even if not cryptographic +authenticated. +It should be understood +that operating with the +.Ic auth +flag disabled invites a significant vulnerability +where a rogue hacker can +masquerade as a falseticker and seriously +disrupt system timekeeping. +It is +important to note that this flag has no purpose +other than to allow or disallow +a new association in response to new broadcast +and symmetric active messages +and remote configuration commands and, in particular, +the flag has no effect on +the authentication process itself. +.Pp +An attractive alternative where multicast support is available +is manycast mode, in which clients periodically troll +for servers as described in the +.Sx Automatic NTP Configuration Options +page. +Either symmetric key or public key +cryptographic authentication can be used in this mode. +The principle advantage +of manycast mode is that potential servers need not be +configured in advance, +since the client finds them during regular operation, +and the configuration +files for all clients can be identical. +.Pp +The security model and protocol schemes for +both symmetric key and public key +cryptography are summarized below; +further details are in the briefings, papers +and reports at the NTP project page linked from +.Li http://www.ntp.org/ . +.Ss Symmetric\-Key Cryptography +The original RFC\-1305 specification allows any one of possibly +65,534 keys, each distinguished by a 32\-bit key identifier, to +authenticate an association. +The servers and clients involved must +agree on the key and key identifier to +authenticate NTP packets. +Keys and +related information are specified in a key +file, usually called +.Pa ntp.keys , +which must be distributed and stored using +secure means beyond the scope of the NTP protocol itself. +Besides the keys used +for ordinary NTP associations, +additional keys can be used as passwords for the +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +utility programs. +.Pp +When +.Xr ntpd @NTPD_MS@ +is first started, it reads the key file specified in the +.Ic keys +configuration command and installs the keys +in the key cache. +However, +individual keys must be activated with the +.Ic trusted +command before use. +This +allows, for instance, the installation of possibly +several batches of keys and +then activating or deactivating each batch +remotely using +.Xr ntpdc @NTPDC_MS@ . +This also provides a revocation capability that can be used +if a key becomes compromised. +The +.Ic requestkey +command selects the key used as the password for the +.Xr ntpdc @NTPDC_MS@ +utility, while the +.Ic controlkey +command selects the key used as the password for the +.Xr ntpq @NTPQ_MS@ +utility. +.Ss Public Key Cryptography +NTPv4 supports the original NTPv3 symmetric key scheme +described in RFC\-1305 and in addition the Autokey protocol, +which is based on public key cryptography. +The Autokey Version 2 protocol described on the Autokey Protocol +page verifies packet integrity using MD5 message digests +and verifies the source with digital signatures and any of several +digest/signature schemes. +Optional identity schemes described on the Identity Schemes +page and based on cryptographic challenge/response algorithms +are also available. +Using all of these schemes provides strong security against +replay with or without modification, spoofing, masquerade +and most forms of clogging attacks. +.\" .Pp +.\" The cryptographic means necessary for all Autokey operations +.\" is provided by the OpenSSL software library. +.\" This library is available from http://www.openssl.org/ +.\" and can be installed using the procedures outlined +.\" in the Building and Installing the Distribution page. +.\" Once installed, +.\" the configure and build +.\" process automatically detects the library and links +.\" the library routines required. +.Pp +The Autokey protocol has several modes of operation +corresponding to the various NTP modes supported. +Most modes use a special cookie which can be +computed independently by the client and server, +but encrypted in transmission. +All modes use in addition a variant of the S\-KEY scheme, +in which a pseudo\-random key list is generated and used +in reverse order. +These schemes are described along with an executive summary, +current status, briefing slides and reading list on the +.Sx Autonomous Authentication +page. +.Pp +The specific cryptographic environment used by Autokey servers +and clients is determined by a set of files +and soft links generated by the +.Xr ntp\-keygen 1ntpkeygenmdoc +program. +This includes a required host key file, +required certificate file and optional sign key file, +leapsecond file and identity scheme files. +The +digest/signature scheme is specified in the X.509 certificate +along with the matching sign key. +There are several schemes +available in the OpenSSL software library, each identified +by a specific string such as +.Cm md5WithRSAEncryption , +which stands for the MD5 message digest with RSA +encryption scheme. +The current NTP distribution supports +all the schemes in the OpenSSL library, including +those based on RSA and DSA digital signatures. +.Pp +NTP secure groups can be used to define cryptographic compartments +and security hierarchies. +It is important that every host +in the group be able to construct a certificate trail to one +or more trusted hosts in the same group. +Each group +host runs the Autokey protocol to obtain the certificates +for all hosts along the trail to one or more trusted hosts. +This requires the configuration file in all hosts to be +engineered so that, even under anticipated failure conditions, +the NTP subnet will form such that every group host can find +a trail to at least one trusted host. +.Ss Naming and Addressing +It is important to note that Autokey does not use DNS to +resolve addresses, since DNS can't be completely trusted +until the name servers have synchronized clocks. +The cryptographic name used by Autokey to bind the host identity +credentials and cryptographic values must be independent +of interface, network and any other naming convention. +The name appears in the host certificate in either or both +the subject and issuer fields, so protection against +DNS compromise is essential. +.Pp +By convention, the name of an Autokey host is the name returned +by the Unix +.Xr gethostname 2 +system call or equivalent in other systems. +By the system design +model, there are no provisions to allow alternate names or aliases. +However, this is not to say that DNS aliases, different names +for each interface, etc., are constrained in any way. +.Pp +It is also important to note that Autokey verifies authenticity +using the host name, network address and public keys, +all of which are bound together by the protocol specifically +to deflect masquerade attacks. +For this reason Autokey +includes the source and destinatino IP addresses in message digest +computations and so the same addresses must be available +at both the server and client. +For this reason operation +with network address translation schemes is not possible. +This reflects the intended robust security model where government +and corporate NTP servers are operated outside firewall perimeters. +.Ss Operation +A specific combination of authentication scheme (none, +symmetric key, public key) and identity scheme is called +a cryptotype, although not all combinations are compatible. +There may be management configurations where the clients, +servers and peers may not all support the same cryptotypes. +A secure NTPv4 subnet can be configured in many ways while +keeping in mind the principles explained above and +in this section. +Note however that some cryptotype +combinations may successfully interoperate with each other, +but may not represent good security practice. +.Pp +The cryptotype of an association is determined at the time +of mobilization, either at configuration time or some time +later when a message of appropriate cryptotype arrives. +When mobilized by a +.Ic server +or +.Ic peer +configuration command and no +.Ic key +or +.Ic autokey +subcommands are present, the association is not +authenticated; if the +.Ic key +subcommand is present, the association is authenticated +using the symmetric key ID specified; if the +.Ic autokey +subcommand is present, the association is authenticated +using Autokey. +.Pp +When multiple identity schemes are supported in the Autokey +protocol, the first message exchange determines which one is used. +The client request message contains bits corresponding +to which schemes it has available. +The server response message +contains bits corresponding to which schemes it has available. +Both server and client match the received bits with their own +and select a common scheme. +.Pp +Following the principle that time is a public value, +a server responds to any client packet that matches +its cryptotype capabilities. +Thus, a server receiving +an unauthenticated packet will respond with an unauthenticated +packet, while the same server receiving a packet of a cryptotype +it supports will respond with packets of that cryptotype. +However, unconfigured broadcast or manycast client +associations or symmetric passive associations will not be +mobilized unless the server supports a cryptotype compatible +with the first packet received. +By default, unauthenticated associations will not be mobilized +unless overridden in a decidedly dangerous way. +.Pp +Some examples may help to reduce confusion. +Client Alice has no specific cryptotype selected. +Server Bob has both a symmetric key file and minimal Autokey files. +Alice's unauthenticated messages arrive at Bob, who replies with +unauthenticated messages. +Cathy has a copy of Bob's symmetric +key file and has selected key ID 4 in messages to Bob. +Bob verifies the message with his key ID 4. +If it's the +same key and the message is verified, Bob sends Cathy a reply +authenticated with that key. +If verification fails, +Bob sends Cathy a thing called a crypto\-NAK, which tells her +something broke. +She can see the evidence using the +.Xr ntpq @NTPQ_MS@ +program. +.Pp +Denise has rolled her own host key and certificate. +She also uses one of the identity schemes as Bob. +She sends the first Autokey message to Bob and they +both dance the protocol authentication and identity steps. +If all comes out okay, Denise and Bob continue as described above. +.Pp +It should be clear from the above that Bob can support +all the girls at the same time, as long as he has compatible +authentication and identity credentials. +Now, Bob can act just like the girls in his own choice of servers; +he can run multiple configured associations with multiple different +servers (or the same server, although that might not be useful). +But, wise security policy might preclude some cryptotype +combinations; for instance, running an identity scheme +with one server and no authentication with another might not be wise. +.Ss Key Management +The cryptographic values used by the Autokey protocol are +incorporated as a set of files generated by the +.Xr ntp\-keygen 1ntpkeygenmdoc +utility program, including symmetric key, host key and +public certificate files, as well as sign key, identity parameters +and leapseconds files. +Alternatively, host and sign keys and +certificate files can be generated by the OpenSSL utilities +and certificates can be imported from public certificate +authorities. +Note that symmetric keys are necessary for the +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +utility programs. +The remaining files are necessary only for the +Autokey protocol. +.Pp +Certificates imported from OpenSSL or public certificate +authorities have certian limitations. +The certificate should be in ASN.1 syntax, X.509 Version 3 +format and encoded in PEM, which is the same format +used by OpenSSL. +The overall length of the certificate encoded +in ASN.1 must not exceed 1024 bytes. +The subject distinguished +name field (CN) is the fully qualified name of the host +on which it is used; the remaining subject fields are ignored. +The certificate extension fields must not contain either +a subject key identifier or a issuer key identifier field; +however, an extended key usage field for a trusted host must +contain the value +.Cm trustRoot ; . +Other extension fields are ignored. +.Ss Authentication Commands +.Bl -tag -width indent +.It Ic autokey Op Ar logsec +Specifies the interval between regenerations of the session key +list used with the Autokey protocol. +Note that the size of the key +list for each association depends on this interval and the current +poll interval. +The default value is 12 (4096 s or about 1.1 hours). +For poll intervals above the specified interval, a session key list +with a single entry will be regenerated for every message +sent. +.It Ic controlkey Ar key +Specifies the key identifier to use with the +.Xr ntpq @NTPQ_MS@ +utility, which uses the standard +protocol defined in RFC\-1305. +The +.Ar key +argument is +the key identifier for a trusted key, where the value can be in the +range 1 to 65,534, inclusive. +.It Xo Ic crypto +.Op Cm cert Ar file +.Op Cm leap Ar file +.Op Cm randfile Ar file +.Op Cm host Ar file +.Op Cm sign Ar file +.Op Cm gq Ar file +.Op Cm gqpar Ar file +.Op Cm iffpar Ar file +.Op Cm mvpar Ar file +.Op Cm pw Ar password +.Xc +This command requires the OpenSSL library. +It activates public key +cryptography, selects the message digest and signature +encryption scheme and loads the required private and public +values described above. +If one or more files are left unspecified, +the default names are used as described above. +Unless the complete path and name of the file are specified, the +location of a file is relative to the keys directory specified +in the +.Ic keysdir +command or default +.Pa /usr/local/etc . +Following are the subcommands: +.Bl -tag -width indent +.It Cm cert Ar file +Specifies the location of the required host public certificate file. +This overrides the link +.Pa ntpkey_cert_ Ns Ar hostname +in the keys directory. +.It Cm gqpar Ar file +Specifies the location of the optional GQ parameters file. +This +overrides the link +.Pa ntpkey_gq_ Ns Ar hostname +in the keys directory. +.It Cm host Ar file +Specifies the location of the required host key file. +This overrides +the link +.Pa ntpkey_key_ Ns Ar hostname +in the keys directory. +.It Cm iffpar Ar file +Specifies the location of the optional IFF parameters file.This +overrides the link +.Pa ntpkey_iff_ Ns Ar hostname +in the keys directory. +.It Cm leap Ar file +Specifies the location of the optional leapsecond file. +This overrides the link +.Pa ntpkey_leap +in the keys directory. +.It Cm mvpar Ar file +Specifies the location of the optional MV parameters file. +This +overrides the link +.Pa ntpkey_mv_ Ns Ar hostname +in the keys directory. +.It Cm pw Ar password +Specifies the password to decrypt files containing private keys and +identity parameters. +This is required only if these files have been +encrypted. +.It Cm randfile Ar file +Specifies the location of the random seed file used by the OpenSSL +library. +The defaults are described in the main text above. +.It Cm sign Ar file +Specifies the location of the optional sign key file. +This overrides +the link +.Pa ntpkey_sign_ Ns Ar hostname +in the keys directory. +If this file is +not found, the host key is also the sign key. +.El +.It Ic keys Ar keyfile +Specifies the complete path and location of the MD5 key file +containing the keys and key identifiers used by +.Xr ntpd @NTPD_MS@ , +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +when operating with symmetric key cryptography. +This is the same operation as the +.Fl k +command line option. +.It Ic keysdir Ar path +This command specifies the default directory path for +cryptographic keys, parameters and certificates. +The default is +.Pa /usr/local/etc/ . +.It Ic requestkey Ar key +Specifies the key identifier to use with the +.Xr ntpdc @NTPDC_MS@ +utility program, which uses a +proprietary protocol specific to this implementation of +.Xr ntpd @NTPD_MS@ . +The +.Ar key +argument is a key identifier +for the trusted key, where the value can be in the range 1 to +65,534, inclusive. +.It Ic revoke Ar logsec +Specifies the interval between re\-randomization of certain +cryptographic values used by the Autokey scheme, as a power of 2 in +seconds. +These values need to be updated frequently in order to +deflect brute\-force attacks on the algorithms of the scheme; +however, updating some values is a relatively expensive operation. +The default interval is 16 (65,536 s or about 18 hours). +For poll +intervals above the specified interval, the values will be updated +for every message sent. +.It Ic trustedkey Ar key ... +Specifies the key identifiers which are trusted for the +purposes of authenticating peers with symmetric key cryptography, +as well as keys used by the +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +programs. +The authentication procedures require that both the local +and remote servers share the same key and key identifier for this +purpose, although different keys can be used with different +servers. +The +.Ar key +arguments are 32\-bit unsigned +integers with values from 1 to 65,534. +.El +.Ss Error Codes +The following error codes are reported via the NTP control +and monitoring protocol trap mechanism. +.Bl -tag -width indent +.It 101 +.Pq bad field format or length +The packet has invalid version, length or format. +.It 102 +.Pq bad timestamp +The packet timestamp is the same or older than the most recent received. +This could be due to a replay or a server clock time step. +.It 103 +.Pq bad filestamp +The packet filestamp is the same or older than the most recent received. +This could be due to a replay or a key file generation error. +.It 104 +.Pq bad or missing public key +The public key is missing, has incorrect format or is an unsupported type. +.It 105 +.Pq unsupported digest type +The server requires an unsupported digest/signature scheme. +.It 106 +.Pq mismatched digest types +Not used. +.It 107 +.Pq bad signature length +The signature length does not match the current public key. +.It 108 +.Pq signature not verified +The message fails the signature check. +It could be bogus or signed by a +different private key. +.It 109 +.Pq certificate not verified +The certificate is invalid or signed with the wrong key. +.It 110 +.Pq certificate not verified +The certificate is not yet valid or has expired or the signature could not +be verified. +.It 111 +.Pq bad or missing cookie +The cookie is missing, corrupted or bogus. +.It 112 +.Pq bad or missing leapseconds table +The leapseconds table is missing, corrupted or bogus. +.It 113 +.Pq bad or missing certificate +The certificate is missing, corrupted or bogus. +.It 114 +.Pq bad or missing identity +The identity key is missing, corrupt or bogus. +.El +.Sh Monitoring Support +.Xr ntpd @NTPD_MS@ +includes a comprehensive monitoring facility suitable +for continuous, long term recording of server and client +timekeeping performance. +See the +.Ic statistics +command below +for a listing and example of each type of statistics currently +supported. +Statistic files are managed using file generation sets +and scripts in the +.Pa ./scripts +directory of this distribution. +Using +these facilities and +.Ux +.Xr cron 8 +jobs, the data can be +automatically summarized and archived for retrospective analysis. +.Ss Monitoring Commands +.Bl -tag -width indent +.It Ic statistics Ar name ... +Enables writing of statistics records. +Currently, eight kinds of +.Ar name +statistics are supported. +.Bl -tag -width indent +.It Cm clockstats +Enables recording of clock driver statistics information. +Each update +received from a clock driver appends a line of the following form to +the file generation set named +.Cm clockstats : +.Bd -literal +49213 525.624 127.127.4.1 93 226 00:08:29.606 D +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the +clock address in dotted\-quad notation. +The final field shows the last +timecode received from the clock in decoded ASCII format, where +meaningful. +In some clock drivers a good deal of additional information +can be gathered and displayed as well. +See information specific to each +clock for further details. +.It Cm cryptostats +This option requires the OpenSSL cryptographic software library. +It +enables recording of cryptographic public key protocol information. +Each message received by the protocol module appends a line of the +following form to the file generation set named +.Cm cryptostats : +.Bd -literal +49213 525.624 127.127.4.1 message +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The next field shows the peer +address in dotted\-quad notation, The final message field includes the +message type and certain ancillary information. +See the +.Sx Authentication Options +section for further information. +.It Cm loopstats +Enables recording of loop filter statistics information. +Each +update of the local clock outputs a line of the following form to +the file generation set named +.Cm loopstats : +.Bd -literal +50935 75440.031 0.000006019 13.778190 0.000351733 0.0133806 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next five fields +show time offset (seconds), frequency offset (parts per million \- +PPM), RMS jitter (seconds), Allan deviation (PPM) and clock +discipline time constant. +.It Cm peerstats +Enables recording of peer statistics information. +This includes +statistics records of all peers of a NTP server and of special +signals, where present and configured. +Each valid update appends a +line of the following form to the current element of a file +generation set named +.Cm peerstats : +.Bd -literal +48773 10847.650 127.127.4.1 9714 \-0.001605376 0.000000000 0.001424877 0.000958674 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the peer address in dotted\-quad notation and status, +respectively. +The status field is encoded in hex in the format +described in Appendix A of the NTP specification RFC 1305. +The final four fields show the offset, +delay, dispersion and RMS jitter, all in seconds. +.It Cm rawstats +Enables recording of raw\-timestamp statistics information. +This +includes statistics records of all peers of a NTP server and of +special signals, where present and configured. +Each NTP message +received from a peer or clock driver appends a line of the +following form to the file generation set named +.Cm rawstats : +.Bd -literal +50928 2132.543 128.4.1.1 128.4.1.20 3102453281.584327000 3102453281.58622800031 02453332.540806000 3102453332.541458000 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and +time (seconds and fraction past UTC midnight). +The next two fields +show the remote peer or clock address followed by the local address +in dotted\-quad notation. +The final four fields show the originate, +receive, transmit and final NTP timestamps in order. +The timestamp +values are as received and before processing by the various data +smoothing and mitigation algorithms. +.It Cm sysstats +Enables recording of ntpd statistics counters on a periodic basis. +Each +hour a line of the following form is appended to the file generation +set named +.Cm sysstats : +.Bd -literal +50928 2132.543 36000 81965 0 9546 56 71793 512 540 10 147 +.Ed +.Pp +The first two fields show the date (Modified Julian Day) and time +(seconds and fraction past UTC midnight). +The remaining ten fields show +the statistics counter values accumulated since the last generated +line. +.Bl -tag -width indent +.It Time since restart Cm 36000 +Time in hours since the system was last rebooted. +.It Packets received Cm 81965 +Total number of packets received. +.It Packets processed Cm 0 +Number of packets received in response to previous packets sent +.It Current version Cm 9546 +Number of packets matching the current NTP version. +.It Previous version Cm 56 +Number of packets matching the previous NTP version. +.It Bad version Cm 71793 +Number of packets matching neither NTP version. +.It Access denied Cm 512 +Number of packets denied access for any reason. +.It Bad length or format Cm 540 +Number of packets with invalid length, format or port number. +.It Bad authentication Cm 10 +Number of packets not verified as authentic. +.It Rate exceeded Cm 147 +Number of packets discarded due to rate limitation. +.El +.It Cm statsdir Ar directory_path +Indicates the full path of a directory where statistics files +should be created (see below). +This keyword allows +the (otherwise constant) +.Cm filegen +filename prefix to be modified for file generation sets, which +is useful for handling statistics logs. +.It Cm filegen Ar name Xo +.Op Cm file Ar filename +.Op Cm type Ar typename +.Op Cm link | nolink +.Op Cm enable | disable +.Xc +Configures setting of generation file set name. +Generation +file sets provide a means for handling files that are +continuously growing during the lifetime of a server. +Server statistics are a typical example for such files. +Generation file sets provide access to a set of files used +to store the actual data. +At any time at most one element +of the set is being written to. +The type given specifies +when and how data will be directed to a new element of the set. +This way, information stored in elements of a file set +that are currently unused are available for administrational +operations without the risk of disturbing the operation of ntpd. +(Most important: they can be removed to free space for new data +produced.) +.Pp +Note that this command can be sent from the +.Xr ntpdc @NTPDC_MS@ +program running at a remote location. +.Bl -tag -width indent +.It Cm name +This is the type of the statistics records, as shown in the +.Cm statistics +command. +.It Cm file Ar filename +This is the file name for the statistics records. +Filenames of set +members are built from three concatenated elements +.Ar Cm prefix , +.Ar Cm filename +and +.Ar Cm suffix : +.Bl -tag -width indent +.It Cm prefix +This is a constant filename path. +It is not subject to +modifications via the +.Ar filegen +option. +It is defined by the +server, usually specified as a compile\-time constant. +It may, +however, be configurable for individual file generation sets +via other commands. +For example, the prefix used with +.Ar loopstats +and +.Ar peerstats +generation can be configured using the +.Ar statsdir +option explained above. +.It Cm filename +This string is directly concatenated to the prefix mentioned +above (no intervening +.Ql / ) . +This can be modified using +the file argument to the +.Ar filegen +statement. +No +.Pa .. +elements are +allowed in this component to prevent filenames referring to +parts outside the filesystem hierarchy denoted by +.Ar prefix . +.It Cm suffix +This part is reflects individual elements of a file set. +It is +generated according to the type of a file set. +.El +.It Cm type Ar typename +A file generation set is characterized by its type. +The following +types are supported: +.Bl -tag -width indent +.It Cm none +The file set is actually a single plain file. +.It Cm pid +One element of file set is used per incarnation of a ntpd +server. +This type does not perform any changes to file set +members during runtime, however it provides an easy way of +separating files belonging to different +.Xr ntpd @NTPD_MS@ +server incarnations. +The set member filename is built by appending a +.Ql \&. +to concatenated +.Ar prefix +and +.Ar filename +strings, and +appending the decimal representation of the process ID of the +.Xr ntpd @NTPD_MS@ +server process. +.It Cm day +One file generation set element is created per day. +A day is +defined as the period between 00:00 and 24:00 UTC. +The file set +member suffix consists of a +.Ql \&. +and a day specification in +the form +.Cm YYYYMMdd . +.Cm YYYY +is a 4\-digit year number (e.g., 1992). +.Cm MM +is a two digit month number. +.Cm dd +is a two digit day number. +Thus, all information written at 10 December 1992 would end up +in a file named +.Ar prefix +.Ar filename Ns .19921210 . +.It Cm week +Any file set member contains data related to a certain week of +a year. +The term week is defined by computing day\-of\-year +modulo 7. +Elements of such a file generation set are +distinguished by appending the following suffix to the file set +filename base: A dot, a 4\-digit year number, the letter +.Cm W , +and a 2\-digit week number. +For example, information from January, +10th 1992 would end up in a file with suffix +.No . Ns Ar 1992W1 . +.It Cm month +One generation file set element is generated per month. +The +file name suffix consists of a dot, a 4\-digit year number, and +a 2\-digit month. +.It Cm year +One generation file element is generated per year. +The filename +suffix consists of a dot and a 4 digit year number. +.It Cm age +This type of file generation sets changes to a new element of +the file set every 24 hours of server operation. +The filename +suffix consists of a dot, the letter +.Cm a , +and an 8\-digit number. +This number is taken to be the number of seconds the server is +running at the start of the corresponding 24\-hour period. +Information is only written to a file generation by specifying +.Cm enable ; +output is prevented by specifying +.Cm disable . +.El +.It Cm link | nolink +It is convenient to be able to access the current element of a file +generation set by a fixed name. +This feature is enabled by +specifying +.Cm link +and disabled using +.Cm nolink . +If link is specified, a +hard link from the current file set element to a file without +suffix is created. +When there is already a file with this name and +the number of links of this file is one, it is renamed appending a +dot, the letter +.Cm C , +and the pid of the ntpd server process. +When the +number of links is greater than one, the file is unlinked. +This +allows the current file to be accessed by a constant name. +.It Cm enable \&| Cm disable +Enables or disables the recording function. +.El +.El +.El +.Sh Access Control Support +The +.Xr ntpd @NTPD_MS@ +daemon implements a general purpose address/mask based restriction +list. +The list contains address/match entries sorted first +by increasing address values and and then by increasing mask values. +A match occurs when the bitwise AND of the mask and the packet +source address is equal to the bitwise AND of the mask and +address in the list. +The list is searched in order with the +last match found defining the restriction flags associated +with the entry. +Additional information and examples can be found in the +.Qq Notes on Configuring NTP and Setting up a NTP Subnet +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Pp +The restriction facility was implemented in conformance +with the access policies for the original NSFnet backbone +time servers. +Later the facility was expanded to deflect +cryptographic and clogging attacks. +While this facility may +be useful for keeping unwanted or broken or malicious clients +from congesting innocent servers, it should not be considered +an alternative to the NTP authentication facilities. +Source address based restrictions are easily circumvented +by a determined cracker. +.Pp +Clients can be denied service because they are explicitly +included in the restrict list created by the restrict command +or implicitly as the result of cryptographic or rate limit +violations. +Cryptographic violations include certificate +or identity verification failure; rate limit violations generally +result from defective NTP implementations that send packets +at abusive rates. +Some violations cause denied service +only for the offending packet, others cause denied service +for a timed period and others cause the denied service for +an indefinate period. +When a client or network is denied access +for an indefinate period, the only way at present to remove +the restrictions is by restarting the server. +.Ss The Kiss\-of\-Death Packet +Ordinarily, packets denied service are simply dropped with no +further action except incrementing statistics counters. +Sometimes a +more proactive response is needed, such as a server message that +explicitly requests the client to stop sending and leave a message +for the system operator. +A special packet format has been created +for this purpose called the "kiss\-of\-death" (KoD) packet. +KoD packets have the leap bits set unsynchronized and stratum set +to zero and the reference identifier field set to a four\-byte +ASCII code. +If the +.Cm noserve +or +.Cm notrust +flag of the matching restrict list entry is set, +the code is "DENY"; if the +.Cm limited +flag is set and the rate limit +is exceeded, the code is "RATE". +Finally, if a cryptographic violation occurs, the code is "CRYP". +.Pp +A client receiving a KoD performs a set of sanity checks to +minimize security exposure, then updates the stratum and +reference identifier peer variables, sets the access +denied (TEST4) bit in the peer flash variable and sends +a message to the log. +As long as the TEST4 bit is set, +the client will send no further packets to the server. +The only way at present to recover from this condition is +to restart the protocol at both the client and server. +This +happens automatically at the client when the association times out. +It will happen at the server only if the server operator cooperates. +.Ss Access Control Commands +.Bl -tag -width indent +.It Xo Ic discard +.Op Cm average Ar avg +.Op Cm minimum Ar min +.Op Cm monitor Ar prob +.Xc +Set the parameters of the +.Cm limited +facility which protects the server from +client abuse. +The +.Cm average +subcommand specifies the minimum average packet +spacing, while the +.Cm minimum +subcommand specifies the minimum packet spacing. +Packets that violate these minima are discarded +and a kiss\-o'\-death packet returned if enabled. +The default +minimum average and minimum are 5 and 2, respectively. +The monitor subcommand specifies the probability of discard +for packets that overflow the rate\-control window. +.It Xo Ic restrict address +.Op Cm mask Ar mask +.Op Ar flag ... +.Xc +The +.Ar address +argument expressed in +dotted\-quad form is the address of a host or network. +Alternatively, the +.Ar address +argument can be a valid host DNS name. +The +.Ar mask +argument expressed in dotted\-quad form defaults to +.Cm 255.255.255.255 , +meaning that the +.Ar address +is treated as the address of an individual host. +A default entry (address +.Cm 0.0.0.0 , +mask +.Cm 0.0.0.0 ) +is always included and is always the first entry in the list. +Note that text string +.Cm default , +with no mask option, may +be used to indicate the default entry. +In the current implementation, +.Cm flag +always +restricts access, i.e., an entry with no flags indicates that free +access to the server is to be given. +The flags are not orthogonal, +in that more restrictive flags will often make less restrictive +ones redundant. +The flags can generally be classed into two +categories, those which restrict time service and those which +restrict informational queries and attempts to do run\-time +reconfiguration of the server. +One or more of the following flags +may be specified: +.Bl -tag -width indent +.It Cm ignore +Deny packets of all kinds, including +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +queries. +.It Cm kod +If this flag is set when an access violation occurs, a kiss\-o'\-death +(KoD) packet is sent. +KoD packets are rate limited to no more than one +per second. +If another KoD packet occurs within one second after the +last one, the packet is dropped. +.It Cm limited +Deny service if the packet spacing violates the lower limits specified +in the discard command. +A history of clients is kept using the +monitoring capability of +.Xr ntpd @NTPD_MS@ . +Thus, monitoring is always active as +long as there is a restriction entry with the +.Cm limited +flag. +.It Cm lowpriotrap +Declare traps set by matching hosts to be low priority. +The +number of traps a server can maintain is limited (the current limit +is 3). +Traps are usually assigned on a first come, first served +basis, with later trap requestors being denied service. +This flag +modifies the assignment algorithm by allowing low priority traps to +be overridden by later requests for normal priority traps. +.It Cm nomodify +Deny +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +queries which attempt to modify the state of the +server (i.e., run time reconfiguration). +Queries which return +information are permitted. +.It Cm noquery +Deny +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +queries. +Time service is not affected. +.It Cm nopeer +Deny packets which would result in mobilizing a new association. +This +includes broadcast and symmetric active packets when a configured +association does not exist. +It also includes +.Cm pool +associations, so if you want to use servers from a +.Cm pool +directive and also want to use +.Cm nopeer +by default, you'll want a +.Cm "restrict source ..." line as well that does +.It not +include the +.Cm nopeer +directive. +.It Cm noserve +Deny all packets except +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +queries. +.It Cm notrap +Decline to provide mode 6 control message trap service to matching +hosts. +The trap service is a subsystem of the ntpdq control message +protocol which is intended for use by remote event logging programs. +.It Cm notrust +Deny service unless the packet is cryptographically authenticated. +.It Cm ntpport +This is actually a match algorithm modifier, rather than a +restriction flag. +Its presence causes the restriction entry to be +matched only if the source port in the packet is the standard NTP +UDP port (123). +Both +.Cm ntpport +and +.Cm non\-ntpport +may +be specified. +The +.Cm ntpport +is considered more specific and +is sorted later in the list. +.It Cm version +Deny packets that do not match the current NTP version. +.El +.Pp +Default restriction list entries with the flags ignore, interface, +ntpport, for each of the local host's interface addresses are +inserted into the table at startup to prevent the server +from attempting to synchronize to its own time. +A default entry is also always present, though if it is +otherwise unconfigured; no flags are associated +with the default entry (i.e., everything besides your own +NTP server is unrestricted). +.El +.Sh Automatic NTP Configuration Options +.Ss Manycasting +Manycasting is a automatic discovery and configuration paradigm +new to NTPv4. +It is intended as a means for a multicast client +to troll the nearby network neighborhood to find cooperating +manycast servers, validate them using cryptographic means +and evaluate their time values with respect to other servers +that might be lurking in the vicinity. +The intended result is that each manycast client mobilizes +client associations with some number of the "best" +of the nearby manycast servers, yet automatically reconfigures +to sustain this number of servers should one or another fail. +.Pp +Note that the manycasting paradigm does not coincide +with the anycast paradigm described in RFC\-1546, +which is designed to find a single server from a clique +of servers providing the same service. +The manycast paradigm is designed to find a plurality +of redundant servers satisfying defined optimality criteria. +.Pp +Manycasting can be used with either symmetric key +or public key cryptography. +The public key infrastructure (PKI) +offers the best protection against compromised keys +and is generally considered stronger, at least with relatively +large key sizes. +It is implemented using the Autokey protocol and +the OpenSSL cryptographic library available from +.Li http://www.openssl.org/ . +The library can also be used with other NTPv4 modes +as well and is highly recommended, especially for broadcast modes. +.Pp +A persistent manycast client association is configured +using the manycastclient command, which is similar to the +server command but with a multicast (IPv4 class +.Cm D +or IPv6 prefix +.Cm FF ) +group address. +The IANA has designated IPv4 address 224.1.1.1 +and IPv6 address FF05::101 (site local) for NTP. +When more servers are needed, it broadcasts manycast +client messages to this address at the minimum feasible rate +and minimum feasible time\-to\-live (TTL) hops, depending +on how many servers have already been found. +There can be as many manycast client associations +as different group address, each one serving as a template +for a future ephemeral unicast client/server association. +.Pp +Manycast servers configured with the +.Ic manycastserver +command listen on the specified group address for manycast +client messages. +Note the distinction between manycast client, +which actively broadcasts messages, and manycast server, +which passively responds to them. +If a manycast server is +in scope of the current TTL and is itself synchronized +to a valid source and operating at a stratum level equal +to or lower than the manycast client, it replies to the +manycast client message with an ordinary unicast server message. +.Pp +The manycast client receiving this message mobilizes +an ephemeral client/server association according to the +matching manycast client template, but only if cryptographically +authenticated and the server stratum is less than or equal +to the client stratum. +Authentication is explicitly required +and either symmetric key or public key (Autokey) can be used. +Then, the client polls the server at its unicast address +in burst mode in order to reliably set the host clock +and validate the source. +This normally results +in a volley of eight client/server at 2\-s intervals +during which both the synchronization and cryptographic +protocols run concurrently. +Following the volley, +the client runs the NTP intersection and clustering +algorithms, which act to discard all but the "best" +associations according to stratum and synchronization +distance. +The surviving associations then continue +in ordinary client/server mode. +.Pp +The manycast client polling strategy is designed to reduce +as much as possible the volume of manycast client messages +and the effects of implosion due to near\-simultaneous +arrival of manycast server messages. +The strategy is determined by the +.Ic manycastclient , +.Ic tos +and +.Ic ttl +configuration commands. +The manycast poll interval is +normally eight times the system poll interval, +which starts out at the +.Cm minpoll +value specified in the +.Ic manycastclient , +command and, under normal circumstances, increments to the +.Cm maxpolll +value specified in this command. +Initially, the TTL is +set at the minimum hops specified by the ttl command. +At each retransmission the TTL is increased until reaching +the maximum hops specified by this command or a sufficient +number client associations have been found. +Further retransmissions use the same TTL. +.Pp +The quality and reliability of the suite of associations +discovered by the manycast client is determined by the NTP +mitigation algorithms and the +.Cm minclock +and +.Cm minsane +values specified in the +.Ic tos +configuration command. +At least +.Cm minsane +candidate servers must be available and the mitigation +algorithms produce at least +.Cm minclock +survivors in order to synchronize the clock. +Byzantine agreement principles require at least four +candidates in order to correctly discard a single falseticker. +For legacy purposes, +.Cm minsane +defaults to 1 and +.Cm minclock +defaults to 3. +For manycast service +.Cm minsane +should be explicitly set to 4, assuming at least that +number of servers are available. +.Pp +If at least +.Cm minclock +servers are found, the manycast poll interval is immediately +set to eight times +.Cm maxpoll . +If less than +.Cm minclock +servers are found when the TTL has reached the maximum hops, +the manycast poll interval is doubled. +For each transmission +after that, the poll interval is doubled again until +reaching the maximum of eight times +.Cm maxpoll . +Further transmissions use the same poll interval and +TTL values. +Note that while all this is going on, +each client/server association found is operating normally +it the system poll interval. +.Pp +Administratively scoped multicast boundaries are normally +specified by the network router configuration and, +in the case of IPv6, the link/site scope prefix. +By default, the increment for TTL hops is 32 starting +from 31; however, the +.Ic ttl +configuration command can be +used to modify the values to match the scope rules. +.Pp +It is often useful to narrow the range of acceptable +servers which can be found by manycast client associations. +Because manycast servers respond only when the client +stratum is equal to or greater than the server stratum, +primary (stratum 1) servers fill find only primary servers +in TTL range, which is probably the most common objective. +However, unless configured otherwise, all manycast clients +in TTL range will eventually find all primary servers +in TTL range, which is probably not the most common +objective in large networks. +The +.Ic tos +command can be used to modify this behavior. +Servers with stratum below +.Cm floor +or above +.Cm ceiling +specified in the +.Ic tos +command are strongly discouraged during the selection +process; however, these servers may be temporally +accepted if the number of servers within TTL range is +less than +.Cm minclock . +.Pp +The above actions occur for each manycast client message, +which repeats at the designated poll interval. +However, once the ephemeral client association is mobilized, +subsequent manycast server replies are discarded, +since that would result in a duplicate association. +If during a poll interval the number of client associations +falls below +.Cm minclock , +all manycast client prototype associations are reset +to the initial poll interval and TTL hops and operation +resumes from the beginning. +It is important to avoid +frequent manycast client messages, since each one requires +all manycast servers in TTL range to respond. +The result could well be an implosion, either minor or major, +depending on the number of servers in range. +The recommended value for +.Cm maxpoll +is 12 (4,096 s). +.Pp +It is possible and frequently useful to configure a host +as both manycast client and manycast server. +A number of hosts configured this way and sharing a common +group address will automatically organize themselves +in an optimum configuration based on stratum and +synchronization distance. +For example, consider an NTP +subnet of two primary servers and a hundred or more +dependent clients. +With two exceptions, all servers +and clients have identical configuration files including both +.Ic multicastclient +and +.Ic multicastserver +commands using, for instance, multicast group address +239.1.1.1. +The only exception is that each primary server +configuration file must include commands for the primary +reference source such as a GPS receiver. +.Pp +The remaining configuration files for all secondary +servers and clients have the same contents, except for the +.Ic tos +command, which is specific for each stratum level. +For stratum 1 and stratum 2 servers, that command is +not necessary. +For stratum 3 and above servers the +.Cm floor +value is set to the intended stratum number. +Thus, all stratum 3 configuration files are identical, +all stratum 4 files are identical and so forth. +.Pp +Once operations have stabilized in this scenario, +the primary servers will find the primary reference source +and each other, since they both operate at the same +stratum (1), but not with any secondary server or client, +since these operate at a higher stratum. +The secondary +servers will find the servers at the same stratum level. +If one of the primary servers loses its GPS receiver, +it will continue to operate as a client and other clients +will time out the corresponding association and +re\-associate accordingly. +.Pp +Some administrators prefer to avoid running +.Xr ntpd @NTPD_MS@ +continuously and run either +.Xr sntp @SNTP_MS@ +or +.Xr ntpd @NTPD_MS@ +.Fl q +as a cron job. +In either case the servers must be +configured in advance and the program fails if none are +available when the cron job runs. +A really slick +application of manycast is with +.Xr ntpd @NTPD_MS@ +.Fl q . +The program wakes up, scans the local landscape looking +for the usual suspects, selects the best from among +the rascals, sets the clock and then departs. +Servers do not have to be configured in advance and +all clients throughout the network can have the same +configuration file. +.Ss Manycast Interactions with Autokey +Each time a manycast client sends a client mode packet +to a multicast group address, all manycast servers +in scope generate a reply including the host name +and status word. +The manycast clients then run +the Autokey protocol, which collects and verifies +all certificates involved. +Following the burst interval +all but three survivors are cast off, +but the certificates remain in the local cache. +It often happens that several complete signing trails +from the client to the primary servers are collected in this way. +.Pp +About once an hour or less often if the poll interval +exceeds this, the client regenerates the Autokey key list. +This is in general transparent in client/server mode. +However, about once per day the server private value +used to generate cookies is refreshed along with all +manycast client associations. +In this case all +cryptographic values including certificates is refreshed. +If a new certificate has been generated since +the last refresh epoch, it will automatically revoke +all prior certificates that happen to be in the +certificate cache. +At the same time, the manycast +scheme starts all over from the beginning and +the expanding ring shrinks to the minimum and increments +from there while collecting all servers in scope. +.Ss Manycast Options +.Bl -tag -width indent +.It Xo Ic tos +.Oo +.Cm ceiling Ar ceiling | +.Cm cohort { 0 | 1 } | +.Cm floor Ar floor | +.Cm minclock Ar minclock | +.Cm minsane Ar minsane +.Oc +.Xc +This command affects the clock selection and clustering +algorithms. +It can be used to select the quality and +quantity of peers used to synchronize the system clock +and is most useful in manycast mode. +The variables operate +as follows: +.Bl -tag -width indent +.It Cm ceiling Ar ceiling +Peers with strata above +.Cm ceiling +will be discarded if there are at least +.Cm minclock +peers remaining. +This value defaults to 15, but can be changed +to any number from 1 to 15. +.It Cm cohort Bro 0 | 1 Brc +This is a binary flag which enables (0) or disables (1) +manycast server replies to manycast clients with the same +stratum level. +This is useful to reduce implosions where +large numbers of clients with the same stratum level +are present. +The default is to enable these replies. +.It Cm floor Ar floor +Peers with strata below +.Cm floor +will be discarded if there are at least +.Cm minclock +peers remaining. +This value defaults to 1, but can be changed +to any number from 1 to 15. +.It Cm minclock Ar minclock +The clustering algorithm repeatedly casts out outlier +associations until no more than +.Cm minclock +associations remain. +This value defaults to 3, +but can be changed to any number from 1 to the number of +configured sources. +.It Cm minsane Ar minsane +This is the minimum number of candidates available +to the clock selection algorithm in order to produce +one or more truechimers for the clustering algorithm. +If fewer than this number are available, the clock is +undisciplined and allowed to run free. +The default is 1 +for legacy purposes. +However, according to principles of +Byzantine agreement, +.Cm minsane +should be at least 4 in order to detect and discard +a single falseticker. +.El +.It Cm ttl Ar hop ... +This command specifies a list of TTL values in increasing +order, up to 8 values can be specified. +In manycast mode these values are used in turn +in an expanding\-ring search. +The default is eight +multiples of 32 starting at 31. +.El +.Sh Reference Clock Support +The NTP Version 4 daemon supports some three dozen different radio, +satellite and modem reference clocks plus a special pseudo\-clock +used for backup or when no other clock source is available. +Detailed descriptions of individual device drivers and options can +be found in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +Additional information can be found in the pages linked +there, including the +.Qq Debugging Hints for Reference Clock Drivers +and +.Qq How To Write a Reference Clock Driver +pages +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +In addition, support for a PPS +signal is available as described in the +.Qq Pulse\-per\-second (PPS) Signal Interfacing +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +Many +drivers support special line discipline/streams modules which can +significantly improve the accuracy using the driver. +These are +described in the +.Qq Line Disciplines and Streams Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.Pp +A reference clock will generally (though not always) be a radio +timecode receiver which is synchronized to a source of standard +time such as the services offered by the NRC in Canada and NIST and +USNO in the US. +The interface between the computer and the timecode +receiver is device dependent, but is usually a serial port. +A +device driver specific to each reference clock must be selected and +compiled in the distribution; however, most common radio, satellite +and modem clocks are included by default. +Note that an attempt to +configure a reference clock when the driver has not been compiled +or the hardware port has not been appropriately configured results +in a scalding remark to the system log file, but is otherwise non +hazardous. +.Pp +For the purposes of configuration, +.Xr ntpd @NTPD_MS@ +treats +reference clocks in a manner analogous to normal NTP peers as much +as possible. +Reference clocks are identified by a syntactically +correct but invalid IP address, in order to distinguish them from +normal NTP peers. +Reference clock addresses are of the form +.Sm off +.Li 127.127. Ar t . Ar u , +.Sm on +where +.Ar t +is an integer +denoting the clock type and +.Ar u +indicates the unit +number in the range 0\-3. +While it may seem overkill, it is in fact +sometimes useful to configure multiple reference clocks of the same +type, in which case the unit numbers must be unique. +.Pp +The +.Ic server +command is used to configure a reference +clock, where the +.Ar address +argument in that command +is the clock address. +The +.Cm key , +.Cm version +and +.Cm ttl +options are not used for reference clock support. +The +.Cm mode +option is added for reference clock support, as +described below. +The +.Cm prefer +option can be useful to +persuade the server to cherish a reference clock with somewhat more +enthusiasm than other reference clocks or peers. +Further +information on this option can be found in the +.Qq Mitigation Rules and the prefer Keyword +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +page. +The +.Cm minpoll +and +.Cm maxpoll +options have +meaning only for selected clock drivers. +See the individual clock +driver document pages for additional information. +.Pp +The +.Ic fudge +command is used to provide additional +information for individual clock drivers and normally follows +immediately after the +.Ic server +command. +The +.Ar address +argument specifies the clock address. +The +.Cm refid +and +.Cm stratum +options can be used to +override the defaults for the device. +There are two optional +device\-dependent time offsets and four flags that can be included +in the +.Ic fudge +command as well. +.Pp +The stratum number of a reference clock is by default zero. +Since the +.Xr ntpd @NTPD_MS@ +daemon adds one to the stratum of each +peer, a primary server ordinarily displays an external stratum of +one. +In order to provide engineered backups, it is often useful to +specify the reference clock stratum as greater than zero. +The +.Cm stratum +option is used for this purpose. +Also, in cases +involving both a reference clock and a pulse\-per\-second (PPS) +discipline signal, it is useful to specify the reference clock +identifier as other than the default, depending on the driver. +The +.Cm refid +option is used for this purpose. +Except where noted, +these options apply to all clock drivers. +.Ss Reference Clock Commands +.Bl -tag -width indent +.It Xo Ic server +.Sm off +.Li 127.127. Ar t . Ar u +.Sm on +.Op Cm prefer +.Op Cm mode Ar int +.Op Cm minpoll Ar int +.Op Cm maxpoll Ar int +.Xc +This command can be used to configure reference clocks in +special ways. +The options are interpreted as follows: +.Bl -tag -width indent +.It Cm prefer +Marks the reference clock as preferred. +All other things being +equal, this host will be chosen for synchronization among a set of +correctly operating hosts. +See the +.Qq Mitigation Rules and the prefer Keyword +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +for further information. +.It Cm mode Ar int +Specifies a mode number which is interpreted in a +device\-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.It Cm minpoll Ar int +.It Cm maxpoll Ar int +These options specify the minimum and maximum polling interval +for reference clock messages, as a power of 2 in seconds +For +most directly connected reference clocks, both +.Cm minpoll +and +.Cm maxpoll +default to 6 (64 s). +For modem reference clocks, +.Cm minpoll +defaults to 10 (17.1 m) and +.Cm maxpoll +defaults to 14 (4.5 h). +The allowable range is 4 (16 s) to 17 (36.4 h) inclusive. +.El +.It Xo Ic fudge +.Sm off +.Li 127.127. Ar t . Ar u +.Sm on +.Op Cm time1 Ar sec +.Op Cm time2 Ar sec +.Op Cm stratum Ar int +.Op Cm refid Ar string +.Op Cm mode Ar int +.Op Cm flag1 Cm 0 \&| Cm 1 +.Op Cm flag2 Cm 0 \&| Cm 1 +.Op Cm flag3 Cm 0 \&| Cm 1 +.Op Cm flag4 Cm 0 \&| Cm 1 +.Xc +This command can be used to configure reference clocks in +special ways. +It must immediately follow the +.Ic server +command which configures the driver. +Note that the same capability +is possible at run time using the +.Xr ntpdc @NTPDC_MS@ +program. +The options are interpreted as +follows: +.Bl -tag -width indent +.It Cm time1 Ar sec +Specifies a constant to be added to the time offset produced by +the driver, a fixed\-point decimal number in seconds. +This is used +as a calibration constant to adjust the nominal time offset of a +particular clock to agree with an external standard, such as a +precision PPS signal. +It also provides a way to correct a +systematic error or bias due to serial port or operating system +latencies, different cable lengths or receiver internal delay. +The +specified offset is in addition to the propagation delay provided +by other means, such as internal DIPswitches. +Where a calibration +for an individual system and driver is available, an approximate +correction is noted in the driver documentation pages. +Note: in order to facilitate calibration when more than one +radio clock or PPS signal is supported, a special calibration +feature is available. +It takes the form of an argument to the +.Ic enable +command described in +.Sx Miscellaneous Options +page and operates as described in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.It Cm time2 Ar secs +Specifies a fixed\-point decimal number in seconds, which is +interpreted in a driver\-dependent way. +See the descriptions of +specific drivers in the +.Qq Reference Clock Drivers +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +.It Cm stratum Ar int +Specifies the stratum number assigned to the driver, an integer +between 0 and 15. +This number overrides the default stratum number +ordinarily assigned by the driver itself, usually zero. +.It Cm refid Ar string +Specifies an ASCII string of from one to four characters which +defines the reference identifier used by the driver. +This string +overrides the default identifier ordinarily assigned by the driver +itself. +.It Cm mode Ar int +Specifies a mode number which is interpreted in a +device\-specific fashion. +For instance, it selects a dialing +protocol in the ACTS driver and a device subtype in the +parse +drivers. +.It Cm flag1 Cm 0 \&| Cm 1 +.It Cm flag2 Cm 0 \&| Cm 1 +.It Cm flag3 Cm 0 \&| Cm 1 +.It Cm flag4 Cm 0 \&| Cm 1 +These four flags are used for customizing the clock driver. +The +interpretation of these values, and whether they are used at all, +is a function of the particular clock driver. +However, by +convention +.Cm flag4 +is used to enable recording monitoring +data to the +.Cm clockstats +file configured with the +.Ic filegen +command. +Further information on the +.Ic filegen +command can be found in +.Sx Monitoring Options . +.El +.El +.Sh Miscellaneous Options +.Bl -tag -width indent +.It Ic broadcastdelay Ar seconds +The broadcast and multicast modes require a special calibration +to determine the network delay between the local and remote +servers. +Ordinarily, this is done automatically by the initial +protocol exchanges between the client and server. +In some cases, +the calibration procedure may fail due to network or server access +controls, for example. +This command specifies the default delay to +be used under these circumstances. +Typically (for Ethernet), a +number between 0.003 and 0.007 seconds is appropriate. +The default +when this command is not used is 0.004 seconds. +.It Ic calldelay Ar delay +This option controls the delay in seconds between the first and second +packets sent in burst or iburst mode to allow additional time for a modem +or ISDN call to complete. +.It Ic driftfile Ar driftfile +This command specifies the complete path and name of the file used to +record the frequency of the local clock oscillator. +This is the same +operation as the +.Fl f +command line option. +If the file exists, it is read at +startup in order to set the initial frequency and then updated once per +hour with the current frequency computed by the daemon. +If the file name is +specified, but the file itself does not exist, the starts with an initial +frequency of zero and creates the file when writing it for the first time. +If this command is not given, the daemon will always start with an initial +frequency of zero. +.Pp +The file format consists of a single line containing a single +floating point number, which records the frequency offset measured +in parts\-per\-million (PPM). +The file is updated by first writing +the current drift value into a temporary file and then renaming +this file to replace the old version. +This implies that +.Xr ntpd @NTPD_MS@ +must have write permission for the directory the +drift file is located in, and that file system links, symbolic or +otherwise, should be avoided. +.It Ic dscp Ar value +This option specifies the Differentiated Services Control Point (DSCP) value, +a 6\-bit code. The default value is 46, signifying Expedited Forwarding. +.It Xo Ic enable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm mode7 | monitor | +.Cm ntp | Cm stats +.Oc +.Xc +.It Xo Ic disable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm mode7 | monitor | +.Cm ntp | Cm stats +.Oc +.Xc +Provides a way to enable or disable various server options. +Flags not mentioned are unaffected. +Note that all of these flags +can be controlled remotely using the +.Xr ntpdc @NTPDC_MS@ +utility program. +.Bl -tag -width indent +.It Cm auth +Enables the server to synchronize with unconfigured peers only if the +peer has been correctly authenticated using either public key or +private key cryptography. +The default for this flag is +.Ic enable . +.It Cm bclient +Enables the server to listen for a message from a broadcast or +multicast server, as in the +.Ic multicastclient +command with default +address. +The default for this flag is +.Ic disable . +.It Cm calibrate +Enables the calibrate feature for reference clocks. +The default for +this flag is +.Ic disable . +.It Cm kernel +Enables the kernel time discipline, if available. +The default for this +flag is +.Ic enable +if support is available, otherwise +.Ic disable . +.It Cm mode7 +Enables processing of NTP mode 7 implementation\-specific requests +which are used by the deprecated +.Xr ntpdc @NTPDC_MS@ +program. +The default for this flag is disable. +This flag is excluded from runtime configuration using +.Xr ntpq @NTPQ_MS@ . +The +.Xr ntpq @NTPQ_MS@ +program provides the same capabilities as +.Xr ntpdc @NTPDC_MS@ +using standard mode 6 requests. +.It Cm monitor +Enables the monitoring facility. +See the +.Xr ntpdc @NTPDC_MS@ +program +and the +.Ic monlist +command or further information. +The +default for this flag is +.Ic enable . +.It Cm ntp +Enables time and frequency discipline. +In effect, this switch opens and +closes the feedback loop, which is useful for testing. +The default for +this flag is +.Ic enable . +.It Cm stats +Enables the statistics facility. +See the +.Sx Monitoring Options +section for further information. +The default for this flag is +.Ic disable . +.El +.It Ic includefile Ar includefile +This command allows additional configuration commands +to be included from a separate file. +Include files may +be nested to a depth of five; upon reaching the end of any +include file, command processing resumes in the previous +configuration file. +This option is useful for sites that run +.Xr ntpd @NTPD_MS@ +on multiple hosts, with (mostly) common options (e.g., a +restriction list). +.It Ic leapsmearinterval Ar seconds +This EXPERIMENTAL option is only available if +.Xr ntpd @NTPD_MS@ +was built with the +.Cm \-\-enable\-leap\-smear +option to the +.Cm configure +script. +It specifies the interval over which a leap second correction will be applied. +Recommended values for this option are between +7200 (2 hours) and 86400 (24 hours). +.Sy DO NOT USE THIS OPTION ON PUBLIC\-ACCESS SERVERS! +See http://bugs.ntp.org/2855 for more information. +.It Ic logconfig Ar configkeyword +This command controls the amount and type of output written to +the system +.Xr syslog 3 +facility or the alternate +.Ic logfile +log file. +By default, all output is turned on. +All +.Ar configkeyword +keywords can be prefixed with +.Ql = , +.Ql + +and +.Ql \- , +where +.Ql = +sets the +.Xr syslog 3 +priority mask, +.Ql + +adds and +.Ql \- +removes +messages. +.Xr syslog 3 +messages can be controlled in four +classes +.Po +.Cm clock , +.Cm peer , +.Cm sys +and +.Cm sync +.Pc . +Within these classes four types of messages can be +controlled: informational messages +.Po +.Cm info +.Pc , +event messages +.Po +.Cm events +.Pc , +statistics messages +.Po +.Cm statistics +.Pc +and +status messages +.Po +.Cm status +.Pc . +.Pp +Configuration keywords are formed by concatenating the message class with +the event class. +The +.Cm all +prefix can be used instead of a message class. +A +message class may also be followed by the +.Cm all +keyword to enable/disable all +messages of the respective message class.Thus, a minimal log configuration +could look like this: +.Bd -literal +logconfig =syncstatus +sysevents +.Ed +.Pp +This would just list the synchronizations state of +.Xr ntpd @NTPD_MS@ +and the major system events. +For a simple reference server, the +following minimum message configuration could be useful: +.Bd -literal +logconfig =syncall +clockall +.Ed +.Pp +This configuration will list all clock information and +synchronization information. +All other events and messages about +peers, system events and so on is suppressed. +.It Ic logfile Ar logfile +This command specifies the location of an alternate log file to +be used instead of the default system +.Xr syslog 3 +facility. +This is the same operation as the \-l command line option. +.It Ic setvar Ar variable Op Cm default +This command adds an additional system variable. +These +variables can be used to distribute additional information such as +the access policy. +If the variable of the form +.Sm off +.Va name = Ar value +.Sm on +is followed by the +.Cm default +keyword, the +variable will be listed as part of the default system variables +.Po +.Xr ntpq @NTPQ_MS@ +.Ic rv +command +.Pc ) . +These additional variables serve +informational purposes only. +They are not related to the protocol +other that they can be listed. +The known protocol variables will +always override any variables defined via the +.Ic setvar +mechanism. +There are three special variables that contain the names +of all variable of the same group. +The +.Va sys_var_list +holds +the names of all system variables. +The +.Va peer_var_list +holds +the names of all peer variables and the +.Va clock_var_list +holds the names of the reference clock variables. +.It Xo Ic tinker +.Oo +.Cm allan Ar allan | +.Cm dispersion Ar dispersion | +.Cm freq Ar freq | +.Cm huffpuff Ar huffpuff | +.Cm panic Ar panic | +.Cm step Ar step | +.Cm stepback Ar stepback | +.Cm stepfwd Ar stepfwd | +.Cm stepout Ar stepout +.Oc +.Xc +This command can be used to alter several system variables in +very exceptional circumstances. +It should occur in the +configuration file before any other configuration options. +The +default values of these variables have been carefully optimized for +a wide range of network speeds and reliability expectations. +In +general, they interact in intricate ways that are hard to predict +and some combinations can result in some very nasty behavior. +Very +rarely is it necessary to change the default values; but, some +folks cannot resist twisting the knobs anyway and this command is +for them. +Emphasis added: twisters are on their own and can expect +no help from the support group. +.Pp +The variables operate as follows: +.Bl -tag -width indent +.It Cm allan Ar allan +The argument becomes the new value for the minimum Allan +intercept, which is a parameter of the PLL/FLL clock discipline +algorithm. +The value in log2 seconds defaults to 7 (1024 s), which is also the lower +limit. +.It Cm dispersion Ar dispersion +The argument becomes the new value for the dispersion increase rate, +normally .000015 s/s. +.It Cm freq Ar freq +The argument becomes the initial value of the frequency offset in +parts\-per\-million. +This overrides the value in the frequency file, if +present, and avoids the initial training state if it is not. +.It Cm huffpuff Ar huffpuff +The argument becomes the new value for the experimental +huff\-n'\-puff filter span, which determines the most recent interval +the algorithm will search for a minimum delay. +The lower limit is +900 s (15 m), but a more reasonable value is 7200 (2 hours). +There +is no default, since the filter is not enabled unless this command +is given. +.It Cm panic Ar panic +The argument is the panic threshold, normally 1000 s. +If set to zero, +the panic sanity check is disabled and a clock offset of any value will +be accepted. +.It Cm step Ar step +The argument is the step threshold, which by default is 0.128 s. +It can +be set to any positive number in seconds. +If set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if the step threshold is set to zero or greater than the +default. +.It Cm stepback Ar stepback +The argument is the step threshold for the backward direction, +which by default is 0.128 s. +It can +be set to any positive number in seconds. +If both the forward and backward step thresholds are set to zero, step +adjustments will never occur. +Note: The kernel time discipline is +disabled if +each direction of step threshold are either +set to zero or greater than .5 second. +.It Cm stepfwd Ar stepfwd +As for stepback, but for the forward direction. +.It Cm stepout Ar stepout +The argument is the stepout timeout, which by default is 900 s. +It can +be set to any positive number in seconds. +If set to zero, the stepout +pulses will not be suppressed. +.El +.It Xo Ic rlimit +.Oo +.Cm memlock Ar Nmegabytes | +.Cm stacksize Ar N4kPages +.Cm filenum Ar Nfiledescriptors +.Oc +.Xc +.Bl -tag -width indent +.It Cm memlock Ar Nmegabytes +Specify the number of megabytes of memory that should be +allocated and locked. +Probably only available under Linux, this option may be useful +when dropping root (the +.Fl i +option). +The default is 32 megabytes on non\-Linux machines, and \-1 under Linux. +-1 means "do not lock the process into memory". +0 means "lock whatever memory the process wants into memory". +.It Cm stacksize Ar N4kPages +Specifies the maximum size of the process stack on systems with the +.Fn mlockall +function. +Defaults to 50 4k pages (200 4k pages in OpenBSD). +.It Cm filenum Ar Nfiledescriptors +Specifies the maximum number of file descriptors ntpd may have open at once. Defaults to the system default. +.El +.It Xo Ic trap Ar host_address +.Op Cm port Ar port_number +.Op Cm interface Ar interface_address +.Xc +This command configures a trap receiver at the given host +address and port number for sending messages with the specified +local interface address. +If the port number is unspecified, a value +of 18447 is used. +If the interface address is not specified, the +message is sent with a source address of the local interface the +message is sent through. +Note that on a multihomed host the +interface used may vary from time to time with routing changes. +.Pp +The trap receiver will generally log event messages and other +information from the server in a log file. +While such monitor +programs may also request their own trap dynamically, configuring a +trap receiver will ensure that no messages are lost when the server +is started. +.It Cm hop Ar ... +This command specifies a list of TTL values in increasing order, up to 8 +values can be specified. +In manycast mode these values are used in turn in +an expanding\-ring search. +The default is eight multiples of 32 starting at +31. +.El +.Sh "OPTIONS" +.Bl -tag +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTP_CONF_\fP or \fBNTP_CONF\fP +.fi +.ad +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh FILES +.Bl -tag -width /etc/ntp.drift -compact +.It Pa /etc/ntp.conf +the default name of the configuration file +.It Pa ntp.keys +private MD5 keys +.It Pa ntpkey +RSA private key +.It Pa ntpkey_ Ns Ar host +RSA public key +.It Pa ntp_dh +Diffie\-Hellman agreement parameters +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntpd @NTPD_MS@ , +.Xr ntpdc @NTPDC_MS@ , +.Xr ntpq @NTPQ_MS@ +.Pp +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +.Li http://www.ntp.org/ . +A snapshot of this documentation is available in HTML format in +.Pa /usr/share/doc/ntp . +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 4) +.%O RFC5905 +.Re +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh BUGS +The syntax checking is not picky; some combinations of +ridiculous and even hilarious options and modes may not be +detected. +.Pp +The +.Pa ntpkey_ Ns Ar host +files are really digital +certificates. +These should be obtained via secure directory +services when they become universally available. +.Pp +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +This document was derived from FreeBSD. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntp.conf\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.conf.texi b/contrib/ntp/ntpd/ntp.conf.texi new file mode 100644 index 000000000..fb1a7ab0f --- /dev/null +++ b/contrib/ntp/ntpd/ntp.conf.texi @@ -0,0 +1,49 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntp.conf.info +@settitle NTP Configuration File User's Manual +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of the NTP Project's NTP configuration file, +version @value{VERSION}, @value{UPDATED}. +@end ifinfo + +@direntry +* ntp.conf: (ntp.conf). NTP's configuration file +@end direntry + +@titlepage +@title NTP's Configuration File User's Manual +@subtitle ntp.conf, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, ntp.conf Description, (dir), (dir) +@top NTP's Configuration File User Manual + +This document describes the configuration file for the NTP Project's +@code{ntpd} program. + +This document applies to version @value{VERSION} of @code{ntp.conf}. + +@shortcontents + +@menu +* ntp.conf Description:: +* ntp.conf Notes:: +@end menu + +@node ntp.conf Description, , Top, Top +@comment node-name, next, previous, up +@section Description + +The behavior of @code{ntpd} can be changed by a configuration file, +by default @code{ntp.conf}. + +@include invoke-ntp.conf.texi diff --git a/contrib/ntp/ntpd/ntp.keys.5man b/contrib/ntp/ntpd/ntp.keys.5man new file mode 100644 index 000000000..3e5cb54d9 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.keys.5man @@ -0,0 +1,173 @@ +.TH ntp.keys 5man "21 Oct 2015" "4.2.8p4" "File Formats" +.\" +.\" EDIT THIS FILE WITH CAUTION (ntp.man) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:08 PM by AutoGen 5.18.5 +.\" From the definitions ntp.keys.def +.\" and the template file agman-file.tpl +.Sh NAME +.Nm ntp.keys +.Nd NTP symmetric key file format + +.\" +.SH NAME +ntp.keys \- NTP symmetric key file format configuration file +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.SH SYNOPSIS +\f\*[B-Font]\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +This document describes the format of an NTP symmetric key file. +For a description of the use of this type of file, see the +"Authentication Support" +section of the +\fCntp.conf\f[]\fR(5)\f[] +page. +.sp \n(Ppu +.ne 2 + +\fCntpd\f[]\fR(8)\f[] +reads its keys from a file specified using the +\f\*[B-Font]\-k\f[] +command line option or the +\f\*[B-Font]keys\f[] +statement in the configuration file. +While key number 0 is fixed by the NTP standard +(as 56 zero bits) +and may not be changed, +one or more keys numbered between 1 and 65534 +may be arbitrarily set in the keys file. +.sp \n(Ppu +.ne 2 + +The key file uses the same comment conventions +as the configuration file. +Key entries use a fixed format of the form +.sp \n(Ppu +.ne 2 + +.in +4 +\f\*[I-Font]keyno\f[] \f\*[I-Font]type\f[] \f\*[I-Font]key\f[] +.in -4 +.sp \n(Ppu +.ne 2 + +where +\f\*[I-Font]keyno\f[] +is a positive integer (between 1 and 65534), +\f\*[I-Font]type\f[] +is the message digest algorithm, +and +\f\*[I-Font]key\f[] +is the key itself. +.sp \n(Ppu +.ne 2 + +The +\f\*[I-Font]key\f[] +may be given in a format +controlled by the +\f\*[I-Font]type\f[] +field. +The +\f\*[I-Font]type\f[] +\f[C]MD5\f[] +is always supported. +If +\f[C]ntpd\f[] +was built with the OpenSSL library +then any digest library supported by that library may be specified. +However, if compliance with FIPS 140-2 is required the +\f\*[I-Font]type\f[] +must be either +\f[C]SHA\f[] +or +\f[C]SHA1\f[]. +.sp \n(Ppu +.ne 2 + +What follows are some key types, and corresponding formats: +.sp \n(Ppu +.ne 2 + +.TP 7 +.NOP \f[C]MD5\f[] +The key is 1 to 16 printable characters terminated by +an EOL, +whitespace, +or +a +\f[C]#\f[] +(which is the "start of comment" character). +.sp \n(Ppu +.ne 2 + +.br +.ns +.TP 7 +.NOP \f[C]SHA\f[] +.br +.ns +.TP 7 +.NOP \f[C]SHA1\f[] +.br +.ns +.TP 7 +.NOP \f[C]RMD160\f[] +The key is a hex-encoded ASCII string of 40 characters, +which is truncated as necessary. +.PP +.sp \n(Ppu +.ne 2 + +Note that the keys used by the +\fCntpq\f[]\fR(8)\f[] +and +\fCntpdc\f[]\fR(8)\f[] +programs are checked against passwords +requested by the programs and entered by hand, +so it is generally appropriate to specify these keys in ASCII format. +.SH FILES +.TP 14 +.NOP \fI/etc/ntp.keys\f[] +the default name of the configuration file +.PP +.SH "SEE ALSO" +\fCntp.conf\f[]\fR(5)\f[], +\fCntpd\f[]\fR(1ntpdmdoc)\f[], +\fCntpdate\f[]\fR(1ntpdatemdoc)\f[], +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[], +\fCsntp\f[]\fR(1sntpmdoc)\f[] +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +This document was derived from FreeBSD. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntp.keys\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.keys.5mdoc b/contrib/ntp/ntpd/ntp.keys.5mdoc new file mode 100644 index 000000000..6355a39ca --- /dev/null +++ b/contrib/ntp/ntpd/ntp.keys.5mdoc @@ -0,0 +1,158 @@ +.Dd October 21 2015 +.Dt NTP_KEYS 5mdoc File Formats +.Os SunOS 5.10 +.\" EDIT THIS FILE WITH CAUTION (ntp.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:28 PM by AutoGen 5.18.5 +.\" From the definitions ntp.keys.def +.\" and the template file agmdoc-file.tpl +.Sh NAME +.Nm ntp.keys +.Nd NTP symmetric key file format + +.Sh NAME +.Nm ntp.keys +.Nd NTP symmetric key file format +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +This document describes the format of an NTP symmetric key file. +For a description of the use of this type of file, see the +.Qq Authentication Support +section of the +.Xr ntp.conf 5 +page. +.Pp +.Xr ntpd 8 +reads its keys from a file specified using the +.Fl k +command line option or the +.Ic keys +statement in the configuration file. +While key number 0 is fixed by the NTP standard +(as 56 zero bits) +and may not be changed, +one or more keys numbered between 1 and 65534 +may be arbitrarily set in the keys file. +.Pp +The key file uses the same comment conventions +as the configuration file. +Key entries use a fixed format of the form +.Pp +.D1 Ar keyno type key +.Pp +where +.Ar keyno +is a positive integer (between 1 and 65534), +.Ar type +is the message digest algorithm, +and +.Ar key +is the key itself. +.Pp +The +.Ar key +may be given in a format +controlled by the +.Ar type +field. +The +.Ar type +.Li MD5 +is always supported. +If +.Li ntpd +was built with the OpenSSL library +then any digest library supported by that library may be specified. +However, if compliance with FIPS 140\-2 is required the +.Ar type +must be either +.Li SHA +or +.Li SHA1 . +.Pp +What follows are some key types, and corresponding formats: +.Pp +.Bl -tag -width RMD160 -compact +.It Li MD5 +The key is 1 to 16 printable characters terminated by +an EOL, +whitespace, +or +a +.Li # +(which is the "start of comment" character). +.Pp +.It Li SHA +.It Li SHA1 +.It Li RMD160 +The key is a hex\-encoded ASCII string of 40 characters, +which is truncated as necessary. +.El +.Pp +Note that the keys used by the +.Xr ntpq 8 +and +.Xr ntpdc 8 +programs are checked against passwords +requested by the programs and entered by hand, +so it is generally appropriate to specify these keys in ASCII format. +.Sh "OPTIONS" +.Bl -tag +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTP_KEYS_\fP or \fBNTP_KEYS\fP +.fi +.ad +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh FILES +.Bl -tag -width /etc/ntp.keys -compact +.It Pa /etc/ntp.keys +the default name of the configuration file +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntp.conf 5 , +.Xr ntpd 1ntpdmdoc , +.Xr ntpdate 1ntpdatemdoc , +.Xr ntpdc 1ntpdcmdoc , +.Xr sntp 1sntpmdoc +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +This document was derived from FreeBSD. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntp.keys\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.keys.def b/contrib/ntp/ntpd/ntp.keys.def new file mode 100644 index 000000000..dcb3d55ea --- /dev/null +++ b/contrib/ntp/ntpd/ntp.keys.def @@ -0,0 +1,152 @@ +/* -*- Mode: Text -*- */ + +autogen definitions options; + +#include copyright.def +#include version.def + +// We want the synopsis to be "/etc/ntp.keys" but we need the prog-name +// to be ntp.keys - the latter is also how autogen produces the output +// file name. +prog-name = "ntp.keys"; +file-path = "/etc/ntp.keys"; +prog-title = "NTP symmetric key file format"; + +/* explain: Additional information whenever the usage routine is invoked */ +explain = <<- _END_EXPLAIN + _END_EXPLAIN; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +This document describes the format of an NTP symmetric key file. +For a description of the use of this type of file, see the +.Qq Authentication Support +section of the +.Xr ntp.conf 5 +page. +.Pp +.Xr ntpd 8 +reads its keys from a file specified using the +.Fl k +command line option or the +.Ic keys +statement in the configuration file. +While key number 0 is fixed by the NTP standard +(as 56 zero bits) +and may not be changed, +one or more keys numbered between 1 and 65534 +may be arbitrarily set in the keys file. +.Pp +The key file uses the same comment conventions +as the configuration file. +Key entries use a fixed format of the form +.Pp +.D1 Ar keyno type key +.Pp +where +.Ar keyno +is a positive integer (between 1 and 65534), +.Ar type +is the message digest algorithm, +and +.Ar key +is the key itself. +.Pp +The +.Ar key +may be given in a format +controlled by the +.Ar type +field. +The +.Ar type +.Li MD5 +is always supported. +If +.Li ntpd +was built with the OpenSSL library +then any digest library supported by that library may be specified. +However, if compliance with FIPS 140-2 is required the +.Ar type +must be either +.Li SHA +or +.Li SHA1 . +.Pp +What follows are some key types, and corresponding formats: +.Pp +.Bl -tag -width RMD160 -compact +.It Li MD5 +The key is 1 to 16 printable characters terminated by +an EOL, +whitespace, +or +a +.Li # +(which is the "start of comment" character). +.Pp +.It Li SHA +.It Li SHA1 +.It Li RMD160 +The key is a hex-encoded ASCII string of 40 characters, +which is truncated as necessary. +.El +.Pp +Note that the keys used by the +.Xr ntpq 8 +and +.Xr ntpdc 8 +programs are checked against passwords +requested by the programs and entered by hand, +so it is generally appropriate to specify these keys in ASCII format. + _END_PROG_MDOC_DESCRIP; +}; + +doc-section = { + ds-type = 'FILES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_FILES +.Bl -tag -width /etc/ntp.keys -compact +.It Pa /etc/ntp.keys +the default name of the configuration file +.El + _END_MDOC_FILES; +}; + +doc-section = { + ds-type = 'SEE ALSO'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_SEE_ALSO +.Xr ntp.conf 5 , +.Xr ntpd 1ntpdmdoc , +.Xr ntpdate 1ntpdatemdoc , +.Xr ntpdc 1ntpdcmdoc , +.Xr sntp 1sntpmdoc + _END_MDOC_SEE_ALSO; +}; + +/* +doc-section = { + ds-type = 'BUGS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_BUGS +.Xr ntpd 8 +has gotten rather fat. +While not huge, it has gotten larger than might +be desirable for an elevated-priority daemon running on a workstation, +particularly since many of the fancy features which consume the space +were designed more with a busy primary server, rather than a high +stratum workstation, in mind. + _END_MDOC_BUGS; +}; +*/ + +doc-section = { + ds-type = 'NOTES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_NOTES +This document was derived from FreeBSD. + _END_MDOC_NOTES; +}; diff --git a/contrib/ntp/ntpd/ntp.keys.html b/contrib/ntp/ntpd/ntp.keys.html new file mode 100644 index 000000000..3671aaaac --- /dev/null +++ b/contrib/ntp/ntpd/ntp.keys.html @@ -0,0 +1,200 @@ + + +NTP Symmetric Key + + + + + + + + + +

      NTP Symmetric Key

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      NTP's Symmetric Key File User Manual

      + +

      This document describes the symmetric key file for the NTP Project's +ntpd program. + +

      This document applies to version 4.2.8p4 of ntp.keys. + +

      +

      Short Contents

      + +
      + + + +
      +


      +Previous: Top, +Up: Top +
      +
      + + +

      Description

      + +

      The name and location of the symmetric key file for ntpd can +be specified in a configuration file, by default /etc/ntp.keys. + +

      +


      + +
      +
      + +

      Notes about ntp.keys

      + +

      + +

      This document describes the format of an NTP symmetric key file. +For a description of the use of this type of file, see the +"Authentication Support" +section of the +ntp.conf(5) +page. + +

      ntpd(8) +reads its keys from a file specified using the +-k +command line option or the +keys +statement in the configuration file. +While key number 0 is fixed by the NTP standard +(as 56 zero bits) +and may not be changed, +one or more keys numbered between 1 and 65534 +may be arbitrarily set in the keys file. + +

      The key file uses the same comment conventions +as the configuration file. +Key entries use a fixed format of the form + +

           keyno type key
      +
      +

      where +keyno +is a positive integer (between 1 and 65534), +type +is the message digest algorithm, +and +key +is the key itself. + +

      The +key +may be given in a format +controlled by the +type +field. +The +type +MD5 +is always supported. +If +ntpd +was built with the OpenSSL library +then any digest library supported by that library may be specified. +However, if compliance with FIPS 140-2 is required the +type +must be either +SHA +or +SHA1. + +

      What follows are some key types, and corresponding formats: + +

      +
      MD5
      The key is 1 to 16 printable characters terminated by +an EOL, +whitespace, +or +a +# +(which is the "start of comment" character). + +
      SHA
      SHA1
      RMD160
      The key is a hex-encoded ASCII string of 40 characters, +which is truncated as necessary. +
      + +

      Note that the keys used by the +ntpq(8) +and +ntpdc(8) +programs are checked against passwords +requested by the programs and entered by hand, +so it is generally appropriate to specify these keys in ASCII format. + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntp.keys program. +This software is released under the NTP license, <http://ntp.org/license>. + +

      + +
      +


      +Next: , +Up: ntp.keys Notes +
      +
      + +

      ntp.keys Files

      + +
      +
      /etc/ntp.keys
      the default name of the configuration file +
      +
      +


      +Next: , +Previous: ntp.keys Files, +Up: ntp.keys Notes +
      +
      + +

      ntp.keys See Also

      + +

      ntp.conf(5), +ntpd(1ntpdmdoc), +ntpdate(1ntpdatemdoc), +ntpdc(1ntpdcmdoc), +sntp(1sntpmdoc) +

      +


      +Previous: ntp.keys See Also, +Up: ntp.keys Notes +
      +
      + +

      ntp.keys Notes

      + +

      This document was derived from FreeBSD. + + + diff --git a/contrib/ntp/ntpd/ntp.keys.man.in b/contrib/ntp/ntpd/ntp.keys.man.in new file mode 100644 index 000000000..bd64756a0 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.keys.man.in @@ -0,0 +1,173 @@ +.TH ntp.keys 5 "21 Oct 2015" "4.2.8p4" "File Formats" +.\" +.\" EDIT THIS FILE WITH CAUTION (ntp.man) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:08 PM by AutoGen 5.18.5 +.\" From the definitions ntp.keys.def +.\" and the template file agman-file.tpl +.Sh NAME +.Nm ntp.keys +.Nd NTP symmetric key file format + +.\" +.SH NAME +ntp.keys \- NTP symmetric key file format configuration file +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.SH SYNOPSIS +\f\*[B-Font]\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +This document describes the format of an NTP symmetric key file. +For a description of the use of this type of file, see the +"Authentication Support" +section of the +\fCntp.conf\f[]\fR(5)\f[] +page. +.sp \n(Ppu +.ne 2 + +\fCntpd\f[]\fR(8)\f[] +reads its keys from a file specified using the +\f\*[B-Font]\-k\f[] +command line option or the +\f\*[B-Font]keys\f[] +statement in the configuration file. +While key number 0 is fixed by the NTP standard +(as 56 zero bits) +and may not be changed, +one or more keys numbered between 1 and 65534 +may be arbitrarily set in the keys file. +.sp \n(Ppu +.ne 2 + +The key file uses the same comment conventions +as the configuration file. +Key entries use a fixed format of the form +.sp \n(Ppu +.ne 2 + +.in +4 +\f\*[I-Font]keyno\f[] \f\*[I-Font]type\f[] \f\*[I-Font]key\f[] +.in -4 +.sp \n(Ppu +.ne 2 + +where +\f\*[I-Font]keyno\f[] +is a positive integer (between 1 and 65534), +\f\*[I-Font]type\f[] +is the message digest algorithm, +and +\f\*[I-Font]key\f[] +is the key itself. +.sp \n(Ppu +.ne 2 + +The +\f\*[I-Font]key\f[] +may be given in a format +controlled by the +\f\*[I-Font]type\f[] +field. +The +\f\*[I-Font]type\f[] +\f[C]MD5\f[] +is always supported. +If +\f[C]ntpd\f[] +was built with the OpenSSL library +then any digest library supported by that library may be specified. +However, if compliance with FIPS 140-2 is required the +\f\*[I-Font]type\f[] +must be either +\f[C]SHA\f[] +or +\f[C]SHA1\f[]. +.sp \n(Ppu +.ne 2 + +What follows are some key types, and corresponding formats: +.sp \n(Ppu +.ne 2 + +.TP 7 +.NOP \f[C]MD5\f[] +The key is 1 to 16 printable characters terminated by +an EOL, +whitespace, +or +a +\f[C]#\f[] +(which is the "start of comment" character). +.sp \n(Ppu +.ne 2 + +.br +.ns +.TP 7 +.NOP \f[C]SHA\f[] +.br +.ns +.TP 7 +.NOP \f[C]SHA1\f[] +.br +.ns +.TP 7 +.NOP \f[C]RMD160\f[] +The key is a hex-encoded ASCII string of 40 characters, +which is truncated as necessary. +.PP +.sp \n(Ppu +.ne 2 + +Note that the keys used by the +\fCntpq\f[]\fR(8)\f[] +and +\fCntpdc\f[]\fR(8)\f[] +programs are checked against passwords +requested by the programs and entered by hand, +so it is generally appropriate to specify these keys in ASCII format. +.SH FILES +.TP 14 +.NOP \fI/etc/ntp.keys\f[] +the default name of the configuration file +.PP +.SH "SEE ALSO" +\fCntp.conf\f[]\fR(5)\f[], +\fCntpd\f[]\fR(@NTPD_MS@)\f[], +\fCntpdate\f[]\fR(@NTPDATE_MS@)\f[], +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[], +\fCsntp\f[]\fR(@SNTP_MS@)\f[] +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +This document was derived from FreeBSD. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntp.keys\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.keys.mdoc.in b/contrib/ntp/ntpd/ntp.keys.mdoc.in new file mode 100644 index 000000000..6600d57d5 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.keys.mdoc.in @@ -0,0 +1,158 @@ +.Dd October 21 2015 +.Dt NTP_KEYS 5 File Formats +.Os SunOS 5.10 +.\" EDIT THIS FILE WITH CAUTION (ntp.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:28 PM by AutoGen 5.18.5 +.\" From the definitions ntp.keys.def +.\" and the template file agmdoc-file.tpl +.Sh NAME +.Nm ntp.keys +.Nd NTP symmetric key file format + +.Sh NAME +.Nm ntp.keys +.Nd NTP symmetric key file format +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +This document describes the format of an NTP symmetric key file. +For a description of the use of this type of file, see the +.Qq Authentication Support +section of the +.Xr ntp.conf 5 +page. +.Pp +.Xr ntpd 8 +reads its keys from a file specified using the +.Fl k +command line option or the +.Ic keys +statement in the configuration file. +While key number 0 is fixed by the NTP standard +(as 56 zero bits) +and may not be changed, +one or more keys numbered between 1 and 65534 +may be arbitrarily set in the keys file. +.Pp +The key file uses the same comment conventions +as the configuration file. +Key entries use a fixed format of the form +.Pp +.D1 Ar keyno type key +.Pp +where +.Ar keyno +is a positive integer (between 1 and 65534), +.Ar type +is the message digest algorithm, +and +.Ar key +is the key itself. +.Pp +The +.Ar key +may be given in a format +controlled by the +.Ar type +field. +The +.Ar type +.Li MD5 +is always supported. +If +.Li ntpd +was built with the OpenSSL library +then any digest library supported by that library may be specified. +However, if compliance with FIPS 140\-2 is required the +.Ar type +must be either +.Li SHA +or +.Li SHA1 . +.Pp +What follows are some key types, and corresponding formats: +.Pp +.Bl -tag -width RMD160 -compact +.It Li MD5 +The key is 1 to 16 printable characters terminated by +an EOL, +whitespace, +or +a +.Li # +(which is the "start of comment" character). +.Pp +.It Li SHA +.It Li SHA1 +.It Li RMD160 +The key is a hex\-encoded ASCII string of 40 characters, +which is truncated as necessary. +.El +.Pp +Note that the keys used by the +.Xr ntpq 8 +and +.Xr ntpdc 8 +programs are checked against passwords +requested by the programs and entered by hand, +so it is generally appropriate to specify these keys in ASCII format. +.Sh "OPTIONS" +.Bl -tag +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTP_KEYS_\fP or \fBNTP_KEYS\fP +.fi +.ad +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh FILES +.Bl -tag -width /etc/ntp.keys -compact +.It Pa /etc/ntp.keys +the default name of the configuration file +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntp.conf 5 , +.Xr ntpd @NTPD_MS@ , +.Xr ntpdate @NTPDATE_MS@ , +.Xr ntpdc @NTPDC_MS@ , +.Xr sntp @SNTP_MS@ +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +This document was derived from FreeBSD. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntp.keys\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntp.keys.texi b/contrib/ntp/ntpd/ntp.keys.texi new file mode 100644 index 000000000..1fc7b5c51 --- /dev/null +++ b/contrib/ntp/ntpd/ntp.keys.texi @@ -0,0 +1,49 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntp.keys.info +@settitle NTP Symmetric Key +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the NTP Project's NTP Symmetric Key file, +version @value{VERSION}, @value{UPDATED}. +@end ifinfo + +@direntry +* ntp.keys: (ntp.keys). NTP's Symmetric Key file +@end direntry + +@titlepage +@title NTP's Symmetric Key File User's Manual +@subtitle ntp.keys, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, ntp.keys Description, (dir), (dir) +@top NTP's Symmetric Key File User Manual + +This document describes the symmetric key file for the NTP Project's +@code{ntpd} program. + +This document applies to version @value{VERSION} of @code{ntp.keys}. + +@shortcontents + +@menu +* ntp.keys Description:: +* ntp.keys Notes:: +@end menu + +@node ntp.keys Description, , Top, Top +@comment node-name, next, previous, up +@section Description + +The name and location of the symmetric key file for @code{ntpd} can +be specified in a configuration file, by default @code{/etc/ntp.keys}. + +@include invoke-ntp.keys.texi diff --git a/contrib/ntp/ntpd/ntp_config.c b/contrib/ntp/ntpd/ntp_config.c index e038f2057..1c754bd16 100644 --- a/contrib/ntp/ntpd/ntp_config.c +++ b/contrib/ntp/ntpd/ntp_config.c @@ -1,6 +1,14 @@ -/* - * ntp_config.c - read and apply configuration information +/* ntp_config.c + * + * This file contains the ntpd configuration code. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Some parts borrowed from the older ntp_config.c + * Copyright (c) 2006 */ + #ifdef HAVE_CONFIG_H # include #endif @@ -9,375 +17,156 @@ # include #endif -#include "ntpd.h" -#include "ntp_io.h" -#include "ntp_unixtime.h" -#include "ntp_refclock.h" -#include "ntp_filegen.h" -#include "ntp_stdlib.h" -#include -#include -#include - #include #include #ifdef HAVE_SYS_PARAM_H -#include +# include #endif #include #ifndef SIGCHLD # define SIGCHLD SIGCLD #endif -#if !defined(VMS) -# ifdef HAVE_SYS_WAIT_H -# include -# endif -#endif /* VMS */ +#ifdef HAVE_SYS_WAIT_H +# include +#endif -#ifdef SYS_WINNT -# include -static HANDLE ResolverThreadHandle = NULL; -HANDLE ResolverEventHandle; -#else -int resolver_pipe_fd[2]; /* used to let the resolver process alert the parent process */ -#endif /* SYS_WINNT */ +#include +#include +#include "ntp.h" +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_unixtime.h" +#include "ntp_refclock.h" +#include "ntp_filegen.h" +#include "ntp_stdlib.h" +#include "lib_strbuf.h" +#include "ntp_assert.h" +#include "ntp_random.h" /* * [Bug 467]: Some linux headers collide with CONFIG_PHONE and CONFIG_KEYS * so #include these later. */ - #include "ntp_config.h" #include "ntp_cmdargs.h" +#include "ntp_scanner.h" +#include "ntp_parser.h" +#include "ntpd-opts.h" -extern int priority_done; - -/* - * These routines are used to read the configuration file at - * startup time. An entry in the file must fit on a single line. - * Entries are processed as multiple tokens separated by white space - * Lines are considered terminated when a '#' is encountered. Blank - * lines are ignored. - */ -/* - * Translation table - keywords to function index - */ -struct keyword { - const char *text; - int keytype; -}; - -/* - * Command keywords - */ -static struct keyword keywords[] = { - { "automax", CONFIG_AUTOMAX }, - { "broadcast", CONFIG_BROADCAST }, - { "broadcastclient", CONFIG_BROADCASTCLIENT }, - { "broadcastdelay", CONFIG_BDELAY }, - { "calldelay", CONFIG_CDELAY}, -#ifdef OPENSSL - { "crypto", CONFIG_CRYPTO }, -#endif /* OPENSSL */ - { "controlkey", CONFIG_CONTROLKEY }, - { "disable", CONFIG_DISABLE }, - { "driftfile", CONFIG_DRIFTFILE }, - { "enable", CONFIG_ENABLE }, - { "end", CONFIG_END }, - { "filegen", CONFIG_FILEGEN }, - { "fudge", CONFIG_FUDGE }, - { "includefile", CONFIG_INCLUDEFILE }, - { "keys", CONFIG_KEYS }, - { "keysdir", CONFIG_KEYSDIR }, - { "logconfig", CONFIG_LOGCONFIG }, - { "logfile", CONFIG_LOGFILE }, - { "manycastclient", CONFIG_MANYCASTCLIENT }, - { "manycastserver", CONFIG_MANYCASTSERVER }, - { "multicastclient", CONFIG_MULTICASTCLIENT }, - { "peer", CONFIG_PEER }, - { "phone", CONFIG_PHONE }, - { "pidfile", CONFIG_PIDFILE }, - { "discard", CONFIG_DISCARD }, - { "requestkey", CONFIG_REQUESTKEY }, - { "restrict", CONFIG_RESTRICT }, - { "revoke", CONFIG_REVOKE }, - { "server", CONFIG_SERVER }, - { "setvar", CONFIG_SETVAR }, - { "statistics", CONFIG_STATISTICS }, - { "statsdir", CONFIG_STATSDIR }, - { "tick", CONFIG_ADJ }, - { "tinker", CONFIG_TINKER }, - { "tos", CONFIG_TOS }, - { "trap", CONFIG_TRAP }, - { "trustedkey", CONFIG_TRUSTEDKEY }, - { "ttl", CONFIG_TTL }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "peer", "server", "broadcast" modifier keywords - */ -static struct keyword mod_keywords[] = { - { "autokey", CONF_MOD_SKEY }, - { "burst", CONF_MOD_BURST }, - { "iburst", CONF_MOD_IBURST }, - { "key", CONF_MOD_KEY }, - { "maxpoll", CONF_MOD_MAXPOLL }, - { "minpoll", CONF_MOD_MINPOLL }, - { "mode", CONF_MOD_MODE }, /* refclocks */ - { "noselect", CONF_MOD_NOSELECT }, - { "preempt", CONF_MOD_PREEMPT }, - { "true", CONF_MOD_TRUE }, - { "prefer", CONF_MOD_PREFER }, - { "ttl", CONF_MOD_TTL }, /* NTP peers */ - { "version", CONF_MOD_VERSION }, - { "dynamic", CONF_MOD_DYNAMIC }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "restrict" modifier keywords - */ -static struct keyword res_keywords[] = { - { "ignore", CONF_RES_IGNORE }, - { "limited", CONF_RES_LIMITED }, - { "kod", CONF_RES_DEMOBILIZE }, - { "lowpriotrap", CONF_RES_LPTRAP }, - { "mask", CONF_RES_MASK }, - { "nomodify", CONF_RES_NOMODIFY }, - { "nopeer", CONF_RES_NOPEER }, - { "noquery", CONF_RES_NOQUERY }, - { "noserve", CONF_RES_NOSERVE }, - { "notrap", CONF_RES_NOTRAP }, - { "notrust", CONF_RES_NOTRUST }, - { "ntpport", CONF_RES_NTPPORT }, - { "version", CONF_RES_VERSION }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "trap" modifier keywords - */ -static struct keyword trap_keywords[] = { - { "port", CONF_TRAP_PORT }, - { "interface", CONF_TRAP_INTERFACE }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "fudge" modifier keywords - */ -static struct keyword fudge_keywords[] = { - { "flag1", CONF_FDG_FLAG1 }, - { "flag2", CONF_FDG_FLAG2 }, - { "flag3", CONF_FDG_FLAG3 }, - { "flag4", CONF_FDG_FLAG4 }, - { "refid", CONF_FDG_REFID }, /* this mapping should be cleaned up (endianness, \0) - kd 20041031 */ - { "stratum", CONF_FDG_STRATUM }, - { "time1", CONF_FDG_TIME1 }, - { "time2", CONF_FDG_TIME2 }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "filegen" modifier keywords - */ -static struct keyword filegen_keywords[] = { - { "disable", CONF_FGEN_FLAG_DISABLE }, - { "enable", CONF_FGEN_FLAG_ENABLE }, - { "file", CONF_FGEN_FILE }, - { "link", CONF_FGEN_FLAG_LINK }, - { "nolink", CONF_FGEN_FLAG_NOLINK }, - { "type", CONF_FGEN_TYPE }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "type" modifier keywords - */ -static struct keyword fgen_types[] = { - { "age", FILEGEN_AGE }, - { "day", FILEGEN_DAY }, - { "month", FILEGEN_MONTH }, - { "none", FILEGEN_NONE }, - { "pid", FILEGEN_PID }, - { "week", FILEGEN_WEEK }, - { "year", FILEGEN_YEAR }, - { "", CONFIG_UNKNOWN} -}; - -/* - * "enable", "disable" modifier keywords - */ -static struct keyword flags_keywords[] = { - { "auth", PROTO_AUTHENTICATE }, - { "bclient", PROTO_BROADCLIENT }, - { "calibrate", PROTO_CAL }, - { "kernel", PROTO_KERNEL }, - { "monitor", PROTO_MONITOR }, - { "ntp", PROTO_NTP }, - { "stats", PROTO_FILEGEN }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "discard" modifier keywords - */ -static struct keyword discard_keywords[] = { - { "average", CONF_DISCARD_AVERAGE }, - { "minimum", CONF_DISCARD_MINIMUM }, - { "monitor", CONF_DISCARD_MONITOR }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "tinker" modifier keywords - */ -static struct keyword tinker_keywords[] = { - { "step", CONF_CLOCK_MAX }, - { "panic", CONF_CLOCK_PANIC }, - { "dispersion", CONF_CLOCK_PHI }, - { "stepout", CONF_CLOCK_MINSTEP }, - { "allan", CONF_CLOCK_ALLAN }, - { "huffpuff", CONF_CLOCK_HUFFPUFF }, - { "freq", CONF_CLOCK_FREQ }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "tos" modifier keywords - */ -static struct keyword tos_keywords[] = { - { "minclock", CONF_TOS_MINCLOCK }, - { "maxclock", CONF_TOS_MAXCLOCK }, - { "minsane", CONF_TOS_MINSANE }, - { "floor", CONF_TOS_FLOOR }, - { "ceiling", CONF_TOS_CEILING }, - { "cohort", CONF_TOS_COHORT }, - { "mindist", CONF_TOS_MINDISP }, - { "maxdist", CONF_TOS_MAXDIST }, - { "maxhop", CONF_TOS_MAXHOP }, - { "beacon", CONF_TOS_BEACON }, - { "orphan", CONF_TOS_ORPHAN }, - { "", CONFIG_UNKNOWN } -}; +/* Bug 2817 */ +#if defined(HAVE_SYS_MMAN_H) +# include +#endif -#ifdef OPENSSL -/* - * "crypto" modifier keywords - */ -static struct keyword crypto_keywords[] = { - { "cert", CONF_CRYPTO_CERT }, - { "gqpar", CONF_CRYPTO_GQPAR }, - { "host", CONF_CRYPTO_RSA }, - { "ident", CONF_CRYPTO_IDENT }, - { "iffpar", CONF_CRYPTO_IFFPAR }, - { "leap", CONF_CRYPTO_LEAP }, - { "mvpar", CONF_CRYPTO_MVPAR }, - { "pw", CONF_CRYPTO_PW }, - { "randfile", CONF_CRYPTO_RAND }, - { "sign", CONF_CRYPTO_SIGN }, - { "", CONFIG_UNKNOWN } -}; -#endif /* OPENSSL */ +/* list of servers from command line for config_peers() */ +int cmdline_server_count; +char ** cmdline_servers; -/* - * Address type selection, IPv4 or IPv4. - * Used on various lines. +/* Current state of memory locking: + * -1: default + * 0: memory locking disabled + * 1: Memory locking enabled */ -static struct keyword addr_type[] = { - { "-4", CONF_ADDR_IPV4 }, - { "-6", CONF_ADDR_IPV6 }, - { "", CONFIG_UNKNOWN } -}; +int cur_memlock = -1; /* * "logconfig" building blocks */ struct masks { - const char *name; - unsigned long mask; + const char * const name; + const u_int32 mask; }; static struct masks logcfg_class[] = { - { "clock", NLOG_OCLOCK }, - { "peer", NLOG_OPEER }, - { "sync", NLOG_OSYNC }, - { "sys", NLOG_OSYS }, - { (char *)0, 0 } + { "clock", NLOG_OCLOCK }, + { "peer", NLOG_OPEER }, + { "sync", NLOG_OSYNC }, + { "sys", NLOG_OSYS }, + { NULL, 0 } +}; + +/* logcfg_noclass_items[] masks are complete and must not be shifted */ +static struct masks logcfg_noclass_items[] = { + { "allall", NLOG_SYSMASK | NLOG_PEERMASK | NLOG_CLOCKMASK | NLOG_SYNCMASK }, + { "allinfo", NLOG_SYSINFO | NLOG_PEERINFO | NLOG_CLOCKINFO | NLOG_SYNCINFO }, + { "allevents", NLOG_SYSEVENT | NLOG_PEEREVENT | NLOG_CLOCKEVENT | NLOG_SYNCEVENT }, + { "allstatus", NLOG_SYSSTATUS | NLOG_PEERSTATUS | NLOG_CLOCKSTATUS | NLOG_SYNCSTATUS }, + { "allstatistics", NLOG_SYSSTATIST | NLOG_PEERSTATIST | NLOG_CLOCKSTATIST | NLOG_SYNCSTATIST }, + /* the remainder are misspellings of clockall, peerall, sysall, and syncall. */ + { "allclock", (NLOG_INFO | NLOG_STATIST | NLOG_EVENT | NLOG_STATUS) << NLOG_OCLOCK }, + { "allpeer", (NLOG_INFO | NLOG_STATIST | NLOG_EVENT | NLOG_STATUS) << NLOG_OPEER }, + { "allsys", (NLOG_INFO | NLOG_STATIST | NLOG_EVENT | NLOG_STATUS) << NLOG_OSYS }, + { "allsync", (NLOG_INFO | NLOG_STATIST | NLOG_EVENT | NLOG_STATUS) << NLOG_OSYNC }, + { NULL, 0 } }; -static struct masks logcfg_item[] = { +/* logcfg_class_items[] masks are shiftable by NLOG_O* counts */ +static struct masks logcfg_class_items[] = { + { "all", NLOG_INFO | NLOG_EVENT | NLOG_STATUS | NLOG_STATIST }, { "info", NLOG_INFO }, - { "allinfo", NLOG_SYSINFO|NLOG_PEERINFO|NLOG_CLOCKINFO|NLOG_SYNCINFO }, { "events", NLOG_EVENT }, - { "allevents", NLOG_SYSEVENT|NLOG_PEEREVENT|NLOG_CLOCKEVENT|NLOG_SYNCEVENT }, { "status", NLOG_STATUS }, - { "allstatus", NLOG_SYSSTATUS|NLOG_PEERSTATUS|NLOG_CLOCKSTATUS|NLOG_SYNCSTATUS }, { "statistics", NLOG_STATIST }, - { "allstatistics", NLOG_SYSSTATIST|NLOG_PEERSTATIST|NLOG_CLOCKSTATIST|NLOG_SYNCSTATIST }, - { "allclock", (NLOG_INFO|NLOG_STATIST|NLOG_EVENT|NLOG_STATUS)<name) { - if (strncmp(*s, m->name, strlen(m->name)) == 0) { - *s += strlen(m->name); - return m->mask; - } else { - m++; - } + if (ptree->auth.keys) { + free(ptree->auth.keys); + ptree->auth.keys = NULL; + } + + if (ptree->auth.keysdir) { + free(ptree->auth.keysdir); + ptree->auth.keysdir = NULL; + } + + if (ptree->auth.ntp_signd_socket) { + free(ptree->auth.ntp_signd_socket); + ptree->auth.ntp_signd_socket = NULL; } - return 0; } +#endif /* DEBUG */ -/* - * get_match - find logmask value - */ -static unsigned long -get_match( - char *s, - struct masks *m + +static void +init_syntax_tree( + config_tree *ptree ) { - while (m->name) { - if (strcmp(s, m->name) == 0) { - return m->mask; - } else { - m++; - } + ZERO(*ptree); + ptree->mdnstries = 5; +} + + +#ifdef FREE_CFG_T +static void +free_all_config_trees(void) +{ + config_tree *ptree; + config_tree *pnext; + + ptree = cfg_tree_history; + + while (ptree != NULL) { + pnext = ptree->link; + free_config_tree(ptree); + ptree = pnext; } - return 0; } -/* - * get_logmask - build bitmask for ntp_syslogmask - */ -static unsigned long -get_logmask( - char *s + +static void +free_config_tree( + config_tree *ptree ) { - char *t; - unsigned long offset; - unsigned long mask; +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif - t = s; - offset = get_pfxmatch(&t, logcfg_class); - mask = get_match(t, logcfg_item); + if (ptree->source.value.s != NULL) + free(ptree->source.value.s); + + free_config_other_modes(ptree); + free_config_auth(ptree); + free_config_tos(ptree); + free_config_monitor(ptree); + free_config_access(ptree); + free_config_tinker(ptree); + free_config_rlimit(ptree); + free_config_system_opts(ptree); + free_config_logconfig(ptree); + free_config_phone(ptree); + free_config_setvar(ptree); + free_config_ttl(ptree); + free_config_trap(ptree); + free_config_fudge(ptree); + free_config_vars(ptree); + free_config_peers(ptree); + free_config_unpeers(ptree); + free_config_nic_rules(ptree); + free_config_reset_counters(ptree); +#ifdef SIM + free_config_sim(ptree); +#endif + free_auth_node(ptree); - if (mask) - return mask << offset; - else - msyslog(LOG_ERR, "logconfig: illegal argument %s - ignored", s); + free(ptree); - return 0; +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif } +#endif /* FREE_CFG_T */ -/* - * getconfig - get command line options and read the configuration file - */ -void -getconfig( - int argc, - char *argv[] - ) -{ - register int i; - int c; - int errflg; - int status; - int istart; - int peerversion; - int minpoll; - int maxpoll; - int ttl; - long stratum; - unsigned long ul; - keyid_t peerkey; - u_char *peerkeystr; - u_long fudgeflag; - u_int peerflags; - int hmode; - struct sockaddr_storage peeraddr; - struct sockaddr_storage maskaddr; - FILE *fp[MAXINCLUDELEVEL+1]; - FILE *includefile; - int includelevel = 0; - char line[MAXLINE]; - char *(tokens[MAXTOKENS]); - int ntokens = 0; - int tok = CONFIG_UNKNOWN; - struct interface *localaddr; - struct refclockstat clock_stat; - FILEGEN *filegen; +#ifdef SAVECONFIG +/* Dump all trees */ +int +dump_all_config_trees( + FILE *df, + int comment + ) +{ + config_tree * cfg_ptr; + int return_value; - /* - * Initialize, initialize - */ - errflg = 0; - -#ifndef SYS_WINNT - config_file = CONFIG_FILE; -#else - temp = CONFIG_FILE; - if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)config_file_storage, (DWORD)sizeof(config_file_storage))) { - msyslog(LOG_ERR, "ExpandEnvironmentStrings CONFIG_FILE failed: %m\n"); - exit(1); - } - config_file = config_file_storage; + return_value = 0; + for (cfg_ptr = cfg_tree_history; + cfg_ptr != NULL; + cfg_ptr = cfg_ptr->link) + return_value |= dump_config_tree(cfg_ptr, df, comment); - temp = ALT_CONFIG_FILE; - if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)alt_config_file_storage, (DWORD)sizeof(alt_config_file_storage))) { - msyslog(LOG_ERR, "ExpandEnvironmentStrings ALT_CONFIG_FILE failed: %m\n"); - exit(1); + return return_value; +} + + +/* The config dumper */ +int +dump_config_tree( + config_tree *ptree, + FILE *df, + int comment + ) +{ + peer_node *peern; + unpeer_node *unpeern; + attr_val *atrv; + address_node *addr; + address_node *peer_addr; + address_node *fudge_addr; + filegen_node *fgen_node; + restrict_node *rest_node; + addr_opts_node *addr_opts; + setvar_node *setv_node; + nic_rule_node *rule_node; + int_node *i_n; + int_node *flags; + int_node *counter_set; + string_node *str_node; + + const char *s = NULL; + char *s1; + char *s2; + char timestamp[80]; + int enable; + + DPRINTF(1, ("dump_config_tree(%p)\n", ptree)); + + if (comment) { + if (!strftime(timestamp, sizeof(timestamp), + "%Y-%m-%d %H:%M:%S", + localtime(&ptree->timestamp))) + timestamp[0] = '\0'; + + fprintf(df, "# %s %s %s\n", + timestamp, + (CONF_SOURCE_NTPQ == ptree->source.attr) + ? "ntpq remote config from" + : "startup configuration file", + ptree->source.value.s); } - alt_config_file = alt_config_file_storage; -#endif /* SYS_WINNT */ - res_fp = NULL; - ntp_syslogmask = NLOG_SYNCMASK; /* set more via logconfig */ + /* For options I didn't find documentation I'll just output its name and the cor. value */ + atrv = HEAD_PFIFO(ptree->vars); + for ( ; atrv != NULL; atrv = atrv->link) { + switch (atrv->type) { +#ifdef DEBUG + default: + fprintf(df, "\n# dump error:\n" + "# unknown vars type %d (%s) for %s\n", + atrv->type, token_name(atrv->type), + token_name(atrv->attr)); + break; +#endif + case T_Double: + fprintf(df, "%s %s\n", keyword(atrv->attr), + normal_dtoa(atrv->value.d)); + break; - /* - * install a non default variable with this daemon version - */ - (void) sprintf(line, "daemon_version=\"%s\"", Version); - set_sys_var(line, strlen(line)+1, RO); + case T_Integer: + fprintf(df, "%s %d\n", keyword(atrv->attr), + atrv->value.i); + break; - /* - * Say how we're setting the time of day - */ - (void) sprintf(line, "settimeofday=\"%s\"", set_tod_using); - set_sys_var(line, strlen(line)+1, RO); + case T_String: + fprintf(df, "%s \"%s\"", keyword(atrv->attr), + atrv->value.s); + if (T_Driftfile == atrv->attr && + atrv->link != NULL && + T_WanderThreshold == atrv->link->attr) { + atrv = atrv->link; + fprintf(df, " %s\n", + normal_dtoa(atrv->value.d)); + } else { + fprintf(df, "\n"); + } + break; + } + } - /* - * Initialize the loop. - */ - loop_config(LOOP_DRIFTINIT, 0.); + atrv = HEAD_PFIFO(ptree->logconfig); + if (atrv != NULL) { + fprintf(df, "logconfig"); + for ( ; atrv != NULL; atrv = atrv->link) + fprintf(df, " %c%s", atrv->attr, atrv->value.s); + fprintf(df, "\n"); + } - getCmdOpts(argc, argv); + if (ptree->stats_dir) + fprintf(df, "statsdir \"%s\"\n", ptree->stats_dir); - if ( - (fp[0] = fopen(FindConfig(config_file), "r")) == NULL -#ifdef HAVE_NETINFO - /* If there is no config_file, try NetInfo. */ - && check_netinfo && !(config_netinfo = get_netinfo_config()) -#endif /* HAVE_NETINFO */ - ) { - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(config_file)); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(config_file)); -#ifdef SYS_WINNT - /* Under WinNT try alternate_config_file name, first NTP.CONF, then NTP.INI */ + i_n = HEAD_PFIFO(ptree->stats_list); + if (i_n != NULL) { + fprintf(df, "statistics"); + for ( ; i_n != NULL; i_n = i_n->link) + fprintf(df, " %s", keyword(i_n->i)); + fprintf(df, "\n"); + } - if ((fp[0] = fopen(FindConfig(alt_config_file), "r")) == NULL) { + fgen_node = HEAD_PFIFO(ptree->filegen_opts); + for ( ; fgen_node != NULL; fgen_node = fgen_node->link) { + atrv = HEAD_PFIFO(fgen_node->options); + if (atrv != NULL) { + fprintf(df, "filegen %s", + keyword(fgen_node->filegen_token)); + for ( ; atrv != NULL; atrv = atrv->link) { + switch (atrv->attr) { +#ifdef DEBUG + default: + fprintf(df, "\n# dump error:\n" + "# unknown filegen option token %s\n" + "filegen %s", + token_name(atrv->attr), + keyword(fgen_node->filegen_token)); + break; +#endif + case T_File: + fprintf(df, " file %s", + atrv->value.s); + break; - /* - * Broadcast clients can sometimes run without - * a configuration file. - */ + case T_Type: + fprintf(df, " type %s", + keyword(atrv->value.i)); + break; - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(alt_config_file)); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(alt_config_file)); - return; + case T_Flag: + fprintf(df, " %s", + keyword(atrv->value.i)); + break; + } + } + fprintf(df, "\n"); } -#else /* not SYS_WINNT */ - return; -#endif /* not SYS_WINNT */ } - proto_config(PROTO_MONITOR, 0, 0., NULL); - - for (;;) { - if (tok == CONFIG_END) - break; - if (fp[includelevel]) - tok = gettokens(fp[includelevel], line, tokens, &ntokens); -#ifdef HAVE_NETINFO - else - tok = gettokens_netinfo(config_netinfo, tokens, &ntokens); -#endif /* HAVE_NETINFO */ + atrv = HEAD_PFIFO(ptree->auth.crypto_cmd_list); + if (atrv != NULL) { + fprintf(df, "crypto"); + for ( ; atrv != NULL; atrv = atrv->link) { + fprintf(df, " %s %s", keyword(atrv->attr), + atrv->value.s); + } + fprintf(df, "\n"); + } - if (tok == CONFIG_UNKNOWN) { - if (includelevel > 0) { - fclose(fp[includelevel--]); - continue; - } else { - break; - } - } - - switch(tok) { - case CONFIG_PEER: - case CONFIG_SERVER: - case CONFIG_MANYCASTCLIENT: - case CONFIG_BROADCAST: - if (tok == CONFIG_PEER) - hmode = MODE_ACTIVE; - else if (tok == CONFIG_SERVER) - hmode = MODE_CLIENT; - else if (tok == CONFIG_MANYCASTCLIENT) - hmode = MODE_CLIENT; + if (ptree->auth.revoke != 0) + fprintf(df, "revoke %d\n", ptree->auth.revoke); + + if (ptree->auth.keysdir != NULL) + fprintf(df, "keysdir \"%s\"\n", ptree->auth.keysdir); + + if (ptree->auth.keys != NULL) + fprintf(df, "keys \"%s\"\n", ptree->auth.keys); + + atrv = HEAD_PFIFO(ptree->auth.trusted_key_list); + if (atrv != NULL) { + fprintf(df, "trustedkey"); + for ( ; atrv != NULL; atrv = atrv->link) { + if (T_Integer == atrv->type) + fprintf(df, " %d", atrv->value.i); + else if (T_Intrange == atrv->type) + fprintf(df, " (%d ... %d)", + atrv->value.r.first, + atrv->value.r.last); +#ifdef DEBUG else - hmode = MODE_BROADCAST; + fprintf(df, "\n# dump error:\n" + "# unknown trustedkey attr type %d\n" + "trustedkey", atrv->type); +#endif + } + fprintf(df, "\n"); + } - if (ntokens < 2) { - msyslog(LOG_ERR, - "No address for %s, line ignored", - tokens[0]); - break; - } + if (ptree->auth.control_key) + fprintf(df, "controlkey %d\n", ptree->auth.control_key); + + if (ptree->auth.request_key) + fprintf(df, "requestkey %d\n", ptree->auth.request_key); + + /* dump enable list, then disable list */ + for (enable = 1; enable >= 0; enable--) { + atrv = (enable) + ? HEAD_PFIFO(ptree->enable_opts) + : HEAD_PFIFO(ptree->disable_opts); + if (atrv != NULL) { + fprintf(df, "%s", (enable) + ? "enable" + : "disable"); + for ( ; atrv != NULL; atrv = atrv->link) + fprintf(df, " %s", + keyword(atrv->value.i)); + fprintf(df, "\n"); + } + } - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; + atrv = HEAD_PFIFO(ptree->orphan_cmds); + if (atrv != NULL) { + fprintf(df, "tos"); + for ( ; atrv != NULL; atrv = atrv->link) { + switch (atrv->type) { +#ifdef DEBUG + default: + fprintf(df, "\n# dump error:\n" + "# unknown tos attr type %d %s\n" + "tos", atrv->type, + token_name(atrv->type)); break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; +#endif + case T_Double: + fprintf(df, " %s %s", + keyword(atrv->attr), + normal_dtoa(atrv->value.d)); break; } + } + fprintf(df, "\n"); + } - status = getnetnum(tokens[istart], &peeraddr, 0, t_UNK); - if (status == -1) - break; /* Found IPv6 address */ - if(status != 1) { - errflg = -1; - } else { - errflg = 0; + atrv = HEAD_PFIFO(ptree->rlimit); + if (atrv != NULL) { + fprintf(df, "rlimit"); + for ( ; atrv != NULL; atrv = atrv->link) { + INSIST(T_Integer == atrv->type); + fprintf(df, " %s %d", keyword(atrv->attr), + atrv->value.i); + } + fprintf(df, "\n"); + } + + atrv = HEAD_PFIFO(ptree->tinker); + if (atrv != NULL) { + fprintf(df, "tinker"); + for ( ; atrv != NULL; atrv = atrv->link) { + INSIST(T_Double == atrv->type); + fprintf(df, " %s %s", keyword(atrv->attr), + normal_dtoa(atrv->value.d)); + } + fprintf(df, "\n"); + } + + if (ptree->broadcastclient) + fprintf(df, "broadcastclient\n"); - if ( -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && + peern = HEAD_PFIFO(ptree->peers); + for ( ; peern != NULL; peern = peern->link) { + addr = peern->addr; + fprintf(df, "%s", keyword(peern->host_mode)); + switch (addr->type) { +#ifdef DEBUG + default: + fprintf(df, "# dump error:\n" + "# unknown peer family %d for:\n" + "%s", addr->type, + keyword(peern->host_mode)); + break; #endif - ISBADADR(&peeraddr)) { - msyslog(LOG_ERR, - "attempt to configure invalid address %s", - stoa(&peeraddr)); - break; - } - /* - * Shouldn't be able to specify multicast - * address for server/peer! - * and unicast address for manycastclient! - */ - if (peeraddr.ss_family == AF_INET) { - if (((tok == CONFIG_SERVER) || - (tok == CONFIG_PEER)) && -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && -#endif - IN_CLASSD(ntohl(((struct sockaddr_in*)&peeraddr)->sin_addr.s_addr))) { - msyslog(LOG_ERR, - "attempt to configure invalid address %s", - stoa(&peeraddr)); - break; - } - if ((tok == CONFIG_MANYCASTCLIENT) && - !IN_CLASSD(ntohl(((struct sockaddr_in*)&peeraddr)->sin_addr.s_addr))) { - msyslog(LOG_ERR, - "attempt to configure invalid address %s", - stoa(&peeraddr)); - break; - } - } - else if(peeraddr.ss_family == AF_INET6) { - if (((tok == CONFIG_SERVER) || - (tok == CONFIG_PEER)) && -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && -#endif - IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)&peeraddr)->sin6_addr)) { - msyslog(LOG_ERR, - "attempt to configure in valid address %s", - stoa(&peeraddr)); - break; - } - if ((tok == CONFIG_MANYCASTCLIENT) && - !IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)&peeraddr)->sin6_addr)) { - msyslog(LOG_ERR, - "attempt to configure in valid address %s", - stoa(&peeraddr)); - break; - } - } - } - if (peeraddr.ss_family == AF_INET6 && - isc_net_probeipv6() != ISC_R_SUCCESS) - break; - - peerversion = NTP_VERSION; - minpoll = NTP_MINDPOLL; - maxpoll = NTP_MAXDPOLL; - peerkey = 0; - peerkeystr = (u_char *)"*"; - peerflags = 0; - ttl = 0; - istart++; - for (i = istart; i < ntokens; i++) - switch (matchkey(tokens[i], mod_keywords, 1)) { - case CONF_MOD_VERSION: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "peer/server version requires an argument"); - errflg = 1; - break; - } - peerversion = atoi(tokens[++i]); - if ((u_char)peerversion > NTP_VERSION - || (u_char)peerversion < NTP_OLDVERSION) { - msyslog(LOG_ERR, - "inappropriate version number %s, line ignored", - tokens[i]); - errflg = 1; - } - break; - - case CONF_MOD_KEY: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "key: argument required"); - errflg = 1; - break; - } - peerkey = (int)atol(tokens[++i]); - peerflags |= FLAG_AUTHENABLE; - break; - - case CONF_MOD_MINPOLL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "minpoll: argument required"); - errflg = 1; - break; - } - minpoll = atoi(tokens[++i]); - if (minpoll < NTP_MINPOLL) { - msyslog(LOG_INFO, - "minpoll: provided value (%d) is below minimum (%d)", - minpoll, NTP_MINPOLL); - minpoll = NTP_MINPOLL; - } - break; - - case CONF_MOD_MAXPOLL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "maxpoll: argument required" - ); - errflg = 1; - break; - } - maxpoll = atoi(tokens[++i]); - if (maxpoll > NTP_MAXPOLL) { - msyslog(LOG_INFO, - "maxpoll: provided value (%d) is above maximum (%d)", - maxpoll, NTP_MAXPOLL); - maxpoll = NTP_MAXPOLL; - } - break; - - case CONF_MOD_PREFER: - peerflags |= FLAG_PREFER; - break; - - case CONF_MOD_PREEMPT: - peerflags |= FLAG_PREEMPT; - break; - - case CONF_MOD_NOSELECT: - peerflags |= FLAG_NOSELECT; - break; - - case CONF_MOD_TRUE: - peerflags |= FLAG_TRUE; - - case CONF_MOD_BURST: - peerflags |= FLAG_BURST; - break; - - case CONF_MOD_IBURST: - peerflags |= FLAG_IBURST; - break; - - case CONF_MOD_DYNAMIC: - msyslog(LOG_WARNING, - "Warning: the \"dynamic\" keyword has been obsoleted" - " and will be removed in the next release\n"); - break; - -#ifdef OPENSSL - case CONF_MOD_SKEY: - peerflags |= FLAG_SKEY | - FLAG_AUTHENABLE; - break; -#endif /* OPENSSL */ - - case CONF_MOD_TTL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "ttl: argument required"); - errflg = 1; - break; - } - ttl = atoi(tokens[++i]); - if (ttl >= MAX_TTL) { - msyslog(LOG_ERR, - "ttl: invalid argument"); - errflg = 1; - } - break; - - case CONF_MOD_MODE: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "mode: argument required"); - errflg = 1; - break; - } - ttl = atoi(tokens[++i]); - break; - - case CONFIG_UNKNOWN: - errflg = 1; - break; - } - if (minpoll > maxpoll) { - msyslog(LOG_ERR, - "config error: minpoll > maxpoll"); - errflg = 1; - } - if (errflg == 0) { - if (peer_config(&peeraddr, - ANY_INTERFACE_CHOOSE(&peeraddr), hmode, - peerversion, minpoll, maxpoll, peerflags, - ttl, peerkey, peerkeystr) == 0) { - msyslog(LOG_ERR, - "configuration of %s failed", - stoa(&peeraddr)); - } - } else if (errflg == -1) { - save_resolve(tokens[istart - 1], hmode, peerversion, - minpoll, maxpoll, peerflags, ttl, - peerkey, peerkeystr, peeraddr.ss_family); - } + case AF_UNSPEC: break; - case CONFIG_DRIFTFILE: - if (ntokens >= 2) - stats_config(STATS_FREQ_FILE, tokens[1]); - else - stats_config(STATS_FREQ_FILE, (char *)0); - stats_write_period = stats_write_tolerance = 0; - if (ntokens >= 3) - stats_write_period = 60 * atol(tokens[2]); - if (stats_write_period <= 0) - stats_write_period = 3600; - if (ntokens >= 4) { - double ftemp; - sscanf(tokens[3], "%lf", &ftemp); - stats_write_tolerance = ftemp / 100; - } - break; - - case CONFIG_PIDFILE: - if (ntokens >= 2) - stats_config(STATS_PID_FILE, tokens[1]); - else - stats_config(STATS_PID_FILE, (char *)0); + case AF_INET: + fprintf(df, " -4"); break; - case CONFIG_END: - for ( i = 0; i <= includelevel; i++ ) { - fclose(fp[i]); - } - break; - - case CONFIG_INCLUDEFILE: - if (ntokens < 2) { - msyslog(LOG_ERR, "includefile needs one argument"); - break; - } - if (includelevel >= MAXINCLUDELEVEL) { - fprintf(stderr, "getconfig: Maximum include file level exceeded.\n"); - msyslog(LOG_INFO, "getconfig: Maximum include file level exceeded."); - break; - } - includefile = fopen(FindConfig(tokens[1]), "r"); - if (includefile == NULL) { - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(tokens[1])); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(tokens[1])); - break; - } - fp[++includelevel] = includefile; + case AF_INET6: + fprintf(df, " -6"); break; + } + fprintf(df, " %s", addr->address); - case CONFIG_LOGFILE: - if (ntokens >= 2) { - FILE *new_file; + if (peern->minpoll != 0) + fprintf(df, " minpoll %u", peern->minpoll); - new_file = fopen(tokens[1], "a"); - if (new_file != NULL) { - NLOG(NLOG_SYSINFO) /* conditional if clause for conditional syslog */ - msyslog(LOG_NOTICE, "logging to file %s", tokens[1]); - if (syslog_file != NULL && - fileno(syslog_file) != fileno(new_file)) - (void)fclose(syslog_file); + if (peern->maxpoll != 0) + fprintf(df, " maxpoll %u", peern->maxpoll); - syslog_file = new_file; - syslogit = 0; - } - else - msyslog(LOG_ERR, - "Cannot open log file %s", - tokens[1]); - } + if (peern->ttl != 0) { + if (strlen(addr->address) > 8 + && !memcmp(addr->address, "127.127.", 8)) + fprintf(df, " mode %u", peern->ttl); else - msyslog(LOG_ERR, "logfile needs one argument"); - break; - - case CONFIG_LOGCONFIG: - for (i = 1; i < ntokens; i++) - { - int add = 1; - int equals = 0; - char * s = &tokens[i][0]; - - switch (*s) { - case '+': - case '-': - case '=': - add = *s == '+'; - equals = *s == '='; - s++; + fprintf(df, " ttl %u", peern->ttl); + } + + if (peern->peerversion != NTP_VERSION) + fprintf(df, " version %u", peern->peerversion); + + if (peern->peerkey != 0) + fprintf(df, " key %u", peern->peerkey); + + if (peern->group != NULL) + fprintf(df, " ident \"%s\"", peern->group); + + atrv = HEAD_PFIFO(peern->peerflags); + for ( ; atrv != NULL; atrv = atrv->link) { + INSIST(T_Flag == atrv->attr); + INSIST(T_Integer == atrv->type); + fprintf(df, " %s", keyword(atrv->value.i)); + } + + fprintf(df, "\n"); + + addr_opts = HEAD_PFIFO(ptree->fudge); + for ( ; addr_opts != NULL; addr_opts = addr_opts->link) { + peer_addr = peern->addr; + fudge_addr = addr_opts->addr; + + s1 = peer_addr->address; + s2 = fudge_addr->address; + + if (strcmp(s1, s2)) + continue; + + fprintf(df, "fudge %s", s1); + + for (atrv = HEAD_PFIFO(addr_opts->options); + atrv != NULL; + atrv = atrv->link) { + + switch (atrv->type) { +#ifdef DEBUG + default: + fprintf(df, "\n# dump error:\n" + "# unknown fudge atrv->type %d\n" + "fudge %s", atrv->type, + s1); + break; +#endif + case T_Double: + fprintf(df, " %s %s", + keyword(atrv->attr), + normal_dtoa(atrv->value.d)); break; - default: + case T_Integer: + fprintf(df, " %s %d", + keyword(atrv->attr), + atrv->value.i); + break; + + case T_String: + fprintf(df, " %s %s", + keyword(atrv->attr), + atrv->value.s); break; } - if (equals) { - ntp_syslogmask = get_logmask(s); - } else { - if (add) { - ntp_syslogmask |= get_logmask(s); - } else { - ntp_syslogmask &= ~get_logmask(s); - } - } -#ifdef DEBUG - if (debug) - printf("ntp_syslogmask = 0x%08lx (%s)\n", ntp_syslogmask, tokens[i]); -#endif } - break; + fprintf(df, "\n"); + } + } - case CONFIG_BROADCASTCLIENT: - if (ntokens == 1) { - proto_config(PROTO_BROADCLIENT, 1, 0., NULL); - } else { - proto_config(PROTO_BROADCLIENT, 2, 0., NULL); - } - break; + addr = HEAD_PFIFO(ptree->manycastserver); + if (addr != NULL) { + fprintf(df, "manycastserver"); + for ( ; addr != NULL; addr = addr->link) + fprintf(df, " %s", addr->address); + fprintf(df, "\n"); + } - case CONFIG_MULTICASTCLIENT: - case CONFIG_MANYCASTSERVER: - if (ntokens > 1) { - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], - addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; - break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; + addr = HEAD_PFIFO(ptree->multicastclient); + if (addr != NULL) { + fprintf(df, "multicastclient"); + for ( ; addr != NULL; addr = addr->link) + fprintf(df, " %s", addr->address); + fprintf(df, "\n"); + } + + + for (unpeern = HEAD_PFIFO(ptree->unpeers); + unpeern != NULL; + unpeern = unpeern->link) + fprintf(df, "unpeer %s\n", unpeern->addr->address); + + atrv = HEAD_PFIFO(ptree->mru_opts); + if (atrv != NULL) { + fprintf(df, "mru"); + for ( ; atrv != NULL; atrv = atrv->link) + fprintf(df, " %s %d", keyword(atrv->attr), + atrv->value.i); + fprintf(df, "\n"); + } + + atrv = HEAD_PFIFO(ptree->discard_opts); + if (atrv != NULL) { + fprintf(df, "discard"); + for ( ; atrv != NULL; atrv = atrv->link) + fprintf(df, " %s %d", keyword(atrv->attr), + atrv->value.i); + fprintf(df, "\n"); + } + + + for (rest_node = HEAD_PFIFO(ptree->restrict_opts); + rest_node != NULL; + rest_node = rest_node->link) { + + if (NULL == rest_node->addr) { + s = "default"; + flags = HEAD_PFIFO(rest_node->flags); + for ( ; flags != NULL; flags = flags->link) + if (T_Source == flags->i) { + s = "source"; break; } - /* - * Abuse maskaddr to store the prefered ip - * version. - */ - memset((char *)&maskaddr, 0, sizeof(maskaddr)); - maskaddr.ss_family = peeraddr.ss_family; - - for (i = istart; i < ntokens; i++) { - memset((char *)&peeraddr, 0, - sizeof(peeraddr)); - peeraddr.ss_family = maskaddr.ss_family; - if (getnetnum(tokens[i], &peeraddr, 1, - t_UNK) == 1) - proto_config(PROTO_MULTICAST_ADD, - 0, 0., &peeraddr); - } - } else - proto_config(PROTO_MULTICAST_ADD, - 0, 0., NULL); - if (tok == CONFIG_MULTICASTCLIENT) - proto_config(PROTO_MULTICAST_ADD, 1, 0., NULL); - else if (tok == CONFIG_MANYCASTSERVER) - sys_manycastserver = 1; - break; + } else { + s = rest_node->addr->address; + } + fprintf(df, "restrict %s", s); + if (rest_node->mask != NULL) + fprintf(df, " mask %s", + rest_node->mask->address); + flags = HEAD_PFIFO(rest_node->flags); + for ( ; flags != NULL; flags = flags->link) + if (T_Source != flags->i) + fprintf(df, " %s", keyword(flags->i)); + fprintf(df, "\n"); + } - case CONFIG_KEYS: - if (ntokens >= 2) { - getauthkeys(tokens[1]); - } - break; + rule_node = HEAD_PFIFO(ptree->nic_rules); + for ( ; rule_node != NULL; rule_node = rule_node->link) { + fprintf(df, "interface %s %s\n", + keyword(rule_node->action), + (rule_node->match_class) + ? keyword(rule_node->match_class) + : rule_node->if_name); + } - case CONFIG_KEYSDIR: - if (ntokens < 2) { - msyslog(LOG_ERR, - "Keys directory name required"); - break; - } - keysdir = (char *)emalloc(strlen(tokens[1]) + 1); - strcpy(keysdir, tokens[1]); - break; + str_node = HEAD_PFIFO(ptree->phone); + if (str_node != NULL) { + fprintf(df, "phone"); + for ( ; str_node != NULL; str_node = str_node->link) + fprintf(df, " \"%s\"", str_node->s); + fprintf(df, "\n"); + } - case CONFIG_TINKER: - for (i = 1; i < ntokens; i++) { - int temp; - double ftemp; + setv_node = HEAD_PFIFO(ptree->setvar); + for ( ; setv_node != NULL; setv_node = setv_node->link) { + s1 = quote_if_needed(setv_node->var); + s2 = quote_if_needed(setv_node->val); + fprintf(df, "setvar %s = %s", s1, s2); + free(s1); + free(s2); + if (setv_node->isdefault) + fprintf(df, " default"); + fprintf(df, "\n"); + } - temp = matchkey(tokens[i++], tinker_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "tinker: missing argument"); - errflg++; - break; - } - sscanf(tokens[i], "%lf", &ftemp); - switch(temp) { + i_n = HEAD_PFIFO(ptree->ttl); + if (i_n != NULL) { + fprintf(df, "ttl"); + for( ; i_n != NULL; i_n = i_n->link) + fprintf(df, " %d", i_n->i); + fprintf(df, "\n"); + } - case CONF_CLOCK_MAX: - loop_config(LOOP_MAX, ftemp); + addr_opts = HEAD_PFIFO(ptree->trap); + for ( ; addr_opts != NULL; addr_opts = addr_opts->link) { + addr = addr_opts->addr; + fprintf(df, "trap %s", addr->address); + atrv = HEAD_PFIFO(addr_opts->options); + for ( ; atrv != NULL; atrv = atrv->link) { + switch (atrv->attr) { +#ifdef DEBUG + default: + fprintf(df, "\n# dump error:\n" + "# unknown trap token %d\n" + "trap %s", atrv->attr, + addr->address); break; - - case CONF_CLOCK_PANIC: - loop_config(LOOP_PANIC, ftemp); +#endif + case T_Port: + fprintf(df, " port %d", atrv->value.i); break; - case CONF_CLOCK_PHI: - loop_config(LOOP_PHI, ftemp); + case T_Interface: + fprintf(df, " interface %s", + atrv->value.s); break; + } + } + fprintf(df, "\n"); + } - case CONF_CLOCK_MINSTEP: - loop_config(LOOP_MINSTEP, ftemp); - break; + counter_set = HEAD_PFIFO(ptree->reset_counters); + if (counter_set != NULL) { + fprintf(df, "reset"); + for ( ; counter_set != NULL; + counter_set = counter_set->link) + fprintf(df, " %s", keyword(counter_set->i)); + fprintf(df, "\n"); + } - case CONF_CLOCK_ALLAN: - loop_config(LOOP_ALLAN, ftemp); - break; + return 0; +} +#endif /* SAVECONFIG */ - case CONF_CLOCK_HUFFPUFF: - loop_config(LOOP_HUFFPUFF, ftemp); - break; - case CONF_CLOCK_FREQ: - loop_config(LOOP_FREQ, ftemp); - break; - } - } - break; - case CONFIG_TOS: - for (i = 1; i < ntokens; i++) { - int temp; - double ftemp; +/* generic fifo routines for structs linked by 1st member */ +void * +append_gen_fifo( + void *fifo, + void *entry + ) +{ + gen_fifo *pf; + gen_node *pe; - temp = matchkey(tokens[i++], tos_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "tos: missing argument"); - errflg++; - break; - } - sscanf(tokens[i], "%lf", &ftemp); - switch(temp) { + pf = fifo; + pe = entry; + if (NULL == pf) + pf = emalloc_zero(sizeof(*pf)); + else + CHECK_FIFO_CONSISTENCY(*pf); + if (pe != NULL) + LINK_FIFO(*pf, pe, link); + CHECK_FIFO_CONSISTENCY(*pf); - case CONF_TOS_MINCLOCK: - proto_config(PROTO_MINCLOCK, 0, ftemp, NULL); - break; + return pf; +} - case CONF_TOS_MAXCLOCK: - proto_config(PROTO_MAXCLOCK, 0, ftemp, NULL); - break; - case CONF_TOS_MINSANE: - proto_config(PROTO_MINSANE, 0, ftemp, NULL); - break; +void * +concat_gen_fifos( + void *first, + void *second + ) +{ + gen_fifo *pf1; + gen_fifo *pf2; - case CONF_TOS_FLOOR: - proto_config(PROTO_FLOOR, 0, ftemp, NULL); - break; + pf1 = first; + pf2 = second; + if (NULL == pf1) + return pf2; + if (NULL == pf2) + return pf1; - case CONF_TOS_CEILING: - proto_config(PROTO_CEILING, 0, ftemp, NULL); - break; + CONCAT_FIFO(*pf1, *pf2, link); + free(pf2); - case CONF_TOS_COHORT: - proto_config(PROTO_COHORT, 0, ftemp, NULL); - break; + return pf1; +} - case CONF_TOS_MINDISP: - proto_config(PROTO_MINDISP, 0, ftemp, NULL); - break; - case CONF_TOS_MAXDIST: - proto_config(PROTO_MAXDIST, 0, ftemp, NULL); - break; +/* FUNCTIONS FOR CREATING NODES ON THE SYNTAX TREE + * ----------------------------------------------- + */ - case CONF_TOS_MAXHOP: - proto_config(PROTO_MAXHOP, 0, ftemp, NULL); - break; +attr_val * +create_attr_dval( + int attr, + double value + ) +{ + attr_val *my_val; - case CONF_TOS_ORPHAN: - proto_config(PROTO_ORPHAN, 0, ftemp, NULL); - break; + my_val = emalloc_zero(sizeof(*my_val)); + my_val->attr = attr; + my_val->value.d = value; + my_val->type = T_Double; - case CONF_TOS_BEACON: - proto_config(PROTO_BEACON, 0, ftemp, NULL); - break; - } - } - break; + return my_val; +} - case CONFIG_TTL: - for (i = 1; i < ntokens && i < MAX_TTL; i++) { - sys_ttl[i - 1] = (u_char) atoi(tokens[i]); - sys_ttlmax = i - 1; - } - break; - case CONFIG_DISCARD: - for (i = 1; i < ntokens; i++) { - int temp; +attr_val * +create_attr_ival( + int attr, + int value + ) +{ + attr_val *my_val; - temp = matchkey(tokens[i++], - discard_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "discard: missing argument"); - errflg++; - break; - } - switch(temp) { - case CONF_DISCARD_AVERAGE: - res_avg_interval = atoi(tokens[i]); - break; + my_val = emalloc_zero(sizeof(*my_val)); + my_val->attr = attr; + my_val->value.i = value; + my_val->type = T_Integer; - case CONF_DISCARD_MINIMUM: - res_min_interval = atoi(tokens[i]); - break; + return my_val; +} - case CONF_DISCARD_MONITOR: - mon_age = atoi(tokens[i]); - break; - default: - msyslog(LOG_ERR, - "discard: unknown keyword"); - break; - } - } - break; +attr_val * +create_attr_uval( + int attr, + u_int value + ) +{ + attr_val *my_val; -#ifdef OPENSSL - case CONFIG_REVOKE: - if (ntokens >= 2) - sys_revoke = (u_char) max(atoi(tokens[1]), KEY_REVOKE); - break; + my_val = emalloc_zero(sizeof(*my_val)); + my_val->attr = attr; + my_val->value.u = value; + my_val->type = T_U_int; - case CONFIG_AUTOMAX: - if (ntokens >= 2) - sys_automax = 1 << max(atoi(tokens[1]), 10); - break; + return my_val; +} - case CONFIG_CRYPTO: - if (ntokens == 1) { - crypto_config(CRYPTO_CONF_NONE, NULL); - break; - } - for (i = 1; i < ntokens; i++) { - int temp; - temp = matchkey(tokens[i++], - crypto_keywords, 1); - if (i > ntokens - 1) { - msyslog(LOG_ERR, - "crypto: missing argument"); - errflg++; - break; - } - switch(temp) { +attr_val * +create_attr_rangeval( + int attr, + int first, + int last + ) +{ + attr_val *my_val; - case CONF_CRYPTO_CERT: - crypto_config(CRYPTO_CONF_CERT, - tokens[i]); - break; + my_val = emalloc_zero(sizeof(*my_val)); + my_val->attr = attr; + my_val->value.r.first = first; + my_val->value.r.last = last; + my_val->type = T_Intrange; - case CONF_CRYPTO_RSA: - crypto_config(CRYPTO_CONF_PRIV, - tokens[i]); - break; + return my_val; +} - case CONF_CRYPTO_IDENT: - crypto_config(CRYPTO_CONF_IDENT, - tokens[i]); - break; - case CONF_CRYPTO_IFFPAR: - crypto_config(CRYPTO_CONF_IFFPAR, - tokens[i]); - break; +attr_val * +create_attr_sval( + int attr, + const char *s + ) +{ + attr_val *my_val; - case CONF_CRYPTO_GQPAR: - crypto_config(CRYPTO_CONF_GQPAR, - tokens[i]); - break; + my_val = emalloc_zero(sizeof(*my_val)); + my_val->attr = attr; + if (NULL == s) /* free() hates NULL */ + s = estrdup(""); + my_val->value.s = _UC(s); + my_val->type = T_String; - case CONF_CRYPTO_MVPAR: - crypto_config(CRYPTO_CONF_MVPAR, - tokens[i]); - break; + return my_val; +} - case CONF_CRYPTO_LEAP: - crypto_config(CRYPTO_CONF_LEAP, - tokens[i]); - break; - case CONF_CRYPTO_PW: - crypto_config(CRYPTO_CONF_PW, - tokens[i]); - break; +int_node * +create_int_node( + int val + ) +{ + int_node *i_n; - case CONF_CRYPTO_RAND: - crypto_config(CRYPTO_CONF_RAND, - tokens[i]); - break; + i_n = emalloc_zero(sizeof(*i_n)); + i_n->i = val; - case CONF_CRYPTO_SIGN: - crypto_config(CRYPTO_CONF_SIGN, - tokens[i]); - break; + return i_n; +} - default: - msyslog(LOG_ERR, - "crypto: unknown keyword"); - break; - } - } - break; -#endif /* OPENSSL */ - case CONFIG_RESTRICT: - if (ntokens < 2) { - msyslog(LOG_ERR, "restrict requires an address"); - break; - } - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; - break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; - break; - } +string_node * +create_string_node( + char *str + ) +{ + string_node *sn; - /* - * Assume default means an IPv4 address, except - * if forced by a -4 or -6. - */ - if (STREQ(tokens[istart], "default")) { - if (peeraddr.ss_family == 0) - peeraddr.ss_family = AF_INET; - } else if (getnetnum(tokens[istart], &peeraddr, 1, - t_UNK) != 1) - break; + sn = emalloc_zero(sizeof(*sn)); + sn->s = str; - /* - * Use peerversion as flags, peerkey as mflags. Ick. - */ - peerversion = 0; - peerkey = 0; - errflg = 0; - SET_HOSTMASK(&maskaddr, peeraddr.ss_family); - istart++; - for (i = istart; i < ntokens; i++) { - switch (matchkey(tokens[i], res_keywords, 1)) { - case CONF_RES_MASK: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "mask keyword needs argument"); - errflg++; - break; - } - i++; - if (getnetnum(tokens[i], &maskaddr, 1, - t_MSK) != 1) - errflg++; - break; + return sn; +} - case CONF_RES_IGNORE: - peerversion |= RES_IGNORE; - break; - case CONF_RES_NOSERVE: - peerversion |= RES_DONTSERVE; - break; +address_node * +create_address_node( + char * addr, + int type + ) +{ + address_node *my_node; - case CONF_RES_NOTRUST: - peerversion |= RES_DONTTRUST; - break; + REQUIRE(NULL != addr); + REQUIRE(AF_INET == type || AF_INET6 == type || AF_UNSPEC == type); + my_node = emalloc_zero(sizeof(*my_node)); + my_node->address = addr; + my_node->type = (u_short)type; - case CONF_RES_NOQUERY: - peerversion |= RES_NOQUERY; - break; + return my_node; +} - case CONF_RES_NOMODIFY: - peerversion |= RES_NOMODIFY; - break; - case CONF_RES_NOPEER: - peerversion |= RES_NOPEER; - break; +void +destroy_address_node( + address_node *my_node + ) +{ + if (NULL == my_node) + return; + REQUIRE(NULL != my_node->address); - case CONF_RES_NOTRAP: - peerversion |= RES_NOTRAP; - break; + free(my_node->address); + free(my_node); +} - case CONF_RES_LPTRAP: - peerversion |= RES_LPTRAP; - break; - case CONF_RES_NTPPORT: - peerkey |= RESM_NTPONLY; - break; +peer_node * +create_peer_node( + int hmode, + address_node * addr, + attr_val_fifo * options + ) +{ + peer_node *my_node; + attr_val *option; + int freenode; + int errflag = 0; - case CONF_RES_VERSION: - peerversion |= RES_VERSION; - break; + my_node = emalloc_zero(sizeof(*my_node)); - case CONF_RES_DEMOBILIZE: - peerversion |= RES_DEMOBILIZE; - break; + /* Initialize node values to default */ + my_node->peerversion = NTP_VERSION; - case CONF_RES_LIMITED: - peerversion |= RES_LIMITED; - break; + /* Now set the node to the read values */ + my_node->host_mode = hmode; + my_node->addr = addr; - case CONFIG_UNKNOWN: - errflg++; - break; - } - } - if (SOCKNUL(&peeraddr)) - ANYSOCK(&maskaddr); - if (!errflg) - hack_restrict(RESTRICT_FLAGS, &peeraddr, &maskaddr, - (int)peerkey, peerversion); + /* + * the options FIFO mixes items that will be saved in the + * peer_node as explicit members, such as minpoll, and + * those that are moved intact to the peer_node's peerflags + * FIFO. The options FIFO is consumed and reclaimed here. + */ + + if (options != NULL) + CHECK_FIFO_CONSISTENCY(*options); + while (options != NULL) { + UNLINK_FIFO(option, *options, link); + if (NULL == option) { + free(options); break; + } - case CONFIG_BDELAY: - if (ntokens >= 2) { - double tmp; + freenode = 1; + /* Check the kind of option being set */ + switch (option->attr) { - if (sscanf(tokens[1], "%lf", &tmp) != 1) { - msyslog(LOG_ERR, - "broadcastdelay value %s undecodable", - tokens[1]); - } else { - proto_config(PROTO_BROADDELAY, 0, tmp, NULL); - } - } + case T_Flag: + APPEND_G_FIFO(my_node->peerflags, option); + freenode = 0; break; - case CONFIG_CDELAY: - if (ntokens >= 2) { - u_long ui; - - if (sscanf(tokens[1], "%ld", &ui) != 1) - msyslog(LOG_ERR, - "illegal value - line ignored"); - else - proto_config(PROTO_CALLDELAY, ui, 0, NULL); + case T_Minpoll: + if (option->value.i < NTP_MINPOLL || + option->value.i > UCHAR_MAX) { + msyslog(LOG_INFO, + "minpoll: provided value (%d) is out of range [%d-%d])", + option->value.i, NTP_MINPOLL, + UCHAR_MAX); + my_node->minpoll = NTP_MINPOLL; + } else { + my_node->minpoll = + (u_char)option->value.u; } break; - case CONFIG_TRUSTEDKEY: - for (i = 1; i < ntokens; i++) { - keyid_t tkey; - - tkey = atol(tokens[i]); - if (tkey == 0) { - msyslog(LOG_ERR, - "trusted key %s unlikely", - tokens[i]); - } else { - authtrust(tkey, 1); - } + case T_Maxpoll: + if (option->value.i < 0 || + option->value.i > NTP_MAXPOLL) { + msyslog(LOG_INFO, + "maxpoll: provided value (%d) is out of range [0-%d])", + option->value.i, NTP_MAXPOLL); + my_node->maxpoll = NTP_MAXPOLL; + } else { + my_node->maxpoll = + (u_char)option->value.u; } break; - case CONFIG_REQUESTKEY: - if (ntokens >= 2) { - if (!atouint(tokens[1], &ul)) { - msyslog(LOG_ERR, - "%s is undecodable as request key", - tokens[1]); - } else if (ul == 0) { - msyslog(LOG_ERR, - "%s makes a poor request keyid", - tokens[1]); - } else { -#ifdef DEBUG - if (debug > 3) - printf( - "set info_auth_key to %08lx\n", ul); -#endif - info_auth_keyid = (keyid_t)ul; - } + case T_Ttl: + if (option->value.u >= MAX_TTL) { + msyslog(LOG_ERR, "ttl: invalid argument"); + errflag = 1; + } else { + my_node->ttl = (u_char)option->value.u; } break; - case CONFIG_CONTROLKEY: - if (ntokens >= 2) { - keyid_t ckey; + case T_Mode: + my_node->ttl = option->value.u; + break; - ckey = atol(tokens[1]); - if (ckey == 0) { - msyslog(LOG_ERR, - "%s makes a poor control keyid", - tokens[1]); - } else { - ctl_auth_keyid = ckey; - } + case T_Key: + if (option->value.u >= KEYID_T_MAX) { + msyslog(LOG_ERR, "key: invalid argument"); + errflag = 1; + } else { + my_node->peerkey = + (keyid_t)option->value.u; } break; - case CONFIG_TRAP: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no address for trap command, line ignored"); - break; - } - istart = 1; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - peeraddr.ss_family = default_ai_family; - switch (matchkey(tokens[istart], addr_type, 0)) { - case CONF_ADDR_IPV4: - peeraddr.ss_family = AF_INET; - istart++; - break; - case CONF_ADDR_IPV6: - peeraddr.ss_family = AF_INET6; - istart++; - break; + case T_Version: + if (option->value.u >= UCHAR_MAX) { + msyslog(LOG_ERR, "version: invalid argument"); + errflag = 1; + } else { + my_node->peerversion = + (u_char)option->value.u; } + break; - if (getnetnum(tokens[istart], &peeraddr, 1, t_UNK) != 1) - break; + case T_Ident: + my_node->group = option->value.s; + break; - /* - * Use peerversion for port number. Barf. - */ - errflg = 0; - peerversion = 0; - localaddr = 0; - istart++; - for (i = istart; i < ntokens-1; i++) - switch (matchkey(tokens[i], trap_keywords, 1)) { - case CONF_TRAP_PORT: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "trap port requires an argument"); - errflg = 1; - break; - } - peerversion = atoi(tokens[++i]); - if (peerversion <= 0 - || peerversion > 32767) { - msyslog(LOG_ERR, - "invalid port number %s, trap ignored", - tokens[i]); - errflg = 1; - } - break; - - case CONF_TRAP_INTERFACE: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "trap interface requires an argument"); - errflg = 1; - break; - } - - memset((char *)&maskaddr, 0, - sizeof(maskaddr)); - maskaddr.ss_family = peeraddr.ss_family; - if (getnetnum(tokens[++i], - &maskaddr, 1, t_UNK) != 1) { - errflg = 1; - break; - } - - localaddr = findinterface(&maskaddr); - if (localaddr == NULL) { - msyslog(LOG_ERR, - "can't find interface with address %s", - stoa(&maskaddr)); - errflg = 1; - } - break; - - case CONFIG_UNKNOWN: - errflg++; - break; - } - - if (!errflg) { - if (peerversion != 0) - ((struct sockaddr_in6*)&peeraddr)->sin6_port = htons( (u_short) peerversion); + default: + msyslog(LOG_ERR, + "Unknown peer/server option token %s", + token_name(option->attr)); + errflag = 1; + } + if (freenode) + free(option); + } + + /* Check if errors were reported. If yes, ignore the node */ + if (errflag) { + free(my_node); + my_node = NULL; + } + + return my_node; +} + + +unpeer_node * +create_unpeer_node( + address_node *addr + ) +{ + unpeer_node * my_node; + u_int u; + char * pch; + + my_node = emalloc_zero(sizeof(*my_node)); + + /* + * From the parser's perspective an association ID fits into + * its generic T_String definition of a name/address "address". + * We treat all valid 16-bit numbers as association IDs. + */ + pch = addr->address; + while (*pch && isdigit((unsigned char)*pch)) + pch++; + + if (!*pch + && 1 == sscanf(addr->address, "%u", &u) + && u <= ASSOCID_MAX) { + my_node->assocID = (associd_t)u; + destroy_address_node(addr); + my_node->addr = NULL; + } else { + my_node->assocID = 0; + my_node->addr = addr; + } + + return my_node; +} + +filegen_node * +create_filegen_node( + int filegen_token, + attr_val_fifo * options + ) +{ + filegen_node *my_node; + + my_node = emalloc_zero(sizeof(*my_node)); + my_node->filegen_token = filegen_token; + my_node->options = options; + + return my_node; +} + + +restrict_node * +create_restrict_node( + address_node * addr, + address_node * mask, + int_fifo * flags, + int line_no + ) +{ + restrict_node *my_node; + + my_node = emalloc_zero(sizeof(*my_node)); + my_node->addr = addr; + my_node->mask = mask; + my_node->flags = flags; + my_node->line_no = line_no; + + return my_node; +} + + +static void +destroy_restrict_node( + restrict_node *my_node + ) +{ + /* With great care, free all the memory occupied by + * the restrict node + */ + destroy_address_node(my_node->addr); + destroy_address_node(my_node->mask); + destroy_int_fifo(my_node->flags); + free(my_node); +} + + +static void +destroy_int_fifo( + int_fifo * fifo + ) +{ + int_node * i_n; + + if (fifo != NULL) { + for (;;) { + UNLINK_FIFO(i_n, *fifo, link); + if (i_n == NULL) + break; + free(i_n); + } + free(fifo); + } +} + + +static void +destroy_string_fifo( + string_fifo * fifo + ) +{ + string_node * sn; + + if (fifo != NULL) { + for (;;) { + UNLINK_FIFO(sn, *fifo, link); + if (sn == NULL) + break; + free(sn->s); + free(sn); + } + free(fifo); + } +} + + +static void +destroy_attr_val_fifo( + attr_val_fifo * av_fifo + ) +{ + attr_val * av; + + if (av_fifo != NULL) { + for (;;) { + UNLINK_FIFO(av, *av_fifo, link); + if (av == NULL) + break; + if (T_String == av->type) + free(av->value.s); + free(av); + } + free(av_fifo); + } +} + + +static void +destroy_filegen_fifo( + filegen_fifo * fifo + ) +{ + filegen_node * fg; + + if (fifo != NULL) { + for (;;) { + UNLINK_FIFO(fg, *fifo, link); + if (fg == NULL) + break; + destroy_attr_val_fifo(fg->options); + free(fg); + } + free(fifo); + } +} + + +static void +destroy_restrict_fifo( + restrict_fifo * fifo + ) +{ + restrict_node * rn; + + if (fifo != NULL) { + for (;;) { + UNLINK_FIFO(rn, *fifo, link); + if (rn == NULL) + break; + destroy_restrict_node(rn); + } + free(fifo); + } +} + + +static void +destroy_setvar_fifo( + setvar_fifo * fifo + ) +{ + setvar_node * sv; + + if (fifo != NULL) { + for (;;) { + UNLINK_FIFO(sv, *fifo, link); + if (sv == NULL) + break; + free(sv->var); + free(sv->val); + free(sv); + } + free(fifo); + } +} + + +static void +destroy_addr_opts_fifo( + addr_opts_fifo * fifo + ) +{ + addr_opts_node * aon; + + if (fifo != NULL) { + for (;;) { + UNLINK_FIFO(aon, *fifo, link); + if (aon == NULL) + break; + destroy_address_node(aon->addr); + destroy_attr_val_fifo(aon->options); + free(aon); + } + free(fifo); + } +} + + +setvar_node * +create_setvar_node( + char * var, + char * val, + int isdefault + ) +{ + setvar_node * my_node; + char * pch; + + /* do not allow = in the variable name */ + pch = strchr(var, '='); + if (NULL != pch) + *pch = '\0'; + + /* Now store the string into a setvar_node */ + my_node = emalloc_zero(sizeof(*my_node)); + my_node->var = var; + my_node->val = val; + my_node->isdefault = isdefault; + + return my_node; +} + + +nic_rule_node * +create_nic_rule_node( + int match_class, + char *if_name, /* interface name or numeric address */ + int action + ) +{ + nic_rule_node *my_node; + + REQUIRE(match_class != 0 || if_name != NULL); + + my_node = emalloc_zero(sizeof(*my_node)); + my_node->match_class = match_class; + my_node->if_name = if_name; + my_node->action = action; + + return my_node; +} + + +addr_opts_node * +create_addr_opts_node( + address_node * addr, + attr_val_fifo * options + ) +{ + addr_opts_node *my_node; + + my_node = emalloc_zero(sizeof(*my_node)); + my_node->addr = addr; + my_node->options = options; + + return my_node; +} + + +#ifdef SIM +script_info * +create_sim_script_info( + double duration, + attr_val_fifo * script_queue + ) +{ + script_info *my_info; + attr_val *my_attr_val; + + my_info = emalloc_zero(sizeof(*my_info)); + + /* Initialize Script Info with default values*/ + my_info->duration = duration; + my_info->prop_delay = NET_DLY; + my_info->proc_delay = PROC_DLY; + + /* Traverse the script_queue and fill out non-default values */ + + for (my_attr_val = HEAD_PFIFO(script_queue); + my_attr_val != NULL; + my_attr_val = my_attr_val->link) { + + /* Set the desired value */ + switch (my_attr_val->attr) { + + case T_Freq_Offset: + my_info->freq_offset = my_attr_val->value.d; + break; + + case T_Wander: + my_info->wander = my_attr_val->value.d; + break; + + case T_Jitter: + my_info->jitter = my_attr_val->value.d; + break; + + case T_Prop_Delay: + my_info->prop_delay = my_attr_val->value.d; + break; + + case T_Proc_Delay: + my_info->proc_delay = my_attr_val->value.d; + break; + + default: + msyslog(LOG_ERR, "Unknown script token %d", + my_attr_val->attr); + } + } + + return my_info; +} +#endif /* SIM */ + + +#ifdef SIM +static sockaddr_u * +get_next_address( + address_node *addr + ) +{ + const char addr_prefix[] = "192.168.0."; + static int curr_addr_num = 1; +#define ADDR_LENGTH 16 + 1 /* room for 192.168.1.255 */ + char addr_string[ADDR_LENGTH]; + sockaddr_u *final_addr; + struct addrinfo *ptr; + int gai_err; + + final_addr = emalloc(sizeof(*final_addr)); + + if (addr->type == T_String) { + snprintf(addr_string, sizeof(addr_string), "%s%d", + addr_prefix, curr_addr_num++); + printf("Selecting ip address %s for hostname %s\n", + addr_string, addr->address); + gai_err = getaddrinfo(addr_string, "ntp", NULL, &ptr); + } else { + gai_err = getaddrinfo(addr->address, "ntp", NULL, &ptr); + } + + if (gai_err) { + fprintf(stderr, "ERROR!! Could not get a new address\n"); + exit(1); + } + memcpy(final_addr, ptr->ai_addr, ptr->ai_addrlen); + fprintf(stderr, "Successful in setting ip address of simulated server to: %s\n", + stoa(final_addr)); + freeaddrinfo(ptr); + + return final_addr; +} +#endif /* SIM */ + + +#ifdef SIM +server_info * +create_sim_server( + address_node * addr, + double server_offset, + script_info_fifo * script + ) +{ + server_info *my_info; + + my_info = emalloc_zero(sizeof(*my_info)); + my_info->server_time = server_offset; + my_info->addr = get_next_address(addr); + my_info->script = script; + UNLINK_FIFO(my_info->curr_script, *my_info->script, link); + + return my_info; +} +#endif /* SIM */ + +sim_node * +create_sim_node( + attr_val_fifo * init_opts, + server_info_fifo * servers + ) +{ + sim_node *my_node; + + my_node = emalloc(sizeof(*my_node)); + my_node->init_opts = init_opts; + my_node->servers = servers; + + return my_node; +} + + + + +/* FUNCTIONS FOR PERFORMING THE CONFIGURATION + * ------------------------------------------ + */ + +#ifndef SIM +static void +config_other_modes( + config_tree * ptree + ) +{ + sockaddr_u addr_sock; + address_node * addr_node; + + if (ptree->broadcastclient) + proto_config(PROTO_BROADCLIENT, ptree->broadcastclient, + 0., NULL); + + addr_node = HEAD_PFIFO(ptree->manycastserver); + while (addr_node != NULL) { + ZERO_SOCK(&addr_sock); + AF(&addr_sock) = addr_node->type; + if (1 == getnetnum(addr_node->address, &addr_sock, 1, + t_UNK)) { + proto_config(PROTO_MULTICAST_ADD, + 0, 0., &addr_sock); + sys_manycastserver = 1; + } + addr_node = addr_node->link; + } + + /* Configure the multicast clients */ + addr_node = HEAD_PFIFO(ptree->multicastclient); + if (addr_node != NULL) { + do { + ZERO_SOCK(&addr_sock); + AF(&addr_sock) = addr_node->type; + if (1 == getnetnum(addr_node->address, + &addr_sock, 1, t_UNK)) { + proto_config(PROTO_MULTICAST_ADD, 0, 0., + &addr_sock); + } + addr_node = addr_node->link; + } while (addr_node != NULL); + proto_config(PROTO_MULTICAST_ADD, 1, 0., NULL); + } +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +destroy_address_fifo( + address_fifo * pfifo + ) +{ + address_node * addr_node; + + if (pfifo != NULL) { + for (;;) { + UNLINK_FIFO(addr_node, *pfifo, link); + if (addr_node == NULL) + break; + destroy_address_node(addr_node); + } + free(pfifo); + } +} + + +static void +free_config_other_modes( + config_tree *ptree + ) +{ + FREE_ADDRESS_FIFO(ptree->manycastserver); + FREE_ADDRESS_FIFO(ptree->multicastclient); +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_auth( + config_tree *ptree + ) +{ + attr_val * my_val; + int first; + int last; + int i; + int count; +#ifdef AUTOKEY + int item; +#endif + + /* Crypto Command */ +#ifdef AUTOKEY +# ifdef __GNUC__ + item = -1; /* quiet warning */ +# endif + my_val = HEAD_PFIFO(ptree->auth.crypto_cmd_list); + for (; my_val != NULL; my_val = my_val->link) { + switch (my_val->attr) { + + default: + INSIST(0); + break; + + case T_Host: + item = CRYPTO_CONF_PRIV; + break; + + case T_Ident: + item = CRYPTO_CONF_IDENT; + break; + + case T_Pw: + item = CRYPTO_CONF_PW; + break; + + case T_Randfile: + item = CRYPTO_CONF_RAND; + break; + + case T_Digest: + item = CRYPTO_CONF_NID; + break; + } + crypto_config(item, my_val->value.s); + } +#endif /* AUTOKEY */ + + /* Keysdir Command */ + if (ptree->auth.keysdir) { + if (keysdir != default_keysdir) + free(keysdir); + keysdir = estrdup(ptree->auth.keysdir); + } + + + /* ntp_signd_socket Command */ + if (ptree->auth.ntp_signd_socket) { + if (ntp_signd_socket != default_ntp_signd_socket) + free(ntp_signd_socket); + ntp_signd_socket = estrdup(ptree->auth.ntp_signd_socket); + } + +#ifdef AUTOKEY + if (ptree->auth.cryptosw && !cryptosw) { + crypto_setup(); + cryptosw = 1; + } +#endif /* AUTOKEY */ + + /* + * Count the number of trusted keys to preallocate storage and + * size the hash table. + */ + count = 0; + my_val = HEAD_PFIFO(ptree->auth.trusted_key_list); + for (; my_val != NULL; my_val = my_val->link) { + if (T_Integer == my_val->type) { + first = my_val->value.i; + if (first > 1 && first <= NTP_MAXKEY) + count++; + } else { + REQUIRE(T_Intrange == my_val->type); + first = my_val->value.r.first; + last = my_val->value.r.last; + if (!(first > last || first < 1 || + last > NTP_MAXKEY)) { + count += 1 + last - first; + } + } + } + auth_prealloc_symkeys(count); + + /* Keys Command */ + if (ptree->auth.keys) + getauthkeys(ptree->auth.keys); + + /* Control Key Command */ + if (ptree->auth.control_key) + ctl_auth_keyid = (keyid_t)ptree->auth.control_key; + + /* Requested Key Command */ + if (ptree->auth.request_key) { + DPRINTF(4, ("set info_auth_keyid to %08lx\n", + (u_long) ptree->auth.request_key)); + info_auth_keyid = (keyid_t)ptree->auth.request_key; + } + + /* Trusted Key Command */ + my_val = HEAD_PFIFO(ptree->auth.trusted_key_list); + for (; my_val != NULL; my_val = my_val->link) { + if (T_Integer == my_val->type) { + first = my_val->value.i; + if (first >= 1 && first <= NTP_MAXKEY) { + authtrust(first, TRUE); + } else { + msyslog(LOG_NOTICE, + "Ignoring invalid trustedkey %d, min 1 max %d.", + first, NTP_MAXKEY); + } + } else { + first = my_val->value.r.first; + last = my_val->value.r.last; + if (first > last || first < 1 || + last > NTP_MAXKEY) { + msyslog(LOG_NOTICE, + "Ignoring invalid trustedkey range %d ... %d, min 1 max %d.", + first, last, NTP_MAXKEY); + } else { + for (i = first; i <= last; i++) { + authtrust(i, TRUE); + } + } + } + } + +#ifdef AUTOKEY + /* crypto revoke command */ + if (ptree->auth.revoke) + sys_revoke = 1UL << ptree->auth.revoke; +#endif /* AUTOKEY */ +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_auth( + config_tree *ptree + ) +{ + destroy_attr_val_fifo(ptree->auth.crypto_cmd_list); + ptree->auth.crypto_cmd_list = NULL; + destroy_attr_val_fifo(ptree->auth.trusted_key_list); + ptree->auth.trusted_key_list = NULL; +} +#endif /* FREE_CFG_T */ + + +static void +config_tos( + config_tree *ptree + ) +{ + attr_val * tos; + int item; + double val; + +#ifdef __GNUC__ + item = -1; /* quiet warning */ +#endif + tos = HEAD_PFIFO(ptree->orphan_cmds); + for (; tos != NULL; tos = tos->link) { + val = tos->value.d; + switch(tos->attr) { + + default: + INSIST(0); + break; + + case T_Ceiling: + if (val > STRATUM_UNSPEC - 1) { + msyslog(LOG_WARNING, + "Using maximum tos ceiling %d, %g requested", + STRATUM_UNSPEC - 1, val); + val = STRATUM_UNSPEC - 1; + } + item = PROTO_CEILING; + break; + + case T_Floor: + item = PROTO_FLOOR; + break; + + case T_Cohort: + item = PROTO_COHORT; + break; + + case T_Orphan: + item = PROTO_ORPHAN; + break; + + case T_Orphanwait: + item = PROTO_ORPHWAIT; + break; + + case T_Mindist: + item = PROTO_MINDISP; + break; + + case T_Maxdist: + item = PROTO_MAXDIST; + break; + + case T_Minclock: + item = PROTO_MINCLOCK; + break; + + case T_Maxclock: + item = PROTO_MAXCLOCK; + break; + + case T_Minsane: + item = PROTO_MINSANE; + break; + + case T_Beacon: + item = PROTO_BEACON; + break; + } + proto_config(item, 0, val, NULL); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_tos( + config_tree *ptree + ) +{ + FREE_ATTR_VAL_FIFO(ptree->orphan_cmds); +} +#endif /* FREE_CFG_T */ + + +static void +config_monitor( + config_tree *ptree + ) +{ + int_node *pfilegen_token; + const char *filegen_string; + const char *filegen_file; + FILEGEN *filegen; + filegen_node *my_node; + attr_val *my_opts; + int filegen_type; + int filegen_flag; + + /* Set the statistics directory */ + if (ptree->stats_dir) + stats_config(STATS_STATSDIR, ptree->stats_dir); + + /* NOTE: + * Calling filegen_get is brain dead. Doing a string + * comparison to find the relavant filegen structure is + * expensive. + * + * Through the parser, we already know which filegen is + * being specified. Hence, we should either store a + * pointer to the specified structure in the syntax tree + * or an index into a filegen array. + * + * Need to change the filegen code to reflect the above. + */ + + /* Turn on the specified statistics */ + pfilegen_token = HEAD_PFIFO(ptree->stats_list); + for (; pfilegen_token != NULL; pfilegen_token = pfilegen_token->link) { + filegen_string = keyword(pfilegen_token->i); + filegen = filegen_get(filegen_string); + if (NULL == filegen) { + msyslog(LOG_ERR, + "stats %s unrecognized", + filegen_string); + continue; + } + DPRINTF(4, ("enabling filegen for %s statistics '%s%s'\n", + filegen_string, filegen->dir, + filegen->fname)); + filegen_flag = filegen->flag; + filegen_flag |= FGEN_FLAG_ENABLED; + filegen_config(filegen, statsdir, filegen_string, + filegen->type, filegen_flag); + } + + /* Configure the statistics with the options */ + my_node = HEAD_PFIFO(ptree->filegen_opts); + for (; my_node != NULL; my_node = my_node->link) { + filegen_string = keyword(my_node->filegen_token); + filegen = filegen_get(filegen_string); + if (NULL == filegen) { + msyslog(LOG_ERR, + "filegen category '%s' unrecognized", + filegen_string); + continue; + } + filegen_file = filegen_string; + + /* Initialize the filegen variables to their pre-configuration states */ + filegen_flag = filegen->flag; + filegen_type = filegen->type; + + /* "filegen ... enabled" is the default (when filegen is used) */ + filegen_flag |= FGEN_FLAG_ENABLED; + + my_opts = HEAD_PFIFO(my_node->options); + for (; my_opts != NULL; my_opts = my_opts->link) { + switch (my_opts->attr) { + + case T_File: + filegen_file = my_opts->value.s; + break; + + case T_Type: + switch (my_opts->value.i) { + + default: + INSIST(0); + break; + + case T_None: + filegen_type = FILEGEN_NONE; + break; + + case T_Pid: + filegen_type = FILEGEN_PID; + break; + + case T_Day: + filegen_type = FILEGEN_DAY; + break; + + case T_Week: + filegen_type = FILEGEN_WEEK; + break; + + case T_Month: + filegen_type = FILEGEN_MONTH; + break; + + case T_Year: + filegen_type = FILEGEN_YEAR; + break; + + case T_Age: + filegen_type = FILEGEN_AGE; + break; + } + break; + + case T_Flag: + switch (my_opts->value.i) { + + case T_Link: + filegen_flag |= FGEN_FLAG_LINK; + break; + + case T_Nolink: + filegen_flag &= ~FGEN_FLAG_LINK; + break; + + case T_Enable: + filegen_flag |= FGEN_FLAG_ENABLED; + break; + + case T_Disable: + filegen_flag &= ~FGEN_FLAG_ENABLED; + break; + + default: + msyslog(LOG_ERR, + "Unknown filegen flag token %d", + my_opts->value.i); + exit(1); + } + break; + + default: + msyslog(LOG_ERR, + "Unknown filegen option token %d", + my_opts->attr); + exit(1); + } + } + filegen_config(filegen, statsdir, filegen_file, + filegen_type, filegen_flag); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_monitor( + config_tree *ptree + ) +{ + if (ptree->stats_dir) { + free(ptree->stats_dir); + ptree->stats_dir = NULL; + } + + FREE_INT_FIFO(ptree->stats_list); + FREE_FILEGEN_FIFO(ptree->filegen_opts); +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_access( + config_tree *ptree + ) +{ + static int warned_signd; + attr_val * my_opt; + restrict_node * my_node; + int_node * curr_flag; + sockaddr_u addr; + sockaddr_u mask; + struct addrinfo hints; + struct addrinfo * ai_list; + struct addrinfo * pai; + int rc; + int restrict_default; + u_short flags; + u_short mflags; + int range_err; + const char * signd_warning = +#ifdef HAVE_NTP_SIGND + "MS-SNTP signd operations currently block ntpd degrading service to all clients."; +#else + "mssntp restrict bit ignored, this ntpd was configured without --enable-ntp-signd."; +#endif + + /* Configure the mru options */ + my_opt = HEAD_PFIFO(ptree->mru_opts); + for (; my_opt != NULL; my_opt = my_opt->link) { + + range_err = FALSE; + + switch (my_opt->attr) { + + case T_Incalloc: + if (0 <= my_opt->value.i) + mru_incalloc = my_opt->value.u; + else + range_err = TRUE; + break; + + case T_Incmem: + if (0 <= my_opt->value.i) + mru_incalloc = (my_opt->value.u * 1024U) + / sizeof(mon_entry); + else + range_err = TRUE; + break; + + case T_Initalloc: + if (0 <= my_opt->value.i) + mru_initalloc = my_opt->value.u; + else + range_err = TRUE; + break; + + case T_Initmem: + if (0 <= my_opt->value.i) + mru_initalloc = (my_opt->value.u * 1024U) + / sizeof(mon_entry); + else + range_err = TRUE; + break; + + case T_Mindepth: + if (0 <= my_opt->value.i) + mru_mindepth = my_opt->value.u; + else + range_err = TRUE; + break; + + case T_Maxage: + mru_maxage = my_opt->value.i; + break; + + case T_Maxdepth: + if (0 <= my_opt->value.i) + mru_maxdepth = my_opt->value.u; + else + mru_maxdepth = UINT_MAX; + break; + + case T_Maxmem: + if (0 <= my_opt->value.i) + mru_maxdepth = (my_opt->value.u * 1024U) / + sizeof(mon_entry); + else + mru_maxdepth = UINT_MAX; + break; + + default: + msyslog(LOG_ERR, + "Unknown mru option %s (%d)", + keyword(my_opt->attr), my_opt->attr); + exit(1); + } + if (range_err) + msyslog(LOG_ERR, + "mru %s %d out of range, ignored.", + keyword(my_opt->attr), my_opt->value.i); + } + + /* Configure the discard options */ + my_opt = HEAD_PFIFO(ptree->discard_opts); + for (; my_opt != NULL; my_opt = my_opt->link) { + + switch (my_opt->attr) { + + case T_Average: + if (0 <= my_opt->value.i && + my_opt->value.i <= UCHAR_MAX) + ntp_minpoll = (u_char)my_opt->value.u; + else + msyslog(LOG_ERR, + "discard average %d out of range, ignored.", + my_opt->value.i); + break; + + case T_Minimum: + ntp_minpkt = my_opt->value.i; + break; + + case T_Monitor: + mon_age = my_opt->value.i; + break; + + default: + msyslog(LOG_ERR, + "Unknown discard option %s (%d)", + keyword(my_opt->attr), my_opt->attr); + exit(1); + } + } + + /* Configure the restrict options */ + my_node = HEAD_PFIFO(ptree->restrict_opts); + for (; my_node != NULL; my_node = my_node->link) { + /* Parse the flags */ + flags = 0; + mflags = 0; + + curr_flag = HEAD_PFIFO(my_node->flags); + for (; curr_flag != NULL; curr_flag = curr_flag->link) { + switch (curr_flag->i) { + + default: + INSIST(0); + break; + + case T_Ntpport: + mflags |= RESM_NTPONLY; + break; + + case T_Source: + mflags |= RESM_SOURCE; + break; + + case T_Flake: + flags |= RES_FLAKE; + break; + + case T_Ignore: + flags |= RES_IGNORE; + break; + + case T_Kod: + flags |= RES_KOD; + break; + + case T_Mssntp: + flags |= RES_MSSNTP; + break; + + case T_Limited: + flags |= RES_LIMITED; + break; + + case T_Lowpriotrap: + flags |= RES_LPTRAP; + break; + + case T_Nomodify: + flags |= RES_NOMODIFY; + break; + + case T_Nomrulist: + flags |= RES_NOMRULIST; + break; + + case T_Nopeer: + flags |= RES_NOPEER; + break; + + case T_Noquery: + flags |= RES_NOQUERY; + break; + + case T_Noserve: + flags |= RES_DONTSERVE; + break; + + case T_Notrap: + flags |= RES_NOTRAP; + break; + + case T_Notrust: + flags |= RES_DONTTRUST; + break; + + case T_Version: + flags |= RES_VERSION; + break; + } + } + + if ((RES_MSSNTP & flags) && !warned_signd) { + warned_signd = 1; + fprintf(stderr, "%s\n", signd_warning); + msyslog(LOG_WARNING, "%s", signd_warning); + } + + /* It would be swell if we could identify the line number */ + if ((RES_KOD & flags) && !(RES_LIMITED & flags)) { + const char *kod_where = (my_node->addr) + ? my_node->addr->address + : (mflags & RESM_SOURCE) + ? "source" + : "default"; + const char *kod_warn = "KOD does nothing without LIMITED."; + + fprintf(stderr, "restrict %s: %s\n", kod_where, kod_warn); + msyslog(LOG_WARNING, "restrict %s: %s", kod_where, kod_warn); + } + + ZERO_SOCK(&addr); + ai_list = NULL; + pai = NULL; + restrict_default = 0; + + if (NULL == my_node->addr) { + ZERO_SOCK(&mask); + if (!(RESM_SOURCE & mflags)) { + /* + * The user specified a default rule + * without a -4 / -6 qualifier, add to + * both lists + */ + restrict_default = 1; + } else { + /* apply "restrict source ..." */ + DPRINTF(1, ("restrict source template mflags %x flags %x\n", + mflags, flags)); + hack_restrict(RESTRICT_FLAGS, NULL, + NULL, mflags, flags, 0); + continue; + } + } else { + /* Resolve the specified address */ + AF(&addr) = (u_short)my_node->addr->type; + + if (getnetnum(my_node->addr->address, + &addr, 1, t_UNK) != 1) { + /* + * Attempt a blocking lookup. This + * is in violation of the nonblocking + * design of ntpd's mainline code. The + * alternative of running without the + * restriction until the name resolved + * seems worse. + * Ideally some scheme could be used for + * restrict directives in the startup + * ntp.conf to delay starting up the + * protocol machinery until after all + * restrict hosts have been resolved. + */ + ai_list = NULL; + ZERO(hints); + hints.ai_protocol = IPPROTO_UDP; + hints.ai_socktype = SOCK_DGRAM; + hints.ai_family = my_node->addr->type; + rc = getaddrinfo(my_node->addr->address, + "ntp", &hints, + &ai_list); + if (rc) { + msyslog(LOG_ERR, + "restrict: ignoring line %d, address/host '%s' unusable.", + my_node->line_no, + my_node->addr->address); + continue; + } + INSIST(ai_list != NULL); + pai = ai_list; + INSIST(pai->ai_addr != NULL); + INSIST(sizeof(addr) >= + pai->ai_addrlen); + memcpy(&addr, pai->ai_addr, + pai->ai_addrlen); + INSIST(AF_INET == AF(&addr) || + AF_INET6 == AF(&addr)); + } + + SET_HOSTMASK(&mask, AF(&addr)); + + /* Resolve the mask */ + if (my_node->mask) { + ZERO_SOCK(&mask); + AF(&mask) = my_node->mask->type; + if (getnetnum(my_node->mask->address, + &mask, 1, t_MSK) != 1) { + msyslog(LOG_ERR, + "restrict: ignoring line %d, mask '%s' unusable.", + my_node->line_no, + my_node->mask->address); + continue; + } + } + } + + /* Set the flags */ + if (restrict_default) { + AF(&addr) = AF_INET; + AF(&mask) = AF_INET; + hack_restrict(RESTRICT_FLAGS, &addr, + &mask, mflags, flags, 0); + AF(&addr) = AF_INET6; + AF(&mask) = AF_INET6; + } + + do { + hack_restrict(RESTRICT_FLAGS, &addr, + &mask, mflags, flags, 0); + if (pai != NULL && + NULL != (pai = pai->ai_next)) { + INSIST(pai->ai_addr != NULL); + INSIST(sizeof(addr) >= + pai->ai_addrlen); + ZERO_SOCK(&addr); + memcpy(&addr, pai->ai_addr, + pai->ai_addrlen); + INSIST(AF_INET == AF(&addr) || + AF_INET6 == AF(&addr)); + SET_HOSTMASK(&mask, AF(&addr)); + } + } while (pai != NULL); + + if (ai_list != NULL) + freeaddrinfo(ai_list); + } +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_access( + config_tree *ptree + ) +{ + FREE_ATTR_VAL_FIFO(ptree->mru_opts); + FREE_ATTR_VAL_FIFO(ptree->discard_opts); + FREE_RESTRICT_FIFO(ptree->restrict_opts); +} +#endif /* FREE_CFG_T */ + + +static void +config_rlimit( + config_tree *ptree + ) +{ + attr_val * rlimit_av; + + rlimit_av = HEAD_PFIFO(ptree->rlimit); + for (; rlimit_av != NULL; rlimit_av = rlimit_av->link) { + switch (rlimit_av->attr) { + + default: + INSIST(0); + break; + + case T_Memlock: + /* What if we HAVE_OPT(SAVECONFIGQUIT) ? */ + if (rlimit_av->value.i == -1) { +# if defined(HAVE_MLOCKALL) + if (cur_memlock != 0) { + if (-1 == munlockall()) { + msyslog(LOG_ERR, "munlockall() failed: %m"); + } + } + cur_memlock = 0; +# endif /* HAVE_MLOCKALL */ + } else if (rlimit_av->value.i >= 0) { +#if defined(RLIMIT_MEMLOCK) +# if defined(HAVE_MLOCKALL) + if (cur_memlock != 1) { + if (-1 == mlockall(MCL_CURRENT|MCL_FUTURE)) { + msyslog(LOG_ERR, "mlockall() failed: %m"); + } + } +# endif /* HAVE_MLOCKALL */ + ntp_rlimit(RLIMIT_MEMLOCK, + (rlim_t)(rlimit_av->value.i * 1024 * 1024), + 1024 * 1024, + "MB"); + cur_memlock = 1; +#else + /* STDERR as well would be fine... */ + msyslog(LOG_WARNING, "'rlimit memlock' specified but is not available on this system."); +#endif /* RLIMIT_MEMLOCK */ + } else { + msyslog(LOG_WARNING, "'rlimit memlock' value of %d is unexpected!", rlimit_av->value.i); + } + break; + + case T_Stacksize: +#if defined(RLIMIT_STACK) + ntp_rlimit(RLIMIT_STACK, + (rlim_t)(rlimit_av->value.i * 4096), + 4096, + "4k"); +#else + /* STDERR as well would be fine... */ + msyslog(LOG_WARNING, "'rlimit stacksize' specified but is not available on this system."); +#endif /* RLIMIT_STACK */ + break; + + case T_Filenum: +#if defined(RLIMIT_NOFILE) + ntp_rlimit(RLIMIT_NOFILE, + (rlim_t)(rlimit_av->value.i), + 1, + ""); +#else + /* STDERR as well would be fine... */ + msyslog(LOG_WARNING, "'rlimit filenum' specified but is not available on this system."); +#endif /* RLIMIT_NOFILE */ + break; + + } + } +} + + +static void +config_tinker( + config_tree *ptree + ) +{ + attr_val * tinker; + int item; + +#ifdef __GNUC__ + item = -1; /* quiet warning */ +#endif + tinker = HEAD_PFIFO(ptree->tinker); + for (; tinker != NULL; tinker = tinker->link) { + switch (tinker->attr) { + + default: + INSIST(0); + break; + + case T_Allan: + item = LOOP_ALLAN; + break; + + case T_Dispersion: + item = LOOP_PHI; + break; + + case T_Freq: + item = LOOP_FREQ; + break; + + case T_Huffpuff: + item = LOOP_HUFFPUFF; + break; + + case T_Panic: + item = LOOP_PANIC; + break; + + case T_Step: + item = LOOP_MAX; + break; + + case T_Stepback: + item = LOOP_MAX_BACK; + break; + + case T_Stepfwd: + item = LOOP_MAX_FWD; + break; + + case T_Stepout: + item = LOOP_MINSTEP; + break; + + case T_Tick: + item = LOOP_TICK; + break; + } + loop_config(item, tinker->value.d); + } +} + + +#ifdef FREE_CFG_T +static void +free_config_rlimit( + config_tree *ptree + ) +{ + FREE_ATTR_VAL_FIFO(ptree->rlimit); +} + +static void +free_config_tinker( + config_tree *ptree + ) +{ + FREE_ATTR_VAL_FIFO(ptree->tinker); +} +#endif /* FREE_CFG_T */ + + +/* + * config_nic_rules - apply interface listen/ignore/drop items + */ +#ifndef SIM +static void +config_nic_rules( + config_tree *ptree, + int/*BOOL*/ input_from_file + ) +{ + nic_rule_node * curr_node; + sockaddr_u addr; + nic_rule_match match_type; + nic_rule_action action; + char * if_name; + char * pchSlash; + int prefixlen; + int addrbits; + + curr_node = HEAD_PFIFO(ptree->nic_rules); + + if (curr_node != NULL + && (HAVE_OPT( NOVIRTUALIPS ) || HAVE_OPT( INTERFACE ))) { + msyslog(LOG_ERR, + "interface/nic rules are not allowed with --interface (-I) or --novirtualips (-L)%s", + (input_from_file) ? ", exiting" : ""); + if (input_from_file) + exit(1); + else + return; + } + + for (; curr_node != NULL; curr_node = curr_node->link) { + prefixlen = -1; + if_name = curr_node->if_name; + if (if_name != NULL) + if_name = estrdup(if_name); + + switch (curr_node->match_class) { + + default: +#ifdef __GNUC__ + /* + * this assignment quiets a gcc "may be used + * uninitialized" warning and is here for no + * other reason. + */ + match_type = MATCH_ALL; +#endif + INSIST(FALSE); + break; + + case 0: + /* + * 0 is out of range for valid token T_... + * and in a nic_rules_node indicates the + * interface descriptor is either a name or + * address, stored in if_name in either case. + */ + INSIST(if_name != NULL); + pchSlash = strchr(if_name, '/'); + if (pchSlash != NULL) + *pchSlash = '\0'; + if (is_ip_address(if_name, AF_UNSPEC, &addr)) { + match_type = MATCH_IFADDR; + if (pchSlash != NULL + && 1 == sscanf(pchSlash + 1, "%d", + &prefixlen)) { + addrbits = 8 * + SIZEOF_INADDR(AF(&addr)); + prefixlen = max(-1, prefixlen); + prefixlen = min(prefixlen, + addrbits); + } + } else { + match_type = MATCH_IFNAME; + if (pchSlash != NULL) + *pchSlash = '/'; + } + break; + + case T_All: + match_type = MATCH_ALL; + break; + + case T_Ipv4: + match_type = MATCH_IPV4; + break; + + case T_Ipv6: + match_type = MATCH_IPV6; + break; + + case T_Wildcard: + match_type = MATCH_WILDCARD; + break; + } + + switch (curr_node->action) { + + default: +#ifdef __GNUC__ + /* + * this assignment quiets a gcc "may be used + * uninitialized" warning and is here for no + * other reason. + */ + action = ACTION_LISTEN; +#endif + INSIST(FALSE); + break; + + case T_Listen: + action = ACTION_LISTEN; + break; + + case T_Ignore: + action = ACTION_IGNORE; + break; + + case T_Drop: + action = ACTION_DROP; + break; + } + + add_nic_rule(match_type, if_name, prefixlen, + action); + timer_interfacetimeout(current_time + 2); + if (if_name != NULL) + free(if_name); + } +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_nic_rules( + config_tree *ptree + ) +{ + nic_rule_node *curr_node; + + if (ptree->nic_rules != NULL) { + for (;;) { + UNLINK_FIFO(curr_node, *ptree->nic_rules, link); + if (NULL == curr_node) + break; + free(curr_node->if_name); + free(curr_node); + } + free(ptree->nic_rules); + ptree->nic_rules = NULL; + } +} +#endif /* FREE_CFG_T */ + + +static void +apply_enable_disable( + attr_val_fifo * fifo, + int enable + ) +{ + attr_val *curr_flag; + int option; +#ifdef BC_LIST_FRAMEWORK_NOT_YET_USED + bc_entry *pentry; +#endif + + for (curr_flag = HEAD_PFIFO(fifo); + curr_flag != NULL; + curr_flag = curr_flag->link) { + + option = curr_flag->value.i; + switch (option) { + + default: + msyslog(LOG_ERR, + "can not apply enable/disable token %d, unknown", + option); + break; + + case T_Auth: + proto_config(PROTO_AUTHENTICATE, enable, 0., NULL); + break; + + case T_Bclient: + proto_config(PROTO_BROADCLIENT, enable, 0., NULL); + break; + + case T_Calibrate: + proto_config(PROTO_CAL, enable, 0., NULL); + break; + + case T_Kernel: + proto_config(PROTO_KERNEL, enable, 0., NULL); + break; + + case T_Monitor: + proto_config(PROTO_MONITOR, enable, 0., NULL); + break; + + case T_Ntp: + proto_config(PROTO_NTP, enable, 0., NULL); + break; + + case T_Mode7: + proto_config(PROTO_MODE7, enable, 0., NULL); + break; + + case T_Stats: + proto_config(PROTO_FILEGEN, enable, 0., NULL); + break; + +#ifdef BC_LIST_FRAMEWORK_NOT_YET_USED + case T_Bc_bugXXXX: + pentry = bc_list; + while (pentry->token) { + if (pentry->token == option) + break; + pentry++; + } + if (!pentry->token) { + msyslog(LOG_ERR, + "compat token %d not in bc_list[]", + option); + continue; + } + pentry->enabled = enable; + break; +#endif + } + } +} + + +static void +config_system_opts( + config_tree *ptree + ) +{ + apply_enable_disable(ptree->enable_opts, 1); + apply_enable_disable(ptree->disable_opts, 0); +} + + +#ifdef FREE_CFG_T +static void +free_config_system_opts( + config_tree *ptree + ) +{ + FREE_ATTR_VAL_FIFO(ptree->enable_opts); + FREE_ATTR_VAL_FIFO(ptree->disable_opts); +} +#endif /* FREE_CFG_T */ + + +static void +config_logconfig( + config_tree *ptree + ) +{ + attr_val * my_lc; + + my_lc = HEAD_PFIFO(ptree->logconfig); + for (; my_lc != NULL; my_lc = my_lc->link) { + switch (my_lc->attr) { + + case '+': + ntp_syslogmask |= get_logmask(my_lc->value.s); + break; + + case '-': + ntp_syslogmask &= ~get_logmask(my_lc->value.s); + break; + + case '=': + ntp_syslogmask = get_logmask(my_lc->value.s); + break; + default: + INSIST(0); + break; + } + } +} + + +#ifdef FREE_CFG_T +static void +free_config_logconfig( + config_tree *ptree + ) +{ + FREE_ATTR_VAL_FIFO(ptree->logconfig); +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_phone( + config_tree *ptree + ) +{ + size_t i; + string_node * sn; + + i = 0; + sn = HEAD_PFIFO(ptree->phone); + for (; sn != NULL; sn = sn->link) { + /* need to leave array entry for NULL terminator */ + if (i < COUNTOF(sys_phone) - 1) { + sys_phone[i++] = estrdup(sn->s); + sys_phone[i] = NULL; + } else { + msyslog(LOG_INFO, + "phone: Number of phone entries exceeds %zu. Ignoring phone %s...", + (COUNTOF(sys_phone) - 1), sn->s); + } + } +} +#endif /* !SIM */ + +static void +config_mdnstries( + config_tree *ptree + ) +{ +#ifdef HAVE_DNSREGISTRATION + extern int mdnstries; + mdnstries = ptree->mdnstries; +#endif /* HAVE_DNSREGISTRATION */ +} + +#ifdef FREE_CFG_T +static void +free_config_phone( + config_tree *ptree + ) +{ + FREE_STRING_FIFO(ptree->phone); +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_setvar( + config_tree *ptree + ) +{ + setvar_node *my_node; + size_t varlen, vallen, octets; + char * str; + + str = NULL; + my_node = HEAD_PFIFO(ptree->setvar); + for (; my_node != NULL; my_node = my_node->link) { + varlen = strlen(my_node->var); + vallen = strlen(my_node->val); + octets = varlen + vallen + 1 + 1; + str = erealloc(str, octets); + snprintf(str, octets, "%s=%s", my_node->var, + my_node->val); + set_sys_var(str, octets, (my_node->isdefault) + ? DEF + : 0); + } + if (str != NULL) + free(str); +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_setvar( + config_tree *ptree + ) +{ + FREE_SETVAR_FIFO(ptree->setvar); +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_ttl( + config_tree *ptree + ) +{ + size_t i = 0; + int_node *curr_ttl; + + curr_ttl = HEAD_PFIFO(ptree->ttl); + for (; curr_ttl != NULL; curr_ttl = curr_ttl->link) { + if (i < COUNTOF(sys_ttl)) + sys_ttl[i++] = (u_char)curr_ttl->i; + else + msyslog(LOG_INFO, + "ttl: Number of TTL entries exceeds %zu. Ignoring TTL %d...", + COUNTOF(sys_ttl), curr_ttl->i); + } + sys_ttlmax = i - 1; +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_ttl( + config_tree *ptree + ) +{ + FREE_INT_FIFO(ptree->ttl); +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_trap( + config_tree *ptree + ) +{ + addr_opts_node *curr_trap; + attr_val *curr_opt; + sockaddr_u addr_sock; + sockaddr_u peeraddr; + struct interface *localaddr; + struct addrinfo hints; + char port_text[8]; + settrap_parms *pstp; + u_short port; + int err_flag; + int rc; + + /* silence warning about addr_sock potentially uninitialized */ + AF(&addr_sock) = AF_UNSPEC; + + curr_trap = HEAD_PFIFO(ptree->trap); + for (; curr_trap != NULL; curr_trap = curr_trap->link) { + err_flag = 0; + port = 0; + localaddr = NULL; + + curr_opt = HEAD_PFIFO(curr_trap->options); + for (; curr_opt != NULL; curr_opt = curr_opt->link) { + if (T_Port == curr_opt->attr) { + if (curr_opt->value.i < 1 + || curr_opt->value.i > USHRT_MAX) { + msyslog(LOG_ERR, + "invalid port number " + "%d, trap ignored", + curr_opt->value.i); + err_flag = 1; + } + port = (u_short)curr_opt->value.i; + } + else if (T_Interface == curr_opt->attr) { + /* Resolve the interface address */ + ZERO_SOCK(&addr_sock); + if (getnetnum(curr_opt->value.s, + &addr_sock, 1, t_UNK) != 1) { + err_flag = 1; + break; + } + + localaddr = findinterface(&addr_sock); + + if (NULL == localaddr) { + msyslog(LOG_ERR, + "can't find interface with address %s", + stoa(&addr_sock)); + err_flag = 1; + } + } + } + + /* Now process the trap for the specified interface + * and port number + */ + if (!err_flag) { + if (!port) + port = TRAPPORT; + ZERO_SOCK(&peeraddr); + rc = getnetnum(curr_trap->addr->address, + &peeraddr, 1, t_UNK); + if (1 != rc) { +#ifndef WORKER + msyslog(LOG_ERR, + "trap: unable to use IP address %s.", + curr_trap->addr->address); +#else /* WORKER follows */ + /* + * save context and hand it off + * for name resolution. + */ + ZERO(hints); + hints.ai_protocol = IPPROTO_UDP; + hints.ai_socktype = SOCK_DGRAM; + snprintf(port_text, sizeof(port_text), + "%u", port); + hints.ai_flags = Z_AI_NUMERICSERV; + pstp = emalloc_zero(sizeof(*pstp)); + if (localaddr != NULL) { + hints.ai_family = localaddr->family; + pstp->ifaddr_nonnull = 1; + memcpy(&pstp->ifaddr, + &localaddr->sin, + sizeof(pstp->ifaddr)); + } + rc = getaddrinfo_sometime( + curr_trap->addr->address, + port_text, &hints, + INITIAL_DNS_RETRY, + &trap_name_resolved, + pstp); + if (!rc) + msyslog(LOG_ERR, + "config_trap: getaddrinfo_sometime(%s,%s): %m", + curr_trap->addr->address, + port_text); +#endif /* WORKER */ + continue; + } + /* port is at same location for v4 and v6 */ + SET_PORT(&peeraddr, port); + + if (NULL == localaddr) + localaddr = ANY_INTERFACE_CHOOSE(&peeraddr); + else + AF(&peeraddr) = AF(&addr_sock); + + if (!ctlsettrap(&peeraddr, localaddr, 0, + NTP_VERSION)) + msyslog(LOG_ERR, + "set trap %s -> %s failed.", + latoa(localaddr), + stoa(&peeraddr)); + } + } +} + + +/* + * trap_name_resolved() + * + * Callback invoked when config_trap()'s DNS lookup completes. + */ +# ifdef WORKER +static void +trap_name_resolved( + int rescode, + int gai_errno, + void * context, + const char * name, + const char * service, + const struct addrinfo * hints, + const struct addrinfo * res + ) +{ + settrap_parms *pstp; + struct interface *localaddr; + sockaddr_u peeraddr; + + (void)gai_errno; + (void)service; + (void)hints; + pstp = context; + if (rescode) { + msyslog(LOG_ERR, + "giving up resolving trap host %s: %s (%d)", + name, gai_strerror(rescode), rescode); + free(pstp); + return; + } + INSIST(sizeof(peeraddr) >= res->ai_addrlen); + ZERO(peeraddr); + memcpy(&peeraddr, res->ai_addr, res->ai_addrlen); + localaddr = NULL; + if (pstp->ifaddr_nonnull) + localaddr = findinterface(&pstp->ifaddr); + if (NULL == localaddr) + localaddr = ANY_INTERFACE_CHOOSE(&peeraddr); + if (!ctlsettrap(&peeraddr, localaddr, 0, NTP_VERSION)) + msyslog(LOG_ERR, "set trap %s -> %s failed.", + latoa(localaddr), stoa(&peeraddr)); + free(pstp); +} +# endif /* WORKER */ +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_trap( + config_tree *ptree + ) +{ + FREE_ADDR_OPTS_FIFO(ptree->trap); +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_fudge( + config_tree *ptree + ) +{ + addr_opts_node *curr_fudge; + attr_val *curr_opt; + sockaddr_u addr_sock; + address_node *addr_node; + struct refclockstat clock_stat; + int err_flag; + + curr_fudge = HEAD_PFIFO(ptree->fudge); + for (; curr_fudge != NULL; curr_fudge = curr_fudge->link) { + err_flag = 0; + + /* Get the reference clock address and + * ensure that it is sane + */ + addr_node = curr_fudge->addr; + ZERO_SOCK(&addr_sock); + if (getnetnum(addr_node->address, &addr_sock, 1, t_REF) + != 1) { + err_flag = 1; + msyslog(LOG_ERR, + "unrecognized fudge reference clock address %s, line ignored", + stoa(&addr_sock)); + } + + if (!ISREFCLOCKADR(&addr_sock)) { + err_flag = 1; + msyslog(LOG_ERR, + "inappropriate address %s for the fudge command, line ignored", + stoa(&addr_sock)); + } + + /* Parse all the options to the fudge command */ + ZERO(clock_stat); + curr_opt = HEAD_PFIFO(curr_fudge->options); + for (; curr_opt != NULL; curr_opt = curr_opt->link) { + switch (curr_opt->attr) { + + case T_Time1: + clock_stat.haveflags |= CLK_HAVETIME1; + clock_stat.fudgetime1 = curr_opt->value.d; + break; + + case T_Time2: + clock_stat.haveflags |= CLK_HAVETIME2; + clock_stat.fudgetime2 = curr_opt->value.d; + break; + + case T_Stratum: + clock_stat.haveflags |= CLK_HAVEVAL1; + clock_stat.fudgeval1 = curr_opt->value.i; + break; + + case T_Refid: + clock_stat.haveflags |= CLK_HAVEVAL2; + clock_stat.fudgeval2 = 0; + memcpy(&clock_stat.fudgeval2, + curr_opt->value.s, + min(strlen(curr_opt->value.s), 4)); + break; + + case T_Flag1: + clock_stat.haveflags |= CLK_HAVEFLAG1; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG1; + else + clock_stat.flags &= ~CLK_FLAG1; + break; + + case T_Flag2: + clock_stat.haveflags |= CLK_HAVEFLAG2; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG2; + else + clock_stat.flags &= ~CLK_FLAG2; + break; + + case T_Flag3: + clock_stat.haveflags |= CLK_HAVEFLAG3; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG3; else - ((struct sockaddr_in6*)&peeraddr)->sin6_port = htons(TRAPPORT); - if (localaddr == NULL) - localaddr = ANY_INTERFACE_CHOOSE(&peeraddr); - if (!ctlsettrap(&peeraddr, localaddr, 0, - NTP_VERSION)) - msyslog(LOG_ERR, - "can't set trap for %s, no resources", - stoa(&peeraddr)); + clock_stat.flags &= ~CLK_FLAG3; + break; + + case T_Flag4: + clock_stat.haveflags |= CLK_HAVEFLAG4; + if (curr_opt->value.i) + clock_stat.flags |= CLK_FLAG4; + else + clock_stat.flags &= ~CLK_FLAG4; + break; + + default: + msyslog(LOG_ERR, + "Unexpected fudge flag %s (%d) for %s", + token_name(curr_opt->attr), + curr_opt->attr, stoa(&addr_sock)); + exit(curr_opt->attr ? curr_opt->attr : 1); + } + } +# ifdef REFCLOCK + if (!err_flag) + refclock_control(&addr_sock, &clock_stat, NULL); +# endif + } +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_fudge( + config_tree *ptree + ) +{ + FREE_ADDR_OPTS_FIFO(ptree->fudge); +} +#endif /* FREE_CFG_T */ + + +static void +config_vars( + config_tree *ptree + ) +{ + attr_val *curr_var; + int len; + + curr_var = HEAD_PFIFO(ptree->vars); + for (; curr_var != NULL; curr_var = curr_var->link) { + /* Determine which variable to set and set it */ + switch (curr_var->attr) { + + case T_Broadcastdelay: + proto_config(PROTO_BROADDELAY, 0, curr_var->value.d, NULL); + break; + + case T_Tick: + loop_config(LOOP_TICK, curr_var->value.d); + break; + + case T_Driftfile: + if ('\0' == curr_var->value.s[0]) { + stats_drift_file = 0; + msyslog(LOG_INFO, "config: driftfile disabled"); + } else + stats_config(STATS_FREQ_FILE, curr_var->value.s); + break; + + case T_Dscp: + /* DSCP is in the upper 6 bits of the IP TOS/DS field */ + qos = curr_var->value.i << 2; + break; + + case T_Ident: + sys_ident = curr_var->value.s; + break; + + case T_WanderThreshold: /* FALLTHROUGH */ + case T_Nonvolatile: + wander_threshold = curr_var->value.d; + break; + + case T_Leapfile: + stats_config(STATS_LEAP_FILE, curr_var->value.s); + break; + +#ifdef LEAP_SMEAR + case T_Leapsmearinterval: + leap_smear_intv = curr_var->value.i; + msyslog(LOG_INFO, "config: leap smear interval %i s", leap_smear_intv); + break; +#endif + + case T_Pidfile: + stats_config(STATS_PID_FILE, curr_var->value.s); + break; + + case T_Logfile: + if (-1 == change_logfile(curr_var->value.s, TRUE)) + msyslog(LOG_ERR, + "Cannot open logfile %s: %m", + curr_var->value.s); + break; + + case T_Saveconfigdir: + if (saveconfigdir != NULL) + free(saveconfigdir); + len = strlen(curr_var->value.s); + if (0 == len) { + saveconfigdir = NULL; + } else if (DIR_SEP != curr_var->value.s[len - 1] +#ifdef SYS_WINNT /* slash is also a dir. sep. on Windows */ + && '/' != curr_var->value.s[len - 1] +#endif + ) { + len++; + saveconfigdir = emalloc(len + 1); + snprintf(saveconfigdir, len + 1, + "%s%c", + curr_var->value.s, + DIR_SEP); + } else { + saveconfigdir = estrdup( + curr_var->value.s); + } + break; + + case T_Automax: +#ifdef AUTOKEY + sys_automax = curr_var->value.i; +#endif + break; + + default: + msyslog(LOG_ERR, + "config_vars(): unexpected token %d", + curr_var->attr); + } + } +} + + +#ifdef FREE_CFG_T +static void +free_config_vars( + config_tree *ptree + ) +{ + FREE_ATTR_VAL_FIFO(ptree->vars); +} +#endif /* FREE_CFG_T */ + + +/* Define a function to check if a resolved address is sane. + * If yes, return 1, else return 0; + */ +static int +is_sane_resolved_address( + sockaddr_u * peeraddr, + int hmode + ) +{ + if (!ISREFCLOCKADR(peeraddr) && ISBADADR(peeraddr)) { + msyslog(LOG_ERR, + "attempt to configure invalid address %s", + stoa(peeraddr)); + return 0; + } + /* + * Shouldn't be able to specify multicast + * address for server/peer! + * and unicast address for manycastclient! + */ + if ((T_Server == hmode || T_Peer == hmode || T_Pool == hmode) + && IS_MCAST(peeraddr)) { + msyslog(LOG_ERR, + "attempt to configure invalid address %s", + stoa(peeraddr)); + return 0; + } + if (T_Manycastclient == hmode && !IS_MCAST(peeraddr)) { + msyslog(LOG_ERR, + "attempt to configure invalid address %s", + stoa(peeraddr)); + return 0; + } + + if (IS_IPV6(peeraddr) && !ipv6_works) + return 0; + + /* Ok, all tests succeeded, now we can return 1 */ + return 1; +} + + +#ifndef SIM +static u_char +get_correct_host_mode( + int token + ) +{ + switch (token) { + + case T_Server: + case T_Pool: + case T_Manycastclient: + return MODE_CLIENT; + + case T_Peer: + return MODE_ACTIVE; + + case T_Broadcast: + return MODE_BROADCAST; + + default: + return 0; + } +} + + +/* + * peerflag_bits() get config_peers() peerflags value from a + * peer_node's queue of flag attr_val entries. + */ +static int +peerflag_bits( + peer_node *pn + ) +{ + int peerflags; + attr_val *option; + + /* translate peerflags options to bits */ + peerflags = 0; + option = HEAD_PFIFO(pn->peerflags); + for (; option != NULL; option = option->link) { + switch (option->value.i) { + + default: + INSIST(0); + break; + + case T_Autokey: + peerflags |= FLAG_SKEY; + break; + + case T_Burst: + peerflags |= FLAG_BURST; + break; + + case T_Iburst: + peerflags |= FLAG_IBURST; + break; + + case T_Noselect: + peerflags |= FLAG_NOSELECT; + break; + + case T_Preempt: + peerflags |= FLAG_PREEMPT; + break; + + case T_Prefer: + peerflags |= FLAG_PREFER; + break; + + case T_True: + peerflags |= FLAG_TRUE; + break; + + case T_Xleave: + peerflags |= FLAG_XLEAVE; + break; + } + } + + return peerflags; +} + + +static void +config_peers( + config_tree *ptree + ) +{ + sockaddr_u peeraddr; + struct addrinfo hints; + peer_node * curr_peer; + peer_resolved_ctx * ctx; + u_char hmode; + + /* add servers named on the command line with iburst implied */ + for (; + cmdline_server_count > 0; + cmdline_server_count--, cmdline_servers++) { + + ZERO_SOCK(&peeraddr); + /* + * If we have a numeric address, we can safely + * proceed in the mainline with it. Otherwise, hand + * the hostname off to the blocking child. + */ + if (is_ip_address(*cmdline_servers, AF_UNSPEC, + &peeraddr)) { + + SET_PORT(&peeraddr, NTP_PORT); + if (is_sane_resolved_address(&peeraddr, + T_Server)) + peer_config( + &peeraddr, + NULL, + NULL, + MODE_CLIENT, + NTP_VERSION, + 0, + 0, + FLAG_IBURST, + 0, + 0, + NULL); + } else { + /* we have a hostname to resolve */ +# ifdef WORKER + ctx = emalloc_zero(sizeof(*ctx)); + ctx->family = AF_UNSPEC; + ctx->host_mode = T_Server; + ctx->hmode = MODE_CLIENT; + ctx->version = NTP_VERSION; + ctx->flags = FLAG_IBURST; + + ZERO(hints); + hints.ai_family = (u_short)ctx->family; + hints.ai_socktype = SOCK_DGRAM; + hints.ai_protocol = IPPROTO_UDP; + + getaddrinfo_sometime(*cmdline_servers, + "ntp", &hints, + INITIAL_DNS_RETRY, + &peer_name_resolved, + (void *)ctx); +# else /* !WORKER follows */ + msyslog(LOG_ERR, + "hostname %s can not be used, please use IP address instead.", + curr_peer->addr->address); +# endif + } + } + + /* add associations from the configuration file */ + curr_peer = HEAD_PFIFO(ptree->peers); + for (; curr_peer != NULL; curr_peer = curr_peer->link) { + ZERO_SOCK(&peeraddr); + /* Find the correct host-mode */ + hmode = get_correct_host_mode(curr_peer->host_mode); + INSIST(hmode != 0); + + if (T_Pool == curr_peer->host_mode) { + AF(&peeraddr) = curr_peer->addr->type; + peer_config( + &peeraddr, + curr_peer->addr->address, + NULL, + hmode, + curr_peer->peerversion, + curr_peer->minpoll, + curr_peer->maxpoll, + peerflag_bits(curr_peer), + curr_peer->ttl, + curr_peer->peerkey, + curr_peer->group); + /* + * If we have a numeric address, we can safely + * proceed in the mainline with it. Otherwise, hand + * the hostname off to the blocking child. + */ + } else if (is_ip_address(curr_peer->addr->address, + curr_peer->addr->type, &peeraddr)) { + + SET_PORT(&peeraddr, NTP_PORT); + if (is_sane_resolved_address(&peeraddr, + curr_peer->host_mode)) + peer_config( + &peeraddr, + NULL, + NULL, + hmode, + curr_peer->peerversion, + curr_peer->minpoll, + curr_peer->maxpoll, + peerflag_bits(curr_peer), + curr_peer->ttl, + curr_peer->peerkey, + curr_peer->group); + } else { + /* we have a hostname to resolve */ +# ifdef WORKER + ctx = emalloc_zero(sizeof(*ctx)); + ctx->family = curr_peer->addr->type; + ctx->host_mode = curr_peer->host_mode; + ctx->hmode = hmode; + ctx->version = curr_peer->peerversion; + ctx->minpoll = curr_peer->minpoll; + ctx->maxpoll = curr_peer->maxpoll; + ctx->flags = peerflag_bits(curr_peer); + ctx->ttl = curr_peer->ttl; + ctx->keyid = curr_peer->peerkey; + ctx->group = curr_peer->group; + + ZERO(hints); + hints.ai_family = ctx->family; + hints.ai_socktype = SOCK_DGRAM; + hints.ai_protocol = IPPROTO_UDP; + + getaddrinfo_sometime(curr_peer->addr->address, + "ntp", &hints, + INITIAL_DNS_RETRY, + &peer_name_resolved, ctx); +# else /* !WORKER follows */ + msyslog(LOG_ERR, + "hostname %s can not be used, please use IP address instead.", + curr_peer->addr->address); +# endif + } + } +} +#endif /* !SIM */ + +/* + * peer_name_resolved() + * + * Callback invoked when config_peers()'s DNS lookup completes. + */ +#ifdef WORKER +static void +peer_name_resolved( + int rescode, + int gai_errno, + void * context, + const char * name, + const char * service, + const struct addrinfo * hints, + const struct addrinfo * res + ) +{ + sockaddr_u peeraddr; + peer_resolved_ctx * ctx; + u_short af; + const char * fam_spec; + + (void)gai_errno; + (void)service; + (void)hints; + ctx = context; + + DPRINTF(1, ("peer_name_resolved(%s) rescode %d\n", name, rescode)); + + if (rescode) { +#ifndef IGNORE_DNS_ERRORS + free(ctx); + msyslog(LOG_ERR, + "giving up resolving host %s: %s (%d)", + name, gai_strerror(rescode), rescode); +#else /* IGNORE_DNS_ERRORS follows */ + getaddrinfo_sometime(name, service, hints, + INITIAL_DNS_RETRY, + &peer_name_resolved, context); +#endif + return; + } + + /* Loop to configure a single association */ + for (; res != NULL; res = res->ai_next) { + memcpy(&peeraddr, res->ai_addr, res->ai_addrlen); + if (is_sane_resolved_address(&peeraddr, + ctx->host_mode)) { + NLOG(NLOG_SYSINFO) { + af = ctx->family; + fam_spec = (AF_INET6 == af) + ? "(AAAA) " + : (AF_INET == af) + ? "(A) " + : ""; + msyslog(LOG_INFO, "DNS %s %s-> %s", + name, fam_spec, + stoa(&peeraddr)); } + peer_config( + &peeraddr, + NULL, + NULL, + ctx->hmode, + ctx->version, + ctx->minpoll, + ctx->maxpoll, + ctx->flags, + ctx->ttl, + ctx->keyid, + ctx->group); break; + } + } + free(ctx); +} +#endif /* WORKER */ - case CONFIG_FUDGE: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no address for fudge command, line ignored"); + +#ifdef FREE_CFG_T +static void +free_config_peers( + config_tree *ptree + ) +{ + peer_node *curr_peer; + + if (ptree->peers != NULL) { + for (;;) { + UNLINK_FIFO(curr_peer, *ptree->peers, link); + if (NULL == curr_peer) break; + destroy_address_node(curr_peer->addr); + destroy_attr_val_fifo(curr_peer->peerflags); + free(curr_peer); + } + free(ptree->peers); + ptree->peers = NULL; + } +} +#endif /* FREE_CFG_T */ + + +#ifndef SIM +static void +config_unpeers( + config_tree *ptree + ) +{ + sockaddr_u peeraddr; + struct addrinfo hints; + unpeer_node * curr_unpeer; + struct peer * p; + const char * name; + int rc; + + curr_unpeer = HEAD_PFIFO(ptree->unpeers); + for (; curr_unpeer != NULL; curr_unpeer = curr_unpeer->link) { + /* + * Either AssocID will be zero, and we unpeer by name/ + * address addr, or it is nonzero and addr NULL. + */ + if (curr_unpeer->assocID) { + p = findpeerbyassoc(curr_unpeer->assocID); + if (p != NULL) { + msyslog(LOG_NOTICE, "unpeered %s", + stoa(&p->srcadr)); + peer_clear(p, "GONE"); + unpeer(p); } - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (getnetnum(tokens[1], &peeraddr, 1, t_REF) != 1) - break; - if (!ISREFCLOCKADR(&peeraddr)) { - msyslog(LOG_ERR, - "%s is inappropriate address for the fudge command, line ignored", + continue; + } + + ZERO(peeraddr); + AF(&peeraddr) = curr_unpeer->addr->type; + name = curr_unpeer->addr->address; + rc = getnetnum(name, &peeraddr, 0, t_UNK); + /* Do we have a numeric address? */ + if (rc > 0) { + DPRINTF(1, ("unpeer: searching for %s\n", + stoa(&peeraddr))); + p = findexistingpeer(&peeraddr, NULL, NULL, -1, 0); + if (p != NULL) { + msyslog(LOG_NOTICE, "unpeered %s", stoa(&peeraddr)); - break; + peer_clear(p, "GONE"); + unpeer(p); } - memset((void *)&clock_stat, 0, sizeof clock_stat); - fudgeflag = 0; - errflg = 0; - for (i = 2; i < ntokens-1; i++) { - switch (c = matchkey(tokens[i], - fudge_keywords, 1)) { - case CONF_FDG_TIME1: - if (sscanf(tokens[++i], "%lf", - &clock_stat.fudgetime1) != 1) { - msyslog(LOG_ERR, - "fudge %s time1 value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - clock_stat.haveflags |= CLK_HAVETIME1; + continue; + } + /* + * It's not a numeric IP address, it's a hostname. + * Check for associations with a matching hostname. + */ + for (p = peer_list; p != NULL; p = p->p_link) + if (p->hostname != NULL) + if (!strcasecmp(p->hostname, name)) break; + if (p != NULL) { + msyslog(LOG_NOTICE, "unpeered %s", name); + peer_clear(p, "GONE"); + unpeer(p); + } + /* Resolve the hostname to address(es). */ +# ifdef WORKER + ZERO(hints); + hints.ai_family = curr_unpeer->addr->type; + hints.ai_socktype = SOCK_DGRAM; + hints.ai_protocol = IPPROTO_UDP; + getaddrinfo_sometime(name, "ntp", &hints, + INITIAL_DNS_RETRY, + &unpeer_name_resolved, NULL); +# else /* !WORKER follows */ + msyslog(LOG_ERR, + "hostname %s can not be used, please use IP address instead.", + name); +# endif + } +} +#endif /* !SIM */ - case CONF_FDG_TIME2: - if (sscanf(tokens[++i], "%lf", - &clock_stat.fudgetime2) != 1) { - msyslog(LOG_ERR, - "fudge %s time2 value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - clock_stat.haveflags |= CLK_HAVETIME2; - break; + +/* + * unpeer_name_resolved() + * + * Callback invoked when config_unpeers()'s DNS lookup completes. + */ +#ifdef WORKER +static void +unpeer_name_resolved( + int rescode, + int gai_errno, + void * context, + const char * name, + const char * service, + const struct addrinfo * hints, + const struct addrinfo * res + ) +{ + sockaddr_u peeraddr; + struct peer * peer; + u_short af; + const char * fam_spec; + + (void)context; + (void)hints; + DPRINTF(1, ("unpeer_name_resolved(%s) rescode %d\n", name, rescode)); + + if (rescode) { + msyslog(LOG_ERR, "giving up resolving unpeer %s: %s (%d)", + name, gai_strerror(rescode), rescode); + return; + } + /* + * Loop through the addresses found + */ + for (; res != NULL; res = res->ai_next) { + INSIST(res->ai_addrlen <= sizeof(peeraddr)); + memcpy(&peeraddr, res->ai_addr, res->ai_addrlen); + DPRINTF(1, ("unpeer: searching for peer %s\n", + stoa(&peeraddr))); + peer = findexistingpeer(&peeraddr, NULL, NULL, -1, 0); + if (peer != NULL) { + af = AF(&peeraddr); + fam_spec = (AF_INET6 == af) + ? "(AAAA) " + : (AF_INET == af) + ? "(A) " + : ""; + msyslog(LOG_NOTICE, "unpeered %s %s-> %s", name, + fam_spec, stoa(&peeraddr)); + peer_clear(peer, "GONE"); + unpeer(peer); + } + } +} +#endif /* WORKER */ - case CONF_FDG_STRATUM: - if (!atoint(tokens[++i], &stratum)) - { - msyslog(LOG_ERR, - "fudge %s stratum value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - clock_stat.fudgeval1 = stratum; - clock_stat.haveflags |= CLK_HAVEVAL1; - break; +#ifdef FREE_CFG_T +static void +free_config_unpeers( + config_tree *ptree + ) +{ + unpeer_node *curr_unpeer; - case CONF_FDG_REFID: - i++; - memcpy(&clock_stat.fudgeval2, - tokens[i], min(strlen(tokens[i]), - 4)); - clock_stat.haveflags |= CLK_HAVEVAL2; - break; + if (ptree->unpeers != NULL) { + for (;;) { + UNLINK_FIFO(curr_unpeer, *ptree->unpeers, link); + if (NULL == curr_unpeer) + break; + destroy_address_node(curr_unpeer->addr); + free(curr_unpeer); + } + free(ptree->unpeers); + } +} +#endif /* FREE_CFG_T */ - case CONF_FDG_FLAG1: - case CONF_FDG_FLAG2: - case CONF_FDG_FLAG3: - case CONF_FDG_FLAG4: - if (!atouint(tokens[++i], &fudgeflag) - || fudgeflag > 1) { - msyslog(LOG_ERR, - "fudge %s flag value in error", - stoa(&peeraddr)); - errflg = i; - break; - } - switch(c) { - case CONF_FDG_FLAG1: - c = CLK_FLAG1; - clock_stat.haveflags|=CLK_HAVEFLAG1; - break; - case CONF_FDG_FLAG2: - c = CLK_FLAG2; - clock_stat.haveflags|=CLK_HAVEFLAG2; - break; - case CONF_FDG_FLAG3: - c = CLK_FLAG3; - clock_stat.haveflags|=CLK_HAVEFLAG3; - break; - case CONF_FDG_FLAG4: - c = CLK_FLAG4; - clock_stat.haveflags|=CLK_HAVEFLAG4; - break; - } - if (fudgeflag == 0) - clock_stat.flags &= ~c; - else - clock_stat.flags |= c; - break; - case CONFIG_UNKNOWN: - errflg = -1; +#ifndef SIM +static void +config_reset_counters( + config_tree *ptree + ) +{ + int_node *counter_set; + + for (counter_set = HEAD_PFIFO(ptree->reset_counters); + counter_set != NULL; + counter_set = counter_set->link) { + switch (counter_set->i) { + default: + DPRINTF(1, ("config_reset_counters %s (%d) invalid\n", + keyword(counter_set->i), counter_set->i)); + break; + + case T_Allpeers: + peer_all_reset(); + break; + + case T_Auth: + reset_auth_stats(); + break; + + case T_Ctl: + ctl_clr_stats(); + break; + + case T_Io: + io_clr_stats(); + break; + + case T_Mem: + peer_clr_stats(); + break; + + case T_Sys: + proto_clr_stats(); + break; + + case T_Timer: + timer_clr_stats(); + break; + } + } +} +#endif /* !SIM */ + + +#ifdef FREE_CFG_T +static void +free_config_reset_counters( + config_tree *ptree + ) +{ + FREE_INT_FIFO(ptree->reset_counters); +} +#endif /* FREE_CFG_T */ + + +#ifdef SIM +static void +config_sim( + config_tree *ptree + ) +{ + int i; + server_info *serv_info; + attr_val *init_stmt; + sim_node *sim_n; + + /* Check if a simulate block was found in the configuration code. + * If not, return an error and exit + */ + sim_n = HEAD_PFIFO(ptree->sim_details); + if (NULL == sim_n) { + fprintf(stderr, "ERROR!! I couldn't find a \"simulate\" block for configuring the simulator.\n"); + fprintf(stderr, "\tCheck your configuration file.\n"); + exit(1); + } + + /* Process the initialization statements + * ------------------------------------- + */ + init_stmt = HEAD_PFIFO(sim_n->init_opts); + for (; init_stmt != NULL; init_stmt = init_stmt->link) { + switch(init_stmt->attr) { + + case T_Beep_Delay: + simulation.beep_delay = init_stmt->value.d; + break; + + case T_Sim_Duration: + simulation.end_time = init_stmt->value.d; + break; + + default: + fprintf(stderr, + "Unknown simulator init token %d\n", + init_stmt->attr); + exit(1); + } + } + + /* Process the server list + * ----------------------- + */ + simulation.num_of_servers = 0; + serv_info = HEAD_PFIFO(sim_n->servers); + for (; serv_info != NULL; serv_info = serv_info->link) + simulation.num_of_servers++; + simulation.servers = eallocarray(simulation.num_of_servers, + sizeof(simulation.servers[0])); + + i = 0; + serv_info = HEAD_PFIFO(sim_n->servers); + for (; serv_info != NULL; serv_info = serv_info->link) { + if (NULL == serv_info) { + fprintf(stderr, "Simulator server list is corrupt\n"); + exit(1); + } else { + simulation.servers[i] = *serv_info; + simulation.servers[i].link = NULL; + i++; + } + } + + printf("Creating server associations\n"); + create_server_associations(); + fprintf(stderr,"\tServer associations successfully created!!\n"); +} + + +#ifdef FREE_CFG_T +static void +free_config_sim( + config_tree *ptree + ) +{ + sim_node *sim_n; + server_info *serv_n; + script_info *script_n; + + if (NULL == ptree->sim_details) + return; + sim_n = HEAD_PFIFO(ptree->sim_details); + free(ptree->sim_details); + ptree->sim_details = NULL; + if (NULL == sim_n) + return; + + FREE_ATTR_VAL_FIFO(sim_n->init_opts); + for (;;) { + UNLINK_FIFO(serv_n, *sim_n->servers, link); + if (NULL == serv_n) + break; + free(serv_n->curr_script); + if (serv_n->script != NULL) { + for (;;) { + UNLINK_FIFO(script_n, *serv_n->script, + link); + if (script_n == NULL) break; - } + free(script_n); } + free(serv_n->script); + } + free(serv_n); + } + free(sim_n); +} +#endif /* FREE_CFG_T */ +#endif /* SIM */ -#ifdef REFCLOCK - /* - * If reference clock support isn't defined the - * fudge line will still be accepted and syntax - * checked, but will essentially do nothing. - */ - if (!errflg) { - refclock_control(&peeraddr, &clock_stat, - (struct refclockstat *)0); - } + +/* Define two different config functions. One for the daemon and the other for + * the simulator. The simulator ignores a lot of the standard ntpd configuration + * options + */ +#ifndef SIM +static void +config_ntpd( + config_tree *ptree, + int/*BOOL*/ input_from_files + ) +{ + config_nic_rules(ptree, input_from_files); + config_monitor(ptree); + config_auth(ptree); + config_tos(ptree); + config_access(ptree); + config_tinker(ptree); + config_rlimit(ptree); + config_system_opts(ptree); + config_logconfig(ptree); + config_phone(ptree); + config_mdnstries(ptree); + config_setvar(ptree); + config_ttl(ptree); + config_trap(ptree); + config_vars(ptree); + + io_open_sockets(); + + config_other_modes(ptree); + config_peers(ptree); + config_unpeers(ptree); + config_fudge(ptree); + config_reset_counters(ptree); + +#ifdef TEST_BLOCKING_WORKER + { + struct addrinfo hints; + + ZERO(hints); + hints.ai_socktype = SOCK_STREAM; + hints.ai_protocol = IPPROTO_TCP; + getaddrinfo_sometime("www.cnn.com", "ntp", &hints, + INITIAL_DNS_RETRY, + gai_test_callback, (void *)1); + hints.ai_family = AF_INET6; + getaddrinfo_sometime("ipv6.google.com", "ntp", &hints, + INITIAL_DNS_RETRY, + gai_test_callback, (void *)0x600); + } #endif - break; +} +#endif /* !SIM */ - case CONFIG_STATSDIR: - if (ntokens >= 2) - stats_config(STATS_STATSDIR,tokens[1]); - break; - case CONFIG_STATISTICS: - for (i = 1; i < ntokens; i++) { - filegen = filegen_get(tokens[i]); +#ifdef SIM +static void +config_ntpdsim( + config_tree *ptree + ) +{ + printf("Configuring Simulator...\n"); + printf("Some ntpd-specific commands in the configuration file will be ignored.\n"); + + config_tos(ptree); + config_monitor(ptree); + config_tinker(ptree); + if (0) + config_rlimit(ptree); /* not needed for the simulator */ + config_system_opts(ptree); + config_logconfig(ptree); + config_vars(ptree); + config_sim(ptree); +} +#endif /* SIM */ + + +/* + * config_remotely() - implements ntpd side of ntpq :config + */ +void +config_remotely( + sockaddr_u * remote_addr + ) +{ + char origin[128]; + + snprintf(origin, sizeof(origin), "remote config from %s", + stoa(remote_addr)); + lex_init_stack(origin, NULL); /* no checking needed... */ + init_syntax_tree(&cfgt); + yyparse(); + lex_drop_stack(); + + cfgt.source.attr = CONF_SOURCE_NTPQ; + cfgt.timestamp = time(NULL); + cfgt.source.value.s = estrdup(stoa(remote_addr)); + + DPRINTF(1, ("Finished Parsing!!\n")); + + save_and_apply_config_tree(FALSE); +} + + +/* + * getconfig() - process startup configuration file e.g /etc/ntp.conf + */ +void +getconfig( + int argc, + char ** argv + ) +{ + char line[256]; - if (filegen == NULL) { - msyslog(LOG_ERR, - "no statistics named %s available", - tokens[i]); - continue; - } #ifdef DEBUG - if (debug > 3) - printf("enabling filegen for %s statistics \"%s%s\"\n", - tokens[i], filegen->prefix, filegen->basename); + atexit(free_all_config_trees); #endif - filegen->flag |= FGEN_FLAG_ENABLED; - } - break; +#ifndef SYS_WINNT + config_file = CONFIG_FILE; +#else + temp = CONFIG_FILE; + if (!ExpandEnvironmentStringsA(temp, config_file_storage, + sizeof(config_file_storage))) { + msyslog(LOG_ERR, "ExpandEnvironmentStrings CONFIG_FILE failed: %m"); + exit(1); + } + config_file = config_file_storage; - case CONFIG_FILEGEN: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no id for filegen command, line ignored"); - break; - } + temp = ALT_CONFIG_FILE; + if (!ExpandEnvironmentStringsA(temp, alt_config_file_storage, + sizeof(alt_config_file_storage))) { + msyslog(LOG_ERR, "ExpandEnvironmentStrings ALT_CONFIG_FILE failed: %m"); + exit(1); + } + alt_config_file = alt_config_file_storage; +#endif /* SYS_WINNT */ - filegen = filegen_get(tokens[1]); - if (filegen == NULL) { - msyslog(LOG_ERR, - "unknown filegen \"%s\" ignored", - tokens[1]); - break; - } + /* + * install a non default variable with this daemon version + */ + snprintf(line, sizeof(line), "daemon_version=\"%s\"", Version); + set_sys_var(line, strlen(line) + 1, RO); + + /* + * Set up for the first time step to install a variable showing + * which syscall is being used to step. + */ + set_tod_using = &ntpd_set_tod_using; + + getCmdOpts(argc, argv); + init_syntax_tree(&cfgt); + if ( + !lex_init_stack(FindConfig(config_file), "r") +#ifdef HAVE_NETINFO + /* If there is no config_file, try NetInfo. */ + && check_netinfo && !(config_netinfo = get_netinfo_config()) +#endif /* HAVE_NETINFO */ + ) { + msyslog(LOG_INFO, "getconfig: Couldn't open <%s>: %m", FindConfig(config_file)); +#ifndef SYS_WINNT + io_open_sockets(); + + return; +#else + /* Under WinNT try alternate_config_file name, first NTP.CONF, then NTP.INI */ + + if (!lex_init_stack(FindConfig(alt_config_file), "r")) { /* - * peerversion is (ab)used for filegen file (index) - * peerkey is (ab)used for filegen type - * peerflags is (ab)used for filegen flags + * Broadcast clients can sometimes run without + * a configuration file. */ - peerversion = 0; - peerkey = filegen->type; - peerflags = filegen->flag; - errflg = 0; - - for (i = 2; i < ntokens; i++) { - switch (matchkey(tokens[i], - filegen_keywords, 1)) { - case CONF_FGEN_FILE: - if (i >= ntokens - 1) { - msyslog(LOG_ERR, - "filegen %s file requires argument", - tokens[1]); - errflg = i; - break; - } - peerversion = ++i; - break; - case CONF_FGEN_TYPE: - if (i >= ntokens -1) { - msyslog(LOG_ERR, - "filegen %s type requires argument", - tokens[1]); - errflg = i; - break; - } - peerkey = matchkey(tokens[++i], - fgen_types, 1); - if (peerkey == CONFIG_UNKNOWN) { - msyslog(LOG_ERR, - "filegen %s unknown type \"%s\"", - tokens[1], tokens[i]); - errflg = i; - break; - } - break; + msyslog(LOG_INFO, "getconfig: Couldn't open <%s>: %m", FindConfig(alt_config_file)); + io_open_sockets(); + + return; + } + cfgt.source.value.s = estrdup(alt_config_file); +#endif /* SYS_WINNT */ + } else + cfgt.source.value.s = estrdup(config_file); + + + /*** BULK OF THE PARSER ***/ +#ifdef DEBUG + yydebug = !!(debug >= 5); +#endif + yyparse(); + lex_drop_stack(); + + DPRINTF(1, ("Finished Parsing!!\n")); + + cfgt.source.attr = CONF_SOURCE_FILE; + cfgt.timestamp = time(NULL); + + save_and_apply_config_tree(TRUE); + +#ifdef HAVE_NETINFO + if (config_netinfo) + free_netinfo_config(config_netinfo); +#endif /* HAVE_NETINFO */ +} + + +void +save_and_apply_config_tree(int/*BOOL*/ input_from_file) +{ + config_tree *ptree; +#ifndef SAVECONFIG + config_tree *punlinked; +#endif + + /* + * Keep all the configuration trees applied since startup in + * a list that can be used to dump the configuration back to + * a text file. + */ + ptree = emalloc(sizeof(*ptree)); + memcpy(ptree, &cfgt, sizeof(*ptree)); + ZERO(cfgt); + + LINK_TAIL_SLIST(cfg_tree_history, ptree, link, config_tree); + +#ifdef SAVECONFIG + if (HAVE_OPT( SAVECONFIGQUIT )) { + FILE *dumpfile; + int err; + int dumpfailed; + + dumpfile = fopen(OPT_ARG( SAVECONFIGQUIT ), "w"); + if (NULL == dumpfile) { + err = errno; + mfprintf(stderr, + "can not create save file %s, error %d %m\n", + OPT_ARG(SAVECONFIGQUIT), err); + exit(err); + } - case CONF_FGEN_FLAG_LINK: - peerflags |= FGEN_FLAG_LINK; - break; + dumpfailed = dump_all_config_trees(dumpfile, 0); + if (dumpfailed) + fprintf(stderr, + "--saveconfigquit %s error %d\n", + OPT_ARG( SAVECONFIGQUIT ), + dumpfailed); + else + fprintf(stderr, + "configuration saved to %s\n", + OPT_ARG( SAVECONFIGQUIT )); - case CONF_FGEN_FLAG_NOLINK: - peerflags &= ~FGEN_FLAG_LINK; - break; + exit(dumpfailed); + } +#endif /* SAVECONFIG */ - case CONF_FGEN_FLAG_ENABLE: - peerflags |= FGEN_FLAG_ENABLED; - break; + /* The actual configuration done depends on whether we are configuring the + * simulator or the daemon. Perform a check and call the appropriate + * function as needed. + */ - case CONF_FGEN_FLAG_DISABLE: - peerflags &= ~FGEN_FLAG_ENABLED; - break; - } - } - if (!errflg) - filegen_config(filegen, tokens[peerversion], - (u_char)peerkey, (u_char)peerflags); - break; +#ifndef SIM + config_ntpd(ptree, input_from_file); +#else + config_ntpdsim(ptree); +#endif - case CONFIG_SETVAR: - if (ntokens < 2) { - msyslog(LOG_ERR, - "no value for setvar command - line ignored"); - } else { - set_sys_var(tokens[1], strlen(tokens[1])+1, - (u_short) (RW | - ((((ntokens > 2) - && !strcmp(tokens[2], - "default"))) - ? DEF - : 0))); - } - break; + /* + * With configure --disable-saveconfig, there's no use keeping + * the config tree around after application, so free it. + */ +#ifndef SAVECONFIG + UNLINK_SLIST(punlinked, cfg_tree_history, ptree, link, + config_tree); + INSIST(punlinked == ptree); + free_config_tree(ptree); +#endif +} - case CONFIG_ENABLE: - for (i = 1; i < ntokens; i++) { - int flag; - flag = matchkey(tokens[i], flags_keywords, 1); - if (flag == CONFIG_UNKNOWN) { - msyslog(LOG_ERR, - "enable unknown flag %s", - tokens[i]); - errflg = 1; - break; - } - proto_config(flag, 1, 0., NULL); - } - break; +static void +ntpd_set_tod_using( + const char *which + ) +{ + char line[128]; - case CONFIG_DISABLE: - for (i = 1; i < ntokens; i++) { - int flag; + snprintf(line, sizeof(line), "settimeofday=\"%s\"", which); + set_sys_var(line, strlen(line) + 1, RO); +} - flag = matchkey(tokens[i], flags_keywords, 1); - if (flag == CONFIG_UNKNOWN) { - msyslog(LOG_ERR, - "disable unknown flag %s", - tokens[i]); - errflg = 1; - break; - } - proto_config(flag, 0, 0., NULL); - } - break; - case CONFIG_PHONE: - for (i = 1; i < ntokens && i < MAXPHONE - 1; i++) { - sys_phone[i - 1] = - emalloc(strlen(tokens[i]) + 1); - strcpy(sys_phone[i - 1], tokens[i]); - } - sys_phone[i] = NULL; - break; +static char * +normal_dtoa( + double d + ) +{ + char * buf; + char * pch_e; + char * pch_nz; + + LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%g", d); + + /* use lowercase 'e', strip any leading zeroes in exponent */ + pch_e = strchr(buf, 'e'); + if (NULL == pch_e) { + pch_e = strchr(buf, 'E'); + if (NULL == pch_e) + return buf; + *pch_e = 'e'; + } + pch_e++; + if ('-' == *pch_e) + pch_e++; + pch_nz = pch_e; + while ('0' == *pch_nz) + pch_nz++; + if (pch_nz == pch_e) + return buf; + strlcpy(pch_e, pch_nz, LIB_BUFLENGTH - (pch_e - buf)); + + return buf; +} - case CONFIG_ADJ: { - double ftemp; - sscanf(tokens[1], "%lf", &ftemp); - proto_config(PROTO_ADJ, 0, ftemp, NULL); - } - break; +/* FUNCTIONS COPIED FROM THE OLDER ntp_config.c + * -------------------------------------------- + */ + +/* + * get_pfxmatch - find value for prefixmatch + * and update char * accordingly + */ +static u_int32 +get_pfxmatch( + const char ** pstr, + struct masks * m + ) +{ + while (m->name != NULL) { + if (strncmp(*pstr, m->name, strlen(m->name)) == 0) { + *pstr += strlen(m->name); + return m->mask; + } else { + m++; } } - if (fp[0]) - (void)fclose(fp[0]); + return 0; +} -#ifdef HAVE_NETINFO - if (config_netinfo) - free_netinfo_config(config_netinfo); -#endif /* HAVE_NETINFO */ +/* + * get_match - find logmask value + */ +static u_int32 +get_match( + const char * str, + struct masks * m + ) +{ + while (m->name != NULL) { + if (strcmp(str, m->name) == 0) + return m->mask; + else + m++; + } + return 0; +} -#if !defined(VMS) && !defined(SYS_VXWORKS) - /* find a keyid */ - if (info_auth_keyid == 0) - req_keyid = 65535; - else - req_keyid = info_auth_keyid; +/* + * get_logmask - build bitmask for ntp_syslogmask + */ +static u_int32 +get_logmask( + const char * str + ) +{ + const char * t; + u_int32 offset; + u_int32 mask; - /* if doesn't exist, make up one at random */ - if (!authhavekey(req_keyid)) { - char rankey[9]; - int j; + mask = get_match(str, logcfg_noclass_items); + if (mask != 0) + return mask; - for (i = 0; i < 8; i++) - for (j = 1; j < 100; ++j) { - rankey[i] = (char) (arc4random() & 0xff); - if (rankey[i] != 0) break; - } - rankey[8] = 0; - authusekey(req_keyid, KEY_TYPE_MD5, (u_char *)rankey); - authtrust(req_keyid, 1); - if (!authhavekey(req_keyid)) { - msyslog(LOG_ERR, "getconfig: Couldn't generate a valid random key!"); - /* HMS: Should this be fatal? */ - } - } + t = str; + offset = get_pfxmatch(&t, logcfg_class); + mask = get_match(t, logcfg_class_items); - /* save keyid so we will accept config requests with it */ - info_auth_keyid = req_keyid; -#endif /* !defined(VMS) && !defined(SYS_VXWORKS) */ + if (mask) + return mask << offset; + else + msyslog(LOG_ERR, "logconfig: '%s' not recognized - ignored", + str); - if (res_fp != NULL) { - if (call_resolver) { - /* - * Need name resolution - */ - do_resolve_internal(); - } - } + return 0; } #ifdef HAVE_NETINFO -/* +/* * get_netinfo_config - find the nearest NetInfo domain with an ntp * configuration and initialize the configuration state. */ static struct netinfo_config_state * -get_netinfo_config() +get_netinfo_config(void) { ni_status status; void *domain; ni_id config_dir; - struct netinfo_config_state *config; + struct netinfo_config_state *config; if (ni_open(NULL, ".", &domain) != NI_OK) return NULL; @@ -1944,30 +4753,30 @@ get_netinfo_config() return NULL; } - config = (struct netinfo_config_state *)malloc(sizeof(struct netinfo_config_state)); - config->domain = domain; - config->config_dir = config_dir; - config->prop_index = 0; - config->val_index = 0; - config->val_list = NULL; + config = emalloc(sizeof(*config)); + config->domain = domain; + config->config_dir = config_dir; + config->prop_index = 0; + config->val_index = 0; + config->val_list = NULL; return config; } - /* * free_netinfo_config - release NetInfo configuration state */ static void -free_netinfo_config(struct netinfo_config_state *config) +free_netinfo_config( + struct netinfo_config_state *config + ) { ni_free(config->domain); free(config); } - /* * gettokens_netinfo - return tokens from NetInfo */ @@ -1985,35 +4794,40 @@ gettokens_netinfo ( /* * Iterate through each keyword and look for a property that matches it. */ - again: + again: if (!val_list) { - for (; prop_index < (sizeof(keywords)/sizeof(keywords[0])); prop_index++) - { - ni_namelist namelist; + for (; prop_index < COUNTOF(keywords); prop_index++) + { + ni_namelist namelist; struct keyword current_prop = keywords[prop_index]; + ni_index index; /* * For each value associated in the property, we're going to return * a separate line. We squirrel away the values in the config state * so the next time through, we don't need to do this lookup. */ - NI_INIT(&namelist); - if (ni_lookupprop(config->domain, &config->config_dir, current_prop.text, &namelist) == NI_OK) { - ni_index index; + NI_INIT(&namelist); + if (NI_OK == ni_lookupprop(config->domain, + &config->config_dir, current_prop.text, + &namelist)) { /* Found the property, but it has no values */ if (namelist.ni_namelist_len == 0) continue; - if (! (val_list = config->val_list = (char**)malloc(sizeof(char*) * (namelist.ni_namelist_len + 1)))) - { msyslog(LOG_ERR, "out of memory while configuring"); break; } - - for (index = 0; index < namelist.ni_namelist_len; index++) { - char *value = namelist.ni_namelist_val[index]; + config->val_list = + eallocarray( + (namelist.ni_namelist_len + 1), + sizeof(char*)); + val_list = config->val_list; - if (! (val_list[index] = (char*)malloc(strlen(value)+1))) - { msyslog(LOG_ERR, "out of memory while configuring"); break; } + for (index = 0; + index < namelist.ni_namelist_len; + index++) { + char *value; - strcpy(val_list[index], value); + value = namelist.ni_namelist_val[index]; + val_list[index] = estrdup(value); } val_list[index] = NULL; @@ -2025,14 +4839,14 @@ gettokens_netinfo ( } /* No list; we're done here. */ - if (!val_list) return CONFIG_UNKNOWN; + if (!val_list) + return CONFIG_UNKNOWN; /* * We have a list of values for the current property. * Iterate through them and return each in order. */ - if (val_list[val_index]) - { + if (val_list[val_index]) { int ntok = 1; int quoted = 0; char *tokens = val_list[val_index]; @@ -2050,16 +4864,18 @@ gettokens_netinfo ( break; } else { /* must be space */ *tokens++ = '\0'; - while (ISSPACE(*tokens)) tokens++; - if (ISEOL(*tokens)) break; + while (ISSPACE(*tokens)) + tokens++; + if (ISEOL(*tokens)) + break; } } if (ntok == MAXTOKENS) { /* HMS: chomp it to lose the EOL? */ msyslog(LOG_ERR, - "gettokens_netinfo: too many tokens. Ignoring: %s", - tokens); + "gettokens_netinfo: too many tokens. Ignoring: %s", + tokens); } else { *ntokens = ntok + 1; } @@ -2075,508 +4891,124 @@ gettokens_netinfo ( /* Free val_list and reset counters. */ for (val_index = 0; val_list[val_index]; val_index++) free(val_list[val_index]); - free(val_list); val_list = config->val_list = NULL; val_index = config->val_index = 0; + free(val_list); + val_list = config->val_list = NULL; + val_index = config->val_index = 0; goto again; } - #endif /* HAVE_NETINFO */ -/* - * gettokens - read a line and return tokens - */ -static int -gettokens ( - FILE *fp, - char *line, - char **tokenlist, - int *ntokens - ) -{ - register char *cp; - register int ntok; - register int quoted = 0; - - /* - * Find start of first token - */ - again: - while ((cp = fgets(line, MAXLINE, fp)) != NULL) { - cp = line; - while (ISSPACE(*cp)) - cp++; - if (!ISEOL(*cp)) - break; - } - if (cp == NULL) { - *ntokens = 0; - return CONFIG_UNKNOWN; /* hack. Is recognized as EOF */ - } - - /* - * Now separate out the tokens - */ - for (ntok = 0; ntok < MAXTOKENS; ntok++) { - tokenlist[ntok] = cp; - while (!ISEOL(*cp) && (!ISSPACE(*cp) || quoted)) - quoted ^= (*cp++ == '"'); - - if (ISEOL(*cp)) { - *cp = '\0'; - break; - } else { /* must be space */ - *cp++ = '\0'; - while (ISSPACE(*cp)) - cp++; - if (ISEOL(*cp)) - break; - } - } - - /* Heiko: Remove leading and trailing quotes around tokens */ - { - int i,j = 0; - - - for (i = 0; i < ntok; i++) { - /* Now check if the first char is a quote and remove that */ - if ( tokenlist[ntok][0] == '"' ) - tokenlist[ntok]++; - - /* Now check the last char ... */ - j = strlen(tokenlist[ntok])-1; - if ( tokenlist[ntok][j] == '"' ) - tokenlist[ntok][j] = '\0'; - } - - } - - if (ntok == MAXTOKENS) { - --ntok; - /* HMS: chomp it to lose the EOL? */ - msyslog(LOG_ERR, - "gettokens: too many tokens on the line. Ignoring %s", - cp); - } else { - /* - * Return the match - */ - *ntokens = ntok + 1; - ntok = matchkey(tokenlist[0], keywords, 1); - if (ntok == CONFIG_UNKNOWN) - goto again; - } - - return ntok; -} - - - -/* - * matchkey - match a keyword to a list - */ -static int -matchkey( - register char *word, - register struct keyword *keys, - int complain - ) -{ - for (;;) { - if (keys->keytype == CONFIG_UNKNOWN) { - if (complain) - msyslog(LOG_ERR, - "configure: keyword \"%s\" unknown, line ignored", - word); - return CONFIG_UNKNOWN; - } - if (STRSAME(word, keys->text)) - return keys->keytype; - keys++; - } -} - - /* * getnetnum - return a net number (this is crude, but careful) + * + * returns 1 for success, and mysteriously, 0 for most failures, and + * -1 if the address found is IPv6 and we believe IPv6 isn't working. */ +#ifndef SIM static int getnetnum( const char *num, - struct sockaddr_storage *addr, + sockaddr_u *addr, int complain, - enum gnn_type a_type + enum gnn_type a_type /* ignored */ ) { - struct addrinfo hints; - struct addrinfo *ptr; - int retval; - -#if 0 - printf("getnetnum: <%s> is a %s (%d)\n", - num, - (a_type == t_UNK) - ? "t_UNK" - : (a_type == t_REF) - ? "t_REF" - : (a_type == t_MSK) - ? "t_MSK" - : "???", - a_type); -#endif + REQUIRE(AF_UNSPEC == AF(addr) || + AF_INET == AF(addr) || + AF_INET6 == AF(addr)); - /* Get host address. Looking for UDP datagram connection */ - memset(&hints, 0, sizeof (hints)); - if (addr->ss_family == AF_INET || addr->ss_family == AF_INET6) - hints.ai_family = addr->ss_family; - else - hints.ai_family = AF_UNSPEC; - /* - * If we don't have an IPv6 stack, just look up IPv4 addresses - */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) - hints.ai_family = AF_INET; + if (!is_ip_address(num, AF(addr), addr)) + return 0; - hints.ai_socktype = SOCK_DGRAM; + if (IS_IPV6(addr) && !ipv6_works) + return -1; - if (a_type != t_UNK) { - hints.ai_flags = AI_NUMERICHOST; - } +# ifdef ISC_PLATFORM_HAVESALEN + addr->sa.sa_len = SIZEOF_SOCKADDR(AF(addr)); +# endif + SET_PORT(addr, NTP_PORT); -#ifdef DEBUG - if (debug > 3) - printf("getnetnum: calling getaddrinfo(%s,...)\n", num); -#endif - retval = getaddrinfo(num, "ntp", &hints, &ptr); - if (retval != 0 || - (ptr->ai_family == AF_INET6 && isc_net_probeipv6() != ISC_R_SUCCESS)) { - if (complain) - msyslog(LOG_ERR, - "getaddrinfo: \"%s\" invalid host address, ignored", - num); -#ifdef DEBUG - if (debug > 0) - printf( - "getaddrinfo: \"%s\" invalid host address%s.\n", - num, (complain) - ? ", ignored" - : ""); -#endif - if (retval == 0 && - ptr->ai_family == AF_INET6 && - isc_net_probeipv6() != ISC_R_SUCCESS) - { - return -1; - } - else { - return 0; - } - } + DPRINTF(2, ("getnetnum given %s, got %s\n", num, stoa(addr))); - memcpy(addr, ptr->ai_addr, ptr->ai_addrlen); -#ifdef DEBUG - if (debug > 1) - printf("getnetnum given %s, got %s (%s/%d)\n", - num, stoa(addr), - (a_type == t_UNK) - ? "t_UNK" - : (a_type == t_REF) - ? "t_REF" - : (a_type == t_MSK) - ? "t_MSK" - : "???", - a_type); -#endif - freeaddrinfo(ptr); return 1; } +#endif /* !SIM */ - -#if !defined(VMS) && !defined(SYS_WINNT) -/* - * catchchild - receive the resolver's exit status - */ -static RETSIGTYPE -catchchild( - int sig +#if defined(HAVE_SETRLIMIT) +void +ntp_rlimit( + int rl_what, + rlim_t rl_value, + int rl_scale, + const char * rl_sstr ) { - /* - * We only start up one child, and if we're here - * it should have already exited. Hence the following - * shouldn't hang. If it does, please tell me. - */ -#if !defined (SYS_WINNT) && !defined(SYS_VXWORKS) - (void) wait(0); -#endif /* SYS_WINNT && VXWORKS*/ -} -#endif /* VMS */ - - -/* - * save_resolve - save configuration info into a file for later name resolution - */ -static void -save_resolve( - char *name, - int mode, - int version, - int minpoll, - int maxpoll, - u_int flags, - int ttl, - keyid_t keyid, - u_char *keystr, - u_char peeraf - ) -{ -#ifndef SYS_VXWORKS - if (res_fp == NULL) { -#ifndef SYS_WINNT - (void) strcpy(res_file, RES_TEMPFILE); -#else - /* no /tmp directory under NT */ - { - if(!(GetTempPath((DWORD)MAX_PATH, (LPTSTR)res_file))) { - msyslog(LOG_ERR, "cannot get pathname for temporary directory: %m"); - return; - } - (void) strcat(res_file, "ntpdXXXXXX"); - } -#endif /* SYS_WINNT */ -#ifdef HAVE_MKSTEMP - { - int fd; - - res_fp = NULL; - if ((fd = mkstemp(res_file)) != -1) - res_fp = fdopen(fd, "r+"); - } -#else - (void) mktemp(res_file); - res_fp = fopen(res_file, "w"); -#endif - if (res_fp == NULL) { - msyslog(LOG_ERR, "open failed for %s: %m", res_file); - return; - } - } -#ifdef DEBUG - if (debug) { - printf("resolving %s\n", name); - } -#endif - - (void)fprintf(res_fp, "%s %u %d %d %d %d %d %d %u %s\n", name, peeraf, - mode, version, minpoll, maxpoll, flags, ttl, keyid, keystr); -#ifdef DEBUG - if (debug > 1) - printf("config: %s %u %d %d %d %d %x %d %u %s\n", name, peeraf, mode, - version, minpoll, maxpoll, flags, ttl, keyid, keystr); -#endif - -#else /* SYS_VXWORKS */ - /* save resolve info to a struct */ -#endif /* SYS_VXWORKS */ -} - - -/* - * abort_resolve - terminate the resolver stuff and delete the file - */ -static void -abort_resolve(void) -{ - /* - * In an ideal world we would might reread the file and - * log the hosts which aren't getting configured. Since - * this is too much work, however, just close and delete - * the temp file. - */ - if (res_fp != NULL) - (void) fclose(res_fp); - res_fp = NULL; - -#ifndef SYS_VXWORKS /* we don't open the file to begin with */ -#if !defined(VMS) - (void) unlink(res_file); -#else - (void) delete(res_file); -#endif /* VMS */ -#endif /* SYS_VXWORKS */ -} - - -/* - * do_resolve_internal - start up the resolver function (not program) - */ -/* - * On VMS, this routine will simply refuse to resolve anything. - * - * Possible implementation: keep `res_file' in memory, do async - * name resolution via QIO, update from within completion AST. - * I'm unlikely to find the time for doing this, though. -wjm - */ -static void -do_resolve_internal(void) -{ - int i; - - if (res_fp == NULL) { - /* belch */ - msyslog(LOG_ERR, - "do_resolve_internal: Fatal: res_fp == NULL"); - exit(1); - } - - /* we are done with this now */ - (void) fclose(res_fp); - res_fp = NULL; - -#if !defined(VMS) && !defined (SYS_VXWORKS) - req_file = res_file; /* set up pointer to res file */ -#ifndef SYS_WINNT - (void) signal_no_reset(SIGCHLD, catchchild); - -#ifndef SYS_VXWORKS - /* the parent process will write to the pipe - * in order to wake up to child process - * which may be waiting in a select() call - * on the read fd */ - if (pipe(resolver_pipe_fd) < 0) { - msyslog(LOG_ERR, - "unable to open resolver pipe"); - exit(1); - } + struct rlimit rl; - i = fork(); - /* Shouldn't the code below be re-ordered? - * I.e. first check if the fork() returned an error, then - * check whether we're parent or child. - * Martin Burnicki - */ - if (i == 0) { + switch (rl_what) { +# ifdef RLIMIT_MEMLOCK + case RLIMIT_MEMLOCK: /* - * this used to close everything - * I don't think this is necessary + * The default RLIMIT_MEMLOCK is very low on Linux systems. + * Unless we increase this limit malloc calls are likely to + * fail if we drop root privilege. To be useful the value + * has to be larger than the largest ntpd resident set size. */ + DPRINTF(2, ("ntp_rlimit: MEMLOCK: %d %s\n", + (int)(rl_value / rl_scale), rl_sstr)); + rl.rlim_cur = rl.rlim_max = rl_value; + if (setrlimit(RLIMIT_MEMLOCK, &rl) == -1) + msyslog(LOG_ERR, "Cannot set RLIMIT_MEMLOCK: %m"); + break; +# endif /* RLIMIT_MEMLOCK */ + +# ifdef RLIMIT_NOFILE + case RLIMIT_NOFILE: /* - * To the unknown commenter above: - * Well, I think it's better to clean up - * after oneself. I have had problems with - * refclock-io when intres was running - things - * where fine again when ntpintres was gone. - * So some systems react erratic at least. - * - * Frank Kardel - * - * 94-11-16: - * Further debugging has proven that the above is - * absolutely harmful. The internal resolver - * is still in the SIGIO process group and the lingering - * async io information causes it to process requests from - * all file decriptor causing a race between the NTP daemon - * and the resolver. which then eats data when it wins 8-(. - * It is absolutly necessary to kill any IO associations - * shared with the NTP daemon. - * - * We also block SIGIO (currently no ports means to - * disable the signal handle for IO). - * - * Thanks to wgstuken@informatik.uni-erlangen.de to notice - * that it is the ntp-resolver child running into trouble. - * - * THUS: + * For large systems the default file descriptor limit may + * not be enough. */ - - /* This is the child process who will read the pipe, - * so we close the write fd */ - close(resolver_pipe_fd[1]); - closelog(); - kill_asyncio(0); - - (void) signal_no_reset(SIGCHLD, SIG_DFL); - -#ifdef DEBUG - if (0) - debug = 2; -#endif - -# ifndef LOG_DAEMON - openlog("ntpd_initres", LOG_PID); -# else /* LOG_DAEMON */ - -# ifndef LOG_NTP -# define LOG_NTP LOG_DAEMON -# endif - openlog("ntpd_initres", LOG_PID | LOG_NDELAY, LOG_NTP); -#ifndef SYS_CYGWIN32 -# ifdef DEBUG - if (debug) - setlogmask(LOG_UPTO(LOG_DEBUG)); - else -# endif /* DEBUG */ - setlogmask(LOG_UPTO(LOG_DEBUG)); /* @@@ was INFO */ -# endif /* LOG_DAEMON */ -#endif - - ntp_intres(); - + DPRINTF(2, ("ntp_rlimit: NOFILE: %d %s\n", + (int)(rl_value / rl_scale), rl_sstr)); + rl.rlim_cur = rl.rlim_max = rl_value; + if (setrlimit(RLIMIT_NOFILE, &rl) == -1) + msyslog(LOG_ERR, "Cannot set RLIMIT_NOFILE: %m"); + break; +# endif /* RLIMIT_NOFILE */ + +# ifdef RLIMIT_STACK + case RLIMIT_STACK: /* - * If we got here, the intres code screwed up. - * Print something so we don't die without complaint - */ - msyslog(LOG_ERR, "call to ntp_intres lost"); - abort_resolve(); - exit(1); - } -#else - /* vxWorks spawns a thread... -casey */ - i = sp (ntp_intres); - /*i = taskSpawn("ntp_intres",100,VX_FP_TASK,20000,ntp_intres);*/ -#endif - if (i == -1) { - msyslog(LOG_ERR, "fork() failed, can't start ntp_intres: %m"); - (void) signal_no_reset(SIGCHLD, SIG_DFL); - abort_resolve(); - } - else { - /* This is the parent process who will write to the pipe, - * so we close the read fd */ - close(resolver_pipe_fd[0]); - } -#else /* SYS_WINNT */ - { - /* NT's equivalent of fork() is _spawn(), but the start point - * of the new process is an executable filename rather than - * a function name as desired here. + * Provide a way to set the stack limit to something + * smaller, so that we don't lock a lot of unused + * stack memory. */ - DWORD dwThreadId; - fflush(stdout); - ResolverEventHandle = CreateEvent(NULL, FALSE, FALSE, NULL); - if (ResolverEventHandle == NULL) { - msyslog(LOG_ERR, "Unable to create resolver event object, can't start ntp_intres"); - abort_resolve(); - } - ResolverThreadHandle = CreateThread( - NULL, /* no security attributes */ - 0, /* use default stack size */ - (LPTHREAD_START_ROUTINE) ntp_intres, /* thread function */ - NULL, /* argument to thread function */ - 0, /* use default creation flags */ - &dwThreadId); /* returns the thread identifier */ - if (ResolverThreadHandle == NULL) { - msyslog(LOG_ERR, "CreateThread() failed, can't start ntp_intres"); - CloseHandle(ResolverEventHandle); - ResolverEventHandle = NULL; - abort_resolve(); + DPRINTF(2, ("ntp_rlimit: STACK: %d %s pages\n", + (int)(rl_value / rl_scale), rl_sstr)); + if (-1 == getrlimit(RLIMIT_STACK, &rl)) { + msyslog(LOG_ERR, "getrlimit(RLIMIT_STACK) failed: %m"); + } else { + if (rl_value > rl.rlim_max) { + msyslog(LOG_WARNING, + "ntp_rlimit: using maximum allowed stack limit %lu instead of %lu.", + (u_long)rl.rlim_max, + (u_long)rl_value); + rl_value = rl.rlim_max; + } + rl.rlim_cur = rl_value; + if (-1 == setrlimit(RLIMIT_STACK, &rl)) { + msyslog(LOG_ERR, + "ntp_rlimit: Cannot set RLIMIT_STACK: %m"); + } } + break; +# endif /* RLIMIT_STACK */ + + default: + INSIST(!"Unexpected setrlimit() case!"); + break; } -#endif /* SYS_WINNT */ -#else /* VMS VX_WORKS */ - msyslog(LOG_ERR, - "Name resolution not implemented for VMS - use numeric addresses"); - abort_resolve(); -#endif /* VMS VX_WORKS */ } +#endif /* HAVE_SETRLIMIT */ diff --git a/contrib/ntp/ntpd/ntp_control.c b/contrib/ntp/ntpd/ntp_control.c index dbee89a0c..77363117b 100644 --- a/contrib/ntp/ntpd/ntp_control.c +++ b/contrib/ntp/ntpd/ntp_control.c @@ -1,14 +1,20 @@ /* - * ntp_control.c - respond to control messages and send async traps - */ - -/* - * $FreeBSD$ + * ntp_control.c - respond to mode 6 control messages and send async + * traps. Provides service to ntpq and others. */ #ifdef HAVE_CONFIG_H -#include +# include +#endif + +#include +#include +#include +#include +#ifdef HAVE_NETINET_IN_H +# include #endif +#include #include "ntpd.h" #include "ntp_io.h" @@ -16,138 +22,428 @@ #include "ntp_control.h" #include "ntp_unixtime.h" #include "ntp_stdlib.h" - -#include -#include -#include - -#include -#include - -#ifndef MIN -#define MIN(a, b) (((a) <= (b)) ? (a) : (b)) +#include "ntp_config.h" +#include "ntp_crypto.h" +#include "ntp_assert.h" +#include "ntp_leapsec.h" +#include "ntp_md5.h" /* provides OpenSSL digest API */ +#include "lib_strbuf.h" +#include +#ifdef KERNEL_PLL +# include "ntp_syscall.h" #endif + /* * Structure to hold request procedure information */ -#define NOAUTH 0 -#define AUTH 1 - -#define NO_REQUEST (-1) struct ctl_proc { short control_code; /* defined request code */ +#define NO_REQUEST (-1) u_short flags; /* flags word */ - void (*handler) P((struct recvbuf *, int)); /* handle request */ -}; - -/* - * Only one flag. Authentication required or not. - */ + /* Only one flag. Authentication required or not. */ #define NOAUTH 0 #define AUTH 1 + void (*handler) (struct recvbuf *, int); /* handle request */ +}; + /* * Request processing routines */ -static void ctl_error P((int)); +static void ctl_error (u_char); #ifdef REFCLOCK -static u_short ctlclkstatus P((struct refclockstat *)); -#endif -static void ctl_flushpkt P((int)); -static void ctl_putdata P((const char *, unsigned int, int)); -static void ctl_putstr P((const char *, const char *, - unsigned int)); -static void ctl_putdbl P((const char *, double)); -static void ctl_putuint P((const char *, u_long)); -static void ctl_puthex P((const char *, u_long)); -static void ctl_putint P((const char *, long)); -static void ctl_putts P((const char *, l_fp *)); -static void ctl_putadr P((const char *, u_int32, struct sockaddr_storage*)); -static void ctl_putid P((const char *, char *)); -static void ctl_putarray P((const char *, double *, int)); -static void ctl_putsys P((int)); -static void ctl_putpeer P((int, struct peer *)); -#ifdef OPENSSL -static void ctl_putfs P((const char *, tstamp_t)); +static u_short ctlclkstatus (struct refclockstat *); #endif +static void ctl_flushpkt (u_char); +static void ctl_putdata (const char *, unsigned int, int); +static void ctl_putstr (const char *, const char *, size_t); +static void ctl_putdblf (const char *, int, int, double); +#define ctl_putdbl(tag, d) ctl_putdblf(tag, 1, 3, d) +#define ctl_putdbl6(tag, d) ctl_putdblf(tag, 1, 6, d) +#define ctl_putsfp(tag, sfp) ctl_putdblf(tag, 0, -1, \ + FPTOD(sfp)) +static void ctl_putuint (const char *, u_long); +static void ctl_puthex (const char *, u_long); +static void ctl_putint (const char *, long); +static void ctl_putts (const char *, l_fp *); +static void ctl_putadr (const char *, u_int32, + sockaddr_u *); +static void ctl_putrefid (const char *, u_int32); +static void ctl_putarray (const char *, double *, int); +static void ctl_putsys (int); +static void ctl_putpeer (int, struct peer *); +static void ctl_putfs (const char *, tstamp_t); #ifdef REFCLOCK -static void ctl_putclock P((int, struct refclockstat *, int)); +static void ctl_putclock (int, struct refclockstat *, int); #endif /* REFCLOCK */ -static struct ctl_var *ctl_getitem P((struct ctl_var *, char **)); -static u_long count_var P((struct ctl_var *)); -static void control_unspec P((struct recvbuf *, int)); -static void read_status P((struct recvbuf *, int)); -static void read_variables P((struct recvbuf *, int)); -static void write_variables P((struct recvbuf *, int)); -static void read_clock_status P((struct recvbuf *, int)); -static void write_clock_status P((struct recvbuf *, int)); -static void set_trap P((struct recvbuf *, int)); -static void unset_trap P((struct recvbuf *, int)); -static struct ctl_trap *ctlfindtrap P((struct sockaddr_storage *, - struct interface *)); - -static struct ctl_proc control_codes[] = { - { CTL_OP_UNSPEC, NOAUTH, control_unspec }, - { CTL_OP_READSTAT, NOAUTH, read_status }, - { CTL_OP_READVAR, NOAUTH, read_variables }, - { CTL_OP_WRITEVAR, AUTH, write_variables }, - { CTL_OP_READCLOCK, NOAUTH, read_clock_status }, - { CTL_OP_WRITECLOCK, NOAUTH, write_clock_status }, - { CTL_OP_SETTRAP, NOAUTH, set_trap }, - { CTL_OP_UNSETTRAP, NOAUTH, unset_trap }, - { NO_REQUEST, 0 } +static const struct ctl_var *ctl_getitem(const struct ctl_var *, + char **); +static u_short count_var (const struct ctl_var *); +static void control_unspec (struct recvbuf *, int); +static void read_status (struct recvbuf *, int); +static void read_sysvars (void); +static void read_peervars (void); +static void read_variables (struct recvbuf *, int); +static void write_variables (struct recvbuf *, int); +static void read_clockstatus(struct recvbuf *, int); +static void write_clockstatus(struct recvbuf *, int); +static void set_trap (struct recvbuf *, int); +static void save_config (struct recvbuf *, int); +static void configure (struct recvbuf *, int); +static void send_mru_entry (mon_entry *, int); +static void send_random_tag_value(int); +static void read_mru_list (struct recvbuf *, int); +static void send_ifstats_entry(endpt *, u_int); +static void read_ifstats (struct recvbuf *); +static void sockaddrs_from_restrict_u(sockaddr_u *, sockaddr_u *, + restrict_u *, int); +static void send_restrict_entry(restrict_u *, int, u_int); +static void send_restrict_list(restrict_u *, int, u_int *); +static void read_addr_restrictions(struct recvbuf *); +static void read_ordlist (struct recvbuf *, int); +static u_int32 derive_nonce (sockaddr_u *, u_int32, u_int32); +static void generate_nonce (struct recvbuf *, char *, size_t); +static int validate_nonce (const char *, struct recvbuf *); +static void req_nonce (struct recvbuf *, int); +static void unset_trap (struct recvbuf *, int); +static struct ctl_trap *ctlfindtrap(sockaddr_u *, + struct interface *); + +static const struct ctl_proc control_codes[] = { + { CTL_OP_UNSPEC, NOAUTH, control_unspec }, + { CTL_OP_READSTAT, NOAUTH, read_status }, + { CTL_OP_READVAR, NOAUTH, read_variables }, + { CTL_OP_WRITEVAR, AUTH, write_variables }, + { CTL_OP_READCLOCK, NOAUTH, read_clockstatus }, + { CTL_OP_WRITECLOCK, NOAUTH, write_clockstatus }, + { CTL_OP_SETTRAP, NOAUTH, set_trap }, + { CTL_OP_CONFIGURE, AUTH, configure }, + { CTL_OP_SAVECONFIG, AUTH, save_config }, + { CTL_OP_READ_MRU, NOAUTH, read_mru_list }, + { CTL_OP_READ_ORDLIST_A, AUTH, read_ordlist }, + { CTL_OP_REQ_NONCE, NOAUTH, req_nonce }, + { CTL_OP_UNSETTRAP, NOAUTH, unset_trap }, + { NO_REQUEST, 0, NULL } }; +/* + * System variables we understand + */ +#define CS_LEAP 1 +#define CS_STRATUM 2 +#define CS_PRECISION 3 +#define CS_ROOTDELAY 4 +#define CS_ROOTDISPERSION 5 +#define CS_REFID 6 +#define CS_REFTIME 7 +#define CS_POLL 8 +#define CS_PEERID 9 +#define CS_OFFSET 10 +#define CS_DRIFT 11 +#define CS_JITTER 12 +#define CS_ERROR 13 +#define CS_CLOCK 14 +#define CS_PROCESSOR 15 +#define CS_SYSTEM 16 +#define CS_VERSION 17 +#define CS_STABIL 18 +#define CS_VARLIST 19 +#define CS_TAI 20 +#define CS_LEAPTAB 21 +#define CS_LEAPEND 22 +#define CS_RATE 23 +#define CS_MRU_ENABLED 24 +#define CS_MRU_DEPTH 25 +#define CS_MRU_DEEPEST 26 +#define CS_MRU_MINDEPTH 27 +#define CS_MRU_MAXAGE 28 +#define CS_MRU_MAXDEPTH 29 +#define CS_MRU_MEM 30 +#define CS_MRU_MAXMEM 31 +#define CS_SS_UPTIME 32 +#define CS_SS_RESET 33 +#define CS_SS_RECEIVED 34 +#define CS_SS_THISVER 35 +#define CS_SS_OLDVER 36 +#define CS_SS_BADFORMAT 37 +#define CS_SS_BADAUTH 38 +#define CS_SS_DECLINED 39 +#define CS_SS_RESTRICTED 40 +#define CS_SS_LIMITED 41 +#define CS_SS_KODSENT 42 +#define CS_SS_PROCESSED 43 +#define CS_PEERADR 44 +#define CS_PEERMODE 45 +#define CS_BCASTDELAY 46 +#define CS_AUTHDELAY 47 +#define CS_AUTHKEYS 48 +#define CS_AUTHFREEK 49 +#define CS_AUTHKLOOKUPS 50 +#define CS_AUTHKNOTFOUND 51 +#define CS_AUTHKUNCACHED 52 +#define CS_AUTHKEXPIRED 53 +#define CS_AUTHENCRYPTS 54 +#define CS_AUTHDECRYPTS 55 +#define CS_AUTHRESET 56 +#define CS_K_OFFSET 57 +#define CS_K_FREQ 58 +#define CS_K_MAXERR 59 +#define CS_K_ESTERR 60 +#define CS_K_STFLAGS 61 +#define CS_K_TIMECONST 62 +#define CS_K_PRECISION 63 +#define CS_K_FREQTOL 64 +#define CS_K_PPS_FREQ 65 +#define CS_K_PPS_STABIL 66 +#define CS_K_PPS_JITTER 67 +#define CS_K_PPS_CALIBDUR 68 +#define CS_K_PPS_CALIBS 69 +#define CS_K_PPS_CALIBERRS 70 +#define CS_K_PPS_JITEXC 71 +#define CS_K_PPS_STBEXC 72 +#define CS_KERN_FIRST CS_K_OFFSET +#define CS_KERN_LAST CS_K_PPS_STBEXC +#define CS_IOSTATS_RESET 73 +#define CS_TOTAL_RBUF 74 +#define CS_FREE_RBUF 75 +#define CS_USED_RBUF 76 +#define CS_RBUF_LOWATER 77 +#define CS_IO_DROPPED 78 +#define CS_IO_IGNORED 79 +#define CS_IO_RECEIVED 80 +#define CS_IO_SENT 81 +#define CS_IO_SENDFAILED 82 +#define CS_IO_WAKEUPS 83 +#define CS_IO_GOODWAKEUPS 84 +#define CS_TIMERSTATS_RESET 85 +#define CS_TIMER_OVERRUNS 86 +#define CS_TIMER_XMTS 87 +#define CS_FUZZ 88 +#define CS_WANDER_THRESH 89 +#define CS_LEAPSMEARINTV 90 +#define CS_LEAPSMEAROFFS 91 +#define CS_MAX_NOAUTOKEY CS_LEAPSMEAROFFS +#ifdef AUTOKEY +#define CS_FLAGS (1 + CS_MAX_NOAUTOKEY) +#define CS_HOST (2 + CS_MAX_NOAUTOKEY) +#define CS_PUBLIC (3 + CS_MAX_NOAUTOKEY) +#define CS_CERTIF (4 + CS_MAX_NOAUTOKEY) +#define CS_SIGNATURE (5 + CS_MAX_NOAUTOKEY) +#define CS_REVTIME (6 + CS_MAX_NOAUTOKEY) +#define CS_IDENT (7 + CS_MAX_NOAUTOKEY) +#define CS_DIGEST (8 + CS_MAX_NOAUTOKEY) +#define CS_MAXCODE CS_DIGEST +#else /* !AUTOKEY follows */ +#define CS_MAXCODE CS_MAX_NOAUTOKEY +#endif /* !AUTOKEY */ + +/* + * Peer variables we understand + */ +#define CP_CONFIG 1 +#define CP_AUTHENABLE 2 +#define CP_AUTHENTIC 3 +#define CP_SRCADR 4 +#define CP_SRCPORT 5 +#define CP_DSTADR 6 +#define CP_DSTPORT 7 +#define CP_LEAP 8 +#define CP_HMODE 9 +#define CP_STRATUM 10 +#define CP_PPOLL 11 +#define CP_HPOLL 12 +#define CP_PRECISION 13 +#define CP_ROOTDELAY 14 +#define CP_ROOTDISPERSION 15 +#define CP_REFID 16 +#define CP_REFTIME 17 +#define CP_ORG 18 +#define CP_REC 19 +#define CP_XMT 20 +#define CP_REACH 21 +#define CP_UNREACH 22 +#define CP_TIMER 23 +#define CP_DELAY 24 +#define CP_OFFSET 25 +#define CP_JITTER 26 +#define CP_DISPERSION 27 +#define CP_KEYID 28 +#define CP_FILTDELAY 29 +#define CP_FILTOFFSET 30 +#define CP_PMODE 31 +#define CP_RECEIVED 32 +#define CP_SENT 33 +#define CP_FILTERROR 34 +#define CP_FLASH 35 +#define CP_TTL 36 +#define CP_VARLIST 37 +#define CP_IN 38 +#define CP_OUT 39 +#define CP_RATE 40 +#define CP_BIAS 41 +#define CP_SRCHOST 42 +#define CP_TIMEREC 43 +#define CP_TIMEREACH 44 +#define CP_BADAUTH 45 +#define CP_BOGUSORG 46 +#define CP_OLDPKT 47 +#define CP_SELDISP 48 +#define CP_SELBROKEN 49 +#define CP_CANDIDATE 50 +#define CP_MAX_NOAUTOKEY CP_CANDIDATE +#ifdef AUTOKEY +#define CP_FLAGS (1 + CP_MAX_NOAUTOKEY) +#define CP_HOST (2 + CP_MAX_NOAUTOKEY) +#define CP_VALID (3 + CP_MAX_NOAUTOKEY) +#define CP_INITSEQ (4 + CP_MAX_NOAUTOKEY) +#define CP_INITKEY (5 + CP_MAX_NOAUTOKEY) +#define CP_INITTSP (6 + CP_MAX_NOAUTOKEY) +#define CP_SIGNATURE (7 + CP_MAX_NOAUTOKEY) +#define CP_IDENT (8 + CP_MAX_NOAUTOKEY) +#define CP_MAXCODE CP_IDENT +#else /* !AUTOKEY follows */ +#define CP_MAXCODE CP_MAX_NOAUTOKEY +#endif /* !AUTOKEY */ + +/* + * Clock variables we understand + */ +#define CC_TYPE 1 +#define CC_TIMECODE 2 +#define CC_POLL 3 +#define CC_NOREPLY 4 +#define CC_BADFORMAT 5 +#define CC_BADDATA 6 +#define CC_FUDGETIME1 7 +#define CC_FUDGETIME2 8 +#define CC_FUDGEVAL1 9 +#define CC_FUDGEVAL2 10 +#define CC_FLAGS 11 +#define CC_DEVICE 12 +#define CC_VARLIST 13 +#define CC_MAXCODE CC_VARLIST + /* * System variable values. The array can be indexed by the variable * index to find the textual name. */ -static struct ctl_var sys_var[] = { +static const struct ctl_var sys_var[] = { { 0, PADDING, "" }, /* 0 */ { CS_LEAP, RW, "leap" }, /* 1 */ { CS_STRATUM, RO, "stratum" }, /* 2 */ { CS_PRECISION, RO, "precision" }, /* 3 */ { CS_ROOTDELAY, RO, "rootdelay" }, /* 4 */ - { CS_ROOTDISPERSION, RO, "rootdispersion" }, /* 5 */ + { CS_ROOTDISPERSION, RO, "rootdisp" }, /* 5 */ { CS_REFID, RO, "refid" }, /* 6 */ { CS_REFTIME, RO, "reftime" }, /* 7 */ - { CS_POLL, RO, "poll" }, /* 8 */ + { CS_POLL, RO, "tc" }, /* 8 */ { CS_PEERID, RO, "peer" }, /* 9 */ - { CS_STATE, RO, "state" }, /* 10 */ - { CS_OFFSET, RO, "offset" }, /* 11 */ - { CS_DRIFT, RO, "frequency" }, /* 12 */ - { CS_JITTER, RO, "jitter" }, /* 13 */ - { CS_ERROR, RO, "noise" }, /* 14 */ - { CS_CLOCK, RO, "clock" }, /* 15 */ - { CS_PROCESSOR, RO, "processor" }, /* 16 */ - { CS_SYSTEM, RO, "system" }, /* 17 */ - { CS_VERSION, RO, "version" }, /* 18 */ - { CS_STABIL, RO, "stability" }, /* 19 */ - { CS_VARLIST, RO, "sys_var_list" }, /* 20 */ -#ifdef OPENSSL - { CS_FLAGS, RO, "flags" }, /* 21 */ - { CS_HOST, RO, "hostname" }, /* 22 */ - { CS_PUBLIC, RO, "update" }, /* 23 */ - { CS_CERTIF, RO, "cert" }, /* 24 */ - { CS_REVTIME, RO, "expire" }, /* 25 */ - { CS_LEAPTAB, RO, "leapsec" }, /* 26 */ - { CS_TAI, RO, "tai" }, /* 27 */ - { CS_DIGEST, RO, "signature" }, /* 28 */ - { CS_IDENT, RO, "ident" }, /* 29 */ - { CS_REVOKE, RO, "expire" }, /* 30 */ -#endif /* OPENSSL */ - { 0, EOV, "" } /* 21/31 */ + { CS_OFFSET, RO, "offset" }, /* 10 */ + { CS_DRIFT, RO, "frequency" }, /* 11 */ + { CS_JITTER, RO, "sys_jitter" }, /* 12 */ + { CS_ERROR, RO, "clk_jitter" }, /* 13 */ + { CS_CLOCK, RO, "clock" }, /* 14 */ + { CS_PROCESSOR, RO, "processor" }, /* 15 */ + { CS_SYSTEM, RO, "system" }, /* 16 */ + { CS_VERSION, RO, "version" }, /* 17 */ + { CS_STABIL, RO, "clk_wander" }, /* 18 */ + { CS_VARLIST, RO, "sys_var_list" }, /* 19 */ + { CS_TAI, RO, "tai" }, /* 20 */ + { CS_LEAPTAB, RO, "leapsec" }, /* 21 */ + { CS_LEAPEND, RO, "expire" }, /* 22 */ + { CS_RATE, RO, "mintc" }, /* 23 */ + { CS_MRU_ENABLED, RO, "mru_enabled" }, /* 24 */ + { CS_MRU_DEPTH, RO, "mru_depth" }, /* 25 */ + { CS_MRU_DEEPEST, RO, "mru_deepest" }, /* 26 */ + { CS_MRU_MINDEPTH, RO, "mru_mindepth" }, /* 27 */ + { CS_MRU_MAXAGE, RO, "mru_maxage" }, /* 28 */ + { CS_MRU_MAXDEPTH, RO, "mru_maxdepth" }, /* 29 */ + { CS_MRU_MEM, RO, "mru_mem" }, /* 30 */ + { CS_MRU_MAXMEM, RO, "mru_maxmem" }, /* 31 */ + { CS_SS_UPTIME, RO, "ss_uptime" }, /* 32 */ + { CS_SS_RESET, RO, "ss_reset" }, /* 33 */ + { CS_SS_RECEIVED, RO, "ss_received" }, /* 34 */ + { CS_SS_THISVER, RO, "ss_thisver" }, /* 35 */ + { CS_SS_OLDVER, RO, "ss_oldver" }, /* 36 */ + { CS_SS_BADFORMAT, RO, "ss_badformat" }, /* 37 */ + { CS_SS_BADAUTH, RO, "ss_badauth" }, /* 38 */ + { CS_SS_DECLINED, RO, "ss_declined" }, /* 39 */ + { CS_SS_RESTRICTED, RO, "ss_restricted" }, /* 40 */ + { CS_SS_LIMITED, RO, "ss_limited" }, /* 41 */ + { CS_SS_KODSENT, RO, "ss_kodsent" }, /* 42 */ + { CS_SS_PROCESSED, RO, "ss_processed" }, /* 43 */ + { CS_PEERADR, RO, "peeradr" }, /* 44 */ + { CS_PEERMODE, RO, "peermode" }, /* 45 */ + { CS_BCASTDELAY, RO, "bcastdelay" }, /* 46 */ + { CS_AUTHDELAY, RO, "authdelay" }, /* 47 */ + { CS_AUTHKEYS, RO, "authkeys" }, /* 48 */ + { CS_AUTHFREEK, RO, "authfreek" }, /* 49 */ + { CS_AUTHKLOOKUPS, RO, "authklookups" }, /* 50 */ + { CS_AUTHKNOTFOUND, RO, "authknotfound" }, /* 51 */ + { CS_AUTHKUNCACHED, RO, "authkuncached" }, /* 52 */ + { CS_AUTHKEXPIRED, RO, "authkexpired" }, /* 53 */ + { CS_AUTHENCRYPTS, RO, "authencrypts" }, /* 54 */ + { CS_AUTHDECRYPTS, RO, "authdecrypts" }, /* 55 */ + { CS_AUTHRESET, RO, "authreset" }, /* 56 */ + { CS_K_OFFSET, RO, "koffset" }, /* 57 */ + { CS_K_FREQ, RO, "kfreq" }, /* 58 */ + { CS_K_MAXERR, RO, "kmaxerr" }, /* 59 */ + { CS_K_ESTERR, RO, "kesterr" }, /* 60 */ + { CS_K_STFLAGS, RO, "kstflags" }, /* 61 */ + { CS_K_TIMECONST, RO, "ktimeconst" }, /* 62 */ + { CS_K_PRECISION, RO, "kprecis" }, /* 63 */ + { CS_K_FREQTOL, RO, "kfreqtol" }, /* 64 */ + { CS_K_PPS_FREQ, RO, "kppsfreq" }, /* 65 */ + { CS_K_PPS_STABIL, RO, "kppsstab" }, /* 66 */ + { CS_K_PPS_JITTER, RO, "kppsjitter" }, /* 67 */ + { CS_K_PPS_CALIBDUR, RO, "kppscalibdur" }, /* 68 */ + { CS_K_PPS_CALIBS, RO, "kppscalibs" }, /* 69 */ + { CS_K_PPS_CALIBERRS, RO, "kppscaliberrs" }, /* 70 */ + { CS_K_PPS_JITEXC, RO, "kppsjitexc" }, /* 71 */ + { CS_K_PPS_STBEXC, RO, "kppsstbexc" }, /* 72 */ + { CS_IOSTATS_RESET, RO, "iostats_reset" }, /* 73 */ + { CS_TOTAL_RBUF, RO, "total_rbuf" }, /* 74 */ + { CS_FREE_RBUF, RO, "free_rbuf" }, /* 75 */ + { CS_USED_RBUF, RO, "used_rbuf" }, /* 76 */ + { CS_RBUF_LOWATER, RO, "rbuf_lowater" }, /* 77 */ + { CS_IO_DROPPED, RO, "io_dropped" }, /* 78 */ + { CS_IO_IGNORED, RO, "io_ignored" }, /* 79 */ + { CS_IO_RECEIVED, RO, "io_received" }, /* 80 */ + { CS_IO_SENT, RO, "io_sent" }, /* 81 */ + { CS_IO_SENDFAILED, RO, "io_sendfailed" }, /* 82 */ + { CS_IO_WAKEUPS, RO, "io_wakeups" }, /* 83 */ + { CS_IO_GOODWAKEUPS, RO, "io_goodwakeups" }, /* 84 */ + { CS_TIMERSTATS_RESET, RO, "timerstats_reset" },/* 85 */ + { CS_TIMER_OVERRUNS, RO, "timer_overruns" }, /* 86 */ + { CS_TIMER_XMTS, RO, "timer_xmts" }, /* 87 */ + { CS_FUZZ, RO, "fuzz" }, /* 88 */ + { CS_WANDER_THRESH, RO, "clk_wander_threshold" }, /* 89 */ + + { CS_LEAPSMEARINTV, RO, "leapsmearinterval" }, /* 90 */ + { CS_LEAPSMEAROFFS, RO, "leapsmearoffset" }, /* 91 */ + +#ifdef AUTOKEY + { CS_FLAGS, RO, "flags" }, /* 1 + CS_MAX_NOAUTOKEY */ + { CS_HOST, RO, "host" }, /* 2 + CS_MAX_NOAUTOKEY */ + { CS_PUBLIC, RO, "update" }, /* 3 + CS_MAX_NOAUTOKEY */ + { CS_CERTIF, RO, "cert" }, /* 4 + CS_MAX_NOAUTOKEY */ + { CS_SIGNATURE, RO, "signature" }, /* 5 + CS_MAX_NOAUTOKEY */ + { CS_REVTIME, RO, "until" }, /* 6 + CS_MAX_NOAUTOKEY */ + { CS_IDENT, RO, "ident" }, /* 7 + CS_MAX_NOAUTOKEY */ + { CS_DIGEST, RO, "digest" }, /* 8 + CS_MAX_NOAUTOKEY */ +#endif /* AUTOKEY */ + { 0, EOV, "" } /* 87/95 */ }; -static struct ctl_var *ext_sys_var = (struct ctl_var *)0; +static struct ctl_var *ext_sys_var = NULL; /* * System variables we print by default (in fuzzball order, * more-or-less) */ -static u_char def_sys_var[] = { +static const u_char def_sys_var[] = { CS_VERSION, CS_PROCESSOR, CS_SYSTEM, @@ -156,27 +452,31 @@ static u_char def_sys_var[] = { CS_PRECISION, CS_ROOTDELAY, CS_ROOTDISPERSION, - CS_PEERID, CS_REFID, CS_REFTIME, - CS_POLL, CS_CLOCK, - CS_STATE, + CS_PEERID, + CS_POLL, + CS_RATE, CS_OFFSET, CS_DRIFT, CS_JITTER, CS_ERROR, CS_STABIL, -#ifdef OPENSSL + CS_TAI, + CS_LEAPTAB, + CS_LEAPEND, + CS_LEAPSMEARINTV, + CS_LEAPSMEAROFFS, +#ifdef AUTOKEY CS_HOST, - CS_DIGEST, + CS_IDENT, CS_FLAGS, + CS_DIGEST, + CS_SIGNATURE, CS_PUBLIC, - CS_IDENT, - CS_LEAPTAB, - CS_TAI, CS_CERTIF, -#endif /* OPENSSL */ +#endif /* AUTOKEY */ 0 }; @@ -184,11 +484,11 @@ static u_char def_sys_var[] = { /* * Peer variable list */ -static struct ctl_var peer_var[] = { +static const struct ctl_var peer_var[] = { { 0, PADDING, "" }, /* 0 */ { CP_CONFIG, RO, "config" }, /* 1 */ { CP_AUTHENABLE, RO, "authenable" }, /* 2 */ - { CP_AUTHENTIC, RO, "authentic" }, /* 3 */ + { CP_AUTHENTIC, RO, "authentic" }, /* 3 */ { CP_SRCADR, RO, "srcadr" }, /* 4 */ { CP_SRCPORT, RO, "srcport" }, /* 5 */ { CP_DSTADR, RO, "dstadr" }, /* 6 */ @@ -200,12 +500,12 @@ static struct ctl_var peer_var[] = { { CP_HPOLL, RO, "hpoll" }, /* 12 */ { CP_PRECISION, RO, "precision" }, /* 13 */ { CP_ROOTDELAY, RO, "rootdelay" }, /* 14 */ - { CP_ROOTDISPERSION, RO, "rootdispersion" }, /* 15 */ + { CP_ROOTDISPERSION, RO, "rootdisp" }, /* 15 */ { CP_REFID, RO, "refid" }, /* 16 */ { CP_REFTIME, RO, "reftime" }, /* 17 */ { CP_ORG, RO, "org" }, /* 18 */ { CP_REC, RO, "rec" }, /* 19 */ - { CP_XMT, RO, "xmt" }, /* 20 */ + { CP_XMT, RO, "xleave" }, /* 20 */ { CP_REACH, RO, "reach" }, /* 21 */ { CP_UNREACH, RO, "unreach" }, /* 22 */ { CP_TIMER, RO, "timer" }, /* 23 */ @@ -214,49 +514,68 @@ static struct ctl_var peer_var[] = { { CP_JITTER, RO, "jitter" }, /* 26 */ { CP_DISPERSION, RO, "dispersion" }, /* 27 */ { CP_KEYID, RO, "keyid" }, /* 28 */ - { CP_FILTDELAY, RO, "filtdelay=" }, /* 29 */ - { CP_FILTOFFSET, RO, "filtoffset=" }, /* 30 */ + { CP_FILTDELAY, RO, "filtdelay" }, /* 29 */ + { CP_FILTOFFSET, RO, "filtoffset" }, /* 30 */ { CP_PMODE, RO, "pmode" }, /* 31 */ { CP_RECEIVED, RO, "received"}, /* 32 */ { CP_SENT, RO, "sent" }, /* 33 */ - { CP_FILTERROR, RO, "filtdisp=" }, /* 34 */ + { CP_FILTERROR, RO, "filtdisp" }, /* 34 */ { CP_FLASH, RO, "flash" }, /* 35 */ { CP_TTL, RO, "ttl" }, /* 36 */ { CP_VARLIST, RO, "peer_var_list" }, /* 37 */ -#ifdef OPENSSL - { CP_FLAGS, RO, "flags" }, /* 38 */ - { CP_HOST, RO, "hostname" }, /* 39 */ - { CP_VALID, RO, "valid" }, /* 40 */ - { CP_INITSEQ, RO, "initsequence" }, /* 41 */ - { CP_INITKEY, RO, "initkey" }, /* 42 */ - { CP_INITTSP, RO, "timestamp" }, /* 43 */ - { CP_DIGEST, RO, "signature" }, /* 44 */ - { CP_IDENT, RO, "trust" }, /* 45 */ -#endif /* OPENSSL */ - { 0, EOV, "" } /* 38/46 */ + { CP_IN, RO, "in" }, /* 38 */ + { CP_OUT, RO, "out" }, /* 39 */ + { CP_RATE, RO, "headway" }, /* 40 */ + { CP_BIAS, RO, "bias" }, /* 41 */ + { CP_SRCHOST, RO, "srchost" }, /* 42 */ + { CP_TIMEREC, RO, "timerec" }, /* 43 */ + { CP_TIMEREACH, RO, "timereach" }, /* 44 */ + { CP_BADAUTH, RO, "badauth" }, /* 45 */ + { CP_BOGUSORG, RO, "bogusorg" }, /* 46 */ + { CP_OLDPKT, RO, "oldpkt" }, /* 47 */ + { CP_SELDISP, RO, "seldisp" }, /* 48 */ + { CP_SELBROKEN, RO, "selbroken" }, /* 49 */ + { CP_CANDIDATE, RO, "candidate" }, /* 50 */ +#ifdef AUTOKEY + { CP_FLAGS, RO, "flags" }, /* 1 + CP_MAX_NOAUTOKEY */ + { CP_HOST, RO, "host" }, /* 2 + CP_MAX_NOAUTOKEY */ + { CP_VALID, RO, "valid" }, /* 3 + CP_MAX_NOAUTOKEY */ + { CP_INITSEQ, RO, "initsequence" }, /* 4 + CP_MAX_NOAUTOKEY */ + { CP_INITKEY, RO, "initkey" }, /* 5 + CP_MAX_NOAUTOKEY */ + { CP_INITTSP, RO, "timestamp" }, /* 6 + CP_MAX_NOAUTOKEY */ + { CP_SIGNATURE, RO, "signature" }, /* 7 + CP_MAX_NOAUTOKEY */ + { CP_IDENT, RO, "ident" }, /* 8 + CP_MAX_NOAUTOKEY */ +#endif /* AUTOKEY */ + { 0, EOV, "" } /* 50/58 */ }; /* * Peer variables we print by default */ -static u_char def_peer_var[] = { +static const u_char def_peer_var[] = { CP_SRCADR, CP_SRCPORT, + CP_SRCHOST, CP_DSTADR, CP_DSTPORT, + CP_OUT, + CP_IN, CP_LEAP, CP_STRATUM, CP_PRECISION, CP_ROOTDELAY, CP_ROOTDISPERSION, CP_REFID, + CP_REFTIME, + CP_REC, CP_REACH, CP_UNREACH, CP_HMODE, CP_PMODE, CP_HPOLL, CP_PPOLL, + CP_RATE, CP_FLASH, CP_KEYID, CP_TTL, @@ -264,21 +583,19 @@ static u_char def_peer_var[] = { CP_DELAY, CP_DISPERSION, CP_JITTER, - CP_REFTIME, - CP_ORG, - CP_REC, CP_XMT, + CP_BIAS, CP_FILTDELAY, CP_FILTOFFSET, CP_FILTERROR, -#ifdef OPENSSL +#ifdef AUTOKEY CP_HOST, - CP_DIGEST, - CP_VALID, CP_FLAGS, - CP_IDENT, + CP_SIGNATURE, + CP_VALID, CP_INITSEQ, -#endif /* OPENSSL */ + CP_IDENT, +#endif /* AUTOKEY */ 0 }; @@ -287,7 +604,7 @@ static u_char def_peer_var[] = { /* * Clock variable list */ -static struct ctl_var clock_var[] = { +static const struct ctl_var clock_var[] = { { 0, PADDING, "" }, /* 0 */ { CC_TYPE, RO, "type" }, /* 1 */ { CC_TIMECODE, RO, "timecode" }, /* 2 */ @@ -309,7 +626,7 @@ static struct ctl_var clock_var[] = { /* * Clock variables printed by default */ -static u_char def_clock_var[] = { +static const u_char def_clock_var[] = { CC_DEVICE, CC_TYPE, /* won't be output if device = known */ CC_TIMECODE, @@ -326,6 +643,11 @@ static u_char def_clock_var[] = { }; #endif +/* + * MRU string constants shared by send_mru_entry() and read_mru_list(). + */ +static const char addr_fmt[] = "addr.%d"; +static const char last_fmt[] = "last.%d"; /* * System and processor definitions. @@ -335,11 +657,11 @@ static u_char def_clock_var[] = { # define STR_SYSTEM "UNIX" # endif # ifndef STR_PROCESSOR -# define STR_PROCESSOR "unknown" +# define STR_PROCESSOR "unknown" # endif -static char str_system[] = STR_SYSTEM; -static char str_processor[] = STR_PROCESSOR; +static const char str_system[] = STR_SYSTEM; +static const char str_processor[] = STR_PROCESSOR; #else # include static struct utsname utsnamebuf; @@ -352,7 +674,7 @@ static struct utsname utsnamebuf; * timed out. */ /* ntp_request.c */ -struct ctl_trap ctl_trap[CTL_MAXTRAPS]; +struct ctl_trap ctl_traps[CTL_MAXTRAPS]; int num_ctl_traps; /* @@ -369,53 +691,57 @@ int num_ctl_traps; * the reference clock driver doesn't set peer->sstclktype to something * different than CTL_SST_TS_UNSPEC. */ -static u_char clocktypes[] = { - CTL_SST_TS_NTP, /* REFCLK_NONE (0) */ +#ifdef REFCLOCK +static const u_char clocktypes[] = { + CTL_SST_TS_NTP, /* REFCLK_NONE (0) */ CTL_SST_TS_LOCAL, /* REFCLK_LOCALCLOCK (1) */ - CTL_SST_TS_UHF, /* deprecated REFCLK_GPS_TRAK (2) */ + CTL_SST_TS_UHF, /* deprecated REFCLK_GPS_TRAK (2) */ CTL_SST_TS_HF, /* REFCLK_WWV_PST (3) */ CTL_SST_TS_LF, /* REFCLK_WWVB_SPECTRACOM (4) */ - CTL_SST_TS_UHF, /* REFCLK_TRUETIME (5) */ - CTL_SST_TS_UHF, /* REFCLK_GOES_TRAK (6) IRIG_AUDIO? */ + CTL_SST_TS_UHF, /* REFCLK_TRUETIME (5) */ + CTL_SST_TS_UHF, /* REFCLK_IRIG_AUDIO (6) */ CTL_SST_TS_HF, /* REFCLK_CHU (7) */ CTL_SST_TS_LF, /* REFCLOCK_PARSE (default) (8) */ CTL_SST_TS_LF, /* REFCLK_GPS_MX4200 (9) */ - CTL_SST_TS_UHF, /* REFCLK_GPS_AS2201 (10) */ - CTL_SST_TS_UHF, /* REFCLK_GPS_ARBITER (11) */ - CTL_SST_TS_UHF, /* REFCLK_IRIG_TPRO (12) */ + CTL_SST_TS_UHF, /* REFCLK_GPS_AS2201 (10) */ + CTL_SST_TS_UHF, /* REFCLK_GPS_ARBITER (11) */ + CTL_SST_TS_UHF, /* REFCLK_IRIG_TPRO (12) */ CTL_SST_TS_ATOM, /* REFCLK_ATOM_LEITCH (13) */ CTL_SST_TS_LF, /* deprecated REFCLK_MSF_EES (14) */ - CTL_SST_TS_NTP, /* not used (15) */ - CTL_SST_TS_UHF, /* REFCLK_IRIG_BANCOMM (16) */ - CTL_SST_TS_UHF, /* REFCLK_GPS_DATU (17) */ + CTL_SST_TS_NTP, /* not used (15) */ + CTL_SST_TS_UHF, /* REFCLK_IRIG_BANCOMM (16) */ + CTL_SST_TS_UHF, /* REFCLK_GPS_DATU (17) */ CTL_SST_TS_TELEPHONE, /* REFCLK_NIST_ACTS (18) */ CTL_SST_TS_HF, /* REFCLK_WWV_HEATH (19) */ - CTL_SST_TS_UHF, /* REFCLK_GPS_NMEA (20) */ - CTL_SST_TS_UHF, /* REFCLK_GPS_VME (21) */ + CTL_SST_TS_UHF, /* REFCLK_GPS_NMEA (20) */ + CTL_SST_TS_UHF, /* REFCLK_GPS_VME (21) */ CTL_SST_TS_ATOM, /* REFCLK_ATOM_PPS (22) */ CTL_SST_TS_NTP, /* not used (23) */ CTL_SST_TS_NTP, /* not used (24) */ - CTL_SST_TS_NTP, /* not used (25) */ - CTL_SST_TS_UHF, /* REFCLK_GPS_HP (26) */ - CTL_SST_TS_TELEPHONE, /* REFCLK_ARCRON_MSF (27) */ - CTL_SST_TS_TELEPHONE, /* REFCLK_SHM (28) */ - CTL_SST_TS_UHF, /* REFCLK_PALISADE (29) */ - CTL_SST_TS_UHF, /* REFCLK_ONCORE (30) */ + CTL_SST_TS_NTP, /* not used (25) */ + CTL_SST_TS_UHF, /* REFCLK_GPS_HP (26) */ + CTL_SST_TS_LF, /* REFCLK_ARCRON_MSF (27) */ + CTL_SST_TS_UHF, /* REFCLK_SHM (28) */ + CTL_SST_TS_UHF, /* REFCLK_PALISADE (29) */ + CTL_SST_TS_UHF, /* REFCLK_ONCORE (30) */ CTL_SST_TS_UHF, /* REFCLK_JUPITER (31) */ CTL_SST_TS_LF, /* REFCLK_CHRONOLOG (32) */ CTL_SST_TS_LF, /* REFCLK_DUMBCLOCK (33) */ CTL_SST_TS_LF, /* REFCLK_ULINK (34) */ CTL_SST_TS_LF, /* REFCLK_PCF (35) */ - CTL_SST_TS_LF, /* REFCLK_WWV (36) */ + CTL_SST_TS_HF, /* REFCLK_WWV (36) */ CTL_SST_TS_LF, /* REFCLK_FG (37) */ - CTL_SST_TS_UHF, /* REFCLK_HOPF_SERIAL (38) */ + CTL_SST_TS_UHF, /* REFCLK_HOPF_SERIAL (38) */ CTL_SST_TS_UHF, /* REFCLK_HOPF_PCI (39) */ CTL_SST_TS_LF, /* REFCLK_JJY (40) */ CTL_SST_TS_UHF, /* REFCLK_TT560 (41) */ CTL_SST_TS_UHF, /* REFCLK_ZYFER (42) */ CTL_SST_TS_UHF, /* REFCLK_RIPENCC (43) */ CTL_SST_TS_UHF, /* REFCLK_NEOCLOCK4X (44) */ + CTL_SST_TS_UHF, /* REFCLK_TSYNCPCI (45) */ + CTL_SST_TS_UHF /* REFCLK_GPSDJSON (46) */ }; +#endif /* REFCLOCK */ /* @@ -436,17 +762,17 @@ static u_char ctl_sys_num_events; u_long ctltimereset; /* time stats reset */ u_long numctlreq; /* number of requests we've received */ u_long numctlbadpkts; /* number of bad control packets */ -u_long numctlresponses; /* number of resp packets sent with data */ -u_long numctlfrags; /* number of fragments sent */ +u_long numctlresponses; /* number of resp packets sent with data */ +u_long numctlfrags; /* number of fragments sent */ u_long numctlerrors; /* number of error responses sent */ u_long numctltooshort; /* number of too short input packets */ -u_long numctlinputresp; /* number of responses on input */ -u_long numctlinputfrag; /* number of fragments on input */ +u_long numctlinputresp; /* number of responses on input */ +u_long numctlinputfrag; /* number of fragments on input */ u_long numctlinputerr; /* number of input pkts with err bit set */ -u_long numctlbadoffset; /* number of input pkts with nonzero offset */ +u_long numctlbadoffset; /* number of input pkts with nonzero offset */ u_long numctlbadversion; /* number of input pkts with unknown version */ u_long numctldatatooshort; /* data too short for count */ -u_long numctlbadop; /* bad op code found in packet */ +u_long numctlbadop; /* bad op code found in packet */ u_long numasyncmsgs; /* number of async messages we've sent */ /* @@ -460,12 +786,14 @@ static struct ntp_control rpkt; static u_char res_version; static u_char res_opcode; static associd_t res_associd; -static int res_offset; +static u_short res_frags; /* datagrams in this response */ +static int res_offset; /* offset of payload in response */ static u_char * datapt; static u_char * dataend; static int datalinelen; +static int datasent; /* flag to avoid initial ", " */ static int datanotbinflag; -static struct sockaddr_storage *rmt_addr; +static sockaddr_u *rmt_addr; static struct interface *lcl_inter; static u_char res_authenticate; @@ -474,7 +802,7 @@ static keyid_t res_keyid; #define MAXDATALINELEN (72) -static u_char res_async; /* set to 1 if this is async trap response */ +static u_char res_async; /* sending async trap response? */ /* * Pointers for saving state when decoding request packets @@ -482,13 +810,17 @@ static u_char res_async; /* set to 1 if this is async trap response */ static char *reqpt; static char *reqend; +#ifndef MIN +#define MIN(a, b) (((a) <= (b)) ? (a) : (b)) +#endif + /* * init_control - initialize request data */ void init_control(void) { - int i; + size_t i; #ifdef HAVE_UNAME uname(&utsnamebuf); @@ -501,8 +833,8 @@ init_control(void) ctl_sys_num_events = 0; num_ctl_traps = 0; - for (i = 0; i < CTL_MAXTRAPS; i++) - ctl_trap[i].tr_flags = 0; + for (i = 0; i < COUNTOF(ctl_traps); i++) + ctl_traps[i].tr_flags = 0; } @@ -511,39 +843,178 @@ init_control(void) */ static void ctl_error( - int errcode + u_char errcode ) { -#ifdef DEBUG - if (debug >= 4) - printf("sending control error %d\n", errcode); -#endif + int maclen; + + numctlerrors++; + DPRINTF(3, ("sending control error %u\n", errcode)); + /* * Fill in the fields. We assume rpkt.sequence and rpkt.associd * have already been filled in. */ - rpkt.r_m_e_op = (u_char) (CTL_RESPONSE|CTL_ERROR|(res_opcode & - CTL_OP_MASK)); - rpkt.status = htons((u_short) ((errcode<<8) & 0xff00)); + rpkt.r_m_e_op = (u_char)CTL_RESPONSE | CTL_ERROR | + (res_opcode & CTL_OP_MASK); + rpkt.status = htons((u_short)(errcode << 8) & 0xff00); rpkt.count = 0; /* * send packet and bump counters */ if (res_authenticate && sys_authenticate) { - int maclen; - - *(u_int32 *)((u_char *)&rpkt + CTL_HEADER_LEN) = - htonl(res_keyid); maclen = authencrypt(res_keyid, (u_int32 *)&rpkt, - CTL_HEADER_LEN); - sendpkt(rmt_addr, lcl_inter, -2, (struct pkt *)&rpkt, - CTL_HEADER_LEN + maclen); + CTL_HEADER_LEN); + sendpkt(rmt_addr, lcl_inter, -2, (void *)&rpkt, + CTL_HEADER_LEN + maclen); + } else + sendpkt(rmt_addr, lcl_inter, -3, (void *)&rpkt, + CTL_HEADER_LEN); +} + +/* + * save_config - Implements ntpq -c "saveconfig " + * Writes current configuration including any runtime + * changes by ntpq's :config or config-from-file + */ +void +save_config( + struct recvbuf *rbufp, + int restrict_mask + ) +{ + /* block directory traversal by searching for characters that + * indicate directory components in a file path. + * + * Conceptually we should be searching for DIRSEP in filename, + * however Windows actually recognizes both forward and + * backslashes as equivalent directory separators at the API + * level. On POSIX systems we could allow '\\' but such + * filenames are tricky to manipulate from a shell, so just + * reject both types of slashes on all platforms. + */ + /* TALOS-CAN-0062: block directory traversal for VMS, too */ + static const char * illegal_in_filename = +#if defined(VMS) + ":[]" /* do not allow drive and path components here */ +#elif defined(SYS_WINNT) + ":\\/" /* path and drive separators */ +#else + "\\/" /* separator and critical char for POSIX */ +#endif + ; + + + char reply[128]; +#ifdef SAVECONFIG + char filespec[128]; + char filename[128]; + char fullpath[512]; + const char savedconfig_eq[] = "savedconfig="; + char savedconfig[sizeof(savedconfig_eq) + sizeof(filename)]; + time_t now; + int fd; + FILE *fptr; +#endif + + if (RES_NOMODIFY & restrict_mask) { + snprintf(reply, sizeof(reply), + "saveconfig prohibited by restrict ... nomodify"); + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); + NLOG(NLOG_SYSINFO) + msyslog(LOG_NOTICE, + "saveconfig from %s rejected due to nomodify restriction", + stoa(&rbufp->recv_srcadr)); + sys_restricted++; + return; + } + +#ifdef SAVECONFIG + if (NULL == saveconfigdir) { + snprintf(reply, sizeof(reply), + "saveconfig prohibited, no saveconfigdir configured"); + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); + NLOG(NLOG_SYSINFO) + msyslog(LOG_NOTICE, + "saveconfig from %s rejected, no saveconfigdir", + stoa(&rbufp->recv_srcadr)); + return; + } + + if (0 == reqend - reqpt) + return; + + strlcpy(filespec, reqpt, sizeof(filespec)); + time(&now); + + /* + * allow timestamping of the saved config filename with + * strftime() format such as: + * ntpq -c "saveconfig ntp-%Y%m%d-%H%M%S.conf" + * XXX: Nice feature, but not too safe. + */ + if (0 == strftime(filename, sizeof(filename), filespec, + localtime(&now))) + strlcpy(filename, filespec, sizeof(filename)); + + /* block directory/drive traversal */ + /* TALOS-CAN-0062: block directory traversal for VMS, too */ + if (NULL != strpbrk(filename, illegal_in_filename)) { + snprintf(reply, sizeof(reply), + "saveconfig does not allow directory in filename"); + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); + msyslog(LOG_NOTICE, + "saveconfig with path from %s rejected", + stoa(&rbufp->recv_srcadr)); + return; + } + + snprintf(fullpath, sizeof(fullpath), "%s%s", + saveconfigdir, filename); + + fd = open(fullpath, O_CREAT | O_TRUNC | O_WRONLY, + S_IRUSR | S_IWUSR); + if (-1 == fd) + fptr = NULL; + else + fptr = fdopen(fd, "w"); + + if (NULL == fptr || -1 == dump_all_config_trees(fptr, 1)) { + snprintf(reply, sizeof(reply), + "Unable to save configuration to file %s", + filename); + msyslog(LOG_ERR, + "saveconfig %s from %s failed", filename, + stoa(&rbufp->recv_srcadr)); } else { - sendpkt(rmt_addr, lcl_inter, -3, (struct pkt *)&rpkt, - CTL_HEADER_LEN); + snprintf(reply, sizeof(reply), + "Configuration saved to %s", filename); + msyslog(LOG_NOTICE, + "Configuration saved to %s (requested by %s)", + fullpath, stoa(&rbufp->recv_srcadr)); + /* + * save the output filename in system variable + * savedconfig, retrieved with: + * ntpq -c "rv 0 savedconfig" + */ + snprintf(savedconfig, sizeof(savedconfig), "%s%s", + savedconfig_eq, filename); + set_sys_var(savedconfig, strlen(savedconfig) + 1, RO); } - numctlerrors++; + + if (NULL != fptr) + fclose(fptr); +#else /* !SAVECONFIG follows */ + snprintf(reply, sizeof(reply), + "saveconfig unavailable, configured with --disable-saveconfig"); +#endif + + ctl_putdata(reply, strlen(reply), 0); + ctl_flushpkt(0); } @@ -556,17 +1027,15 @@ process_control( int restrict_mask ) { - register struct ntp_control *pkt; - register int req_count; - register int req_data; - register struct ctl_proc *cc; + struct ntp_control *pkt; + int req_count; + int req_data; + const struct ctl_proc *cc; + keyid_t *pkid; int properlen; - int maclen; + size_t maclen; -#ifdef DEBUG - if (debug > 2) - printf("in process_control()\n"); -#endif + DPRINTF(3, ("in process_control()\n")); /* * Save the addresses for error responses @@ -580,20 +1049,17 @@ process_control( * If the length is less than required for the header, or * it is a response or a fragment, ignore this. */ - if (rbufp->recv_length < CTL_HEADER_LEN - || pkt->r_m_e_op & (CTL_RESPONSE|CTL_MORE|CTL_ERROR) + if (rbufp->recv_length < (int)CTL_HEADER_LEN + || (CTL_RESPONSE | CTL_MORE | CTL_ERROR) & pkt->r_m_e_op || pkt->offset != 0) { -#ifdef DEBUG - if (debug) - printf("invalid format in control packet\n"); -#endif - if (rbufp->recv_length < CTL_HEADER_LEN) + DPRINTF(1, ("invalid format in control packet\n")); + if (rbufp->recv_length < (int)CTL_HEADER_LEN) numctltooshort++; - if (pkt->r_m_e_op & CTL_RESPONSE) + if (CTL_RESPONSE & pkt->r_m_e_op) numctlinputresp++; - if (pkt->r_m_e_op & CTL_MORE) + if (CTL_MORE & pkt->r_m_e_op) numctlinputfrag++; - if (pkt->r_m_e_op & CTL_ERROR) + if (CTL_ERROR & pkt->r_m_e_op) numctlinputerr++; if (pkt->offset != 0) numctlbadoffset++; @@ -601,11 +1067,8 @@ process_control( } res_version = PKT_VERSION(pkt->li_vn_mode); if (res_version > NTP_VERSION || res_version < NTP_OLDVERSION) { -#ifdef DEBUG - if (debug) - printf("unknown version %d in control packet\n", - res_version); -#endif + DPRINTF(1, ("unknown version %d in control packet\n", + res_version)); numctlbadversion++; return; } @@ -615,22 +1078,28 @@ process_control( * responses */ rpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, res_version, - MODE_CONTROL); + MODE_CONTROL); res_opcode = pkt->r_m_e_op; rpkt.sequence = pkt->sequence; rpkt.associd = pkt->associd; rpkt.status = 0; + res_frags = 1; res_offset = 0; res_associd = htons(pkt->associd); - res_async = 0; - res_authenticate = 0; + res_async = FALSE; + res_authenticate = FALSE; res_keyid = 0; - res_authokay = 0; - req_count = (int)htons(pkt->count); - datanotbinflag = 0; + res_authokay = FALSE; + req_count = (int)ntohs(pkt->count); + datanotbinflag = FALSE; datalinelen = 0; - datapt = rpkt.data; - dataend = &(rpkt.data[CTL_MAX_DATA_LEN]); + datasent = 0; + datapt = rpkt.u.data; + dataend = &rpkt.u.data[CTL_MAX_DATA_LEN]; + + if ((rbufp->recv_length & 0x3) != 0) + DPRINTF(3, ("Control packet length %d unrounded\n", + rbufp->recv_length)); /* * We're set up now. Make sure we've got at least enough @@ -644,54 +1113,37 @@ process_control( } properlen = req_count + CTL_HEADER_LEN; -#ifdef DEBUG - if (debug > 2 && (rbufp->recv_length & 0x3) != 0) - printf("Packet length %d unrounded\n", - rbufp->recv_length); -#endif /* round up proper len to a 8 octet boundary */ properlen = (properlen + 7) & ~7; maclen = rbufp->recv_length - properlen; - if ((rbufp->recv_length & (sizeof(u_long) - 1)) == 0 && + if ((rbufp->recv_length & 3) == 0 && maclen >= MIN_MAC_LEN && maclen <= MAX_MAC_LEN && sys_authenticate) { - res_authenticate = 1; - res_keyid = ntohl(*(u_int32 *)((u_char *)pkt + - properlen)); - -#ifdef DEBUG - if (debug > 2) - printf( - "recv_len %d, properlen %d, wants auth with keyid %08x, MAC length=%d\n", - rbufp->recv_length, properlen, res_keyid, maclen); -#endif - if (!authistrusted(res_keyid)) { -#ifdef DEBUG - if (debug > 2) - printf("invalid keyid %08x\n", - res_keyid); -#endif - } else if (authdecrypt(res_keyid, (u_int32 *)pkt, - rbufp->recv_length - maclen, maclen)) { -#ifdef DEBUG - if (debug > 2) - printf("authenticated okay\n"); -#endif - res_authokay = 1; + res_authenticate = TRUE; + pkid = (void *)((char *)pkt + properlen); + res_keyid = ntohl(*pkid); + DPRINTF(3, ("recv_len %d, properlen %d, wants auth with keyid %08x, MAC length=%zu\n", + rbufp->recv_length, properlen, res_keyid, + maclen)); + + if (!authistrusted(res_keyid)) + DPRINTF(3, ("invalid keyid %08x\n", res_keyid)); + else if (authdecrypt(res_keyid, (u_int32 *)pkt, + rbufp->recv_length - maclen, + maclen)) { + res_authokay = TRUE; + DPRINTF(3, ("authenticated okay\n")); } else { -#ifdef DEBUG - if (debug > 2) - printf("authentication failed\n"); -#endif res_keyid = 0; + DPRINTF(3, ("authentication failed\n")); } } /* * Set up translate pointers */ - reqpt = (char *)pkt->data; + reqpt = (char *)pkt->u.data; reqend = reqpt + req_count; /* @@ -699,13 +1151,11 @@ process_control( */ for (cc = control_codes; cc->control_code != NO_REQUEST; cc++) { if (cc->control_code == res_opcode) { -#ifdef DEBUG - if (debug > 2) - printf("opcode %d, found command handler\n", - res_opcode); -#endif - if (cc->flags == AUTH && (!res_authokay || - res_keyid != ctl_auth_keyid)) { + DPRINTF(3, ("opcode %d, found command handler\n", + res_opcode)); + if (cc->flags == AUTH + && (!res_authokay + || res_keyid != ctl_auth_keyid)) { ctl_error(CERR_PERMISSION); return; } @@ -728,22 +1178,24 @@ process_control( */ u_short ctlpeerstatus( - register struct peer *peer + register struct peer *p ) { - register u_short status; + u_short status; - status = peer->status; - if (peer->flags & FLAG_CONFIG) + status = p->status; + if (FLAG_CONFIG & p->flags) status |= CTL_PST_CONFIG; - if (peer->flags & FLAG_AUTHENABLE) + if (p->keyid) status |= CTL_PST_AUTHENABLE; - if (peer->flags & FLAG_AUTHENTIC) + if (FLAG_AUTHENTIC & p->flags) status |= CTL_PST_AUTHENTIC; - if (peer->reach != 0) + if (p->reach) status |= CTL_PST_REACH; - return (u_short)CTL_PEER_STATUS(status, peer->num_events, - peer->last_event); + if (MDF_TXONLY_MASK & p->cast_flags) + status |= CTL_PST_BCAST; + + return CTL_PEER_STATUS(status, p->num_events, p->last_event); } @@ -753,11 +1205,10 @@ ctlpeerstatus( #ifdef REFCLOCK static u_short ctlclkstatus( - struct refclockstat *this_clock + struct refclockstat *pcs ) { - return ((u_short)(((this_clock->currentstatus) << 8) | - (this_clock->lastevent))); + return CTL_PEER_STATUS(0, pcs->lastevent, pcs->currentstatus); } #endif @@ -772,22 +1223,18 @@ ctlsysstatus(void) this_clock = CTL_SST_TS_UNSPEC; #ifdef REFCLOCK - if (sys_peer != 0) { - if (sys_peer->sstclktype != CTL_SST_TS_UNSPEC) { + if (sys_peer != NULL) { + if (CTL_SST_TS_UNSPEC != sys_peer->sstclktype) this_clock = sys_peer->sstclktype; - if (pps_control) - this_clock |= CTL_SST_TS_PPS; - } else { - if (sys_peer->refclktype < sizeof(clocktypes)) - this_clock = - clocktypes[sys_peer->refclktype]; - if (pps_control) - this_clock |= CTL_SST_TS_PPS; - } + else if (sys_peer->refclktype < COUNTOF(clocktypes)) + this_clock = clocktypes[sys_peer->refclktype]; } +#else /* REFCLOCK */ + if (sys_peer != 0) + this_clock = CTL_SST_TS_NTP; #endif /* REFCLOCK */ - return (u_short)CTL_SYS_STATUS(sys_leap, this_clock, - ctl_sys_num_events, ctl_sys_last_event); + return CTL_SYS_STATUS(sys_leap, this_clock, ctl_sys_num_events, + ctl_sys_last_event); } @@ -797,20 +1244,25 @@ ctlsysstatus(void) */ static void ctl_flushpkt( - int more + u_char more ) { + size_t i; int dlen; int sendlen; + int maclen; + int totlen; + keyid_t keyid; - if (!more && datanotbinflag) { + dlen = datapt - rpkt.u.data; + if (!more && datanotbinflag && dlen + 2 < CTL_MAX_DATA_LEN) { /* * Big hack, output a trailing \r\n */ *datapt++ = '\r'; *datapt++ = '\n'; + dlen += 2; } - dlen = datapt - (u_char *)rpkt.data; sendlen = dlen + CTL_HEADER_LEN; /* @@ -824,35 +1276,31 @@ ctl_flushpkt( /* * Fill in the packet with the current info */ - rpkt.r_m_e_op = (u_char)(CTL_RESPONSE|more|(res_opcode & - CTL_OP_MASK)); - rpkt.count = htons((u_short) dlen); - rpkt.offset = htons( (u_short) res_offset); + rpkt.r_m_e_op = CTL_RESPONSE | more | + (res_opcode & CTL_OP_MASK); + rpkt.count = htons((u_short)dlen); + rpkt.offset = htons((u_short)res_offset); if (res_async) { - register int i; - - for (i = 0; i < CTL_MAXTRAPS; i++) { - if (ctl_trap[i].tr_flags & TRAP_INUSE) { + for (i = 0; i < COUNTOF(ctl_traps); i++) { + if (TRAP_INUSE & ctl_traps[i].tr_flags) { rpkt.li_vn_mode = - PKT_LI_VN_MODE(sys_leap, - ctl_trap[i].tr_version, - MODE_CONTROL); + PKT_LI_VN_MODE( + sys_leap, + ctl_traps[i].tr_version, + MODE_CONTROL); rpkt.sequence = - htons(ctl_trap[i].tr_sequence); - sendpkt(&ctl_trap[i].tr_addr, - ctl_trap[i].tr_localaddr, -4, + htons(ctl_traps[i].tr_sequence); + sendpkt(&ctl_traps[i].tr_addr, + ctl_traps[i].tr_localaddr, -4, (struct pkt *)&rpkt, sendlen); if (!more) - ctl_trap[i].tr_sequence++; + ctl_traps[i].tr_sequence++; numasyncmsgs++; } } } else { if (res_authenticate && sys_authenticate) { - int maclen; - int totlen = sendlen; - keyid_t keyid = htonl(res_keyid); - + totlen = sendlen; /* * If we are going to authenticate, then there * is an additional requirement that the MAC @@ -862,14 +1310,15 @@ ctl_flushpkt( *datapt++ = '\0'; totlen++; } - memcpy(datapt, &keyid, sizeof keyid); + keyid = htonl(res_keyid); + memcpy(datapt, &keyid, sizeof(keyid)); maclen = authencrypt(res_keyid, - (u_int32 *)&rpkt, totlen); + (u_int32 *)&rpkt, totlen); sendpkt(rmt_addr, lcl_inter, -5, - (struct pkt *)&rpkt, totlen + maclen); + (struct pkt *)&rpkt, totlen + maclen); } else { sendpkt(rmt_addr, lcl_inter, -6, - (struct pkt *)&rpkt, sendlen); + (struct pkt *)&rpkt, sendlen); } if (more) numctlfrags++; @@ -880,8 +1329,9 @@ ctl_flushpkt( /* * Set us up for another go around. */ + res_frags++; res_offset += dlen; - datapt = (u_char *)rpkt.data; + datapt = rpkt.u.data; } @@ -893,7 +1343,7 @@ static void ctl_putdata( const char *dp, unsigned int dlen, - int bin /* set to 1 when data is binary */ + int bin /* set to 1 when data is binary */ ) { int overhead; @@ -901,13 +1351,12 @@ ctl_putdata( overhead = 0; if (!bin) { - datanotbinflag = 1; + datanotbinflag = TRUE; overhead = 3; - if (datapt != rpkt.data) { + if (datasent) { *datapt++ = ','; datalinelen++; - if ((dlen + datalinelen + 1) >= MAXDATALINELEN) - { + if ((dlen + datalinelen + 1) >= MAXDATALINELEN) { *datapt++ = '\r'; *datapt++ = '\n'; datalinelen = 0; @@ -925,7 +1374,7 @@ ctl_putdata( /* * Not enough room in this one, flush it out. */ - currentlen = MIN(dlen, dataend - datapt); + currentlen = MIN(dlen, (unsigned int)(dataend - datapt)); memcpy(datapt, dp, currentlen); @@ -937,54 +1386,94 @@ ctl_putdata( ctl_flushpkt(CTL_MORE); } - memmove((char *)datapt, dp, (unsigned)dlen); + memcpy(datapt, dp, dlen); datapt += dlen; datalinelen += dlen; + datasent = TRUE; } /* * ctl_putstr - write a tagged string into the response packet + * in the form: + * + * tag="data" + * + * len is the data length excluding the NUL terminator, + * as in ctl_putstr("var", "value", strlen("value")); */ static void ctl_putstr( - const char *tag, - const char *data, - unsigned int len + const char * tag, + const char * data, + size_t len ) { - register char *cp; - register const char *cq; - char buffer[400]; + char buffer[512]; + char *cp; + size_t tl; - cp = buffer; - cq = tag; - while (*cq != '\0') - *cp++ = *cq++; + tl = strlen(tag); + memcpy(buffer, tag, tl); + cp = buffer + tl; if (len > 0) { + INSIST(tl + 3 + len <= sizeof(buffer)); *cp++ = '='; *cp++ = '"'; - if (len > (int) (sizeof(buffer) - (cp - buffer) - 1)) - len = sizeof(buffer) - (cp - buffer) - 1; - memmove(cp, data, (unsigned)len); + memcpy(cp, data, len); cp += len; *cp++ = '"'; } - ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); + ctl_putdata(buffer, (u_int)(cp - buffer), 0); } /* - * ctl_putdbl - write a tagged, signed double into the response packet + * ctl_putunqstr - write a tagged string into the response packet + * in the form: + * + * tag=data + * + * len is the data length excluding the NUL terminator. + * data must not contain a comma or whitespace. */ static void -ctl_putdbl( - const char *tag, - double ts +ctl_putunqstr( + const char * tag, + const char * data, + size_t len ) { - register char *cp; - register const char *cq; + char buffer[512]; + char *cp; + size_t tl; + + tl = strlen(tag); + memcpy(buffer, tag, tl); + cp = buffer + tl; + if (len > 0) { + INSIST(tl + 1 + len <= sizeof(buffer)); + *cp++ = '='; + memcpy(cp, data, len); + cp += len; + } + ctl_putdata(buffer, (u_int)(cp - buffer), 0); +} + + +/* + * ctl_putdblf - write a tagged, signed double into the response packet + */ +static void +ctl_putdblf( + const char * tag, + int use_f, + int precision, + double d + ) +{ + char *cp; + const char *cq; char buffer[200]; cp = buffer; @@ -992,10 +1481,11 @@ ctl_putdbl( while (*cq != '\0') *cp++ = *cq++; *cp++ = '='; - (void)sprintf(cp, "%.3f", ts); - while (*cp != '\0') - cp++; - ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); + INSIST((size_t)(cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), use_f ? "%.*f" : "%.*g", + precision, d); + cp += strlen(cp); + ctl_putdata(buffer, (unsigned)(cp - buffer), 0); } /* @@ -1017,16 +1507,42 @@ ctl_putuint( *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "%lu", uval); - while (*cp != '\0') - cp++; + INSIST((cp - buffer) < (int)sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%lu", uval); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } +/* + * ctl_putcal - write a decoded calendar data into the response + */ +static void +ctl_putcal( + const char *tag, + const struct calendar *pcal + ) +{ + char buffer[100]; + unsigned numch; + + numch = snprintf(buffer, sizeof(buffer), + "%s=%04d%02d%02d%02d%02d", + tag, + pcal->year, + pcal->month, + pcal->monthday, + pcal->hour, + pcal->minute + ); + INSIST(numch < sizeof(buffer)); + ctl_putdata(buffer, numch, 0); + + return; +} + /* * ctl_putfs - write a decoded filestamp into the response */ -#ifdef OPENSSL static void ctl_putfs( const char *tag, @@ -1047,20 +1563,20 @@ ctl_putfs( *cp++ = '='; fstamp = uval - JAN_1970; tm = gmtime(&fstamp); - if (tm == NULL) + if (NULL == tm) return; - - sprintf(cp, "%04d%02d%02d%02d%02d", tm->tm_year + 1900, - tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min); - while (*cp != '\0') - cp++; + INSIST((cp - buffer) < (int)sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), + "%04d%02d%02d%02d%02d", tm->tm_year + 1900, + tm->tm_mon + 1, tm->tm_mday, tm->tm_hour, tm->tm_min); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } -#endif /* - * ctl_puthex - write a tagged unsigned integer, in hex, into the response + * ctl_puthex - write a tagged unsigned integer, in hex, into the + * response */ static void ctl_puthex( @@ -1078,9 +1594,9 @@ ctl_puthex( *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "0x%lx", uval); - while (*cp != '\0') - cp++; + INSIST((cp - buffer) < (int)sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "0x%lx", uval); + cp += strlen(cp); ctl_putdata(buffer,(unsigned)( cp - buffer ), 0); } @@ -1104,9 +1620,9 @@ ctl_putint( *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "%ld", ival); - while (*cp != '\0') - cp++; + INSIST((cp - buffer) < (int)sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%ld", ival); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } @@ -1130,11 +1646,10 @@ ctl_putts( *cp++ = *cq++; *cp++ = '='; - (void) sprintf(cp, "0x%08lx.%08lx", - ts->l_ui & ULONG_CONST(0xffffffff), - ts->l_uf & ULONG_CONST(0xffffffff)); - while (*cp != '\0') - cp++; + INSIST((size_t)(cp - buffer) < sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "0x%08x.%08x", + (u_int)ts->l_ui, (u_int)ts->l_uf); + cp += strlen(cp); ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); } @@ -1146,7 +1661,7 @@ static void ctl_putadr( const char *tag, u_int32 addr32, - struct sockaddr_storage* addr + sockaddr_u *addr ) { register char *cp; @@ -1159,38 +1674,54 @@ ctl_putadr( *cp++ = *cq++; *cp++ = '='; - if (addr == NULL) + if (NULL == addr) cq = numtoa(addr32); else cq = stoa(addr); - while (*cq != '\0') - *cp++ = *cq++; - ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); + INSIST((cp - buffer) < (int)sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), "%s", cq); + cp += strlen(cp); + ctl_putdata(buffer, (unsigned)(cp - buffer), 0); } + /* - * ctl_putid - write a tagged clock ID into the response + * ctl_putrefid - send a u_int32 refid as printable text */ static void -ctl_putid( - const char *tag, - char *id +ctl_putrefid( + const char * tag, + u_int32 refid ) { - register char *cp; - register const char *cq; - char buffer[200]; - - cp = buffer; - cq = tag; - while (*cq != '\0') - *cp++ = *cq++; - - *cp++ = '='; - cq = id; - while (*cq != '\0' && (cq - id) < 4) - *cp++ = *cq++; - ctl_putdata(buffer, (unsigned)( cp - buffer ), 0); + char output[16]; + char * optr; + char * oplim; + char * iptr; + char * iplim; + char * past_eq; + + optr = output; + oplim = output + sizeof(output); + while (optr < oplim && '\0' != *tag) + *optr++ = *tag++; + if (optr < oplim) { + *optr++ = '='; + past_eq = optr; + } + if (!(optr < oplim)) + return; + iptr = (char *)&refid; + iplim = iptr + sizeof(refid); + for ( ; optr < oplim && iptr < iplim && '\0' != *iptr; + iptr++, optr++) + if (isprint((int)*iptr)) + *optr = *iptr; + else + *optr = '.'; + if (!(optr <= oplim)) + optr = past_eq; + ctl_putdata(output, (u_int)(optr - output), FALSE); } @@ -1212,15 +1743,17 @@ ctl_putarray( cq = tag; while (*cq != '\0') *cp++ = *cq++; + *cp++ = '='; i = start; do { if (i == 0) i = NTP_SHIFT; i--; - (void)sprintf(cp, " %.2f", arr[i] * 1e3); - while (*cp != '\0') - cp++; - } while(i != start); + INSIST((cp - buffer) < (int)sizeof(buffer)); + snprintf(cp, sizeof(buffer) - (cp - buffer), + " %.2f", arr[i] * 1e3); + cp += strlen(cp); + } while (i != start); ctl_putdata(buffer, (unsigned)(cp - buffer), 0); } @@ -1235,10 +1768,36 @@ ctl_putsys( { l_fp tmp; char str[256]; -#ifdef OPENSSL + u_int u; + double kb; + double dtemp; + const char *ss; +#ifdef AUTOKEY struct cert_info *cp; - char cbuf[256]; -#endif /* OPENSSL */ +#endif /* AUTOKEY */ +#ifdef KERNEL_PLL + static struct timex ntx; + static u_long ntp_adjtime_time; + + static const double to_ms = +# ifdef STA_NANO + 1.0e-6; /* nsec to msec */ +# else + 1.0e-3; /* usec to msec */ +# endif + + /* + * CS_K_* variables depend on up-to-date output of ntp_adjtime() + */ + if (CS_KERN_FIRST <= varid && varid <= CS_KERN_LAST && + current_time != ntp_adjtime_time) { + ZERO(ntx); + if (ntp_adjtime(&ntx) < 0) + msyslog(LOG_ERR, "ntp_adjtime() for mode 6 query failed: %m"); + else + ntp_adjtime_time = current_time; + } +#endif /* KERNEL_PLL */ switch (varid) { @@ -1256,20 +1815,19 @@ ctl_putsys( case CS_ROOTDELAY: ctl_putdbl(sys_var[CS_ROOTDELAY].text, sys_rootdelay * - 1e3); + 1e3); break; case CS_ROOTDISPERSION: ctl_putdbl(sys_var[CS_ROOTDISPERSION].text, - sys_rootdispersion * 1e3); + sys_rootdisp * 1e3); break; case CS_REFID: if (sys_stratum > 1 && sys_stratum < STRATUM_UNSPEC) - ctl_putadr(sys_var[CS_REFID].text, sys_refid, NULL); + ctl_putadr(sys_var[varid].text, sys_refid, NULL); else - ctl_putid(sys_var[CS_REFID].text, - (char *)&sys_refid); + ctl_putrefid(sys_var[varid].text, sys_refid); break; case CS_REFTIME: @@ -1285,15 +1843,26 @@ ctl_putsys( ctl_putuint(sys_var[CS_PEERID].text, 0); else ctl_putuint(sys_var[CS_PEERID].text, - sys_peer->associd); + sys_peer->associd); + break; + + case CS_PEERADR: + if (sys_peer != NULL && sys_peer->dstadr != NULL) + ss = sptoa(&sys_peer->srcadr); + else + ss = "0.0.0.0:0"; + ctl_putunqstr(sys_var[CS_PEERADR].text, ss, strlen(ss)); break; - case CS_STATE: - ctl_putuint(sys_var[CS_STATE].text, (unsigned)state); + case CS_PEERMODE: + u = (sys_peer != NULL) + ? sys_peer->hmode + : MODE_UNSPEC; + ctl_putuint(sys_var[CS_PEERMODE].text, u); break; case CS_OFFSET: - ctl_putdbl(sys_var[CS_OFFSET].text, last_offset * 1e3); + ctl_putdbl6(sys_var[CS_OFFSET].text, last_offset * 1e3); break; case CS_DRIFT: @@ -1301,7 +1870,7 @@ ctl_putsys( break; case CS_JITTER: - ctl_putdbl(sys_var[CS_JITTER].text, sys_jitter * 1e3); + ctl_putdbl6(sys_var[CS_JITTER].text, sys_jitter * 1e3); break; case CS_ERROR: @@ -1316,164 +1885,542 @@ ctl_putsys( case CS_PROCESSOR: #ifndef HAVE_UNAME ctl_putstr(sys_var[CS_PROCESSOR].text, str_processor, - sizeof(str_processor) - 1); + sizeof(str_processor) - 1); #else ctl_putstr(sys_var[CS_PROCESSOR].text, - utsnamebuf.machine, strlen(utsnamebuf.machine)); + utsnamebuf.machine, strlen(utsnamebuf.machine)); #endif /* HAVE_UNAME */ break; case CS_SYSTEM: #ifndef HAVE_UNAME ctl_putstr(sys_var[CS_SYSTEM].text, str_system, - sizeof(str_system) - 1); + sizeof(str_system) - 1); #else - sprintf(str, "%s/%s", utsnamebuf.sysname, utsnamebuf.release); + snprintf(str, sizeof(str), "%s/%s", utsnamebuf.sysname, + utsnamebuf.release); ctl_putstr(sys_var[CS_SYSTEM].text, str, strlen(str)); #endif /* HAVE_UNAME */ break; case CS_VERSION: ctl_putstr(sys_var[CS_VERSION].text, Version, - strlen(Version)); + strlen(Version)); break; case CS_STABIL: ctl_putdbl(sys_var[CS_STABIL].text, clock_stability * - 1e6); + 1e6); break; case CS_VARLIST: - { - char buf[CTL_MAX_DATA_LEN]; - register char *s, *t, *be; - register const char *ss; - register int i; - register struct ctl_var *k; - - s = buf; - be = buf + sizeof(buf) - - strlen(sys_var[CS_VARLIST].text) - 4; - if (s > be) - break; /* really long var name */ - - strcpy(s, sys_var[CS_VARLIST].text); - strcat(s, "=\""); - s += strlen(s); - t = s; - for (k = sys_var; !(k->flags &EOV); k++) { - if (k->flags & PADDING) - continue; - i = strlen(k->text); - if (s+i+1 >= be) + { + char buf[CTL_MAX_DATA_LEN]; + //buffPointer, firstElementPointer, buffEndPointer + char *buffp, *buffend; + int firstVarName; + const char *ss1; + int len; + const struct ctl_var *k; + + buffp = buf; + buffend = buf + sizeof(buf); + if (buffp + strlen(sys_var[CS_VARLIST].text) + 4 > buffend) + break; /* really long var name */ + + snprintf(buffp, sizeof(buf), "%s=\"",sys_var[CS_VARLIST].text); + buffp += strlen(buffp); + firstVarName = TRUE; + for (k = sys_var; !(k->flags & EOV); k++) { + if (k->flags & PADDING) + continue; + len = strlen(k->text); + if (buffp + len + 1 >= buffend) break; + if (!firstVarName) + *buffp++ = ','; + else + firstVarName = FALSE; + memcpy(buffp, k->text, len); + buffp += len; + } - if (s != t) - *s++ = ','; - strcpy(s, k->text); - s += i; + for (k = ext_sys_var; k && !(k->flags & EOV); k++) { + if (k->flags & PADDING) + continue; + if (NULL == k->text) + continue; + ss1 = strchr(k->text, '='); + if (NULL == ss1) + len = strlen(k->text); + else + len = ss1 - k->text; + if (buffp + len + 1 >= buffend) + break; + if (firstVarName) { + *buffp++ = ','; + firstVarName = FALSE; } + memcpy(buffp, k->text,(unsigned)len); + buffp += len; + } + if (buffp + 2 >= buffend) + break; - for (k = ext_sys_var; k && !(k->flags &EOV); - k++) { - if (k->flags & PADDING) - continue; + *buffp++ = '"'; + *buffp = '\0'; - ss = k->text; - if (!ss) - continue; + ctl_putdata(buf, (unsigned)( buffp - buf ), 0); + break; + } - while (*ss && *ss != '=') - ss++; - i = ss - k->text; - if (s + i + 1 >= be) - break; + case CS_TAI: + if (sys_tai > 0) + ctl_putuint(sys_var[CS_TAI].text, sys_tai); + break; - if (s != t) - *s++ = ','; - strncpy(s, k->text, - (unsigned)i); - s += i; - } - if (s+2 >= be) - break; + case CS_LEAPTAB: + { + leap_signature_t lsig; + leapsec_getsig(&lsig); + if (lsig.ttime > 0) + ctl_putfs(sys_var[CS_LEAPTAB].text, lsig.ttime); + break; + } - *s++ = '"'; - *s = '\0'; + case CS_LEAPEND: + { + leap_signature_t lsig; + leapsec_getsig(&lsig); + if (lsig.etime > 0) + ctl_putfs(sys_var[CS_LEAPEND].text, lsig.etime); + break; + } - ctl_putdata(buf, (unsigned)( s - buf ), - 0); - } +#ifdef LEAP_SMEAR + case CS_LEAPSMEARINTV: + if (leap_smear_intv > 0) + ctl_putuint(sys_var[CS_LEAPSMEARINTV].text, leap_smear_intv); break; -#ifdef OPENSSL - case CS_FLAGS: - if (crypto_flags) { - ctl_puthex(sys_var[CS_FLAGS].text, crypto_flags); - } + case CS_LEAPSMEAROFFS: + if (leap_smear_intv > 0) + ctl_putdbl(sys_var[CS_LEAPSMEAROFFS].text, + leap_smear.doffset * 1e3); break; +#endif /* LEAP_SMEAR */ - case CS_DIGEST: - if (crypto_flags) { - const EVP_MD *dp; + case CS_RATE: + ctl_putuint(sys_var[CS_RATE].text, ntp_minpoll); + break; - dp = EVP_get_digestbynid(crypto_flags >> 16); - strcpy(str, OBJ_nid2ln(EVP_MD_pkey_type(dp))); - ctl_putstr(sys_var[CS_DIGEST].text, str, - strlen(str)); - } + case CS_MRU_ENABLED: + ctl_puthex(sys_var[varid].text, mon_enabled); break; - case CS_HOST: - if (sys_hostname != NULL) - ctl_putstr(sys_var[CS_HOST].text, sys_hostname, - strlen(sys_hostname)); + case CS_MRU_DEPTH: + ctl_putuint(sys_var[varid].text, mru_entries); break; - case CS_CERTIF: - for (cp = cinfo; cp != NULL; cp = cp->link) { - sprintf(cbuf, "%s %s 0x%x", cp->subject, - cp->issuer, cp->flags); - ctl_putstr(sys_var[CS_CERTIF].text, cbuf, - strlen(cbuf)); - ctl_putfs(sys_var[CS_REVOKE].text, cp->last); - } + case CS_MRU_MEM: + kb = mru_entries * (sizeof(mon_entry) / 1024.); + u = (u_int)kb; + if (kb - u >= 0.5) + u++; + ctl_putuint(sys_var[varid].text, u); break; - case CS_PUBLIC: - if (hostval.fstamp != 0) - ctl_putfs(sys_var[CS_PUBLIC].text, - ntohl(hostval.tstamp)); + case CS_MRU_DEEPEST: + ctl_putuint(sys_var[varid].text, mru_peakentries); break; - case CS_REVTIME: - if (hostval.tstamp != 0) - ctl_putfs(sys_var[CS_REVTIME].text, - ntohl(hostval.tstamp)); + case CS_MRU_MINDEPTH: + ctl_putuint(sys_var[varid].text, mru_mindepth); + break; + + case CS_MRU_MAXAGE: + ctl_putint(sys_var[varid].text, mru_maxage); + break; + + case CS_MRU_MAXDEPTH: + ctl_putuint(sys_var[varid].text, mru_maxdepth); + break; + + case CS_MRU_MAXMEM: + kb = mru_maxdepth * (sizeof(mon_entry) / 1024.); + u = (u_int)kb; + if (kb - u >= 0.5) + u++; + ctl_putuint(sys_var[varid].text, u); + break; + + case CS_SS_UPTIME: + ctl_putuint(sys_var[varid].text, current_time); + break; + + case CS_SS_RESET: + ctl_putuint(sys_var[varid].text, + current_time - sys_stattime); + break; + + case CS_SS_RECEIVED: + ctl_putuint(sys_var[varid].text, sys_received); + break; + + case CS_SS_THISVER: + ctl_putuint(sys_var[varid].text, sys_newversion); + break; + + case CS_SS_OLDVER: + ctl_putuint(sys_var[varid].text, sys_oldversion); + break; + + case CS_SS_BADFORMAT: + ctl_putuint(sys_var[varid].text, sys_badlength); + break; + + case CS_SS_BADAUTH: + ctl_putuint(sys_var[varid].text, sys_badauth); + break; + + case CS_SS_DECLINED: + ctl_putuint(sys_var[varid].text, sys_declined); + break; + + case CS_SS_RESTRICTED: + ctl_putuint(sys_var[varid].text, sys_restricted); + break; + + case CS_SS_LIMITED: + ctl_putuint(sys_var[varid].text, sys_limitrejected); + break; + + case CS_SS_KODSENT: + ctl_putuint(sys_var[varid].text, sys_kodsent); + break; + + case CS_SS_PROCESSED: + ctl_putuint(sys_var[varid].text, sys_processed); + break; + + case CS_BCASTDELAY: + ctl_putdbl(sys_var[varid].text, sys_bdelay * 1e3); + break; + + case CS_AUTHDELAY: + LFPTOD(&sys_authdelay, dtemp); + ctl_putdbl(sys_var[varid].text, dtemp * 1e3); + break; + + case CS_AUTHKEYS: + ctl_putuint(sys_var[varid].text, authnumkeys); + break; + + case CS_AUTHFREEK: + ctl_putuint(sys_var[varid].text, authnumfreekeys); + break; + + case CS_AUTHKLOOKUPS: + ctl_putuint(sys_var[varid].text, authkeylookups); + break; + + case CS_AUTHKNOTFOUND: + ctl_putuint(sys_var[varid].text, authkeynotfound); + break; + + case CS_AUTHKUNCACHED: + ctl_putuint(sys_var[varid].text, authkeyuncached); + break; + + case CS_AUTHKEXPIRED: + ctl_putuint(sys_var[varid].text, authkeyexpired); + break; + + case CS_AUTHENCRYPTS: + ctl_putuint(sys_var[varid].text, authencryptions); + break; + + case CS_AUTHDECRYPTS: + ctl_putuint(sys_var[varid].text, authdecryptions); + break; + + case CS_AUTHRESET: + ctl_putuint(sys_var[varid].text, + current_time - auth_timereset); + break; + + /* + * CTL_IF_KERNLOOP() puts a zero if the kernel loop is + * unavailable, otherwise calls putfunc with args. + */ +#ifndef KERNEL_PLL +# define CTL_IF_KERNLOOP(putfunc, args) \ + ctl_putint(sys_var[varid].text, 0) +#else +# define CTL_IF_KERNLOOP(putfunc, args) \ + putfunc args +#endif + + /* + * CTL_IF_KERNPPS() puts a zero if either the kernel + * loop is unavailable, or kernel hard PPS is not + * active, otherwise calls putfunc with args. + */ +#ifndef KERNEL_PLL +# define CTL_IF_KERNPPS(putfunc, args) \ + ctl_putint(sys_var[varid].text, 0) +#else +# define CTL_IF_KERNPPS(putfunc, args) \ + if (0 == ntx.shift) \ + ctl_putint(sys_var[varid].text, 0); \ + else \ + putfunc args /* no trailing ; */ +#endif + + case CS_K_OFFSET: + CTL_IF_KERNLOOP( + ctl_putdblf, + (sys_var[varid].text, 0, -1, to_ms * ntx.offset) + ); + break; + + case CS_K_FREQ: + CTL_IF_KERNLOOP( + ctl_putsfp, + (sys_var[varid].text, ntx.freq) + ); + break; + + case CS_K_MAXERR: + CTL_IF_KERNLOOP( + ctl_putdblf, + (sys_var[varid].text, 0, 6, + to_ms * ntx.maxerror) + ); + break; + + case CS_K_ESTERR: + CTL_IF_KERNLOOP( + ctl_putdblf, + (sys_var[varid].text, 0, 6, + to_ms * ntx.esterror) + ); + break; + + case CS_K_STFLAGS: +#ifndef KERNEL_PLL + ss = ""; +#else + ss = k_st_flags(ntx.status); +#endif + ctl_putstr(sys_var[varid].text, ss, strlen(ss)); + break; + + case CS_K_TIMECONST: + CTL_IF_KERNLOOP( + ctl_putint, + (sys_var[varid].text, ntx.constant) + ); + break; + + case CS_K_PRECISION: + CTL_IF_KERNLOOP( + ctl_putdblf, + (sys_var[varid].text, 0, 6, + to_ms * ntx.precision) + ); + break; + + case CS_K_FREQTOL: + CTL_IF_KERNLOOP( + ctl_putsfp, + (sys_var[varid].text, ntx.tolerance) + ); + break; + + case CS_K_PPS_FREQ: + CTL_IF_KERNPPS( + ctl_putsfp, + (sys_var[varid].text, ntx.ppsfreq) + ); + break; + + case CS_K_PPS_STABIL: + CTL_IF_KERNPPS( + ctl_putsfp, + (sys_var[varid].text, ntx.stabil) + ); + break; + + case CS_K_PPS_JITTER: + CTL_IF_KERNPPS( + ctl_putdbl, + (sys_var[varid].text, to_ms * ntx.jitter) + ); + break; + + case CS_K_PPS_CALIBDUR: + CTL_IF_KERNPPS( + ctl_putint, + (sys_var[varid].text, 1 << ntx.shift) + ); + break; + + case CS_K_PPS_CALIBS: + CTL_IF_KERNPPS( + ctl_putint, + (sys_var[varid].text, ntx.calcnt) + ); + break; + + case CS_K_PPS_CALIBERRS: + CTL_IF_KERNPPS( + ctl_putint, + (sys_var[varid].text, ntx.errcnt) + ); + break; + + case CS_K_PPS_JITEXC: + CTL_IF_KERNPPS( + ctl_putint, + (sys_var[varid].text, ntx.jitcnt) + ); + break; + + case CS_K_PPS_STBEXC: + CTL_IF_KERNPPS( + ctl_putint, + (sys_var[varid].text, ntx.stbcnt) + ); + break; + + case CS_IOSTATS_RESET: + ctl_putuint(sys_var[varid].text, + current_time - io_timereset); + break; + + case CS_TOTAL_RBUF: + ctl_putuint(sys_var[varid].text, total_recvbuffs()); + break; + + case CS_FREE_RBUF: + ctl_putuint(sys_var[varid].text, free_recvbuffs()); + break; + + case CS_USED_RBUF: + ctl_putuint(sys_var[varid].text, full_recvbuffs()); + break; + + case CS_RBUF_LOWATER: + ctl_putuint(sys_var[varid].text, lowater_additions()); + break; + + case CS_IO_DROPPED: + ctl_putuint(sys_var[varid].text, packets_dropped); + break; + + case CS_IO_IGNORED: + ctl_putuint(sys_var[varid].text, packets_ignored); + break; + + case CS_IO_RECEIVED: + ctl_putuint(sys_var[varid].text, packets_received); + break; + + case CS_IO_SENT: + ctl_putuint(sys_var[varid].text, packets_sent); + break; + + case CS_IO_SENDFAILED: + ctl_putuint(sys_var[varid].text, packets_notsent); + break; + + case CS_IO_WAKEUPS: + ctl_putuint(sys_var[varid].text, handler_calls); + break; + + case CS_IO_GOODWAKEUPS: + ctl_putuint(sys_var[varid].text, handler_pkts); + break; + + case CS_TIMERSTATS_RESET: + ctl_putuint(sys_var[varid].text, + current_time - timer_timereset); + break; + + case CS_TIMER_OVERRUNS: + ctl_putuint(sys_var[varid].text, alarm_overflow); + break; + + case CS_TIMER_XMTS: + ctl_putuint(sys_var[varid].text, timer_xmtcalls); + break; + + case CS_FUZZ: + ctl_putdbl(sys_var[varid].text, sys_fuzz * 1e3); + break; + case CS_WANDER_THRESH: + ctl_putdbl(sys_var[varid].text, wander_threshold * 1e6); + break; +#ifdef AUTOKEY + case CS_FLAGS: + if (crypto_flags) + ctl_puthex(sys_var[CS_FLAGS].text, + crypto_flags); + break; + + case CS_DIGEST: + if (crypto_flags) { + strlcpy(str, OBJ_nid2ln(crypto_nid), + COUNTOF(str)); + ctl_putstr(sys_var[CS_DIGEST].text, str, + strlen(str)); + } + break; + + case CS_SIGNATURE: + if (crypto_flags) { + const EVP_MD *dp; + + dp = EVP_get_digestbynid(crypto_flags >> 16); + strlcpy(str, OBJ_nid2ln(EVP_MD_pkey_type(dp)), + COUNTOF(str)); + ctl_putstr(sys_var[CS_SIGNATURE].text, str, + strlen(str)); + } + break; + + case CS_HOST: + if (hostval.ptr != NULL) + ctl_putstr(sys_var[CS_HOST].text, hostval.ptr, + strlen(hostval.ptr)); break; case CS_IDENT: - if (iffpar_pkey != NULL) - ctl_putstr(sys_var[CS_IDENT].text, - iffpar_file, strlen(iffpar_file)); - if (gqpar_pkey != NULL) - ctl_putstr(sys_var[CS_IDENT].text, - gqpar_file, strlen(gqpar_file)); - if (mvpar_pkey != NULL) - ctl_putstr(sys_var[CS_IDENT].text, - mvpar_file, strlen(mvpar_file)); + if (sys_ident != NULL) + ctl_putstr(sys_var[CS_IDENT].text, sys_ident, + strlen(sys_ident)); break; - case CS_LEAPTAB: - if (tai_leap.fstamp != 0) - ctl_putfs(sys_var[CS_LEAPTAB].text, - ntohl(tai_leap.fstamp)); + case CS_CERTIF: + for (cp = cinfo; cp != NULL; cp = cp->link) { + snprintf(str, sizeof(str), "%s %s 0x%x", + cp->subject, cp->issuer, cp->flags); + ctl_putstr(sys_var[CS_CERTIF].text, str, + strlen(str)); + ctl_putcal(sys_var[CS_REVTIME].text, &(cp->last)); + } break; - case CS_TAI: - ctl_putuint(sys_var[CS_TAI].text, sys_tai); + case CS_PUBLIC: + if (hostval.tstamp != 0) + ctl_putfs(sys_var[CS_PUBLIC].text, + ntohl(hostval.tstamp)); + break; +#endif /* AUTOKEY */ + + default: break; -#endif /* OPENSSL */ } } @@ -1483,275 +2430,328 @@ ctl_putsys( */ static void ctl_putpeer( - int varid, - struct peer *peer + int id, + struct peer *p ) { - int temp; -#ifdef OPENSSL - char str[256]; + char buf[CTL_MAX_DATA_LEN]; + char *s; + char *t; + char *be; + int i; + const struct ctl_var *k; +#ifdef AUTOKEY struct autokey *ap; -#endif /* OPENSSL */ + const EVP_MD *dp; + const char *str; +#endif /* AUTOKEY */ - switch (varid) { + switch (id) { case CP_CONFIG: - ctl_putuint(peer_var[CP_CONFIG].text, - (unsigned)((peer->flags & FLAG_CONFIG) != 0)); + ctl_putuint(peer_var[id].text, + !(FLAG_PREEMPT & p->flags)); break; case CP_AUTHENABLE: - ctl_putuint(peer_var[CP_AUTHENABLE].text, - (unsigned)((peer->flags & FLAG_AUTHENABLE) != 0)); + ctl_putuint(peer_var[id].text, !(p->keyid)); break; case CP_AUTHENTIC: - ctl_putuint(peer_var[CP_AUTHENTIC].text, - (unsigned)((peer->flags & FLAG_AUTHENTIC) != 0)); + ctl_putuint(peer_var[id].text, + !!(FLAG_AUTHENTIC & p->flags)); break; case CP_SRCADR: - ctl_putadr(peer_var[CP_SRCADR].text, 0, - &peer->srcadr); + ctl_putadr(peer_var[id].text, 0, &p->srcadr); break; case CP_SRCPORT: - ctl_putuint(peer_var[CP_SRCPORT].text, - ntohs(((struct sockaddr_in*)&peer->srcadr)->sin_port)); + ctl_putuint(peer_var[id].text, SRCPORT(&p->srcadr)); + break; + + case CP_SRCHOST: + if (p->hostname != NULL) + ctl_putstr(peer_var[id].text, p->hostname, + strlen(p->hostname)); break; case CP_DSTADR: - if (peer->dstadr) { - ctl_putadr(peer_var[CP_DSTADR].text, 0, - &(peer->dstadr->sin)); - } else { - ctl_putadr(peer_var[CP_DSTADR].text, 0, - NULL); - } + ctl_putadr(peer_var[id].text, 0, + (p->dstadr != NULL) + ? &p->dstadr->sin + : NULL); break; case CP_DSTPORT: - ctl_putuint(peer_var[CP_DSTPORT].text, - (u_long)(peer->dstadr ? - ntohs(((struct sockaddr_in*)&peer->dstadr->sin)->sin_port) : 0)); + ctl_putuint(peer_var[id].text, + (p->dstadr != NULL) + ? SRCPORT(&p->dstadr->sin) + : 0); + break; + + case CP_IN: + if (p->r21 > 0.) + ctl_putdbl(peer_var[id].text, p->r21 / 1e3); + break; + + case CP_OUT: + if (p->r34 > 0.) + ctl_putdbl(peer_var[id].text, p->r34 / 1e3); + break; + + case CP_RATE: + ctl_putuint(peer_var[id].text, p->throttle); break; case CP_LEAP: - ctl_putuint(peer_var[CP_LEAP].text, peer->leap); + ctl_putuint(peer_var[id].text, p->leap); break; case CP_HMODE: - ctl_putuint(peer_var[CP_HMODE].text, peer->hmode); + ctl_putuint(peer_var[id].text, p->hmode); break; case CP_STRATUM: - ctl_putuint(peer_var[CP_STRATUM].text, peer->stratum); + ctl_putuint(peer_var[id].text, p->stratum); break; case CP_PPOLL: - ctl_putuint(peer_var[CP_PPOLL].text, peer->ppoll); + ctl_putuint(peer_var[id].text, p->ppoll); break; case CP_HPOLL: - ctl_putuint(peer_var[CP_HPOLL].text, peer->hpoll); + ctl_putuint(peer_var[id].text, p->hpoll); break; case CP_PRECISION: - ctl_putint(peer_var[CP_PRECISION].text, - peer->precision); + ctl_putint(peer_var[id].text, p->precision); break; case CP_ROOTDELAY: - ctl_putdbl(peer_var[CP_ROOTDELAY].text, - peer->rootdelay * 1e3); + ctl_putdbl(peer_var[id].text, p->rootdelay * 1e3); break; case CP_ROOTDISPERSION: - ctl_putdbl(peer_var[CP_ROOTDISPERSION].text, - peer->rootdispersion * 1e3); + ctl_putdbl(peer_var[id].text, p->rootdisp * 1e3); break; case CP_REFID: - if (peer->flags & FLAG_REFCLOCK) { - ctl_putid(peer_var[CP_REFID].text, - (char *)&peer->refid); - } else { - if (peer->stratum > 1 && peer->stratum < - STRATUM_UNSPEC) - ctl_putadr(peer_var[CP_REFID].text, - peer->refid, NULL); - else - ctl_putid(peer_var[CP_REFID].text, - (char *)&peer->refid); +#ifdef REFCLOCK + if (p->flags & FLAG_REFCLOCK) { + ctl_putrefid(peer_var[id].text, p->refid); + break; } +#endif + if (p->stratum > 1 && p->stratum < STRATUM_UNSPEC) + ctl_putadr(peer_var[id].text, p->refid, + NULL); + else + ctl_putrefid(peer_var[id].text, p->refid); break; case CP_REFTIME: - ctl_putts(peer_var[CP_REFTIME].text, &peer->reftime); + ctl_putts(peer_var[id].text, &p->reftime); break; case CP_ORG: - ctl_putts(peer_var[CP_ORG].text, &peer->org); + ctl_putts(peer_var[id].text, &p->aorg); break; case CP_REC: - ctl_putts(peer_var[CP_REC].text, &peer->rec); + ctl_putts(peer_var[id].text, &p->dst); break; case CP_XMT: - ctl_putts(peer_var[CP_XMT].text, &peer->xmt); + if (p->xleave) + ctl_putdbl(peer_var[id].text, p->xleave * 1e3); + break; + + case CP_BIAS: + if (p->bias != 0.) + ctl_putdbl(peer_var[id].text, p->bias * 1e3); break; case CP_REACH: - ctl_puthex(peer_var[CP_REACH].text, peer->reach); + ctl_puthex(peer_var[id].text, p->reach); break; case CP_FLASH: - temp = peer->flash; - ctl_puthex(peer_var[CP_FLASH].text, temp); + ctl_puthex(peer_var[id].text, p->flash); break; case CP_TTL: - ctl_putint(peer_var[CP_TTL].text, sys_ttl[peer->ttl]); +#ifdef REFCLOCK + if (p->flags & FLAG_REFCLOCK) { + ctl_putuint(peer_var[id].text, p->ttl); + break; + } +#endif + if (p->ttl > 0 && p->ttl < COUNTOF(sys_ttl)) + ctl_putint(peer_var[id].text, + sys_ttl[p->ttl]); break; case CP_UNREACH: - ctl_putuint(peer_var[CP_UNREACH].text, peer->unreach); + ctl_putuint(peer_var[id].text, p->unreach); break; case CP_TIMER: - ctl_putuint(peer_var[CP_TIMER].text, - peer->nextdate - current_time); + ctl_putuint(peer_var[id].text, + p->nextdate - current_time); break; case CP_DELAY: - ctl_putdbl(peer_var[CP_DELAY].text, peer->delay * 1e3); + ctl_putdbl(peer_var[id].text, p->delay * 1e3); break; case CP_OFFSET: - ctl_putdbl(peer_var[CP_OFFSET].text, peer->offset * - 1e3); + ctl_putdbl(peer_var[id].text, p->offset * 1e3); break; case CP_JITTER: - ctl_putdbl(peer_var[CP_JITTER].text, peer->jitter * 1e3); + ctl_putdbl(peer_var[id].text, p->jitter * 1e3); break; case CP_DISPERSION: - ctl_putdbl(peer_var[CP_DISPERSION].text, peer->disp * - 1e3); + ctl_putdbl(peer_var[id].text, p->disp * 1e3); break; case CP_KEYID: - ctl_putuint(peer_var[CP_KEYID].text, peer->keyid); + if (p->keyid > NTP_MAXKEY) + ctl_puthex(peer_var[id].text, p->keyid); + else + ctl_putuint(peer_var[id].text, p->keyid); break; case CP_FILTDELAY: - ctl_putarray(peer_var[CP_FILTDELAY].text, - peer->filter_delay, (int)peer->filter_nextpt); + ctl_putarray(peer_var[id].text, p->filter_delay, + p->filter_nextpt); break; case CP_FILTOFFSET: - ctl_putarray(peer_var[CP_FILTOFFSET].text, - peer->filter_offset, (int)peer->filter_nextpt); + ctl_putarray(peer_var[id].text, p->filter_offset, + p->filter_nextpt); break; case CP_FILTERROR: - ctl_putarray(peer_var[CP_FILTERROR].text, - peer->filter_disp, (int)peer->filter_nextpt); + ctl_putarray(peer_var[id].text, p->filter_disp, + p->filter_nextpt); break; case CP_PMODE: - ctl_putuint(peer_var[CP_PMODE].text, peer->pmode); + ctl_putuint(peer_var[id].text, p->pmode); break; case CP_RECEIVED: - ctl_putuint(peer_var[CP_RECEIVED].text, peer->received); + ctl_putuint(peer_var[id].text, p->received); break; case CP_SENT: - ctl_putuint(peer_var[CP_SENT].text, peer->sent); + ctl_putuint(peer_var[id].text, p->sent); break; case CP_VARLIST: - { - char buf[CTL_MAX_DATA_LEN]; - register char *s, *t, *be; - register int i; - register struct ctl_var *k; - - s = buf; - be = buf + sizeof(buf) - - strlen(peer_var[CP_VARLIST].text) - 4; - if (s > be) - break; /* really long var name */ - - strcpy(s, peer_var[CP_VARLIST].text); - strcat(s, "=\""); - s += strlen(s); - t = s; - for (k = peer_var; !(k->flags &EOV); k++) { - if (k->flags & PADDING) - continue; - - i = strlen(k->text); - if (s + i + 1 >= be) - break; - - if (s != t) - *s++ = ','; - strcpy(s, k->text); - s += i; - } - if (s+2 >= be) + s = buf; + be = buf + sizeof(buf); + if (strlen(peer_var[id].text) + 4 > sizeof(buf)) + break; /* really long var name */ + + snprintf(s, sizeof(buf), "%s=\"", peer_var[id].text); + s += strlen(s); + t = s; + for (k = peer_var; !(EOV & k->flags); k++) { + if (PADDING & k->flags) + continue; + i = strlen(k->text); + if (s + i + 1 >= be) break; - + if (s != t) + *s++ = ','; + memcpy(s, k->text, i); + s += i; + } + if (s + 2 < be) { *s++ = '"'; *s = '\0'; - ctl_putdata(buf, (unsigned)(s - buf), 0); + ctl_putdata(buf, (u_int)(s - buf), 0); } break; -#ifdef OPENSSL - case CP_FLAGS: - if (peer->crypto) - ctl_puthex(peer_var[CP_FLAGS].text, peer->crypto); + + case CP_TIMEREC: + ctl_putuint(peer_var[id].text, + current_time - p->timereceived); break; - case CP_DIGEST: - if (peer->crypto) { - const EVP_MD *dp; + case CP_TIMEREACH: + ctl_putuint(peer_var[id].text, + current_time - p->timereachable); + break; + + case CP_BADAUTH: + ctl_putuint(peer_var[id].text, p->badauth); + break; + + case CP_BOGUSORG: + ctl_putuint(peer_var[id].text, p->bogusorg); + break; + + case CP_OLDPKT: + ctl_putuint(peer_var[id].text, p->oldpkt); + break; + + case CP_SELDISP: + ctl_putuint(peer_var[id].text, p->seldisptoolarge); + break; + + case CP_SELBROKEN: + ctl_putuint(peer_var[id].text, p->selbroken); + break; + + case CP_CANDIDATE: + ctl_putuint(peer_var[id].text, p->status); + break; +#ifdef AUTOKEY + case CP_FLAGS: + if (p->crypto) + ctl_puthex(peer_var[id].text, p->crypto); + break; - dp = EVP_get_digestbynid(peer->crypto >> 16); - strcpy(str, OBJ_nid2ln(EVP_MD_pkey_type(dp))); - ctl_putstr(peer_var[CP_DIGEST].text, str, - strlen(str)); + case CP_SIGNATURE: + if (p->crypto) { + dp = EVP_get_digestbynid(p->crypto >> 16); + str = OBJ_nid2ln(EVP_MD_pkey_type(dp)); + ctl_putstr(peer_var[id].text, str, strlen(str)); } break; case CP_HOST: - if (peer->subject != NULL) - ctl_putstr(peer_var[CP_HOST].text, - peer->subject, strlen(peer->subject)); + if (p->subject != NULL) + ctl_putstr(peer_var[id].text, p->subject, + strlen(p->subject)); break; case CP_VALID: /* not used */ break; - case CP_IDENT: - if (peer->issuer != NULL) - ctl_putstr(peer_var[CP_IDENT].text, - peer->issuer, strlen(peer->issuer)); - break; - case CP_INITSEQ: - if ((ap = (struct autokey *)peer->recval.ptr) == NULL) + if (NULL == (ap = p->recval.ptr)) break; + ctl_putint(peer_var[CP_INITSEQ].text, ap->seq); ctl_puthex(peer_var[CP_INITKEY].text, ap->key); ctl_putfs(peer_var[CP_INITTSP].text, - ntohl(peer->recval.tstamp)); + ntohl(p->recval.tstamp)); + break; + + case CP_IDENT: + if (p->ident != NULL) + ctl_putstr(peer_var[id].text, p->ident, + strlen(p->ident)); break; -#endif /* OPENSSL */ + + +#endif /* AUTOKEY */ } } @@ -1762,153 +2762,148 @@ ctl_putpeer( */ static void ctl_putclock( - int varid, - struct refclockstat *clock_stat, + int id, + struct refclockstat *pcs, int mustput ) { - switch(varid) { + char buf[CTL_MAX_DATA_LEN]; + char *s, *t, *be; + const char *ss; + int i; + const struct ctl_var *k; + + switch (id) { case CC_TYPE: - if (mustput || clock_stat->clockdesc == NULL - || *(clock_stat->clockdesc) == '\0') { - ctl_putuint(clock_var[CC_TYPE].text, clock_stat->type); + if (mustput || pcs->clockdesc == NULL + || *(pcs->clockdesc) == '\0') { + ctl_putuint(clock_var[id].text, pcs->type); } break; case CC_TIMECODE: - ctl_putstr(clock_var[CC_TIMECODE].text, - clock_stat->p_lastcode, - (unsigned)clock_stat->lencode); + ctl_putstr(clock_var[id].text, + pcs->p_lastcode, + (unsigned)pcs->lencode); break; case CC_POLL: - ctl_putuint(clock_var[CC_POLL].text, clock_stat->polls); + ctl_putuint(clock_var[id].text, pcs->polls); break; case CC_NOREPLY: - ctl_putuint(clock_var[CC_NOREPLY].text, - clock_stat->noresponse); + ctl_putuint(clock_var[id].text, + pcs->noresponse); break; case CC_BADFORMAT: - ctl_putuint(clock_var[CC_BADFORMAT].text, - clock_stat->badformat); + ctl_putuint(clock_var[id].text, + pcs->badformat); break; case CC_BADDATA: - ctl_putuint(clock_var[CC_BADDATA].text, - clock_stat->baddata); + ctl_putuint(clock_var[id].text, + pcs->baddata); break; case CC_FUDGETIME1: - if (mustput || (clock_stat->haveflags & CLK_HAVETIME1)) - ctl_putdbl(clock_var[CC_FUDGETIME1].text, - clock_stat->fudgetime1 * 1e3); + if (mustput || (pcs->haveflags & CLK_HAVETIME1)) + ctl_putdbl(clock_var[id].text, + pcs->fudgetime1 * 1e3); break; case CC_FUDGETIME2: - if (mustput || (clock_stat->haveflags & CLK_HAVETIME2)) ctl_putdbl(clock_var[CC_FUDGETIME2].text, - clock_stat->fudgetime2 * 1e3); + if (mustput || (pcs->haveflags & CLK_HAVETIME2)) + ctl_putdbl(clock_var[id].text, + pcs->fudgetime2 * 1e3); break; case CC_FUDGEVAL1: - if (mustput || (clock_stat->haveflags & CLK_HAVEVAL1)) - ctl_putint(clock_var[CC_FUDGEVAL1].text, - clock_stat->fudgeval1); + if (mustput || (pcs->haveflags & CLK_HAVEVAL1)) + ctl_putint(clock_var[id].text, + pcs->fudgeval1); break; case CC_FUDGEVAL2: - if (mustput || (clock_stat->haveflags & CLK_HAVEVAL2)) { - if (clock_stat->fudgeval1 > 1) - ctl_putadr(clock_var[CC_FUDGEVAL2].text, - (u_int32)clock_stat->fudgeval2, NULL); + if (mustput || (pcs->haveflags & CLK_HAVEVAL2)) { + if (pcs->fudgeval1 > 1) + ctl_putadr(clock_var[id].text, + pcs->fudgeval2, NULL); else - ctl_putid(clock_var[CC_FUDGEVAL2].text, - (char *)&clock_stat->fudgeval2); + ctl_putrefid(clock_var[id].text, + pcs->fudgeval2); } break; case CC_FLAGS: - if (mustput || (clock_stat->haveflags & (CLK_HAVEFLAG1 | - CLK_HAVEFLAG2 | CLK_HAVEFLAG3 | CLK_HAVEFLAG4))) - ctl_putuint(clock_var[CC_FLAGS].text, - clock_stat->flags); + ctl_putuint(clock_var[id].text, pcs->flags); break; case CC_DEVICE: - if (clock_stat->clockdesc == NULL || - *(clock_stat->clockdesc) == '\0') { + if (pcs->clockdesc == NULL || + *(pcs->clockdesc) == '\0') { if (mustput) - ctl_putstr(clock_var[CC_DEVICE].text, - "", 0); + ctl_putstr(clock_var[id].text, + "", 0); } else { - ctl_putstr(clock_var[CC_DEVICE].text, - clock_stat->clockdesc, - strlen(clock_stat->clockdesc)); + ctl_putstr(clock_var[id].text, + pcs->clockdesc, + strlen(pcs->clockdesc)); } break; case CC_VARLIST: - { - char buf[CTL_MAX_DATA_LEN]; - register char *s, *t, *be; - register const char *ss; - register int i; - register struct ctl_var *k; - - s = buf; - be = buf + sizeof(buf); - if (s + strlen(clock_var[CC_VARLIST].text) + 4 > - be) - break; /* really long var name */ - - strcpy(s, clock_var[CC_VARLIST].text); - strcat(s, "=\""); - s += strlen(s); - t = s; - - for (k = clock_var; !(k->flags &EOV); k++) { - if (k->flags & PADDING) - continue; - - i = strlen(k->text); - if (s + i + 1 >= be) - break; + s = buf; + be = buf + sizeof(buf); + if (strlen(clock_var[CC_VARLIST].text) + 4 > + sizeof(buf)) + break; /* really long var name */ + + snprintf(s, sizeof(buf), "%s=\"", + clock_var[CC_VARLIST].text); + s += strlen(s); + t = s; + + for (k = clock_var; !(EOV & k->flags); k++) { + if (PADDING & k->flags) + continue; - if (s != t) - *s++ = ','; - strcpy(s, k->text); - s += i; - } + i = strlen(k->text); + if (s + i + 1 >= be) + break; - for (k = clock_stat->kv_list; k && !(k->flags & - EOV); k++) { - if (k->flags & PADDING) - continue; + if (s != t) + *s++ = ','; + memcpy(s, k->text, i); + s += i; + } - ss = k->text; - if (!ss) - continue; + for (k = pcs->kv_list; k && !(EOV & k->flags); k++) { + if (PADDING & k->flags) + continue; - while (*ss && *ss != '=') - ss++; - i = ss - k->text; - if (s+i+1 >= be) - break; + ss = k->text; + if (NULL == ss) + continue; - if (s != t) - *s++ = ','; - strncpy(s, k->text, (unsigned)i); - s += i; - *s = '\0'; - } - if (s+2 >= be) + while (*ss && *ss != '=') + ss++; + i = ss - k->text; + if (s + i + 1 >= be) break; - *s++ = '"'; + if (s != t) + *s++ = ','; + memcpy(s, k->text, (unsigned)i); + s += i; *s = '\0'; - ctl_putdata(buf, (unsigned)( s - buf ), 0); } + if (s + 2 >= be) + break; + + *s++ = '"'; + *s = '\0'; + ctl_putdata(buf, (unsigned)(s - buf), 0); break; } } @@ -1919,48 +2914,49 @@ ctl_putclock( /* * ctl_getitem - get the next data item from the incoming packet */ -static struct ctl_var * +static const struct ctl_var * ctl_getitem( - struct ctl_var *var_list, + const struct ctl_var *var_list, char **data ) { - register struct ctl_var *v; - register char *cp; - register char *tp; - static struct ctl_var eol = { 0, EOV, }; + static const struct ctl_var eol = { 0, EOV, NULL }; static char buf[128]; + static u_long quiet_until; + const struct ctl_var *v; + const char *pch; + char *cp; + char *tp; /* * Delete leading commas and white space */ while (reqpt < reqend && (*reqpt == ',' || - isspace((unsigned char)*reqpt))) + isspace((unsigned char)*reqpt))) reqpt++; if (reqpt >= reqend) - return (0); + return NULL; - if (var_list == (struct ctl_var *)0) - return (&eol); + if (NULL == var_list) + return &eol; /* * Look for a first character match on the tag. If we find * one, see if it is a full match. */ - v = var_list; cp = reqpt; - while (!(v->flags & EOV)) { - if (!(v->flags & PADDING) && *cp == *(v->text)) { - tp = v->text; - while (*tp != '\0' && *tp != '=' && cp < - reqend && *cp == *tp) { + for (v = var_list; !(EOV & v->flags); v++) { + if (!(PADDING & v->flags) && *cp == *(v->text)) { + pch = v->text; + while ('\0' != *pch && '=' != *pch && cp < reqend + && *cp == *pch) { cp++; - tp++; + pch++; } - if ((*tp == '\0') || (*tp == '=')) { - while (cp < reqend && isspace((unsigned char)*cp)) + if ('\0' == *pch || '=' == *pch) { + while (cp < reqend && isspace((u_char)*cp)) cp++; - if (cp == reqend || *cp == ',') { + if (cp == reqend || ',' == *cp) { buf[0] = '\0'; *data = buf; if (cp < reqend) @@ -1968,42 +2964,37 @@ ctl_getitem( reqpt = cp; return v; } - if (*cp == '=') { + if ('=' == *cp) { cp++; tp = buf; - while (cp < reqend && isspace((unsigned char)*cp)) + while (cp < reqend && isspace((u_char)*cp)) cp++; while (cp < reqend && *cp != ',') { *tp++ = *cp++; - if (tp >= buf + sizeof(buf)) { + if ((size_t)(tp - buf) >= sizeof(buf)) { ctl_error(CERR_BADFMT); numctlbadpkts++; -#if 0 /* Avoid possible DOS attack */ -/* If we get a smarter msyslog we can re-enable this */ - msyslog(LOG_WARNING, - "Possible 'ntpdx' exploit from %s:%d (possibly spoofed)\n", - stoa(rmt_addr), SRCPORT(rmt_addr) - ); -#endif - return (0); + NLOG(NLOG_SYSEVENT) + if (quiet_until <= current_time) { + quiet_until = current_time + 300; + msyslog(LOG_WARNING, +"Possible 'ntpdx' exploit from %s#%u (possibly spoofed)", stoa(rmt_addr), SRCPORT(rmt_addr)); + } + return NULL; } } if (cp < reqend) cp++; *tp-- = '\0'; - while (tp >= buf) { - if (!isspace((unsigned int)(*tp))) - break; + while (tp >= buf && isspace((u_char)*tp)) *tp-- = '\0'; - } reqpt = cp; *data = buf; - return (v); + return v; } } cp = reqpt; } - v++; } return v; } @@ -2026,15 +3017,15 @@ control_unspec( * I return no errors and no data, unless a specified assocation * doesn't exist. */ - if (res_associd != 0) { - if ((peer = findpeerbyassoc(res_associd)) == 0) { + if (res_associd) { + peer = findpeerbyassoc(res_associd); + if (NULL == peer) { ctl_error(CERR_BADASSOC); return; } rpkt.status = htons(ctlpeerstatus(peer)); - } else { + } else rpkt.status = htons(ctlsysstatus()); - } ctl_flushpkt(0); } @@ -2050,9 +3041,11 @@ read_status( int restrict_mask ) { - register int i; - register struct peer *peer; - u_short ass_stat[CTL_MAX_DATA_LEN / sizeof(u_short)]; + struct peer *peer; + const u_char *cp; + size_t n; + /* a_st holds association ID, status pairs alternating */ + u_short a_st[CTL_MAX_DATA_LEN / sizeof(u_short)]; #ifdef DEBUG if (debug > 2) @@ -2063,276 +3056,1302 @@ read_status( * zero we return all known assocation ID's. Otherwise * we return a bunch of stuff about the particular peer. */ - if (res_associd == 0) { - register int n; - - n = 0; - rpkt.status = htons(ctlsysstatus()); - for (i = 0; i < NTP_HASH_SIZE; i++) { - for (peer = assoc_hash[i]; peer != 0; - peer = peer->ass_next) { - ass_stat[n++] = htons(peer->associd); - ass_stat[n++] = - htons(ctlpeerstatus(peer)); - if (n == - CTL_MAX_DATA_LEN/sizeof(u_short)) { - ctl_putdata((char *)ass_stat, - n * sizeof(u_short), 1); - n = 0; - } + if (res_associd) { + peer = findpeerbyassoc(res_associd); + if (NULL == peer) { + ctl_error(CERR_BADASSOC); + return; + } + rpkt.status = htons(ctlpeerstatus(peer)); + if (res_authokay) + peer->num_events = 0; + /* + * For now, output everything we know about the + * peer. May be more selective later. + */ + for (cp = def_peer_var; *cp != 0; cp++) + ctl_putpeer((int)*cp, peer); + ctl_flushpkt(0); + return; + } + n = 0; + rpkt.status = htons(ctlsysstatus()); + for (peer = peer_list; peer != NULL; peer = peer->p_link) { + a_st[n++] = htons(peer->associd); + a_st[n++] = htons(ctlpeerstatus(peer)); + /* two entries each loop iteration, so n + 1 */ + if (n + 1 >= COUNTOF(a_st)) { + ctl_putdata((void *)a_st, n * sizeof(a_st[0]), + 1); + n = 0; + } + } + if (n) + ctl_putdata((void *)a_st, n * sizeof(a_st[0]), 1); + ctl_flushpkt(0); +} + + +/* + * read_peervars - half of read_variables() implementation + */ +static void +read_peervars(void) +{ + const struct ctl_var *v; + struct peer *peer; + const u_char *cp; + size_t i; + char * valuep; + u_char wants[CP_MAXCODE + 1]; + u_int gotvar; + + /* + * Wants info for a particular peer. See if we know + * the guy. + */ + peer = findpeerbyassoc(res_associd); + if (NULL == peer) { + ctl_error(CERR_BADASSOC); + return; + } + rpkt.status = htons(ctlpeerstatus(peer)); + if (res_authokay) + peer->num_events = 0; + ZERO(wants); + gotvar = 0; + while (NULL != (v = ctl_getitem(peer_var, &valuep))) { + if (v->flags & EOV) { + ctl_error(CERR_UNKNOWNVAR); + return; + } + INSIST(v->code < COUNTOF(wants)); + wants[v->code] = 1; + gotvar = 1; + } + if (gotvar) { + for (i = 1; i < COUNTOF(wants); i++) + if (wants[i]) + ctl_putpeer(i, peer); + } else + for (cp = def_peer_var; *cp != 0; cp++) + ctl_putpeer((int)*cp, peer); + ctl_flushpkt(0); +} + + +/* + * read_sysvars - half of read_variables() implementation + */ +static void +read_sysvars(void) +{ + const struct ctl_var *v; + struct ctl_var *kv; + u_int n; + u_int gotvar; + const u_char *cs; + char * valuep; + const char * pch; + u_char *wants; + size_t wants_count; + + /* + * Wants system variables. Figure out which he wants + * and give them to him. + */ + rpkt.status = htons(ctlsysstatus()); + if (res_authokay) + ctl_sys_num_events = 0; + wants_count = CS_MAXCODE + 1 + count_var(ext_sys_var); + wants = emalloc_zero(wants_count); + gotvar = 0; + while (NULL != (v = ctl_getitem(sys_var, &valuep))) { + if (!(EOV & v->flags)) { + INSIST(v->code < wants_count); + wants[v->code] = 1; + gotvar = 1; + } else { + v = ctl_getitem(ext_sys_var, &valuep); + INSIST(v != NULL); + if (EOV & v->flags) { + ctl_error(CERR_UNKNOWNVAR); + free(wants); + return; + } + n = v->code + CS_MAXCODE + 1; + INSIST(n < wants_count); + wants[n] = 1; + gotvar = 1; + } + } + if (gotvar) { + for (n = 1; n <= CS_MAXCODE; n++) + if (wants[n]) + ctl_putsys(n); + for (n = 0; n + CS_MAXCODE + 1 < wants_count; n++) + if (wants[n + CS_MAXCODE + 1]) { + pch = ext_sys_var[n].text; + ctl_putdata(pch, strlen(pch), 0); } + } else { + for (cs = def_sys_var; *cs != 0; cs++) + ctl_putsys((int)*cs); + for (kv = ext_sys_var; kv && !(EOV & kv->flags); kv++) + if (DEF & kv->flags) + ctl_putdata(kv->text, strlen(kv->text), + 0); + } + free(wants); + ctl_flushpkt(0); +} + + +/* + * read_variables - return the variables the caller asks for + */ +/*ARGSUSED*/ +static void +read_variables( + struct recvbuf *rbufp, + int restrict_mask + ) +{ + if (res_associd) + read_peervars(); + else + read_sysvars(); +} + + +/* + * write_variables - write into variables. We only allow leap bit + * writing this way. + */ +/*ARGSUSED*/ +static void +write_variables( + struct recvbuf *rbufp, + int restrict_mask + ) +{ + const struct ctl_var *v; + int ext_var; + char *valuep; + long val; + size_t octets; + char *vareqv; + const char *t; + char *tt; + + val = 0; + /* + * If he's trying to write into a peer tell him no way + */ + if (res_associd != 0) { + ctl_error(CERR_PERMISSION); + return; + } + + /* + * Set status + */ + rpkt.status = htons(ctlsysstatus()); + + /* + * Look through the variables. Dump out at the first sign of + * trouble. + */ + while ((v = ctl_getitem(sys_var, &valuep)) != 0) { + ext_var = 0; + if (v->flags & EOV) { + if ((v = ctl_getitem(ext_sys_var, &valuep)) != + 0) { + if (v->flags & EOV) { + ctl_error(CERR_UNKNOWNVAR); + return; + } + ext_var = 1; + } else { + break; + } + } + if (!(v->flags & CAN_WRITE)) { + ctl_error(CERR_PERMISSION); + return; + } + if (!ext_var && (*valuep == '\0' || !atoint(valuep, + &val))) { + ctl_error(CERR_BADFMT); + return; + } + if (!ext_var && (val & ~LEAP_NOTINSYNC) != 0) { + ctl_error(CERR_BADVALUE); + return; + } + + if (ext_var) { + octets = strlen(v->text) + strlen(valuep) + 2; + vareqv = emalloc(octets); + tt = vareqv; + t = v->text; + while (*t && *t != '=') + *tt++ = *t++; + *tt++ = '='; + memcpy(tt, valuep, 1 + strlen(valuep)); + set_sys_var(vareqv, 1 + strlen(vareqv), v->flags); + free(vareqv); + } else { + ctl_error(CERR_UNSPEC); /* really */ + return; + } + } + + /* + * If we got anything, do it. xxx nothing to do *** + */ + /* + if (leapind != ~0 || leapwarn != ~0) { + if (!leap_setleap((int)leapind, (int)leapwarn)) { + ctl_error(CERR_PERMISSION); + return; + } + } + */ + ctl_flushpkt(0); +} + + +/* + * configure() processes ntpq :config/config-from-file, allowing + * generic runtime reconfiguration. + */ +static void configure( + struct recvbuf *rbufp, + int restrict_mask + ) +{ + size_t data_count; + int retval; + + /* I haven't yet implemented changes to an existing association. + * Hence check if the association id is 0 + */ + if (res_associd != 0) { + ctl_error(CERR_BADVALUE); + return; + } + + if (RES_NOMODIFY & restrict_mask) { + snprintf(remote_config.err_msg, + sizeof(remote_config.err_msg), + "runtime configuration prohibited by restrict ... nomodify"); + ctl_putdata(remote_config.err_msg, + strlen(remote_config.err_msg), 0); + ctl_flushpkt(0); + NLOG(NLOG_SYSINFO) + msyslog(LOG_NOTICE, + "runtime config from %s rejected due to nomodify restriction", + stoa(&rbufp->recv_srcadr)); + sys_restricted++; + return; + } + + /* Initialize the remote config buffer */ + data_count = remoteconfig_cmdlength(reqpt, reqend); + + if (data_count > sizeof(remote_config.buffer) - 2) { + snprintf(remote_config.err_msg, + sizeof(remote_config.err_msg), + "runtime configuration failed: request too long"); + ctl_putdata(remote_config.err_msg, + strlen(remote_config.err_msg), 0); + ctl_flushpkt(0); + msyslog(LOG_NOTICE, + "runtime config from %s rejected: request too long", + stoa(&rbufp->recv_srcadr)); + return; + } + /* Bug 2853 -- check if all characters were acceptable */ + if (data_count != (size_t)(reqend - reqpt)) { + snprintf(remote_config.err_msg, + sizeof(remote_config.err_msg), + "runtime configuration failed: request contains an unprintable character"); + ctl_putdata(remote_config.err_msg, + strlen(remote_config.err_msg), 0); + ctl_flushpkt(0); + msyslog(LOG_NOTICE, + "runtime config from %s rejected: request contains an unprintable character: %0x", + stoa(&rbufp->recv_srcadr), + reqpt[data_count]); + return; + } + + memcpy(remote_config.buffer, reqpt, data_count); + /* The buffer has no trailing linefeed or NUL right now. For + * logging, we do not want a newline, so we do that first after + * adding the necessary NUL byte. + */ + remote_config.buffer[data_count] = '\0'; + DPRINTF(1, ("Got Remote Configuration Command: %s\n", + remote_config.buffer)); + msyslog(LOG_NOTICE, "%s config: %s", + stoa(&rbufp->recv_srcadr), + remote_config.buffer); + + /* Now we have to make sure there is a NL/NUL sequence at the + * end of the buffer before we parse it. + */ + remote_config.buffer[data_count++] = '\n'; + remote_config.buffer[data_count] = '\0'; + remote_config.pos = 0; + remote_config.err_pos = 0; + remote_config.no_errors = 0; + config_remotely(&rbufp->recv_srcadr); + + /* + * Check if errors were reported. If not, output 'Config + * Succeeded'. Else output the error count. It would be nice + * to output any parser error messages. + */ + if (0 == remote_config.no_errors) { + retval = snprintf(remote_config.err_msg, + sizeof(remote_config.err_msg), + "Config Succeeded"); + if (retval > 0) + remote_config.err_pos += retval; + } + + ctl_putdata(remote_config.err_msg, remote_config.err_pos, 0); + ctl_flushpkt(0); + + DPRINTF(1, ("Reply: %s\n", remote_config.err_msg)); + + if (remote_config.no_errors > 0) + msyslog(LOG_NOTICE, "%d error in %s config", + remote_config.no_errors, + stoa(&rbufp->recv_srcadr)); +} + + +/* + * derive_nonce - generate client-address-specific nonce value + * associated with a given timestamp. + */ +static u_int32 derive_nonce( + sockaddr_u * addr, + u_int32 ts_i, + u_int32 ts_f + ) +{ + static u_int32 salt[4]; + static u_long last_salt_update; + union d_tag { + u_char digest[EVP_MAX_MD_SIZE]; + u_int32 extract; + } d; + EVP_MD_CTX ctx; + u_int len; + + while (!salt[0] || current_time - last_salt_update >= 3600) { + salt[0] = ntp_random(); + salt[1] = ntp_random(); + salt[2] = ntp_random(); + salt[3] = ntp_random(); + last_salt_update = current_time; + } + + EVP_DigestInit(&ctx, EVP_get_digestbynid(NID_md5)); + EVP_DigestUpdate(&ctx, salt, sizeof(salt)); + EVP_DigestUpdate(&ctx, &ts_i, sizeof(ts_i)); + EVP_DigestUpdate(&ctx, &ts_f, sizeof(ts_f)); + if (IS_IPV4(addr)) + EVP_DigestUpdate(&ctx, &SOCK_ADDR4(addr), + sizeof(SOCK_ADDR4(addr))); + else + EVP_DigestUpdate(&ctx, &SOCK_ADDR6(addr), + sizeof(SOCK_ADDR6(addr))); + EVP_DigestUpdate(&ctx, &NSRCPORT(addr), sizeof(NSRCPORT(addr))); + EVP_DigestUpdate(&ctx, salt, sizeof(salt)); + EVP_DigestFinal(&ctx, d.digest, &len); + + return d.extract; +} + + +/* + * generate_nonce - generate client-address-specific nonce string. + */ +static void generate_nonce( + struct recvbuf * rbufp, + char * nonce, + size_t nonce_octets + ) +{ + u_int32 derived; + + derived = derive_nonce(&rbufp->recv_srcadr, + rbufp->recv_time.l_ui, + rbufp->recv_time.l_uf); + snprintf(nonce, nonce_octets, "%08x%08x%08x", + rbufp->recv_time.l_ui, rbufp->recv_time.l_uf, derived); +} + + +/* + * validate_nonce - validate client-address-specific nonce string. + * + * Returns TRUE if the local calculation of the nonce matches the + * client-provided value and the timestamp is recent enough. + */ +static int validate_nonce( + const char * pnonce, + struct recvbuf * rbufp + ) +{ + u_int ts_i; + u_int ts_f; + l_fp ts; + l_fp now_delta; + u_int supposed; + u_int derived; + + if (3 != sscanf(pnonce, "%08x%08x%08x", &ts_i, &ts_f, &supposed)) + return FALSE; + + ts.l_ui = (u_int32)ts_i; + ts.l_uf = (u_int32)ts_f; + derived = derive_nonce(&rbufp->recv_srcadr, ts.l_ui, ts.l_uf); + get_systime(&now_delta); + L_SUB(&now_delta, &ts); + + return (supposed == derived && now_delta.l_ui < 16); +} + + +/* + * send_random_tag_value - send a randomly-generated three character + * tag prefix, a '.', an index, a '=' and a + * random integer value. + * + * To try to force clients to ignore unrecognized tags in mrulist, + * reslist, and ifstats responses, the first and last rows are spiced + * with randomly-generated tag names with correct .# index. Make it + * three characters knowing that none of the currently-used subscripted + * tags have that length, avoiding the need to test for + * tag collision. + */ +static void +send_random_tag_value( + int indx + ) +{ + int noise; + char buf[32]; + + noise = rand() ^ (rand() << 16); + buf[0] = 'a' + noise % 26; + noise >>= 5; + buf[1] = 'a' + noise % 26; + noise >>= 5; + buf[2] = 'a' + noise % 26; + noise >>= 5; + buf[3] = '.'; + snprintf(&buf[4], sizeof(buf) - 4, "%d", indx); + ctl_putuint(buf, noise); +} + + +/* + * Send a MRU list entry in response to a "ntpq -c mrulist" operation. + * + * To keep clients honest about not depending on the order of values, + * and thereby avoid being locked into ugly workarounds to maintain + * backward compatibility later as new fields are added to the response, + * the order is random. + */ +static void +send_mru_entry( + mon_entry * mon, + int count + ) +{ + const char first_fmt[] = "first.%d"; + const char ct_fmt[] = "ct.%d"; + const char mv_fmt[] = "mv.%d"; + const char rs_fmt[] = "rs.%d"; + char tag[32]; + u_char sent[6]; /* 6 tag=value pairs */ + u_int32 noise; + u_int which; + u_int remaining; + const char * pch; + + remaining = COUNTOF(sent); + ZERO(sent); + noise = (u_int32)(rand() ^ (rand() << 16)); + while (remaining > 0) { + which = (noise & 7) % COUNTOF(sent); + noise >>= 3; + while (sent[which]) + which = (which + 1) % COUNTOF(sent); + + switch (which) { + + case 0: + snprintf(tag, sizeof(tag), addr_fmt, count); + pch = sptoa(&mon->rmtadr); + ctl_putunqstr(tag, pch, strlen(pch)); + break; + + case 1: + snprintf(tag, sizeof(tag), last_fmt, count); + ctl_putts(tag, &mon->last); + break; + + case 2: + snprintf(tag, sizeof(tag), first_fmt, count); + ctl_putts(tag, &mon->first); + break; + + case 3: + snprintf(tag, sizeof(tag), ct_fmt, count); + ctl_putint(tag, mon->count); + break; + + case 4: + snprintf(tag, sizeof(tag), mv_fmt, count); + ctl_putuint(tag, mon->vn_mode); + break; + + case 5: + snprintf(tag, sizeof(tag), rs_fmt, count); + ctl_puthex(tag, mon->flags); + break; + } + sent[which] = TRUE; + remaining--; + } +} + + +/* + * read_mru_list - supports ntpq's mrulist command. + * + * The challenge here is to match ntpdc's monlist functionality without + * being limited to hundreds of entries returned total, and without + * requiring state on the server. If state were required, ntpq's + * mrulist command would require authentication. + * + * The approach was suggested by Ry Jones. A finite and variable number + * of entries are retrieved per request, to avoid having responses with + * such large numbers of packets that socket buffers are overflowed and + * packets lost. The entries are retrieved oldest-first, taking into + * account that the MRU list will be changing between each request. We + * can expect to see duplicate entries for addresses updated in the MRU + * list during the fetch operation. In the end, the client can assemble + * a close approximation of the MRU list at the point in time the last + * response was sent by ntpd. The only difference is it may be longer, + * containing some number of oldest entries which have since been + * reclaimed. If necessary, the protocol could be extended to zap those + * from the client snapshot at the end, but so far that doesn't seem + * useful. + * + * To accomodate the changing MRU list, the starting point for requests + * after the first request is supplied as a series of last seen + * timestamps and associated addresses, the newest ones the client has + * received. As long as at least one of those entries hasn't been + * bumped to the head of the MRU list, ntpd can pick up at that point. + * Otherwise, the request is failed and it is up to ntpq to back up and + * provide the next newest entry's timestamps and addresses, conceivably + * backing up all the way to the starting point. + * + * input parameters: + * nonce= Regurgitated nonce retrieved by the client + * previously using CTL_OP_REQ_NONCE, demonstrating + * ability to receive traffic sent to its address. + * frags= Limit on datagrams (fragments) in response. Used + * by newer ntpq versions instead of limit= when + * retrieving multiple entries. + * limit= Limit on MRU entries returned. One of frags= or + * limit= must be provided. + * limit=1 is a special case: Instead of fetching + * beginning with the supplied starting point's + * newer neighbor, fetch the supplied entry, and + * in that case the #.last timestamp can be zero. + * This enables fetching a single entry by IP + * address. When limit is not one and frags= is + * provided, the fragment limit controls. + * mincount= (decimal) Return entries with count >= mincount. + * laddr= Return entries associated with the server's IP + * address given. No port specification is needed, + * and any supplied is ignored. + * resall= 0x-prefixed hex restrict bits which must all be + * lit for an MRU entry to be included. + * Has precedence over any resany=. + * resany= 0x-prefixed hex restrict bits, at least one of + * which must be list for an MRU entry to be + * included. + * last.0= 0x-prefixed hex l_fp timestamp of newest entry + * which client previously received. + * addr.0= text of newest entry's IP address and port, + * IPv6 addresses in bracketed form: [::]:123 + * last.1= timestamp of 2nd newest entry client has. + * addr.1= address of 2nd newest entry. + * [...] + * + * ntpq provides as many last/addr pairs as will fit in a single request + * packet, except for the first request in a MRU fetch operation. + * + * The response begins with a new nonce value to be used for any + * followup request. Following the nonce is the next newer entry than + * referred to by last.0 and addr.0, if the "0" entry has not been + * bumped to the front. If it has, the first entry returned will be the + * next entry newer than referred to by last.1 and addr.1, and so on. + * If none of the referenced entries remain unchanged, the request fails + * and ntpq backs up to the next earlier set of entries to resync. + * + * Except for the first response, the response begins with confirmation + * of the entry that precedes the first additional entry provided: + * + * last.older= hex l_fp timestamp matching one of the input + * .last timestamps, which entry now precedes the + * response 0. entry in the MRU list. + * addr.older= text of address corresponding to older.last. + * + * And in any case, a successful response contains sets of values + * comprising entries, with the oldest numbered 0 and incrementing from + * there: + * + * addr.# text of IPv4 or IPv6 address and port + * last.# hex l_fp timestamp of last receipt + * first.# hex l_fp timestamp of first receipt + * ct.# count of packets received + * mv.# mode and version + * rs.# restriction mask (RES_* bits) + * + * Note the code currently assumes there are no valid three letter + * tags sent with each row, and needs to be adjusted if that changes. + * + * The client should accept the values in any order, and ignore .# + * values which it does not understand, to allow a smooth path to + * future changes without requiring a new opcode. Clients can rely + * on all *.0 values preceding any *.1 values, that is all values for + * a given index number are together in the response. + * + * The end of the response list is noted with one or two tag=value + * pairs. Unconditionally: + * + * now= 0x-prefixed l_fp timestamp at the server marking + * the end of the operation. + * + * If any entries were returned, now= is followed by: + * + * last.newest= hex l_fp identical to last.# of the prior + * entry. + */ +static void read_mru_list( + struct recvbuf *rbufp, + int restrict_mask + ) +{ + const char nonce_text[] = "nonce"; + const char frags_text[] = "frags"; + const char limit_text[] = "limit"; + const char mincount_text[] = "mincount"; + const char resall_text[] = "resall"; + const char resany_text[] = "resany"; + const char maxlstint_text[] = "maxlstint"; + const char laddr_text[] = "laddr"; + const char resaxx_fmt[] = "0x%hx"; + u_int limit; + u_short frags; + u_short resall; + u_short resany; + int mincount; + u_int maxlstint; + sockaddr_u laddr; + struct interface * lcladr; + u_int count; + u_int ui; + u_int uf; + l_fp last[16]; + sockaddr_u addr[COUNTOF(last)]; + char buf[128]; + struct ctl_var * in_parms; + const struct ctl_var * v; + char * val; + const char * pch; + char * pnonce; + int nonce_valid; + size_t i; + int priors; + u_short hash; + mon_entry * mon; + mon_entry * prior_mon; + l_fp now; + + if (RES_NOMRULIST & restrict_mask) { + ctl_error(CERR_PERMISSION); + NLOG(NLOG_SYSINFO) + msyslog(LOG_NOTICE, + "mrulist from %s rejected due to nomrulist restriction", + stoa(&rbufp->recv_srcadr)); + sys_restricted++; + return; + } + /* + * fill in_parms var list with all possible input parameters. + */ + in_parms = NULL; + set_var(&in_parms, nonce_text, sizeof(nonce_text), 0); + set_var(&in_parms, frags_text, sizeof(frags_text), 0); + set_var(&in_parms, limit_text, sizeof(limit_text), 0); + set_var(&in_parms, mincount_text, sizeof(mincount_text), 0); + set_var(&in_parms, resall_text, sizeof(resall_text), 0); + set_var(&in_parms, resany_text, sizeof(resany_text), 0); + set_var(&in_parms, maxlstint_text, sizeof(maxlstint_text), 0); + set_var(&in_parms, laddr_text, sizeof(laddr_text), 0); + for (i = 0; i < COUNTOF(last); i++) { + snprintf(buf, sizeof(buf), last_fmt, (int)i); + set_var(&in_parms, buf, strlen(buf) + 1, 0); + snprintf(buf, sizeof(buf), addr_fmt, (int)i); + set_var(&in_parms, buf, strlen(buf) + 1, 0); + } + + /* decode input parms */ + pnonce = NULL; + frags = 0; + limit = 0; + mincount = 0; + resall = 0; + resany = 0; + maxlstint = 0; + lcladr = NULL; + priors = 0; + ZERO(last); + ZERO(addr); + + while (NULL != (v = ctl_getitem(in_parms, &val)) && + !(EOV & v->flags)) { + int si; + + if (!strcmp(nonce_text, v->text)) { + if (NULL != pnonce) + free(pnonce); + pnonce = estrdup(val); + } else if (!strcmp(frags_text, v->text)) { + sscanf(val, "%hu", &frags); + } else if (!strcmp(limit_text, v->text)) { + sscanf(val, "%u", &limit); + } else if (!strcmp(mincount_text, v->text)) { + if (1 != sscanf(val, "%d", &mincount) || + mincount < 0) + mincount = 0; + } else if (!strcmp(resall_text, v->text)) { + sscanf(val, resaxx_fmt, &resall); + } else if (!strcmp(resany_text, v->text)) { + sscanf(val, resaxx_fmt, &resany); + } else if (!strcmp(maxlstint_text, v->text)) { + sscanf(val, "%u", &maxlstint); + } else if (!strcmp(laddr_text, v->text)) { + if (decodenetnum(val, &laddr)) + lcladr = getinterface(&laddr, 0); + } else if (1 == sscanf(v->text, last_fmt, &si) && + (size_t)si < COUNTOF(last)) { + if (2 == sscanf(val, "0x%08x.%08x", &ui, &uf)) { + last[si].l_ui = ui; + last[si].l_uf = uf; + if (!SOCK_UNSPEC(&addr[si]) && + si == priors) + priors++; + } + } else if (1 == sscanf(v->text, addr_fmt, &si) && + (size_t)si < COUNTOF(addr)) { + if (decodenetnum(val, &addr[si]) + && last[si].l_ui && last[si].l_uf && + si == priors) + priors++; + } + } + free_varlist(in_parms); + in_parms = NULL; + + /* return no responses until the nonce is validated */ + if (NULL == pnonce) + return; + + nonce_valid = validate_nonce(pnonce, rbufp); + free(pnonce); + if (!nonce_valid) + return; + + if ((0 == frags && !(0 < limit && limit <= MRU_ROW_LIMIT)) || + frags > MRU_FRAGS_LIMIT) { + ctl_error(CERR_BADVALUE); + return; + } + + /* + * If either frags or limit is not given, use the max. + */ + if (0 != frags && 0 == limit) + limit = UINT_MAX; + else if (0 != limit && 0 == frags) + frags = MRU_FRAGS_LIMIT; + + /* + * Find the starting point if one was provided. + */ + mon = NULL; + for (i = 0; i < (size_t)priors; i++) { + hash = MON_HASH(&addr[i]); + for (mon = mon_hash[hash]; + mon != NULL; + mon = mon->hash_next) + if (ADDR_PORT_EQ(&mon->rmtadr, &addr[i])) + break; + if (mon != NULL) { + if (L_ISEQU(&mon->last, &last[i])) + break; + mon = NULL; + } + } + + /* If a starting point was provided... */ + if (priors) { + /* and none could be found unmodified... */ + if (NULL == mon) { + /* tell ntpq to try again with older entries */ + ctl_error(CERR_UNKNOWNVAR); + return; + } + /* confirm the prior entry used as starting point */ + ctl_putts("last.older", &mon->last); + pch = sptoa(&mon->rmtadr); + ctl_putunqstr("addr.older", pch, strlen(pch)); + + /* + * Move on to the first entry the client doesn't have, + * except in the special case of a limit of one. In + * that case return the starting point entry. + */ + if (limit > 1) + mon = PREV_DLIST(mon_mru_list, mon, mru); + } else { /* start with the oldest */ + mon = TAIL_DLIST(mon_mru_list, mru); + } + + /* + * send up to limit= entries in up to frags= datagrams + */ + get_systime(&now); + generate_nonce(rbufp, buf, sizeof(buf)); + ctl_putunqstr("nonce", buf, strlen(buf)); + prior_mon = NULL; + for (count = 0; + mon != NULL && res_frags < frags && count < limit; + mon = PREV_DLIST(mon_mru_list, mon, mru)) { + + if (mon->count < mincount) + continue; + if (resall && resall != (resall & mon->flags)) + continue; + if (resany && !(resany & mon->flags)) + continue; + if (maxlstint > 0 && now.l_ui - mon->last.l_ui > + maxlstint) + continue; + if (lcladr != NULL && mon->lcladr != lcladr) + continue; + + send_mru_entry(mon, count); + if (!count) + send_random_tag_value(0); + count++; + prior_mon = mon; + } + + /* + * If this batch completes the MRU list, say so explicitly with + * a now= l_fp timestamp. + */ + if (NULL == mon) { + if (count > 1) + send_random_tag_value(count - 1); + ctl_putts("now", &now); + /* if any entries were returned confirm the last */ + if (prior_mon != NULL) + ctl_putts("last.newest", &prior_mon->last); + } + ctl_flushpkt(0); +} + + +/* + * Send a ifstats entry in response to a "ntpq -c ifstats" request. + * + * To keep clients honest about not depending on the order of values, + * and thereby avoid being locked into ugly workarounds to maintain + * backward compatibility later as new fields are added to the response, + * the order is random. + */ +static void +send_ifstats_entry( + endpt * la, + u_int ifnum + ) +{ + const char addr_fmtu[] = "addr.%u"; + const char bcast_fmt[] = "bcast.%u"; + const char en_fmt[] = "en.%u"; /* enabled */ + const char name_fmt[] = "name.%u"; + const char flags_fmt[] = "flags.%u"; + const char tl_fmt[] = "tl.%u"; /* ttl */ + const char mc_fmt[] = "mc.%u"; /* mcast count */ + const char rx_fmt[] = "rx.%u"; + const char tx_fmt[] = "tx.%u"; + const char txerr_fmt[] = "txerr.%u"; + const char pc_fmt[] = "pc.%u"; /* peer count */ + const char up_fmt[] = "up.%u"; /* uptime */ + char tag[32]; + u_char sent[IFSTATS_FIELDS]; /* 12 tag=value pairs */ + int noisebits; + u_int32 noise; + u_int which; + u_int remaining; + const char *pch; + + remaining = COUNTOF(sent); + ZERO(sent); + noise = 0; + noisebits = 0; + while (remaining > 0) { + if (noisebits < 4) { + noise = rand() ^ (rand() << 16); + noisebits = 31; + } + which = (noise & 0xf) % COUNTOF(sent); + noise >>= 4; + noisebits -= 4; + + while (sent[which]) + which = (which + 1) % COUNTOF(sent); + + switch (which) { + + case 0: + snprintf(tag, sizeof(tag), addr_fmtu, ifnum); + pch = sptoa(&la->sin); + ctl_putunqstr(tag, pch, strlen(pch)); + break; + + case 1: + snprintf(tag, sizeof(tag), bcast_fmt, ifnum); + if (INT_BCASTOPEN & la->flags) + pch = sptoa(&la->bcast); + else + pch = ""; + ctl_putunqstr(tag, pch, strlen(pch)); + break; + + case 2: + snprintf(tag, sizeof(tag), en_fmt, ifnum); + ctl_putint(tag, !la->ignore_packets); + break; + + case 3: + snprintf(tag, sizeof(tag), name_fmt, ifnum); + ctl_putstr(tag, la->name, strlen(la->name)); + break; + + case 4: + snprintf(tag, sizeof(tag), flags_fmt, ifnum); + ctl_puthex(tag, (u_int)la->flags); + break; + + case 5: + snprintf(tag, sizeof(tag), tl_fmt, ifnum); + ctl_putint(tag, la->last_ttl); + break; + + case 6: + snprintf(tag, sizeof(tag), mc_fmt, ifnum); + ctl_putint(tag, la->num_mcast); + break; + + case 7: + snprintf(tag, sizeof(tag), rx_fmt, ifnum); + ctl_putint(tag, la->received); + break; + + case 8: + snprintf(tag, sizeof(tag), tx_fmt, ifnum); + ctl_putint(tag, la->sent); + break; + + case 9: + snprintf(tag, sizeof(tag), txerr_fmt, ifnum); + ctl_putint(tag, la->notsent); + break; + + case 10: + snprintf(tag, sizeof(tag), pc_fmt, ifnum); + ctl_putuint(tag, la->peercnt); + break; + + case 11: + snprintf(tag, sizeof(tag), up_fmt, ifnum); + ctl_putuint(tag, current_time - la->starttime); + break; + } + sent[which] = TRUE; + remaining--; + } + send_random_tag_value((int)ifnum); +} + + +/* + * read_ifstats - send statistics for each local address, exposed by + * ntpq -c ifstats + */ +static void +read_ifstats( + struct recvbuf * rbufp + ) +{ + u_int ifidx; + endpt * la; + + /* + * loop over [0..sys_ifnum] searching ep_list for each + * ifnum in turn. + */ + for (ifidx = 0; ifidx < sys_ifnum; ifidx++) { + for (la = ep_list; la != NULL; la = la->elink) + if (ifidx == la->ifnum) + break; + if (NULL == la) + continue; + /* return stats for one local address */ + send_ifstats_entry(la, ifidx); + } + ctl_flushpkt(0); +} + +static void +sockaddrs_from_restrict_u( + sockaddr_u * psaA, + sockaddr_u * psaM, + restrict_u * pres, + int ipv6 + ) +{ + ZERO(*psaA); + ZERO(*psaM); + if (!ipv6) { + psaA->sa.sa_family = AF_INET; + psaA->sa4.sin_addr.s_addr = htonl(pres->u.v4.addr); + psaM->sa.sa_family = AF_INET; + psaM->sa4.sin_addr.s_addr = htonl(pres->u.v4.mask); + } else { + psaA->sa.sa_family = AF_INET6; + memcpy(&psaA->sa6.sin6_addr, &pres->u.v6.addr, + sizeof(psaA->sa6.sin6_addr)); + psaM->sa.sa_family = AF_INET6; + memcpy(&psaM->sa6.sin6_addr, &pres->u.v6.mask, + sizeof(psaA->sa6.sin6_addr)); + } +} + + +/* + * Send a restrict entry in response to a "ntpq -c reslist" request. + * + * To keep clients honest about not depending on the order of values, + * and thereby avoid being locked into ugly workarounds to maintain + * backward compatibility later as new fields are added to the response, + * the order is random. + */ +static void +send_restrict_entry( + restrict_u * pres, + int ipv6, + u_int idx + ) +{ + const char addr_fmtu[] = "addr.%u"; + const char mask_fmtu[] = "mask.%u"; + const char hits_fmt[] = "hits.%u"; + const char flags_fmt[] = "flags.%u"; + char tag[32]; + u_char sent[RESLIST_FIELDS]; /* 4 tag=value pairs */ + int noisebits; + u_int32 noise; + u_int which; + u_int remaining; + sockaddr_u addr; + sockaddr_u mask; + const char * pch; + char * buf; + const char * match_str; + const char * access_str; + + sockaddrs_from_restrict_u(&addr, &mask, pres, ipv6); + remaining = COUNTOF(sent); + ZERO(sent); + noise = 0; + noisebits = 0; + while (remaining > 0) { + if (noisebits < 2) { + noise = rand() ^ (rand() << 16); + noisebits = 31; + } + which = (noise & 0x3) % COUNTOF(sent); + noise >>= 2; + noisebits -= 2; + + while (sent[which]) + which = (which + 1) % COUNTOF(sent); + + switch (which) { + + case 0: + snprintf(tag, sizeof(tag), addr_fmtu, idx); + pch = stoa(&addr); + ctl_putunqstr(tag, pch, strlen(pch)); + break; + + case 1: + snprintf(tag, sizeof(tag), mask_fmtu, idx); + pch = stoa(&mask); + ctl_putunqstr(tag, pch, strlen(pch)); + break; + + case 2: + snprintf(tag, sizeof(tag), hits_fmt, idx); + ctl_putuint(tag, pres->count); + break; + + case 3: + snprintf(tag, sizeof(tag), flags_fmt, idx); + match_str = res_match_flags(pres->mflags); + access_str = res_access_flags(pres->flags); + if ('\0' == match_str[0]) { + pch = access_str; + } else { + LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%s %s", + match_str, access_str); + pch = buf; + } + ctl_putunqstr(tag, pch, strlen(pch)); + break; } + sent[which] = TRUE; + remaining--; + } + send_random_tag_value((int)idx); +} - if (n != 0) - ctl_putdata((char *)ass_stat, n * - sizeof(u_short), 1); - ctl_flushpkt(0); - } else { - peer = findpeerbyassoc(res_associd); - if (peer == 0) { - ctl_error(CERR_BADASSOC); - } else { - register u_char *cp; - rpkt.status = htons(ctlpeerstatus(peer)); - if (res_authokay) - peer->num_events = 0; - /* - * For now, output everything we know about the - * peer. May be more selective later. - */ - for (cp = def_peer_var; *cp != 0; cp++) - ctl_putpeer((int)*cp, peer); - ctl_flushpkt(0); - } +static void +send_restrict_list( + restrict_u * pres, + int ipv6, + u_int * pidx + ) +{ + for ( ; pres != NULL; pres = pres->link) { + send_restrict_entry(pres, ipv6, *pidx); + (*pidx)++; } } /* - * read_variables - return the variables the caller asks for + * read_addr_restrictions - returns IPv4 and IPv6 access control lists */ -/*ARGSUSED*/ static void -read_variables( - struct recvbuf *rbufp, - int restrict_mask - ) +read_addr_restrictions( + struct recvbuf * rbufp +) { - register struct ctl_var *v; - register int i; - char *valuep; - u_char *wants; - unsigned int gotvar = (CS_MAXCODE > CP_MAXCODE) ? (CS_MAXCODE + - 1) : (CP_MAXCODE + 1); - if (res_associd == 0) { - /* - * Wants system variables. Figure out which he wants - * and give them to him. - */ - rpkt.status = htons(ctlsysstatus()); - if (res_authokay) - ctl_sys_num_events = 0; - gotvar += count_var(ext_sys_var); - wants = (u_char *)emalloc(gotvar); - memset((char *)wants, 0, gotvar); - gotvar = 0; - while ((v = ctl_getitem(sys_var, &valuep)) != 0) { - if (v->flags & EOV) { - if ((v = ctl_getitem(ext_sys_var, - &valuep)) != 0) { - if (v->flags & EOV) { - ctl_error(CERR_UNKNOWNVAR); - free((char *)wants); - return; - } - wants[CS_MAXCODE + 1 + - v->code] = 1; - gotvar = 1; - continue; - } else { - break; /* shouldn't happen ! */ - } - } - wants[v->code] = 1; - gotvar = 1; - } - if (gotvar) { - for (i = 1; i <= CS_MAXCODE; i++) - if (wants[i]) - ctl_putsys(i); - for (i = 0; ext_sys_var && - !(ext_sys_var[i].flags & EOV); i++) - if (wants[i + CS_MAXCODE + 1]) - ctl_putdata(ext_sys_var[i].text, - strlen(ext_sys_var[i].text), - 0); - } else { - register u_char *cs; - register struct ctl_var *kv; - - for (cs = def_sys_var; *cs != 0; cs++) - ctl_putsys((int)*cs); - for (kv = ext_sys_var; kv && !(kv->flags & EOV); - kv++) - if (kv->flags & DEF) - ctl_putdata(kv->text, - strlen(kv->text), 0); - } - free((char *)wants); - } else { - register struct peer *peer; - - /* - * Wants info for a particular peer. See if we know - * the guy. - */ - peer = findpeerbyassoc(res_associd); - if (peer == 0) { - ctl_error(CERR_BADASSOC); - return; - } - rpkt.status = htons(ctlpeerstatus(peer)); - if (res_authokay) - peer->num_events = 0; - wants = (u_char *)emalloc(gotvar); - memset((char*)wants, 0, gotvar); - gotvar = 0; - while ((v = ctl_getitem(peer_var, &valuep)) != 0) { - if (v->flags & EOV) { - ctl_error(CERR_UNKNOWNVAR); - free((char *)wants); - return; - } - wants[v->code] = 1; - gotvar = 1; - } - if (gotvar) { - for (i = 1; i <= CP_MAXCODE; i++) - if (wants[i]) - ctl_putpeer(i, peer); - } else { - register u_char *cp; + u_int idx; - for (cp = def_peer_var; *cp != 0; cp++) - ctl_putpeer((int)*cp, peer); - } - free((char *)wants); - } + idx = 0; + send_restrict_list(restrictlist4, FALSE, &idx); + send_restrict_list(restrictlist6, TRUE, &idx); ctl_flushpkt(0); } /* - * write_variables - write into variables. We only allow leap bit - * writing this way. + * read_ordlist - CTL_OP_READ_ORDLIST_A for ntpq -c ifstats & reslist */ -/*ARGSUSED*/ static void -write_variables( - struct recvbuf *rbufp, - int restrict_mask +read_ordlist( + struct recvbuf * rbufp, + int restrict_mask ) { - register struct ctl_var *v; - register int ext_var; - char *valuep; - long val = 0; + const char ifstats_s[] = "ifstats"; + const size_t ifstats_chars = COUNTOF(ifstats_s) - 1; + const char addr_rst_s[] = "addr_restrictions"; + const size_t a_r_chars = COUNTOF(addr_rst_s) - 1; + struct ntp_control * cpkt; + u_short qdata_octets; /* - * If he's trying to write into a peer tell him no way + * CTL_OP_READ_ORDLIST_A was first named CTL_OP_READ_IFSTATS and + * used only for ntpq -c ifstats. With the addition of reslist + * the same opcode was generalized to retrieve ordered lists + * which require authentication. The request data is empty or + * contains "ifstats" (not null terminated) to retrieve local + * addresses and associated stats. It is "addr_restrictions" + * to retrieve the IPv4 then IPv6 remote address restrictions, + * which are access control lists. Other request data return + * CERR_UNKNOWNVAR. */ - if (res_associd != 0) { - ctl_error(CERR_PERMISSION); + cpkt = (struct ntp_control *)&rbufp->recv_pkt; + qdata_octets = ntohs(cpkt->count); + if (0 == qdata_octets || (ifstats_chars == qdata_octets && + !memcmp(ifstats_s, cpkt->u.data, ifstats_chars))) { + read_ifstats(rbufp); return; } + if (a_r_chars == qdata_octets && + !memcmp(addr_rst_s, cpkt->u.data, a_r_chars)) { + read_addr_restrictions(rbufp); + return; + } + ctl_error(CERR_UNKNOWNVAR); +} - /* - * Set status - */ - rpkt.status = htons(ctlsysstatus()); - - /* - * Look through the variables. Dump out at the first sign of - * trouble. - */ - while ((v = ctl_getitem(sys_var, &valuep)) != 0) { - ext_var = 0; - if (v->flags & EOV) { - if ((v = ctl_getitem(ext_sys_var, &valuep)) != - 0) { - if (v->flags & EOV) { - ctl_error(CERR_UNKNOWNVAR); - return; - } - ext_var = 1; - } else { - break; - } - } - if (!(v->flags & CAN_WRITE)) { - ctl_error(CERR_PERMISSION); - return; - } - if (!ext_var && (*valuep == '\0' || !atoint(valuep, - &val))) { - ctl_error(CERR_BADFMT); - return; - } - if (!ext_var && (val & ~LEAP_NOTINSYNC) != 0) { - ctl_error(CERR_BADVALUE); - return; - } - - if (ext_var) { - char *s = (char *)emalloc(strlen(v->text) + - strlen(valuep) + 2); - const char *t; - char *tt = s; - - t = v->text; - while (*t && *t != '=') - *tt++ = *t++; - - *tt++ = '='; - strcat(tt, valuep); - set_sys_var(s, strlen(s)+1, v->flags); - free(s); - } else { - /* - * This one seems sane. Save it. - */ - switch(v->code) { - case CS_LEAP: - default: - ctl_error(CERR_UNSPEC); /* really */ - return; - } - } - } +/* + * req_nonce - CTL_OP_REQ_NONCE for ntpq -c mrulist prerequisite. + */ +static void req_nonce( + struct recvbuf * rbufp, + int restrict_mask + ) +{ + char buf[64]; - /* - * If we got anything, do it. xxx nothing to do *** - */ - /* - if (leapind != ~0 || leapwarn != ~0) { - if (!leap_setleap((int)leapind, (int)leapwarn)) { - ctl_error(CERR_PERMISSION); - return; - } - } - */ + generate_nonce(rbufp, buf, sizeof(buf)); + ctl_putunqstr("nonce", buf, strlen(buf)); ctl_flushpkt(0); } /* - * read_clock_status - return clock radio status + * read_clockstatus - return clock radio status */ /*ARGSUSED*/ static void -read_clock_status( +read_clockstatus( struct recvbuf *rbufp, int restrict_mask ) @@ -2343,108 +4362,91 @@ read_clock_status( */ ctl_error(CERR_BADASSOC); #else - register struct ctl_var *v; - register int i; - register struct peer *peer; - char *valuep; - u_char *wants; - unsigned int gotvar; - struct refclockstat clock_stat; - - if (res_associd == 0) { + const struct ctl_var * v; + int i; + struct peer * peer; + char * valuep; + u_char * wants; + size_t wants_alloc; + int gotvar; + const u_char * cc; + struct ctl_var * kv; + struct refclockstat cs; + if (res_associd != 0) { + peer = findpeerbyassoc(res_associd); + } else { /* * Find a clock for this jerk. If the system peer - * is a clock use it, else search the hash tables - * for one. + * is a clock use it, else search peer_list for one. */ - if (sys_peer != 0 && (sys_peer->flags & FLAG_REFCLOCK)) - { + if (sys_peer != NULL && (FLAG_REFCLOCK & + sys_peer->flags)) peer = sys_peer; - } else { - peer = 0; - for (i = 0; peer == 0 && i < NTP_HASH_SIZE; i++) { - for (peer = assoc_hash[i]; peer != 0; - peer = peer->ass_next) { - if (peer->flags & FLAG_REFCLOCK) - break; - } - } - if (peer == 0) { - ctl_error(CERR_BADASSOC); - return; - } - } - } else { - peer = findpeerbyassoc(res_associd); - if (peer == 0 || !(peer->flags & FLAG_REFCLOCK)) { - ctl_error(CERR_BADASSOC); - return; - } + else + for (peer = peer_list; + peer != NULL; + peer = peer->p_link) + if (FLAG_REFCLOCK & peer->flags) + break; + } + if (NULL == peer || !(FLAG_REFCLOCK & peer->flags)) { + ctl_error(CERR_BADASSOC); + return; } - /* * If we got here we have a peer which is a clock. Get his * status. */ - clock_stat.kv_list = (struct ctl_var *)0; - refclock_control(&peer->srcadr, (struct refclockstat *)0, - &clock_stat); - + cs.kv_list = NULL; + refclock_control(&peer->srcadr, NULL, &cs); + kv = cs.kv_list; /* * Look for variables in the packet. */ - rpkt.status = htons(ctlclkstatus(&clock_stat)); - gotvar = CC_MAXCODE + 1 + count_var(clock_stat.kv_list); - wants = (u_char *)emalloc(gotvar); - memset((char*)wants, 0, gotvar); - gotvar = 0; - while ((v = ctl_getitem(clock_var, &valuep)) != 0) { - if (v->flags & EOV) { - if ((v = ctl_getitem(clock_stat.kv_list, - &valuep)) != 0) { - if (v->flags & EOV) { - ctl_error(CERR_UNKNOWNVAR); - free((char*)wants); - free_varlist(clock_stat.kv_list); - return; - } - wants[CC_MAXCODE + 1 + v->code] = 1; - gotvar = 1; - continue; - } else { - break; /* shouldn't happen ! */ + rpkt.status = htons(ctlclkstatus(&cs)); + wants_alloc = CC_MAXCODE + 1 + count_var(kv); + wants = emalloc_zero(wants_alloc); + gotvar = FALSE; + while (NULL != (v = ctl_getitem(clock_var, &valuep))) { + if (!(EOV & v->flags)) { + wants[v->code] = TRUE; + gotvar = TRUE; + } else { + v = ctl_getitem(kv, &valuep); + INSIST(NULL != v); + if (EOV & v->flags) { + ctl_error(CERR_UNKNOWNVAR); + free(wants); + free_varlist(cs.kv_list); + return; } + wants[CC_MAXCODE + 1 + v->code] = TRUE; + gotvar = TRUE; } - wants[v->code] = 1; - gotvar = 1; } if (gotvar) { for (i = 1; i <= CC_MAXCODE; i++) if (wants[i]) - ctl_putclock(i, &clock_stat, 1); - for (i = 0; clock_stat.kv_list && - !(clock_stat.kv_list[i].flags & EOV); i++) - if (wants[i + CC_MAXCODE + 1]) - ctl_putdata(clock_stat.kv_list[i].text, - strlen(clock_stat.kv_list[i].text), - 0); + ctl_putclock(i, &cs, TRUE); + if (kv != NULL) + for (i = 0; !(EOV & kv[i].flags); i++) + if (wants[i + CC_MAXCODE + 1]) + ctl_putdata(kv[i].text, + strlen(kv[i].text), + FALSE); } else { - register u_char *cc; - register struct ctl_var *kv; - for (cc = def_clock_var; *cc != 0; cc++) - ctl_putclock((int)*cc, &clock_stat, 0); - for (kv = clock_stat.kv_list; kv && !(kv->flags & EOV); - kv++) - if (kv->flags & DEF) + ctl_putclock((int)*cc, &cs, FALSE); + for ( ; kv != NULL && !(EOV & kv->flags); kv++) + if (DEF & kv->flags) ctl_putdata(kv->text, strlen(kv->text), - 0); + FALSE); } - free((char*)wants); - free_varlist(clock_stat.kv_list); + free(wants); + free_varlist(cs.kv_list); ctl_flushpkt(0); #endif @@ -2452,11 +4454,11 @@ read_clock_status( /* - * write_clock_status - we don't do this + * write_clockstatus - we don't do this */ /*ARGSUSED*/ static void -write_clock_status( +write_clockstatus( struct recvbuf *rbufp, int restrict_mask ) @@ -2500,7 +4502,7 @@ set_trap( * an error if it can't assign the trap. */ if (!ctlsettrap(&rbufp->recv_srcadr, rbufp->dstadr, traptype, - (int)res_version)) + (int)res_version)) ctl_error(CERR_NORESOURCE); ctl_flushpkt(0); } @@ -2541,14 +4543,15 @@ unset_trap( */ int ctlsettrap( - struct sockaddr_storage *raddr, + sockaddr_u *raddr, struct interface *linter, int traptype, int version ) { - register struct ctl_trap *tp; - register struct ctl_trap *tptouse; + size_t n; + struct ctl_trap *tp; + struct ctl_trap *tptouse; /* * See if we can find this trap. If so, we only need update @@ -2584,16 +4587,17 @@ ctlsettrap( * have to. Clear out anyone who's expired while we're at it. */ tptouse = NULL; - for (tp = ctl_trap; tp < &ctl_trap[CTL_MAXTRAPS]; tp++) { - if ((tp->tr_flags & TRAP_INUSE) && - !(tp->tr_flags & TRAP_CONFIGURED) && + for (n = 0; n < COUNTOF(ctl_traps); n++) { + tp = &ctl_traps[n]; + if ((TRAP_INUSE & tp->tr_flags) && + !(TRAP_CONFIGURED & tp->tr_flags) && ((tp->tr_settime + CTL_TRAPTIME) > current_time)) { tp->tr_flags = 0; num_ctl_traps--; } - if (!(tp->tr_flags & TRAP_INUSE)) { + if (!(TRAP_INUSE & tp->tr_flags)) { tptouse = tp; - } else if (!(tp->tr_flags & TRAP_CONFIGURED)) { + } else if (!(TRAP_CONFIGURED & tp->tr_flags)) { switch (traptype) { case TRAP_TYPE_CONFIG: @@ -2601,12 +4605,12 @@ ctlsettrap( tptouse = tp; break; } - if (tptouse->tr_flags & TRAP_NONPRIO && - !(tp->tr_flags & TRAP_NONPRIO)) + if ((TRAP_NONPRIO & tptouse->tr_flags) && + !(TRAP_NONPRIO & tp->tr_flags)) break; - if (!(tptouse->tr_flags & TRAP_NONPRIO) - && tp->tr_flags & TRAP_NONPRIO) { + if (!(TRAP_NONPRIO & tptouse->tr_flags) + && (TRAP_NONPRIO & tp->tr_flags)) { tptouse = tp; break; } @@ -2616,12 +4620,12 @@ ctlsettrap( break; case TRAP_TYPE_PRIO: - if (tp->tr_flags & TRAP_NONPRIO) { + if ( TRAP_NONPRIO & tp->tr_flags) { if (tptouse == NULL || - (tptouse->tr_flags & - TRAP_INUSE && - tptouse->tr_origtime < - tp->tr_origtime)) + ((TRAP_INUSE & + tptouse->tr_flags) && + tptouse->tr_origtime < + tp->tr_origtime)) tptouse = tp; } break; @@ -2662,7 +4666,7 @@ ctlsettrap( */ int ctlclrtrap( - struct sockaddr_storage *raddr, + sockaddr_u *raddr, struct interface *linter, int traptype ) @@ -2673,7 +4677,7 @@ ctlclrtrap( return (0); if (tp->tr_flags & TRAP_CONFIGURED - && traptype != TRAP_TYPE_CONFIG) + && traptype != TRAP_TYPE_CONFIG) return (0); tp->tr_flags = 0; @@ -2687,20 +4691,19 @@ ctlclrtrap( */ static struct ctl_trap * ctlfindtrap( - struct sockaddr_storage *raddr, + sockaddr_u *raddr, struct interface *linter ) { - register struct ctl_trap *tp; + size_t n; - for (tp = ctl_trap; tp < &ctl_trap[CTL_MAXTRAPS]; tp++) { - if ((tp->tr_flags & TRAP_INUSE) - && (NSRCPORT(raddr) == NSRCPORT(&tp->tr_addr)) - && SOCKCMP(raddr, &tp->tr_addr) - && (linter == tp->tr_localaddr) ) - return (tp); - } - return (struct ctl_trap *)NULL; + for (n = 0; n < COUNTOF(ctl_traps); n++) + if ((ctl_traps[n].tr_flags & TRAP_INUSE) + && ADDR_PORT_EQ(raddr, &ctl_traps[n].tr_addr) + && (linter == ctl_traps[n].tr_localaddr)) + return &ctl_traps[n]; + + return NULL; } @@ -2709,69 +4712,80 @@ ctlfindtrap( */ void report_event( - int err, - struct peer *peer + int err, /* error code */ + struct peer *peer, /* peer structure pointer */ + const char *str /* protostats string */ ) { - register int i; + char statstr[NTP_MAXSTRLEN]; + int i; + size_t len; /* - * Record error code in proper spots, but have mercy on the - * log file. + * Report the error to the protostats file, system log and + * trappers. */ - if (!(err & (PEER_EVENT | CRPT_EVENT))) { - if (ctl_sys_num_events < CTL_SYS_MAXEVENTS) - ctl_sys_num_events++; - if (ctl_sys_last_event != (u_char)err) { - NLOG(NLOG_SYSEVENT) - msyslog(LOG_INFO, "system event '%s' (0x%02x) status '%s' (0x%02x)", - eventstr(err), err, - sysstatstr(ctlsysstatus()), ctlsysstatus()); -#ifdef DEBUG - if (debug) - printf("report_event: system event '%s' (0x%02x) status '%s' (0x%02x)\n", - eventstr(err), err, - sysstatstr(ctlsysstatus()), - ctlsysstatus()); -#endif - ctl_sys_last_event = (u_char)err; + if (peer == NULL) { + + /* + * Discard a system report if the number of reports of + * the same type exceeds the maximum. + */ + if (ctl_sys_last_event != (u_char)err) + ctl_sys_num_events= 0; + if (ctl_sys_num_events >= CTL_SYS_MAXEVENTS) + return; + + ctl_sys_last_event = (u_char)err; + ctl_sys_num_events++; + snprintf(statstr, sizeof(statstr), + "0.0.0.0 %04x %02x %s", + ctlsysstatus(), err, eventstr(err)); + if (str != NULL) { + len = strlen(statstr); + snprintf(statstr + len, sizeof(statstr) - len, + " %s", str); } - } else if (peer != 0) { - char *src; + NLOG(NLOG_SYSEVENT) + msyslog(LOG_INFO, "%s", statstr); + } else { -#ifdef REFCLOCK + /* + * Discard a peer report if the number of reports of + * the same type exceeds the maximum for that peer. + */ + const char * src; + u_char errlast; + + errlast = (u_char)err & ~PEER_EVENT; + if (peer->last_event == errlast) + peer->num_events = 0; + if (peer->num_events >= CTL_PEER_MAXEVENTS) + return; + + peer->last_event = errlast; + peer->num_events++; if (ISREFCLOCKADR(&peer->srcadr)) src = refnumtoa(&peer->srcadr); else -#endif src = stoa(&peer->srcadr); - peer->last_event = (u_char)(err & ~PEER_EVENT); - if (peer->num_events < CTL_PEER_MAXEVENTS) - peer->num_events++; + snprintf(statstr, sizeof(statstr), + "%s %04x %02x %s", src, + ctlpeerstatus(peer), err, eventstr(err)); + if (str != NULL) { + len = strlen(statstr); + snprintf(statstr + len, sizeof(statstr) - len, + " %s", str); + } NLOG(NLOG_PEEREVENT) - msyslog(LOG_INFO, "peer %s event '%s' (0x%02x) status '%s' (0x%02x)", - src, eventstr(err), err, - peerstatstr(ctlpeerstatus(peer)), - ctlpeerstatus(peer)); -#ifdef DEBUG - if (debug) - printf( "peer %s event '%s' (0x%02x) status '%s' (0x%02x)\n", - src, eventstr(err), err, - peerstatstr(ctlpeerstatus(peer)), - ctlpeerstatus(peer)); -#endif - } else { - msyslog(LOG_ERR, - "report_event: err '%s' (0x%02x), no peer", - eventstr(err), err); -#ifdef DEBUG - printf( - "report_event: peer event '%s' (0x%02x), no peer\n", - eventstr(err), err); -#endif - return; + msyslog(LOG_INFO, "%s", statstr); } + record_proto_stats(statstr); +#if DEBUG + if (debug) + printf("event at %lu %s\n", current_time, statstr); +#endif /* * If no trappers, return. @@ -2784,87 +4798,50 @@ report_event( */ res_opcode = CTL_OP_ASYNCMSG; res_offset = 0; - res_async = 1; - res_authenticate = 0; - datapt = rpkt.data; - dataend = &(rpkt.data[CTL_MAX_DATA_LEN]); + res_async = TRUE; + res_authenticate = FALSE; + datapt = rpkt.u.data; + dataend = &rpkt.u.data[CTL_MAX_DATA_LEN]; if (!(err & PEER_EVENT)) { rpkt.associd = 0; rpkt.status = htons(ctlsysstatus()); - /* - * For now, put everything we know about system - * variables. Don't send crypto strings. - */ - for (i = 1; i <= CS_MAXCODE; i++) { -#ifdef OPENSSL - if (i > CS_VARLIST) - continue; -#endif /* OPENSSL */ + /* Include the core system variables and the list. */ + for (i = 1; i <= CS_VARLIST; i++) ctl_putsys(i); - } -#ifdef REFCLOCK - /* - * for clock exception events: add clock variables to - * reflect info on exception - */ - if (err == EVNT_CLOCKEXCPT) { - struct refclockstat clock_stat; - struct ctl_var *kv; - - clock_stat.kv_list = (struct ctl_var *)0; - refclock_control(&peer->srcadr, - (struct refclockstat *)0, &clock_stat); - ctl_puthex("refclockstatus", - ctlclkstatus(&clock_stat)); - for (i = 1; i <= CC_MAXCODE; i++) - ctl_putclock(i, &clock_stat, 0); - for (kv = clock_stat.kv_list; kv && - !(kv->flags & EOV); kv++) - if (kv->flags & DEF) - ctl_putdata(kv->text, - strlen(kv->text), 0); - free_varlist(clock_stat.kv_list); - } -#endif /* REFCLOCK */ } else { + INSIST(peer != NULL); rpkt.associd = htons(peer->associd); rpkt.status = htons(ctlpeerstatus(peer)); - /* - * Dump it all. Later, maybe less. - */ - for (i = 1; i <= CP_MAXCODE; i++) { -#ifdef OPENSSL - if (i > CP_VARLIST) - continue; -#endif /* OPENSSL */ + /* Dump it all. Later, maybe less. */ + for (i = 1; i <= CP_MAX_NOAUTOKEY; i++) ctl_putpeer(i, peer); - } #ifdef REFCLOCK /* * for clock exception events: add clock variables to * reflect info on exception */ - if (err == EVNT_PEERCLOCK) { - struct refclockstat clock_stat; + if (err == PEVNT_CLOCK) { + struct refclockstat cs; struct ctl_var *kv; - clock_stat.kv_list = (struct ctl_var *)0; - refclock_control(&peer->srcadr, - (struct refclockstat *)0, &clock_stat); + cs.kv_list = NULL; + refclock_control(&peer->srcadr, NULL, &cs); ctl_puthex("refclockstatus", - ctlclkstatus(&clock_stat)); + ctlclkstatus(&cs)); for (i = 1; i <= CC_MAXCODE; i++) - ctl_putclock(i, &clock_stat, 0); - for (kv = clock_stat.kv_list; kv && - !(kv->flags & EOV); kv++) - if (kv->flags & DEF) + ctl_putclock(i, &cs, FALSE); + for (kv = cs.kv_list; + kv != NULL && !(EOV & kv->flags); + kv++) + if (DEF & kv->flags) ctl_putdata(kv->text, - strlen(kv->text), 0); - free_varlist(clock_stat.kv_list); + strlen(kv->text), + FALSE); + free_varlist(cs.kv_list); } #endif /* REFCLOCK */ } @@ -2876,6 +4853,30 @@ report_event( } +/* + * mprintf_event - printf-style varargs variant of report_event() + */ +int +mprintf_event( + int evcode, /* event code */ + struct peer * p, /* may be NULL */ + const char * fmt, /* msnprintf format */ + ... + ) +{ + va_list ap; + int rc; + char msg[512]; + + va_start(ap, fmt); + rc = mvsnprintf(msg, sizeof(msg), fmt, ap); + va_end(ap); + report_event(evcode, p, msg); + + return rc; +} + + /* * ctl_clr_stats - clear stat counters */ @@ -2900,22 +4901,25 @@ ctl_clr_stats(void) numasyncmsgs = 0; } -static u_long +static u_short count_var( - struct ctl_var *k + const struct ctl_var *k ) { - register u_long c; + u_int c; - if (!k) - return (0); + if (NULL == k) + return 0; c = 0; - while (!(k++->flags & EOV)) + while (!(EOV & (k++)->flags)) c++; - return (c); + + ENSURE(c <= USHRT_MAX); + return (u_short)c; } + char * add_var( struct ctl_var **kv, @@ -2923,27 +4927,25 @@ add_var( u_short def ) { - register u_long c; - register struct ctl_var *k; + u_short c; + struct ctl_var *k; + char * buf; c = count_var(*kv); - + *kv = erealloc(*kv, (c + 2) * sizeof(**kv)); k = *kv; - *kv = (struct ctl_var *)emalloc((c+2)*sizeof(struct ctl_var)); - if (k) { - memmove((char *)*kv, (char *)k, - sizeof(struct ctl_var)*c); - free((char *)k); - } - (*kv)[c].code = (u_short) c; - (*kv)[c].text = (char *)emalloc(size); - (*kv)[c].flags = def; - (*kv)[c+1].code = 0; - (*kv)[c+1].text = (char *)0; - (*kv)[c+1].flags = EOV; - return (char *)(*kv)[c].text; + buf = emalloc(size); + k[c].code = c; + k[c].text = buf; + k[c].flags = def; + k[c + 1].code = 0; + k[c + 1].text = NULL; + k[c + 1].flags = EOV; + + return buf; } + void set_var( struct ctl_var **kv, @@ -2952,46 +4954,46 @@ set_var( u_short def ) { - register struct ctl_var *k; - register const char *s; - register const char *t; + struct ctl_var *k; + const char *s; + const char *t; char *td; - if (!data || !size) + if (NULL == data || !size) return; k = *kv; if (k != NULL) { - while (!(k->flags & EOV)) { - s = data; - t = k->text; - if (t) { - while (*t != '=' && *s - *t == 0) { + while (!(EOV & k->flags)) { + if (NULL == k->text) { + td = emalloc(size); + memcpy(td, data, size); + k->text = td; + k->flags = def; + return; + } else { + s = data; + t = k->text; + while (*t != '=' && *s == *t) { s++; t++; } if (*s == *t && ((*t == '=') || !*t)) { - free((void *)k->text); - td = (char *)emalloc(size); - memmove(td, data, size); - k->text =td; + td = erealloc((void *)(intptr_t)k->text, size); + memcpy(td, data, size); + k->text = td; k->flags = def; return; } - } else { - td = (char *)emalloc(size); - memmove(td, data, size); - k->text = td; - k->flags = def; - return; } k++; } } td = add_var(kv, size, def); - memmove(td, data, size); + memcpy(td, data, size); } + void set_sys_var( const char *data, @@ -3002,6 +5004,36 @@ set_sys_var( set_var(&ext_sys_var, data, size, def); } + +/* + * get_ext_sys_var() retrieves the value of a user-defined variable or + * NULL if the variable has not been setvar'd. + */ +const char * +get_ext_sys_var(const char *tag) +{ + struct ctl_var * v; + size_t c; + const char * val; + + val = NULL; + c = strlen(tag); + for (v = ext_sys_var; !(EOV & v->flags); v++) { + if (NULL != v->text && !memcmp(tag, v->text, c)) { + if ('=' == v->text[c]) { + val = v->text + c + 1; + break; + } else if ('\0' == v->text[c]) { + val = ""; + break; + } + } + } + + return val; +} + + void free_varlist( struct ctl_var *kv @@ -3010,7 +5042,7 @@ free_varlist( struct ctl_var *k; if (kv) { for (k = kv; !(k->flags & EOV); k++) - free((void *)k->text); + free((void *)(intptr_t)k->text); free((void *)kv); } } diff --git a/contrib/ntp/ntpd/ntp_crypto.c b/contrib/ntp/ntpd/ntp_crypto.c index e3f7afdbc..376b5b505 100644 --- a/contrib/ntp/ntpd/ntp_crypto.c +++ b/contrib/ntp/ntpd/ntp_crypto.c @@ -5,8 +5,9 @@ #include #endif -#ifdef OPENSSL +#ifdef AUTOKEY #include +#include /* strtoul */ #include #include #include @@ -16,7 +17,10 @@ #include "ntp_stdlib.h" #include "ntp_unixtime.h" #include "ntp_string.h" -#include +#include "ntp_random.h" +#include "ntp_assert.h" +#include "ntp_calendar.h" +#include "ntp_leapsec.h" #include "openssl/asn1_mac.h" #include "openssl/bn.h" @@ -30,6 +34,33 @@ #include "ntp_syscall.h" #endif /* KERNEL_PLL */ +/* + * calcomp - compare two calendar structures, ignoring yearday and weekday; like strcmp + * No, it's not a plotter. If you don't understand that, you're too young. + */ +static int calcomp(struct calendar *pjd1, struct calendar *pjd2) +{ + int32_t diff; /* large enough to hold the signed difference between two uint16_t values */ + + diff = pjd1->year - pjd2->year; + if (diff < 0) return -1; else if (diff > 0) return 1; + /* same year; compare months */ + diff = pjd1->month - pjd2->month; + if (diff < 0) return -1; else if (diff > 0) return 1; + /* same year and month; compare monthday */ + diff = pjd1->monthday - pjd2->monthday; + if (diff < 0) return -1; else if (diff > 0) return 1; + /* same year and month and monthday; compare time */ + diff = pjd1->hour - pjd2->hour; + if (diff < 0) return -1; else if (diff > 0) return 1; + diff = pjd1->minute - pjd2->minute; + if (diff < 0) return -1; else if (diff > 0) return 1; + diff = pjd1->second - pjd2->second; + if (diff < 0) return -1; else if (diff > 0) return 1; + /* identical */ + return 0; +} + /* * Extension field message format * @@ -40,7 +71,7 @@ * +-------+-------+ * | op | len | <- extension pointer * +-------+-------+ - * | assocID | + * | associd | * +---------------+ * | timestamp | <- value pointer * +---------------+ @@ -79,13 +110,28 @@ * creator or signor is synchronized to an authoritative source and * proventicated to a trusted authority. * - * Note there are four conditions required for server trust. First, the - * public key on the certificate must be verified, which involves a - * number of format, content and consistency checks. Next, the server - * identity must be confirmed by one of four schemes: private - * certificate, IFF scheme, GQ scheme or certificate trail hike to a - * self signed trusted certificate. Finally, the server signature must - * be verified. + * Note there are several conditions required for server trust. First, + * the public key on the server certificate must be verified, which can + * involve a hike along the certificate trail to a trusted host. Next, + * the server trust must be confirmed by one of several identity + * schemes. Valid cryptographic values are signed with attached + * timestamp and filestamp. Individual packet trust is confirmed + * relative to these values by a message digest with keys generated by a + * reverse-order pseudorandom hash. + * + * State decomposition. These flags are lit in the order given. They are + * dim only when the association is demobilized. + * + * CRYPTO_FLAG_ENAB Lit upon acceptance of a CRYPTO_ASSOC message + * CRYPTO_FLAG_CERT Lit when a self-digned trusted certificate is + * accepted. + * CRYPTO_FLAG_VRFY Lit when identity is confirmed. + * CRYPTO_FLAG_PROV Lit when the first signature is verified. + * CRYPTO_FLAG_COOK Lit when a valid cookie is accepted. + * CRYPTO_FLAG_AUTO Lit when valid autokey values are accepted. + * CRYPTO_FLAG_SIGN Lit when the server signed certificate is + * accepted. + * CRYPTO_FLAG_LEAP Lit when the leapsecond values are accepted. */ /* * Cryptodefines @@ -100,20 +146,24 @@ * Global cryptodata in host byte order */ u_int32 crypto_flags = 0x0; /* status word */ +int crypto_nid = KEY_TYPE_MD5; /* digest nid */ +char *sys_hostname = NULL; +char *sys_groupname = NULL; +static char *host_filename = NULL; /* host file name */ +static char *ident_filename = NULL; /* group file name */ /* * Global cryptodata in network byte order */ -struct cert_info *cinfo = NULL; /* certificate info/value */ +struct cert_info *cinfo = NULL; /* certificate info/value cache */ +struct cert_info *cert_host = NULL; /* host certificate */ +struct pkey_info *pkinfo = NULL; /* key info/value cache */ struct value hostval; /* host value */ struct value pubkey; /* public key */ -struct value tai_leap; /* leapseconds table */ -EVP_PKEY *iffpar_pkey = NULL; /* IFF parameters */ -EVP_PKEY *gqpar_pkey = NULL; /* GQ parameters */ -EVP_PKEY *mvpar_pkey = NULL; /* MV parameters */ -char *iffpar_file = NULL; /* IFF parameters file */ -char *gqpar_file = NULL; /* GQ parameters file */ -char *mvpar_file = NULL; /* MV parameters file */ +struct value tai_leap; /* leapseconds values */ +struct pkey_info *iffkey_info = NULL; /* IFF keys */ +struct pkey_info *gqkey_info = NULL; /* GQ keys */ +struct pkey_info *mvkey_info = NULL; /* MV keys */ /* * Private cryptodata in host byte order @@ -124,43 +174,35 @@ static EVP_PKEY *sign_pkey = NULL; /* sign key */ static const EVP_MD *sign_digest = NULL; /* sign digest */ static u_int sign_siglen; /* sign key length */ static char *rand_file = NULL; /* random seed file */ -static char *host_file = NULL; /* host key file */ -static char *sign_file = NULL; /* sign key file */ -static char *cert_file = NULL; /* certificate file */ -static char *leap_file = NULL; /* leapseconds file */ -static tstamp_t if_fstamp = 0; /* IFF filestamp */ -static tstamp_t gq_fstamp = 0; /* GQ file stamp */ -static tstamp_t mv_fstamp = 0; /* MV filestamp */ -static u_int ident_scheme = 0; /* server identity scheme */ /* * Cryptotypes */ -static int crypto_verify P((struct exten *, struct value *, - struct peer *)); -static int crypto_encrypt P((const u_char *, u_int, keyid_t *, - struct value *)); -static int crypto_alice P((struct peer *, struct value *)); -static int crypto_alice2 P((struct peer *, struct value *)); -static int crypto_alice3 P((struct peer *, struct value *)); -static int crypto_bob P((struct exten *, struct value *)); -static int crypto_bob2 P((struct exten *, struct value *)); -static int crypto_bob3 P((struct exten *, struct value *)); -static int crypto_iff P((struct exten *, struct peer *)); -static int crypto_gq P((struct exten *, struct peer *)); -static int crypto_mv P((struct exten *, struct peer *)); -static u_int crypto_send P((struct exten *, struct value *)); -static tstamp_t crypto_time P((void)); -static u_long asn2ntp P((ASN1_TIME *)); -static struct cert_info *cert_parse P((u_char *, u_int, tstamp_t)); -static int cert_sign P((struct exten *, struct value *)); -static int cert_valid P((struct cert_info *, EVP_PKEY *)); -static int cert_install P((struct exten *, struct peer *)); -static void cert_free P((struct cert_info *)); -static EVP_PKEY *crypto_key P((char *, tstamp_t *)); -static int bighash P((BIGNUM *, BIGNUM *)); -static struct cert_info *crypto_cert P((char *)); -static void crypto_tai P((char *)); +static int crypto_verify (struct exten *, struct value *, + struct peer *); +static int crypto_encrypt (const u_char *, u_int, keyid_t *, + struct value *); +static int crypto_alice (struct peer *, struct value *); +static int crypto_alice2 (struct peer *, struct value *); +static int crypto_alice3 (struct peer *, struct value *); +static int crypto_bob (struct exten *, struct value *); +static int crypto_bob2 (struct exten *, struct value *); +static int crypto_bob3 (struct exten *, struct value *); +static int crypto_iff (struct exten *, struct peer *); +static int crypto_gq (struct exten *, struct peer *); +static int crypto_mv (struct exten *, struct peer *); +static int crypto_send (struct exten *, struct value *, int); +static tstamp_t crypto_time (void); +static void asn_to_calendar (ASN1_TIME *, struct calendar*); +static struct cert_info *cert_parse (const u_char *, long, tstamp_t); +static int cert_sign (struct exten *, struct value *); +static struct cert_info *cert_install (struct exten *, struct peer *); +static int cert_hike (struct peer *, struct cert_info *); +static void cert_free (struct cert_info *); +static struct pkey_info *crypto_key (char *, char *, sockaddr_u *); +static void bighash (BIGNUM *, BIGNUM *); +static struct cert_info *crypto_cert (char *); +static u_int exten_payload_size(const struct exten *); #ifdef SYS_WINNT int @@ -177,12 +219,12 @@ readlink(char * link, char * file, int len) { * session key is the MD5 hash of these values, while the next key ID is * the first four octets of the hash. * - * Returns the next key ID + * Returns the next key ID or 0 if there is no destination address. */ keyid_t session_key( - struct sockaddr_storage *srcadr, /* source address */ - struct sockaddr_storage *dstadr, /* destination address */ + sockaddr_u *srcadr, /* source address */ + sockaddr_u *dstadr, /* destination address */ keyid_t keyno, /* key ID */ keyid_t private, /* private value */ u_long lifetime /* key lifetime */ @@ -202,41 +244,38 @@ session_key( * greater than zero, install the key and call it trusted. */ hdlen = 0; - switch(srcadr->ss_family) { + switch(AF(srcadr)) { case AF_INET: - header[0] = ((struct sockaddr_in *)srcadr)->sin_addr.s_addr; - header[1] = ((struct sockaddr_in *)dstadr)->sin_addr.s_addr; + header[0] = NSRCADR(srcadr); + header[1] = NSRCADR(dstadr); header[2] = htonl(keyno); header[3] = htonl(private); hdlen = 4 * sizeof(u_int32); break; case AF_INET6: - memcpy(&header[0], &GET_INADDR6(*srcadr), + memcpy(&header[0], PSOCK_ADDR6(srcadr), sizeof(struct in6_addr)); - memcpy(&header[4], &GET_INADDR6(*dstadr), + memcpy(&header[4], PSOCK_ADDR6(dstadr), sizeof(struct in6_addr)); header[8] = htonl(keyno); header[9] = htonl(private); hdlen = 10 * sizeof(u_int32); break; } - EVP_DigestInit(&ctx, EVP_md5()); + EVP_DigestInit(&ctx, EVP_get_digestbynid(crypto_nid)); EVP_DigestUpdate(&ctx, (u_char *)header, hdlen); EVP_DigestFinal(&ctx, dgst, &len); memcpy(&keyid, dgst, 4); keyid = ntohl(keyid); if (lifetime != 0) { - MD5auth_setkey(keyno, dgst, len); + MD5auth_setkey(keyno, crypto_nid, dgst, len); authtrust(keyno, lifetime); } -#ifdef DEBUG - if (debug > 1) - printf( - "session_key: %s > %s %08x %08x hash %08x life %lu\n", + DPRINTF(2, ("session_key: %s > %s %08x %08x hash %08x life %lu\n", stoa(srcadr), stoa(dstadr), keyno, - private, keyid, lifetime); -#endif + private, keyid, lifetime)); + return (keyid); } @@ -246,7 +285,7 @@ session_key( * * Returns * XEVNT_OK success - * XEVNT_PER host certificate expired + * XEVNT_ERR protocol error * * This routine constructs a pseudo-random sequence by repeatedly * hashing the session key starting from a given source address, @@ -266,28 +305,30 @@ make_keylist( struct value *vp; /* value pointer */ keyid_t keyid = 0; /* next key ID */ keyid_t cookie; /* private value */ - u_long lifetime; + long lifetime; u_int len, mpoll; int i; if (!dstadr) - return XEVNT_OK; + return XEVNT_ERR; /* * Allocate the key list if necessary. */ tstamp = crypto_time(); if (peer->keylist == NULL) - peer->keylist = emalloc(sizeof(keyid_t) * - NTP_MAXSESSION); + peer->keylist = eallocarray(NTP_MAXSESSION, + sizeof(keyid_t)); /* * Generate an initial key ID which is unique and greater than * NTP_MAXKEY. */ while (1) { - keyid = (ntp_random() + NTP_MAXKEY + 1) & ((1 << - sizeof(keyid_t)) - 1); + keyid = ntp_random() & 0xffffffff; + if (keyid <= NTP_MAXKEY) + continue; + if (authhavekey(keyid)) continue; break; @@ -301,7 +342,7 @@ make_keylist( * cookie if client mode or the host cookie if symmetric modes. */ mpoll = 1 << min(peer->ppoll, peer->hpoll); - lifetime = min(sys_automax, NTP_MAXSESSION * mpoll); + lifetime = min(1U << sys_automax, NTP_MAXSESSION * mpoll); if (peer->hmode == MODE_BROADCAST) cookie = 0; else @@ -310,10 +351,10 @@ make_keylist( peer->keylist[i] = keyid; peer->keynumber = i; keyid = session_key(&dstadr->sin, &peer->srcadr, keyid, - cookie, lifetime); + cookie, lifetime + mpoll); lifetime -= mpoll; if (auth_havekey(keyid) || keyid <= NTP_MAXKEY || - lifetime <= mpoll) + lifetime < 0 || tstamp == 0) break; } @@ -334,27 +375,20 @@ make_keylist( vp->vallen = htonl(sizeof(struct autokey)); vp->siglen = 0; if (tstamp != 0) { - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - if (vp->sig == NULL) vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)vp, 12); EVP_SignUpdate(&ctx, vp->ptr, sizeof(struct autokey)); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); vp->siglen = htonl(len); - else - msyslog(LOG_ERR, "make_keys %s\n", - ERR_error_string(ERR_get_error(), NULL)); - peer->flags |= FLAG_ASSOC; + peer->flags |= FLAG_ASSOC; + } } -#ifdef DEBUG - if (debug) - printf("make_keys: %d %08x %08x ts %u fs %u poll %d\n", - ntohl(ap->seq), ntohl(ap->key), cookie, - ntohl(vp->tstamp), ntohl(vp->fstamp), peer->hpoll); -#endif + DPRINTF(1, ("make_keys: %d %08x %08x ts %u fs %u poll %d\n", + peer->keynumber, keyid, cookie, ntohl(vp->tstamp), + ntohl(vp->fstamp), peer->hpoll)); return (XEVNT_OK); } @@ -369,6 +403,11 @@ make_keylist( * valid length and is verified. There are a few cases where some values * are believed even if the signature fails, but only if the proventic * bit is not set. + * + * Returns + * XEVNT_OK success + * XEVNT_ERR protocol error + * XEVNT_LEN bad field format or length */ int crypto_recv( @@ -380,10 +419,10 @@ crypto_recv( u_int32 *pkt; /* receive packet pointer */ struct autokey *ap, *bp; /* autokey pointer */ struct exten *ep, *fp; /* extension pointers */ - int has_mac; /* length of MAC field */ + struct cert_info *xinfo; /* certificate info pointer */ + int macbytes; /* length of MAC field, signed by intention */ int authlen; /* offset of MAC field */ associd_t associd; /* association ID */ - tstamp_t tstamp = 0; /* timestamp */ tstamp_t fstamp = 0; /* filestamp */ u_int len; /* extension field length */ u_int code; /* extension field opcode */ @@ -393,7 +432,7 @@ crypto_recv( keyid_t cookie; /* crumbles */ int hismode; /* packet mode */ int rval = XEVNT_OK; - u_char *ptr; + const u_char *puch; u_int32 temp32; /* @@ -408,43 +447,44 @@ crypto_recv( */ authlen = LEN_PKT_NOMAC; hismode = (int)PKT_MODE((&rbufp->recv_pkt)->li_vn_mode); - while ((has_mac = rbufp->recv_length - authlen) > MAX_MAC_LEN) { + while ((macbytes = rbufp->recv_length - authlen) > (int)MAX_MAC_LEN) { + /* We can be reasonably sure that we can read at least + * the opcode and the size field here. More stringent + * checks follow up shortly. + */ pkt = (u_int32 *)&rbufp->recv_pkt + authlen / 4; ep = (struct exten *)pkt; code = ntohl(ep->opcode) & 0xffff0000; len = ntohl(ep->opcode) & 0x0000ffff; - associd = (associd_t) ntohl(pkt[1]); + // HMS: Why pkt[1] instead of ep->associd ? + associd = (associd_t)ntohl(pkt[1]); rval = XEVNT_OK; -#ifdef DEBUG - if (debug) - printf( - "crypto_recv: flags 0x%x ext offset %d len %u code 0x%x assocID %d\n", + DPRINTF(1, ("crypto_recv: flags 0x%x ext offset %d len %u code 0x%x associd %d\n", peer->crypto, authlen, len, code >> 16, - associd); -#endif + associd)); /* * Check version number and field length. If bad, * quietly ignore the packet. */ if (((code >> 24) & 0x3f) != CRYPTO_VN || len < 8) { - sys_unknownversion++; + sys_badlength++; code |= CRYPTO_ERROR; } - /* - * Little vulnerability bandage here. If a perp tosses a - * fake association ID over the fence, we better toss it - * out. Only the first one counts. + /* Check if the declared size fits into the remaining + * buffer. */ - if (code & CRYPTO_RESP) { - if (peer->assoc == 0) - peer->assoc = associd; - else if (peer->assoc != associd) - code |= CRYPTO_ERROR; + if (len > macbytes) { + DPRINTF(1, ("crypto_recv: possible attack detected, associd %d\n", + associd)); + return XEVNT_LEN; } + + /* Check if the paylod of the extension fits into the + * declared frame. + */ if (len >= VALUE_LEN) { - tstamp = ntohl(ep->tstamp); fstamp = ntohl(ep->fstamp); vallen = ntohl(ep->vallen); /* @@ -469,19 +509,27 @@ crypto_recv( case CRYPTO_ASSOC: /* - * If the machine is running when this message - * arrives, the other fellow has reset and so - * must we. Otherwise, pass the extension field - * to the transmit side. + * If our state machine is running when this + * message arrives, the other fellow might have + * restarted. However, this could be an + * intruder, so just clamp the poll interval and + * find out for ourselves. Otherwise, pass the + * extension field to the transmit side. */ - if (peer->crypto) { + if (peer->crypto & CRYPTO_FLAG_CERT) { rval = XEVNT_ERR; break; } + if (peer->cmmd) { + if (peer->assoc != associd) { + rval = XEVNT_ERR; + break; + } + free(peer->cmmd); /* will be set again! */ + } fp = emalloc(len); memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); + fp->associd = htonl(peer->associd); peer->cmmd = fp; /* fall through */ @@ -491,67 +539,52 @@ crypto_recv( * Discard the message if it has already been * stored or the message has been amputated. */ - if (peer->crypto) + if (peer->crypto) { + if (peer->assoc != associd) + rval = XEVNT_ERR; break; - + } + INSIST(len >= VALUE_LEN); if (vallen == 0 || vallen > MAXHOSTNAME || len - VALUE_LEN < vallen) { rval = XEVNT_LEN; break; } + DPRINTF(1, ("crypto_recv: ident host 0x%x %d server 0x%x %d\n", + crypto_flags, peer->associd, fstamp, + peer->assoc)); + temp32 = crypto_flags & CRYPTO_FLAG_MASK; /* - * Check the identity schemes are compatible. If - * the client has PC, the server must have PC, - * in which case the server public key and - * identity are presumed valid, so we skip the - * certificate and identity exchanges and move - * immediately to the cookie exchange which - * confirms the server signature. + * If the client scheme is PC, the server scheme + * must be PC. The public key and identity are + * presumed valid, so we skip the certificate + * and identity exchanges and move immediately + * to the cookie exchange which confirms the + * server signature. */ -#ifdef DEBUG - if (debug) - printf( - "crypto_recv: ident host 0x%x server 0x%x\n", - crypto_flags, fstamp); -#endif - temp32 = (crypto_flags | ident_scheme) & - fstamp & CRYPTO_FLAG_MASK; if (crypto_flags & CRYPTO_FLAG_PRIV) { if (!(fstamp & CRYPTO_FLAG_PRIV)) { rval = XEVNT_KEY; break; - - } else { - fstamp |= CRYPTO_FLAG_VALID | - CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_SIGN; } - /* - * In symmetric modes it is an error if either - * peer requests identity and the other peer - * does not support it. - */ - } else if ((hismode == MODE_ACTIVE || hismode == - MODE_PASSIVE) && ((crypto_flags | fstamp) & - CRYPTO_FLAG_MASK) && !temp32) { - rval = XEVNT_KEY; - break; - /* - * It is an error if the client requests - * identity and the server does not support it. - */ - } else if (hismode == MODE_CLIENT && (fstamp & - CRYPTO_FLAG_MASK) && !temp32) { - rval = XEVNT_KEY; - break; - } + fstamp |= CRYPTO_FLAG_CERT | + CRYPTO_FLAG_VRFY | CRYPTO_FLAG_SIGN; /* - * Otherwise, the identity scheme(s) are those - * that both client and server support. + * It is an error if either peer supports + * identity, but the other does not. */ - fstamp = temp32 | (fstamp & ~CRYPTO_FLAG_MASK); + } else if (hismode == MODE_ACTIVE || hismode == + MODE_PASSIVE) { + if ((temp32 && !(fstamp & + CRYPTO_FLAG_MASK)) || + (!temp32 && (fstamp & + CRYPTO_FLAG_MASK))) { + rval = XEVNT_KEY; + break; + } + } /* * Discard the message if the signature digest @@ -567,24 +600,32 @@ crypto_recv( /* * Save status word, host name and message - * digest/signature type. + * digest/signature type. If this is from a + * broadcast and the association ID has changed, + * request the autokey values. */ + peer->assoc = associd; + if (hismode == MODE_SERVER) + fstamp |= CRYPTO_FLAG_AUTO; + if (!(fstamp & CRYPTO_FLAG_TAI)) + fstamp |= CRYPTO_FLAG_LEAP; + RAND_bytes((u_char *)&peer->hcookie, 4); peer->crypto = fstamp; peer->digest = dp; + if (peer->subject != NULL) + free(peer->subject); peer->subject = emalloc(vallen + 1); memcpy(peer->subject, ep->pkt, vallen); peer->subject[vallen] = '\0'; - peer->issuer = emalloc(vallen + 1); - strcpy(peer->issuer, peer->subject); - temp32 = (fstamp >> 16) & 0xffff; - snprintf(statstr, NTP_MAXSTRLEN, - "flags 0x%x host %s signature %s", fstamp, - peer->subject, OBJ_nid2ln(temp32)); + if (peer->issuer != NULL) + free(peer->issuer); + peer->issuer = estrdup(peer->subject); + snprintf(statstr, sizeof(statstr), + "assoc %d %d host %s %s", peer->associd, + peer->assoc, peer->subject, + OBJ_nid2ln(temp32)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* @@ -597,8 +638,11 @@ crypto_recv( case CRYPTO_CERT | CRYPTO_RESP: /* - * Discard the message if invalid. + * Discard the message if empty or invalid. */ + if (len < VALUE_LEN) + break; + if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; @@ -606,26 +650,16 @@ crypto_recv( /* * Scan the certificate list to delete old * versions and link the newest version first on - * the list. + * the list. Then, verify the signature. If the + * certificate is bad or missing, just ignore + * it. */ - if ((rval = cert_install(ep, peer)) != XEVNT_OK) + if ((xinfo = cert_install(ep, peer)) == NULL) { + rval = XEVNT_CRT; + break; + } + if ((rval = cert_hike(peer, xinfo)) != XEVNT_OK) break; - - /* - * If we snatch the certificate before the - * server certificate has been signed by its - * server, it will be self signed. When it is, - * we chase the certificate issuer, which the - * server has, and keep going until a self - * signed trusted certificate is found. Be sure - * to update the issuer field, since it may - * change. - */ - if (peer->issuer != NULL) - free(peer->issuer); - peer->issuer = emalloc(strlen(cinfo->issuer) + - 1); - strcpy(peer->issuer, cinfo->issuer); /* * We plug in the public key and lifetime from @@ -635,71 +669,58 @@ crypto_recv( * signature/digest NID. */ if (peer->pkey == NULL) { - ptr = (u_char *)cinfo->cert.ptr; - cert = d2i_X509(NULL, &ptr, - ntohl(cinfo->cert.vallen)); + puch = xinfo->cert.ptr; + cert = d2i_X509(NULL, &puch, + ntohl(xinfo->cert.vallen)); peer->pkey = X509_get_pubkey(cert); X509_free(cert); } peer->flash &= ~TEST8; - temp32 = cinfo->nid; - snprintf(statstr, NTP_MAXSTRLEN, - "cert %s 0x%x %s (%u) fs %u", - cinfo->subject, cinfo->flags, + temp32 = xinfo->nid; + snprintf(statstr, sizeof(statstr), + "cert %s %s 0x%x %s (%u) fs %u", + xinfo->subject, xinfo->issuer, xinfo->flags, OBJ_nid2ln(temp32), temp32, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* - * Schnorr (IFF)identity scheme. This scheme is designed - * for use with shared secret group keys and where the - * certificate may be generated by a third party. The - * client sends a challenge to the server, which - * performs a calculation and returns the result. A - * positive result is possible only if both client and + * Schnorr (IFF) identity scheme. This scheme is + * designed for use with shared secret server group keys + * and where the certificate may be generated by a third + * party. The client sends a challenge to the server, + * which performs a calculation and returns the result. + * A positive result is possible only if both client and * server contain the same secret group key. */ case CRYPTO_IFF | CRYPTO_RESP: /* - * Discard the message if invalid or certificate - * trail not trusted. + * Discard the message if invalid. */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; /* - * If the the challenge matches the response, - * the certificate public key, as well as the - * server public key, signatyre and identity are + * If the challenge matches the response, the + * server public key, signature and identity are * all verified at the same time. The server is * declared trusted, so we skip further - * certificate stages and move immediately to - * the cookie stage. + * certificate exchanges and move immediately to + * the cookie exchange. */ if ((rval = crypto_iff(ep, peer)) != XEVNT_OK) break; - peer->crypto |= CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_PROV; + peer->crypto |= CRYPTO_FLAG_VRFY; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "iff fs %u", - ntohl(ep->fstamp)); + snprintf(statstr, sizeof(statstr), "iff %s fs %u", + peer->issuer, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* @@ -715,136 +736,68 @@ crypto_recv( case CRYPTO_GQ | CRYPTO_RESP: /* - * Discard the message if invalid or certificate - * trail not trusted. + * Discard the message if invalid */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; /* - * If the the challenge matches the response, - * the certificate public key, as well as the - * server public key, signatyre and identity are + * If the challenge matches the response, the + * server public key, signature and identity are * all verified at the same time. The server is * declared trusted, so we skip further - * certificate stages and move immediately to - * the cookie stage. + * certificate exchanges and move immediately to + * the cookie exchange. */ if ((rval = crypto_gq(ep, peer)) != XEVNT_OK) break; - peer->crypto |= CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_PROV; + peer->crypto |= CRYPTO_FLAG_VRFY; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "gq fs %u", - ntohl(ep->fstamp)); + snprintf(statstr, sizeof(statstr), "gq %s fs %u", + peer->issuer, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* - * MV + * Mu-Varadharajan (MV) identity scheme. This scheme is + * designed for use with three levels of trust, trusted + * host, server and client. The trusted host key is + * opaque to servers and clients; the server keys are + * opaque to clients and each client key is different. + * Client keys can be revoked without requiring new key + * generations. */ case CRYPTO_MV | CRYPTO_RESP: /* - * Discard the message if invalid or certificate - * trail not trusted. + * Discard the message if invalid. */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; /* - * If the the challenge matches the response, - * the certificate public key, as well as the - * server public key, signatyre and identity are + * If the challenge matches the response, the + * server public key, signature and identity are * all verified at the same time. The server is * declared trusted, so we skip further - * certificate stages and move immediately to - * the cookie stage. + * certificate exchanges and move immediately to + * the cookie exchange. */ if ((rval = crypto_mv(ep, peer)) != XEVNT_OK) break; - peer->crypto |= CRYPTO_FLAG_VRFY | - CRYPTO_FLAG_PROV; + peer->crypto |= CRYPTO_FLAG_VRFY; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "mv fs %u", - ntohl(ep->fstamp)); + snprintf(statstr, sizeof(statstr), "mv %s fs %u", + peer->issuer, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; - /* - * Cookie request in symmetric modes. Roll a random - * cookie and install in symmetric mode. Encrypt for the - * response, which is transmitted later. - */ - case CRYPTO_COOK: - - /* - * Discard the message if invalid or certificate - * trail not trusted. - */ - if (!(peer->crypto & CRYPTO_FLAG_VALID)) { - rval = XEVNT_ERR; - break; - } - if ((rval = crypto_verify(ep, NULL, peer)) != - XEVNT_OK) - break; - - /* - * Pass the extension field to the transmit - * side. If already agreed, walk away. - */ - fp = emalloc(len); - memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); - peer->cmmd = fp; - if (peer->crypto & CRYPTO_FLAG_AGREE) { - peer->flash &= ~TEST8; - break; - } - - /* - * Install cookie values and light the cookie - * bit. The transmit side will pick up and - * encrypt it for the response. - */ - key_expire(peer); - peer->cookval.tstamp = ep->tstamp; - peer->cookval.fstamp = ep->fstamp; - RAND_bytes((u_char *)&peer->pcookie, 4); - peer->crypto &= ~CRYPTO_FLAG_AUTO; - peer->crypto |= CRYPTO_FLAG_AGREE; - peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "cook %x ts %u fs %u", - peer->pcookie, ntohl(ep->tstamp), - ntohl(ep->fstamp)); - record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif - break; /* * Cookie response in client and symmetric modes. If the @@ -854,14 +807,10 @@ crypto_recv( case CRYPTO_COOK | CRYPTO_RESP: /* - * Discard the message if invalid or identity - * not confirmed or signature not verified with - * respect to the cookie values. + * Discard the message if invalid or signature + * not verified with respect to the cookie + * values. */ - if (!(peer->crypto & CRYPTO_FLAG_VRFY)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, &peer->cookval, peer)) != XEVNT_OK) break; @@ -870,13 +819,14 @@ crypto_recv( * Decrypt the cookie, hunting all the time for * errors. */ - if (vallen == (u_int) EVP_PKEY_size(host_pkey)) { + if (vallen == (u_int)EVP_PKEY_size(host_pkey)) { u_int32 *cookiebuf = malloc( - RSA_size(host_pkey->pkey.rsa)); - if (cookiebuf == NULL) { + RSA_size(host_pkey->pkey.rsa)); + if (!cookiebuf) { rval = XEVNT_CKY; break; } + if (RSA_private_decrypt(vallen, (u_char *)ep->pkt, (u_char *)cookiebuf, @@ -900,27 +850,18 @@ crypto_recv( * are done here. */ key_expire(peer); - peer->cookval.tstamp = ep->tstamp; - peer->cookval.fstamp = ep->fstamp; - if (peer->crypto & CRYPTO_FLAG_AGREE) - peer->pcookie ^= cookie; + if (hismode == MODE_ACTIVE || hismode == + MODE_PASSIVE) + peer->pcookie = peer->hcookie ^ cookie; else peer->pcookie = cookie; - if (peer->hmode == MODE_CLIENT && - !(peer->cast_flags & MDF_BCLNT)) - peer->crypto |= CRYPTO_FLAG_AUTO; - else - peer->crypto &= ~CRYPTO_FLAG_AUTO; - peer->crypto |= CRYPTO_FLAG_AGREE; + peer->crypto |= CRYPTO_FLAG_COOK; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, "cook %x ts %u fs %u", - peer->pcookie, ntohl(ep->tstamp), - ntohl(ep->fstamp)); + snprintf(statstr, sizeof(statstr), + "cook %x ts %u fs %u", peer->pcookie, + ntohl(ep->tstamp), ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* @@ -936,22 +877,32 @@ crypto_recv( case CRYPTO_AUTO | CRYPTO_RESP: /* - * Discard the message if invalid or identity - * not confirmed or signature not verified with - * respect to the receive autokey values. + * Discard the message if invalid or signature + * not verified with respect to the receive + * autokey values. */ - if (!(peer->crypto & CRYPTO_FLAG_VRFY)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, &peer->recval, - peer)) != XEVNT_OK) + peer)) != XEVNT_OK) + break; + + /* + * Discard the message if a broadcast client and + * the association ID does not match. This might + * happen if a broacast server restarts the + * protocol. A protocol restart will occur at + * the next ASSOC message. + */ + if ((peer->cast_flags & MDF_BCLNT) && + peer->assoc != associd) break; /* * Install autokey values and light the * autokey bit. This is not hard. */ + if (ep->tstamp == 0) + break; + if (peer->recval.ptr == NULL) peer->recval.ptr = emalloc(sizeof(struct autokey)); @@ -964,15 +915,12 @@ crypto_recv( peer->pkeyid = bp->key; peer->crypto |= CRYPTO_FLAG_AUTO; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, + snprintf(statstr, sizeof(statstr), "auto seq %d key %x ts %u fs %u", bp->seq, bp->key, ntohl(ep->tstamp), ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* @@ -985,13 +933,8 @@ crypto_recv( case CRYPTO_SIGN | CRYPTO_RESP: /* - * Discard the message if invalid or not - * proventic. + * Discard the message if invalid. */ - if (!(peer->crypto & CRYPTO_FLAG_PROV)) { - rval = XEVNT_ERR; - break; - } if ((rval = crypto_verify(ep, NULL, peer)) != XEVNT_OK) break; @@ -1001,118 +944,74 @@ crypto_recv( * versions and link the newest version first on * the list. */ - if ((rval = cert_install(ep, peer)) != XEVNT_OK) + if ((xinfo = cert_install(ep, peer)) == NULL) { + rval = XEVNT_CRT; break; - + } peer->crypto |= CRYPTO_FLAG_SIGN; peer->flash &= ~TEST8; - temp32 = cinfo->nid; - snprintf(statstr, NTP_MAXSTRLEN, - "sign %s 0x%x %s (%u) fs %u", - cinfo->issuer, cinfo->flags, + temp32 = xinfo->nid; + snprintf(statstr, sizeof(statstr), + "sign %s %s 0x%x %s (%u) fs %u", + xinfo->subject, xinfo->issuer, xinfo->flags, OBJ_nid2ln(temp32), temp32, ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* - * Install leapseconds table in symmetric modes. This - * table is proventicated to the NIST primary servers, - * either by copying the file containing the table from - * a NIST server to a trusted server or directly using - * this protocol. While the entire table is installed at - * the server, presently only the current TAI offset is - * provided via the kernel to other applications. + * Install leapseconds values. While the leapsecond + * values epoch, TAI offset and values expiration epoch + * are retained, only the current TAI offset is provided + * via the kernel to other applications. */ - case CRYPTO_TAI: - - /* - * Discard the message if invalid. - */ - if ((rval = crypto_verify(ep, NULL, peer)) != - XEVNT_OK) - break; - + case CRYPTO_LEAP | CRYPTO_RESP: /* - * Pass the extension field to the transmit - * side. Continue below if a leapseconds table - * accompanies the message. + * Discard the message if invalid. We can't + * compare the value timestamps here, as they + * can be updated by different servers. */ - fp = emalloc(len); - memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); - peer->cmmd = fp; - if (len <= VALUE_LEN) { - peer->flash &= ~TEST8; + rval = crypto_verify(ep, NULL, peer); + if ((rval != XEVNT_OK ) || + (vallen != 3*sizeof(uint32_t)) ) break; - } - /* fall through */ - - case CRYPTO_TAI | CRYPTO_RESP: - - /* - * If this is a response, discard the message if - * signature not verified with respect to the - * leapsecond table values. - */ - if (peer->cmmd == NULL) { - if ((rval = crypto_verify(ep, - &peer->tai_leap, peer)) != XEVNT_OK) - break; - } - - /* - * Initialize peer variables with latest update. - */ - peer->tai_leap.tstamp = ep->tstamp; - peer->tai_leap.fstamp = ep->fstamp; - peer->tai_leap.vallen = ep->vallen; - /* - * Install the new table if there is no stored - * table or the new table is more recent than - * the stored table. Since a filestamp may have - * changed, recompute the signatures. + /* Check if we can update the basic TAI offset + * for our current leap frame. This is a hack + * and ignores the time stamps in the autokey + * message. */ - if (ntohl(peer->tai_leap.fstamp) > - ntohl(tai_leap.fstamp)) { - tai_leap.fstamp = ep->fstamp; - tai_leap.vallen = ep->vallen; - if (tai_leap.ptr != NULL) - free(tai_leap.ptr); - tai_leap.ptr = emalloc(vallen); - memcpy(tai_leap.ptr, ep->pkt, vallen); - crypto_update(); - } - crypto_flags |= CRYPTO_FLAG_TAI; + if (sys_leap != LEAP_NOTINSYNC) + leapsec_autokey_tai(ntohl(ep->pkt[0]), + rbufp->recv_time.l_ui, NULL); + tai_leap.tstamp = ep->tstamp; + tai_leap.fstamp = ep->fstamp; + crypto_update(); + mprintf_event(EVNT_TAI, peer, + "%d seconds", ntohl(ep->pkt[0])); peer->crypto |= CRYPTO_FLAG_LEAP; peer->flash &= ~TEST8; - snprintf(statstr, NTP_MAXSTRLEN, - "leap %u ts %u fs %u", vallen, - ntohl(ep->tstamp), ntohl(ep->fstamp)); + snprintf(statstr, sizeof(statstr), + "leap TAI offset %d at %u expire %u fs %u", + ntohl(ep->pkt[0]), ntohl(ep->pkt[1]), + ntohl(ep->pkt[2]), ntohl(ep->fstamp)); record_crypto_stats(&peer->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_recv: %s\n", statstr)); break; /* * We come here in symmetric modes for miscellaneous * commands that have value fields but are processed on * the transmit side. All we need do here is check for - * valid field length. Remaining checks are below and on - * the transmit side. + * valid field length. Note that ASSOC is handled + * separately. */ case CRYPTO_CERT: case CRYPTO_IFF: case CRYPTO_GQ: case CRYPTO_MV: + case CRYPTO_COOK: case CRYPTO_SIGN: if (len < VALUE_LEN) { rval = XEVNT_LEN; @@ -1121,49 +1020,36 @@ crypto_recv( /* fall through */ /* - * We come here for miscellaneous requests and unknown - * requests and responses. If an unknown response or - * error, forget it. If a request, save the extension - * field for later. Unknown requests will be caught on - * the transmit side. + * We come here in symmetric modes for requests + * requiring a response (above plus AUTO and LEAP) and + * for responses. If a request, save the extension field + * for later; invalid requests will be caught on the + * transmit side. If an error or invalid response, + * declare a protocol error. */ default: if (code & (CRYPTO_RESP | CRYPTO_ERROR)) { rval = XEVNT_ERR; - } else if ((rval = crypto_verify(ep, NULL, - peer)) == XEVNT_OK) { + } else if (peer->cmmd == NULL) { fp = emalloc(len); memcpy(fp, ep, len); - temp32 = CRYPTO_RESP; - fp->opcode |= htonl(temp32); peer->cmmd = fp; } } /* - * We don't log length/format/timestamp errors and - * duplicates, which are log clogging vulnerabilities. * The first error found terminates the extension field - * scan and we return the laundry to the caller. A - * length/format/timestamp error on transmit is - * cheerfully ignored, as the message is not sent. + * scan and we return the laundry to the caller. */ - if (rval > XEVNT_TSP) { - snprintf(statstr, NTP_MAXSTRLEN, - "error %x opcode %x ts %u fs %u", rval, - code, tstamp, fstamp); + if (rval != XEVNT_OK) { + snprintf(statstr, sizeof(statstr), + "%04x %d %02x %s", htonl(ep->opcode), + associd, rval, eventstr(rval)); record_crypto_stats(&peer->srcadr, statstr); - report_event(rval, peer); -#ifdef DEBUG - if (debug) - printf("crypto_recv: %s\n", statstr); -#endif - break; - - } else if (rval > XEVNT_OK && (code & CRYPTO_RESP)) { - rval = XEVNT_OK; + DPRINTF(1, ("crypto_recv: %s\n", statstr)); + return (rval); } - authlen += len; + authlen += (len + 3) / 4 * 4; } return (rval); } @@ -1177,30 +1063,39 @@ crypto_recv( * autokey information, in which case the caller has to provide the * association ID to match the association. * - * Returns length of extension field. + * Side effect: update the packet offset. + * + * Errors + * XEVNT_OK success + * XEVNT_CRT bad or missing certificate + * XEVNT_ERR protocol error + * XEVNT_LEN bad field format or length + * XEVNT_PER host certificate expired */ int crypto_xmit( + struct peer *peer, /* peer structure pointer */ struct pkt *xpkt, /* transmit packet pointer */ - struct sockaddr_storage *srcadr_sin, /* active runway */ + struct recvbuf *rbufp, /* receive buffer pointer */ int start, /* offset to extension field */ struct exten *ep, /* extension pointer */ keyid_t cookie /* session cookie */ ) { + struct exten *fp; /* extension pointers */ + struct cert_info *cp, *xp, *yp; /* cert info/value pointer */ + sockaddr_u *srcadr_sin; /* source address */ u_int32 *pkt; /* packet pointer */ - struct peer *peer; /* peer structure pointer */ u_int opcode; /* extension field opcode */ - struct exten *fp; /* extension pointers */ - struct cert_info *cp, *xp; /* certificate info/value pointer */ char certname[MAXHOSTNAME + 1]; /* subject name buffer */ char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ tstamp_t tstamp; + struct calendar tscal; u_int vallen; - u_int len; struct value vtemp; associd_t associd; int rval; + int len; keyid_t tcookie; /* @@ -1211,9 +1106,17 @@ crypto_xmit( pkt = (u_int32 *)xpkt + start / 4; fp = (struct exten *)pkt; opcode = ntohl(ep->opcode); + if (peer != NULL) { + srcadr_sin = &peer->srcadr; + if (!(opcode & CRYPTO_RESP)) + peer->opcode = ep->opcode; + } else { + srcadr_sin = &rbufp->recv_srcadr; + } associd = (associd_t) ntohl(ep->associd); - fp->associd = htonl(associd); len = 8; + fp->opcode = htonl((opcode & 0xffff0000) | len); + fp->associd = ep->associd; rval = XEVNT_OK; tstamp = crypto_time(); switch (opcode & 0xffff0000) { @@ -1223,16 +1126,12 @@ crypto_xmit( * host name. Note, this message is not signed and the filestamp * contains only the status word. */ + case CRYPTO_ASSOC: case CRYPTO_ASSOC | CRYPTO_RESP: - len += crypto_send(fp, &hostval); + len = crypto_send(fp, &hostval, start); fp->fstamp = htonl(crypto_flags); break; - case CRYPTO_ASSOC: - len += crypto_send(fp, &hostval); - fp->fstamp = htonl(crypto_flags | ident_scheme); - break; - /* * Send certificate request. Use the values from the extension * field. @@ -1243,89 +1142,98 @@ crypto_xmit( vtemp.fstamp = ep->fstamp; vtemp.vallen = ep->vallen; vtemp.ptr = (u_char *)ep->pkt; - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); break; /* - * Send certificate response or sign request. Use the values - * from the certificate cache. If the request contains no - * subject name, assume the name of this host. This is for - * backwards compatibility. Private certificates are never sent. + * Send sign request. Use the host certificate, which is self- + * signed and may or may not be trusted. */ case CRYPTO_SIGN: + (void)ntpcal_ntp_to_date(&tscal, tstamp, NULL); + if ((calcomp(&tscal, &(cert_host->first)) < 0) + || (calcomp(&tscal, &(cert_host->last)) > 0)) + rval = XEVNT_PER; + else + len = crypto_send(fp, &cert_host->cert, start); + break; + + /* + * Send certificate response. Use the name in the extension + * field to find the certificate in the cache. If the request + * contains no subject name, assume the name of this host. This + * is for backwards compatibility. Private certificates are + * never sent. + * + * There may be several certificates matching the request. First + * choice is a self-signed trusted certificate; second choice is + * any certificate signed by another host. There is no third + * choice. + */ case CRYPTO_CERT | CRYPTO_RESP: - vallen = ntohl(ep->vallen); - if (vallen == 8) { - strcpy(certname, sys_hostname); - } else if (vallen == 0 || vallen > MAXHOSTNAME || - len - VALUE_LEN < vallen) { + vallen = exten_payload_size(ep); /* Must be <64k */ + if (vallen == 0 || vallen >= sizeof(certname) ) { rval = XEVNT_LEN; break; - - } else { - memcpy(certname, ep->pkt, vallen); - certname[vallen] = '\0'; } /* - * Find all certificates with matching subject. If a - * self-signed, trusted certificate is found, use that. - * If not, use the first one with matching subject. A - * private certificate is never divulged or signed. + * Find all public valid certificates with matching + * subject. If a self-signed, trusted certificate is + * found, use that certificate. If not, use the last non + * self-signed certificate. */ - xp = NULL; + memcpy(certname, ep->pkt, vallen); + certname[vallen] = '\0'; + xp = yp = NULL; for (cp = cinfo; cp != NULL; cp = cp->link) { - if (cp->flags & CERT_PRIV) + if (cp->flags & (CERT_PRIV | CERT_ERROR)) continue; - if (strcmp(certname, cp->subject) == 0) { - if (xp == NULL) - xp = cp; - if (strcmp(certname, cp->issuer) == - 0 && cp->flags & CERT_TRUST) { - xp = cp; - break; - } - } + if (strcmp(certname, cp->subject) != 0) + continue; + + if (strcmp(certname, cp->issuer) != 0) + yp = cp; + else if (cp ->flags & CERT_TRUST) + xp = cp; + continue; } /* - * Be careful who you trust. If not yet synchronized, - * give back an empty response. If certificate not found - * or beyond the lifetime, return an error. This is to - * avoid a bad dude trying to get an expired certificate - * re-signed. Otherwise, send it. + * Be careful who you trust. If the certificate is not + * found, return an empty response. Note that we dont + * enforce lifetimes here. * - * Note the timestamp and filestamp are taken from the + * The timestamp and filestamp are taken from the * certificate value structure. For all certificates the * timestamp is the latest signature update time. For * host and imported certificates the filestamp is the * creation epoch. For signed certificates the filestamp * is the creation epoch of the trusted certificate at - * the base of the certificate trail. In principle, this + * the root of the certificate trail. In principle, this * allows strong checking for signature masquerade. */ + if (xp == NULL) + xp = yp; + if (xp == NULL) + break; + if (tstamp == 0) break; - if (xp == NULL) - rval = XEVNT_CRT; - else if (tstamp < xp->first || tstamp > xp->last) - rval = XEVNT_SRV; - else - len += crypto_send(fp, &xp->cert); + len = crypto_send(fp, &xp->cert, start); break; /* * Send challenge in Schnorr (IFF) identity scheme. */ case CRYPTO_IFF: - if ((peer = findpeerbyassoc(ep->pkt[0])) == NULL) { - rval = XEVNT_ERR; - break; - } + if (peer == NULL) + break; /* hack attack */ + if ((rval = crypto_alice(peer, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1335,7 +1243,7 @@ crypto_xmit( */ case CRYPTO_IFF | CRYPTO_RESP: if ((rval = crypto_bob(ep, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1344,12 +1252,11 @@ crypto_xmit( * Send challenge in Guillou-Quisquater (GQ) identity scheme. */ case CRYPTO_GQ: - if ((peer = findpeerbyassoc(ep->pkt[0])) == NULL) { - rval = XEVNT_ERR; - break; - } + if (peer == NULL) + break; /* hack attack */ + if ((rval = crypto_alice2(peer, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1359,7 +1266,7 @@ crypto_xmit( */ case CRYPTO_GQ | CRYPTO_RESP: if ((rval = crypto_bob2(ep, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1368,12 +1275,11 @@ crypto_xmit( * Send challenge in MV identity scheme. */ case CRYPTO_MV: - if ((peer = findpeerbyassoc(ep->pkt[0])) == NULL) { - rval = XEVNT_ERR; - break; - } + if (peer == NULL) + break; /* hack attack */ + if ((rval = crypto_alice3(peer, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1383,7 +1289,7 @@ crypto_xmit( */ case CRYPTO_MV | CRYPTO_RESP: if ((rval = crypto_bob3(ep, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1397,9 +1303,10 @@ crypto_xmit( * invalid or contains an unverified signature. */ case CRYPTO_SIGN | CRYPTO_RESP: - if ((rval = cert_sign(ep, &vtemp)) == XEVNT_OK) - len += crypto_send(fp, &vtemp); - value_free(&vtemp); + if ((rval = cert_sign(ep, &vtemp)) == XEVNT_OK) { + len = crypto_send(fp, &vtemp, start); + value_free(&vtemp); + } break; /* @@ -1407,7 +1314,7 @@ crypto_xmit( * key. */ case CRYPTO_COOK: - len += crypto_send(fp, &pubkey); + len = crypto_send(fp, &pubkey, start); break; /* @@ -1422,18 +1329,13 @@ crypto_xmit( rval = XEVNT_LEN; break; } - if (PKT_MODE(xpkt->li_vn_mode) == MODE_SERVER) { + if (peer == NULL) tcookie = cookie; - } else { - if ((peer = findpeerbyassoc(associd)) == NULL) { - rval = XEVNT_ERR; - break; - } - tcookie = peer->pcookie; - } + else + tcookie = peer->hcookie; if ((rval = crypto_encrypt((const u_char *)ep->pkt, vallen, &tcookie, &vtemp)) == XEVNT_OK) { - len += crypto_send(fp, &vtemp); + len = crypto_send(fp, &vtemp, start); value_free(&vtemp); } break; @@ -1446,28 +1348,28 @@ crypto_xmit( * old message, in which case light the error bit. */ case CRYPTO_AUTO | CRYPTO_RESP: - if ((peer = findpeerbyassoc(associd)) == NULL) { - rval = XEVNT_ERR; - break; + if (peer == NULL) { + if ((peer = findpeerbyassoc(associd)) == NULL) { + rval = XEVNT_ERR; + break; + } } peer->flags &= ~FLAG_ASSOC; - len += crypto_send(fp, &peer->sndval); + len = crypto_send(fp, &peer->sndval, start); break; /* - * Send leapseconds table and signature. Use the values from the - * tai structure. If no table has been loaded, just send an + * Send leapseconds values and signature. Use the values from + * the tai structure. If no table has been loaded, just send an * empty request. */ - case CRYPTO_TAI: - case CRYPTO_TAI | CRYPTO_RESP: - if (crypto_flags & CRYPTO_FLAG_TAI) - len += crypto_send(fp, &tai_leap); + case CRYPTO_LEAP | CRYPTO_RESP: + len = crypto_send(fp, &tai_leap, start); break; /* - * Default - Fall through for requests; for unknown responses, - * flag as error. + * Default - Send a valid command for unknown requests; send + * an error response for unknown resonses. */ default: if (opcode & CRYPTO_RESP) @@ -1479,47 +1381,37 @@ crypto_xmit( * puppy; if a response, return so the sender can flame, too. */ if (rval != XEVNT_OK) { - opcode |= CRYPTO_ERROR; - snprintf(statstr, NTP_MAXSTRLEN, - "error %x opcode %x", rval, opcode); + u_int32 uint32; + + uint32 = CRYPTO_ERROR; + opcode |= uint32; + fp->opcode |= htonl(uint32); + snprintf(statstr, sizeof(statstr), + "%04x %d %02x %s", opcode, associd, rval, + eventstr(rval)); record_crypto_stats(srcadr_sin, statstr); - report_event(rval, NULL); -#ifdef DEBUG - if (debug) - printf("crypto_xmit: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_xmit: %s\n", statstr)); if (!(opcode & CRYPTO_RESP)) return (0); } - - /* - * Round up the field length to a multiple of 8 bytes and save - * the request code and length. - */ - len = ((len + 7) / 8) * 8; - fp->opcode = htonl((opcode & 0xffff0000) | len); -#ifdef DEBUG - if (debug) - printf( - "crypto_xmit: flags 0x%x ext offset %d len %u code 0x%x assocID %d\n", - crypto_flags, start, len, opcode >> 16, associd); -#endif - return (len); -} + DPRINTF(1, ("crypto_xmit: flags 0x%x offset %d len %d code 0x%x associd %d\n", + crypto_flags, start, len, opcode >> 16, associd)); + return (len); +} /* - * crypto_verify - parse and verify the extension field and value + * crypto_verify - verify the extension field value and signature * * Returns * XEVNT_OK success - * XEVNT_LEN bad field format or length - * XEVNT_TSP bad timestamp + * XEVNT_ERR protocol error * XEVNT_FSP bad filestamp + * XEVNT_LEN bad field format or length * XEVNT_PUB bad or missing public key * XEVNT_SGL bad signature length * XEVNT_SIG signature not verified - * XEVNT_ERR protocol error + * XEVNT_TSP bad timestamp */ static int crypto_verify( @@ -1538,41 +1430,47 @@ crypto_verify( int i; /* - * We require valid opcode and field lengths, timestamp, - * filestamp, public key, digest, signature length and - * signature, where relevant. Note that preliminary length - * checks are done in the main loop. + * We are extremely parannoyed. We require valid opcode, length, + * association ID, timestamp, filestamp, public key, digest, + * signature length and signature, where relevant. Note that + * preliminary length checks are done in the main loop. */ len = ntohl(ep->opcode) & 0x0000ffff; opcode = ntohl(ep->opcode) & 0xffff0000; /* - * Check for valid operation code and protocol. The opcode must - * not have the error bit set. If a response, it must have a - * value header. If a request and does not contain a value - * header, no need for further checking. + * Check for valid value header, association ID and extension + * field length. Remember, it is not an error to receive an + * unsolicited response; however, the response ID must match + * the association ID. */ if (opcode & CRYPTO_ERROR) return (XEVNT_ERR); - if (opcode & CRYPTO_RESP) { - if (len < VALUE_LEN) - return (XEVNT_LEN); + if (len < VALUE_LEN) + return (XEVNT_LEN); + + if (opcode == (CRYPTO_AUTO | CRYPTO_RESP) && (peer->pmode == + MODE_BROADCAST || (peer->cast_flags & MDF_BCLNT))) { + if (ntohl(ep->associd) != peer->assoc) + return (XEVNT_ERR); } else { - if (len < VALUE_LEN) - return (XEVNT_OK); + if (ntohl(ep->associd) != peer->associd) + return (XEVNT_ERR); } /* - * We have a value header. Check for valid field lengths. The - * field length must be long enough to contain the value header, - * value and signature. Note both the value and signature fields - * are rounded up to the next word. + * We have a valid value header. Check for valid value and + * signature field lengths. The extension field length must be + * long enough to contain the value header, value and signature. + * Note both the value and signature field lengths are rounded + * up to the next word (4 octets). */ vallen = ntohl(ep->vallen); if ( vallen == 0 || vallen > MAX_VALLEN) return (XEVNT_LEN); + i = (vallen + 3) / 4; siglen = ntohl(ep->pkt[i++]); if ( siglen > MAX_VALLEN @@ -1581,33 +1479,17 @@ crypto_verify( < ((siglen + 3) / 4) * 4) return (XEVNT_LEN); - /* - * Punt if this is a response with no data. Punt if this is a - * request and a previous response is pending. - */ - if (opcode & CRYPTO_RESP) { - if (vallen == 0) - return (XEVNT_LEN); - } else { - if (peer->cmmd != NULL) - return (XEVNT_LEN); - } - /* * Check for valid timestamp and filestamp. If the timestamp is * zero, the sender is not synchronized and signatures are - * disregarded. If not, the timestamp must not precede the + * not possible. If nonzero the timestamp must not precede the * filestamp. The timestamp and filestamp must not precede the - * corresponding values in the value structure, if present. Once - * the autokey values have been installed, the timestamp must - * always be later than the corresponding value in the value - * structure. Duplicate timestamps are illegal once the cookie - * has been validated. - */ + * corresponding values in the value structure, if present. + */ tstamp = ntohl(ep->tstamp); fstamp = ntohl(ep->fstamp); if (tstamp == 0) - return (XEVNT_OK); + return (XEVNT_TSP); if (tstamp < fstamp) return (XEVNT_TSP); @@ -1615,14 +1497,23 @@ crypto_verify( if (vp != NULL) { tstamp1 = ntohl(vp->tstamp); fstamp1 = ntohl(vp->fstamp); - if ((tstamp < tstamp1 || (tstamp == tstamp1 && - (peer->crypto & CRYPTO_FLAG_AUTO)))) - return (XEVNT_TSP); + if (tstamp1 != 0 && fstamp1 != 0) { + if (tstamp < tstamp1) + return (XEVNT_TSP); - if ((tstamp < fstamp1 || fstamp < fstamp1)) - return (XEVNT_FSP); + if ((tstamp < fstamp1 || fstamp < fstamp1)) + return (XEVNT_FSP); + } } + /* + * At the time the certificate message is validated, the public + * key in the message is not available. Thus, don't try to + * verify the signature. + */ + if (opcode == (CRYPTO_CERT | CRYPTO_RESP)) + return (XEVNT_OK); + /* * Check for valid signature length, public key and digest * algorithm. @@ -1632,7 +1523,7 @@ crypto_verify( else pkey = peer->pkey; if (siglen == 0 || pkey == NULL || peer->digest == NULL) - return (XEVNT_OK); + return (XEVNT_ERR); if (siglen != (u_int)EVP_PKEY_size(pkey)) return (XEVNT_SGL); @@ -1640,20 +1531,17 @@ crypto_verify( /* * Darn, I thought we would never get here. Verify the * signature. If the identity exchange is verified, light the - * proventic bit. If no client identity scheme is specified, - * avoid doing the sign exchange. + * proventic bit. What a relief. */ EVP_VerifyInit(&ctx, peer->digest); /* XXX: the "+ 12" needs to be at least documented... */ EVP_VerifyUpdate(&ctx, (u_char *)&ep->tstamp, vallen + 12); - if (EVP_VerifyFinal(&ctx, (u_char *)&ep->pkt[i], siglen, pkey) <= 0) + if (EVP_VerifyFinal(&ctx, (u_char *)&ep->pkt[i], siglen, + pkey) <= 0) return (XEVNT_SIG); - if (peer->crypto & CRYPTO_FLAG_VRFY) { + if (peer->crypto & CRYPTO_FLAG_VRFY) peer->crypto |= CRYPTO_FLAG_PROV; - if (!(crypto_flags & CRYPTO_FLAG_MASK)) - peer->crypto |= CRYPTO_FLAG_SIGN; - } return (XEVNT_OK); } @@ -1664,9 +1552,8 @@ crypto_verify( * * Returns: * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_CKY bad or missing cookie - * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key */ static int crypto_encrypt( @@ -1680,13 +1567,14 @@ crypto_encrypt( EVP_MD_CTX ctx; /* signature context */ tstamp_t tstamp; /* NTP timestamp */ u_int32 temp32; + u_char *puch; /* * Extract the public key from the request. */ pkey = d2i_PublicKey(EVP_PKEY_RSA, NULL, &ptr, vallen); if (pkey == NULL) { - msyslog(LOG_ERR, "crypto_encrypt %s\n", + msyslog(LOG_ERR, "crypto_encrypt: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_PUB); } @@ -1694,35 +1582,35 @@ crypto_encrypt( /* * Encrypt the cookie, encode in ASN.1 and sign. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); vp->fstamp = hostval.tstamp; vallen = EVP_PKEY_size(pkey); vp->vallen = htonl(vallen); vp->ptr = emalloc(vallen); + puch = vp->ptr; temp32 = htonl(*cookie); - if (!RSA_public_encrypt(4, (u_char *)&temp32, vp->ptr, - pkey->pkey.rsa, RSA_PKCS1_OAEP_PADDING)) { - msyslog(LOG_ERR, "crypto_encrypt %s\n", + if (RSA_public_encrypt(4, (u_char *)&temp32, puch, + pkey->pkey.rsa, RSA_PKCS1_OAEP_PADDING) <= 0) { + msyslog(LOG_ERR, "crypto_encrypt: %s", ERR_error_string(ERR_get_error(), NULL)); + free(vp->ptr); EVP_PKEY_free(pkey); return (XEVNT_CKY); } EVP_PKEY_free(pkey); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, vallen); - if (EVP_SignFinal(&ctx, vp->sig, &vallen, sign_pkey)) - vp->siglen = htonl(sign_siglen); + if (EVP_SignFinal(&ctx, vp->sig, &vallen, sign_pkey)) { + INSIST(vallen <= sign_siglen); + vp->siglen = htonl(vallen); + } return (XEVNT_OK); } @@ -1732,71 +1620,54 @@ crypto_encrypt( * * This routine determines which identity scheme is in use and * constructs an extension field for that scheme. + * + * Returns + * CRYTPO_IFF IFF scheme + * CRYPTO_GQ GQ scheme + * CRYPTO_MV MV scheme + * CRYPTO_NULL no available scheme */ u_int crypto_ident( struct peer *peer /* peer structure pointer */ ) { - char filename[MAXFILENAME + 1]; + char filename[MAXFILENAME]; + const char * scheme_name; + u_int scheme_id; /* - * If the server identity has already been verified, no further - * action is necessary. Otherwise, try to load the identity file - * of the certificate issuer. If the issuer file is not found, - * try the host file. If nothing found, declare a cryptobust. - * Note we can't get here unless the trusted certificate has - * been found and the CRYPTO_FLAG_VALID bit is set, so the - * certificate issuer is valid. + * We come here after the group trusted host has been found; its + * name defines the group name. Search the key cache for all + * keys matching the same group name in order IFF, GQ and MV. + * Use the first one available. */ - if (peer->ident_pkey != NULL) - EVP_PKEY_free(peer->ident_pkey); - if (peer->crypto & CRYPTO_FLAG_GQ) { - snprintf(filename, MAXFILENAME, "ntpkey_gq_%s", - peer->issuer); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_GQ); - - snprintf(filename, MAXFILENAME, "ntpkey_gq_%s", - sys_hostname); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_GQ); - } + scheme_name = NULL; if (peer->crypto & CRYPTO_FLAG_IFF) { - snprintf(filename, MAXFILENAME, "ntpkey_iff_%s", - peer->issuer); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_IFF); - - snprintf(filename, MAXFILENAME, "ntpkey_iff_%s", - sys_hostname); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); + scheme_name = "iff"; + scheme_id = CRYPTO_IFF; + } else if (peer->crypto & CRYPTO_FLAG_GQ) { + scheme_name = "gq"; + scheme_id = CRYPTO_GQ; + } else if (peer->crypto & CRYPTO_FLAG_MV) { + scheme_name = "mv"; + scheme_id = CRYPTO_MV; + } + + if (scheme_name != NULL) { + snprintf(filename, sizeof(filename), "ntpkey_%spar_%s", + scheme_name, peer->ident); + peer->ident_pkey = crypto_key(filename, NULL, + &peer->srcadr); if (peer->ident_pkey != NULL) - return (CRYPTO_IFF); + return scheme_id; } - if (peer->crypto & CRYPTO_FLAG_MV) { - snprintf(filename, MAXFILENAME, "ntpkey_mv_%s", - peer->issuer); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_MV); - snprintf(filename, MAXFILENAME, "ntpkey_mv_%s", - sys_hostname); - peer->ident_pkey = crypto_key(filename, &peer->fstamp); - if (peer->ident_pkey != NULL) - return (CRYPTO_MV); - } + msyslog(LOG_NOTICE, + "crypto_ident: no identity parameters found for group %s", + peer->ident); - /* - * No compatible identity scheme is available. Life is hard. - */ - msyslog(LOG_INFO, - "crypto_ident: no compatible identity scheme found"); - return (0); + return CRYPTO_NULL; } @@ -1808,7 +1679,7 @@ crypto_ident( * extension field is created here, but freed after the crypto_xmit() * call in the protocol module. * - * Returns extension field pointer (no errors). + * Returns extension field pointer (no errors) * * XXX: opcode and len should really be 32-bit quantities and * we should make sure that str is not too big. @@ -1817,43 +1688,37 @@ struct exten * crypto_args( struct peer *peer, /* peer structure pointer */ u_int opcode, /* operation code */ + associd_t associd, /* association ID */ char *str /* argument string */ ) { tstamp_t tstamp; /* NTP timestamp */ struct exten *ep; /* extension field pointer */ u_int len; /* extension field length */ - size_t slen; + size_t slen = 0; tstamp = crypto_time(); len = sizeof(struct exten); if (str != NULL) { slen = strlen(str); + INSIST(slen < MAX_VALLEN); len += slen; } - ep = emalloc(len); - memset(ep, 0, len); + ep = emalloc_zero(len); if (opcode == 0) return (ep); - ep->opcode = htonl(opcode + len); + REQUIRE(0 == (len & ~0x0000ffff)); + REQUIRE(0 == (opcode & ~0xffff0000)); - /* - * If a response, send our ID; if a request, send the - * responder's ID. - */ - if (opcode & CRYPTO_RESP) - ep->associd = htonl(peer->associd); - else - ep->associd = htonl(peer->assoc); + ep->opcode = htonl(opcode + len); + ep->associd = htonl(associd); ep->tstamp = htonl(tstamp); ep->fstamp = hostval.tstamp; ep->vallen = 0; if (str != NULL) { ep->vallen = htonl(slen); memcpy((char *)ep->pkt, str, slen); - } else { - ep->pkt[0] = peer->associd; } return (ep); } @@ -1862,44 +1727,71 @@ crypto_args( /* * crypto_send - construct extension field from value components * - * Returns extension field length. Note: it is not polite to send a - * nonempty signature with zero timestamp or a nonzero timestamp with - * empty signature, but these rules are not enforced here. + * The value and signature fields are zero-padded to a word boundary. + * Note: it is not polite to send a nonempty signature with zero + * timestamp or a nonzero timestamp with an empty signature, but those + * rules are not enforced here. * * XXX This code won't work on a box with 16-bit ints. */ -u_int +int crypto_send( struct exten *ep, /* extension field pointer */ - struct value *vp /* value pointer */ + struct value *vp, /* value pointer */ + int start /* buffer offset */ ) { - u_int len, temp32; - int i; + u_int len, vallen, siglen, opcode; + u_int i, j; + + /* + * Calculate extension field length and check for buffer + * overflow. Leave room for the MAC. + */ + len = 16; /* XXX Document! */ + vallen = ntohl(vp->vallen); + INSIST(vallen <= MAX_VALLEN); + len += ((vallen + 3) / 4 + 1) * 4; + siglen = ntohl(vp->siglen); + len += ((siglen + 3) / 4 + 1) * 4; + if (start + len > sizeof(struct pkt) - MAX_MAC_LEN) + return (0); /* - * Copy data. If the data field is empty or zero length, encode - * an empty value with length zero. + * Copy timestamps. */ ep->tstamp = vp->tstamp; ep->fstamp = vp->fstamp; ep->vallen = vp->vallen; - len = 12; - temp32 = ntohl(vp->vallen); - if (temp32 > 0 && vp->ptr != NULL) - memcpy(ep->pkt, vp->ptr, temp32); + + /* + * Copy value. If the data field is empty or zero length, + * encode an empty value with length zero. + */ + i = 0; + if (vallen > 0 && vp->ptr != NULL) { + j = vallen / 4; + if (j * 4 < vallen) + ep->pkt[i + j++] = 0; + memcpy(&ep->pkt[i], vp->ptr, vallen); + i += j; + } /* * Copy signature. If the signature field is empty or zero * length, encode an empty signature with length zero. */ - i = (temp32 + 3) / 4; - len += i * 4 + 4; ep->pkt[i++] = vp->siglen; - temp32 = ntohl(vp->siglen); - if (temp32 > 0 && vp->sig != NULL) - memcpy(&ep->pkt[i], vp->sig, temp32); - len += temp32; + if (siglen > 0 && vp->sig != NULL) { + j = siglen / 4; + if (j * 4 < siglen) + ep->pkt[i + j++] = 0; + memcpy(&ep->pkt[i], vp->sig, siglen); + /* i += j; */ /* We don't use i after this */ + } + opcode = ntohl(ep->opcode); + ep->opcode = htonl((opcode & 0xffff0000) | len); + ENSURE(len <= MAX_VALLEN); return (len); } @@ -1914,12 +1806,11 @@ crypto_send( * hostval host name (not signed) * pubkey public key * cinfo certificate info/value list - * tai_leap leapseconds file + * tai_leap leap values * - * Filestamps are proventicated data, so this routine is run only when - * the host has been synchronized to a proventicated source. Thus, the - * timestamp is proventicated, too, and can be used to deflect - * clogging attacks and even cook breakfast. + * Filestamps are proventic data, so this routine runs only when the + * host is synchronized to a proventicated source. Thus, the timestamp + * is proventic and can be used to deflect clogging attacks. * * Returns void (no errors) */ @@ -1927,16 +1818,16 @@ void crypto_update(void) { EVP_MD_CTX ctx; /* message digest context */ - struct cert_info *cp, *cpn; /* certificate info/value */ + struct cert_info *cp; /* certificate info/value */ char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ - tstamp_t tstamp; /* NTP timestamp */ + u_int32 *ptr; u_int len; + leap_result_t leap_data; - if ((tstamp = crypto_time()) == 0) + hostval.tstamp = htonl(crypto_time()); + if (hostval.tstamp == 0) return; - hostval.tstamp = htonl(tstamp); - /* * Sign public key and timestamps. The filestamp is derived from * the host key file extension from wherever the file was @@ -1950,8 +1841,10 @@ crypto_update(void) EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&pubkey, 12); EVP_SignUpdate(&ctx, pubkey.ptr, ntohl(pubkey.vallen)); - if (EVP_SignFinal(&ctx, pubkey.sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, pubkey.sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); pubkey.siglen = htonl(len); + } } /* @@ -1960,8 +1853,7 @@ crypto_update(void) * was generated. Note we do not throw expired certificates * away; they may have signed younger ones. */ - for (cp = cinfo; cp != NULL; cp = cpn) { - cpn = cp->link; + for (cp = cinfo; cp != NULL; cp = cp->link) { cp->cert.tstamp = hostval.tstamp; cp->cert.siglen = 0; if (cp->cert.sig == NULL) @@ -1970,36 +1862,98 @@ crypto_update(void) EVP_SignUpdate(&ctx, (u_char *)&cp->cert, 12); EVP_SignUpdate(&ctx, cp->cert.ptr, ntohl(cp->cert.vallen)); - if (EVP_SignFinal(&ctx, cp->cert.sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, cp->cert.sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); cp->cert.siglen = htonl(len); + } } /* - * Sign leapseconds table and timestamps. The filestamp is - * derived from the leapsecond file extension from wherever the - * file was generated. + * Sign leapseconds values and timestamps. Note it is not an + * error to return null values. */ - if (tai_leap.vallen != 0) { - tai_leap.tstamp = hostval.tstamp; - tai_leap.siglen = 0; - if (tai_leap.sig == NULL) - tai_leap.sig = emalloc(sign_siglen); - EVP_SignInit(&ctx, sign_digest); - EVP_SignUpdate(&ctx, (u_char *)&tai_leap, 12); - EVP_SignUpdate(&ctx, tai_leap.ptr, - ntohl(tai_leap.vallen)); - if (EVP_SignFinal(&ctx, tai_leap.sig, &len, sign_pkey)) - tai_leap.siglen = htonl(len); + tai_leap.tstamp = hostval.tstamp; + tai_leap.fstamp = hostval.fstamp; + + /* Get the leap second era. We might need a full lookup early + * after start, when the cache is not yet loaded. + */ + leapsec_frame(&leap_data); + if ( ! memcmp(&leap_data.ebase, &leap_data.ttime, sizeof(vint64))) { + time_t now = time(NULL); + uint32_t nowntp = (uint32_t)now + JAN_1970; + leapsec_query(&leap_data, nowntp, &now); + } + + /* Create the data block. The protocol does not work without. */ + len = 3 * sizeof(u_int32); + if (tai_leap.ptr == NULL || ntohl(tai_leap.vallen) != len) { + free(tai_leap.ptr); + tai_leap.ptr = emalloc(len); + tai_leap.vallen = htonl(len); + } + ptr = (u_int32 *)tai_leap.ptr; + if (leap_data.tai_offs > 10) { + /* create a TAI / leap era block. The end time is a + * fake -- maybe we can do better. + */ + ptr[0] = htonl(leap_data.tai_offs); + ptr[1] = htonl(leap_data.ebase.d_s.lo); + if (leap_data.ttime.d_s.hi >= 0) + ptr[2] = htonl(leap_data.ttime.D_s.lo + 7*86400); + else + ptr[2] = htonl(leap_data.ebase.D_s.lo + 25*86400); + } else { + /* no leap era available */ + memset(ptr, 0, len); + } + if (tai_leap.sig == NULL) + tai_leap.sig = emalloc(sign_siglen); + EVP_SignInit(&ctx, sign_digest); + EVP_SignUpdate(&ctx, (u_char *)&tai_leap, 12); + EVP_SignUpdate(&ctx, tai_leap.ptr, len); + if (EVP_SignFinal(&ctx, tai_leap.sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); + tai_leap.siglen = htonl(len); } - snprintf(statstr, NTP_MAXSTRLEN, - "update ts %u", ntohl(hostval.tstamp)); + crypto_flags |= CRYPTO_FLAG_TAI; + + snprintf(statstr, sizeof(statstr), "signature update ts %u", + ntohl(hostval.tstamp)); record_crypto_stats(NULL, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_update: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_update: %s\n", statstr)); } +/* + * crypto_update_taichange - eventually trigger crypto_update + * + * This is called when a change in 'sys_tai' is detected. This will + * happen shortly after a leap second is detected, but unhappily also + * early after system start; also, the crypto stuff might be unused and + * an unguarded call to crypto_update() causes a crash. + * + * This function makes sure that there already *is* a valid crypto block + * for the use with autokey, and only calls 'crypto_update()' if it can + * succeed. + * + * Returns void (no errors) + */ +void +crypto_update_taichange(void) +{ + static const u_int len = 3 * sizeof(u_int32); + + /* check if the signing digest algo is available */ + if (sign_digest == NULL || sign_pkey == NULL) + return; + + /* check size of TAI extension block */ + if (tai_leap.ptr == NULL || ntohl(tai_leap.vallen) != len) + return; + + /* crypto_update should at least not crash here! */ + crypto_update(); +} /* * value_free - free value structure components. @@ -2020,12 +1974,14 @@ value_free( /* - * crypto_time - returns current NTP time in seconds. + * crypto_time - returns current NTP time. + * + * Returns NTP seconds if in synch, 0 otherwise */ tstamp_t crypto_time() { - l_fp tstamp; /* NTP time */ L_CLR(&tstamp); + l_fp tstamp; /* NTP time */ L_CLR(&tstamp); if (sys_leap != LEAP_NOTINSYNC) @@ -2035,46 +1991,71 @@ crypto_time() /* - * asn2ntp - convert ASN1_TIME time structure to NTP time in seconds. + * asn_to_calendar - convert ASN1_TIME time structure to struct calendar. + * */ -u_long -asn2ntp ( - ASN1_TIME *asn1time /* pointer to ASN1_TIME structure */ +static +void +asn_to_calendar ( + ASN1_TIME *asn1time, /* pointer to ASN1_TIME structure */ + struct calendar *pjd /* pointer to result */ ) { - char *v; /* pointer to ASN1_TIME string */ - struct tm tm; /* used to convert to NTP time */ + size_t len; /* length of ASN1_TIME string */ + char v[24]; /* writable copy of ASN1_TIME string */ + unsigned long temp; /* result from strtoul */ /* * Extract time string YYMMDDHHMMSSZ from ASN1 time structure. + * Or YYYYMMDDHHMMSSZ. * Note that the YY, MM, DD fields start with one, the HH, MM, - * SS fiels start with zero and the Z character should be 'Z' - * for UTC. Also note that years less than 50 map to years - * greater than 100. Dontcha love ASN.1? Better than MIL-188. - */ - if (asn1time->length > 13) - return ((u_long)(~0)); /* We can't use -1 here. It's invalid */ - - v = (char *)asn1time->data; - tm.tm_year = (v[0] - '0') * 10 + v[1] - '0'; - if (tm.tm_year < 50) - tm.tm_year += 100; - tm.tm_mon = (v[2] - '0') * 10 + v[3] - '0' - 1; - tm.tm_mday = (v[4] - '0') * 10 + v[5] - '0'; - tm.tm_hour = (v[6] - '0') * 10 + v[7] - '0'; - tm.tm_min = (v[8] - '0') * 10 + v[9] - '0'; - tm.tm_sec = (v[10] - '0') * 10 + v[11] - '0'; - tm.tm_wday = 0; - tm.tm_yday = 0; - tm.tm_isdst = 0; - return (timegm(&tm) + JAN_1970); + * SS fields start with zero and the Z character is ignored. + * Also note that two-digit years less than 50 map to years greater than + * 100. Dontcha love ASN.1? Better than MIL-188. + */ + len = asn1time->length; + REQUIRE(len < sizeof(v)); + (void)strncpy(v, (char *)(asn1time->data), len); + REQUIRE(len >= 13); + temp = strtoul(v+len-3, NULL, 10); + pjd->second = temp; + v[len-3] = '\0'; + + temp = strtoul(v+len-5, NULL, 10); + pjd->minute = temp; + v[len-5] = '\0'; + + temp = strtoul(v+len-7, NULL, 10); + pjd->hour = temp; + v[len-7] = '\0'; + + temp = strtoul(v+len-9, NULL, 10); + pjd->monthday = temp; + v[len-9] = '\0'; + + temp = strtoul(v+len-11, NULL, 10); + pjd->month = temp; + v[len-11] = '\0'; + + temp = strtoul(v, NULL, 10); + /* handle two-digit years */ + if (temp < 50UL) + temp += 100UL; + if (temp < 150UL) + temp += 1900UL; + pjd->year = temp; + + pjd->yearday = pjd->weekday = 0; + return; } /* * bigdig() - compute a BIGNUM MD5 hash of a BIGNUM number. + * + * Returns void (no errors) */ -static int +static void bighash( BIGNUM *bn, /* BIGNUM * from */ BIGNUM *bk /* BIGNUM * to */ @@ -2092,10 +2073,7 @@ bighash( EVP_DigestUpdate(&ctx, ptr, len); EVP_DigestFinal(&ctx, dgst, &len); BN_bin2bn(dgst, len, bk); - - /* XXX MEMLEAK? free ptr? */ - - return (1); + free(ptr); } @@ -2107,35 +2085,38 @@ bighash( *********************************************************************** * * The Schnorr (IFF) identity scheme is intended for use when - * the ntp-genkeys program does not generate the certificates used in - * the protocol and the group key cannot be conveyed in the certificate - * itself. For this purpose, new generations of IFF values must be - * securely transmitted to all members of the group before use. The - * scheme is self contained and independent of new generations of host - * keys, sign keys and certificates. - * - * The IFF identity scheme is based on DSA cryptography and algorithms - * described in Stinson p. 285. The IFF values hide in a DSA cuckoo - * structure, but only the primes and generator are used. The p is a - * 512-bit prime, q a 160-bit prime that divides p - 1 and is a qth root - * of 1 mod p; that is, g^q = 1 mod p. The TA rolls primvate random - * group key b disguised as a DSA structure member, then computes public - * key g^(q - b). These values are shared only among group members and - * never revealed in messages. Alice challenges Bob to confirm identity - * using the protocol described below. + * certificates are generated by some other trusted certificate + * authority and the certificate cannot be used to convey public + * parameters. There are two kinds of files: encrypted server files that + * contain private and public values and nonencrypted client files that + * contain only public values. New generations of server files must be + * securely transmitted to all servers of the group; client files can be + * distributed by any means. The scheme is self contained and + * independent of new generations of host keys, sign keys and + * certificates. + * + * The IFF values hide in a DSA cuckoo structure which uses the same + * parameters. The values are used by an identity scheme based on DSA + * cryptography and described in Stimson p. 285. The p is a 512-bit + * prime, g a generator of Zp* and q a 160-bit prime that divides p - 1 + * and is a qth root of 1 mod p; that is, g^q = 1 mod p. The TA rolls a + * private random group key b (0 < b < q) and public key v = g^b, then + * sends (p, q, g, b) to the servers and (p, q, g, v) to the clients. + * Alice challenges Bob to confirm identity using the protocol described + * below. * * How it works * * The scheme goes like this. Both Alice and Bob have the public primes * p, q and generator g. The TA gives private key b to Bob and public - * key v = g^(q - a) mod p to Alice. - * - * Alice rolls new random challenge r and sends to Bob in the IFF - * request message. Bob rolls new random k, then computes y = k + b r - * mod q and x = g^k mod p and sends (y, hash(x)) to Alice in the - * response message. Besides making the response shorter, the hash makes - * it effectivey impossible for an intruder to solve for b by observing - * a number of these messages. + * key v to Alice. + * + * Alice rolls new random challenge r (o < r < q) and sends to Bob in + * the IFF request message. Bob rolls new random k (0 < k < q), then + * computes y = k + b r mod q and x = g^k mod p and sends (y, hash(x)) + * to Alice in the response message. Besides making the response + * shorter, the hash makes it effectivey impossible for an intruder to + * solve for b by observing a number of these messages. * * Alice receives the response and computes g^y v^r mod p. After a bit * of algebra, this simplifies to g^k. If the hash of this result @@ -2147,8 +2128,8 @@ bighash( * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_ID bad or missing group key + * XEVNT_PUB bad or missing public key */ static int crypto_alice( @@ -2165,50 +2146,49 @@ crypto_alice( /* * The identity parameters must have correct format and content. */ - if (peer->ident_pkey == NULL) + if (peer->ident_pkey == NULL) { + msyslog(LOG_NOTICE, "crypto_alice: scheme unavailable"); return (XEVNT_ID); + } - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_alice: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_alice: defective key"); return (XEVNT_PUB); } /* - * Roll new random r (0 < r < q). The OpenSSL library has a bug - * omitting BN_rand_range, so we have to do it the hard way. + * Roll new random r (0 < r < q). */ - bctx = BN_CTX_new(); - len = BN_num_bytes(dsa->q); if (peer->iffval != NULL) BN_free(peer->iffval); peer->iffval = BN_new(); - BN_rand(peer->iffval, len * 8, -1, 1); /* r */ + len = BN_num_bytes(dsa->q); + BN_rand(peer->iffval, len * 8, -1, 1); /* r mod q*/ + bctx = BN_CTX_new(); BN_mod(peer->iffval, peer->iffval, dsa->q, bctx); BN_CTX_free(bctx); /* * Sign and send to Bob. The filestamp is from the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(peer->fstamp); + vp->fstamp = htonl(peer->ident_pkey->fstamp); vp->vallen = htonl(len); vp->ptr = emalloc(len); BN_bn2bin(peer->iffval, vp->ptr); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); vp->siglen = htonl(len); + } return (XEVNT_OK); } @@ -2218,9 +2198,8 @@ crypto_alice( * * Returns * XEVNT_OK success - * XEVNT_ID bad or missing group key * XEVNT_ERR protocol error - * XEVNT_PER host expired certificate + * XEVNT_ID bad or missing group key */ static int crypto_bob( @@ -2235,28 +2214,26 @@ crypto_bob( tstamp_t tstamp; /* NTP timestamp */ BIGNUM *bn, *bk, *r; u_char *ptr; - u_int len; /* extension field length */ - u_int vallen = 0; /* value length */ + u_int len; /* extension field value length */ /* * If the IFF parameters are not valid, something awful * happened or we are being tormented. */ - if (iffpar_pkey == NULL) { - msyslog(LOG_INFO, "crypto_bob: scheme unavailable"); + if (iffkey_info == NULL) { + msyslog(LOG_NOTICE, "crypto_bob: scheme unavailable"); return (XEVNT_ID); } - dsa = iffpar_pkey->pkey.dsa; + dsa = iffkey_info->pkey->pkey.dsa; /* * Extract r from the challenge. */ - vallen = ntohl(ep->vallen); - len = ntohl(ep->opcode) & 0x0000ffff; - if (vallen == 0 || len < VALUE_LEN || len - VALUE_LEN < vallen) - return XEVNT_LEN; - if ((r = BN_bin2bn((u_char *)ep->pkt, vallen, NULL)) == NULL) { - msyslog(LOG_ERR, "crypto_bob %s\n", + len = exten_payload_size(ep); + if (len == 0 || len > MAX_VALLEN) + return (XEVNT_LEN); + if ((r = BN_bin2bn((u_char *)ep->pkt, len, NULL)) == NULL) { + msyslog(LOG_ERR, "crypto_bob: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2267,7 +2244,7 @@ crypto_bob( */ bctx = BN_CTX_new(); bk = BN_new(); bn = BN_new(); sdsa = DSA_SIG_new(); - BN_rand(bk, vallen * 8, -1, 1); /* k */ + BN_rand(bk, len * 8, -1, 1); /* k */ BN_mod_mul(bn, dsa->priv_key, r, dsa->q, bctx); /* b r mod q */ BN_add(bn, bn, bk); BN_mod(bn, bn, dsa->q, bctx); /* k + b r mod q */ @@ -2277,46 +2254,49 @@ crypto_bob( sdsa->s = BN_dup(bk); BN_CTX_free(bctx); BN_free(r); BN_free(bn); BN_free(bk); +#ifdef DEBUG + if (debug > 1) + DSA_print_fp(stdout, dsa, 0); +#endif /* - * Encode the values in ASN.1 and sign. + * Encode the values in ASN.1 and sign. The filestamp is from + * the local file. */ - vallen = i2d_DSA_SIG(sdsa, NULL); - if (vallen == 0) { - msyslog(LOG_ERR, "crypto_bob %s\n", + len = i2d_DSA_SIG(sdsa, NULL); + if (len == 0) { + msyslog(LOG_ERR, "crypto_bob: %s", ERR_error_string(ERR_get_error(), NULL)); DSA_SIG_free(sdsa); return (XEVNT_ERR); } - if (vallen > MAX_VALLEN) { - msyslog(LOG_ERR, "crypto_bob: signature is too big: %d", - vallen); + if (len > MAX_VALLEN) { + msyslog(LOG_ERR, "crypto_bob: signature is too big: %u", + len); DSA_SIG_free(sdsa); return (XEVNT_LEN); } memset(vp, 0, sizeof(struct value)); tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(if_fstamp); - vp->vallen = htonl(vallen); - ptr = emalloc(vallen); + vp->fstamp = htonl(iffkey_info->fstamp); + vp->vallen = htonl(len); + ptr = emalloc(len); vp->ptr = ptr; i2d_DSA_SIG(sdsa, &ptr); DSA_SIG_free(sdsa); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - /* XXX: more validation to make sure the sign fits... */ vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); - EVP_SignUpdate(&ctx, vp->ptr, vallen); - if (EVP_SignFinal(&ctx, vp->sig, &vallen, sign_pkey)) + EVP_SignUpdate(&ctx, vp->ptr, len); + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); vp->siglen = htonl(len); + } return (XEVNT_OK); } @@ -2326,9 +2306,9 @@ crypto_bob( * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key - * XEVNT_ID bad or missing group key * XEVNT_FSP bad filestamp + * XEVNT_ID bad or missing group key + * XEVNT_PUB bad or missing public key */ int crypto_iff( @@ -2341,7 +2321,7 @@ crypto_iff( DSA_SIG *sdsa; /* DSA parameters */ BIGNUM *bn, *bk; u_int len; - const u_char *ptr; + const u_char *ptr; int temp; /* @@ -2349,20 +2329,20 @@ crypto_iff( * something awful happened or we are being tormented. */ if (peer->ident_pkey == NULL) { - msyslog(LOG_INFO, "crypto_iff: scheme unavailable"); + msyslog(LOG_NOTICE, "crypto_iff: scheme unavailable"); return (XEVNT_ID); } - if (ntohl(ep->fstamp) != peer->fstamp) { - msyslog(LOG_INFO, "crypto_iff: invalid filestamp %u", + if (ntohl(ep->fstamp) != peer->ident_pkey->fstamp) { + msyslog(LOG_NOTICE, "crypto_iff: invalid filestamp %u", ntohl(ep->fstamp)); return (XEVNT_FSP); } - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_iff: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_iff: defective key"); return (XEVNT_PUB); } if (peer->iffval == NULL) { - msyslog(LOG_INFO, "crypto_iff: missing challenge"); + msyslog(LOG_NOTICE, "crypto_iff: missing challenge"); return (XEVNT_ID); } @@ -2371,9 +2351,10 @@ crypto_iff( */ bctx = BN_CTX_new(); bk = BN_new(); bn = BN_new(); len = ntohl(ep->vallen); - ptr = (const u_char *)ep->pkt; + ptr = (u_char *)ep->pkt; if ((sdsa = d2i_DSA_SIG(NULL, &ptr, len)) == NULL) { - msyslog(LOG_ERR, "crypto_iff %s\n", + BN_free(bn); BN_free(bk); BN_CTX_free(bctx); + msyslog(LOG_ERR, "crypto_iff: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2397,8 +2378,8 @@ crypto_iff( if (temp == 0) return (XEVNT_OK); - else - return (XEVNT_ID); + msyslog(LOG_NOTICE, "crypto_iff: identity not verified"); + return (XEVNT_ID); } @@ -2411,20 +2392,25 @@ crypto_iff( *********************************************************************** * * The Guillou-Quisquater (GQ) identity scheme is intended for use when - * the ntp-genkeys program generates the certificates used in the - * protocol and the group key can be conveyed in a certificate extension - * field. The scheme is self contained and independent of new - * generations of host keys, sign keys and certificates. - * - * The GQ identity scheme is based on RSA cryptography and algorithms - * described in Stinson p. 300 (with errors). The GQ values hide in a - * RSA cuckoo structure, but only the modulus is used. The 512-bit - * public modulus is n = p q, where p and q are secret large primes. The - * TA rolls random group key b disguised as a RSA structure member. - * Except for the public key, these values are shared only among group - * members and never revealed in messages. - * - * When rolling new certificates, Bob recomputes the private and + * the certificate can be used to convey public parameters. The scheme + * uses a X509v3 certificate extension field do convey the public key of + * a private key known only to servers. There are two kinds of files: + * encrypted server files that contain private and public values and + * nonencrypted client files that contain only public values. New + * generations of server files must be securely transmitted to all + * servers of the group; client files can be distributed by any means. + * The scheme is self contained and independent of new generations of + * host keys and sign keys. The scheme is self contained and independent + * of new generations of host keys and sign keys. + * + * The GQ parameters hide in a RSA cuckoo structure which uses the same + * parameters. The values are used by an identity scheme based on RSA + * cryptography and described in Stimson p. 300 (with errors). The 512- + * bit public modulus is n = p q, where p and q are secret large primes. + * The TA rolls private random group key b as RSA exponent. These values + * are known to all group members. + * + * When rolling new certificates, a server recomputes the private and * public keys. The private key u is a random roll, while the public key * is the inverse obscured by the group key v = (u^-1)^b. These values * replace the private and public keys normally generated by the RSA @@ -2459,9 +2445,8 @@ crypto_iff( * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_ID bad or missing group key - * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key */ static int crypto_alice2( @@ -2481,47 +2466,44 @@ crypto_alice2( if (peer->ident_pkey == NULL) return (XEVNT_ID); - if ((rsa = peer->ident_pkey->pkey.rsa) == NULL) { - msyslog(LOG_INFO, "crypto_alice2: defective key"); + if ((rsa = peer->ident_pkey->pkey->pkey.rsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_alice2: defective key"); return (XEVNT_PUB); } /* - * Roll new random r (0 < r < n). The OpenSSL library has a bug - * omitting BN_rand_range, so we have to do it the hard way. + * Roll new random r (0 < r < n). */ - bctx = BN_CTX_new(); - len = BN_num_bytes(rsa->n); if (peer->iffval != NULL) BN_free(peer->iffval); peer->iffval = BN_new(); + len = BN_num_bytes(rsa->n); BN_rand(peer->iffval, len * 8, -1, 1); /* r mod n */ + bctx = BN_CTX_new(); BN_mod(peer->iffval, peer->iffval, rsa->n, bctx); BN_CTX_free(bctx); /* * Sign and send to Bob. The filestamp is from the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(peer->fstamp); + vp->fstamp = htonl(peer->ident_pkey->fstamp); vp->vallen = htonl(len); vp->ptr = emalloc(len); BN_bn2bin(peer->iffval, vp->ptr); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); vp->siglen = htonl(len); + } return (XEVNT_OK); } @@ -2531,9 +2513,8 @@ crypto_alice2( * * Returns * XEVNT_OK success - * XEVNT_ID bad or missing group key * XEVNT_ERR protocol error - * XEVNT_PER host certificate expired + * XEVNT_ID bad or missing group key */ static int crypto_bob2( @@ -2549,23 +2530,26 @@ crypto_bob2( BIGNUM *r, *k, *g, *y; u_char *ptr; u_int len; + int s_len; /* * If the GQ parameters are not valid, something awful * happened or we are being tormented. */ - if (gqpar_pkey == NULL) { - msyslog(LOG_INFO, "crypto_bob2: scheme unavailable"); + if (gqkey_info == NULL) { + msyslog(LOG_NOTICE, "crypto_bob2: scheme unavailable"); return (XEVNT_ID); } - rsa = gqpar_pkey->pkey.rsa; + rsa = gqkey_info->pkey->pkey.rsa; /* * Extract r from the challenge. */ - len = ntohl(ep->vallen); + len = exten_payload_size(ep); + if (len == 0 || len > MAX_VALLEN) + return (XEVNT_LEN); if ((r = BN_bin2bn((u_char *)ep->pkt, len, NULL)) == NULL) { - msyslog(LOG_ERR, "crypto_bob2 %s\n", + msyslog(LOG_ERR, "crypto_bob2: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2586,39 +2570,42 @@ crypto_bob2( sdsa->s = BN_dup(g); BN_CTX_free(bctx); BN_free(r); BN_free(k); BN_free(g); BN_free(y); +#ifdef DEBUG + if (debug > 1) + RSA_print_fp(stdout, rsa, 0); +#endif /* - * Encode the values in ASN.1 and sign. + * Encode the values in ASN.1 and sign. The filestamp is from + * the local file. */ - tstamp = crypto_time(); - memset(vp, 0, sizeof(struct value)); - vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(gq_fstamp); - len = i2d_DSA_SIG(sdsa, NULL); - if (len <= 0) { - msyslog(LOG_ERR, "crypto_bob2 %s\n", + len = s_len = i2d_DSA_SIG(sdsa, NULL); + if (s_len <= 0) { + msyslog(LOG_ERR, "crypto_bob2: %s", ERR_error_string(ERR_get_error(), NULL)); DSA_SIG_free(sdsa); return (XEVNT_ERR); } + memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); + vp->tstamp = htonl(tstamp); + vp->fstamp = htonl(gqkey_info->fstamp); vp->vallen = htonl(len); ptr = emalloc(len); vp->ptr = ptr; i2d_DSA_SIG(sdsa, &ptr); DSA_SIG_free(sdsa); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); vp->siglen = htonl(len); + } return (XEVNT_OK); } @@ -2628,10 +2615,10 @@ crypto_bob2( * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key - * XEVNT_ID bad or missing group keys * XEVNT_ERR protocol error * XEVNT_FSP bad filestamp + * XEVNT_ID bad or missing group keys + * XEVNT_PUB bad or missing public key */ int crypto_gq( @@ -2643,29 +2630,31 @@ crypto_gq( BN_CTX *bctx; /* BIGNUM context */ DSA_SIG *sdsa; /* RSA signature context fake */ BIGNUM *y, *v; - const u_char *ptr; - u_int len; - int temp; + const u_char *ptr; + long len; + u_int temp; /* * If the GQ parameters are not valid or no challenge was sent, - * something awful happened or we are being tormented. + * something awful happened or we are being tormented. Note that + * the filestamp on the local key file can be greater than on + * the remote parameter file if the keys have been refreshed. */ if (peer->ident_pkey == NULL) { - msyslog(LOG_INFO, "crypto_gq: scheme unavailable"); + msyslog(LOG_NOTICE, "crypto_gq: scheme unavailable"); return (XEVNT_ID); } - if (ntohl(ep->fstamp) != peer->fstamp) { - msyslog(LOG_INFO, "crypto_gq: invalid filestamp %u", + if (ntohl(ep->fstamp) < peer->ident_pkey->fstamp) { + msyslog(LOG_NOTICE, "crypto_gq: invalid filestamp %u", ntohl(ep->fstamp)); return (XEVNT_FSP); } - if ((rsa = peer->ident_pkey->pkey.rsa) == NULL) { - msyslog(LOG_INFO, "crypto_gq: defective key"); + if ((rsa = peer->ident_pkey->pkey->pkey.rsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_gq: defective key"); return (XEVNT_PUB); } if (peer->iffval == NULL) { - msyslog(LOG_INFO, "crypto_gq: missing challenge"); + msyslog(LOG_NOTICE, "crypto_gq: missing challenge"); return (XEVNT_ID); } @@ -2675,9 +2664,10 @@ crypto_gq( */ bctx = BN_CTX_new(); y = BN_new(); v = BN_new(); len = ntohl(ep->vallen); - ptr = (const u_char *)ep->pkt; + ptr = (u_char *)ep->pkt; if ((sdsa = d2i_DSA_SIG(NULL, &ptr, len)) == NULL) { - msyslog(LOG_ERR, "crypto_gq %s\n", + BN_CTX_free(bctx); BN_free(y); BN_free(v); + msyslog(LOG_ERR, "crypto_gq: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } @@ -2685,6 +2675,10 @@ crypto_gq( /* * Compute v^r y^b mod n. */ + if (peer->grpkey == NULL) { + msyslog(LOG_NOTICE, "crypto_gq: missing group key"); + return (XEVNT_ID); + } BN_mod_exp(v, peer->grpkey, peer->iffval, rsa->n, bctx); /* v^r mod n */ BN_mod_exp(y, sdsa->r, rsa->e, rsa->n, bctx); /* y^b mod n */ @@ -2702,8 +2696,8 @@ crypto_gq( if (temp == 0) return (XEVNT_OK); - else - return (XEVNT_ID); + msyslog(LOG_NOTICE, "crypto_gq: identity not verified"); + return (XEVNT_ID); } @@ -2714,8 +2708,7 @@ crypto_gq( * scheme * * * *********************************************************************** - */ -/* + * * The Mu-Varadharajan (MV) cryptosystem was originally intended when * servers broadcast messages to clients, but clients never send * messages to servers. There is one encryption key for the server and a @@ -2732,19 +2725,16 @@ crypto_gq( * Varadharajan: Robust and Secure Broadcasting, Proc. Indocrypt 2001, * 223-231. The paper has significant errors and serious omissions. * - * Let q be the product of n distinct primes s'[j] (j = 1...n), where - * each s'[j] has m significant bits. Let p be a prime p = 2 * q + 1, so - * that q and each s'[j] divide p - 1 and p has M = n * m + 1 - * significant bits. The elements x mod q of Zq with the elements 2 and - * the primes removed form a field Zq* valid for polynomial arithetic. - * Let g be a generator of Zp; that is, gcd(g, p - 1) = 1 and g^q = 1 - * mod p. We expect M to be in the 500-bit range and n relatively small, - * like 25, so the likelihood of a randomly generated element of x mod q - * of Zq colliding with a factor of p - 1 is very small and can be - * avoided. Associated with each s'[j] is an element s[j] such that s[j] - * s'[j] = s'[j] mod q. We find s[j] as the quotient (q + s'[j]) / - * s'[j]. These are the parameters of the scheme and they are expensive - * to compute. + * Let q be the product of n distinct primes s1[j] (j = 1...n), where + * each s1[j] has m significant bits. Let p be a prime p = 2 * q + 1, so + * that q and each s1[j] divide p - 1 and p has M = n * m + 1 + * significant bits. Let g be a generator of Zp; that is, gcd(g, p - 1) + * = 1 and g^q = 1 mod p. We do modular arithmetic over Zq and then + * project into Zp* as exponents of g. Sometimes we have to compute an + * inverse b^-1 of random b in Zq, but for that purpose we require + * gcd(b, q) = 1. We expect M to be in the 500-bit range and n + * relatively small, like 30. These are the parameters of the scheme and + * they are expensive to compute. * * We set up an instance of the scheme as follows. A set of random * values x[j] mod q (j = 1...n), are generated as the zeros of a @@ -2755,39 +2745,41 @@ crypto_gq( * pairs (xbar[j], xhat[j]) (j = 1...n) of private client keys are used * to construct the decryption keys. The devil is in the details. * + * This routine generates a private server encryption file including the + * private encryption key E and partial decryption keys gbar and ghat. + * It then generates public client decryption files including the public + * keys xbar[j] and xhat[j] for each client j. The partial decryption + * files are used to compute the inverse of E. These values are suitably + * blinded so secrets are not revealed. + * * The distinguishing characteristic of this scheme is the capability to * revoke keys. Included in the calculation of E, gbar and ghat is the - * product s = prod(s'[j]) (j = 1...n) above. If the factor s'[j] is + * product s = prod(s1[j]) (j = 1...n) above. If the factor s1[j] is * subsequently removed from the product and E, gbar and ghat * recomputed, the jth client will no longer be able to compute E^-1 and - * thus unable to decrypt the block. + * thus unable to decrypt the messageblock. * * How it works * - * The scheme goes like this. Bob has the server values (p, A, q, gbar, - * ghat) and Alice the client values (p, xbar, xhat). + * The scheme goes like this. Bob has the server values (p, E, q, gbar, + * ghat) and Alice has the client values (p, xbar, xhat). * - * Alice rolls new random challenge r (0 < r < p) and sends to Bob in - * the MV request message. Bob rolls new random k (0 < k < q), encrypts - * y = A^k mod p (a permutation) and sends (hash(y), gbar^k, ghat^k) to - * Alice. + * Alice rolls new random nonce r mod p and sends to Bob in the MV + * request message. Bob rolls random nonce k mod q, encrypts y = r E^k + * mod p and sends (y, gbar^k, ghat^k) to Alice. * - * Alice receives the response and computes the decryption key (the - * inverse permutation) from previously obtained (xbar, xhat) and - * (gbar^k, ghat^k) in the message. She computes the inverse, which is - * unique by reasons explained in the ntp-keygen.c program sources. If - * the hash of this result matches hash(y), Alice knows that Bob has the - * group key b. The signed response binds this knowledge to Bob's - * private key and the public key previously received in his - * certificate. + * Alice receives the response and computes the inverse (E^k)^-1 from + * the partial decryption keys gbar^k, ghat^k, xbar and xhat. She then + * decrypts y and verifies it matches the original r. The signed + * response binds this knowledge to Bob's private key and the public key + * previously received in his certificate. * * crypto_alice3 - construct Alice's challenge in MV scheme * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_ID bad or missing group key - * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key */ static int crypto_alice3( @@ -2807,47 +2799,44 @@ crypto_alice3( if (peer->ident_pkey == NULL) return (XEVNT_ID); - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_alice3: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_alice3: defective key"); return (XEVNT_PUB); } /* - * Roll new random r (0 < r < q). The OpenSSL library has a bug - * omitting BN_rand_range, so we have to do it the hard way. + * Roll new random r (0 < r < q). */ - bctx = BN_CTX_new(); - len = BN_num_bytes(dsa->p); if (peer->iffval != NULL) BN_free(peer->iffval); peer->iffval = BN_new(); - BN_rand(peer->iffval, len * 8, -1, 1); /* r */ + len = BN_num_bytes(dsa->p); + BN_rand(peer->iffval, len * 8, -1, 1); /* r mod p */ + bctx = BN_CTX_new(); BN_mod(peer->iffval, peer->iffval, dsa->p, bctx); BN_CTX_free(bctx); /* * Sign and send to Bob. The filestamp is from the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(peer->fstamp); + vp->fstamp = htonl(peer->ident_pkey->fstamp); vp->vallen = htonl(len); vp->ptr = emalloc(len); BN_bn2bin(peer->iffval, vp->ptr); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); vp->siglen = htonl(len); + } return (XEVNT_OK); } @@ -2858,7 +2847,6 @@ crypto_alice3( * Returns * XEVNT_OK success * XEVNT_ERR protocol error - * XEVNT_PER host certificate expired */ static int crypto_bob3( @@ -2879,26 +2867,28 @@ crypto_bob3( * If the MV parameters are not valid, something awful * happened or we are being tormented. */ - if (mvpar_pkey == NULL) { - msyslog(LOG_INFO, "crypto_bob3: scheme unavailable"); + if (mvkey_info == NULL) { + msyslog(LOG_NOTICE, "crypto_bob3: scheme unavailable"); return (XEVNT_ID); } - dsa = mvpar_pkey->pkey.dsa; + dsa = mvkey_info->pkey->pkey.dsa; /* * Extract r from the challenge. */ - len = ntohl(ep->vallen); + len = exten_payload_size(ep); + if (len == 0 || len > MAX_VALLEN) + return (XEVNT_LEN); if ((r = BN_bin2bn((u_char *)ep->pkt, len, NULL)) == NULL) { - msyslog(LOG_ERR, "crypto_bob3 %s\n", + msyslog(LOG_ERR, "crypto_bob3: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } /* * Bob rolls random k (0 < k < q), making sure it is not a - * factor of q. He then computes y = A^k r and sends (hash(y), - * gbar^k, ghat^k) to Alice. + * factor of q. He then computes y = r A^k and sends (y, gbar^k, + * and ghat^k) to Alice. */ bctx = BN_CTX_new(); k = BN_new(); u = BN_new(); sdsa = DSA_new(); @@ -2910,23 +2900,27 @@ crypto_bob3( if (BN_is_one(u)) break; } - BN_mod_exp(u, dsa->g, k, dsa->p, bctx); /* A r */ - BN_mod_mul(u, u, r, dsa->p, bctx); - bighash(u, sdsa->p); + BN_mod_exp(u, dsa->g, k, dsa->p, bctx); /* A^k r */ + BN_mod_mul(sdsa->p, u, r, dsa->p, bctx); BN_mod_exp(sdsa->q, dsa->priv_key, k, dsa->p, bctx); /* gbar */ BN_mod_exp(sdsa->g, dsa->pub_key, k, dsa->p, bctx); /* ghat */ BN_CTX_free(bctx); BN_free(k); BN_free(r); BN_free(u); +#ifdef DEBUG + if (debug > 1) + DSA_print_fp(stdout, sdsa, 0); +#endif /* - * Encode the values in ASN.1 and sign. + * Encode the values in ASN.1 and sign. The filestamp is from + * the local file. */ - tstamp = crypto_time(); memset(vp, 0, sizeof(struct value)); + tstamp = crypto_time(); vp->tstamp = htonl(tstamp); - vp->fstamp = htonl(mv_fstamp); + vp->fstamp = htonl(mvkey_info->fstamp); len = i2d_DSAparams(sdsa, NULL); - if (len <= 0) { - msyslog(LOG_ERR, "crypto_bob3 %s\n", + if (len == 0) { + msyslog(LOG_ERR, "crypto_bob3: %s", ERR_error_string(ERR_get_error(), NULL)); DSA_free(sdsa); return (XEVNT_ERR); @@ -2936,19 +2930,17 @@ crypto_bob3( vp->ptr = ptr; i2d_DSAparams(sdsa, &ptr); DSA_free(sdsa); - vp->siglen = 0; if (tstamp == 0) return (XEVNT_OK); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - vp->sig = emalloc(sign_siglen); EVP_SignInit(&ctx, sign_digest); EVP_SignUpdate(&ctx, (u_char *)&vp->tstamp, 12); EVP_SignUpdate(&ctx, vp->ptr, len); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); vp->siglen = htonl(len); + } return (XEVNT_OK); } @@ -2958,10 +2950,10 @@ crypto_bob3( * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key - * XEVNT_ID bad or missing group key * XEVNT_ERR protocol error * XEVNT_FSP bad filestamp + * XEVNT_ID bad or missing group key + * XEVNT_PUB bad or missing public key */ int crypto_mv( @@ -2974,7 +2966,7 @@ crypto_mv( BN_CTX *bctx; /* BIGNUM context */ BIGNUM *k, *u, *v; u_int len; - const u_char *ptr; + const u_char *ptr; int temp; /* @@ -2982,49 +2974,47 @@ crypto_mv( * something awful happened or we are being tormented. */ if (peer->ident_pkey == NULL) { - msyslog(LOG_INFO, "crypto_mv: scheme unavailable"); + msyslog(LOG_NOTICE, "crypto_mv: scheme unavailable"); return (XEVNT_ID); } - if (ntohl(ep->fstamp) != peer->fstamp) { - msyslog(LOG_INFO, "crypto_mv: invalid filestamp %u", + if (ntohl(ep->fstamp) != peer->ident_pkey->fstamp) { + msyslog(LOG_NOTICE, "crypto_mv: invalid filestamp %u", ntohl(ep->fstamp)); return (XEVNT_FSP); } - if ((dsa = peer->ident_pkey->pkey.dsa) == NULL) { - msyslog(LOG_INFO, "crypto_mv: defective key"); + if ((dsa = peer->ident_pkey->pkey->pkey.dsa) == NULL) { + msyslog(LOG_NOTICE, "crypto_mv: defective key"); return (XEVNT_PUB); } if (peer->iffval == NULL) { - msyslog(LOG_INFO, "crypto_mv: missing challenge"); + msyslog(LOG_NOTICE, "crypto_mv: missing challenge"); return (XEVNT_ID); } /* - * Extract the (hash(y), gbar, ghat) values from the response. + * Extract the y, gbar and ghat values from the response. */ bctx = BN_CTX_new(); k = BN_new(); u = BN_new(); v = BN_new(); len = ntohl(ep->vallen); - ptr = (const u_char *)ep->pkt; + ptr = (u_char *)ep->pkt; if ((sdsa = d2i_DSAparams(NULL, &ptr, len)) == NULL) { - msyslog(LOG_ERR, "crypto_mv %s\n", + msyslog(LOG_ERR, "crypto_mv: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_ERR); } /* - * Compute (gbar^xhat ghat^xbar)^-1 mod p. + * Compute (gbar^xhat ghat^xbar) mod p. */ BN_mod_exp(u, sdsa->q, dsa->pub_key, dsa->p, bctx); BN_mod_exp(v, sdsa->g, dsa->priv_key, dsa->p, bctx); BN_mod_mul(u, u, v, dsa->p, bctx); - BN_mod_inverse(u, u, dsa->p, bctx); - BN_mod_mul(v, u, peer->iffval, dsa->p, bctx); + BN_mod_mul(u, u, sdsa->p, dsa->p, bctx); /* - * The result should match the hash of r mod p. + * The result should match r. */ - bighash(v, v); - temp = BN_cmp(v, sdsa->p); + temp = BN_cmp(u, peer->iffval); BN_CTX_free(bctx); BN_free(k); BN_free(u); BN_free(v); BN_free(peer->iffval); peer->iffval = NULL; @@ -3032,8 +3022,8 @@ crypto_mv( if (temp == 0) return (XEVNT_OK); - else - return (XEVNT_ID); + msyslog(LOG_NOTICE, "crypto_mv: identity not verified"); + return (XEVNT_ID); } @@ -3045,188 +3035,7 @@ crypto_mv( *********************************************************************** */ /* - * cert_parse - parse x509 certificate and create info/value structures. - * - * The server certificate includes the version number, issuer name, - * subject name, public key and valid date interval. If the issuer name - * is the same as the subject name, the certificate is self signed and - * valid only if the server is configured as trustable. If the names are - * different, another issuer has signed the server certificate and - * vouched for it. In this case the server certificate is valid if - * verified by the issuer public key. - * - * Returns certificate info/value pointer if valid, NULL if not. - */ -struct cert_info * /* certificate information structure */ -cert_parse( - u_char *asn1cert, /* X509 certificate */ - u_int len, /* certificate length */ - tstamp_t fstamp /* filestamp */ - ) -{ - X509 *cert; /* X509 certificate */ - X509_EXTENSION *ext; /* X509v3 extension */ - struct cert_info *ret; /* certificate info/value */ - BIO *bp; - X509V3_EXT_METHOD *method; - char pathbuf[MAXFILENAME]; - u_char *uptr; - char *ptr; - int temp, cnt, i; - - /* - * Decode ASN.1 objects and construct certificate structure. - */ - uptr = asn1cert; - if ((cert = d2i_X509(NULL, &uptr, len)) == NULL) { - msyslog(LOG_ERR, "cert_parse %s\n", - ERR_error_string(ERR_get_error(), NULL)); - return (NULL); - } - - /* - * Extract version, subject name and public key. - */ - ret = emalloc(sizeof(struct cert_info)); - memset(ret, 0, sizeof(struct cert_info)); - if ((ret->pkey = X509_get_pubkey(cert)) == NULL) { - msyslog(LOG_ERR, "cert_parse %s\n", - ERR_error_string(ERR_get_error(), NULL)); - cert_free(ret); - X509_free(cert); - return (NULL); - } - ret->version = X509_get_version(cert); - X509_NAME_oneline(X509_get_subject_name(cert), pathbuf, - MAXFILENAME - 1); - ptr = strstr(pathbuf, "CN="); - if (ptr == NULL) { - msyslog(LOG_INFO, "cert_parse: invalid subject %s", - pathbuf); - cert_free(ret); - X509_free(cert); - return (NULL); - } - ret->subject = emalloc(strlen(ptr) + 1); - strcpy(ret->subject, ptr + 3); - - /* - * Extract remaining objects. Note that the NTP serial number is - * the NTP seconds at the time of signing, but this might not be - * the case for other authority. We don't bother to check the - * objects at this time, since the real crunch can happen only - * when the time is valid but not yet certificated. - */ - ret->nid = OBJ_obj2nid(cert->cert_info->signature->algorithm); - ret->digest = (const EVP_MD *)EVP_get_digestbynid(ret->nid); - ret->serial = - (u_long)ASN1_INTEGER_get(X509_get_serialNumber(cert)); - X509_NAME_oneline(X509_get_issuer_name(cert), pathbuf, - MAXFILENAME); - if ((ptr = strstr(pathbuf, "CN=")) == NULL) { - msyslog(LOG_INFO, "cert_parse: invalid issuer %s", - pathbuf); - cert_free(ret); - X509_free(cert); - return (NULL); - } - ret->issuer = emalloc(strlen(ptr) + 1); - strcpy(ret->issuer, ptr + 3); - ret->first = asn2ntp(X509_get_notBefore(cert)); - ret->last = asn2ntp(X509_get_notAfter(cert)); - - /* - * Extract extension fields. These are ad hoc ripoffs of - * currently assigned functions and will certainly be changed - * before prime time. - */ - cnt = X509_get_ext_count(cert); - for (i = 0; i < cnt; i++) { - ext = X509_get_ext(cert, i); - method = X509V3_EXT_get(ext); - temp = OBJ_obj2nid(ext->object); - switch (temp) { - - /* - * If a key_usage field is present, we decode whether - * this is a trusted or private certificate. This is - * dorky; all we want is to compare NIDs, but OpenSSL - * insists on BIO text strings. - */ - case NID_ext_key_usage: - bp = BIO_new(BIO_s_mem()); - X509V3_EXT_print(bp, ext, 0, 0); - BIO_gets(bp, pathbuf, MAXFILENAME); - BIO_free(bp); -#if DEBUG - if (debug) - printf("cert_parse: %s: %s\n", - OBJ_nid2ln(temp), pathbuf); -#endif - if (strcmp(pathbuf, "Trust Root") == 0) - ret->flags |= CERT_TRUST; - else if (strcmp(pathbuf, "Private") == 0) - ret->flags |= CERT_PRIV; - break; - - /* - * If a NID_subject_key_identifier field is present, it - * contains the GQ public key. - */ - case NID_subject_key_identifier: - ret->grplen = ext->value->length - 2; - ret->grpkey = emalloc(ret->grplen); - memcpy(ret->grpkey, &ext->value->data[2], - ret->grplen); - break; - } - } - - /* - * If certificate is self signed, verify signature. - */ - if (strcmp(ret->subject, ret->issuer) == 0) { - if (!X509_verify(cert, ret->pkey)) { - msyslog(LOG_INFO, - "cert_parse: signature not verified %s", - pathbuf); - cert_free(ret); - X509_free(cert); - return (NULL); - } - } - - /* - * Verify certificate valid times. Note that certificates cannot - * be retroactive. - */ - if (ret->first > ret->last || ret->first < fstamp) { - msyslog(LOG_INFO, - "cert_parse: invalid certificate %s first %u last %u fstamp %u", - ret->subject, ret->first, ret->last, fstamp); - cert_free(ret); - X509_free(cert); - return (NULL); - } - - /* - * Build the value structure to sign and send later. - */ - ret->cert.fstamp = htonl(fstamp); - ret->cert.vallen = htonl(len); - ret->cert.ptr = emalloc(len); - memcpy(ret->cert.ptr, asn1cert, len); -#ifdef DEBUG - if (debug > 1) - X509_print_fp(stdout, cert); -#endif - X509_free(cert); - return (ret); -} - - -/* - * cert_sign - sign x509 certificate equest and update value structure. + * cert_sign - sign x509 certificate equest and update value structure. * * The certificate request includes a copy of the host certificate, * which includes the version number, subject name and public key of the @@ -3254,10 +3063,10 @@ cert_parse( * * Returns * XEVNT_OK success - * XEVNT_PUB bad or missing public key * XEVNT_CRT bad or missing certificate - * XEVNT_VFY certificate not verified * XEVNT_PER host certificate expired + * XEVNT_PUB bad or missing public key + * XEVNT_VFY certificate not verified */ static int cert_sign( @@ -3273,8 +3082,10 @@ cert_sign( EVP_PKEY *pkey; /* public key */ EVP_MD_CTX ctx; /* message digest context */ tstamp_t tstamp; /* NTP timestamp */ + struct calendar tscal; u_int len; - u_char *ptr; + const u_char *cptr; + u_char *ptr; int i, temp; /* @@ -3286,12 +3097,12 @@ cert_sign( if (tstamp == 0) return (XEVNT_TSP); - if (tstamp < cinfo->first || tstamp > cinfo->last) - return (XEVNT_PER); - - ptr = (u_char *)ep->pkt; - if ((req = d2i_X509(NULL, &ptr, ntohl(ep->vallen))) == NULL) { - msyslog(LOG_ERR, "cert_sign %s\n", + len = exten_payload_size(ep); + if (len == 0 || len > MAX_VALLEN) + return (XEVNT_LEN); + cptr = (void *)ep->pkt; + if ((req = d2i_X509(NULL, &cptr, len)) == NULL) { + msyslog(LOG_ERR, "cert_sign: %s", ERR_error_string(ERR_get_error(), NULL)); return (XEVNT_CRT); } @@ -3299,16 +3110,17 @@ cert_sign( * Extract public key and check for errors. */ if ((pkey = X509_get_pubkey(req)) == NULL) { - msyslog(LOG_ERR, "cert_sign %s\n", + msyslog(LOG_ERR, "cert_sign: %s", ERR_error_string(ERR_get_error(), NULL)); X509_free(req); return (XEVNT_PUB); } /* - * Generate X509 certificate signed by this server. For this - * purpose the issuer name is the server name. Also copy any - * extensions that might be present. + * Generate X509 certificate signed by this server. If this is a + * trusted host, the issuer name is the group name; otherwise, + * it is the host name. Also copy any extensions that might be + * present. */ cert = X509_new(); X509_set_version(cert, X509_get_version(req)); @@ -3319,24 +3131,30 @@ cert_sign( X509_gmtime_adj(X509_get_notAfter(cert), YEAR); subj = X509_get_issuer_name(cert); X509_NAME_add_entry_by_txt(subj, "commonName", MBSTRING_ASC, - (u_char *)sys_hostname, strlen(sys_hostname), -1, 0); + hostval.ptr, strlen((const char *)hostval.ptr), -1, 0); subj = X509_get_subject_name(req); X509_set_subject_name(cert, subj); X509_set_pubkey(cert, pkey); - ext = X509_get_ext(req, 0); temp = X509_get_ext_count(req); for (i = 0; i < temp; i++) { ext = X509_get_ext(req, i); - X509_add_ext(cert, ext, -1); + INSIST(X509_add_ext(cert, ext, -1)); } X509_free(req); /* - * Sign and verify the certificate. + * Sign and verify the client certificate, but only if the host + * certificate has not expired. */ + (void)ntpcal_ntp_to_date(&tscal, tstamp, NULL); + if ((calcomp(&tscal, &(cert_host->first)) < 0) + || (calcomp(&tscal, &(cert_host->last)) > 0)) { + X509_free(cert); + return (XEVNT_PER); + } X509_sign(cert, sign_pkey, sign_digest); - if (!X509_verify(cert, sign_pkey)) { - printf("cert_sign\n%s\n", + if (X509_verify(cert, sign_pkey) <= 0) { + msyslog(LOG_ERR, "cert_sign: %s", ERR_error_string(ERR_get_error(), NULL)); X509_free(cert); return (XEVNT_VFY); @@ -3354,14 +3172,18 @@ cert_sign( vp->vallen = htonl(len); vp->ptr = emalloc(len); ptr = vp->ptr; - i2d_X509(cert, &ptr); + i2d_X509(cert, (unsigned char **)(intptr_t)&ptr); vp->siglen = 0; - vp->sig = emalloc(sign_siglen); - EVP_SignInit(&ctx, sign_digest); - EVP_SignUpdate(&ctx, (u_char *)vp, 12); - EVP_SignUpdate(&ctx, vp->ptr, len); - if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) - vp->siglen = htonl(len); + if (tstamp != 0) { + vp->sig = emalloc(sign_siglen); + EVP_SignInit(&ctx, sign_digest); + EVP_SignUpdate(&ctx, (u_char *)vp, 12); + EVP_SignUpdate(&ctx, vp->ptr, len); + if (EVP_SignFinal(&ctx, vp->sig, &len, sign_pkey)) { + INSIST(len <= sign_siglen); + vp->siglen = htonl(len); + } + } #ifdef DEBUG if (debug > 1) X509_print_fp(stdout, cert); @@ -3372,74 +3194,38 @@ cert_sign( /* - * cert_valid - verify certificate with given public key - * - * This is pretty ugly, as the certificate has to be verified in the - * OpenSSL X509 structure, not in the DER format in the info/value - * structure. - * - * Returns - * XEVNT_OK success - * XEVNT_VFY certificate not verified - */ -int -cert_valid( - struct cert_info *cinf, /* certificate information structure */ - EVP_PKEY *pkey /* public key */ - ) -{ - X509 *cert; /* X509 certificate */ - u_char *ptr; - - if (cinf->flags & CERT_SIGN) - return (XEVNT_OK); - - ptr = (u_char *)cinf->cert.ptr; - cert = d2i_X509(NULL, &ptr, ntohl(cinf->cert.vallen)); - if (cert == NULL || !X509_verify(cert, pkey)) - return (XEVNT_VFY); - - X509_free(cert); - return (XEVNT_OK); -} - - -/* - * cert - install certificate in certificate list + * cert_install - install certificate in certificate cache * * This routine encodes an extension field into a certificate info/value * structure. It searches the certificate list for duplicates and - * expunges whichever is older. It then searches the list for other - * certificates that might be verified by this latest one. Finally, it - * inserts this certificate first on the list. + * expunges whichever is older. Finally, it inserts this certificate + * first on the list. * - * Returns - * XEVNT_OK success - * XEVNT_FSP bad or missing filestamp - * XEVNT_CRT bad or missing certificate + * Returns certificate info pointer if valid, NULL if not. */ -int +struct cert_info * cert_install( struct exten *ep, /* cert info/value */ struct peer *peer /* peer structure */ ) { - struct cert_info *cp, *xp, *yp, **zp; + struct cert_info *cp, *xp, **zp; /* * Parse and validate the signed certificate. If valid, - * construct the info/value structure; otherwise, scamper home. + * construct the info/value structure; otherwise, scamper home + * empty handed. */ - if ((cp = cert_parse((u_char *)ep->pkt, ntohl(ep->vallen), - ntohl(ep->fstamp))) == NULL) - return (XEVNT_CRT); + if ((cp = cert_parse((u_char *)ep->pkt, (long)ntohl(ep->vallen), + (tstamp_t)ntohl(ep->fstamp))) == NULL) + return (NULL); /* * Scan certificate list looking for another certificate with * the same subject and issuer. If another is found with the * same or older filestamp, unlink it and return the goodies to * the heap. If another is found with a later filestamp, discard - * the new one and leave the building. + * the new one and leave the building with the old one. * * Make a note to study this issue again. An earlier certificate * with a long lifetime might be overtaken by a later @@ -3447,112 +3233,314 @@ cert_install( * earlier signature. However, we gotta find a way to leak old * stuff from the cache, so we do it anyway. */ - yp = cp; zp = &cinfo; for (xp = cinfo; xp != NULL; xp = xp->link) { if (strcmp(cp->subject, xp->subject) == 0 && strcmp(cp->issuer, xp->issuer) == 0) { if (ntohl(cp->cert.fstamp) <= ntohl(xp->cert.fstamp)) { - *zp = xp->link;; - cert_free(xp); - } else { cert_free(cp); - return (XEVNT_FSP); + cp = xp; + } else { + *zp = xp->link; + cert_free(xp); + xp = NULL; } break; } - zp = &xp->link; + zp = &xp->link; + } + if (xp == NULL) { + cp->link = cinfo; + cinfo = cp; + } + cp->flags |= CERT_VALID; + crypto_update(); + return (cp); +} + + +/* + * cert_hike - verify the signature using the issuer public key + * + * Returns + * XEVNT_OK success + * XEVNT_CRT bad or missing certificate + * XEVNT_PER host certificate expired + * XEVNT_VFY certificate not verified + */ +int +cert_hike( + struct peer *peer, /* peer structure pointer */ + struct cert_info *yp /* issuer certificate */ + ) +{ + struct cert_info *xp; /* subject certificate */ + X509 *cert; /* X509 certificate */ + const u_char *ptr; + + /* + * Save the issuer on the new certificate, but remember the old + * one. + */ + if (peer->issuer != NULL) + free(peer->issuer); + peer->issuer = estrdup(yp->issuer); + xp = peer->xinfo; + peer->xinfo = yp; + + /* + * If subject Y matches issuer Y, then the certificate trail is + * complete. If Y is not trusted, the server certificate has yet + * been signed, so keep trying. Otherwise, save the group key + * and light the valid bit. If the host certificate is trusted, + * do not execute a sign exchange. If no identity scheme is in + * use, light the identity and proventic bits. + */ + if (strcmp(yp->subject, yp->issuer) == 0) { + if (!(yp->flags & CERT_TRUST)) + return (XEVNT_OK); + + /* + * If the server has an an identity scheme, fetch the + * identity credentials. If not, the identity is + * verified only by the trusted certificate. The next + * signature will set the server proventic. + */ + peer->crypto |= CRYPTO_FLAG_CERT; + peer->grpkey = yp->grpkey; + if (peer->ident == NULL || !(peer->crypto & + CRYPTO_FLAG_MASK)) + peer->crypto |= CRYPTO_FLAG_VRFY; + } + + /* + * If X exists, verify signature X using public key Y. + */ + if (xp == NULL) + return (XEVNT_OK); + + ptr = (u_char *)xp->cert.ptr; + cert = d2i_X509(NULL, &ptr, ntohl(xp->cert.vallen)); + if (cert == NULL) { + xp->flags |= CERT_ERROR; + return (XEVNT_CRT); + } + if (X509_verify(cert, yp->pkey) <= 0) { + X509_free(cert); + xp->flags |= CERT_ERROR; + return (XEVNT_VFY); + } + X509_free(cert); + + /* + * Signature X is valid only if it begins during the + * lifetime of Y. + */ + if ((calcomp(&(xp->first), &(yp->first)) < 0) + || (calcomp(&(xp->first), &(yp->last)) > 0)) { + xp->flags |= CERT_ERROR; + return (XEVNT_PER); + } + xp->flags |= CERT_SIGN; + return (XEVNT_OK); +} + + +/* + * cert_parse - parse x509 certificate and create info/value structures. + * + * The server certificate includes the version number, issuer name, + * subject name, public key and valid date interval. If the issuer name + * is the same as the subject name, the certificate is self signed and + * valid only if the server is configured as trustable. If the names are + * different, another issuer has signed the server certificate and + * vouched for it. In this case the server certificate is valid if + * verified by the issuer public key. + * + * Returns certificate info/value pointer if valid, NULL if not. + */ +struct cert_info * /* certificate information structure */ +cert_parse( + const u_char *asn1cert, /* X509 certificate */ + long len, /* certificate length */ + tstamp_t fstamp /* filestamp */ + ) +{ + X509 *cert; /* X509 certificate */ + X509_EXTENSION *ext; /* X509v3 extension */ + struct cert_info *ret; /* certificate info/value */ + BIO *bp; + char pathbuf[MAXFILENAME]; + const u_char *ptr; + char *pch; + int temp, cnt, i; + struct calendar fscal; + + /* + * Decode ASN.1 objects and construct certificate structure. + */ + ptr = asn1cert; + if ((cert = d2i_X509(NULL, &ptr, len)) == NULL) { + msyslog(LOG_ERR, "cert_parse: %s", + ERR_error_string(ERR_get_error(), NULL)); + return (NULL); + } +#ifdef DEBUG + if (debug > 1) + X509_print_fp(stdout, cert); +#endif + + /* + * Extract version, subject name and public key. + */ + ret = emalloc_zero(sizeof(*ret)); + if ((ret->pkey = X509_get_pubkey(cert)) == NULL) { + msyslog(LOG_ERR, "cert_parse: %s", + ERR_error_string(ERR_get_error(), NULL)); + cert_free(ret); + X509_free(cert); + return (NULL); + } + ret->version = X509_get_version(cert); + X509_NAME_oneline(X509_get_subject_name(cert), pathbuf, + sizeof(pathbuf)); + pch = strstr(pathbuf, "CN="); + if (NULL == pch) { + msyslog(LOG_NOTICE, "cert_parse: invalid subject %s", + pathbuf); + cert_free(ret); + X509_free(cert); + return (NULL); + } + ret->subject = estrdup(pch + 3); + + /* + * Extract remaining objects. Note that the NTP serial number is + * the NTP seconds at the time of signing, but this might not be + * the case for other authority. We don't bother to check the + * objects at this time, since the real crunch can happen only + * when the time is valid but not yet certificated. + */ + ret->nid = OBJ_obj2nid(cert->cert_info->signature->algorithm); + ret->digest = (const EVP_MD *)EVP_get_digestbynid(ret->nid); + ret->serial = + (u_long)ASN1_INTEGER_get(X509_get_serialNumber(cert)); + X509_NAME_oneline(X509_get_issuer_name(cert), pathbuf, + sizeof(pathbuf)); + if ((pch = strstr(pathbuf, "CN=")) == NULL) { + msyslog(LOG_NOTICE, "cert_parse: invalid issuer %s", + pathbuf); + cert_free(ret); + X509_free(cert); + return (NULL); + } + ret->issuer = estrdup(pch + 3); + asn_to_calendar(X509_get_notBefore(cert), &(ret->first)); + asn_to_calendar(X509_get_notAfter(cert), &(ret->last)); + + /* + * Extract extension fields. These are ad hoc ripoffs of + * currently assigned functions and will certainly be changed + * before prime time. + */ + cnt = X509_get_ext_count(cert); + for (i = 0; i < cnt; i++) { + ext = X509_get_ext(cert, i); + temp = OBJ_obj2nid(ext->object); + switch (temp) { + + /* + * If a key_usage field is present, we decode whether + * this is a trusted or private certificate. This is + * dorky; all we want is to compare NIDs, but OpenSSL + * insists on BIO text strings. + */ + case NID_ext_key_usage: + bp = BIO_new(BIO_s_mem()); + X509V3_EXT_print(bp, ext, 0, 0); + BIO_gets(bp, pathbuf, sizeof(pathbuf)); + BIO_free(bp); + if (strcmp(pathbuf, "Trust Root") == 0) + ret->flags |= CERT_TRUST; + else if (strcmp(pathbuf, "Private") == 0) + ret->flags |= CERT_PRIV; + DPRINTF(1, ("cert_parse: %s: %s\n", + OBJ_nid2ln(temp), pathbuf)); + break; + + /* + * If a NID_subject_key_identifier field is present, it + * contains the GQ public key. + */ + case NID_subject_key_identifier: + ret->grpkey = BN_bin2bn(&ext->value->data[2], + ext->value->length - 2, NULL); + /* fall through */ + default: + DPRINTF(1, ("cert_parse: %s\n", + OBJ_nid2ln(temp))); + break; + } + } + if (strcmp(ret->subject, ret->issuer) == 0) { + + /* + * If certificate is self signed, verify signature. + */ + if (X509_verify(cert, ret->pkey) <= 0) { + msyslog(LOG_NOTICE, + "cert_parse: signature not verified %s", + ret->subject); + cert_free(ret); + X509_free(cert); + return (NULL); + } + } else { + + /* + * Check for a certificate loop. + */ + if (strcmp((const char *)hostval.ptr, ret->issuer) == 0) { + msyslog(LOG_NOTICE, + "cert_parse: certificate trail loop %s", + ret->subject); + cert_free(ret); + X509_free(cert); + return (NULL); + } } - yp->link = cinfo; - cinfo = yp; /* - * Scan the certificate list to see if Y is signed by X. This is - * independent of order. + * Verify certificate valid times. Note that certificates cannot + * be retroactive. */ - for (yp = cinfo; yp != NULL; yp = yp->link) { - for (xp = cinfo; xp != NULL; xp = xp->link) { - - /* - * If the issuer of certificate Y matches the - * subject of certificate X, verify the - * signature of Y using the public key of X. If - * so, X signs Y. - */ - if (strcmp(yp->issuer, xp->subject) != 0 || - xp->flags & CERT_ERROR) - continue; - - if (cert_valid(yp, xp->pkey) != XEVNT_OK) { - yp->flags |= CERT_ERROR; - continue; - } - - /* - * The signature Y is valid only if it begins - * during the lifetime of X; however, it is not - * necessarily an error, since some other - * certificate might sign Y. - */ - if (yp->first < xp->first || yp->first > - xp->last) - continue; - - yp->flags |= CERT_SIGN; - - /* - * If X is trusted, then Y is trusted. Note that - * we might stumble over a self-signed - * certificate that is not trusted, at least - * temporarily. This can happen when a dude - * first comes up, but has not synchronized the - * clock and had its certificate signed by its - * server. In case of broken certificate trail, - * this might result in a loop that could - * persist until timeout. - */ - if (!(xp->flags & (CERT_TRUST | CERT_VALID))) - continue; - - yp->flags |= CERT_VALID; - - /* - * If subject Y matches the server subject name, - * then Y has completed the certificate trail. - * Save the group key and light the valid bit. - */ - if (strcmp(yp->subject, peer->subject) != 0) - continue; - - if (yp->grpkey != NULL) { - if (peer->grpkey != NULL) - BN_free(peer->grpkey); - peer->grpkey = BN_bin2bn(yp->grpkey, - yp->grplen, NULL); - } - peer->crypto |= CRYPTO_FLAG_VALID; - - /* - * If the server has an an identity scheme, - * fetch the identity credentials. If not, the - * identity is verified only by the trusted - * certificate. The next signature will set the - * server proventic. - */ - if (peer->crypto & (CRYPTO_FLAG_GQ | - CRYPTO_FLAG_IFF | CRYPTO_FLAG_MV)) - continue; - - peer->crypto |= CRYPTO_FLAG_VRFY; - } + (void)ntpcal_ntp_to_date(&fscal, fstamp, NULL); + if ((calcomp(&(ret->first), &(ret->last)) > 0) + || (calcomp(&(ret->first), &fscal) < 0)) { + msyslog(LOG_NOTICE, + "cert_parse: invalid times %s first %u-%02u-%02uT%02u:%02u:%02u last %u-%02u-%02uT%02u:%02u:%02u fstamp %u-%02u-%02uT%02u:%02u:%02u", + ret->subject, + ret->first.year, ret->first.month, ret->first.monthday, + ret->first.hour, ret->first.minute, ret->first.second, + ret->last.year, ret->last.month, ret->last.monthday, + ret->last.hour, ret->last.minute, ret->last.second, + fscal.year, fscal.month, fscal.monthday, + fscal.hour, fscal.minute, fscal.second); + cert_free(ret); + X509_free(cert); + return (NULL); } /* - * That was awesome. Now update the timestamps and signatures. + * Build the value structure to sign and send later. */ - crypto_update(); - return (XEVNT_OK); + ret->cert.fstamp = htonl(fstamp); + ret->cert.vallen = htonl(len); + ret->cert.ptr = emalloc(len); + memcpy(ret->cert.ptr, asn1cert, len); + X509_free(cert); + return (ret); } @@ -3571,50 +3559,56 @@ cert_free( if (cinf->issuer != NULL) free(cinf->issuer); if (cinf->grpkey != NULL) - free(cinf->grpkey); + BN_free(cinf->grpkey); value_free(&cinf->cert); free(cinf); } /* - *********************************************************************** - * * - * The following routines are used only at initialization time * - * * - *********************************************************************** - */ -/* - * crypto_key - load cryptographic parameters and keys from files - * - * This routine loads a PEM-encoded public/private key pair and extracts - * the filestamp from the file name. - * - * Returns public key pointer if valid, NULL if not. Side effect updates - * the filestamp if valid. + * crypto_key - load cryptographic parameters and keys + * + * This routine searches the key cache for matching name in the form + * ntpkey__, where is one of host, sign, iff, gq, mv, + * and is the host/group name. If not found, it tries to load a + * PEM-encoded file of the same name and extracts the filestamp from + * the first line of the file name. It returns the key pointer if valid, + * NULL if not. */ -static EVP_PKEY * +static struct pkey_info * crypto_key( char *cp, /* file name */ - tstamp_t *fstamp /* filestamp */ + char *passwd1, /* password */ + sockaddr_u *addr /* IP address */ ) { FILE *str; /* file handle */ + struct pkey_info *pkp; /* generic key */ EVP_PKEY *pkey = NULL; /* public/private key */ + tstamp_t fstamp; char filename[MAXFILENAME]; /* name of key file */ char linkname[MAXFILENAME]; /* filestamp buffer) */ char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ char *ptr; + /* + * Search the key cache for matching key and name. + */ + for (pkp = pkinfo; pkp != NULL; pkp = pkp->link) { + if (strcmp(cp, pkp->name) == 0) + return (pkp); + } + /* * Open the key file. If the first character of the file name is * not '/', prepend the keys directory string. If something goes * wrong, abandon ship. */ if (*cp == '/') - strcpy(filename, cp); + strlcpy(filename, cp, sizeof(filename)); else - snprintf(filename, MAXFILENAME, "%s/%s", keysdir, cp); + snprintf(filename, sizeof(filename), "%s/%s", keysdir, + cp); str = fopen(filename, "r"); if (str == NULL) return (NULL); @@ -3622,65 +3616,83 @@ crypto_key( /* * Read the filestamp, which is contained in the first line. */ - if ((ptr = fgets(linkname, MAXFILENAME, str)) == NULL) { - msyslog(LOG_ERR, "crypto_key: no data %s\n", + if ((ptr = fgets(linkname, sizeof(linkname), str)) == NULL) { + msyslog(LOG_ERR, "crypto_key: empty file %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } if ((ptr = strrchr(ptr, '.')) == NULL) { - msyslog(LOG_ERR, "crypto_key: no filestamp %s\n", + msyslog(LOG_ERR, "crypto_key: no filestamp %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } - if (sscanf(++ptr, "%u", fstamp) != 1) { - msyslog(LOG_ERR, "crypto_key: invalid timestamp %s\n", + if (sscanf(++ptr, "%u", &fstamp) != 1) { + msyslog(LOG_ERR, "crypto_key: invalid filestamp %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } /* - * Read and decrypt PEM-encoded private key. + * Read and decrypt PEM-encoded private key. If it fails to + * decrypt, game over. */ - pkey = PEM_read_PrivateKey(str, NULL, NULL, passwd); + pkey = PEM_read_PrivateKey(str, NULL, NULL, passwd1); fclose(str); if (pkey == NULL) { - msyslog(LOG_ERR, "crypto_key %s\n", + msyslog(LOG_ERR, "crypto_key: %s", ERR_error_string(ERR_get_error(), NULL)); - return (NULL); + exit (-1); } + /* + * Make a new entry in the key cache. + */ + pkp = emalloc(sizeof(struct pkey_info)); + pkp->link = pkinfo; + pkinfo = pkp; + pkp->pkey = pkey; + pkp->name = estrdup(cp); + pkp->fstamp = fstamp; + /* * Leave tracks in the cryptostats. */ if ((ptr = strrchr(linkname, '\n')) != NULL) *ptr = '\0'; - snprintf(statstr, NTP_MAXSTRLEN, "%s mod %d", &linkname[2], + snprintf(statstr, sizeof(statstr), "%s mod %d", &linkname[2], EVP_PKEY_size(pkey) * 8); - record_crypto_stats(NULL, statstr); + record_crypto_stats(addr, statstr); + + DPRINTF(1, ("crypto_key: %s\n", statstr)); #ifdef DEBUG - if (debug) - printf("crypto_key: %s\n", statstr); if (debug > 1) { if (pkey->type == EVP_PKEY_DSA) DSA_print_fp(stdout, pkey->pkey.dsa, 0); - else + else if (pkey->type == EVP_PKEY_RSA) RSA_print_fp(stdout, pkey->pkey.rsa, 0); } #endif - return (pkey); + return (pkp); } +/* + *********************************************************************** + * * + * The following routines are used only at initialization time * + * * + *********************************************************************** + */ /* * crypto_cert - load certificate from file * - * This routine loads a X.509 RSA or DSA certificate from a file and + * This routine loads an X.509 RSA or DSA certificate from a file and * constructs a info/cert value structure for this machine. The * structure includes a filestamp extracted from the file name. Later - * the certificate can be sent to another machine by request. + * the certificate can be sent to another machine on request. * * Returns certificate info/value pointer if valid, NULL if not. */ @@ -3706,9 +3718,10 @@ crypto_cert( * something goes wrong, abandon ship. */ if (*cp == '/') - strcpy(filename, cp); + strlcpy(filename, cp, sizeof(filename)); else - snprintf(filename, MAXFILENAME, "%s/%s", keysdir, cp); + snprintf(filename, sizeof(filename), "%s/%s", keysdir, + cp); str = fopen(filename, "r"); if (str == NULL) return (NULL); @@ -3716,22 +3729,22 @@ crypto_cert( /* * Read the filestamp, which is contained in the first line. */ - if ((ptr = fgets(linkname, MAXFILENAME, str)) == NULL) { - msyslog(LOG_ERR, "crypto_cert: no data %s\n", + if ((ptr = fgets(linkname, sizeof(linkname), str)) == NULL) { + msyslog(LOG_ERR, "crypto_cert: empty file %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } if ((ptr = strrchr(ptr, '.')) == NULL) { - msyslog(LOG_ERR, "crypto_cert: no filestamp %s\n", + msyslog(LOG_ERR, "crypto_cert: no filestamp %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } if (sscanf(++ptr, "%u", &fstamp) != 1) { - msyslog(LOG_ERR, "crypto_cert: invalid filestamp %s\n", + msyslog(LOG_ERR, "crypto_cert: invalid filestamp %s", filename); - (void)fclose(str); + fclose(str); return (NULL); } @@ -3739,266 +3752,144 @@ crypto_cert( * Read PEM-encoded certificate and install. */ if (!PEM_read(str, &name, &header, &data, &len)) { - msyslog(LOG_ERR, "crypto_cert %s\n", + msyslog(LOG_ERR, "crypto_cert: %s", ERR_error_string(ERR_get_error(), NULL)); - (void)fclose(str); + fclose(str); return (NULL); } + fclose(str); free(header); - if (strcmp(name, "CERTIFICATE") !=0) { - msyslog(LOG_INFO, "crypto_cert: wrong PEM type %s", + if (strcmp(name, "CERTIFICATE") != 0) { + msyslog(LOG_NOTICE, "crypto_cert: wrong PEM type %s", name); free(name); free(data); - (void)fclose(str); return (NULL); } free(name); /* - * Parse certificate and generate info/value structure. + * Parse certificate and generate info/value structure. The + * pointer and copy nonsense is due something broken in Solaris. */ ret = cert_parse(data, len, fstamp); free(data); - (void)fclose(str); if (ret == NULL) return (NULL); if ((ptr = strrchr(linkname, '\n')) != NULL) *ptr = '\0'; - snprintf(statstr, NTP_MAXSTRLEN, - "%s 0x%x len %lu", &linkname[2], ret->flags, len); + snprintf(statstr, sizeof(statstr), "%s 0x%x len %lu", + &linkname[2], ret->flags, len); record_crypto_stats(NULL, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_cert: %s\n", statstr); -#endif + DPRINTF(1, ("crypto_cert: %s\n", statstr)); return (ret); } /* - * crypto_tai - load leapseconds table from file - * - * This routine loads the ERTS leapsecond file in NIST text format, - * converts to a value structure and extracts a filestamp from the file - * name. The data are used to establish the TAI offset from UTC, which - * is provided to the kernel if supported. Later the data can be sent to - * another machine on request. - */ -static void -crypto_tai( - char *cp /* file name */ - ) -{ - FILE *str; /* file handle */ - char buf[NTP_MAXSTRLEN]; /* file line buffer */ - u_int32 leapsec[MAX_LEAP]; /* NTP time at leaps */ - int offset; /* offset at leap (s) */ - char filename[MAXFILENAME]; /* name of leapseconds file */ - char linkname[MAXFILENAME]; /* file link (for filestamp) */ - char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ - tstamp_t fstamp; /* filestamp */ - u_int len; - u_int32 *ptr; - char *dp; - int rval, i, j; - - /* - * Open the file and discard comment lines. If the first - * character of the file name is not '/', prepend the keys - * directory string. If the file is not found, not to worry; it - * can be retrieved over the net. But, if it is found with - * errors, we crash and burn. - */ - if (*cp == '/') - strcpy(filename, cp); - else - snprintf(filename, MAXFILENAME, "%s/%s", keysdir, cp); - if ((str = fopen(filename, "r")) == NULL) - return; - - /* - * Extract filestamp if present. - */ - rval = readlink(filename, linkname, MAXFILENAME - 1); - if (rval > 0) { - linkname[rval] = '\0'; - dp = strrchr(linkname, '.'); - } else { - dp = strrchr(filename, '.'); - } - if (dp != NULL) - sscanf(++dp, "%u", &fstamp); - else - fstamp = 0; - tai_leap.fstamp = htonl(fstamp); - - /* - * We are rather paranoid here, since an intruder might cause a - * coredump by infiltrating naughty values. Empty lines and - * comments are ignored. Other lines must begin with two - * integers followed by junk or comments. The first integer is - * the NTP seconds of leap insertion, the second is the offset - * of TAI relative to UTC after that insertion. The second word - * must equal the initial insertion of ten seconds on 1 January - * 1972 plus one second for each succeeding insertion. - */ - i = 0; - while (i < MAX_LEAP) { - dp = fgets(buf, NTP_MAXSTRLEN - 1, str); - if (dp == NULL) - break; - - if (strlen(buf) < 1) - continue; - - if (*buf == '#') - continue; - - if (sscanf(buf, "%u %d", &leapsec[i], &offset) != 2) - continue; - - if (i != offset - TAI_1972) - break; - - i++; - } - fclose(str); - if (dp != NULL) { - msyslog(LOG_INFO, - "crypto_tai: leapseconds file %s error %d", cp, - rval); - exit (-1); - } - - /* - * The extension field table entries consists of the NTP seconds - * of leap insertion in network byte order. - */ - len = i * sizeof(u_int32); - tai_leap.vallen = htonl(len); - ptr = emalloc(len); - tai_leap.ptr = (u_char *)ptr; - for (j = 0; j < i; j++) - *ptr++ = htonl(leapsec[j]); - crypto_flags |= CRYPTO_FLAG_TAI; - snprintf(statstr, NTP_MAXSTRLEN, "%s fs %u leap %u len %u", cp, fstamp, - leapsec[--j], len); - record_crypto_stats(NULL, statstr); -#ifdef DEBUG - if (debug) - printf("crypto_tai: %s\n", statstr); -#endif -} - - -/* - * crypto_setup - load keys, certificate and leapseconds table + * crypto_setup - load keys, certificate and identity parameters * * This routine loads the public/private host key and certificate. If * available, it loads the public/private sign key, which defaults to - * the host key, and leapseconds table. The host key must be RSA, but - * the sign key can be either RSA or DSA. In either case, the public key - * on the certificate must agree with the sign key. + * the host key. The host key must be RSA, but the sign key can be + * either RSA or DSA. If a trusted certificate, it loads the identity + * parameters. In either case, the public key on the certificate must + * agree with the sign key. + * + * Required but missing files and inconsistent data and errors are + * fatal. Allowing configuration to continue would be hazardous and + * require really messy error checks. */ void crypto_setup(void) { - EVP_PKEY *pkey; /* private/public key pair */ + struct pkey_info *pinfo; /* private/public key */ char filename[MAXFILENAME]; /* file name buffer */ + char hostname[MAXFILENAME]; /* host name buffer */ + char *randfile; + char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ l_fp seed; /* crypto PRNG seed as NTP timestamp */ - tstamp_t fstamp; /* filestamp */ - tstamp_t sstamp; /* sign filestamp */ - u_int len, bytes; + u_int len; + int bytes; u_char *ptr; /* - * Initialize structures. + * Check for correct OpenSSL version and avoid initialization in + * the case of multiple crypto commands. */ - if (!crypto_flags) + if (crypto_flags & CRYPTO_FLAG_ENAB) { + msyslog(LOG_NOTICE, + "crypto_setup: spurious crypto command"); return; - - gethostname(filename, MAXFILENAME); - bytes = strlen(filename) + 1; - sys_hostname = emalloc(bytes); - memcpy(sys_hostname, filename, bytes); - if (passwd == NULL) - passwd = sys_hostname; - memset(&hostval, 0, sizeof(hostval)); - memset(&pubkey, 0, sizeof(pubkey)); - memset(&tai_leap, 0, sizeof(tai_leap)); + } + ssl_check_version(); /* * Load required random seed file and seed the random number - * generator. Be default, it is found in the user home + * generator. Be default, it is found as .rnd in the user home * directory. The root home directory may be / or /root, * depending on the system. Wiggle the contents a bit and write * it back so the sequence does not repeat when we next restart. */ - ERR_load_crypto_strings(); - if (rand_file == NULL) { - if ((RAND_file_name(filename, MAXFILENAME)) != NULL) { - rand_file = emalloc(strlen(filename) + 1); - strcpy(rand_file, filename); + if (!RAND_status()) { + if (rand_file == NULL) { + RAND_file_name(filename, sizeof(filename)); + randfile = filename; + } else if (*rand_file != '/') { + snprintf(filename, sizeof(filename), "%s/%s", + keysdir, rand_file); + randfile = filename; + } else + randfile = rand_file; + + if ((bytes = RAND_load_file(randfile, -1)) == 0) { + msyslog(LOG_ERR, + "crypto_setup: random seed file %s missing", + randfile); + exit (-1); } - } else if (*rand_file != '/') { - snprintf(filename, MAXFILENAME, "%s/%s", keysdir, - rand_file); - free(rand_file); - rand_file = emalloc(strlen(filename) + 1); - strcpy(rand_file, filename); - } - if (rand_file == NULL) { - msyslog(LOG_ERR, - "crypto_setup: random seed file not specified"); - exit (-1); - } - if ((bytes = RAND_load_file(rand_file, -1)) == 0) { - msyslog(LOG_ERR, - "crypto_setup: random seed file %s not found\n", - rand_file); - exit (-1); + arc4random_buf(&seed, sizeof(l_fp)); + RAND_seed(&seed, sizeof(l_fp)); + RAND_write_file(randfile); + DPRINTF(1, ("crypto_setup: OpenSSL version %lx random seed file %s bytes read %d\n", + SSLeay(), randfile, bytes)); } - arc4random_buf(&seed, sizeof(l_fp)); - RAND_seed(&seed, sizeof(l_fp)); - RAND_write_file(rand_file); - OpenSSL_add_all_algorithms(); -#ifdef DEBUG - if (debug) - printf( - "crypto_setup: OpenSSL version %lx random seed file %s bytes read %d\n", - SSLeay(), rand_file, bytes); -#endif /* - * Load required host key from file "ntpkey_host_". It - * also becomes the default sign key. + * Initialize structures. */ - if (host_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_host_%s", - sys_hostname); - host_file = emalloc(strlen(filename) + 1); - strcpy(host_file, filename); - } - pkey = crypto_key(host_file, &fstamp); - if (pkey == NULL) { + gethostname(hostname, sizeof(hostname)); + if (host_filename != NULL) + strlcpy(hostname, host_filename, sizeof(hostname)); + if (passwd == NULL) + passwd = estrdup(hostname); + memset(&hostval, 0, sizeof(hostval)); + memset(&pubkey, 0, sizeof(pubkey)); + memset(&tai_leap, 0, sizeof(tai_leap)); + + /* + * Load required host key from file "ntpkey_host_". If + * no host key file is not found or has invalid password, life + * as we know it ends. The host key also becomes the default + * sign key. + */ + snprintf(filename, sizeof(filename), "ntpkey_host_%s", hostname); + pinfo = crypto_key(filename, passwd, NULL); + if (pinfo == NULL) { msyslog(LOG_ERR, "crypto_setup: host key file %s not found or corrupt", - host_file); + filename); exit (-1); } - host_pkey = pkey; - sign_pkey = pkey; - sstamp = fstamp; - hostval.fstamp = htonl(fstamp); - if (host_pkey->type != EVP_PKEY_RSA) { + if (pinfo->pkey->type != EVP_PKEY_RSA) { msyslog(LOG_ERR, "crypto_setup: host key is not RSA key type"); exit (-1); } - hostval.vallen = htonl(strlen(sys_hostname)); - hostval.ptr = (u_char *)sys_hostname; + host_pkey = pinfo->pkey; + sign_pkey = host_pkey; + hostval.fstamp = htonl(pinfo->fstamp); /* * Construct public key extension field for agreement scheme. @@ -4007,229 +3898,188 @@ crypto_setup(void) ptr = emalloc(len); pubkey.ptr = ptr; i2d_PublicKey(host_pkey, &ptr); - pubkey.vallen = htonl(len); pubkey.fstamp = hostval.fstamp; + pubkey.vallen = htonl(len); /* * Load optional sign key from file "ntpkey_sign_". If - * loaded, it becomes the sign key. - */ - if (sign_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_sign_%s", - sys_hostname); - sign_file = emalloc(strlen(filename) + 1); - strcpy(sign_file, filename); - } - pkey = crypto_key(sign_file, &fstamp); - if (pkey != NULL) { - sign_pkey = pkey; - sstamp = fstamp; - } - sign_siglen = EVP_PKEY_size(sign_pkey); - - /* - * Load optional IFF parameters from file - * "ntpkey_iff_". + * available, it becomes the sign key. */ - if (iffpar_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_iff_%s", - sys_hostname); - iffpar_file = emalloc(strlen(filename) + 1); - strcpy(iffpar_file, filename); - } - iffpar_pkey = crypto_key(iffpar_file, &if_fstamp); - if (iffpar_pkey != NULL) - crypto_flags |= CRYPTO_FLAG_IFF; + snprintf(filename, sizeof(filename), "ntpkey_sign_%s", hostname); + pinfo = crypto_key(filename, passwd, NULL); + if (pinfo != NULL) + sign_pkey = pinfo->pkey; /* - * Load optional GQ parameters from file "ntpkey_gq_". + * Load required certificate from file "ntpkey_cert_". */ - if (gqpar_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_gq_%s", - sys_hostname); - gqpar_file = emalloc(strlen(filename) + 1); - strcpy(gqpar_file, filename); + snprintf(filename, sizeof(filename), "ntpkey_cert_%s", hostname); + cinfo = crypto_cert(filename); + if (cinfo == NULL) { + msyslog(LOG_ERR, + "crypto_setup: certificate file %s not found or corrupt", + filename); + exit (-1); } - gqpar_pkey = crypto_key(gqpar_file, &gq_fstamp); - if (gqpar_pkey != NULL) - crypto_flags |= CRYPTO_FLAG_GQ; + cert_host = cinfo; + sign_digest = cinfo->digest; + sign_siglen = EVP_PKEY_size(sign_pkey); + if (cinfo->flags & CERT_PRIV) + crypto_flags |= CRYPTO_FLAG_PRIV; /* - * Load optional MV parameters from file "ntpkey_mv_". + * The certificate must be self-signed. */ - if (mvpar_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_mv_%s", - sys_hostname); - mvpar_file = emalloc(strlen(filename) + 1); - strcpy(mvpar_file, filename); + if (strcmp(cinfo->subject, cinfo->issuer) != 0) { + msyslog(LOG_ERR, + "crypto_setup: certificate %s is not self-signed", + filename); + exit (-1); } - mvpar_pkey = crypto_key(mvpar_file, &mv_fstamp); - if (mvpar_pkey != NULL) - crypto_flags |= CRYPTO_FLAG_MV; + hostval.ptr = estrdup(cinfo->subject); + hostval.vallen = htonl(strlen(cinfo->subject)); + sys_hostname = hostval.ptr; + ptr = (u_char *)strchr(sys_hostname, '@'); + if (ptr != NULL) + sys_groupname = estrdup((char *)++ptr); + if (ident_filename != NULL) + strlcpy(hostname, ident_filename, sizeof(hostname)); /* - * Load required certificate from file "ntpkey_cert_". + * Load optional IFF parameters from file + * "ntpkey_iffkey_". */ - if (cert_file == NULL) { - snprintf(filename, MAXFILENAME, "ntpkey_cert_%s", - sys_hostname); - cert_file = emalloc(strlen(filename) + 1); - strcpy(cert_file, filename); - } - if ((cinfo = crypto_cert(cert_file)) == NULL) { - msyslog(LOG_ERR, - "certificate file %s not found or corrupt", - cert_file); - exit (-1); - } + snprintf(filename, sizeof(filename), "ntpkey_iffkey_%s", + hostname); + iffkey_info = crypto_key(filename, passwd, NULL); + if (iffkey_info != NULL) + crypto_flags |= CRYPTO_FLAG_IFF; /* - * The subject name must be the same as the host name, unless - * the certificate is private, in which case it may have come - * from another host. + * Load optional GQ parameters from file + * "ntpkey_gqkey_". */ - if (!(cinfo->flags & CERT_PRIV) && strcmp(cinfo->subject, - sys_hostname) != 0) { - msyslog(LOG_ERR, - "crypto_setup: certificate %s not for this host", - cert_file); - cert_free(cinfo); - exit (-1); - } + snprintf(filename, sizeof(filename), "ntpkey_gqkey_%s", + hostname); + gqkey_info = crypto_key(filename, passwd, NULL); + if (gqkey_info != NULL) + crypto_flags |= CRYPTO_FLAG_GQ; /* - * It the certificate is trusted, the subject must be the same - * as the issuer, in other words it must be self signed. + * Load optional MV parameters from file + * "ntpkey_mvkey_". */ - if (cinfo->flags & CERT_TRUST && strcmp(cinfo->subject, - cinfo->issuer) != 0) { - if (cert_valid(cinfo, sign_pkey) != XEVNT_OK) { - msyslog(LOG_ERR, - "crypto_setup: certificate %s is trusted, but not self signed.", - cert_file); - cert_free(cinfo); - exit (-1); - } - } - sign_digest = cinfo->digest; - if (cinfo->flags & CERT_PRIV) - crypto_flags |= CRYPTO_FLAG_PRIV; - crypto_flags |= cinfo->nid << 16; + snprintf(filename, sizeof(filename), "ntpkey_mvkey_%s", + hostname); + mvkey_info = crypto_key(filename, passwd, NULL); + if (mvkey_info != NULL) + crypto_flags |= CRYPTO_FLAG_MV; /* - * Load optional leapseconds table from file "ntpkey_leap". If - * the file is missing or defective, the values can later be - * retrieved from a server. + * We met the enemy and he is us. Now strike up the dance. */ - if (leap_file == NULL) - leap_file = "ntpkey_leap"; - crypto_tai(leap_file); -#ifdef DEBUG - if (debug) - printf( - "crypto_setup: flags 0x%x host %s signature %s\n", - crypto_flags, sys_hostname, OBJ_nid2ln(cinfo->nid)); -#endif + crypto_flags |= CRYPTO_FLAG_ENAB | (cinfo->nid << 16); + snprintf(statstr, sizeof(statstr), "setup 0x%x host %s %s", + crypto_flags, hostname, OBJ_nid2ln(cinfo->nid)); + record_crypto_stats(NULL, statstr); + DPRINTF(1, ("crypto_setup: %s\n", statstr)); } /* - * crypto_config - configure data from crypto configuration command. + * crypto_config - configure data from the crypto command. */ void crypto_config( int item, /* configuration item */ - char *cp /* file name */ + char *cp /* item name */ ) { - switch (item) { + int nid; - /* - * Set random seed file name. - */ - case CRYPTO_CONF_RAND: - rand_file = emalloc(strlen(cp) + 1); - strcpy(rand_file, cp); - break; + DPRINTF(1, ("crypto_config: item %d %s\n", item, cp)); - /* - * Set private key password. - */ - case CRYPTO_CONF_PW: - passwd = emalloc(strlen(cp) + 1); - strcpy(passwd, cp); - break; + switch (item) { /* - * Set host file name. + * Set host name (host). */ case CRYPTO_CONF_PRIV: - host_file = emalloc(strlen(cp) + 1); - strcpy(host_file, cp); - break; - - /* - * Set sign key file name. - */ - case CRYPTO_CONF_SIGN: - sign_file = emalloc(strlen(cp) + 1); - strcpy(sign_file, cp); - break; - - /* - * Set iff parameters file name. - */ - case CRYPTO_CONF_IFFPAR: - iffpar_file = emalloc(strlen(cp) + 1); - strcpy(iffpar_file, cp); + if (NULL != host_filename) + free(host_filename); + host_filename = estrdup(cp); break; /* - * Set gq parameters file name. + * Set group name (ident). */ - case CRYPTO_CONF_GQPAR: - gqpar_file = emalloc(strlen(cp) + 1); - strcpy(gqpar_file, cp); + case CRYPTO_CONF_IDENT: + if (NULL != ident_filename) + free(ident_filename); + ident_filename = estrdup(cp); break; /* - * Set mv parameters file name. + * Set private key password (pw). */ - case CRYPTO_CONF_MVPAR: - mvpar_file = emalloc(strlen(cp) + 1); - strcpy(mvpar_file, cp); + case CRYPTO_CONF_PW: + if (NULL != passwd) + free(passwd); + passwd = estrdup(cp); break; /* - * Set identity scheme. + * Set random seed file name (randfile). */ - case CRYPTO_CONF_IDENT: - if (!strcasecmp(cp, "iff")) - ident_scheme |= CRYPTO_FLAG_IFF; - else if (!strcasecmp(cp, "gq")) - ident_scheme |= CRYPTO_FLAG_GQ; - else if (!strcasecmp(cp, "mv")) - ident_scheme |= CRYPTO_FLAG_MV; + case CRYPTO_CONF_RAND: + if (NULL != rand_file) + free(rand_file); + rand_file = estrdup(cp); break; /* - * Set certificate file name. + * Set message digest NID. */ - case CRYPTO_CONF_CERT: - cert_file = emalloc(strlen(cp) + 1); - strcpy(cert_file, cp); + case CRYPTO_CONF_NID: + nid = OBJ_sn2nid(cp); + if (nid == 0) + msyslog(LOG_ERR, + "crypto_config: invalid digest name %s", cp); + else + crypto_nid = nid; break; + } +} - /* - * Set leapseconds file name. - */ - case CRYPTO_CONF_LEAP: - leap_file = emalloc(strlen(cp) + 1); - strcpy(leap_file, cp); - break; +/* + * Get the payload size (internal value length) of an extension packet. + * If the inner value size does not match the outer packet size (that + * is, the value would end behind the frame given by the opcode/size + * field) the function will effectively return UINT_MAX. If the frame is + * too short to hold a variable-sized value, the return value is zero. + */ +static u_int +exten_payload_size( + const struct exten * ep) +{ + typedef const u_char *BPTR; + + size_t extn_size; + size_t data_size; + size_t head_size; + + data_size = 0; + if (NULL != ep) { + head_size = (BPTR)(&ep->vallen + 1) - (BPTR)ep; + extn_size = (uint16_t)(ntohl(ep->opcode) & 0x0000ffff); + if (extn_size >= head_size) { + data_size = (uint32_t)ntohl(ep->vallen); + if (data_size > extn_size - head_size) + data_size = ~(size_t)0u; + } } - crypto_flags |= CRYPTO_FLAG_ENAB; + return (u_int)data_size; } -# else +# else /* !AUTOKEY follows */ int ntp_crypto_bs_pubkey; -# endif /* OPENSSL */ +# endif /* !AUTOKEY */ diff --git a/contrib/ntp/ntpd/ntp_filegen.c b/contrib/ntp/ntpd/ntp_filegen.c index 932d1b6f1..4ee90955c 100644 --- a/contrib/ntp/ntpd/ntp_filegen.c +++ b/contrib/ntp/ntpd/ntp_filegen.c @@ -6,7 +6,7 @@ * * * Copyright (C) 1992, 1996 by Rainer Pruy - * Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * This code may be modified and used freely * provided credits remain intact. @@ -44,34 +44,48 @@ */ #define SUFFIX_SEP '.' +static void filegen_open (FILEGEN *, u_int32, const time_t*); +static int valid_fileref (const char *, const char *); +static void filegen_init (const char *, const char *, FILEGEN *); +#ifdef DEBUG +static void filegen_uninit (FILEGEN *); +#endif /* DEBUG */ + + /* - * other constants + * filegen_init */ -#define FGEN_AGE_SECS (24*60*60) /* life time of FILEGEN_AGE in seconds */ -static void filegen_open P((FILEGEN *, u_long)); -static int valid_fileref P((char *, char *)); -#ifdef UNUSED -static FILEGEN *filegen_unregister P((char *)); -#endif /* UNUSED */ +static void +filegen_init( + const char * dir, + const char * fname, + FILEGEN * fgp + ) +{ + fgp->fp = NULL; + fgp->dir = estrdup(dir); + fgp->fname = estrdup(fname); + fgp->id_lo = 0; + fgp->id_hi = 0; + fgp->type = FILEGEN_DAY; + fgp->flag = FGEN_FLAG_LINK; /* not yet enabled !!*/ +} -static void filegen_init P((char *, const char *, FILEGEN *)); /* - * filegen_init + * filegen_uninit - free memory allocated by filegen_init */ - +#ifdef DEBUG static void -filegen_init(char *prefix, const char *basename, FILEGEN *fp) +filegen_uninit( + FILEGEN *fgp + ) { - fp->fp = NULL; - fp->prefix = prefix; /* Yes, this is TOTALLY lame! */ - fp->basename = (char*)emalloc(strlen(basename) + 1); - strcpy(fp->basename, basename); - fp->id = 0; - fp->type = FILEGEN_DAY; - fp->flag = FGEN_FLAG_LINK; /* not yet enabled !!*/ + free(fgp->dir); + free(fgp->fname); } +#endif /* @@ -81,81 +95,117 @@ filegen_init(char *prefix, const char *basename, FILEGEN *fp) static void filegen_open( - FILEGEN *gen, - u_long newid + FILEGEN * gen, + u_int32 stamp, + const time_t * pivot ) { - char *filename; - char *basename; - u_int len; + char *savename; /* temp store for name collision handling */ + char *fullname; /* name with any designation extension */ + char *filename; /* name without designation extension */ + char *suffix; /* where to print suffix extension */ + u_int len, suflen; FILE *fp; struct calendar cal; + struct isodate iso; - len = strlen(gen->prefix) + strlen(gen->basename) + 1; - basename = (char*)emalloc(len); - sprintf(basename, "%s%s", gen->prefix, gen->basename); - - switch(gen->type) { - default: - msyslog(LOG_ERR, "unsupported file generations type %d for \"%s\" - reverting to FILEGEN_NONE", - gen->type, basename); + /* get basic filename in buffer, leave room for extensions */ + len = strlen(gen->dir) + strlen(gen->fname) + 65; + filename = emalloc(len); + fullname = emalloc(len); + savename = NULL; + snprintf(filename, len, "%s%s", gen->dir, gen->fname); + + /* where to place suffix */ + suflen = strlcpy(fullname, filename, len); + suffix = fullname + suflen; + suflen = len - suflen; + + /* last octet of fullname set to '\0' for truncation check */ + fullname[len - 1] = '\0'; + + switch (gen->type) { + + default: + msyslog(LOG_ERR, + "unsupported file generations type %d for " + "\"%s\" - reverting to FILEGEN_NONE", + gen->type, filename); gen->type = FILEGEN_NONE; - - /*FALLTHROUGH*/ - case FILEGEN_NONE: - filename = (char*)emalloc(len); - sprintf(filename,"%s", basename); break; - case FILEGEN_PID: - filename = (char*)emalloc(len + 1 + 1 + 10); - sprintf(filename,"%s%c#%ld", basename, SUFFIX_SEP, newid); + case FILEGEN_NONE: + /* no suffix, all set */ break; - - case FILEGEN_DAY: - /* You can argue here in favor of using MJD, but - * I would assume it to be easier for humans to interpret dates - * in a format they are used to in everyday life. - */ - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4 + 2 + 2); - sprintf(filename, "%s%c%04d%02d%02d", - basename, SUFFIX_SEP, cal.year, cal.month, cal.monthday); + + case FILEGEN_PID: + gen->id_lo = getpid(); + gen->id_hi = 0; + snprintf(suffix, suflen, "%c#%ld", + SUFFIX_SEP, gen->id_lo); break; - - case FILEGEN_WEEK: + + case FILEGEN_DAY: /* - * This is still a hack - * - the term week is not correlated to week as it is used - * normally - it just refers to a period of 7 days - * starting at Jan 1 - 'weeks' are counted starting from zero + * You can argue here in favor of using MJD, but I + * would assume it to be easier for humans to interpret + * dates in a format they are used to in everyday life. */ - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4 + 1 + 2); - sprintf(filename, "%s%c%04dw%02d", - basename, SUFFIX_SEP, cal.year, cal.yearday / 7); + ntpcal_ntp_to_date(&cal, stamp, pivot); + snprintf(suffix, suflen, "%c%04d%02d%02d", + SUFFIX_SEP, cal.year, cal.month, cal.monthday); + cal.hour = cal.minute = cal.second = 0; + gen->id_lo = ntpcal_date_to_ntp(&cal); + gen->id_hi = (u_int32)(gen->id_lo + SECSPERDAY); break; - case FILEGEN_MONTH: - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4 + 2); - sprintf(filename, "%s%c%04d%02d", - basename, SUFFIX_SEP, cal.year, cal.month); + case FILEGEN_WEEK: + isocal_ntp_to_date(&iso, stamp, pivot); + snprintf(suffix, suflen, "%c%04dw%02d", + SUFFIX_SEP, iso.year, iso.week); + iso.hour = iso.minute = iso.second = 0; + iso.weekday = 1; + gen->id_lo = isocal_date_to_ntp(&iso); + gen->id_hi = (u_int32)(gen->id_lo + 7 * SECSPERDAY); break; - case FILEGEN_YEAR: - caljulian(newid,&cal); - filename = (char*)emalloc(len + 1 + 4); - sprintf(filename, "%s%c%04d", basename, SUFFIX_SEP, cal.year); + case FILEGEN_MONTH: + ntpcal_ntp_to_date(&cal, stamp, pivot); + snprintf(suffix, suflen, "%c%04d%02d", + SUFFIX_SEP, cal.year, cal.month); + cal.hour = cal.minute = cal.second = 0; + cal.monthday = 1; + gen->id_lo = ntpcal_date_to_ntp(&cal); + cal.month++; + gen->id_hi = ntpcal_date_to_ntp(&cal); break; - case FILEGEN_AGE: - filename = (char*)emalloc(len + 1 + 2 + 10); - sprintf(filename, "%s%ca%08ld", basename, SUFFIX_SEP, newid); + case FILEGEN_YEAR: + ntpcal_ntp_to_date(&cal, stamp, pivot); + snprintf(suffix, suflen, "%c%04d", + SUFFIX_SEP, cal.year); + cal.hour = cal.minute = cal.second = 0; + cal.month = cal.monthday = 1; + gen->id_lo = ntpcal_date_to_ntp(&cal); + cal.year++; + gen->id_hi = ntpcal_date_to_ntp(&cal); break; + + case FILEGEN_AGE: + gen->id_lo = current_time - (current_time % SECSPERDAY); + gen->id_hi = gen->id_lo + SECSPERDAY; + snprintf(suffix, suflen, "%ca%08ld", + SUFFIX_SEP, gen->id_lo); } - if (gen->type != FILEGEN_NONE) { + /* check possible truncation */ + if ('\0' != fullname[len - 1]) { + fullname[len - 1] = '\0'; + msyslog(LOG_ERR, "logfile name truncated: \"%s\"", + fullname); + } + + if (FILEGEN_NONE != gen->type) { /* * check for existence of a file with name 'basename' * as we disallow such a file @@ -170,21 +220,23 @@ filegen_open( #ifndef S_ISREG #define S_ISREG(mode) (((mode) & S_IFREG) == S_IFREG) #endif - if (stat(basename, &stats) == 0) { + if (stat(filename, &stats) == 0) { /* Hm, file exists... */ if (S_ISREG(stats.st_mode)) { if (stats.st_nlink <= 1) { /* * Oh, it is not linked - try to save it */ - char *savename = (char*)emalloc(len + 1 + 1 + 10 + 10); - sprintf(savename, "%s%c%dC%lu", - basename, - SUFFIX_SEP, - (int) getpid(), - (u_long)conflicts++); - if (rename(basename, savename) != 0) - msyslog(LOG_ERR," couldn't save %s: %m", basename); + savename = emalloc(len); + snprintf(savename, len, + "%s%c%dC%lu", + filename, SUFFIX_SEP, + (int)getpid(), conflicts++); + + if (rename(filename, savename) != 0) + msyslog(LOG_ERR, + "couldn't save %s: %m", + filename); free(savename); } else { /* @@ -194,42 +246,45 @@ filegen_open( */ if ( #if !defined(VMS) - unlink(basename) != 0 + unlink(filename) != 0 #else - delete(basename) != 0 + delete(filename) != 0 #endif ) - msyslog(LOG_ERR, "couldn't unlink %s: %m", basename); + msyslog(LOG_ERR, + "couldn't unlink %s: %m", + filename); } } else { /* * Ehh? Not a regular file ?? strange !!!! */ - msyslog(LOG_ERR, "expected regular file for %s (found mode 0%lo)", - basename, (unsigned long)stats.st_mode); + msyslog(LOG_ERR, + "expected regular file for %s " + "(found mode 0%lo)", + filename, + (unsigned long)stats.st_mode); } } else { /* * stat(..) failed, but it is absolutely correct for * 'basename' not to exist */ - if (errno != ENOENT) - msyslog(LOG_ERR,"stat(%s) failed: %m", basename); + if (ENOENT != errno) + msyslog(LOG_ERR, "stat(%s) failed: %m", + filename); } } /* * now, try to open new file generation... */ - fp = fopen(filename, "a"); - -#ifdef DEBUG - if (debug > 3) - printf("opening filegen (type=%d/id=%lu) \"%s\"\n", - gen->type, (u_long)newid, filename); -#endif + DPRINTF(4, ("opening filegen (type=%d/stamp=%u) \"%s\"\n", + gen->type, stamp, fullname)); - if (fp == NULL) { + fp = fopen(fullname, "a"); + + if (NULL == fp) { /* open failed -- keep previous state * * If the file was open before keep the previous generation. @@ -239,14 +294,14 @@ filegen_open( * ignore errors due to missing directories */ - if (errno != ENOENT) - msyslog(LOG_ERR, "can't open %s: %m", filename); + if (ENOENT != errno) + msyslog(LOG_ERR, "can't open %s: %m", fullname); } else { - if (gen->fp != NULL) { + if (NULL != gen->fp) { fclose(gen->fp); + gen->fp = NULL; } gen->fp = fp; - gen->id = newid; if (gen->flag & FGEN_FLAG_LINK) { /* @@ -254,7 +309,7 @@ filegen_open( * have to use hardlink for now as I want to allow * gen->basename spanning directory levels * this would make it more complex to get the correct - * filename for symlink + * fullname for symlink * * Ok, it would just mean taking the part following * the last '/' in the name.... Should add it later.... @@ -262,20 +317,22 @@ filegen_open( /* Windows NT does not support file links -Greg Schueman 1/18/97 */ -#if defined SYS_WINNT || defined SYS_VXWORKS +#if defined(SYS_WINNT) || defined(SYS_VXWORKS) SetLastError(0); /* On WinNT, don't support FGEN_FLAG_LINK */ #elif defined(VMS) errno = 0; /* On VMS, don't support FGEN_FLAG_LINK */ #else /* not (VMS) / VXWORKS / WINNT ; DO THE LINK) */ - if (link(filename, basename) != 0) - if (errno != EEXIST) - msyslog(LOG_ERR, "can't link(%s, %s): %m", filename, basename); + if (link(fullname, filename) != 0) + if (EEXIST != errno) + msyslog(LOG_ERR, + "can't link(%s, %s): %m", + fullname, filename); #endif /* SYS_WINNT || VXWORKS */ } /* flags & FGEN_FLAG_LINK */ } /* else fp == NULL */ - free(basename); free(filename); + free(fullname); return; } @@ -289,78 +346,53 @@ filegen_open( void filegen_setup( - FILEGEN *gen, - u_long now + FILEGEN * gen, + u_int32 now ) { - u_long new_gen = ~ (u_long) 0; - struct calendar cal; + int current; + time_t pivot; if (!(gen->flag & FGEN_FLAG_ENABLED)) { - if (gen->fp != NULL) - fclose(gen->fp); + if (NULL != gen->fp) { + fclose(gen->fp); + gen->fp = NULL; + } return; } - + switch (gen->type) { - case FILEGEN_NONE: - if (gen->fp != NULL) return; /* file already open */ - break; - - case FILEGEN_PID: - new_gen = getpid(); - break; - case FILEGEN_DAY: - caljulian(now, &cal); - cal.hour = cal.minute = cal.second = 0; - new_gen = caltontp(&cal); + default: + case FILEGEN_NONE: + current = TRUE; break; - - case FILEGEN_WEEK: - /* Would be nice to have a calweekstart() routine */ - /* so just use a hack ... */ - /* just round time to integral 7 day period for actual year */ - new_gen = now - (now - calyearstart(now)) % TIMES7(SECSPERDAY) - + 60; - /* - * just to be sure - - * the computation above would fail in the presence of leap seconds - * so at least carry the date to the next day (+60 (seconds)) - * and go back to the start of the day via calendar computations - */ - caljulian(new_gen, &cal); - cal.hour = cal.minute = cal.second = 0; - new_gen = caltontp(&cal); - break; - - case FILEGEN_MONTH: - caljulian(now, &cal); - cal.yearday = (u_short) (cal.yearday - cal.monthday + 1); - cal.monthday = 1; - cal.hour = cal.minute = cal.second = 0; - new_gen = caltontp(&cal); + + case FILEGEN_PID: + current = ((int)gen->id_lo == getpid()); break; - - case FILEGEN_YEAR: - new_gen = calyearstart(now); + + case FILEGEN_AGE: + current = (gen->id_lo <= current_time) && + (gen->id_hi > current_time); break; - case FILEGEN_AGE: - new_gen = current_time - (current_time % FGEN_AGE_SECS); + case FILEGEN_DAY: + case FILEGEN_WEEK: + case FILEGEN_MONTH: + case FILEGEN_YEAR: + current = (gen->id_lo <= now) && + (gen->id_hi > now); break; } /* * try to open file if not yet open * reopen new file generation file on change of generation id */ - if (gen->fp == NULL || gen->id != new_gen) { -#if DEBUG - if (debug) - printf("filegen %0x %lu %lu %lu\n", gen->type, now, - gen->id, new_gen); -#endif - filegen_open(gen, new_gen); + if (NULL == gen->fp || !current) { + DPRINTF(1, ("filegen %0x %u\n", gen->type, now)); + pivot = time(NULL); + filegen_open(gen, now, &pivot); } } @@ -370,41 +402,59 @@ filegen_setup( */ void filegen_config( - FILEGEN *gen, - char *basename, - u_int type, - u_int flag + FILEGEN * gen, + const char * dir, + const char * fname, + u_int type, + u_int flag ) { + int file_existed; + l_fp now; + + /* * if nothing would be changed... */ - if ((basename == gen->basename || strcmp(basename,gen->basename) == 0) && - type == gen->type && - flag == gen->flag) - return; - + if (strcmp(dir, gen->dir) == 0 && strcmp(fname, gen->fname) == 0 + && type == gen->type && flag == gen->flag) + return; + /* * validate parameters */ - if (!valid_fileref(gen->prefix,basename)) - return; + if (!valid_fileref(dir, fname)) + return; - if (gen->fp != NULL) - fclose(gen->fp); + if (NULL != gen->fp) { + fclose(gen->fp); + gen->fp = NULL; + file_existed = TRUE; + } else { + file_existed = FALSE; + } -#ifdef DEBUG - if (debug > 2) - printf("configuring filegen:\n\tprefix:\t%s\n\tbasename:\t%s -> %s\n\ttype:\t%d -> %d\n\tflag: %x -> %x\n", - gen->prefix, gen->basename, basename, gen->type, type, gen->flag, flag); -#endif - if (gen->basename != basename || strcmp(gen->basename, basename) != 0) { - free(gen->basename); - gen->basename = (char*)emalloc(strlen(basename) + 1); - strcpy(gen->basename, basename); + DPRINTF(3, ("configuring filegen:\n" + "\tdir:\t%s -> %s\n" + "\tfname:\t%s -> %s\n" + "\ttype:\t%d -> %d\n" + "\tflag: %x -> %x\n", + gen->dir, dir, + gen->fname, fname, + gen->type, type, + gen->flag, flag)); + + if (strcmp(gen->dir, dir) != 0) { + free(gen->dir); + gen->dir = estrdup(dir); + } + + if (strcmp(gen->fname, fname) != 0) { + free(gen->fname); + gen->fname = estrdup(fname); } - gen->type = (u_char) type; - gen->flag = (u_char) flag; + gen->type = (u_char)type; + gen->flag = (u_char)flag; /* * make filegen use the new settings @@ -412,9 +462,7 @@ filegen_config( * is currently open * otherwise the new settings will be used anyway at the next open */ - if (gen->fp != NULL) { - l_fp now; - + if (file_existed) { get_systime(&now); filegen_setup(gen, now.l_ui); } @@ -427,40 +475,54 @@ filegen_config( */ static int valid_fileref( - char *prefix, - char *basename + const char * dir, + const char * fname ) { /* - * prefix cannot be changed dynamically + * dir cannot be changed dynamically * (within the context of filegen) * so just reject basenames containing '..' * * ASSUMPTION: - * file system parts 'below' prefix may be + * file system parts 'below' dir may be * specified without infringement of security * - * restricing prefix to legal values + * restricting dir to legal values * has to be ensured by other means * (however, it would be possible to perform some checks here...) */ - register char *p = basename; - + const char *p; + /* * Just to catch, dumb errors opening up the world... */ - if (prefix == NULL || *prefix == '\0') - return 0; + if (NULL == dir || '\0' == dir[0]) + return FALSE; - if (basename == NULL) - return 0; - - for (p = basename; p; p = strchr(p, '/')) { - if (*p == '.' && *(p+1) == '.' && (*(p+2) == '\0' || *(p+2) == '/')) - return 0; + if (NULL == fname) + return FALSE; + +#ifdef SYS_WINNT + /* + * Windows treats / equivalent to \, reject any / to ensure + * check below for DIR_SEP (\ on windows) are adequate. + */ + if (strchr(fname, '/')) { + msyslog(LOG_ERR, + "filegen filenames must not contain '/': %s", + fname); + return FALSE; } - - return 1; +#endif + + for (p = fname; p != NULL; p = strchr(p, DIR_SEP)) { + if ('.' == p[0] && '.' == p[1] + && ('\0' == p[2] || DIR_SEP == p[2])) + return FALSE; + } + + return TRUE; } @@ -469,108 +531,115 @@ valid_fileref( */ static struct filegen_entry { - char *name; - FILEGEN *filegen; - struct filegen_entry *next; + char * name; + FILEGEN * filegen; + struct filegen_entry * next; } *filegen_registry = NULL; FILEGEN * filegen_get( - char *name + const char * name ) { struct filegen_entry *f = filegen_registry; - while(f) { + while (f) { if (f->name == name || strcmp(name, f->name) == 0) { -#ifdef XXX /* this gives the Alpha compiler fits */ - if (debug > 3) - printf("filegen_get(\"%s\") = %x\n", name, - (u_int)f->filegen); -#endif + DPRINTF(4, ("filegen_get(%s) = %p\n", + name, f->filegen)); return f->filegen; } f = f->next; } -#ifdef DEBUG - if (debug > 3) - printf("filegen_get(\"%s\") = NULL\n", name); -#endif + DPRINTF(4, ("filegen_get(%s) = NULL\n", name)); return NULL; } + void filegen_register( - char *prefix, - const char *name, - FILEGEN *filegen + const char * dir, + const char * name, + FILEGEN * filegen ) { - struct filegen_entry **f = &filegen_registry; + struct filegen_entry **ppfe; -#ifdef XXX /* this gives the Alpha compiler fits */ - if (debug > 3) - printf("filegen_register(\"%s\",%x)\n", name, (u_int)filegen); -#endif + DPRINTF(4, ("filegen_register(%s, %p)\n", name, filegen)); - filegen_init(prefix, name, filegen); + filegen_init(dir, name, filegen); - while (*f) { - if ((*f)->name == name || strcmp(name, (*f)->name) == 0) { -#ifdef XXX /* this gives the Alpha compiler fits */ - if (debug > 4) { - printf("replacing filegen %x\n", (u_int)(*f)->filegen); - } -#endif - (*f)->filegen = filegen; + ppfe = &filegen_registry; + while (NULL != *ppfe) { + if ((*ppfe)->name == name + || !strcmp((*ppfe)->name, name)) { + + DPRINTF(5, ("replacing filegen %p\n", + (*ppfe)->filegen)); + + (*ppfe)->filegen = filegen; return; } - f = &((*f)->next); + ppfe = &((*ppfe)->next); } - *f = (struct filegen_entry *) emalloc(sizeof(struct filegen_entry)); - if (*f) { - (*f)->next = NULL; - (*f)->name = (char*)emalloc(strlen(name) + 1); - strcpy((*f)->name, name); - (*f)->filegen = filegen; -#ifdef DEBUG - if (debug > 5) { - printf("adding new filegen\n"); - } -#endif - } + *ppfe = emalloc(sizeof **ppfe); + + (*ppfe)->next = NULL; + (*ppfe)->name = estrdup(name); + (*ppfe)->filegen = filegen; + + DPRINTF(6, ("adding new filegen\n")); return; } -#ifdef UNUSED -static FILEGEN * + +/* + * filegen_statsdir() - reset each filegen entry's dir to statsdir. + */ +void +filegen_statsdir(void) +{ + struct filegen_entry *f; + + for (f = filegen_registry; f != NULL; f = f->next) + filegen_config(f->filegen, statsdir, f->filegen->fname, + f->filegen->type, f->filegen->flag); +} + + +/* + * filegen_unregister frees memory allocated by filegen_register for + * name. + */ +#ifdef DEBUG +void filegen_unregister( - char *name + const char *name ) { - struct filegen_entry **f = &filegen_registry; - -#ifdef DEBUG - if (debug > 3) - printf("filegen_unregister(\"%s\")\n", name); -#endif - - while (*f) { - if (strcmp((*f)->name,name) == 0) { - struct filegen_entry *ff = *f; - FILEGEN *fg; + struct filegen_entry ** ppfe; + struct filegen_entry * pfe; + FILEGEN * fg; - *f = (*f)->next; - fg = ff->filegen; - free(ff->name); - free(ff); - return fg; + DPRINTF(4, ("filegen_unregister(%s)\n", name)); + + ppfe = &filegen_registry; + + while (NULL != *ppfe) { + if ((*ppfe)->name == name + || !strcmp((*ppfe)->name, name)) { + pfe = *ppfe; + *ppfe = (*ppfe)->next; + fg = pfe->filegen; + free(pfe->name); + free(pfe); + filegen_uninit(fg); + break; } - f = &((*f)->next); + ppfe = &((*ppfe)->next); } - return NULL; } -#endif /* UNUSED */ +#endif /* DEBUG */ diff --git a/contrib/ntp/ntpd/ntp_intres.c b/contrib/ntp/ntpd/ntp_intres.c deleted file mode 100644 index e18888f4d..000000000 --- a/contrib/ntp/ntpd/ntp_intres.c +++ /dev/null @@ -1,1185 +0,0 @@ -/* - * ripped off from ../ntpres/ntpres.c by Greg Troxel 4/2/92 - * routine callable from ntpd, rather than separate program - * also, key info passed in via a global, so no key file needed. - */ - -/* - * ntpres - process configuration entries which require use of the resolver - * - * This is meant to be run by ntpd on the fly. It is not guaranteed - * to work properly if run by hand. This is actually a quick hack to - * stave off violence from people who hate using numbers in the - * configuration file (at least I hope the rest of the daemon is - * better than this). Also might provide some ideas about how one - * might go about autoconfiguring an NTP distribution network. - * - */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "ntp_machine.h" -#include "ntpd.h" -#include "ntp_io.h" -#include "ntp_request.h" -#include "ntp_stdlib.h" -#include "ntp_syslog.h" - -#include -#include -#include -#include - -/**/ -#include -#include -/**/ -#ifdef HAVE_SYS_PARAM_H -# include /* MAXHOSTNAMELEN (often) */ -#endif - -#include -#include - -#define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) - -/* - * Each item we are to resolve and configure gets one of these - * structures defined for it. - */ -struct conf_entry { - struct conf_entry *ce_next; - char *ce_name; /* name we are trying to resolve */ - struct conf_peer ce_config; /* configuration info for peer */ - struct sockaddr_storage peer_store; /* address info for both fams */ -}; -#define ce_peeraddr ce_config.peeraddr -#define ce_peeraddr6 ce_config.peeraddr6 -#define ce_hmode ce_config.hmode -#define ce_version ce_config.version -#define ce_minpoll ce_config.minpoll -#define ce_maxpoll ce_config.maxpoll -#define ce_flags ce_config.flags -#define ce_ttl ce_config.ttl -#define ce_keyid ce_config.keyid -#define ce_keystr ce_config.keystr - -/* - * confentries is a pointer to the list of configuration entries - * we have left to do. - */ -static struct conf_entry *confentries = NULL; - -/* - * We take an interrupt every thirty seconds, at which time we decrement - * config_timer and resolve_timer. The former is set to 2, so we retry - * unsucessful reconfigurations every minute. The latter is set to - * an exponentially increasing value which starts at 2 and increases to - * 32. When this expires we retry failed name resolutions. - * - * We sleep SLEEPTIME seconds before doing anything, to give the server - * time to arrange itself. - */ -#define MINRESOLVE 2 -#define MAXRESOLVE 32 -#define CONFIG_TIME 2 -#define ALARM_TIME 30 -#define SLEEPTIME 2 - -static volatile int config_timer = 0; -static volatile int resolve_timer = 0; - -static int resolve_value; /* next value of resolve timer */ - -/* - * Big hack attack - */ -#define LOCALHOST 0x7f000001 /* 127.0.0.1, in hex, of course */ -#define SKEWTIME 0x08000000 /* 0.03125 seconds as a l_fp fraction */ - -/* - * Select time out. Set to 2 seconds. The server is on the local machine, - * after all. - */ -#define TIMEOUT_SEC 2 -#define TIMEOUT_USEC 0 - - -/* - * Input processing. The data on each line in the configuration file - * is supposed to consist of entries in the following order - */ -#define TOK_HOSTNAME 0 -#define TOK_PEERAF 1 -#define TOK_HMODE 2 -#define TOK_VERSION 3 -#define TOK_MINPOLL 4 -#define TOK_MAXPOLL 5 -#define TOK_FLAGS 6 -#define TOK_TTL 7 -#define TOK_KEYID 8 -#define TOK_KEYSTR 9 -#define NUMTOK 10 - -#define MAXLINESIZE 512 - - -/* - * File descriptor for ntp request code. - */ -static SOCKET sockfd = INVALID_SOCKET; /* NT uses SOCKET */ - -/* stuff to be filled in by caller */ - -keyid_t req_keyid; /* request keyid */ -char *req_file; /* name of the file with configuration info */ - -/* end stuff to be filled in */ - - -static void checkparent P((void)); -static void removeentry P((struct conf_entry *)); -static void addentry P((char *, int, int, int, int, u_int, - int, keyid_t, char *, u_char)); -static int findhostaddr P((struct conf_entry *)); -static void openntp P((void)); -static int request P((struct conf_peer *)); -static char * nexttoken P((char **)); -static void readconf P((FILE *, char *)); -static void doconfigure P((int)); - -struct ntp_res_t_pkt { /* Tagged packet: */ - void *tag; /* For the caller */ - u_int32 paddr; /* IP to look up, or 0 */ - char name[MAXHOSTNAMELEN]; /* Name to look up (if 1st byte is not 0) */ -}; - -struct ntp_res_c_pkt { /* Control packet: */ - char name[MAXHOSTNAMELEN]; - u_int32 paddr; - int mode; - int version; - int minpoll; - int maxpoll; - u_int flags; - int ttl; - keyid_t keyid; - u_char keystr[MAXFILENAME]; -}; - - -static void resolver_exit P((int)); - -/* - * Call here instead of just exiting - */ - -static void resolver_exit (int code) -{ -#ifdef SYS_WINNT - CloseHandle(ResolverEventHandle); - ResolverEventHandle = NULL; - ExitThread(code); /* Just to kill the thread not the process */ -#else - exit(code); /* kill the forked process */ -#endif -} - -/* - * ntp_res_recv: Process an answer from the resolver - */ - -void -ntp_res_recv(void) -{ - /* - We have data ready on our descriptor. - It may be an EOF, meaning the resolver process went away. - Otherwise, it will be an "answer". - */ -} - - -/* - * ntp_intres needs; - * - * req_key(???), req_keyid, req_file valid - * syslog still open - */ - -void -ntp_intres(void) -{ - FILE *in; - struct timeval tv; - fd_set fdset; -#ifdef SYS_WINNT - DWORD rc; -#else - int rc; -#endif - -#ifdef DEBUG - if (debug > 1) { - msyslog(LOG_INFO, "NTP_INTRES running"); - } -#endif - - /* check out auth stuff */ - if (sys_authenticate) { - if (!authistrusted(req_keyid)) { - msyslog(LOG_ERR, "invalid request keyid %08x", - req_keyid ); - resolver_exit(1); - } - } - - /* - * Read the configuration info - * {this is bogus, since we are forked, but it is easier - * to keep this code - gdt} - */ - if ((in = fopen(req_file, "r")) == NULL) { - msyslog(LOG_ERR, "can't open configuration file %s: %m", - req_file); - resolver_exit(1); - } - readconf(in, req_file); - (void) fclose(in); - -#ifdef DEBUG - if (!debug ) -#endif - (void) unlink(req_file); - - /* - * Set up the timers to do first shot immediately. - */ - resolve_timer = 0; - resolve_value = MINRESOLVE; - config_timer = CONFIG_TIME; - - for (;;) { - checkparent(); - - if (resolve_timer == 0) { - /* - * Sleep a little to make sure the network is completely up - */ - sleep(SLEEPTIME); - doconfigure(1); - - /* prepare retry, in case there's more work to do */ - resolve_timer = resolve_value; -#ifdef DEBUG - if (debug > 2) - msyslog(LOG_INFO, "resolve_timer: 0->%d", resolve_timer); -#endif - if (resolve_value < MAXRESOLVE) - resolve_value <<= 1; - - config_timer = CONFIG_TIME; - } else if (config_timer == 0) { /* MB: in which case would this be required ? */ - doconfigure(0); - /* MB: should we check now if we could exit, similar to the code above? */ - config_timer = CONFIG_TIME; -#ifdef DEBUG - if (debug > 2) - msyslog(LOG_INFO, "config_timer: 0->%d", config_timer); -#endif - } - - if (confentries == NULL) - resolver_exit(0); /* done */ - -#ifdef SYS_WINNT - rc = WaitForSingleObject(ResolverEventHandle, 1000 * ALARM_TIME); /* in milliseconds */ - - if ( rc == WAIT_OBJECT_0 ) { /* signaled by the main thread */ - resolve_timer = 0; /* retry resolving immediately */ - continue; - } - - if ( rc != WAIT_TIMEOUT ) /* not timeout: error */ - resolver_exit(1); - -#else /* not SYS_WINNT */ - tv.tv_sec = ALARM_TIME; - tv.tv_usec = 0; - FD_ZERO(&fdset); - FD_SET(resolver_pipe_fd[0], &fdset); - rc = select(resolver_pipe_fd[0] + 1, &fdset, (fd_set *)0, (fd_set *)0, &tv); - - if (rc > 0) { /* parent process has written to the pipe */ - read(resolver_pipe_fd[0], (char *)&rc, sizeof(rc)); /* make pipe empty */ - resolve_timer = 0; /* retry resolving immediately */ - continue; - } - - if ( rc < 0 ) /* select() returned error */ - resolver_exit(1); -#endif - - /* normal timeout, keep on waiting */ - if (config_timer > 0) - config_timer--; - if (resolve_timer > 0) - resolve_timer--; - } -} - - - -/* - * checkparent - see if our parent process is still running - * - * No need to worry in the Windows NT environment whether the - * main thread is still running, because if it goes - * down it takes the whole process down with it (in - * which case we won't be running this thread either) - * Turn function into NOP; - */ - -static void -checkparent(void) -{ -#if !defined (SYS_WINNT) && !defined (SYS_VXWORKS) - - /* - * If our parent (the server) has died we will have been - * inherited by init. If so, exit. - */ - if (getppid() == 1) { - msyslog(LOG_INFO, "parent died before we finished, exiting"); - resolver_exit(0); - } -#endif /* SYS_WINNT && SYS_VXWORKS*/ -} - - - -/* - * removeentry - we are done with an entry, remove it from the list - */ -static void -removeentry( - struct conf_entry *entry - ) -{ - register struct conf_entry *ce; - - ce = confentries; - if (ce == entry) { - confentries = ce->ce_next; - return; - } - - while (ce != NULL) { - if (ce->ce_next == entry) { - ce->ce_next = entry->ce_next; - return; - } - ce = ce->ce_next; - } -} - - -/* - * addentry - add an entry to the configuration list - */ -static void -addentry( - char *name, - int mode, - int version, - int minpoll, - int maxpoll, - u_int flags, - int ttl, - keyid_t keyid, - char *keystr, - u_char peeraf - ) -{ - register char *cp; - register struct conf_entry *ce; - unsigned int len; - -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, - "intres: <%s> %u %d %d %d %d %x %d %x %s\n", name, peeraf, - mode, version, minpoll, maxpoll, flags, ttl, keyid, - keystr); -#endif - len = strlen(name) + 1; - cp = (char *)emalloc(len); - memmove(cp, name, len); - - ce = (struct conf_entry *)emalloc(sizeof(struct conf_entry)); - ce->ce_name = cp; - ce->ce_peeraddr = 0; -#ifdef ISC_PLATFORM_HAVEIPV6 - ce->ce_peeraddr6 = in6addr_any; -#endif - ANYSOCK(&ce->peer_store); - ce->peer_store.ss_family = peeraf; /* Save AF for getaddrinfo hints. */ - ce->ce_hmode = (u_char)mode; - ce->ce_version = (u_char)version; - ce->ce_minpoll = (u_char)minpoll; - ce->ce_maxpoll = (u_char)maxpoll; - ce->ce_flags = (u_char)flags; - ce->ce_ttl = (u_char)ttl; - ce->ce_keyid = keyid; - strncpy((char *)ce->ce_keystr, keystr, MAXFILENAME); - ce->ce_next = NULL; - - if (confentries == NULL) { - confentries = ce; - } else { - register struct conf_entry *cep; - - for (cep = confentries; cep->ce_next != NULL; - cep = cep->ce_next) - /* nothing */; - cep->ce_next = ce; - } -} - - -/* - * findhostaddr - resolve a host name into an address (Or vice-versa) - * - * Given one of {ce_peeraddr,ce_name}, find the other one. - * It returns 1 for "success" and 0 for an uncorrectable failure. - * Note that "success" includes try again errors. You can tell that you - * got a "try again" since {ce_peeraddr,ce_name} will still be zero. - */ -static int -findhostaddr( - struct conf_entry *entry - ) -{ - static int eai_again_seen = 0; - struct addrinfo *addr; - struct addrinfo hints; - int again; - int error; - - checkparent(); /* make sure our guy is still running */ - - if (entry->ce_name != NULL && !SOCKNUL(&entry->peer_store)) { - /* HMS: Squawk? */ - msyslog(LOG_ERR, "findhostaddr: both ce_name and ce_peeraddr are defined..."); - return 1; - } - - if (entry->ce_name == NULL && SOCKNUL(&entry->peer_store)) { - msyslog(LOG_ERR, "findhostaddr: both ce_name and ce_peeraddr are undefined!"); - return 0; - } - - if (entry->ce_name) { - DPRINTF(2, ("findhostaddr: Resolving <%s>\n", - entry->ce_name)); - - memset(&hints, 0, sizeof(hints)); - hints.ai_family = entry->peer_store.ss_family; - hints.ai_socktype = SOCK_DGRAM; - /* - * If the IPv6 stack is not available look only for IPv4 addresses - */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) - hints.ai_family = AF_INET; - - error = getaddrinfo(entry->ce_name, NULL, &hints, &addr); - if (error == 0) { - entry->peer_store = *((struct sockaddr_storage*)(addr->ai_addr)); - if (entry->peer_store.ss_family == AF_INET) { - entry->ce_peeraddr = - GET_INADDR(entry->peer_store); - entry->ce_config.v6_flag = 0; - } else { - entry->ce_peeraddr6 = - GET_INADDR6(entry->peer_store); - entry->ce_config.v6_flag = 1; - } - } - } else { - DPRINTF(2, ("findhostaddr: Resolving <%s>\n", - stoa(&entry->peer_store))); - - entry->ce_name = emalloc(MAXHOSTNAMELEN); - error = getnameinfo((const struct sockaddr *)&entry->peer_store, - SOCKLEN(&entry->peer_store), - (char *)&entry->ce_name, MAXHOSTNAMELEN, - NULL, 0, 0); - } - - if (0 == error) { - - /* again is our return value, for success it is 1 */ - again = 1; - - DPRINTF(2, ("findhostaddr: %s resolved.\n", - (entry->ce_name) ? "name" : "address")); - } else { - /* - * If the resolver failed, see if the failure is - * temporary. If so, return success. - */ - again = 0; - - switch (error) { - - case EAI_FAIL: - again = 1; - break; - - case EAI_AGAIN: - again = 1; - eai_again_seen = 1; - break; - - case EAI_NONAME: -#if defined(EAI_NODATA) && (EAI_NODATA != EAI_NONAME) - case EAI_NODATA: -#endif - msyslog(LOG_ERR, "host name not found%s%s: %s", - (EAI_NONAME == error) ? "" : " EAI_NODATA", - (eai_again_seen) ? " (permanent)" : "", - entry->ce_name); - again = !eai_again_seen; - break; - -#ifdef EAI_SYSTEM - case EAI_SYSTEM: - /* - * EAI_SYSTEM means the real error is in errno. We should be more - * discriminating about which errno values require retrying, but - * this matches existing behavior. - */ - again = 1; - DPRINTF(1, ("intres: EAI_SYSTEM errno %d (%s) means try again, right?\n", - errno, strerror(errno))); - break; -#endif - } - - /* do this here to avoid perturbing errno earlier */ - DPRINTF(2, ("intres: got error status of: %d\n", error)); - } - - return again; -} - - -/* - * openntp - open a socket to the ntp server - */ -static void -openntp(void) -{ - const char *localhost = "127.0.0.1"; /* Use IPv4 loopback */ - struct addrinfo hints; - struct addrinfo *addr; - u_long on; - int err; - - if (sockfd != INVALID_SOCKET) - return; - - memset(&hints, 0, sizeof(hints)); - - /* - * For now only bother with IPv4 - */ - hints.ai_family = AF_INET; - hints.ai_socktype = SOCK_DGRAM; - - err = getaddrinfo(localhost, "ntp", &hints, &addr); - - if (err) { -#ifdef EAI_SYSTEM - if (EAI_SYSTEM == err) - msyslog(LOG_ERR, "getaddrinfo(%s) failed: %m", - localhost); - else -#endif - msyslog(LOG_ERR, "getaddrinfo(%s) failed: %s", - localhost, gai_strerror(err)); - resolver_exit(1); - } - - sockfd = socket(addr->ai_family, addr->ai_socktype, 0); - - if (INVALID_SOCKET == sockfd) { - msyslog(LOG_ERR, "socket() failed: %m"); - resolver_exit(1); - } - -#ifndef SYS_WINNT - /* - * On Windows only the count of sockets must be less than - * FD_SETSIZE. On Unix each descriptor's value must be less - * than FD_SETSIZE, as fd_set is a bit array. - */ - if (sockfd >= FD_SETSIZE) { - msyslog(LOG_ERR, "socket fd %d too large, FD_SETSIZE %d", - (int)sockfd, FD_SETSIZE); - resolver_exit(1); - } - - /* - * Make the socket non-blocking. We'll wait with select() - * Unix: fcntl(O_NONBLOCK) or fcntl(FNDELAY) - */ -# ifdef O_NONBLOCK - if (fcntl(sockfd, F_SETFL, O_NONBLOCK) == -1) { - msyslog(LOG_ERR, "fcntl(O_NONBLOCK) failed: %m"); - resolver_exit(1); - } -# else -# ifdef FNDELAY - if (fcntl(sockfd, F_SETFL, FNDELAY) == -1) { - msyslog(LOG_ERR, "fcntl(FNDELAY) failed: %m"); - resolver_exit(1); - } -# else -# include "Bletch: NEED NON BLOCKING IO" -# endif /* FNDDELAY */ -# endif /* O_NONBLOCK */ - (void)on; /* quiet unused warning */ -#else /* !SYS_WINNT above */ - /* - * Make the socket non-blocking. We'll wait with select() - * Windows: ioctlsocket(FIONBIO) - */ - on = 1; - err = ioctlsocket(sockfd, FIONBIO, &on); - if (SOCKET_ERROR == err) { - msyslog(LOG_ERR, "ioctlsocket(FIONBIO) fails: %m"); - resolver_exit(1); - } -#endif /* SYS_WINNT */ - - err = connect(sockfd, addr->ai_addr, addr->ai_addrlen); - if (SOCKET_ERROR == err) { - msyslog(LOG_ERR, "openntp: connect() failed: %m"); - resolver_exit(1); - } - - freeaddrinfo(addr); -} - - -/* - * request - send a configuration request to the server, wait for a response - */ -static int -request( - struct conf_peer *conf - ) -{ - fd_set fdset; - struct timeval tvout; - struct req_pkt reqpkt; - l_fp ts; - int n; -#ifdef SYS_WINNT - HANDLE hReadWriteEvent = NULL; - BOOL ret; - DWORD NumberOfBytesWritten, NumberOfBytesRead, dwWait; - OVERLAPPED overlap; -#endif /* SYS_WINNT */ - - checkparent(); /* make sure our guy is still running */ - - if (sockfd == INVALID_SOCKET) - openntp(); - -#ifdef SYS_WINNT - hReadWriteEvent = CreateEvent(NULL, FALSE, FALSE, NULL); -#endif /* SYS_WINNT */ - - /* - * Try to clear out any previously received traffic so it - * doesn't fool us. Note the socket is nonblocking. - */ - tvout.tv_sec = 0; - tvout.tv_usec = 0; - FD_ZERO(&fdset); - FD_SET(sockfd, &fdset); - while (select(sockfd + 1, &fdset, (fd_set *)0, (fd_set *)0, &tvout) > - 0) { - recv(sockfd, (char *)&reqpkt, REQ_LEN_MAC, 0); - FD_ZERO(&fdset); - FD_SET(sockfd, &fdset); - } - - /* - * Make up a request packet with the configuration info - */ - memset((char *)&reqpkt, 0, sizeof(reqpkt)); - - reqpkt.rm_vn_mode = RM_VN_MODE(0, 0, 0); - reqpkt.auth_seq = AUTH_SEQ(1, 0); /* authenticated, no seq */ - reqpkt.implementation = IMPL_XNTPD; /* local implementation */ - reqpkt.request = REQ_CONFIG; /* configure a new peer */ - reqpkt.err_nitems = ERR_NITEMS(0, 1); /* one item */ - reqpkt.mbz_itemsize = MBZ_ITEMSIZE(sizeof(struct conf_peer)); - /* Make sure mbz_itemsize <= sizeof reqpkt.data */ - if (sizeof(struct conf_peer) > sizeof (reqpkt.data)) { - msyslog(LOG_ERR, "Bletch: conf_peer is too big for reqpkt.data!"); - resolver_exit(1); - } - memmove(reqpkt.data, (char *)conf, sizeof(struct conf_peer)); - reqpkt.keyid = htonl(req_keyid); - - get_systime(&ts); - L_ADDUF(&ts, SKEWTIME); - HTONL_FP(&ts, &reqpkt.tstamp); - n = 0; - if (sys_authenticate) - n = authencrypt(req_keyid, (u_int32 *)&reqpkt, REQ_LEN_NOMAC); - - /* - * Done. Send it. - */ -#ifndef SYS_WINNT - n = send(sockfd, (char *)&reqpkt, (unsigned)(REQ_LEN_NOMAC + n), 0); - if (n < 0) { - msyslog(LOG_ERR, "send to NTP server failed: %m"); - return 0; /* maybe should exit */ - } -#else - /* In the NT world, documentation seems to indicate that there - * exist _write and _read routines that can be used to do blocking - * I/O on sockets. Problem is these routines require a socket - * handle obtained through the _open_osf_handle C run-time API - * of which there is no explanation in the documentation. We need - * nonblocking write's and read's anyway for our purpose here. - * We're therefore forced to deviate a little bit from the Unix - * model here and use the ReadFile and WriteFile Win32 I/O API's - * on the socket - */ - overlap.Offset = overlap.OffsetHigh = (DWORD)0; - overlap.hEvent = hReadWriteEvent; - ret = WriteFile((HANDLE)sockfd, (char *)&reqpkt, REQ_LEN_NOMAC + n, - NULL, (LPOVERLAPPED)&overlap); - if ((ret == FALSE) && (GetLastError() != ERROR_IO_PENDING)) { - msyslog(LOG_ERR, "send to NTP server failed: %m"); - return 0; - } - dwWait = WaitForSingleObject(hReadWriteEvent, (DWORD) TIMEOUT_SEC * 1000); - if ((dwWait == WAIT_FAILED) || (dwWait == WAIT_TIMEOUT)) { - if (dwWait == WAIT_FAILED) - msyslog(LOG_ERR, "WaitForSingleObject failed: %m"); - return 0; - } - if (!GetOverlappedResult((HANDLE)sockfd, (LPOVERLAPPED)&overlap, - (LPDWORD)&NumberOfBytesWritten, FALSE)) { - msyslog(LOG_ERR, "GetOverlappedResult for WriteFile fails: %m"); - return 0; - } -#endif /* SYS_WINNT */ - - - /* - * Wait for a response. A weakness of the mode 7 protocol used - * is that there is no way to associate a response with a - * particular request, i.e. the response to this configuration - * request is indistinguishable from that to any other. I should - * fix this some day. In any event, the time out is fairly - * pessimistic to make sure that if an answer is coming back - * at all, we get it. - */ - for (;;) { - FD_ZERO(&fdset); - FD_SET(sockfd, &fdset); - tvout.tv_sec = TIMEOUT_SEC; - tvout.tv_usec = TIMEOUT_USEC; - - n = select(sockfd + 1, &fdset, (fd_set *)0, - (fd_set *)0, &tvout); - - if (n < 0) - { - if (errno != EINTR) - msyslog(LOG_ERR, "select() fails: %m"); - return 0; - } - else if (n == 0) - { -#ifdef DEBUG - if (debug) - msyslog(LOG_INFO, "select() returned 0."); -#endif - return 0; - } - -#ifndef SYS_WINNT - n = recv(sockfd, (char *)&reqpkt, REQ_LEN_MAC, 0); - if (n <= 0) { - if (n < 0) { - msyslog(LOG_ERR, "recv() fails: %m"); - return 0; - } - continue; - } -#else /* Overlapped I/O used on non-blocking sockets on Windows NT */ - ret = ReadFile((HANDLE)sockfd, (char *)&reqpkt, (DWORD)REQ_LEN_MAC, - NULL, (LPOVERLAPPED)&overlap); - if ((ret == FALSE) && (GetLastError() != ERROR_IO_PENDING)) { - msyslog(LOG_ERR, "ReadFile() fails: %m"); - return 0; - } - dwWait = WaitForSingleObject(hReadWriteEvent, (DWORD) TIMEOUT_SEC * 1000); - if ((dwWait == WAIT_FAILED) || (dwWait == WAIT_TIMEOUT)) { - if (dwWait == WAIT_FAILED) { - msyslog(LOG_ERR, "WaitForSingleObject for ReadFile fails: %m"); - return 0; - } - continue; - } - if (!GetOverlappedResult((HANDLE)sockfd, (LPOVERLAPPED)&overlap, - (LPDWORD)&NumberOfBytesRead, FALSE)) { - msyslog(LOG_ERR, "GetOverlappedResult fails: %m"); - return 0; - } - n = NumberOfBytesRead; -#endif /* SYS_WINNT */ - - /* - * Got one. Check through to make sure it is what - * we expect. - */ - if (n < RESP_HEADER_SIZE) { - msyslog(LOG_ERR, "received runt response (%d octets)", - n); - continue; - } - - if (!ISRESPONSE(reqpkt.rm_vn_mode)) { -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, "received non-response packet"); -#endif - continue; - } - - if (ISMORE(reqpkt.rm_vn_mode)) { -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, "received fragmented packet"); -#endif - continue; - } - - if ( ( (INFO_VERSION(reqpkt.rm_vn_mode) < 2) - || (INFO_VERSION(reqpkt.rm_vn_mode) > NTP_VERSION)) - || INFO_MODE(reqpkt.rm_vn_mode) != MODE_PRIVATE) { -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, - "version (%d/%d) or mode (%d/%d) incorrect", - INFO_VERSION(reqpkt.rm_vn_mode), - NTP_VERSION, - INFO_MODE(reqpkt.rm_vn_mode), - MODE_PRIVATE); -#endif - continue; - } - - if (INFO_SEQ(reqpkt.auth_seq) != 0) { -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, - "nonzero sequence number (%d)", - INFO_SEQ(reqpkt.auth_seq)); -#endif - continue; - } - - if (reqpkt.implementation != IMPL_XNTPD || - reqpkt.request != REQ_CONFIG) { -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, - "implementation (%d) or request (%d) incorrect", - reqpkt.implementation, reqpkt.request); -#endif - continue; - } - - if (INFO_NITEMS(reqpkt.err_nitems) != 0 || - INFO_MBZ(reqpkt.mbz_itemsize) != 0 || - INFO_ITEMSIZE(reqpkt.mbz_itemsize) != 0) { -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, - "nitems (%d) mbz (%d) or itemsize (%d) nonzero", - INFO_NITEMS(reqpkt.err_nitems), - INFO_MBZ(reqpkt.mbz_itemsize), - INFO_ITEMSIZE(reqpkt.mbz_itemsize)); -#endif - continue; - } - - n = INFO_ERR(reqpkt.err_nitems); - switch (n) { - case INFO_OKAY: - /* success */ - return 1; - - case INFO_ERR_IMPL: - msyslog(LOG_ERR, - "ntpd reports implementation mismatch!"); - return 0; - - case INFO_ERR_REQ: - msyslog(LOG_ERR, - "ntpd says configuration request is unknown!"); - return 0; - - case INFO_ERR_FMT: - msyslog(LOG_ERR, - "ntpd indicates a format error occurred!"); - return 0; - - case INFO_ERR_NODATA: - msyslog(LOG_ERR, - "ntpd indicates no data available!"); - return 0; - - case INFO_ERR_AUTH: - msyslog(LOG_ERR, - "ntpd returns a permission denied error!"); - return 0; - - default: - msyslog(LOG_ERR, - "ntpd returns unknown error code %d!", n); - return 0; - } - } -} - - -/* - * nexttoken - return the next token from a line - */ -static char * -nexttoken( - char **lptr - ) -{ - register char *cp; - register char *tstart; - - cp = *lptr; - - /* - * Skip leading white space - */ - while (*cp == ' ' || *cp == '\t') - cp++; - - /* - * If this is the end of the line, return nothing. - */ - if (*cp == '\n' || *cp == '\0') { - *lptr = cp; - return NULL; - } - - /* - * Must be the start of a token. Record the pointer and look - * for the end. - */ - tstart = cp++; - while (*cp != ' ' && *cp != '\t' && *cp != '\n' && *cp != '\0') - cp++; - - /* - * Terminate the token with a \0. If this isn't the end of the - * line, space to the next character. - */ - if (*cp == '\n' || *cp == '\0') - *cp = '\0'; - else - *cp++ = '\0'; - - *lptr = cp; - return tstart; -} - - -/* - * readconf - read the configuration information out of the file we - * were passed. Note that since the file is supposed to be - * machine generated, we bail out at the first sign of trouble. - */ -static void -readconf( - FILE *fp, - char *name - ) -{ - register int i; - char *token[NUMTOK]; - u_long intval[NUMTOK]; - u_int flags; - char buf[MAXLINESIZE]; - char *bp; - - while (fgets(buf, MAXLINESIZE, fp) != NULL) { - - bp = buf; - for (i = 0; i < NUMTOK; i++) { - if ((token[i] = nexttoken(&bp)) == NULL) { - msyslog(LOG_ERR, - "tokenizing error in file `%s', quitting", - name); - resolver_exit(1); - } - } - - for (i = 1; i < NUMTOK - 1; i++) { - if (!atouint(token[i], &intval[i])) { - msyslog(LOG_ERR, - "format error for integer token `%s', file `%s', quitting", - token[i], name); - resolver_exit(1); - } - } - - if (intval[TOK_PEERAF] != AF_UNSPEC && intval[TOK_PEERAF] != - AF_INET && intval[TOK_PEERAF] != AF_INET6) { - msyslog(LOG_ERR, "invalid peer address family (%u) in " - "file %s", intval[TOK_PEERAF], name); - exit(1); - } - - if (intval[TOK_HMODE] != MODE_ACTIVE && - intval[TOK_HMODE] != MODE_CLIENT && - intval[TOK_HMODE] != MODE_BROADCAST) { - msyslog(LOG_ERR, "invalid mode (%ld) in file %s", - intval[TOK_HMODE], name); - resolver_exit(1); - } - - if (intval[TOK_VERSION] > NTP_VERSION || - intval[TOK_VERSION] < NTP_OLDVERSION) { - msyslog(LOG_ERR, "invalid version (%ld) in file %s", - intval[TOK_VERSION], name); - resolver_exit(1); - } - if (intval[TOK_MINPOLL] < NTP_MINPOLL || - intval[TOK_MINPOLL] > NTP_MAXPOLL) { - msyslog(LOG_ERR, "invalid MINPOLL value (%ld) in file %s", - intval[TOK_MINPOLL], name); - resolver_exit(1); - } - - if (intval[TOK_MAXPOLL] < NTP_MINPOLL || - intval[TOK_MAXPOLL] > NTP_MAXPOLL) { - msyslog(LOG_ERR, "invalid MAXPOLL value (%ld) in file %s", - intval[TOK_MAXPOLL], name); - resolver_exit(1); - } - - if ((intval[TOK_FLAGS] & ~(FLAG_AUTHENABLE | FLAG_PREFER | - FLAG_NOSELECT | FLAG_BURST | FLAG_IBURST | FLAG_SKEY)) - != 0) { - msyslog(LOG_ERR, "invalid flags (%ld) in file %s", - intval[TOK_FLAGS], name); - resolver_exit(1); - } - - flags = 0; - if (intval[TOK_FLAGS] & FLAG_AUTHENABLE) - flags |= CONF_FLAG_AUTHENABLE; - if (intval[TOK_FLAGS] & FLAG_PREFER) - flags |= CONF_FLAG_PREFER; - if (intval[TOK_FLAGS] & FLAG_NOSELECT) - flags |= CONF_FLAG_NOSELECT; - if (intval[TOK_FLAGS] & FLAG_BURST) - flags |= CONF_FLAG_BURST; - if (intval[TOK_FLAGS] & FLAG_IBURST) - flags |= CONF_FLAG_IBURST; - if (intval[TOK_FLAGS] & FLAG_SKEY) - flags |= CONF_FLAG_SKEY; - - /* - * This is as good as we can check it. Add it in. - */ - addentry(token[TOK_HOSTNAME], (int)intval[TOK_HMODE], - (int)intval[TOK_VERSION], (int)intval[TOK_MINPOLL], - (int)intval[TOK_MAXPOLL], flags, (int)intval[TOK_TTL], - intval[TOK_KEYID], token[TOK_KEYSTR], (u_char)intval[TOK_PEERAF]); - } -} - - -/* - * doconfigure - attempt to resolve names and configure the server - */ -static void -doconfigure( - int dores - ) -{ - register struct conf_entry *ce; - register struct conf_entry *ceremove; - -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, "Running doconfigure %s DNS", - dores ? "with" : "without" ); -#endif - - if (dores) /* Reload /etc/resolv.conf - bug 1226 */ - res_init(); - - ce = confentries; - while (ce != NULL) { -#ifdef DEBUG - if (debug > 1) - msyslog(LOG_INFO, - "doconfigure: <%s> has peeraddr %s", - ce->ce_name, stoa(&ce->peer_store)); -#endif - if (dores && SOCKNUL(&(ce->peer_store))) { - if (!findhostaddr(ce)) { -#ifndef IGNORE_DNS_ERRORS - msyslog(LOG_ERR, - "couldn't resolve `%s', giving up on it", - ce->ce_name); - ceremove = ce; - ce = ceremove->ce_next; - removeentry(ceremove); - continue; -#endif - } - } - - if (!SOCKNUL(&ce->peer_store)) { - if (request(&ce->ce_config)) { - ceremove = ce; - ce = ceremove->ce_next; - removeentry(ceremove); - continue; - } -#ifdef DEBUG - if (debug > 1) { - msyslog(LOG_INFO, - "doconfigure: request() FAILED, maybe next time."); - } -#endif - } - ce = ce->ce_next; - } -} diff --git a/contrib/ntp/ntpd/ntp_io.c b/contrib/ntp/ntpd/ntp_io.c index 2d5572a21..5fc6ed52a 100644 --- a/contrib/ntp/ntpd/ntp_io.c +++ b/contrib/ntp/ntpd/ntp_io.c @@ -7,41 +7,61 @@ # include #endif +#include +#include +#ifdef HAVE_FNMATCH_H +# include +# if !defined(FNM_CASEFOLD) && defined(FNM_IGNORECASE) +# define FNM_CASEFOLD FNM_IGNORECASE +# endif +#endif +#ifdef HAVE_SYS_PARAM_H +# include +#endif +#ifdef HAVE_SYS_IOCTL_H +# include +#endif +#ifdef HAVE_SYS_SOCKIO_H /* UXPV: SIOC* #defines (Frank Vance ) */ +# include +#endif +#ifdef HAVE_SYS_UIO_H +# include +#endif + #include "ntp_machine.h" #include "ntpd.h" #include "ntp_io.h" #include "iosignal.h" +#include "ntp_lists.h" #include "ntp_refclock.h" #include "ntp_stdlib.h" +#include "ntp_worker.h" #include "ntp_request.h" -#include "ntp.h" -#include "ntp_unixtime.h" +#include "ntp_assert.h" +#include "timevalops.h" +#include "timespecops.h" +#include "ntpd-opts.h" /* Don't include ISC's version of IPv6 variables and structures */ #define ISC_IPV6_H 1 +#include #include -#include +#include #include +#include #ifdef SIM #include "ntpsim.h" #endif -#include -#include -#ifdef HAVE_SYS_PARAM_H -# include -#endif /* HAVE_SYS_PARAM_H */ -#ifdef HAVE_SYS_IOCTL_H -# include -#endif -#ifdef HAVE_SYS_SOCKIO_H /* UXPV: SIOC* #defines (Frank Vance ) */ -# include -#endif -#ifdef HAVE_SYS_UIO_H -# include +#ifdef HAS_ROUTING_SOCKET +# include +# ifdef HAVE_RTNETLINK +# include +# endif #endif + /* * setsockopt does not always have the same arg declaration * across all platforms. If it's not defined we make it empty @@ -51,62 +71,75 @@ #define SETSOCKOPT_ARG_CAST #endif -/* - * Set up some macros to look for IPv6 and IPv6 multicast - */ - -#if defined(ISC_PLATFORM_HAVEIPV6) && !defined(DISABLE_IPV6) - -#define INCLUDE_IPV6_SUPPORT - -#if defined(INCLUDE_IPV6_SUPPORT) && defined(IPV6_JOIN_GROUP) && defined(IPV6_LEAVE_GROUP) -#define INCLUDE_IPV6_MULTICAST_SUPPORT +extern int listen_to_virtual_ips; -#endif /* IPV6 Multicast Support */ -#endif /* IPv6 Support */ +#ifndef IPTOS_DSCP_EF +#define IPTOS_DSCP_EF 0xb8 +#endif +int qos = IPTOS_DSCP_EF; /* QoS RFC3246 */ -#ifdef INCLUDE_IPV6_SUPPORT -#include -#include -#include -#endif /* !INCLUDE_IPV6_SUPPORT */ +#ifdef LEAP_SMEAR +/* TODO burnicki: This should be moved to ntp_timer.c, but if we do so + * we get a linker error. Since we're running out of time before the leap + * second occurs, we let it here where it just works. + */ +int leap_smear_intv; +#endif -extern int listen_to_virtual_ips; -extern const char *specific_interface; +/* + * NIC rule entry + */ +typedef struct nic_rule_tag nic_rule; + +struct nic_rule_tag { + nic_rule * next; + nic_rule_action action; + nic_rule_match match_type; + char * if_name; + sockaddr_u addr; + int prefixlen; +}; -#if defined(SO_TIMESTAMP) && defined(SCM_TIMESTAMP) -#if defined(CMSG_FIRSTHDR) -#define HAVE_TIMESTAMP -#define USE_TIMESTAMP_CMSG -#ifndef TIMESTAMP_CTLMSGBUF_SIZE -#define TIMESTAMP_CTLMSGBUF_SIZE 1536 /* moderate default */ -#endif +/* + * NIC rule listhead. Entries are added at the head so that the first + * match in the list is the last matching rule specified. + */ +nic_rule *nic_rule_list; + + +#if defined(SO_BINTIME) && defined(SCM_BINTIME) && defined(CMSG_FIRSTHDR) +# define HAVE_PACKET_TIMESTAMP +# define HAVE_BINTIME +# ifdef BINTIME_CTLMSGBUF_SIZE +# define CMSG_BUFSIZE BINTIME_CTLMSGBUF_SIZE +# else +# define CMSG_BUFSIZE 1536 /* moderate default */ +# endif +#elif defined(SO_TIMESTAMPNS) && defined(SCM_TIMESTAMPNS) && defined(CMSG_FIRSTHDR) +# define HAVE_PACKET_TIMESTAMP +# define HAVE_TIMESTAMPNS +# ifdef TIMESTAMPNS_CTLMSGBUF_SIZE +# define CMSG_BUFSIZE TIMESTAMPNS_CTLMSGBUF_SIZE +# else +# define CMSG_BUFSIZE 1536 /* moderate default */ +# endif +#elif defined(SO_TIMESTAMP) && defined(SCM_TIMESTAMP) && defined(CMSG_FIRSTHDR) +# define HAVE_PACKET_TIMESTAMP +# define HAVE_TIMESTAMP +# ifdef TIMESTAMP_CTLMSGBUF_SIZE +# define CMSG_BUFSIZE TIMESTAMP_CTLMSGBUF_SIZE +# else +# define CMSG_BUFSIZE 1536 /* moderate default */ +# endif #else /* fill in for old/other timestamp interfaces */ #endif -#endif #if defined(SYS_WINNT) -#include +#include "win32_io.h" #include -/* - * Define this macro to control the behavior of connection - * resets on UDP sockets. See Microsoft KnowledgeBase Article Q263823 - * for details. - * NOTE: This requires that Windows 2000 systems install Service Pack 2 - * or later. - */ -#ifndef SIO_UDP_CONNRESET -#define SIO_UDP_CONNRESET _WSAIOW(IOC_VENDOR,12) #endif -/* - * Windows C runtime ioctl() can't deal properly with sockets, - * map to ioctlsocket for this source file. - */ -#define ioctl(fd, opt, val) ioctlsocket((fd), (opt), (u_long *)(val)) -#endif /* SYS_WINNT */ - /* * We do asynchronous input using the SIGIO facility. A number of * recvbuf buffers are preallocated for input. In the signal @@ -130,8 +163,8 @@ extern const char *specific_interface; volatile u_long packets_dropped; /* total number of packets dropped on reception */ volatile u_long packets_ignored; /* packets received on wild card interface */ volatile u_long packets_received; /* total number of packets received */ -u_long packets_sent; /* total number of packets sent */ -u_long packets_notsent; /* total number of packets which couldn't be sent */ + u_long packets_sent; /* total number of packets sent */ + u_long packets_notsent; /* total number of packets which couldn't be sent */ volatile u_long handler_calls; /* number of calls to interrupt handler */ volatile u_long handler_pkts; /* number of pkts received by handler */ @@ -140,13 +173,15 @@ u_long io_timereset; /* time counters were reset */ /* * Interface stuff */ -struct interface *any_interface; /* default ipv4 interface */ -struct interface *any6_interface; /* default ipv6 interface */ -struct interface *loopback_interface; /* loopback ipv4 interface */ +endpt * any_interface; /* wildcard ipv4 interface */ +endpt * any6_interface; /* wildcard ipv6 interface */ +endpt * loopback_interface; /* loopback ipv4 interface */ +isc_boolean_t broadcast_client_enabled; /* is broadcast client enabled */ +u_int sys_ifnum; /* next .ifnum to assign */ int ninterfaces; /* Total number of interfaces */ -volatile int disable_dynamic_updates; /* when set to != 0 dynamic updates won't happen */ +int disable_dynamic_updates; /* scan interfaces once only */ #ifdef REFCLOCK /* @@ -156,67 +191,62 @@ volatile int disable_dynamic_updates; /* when set to != 0 dynamic updates won' static struct refclockio *refio; #endif /* REFCLOCK */ - -/* - * Define what the possible "soft" errors can be. These are non-fatal returns - * of various network related functions, like recv() and so on. - * - * For some reason, BSDI (and perhaps others) will sometimes return <0 - * from recv() but will have errno==0. This is broken, but we have to - * work around it here. - */ -#define SOFT_ERROR(e) ((e) == EAGAIN || \ - (e) == EWOULDBLOCK || \ - (e) == EINTR || \ - (e) == 0) - /* * File descriptor masks etc. for call to select - * Not needed for I/O Completion Ports + * Not needed for I/O Completion Ports or anything outside this file */ -fd_set activefds; -int maxactivefd; +static fd_set activefds; +static int maxactivefd; + /* * bit alternating value to detect verified interfaces during an update cycle */ -static u_char sys_interphase = 0; +static u_short sys_interphase = 0; -static struct interface *new_interface P((struct interface *)); -static void add_interface P((struct interface *)); -static int update_interfaces P((u_short, interface_receiver_t, void *)); -static void remove_interface P((struct interface *)); -static struct interface *create_interface P((u_short, struct interface *)); +static endpt * new_interface(endpt *); +static void add_interface(endpt *); +static int update_interfaces(u_short, interface_receiver_t, + void *); +static void remove_interface(endpt *); +static endpt * create_interface(u_short, endpt *); -static int move_fd P((SOCKET)); +static int is_wildcard_addr (const sockaddr_u *); /* * Multicast functions */ -static isc_boolean_t addr_ismulticast P((struct sockaddr_storage *)); +static isc_boolean_t addr_ismulticast (sockaddr_u *); +static isc_boolean_t is_anycast (sockaddr_u *, + const char *); + /* * Not all platforms support multicast */ #ifdef MCAST -static isc_boolean_t socket_multicast_enable P((struct interface *, int, struct sockaddr_storage *)); -static isc_boolean_t socket_multicast_disable P((struct interface *, struct sockaddr_storage *)); +static isc_boolean_t socket_multicast_enable (endpt *, sockaddr_u *); +static isc_boolean_t socket_multicast_disable(endpt *, sockaddr_u *); #endif #ifdef DEBUG -static void print_interface P((struct interface *, char *, char *)); -#define DPRINT_INTERFACE(_LVL_, _ARGS_) do { if (debug >= (_LVL_)) { print_interface _ARGS_; } } while (0) +static void interface_dump (const endpt *); +static void sockaddr_dump (const sockaddr_u *); +static void print_interface (const endpt *, const char *, const char *); +#define DPRINT_INTERFACE(level, args) do { if (debug >= (level)) { print_interface args; } } while (0) #else -#define DPRINT_INTERFACE(_LVL_, _ARGS_) do {} while (0) +#define DPRINT_INTERFACE(level, args) do {} while (0) #endif typedef struct vsock vsock_t; enum desc_type { FD_TYPE_SOCKET, FD_TYPE_FILE }; struct vsock { - SOCKET fd; - enum desc_type type; - ISC_LINK(vsock_t) link; + vsock_t * link; + SOCKET fd; + enum desc_type type; }; +vsock_t *fd_list; + #if !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) /* * async notification processing (e. g. routing sockets) @@ -226,213 +256,132 @@ struct vsock { * like e. g. routing sockets */ struct asyncio_reader { - SOCKET fd; /* fd to be read */ - void *data; /* possibly local data */ + struct asyncio_reader *link; /* the list this is being kept in */ + SOCKET fd; /* fd to be read */ + void *data; /* possibly local data */ void (*receiver)(struct asyncio_reader *); /* input handler */ - ISC_LINK(struct asyncio_reader) link; /* the list this is being kept in */ }; -ISC_LIST(struct asyncio_reader) asyncio_reader_list; +struct asyncio_reader *asyncio_reader_list; -static void delete_asyncio_reader P((struct asyncio_reader *)); -static struct asyncio_reader *new_asyncio_reader P((void)); -static void add_asyncio_reader P((struct asyncio_reader *, enum desc_type)); -static void remove_asyncio_reader P((struct asyncio_reader *)); +static void delete_asyncio_reader (struct asyncio_reader *); +static struct asyncio_reader *new_asyncio_reader (void); +static void add_asyncio_reader (struct asyncio_reader *, enum desc_type); +static void remove_asyncio_reader (struct asyncio_reader *); #endif /* !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) */ -static void init_async_notifications P((void)); - -static int create_sockets P((u_short)); -static SOCKET open_socket P((struct sockaddr_storage *, int, int, struct interface *)); -static char * fdbits P((int, fd_set *)); -static void set_reuseaddr P((int)); -static isc_boolean_t socket_broadcast_enable P((struct interface *, SOCKET, struct sockaddr_storage *)); -static isc_boolean_t socket_broadcast_disable P((struct interface *, struct sockaddr_storage *)); - -ISC_LIST(vsock_t) fd_list; +static void init_async_notifications (void); + +static int addr_eqprefix (const sockaddr_u *, const sockaddr_u *, + int); +static int addr_samesubnet (const sockaddr_u *, const sockaddr_u *, + const sockaddr_u *, const sockaddr_u *); +static int create_sockets (u_short); +static SOCKET open_socket (sockaddr_u *, int, int, endpt *); +static char * fdbits (int, fd_set *); +static void set_reuseaddr (int); +static isc_boolean_t socket_broadcast_enable (struct interface *, SOCKET, sockaddr_u *); +#ifdef OS_MISSES_SPECIFIC_ROUTE_UPDATES +static isc_boolean_t socket_broadcast_disable (struct interface *, sockaddr_u *); +#endif typedef struct remaddr remaddr_t; struct remaddr { - struct sockaddr_storage addr; - struct interface *interface; - ISC_LINK(remaddr_t) link; + remaddr_t * link; + sockaddr_u addr; + endpt * ep; }; -ISC_LIST(remaddr_t) remoteaddr_list; +remaddr_t * remoteaddr_list; +endpt * ep_list; /* complete endpt list */ +endpt * mc4_list; /* IPv4 mcast-capable unicast endpts */ +endpt * mc6_list; /* IPv6 mcast-capable unicast endpts */ -ISC_LIST(struct interface) inter_list; +static endpt * wildipv4; +static endpt * wildipv6; -static struct interface *wildipv4 = NULL; -static struct interface *wildipv6 = NULL; +#ifdef SYS_WINNT +int accept_wildcard_if_for_winnt; +#else +const int accept_wildcard_if_for_winnt = FALSE; +#endif -static void add_fd_to_list P((SOCKET, enum desc_type)); -static void close_and_delete_fd_from_list P((SOCKET)); -static void add_addr_to_list P((struct sockaddr_storage *, struct interface *)); -static void delete_addr_from_list P((struct sockaddr_storage *)); -static struct interface *find_addr_in_list P((struct sockaddr_storage *)); -static struct interface *find_flagged_addr_in_list P((struct sockaddr_storage *, int)); -static void create_wildcards P((u_short)); -static isc_boolean_t address_okay P((struct interface *)); -static void convert_isc_if P((isc_interface_t *, struct interface *, u_short)); -static void delete_interface_from_list P((struct interface *)); -static struct interface *getinterface P((struct sockaddr_storage *, int)); -static struct interface *findlocalinterface P((struct sockaddr_storage *, int)); -static struct interface *findlocalcastinterface P((struct sockaddr_storage *, int)); +static void add_fd_to_list (SOCKET, enum desc_type); +static endpt * find_addr_in_list (sockaddr_u *); +static endpt * find_flagged_addr_in_list(sockaddr_u *, u_int32); +static void delete_addr_from_list (sockaddr_u *); +static void delete_interface_from_list(endpt *); +static void close_and_delete_fd_from_list(SOCKET); +static void add_addr_to_list (sockaddr_u *, endpt *); +static void create_wildcards (u_short); +static endpt * findlocalinterface (sockaddr_u *, int, int); +static endpt * findclosestinterface (sockaddr_u *, int); +#ifdef DEBUG +static const char * action_text (nic_rule_action); +#endif +static nic_rule_action interface_action(char *, sockaddr_u *, u_int32); +static void convert_isc_if (isc_interface_t *, + endpt *, u_short); +static void calc_addr_distance(sockaddr_u *, + const sockaddr_u *, + const sockaddr_u *); +static int cmp_addr_distance(const sockaddr_u *, + const sockaddr_u *); /* * Routines to read the ntp packets */ #if !defined(HAVE_IO_COMPLETION_PORT) -static inline int read_network_packet P((SOCKET, struct interface *, l_fp)); -static inline int read_refclock_packet P((SOCKET, struct refclockio *, l_fp)); -#endif - -#ifdef SYS_WINNT -/* - * Windows 2000 systems incorrectly cause UDP sockets using WASRecvFrom - * to not work correctly, returning a WSACONNRESET error when a WSASendTo - * fails with an "ICMP port unreachable" response and preventing the - * socket from using the WSARecvFrom in subsequent operations. - * The function below fixes this, but requires that Windows 2000 - * Service Pack 2 or later be installed on the system. NT 4.0 - * systems are not affected by this and work correctly. - * See Microsoft Knowledge Base Article Q263823 for details of this. - */ -void -connection_reset_fix( - SOCKET fd, - struct sockaddr_storage *addr - ) -{ - DWORD dwBytesReturned = 0; - BOOL bNewBehavior = FALSE; - DWORD status; - - /* - * disable bad behavior using IOCTL: SIO_UDP_CONNRESET - * NT 4.0 has no problem - */ - if (isc_win32os_majorversion() >= 5) { - status = WSAIoctl(fd, SIO_UDP_CONNRESET, &bNewBehavior, - sizeof(bNewBehavior), NULL, 0, - &dwBytesReturned, NULL, NULL); - if (SOCKET_ERROR == status) - netsyslog(LOG_ERR, "connection_reset_fix() " - "failed for address %s: %m", - stoa(addr)); - } -} -#endif - -/* - * on Unix systems the stdio library typically - * makes use of file descriptors in the lower - * integer range. stdio usually will make use - * of the file descriptor in the range of - * [0..FOPEN_MAX) - * in order to keep this range clean for socket - * file descriptors we attempt to move them above - * FOPEM_MAX. This is not as easy as it sounds as - * FOPEN_MAX changes from implementation to implementation - * and may exceed to current file decriptor limits. - * We are using following strategy: - * - keep a current socket fd boundary initialized with - * max(0, min(getdtablesize() - FD_CHUNK, FOPEN_MAX)) - * - attempt to move the descriptor to the boundary or - * above. - * - if that fails and boundary > 0 set boundary - * to min(0, socket_fd_boundary - FD_CHUNK) - * -> retry - * if failure and boundary == 0 return old fd - * - on success close old fd return new fd - * - * effects: - * - fds will be moved above the socket fd boundary - * if at all possible. - * - the socket boundary will be reduced until - * allocation is possible or 0 is reached - at this - * point the algrithm will be disabled - */ -static int move_fd(SOCKET fd) -{ -#if !defined(SYS_WINNT) && defined(F_DUPFD) -#ifndef FD_CHUNK -#define FD_CHUNK 10 +static inline int read_network_packet (SOCKET, struct interface *, l_fp); +static void ntpd_addremove_io_fd (int, int, int); +static input_handler_t input_handler; +#ifdef REFCLOCK +static inline int read_refclock_packet (SOCKET, struct refclockio *, l_fp); #endif -/* - * number of fds we would like to have for - * stdio FILE* available. - * we can pick a "low" number as our use of - * FILE* is limited to log files and temporarily - * to data and config files. Except for log files - * we don't keep the other FILE* open beyond the - * scope of the function that opened it. - */ -#ifndef FD_PREFERRED_SOCKBOUNDARY -#define FD_PREFERRED_SOCKBOUNDARY 48 #endif -#ifndef HAVE_GETDTABLESIZE -/* - * if we have no idea about the max fd value set up things - * so we will start at FOPEN_MAX - */ -#define getdtablesize() (FOPEN_MAX+FD_CHUNK) -#endif -#ifndef FOPEN_MAX -#define FOPEN_MAX 20 /* assume that for the lack of anything better */ -#endif - static SOCKET socket_boundary = -1; - SOCKET newfd; - /* - * check whether boundary has be set up - * already - */ - if (socket_boundary == -1) { - socket_boundary = max(0, min(getdtablesize() - FD_CHUNK, - min(FOPEN_MAX, FD_PREFERRED_SOCKBOUNDARY))); -#ifdef DEBUG - msyslog(LOG_DEBUG, "ntp_io: estimated max descriptors: %d, initial socket boundary: %d", - getdtablesize(), socket_boundary); -#endif +#ifndef HAVE_IO_COMPLETION_PORT +void +maintain_activefds( + int fd, + int closing + ) +{ + int i; + + if (fd < 0 || fd >= FD_SETSIZE) { + msyslog(LOG_ERR, + "Too many sockets in use, FD_SETSIZE %d exceeded by fd %d", + FD_SETSIZE, fd); + exit(1); } - /* - * Leave a space for stdio to work in. potentially moving the - * socket_boundary lower until allocation succeeds. - */ - do { - if (fd >= 0 && fd < socket_boundary) { - /* inside reserved range: attempt to move fd */ - newfd = fcntl(fd, F_DUPFD, socket_boundary); - - if (newfd != -1) { - /* success: drop the old one - return the new one */ - (void)close(fd); - return (newfd); - } - } else { - /* outside reserved range: no work - return the original one */ - return (fd); + if (!closing) { + FD_SET(fd, &activefds); + maxactivefd = max(fd, maxactivefd); + } else { + FD_CLR(fd, &activefds); + if (maxactivefd && fd == maxactivefd) { + for (i = maxactivefd - 1; i >= 0; i--) + if (FD_ISSET(i, &activefds)) { + maxactivefd = i; + break; + } + INSIST(fd != maxactivefd); } - socket_boundary = max(0, socket_boundary - FD_CHUNK); -#ifdef DEBUG - msyslog(LOG_DEBUG, "ntp_io: selecting new socket boundary: %d", - socket_boundary); -#endif - } while (socket_boundary > 0); -#endif /* !defined(SYS_WINNT) && defined(F_DUPFD) */ - return (fd); + } } +#endif /* !HAVE_IO_COMPLETION_PORT */ + #ifdef DEBUG_TIMING /* * collect timing information for various processing - * paths. currently we only pass then on to the file + * paths. currently we only pass them on to the file * for later processing. this could also do histogram * based analysis in other to reduce the load (and skew) * dur to the file output @@ -440,16 +389,19 @@ static int move_fd(SOCKET fd) void collect_timing(struct recvbuf *rb, const char *tag, int count, l_fp *dts) { - char buf[2048]; - - snprintf(buf, sizeof(buf), "%s %d %s %s", - (rb != NULL) ? - ((rb->dstadr) ? stoa(&rb->recv_srcadr) : "-REFCLOCK-") : "-", + char buf[256]; + + snprintf(buf, sizeof(buf), "%s %d %s %s", + (rb != NULL) + ? ((rb->dstadr != NULL) + ? stoa(&rb->recv_srcadr) + : "-REFCLOCK-") + : "-", count, lfptoa(dts, 9), tag); record_timing_stats(buf); } #endif - + /* * About dynamic interfaces, sockets, reception and more... * @@ -459,7 +411,7 @@ collect_timing(struct recvbuf *rb, const char *tag, int count, l_fp *dts) * to bind to to the interface address on NTP_PORT so that * all wild and specific bindings for NTP_PORT are taken by ntpd * to avoid other daemons messing with the time or sockets. - * - all interfaces keep a list of peers that are referencing + * - all interfaces keep a list of peers that are referencing * the interface in order to quickly re-assign the peers to * new interface in case an interface is deleted (=> gone from system or * down) @@ -483,114 +435,95 @@ collect_timing(struct recvbuf *rb, const char *tag, int count, l_fp *dts) * but a list of interfaces that represent a unique address as determined by the kernel * by the procedure in findlocalinterface. Thus it is perfectly legal to see only * one representative of a group of real interfaces if they share the same address. - * + * * Frank Kardel 20050910 */ /* - * init_io - initialize I/O data structures and call socket creation routine + * init_io - initialize I/O module. */ void init_io(void) { -#ifdef SYS_WINNT - init_io_completion_port(); - - if (!Win32InitSockets()) - { - netsyslog(LOG_ERR, "No useable winsock.dll: %m"); - exit(1); - } - init_transmitbuff(); -#endif /* SYS_WINNT */ - - /* - * Init buffer free list and stat counters - */ + /* Init buffer free list and stat counters */ init_recvbuff(RECV_INIT); + /* update interface every 5 minutes as default */ + interface_interval = 300; - packets_dropped = packets_received = 0; - packets_ignored = 0; - packets_sent = packets_notsent = 0; - handler_calls = handler_pkts = 0; - io_timereset = 0; - loopback_interface = NULL; - any_interface = NULL; - any6_interface = NULL; +#ifdef WORK_PIPE + addremove_io_fd = &ntpd_addremove_io_fd; +#endif -#ifdef REFCLOCK - refio = NULL; +#ifdef SYS_WINNT + init_io_completion_port(); #endif #if defined(HAVE_SIGNALED_IO) - (void) set_signal(); + (void) set_signal(input_handler); #endif +} - ISC_LIST_INIT(fd_list); -#if !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) - ISC_LIST_INIT(asyncio_reader_list); -#endif +static void +ntpd_addremove_io_fd( + int fd, + int is_pipe, + int remove_it + ) +{ + UNUSED_ARG(is_pipe); + +#ifdef HAVE_SIGNALED_IO + init_socket_sig(fd); +#endif /* not HAVE_SIGNALED_IO */ + + maintain_activefds(fd, remove_it); +} + + +/* + * io_open_sockets - call socket creation routine + */ +void +io_open_sockets(void) +{ + static int already_opened; - ISC_LIST_INIT(remoteaddr_list); + if (already_opened || HAVE_OPT( SAVECONFIGQUIT )) + return; - ISC_LIST_INIT(inter_list); + already_opened = 1; /* * Create the sockets */ BLOCKIO(); - (void) create_sockets(htons(NTP_PORT)); + create_sockets(NTP_PORT); UNBLOCKIO(); init_async_notifications(); - DPRINTF(3, ("init_io: maxactivefd %d\n", maxactivefd)); + DPRINTF(3, ("io_open_sockets: maxactivefd %d\n", maxactivefd)); } + #ifdef DEBUG /* * function to dump the contents of the interface structure * for debugging use only. */ void -interface_dump(struct interface *itf) +interface_dump(const endpt *itf) { - u_char* cp; - int i; - /* Limit the size of the sockaddr_storage hex dump */ - int maxsize = min(32, sizeof(struct sockaddr_storage)); - printf("Dumping interface: %p\n", itf); printf("fd = %d\n", itf->fd); printf("bfd = %d\n", itf->bfd); - printf("sin = %s,\n", stoa(&(itf->sin))); - cp = (u_char*) &(itf->sin); - for(i = 0; i < maxsize; i++) - { - printf("%02x", *cp++); - if((i+1)%4 == 0) - printf(" "); - } - printf("\n"); - printf("bcast = %s,\n", stoa(&(itf->bcast))); - cp = (u_char*) &(itf->bcast); - for(i = 0; i < maxsize; i++) - { - printf("%02x", *cp++); - if((i+1)%4 == 0) - printf(" "); - } - printf("\n"); - printf("mask = %s,\n", stoa(&(itf->mask))); - cp = (u_char*) &(itf->mask); - for(i = 0; i < maxsize; i++) - { - printf("%02x", *cp++); - if((i+1)%4 == 0) - printf(" "); - } - printf("\n"); + printf("sin = %s,\n", stoa(&itf->sin)); + sockaddr_dump(&itf->sin); + printf("bcast = %s,\n", stoa(&itf->bcast)); + sockaddr_dump(&itf->bcast); + printf("mask = %s,\n", stoa(&itf->mask)); + sockaddr_dump(&itf->mask); printf("name = %s\n", itf->name); printf("flags = 0x%08x\n", itf->flags); printf("last_ttl = %d\n", itf->last_ttl); @@ -600,40 +533,60 @@ interface_dump(struct interface *itf) printf("sent = %ld\n", itf->sent); printf("notsent = %ld\n", itf->notsent); printf("ifindex = %u\n", itf->ifindex); - printf("scopeid = %u\n", itf->scopeid); printf("peercnt = %u\n", itf->peercnt); printf("phase = %u\n", itf->phase); } +/* + * sockaddr_dump - hex dump the start of a sockaddr_u + */ +static void +sockaddr_dump(const sockaddr_u *psau) +{ + /* Limit the size of the sockaddr_in6 hex dump */ + const int maxsize = min(32, sizeof(psau->sa6)); + const u_char * cp; + int i; + + /* XXX: Should we limit maxsize based on psau->saX.sin_family? */ + cp = (const void *)&psau->sa6; + + for(i = 0; i < maxsize; i++) { + printf("%02x", *cp++); + if (!((i + 1) % 4)) + printf(" "); + } + printf("\n"); +} + /* * print_interface - helper to output debug information */ static void -print_interface(struct interface *iface, char *pfx, char *sfx) +print_interface(const endpt *iface, const char *pfx, const char *sfx) { - printf("%sinterface #%d: fd=%d, bfd=%d, name=%s, flags=0x%x, scope=%d, ifindex=%d", + printf("%sinterface #%d: fd=%d, bfd=%d, name=%s, flags=0x%x, ifindex=%u, sin=%s", pfx, iface->ifnum, iface->fd, iface->bfd, iface->name, iface->flags, - iface->scopeid, - iface->ifindex); - /* Leave these as three printf calls. */ - printf(", sin=%s", - stoa((&iface->sin))); - if (iface->flags & INT_BROADCAST) - printf(", bcast=%s,", - stoa((&iface->bcast))); - if (iface->family == AF_INET) - printf(", mask=%s", - stoa((&iface->mask))); - printf(", %s:%s", iface->ignore_packets == ISC_FALSE ? "Enabled" : "Disabled", sfx); + iface->ifindex, + stoa(&iface->sin)); + if (AF_INET == iface->family) { + if (iface->flags & INT_BROADCAST) + printf(", bcast=%s", stoa(&iface->bcast)); + printf(", mask=%s", stoa(&iface->mask)); + } + printf(", %s:%s", + (iface->ignore_packets) + ? "Disabled" + : "Enabled", + sfx); if (debug > 4) /* in-depth debugging only */ interface_dump(iface); } - #endif #if !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) @@ -641,15 +594,13 @@ print_interface(struct interface *iface, char *pfx, char *sfx) * create an asyncio_reader structure */ static struct asyncio_reader * -new_asyncio_reader() +new_asyncio_reader(void) { struct asyncio_reader *reader; - reader = (struct asyncio_reader *)emalloc(sizeof(struct asyncio_reader)); - - memset((char *)reader, 0, sizeof(*reader)); - ISC_LINK_INIT(reader, link); + reader = emalloc_zero(sizeof(*reader)); reader->fd = INVALID_SOCKET; + return reader; } @@ -657,7 +608,9 @@ new_asyncio_reader() * delete a reader */ static void -delete_asyncio_reader(struct asyncio_reader *reader) +delete_asyncio_reader( + struct asyncio_reader *reader + ) { free(reader); } @@ -666,19 +619,26 @@ delete_asyncio_reader(struct asyncio_reader *reader) * add asynchio_reader */ static void -add_asyncio_reader(struct asyncio_reader *reader, enum desc_type type) +add_asyncio_reader( + struct asyncio_reader * reader, + enum desc_type type) { - ISC_LIST_APPEND(asyncio_reader_list, reader, link); + LINK_SLIST(asyncio_reader_list, reader, link); add_fd_to_list(reader->fd, type); } - + /* * remove asynchio_reader */ static void -remove_asyncio_reader(struct asyncio_reader *reader) +remove_asyncio_reader( + struct asyncio_reader *reader + ) { - ISC_LIST_UNLINK_TYPE(asyncio_reader_list, reader, link, struct asyncio_reader); + struct asyncio_reader *unlinked; + + UNLINK_SLIST(unlinked, asyncio_reader_list, reader, link, + struct asyncio_reader); if (reader->fd != INVALID_SOCKET) close_and_delete_fd_from_list(reader->fd); @@ -687,366 +647,874 @@ remove_asyncio_reader(struct asyncio_reader *reader) } #endif /* !defined(HAVE_IO_COMPLETION_PORT) && defined(HAS_ROUTING_SOCKET) */ + +/* compare two sockaddr prefixes */ +static int +addr_eqprefix( + const sockaddr_u * a, + const sockaddr_u * b, + int prefixlen + ) +{ + isc_netaddr_t isc_a; + isc_netaddr_t isc_b; + isc_sockaddr_t isc_sa; + + ZERO(isc_sa); + memcpy(&isc_sa.type, a, min(sizeof(isc_sa.type), sizeof(*a))); + isc_netaddr_fromsockaddr(&isc_a, &isc_sa); + + ZERO(isc_sa); + memcpy(&isc_sa.type, b, min(sizeof(isc_sa.type), sizeof(*b))); + isc_netaddr_fromsockaddr(&isc_b, &isc_sa); + + return (int)isc_netaddr_eqprefix(&isc_a, &isc_b, + (u_int)prefixlen); +} + + +static int +addr_samesubnet( + const sockaddr_u * a, + const sockaddr_u * a_mask, + const sockaddr_u * b, + const sockaddr_u * b_mask + ) +{ + const u_int32 * pa; + const u_int32 * pa_limit; + const u_int32 * pb; + const u_int32 * pm; + size_t loops; + + REQUIRE(AF(a) == AF(a_mask)); + REQUIRE(AF(b) == AF(b_mask)); + /* + * With address and mask families verified to match, comparing + * the masks also validates the address's families match. + */ + if (!SOCK_EQ(a_mask, b_mask)) + return FALSE; + + if (IS_IPV6(a)) { + loops = sizeof(NSRCADR6(a)) / sizeof(*pa); + pa = (const void *)&NSRCADR6(a); + pb = (const void *)&NSRCADR6(b); + pm = (const void *)&NSRCADR6(a_mask); + } else { + loops = sizeof(NSRCADR(a)) / sizeof(*pa); + pa = (const void *)&NSRCADR(a); + pb = (const void *)&NSRCADR(b); + pm = (const void *)&NSRCADR(a_mask); + } + for (pa_limit = pa + loops; pa < pa_limit; pa++, pb++, pm++) + if ((*pa & *pm) != (*pb & *pm)) + return FALSE; + + return TRUE; +} + + +/* + * Code to tell if we have an IP address + * If we have then return the sockaddr structure + * and set the return value + * see the bind9/getaddresses.c for details + */ +int +is_ip_address( + const char * host, + u_short af, + sockaddr_u * addr + ) +{ + struct in_addr in4; + struct addrinfo hints; + struct addrinfo *result; + struct sockaddr_in6 *resaddr6; + char tmpbuf[128]; + char *pch; + + REQUIRE(host != NULL); + REQUIRE(addr != NULL); + + ZERO_SOCK(addr); + + /* + * Try IPv4, then IPv6. In order to handle the extended format + * for IPv6 scoped addresses (address%scope_ID), we'll use a local + * working buffer of 128 bytes. The length is an ad-hoc value, but + * should be enough for this purpose; the buffer can contain a string + * of at least 80 bytes for scope_ID in addition to any IPv6 numeric + * addresses (up to 46 bytes), the delimiter character and the + * terminating NULL character. + */ + if (AF_UNSPEC == af || AF_INET == af) + if (inet_pton(AF_INET, host, &in4) == 1) { + AF(addr) = AF_INET; + SET_ADDR4N(addr, in4.s_addr); + + return TRUE; + } + + if (AF_UNSPEC == af || AF_INET6 == af) + if (sizeof(tmpbuf) > strlen(host)) { + if ('[' == host[0]) { + strlcpy(tmpbuf, &host[1], sizeof(tmpbuf)); + pch = strchr(tmpbuf, ']'); + if (pch != NULL) + *pch = '\0'; + } else { + strlcpy(tmpbuf, host, sizeof(tmpbuf)); + } + ZERO(hints); + hints.ai_family = AF_INET6; + hints.ai_flags |= AI_NUMERICHOST; + if (getaddrinfo(tmpbuf, NULL, &hints, &result) == 0) { + AF(addr) = AF_INET6; + resaddr6 = (struct sockaddr_in6 *)result->ai_addr; + SET_ADDR6N(addr, resaddr6->sin6_addr); + SET_SCOPE(addr, resaddr6->sin6_scope_id); + + freeaddrinfo(result); + return TRUE; + } + } + /* + * If we got here it was not an IP address + */ + return FALSE; +} + + /* * interface list enumerator - visitor pattern */ void -interface_enumerate(interface_receiver_t receiver, void *data) +interface_enumerate( + interface_receiver_t receiver, + void * data + ) { interface_info_t ifi; - struct interface *interf; ifi.action = IFS_EXISTS; - - for (interf = ISC_LIST_HEAD(inter_list); - interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) { - ifi.interface = interf; - receiver(data, &ifi); - } + for (ifi.ep = ep_list; ifi.ep != NULL; ifi.ep = ifi.ep->elink) + (*receiver)(data, &ifi); } /* * do standard initialization of interface structure */ static void -init_interface(struct interface *interface) +init_interface( + endpt *ep + ) { - memset((char *)interface, 0, sizeof(struct interface)); - ISC_LINK_INIT(interface, link); - ISC_LIST_INIT(interface->peers); - interface->fd = INVALID_SOCKET; - interface->bfd = INVALID_SOCKET; - interface->num_mcast = 0; - interface->received = 0; - interface->sent = 0; - interface->notsent = 0; - interface->peercnt = 0; - interface->phase = sys_interphase; + ZERO(*ep); + ep->fd = INVALID_SOCKET; + ep->bfd = INVALID_SOCKET; + ep->phase = sys_interphase; } + /* * create new interface structure initialize from * template structure or via standard initialization * function */ static struct interface * -new_interface(struct interface *interface) +new_interface( + struct interface *interface + ) { - static u_int sys_ifnum = 0; + struct interface * iface; - struct interface *iface = (struct interface *)emalloc(sizeof(struct interface)); + iface = emalloc(sizeof(*iface)); - if (interface != NULL) - { - memcpy((char*)iface, (char*)interface, sizeof(*interface)); - } - else - { + if (NULL == interface) init_interface(iface); - } + else /* use the template */ + memcpy(iface, interface, sizeof(*iface)); - iface->ifnum = sys_ifnum++; /* count every new instance of an interface in the system */ + /* count every new instance of an interface in the system */ + iface->ifnum = sys_ifnum++; iface->starttime = current_time; return iface; } + /* * return interface storage into free memory pool */ -static void -delete_interface(struct interface *interface) +static inline void +delete_interface( + endpt *ep + ) { - free(interface); + free(ep); } + /* * link interface into list of known interfaces */ static void -add_interface(struct interface *interface) +add_interface( + endpt * ep + ) { - static struct interface *listhead = NULL; - - /* - * For ntpd, the first few interfaces (wildcard, localhost) - * will never be removed. This means inter_list.head is - * unchanging once initialized. Take advantage of that to - * watch for changes and catch corruption earlier. This - * helped track down corruption caused by using FD_SET with - * a descriptor numerically larger than FD_SETSIZE. - */ - if (NULL == listhead) - listhead = inter_list.head; - - if (listhead != inter_list.head) { - msyslog(LOG_ERR, "add_interface inter_list.head corrupted: was %p now %p", - listhead, inter_list.head); - exit(1); + endpt ** pmclisthead; + endpt * scan; + endpt * scan_next; + endpt * unlinked; + sockaddr_u * addr; + int ep_local; + int scan_local; + int same_subnet; + int ep_univ_iid; /* iface ID from MAC address */ + int scan_univ_iid; /* see RFC 4291 */ + int ep_privacy; /* random local iface ID */ + int scan_privacy; /* see RFC 4941 */ + int rc; + + /* Calculate the refid */ + ep->addr_refid = addr2refid(&ep->sin); + /* link at tail so ntpdc -c ifstats index increases each row */ + LINK_TAIL_SLIST(ep_list, ep, elink, endpt); + ninterfaces++; +#ifdef MCAST + /* the rest is for enabled multicast-capable addresses only */ + if (ep->ignore_packets || !(INT_MULTICAST & ep->flags) || + INT_LOOPBACK & ep->flags) + return; +# ifndef INCLUDE_IPV6_MULTICAST_SUPPORT + if (AF_INET6 == ep->family) + return; +# endif + pmclisthead = (AF_INET == ep->family) + ? &mc4_list + : &mc6_list; + + if (AF_INET6 == ep->family) { + ep_local = + IN6_IS_ADDR_LINKLOCAL(PSOCK_ADDR6(&ep->sin)) || + IN6_IS_ADDR_SITELOCAL(PSOCK_ADDR6(&ep->sin)); + ep_univ_iid = IS_IID_UNIV(&ep->sin); + ep_privacy = !!(INT_PRIVACY & ep->flags); + } else { + ep_local = FALSE; + ep_univ_iid = FALSE; + ep_privacy = FALSE; } + DPRINTF(4, ("add_interface mcast-capable %s%s%s%s\n", + stoa(&ep->sin), + (ep_local) ? " link/scope-local" : "", + (ep_univ_iid) ? " univ-IID" : "", + (ep_privacy) ? " privacy" : "")); /* - * Calculate the address hash + * If we have multiple local addresses on the same network + * interface, and some are link- or site-local, do not multicast + * out from the link-/site-local addresses by default, to avoid + * duplicate manycastclient associations between v6 peers using + * link-local and global addresses. link-local can still be + * chosen using "nic ignore myv6globalprefix::/64". + * Similarly, if we have multiple global addresses from the same + * prefix on the same network interface, multicast from one, + * preferring EUI-64, then static, then least RFC 4941 privacy + * addresses. */ - interface->addr_refid = addr2refid(&interface->sin); - - ISC_LIST_APPEND(inter_list, interface, link); - ninterfaces++; -} + for (scan = *pmclisthead; scan != NULL; scan = scan_next) { + scan_next = scan->mclink; + if (ep->family != scan->family) + continue; + if (strcmp(ep->name, scan->name)) + continue; + same_subnet = addr_samesubnet(&ep->sin, &ep->mask, + &scan->sin, &scan->mask); + if (AF_INET6 == ep->family) { + addr = &scan->sin; + scan_local = + IN6_IS_ADDR_LINKLOCAL(PSOCK_ADDR6(addr)) || + IN6_IS_ADDR_SITELOCAL(PSOCK_ADDR6(addr)); + scan_univ_iid = IS_IID_UNIV(addr); + scan_privacy = !!(INT_PRIVACY & scan->flags); + } else { + scan_local = FALSE; + scan_univ_iid = FALSE; + scan_privacy = FALSE; + } + DPRINTF(4, ("add_interface mcast-capable scan %s%s%s%s\n", + stoa(&scan->sin), + (scan_local) ? " link/scope-local" : "", + (scan_univ_iid) ? " univ-IID" : "", + (scan_privacy) ? " privacy" : "")); + if ((ep_local && !scan_local) || (same_subnet && + ((ep_privacy && !scan_privacy) || + (!ep_univ_iid && scan_univ_iid)))) { + DPRINTF(4, ("did not add %s to %s of IPv6 multicast-capable list which already has %s\n", + stoa(&ep->sin), + (ep_local) + ? "tail" + : "head", + stoa(&scan->sin))); + return; + } + if ((scan_local && !ep_local) || (same_subnet && + ((scan_privacy && !ep_privacy) || + (!scan_univ_iid && ep_univ_iid)))) { + UNLINK_SLIST(unlinked, *pmclisthead, + scan, mclink, endpt); + DPRINTF(4, ("%s %s from IPv6 multicast-capable list to add %s\n", + (unlinked != scan) + ? "Failed to remove" + : "removed", + stoa(&scan->sin), stoa(&ep->sin))); + } + } + /* + * Add link/site local at the tail of the multicast- + * capable unicast interfaces list, so that ntpd will + * send from global addresses before link-/site-local + * ones. + */ + if (ep_local) + LINK_TAIL_SLIST(*pmclisthead, ep, mclink, endpt); + else + LINK_SLIST(*pmclisthead, ep, mclink); + DPRINTF(4, ("added %s to %s of IPv%s multicast-capable unicast local address list\n", + stoa(&ep->sin), + (ep_local) + ? "tail" + : "head", + (AF_INET == ep->family) + ? "4" + : "6")); + + if (INVALID_SOCKET == ep->fd) + return; + + /* + * select the local address from which to send to multicast. + */ + switch (AF(&ep->sin)) { + + case AF_INET : + rc = setsockopt(ep->fd, IPPROTO_IP, + IP_MULTICAST_IF, + (void *)&NSRCADR(&ep->sin), + sizeof(NSRCADR(&ep->sin))); + if (rc) + msyslog(LOG_ERR, + "setsockopt IP_MULTICAST_IF %s fails: %m", + stoa(&ep->sin)); + break; + +# ifdef INCLUDE_IPV6_MULTICAST_SUPPORT + case AF_INET6 : + rc = setsockopt(ep->fd, IPPROTO_IPV6, + IPV6_MULTICAST_IF, + (void *)&ep->ifindex, + sizeof(ep->ifindex)); + /* do not complain if bound addr scope is ifindex */ + if (rc && ep->ifindex != SCOPE(&ep->sin)) + msyslog(LOG_ERR, + "setsockopt IPV6_MULTICAST_IF %u for %s fails: %m", + ep->ifindex, stoa(&ep->sin)); + break; +# endif + } +#endif /* MCAST */ +} + /* * remove interface from known interface list and clean up * associated resources */ static void -remove_interface(struct interface *interface) +remove_interface( + endpt * ep + ) { - struct sockaddr_storage resmask; - - ISC_LIST_UNLINK_TYPE(inter_list, interface, link, struct interface); - - delete_interface_from_list(interface); - - if (interface->fd != INVALID_SOCKET) - { - msyslog(LOG_INFO, "Deleting interface #%d %s, %s#%d, interface stats: received=%ld, sent=%ld, dropped=%ld, active_time=%ld secs", - interface->ifnum, - interface->name, - stoa((&interface->sin)), - NTP_PORT, /* XXX should extract port from sin structure */ - interface->received, - interface->sent, - interface->notsent, - current_time - interface->starttime); - - close_and_delete_fd_from_list(interface->fd); + endpt * unlinked; + endpt ** pmclisthead; + sockaddr_u resmask; + + UNLINK_SLIST(unlinked, ep_list, ep, elink, endpt); + if (!ep->ignore_packets && INT_MULTICAST & ep->flags) { + pmclisthead = (AF_INET == ep->family) + ? &mc4_list + : &mc6_list; + UNLINK_SLIST(unlinked, *pmclisthead, ep, mclink, endpt); + DPRINTF(4, ("%s %s IPv%s multicast-capable unicast local address list\n", + stoa(&ep->sin), + (unlinked != NULL) + ? "removed from" + : "not found on", + (AF_INET == ep->family) + ? "4" + : "6")); } - - if (interface->bfd != INVALID_SOCKET) - { - msyslog(LOG_INFO, "Deleting interface #%d %s, broadcast address %s#%d", - interface->ifnum, - interface->name, - stoa((&interface->bcast)), - (u_short) NTP_PORT); /* XXX extract port from sin structure */ - close_and_delete_fd_from_list(interface->bfd); + delete_interface_from_list(ep); + + if (ep->fd != INVALID_SOCKET) { + msyslog(LOG_INFO, + "Deleting interface #%d %s, %s#%d, interface stats: received=%ld, sent=%ld, dropped=%ld, active_time=%ld secs", + ep->ifnum, + ep->name, + stoa(&ep->sin), + SRCPORT(&ep->sin), + ep->received, + ep->sent, + ep->notsent, + current_time - ep->starttime); + close_and_delete_fd_from_list(ep->fd); + ep->fd = INVALID_SOCKET; + } + + if (ep->bfd != INVALID_SOCKET) { + msyslog(LOG_INFO, + "stop listening for broadcasts to %s on interface #%d %s", + stoa(&ep->bcast), ep->ifnum, ep->name); + close_and_delete_fd_from_list(ep->bfd); + ep->bfd = INVALID_SOCKET; + ep->flags &= ~INT_BCASTOPEN; } ninterfaces--; - ntp_monclearinterface(interface); + mon_clearinterface(ep); /* remove restrict interface entry */ - - /* - * Blacklist bound interface address - */ - SET_HOSTMASK(&resmask, interface->sin.ss_family); - hack_restrict(RESTRICT_REMOVEIF, &interface->sin, &resmask, - RESM_NTPONLY|RESM_INTERFACE, RES_IGNORE); + SET_HOSTMASK(&resmask, AF(&ep->sin)); + hack_restrict(RESTRICT_REMOVEIF, &ep->sin, &resmask, + RESM_NTPONLY | RESM_INTERFACE, RES_IGNORE, 0); } + static void -list_if_listening(struct interface *interface, u_short port) +log_listen_address( + endpt * ep + ) { - msyslog(LOG_INFO, "Listening on interface #%d %s, %s#%d %s", - interface->ifnum, - interface->name, - stoa((&interface->sin)), - ntohs( (u_short) port), - (interface->ignore_packets == ISC_FALSE) ? - "Enabled": "Disabled"); + msyslog(LOG_INFO, "%s on %d %s %s", + (ep->ignore_packets) + ? "Listen and drop" + : "Listen normally", + ep->ifnum, + ep->name, + sptoa(&ep->sin)); } + static void -create_wildcards(u_short port) { - isc_boolean_t okipv4 = ISC_TRUE; +create_wildcards( + u_short port + ) +{ + int v4wild; +#ifdef INCLUDE_IPV6_SUPPORT + int v6wild; +#endif + sockaddr_u wildaddr; + nic_rule_action action; + struct interface * wildif; + /* - * create pseudo-interface with wildcard IPv4 address + * silence "potentially uninitialized" warnings from VC9 + * failing to follow the logic. Ideally action could remain + * uninitialized, and the memset be the first statement under + * the first if (v4wild). */ -#ifdef IPV6_V6ONLY - if(isc_net_probeipv4() != ISC_R_SUCCESS) - okipv4 = ISC_FALSE; -#endif - - if(okipv4 == ISC_TRUE) { - struct interface *interface = new_interface(NULL); - - interface->family = AF_INET; - interface->sin.ss_family = AF_INET; - ((struct sockaddr_in*)&interface->sin)->sin_addr.s_addr = htonl(INADDR_ANY); - ((struct sockaddr_in*)&interface->sin)->sin_port = port; - (void) strncpy(interface->name, "wildcard", sizeof(interface->name)); - interface->mask.ss_family = AF_INET; - ((struct sockaddr_in*)&interface->mask)->sin_addr.s_addr = htonl(~(u_int32)0); - interface->flags = INT_BROADCAST | INT_UP | INT_WILDCARD; - interface->ignore_packets = ISC_TRUE; -#if defined(MCAST) - /* - * enable possible multicast reception on the broadcast socket - */ - interface->bcast.ss_family = AF_INET; - ((struct sockaddr_in*)&interface->bcast)->sin_port = port; - ((struct sockaddr_in*)&interface->bcast)->sin_addr.s_addr = htonl(INADDR_ANY); -#endif /* MCAST */ - interface->fd = open_socket(&interface->sin, - interface->flags, 1, interface); - - if (interface->fd != INVALID_SOCKET) { - wildipv4 = interface; - any_interface = interface; - - add_addr_to_list(&interface->sin, interface); - add_interface(interface); - list_if_listening(interface, port); + action = ACTION_LISTEN; + ZERO(wildaddr); + +#ifdef INCLUDE_IPV6_SUPPORT + /* + * create pseudo-interface with wildcard IPv6 address + */ + v6wild = ipv6_works; + if (v6wild) { + /* set wildaddr to the v6 wildcard address :: */ + ZERO(wildaddr); + AF(&wildaddr) = AF_INET6; + SET_ADDR6N(&wildaddr, in6addr_any); + SET_PORT(&wildaddr, port); + SET_SCOPE(&wildaddr, 0); + + /* check for interface/nic rules affecting the wildcard */ + action = interface_action(NULL, &wildaddr, 0); + v6wild = (ACTION_IGNORE != action); + } + if (v6wild) { + wildif = new_interface(NULL); + + strlcpy(wildif->name, "v6wildcard", sizeof(wildif->name)); + memcpy(&wildif->sin, &wildaddr, sizeof(wildif->sin)); + wildif->family = AF_INET6; + AF(&wildif->mask) = AF_INET6; + SET_ONESMASK(&wildif->mask); + + wildif->flags = INT_UP | INT_WILDCARD; + wildif->ignore_packets = (ACTION_DROP == action); + + wildif->fd = open_socket(&wildif->sin, 0, 1, wildif); + + if (wildif->fd != INVALID_SOCKET) { + wildipv6 = wildif; + any6_interface = wildif; + add_addr_to_list(&wildif->sin, wildif); + add_interface(wildif); + log_listen_address(wildif); } else { - msyslog(LOG_ERR, "unable to bind to wildcard socket address %s - another process may be running - EXITING", - stoa((&interface->sin))); + msyslog(LOG_ERR, + "unable to bind to wildcard address %s - another process may be running - EXITING", + stoa(&wildif->sin)); exit(1); } + DPRINT_INTERFACE(2, (wildif, "created ", "\n")); } +#endif -#ifdef INCLUDE_IPV6_SUPPORT /* - * create pseudo-interface with wildcard IPv6 address + * create pseudo-interface with wildcard IPv4 address */ - if (isc_net_probeipv6() == ISC_R_SUCCESS) { - struct interface *interface = new_interface(NULL); + v4wild = ipv4_works; + if (v4wild) { + /* set wildaddr to the v4 wildcard address 0.0.0.0 */ + AF(&wildaddr) = AF_INET; + SET_ADDR4N(&wildaddr, INADDR_ANY); + SET_PORT(&wildaddr, port); + + /* check for interface/nic rules affecting the wildcard */ + action = interface_action(NULL, &wildaddr, 0); + v4wild = (ACTION_IGNORE != action); + } + if (v4wild) { + wildif = new_interface(NULL); - interface->family = AF_INET6; - interface->sin.ss_family = AF_INET6; - ((struct sockaddr_in6*)&interface->sin)->sin6_addr = in6addr_any; - ((struct sockaddr_in6*)&interface->sin)->sin6_port = port; -# ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)&interface->sin)->sin6_scope_id = 0; -# endif - (void) strncpy(interface->name, "wildcard", sizeof(interface->name)); - interface->mask.ss_family = AF_INET6; - memset(&((struct sockaddr_in6*)&interface->mask)->sin6_addr.s6_addr, 0xff, sizeof(struct in6_addr)); - interface->flags = INT_UP | INT_WILDCARD; - interface->ignore_packets = ISC_TRUE; + strlcpy(wildif->name, "v4wildcard", sizeof(wildif->name)); + memcpy(&wildif->sin, &wildaddr, sizeof(wildif->sin)); + wildif->family = AF_INET; + AF(&wildif->mask) = AF_INET; + SET_ONESMASK(&wildif->mask); - interface->fd = open_socket(&interface->sin, - interface->flags, 1, interface); - - if (interface->fd != INVALID_SOCKET) { - wildipv6 = interface; - any6_interface = interface; - add_addr_to_list(&interface->sin, interface); - add_interface(interface); - list_if_listening(interface, port); + wildif->flags = INT_BROADCAST | INT_UP | INT_WILDCARD; + wildif->ignore_packets = (ACTION_DROP == action); +#if defined(MCAST) + /* + * enable multicast reception on the broadcast socket + */ + AF(&wildif->bcast) = AF_INET; + SET_ADDR4N(&wildif->bcast, INADDR_ANY); + SET_PORT(&wildif->bcast, port); +#endif /* MCAST */ + wildif->fd = open_socket(&wildif->sin, 0, 1, wildif); + + if (wildif->fd != INVALID_SOCKET) { + wildipv4 = wildif; + any_interface = wildif; + + add_addr_to_list(&wildif->sin, wildif); + add_interface(wildif); + log_listen_address(wildif); } else { - msyslog(LOG_ERR, "unable to bind to wildcard socket address %s - another process may be running - EXITING", - stoa((&interface->sin))); + msyslog(LOG_ERR, + "unable to bind to wildcard address %s - another process may be running - EXITING", + stoa(&wildif->sin)); exit(1); } + DPRINT_INTERFACE(2, (wildif, "created ", "\n")); } -#endif } -static isc_boolean_t -address_okay(struct interface *iface) { +/* + * add_nic_rule() -- insert a rule entry at the head of nic_rule_list. + */ +void +add_nic_rule( + nic_rule_match match_type, + const char * if_name, /* interface name or numeric address */ + int prefixlen, + nic_rule_action action + ) +{ + nic_rule * rule; + isc_boolean_t is_ip; + + rule = emalloc_zero(sizeof(*rule)); + rule->match_type = match_type; + rule->prefixlen = prefixlen; + rule->action = action; + + if (MATCH_IFNAME == match_type) { + REQUIRE(NULL != if_name); + rule->if_name = estrdup(if_name); + } else if (MATCH_IFADDR == match_type) { + REQUIRE(NULL != if_name); + /* set rule->addr */ + is_ip = is_ip_address(if_name, AF_UNSPEC, &rule->addr); + REQUIRE(is_ip); + } else + REQUIRE(NULL == if_name); + + LINK_SLIST(nic_rule_list, rule, next); +} - DPRINTF(4, ("address_okay: listen Virtual: %d, IF name: %s\n", - listen_to_virtual_ips, iface->name)); + +#ifdef DEBUG +static const char * +action_text( + nic_rule_action action + ) +{ + const char *t; + + switch (action) { + + default: + t = "ERROR"; /* quiet uninit warning */ + DPRINTF(1, ("fatal: unknown nic_rule_action %d\n", + action)); + ENSURE(0); + break; + + case ACTION_LISTEN: + t = "listen"; + break; + + case ACTION_IGNORE: + t = "ignore"; + break; + + case ACTION_DROP: + t = "drop"; + break; + } + + return t; +} +#endif /* DEBUG */ + + +static nic_rule_action +interface_action( + char * if_name, + sockaddr_u * if_addr, + u_int32 if_flags + ) +{ + nic_rule * rule; + int isloopback; + int iswildcard; + + DPRINTF(4, ("interface_action: interface %s ", + (if_name != NULL) ? if_name : "wildcard")); + + iswildcard = is_wildcard_addr(if_addr); + isloopback = !!(INT_LOOPBACK & if_flags); /* - * Always allow the loopback + * Find any matching NIC rule from --interface / -I or ntp.conf + * interface/nic rules. */ - if((iface->flags & INT_LOOPBACK) != 0) { - DPRINTF(4, ("address_okay: loopback - OK\n")); - return (ISC_TRUE); + for (rule = nic_rule_list; rule != NULL; rule = rule->next) { + + switch (rule->match_type) { + + case MATCH_ALL: + /* loopback and wildcard excluded from "all" */ + if (isloopback || iswildcard) + break; + DPRINTF(4, ("nic all %s\n", + action_text(rule->action))); + return rule->action; + + case MATCH_IPV4: + if (IS_IPV4(if_addr)) { + DPRINTF(4, ("nic ipv4 %s\n", + action_text(rule->action))); + return rule->action; + } + break; + + case MATCH_IPV6: + if (IS_IPV6(if_addr)) { + DPRINTF(4, ("nic ipv6 %s\n", + action_text(rule->action))); + return rule->action; + } + break; + + case MATCH_WILDCARD: + if (iswildcard) { + DPRINTF(4, ("nic wildcard %s\n", + action_text(rule->action))); + return rule->action; + } + break; + + case MATCH_IFADDR: + if (rule->prefixlen != -1) { + if (addr_eqprefix(if_addr, &rule->addr, + rule->prefixlen)) { + + DPRINTF(4, ("subnet address match - %s\n", + action_text(rule->action))); + return rule->action; + } + } else + if (SOCK_EQ(if_addr, &rule->addr)) { + + DPRINTF(4, ("address match - %s\n", + action_text(rule->action))); + return rule->action; + } + break; + + case MATCH_IFNAME: + if (if_name != NULL +#if defined(HAVE_FNMATCH) && defined(FNM_CASEFOLD) + && !fnmatch(rule->if_name, if_name, FNM_CASEFOLD) +#else + && !strcasecmp(if_name, rule->if_name) +#endif + ) { + + DPRINTF(4, ("interface name match - %s\n", + action_text(rule->action))); + return rule->action; + } + break; + } } /* - * Check if the interface is specified + * Unless explicitly disabled such as with "nic ignore ::1" + * listen on loopback addresses. Since ntpq and ntpdc query + * "localhost" by default, which typically resolves to ::1 and + * 127.0.0.1, it's useful to default to listening on both. */ - if (specific_interface != NULL) { - if (strcasecmp(iface->name, specific_interface) == 0) { - DPRINTF(4, ("address_okay: specific interface name matched - OK\n")); - return (ISC_TRUE); - } else { - DPRINTF(4, ("address_okay: specific interface name NOT matched - FAIL\n")); - return (ISC_FALSE); - } + if (isloopback) { + DPRINTF(4, ("default loopback listen\n")); + return ACTION_LISTEN; } - else { - if (listen_to_virtual_ips == 0 && - (strchr(iface->name, (int)':') != NULL)) { - DPRINTF(4, ("address_okay: virtual ip/alias - FAIL\n")); - return (ISC_FALSE); - } + + /* + * Treat wildcard addresses specially. If there is no explicit + * "nic ... wildcard" or "nic ... 0.0.0.0" or "nic ... ::" rule + * default to drop. + */ + if (iswildcard) { + DPRINTF(4, ("default wildcard drop\n")); + return ACTION_DROP; } - DPRINTF(4, ("address_okay: OK\n")); - return (ISC_TRUE); + /* + * Check for "virtual IP" (colon in the interface name) after + * the rules so that "ntpd --interface eth0:1 -novirtualips" + * does indeed listen on eth0:1's addresses. + */ + if (!listen_to_virtual_ips && if_name != NULL + && (strchr(if_name, ':') != NULL)) { + + DPRINTF(4, ("virtual ip - ignore\n")); + return ACTION_IGNORE; + } + + /* + * If there are no --interface/-I command-line options and no + * interface/nic rules in ntp.conf, the default action is to + * listen. In the presence of rules from either, the default + * is to ignore. This implements ntpd's traditional listen- + * every default with no interface listen configuration, and + * ensures a single -I eth0 or "nic listen eth0" means do not + * listen on any other addresses. + */ + if (NULL == nic_rule_list) { + DPRINTF(4, ("default listen\n")); + return ACTION_LISTEN; + } + + DPRINTF(4, ("implicit ignore\n")); + return ACTION_IGNORE; } + static void -convert_isc_if(isc_interface_t *isc_if, struct interface *itf, u_short port) +convert_isc_if( + isc_interface_t *isc_if, + endpt *itf, + u_short port + ) { - itf->scopeid = 0; - itf->family = (short) isc_if->af; - strcpy(itf->name, isc_if->name); - - if(isc_if->af == AF_INET) { - itf->sin.ss_family = (u_short) isc_if->af; - memcpy(&(((struct sockaddr_in*)&itf->sin)->sin_addr), - &(isc_if->address.type.in), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&itf->sin)->sin_port = port; - - if((isc_if->flags & INTERFACE_F_BROADCAST) != 0) { + const u_char v6loop[16] = {0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1}; + + strlcpy(itf->name, isc_if->name, sizeof(itf->name)); + itf->ifindex = isc_if->ifindex; + itf->family = (u_short)isc_if->af; + AF(&itf->sin) = itf->family; + AF(&itf->mask) = itf->family; + AF(&itf->bcast) = itf->family; + SET_PORT(&itf->sin, port); + SET_PORT(&itf->mask, port); + SET_PORT(&itf->bcast, port); + + if (IS_IPV4(&itf->sin)) { + NSRCADR(&itf->sin) = isc_if->address.type.in.s_addr; + NSRCADR(&itf->mask) = isc_if->netmask.type.in.s_addr; + + if (isc_if->flags & INTERFACE_F_BROADCAST) { itf->flags |= INT_BROADCAST; - itf->bcast.ss_family = itf->sin.ss_family; - memcpy(&(((struct sockaddr_in*)&itf->bcast)->sin_addr), - &(isc_if->broadcast.type.in), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&itf->bcast)->sin_port = port; + NSRCADR(&itf->bcast) = + isc_if->broadcast.type.in.s_addr; } - - itf->mask.ss_family = itf->sin.ss_family; - memcpy(&(((struct sockaddr_in*)&itf->mask)->sin_addr), - &(isc_if->netmask.type.in), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&itf->mask)->sin_port = port; } #ifdef INCLUDE_IPV6_SUPPORT - else if (isc_if->af == AF_INET6) { - itf->sin.ss_family = (u_short) isc_if->af; - memcpy(&(((struct sockaddr_in6 *)&itf->sin)->sin6_addr), - &(isc_if->address.type.in6), - sizeof(((struct sockaddr_in6 *)&itf->sin)->sin6_addr)); - ((struct sockaddr_in6 *)&itf->sin)->sin6_port = port; - -#ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6 *)&itf->sin)->sin6_scope_id = isc_netaddr_getzone(&isc_if->address); - itf->scopeid = isc_netaddr_getzone(&isc_if->address); -#endif - itf->mask.ss_family = itf->sin.ss_family; - memcpy(&(((struct sockaddr_in6 *)&itf->mask)->sin6_addr), - &(isc_if->netmask.type.in6), - sizeof(struct in6_addr)); - ((struct sockaddr_in6 *)&itf->mask)->sin6_port = port; - /* Copy the interface index */ - itf->ifindex = isc_if->ifindex; + else if (IS_IPV6(&itf->sin)) { + SET_ADDR6N(&itf->sin, isc_if->address.type.in6); + SET_ADDR6N(&itf->mask, isc_if->netmask.type.in6); + + SET_SCOPE(&itf->sin, isc_if->address.zone); } #endif /* INCLUDE_IPV6_SUPPORT */ /* Process the rest of the flags */ - if((isc_if->flags & INTERFACE_F_UP) != 0) - itf->flags |= INT_UP; - if((isc_if->flags & INTERFACE_F_LOOPBACK) != 0) - itf->flags |= INT_LOOPBACK; - if((isc_if->flags & INTERFACE_F_POINTTOPOINT) != 0) - itf->flags |= INT_PPP; - if((isc_if->flags & INTERFACE_F_MULTICAST) != 0) - itf->flags |= INT_MULTICAST; + itf->flags |= + ((INTERFACE_F_UP & isc_if->flags) + ? INT_UP : 0) + | ((INTERFACE_F_LOOPBACK & isc_if->flags) + ? INT_LOOPBACK : 0) + | ((INTERFACE_F_POINTTOPOINT & isc_if->flags) + ? INT_PPP : 0) + | ((INTERFACE_F_MULTICAST & isc_if->flags) + ? INT_MULTICAST : 0) + | ((INTERFACE_F_PRIVACY & isc_if->flags) + ? INT_PRIVACY : 0) + ; + /* + * Clear the loopback flag if the address is not localhost. + * http://bugs.ntp.org/1683 + */ + if (INT_LOOPBACK & itf->flags) { + if (AF_INET == itf->family) { + if (127 != (SRCADR(&itf->sin) >> 24)) + itf->flags &= ~INT_LOOPBACK; + } else { + if (memcmp(v6loop, NSRCADR6(&itf->sin), + sizeof(NSRCADR6(&itf->sin)))) + itf->flags &= ~INT_LOOPBACK; + } + } } + /* * refresh_interface * @@ -1057,27 +1525,34 @@ convert_isc_if(isc_interface_t *isc_if, struct interface *itf, u_short port) * the socket. */ static int -refresh_interface(struct interface * interface) +refresh_interface( + struct interface * interface + ) { #ifdef OS_MISSES_SPECIFIC_ROUTE_UPDATES - if (interface->fd != INVALID_SOCKET) - { + if (interface->fd != INVALID_SOCKET) { + int bcast = (interface->flags & INT_BCASTXMIT) != 0; + /* as we forcibly close() the socket remove the + broadcast permission indication */ + if (bcast) + socket_broadcast_disable(interface, &interface->sin); + close_and_delete_fd_from_list(interface->fd); + + /* create new socket picking up a new first hop binding + at connect() time */ interface->fd = open_socket(&interface->sin, - interface->flags, 0, interface); + bcast, 0, interface); /* - * reset TTL indication so TTL is is set again + * reset TTL indication so TTL is is set again * next time around */ interface->last_ttl = 0; - return interface->fd != INVALID_SOCKET; - } - else - { + return (interface->fd != INVALID_SOCKET); + } else return 0; /* invalid sockets are not refreshable */ - } #else /* !OS_MISSES_SPECIFIC_ROUTE_UPDATES */ - return interface->fd != INVALID_SOCKET; + return (interface->fd != INVALID_SOCKET); #endif /* !OS_MISSES_SPECIFIC_ROUTE_UPDATES */ } @@ -1085,124 +1560,167 @@ refresh_interface(struct interface * interface) * interface_update - externally callable update function */ void -interface_update(interface_receiver_t receiver, void *data) +interface_update( + interface_receiver_t receiver, + void * data) { - if (!disable_dynamic_updates) { - int new_interface_found; + int new_interface_found; - BLOCKIO(); - new_interface_found = update_interfaces(htons(NTP_PORT), receiver, data); - UNBLOCKIO(); + if (disable_dynamic_updates) + return; + + BLOCKIO(); + new_interface_found = update_interfaces(NTP_PORT, receiver, data); + UNBLOCKIO(); + + if (!new_interface_found) + return; - if (new_interface_found) { #ifdef DEBUG - msyslog(LOG_DEBUG, "new interface(s) found: waking up resolver"); -#endif -#ifdef SYS_WINNT - /* wake up the resolver thread */ - if (ResolverEventHandle != NULL) - SetEvent(ResolverEventHandle); -#else - /* write any single byte to the pipe to wake up the resolver process */ - write( resolver_pipe_fd[1], &new_interface_found, 1 ); + msyslog(LOG_DEBUG, "new interface(s) found: waking up resolver"); #endif - } - } + interrupt_worker_sleep(); } + /* - * find out if a given interface structure contains - * a wildcard address + * sau_from_netaddr() - convert network address on-wire formats. + * Convert from libisc's isc_netaddr_t to NTP's sockaddr_u */ +void +sau_from_netaddr( + sockaddr_u *psau, + const isc_netaddr_t *pna + ) +{ + ZERO_SOCK(psau); + AF(psau) = (u_short)pna->family; + switch (pna->family) { + + case AF_INET: + memcpy(&psau->sa4.sin_addr, &pna->type.in, + sizeof(psau->sa4.sin_addr)); + break; + + case AF_INET6: + memcpy(&psau->sa6.sin6_addr, &pna->type.in6, + sizeof(psau->sa6.sin6_addr)); + break; + } +} + + static int -is_wildcard_addr(struct sockaddr_storage *sas) +is_wildcard_addr( + const sockaddr_u *psau + ) { - if (sas->ss_family == AF_INET && - ((struct sockaddr_in*)sas)->sin_addr.s_addr == htonl(INADDR_ANY)) + if (IS_IPV4(psau) && !NSRCADR(psau)) return 1; #ifdef INCLUDE_IPV6_SUPPORT - if (sas->ss_family == AF_INET6 && - memcmp(&((struct sockaddr_in6*)sas)->sin6_addr, &in6addr_any, - sizeof(in6addr_any) == 0)) + if (IS_IPV6(psau) && S_ADDR6_EQ(psau, &in6addr_any)) return 1; #endif return 0; } + #ifdef OS_NEEDS_REUSEADDR_FOR_IFADDRBIND /* * enable/disable re-use of wildcard address socket */ static void -set_wildcard_reuse(int family, int on) +set_wildcard_reuse( + u_short family, + int on + ) { - int onvalue = 1; - int offvalue = 0; - int *onoff; + struct interface *any; SOCKET fd = INVALID_SOCKET; - onoff = on ? &onvalue : &offvalue; - - switch (family) { - case AF_INET: - if (any_interface) { - fd = any_interface->fd; - } - break; - -#ifdef INCLUDE_IPV6_SUPPORT - case AF_INET6: - if (any6_interface) { - fd = any6_interface->fd; - } - break; -#endif /* !INCLUDE_IPV6_SUPPORT */ - } + any = ANY_INTERFACE_BYFAM(family); + if (any != NULL) + fd = any->fd; if (fd != INVALID_SOCKET) { - if (setsockopt(fd, SOL_SOCKET, - SO_REUSEADDR, (char *)onoff, - sizeof(*onoff))) { - netsyslog(LOG_ERR, "set_wildcard_reuse: setsockopt(SO_REUSEADDR, %s) failed: %m", *onoff ? "on" : "off"); - } - DPRINTF(4, ("set SO_REUSEADDR to %s on %s\n", *onoff ? "ON" : "OFF", - stoa((family == AF_INET) ? - &any_interface->sin : &any6_interface->sin))); + if (setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, + (char *)&on, sizeof(on))) + msyslog(LOG_ERR, + "set_wildcard_reuse: setsockopt(SO_REUSEADDR, %s) failed: %m", + on ? "on" : "off"); + + DPRINTF(4, ("set SO_REUSEADDR to %s on %s\n", + on ? "on" : "off", + stoa(&any->sin))); } } #endif /* OS_NEEDS_REUSEADDR_FOR_IFADDRBIND */ -#ifdef INCLUDE_IPV6_SUPPORT + static isc_boolean_t -is_anycast(struct sockaddr *sa, char *name) +check_flags6( + sockaddr_u *psau, + const char *name, + u_int32 flags6 + ) { -#if defined(SIOCGIFAFLAG_IN6) && defined(IN6_IFF_ANYCAST) +#if defined(INCLUDE_IPV6_SUPPORT) && defined(SIOCGIFAFLAG_IN6) struct in6_ifreq ifr6; int fd; - u_int32_t flags6; - if (sa->sa_family != AF_INET6) + if (psau->sa.sa_family != AF_INET6) return ISC_FALSE; if ((fd = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) return ISC_FALSE; - memset(&ifr6, 0, sizeof(ifr6)); - memcpy(&ifr6.ifr_addr, (struct sockaddr_in6 *)sa, - sizeof(struct sockaddr_in6)); - strlcpy(ifr6.ifr_name, name, IF_NAMESIZE); + ZERO(ifr6); + memcpy(&ifr6.ifr_addr, &psau->sa6, sizeof(ifr6.ifr_addr)); + strlcpy(ifr6.ifr_name, name, sizeof(ifr6.ifr_name)); if (ioctl(fd, SIOCGIFAFLAG_IN6, &ifr6) < 0) { close(fd); return ISC_FALSE; } close(fd); - flags6 = ifr6.ifr_ifru.ifru_flags6; - if ((flags6 & IN6_IFF_ANYCAST) != 0) + if ((ifr6.ifr_ifru.ifru_flags6 & flags6) != 0) return ISC_TRUE; -#endif /* !SIOCGIFAFLAG_IN6 || !IN6_IFF_ANYCAST */ +#endif /* INCLUDE_IPV6_SUPPORT && SIOCGIFAFLAG_IN6 */ + return ISC_FALSE; +} + +static isc_boolean_t +is_anycast( + sockaddr_u *psau, + const char *name + ) +{ +#ifdef IN6_IFF_ANYCAST + return check_flags6(psau, name, IN6_IFF_ANYCAST); +#else return ISC_FALSE; +#endif +} + +static isc_boolean_t +is_valid( + sockaddr_u *psau, + const char *name + ) +{ + u_int32 flags6; + + flags6 = 0; +#ifdef IN6_IFF_DEPARTED + flags6 |= IN6_IFF_DEPARTED; +#endif +#ifdef IN6_IFF_DETACHED + flags6 |= IN6_IFF_DETACHED; +#endif +#ifdef IN6_IFF_TENTATIVE + flags6 |= IN6_IFF_TENTATIVE; +#endif + return check_flags6(psau, name, flags6) ? ISC_FALSE : ISC_TRUE; } -#endif /* !INCLUDE_IPV6_SUPPORT */ /* * update_interface strategy @@ -1212,17 +1730,17 @@ is_anycast(struct sockaddr *sa, char *name) * Phase 1: * forall currently existing interfaces * if address is known: - * drop socket - rebind again + * drop socket - rebind again * * if address is NOT known: - * attempt to create a new interface entry + * attempt to create a new interface entry * * Phase 2: * forall currently known non MCAST and WILDCARD interfaces * if interface does not match configuration phase (not seen in phase 1): - * remove interface from known interface list - * forall peers associated with this interface - * disconnect peer from this interface + * remove interface from known interface list + * forall peers associated with this interface + * disconnect peer from this interface * * Phase 3: * attempt to re-assign interfaces to peers @@ -1231,67 +1749,47 @@ is_anycast(struct sockaddr *sa, char *name) static int update_interfaces( - u_short port, - interface_receiver_t receiver, - void *data + u_short port, + interface_receiver_t receiver, + void * data ) { - interface_info_t ifi; - isc_mem_t *mctx = NULL; - isc_interfaceiter_t *iter = NULL; - isc_boolean_t scan_ipv4 = ISC_FALSE; - isc_boolean_t scan_ipv6 = ISC_FALSE; - isc_result_t result; - int new_interface_found = 0; - - DPRINTF(3, ("update_interfaces(%d)\n", ntohs( (u_short) port))); + isc_mem_t * mctx = (void *)-1; + interface_info_t ifi; + isc_interfaceiter_t * iter; + isc_result_t result; + isc_interface_t isc_if; + int new_interface_found; + unsigned int family; + endpt enumep; + endpt * ep; + endpt * next_ep; + + DPRINTF(3, ("update_interfaces(%d)\n", port)); -#ifdef INCLUDE_IPV6_SUPPORT - if (isc_net_probeipv6() == ISC_R_SUCCESS) - scan_ipv6 = ISC_TRUE; -#if defined(DEBUG) - else - if (debug) - netsyslog(LOG_ERR, "no IPv6 interfaces found"); -#endif -#endif - if (isc_net_probeipv6() == ISC_R_SUCCESS) - scan_ipv6 = ISC_TRUE; -#if defined(ISC_PLATFORM_HAVEIPV6) && defined(DEBUG) - else - if (debug) - netsyslog(LOG_ERR, "no IPv6 interfaces found"); -#endif - - if (isc_net_probeipv4() == ISC_R_SUCCESS) - scan_ipv4 = ISC_TRUE; -#ifdef DEBUG - else - if(debug) - netsyslog(LOG_ERR, "no IPv4 interfaces found"); -#endif /* * phase one - scan interfaces * - create those that are not found * - update those that are found */ + new_interface_found = FALSE; + iter = NULL; result = isc_interfaceiter_create(mctx, &iter); if (result != ISC_R_SUCCESS) return 0; - sys_interphase ^= 0x1; /* toggle system phase for finding untouched (to be deleted) interfaces */ - + /* + * Toggle system interface scan phase to find untouched + * interfaces to be deleted. + */ + sys_interphase ^= 0x1; + for (result = isc_interfaceiter_first(iter); - result == ISC_R_SUCCESS; - result = isc_interfaceiter_next(iter)) - { - isc_interface_t isc_if; - unsigned int family; - struct interface interface; - struct interface *iface; - + ISC_R_SUCCESS == result; + result = isc_interfaceiter_next(iter)) { + result = isc_interfaceiter_current(iter, &isc_if); if (result != ISC_R_SUCCESS) @@ -1299,39 +1797,48 @@ update_interfaces( /* See if we have a valid family to use */ family = isc_if.address.family; - if (family != AF_INET && family != AF_INET6) + if (AF_INET != family && AF_INET6 != family) continue; - if (scan_ipv4 == ISC_FALSE && family == AF_INET) + if (AF_INET == family && !ipv4_works) continue; - if (scan_ipv6 == ISC_FALSE && family == AF_INET6) + if (AF_INET6 == family && !ipv6_works) continue; + /* create prototype */ + init_interface(&enumep); + + convert_isc_if(&isc_if, &enumep, port); + + DPRINT_INTERFACE(4, (&enumep, "examining ", "\n")); + /* - * create prototype + * Check if and how we are going to use the interface. */ - init_interface(&interface); + switch (interface_action(enumep.name, &enumep.sin, + enumep.flags)) { - convert_isc_if(&isc_if, &interface, port); + case ACTION_IGNORE: + DPRINTF(4, ("ignoring interface %s (%s) - by nic rules\n", + enumep.name, stoa(&enumep.sin))); + continue; - /* - * Check to see if we are going to use the interface - * If we don't use it we mark it to drop any packet - * received but we still must create the socket and - * bind to it. This prevents other apps binding to it - * and potentially causing problems with more than one - * process fiddling with the clock - */ - if (address_okay(&interface) == ISC_TRUE) { - interface.ignore_packets = ISC_FALSE; - } - else { - interface.ignore_packets = ISC_TRUE; - } + case ACTION_LISTEN: + DPRINTF(4, ("listen interface %s (%s) - by nic rules\n", + enumep.name, stoa(&enumep.sin))); + enumep.ignore_packets = ISC_FALSE; + break; - DPRINT_INTERFACE(4, (&interface, "examining ", "\n")); + case ACTION_DROP: + DPRINTF(4, ("drop on interface %s (%s) - by nic rules\n", + enumep.name, stoa(&enumep.sin))); + enumep.ignore_packets = ISC_TRUE; + break; + } - if (!(interface.flags & INT_UP)) { /* interfaces must be UP to be usable */ - DPRINTF(4, ("skipping interface %s (%s) - DOWN\n", interface.name, stoa(&interface.sin))); + /* interfaces must be UP to be usable */ + if (!(enumep.flags & INT_UP)) { + DPRINTF(4, ("skipping interface %s (%s) - DOWN\n", + enumep.name, stoa(&enumep.sin))); continue; } @@ -1340,62 +1847,119 @@ update_interfaces( * address - some dhcp clients produce that in the * wild */ - if (is_wildcard_addr(&interface.sin)) + if (is_wildcard_addr(&enumep.sin)) continue; -#ifdef INCLUDE_IPV6_SUPPORT - if (is_anycast((struct sockaddr *)&interface.sin, isc_if.name)) + if (is_anycast(&enumep.sin, isc_if.name)) continue; -#endif /* !INCLUDE_IPV6_SUPPORT */ /* - * map to local *address* in order - * to map all duplicate interfaces to an interface structure - * with the appropriate socket (our name space is - * (ip-address) - NOT (interface name, ip-address)) + * skip any address that is an invalid state to be used */ - iface = getinterface(&interface.sin, INT_WILDCARD); - - if (iface && refresh_interface(iface)) - { + if (!is_valid(&enumep.sin, isc_if.name)) + continue; + + /* + * map to local *address* in order to map all duplicate + * interfaces to an endpt structure with the appropriate + * socket. Our name space is (ip-address), NOT + * (interface name, ip-address). + */ + ep = getinterface(&enumep.sin, INT_WILDCARD); + + if (ep != NULL && refresh_interface(ep)) { /* - * found existing and up to date interface - mark present + * found existing and up to date interface - + * mark present. */ + if (ep->phase != sys_interphase) { + /* + * On a new round we reset the name so + * the interface name shows up again if + * this address is no longer shared. + * We reset ignore_packets from the + * new prototype to respect any runtime + * changes to the nic rules. + */ + strlcpy(ep->name, enumep.name, + sizeof(ep->name)); + ep->ignore_packets = + enumep.ignore_packets; + } else { + /* name collision - rename interface */ + strlcpy(ep->name, "*multiple*", + sizeof(ep->name)); + } + + DPRINT_INTERFACE(4, (ep, "updating ", + " present\n")); + + if (ep->ignore_packets != + enumep.ignore_packets) { + /* + * We have conflicting configurations + * for the interface address. This is + * caused by using -I + * for an interface that shares its + * address with other interfaces. We + * can not disambiguate incoming + * packets delivered to this socket + * without extra syscalls/features. + * These are not (commonly) available. + * Note this is a more unusual + * configuration where several + * interfaces share an address but + * filtering via interface name is + * attempted. We resolve the + * configuration conflict by disabling + * the processing of received packets. + * This leads to no service on the + * interface address where the conflict + * occurs. + */ + msyslog(LOG_ERR, + "WARNING: conflicting enable configuration for interfaces %s and %s for address %s - unsupported configuration - address DISABLED", + enumep.name, ep->name, + stoa(&enumep.sin)); + + ep->ignore_packets = ISC_TRUE; + } + + ep->phase = sys_interphase; - iface->phase = sys_interphase; - DPRINT_INTERFACE(4, (iface, "updating ", " present\n")); ifi.action = IFS_EXISTS; - ifi.interface = iface; - if (receiver) - receiver(data, &ifi); - } - else - { + ifi.ep = ep; + if (receiver != NULL) + (*receiver)(data, &ifi); + } else { /* - * this is new or refreshing failed - add to our interface list - * if refreshing failed we will delete the interface structure in - * phase 2 as the interface was not marked current. We can bind to - * the address as the refresh code already closed the offending socket + * This is new or refreshing failed - add to + * our interface list. If refreshing failed we + * will delete the interface structure in phase + * 2 as the interface was not marked current. + * We can bind to the address as the refresh + * code already closed the offending socket */ - - iface = create_interface(port, &interface); + ep = create_interface(port, &enumep); - if (iface) - { + if (ep != NULL) { ifi.action = IFS_CREATED; - ifi.interface = iface; - if (receiver) - receiver(data, &ifi); - - new_interface_found = 1; - - DPRINT_INTERFACE(3, (iface, "updating ", " new - created\n")); - } - else - { - DPRINT_INTERFACE(3, (&interface, "updating ", " new - creation FAILED")); - - msyslog(LOG_INFO, "failed to initialize interface for address %s", stoa(&interface.sin)); + ifi.ep = ep; + if (receiver != NULL) + (*receiver)(data, &ifi); + + new_interface_found = TRUE; + DPRINT_INTERFACE(3, + (ep, "updating ", + " new - created\n")); + } else { + DPRINT_INTERFACE(3, + (&enumep, "updating ", + " new - creation FAILED")); + + msyslog(LOG_INFO, + "failed to init interface for address %s", + stoa(&enumep.sin)); continue; } } @@ -1404,64 +1968,88 @@ update_interfaces( isc_interfaceiter_destroy(&iter); /* - * phase 2 - delete gone interfaces - reassigning peers to other interfaces + * phase 2 - delete gone interfaces - reassigning peers to + * other interfaces */ - { - struct interface *interf = ISC_LIST_HEAD(inter_list); + for (ep = ep_list; ep != NULL; ep = next_ep) { + next_ep = ep->elink; - while (interf != NULL) - { - struct interface *next = ISC_LIST_NEXT(interf, link); - - if (!(interf->flags & (INT_WILDCARD|INT_MCASTIF))) { - /* - * if phase does not match sys_phase this interface was not - * enumerated during interface scan - so it is gone and - * will be deleted here unless it is solely an MCAST/WILDCARD interface - */ - if (interf->phase != sys_interphase) { - struct peer *peer; - DPRINT_INTERFACE(3, (interf, "updating ", "GONE - deleting\n")); - remove_interface(interf); - - ifi.action = IFS_DELETED; - ifi.interface = interf; - if (receiver) - receiver(data, &ifi); - - peer = ISC_LIST_HEAD(interf->peers); - /* - * disconnect peer from deleted interface - */ - while (peer != NULL) { - struct peer *npeer = ISC_LIST_NEXT(peer, ilink); - - /* - * this one just lost it's interface - */ - set_peerdstadr(peer, NULL); - - peer = npeer; - } - - /* - * update globals in case we lose - * a loopback interface - */ - if (interf == loopback_interface) - loopback_interface = NULL; - - delete_interface(interf); - } - } - interf = next; - } + /* + * if phase does not match sys_phase this interface was + * not enumerated during the last interface scan - so it + * is gone and will be deleted here unless it did not + * originate from interface enumeration (INT_WILDCARD, + * INT_MCASTIF). + */ + if (((INT_WILDCARD | INT_MCASTIF) & ep->flags) || + ep->phase == sys_interphase) + continue; + + DPRINT_INTERFACE(3, (ep, "updating ", + "GONE - deleting\n")); + remove_interface(ep); + + ifi.action = IFS_DELETED; + ifi.ep = ep; + if (receiver != NULL) + (*receiver)(data, &ifi); + + /* disconnect peers from deleted endpt. */ + while (ep->peers != NULL) + set_peerdstadr(ep->peers, NULL); + + /* + * update globals in case we lose + * a loopback interface + */ + if (ep == loopback_interface) + loopback_interface = NULL; + + delete_interface(ep); } /* - * phase 3 - re-configure as the world has changed if necessary + * phase 3 - re-configure as the world has possibly changed + * + * never ever make this conditional again - it is needed to track + * routing updates. see bug #2506 */ refresh_all_peerinterfaces(); + + if (broadcast_client_enabled) + io_setbclient(); + + if (sys_bclient) + io_setbclient(); + +#ifdef MCAST + /* + * Check multicast interfaces and try to join multicast groups if + * not joined yet. + */ + for (ep = ep_list; ep != NULL; ep = ep->elink) { + remaddr_t *entry; + + if (!(INT_MCASTIF & ep->flags) || (INT_MCASTOPEN & ep->flags)) + continue; + + /* Find remote address that was linked to this interface */ + for (entry = remoteaddr_list; + entry != NULL; + entry = entry->link) { + if (entry->ep == ep) { + if (socket_multicast_enable(ep, &entry->addr)) { + msyslog(LOG_INFO, + "Joined %s socket to multicast group %s", + stoa(&ep->sin), + stoa(&entry->addr)); + } + break; + } + } + } +#endif /* MCAST */ + return new_interface_found; } @@ -1483,12 +2071,12 @@ create_sockets( FD_ZERO(&activefds); #endif - DPRINTF(2, ("create_sockets(%d)\n", ntohs( (u_short) port))); + DPRINTF(2, ("create_sockets(%d)\n", port)); create_wildcards(port); update_interfaces(port, NULL, NULL); - + /* * Now that we have opened all the sockets, turn off the reuse * flag for security. @@ -1506,87 +2094,137 @@ create_sockets( */ static struct interface * create_interface( - u_short port, - struct interface *iface - ) + u_short port, + struct interface * protot + ) { - struct sockaddr_storage resmask; - struct interface *interface; - - DPRINTF(2, ("create_interface(%s#%d)\n", stoa(&iface->sin), ntohs( (u_short) port))); + sockaddr_u resmask; + endpt * iface; +#if defined(MCAST) && defined(MULTICAST_NONEWSOCKET) + remaddr_t * entry; + remaddr_t * next_entry; +#endif + DPRINTF(2, ("create_interface(%s#%d)\n", stoa(&protot->sin), + port)); /* build an interface */ - interface = new_interface(iface); - + iface = new_interface(protot); + /* * create socket */ - interface->fd = open_socket(&interface->sin, - interface->flags, 0, interface); + iface->fd = open_socket(&iface->sin, 0, 0, iface); - if (interface->fd != INVALID_SOCKET) - list_if_listening(interface, port); + if (iface->fd != INVALID_SOCKET) + log_listen_address(iface); - if ((interface->flags & INT_BROADCAST) && - interface->bfd != INVALID_SOCKET) - msyslog(LOG_INFO, "Listening on broadcast address %s#%d", - stoa((&interface->bcast)), - ntohs( (u_short) port)); + if ((INT_BROADCAST & iface->flags) + && iface->bfd != INVALID_SOCKET) + msyslog(LOG_INFO, "Listening on broadcast address %s#%d", + stoa((&iface->bcast)), port); - if (interface->fd == INVALID_SOCKET && - interface->bfd == INVALID_SOCKET) { + if (INVALID_SOCKET == iface->fd + && INVALID_SOCKET == iface->bfd) { msyslog(LOG_ERR, "unable to create socket on %s (%d) for %s#%d", - interface->name, - interface->ifnum, - stoa((&interface->sin)), - ntohs( (u_short) port)); - delete_interface(interface); + iface->name, + iface->ifnum, + stoa((&iface->sin)), + port); + delete_interface(iface); return NULL; } - - /* - * Blacklist bound interface address + + /* + * Blacklist our own addresses, no use talking to ourself */ - - SET_HOSTMASK(&resmask, interface->sin.ss_family); - hack_restrict(RESTRICT_FLAGS, &interface->sin, &resmask, - RESM_NTPONLY|RESM_INTERFACE, RES_IGNORE); - + SET_HOSTMASK(&resmask, AF(&iface->sin)); + hack_restrict(RESTRICT_FLAGS, &iface->sin, &resmask, + RESM_NTPONLY | RESM_INTERFACE, RES_IGNORE, 0); + /* * set globals with the first found * loopback interface of the appropriate class */ - if ((loopback_interface == NULL) && - (interface->family == AF_INET) && - ((interface->flags & INT_LOOPBACK) != 0)) - { - loopback_interface = interface; - } + if (NULL == loopback_interface && AF_INET == iface->family + && (INT_LOOPBACK & iface->flags)) + loopback_interface = iface; /* * put into our interface list */ - add_addr_to_list(&interface->sin, interface); - add_interface(interface); + add_addr_to_list(&iface->sin, iface); + add_interface(iface); + +#if defined(MCAST) && defined(MULTICAST_NONEWSOCKET) + /* + * Join any previously-configured compatible multicast groups. + */ + if (INT_MULTICAST & iface->flags && + !((INT_LOOPBACK | INT_WILDCARD) & iface->flags) && + !iface->ignore_packets) { + for (entry = remoteaddr_list; + entry != NULL; + entry = next_entry) { + next_entry = entry->link; + if (AF(&iface->sin) != AF(&entry->addr) || + !IS_MCAST(&entry->addr)) + continue; + if (socket_multicast_enable(iface, + &entry->addr)) + msyslog(LOG_INFO, + "Joined %s socket to multicast group %s", + stoa(&iface->sin), + stoa(&entry->addr)); + else + msyslog(LOG_ERR, + "Failed to join %s socket to multicast group %s", + stoa(&iface->sin), + stoa(&entry->addr)); + } + } +#endif /* MCAST && MCAST_NONEWSOCKET */ - DPRINT_INTERFACE(2, (interface, "created ", "\n")); - return interface; + DPRINT_INTERFACE(2, (iface, "created ", "\n")); + return iface; } #ifdef SO_EXCLUSIVEADDRUSE static void -set_excladdruse(int fd) +set_excladdruse( + SOCKET fd + ) { int one = 1; int failed; +#ifdef SYS_WINNT + DWORD err; +#endif failed = setsockopt(fd, SOL_SOCKET, SO_EXCLUSIVEADDRUSE, (char *)&one, sizeof(one)); - if (failed) - netsyslog(LOG_ERR, - "setsockopt(%d, SO_EXCLUSIVEADDRUSE, on): %m", fd); + if (!failed) + return; + +#ifdef SYS_WINNT + /* + * Prior to Windows XP setting SO_EXCLUSIVEADDRUSE can fail with + * error WSAINVAL depending on service pack level and whether + * the user account is in the Administrators group. Do not + * complain if it fails that way on versions prior to XP (5.1). + */ + err = GetLastError(); + + if (isc_win32os_versioncheck(5, 1, 0, 0) < 0 /* < 5.1/XP */ + && WSAEINVAL == err) + return; + + SetLastError(err); +#endif + msyslog(LOG_ERR, + "setsockopt(%d, SO_EXCLUSIVEADDRUSE, on): %m", + (int)fd); } #endif /* SO_EXCLUSIVEADDRUSE */ @@ -1597,29 +2235,30 @@ set_excladdruse(int fd) * fd's also? */ static void -set_reuseaddr(int flag) { - struct interface *interf; - +set_reuseaddr( + int flag + ) +{ #ifndef SO_EXCLUSIVEADDRUSE + endpt *ep; - for (interf = ISC_LIST_HEAD(inter_list); - interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) { - - if (interf->flags & INT_WILDCARD) + for (ep = ep_list; ep != NULL; ep = ep->elink) { + if (ep->flags & INT_WILDCARD) continue; - + /* - * if interf->fd is INVALID_SOCKET, we might have a adapter + * if ep->fd is INVALID_SOCKET, we might have a adapter * configured but not present */ - DPRINTF(4, ("setting SO_REUSEADDR on %.16s@%s to %s\n", interf->name, stoa(&interf->sin), flag ? "on" : "off")); - - if (interf->fd != INVALID_SOCKET) { - if (setsockopt(interf->fd, SOL_SOCKET, - SO_REUSEADDR, (char *)&flag, - sizeof(flag))) { - netsyslog(LOG_ERR, "set_reuseaddr: setsockopt(SO_REUSEADDR, %s) failed: %m", flag ? "on" : "off"); + DPRINTF(4, ("setting SO_REUSEADDR on %.16s@%s to %s\n", + ep->name, stoa(&ep->sin), + flag ? "on" : "off")); + + if (ep->fd != INVALID_SOCKET) { + if (setsockopt(ep->fd, SOL_SOCKET, SO_REUSEADDR, + (char *)&flag, sizeof(flag))) { + msyslog(LOG_ERR, "set_reuseaddr: setsockopt(%s, SO_REUSEADDR, %s) failed: %m", + stoa(&ep->sin), flag ? "on" : "off"); } } } @@ -1631,117 +2270,114 @@ set_reuseaddr(int flag) { * make other changes as necessary later on */ void -enable_broadcast(struct interface *iface, struct sockaddr_storage *baddr) +enable_broadcast( + struct interface * iface, + sockaddr_u * baddr + ) { -#ifdef SO_BROADCAST +#ifdef OPEN_BCAST_SOCKET socket_broadcast_enable(iface, iface->fd, baddr); #endif } -#ifdef OPEN_BCAST_SOCKET +#ifdef OPEN_BCAST_SOCKET /* * Enable a broadcast address to a given socket - * The socket is in the inter_list all we need to do is enable + * The socket is in the ep_list all we need to do is enable * broadcasting. It is not this function's job to select the socket */ static isc_boolean_t -socket_broadcast_enable(struct interface *iface, SOCKET fd, struct sockaddr_storage *maddr) +socket_broadcast_enable( + struct interface * iface, + SOCKET fd, + sockaddr_u * baddr + ) { #ifdef SO_BROADCAST int on = 1; - if (maddr->ss_family == AF_INET) - { + if (IS_IPV4(baddr)) { /* if this interface can support broadcast, set SO_BROADCAST */ if (setsockopt(fd, SOL_SOCKET, SO_BROADCAST, (char *)&on, sizeof(on))) - { - netsyslog(LOG_ERR, "setsockopt(SO_BROADCAST) enable failure on address %s: %m", - stoa(maddr)); - } -#ifdef DEBUG - else if (debug > 1) { - printf("Broadcast enabled on socket %d for address %s\n", - fd, stoa(maddr)); - } -#endif + msyslog(LOG_ERR, + "setsockopt(SO_BROADCAST) enable failure on address %s: %m", + stoa(baddr)); + else + DPRINTF(2, ("Broadcast enabled on socket %d for address %s\n", + fd, stoa(baddr))); } - iface->flags |= INT_BCASTOPEN; + iface->flags |= INT_BCASTXMIT; return ISC_TRUE; #else return ISC_FALSE; #endif /* SO_BROADCAST */ } +#ifdef OS_MISSES_SPECIFIC_ROUTE_UPDATES /* * Remove a broadcast address from a given socket - * The socket is in the inter_list all we need to do is disable + * The socket is in the ep_list all we need to do is disable * broadcasting. It is not this function's job to select the socket */ static isc_boolean_t -socket_broadcast_disable(struct interface *iface, struct sockaddr_storage *maddr) +socket_broadcast_disable( + struct interface * iface, + sockaddr_u * baddr + ) { #ifdef SO_BROADCAST int off = 0; /* This seems to be OK as an int */ - if (maddr->ss_family == AF_INET) - { - if (setsockopt(iface->fd, SOL_SOCKET, SO_BROADCAST, - (char *)&off, sizeof(off))) - { - netsyslog(LOG_ERR, "setsockopt(SO_BROADCAST) disable failure on address %s: %m", - stoa(maddr)); - } - } - iface->flags &= ~INT_BCASTOPEN; + if (IS_IPV4(baddr) && setsockopt(iface->fd, SOL_SOCKET, + SO_BROADCAST, (char *)&off, sizeof(off))) + msyslog(LOG_ERR, + "setsockopt(SO_BROADCAST) disable failure on address %s: %m", + stoa(baddr)); + + iface->flags &= ~INT_BCASTXMIT; return ISC_TRUE; #else return ISC_FALSE; #endif /* SO_BROADCAST */ } +#endif /* OS_MISSES_SPECIFIC_ROUTE_UPDATES */ #endif /* OPEN_BCAST_SOCKET */ + +/* + * return the broadcast client flag value + */ +isc_boolean_t +get_broadcastclient_flag(void) +{ + return (broadcast_client_enabled); +} /* * Check to see if the address is a multicast address */ static isc_boolean_t -addr_ismulticast(struct sockaddr_storage *maddr) +addr_ismulticast( + sockaddr_u *maddr + ) { - switch (maddr->ss_family) - { - case AF_INET : - if (!IN_CLASSD(ntohl(((struct sockaddr_in*)maddr)->sin_addr.s_addr))) { - DPRINTF(4, ("multicast address %s not class D\n", stoa(maddr))); - return (ISC_FALSE); - } - else - { - return (ISC_TRUE); - } - - case AF_INET6 : -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - if (!IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)maddr)->sin6_addr)) { - DPRINTF(4, ("address %s not IPv6 multicast address\n", stoa(maddr))); - return (ISC_FALSE); - } - else - { - return (ISC_TRUE); - } + isc_boolean_t result; -/* - * If we don't have IPV6 support any IPV6 address is not multicast - */ -#else - return (ISC_FALSE); -#endif +#ifndef INCLUDE_IPV6_MULTICAST_SUPPORT /* - * Never valid + * If we don't have IPV6 support any IPV6 addr is not multicast */ - default: - return (ISC_FALSE); - } + if (IS_IPV6(maddr)) + result = ISC_FALSE; + else +#endif + result = IS_MCAST(maddr); + + if (!result) + DPRINTF(4, ("address %s is not multicast\n", + stoa(maddr))); + + return result; } /* @@ -1750,67 +2386,57 @@ addr_ismulticast(struct sockaddr_storage *maddr) * send the multicast packet. */ void -enable_multicast_if(struct interface *iface, struct sockaddr_storage *maddr) +enable_multicast_if( + struct interface * iface, + sockaddr_u * maddr + ) { #ifdef MCAST #ifdef IP_MULTICAST_LOOP - /*u_char*/ TYPEOF_IP_MULTICAST_LOOP off = 0; + TYPEOF_IP_MULTICAST_LOOP off = 0; #endif -#ifdef IPV6_MULTICAST_LOOP - u_int off6 = 0; /* RFC 3493, 5.2. defines type unsigned int */ +#if defined(INCLUDE_IPV6_MULTICAST_SUPPORT) && defined(IPV6_MULTICAST_LOOP) + u_int off6 = 0; #endif - switch (maddr->ss_family) - { + REQUIRE(AF(maddr) == AF(&iface->sin)); + + switch (AF(&iface->sin)) { + case AF_INET: - if (setsockopt(iface->fd, IPPROTO_IP, IP_MULTICAST_IF, - (char *)&(((struct sockaddr_in*)&iface->sin)->sin_addr.s_addr), - sizeof(struct in_addr)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_MULTICAST_IF failure: %m on socket %d, addr %s for multicast address %s", - iface->fd, stoa(&iface->sin), stoa(maddr)); - return; - } #ifdef IP_MULTICAST_LOOP /* - * Don't send back to itself, but allow it to fail to set it + * Don't send back to itself, but allow failure to set */ - if (setsockopt(iface->fd, IPPROTO_IP, IP_MULTICAST_LOOP, - SETSOCKOPT_ARG_CAST &off, sizeof(off)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_MULTICAST_LOOP failure: %m on socket %d, addr %s for multicast address %s", - iface->fd, stoa(&iface->sin), stoa(maddr)); + if (setsockopt(iface->fd, IPPROTO_IP, + IP_MULTICAST_LOOP, + SETSOCKOPT_ARG_CAST &off, + sizeof(off))) { + + msyslog(LOG_ERR, + "setsockopt IP_MULTICAST_LOOP failed: %m on socket %d, addr %s for multicast address %s", + iface->fd, stoa(&iface->sin), + stoa(maddr)); } #endif - DPRINTF(4, ("Added IPv4 multicast interface on socket %d, addr %s for multicast address %s\n", - iface->fd, stoa(&iface->sin), - stoa(maddr))); break; case AF_INET6: #ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_MULTICAST_IF, - (char *) &iface->scopeid, sizeof(iface->scopeid)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IPV6_MULTICAST_IF failure: %m on socket %d, addr %s, scope %d for multicast address %s", - iface->fd, stoa(&iface->sin), iface->scopeid, - stoa(maddr)); - return; - } #ifdef IPV6_MULTICAST_LOOP /* - * Don't send back to itself, but allow it to fail to set it + * Don't send back to itself, but allow failure to set */ - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_MULTICAST_LOOP, - (char *) &off6, sizeof(off6)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IPV6_MULTICAST_LOOP failure: %m on socket %d, addr %s for multicast address %s", - iface->fd, stoa(&iface->sin), stoa(maddr)); + if (setsockopt(iface->fd, IPPROTO_IPV6, + IPV6_MULTICAST_LOOP, + (char *) &off6, sizeof(off6))) { + + msyslog(LOG_ERR, + "setsockopt IPV6_MULTICAST_LOOP failed: %m on socket %d, addr %s for multicast address %s", + iface->fd, stoa(&iface->sin), + stoa(maddr)); } #endif - DPRINTF(4, ("Added IPv6 multicast interface on socket %d, addr %s, scope %d for multicast address %s\n", - iface->fd, stoa(&iface->sin), iface->scopeid, - stoa(maddr))); break; #else return; @@ -1822,37 +2448,37 @@ enable_multicast_if(struct interface *iface, struct sockaddr_storage *maddr) /* * Add a multicast address to a given socket - * The socket is in the inter_list all we need to do is enable + * The socket is in the ep_list all we need to do is enable * multicasting. It is not this function's job to select the socket */ +#if defined(MCAST) static isc_boolean_t -socket_multicast_enable(struct interface *iface, int lscope, struct sockaddr_storage *maddr) +socket_multicast_enable( + endpt * iface, + sockaddr_u * maddr + ) { -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - struct ipv6_mreq mreq6; - struct in6_addr iaddr6; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ - - struct ip_mreq mreq; - - if (find_addr_in_list(maddr)) { - DPRINTF(4, ("socket_multicast_enable(%s): already enabled\n", stoa(maddr))); - return ISC_TRUE; - } + struct ip_mreq mreq; +# ifdef INCLUDE_IPV6_MULTICAST_SUPPORT + struct ipv6_mreq mreq6; +# endif + switch (AF(maddr)) { - switch (maddr->ss_family) - { case AF_INET: - memset((char *)&mreq, 0, sizeof(mreq)); - mreq.imr_multiaddr = (((struct sockaddr_in*)maddr)->sin_addr); + ZERO(mreq); + mreq.imr_multiaddr = SOCK_ADDR4(maddr); mreq.imr_interface.s_addr = htonl(INADDR_ANY); - if (setsockopt(iface->fd, IPPROTO_IP, IP_ADD_MEMBERSHIP, - (char *)&mreq, sizeof(mreq)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_ADD_MEMBERSHIP failure: %m on socket %d, addr %s for %x / %x (%s)", - iface->fd, stoa(&iface->sin), - mreq.imr_multiaddr.s_addr, - mreq.imr_interface.s_addr, stoa(maddr)); + if (setsockopt(iface->fd, + IPPROTO_IP, + IP_ADD_MEMBERSHIP, + (char *)&mreq, + sizeof(mreq))) { + DPRINTF(2, ( + "setsockopt IP_ADD_MEMBERSHIP failed: %m on socket %d, addr %s for %x / %x (%s)", + iface->fd, stoa(&iface->sin), + mreq.imr_multiaddr.s_addr, + mreq.imr_interface.s_addr, + stoa(maddr))); return ISC_FALSE; } DPRINTF(4, ("Added IPv4 multicast membership on socket %d, addr %s for %x / %x (%s)\n", @@ -1862,109 +2488,119 @@ socket_multicast_enable(struct interface *iface, int lscope, struct sockaddr_sto break; case AF_INET6: -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT +# ifdef INCLUDE_IPV6_MULTICAST_SUPPORT /* - * Enable reception of multicast packets - * If the address is link-local we can get the interface index - * from the scope id. Don't do this for other types of multicast - * addresses. For now let the kernel figure it out. + * Enable reception of multicast packets. + * If the address is link-local we can get the + * interface index from the scope id. Don't do this + * for other types of multicast addresses. For now let + * the kernel figure it out. */ - memset((char *)&mreq6, 0, sizeof(mreq6)); - iaddr6 = ((struct sockaddr_in6*)maddr)->sin6_addr; - mreq6.ipv6mr_multiaddr = iaddr6; - mreq6.ipv6mr_interface = lscope; - - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_JOIN_GROUP, - (char *)&mreq6, sizeof(mreq6)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IPV6_JOIN_GROUP failure: %m on socket %d, addr %s for interface %d(%s)", - iface->fd, stoa(&iface->sin), - mreq6.ipv6mr_interface, stoa(maddr)); + ZERO(mreq6); + mreq6.ipv6mr_multiaddr = SOCK_ADDR6(maddr); + mreq6.ipv6mr_interface = iface->ifindex; + + if (setsockopt(iface->fd, IPPROTO_IPV6, + IPV6_JOIN_GROUP, (char *)&mreq6, + sizeof(mreq6))) { + DPRINTF(2, ( + "setsockopt IPV6_JOIN_GROUP failed: %m on socket %d, addr %s for interface %u (%s)", + iface->fd, stoa(&iface->sin), + mreq6.ipv6mr_interface, stoa(maddr))); return ISC_FALSE; } - DPRINTF(4, ("Added IPv6 multicast group on socket %d, addr %s for interface %d(%s)\n", + DPRINTF(4, ("Added IPv6 multicast group on socket %d, addr %s for interface %u (%s)\n", iface->fd, stoa(&iface->sin), mreq6.ipv6mr_interface, stoa(maddr))); - break; -#else +# else return ISC_FALSE; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ +# endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ } iface->flags |= INT_MCASTOPEN; iface->num_mcast++; - add_addr_to_list(maddr, iface); + return ISC_TRUE; } +#endif /* MCAST */ + /* * Remove a multicast address from a given socket - * The socket is in the inter_list all we need to do is disable + * The socket is in the ep_list all we need to do is disable * multicasting. It is not this function's job to select the socket */ +#ifdef MCAST static isc_boolean_t -socket_multicast_disable(struct interface *iface, struct sockaddr_storage *maddr) +socket_multicast_disable( + struct interface * iface, + sockaddr_u * maddr + ) { -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT +# ifdef INCLUDE_IPV6_MULTICAST_SUPPORT struct ipv6_mreq mreq6; - struct in6_addr iaddr6; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ - +# endif struct ip_mreq mreq; - memset((char *)&mreq, 0, sizeof(mreq)); + + ZERO(mreq); if (find_addr_in_list(maddr) == NULL) { - DPRINTF(4, ("socket_multicast_disable(%s): not enabled\n", stoa(maddr))); + DPRINTF(4, ("socket_multicast_disable(%s): not found\n", + stoa(maddr))); return ISC_TRUE; } - switch (maddr->ss_family) - { + switch (AF(maddr)) { + case AF_INET: - mreq.imr_multiaddr = (((struct sockaddr_in*)&maddr)->sin_addr); - mreq.imr_interface.s_addr = ((struct sockaddr_in*)&iface->sin)->sin_addr.s_addr; - if (setsockopt(iface->fd, IPPROTO_IP, IP_DROP_MEMBERSHIP, - (char *)&mreq, sizeof(mreq)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IP_DROP_MEMBERSHIP failure: %m on socket %d, addr %s for %x / %x (%s)", - iface->fd, stoa(&iface->sin), - mreq.imr_multiaddr.s_addr, - mreq.imr_interface.s_addr, stoa(maddr)); + mreq.imr_multiaddr = SOCK_ADDR4(maddr); + mreq.imr_interface = SOCK_ADDR4(&iface->sin); + if (setsockopt(iface->fd, IPPROTO_IP, + IP_DROP_MEMBERSHIP, (char *)&mreq, + sizeof(mreq))) { + + msyslog(LOG_ERR, + "setsockopt IP_DROP_MEMBERSHIP failed: %m on socket %d, addr %s for %x / %x (%s)", + iface->fd, stoa(&iface->sin), + SRCADR(maddr), SRCADR(&iface->sin), + stoa(maddr)); return ISC_FALSE; } break; case AF_INET6: -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT +# ifdef INCLUDE_IPV6_MULTICAST_SUPPORT /* * Disable reception of multicast packets - * If the address is link-local we can get the interface index - * from the scope id. Don't do this for other types of multicast - * addresses. For now let the kernel figure it out. + * If the address is link-local we can get the + * interface index from the scope id. Don't do this + * for other types of multicast addresses. For now let + * the kernel figure it out. */ - iaddr6 = ((struct sockaddr_in6*)&maddr)->sin6_addr; - mreq6.ipv6mr_multiaddr = iaddr6; - mreq6.ipv6mr_interface = iface->scopeid; - - if (setsockopt(iface->fd, IPPROTO_IPV6, IPV6_LEAVE_GROUP, - (char *)&mreq6, sizeof(mreq6)) == -1) { - netsyslog(LOG_ERR, - "setsockopt IPV6_LEAVE_GROUP failure: %m on socket %d, addr %s for %d(%s)", - iface->fd, stoa(&iface->sin), - mreq6.ipv6mr_interface, stoa(maddr)); + mreq6.ipv6mr_multiaddr = SOCK_ADDR6(maddr); + mreq6.ipv6mr_interface = iface->ifindex; + + if (setsockopt(iface->fd, IPPROTO_IPV6, + IPV6_LEAVE_GROUP, (char *)&mreq6, + sizeof(mreq6))) { + + msyslog(LOG_ERR, + "setsockopt IPV6_LEAVE_GROUP failure: %m on socket %d, addr %s for %d (%s)", + iface->fd, stoa(&iface->sin), + iface->ifindex, stoa(maddr)); return ISC_FALSE; } break; -#else +# else return ISC_FALSE; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ - +# endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ } + iface->num_mcast--; - if (iface->num_mcast <= 0) { - iface->num_mcast = 0; + if (!iface->num_mcast) iface->flags &= ~INT_MCASTOPEN; - } + return ISC_TRUE; } +#endif /* MCAST */ /* * io_setbclient - open the broadcast client sockets @@ -1972,38 +2608,37 @@ socket_multicast_disable(struct interface *iface, struct sockaddr_storage *maddr void io_setbclient(void) { -#ifdef OPEN_BCAST_SOCKET - struct interface *interf; - int nif = 0; - isc_boolean_t jstatus; - SOCKET fd; +#ifdef OPEN_BCAST_SOCKET + struct interface * interf; + int nif; + nif = 0; set_reuseaddr(1); - for (interf = ISC_LIST_HEAD(inter_list); + for (interf = ep_list; interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) { - if (interf->flags & INT_WILDCARD) - continue; - - /* use only allowed addresses */ - if (interf->ignore_packets == ISC_TRUE) + interf = interf->elink) { + + if (interf->flags & (INT_WILDCARD | INT_LOOPBACK)) continue; - /* Only IPv4 addresses are valid for broadcast */ - if (interf->sin.ss_family != AF_INET) + + /* use only allowed addresses */ + if (interf->ignore_packets) continue; - /* Is this a broadcast address? */ + /* Need a broadcast-capable interface */ if (!(interf->flags & INT_BROADCAST)) continue; - /* Skip the loopback addresses */ - if (interf->flags & INT_LOOPBACK) - continue; + /* Only IPv4 addresses are valid for broadcast */ + REQUIRE(IS_IPV4(&interf->sin)); /* Do we already have the broadcast address open? */ if (interf->flags & INT_BCASTOPEN) { - /* account for already open interfaces to aviod misleading warning below */ + /* + * account for already open interfaces to avoid + * misleading warning below + */ nif++; continue; } @@ -2012,41 +2647,41 @@ io_setbclient(void) * Try to open the broadcast address */ interf->family = AF_INET; - interf->bfd = open_socket(&interf->bcast, - INT_BROADCAST, 0, interf); + interf->bfd = open_socket(&interf->bcast, 1, 0, interf); - /* - * If we succeeded then we use it otherwise - * enable the underlying address + /* + * If we succeeded then we use it otherwise enable + * broadcast on the interface address */ - if (interf->bfd == INVALID_SOCKET) { - fd = interf->fd; - } - else { - fd = interf->bfd; - } - - /* Enable Broadcast on socket */ - jstatus = socket_broadcast_enable(interf, fd, &interf->sin); - if (jstatus == ISC_TRUE) - { + if (interf->bfd != INVALID_SOCKET) { nif++; - netsyslog(LOG_INFO,"io_setbclient: Opened broadcast client on interface #%d %s, socket: %d", - interf->ifnum, interf->name, fd); - interf->addr_refid = addr2refid(&interf->sin); + interf->flags |= INT_BCASTOPEN; + msyslog(LOG_INFO, + "Listen for broadcasts to %s on interface #%d %s", + stoa(&interf->bcast), interf->ifnum, interf->name); + } else { + /* silently ignore EADDRINUSE as we probably opened + the socket already for an address in the same network */ + if (errno != EADDRINUSE) + msyslog(LOG_INFO, + "failed to listen for broadcasts to %s on interface #%d %s", + stoa(&interf->bcast), interf->ifnum, interf->name); } } set_reuseaddr(0); -#ifdef DEBUG - if (debug) - if (nif > 0) - printf("io_setbclient: Opened broadcast clients\n"); -#endif - if (nif == 0) - netsyslog(LOG_ERR, "Unable to listen for broadcasts, no broadcast interfaces available"); + if (nif > 0) { + broadcast_client_enabled = ISC_TRUE; + DPRINTF(1, ("io_setbclient: listening to %d broadcast addresses\n", nif)); + } + else if (!nif) { + broadcast_client_enabled = ISC_FALSE; + msyslog(LOG_ERR, + "Unable to listen for broadcasts, no broadcast interfaces available"); + } #else - netsyslog(LOG_ERR, "io_setbclient: Broadcast Client disabled by build"); -#endif + msyslog(LOG_ERR, + "io_setbclient: Broadcast Client disabled by build"); +#endif /* OPEN_BCAST_SOCKET */ } /* @@ -2055,20 +2690,25 @@ io_setbclient(void) void io_unsetbclient(void) { - struct interface *interf; - isc_boolean_t lstatus; + endpt *ep; - for (interf = ISC_LIST_HEAD(inter_list); - interf != NULL; - interf = ISC_LIST_NEXT(interf, link)) - { - if (interf->flags & INT_WILDCARD) - continue; - - if (!(interf->flags & INT_BCASTOPEN)) - continue; - lstatus = socket_broadcast_disable(interf, &interf->sin); + for (ep = ep_list; ep != NULL; ep = ep->elink) { + if (INT_WILDCARD & ep->flags) + continue; + if (!(INT_BCASTOPEN & ep->flags)) + continue; + + if (ep->bfd != INVALID_SOCKET) { + /* destroy broadcast listening socket */ + msyslog(LOG_INFO, + "stop listening for broadcasts to %s on interface #%d %s", + stoa(&ep->bcast), ep->ifnum, ep->name); + close_and_delete_fd_from_list(ep->bfd); + ep->bfd = INVALID_SOCKET; + ep->flags &= ~INT_BCASTOPEN; + } } + broadcast_client_enabled = ISC_FALSE; } /* @@ -2076,279 +2716,146 @@ io_unsetbclient(void) */ void io_multicast_add( - struct sockaddr_storage addr + sockaddr_u *addr ) { #ifdef MCAST - struct interface *interface; -#ifndef MULTICAST_NONEWSOCKET - struct interface *iface; -#endif - int lscope = 0; - + endpt * ep; + endpt * one_ep; + /* * Check to see if this is a multicast address */ - if (addr_ismulticast(&addr) == ISC_FALSE) + if (!addr_ismulticast(addr)) return; /* If we already have it we can just return */ - if (find_flagged_addr_in_list(&addr, INT_MCASTOPEN|INT_MCASTIF) != NULL) - { - netsyslog(LOG_INFO, "Duplicate request found for multicast address %s", - stoa(&addr)); + if (NULL != find_flagged_addr_in_list(addr, INT_MCASTOPEN)) { + msyslog(LOG_INFO, + "Duplicate request found for multicast address %s", + stoa(addr)); return; } -#ifndef MULTICAST_NONEWSOCKET - interface = new_interface(NULL); - +# ifndef MULTICAST_NONEWSOCKET + ep = new_interface(NULL); + /* * Open a new socket for the multicast address */ - interface->sin.ss_family = addr.ss_family; - interface->family = addr.ss_family; + ep->sin = *addr; + SET_PORT(&ep->sin, NTP_PORT); + ep->family = AF(&ep->sin); + AF(&ep->mask) = ep->family; + SET_ONESMASK(&ep->mask); - switch(addr.ss_family) { - case AF_INET: - memcpy(&(((struct sockaddr_in *)&interface->sin)->sin_addr), - &(((struct sockaddr_in*)&addr)->sin_addr), - sizeof(struct in_addr)); - ((struct sockaddr_in*)&interface->sin)->sin_port = htons(NTP_PORT); - memset(&((struct sockaddr_in*)&interface->mask)->sin_addr.s_addr, 0xff, sizeof(struct in_addr)); - break; - case AF_INET6: -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - memcpy(&(((struct sockaddr_in6 *)&interface->sin)->sin6_addr), - &((struct sockaddr_in6*)&addr)->sin6_addr, - sizeof(struct in6_addr)); - ((struct sockaddr_in6*)&interface->sin)->sin6_port = htons(NTP_PORT); -#ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)&interface->sin)->sin6_scope_id = ((struct sockaddr_in6*)&addr)->sin6_scope_id; -#endif - memset(&((struct sockaddr_in6*)&interface->mask)->sin6_addr.s6_addr, 0xff, sizeof(struct in6_addr)); -#endif - iface = findlocalcastinterface(&addr, INT_MULTICAST); - if (iface) { -# ifdef ISC_PLATFORM_HAVESCOPEID - lscope = ((struct sockaddr_in6*)&iface->sin)->sin6_scope_id; -# endif - DPRINTF(4, ("Found interface #%d %s, scope: %d for address %s\n", iface->ifnum, iface->name, lscope, stoa(&addr))); - } - break; - } - set_reuseaddr(1); - interface->bfd = INVALID_SOCKET; - interface->fd = open_socket(&interface->sin, - INT_MULTICAST, 0, interface); + ep->bfd = INVALID_SOCKET; + ep->fd = open_socket(&ep->sin, 0, 0, ep); + if (ep->fd != INVALID_SOCKET) { + ep->ignore_packets = ISC_FALSE; + ep->flags |= INT_MCASTIF; + + strlcpy(ep->name, "multicast", sizeof(ep->name)); + DPRINT_INTERFACE(2, (ep, "multicast add ", "\n")); + add_interface(ep); + log_listen_address(ep); + } else { + /* bind failed, re-use wildcard interface */ + delete_interface(ep); - if (interface->fd != INVALID_SOCKET) - { - interface->bfd = INVALID_SOCKET; - interface->ignore_packets = ISC_FALSE; - interface->flags |= INT_MCASTIF; - - (void) strncpy(interface->name, "multicast", - sizeof(interface->name)); - ((struct sockaddr_in*)&interface->mask)->sin_addr.s_addr = - htonl(~(u_int32)0); - DPRINT_INTERFACE(2, (interface, "multicast add ", "\n")); - /* socket_multicast_enable() will add this address to the addresslist */ - add_interface(interface); - list_if_listening(interface, htons(NTP_PORT)); - } - else - { - delete_interface(interface); /* re-use existing interface */ - interface = NULL; - if (addr.ss_family == AF_INET) - interface = wildipv4; - else if (addr.ss_family == AF_INET6) - interface = wildipv6; - - if (interface != NULL) { + if (IS_IPV4(addr)) + ep = wildipv4; + else if (IS_IPV6(addr)) + ep = wildipv6; + else + ep = NULL; + + if (ep != NULL) { /* HACK ! -- stuff in an address */ - interface->bcast = addr; - netsyslog(LOG_ERR, - "...multicast address %s using wildcard interface #%d %s", - stoa(&addr), interface->ifnum, interface->name); + /* because we don't bind addr? DH */ + ep->bcast = *addr; + msyslog(LOG_ERR, + "multicast address %s using wildcard interface #%d %s", + stoa(addr), ep->ifnum, ep->name); } else { - netsyslog(LOG_ERR, - "No multicast socket available to use for address %s", - stoa(&addr)); + msyslog(LOG_ERR, + "No multicast socket available to use for address %s", + stoa(addr)); return; } } -#else - /* - * For the case where we can't use a separate socket - */ - interface = findlocalcastinterface(&addr, INT_MULTICAST); + { /* in place of the { following for in #else clause */ + one_ep = ep; +# else /* MULTICAST_NONEWSOCKET follows */ /* - * If we don't have a valid socket, just return + * For the case where we can't use a separate socket (Windows) + * join each applicable endpoint socket to the group address. */ - if (!interface) - { - netsyslog(LOG_ERR, - "Cannot add multicast address %s: Cannot find slot", - stoa(&addr)); - return; + if (IS_IPV4(addr)) + one_ep = wildipv4; + else + one_ep = wildipv6; + for (ep = ep_list; ep != NULL; ep = ep->elink) { + if (ep->ignore_packets || AF(&ep->sin) != AF(addr) || + !(INT_MULTICAST & ep->flags) || + (INT_LOOPBACK | INT_WILDCARD) & ep->flags) + continue; + one_ep = ep; +# endif /* MULTICAST_NONEWSOCKET */ + if (socket_multicast_enable(ep, addr)) + msyslog(LOG_INFO, + "Joined %s socket to multicast group %s", + stoa(&ep->sin), + stoa(addr)); } + add_addr_to_list(addr, one_ep); +#else /* !MCAST follows*/ + msyslog(LOG_ERR, + "Can not add multicast address %s: no multicast support", + stoa(addr)); #endif - { - isc_boolean_t jstatus; - jstatus = socket_multicast_enable(interface, lscope, &addr); - - if (jstatus == ISC_TRUE) - netsyslog(LOG_INFO, "Added Multicast Listener %s on interface #%d %s\n", stoa(&addr), interface->ifnum, interface->name); - else - netsyslog(LOG_ERR, "Failed to add Multicast Listener %s\n", stoa(&addr)); - } -#else /* MCAST */ - netsyslog(LOG_ERR, - "Cannot add multicast address %s: no Multicast support", - stoa(&addr)); -#endif /* MCAST */ return; } + /* * io_multicast_del() - delete multicast group address */ void io_multicast_del( - struct sockaddr_storage addr + sockaddr_u * addr ) { #ifdef MCAST - struct interface *interface; - isc_boolean_t lstatus; + endpt *iface; /* * Check to see if this is a multicast address */ - if (addr_ismulticast(&addr) == ISC_FALSE) - { - netsyslog(LOG_ERR, - "invalid multicast address %s", stoa(&addr)); + if (!addr_ismulticast(addr)) { + msyslog(LOG_ERR, "invalid multicast address %s", + stoa(addr)); return; } - switch (addr.ss_family) - { - case AF_INET : - /* - * Disable reception of multicast packets - */ - interface = find_flagged_addr_in_list(&addr, INT_MCASTOPEN); - while ( interface != NULL) { - lstatus = socket_multicast_disable(interface, &addr); - interface = find_flagged_addr_in_list(&addr, INT_MCASTOPEN); - } - break; - -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - case AF_INET6 : - /* - * Disable reception of multicast packets - */ - for (interface = ISC_LIST_HEAD(inter_list); - interface != NULL; - interface = ISC_LIST_NEXT(interface, link)) - { - if (interface->flags & INT_WILDCARD) - continue; - - /* Be sure it's the correct family */ - if (interface->sin.ss_family != AF_INET6) - continue; - if (!(interface->flags & INT_MCASTOPEN)) - continue; - if (!(interface->fd < 0)) - continue; - if (!SOCKCMP(&addr, &interface->sin)) - continue; - lstatus = socket_multicast_disable(interface, &addr); - } - break; -#endif /* INCLUDE_IPV6_MULTICAST_SUPPORT */ - - }/* switch */ + /* + * Disable reception of multicast packets + */ + while ((iface = find_flagged_addr_in_list(addr, INT_MCASTOPEN)) + != NULL) + socket_multicast_disable(iface, addr); - delete_addr_from_list(&addr); + delete_addr_from_list(addr); #else /* not MCAST */ - netsyslog(LOG_ERR, "this function requires multicast kernel"); + msyslog(LOG_ERR, + "Can not delete multicast address %s: no multicast support", + stoa(addr)); #endif /* not MCAST */ } -/* - * init_nonblocking_io() - set up descriptor to be non blocking - */ -static void init_nonblocking_io(SOCKET fd) -{ - /* - * set non-blocking, - */ - -#ifdef USE_FIONBIO - /* in vxWorks we use FIONBIO, but the others are defined for old systems, so - * all hell breaks loose if we leave them defined - */ -#undef O_NONBLOCK -#undef FNDELAY -#undef O_NDELAY -#endif - -#if defined(O_NONBLOCK) /* POSIX */ - if (fcntl(fd, F_SETFL, O_NONBLOCK) < 0) - { - netsyslog(LOG_ERR, "fcntl(O_NONBLOCK) fails on fd #%d: %m", - fd); - exit(1); - /*NOTREACHED*/ - } -#elif defined(FNDELAY) - if (fcntl(fd, F_SETFL, FNDELAY) < 0) - { - netsyslog(LOG_ERR, "fcntl(FNDELAY) fails on fd #%d: %m", - fd); - exit(1); - /*NOTREACHED*/ - } -#elif defined(O_NDELAY) /* generally the same as FNDELAY */ - if (fcntl(fd, F_SETFL, O_NDELAY) < 0) - { - netsyslog(LOG_ERR, "fcntl(O_NDELAY) fails on fd #%d: %m", - fd); - exit(1); - /*NOTREACHED*/ - } -#elif defined(FIONBIO) - { - int on = 1; - if (ioctl(fd,FIONBIO,&on) < 0) - { - netsyslog(LOG_ERR, "ioctl(FIONBIO) fails on fd #%d: %m", - fd); - exit(1); - /*NOTREACHED*/ - } - } -#elif defined(FIOSNBIO) - if (ioctl(fd,FIOSNBIO,&on) < 0) - { - netsyslog(LOG_ERR, "ioctl(FIOSNBIO) fails on fd #%d: %m", - fd); - exit(1); - /*NOTREACHED*/ - } -#else -# include "Bletch: Need non-blocking I/O!" -#endif -} /* * open_socket - open a socket, returning the file descriptor @@ -2356,48 +2863,42 @@ static void init_nonblocking_io(SOCKET fd) static SOCKET open_socket( - struct sockaddr_storage *addr, - int flags, - int turn_off_reuse, - struct interface *interf + sockaddr_u * addr, + int bcast, + int turn_off_reuse, + endpt * interf ) { - int errval; - SOCKET fd; + SOCKET fd; + int errval; /* - * int is OK for REUSEADR per + * int is OK for REUSEADR per * http://www.kohala.com/start/mcast.api.txt */ - int on = 1; - int off = 0; + int on = 1; + int off = 0; -#if defined(IPTOS_LOWDELAY) && defined(IPPROTO_IP) && defined(IP_TOS) - int tos; -#endif /* IPTOS_LOWDELAY && IPPROTO_IP && IP_TOS */ - - if ((addr->ss_family == AF_INET6) && (isc_net_probeipv6() != ISC_R_SUCCESS)) - return (INVALID_SOCKET); + if (IS_IPV6(addr) && !ipv6_works) + return INVALID_SOCKET; /* create a datagram (UDP) socket */ - fd = socket(addr->ss_family, SOCK_DGRAM, 0); + fd = socket(AF(addr), SOCK_DGRAM, 0); if (INVALID_SOCKET == fd) { -#ifndef SYS_WINNT - errval = errno; -#else - errval = WSAGetLastError(); -#endif - netsyslog(LOG_ERR, - "socket(AF_INET%s, SOCK_DGRAM, 0) failed on address %s: %m", - (addr->ss_family == AF_INET6) ? "6" : "", - stoa(addr)); + errval = socket_errno(); + msyslog(LOG_ERR, + "socket(AF_INET%s, SOCK_DGRAM, 0) failed on address %s: %m", + IS_IPV6(addr) ? "6" : "", stoa(addr)); - if (errval == EPROTONOSUPPORT || + if (errval == EPROTONOSUPPORT || errval == EAFNOSUPPORT || errval == EPFNOSUPPORT) return (INVALID_SOCKET); - msyslog(LOG_ERR, "unexpected error code %d (not PROTONOSUPPORT|AFNOSUPPORT|FPNOSUPPORT) - exiting", errval); + + errno = errval; + msyslog(LOG_ERR, + "unexpected socket() error %m code %d (not EPROTONOSUPPORT nor EAFNOSUPPORT nor EPFNOSUPPORT) - exiting", + errno); exit(1); - /*NOTREACHED*/ } #ifdef SYS_WINNT @@ -2419,17 +2920,17 @@ open_socket( if (isc_win32os_versioncheck(5, 1, 0, 0) < 0) /* before 5.1 */ #endif if (setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, - (char *)(turn_off_reuse - ? &off - : &on), + (char *)((turn_off_reuse) + ? &off + : &on), sizeof(on))) { - netsyslog(LOG_ERR, "setsockopt SO_REUSEADDR %s" - " fails for address %s: %m", - turn_off_reuse - ? "off" - : "on", - stoa(addr)); + msyslog(LOG_ERR, + "setsockopt SO_REUSEADDR %s fails for address %s: %m", + (turn_off_reuse) + ? "off" + : "on", + stoa(addr)); closesocket(fd); return INVALID_SOCKET; } @@ -2445,39 +2946,44 @@ open_socket( /* * IPv4 specific options go here */ - if (addr->ss_family == AF_INET) { -#if defined(IPTOS_LOWDELAY) && defined(IPPROTO_IP) && defined(IP_TOS) - /* set IP_TOS to minimize packet delay */ - tos = IPTOS_LOWDELAY; - if (setsockopt(fd, IPPROTO_IP, IP_TOS, (char *) &tos, sizeof(tos)) < 0) - { - netsyslog(LOG_ERR, "setsockopt IPTOS_LOWDELAY on fails on address %s: %m", - stoa(addr)); - } -#endif /* IPTOS_LOWDELAY && IPPROTO_IP && IP_TOS */ + if (IS_IPV4(addr)) { +#if defined(IPPROTO_IP) && defined(IP_TOS) + if (setsockopt(fd, IPPROTO_IP, IP_TOS, (char*)&qos, + sizeof(qos))) + msyslog(LOG_ERR, + "setsockopt IP_TOS (%02x) fails on address %s: %m", + qos, stoa(addr)); +#endif /* IPPROTO_IP && IP_TOS */ + if (bcast) + socket_broadcast_enable(interf, fd, addr); } /* * IPv6 specific options go here */ - if (addr->ss_family == AF_INET6) { -#if defined(IPV6_V6ONLY) - if (setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, - (char*)&on, sizeof(on))) - { - netsyslog(LOG_ERR, "setsockopt IPV6_V6ONLY on fails on address %s: %m", + if (IS_IPV6(addr)) { +#if defined(IPPROTO_IPV6) && defined(IPV6_TCLASS) + if (setsockopt(fd, IPPROTO_IPV6, IPV6_TCLASS, (char*)&qos, + sizeof(qos))) + msyslog(LOG_ERR, + "setsockopt IPV6_TCLASS (%02x) fails on address %s: %m", + qos, stoa(addr)); +#endif /* IPPROTO_IPV6 && IPV6_TCLASS */ +#ifdef IPV6_V6ONLY + if (isc_net_probe_ipv6only() == ISC_R_SUCCESS + && setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, + (char*)&on, sizeof(on))) + msyslog(LOG_ERR, + "setsockopt IPV6_V6ONLY on fails on address %s: %m", stoa(addr)); - } -#endif /* IPV6_V6ONLY */ -#if defined(IPV6_BINDV6ONLY) - if (setsockopt(fd, IPPROTO_IPV6, IPV6_BINDV6ONLY, - (char*)&on, sizeof(on))) - { - netsyslog(LOG_ERR, - "setsockopt IPV6_BINDV6ONLY on fails on address %s: %m", - stoa(addr)); - } -#endif /* IPV6_BINDV6ONLY */ +#endif +#ifdef IPV6_BINDV6ONLY + if (setsockopt(fd, IPPROTO_IPV6, IPV6_BINDV6ONLY, + (char*)&on, sizeof(on))) + msyslog(LOG_ERR, + "setsockopt IPV6_BINDV6ONLY on fails on address %s: %m", + stoa(addr)); +#endif } #ifdef OS_NEEDS_REUSEADDR_FOR_IFADDRBIND @@ -2486,25 +2992,18 @@ open_socket( * addresses if a wildcard address already bound * to the port and SO_REUSEADDR is not set */ - if (!is_wildcard_addr(addr)) { - set_wildcard_reuse(addr->ss_family, 1); - } + if (!is_wildcard_addr(addr)) + set_wildcard_reuse(AF(addr), 1); #endif /* * bind the local address. */ - errval = bind(fd, (struct sockaddr *)addr, SOCKLEN(addr)); + errval = bind(fd, &addr->sa, SOCKLEN(addr)); #ifdef OS_NEEDS_REUSEADDR_FOR_IFADDRBIND - /* - * some OSes don't allow binding to more specific - * addresses if a wildcard address already bound - * to the port and REUSE_ADDR is not set - */ - if (!is_wildcard_addr(addr)) { - set_wildcard_reuse(addr->ss_family, 0); - } + if (!is_wildcard_addr(addr)) + set_wildcard_reuse(AF(addr), 0); #endif if (errval < 0) { @@ -2515,32 +3014,17 @@ open_socket( #ifdef DEBUG || debug > 1 #endif - ) { - if (addr->ss_family == AF_INET) - netsyslog(LOG_ERR, - "bind() fd %d, family AF_INET, port %d, addr %s, in_classd=%d flags=0x%x fails: %m", - fd, (int)ntohs(((struct sockaddr_in*)addr)->sin_port), - stoa(addr), - IN_CLASSD(ntohl(((struct sockaddr_in*)addr)->sin_addr.s_addr)), - flags); -#ifdef INCLUDE_IPV6_SUPPORT - else if (addr->ss_family == AF_INET6) - netsyslog(LOG_ERR, - "bind() fd %d, family AF_INET6, port %d, scope %d, addr %s, mcast=%d flags=0x%x fails: %m", - fd, (int)ntohs(((struct sockaddr_in6*)addr)->sin6_port), -# ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)addr)->sin6_scope_id -# else - -1 -# endif - , stoa(addr), - IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)addr)->sin6_addr), - flags); -#endif + ) { + msyslog(LOG_ERR, + "bind(%d) AF_INET%s %s#%d%s flags 0x%x failed: %m", + fd, IS_IPV6(addr) ? "6" : "", + stoa(addr), SRCPORT(addr), + IS_MCAST(addr) ? " (multicast)" : "", + interf->flags); } closesocket(fd); - + return INVALID_SOCKET; } @@ -2548,28 +3032,45 @@ open_socket( { if (setsockopt(fd, SOL_SOCKET, SO_TIMESTAMP, (char*)&on, sizeof(on))) - { - netsyslog(LOG_DEBUG, - "setsockopt SO_TIMESTAMP on fails on address %s: %m", - stoa(addr)); - } -#ifdef DEBUG + msyslog(LOG_DEBUG, + "setsockopt SO_TIMESTAMP on fails on address %s: %m", + stoa(addr)); else - { - DPRINTF(4, ("setsockopt SO_TIMESTAMP enabled on fd %d address %s\n", fd, stoa(addr))); - } + DPRINTF(4, ("setsockopt SO_TIMESTAMP enabled on fd %d address %s\n", + fd, stoa(addr))); + } +#endif +#ifdef HAVE_TIMESTAMPNS + { + if (setsockopt(fd, SOL_SOCKET, SO_TIMESTAMPNS, + (char*)&on, sizeof(on))) + msyslog(LOG_DEBUG, + "setsockopt SO_TIMESTAMPNS on fails on address %s: %m", + stoa(addr)); + else + DPRINTF(4, ("setsockopt SO_TIMESTAMPNS enabled on fd %d address %s\n", + fd, stoa(addr))); + } #endif - } +#ifdef HAVE_BINTIME + { + if (setsockopt(fd, SOL_SOCKET, SO_BINTIME, + (char*)&on, sizeof(on))) + msyslog(LOG_DEBUG, + "setsockopt SO_BINTIME on fails on address %s: %m", + stoa(addr)); + else + DPRINTF(4, ("setsockopt SO_BINTIME enabled on fd %d address %s\n", + fd, stoa(addr))); + } #endif - DPRINTF(4, ("bind() fd %d, family %d, port %d, addr %s, flags=0x%x\n", - fd, - addr->ss_family, - (int)ntohs(((struct sockaddr_in*)addr)->sin_port), - stoa(addr), - interf->flags)); - init_nonblocking_io(fd); - + DPRINTF(4, ("bind(%d) AF_INET%s, addr %s%%%d#%d, flags 0x%x\n", + fd, IS_IPV6(addr) ? "6" : "", stoa(addr), + SCOPE(addr), SRCPORT(addr), interf->flags)); + + make_socket_nonblocking(fd); + #ifdef HAVE_SIGNALED_IO init_socket_sig(fd); #endif /* not HAVE_SIGNALED_IO */ @@ -2585,233 +3086,123 @@ open_socket( /* * Add the socket to the completion port */ - if (io_completion_port_add_socket(fd, interf)) - { + if (io_completion_port_add_socket(fd, interf)) { msyslog(LOG_ERR, "unable to set up io completion port - EXITING"); exit(1); } #endif - return fd; -} - -/* XXX ELIMINATE sendpkt similar in ntpq.c, ntpdc.c, ntp_io.c, ntptrace.c */ -/* - * sendpkt - send a packet to the specified destination. Maintain a - * send error cache so that only the first consecutive error for a - * destination is logged. - */ -void -sendpkt( - struct sockaddr_storage *dest, - struct interface *inter, - int ttl, - struct pkt *pkt, - int len - ) -{ - int cc, slot; - - /* - * Send error caches. Empty slots have port == 0 - * Set ERRORCACHESIZE to 0 to disable - */ - struct cache { - u_short port; - struct in_addr addr; - }; - -#ifdef INCLUDE_IPV6_SUPPORT - struct cache6 { - u_short port; - struct in6_addr addr; - }; -#endif /* INCLUDE_IPV6_SUPPORT */ - - -#ifndef ERRORCACHESIZE -#define ERRORCACHESIZE 8 -#endif -#if ERRORCACHESIZE > 0 - static struct cache badaddrs[ERRORCACHESIZE]; -#ifdef INCLUDE_IPV6_SUPPORT - static struct cache6 badaddrs6[ERRORCACHESIZE]; -#endif /* INCLUDE_IPV6_SUPPORT */ -#else -#define badaddrs ((struct cache *)0) /* Only used in empty loops! */ -#ifdef INCLUDE_IPV6_SUPPORT -#define badaddrs6 ((struct cache6 *)0) /* Only used in empty loops! */ -#endif /* INCLUDE_IPV6_SUPPORT */ -#endif -#ifdef DEBUG - if (debug > 1) - { - if (inter != NULL) - { - printf("%ssendpkt(fd=%d dst=%s, src=%s, ttl=%d, len=%d)\n", - (ttl > 0) ? "\tMCAST\t***** " : "", - inter->fd, stoa(dest), - stoa(&inter->sin), ttl, len); - } - else - { - printf("%ssendpkt(dst=%s, ttl=%d, len=%d): no interface - IGNORED\n", - (ttl > 0) ? "\tMCAST\t***** " : "", - stoa(dest), - ttl, len); - } - } -#endif - - if (inter == NULL) /* unbound peer - drop request and wait for better network conditions */ - return; - -#ifdef MCAST - - /* - * for the moment we use the bcast option to set multicast ttl - */ - if (ttl > 0 && ttl != inter->last_ttl) { - - /* - * set the multicast ttl for outgoing packets - */ - int rtc; - - switch (inter->sin.ss_family) { - - case AF_INET : - { - u_char mttl = (u_char) ttl; - - rtc = setsockopt(inter->fd, IPPROTO_IP, IP_MULTICAST_TTL, - (const void *) &mttl, sizeof(mttl)); - break; - } - -#ifdef INCLUDE_IPV6_SUPPORT - case AF_INET6 : - { - u_int ittl = (u_char) ttl; - - rtc = setsockopt(inter->fd, IPPROTO_IPV6, IPV6_MULTICAST_HOPS, - (const void *) &ittl, sizeof(ittl)); - break; - } - -#endif /* INCLUDE_IPV6_SUPPORT */ - default: /* just NOP if not supported */ - rtc = 0; - break; - } - - if (rtc != 0) { - netsyslog(LOG_ERR, "setsockopt IP_MULTICAST_TTL/IPV6_MULTICAST_HOPS fails on address %s: %m", - stoa(&inter->sin)); - } - else - inter->last_ttl = ttl; - } - -#endif /* MCAST */ - - for (slot = ERRORCACHESIZE; --slot >= 0; ) - if(dest->ss_family == AF_INET) { - if (badaddrs[slot].port == SRCPORT(dest) && - badaddrs[slot].addr.s_addr == ((struct sockaddr_in*)dest)->sin_addr.s_addr) - break; - } -#ifdef INCLUDE_IPV6_SUPPORT - else if (dest->ss_family == AF_INET6) { - if (badaddrs6[slot].port == SRCPORT(dest) && - !memcmp(&badaddrs6[slot].addr, &((struct sockaddr_in6*)dest)->sin6_addr, sizeof(struct in6_addr))) - break; - } -#endif /* INCLUDE_IPV6_SUPPORT */ - -#if defined(HAVE_IO_COMPLETION_PORT) - cc = io_completion_port_sendto(inter, pkt, len, dest); - if (cc != ERROR_SUCCESS) -#else -#ifdef SIM - cc = srvr_rply(&ntp_node, dest, inter, pkt); -#else /* SIM */ - cc = sendto(inter->fd, (char *)pkt, (unsigned int)len, 0, (struct sockaddr *)dest, - SOCKLEN(dest)); -#endif /* SIM */ - if (cc == -1) -#endif - { - inter->notsent++; - packets_notsent++; + return fd; +} -#if defined(HAVE_IO_COMPLETION_PORT) - if (cc != WSAEWOULDBLOCK && cc != WSAENOBUFS && slot < 0) -#else - if (errno != EWOULDBLOCK && errno != ENOBUFS && slot < 0) + +#ifdef SYS_WINNT +#define sendto(fd, buf, len, flags, dest, destsz) \ + io_completion_port_sendto(fd, buf, len, (sockaddr_u *)(dest)) #endif - { + +/* XXX ELIMINATE sendpkt similar in ntpq.c, ntpdc.c, ntp_io.c, ntptrace.c */ +/* + * sendpkt - send a packet to the specified destination. Maintain a + * send error cache so that only the first consecutive error for a + * destination is logged. + */ +void +sendpkt( + sockaddr_u * dest, + struct interface * ep, + int ttl, + struct pkt * pkt, + int len + ) +{ + endpt * src; + int ismcast; + int cc; + int rc; + u_char cttl; + + ismcast = IS_MCAST(dest); + if (!ismcast) + src = ep; + else + src = (IS_IPV4(dest)) + ? mc4_list + : mc6_list; + + if (NULL == src) { + /* + * unbound peer - drop request and wait for better + * network conditions + */ + DPRINTF(2, ("%ssendpkt(dst=%s, ttl=%d, len=%d): no interface - IGNORED\n", + ismcast ? "\tMCAST\t***** " : "", + stoa(dest), ttl, len)); + return; + } + + do { + DPRINTF(2, ("%ssendpkt(%d, dst=%s, src=%s, ttl=%d, len=%d)\n", + ismcast ? "\tMCAST\t***** " : "", src->fd, + stoa(dest), stoa(&src->sin), ttl, len)); +#ifdef MCAST + /* + * for the moment we use the bcast option to set multicast ttl + */ + if (ismcast && ttl > 0 && ttl != src->last_ttl) { /* - * Remember this, if there's an empty slot + * set the multicast ttl for outgoing packets */ - switch (dest->ss_family) { + switch (AF(&src->sin)) { case AF_INET : - - for (slot = ERRORCACHESIZE; --slot >= 0; ) - if (badaddrs[slot].port == 0) - { - badaddrs[slot].port = SRCPORT(dest); - badaddrs[slot].addr = ((struct sockaddr_in*)dest)->sin_addr; - break; - } + cttl = (u_char)ttl; + rc = setsockopt(src->fd, IPPROTO_IP, + IP_MULTICAST_TTL, + (void *)&cttl, + sizeof(cttl)); break; -#ifdef INCLUDE_IPV6_SUPPORT +# ifdef INCLUDE_IPV6_SUPPORT case AF_INET6 : - - for (slot = ERRORCACHESIZE; --slot >= 0; ) - if (badaddrs6[slot].port == 0) - { - badaddrs6[slot].port = SRCPORT(dest); - badaddrs6[slot].addr = ((struct sockaddr_in6*)dest)->sin6_addr; - break; - } - break; -#endif /* INCLUDE_IPV6_SUPPORT */ - default: /* don't care if not supported */ + rc = setsockopt(src->fd, IPPROTO_IPV6, + IPV6_MULTICAST_HOPS, + (void *)&ttl, + sizeof(ttl)); break; +# endif /* INCLUDE_IPV6_SUPPORT */ + + default: + rc = 0; } - netsyslog(LOG_ERR, "sendto(%s) (fd=%d): %m", - stoa(dest), inter->fd); + if (!rc) + src->last_ttl = ttl; + else + msyslog(LOG_ERR, + "setsockopt IP_MULTICAST_TTL/IPV6_MULTICAST_HOPS fails on address %s: %m", + stoa(&src->sin)); } - } - else - { - inter->sent++; - packets_sent++; - /* - * He's not bad any more - */ - if (slot >= 0) - { - netsyslog(LOG_INFO, "Connection re-established to %s", stoa(dest)); - switch (dest->ss_family) { - case AF_INET : - badaddrs[slot].port = 0; - break; -#ifdef INCLUDE_IPV6_SUPPORT - case AF_INET6 : - badaddrs6[slot].port = 0; - break; -#endif /* INCLUDE_IPV6_SUPPORT */ - default: /* don't care if not supported */ - break; - } +#endif /* MCAST */ + +#ifdef SIM + cc = simulate_server(dest, src, pkt); +#else + cc = sendto(src->fd, (char *)pkt, (u_int)len, 0, + &dest->sa, SOCKLEN(dest)); +#endif + if (cc == -1) { + src->notsent++; + packets_notsent++; + } else { + src->sent++; + packets_sent++; } - } + if (ismcast) + src = src->mclink; + } while (ismcast && src != NULL); } + #if !defined(HAVE_IO_COMPLETION_PORT) /* * fdbits - generate ascii representation of fd_set (FAU debug support) @@ -2826,10 +3217,9 @@ fdbits( static char buffer[256]; char * buf = buffer; - count = (count < 256) ? count : 255; + count = min(count, 255); - while (count >= 0) - { + while (count >= 0) { *buf++ = FD_ISSET(count, set) ? '#' : '-'; count--; } @@ -2838,22 +3228,29 @@ fdbits( return buffer; } + +#ifdef REFCLOCK /* * Routine to read the refclock packets for a specific interface * Return the number of bytes read. That way we know if we should * read it again or go on to the next one if no bytes returned */ static inline int -read_refclock_packet(SOCKET fd, struct refclockio *rp, l_fp ts) +read_refclock_packet( + SOCKET fd, + struct refclockio * rp, + l_fp ts + ) { - int i; - int buflen; - register struct recvbuf *rb; + u_int read_count; + int buflen; + int saved_errno; + int consumed; + struct recvbuf * rb; rb = get_free_recv_buffer(); - if (rb == NULL) - { + if (NULL == rb) { /* * No buffer space available - just drop the packet */ @@ -2864,18 +3261,22 @@ read_refclock_packet(SOCKET fd, struct refclockio *rp, l_fp ts) return (buflen); } - i = (rp->datalen == 0 - || rp->datalen > sizeof(rb->recv_space)) - ? sizeof(rb->recv_space) : rp->datalen; - buflen = read(fd, (char *)&rb->recv_space, (unsigned)i); + /* TALOS-CAN-0064: avoid signed/unsigned clashes that can lead + * to buffer overrun and memory corruption + */ + if (rp->datalen <= 0 || rp->datalen > sizeof(rb->recv_space)) + read_count = sizeof(rb->recv_space); + else + read_count = (u_int)rp->datalen; + do { + buflen = read(fd, (char *)&rb->recv_space, read_count); + } while (buflen < 0 && EINTR == errno); - if (buflen < 0) - { - if (errno != EINTR && errno != EAGAIN) { - netsyslog(LOG_ERR, "clock read fd %d: %m", fd); - } + if (buflen <= 0) { + saved_errno = errno; freerecvbuf(rb); - return (buflen); + errno = saved_errno; + return buflen; } /* @@ -2883,85 +3284,141 @@ read_refclock_packet(SOCKET fd, struct refclockio *rp, l_fp ts) * put it on the full list and do bookkeeping. */ rb->recv_length = buflen; - rb->recv_srcclock = rp->srcclock; + rb->recv_peer = rp->srcclock; rb->dstadr = 0; rb->fd = fd; rb->recv_time = ts; rb->receiver = rp->clock_recv; - if (rp->io_input) - { - /* - * have direct input routine for refclocks - */ - if (rp->io_input(rb) == 0) - { - /* - * data was consumed - nothing to pass up - * into block input machine - */ - freerecvbuf(rb); - return (buflen); - } + consumed = indicate_refclock_packet(rp, rb); + if (!consumed) { + rp->recvcount++; + packets_received++; } - - add_full_recv_buffer(rb); - rp->recvcount++; - packets_received++; - return (buflen); + return buflen; } +#endif /* REFCLOCK */ -#ifdef HAVE_TIMESTAMP + +#ifdef HAVE_PACKET_TIMESTAMP /* * extract timestamps from control message buffer */ static l_fp - fetch_timestamp(struct recvbuf *rb, struct msghdr *msghdr, l_fp ts) +fetch_timestamp( + struct recvbuf * rb, + struct msghdr * msghdr, + l_fp ts + ) { -#ifdef USE_TIMESTAMP_CMSG - struct cmsghdr *cmsghdr; + struct cmsghdr * cmsghdr; +#ifdef HAVE_BINTIME + struct bintime * btp; +#endif +#ifdef HAVE_TIMESTAMPNS + struct timespec * tsp; +#endif +#ifdef HAVE_TIMESTAMP + struct timeval * tvp; +#endif + unsigned long ticks; + double fuzz; + l_fp lfpfuzz; + l_fp nts; +#ifdef DEBUG_TIMING + l_fp dts; +#endif cmsghdr = CMSG_FIRSTHDR(msghdr); while (cmsghdr != NULL) { switch (cmsghdr->cmsg_type) { +#ifdef HAVE_BINTIME + case SCM_BINTIME: +#endif /* HAVE_BINTIME */ +#ifdef HAVE_TIMESTAMPNS + case SCM_TIMESTAMPNS: +#endif /* HAVE_TIMESTAMPNS */ +#ifdef HAVE_TIMESTAMP case SCM_TIMESTAMP: - { - struct timeval *tvp = (struct timeval *)CMSG_DATA(cmsghdr); - double dtemp; - l_fp nts; - DPRINTF(4, ("fetch_timestamp: system network time stamp: %ld.%06ld\n", tvp->tv_sec, tvp->tv_usec)); - nts.l_i = tvp->tv_sec + JAN_1970; - dtemp = tvp->tv_usec / 1e6; - - /* fuzz lower bits not covered by precision */ - if (sys_precision != 0) - dtemp += (ntp_random() / FRAC - .5) / (1 << - -sys_precision); - - nts.l_uf = (u_int32)(dtemp*FRAC); -#ifdef DEBUG_TIMING +#endif /* HAVE_TIMESTAMP */ +#if defined(HAVE_BINTIME) || defined (HAVE_TIMESTAMPNS) || defined(HAVE_TIMESTAMP) + switch (cmsghdr->cmsg_type) { - l_fp dts = ts; - L_SUB(&dts, &nts); - collect_timing(rb, "input processing delay", 1, &dts); - DPRINTF(4, ("fetch_timestamp: timestamp delta: %s (incl. prec fuzz)\n", lfptoa(&dts, 9))); +#ifdef HAVE_BINTIME + case SCM_BINTIME: + btp = (struct bintime *)CMSG_DATA(cmsghdr); + /* + * bintime documentation is at http://phk.freebsd.dk/pubs/timecounter.pdf + */ + nts.l_i = btp->sec + JAN_1970; + nts.l_uf = (u_int32)(btp->frac >> 32); + if (sys_tick > measured_tick && + sys_tick > 1e-9) { + ticks = (unsigned long)(nts.l_uf / (unsigned long)(sys_tick * FRAC)); + nts.l_uf = (unsigned long)(ticks * (unsigned long)(sys_tick * FRAC)); + } + DPRINTF(4, ("fetch_timestamp: system bintime network time stamp: %ld.%09lu\n", + btp->sec, (unsigned long)((nts.l_uf / FRAC) * 1e9))); + break; +#endif /* HAVE_BINTIME */ +#ifdef HAVE_TIMESTAMPNS + case SCM_TIMESTAMPNS: + tsp = (struct timespec *)CMSG_DATA(cmsghdr); + if (sys_tick > measured_tick && + sys_tick > 1e-9) { + ticks = (unsigned long)((tsp->tv_nsec * 1e-9) / + sys_tick); + tsp->tv_nsec = (long)(ticks * 1e9 * + sys_tick); + } + DPRINTF(4, ("fetch_timestamp: system nsec network time stamp: %ld.%09ld\n", + tsp->tv_sec, tsp->tv_nsec)); + nts = tspec_stamp_to_lfp(*tsp); + break; +#endif /* HAVE_TIMESTAMPNS */ +#ifdef HAVE_TIMESTAMP + case SCM_TIMESTAMP: + tvp = (struct timeval *)CMSG_DATA(cmsghdr); + if (sys_tick > measured_tick && + sys_tick > 1e-6) { + ticks = (unsigned long)((tvp->tv_usec * 1e-6) / + sys_tick); + tvp->tv_usec = (long)(ticks * 1e6 * + sys_tick); + } + DPRINTF(4, ("fetch_timestamp: system usec network time stamp: %jd.%06ld\n", + (intmax_t)tvp->tv_sec, (long)tvp->tv_usec)); + nts = tval_stamp_to_lfp(*tvp); + break; +#endif /* HAVE_TIMESTAMP */ } -#endif + fuzz = ntp_random() * 2. / FRAC * sys_fuzz; + DTOLFP(fuzz, &lfpfuzz); + L_ADD(&nts, &lfpfuzz); +#ifdef DEBUG_TIMING + dts = ts; + L_SUB(&dts, &nts); + collect_timing(rb, "input processing delay", 1, + &dts); + DPRINTF(4, ("fetch_timestamp: timestamp delta: %s (incl. fuzz)\n", + lfptoa(&dts, 9))); +#endif /* DEBUG_TIMING */ ts = nts; /* network time stamp */ break; - } +#endif /* HAVE_BINTIME || HAVE_TIMESTAMPNS || HAVE_TIMESTAMP */ + default: - DPRINTF(4, ("fetch_timestamp: skipping control message 0x%x\n", cmsghdr->cmsg_type)); - break; + DPRINTF(4, ("fetch_timestamp: skipping control message 0x%x\n", + cmsghdr->cmsg_type)); } cmsghdr = CMSG_NXTHDR(msghdr, cmsghdr); } -#endif return ts; } -#endif +#endif /* HAVE_PACKET_TIMESTAMP */ + /* * Routine to read the network NTP packets for a specific interface @@ -2969,15 +3426,19 @@ static l_fp * read it again or go on to the next one if no bytes returned */ static inline int -read_network_packet(SOCKET fd, struct interface *itf, l_fp ts) +read_network_packet( + SOCKET fd, + struct interface * itf, + l_fp ts + ) { GETSOCKNAME_SOCKLEN_TYPE fromlen; int buflen; register struct recvbuf *rb; -#ifdef HAVE_TIMESTAMP +#ifdef HAVE_PACKET_TIMESTAMP struct msghdr msghdr; struct iovec iovec; - char control[TIMESTAMP_CTLMSGBUF_SIZE]; /* pick up control messages */ + char control[CMSG_BUFSIZE]; #endif /* @@ -2988,41 +3449,39 @@ read_network_packet(SOCKET fd, struct interface *itf, l_fp ts) */ rb = get_free_recv_buffer(); - - if (rb == NULL || itf->ignore_packets == ISC_TRUE) - { + if (NULL == rb || itf->ignore_packets) { char buf[RX_BUFF_SIZE]; - struct sockaddr_storage from; + sockaddr_u from; + if (rb != NULL) freerecvbuf(rb); fromlen = sizeof(from); buflen = recvfrom(fd, buf, sizeof(buf), 0, - (struct sockaddr*)&from, &fromlen); + &from.sa, &fromlen); DPRINTF(4, ("%s on (%lu) fd=%d from %s\n", - (itf->ignore_packets == ISC_TRUE) ? "ignore" : "drop", - free_recvbuffs(), fd, - stoa(&from))); - if (itf->ignore_packets == ISC_TRUE) + (itf->ignore_packets) + ? "ignore" + : "drop", + free_recvbuffs(), fd, stoa(&from))); + if (itf->ignore_packets) packets_ignored++; else packets_dropped++; return (buflen); } - fromlen = sizeof(struct sockaddr_storage); + fromlen = sizeof(rb->recv_srcadr); -#ifndef HAVE_TIMESTAMP - rb->recv_length = recvfrom(fd, - (char *)&rb->recv_space, - sizeof(rb->recv_space), 0, - (struct sockaddr *)&rb->recv_srcadr, - &fromlen); +#ifndef HAVE_PACKET_TIMESTAMP + rb->recv_length = recvfrom(fd, (char *)&rb->recv_space, + sizeof(rb->recv_space), 0, + &rb->recv_srcadr.sa, &fromlen); #else - iovec.iov_base = (void *)&rb->recv_space; + iovec.iov_base = &rb->recv_space; iovec.iov_len = sizeof(rb->recv_space); - msghdr.msg_name = (void *)&rb->recv_srcadr; - msghdr.msg_namelen = sizeof(rb->recv_srcadr); + msghdr.msg_name = &rb->recv_srcadr; + msghdr.msg_namelen = fromlen; msghdr.msg_iov = &iovec; msghdr.msg_iovlen = 1; msghdr.msg_control = (void *)&control; @@ -3033,38 +3492,48 @@ read_network_packet(SOCKET fd, struct interface *itf, l_fp ts) buflen = rb->recv_length; - if (buflen == 0 || (buflen == -1 && - (errno==EWOULDBLOCK + if (buflen == 0 || (buflen == -1 && + (EWOULDBLOCK == errno #ifdef EAGAIN - || errno==EAGAIN + || EAGAIN == errno #endif - ))) { + ))) { freerecvbuf(rb); return (buflen); - } - else if (buflen < 0) - { - netsyslog(LOG_ERR, "recvfrom(%s) fd=%d: %m", - stoa(&rb->recv_srcadr), fd); - DPRINTF(5, ("read_network_packet: fd=%d dropped (bad recvfrom)\n", fd)); + } else if (buflen < 0) { + msyslog(LOG_ERR, "recvfrom(%s) fd=%d: %m", + stoa(&rb->recv_srcadr), fd); + DPRINTF(5, ("read_network_packet: fd=%d dropped (bad recvfrom)\n", + fd)); freerecvbuf(rb); return (buflen); } -#ifdef DEBUG - if (debug > 2) { - if(rb->recv_srcadr.ss_family == AF_INET) - printf("read_network_packet: fd=%d length %d from %08lx %s\n", - fd, buflen, - (u_long)ntohl(((struct sockaddr_in*)&rb->recv_srcadr)->sin_addr.s_addr) & - 0x00000000ffffffff, - stoa(&rb->recv_srcadr)); - else - printf("read_network_packet: fd=%d length %d from %s\n", - fd, buflen, - stoa(&rb->recv_srcadr)); + DPRINTF(3, ("read_network_packet: fd=%d length %d from %s\n", + fd, buflen, stoa(&rb->recv_srcadr))); + + /* + ** Bug 2672: Some OSes (MacOSX and Linux) don't block spoofed ::1 + */ + + if (AF_INET6 == itf->family) { + DPRINTF(2, ("Got an IPv6 packet, from <%s> (%d) to <%s> (%d)\n", + stoa(&rb->recv_srcadr), + IN6_IS_ADDR_LOOPBACK(PSOCK_ADDR6(&rb->recv_srcadr)), + stoa(&itf->sin), + !IN6_IS_ADDR_LOOPBACK(PSOCK_ADDR6(&itf->sin)) + )); + + if ( IN6_IS_ADDR_LOOPBACK(PSOCK_ADDR6(&rb->recv_srcadr)) + && !IN6_IS_ADDR_LOOPBACK(PSOCK_ADDR6(&itf->sin)) + ) { + packets_dropped++; + DPRINTF(2, ("DROPPING that packet\n")); + freerecvbuf(rb); + return buflen; + } + DPRINTF(2, ("processing that packet\n")); } -#endif /* * Got one. Mark how and when it got here, @@ -3072,8 +3541,9 @@ read_network_packet(SOCKET fd, struct interface *itf, l_fp ts) */ rb->dstadr = itf; rb->fd = fd; -#ifdef HAVE_TIMESTAMP - ts = fetch_timestamp(rb, &msghdr, ts); /* pick up a network time stamp if possible */ +#ifdef HAVE_PACKET_TIMESTAMP + /* pick up a network time stamp if possible */ + ts = fetch_timestamp(rb, &msghdr, ts); #endif rb->recv_time = ts; rb->receiver = receive; @@ -3086,35 +3556,106 @@ read_network_packet(SOCKET fd, struct interface *itf, l_fp ts) } /* - * input_handler - receive packets asynchronously + * attempt to handle io (select()/signaled IO) */ void +io_handler(void) +{ +# ifndef HAVE_SIGNALED_IO + fd_set rdfdes; + int nfound; + + /* + * Use select() on all on all input fd's for unlimited + * time. select() will terminate on SIGALARM or on the + * reception of input. Using select() means we can't do + * robust signal handling and we get a potential race + * between checking for alarms and doing the select(). + * Mostly harmless, I think. + */ + /* + * On VMS, I suspect that select() can't be interrupted + * by a "signal" either, so I take the easy way out and + * have select() time out after one second. + * System clock updates really aren't time-critical, + * and - lacking a hardware reference clock - I have + * yet to learn about anything else that is. + */ + rdfdes = activefds; +# if !defined(VMS) && !defined(SYS_VXWORKS) + nfound = select(maxactivefd + 1, &rdfdes, NULL, + NULL, NULL); +# else /* VMS, VxWorks */ + /* make select() wake up after one second */ + { + struct timeval t1; + + t1.tv_sec = 1; + t1.tv_usec = 0; + nfound = select(maxactivefd + 1, + &rdfdes, NULL, NULL, + &t1); + } +# endif /* VMS, VxWorks */ + if (nfound > 0) { + l_fp ts; + + get_systime(&ts); + + input_handler(&ts); + } else if (nfound == -1 && errno != EINTR) { + msyslog(LOG_ERR, "select() error: %m"); + } +# ifdef DEBUG + else if (debug > 4) { + msyslog(LOG_DEBUG, "select(): nfound=%d, error: %m", nfound); + } else { + DPRINTF(3, ("select() returned %d: %m\n", nfound)); + } +# endif /* DEBUG */ +# else /* HAVE_SIGNALED_IO */ + wait_for_signal(); +# endif /* HAVE_SIGNALED_IO */ +} + +/* + * input_handler - receive packets asynchronously + */ +static void input_handler( - l_fp *cts + l_fp * cts ) { - - int buflen; - int n; - int doing; - SOCKET fd; - struct timeval tvzero; - l_fp ts; /* Timestamp at BOselect() gob */ + int buflen; + int n; + u_int idx; + int doing; + SOCKET fd; + blocking_child *c; + struct timeval tvzero; + l_fp ts; /* Timestamp at BOselect() gob */ #ifdef DEBUG_TIMING - l_fp ts_e; /* Timestamp at EOselect() gob */ + l_fp ts_e; /* Timestamp at EOselect() gob */ +#endif + fd_set fds; + size_t select_count; + endpt * ep; +#ifdef REFCLOCK + struct refclockio *rp; + int saved_errno; + const char * clk; #endif - fd_set fds; - int select_count = 0; - struct interface *interface; -#if defined(HAS_ROUTING_SOCKET) - struct asyncio_reader *asyncio_reader; +#ifdef HAS_ROUTING_SOCKET + struct asyncio_reader * asyncio_reader; + struct asyncio_reader * next_asyncio_reader; #endif handler_calls++; + select_count = 0; /* * If we have something to do, freeze a timestamp. - * See below for the other cases (nothing (left) to do or error) + * See below for the other cases (nothing left to do or error) */ ts = *cts; @@ -3125,33 +3666,43 @@ input_handler( fds = activefds; tvzero.tv_sec = tvzero.tv_usec = 0; - n = select(maxactivefd+1, &fds, (fd_set *)0, (fd_set *)0, &tvzero); + n = select(maxactivefd + 1, &fds, (fd_set *)0, (fd_set *)0, + &tvzero); /* * If there are no packets waiting just return */ - if (n < 0) - { + if (n < 0) { int err = errno; + int j, b, prior; /* * extended FAU debugging output */ if (err != EINTR) - netsyslog(LOG_ERR, - "select(%d, %s, 0L, 0L, &0.0) error: %m", - maxactivefd+1, - fdbits(maxactivefd, &activefds)); - if (err == EBADF) { - int j, b; - fds = activefds; - for (j = 0; j <= maxactivefd; j++) - if ((FD_ISSET(j, &fds) && (read(j, &b, 0) == -1))) - netsyslog(LOG_ERR, "Bad file descriptor %d", j); + msyslog(LOG_ERR, + "select(%d, %s, 0L, 0L, &0.0) error: %m", + maxactivefd + 1, + fdbits(maxactivefd, &activefds)); + if (err != EBADF) + goto ih_return; + for (j = 0, prior = 0; j <= maxactivefd; j++) { + if (FD_ISSET(j, &activefds)) { + if (-1 != read(j, &b, 0)) { + prior = j; + continue; + } + msyslog(LOG_ERR, + "Removing bad file descriptor %d from select set", + j); + FD_CLR(j, &activefds); + if (j == maxactivefd) + maxactivefd = prior; + } } - return; + goto ih_return; } else if (n == 0) - return; + goto ih_return; ++handler_pkts; @@ -3160,55 +3711,64 @@ input_handler( * Check out the reference clocks first, if any */ - if (refio != NULL) - { - register struct refclockio *rp; - - for (rp = refio; rp != NULL; rp = rp->next) - { + if (refio != NULL) { + for (rp = refio; rp != NULL; rp = rp->next) { fd = rp->fd; - if (FD_ISSET(fd, &fds)) - { + if (!FD_ISSET(fd, &fds)) + continue; + ++select_count; + buflen = read_refclock_packet(fd, rp, ts); + /* + * The first read must succeed after select() + * indicates readability, or we've reached + * a permanent EOF. http://bugs.ntp.org/1732 + * reported ntpd munching CPU after a USB GPS + * was unplugged because select was indicating + * EOF but ntpd didn't remove the descriptor + * from the activefds set. + */ + if (buflen < 0 && EAGAIN != errno) { + saved_errno = errno; + clk = refnumtoa(&rp->srcclock->srcadr); + errno = saved_errno; + msyslog(LOG_ERR, "%s read: %m", clk); + maintain_activefds(fd, TRUE); + } else if (0 == buflen) { + clk = refnumtoa(&rp->srcclock->srcadr); + msyslog(LOG_ERR, "%s read EOF", clk); + maintain_activefds(fd, TRUE); + } else { + /* drain any remaining refclock input */ do { - ++select_count; buflen = read_refclock_packet(fd, rp, ts); } while (buflen > 0); - - } /* End if (FD_ISSET(fd, &fds)) */ - } /* End for (rp = refio; rp != 0 && n > 0; rp = rp->next) */ - } /* End if (refio != 0) */ - + } + } + } #endif /* REFCLOCK */ /* * Loop through the interfaces looking for data to read. */ - for (interface = ISC_LIST_TAIL(inter_list); - interface != NULL; - interface = ISC_LIST_PREV(interface, link)) - { - for (doing = 0; (doing < 2); doing++) - { - if (doing == 0) - { - fd = interface->fd; - } - else - { - if (!(interface->flags & INT_BCASTOPEN)) - break; - fd = interface->bfd; + for (ep = ep_list; ep != NULL; ep = ep->elink) { + for (doing = 0; doing < 2; doing++) { + if (!doing) { + fd = ep->fd; + } else { + if (!(ep->flags & INT_BCASTOPEN)) + break; + fd = ep->bfd; } - if (fd < 0) continue; + if (fd < 0) + continue; if (FD_ISSET(fd, &fds)) - { do { ++select_count; - buflen = read_network_packet(fd, interface, ts); + buflen = read_network_packet( + fd, ep, ts); } while (buflen > 0); - } - /* Check more interfaces */ + /* Check more interfaces */ } } @@ -3216,36 +3776,45 @@ input_handler( /* * scan list of asyncio readers - currently only used for routing sockets */ - asyncio_reader = ISC_LIST_TAIL(asyncio_reader_list); + asyncio_reader = asyncio_reader_list; - while (asyncio_reader != NULL) - { - struct asyncio_reader *next = ISC_LIST_PREV(asyncio_reader, link); + while (asyncio_reader != NULL) { + /* callback may unlink and free asyncio_reader */ + next_asyncio_reader = asyncio_reader->link; if (FD_ISSET(asyncio_reader->fd, &fds)) { ++select_count; - asyncio_reader->receiver(asyncio_reader); + (*asyncio_reader->receiver)(asyncio_reader); } - asyncio_reader = next; + asyncio_reader = next_asyncio_reader; } #endif /* HAS_ROUTING_SOCKET */ - + /* - * Done everything from that select. + * Check for a response from a blocking child */ + for (idx = 0; idx < blocking_children_alloc; idx++) { + c = blocking_children[idx]; + if (NULL == c || -1 == c->resp_read_pipe) + continue; + if (FD_ISSET(c->resp_read_pipe, &fds)) { + select_count++; + process_blocking_resp(c); + } + } /* + * Done everything from that select. * If nothing to do, just return. * If an error occurred, complain and return. */ - if (select_count == 0) /* We really had nothing to do */ - { + if (select_count == 0) { /* We really had nothing to do */ #ifdef DEBUG if (debug) - netsyslog(LOG_DEBUG, "input_handler: select() returned 0"); -#endif - return; + msyslog(LOG_DEBUG, "input_handler: select() returned 0"); +#endif /* DEBUG */ + goto ih_return; } - /* We've done our work */ + /* We've done our work */ #ifdef DEBUG_TIMING get_systime(&ts_e); /* @@ -3256,44 +3825,109 @@ input_handler( L_SUB(&ts_e, &ts); collect_timing(NULL, "input handler", 1, &ts_e); if (debug > 3) - netsyslog(LOG_INFO, "input_handler: Processed a gob of fd's in %s msec", lfptoms(&ts_e, 6)); -#endif - /* just bail. */ + msyslog(LOG_DEBUG, + "input_handler: Processed a gob of fd's in %s msec", + lfptoms(&ts_e, 6)); +#endif /* DEBUG_TIMING */ + /* We're done... */ + ih_return: return; } +#endif /* !HAVE_IO_COMPLETION_PORT */ + + +/* + * find an interface suitable for the src address + */ +endpt * +select_peerinterface( + struct peer * peer, + sockaddr_u * srcadr, + endpt * dstadr + ) +{ + endpt *ep; +#ifndef SIM + endpt *wild; + + wild = ANY_INTERFACE_CHOOSE(srcadr); + /* + * Initialize the peer structure and dance the interface jig. + * Reference clocks step the loopback waltz, the others + * squaredance around the interface list looking for a buddy. If + * the dance peters out, there is always the wildcard interface. + * This might happen in some systems and would preclude proper + * operation with public key cryptography. + */ + if (ISREFCLOCKADR(srcadr)) { + ep = loopback_interface; + } else if (peer->cast_flags & + (MDF_BCLNT | MDF_ACAST | MDF_MCAST | MDF_BCAST)) { + ep = findbcastinter(srcadr); + if (ep != NULL) + DPRINTF(4, ("Found *-cast interface %s for address %s\n", + stoa(&ep->sin), stoa(srcadr))); + else + DPRINTF(4, ("No *-cast local address found for address %s\n", + stoa(srcadr))); + } else { + ep = dstadr; + if (NULL == ep) + ep = wild; + } + /* + * If it is a multicast address, findbcastinter() may not find + * it. For unicast, we get to find the interface when dstadr is + * given to us as the wildcard (ANY_INTERFACE_CHOOSE). Either + * way, try a little harder. + */ + if (wild == ep) + ep = findinterface(srcadr); + /* + * we do not bind to the wildcard interfaces for output + * as our (network) source address would be undefined and + * crypto will not work without knowing the own transmit address + */ + if (ep != NULL && INT_WILDCARD & ep->flags) + if (!accept_wildcard_if_for_winnt) + ep = NULL; +#else /* SIM follows */ + ep = loopback_interface; #endif + return ep; +} + + /* * findinterface - find local interface corresponding to address */ -struct interface * +endpt * findinterface( - struct sockaddr_storage *addr + sockaddr_u *addr ) { - struct interface *interface; - - interface = findlocalinterface(addr, INT_WILDCARD); + endpt *iface; - if (interface == NULL) - { + iface = findlocalinterface(addr, INT_WILDCARD, 0); + + if (NULL == iface) { DPRINTF(4, ("Found no interface for address %s - returning wildcard\n", stoa(addr))); - return (ANY_INTERFACE_CHOOSE(addr)); - } - else - { + iface = ANY_INTERFACE_CHOOSE(addr); + } else DPRINTF(4, ("Found interface #%d %s for address %s\n", - interface->ifnum, interface->name, stoa(addr))); + iface->ifnum, iface->name, stoa(addr))); - return (interface); - } + return iface; } /* - * findlocalinterface - find local interface index corresponding to address + * findlocalinterface - find local interface corresponding to addr, + * which does not have any of flags set. If bast is nonzero, addr is + * a broadcast address. * * This code attempts to find the local sending address for an outgoing * address by connecting a new socket to destinationaddress:NTP_PORT @@ -3305,246 +3939,307 @@ findinterface( * logic in ntpd which would be a silly and really unportable thing to do. * */ -static struct interface * +static endpt * findlocalinterface( - struct sockaddr_storage *addr, - int flags + sockaddr_u * addr, + int flags, + int bcast ) { - SOCKET s; - int rtn; - struct sockaddr_storage saddr; - GETSOCKNAME_SOCKLEN_TYPE saddrlen = SOCKLEN(addr); - struct interface *iface; + GETSOCKNAME_SOCKLEN_TYPE sockaddrlen; + endpt * iface; + sockaddr_u saddr; + SOCKET s; + int rtn; + int on; DPRINTF(4, ("Finding interface for addr %s in list of addresses\n", stoa(addr))); - memset(&saddr, 0, sizeof(saddr)); - saddr.ss_family = addr->ss_family; - if(addr->ss_family == AF_INET) { - memcpy(&((struct sockaddr_in*)&saddr)->sin_addr, &((struct sockaddr_in*)addr)->sin_addr, sizeof(struct in_addr)); - ((struct sockaddr_in*)&saddr)->sin_port = htons(NTP_PORT); - } -#ifdef INCLUDE_IPV6_SUPPORT - else if(addr->ss_family == AF_INET6) { - memcpy(&((struct sockaddr_in6*)&saddr)->sin6_addr, &((struct sockaddr_in6*)addr)->sin6_addr, sizeof(struct in6_addr)); - ((struct sockaddr_in6*)&saddr)->sin6_port = htons(NTP_PORT); -# ifdef ISC_PLATFORM_HAVESCOPEID - ((struct sockaddr_in6*)&saddr)->sin6_scope_id = ((struct sockaddr_in6*)addr)->sin6_scope_id; -# endif - } -#endif - - s = socket(addr->ss_family, SOCK_DGRAM, 0); - if (s == INVALID_SOCKET) + s = socket(AF(addr), SOCK_DGRAM, 0); + if (INVALID_SOCKET == s) return NULL; - rtn = connect(s, (struct sockaddr *)&saddr, SOCKLEN(&saddr)); -#ifndef SYS_WINNT - if (rtn < 0) -#else - if (rtn == SOCKET_ERROR) -#endif - { + /* + * If we are looking for broadcast interface we need to set this + * socket to allow broadcast + */ + if (bcast) { + on = 1; + if (SOCKET_ERROR == setsockopt(s, SOL_SOCKET, + SO_BROADCAST, + (char *)&on, + sizeof(on))) { + closesocket(s); + return NULL; + } + } + + rtn = connect(s, &addr->sa, SOCKLEN(addr)); + if (SOCKET_ERROR == rtn) { closesocket(s); return NULL; } - rtn = getsockname(s, (struct sockaddr *)&saddr, &saddrlen); + sockaddrlen = sizeof(saddr); + rtn = getsockname(s, &saddr.sa, &sockaddrlen); closesocket(s); -#ifndef SYS_WINNT - if (rtn < 0) -#else - if (rtn == SOCKET_ERROR) -#endif + if (SOCKET_ERROR == rtn) return NULL; - DPRINTF(4, ("findlocalinterface: kernel maps %s to %s\n", stoa(addr), stoa(&saddr))); - + DPRINTF(4, ("findlocalinterface: kernel maps %s to %s\n", + stoa(addr), stoa(&saddr))); + iface = getinterface(&saddr, flags); - /* Don't both with ignore interfaces */ - if (iface != NULL && iface->ignore_packets == ISC_TRUE) - { - return NULL; + /* + * if we didn't find an exact match on saddr, find the closest + * available local address. This handles the case of the + * address suggested by the kernel being excluded by nic rules + * or the user's -I and -L options to ntpd. + * See http://bugs.ntp.org/1184 and http://bugs.ntp.org/1683 + * for more background. + */ + if (NULL == iface || iface->ignore_packets) + iface = findclosestinterface(&saddr, + flags | INT_LOOPBACK); + + /* Don't use an interface which will ignore replies */ + if (iface != NULL && iface->ignore_packets) + iface = NULL; + + return iface; +} + + +/* + * findclosestinterface + * + * If there are -I/--interface or -L/novirtualips command-line options, + * or "nic" or "interface" rules in ntp.conf, findlocalinterface() may + * find the kernel's preferred local address for a given peer address is + * administratively unavailable to ntpd, and punt to this routine's more + * expensive search. + * + * Find the numerically closest local address to the one connect() + * suggested. This matches an address on the same subnet first, as + * needed by Bug 1184, and provides a consistent choice if there are + * multiple feasible local addresses, regardless of the order ntpd + * enumerated them. + */ +endpt * +findclosestinterface( + sockaddr_u * addr, + int flags + ) +{ + endpt * ep; + endpt * winner; + sockaddr_u addr_dist; + sockaddr_u min_dist; + + ZERO_SOCK(&min_dist); + winner = NULL; + + for (ep = ep_list; ep != NULL; ep = ep->elink) { + if (ep->ignore_packets || + AF(addr) != ep->family || + flags & ep->flags) + continue; + + calc_addr_distance(&addr_dist, addr, &ep->sin); + if (NULL == winner || + -1 == cmp_addr_distance(&addr_dist, &min_dist)) { + min_dist = addr_dist; + winner = ep; + } } + if (NULL == winner) + DPRINTF(4, ("findclosestinterface(%s) failed\n", + stoa(addr))); else - { - return iface; - } + DPRINTF(4, ("findclosestinterface(%s) -> %s\n", + stoa(addr), stoa(&winner->sin))); + + return winner; } + /* - * fetch an interface structure the matches the - * address is has the given flags not set + * calc_addr_distance - calculate the distance between two addresses, + * the absolute value of the difference between + * the addresses numerically, stored as an address. */ -static struct interface * -getinterface(struct sockaddr_storage *addr, int flags) +static void +calc_addr_distance( + sockaddr_u * dist, + const sockaddr_u * a1, + const sockaddr_u * a2 + ) { - struct interface *interface = find_addr_in_list(addr); + u_int32 a1val; + u_int32 a2val; + u_int32 v4dist; + int found_greater; + int a1_greater; + int i; + + REQUIRE(AF(a1) == AF(a2)); + + ZERO_SOCK(dist); + AF(dist) = AF(a1); + + /* v4 can be done a bit simpler */ + if (IS_IPV4(a1)) { + a1val = SRCADR(a1); + a2val = SRCADR(a2); + v4dist = (a1val > a2val) + ? a1val - a2val + : a2val - a1val; + SET_ADDR4(dist, v4dist); - if (interface != NULL && interface->flags & flags) - { - return NULL; + return; } - else - { - return interface; + + found_greater = FALSE; + a1_greater = FALSE; /* suppress pot. uninit. warning */ + for (i = 0; i < (int)sizeof(NSRCADR6(a1)); i++) { + if (!found_greater && + NSRCADR6(a1)[i] != NSRCADR6(a2)[i]) { + found_greater = TRUE; + a1_greater = (NSRCADR6(a1)[i] > NSRCADR6(a2)[i]); + } + if (!found_greater) { + NSRCADR6(dist)[i] = 0; + } else { + if (a1_greater) + NSRCADR6(dist)[i] = NSRCADR6(a1)[i] - + NSRCADR6(a2)[i]; + else + NSRCADR6(dist)[i] = NSRCADR6(a2)[i] - + NSRCADR6(a1)[i]; + } } } + /* - * findlocalcastinterface - find local *cast interface index corresponding to address - * depending on the flags passed + * cmp_addr_distance - compare two address distances, returning -1, 0, + * 1 to indicate their relationship. */ -static struct interface * -findlocalcastinterface( - struct sockaddr_storage *addr, int flags +static int +cmp_addr_distance( + const sockaddr_u * d1, + const sockaddr_u * d2 ) { - struct interface *interface; - struct interface *nif = NULL; -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - isc_boolean_t want_linklocal; -#endif + int i; - /* - * see how kernel maps the mcast address - */ - nif = findlocalinterface(addr, 0); + REQUIRE(AF(d1) == AF(d2)); - if (nif) { - DPRINTF(2, ("findlocalcastinterface: kernel recommends interface #%d %s\n", nif->ifnum, nif->name)); - return nif; + if (IS_IPV4(d1)) { + if (SRCADR(d1) < SRCADR(d2)) + return -1; + else if (SRCADR(d1) == SRCADR(d2)) + return 0; + else + return 1; } -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - want_linklocal = ISC_FALSE; - if (addr_ismulticast(addr) && flags == INT_MULTICAST) - { - if (IN6_IS_ADDR_MC_LINKLOCAL(&((struct sockaddr_in6*)addr)->sin6_addr)) - { - want_linklocal = ISC_TRUE; - } - else if (IN6_IS_ADDR_MC_SITELOCAL(&((struct sockaddr_in6*)addr)->sin6_addr)) - { - want_linklocal = ISC_TRUE; - } + for (i = 0; i < (int)sizeof(NSRCADR6(d1)); i++) { + if (NSRCADR6(d1)[i] < NSRCADR6(d2)[i]) + return -1; + else if (NSRCADR6(d1)[i] > NSRCADR6(d2)[i]) + return 1; } -#endif - for (interface = ISC_LIST_HEAD(inter_list); - interface != NULL; - interface = ISC_LIST_NEXT(interface, link)) - { - /* use only allowed addresses */ - if (interface->ignore_packets == ISC_TRUE) - continue; + return 0; +} - /* Skip the loopback and wildcard addresses */ - if (interface->flags & (INT_LOOPBACK|INT_WILDCARD)) - continue; - /* Skip if different family */ - if(interface->sin.ss_family != addr->ss_family) - continue; - /* Is this it one of these based on flags? */ - if (!(interface->flags & flags)) - continue; +/* + * fetch an interface structure the matches the + * address and has the given flags NOT set + */ +endpt * +getinterface( + sockaddr_u * addr, + u_int32 flags + ) +{ + endpt *iface; - /* for IPv6 multicast check the address for linklocal */ -#ifdef INCLUDE_IPV6_MULTICAST_SUPPORT - if (flags == INT_MULTICAST && interface->sin.ss_family == AF_INET6 && - (IN6_IS_ADDR_LINKLOCAL(&((struct sockaddr_in6*)&interface->sin)->sin6_addr)) - && want_linklocal == ISC_TRUE) - { - nif = interface; - break; - } - /* If we want a linklocal address and this isn't it, skip */\ - if (want_linklocal == ISC_TRUE) - continue; -#endif - /* Otherwise just look for the flag */ - if((interface->flags & flags)) - { - nif = interface; - break; - } - } -#ifdef DEBUG - if (debug > 2) - { - if (nif) - printf("findlocalcastinterface: found interface #%d %s\n", nif->ifnum, nif->name); - else - printf("findlocalcastinterface: no interface found for %s flags 0x%x\n", stoa(addr), flags); - } -#endif - return (nif); + iface = find_addr_in_list(addr); + + if (iface != NULL && (iface->flags & flags)) + iface = NULL; + + return iface; } + /* * findbcastinter - find broadcast interface corresponding to address */ -struct interface * +endpt * findbcastinter( - struct sockaddr_storage *addr + sockaddr_u *addr ) { + endpt * iface; + + iface = NULL; #if !defined(MPE) && (defined(SIOCGIFCONF) || defined(SYS_WINNT)) - struct interface *interface; - - DPRINTF(4, ("Finding broadcast/multicast interface for addr %s in list of addresses\n", stoa(addr))); - interface = findlocalinterface(addr, INT_LOOPBACK|INT_WILDCARD); - - if (interface != NULL) - { - DPRINTF(4, ("Found bcast-/mcast- interface index #%d %s\n", interface->ifnum, interface->name)); - return interface; + iface = findlocalinterface(addr, INT_LOOPBACK | INT_WILDCARD, + 1); + if (iface != NULL) { + DPRINTF(4, ("Easily found bcast-/mcast- interface index #%d %s\n", + iface->ifnum, iface->name)); + return iface; } - /* plan B - try to find something reasonable in our lists in case kernel lookup doesn't help */ + /* + * plan B - try to find something reasonable in our lists in + * case kernel lookup doesn't help + */ + for (iface = ep_list; iface != NULL; iface = iface->elink) { + if (iface->flags & INT_WILDCARD) + continue; - for (interface = ISC_LIST_HEAD(inter_list); - interface != NULL; - interface = ISC_LIST_NEXT(interface, link)) - { - if (interface->flags & INT_WILDCARD) - continue; - /* Don't bother with ignored interfaces */ - if (interface->ignore_packets == ISC_TRUE) + if (iface->ignore_packets) continue; - + /* * First look if this is the correct family */ - if(interface->sin.ss_family != addr->ss_family) - continue; + if(AF(&iface->sin) != AF(addr)) + continue; /* Skip the loopback addresses */ - if (interface->flags & INT_LOOPBACK) + if (iface->flags & INT_LOOPBACK) continue; /* - * If we are looking to match a multicast address grab it. + * If we are looking to match a multicast address and + * this interface is one... */ - if (addr_ismulticast(addr) == ISC_TRUE && interface->flags & INT_MULTICAST) - { + if (addr_ismulticast(addr) + && (iface->flags & INT_MULTICAST)) { #ifdef INCLUDE_IPV6_SUPPORT - if(addr->ss_family == AF_INET6) { - /* Only use link-local address for link-scope mcast */ - if(IN6_IS_ADDR_MC_LINKLOCAL(&((struct sockaddr_in6*)addr)->sin6_addr) && - !IN6_IS_ADDR_LINKLOCAL(&((struct sockaddr_in6*)&interface->sin)->sin6_addr)) { - continue; - } - } + /* + * ...it is the winner unless we're looking for + * an interface to use for link-local multicast + * and its address is not link-local. + */ + if (IS_IPV6(addr) + && IN6_IS_ADDR_MC_LINKLOCAL(PSOCK_ADDR6(addr)) + && !IN6_IS_ADDR_LINKLOCAL(PSOCK_ADDR6(&iface->sin))) + continue; #endif break; } @@ -3555,34 +4250,35 @@ findbcastinter( * address or the network portion of the IP address. * Sloppy. */ - if(addr->ss_family == AF_INET) { - if (SOCKCMP(&interface->bcast, addr)) { + if (IS_IPV4(addr)) { + if (SOCK_EQ(&iface->bcast, addr)) break; - } - if ((NSRCADR(&interface->sin) & - NSRCADR(&interface->mask)) == (NSRCADR(addr) & - NSRCADR(&interface->mask))) + + if ((NSRCADR(&iface->sin) & NSRCADR(&iface->mask)) + == (NSRCADR(addr) & NSRCADR(&iface->mask))) break; } #ifdef INCLUDE_IPV6_SUPPORT - else if(addr->ss_family == AF_INET6) { - if (SOCKCMP(&interface->bcast, addr)) { + else if (IS_IPV6(addr)) { + if (SOCK_EQ(&iface->bcast, addr)) break; - } - if (SOCKCMP(netof(&interface->sin), netof(addr))) { + + if (SOCK_EQ(netof(&iface->sin), netof(addr))) break; - } } #endif } #endif /* SIOCGIFCONF */ - if (interface == NULL) { - DPRINTF(4, ("No bcast interface found for %s\n", stoa(addr))); - return ANY_INTERFACE_CHOOSE(addr); + if (NULL == iface) { + DPRINTF(4, ("No bcast interface found for %s\n", + stoa(addr))); + iface = ANY_INTERFACE_CHOOSE(addr); } else { - DPRINTF(4, ("Found bcast-/mcast- interface index #%d %s\n", interface->ifnum, interface->name)); - return interface; + DPRINTF(4, ("Found bcast-/mcast- interface index #%d %s\n", + iface->ifnum, iface->name)); } + + return iface; } @@ -3615,21 +4311,20 @@ io_addclock( ) { BLOCKIO(); + /* * Stuff the I/O structure in the list and mark the descriptor - * in use. There is a harmless (I hope) race condition here. + * in use. There is a harmless (I hope) race condition here. */ - rio->next = refio; + rio->active = TRUE; # ifdef HAVE_SIGNALED_IO - if (init_clock_sig(rio)) - { + if (init_clock_sig(rio)) { UNBLOCKIO(); return 0; } # elif defined(HAVE_IO_COMPLETION_PORT) - if (io_completion_port_add_clock_io(rio)) - { + if (io_completion_port_add_clock_io(rio)) { UNBLOCKIO(); return 0; } @@ -3638,9 +4333,9 @@ io_addclock( /* * enqueue */ - refio = rio; + LINK_SLIST(refio, rio, next); - /* + /* * register fd */ add_fd_to_list(rio->fd, FD_TYPE_FILE); @@ -3649,6 +4344,7 @@ io_addclock( return 1; } + /* * io_closeclock - close the clock in the I/O structure given */ @@ -3657,267 +4353,270 @@ io_closeclock( struct refclockio *rio ) { + struct refclockio *unlinked; + BLOCKIO(); + /* * Remove structure from the list */ - if (refio == rio) - { - refio = rio->next; - } - else - { - register struct refclockio *rp; - - for (rp = refio; rp != NULL; rp = rp->next) - if (rp->next == rio) - { - rp->next = rio->next; - break; - } - - if (rp == NULL) { - UNBLOCKIO(); - return; - } + rio->active = FALSE; + UNLINK_SLIST(unlinked, refio, rio, next, struct refclockio); + if (NULL != unlinked) { + purge_recv_buffers_for_fd(rio->fd); + /* + * Close the descriptor. + */ + close_and_delete_fd_from_list(rio->fd); } + rio->fd = -1; - /* - * Close the descriptor. - */ - close_and_delete_fd_from_list(rio->fd); UNBLOCKIO(); } #endif /* REFCLOCK */ + /* * On NT a SOCKET is an unsigned int so we cannot possibly keep it in * an array. So we use one of the ISC_LIST functions to hold the * socket value and use that when we want to enumerate it. + * + * This routine is called by the forked intres child process to close + * all open sockets. On Windows there's no need as intres runs in + * the same process as a thread. */ +#ifndef SYS_WINNT void -kill_asyncio(int startfd) +kill_asyncio( + int startfd + ) { - vsock_t *lsock; - vsock_t *next; - BLOCKIO(); - lsock = ISC_LIST_HEAD(fd_list); - while (lsock != NULL) { - /* - * careful here - list is being dismantled while - * we scan it - setting next here insures that - * we are able to correctly scan the list - */ - next = ISC_LIST_NEXT(lsock, link); - /* - * will remove socket from list - */ - close_and_delete_fd_from_list(lsock->fd); - lsock = next; - } + /* + * In the child process we do not maintain activefds and + * maxactivefd. Zeroing maxactivefd disables code which + * maintains it in close_and_delete_fd_from_list(). + */ + maxactivefd = 0; + + while (fd_list != NULL) + close_and_delete_fd_from_list(fd_list->fd); UNBLOCKIO(); } +#endif /* !SYS_WINNT */ + /* * Add and delete functions for the list of open sockets */ static void -add_fd_to_list(SOCKET fd, enum desc_type type) { - vsock_t *lsock = (vsock_t *)emalloc(sizeof(vsock_t)); +add_fd_to_list( + SOCKET fd, + enum desc_type type + ) +{ + vsock_t *lsock = emalloc(sizeof(*lsock)); + lsock->fd = fd; lsock->type = type; - ISC_LIST_APPEND(fd_list, lsock, link); - /* - * I/O Completion Ports don't care about the select and FD_SET - */ -#ifndef HAVE_IO_COMPLETION_PORT - if (fd < 0 || fd >= FD_SETSIZE) { - msyslog(LOG_ERR, "Too many sockets in use, FD_SETSIZE %d exceeded", - FD_SETSIZE); - exit(1); - } - /* - * keep activefds in sync - */ - if (fd > maxactivefd) - maxactivefd = fd; - FD_SET( (u_int)fd, &activefds); -#endif + LINK_SLIST(fd_list, lsock, link); + maintain_activefds(fd, 0); } + static void -close_and_delete_fd_from_list(SOCKET fd) { +close_and_delete_fd_from_list( + SOCKET fd + ) +{ + vsock_t *lsock; - vsock_t *next; - vsock_t *lsock = ISC_LIST_HEAD(fd_list); + UNLINK_EXPR_SLIST(lsock, fd_list, fd == + UNLINK_EXPR_SLIST_CURRENT()->fd, link, vsock_t); - while(lsock != NULL) { - next = ISC_LIST_NEXT(lsock, link); - if(lsock->fd == fd) { - ISC_LIST_DEQUEUE_TYPE(fd_list, lsock, link, vsock_t); + if (NULL == lsock) + return; - switch (lsock->type) { - case FD_TYPE_SOCKET: -#ifdef SYS_WINNT - closesocket(lsock->fd); - break; -#endif - case FD_TYPE_FILE: - (void) close(lsock->fd); - break; - default: - msyslog(LOG_ERR, "internal error - illegal descriptor type %d - EXITING", (int)lsock->type); - exit(1); - } + switch (lsock->type) { - free(lsock); - /* - * I/O Completion Ports don't care about select and fd_set - */ -#ifndef HAVE_IO_COMPLETION_PORT - /* - * remove from activefds - */ - FD_CLR( (u_int) fd, &activefds); - - if (fd == maxactivefd) { - int i, newmax = 0; - for (i = 0; i < maxactivefd; i++) - if (FD_ISSET(i, &activefds)) - newmax = i; - maxactivefd = newmax; - } -#endif - break; - } - lsock = next; + case FD_TYPE_SOCKET: + closesocket(lsock->fd); + break; + + case FD_TYPE_FILE: + closeserial(lsock->fd); + break; + + default: + msyslog(LOG_ERR, + "internal error - illegal descriptor type %d - EXITING", + (int)lsock->type); + exit(1); } + + free(lsock); + /* + * remove from activefds + */ + maintain_activefds(fd, 1); } + static void -add_addr_to_list(struct sockaddr_storage *addr, struct interface *interface){ +add_addr_to_list( + sockaddr_u * addr, + endpt * ep + ) +{ + remaddr_t *laddr; + #ifdef DEBUG if (find_addr_in_list(addr) == NULL) { #endif /* not there yet - add to list */ - remaddr_t *laddr = (remaddr_t *)emalloc(sizeof(remaddr_t)); - memcpy(&laddr->addr, addr, sizeof(struct sockaddr_storage)); - laddr->interface = interface; - - ISC_LIST_APPEND(remoteaddr_list, laddr, link); - + laddr = emalloc(sizeof(*laddr)); + laddr->addr = *addr; + laddr->ep = ep; + + LINK_SLIST(remoteaddr_list, laddr, link); + DPRINTF(4, ("Added addr %s to list of addresses\n", stoa(addr))); #ifdef DEBUG - } else { + } else DPRINTF(4, ("WARNING: Attempt to add duplicate addr %s to address list\n", stoa(addr))); - } #endif } + static void -delete_addr_from_list(struct sockaddr_storage *addr) { - - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); - - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if(SOCKCMP(&laddr->addr, addr)) { - ISC_LIST_DEQUEUE_TYPE(remoteaddr_list, laddr, link, remaddr_t); - DPRINTF(4, ("Deleted addr %s from list of addresses\n", - stoa(addr))); - free(laddr); - break; - } - laddr = next; +delete_addr_from_list( + sockaddr_u *addr + ) +{ + remaddr_t *unlinked; + + UNLINK_EXPR_SLIST(unlinked, remoteaddr_list, SOCK_EQ(addr, + &(UNLINK_EXPR_SLIST_CURRENT()->addr)), link, remaddr_t); + + if (unlinked != NULL) { + DPRINTF(4, ("Deleted addr %s from list of addresses\n", + stoa(addr))); + free(unlinked); } } + static void -delete_interface_from_list(struct interface *iface) { - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); - - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if (laddr->interface == iface) { - ISC_LIST_DEQUEUE_TYPE(remoteaddr_list, laddr, link, remaddr_t); - DPRINTF(4, ("Deleted addr %s for interface #%d %s from list of addresses\n", - stoa(&laddr->addr), iface->ifnum, iface->name)); - free(laddr); - } - laddr = next; +delete_interface_from_list( + endpt *iface + ) +{ + remaddr_t *unlinked; + + for (;;) { + UNLINK_EXPR_SLIST(unlinked, remoteaddr_list, iface == + UNLINK_EXPR_SLIST_CURRENT()->ep, link, + remaddr_t); + + if (unlinked == NULL) + break; + DPRINTF(4, ("Deleted addr %s for interface #%d %s from list of addresses\n", + stoa(&unlinked->addr), iface->ifnum, + iface->name)); + free(unlinked); } } + static struct interface * -find_addr_in_list(struct sockaddr_storage *addr) { +find_addr_in_list( + sockaddr_u *addr + ) +{ + remaddr_t *entry; - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); DPRINTF(4, ("Searching for addr %s in list of addresses - ", stoa(addr))); - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if(SOCKCMP(&laddr->addr, addr)) { + for (entry = remoteaddr_list; + entry != NULL; + entry = entry->link) + if (SOCK_EQ(&entry->addr, addr)) { DPRINTF(4, ("FOUND\n")); - return laddr->interface; + return entry->ep; } - else - laddr = next; - } + DPRINTF(4, ("NOT FOUND\n")); - return NULL; /* Not found */ + return NULL; } + /* - * Find the given address with the associated flag in the list + * Find the given address with the all given flags set in the list */ -static struct interface * -find_flagged_addr_in_list(struct sockaddr_storage *addr, int flag) { +static endpt * +find_flagged_addr_in_list( + sockaddr_u * addr, + u_int32 flags + ) +{ + remaddr_t *entry; - remaddr_t *next; - remaddr_t *laddr = ISC_LIST_HEAD(remoteaddr_list); - DPRINTF(4, ("Finding addr %s in list of addresses\n", - stoa(addr))); + DPRINTF(4, ("Finding addr %s with flags %d in list: ", + stoa(addr), flags)); - while(laddr != NULL) { - next = ISC_LIST_NEXT(laddr, link); - if(SOCKCMP(&laddr->addr, addr) && (laddr->interface->flags & flag)) { - return laddr->interface; - break; + for (entry = remoteaddr_list; + entry != NULL; + entry = entry->link) + + if (SOCK_EQ(&entry->addr, addr) + && (entry->ep->flags & flags) == flags) { + + DPRINTF(4, ("FOUND\n")); + return entry->ep; } - else - laddr = next; - } - return NULL; /* Not found */ + + DPRINTF(4, ("NOT FOUND\n")); + return NULL; } -#ifdef HAS_ROUTING_SOCKET -#include -#ifndef UPDATE_GRACE -#define UPDATE_GRACE 2 /* wait UPDATE_GRACE seconds before scanning */ -#endif +const char * +localaddrtoa( + endpt *la + ) +{ + return (NULL == la) + ? "" + : stoa(&la->sin); +} + + +#ifdef HAS_ROUTING_SOCKET +# ifndef UPDATE_GRACE +# define UPDATE_GRACE 2 /* wait UPDATE_GRACE seconds before scanning */ +# endif static void process_routing_msgs(struct asyncio_reader *reader) { char buffer[5120]; - char *p = buffer; + int cnt, msg_type; +#ifdef HAVE_RTNETLINK + struct nlmsghdr *nh; +#else + struct rt_msghdr rtm; + char *p; +#endif - int cnt; - if (disable_dynamic_updates) { /* - * discard ourselves if we are not need any more + * discard ourselves if we are not needed any more * usually happens when running unprivileged */ remove_asyncio_reader(reader); @@ -3926,30 +4625,45 @@ process_routing_msgs(struct asyncio_reader *reader) } cnt = read(reader->fd, buffer, sizeof(buffer)); - + if (cnt < 0) { - msyslog(LOG_ERR, "i/o error on routing socket %m - disabling"); - remove_asyncio_reader(reader); - delete_asyncio_reader(reader); + if (errno == ENOBUFS) { + msyslog(LOG_ERR, + "routing socket reports: %m"); + } else { + msyslog(LOG_ERR, + "routing socket reports: %m - disabling"); + remove_asyncio_reader(reader); + delete_asyncio_reader(reader); + } return; } /* * process routing message */ - while ((p + sizeof(struct rt_msghdr)) <= (buffer + cnt)) - { - struct rt_msghdr *rtm; - - rtm = (struct rt_msghdr *)p; - if (rtm->rtm_version != RTM_VERSION) { - msyslog(LOG_ERR, "version mismatch on routing socket %m - disabling"); +#ifdef HAVE_RTNETLINK + for (nh = (struct nlmsghdr *)buffer; + NLMSG_OK(nh, cnt); + nh = NLMSG_NEXT(nh, cnt)) { + msg_type = nh->nlmsg_type; +#else + for (p = buffer; + (p + sizeof(struct rt_msghdr)) <= (buffer + cnt); + p += rtm.rtm_msglen) { + memcpy(&rtm, p, sizeof(rtm)); + if (rtm.rtm_version != RTM_VERSION) { + msyslog(LOG_ERR, + "version mismatch (got %d - expected %d) on routing socket - disabling", + rtm.rtm_version, RTM_VERSION); + remove_asyncio_reader(reader); delete_asyncio_reader(reader); return; } - - switch (rtm->rtm_type) { + msg_type = rtm.rtm_type; +#endif + switch (msg_type) { #ifdef RTM_NEWADDR case RTM_NEWADDR: #endif @@ -3976,21 +4690,41 @@ process_routing_msgs(struct asyncio_reader *reader) #endif #ifdef RTM_IFANNOUNCE case RTM_IFANNOUNCE: +#endif +#ifdef RTM_NEWLINK + case RTM_NEWLINK: +#endif +#ifdef RTM_DELLINK + case RTM_DELLINK: +#endif +#ifdef RTM_NEWROUTE + case RTM_NEWROUTE: +#endif +#ifdef RTM_DELROUTE + case RTM_DELROUTE: #endif /* - * we are keen on new and deleted addresses and if an interface goes up and down or routing changes + * we are keen on new and deleted addresses and + * if an interface goes up and down or routing + * changes */ - DPRINTF(3, ("routing message op = %d: scheduling interface update\n", rtm->rtm_type)); + DPRINTF(3, ("routing message op = %d: scheduling interface update\n", + msg_type)); timer_interfacetimeout(current_time + UPDATE_GRACE); break; +#ifdef HAVE_RTNETLINK + case NLMSG_DONE: + /* end of multipart message */ + return; +#endif default: /* * the rest doesn't bother us. */ - DPRINTF(4, ("routing message op = %d: ignored\n", rtm->rtm_type)); + DPRINTF(4, ("routing message op = %d: ignored\n", + msg_type)); break; } - p += rtm->rtm_msglen; } } @@ -4001,29 +4735,52 @@ static void init_async_notifications() { struct asyncio_reader *reader; +#ifdef HAVE_RTNETLINK + int fd = socket(PF_NETLINK, SOCK_RAW, NETLINK_ROUTE); + struct sockaddr_nl sa; +#else int fd = socket(PF_ROUTE, SOCK_RAW, 0); - - if (fd >= 0) { - fd = move_fd(fd); - init_nonblocking_io(fd); +#endif + if (fd < 0) { + msyslog(LOG_ERR, + "unable to open routing socket (%m) - using polled interface update"); + return; + } + + fd = move_fd(fd); +#ifdef HAVE_RTNETLINK + ZERO(sa); + sa.nl_family = PF_NETLINK; + sa.nl_groups = RTMGRP_LINK | RTMGRP_IPV4_IFADDR + | RTMGRP_IPV6_IFADDR | RTMGRP_IPV4_ROUTE + | RTMGRP_IPV4_MROUTE | RTMGRP_IPV6_ROUTE + | RTMGRP_IPV6_MROUTE; + if (bind(fd, (struct sockaddr *)&sa, sizeof(sa)) < 0) { + msyslog(LOG_ERR, + "bind failed on routing socket (%m) - using polled interface update"); + return; + } +#endif + make_socket_nonblocking(fd); #if defined(HAVE_SIGNALED_IO) - init_socket_sig(fd); + init_socket_sig(fd); #endif /* HAVE_SIGNALED_IO */ - - reader = new_asyncio_reader(); - - reader->fd = fd; - reader->receiver = process_routing_msgs; - - add_asyncio_reader(reader, FD_TYPE_SOCKET); - msyslog(LOG_INFO, "Listening on routing socket on fd #%d for interface updates", fd); - } else { - msyslog(LOG_ERR, "unable to open routing socket (%m) - using polled interface update"); - } + + reader = new_asyncio_reader(); + + reader->fd = fd; + reader->receiver = process_routing_msgs; + + add_asyncio_reader(reader, FD_TYPE_SOCKET); + msyslog(LOG_INFO, + "Listening on routing socket on fd #%d for interface updates", + fd); } #else +/* HAS_ROUTING_SOCKET not defined */ static void -init_async_notifications() +init_async_notifications(void) { } #endif + diff --git a/contrib/ntp/ntpd/ntp_keyword.h b/contrib/ntp/ntpd/ntp_keyword.h new file mode 100644 index 000000000..0a593f69d --- /dev/null +++ b/contrib/ntp/ntpd/ntp_keyword.h @@ -0,0 +1,1068 @@ +/* + * ntp_keyword.h + * + * NOTE: edit this file with caution, it is generated by keyword-gen.c + * Generated 2015-06-25 03:57:00 UTC diff_ignore_line + * + */ +#include "ntp_scanner.h" +#include "ntp_parser.h" + +#define LOWEST_KEYWORD_ID 258 + +const char * const keyword_text[191] = { + /* 0 258 T_Abbrev */ "abbrev", + /* 1 259 T_Age */ "age", + /* 2 260 T_All */ "all", + /* 3 261 T_Allan */ "allan", + /* 4 262 T_Allpeers */ "allpeers", + /* 5 263 T_Auth */ "auth", + /* 6 264 T_Autokey */ "autokey", + /* 7 265 T_Automax */ "automax", + /* 8 266 T_Average */ "average", + /* 9 267 T_Bclient */ "bclient", + /* 10 268 T_Beacon */ "beacon", + /* 11 269 T_Broadcast */ "broadcast", + /* 12 270 T_Broadcastclient */ "broadcastclient", + /* 13 271 T_Broadcastdelay */ "broadcastdelay", + /* 14 272 T_Burst */ "burst", + /* 15 273 T_Calibrate */ "calibrate", + /* 16 274 T_Ceiling */ "ceiling", + /* 17 275 T_Clockstats */ "clockstats", + /* 18 276 T_Cohort */ "cohort", + /* 19 277 T_ControlKey */ "controlkey", + /* 20 278 T_Crypto */ "crypto", + /* 21 279 T_Cryptostats */ "cryptostats", + /* 22 280 T_Ctl */ "ctl", + /* 23 281 T_Day */ "day", + /* 24 282 T_Default */ "default", + /* 25 283 T_Digest */ "digest", + /* 26 284 T_Disable */ "disable", + /* 27 285 T_Discard */ "discard", + /* 28 286 T_Dispersion */ "dispersion", + /* 29 287 T_Double */ NULL, + /* 30 288 T_Driftfile */ "driftfile", + /* 31 289 T_Drop */ "drop", + /* 32 290 T_Dscp */ "dscp", + /* 33 291 T_Ellipsis */ "...", + /* 34 292 T_Enable */ "enable", + /* 35 293 T_End */ "end", + /* 36 294 T_False */ NULL, + /* 37 295 T_File */ "file", + /* 38 296 T_Filegen */ "filegen", + /* 39 297 T_Filenum */ "filenum", + /* 40 298 T_Flag1 */ "flag1", + /* 41 299 T_Flag2 */ "flag2", + /* 42 300 T_Flag3 */ "flag3", + /* 43 301 T_Flag4 */ "flag4", + /* 44 302 T_Flake */ "flake", + /* 45 303 T_Floor */ "floor", + /* 46 304 T_Freq */ "freq", + /* 47 305 T_Fudge */ "fudge", + /* 48 306 T_Host */ "host", + /* 49 307 T_Huffpuff */ "huffpuff", + /* 50 308 T_Iburst */ "iburst", + /* 51 309 T_Ident */ "ident", + /* 52 310 T_Ignore */ "ignore", + /* 53 311 T_Incalloc */ "incalloc", + /* 54 312 T_Incmem */ "incmem", + /* 55 313 T_Initalloc */ "initalloc", + /* 56 314 T_Initmem */ "initmem", + /* 57 315 T_Includefile */ "includefile", + /* 58 316 T_Integer */ NULL, + /* 59 317 T_Interface */ "interface", + /* 60 318 T_Intrange */ NULL, + /* 61 319 T_Io */ "io", + /* 62 320 T_Ipv4 */ "ipv4", + /* 63 321 T_Ipv4_flag */ "-4", + /* 64 322 T_Ipv6 */ "ipv6", + /* 65 323 T_Ipv6_flag */ "-6", + /* 66 324 T_Kernel */ "kernel", + /* 67 325 T_Key */ "key", + /* 68 326 T_Keys */ "keys", + /* 69 327 T_Keysdir */ "keysdir", + /* 70 328 T_Kod */ "kod", + /* 71 329 T_Mssntp */ "mssntp", + /* 72 330 T_Leapfile */ "leapfile", + /* 73 331 T_Leapsmearinterval */ "leapsmearinterval", + /* 74 332 T_Limited */ "limited", + /* 75 333 T_Link */ "link", + /* 76 334 T_Listen */ "listen", + /* 77 335 T_Logconfig */ "logconfig", + /* 78 336 T_Logfile */ "logfile", + /* 79 337 T_Loopstats */ "loopstats", + /* 80 338 T_Lowpriotrap */ "lowpriotrap", + /* 81 339 T_Manycastclient */ "manycastclient", + /* 82 340 T_Manycastserver */ "manycastserver", + /* 83 341 T_Mask */ "mask", + /* 84 342 T_Maxage */ "maxage", + /* 85 343 T_Maxclock */ "maxclock", + /* 86 344 T_Maxdepth */ "maxdepth", + /* 87 345 T_Maxdist */ "maxdist", + /* 88 346 T_Maxmem */ "maxmem", + /* 89 347 T_Maxpoll */ "maxpoll", + /* 90 348 T_Mdnstries */ "mdnstries", + /* 91 349 T_Mem */ "mem", + /* 92 350 T_Memlock */ "memlock", + /* 93 351 T_Minclock */ "minclock", + /* 94 352 T_Mindepth */ "mindepth", + /* 95 353 T_Mindist */ "mindist", + /* 96 354 T_Minimum */ "minimum", + /* 97 355 T_Minpoll */ "minpoll", + /* 98 356 T_Minsane */ "minsane", + /* 99 357 T_Mode */ "mode", + /* 100 358 T_Mode7 */ "mode7", + /* 101 359 T_Monitor */ "monitor", + /* 102 360 T_Month */ "month", + /* 103 361 T_Mru */ "mru", + /* 104 362 T_Multicastclient */ "multicastclient", + /* 105 363 T_Nic */ "nic", + /* 106 364 T_Nolink */ "nolink", + /* 107 365 T_Nomodify */ "nomodify", + /* 108 366 T_Nomrulist */ "nomrulist", + /* 109 367 T_None */ "none", + /* 110 368 T_Nonvolatile */ "nonvolatile", + /* 111 369 T_Nopeer */ "nopeer", + /* 112 370 T_Noquery */ "noquery", + /* 113 371 T_Noselect */ "noselect", + /* 114 372 T_Noserve */ "noserve", + /* 115 373 T_Notrap */ "notrap", + /* 116 374 T_Notrust */ "notrust", + /* 117 375 T_Ntp */ "ntp", + /* 118 376 T_Ntpport */ "ntpport", + /* 119 377 T_NtpSignDsocket */ "ntpsigndsocket", + /* 120 378 T_Orphan */ "orphan", + /* 121 379 T_Orphanwait */ "orphanwait", + /* 122 380 T_Panic */ "panic", + /* 123 381 T_Peer */ "peer", + /* 124 382 T_Peerstats */ "peerstats", + /* 125 383 T_Phone */ "phone", + /* 126 384 T_Pid */ "pid", + /* 127 385 T_Pidfile */ "pidfile", + /* 128 386 T_Pool */ "pool", + /* 129 387 T_Port */ "port", + /* 130 388 T_Preempt */ "preempt", + /* 131 389 T_Prefer */ "prefer", + /* 132 390 T_Protostats */ "protostats", + /* 133 391 T_Pw */ "pw", + /* 134 392 T_Randfile */ "randfile", + /* 135 393 T_Rawstats */ "rawstats", + /* 136 394 T_Refid */ "refid", + /* 137 395 T_Requestkey */ "requestkey", + /* 138 396 T_Reset */ "reset", + /* 139 397 T_Restrict */ "restrict", + /* 140 398 T_Revoke */ "revoke", + /* 141 399 T_Rlimit */ "rlimit", + /* 142 400 T_Saveconfigdir */ "saveconfigdir", + /* 143 401 T_Server */ "server", + /* 144 402 T_Setvar */ "setvar", + /* 145 403 T_Source */ "source", + /* 146 404 T_Stacksize */ "stacksize", + /* 147 405 T_Statistics */ "statistics", + /* 148 406 T_Stats */ "stats", + /* 149 407 T_Statsdir */ "statsdir", + /* 150 408 T_Step */ "step", + /* 151 409 T_Stepback */ "stepback", + /* 152 410 T_Stepfwd */ "stepfwd", + /* 153 411 T_Stepout */ "stepout", + /* 154 412 T_Stratum */ "stratum", + /* 155 413 T_String */ NULL, + /* 156 414 T_Sys */ "sys", + /* 157 415 T_Sysstats */ "sysstats", + /* 158 416 T_Tick */ "tick", + /* 159 417 T_Time1 */ "time1", + /* 160 418 T_Time2 */ "time2", + /* 161 419 T_Timer */ "timer", + /* 162 420 T_Timingstats */ "timingstats", + /* 163 421 T_Tinker */ "tinker", + /* 164 422 T_Tos */ "tos", + /* 165 423 T_Trap */ "trap", + /* 166 424 T_True */ "true", + /* 167 425 T_Trustedkey */ "trustedkey", + /* 168 426 T_Ttl */ "ttl", + /* 169 427 T_Type */ "type", + /* 170 428 T_U_int */ NULL, + /* 171 429 T_Unconfig */ "unconfig", + /* 172 430 T_Unpeer */ "unpeer", + /* 173 431 T_Version */ "version", + /* 174 432 T_WanderThreshold */ NULL, + /* 175 433 T_Week */ "week", + /* 176 434 T_Wildcard */ "wildcard", + /* 177 435 T_Xleave */ "xleave", + /* 178 436 T_Year */ "year", + /* 179 437 T_Flag */ NULL, + /* 180 438 T_EOC */ NULL, + /* 181 439 T_Simulate */ "simulate", + /* 182 440 T_Beep_Delay */ "beep_delay", + /* 183 441 T_Sim_Duration */ "simulation_duration", + /* 184 442 T_Server_Offset */ "server_offset", + /* 185 443 T_Duration */ "duration", + /* 186 444 T_Freq_Offset */ "freq_offset", + /* 187 445 T_Wander */ "wander", + /* 188 446 T_Jitter */ "jitter", + /* 189 447 T_Prop_Delay */ "prop_delay", + /* 190 448 T_Proc_Delay */ "proc_delay" +}; + +#define SCANNER_INIT_S 853 + +const scan_state sst[856] = { +/*SS_T( ch, f-by, match, other ), */ + 0, /* 0 */ + S_ST( '-', 3, 323, 0 ), /* 1 */ + S_ST( '.', 3, 3, 1 ), /* 2 */ + S_ST( '.', 3, 291, 0 ), /* 3 . */ + S_ST( 'a', 3, 23, 2 ), /* 4 */ + S_ST( 'b', 3, 6, 0 ), /* 5 a */ + S_ST( 'b', 3, 7, 0 ), /* 6 ab */ + S_ST( 'r', 3, 8, 0 ), /* 7 abb */ + S_ST( 'e', 3, 258, 0 ), /* 8 abbr */ + S_ST( 'g', 3, 259, 5 ), /* 9 a */ + S_ST( 'l', 3, 260, 9 ), /* 10 a */ + S_ST( 'a', 3, 261, 0 ), /* 11 all */ + S_ST( 'p', 3, 13, 11 ), /* 12 all */ + S_ST( 'e', 3, 14, 0 ), /* 13 allp */ + S_ST( 'e', 3, 15, 0 ), /* 14 allpe */ + S_ST( 'r', 3, 262, 0 ), /* 15 allpee */ + S_ST( 'u', 3, 17, 10 ), /* 16 a */ + S_ST( 't', 3, 18, 0 ), /* 17 au */ + S_ST( 'o', 3, 21, 263 ), /* 18 aut */ + S_ST( 'k', 3, 20, 0 ), /* 19 auto */ + S_ST( 'e', 3, 264, 0 ), /* 20 autok */ + S_ST( 'm', 3, 22, 19 ), /* 21 auto */ + S_ST( 'a', 3, 265, 0 ), /* 22 autom */ + S_ST( 'v', 3, 24, 16 ), /* 23 a */ + S_ST( 'e', 3, 25, 0 ), /* 24 av */ + S_ST( 'r', 3, 26, 0 ), /* 25 ave */ + S_ST( 'a', 3, 27, 0 ), /* 26 aver */ + S_ST( 'g', 3, 266, 0 ), /* 27 avera */ + S_ST( 'b', 3, 61, 4 ), /* 28 */ + S_ST( 'c', 3, 30, 0 ), /* 29 b */ + S_ST( 'l', 3, 31, 0 ), /* 30 bc */ + S_ST( 'i', 3, 32, 0 ), /* 31 bcl */ + S_ST( 'e', 3, 33, 0 ), /* 32 bcli */ + S_ST( 'n', 3, 267, 0 ), /* 33 bclie */ + S_ST( 'e', 3, 38, 29 ), /* 34 b */ + S_ST( 'a', 3, 36, 0 ), /* 35 be */ + S_ST( 'c', 3, 37, 0 ), /* 36 bea */ + S_ST( 'o', 3, 268, 0 ), /* 37 beac */ + S_ST( 'e', 3, 39, 35 ), /* 38 be */ + S_ST( 'p', 3, 40, 0 ), /* 39 bee */ + S_ST( '_', 3, 41, 0 ), /* 40 beep */ + S_ST( 'd', 3, 42, 0 ), /* 41 beep_ */ + S_ST( 'e', 3, 43, 0 ), /* 42 beep_d */ + S_ST( 'l', 3, 44, 0 ), /* 43 beep_de */ + S_ST( 'a', 3, 440, 0 ), /* 44 beep_del */ + S_ST( 'r', 3, 46, 34 ), /* 45 b */ + S_ST( 'o', 3, 47, 0 ), /* 46 br */ + S_ST( 'a', 3, 48, 0 ), /* 47 bro */ + S_ST( 'd', 3, 49, 0 ), /* 48 broa */ + S_ST( 'c', 3, 50, 0 ), /* 49 broad */ + S_ST( 'a', 3, 51, 0 ), /* 50 broadc */ + S_ST( 's', 3, 269, 0 ), /* 51 broadca */ + S_ST( 'c', 3, 53, 0 ), /* 52 broadcast */ + S_ST( 'l', 3, 54, 0 ), /* 53 broadcastc */ + S_ST( 'i', 3, 55, 0 ), /* 54 broadcastcl */ + S_ST( 'e', 3, 56, 0 ), /* 55 broadcastcli */ + S_ST( 'n', 3, 270, 0 ), /* 56 broadcastclie */ + S_ST( 'd', 3, 58, 52 ), /* 57 broadcast */ + S_ST( 'e', 3, 59, 0 ), /* 58 broadcastd */ + S_ST( 'l', 3, 60, 0 ), /* 59 broadcastde */ + S_ST( 'a', 3, 271, 0 ), /* 60 broadcastdel */ + S_ST( 'u', 3, 62, 45 ), /* 61 b */ + S_ST( 'r', 3, 63, 0 ), /* 62 bu */ + S_ST( 's', 3, 272, 0 ), /* 63 bur */ + S_ST( 'c', 3, 104, 28 ), /* 64 */ + S_ST( 'a', 3, 66, 0 ), /* 65 c */ + S_ST( 'l', 3, 67, 0 ), /* 66 ca */ + S_ST( 'i', 3, 68, 0 ), /* 67 cal */ + S_ST( 'b', 3, 69, 0 ), /* 68 cali */ + S_ST( 'r', 3, 70, 0 ), /* 69 calib */ + S_ST( 'a', 3, 71, 0 ), /* 70 calibr */ + S_ST( 't', 3, 273, 0 ), /* 71 calibra */ + S_ST( 'e', 3, 73, 65 ), /* 72 c */ + S_ST( 'i', 3, 74, 0 ), /* 73 ce */ + S_ST( 'l', 3, 75, 0 ), /* 74 cei */ + S_ST( 'i', 3, 76, 0 ), /* 75 ceil */ + S_ST( 'n', 3, 274, 0 ), /* 76 ceili */ + S_ST( 'l', 3, 78, 72 ), /* 77 c */ + S_ST( 'o', 3, 79, 0 ), /* 78 cl */ + S_ST( 'c', 3, 80, 0 ), /* 79 clo */ + S_ST( 'k', 3, 81, 0 ), /* 80 cloc */ + S_ST( 's', 3, 82, 0 ), /* 81 clock */ + S_ST( 't', 3, 83, 0 ), /* 82 clocks */ + S_ST( 'a', 3, 84, 0 ), /* 83 clockst */ + S_ST( 't', 3, 275, 0 ), /* 84 clocksta */ + S_ST( 'o', 3, 89, 77 ), /* 85 c */ + S_ST( 'h', 3, 87, 0 ), /* 86 co */ + S_ST( 'o', 3, 88, 0 ), /* 87 coh */ + S_ST( 'r', 3, 276, 0 ), /* 88 coho */ + S_ST( 'n', 3, 90, 86 ), /* 89 co */ + S_ST( 't', 3, 91, 0 ), /* 90 con */ + S_ST( 'r', 3, 92, 0 ), /* 91 cont */ + S_ST( 'o', 3, 93, 0 ), /* 92 contr */ + S_ST( 'l', 3, 94, 0 ), /* 93 contro */ + S_ST( 'k', 3, 95, 0 ), /* 94 control */ + S_ST( 'e', 3, 277, 0 ), /* 95 controlk */ + S_ST( 'r', 3, 97, 85 ), /* 96 c */ + S_ST( 'y', 3, 98, 0 ), /* 97 cr */ + S_ST( 'p', 3, 99, 0 ), /* 98 cry */ + S_ST( 't', 3, 278, 0 ), /* 99 cryp */ + S_ST( 's', 3, 101, 0 ), /* 100 crypto */ + S_ST( 't', 3, 102, 0 ), /* 101 cryptos */ + S_ST( 'a', 3, 103, 0 ), /* 102 cryptost */ + S_ST( 't', 3, 279, 0 ), /* 103 cryptosta */ + S_ST( 't', 3, 280, 96 ), /* 104 c */ + S_ST( 'd', 3, 139, 64 ), /* 105 */ + S_ST( 'a', 3, 281, 0 ), /* 106 d */ + S_ST( 'e', 3, 108, 106 ), /* 107 d */ + S_ST( 'f', 3, 109, 0 ), /* 108 de */ + S_ST( 'a', 3, 110, 0 ), /* 109 def */ + S_ST( 'u', 3, 111, 0 ), /* 110 defa */ + S_ST( 'l', 3, 282, 0 ), /* 111 defau */ + S_ST( 'i', 3, 116, 107 ), /* 112 d */ + S_ST( 'g', 3, 114, 0 ), /* 113 di */ + S_ST( 'e', 3, 115, 0 ), /* 114 dig */ + S_ST( 's', 3, 283, 0 ), /* 115 dige */ + S_ST( 's', 3, 123, 113 ), /* 116 di */ + S_ST( 'a', 3, 118, 0 ), /* 117 dis */ + S_ST( 'b', 3, 119, 0 ), /* 118 disa */ + S_ST( 'l', 3, 284, 0 ), /* 119 disab */ + S_ST( 'c', 3, 121, 117 ), /* 120 dis */ + S_ST( 'a', 3, 122, 0 ), /* 121 disc */ + S_ST( 'r', 3, 285, 0 ), /* 122 disca */ + S_ST( 'p', 3, 124, 120 ), /* 123 dis */ + S_ST( 'e', 3, 125, 0 ), /* 124 disp */ + S_ST( 'r', 3, 126, 0 ), /* 125 dispe */ + S_ST( 's', 3, 127, 0 ), /* 126 disper */ + S_ST( 'i', 3, 128, 0 ), /* 127 dispers */ + S_ST( 'o', 3, 286, 0 ), /* 128 dispersi */ + S_ST( 'r', 3, 136, 112 ), /* 129 d */ + S_ST( 'i', 3, 131, 0 ), /* 130 dr */ + S_ST( 'f', 3, 132, 0 ), /* 131 dri */ + S_ST( 't', 3, 133, 0 ), /* 132 drif */ + S_ST( 'f', 3, 134, 0 ), /* 133 drift */ + S_ST( 'i', 3, 135, 0 ), /* 134 driftf */ + S_ST( 'l', 3, 288, 0 ), /* 135 driftfi */ + S_ST( 'o', 3, 289, 130 ), /* 136 dr */ + S_ST( 's', 3, 138, 129 ), /* 137 d */ + S_ST( 'c', 3, 290, 0 ), /* 138 ds */ + S_ST( 'u', 3, 140, 137 ), /* 139 d */ + S_ST( 'r', 3, 141, 0 ), /* 140 du */ + S_ST( 'a', 3, 142, 0 ), /* 141 dur */ + S_ST( 't', 3, 143, 0 ), /* 142 dura */ + S_ST( 'i', 3, 144, 0 ), /* 143 durat */ + S_ST( 'o', 3, 443, 0 ), /* 144 durati */ + S_ST( 'e', 3, 146, 105 ), /* 145 */ + S_ST( 'n', 3, 293, 0 ), /* 146 e */ + S_ST( 'a', 3, 148, 0 ), /* 147 en */ + S_ST( 'b', 3, 149, 0 ), /* 148 ena */ + S_ST( 'l', 3, 292, 0 ), /* 149 enab */ + S_ST( 'f', 3, 171, 145 ), /* 150 */ + S_ST( 'i', 3, 152, 0 ), /* 151 f */ + S_ST( 'l', 3, 295, 0 ), /* 152 fi */ + S_ST( 'g', 3, 154, 0 ), /* 153 file */ + S_ST( 'e', 3, 296, 0 ), /* 154 fileg */ + S_ST( 'n', 3, 156, 153 ), /* 155 file */ + S_ST( 'u', 3, 297, 0 ), /* 156 filen */ + S_ST( 'l', 3, 161, 151 ), /* 157 f */ + S_ST( 'a', 3, 160, 0 ), /* 158 fl */ + S_ST( 'g', 3, 301, 0 ), /* 159 fla */ + S_ST( 'k', 3, 302, 159 ), /* 160 fla */ + S_ST( 'o', 3, 162, 158 ), /* 161 fl */ + S_ST( 'o', 3, 303, 0 ), /* 162 flo */ + S_ST( 'r', 3, 164, 157 ), /* 163 f */ + S_ST( 'e', 3, 304, 0 ), /* 164 fr */ + S_ST( '_', 3, 166, 0 ), /* 165 freq */ + S_ST( 'o', 3, 167, 0 ), /* 166 freq_ */ + S_ST( 'f', 3, 168, 0 ), /* 167 freq_o */ + S_ST( 'f', 3, 169, 0 ), /* 168 freq_of */ + S_ST( 's', 3, 170, 0 ), /* 169 freq_off */ + S_ST( 'e', 3, 444, 0 ), /* 170 freq_offs */ + S_ST( 'u', 3, 172, 163 ), /* 171 f */ + S_ST( 'd', 3, 173, 0 ), /* 172 fu */ + S_ST( 'g', 3, 305, 0 ), /* 173 fud */ + S_ST( 'h', 3, 177, 150 ), /* 174 */ + S_ST( 'o', 3, 176, 0 ), /* 175 h */ + S_ST( 's', 3, 306, 0 ), /* 176 ho */ + S_ST( 'u', 3, 178, 175 ), /* 177 h */ + S_ST( 'f', 3, 179, 0 ), /* 178 hu */ + S_ST( 'f', 3, 180, 0 ), /* 179 huf */ + S_ST( 'p', 3, 181, 0 ), /* 180 huff */ + S_ST( 'u', 3, 182, 0 ), /* 181 huffp */ + S_ST( 'f', 3, 307, 0 ), /* 182 huffpu */ + S_ST( 'i', 3, 224, 174 ), /* 183 */ + S_ST( 'b', 3, 185, 0 ), /* 184 i */ + S_ST( 'u', 3, 186, 0 ), /* 185 ib */ + S_ST( 'r', 3, 187, 0 ), /* 186 ibu */ + S_ST( 's', 3, 308, 0 ), /* 187 ibur */ + S_ST( 'd', 3, 189, 184 ), /* 188 i */ + S_ST( 'e', 3, 190, 0 ), /* 189 id */ + S_ST( 'n', 3, 309, 0 ), /* 190 ide */ + S_ST( 'g', 3, 192, 188 ), /* 191 i */ + S_ST( 'n', 3, 193, 0 ), /* 192 ig */ + S_ST( 'o', 3, 194, 0 ), /* 193 ign */ + S_ST( 'r', 3, 310, 0 ), /* 194 igno */ + S_ST( 'n', 3, 218, 191 ), /* 195 i */ + S_ST( 'c', 3, 208, 0 ), /* 196 in */ + S_ST( 'a', 3, 198, 0 ), /* 197 inc */ + S_ST( 'l', 3, 199, 0 ), /* 198 inca */ + S_ST( 'l', 3, 200, 0 ), /* 199 incal */ + S_ST( 'o', 3, 311, 0 ), /* 200 incall */ + S_ST( 'l', 3, 202, 197 ), /* 201 inc */ + S_ST( 'u', 3, 203, 0 ), /* 202 incl */ + S_ST( 'd', 3, 204, 0 ), /* 203 inclu */ + S_ST( 'e', 3, 205, 0 ), /* 204 includ */ + S_ST( 'f', 3, 206, 0 ), /* 205 include */ + S_ST( 'i', 3, 207, 0 ), /* 206 includef */ + S_ST( 'l', 3, 315, 0 ), /* 207 includefi */ + S_ST( 'm', 3, 209, 201 ), /* 208 inc */ + S_ST( 'e', 3, 312, 0 ), /* 209 incm */ + S_ST( 'i', 3, 211, 196 ), /* 210 in */ + S_ST( 't', 3, 216, 0 ), /* 211 ini */ + S_ST( 'a', 3, 213, 0 ), /* 212 init */ + S_ST( 'l', 3, 214, 0 ), /* 213 inita */ + S_ST( 'l', 3, 215, 0 ), /* 214 inital */ + S_ST( 'o', 3, 313, 0 ), /* 215 initall */ + S_ST( 'm', 3, 217, 212 ), /* 216 init */ + S_ST( 'e', 3, 314, 0 ), /* 217 initm */ + S_ST( 't', 3, 219, 210 ), /* 218 in */ + S_ST( 'e', 3, 220, 0 ), /* 219 int */ + S_ST( 'r', 3, 221, 0 ), /* 220 inte */ + S_ST( 'f', 3, 222, 0 ), /* 221 inter */ + S_ST( 'a', 3, 223, 0 ), /* 222 interf */ + S_ST( 'c', 3, 317, 0 ), /* 223 interfa */ + S_ST( 'p', 3, 225, 319 ), /* 224 i */ + S_ST( 'v', 3, 322, 0 ), /* 225 ip */ + S_ST( 'j', 3, 227, 183 ), /* 226 */ + S_ST( 'i', 3, 228, 0 ), /* 227 j */ + S_ST( 't', 3, 229, 0 ), /* 228 ji */ + S_ST( 't', 3, 230, 0 ), /* 229 jit */ + S_ST( 'e', 3, 446, 0 ), /* 230 jitt */ + S_ST( 'k', 3, 238, 226 ), /* 231 */ + S_ST( 'e', 3, 325, 0 ), /* 232 k */ + S_ST( 'r', 3, 234, 0 ), /* 233 ke */ + S_ST( 'n', 3, 235, 0 ), /* 234 ker */ + S_ST( 'e', 3, 324, 0 ), /* 235 kern */ + S_ST( 'd', 3, 237, 0 ), /* 236 keys */ + S_ST( 'i', 3, 327, 0 ), /* 237 keysd */ + S_ST( 'o', 3, 328, 232 ), /* 238 k */ + S_ST( 'l', 3, 449, 231 ), /* 239 */ + S_ST( 'e', 3, 241, 0 ), /* 240 l */ + S_ST( 'a', 3, 242, 0 ), /* 241 le */ + S_ST( 'p', 3, 246, 0 ), /* 242 lea */ + S_ST( 'f', 3, 244, 0 ), /* 243 leap */ + S_ST( 'i', 3, 245, 0 ), /* 244 leapf */ + S_ST( 'l', 3, 330, 0 ), /* 245 leapfi */ + S_ST( 's', 3, 247, 243 ), /* 246 leap */ + S_ST( 'm', 3, 248, 0 ), /* 247 leaps */ + S_ST( 'e', 3, 249, 0 ), /* 248 leapsm */ + S_ST( 'a', 3, 250, 0 ), /* 249 leapsme */ + S_ST( 'r', 3, 251, 0 ), /* 250 leapsmea */ + S_ST( 'i', 3, 252, 0 ), /* 251 leapsmear */ + S_ST( 'n', 3, 253, 0 ), /* 252 leapsmeari */ + S_ST( 't', 3, 254, 0 ), /* 253 leapsmearin */ + S_ST( 'e', 3, 255, 0 ), /* 254 leapsmearint */ + S_ST( 'r', 3, 256, 0 ), /* 255 leapsmearinte */ + S_ST( 'v', 3, 257, 0 ), /* 256 leapsmearinter */ + S_ST( 'a', 3, 331, 0 ), /* 257 leapsmearinterv */ + S_ST( 'v', 1, 0, 0 ), /* 258 T_Abbrev */ + S_ST( 'e', 0, 0, 0 ), /* 259 T_Age */ + S_ST( 'l', 0, 12, 0 ), /* 260 T_All */ + S_ST( 'n', 0, 0, 0 ), /* 261 T_Allan */ + S_ST( 's', 0, 0, 0 ), /* 262 T_Allpeers */ + S_ST( 'h', 0, 0, 0 ), /* 263 T_Auth */ + S_ST( 'y', 0, 0, 0 ), /* 264 T_Autokey */ + S_ST( 'x', 0, 0, 0 ), /* 265 T_Automax */ + S_ST( 'e', 0, 0, 0 ), /* 266 T_Average */ + S_ST( 't', 0, 0, 0 ), /* 267 T_Bclient */ + S_ST( 'n', 0, 0, 0 ), /* 268 T_Beacon */ + S_ST( 't', 1, 57, 0 ), /* 269 T_Broadcast */ + S_ST( 't', 0, 0, 0 ), /* 270 T_Broadcastclient */ + S_ST( 'y', 0, 0, 0 ), /* 271 T_Broadcastdelay */ + S_ST( 't', 0, 0, 0 ), /* 272 T_Burst */ + S_ST( 'e', 0, 0, 0 ), /* 273 T_Calibrate */ + S_ST( 'g', 0, 0, 0 ), /* 274 T_Ceiling */ + S_ST( 's', 0, 0, 0 ), /* 275 T_Clockstats */ + S_ST( 't', 0, 0, 0 ), /* 276 T_Cohort */ + S_ST( 'y', 0, 0, 0 ), /* 277 T_ControlKey */ + S_ST( 'o', 0, 100, 0 ), /* 278 T_Crypto */ + S_ST( 's', 0, 0, 0 ), /* 279 T_Cryptostats */ + S_ST( 'l', 0, 0, 0 ), /* 280 T_Ctl */ + S_ST( 'y', 0, 0, 0 ), /* 281 T_Day */ + S_ST( 't', 0, 0, 0 ), /* 282 T_Default */ + S_ST( 't', 1, 0, 0 ), /* 283 T_Digest */ + S_ST( 'e', 0, 0, 0 ), /* 284 T_Disable */ + S_ST( 'd', 0, 0, 0 ), /* 285 T_Discard */ + S_ST( 'n', 0, 0, 0 ), /* 286 T_Dispersion */ + S_ST( 'i', 3, 432, 240 ), /* 287 l */ + S_ST( 'e', 1, 0, 0 ), /* 288 T_Driftfile */ + S_ST( 'p', 0, 0, 0 ), /* 289 T_Drop */ + S_ST( 'p', 0, 0, 0 ), /* 290 T_Dscp */ + S_ST( '.', 0, 0, 0 ), /* 291 T_Ellipsis */ + S_ST( 'e', 0, 0, 0 ), /* 292 T_Enable */ + S_ST( 'd', 0, 0, 147 ), /* 293 T_End */ + S_ST( 'm', 3, 316, 0 ), /* 294 li */ + S_ST( 'e', 1, 155, 0 ), /* 295 T_File */ + S_ST( 'n', 0, 0, 0 ), /* 296 T_Filegen */ + S_ST( 'm', 0, 0, 0 ), /* 297 T_Filenum */ + S_ST( '1', 0, 0, 0 ), /* 298 T_Flag1 */ + S_ST( '2', 0, 0, 298 ), /* 299 T_Flag2 */ + S_ST( '3', 0, 0, 299 ), /* 300 T_Flag3 */ + S_ST( '4', 0, 0, 300 ), /* 301 T_Flag4 */ + S_ST( 'e', 0, 0, 0 ), /* 302 T_Flake */ + S_ST( 'r', 0, 0, 0 ), /* 303 T_Floor */ + S_ST( 'q', 0, 165, 0 ), /* 304 T_Freq */ + S_ST( 'e', 1, 0, 0 ), /* 305 T_Fudge */ + S_ST( 't', 1, 0, 0 ), /* 306 T_Host */ + S_ST( 'f', 0, 0, 0 ), /* 307 T_Huffpuff */ + S_ST( 't', 0, 0, 0 ), /* 308 T_Iburst */ + S_ST( 't', 1, 0, 0 ), /* 309 T_Ident */ + S_ST( 'e', 0, 0, 0 ), /* 310 T_Ignore */ + S_ST( 'c', 0, 0, 0 ), /* 311 T_Incalloc */ + S_ST( 'm', 0, 0, 0 ), /* 312 T_Incmem */ + S_ST( 'c', 0, 0, 0 ), /* 313 T_Initalloc */ + S_ST( 'm', 0, 0, 0 ), /* 314 T_Initmem */ + S_ST( 'e', 1, 0, 0 ), /* 315 T_Includefile */ + S_ST( 'i', 3, 318, 0 ), /* 316 lim */ + S_ST( 'e', 0, 0, 0 ), /* 317 T_Interface */ + S_ST( 't', 3, 413, 0 ), /* 318 limi */ + S_ST( 'o', 0, 0, 195 ), /* 319 T_Io */ + S_ST( '4', 0, 0, 0 ), /* 320 T_Ipv4 */ + S_ST( '4', 0, 0, 0 ), /* 321 T_Ipv4_flag */ + S_ST( '6', 0, 0, 320 ), /* 322 T_Ipv6 */ + S_ST( '6', 0, 0, 321 ), /* 323 T_Ipv6_flag */ + S_ST( 'l', 0, 0, 0 ), /* 324 T_Kernel */ + S_ST( 'y', 0, 326, 233 ), /* 325 T_Key */ + S_ST( 's', 1, 236, 0 ), /* 326 T_Keys */ + S_ST( 'r', 1, 0, 0 ), /* 327 T_Keysdir */ + S_ST( 'd', 0, 0, 0 ), /* 328 T_Kod */ + S_ST( 'p', 0, 0, 0 ), /* 329 T_Mssntp */ + S_ST( 'e', 1, 0, 0 ), /* 330 T_Leapfile */ + S_ST( 'l', 0, 0, 0 ), /* 331 T_Leapsmearinterval */ + S_ST( 'd', 0, 0, 0 ), /* 332 T_Limited */ + S_ST( 'k', 0, 0, 0 ), /* 333 T_Link */ + S_ST( 'n', 0, 0, 0 ), /* 334 T_Listen */ + S_ST( 'g', 2, 0, 0 ), /* 335 T_Logconfig */ + S_ST( 'e', 1, 0, 0 ), /* 336 T_Logfile */ + S_ST( 's', 0, 0, 0 ), /* 337 T_Loopstats */ + S_ST( 'p', 0, 0, 0 ), /* 338 T_Lowpriotrap */ + S_ST( 't', 1, 0, 0 ), /* 339 T_Manycastclient */ + S_ST( 'r', 2, 0, 0 ), /* 340 T_Manycastserver */ + S_ST( 'k', 0, 0, 0 ), /* 341 T_Mask */ + S_ST( 'e', 0, 0, 0 ), /* 342 T_Maxage */ + S_ST( 'k', 0, 0, 0 ), /* 343 T_Maxclock */ + S_ST( 'h', 0, 0, 0 ), /* 344 T_Maxdepth */ + S_ST( 't', 0, 0, 0 ), /* 345 T_Maxdist */ + S_ST( 'm', 0, 0, 0 ), /* 346 T_Maxmem */ + S_ST( 'l', 0, 0, 0 ), /* 347 T_Maxpoll */ + S_ST( 's', 0, 0, 0 ), /* 348 T_Mdnstries */ + S_ST( 'm', 0, 518, 0 ), /* 349 T_Mem */ + S_ST( 'k', 0, 0, 0 ), /* 350 T_Memlock */ + S_ST( 'k', 0, 0, 0 ), /* 351 T_Minclock */ + S_ST( 'h', 0, 0, 0 ), /* 352 T_Mindepth */ + S_ST( 't', 0, 0, 0 ), /* 353 T_Mindist */ + S_ST( 'm', 0, 0, 0 ), /* 354 T_Minimum */ + S_ST( 'l', 0, 0, 0 ), /* 355 T_Minpoll */ + S_ST( 'e', 0, 0, 0 ), /* 356 T_Minsane */ + S_ST( 'e', 0, 358, 0 ), /* 357 T_Mode */ + S_ST( '7', 0, 0, 0 ), /* 358 T_Mode7 */ + S_ST( 'r', 0, 0, 0 ), /* 359 T_Monitor */ + S_ST( 'h', 0, 0, 0 ), /* 360 T_Month */ + S_ST( 'u', 0, 0, 0 ), /* 361 T_Mru */ + S_ST( 't', 2, 0, 0 ), /* 362 T_Multicastclient */ + S_ST( 'c', 0, 0, 0 ), /* 363 T_Nic */ + S_ST( 'k', 0, 0, 0 ), /* 364 T_Nolink */ + S_ST( 'y', 0, 0, 0 ), /* 365 T_Nomodify */ + S_ST( 't', 0, 0, 0 ), /* 366 T_Nomrulist */ + S_ST( 'e', 0, 0, 0 ), /* 367 T_None */ + S_ST( 'e', 0, 0, 0 ), /* 368 T_Nonvolatile */ + S_ST( 'r', 0, 0, 0 ), /* 369 T_Nopeer */ + S_ST( 'y', 0, 0, 0 ), /* 370 T_Noquery */ + S_ST( 't', 0, 0, 0 ), /* 371 T_Noselect */ + S_ST( 'e', 0, 0, 0 ), /* 372 T_Noserve */ + S_ST( 'p', 0, 0, 0 ), /* 373 T_Notrap */ + S_ST( 't', 0, 0, 0 ), /* 374 T_Notrust */ + S_ST( 'p', 0, 614, 0 ), /* 375 T_Ntp */ + S_ST( 't', 0, 0, 0 ), /* 376 T_Ntpport */ + S_ST( 't', 1, 0, 0 ), /* 377 T_NtpSignDsocket */ + S_ST( 'n', 0, 629, 0 ), /* 378 T_Orphan */ + S_ST( 't', 0, 0, 0 ), /* 379 T_Orphanwait */ + S_ST( 'c', 0, 0, 0 ), /* 380 T_Panic */ + S_ST( 'r', 1, 638, 0 ), /* 381 T_Peer */ + S_ST( 's', 0, 0, 0 ), /* 382 T_Peerstats */ + S_ST( 'e', 2, 0, 0 ), /* 383 T_Phone */ + S_ST( 'd', 0, 646, 0 ), /* 384 T_Pid */ + S_ST( 'e', 1, 0, 0 ), /* 385 T_Pidfile */ + S_ST( 'l', 1, 0, 0 ), /* 386 T_Pool */ + S_ST( 't', 0, 0, 0 ), /* 387 T_Port */ + S_ST( 't', 0, 0, 0 ), /* 388 T_Preempt */ + S_ST( 'r', 0, 0, 0 ), /* 389 T_Prefer */ + S_ST( 's', 0, 0, 0 ), /* 390 T_Protostats */ + S_ST( 'w', 1, 0, 652 ), /* 391 T_Pw */ + S_ST( 'e', 1, 0, 0 ), /* 392 T_Randfile */ + S_ST( 's', 0, 0, 0 ), /* 393 T_Rawstats */ + S_ST( 'd', 1, 0, 0 ), /* 394 T_Refid */ + S_ST( 'y', 0, 0, 0 ), /* 395 T_Requestkey */ + S_ST( 't', 0, 0, 0 ), /* 396 T_Reset */ + S_ST( 't', 0, 0, 0 ), /* 397 T_Restrict */ + S_ST( 'e', 0, 0, 0 ), /* 398 T_Revoke */ + S_ST( 't', 0, 0, 0 ), /* 399 T_Rlimit */ + S_ST( 'r', 1, 0, 0 ), /* 400 T_Saveconfigdir */ + S_ST( 'r', 1, 729, 0 ), /* 401 T_Server */ + S_ST( 'r', 1, 0, 0 ), /* 402 T_Setvar */ + S_ST( 'e', 0, 0, 0 ), /* 403 T_Source */ + S_ST( 'e', 0, 0, 0 ), /* 404 T_Stacksize */ + S_ST( 's', 0, 0, 0 ), /* 405 T_Statistics */ + S_ST( 's', 0, 772, 767 ), /* 406 T_Stats */ + S_ST( 'r', 1, 0, 0 ), /* 407 T_Statsdir */ + S_ST( 'p', 0, 780, 0 ), /* 408 T_Step */ + S_ST( 'k', 0, 0, 0 ), /* 409 T_Stepback */ + S_ST( 'd', 0, 0, 0 ), /* 410 T_Stepfwd */ + S_ST( 't', 0, 0, 0 ), /* 411 T_Stepout */ + S_ST( 'm', 0, 0, 0 ), /* 412 T_Stratum */ + S_ST( 'e', 3, 332, 0 ), /* 413 limit */ + S_ST( 's', 0, 787, 0 ), /* 414 T_Sys */ + S_ST( 's', 0, 0, 0 ), /* 415 T_Sysstats */ + S_ST( 'k', 0, 0, 0 ), /* 416 T_Tick */ + S_ST( '1', 0, 0, 0 ), /* 417 T_Time1 */ + S_ST( '2', 0, 0, 417 ), /* 418 T_Time2 */ + S_ST( 'r', 0, 0, 418 ), /* 419 T_Timer */ + S_ST( 's', 0, 0, 0 ), /* 420 T_Timingstats */ + S_ST( 'r', 0, 0, 0 ), /* 421 T_Tinker */ + S_ST( 's', 0, 0, 0 ), /* 422 T_Tos */ + S_ST( 'p', 1, 0, 0 ), /* 423 T_Trap */ + S_ST( 'e', 0, 0, 0 ), /* 424 T_True */ + S_ST( 'y', 0, 0, 0 ), /* 425 T_Trustedkey */ + S_ST( 'l', 0, 0, 0 ), /* 426 T_Ttl */ + S_ST( 'e', 0, 0, 0 ), /* 427 T_Type */ + S_ST( 'n', 3, 333, 294 ), /* 428 li */ + S_ST( 'g', 1, 0, 0 ), /* 429 T_Unconfig */ + S_ST( 'r', 1, 0, 0 ), /* 430 T_Unpeer */ + S_ST( 'n', 0, 0, 0 ), /* 431 T_Version */ + S_ST( 's', 3, 437, 428 ), /* 432 li */ + S_ST( 'k', 0, 0, 0 ), /* 433 T_Week */ + S_ST( 'd', 0, 0, 0 ), /* 434 T_Wildcard */ + S_ST( 'e', 0, 0, 0 ), /* 435 T_Xleave */ + S_ST( 'r', 0, 0, 0 ), /* 436 T_Year */ + S_ST( 't', 3, 438, 0 ), /* 437 lis */ + S_ST( 'e', 3, 334, 0 ), /* 438 list */ + S_ST( 'e', 0, 0, 0 ), /* 439 T_Simulate */ + S_ST( 'y', 0, 0, 0 ), /* 440 T_Beep_Delay */ + S_ST( 'n', 0, 0, 0 ), /* 441 T_Sim_Duration */ + S_ST( 't', 0, 0, 0 ), /* 442 T_Server_Offset */ + S_ST( 'n', 0, 0, 0 ), /* 443 T_Duration */ + S_ST( 't', 0, 0, 0 ), /* 444 T_Freq_Offset */ + S_ST( 'r', 0, 0, 0 ), /* 445 T_Wander */ + S_ST( 'r', 0, 0, 0 ), /* 446 T_Jitter */ + S_ST( 'y', 0, 0, 0 ), /* 447 T_Prop_Delay */ + S_ST( 'y', 0, 0, 0 ), /* 448 T_Proc_Delay */ + S_ST( 'o', 3, 465, 287 ), /* 449 l */ + S_ST( 'g', 3, 456, 0 ), /* 450 lo */ + S_ST( 'c', 3, 452, 0 ), /* 451 log */ + S_ST( 'o', 3, 453, 0 ), /* 452 logc */ + S_ST( 'n', 3, 454, 0 ), /* 453 logco */ + S_ST( 'f', 3, 455, 0 ), /* 454 logcon */ + S_ST( 'i', 3, 335, 0 ), /* 455 logconf */ + S_ST( 'f', 3, 457, 451 ), /* 456 log */ + S_ST( 'i', 3, 458, 0 ), /* 457 logf */ + S_ST( 'l', 3, 336, 0 ), /* 458 logfi */ + S_ST( 'o', 3, 460, 450 ), /* 459 lo */ + S_ST( 'p', 3, 461, 0 ), /* 460 loo */ + S_ST( 's', 3, 462, 0 ), /* 461 loop */ + S_ST( 't', 3, 463, 0 ), /* 462 loops */ + S_ST( 'a', 3, 464, 0 ), /* 463 loopst */ + S_ST( 't', 3, 337, 0 ), /* 464 loopsta */ + S_ST( 'w', 3, 466, 459 ), /* 465 lo */ + S_ST( 'p', 3, 467, 0 ), /* 466 low */ + S_ST( 'r', 3, 468, 0 ), /* 467 lowp */ + S_ST( 'i', 3, 469, 0 ), /* 468 lowpr */ + S_ST( 'o', 3, 470, 0 ), /* 469 lowpri */ + S_ST( 't', 3, 471, 0 ), /* 470 lowprio */ + S_ST( 'r', 3, 472, 0 ), /* 471 lowpriot */ + S_ST( 'a', 3, 338, 0 ), /* 472 lowpriotr */ + S_ST( 'm', 3, 554, 239 ), /* 473 */ + S_ST( 'a', 3, 492, 0 ), /* 474 m */ + S_ST( 'n', 3, 476, 0 ), /* 475 ma */ + S_ST( 'y', 3, 477, 0 ), /* 476 man */ + S_ST( 'c', 3, 478, 0 ), /* 477 many */ + S_ST( 'a', 3, 479, 0 ), /* 478 manyc */ + S_ST( 's', 3, 480, 0 ), /* 479 manyca */ + S_ST( 't', 3, 486, 0 ), /* 480 manycas */ + S_ST( 'c', 3, 482, 0 ), /* 481 manycast */ + S_ST( 'l', 3, 483, 0 ), /* 482 manycastc */ + S_ST( 'i', 3, 484, 0 ), /* 483 manycastcl */ + S_ST( 'e', 3, 485, 0 ), /* 484 manycastcli */ + S_ST( 'n', 3, 339, 0 ), /* 485 manycastclie */ + S_ST( 's', 3, 487, 481 ), /* 486 manycast */ + S_ST( 'e', 3, 488, 0 ), /* 487 manycasts */ + S_ST( 'r', 3, 489, 0 ), /* 488 manycastse */ + S_ST( 'v', 3, 490, 0 ), /* 489 manycastser */ + S_ST( 'e', 3, 340, 0 ), /* 490 manycastserv */ + S_ST( 's', 3, 341, 475 ), /* 491 ma */ + S_ST( 'x', 3, 507, 491 ), /* 492 ma */ + S_ST( 'a', 3, 494, 0 ), /* 493 max */ + S_ST( 'g', 3, 342, 0 ), /* 494 maxa */ + S_ST( 'c', 3, 496, 493 ), /* 495 max */ + S_ST( 'l', 3, 497, 0 ), /* 496 maxc */ + S_ST( 'o', 3, 498, 0 ), /* 497 maxcl */ + S_ST( 'c', 3, 343, 0 ), /* 498 maxclo */ + S_ST( 'd', 3, 503, 495 ), /* 499 max */ + S_ST( 'e', 3, 501, 0 ), /* 500 maxd */ + S_ST( 'p', 3, 502, 0 ), /* 501 maxde */ + S_ST( 't', 3, 344, 0 ), /* 502 maxdep */ + S_ST( 'i', 3, 504, 500 ), /* 503 maxd */ + S_ST( 's', 3, 345, 0 ), /* 504 maxdi */ + S_ST( 'm', 3, 506, 499 ), /* 505 max */ + S_ST( 'e', 3, 346, 0 ), /* 506 maxm */ + S_ST( 'p', 3, 508, 505 ), /* 507 max */ + S_ST( 'o', 3, 509, 0 ), /* 508 maxp */ + S_ST( 'l', 3, 347, 0 ), /* 509 maxpo */ + S_ST( 'd', 3, 511, 474 ), /* 510 m */ + S_ST( 'n', 3, 512, 0 ), /* 511 md */ + S_ST( 's', 3, 513, 0 ), /* 512 mdn */ + S_ST( 't', 3, 514, 0 ), /* 513 mdns */ + S_ST( 'r', 3, 515, 0 ), /* 514 mdnst */ + S_ST( 'i', 3, 516, 0 ), /* 515 mdnstr */ + S_ST( 'e', 3, 348, 0 ), /* 516 mdnstri */ + S_ST( 'e', 3, 349, 510 ), /* 517 m */ + S_ST( 'l', 3, 519, 0 ), /* 518 mem */ + S_ST( 'o', 3, 520, 0 ), /* 519 meml */ + S_ST( 'c', 3, 350, 0 ), /* 520 memlo */ + S_ST( 'i', 3, 522, 517 ), /* 521 m */ + S_ST( 'n', 3, 539, 0 ), /* 522 mi */ + S_ST( 'c', 3, 524, 0 ), /* 523 min */ + S_ST( 'l', 3, 525, 0 ), /* 524 minc */ + S_ST( 'o', 3, 526, 0 ), /* 525 mincl */ + S_ST( 'c', 3, 351, 0 ), /* 526 minclo */ + S_ST( 'd', 3, 531, 523 ), /* 527 min */ + S_ST( 'e', 3, 529, 0 ), /* 528 mind */ + S_ST( 'p', 3, 530, 0 ), /* 529 minde */ + S_ST( 't', 3, 352, 0 ), /* 530 mindep */ + S_ST( 'i', 3, 532, 528 ), /* 531 mind */ + S_ST( 's', 3, 353, 0 ), /* 532 mindi */ + S_ST( 'i', 3, 534, 527 ), /* 533 min */ + S_ST( 'm', 3, 535, 0 ), /* 534 mini */ + S_ST( 'u', 3, 354, 0 ), /* 535 minim */ + S_ST( 'p', 3, 537, 533 ), /* 536 min */ + S_ST( 'o', 3, 538, 0 ), /* 537 minp */ + S_ST( 'l', 3, 355, 0 ), /* 538 minpo */ + S_ST( 's', 3, 540, 536 ), /* 539 min */ + S_ST( 'a', 3, 541, 0 ), /* 540 mins */ + S_ST( 'n', 3, 356, 0 ), /* 541 minsa */ + S_ST( 'o', 3, 544, 521 ), /* 542 m */ + S_ST( 'd', 3, 357, 0 ), /* 543 mo */ + S_ST( 'n', 3, 548, 543 ), /* 544 mo */ + S_ST( 'i', 3, 546, 0 ), /* 545 mon */ + S_ST( 't', 3, 547, 0 ), /* 546 moni */ + S_ST( 'o', 3, 359, 0 ), /* 547 monit */ + S_ST( 't', 3, 360, 545 ), /* 548 mon */ + S_ST( 'r', 3, 361, 542 ), /* 549 m */ + S_ST( 's', 3, 551, 549 ), /* 550 m */ + S_ST( 's', 3, 552, 0 ), /* 551 ms */ + S_ST( 'n', 3, 553, 0 ), /* 552 mss */ + S_ST( 't', 3, 329, 0 ), /* 553 mssn */ + S_ST( 'u', 3, 555, 550 ), /* 554 m */ + S_ST( 'l', 3, 556, 0 ), /* 555 mu */ + S_ST( 't', 3, 557, 0 ), /* 556 mul */ + S_ST( 'i', 3, 558, 0 ), /* 557 mult */ + S_ST( 'c', 3, 559, 0 ), /* 558 multi */ + S_ST( 'a', 3, 560, 0 ), /* 559 multic */ + S_ST( 's', 3, 561, 0 ), /* 560 multica */ + S_ST( 't', 3, 562, 0 ), /* 561 multicas */ + S_ST( 'c', 3, 563, 0 ), /* 562 multicast */ + S_ST( 'l', 3, 564, 0 ), /* 563 multicastc */ + S_ST( 'i', 3, 565, 0 ), /* 564 multicastcl */ + S_ST( 'e', 3, 566, 0 ), /* 565 multicastcli */ + S_ST( 'n', 3, 362, 0 ), /* 566 multicastclie */ + S_ST( 'n', 3, 610, 473 ), /* 567 */ + S_ST( 'i', 3, 363, 0 ), /* 568 n */ + S_ST( 'o', 3, 605, 568 ), /* 569 n */ + S_ST( 'l', 3, 571, 0 ), /* 570 no */ + S_ST( 'i', 3, 572, 0 ), /* 571 nol */ + S_ST( 'n', 3, 364, 0 ), /* 572 noli */ + S_ST( 'm', 3, 578, 570 ), /* 573 no */ + S_ST( 'o', 3, 575, 0 ), /* 574 nom */ + S_ST( 'd', 3, 576, 0 ), /* 575 nomo */ + S_ST( 'i', 3, 577, 0 ), /* 576 nomod */ + S_ST( 'f', 3, 365, 0 ), /* 577 nomodi */ + S_ST( 'r', 3, 579, 574 ), /* 578 nom */ + S_ST( 'u', 3, 580, 0 ), /* 579 nomr */ + S_ST( 'l', 3, 581, 0 ), /* 580 nomru */ + S_ST( 'i', 3, 582, 0 ), /* 581 nomrul */ + S_ST( 's', 3, 366, 0 ), /* 582 nomruli */ + S_ST( 'n', 3, 584, 573 ), /* 583 no */ + S_ST( 'v', 3, 585, 367 ), /* 584 non */ + S_ST( 'o', 3, 586, 0 ), /* 585 nonv */ + S_ST( 'l', 3, 587, 0 ), /* 586 nonvo */ + S_ST( 'a', 3, 588, 0 ), /* 587 nonvol */ + S_ST( 't', 3, 589, 0 ), /* 588 nonvola */ + S_ST( 'i', 3, 590, 0 ), /* 589 nonvolat */ + S_ST( 'l', 3, 368, 0 ), /* 590 nonvolati */ + S_ST( 'p', 3, 592, 583 ), /* 591 no */ + S_ST( 'e', 3, 593, 0 ), /* 592 nop */ + S_ST( 'e', 3, 369, 0 ), /* 593 nope */ + S_ST( 'q', 3, 595, 591 ), /* 594 no */ + S_ST( 'u', 3, 596, 0 ), /* 595 noq */ + S_ST( 'e', 3, 597, 0 ), /* 596 noqu */ + S_ST( 'r', 3, 370, 0 ), /* 597 noque */ + S_ST( 's', 3, 599, 594 ), /* 598 no */ + S_ST( 'e', 3, 603, 0 ), /* 599 nos */ + S_ST( 'l', 3, 601, 0 ), /* 600 nose */ + S_ST( 'e', 3, 602, 0 ), /* 601 nosel */ + S_ST( 'c', 3, 371, 0 ), /* 602 nosele */ + S_ST( 'r', 3, 604, 600 ), /* 603 nose */ + S_ST( 'v', 3, 372, 0 ), /* 604 noser */ + S_ST( 't', 3, 606, 598 ), /* 605 no */ + S_ST( 'r', 3, 608, 0 ), /* 606 not */ + S_ST( 'a', 3, 373, 0 ), /* 607 notr */ + S_ST( 'u', 3, 609, 607 ), /* 608 notr */ + S_ST( 's', 3, 374, 0 ), /* 609 notru */ + S_ST( 't', 3, 375, 569 ), /* 610 n */ + S_ST( 'p', 3, 612, 0 ), /* 611 ntp */ + S_ST( 'o', 3, 613, 0 ), /* 612 ntpp */ + S_ST( 'r', 3, 376, 0 ), /* 613 ntppo */ + S_ST( 's', 3, 615, 611 ), /* 614 ntp */ + S_ST( 'i', 3, 616, 0 ), /* 615 ntps */ + S_ST( 'g', 3, 617, 0 ), /* 616 ntpsi */ + S_ST( 'n', 3, 618, 0 ), /* 617 ntpsig */ + S_ST( 'd', 3, 619, 0 ), /* 618 ntpsign */ + S_ST( 's', 3, 620, 0 ), /* 619 ntpsignd */ + S_ST( 'o', 3, 621, 0 ), /* 620 ntpsignds */ + S_ST( 'c', 3, 622, 0 ), /* 621 ntpsigndso */ + S_ST( 'k', 3, 623, 0 ), /* 622 ntpsigndsoc */ + S_ST( 'e', 3, 377, 0 ), /* 623 ntpsigndsock */ + S_ST( 'o', 3, 625, 567 ), /* 624 */ + S_ST( 'r', 3, 626, 0 ), /* 625 o */ + S_ST( 'p', 3, 627, 0 ), /* 626 or */ + S_ST( 'h', 3, 628, 0 ), /* 627 orp */ + S_ST( 'a', 3, 378, 0 ), /* 628 orph */ + S_ST( 'w', 3, 630, 0 ), /* 629 orphan */ + S_ST( 'a', 3, 631, 0 ), /* 630 orphanw */ + S_ST( 'i', 3, 379, 0 ), /* 631 orphanwa */ + S_ST( 'p', 3, 391, 624 ), /* 632 */ + S_ST( 'a', 3, 634, 0 ), /* 633 p */ + S_ST( 'n', 3, 635, 0 ), /* 634 pa */ + S_ST( 'i', 3, 380, 0 ), /* 635 pan */ + S_ST( 'e', 3, 637, 633 ), /* 636 p */ + S_ST( 'e', 3, 381, 0 ), /* 637 pe */ + S_ST( 's', 3, 639, 0 ), /* 638 peer */ + S_ST( 't', 3, 640, 0 ), /* 639 peers */ + S_ST( 'a', 3, 641, 0 ), /* 640 peerst */ + S_ST( 't', 3, 382, 0 ), /* 641 peersta */ + S_ST( 'h', 3, 643, 636 ), /* 642 p */ + S_ST( 'o', 3, 644, 0 ), /* 643 ph */ + S_ST( 'n', 3, 383, 0 ), /* 644 pho */ + S_ST( 'i', 3, 384, 642 ), /* 645 p */ + S_ST( 'f', 3, 647, 0 ), /* 646 pid */ + S_ST( 'i', 3, 648, 0 ), /* 647 pidf */ + S_ST( 'l', 3, 385, 0 ), /* 648 pidfi */ + S_ST( 'o', 3, 651, 645 ), /* 649 p */ + S_ST( 'o', 3, 386, 0 ), /* 650 po */ + S_ST( 'r', 3, 387, 650 ), /* 651 po */ + S_ST( 'r', 3, 659, 649 ), /* 652 p */ + S_ST( 'e', 3, 657, 0 ), /* 653 pr */ + S_ST( 'e', 3, 655, 0 ), /* 654 pre */ + S_ST( 'm', 3, 656, 0 ), /* 655 pree */ + S_ST( 'p', 3, 388, 0 ), /* 656 preem */ + S_ST( 'f', 3, 658, 654 ), /* 657 pre */ + S_ST( 'e', 3, 389, 0 ), /* 658 pref */ + S_ST( 'o', 3, 672, 653 ), /* 659 pr */ + S_ST( 'c', 3, 661, 0 ), /* 660 pro */ + S_ST( '_', 3, 662, 0 ), /* 661 proc */ + S_ST( 'd', 3, 663, 0 ), /* 662 proc_ */ + S_ST( 'e', 3, 664, 0 ), /* 663 proc_d */ + S_ST( 'l', 3, 665, 0 ), /* 664 proc_de */ + S_ST( 'a', 3, 448, 0 ), /* 665 proc_del */ + S_ST( 'p', 3, 667, 660 ), /* 666 pro */ + S_ST( '_', 3, 668, 0 ), /* 667 prop */ + S_ST( 'd', 3, 669, 0 ), /* 668 prop_ */ + S_ST( 'e', 3, 670, 0 ), /* 669 prop_d */ + S_ST( 'l', 3, 671, 0 ), /* 670 prop_de */ + S_ST( 'a', 3, 447, 0 ), /* 671 prop_del */ + S_ST( 't', 3, 673, 666 ), /* 672 pro */ + S_ST( 'o', 3, 674, 0 ), /* 673 prot */ + S_ST( 's', 3, 675, 0 ), /* 674 proto */ + S_ST( 't', 3, 676, 0 ), /* 675 protos */ + S_ST( 'a', 3, 677, 0 ), /* 676 protost */ + S_ST( 't', 3, 390, 0 ), /* 677 protosta */ + S_ST( 'r', 3, 709, 632 ), /* 678 */ + S_ST( 'a', 3, 685, 0 ), /* 679 r */ + S_ST( 'n', 3, 681, 0 ), /* 680 ra */ + S_ST( 'd', 3, 682, 0 ), /* 681 ran */ + S_ST( 'f', 3, 683, 0 ), /* 682 rand */ + S_ST( 'i', 3, 684, 0 ), /* 683 randf */ + S_ST( 'l', 3, 392, 0 ), /* 684 randfi */ + S_ST( 'w', 3, 686, 680 ), /* 685 ra */ + S_ST( 's', 3, 687, 0 ), /* 686 raw */ + S_ST( 't', 3, 688, 0 ), /* 687 raws */ + S_ST( 'a', 3, 689, 0 ), /* 688 rawst */ + S_ST( 't', 3, 393, 0 ), /* 689 rawsta */ + S_ST( 'e', 3, 706, 679 ), /* 690 r */ + S_ST( 'f', 3, 692, 0 ), /* 691 re */ + S_ST( 'i', 3, 394, 0 ), /* 692 ref */ + S_ST( 'q', 3, 694, 691 ), /* 693 re */ + S_ST( 'u', 3, 695, 0 ), /* 694 req */ + S_ST( 'e', 3, 696, 0 ), /* 695 requ */ + S_ST( 's', 3, 697, 0 ), /* 696 reque */ + S_ST( 't', 3, 698, 0 ), /* 697 reques */ + S_ST( 'k', 3, 699, 0 ), /* 698 request */ + S_ST( 'e', 3, 395, 0 ), /* 699 requestk */ + S_ST( 's', 3, 702, 693 ), /* 700 re */ + S_ST( 'e', 3, 396, 0 ), /* 701 res */ + S_ST( 't', 3, 703, 701 ), /* 702 res */ + S_ST( 'r', 3, 704, 0 ), /* 703 rest */ + S_ST( 'i', 3, 705, 0 ), /* 704 restr */ + S_ST( 'c', 3, 397, 0 ), /* 705 restri */ + S_ST( 'v', 3, 707, 700 ), /* 706 re */ + S_ST( 'o', 3, 708, 0 ), /* 707 rev */ + S_ST( 'k', 3, 398, 0 ), /* 708 revo */ + S_ST( 'l', 3, 710, 690 ), /* 709 r */ + S_ST( 'i', 3, 711, 0 ), /* 710 rl */ + S_ST( 'm', 3, 712, 0 ), /* 711 rli */ + S_ST( 'i', 3, 399, 0 ), /* 712 rlim */ + S_ST( 's', 3, 786, 678 ), /* 713 */ + S_ST( 'a', 3, 715, 0 ), /* 714 s */ + S_ST( 'v', 3, 716, 0 ), /* 715 sa */ + S_ST( 'e', 3, 717, 0 ), /* 716 sav */ + S_ST( 'c', 3, 718, 0 ), /* 717 save */ + S_ST( 'o', 3, 719, 0 ), /* 718 savec */ + S_ST( 'n', 3, 720, 0 ), /* 719 saveco */ + S_ST( 'f', 3, 721, 0 ), /* 720 savecon */ + S_ST( 'i', 3, 722, 0 ), /* 721 saveconf */ + S_ST( 'g', 3, 723, 0 ), /* 722 saveconfi */ + S_ST( 'd', 3, 724, 0 ), /* 723 saveconfig */ + S_ST( 'i', 3, 400, 0 ), /* 724 saveconfigd */ + S_ST( 'e', 3, 735, 714 ), /* 725 s */ + S_ST( 'r', 3, 727, 0 ), /* 726 se */ + S_ST( 'v', 3, 728, 0 ), /* 727 ser */ + S_ST( 'e', 3, 401, 0 ), /* 728 serv */ + S_ST( '_', 3, 730, 0 ), /* 729 server */ + S_ST( 'o', 3, 731, 0 ), /* 730 server_ */ + S_ST( 'f', 3, 732, 0 ), /* 731 server_o */ + S_ST( 'f', 3, 733, 0 ), /* 732 server_of */ + S_ST( 's', 3, 734, 0 ), /* 733 server_off */ + S_ST( 'e', 3, 442, 0 ), /* 734 server_offs */ + S_ST( 't', 3, 736, 726 ), /* 735 se */ + S_ST( 'v', 3, 737, 0 ), /* 736 set */ + S_ST( 'a', 3, 402, 0 ), /* 737 setv */ + S_ST( 'i', 3, 739, 725 ), /* 738 s */ + S_ST( 'm', 3, 740, 0 ), /* 739 si */ + S_ST( 'u', 3, 741, 0 ), /* 740 sim */ + S_ST( 'l', 3, 742, 0 ), /* 741 simu */ + S_ST( 'a', 3, 743, 0 ), /* 742 simul */ + S_ST( 't', 3, 744, 0 ), /* 743 simula */ + S_ST( 'i', 3, 745, 439 ), /* 744 simulat */ + S_ST( 'o', 3, 746, 0 ), /* 745 simulati */ + S_ST( 'n', 3, 747, 0 ), /* 746 simulatio */ + S_ST( '_', 3, 748, 0 ), /* 747 simulation */ + S_ST( 'd', 3, 749, 0 ), /* 748 simulation_ */ + S_ST( 'u', 3, 750, 0 ), /* 749 simulation_d */ + S_ST( 'r', 3, 751, 0 ), /* 750 simulation_du */ + S_ST( 'a', 3, 752, 0 ), /* 751 simulation_dur */ + S_ST( 't', 3, 753, 0 ), /* 752 simulation_dura */ + S_ST( 'i', 3, 754, 0 ), /* 753 simulation_durat */ + S_ST( 'o', 3, 441, 0 ), /* 754 simulation_durati */ + S_ST( 'o', 3, 756, 738 ), /* 755 s */ + S_ST( 'u', 3, 757, 0 ), /* 756 so */ + S_ST( 'r', 3, 758, 0 ), /* 757 sou */ + S_ST( 'c', 3, 403, 0 ), /* 758 sour */ + S_ST( 't', 3, 782, 755 ), /* 759 s */ + S_ST( 'a', 3, 766, 0 ), /* 760 st */ + S_ST( 'c', 3, 762, 0 ), /* 761 sta */ + S_ST( 'k', 3, 763, 0 ), /* 762 stac */ + S_ST( 's', 3, 764, 0 ), /* 763 stack */ + S_ST( 'i', 3, 765, 0 ), /* 764 stacks */ + S_ST( 'z', 3, 404, 0 ), /* 765 stacksi */ + S_ST( 't', 3, 406, 761 ), /* 766 sta */ + S_ST( 'i', 3, 768, 0 ), /* 767 stat */ + S_ST( 's', 3, 769, 0 ), /* 768 stati */ + S_ST( 't', 3, 770, 0 ), /* 769 statis */ + S_ST( 'i', 3, 771, 0 ), /* 770 statist */ + S_ST( 'c', 3, 405, 0 ), /* 771 statisti */ + S_ST( 'd', 3, 773, 0 ), /* 772 stats */ + S_ST( 'i', 3, 407, 0 ), /* 773 statsd */ + S_ST( 'e', 3, 408, 760 ), /* 774 st */ + S_ST( 'b', 3, 776, 0 ), /* 775 step */ + S_ST( 'a', 3, 777, 0 ), /* 776 stepb */ + S_ST( 'c', 3, 409, 0 ), /* 777 stepba */ + S_ST( 'f', 3, 779, 775 ), /* 778 step */ + S_ST( 'w', 3, 410, 0 ), /* 779 stepf */ + S_ST( 'o', 3, 781, 778 ), /* 780 step */ + S_ST( 'u', 3, 411, 0 ), /* 781 stepo */ + S_ST( 'r', 3, 783, 774 ), /* 782 st */ + S_ST( 'a', 3, 784, 0 ), /* 783 str */ + S_ST( 't', 3, 785, 0 ), /* 784 stra */ + S_ST( 'u', 3, 412, 0 ), /* 785 strat */ + S_ST( 'y', 3, 414, 759 ), /* 786 s */ + S_ST( 's', 3, 788, 0 ), /* 787 sys */ + S_ST( 't', 3, 789, 0 ), /* 788 syss */ + S_ST( 'a', 3, 790, 0 ), /* 789 sysst */ + S_ST( 't', 3, 415, 0 ), /* 790 syssta */ + S_ST( 't', 3, 817, 713 ), /* 791 */ + S_ST( 'i', 3, 803, 0 ), /* 792 t */ + S_ST( 'c', 3, 416, 0 ), /* 793 ti */ + S_ST( 'm', 3, 796, 793 ), /* 794 ti */ + S_ST( 'e', 3, 419, 0 ), /* 795 tim */ + S_ST( 'i', 3, 797, 795 ), /* 796 tim */ + S_ST( 'n', 3, 798, 0 ), /* 797 timi */ + S_ST( 'g', 3, 799, 0 ), /* 798 timin */ + S_ST( 's', 3, 800, 0 ), /* 799 timing */ + S_ST( 't', 3, 801, 0 ), /* 800 timings */ + S_ST( 'a', 3, 802, 0 ), /* 801 timingst */ + S_ST( 't', 3, 420, 0 ), /* 802 timingsta */ + S_ST( 'n', 3, 804, 794 ), /* 803 ti */ + S_ST( 'k', 3, 805, 0 ), /* 804 tin */ + S_ST( 'e', 3, 421, 0 ), /* 805 tink */ + S_ST( 'o', 3, 422, 792 ), /* 806 t */ + S_ST( 'r', 3, 809, 806 ), /* 807 t */ + S_ST( 'a', 3, 423, 0 ), /* 808 tr */ + S_ST( 'u', 3, 810, 808 ), /* 809 tr */ + S_ST( 's', 3, 811, 424 ), /* 810 tru */ + S_ST( 't', 3, 812, 0 ), /* 811 trus */ + S_ST( 'e', 3, 813, 0 ), /* 812 trust */ + S_ST( 'd', 3, 814, 0 ), /* 813 truste */ + S_ST( 'k', 3, 815, 0 ), /* 814 trusted */ + S_ST( 'e', 3, 425, 0 ), /* 815 trustedk */ + S_ST( 't', 3, 426, 807 ), /* 816 t */ + S_ST( 'y', 3, 818, 816 ), /* 817 t */ + S_ST( 'p', 3, 427, 0 ), /* 818 ty */ + S_ST( 'u', 3, 820, 791 ), /* 819 */ + S_ST( 'n', 3, 826, 0 ), /* 820 u */ + S_ST( 'c', 3, 822, 0 ), /* 821 un */ + S_ST( 'o', 3, 823, 0 ), /* 822 unc */ + S_ST( 'n', 3, 824, 0 ), /* 823 unco */ + S_ST( 'f', 3, 825, 0 ), /* 824 uncon */ + S_ST( 'i', 3, 429, 0 ), /* 825 unconf */ + S_ST( 'p', 3, 827, 821 ), /* 826 un */ + S_ST( 'e', 3, 828, 0 ), /* 827 unp */ + S_ST( 'e', 3, 430, 0 ), /* 828 unpe */ + S_ST( 'v', 3, 830, 819 ), /* 829 */ + S_ST( 'e', 3, 831, 0 ), /* 830 v */ + S_ST( 'r', 3, 832, 0 ), /* 831 ve */ + S_ST( 's', 3, 833, 0 ), /* 832 ver */ + S_ST( 'i', 3, 834, 0 ), /* 833 vers */ + S_ST( 'o', 3, 431, 0 ), /* 834 versi */ + S_ST( 'w', 3, 842, 829 ), /* 835 */ + S_ST( 'a', 3, 837, 0 ), /* 836 w */ + S_ST( 'n', 3, 838, 0 ), /* 837 wa */ + S_ST( 'd', 3, 839, 0 ), /* 838 wan */ + S_ST( 'e', 3, 445, 0 ), /* 839 wand */ + S_ST( 'e', 3, 841, 836 ), /* 840 w */ + S_ST( 'e', 3, 433, 0 ), /* 841 we */ + S_ST( 'i', 3, 843, 840 ), /* 842 w */ + S_ST( 'l', 3, 844, 0 ), /* 843 wi */ + S_ST( 'd', 3, 845, 0 ), /* 844 wil */ + S_ST( 'c', 3, 846, 0 ), /* 845 wild */ + S_ST( 'a', 3, 847, 0 ), /* 846 wildc */ + S_ST( 'r', 3, 434, 0 ), /* 847 wildca */ + S_ST( 'x', 3, 849, 835 ), /* 848 */ + S_ST( 'l', 3, 850, 0 ), /* 849 x */ + S_ST( 'e', 3, 851, 0 ), /* 850 xl */ + S_ST( 'a', 3, 852, 0 ), /* 851 xle */ + S_ST( 'v', 3, 435, 0 ), /* 852 xlea */ + S_ST( 'y', 3, 854, 848 ), /* 853 [initial state] */ + S_ST( 'e', 3, 855, 0 ), /* 854 y */ + S_ST( 'a', 3, 436, 0 ) /* 855 ye */ +}; + diff --git a/contrib/ntp/ntpd/ntp_leapsec.c b/contrib/ntp/ntpd/ntp_leapsec.c new file mode 100644 index 000000000..7a652f5cf --- /dev/null +++ b/contrib/ntp/ntpd/ntp_leapsec.c @@ -0,0 +1,1186 @@ +/* + * ntp_leapsec.c - leap second processing for NTPD + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * ---------------------------------------------------------------------- + * This is an attempt to get the leap second handling into a dedicated + * module to make the somewhat convoluted logic testable. + */ + +#include +#include +#include +#include + +#include "ntp_types.h" +#include "ntp_fp.h" +#include "ntp_stdlib.h" +#include "ntp_calendar.h" +#include "ntp_leapsec.h" +#include "ntp.h" +#include "vint64ops.h" +#include "lib_strbuf.h" + +#include "isc/sha1.h" + +static const char * const logPrefix = "leapsecond file"; + +/* --------------------------------------------------------------------- + * GCC is rather sticky with its 'const' attribute. We have to do it more + * explicit than with a cast if we want to get rid of a CONST qualifier. + * Greetings from the PASCAL world, where casting was only possible via + * untagged unions... + */ +static inline void* +noconst( + const void* ptr + ) +{ + union { + const void * cp; + void * vp; + } tmp; + tmp.cp = ptr; + return tmp.vp; +} + +/* --------------------------------------------------------------------- + * Our internal data structure + */ +#define MAX_HIST 10 /* history of leap seconds */ + +struct leap_info { + vint64 ttime; /* transition time (after the step, ntp scale) */ + uint32_t stime; /* schedule limit (a month before transition) */ + int16_t taiof; /* TAI offset on and after the transition */ + uint8_t dynls; /* dynamic: inserted on peer/clock request */ +}; +typedef struct leap_info leap_info_t; + +struct leap_head { + vint64 update; /* time of information update */ + vint64 expire; /* table expiration time */ + uint16_t size; /* number of infos in table */ + int16_t base_tai; /* total leaps before first entry */ + int16_t this_tai; /* current TAI offset */ + int16_t next_tai; /* TAI offset after 'when' */ + vint64 dtime; /* due time (current era end) */ + vint64 ttime; /* nominal transition time (next era start) */ + vint64 stime; /* schedule time (when we take notice) */ + vint64 ebase; /* base time of this leap era */ + uint8_t dynls; /* next leap is dynamic (by peer request) */ +}; +typedef struct leap_head leap_head_t; + +struct leap_table { + leap_signature_t lsig; + leap_head_t head; + leap_info_t info[MAX_HIST]; +}; + +/* Where we store our tables */ +static leap_table_t _ltab[2], *_lptr; +static int/*BOOL*/ _electric; + +/* Forward decls of local helpers */ +static int add_range(leap_table_t*, const leap_info_t*); +static char * get_line(leapsec_reader, void*, char*, size_t); +static char * skipws(const char*); +static int parsefail(const char * cp, const char * ep); +static void reload_limits(leap_table_t*, const vint64*); +static void fetch_leap_era(leap_era_t*, const leap_table_t*, + const vint64*); +static int betweenu32(uint32_t, uint32_t, uint32_t); +static void reset_times(leap_table_t*); +static int leapsec_add(leap_table_t*, const vint64*, int); +static int leapsec_raw(leap_table_t*, const vint64 *, int, int); +static const char * lstostr(const vint64 * ts); + +/* ===================================================================== + * Get & Set the current leap table + */ + +/* ------------------------------------------------------------------ */ +leap_table_t * +leapsec_get_table( + int alternate) +{ + leap_table_t *p1, *p2; + + p1 = _lptr; + if (p1 == &_ltab[0]) { + p2 = &_ltab[1]; + } else if (p1 == &_ltab[1]) { + p2 = &_ltab[0]; + } else { + p1 = &_ltab[0]; + p2 = &_ltab[1]; + reset_times(p1); + reset_times(p2); + _lptr = p1; + } + if (alternate) { + memcpy(p2, p1, sizeof(leap_table_t)); + p1 = p2; + } + + return p1; +} + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_set_table( + leap_table_t * pt) +{ + if (pt == &_ltab[0] || pt == &_ltab[1]) + _lptr = pt; + return _lptr == pt; +} + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_electric( + int/*BOOL*/ on) +{ + int res = _electric; + if (on < 0) + return res; + + _electric = (on != 0); + if (_electric == res) + return res; + + if (_lptr == &_ltab[0] || _lptr == &_ltab[1]) + reset_times(_lptr); + + return res; +} + +/* ===================================================================== + * API functions that operate on tables + */ + +/* --------------------------------------------------------------------- + * Clear all leap second data. Use it for init & cleanup + */ +void +leapsec_clear( + leap_table_t * pt) +{ + memset(&pt->lsig, 0, sizeof(pt->lsig)); + memset(&pt->head, 0, sizeof(pt->head)); + reset_times(pt); +} + +/* --------------------------------------------------------------------- + * Load a leap second file and check expiration on the go + */ +int/*BOOL*/ +leapsec_load( + leap_table_t * pt , + leapsec_reader func, + void * farg, + int use_build_limit) +{ + char *cp, *ep, linebuf[50]; + vint64 ttime, limit; + long taiof; + struct calendar build; + + leapsec_clear(pt); + if (use_build_limit && ntpcal_get_build_date(&build)) { + /* don't prune everything -- permit the last 10yrs + * before build. + */ + build.year -= 10; + limit = ntpcal_date_to_ntp64(&build); + } else { + memset(&limit, 0, sizeof(limit)); + } + + while (get_line(func, farg, linebuf, sizeof(linebuf))) { + cp = linebuf; + if (*cp == '#') { + cp++; + if (*cp == '@') { + cp = skipws(cp+1); + pt->head.expire = strtouv64(cp, &ep, 10); + if (parsefail(cp, ep)) + goto fail_read; + pt->lsig.etime = pt->head.expire.D_s.lo; + } else if (*cp == '$') { + cp = skipws(cp+1); + pt->head.update = strtouv64(cp, &ep, 10); + if (parsefail(cp, ep)) + goto fail_read; + } + } else if (isdigit((u_char)*cp)) { + ttime = strtouv64(cp, &ep, 10); + if (parsefail(cp, ep)) + goto fail_read; + cp = skipws(ep); + taiof = strtol(cp, &ep, 10); + if ( parsefail(cp, ep) + || taiof > SHRT_MAX || taiof < SHRT_MIN) + goto fail_read; + if (ucmpv64(&ttime, &limit) >= 0) { + if (!leapsec_raw(pt, &ttime, + taiof, FALSE)) + goto fail_insn; + } else { + pt->head.base_tai = (int16_t)taiof; + } + pt->lsig.ttime = ttime.D_s.lo; + pt->lsig.taiof = (int16_t)taiof; + } + } + return TRUE; + +fail_read: + errno = EILSEQ; +fail_insn: + leapsec_clear(pt); + return FALSE; +} + +/* --------------------------------------------------------------------- + * Dump a table in human-readable format. Use 'fprintf' and a FILE + * pointer if you want to get it printed into a stream. + */ +void +leapsec_dump( + const leap_table_t * pt , + leapsec_dumper func, + void * farg) +{ + int idx; + vint64 ts; + struct calendar atb, ttb; + + ntpcal_ntp64_to_date(&ttb, &pt->head.expire); + (*func)(farg, "leap table (%u entries) expires at %04u-%02u-%02u:\n", + pt->head.size, + ttb.year, ttb.month, ttb.monthday); + idx = pt->head.size; + while (idx-- != 0) { + ts = pt->info[idx].ttime; + ntpcal_ntp64_to_date(&ttb, &ts); + ts = subv64u32(&ts, pt->info[idx].stime); + ntpcal_ntp64_to_date(&atb, &ts); + + (*func)(farg, "%04u-%02u-%02u [%c] (%04u-%02u-%02u) - %d\n", + ttb.year, ttb.month, ttb.monthday, + "-*"[pt->info[idx].dynls != 0], + atb.year, atb.month, atb.monthday, + pt->info[idx].taiof); + } +} + +/* ===================================================================== + * usecase driven API functions + */ + +int/*BOOL*/ +leapsec_query( + leap_result_t * qr , + uint32_t ts32 , + const time_t * pivot) +{ + leap_table_t * pt; + vint64 ts64, last, next; + uint32_t due32; + int fired; + + /* preset things we use later on... */ + fired = FALSE; + ts64 = ntpcal_ntp_to_ntp(ts32, pivot); + pt = leapsec_get_table(FALSE); + memset(qr, 0, sizeof(leap_result_t)); + + if (ucmpv64(&ts64, &pt->head.ebase) < 0) { + /* Most likely after leap frame reset. Could also be a + * backstep of the system clock. Anyway, get the new + * leap era frame. + */ + reload_limits(pt, &ts64); + } else if (ucmpv64(&ts64, &pt->head.dtime) >= 0) { + /* Boundary crossed in forward direction. This might + * indicate a leap transition, so we prepare for that + * case. + * + * Some operations below are actually NOPs in electric + * mode, but having only one code path that works for + * both modes is easier to maintain. + * + * There's another quirk we must keep looking out for: + * If we just stepped the clock, the step might have + * crossed a leap boundary. As with backward steps, we + * do not want to raise the 'fired' event in that case. + * So we raise the 'fired' event only if we're close to + * the transition and just reload the limits otherwise. + */ + last = addv64i32(&pt->head.dtime, 3); /* get boundary */ + if (ucmpv64(&ts64, &last) >= 0) { + /* that was likely a query after a step */ + reload_limits(pt, &ts64); + } else { + /* close enough for deeper examination */ + last = pt->head.ttime; + qr->warped = (int16_t)(last.D_s.lo - + pt->head.dtime.D_s.lo); + next = addv64i32(&ts64, qr->warped); + reload_limits(pt, &next); + fired = ucmpv64(&pt->head.ebase, &last) == 0; + if (fired) { + ts64 = next; + ts32 = next.D_s.lo; + } else { + qr->warped = 0; + } + } + } + + qr->tai_offs = pt->head.this_tai; + qr->ebase = pt->head.ebase; + qr->ttime = pt->head.ttime; + + /* If before the next scheduling alert, we're done. */ + if (ucmpv64(&ts64, &pt->head.stime) < 0) + return fired; + + /* now start to collect the remaining data */ + due32 = pt->head.dtime.D_s.lo; + + qr->tai_diff = pt->head.next_tai - pt->head.this_tai; + qr->ddist = due32 - ts32; + qr->dynamic = pt->head.dynls; + qr->proximity = LSPROX_SCHEDULE; + + /* if not in the last day before transition, we're done. */ + if (!betweenu32(due32 - SECSPERDAY, ts32, due32)) + return fired; + + qr->proximity = LSPROX_ANNOUNCE; + if (!betweenu32(due32 - 10, ts32, due32)) + return fired; + + /* The last 10s before the transition. Prepare for action! */ + qr->proximity = LSPROX_ALERT; + return fired; +} + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_query_era( + leap_era_t * qr , + uint32_t ntpts, + const time_t * pivot) +{ + const leap_table_t * pt; + vint64 ts64; + + pt = leapsec_get_table(FALSE); + ts64 = ntpcal_ntp_to_ntp(ntpts, pivot); + fetch_leap_era(qr, pt, &ts64); + return TRUE; +} + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_frame( + leap_result_t *qr) +{ + const leap_table_t * pt; + + memset(qr, 0, sizeof(leap_result_t)); + pt = leapsec_get_table(FALSE); + + qr->tai_offs = pt->head.this_tai; + qr->tai_diff = pt->head.next_tai - pt->head.this_tai; + qr->ebase = pt->head.ebase; + qr->ttime = pt->head.ttime; + qr->dynamic = pt->head.dynls; + + return ucmpv64(&pt->head.ttime, &pt->head.stime) >= 0; +} + +/* ------------------------------------------------------------------ */ +/* Reset the current leap frame */ +void +leapsec_reset_frame(void) +{ + reset_times(leapsec_get_table(FALSE)); +} + +/* ------------------------------------------------------------------ */ +/* load a file from a FILE pointer. Note: If hcheck is true, load + * only after successful signature check. The stream must be seekable + * or this will fail. + */ +int/*BOOL*/ +leapsec_load_stream( + FILE * ifp , + const char * fname, + int/*BOOL*/ logall) +{ + leap_table_t *pt; + int rcheck; + + if (NULL == fname) + fname = ""; + + rcheck = leapsec_validate((leapsec_reader)getc, ifp); + if (logall) + switch (rcheck) + { + case LSVALID_GOODHASH: + msyslog(LOG_NOTICE, "%s ('%s'): good hash signature", + logPrefix, fname); + break; + + case LSVALID_NOHASH: + msyslog(LOG_ERR, "%s ('%s'): no hash signature", + logPrefix, fname); + break; + case LSVALID_BADHASH: + msyslog(LOG_ERR, "%s ('%s'): signature mismatch", + logPrefix, fname); + break; + case LSVALID_BADFORMAT: + msyslog(LOG_ERR, "%s ('%s'): malformed hash signature", + logPrefix, fname); + break; + default: + msyslog(LOG_ERR, "%s ('%s'): unknown error code %d", + logPrefix, fname, rcheck); + break; + } + if (rcheck < 0) + return FALSE; + + rewind(ifp); + pt = leapsec_get_table(TRUE); + if (!leapsec_load(pt, (leapsec_reader)getc, ifp, TRUE)) { + switch (errno) { + case EINVAL: + msyslog(LOG_ERR, "%s ('%s'): bad transition time", + logPrefix, fname); + break; + case ERANGE: + msyslog(LOG_ERR, "%s ('%s'): times not ascending", + logPrefix, fname); + break; + default: + msyslog(LOG_ERR, "%s ('%s'): parsing error", + logPrefix, fname); + break; + } + return FALSE; + } + + if (pt->head.size) + msyslog(LOG_NOTICE, "%s ('%s'): loaded, expire=%s last=%s ofs=%d", + logPrefix, fname, lstostr(&pt->head.expire), + lstostr(&pt->info[0].ttime), pt->info[0].taiof); + else + msyslog(LOG_NOTICE, + "%s ('%s'): loaded, expire=%s ofs=%d (no entries after build date)", + logPrefix, fname, lstostr(&pt->head.expire), + pt->head.base_tai); + + return leapsec_set_table(pt); +} + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_load_file( + const char * fname, + struct stat * sb_old, + int/*BOOL*/ force, + int/*BOOL*/ logall) +{ + FILE * fp; + struct stat sb_new; + int rc; + + /* just do nothing if there is no leap file */ + if ( !(fname && *fname) ) + return FALSE; + + /* try to stat the leapfile */ + if (0 != stat(fname, &sb_new)) { + if (logall) + msyslog(LOG_ERR, "%s ('%s'): stat failed: %m", + logPrefix, fname); + return FALSE; + } + + /* silently skip to postcheck if no new file found */ + if (NULL != sb_old) { + if (!force + && sb_old->st_mtime == sb_new.st_mtime + && sb_old->st_ctime == sb_new.st_ctime + ) + return FALSE; + *sb_old = sb_new; + } + + /* try to open the leap file, complain if that fails + * + * [perlinger@ntp.org] + * coverity raises a TOCTOU (time-of-check/time-of-use) issue + * here, which is not entirely helpful: While there is indeed a + * possible race condition between the 'stat()' call above and + * the 'fopen)' call below, I intentionally want to omit the + * overhead of opening the file and calling 'fstat()', because + * in most cases the file would have be to closed anyway without + * reading the contents. I chose to disable the coverity + * warning instead. + * + * So unless someone comes up with a reasonable argument why + * this could be a real issue, I'll just try to silence coverity + * on that topic. + */ + /* coverity[toctou] */ + if ((fp = fopen(fname, "r")) == NULL) { + if (logall) + msyslog(LOG_ERR, + "%s ('%s'): open failed: %m", + logPrefix, fname); + return FALSE; + } + + rc = leapsec_load_stream(fp, fname, logall); + fclose(fp); + return rc; +} + +/* ------------------------------------------------------------------ */ +void +leapsec_getsig( + leap_signature_t * psig) +{ + const leap_table_t * pt; + + pt = leapsec_get_table(FALSE); + memcpy(psig, &pt->lsig, sizeof(leap_signature_t)); +} + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_expired( + uint32_t when, + const time_t * tpiv) +{ + const leap_table_t * pt; + vint64 limit; + + pt = leapsec_get_table(FALSE); + limit = ntpcal_ntp_to_ntp(when, tpiv); + return ucmpv64(&limit, &pt->head.expire) >= 0; +} + +/* ------------------------------------------------------------------ */ +int32_t +leapsec_daystolive( + uint32_t when, + const time_t * tpiv) +{ + const leap_table_t * pt; + vint64 limit; + + pt = leapsec_get_table(FALSE); + limit = ntpcal_ntp_to_ntp(when, tpiv); + limit = subv64(&pt->head.expire, &limit); + return ntpcal_daysplit(&limit).hi; +} + +/* ------------------------------------------------------------------ */ +#if 0 /* currently unused -- possibly revived later */ +int/*BOOL*/ +leapsec_add_fix( + int total, + uint32_t ttime, + uint32_t etime, + const time_t * pivot) +{ + time_t tpiv; + leap_table_t * pt; + vint64 tt64, et64; + + if (pivot == NULL) { + time(&tpiv); + pivot = &tpiv; + } + + et64 = ntpcal_ntp_to_ntp(etime, pivot); + tt64 = ntpcal_ntp_to_ntp(ttime, pivot); + pt = leapsec_get_table(TRUE); + + if ( ucmpv64(&et64, &pt->head.expire) <= 0 + || !leapsec_raw(pt, &tt64, total, FALSE) ) + return FALSE; + + pt->lsig.etime = etime; + pt->lsig.ttime = ttime; + pt->lsig.taiof = (int16_t)total; + + pt->head.expire = et64; + + return leapsec_set_table(pt); +} +#endif + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_add_dyn( + int insert, + uint32_t ntpnow, + const time_t * pivot ) +{ + leap_table_t * pt; + vint64 now64; + + pt = leapsec_get_table(TRUE); + now64 = ntpcal_ntp_to_ntp(ntpnow, pivot); + return ( leapsec_add(pt, &now64, (insert != 0)) + && leapsec_set_table(pt)); +} + +/* ------------------------------------------------------------------ */ +int/*BOOL*/ +leapsec_autokey_tai( + int tai_offset, + uint32_t ntpnow , + const time_t * pivot ) +{ + leap_table_t * pt; + leap_era_t era; + vint64 now64; + int idx; + + (void)tai_offset; + pt = leapsec_get_table(FALSE); + + /* Bail out if the basic offset is not zero and the putative + * offset is bigger than 10s. That was in 1972 -- we don't want + * to go back that far! + */ + if (pt->head.base_tai != 0 || tai_offset < 10) + return FALSE; + + /* If there's already data in the table, check if an update is + * possible. Update is impossible if there are static entries + * (since this indicates a valid leapsecond file) or if we're + * too close to a leapsecond transition: We do not know on what + * side the transition the sender might have been, so we use a + * dead zone around the transition. + */ + + /* Check for static entries */ + for (idx = 0; idx != pt->head.size; idx++) + if ( ! pt->info[idx].dynls) + return FALSE; + + /* get the fulll time stamp and leap era for it */ + now64 = ntpcal_ntp_to_ntp(ntpnow, pivot); + fetch_leap_era(&era, pt, &now64); + + /* check the limits with 20s dead band */ + era.ebase = addv64i32(&era.ebase, 20); + if (ucmpv64(&now64, &era.ebase) < 0) + return FALSE; + + era.ttime = addv64i32(&era.ttime, -20); + if (ucmpv64(&now64, &era.ttime) > 0) + return FALSE; + + /* Here we can proceed. Calculate the delta update. */ + tai_offset -= era.taiof; + + /* Shift the header info offsets. */ + pt->head.base_tai += tai_offset; + pt->head.this_tai += tai_offset; + pt->head.next_tai += tai_offset; + + /* Shift table entry offsets (if any) */ + for (idx = 0; idx != pt->head.size; idx++) + pt->info[idx].taiof += tai_offset; + + /* claim success... */ + return TRUE; +} + + +/* ===================================================================== + * internal helpers + */ + +/* [internal] Reset / init the time window in the leap processor to + * force reload on next query. Since a leap transition cannot take place + * at an odd second, the value chosen avoids spurious leap transition + * triggers. Making all three times equal forces a reload. Using the + * maximum value for unsigned 64 bits makes finding the next leap frame + * a bit easier. + */ +static void +reset_times( + leap_table_t * pt) +{ + memset(&pt->head.ebase, 0xFF, sizeof(vint64)); + pt->head.stime = pt->head.ebase; + pt->head.ttime = pt->head.ebase; + pt->head.dtime = pt->head.ebase; +} + +/* [internal] Add raw data to the table, removing old entries on the + * fly. This cannot fail currently. + */ +static int/*BOOL*/ +add_range( + leap_table_t * pt, + const leap_info_t * pi) +{ + /* If the table is full, make room by throwing out the oldest + * entry. But remember the accumulated leap seconds! Likewise, + * assume a positive leap insertion if this is the first entry + * in the table. This is not necessarily the best of all ideas, + * but it helps a great deal if a system does not have a leap + * table and gets updated from an upstream server. + */ + if (pt->head.size == 0) { + pt->head.base_tai = pi->taiof - 1; + } else if (pt->head.size >= MAX_HIST) { + pt->head.size = MAX_HIST - 1; + pt->head.base_tai = pt->info[pt->head.size].taiof; + } + + /* make room in lower end and insert item */ + memmove(pt->info+1, pt->info, pt->head.size*sizeof(*pt->info)); + pt->info[0] = *pi; + pt->head.size++; + + /* invalidate the cached limit data -- we might have news ;-) + * + * This blocks a spurious transition detection. OTOH, if you add + * a value after the last query before a leap transition was + * expected to occur, this transition trigger is lost. But we + * can probably live with that. + */ + reset_times(pt); + return TRUE; +} + +/* [internal] given a reader function, read characters into a buffer + * until either EOL or EOF is reached. Makes sure that the buffer is + * always NUL terminated, but silently truncates excessive data. The + * EOL-marker ('\n') is *not* stored in the buffer. + * + * Returns the pointer to the buffer, unless EOF was reached when trying + * to read the first character of a line. + */ +static char * +get_line( + leapsec_reader func, + void * farg, + char * buff, + size_t size) +{ + int ch; + char *ptr; + + /* if we cannot even store the delimiter, declare failure */ + if (buff == NULL || size == 0) + return NULL; + + ptr = buff; + while (EOF != (ch = (*func)(farg)) && '\n' != ch) + if (size > 1) { + size--; + *ptr++ = (char)ch; + } + /* discard trailing whitespace */ + while (ptr != buff && isspace((u_char)ptr[-1])) + ptr--; + *ptr = '\0'; + return (ptr == buff && ch == EOF) ? NULL : buff; +} + +/* [internal] skips whitespace characters from a character buffer. */ +static char * +skipws( + const char *ptr) +{ + while (isspace((u_char)*ptr)) + ptr++; + return (char*)noconst(ptr); +} + +/* [internal] check if a strtoXYZ ended at EOL or whitespace and + * converted something at all. Return TRUE if something went wrong. + */ +static int/*BOOL*/ +parsefail( + const char * cp, + const char * ep) +{ + return (cp == ep) + || (*ep && *ep != '#' && !isspace((u_char)*ep)); +} + +/* [internal] reload the table limits around the given time stamp. This + * is where the real work is done when it comes to table lookup and + * evaluation. Some care has been taken to have correct code for dealing + * with boundary conditions and empty tables. + * + * In electric mode, transition and trip time are the same. In dumb + * mode, the difference of the TAI offsets must be taken into account + * and trip time and transition time become different. The difference + * becomes the warping distance when the trip time is reached. + */ +static void +reload_limits( + leap_table_t * pt, + const vint64 * ts) +{ + int idx; + + /* Get full time and search the true lower bound. Use a + * simple loop here, since the number of entries does + * not warrant a binary search. This also works for an empty + * table, so there is no shortcut for that case. + */ + for (idx = 0; idx != pt->head.size; idx++) + if (ucmpv64(ts, &pt->info[idx].ttime) >= 0) + break; + + /* get time limits with proper bound conditions. Note that the + * bounds of the table will be observed even if the table is + * empty -- no undefined condition must arise from this code. + */ + if (idx >= pt->head.size) { + memset(&pt->head.ebase, 0x00, sizeof(vint64)); + pt->head.this_tai = pt->head.base_tai; + } else { + pt->head.ebase = pt->info[idx].ttime; + pt->head.this_tai = pt->info[idx].taiof; + } + if (--idx >= 0) { + pt->head.next_tai = pt->info[idx].taiof; + pt->head.dynls = pt->info[idx].dynls; + pt->head.ttime = pt->info[idx].ttime; + + if (_electric) + pt->head.dtime = pt->head.ttime; + else + pt->head.dtime = addv64i32( + &pt->head.ttime, + pt->head.next_tai - pt->head.this_tai); + + pt->head.stime = subv64u32( + &pt->head.ttime, pt->info[idx].stime); + + } else { + memset(&pt->head.ttime, 0xFF, sizeof(vint64)); + pt->head.stime = pt->head.ttime; + pt->head.dtime = pt->head.ttime; + pt->head.next_tai = pt->head.this_tai; + pt->head.dynls = 0; + } +} + +/* [internal] fetch the leap era for a given time stamp. + * This is a cut-down version the algorithm used to reload the table + * limits, but it does not update any global state and provides just the + * era information for a given time stamp. + */ +static void +fetch_leap_era( + leap_era_t * into, + const leap_table_t * pt , + const vint64 * ts ) +{ + int idx; + + /* Simple search loop, also works with empty table. */ + for (idx = 0; idx != pt->head.size; idx++) + if (ucmpv64(ts, &pt->info[idx].ttime) >= 0) + break; + /* fetch era data, keeping an eye on boundary conditions */ + if (idx >= pt->head.size) { + memset(&into->ebase, 0x00, sizeof(vint64)); + into->taiof = pt->head.base_tai; + } else { + into->ebase = pt->info[idx].ttime; + into->taiof = pt->info[idx].taiof; + } + if (--idx >= 0) + into->ttime = pt->info[idx].ttime; + else + memset(&into->ttime, 0xFF, sizeof(vint64)); +} + +/* [internal] Take a time stamp and create a leap second frame for + * it. This will schedule a leap second for the beginning of the next + * month, midnight UTC. The 'insert' argument tells if a leap second is + * added (!=0) or removed (==0). We do not handle multiple inserts + * (yet?) + * + * Returns 1 if the insert worked, 0 otherwise. (It's not possible to + * insert a leap second into the current history -- only appending + * towards the future is allowed!) + */ +static int/*BOOL*/ +leapsec_add( + leap_table_t* pt , + const vint64 * now64 , + int insert) +{ + vint64 ttime, starttime; + struct calendar fts; + leap_info_t li; + + /* Check against the table expiration and the latest available + * leap entry. Do not permit inserts, only appends, and only if + * the extend the table beyond the expiration! + */ + if ( ucmpv64(now64, &pt->head.expire) < 0 + || (pt->head.size && ucmpv64(now64, &pt->info[0].ttime) <= 0)) { + errno = ERANGE; + return FALSE; + } + + ntpcal_ntp64_to_date(&fts, now64); + /* To guard against dangling leap flags: do not accept leap + * second request on the 1st hour of the 1st day of the month. + */ + if (fts.monthday == 1 && fts.hour == 0) { + errno = EINVAL; + return FALSE; + } + + /* Ok, do the remaining calculations */ + fts.monthday = 1; + fts.hour = 0; + fts.minute = 0; + fts.second = 0; + starttime = ntpcal_date_to_ntp64(&fts); + fts.month++; + ttime = ntpcal_date_to_ntp64(&fts); + + li.ttime = ttime; + li.stime = ttime.D_s.lo - starttime.D_s.lo; + li.taiof = (pt->head.size ? pt->info[0].taiof : pt->head.base_tai) + + (insert ? 1 : -1); + li.dynls = 1; + return add_range(pt, &li); +} + +/* [internal] Given a time stamp for a leap insertion (the exact begin + * of the new leap era), create new leap frame and put it into the + * table. This is the work horse for reading a leap file and getting a + * leap second update via authenticated network packet. + */ +int/*BOOL*/ +leapsec_raw( + leap_table_t * pt, + const vint64 * ttime, + int taiof, + int dynls) +{ + vint64 starttime; + struct calendar fts; + leap_info_t li; + + /* Check that we either extend the table or get a duplicate of + * the latest entry. The latter is a benevolent overwrite with + * identical data and could happen if we get an autokey message + * that extends the lifetime of the current leapsecond table. + * Otherwise paranoia rulez! + */ + if (pt->head.size) { + int cmp = ucmpv64(ttime, &pt->info[0].ttime); + if (cmp == 0) + cmp -= (taiof != pt->info[0].taiof); + if (cmp < 0) { + errno = ERANGE; + return FALSE; + } + if (cmp == 0) + return TRUE; + } + + ntpcal_ntp64_to_date(&fts, ttime); + /* If this does not match the exact month start, bail out. */ + if (fts.monthday != 1 || fts.hour || fts.minute || fts.second) { + errno = EINVAL; + return FALSE; + } + fts.month--; /* was in range 1..12, no overflow here! */ + starttime = ntpcal_date_to_ntp64(&fts); + li.ttime = *ttime; + li.stime = ttime->D_s.lo - starttime.D_s.lo; + li.taiof = (int16_t)taiof; + li.dynls = (dynls != 0); + return add_range(pt, &li); +} + +/* [internal] Do a wrap-around save range inclusion check. + * Returns TRUE if x in [lo,hi[ (intervall open on right side) with full + * handling of an overflow / wrap-around. + */ +static int/*BOOL*/ +betweenu32( + uint32_t lo, + uint32_t x, + uint32_t hi) +{ + int rc; + + if (lo <= hi) + rc = (lo <= x) && (x < hi); + else + rc = (lo <= x) || (x < hi); + return rc; +} + +/* ===================================================================== + * validation stuff + */ + +typedef struct { + unsigned char hv[ISC_SHA1_DIGESTLENGTH]; +} sha1_digest; + +/* [internal] parse a digest line to get the hash signature + * The NIST code creating the hash writes them out as 5 hex integers + * without leading zeros. This makes reading them back as hex-encoded + * BLOB impossible, because there might be less than 40 hex digits. + * + * The solution is to read the values back as integers, and then do the + * byte twiddle necessary to get it into an array of 20 chars. The + * drawback is that it permits any acceptable number syntax provided by + * 'scanf()' and 'strtoul()', including optional signs and '0x' + * prefixes. + */ +static int/*BOOL*/ +do_leap_hash( + sha1_digest * mac, + char const * cp ) +{ + int wi, di, num, len; + unsigned long tmp[5]; + + memset(mac, 0, sizeof(*mac)); + num = sscanf(cp, " %lx %lx %lx %lx %lx%n", + &tmp[0], &tmp[1], &tmp[2], &tmp[3], &tmp[4], + &len); + if (num != 5 || cp[len] > ' ') + return FALSE; + + /* now do the byte twiddle */ + for (wi=0; wi < 5; ++wi) + for (di=3; di >= 0; --di) { + mac->hv[wi*4 + di] = + (unsigned char)(tmp[wi] & 0x0FF); + tmp[wi] >>= 8; + } + return TRUE; +} + +/* [internal] add the digits of a data line to the hash, stopping at the + * next hash ('#') character. + */ +static void +do_hash_data( + isc_sha1_t * mdctx, + char const * cp ) +{ + unsigned char text[32]; // must be power of two! + unsigned int tlen = 0; + unsigned char ch; + + while ('\0' != (ch = *cp++) && '#' != ch) + if (isdigit(ch)) { + text[tlen++] = ch; + tlen &= (sizeof(text)-1); + if (0 == tlen) + isc_sha1_update( + mdctx, text, sizeof(text)); + } + + if (0 < tlen) + isc_sha1_update(mdctx, text, tlen); +} + +/* given a reader and a reader arg, calculate and validate the the hash + * signature of a NIST leap second file. + */ +int +leapsec_validate( + leapsec_reader func, + void * farg) +{ + isc_sha1_t mdctx; + sha1_digest rdig, ldig; /* remote / local digests */ + char line[50]; + int hlseen = -1; + + isc_sha1_init(&mdctx); + while (get_line(func, farg, line, sizeof(line))) { + if (!strncmp(line, "#h", 2)) + hlseen = do_leap_hash(&rdig, line+2); + else if (!strncmp(line, "#@", 2)) + do_hash_data(&mdctx, line+2); + else if (!strncmp(line, "#$", 2)) + do_hash_data(&mdctx, line+2); + else if (isdigit((unsigned char)line[0])) + do_hash_data(&mdctx, line); + } + isc_sha1_final(&mdctx, ldig.hv); + isc_sha1_invalidate(&mdctx); + + if (0 > hlseen) + return LSVALID_NOHASH; + if (0 == hlseen) + return LSVALID_BADFORMAT; + if (0 != memcmp(&rdig, &ldig, sizeof(sha1_digest))) + return LSVALID_BADHASH; + return LSVALID_GOODHASH; +} + +/* + * lstostr - prettyprint NTP seconds + */ +static const char * +lstostr( + const vint64 * ts) +{ + char * buf; + struct calendar tm; + + LIB_GETBUF(buf); + + if ( ! (ts->d_s.hi >= 0 && ntpcal_ntp64_to_date(&tm, ts) >= 0)) + snprintf(buf, LIB_BUFLENGTH, "%s", "9999-12-31T23:59:59Z"); + else + snprintf(buf, LIB_BUFLENGTH, "%04d-%02d-%02dT%02d:%02d:%02dZ", + tm.year, tm.month, tm.monthday, + tm.hour, tm.minute, tm.second); + + return buf; +} + +/* reset the global state for unit tests */ +void +leapsec_ut_pristine(void) +{ + memset(_ltab, 0, sizeof(_ltab)); + _lptr = NULL; + _electric = 0; +} + + + +/* -*- that's all folks! -*- */ diff --git a/contrib/ntp/ntpd/ntp_leapsec.h b/contrib/ntp/ntpd/ntp_leapsec.h new file mode 100644 index 000000000..120b75fcb --- /dev/null +++ b/contrib/ntp/ntpd/ntp_leapsec.h @@ -0,0 +1,276 @@ +/* + * ntp_leapsec.h - leap second processing for NTPD + * + * Written by Juergen Perlinger (perlinger@ntp.org) for the NTP project. + * The contents of 'html/copyright.html' apply. + * ---------------------------------------------------------------------- + * This is an attempt to get the leap second handling into a dedicated + * module to make the somewhat convoluted logic testable. + */ + +#ifndef NTP_LEAPSEC_H +#define NTP_LEAPSEC_H + +struct stat; + + +/* function pointer types. Note that 'fprintf' and 'getc' can be casted + * to the dumper resp. reader type, provided the auxiliary argument is a + * valid FILE pointer in hat case. + */ +typedef void (*leapsec_dumper)(void*, const char *fmt, ...); +typedef int (*leapsec_reader)(void*); + +struct leap_table; +typedef struct leap_table leap_table_t; + +/* Validate a stream containing a leap second file in the NIST / NTPD + * format that can also be loaded via 'leapsec_load()'. This uses + * the SHA1 hash and preprocessing as described in the NIST leapsecond + * file. + */ +#define LSVALID_GOODHASH 1 /* valid signature */ +#define LSVALID_NOHASH 0 /* no signature in file */ +#define LSVALID_BADHASH -1 /* signature mismatch */ +#define LSVALID_BADFORMAT -2 /* signature not parseable */ + +extern int leapsec_validate(leapsec_reader, void*); + + +/* Set/get electric mode + * Electric mode is defined as the operation mode where the system clock + * automagically manages the leap second, so we don't have to care about + * stepping the clock. (This should be the case with most systems, + * including the current implementation of the Win32 timekeeping.) + * + * The consequence of electric mode is that we do not 'see' the leap + * second, and no client actions are needed when crossing the leap era + * boundary. In manual (aka non-electric) mode the clock will simply + * step forward untill *we* (that is, this module) tells the client app + * to step at the right time. This needs a slightly different type of + * processing, so switching between those two modes should not be done + * too close to a leap second. The transition might be lost in that + * case. (The limit is actual 2 sec before transition.) + * + * OTOH, this is a system characteristic, so it's expected to be set + * properly somewhere after system start and retain the value. + * + * Simply querying the state or setting it to the same value as before + * does not have any unwanted side effects. You can query by giving a + * negative value for the switch. + */ +extern int/*BOOL*/ leapsec_electric(int/*BOOL*/ on); + +/* Query result for a leap era. This is the minimal stateless + * information available for a time stamp in UTC. + */ +struct leap_era { + vint64 ebase; /* era base (UTC of start) */ + vint64 ttime; /* era end (UTC of next leap second) */ + int16_t taiof; /* offset to TAI in this era */ +}; +typedef struct leap_era leap_era_t; + +/* Query result for a leap second schedule + * 'ebase' is the nominal UTC time when the current leap era + * started. (Era base time) + * 'ttime' is the next transition point in full time scale. (Nominal UTC + * time when the next leap era starts.) + * 'ddist' is the distance to the transition, in clock seconds. + * This is the distance to the due time, which is different + * from the transition time if the mode is non-electric. + * Only valid if 'tai_diff' is not zero. + * 'tai_offs' is the CURRENT distance from clock (UTC) to TAI. Always + * valid. + * 'tai_diff' is the change in TAI offset after the next leap + * transition. Zero if nothing is pending or too far ahead. + * 'warped' is set only once, when the the leap second occurred between + * two queries. Always zero in electric mode. If non-zero, + * immediately step the clock. + * 'proximity' is a proximity warning. See definitions below. This is + * more useful than an absolute difference to the leap second. + * 'dynamic' != 0 if entry was requested by clock/peer + */ +struct leap_result { + vint64 ebase; + vint64 ttime; + uint32_t ddist; + int16_t tai_offs; + int16_t tai_diff; + int16_t warped; + uint8_t proximity; + uint8_t dynamic; +}; +typedef struct leap_result leap_result_t; + +/* The leap signature is used in two distinct circumstances, and it has + * slightly different content in these cases: + * - it is used to indictae the time range covered by the leap second + * table, and then it contains the last transition, TAI offset after + * the final transition, and the expiration time. + * - it is used to query data for AUTOKEY updates, and then it contains + * the *current* TAI offset, the *next* transition time and the + * expiration time of the table. + */ +struct leap_signature { + uint32_t etime; /* expiration time */ + uint32_t ttime; /* transition time */ + int16_t taiof; /* total offset to TAI */ +}; +typedef struct leap_signature leap_signature_t; + + +#ifdef LEAP_SMEAR + +struct leap_smear_info { + int enabled; /* not 0 if smearing is generally enabled */ + int in_progress; /* not 0 if smearing is in progress, i.e. the offset has been computed */ + int leap_occurred; /* not 0 if the leap second has already occurred, i.e., during the leap second */ + double doffset; /* the current smear offset as double */ + l_fp offset; /* the current smear offset */ + uint32_t t_offset; /* the current time for which a smear offset has been computed */ + long interval; /* smear interval, in [s], should be at least some hours */ + double intv_start; /* start time of the smear interval */ + double intv_end; /* end time of the smear interval */ +}; +typedef struct leap_smear_info leap_smear_info_t; + +#endif /* LEAP_SMEAR */ + + +#define LSPROX_NOWARN 0 /* clear radar screen */ +#define LSPROX_SCHEDULE 1 /* less than 1 month to target*/ +#define LSPROX_ANNOUNCE 2 /* less than 1 day to target */ +#define LSPROX_ALERT 3 /* less than 10 sec to target */ + +/* Get the current or alternate table pointer. Getting the alternate + * pointer will automatically copy the primary table, so it can be + * subsequently modified. + */ +extern leap_table_t *leapsec_get_table(int alternate); + +/* Set the current leap table. Accepts only return values from + * 'leapsec_get_table()', so it's hard to do something wrong. Returns + * TRUE if the current table is the requested one. + */ +extern int/*BOOL*/ leapsec_set_table(leap_table_t *); + +/* Clear all leap second data. Use it for init & cleanup */ +extern void leapsec_clear(leap_table_t*); + +/* Load a leap second file. If 'blimit' is set, do not store (but + * register with their TAI offset) leap entries before the build date. + * Update the leap signature data on the fly. + */ +extern int/*BOOL*/ leapsec_load(leap_table_t*, leapsec_reader, + void*, int blimit); + +/* Dump the current leap table in readable format, using the provided + * dump formatter function. + */ +extern void leapsec_dump(const leap_table_t*, leapsec_dumper func, void *farg); + +/* Read a leap second file from stream. This is a convenience wrapper + * around the generic load function, 'leapsec_load()'. + */ +extern int/*BOOL*/ leapsec_load_stream(FILE * fp, const char * fname, + int/*BOOL*/logall); + +/* Read a leap second file from file. It checks that the file exists and + * (if 'force' is not applied) the ctime/mtime has changed since the + * last load. If the file has to be loaded, either due to 'force' or + * changed time stamps, the 'stat()' results of the file are stored in + * '*sb' for the next cycle. Returns TRUE on successful load, FALSE + * otherwise. Uses 'leapsec_load_stream()' internally. + */ +extern int/*BOOL*/ leapsec_load_file(const char * fname, struct stat * sb, + int/*BOOL*/force, int/*BOOL*/logall); + +/* Get the current leap data signature. This consists of the last + * ransition, the table expiration, and the total TAI difference at the + * last transition. This is valid even if the leap transition itself was + * culled due to the build date limit. + */ +extern void leapsec_getsig(leap_signature_t * psig); + +/* Check if the leap table is expired at the given time. + */ +extern int/*BOOL*/ leapsec_expired(uint32_t when, const time_t * pivot); + +/* Get the distance to expiration in days. + * Returns negative values if expired, zero if there are less than 24hrs + * left, and positive numbers otherwise. + */ +extern int32_t leapsec_daystolive(uint32_t when, const time_t * pivot); + +/* Reset the current leap frame, so the next query will do proper table + * lookup from fresh. Suppresses a possible leap era transition detection + * for the next query. + */ +extern void leapsec_reset_frame(void); + +#if 0 /* currently unused -- possibly revived later */ +/* Given a transition time, the TAI offset valid after that and an + * expiration time, try to establish a system leap transition. Only + * works if the existing table is extended. On success, updates the + * signature data. + */ +extern int/*BOOL*/ leapsec_add_fix(int offset, uint32_t ttime, uint32_t etime, + const time_t * pivot); +#endif + +/* Take a time stamp and create a leap second frame for it. This will + * schedule a leap second for the beginning of the next month, midnight + * UTC. The 'insert' argument tells if a leap second is added (!=0) or + * removed (==0). We do not handle multiple inserts (yet?) + * + * Returns 1 if the insert worked, 0 otherwise. (It's not possible to + * insert a leap second into the current history -- only appending + * towards the future is allowed!) + * + * 'ntp_now' is subject to era unfolding. The entry is marked + * dynamic. The leap signature is NOT updated. + */ +extern int/*BOOL*/ leapsec_add_dyn(int/*BOOL*/ insert, uint32_t ntp_now, + const time_t * pivot); + +/* Take a time stamp and get the associated leap information. The time + * stamp is subject to era unfolding around the pivot or the current + * system time if pivot is NULL. Sets the information in '*qr' and + * returns TRUE if a leap second era boundary was crossed between the + * last and the current query. In that case, qr->warped contains the + * required clock stepping, which is always zero in electric mode. + */ +extern int/*BOOL*/ leapsec_query(leap_result_t * qr, uint32_t ntpts, + const time_t * pivot); + +/* For a given time stamp, fetch the data for the bracketing leap + * era. The time stamp is subject to NTP era unfolding. + */ +extern int/*BOOL*/ leapsec_query_era(leap_era_t * qr, uint32_t ntpts, + const time_t * pivot); + +/* Get the current leap frame info. Returns TRUE if the result contains + * useable data, FALSE if there is currently no leap second frame. + * This merely replicates some results from a previous query, but since + * it does not check the current time, only the following entries are + * meaningful: + * qr->ttime; + * qr->tai_offs; + * qr->tai_diff; + * qr->dynamic; + */ +extern int/*BOOL*/ leapsec_frame(leap_result_t *qr); + + +/* Process a AUTOKEY TAI offset information. This *might* augment the + * current leap data table with the given TAI offset. + * Returns TRUE if action was taken, FALSE otherwise. + */ +extern int/*BOOL*/ leapsec_autokey_tai(int tai_offset, uint32_t ntpnow, + const time_t * pivot); + +/* reset global state for unit tests */ +extern void leapsec_ut_pristine(void); + +#endif /* !defined(NTP_LEAPSEC_H) */ diff --git a/contrib/ntp/ntpd/ntp_loopfilter.c b/contrib/ntp/ntpd/ntp_loopfilter.c index 600f68307..42c30de56 100644 --- a/contrib/ntp/ntpd/ntp_loopfilter.c +++ b/contrib/ntp/ntpd/ntp_loopfilter.c @@ -8,21 +8,21 @@ # include #endif +#ifdef USE_SNPRINTB +# include +#endif #include "ntpd.h" #include "ntp_io.h" #include "ntp_unixtime.h" #include "ntp_stdlib.h" +#include #include #include #include #include -#if defined(VMS) && defined(VMS_LOCALUNIT) /*wjm*/ -#include "ntp_refclock.h" -#endif /* VMS */ - #ifdef KERNEL_PLL #include "ntp_syscall.h" #endif /* KERNEL_PLL */ @@ -35,18 +35,19 @@ * All units are in s and s/s, unless noted otherwise. */ #define CLOCK_MAX .128 /* default step threshold (s) */ -#define CLOCK_MINSTEP 900. /* default stepout threshold (s) */ +#define CLOCK_MINSTEP 300. /* default stepout threshold (s) */ #define CLOCK_PANIC 1000. /* default panic threshold (s) */ #define CLOCK_PHI 15e-6 /* max frequency error (s/s) */ #define CLOCK_PLL 16. /* PLL loop gain (log2) */ #define CLOCK_AVG 8. /* parameter averaging constant */ -#define CLOCK_FLL (NTP_MAXPOLL + CLOCK_AVG) /* FLL loop gain */ -#define CLOCK_ALLAN 1500. /* compromise Allan intercept (s) */ -#define CLOCK_DAY 86400. /* one day in seconds (s) */ -#define CLOCK_JUNE (CLOCK_DAY * 30) /* June in seconds (s) */ +#define CLOCK_FLL .25 /* FLL loop gain */ +#define CLOCK_FLOOR .0005 /* startup offset floor (s) */ +#define CLOCK_ALLAN 11 /* Allan intercept (log2 s) */ #define CLOCK_LIMIT 30 /* poll-adjust threshold */ #define CLOCK_PGATE 4. /* poll-adjust gate */ #define PPS_MAXAGE 120 /* kernel pps signal timeout (s) */ +#define FREQTOD(x) ((x) / 65536e6) /* NTP to double */ +#define DTOFREQ(x) ((int32)((x) * 65536e6)) /* double to NTP */ /* * Clock discipline state machine. This is used to control the @@ -54,32 +55,25 @@ * timewarp. * * State < step > step Comments - * ==================================================== - * NSET FREQ step, FREQ no ntp.drift + * ======================================================== + * NSET FREQ step, FREQ freq not set * - * FSET SYNC step, SYNC ntp.drift + * FSET SYNC step, SYNC freq set * - * FREQ if (mu < 900) if (mu < 900) set freq + * FREQ if (mu < 900) if (mu < 900) set freq direct * ignore ignore * else else * freq, SYNC freq, step, SYNC * - * SYNC SYNC if (mu < 900) adjust phase/freq - * ignore - * else - * SPIK + * SYNC SYNC SPIK, ignore adjust phase/freq * - * SPIK SYNC step, SYNC set phase + * SPIK SYNC if (mu < 900) adjust phase/freq + * ignore + * step, SYNC */ -#define S_NSET 0 /* clock never set */ -#define S_FSET 1 /* frequency set from the drift file */ -#define S_SPIK 2 /* spike detected */ -#define S_FREQ 3 /* frequency mode */ -#define S_SYNC 4 /* clock synchronized */ - /* * Kernel PLL/PPS state machine. This is used with the kernel PLL - * modifications described in the README.kernel file. + * modifications described in the documentation. * * If kernel support for the ntp_adjtime() system call is available, the * ntp_control flag is set. The ntp_enable and kern_enable flags can be @@ -97,65 +91,80 @@ * includes TAI offset and is identified by the symbol NTP_API with * value 4. * - * Each update to a prefer peer sets pps_stratum if it survives the - * intersection algorithm and its time is within range. The PPS time - * discipline is enabled (STA_PPSTIME bit set in the status word) when - * pps_stratum is true and the PPS frequency discipline is enabled. If - * the PPS time discipline is enabled and the kernel reports a PPS - * signal is present, the pps_control variable is set to the current - * time. If the current time is later than pps_control by PPS_MAXAGE - * (120 s), this variable is set to zero. + * Each PPS time/frequency discipline can be enabled by the atom driver + * or another driver. If enabled, the STA_PPSTIME and STA_FREQ bits are + * set in the kernel status word; otherwise, these bits are cleared. + * These bits are also cleard if the kernel reports an error. * * If an external clock is present, the clock driver sets STA_CLK in the * status word. When the local clock driver sees this bit, it updates * via this routine, which then calls ntp_adjtime() with the STA_PLL bit * set to zero, in which case the system clock is not adjusted. This is * also a signal for the external clock driver to discipline the system - * clock. + * clock. Unless specified otherwise, all times are in seconds. */ /* * Program variables that can be tinkered. */ -double clock_max = CLOCK_MAX; /* step threshold (s) */ -double clock_minstep = CLOCK_MINSTEP; /* stepout threshold (s) */ -double clock_panic = CLOCK_PANIC; /* panic threshold (s) */ +double clock_max_back = CLOCK_MAX; /* step threshold */ +double clock_max_fwd = CLOCK_MAX; /* step threshold */ +double clock_minstep = CLOCK_MINSTEP; /* stepout threshold */ +double clock_panic = CLOCK_PANIC; /* panic threshold */ double clock_phi = CLOCK_PHI; /* dispersion rate (s/s) */ -double allan_xpt = CLOCK_ALLAN; /* Allan intercept (s) */ +u_char allan_xpt = CLOCK_ALLAN; /* Allan intercept (log2 s) */ /* * Program variables */ -static double clock_offset; /* offset (s) */ -double clock_jitter; /* offset jitter (s) */ +static double clock_offset; /* offset */ +double clock_jitter; /* offset jitter */ double drift_comp; /* frequency (s/s) */ +static double init_drift_comp; /* initial frequency (PPM) */ double clock_stability; /* frequency stability (wander) (s/s) */ -u_long sys_clocktime; /* last system clock update */ -u_long pps_control; /* last pps update */ -u_long sys_tai; /* UTC offset from TAI (s) */ -static void rstclock P((int, u_long, double)); /* transition function */ +double clock_codec; /* audio codec frequency (samples/s) */ +static u_long clock_epoch; /* last update */ +u_int sys_tai; /* TAI offset from UTC */ +static int loop_started; /* TRUE after LOOP_DRIFTINIT */ +static void rstclock (int, double); /* transition function */ +static double direct_freq(double); /* direct set frequency */ +static void set_freq(double); /* set frequency */ +#ifndef PATH_MAX +# define PATH_MAX MAX_PATH +#endif +static char relative_path[PATH_MAX + 1]; /* relative path per recursive make */ +static char *this_file = NULL; #ifdef KERNEL_PLL -struct timex ntv; /* kernel API parameters */ -int pll_status; /* status bits for kernel pll */ +static struct timex ntv; /* ntp_adjtime() parameters */ +int pll_status; /* last kernel status bits */ +#if defined(STA_NANO) && NTP_API == 4 +static u_int loop_tai; /* last TAI offset */ +#endif /* STA_NANO */ +static void start_kern_loop(void); +static void stop_kern_loop(void); #endif /* KERNEL_PLL */ /* * Clock state machine control flags */ -int ntp_enable; /* clock discipline enabled */ +int ntp_enable = TRUE; /* clock discipline enabled */ int pll_control; /* kernel support available */ -int kern_enable; /* kernel support enabled */ -int pps_enable; /* kernel PPS discipline enabled */ +int kern_enable = TRUE; /* kernel support enabled */ +int hardpps_enable; /* kernel PPS discipline enabled */ int ext_enable; /* external clock enabled */ int pps_stratum; /* pps stratum */ -int allow_panic = FALSE; /* allow panic correction */ -int mode_ntpdate = FALSE; /* exit on first clock set */ +int kernel_status; /* from ntp_adjtime */ +int allow_panic = FALSE; /* allow panic correction (-g) */ +int force_step_once = FALSE; /* always step time once at startup (-G) */ +int mode_ntpdate = FALSE; /* exit on first clock set (-q) */ +int freq_cnt; /* initial frequency clamp */ +int freq_set; /* initial set frequency switch */ /* * Clock state machine variables */ -int state; /* clock discipline state */ -u_char sys_poll = NTP_MINDPOLL; /* time constant/poll (log2 s) */ +int state = 0; /* clock discipline state */ +u_char sys_poll; /* time constant/poll (log2 s) */ int tc_counter; /* jiggle counter */ double last_offset; /* last offset (s) */ @@ -172,13 +181,42 @@ static double sys_mindly; /* huff-n'-puff filter min delay */ #define MOD_BITS (MOD_OFFSET | MOD_MAXERROR | MOD_ESTERROR | \ MOD_STATUS | MOD_TIMECONST) #ifdef SIGSYS -static void pll_trap P((int)); /* configuration trap */ +static void pll_trap (int); /* configuration trap */ static struct sigaction sigsys; /* current sigaction status */ static struct sigaction newsigsys; /* new sigaction status */ static sigjmp_buf env; /* environment var. for pll_trap() */ #endif /* SIGSYS */ #endif /* KERNEL_PLL */ +static void +sync_status(const char *what, int ostatus, int nstatus) +{ + char obuf[256], nbuf[256], tbuf[1024]; +#if defined(USE_SNPRINTB) && defined (STA_FMT) + snprintb(obuf, sizeof(obuf), STA_FMT, ostatus); + snprintb(nbuf, sizeof(nbuf), STA_FMT, nstatus); +#else + snprintf(obuf, sizeof(obuf), "%04x", ostatus); + snprintf(nbuf, sizeof(nbuf), "%04x", nstatus); +#endif + snprintf(tbuf, sizeof(tbuf), "%s status: %s -> %s", what, obuf, nbuf); + report_event(EVNT_KERN, NULL, tbuf); +} + +/* + * file_name - return pointer to non-relative portion of this C file pathname + */ +static char *file_name(void) +{ + if (this_file == NULL) { + (void)strncpy(relative_path, __FILE__, PATH_MAX); + for (this_file=relative_path; + *this_file && ! isalnum((unsigned char)*this_file); + this_file++) ; + } + return this_file; +} + /* * init_loopfilter - initialize loop filter data */ @@ -186,13 +224,214 @@ void init_loopfilter(void) { /* - * Initialize state variables. Initially, we expect no drift - * file, so set the state to S_NSET. If a drift file is present, - * it will be detected later and the state set to S_FSET. + * Initialize state variables. */ - rstclock(S_NSET, 0, 0); + sys_poll = ntp_minpoll; clock_jitter = LOGTOD(sys_precision); + freq_cnt = (int)clock_minstep; +} + +#ifdef KERNEL_PLL +/* + * ntp_adjtime_error_handler - process errors from ntp_adjtime + */ +static void +ntp_adjtime_error_handler( + const char *caller, /* name of calling function */ + struct timex *ptimex, /* pointer to struct timex */ + int ret, /* return value from ntp_adjtime */ + int saved_errno, /* value of errno when ntp_adjtime returned */ + int pps_call, /* ntp_adjtime call was PPS-related */ + int tai_call, /* ntp_adjtime call was TAI-related */ + int line /* line number of ntp_adjtime call */ + ) +{ + char des[1024] = ""; /* Decoded Error Status */ + + switch (ret) { + case -1: + switch (saved_errno) { + case EFAULT: + msyslog(LOG_ERR, "%s: %s line %d: invalid struct timex pointer: 0x%lx", + caller, file_name(), line, + (long)((void *)ptimex) + ); + break; + case EINVAL: + msyslog(LOG_ERR, "%s: %s line %d: invalid struct timex \"constant\" element value: %ld", + caller, file_name(), line, + (long)(ptimex->constant) + ); + break; + case EPERM: + if (tai_call) { + errno = saved_errno; + msyslog(LOG_ERR, + "%s: ntp_adjtime(TAI) failed: %m", + caller); + } + errno = saved_errno; + msyslog(LOG_ERR, "%s: %s line %d: ntp_adjtime: %m", + caller, file_name(), line + ); + break; + default: + msyslog(LOG_NOTICE, "%s: %s line %d: unhandled errno value %d after failed ntp_adjtime call", + caller, file_name(), line, + saved_errno + ); + break; + } + break; +#ifdef TIME_OK + case TIME_OK: /* 0: synchronized, no leap second warning */ + /* msyslog(LOG_INFO, "kernel reports time is synchronized normally"); */ + break; +#else +# warning TIME_OK is not defined +#endif +#ifdef TIME_INS + case TIME_INS: /* 1: positive leap second warning */ + msyslog(LOG_INFO, "kernel reports leap second insertion scheduled"); + break; +#else +# warning TIME_INS is not defined +#endif +#ifdef TIME_DEL + case TIME_DEL: /* 2: negative leap second warning */ + msyslog(LOG_INFO, "kernel reports leap second deletion scheduled"); + break; +#else +# warning TIME_DEL is not defined +#endif +#ifdef TIME_OOP + case TIME_OOP: /* 3: leap second in progress */ + msyslog(LOG_INFO, "kernel reports leap second in progress"); + break; +#else +# warning TIME_OOP is not defined +#endif +#ifdef TIME_WAIT + case TIME_WAIT: /* 4: leap second has occured */ + msyslog(LOG_INFO, "kernel reports leap second has occurred"); + break; +#else +# warning TIME_WAIT is not defined +#endif +#ifdef TIME_ERROR +#if 0 + +from the reference implementation of ntp_gettime(): + + // Hardware or software error + if ((time_status & (STA_UNSYNC | STA_CLOCKERR)) + + /* + * PPS signal lost when either time or frequency synchronization + * requested + */ + || (time_status & (STA_PPSFREQ | STA_PPSTIME) + && !(time_status & STA_PPSSIGNAL)) + + /* + * PPS jitter exceeded when time synchronization requested + */ + || (time_status & STA_PPSTIME && + time_status & STA_PPSJITTER) + + /* + * PPS wander exceeded or calibration error when frequency + * synchronization requested + */ + || (time_status & STA_PPSFREQ && + time_status & (STA_PPSWANDER | STA_PPSERROR))) + return (TIME_ERROR); + +or, from ntp_adjtime(): + + if ( (time_status & (STA_UNSYNC | STA_CLOCKERR)) + || (time_status & (STA_PPSFREQ | STA_PPSTIME) + && !(time_status & STA_PPSSIGNAL)) + || (time_status & STA_PPSTIME + && time_status & STA_PPSJITTER) + || (time_status & STA_PPSFREQ + && time_status & (STA_PPSWANDER | STA_PPSERROR)) + ) + return (TIME_ERROR); +#endif + + case TIME_ERROR: /* 5: unsynchronized, or loss of synchronization */ + /* error (see status word) */ + + if (ptimex->status & STA_UNSYNC) + snprintf(des, sizeof(des), "%s%sClock Unsynchronized", + des, (*des) ? "; " : ""); + + if (ptimex->status & STA_CLOCKERR) + snprintf(des, sizeof(des), "%s%sClock Error", + des, (*des) ? "; " : ""); + + if (!(ptimex->status & STA_PPSSIGNAL) + && ptimex->status & STA_PPSFREQ) + snprintf(des, sizeof(des), "%s%sPPS Frequency Sync wanted but no PPS", + des, (*des) ? "; " : ""); + + if (!(ptimex->status & STA_PPSSIGNAL) + && ptimex->status & STA_PPSTIME) + snprintf(des, sizeof(des), "%s%sPPS Time Sync wanted but no PPS signal", + des, (*des) ? "; " : ""); + + if ( ptimex->status & STA_PPSTIME + && ptimex->status & STA_PPSJITTER) + snprintf(des, sizeof(des), "%s%sPPS Time Sync wanted but PPS Jitter exceeded", + des, (*des) ? "; " : ""); + + if ( ptimex->status & STA_PPSFREQ + && ptimex->status & STA_PPSWANDER) + snprintf(des, sizeof(des), "%s%sPPS Frequency Sync wanted but PPS Wander exceeded", + des, (*des) ? "; " : ""); + + if ( ptimex->status & STA_PPSFREQ + && ptimex->status & STA_PPSERROR) + snprintf(des, sizeof(des), "%s%sPPS Frequency Sync wanted but Calibration error detected", + des, (*des) ? "; " : ""); + + if (pps_call && !(ptimex->status & STA_PPSSIGNAL)) + report_event(EVNT_KERN, NULL, + "no PPS signal"); + DPRINTF(1, ("kernel loop status %#x (%s)\n", + ptimex->status, des)); + /* + * This code may be returned when ntp_adjtime() has just + * been called for the first time, quite a while after + * startup, when ntpd just starts to discipline the kernel + * time. In this case the occurrence of this message + * can be pretty confusing. + * + * HMS: How about a message when we begin kernel processing: + * Determining kernel clock state... + * so an initial TIME_ERROR message is less confising, + * or skipping the first message (ugh), + * or ??? + * msyslog(LOG_INFO, "kernel reports time synchronization lost"); + */ + msyslog(LOG_INFO, "kernel reports TIME_ERROR: %#x: %s", + ptimex->status, des); + break; +#else +# warning TIME_ERROR is not defined +#endif + default: + msyslog(LOG_NOTICE, "%s: %s line %d: unhandled return value %d from ntp_adjtime() in %s at line %d", + caller, file_name(), line, + ret, + __func__, __LINE__ + ); + break; + } + return; } +#endif /* * local_clock - the NTP logical clock loop filter. @@ -204,7 +443,7 @@ init_loopfilter(void) * 2 clock was stepped * * LOCKCLOCK: The only thing this routine does is set the - * sys_rootdispersion variable equal to the peer dispersion. + * sys_rootdisp variable equal to the peer dispersion. */ int local_clock( @@ -213,39 +452,29 @@ local_clock( ) { int rval; /* return code */ - u_long mu; /* interval since last update (s) */ - double flladj; /* FLL frequency adjustment (ppm) */ - double plladj; /* PLL frequency adjustment (ppm) */ - double clock_frequency; /* clock frequency adjustment (ppm) */ + int osys_poll; /* old system poll */ + int ntp_adj_ret; /* returned by ntp_adjtime */ + double mu; /* interval since last update */ + double clock_frequency; /* clock frequency */ double dtemp, etemp; /* double temps */ -#ifdef OPENSSL - u_int32 *tpt; - int i; - u_int len; - long togo; -#endif /* OPENSSL */ + char tbuf[80]; /* report buffer */ /* * If the loop is opened or the NIST LOCKCLOCK is in use, * monitor and record the offsets anyway in order to determine * the open-loop response and then go home. */ -#ifdef DEBUG - if (debug) - printf( - "local_clock: assocID %d offset %.9f freq %.3f state %d\n", - peer->associd, fp_offset, drift_comp * 1e6, state); -#endif #ifdef LOCKCLOCK - return (0); - -#else /* LOCKCLOCK */ + { +#else if (!ntp_enable) { +#endif /* LOCKCLOCK */ record_loop_stats(fp_offset, drift_comp, clock_jitter, clock_stability, sys_poll); return (0); } +#ifndef LOCKCLOCK /* * If the clock is way off, panic is declared. The clock_panic * defaults to 1000 s; if set to zero, the panic will never @@ -257,33 +486,32 @@ local_clock( */ if (fabs(fp_offset) > clock_panic && clock_panic > 0 && !allow_panic) { - msyslog(LOG_ERR, - "time correction of %.0f seconds exceeds sanity limit (%.0f); set clock manually to the correct UTC time.", + snprintf(tbuf, sizeof(tbuf), + "%+.0f s; set clock manually within %.0f s.", fp_offset, clock_panic); + report_event(EVNT_SYSFAULT, NULL, tbuf); return (-1); } /* - * If simulating ntpdate, set the clock directly, rather than - * using the discipline. The clock_max defines the step - * threshold, above which the clock will be stepped instead of - * slewed. The value defaults to 128 ms, but can be set to even - * unreasonable values. If set to zero, the clock will never be - * stepped. Note that a slew will persist beyond the life of - * this program. - * - * Note that if ntpdate is active, the terminal does not detach, - * so the termination comments print directly to the console. + * This section simulates ntpdate. If the offset exceeds the + * step threshold (128 ms), step the clock to that time and + * exit. Otherwise, slew the clock to that time and exit. Note + * that the slew will persist and eventually complete beyond the + * life of this program. Note that while ntpdate is active, the + * terminal does not detach, so the termination message prints + * directly to the terminal. */ if (mode_ntpdate) { - if (fabs(fp_offset) > clock_max && clock_max > 0) { + if ( ( fp_offset > clock_max_fwd && clock_max_fwd > 0) + || (-fp_offset > clock_max_back && clock_max_back > 0)) { step_systime(fp_offset); - msyslog(LOG_NOTICE, "time reset %+.6f s", - fp_offset); + msyslog(LOG_NOTICE, "ntpd: time set %+.6f s", + fp_offset); printf("ntpd: time set %+.6fs\n", fp_offset); } else { adj_systime(fp_offset); - msyslog(LOG_NOTICE, "time slew %+.6f s", + msyslog(LOG_NOTICE, "ntpd: time slew %+.6f s", fp_offset); printf("ntpd: time slew %+.6fs\n", fp_offset); } @@ -299,12 +527,8 @@ local_clock( * is most effective if the delays are highly assymetric and * clockhopping is avoided and the clock frequency wander is * relatively small. - * - * Note either there is no prefer peer or this update is from - * the prefer peer. */ - if (sys_huffpuff != NULL && (sys_prefer == NULL || sys_prefer == - peer)) { + if (sys_huffpuff != NULL) { if (peer->delay < sys_huffpuff[sys_huffptr]) sys_huffpuff[sys_huffptr] = peer->delay; if (peer->delay < sys_mindly) @@ -323,107 +547,115 @@ local_clock( } /* - * Clock state machine transition function. This is where the - * action is and defines how the system reacts to large phase - * and frequency errors. There are two main regimes: when the - * offset exceeds the step threshold and when it does not. - * However, if the step threshold is set to zero, a step will - * never occur. See the instruction manual for the details how - * these actions interact with the command line options. + * Clock state machine transition function which defines how the + * system reacts to large phase and frequency excursion. There + * are two main regimes: when the offset exceeds the step + * threshold (128 ms) and when it does not. Under certain + * conditions updates are suspended until the stepout theshold + * (900 s) is exceeded. See the documentation on how these + * thresholds interact with commands and command line options. * - * Note the system poll is set to minpoll only if the clock is - * stepped. Note also the kernel is disabled if step is - * disabled or greater than 0.5 s. + * Note the kernel is disabled if step is disabled or greater + * than 0.5 s or in ntpdate mode. */ - clock_frequency = flladj = plladj = 0; - mu = peer->epoch - sys_clocktime; - if (clock_max == 0 || clock_max > 0.5) - kern_enable = 0; + osys_poll = sys_poll; + if (sys_poll < peer->minpoll) + sys_poll = peer->minpoll; + if (sys_poll > peer->maxpoll) + sys_poll = peer->maxpoll; + mu = current_time - clock_epoch; + clock_frequency = drift_comp; rval = 1; - if (fabs(fp_offset) > clock_max && clock_max > 0) { + if ( ( fp_offset > clock_max_fwd && clock_max_fwd > 0) + || (-fp_offset > clock_max_back && clock_max_back > 0) + || force_step_once ) { + if (force_step_once) { + force_step_once = FALSE; /* we want this only once after startup */ + msyslog(LOG_NOTICE, "Doing intital time step" ); + } + switch (state) { /* - * In S_SYNC state we ignore the first outlyer amd - * switch to S_SPIK state. + * In SYNC state we ignore the first outlier and switch + * to SPIK state. */ - case S_SYNC: - state = S_SPIK; + case EVNT_SYNC: + snprintf(tbuf, sizeof(tbuf), "%+.6f s", + fp_offset); + report_event(EVNT_SPIK, NULL, tbuf); + state = EVNT_SPIK; return (0); /* - * In S_FREQ state we ignore outlyers and inlyers. At - * the first outlyer after the stepout threshold, - * compute the apparent frequency correction and step - * the phase. + * In FREQ state we ignore outliers and inlyers. At the + * first outlier after the stepout threshold, compute + * the apparent frequency correction and step the phase. */ - case S_FREQ: + case EVNT_FREQ: if (mu < clock_minstep) return (0); - clock_frequency = (fp_offset - clock_offset) / - mu; + clock_frequency = direct_freq(fp_offset); - /* fall through to S_SPIK */ + /* fall through to EVNT_SPIK */ /* - * In S_SPIK state we ignore succeeding outlyers until + * In SPIK state we ignore succeeding outliers until * either an inlyer is found or the stepout threshold is * exceeded. */ - case S_SPIK: + case EVNT_SPIK: if (mu < clock_minstep) return (0); /* fall through to default */ /* - * We get here by default in S_NSET and S_FSET states - * and from above in S_FREQ or S_SPIK states. + * We get here by default in NSET and FSET states and + * from above in FREQ or SPIK states. * - * In S_NSET state an initial frequency correction is - * not available, usually because the frequency file has - * not yet been written. Since the time is outside the - * step threshold, the clock is stepped. The frequency - * will be set directly following the stepout interval. + * In NSET state an initial frequency correction is not + * available, usually because the frequency file has not + * yet been written. Since the time is outside the step + * threshold, the clock is stepped. The frequency will + * be set directly following the stepout interval. * - * In S_FSET state the initial frequency has been set - * from the frequency file. Since the time is outside - * the step threshold, the clock is stepped immediately, + * In FSET state the initial frequency has been set from + * the frequency file. Since the time is outside the + * step threshold, the clock is stepped immediately, * rather than after the stepout interval. Guys get - * nervous if it takes 17 minutes to set the clock for + * nervous if it takes 15 minutes to set the clock for * the first time. * - * In S_FREQ and S_SPIK states the stepout threshold has + * In FREQ and SPIK states the stepout threshold has * expired and the phase is still above the step * threshold. Note that a single spike greater than the - * step threshold is always suppressed, even at the - * longer poll intervals. - */ + * step threshold is always suppressed, even with a + * long time constant. + */ default: - step_systime(fp_offset); - msyslog(LOG_NOTICE, "time reset %+.6f s", + snprintf(tbuf, sizeof(tbuf), "%+.6f s", fp_offset); + report_event(EVNT_CLOCKRESET, NULL, tbuf); + step_systime(fp_offset); reinit_timer(); tc_counter = 0; - sys_poll = NTP_MINPOLL; - sys_tai = 0; clock_jitter = LOGTOD(sys_precision); rval = 2; - if (state == S_NSET) { - rstclock(S_FREQ, peer->epoch, 0); + if (state == EVNT_NSET) { + rstclock(EVNT_FREQ, 0); return (rval); } break; } - rstclock(S_SYNC, peer->epoch, 0); + rstclock(EVNT_SYNC, 0); } else { - /* * The offset is less than the step threshold. Calculate * the jitter as the exponentially weighted offset * differences. - */ + */ etemp = SQUARE(clock_jitter); dtemp = SQUARE(max(fabs(fp_offset - last_offset), LOGTOD(sys_precision))); @@ -432,105 +664,69 @@ local_clock( switch (state) { /* - * In S_NSET state this is the first update received and + * In NSET state this is the first update received and * the frequency has not been initialized. Adjust the * phase, but do not adjust the frequency until after * the stepout threshold. */ - case S_NSET: - rstclock(S_FREQ, peer->epoch, fp_offset); - break; - - /* - * In S_FSET state this is the first update received and - * the frequency has been initialized. Adjust the phase, - * but do not adjust the frequency until the next - * update. - */ - case S_FSET: - rstclock(S_SYNC, peer->epoch, fp_offset); + case EVNT_NSET: + adj_systime(fp_offset); + rstclock(EVNT_FREQ, fp_offset); break; /* - * In S_FREQ state ignore updates until the stepout - * threshold. After that, correct the phase and - * frequency and switch to S_SYNC state. + * In FREQ state ignore updates until the stepout + * threshold. After that, compute the new frequency, but + * do not adjust the frequency until the holdoff counter + * decrements to zero. */ - case S_FREQ: + case EVNT_FREQ: if (mu < clock_minstep) return (0); - clock_frequency = (fp_offset - clock_offset) / - mu; - rstclock(S_SYNC, peer->epoch, fp_offset); - break; + clock_frequency = direct_freq(fp_offset); + /* fall through */ /* - * We get here by default in S_SYNC and S_SPIK states. - * Here we compute the frequency update due to PLL and - * FLL contributions. + * We get here by default in FSET, SPIK and SYNC states. + * Here compute the frequency update due to PLL and FLL + * contributions. Note, we avoid frequency discipline at + * startup until the initial transient has subsided. */ default: allow_panic = FALSE; - - /* - * The FLL and PLL frequency gain constants - * depend on the poll interval and Allan - * intercept. The PLL is always used, but - * becomes ineffective above the Allan - * intercept. The FLL is not used below one-half - * the Allan intercept. Above that the loop gain - * increases in steps to 1 / CLOCK_AVG. - */ - if (ULOGTOD(sys_poll) > allan_xpt / 2) { - dtemp = CLOCK_FLL - sys_poll; - flladj = (fp_offset - clock_offset) / - (max(mu, allan_xpt) * dtemp); + if (freq_cnt == 0) { + + /* + * The FLL and PLL frequency gain constants + * depend on the time constant and Allan + * intercept. The PLL is always used, but + * becomes ineffective above the Allan intercept + * where the FLL becomes effective. + */ + if (sys_poll >= allan_xpt) + clock_frequency += (fp_offset - + clock_offset) / max(ULOGTOD(sys_poll), + mu) * CLOCK_FLL; + + /* + * The PLL frequency gain (numerator) depends on + * the minimum of the update interval and Allan + * intercept. This reduces the PLL gain when the + * FLL becomes effective. + */ + etemp = min(ULOGTOD(allan_xpt), mu); + dtemp = 4 * CLOCK_PLL * ULOGTOD(sys_poll); + clock_frequency += fp_offset * etemp / (dtemp * + dtemp); } - - /* - * For the PLL the integration interval - * (numerator) is the minimum of the update - * interval and poll interval. This allows - * oversampling, but not undersampling. - */ - etemp = min(mu, (u_long)ULOGTOD(sys_poll)); - dtemp = 4 * CLOCK_PLL * ULOGTOD(sys_poll); - plladj = fp_offset * etemp / (dtemp * dtemp); - rstclock(S_SYNC, peer->epoch, fp_offset); + rstclock(EVNT_SYNC, fp_offset); + if (fabs(fp_offset) < CLOCK_FLOOR) + freq_cnt = 0; break; } } -#ifdef OPENSSL - /* - * Scan the loopsecond table to determine the TAI offset. If - * there is a scheduled leap in future, set the leap warning, - * but only if less than 30 days before the leap. - */ - tpt = (u_int32 *)tai_leap.ptr; - len = ntohl(tai_leap.vallen) / sizeof(u_int32); - if (tpt != NULL) { - for (i = 0; i < len; i++) { - togo = (long)ntohl(tpt[i]) - - (long)peer->rec.l_ui; - if (togo > 0) { - if (togo < CLOCK_JUNE) - leap_next |= LEAP_ADDSECOND; - break; - } - } -#if defined(STA_NANO) && NTP_API == 4 - if (pll_control && kern_enable && sys_tai == 0) { - memset(&ntv, 0, sizeof(ntv)); - ntv.modes = MOD_TAI; - ntv.constant = i + TAI_1972 - 1; - ntp_adjtime(&ntv); - } -#endif /* STA_NANO */ - sys_tai = i + TAI_1972 - 1; - } -#endif /* OPENSSL */ #ifdef KERNEL_PLL /* * This code segment works when clock adjustments are made using @@ -547,7 +743,7 @@ local_clock( * lead to overflow problems. This might occur if some misguided * lad set the step threshold to something ridiculous. */ - if (pll_control && kern_enable) { + if (pll_control && kern_enable && freq_cnt == 0) { /* * We initialize the structure for the ntp_adjtime() @@ -560,13 +756,10 @@ local_clock( * frequency offsets for jitter and stability values and * to update the frequency file. */ - memset(&ntv, 0, sizeof(ntv)); + ZERO(ntv); if (ext_enable) { ntv.modes = MOD_STATUS; } else { - struct tm *tm = NULL; - time_t tstamp; - #ifdef STA_NANO ntv.modes = MOD_BITS | MOD_NANO; #else /* STA_NANO */ @@ -585,67 +778,48 @@ local_clock( dtemp); ntv.constant = sys_poll - 4; #endif /* STA_NANO */ + if (ntv.constant < 0) + ntv.constant = 0; - /* - * The frequency is set directly only if - * clock_frequency is nonzero coming out of FREQ - * state. - */ - if (clock_frequency != 0) { - ntv.modes |= MOD_FREQUENCY; - ntv.freq = (int32)((clock_frequency + - drift_comp) * 65536e6); - } ntv.esterror = (u_int32)(clock_jitter * 1e6); ntv.maxerror = (u_int32)((sys_rootdelay / 2 + - sys_rootdispersion) * 1e6); + sys_rootdisp) * 1e6); ntv.status = STA_PLL; /* - * Set the leap bits in the status word, but - * only on the last day of June or December. - */ - tstamp = peer->rec.l_ui - JAN_1970; - tm = gmtime(&tstamp); - if (tm != NULL) { - if ((tm->tm_mon + 1 == 6 && - tm->tm_mday == 30) || (tm->tm_mon + - 1 == 12 && tm->tm_mday == 31)) { - if (leap_next & LEAP_ADDSECOND) - ntv.status |= STA_INS; - else if (leap_next & - LEAP_DELSECOND) - ntv.status |= STA_DEL; - } - } - - /* - * If the PPS signal is up and enabled, light - * the frequency bit. If the PPS driver is - * working, light the phase bit as well. If not, - * douse the lights, since somebody else may - * have left the switch on. + * Enable/disable the PPS if requested. */ - if (pps_enable && pll_status & STA_PPSSIGNAL) { - ntv.status |= STA_PPSFREQ; - if (pps_stratum < STRATUM_UNSPEC) - ntv.status |= STA_PPSTIME; + if (hardpps_enable) { + ntv.status |= (STA_PPSTIME | STA_PPSFREQ); + if (!(pll_status & STA_PPSTIME)) + sync_status("PPS enabled", + pll_status, + ntv.status); } else { - ntv.status &= ~(STA_PPSFREQ | - STA_PPSTIME); + ntv.status &= ~(STA_PPSTIME | STA_PPSFREQ); + if (pll_status & STA_PPSTIME) + sync_status("PPS disabled", + pll_status, + ntv.status); } + if (sys_leap == LEAP_ADDSECOND) + ntv.status |= STA_INS; + else if (sys_leap == LEAP_DELSECOND) + ntv.status |= STA_DEL; } /* * Pass the stuff to the kernel. If it squeals, turn off - * the pig. In any case, fetch the kernel offset and - * frequency and pretend we did it here. + * the pps. In any case, fetch the kernel offset, + * frequency and jitter. + */ + ntp_adj_ret = ntp_adjtime(&ntv); + /* + * A squeal is a return status < 0, or a state change. */ - if (ntp_adjtime(&ntv) == TIME_ERROR) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "kernel time sync error %04x", ntv.status); - ntv.status &= ~(STA_PPSFREQ | STA_PPSTIME); + if ((0 > ntp_adj_ret) || (ntp_adj_ret != kernel_status)) { + kernel_status = ntp_adj_ret; + ntp_adjtime_error_handler(__func__, &ntv, ntp_adj_ret, errno, hardpps_enable, 0, __LINE__ - 1); } pll_status = ntv.status; #ifdef STA_NANO @@ -653,42 +827,41 @@ local_clock( #else /* STA_NANO */ clock_offset = ntv.offset / 1e6; #endif /* STA_NANO */ - clock_frequency = ntv.freq / 65536e6; - flladj = plladj = 0; + clock_frequency = FREQTOD(ntv.freq); /* * If the kernel PPS is lit, monitor its performance. */ if (ntv.status & STA_PPSTIME) { - pps_control = current_time; #ifdef STA_NANO clock_jitter = ntv.jitter / 1e9; #else /* STA_NANO */ clock_jitter = ntv.jitter / 1e6; #endif /* STA_NANO */ } - } else { -#endif /* KERNEL_PLL */ - + +#if defined(STA_NANO) && NTP_API == 4 /* - * We get here if the kernel discipline is not enabled. - * Adjust the clock frequency as the sum of the directly - * computed frequency (if measured) and the PLL and FLL - * increments. + * If the TAI changes, update the kernel TAI. */ - clock_frequency = drift_comp + clock_frequency + - flladj + plladj; -#ifdef KERNEL_PLL + if (loop_tai != sys_tai) { + loop_tai = sys_tai; + ntv.modes = MOD_TAI; + ntv.constant = sys_tai; + if ((ntp_adj_ret = ntp_adjtime(&ntv)) != 0) { + ntp_adjtime_error_handler(__func__, &ntv, ntp_adj_ret, errno, 0, 1, __LINE__ - 1); + } + } +#endif /* STA_NANO */ } #endif /* KERNEL_PLL */ /* * Clamp the frequency within the tolerance range and calculate - * the frequency change since the last update. + * the frequency difference since the last update. */ if (fabs(clock_frequency) > NTP_MAXFREQ) - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, + msyslog(LOG_NOTICE, "frequency error %.0f PPM exceeds tolerance %.0f PPM", clock_frequency * 1e6, NTP_MAXFREQ * 1e6); dtemp = SQUARE(clock_frequency - drift_comp); @@ -700,20 +873,24 @@ local_clock( drift_comp = clock_frequency; /* - * Calculate the wander as the exponentially weighted frequency - * differences. + * Calculate the wander as the exponentially weighted RMS + * frequency differences. Record the change for the frequency + * file update. */ etemp = SQUARE(clock_stability); clock_stability = SQRT(etemp + (dtemp - etemp) / CLOCK_AVG); /* - * Here we adjust the poll interval by comparing the current + * Here we adjust the time constant by comparing the current * offset with the clock jitter. If the offset is less than the * clock jitter times a constant, then the averaging interval is * increased, otherwise it is decreased. A bit of hysteresis - * helps calm the dance. Works best using burst mode. + * helps calm the dance. Works best using burst mode. Don't + * fiddle with the poll during the startup clamp period. */ - if (fabs(clock_offset) < CLOCK_PGATE * clock_jitter) { + if (freq_cnt > 0) { + tc_counter = 0; + } else if (fabs(clock_offset) < CLOCK_PGATE * clock_jitter) { tc_counter += sys_poll; if (tc_counter > CLOCK_LIMIT) { tc_counter = CLOCK_LIMIT; @@ -733,6 +910,12 @@ local_clock( } } + /* + * If the time constant has changed, update the poll variables. + */ + if (osys_poll != sys_poll) + poll_update(peer, sys_poll); + /* * Yibbidy, yibbbidy, yibbidy; that'h all folks. */ @@ -741,9 +924,9 @@ local_clock( #ifdef DEBUG if (debug) printf( - "local_clock: mu %lu jitr %.6f freq %.3f stab %.6f poll %d count %d\n", - mu, clock_jitter, drift_comp * 1e6, - clock_stability * 1e6, sys_poll, tc_counter); + "local_clock: offset %.9f jit %.9f freq %.3f stab %.3f poll %d\n", + clock_offset, clock_jitter, drift_comp * 1e6, + clock_stability * 1e6, sys_poll); #endif /* DEBUG */ return (rval); #endif /* LOCKCLOCK */ @@ -754,82 +937,267 @@ local_clock( * adj_host_clock - Called once every second to update the local clock. * * LOCKCLOCK: The only thing this routine does is increment the - * sys_rootdispersion variable. + * sys_rootdisp variable. */ void adj_host_clock( void ) { - double adjustment; + double offset_adj; + double freq_adj; /* * Update the dispersion since the last update. In contrast to * NTPv3, NTPv4 does not declare unsynchronized after one day, * since the dispersion check serves this function. Also, * since the poll interval can exceed one day, the old test - * would be counterproductive. Note we do this even with - * external clocks, since the clock driver will recompute the - * maximum error and the local clock driver will pick it up and - * pass to the common refclock routines. Very elegant. + * would be counterproductive. During the startup clamp period, the + * time constant is clamped at 2. */ - sys_rootdispersion += clock_phi; - + sys_rootdisp += clock_phi; #ifndef LOCKCLOCK + if (!ntp_enable || mode_ntpdate) + return; /* - * If clock discipline is disabled or if the kernel is enabled, - * get out of Dodge quick. + * Determine the phase adjustment. The gain factor (denominator) + * increases with poll interval, so is dominated by the FLL + * above the Allan intercept. Note the reduced time constant at + * startup. */ - if (!ntp_enable || mode_ntpdate || (pll_control && - kern_enable)) - return; + if (state != EVNT_SYNC) { + offset_adj = 0.; + } else if (freq_cnt > 0) { + offset_adj = clock_offset / (CLOCK_PLL * ULOGTOD(1)); + freq_cnt--; +#ifdef KERNEL_PLL + } else if (pll_control && kern_enable) { + offset_adj = 0.; +#endif /* KERNEL_PLL */ + } else { + offset_adj = clock_offset / (CLOCK_PLL * ULOGTOD(sys_poll)); + } /* - * Declare PPS kernel unsync if the pps signal has not been - * heard for a few minutes. + * If the kernel discipline is enabled the frequency correction + * drift_comp has already been engaged via ntp_adjtime() in + * set_freq(). Otherwise it is a component of the adj_systime() + * offset. */ - if (pps_control && current_time - pps_control > PPS_MAXAGE) { - if (pps_control) - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, "pps sync disabled"); - pps_control = 0; - } +#ifdef KERNEL_PLL + if (pll_control && kern_enable) + freq_adj = 0.; + else +#endif /* KERNEL_PLL */ + freq_adj = drift_comp; + /* Bound absolute value of total adjustment to NTP_MAXFREQ. */ + if (offset_adj + freq_adj > NTP_MAXFREQ) + offset_adj = NTP_MAXFREQ - freq_adj; + else if (offset_adj + freq_adj < -NTP_MAXFREQ) + offset_adj = -NTP_MAXFREQ - freq_adj; + + clock_offset -= offset_adj; /* - * Implement the phase and frequency adjustments. The gain - * factor (denominator) is not allowed to increase beyond the - * Allan intercept. It doesn't make sense to average phase noise - * beyond this point and it helps to damp residual offset at the - * longer poll intervals. + * Windows port adj_systime() must be called each second, + * even if the argument is zero, to ease emulation of + * adjtime() using Windows' slew API which controls the rate + * but does not automatically stop slewing when an offset + * has decayed to zero. */ - adjustment = clock_offset / (CLOCK_PLL * min(ULOGTOD(sys_poll), - allan_xpt)); - clock_offset -= adjustment; - adj_systime(adjustment + drift_comp); + adj_systime(offset_adj + freq_adj); #endif /* LOCKCLOCK */ } /* - * Clock state machine. Enter new state and set state variables. Note we - * use the time of the last clock filter sample, which may be earlier - * than the current time. + * Clock state machine. Enter new state and set state variables. */ static void rstclock( int trans, /* new state */ - u_long update, /* new update time */ double offset /* new offset */ ) { #ifdef DEBUG - if (debug) - printf("local_clock: time %lu offset %.6f freq %.3f state %d\n", - update, offset, drift_comp * 1e6, trans); + if (debug > 1) + printf("local_clock: mu %lu state %d poll %d count %d\n", + current_time - clock_epoch, trans, sys_poll, + tc_counter); #endif + if (trans != state && trans != EVNT_FSET) + report_event(trans, NULL, NULL); state = trans; - sys_clocktime = update; last_offset = clock_offset = offset; + clock_epoch = current_time; +} + + +/* + * calc_freq - calculate frequency directly + * + * This is very carefully done. When the offset is first computed at the + * first update, a residual frequency component results. Subsequently, + * updates are suppresed until the end of the measurement interval while + * the offset is amortized. At the end of the interval the frequency is + * calculated from the current offset, residual offset, length of the + * interval and residual frequency component. At the same time the + * frequenchy file is armed for update at the next hourly stats. + */ +static double +direct_freq( + double fp_offset + ) +{ + set_freq(fp_offset / (current_time - clock_epoch)); + + return drift_comp; +} + + +/* + * set_freq - set clock frequency correction + * + * Used to step the frequency correction at startup, possibly again once + * the frequency is measured (that is, transitioning from EVNT_NSET to + * EVNT_FSET), and finally to switch between daemon and kernel loop + * discipline at runtime. + * + * When the kernel loop discipline is available but the daemon loop is + * in use, the kernel frequency correction is disabled (set to 0) to + * ensure drift_comp is applied by only one of the loops. + */ +static void +set_freq( + double freq /* frequency update */ + ) +{ + const char * loop_desc; + int ntp_adj_ret; + + drift_comp = freq; + loop_desc = "ntpd"; +#ifdef KERNEL_PLL + if (pll_control) { + ZERO(ntv); + ntv.modes = MOD_FREQUENCY; + if (kern_enable) { + loop_desc = "kernel"; + ntv.freq = DTOFREQ(drift_comp); + } + if ((ntp_adj_ret = ntp_adjtime(&ntv)) != 0) { + ntp_adjtime_error_handler(__func__, &ntv, ntp_adj_ret, errno, 0, 0, __LINE__ - 1); + } + } +#endif /* KERNEL_PLL */ + mprintf_event(EVNT_FSET, NULL, "%s %.3f PPM", loop_desc, + drift_comp * 1e6); +} + + +#ifdef KERNEL_PLL +static void +start_kern_loop(void) +{ + static int atexit_done; + int ntp_adj_ret; + + pll_control = TRUE; + ZERO(ntv); + ntv.modes = MOD_BITS; + ntv.status = STA_PLL; + ntv.maxerror = MAXDISPERSE; + ntv.esterror = MAXDISPERSE; + ntv.constant = sys_poll; /* why is it that here constant is unconditionally set to sys_poll, whereas elsewhere is is modified depending on nanosecond vs. microsecond kernel? */ +#ifdef SIGSYS + /* + * Use sigsetjmp() to save state and then call ntp_adjtime(); if + * it fails, then pll_trap() will set pll_control FALSE before + * returning control using siglogjmp(). + */ + newsigsys.sa_handler = pll_trap; + newsigsys.sa_flags = 0; + if (sigaction(SIGSYS, &newsigsys, &sigsys)) { + msyslog(LOG_ERR, "sigaction() trap SIGSYS: %m"); + pll_control = FALSE; + } else { + if (sigsetjmp(env, 1) == 0) { + if ((ntp_adj_ret = ntp_adjtime(&ntv)) != 0) { + ntp_adjtime_error_handler(__func__, &ntv, ntp_adj_ret, errno, 0, 0, __LINE__ - 1); + } + } + if (sigaction(SIGSYS, &sigsys, NULL)) { + msyslog(LOG_ERR, + "sigaction() restore SIGSYS: %m"); + pll_control = FALSE; + } + } +#else /* SIGSYS */ + if ((ntp_adj_ret = ntp_adjtime(&ntv)) != 0) { + ntp_adjtime_error_handler(__func__, &ntv, ntp_adj_ret, errno, 0, 0, __LINE__ - 1); + } +#endif /* SIGSYS */ + + /* + * Save the result status and light up an external clock + * if available. + */ + pll_status = ntv.status; + if (pll_control) { + if (!atexit_done) { + atexit_done = TRUE; + atexit(&stop_kern_loop); + } +#ifdef STA_NANO + if (pll_status & STA_CLK) + ext_enable = TRUE; +#endif /* STA_NANO */ + report_event(EVNT_KERN, NULL, + "kernel time sync enabled"); + } +} +#endif /* KERNEL_PLL */ + + +#ifdef KERNEL_PLL +static void +stop_kern_loop(void) +{ + if (pll_control && kern_enable) + report_event(EVNT_KERN, NULL, + "kernel time sync disabled"); +} +#endif /* KERNEL_PLL */ + + +/* + * select_loop() - choose kernel or daemon loop discipline. + */ +void +select_loop( + int use_kern_loop + ) +{ + if (kern_enable == use_kern_loop) + return; +#ifdef KERNEL_PLL + if (pll_control && !use_kern_loop) + stop_kern_loop(); +#endif + kern_enable = use_kern_loop; +#ifdef KERNEL_PLL + if (pll_control && use_kern_loop) + start_kern_loop(); +#endif + /* + * If this loop selection change occurs after initial startup, + * call set_freq() to switch the frequency compensation to or + * from the kernel loop. + */ +#ifdef KERNEL_PLL + if (pll_control && loop_started) + set_freq(drift_comp); +#endif } @@ -837,7 +1205,7 @@ rstclock( * huff-n'-puff filter */ void -huffpuff() +huffpuff(void) { int i; @@ -861,173 +1229,144 @@ huffpuff() */ void loop_config( - int item, - double freq + int item, + double freq ) { - int i; + int i; + double ftemp; +#ifdef DEBUG + if (debug > 1) + printf("loop_config: item %d freq %f\n", item, freq); +#endif switch (item) { + /* + * We first assume the kernel supports the ntp_adjtime() + * syscall. If that syscall works, initialize the kernel time + * variables. Otherwise, continue leaving no harm behind. + */ case LOOP_DRIFTINIT: - #ifndef LOCKCLOCK #ifdef KERNEL_PLL - /* - * Assume the kernel supports the ntp_adjtime() syscall. - * If that syscall works, initialize the kernel time - * variables. Otherwise, continue leaving no harm - * behind. While at it, ask to set nanosecond mode. If - * the kernel agrees, rejoice; othewise, it does only - * microseconds. - */ if (mode_ntpdate) break; - pll_control = 1; - memset(&ntv, 0, sizeof(ntv)); -#ifdef STA_NANO - ntv.modes = MOD_BITS | MOD_NANO; -#else /* STA_NANO */ - ntv.modes = MOD_BITS; -#endif /* STA_NANO */ - ntv.maxerror = MAXDISPERSE; - ntv.esterror = MAXDISPERSE; - ntv.status = STA_UNSYNC; -#ifdef SIGSYS - /* - * Use sigsetjmp() to save state and then call - * ntp_adjtime(); if it fails, then siglongjmp() is used - * to return control - */ - newsigsys.sa_handler = pll_trap; - newsigsys.sa_flags = 0; - if (sigaction(SIGSYS, &newsigsys, &sigsys)) { - msyslog(LOG_ERR, - "sigaction() fails to save SIGSYS trap: %m"); - pll_control = 0; - } - if (sigsetjmp(env, 1) == 0) - ntp_adjtime(&ntv); - if ((sigaction(SIGSYS, &sigsys, - (struct sigaction *)NULL))) { - msyslog(LOG_ERR, - "sigaction() fails to restore SIGSYS trap: %m"); - pll_control = 0; - } -#else /* SIGSYS */ - ntp_adjtime(&ntv); -#endif /* SIGSYS */ - - /* - * Save the result status and light up an external clock - * if available. - */ - pll_status = ntv.status; - if (pll_control) { -#ifdef STA_NANO - if (pll_status & STA_CLK) - ext_enable = 1; -#endif /* STA_NANO */ - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_INFO, - "kernel time sync status %04x", - pll_status); - } + start_kern_loop(); #endif /* KERNEL_PLL */ -#endif /* LOCKCLOCK */ - break; - case LOOP_DRIFTCOMP: - -#ifndef LOCKCLOCK /* - * If the frequency value is reasonable, set the initial - * frequency to the given value and the state to S_FSET. - * Otherwise, the drift file may be missing or broken, - * so set the frequency to zero. This erases past - * history should somebody break something. + * Initialize frequency if given; otherwise, begin frequency + * calibration phase. */ - if (freq <= NTP_MAXFREQ && freq >= -NTP_MAXFREQ) { - drift_comp = freq; - rstclock(S_FSET, 0, 0); - } else { - drift_comp = 0; - } - -#ifdef KERNEL_PLL - /* - * Sanity check. If the kernel is available, load the - * frequency and light up the loop. Make sure the offset - * is zero to cancel any previous nonsense. If you don't - * want this initialization, remove the ntp.drift file. - */ - if (pll_control && kern_enable) { - memset((char *)&ntv, 0, sizeof(ntv)); - ntv.modes = MOD_OFFSET | MOD_FREQUENCY; - ntv.freq = (int32)(drift_comp * 65536e6); - ntp_adjtime(&ntv); - } -#endif /* KERNEL_PLL */ + ftemp = init_drift_comp / 1e6; + if (ftemp > NTP_MAXFREQ) + ftemp = NTP_MAXFREQ; + else if (ftemp < -NTP_MAXFREQ) + ftemp = -NTP_MAXFREQ; + set_freq(ftemp); + if (freq_set) + rstclock(EVNT_FSET, 0); + else + rstclock(EVNT_NSET, 0); + loop_started = TRUE; #endif /* LOCKCLOCK */ break; case LOOP_KERN_CLEAR: +#if 0 /* XXX: needs more review, and how can we get here? */ #ifndef LOCKCLOCK -#ifdef KERNEL_PLL - /* Completely turn off the kernel time adjustments. */ - if (pll_control) { +# ifdef KERNEL_PLL + if (pll_control && kern_enable) { memset((char *)&ntv, 0, sizeof(ntv)); - ntv.modes = MOD_BITS | MOD_OFFSET | MOD_FREQUENCY; + ntv.modes = MOD_STATUS; ntv.status = STA_UNSYNC; ntp_adjtime(&ntv); - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_INFO, - "kernel time sync disabled %04x", - ntv.status); + sync_status("kernel time sync disabled", + pll_status, + ntv.status); } -#endif /* KERNEL_PLL */ +# endif /* KERNEL_PLL */ #endif /* LOCKCLOCK */ +#endif break; /* - * Special tinker variables for Ulrich Windl. Very dangerous. + * Tinker command variables for Ulrich Windl. Very dangerous. */ - case LOOP_MAX: /* step threshold */ - clock_max = freq; + case LOOP_ALLAN: /* Allan intercept (log2) (allan) */ + allan_xpt = (u_char)freq; break; - case LOOP_PANIC: /* panic threshold */ - clock_panic = freq; + case LOOP_CODEC: /* audio codec frequency (codec) */ + clock_codec = freq / 1e6; break; - case LOOP_PHI: /* dispersion rate */ - clock_phi = freq; + case LOOP_PHI: /* dispersion threshold (dispersion) */ + clock_phi = freq / 1e6; break; - case LOOP_MINSTEP: /* watchdog bark */ - clock_minstep = freq; + case LOOP_FREQ: /* initial frequency (freq) */ + init_drift_comp = freq; + freq_set++; break; - case LOOP_ALLAN: /* Allan intercept */ - allan_xpt = freq; - break; - - case LOOP_HUFFPUFF: /* huff-n'-puff filter length */ + case LOOP_HUFFPUFF: /* huff-n'-puff length (huffpuff) */ if (freq < HUFFPUFF) freq = HUFFPUFF; sys_hufflen = (int)(freq / HUFFPUFF); - sys_huffpuff = (double *)emalloc(sizeof(double) * + sys_huffpuff = emalloc(sizeof(sys_huffpuff[0]) * sys_hufflen); for (i = 0; i < sys_hufflen; i++) sys_huffpuff[i] = 1e9; sys_mindly = 1e9; break; - case LOOP_FREQ: /* initial frequency */ - drift_comp = freq / 1e6; - rstclock(S_FSET, 0, 0); + case LOOP_PANIC: /* panic threshold (panic) */ + clock_panic = freq; + break; + + case LOOP_MAX: /* step threshold (step) */ + clock_max_fwd = clock_max_back = freq; + if (freq == 0 || freq > 0.5) + select_loop(FALSE); + break; + + case LOOP_MAX_BACK: /* step threshold (step) */ + clock_max_back = freq; + /* + * Leave using the kernel discipline code unless both + * limits are massive. This assumes the reason to stop + * using it is that it's pointless, not that it goes wrong. + */ + if ( (clock_max_back == 0 || clock_max_back > 0.5) + || (clock_max_fwd == 0 || clock_max_fwd > 0.5)) + select_loop(FALSE); + break; + + case LOOP_MAX_FWD: /* step threshold (step) */ + clock_max_fwd = freq; + if ( (clock_max_back == 0 || clock_max_back > 0.5) + || (clock_max_fwd == 0 || clock_max_fwd > 0.5)) + select_loop(FALSE); + break; + + case LOOP_MINSTEP: /* stepout threshold (stepout) */ + if (freq < CLOCK_MINSTEP) + clock_minstep = CLOCK_MINSTEP; + else + clock_minstep = freq; + break; + + case LOOP_TICK: /* tick increment (tick) */ + set_sys_tick_precision(freq); break; + + case LOOP_LEAP: /* not used, fall through */ + default: + msyslog(LOG_NOTICE, + "loop_config: unsupported option %d", item); } } @@ -1046,7 +1385,7 @@ pll_trap( int arg ) { - pll_control = 0; + pll_control = FALSE; siglongjmp(env, 1); } #endif /* KERNEL_PLL && SIGSYS */ diff --git a/contrib/ntp/ntpd/ntp_monitor.c b/contrib/ntp/ntpd/ntp_monitor.c index 753fa767c..a07a1aaef 100644 --- a/contrib/ntp/ntpd/ntp_monitor.c +++ b/contrib/ntp/ntpd/ntp_monitor.c @@ -8,6 +8,7 @@ #include "ntpd.h" #include "ntp_io.h" #include "ntp_if.h" +#include "ntp_lists.h" #include "ntp_stdlib.h" #include @@ -18,17 +19,14 @@ #endif /* - * I'm still not sure I like what I've done here. It certainly consumes - * memory like it is going out of style, and also may not be as low - * overhead as I'd imagined. + * Record statistics based on source address, mode and version. The + * receive procedure calls us with the incoming rbufp before it does + * anything else. While at it, implement rate controls for inbound + * traffic. * - * Anyway, we record statistics based on source address, mode and - * version (for now, anyway. Check the code). The receive procedure - * calls us with the incoming rbufp before it does anything else. - * - * Each entry is doubly linked into two lists, a hash table and a - * most-recently-used list. When a packet arrives it is looked up in - * the hash table. If found, the statistics are updated and the entry + * Each entry is doubly linked into two lists, a hash table and a most- + * recently-used (MRU) list. When a packet arrives it is looked up in + * the hash table. If found, the statistics are updated and the entry * relinked at the head of the MRU list. If not found, a new entry is * allocated, initialized and linked into both the hash table and at the * head of the MRU list. @@ -39,55 +37,70 @@ * tail for the MRU list, unlinking from the hash table, and * reinitializing. * - * trimmed back memory consumption ... jdg 8/94 - */ -/* - * Limits on the number of structures allocated. This limit is picked - * with the illicit knowlege that we can only return somewhat less - * than 8K bytes in a mode 7 response packet, and that each structure - * will require about 20 bytes of space in the response. - * - * ... I don't believe the above is true anymore ... jdg + * INC_MONLIST is the default allocation granularity in entries. + * INIT_MONLIST is the default initial allocation in entries. */ -#ifndef MAXMONMEM -#define MAXMONMEM 600 /* we allocate up to 600 structures */ +#ifdef MONMEMINC /* old name */ +# define INC_MONLIST MONMEMINC +#elif !defined(INC_MONLIST) +# define INC_MONLIST (4 * 1024 / sizeof(mon_entry)) #endif -#ifndef MONMEMINC -#define MONMEMINC 40 /* allocate them 40 at a time */ +#ifndef INIT_MONLIST +# define INIT_MONLIST (4 * 1024 / sizeof(mon_entry)) +#endif +#ifndef MRU_MAXDEPTH_DEF +# define MRU_MAXDEPTH_DEF (1024 * 1024 / sizeof(mon_entry)) #endif /* * Hashing stuff */ -#define MON_HASH_SIZE 128 -#define MON_HASH_MASK (MON_HASH_SIZE-1) -#define MON_HASH(addr) sock_hash(addr) +u_char mon_hash_bits; /* - * Pointers to the hash table, the MRU list and the count table. Memory - * for the hash and count tables is only allocated if monitoring is - * turned on. + * Pointers to the hash table and the MRU list. Memory for the hash + * table is allocated only if monitoring is enabled. */ -static struct mon_data *mon_hash[MON_HASH_SIZE]; /* list ptrs */ -struct mon_data mon_mru_list; +mon_entry ** mon_hash; /* MRU hash table */ +mon_entry mon_mru_list; /* mru listhead */ /* - * List of free structures structures, and counters of free and total - * structures. The free structures are linked with the hash_next field. + * List of free structures structures, and counters of in-use and total + * structures. The free structures are linked with the hash_next field. */ -static struct mon_data *mon_free; /* free list or null if none */ -static int mon_total_mem; /* total structures allocated */ -static int mon_mem_increments; /* times called malloc() */ +static mon_entry *mon_free; /* free list or null if none */ + u_int mru_alloc; /* mru list + free list count */ + u_int mru_entries; /* mru list count */ + u_int mru_peakentries; /* highest mru_entries seen */ + u_int mru_initalloc = INIT_MONLIST;/* entries to preallocate */ + u_int mru_incalloc = INC_MONLIST;/* allocation batch factor */ +static u_int mon_mem_increments; /* times called malloc() */ + +/* + * Parameters of the RES_LIMITED restriction option. We define headway + * as the idle time between packets. A packet is discarded if the + * headway is less than the minimum, as well as if the average headway + * is less than eight times the increment. + */ +int ntp_minpkt = NTP_MINPKT; /* minimum (log 2 s) */ +u_char ntp_minpoll = NTP_MINPOLL; /* increment (log 2 s) */ /* * Initialization state. We may be monitoring, we may not. If * we aren't, we may not even have allocated any memory yet. */ -int mon_enabled; /* enable switch */ -u_long mon_age = 3000; /* preemption limit */ -static int mon_have_memory; -static void mon_getmoremem P((void)); -static void remove_from_hash P((struct mon_data *)); + u_int mon_enabled; /* enable switch */ + u_int mru_mindepth = 600; /* preempt above this */ + int mru_maxage = 64; /* for entries older than */ + u_int mru_maxdepth = /* MRU count hard limit */ + MRU_MAXDEPTH_DEF; + int mon_age = 3000; /* preemption limit */ + +static void mon_getmoremem(void); +static void remove_from_hash(mon_entry *); +static inline void mon_free_entry(mon_entry *); +static inline void mon_reclaim_entry(mon_entry *); + /* * init_mon - initialize monitoring global data @@ -97,16 +110,86 @@ init_mon(void) { /* * Don't do much of anything here. We don't allocate memory - * until someone explicitly starts us. + * until mon_start(). */ mon_enabled = MON_OFF; - mon_have_memory = 0; + INIT_DLIST(mon_mru_list, mru); +} + + +/* + * remove_from_hash - removes an entry from the address hash table and + * decrements mru_entries. + */ +static void +remove_from_hash( + mon_entry *mon + ) +{ + u_int hash; + mon_entry *punlinked; + + mru_entries--; + hash = MON_HASH(&mon->rmtadr); + UNLINK_SLIST(punlinked, mon_hash[hash], mon, hash_next, + mon_entry); + ENSURE(punlinked == mon); +} + + +static inline void +mon_free_entry( + mon_entry *m + ) +{ + ZERO(*m); + LINK_SLIST(mon_free, m, hash_next); +} + - mon_total_mem = 0; - mon_mem_increments = 0; - mon_free = NULL; - memset(&mon_hash[0], 0, sizeof mon_hash); - memset(&mon_mru_list, 0, sizeof mon_mru_list); +/* + * mon_reclaim_entry - Remove an entry from the MRU list and from the + * hash array, then zero-initialize it. Indirectly + * decrements mru_entries. + + * The entry is prepared to be reused. Before return, in + * remove_from_hash(), mru_entries is decremented. It is the caller's + * responsibility to increment it again. + */ +static inline void +mon_reclaim_entry( + mon_entry *m + ) +{ + DEBUG_INSIST(NULL != m); + + UNLINK_DLIST(m, mru); + remove_from_hash(m); + ZERO(*m); +} + + +/* + * mon_getmoremem - get more memory and put it on the free list + */ +static void +mon_getmoremem(void) +{ + mon_entry *chunk; + u_int entries; + + entries = (0 == mon_mem_increments) + ? mru_initalloc + : mru_incalloc; + + if (entries) { + chunk = eallocarray(entries, sizeof(*chunk)); + mru_alloc += entries; + for (chunk += entries; entries; entries--) + mon_free_entry(--chunk); + + mon_mem_increments++; + } } @@ -118,24 +201,31 @@ mon_start( int mode ) { + size_t octets; + u_int min_hash_slots; - if (mon_enabled != MON_OFF) { + if (MON_OFF == mode) /* MON_OFF is 0 */ + return; + if (mon_enabled) { mon_enabled |= mode; return; } - if (mode == MON_OFF) - return; - - if (!mon_have_memory) { - mon_total_mem = 0; - mon_mem_increments = 0; - mon_free = NULL; + if (0 == mon_mem_increments) mon_getmoremem(); - mon_have_memory = 1; - } + /* + * Select the MRU hash table size to limit the average count + * per bucket at capacity (mru_maxdepth) to 8, if possible + * given our hash is limited to 16 bits. + */ + min_hash_slots = (mru_maxdepth / 8) + 1; + mon_hash_bits = 0; + while (min_hash_slots >>= 1) + mon_hash_bits++; + mon_hash_bits = max(4, mon_hash_bits); + mon_hash_bits = min(16, mon_hash_bits); + octets = sizeof(*mon_hash) * MON_HASH_SIZE; + mon_hash = erealloc_zero(mon_hash, octets, 0); - mon_mru_list.mru_next = &mon_mru_list; - mon_mru_list.mru_prev = &mon_mru_list; mon_enabled = mode; } @@ -148,211 +238,263 @@ mon_stop( int mode ) { - register struct mon_data *md, *md_next; - register int i; + mon_entry *mon; - if (mon_enabled == MON_OFF) - return; + if (MON_OFF == mon_enabled) + return; if ((mon_enabled & mode) == 0 || mode == MON_OFF) - return; + return; mon_enabled &= ~mode; if (mon_enabled != MON_OFF) - return; + return; /* - * Put everything back on the free list + * Move everything on the MRU list to the free list quickly, + * without bothering to remove each from either the MRU list or + * the hash table. */ - for (i = 0; i < MON_HASH_SIZE; i++) { - md = mon_hash[i]; /* get next list */ - mon_hash[i] = NULL; /* zero the list head */ - while (md != NULL) { - md_next = md->hash_next; - md->hash_next = mon_free; - mon_free = md; - md = md_next; - } - } - - mon_mru_list.mru_next = &mon_mru_list; - mon_mru_list.mru_prev = &mon_mru_list; + ITER_DLIST_BEGIN(mon_mru_list, mon, mru, mon_entry) + mon_free_entry(mon); + ITER_DLIST_END() + + /* empty the MRU list and hash table. */ + mru_entries = 0; + INIT_DLIST(mon_mru_list, mru); + zero_mem(mon_hash, sizeof(*mon_hash) * MON_HASH_SIZE); } + +/* + * mon_clearinterface -- remove mru entries referring to a local address + * which is going away. + */ void -ntp_monclearinterface(struct interface *interface) +mon_clearinterface( + endpt *lcladr + ) { - struct mon_data *md; - - for (md = mon_mru_list.mru_next; md != &mon_mru_list; - md = md->mru_next) { - if (md->interface == interface) - { - /* dequeue from mru list and put to free list */ - md->mru_prev->mru_next = md->mru_next; - md->mru_next->mru_prev = md->mru_prev; - remove_from_hash(md); - md->hash_next = mon_free; - mon_free = md; - } - } + mon_entry *mon; + + /* iterate mon over mon_mru_list */ + ITER_DLIST_BEGIN(mon_mru_list, mon, mru, mon_entry) + if (mon->lcladr == lcladr) { + /* remove from mru list */ + UNLINK_DLIST(mon, mru); + /* remove from hash list, adjust mru_entries */ + remove_from_hash(mon); + /* put on free list */ + mon_free_entry(mon); + } + ITER_DLIST_END() } + /* * ntp_monitor - record stats about this packet * - * Returns 1 if the packet is at the head of the list, 0 otherwise. + * Returns supplied restriction flags, with RES_LIMITED and RES_KOD + * cleared unless the packet should not be responded to normally + * (RES_LIMITED) and possibly should trigger a KoD response (RES_KOD). + * The returned flags are saved in the MRU entry, so that it reflects + * whether the last packet from that source triggered rate limiting, + * and if so, possible KoD response. This implies you can not tell + * whether a given address is eligible for rate limiting/KoD from the + * monlist restrict bits, only whether or not the last packet triggered + * such responses. ntpdc -c reslist lets you see whether RES_LIMITED + * or RES_KOD is lit for a particular address before ntp_monitor()'s + * typical dousing. */ -int +u_short ntp_monitor( - struct recvbuf *rbufp + struct recvbuf *rbufp, + u_short flags ) { - register struct pkt *pkt; - register struct mon_data *md; - struct sockaddr_storage addr; - register int hash; - register int mode; + l_fp interval_fp; + struct pkt * pkt; + mon_entry * mon; + mon_entry * oldest; + int oldest_age; + u_int hash; + u_short restrict_mask; + u_char mode; + u_char version; + int interval; + int head; /* headway increment */ + int leak; /* new headway */ + int limit; /* average threshold */ + + REQUIRE(rbufp != NULL); if (mon_enabled == MON_OFF) - return 0; + return ~(RES_LIMITED | RES_KOD) & flags; pkt = &rbufp->recv_pkt; - memset(&addr, 0, sizeof(addr)); - memcpy(&addr, &(rbufp->recv_srcadr), sizeof(addr)); - hash = MON_HASH(&addr); + hash = MON_HASH(&rbufp->recv_srcadr); mode = PKT_MODE(pkt->li_vn_mode); - md = mon_hash[hash]; - while (md != NULL) { + version = PKT_VERSION(pkt->li_vn_mode); + mon = mon_hash[hash]; + + /* + * We keep track of all traffic for a given IP in one entry, + * otherwise cron'ed ntpdate or similar evades RES_LIMITED. + */ + + for (; mon != NULL; mon = mon->hash_next) + if (SOCK_EQ(&mon->rmtadr, &rbufp->recv_srcadr)) + break; + + if (mon != NULL) { + interval_fp = rbufp->recv_time; + L_SUB(&interval_fp, &mon->last); + /* add one-half second to round up */ + L_ADDUF(&interval_fp, 0x80000000); + interval = interval_fp.l_i; + mon->last = rbufp->recv_time; + NSRCPORT(&mon->rmtadr) = NSRCPORT(&rbufp->recv_srcadr); + mon->count++; + restrict_mask = flags; + mon->vn_mode = VN_MODE(version, mode); + + /* Shuffle to the head of the MRU list. */ + UNLINK_DLIST(mon, mru); + LINK_DLIST(mon_mru_list, mon, mru); /* - * Match address only to conserve MRU size. + * At this point the most recent arrival is first in the + * MRU list. Decrease the counter by the headway, but + * not less than zero. */ - if (SOCKCMP(&md->rmtadr, &addr)) { - md->drop_count = current_time - md->lasttime; - md->lasttime = current_time; - md->count++; - md->rmtport = NSRCPORT(&rbufp->recv_srcadr); - md->mode = (u_char) mode; - md->version = PKT_VERSION(pkt->li_vn_mode); - - /* - * Shuffle to the head of the MRU list. - */ - md->mru_next->mru_prev = md->mru_prev; - md->mru_prev->mru_next = md->mru_next; - md->mru_next = mon_mru_list.mru_next; - md->mru_prev = &mon_mru_list; - mon_mru_list.mru_next->mru_prev = md; - mon_mru_list.mru_next = md; - return 1; - } - md = md->hash_next; + mon->leak -= interval; + mon->leak = max(0, mon->leak); + head = 1 << ntp_minpoll; + leak = mon->leak + head; + limit = NTP_SHIFT * head; + + DPRINTF(2, ("MRU: interval %d headway %d limit %d\n", + interval, leak, limit)); + + /* + * If the minimum and average thresholds are not + * exceeded, douse the RES_LIMITED and RES_KOD bits and + * increase the counter by the headway increment. Note + * that we give a 1-s grace for the minimum threshold + * and a 2-s grace for the headway increment. If one or + * both thresholds are exceeded and the old counter is + * less than the average threshold, set the counter to + * the average threshold plus the increment and leave + * the RES_LIMITED and RES_KOD bits lit. Otherwise, + * leave the counter alone and douse the RES_KOD bit. + * This rate-limits the KoDs to no less than the average + * headway. + */ + if (interval + 1 >= ntp_minpkt && leak < limit) { + mon->leak = leak - 2; + restrict_mask &= ~(RES_LIMITED | RES_KOD); + } else if (mon->leak < limit) + mon->leak = limit + head; + else + restrict_mask &= ~RES_KOD; + + mon->flags = restrict_mask; + + return mon->flags; } /* * If we got here, this is the first we've heard of this * guy. Get him some memory, either from the free list * or from the tail of the MRU list. + * + * The following ntp.conf "mru" knobs come into play determining + * the depth (or count) of the MRU list: + * - mru_mindepth ("mru mindepth") is a floor beneath which + * entries are kept without regard to their age. The + * default is 600 which matches the longtime implementation + * limit on the total number of entries. + * - mru_maxage ("mru maxage") is a ceiling on the age in + * seconds of entries. Entries older than this are + * reclaimed once mon_mindepth is exceeded. 64s default. + * Note that entries older than this can easily survive + * as they are reclaimed only as needed. + * - mru_maxdepth ("mru maxdepth") is a hard limit on the + * number of entries. + * - "mru maxmem" sets mru_maxdepth to the number of entries + * which fit in the given number of kilobytes. The default is + * 1024, or 1 megabyte. + * - mru_initalloc ("mru initalloc" sets the count of the + * initial allocation of MRU entries. + * - "mru initmem" sets mru_initalloc in units of kilobytes. + * The default is 4. + * - mru_incalloc ("mru incalloc" sets the number of entries to + * allocate on-demand each time the free list is empty. + * - "mru incmem" sets mru_incalloc in units of kilobytes. + * The default is 4. + * Whichever of "mru maxmem" or "mru maxdepth" occurs last in + * ntp.conf controls. Similarly for "mru initalloc" and "mru + * initmem", and for "mru incalloc" and "mru incmem". */ - if (mon_free == NULL && mon_total_mem >= MAXMONMEM) { - - /* - * Preempt from the MRU list if old enough. - */ - md = mon_mru_list.mru_prev; - /* We get 31 bits from ntp_random() */ - if (((u_long)ntp_random()) / FRAC > - (double)(current_time - md->lasttime) / mon_age) - return 0; - - md->mru_prev->mru_next = &mon_mru_list; - mon_mru_list.mru_prev = md->mru_prev; - remove_from_hash(md); - } else { - if (mon_free == NULL) + if (mru_entries < mru_mindepth) { + if (NULL == mon_free) mon_getmoremem(); - md = mon_free; - mon_free = md->hash_next; + UNLINK_HEAD_SLIST(mon, mon_free, hash_next); + } else { + oldest = TAIL_DLIST(mon_mru_list, mru); + oldest_age = 0; /* silence uninit warning */ + if (oldest != NULL) { + interval_fp = rbufp->recv_time; + L_SUB(&interval_fp, &oldest->last); + /* add one-half second to round up */ + L_ADDUF(&interval_fp, 0x80000000); + oldest_age = interval_fp.l_i; + } + /* note -1 is legal for mru_maxage (disables) */ + if (oldest != NULL && mru_maxage < oldest_age) { + mon_reclaim_entry(oldest); + mon = oldest; + } else if (mon_free != NULL || mru_alloc < + mru_maxdepth) { + if (NULL == mon_free) + mon_getmoremem(); + UNLINK_HEAD_SLIST(mon, mon_free, hash_next); + /* Preempt from the MRU list if old enough. */ + } else if (ntp_random() / (2. * FRAC) > + (double)oldest_age / mon_age) { + return ~(RES_LIMITED | RES_KOD) & flags; + } else { + mon_reclaim_entry(oldest); + mon = oldest; + } } + INSIST(mon != NULL); + /* * Got one, initialize it */ - md->avg_interval = 0; - md->lasttime = current_time; - md->count = 1; - md->drop_count = 0; - memset(&md->rmtadr, 0, sizeof(md->rmtadr)); - memcpy(&md->rmtadr, &addr, sizeof(addr)); - md->rmtport = NSRCPORT(&rbufp->recv_srcadr); - md->mode = (u_char) mode; - md->version = PKT_VERSION(pkt->li_vn_mode); - md->interface = rbufp->dstadr; - md->cast_flags = (u_char)(((rbufp->dstadr->flags & INT_MCASTOPEN) && - rbufp->fd == md->interface->fd) ? MDF_MCAST: rbufp->fd == - md->interface->bfd ? MDF_BCAST : MDF_UCAST); + mru_entries++; + mru_peakentries = max(mru_peakentries, mru_entries); + mon->last = rbufp->recv_time; + mon->first = mon->last; + mon->count = 1; + mon->flags = ~(RES_LIMITED | RES_KOD) & flags; + mon->leak = 0; + memcpy(&mon->rmtadr, &rbufp->recv_srcadr, sizeof(mon->rmtadr)); + mon->vn_mode = VN_MODE(version, mode); + mon->lcladr = rbufp->dstadr; + mon->cast_flags = (u_char)(((rbufp->dstadr->flags & + INT_MCASTOPEN) && rbufp->fd == mon->lcladr->fd) ? MDF_MCAST + : rbufp->fd == mon->lcladr->bfd ? MDF_BCAST : MDF_UCAST); /* * Drop him into front of the hash table. Also put him on top of * the MRU list. */ - md->hash_next = mon_hash[hash]; - mon_hash[hash] = md; - md->mru_next = mon_mru_list.mru_next; - md->mru_prev = &mon_mru_list; - mon_mru_list.mru_next->mru_prev = md; - mon_mru_list.mru_next = md; - return 1; -} - + LINK_SLIST(mon_hash[hash], mon, hash_next); + LINK_DLIST(mon_mru_list, mon, mru); -/* - * mon_getmoremem - get more memory and put it on the free list - */ -static void -mon_getmoremem(void) -{ - register struct mon_data *md; - register int i; - struct mon_data *freedata; /* 'old' free list (null) */ - - md = (struct mon_data *)emalloc(MONMEMINC * - sizeof(struct mon_data)); - freedata = mon_free; - mon_free = md; - for (i = 0; i < (MONMEMINC-1); i++) { - md->hash_next = (md + 1); - md++; - } - - /* - * md now points at the last. Link in the rest of the chain. - */ - md->hash_next = freedata; - mon_total_mem += MONMEMINC; - mon_mem_increments++; + return mon->flags; } -static void -remove_from_hash( - struct mon_data *md - ) -{ - register int hash; - register struct mon_data *md_prev; - hash = MON_HASH(&md->rmtadr); - if (mon_hash[hash] == md) { - mon_hash[hash] = md->hash_next; - } else { - md_prev = mon_hash[hash]; - while (md_prev->hash_next != md) { - md_prev = md_prev->hash_next; - if (md_prev == NULL) { - /* logic error */ - return; - } - } - md_prev->hash_next = md->hash_next; - } -} diff --git a/contrib/ntp/ntpd/ntp_parser.c b/contrib/ntp/ntpd/ntp_parser.c new file mode 100644 index 000000000..6235033fe --- /dev/null +++ b/contrib/ntp/ntpd/ntp_parser.c @@ -0,0 +1,3657 @@ +/* A Bison parser, made by GNU Bison 3.0.2. */ + +/* Bison implementation for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "3.0.2" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + + + + +/* Copy the first part of user declarations. */ +#line 11 "../../ntpd/ntp_parser.y" /* yacc.c:339 */ + + #ifdef HAVE_CONFIG_H + # include + #endif + + #include "ntp.h" + #include "ntpd.h" + #include "ntp_machine.h" + #include "ntp_stdlib.h" + #include "ntp_filegen.h" + #include "ntp_scanner.h" + #include "ntp_config.h" + #include "ntp_crypto.h" + + #include "ntpsim.h" /* HMS: Do we really want this all the time? */ + /* SK: It might be a good idea to always + include the simulator code. That way + someone can use the same configuration file + for both the simulator and the daemon + */ + + #define YYMALLOC emalloc + #define YYFREE free + #define YYERROR_VERBOSE + #define YYMAXDEPTH 1000 /* stop the madness sooner */ + void yyerror(const char *msg); + + #ifdef SIM + # define ONLY_SIM(a) (a) + #else + # define ONLY_SIM(a) NULL + #endif + +#line 100 "../../ntpd/ntp_parser.c" /* yacc.c:339 */ + +# ifndef YY_NULLPTR +# if defined __cplusplus && 201103L <= __cplusplus +# define YY_NULLPTR nullptr +# else +# define YY_NULLPTR 0 +# endif +# endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* In a future release of Bison, this section will be replaced + by #include "y.tab.h". */ +#ifndef YY_YY__NTPD_NTP_PARSER_H_INCLUDED +# define YY_YY__NTPD_NTP_PARSER_H_INCLUDED +/* Debug traces. */ +#ifndef YYDEBUG +# define YYDEBUG 1 +#endif +#if YYDEBUG +extern int yydebug; +#endif + +/* Token type. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + enum yytokentype + { + T_Abbrev = 258, + T_Age = 259, + T_All = 260, + T_Allan = 261, + T_Allpeers = 262, + T_Auth = 263, + T_Autokey = 264, + T_Automax = 265, + T_Average = 266, + T_Bclient = 267, + T_Beacon = 268, + T_Broadcast = 269, + T_Broadcastclient = 270, + T_Broadcastdelay = 271, + T_Burst = 272, + T_Calibrate = 273, + T_Ceiling = 274, + T_Clockstats = 275, + T_Cohort = 276, + T_ControlKey = 277, + T_Crypto = 278, + T_Cryptostats = 279, + T_Ctl = 280, + T_Day = 281, + T_Default = 282, + T_Digest = 283, + T_Disable = 284, + T_Discard = 285, + T_Dispersion = 286, + T_Double = 287, + T_Driftfile = 288, + T_Drop = 289, + T_Dscp = 290, + T_Ellipsis = 291, + T_Enable = 292, + T_End = 293, + T_False = 294, + T_File = 295, + T_Filegen = 296, + T_Filenum = 297, + T_Flag1 = 298, + T_Flag2 = 299, + T_Flag3 = 300, + T_Flag4 = 301, + T_Flake = 302, + T_Floor = 303, + T_Freq = 304, + T_Fudge = 305, + T_Host = 306, + T_Huffpuff = 307, + T_Iburst = 308, + T_Ident = 309, + T_Ignore = 310, + T_Incalloc = 311, + T_Incmem = 312, + T_Initalloc = 313, + T_Initmem = 314, + T_Includefile = 315, + T_Integer = 316, + T_Interface = 317, + T_Intrange = 318, + T_Io = 319, + T_Ipv4 = 320, + T_Ipv4_flag = 321, + T_Ipv6 = 322, + T_Ipv6_flag = 323, + T_Kernel = 324, + T_Key = 325, + T_Keys = 326, + T_Keysdir = 327, + T_Kod = 328, + T_Mssntp = 329, + T_Leapfile = 330, + T_Leapsmearinterval = 331, + T_Limited = 332, + T_Link = 333, + T_Listen = 334, + T_Logconfig = 335, + T_Logfile = 336, + T_Loopstats = 337, + T_Lowpriotrap = 338, + T_Manycastclient = 339, + T_Manycastserver = 340, + T_Mask = 341, + T_Maxage = 342, + T_Maxclock = 343, + T_Maxdepth = 344, + T_Maxdist = 345, + T_Maxmem = 346, + T_Maxpoll = 347, + T_Mdnstries = 348, + T_Mem = 349, + T_Memlock = 350, + T_Minclock = 351, + T_Mindepth = 352, + T_Mindist = 353, + T_Minimum = 354, + T_Minpoll = 355, + T_Minsane = 356, + T_Mode = 357, + T_Mode7 = 358, + T_Monitor = 359, + T_Month = 360, + T_Mru = 361, + T_Multicastclient = 362, + T_Nic = 363, + T_Nolink = 364, + T_Nomodify = 365, + T_Nomrulist = 366, + T_None = 367, + T_Nonvolatile = 368, + T_Nopeer = 369, + T_Noquery = 370, + T_Noselect = 371, + T_Noserve = 372, + T_Notrap = 373, + T_Notrust = 374, + T_Ntp = 375, + T_Ntpport = 376, + T_NtpSignDsocket = 377, + T_Orphan = 378, + T_Orphanwait = 379, + T_Panic = 380, + T_Peer = 381, + T_Peerstats = 382, + T_Phone = 383, + T_Pid = 384, + T_Pidfile = 385, + T_Pool = 386, + T_Port = 387, + T_Preempt = 388, + T_Prefer = 389, + T_Protostats = 390, + T_Pw = 391, + T_Randfile = 392, + T_Rawstats = 393, + T_Refid = 394, + T_Requestkey = 395, + T_Reset = 396, + T_Restrict = 397, + T_Revoke = 398, + T_Rlimit = 399, + T_Saveconfigdir = 400, + T_Server = 401, + T_Setvar = 402, + T_Source = 403, + T_Stacksize = 404, + T_Statistics = 405, + T_Stats = 406, + T_Statsdir = 407, + T_Step = 408, + T_Stepback = 409, + T_Stepfwd = 410, + T_Stepout = 411, + T_Stratum = 412, + T_String = 413, + T_Sys = 414, + T_Sysstats = 415, + T_Tick = 416, + T_Time1 = 417, + T_Time2 = 418, + T_Timer = 419, + T_Timingstats = 420, + T_Tinker = 421, + T_Tos = 422, + T_Trap = 423, + T_True = 424, + T_Trustedkey = 425, + T_Ttl = 426, + T_Type = 427, + T_U_int = 428, + T_Unconfig = 429, + T_Unpeer = 430, + T_Version = 431, + T_WanderThreshold = 432, + T_Week = 433, + T_Wildcard = 434, + T_Xleave = 435, + T_Year = 436, + T_Flag = 437, + T_EOC = 438, + T_Simulate = 439, + T_Beep_Delay = 440, + T_Sim_Duration = 441, + T_Server_Offset = 442, + T_Duration = 443, + T_Freq_Offset = 444, + T_Wander = 445, + T_Jitter = 446, + T_Prop_Delay = 447, + T_Proc_Delay = 448 + }; +#endif +/* Tokens. */ +#define T_Abbrev 258 +#define T_Age 259 +#define T_All 260 +#define T_Allan 261 +#define T_Allpeers 262 +#define T_Auth 263 +#define T_Autokey 264 +#define T_Automax 265 +#define T_Average 266 +#define T_Bclient 267 +#define T_Beacon 268 +#define T_Broadcast 269 +#define T_Broadcastclient 270 +#define T_Broadcastdelay 271 +#define T_Burst 272 +#define T_Calibrate 273 +#define T_Ceiling 274 +#define T_Clockstats 275 +#define T_Cohort 276 +#define T_ControlKey 277 +#define T_Crypto 278 +#define T_Cryptostats 279 +#define T_Ctl 280 +#define T_Day 281 +#define T_Default 282 +#define T_Digest 283 +#define T_Disable 284 +#define T_Discard 285 +#define T_Dispersion 286 +#define T_Double 287 +#define T_Driftfile 288 +#define T_Drop 289 +#define T_Dscp 290 +#define T_Ellipsis 291 +#define T_Enable 292 +#define T_End 293 +#define T_False 294 +#define T_File 295 +#define T_Filegen 296 +#define T_Filenum 297 +#define T_Flag1 298 +#define T_Flag2 299 +#define T_Flag3 300 +#define T_Flag4 301 +#define T_Flake 302 +#define T_Floor 303 +#define T_Freq 304 +#define T_Fudge 305 +#define T_Host 306 +#define T_Huffpuff 307 +#define T_Iburst 308 +#define T_Ident 309 +#define T_Ignore 310 +#define T_Incalloc 311 +#define T_Incmem 312 +#define T_Initalloc 313 +#define T_Initmem 314 +#define T_Includefile 315 +#define T_Integer 316 +#define T_Interface 317 +#define T_Intrange 318 +#define T_Io 319 +#define T_Ipv4 320 +#define T_Ipv4_flag 321 +#define T_Ipv6 322 +#define T_Ipv6_flag 323 +#define T_Kernel 324 +#define T_Key 325 +#define T_Keys 326 +#define T_Keysdir 327 +#define T_Kod 328 +#define T_Mssntp 329 +#define T_Leapfile 330 +#define T_Leapsmearinterval 331 +#define T_Limited 332 +#define T_Link 333 +#define T_Listen 334 +#define T_Logconfig 335 +#define T_Logfile 336 +#define T_Loopstats 337 +#define T_Lowpriotrap 338 +#define T_Manycastclient 339 +#define T_Manycastserver 340 +#define T_Mask 341 +#define T_Maxage 342 +#define T_Maxclock 343 +#define T_Maxdepth 344 +#define T_Maxdist 345 +#define T_Maxmem 346 +#define T_Maxpoll 347 +#define T_Mdnstries 348 +#define T_Mem 349 +#define T_Memlock 350 +#define T_Minclock 351 +#define T_Mindepth 352 +#define T_Mindist 353 +#define T_Minimum 354 +#define T_Minpoll 355 +#define T_Minsane 356 +#define T_Mode 357 +#define T_Mode7 358 +#define T_Monitor 359 +#define T_Month 360 +#define T_Mru 361 +#define T_Multicastclient 362 +#define T_Nic 363 +#define T_Nolink 364 +#define T_Nomodify 365 +#define T_Nomrulist 366 +#define T_None 367 +#define T_Nonvolatile 368 +#define T_Nopeer 369 +#define T_Noquery 370 +#define T_Noselect 371 +#define T_Noserve 372 +#define T_Notrap 373 +#define T_Notrust 374 +#define T_Ntp 375 +#define T_Ntpport 376 +#define T_NtpSignDsocket 377 +#define T_Orphan 378 +#define T_Orphanwait 379 +#define T_Panic 380 +#define T_Peer 381 +#define T_Peerstats 382 +#define T_Phone 383 +#define T_Pid 384 +#define T_Pidfile 385 +#define T_Pool 386 +#define T_Port 387 +#define T_Preempt 388 +#define T_Prefer 389 +#define T_Protostats 390 +#define T_Pw 391 +#define T_Randfile 392 +#define T_Rawstats 393 +#define T_Refid 394 +#define T_Requestkey 395 +#define T_Reset 396 +#define T_Restrict 397 +#define T_Revoke 398 +#define T_Rlimit 399 +#define T_Saveconfigdir 400 +#define T_Server 401 +#define T_Setvar 402 +#define T_Source 403 +#define T_Stacksize 404 +#define T_Statistics 405 +#define T_Stats 406 +#define T_Statsdir 407 +#define T_Step 408 +#define T_Stepback 409 +#define T_Stepfwd 410 +#define T_Stepout 411 +#define T_Stratum 412 +#define T_String 413 +#define T_Sys 414 +#define T_Sysstats 415 +#define T_Tick 416 +#define T_Time1 417 +#define T_Time2 418 +#define T_Timer 419 +#define T_Timingstats 420 +#define T_Tinker 421 +#define T_Tos 422 +#define T_Trap 423 +#define T_True 424 +#define T_Trustedkey 425 +#define T_Ttl 426 +#define T_Type 427 +#define T_U_int 428 +#define T_Unconfig 429 +#define T_Unpeer 430 +#define T_Version 431 +#define T_WanderThreshold 432 +#define T_Week 433 +#define T_Wildcard 434 +#define T_Xleave 435 +#define T_Year 436 +#define T_Flag 437 +#define T_EOC 438 +#define T_Simulate 439 +#define T_Beep_Delay 440 +#define T_Sim_Duration 441 +#define T_Server_Offset 442 +#define T_Duration 443 +#define T_Freq_Offset 444 +#define T_Wander 445 +#define T_Jitter 446 +#define T_Prop_Delay 447 +#define T_Proc_Delay 448 + +/* Value type. */ +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE YYSTYPE; +union YYSTYPE +{ +#line 51 "../../ntpd/ntp_parser.y" /* yacc.c:355 */ + + char * String; + double Double; + int Integer; + unsigned U_int; + gen_fifo * Generic_fifo; + attr_val * Attr_val; + attr_val_fifo * Attr_val_fifo; + int_fifo * Int_fifo; + string_fifo * String_fifo; + address_node * Address_node; + address_fifo * Address_fifo; + setvar_node * Set_var; + server_info * Sim_server; + server_info_fifo * Sim_server_fifo; + script_info * Sim_script; + script_info_fifo * Sim_script_fifo; + +#line 545 "../../ntpd/ntp_parser.c" /* yacc.c:355 */ +}; +# define YYSTYPE_IS_TRIVIAL 1 +# define YYSTYPE_IS_DECLARED 1 +#endif + + +extern YYSTYPE yylval; + +int yyparse (void); + +#endif /* !YY_YY__NTPD_NTP_PARSER_H_INCLUDED */ + +/* Copy the second part of user declarations. */ + +#line 560 "../../ntpd/ntp_parser.c" /* yacc.c:358 */ + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#else +typedef signed char yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if defined YYENABLE_NLS && YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(Msgid) dgettext ("bison-runtime", Msgid) +# endif +# endif +# ifndef YY_ +# define YY_(Msgid) Msgid +# endif +#endif + +#ifndef YY_ATTRIBUTE +# if (defined __GNUC__ \ + && (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \ + || defined __SUNPRO_C && 0x5110 <= __SUNPRO_C +# define YY_ATTRIBUTE(Spec) __attribute__(Spec) +# else +# define YY_ATTRIBUTE(Spec) /* empty */ +# endif +#endif + +#ifndef YY_ATTRIBUTE_PURE +# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__)) +#endif + +#ifndef YY_ATTRIBUTE_UNUSED +# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__)) +#endif + +#if !defined _Noreturn \ + && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112) +# if defined _MSC_VER && 1200 <= _MSC_VER +# define _Noreturn __declspec (noreturn) +# else +# define _Noreturn YY_ATTRIBUTE ((__noreturn__)) +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(E) ((void) (E)) +#else +# define YYUSE(E) /* empty */ +#endif + +#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ +/* Suppress an incorrect diagnostic about yylval being uninitialized. */ +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ + _Pragma ("GCC diagnostic push") \ + _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\ + _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") +# define YY_IGNORE_MAYBE_UNINITIALIZED_END \ + _Pragma ("GCC diagnostic pop") +#else +# define YY_INITIAL_VALUE(Value) Value +#endif +#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN +# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN +# define YY_IGNORE_MAYBE_UNINITIALIZED_END +#endif +#ifndef YY_INITIAL_VALUE +# define YY_INITIAL_VALUE(Value) /* Nothing. */ +#endif + + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS +# include /* INFRINGES ON USER NAME SPACE */ + /* Use EXIT_SUCCESS as a witness for stdlib.h. */ +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's 'empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined EXIT_SUCCESS \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined EXIT_SUCCESS +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined EXIT_SUCCESS +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAXIMUM) + +# define YYCOPY_NEEDED 1 + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (0) + +#endif + +#if defined YYCOPY_NEEDED && YYCOPY_NEEDED +/* Copy COUNT objects from SRC to DST. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(Dst, Src, Count) \ + __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src))) +# else +# define YYCOPY(Dst, Src, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (Dst)[yyi] = (Src)[yyi]; \ + } \ + while (0) +# endif +# endif +#endif /* !YYCOPY_NEEDED */ + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 210 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 647 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 199 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 105 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 313 +/* YYNSTATES -- Number of states. */ +#define YYNSTATES 419 + +/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned + by yylex, with out-of-bounds checking. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 448 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM + as returned by yylex, without out-of-bounds checking. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 195, 196, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 194, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 197, 2, 198, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, + 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, + 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, + 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, + 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, + 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, + 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, + 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, + 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, + 185, 186, 187, 188, 189, 190, 191, 192, 193 +}; + +#if YYDEBUG + /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ +static const yytype_uint16 yyrline[] = +{ + 0, 366, 366, 370, 371, 372, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 397, 398, 399, 400, + 408, 418, 419, 420, 421, 422, 426, 427, 432, 437, + 439, 445, 446, 454, 455, 456, 460, 465, 466, 467, + 468, 469, 470, 471, 472, 476, 478, 483, 484, 485, + 486, 487, 488, 492, 497, 506, 516, 517, 527, 529, + 531, 533, 544, 551, 553, 558, 560, 562, 564, 566, + 575, 581, 582, 590, 592, 604, 605, 606, 607, 608, + 617, 622, 627, 635, 637, 639, 644, 645, 646, 647, + 648, 649, 653, 654, 655, 656, 665, 667, 676, 686, + 691, 699, 700, 701, 702, 703, 704, 705, 706, 711, + 712, 720, 730, 739, 754, 759, 760, 764, 765, 769, + 770, 771, 772, 773, 774, 775, 784, 788, 792, 800, + 808, 816, 831, 846, 859, 860, 868, 869, 870, 871, + 872, 873, 874, 875, 876, 877, 878, 879, 880, 881, + 882, 886, 891, 899, 904, 905, 906, 910, 915, 923, + 928, 929, 930, 931, 932, 933, 934, 935, 943, 953, + 958, 966, 968, 970, 972, 974, 979, 980, 984, 985, + 986, 987, 995, 1000, 1005, 1013, 1018, 1019, 1020, 1029, + 1031, 1036, 1041, 1049, 1051, 1068, 1069, 1070, 1071, 1072, + 1073, 1077, 1078, 1086, 1091, 1096, 1104, 1109, 1110, 1111, + 1112, 1113, 1114, 1115, 1116, 1117, 1118, 1127, 1128, 1129, + 1136, 1143, 1150, 1166, 1185, 1187, 1189, 1191, 1193, 1195, + 1202, 1207, 1208, 1209, 1213, 1217, 1226, 1227, 1231, 1232, + 1233, 1237, 1248, 1262, 1274, 1279, 1281, 1286, 1287, 1295, + 1297, 1305, 1310, 1318, 1343, 1350, 1360, 1361, 1365, 1366, + 1367, 1368, 1372, 1373, 1374, 1378, 1383, 1388, 1396, 1397, + 1398, 1399, 1400, 1401, 1402, 1412, 1417, 1425, 1430, 1438, + 1440, 1444, 1449, 1454, 1462, 1467, 1475, 1484, 1485, 1489, + 1490, 1499, 1517, 1521, 1526, 1534, 1539, 1540, 1544, 1549, + 1557, 1562, 1567, 1572, 1577, 1585, 1590, 1595, 1603, 1608, + 1609, 1610, 1611, 1612 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || 1 +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "T_Abbrev", "T_Age", "T_All", "T_Allan", + "T_Allpeers", "T_Auth", "T_Autokey", "T_Automax", "T_Average", + "T_Bclient", "T_Beacon", "T_Broadcast", "T_Broadcastclient", + "T_Broadcastdelay", "T_Burst", "T_Calibrate", "T_Ceiling", + "T_Clockstats", "T_Cohort", "T_ControlKey", "T_Crypto", "T_Cryptostats", + "T_Ctl", "T_Day", "T_Default", "T_Digest", "T_Disable", "T_Discard", + "T_Dispersion", "T_Double", "T_Driftfile", "T_Drop", "T_Dscp", + "T_Ellipsis", "T_Enable", "T_End", "T_False", "T_File", "T_Filegen", + "T_Filenum", "T_Flag1", "T_Flag2", "T_Flag3", "T_Flag4", "T_Flake", + "T_Floor", "T_Freq", "T_Fudge", "T_Host", "T_Huffpuff", "T_Iburst", + "T_Ident", "T_Ignore", "T_Incalloc", "T_Incmem", "T_Initalloc", + "T_Initmem", "T_Includefile", "T_Integer", "T_Interface", "T_Intrange", + "T_Io", "T_Ipv4", "T_Ipv4_flag", "T_Ipv6", "T_Ipv6_flag", "T_Kernel", + "T_Key", "T_Keys", "T_Keysdir", "T_Kod", "T_Mssntp", "T_Leapfile", + "T_Leapsmearinterval", "T_Limited", "T_Link", "T_Listen", "T_Logconfig", + "T_Logfile", "T_Loopstats", "T_Lowpriotrap", "T_Manycastclient", + "T_Manycastserver", "T_Mask", "T_Maxage", "T_Maxclock", "T_Maxdepth", + "T_Maxdist", "T_Maxmem", "T_Maxpoll", "T_Mdnstries", "T_Mem", + "T_Memlock", "T_Minclock", "T_Mindepth", "T_Mindist", "T_Minimum", + "T_Minpoll", "T_Minsane", "T_Mode", "T_Mode7", "T_Monitor", "T_Month", + "T_Mru", "T_Multicastclient", "T_Nic", "T_Nolink", "T_Nomodify", + "T_Nomrulist", "T_None", "T_Nonvolatile", "T_Nopeer", "T_Noquery", + "T_Noselect", "T_Noserve", "T_Notrap", "T_Notrust", "T_Ntp", "T_Ntpport", + "T_NtpSignDsocket", "T_Orphan", "T_Orphanwait", "T_Panic", "T_Peer", + "T_Peerstats", "T_Phone", "T_Pid", "T_Pidfile", "T_Pool", "T_Port", + "T_Preempt", "T_Prefer", "T_Protostats", "T_Pw", "T_Randfile", + "T_Rawstats", "T_Refid", "T_Requestkey", "T_Reset", "T_Restrict", + "T_Revoke", "T_Rlimit", "T_Saveconfigdir", "T_Server", "T_Setvar", + "T_Source", "T_Stacksize", "T_Statistics", "T_Stats", "T_Statsdir", + "T_Step", "T_Stepback", "T_Stepfwd", "T_Stepout", "T_Stratum", + "T_String", "T_Sys", "T_Sysstats", "T_Tick", "T_Time1", "T_Time2", + "T_Timer", "T_Timingstats", "T_Tinker", "T_Tos", "T_Trap", "T_True", + "T_Trustedkey", "T_Ttl", "T_Type", "T_U_int", "T_Unconfig", "T_Unpeer", + "T_Version", "T_WanderThreshold", "T_Week", "T_Wildcard", "T_Xleave", + "T_Year", "T_Flag", "T_EOC", "T_Simulate", "T_Beep_Delay", + "T_Sim_Duration", "T_Server_Offset", "T_Duration", "T_Freq_Offset", + "T_Wander", "T_Jitter", "T_Prop_Delay", "T_Proc_Delay", "'='", "'('", + "')'", "'{'", "'}'", "$accept", "configuration", "command_list", + "command", "server_command", "client_type", "address", "ip_address", + "address_fam", "option_list", "option", "option_flag", + "option_flag_keyword", "option_int", "option_int_keyword", "option_str", + "option_str_keyword", "unpeer_command", "unpeer_keyword", + "other_mode_command", "authentication_command", "crypto_command_list", + "crypto_command", "crypto_str_keyword", "orphan_mode_command", + "tos_option_list", "tos_option", "tos_option_int_keyword", + "tos_option_dbl_keyword", "monitoring_command", "stats_list", "stat", + "filegen_option_list", "filegen_option", "link_nolink", "enable_disable", + "filegen_type", "access_control_command", "ac_flag_list", + "access_control_flag", "discard_option_list", "discard_option", + "discard_option_keyword", "mru_option_list", "mru_option", + "mru_option_keyword", "fudge_command", "fudge_factor_list", + "fudge_factor", "fudge_factor_dbl_keyword", "fudge_factor_bool_keyword", + "rlimit_command", "rlimit_option_list", "rlimit_option", + "rlimit_option_keyword", "system_option_command", "system_option_list", + "system_option", "system_option_flag_keyword", + "system_option_local_flag_keyword", "tinker_command", + "tinker_option_list", "tinker_option", "tinker_option_keyword", + "miscellaneous_command", "misc_cmd_dbl_keyword", "misc_cmd_int_keyword", + "misc_cmd_str_keyword", "misc_cmd_str_lcl_keyword", "drift_parm", + "variable_assign", "t_default_or_zero", "trap_option_list", + "trap_option", "log_config_list", "log_config_command", + "interface_command", "interface_nic", "nic_rule_class", + "nic_rule_action", "reset_command", "counter_set_list", + "counter_set_keyword", "integer_list", "integer_list_range", + "integer_list_range_elt", "integer_range", "string_list", "address_list", + "boolean", "number", "simulate_command", "sim_conf_start", + "sim_init_statement_list", "sim_init_statement", "sim_init_keyword", + "sim_server_list", "sim_server", "sim_server_offset", "sim_server_name", + "sim_act_list", "sim_act", "sim_act_stmt_list", "sim_act_stmt", + "sim_act_keyword", YY_NULLPTR +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[NUM] -- (External) token number corresponding to the + (internal) symbol number NUM (which must be that of a token). */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 420, 421, 422, 423, 424, + 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, + 445, 446, 447, 448, 61, 40, 41, 123, 125 +}; +# endif + +#define YYPACT_NINF -185 + +#define yypact_value_is_default(Yystate) \ + (!!((Yystate) == (-185))) + +#define YYTABLE_NINF -7 + +#define yytable_value_is_error(Yytable_value) \ + 0 + + /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +static const yytype_int16 yypact[] = +{ + 78, -169, -34, -185, -185, -185, -29, -185, 17, 43, + -124, -185, 17, -185, -5, -27, -185, -121, -185, -112, + -110, -185, -185, -100, -185, -185, -27, 0, 116, -27, + -185, -185, -91, -185, -89, -185, -185, 11, 35, 30, + 13, 31, -185, -185, -83, -5, -78, -185, 186, 523, + -76, -56, 15, -185, -185, -185, 83, 244, -99, -185, + -27, -185, -27, -185, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -12, 24, -71, -69, -185, -11, -185, + -185, -107, -185, -185, -185, 8, -185, -185, -185, -185, + -185, -185, -185, -185, 17, -185, -185, -185, -185, -185, + -185, 43, -185, 34, 59, -185, 17, -185, -185, -185, + -185, -185, -185, -185, -185, -185, -185, -185, -185, 7, + -185, -61, 407, -185, -185, -185, -100, -185, -185, -27, + -185, -185, -185, -185, -185, -185, -185, -185, -185, 116, + -185, 44, -27, -185, -185, -52, -185, -185, -185, -185, + -185, -185, -185, -185, 35, -185, -185, 85, 96, -185, + -185, 39, -185, -185, -185, -185, 31, -185, 75, -46, + -185, -5, -185, -185, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -185, 186, -185, -12, -185, -185, -35, + -185, -185, -185, -185, -185, -185, -185, -185, 523, -185, + 82, -12, -185, -185, 91, -56, -185, -185, -185, 100, + -185, -26, -185, -185, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -185, -2, -130, -185, -185, -185, -185, + -185, 105, -185, 9, -185, -185, -185, -185, -7, 18, + -185, -185, -185, -185, 25, 121, -185, -185, 7, -185, + -12, -35, -185, -185, -185, -185, -185, -185, -185, -185, + 391, -185, -185, 391, 391, -76, -185, -185, 29, -185, + -185, -185, -185, -185, -185, -185, -185, -185, -185, -51, + 153, -185, -185, -185, 464, -185, -185, -185, -185, -185, + -185, -185, -185, -82, 14, 1, -185, -185, -185, -185, + 38, -185, -185, 12, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -185, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -185, -185, -185, -185, -185, -185, 391, + 391, -185, 171, -76, 140, -185, 141, -185, -185, -185, + -185, -185, -185, -185, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -185, -185, -185, -55, -185, 53, 20, + 33, -128, -185, 32, -185, -12, -185, -185, -185, -185, + -185, -185, -185, -185, -185, 391, -185, -185, -185, -185, + 16, -185, -185, -185, -27, -185, -185, -185, 46, -185, + -185, -185, 37, 48, -12, 40, -167, -185, 54, -12, + -185, -185, -185, 45, 79, -185, -185, -185, -185, -185, + 98, 57, 47, -185, 60, -185, -12, -185, -185 +}; + + /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. + Performed when YYTABLE does not specify something else to do. Zero + means the default is an error. */ +static const yytype_uint16 yydefact[] = +{ + 0, 0, 0, 24, 58, 231, 0, 71, 0, 0, + 243, 234, 0, 224, 0, 0, 236, 0, 256, 0, + 0, 237, 235, 0, 238, 25, 0, 0, 0, 0, + 257, 232, 0, 23, 0, 239, 22, 0, 0, 0, + 0, 0, 240, 21, 0, 0, 0, 233, 0, 0, + 0, 0, 0, 56, 57, 292, 0, 2, 0, 7, + 0, 8, 0, 9, 10, 13, 11, 12, 14, 15, + 16, 17, 18, 0, 0, 0, 0, 217, 0, 218, + 19, 0, 5, 62, 63, 64, 195, 196, 197, 198, + 201, 199, 200, 202, 190, 192, 193, 194, 154, 155, + 156, 126, 152, 0, 241, 225, 189, 101, 102, 103, + 104, 108, 105, 106, 107, 109, 29, 30, 28, 0, + 26, 0, 6, 65, 66, 253, 226, 252, 285, 59, + 61, 160, 161, 162, 163, 164, 165, 166, 167, 127, + 158, 0, 60, 70, 283, 227, 67, 268, 269, 270, + 271, 272, 273, 274, 265, 267, 134, 29, 30, 134, + 134, 26, 68, 188, 186, 187, 182, 184, 0, 0, + 228, 96, 100, 97, 207, 208, 209, 210, 211, 212, + 213, 214, 215, 216, 203, 205, 0, 91, 86, 0, + 87, 95, 93, 94, 92, 90, 88, 89, 80, 82, + 0, 0, 247, 279, 0, 69, 278, 280, 276, 230, + 1, 0, 4, 31, 55, 290, 289, 219, 220, 221, + 222, 264, 263, 262, 0, 0, 79, 75, 76, 77, + 78, 0, 72, 0, 191, 151, 153, 242, 98, 0, + 178, 179, 180, 181, 0, 0, 176, 177, 168, 170, + 0, 0, 27, 223, 251, 284, 157, 159, 282, 266, + 130, 134, 134, 133, 128, 0, 183, 185, 0, 99, + 204, 206, 288, 286, 287, 85, 81, 83, 84, 229, + 0, 277, 275, 3, 20, 258, 259, 260, 255, 261, + 254, 296, 297, 0, 0, 0, 74, 73, 118, 117, + 0, 115, 116, 0, 110, 113, 114, 174, 175, 173, + 169, 171, 172, 136, 137, 138, 139, 140, 141, 142, + 143, 144, 145, 146, 147, 148, 149, 150, 135, 131, + 132, 134, 246, 0, 0, 248, 0, 37, 38, 39, + 54, 47, 49, 48, 51, 40, 41, 42, 43, 50, + 52, 44, 32, 33, 36, 34, 0, 35, 0, 0, + 0, 0, 299, 0, 294, 0, 111, 125, 121, 123, + 119, 120, 122, 124, 112, 129, 245, 244, 250, 249, + 0, 45, 46, 53, 0, 293, 291, 298, 0, 295, + 281, 302, 0, 0, 0, 0, 0, 304, 0, 0, + 300, 303, 301, 0, 0, 309, 310, 311, 312, 313, + 0, 0, 0, 305, 0, 307, 0, 306, 308 +}; + + /* YYPGOTO[NTERM-NUM]. */ +static const yytype_int16 yypgoto[] = +{ + -185, -185, -185, -44, -185, -185, -15, -38, -185, -185, + -185, -185, -185, -185, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -185, -185, -185, 28, -185, -185, -185, + -185, -36, -185, -185, -185, -185, -185, -185, -152, -185, + -185, 146, -185, -185, 111, -185, -185, -185, 3, -185, + -185, -185, -185, 89, -185, -185, 245, -66, -185, -185, + -185, -185, 72, -185, -185, -185, -185, -185, -185, -185, + -185, -185, -185, -185, -185, 137, -185, -185, -185, -185, + -185, -185, 110, -185, -185, 70, -185, -185, 236, 27, + -184, -185, -185, -185, -17, -185, -185, -81, -185, -185, + -185, -113, -185, -126, -185 +}; + + /* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int16 yydefgoto[] = +{ + -1, 56, 57, 58, 59, 60, 128, 120, 121, 284, + 352, 353, 354, 355, 356, 357, 358, 61, 62, 63, + 64, 85, 232, 233, 65, 198, 199, 200, 201, 66, + 171, 115, 238, 304, 305, 306, 374, 67, 260, 328, + 101, 102, 103, 139, 140, 141, 68, 248, 249, 250, + 251, 69, 166, 167, 168, 70, 94, 95, 96, 97, + 71, 184, 185, 186, 72, 73, 74, 75, 76, 105, + 170, 377, 279, 335, 126, 127, 77, 78, 290, 224, + 79, 154, 155, 209, 205, 206, 207, 145, 129, 275, + 217, 80, 81, 293, 294, 295, 361, 362, 393, 363, + 396, 397, 410, 411, 412 +}; + + /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule whose + number is the opposite. If YYTABLE_NINF, syntax error. */ +static const yytype_int16 yytable[] = +{ + 119, 161, 271, 285, 272, 203, 381, 263, 264, 172, + 239, 333, 202, 211, 82, 107, 367, 278, 359, 108, + 215, 395, 298, 221, 160, 86, 273, 83, 234, 87, + 299, 400, 84, 300, 104, 88, 226, 122, 368, 116, + 234, 117, 147, 148, 222, 213, 123, 214, 124, 216, + 240, 241, 242, 243, 98, 291, 292, 156, 125, 227, + 149, 130, 228, 286, 359, 287, 311, 143, 223, 144, + 386, 301, 146, 163, 162, 169, 208, 109, 253, 1, + 173, 334, 118, 210, 212, 218, 89, 219, 2, 220, + 225, 237, 3, 4, 5, 236, 157, 252, 158, 150, + 6, 7, 302, 291, 292, 257, 258, 8, 9, 329, + 330, 10, 261, 11, 255, 12, 13, 369, 382, 14, + 90, 91, 110, 262, 370, 265, 164, 255, 15, 151, + 111, 118, 16, 112, 274, 269, 267, 92, 17, 204, + 18, 371, 99, 277, 229, 230, 244, 100, 268, 19, + 20, 231, 280, 21, 22, 113, 288, 283, 23, 24, + 114, 282, 25, 26, 245, 303, 296, 297, 93, 246, + 247, 27, 131, 132, 133, 134, 307, 289, 159, 375, + 165, 389, 309, 308, 28, 29, 30, 332, 118, 336, + 372, 31, 174, 373, 152, 365, 366, 364, 376, 153, + 32, 379, 380, 135, 33, 136, 34, 137, 35, 36, + 398, 383, 390, 138, 384, 403, 385, 175, 37, 38, + 39, 40, 41, 42, 43, 44, 276, 331, 45, 388, + 46, 394, 418, 392, 399, 176, 395, 402, 177, 47, + 415, 416, 404, 417, 48, 49, 50, 235, 51, 52, + 256, 310, 53, 54, 2, 266, 270, 106, 3, 4, + 5, -6, 55, 254, 259, 142, 6, 7, 405, 406, + 407, 408, 409, 8, 9, 281, 360, 10, 312, 11, + 387, 12, 13, 401, 414, 14, 0, 405, 406, 407, + 408, 409, 0, 0, 15, 378, 413, 0, 16, 0, + 0, 0, 0, 0, 17, 0, 18, 0, 0, 0, + 0, 178, 0, 0, 0, 19, 20, 0, 0, 21, + 22, 0, 0, 0, 23, 24, 0, 0, 25, 26, + 0, 0, 0, 0, 0, 0, 0, 27, 0, 179, + 180, 181, 182, 0, 0, 0, 0, 183, 0, 0, + 28, 29, 30, 0, 0, 0, 0, 31, 0, 0, + 0, 0, 0, 0, 0, 0, 32, 0, 0, 391, + 33, 0, 34, 0, 35, 36, 0, 0, 0, 0, + 0, 0, 0, 0, 37, 38, 39, 40, 41, 42, + 43, 44, 0, 0, 45, 0, 46, 0, 0, 0, + 0, 0, 0, 0, 0, 47, 0, 0, 0, 0, + 48, 49, 50, 0, 51, 52, 0, 2, 53, 54, + 0, 3, 4, 5, 0, 0, 0, -6, 55, 6, + 7, 0, 0, 0, 0, 0, 8, 9, 313, 0, + 10, 0, 11, 0, 12, 13, 314, 0, 14, 0, + 0, 0, 0, 0, 0, 0, 0, 15, 0, 0, + 0, 16, 0, 0, 315, 316, 0, 17, 317, 18, + 0, 0, 0, 337, 318, 0, 0, 0, 19, 20, + 0, 338, 21, 22, 0, 0, 0, 23, 24, 0, + 0, 25, 26, 0, 0, 0, 0, 0, 0, 0, + 27, 319, 320, 0, 0, 321, 322, 0, 323, 324, + 325, 0, 326, 28, 29, 30, 0, 339, 340, 0, + 31, 0, 0, 0, 0, 0, 0, 0, 0, 32, + 0, 0, 0, 33, 341, 34, 187, 35, 36, 0, + 0, 0, 188, 0, 189, 0, 0, 37, 38, 39, + 40, 41, 42, 43, 44, 0, 342, 45, 0, 46, + 0, 0, 0, 0, 343, 0, 344, 327, 47, 0, + 0, 190, 0, 48, 49, 50, 0, 51, 52, 0, + 345, 53, 54, 0, 0, 0, 0, 0, 0, 0, + 0, 55, 0, 0, 0, 0, 0, 346, 347, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 191, 0, 192, 0, 0, 0, 0, 0, 193, + 0, 194, 0, 0, 195, 0, 0, 0, 0, 0, + 0, 0, 0, 348, 0, 349, 0, 0, 0, 0, + 350, 0, 0, 0, 351, 0, 196, 197 +}; + +static const yytype_int16 yycheck[] = +{ + 15, 39, 186, 5, 39, 61, 61, 159, 160, 45, + 3, 62, 50, 57, 183, 20, 4, 201, 146, 24, + 32, 188, 29, 34, 39, 8, 61, 61, 94, 12, + 37, 198, 61, 40, 158, 18, 28, 158, 26, 66, + 106, 68, 7, 8, 55, 60, 158, 62, 158, 61, + 43, 44, 45, 46, 11, 185, 186, 27, 158, 51, + 25, 61, 54, 65, 146, 67, 250, 158, 79, 158, + 198, 78, 61, 42, 61, 158, 61, 82, 122, 1, + 158, 132, 158, 0, 183, 61, 69, 158, 10, 158, + 197, 32, 14, 15, 16, 61, 66, 158, 68, 64, + 22, 23, 109, 185, 186, 61, 158, 29, 30, 261, + 262, 33, 27, 35, 129, 37, 38, 105, 173, 41, + 103, 104, 127, 27, 112, 86, 95, 142, 50, 94, + 135, 158, 54, 138, 169, 171, 61, 120, 60, 195, + 62, 129, 99, 61, 136, 137, 139, 104, 194, 71, + 72, 143, 61, 75, 76, 160, 158, 183, 80, 81, + 165, 61, 84, 85, 157, 172, 61, 158, 151, 162, + 163, 93, 56, 57, 58, 59, 158, 179, 148, 331, + 149, 365, 61, 158, 106, 107, 108, 158, 158, 36, + 178, 113, 6, 181, 159, 194, 158, 183, 27, 164, + 122, 61, 61, 87, 126, 89, 128, 91, 130, 131, + 394, 158, 196, 97, 194, 399, 183, 31, 140, 141, + 142, 143, 144, 145, 146, 147, 198, 265, 150, 197, + 152, 194, 416, 187, 194, 49, 188, 183, 52, 161, + 183, 194, 197, 183, 166, 167, 168, 101, 170, 171, + 139, 248, 174, 175, 10, 166, 184, 12, 14, 15, + 16, 183, 184, 126, 154, 29, 22, 23, 189, 190, + 191, 192, 193, 29, 30, 205, 293, 33, 251, 35, + 361, 37, 38, 396, 410, 41, -1, 189, 190, 191, + 192, 193, -1, -1, 50, 333, 198, -1, 54, -1, + -1, -1, -1, -1, 60, -1, 62, -1, -1, -1, + -1, 125, -1, -1, -1, 71, 72, -1, -1, 75, + 76, -1, -1, -1, 80, 81, -1, -1, 84, 85, + -1, -1, -1, -1, -1, -1, -1, 93, -1, 153, + 154, 155, 156, -1, -1, -1, -1, 161, -1, -1, + 106, 107, 108, -1, -1, -1, -1, 113, -1, -1, + -1, -1, -1, -1, -1, -1, 122, -1, -1, 384, + 126, -1, 128, -1, 130, 131, -1, -1, -1, -1, + -1, -1, -1, -1, 140, 141, 142, 143, 144, 145, + 146, 147, -1, -1, 150, -1, 152, -1, -1, -1, + -1, -1, -1, -1, -1, 161, -1, -1, -1, -1, + 166, 167, 168, -1, 170, 171, -1, 10, 174, 175, + -1, 14, 15, 16, -1, -1, -1, 183, 184, 22, + 23, -1, -1, -1, -1, -1, 29, 30, 47, -1, + 33, -1, 35, -1, 37, 38, 55, -1, 41, -1, + -1, -1, -1, -1, -1, -1, -1, 50, -1, -1, + -1, 54, -1, -1, 73, 74, -1, 60, 77, 62, + -1, -1, -1, 9, 83, -1, -1, -1, 71, 72, + -1, 17, 75, 76, -1, -1, -1, 80, 81, -1, + -1, 84, 85, -1, -1, -1, -1, -1, -1, -1, + 93, 110, 111, -1, -1, 114, 115, -1, 117, 118, + 119, -1, 121, 106, 107, 108, -1, 53, 54, -1, + 113, -1, -1, -1, -1, -1, -1, -1, -1, 122, + -1, -1, -1, 126, 70, 128, 13, 130, 131, -1, + -1, -1, 19, -1, 21, -1, -1, 140, 141, 142, + 143, 144, 145, 146, 147, -1, 92, 150, -1, 152, + -1, -1, -1, -1, 100, -1, 102, 176, 161, -1, + -1, 48, -1, 166, 167, 168, -1, 170, 171, -1, + 116, 174, 175, -1, -1, -1, -1, -1, -1, -1, + -1, 184, -1, -1, -1, -1, -1, 133, 134, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 88, -1, 90, -1, -1, -1, -1, -1, 96, + -1, 98, -1, -1, 101, -1, -1, -1, -1, -1, + -1, -1, -1, 169, -1, 171, -1, -1, -1, -1, + 176, -1, -1, -1, 180, -1, 123, 124 +}; + + /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint16 yystos[] = +{ + 0, 1, 10, 14, 15, 16, 22, 23, 29, 30, + 33, 35, 37, 38, 41, 50, 54, 60, 62, 71, + 72, 75, 76, 80, 81, 84, 85, 93, 106, 107, + 108, 113, 122, 126, 128, 130, 131, 140, 141, 142, + 143, 144, 145, 146, 147, 150, 152, 161, 166, 167, + 168, 170, 171, 174, 175, 184, 200, 201, 202, 203, + 204, 216, 217, 218, 219, 223, 228, 236, 245, 250, + 254, 259, 263, 264, 265, 266, 267, 275, 276, 279, + 290, 291, 183, 61, 61, 220, 8, 12, 18, 69, + 103, 104, 120, 151, 255, 256, 257, 258, 11, 99, + 104, 239, 240, 241, 158, 268, 255, 20, 24, 82, + 127, 135, 138, 160, 165, 230, 66, 68, 158, 205, + 206, 207, 158, 158, 158, 158, 273, 274, 205, 287, + 61, 56, 57, 58, 59, 87, 89, 91, 97, 242, + 243, 244, 287, 158, 158, 286, 61, 7, 8, 25, + 64, 94, 159, 164, 280, 281, 27, 66, 68, 148, + 205, 206, 61, 42, 95, 149, 251, 252, 253, 158, + 269, 229, 230, 158, 6, 31, 49, 52, 125, 153, + 154, 155, 156, 161, 260, 261, 262, 13, 19, 21, + 48, 88, 90, 96, 98, 101, 123, 124, 224, 225, + 226, 227, 206, 61, 195, 283, 284, 285, 61, 282, + 0, 202, 183, 205, 205, 32, 61, 289, 61, 158, + 158, 34, 55, 79, 278, 197, 28, 51, 54, 136, + 137, 143, 221, 222, 256, 240, 61, 32, 231, 3, + 43, 44, 45, 46, 139, 157, 162, 163, 246, 247, + 248, 249, 158, 202, 274, 205, 243, 61, 158, 281, + 237, 27, 27, 237, 237, 86, 252, 61, 194, 230, + 261, 289, 39, 61, 169, 288, 225, 61, 289, 271, + 61, 284, 61, 183, 208, 5, 65, 67, 158, 179, + 277, 185, 186, 292, 293, 294, 61, 158, 29, 37, + 40, 78, 109, 172, 232, 233, 234, 158, 158, 61, + 247, 289, 288, 47, 55, 73, 74, 77, 83, 110, + 111, 114, 115, 117, 118, 119, 121, 176, 238, 237, + 237, 206, 158, 62, 132, 272, 36, 9, 17, 53, + 54, 70, 92, 100, 102, 116, 133, 134, 169, 171, + 176, 180, 209, 210, 211, 212, 213, 214, 215, 146, + 293, 295, 296, 298, 183, 194, 158, 4, 26, 105, + 112, 129, 178, 181, 235, 237, 27, 270, 206, 61, + 61, 61, 173, 158, 194, 183, 198, 296, 197, 289, + 196, 205, 187, 297, 194, 188, 299, 300, 289, 194, + 198, 300, 183, 289, 197, 189, 190, 191, 192, 193, + 301, 302, 303, 198, 302, 183, 194, 183, 289 +}; + + /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint16 yyr1[] = +{ + 0, 199, 200, 201, 201, 201, 202, 202, 202, 202, + 202, 202, 202, 202, 202, 202, 202, 202, 202, 202, + 203, 204, 204, 204, 204, 204, 205, 205, 206, 207, + 207, 208, 208, 209, 209, 209, 210, 211, 211, 211, + 211, 211, 211, 211, 211, 212, 212, 213, 213, 213, + 213, 213, 213, 214, 215, 216, 217, 217, 218, 218, + 218, 218, 219, 219, 219, 219, 219, 219, 219, 219, + 219, 220, 220, 221, 221, 222, 222, 222, 222, 222, + 223, 224, 224, 225, 225, 225, 226, 226, 226, 226, + 226, 226, 227, 227, 227, 227, 228, 228, 228, 229, + 229, 230, 230, 230, 230, 230, 230, 230, 230, 231, + 231, 232, 232, 232, 232, 233, 233, 234, 234, 235, + 235, 235, 235, 235, 235, 235, 236, 236, 236, 236, + 236, 236, 236, 236, 237, 237, 238, 238, 238, 238, + 238, 238, 238, 238, 238, 238, 238, 238, 238, 238, + 238, 239, 239, 240, 241, 241, 241, 242, 242, 243, + 244, 244, 244, 244, 244, 244, 244, 244, 245, 246, + 246, 247, 247, 247, 247, 247, 248, 248, 249, 249, + 249, 249, 250, 251, 251, 252, 253, 253, 253, 254, + 254, 255, 255, 256, 256, 257, 257, 257, 257, 257, + 257, 258, 258, 259, 260, 260, 261, 262, 262, 262, + 262, 262, 262, 262, 262, 262, 262, 263, 263, 263, + 263, 263, 263, 263, 263, 263, 263, 263, 263, 263, + 263, 264, 264, 264, 265, 265, 266, 266, 267, 267, + 267, 268, 268, 268, 269, 270, 270, 271, 271, 272, + 272, 273, 273, 274, 275, 275, 276, 276, 277, 277, + 277, 277, 278, 278, 278, 279, 280, 280, 281, 281, + 281, 281, 281, 281, 281, 282, 282, 283, 283, 284, + 284, 285, 286, 286, 287, 287, 288, 288, 288, 289, + 289, 290, 291, 292, 292, 293, 294, 294, 295, 295, + 296, 297, 298, 299, 299, 300, 301, 301, 302, 303, + 303, 303, 303, 303 +}; + + /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 1, 3, 2, 2, 0, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 3, 1, 1, 1, 1, 1, 1, 2, 1, 1, + 1, 0, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, + 1, 1, 1, 2, 1, 2, 1, 1, 1, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 0, 2, 2, 2, 1, 1, 1, 1, 1, + 2, 2, 1, 2, 2, 2, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 2, 2, 3, 2, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, + 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 2, 2, 3, 5, + 3, 4, 4, 3, 0, 2, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 2, 1, 2, 1, 1, 1, 2, 1, 2, + 1, 1, 1, 1, 1, 1, 1, 1, 3, 2, + 1, 2, 2, 2, 2, 2, 1, 1, 1, 1, + 1, 1, 2, 2, 1, 2, 1, 1, 1, 2, + 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 2, 2, 1, 2, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, + 2, 2, 2, 3, 1, 2, 2, 2, 2, 3, + 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 2, 0, 4, 1, 0, 0, 2, 2, + 2, 2, 1, 1, 3, 3, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, + 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, + 1, 5, 2, 1, 2, 1, 1, 1, 1, 1, + 1, 5, 1, 3, 2, 3, 1, 1, 2, 1, + 5, 4, 3, 2, 1, 6, 3, 2, 3, 1, + 1, 1, 1, 1 +}; + + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + YYPOPSTACK (yylen); \ + yystate = *yyssp; \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (0) + +/* Error token number */ +#define YYTERROR 1 +#define YYERRCODE 256 + + + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (0) + +/* This macro is provided for backward compatibility. */ +#ifndef YY_LOCATION_PRINT +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +#endif + + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (0) + + +/*----------------------------------------. +| Print this symbol's value on YYOUTPUT. | +`----------------------------------------*/ + +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +{ + FILE *yyo = yyoutput; + YYUSE (yyo); + if (!yyvaluep) + return; +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# endif + YYUSE (yytype); +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +{ + YYFPRINTF (yyoutput, "%s %s (", + yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]); + + yy_symbol_value_print (yyoutput, yytype, yyvaluep); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (0) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +static void +yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule) +{ + unsigned long int yylno = yyrline[yyrule]; + int yynrhs = yyr2[yyrule]; + int yyi; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, + yystos[yyssp[yyi + 1 - yynrhs]], + &(yyvsp[(yyi + 1) - (yynrhs)]) + ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyssp, yyvsp, Rule); \ +} while (0) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +static YYSIZE_T +yystrlen (const char *yystr) +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +static char * +yystpcpy (char *yydest, const char *yysrc) +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message + about the unexpected token YYTOKEN for the state stack whose top is + YYSSP. + + Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is + not large enough to hold the message. In that case, also set + *YYMSG_ALLOC to the required number of bytes. Return 2 if the + required number of bytes is too large to store. */ +static int +yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, + yytype_int16 *yyssp, int yytoken) +{ + YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]); + YYSIZE_T yysize = yysize0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + /* Internationalized format string. */ + const char *yyformat = YY_NULLPTR; + /* Arguments of yyformat. */ + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + /* Number of reported tokens (one for the "unexpected", one per + "expected"). */ + int yycount = 0; + + /* There are many possibilities here to consider: + - If this state is a consistent state with a default action, then + the only way this function was invoked is if the default action + is an error action. In that case, don't check for expected + tokens because there are none. + - The only way there can be no lookahead present (in yychar) is if + this state is a consistent state with a default action. Thus, + detecting the absence of a lookahead is sufficient to determine + that there is no unexpected or expected token to report. In that + case, just report a simple "syntax error". + - Don't assume there isn't a lookahead just because this state is a + consistent state with a default action. There might have been a + previous inconsistent state, consistent state with a non-default + action, or user semantic action that manipulated yychar. + - Of course, the expected token list depends on states to have + correct lookahead information, and it depends on the parser not + to perform extra reductions after fetching a lookahead from the + scanner and before detecting a syntax error. Thus, state merging + (from LALR or IELR) and default reductions corrupt the expected + token list. However, the list is correct for canonical LR with + one exception: it will still contain any token that will not be + accepted due to an error action in a later state. + */ + if (yytoken != YYEMPTY) + { + int yyn = yypact[*yyssp]; + yyarg[yycount++] = yytname[yytoken]; + if (!yypact_value_is_default (yyn)) + { + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. In other words, skip the first -YYN actions for + this state because they are default actions. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yyx; + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR + && !yytable_value_is_error (yytable[yyx + yyn])) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + break; + } + yyarg[yycount++] = yytname[yyx]; + { + YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]); + if (! (yysize <= yysize1 + && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + } + } + } + + switch (yycount) + { +# define YYCASE_(N, S) \ + case N: \ + yyformat = S; \ + break + YYCASE_(0, YY_("syntax error")); + YYCASE_(1, YY_("syntax error, unexpected %s")); + YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); + YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); + YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); + YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); +# undef YYCASE_ + } + + { + YYSIZE_T yysize1 = yysize + yystrlen (yyformat); + if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + + if (*yymsg_alloc < yysize) + { + *yymsg_alloc = 2 * yysize; + if (! (yysize <= *yymsg_alloc + && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) + *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; + return 1; + } + + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + { + char *yyp = *yymsg; + int yyi = 0; + while ((*yyp = *yyformat) != '\0') + if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyformat += 2; + } + else + { + yyp++; + yyformat++; + } + } + return 0; +} +#endif /* YYERROR_VERBOSE */ + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +{ + YYUSE (yyvaluep); + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN + YYUSE (yytype); + YY_IGNORE_MAYBE_UNINITIALIZED_END +} + + + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; +/* Number of syntax errors so far. */ +int yynerrs; + + +/*----------. +| yyparse. | +`----------*/ + +int +yyparse (void) +{ + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + 'yyss': related to states. + 'yyvs': related to semantic values. + + Refer to the stacks through separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken = 0; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yyssp = yyss = yyssa; + yyvsp = yyvs = yyvsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yypact_value_is_default (yyn)) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = yylex (); + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yytable_value_is_error (yyn)) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN + *++yyvsp = yylval; + YY_IGNORE_MAYBE_UNINITIALIZED_END + + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + '$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 5: +#line 373 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + /* I will need to incorporate much more fine grained + * error messages. The following should suffice for + * the time being. + */ + struct FILE_INFO * ip_ctx = lex_current(); + msyslog(LOG_ERR, + "syntax error in %s line %d, column %d", + ip_ctx->fname, + ip_ctx->errpos.nline, + ip_ctx->errpos.ncol); + } +#line 2106 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 20: +#line 409 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + peer_node *my_node; + + my_node = create_peer_node((yyvsp[-2].Integer), (yyvsp[-1].Address_node), (yyvsp[0].Attr_val_fifo)); + APPEND_G_FIFO(cfgt.peers, my_node); + } +#line 2117 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 27: +#line 428 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Address_node) = create_address_node((yyvsp[0].String), (yyvsp[-1].Integer)); } +#line 2123 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 28: +#line 433 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Address_node) = create_address_node((yyvsp[0].String), AF_UNSPEC); } +#line 2129 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 29: +#line 438 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Integer) = AF_INET; } +#line 2135 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 30: +#line 440 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Integer) = AF_INET6; } +#line 2141 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 31: +#line 445 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val_fifo) = NULL; } +#line 2147 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 32: +#line 447 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2156 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 36: +#line 461 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[0].Integer)); } +#line 2162 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 45: +#line 477 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 2168 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 46: +#line 479 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_uval((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 2174 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 53: +#line 493 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_sval((yyvsp[-1].Integer), (yyvsp[0].String)); } +#line 2180 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 55: +#line 507 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + unpeer_node *my_node; + + my_node = create_unpeer_node((yyvsp[0].Address_node)); + if (my_node) + APPEND_G_FIFO(cfgt.unpeers, my_node); + } +#line 2192 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 58: +#line 528 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.broadcastclient = 1; } +#line 2198 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 59: +#line 530 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.manycastserver, (yyvsp[0].Address_fifo)); } +#line 2204 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 60: +#line 532 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.multicastclient, (yyvsp[0].Address_fifo)); } +#line 2210 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 61: +#line 534 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.mdnstries = (yyvsp[0].Integer); } +#line 2216 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 62: +#line 545 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + attr_val *atrv; + + atrv = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); + APPEND_G_FIFO(cfgt.vars, atrv); + } +#line 2227 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 63: +#line 552 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.auth.control_key = (yyvsp[0].Integer); } +#line 2233 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 64: +#line 554 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + cfgt.auth.cryptosw++; + CONCAT_G_FIFOS(cfgt.auth.crypto_cmd_list, (yyvsp[0].Attr_val_fifo)); + } +#line 2242 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 65: +#line 559 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.auth.keys = (yyvsp[0].String); } +#line 2248 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 66: +#line 561 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.auth.keysdir = (yyvsp[0].String); } +#line 2254 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 67: +#line 563 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.auth.request_key = (yyvsp[0].Integer); } +#line 2260 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 68: +#line 565 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.auth.revoke = (yyvsp[0].Integer); } +#line 2266 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 69: +#line 567 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + cfgt.auth.trusted_key_list = (yyvsp[0].Attr_val_fifo); + + // if (!cfgt.auth.trusted_key_list) + // cfgt.auth.trusted_key_list = $2; + // else + // LINK_SLIST(cfgt.auth.trusted_key_list, $2, link); + } +#line 2279 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 70: +#line 576 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { cfgt.auth.ntp_signd_socket = (yyvsp[0].String); } +#line 2285 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 71: +#line 581 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val_fifo) = NULL; } +#line 2291 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 72: +#line 583 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2300 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 73: +#line 591 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_sval((yyvsp[-1].Integer), (yyvsp[0].String)); } +#line 2306 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 74: +#line 593 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val) = NULL; + cfgt.auth.revoke = (yyvsp[0].Integer); + msyslog(LOG_WARNING, + "'crypto revoke %d' is deprecated, " + "please use 'revoke %d' instead.", + cfgt.auth.revoke, cfgt.auth.revoke); + } +#line 2319 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 80: +#line 618 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.orphan_cmds, (yyvsp[0].Attr_val_fifo)); } +#line 2325 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 81: +#line 623 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2334 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 82: +#line 628 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2343 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 83: +#line 636 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_dval((yyvsp[-1].Integer), (double)(yyvsp[0].Integer)); } +#line 2349 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 84: +#line 638 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_dval((yyvsp[-1].Integer), (yyvsp[0].Double)); } +#line 2355 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 85: +#line 640 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_dval((yyvsp[-1].Integer), (double)(yyvsp[0].Integer)); } +#line 2361 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 96: +#line 666 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.stats_list, (yyvsp[0].Int_fifo)); } +#line 2367 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 97: +#line 668 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (lex_from_file()) { + cfgt.stats_dir = (yyvsp[0].String); + } else { + YYFREE((yyvsp[0].String)); + yyerror("statsdir remote configuration ignored"); + } + } +#line 2380 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 98: +#line 677 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + filegen_node *fgn; + + fgn = create_filegen_node((yyvsp[-1].Integer), (yyvsp[0].Attr_val_fifo)); + APPEND_G_FIFO(cfgt.filegen_opts, fgn); + } +#line 2391 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 99: +#line 687 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Int_fifo) = (yyvsp[-1].Int_fifo); + APPEND_G_FIFO((yyval.Int_fifo), create_int_node((yyvsp[0].Integer))); + } +#line 2400 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 100: +#line 692 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Int_fifo) = NULL; + APPEND_G_FIFO((yyval.Int_fifo), create_int_node((yyvsp[0].Integer))); + } +#line 2409 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 109: +#line 711 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val_fifo) = NULL; } +#line 2415 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 110: +#line 713 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2424 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 111: +#line 721 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (lex_from_file()) { + (yyval.Attr_val) = create_attr_sval((yyvsp[-1].Integer), (yyvsp[0].String)); + } else { + (yyval.Attr_val) = NULL; + YYFREE((yyvsp[0].String)); + yyerror("filegen file remote config ignored"); + } + } +#line 2438 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 112: +#line 731 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (lex_from_file()) { + (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); + } else { + (yyval.Attr_val) = NULL; + yyerror("filegen type remote config ignored"); + } + } +#line 2451 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 113: +#line 740 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + const char *err; + + if (lex_from_file()) { + (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[0].Integer)); + } else { + (yyval.Attr_val) = NULL; + if (T_Link == (yyvsp[0].Integer)) + err = "filegen link remote config ignored"; + else + err = "filegen nolink remote config ignored"; + yyerror(err); + } + } +#line 2470 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 114: +#line 755 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[0].Integer)); } +#line 2476 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 126: +#line 785 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + CONCAT_G_FIFOS(cfgt.discard_opts, (yyvsp[0].Attr_val_fifo)); + } +#line 2484 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 127: +#line 789 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + CONCAT_G_FIFOS(cfgt.mru_opts, (yyvsp[0].Attr_val_fifo)); + } +#line 2492 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 128: +#line 793 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + restrict_node *rn; + + rn = create_restrict_node((yyvsp[-1].Address_node), NULL, (yyvsp[0].Int_fifo), + lex_current()->curpos.nline); + APPEND_G_FIFO(cfgt.restrict_opts, rn); + } +#line 2504 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 129: +#line 801 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + restrict_node *rn; + + rn = create_restrict_node((yyvsp[-3].Address_node), (yyvsp[-1].Address_node), (yyvsp[0].Int_fifo), + lex_current()->curpos.nline); + APPEND_G_FIFO(cfgt.restrict_opts, rn); + } +#line 2516 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 130: +#line 809 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + restrict_node *rn; + + rn = create_restrict_node(NULL, NULL, (yyvsp[0].Int_fifo), + lex_current()->curpos.nline); + APPEND_G_FIFO(cfgt.restrict_opts, rn); + } +#line 2528 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 131: +#line 817 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + restrict_node *rn; + + rn = create_restrict_node( + create_address_node( + estrdup("0.0.0.0"), + AF_INET), + create_address_node( + estrdup("0.0.0.0"), + AF_INET), + (yyvsp[0].Int_fifo), + lex_current()->curpos.nline); + APPEND_G_FIFO(cfgt.restrict_opts, rn); + } +#line 2547 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 132: +#line 832 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + restrict_node *rn; + + rn = create_restrict_node( + create_address_node( + estrdup("::"), + AF_INET6), + create_address_node( + estrdup("::"), + AF_INET6), + (yyvsp[0].Int_fifo), + lex_current()->curpos.nline); + APPEND_G_FIFO(cfgt.restrict_opts, rn); + } +#line 2566 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 133: +#line 847 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + restrict_node * rn; + + APPEND_G_FIFO((yyvsp[0].Int_fifo), create_int_node((yyvsp[-1].Integer))); + rn = create_restrict_node( + NULL, NULL, (yyvsp[0].Int_fifo), lex_current()->curpos.nline); + APPEND_G_FIFO(cfgt.restrict_opts, rn); + } +#line 2579 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 134: +#line 859 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Int_fifo) = NULL; } +#line 2585 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 135: +#line 861 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Int_fifo) = (yyvsp[-1].Int_fifo); + APPEND_G_FIFO((yyval.Int_fifo), create_int_node((yyvsp[0].Integer))); + } +#line 2594 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 151: +#line 887 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2603 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 152: +#line 892 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2612 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 153: +#line 900 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 2618 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 157: +#line 911 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2627 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 158: +#line 916 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2636 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 159: +#line 924 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 2642 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 168: +#line 944 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + addr_opts_node *aon; + + aon = create_addr_opts_node((yyvsp[-1].Address_node), (yyvsp[0].Attr_val_fifo)); + APPEND_G_FIFO(cfgt.fudge, aon); + } +#line 2653 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 169: +#line 954 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2662 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 170: +#line 959 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2671 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 171: +#line 967 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_dval((yyvsp[-1].Integer), (yyvsp[0].Double)); } +#line 2677 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 172: +#line 969 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 2683 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 173: +#line 971 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 2689 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 174: +#line 973 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_sval((yyvsp[-1].Integer), (yyvsp[0].String)); } +#line 2695 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 175: +#line 975 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_sval((yyvsp[-1].Integer), (yyvsp[0].String)); } +#line 2701 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 182: +#line 996 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.rlimit, (yyvsp[0].Attr_val_fifo)); } +#line 2707 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 183: +#line 1001 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2716 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 184: +#line 1006 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2725 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 185: +#line 1014 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 2731 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 189: +#line 1030 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.enable_opts, (yyvsp[0].Attr_val_fifo)); } +#line 2737 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 190: +#line 1032 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.disable_opts, (yyvsp[0].Attr_val_fifo)); } +#line 2743 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 191: +#line 1037 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2752 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 192: +#line 1042 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2761 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 193: +#line 1050 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[0].Integer)); } +#line 2767 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 194: +#line 1052 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (lex_from_file()) { + (yyval.Attr_val) = create_attr_ival(T_Flag, (yyvsp[0].Integer)); + } else { + char err_str[128]; + + (yyval.Attr_val) = NULL; + snprintf(err_str, sizeof(err_str), + "enable/disable %s remote configuration ignored", + keyword((yyvsp[0].Integer))); + yyerror(err_str); + } + } +#line 2785 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 203: +#line 1087 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.tinker, (yyvsp[0].Attr_val_fifo)); } +#line 2791 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 204: +#line 1092 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2800 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 205: +#line 1097 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 2809 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 206: +#line 1105 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_dval((yyvsp[-1].Integer), (yyvsp[0].Double)); } +#line 2815 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 219: +#line 1130 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + attr_val *av; + + av = create_attr_dval((yyvsp[-1].Integer), (yyvsp[0].Double)); + APPEND_G_FIFO(cfgt.vars, av); + } +#line 2826 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 220: +#line 1137 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + attr_val *av; + + av = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); + APPEND_G_FIFO(cfgt.vars, av); + } +#line 2837 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 221: +#line 1144 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + attr_val *av; + + av = create_attr_sval((yyvsp[-1].Integer), (yyvsp[0].String)); + APPEND_G_FIFO(cfgt.vars, av); + } +#line 2848 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 222: +#line 1151 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + char error_text[64]; + attr_val *av; + + if (lex_from_file()) { + av = create_attr_sval((yyvsp[-1].Integer), (yyvsp[0].String)); + APPEND_G_FIFO(cfgt.vars, av); + } else { + YYFREE((yyvsp[0].String)); + snprintf(error_text, sizeof(error_text), + "%s remote config ignored", + keyword((yyvsp[-1].Integer))); + yyerror(error_text); + } + } +#line 2868 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 223: +#line 1167 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (!lex_from_file()) { + YYFREE((yyvsp[-1].String)); /* avoid leak */ + yyerror("remote includefile ignored"); + break; + } + if (lex_level() > MAXINCLUDELEVEL) { + fprintf(stderr, "getconfig: Maximum include file level exceeded.\n"); + msyslog(LOG_ERR, "getconfig: Maximum include file level exceeded."); + } else { + const char * path = FindConfig((yyvsp[-1].String)); /* might return $2! */ + if (!lex_push_file(path, "r")) { + fprintf(stderr, "getconfig: Couldn't open <%s>\n", path); + msyslog(LOG_ERR, "getconfig: Couldn't open <%s>", path); + } + } + YYFREE((yyvsp[-1].String)); /* avoid leak */ + } +#line 2891 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 224: +#line 1186 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { lex_flush_stack(); } +#line 2897 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 225: +#line 1188 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { /* see drift_parm below for actions */ } +#line 2903 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 226: +#line 1190 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.logconfig, (yyvsp[0].Attr_val_fifo)); } +#line 2909 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 227: +#line 1192 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.phone, (yyvsp[0].String_fifo)); } +#line 2915 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 228: +#line 1194 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { APPEND_G_FIFO(cfgt.setvar, (yyvsp[0].Set_var)); } +#line 2921 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 229: +#line 1196 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + addr_opts_node *aon; + + aon = create_addr_opts_node((yyvsp[-1].Address_node), (yyvsp[0].Attr_val_fifo)); + APPEND_G_FIFO(cfgt.trap, aon); + } +#line 2932 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 230: +#line 1203 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.ttl, (yyvsp[0].Attr_val_fifo)); } +#line 2938 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 235: +#line 1218 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { +#ifndef LEAP_SMEAR + yyerror("Built without LEAP_SMEAR support."); +#endif + } +#line 2948 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 241: +#line 1238 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (lex_from_file()) { + attr_val *av; + av = create_attr_sval(T_Driftfile, (yyvsp[0].String)); + APPEND_G_FIFO(cfgt.vars, av); + } else { + YYFREE((yyvsp[0].String)); + yyerror("driftfile remote configuration ignored"); + } + } +#line 2963 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 242: +#line 1249 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (lex_from_file()) { + attr_val *av; + av = create_attr_sval(T_Driftfile, (yyvsp[-1].String)); + APPEND_G_FIFO(cfgt.vars, av); + av = create_attr_dval(T_WanderThreshold, (yyvsp[0].Double)); + APPEND_G_FIFO(cfgt.vars, av); + } else { + YYFREE((yyvsp[-1].String)); + yyerror("driftfile remote configuration ignored"); + } + } +#line 2980 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 243: +#line 1262 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if (lex_from_file()) { + attr_val *av; + av = create_attr_sval(T_Driftfile, estrdup("")); + APPEND_G_FIFO(cfgt.vars, av); + } else { + yyerror("driftfile remote configuration ignored"); + } + } +#line 2994 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 244: +#line 1275 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Set_var) = create_setvar_node((yyvsp[-3].String), (yyvsp[-1].String), (yyvsp[0].Integer)); } +#line 3000 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 246: +#line 1281 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Integer) = 0; } +#line 3006 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 247: +#line 1286 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val_fifo) = NULL; } +#line 3012 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 248: +#line 1288 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 3021 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 249: +#line 1296 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival((yyvsp[-1].Integer), (yyvsp[0].Integer)); } +#line 3027 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 250: +#line 1298 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val) = create_attr_sval((yyvsp[-1].Integer), estrdup((yyvsp[0].Address_node)->address)); + destroy_address_node((yyvsp[0].Address_node)); + } +#line 3036 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 251: +#line 1306 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 3045 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 252: +#line 1311 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 3054 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 253: +#line 1319 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + char prefix; + char * type; + + switch ((yyvsp[0].String)[0]) { + + case '+': + case '-': + case '=': + prefix = (yyvsp[0].String)[0]; + type = (yyvsp[0].String) + 1; + break; + + default: + prefix = '='; + type = (yyvsp[0].String); + } + + (yyval.Attr_val) = create_attr_sval(prefix, estrdup(type)); + YYFREE((yyvsp[0].String)); + } +#line 3080 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 254: +#line 1344 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + nic_rule_node *nrn; + + nrn = create_nic_rule_node((yyvsp[0].Integer), NULL, (yyvsp[-1].Integer)); + APPEND_G_FIFO(cfgt.nic_rules, nrn); + } +#line 3091 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 255: +#line 1351 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + nic_rule_node *nrn; + + nrn = create_nic_rule_node(0, (yyvsp[0].String), (yyvsp[-1].Integer)); + APPEND_G_FIFO(cfgt.nic_rules, nrn); + } +#line 3102 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 265: +#line 1379 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { CONCAT_G_FIFOS(cfgt.reset_counters, (yyvsp[0].Int_fifo)); } +#line 3108 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 266: +#line 1384 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Int_fifo) = (yyvsp[-1].Int_fifo); + APPEND_G_FIFO((yyval.Int_fifo), create_int_node((yyvsp[0].Integer))); + } +#line 3117 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 267: +#line 1389 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Int_fifo) = NULL; + APPEND_G_FIFO((yyval.Int_fifo), create_int_node((yyvsp[0].Integer))); + } +#line 3126 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 275: +#line 1413 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), create_int_node((yyvsp[0].Integer))); + } +#line 3135 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 276: +#line 1418 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), create_int_node((yyvsp[0].Integer))); + } +#line 3144 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 277: +#line 1426 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-1].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 3153 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 278: +#line 1431 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[0].Attr_val)); + } +#line 3162 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 279: +#line 1439 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_ival('i', (yyvsp[0].Integer)); } +#line 3168 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 281: +#line 1445 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_rangeval('-', (yyvsp[-3].Integer), (yyvsp[-1].Integer)); } +#line 3174 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 282: +#line 1450 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.String_fifo) = (yyvsp[-1].String_fifo); + APPEND_G_FIFO((yyval.String_fifo), create_string_node((yyvsp[0].String))); + } +#line 3183 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 283: +#line 1455 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.String_fifo) = NULL; + APPEND_G_FIFO((yyval.String_fifo), create_string_node((yyvsp[0].String))); + } +#line 3192 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 284: +#line 1463 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Address_fifo) = (yyvsp[-1].Address_fifo); + APPEND_G_FIFO((yyval.Address_fifo), (yyvsp[0].Address_node)); + } +#line 3201 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 285: +#line 1468 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Address_fifo) = NULL; + APPEND_G_FIFO((yyval.Address_fifo), (yyvsp[0].Address_node)); + } +#line 3210 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 286: +#line 1476 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + if ((yyvsp[0].Integer) != 0 && (yyvsp[0].Integer) != 1) { + yyerror("Integer value is not boolean (0 or 1). Assuming 1"); + (yyval.Integer) = 1; + } else { + (yyval.Integer) = (yyvsp[0].Integer); + } + } +#line 3223 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 287: +#line 1484 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Integer) = 1; } +#line 3229 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 288: +#line 1485 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Integer) = 0; } +#line 3235 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 289: +#line 1489 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Double) = (double)(yyvsp[0].Integer); } +#line 3241 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 291: +#line 1500 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + sim_node *sn; + + sn = create_sim_node((yyvsp[-2].Attr_val_fifo), (yyvsp[-1].Sim_server_fifo)); + APPEND_G_FIFO(cfgt.sim_details, sn); + + /* Revert from ; to \n for end-of-command */ + old_config_style = 1; + } +#line 3255 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 292: +#line 1517 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { old_config_style = 0; } +#line 3261 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 293: +#line 1522 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-2].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[-1].Attr_val)); + } +#line 3270 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 294: +#line 1527 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[-1].Attr_val)); + } +#line 3279 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 295: +#line 1535 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_dval((yyvsp[-2].Integer), (yyvsp[0].Double)); } +#line 3285 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 298: +#line 1545 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Sim_server_fifo) = (yyvsp[-1].Sim_server_fifo); + APPEND_G_FIFO((yyval.Sim_server_fifo), (yyvsp[0].Sim_server)); + } +#line 3294 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 299: +#line 1550 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Sim_server_fifo) = NULL; + APPEND_G_FIFO((yyval.Sim_server_fifo), (yyvsp[0].Sim_server)); + } +#line 3303 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 300: +#line 1558 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Sim_server) = ONLY_SIM(create_sim_server((yyvsp[-4].Address_node), (yyvsp[-2].Double), (yyvsp[-1].Sim_script_fifo))); } +#line 3309 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 301: +#line 1563 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Double) = (yyvsp[-1].Double); } +#line 3315 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 302: +#line 1568 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Address_node) = (yyvsp[0].Address_node); } +#line 3321 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 303: +#line 1573 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Sim_script_fifo) = (yyvsp[-1].Sim_script_fifo); + APPEND_G_FIFO((yyval.Sim_script_fifo), (yyvsp[0].Sim_script)); + } +#line 3330 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 304: +#line 1578 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Sim_script_fifo) = NULL; + APPEND_G_FIFO((yyval.Sim_script_fifo), (yyvsp[0].Sim_script)); + } +#line 3339 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 305: +#line 1586 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Sim_script) = ONLY_SIM(create_sim_script_info((yyvsp[-3].Double), (yyvsp[-1].Attr_val_fifo))); } +#line 3345 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 306: +#line 1591 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = (yyvsp[-2].Attr_val_fifo); + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[-1].Attr_val)); + } +#line 3354 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 307: +#line 1596 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { + (yyval.Attr_val_fifo) = NULL; + APPEND_G_FIFO((yyval.Attr_val_fifo), (yyvsp[-1].Attr_val)); + } +#line 3363 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + case 308: +#line 1604 "../../ntpd/ntp_parser.y" /* yacc.c:1646 */ + { (yyval.Attr_val) = create_attr_dval((yyvsp[-2].Integer), (yyvsp[0].Double)); } +#line 3369 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + break; + + +#line 3373 "../../ntpd/ntp_parser.c" /* yacc.c:1646 */ + default: break; + } + /* User semantic actions sometimes alter yychar, and that requires + that yytoken be updated with the new translation. We take the + approach of translating immediately before every use of yytoken. + One alternative is translating here after every semantic action, + but that translation would be missed if the semantic action invokes + YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or + if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an + incorrect destructor might then be invoked immediately. In the + case of YYERROR or YYBACKUP, subsequent parser actions might lead + to an incorrect destructor call or verbose syntax error message + before the lookahead is translated. */ + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + + /* Now 'shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*--------------------------------------. +| yyerrlab -- here on detecting error. | +`--------------------------------------*/ +yyerrlab: + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); + + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else +# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ + yyssp, yytoken) + { + char const *yymsgp = YY_("syntax error"); + int yysyntax_error_status; + yysyntax_error_status = YYSYNTAX_ERROR; + if (yysyntax_error_status == 0) + yymsgp = yymsg; + else if (yysyntax_error_status == 1) + { + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); + if (!yymsg) + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + yysyntax_error_status = 2; + } + else + { + yysyntax_error_status = YYSYNTAX_ERROR; + yymsgp = yymsg; + } + } + yyerror (yymsgp); + if (yysyntax_error_status == 2) + goto yyexhaustedlab; + } +# undef YYSYNTAX_ERROR +#endif + } + + + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + /* Do not reclaim the symbols of the rule whose action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (!yypact_value_is_default (yyn)) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + + yydestruct ("Error: popping", + yystos[yystate], yyvsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN + *++yyvsp = yylval; + YY_IGNORE_MAYBE_UNINITIALIZED_END + + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined yyoverflow || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + { + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = YYTRANSLATE (yychar); + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + } + /* Do not reclaim the symbols of the rule whose action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + return yyresult; +} +#line 1615 "../../ntpd/ntp_parser.y" /* yacc.c:1906 */ + + +void +yyerror( + const char *msg + ) +{ + int retval; + struct FILE_INFO * ip_ctx; + + ip_ctx = lex_current(); + ip_ctx->errpos = ip_ctx->tokpos; + + msyslog(LOG_ERR, "line %d column %d %s", + ip_ctx->errpos.nline, ip_ctx->errpos.ncol, msg); + if (!lex_from_file()) { + /* Save the error message in the correct buffer */ + retval = snprintf(remote_config.err_msg + remote_config.err_pos, + MAXLINE - remote_config.err_pos, + "column %d %s", + ip_ctx->errpos.ncol, msg); + + /* Increment the value of err_pos */ + if (retval > 0) + remote_config.err_pos += retval; + + /* Increment the number of errors */ + ++remote_config.no_errors; + } +} + + +/* + * token_name - convert T_ token integers to text + * example: token_name(T_Server) returns "T_Server" + */ +const char * +token_name( + int token + ) +{ + return yytname[YYTRANSLATE(token)]; +} + + +/* Initial Testing function -- ignore */ +#if 0 +int main(int argc, char *argv[]) +{ + ip_file = FOPEN(argv[1], "r"); + if (!ip_file) + fprintf(stderr, "ERROR!! Could not open file: %s\n", argv[1]); + yyparse(); + return 0; +} +#endif + diff --git a/contrib/ntp/ntpd/ntp_parser.h b/contrib/ntp/ntpd/ntp_parser.h new file mode 100644 index 000000000..1ec7f8cc6 --- /dev/null +++ b/contrib/ntp/ntpd/ntp_parser.h @@ -0,0 +1,469 @@ +/* A Bison parser, made by GNU Bison 3.0.2. */ + +/* Bison interface for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +#ifndef YY_YY__NTPD_NTP_PARSER_H_INCLUDED +# define YY_YY__NTPD_NTP_PARSER_H_INCLUDED +/* Debug traces. */ +#ifndef YYDEBUG +# define YYDEBUG 1 +#endif +#if YYDEBUG +extern int yydebug; +#endif + +/* Token type. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + enum yytokentype + { + T_Abbrev = 258, + T_Age = 259, + T_All = 260, + T_Allan = 261, + T_Allpeers = 262, + T_Auth = 263, + T_Autokey = 264, + T_Automax = 265, + T_Average = 266, + T_Bclient = 267, + T_Beacon = 268, + T_Broadcast = 269, + T_Broadcastclient = 270, + T_Broadcastdelay = 271, + T_Burst = 272, + T_Calibrate = 273, + T_Ceiling = 274, + T_Clockstats = 275, + T_Cohort = 276, + T_ControlKey = 277, + T_Crypto = 278, + T_Cryptostats = 279, + T_Ctl = 280, + T_Day = 281, + T_Default = 282, + T_Digest = 283, + T_Disable = 284, + T_Discard = 285, + T_Dispersion = 286, + T_Double = 287, + T_Driftfile = 288, + T_Drop = 289, + T_Dscp = 290, + T_Ellipsis = 291, + T_Enable = 292, + T_End = 293, + T_False = 294, + T_File = 295, + T_Filegen = 296, + T_Filenum = 297, + T_Flag1 = 298, + T_Flag2 = 299, + T_Flag3 = 300, + T_Flag4 = 301, + T_Flake = 302, + T_Floor = 303, + T_Freq = 304, + T_Fudge = 305, + T_Host = 306, + T_Huffpuff = 307, + T_Iburst = 308, + T_Ident = 309, + T_Ignore = 310, + T_Incalloc = 311, + T_Incmem = 312, + T_Initalloc = 313, + T_Initmem = 314, + T_Includefile = 315, + T_Integer = 316, + T_Interface = 317, + T_Intrange = 318, + T_Io = 319, + T_Ipv4 = 320, + T_Ipv4_flag = 321, + T_Ipv6 = 322, + T_Ipv6_flag = 323, + T_Kernel = 324, + T_Key = 325, + T_Keys = 326, + T_Keysdir = 327, + T_Kod = 328, + T_Mssntp = 329, + T_Leapfile = 330, + T_Leapsmearinterval = 331, + T_Limited = 332, + T_Link = 333, + T_Listen = 334, + T_Logconfig = 335, + T_Logfile = 336, + T_Loopstats = 337, + T_Lowpriotrap = 338, + T_Manycastclient = 339, + T_Manycastserver = 340, + T_Mask = 341, + T_Maxage = 342, + T_Maxclock = 343, + T_Maxdepth = 344, + T_Maxdist = 345, + T_Maxmem = 346, + T_Maxpoll = 347, + T_Mdnstries = 348, + T_Mem = 349, + T_Memlock = 350, + T_Minclock = 351, + T_Mindepth = 352, + T_Mindist = 353, + T_Minimum = 354, + T_Minpoll = 355, + T_Minsane = 356, + T_Mode = 357, + T_Mode7 = 358, + T_Monitor = 359, + T_Month = 360, + T_Mru = 361, + T_Multicastclient = 362, + T_Nic = 363, + T_Nolink = 364, + T_Nomodify = 365, + T_Nomrulist = 366, + T_None = 367, + T_Nonvolatile = 368, + T_Nopeer = 369, + T_Noquery = 370, + T_Noselect = 371, + T_Noserve = 372, + T_Notrap = 373, + T_Notrust = 374, + T_Ntp = 375, + T_Ntpport = 376, + T_NtpSignDsocket = 377, + T_Orphan = 378, + T_Orphanwait = 379, + T_Panic = 380, + T_Peer = 381, + T_Peerstats = 382, + T_Phone = 383, + T_Pid = 384, + T_Pidfile = 385, + T_Pool = 386, + T_Port = 387, + T_Preempt = 388, + T_Prefer = 389, + T_Protostats = 390, + T_Pw = 391, + T_Randfile = 392, + T_Rawstats = 393, + T_Refid = 394, + T_Requestkey = 395, + T_Reset = 396, + T_Restrict = 397, + T_Revoke = 398, + T_Rlimit = 399, + T_Saveconfigdir = 400, + T_Server = 401, + T_Setvar = 402, + T_Source = 403, + T_Stacksize = 404, + T_Statistics = 405, + T_Stats = 406, + T_Statsdir = 407, + T_Step = 408, + T_Stepback = 409, + T_Stepfwd = 410, + T_Stepout = 411, + T_Stratum = 412, + T_String = 413, + T_Sys = 414, + T_Sysstats = 415, + T_Tick = 416, + T_Time1 = 417, + T_Time2 = 418, + T_Timer = 419, + T_Timingstats = 420, + T_Tinker = 421, + T_Tos = 422, + T_Trap = 423, + T_True = 424, + T_Trustedkey = 425, + T_Ttl = 426, + T_Type = 427, + T_U_int = 428, + T_Unconfig = 429, + T_Unpeer = 430, + T_Version = 431, + T_WanderThreshold = 432, + T_Week = 433, + T_Wildcard = 434, + T_Xleave = 435, + T_Year = 436, + T_Flag = 437, + T_EOC = 438, + T_Simulate = 439, + T_Beep_Delay = 440, + T_Sim_Duration = 441, + T_Server_Offset = 442, + T_Duration = 443, + T_Freq_Offset = 444, + T_Wander = 445, + T_Jitter = 446, + T_Prop_Delay = 447, + T_Proc_Delay = 448 + }; +#endif +/* Tokens. */ +#define T_Abbrev 258 +#define T_Age 259 +#define T_All 260 +#define T_Allan 261 +#define T_Allpeers 262 +#define T_Auth 263 +#define T_Autokey 264 +#define T_Automax 265 +#define T_Average 266 +#define T_Bclient 267 +#define T_Beacon 268 +#define T_Broadcast 269 +#define T_Broadcastclient 270 +#define T_Broadcastdelay 271 +#define T_Burst 272 +#define T_Calibrate 273 +#define T_Ceiling 274 +#define T_Clockstats 275 +#define T_Cohort 276 +#define T_ControlKey 277 +#define T_Crypto 278 +#define T_Cryptostats 279 +#define T_Ctl 280 +#define T_Day 281 +#define T_Default 282 +#define T_Digest 283 +#define T_Disable 284 +#define T_Discard 285 +#define T_Dispersion 286 +#define T_Double 287 +#define T_Driftfile 288 +#define T_Drop 289 +#define T_Dscp 290 +#define T_Ellipsis 291 +#define T_Enable 292 +#define T_End 293 +#define T_False 294 +#define T_File 295 +#define T_Filegen 296 +#define T_Filenum 297 +#define T_Flag1 298 +#define T_Flag2 299 +#define T_Flag3 300 +#define T_Flag4 301 +#define T_Flake 302 +#define T_Floor 303 +#define T_Freq 304 +#define T_Fudge 305 +#define T_Host 306 +#define T_Huffpuff 307 +#define T_Iburst 308 +#define T_Ident 309 +#define T_Ignore 310 +#define T_Incalloc 311 +#define T_Incmem 312 +#define T_Initalloc 313 +#define T_Initmem 314 +#define T_Includefile 315 +#define T_Integer 316 +#define T_Interface 317 +#define T_Intrange 318 +#define T_Io 319 +#define T_Ipv4 320 +#define T_Ipv4_flag 321 +#define T_Ipv6 322 +#define T_Ipv6_flag 323 +#define T_Kernel 324 +#define T_Key 325 +#define T_Keys 326 +#define T_Keysdir 327 +#define T_Kod 328 +#define T_Mssntp 329 +#define T_Leapfile 330 +#define T_Leapsmearinterval 331 +#define T_Limited 332 +#define T_Link 333 +#define T_Listen 334 +#define T_Logconfig 335 +#define T_Logfile 336 +#define T_Loopstats 337 +#define T_Lowpriotrap 338 +#define T_Manycastclient 339 +#define T_Manycastserver 340 +#define T_Mask 341 +#define T_Maxage 342 +#define T_Maxclock 343 +#define T_Maxdepth 344 +#define T_Maxdist 345 +#define T_Maxmem 346 +#define T_Maxpoll 347 +#define T_Mdnstries 348 +#define T_Mem 349 +#define T_Memlock 350 +#define T_Minclock 351 +#define T_Mindepth 352 +#define T_Mindist 353 +#define T_Minimum 354 +#define T_Minpoll 355 +#define T_Minsane 356 +#define T_Mode 357 +#define T_Mode7 358 +#define T_Monitor 359 +#define T_Month 360 +#define T_Mru 361 +#define T_Multicastclient 362 +#define T_Nic 363 +#define T_Nolink 364 +#define T_Nomodify 365 +#define T_Nomrulist 366 +#define T_None 367 +#define T_Nonvolatile 368 +#define T_Nopeer 369 +#define T_Noquery 370 +#define T_Noselect 371 +#define T_Noserve 372 +#define T_Notrap 373 +#define T_Notrust 374 +#define T_Ntp 375 +#define T_Ntpport 376 +#define T_NtpSignDsocket 377 +#define T_Orphan 378 +#define T_Orphanwait 379 +#define T_Panic 380 +#define T_Peer 381 +#define T_Peerstats 382 +#define T_Phone 383 +#define T_Pid 384 +#define T_Pidfile 385 +#define T_Pool 386 +#define T_Port 387 +#define T_Preempt 388 +#define T_Prefer 389 +#define T_Protostats 390 +#define T_Pw 391 +#define T_Randfile 392 +#define T_Rawstats 393 +#define T_Refid 394 +#define T_Requestkey 395 +#define T_Reset 396 +#define T_Restrict 397 +#define T_Revoke 398 +#define T_Rlimit 399 +#define T_Saveconfigdir 400 +#define T_Server 401 +#define T_Setvar 402 +#define T_Source 403 +#define T_Stacksize 404 +#define T_Statistics 405 +#define T_Stats 406 +#define T_Statsdir 407 +#define T_Step 408 +#define T_Stepback 409 +#define T_Stepfwd 410 +#define T_Stepout 411 +#define T_Stratum 412 +#define T_String 413 +#define T_Sys 414 +#define T_Sysstats 415 +#define T_Tick 416 +#define T_Time1 417 +#define T_Time2 418 +#define T_Timer 419 +#define T_Timingstats 420 +#define T_Tinker 421 +#define T_Tos 422 +#define T_Trap 423 +#define T_True 424 +#define T_Trustedkey 425 +#define T_Ttl 426 +#define T_Type 427 +#define T_U_int 428 +#define T_Unconfig 429 +#define T_Unpeer 430 +#define T_Version 431 +#define T_WanderThreshold 432 +#define T_Week 433 +#define T_Wildcard 434 +#define T_Xleave 435 +#define T_Year 436 +#define T_Flag 437 +#define T_EOC 438 +#define T_Simulate 439 +#define T_Beep_Delay 440 +#define T_Sim_Duration 441 +#define T_Server_Offset 442 +#define T_Duration 443 +#define T_Freq_Offset 444 +#define T_Wander 445 +#define T_Jitter 446 +#define T_Prop_Delay 447 +#define T_Proc_Delay 448 + +/* Value type. */ +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE YYSTYPE; +union YYSTYPE +{ +#line 51 "../../ntpd/ntp_parser.y" /* yacc.c:1909 */ + + char * String; + double Double; + int Integer; + unsigned U_int; + gen_fifo * Generic_fifo; + attr_val * Attr_val; + attr_val_fifo * Attr_val_fifo; + int_fifo * Int_fifo; + string_fifo * String_fifo; + address_node * Address_node; + address_fifo * Address_fifo; + setvar_node * Set_var; + server_info * Sim_server; + server_info_fifo * Sim_server_fifo; + script_info * Sim_script; + script_info_fifo * Sim_script_fifo; + +#line 459 "../../ntpd/ntp_parser.h" /* yacc.c:1909 */ +}; +# define YYSTYPE_IS_TRIVIAL 1 +# define YYSTYPE_IS_DECLARED 1 +#endif + + +extern YYSTYPE yylval; + +int yyparse (void); + +#endif /* !YY_YY__NTPD_NTP_PARSER_H_INCLUDED */ diff --git a/contrib/ntp/ntpd/ntp_peer.c b/contrib/ntp/ntpd/ntp_peer.c index deeec5bc3..cc23a3823 100644 --- a/contrib/ntp/ntpd/ntp_peer.c +++ b/contrib/ntp/ntpd/ntp_peer.c @@ -9,19 +9,14 @@ #include #include "ntpd.h" +#include "ntp_lists.h" #include "ntp_stdlib.h" +#include "ntp_control.h" #include -#ifdef OPENSSL -#include "openssl/rand.h" -#endif /* OPENSSL */ - -#ifdef SYS_WINNT -extern int accept_wildcard_if_for_winnt; -#endif /* - * Table of valid association combinations - * --------------------------------------- + * Table of valid association combinations + * --------------------------------------- * * packet->mode * peer->mode | UNSPEC ACTIVE PASSIVE CLIENT SERVER BCAST @@ -29,7 +24,7 @@ extern int accept_wildcard_if_for_winnt; * NO_PEER | e 1 0 1 1 1 * ACTIVE | e 1 1 0 0 0 * PASSIVE | e 1 e 0 0 0 - * CLIENT | e 0 0 0 1 1 + * CLIENT | e 0 0 0 1 0 * SERVER | e 0 0 0 0 0 * BCAST | e 0 0 0 0 0 * BCLIENT | e 0 0 0 e 1 @@ -45,15 +40,16 @@ extern int accept_wildcard_if_for_winnt; #define NO_PEER 0 /* action when no peer is found */ int AM[AM_MODES][AM_MODES] = { -/* { UNSPEC, ACTIVE, PASSIVE, CLIENT, SERVER, BCAST } */ - +/* packet->mode */ +/* peer { UNSPEC, ACTIVE, PASSIVE, CLIENT, SERVER, BCAST } */ +/* mode */ /*NONE*/{ AM_ERR, AM_NEWPASS, AM_NOMATCH, AM_FXMIT, AM_MANYCAST, AM_NEWBCL}, /*A*/ { AM_ERR, AM_PROCPKT, AM_PROCPKT, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH}, /*P*/ { AM_ERR, AM_PROCPKT, AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH}, -/*C*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_PROCPKT, AM_POSSBCL}, +/*C*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_PROCPKT, AM_NOMATCH}, /*S*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH}, @@ -62,53 +58,70 @@ int AM[AM_MODES][AM_MODES] = { /*BCL*/ { AM_ERR, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_NOMATCH, AM_PROCPKT}, }; -#define MATCH_ASSOC(x,y) AM[(x)][(y)] +#define MATCH_ASSOC(x, y) AM[(x)][(y)] /* * These routines manage the allocation of memory to peer structures - * and the maintenance of the peer hash table. The two main entry - * points are findpeer(), which looks for matching peer sturctures in - * the peer list, newpeer(), which allocates a new peer structure and - * adds it to the list, and unpeer(), which demobilizes the association - * and deallocates the structure. + * and the maintenance of three data structures involving all peers: + * + * - peer_list is a single list with all peers, suitable for scanning + * operations over all peers. + * - peer_adr_hash is an array of lists indexed by hashed peer address. + * - peer_aid_hash is an array of lists indexed by hashed associd. + * + * They also maintain a free list of peer structures, peer_free. + * + * The three main entry points are findpeer(), which looks for matching + * peer structures in the peer list, newpeer(), which allocates a new + * peer structure and adds it to the list, and unpeer(), which + * demobilizes the association and deallocates the structure. */ /* * Peer hash tables */ struct peer *peer_hash[NTP_HASH_SIZE]; /* peer hash table */ -int peer_hash_count[NTP_HASH_SIZE]; /* peers in each bucket */ +int peer_hash_count[NTP_HASH_SIZE]; /* peers in each bucket */ struct peer *assoc_hash[NTP_HASH_SIZE]; /* association ID hash table */ -int assoc_hash_count[NTP_HASH_SIZE]; /* peers in each bucket */ +int assoc_hash_count[NTP_HASH_SIZE];/* peers in each bucket */ +struct peer *peer_list; /* peer structures list */ static struct peer *peer_free; /* peer structures free list */ -int peer_free_count; /* count of free structures */ +int peer_free_count; /* count of free structures */ /* * Association ID. We initialize this value randomly, then assign a new - * value every time the peer structure is incremented. + * value every time an association is mobilized. */ static associd_t current_association_ID; /* association ID */ +static associd_t initial_association_ID; /* association ID */ /* * Memory allocation watermarks. */ -#define INIT_PEER_ALLOC 15 /* initialize for 15 peers */ -#define INC_PEER_ALLOC 5 /* when run out, add 5 more */ +#define INIT_PEER_ALLOC 8 /* static preallocation */ +#define INC_PEER_ALLOC 4 /* add N more when empty */ /* * Miscellaneous statistic counters which may be queried. */ -u_long peer_timereset; /* time stat counters zeroed */ -u_long findpeer_calls; /* calls to findpeer */ -u_long assocpeer_calls; /* calls to findpeerbyassoc */ -u_long peer_allocations; /* allocations from free list */ -u_long peer_demobilizations; /* structs freed to free list */ -int total_peer_structs; /* peer structs */ -int peer_associations; /* mobilized associations */ -int peer_preempt; /* preemptable associations */ +u_long peer_timereset; /* time stat counters zeroed */ +u_long findpeer_calls; /* calls to findpeer */ +u_long assocpeer_calls; /* calls to findpeerbyassoc */ +u_long peer_allocations; /* allocations from free list */ +u_long peer_demobilizations; /* structs freed to free list */ +int total_peer_structs; /* peer structs */ +int peer_associations; /* mobilized associations */ +int peer_preempt; /* preemptable associations */ static struct peer init_peer_alloc[INIT_PEER_ALLOC]; /* init alloc */ -static void getmorepeermem P((void)); -static struct interface *select_peerinterface P((struct peer *, struct sockaddr_storage *, struct interface *, u_char)); +static struct peer * findexistingpeer_name(const char *, u_short, + struct peer *, int); +static struct peer * findexistingpeer_addr(sockaddr_u *, + struct peer *, int, + u_char); +static void free_peer(struct peer *, int); +static void getmorepeermem(void); +static int score(struct peer *); + /* * init_peer - initialize peer data structures and counters @@ -119,39 +132,23 @@ static struct interface *select_peerinterface P((struct peer *, struct sockaddr_ void init_peer(void) { - register int i; - - /* - * Clear hash table and counters. - */ - for (i = 0; i < NTP_HASH_SIZE; i++) { - peer_hash[i] = 0; - peer_hash_count[i] = 0; - assoc_hash[i] = 0; - assoc_hash_count[i] = 0; - } - - /* - * Clear stat counters - */ - findpeer_calls = peer_allocations = 0; - assocpeer_calls = peer_demobilizations = 0; + int i; /* - * Initialize peer memory. + * Initialize peer free list from static allocation. */ - peer_free = 0; - for (i = 0; i < INIT_PEER_ALLOC; i++) { - init_peer_alloc[i].next = peer_free; - peer_free = &init_peer_alloc[i]; - } - total_peer_structs = INIT_PEER_ALLOC; - peer_free_count = INIT_PEER_ALLOC; + for (i = COUNTOF(init_peer_alloc) - 1; i >= 0; i--) + LINK_SLIST(peer_free, &init_peer_alloc[i], p_link); + total_peer_structs = COUNTOF(init_peer_alloc); + peer_free_count = COUNTOF(init_peer_alloc); /* * Initialize our first association ID */ - while ((current_association_ID = ntp_random() & 0xffff) == 0); + do + current_association_ID = ntp_random() & ASSOCID_MAX; + while (!current_association_ID); + initial_association_ID = current_association_ID; } @@ -161,90 +158,172 @@ init_peer(void) static void getmorepeermem(void) { - register int i; - register struct peer *peer; - - peer = (struct peer *)emalloc(INC_PEER_ALLOC * - sizeof(struct peer)); - for (i = 0; i < INC_PEER_ALLOC; i++) { - peer->next = peer_free; - peer_free = peer; - peer++; - } + int i; + struct peer *peers; + + peers = emalloc_zero(INC_PEER_ALLOC * sizeof(*peers)); + + for (i = INC_PEER_ALLOC - 1; i >= 0; i--) + LINK_SLIST(peer_free, &peers[i], p_link); total_peer_structs += INC_PEER_ALLOC; peer_free_count += INC_PEER_ALLOC; } -/* - * findexistingpeer - return a pointer to a peer in the hash table - */ -struct peer * -findexistingpeer( - struct sockaddr_storage *addr, - struct peer *start_peer, - int mode +static struct peer * +findexistingpeer_name( + const char * hostname, + u_short hname_fam, + struct peer * start_peer, + int mode + ) +{ + struct peer *p; + + if (NULL == start_peer) + p = peer_list; + else + p = start_peer->p_link; + for (; p != NULL; p = p->p_link) + if (p->hostname != NULL + && (-1 == mode || p->hmode == mode) + && (AF_UNSPEC == hname_fam + || AF_UNSPEC == AF(&p->srcadr) + || hname_fam == AF(&p->srcadr)) + && !strcasecmp(p->hostname, hostname)) + break; + return p; +} + + +static +struct peer * +findexistingpeer_addr( + sockaddr_u * addr, + struct peer * start_peer, + int mode, + u_char cast_flags ) { - register struct peer *peer; + struct peer *peer; + + DPRINTF(2, ("findexistingpeer_addr(%s, %s, %d, 0x%x)\n", + sptoa(addr), + (start_peer) + ? sptoa(&start_peer->srcadr) + : "NULL", + mode, (u_int)cast_flags)); /* * start_peer is included so we can locate instances of the * same peer through different interfaces in the hash table. + * Without MDF_BCLNT, a match requires the same mode and remote + * address. MDF_BCLNT associations start out as MODE_CLIENT + * if broadcastdelay is not specified, and switch to + * MODE_BCLIENT after estimating the one-way delay. Duplicate + * associations are expanded in definition to match any other + * MDF_BCLNT with the same srcadr (remote, unicast address). */ - if (start_peer == 0) + if (NULL == start_peer) peer = peer_hash[NTP_HASH_ADDR(addr)]; else - peer = start_peer->next; + peer = start_peer->adr_link; - while (peer != 0) { - if (SOCKCMP(addr, &peer->srcadr) - && NSRCPORT(addr) == NSRCPORT(&peer->srcadr)) { - if (mode == -1) - return (peer); - else if (peer->hmode == mode) - break; + while (peer != NULL) { + DPRINTF(3, ("%s %s %d %d 0x%x 0x%x ", sptoa(addr), + sptoa(&peer->srcadr), mode, peer->hmode, + (u_int)cast_flags, (u_int)peer->cast_flags)); + if ((-1 == mode || peer->hmode == mode || + ((MDF_BCLNT & peer->cast_flags) && + (MDF_BCLNT & cast_flags))) && + ADDR_PORT_EQ(addr, &peer->srcadr)) { + DPRINTF(3, ("found.\n")); + break; } - peer = peer->next; + DPRINTF(3, ("\n")); + peer = peer->adr_link; } - return (peer); + + return peer; +} + + +/* + * findexistingpeer - search by address and return a pointer to a peer. + */ +struct peer * +findexistingpeer( + sockaddr_u * addr, + const char * hostname, + struct peer * start_peer, + int mode, + u_char cast_flags + ) +{ + if (hostname != NULL) + return findexistingpeer_name(hostname, AF(addr), + start_peer, mode); + else + return findexistingpeer_addr(addr, start_peer, mode, + cast_flags); } /* - * findpeer - find and return a peer in the hash table. + * findpeer - find and return a peer match for a received datagram in + * the peer_hash table. */ struct peer * findpeer( - struct sockaddr_storage *srcadr, - struct interface *dstadr, - int pkt_mode, - int *action + struct recvbuf *rbufp, + int pkt_mode, + int * action ) { - register struct peer *peer; - int hash; + struct peer * p; + sockaddr_u * srcadr; + u_int hash; + struct pkt * pkt; + l_fp pkt_org; findpeer_calls++; + srcadr = &rbufp->recv_srcadr; hash = NTP_HASH_ADDR(srcadr); - for (peer = peer_hash[hash]; peer != NULL; peer = peer->next) { - if (SOCKCMP(srcadr, &peer->srcadr) && - NSRCPORT(srcadr) == NSRCPORT(&peer->srcadr)) { + for (p = peer_hash[hash]; p != NULL; p = p->adr_link) { + if (ADDR_PORT_EQ(srcadr, &p->srcadr)) { /* * if the association matching rules determine * that this is not a valid combination, then * look for the next valid peer association. */ - *action = MATCH_ASSOC(peer->hmode, pkt_mode); + *action = MATCH_ASSOC(p->hmode, pkt_mode); + + /* + * A response to our manycastclient solicitation + * might be misassociated with an ephemeral peer + * already spun for the server. If the packet's + * org timestamp doesn't match the peer's, check + * if it matches the ACST prototype peer's. If + * so it is a redundant solicitation response, + * return AM_ERR to discard it. [Bug 1762] + */ + if (MODE_SERVER == pkt_mode && + AM_PROCPKT == *action) { + pkt = &rbufp->recv_pkt; + NTOHL_FP(&pkt->org, &pkt_org); + if (!L_ISEQU(&p->aorg, &pkt_org) && + findmanycastpeer(rbufp)) + *action = AM_ERR; + } /* * if an error was returned, exit back right * here. */ if (*action == AM_ERR) - return ((struct peer *)0); + return NULL; /* * if a match is found, we stop our search. @@ -257,36 +336,36 @@ findpeer( /* * If no matching association is found */ - if (peer == 0) { + if (NULL == p) { *action = MATCH_ASSOC(NO_PEER, pkt_mode); - return ((struct peer *)0); + } else if (p->dstadr != rbufp->dstadr) { + set_peerdstadr(p, rbufp->dstadr); + if (p->dstadr == rbufp->dstadr) { + DPRINTF(1, ("Changed %s local address to match response\n", + stoa(&p->srcadr))); + return findpeer(rbufp, pkt_mode, action); + } } - - set_peerdstadr(peer, dstadr); - - return (peer); + return p; } /* - * findpeerbyassocid - find and return a peer using his association ID + * findpeerbyassoc - find and return a peer using his association ID */ struct peer * findpeerbyassoc( - u_int assoc + associd_t assoc ) { - register struct peer *peer; - int hash; + struct peer *p; + u_int hash; assocpeer_calls++; - hash = assoc & NTP_HASH_MASK; - for (peer = assoc_hash[hash]; peer != 0; peer = - peer->ass_next) { - if (assoc == peer->associd) - return (peer); - } - return (NULL); + for (p = assoc_hash[hash]; p != NULL; p = p->aid_link) + if (assoc == p->associd) + break; + return p; } @@ -296,27 +375,148 @@ findpeerbyassoc( void clear_all(void) { - struct peer *peer, *next_peer; - int n; + struct peer *p; /* * This routine is called when the clock is stepped, and so all * previously saved time values are untrusted. */ - for (n = 0; n < NTP_HASH_SIZE; n++) { - for (peer = peer_hash[n]; peer != 0; peer = next_peer) { - next_peer = peer->next; - if (!(peer->cast_flags & (MDF_ACAST | MDF_MCAST | - MDF_BCAST))) { - peer->hpoll = peer->minpoll; - peer_clear(peer, "STEP"); - } + for (p = peer_list; p != NULL; p = p->p_link) + if (!(MDF_TXONLY_MASK & p->cast_flags)) + peer_clear(p, "STEP"); + + DPRINTF(1, ("clear_all: at %lu\n", current_time)); +} + + +/* + * score_all() - determine if an association can be demobilized + */ +int +score_all( + struct peer *peer /* peer structure pointer */ + ) +{ + struct peer *speer; + int temp, tamp; + int x; + + /* + * This routine finds the minimum score for all preemptible + * associations and returns > 0 if the association can be + * demobilized. + */ + tamp = score(peer); + temp = 100; + for (speer = peer_list; speer != NULL; speer = speer->p_link) + if (speer->flags & FLAG_PREEMPT) { + x = score(speer); + if (x < temp) + temp = x; + } + DPRINTF(1, ("score_all: at %lu score %d min %d\n", + current_time, tamp, temp)); + + if (tamp != temp) + temp = 0; + + return temp; +} + + +/* + * score() - calculate preemption score + */ +static int +score( + struct peer *peer /* peer structure pointer */ + ) +{ + int temp; + + /* + * This routine calculates the premption score from the peer + * error bits and status. Increasing values are more cherished. + */ + temp = 0; + if (!(peer->flash & TEST10)) + temp++; /* 1 good synch and stratum */ + if (!(peer->flash & TEST13)) + temp++; /* 2 reachable */ + if (!(peer->flash & TEST12)) + temp++; /* 3 no loop */ + if (!(peer->flash & TEST11)) + temp++; /* 4 good distance */ + if (peer->status >= CTL_PST_SEL_SELCAND) + temp++; /* 5 in the hunt */ + if (peer->status != CTL_PST_SEL_EXCESS) + temp++; /* 6 not spare tire */ + return (temp); /* selection status */ +} + + +/* + * free_peer - internal routine to free memory referred to by a struct + * peer and return it to the peer free list. If unlink is + * nonzero, unlink from the various lists. + */ +static void +free_peer( + struct peer * p, + int unlink_peer + ) +{ + struct peer * unlinked; + int hash; + + if (unlink_peer) { + hash = NTP_HASH_ADDR(&p->srcadr); + peer_hash_count[hash]--; + + UNLINK_SLIST(unlinked, peer_hash[hash], p, adr_link, + struct peer); + if (NULL == unlinked) { + peer_hash_count[hash]++; + msyslog(LOG_ERR, "peer %s not in address table!", + stoa(&p->srcadr)); + } + + /* + * Remove him from the association hash as well. + */ + hash = p->associd & NTP_HASH_MASK; + assoc_hash_count[hash]--; + + UNLINK_SLIST(unlinked, assoc_hash[hash], p, aid_link, + struct peer); + if (NULL == unlinked) { + assoc_hash_count[hash]++; + msyslog(LOG_ERR, + "peer %s not in association ID table!", + stoa(&p->srcadr)); } + + /* Remove him from the overall list. */ + UNLINK_SLIST(unlinked, peer_list, p, p_link, + struct peer); + if (NULL == unlinked) + msyslog(LOG_ERR, "%s not in peer list!", + stoa(&p->srcadr)); } -#ifdef DEBUG - if (debug) - printf("clear_all: at %lu\n", current_time); -#endif + + if (p->hostname != NULL) + free(p->hostname); + + if (p->ident != NULL) + free(p->ident); + + if (p->addrs != NULL) + free(p->addrs); /* from copy_addrinfo_list() */ + + /* Add his corporeal form to peer free list */ + ZERO(*p); + LINK_SLIST(peer_free, p, p_link); + peer_free_count++; } @@ -325,91 +525,25 @@ clear_all(void) */ void unpeer( - struct peer *peer_to_remove + struct peer *peer ) { - int hash; -#ifdef OPENSSL - char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ - - if (peer_to_remove->flags & FLAG_SKEY) { - sprintf(statstr, "unpeer %d flash %x reach %03o flags %04x", - peer_to_remove->associd, peer_to_remove->flash, - peer_to_remove->reach, peer_to_remove->flags); - record_crypto_stats(&peer_to_remove->srcadr, statstr); -#ifdef DEBUG - if (debug) - printf("peer: %s\n", statstr); -#endif - } -#endif /* OPENSSL */ -#ifdef DEBUG - if (debug) - printf("demobilize %u %d %d\n", peer_to_remove->associd, - peer_associations, peer_preempt); -#endif - set_peerdstadr(peer_to_remove, NULL); - - /* XXXMEMLEAK? peer_clear->crypto allocation */ - - hash = NTP_HASH_ADDR(&peer_to_remove->srcadr); - peer_hash_count[hash]--; + mprintf_event(PEVNT_DEMOBIL, peer, "assoc %u", peer->associd); + restrict_source(&peer->srcadr, 1, 0); + set_peerdstadr(peer, NULL); peer_demobilizations++; peer_associations--; - if (peer_to_remove->flags & FLAG_PREEMPT) + if (FLAG_PREEMPT & peer->flags) peer_preempt--; #ifdef REFCLOCK /* * If this peer is actually a clock, shut it down first */ - if (peer_to_remove->flags & FLAG_REFCLOCK) - refclock_unpeer(peer_to_remove); + if (FLAG_REFCLOCK & peer->flags) + refclock_unpeer(peer); #endif - peer_to_remove->action = 0; /* disable timeout actions */ - if (peer_hash[hash] == peer_to_remove) - peer_hash[hash] = peer_to_remove->next; - else { - register struct peer *peer; - - peer = peer_hash[hash]; - while (peer != 0 && peer->next != peer_to_remove) - peer = peer->next; - - if (peer == 0) { - peer_hash_count[hash]++; - msyslog(LOG_ERR, "peer struct for %s not in table!", - stoa(&peer->srcadr)); - } else { - peer->next = peer_to_remove->next; - } - } - /* - * Remove him from the association hash as well. - */ - hash = peer_to_remove->associd & NTP_HASH_MASK; - assoc_hash_count[hash]--; - if (assoc_hash[hash] == peer_to_remove) - assoc_hash[hash] = peer_to_remove->ass_next; - else { - register struct peer *peer; - - peer = assoc_hash[hash]; - while (peer != 0 && peer->ass_next != peer_to_remove) - peer = peer->ass_next; - - if (peer == 0) { - assoc_hash_count[hash]++; - msyslog(LOG_ERR, - "peer struct for %s not in association table!", - stoa(&peer->srcadr)); - } else { - peer->ass_next = peer_to_remove->ass_next; - } - } - peer_to_remove->next = peer_free; - peer_free = peer_to_remove; - peer_free_count++; + free_peer(peer, TRUE); } @@ -418,152 +552,98 @@ unpeer( */ struct peer * peer_config( - struct sockaddr_storage *srcadr, - struct interface *dstadr, - int hmode, - int version, - int minpoll, - int maxpoll, - u_int flags, - int ttl, - keyid_t key, - u_char *keystr + sockaddr_u * srcadr, + const char * hostname, + endpt * dstadr, + u_char hmode, + u_char version, + u_char minpoll, + u_char maxpoll, + u_int flags, + u_int32 ttl, + keyid_t key, + const char * ident /* autokey group */ ) { - register struct peer *peer; u_char cast_flags; - /* - * First search from the beginning for an association with given - * remote address and mode. If an interface is given, search - * from there to find the association which matches that - * destination. If the given interface is "any", track down - * the actual interface, because that's what gets put into the - * peer structure. - */ - peer = findexistingpeer(srcadr, (struct peer *)0, hmode); - if (dstadr != 0) { - while (peer != 0) { - if (peer->dstadr == dstadr) - break; - if (dstadr == ANY_INTERFACE_CHOOSE(srcadr) && - peer->dstadr == findinterface(srcadr)) - break; - peer = findexistingpeer(srcadr, peer, hmode); - } - } - /* * We do a dirty little jig to figure the cast flags. This is * probably not the best place to do this, at least until the * configure code is rebuilt. Note only one flag can be set. */ switch (hmode) { - case MODE_BROADCAST: - if(srcadr->ss_family == AF_INET) { - if (IN_CLASSD(ntohl(((struct sockaddr_in*)srcadr)->sin_addr.s_addr))) - cast_flags = MDF_MCAST; - else - cast_flags = MDF_BCAST; - break; - } - else { - if (IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)srcadr)->sin6_addr)) - cast_flags = MDF_MCAST; - else - cast_flags = MDF_BCAST; - break; - } + if (IS_MCAST(srcadr)) + cast_flags = MDF_MCAST; + else + cast_flags = MDF_BCAST; + break; case MODE_CLIENT: - if(srcadr->ss_family == AF_INET) { - if (IN_CLASSD(ntohl(((struct sockaddr_in*)srcadr)->sin_addr.s_addr))) - cast_flags = MDF_ACAST; - else - cast_flags = MDF_UCAST; - break; - } - else { - if (IN6_IS_ADDR_MULTICAST(&((struct sockaddr_in6*)srcadr)->sin6_addr)) - cast_flags = MDF_ACAST; - else - cast_flags = MDF_UCAST; - break; - } + if (hostname != NULL && SOCK_UNSPEC(srcadr)) + cast_flags = MDF_POOL; + else if (IS_MCAST(srcadr)) + cast_flags = MDF_ACAST; + else + cast_flags = MDF_UCAST; + break; default: cast_flags = MDF_UCAST; } /* - * If the peer is already configured, some dope has a duplicate - * configureation entry or another dope is wiggling from afar. - */ - if (peer != 0) { - peer->hmode = (u_char)hmode; - peer->version = (u_char) version; - peer->minpoll = (u_char) minpoll; - peer->maxpoll = (u_char) maxpoll; - peer->flags = flags | FLAG_CONFIG | - (peer->flags & FLAG_REFCLOCK); - peer->cast_flags = cast_flags; - peer->ttl = (u_char) ttl; - peer->keyid = key; - peer->precision = sys_precision; - peer_clear(peer, "RMOT"); - return (peer); - } - - /* - * Here no match has been found, so presumably this is a new - * persistent association. Mobilize the thing and initialize its - * variables. If emulating ntpdate, force iburst. + * Mobilize the association and initialize its variables. If + * emulating ntpdate, force iburst. For pool and manycastclient + * strip FLAG_PREEMPT as the prototype associations are not + * themselves preemptible, though the resulting associations + * are. */ + flags |= FLAG_CONFIG; if (mode_ntpdate) flags |= FLAG_IBURST; - peer = newpeer(srcadr, dstadr, hmode, version, minpoll, maxpoll, - flags | FLAG_CONFIG, cast_flags, ttl, key); - return (peer); + if ((MDF_ACAST | MDF_POOL) & cast_flags) + flags &= ~FLAG_PREEMPT; + return newpeer(srcadr, hostname, dstadr, hmode, version, + minpoll, maxpoll, flags, cast_flags, ttl, key, ident); } /* - * setup peer dstadr field keeping it in sync with the interface structures + * setup peer dstadr field keeping it in sync with the interface + * structures */ void -set_peerdstadr(struct peer *peer, struct interface *interface) +set_peerdstadr( + struct peer * p, + endpt * dstadr + ) { - if (peer->dstadr != interface) { - if (interface != NULL && - (peer->cast_flags & MDF_BCLNT) && - (interface->flags & INT_MCASTIF) && - peer->burst) { - /* - * don't accept updates to a true multicast reception - * interface while a BCLNT peer is running it's - * unicast protocol - */ - return; - } - - if (peer->dstadr != NULL) - { - peer->dstadr->peercnt--; - ISC_LIST_UNLINK_TYPE(peer->dstadr->peers, peer, ilink, struct peer); - } - - DPRINTF(4, ("set_peerdstadr(%s): change interface from %s to %s\n", - stoa(&peer->srcadr), - (peer->dstadr != NULL) ? stoa(&peer->dstadr->sin) : "", - (interface != NULL) ? stoa(&interface->sin) : "")); + struct peer * unlinked; - peer->dstadr = interface; + if (p->dstadr == dstadr) + return; - if (peer->dstadr != NULL) - { - ISC_LIST_APPEND(peer->dstadr->peers, peer, ilink); - peer->dstadr->peercnt++; - } + /* + * Don't accept updates to a separate multicast receive-only + * endpt while a BCLNT peer is running its unicast protocol. + */ + if (dstadr != NULL && (FLAG_BC_VOL & p->flags) && + (INT_MCASTIF & dstadr->flags) && MODE_CLIENT == p->hmode) { + return; + } + if (p->dstadr != NULL) { + p->dstadr->peercnt--; + UNLINK_SLIST(unlinked, p->dstadr->peers, p, ilink, + struct peer); + msyslog(LOG_INFO, "%s local addr %s -> %s", + stoa(&p->srcadr), latoa(p->dstadr), + latoa(dstadr)); + } + p->dstadr = dstadr; + if (dstadr != NULL) { + LINK_SLIST(dstadr->peers, p, ilink); + dstadr->peercnt++; } } @@ -571,176 +651,170 @@ set_peerdstadr(struct peer *peer, struct interface *interface) * attempt to re-rebind interface if necessary */ static void -peer_refresh_interface(struct peer *peer) +peer_refresh_interface( + struct peer *p + ) { - struct interface *niface, *piface; - - niface = select_peerinterface(peer, &peer->srcadr, NULL, peer->cast_flags); - -#ifdef DEBUG - if (debug > 3) - { - printf( - "peer_refresh_interface: %s->%s mode %d vers %d poll %d %d flags 0x%x 0x%x ttl %d key %08x: new interface: ", - peer->dstadr == NULL ? "" : stoa(&peer->dstadr->sin), - stoa(&peer->srcadr), - peer->hmode, peer->version, peer->minpoll, - peer->maxpoll, peer->flags, peer->cast_flags, - peer->ttl, peer->keyid); - if (niface != NULL) - { - printf("fd=%d, bfd=%d, name=%.16s, flags=0x%x, scope=%d, ", - niface->fd, - niface->bfd, - niface->name, - niface->flags, - niface->scopeid); - /* Leave these as three printf calls. */ - printf(", sin=%s", - stoa((&niface->sin))); - if (niface->flags & INT_BROADCAST) - printf(", bcast=%s,", - stoa((&niface->bcast))); - printf(", mask=%s\n", - stoa((&niface->mask))); - } - else - { - printf("\n"); - } + endpt * niface; + endpt * piface; + + niface = select_peerinterface(p, &p->srcadr, NULL); + + DPRINTF(4, ( + "peer_refresh_interface: %s->%s mode %d vers %d poll %d %d flags 0x%x 0x%x ttl %u key %08x: new interface: ", + p->dstadr == NULL ? "" : + stoa(&p->dstadr->sin), stoa(&p->srcadr), p->hmode, + p->version, p->minpoll, p->maxpoll, p->flags, p->cast_flags, + p->ttl, p->keyid)); + if (niface != NULL) { + DPRINTF(4, ( + "fd=%d, bfd=%d, name=%.16s, flags=0x%x, ifindex=%u, sin=%s", + niface->fd, niface->bfd, niface->name, + niface->flags, niface->ifindex, + stoa(&niface->sin))); + if (niface->flags & INT_BROADCAST) + DPRINTF(4, (", bcast=%s", + stoa(&niface->bcast))); + DPRINTF(4, (", mask=%s\n", stoa(&niface->mask))); + } else { + DPRINTF(4, ("\n")); } -#endif - piface = peer->dstadr; - - set_peerdstadr(peer, niface); - - if (peer->dstadr) { - /* - * clear crypto if we change the local address - */ - if (peer->dstadr != piface && !(peer->cast_flags & MDF_BCLNT)) { - peer_crypto_clear(peer); - } + piface = p->dstadr; + set_peerdstadr(p, niface); + if (p->dstadr != NULL) { + /* + * clear crypto if we change the local address + */ + if (p->dstadr != piface && !(MDF_ACAST & p->cast_flags) + && MODE_BROADCAST != p->pmode) + peer_clear(p, "XFAC"); /* * Broadcast needs the socket enabled for broadcast */ - if (peer->cast_flags & MDF_BCAST) { - enable_broadcast(peer->dstadr, &peer->srcadr); - } + if (MDF_BCAST & p->cast_flags) + enable_broadcast(p->dstadr, &p->srcadr); /* - * Multicast needs the socket interface enabled for multicast + * Multicast needs the socket interface enabled for + * multicast */ - if (peer->cast_flags & MDF_MCAST) { - enable_multicast_if(peer->dstadr, &peer->srcadr); - } + if (MDF_MCAST & p->cast_flags) + enable_multicast_if(p->dstadr, &p->srcadr); } } + /* - * refresh_all_peerinterfaces - see that all interface bindings are up to date + * refresh_all_peerinterfaces - see that all interface bindings are up + * to date */ void refresh_all_peerinterfaces(void) { - struct peer *peer, *next_peer; - int n; + struct peer *p; /* * this is called when the interface list has changed * give all peers a chance to find a better interface + * but only if either they don't have an address already + * or if the one they have hasn't worked for a while. */ - for (n = 0; n < NTP_HASH_SIZE; n++) { - for (peer = peer_hash[n]; peer != 0; peer = next_peer) { - next_peer = peer->next; - peer_refresh_interface(peer); - } + for (p = peer_list; p != NULL; p = p->p_link) { + if (!(p->dstadr && (p->reach & 0x3))) // Bug 2849 XOR 2043 + peer_refresh_interface(p); } } - + /* - * find an interface suitable for the src address + * newpeer - initialize a new peer association */ -static struct interface * -select_peerinterface(struct peer *peer, struct sockaddr_storage *srcadr, struct interface *dstadr, u_char cast_flags) +struct peer * +newpeer( + sockaddr_u * srcadr, + const char * hostname, + endpt * dstadr, + u_char hmode, + u_char version, + u_char minpoll, + u_char maxpoll, + u_int flags, + u_char cast_flags, + u_int32 ttl, + keyid_t key, + const char * ident + ) { - struct interface *interface; - + struct peer * peer; + u_int hash; + + DEBUG_REQUIRE(srcadr); + +#ifdef AUTOKEY /* - * Initialize the peer structure and dance the interface jig. - * Reference clocks step the loopback waltz, the others - * squaredance around the interface list looking for a buddy. If - * the dance peters out, there is always the wildcard interface. - * This might happen in some systems and would preclude proper - * operation with public key cryptography. + * If Autokey is requested but not configured, complain loudly. */ - if (ISREFCLOCKADR(srcadr)) - interface = loopback_interface; - else - if (cast_flags & (MDF_BCLNT | MDF_ACAST | MDF_MCAST | MDF_BCAST)) { - interface = findbcastinter(srcadr); -#ifdef DEBUG - if (debug > 3) { - if (interface != NULL) - printf("Found *-cast interface address %s, for address %s\n", - stoa(&(interface)->sin), stoa(srcadr)); - else - printf("No *-cast local address found for address %s\n", - stoa(srcadr)); - } -#endif - /* - * If it was a multicast packet, findbcastinter() may not - * find it, so try a little harder. - */ - if (interface == ANY_INTERFACE_CHOOSE(srcadr)) - interface = findinterface(srcadr); - } - else if (dstadr != NULL && dstadr != ANY_INTERFACE_CHOOSE(srcadr)) - interface = dstadr; - else - interface = findinterface(srcadr); + if (!crypto_flags) { + if (key > NTP_MAXKEY) { + return (NULL); + + } else if (flags & FLAG_SKEY) { + msyslog(LOG_ERR, "Autokey not configured"); + return (NULL); + } + } +#endif /* AUTOKEY */ /* - * we do not bind to the wildcard interfaces for output - * as our (network) source address would be undefined and - * crypto will not work without knowing the own transmit address + * For now only pool associations have a hostname. */ - if (interface != NULL && interface->flags & INT_WILDCARD) -#ifdef SYS_WINNT - if ( !accept_wildcard_if_for_winnt ) -#endif - interface = NULL; + INSIST(NULL == hostname || (MDF_POOL & cast_flags)); + /* + * First search from the beginning for an association with given + * remote address and mode. If an interface is given, search + * from there to find the association which matches that + * destination. If the given interface is "any", track down the + * actual interface, because that's what gets put into the peer + * structure. + */ + if (dstadr != NULL) { + peer = findexistingpeer(srcadr, hostname, NULL, hmode, + cast_flags); + while (peer != NULL) { + if (peer->dstadr == dstadr || + ((MDF_BCLNT & cast_flags) && + (MDF_BCLNT & peer->cast_flags))) + break; - return interface; -} + if (dstadr == ANY_INTERFACE_CHOOSE(srcadr) && + peer->dstadr == findinterface(srcadr)) + break; -/* - * newpeer - initialize a new peer association - */ -struct peer * -newpeer( - struct sockaddr_storage *srcadr, - struct interface *dstadr, - int hmode, - int version, - int minpoll, - int maxpoll, - u_int flags, - u_char cast_flags, - int ttl, - keyid_t key - ) -{ - register struct peer *peer; - register int i; -#ifdef OPENSSL - char statstr[NTP_MAXSTRLEN]; /* statistics for filegen */ -#endif /* OPENSSL */ + peer = findexistingpeer(srcadr, hostname, peer, + hmode, cast_flags); + } + } else { + /* no endpt address given */ + peer = findexistingpeer(srcadr, hostname, NULL, hmode, + cast_flags); + } + + /* + * If a peer is found, this would be a duplicate and we don't + * allow that. This avoids duplicate ephemeral (broadcast/ + * multicast) and preemptible (manycast and pool) client + * associations. + */ + if (peer != NULL) { + DPRINTF(2, ("newpeer(%s) found existing association\n", + (hostname) + ? hostname + : stoa(srcadr))); + return NULL; + } /* * Allocate a new peer structure. Some dirt here, since some of @@ -748,13 +822,12 @@ newpeer( */ if (peer_free_count == 0) getmorepeermem(); - peer = peer_free; - peer_free = peer->next; + UNLINK_HEAD_SLIST(peer, peer_free, p_link); + INSIST(peer != NULL); peer_free_count--; peer_associations++; - if (flags & FLAG_PREEMPT) + if (FLAG_PREEMPT & flags) peer_preempt++; - memset((char *)peer, 0, sizeof(struct peer)); /* * Assign an association ID and increment the system variable. @@ -763,52 +836,68 @@ newpeer( if (++current_association_ID == 0) ++current_association_ID; - DPRINTF(3, ("newpeer: cast flags: 0x%x for address: %s\n", - cast_flags, stoa(srcadr))); - - ISC_LINK_INIT(peer, ilink); /* set up interface link chain */ peer->srcadr = *srcadr; - set_peerdstadr(peer, select_peerinterface(peer, srcadr, dstadr, - cast_flags)); - peer->hmode = (u_char)hmode; - peer->version = (u_char)version; - peer->minpoll = (u_char)max(NTP_MINPOLL, minpoll); - peer->maxpoll = (u_char)min(NTP_MAXPOLL, maxpoll); + if (hostname != NULL) + peer->hostname = estrdup(hostname); + peer->hmode = hmode; + peer->version = version; peer->flags = flags; -#ifdef DEBUG - if (debug > 2) { - if (peer->dstadr) - printf("newpeer: using fd %d and our addr %s\n", - peer->dstadr->fd, - stoa(&peer->dstadr->sin)); - else - printf("newpeer: local interface currently not bound\n"); - } -#endif + peer->cast_flags = cast_flags; + set_peerdstadr(peer, + select_peerinterface(peer, srcadr, dstadr)); + + /* + * It is an error to set minpoll less than NTP_MINPOLL or to + * set maxpoll greater than NTP_MAXPOLL. However, minpoll is + * clamped not greater than NTP_MAXPOLL and maxpoll is clamped + * not less than NTP_MINPOLL without complaint. Finally, + * minpoll is clamped not greater than maxpoll. + */ + if (minpoll == 0) + peer->minpoll = NTP_MINDPOLL; + else + peer->minpoll = min(minpoll, NTP_MAXPOLL); + if (maxpoll == 0) + peer->maxpoll = NTP_MAXDPOLL; + else + peer->maxpoll = max(maxpoll, NTP_MINPOLL); + if (peer->minpoll > peer->maxpoll) + peer->minpoll = peer->maxpoll; + + if (peer->dstadr != NULL) + DPRINTF(3, ("newpeer(%s): using fd %d and our addr %s\n", + stoa(srcadr), peer->dstadr->fd, + stoa(&peer->dstadr->sin))); + else + DPRINTF(3, ("newpeer(%s): local interface currently not bound\n", + stoa(srcadr))); /* * Broadcast needs the socket enabled for broadcast */ - if (cast_flags & MDF_BCAST && peer->dstadr) { + if ((MDF_BCAST & cast_flags) && peer->dstadr != NULL) enable_broadcast(peer->dstadr, srcadr); - } + /* * Multicast needs the socket interface enabled for multicast */ - if (cast_flags & MDF_MCAST && peer->dstadr) { + if ((MDF_MCAST & cast_flags) && peer->dstadr != NULL) enable_multicast_if(peer->dstadr, srcadr); - } - if (key != 0) - peer->flags |= FLAG_AUTHENABLE; + +#ifdef AUTOKEY if (key > NTP_MAXKEY) peer->flags |= FLAG_SKEY; - peer->cast_flags = cast_flags; - peer->ttl = (u_char)ttl; +#endif /* AUTOKEY */ + peer->ttl = ttl; peer->keyid = key; + if (ident != NULL) + peer->ident = estrdup(ident); peer->precision = sys_precision; peer->hpoll = peer->minpoll; if (cast_flags & MDF_ACAST) peer_clear(peer, "ACST"); + else if (cast_flags & MDF_POOL) + peer_clear(peer, "POOL"); else if (cast_flags & MDF_MCAST) peer_clear(peer, "MCST"); else if (cast_flags & MDF_BCAST) @@ -825,105 +914,56 @@ newpeer( peer->timereachable = current_time; peer->timereceived = current_time; -#ifdef REFCLOCK if (ISREFCLOCKADR(&peer->srcadr)) { - +#ifdef REFCLOCK /* * We let the reference clock support do clock * dependent initialization. This includes setting * the peer timer, since the clock may have requirements * for this. */ + if (maxpoll == 0) + peer->maxpoll = peer->minpoll; if (!refclock_newpeer(peer)) { /* * Dump it, something screwed up */ set_peerdstadr(peer, NULL); - - peer->next = peer_free; - peer_free = peer; - peer_free_count++; - return (NULL); + free_peer(peer, 0); + return NULL; } +#else /* REFCLOCK */ + msyslog(LOG_ERR, "refclock %s isn't supported. ntpd was compiled without refclock support.", + stoa(&peer->srcadr)); + set_peerdstadr(peer, NULL); + free_peer(peer, 0); + return NULL; +#endif /* REFCLOCK */ } -#endif /* * Put the new peer in the hash tables. */ - i = NTP_HASH_ADDR(&peer->srcadr); - peer->next = peer_hash[i]; - peer_hash[i] = peer; - peer_hash_count[i]++; - i = peer->associd & NTP_HASH_MASK; - peer->ass_next = assoc_hash[i]; - assoc_hash[i] = peer; - assoc_hash_count[i]++; - -#ifdef OPENSSL - if (peer->flags & FLAG_SKEY) { - sprintf(statstr, "newpeer %d", peer->associd); - record_crypto_stats(&peer->srcadr, statstr); - DPRINTF(1, ("peer: %s\n", statstr)); - } -#endif /* OPENSSL */ - - DPRINTF(1, ("newpeer: %s->%s mode %d vers %d poll %d %d flags 0x%x 0x%x ttl %d key %08x\n", - peer->dstadr == NULL ? "" : stoa(&peer->dstadr->sin), - stoa(&peer->srcadr), - peer->hmode, peer->version, peer->minpoll, - peer->maxpoll, peer->flags, peer->cast_flags, - peer->ttl, peer->keyid)); - - return (peer); + hash = NTP_HASH_ADDR(&peer->srcadr); + LINK_SLIST(peer_hash[hash], peer, adr_link); + peer_hash_count[hash]++; + hash = peer->associd & NTP_HASH_MASK; + LINK_SLIST(assoc_hash[hash], peer, aid_link); + assoc_hash_count[hash]++; + LINK_SLIST(peer_list, peer, p_link); + + restrict_source(&peer->srcadr, 0, 0); + mprintf_event(PEVNT_MOBIL, peer, "assoc %d", peer->associd); + DPRINTF(1, ("newpeer: %s->%s mode %u vers %u poll %u %u flags 0x%x 0x%x ttl %u key %08x\n", + latoa(peer->dstadr), stoa(&peer->srcadr), peer->hmode, + peer->version, peer->minpoll, peer->maxpoll, peer->flags, + peer->cast_flags, peer->ttl, peer->keyid)); + return peer; } /* - * peer_unconfig - remove the configuration bit from a peer - */ -int -peer_unconfig( - struct sockaddr_storage *srcadr, - struct interface *dstadr, - int mode - ) -{ - register struct peer *peer; - int num_found; - - num_found = 0; - peer = findexistingpeer(srcadr, (struct peer *)0, mode); - while (peer != 0) { - if (peer->flags & FLAG_CONFIG - && (dstadr == 0 || peer->dstadr == dstadr)) { - num_found++; - - /* - * Tricky stuff here. If the peer is polling us - * in active mode, turn off the configuration - * bit and make the mode passive. This allows us - * to avoid dumping a lot of history for peers - * we might choose to keep track of in passive - * mode. The protocol will eventually terminate - * undesirables on its own. - */ - if (peer->hmode == MODE_ACTIVE - && peer->pmode == MODE_ACTIVE) { - peer->hmode = MODE_PASSIVE; - peer->flags &= ~FLAG_CONFIG; - } else { - unpeer(peer); - peer = 0; - } - } - peer = findexistingpeer(srcadr, peer, mode); - } - return (num_found); -} - -/* - * peer_clr_stats - clear peer module stat counters + * peer_clr_stats - clear peer module statistics counters */ void peer_clr_stats(void) @@ -935,16 +975,19 @@ peer_clr_stats(void) peer_timereset = current_time; } + /* - * peer_reset - reset stat counters in a peer structure + * peer_reset - reset statistics counters */ void peer_reset( struct peer *peer ) { - if (peer == 0) - return; + if (peer == NULL) + return; + + peer->timereset = current_time; peer->sent = 0; peer->received = 0; peer->processed = 0; @@ -952,100 +995,71 @@ peer_reset( peer->bogusorg = 0; peer->oldpkt = 0; peer->seldisptoolarge = 0; - peer->timereset = current_time; + peer->selbroken = 0; } /* - * peer_all_reset - reset all peer stat counters + * peer_all_reset - reset all peer statistics counters */ void peer_all_reset(void) { struct peer *peer; - int hash; - for (hash = 0; hash < NTP_HASH_SIZE; hash++) - for (peer = peer_hash[hash]; peer != 0; peer = peer->next) + for (peer = peer_list; peer != NULL; peer = peer->p_link) peer_reset(peer); } -#ifdef OPENSSL /* - * expire_all - flush all crypto data and update timestamps. - */ -void -expire_all(void) -{ - struct peer *peer, *next_peer; - int n; - - /* - * This routine is called about once per day from the timer - * routine and when the client is first synchronized. Search the - * peer list for all associations and flush only the key list - * and cookie. If a manycast client association, flush - * everything. Then, recompute and sign the agreement public - * value, if present. - */ - if (!crypto_flags) - return; - - for (n = 0; n < NTP_HASH_SIZE; n++) { - for (peer = peer_hash[n]; peer != 0; peer = next_peer) { - next_peer = peer->next; - if (!(peer->flags & FLAG_SKEY)) { - continue; - - } else if (peer->hmode == MODE_ACTIVE || - peer->hmode == MODE_PASSIVE) { - key_expire(peer); - peer->crypto &= ~(CRYPTO_FLAG_AUTO | - CRYPTO_FLAG_AGREE); - } - - } - } - RAND_bytes((u_char *)&sys_private, 4); - crypto_update(); -} -#endif /* OPENSSL */ - - -/* - * findmanycastpeer - find and return a manycast peer + * findmanycastpeer - find and return a manycastclient or pool + * association matching a received response. */ struct peer * findmanycastpeer( - struct recvbuf *rbufp + struct recvbuf *rbufp /* receive buffer pointer */ ) { - register struct peer *peer; + struct peer *peer; struct pkt *pkt; l_fp p_org; - int i; /* - * This routine is called upon arrival of a server-mode message - * from a manycast client. Search the peer list for a manycast - * client association where the last transmit timestamp matches - * the originate timestamp. This assumes the transmit timestamps - * for possibly more than one manycast association are unique. + * This routine is called upon arrival of a server-mode response + * to a manycastclient multicast solicitation, or to a pool + * server unicast solicitation. Search the peer list for a + * manycastclient association where the last transmit timestamp + * matches the response packet's originate timestamp. There can + * be multiple manycastclient associations, or multiple pool + * solicitation assocations, so this assumes the transmit + * timestamps are unique for such. */ pkt = &rbufp->recv_pkt; - for (i = 0; i < NTP_HASH_SIZE; i++) { - if (peer_hash_count[i] == 0) - continue; - - for (peer = peer_hash[i]; peer != 0; peer = - peer->next) { - if (peer->cast_flags & MDF_ACAST) { - NTOHL_FP(&pkt->org, &p_org); - if (L_ISEQU(&peer->xmt, &p_org)) - return (peer); - } + for (peer = peer_list; peer != NULL; peer = peer->p_link) + if (MDF_SOLICIT_MASK & peer->cast_flags) { + NTOHL_FP(&pkt->org, &p_org); + if (L_ISEQU(&p_org, &peer->aorg)) + break; } - } - return (NULL); + + return peer; +} + +/* peer_cleanup - clean peer list prior to shutdown */ +void peer_cleanup(void) +{ + struct peer *peer; + associd_t assoc; + + for (assoc = initial_association_ID; assoc != current_association_ID; assoc++) { + if (assoc != 0U) { + peer = findpeerbyassoc(assoc); + if (peer != NULL) + unpeer(peer); + } + } + peer = findpeerbyassoc(current_association_ID); + if (peer != NULL) + unpeer(peer); } diff --git a/contrib/ntp/ntpd/ntp_prio_q.c b/contrib/ntp/ntpd/ntp_prio_q.c new file mode 100644 index 000000000..703673b8a --- /dev/null +++ b/contrib/ntp/ntpd/ntp_prio_q.c @@ -0,0 +1,238 @@ +/* ntp_prio_q.c + * + * This file contains the priority queue implementation used by the + * discrete event simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include + +/* Priority Queue + * -------------- + * Define a priority queue in which the relative priority of the elements + * is determined by a function 'get_order' which is supplied to the + * priority_queue + */ +queue *debug_create_priority_queue( + q_order_func get_order +#ifdef _CRTDBG_MAP_ALLOC + , const char * sourcefile + , int line_num +#endif + ) +{ + queue *my_queue; + +#ifndef _CRTDBG_MAP_ALLOC + my_queue = emalloc(sizeof(queue)); +#else + /* preserve original callsite __FILE__ and __LINE__ for leak report */ + my_queue = debug_erealloc(NULL, sizeof(queue), sourcefile, line_num); +#endif + my_queue->get_order = get_order; + my_queue->front = NULL; + my_queue->no_of_elements = 0; + + return my_queue; +} + + +/* Define a function to "destroy" a priority queue, freeing-up + * all the allocated resources in the process + */ + +void destroy_queue( + queue *my_queue + ) +{ + node *temp = NULL; + + /* Empty out the queue elements if they are not already empty */ + while (my_queue->front != NULL) { + temp = my_queue->front; + my_queue->front = my_queue->front->node_next; + free(temp); + } + + /* Now free the queue */ + free(my_queue); +} + + +/* Define a function to allocate memory for one element + * of the queue. The allocated memory consists of size + * bytes plus the number of bytes needed for bookkeeping + */ + +void *debug_get_node( + size_t size +#ifdef _CRTDBG_MAP_ALLOC + , const char * sourcefile + , int line_num +#endif + ) +{ + node *new_node; + +#ifndef _CRTDBG_MAP_ALLOC + new_node = emalloc(sizeof(*new_node) + size); +#else + new_node = debug_erealloc(NULL, sizeof(*new_node) + size, + sourcefile, line_num); +#endif + new_node->node_next = NULL; + + return new_node + 1; +} + +/* Define a function to free the allocated memory for a queue node */ +void free_node( + void *my_node + ) +{ + node *old_node = my_node; + + free(old_node - 1); +} + + +void * +next_node( + void *pv + ) +{ + node *pn; + + pn = pv; + pn--; + + if (pn->node_next == NULL) + return NULL; + + return pn->node_next + 1; +} + + +/* Define a function to check if the queue is empty. */ +int empty( + queue *my_queue + ) +{ + return (!my_queue || !my_queue->front); +} + + +void * +queue_head( + queue *q + ) +{ + if (NULL == q || NULL == q->front) + return NULL; + + return q->front + 1; +} + + +/* Define a function to add an element to the priority queue. + * The element is added according to its priority - + * relative priority is given by the get_order function + */ +queue *enqueue( + queue * my_queue, + void * my_node + ) +{ + node *new_node = (node *)my_node - 1; + node *i = NULL; + node *j = my_queue->front; + + while (j != NULL && + (*my_queue->get_order)(new_node + 1, j + 1) > 0) { + i = j; + j = j->node_next; + } + + if (i == NULL) { /* Insert at beginning of the queue */ + new_node->node_next = my_queue->front; + my_queue->front = new_node; + } else { /* Insert Elsewhere, including the end */ + new_node->node_next = i->node_next; + i->node_next = new_node; + } + + ++my_queue->no_of_elements; + return my_queue; +} + + +/* Define a function to dequeue the first element from the priority + * queue and return it + */ +void *dequeue( + queue *my_queue + ) +{ + node *my_node = my_queue->front; + + if (my_node != NULL) { + my_queue->front = my_node->node_next; + --my_queue->no_of_elements; + return my_node + 1; + } else + return NULL; +} + + +/* Define a function that returns the number of elements in the + * priority queue + */ +int get_no_of_elements( + queue *my_queue + ) +{ + return my_queue->no_of_elements; +} + + +/* Define a function to append a queue onto another. + * Note: there is a faster way (O(1) as opposed to O(n)) + * to do this for simple (FIFO) queues, but we can't rely on + * that for priority queues. (Given the current representation) + * + * I don't anticipate this to be a problem. If it does turn + * out to be a bottleneck, I will consider replacing the + * current implementation with a binomial or fibonacci heap. + */ +void append_queue( + queue *q1, + queue *q2 + ) +{ + while (!empty(q2)) + enqueue(q1, dequeue(q2)); + destroy_queue(q2); +} + + +/* FIFO Queue + * ---------- + * Use the priority queue to create a traditional FIFO queue. + * The only extra function needed is the create_queue + */ + +/* C is not Lisp and does not allow anonymous lambda functions :-(. + * So define a get_fifo_order function here + */ +int get_fifo_order(const void *el1, const void *el2) +{ + return 1; +} diff --git a/contrib/ntp/ntpd/ntp_proto.c b/contrib/ntp/ntpd/ntp_proto.c index 12619b032..2a15d7242 100644 --- a/contrib/ntp/ntpd/ntp_proto.c +++ b/contrib/ntp/ntpd/ntp_proto.c @@ -13,117 +13,229 @@ #include "ntp_unixtime.h" #include "ntp_control.h" #include "ntp_string.h" +#include "ntp_leapsec.h" +#include "refidsmear.h" #include - -#if defined(VMS) && defined(VMS_LOCALUNIT) /*wjm*/ -#include "ntp_refclock.h" +#ifdef HAVE_LIBSCF_H +#include #endif - -#if defined(__FreeBSD__) && __FreeBSD__ >= 3 -#include +#ifdef HAVE_UNISTD_H +#include #endif /* * This macro defines the authentication state. If x is 1 authentication * is required; othewise it is optional. */ -#define AUTH(x, y) ((x) ? (y) == AUTH_OK : (y) == AUTH_OK || \ - (y) == AUTH_NONE) +#define AUTH(x, y) ((x) ? (y) == AUTH_OK \ + : (y) == AUTH_OK || (y) == AUTH_NONE) + +#define AUTH_NONE 0 /* authentication not required */ +#define AUTH_OK 1 /* authentication OK */ +#define AUTH_ERROR 2 /* authentication error */ +#define AUTH_CRYPTO 3 /* crypto_NAK */ + +/* + * Set up Kiss Code values + */ + +enum kiss_codes { + NOKISS, /* No Kiss Code */ + RATEKISS, /* Rate limit Kiss Code */ + DENYKISS, /* Deny Kiss */ + RSTRKISS, /* Restricted Kiss */ + XKISS, /* Experimental Kiss */ + UNKNOWNKISS /* Unknown Kiss Code */ +}; + +/* + * traffic shaping parameters + */ +#define NTP_IBURST 6 /* packets in iburst */ +#define RESP_DELAY 1 /* refclock burst delay (s) */ + +/* + * pool soliciting restriction duration (s) + */ +#define POOL_SOLICIT_WINDOW 8 + +/* + * peer_select groups statistics for a peer used by clock_select() and + * clock_cluster(). + */ +typedef struct peer_select_tag { + struct peer * peer; + double synch; /* sync distance */ + double error; /* jitter */ + double seljit; /* selection jitter */ +} peer_select; /* - * System variables are declared here. See Section 3.2 of the - * specification. + * System variables are declared here. Unless specified otherwise, all + * times are in seconds. */ -u_char sys_leap; /* system leap indicator */ -u_char sys_stratum; /* stratum of system */ +u_char sys_leap; /* system leap indicator, use set_sys_leap() to change this */ +u_char xmt_leap; /* leap indicator sent in client requests, set up by set_sys_leap() */ +u_char sys_stratum; /* system stratum */ s_char sys_precision; /* local clock precision (log2 s) */ double sys_rootdelay; /* roundtrip delay to primary source */ -double sys_rootdispersion; /* dispersion to primary source */ -u_int32 sys_refid; /* source/loop in network byte order */ -static double sys_offset; /* current local clock offset */ -l_fp sys_reftime; /* time we were last updated */ -struct peer *sys_peer; /* our current peer */ -struct peer *sys_pps; /* our PPS peer */ -struct peer *sys_prefer; /* our cherished peer */ -int sys_kod; /* kod credit */ -int sys_kod_rate = 2; /* max kod packets per second */ -#ifdef OPENSSL -u_long sys_automax; /* maximum session key lifetime */ -#endif /* OPENSSL */ +double sys_rootdisp; /* dispersion to primary source */ +u_int32 sys_refid; /* reference id (network byte order) */ +l_fp sys_reftime; /* last update time */ +struct peer *sys_peer; /* current peer */ +#ifdef LEAP_SMEAR +struct leap_smear_info leap_smear; +#endif +int leap_sec_in_progress; + +/* + * Rate controls. Leaky buckets are used to throttle the packet + * transmission rates in order to protect busy servers such as at NIST + * and USNO. There is a counter for each association and another for KoD + * packets. The association counter decrements each second, but not + * below zero. Each time a packet is sent the counter is incremented by + * a configurable value representing the average interval between + * packets. A packet is delayed as long as the counter is greater than + * zero. Note this does not affect the time value computations. + */ /* - * Nonspecified system state variables. + * Nonspecified system state variables */ int sys_bclient; /* broadcast client enable */ double sys_bdelay; /* broadcast client default delay */ -int sys_calldelay; /* modem callup delay (s) */ int sys_authenticate; /* requre authentication for config */ l_fp sys_authdelay; /* authentication delay */ -static u_long sys_authdly[2]; /* authentication delay shift reg */ -static double sys_mindisp = MINDISPERSE; /* min disp increment (s) */ -static double sys_maxdist = MAXDISTANCE; /* selection threshold (s) */ -double sys_jitter; /* system jitter (s) */ -static int sys_hopper; /* anticlockhop counter */ -static int sys_maxhop = MAXHOP; /* anticlockhop counter threshold */ -int leap_next; /* leap consensus */ +double sys_offset; /* current local clock offset */ +double sys_mindisp = MINDISPERSE; /* minimum distance (s) */ +double sys_maxdist = MAXDISTANCE; /* selection threshold */ +double sys_jitter; /* system jitter */ +u_long sys_epoch; /* last clock update time */ +static double sys_clockhop; /* clockhop threshold */ +static int leap_vote_ins; /* leap consensus for insert */ +static int leap_vote_del; /* leap consensus for delete */ keyid_t sys_private; /* private value for session seed */ int sys_manycastserver; /* respond to manycast client pkts */ +int ntp_mode7; /* respond to ntpdc (mode7) */ int peer_ntpdate; /* active peers in ntpdate mode */ int sys_survivors; /* truest of the truechimers */ -#ifdef OPENSSL -char *sys_hostname; /* gethostname() name */ -#endif /* OPENSSL */ +char *sys_ident = NULL; /* identity scheme */ /* * TOS and multicast mapping stuff */ int sys_floor = 0; /* cluster stratum floor */ -int sys_ceiling = STRATUM_UNSPEC; /* cluster stratum ceiling */ +int sys_ceiling = STRATUM_UNSPEC - 1; /* cluster stratum ceiling */ int sys_minsane = 1; /* minimum candidates */ -int sys_minclock = NTP_MINCLOCK; /* minimum survivors */ +int sys_minclock = NTP_MINCLOCK; /* minimum candidates */ int sys_maxclock = NTP_MAXCLOCK; /* maximum candidates */ int sys_cohort = 0; /* cohort switch */ int sys_orphan = STRATUM_UNSPEC + 1; /* orphan stratum */ -double sys_orphandelay = 0; /* orphan root delay */ +int sys_orphwait = NTP_ORPHWAIT; /* orphan wait */ int sys_beacon = BEACON; /* manycast beacon interval */ int sys_ttlmax; /* max ttl mapping vector index */ u_char sys_ttl[MAX_TTL]; /* ttl mapping vector */ /* - * Statistics counters + * Statistics counters - first the good, then the bad */ -u_long sys_stattime; /* time since reset */ +u_long sys_stattime; /* elapsed time */ u_long sys_received; /* packets received */ -u_long sys_processed; /* packets processed */ -u_long sys_newversionpkt; /* current version */ -u_long sys_oldversionpkt; /* recent version */ -u_long sys_unknownversion; /* invalid version */ +u_long sys_processed; /* packets for this host */ +u_long sys_newversion; /* current version */ +u_long sys_oldversion; /* old version */ u_long sys_restricted; /* access denied */ u_long sys_badlength; /* bad length or format */ u_long sys_badauth; /* bad authentication */ +u_long sys_declined; /* declined */ u_long sys_limitrejected; /* rate exceeded */ +u_long sys_kodsent; /* KoD sent */ + +static int kiss_code_check(u_char hisleap, u_char hisstratum, u_char hismode, u_int32 refid); +static double root_distance (struct peer *); +static void clock_combine (peer_select *, int, int); +static void peer_xmit (struct peer *); +static void fast_xmit (struct recvbuf *, int, keyid_t, int); +static void pool_xmit (struct peer *); +static void clock_update (struct peer *); +static void measure_precision(void); +static double measure_tick_fuzz(void); +static int local_refid (struct peer *); +static int peer_unfit (struct peer *); +#ifdef AUTOKEY +static int group_test (char *, char *); +#endif /* AUTOKEY */ +#ifdef WORKER +void pool_name_resolved (int, int, void *, const char *, + const char *, const struct addrinfo *, + const struct addrinfo *); +#endif /* WORKER */ -static double root_distance P((struct peer *)); -static void clock_combine P((struct peer **, int)); -static void peer_xmit P((struct peer *)); -static void fast_xmit P((struct recvbuf *, int, keyid_t, - int)); -static void clock_update P((void)); -static int default_get_precision P((void)); -static int peer_unfit P((struct peer *)); +void +set_sys_leap(u_char new_sys_leap) { + sys_leap = new_sys_leap; + xmt_leap = sys_leap; + + /* + * Under certain conditions we send faked leap bits to clients, so + * eventually change xmt_leap below, but never change LEAP_NOTINSYNC. + */ + if (xmt_leap != LEAP_NOTINSYNC) { + if (leap_sec_in_progress) { + /* always send "not sync" */ + xmt_leap = LEAP_NOTINSYNC; + } +#ifdef LEAP_SMEAR + else { + /* + * If leap smear is enabled in general we must never send a leap second warning + * to clients, so make sure we only send "in sync". + */ + if (leap_smear.enabled) + xmt_leap = LEAP_NOWARNING; + } +#endif /* LEAP_SMEAR */ + } +} +/* + * Kiss Code check + */ +int kiss_code_check(u_char hisleap, u_char hisstratum, u_char hismode, u_int32 refid) { + if ( hismode == MODE_SERVER + && hisleap == LEAP_NOTINSYNC + && hisstratum == STRATUM_UNSPEC) { + if(memcmp(&refid,"RATE", 4) == 0) { + return (RATEKISS); + } + else if(memcmp(&refid,"DENY", 4) == 0) { + return (DENYKISS); + } + else if(memcmp(&refid,"RSTR", 4) == 0) { + return (RSTRKISS); + } + else if(memcmp(&refid,"X", 1) == 0) { + return (XKISS); + } + else { + return (UNKNOWNKISS); + } + } + else { + return (NOKISS); + } +} /* - * transmit - Transmit Procedure. See Section 3.4.2 of the - * specification. + * transmit - transmit procedure called by poll timeout */ void transmit( struct peer *peer /* peer structure pointer */ ) { - int hpoll; + u_char hpoll; /* * The polling state machine. There are two kinds of machines, @@ -131,24 +243,7 @@ transmit( * server modes) and those that do (all other modes). The dance * is intricate... */ - /* - * Orphan mode is active when enabled and when no servers less - * than the orphan statum are available. In this mode packets - * are sent at the orphan stratum. An orphan with no other - * synchronization source is an orphan parent. It assumes root - * delay zero and reference ID the loopback address. All others - * are orphan children with root delay randomized over a 1-s - * range. The root delay is used by the election algorithm to - * select the order of synchronization. - */ hpoll = peer->hpoll; - if (sys_orphan < STRATUM_UNSPEC && sys_peer == NULL) { - sys_leap = LEAP_NOWARNING; - sys_stratum = sys_orphan; - sys_refid = htonl(LOOPBACKADR); - sys_rootdelay = 0; - sys_rootdispersion = 0; - } /* * In broadcast mode the poll interval is never changed from @@ -156,7 +251,8 @@ transmit( */ if (peer->cast_flags & (MDF_BCAST | MDF_MCAST)) { peer->outdate = current_time; - peer_xmit(peer); + if (sys_leap != LEAP_NOTINSYNC) + peer_xmit(peer); poll_update(peer, hpoll); return; } @@ -166,9 +262,13 @@ transmit( * increased by one for each poll until either sys_maxclock * servers have been found or the maximum ttl is reached. When * sys_maxclock servers are found we stop polling until one or - * more servers have timed out or until less than minpoll + * more servers have timed out or until less than sys_minclock * associations turn up. In this case additional better servers - * are dragged in and preempt the existing ones. + * are dragged in and preempt the existing ones. Once every + * sys_beacon seconds we are to transmit unconditionally, but + * this code is not quite right -- peer->unreach counts polls + * and is being compared with sys_beacon, so the beacons happen + * every sys_beacon polls. */ if (peer->cast_flags & MDF_ACAST) { peer->outdate = current_time; @@ -176,9 +276,9 @@ transmit( peer->unreach = 0; peer->ttl = 0; peer_xmit(peer); - } else if (sys_survivors < sys_minclock || - peer_preempt < sys_maxclock) { - if (peer->ttl < sys_ttlmax) + } else if ( sys_survivors < sys_minclock + || peer_associations < sys_maxclock) { + if (peer->ttl < (u_int32)sys_ttlmax) peer->ttl++; peer_xmit(peer); } @@ -187,9 +287,31 @@ transmit( return; } + /* + * Pool associations transmit unicast solicitations when there + * are less than a hard limit of 2 * sys_maxclock associations, + * and either less than sys_minclock survivors or less than + * sys_maxclock associations. The hard limit prevents unbounded + * growth in associations if the system clock or network quality + * result in survivor count dipping below sys_minclock often. + * This was observed testing with pool, where sys_maxclock == 12 + * resulted in 60 associations without the hard limit. A + * similar hard limit on manycastclient ephemeral associations + * may be appropriate. + */ + if (peer->cast_flags & MDF_POOL) { + peer->outdate = current_time; + if ( (peer_associations <= 2 * sys_maxclock) + && ( peer_associations < sys_maxclock + || sys_survivors < sys_minclock)) + pool_xmit(peer); + poll_update(peer, hpoll); + return; + } + /* * In unicast modes the dance is much more intricate. It is - * desigmed to back off whenever possible to minimize network + * designed to back off whenever possible to minimize network * traffic. */ if (peer->burst == 0) { @@ -198,100 +320,74 @@ transmit( /* * Update the reachability status. If not heard for * three consecutive polls, stuff infinity in the clock - * filter. + * filter. */ oreach = peer->reach; peer->outdate = current_time; - if (peer == sys_peer) - sys_hopper++; + peer->unreach++; peer->reach <<= 1; - if (!(peer->reach & 0x07)) - clock_filter(peer, 0., 0., MAXDISPERSE); if (!peer->reach) { /* * Here the peer is unreachable. If it was - * previously reachable, raise a trap. + * previously reachable raise a trap. Send a + * burst if enabled. */ + clock_filter(peer, 0., 0., MAXDISPERSE); if (oreach) { - report_event(EVNT_UNREACH, peer); - peer->timereachable = current_time; + peer_unfit(peer); + report_event(PEVNT_UNREACH, peer, NULL); } - - /* - * Send a burst if enabled, but only once after - * a peer becomes unreachable. If the prempt - * flag is dim, bump the unreach counter by one; - * otherwise, bump it by three. - */ - if (peer->flags & FLAG_IBURST && - peer->unreach == 0) { - peer->burst = NTP_BURST; - } - if (!(peer->flags & FLAG_PREEMPT)) - peer->unreach++; - else - peer->unreach += 3; + if ( (peer->flags & FLAG_IBURST) + && peer->retry == 0) + peer->retry = NTP_RETRY; } else { /* - * Here the peer is reachable. Set the poll - * interval to the system poll interval. Send a - * burst only if enabled and the peer is fit. - * - * Respond to the peer evaluation produced by - * the selection algorithm. If less than the - * outlyer level, up the unreach by three. If - * there are excess associations, up the unreach - * by two if not a candidate and by one if so. + * Here the peer is reachable. Send a burst if + * enabled and the peer is fit. Reset unreach + * for persistent and ephemeral associations. + * Unreach is also reset for survivors in + * clock_select(). */ - if (!(peer->flags & FLAG_PREEMPT)) { - peer->unreach = 0; - } else if (peer->status < CTL_PST_SEL_SELCAND) { - peer->unreach += 3; - } else if (peer_preempt > sys_maxclock) { - if (peer->status < CTL_PST_SEL_SYNCCAND) - peer->unreach += 2; - else - peer->unreach++; - } else { - peer->unreach = 0; - } hpoll = sys_poll; - if (peer->flags & FLAG_BURST && - !peer_unfit(peer)) - peer->burst = NTP_BURST; + if (!(peer->flags & FLAG_PREEMPT)) + peer->unreach = 0; + if ( (peer->flags & FLAG_BURST) + && peer->retry == 0 + && !peer_unfit(peer)) + peer->retry = NTP_RETRY; } /* - * Watch for timeout. If ephemeral or preemptable, toss - * the rascal; otherwise, bump the poll interval. - */ + * Watch for timeout. If ephemeral, toss the rascal; + * otherwise, bump the poll interval. Note the + * poll_update() routine will clamp it to maxpoll. + * If preemptible and we have more peers than maxclock, + * and this peer has the minimum score of preemptibles, + * demobilize. + */ if (peer->unreach >= NTP_UNREACH) { - if (peer->flags & FLAG_PREEMPT || - !(peer->flags & FLAG_CONFIG)) { + hpoll++; + /* ephemeral: no FLAG_CONFIG nor FLAG_PREEMPT */ + if (!(peer->flags & (FLAG_CONFIG | FLAG_PREEMPT))) { + report_event(PEVNT_RESTART, peer, "timeout"); + peer_clear(peer, "TIME"); + unpeer(peer); + return; + } + if ( (peer->flags & FLAG_PREEMPT) + && (peer_associations > sys_maxclock) + && score_all(peer)) { + report_event(PEVNT_RESTART, peer, "timeout"); peer_clear(peer, "TIME"); unpeer(peer); return; - } else { - hpoll++; } } } else { peer->burst--; - - /* - * If a broadcast client at this point, the burst has - * concluded, so we switch to client mode and purge the - * keylist, since no further transmissions will be made. - */ if (peer->burst == 0) { - if (peer->cast_flags & MDF_BCLNT) { - peer->hmode = MODE_BCLIENT; -#ifdef OPENSSL - key_expire(peer); -#endif /* OPENSSL */ - } /* * If ntpdate mode and the clock has not been @@ -302,15 +398,20 @@ transmit( peer_ntpdate--; if (peer_ntpdate == 0) { msyslog(LOG_NOTICE, - "no reply; clock not set"); + "ntpd: no servers found"); + if (!msyslog_term) + printf( + "ntpd: no servers found\n"); exit (0); } } } } + if (peer->retry > 0) + peer->retry--; /* - * Do not transmit if in broadcast client mode. + * Do not transmit if in broadcast client mode. */ if (peer->hmode != MODE_BCLIENT) peer_xmit(peer); @@ -319,7 +420,7 @@ transmit( /* - * receive - Receive Procedure. See section 3.4.3 in the specification. + * receive - receive procedure called for each packet received */ void receive( @@ -328,68 +429,66 @@ receive( { register struct peer *peer; /* peer structure pointer */ register struct pkt *pkt; /* receive packet pointer */ - int hisversion; /* packet version */ - int hisleap; /* packet leap indicator */ - int hismode; /* packet mode */ - int hisstratum; /* packet stratum */ - int restrict_mask; /* restrict bits */ + u_char hisversion; /* packet version */ + u_char hisleap; /* packet leap indicator */ + u_char hismode; /* packet mode */ + u_char hisstratum; /* packet stratum */ + u_short restrict_mask; /* restrict bits */ + int kissCode = NOKISS; /* Kiss Code */ int has_mac; /* length of MAC field */ int authlen; /* offset of MAC field */ int is_authentic = 0; /* cryptosum ok */ - keyid_t skeyid = 0; /* key ID */ - struct sockaddr_storage *dstadr_sin; /* active runway */ + int retcode = AM_NOMATCH; /* match code */ + keyid_t skeyid = 0; /* key IDs */ + u_int32 opcode = 0; /* extension field opcode */ + sockaddr_u *dstadr_sin; /* active runway */ struct peer *peer2; /* aux peer structure pointer */ + endpt * match_ep; /* newpeer() local address */ l_fp p_org; /* origin timestamp */ l_fp p_rec; /* receive timestamp */ l_fp p_xmt; /* transmit timestamp */ -#ifdef OPENSSL - keyid_t tkeyid = 0; /* temporary key ID */ - keyid_t pkeyid = 0; /* previous key ID */ +#ifdef AUTOKEY + char hostname[NTP_MAXSTRLEN + 1]; + char *groupname = NULL; struct autokey *ap; /* autokey structure pointer */ int rval; /* cookie snatcher */ -#endif /* OPENSSL */ - int retcode = AM_NOMATCH; - int at_listhead; + keyid_t pkeyid = 0, tkeyid = 0; /* key IDs */ +#endif /* AUTOKEY */ +#ifdef HAVE_NTP_SIGND + static unsigned char zero_key[16]; +#endif /* HAVE_NTP_SIGND */ /* * Monitor the packet and get restrictions. Note that the packet * length for control and private mode packets must be checked - * by the service routines. Note that no statistics counters are - * recorded for restrict violations, since these counters are in - * the restriction routine. Note the careful distinctions here - * between a packet with a format error and a packet that is - * simply discarded without prejudice. Some restrictions have to - * be handled later in order to generate a kiss-of-death packet. + * by the service routines. Some restrictions have to be handled + * later in order to generate a kiss-o'-death packet. */ /* * Bogus port check is before anything, since it probably * reveals a clogging attack. */ sys_received++; - if (SRCPORT(&rbufp->recv_srcadr) == 0) { + if (0 == SRCPORT(&rbufp->recv_srcadr)) { sys_badlength++; return; /* bogus port */ } - at_listhead = ntp_monitor(rbufp); - restrict_mask = restrictions(&rbufp->recv_srcadr, at_listhead); -#ifdef DEBUG - if (debug > 1) - printf("receive: at %ld %s<-%s flags %x restrict %03x\n", + restrict_mask = restrictions(&rbufp->recv_srcadr); + DPRINTF(2, ("receive: at %ld %s<-%s flags %x restrict %03x\n", current_time, stoa(&rbufp->dstadr->sin), stoa(&rbufp->recv_srcadr), - rbufp->dstadr->flags, restrict_mask); -#endif - if (restrict_mask & RES_IGNORE) { - sys_restricted++; - return; /* ignore everything */ - } + rbufp->dstadr->flags, restrict_mask)); pkt = &rbufp->recv_pkt; hisversion = PKT_VERSION(pkt->li_vn_mode); hisleap = PKT_LEAP(pkt->li_vn_mode); hismode = (int)PKT_MODE(pkt->li_vn_mode); hisstratum = PKT_TO_STRATUM(pkt->stratum); + if (restrict_mask & RES_IGNORE) { + sys_restricted++; + return; /* ignore everything */ + } if (hismode == MODE_PRIVATE) { - if (restrict_mask & RES_NOQUERY) { + if (!ntp_mode7 || (restrict_mask & RES_NOQUERY)) { sys_restricted++; return; /* no query private */ } @@ -407,24 +506,31 @@ receive( } if (restrict_mask & RES_DONTSERVE) { sys_restricted++; - return; /* no time */ + return; /* no time serve */ } - if (rbufp->recv_length < LEN_PKT_NOMAC) { - sys_badlength++; - return; /* runt packet */ + + /* + * This is for testing. If restricted drop ten percent of + * surviving packets. + */ + if (restrict_mask & RES_FLAKE) { + if ((double)ntp_random() / 0x7fffffff < .1) { + sys_restricted++; + return; /* no flakeway */ + } } - + /* * Version check must be after the query packets, since they - * intentionally use early version. + * intentionally use an early version. */ if (hisversion == NTP_VERSION) { - sys_newversionpkt++; /* new version */ - } else if (!(restrict_mask & RES_VERSION) && hisversion >= - NTP_OLDVERSION) { - sys_oldversionpkt++; /* previous version */ + sys_newversion++; /* new version */ + } else if ( !(restrict_mask & RES_VERSION) + && hisversion >= NTP_OLDVERSION) { + sys_oldversion++; /* previous version */ } else { - sys_unknownversion++; + sys_badlength++; return; /* old version */ } @@ -449,40 +555,69 @@ receive( * the number of words following the packet header is 0, no MAC * is present and the packet is not authenticated. If 1, the * packet is a crypto-NAK; if 3, the packet is authenticated - * with DES; if 5, the packet is authenticated with MD5. If 2 or - * 4, the packet is a runt and discarded forthwith. If greater - * than 5, an extension field is present, so we subtract the - * length of the field and go around again. + * with DES; if 5, the packet is authenticated with MD5; if 6, + * the packet is authenticated with SHA. If 2 or * 4, the packet + * is a runt and discarded forthwith. If greater than 6, an + * extension field is present, so we subtract the length of the + * field and go around again. */ authlen = LEN_PKT_NOMAC; has_mac = rbufp->recv_length - authlen; while (has_mac > 0) { - int temp; + u_int32 len; +#ifdef AUTOKEY + u_int32 hostlen; + struct exten *ep; +#endif /*AUTOKEY */ - if (has_mac % 4 != 0 || has_mac < MIN_MAC_LEN) { + if (has_mac % 4 != 0 || has_mac < (int)MIN_MAC_LEN) { sys_badlength++; - return; /* bad MAC length */ + return; /* bad length */ } - if (has_mac == 1 * 4 || has_mac == 3 * 4 || has_mac == - MAX_MAC_LEN) { + if (has_mac <= (int)MAX_MAC_LEN) { skeyid = ntohl(((u_int32 *)pkt)[authlen / 4]); break; - } else if (has_mac > MAX_MAC_LEN) { - temp = ntohl(((u_int32 *)pkt)[authlen / 4]) & - 0xffff; - if (temp < 4 || temp > NTP_MAXEXTEN || temp % 4 - != 0) { + } else { + opcode = ntohl(((u_int32 *)pkt)[authlen / 4]); + len = opcode & 0xffff; + if ( len % 4 != 0 + || len < 4 + || (int)len + authlen > rbufp->recv_length) { sys_badlength++; - return; /* bad MAC length */ + return; /* bad length */ } - authlen += temp; - has_mac -= temp; - } else { - sys_badlength++; - return; /* bad MAC length */ +#ifdef AUTOKEY + /* + * Extract calling group name for later. If + * sys_groupname is non-NULL, there must be + * a group name provided to elicit a response. + */ + if ( (opcode & 0x3fff0000) == CRYPTO_ASSOC + && sys_groupname != NULL) { + ep = (struct exten *)&((u_int32 *)pkt)[authlen / 4]; + hostlen = ntohl(ep->vallen); + if ( hostlen >= sizeof(hostname) + || hostlen > len - + offsetof(struct exten, pkt)) { + sys_badlength++; + return; /* bad length */ + } + memcpy(hostname, &ep->pkt, hostlen); + hostname[hostlen] = '\0'; + groupname = strchr(hostname, '@'); + if (groupname == NULL) { + sys_declined++; + return; + } + groupname++; + } +#endif /* AUTOKEY */ + authlen += len; + has_mac -= len; } } + /* * If has_mac is < 0 we had a malformed packet. */ @@ -490,16 +625,48 @@ receive( sys_badlength++; return; /* bad length */ } -#ifdef OPENSSL - pkeyid = tkeyid = 0; -#endif /* OPENSSL */ + + /* + * If authentication required, a MAC must be present. + */ + if (restrict_mask & RES_DONTTRUST && has_mac == 0) { + sys_restricted++; + return; /* access denied */ + } + + /* + * Update the MRU list and finger the cloggers. It can be a + * little expensive, so turn it off for production use. + * RES_LIMITED and RES_KOD will be cleared in the returned + * restrict_mask unless one or both actions are warranted. + */ + restrict_mask = ntp_monitor(rbufp, restrict_mask); + if (restrict_mask & RES_LIMITED) { + sys_limitrejected++; + if ( !(restrict_mask & RES_KOD) + || MODE_BROADCAST == hismode + || MODE_SERVER == hismode) { + if (MODE_SERVER == hismode) + DPRINTF(1, ("Possibly self-induced rate limiting of MODE_SERVER from %s\n", + stoa(&rbufp->recv_srcadr))); + return; /* rate exceeded */ + } + if (hismode == MODE_CLIENT) + fast_xmit(rbufp, MODE_SERVER, skeyid, + restrict_mask); + else + fast_xmit(rbufp, MODE_ACTIVE, skeyid, + restrict_mask); + return; /* rate exceeded */ + } + restrict_mask &= ~RES_KOD; /* * We have tossed out as many buggy packets as possible early in * the game to reduce the exposure to a clogging attack. Now we * have to burn some cycles to find the association and * authenticate the packet if required. Note that we burn only - * MD5 cycles, again to reduce exposure. There may be no + * digest cycles, again to reduce exposure. There may be no * matching association and that's okay. * * More on the autokey mambo. Normally the local interface is @@ -509,12 +676,11 @@ receive( * address used to construct the autokey is the unicast address * of the interface. However, if the sender is a broadcaster, * the interface broadcast address is used instead. - & Notwithstanding this technobabble, if the sender is a + * Notwithstanding this technobabble, if the sender is a * multicaster, the broadcast address is null, so we use the * unicast address anyway. Don't ask. */ - peer = findpeer(&rbufp->recv_srcadr, rbufp->dstadr, hismode, - &retcode); + peer = findpeer(rbufp, hismode, &retcode); dstadr_sin = &rbufp->dstadr->sin; NTOHL_FP(&pkt->org, &p_org); NTOHL_FP(&pkt->rec, &p_rec); @@ -543,34 +709,58 @@ receive( * is zero, acceptable outcomes of y are NONE and OK. If x is * one, the only acceptable outcome of y is OK. */ + if (has_mac == 0) { + restrict_mask &= ~RES_MSSNTP; is_authentic = AUTH_NONE; /* not required */ #ifdef DEBUG if (debug) - printf("receive: at %ld %s<-%s mode %d code %d auth %d\n", + printf( + "receive: at %ld %s<-%s mode %d len %d\n", current_time, stoa(dstadr_sin), - stoa(&rbufp->recv_srcadr), hismode, retcode, - is_authentic); + stoa(&rbufp->recv_srcadr), hismode, + authlen); #endif } else if (has_mac == 4) { - is_authentic = AUTH_CRYPTO; /* crypto-NAK */ + restrict_mask &= ~RES_MSSNTP; + is_authentic = AUTH_CRYPTO; /* crypto-NAK */ #ifdef DEBUG if (debug) printf( - "receive: at %ld %s<-%s mode %d code %d keyid %08x len %d mac %d auth %d\n", + "receive: at %ld %s<-%s mode %d keyid %08x len %d auth %d\n", current_time, stoa(dstadr_sin), - stoa(&rbufp->recv_srcadr), hismode, retcode, - skeyid, authlen, has_mac, is_authentic); + stoa(&rbufp->recv_srcadr), hismode, skeyid, + authlen + has_mac, is_authentic); #endif + +#ifdef HAVE_NTP_SIGND + /* + * If the signature is 20 bytes long, the last 16 of + * which are zero, then this is a Microsoft client + * wanting AD-style authentication of the server's + * reply. + * + * This is described in Microsoft's WSPP docs, in MS-SNTP: + * http://msdn.microsoft.com/en-us/library/cc212930.aspx + */ + } else if ( has_mac == MAX_MD5_LEN + && (restrict_mask & RES_MSSNTP) + && (retcode == AM_FXMIT || retcode == AM_NEWPASS) + && (memcmp(zero_key, (char *)pkt + authlen + 4, + MAX_MD5_LEN - 4) == 0)) { + is_authentic = AUTH_NONE; +#endif /* HAVE_NTP_SIGND */ + } else { -#ifdef OPENSSL + restrict_mask &= ~RES_MSSNTP; +#ifdef AUTOKEY /* * For autokey modes, generate the session key * and install in the key cache. Use the socket * broadcast or unicast address as appropriate. */ - if (skeyid > NTP_MAXKEY) { - + if (crypto_flags && skeyid > NTP_MAXKEY) { + /* * More on the autokey dance (AKD). A cookie is * constructed from public and private values. @@ -596,6 +786,10 @@ receive( * # if unsync, 0 * % can't happen */ + if (has_mac < (int)MAX_MD5_LEN) { + sys_badauth++; + return; + } if (hismode == MODE_BROADCAST) { /* @@ -606,13 +800,14 @@ receive( * mobilized. However, if this is from * the wildcard interface, game over. */ - if (crypto_flags && rbufp->dstadr == - any_interface) { + if ( crypto_flags + && rbufp->dstadr == + ANY_INTERFACE_CHOOSE(&rbufp->recv_srcadr)) { sys_restricted++; return; /* no wildcard */ } pkeyid = 0; - if (!SOCKNUL(&rbufp->dstadr->bcast)) + if (!SOCK_UNSPEC(&rbufp->dstadr->bcast)) dstadr_sin = &rbufp->dstadr->bcast; } else if (peer == NULL) { @@ -630,7 +825,7 @@ receive( * purposes is zero. Note the hash is saved for * use later in the autokey mambo. */ - if (authlen > LEN_PKT_NOMAC && pkeyid != 0) { + if (authlen > (int)LEN_PKT_NOMAC && pkeyid != 0) { session_key(&rbufp->recv_srcadr, dstadr_sin, skeyid, 0, 2); tkeyid = session_key( @@ -643,7 +838,7 @@ receive( } } -#endif /* OPENSSL */ +#endif /* AUTOKEY */ /* * Compute the cryptosum. Note a clogging attack may @@ -653,24 +848,21 @@ receive( * association. Note that there is no key zero. */ if (!authdecrypt(skeyid, (u_int32 *)pkt, authlen, - has_mac)) { + has_mac)) is_authentic = AUTH_ERROR; - sys_badauth++; - return; - } else { + else is_authentic = AUTH_OK; - } -#ifdef OPENSSL - if (skeyid > NTP_MAXKEY) +#ifdef AUTOKEY + if (crypto_flags && skeyid > NTP_MAXKEY) authtrust(skeyid, 0); -#endif /* OPENSSL */ +#endif /* AUTOKEY */ #ifdef DEBUG if (debug) printf( - "receive: at %ld %s<-%s mode %d code %d keyid %08x len %d mac %d auth %d\n", + "receive: at %ld %s<-%s mode %d keyid %08x len %d auth %d\n", current_time, stoa(dstadr_sin), - stoa(&rbufp->recv_srcadr), hismode, retcode, - skeyid, authlen, has_mac, is_authentic); + stoa(&rbufp->recv_srcadr), hismode, skeyid, + authlen + has_mac, is_authentic); #endif } @@ -695,19 +887,21 @@ receive( case AM_FXMIT: /* - * The vanilla case is when this is not a multicast - * interface. If authentication succeeds, return a - * server mode packet; if not and the key ID is nonzero, - * return a crypto-NAK. + * If authentication OK, send a server reply; otherwise, + * send a crypto-NAK. */ if (!(rbufp->dstadr->flags & INT_MCASTOPEN)) { if (AUTH(restrict_mask & RES_DONTTRUST, - is_authentic)) + is_authentic)) { fast_xmit(rbufp, MODE_SERVER, skeyid, restrict_mask); - else if (is_authentic == AUTH_ERROR) + } else if (is_authentic == AUTH_ERROR) { fast_xmit(rbufp, MODE_SERVER, 0, restrict_mask); + sys_badauth++; + } else { + sys_restricted++; + } return; /* hooray */ } @@ -720,22 +914,28 @@ receive( return; /* not enabled */ } +#ifdef AUTOKEY /* - * Do not respond if unsynchronized or stratum is below - * the floor or at or above the ceiling. + * Do not respond if not the same group. */ - if (sys_leap == LEAP_NOTINSYNC || sys_stratum < - sys_floor || sys_stratum >= sys_ceiling) - return; /* bad stratum */ + if (group_test(groupname, NULL)) { + sys_declined++; + return; + } +#endif /* AUTOKEY */ /* - * Do not respond if our stratum is greater than the - * manycaster or it has already synchronized to us. + * Do not respond if we are not synchronized or our + * stratum is greater than the manycaster or the + * manycaster has already synchronized to us. */ - if (sys_peer == NULL || hisstratum < sys_stratum || - (sys_cohort && hisstratum == sys_stratum) || - rbufp->dstadr->addr_refid == pkt->refid) + if ( sys_leap == LEAP_NOTINSYNC + || sys_stratum >= hisstratum + || (!sys_cohort && sys_stratum == hisstratum + 1) + || rbufp->dstadr->addr_refid == pkt->refid) { + sys_declined++; return; /* no help */ + } /* * Respond only if authentication succeeds. Don't do a @@ -744,47 +944,86 @@ receive( if (AUTH(restrict_mask & RES_DONTTRUST, is_authentic)) fast_xmit(rbufp, MODE_SERVER, skeyid, restrict_mask); - return; /* hooray */ /* * This is a server mode packet returned in response to a client - * mode packet sent to a multicast group address. The origin - * timestamp is a good nonce to reliably associate the reply - * with what was sent. If there is no match, that's curious and - * could be an intruder attempting to clog, so we just ignore - * it. + * mode packet sent to a multicast group address (for + * manycastclient) or to a unicast address (for pool). The + * origin timestamp is a good nonce to reliably associate the + * reply with what was sent. If there is no match, that's + * curious and could be an intruder attempting to clog, so we + * just ignore it. * - * If the packet is authentic and the manycast association is - * found, we mobilize a client association and copy pertinent - * variables from the manycast association to the new client - * association. If not, just ignore the packet. + * If the packet is authentic and the manycastclient or pool + * association is found, we mobilize a client association and + * copy pertinent variables from the manycastclient or pool + * association to the new client association. If not, just + * ignore the packet. * * There is an implosion hazard at the manycast client, since * the manycast servers send the server packet immediately. If * the guy is already here, don't fire up a duplicate. */ case AM_MANYCAST: - if (!AUTH(sys_authenticate | (restrict_mask & - (RES_NOPEER | RES_DONTTRUST)), is_authentic)) - return; /* bad auth */ +#ifdef AUTOKEY + /* + * Do not respond if not the same group. + */ + if (group_test(groupname, NULL)) { + sys_declined++; + return; + } +#endif /* AUTOKEY */ if ((peer2 = findmanycastpeer(rbufp)) == NULL) { sys_restricted++; return; /* not enabled */ } - if ((peer = newpeer(&rbufp->recv_srcadr, - rbufp->dstadr, MODE_CLIENT, - hisversion, NTP_MINDPOLL, NTP_MAXDPOLL, - FLAG_IBURST | FLAG_PREEMPT, MDF_UCAST | MDF_ACLNT, - 0, skeyid)) == NULL) - return; /* system error */ + if (!AUTH( (!(peer2->cast_flags & MDF_POOL) + && sys_authenticate) + || (restrict_mask & (RES_NOPEER | + RES_DONTTRUST)), is_authentic)) { + sys_restricted++; + return; /* access denied */ + } /* - * We don't need these, but it warms the billboards. + * Do not respond if unsynchronized or stratum is below + * the floor or at or above the ceiling. */ - peer->ttl = peer2->ttl; - break; + if ( hisleap == LEAP_NOTINSYNC + || hisstratum < sys_floor + || hisstratum >= sys_ceiling) { + sys_declined++; + return; /* no help */ + } + peer = newpeer(&rbufp->recv_srcadr, NULL, rbufp->dstadr, + MODE_CLIENT, hisversion, peer2->minpoll, + peer2->maxpoll, FLAG_PREEMPT | + (FLAG_IBURST & peer2->flags), MDF_UCAST | + MDF_UCLNT, 0, skeyid, sys_ident); + if (NULL == peer) { + sys_declined++; + return; /* ignore duplicate */ + } + + /* + * After each ephemeral pool association is spun, + * accelerate the next poll for the pool solicitor so + * the pool will fill promptly. + */ + if (peer2->cast_flags & MDF_POOL) + peer2->nextdate = current_time + 1; + + /* + * Further processing of the solicitation response would + * simply detect its origin timestamp as bogus for the + * brand-new association (it matches the prototype + * association) and tinker with peer->nextdate delaying + * first sync. + */ + return; /* solicitation response handled */ /* * This is the first packet received from a broadcast server. If @@ -793,68 +1032,118 @@ receive( * kiss any frogs here. */ case AM_NEWBCL: + +#ifdef AUTOKEY + /* + * Do not respond if not the same group. + */ + if (group_test(groupname, sys_ident)) { + sys_declined++; + return; + } +#endif /* AUTOKEY */ + if (sys_bclient == 0) { + sys_restricted++; + return; /* not enabled */ + } if (!AUTH(sys_authenticate | (restrict_mask & - (RES_NOPEER | RES_DONTTRUST)), is_authentic)) - return; /* bad auth */ + (RES_NOPEER | RES_DONTTRUST)), is_authentic)) { + sys_restricted++; + return; /* access denied */ + } /* * Do not respond if unsynchronized or stratum is below * the floor or at or above the ceiling. */ - if (hisleap == LEAP_NOTINSYNC || hisstratum < - sys_floor || hisstratum >= sys_ceiling) - return; /* bad stratum */ - - switch (sys_bclient) { + if ( hisleap == LEAP_NOTINSYNC + || hisstratum < sys_floor + || hisstratum >= sys_ceiling) { + sys_declined++; + return; /* no help */ + } +#ifdef AUTOKEY /* - * If not enabled, just skedaddle. + * Do not respond if Autokey and the opcode is not a + * CRYPTO_ASSOC response with association ID. */ - case 0: - sys_restricted++; - return; /* not enabled */ + if ( crypto_flags && skeyid > NTP_MAXKEY + && (opcode & 0xffff0000) != (CRYPTO_ASSOC | CRYPTO_RESP)) { + sys_declined++; + return; /* protocol error */ + } +#endif /* AUTOKEY */ /* - * Execute the initial volley in order to calibrate the - * propagation delay and run the Autokey protocol, if - * enabled. + * Broadcasts received via a multicast address may + * arrive after a unicast volley has begun + * with the same remote address. newpeer() will not + * find duplicate associations on other local endpoints + * if a non-NULL endpoint is supplied. multicastclient + * ephemeral associations are unique across all local + * endpoints. */ - case 1: - if ((peer = newpeer(&rbufp->recv_srcadr, - rbufp->dstadr, MODE_CLIENT, hisversion, - NTP_MINDPOLL, NTP_MAXDPOLL, FLAG_MCAST | - FLAG_IBURST, MDF_BCLNT, 0, skeyid)) == - NULL) - return; /* system error */ -#ifdef OPENSSL - if (skeyid > NTP_MAXKEY) - crypto_recv(peer, rbufp); -#endif /* OPENSSL */ - return; /* hooray */ - + if (!(INT_MCASTOPEN & rbufp->dstadr->flags)) + match_ep = rbufp->dstadr; + else + match_ep = NULL; /* - * Do not execute the initial volley. + * Determine whether to execute the initial volley. */ - case 2: -#ifdef OPENSSL + if (sys_bdelay != 0) { +#ifdef AUTOKEY /* * If a two-way exchange is not possible, * neither is Autokey. */ - if (skeyid > NTP_MAXKEY) { - msyslog(LOG_INFO, - "receive: autokey requires two-way communication"); + if (crypto_flags && skeyid > NTP_MAXKEY) { + sys_restricted++; return; /* no autokey */ } -#endif /* OPENSSL */ - if ((peer = newpeer(&rbufp->recv_srcadr, - rbufp->dstadr, MODE_BCLIENT, hisversion, - NTP_MINDPOLL, NTP_MAXDPOLL, 0, MDF_BCLNT, 0, - skeyid)) == NULL) - return; /* system error */ +#endif /* AUTOKEY */ + + /* + * Do not execute the volley. Start out in + * broadcast client mode. + */ + peer = newpeer(&rbufp->recv_srcadr, NULL, + match_ep, MODE_BCLIENT, hisversion, + pkt->ppoll, pkt->ppoll, FLAG_PREEMPT, + MDF_BCLNT, 0, skeyid, sys_ident); + if (NULL == peer) { + sys_restricted++; + return; /* ignore duplicate */ + + } else { + peer->delay = sys_bdelay; + } + break; } - break; + + /* + * Execute the initial volley in order to calibrate the + * propagation delay and run the Autokey protocol. + * + * Note that the minpoll is taken from the broadcast + * packet, normally 6 (64 s) and that the poll interval + * is fixed at this value. + */ + peer = newpeer(&rbufp->recv_srcadr, NULL, match_ep, + MODE_CLIENT, hisversion, pkt->ppoll, pkt->ppoll, + FLAG_BC_VOL | FLAG_IBURST | FLAG_PREEMPT, MDF_BCLNT, + 0, skeyid, sys_ident); + if (NULL == peer) { + sys_restricted++; + return; /* ignore duplicate */ + } +#ifdef AUTOKEY + if (skeyid > NTP_MAXKEY) + crypto_recv(peer, rbufp); +#endif /* AUTOKEY */ + + return; /* hooray */ /* * This is the first packet received from a symmetric active @@ -863,150 +1152,322 @@ receive( */ case AM_NEWPASS: +#ifdef AUTOKEY /* - * If the inbound packet is correctly authenticated and - * enabled, a symmetric passive association is - * mobilized. If not but correctly authenticated, a - * symmetric active response is sent. If authentication - * fails, send a crypto-NAK packet. + * Do not respond if not the same group. */ - if (!AUTH(restrict_mask & RES_DONTTRUST, is_authentic)) - { - if (is_authentic == AUTH_ERROR) + if (group_test(groupname, sys_ident)) { + sys_declined++; + return; + } +#endif /* AUTOKEY */ + if (!AUTH(sys_authenticate | (restrict_mask & + (RES_NOPEER | RES_DONTTRUST)), is_authentic)) { + + /* + * If authenticated but cannot mobilize an + * association, send a symmetric passive + * response without mobilizing an association. + * This is for drat broken Windows clients. See + * Microsoft KB 875424 for preferred workaround. + */ + if (AUTH(restrict_mask & RES_DONTTRUST, + is_authentic)) { + fast_xmit(rbufp, MODE_PASSIVE, skeyid, + restrict_mask); + return; /* hooray */ + } + if (is_authentic == AUTH_ERROR) { fast_xmit(rbufp, MODE_ACTIVE, 0, restrict_mask); - return; /* bad auth */ + sys_restricted++; + return; + } + /* [Bug 2941] + * If we got here, the packet isn't part of an + * existing association, it isn't correctly + * authenticated, and it didn't meet either of + * the previous two special cases so we should + * just drop it on the floor. For example, + * crypto-NAKs (is_authentic == AUTH_CRYPTO) + * will make it this far. This is just + * debug-printed and not logged to avoid log + * flooding. + */ + DPRINTF(1, ("receive: at %ld refusing to mobilize passive association" + " with unknown peer %s mode %d keyid %08x len %d auth %d\n", + current_time, stoa(&rbufp->recv_srcadr), + hismode, skeyid, (authlen + has_mac), + is_authentic)); + sys_declined++; + return; } - if (!AUTH(sys_authenticate | (restrict_mask & - RES_NOPEER), is_authentic)) { - fast_xmit(rbufp, MODE_ACTIVE, skeyid, - restrict_mask); - return; /* hooray */ + + /* + * Do not respond if synchronized and if stratum is + * below the floor or at or above the ceiling. Note, + * this allows an unsynchronized peer to synchronize to + * us. It would be very strange if he did and then was + * nipped, but that could only happen if we were + * operating at the top end of the range. It also means + * we will spin an ephemeral association in response to + * MODE_ACTIVE KoDs, which will time out eventually. + */ + if ( hisleap != LEAP_NOTINSYNC + && (hisstratum < sys_floor || hisstratum >= sys_ceiling)) { + sys_declined++; + return; /* no help */ } /* - * Do not respond if stratum is below the floor. + * The message is correctly authenticated and allowed. + * Mobilize a symmetric passive association. */ - if (hisstratum < sys_floor) - return; /* bad stratum */ - - if ((peer = newpeer(&rbufp->recv_srcadr, - rbufp->dstadr, MODE_PASSIVE, hisversion, - NTP_MINDPOLL, NTP_MAXDPOLL, 0, MDF_UCAST, 0, - skeyid)) == NULL) - return; /* system error */ + if ((peer = newpeer(&rbufp->recv_srcadr, NULL, + rbufp->dstadr, MODE_PASSIVE, hisversion, pkt->ppoll, + NTP_MAXDPOLL, 0, MDF_UCAST, 0, skeyid, + sys_ident)) == NULL) { + sys_declined++; + return; /* ignore duplicate */ + } break; + /* * Process regular packet. Nothing special. */ case AM_PROCPKT: + +#ifdef AUTOKEY + /* + * Do not respond if not the same group. + */ + if (group_test(groupname, peer->ident)) { + sys_declined++; + return; + } +#endif /* AUTOKEY */ break; /* * A passive packet matches a passive association. This is * usually the result of reconfiguring a client on the fly. As - * this association might be legitamate and this packet an + * this association might be legitimate and this packet an * attempt to deny service, just ignore it. */ case AM_ERR: + sys_declined++; return; /* * For everything else there is the bit bucket. */ default: + sys_declined++; + return; + } + +#ifdef AUTOKEY + /* + * If the association is configured for Autokey, the packet must + * have a public key ID; if not, the packet must have a + * symmetric key ID. + */ + if ( is_authentic != AUTH_CRYPTO + && ( ((peer->flags & FLAG_SKEY) && skeyid <= NTP_MAXKEY) + || (!(peer->flags & FLAG_SKEY) && skeyid > NTP_MAXKEY))) { + sys_badauth++; return; } +#endif /* AUTOKEY */ + peer->received++; peer->flash &= ~PKT_TEST_MASK; + if (peer->flags & FLAG_XBOGUS) { + peer->flags &= ~FLAG_XBOGUS; + peer->flash |= TEST3; + } /* * Next comes a rigorous schedule of timestamp checking. If the - * transmit timestamp is zero, the server is horribly broken. + * transmit timestamp is zero, the server has not initialized in + * interleaved modes or is horribly broken. */ if (L_ISZERO(&p_xmt)) { - return; /* read rfc1305 */ + peer->flash |= TEST3; /* unsynch */ /* * If the transmit timestamp duplicates a previous one, the * packet is a replay. This prevents the bad guys from replaying * the most recent packet, authenticated or not. */ - } else if (L_ISEQU(&peer->org, &p_xmt)) { - peer->flash |= TEST1; + } else if (L_ISEQU(&peer->xmt, &p_xmt)) { + peer->flash |= TEST1; /* duplicate */ peer->oldpkt++; - return; /* duplicate packet */ - + return; /* - * If this is a broadcast mode packet, skip further checking. + * If this is a broadcast mode packet, skip further checking. If + * an initial volley, bail out now and let the client do its + * stuff. If the origin timestamp is nonzero, this is an + * interleaved broadcast. so restart the protocol. */ - } else if (hismode != MODE_BROADCAST) { - if (L_ISZERO(&p_org)) - peer->flash |= TEST3; /* protocol unsynch */ - else if (!L_ISEQU(&p_org, &peer->xmt)) - peer->flash |= TEST2; /* bogus packet */ - } + } else if (hismode == MODE_BROADCAST) { + if (!L_ISZERO(&p_org) && !(peer->flags & FLAG_XB)) { + peer->flags |= FLAG_XB; + peer->aorg = p_xmt; + peer->borg = rbufp->recv_time; + report_event(PEVNT_XLEAVE, peer, NULL); + return; + } /* - * If unsynchronized or bogus abandon ship. If the crypto machine - * breaks, light the crypto bit and plaint the log. + * Check for bogus packet in basic mode. If found, switch to + * interleaved mode and resynchronize, but only after confirming + * the packet is not bogus in symmetric interleaved mode. + * + * This could also mean somebody is forging packets claiming to + * be from us, attempting to cause our server to KoD us. */ - if (peer->flash & PKT_TEST_MASK) { -#ifdef OPENSSL - if (crypto_flags && (peer->flags & FLAG_SKEY)) { - rval = crypto_recv(peer, rbufp); - if (rval != XEVNT_OK) { - peer_clear(peer, "CRYP"); - peer->flash |= TEST9; /* crypto error */ + } else if (peer->flip == 0) { + if (!L_ISEQU(&p_org, &peer->aorg)) { + peer->bogusorg++; + peer->flash |= TEST2; /* bogus */ + msyslog(LOG_INFO, + "receive: Unexpected origin timestamp from %s", + ntoa(&peer->srcadr)); + if ( !L_ISZERO(&peer->dst) + && L_ISEQU(&p_org, &peer->dst)) { + peer->flip = 1; + report_event(PEVNT_XLEAVE, peer, NULL); } + return; /* Bogus packet, we are done */ + } else { + L_CLR(&peer->aorg); } -#endif /* OPENSSL */ - return; /* unsynch */ - } /* - * The timestamps are valid and the receive packet matches the - * last one sent. If the packet is a crypto-NAK, the server - * might have just changed keys. We reset the association - * and restart the protocol. + * Check for valid nonzero timestamp fields. */ - if (is_authentic == AUTH_CRYPTO) { - peer_clear(peer, "AUTH"); - return; /* crypto-NAK */ + } else if (L_ISZERO(&p_org) || L_ISZERO(&p_rec) || + L_ISZERO(&peer->dst)) { + peer->flash |= TEST3; /* unsynch */ - /* - * If the association is authenticated, the key ID is nonzero - * and received packets must be authenticated. This is designed - * to avoid a bait-and-switch attack, which was possible in past - * versions. If symmetric modes, return a crypto-NAK. The peer - * should restart the protocol. + /* + * Check for bogus packet in interleaved symmetric mode. This + * can happen if a packet is lost, duplicated or crossed. If + * found, flip and resynchronize. */ - } else if (!AUTH(peer->keyid || has_mac || - (restrict_mask & RES_DONTTRUST), is_authentic)) { - peer->flash |= TEST5; - if (has_mac && - (hismode == MODE_ACTIVE || hismode == MODE_PASSIVE)) - fast_xmit(rbufp, MODE_ACTIVE, 0, restrict_mask); - return; /* bad auth */ + } else if ( !L_ISZERO(&peer->dst) + && !L_ISEQU(&p_org, &peer->dst)) { + peer->bogusorg++; + peer->flags |= FLAG_XBOGUS; + peer->flash |= TEST2; /* bogus */ + return; /* Bogus packet, we are done */ } /* - * That was hard and I am sweaty, but the packet is squeaky - * clean. Get on with real work. - * - * Update the origin and destination timestamps. + * If this is a crypto_NAK, the server cannot authenticate a + * client packet. The server might have just changed keys. Clear + * the association and restart the protocol. */ - peer->org = p_xmt; - peer->rec = rbufp->recv_time; + if (is_authentic == AUTH_CRYPTO) { + report_event(PEVNT_AUTH, peer, "crypto_NAK"); + peer->flash |= TEST5; /* bad auth */ + peer->badauth++; + if (peer->flags & FLAG_PREEMPT) { + unpeer(peer); + return; + } +#ifdef AUTOKEY + if (peer->crypto) + peer_clear(peer, "AUTH"); +#endif /* AUTOKEY */ + return; - peer->received++; + /* + * If the digest fails or it's missing for authenticated + * associations, the client cannot authenticate a server + * reply to a client packet previously sent. The loopback check + * is designed to avoid a bait-and-switch attack, which was + * possible in past versions. If symmetric modes, return a + * crypto-NAK. The peer should restart the protocol. + */ + } else if (!AUTH(peer->keyid || has_mac || + (restrict_mask & RES_DONTTRUST), is_authentic)) { + report_event(PEVNT_AUTH, peer, "digest"); + peer->flash |= TEST5; /* bad auth */ + peer->badauth++; + if ( has_mac + && (hismode == MODE_ACTIVE || hismode == MODE_PASSIVE)) + fast_xmit(rbufp, MODE_ACTIVE, 0, restrict_mask); + if (peer->flags & FLAG_PREEMPT) { + unpeer(peer); + return; + } +#ifdef AUTOKEY + if (peer->crypto) + peer_clear(peer, "AUTH"); +#endif /* AUTOKEY */ + return; + } + + /* + * Update the state variables. + */ + if (peer->flip == 0) { + if (hismode != MODE_BROADCAST) + peer->rec = p_xmt; + peer->dst = rbufp->recv_time; + } + peer->xmt = p_xmt; + + /* + * Set the peer ppoll to the maximum of the packet ppoll and the + * peer minpoll. If a kiss-o'-death, set the peer minpoll to + * this maximum and advance the headway to give the sender some + * headroom. Very intricate. + */ + + /* + * Check for any kiss codes. Note this is only used when a server + * responds to a packet request + */ + + kissCode = kiss_code_check(hisleap, hisstratum, hismode, pkt->refid); + + /* + * Check to see if this is a RATE Kiss Code + * Currently this kiss code will accept whatever poll + * rate that the server sends + */ + peer->ppoll = max(peer->minpoll, pkt->ppoll); + if (kissCode == RATEKISS) { + peer->selbroken++; /* Increment the KoD count */ + report_event(PEVNT_RATE, peer, NULL); + if (pkt->ppoll > peer->minpoll) + peer->minpoll = peer->ppoll; + peer->burst = peer->retry = 0; + peer->throttle = (NTP_SHIFT + 1) * (1 << peer->minpoll); + poll_update(peer, pkt->ppoll); + return; /* kiss-o'-death */ + } + if (kissCode != NOKISS) { + peer->selbroken++; /* Increment the KoD count */ + return; /* Drop any other kiss code packets */ + } + + + /* + * That was hard and I am sweaty, but the packet is squeaky + * clean. Get on with real work. + */ peer->timereceived = current_time; if (is_authentic == AUTH_OK) peer->flags |= FLAG_AUTHENTIC; else peer->flags &= ~FLAG_AUTHENTIC; -#ifdef OPENSSL + +#ifdef AUTOKEY /* * More autokey dance. The rules of the cha-cha are as follows: * @@ -1025,77 +1486,122 @@ receive( * 5. Check to see that one or more hashes of the current key ID * matches the previous key ID or ultimate original key ID * obtained from the broadcaster or symmetric peer. If no - * match, sit the dance and wait for timeout. + * match, sit the dance and call for new autokey values. * - * In case of crypto error, fire the orchestra and stop dancing. - * This is considered a permanant error, so light the crypto bit - * to suppress further requests. If preemptable or ephemeral, - * scuttle the ship. + * In case of crypto error, fire the orchestra, stop dancing and + * restart the protocol. */ - if (crypto_flags && (peer->flags & FLAG_SKEY)) { + if (peer->flags & FLAG_SKEY) { + /* + * Decrement remaining autokey hashes. This isn't + * perfect if a packet is lost, but results in no harm. + */ + ap = (struct autokey *)peer->recval.ptr; + if (ap != NULL) { + if (ap->seq > 0) + ap->seq--; + } peer->flash |= TEST8; rval = crypto_recv(peer, rbufp); - if (rval != XEVNT_OK) { - peer_clear(peer, "CRYP"); - peer->flash |= TEST9; /* crypto error */ - if (peer->flags & FLAG_PREEMPT || - !(peer->flags & FLAG_CONFIG)) - unpeer(peer); + if (rval == XEVNT_OK) { + peer->unreach = 0; + } else { + if (rval == XEVNT_ERR) { + report_event(PEVNT_RESTART, peer, + "crypto error"); + peer_clear(peer, "CRYP"); + peer->flash |= TEST9; /* bad crypt */ + if (peer->flags & FLAG_PREEMPT) + unpeer(peer); + } return; + } - } else if (hismode == MODE_SERVER) { + /* + * If server mode, verify the receive key ID matches + * the transmit key ID. + */ + if (hismode == MODE_SERVER) { if (skeyid == peer->keyid) peer->flash &= ~TEST8; + + /* + * If an extension field is present, verify only that it + * has been correctly signed. We don't need a sequence + * check here, but the sequence continues. + */ } else if (!(peer->flash & TEST8)) { peer->pkeyid = skeyid; - } else if ((ap = (struct autokey *)peer->recval.ptr) != - NULL) { + + /* + * Now the fun part. Here, skeyid is the current ID in + * the packet, pkeyid is the ID in the last packet and + * tkeyid is the hash of skeyid. If the autokey values + * have not been received, this is an automatic error. + * If so, check that the tkeyid matches pkeyid. If not, + * hash tkeyid and try again. If the number of hashes + * exceeds the number remaining in the sequence, declare + * a successful failure and refresh the autokey values. + */ + } else if (ap != NULL) { int i; for (i = 0; ; i++) { - if (tkeyid == peer->pkeyid || - tkeyid == ap->key) { + if ( tkeyid == peer->pkeyid + || tkeyid == ap->key) { peer->flash &= ~TEST8; peer->pkeyid = skeyid; + ap->seq -= i; break; } - if (i > ap->seq) + if (i > ap->seq) { + peer->crypto &= + ~CRYPTO_FLAG_AUTO; break; + } tkeyid = session_key( &rbufp->recv_srcadr, dstadr_sin, tkeyid, pkeyid, 0); } + if (peer->flash & TEST8) + report_event(PEVNT_AUTH, peer, "keylist"); } if (!(peer->crypto & CRYPTO_FLAG_PROV)) /* test 9 */ - peer->flash |= TEST8; /* not proventic */ + peer->flash |= TEST8; /* bad autokey */ /* - * If the transmit queue is nonempty, clamp the host - * poll interval to the packet poll interval. + * The maximum lifetime of the protocol is about one + * week before restarting the Autokey protocol to + * refresh certificates and leapseconds values. */ - if (peer->cmmd != 0) { - peer->ppoll = pkt->ppoll; - poll_update(peer, peer->hpoll); + if (current_time > peer->refresh) { + report_event(PEVNT_RESTART, peer, + "crypto refresh"); + peer_clear(peer, "TIME"); + return; } } -#endif /* OPENSSL */ +#endif /* AUTOKEY */ /* * The dance is complete and the flash bits have been lit. Toss * the packet over the fence for processing, which may light up * more flashers. */ - process_packet(peer, pkt); + process_packet(peer, pkt, rbufp->recv_length); /* - * Well, that was nice. If TEST4 is lit, either the crypto - * machine jammed or a kiss-o'-death packet flew in, either of - * which is fatal. + * In interleaved mode update the state variables. Also adjust the + * transmit phase to avoid crossover. */ - if (peer->flash & TEST4) { - msyslog(LOG_INFO, "receive: fatal error %04x for %s", - peer->flash, stoa(&peer->srcadr)); - return; + if (peer->flip != 0) { + peer->rec = p_rec; + peer->dst = rbufp->recv_time; + if (peer->nextdate - current_time < (1U << min(peer->ppoll, + peer->hpoll)) / 2) + peer->nextdate++; + else + peer->nextdate--; } } @@ -1109,66 +1615,76 @@ receive( void process_packet( register struct peer *peer, - register struct pkt *pkt + register struct pkt *pkt, + u_int len ) { double t34, t21; double p_offset, p_del, p_disp; - l_fp p_rec, p_xmt, p_org, p_reftime; - l_fp ci; - u_char pmode, pleap, pstratum; + l_fp p_rec, p_xmt, p_org, p_reftime, ci; + u_char pmode, pleap, pversion, pstratum; + char statstr[NTP_MAXSTRLEN]; +#ifdef ASSYM + int itemp; + double etemp, ftemp, td; +#endif /* ASSYM */ sys_processed++; peer->processed++; p_del = FPTOD(NTOHS_FP(pkt->rootdelay)); - p_disp = FPTOD(NTOHS_FP(pkt->rootdispersion)); + p_offset = 0; + p_disp = FPTOD(NTOHS_FP(pkt->rootdisp)); NTOHL_FP(&pkt->reftime, &p_reftime); + NTOHL_FP(&pkt->org, &p_org); NTOHL_FP(&pkt->rec, &p_rec); NTOHL_FP(&pkt->xmt, &p_xmt); pmode = PKT_MODE(pkt->li_vn_mode); pleap = PKT_LEAP(pkt->li_vn_mode); - if (pmode != MODE_BROADCAST) - NTOHL_FP(&pkt->org, &p_org); - else - p_org = peer->rec; + pversion = PKT_VERSION(pkt->li_vn_mode); pstratum = PKT_TO_STRATUM(pkt->stratum); /* - * Test for kiss-o'death packet) - */ - if (pleap == LEAP_NOTINSYNC && pstratum == STRATUM_UNSPEC) { - if (memcmp(&pkt->refid, "DENY", 4) == 0) { - peer_clear(peer, "DENY"); - peer->flash |= TEST4; /* access denied */ - } - } - - /* - * Capture the header values. + * Capture the header values in the client/peer association.. */ - record_raw_stats(&peer->srcadr, peer->dstadr ? &peer->dstadr->sin : NULL, &p_org, - &p_rec, &p_xmt, &peer->rec); + record_raw_stats(&peer->srcadr, peer->dstadr ? + &peer->dstadr->sin : NULL, + &p_org, &p_rec, &p_xmt, &peer->dst, + pleap, pversion, pmode, pstratum, pkt->ppoll, pkt->precision, + p_del, p_disp, pkt->refid); peer->leap = pleap; peer->stratum = min(pstratum, STRATUM_UNSPEC); peer->pmode = pmode; - peer->ppoll = pkt->ppoll; peer->precision = pkt->precision; peer->rootdelay = p_del; - peer->rootdispersion = p_disp; + peer->rootdisp = p_disp; peer->refid = pkt->refid; /* network byte order */ peer->reftime = p_reftime; /* - * Verify the server is synchronized; that is, the leap bits and - * stratum are valid, the root delay and root dispersion are - * valid and the reference timestamp is not later than the - * transmit timestamp. + * First, if either burst mode is armed, enable the burst. + * Compute the headway for the next packet and delay if + * necessary to avoid exceeding the threshold. */ - if (pleap == LEAP_NOTINSYNC || /* test 6 */ - pstratum < sys_floor || pstratum >= sys_ceiling) - peer->flash |= TEST6; /* peer not synch */ - if (p_del < 0 || p_disp < 0 || p_del / /* test 7 */ - 2 + p_disp >= MAXDISPERSE || !L_ISHIS(&p_xmt, &p_reftime)) + if (peer->retry > 0) { + peer->retry = 0; + if (peer->reach) + peer->burst = min(1 << (peer->hpoll - + peer->minpoll), NTP_SHIFT) - 1; + else + peer->burst = NTP_IBURST - 1; + if (peer->burst > 0) + peer->nextdate = current_time; + } + poll_update(peer, peer->hpoll); + + /* + * Verify the server is synchronized; that is, the leap bits, + * stratum and root distance are valid. + */ + if ( pleap == LEAP_NOTINSYNC /* test 6 */ + || pstratum < sys_floor || pstratum >= sys_ceiling) + peer->flash |= TEST6; /* bad synch or strat */ + if (p_del / 2 + p_disp >= MAXDISPERSE) /* test 7 */ peer->flash |= TEST7; /* bad header */ /* @@ -1177,6 +1693,7 @@ process_packet( * receive() routine. */ if (peer->flash & PKT_TEST_MASK) { + peer->seldisptoolarge++; #ifdef DEBUG if (debug) printf("packet: flash header %04x\n", @@ -1184,11 +1701,15 @@ process_packet( #endif return; } - if (!(peer->reach)) { - report_event(EVNT_REACH, peer); + + /* + * If the peer was previously unreachable, raise a trap. In any + * case, mark it reachable. + */ + if (!peer->reach) { + report_event(PEVNT_REACH, peer, NULL); peer->timereachable = current_time; } - poll_update(peer, peer->hpoll); peer->reach |= 1; /* @@ -1196,8 +1717,7 @@ process_packet( * roundtrip delay and dispersion. The equations are reordered * from the spec for more efficient use of temporaries. For a * broadcast association, offset the last measurement by the - * computed delay during the client/server volley. Note that - * org has been set to the time of last reception. Note the + * computed delay during the client/server volley. Note the * computation of dispersion includes the system precision plus * that due to the frequency error since the origin time. * @@ -1212,52 +1732,203 @@ process_packet( * only half that span. Since the typical first-order * differences are usually very small, they are converted to 64- * bit doubles and all remaining calculations done in floating- - * point arithmetic. This preserves the accuracy while retaining - * the 68-year span. + * double arithmetic. This preserves the accuracy while + * retaining the 68-year span. + * + * There are three interleaving schemes, basic, interleaved + * symmetric and interleaved broadcast. The timestamps are + * idioscyncratically different. See the onwire briefing/white + * paper at www.eecis.udel.edu/~mills for details. * - * Let t1 = p_org, t2 = p_rec, t3 = p_xmt, t4 = peer->rec: - */ - ci = p_xmt; /* t3 - t4 */ - L_SUB(&ci, &peer->rec); - LFPTOD(&ci, t34); - ci = p_rec; /* t2 - t1 */ - L_SUB(&ci, &p_org); - LFPTOD(&ci, t21); - ci = peer->rec; /* t4 - t1 */ - L_SUB(&ci, &p_org); - - /* - * If running in a broadcast association, the clock offset is - * (t1 - t0) corrected by the one-way delay, but we can't - * measure that directly. Therefore, we start up in MODE_CLIENT - * mode, set FLAG_MCAST and exchange eight messages to determine - * the clock offset. When the last message is sent, we switch to - * MODE_BCLIENT mode. The next broadcast message after that - * computes the broadcast offset and clears FLAG_MCAST. - */ - if (pmode == MODE_BROADCAST) { - p_offset = t34; - if (peer->flags & FLAG_MCAST) { - peer->estbdelay = peer->offset - p_offset; - if (peer->hmode == MODE_CLIENT) + * Interleaved symmetric mode + * t1 = peer->aorg/borg, t2 = peer->rec, t3 = p_xmt, + * t4 = peer->dst + */ + if (peer->flip != 0) { + ci = p_xmt; /* t3 - t4 */ + L_SUB(&ci, &peer->dst); + LFPTOD(&ci, t34); + ci = p_rec; /* t2 - t1 */ + if (peer->flip > 0) + L_SUB(&ci, &peer->borg); + else + L_SUB(&ci, &peer->aorg); + LFPTOD(&ci, t21); + p_del = t21 - t34; + p_offset = (t21 + t34) / 2.; + if (p_del < 0 || p_del > 1.) { + snprintf(statstr, sizeof(statstr), + "t21 %.6f t34 %.6f", t21, t34); + report_event(PEVNT_XERR, peer, statstr); + return; + } + + /* + * Broadcast modes + */ + } else if (peer->pmode == MODE_BROADCAST) { + + /* + * Interleaved broadcast mode. Use interleaved timestamps. + * t1 = peer->borg, t2 = p_org, t3 = p_org, t4 = aorg + */ + if (peer->flags & FLAG_XB) { + ci = p_org; /* delay */ + L_SUB(&ci, &peer->aorg); + LFPTOD(&ci, t34); + ci = p_org; /* t2 - t1 */ + L_SUB(&ci, &peer->borg); + LFPTOD(&ci, t21); + peer->aorg = p_xmt; + peer->borg = peer->dst; + if (t34 < 0 || t34 > 1.) { + snprintf(statstr, sizeof(statstr), + "offset %.6f delay %.6f", t21, t34); + report_event(PEVNT_XERR, peer, statstr); return; + } + p_offset = t21; + peer->xleave = t34; + + /* + * Basic broadcast - use direct timestamps. + * t3 = p_xmt, t4 = peer->dst + */ + } else { + ci = p_xmt; /* t3 - t4 */ + L_SUB(&ci, &peer->dst); + LFPTOD(&ci, t34); + p_offset = t34; + } - peer->flags &= ~(FLAG_MCAST | FLAG_BURST); + /* + * When calibration is complete and the clock is + * synchronized, the bias is calculated as the difference + * between the unicast timestamp and the broadcast + * timestamp. This works for both basic and interleaved + * modes. + */ + if (FLAG_BC_VOL & peer->flags) { + peer->flags &= ~FLAG_BC_VOL; + peer->delay = fabs(peer->offset - p_offset) * 2; } - p_offset += peer->estbdelay; p_del = peer->delay; - p_disp = 0; + p_offset += p_del / 2; + + + /* + * Basic mode, otherwise known as the old fashioned way. + * + * t1 = p_org, t2 = p_rec, t3 = p_xmt, t4 = peer->dst + */ } else { + ci = p_xmt; /* t3 - t4 */ + L_SUB(&ci, &peer->dst); + LFPTOD(&ci, t34); + ci = p_rec; /* t2 - t1 */ + L_SUB(&ci, &p_org); + LFPTOD(&ci, t21); + p_del = fabs(t21 - t34); p_offset = (t21 + t34) / 2.; - p_del = t21 - t34; - LFPTOD(&ci, p_disp); - p_disp = LOGTOD(sys_precision) + - LOGTOD(peer->precision) + clock_phi * p_disp; } p_del = max(p_del, LOGTOD(sys_precision)); - clock_filter(peer, p_offset, p_del, p_disp); - record_peer_stats(&peer->srcadr, ctlpeerstatus(peer), - peer->offset, peer->delay, peer->disp, peer->jitter); + p_disp = LOGTOD(sys_precision) + LOGTOD(peer->precision) + + clock_phi * p_del; + +#if ASSYM + /* + * This code calculates the outbound and inbound data rates by + * measuring the differences between timestamps at different + * packet lengths. This is helpful in cases of large asymmetric + * delays commonly experienced on deep space communication + * links. + */ + if (peer->t21_last > 0 && peer->t34_bytes > 0) { + itemp = peer->t21_bytes - peer->t21_last; + if (itemp > 25) { + etemp = t21 - peer->t21; + if (fabs(etemp) > 1e-6) { + ftemp = itemp / etemp; + if (ftemp > 1000.) + peer->r21 = ftemp; + } + } + itemp = len - peer->t34_bytes; + if (itemp > 25) { + etemp = -t34 - peer->t34; + if (fabs(etemp) > 1e-6) { + ftemp = itemp / etemp; + if (ftemp > 1000.) + peer->r34 = ftemp; + } + } + } + + /* + * The following section compensates for different data rates on + * the outbound (d21) and inbound (t34) directions. To do this, + * it finds t such that r21 * t - r34 * (d - t) = 0, where d is + * the roundtrip delay. Then it calculates the correction as a + * fraction of d. + */ + peer->t21 = t21; + peer->t21_last = peer->t21_bytes; + peer->t34 = -t34; + peer->t34_bytes = len; +#ifdef DEBUG + if (debug > 1) + printf("packet: t21 %.9lf %d t34 %.9lf %d\n", peer->t21, + peer->t21_bytes, peer->t34, peer->t34_bytes); +#endif + if (peer->r21 > 0 && peer->r34 > 0 && p_del > 0) { + if (peer->pmode != MODE_BROADCAST) + td = (peer->r34 / (peer->r21 + peer->r34) - + .5) * p_del; + else + td = 0; + + /* + * Unfortunately, in many cases the errors are + * unacceptable, so for the present the rates are not + * used. In future, we might find conditions where the + * calculations are useful, so this should be considered + * a work in progress. + */ + t21 -= td; + t34 -= td; +#ifdef DEBUG + if (debug > 1) + printf("packet: del %.6lf r21 %.1lf r34 %.1lf %.6lf\n", + p_del, peer->r21 / 1e3, peer->r34 / 1e3, + td); +#endif + } +#endif /* ASSYM */ + + /* + * That was awesome. Now hand off to the clock filter. + */ + clock_filter(peer, p_offset + peer->bias, p_del, p_disp); + + /* + * If we are in broadcast calibrate mode, return to broadcast + * client mode when the client is fit and the autokey dance is + * complete. + */ + if ( (FLAG_BC_VOL & peer->flags) + && MODE_CLIENT == peer->hmode + && !(TEST11 & peer_unfit(peer))) { /* distance exceeded */ +#ifdef AUTOKEY + if (peer->flags & FLAG_SKEY) { + if (!(~peer->crypto & CRYPTO_FLAG_ALL)) + peer->hmode = MODE_BCLIENT; + } else { + peer->hmode = MODE_BCLIENT; + } +#else /* !AUTOKEY follows */ + peer->hmode = MODE_BCLIENT; +#endif /* !AUTOKEY */ + } } @@ -1265,39 +1936,98 @@ process_packet( * clock_update - Called at system process update intervals. */ static void -clock_update(void) +clock_update( + struct peer *peer /* peer structure pointer */ + ) { - u_char oleap; - u_char ostratum; double dtemp; + l_fp now; +#ifdef HAVE_LIBSCF_H + char *fmri; +#endif /* HAVE_LIBSCF_H */ /* - * There must be a system peer at this point. If we just changed - * the system peer, but have a newer sample from the old one, - * wait until newer data are available. + * Update the system state variables. We do this very carefully, + * as the poll interval might need to be clamped differently. */ - if (sys_poll < sys_peer->minpoll) - sys_poll = sys_peer->minpoll; - if (sys_poll > sys_peer->maxpoll) - sys_poll = sys_peer->maxpoll; - poll_update(sys_peer, sys_poll); - if (sys_peer->epoch <= sys_clocktime) - return; + sys_peer = peer; + sys_epoch = peer->epoch; + if (sys_poll < peer->minpoll) + sys_poll = peer->minpoll; + if (sys_poll > peer->maxpoll) + sys_poll = peer->maxpoll; + poll_update(peer, sys_poll); + sys_stratum = min(peer->stratum + 1, STRATUM_UNSPEC); + if ( peer->stratum == STRATUM_REFCLOCK + || peer->stratum == STRATUM_UNSPEC) + sys_refid = peer->refid; + else + sys_refid = addr2refid(&peer->srcadr); + /* + * Root Dispersion (E) is defined (in RFC 5905) as: + * + * E = p.epsilon_r + p.epsilon + p.psi + PHI*(s.t - p.t) + |THETA| + * + * where: + * p.epsilon_r is the PollProc's root dispersion + * p.epsilon is the PollProc's dispersion + * p.psi is the PollProc's jitter + * THETA is the combined offset + * + * NB: Think Hard about where these numbers come from and + * what they mean. When did peer->update happen? Has anything + * interesting happened since then? What values are the most + * defensible? Why? + * + * DLM thinks this equation is probably the best of all worse choices. + */ + dtemp = peer->rootdisp + + peer->disp + + sys_jitter + + clock_phi * (current_time - peer->update) + + fabs(sys_offset); + + if (dtemp > sys_mindisp) + sys_rootdisp = dtemp; + else + sys_rootdisp = sys_mindisp; + sys_rootdelay = peer->delay + peer->rootdelay; + sys_reftime = peer->dst; #ifdef DEBUG if (debug) - printf("clock_update: at %ld assoc %d \n", current_time, - peer_associations); + printf( + "clock_update: at %lu sample %lu associd %d\n", + current_time, peer->epoch, peer->associd); #endif - oleap = sys_leap; - ostratum = sys_stratum; - switch (local_clock(sys_peer, sys_offset)) { + + /* + * Comes now the moment of truth. Crank the clock discipline and + * see what comes out. + */ + switch (local_clock(peer, sys_offset)) { /* * Clock exceeds panic threshold. Life as we know it ends. */ case -1: - report_event(EVNT_SYSFAULT, NULL); +#ifdef HAVE_LIBSCF_H + /* + * For Solaris enter the maintenance mode. + */ + if ((fmri = getenv("SMF_FMRI")) != NULL) { + if (smf_maintain_instance(fmri, 0) < 0) { + printf("smf_maintain_instance: %s\n", + scf_strerror(scf_error())); + exit(1); + } + /* + * Sleep until SMF kills us. + */ + for (;;) + pause(); + } +#endif /* HAVE_LIBSCF_H */ exit (-1); /* not reached */ @@ -1306,64 +2036,68 @@ clock_update(void) */ case 2: clear_all(); - sys_leap = LEAP_NOTINSYNC; + set_sys_leap(LEAP_NOTINSYNC); sys_stratum = STRATUM_UNSPEC; - sys_peer = NULL; - sys_rootdelay = 0; - sys_rootdispersion = 0; memcpy(&sys_refid, "STEP", 4); - report_event(EVNT_CLOCKRESET, NULL); + sys_rootdelay = 0; + sys_rootdisp = 0; + L_CLR(&sys_reftime); + sys_jitter = LOGTOD(sys_precision); + leapsec_reset_frame(); break; /* - * Clock was slewed. Update the system stratum, leap bits, root - * delay, root dispersion, reference ID and reference time. If - * the leap changes, we gotta reroll the keys. Except for - * reference clocks, the minimum dispersion increment is not - * less than sys_mindisp. + * Clock was slewed. Handle the leapsecond stuff. */ case 1: - sys_leap = leap_next; - sys_stratum = min(sys_peer->stratum + 1, - STRATUM_UNSPEC); - sys_reftime = sys_peer->rec; /* - * In orphan mode the stratum defaults to the orphan - * stratum. The root delay is set to a random value - * generated at startup. The root dispersion is set from - * the peer dispersion; the peer root dispersion is - * ignored. + * If this is the first time the clock is set, reset the + * leap bits. If crypto, the timer will goose the setup + * process. */ - dtemp = sys_peer->disp + clock_phi * (current_time - - sys_peer->update) + sys_jitter + - fabs(sys_peer->offset); -#ifdef REFCLOCK - if (!(sys_peer->flags & FLAG_REFCLOCK) && dtemp < - sys_mindisp) - dtemp = sys_mindisp; -#else - if (dtemp < sys_mindisp) - dtemp = sys_mindisp; -#endif /* REFCLOCK */ - if (sys_stratum >= sys_orphan) { - sys_stratum = sys_orphan; - sys_rootdelay = sys_peer->delay; - sys_rootdispersion = dtemp; - } else { - sys_rootdelay = sys_peer->delay + - sys_peer->rootdelay; - sys_rootdispersion = dtemp + - sys_peer->rootdispersion; - } - if (oleap == LEAP_NOTINSYNC) { - report_event(EVNT_SYNCCHG, NULL); -#ifdef OPENSSL - expire_all(); - crypto_update(); -#endif /* OPENSSL */ + if (sys_leap == LEAP_NOTINSYNC) { + set_sys_leap(LEAP_NOWARNING); +#ifdef AUTOKEY + if (crypto_flags) + crypto_update(); +#endif /* AUTOKEY */ + /* + * If our parent process is waiting for the + * first clock sync, send them home satisfied. + */ +#ifdef HAVE_WORKING_FORK + if (waitsync_fd_to_close != -1) { + close(waitsync_fd_to_close); + waitsync_fd_to_close = -1; + DPRINTF(1, ("notified parent --wait-sync is done\n")); + } +#endif /* HAVE_WORKING_FORK */ + + } + + /* + * If there is no leap second pending and the number of + * survivor leap bits is greater than half the number of + * survivors, try to schedule a leap for the end of the + * current month. (This only works if no leap second for + * that range is in the table, so doing this more than + * once is mostly harmless.) + */ + if (leapsec == LSPROX_NOWARN) { + if ( leap_vote_ins > leap_vote_del + && leap_vote_ins > sys_survivors / 2) { + get_systime(&now); + leapsec_add_dyn(TRUE, now.l_ui, NULL); + } + if ( leap_vote_del > leap_vote_ins + && leap_vote_del > sys_survivors / 2) { + get_systime(&now); + leapsec_add_dyn(FALSE, now.l_ui, NULL); + } } break; + /* * Popcorn spike or step threshold exceeded. Pretend it never * happened. @@ -1371,8 +2105,6 @@ clock_update(void) default: break; } - if (ostratum != sys_stratum) - report_event(EVNT_PEERSTCHG, NULL); } @@ -1381,115 +2113,129 @@ clock_update(void) */ void poll_update( - struct peer *peer, - int mpoll + struct peer *peer, /* peer structure pointer */ + u_char mpoll ) { - int hpoll; + u_long next, utemp; + u_char hpoll; /* * This routine figures out when the next poll should be sent. - * That turns out to be wickedly complicated. The big problem is - * that sometimes the time for the next poll is in the past. - * Watch out for races here between the receive process and the - * poll process. The key assertion is that, if nextdate equals - * current_time, the call is from the poll process; otherwise, - * it is from the receive process. + * That turns out to be wickedly complicated. One problem is + * that sometimes the time for the next poll is in the past when + * the poll interval is reduced. We watch out for races here + * between the receive process and the poll process. * - * First, bracket the poll interval according to the type of - * association and options. If a fixed interval is configured, - * use minpoll. This primarily is for reference clocks, but - * works for any association. + * Clamp the poll interval between minpoll and maxpoll. */ - if (peer->flags & FLAG_FIXPOLL) { - hpoll = peer->minpoll; + hpoll = max(min(peer->maxpoll, mpoll), peer->minpoll); +#ifdef AUTOKEY /* - * The ordinary case; clamp the poll interval between minpoll - * and maxpoll. - */ - } else { - hpoll = max(min(peer->maxpoll, mpoll), peer->minpoll); - } -#ifdef OPENSSL - /* - * Bit of crass arrogance at this point. If the poll interval - * has changed and we have a keylist, the lifetimes in the - * keylist are probably bogus. In this case purge the keylist - * and regenerate it later. + * If during the crypto protocol the poll interval has changed, + * the lifetimes in the key list are probably bogus. Purge the + * the key list and regenerate it later. */ - if (hpoll != peer->hpoll) + if ((peer->flags & FLAG_SKEY) && hpoll != peer->hpoll) key_expire(peer); -#endif /* OPENSSL */ +#endif /* AUTOKEY */ peer->hpoll = hpoll; /* - * Now we figure out if there is an override. If during the - * crypto protocol and a message is pending, make it wait not - * more than two seconds. - */ -#ifdef OPENSSL - if (peer->cmmd != NULL && (sys_leap != LEAP_NOTINSYNC || - peer->crypto)) { - peer->nextdate = current_time + RESP_DELAY; - - /* - * If we get called from the receive routine while a burst is - * pending, just slink away. If from the poll routine and a - * reference clock or a pending crypto response, delay for one - * second. If this is the first sent in a burst, wait for the - * modem to come up. For others in the burst, delay two seconds. + * There are three variables important for poll scheduling, the + * current time (current_time), next scheduled time (nextdate) + * and the earliest time (utemp). The earliest time is 2 s + * seconds, but could be more due to rate management. When + * sending in a burst, use the earliest time. When not in a + * burst but with a reply pending, send at the earliest time + * unless the next scheduled time has not advanced. This can + * only happen if multiple replies are pending in the same + * response interval. Otherwise, send at the later of the next + * scheduled time and the earliest time. + * + * Now we figure out if there is an override. If a burst is in + * progress and we get called from the receive process, just + * slink away. If called from the poll process, delay 1 s for a + * reference clock, otherwise 2 s. */ - } else if (peer->burst > 0) { -#else /* OPENSSL */ + utemp = current_time + max(peer->throttle - (NTP_SHIFT - 1) * + (1 << peer->minpoll), ntp_minpkt); if (peer->burst > 0) { -#endif /* OPENSSL */ - if (peer->nextdate != current_time) + if (peer->nextdate > current_time) return; #ifdef REFCLOCK else if (peer->flags & FLAG_REFCLOCK) - peer->nextdate += RESP_DELAY; + peer->nextdate = current_time + RESP_DELAY; #endif /* REFCLOCK */ - else if (peer->flags & (FLAG_IBURST | FLAG_BURST) && - peer->burst == NTP_BURST) - peer->nextdate += sys_calldelay; else - peer->nextdate += BURST_DELAY; + peer->nextdate = utemp; + +#ifdef AUTOKEY /* - * The ordinary case; use the minimum of the host and peer - * intervals, but not less than minpoll. In other words, - * oversampling is okay but understampling is evil. + * If a burst is not in progress and a crypto response message + * is pending, delay 2 s, but only if this is a new interval. */ - } else { - peer->nextdate = peer->outdate + - RANDPOLL(max(min(peer->ppoll, hpoll), - peer->minpoll)); - } + } else if (peer->cmmd != NULL) { + if (peer->nextdate > current_time) { + if (peer->nextdate + ntp_minpkt != utemp) + peer->nextdate = utemp; + } else { + peer->nextdate = utemp; + } +#endif /* AUTOKEY */ /* - * If the time for the next poll has already happened, bring it - * up to the next second after this one. This way the only way - * to get nexdate == current time is from the poll routine. + * The ordinary case. If a retry, use minpoll; if unreachable, + * use host poll; otherwise, use the minimum of host and peer + * polls; In other words, oversampling is okay but + * understampling is evil. Use the maximum of this value and the + * headway. If the average headway is greater than the headway + * threshold, increase the headway by the minimum interval. */ - if (peer->nextdate <= current_time) - peer->nextdate = current_time + 1; -#ifdef DEBUG - if (debug > 1) - printf("poll_update: at %lu %s flags %04x poll %d burst %d last %lu next %lu\n", - current_time, ntoa(&peer->srcadr), peer->flags, - peer->hpoll, peer->burst, peer->outdate, - peer->nextdate); -#endif + } else { + if (peer->retry > 0) + hpoll = peer->minpoll; + else if (!(peer->reach)) + hpoll = peer->hpoll; + else + hpoll = min(peer->ppoll, peer->hpoll); +#ifdef REFCLOCK + if (peer->flags & FLAG_REFCLOCK) + next = 1 << hpoll; + else +#endif /* REFCLOCK */ + next = ((0x1000UL | (ntp_random() & 0x0ff)) << + hpoll) >> 12; + next += peer->outdate; + if (next > utemp) + peer->nextdate = next; + else + peer->nextdate = utemp; + if (peer->throttle > (1 << peer->minpoll)) + peer->nextdate += ntp_minpkt; + } + DPRINTF(2, ("poll_update: at %lu %s poll %d burst %d retry %d head %d early %lu next %lu\n", + current_time, ntoa(&peer->srcadr), peer->hpoll, + peer->burst, peer->retry, peer->throttle, + utemp - current_time, peer->nextdate - + current_time)); } + /* - * peer_crypto_clear - discard crypto information + * peer_clear - clear peer filter registers. See Section 3.4.8 of the + * spec. */ void -peer_crypto_clear( - struct peer *peer - ) +peer_clear( + struct peer *peer, /* peer structure */ + const char *ident /* tally lights */ + ) { + u_char u; + +#ifdef AUTOKEY /* * If cryptographic credentials have been acquired, toss them to * Valhalla. Note that autokeys are ephemeral, in that they are @@ -1499,117 +2245,76 @@ peer_crypto_clear( * purged, too. This makes it much harder to sneak in some * unauthenticated data in the clock filter. */ - DPRINTF(1, ("peer_crypto_clear: at %ld next %ld assoc ID %d\n", - current_time, peer->nextdate, peer->associd)); - -#ifdef OPENSSL - peer->assoc = 0; - peer->crypto = 0; - - if (peer->pkey != NULL) - EVP_PKEY_free(peer->pkey); - peer->pkey = NULL; - - peer->digest = NULL; /* XXX MEMLEAK? check whether this needs to be freed in any way - never was freed */ - - if (peer->subject != NULL) - free(peer->subject); - peer->subject = NULL; - - if (peer->issuer != NULL) - free(peer->issuer); - peer->issuer = NULL; - - peer->pkeyid = 0; - - peer->pcookie = 0; - - if (peer->ident_pkey != NULL) - EVP_PKEY_free(peer->ident_pkey); - peer->ident_pkey = NULL; - - memset(&peer->fstamp, 0, sizeof(peer->fstamp)); - + key_expire(peer); if (peer->iffval != NULL) BN_free(peer->iffval); - peer->iffval = NULL; - - if (peer->grpkey != NULL) - BN_free(peer->grpkey); - peer->grpkey = NULL; - value_free(&peer->cookval); value_free(&peer->recval); - - if (peer->cmmd != NULL) { - free(peer->cmmd); - peer->cmmd = NULL; - } - - key_expire(peer); - value_free(&peer->encrypt); -#endif /* OPENSSL */ -} - -/* - * peer_clear - clear peer filter registers. See Section 3.4.8 of the spec. - */ -void -peer_clear( - struct peer *peer, /* peer structure */ - char *ident /* tally lights */ - ) -{ - int i; - - peer_crypto_clear(peer); - - if (peer == sys_peer) - sys_peer = NULL; + value_free(&peer->sndval); + if (peer->cmmd != NULL) + free(peer->cmmd); + if (peer->subject != NULL) + free(peer->subject); + if (peer->issuer != NULL) + free(peer->issuer); +#endif /* AUTOKEY */ /* - * Wipe the association clean and initialize the nonzero values. + * Clear all values, including the optional crypto values above. */ - memset(CLEAR_TO_ZERO(peer), 0, LEN_CLEAR_TO_ZERO); - peer->estbdelay = sys_bdelay; + memset(CLEAR_TO_ZERO(peer), 0, LEN_CLEAR_TO_ZERO(peer)); peer->ppoll = peer->maxpoll; peer->hpoll = peer->minpoll; peer->disp = MAXDISPERSE; + peer->flash = peer_unfit(peer); peer->jitter = LOGTOD(sys_precision); - for (i = 0; i < NTP_SHIFT; i++) { - peer->filter_order[i] = i; - peer->filter_disp[i] = MAXDISPERSE; + + /* + * If interleave mode, initialize the alternate origin switch. + */ + if (peer->flags & FLAG_XLEAVE) + peer->flip = 1; + for (u = 0; u < NTP_SHIFT; u++) { + peer->filter_order[u] = u; + peer->filter_disp[u] = MAXDISPERSE; } #ifdef REFCLOCK if (!(peer->flags & FLAG_REFCLOCK)) { +#endif peer->leap = LEAP_NOTINSYNC; peer->stratum = STRATUM_UNSPEC; memcpy(&peer->refid, ident, 4); +#ifdef REFCLOCK } -#else - peer->leap = LEAP_NOTINSYNC; - peer->stratum = STRATUM_UNSPEC; - memcpy(&peer->refid, ident, 4); -#endif /* REFCLOCK */ +#endif /* * During initialization use the association count to spread out - * the polls at one-second intervals. Othersie, randomize over - * the minimum poll interval in order to avoid broadcast - * implosion. + * the polls at one-second intervals. Passive associations' + * first poll is delayed by the "discard minimum" to avoid rate + * limiting. Other post-startup new or cleared associations + * randomize the first poll over the minimum poll interval to + * avoid implosion. */ peer->nextdate = peer->update = peer->outdate = current_time; - if (initializing) + if (initializing) { peer->nextdate += peer_associations; - else if (peer->hmode == MODE_PASSIVE) - peer->nextdate += RESP_DELAY; - else - peer->nextdate += (ntp_random() & ((1 << NTP_MINDPOLL) - - 1)); - - DPRINTF(1, ("peer_clear: at %ld next %ld assoc ID %d refid %s\n", - current_time, peer->nextdate, peer->associd, ident)); + } else if (MODE_PASSIVE == peer->hmode) { + peer->nextdate += ntp_minpkt; + } else { + peer->nextdate += ntp_random() % peer->minpoll; + } +#ifdef AUTOKEY + peer->refresh = current_time + (1 << NTP_REFRESH); +#endif /* AUTOKEY */ +#ifdef DEBUG + if (debug) + printf( + "peer_clear: at %ld next %ld associd %d refid %s\n", + current_time, peer->nextdate, peer->associd, + ident); +#endif } @@ -1629,19 +2334,20 @@ clock_filter( int ord[NTP_SHIFT]; /* index vector */ int i, j, k, m; double dtemp, etemp; + char tbuf[80]; /* - * Shift the new sample into the register and discard the oldest - * one. The new offset and delay come directly from the - * timestamp calculations. The dispersion grows from the last - * outbound packet or reference clock update to the present time - * and increased by the sum of the peer precision and the system - * precision. The delay can sometimes swing negative due to - * frequency skew, so it is clamped non-negative. + * A sample consists of the offset, delay, dispersion and epoch + * of arrival. The offset and delay are determined by the on- + * wire protocol. The dispersion grows from the last outbound + * packet to the arrival of this one increased by the sum of the + * peer precision and the system precision as required by the + * error budget. First, shift the new arrival into the shift + * register discarding the oldest one. */ j = peer->filter_nextpt; peer->filter_offset[j] = sample_offset; - peer->filter_delay[j] = max(0, sample_delay); + peer->filter_delay[j] = sample_delay; peer->filter_disp[j] = sample_disp; peer->filter_epoch[j] = current_time; j = (j + 1) % NTP_SHIFT; @@ -1649,40 +2355,41 @@ clock_filter( /* * Update dispersions since the last update and at the same - * time initialize the distance and index lists. The distance - * list uses a compound metric. If the sample is valid and - * younger than the minimum Allan intercept, use delay; - * otherwise, use biased dispersion. + * time initialize the distance and index lists. Since samples + * become increasingly uncorrelated beyond the Allan intercept, + * only under exceptional cases will an older sample be used. + * Therefore, the distance list uses a compound metric. If the + * dispersion is greater than the maximum dispersion, clamp the + * distance at that value. If the time since the last update is + * less than the Allan intercept use the delay; otherwise, use + * the sum of the delay and dispersion. */ dtemp = clock_phi * (current_time - peer->update); peer->update = current_time; for (i = NTP_SHIFT - 1; i >= 0; i--) { if (i != 0) peer->filter_disp[j] += dtemp; - if (peer->filter_disp[j] >= MAXDISPERSE) + if (peer->filter_disp[j] >= MAXDISPERSE) { peer->filter_disp[j] = MAXDISPERSE; - if (peer->filter_disp[j] >= MAXDISPERSE) dst[i] = MAXDISPERSE; - else if (peer->update - peer->filter_epoch[j] > - allan_xpt) - dst[i] = sys_maxdist + peer->filter_disp[j]; - else + } else if (peer->update - peer->filter_epoch[j] > + (u_long)ULOGTOD(allan_xpt)) { + dst[i] = peer->filter_delay[j] + + peer->filter_disp[j]; + } else { dst[i] = peer->filter_delay[j]; + } ord[i] = j; - j++; j %= NTP_SHIFT; + j = (j + 1) % NTP_SHIFT; } - /* - * If the clock discipline has stabilized, sort the samples in - * both lists by distance. Note, we do not displace a higher - * distance sample by a lower distance one unless lower by at - * least the precision. + /* + * If the clock has stabilized, sort the samples by distance. */ - if (state == 4) { + if (freq_cnt == 0) { for (i = 1; i < NTP_SHIFT; i++) { for (j = 0; j < i; j++) { - if (dst[j] > dst[i] + - LOGTOD(sys_precision)) { + if (dst[j] > dst[i]) { k = ord[j]; ord[j] = ord[i]; ord[i] = k; @@ -1696,26 +2403,27 @@ clock_filter( /* * Copy the index list to the association structure so ntpq - * can see it later. Prune the distance list to samples less - * than max distance, but keep at least two valid samples for - * jitter calculation. + * can see it later. Prune the distance list to leave only + * samples less than the maximum dispersion, which disfavors + * uncorrelated samples older than the Allan intercept. To + * further improve the jitter estimate, of the remainder leave + * only samples less than the maximum distance, but keep at + * least two samples for jitter calculation. */ m = 0; for (i = 0; i < NTP_SHIFT; i++) { peer->filter_order[i] = (u_char) ord[i]; - if (dst[i] >= MAXDISPERSE || (m >= 2 && dst[i] >= - sys_maxdist)) + if ( dst[i] >= MAXDISPERSE + || (m >= 2 && dst[i] >= sys_maxdist)) continue; m++; } - + /* * Compute the dispersion and jitter. The dispersion is weighted * exponentially by NTP_FWEIGHT (0.5) so it is normalized close * to 1.0. The jitter is the RMS differences relative to the - * lowest delay sample. If no acceptable samples remain in the - * shift register, quietly tiptoe home leaving only the - * dispersion. + * lowest delay sample. */ peer->disp = peer->jitter = 0; k = ord[0]; @@ -1734,9 +2442,10 @@ clock_filter( * save the offset, delay and jitter. Note the jitter must not * be less than the precision. */ - if (m == 0) + if (m == 0) { + clock_select(); return; - + } etemp = fabs(peer->offset - peer->filter_offset[k]); peer->offset = peer->filter_offset[k]; peer->delay = peer->filter_delay[k]; @@ -1745,47 +2454,52 @@ clock_filter( peer->jitter = max(SQRT(peer->jitter), LOGTOD(sys_precision)); /* - * A new sample is useful only if it is younger than the last - * one used. Note the order is FIFO if the clock discipline has - * not stabilized. + * If the the new sample and the current sample are both valid + * and the difference between their offsets exceeds CLOCK_SGATE + * (3) times the jitter and the interval between them is less + * than twice the host poll interval, consider the new sample + * a popcorn spike and ignore it. */ - if (peer->filter_epoch[k] <= peer->epoch) { -#ifdef DEBUG - if (debug) - printf("clock_filter: discard %lu\n", - peer->epoch - peer->filter_epoch[k]); -#endif + if ( peer->disp < sys_maxdist + && peer->filter_disp[k] < sys_maxdist + && etemp > CLOCK_SGATE * peer->jitter + && peer->filter_epoch[k] - peer->epoch + < 2. * ULOGTOD(peer->hpoll)) { + snprintf(tbuf, sizeof(tbuf), "%.6f s", etemp); + report_event(PEVNT_POPCORN, peer, tbuf); return; } /* - * If the difference between the last offset and the current one - * exceeds the jitter by CLOCK_SGATE and the interval since the - * last update is less than twice the system poll interval, - * consider the update a popcorn spike and ignore it. + * A new minimum sample is useful only if it is later than the + * last one used. In this design the maximum lifetime of any + * sample is not greater than eight times the poll interval, so + * the maximum interval between minimum samples is eight + * packets. */ - if (etemp > CLOCK_SGATE * peer->jitter && m > 1 && - peer->filter_epoch[k] - peer->epoch < 2. * - ULOGTOD(sys_poll)) { -#ifdef DEBUG - if (debug) - printf("clock_filter: popcorn %.6f %.6f\n", - etemp, dtemp); + if (peer->filter_epoch[k] <= peer->epoch) { +#if DEBUG + if (debug > 1) + printf("clock_filter: old sample %lu\n", current_time - + peer->filter_epoch[k]); #endif return; } + peer->epoch = peer->filter_epoch[k]; /* * The mitigated sample statistics are saved for later - * processing. If not in a burst, tickle the select. + * processing. If not synchronized or not in a burst, tickle the + * clock select algorithm. */ - peer->epoch = peer->filter_epoch[k]; + record_peer_stats(&peer->srcadr, ctlpeerstatus(peer), + peer->offset, peer->delay, peer->disp, peer->jitter); #ifdef DEBUG if (debug) printf( - "clock_filter: n %d off %.6f del %.6f dsp %.6f jit %.6f, age %lu\n", + "clock_filter: n %d off %.6f del %.6f dsp %.6f jit %.6f\n", m, peer->offset, peer->delay, peer->disp, - peer->jitter, current_time - peer->epoch); + peer->jitter); #endif if (peer->burst == 0 || sys_leap == LEAP_NOTINSYNC) clock_select(); @@ -1795,69 +2509,68 @@ clock_filter( /* * clock_select - find the pick-of-the-litter clock * - * LOCKCLOCK: If the local clock is the prefer peer, it will always be - * enabled, even if declared falseticker, (2) only the prefer peer can - * be selected as the system peer, (3) if the external source is down, - * the system leap bits are set to 11 and the stratum set to infinity. + * LOCKCLOCK: (1) If the local clock is the prefer peer, it will always + * be enabled, even if declared falseticker, (2) only the prefer peer + * can be selected as the system peer, (3) if the external source is + * down, the system leap bits are set to 11 and the stratum set to + * infinity. */ void clock_select(void) { struct peer *peer; int i, j, k, n; - int nlist, nl3; - - int allow, osurv; + int nlist, nl2; + int allow; + int speer; double d, e, f, g; double high, low; - double synch[NTP_MAXASSOC], error[NTP_MAXASSOC]; + double speermet; + double orphmet = 2.0 * U_INT32_MAX; /* 2x is greater than */ + struct endpoint endp; struct peer *osys_peer; + struct peer *sys_prefer = NULL; /* prefer peer */ + struct peer *typesystem = NULL; + struct peer *typeorphan = NULL; +#ifdef REFCLOCK struct peer *typeacts = NULL; struct peer *typelocal = NULL; - struct peer *typesystem = NULL; - - static int list_alloc = 0; + struct peer *typepps = NULL; +#endif /* REFCLOCK */ static struct endpoint *endpoint = NULL; static int *indx = NULL; - static struct peer **peer_list = NULL; + static peer_select *peers = NULL; static u_int endpoint_size = 0; + static u_int peers_size = 0; static u_int indx_size = 0; - static u_int peer_list_size = 0; + size_t octets; /* * Initialize and create endpoint, index and peer lists big * enough to handle all associations. */ osys_peer = sys_peer; - sys_peer = NULL; - sys_pps = NULL; - sys_prefer = NULL; - osurv = sys_survivors; sys_survivors = 0; #ifdef LOCKCLOCK - sys_leap = LEAP_NOTINSYNC; + set_sys_leap(LEAP_NOTINSYNC); sys_stratum = STRATUM_UNSPEC; memcpy(&sys_refid, "DOWN", 4); #endif /* LOCKCLOCK */ - nlist = 0; - for (n = 0; n < NTP_HASH_SIZE; n++) - nlist += peer_hash_count[n]; - if (nlist > list_alloc) { - if (list_alloc > 0) { - free(endpoint); - free(indx); - free(peer_list); - } - while (list_alloc < nlist) { - list_alloc += 5; - endpoint_size += 5 * 3 * sizeof(*endpoint); - indx_size += 5 * 3 * sizeof(*indx); - peer_list_size += 5 * sizeof(*peer_list); - } - endpoint = (struct endpoint *)emalloc(endpoint_size); - indx = (int *)emalloc(indx_size); - peer_list = (struct peer **)emalloc(peer_list_size); - } + + /* + * Allocate dynamic space depending on the number of + * associations. + */ + nlist = 1; + for (peer = peer_list; peer != NULL; peer = peer->p_link) + nlist++; + endpoint_size = ALIGNED_SIZE(nlist * 2 * sizeof(*endpoint)); + peers_size = ALIGNED_SIZE(nlist * sizeof(*peers)); + indx_size = ALIGNED_SIZE(nlist * 2 * sizeof(*indx)); + octets = endpoint_size + peers_size + indx_size; + endpoint = erealloc(endpoint, octets); + peers = INC_ALIGNED_PTR(endpoint, endpoint_size); + indx = INC_ALIGNED_PTR(peers, peers_size); /* * Initially, we populate the island with all the rifraff peers @@ -1869,103 +2582,130 @@ clock_select(void) * has dwindled to sys_minclock, the survivors split a million * bucks and collectively crank the chimes. */ - nlist = nl3 = 0; /* none yet */ - for (n = 0; n < NTP_HASH_SIZE; n++) { - for (peer = peer_hash[n]; peer != NULL; peer = - peer->next) { - peer->flags &= ~FLAG_SYSPEER; - peer->status = CTL_PST_SEL_REJECT; - - /* - * Leave the island immediately if the peer is - * unfit to synchronize. - */ - if (peer_unfit(peer)) - continue; - - /* - * Don't allow the local clock or modem drivers - * in the kitchen at this point, unless the - * prefer peer. Do that later, but only if - * nobody else is around. These guys are all - * configured, so we never throw them away. - */ -#ifdef REFCLOCK - if (peer->refclktype == REFCLK_LOCALCLOCK -#if defined(VMS) && defined(VMS_LOCALUNIT) - /* wjm: VMS_LOCALUNIT taken seriously */ - && REFCLOCKUNIT(&peer->srcadr) != - VMS_LOCALUNIT -#endif /* VMS && VMS_LOCALUNIT */ - ) { - typelocal = peer; -#ifndef LOCKCLOCK - if (!(peer->flags & FLAG_PREFER)) - continue; /* no local clock */ -#endif /* LOCKCLOCK */ - } - if (peer->sstclktype == CTL_SST_TS_TELEPHONE) { - typeacts = peer; - if (!(peer->flags & FLAG_PREFER)) - continue; /* no acts */ - } -#endif /* REFCLOCK */ + nlist = nl2 = 0; /* none yet */ + for (peer = peer_list; peer != NULL; peer = peer->p_link) { + peer->new_status = CTL_PST_SEL_REJECT; - /* - * If we get this far, the peer can stay on the - * island, but does not yet have the immunity - * idol. - */ - peer->status = CTL_PST_SEL_SANE; - peer_list[nlist++] = peer; + /* + * Leave the island immediately if the peer is + * unfit to synchronize. + */ + if (peer_unfit(peer)) + continue; - /* - * Insert each interval endpoint on the sorted - * list. - */ - e = peer->offset; /* Upper end */ - f = root_distance(peer); - e = e + f; - for (i = nl3 - 1; i >= 0; i--) { - if (e >= endpoint[indx[i]].val) - break; + /* + * If this peer is an orphan parent, elect the + * one with the lowest metric defined as the + * IPv4 address or the first 64 bits of the + * hashed IPv6 address. To ensure convergence + * on the same selected orphan, consider as + * well that this system may have the lowest + * metric and be the orphan parent. If this + * system wins, sys_peer will be NULL to trigger + * orphan mode in timer(). + */ + if (peer->stratum == sys_orphan) { + u_int32 localmet; + u_int32 peermet; - indx[i + 3] = indx[i]; + if (peer->dstadr != NULL) + localmet = ntohl(peer->dstadr->addr_refid); + else + localmet = U_INT32_MAX; + peermet = ntohl(addr2refid(&peer->srcadr)); + if (peermet < localmet && peermet < orphmet) { + typeorphan = peer; + orphmet = peermet; } - indx[i + 3] = nl3; - endpoint[nl3].type = 1; - endpoint[nl3++].val = e; + continue; + } - e = e - f; /* Center point */ - for (; i >= 0; i--) { - if (e >= endpoint[indx[i]].val) - break; + /* + * If this peer could have the orphan parent + * as a synchronization ancestor, exclude it + * from selection to avoid forming a + * synchronization loop within the orphan mesh, + * triggering stratum climb to infinity + * instability. Peers at stratum higher than + * the orphan stratum could have the orphan + * parent in ancestry so are excluded. + * See http://bugs.ntp.org/2050 + */ + if (peer->stratum > sys_orphan) + continue; +#ifdef REFCLOCK + /* + * The following are special cases. We deal + * with them later. + */ + if (!(peer->flags & FLAG_PREFER)) { + switch (peer->refclktype) { + case REFCLK_LOCALCLOCK: + if ( current_time > orphwait + && typelocal == NULL) + typelocal = peer; + continue; - indx[i + 2] = indx[i]; + case REFCLK_ACTS: + if ( current_time > orphwait + && typeacts == NULL) + typeacts = peer; + continue; } - indx[i + 2] = nl3; - endpoint[nl3].type = 0; - endpoint[nl3++].val = e; + } +#endif /* REFCLOCK */ - e = e - f; /* Lower end */ - for (; i >= 0; i--) { - if (e >= endpoint[indx[i]].val) - break; + /* + * If we get this far, the peer can stay on the + * island, but does not yet have the immunity + * idol. + */ + peer->new_status = CTL_PST_SEL_SANE; + f = root_distance(peer); + peers[nlist].peer = peer; + peers[nlist].error = peer->jitter; + peers[nlist].synch = f; + nlist++; - indx[i + 1] = indx[i]; + /* + * Insert each interval endpoint on the unsorted + * endpoint[] list. + */ + e = peer->offset; + endpoint[nl2].type = -1; /* lower end */ + endpoint[nl2].val = e - f; + nl2++; + endpoint[nl2].type = 1; /* upper end */ + endpoint[nl2].val = e + f; + nl2++; + } + /* + * Construct sorted indx[] of endpoint[] indexes ordered by + * offset. + */ + for (i = 0; i < nl2; i++) + indx[i] = i; + for (i = 0; i < nl2; i++) { + endp = endpoint[indx[i]]; + e = endp.val; + k = i; + for (j = i + 1; j < nl2; j++) { + endp = endpoint[indx[j]]; + if (endp.val < e) { + e = endp.val; + k = j; } - indx[i + 1] = nl3; - endpoint[nl3].type = -1; - endpoint[nl3++].val = e; + } + if (k != i) { + j = indx[k]; + indx[k] = indx[i]; + indx[i] = j; } } -#ifdef DEBUG - if (debug > 2) - for (i = 0; i < nl3; i++) - printf("select: endpoint %2d %.6f\n", - endpoint[indx[i]].type, - endpoint[indx[i]].val); -#endif + for (i = 0; i < nl2; i++) + DPRINTF(3, ("select: endpoint %2d %.6f\n", + endpoint[indx[i]].type, endpoint[indx[i]].val)); + /* * This is the actual algorithm that cleaves the truechimers * from the falsetickers. The original algorithm was described @@ -1985,48 +2725,32 @@ clock_select(void) * * Here, nlist is the number of candidates and allow is the * number of falsetickers. Upon exit, the truechimers are the - * susvivors with offsets not less than low and not greater than + * survivors with offsets not less than low and not greater than * high. There may be none of them. */ low = 1e9; high = -1e9; for (allow = 0; 2 * allow < nlist; allow++) { - int found; /* - * Bound the interval (low, high) as the largest - * interval containing points from presumed truechimers. + * Bound the interval (low, high) as the smallest + * interval containing points from the most sources. */ - found = 0; n = 0; - for (i = 0; i < nl3; i++) { + for (i = 0; i < nl2; i++) { low = endpoint[indx[i]].val; n -= endpoint[indx[i]].type; if (n >= nlist - allow) break; - if (endpoint[indx[i]].type == 0) - found++; } n = 0; - for (j = nl3 - 1; j >= 0; j--) { + for (j = nl2 - 1; j >= 0; j--) { high = endpoint[indx[j]].val; n += endpoint[indx[j]].type; if (n >= nlist - allow) break; - if (endpoint[indx[j]].type == 0) - found++; } - /* - * If the number of candidates found outside the - * interval is greater than the number of falsetickers, - * then at least one truechimer is outside the interval, - * so go around again. This is what makes this algorithm - * different than Marzullo's. - */ - if (found > allow) - continue; - /* * If an interval containing truechimers is found, stop. * If not, increase the number of falsetickers and go @@ -2037,302 +2761,296 @@ clock_select(void) } /* - * Clustering algorithm. Construct candidate list in order first - * by stratum then by root distance, but keep only the best - * NTP_MAXASSOC of them. Scan the list to find falsetickers, who - * leave the island immediately. The TRUE peer is always a + * Clustering algorithm. Whittle candidate list of falsetickers, + * who leave the island immediately. The TRUE peer is always a * truechimer. We must leave at least one peer to collect the - * million bucks. If in orphan mode, rascals found with lower - * stratum are guaranteed a seat on the bus. + * million bucks. + * + * We assert the correct time is contained in the interval, but + * the best offset estimate for the interval might not be + * contained in the interval. For this purpose, a truechimer is + * defined as the midpoint of an interval that overlaps the + * intersection interval. */ j = 0; for (i = 0; i < nlist; i++) { - peer = peer_list[i]; - if (nlist > 1 && (peer->offset <= low || peer->offset >= - high) && !(peer->flags & FLAG_TRUE) && - !(sys_stratum >= sys_orphan && peer->stratum < - sys_orphan)) + double h; + + peer = peers[i].peer; + h = peers[i].synch; + if (( high <= low + || peer->offset + h < low + || peer->offset - h > high + ) && !(peer->flags & FLAG_TRUE)) continue; - peer->status = CTL_PST_SEL_DISTSYSPEER; - +#ifdef REFCLOCK /* - * The order metric is formed from the stratum times - * max distance (1.) plus the root distance. It strongly - * favors the lowest stratum, but a higher stratum peer - * can capture the clock if the low stratum dominant - * hasn't been heard for awhile. + * Eligible PPS peers must survive the intersection + * algorithm. Use the first one found, but don't + * include any of them in the cluster population. */ - d = root_distance(peer) + peer->stratum * sys_maxdist; - if (j >= NTP_MAXASSOC) { - if (d >= synch[j - 1]) + if (peer->flags & FLAG_PPS) { + if (typepps == NULL) + typepps = peer; + if (!(peer->flags & FLAG_TSTAMP_PPS)) continue; - else - j--; } - for (k = j; k > 0; k--) { - if (d >= synch[k - 1]) - break; +#endif /* REFCLOCK */ - peer_list[k] = peer_list[k - 1]; - error[k] = error[k - 1]; - synch[k] = synch[k - 1]; - } - peer_list[k] = peer; - error[k] = peer->jitter; - synch[k] = d; + if (j != i) + peers[j] = peers[i]; j++; } nlist = j; /* - * If no survivors remain at this point, check if the local - * clock or modem drivers have been found. If so, nominate one - * of them as the only survivor. Otherwise, give up and leave - * the island to the rats. + * If no survivors remain at this point, check if the modem + * driver, local driver or orphan parent in that order. If so, + * nominate the first one found as the only survivor. + * Otherwise, give up and leave the island to the rats. */ if (nlist == 0) { - if (typeacts != 0) { - typeacts->status = CTL_PST_SEL_DISTSYSPEER; - peer_list[0] = typeacts; + peers[0].error = 0; + peers[0].synch = sys_mindisp; +#ifdef REFCLOCK + if (typeacts != NULL) { + peers[0].peer = typeacts; nlist = 1; - } else if (typelocal != 0) { - typelocal->status = CTL_PST_SEL_DISTSYSPEER; - peer_list[0] = typelocal; + } else if (typelocal != NULL) { + peers[0].peer = typelocal; + nlist = 1; + } else +#endif /* REFCLOCK */ + if (typeorphan != NULL) { + peers[0].peer = typeorphan; nlist = 1; - } else { - if (osys_peer != NULL) { - NLOG(NLOG_SYNCSTATUS) - msyslog(LOG_INFO, - "no servers reachable"); - report_event(EVNT_PEERSTCHG, NULL); - } } } /* - * We can only trust the survivors if the number of candidates - * sys_minsane is at least the number required to detect and - * cast out one falsticker. For the Byzantine agreement - * algorithm used here, that number is 4; however, the default - * sys_minsane is 1 to speed initial synchronization. Careful - * operators will tinker a higher value and use at least that - * number of synchronization sources. + * Mark the candidates at this point as truechimers. */ - if (nlist < sys_minsane) - return; - - for (i = 0; i < nlist; i++) - peer_list[i]->status = CTL_PST_SEL_SELCAND; + for (i = 0; i < nlist; i++) { + peers[i].peer->new_status = CTL_PST_SEL_SELCAND; + DPRINTF(2, ("select: survivor %s %f\n", + stoa(&peers[i].peer->srcadr), peers[i].synch)); + } /* - * Now, vote outlyers off the island by select jitter weighted + * Now, vote outliers off the island by select jitter weighted * by root distance. Continue voting as long as there are more - * than sys_minclock survivors and the minimum select jitter is - * greater than the maximum peer jitter. Stop if we are about to - * discard a TRUE or PREFER peer, who of course has the - * immunity idol. + * than sys_minclock survivors and the select jitter of the peer + * with the worst metric is greater than the minimum peer + * jitter. Stop if we are about to discard a TRUE or PREFER + * peer, who of course have the immunity idol. */ while (1) { d = 1e9; e = -1e9; - f = g = 0; + g = 0; k = 0; for (i = 0; i < nlist; i++) { - if (error[i] < d) - d = error[i]; - f = 0; + if (peers[i].error < d) + d = peers[i].error; + peers[i].seljit = 0; if (nlist > 1) { + f = 0; for (j = 0; j < nlist; j++) - f += DIFF(peer_list[j]->offset, - peer_list[i]->offset); - f = SQRT(f / (nlist - 1)); + f += DIFF(peers[j].peer->offset, + peers[i].peer->offset); + peers[i].seljit = SQRT(f / (nlist - 1)); } - if (f * synch[i] > e) { - g = f; - e = f * synch[i]; + if (peers[i].seljit * peers[i].synch > e) { + g = peers[i].seljit; + e = peers[i].seljit * peers[i].synch; k = i; } } - f = max(f, LOGTOD(sys_precision)); - if (nlist <= sys_minclock || f <= d || - peer_list[k]->flags & (FLAG_TRUE | FLAG_PREFER)) + g = max(g, LOGTOD(sys_precision)); + if ( nlist <= max(1, sys_minclock) + || g <= d + || ((FLAG_TRUE | FLAG_PREFER) & peers[k].peer->flags)) break; -#ifdef DEBUG - if (debug > 2) - printf( - "select: drop %s select %.6f jitter %.6f\n", - ntoa(&peer_list[k]->srcadr), g, d); -#endif - for (j = k + 1; j < nlist; j++) { - peer_list[j - 1] = peer_list[j]; - error[j - 1] = error[j]; - } + + DPRINTF(3, ("select: drop %s seljit %.6f jit %.6f\n", + ntoa(&peers[k].peer->srcadr), g, d)); + if (nlist > sys_maxclock) + peers[k].peer->new_status = CTL_PST_SEL_EXCESS; + for (j = k + 1; j < nlist; j++) + peers[j - 1] = peers[j]; nlist--; } /* * What remains is a list usually not greater than sys_minclock - * peers. We want only a peer at the lowest stratum to become - * the system peer, although all survivors are eligible for the - * combining algorithm. Consider each peer in turn and OR the - * leap bits on the assumption that, if some of them honk - * nonzero bits, they must know what they are doing. Check for - * prefer and pps peers at any stratum. Note that the head of - * the list is at the lowest stratum and that unsynchronized - * peers cannot survive this far. - */ - leap_next = 0; + * peers. Note that unsynchronized peers cannot survive this + * far. Count and mark these survivors. + * + * While at it, count the number of leap warning bits found. + * This will be used later to vote the system leap warning bit. + * If a leap warning bit is found on a reference clock, the vote + * is always won. + * + * Choose the system peer using a hybrid metric composed of the + * selection jitter scaled by the root distance augmented by + * stratum scaled by sys_mindisp (.001 by default). The goal of + * the small stratum factor is to avoid clockhop between a + * reference clock and a network peer which has a refclock and + * is using an older ntpd, which does not floor sys_rootdisp at + * sys_mindisp. + * + * In contrast, ntpd 4.2.6 and earlier used stratum primarily + * in selecting the system peer, using a weight of 1 second of + * additional root distance per stratum. This heavy bias is no + * longer appropriate, as the scaled root distance provides a + * more rational metric carrying the cumulative error budget. + */ + e = 1e9; + speer = 0; + leap_vote_ins = 0; + leap_vote_del = 0; for (i = 0; i < nlist; i++) { - peer = peer_list[i]; + peer = peers[i].peer; + peer->unreach = 0; + peer->new_status = CTL_PST_SEL_SYNCCAND; sys_survivors++; - leap_next |= peer->leap; - peer->status = CTL_PST_SEL_SYNCCAND; + if (peer->leap == LEAP_ADDSECOND) { + if (peer->flags & FLAG_REFCLOCK) + leap_vote_ins = nlist; + else if (leap_vote_ins < nlist) + leap_vote_ins++; + } + if (peer->leap == LEAP_DELSECOND) { + if (peer->flags & FLAG_REFCLOCK) + leap_vote_del = nlist; + else if (leap_vote_del < nlist) + leap_vote_del++; + } if (peer->flags & FLAG_PREFER) sys_prefer = peer; - if (peer == osys_peer) - typesystem = peer; -#ifdef REFCLOCK - if (peer->refclktype == REFCLK_ATOM_PPS) - sys_pps = peer; -#endif /* REFCLOCK */ -#if DEBUG - if (debug > 1) - printf("cluster: survivor %s metric %.6f\n", - ntoa(&peer_list[i]->srcadr), synch[i]); -#endif + speermet = peers[i].seljit * peers[i].synch + + peer->stratum * sys_mindisp; + if (speermet < e) { + e = speermet; + speer = i; + } } /* - * Anticlockhop provision. Keep the current system peer if it is - * a survivor but not first in the list. But do that only HOPPER - * times. + * Unless there are at least sys_misane survivors, leave the + * building dark. Otherwise, do a clockhop dance. Ordinarily, + * use the selected survivor speer. However, if the current + * system peer is not speer, stay with the current system peer + * as long as it doesn't get too old or too ugly. */ - if (osys_peer == NULL || typesystem == NULL || typesystem == - peer_list[0] || sys_hopper > sys_maxhop) { - typesystem = peer_list[0]; - sys_hopper = 0; - } else { - peer->selbroken++; + if (nlist > 0 && nlist >= sys_minsane) { + double x; + + typesystem = peers[speer].peer; + if (osys_peer == NULL || osys_peer == typesystem) { + sys_clockhop = 0; + } else if ((x = fabs(typesystem->offset - + osys_peer->offset)) < sys_mindisp) { + if (sys_clockhop == 0) + sys_clockhop = sys_mindisp; + else + sys_clockhop *= .5; + DPRINTF(1, ("select: clockhop %d %.6f %.6f\n", + j, x, sys_clockhop)); + if (fabs(x) < sys_clockhop) + typesystem = osys_peer; + else + sys_clockhop = 0; + } else { + sys_clockhop = 0; + } } /* - * Mitigation rules of the game. There are several types of - * peers that can be selected here: (1) orphan, (2) prefer peer - * (flag FLAG_PREFER) (3) pps peers (type REFCLK_ATOM_PPS), (4) - * the existing system peer, if any, and (5) the head of the - * survivor list. + * Mitigation rules of the game. We have the pick of the + * litter in typesystem if any survivors are left. If + * there is a prefer peer, use its offset and jitter. + * Otherwise, use the combined offset and jitter of all kitters. */ - if (typesystem->stratum >= sys_orphan) { - - /* - * If in orphan mode, choose the system peer. If the - * lowest distance, we are the orphan parent and the - * offset is zero. - */ - sys_peer = typesystem; - sys_peer->status = CTL_PST_SEL_SYSPEER; - if (sys_orphandelay < sys_peer->rootdelay) { - sys_offset = 0; - sys_refid = htonl(LOOPBACKADR); + if (typesystem != NULL) { + if (sys_prefer == NULL) { + typesystem->new_status = CTL_PST_SEL_SYSPEER; + clock_combine(peers, sys_survivors, speer); } else { - sys_offset = sys_peer->offset; - sys_refid = addr2refid(&sys_peer->srcadr); + typesystem = sys_prefer; + sys_clockhop = 0; + typesystem->new_status = CTL_PST_SEL_SYSPEER; + sys_offset = typesystem->offset; + sys_jitter = typesystem->jitter; } - sys_jitter = LOGTOD(sys_precision); -#ifdef DEBUG - if (debug > 1) - printf("select: orphan offset %.6f\n", - sys_offset); -#endif - } else if (sys_prefer) { + DPRINTF(1, ("select: combine offset %.9f jitter %.9f\n", + sys_offset, sys_jitter)); + } +#ifdef REFCLOCK + /* + * If a PPS driver is lit and the combined offset is less than + * 0.4 s, select the driver as the PPS peer and use its offset + * and jitter. However, if this is the atom driver, use it only + * if there is a prefer peer or there are no survivors and none + * are required. + */ + if ( typepps != NULL + && fabs(sys_offset) < 0.4 + && ( typepps->refclktype != REFCLK_ATOM_PPS + || ( typepps->refclktype == REFCLK_ATOM_PPS + && ( sys_prefer != NULL + || (typesystem == NULL && sys_minsane == 0))))) { + typesystem = typepps; + sys_clockhop = 0; + typesystem->new_status = CTL_PST_SEL_PPS; + sys_offset = typesystem->offset; + sys_jitter = typesystem->jitter; + DPRINTF(1, ("select: pps offset %.9f jitter %.9f\n", + sys_offset, sys_jitter)); + } +#endif /* REFCLOCK */ - /* - * If a pps peer is present, choose it; otherwise, - * choose the prefer peer. - */ - if (sys_pps) { - sys_peer = sys_pps; - sys_peer->status = CTL_PST_SEL_PPS; - sys_offset = sys_peer->offset; - if (!pps_control) - NLOG(NLOG_SYSEVENT) - msyslog(LOG_INFO, - "pps sync enabled"); - pps_control = current_time; -#ifdef DEBUG - if (debug > 1) - printf("select: pps offset %.6f\n", - sys_offset); -#endif - } else { - sys_peer = sys_prefer; - sys_peer->status = CTL_PST_SEL_SYSPEER; - sys_offset = sys_peer->offset; -#ifdef DEBUG - if (debug > 1) - printf("select: prefer offset %.6f\n", - sys_offset); -#endif + /* + * If there are no survivors at this point, there is no + * system peer. If so and this is an old update, keep the + * current statistics, but do not update the clock. + */ + if (typesystem == NULL) { + if (osys_peer != NULL) { + if (sys_orphwait > 0) + orphwait = current_time + sys_orphwait; + report_event(EVNT_NOPEER, NULL, NULL); } - if (sys_peer->stratum == STRATUM_REFCLOCK || - sys_peer->stratum == STRATUM_UNSPEC) - sys_refid = sys_peer->refid; - else - sys_refid = addr2refid(&sys_peer->srcadr); - sys_jitter = sys_peer->jitter; - } else { - - /* - * Otherwise, choose the anticlockhopper. - */ - sys_peer = typesystem; - sys_peer->status = CTL_PST_SEL_SYSPEER; - clock_combine(peer_list, nlist); - if (sys_peer->stratum == STRATUM_REFCLOCK || - sys_peer->stratum == STRATUM_UNSPEC) - sys_refid = sys_peer->refid; - else - sys_refid = addr2refid(&sys_peer->srcadr); - sys_jitter = SQRT(SQUARE(sys_peer->jitter) + - SQUARE(sys_jitter)); -#ifdef DEBUG - if (debug > 1) - printf("select: combine offset %.6f\n", - sys_offset); -#endif + sys_peer = NULL; + for (peer = peer_list; peer != NULL; peer = peer->p_link) + peer->status = peer->new_status; + return; } /* - * We have found the alpha male. + * Do not use old data, as this may mess up the clock discipline + * stability. */ - sys_peer->flags |= FLAG_SYSPEER; - if (osys_peer != sys_peer) { - char *src; - - report_event(EVNT_PEERSTCHG, NULL); + if (typesystem->epoch <= sys_epoch) + return; -#ifdef REFCLOCK - if (sys_peer->flags & FLAG_REFCLOCK) - src = refnumtoa(&sys_peer->srcadr); - else -#endif /* REFCLOCK */ - src = ntoa(&sys_peer->srcadr); - NLOG(NLOG_SYNCSTATUS) - msyslog(LOG_INFO, "synchronized to %s, stratum %d", - src, sys_peer->stratum); - } - clock_update(); + /* + * We have found the alpha male. Wind the clock. + */ + if (osys_peer != typesystem) + report_event(PEVNT_NEWPEER, typesystem, NULL); + for (peer = peer_list; peer != NULL; peer = peer->p_link) + peer->status = peer->new_status; + clock_update(typesystem); } -/* - * clock_combine - compute system offset and jitter from selected peers - */ static void clock_combine( - struct peer **peers, /* survivor list */ - int npeers /* number of survivors */ + peer_select * peers, /* survivor list */ + int npeers, /* number of survivors */ + int syspeer /* index of sys.peer */ ) { int i; @@ -2340,41 +3058,64 @@ clock_combine( y = z = w = 0; for (i = 0; i < npeers; i++) { - x = root_distance(peers[i]); - y += 1. / x; - z += peers[i]->offset / x; - w += SQUARE(peers[i]->offset - peers[0]->offset) / x; + x = 1. / peers[i].synch; + y += x; + z += x * peers[i].peer->offset; + w += x * DIFF(peers[i].peer->offset, + peers[syspeer].peer->offset); } sys_offset = z / y; - sys_jitter = SQRT(w / y); + sys_jitter = SQRT(w / y + SQUARE(peers[syspeer].seljit)); } + /* * root_distance - compute synchronization distance from peer to root */ static double root_distance( - struct peer *peer + struct peer *peer /* peer structure pointer */ ) { - double dist; + double dtemp; + /* + * Root Distance (LAMBDA) is defined as: + * (delta + DELTA)/2 + epsilon + EPSILON + phi + * + * where: + * delta is the round-trip delay + * DELTA is the root delay + * epsilon is the remote server precision + local precision + * + (15 usec each second) + * EPSILON is the root dispersion + * phi is the peer jitter statistic + * + * NB: Think hard about why we are using these values, and what + * the alternatives are, and the various pros/cons. + * + * DLM thinks these are probably the best choices from any of the + * other worse choices. + */ + dtemp = (peer->delay + peer->rootdelay) / 2 + + LOGTOD(peer->precision) + + LOGTOD(sys_precision) + + clock_phi * (current_time - peer->update) + + peer->rootdisp + + peer->jitter; /* * Careful squeak here. The value returned must be greater than * the minimum root dispersion in order to avoid clockhop with - * highly precise reference clocks. In orphan mode lose the peer - * root delay, as that is used by the election algorithm. + * highly precise reference clocks. Note that the root distance + * cannot exceed the sys_maxdist, as this is the cutoff by the + * selection algorithm. */ - if (peer->stratum >= sys_orphan) - dist = 0; - else - dist = peer->rootdelay; - dist += max(sys_mindisp, dist + peer->delay) / 2 + - peer->rootdispersion + peer->disp + clock_phi * - (current_time - peer->update) + peer->jitter; - return (dist); + if (dtemp < sys_mindisp) + dtemp = sys_mindisp; + return (dtemp); } + /* * peer_xmit - send packet for persistent association. */ @@ -2384,66 +3125,24 @@ peer_xmit( ) { struct pkt xpkt; /* transmit packet */ - int sendlen, authlen; + size_t sendlen, authlen; keyid_t xkeyid = 0; /* transmit key ID */ - l_fp xmt_tx; + l_fp xmt_tx, xmt_ty; - if (!peer->dstadr) /* don't bother with peers without interface */ + if (!peer->dstadr) /* drop peers without interface */ return; - /* - * This is deliciously complicated. There are three cases. - * - * case leap stratum refid delay dispersion - * - * normal system system system system system - * orphan child 00 orphan system orphan system - * orphan parent 00 orphan loopbk 0 0 - */ - /* - * This is a normal packet. Use the system variables. - */ - if (sys_stratum < sys_orphan) { - xpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, - peer->version, peer->hmode); - xpkt.stratum = STRATUM_TO_PKT(sys_stratum); - xpkt.refid = sys_refid; - xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); - - /* - * This is a orphan child packet. The host is synchronized to an - * orphan parent. Show leap synchronized, orphan stratum, system - * reference ID, orphan root delay and system root dispersion. - */ - } else if (sys_peer != NULL) { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - peer->version, peer->hmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = htonl(LOOPBACKADR); - xpkt.rootdelay = HTONS_FP(DTOFP(sys_orphandelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); - - /* - * This is an orphan parent. Show leap synchronized, orphan - * stratum, loopack reference ID and zero root delay and root - * dispersion. - */ - } else { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - peer->version, peer->hmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = sys_refid; - xpkt.rootdelay = 0; - xpkt.rootdispersion = 0; - } + xpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, peer->version, + peer->hmode); + xpkt.stratum = STRATUM_TO_PKT(sys_stratum); xpkt.ppoll = peer->hpoll; xpkt.precision = sys_precision; + xpkt.refid = sys_refid; + xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); + xpkt.rootdisp = HTONS_FP(DTOUFP(sys_rootdisp)); HTONL_FP(&sys_reftime, &xpkt.reftime); - HTONL_FP(&peer->org, &xpkt.org); - HTONL_FP(&peer->rec, &xpkt.rec); + HTONL_FP(&peer->rec, &xpkt.org); + HTONL_FP(&peer->dst, &xpkt.rec); /* * If the received packet contains a MAC, the transmitted packet @@ -2458,28 +3157,73 @@ peer_xmit( * might not be usable. */ sendlen = LEN_PKT_NOMAC; - if (!(peer->flags & FLAG_AUTHENABLE)) { - get_systime(&peer->xmt); - HTONL_FP(&peer->xmt, &xpkt.xmt); +#ifdef AUTOKEY + if (!(peer->flags & FLAG_SKEY) && peer->keyid == 0) { +#else /* !AUTOKEY follows */ + if (peer->keyid == 0) { +#endif /* !AUTOKEY */ + + /* + * Transmit a-priori timestamps + */ + get_systime(&xmt_tx); + if (peer->flip == 0) { /* basic mode */ + peer->aorg = xmt_tx; + HTONL_FP(&xmt_tx, &xpkt.xmt); + } else { /* interleaved modes */ + if (peer->hmode == MODE_BROADCAST) { /* bcst */ + HTONL_FP(&xmt_tx, &xpkt.xmt); + if (peer->flip > 0) + HTONL_FP(&peer->borg, + &xpkt.org); + else + HTONL_FP(&peer->aorg, + &xpkt.org); + } else { /* symmetric */ + if (peer->flip > 0) + HTONL_FP(&peer->borg, + &xpkt.xmt); + else + HTONL_FP(&peer->aorg, + &xpkt.xmt); + } + } + peer->t21_bytes = sendlen; sendpkt(&peer->srcadr, peer->dstadr, sys_ttl[peer->ttl], - &xpkt, sendlen); + &xpkt, sendlen); peer->sent++; + peer->throttle += (1 << peer->minpoll) - 2; + + /* + * Capture a-posteriori timestamps + */ + get_systime(&xmt_ty); + if (peer->flip != 0) { /* interleaved modes */ + if (peer->flip > 0) + peer->aorg = xmt_ty; + else + peer->borg = xmt_ty; + peer->flip = -peer->flip; + } + L_SUB(&xmt_ty, &xmt_tx); + LFPTOD(&xmt_ty, peer->xleave); #ifdef DEBUG if (debug) - printf("transmit: at %ld %s->%s mode %d\n", - current_time, peer->dstadr ? stoa(&peer->dstadr->sin) : "-", - stoa(&peer->srcadr), peer->hmode); + printf("transmit: at %ld %s->%s mode %d len %zu\n", + current_time, peer->dstadr ? + stoa(&peer->dstadr->sin) : "-", + stoa(&peer->srcadr), peer->hmode, sendlen); #endif return; } /* - * The received packet contains a MAC, so the transmitted packet - * must be authenticated. If autokey is enabled, fuss with the - * various modes; otherwise, symmetric key cryptography is used. + * Authentication is enabled, so the transmitted packet must be + * authenticated. If autokey is enabled, fuss with the various + * modes; otherwise, symmetric key cryptography is used. */ -#ifdef OPENSSL - if (crypto_flags && (peer->flags & FLAG_SKEY)) { +#ifdef AUTOKEY + if (peer->flags & FLAG_SKEY) { struct exten *exten; /* extension field */ /* @@ -2495,7 +3239,7 @@ peer_xmit( * messages have the same code as the request, but have * a response bit and possibly an error bit set. In this * implementation, a message may contain no more than - * one command and no more than one response. + * one command and one or more responses. * * Cryptographic session keys include both a public and * a private componet. Request and response messages @@ -2505,7 +3249,7 @@ peer_xmit( * the session key is generated. */ while (1) { - + /* * Allocate and initialize a keylist if not * already done. Then, use the list in inverse @@ -2521,10 +3265,10 @@ peer_xmit( * identifier to verify authenticity. * * If for some reason a key is no longer in the - * key cache, a birthday has happened and the - * pseudo-random sequence is probably broken. In - * that case, purge the keylist and regenerate - * it. + * key cache, a birthday has happened or the key + * has expired, so the pseudo-random sequence is + * broken. In that case, purge the keylist and + * regenerate it. */ if (peer->keynumber == 0) make_keylist(peer, peer->dstadr); @@ -2540,272 +3284,271 @@ peer_xmit( exten = NULL; switch (peer->hmode) { - /* - * In broadcast server mode the autokey values are - * required by the broadcast clients. Push them when a - * new keylist is generated; otherwise, push the - * association message so the client can request them at - * other times. - */ + /* + * In broadcast server mode the autokey values are + * required by the broadcast clients. Push them when a + * new keylist is generated; otherwise, push the + * association message so the client can request them at + * other times. + */ case MODE_BROADCAST: if (peer->flags & FLAG_ASSOC) exten = crypto_args(peer, CRYPTO_AUTO | - CRYPTO_RESP, NULL); + CRYPTO_RESP, peer->associd, NULL); else exten = crypto_args(peer, CRYPTO_ASSOC | - CRYPTO_RESP, NULL); + CRYPTO_RESP, peer->associd, NULL); break; /* - * In symmetric modes the digest, certificate, agreement - * parameters, cookie and autokey values are required. - * The leapsecond table is optional. But, a passive peer - * will not believe the active peer until the latter has - * synchronized, so the agreement must be postponed - * until then. In any case, if a new keylist is - * generated, the autokey values are pushed. - * - * If the crypto bit is lit, don't send requests. + * In symmetric modes the parameter, certificate, + * identity, cookie and autokey exchanges are + * required. The leapsecond exchange is optional. But, a + * peer will not believe the other peer until the other + * peer has synchronized, so the certificate exchange + * might loop until then. If a peer finds a broken + * autokey sequence, it uses the autokey exchange to + * retrieve the autokey values. In any case, if a new + * keylist is generated, the autokey values are pushed. */ case MODE_ACTIVE: case MODE_PASSIVE: - if (peer->flash & TEST9) - break; + /* - * Parameter and certificate. + * Parameter, certificate and identity. */ if (!peer->crypto) exten = crypto_args(peer, CRYPTO_ASSOC, - sys_hostname); - else if (!(peer->crypto & CRYPTO_FLAG_VALID)) + peer->associd, hostval.ptr); + else if (!(peer->crypto & CRYPTO_FLAG_CERT)) exten = crypto_args(peer, CRYPTO_CERT, - peer->issuer); - - /* - * Identity. Note we have to sign the - * certificate before the cookie to avoid a - * deadlock when the passive peer is walking the - * certificate trail. Awesome. - */ + peer->associd, peer->issuer); else if (!(peer->crypto & CRYPTO_FLAG_VRFY)) exten = crypto_args(peer, - crypto_ident(peer), NULL); - else if (sys_leap != LEAP_NOTINSYNC && - !(peer->crypto & CRYPTO_FLAG_SIGN)) - exten = crypto_args(peer, CRYPTO_SIGN, - sys_hostname); + crypto_ident(peer), peer->associd, + NULL); /* - * Autokey. We request the cookie only when the - * server and client are synchronized and - * signatures work both ways. On the other hand, - * the active peer needs the autokey values - * before then and when the passive peer is - * waiting for the active peer to synchronize. - * Any time we regenerate the key list, we offer - * the autokey values without being asked. + * Cookie and autokey. We request the cookie + * only when the this peer and the other peer + * are synchronized. But, this peer needs the + * autokey values when the cookie is zero. Any + * time we regenerate the key list, we offer the + * autokey values without being asked. If for + * some reason either peer finds a broken + * autokey sequence, the autokey exchange is + * used to retrieve the autokey values. */ - else if (sys_leap != LEAP_NOTINSYNC && - peer->leap != LEAP_NOTINSYNC && - !(peer->crypto & CRYPTO_FLAG_AGREE)) + else if ( sys_leap != LEAP_NOTINSYNC + && peer->leap != LEAP_NOTINSYNC + && !(peer->crypto & CRYPTO_FLAG_COOK)) exten = crypto_args(peer, CRYPTO_COOK, - NULL); - else if (peer->flags & FLAG_ASSOC) - exten = crypto_args(peer, CRYPTO_AUTO | - CRYPTO_RESP, NULL); + peer->associd, NULL); else if (!(peer->crypto & CRYPTO_FLAG_AUTO)) exten = crypto_args(peer, CRYPTO_AUTO, - NULL); + peer->associd, NULL); + else if ( peer->flags & FLAG_ASSOC + && peer->crypto & CRYPTO_FLAG_SIGN) + exten = crypto_args(peer, CRYPTO_AUTO | + CRYPTO_RESP, peer->assoc, NULL); /* - * Postamble. We trade leapseconds only when the - * server and client are synchronized. + * Wait for clock sync, then sign the + * certificate and retrieve the leapsecond + * values. */ - else if (sys_leap != LEAP_NOTINSYNC && - peer->leap != LEAP_NOTINSYNC && - peer->crypto & CRYPTO_FLAG_TAI && - !(peer->crypto & CRYPTO_FLAG_LEAP)) - exten = crypto_args(peer, CRYPTO_TAI, - NULL); + else if (sys_leap == LEAP_NOTINSYNC) + break; + + else if (!(peer->crypto & CRYPTO_FLAG_SIGN)) + exten = crypto_args(peer, CRYPTO_SIGN, + peer->associd, hostval.ptr); + else if (!(peer->crypto & CRYPTO_FLAG_LEAP)) + exten = crypto_args(peer, CRYPTO_LEAP, + peer->associd, NULL); break; /* - * In client mode the digest, certificate, agreement - * parameters and cookie are required. The leapsecond - * table is optional. If broadcast client mode, the - * autokey values are required as well. In broadcast - * client mode, these values must be acquired during the - * client/server exchange to avoid having to wait until - * the next key list regeneration. Otherwise, the poor - * dude may die a lingering death until becoming - * unreachable and attempting rebirth. - * - * If neither the server or client have the agreement - * parameters, the protocol transmits the cookie in the - * clear. If the server has the parameters, the client - * requests them and the protocol blinds it using the - * agreed key. It is a protocol error if the client has - * the parameters but the server does not. - * - * If the crypto bit is lit, don't send requests. + * In client mode the parameter, certificate, identity, + * cookie and sign exchanges are required. The + * leapsecond exchange is optional. If broadcast client + * mode the same exchanges are required, except that the + * autokey exchange is substitutes for the cookie + * exchange, since the cookie is always zero. If the + * broadcast client finds a broken autokey sequence, it + * uses the autokey exchange to retrieve the autokey + * values. */ case MODE_CLIENT: - if (peer->flash & TEST9) - break; + /* - * Parameter and certificate. + * Parameter, certificate and identity. */ if (!peer->crypto) exten = crypto_args(peer, CRYPTO_ASSOC, - sys_hostname); - else if (!(peer->crypto & CRYPTO_FLAG_VALID)) + peer->associd, hostval.ptr); + else if (!(peer->crypto & CRYPTO_FLAG_CERT)) exten = crypto_args(peer, CRYPTO_CERT, - peer->issuer); - - /* - * Identity - */ + peer->associd, peer->issuer); else if (!(peer->crypto & CRYPTO_FLAG_VRFY)) exten = crypto_args(peer, - crypto_ident(peer), NULL); + crypto_ident(peer), peer->associd, + NULL); /* - * Autokey + * Cookie and autokey. These are requests, but + * we use the peer association ID with autokey + * rather than our own. */ - else if (!(peer->crypto & CRYPTO_FLAG_AGREE)) + else if (!(peer->crypto & CRYPTO_FLAG_COOK)) exten = crypto_args(peer, CRYPTO_COOK, - NULL); - else if (!(peer->crypto & CRYPTO_FLAG_AUTO) && - (peer->cast_flags & MDF_BCLNT)) + peer->associd, NULL); + else if (!(peer->crypto & CRYPTO_FLAG_AUTO)) exten = crypto_args(peer, CRYPTO_AUTO, - NULL); + peer->assoc, NULL); /* - * Postamble. We can sign the certificate here, - * since there is no chance of deadlock. + * Wait for clock sync, then sign the + * certificate and retrieve the leapsecond + * values. */ - else if (sys_leap != LEAP_NOTINSYNC && - !(peer->crypto & CRYPTO_FLAG_SIGN)) + else if (sys_leap == LEAP_NOTINSYNC) + break; + + else if (!(peer->crypto & CRYPTO_FLAG_SIGN)) exten = crypto_args(peer, CRYPTO_SIGN, - sys_hostname); - else if (sys_leap != LEAP_NOTINSYNC && - peer->crypto & CRYPTO_FLAG_TAI && - !(peer->crypto & CRYPTO_FLAG_LEAP)) - exten = crypto_args(peer, CRYPTO_TAI, - NULL); + peer->associd, hostval.ptr); + else if (!(peer->crypto & CRYPTO_FLAG_LEAP)) + exten = crypto_args(peer, CRYPTO_LEAP, + peer->associd, NULL); break; } /* - * Build the extension fields as directed. A response to - * a request is always sent, even if an error. If an - * error occurs when sending a request, the crypto - * machinery broke or was misconfigured. In that case - * light the crypto bit to suppress further requests. + * Add a queued extension field if present. This is + * always a request message, so the reply ID is already + * in the message. If an error occurs, the error bit is + * lit in the response. */ if (peer->cmmd != NULL) { - peer->cmmd->associd = htonl(peer->associd); - sendlen += crypto_xmit(&xpkt, &peer->srcadr, - sendlen, peer->cmmd, 0); + u_int32 temp32; + + temp32 = CRYPTO_RESP; + peer->cmmd->opcode |= htonl(temp32); + sendlen += crypto_xmit(peer, &xpkt, NULL, + sendlen, peer->cmmd, 0); free(peer->cmmd); peer->cmmd = NULL; } + + /* + * Add an extension field created above. All but the + * autokey response message are request messages. + */ if (exten != NULL) { - int ltemp = 0; - - if (exten->opcode != 0) { - ltemp = crypto_xmit(&xpkt, - &peer->srcadr, sendlen, exten, 0); - if (ltemp == 0) { - peer->flash |= TEST9; /* crypto error */ - free(exten); - return; - } - } - sendlen += ltemp; + if (exten->opcode != 0) + sendlen += crypto_xmit(peer, &xpkt, + NULL, sendlen, exten, 0); free(exten); } /* - * If extension fields are present, we must use a - * private cookie value of zero. Don't send if the - * crypto bit is set and no extension field is present, - * but in that case give back the key. Most intricate. + * Calculate the next session key. Since extension + * fields are present, the cookie value is zero. */ - if (sendlen > LEN_PKT_NOMAC) { + if (sendlen > (int)LEN_PKT_NOMAC) { session_key(&peer->dstadr->sin, &peer->srcadr, xkeyid, 0, 2); - } else if (peer->flash & TEST9) { - authtrust(xkeyid, 0); - return; } - } -#endif /* OPENSSL */ + } +#endif /* AUTOKEY */ /* - * Stash the transmit timestamp corrected for the encryption - * delay. If autokey, give back the key, as we use keys only - * once. Check for errors such as missing keys, buffer overflow, - * etc. + * Transmit a-priori timestamps */ + get_systime(&xmt_tx); + if (peer->flip == 0) { /* basic mode */ + peer->aorg = xmt_tx; + HTONL_FP(&xmt_tx, &xpkt.xmt); + } else { /* interleaved modes */ + if (peer->hmode == MODE_BROADCAST) { /* bcst */ + HTONL_FP(&xmt_tx, &xpkt.xmt); + if (peer->flip > 0) + HTONL_FP(&peer->borg, &xpkt.org); + else + HTONL_FP(&peer->aorg, &xpkt.org); + } else { /* symmetric */ + if (peer->flip > 0) + HTONL_FP(&peer->borg, &xpkt.xmt); + else + HTONL_FP(&peer->aorg, &xpkt.xmt); + } + } xkeyid = peer->keyid; - get_systime(&peer->xmt); - L_ADD(&peer->xmt, &sys_authdelay); - HTONL_FP(&peer->xmt, &xpkt.xmt); authlen = authencrypt(xkeyid, (u_int32 *)&xpkt, sendlen); if (authlen == 0) { - msyslog(LOG_INFO, "transmit: %s key %u not found", - stoa(&peer->srcadr), xkeyid); - peer->flash |= TEST9; /* no key found */ + report_event(PEVNT_AUTH, peer, "no key"); + peer->flash |= TEST5; /* auth error */ + peer->badauth++; return; } sendlen += authlen; -#ifdef OPENSSL +#ifdef AUTOKEY if (xkeyid > NTP_MAXKEY) authtrust(xkeyid, 0); -#endif /* OPENSSL */ - get_systime(&xmt_tx); +#endif /* AUTOKEY */ if (sendlen > sizeof(xpkt)) { - msyslog(LOG_ERR, "buffer overflow %u", sendlen); + msyslog(LOG_ERR, "proto: buffer overflow %zu", sendlen); exit (-1); } + peer->t21_bytes = sendlen; sendpkt(&peer->srcadr, peer->dstadr, sys_ttl[peer->ttl], &xpkt, - sendlen); + sendlen); + peer->sent++; + peer->throttle += (1 << peer->minpoll) - 2; /* - * Calculate the encryption delay. Keep the minimum over - * the latest two samples. + * Capture a-posteriori timestamps */ - L_SUB(&xmt_tx, &peer->xmt); - L_ADD(&xmt_tx, &sys_authdelay); - sys_authdly[1] = sys_authdly[0]; - sys_authdly[0] = xmt_tx.l_uf; - if (sys_authdly[0] < sys_authdly[1]) - sys_authdelay.l_uf = sys_authdly[0]; - else - sys_authdelay.l_uf = sys_authdly[1]; - peer->sent++; -#ifdef OPENSSL + get_systime(&xmt_ty); + if (peer->flip != 0) { /* interleaved modes */ + if (peer->flip > 0) + peer->aorg = xmt_ty; + else + peer->borg = xmt_ty; + peer->flip = -peer->flip; + } + L_SUB(&xmt_ty, &xmt_tx); + LFPTOD(&xmt_ty, peer->xleave); +#ifdef AUTOKEY #ifdef DEBUG if (debug) - printf( - "transmit: at %ld %s->%s mode %d keyid %08x len %d mac %d index %d\n", - current_time, peer->dstadr ? ntoa(&peer->dstadr->sin) : "-", - ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen - - authlen, authlen, peer->keynumber); + printf("transmit: at %ld %s->%s mode %d keyid %08x len %zu index %d\n", + current_time, latoa(peer->dstadr), + ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen, + peer->keynumber); #endif -#else +#else /* !AUTOKEY follows */ #ifdef DEBUG if (debug) - printf( - "transmit: at %ld %s->%s mode %d keyid %08x len %d mac %d\n", - current_time, peer->dstadr ? ntoa(&peer->dstadr->sin) : "-", - ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen - - authlen, authlen); + printf("transmit: at %ld %s->%s mode %d keyid %08x len %d\n", + current_time, peer->dstadr ? + ntoa(&peer->dstadr->sin) : "-", + ntoa(&peer->srcadr), peer->hmode, xkeyid, sendlen); #endif -#endif /* OPENSSL */ +#endif /* !AUTOKEY */ +} + + +#ifdef LEAP_SMEAR + +static void +leap_smear_add_offs(l_fp *t, l_fp *t_recv) { + L_ADD(t, &leap_smear.offset); } +#endif /* LEAP_SMEAR */ + /* * fast_xmit - Send packet for nonpersistent association. Note that @@ -2814,111 +3557,123 @@ peer_xmit( static void fast_xmit( struct recvbuf *rbufp, /* receive packet pointer */ - int xmode, /* transmit mode */ + int xmode, /* receive mode */ keyid_t xkeyid, /* transmit key ID */ - int mask /* restrict mask */ + int flags /* restrict mask */ ) { - struct pkt xpkt; /* transmit packet structure */ - struct pkt *rpkt; /* receive packet structure */ - l_fp xmt_ts; /* timestamp */ - l_fp xmt_tx; /* timestamp after authent */ - int sendlen, authlen; -#ifdef OPENSSL + struct pkt xpkt; /* transmit packet structure */ + struct pkt *rpkt; /* receive packet structure */ + l_fp xmt_tx, xmt_ty; + int sendlen; +#ifdef AUTOKEY u_int32 temp32; #endif /* * Initialize transmit packet header fields from the receive - * buffer provided. We leave some fields intact as received. If - * the gazinta was from a multicast address, the gazoutta must - * go out another way. + * buffer provided. We leave the fields intact as received, but + * set the peer poll at the maximum of the receive peer poll and + * the system minimum poll (ntp_minpoll). This is for KoD rate + * control and not strictly specification compliant, but doesn't + * break anything. * - * The root delay field is special. If the system stratum is - * less than the orphan stratum, send the real root delay. - * Otherwise, if there is no system peer, send the orphan delay. - * Otherwise, we must be an orphan parent, so send zero. + * If the gazinta was from a multicast address, the gazoutta + * must go out another way. */ rpkt = &rbufp->recv_pkt; if (rbufp->dstadr->flags & INT_MCASTOPEN) rbufp->dstadr = findinterface(&rbufp->recv_srcadr); /* - * This is deliciously complicated. There are four cases. - * - * case leap stratum refid delay dispersion - * - * KoD 11 16 KISS system system - * normal system system system system system - * orphan child 00 orphan system orphan system - * orphan parent 00 orphan loopbk 0 0 - */ - /* - * This is a kiss-of-death (KoD) packet. Show leap + * If this is a kiss-o'-death (KoD) packet, show leap * unsynchronized, stratum zero, reference ID the four-character - * kiss code and system root delay. Note the rate limit on these - * packets. Once a second initialize a bucket counter. Every - * packet sent decrements the counter until reaching zero. If - * the counter is zero, drop the kiss. + * kiss code and system root delay. Note we don't reveal the + * local time, so these packets can't be used for + * synchronization. */ - if (mask & RES_LIMITED) { - sys_limitrejected++; - if (sys_kod == 0 || !(mask & RES_DEMOBILIZE)) - return; - - sys_kod--; + if (flags & RES_KOD) { + sys_kodsent++; xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOTINSYNC, PKT_VERSION(rpkt->li_vn_mode), xmode); - xpkt.stratum = STRATUM_UNSPEC; + xpkt.stratum = STRATUM_PKT_UNSPEC; + xpkt.ppoll = max(rpkt->ppoll, ntp_minpoll); + xpkt.precision = rpkt->precision; memcpy(&xpkt.refid, "RATE", 4); - xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); + xpkt.rootdelay = rpkt->rootdelay; + xpkt.rootdisp = rpkt->rootdisp; + xpkt.reftime = rpkt->reftime; + xpkt.org = rpkt->xmt; + xpkt.rec = rpkt->xmt; + xpkt.xmt = rpkt->xmt; /* * This is a normal packet. Use the system variables. */ - } else if (sys_stratum < sys_orphan) { - xpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, + } else { +#ifdef LEAP_SMEAR + /* + * Make copies of the variables which can be affected by smearing. + */ + l_fp this_ref_time; + l_fp this_recv_time; +#endif + + /* + * If we are inside the leap smear interval we add the current smear offset to + * the packet receive time, to the packet transmit time, and eventually to the + * reftime to make sure the reftime isn't later than the transmit/receive times. + */ + xpkt.li_vn_mode = PKT_LI_VN_MODE(xmt_leap, PKT_VERSION(rpkt->li_vn_mode), xmode); + xpkt.stratum = STRATUM_TO_PKT(sys_stratum); + xpkt.ppoll = max(rpkt->ppoll, ntp_minpoll); + xpkt.precision = sys_precision; xpkt.refid = sys_refid; xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); + xpkt.rootdisp = HTONS_FP(DTOUFP(sys_rootdisp)); + +#ifdef LEAP_SMEAR + this_ref_time = sys_reftime; + if (leap_smear.in_progress) { + leap_smear_add_offs(&this_ref_time, NULL); + xpkt.refid = convertLFPToRefID(leap_smear.offset); + DPRINTF(2, ("fast_xmit: leap_smear.in_progress: refid %8x, smear %s\n", + ntohl(xpkt.refid), + lfptoa(&leap_smear.offset, 8) + )); + } + HTONL_FP(&this_ref_time, &xpkt.reftime); +#else + HTONL_FP(&sys_reftime, &xpkt.reftime); +#endif - /* - * This is a orphan child packet. The host is synchronized to an - * orphan parent. Show leap synchronized, orphan stratum, system - * reference ID and orphan root delay. - */ - } else if (sys_peer != NULL) { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - PKT_VERSION(rpkt->li_vn_mode), xmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = sys_refid; - xpkt.rootdelay = HTONS_FP(DTOFP(sys_orphandelay)); - xpkt.rootdispersion = - HTONS_FP(DTOUFP(sys_rootdispersion)); + xpkt.org = rpkt->xmt; - /* - * This is an orphan parent. Show leap synchronized, orphan - * stratum, loopack reference ID and zero root delay. - */ - } else { - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, - PKT_VERSION(rpkt->li_vn_mode), xmode); - xpkt.stratum = STRATUM_TO_PKT(sys_orphan); - xpkt.refid = htonl(LOOPBACKADR); - xpkt.rootdelay = HTONS_FP(DTOFP(0)); - xpkt.rootdispersion = HTONS_FP(DTOFP(0)); +#ifdef LEAP_SMEAR + this_recv_time = rbufp->recv_time; + if (leap_smear.in_progress) + leap_smear_add_offs(&this_recv_time, NULL); + HTONL_FP(&this_recv_time, &xpkt.rec); +#else + HTONL_FP(&rbufp->recv_time, &xpkt.rec); +#endif + + get_systime(&xmt_tx); +#ifdef LEAP_SMEAR + if (leap_smear.in_progress) + leap_smear_add_offs(&xmt_tx, &this_recv_time); +#endif + HTONL_FP(&xmt_tx, &xpkt.xmt); } - xpkt.ppoll = rpkt->ppoll; - xpkt.precision = sys_precision; - xpkt.rootdispersion = HTONS_FP(DTOUFP(sys_rootdispersion)); - HTONL_FP(&sys_reftime, &xpkt.reftime); - xpkt.org = rpkt->xmt; - HTONL_FP(&rbufp->recv_time, &xpkt.rec); + +#ifdef HAVE_NTP_SIGND + if (flags & RES_MSSNTP) { + send_via_ntp_signd(rbufp, xmode, xkeyid, flags, &xpkt); + return; + } +#endif /* HAVE_NTP_SIGND */ /* * If the received packet contains a MAC, the transmitted packet @@ -2927,15 +3682,14 @@ fast_xmit( */ sendlen = LEN_PKT_NOMAC; if (rbufp->recv_length == sendlen) { - get_systime(&xmt_ts); - HTONL_FP(&xmt_ts, &xpkt.xmt); sendpkt(&rbufp->recv_srcadr, rbufp->dstadr, 0, &xpkt, sendlen); #ifdef DEBUG if (debug) - printf("transmit: at %ld %s->%s mode %d\n", + printf( + "transmit: at %ld %s->%s mode %d len %d\n", current_time, stoa(&rbufp->dstadr->sin), - stoa(&rbufp->recv_srcadr), xmode); + stoa(&rbufp->recv_srcadr), xmode, sendlen); #endif return; } @@ -2948,7 +3702,7 @@ fast_xmit( * value to generate the cookie, which is unique for every * source-destination-key ID combination. */ -#ifdef OPENSSL +#ifdef AUTOKEY if (xkeyid > NTP_MAXKEY) { keyid_t cookie; @@ -2963,61 +3717,199 @@ fast_xmit( */ cookie = session_key(&rbufp->recv_srcadr, &rbufp->dstadr->sin, 0, sys_private, 0); - if (rbufp->recv_length >= (int)(sendlen + MAX_MAC_LEN + - 2 * sizeof(u_int32))) { + if (rbufp->recv_length > sendlen + (int)MAX_MAC_LEN) { session_key(&rbufp->dstadr->sin, &rbufp->recv_srcadr, xkeyid, 0, 2); temp32 = CRYPTO_RESP; rpkt->exten[0] |= htonl(temp32); - sendlen += crypto_xmit(&xpkt, - &rbufp->recv_srcadr, sendlen, - (struct exten *)rpkt->exten, cookie); + sendlen += crypto_xmit(NULL, &xpkt, rbufp, + sendlen, (struct exten *)rpkt->exten, + cookie); } else { session_key(&rbufp->dstadr->sin, &rbufp->recv_srcadr, xkeyid, cookie, 2); } } -#endif /* OPENSSL */ - get_systime(&xmt_ts); - L_ADD(&xmt_ts, &sys_authdelay); - HTONL_FP(&xmt_ts, &xpkt.xmt); - authlen = authencrypt(xkeyid, (u_int32 *)&xpkt, sendlen); - sendlen += authlen; -#ifdef OPENSSL +#endif /* AUTOKEY */ + get_systime(&xmt_tx); + sendlen += authencrypt(xkeyid, (u_int32 *)&xpkt, sendlen); +#ifdef AUTOKEY if (xkeyid > NTP_MAXKEY) authtrust(xkeyid, 0); -#endif /* OPENSSL */ - get_systime(&xmt_tx); - if (sendlen > sizeof(xpkt)) { - msyslog(LOG_ERR, "buffer overflow %u", sendlen); - exit (-1); - } +#endif /* AUTOKEY */ sendpkt(&rbufp->recv_srcadr, rbufp->dstadr, 0, &xpkt, sendlen); - - /* - * Calculate the encryption delay. Keep the minimum over the - * latest two samples. - */ - L_SUB(&xmt_tx, &xmt_ts); - L_ADD(&xmt_tx, &sys_authdelay); - sys_authdly[1] = sys_authdly[0]; - sys_authdly[0] = xmt_tx.l_uf; - if (sys_authdly[0] < sys_authdly[1]) - sys_authdelay.l_uf = sys_authdly[0]; - else - sys_authdelay.l_uf = sys_authdly[1]; + get_systime(&xmt_ty); + L_SUB(&xmt_ty, &xmt_tx); + sys_authdelay = xmt_ty; #ifdef DEBUG if (debug) printf( - "transmit: at %ld %s->%s mode %d keyid %08x len %d mac %d\n", + "transmit: at %ld %s->%s mode %d keyid %08x len %d\n", current_time, ntoa(&rbufp->dstadr->sin), - ntoa(&rbufp->recv_srcadr), xmode, xkeyid, sendlen - - authlen, authlen); + ntoa(&rbufp->recv_srcadr), xmode, xkeyid, sendlen); +#endif +} + + +/* + * pool_xmit - resolve hostname or send unicast solicitation for pool. + */ +static void +pool_xmit( + struct peer *pool /* pool solicitor association */ + ) +{ +#ifdef WORKER + struct pkt xpkt; /* transmit packet structure */ + struct addrinfo hints; + int rc; + struct interface * lcladr; + sockaddr_u * rmtadr; + int restrict_mask; + struct peer * p; + l_fp xmt_tx; + + if (NULL == pool->ai) { + if (pool->addrs != NULL) { + /* free() is used with copy_addrinfo_list() */ + free(pool->addrs); + pool->addrs = NULL; + } + ZERO(hints); + hints.ai_family = AF(&pool->srcadr); + hints.ai_socktype = SOCK_DGRAM; + hints.ai_protocol = IPPROTO_UDP; + /* ignore getaddrinfo_sometime() errors, we will retry */ + rc = getaddrinfo_sometime( + pool->hostname, + "ntp", + &hints, + 0, /* no retry */ + &pool_name_resolved, + (void *)(intptr_t)pool->associd); + if (!rc) + DPRINTF(1, ("pool DNS lookup %s started\n", + pool->hostname)); + else + msyslog(LOG_ERR, + "unable to start pool DNS %s: %m", + pool->hostname); + return; + } + + do { + /* copy_addrinfo_list ai_addr points to a sockaddr_u */ + rmtadr = (sockaddr_u *)(void *)pool->ai->ai_addr; + pool->ai = pool->ai->ai_next; + p = findexistingpeer(rmtadr, NULL, NULL, MODE_CLIENT, 0); + } while (p != NULL && pool->ai != NULL); + if (p != NULL) + return; /* out of addresses, re-query DNS next poll */ + restrict_mask = restrictions(rmtadr); + if (RES_FLAGS & restrict_mask) + restrict_source(rmtadr, 0, + current_time + POOL_SOLICIT_WINDOW + 1); + lcladr = findinterface(rmtadr); + memset(&xpkt, 0, sizeof(xpkt)); + xpkt.li_vn_mode = PKT_LI_VN_MODE(sys_leap, pool->version, + MODE_CLIENT); + xpkt.stratum = STRATUM_TO_PKT(sys_stratum); + xpkt.ppoll = pool->hpoll; + xpkt.precision = sys_precision; + xpkt.refid = sys_refid; + xpkt.rootdelay = HTONS_FP(DTOFP(sys_rootdelay)); + xpkt.rootdisp = HTONS_FP(DTOUFP(sys_rootdisp)); + HTONL_FP(&sys_reftime, &xpkt.reftime); + get_systime(&xmt_tx); + pool->aorg = xmt_tx; + HTONL_FP(&xmt_tx, &xpkt.xmt); + sendpkt(rmtadr, lcladr, sys_ttl[pool->ttl], &xpkt, + LEN_PKT_NOMAC); + pool->sent++; + pool->throttle += (1 << pool->minpoll) - 2; +#ifdef DEBUG + if (debug) + printf("transmit: at %ld %s->%s pool\n", + current_time, latoa(lcladr), stoa(rmtadr)); #endif + msyslog(LOG_INFO, "Soliciting pool server %s", stoa(rmtadr)); +#endif /* WORKER */ +} + + +#ifdef AUTOKEY + /* + * group_test - test if this is the same group + * + * host assoc return action + * none none 0 mobilize * + * none group 0 mobilize * + * group none 0 mobilize * + * group group 1 mobilize + * group different 1 ignore + * * ignore if notrust + */ +int group_test( + char *grp, + char *ident + ) +{ + if (grp == NULL) + return (0); + + if (strcmp(grp, sys_groupname) == 0) + return (0); + + if (ident == NULL) + return (1); + + if (strcmp(grp, ident) == 0) + return (0); + + return (1); +} +#endif /* AUTOKEY */ + +#ifdef WORKER +void +pool_name_resolved( + int rescode, + int gai_errno, + void * context, + const char * name, + const char * service, + const struct addrinfo * hints, + const struct addrinfo * res + ) +{ + struct peer * pool; /* pool solicitor association */ + associd_t assoc; + + if (rescode) { + msyslog(LOG_ERR, + "error resolving pool %s: %s (%d)", + name, gai_strerror(rescode), rescode); + return; + } + + assoc = (associd_t)(intptr_t)context; + pool = findpeerbyassoc(assoc); + if (NULL == pool) { + msyslog(LOG_ERR, + "Could not find assoc %u for pool DNS %s", + assoc, name); + return; + } + DPRINTF(1, ("pool DNS %s completed\n", name)); + pool->addrs = copy_addrinfo_list(res); + pool->ai = pool->addrs; + pool_xmit(pool); + } +#endif /* WORKER */ -#ifdef OPENSSL +#ifdef AUTOKEY /* * key_expire - purge the key list */ @@ -3036,12 +3928,37 @@ key_expire( } value_free(&peer->sndval); peer->keynumber = 0; + peer->flags &= ~FLAG_ASSOC; #ifdef DEBUG if (debug) - printf("key_expire: at %lu\n", current_time); + printf("key_expire: at %lu associd %d\n", current_time, + peer->associd); #endif } -#endif /* OPENSSL */ +#endif /* AUTOKEY */ + + +/* + * local_refid(peer) - check peer refid to avoid selecting peers + * currently synced to this ntpd. + */ +static int +local_refid( + struct peer * p + ) +{ + endpt * unicast_ep; + + if (p->dstadr != NULL && !(INT_MCASTIF & p->dstadr->flags)) + unicast_ep = p->dstadr; + else + unicast_ep = findinterface(&p->srcadr); + + if (unicast_ep != NULL && p->refid == unicast_ep->addr_refid) + return TRUE; + else + return FALSE; +} /* @@ -3049,7 +3966,7 @@ key_expire( * * A peer is unfit for synchronization if * > TEST10 bad leap or stratum below floor or at or above ceiling - * > TEST11 root distance exceeded + * > TEST11 root distance exceeded for remote peer * > TEST12 a direct or indirect synchronization loop would form * > TEST13 unreachable or noselect */ @@ -3063,40 +3980,37 @@ peer_unfit( /* * A stratum error occurs if (1) the server has never been * synchronized, (2) the server stratum is below the floor or - * greater than or equal to the ceiling, (3) the system stratum - * is below the orphan stratum and the server stratum is greater - * than or equal to the orphan stratum. + * greater than or equal to the ceiling. */ - if (peer->leap == LEAP_NOTINSYNC || peer->stratum < sys_floor || - peer->stratum >= sys_ceiling || (sys_stratum < sys_orphan && - peer->stratum >= sys_orphan)) - rval |= TEST10; /* stratum out of bounds */ + if ( peer->leap == LEAP_NOTINSYNC + || peer->stratum < sys_floor + || peer->stratum >= sys_ceiling) + rval |= TEST10; /* bad synch or stratum */ /* - * A distance error occurs if the root distance is greater than - * or equal to the distance threshold plus the increment due to - * one poll interval. + * A distance error for a remote peer occurs if the root + * distance is greater than or equal to the distance threshold + * plus the increment due to one host poll interval. */ - if (root_distance(peer) >= sys_maxdist + clock_phi * - ULOGTOD(sys_poll)) + if ( !(peer->flags & FLAG_REFCLOCK) + && root_distance(peer) >= sys_maxdist + + clock_phi * ULOGTOD(peer->hpoll)) rval |= TEST11; /* distance exceeded */ /* * A loop error occurs if the remote peer is synchronized to the - * local peer of if the remote peer is synchronized to the same - * server as the local peer, but only if the remote peer is not - * the orphan parent. + * local peer or if the remote peer is synchronized to the same + * server as the local peer but only if the remote peer is + * neither a reference clock nor an orphan. */ - if (peer->stratum > 1 && peer->refid != htonl(LOOPBACKADR) && - ((!peer->dstadr || peer->refid == peer->dstadr->addr_refid) || - peer->refid == sys_refid)) - rval |= TEST12; /* synch loop */ + if (peer->stratum > 1 && local_refid(peer)) + rval |= TEST12; /* synchronization loop */ /* * An unreachable error occurs if the server is unreachable or * the noselect bit is set. */ - if (!peer->reach || peer->flags & FLAG_NOSELECT) + if (!peer->reach || (peer->flags & FLAG_NOSELECT)) rval |= TEST13; /* unreachable */ peer->flash &= ~PEER_TEST_MASK; @@ -3108,74 +4022,143 @@ peer_unfit( /* * Find the precision of this particular machine */ -#define MINSTEP 100e-9 /* minimum clock increment (s) */ -#define MAXSTEP 20e-3 /* maximum clock increment (s) */ -#define MINLOOPS 5 /* minimum number of step samples */ +#define MINSTEP 20e-9 /* minimum clock increment (s) */ +#define MAXSTEP 1 /* maximum clock increment (s) */ +#define MINCHANGES 12 /* minimum number of step samples */ +#define MAXLOOPS ((int)(1. / MINSTEP)) /* avoid infinite loop */ /* - * This routine calculates the system precision, defined as the minimum - * of a sequence of differences between successive readings of the - * system clock. However, if the system clock can be read more than once - * during a tick interval, the difference can be zero or one LSB unit, - * where the LSB corresponds to one nanosecond or one microsecond. - * Conceivably, if some other process preempts this one and reads the - * clock, the difference can be more than one LSB unit. + * This routine measures the system precision defined as the minimum of + * a sequence of differences between successive readings of the system + * clock. However, if a difference is less than MINSTEP, the clock has + * been read more than once during a clock tick and the difference is + * ignored. We set MINSTEP greater than zero in case something happens + * like a cache miss, and to tolerate underlying system clocks which + * ensure each reading is strictly greater than prior readings while + * using an underlying stepping (not interpolated) clock. * - * For hardware clock frequencies of 10 MHz or less, we assume the - * logical clock advances only at the hardware clock tick. For higher - * frequencies, we assume the logical clock can advance no more than 100 - * nanoseconds between ticks. + * sys_tick and sys_precision represent the time to read the clock for + * systems with high-precision clocks, and the tick interval or step + * size for lower-precision stepping clocks. + * + * This routine also measures the time to read the clock on stepping + * system clocks by counting the number of readings between changes of + * the underlying clock. With either type of clock, the minimum time + * to read the clock is saved as sys_fuzz, and used to ensure the + * get_systime() readings always increase and are fuzzed below sys_fuzz. + */ +void +measure_precision(void) +{ + /* + * With sys_fuzz set to zero, get_systime() fuzzing of low bits + * is effectively disabled. trunc_os_clock is FALSE to disable + * get_ostime() simulation of a low-precision system clock. + */ + set_sys_fuzz(0.); + trunc_os_clock = FALSE; + measured_tick = measure_tick_fuzz(); + set_sys_tick_precision(measured_tick); + msyslog(LOG_INFO, "proto: precision = %.3f usec (%d)", + sys_tick * 1e6, sys_precision); + if (sys_fuzz < sys_tick) { + msyslog(LOG_NOTICE, "proto: fuzz beneath %.3f usec", + sys_fuzz * 1e6); + } +} + + +/* + * measure_tick_fuzz() + * + * measures the minimum time to read the clock (stored in sys_fuzz) + * and returns the tick, the larger of the minimum increment observed + * between successive clock readings and the time to read the clock. */ -int -default_get_precision(void) +double +measure_tick_fuzz(void) { + l_fp minstep; /* MINSTEP as l_fp */ l_fp val; /* current seconds fraction */ l_fp last; /* last seconds fraction */ - l_fp diff; /* difference */ + l_fp ldiff; /* val - last */ double tick; /* computed tick value */ - double dtemp; /* scratch */ + double diff; + long repeats; + long max_repeats; + int changes; int i; /* log2 precision */ - /* - * Loop to find tick value in nanoseconds. Toss out outlyer - * values less than the minimun tick value. In wacky cases, use - * the default maximum value. - */ - get_systime(&last); tick = MAXSTEP; - for (i = 0; i < MINLOOPS;) { + max_repeats = 0; + repeats = 0; + changes = 0; + DTOLFP(MINSTEP, &minstep); + get_systime(&last); + for (i = 0; i < MAXLOOPS && changes < MINCHANGES; i++) { get_systime(&val); - diff = val; - L_SUB(&diff, &last); + ldiff = val; + L_SUB(&ldiff, &last); last = val; - LFPTOD(&diff, dtemp); - if (dtemp < MINSTEP) - continue; - i++; - if (dtemp < tick) - tick = dtemp; + if (L_ISGT(&ldiff, &minstep)) { + max_repeats = max(repeats, max_repeats); + repeats = 0; + changes++; + LFPTOD(&ldiff, diff); + tick = min(diff, tick); + } else { + repeats++; + } + } + if (changes < MINCHANGES) { + msyslog(LOG_ERR, "Fatal error: precision could not be measured (MINSTEP too large?)"); + exit(1); } - /* - * Find the nearest power of two. - */ - NLOG(NLOG_SYSEVENT) - msyslog(LOG_INFO, "precision = %.3f usec", tick * 1e6); - for (i = 0; tick <= 1; i++) - tick *= 2; - if (tick - 1. > 1. - tick / 2) - i--; - return (-i); + if (0 == max_repeats) { + set_sys_fuzz(tick); + } else { + set_sys_fuzz(tick / max_repeats); + } + + return tick; } -/* - * kod_proto - called once per second to limit kiss-of-death packets - */ void -kod_proto(void) +set_sys_tick_precision( + double tick + ) { - sys_kod = sys_kod_rate; + int i; + + if (tick > 1.) { + msyslog(LOG_ERR, + "unsupported tick %.3f > 1s ignored", tick); + return; + } + if (tick < measured_tick) { + msyslog(LOG_ERR, + "proto: tick %.3f less than measured tick %.3f, ignored", + tick, measured_tick); + return; + } else if (tick > measured_tick) { + trunc_os_clock = TRUE; + msyslog(LOG_NOTICE, + "proto: truncating system clock to multiples of %.9f", + tick); + } + sys_tick = tick; + + /* + * Find the nearest power of two. + */ + for (i = 0; tick <= 1; i--) + tick *= 2; + if (tick - 1 > 1 - tick / 2) + i++; + + sys_precision = (s_char)i; } @@ -3190,46 +4173,31 @@ init_proto(void) /* * Fill in the sys_* stuff. Default is don't listen to - * broadcasting, authenticate. + * broadcasting, require authentication. */ - sys_leap = LEAP_NOTINSYNC; + set_sys_leap(LEAP_NOTINSYNC); sys_stratum = STRATUM_UNSPEC; memcpy(&sys_refid, "INIT", 4); - sys_precision = (s_char)default_get_precision(); - sys_jitter = LOGTOD(sys_precision); + sys_peer = NULL; sys_rootdelay = 0; - sys_orphandelay = (double)(ntp_random() & 0xffff) / 65536. * - sys_maxdist; - sys_rootdispersion = 0; + sys_rootdisp = 0; L_CLR(&sys_reftime); - sys_peer = NULL; - sys_survivors = 0; + sys_jitter = 0; + measure_precision(); get_systime(&dummy); + sys_survivors = 0; sys_manycastserver = 0; sys_bclient = 0; - sys_bdelay = DEFBROADDELAY; - sys_calldelay = BURST_DELAY; + sys_bdelay = 0; sys_authenticate = 1; - L_CLR(&sys_authdelay); - sys_authdly[0] = sys_authdly[1] = 0; - sys_stattime = 0; + sys_stattime = current_time; + orphwait = current_time + sys_orphwait; proto_clr_stats(); for (i = 0; i < MAX_TTL; i++) { sys_ttl[i] = (u_char)((i * 256) / MAX_TTL); sys_ttlmax = i; } -#ifdef OPENSSL - sys_automax = 1 << NTP_AUTOMAX; -#endif /* OPENSSL */ - - /* - * Default these to enable - */ - ntp_enable = 1; -#ifndef KERNEL_FLL_BUG - kern_enable = 1; -#endif - pps_enable = 0; + hardpps_enable = 0; stats_control = 1; } @@ -3242,49 +4210,25 @@ proto_config( int item, u_long value, double dvalue, - struct sockaddr_storage* svalue + sockaddr_u *svalue ) { /* * Figure out what he wants to change, then do it */ - switch (item) { - - /* - * Turn on/off kernel discipline. - */ - case PROTO_KERNEL: - kern_enable = (int)value; - break; - - /* - * Turn on/off clock discipline. - */ - case PROTO_NTP: - ntp_enable = (int)value; - break; + DPRINTF(2, ("proto_config: code %d value %lu dvalue %lf\n", + item, value, dvalue)); - /* - * Turn on/off monitoring. - */ - case PROTO_MONITOR: - if (value) - mon_start(MON_ON); - else - mon_stop(MON_ON); - break; + switch (item) { /* - * Turn on/off statistics. + * enable and disable commands - arguments are Boolean. */ - case PROTO_FILEGEN: - stats_control = (int)value; + case PROTO_AUTHENTICATE: /* authentication (auth) */ + sys_authenticate = value; break; - /* - * Turn on/off enable broadcasts. - */ - case PROTO_BROADCLIENT: + case PROTO_BROADCLIENT: /* broadcast client (bclient) */ sys_bclient = (int)value; if (sys_bclient == 0) io_unsetbclient(); @@ -3292,152 +4236,116 @@ proto_config( io_setbclient(); break; - /* - * Turn on/off PPS discipline. - */ - case PROTO_PPS: - pps_enable = (int)value; +#ifdef REFCLOCK + case PROTO_CAL: /* refclock calibrate (calibrate) */ + cal_enable = value; break; +#endif /* REFCLOCK */ - /* - * Add muliticast group address. - */ - case PROTO_MULTICAST_ADD: - if (svalue) - io_multicast_add(*svalue); - sys_bclient = 1; + case PROTO_KERNEL: /* kernel discipline (kernel) */ + select_loop(value); break; - /* - * Delete multicast group address. - */ - case PROTO_MULTICAST_DEL: - if (svalue) - io_multicast_del(*svalue); + case PROTO_MONITOR: /* monitoring (monitor) */ + if (value) + mon_start(MON_ON); + else { + mon_stop(MON_ON); + if (mon_enabled) + msyslog(LOG_WARNING, + "restrict: 'monitor' cannot be disabled while 'limited' is enabled"); + } break; - /* - * Set default broadcast delay. - */ - case PROTO_BROADDELAY: - sys_bdelay = dvalue; + case PROTO_NTP: /* NTP discipline (ntp) */ + ntp_enable = value; break; - /* - * Set modem call delay. - */ - case PROTO_CALLDELAY: - sys_calldelay = (int)value; + case PROTO_MODE7: /* mode7 management (ntpdc) */ + ntp_mode7 = value; break; - /* - * Turn on/off authentication to mobilize ephemeral - * associations. - */ - case PROTO_AUTHENTICATE: - sys_authenticate = (int)value; + case PROTO_PPS: /* PPS discipline (pps) */ + hardpps_enable = value; break; - /* - * Set minimum number of survivors. - */ - case PROTO_MINCLOCK: - sys_minclock = (int)dvalue; + case PROTO_FILEGEN: /* statistics (stats) */ + stats_control = value; break; /* - * Set maximum number of preemptable associations. + * tos command - arguments are double, sometimes cast to int */ - case PROTO_MAXCLOCK: - sys_maxclock = (int)dvalue; + case PROTO_BEACON: /* manycast beacon (beacon) */ + sys_beacon = (int)dvalue; break; - /* - * Set minimum number of survivors. - */ - case PROTO_MINSANE: - sys_minsane = (int)dvalue; + case PROTO_BROADDELAY: /* default broadcast delay (bdelay) */ + sys_bdelay = dvalue; break; - /* - * Set stratum floor. - */ - case PROTO_FLOOR: + case PROTO_CEILING: /* stratum ceiling (ceiling) */ + sys_ceiling = (int)dvalue; + break; + + case PROTO_COHORT: /* cohort switch (cohort) */ + sys_cohort = (int)dvalue; + break; + + case PROTO_FLOOR: /* stratum floor (floor) */ sys_floor = (int)dvalue; break; - /* - * Set stratum ceiling. - */ - case PROTO_CEILING: - sys_ceiling = (int)dvalue; + case PROTO_MAXCLOCK: /* maximum candidates (maxclock) */ + sys_maxclock = (int)dvalue; break; - /* - * Set orphan stratum. - */ - case PROTO_ORPHAN: - sys_orphan = (int)dvalue; + case PROTO_MAXDIST: /* select threshold (maxdist) */ + sys_maxdist = dvalue; break; - /* - * Set cohort switch. - */ - case PROTO_COHORT: - sys_cohort = (int)dvalue; + case PROTO_CALLDELAY: /* modem call delay (mdelay) */ + break; /* NOT USED */ + + case PROTO_MINCLOCK: /* minimum candidates (minclock) */ + sys_minclock = (int)dvalue; break; - /* - * Set minimum dispersion increment. - */ - case PROTO_MINDISP: + case PROTO_MINDISP: /* minimum distance (mindist) */ sys_mindisp = dvalue; break; - /* - * Set maximum distance (select threshold). - */ - case PROTO_MAXDIST: - sys_maxdist = dvalue; + case PROTO_MINSANE: /* minimum survivors (minsane) */ + sys_minsane = (int)dvalue; break; - /* - * Set anticlockhop threshold. - */ - case PROTO_MAXHOP: - sys_maxhop = (int)dvalue; + case PROTO_ORPHAN: /* orphan stratum (orphan) */ + sys_orphan = (int)dvalue; break; - /* - * Set adjtime() resolution (s). - */ - case PROTO_ADJ: - sys_tick = dvalue; + case PROTO_ORPHWAIT: /* orphan wait (orphwait) */ + orphwait -= sys_orphwait; + sys_orphwait = (int)dvalue; + orphwait += sys_orphwait; break; /* - * Set manycast beacon interval. + * Miscellaneous commands */ - case PROTO_BEACON: - sys_beacon = (int)dvalue; + case PROTO_MULTICAST_ADD: /* add group address */ + if (svalue != NULL) + io_multicast_add(svalue); + sys_bclient = 1; break; -#ifdef REFCLOCK - /* - * Turn on/off refclock calibrate - */ - case PROTO_CAL: - cal_enable = (int)value; + case PROTO_MULTICAST_DEL: /* delete group address */ + if (svalue != NULL) + io_multicast_del(svalue); break; -#endif /* REFCLOCK */ - default: - /* - * Log this error. - */ - msyslog(LOG_INFO, - "proto_config: illegal item %d, value %ld", item, - value); + default: + msyslog(LOG_NOTICE, + "proto: unsupported option %d", item); } } @@ -3451,11 +4359,12 @@ proto_clr_stats(void) sys_stattime = current_time; sys_received = 0; sys_processed = 0; - sys_newversionpkt = 0; - sys_oldversionpkt = 0; - sys_unknownversion = 0; + sys_newversion = 0; + sys_oldversion = 0; + sys_declined = 0; sys_restricted = 0; sys_badlength = 0; sys_badauth = 0; sys_limitrejected = 0; + sys_kodsent = 0; } diff --git a/contrib/ntp/ntpd/ntp_refclock.c b/contrib/ntp/ntpd/ntp_refclock.c index a29ef085e..1f16ca797 100644 --- a/contrib/ntp/ntpd/ntp_refclock.c +++ b/contrib/ntp/ntpd/ntp_refclock.c @@ -11,6 +11,7 @@ #include "ntp_tty.h" #include "ntp_refclock.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" #include @@ -20,77 +21,54 @@ #ifdef REFCLOCK -#ifdef TTYCLK -# ifdef HAVE_SYS_CLKDEFS_H -# include -# include -# endif -# ifdef HAVE_SYS_SIO_H -# include -# endif -#endif /* TTYCLK */ - #ifdef KERNEL_PLL #include "ntp_syscall.h" #endif /* KERNEL_PLL */ +#ifdef HAVE_PPSAPI +#include "ppsapi_timepps.h" +#include "refclock_atom.h" +#endif /* HAVE_PPSAPI */ + /* * Reference clock support is provided here by maintaining the fiction - * that the clock is actually a peer. As no packets are exchanged with a - * reference clock, however, we replace the transmit, receive and packet - * procedures with separate code to simulate them. Routines + * that the clock is actually a peer. As no packets are exchanged with + * a reference clock, however, we replace the transmit, receive and + * packet procedures with separate code to simulate them. Routines * refclock_transmit() and refclock_receive() maintain the peer * variables in a state analogous to an actual peer and pass reference - * clock data on through the filters. Routines refclock_peer() and + * clock data on through the filters. Routines refclock_peer() and * refclock_unpeer() are called to initialize and terminate reference - * clock associations. A set of utility routines is included to open - * serial devices, process sample data, edit input lines to extract - * embedded timestamps and to peform various debugging functions. + * clock associations. A set of utility routines is included to open + * serial devices, process sample data, and to perform various debugging + * functions. * * The main interface used by these routines is the refclockproc - * structure, which contains for most drivers the decimal equivalants of - * the year, day, month, hour, second and millisecond/microsecond - * decoded from the ASCII timecode. Additional information includes the - * receive timestamp, exception report, statistics tallies, etc. In - * addition, there may be a driver-specific unit structure used for + * structure, which contains for most drivers the decimal equivalants + * of the year, day, month, hour, second and millisecond/microsecond + * decoded from the ASCII timecode. Additional information includes + * the receive timestamp, exception report, statistics tallies, etc. + * In addition, there may be a driver-specific unit structure used for * local control of the device. * * The support routines are passed a pointer to the peer structure, - * which is used for all peer-specific processing and contains a pointer - * to the refclockproc structure, which in turn containes a pointer to - * the unit structure, if used. The peer structure is identified by an - * interface address in the dotted quad form 127.127.t.u (for now only - * IPv4 addresses are used, so we need to be sure the address is it), - * where t is the clock type and u the unit. Some legacy drivers derive - * the refclockproc structure pointer from the table - * typeunit[type][unit]. This interface is strongly discouraged and may - * be abandoned in future. + * which is used for all peer-specific processing and contains a + * pointer to the refclockproc structure, which in turn contains a + * pointer to the unit structure, if used. The peer structure is + * identified by an interface address in the dotted quad form + * 127.127.t.u, where t is the clock type and u the unit. */ -#define MAXUNIT 4 /* max units */ #define FUDGEFAC .1 /* fudge correction factor */ #define LF 0x0a /* ASCII LF */ -#ifdef PPS -int fdpps; /* ppsclock legacy */ -#endif /* PPS */ int cal_enable; /* enable refclock calibrate */ -/* - * Type/unit peer index. Used to find the peer structure for control and - * debugging. When all clock drivers have been converted to new style, - * this dissapears. - */ -static struct peer *typeunit[REFCLK_MAX + 1][MAXUNIT]; - /* * Forward declarations */ -#ifdef QSORT_USES_VOID_P -static int refclock_cmpl_fp P((const void *, const void *)); -#else -static int refclock_cmpl_fp P((const double *, const double *)); -#endif /* QSORT_USES_VOID_P */ -static int refclock_sample P((struct refclockproc *)); +static int refclock_cmpl_fp (const void *, const void *); +static int refclock_sample (struct refclockproc *); +static int refclock_ioctl(int, u_int); /* @@ -113,58 +91,36 @@ refclock_report( return; switch (code) { - case CEVNT_NOMINAL: - break; - - case CEVNT_TIMEOUT: - pp->noreply++; - break; - case CEVNT_BADREPLY: - pp->badformat++; - break; + case CEVNT_TIMEOUT: + pp->noreply++; + break; - case CEVNT_FAULT: - break; + case CEVNT_BADREPLY: + pp->badformat++; + break; - case CEVNT_PROP: - break; + case CEVNT_FAULT: + break; - case CEVNT_BADDATE: - case CEVNT_BADTIME: - pp->baddata++; - break; + case CEVNT_BADDATE: + case CEVNT_BADTIME: + pp->baddata++; + break; - default: - /* shouldn't happen */ - break; + default: + /* ignore others */ + break; } - + if (pp->lastevent < 15) + pp->lastevent++; if (pp->currentstatus != code) { pp->currentstatus = (u_char)code; - - /* RFC1305: copy only iff not CEVNT_NOMINAL */ - if (code != CEVNT_NOMINAL) - pp->lastevent = (u_char)code; - - if (code == CEVNT_FAULT) - msyslog(LOG_ERR, - "clock %s event '%s' (0x%02x)", - refnumtoa(&peer->srcadr), - ceventstr(code), code); - else { - NLOG(NLOG_CLOCKEVENT) - msyslog(LOG_INFO, - "clock %s event '%s' (0x%02x)", - refnumtoa(&peer->srcadr), - ceventstr(code), code); - } - - /* RFC1305: post peer clock event */ - report_event(EVNT_PEERCLOCK, peer); + report_event(PEVNT_CLOCK, peer, ceventstr(code)); } } + /* * init_refclock - initialize the reference clock drivers * @@ -175,14 +131,11 @@ refclock_report( void init_refclock(void) { - int i, j; + int i; - for (i = 0; i < (int)num_refclock_conf; i++) { + for (i = 0; i < (int)num_refclock_conf; i++) if (refclock_conf[i]->clock_init != noentry) (refclock_conf[i]->clock_init)(); - for (j = 0; j < MAXUNIT; j++) - typeunit[i][j] = 0; - } } @@ -211,12 +164,6 @@ refclock_newpeer( * Check for valid clock address. If already running, shut it * down first. */ - if (peer->srcadr.ss_family != AF_INET) { - msyslog(LOG_ERR, - "refclock_newpeer: clock address %s invalid, address family not implemented for refclock", - stoa(&peer->srcadr)); - return (0); - } if (!ISREFCLOCKADR(&peer->srcadr)) { msyslog(LOG_ERR, "refclock_newpeer: clock address %s invalid", @@ -225,7 +172,7 @@ refclock_newpeer( } clktype = (u_char)REFCLOCKTYPE(&peer->srcadr); unit = REFCLOCKUNIT(&peer->srcadr); - if (clktype >= num_refclock_conf || unit >= MAXUNIT || + if (clktype >= num_refclock_conf || refclock_conf[clktype]->clock_start == noentry) { msyslog(LOG_ERR, "refclock_newpeer: clock type %d invalid\n", @@ -236,12 +183,7 @@ refclock_newpeer( /* * Allocate and initialize interface structure */ - pp = (struct refclockproc *)emalloc(sizeof(struct refclockproc)); - if (pp == NULL) - return (0); - - memset((char *)pp, 0, sizeof(struct refclockproc)); - typeunit[clktype][unit] = peer; + pp = emalloc_zero(sizeof(*pp)); peer->procptr = pp; /* @@ -249,12 +191,14 @@ refclock_newpeer( */ peer->refclktype = clktype; peer->refclkunit = (u_char)unit; - peer->flags |= FLAG_REFCLOCK | FLAG_FIXPOLL; + peer->flags |= FLAG_REFCLOCK; peer->leap = LEAP_NOTINSYNC; peer->stratum = STRATUM_REFCLOCK; peer->ppoll = peer->maxpoll; pp->type = clktype; + pp->conf = refclock_conf[clktype]; pp->timestarted = current_time; + pp->io.fd = -1; /* * Set peer.pmode based on the hmode. For appearances only. @@ -297,7 +241,7 @@ refclock_unpeer( * Wiggle the driver to release its resources, then give back * the interface structure. */ - if (!peer->procptr) + if (NULL == peer->procptr) return; clktype = peer->refclktype; @@ -305,7 +249,7 @@ refclock_unpeer( if (refclock_conf[clktype]->clock_shutdown != noentry) (refclock_conf[clktype]->clock_shutdown)(unit, peer); free(peer->procptr); - peer->procptr = 0; + peer->procptr = NULL; } @@ -314,16 +258,18 @@ refclock_unpeer( */ void refclock_timer( - struct peer *peer /* peer structure pointer */ + struct peer *p ) { - u_char clktype; - int unit; - - clktype = peer->refclktype; - unit = peer->refclkunit; - if (refclock_conf[clktype]->clock_timer != noentry) - (refclock_conf[clktype]->clock_timer)(unit, peer); + struct refclockproc * pp; + int unit; + + unit = p->refclkunit; + pp = p->procptr; + if (pp->conf->clock_timer != noentry) + (*pp->conf->clock_timer)(unit, p); + if (pp->action != NULL && pp->nextaction <= current_time) + (*pp->action)(p); } @@ -365,19 +311,17 @@ refclock_transmit( * Update reachability and poll variables like the * network code. */ - oreach = peer->reach; + oreach = peer->reach & 0xfe; peer->reach <<= 1; + if (!(peer->reach & 0x0f)) + clock_filter(peer, 0., 0., MAXDISPERSE); peer->outdate = current_time; if (!peer->reach) { if (oreach) { - report_event(EVNT_UNREACH, peer); + report_event(PEVNT_UNREACH, peer, NULL); peer->timereachable = current_time; } } else { - if (!(oreach & 0x07)) { - clock_filter(peer, 0., 0., MAXDISPERSE); - clock_select(); - } if (peer->flags & FLAG_BURST) peer->burst = NSTAGE; } @@ -393,7 +337,6 @@ refclock_transmit( /* * Compare two doubles - used with qsort() */ -#ifdef QSORT_USES_VOID_P static int refclock_cmpl_fp( const void *p1, @@ -404,30 +347,11 @@ refclock_cmpl_fp( const double *dp2 = (const double *)p2; if (*dp1 < *dp2) - return (-1); - - if (*dp1 > *dp2) - return (1); - - return (0); -} - -#else -static int -refclock_cmpl_fp( - const double *dp1, - const double *dp2 - ) -{ - if (*dp1 < *dp2) - return (-1); - + return -1; if (*dp1 > *dp2) - return (1); - - return (0); + return 1; + return 0; } -#endif /* QSORT_USES_VOID_P */ /* @@ -458,6 +382,7 @@ refclock_process_offset( /* * refclock_process - process a sample from the clock + * refclock_process_f - refclock_process with other than time1 fudge * * This routine converts the timecode in the form days, hours, minutes, * seconds and milliseconds/microseconds to internal timestamp format, @@ -472,8 +397,9 @@ refclock_process_offset( * zero and the fraction for pp->lastrec is set to the PPS offset. */ int -refclock_process( - struct refclockproc *pp /* refclock structure pointer */ +refclock_process_f( + struct refclockproc *pp, /* refclock structure pointer */ + double fudge ) { l_fp offset, ltemp; @@ -493,12 +419,20 @@ refclock_process( offset.l_uf = 0; DTOLFP(pp->nsec / 1e9, <emp); L_ADD(&offset, <emp); - refclock_process_offset(pp, offset, pp->lastrec, - pp->fudgetime1); + refclock_process_offset(pp, offset, pp->lastrec, fudge); return (1); } +int +refclock_process( + struct refclockproc *pp /* refclock structure pointer */ +) +{ + return refclock_process_f(pp, pp->fudgetime1); +} + + /* * refclock_sample - process a pile of samples from the clock * @@ -514,7 +448,7 @@ refclock_sample( struct refclockproc *pp /* refclock structure pointer */ ) { - int i, j, k, m, n; + size_t i, j, k, m, n; double off[MAXSTAGE]; double offset; @@ -532,13 +466,7 @@ refclock_sample( return (0); if (n > 1) - qsort( -#ifdef QSORT_USES_VOID_P - (void *) -#else - (char *) -#endif - off, (size_t)n, sizeof(double), refclock_cmpl_fp); + qsort(off, n, sizeof(off[0]), refclock_cmpl_fp); /* * Reject the furthest from the median of the samples until @@ -570,9 +498,9 @@ refclock_sample( if (debug) printf( "refclock_sample: n %d offset %.6f disp %.6f jitter %.6f\n", - n, pp->offset, pp->disp, pp->jitter); + (int)n, pp->offset, pp->disp, pp->jitter); #endif - return (n); + return (int)n; } @@ -611,30 +539,23 @@ refclock_receive( peer->received++; peer->timereceived = current_time; if (!peer->reach) { - report_event(EVNT_REACH, peer); + report_event(PEVNT_REACH, peer, NULL); peer->timereachable = current_time; } peer->reach |= 1; peer->reftime = pp->lastref; - peer->org = pp->lastrec; - peer->rootdispersion = pp->disp; - get_systime(&peer->rec); + peer->aorg = pp->lastrec; + peer->rootdisp = pp->disp; + get_systime(&peer->dst); if (!refclock_sample(pp)) return; clock_filter(peer, pp->offset, 0., pp->jitter); - record_peer_stats(&peer->srcadr, ctlpeerstatus(peer), - peer->offset, peer->delay, clock_phi * (current_time - - peer->epoch), peer->jitter); - if (cal_enable && last_offset < MINDISPERSE) { -#ifdef KERNEL_PLL - if (peer != sys_peer || pll_status & STA_PPSTIME) -#else - if (peer != sys_peer) -#endif /* KERNEL_PLL */ + if (cal_enable && fabs(last_offset) < sys_mindisp && sys_peer != + NULL) { + if (sys_peer->refclktype == REFCLK_ATOM_PPS && + peer->refclktype != REFCLK_ATOM_PPS) pp->fudgetime1 -= pp->offset * FUDGEFAC; - else - pp->fudgetime1 -= pp->fudgetime1 * FUDGEFAC; } } @@ -656,25 +577,39 @@ refclock_gtlin( l_fp *tsptr /* pointer to timestamp returned */ ) { - char s[BMAX]; - char *dpt, *dpend, *dp; + const char *sp, *spend; + char *dp, *dpend; + int dlen; - dpt = s; - dpend = s + refclock_gtraw(rbufp, s, BMAX - 1, tsptr); - if (dpend - dpt > bmax - 1) - dpend = dpt + bmax - 1; - for (dp = lineptr; dpt < dpend; dpt++) { - char c; + if (bmax <= 0) + return (0); - c = *dpt & 0x7f; + dp = lineptr; + dpend = dp + bmax - 1; /* leave room for NUL pad */ + sp = (const char *)rbufp->recv_buffer; + spend = sp + rbufp->recv_length; + + while (sp != spend && dp != dpend) { + char c; + + c = *sp++ & 0x7f; if (c >= 0x20 && c < 0x7f) *dp++ = c; } - if (dp == lineptr) - return (0); - - *dp = '\0'; - return (dp - lineptr); + /* Get length of data written to the destination buffer. If + * zero, do *not* place a NUL byte to preserve the previous + * buffer content. + */ + dlen = dp - lineptr; + if (dlen) + *dp = '\0'; + *tsptr = rbufp->recv_time; + DPRINTF(2, ("refclock_gtlin: fd %d time %s timecode %d %s\n", + rbufp->fd, ulfptoa(&rbufp->recv_time, 6), dlen, + (dlen != 0) + ? lineptr + : "")); + return (dlen); } @@ -691,9 +626,7 @@ refclock_gtlin( * followed by a NULL character ('\0'), which is not included in the * count. * - * If a timestamp is present in the timecode, as produced by the tty_clk - * STREAMS module, it returns that as the timestamp; otherwise, it - * returns the buffer timestamp. + * *tsptr receives a copy of the buffer timestamp. */ int refclock_gtraw( @@ -703,74 +636,99 @@ refclock_gtraw( l_fp *tsptr /* pointer to timestamp returned */ ) { - char *dpt, *dpend, *dp; - l_fp trtmp, tstmp; - int i; + if (bmax <= 0) + return (0); + bmax -= 1; /* leave room for trailing NUL */ + if (bmax > rbufp->recv_length) + bmax = rbufp->recv_length; + memcpy(lineptr, rbufp->recv_buffer, bmax); + lineptr[bmax] = '\0'; + + *tsptr = rbufp->recv_time; + DPRINTF(2, ("refclock_gtraw: fd %d time %s timecode %d %s\n", + rbufp->fd, ulfptoa(&rbufp->recv_time, 6), bmax, + lineptr)); + return (bmax); +} - /* - * Check for the presence of a timestamp left by the tty_clock - * module and, if present, use that instead of the buffer - * timestamp captured by the I/O routines. We recognize a - * timestamp by noting its value is earlier than the buffer - * timestamp, but not more than one second earlier. - */ - dpt = (char *)rbufp->recv_buffer; - dpend = dpt + rbufp->recv_length; - trtmp = rbufp->recv_time; - if (dpend >= dpt + 8) { - if (buftvtots(dpend - 8, &tstmp)) { - L_SUB(&trtmp, &tstmp); - if (trtmp.l_ui == 0) { -#ifdef DEBUG - if (debug > 1) { - printf( - "refclock_gtlin: fd %d ldisc %s", - rbufp->fd, lfptoa(&trtmp, - 6)); - get_systime(&trtmp); - L_SUB(&trtmp, &tstmp); - printf(" sigio %s\n", - lfptoa(&trtmp, 6)); - } -#endif - dpend -= 8; - trtmp = tstmp; - } else - trtmp = rbufp->recv_time; - } + +/* + * indicate_refclock_packet() + * + * Passes a fragment of refclock input read from the device to the + * driver direct input routine, which may consume it (batch it for + * queuing once a logical unit is assembled). If it is not so + * consumed, queue it for the driver's receive entrypoint. + * + * The return value is TRUE if the data has been consumed as a fragment + * and should not be counted as a received packet. + */ +int +indicate_refclock_packet( + struct refclockio * rio, + struct recvbuf * rb + ) +{ + /* Does this refclock use direct input routine? */ + if (rio->io_input != NULL && (*rio->io_input)(rb) == 0) { + /* + * data was consumed - nothing to pass up + * into block input machine + */ + freerecvbuf(rb); + + return TRUE; } + add_full_recv_buffer(rb); - /* - * Copy the raw buffer to the user string. The string is padded - * with a NULL, which is not included in the character count. + return FALSE; +} + + +/* + * process_refclock_packet() + * + * Used for deferred processing of 'io_input' on systems where threading + * is used (notably Windows). This is acting as a trampoline to make the + * real calls to the refclock functions. + */ +#ifdef HAVE_IO_COMPLETION_PORT +void +process_refclock_packet( + struct recvbuf * rb + ) +{ + struct refclockio * rio; + + /* get the refclockio structure from the receive buffer */ + rio = &rb->recv_peer->procptr->io; + + /* call 'clock_recv' if either there is no input function or the + * raw input function tells us to feed the packet to the + * receiver. */ - if (dpend - dpt > bmax - 1) - dpend = dpt + bmax - 1; - for (dp = lineptr; dpt < dpend; dpt++) - *dp++ = *dpt; - *dp = '\0'; - i = dp - lineptr; -#ifdef DEBUG - if (debug > 1) - printf("refclock_gtraw: fd %d time %s timecode %d %s\n", - rbufp->fd, ulfptoa(&trtmp, 6), i, lineptr); -#endif - *tsptr = trtmp; - return (i); + if (rio->io_input == NULL || (*rio->io_input)(rb) != 0) { + rio->recvcount++; + packets_received++; + handler_pkts++; + (*rio->clock_recv)(rb); + } } +#endif /* HAVE_IO_COMPLETION_PORT */ /* * The following code does not apply to WINNT & VMS ... */ -#if !defined SYS_VXWORKS && !defined SYS_WINNT +#if !defined(SYS_VXWORKS) && !defined(SYS_WINNT) #if defined(HAVE_TERMIOS) || defined(HAVE_SYSV_TTYS) || defined(HAVE_BSD_TTYS) /* * refclock_open - open serial port for reference clock * * This routine opens a serial port for I/O and sets default options. It - * returns the file descriptor if success and zero if failure. + * returns the file descriptor if successful, or logs an error and + * returns -1. */ int refclock_open( @@ -781,6 +739,9 @@ refclock_open( { int fd; int omode; +#ifdef O_NONBLOCK + char trash[128]; /* litter bin for old input data */ +#endif /* * Open serial port and set default options @@ -794,21 +755,41 @@ refclock_open( #endif fd = open(dev, omode, 0777); + /* refclock_open() long returned 0 on failure, avoid it. */ + if (0 == fd) { + fd = dup(0); + SAVE_ERRNO( + close(0); + ) + } if (fd < 0) { - msyslog(LOG_ERR, "refclock_open %s: %m", dev); - return (0); + SAVE_ERRNO( + msyslog(LOG_ERR, "refclock_open %s: %m", dev); + ) + return -1; } if (!refclock_setup(fd, speed, lflags)) { close(fd); - return (0); + return -1; } if (!refclock_ioctl(fd, lflags)) { close(fd); - return (0); + return -1; } - return (fd); +#ifdef O_NONBLOCK + /* + * We want to make sure there is no pending trash in the input + * buffer. Since we have non-blocking IO available, this is a + * good moment to read and dump all available outdated stuff + * that might have become toxic for the driver. + */ + while (read(fd, trash, sizeof(trash)) > 0 || errno == EINTR) + /*NOP*/; +#endif + return fd; } + /* * refclock_setup - initialize terminal interface structure */ @@ -821,9 +802,6 @@ refclock_setup( { int i; TTY ttyb, *ttyp; -#ifdef PPS - fdpps = fd; /* ppsclock legacy */ -#endif /* PPS */ /* * By default, the serial line port is initialized in canonical @@ -840,9 +818,12 @@ refclock_setup( * POSIX serial line parameters (termios interface) */ if (tcgetattr(fd, ttyp) < 0) { - msyslog(LOG_ERR, - "refclock_setup fd %d tcgetattr: %m", fd); - return (0); + SAVE_ERRNO( + msyslog(LOG_ERR, + "refclock_setup fd %d tcgetattr: %m", + fd); + ) + return FALSE; } /* @@ -857,7 +838,7 @@ refclock_setup( ttyp->c_cflag = CS8 | CLOCAL | CREAD; if (lflags & LDISC_7O1) { /* HP Z3801A needs 7-bit, odd parity */ - ttyp->c_cflag = CS7 | PARENB | PARODD | CLOCAL | CREAD; + ttyp->c_cflag = CS7 | PARENB | PARODD | CLOCAL | CREAD; } cfsetispeed(&ttyb, speed); cfsetospeed(&ttyb, speed); @@ -896,10 +877,22 @@ refclock_setup( if (lflags & LDISC_ECHO) ttyp->c_lflag |= ECHO; if (tcsetattr(fd, TCSANOW, ttyp) < 0) { - msyslog(LOG_ERR, - "refclock_setup fd %d TCSANOW: %m", fd); - return (0); + SAVE_ERRNO( + msyslog(LOG_ERR, + "refclock_setup fd %d TCSANOW: %m", + fd); + ) + return FALSE; } + + /* + * flush input and output buffers to discard any outdated stuff + * that might have become toxic for the driver. Failing to do so + * is logged, but we keep our fingers crossed otherwise. + */ + if (tcflush(fd, TCIOFLUSH) < 0) + msyslog(LOG_ERR, "refclock_setup fd %d tcflush(): %m", + fd); #endif /* HAVE_TERMIOS */ #ifdef HAVE_SYSV_TTYS @@ -909,9 +902,12 @@ refclock_setup( * */ if (ioctl(fd, TCGETA, ttyp) < 0) { - msyslog(LOG_ERR, - "refclock_setup fd %d TCGETA: %m", fd); - return (0); + SAVE_ERRNO( + msyslog(LOG_ERR, + "refclock_setup fd %d TCGETA: %m", + fd); + ) + return FALSE; } /* @@ -957,9 +953,11 @@ refclock_setup( ttyp->c_cc[VMIN] = 1; } if (ioctl(fd, TCSETA, ttyp) < 0) { - msyslog(LOG_ERR, - "refclock_setup fd %d TCSETA: %m", fd); - return (0); + SAVE_ERRNO( + msyslog(LOG_ERR, + "refclock_setup fd %d TCSETA: %m", fd); + ) + return FALSE; } #endif /* HAVE_SYSV_TTYS */ @@ -969,23 +967,26 @@ refclock_setup( * 4.3bsd serial line parameters (sgttyb interface) */ if (ioctl(fd, TIOCGETP, (char *)ttyp) < 0) { - msyslog(LOG_ERR, - "refclock_setup fd %d TIOCGETP: %m", fd); - return (0); + SAVE_ERRNO( + msyslog(LOG_ERR, + "refclock_setup fd %d TIOCGETP: %m", + fd); + ) + return FALSE; } if (speed) ttyp->sg_ispeed = ttyp->sg_ospeed = speed; ttyp->sg_flags = EVENP | ODDP | CRMOD; if (ioctl(fd, TIOCSETP, (char *)ttyp) < 0) { - msyslog(LOG_ERR, - "refclock_setup TIOCSETP: %m"); - return (0); + SAVE_ERRNO( + msyslog(LOG_ERR, "refclock_setup TIOCSETP: %m"); + ) + return FALSE; } #endif /* HAVE_BSD_TTYS */ return(1); } #endif /* HAVE_TERMIOS || HAVE_SYSV_TTYS || HAVE_BSD_TTYS */ -#endif /* SYS_VXWORKS SYS_WINNT */ /* @@ -994,8 +995,8 @@ refclock_setup( * This routine attempts to hide the internal, system-specific details * of serial ports. It can handle POSIX (termios), SYSV (termio) and BSD * (sgtty) interfaces with varying degrees of success. The routine sets - * up optional features such as tty_clk. The routine returns 1 if - * success and 0 if failure. + * up optional features such as tty_clk. The routine returns TRUE if + * successful. */ int refclock_ioctl( @@ -1004,53 +1005,13 @@ refclock_ioctl( ) { /* - * simply return 1 if no UNIX line discipline is supported - */ -#if !defined SYS_VXWORKS && !defined SYS_WINNT -#if defined(HAVE_TERMIOS) || defined(HAVE_SYSV_TTYS) || defined(HAVE_BSD_TTYS) - -#ifdef DEBUG - if (debug) - printf("refclock_ioctl: fd %d flags 0x%x\n", fd, - lflags); -#endif -#ifdef TTYCLK - - /* - * The TTYCLK option provides timestamping at the driver level. - * It requires the tty_clk streams module and System V STREAMS - * support. If not available, don't complain. + * simply return TRUE if no UNIX line discipline is supported */ - if (lflags & (LDISC_CLK | LDISC_CLKPPS | LDISC_ACTS)) { - int rval = 0; + DPRINTF(1, ("refclock_ioctl: fd %d flags 0x%x\n", fd, lflags)); - if (ioctl(fd, I_PUSH, "clk") < 0) { - msyslog(LOG_NOTICE, - "refclock_ioctl fd %d I_PUSH: %m", fd); - return (0); -#ifdef CLK_SETSTR - } else { - char *str; - - if (lflags & LDISC_CLKPPS) - str = "\377"; - else if (lflags & LDISC_ACTS) - str = "*"; - else - str = "\n"; - if (ioctl(fd, CLK_SETSTR, str) < 0) { - msyslog(LOG_ERR, - "refclock_ioctl fd %d CLK_SETSTR: %m", fd); - return (0); - } -#endif /*CLK_SETSTR */ - } - } -#endif /* TTYCLK */ -#endif /* HAVE_TERMIOS || HAVE_SYSV_TTYS || HAVE_BSD_TTYS */ -#endif /* SYS_VXWORKS SYS_WINNT */ - return (1); + return TRUE; } +#endif /* !defined(SYS_VXWORKS) && !defined(SYS_WINNT) */ /* @@ -1064,8 +1025,8 @@ refclock_ioctl( */ void refclock_control( - struct sockaddr_storage *srcadr, - struct refclockstat *in, + sockaddr_u *srcadr, + const struct refclockstat *in, struct refclockstat *out ) { @@ -1077,30 +1038,24 @@ refclock_control( /* * Check for valid address and running peer */ - if (srcadr->ss_family != AF_INET) - return; - if (!ISREFCLOCKADR(srcadr)) return; clktype = (u_char)REFCLOCKTYPE(srcadr); unit = REFCLOCKUNIT(srcadr); - if (clktype >= num_refclock_conf || unit >= MAXUNIT) - return; - peer = typeunit[clktype][unit]; - if (peer == NULL) - return; + peer = findexistingpeer(srcadr, NULL, NULL, -1, 0); - if (peer->procptr == NULL) + if (NULL == peer) return; + INSIST(peer->procptr != NULL); pp = peer->procptr; /* * Initialize requested data */ - if (in != 0) { + if (in != NULL) { if (in->haveflags & CLK_HAVETIME1) pp->fudgetime1 = in->fudgetime1; if (in->haveflags & CLK_HAVETIME2) @@ -1130,14 +1085,25 @@ refclock_control( /* * Readback requested data */ - if (out != 0) { - out->haveflags = CLK_HAVETIME1 | CLK_HAVEVAL1 | - CLK_HAVEVAL2 | CLK_HAVEFLAG4; - out->fudgetime1 = pp->fudgetime1; - out->fudgetime2 = pp->fudgetime2; + if (out != NULL) { out->fudgeval1 = pp->stratum; out->fudgeval2 = pp->refid; + out->haveflags = CLK_HAVEVAL1 | CLK_HAVEVAL2; + out->fudgetime1 = pp->fudgetime1; + if (0.0 != out->fudgetime1) + out->haveflags |= CLK_HAVETIME1; + out->fudgetime2 = pp->fudgetime2; + if (0.0 != out->fudgetime2) + out->haveflags |= CLK_HAVETIME2; out->flags = (u_char) pp->sloppyclockflag; + if (CLK_FLAG1 & out->flags) + out->haveflags |= CLK_HAVEFLAG1; + if (CLK_FLAG2 & out->flags) + out->haveflags |= CLK_HAVEFLAG2; + if (CLK_FLAG3 & out->flags) + out->haveflags |= CLK_HAVEFLAG3; + if (CLK_FLAG4 & out->flags) + out->haveflags |= CLK_HAVEFLAG4; out->timereset = current_time - pp->timestarted; out->polls = pp->polls; @@ -1149,7 +1115,7 @@ refclock_control( out->currentstatus = pp->currentstatus; out->type = pp->type; out->clockdesc = pp->clockdesc; - out->lencode = pp->lencode; + out->lencode = (u_short)pp->lencode; out->p_lastcode = pp->a_lastcode; } @@ -1170,32 +1136,28 @@ refclock_control( */ void refclock_buginfo( - struct sockaddr_storage *srcadr, /* clock address */ + sockaddr_u *srcadr, /* clock address */ struct refclockbug *bug /* output structure */ ) { struct peer *peer; struct refclockproc *pp; - u_char clktype; + int clktype; int unit; - int i; + unsigned u; /* * Check for valid address and peer structure */ - if (srcadr->ss_family != AF_INET) - return; - if (!ISREFCLOCKADR(srcadr)) return; clktype = (u_char) REFCLOCKTYPE(srcadr); unit = REFCLOCKUNIT(srcadr); - if (clktype >= num_refclock_conf || unit >= MAXUNIT) - return; - peer = typeunit[clktype][unit]; - if (peer == NULL) + peer = findexistingpeer(srcadr, NULL, NULL, -1, 0); + + if (NULL == peer || NULL == peer->procptr) return; pp = peer->procptr; @@ -1216,8 +1178,8 @@ refclock_buginfo( bug->stimes = 0xfffffffc; bug->times[0] = pp->lastref; bug->times[1] = pp->lastrec; - for (i = 2; i < (int)bug->ntimes; i++) - DTOLFP(pp->filter[i - 2], &bug->times[i]); + for (u = 2; u < bug->ntimes; u++) + DTOLFP(pp->filter[u - 2], &bug->times[u]); /* * Give the stuff to the clock @@ -1226,4 +1188,145 @@ refclock_buginfo( (refclock_conf[clktype]->clock_buginfo)(unit, bug, peer); } + +#ifdef HAVE_PPSAPI +/* + * refclock_ppsapi - initialize/update ppsapi + * + * This routine is called after the fudge command to open the PPSAPI + * interface for later parameter setting after the fudge command. + */ +int +refclock_ppsapi( + int fddev, /* fd device */ + struct refclock_atom *ap /* atom structure pointer */ + ) +{ + if (ap->handle == 0) { + if (time_pps_create(fddev, &ap->handle) < 0) { + msyslog(LOG_ERR, + "refclock_ppsapi: time_pps_create: %m"); + return (0); + } + } + return (1); +} + + +/* + * refclock_params - set ppsapi parameters + * + * This routine is called to set the PPSAPI parameters after the fudge + * command. + */ +int +refclock_params( + int mode, /* mode bits */ + struct refclock_atom *ap /* atom structure pointer */ + ) +{ + ZERO(ap->pps_params); + ap->pps_params.api_version = PPS_API_VERS_1; + + /* + * Solaris serial ports provide PPS pulse capture only on the + * assert edge. FreeBSD serial ports provide capture on the + * clear edge, while FreeBSD parallel ports provide capture + * on the assert edge. Your mileage may vary. + */ + if (mode & CLK_FLAG2) + ap->pps_params.mode = PPS_TSFMT_TSPEC | PPS_CAPTURECLEAR; + else + ap->pps_params.mode = PPS_TSFMT_TSPEC | PPS_CAPTUREASSERT; + if (time_pps_setparams(ap->handle, &ap->pps_params) < 0) { + msyslog(LOG_ERR, + "refclock_params: time_pps_setparams: %m"); + return (0); + } + + /* + * If flag3 is lit, select the kernel PPS if we can. + */ + if (mode & CLK_FLAG3) { + if (time_pps_kcbind(ap->handle, PPS_KC_HARDPPS, + ap->pps_params.mode & ~PPS_TSFMT_TSPEC, + PPS_TSFMT_TSPEC) < 0) { + msyslog(LOG_ERR, + "refclock_params: time_pps_kcbind: %m"); + return (0); + } + hardpps_enable = 1; + } + return (1); +} + + +/* + * refclock_pps - called once per second + * + * This routine is called once per second. It snatches the PPS + * timestamp from the kernel and saves the sign-extended fraction in + * a circular buffer for processing at the next poll event. + */ +int +refclock_pps( + struct peer *peer, /* peer structure pointer */ + struct refclock_atom *ap, /* atom structure pointer */ + int mode /* mode bits */ + ) +{ + struct refclockproc *pp; + pps_info_t pps_info; + struct timespec timeout; + double dtemp; + + /* + * We require the clock to be synchronized before setting the + * parameters. When the parameters have been set, fetch the + * most recent PPS timestamp. + */ + pp = peer->procptr; + if (ap->handle == 0) + return (0); + + if (ap->pps_params.mode == 0 && sys_leap != LEAP_NOTINSYNC) { + if (refclock_params(pp->sloppyclockflag, ap) < 1) + return (0); + } + timeout.tv_sec = 0; + timeout.tv_nsec = 0; + ZERO(pps_info); + if (time_pps_fetch(ap->handle, PPS_TSFMT_TSPEC, &pps_info, + &timeout) < 0) { + refclock_report(peer, CEVNT_FAULT); + return (0); + } + timeout = ap->ts; + if (ap->pps_params.mode & PPS_CAPTUREASSERT) + ap->ts = pps_info.assert_timestamp; + else if (ap->pps_params.mode & PPS_CAPTURECLEAR) + ap->ts = pps_info.clear_timestamp; + else + return (0); + + if (0 == memcmp(&timeout, &ap->ts, sizeof(timeout))) + return (0); + + /* + * Convert to signed fraction offset and stuff in median filter. + */ + pp->lastrec.l_ui = (u_int32)ap->ts.tv_sec + JAN_1970; + dtemp = ap->ts.tv_nsec / 1e9; + pp->lastrec.l_uf = (u_int32)(dtemp * FRAC); + if (dtemp > .5) + dtemp -= 1.; + SAMPLE(-dtemp + pp->fudgetime1); +#ifdef DEBUG + if (debug > 1) + printf("refclock_pps: %lu %f %f\n", current_time, + dtemp, pp->fudgetime1); +#endif + return (1); +} +#endif /* HAVE_PPSAPI */ #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/ntp_request.c b/contrib/ntp/ntpd/ntp_request.c index 6d479566d..6073f99c4 100644 --- a/contrib/ntp/ntpd/ntp_request.c +++ b/contrib/ntp/ntpd/ntp_request.c @@ -13,11 +13,14 @@ #include "ntp_refclock.h" #include "ntp_if.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" #include #include #include +#ifdef HAVE_NETINET_IN_H #include +#endif #include #include "recvbuff.h" @@ -47,77 +50,78 @@ struct req_proc { short needs_auth; /* true when authentication needed */ short sizeofitem; /* size of request data item (older size)*/ short v6_sizeofitem; /* size of request data item (new size)*/ - void (*handler) P((struct sockaddr_storage *, struct interface *, - struct req_pkt *)); /* routine to handle request */ + void (*handler) (sockaddr_u *, endpt *, + struct req_pkt *); /* routine to handle request */ }; /* * Universal request codes */ -static struct req_proc univ_codes[] = { - { NO_REQUEST, NOAUTH, 0, 0 } +static const struct req_proc univ_codes[] = { + { NO_REQUEST, NOAUTH, 0, 0, NULL } }; -static void req_ack P((struct sockaddr_storage *, struct interface *, struct req_pkt *, int)); -static char * prepare_pkt P((struct sockaddr_storage *, struct interface *, struct req_pkt *, u_int)); -static char * more_pkt P((void)); -static void flush_pkt P((void)); -static void peer_list P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void peer_list_sum P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void peer_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void peer_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void sys_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void sys_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void mem_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void io_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void timer_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void loop_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_conf P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_unconf P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void set_sys_flag P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void clr_sys_flag P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void setclr_flags P((struct sockaddr_storage *, struct interface *, struct req_pkt *, u_long)); -static void list_restrict P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_resaddflags P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_ressubflags P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_unrestrict P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_restrict P((struct sockaddr_storage *, struct interface *, struct req_pkt *, int)); -static void mon_getlist_0 P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void mon_getlist_1 P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void reset_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void reset_peer P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_key_reread P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void trust_key P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void untrust_key P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_trustkey P((struct sockaddr_storage *, struct interface *, struct req_pkt *, u_long)); -static void get_auth_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void reset_auth_stats P((void)); -static void req_get_traps P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void req_set_trap P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void req_clr_trap P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_setclr_trap P((struct sockaddr_storage *, struct interface *, struct req_pkt *, int)); -static void set_request_keyid P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void set_control_keyid P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void get_ctl_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void get_if_stats P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void do_if_reload P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void req_ack (sockaddr_u *, endpt *, struct req_pkt *, int); +static void * prepare_pkt (sockaddr_u *, endpt *, + struct req_pkt *, size_t); +static void * more_pkt (void); +static void flush_pkt (void); +static void list_peers (sockaddr_u *, endpt *, struct req_pkt *); +static void list_peers_sum (sockaddr_u *, endpt *, struct req_pkt *); +static void peer_info (sockaddr_u *, endpt *, struct req_pkt *); +static void peer_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void sys_info (sockaddr_u *, endpt *, struct req_pkt *); +static void sys_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void mem_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void io_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void timer_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void loop_info (sockaddr_u *, endpt *, struct req_pkt *); +static void do_conf (sockaddr_u *, endpt *, struct req_pkt *); +static void do_unconf (sockaddr_u *, endpt *, struct req_pkt *); +static void set_sys_flag (sockaddr_u *, endpt *, struct req_pkt *); +static void clr_sys_flag (sockaddr_u *, endpt *, struct req_pkt *); +static void setclr_flags (sockaddr_u *, endpt *, struct req_pkt *, u_long); +static void list_restrict4 (restrict_u *, struct info_restrict **); +static void list_restrict6 (restrict_u *, struct info_restrict **); +static void list_restrict (sockaddr_u *, endpt *, struct req_pkt *); +static void do_resaddflags (sockaddr_u *, endpt *, struct req_pkt *); +static void do_ressubflags (sockaddr_u *, endpt *, struct req_pkt *); +static void do_unrestrict (sockaddr_u *, endpt *, struct req_pkt *); +static void do_restrict (sockaddr_u *, endpt *, struct req_pkt *, int); +static void mon_getlist (sockaddr_u *, endpt *, struct req_pkt *); +static void reset_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void reset_peer (sockaddr_u *, endpt *, struct req_pkt *); +static void do_key_reread (sockaddr_u *, endpt *, struct req_pkt *); +static void trust_key (sockaddr_u *, endpt *, struct req_pkt *); +static void untrust_key (sockaddr_u *, endpt *, struct req_pkt *); +static void do_trustkey (sockaddr_u *, endpt *, struct req_pkt *, u_long); +static void get_auth_info (sockaddr_u *, endpt *, struct req_pkt *); +static void req_get_traps (sockaddr_u *, endpt *, struct req_pkt *); +static void req_set_trap (sockaddr_u *, endpt *, struct req_pkt *); +static void req_clr_trap (sockaddr_u *, endpt *, struct req_pkt *); +static void do_setclr_trap (sockaddr_u *, endpt *, struct req_pkt *, int); +static void set_request_keyid (sockaddr_u *, endpt *, struct req_pkt *); +static void set_control_keyid (sockaddr_u *, endpt *, struct req_pkt *); +static void get_ctl_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void get_if_stats (sockaddr_u *, endpt *, struct req_pkt *); +static void do_if_reload (sockaddr_u *, endpt *, struct req_pkt *); #ifdef KERNEL_PLL -static void get_kernel_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void get_kernel_info (sockaddr_u *, endpt *, struct req_pkt *); #endif /* KERNEL_PLL */ #ifdef REFCLOCK -static void get_clock_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); -static void set_clock_fudge P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void get_clock_info (sockaddr_u *, endpt *, struct req_pkt *); +static void set_clock_fudge (sockaddr_u *, endpt *, struct req_pkt *); #endif /* REFCLOCK */ #ifdef REFCLOCK -static void get_clkbug_info P((struct sockaddr_storage *, struct interface *, struct req_pkt *)); +static void get_clkbug_info (sockaddr_u *, endpt *, struct req_pkt *); #endif /* REFCLOCK */ /* * ntpd request codes */ -static struct req_proc ntp_codes[] = { - { REQ_PEER_LIST, NOAUTH, 0, 0, peer_list }, - { REQ_PEER_LIST_SUM, NOAUTH, 0, 0, peer_list_sum }, +static const struct req_proc ntp_codes[] = { + { REQ_PEER_LIST, NOAUTH, 0, 0, list_peers }, + { REQ_PEER_LIST_SUM, NOAUTH, 0, 0, list_peers_sum }, { REQ_PEER_INFO, NOAUTH, v4sizeof(struct info_peer_list), sizeof(struct info_peer_list), peer_info}, { REQ_PEER_STATS, NOAUTH, v4sizeof(struct info_peer_list), @@ -143,8 +147,8 @@ static struct req_proc ntp_codes[] = { sizeof(struct conf_restrict), do_ressubflags }, { REQ_UNRESTRICT, AUTH, v4sizeof(struct conf_restrict), sizeof(struct conf_restrict), do_unrestrict }, - { REQ_MON_GETLIST, NOAUTH, 0, 0, mon_getlist_0 }, - { REQ_MON_GETLIST_1, NOAUTH, 0, 0, mon_getlist_1 }, + { REQ_MON_GETLIST, NOAUTH, 0, 0, mon_getlist }, + { REQ_MON_GETLIST_1, NOAUTH, 0, 0, mon_getlist }, { REQ_RESET_STATS, AUTH, sizeof(struct reset_flags), 0, reset_stats }, { REQ_RESET_PEER, AUTH, v4sizeof(struct conf_unpeer), sizeof(struct conf_unpeer), reset_peer }, @@ -174,7 +178,7 @@ static struct req_proc ntp_codes[] = { get_clkbug_info }, #endif { REQ_IF_STATS, AUTH, 0, 0, get_if_stats }, - { REQ_IF_RELOAD, AUTH, 0, 0, do_if_reload }, + { REQ_IF_RELOAD, AUTH, 0, 0, do_if_reload }, { NO_REQUEST, NOAUTH, 0, 0, 0 } }; @@ -192,14 +196,16 @@ keyid_t info_auth_keyid; u_long numrequests; /* number of requests we've received */ u_long numresppkts; /* number of resp packets sent with data */ -u_long errorcounter[INFO_ERR_AUTH+1]; /* lazy way to count errors, indexed */ -/* by the error code */ +/* + * lazy way to count errors, indexed by the error code + */ +u_long errorcounter[MAX_INFO_ERR + 1]; /* * A hack. To keep the authentication module clear of ntp-ism's, we * include a time reset variable for its stats here. */ -static u_long auth_timereset; +u_long auth_timereset; /* * Response packet used by these routines. Also some state information @@ -216,8 +222,8 @@ static int itemsize; static int databytes; static char exbuf[RESP_DATA_SIZE]; static int usingexbuf; -static struct sockaddr_storage *toaddr; -static struct interface *frominter; +static sockaddr_u *toaddr; +static endpt *frominter; /* * init_request - initialize request data @@ -225,7 +231,7 @@ static struct interface *frominter; void init_request (void) { - int i; + size_t i; numrequests = 0; numresppkts = 0; @@ -242,8 +248,8 @@ init_request (void) */ static void req_ack( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt, int errcode ) @@ -255,7 +261,7 @@ req_ack( rpkt.auth_seq = AUTH_SEQ(0, 0); rpkt.implementation = inpkt->implementation; rpkt.request = inpkt->request; - rpkt.err_nitems = ERR_NITEMS(errcode, 0); + rpkt.err_nitems = ERR_NITEMS(errcode, 0); rpkt.mbz_itemsize = MBZ_ITEMSIZE(0); /* @@ -270,18 +276,15 @@ req_ack( * prepare_pkt - prepare response packet for transmission, return pointer * to storage for data item. */ -static char * +static void * prepare_pkt( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *pkt, - u_int structsize + size_t structsize ) { -#ifdef DEBUG - if (debug > 3) - printf("request: preparing pkt\n"); -#endif + DPRINTF(4, ("request: preparing pkt\n")); /* * Fill in the implementation, request and itemsize fields @@ -305,35 +308,32 @@ prepare_pkt( /* * return the beginning of the packet buffer. */ - return &rpkt.data[0]; + return &rpkt.u; } /* * more_pkt - return a data pointer for a new item. */ -static char * +static void * more_pkt(void) { /* * If we were using the extra buffer, send the packet. */ if (usingexbuf) { -#ifdef DEBUG - if (debug > 2) - printf("request: sending pkt\n"); -#endif + DPRINTF(3, ("request: sending pkt\n")); rpkt.rm_vn_mode = RM_VN_MODE(RESP_BIT, MORE_BIT, reqver); rpkt.auth_seq = AUTH_SEQ(0, seqno); rpkt.err_nitems = htons((u_short)nitems); sendpkt(toaddr, frominter, -1, (struct pkt *)&rpkt, - RESP_HEADER_SIZE+databytes); + RESP_HEADER_SIZE + databytes); numresppkts++; /* * Copy data out of exbuf into the packet. */ - memmove(&rpkt.data[0], exbuf, (unsigned)itemsize); + memcpy(&rpkt.u.data[0], exbuf, (unsigned)itemsize); seqno++; databytes = 0; nitems = 0; @@ -343,26 +343,20 @@ more_pkt(void) databytes += itemsize; nitems++; if (databytes + itemsize <= RESP_DATA_SIZE) { -#ifdef DEBUG - if (debug > 3) - printf("request: giving him more data\n"); -#endif + DPRINTF(4, ("request: giving him more data\n")); /* * More room in packet. Give him the * next address. */ - return &rpkt.data[databytes]; + return &rpkt.u.data[databytes]; } else { /* * No room in packet. Give him the extra * buffer unless this was the last in the sequence. */ -#ifdef DEBUG - if (debug > 3) - printf("request: into extra buffer\n"); -#endif + DPRINTF(4, ("request: into extra buffer\n")); if (seqno == MAXSEQ) - return (char *)0; + return NULL; else { usingexbuf = 1; return exbuf; @@ -377,17 +371,14 @@ more_pkt(void) static void flush_pkt(void) { -#ifdef DEBUG - if (debug > 2) - printf("request: flushing packet, %d items\n", nitems); -#endif + DPRINTF(3, ("request: flushing packet, %d items\n", nitems)); /* * Must send the last packet. If nothing in here and nothing * has been sent, send an error saying no data to be found. */ if (seqno == 0 && nitems == 0) - req_ack(toaddr, frominter, (struct req_pkt *)&rpkt, - INFO_ERR_NODATA); + req_ack(toaddr, frominter, (struct req_pkt *)&rpkt, + INFO_ERR_NODATA); else { rpkt.rm_vn_mode = RM_VN_MODE(RESP_BIT, 0, reqver); rpkt.auth_seq = AUTH_SEQ(0, seqno); @@ -400,6 +391,17 @@ flush_pkt(void) +/* + * Given a buffer, return the packet mode + */ +int +get_packet_mode(struct recvbuf *rbufp) +{ + struct req_pkt *inpkt = (struct req_pkt *)&rbufp->recv_pkt; + return (INFO_MODE(inpkt->rm_vn_mode)); +} + + /* * process_private - process private mode (7) packets */ @@ -412,24 +414,27 @@ process_private( static u_long quiet_until; struct req_pkt *inpkt; struct req_pkt_tail *tailinpkt; - struct sockaddr_storage *srcadr; - struct interface *inter; - struct req_proc *proc; + sockaddr_u *srcadr; + endpt *inter; + const struct req_proc *proc; int ec; short temp_size; + l_fp ftmp; + double dtemp; + size_t recv_len; + size_t noslop_len; + size_t mac_len; /* * Initialize pointers, for convenience */ + recv_len = rbufp->recv_length; inpkt = (struct req_pkt *)&rbufp->recv_pkt; srcadr = &rbufp->recv_srcadr; inter = rbufp->dstadr; -#ifdef DEBUG - if (debug > 2) - printf("process_private: impl %d req %d\n", - inpkt->implementation, inpkt->request); -#endif + DPRINTF(3, ("process_private: impl %d req %d\n", + inpkt->implementation, inpkt->request)); /* * Do some sanity checks on the packet. Return a format @@ -443,7 +448,7 @@ process_private( || (++ec, INFO_SEQ(inpkt->auth_seq) != 0) || (++ec, INFO_ERR(inpkt->err_nitems) != 0) || (++ec, INFO_MBZ(inpkt->mbz_itemsize) != 0) - || (++ec, rbufp->recv_length < REQ_LEN_HDR) + || (++ec, rbufp->recv_length < (int)REQ_LEN_HDR) ) { NLOG(NLOG_SYSEVENT) if (current_time >= quiet_until) { @@ -462,10 +467,10 @@ process_private( * Get the appropriate procedure list to search. */ if (inpkt->implementation == IMPL_UNIV) - proc = univ_codes; + proc = univ_codes; else if ((inpkt->implementation == IMPL_XNTPD) || (inpkt->implementation == IMPL_XNTPD_OLD)) - proc = ntp_codes; + proc = ntp_codes; else { req_ack(srcadr, inter, inpkt, INFO_ERR_IMPL); return; @@ -477,7 +482,7 @@ process_private( */ while (proc->request_code != NO_REQUEST) { if (proc->request_code == (short) inpkt->request) - break; + break; proc++; } if (proc->request_code == NO_REQUEST) { @@ -485,10 +490,7 @@ process_private( return; } -#ifdef DEBUG - if (debug > 3) - printf("found request in tables\n"); -#endif + DPRINTF(4, ("found request in tables\n")); /* * If we need data, check to see if we have some. If we @@ -507,21 +509,15 @@ process_private( !(inpkt->implementation == IMPL_XNTPD && inpkt->request == REQ_CONFIG && temp_size == sizeof(struct old_conf_peer))) { -#ifdef DEBUG - if (debug > 2) - printf("process_private: wrong item size, received %d, should be %d or %d\n", - temp_size, proc->sizeofitem, proc->v6_sizeofitem); -#endif + DPRINTF(3, ("process_private: wrong item size, received %d, should be %d or %d\n", + temp_size, proc->sizeofitem, proc->v6_sizeofitem)); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } if ((proc->sizeofitem != 0) && - ((temp_size * INFO_NITEMS(inpkt->err_nitems)) > - (rbufp->recv_length - REQ_LEN_HDR))) { -#ifdef DEBUG - if (debug > 2) - printf("process_private: not enough data\n"); -#endif + ((size_t)(temp_size * INFO_NITEMS(inpkt->err_nitems)) > + (recv_len - REQ_LEN_HDR))) { + DPRINTF(3, ("process_private: not enough data\n")); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } @@ -547,58 +543,80 @@ process_private( * time stamp. */ if (proc->needs_auth && sys_authenticate) { - l_fp ftmp; - double dtemp; - - if (rbufp->recv_length < (int)((REQ_LEN_HDR + + + if (recv_len < (REQ_LEN_HDR + (INFO_ITEMSIZE(inpkt->mbz_itemsize) * - INFO_NITEMS(inpkt->err_nitems)) - + sizeof(struct req_pkt_tail)))) { + INFO_NITEMS(inpkt->err_nitems)) + + REQ_TAIL_MIN)) { req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); + return; } - tailinpkt = (struct req_pkt_tail *)((char *)&rbufp->recv_pkt + - rbufp->recv_length - sizeof(struct req_pkt_tail)); /* - * If this guy is restricted from doing this, don't let him - * If wrong key was used, or packet doesn't have mac, return. + * For 16-octet digests, regardless of itemsize and + * nitems, authenticated requests are a fixed size + * with the timestamp, key ID, and digest located + * at the end of the packet. Because the key ID + * determining the digest size precedes the digest, + * for larger digests the fixed size request scheme + * is abandoned and the timestamp, key ID, and digest + * are located relative to the start of the packet, + * with the digest size determined by the packet size. */ - if (!INFO_IS_AUTH(inpkt->auth_seq) || info_auth_keyid == 0 + noslop_len = REQ_LEN_HDR + + INFO_ITEMSIZE(inpkt->mbz_itemsize) * + INFO_NITEMS(inpkt->err_nitems) + + sizeof(inpkt->tstamp); + /* 32-bit alignment */ + noslop_len = (noslop_len + 3) & ~3; + if (recv_len > (noslop_len + MAX_MAC_LEN)) + mac_len = 20; + else + mac_len = recv_len - noslop_len; + + tailinpkt = (void *)((char *)inpkt + recv_len - + (mac_len + sizeof(inpkt->tstamp))); + + /* + * If this guy is restricted from doing this, don't let + * him. If the wrong key was used, or packet doesn't + * have mac, return. + */ + if (!INFO_IS_AUTH(inpkt->auth_seq) || !info_auth_keyid || ntohl(tailinpkt->keyid) != info_auth_keyid) { + DPRINTF(5, ("failed auth %d info_auth_keyid %u pkt keyid %u maclen %lu\n", + INFO_IS_AUTH(inpkt->auth_seq), + info_auth_keyid, + ntohl(tailinpkt->keyid), (u_long)mac_len)); #ifdef DEBUG - if (debug > 4) - printf("failed auth %d info_auth_keyid %lu pkt keyid %lu\n", - INFO_IS_AUTH(inpkt->auth_seq), - (u_long)info_auth_keyid, - (u_long)ntohl(tailinpkt->keyid)); msyslog(LOG_DEBUG, - "process_private: failed auth %d info_auth_keyid %lu pkt keyid %lu\n", + "process_private: failed auth %d info_auth_keyid %u pkt keyid %u maclen %lu\n", INFO_IS_AUTH(inpkt->auth_seq), - (u_long)info_auth_keyid, - (u_long)ntohl(tailinpkt->keyid)); + info_auth_keyid, + ntohl(tailinpkt->keyid), (u_long)mac_len); #endif req_ack(srcadr, inter, inpkt, INFO_ERR_AUTH); return; } - if (rbufp->recv_length > REQ_LEN_MAC) { -#ifdef DEBUG - if (debug > 4) - printf("bad pkt length %d\n", - rbufp->recv_length); -#endif - msyslog(LOG_ERR, "process_private: bad pkt length %d", - rbufp->recv_length); + if (recv_len > REQ_LEN_NOMAC + MAX_MAC_LEN) { + DPRINTF(5, ("bad pkt length %zu\n", recv_len)); + msyslog(LOG_ERR, + "process_private: bad pkt length %zu", + recv_len); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } if (!mod_okay || !authhavekey(info_auth_keyid)) { + DPRINTF(5, ("failed auth mod_okay %d\n", + mod_okay)); #ifdef DEBUG - if (debug > 4) - printf("failed auth mod_okay %d\n", mod_okay); msyslog(LOG_DEBUG, "process_private: failed auth mod_okay %d\n", mod_okay); #endif + if (!mod_okay) { + sys_restricted++; + } req_ack(srcadr, inter, inpkt, INFO_ERR_AUTH); return; } @@ -610,14 +628,12 @@ process_private( NTOHL_FP(&tailinpkt->tstamp, &ftmp); L_SUB(&ftmp, &rbufp->recv_time); LFPTOD(&ftmp, dtemp); - if (fabs(dtemp) >= INFO_TS_MAXSKEW) { + if (fabs(dtemp) > INFO_TS_MAXSKEW) { /* * He's a loser. Tell him. */ -#ifdef DEBUG - if (debug > 4) - printf("xmit/rcv timestamp delta > INFO_TS_MAXSKEW\n"); -#endif + DPRINTF(5, ("xmit/rcv timestamp delta %g > INFO_TS_MAXSKEW %g\n", + dtemp, INFO_TS_MAXSKEW)); req_ack(srcadr, inter, inpkt, INFO_ERR_AUTH); return; } @@ -626,22 +642,14 @@ process_private( * So far so good. See if decryption works out okay. */ if (!authdecrypt(info_auth_keyid, (u_int32 *)inpkt, - rbufp->recv_length - sizeof(struct req_pkt_tail) + - REQ_LEN_HDR, sizeof(struct req_pkt_tail) - REQ_LEN_HDR)) { -#ifdef DEBUG - if (debug > 4) - printf("authdecrypt failed\n"); -#endif + recv_len - mac_len, mac_len)) { + DPRINTF(5, ("authdecrypt failed\n")); req_ack(srcadr, inter, inpkt, INFO_ERR_AUTH); return; } } -#ifdef DEBUG - if (debug > 3) - printf("process_private: all okay, into handler\n"); -#endif - + DPRINTF(3, ("process_private: all okay, into handler\n")); /* * Packet is okay. Call the handler to send him data. */ @@ -650,162 +658,149 @@ process_private( /* - * peer_list - send a list of the peers + * list_peers - send a list of the peers */ static void -peer_list( - struct sockaddr_storage *srcadr, - struct interface *inter, +list_peers( + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_peer_list *ip; - register struct peer *pp; - register int i; - register int skip = 0; + struct info_peer_list *ip; + struct peer *pp; + int skip = 0; ip = (struct info_peer_list *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_peer_list)); - for (i = 0; i < NTP_HASH_SIZE && ip != 0; i++) { - pp = peer_hash[i]; - while (pp != 0 && ip != 0) { - if (pp->srcadr.ss_family == AF_INET6) { - if (client_v6_capable) { - ip->addr6 = GET_INADDR6(pp->srcadr); - ip->v6_flag = 1; - skip = 0; - } else { - skip = 1; - break; - } - } else { - ip->addr = GET_INADDR(pp->srcadr); - if (client_v6_capable) - ip->v6_flag = 0; + for (pp = peer_list; pp != NULL && ip != NULL; pp = pp->p_link) { + if (IS_IPV6(&pp->srcadr)) { + if (client_v6_capable) { + ip->addr6 = SOCK_ADDR6(&pp->srcadr); + ip->v6_flag = 1; skip = 0; + } else { + skip = 1; + break; } + } else { + ip->addr = NSRCADR(&pp->srcadr); + if (client_v6_capable) + ip->v6_flag = 0; + skip = 0; + } - if(!skip) { - ip->port = NSRCPORT(&pp->srcadr); - ip->hmode = pp->hmode; - ip->flags = 0; - if (pp->flags & FLAG_CONFIG) - ip->flags |= INFO_FLAG_CONFIG; - if (pp == sys_peer) - ip->flags |= INFO_FLAG_SYSPEER; - if (pp->status == CTL_PST_SEL_SYNCCAND) - ip->flags |= INFO_FLAG_SEL_CANDIDATE; - if (pp->status >= CTL_PST_SEL_SYSPEER) - ip->flags |= INFO_FLAG_SHORTLIST; - ip = (struct info_peer_list *)more_pkt(); - } - pp = pp->next; + if (!skip) { + ip->port = NSRCPORT(&pp->srcadr); + ip->hmode = pp->hmode; + ip->flags = 0; + if (pp->flags & FLAG_CONFIG) + ip->flags |= INFO_FLAG_CONFIG; + if (pp == sys_peer) + ip->flags |= INFO_FLAG_SYSPEER; + if (pp->status == CTL_PST_SEL_SYNCCAND) + ip->flags |= INFO_FLAG_SEL_CANDIDATE; + if (pp->status >= CTL_PST_SEL_SYSPEER) + ip->flags |= INFO_FLAG_SHORTLIST; + ip = (struct info_peer_list *)more_pkt(); } - } + } /* for pp */ + flush_pkt(); } /* - * peer_list_sum - return extended peer list + * list_peers_sum - return extended peer list */ static void -peer_list_sum( - struct sockaddr_storage *srcadr, - struct interface *inter, +list_peers_sum( + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { register struct info_peer_summary *ips; register struct peer *pp; - register int i; l_fp ltmp; register int skip; -#ifdef DEBUG - if (debug > 2) - printf("wants peer list summary\n"); -#endif + DPRINTF(3, ("wants peer list summary\n")); + ips = (struct info_peer_summary *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_peer_summary)); - for (i = 0; i < NTP_HASH_SIZE && ips != 0; i++) { - pp = peer_hash[i]; - while (pp != 0 && ips != 0) { -#ifdef DEBUG - if (debug > 3) - printf("sum: got one\n"); -#endif - /* - * Be careful here not to return v6 peers when we - * want only v4. - */ - if (pp->srcadr.ss_family == AF_INET6) { - if (client_v6_capable) { - ips->srcadr6 = GET_INADDR6(pp->srcadr); - ips->v6_flag = 1; - if (pp->dstadr) - ips->dstadr6 = GET_INADDR6(pp->dstadr->sin); - else - memset(&ips->dstadr6, 0, sizeof(ips->dstadr6)); - skip = 0; - } else { - skip = 1; - break; - } - } else { - ips->srcadr = GET_INADDR(pp->srcadr); - if (client_v6_capable) - ips->v6_flag = 0; -/* XXX PDM This code is buggy. Need to replace with a straightforward assignment */ - + for (pp = peer_list; pp != NULL && ips != NULL; pp = pp->p_link) { + DPRINTF(4, ("sum: got one\n")); + /* + * Be careful here not to return v6 peers when we + * want only v4. + */ + if (IS_IPV6(&pp->srcadr)) { + if (client_v6_capable) { + ips->srcadr6 = SOCK_ADDR6(&pp->srcadr); + ips->v6_flag = 1; if (pp->dstadr) - ips->dstadr = (pp->processed) ? - pp->cast_flags == MDF_BCAST ? - GET_INADDR(pp->dstadr->bcast): - pp->cast_flags ? - GET_INADDR(pp->dstadr->sin) ? - GET_INADDR(pp->dstadr->sin): - GET_INADDR(pp->dstadr->bcast): - 1 : GET_INADDR(pp->dstadr->sin); + ips->dstadr6 = SOCK_ADDR6(&pp->dstadr->sin); else - memset(&ips->dstadr, 0, sizeof(ips->dstadr)); - + ZERO(ips->dstadr6); skip = 0; + } else { + skip = 1; + break; } + } else { + ips->srcadr = NSRCADR(&pp->srcadr); + if (client_v6_capable) + ips->v6_flag = 0; - if (!skip){ - ips->srcport = NSRCPORT(&pp->srcadr); - ips->stratum = pp->stratum; - ips->hpoll = pp->hpoll; - ips->ppoll = pp->ppoll; - ips->reach = pp->reach; - ips->flags = 0; - if (pp == sys_peer) - ips->flags |= INFO_FLAG_SYSPEER; - if (pp->flags & FLAG_CONFIG) - ips->flags |= INFO_FLAG_CONFIG; - if (pp->flags & FLAG_REFCLOCK) - ips->flags |= INFO_FLAG_REFCLOCK; - if (pp->flags & FLAG_AUTHENABLE) - ips->flags |= INFO_FLAG_AUTHENABLE; - if (pp->flags & FLAG_PREFER) - ips->flags |= INFO_FLAG_PREFER; - if (pp->flags & FLAG_BURST) - ips->flags |= INFO_FLAG_BURST; - if (pp->status == CTL_PST_SEL_SYNCCAND) - ips->flags |= INFO_FLAG_SEL_CANDIDATE; - if (pp->status >= CTL_PST_SEL_SYSPEER) - ips->flags |= INFO_FLAG_SHORTLIST; - ips->hmode = pp->hmode; - ips->delay = HTONS_FP(DTOFP(pp->delay)); - DTOLFP(pp->offset, <mp); - HTONL_FP(<mp, &ips->offset); - ips->dispersion = HTONS_FP(DTOUFP(SQRT(pp->disp))); - } - pp = pp->next; - ips = (struct info_peer_summary *)more_pkt(); + if (pp->dstadr) { + if (!pp->processed) + ips->dstadr = NSRCADR(&pp->dstadr->sin); + else { + if (MDF_BCAST == pp->cast_flags) + ips->dstadr = NSRCADR(&pp->dstadr->bcast); + else if (pp->cast_flags) { + ips->dstadr = NSRCADR(&pp->dstadr->sin); + if (!ips->dstadr) + ips->dstadr = NSRCADR(&pp->dstadr->bcast); + } + } + } else + ips->dstadr = 0; + + skip = 0; } - } + + if (!skip) { + ips->srcport = NSRCPORT(&pp->srcadr); + ips->stratum = pp->stratum; + ips->hpoll = pp->hpoll; + ips->ppoll = pp->ppoll; + ips->reach = pp->reach; + ips->flags = 0; + if (pp == sys_peer) + ips->flags |= INFO_FLAG_SYSPEER; + if (pp->flags & FLAG_CONFIG) + ips->flags |= INFO_FLAG_CONFIG; + if (pp->flags & FLAG_REFCLOCK) + ips->flags |= INFO_FLAG_REFCLOCK; + if (pp->flags & FLAG_PREFER) + ips->flags |= INFO_FLAG_PREFER; + if (pp->flags & FLAG_BURST) + ips->flags |= INFO_FLAG_BURST; + if (pp->status == CTL_PST_SEL_SYNCCAND) + ips->flags |= INFO_FLAG_SEL_CANDIDATE; + if (pp->status >= CTL_PST_SEL_SYSPEER) + ips->flags |= INFO_FLAG_SHORTLIST; + ips->hmode = pp->hmode; + ips->delay = HTONS_FP(DTOFP(pp->delay)); + DTOLFP(pp->offset, <mp); + HTONL_FP(<mp, &ips->offset); + ips->dispersion = HTONS_FP(DTOUFP(SQRT(pp->disp))); + } + ips = (struct info_peer_summary *)more_pkt(); + } /* for pp */ + flush_pkt(); } @@ -815,88 +810,98 @@ peer_list_sum( */ static void peer_info ( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_peer_list *ipl; - register struct peer *pp; - register struct info_peer *ip; - register int items; - register int i, j; - struct sockaddr_storage addr; - extern struct peer *sys_peer; - l_fp ltmp; + u_short items; + size_t item_sz; + char * datap; + struct info_peer_list ipl; + struct peer * pp; + struct info_peer * ip; + int i; + int j; + sockaddr_u addr; + l_fp ltmp; - memset((char *)&addr, 0, sizeof addr); items = INFO_NITEMS(inpkt->err_nitems); - ipl = (struct info_peer_list *) inpkt->data; - - ip = (struct info_peer *)prepare_pkt(srcadr, inter, inpkt, - v6sizeof(struct info_peer)); - while (items-- > 0 && ip != 0) { - memset((char *)&addr, 0, sizeof(addr)); - NSRCPORT(&addr) = ipl->port; - if (client_v6_capable && ipl->v6_flag != 0) { - addr.ss_family = AF_INET6; - GET_INADDR6(addr) = ipl->addr6; + item_sz = INFO_ITEMSIZE(inpkt->mbz_itemsize); + datap = inpkt->u.data; + if (item_sz != sizeof(ipl)) { + req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); + return; + } + ip = prepare_pkt(srcadr, inter, inpkt, + v6sizeof(struct info_peer)); + while (items-- > 0 && ip != NULL) { + ZERO(ipl); + memcpy(&ipl, datap, item_sz); + ZERO_SOCK(&addr); + NSRCPORT(&addr) = ipl.port; + if (client_v6_capable && ipl.v6_flag) { + AF(&addr) = AF_INET6; + SOCK_ADDR6(&addr) = ipl.addr6; } else { - addr.ss_family = AF_INET; - GET_INADDR(addr) = ipl->addr; + AF(&addr) = AF_INET; + NSRCADR(&addr) = ipl.addr; } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif - ipl++; - if ((pp = findexistingpeer(&addr, (struct peer *)0, -1)) == 0) - continue; - if (pp->srcadr.ss_family == AF_INET6) { + datap += item_sz; + + pp = findexistingpeer(&addr, NULL, NULL, -1, 0); + if (NULL == pp) + continue; + if (IS_IPV6(srcadr)) { if (pp->dstadr) - ip->dstadr6 = pp->cast_flags == MDF_BCAST ? - GET_INADDR6(pp->dstadr->bcast) : - GET_INADDR6(pp->dstadr->sin); + ip->dstadr6 = + (MDF_BCAST == pp->cast_flags) + ? SOCK_ADDR6(&pp->dstadr->bcast) + : SOCK_ADDR6(&pp->dstadr->sin); else - memset(&ip->dstadr6, 0, sizeof(ip->dstadr6)); + ZERO(ip->dstadr6); - ip->srcadr6 = GET_INADDR6(pp->srcadr); + ip->srcadr6 = SOCK_ADDR6(&pp->srcadr); ip->v6_flag = 1; } else { -/* XXX PDM This code is buggy. Need to replace with a straightforward assignment */ - if (pp->dstadr) - ip->dstadr = (pp->processed) ? - pp->cast_flags == MDF_BCAST ? - GET_INADDR(pp->dstadr->bcast): - pp->cast_flags ? - GET_INADDR(pp->dstadr->sin) ? - GET_INADDR(pp->dstadr->sin): - GET_INADDR(pp->dstadr->bcast): - 2 : GET_INADDR(pp->dstadr->sin); - else - memset(&ip->dstadr, 0, sizeof(ip->dstadr)); + if (pp->dstadr) { + if (!pp->processed) + ip->dstadr = NSRCADR(&pp->dstadr->sin); + else { + if (MDF_BCAST == pp->cast_flags) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + else if (pp->cast_flags) { + ip->dstadr = NSRCADR(&pp->dstadr->sin); + if (!ip->dstadr) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + } + } + } else + ip->dstadr = 0; - ip->srcadr = GET_INADDR(pp->srcadr); + ip->srcadr = NSRCADR(&pp->srcadr); if (client_v6_capable) ip->v6_flag = 0; } ip->srcport = NSRCPORT(&pp->srcadr); ip->flags = 0; if (pp == sys_peer) - ip->flags |= INFO_FLAG_SYSPEER; + ip->flags |= INFO_FLAG_SYSPEER; if (pp->flags & FLAG_CONFIG) - ip->flags |= INFO_FLAG_CONFIG; + ip->flags |= INFO_FLAG_CONFIG; if (pp->flags & FLAG_REFCLOCK) - ip->flags |= INFO_FLAG_REFCLOCK; - if (pp->flags & FLAG_AUTHENABLE) - ip->flags |= INFO_FLAG_AUTHENABLE; + ip->flags |= INFO_FLAG_REFCLOCK; if (pp->flags & FLAG_PREFER) - ip->flags |= INFO_FLAG_PREFER; + ip->flags |= INFO_FLAG_PREFER; if (pp->flags & FLAG_BURST) - ip->flags |= INFO_FLAG_BURST; + ip->flags |= INFO_FLAG_BURST; if (pp->status == CTL_PST_SEL_SYNCCAND) - ip->flags |= INFO_FLAG_SEL_CANDIDATE; + ip->flags |= INFO_FLAG_SEL_CANDIDATE; if (pp->status >= CTL_PST_SEL_SYSPEER) - ip->flags |= INFO_FLAG_SHORTLIST; + ip->flags |= INFO_FLAG_SHORTLIST; ip->leap = pp->leap; ip->hmode = pp->hmode; ip->keyid = pp->keyid; @@ -906,37 +911,38 @@ peer_info ( ip->precision = pp->precision; ip->version = pp->version; ip->reach = pp->reach; - ip->unreach = (u_char) pp->unreach; + ip->unreach = (u_char)pp->unreach; ip->flash = (u_char)pp->flash; - ip->flash2 = (u_short) pp->flash; - ip->estbdelay = HTONS_FP(DTOFP(pp->estbdelay)); - ip->ttl = pp->ttl; + ip->flash2 = (u_short)pp->flash; + ip->estbdelay = HTONS_FP(DTOFP(pp->delay)); + ip->ttl = (u_char)pp->ttl; ip->associd = htons(pp->associd); ip->rootdelay = HTONS_FP(DTOUFP(pp->rootdelay)); - ip->rootdispersion = HTONS_FP(DTOUFP(pp->rootdispersion)); + ip->rootdispersion = HTONS_FP(DTOUFP(pp->rootdisp)); ip->refid = pp->refid; HTONL_FP(&pp->reftime, &ip->reftime); - HTONL_FP(&pp->org, &ip->org); + HTONL_FP(&pp->aorg, &ip->org); HTONL_FP(&pp->rec, &ip->rec); HTONL_FP(&pp->xmt, &ip->xmt); j = pp->filter_nextpt - 1; for (i = 0; i < NTP_SHIFT; i++, j--) { if (j < 0) - j = NTP_SHIFT-1; + j = NTP_SHIFT-1; ip->filtdelay[i] = HTONS_FP(DTOFP(pp->filter_delay[j])); DTOLFP(pp->filter_offset[j], <mp); HTONL_FP(<mp, &ip->filtoffset[i]); - ip->order[i] = (u_char)((pp->filter_nextpt+NTP_SHIFT-1) - - pp->filter_order[i]); + ip->order[i] = (u_char)((pp->filter_nextpt + + NTP_SHIFT - 1) - + pp->filter_order[i]); if (ip->order[i] >= NTP_SHIFT) - ip->order[i] -= NTP_SHIFT; + ip->order[i] -= NTP_SHIFT; } DTOLFP(pp->offset, <mp); HTONL_FP(<mp, &ip->offset); ip->delay = HTONS_FP(DTOFP(pp->delay)); ip->dispersion = HTONS_FP(DTOUFP(SQRT(pp->disp))); ip->selectdisp = HTONS_FP(DTOUFP(SQRT(pp->jitter))); - ip = (struct info_peer *)more_pkt(); + ip = more_pkt(); } flush_pkt(); } @@ -947,78 +953,84 @@ peer_info ( */ static void peer_stats ( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_peer_list *ipl; - register struct peer *pp; - register struct info_peer_stats *ip; - register int items; - struct sockaddr_storage addr; - extern struct peer *sys_peer; - -#ifdef DEBUG - if (debug) - printf("peer_stats: called\n"); -#endif + u_short items; + size_t item_sz; + char * datap; + struct info_peer_list ipl; + struct peer * pp; + struct info_peer_stats *ip; + sockaddr_u addr; + + DPRINTF(1, ("peer_stats: called\n")); items = INFO_NITEMS(inpkt->err_nitems); - ipl = (struct info_peer_list *) inpkt->data; - ip = (struct info_peer_stats *)prepare_pkt(srcadr, inter, inpkt, - v6sizeof(struct info_peer_stats)); - while (items-- > 0 && ip != 0) { - memset((char *)&addr, 0, sizeof(addr)); - NSRCPORT(&addr) = ipl->port; - if (client_v6_capable && ipl->v6_flag) { - addr.ss_family = AF_INET6; - GET_INADDR6(addr) = ipl->addr6; + item_sz = INFO_ITEMSIZE(inpkt->mbz_itemsize); + datap = inpkt->u.data; + if (item_sz > sizeof(ipl)) { + req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); + return; + } + ip = prepare_pkt(srcadr, inter, inpkt, + v6sizeof(struct info_peer_stats)); + while (items-- > 0 && ip != NULL) { + ZERO(ipl); + memcpy(&ipl, datap, item_sz); + ZERO(addr); + NSRCPORT(&addr) = ipl.port; + if (client_v6_capable && ipl.v6_flag) { + AF(&addr) = AF_INET6; + SOCK_ADDR6(&addr) = ipl.addr6; } else { - addr.ss_family = AF_INET; - GET_INADDR(addr) = ipl->addr; + AF(&addr) = AF_INET; + NSRCADR(&addr) = ipl.addr; } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); -#endif -#ifdef DEBUG - if (debug) - printf("peer_stats: looking for %s, %d, %d\n", stoa(&addr), - ipl->port, ((struct sockaddr_in6 *)&addr)->sin6_port); +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif - ipl = (struct info_peer_list *)((char *)ipl + - INFO_ITEMSIZE(inpkt->mbz_itemsize)); - - if ((pp = findexistingpeer(&addr, (struct peer *)0, -1)) == 0) - continue; -#ifdef DEBUG - if (debug) - printf("peer_stats: found %s\n", stoa(&addr)); -#endif - if (pp->srcadr.ss_family == AF_INET) { - if (pp->dstadr) - ip->dstadr = (pp->processed) ? - pp->cast_flags == MDF_BCAST ? - GET_INADDR(pp->dstadr->bcast): - pp->cast_flags ? - GET_INADDR(pp->dstadr->sin) ? - GET_INADDR(pp->dstadr->sin): - GET_INADDR(pp->dstadr->bcast): - 3 : 7; - else - memset(&ip->dstadr, 0, sizeof(ip->dstadr)); + DPRINTF(1, ("peer_stats: looking for %s, %d, %d\n", + stoa(&addr), ipl.port, NSRCPORT(&addr))); + + datap += item_sz; + + pp = findexistingpeer(&addr, NULL, NULL, -1, 0); + if (NULL == pp) + continue; + + DPRINTF(1, ("peer_stats: found %s\n", stoa(&addr))); + + if (IS_IPV4(&pp->srcadr)) { + if (pp->dstadr) { + if (!pp->processed) + ip->dstadr = NSRCADR(&pp->dstadr->sin); + else { + if (MDF_BCAST == pp->cast_flags) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + else if (pp->cast_flags) { + ip->dstadr = NSRCADR(&pp->dstadr->sin); + if (!ip->dstadr) + ip->dstadr = NSRCADR(&pp->dstadr->bcast); + } + } + } else + ip->dstadr = 0; - ip->srcadr = GET_INADDR(pp->srcadr); + ip->srcadr = NSRCADR(&pp->srcadr); if (client_v6_capable) ip->v6_flag = 0; } else { if (pp->dstadr) - ip->dstadr6 = pp->cast_flags == MDF_BCAST ? - GET_INADDR6(pp->dstadr->bcast): - GET_INADDR6(pp->dstadr->sin); + ip->dstadr6 = + (MDF_BCAST == pp->cast_flags) + ? SOCK_ADDR6(&pp->dstadr->bcast) + : SOCK_ADDR6(&pp->dstadr->sin); else - memset(&ip->dstadr6, 0, sizeof(ip->dstadr6)); - - ip->srcadr6 = GET_INADDR6(pp->srcadr); + ZERO(ip->dstadr6); + + ip->srcadr6 = SOCK_ADDR6(&pp->srcadr); ip->v6_flag = 1; } ip->srcport = NSRCPORT(&pp->srcadr); @@ -1029,8 +1041,6 @@ peer_stats ( ip->flags |= INFO_FLAG_CONFIG; if (pp->flags & FLAG_REFCLOCK) ip->flags |= INFO_FLAG_REFCLOCK; - if (pp->flags & FLAG_AUTHENABLE) - ip->flags |= INFO_FLAG_AUTHENABLE; if (pp->flags & FLAG_PREFER) ip->flags |= INFO_FLAG_PREFER; if (pp->flags & FLAG_BURST) @@ -1064,8 +1074,8 @@ peer_stats ( */ static void sys_info( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -1074,13 +1084,13 @@ sys_info( is = (struct info_sys *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_sys)); - if (sys_peer != 0) { - if (sys_peer->srcadr.ss_family == AF_INET) { - is->peer = GET_INADDR(sys_peer->srcadr); + if (sys_peer) { + if (IS_IPV4(&sys_peer->srcadr)) { + is->peer = NSRCADR(&sys_peer->srcadr); if (client_v6_capable) is->v6_flag = 0; } else if (client_v6_capable) { - is->peer6 = GET_INADDR6(sys_peer->srcadr); + is->peer6 = SOCK_ADDR6(&sys_peer->srcadr); is->v6_flag = 1; } is->peer_mode = sys_peer->hmode; @@ -1096,9 +1106,9 @@ sys_info( is->stratum = sys_stratum; is->precision = sys_precision; is->rootdelay = htonl(DTOFP(sys_rootdelay)); - is->rootdispersion = htonl(DTOUFP(sys_rootdispersion)); + is->rootdispersion = htonl(DTOUFP(sys_rootdisp)); is->frequency = htonl(DTOFP(sys_jitter)); - is->stability = htonl(DTOUFP(clock_stability)); + is->stability = htonl(DTOUFP(clock_stability * 1e6)); is->refid = sys_refid; HTONL_FP(&sys_reftime, &is->reftime); @@ -1119,13 +1129,12 @@ sys_info( is->flags |= INFO_FLAG_MONITOR; if (ntp_enable) is->flags |= INFO_FLAG_NTP; - if (pps_enable) + if (hardpps_enable) is->flags |= INFO_FLAG_PPS_SYNC; if (stats_control) is->flags |= INFO_FLAG_FILEGEN; is->bdelay = HTONS_FP(DTOFP(sys_bdelay)); - HTONL_UF(sys_authdelay.l_f, &is->authdelay); - + HTONL_UF(sys_authdelay.l_uf, &is->authdelay); (void) more_pkt(); flush_pkt(); } @@ -1136,24 +1145,21 @@ sys_info( */ static void sys_stats( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { register struct info_sys_stats *ss; - /* - * Importations from the protocol module - */ ss = (struct info_sys_stats *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_sys_stats)); ss->timeup = htonl((u_int32)current_time); ss->timereset = htonl((u_int32)(current_time - sys_stattime)); ss->denied = htonl((u_int32)sys_restricted); - ss->oldversionpkt = htonl((u_int32)sys_oldversionpkt); - ss->newversionpkt = htonl((u_int32)sys_newversionpkt); - ss->unknownversion = htonl((u_int32)sys_unknownversion); + ss->oldversionpkt = htonl((u_int32)sys_oldversion); + ss->newversionpkt = htonl((u_int32)sys_newversion); + ss->unknownversion = htonl((u_int32)sys_declined); ss->badlength = htonl((u_int32)sys_badlength); ss->processed = htonl((u_int32)sys_processed); ss->badauth = htonl((u_int32)sys_badauth); @@ -1169,25 +1175,14 @@ sys_stats( */ static void mem_stats( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { register struct info_mem_stats *ms; register int i; - /* - * Importations from the peer module - */ - extern int peer_hash_count[NTP_HASH_SIZE]; - extern int peer_free_count; - extern u_long peer_timereset; - extern u_long findpeer_calls; - extern u_long peer_allocations; - extern u_long peer_demobilizations; - extern int total_peer_structs; - ms = (struct info_mem_stats *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_mem_stats)); @@ -1198,14 +1193,11 @@ mem_stats( ms->allocations = htonl((u_int32)peer_allocations); ms->demobilizations = htonl((u_int32)peer_demobilizations); - for (i = 0; i < NTP_HASH_SIZE; i++) { - if (peer_hash_count[i] > 255) - ms->hashcount[i] = 255; - else - ms->hashcount[i] = (u_char)peer_hash_count[i]; - } + for (i = 0; i < NTP_HASH_SIZE; i++) + ms->hashcount[i] = (u_char) + max((u_int)peer_hash_count[i], UCHAR_MAX); - (void) more_pkt(); + more_pkt(); flush_pkt(); } @@ -1215,18 +1207,13 @@ mem_stats( */ static void io_stats( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_io_stats *io; + struct info_io_stats *io; - /* - * Importations from the io module - */ - extern u_long io_timereset; - io = (struct info_io_stats *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_io_stats)); @@ -1253,26 +1240,21 @@ io_stats( */ static void timer_stats( - struct sockaddr_storage *srcadr, - struct interface *inter, - struct req_pkt *inpkt + sockaddr_u * srcadr, + endpt * inter, + struct req_pkt * inpkt ) { - register struct info_timer_stats *ts; + struct info_timer_stats * ts; + u_long sincereset; - /* - * Importations from the timer module - */ - extern u_long timer_timereset; - extern u_long timer_overflows; - extern u_long timer_xmtcalls; + ts = (struct info_timer_stats *)prepare_pkt(srcadr, inter, + inpkt, sizeof(*ts)); - ts = (struct info_timer_stats *)prepare_pkt(srcadr, inter, inpkt, - sizeof(struct info_timer_stats)); - - ts->timereset = htonl((u_int32)(current_time - timer_timereset)); - ts->alarms = htonl((u_int32)alarm_overflow); - ts->overflows = htonl((u_int32)timer_overflows); + sincereset = current_time - timer_timereset; + ts->timereset = htonl((u_int32)sincereset); + ts->alarms = ts->timereset; + ts->overflows = htonl((u_int32)alarm_overflow); ts->xmtcalls = htonl((u_int32)timer_xmtcalls); (void) more_pkt(); @@ -1285,22 +1267,14 @@ timer_stats( */ static void loop_info( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_loop *li; + struct info_loop *li; l_fp ltmp; - /* - * Importations from the loop filter module - */ - extern double last_offset; - extern double drift_comp; - extern int tc_counter; - extern u_long sys_clocktime; - li = (struct info_loop *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_loop)); @@ -1309,9 +1283,9 @@ loop_info( DTOLFP(drift_comp * 1e6, <mp); HTONL_FP(<mp, &li->drift_comp); li->compliance = htonl((u_int32)(tc_counter)); - li->watchdog_timer = htonl((u_int32)(current_time - sys_clocktime)); + li->watchdog_timer = htonl((u_int32)(current_time - sys_epoch)); - (void) more_pkt(); + more_pkt(); flush_pkt(); } @@ -1321,18 +1295,17 @@ loop_info( */ static void do_conf( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - static u_long soonest_ifrescan_time = 0; - int items; - u_int fl; - struct conf_peer *cp; - struct conf_peer temp_cp; - struct sockaddr_storage peeraddr; - struct sockaddr_in tmp_clock; + u_short items; + size_t item_sz; + u_int fl; + char * datap; + struct conf_peer temp_cp; + sockaddr_u peeraddr; /* * Do a check of everything to see that it looks @@ -1340,80 +1313,52 @@ do_conf( * very picky here. */ items = INFO_NITEMS(inpkt->err_nitems); - cp = (struct conf_peer *)inpkt->data; - memset(&temp_cp, 0, sizeof(struct conf_peer)); - memcpy(&temp_cp, (char *)cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); - fl = 0; - while (items-- > 0 && !fl) { - if (((temp_cp.version) > NTP_VERSION) - || ((temp_cp.version) < NTP_OLDVERSION)) - fl = 1; - if (temp_cp.hmode != MODE_ACTIVE - && temp_cp.hmode != MODE_CLIENT - && temp_cp.hmode != MODE_BROADCAST) - fl = 1; - if (temp_cp.flags & ~(CONF_FLAG_AUTHENABLE | CONF_FLAG_PREFER - | CONF_FLAG_BURST | CONF_FLAG_IBURST | CONF_FLAG_SKEY)) - fl = 1; - cp = (struct conf_peer *) - ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); - } - - if (fl) { + item_sz = INFO_ITEMSIZE(inpkt->mbz_itemsize); + datap = inpkt->u.data; + if (item_sz > sizeof(temp_cp)) { req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } - /* - * Looks okay, try it out - */ - items = INFO_NITEMS(inpkt->err_nitems); - cp = (struct conf_peer *)inpkt->data; - while (items-- > 0) { - memset(&temp_cp, 0, sizeof(struct conf_peer)); - memcpy(&temp_cp, (char *)cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); - memset((char *)&peeraddr, 0, sizeof(struct sockaddr_storage)); + ZERO(temp_cp); + memcpy(&temp_cp, datap, item_sz); + ZERO_SOCK(&peeraddr); fl = 0; - if (temp_cp.flags & CONF_FLAG_AUTHENABLE) - fl |= FLAG_AUTHENABLE; if (temp_cp.flags & CONF_FLAG_PREFER) fl |= FLAG_PREFER; if (temp_cp.flags & CONF_FLAG_BURST) - fl |= FLAG_BURST; + fl |= FLAG_BURST; if (temp_cp.flags & CONF_FLAG_IBURST) - fl |= FLAG_IBURST; + fl |= FLAG_IBURST; +#ifdef AUTOKEY if (temp_cp.flags & CONF_FLAG_SKEY) fl |= FLAG_SKEY; - - if (client_v6_capable && temp_cp.v6_flag != 0) { - peeraddr.ss_family = AF_INET6; - GET_INADDR6(peeraddr) = temp_cp.peeraddr6; +#endif /* AUTOKEY */ + if (client_v6_capable && temp_cp.v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = temp_cp.peeraddr6; } else { - peeraddr.ss_family = AF_INET; - GET_INADDR(peeraddr) = temp_cp.peeraddr; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = temp_cp.peeraddr; /* * Make sure the address is valid */ - tmp_clock = *CAST_V4(peeraddr); - if ( -#ifdef REFCLOCK - !ISREFCLOCKADR(&tmp_clock) && -#endif - ISBADADR(&tmp_clock)) { + if (!ISREFCLOCKADR(&peeraddr) && + ISBADADR(&peeraddr)) { req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } } NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif /* XXX W2DO? minpoll/maxpoll arguments ??? */ - if (peer_config(&peeraddr, (struct interface *)0, + if (peer_config(&peeraddr, NULL, NULL, temp_cp.hmode, temp_cp.version, temp_cp.minpoll, temp_cp.maxpoll, fl, temp_cp.ttl, temp_cp.keyid, NULL) == 0) { @@ -1421,142 +1366,30 @@ do_conf( return; } - /* - * ntp_intres.c uses REQ_CONFIG/doconf() to add each - * server after its name is resolved. If we have been - * disconnected from the network, it may notice the - * network has returned and add the first server while - * the relevant interface is still disabled, awaiting - * the next interface rescan. To get things moving - * more quickly, trigger an interface scan now, except - * if we have done so in the last half minute. - */ - if (soonest_ifrescan_time < current_time) { - soonest_ifrescan_time = current_time + 30; - timer_interfacetimeout(current_time); - DPRINTF(1, ("do_conf triggering interface rescan\n")); - } - - cp = (struct conf_peer *) - ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); + datap += item_sz; } - req_ack(srcadr, inter, inpkt, INFO_OKAY); } -#if 0 -/* XXX */ -/* - * dns_a - Snarf DNS info for an association ID - */ -static void -dns_a( - struct sockaddr_storage *srcadr, - struct interface *inter, - struct req_pkt *inpkt - ) -{ - register struct info_dns_assoc *dp; - register int items; - struct sockaddr_in peeraddr; - - /* - * Do a check of everything to see that it looks - * okay. If not, complain about it. Note we are - * very picky here. - */ - items = INFO_NITEMS(inpkt->err_nitems); - dp = (struct info_dns_assoc *)inpkt->data; - - /* - * Looks okay, try it out - */ - items = INFO_NITEMS(inpkt->err_nitems); - dp = (struct info_dns_assoc *)inpkt->data; - memset((char *)&peeraddr, 0, sizeof(struct sockaddr_in)); - peeraddr.sin_family = AF_INET; - peeraddr.sin_port = htons(NTP_PORT); - - /* - * Make sure the address is valid - */ - if ( -#ifdef REFCLOCK - !ISREFCLOCKADR(&peeraddr) && -#endif - ISBADADR(&peeraddr)) { -#ifdef REFCLOCK - msyslog(LOG_ERR, "dns_a: !ISREFCLOCK && ISBADADR"); -#else - msyslog(LOG_ERR, "dns_a: ISBADADR"); -#endif - req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); - return; - } - - while (items-- > 0) { - associd_t associd; - size_t hnl; - struct peer *peer; - int bogon = 0; - - associd = dp->associd; - peer = findpeerbyassoc(associd); - if (peer == 0 || peer->flags & FLAG_REFCLOCK) { - msyslog(LOG_ERR, "dns_a: %s", - (peer == 0) - ? "peer == 0" - : "peer->flags & FLAG_REFCLOCK"); - ++bogon; - } - peeraddr.sin_addr.s_addr = dp->peeraddr; - for (hnl = 0; dp->hostname[hnl] && hnl < sizeof dp->hostname; ++hnl) ; - if (hnl >= sizeof dp->hostname) { - msyslog(LOG_ERR, "dns_a: hnl (%ld) >= %ld", - (long)hnl, (long)sizeof dp->hostname); - ++bogon; - } - - msyslog(LOG_INFO, "dns_a: <%s> for %s, AssocID %d, bogon %d", - dp->hostname, - stoa((struct sockaddr_storage *)&peeraddr), associd, - bogon); - - if (bogon) { - /* If it didn't work */ - req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); - return; - } else { -#if 0 -#ifdef PUBKEY - crypto_public(peer, dp->hostname); -#endif /* PUBKEY */ -#endif - } - - dp++; - } - - req_ack(srcadr, inter, inpkt, INFO_OKAY); -} -#endif /* 0 */ /* * do_unconf - remove a peer from the configuration list */ static void do_unconf( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u * srcadr, + endpt * inter, struct req_pkt *inpkt ) { - register struct conf_unpeer *cp; - struct conf_unpeer temp_cp; - register int items; - register struct peer *peer; - struct sockaddr_storage peeraddr; - int bad, found; + u_short items; + size_t item_sz; + char * datap; + struct conf_unpeer temp_cp; + struct peer * p; + sockaddr_u peeraddr; + int bad; + int found; /* * This is a bit unstructured, but I like to be careful. @@ -1565,41 +1398,45 @@ do_unconf( * an error. */ items = INFO_NITEMS(inpkt->err_nitems); - cp = (struct conf_unpeer *)inpkt->data; + item_sz = INFO_ITEMSIZE(inpkt->mbz_itemsize); + datap = inpkt->u.data; + if (item_sz > sizeof(temp_cp)) { + req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); + return; + } - bad = 0; + bad = FALSE; while (items-- > 0 && !bad) { - memset(&temp_cp, 0, sizeof(temp_cp)); - memset(&peeraddr, 0, sizeof(peeraddr)); - memcpy(&temp_cp, cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); - if (client_v6_capable && temp_cp.v6_flag != 0) { - peeraddr.ss_family = AF_INET6; - GET_INADDR6(peeraddr) = temp_cp.peeraddr6; + ZERO(temp_cp); + memcpy(&temp_cp, datap, item_sz); + ZERO_SOCK(&peeraddr); + if (client_v6_capable && temp_cp.v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = temp_cp.peeraddr6; } else { - peeraddr.ss_family = AF_INET; - GET_INADDR(peeraddr) = temp_cp.peeraddr; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = temp_cp.peeraddr; } - NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); -#endif - found = 0; - peer = (struct peer *)0; -#ifdef DEBUG - if (debug) - printf("searching for %s\n", stoa(&peeraddr)); + SET_PORT(&peeraddr, NTP_PORT); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif + found = FALSE; + p = NULL; + + DPRINTF(1, ("searching for %s\n", stoa(&peeraddr))); + while (!found) { - peer = findexistingpeer(&peeraddr, peer, -1); - if (peer == (struct peer *)0) - break; - if (peer->flags & FLAG_CONFIG) - found = 1; + p = findexistingpeer(&peeraddr, NULL, p, -1, 0); + if (NULL == p) + break; + if (FLAG_CONFIG & p->flags) + found = TRUE; } if (!found) - bad = 1; - cp = (struct conf_unpeer *) - ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); + bad = TRUE; + + datap += item_sz; } if (bad) { @@ -1612,25 +1449,40 @@ do_unconf( */ items = INFO_NITEMS(inpkt->err_nitems); - cp = (struct conf_unpeer *)inpkt->data; + datap = inpkt->u.data; + while (items-- > 0) { - memset(&temp_cp, 0, sizeof(temp_cp)); - memset(&peeraddr, 0, sizeof(peeraddr)); - memcpy(&temp_cp, cp, INFO_ITEMSIZE(inpkt->mbz_itemsize)); - if (client_v6_capable && temp_cp.v6_flag != 0) { - peeraddr.ss_family = AF_INET6; - GET_INADDR6(peeraddr) = temp_cp.peeraddr6; + ZERO(temp_cp); + memcpy(&temp_cp, datap, item_sz); + ZERO(peeraddr); + if (client_v6_capable && temp_cp.v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = temp_cp.peeraddr6; } else { - peeraddr.ss_family = AF_INET; - GET_INADDR(peeraddr) = temp_cp.peeraddr; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = temp_cp.peeraddr; } - NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); + SET_PORT(&peeraddr, NTP_PORT); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif - peer_unconfig(&peeraddr, (struct interface *)0, -1); - cp = (struct conf_unpeer *) - ((char *)cp + INFO_ITEMSIZE(inpkt->mbz_itemsize)); + found = FALSE; + p = NULL; + + while (!found) { + p = findexistingpeer(&peeraddr, NULL, p, -1, 0); + if (NULL == p) + break; + if (FLAG_CONFIG & p->flags) + found = TRUE; + } + INSIST(found); + INSIST(NULL != p); + + peer_clear(p, "GONE"); + unpeer(p); + + datap += item_sz; } req_ack(srcadr, inter, inpkt, INFO_OKAY); @@ -1642,8 +1494,8 @@ do_unconf( */ static void set_sys_flag( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -1656,8 +1508,8 @@ set_sys_flag( */ static void clr_sys_flag( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -1670,24 +1522,23 @@ clr_sys_flag( */ static void setclr_flags( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt, u_long set ) { - register u_int flags; - int prev_kern_enable; + struct conf_sys_flags *sf; + u_int32 flags; - prev_kern_enable = kern_enable; if (INFO_NITEMS(inpkt->err_nitems) > 1) { msyslog(LOG_ERR, "setclr_flags: err_nitems > 1"); req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } - flags = ((struct conf_sys_flags *)inpkt->data)->flags; - flags = ntohl(flags); + sf = (struct conf_sys_flags *)&inpkt->u; + flags = ntohl(sf->flags); if (flags & ~(SYS_FLAG_BCLIENT | SYS_FLAG_PPS | SYS_FLAG_NTP | SYS_FLAG_KERNEL | SYS_FLAG_MONITOR | @@ -1718,12 +1569,58 @@ setclr_flags( if (flags & SYS_FLAG_CAL) proto_config(PROTO_CAL, set, 0., NULL); req_ack(srcadr, inter, inpkt, INFO_OKAY); +} - /* Reset the kernel ntp parameters if the kernel flag changed. */ - if (prev_kern_enable && !kern_enable) - loop_config(LOOP_KERN_CLEAR, 0.0); - if (!prev_kern_enable && kern_enable) - loop_config(LOOP_DRIFTCOMP, drift_comp); +/* + * list_restrict4 - recursive helper for list_restrict dumps IPv4 + * restriction list in reverse order. + */ +static void +list_restrict4( + restrict_u * res, + struct info_restrict ** ppir + ) +{ + struct info_restrict * pir; + + if (res->link != NULL) + list_restrict4(res->link, ppir); + + pir = *ppir; + pir->addr = htonl(res->u.v4.addr); + if (client_v6_capable) + pir->v6_flag = 0; + pir->mask = htonl(res->u.v4.mask); + pir->count = htonl(res->count); + pir->flags = htons(res->flags); + pir->mflags = htons(res->mflags); + *ppir = (struct info_restrict *)more_pkt(); +} + + +/* + * list_restrict6 - recursive helper for list_restrict dumps IPv6 + * restriction list in reverse order. + */ +static void +list_restrict6( + restrict_u * res, + struct info_restrict ** ppir + ) +{ + struct info_restrict * pir; + + if (res->link != NULL) + list_restrict6(res->link, ppir); + + pir = *ppir; + pir->addr6 = res->u.v6.addr; + pir->mask6 = res->u.v6.mask; + pir->v6_flag = 1; + pir->count = htonl(res->count); + pir->flags = htons(res->flags); + pir->mflags = htons(res->mflags); + *ppir = (struct info_restrict *)more_pkt(); } @@ -1732,55 +1629,38 @@ setclr_flags( */ static void list_restrict( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_restrict *ir; - register struct restrictlist *rl; - register struct restrictlist6 *rl6; + struct info_restrict *ir; -#ifdef DEBUG - if (debug > 2) - printf("wants restrict list summary\n"); -#endif + DPRINTF(3, ("wants restrict list summary\n")); ir = (struct info_restrict *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_restrict)); - for (rl = restrictlist; rl != 0 && ir != 0; rl = rl->next) { - ir->addr = htonl(rl->addr); - if (client_v6_capable) - ir->v6_flag = 0; - ir->mask = htonl(rl->mask); - ir->count = htonl((u_int32)rl->count); - ir->flags = htons(rl->flags); - ir->mflags = htons(rl->mflags); - ir = (struct info_restrict *)more_pkt(); - } + /* + * The restriction lists are kept sorted in the reverse order + * than they were originally. To preserve the output semantics, + * dump each list in reverse order. A recursive helper function + * achieves that. + */ + list_restrict4(restrictlist4, &ir); if (client_v6_capable) - for (rl6 = restrictlist6; rl6 != 0 && ir != 0; rl6 = rl6->next) { - ir->addr6 = rl6->addr6; - ir->mask6 = rl6->mask6; - ir->v6_flag = 1; - ir->count = htonl((u_int32)rl6->count); - ir->flags = htons(rl6->flags); - ir->mflags = htons(rl6->mflags); - ir = (struct info_restrict *)more_pkt(); - } + list_restrict6(restrictlist6, &ir); flush_pkt(); } - /* * do_resaddflags - add flags to a restrict entry (or create one) */ static void do_resaddflags( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -1794,8 +1674,8 @@ do_resaddflags( */ static void do_ressubflags( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -1808,8 +1688,8 @@ do_ressubflags( */ static void do_unrestrict( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -1817,25 +1697,24 @@ do_unrestrict( } - - - /* * do_restrict - do the dirty stuff of dealing with restrictions */ static void do_restrict( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt, int op ) { - register struct conf_restrict *cr; - register int items; - struct sockaddr_storage matchaddr; - struct sockaddr_storage matchmask; - int bad; + char * datap; + struct conf_restrict cr; + u_short items; + size_t item_sz; + sockaddr_u matchaddr; + sockaddr_u matchmask; + int bad; /* * Do a check of the flags to make sure that only @@ -1843,26 +1722,32 @@ do_restrict( * about it. Note we are very picky here. */ items = INFO_NITEMS(inpkt->err_nitems); - cr = (struct conf_restrict *)inpkt->data; + item_sz = INFO_ITEMSIZE(inpkt->mbz_itemsize); + datap = inpkt->u.data; + if (item_sz > sizeof(cr)) { + req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); + return; + } - bad = 0; - cr->flags = ntohs(cr->flags); - cr->mflags = ntohs(cr->mflags); + bad = FALSE; while (items-- > 0 && !bad) { - if (cr->mflags & ~(RESM_NTPONLY)) - bad |= 1; - if (cr->flags & ~(RES_ALLFLAGS)) - bad |= 2; - if (cr->mask != htonl(INADDR_ANY)) { - if (client_v6_capable && cr->v6_flag != 0) { - if (IN6_IS_ADDR_UNSPECIFIED(&cr->addr6)) + memcpy(&cr, datap, item_sz); + cr.flags = ntohs(cr.flags); + cr.mflags = ntohs(cr.mflags); + if (~RESM_NTPONLY & cr.mflags) + bad |= 1; + if (~RES_ALLFLAGS & cr.flags) + bad |= 2; + if (INADDR_ANY != cr.mask) { + if (client_v6_capable && cr.v6_flag) { + if (IN6_IS_ADDR_UNSPECIFIED(&cr.addr6)) bad |= 4; - } else - if (cr->addr == htonl(INADDR_ANY)) + } else { + if (INADDR_ANY == cr.addr) bad |= 8; + } } - cr = (struct conf_restrict *)((char *)cr + - INFO_ITEMSIZE(inpkt->mbz_itemsize)); + datap += item_sz; } if (bad) { @@ -1872,28 +1757,32 @@ do_restrict( } /* - * Looks okay, try it out + * Looks okay, try it out. Needs to reload data pointer and + * item counter. (Talos-CAN-0052) */ + ZERO_SOCK(&matchaddr); + ZERO_SOCK(&matchmask); items = INFO_NITEMS(inpkt->err_nitems); - cr = (struct conf_restrict *)inpkt->data; - memset((char *)&matchaddr, 0, sizeof(struct sockaddr_storage)); - memset((char *)&matchmask, 0, sizeof(struct sockaddr_storage)); + datap = inpkt->u.data; while (items-- > 0) { - if (client_v6_capable && cr->v6_flag != 0) { - GET_INADDR6(matchaddr) = cr->addr6; - GET_INADDR6(matchmask) = cr->mask6; - matchaddr.ss_family = AF_INET6; - matchmask.ss_family = AF_INET6; + memcpy(&cr, datap, item_sz); + cr.flags = ntohs(cr.flags); + cr.mflags = ntohs(cr.mflags); + if (client_v6_capable && cr.v6_flag) { + AF(&matchaddr) = AF_INET6; + AF(&matchmask) = AF_INET6; + SOCK_ADDR6(&matchaddr) = cr.addr6; + SOCK_ADDR6(&matchmask) = cr.mask6; } else { - GET_INADDR(matchaddr) = cr->addr; - GET_INADDR(matchmask) = cr->mask; - matchaddr.ss_family = AF_INET; - matchmask.ss_family = AF_INET; + AF(&matchaddr) = AF_INET; + AF(&matchmask) = AF_INET; + NSRCADR(&matchaddr) = cr.addr; + NSRCADR(&matchmask) = cr.mask; } - hack_restrict(op, &matchaddr, &matchmask, cr->mflags, - cr->flags); - cr++; + hack_restrict(op, &matchaddr, &matchmask, cr.mflags, + cr.flags, 0); + datap += item_sz; } req_ack(srcadr, inter, inpkt, INFO_OKAY); @@ -1904,109 +1793,22 @@ do_restrict( * mon_getlist - return monitor data */ static void -mon_getlist_0( - struct sockaddr_storage *srcadr, - struct interface *inter, +mon_getlist( + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_monitor *im; - register struct mon_data *md; - extern struct mon_data mon_mru_list; - extern int mon_enabled; - -#ifdef DEBUG - if (debug > 2) - printf("wants monitor 0 list\n"); -#endif - if (!mon_enabled) { - return; - } - im = (struct info_monitor *)prepare_pkt(srcadr, inter, inpkt, - v6sizeof(struct info_monitor)); - for (md = mon_mru_list.mru_next; md != &mon_mru_list && im != 0; - md = md->mru_next) { - im->lasttime = htonl((u_int32)md->avg_interval); - im->firsttime = htonl((u_int32)(current_time - md->lasttime)); - im->lastdrop = htonl((u_int32)md->drop_count); - im->count = htonl((u_int32)(md->count)); - if (md->rmtadr.ss_family == AF_INET6) { - if (!client_v6_capable) - continue; - im->addr6 = GET_INADDR6(md->rmtadr); - im->v6_flag = 1; - } else { - im->addr = GET_INADDR(md->rmtadr); - if (client_v6_capable) - im->v6_flag = 0; - } - im->port = md->rmtport; - im->mode = md->mode; - im->version = md->version; - im = (struct info_monitor *)more_pkt(); - } - flush_pkt(); + req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); } -/* - * mon_getlist - return monitor data - */ -static void -mon_getlist_1( - struct sockaddr_storage *srcadr, - struct interface *inter, - struct req_pkt *inpkt - ) -{ - register struct info_monitor_1 *im; - register struct mon_data *md; - extern struct mon_data mon_mru_list; - extern int mon_enabled; - - if (!mon_enabled) { - return; - } - im = (struct info_monitor_1 *)prepare_pkt(srcadr, inter, inpkt, - v6sizeof(struct info_monitor_1)); - for (md = mon_mru_list.mru_next; md != &mon_mru_list && im != 0; - md = md->mru_next) { - im->lasttime = htonl((u_int32)md->avg_interval); - im->firsttime = htonl((u_int32)(current_time - md->lasttime)); - im->lastdrop = htonl((u_int32)md->drop_count); - im->count = htonl((u_int32)md->count); - if (md->rmtadr.ss_family == AF_INET6) { - if (!client_v6_capable) - continue; - im->addr6 = GET_INADDR6(md->rmtadr); - im->v6_flag = 1; - im->daddr6 = GET_INADDR6(md->interface->sin); - } else { - im->addr = GET_INADDR(md->rmtadr); - if (client_v6_capable) - im->v6_flag = 0; - im->daddr = (md->cast_flags == MDF_BCAST) - ? GET_INADDR(md->interface->bcast) - : (md->cast_flags - ? (GET_INADDR(md->interface->sin) - ? GET_INADDR(md->interface->sin) - : GET_INADDR(md->interface->bcast)) - : 4); - } - im->flags = htonl(md->cast_flags); - im->port = md->rmtport; - im->mode = md->mode; - im->version = md->version; - im = (struct info_monitor_1 *)more_pkt(); - } - flush_pkt(); -} /* * Module entry points and the flags they correspond with */ struct reset_entry { int flag; /* flag this corresponds to */ - void (*handler) P((void)); /* routine to handle request */ + void (*handler)(void); /* routine to handle request */ }; struct reset_entry reset_entries[] = { @@ -2025,11 +1827,12 @@ struct reset_entry reset_entries[] = { */ static void reset_stats( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { + struct reset_flags *rflags; u_long flags; struct reset_entry *rent; @@ -2039,9 +1842,9 @@ reset_stats( return; } - flags = ((struct reset_flags *)inpkt->data)->flags; - flags = ntohl(flags); - + rflags = (struct reset_flags *)&inpkt->u; + flags = ntohl(rflags->flags); + if (flags & ~RESET_ALLFLAGS) { msyslog(LOG_ERR, "reset_stats: reset leaves %#lx", flags & ~RESET_ALLFLAGS); @@ -2051,7 +1854,7 @@ reset_stats( for (rent = reset_entries; rent->flag != 0; rent++) { if (flags & rent->flag) - (rent->handler)(); + (*rent->handler)(); } req_ack(srcadr, inter, inpkt, INFO_OKAY); } @@ -2062,16 +1865,18 @@ reset_stats( */ static void reset_peer( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct conf_unpeer *cp; - register int items; - register struct peer *peer; - struct sockaddr_storage peeraddr; - int bad; + u_short items; + size_t item_sz; + char * datap; + struct conf_unpeer cp; + struct peer * p; + sockaddr_u peeraddr; + int bad; /* * We check first to see that every peer exists. If not, @@ -2079,27 +1884,33 @@ reset_peer( */ items = INFO_NITEMS(inpkt->err_nitems); - cp = (struct conf_unpeer *)inpkt->data; + item_sz = INFO_ITEMSIZE(inpkt->mbz_itemsize); + datap = inpkt->u.data; + if (item_sz > sizeof(cp)) { + req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); + return; + } - bad = 0; + bad = FALSE; while (items-- > 0 && !bad) { - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (client_v6_capable && cp->v6_flag != 0) { - GET_INADDR6(peeraddr) = cp->peeraddr6; - peeraddr.ss_family = AF_INET6; + ZERO(cp); + memcpy(&cp, datap, item_sz); + ZERO_SOCK(&peeraddr); + if (client_v6_capable && cp.v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = cp.peeraddr6; } else { - GET_INADDR(peeraddr) = cp->peeraddr; - peeraddr.ss_family = AF_INET; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = cp.peeraddr; } - NSRCPORT(&peeraddr) = htons(NTP_PORT); -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); + +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif - peer = findexistingpeer(&peeraddr, (struct peer *)0, -1); - if (peer == (struct peer *)0) - bad++; - cp = (struct conf_unpeer *)((char *)cp + - INFO_ITEMSIZE(inpkt->mbz_itemsize)); + p = findexistingpeer(&peeraddr, NULL, NULL, -1, 0); + if (NULL == p) + bad++; + datap += item_sz; } if (bad) { @@ -2108,30 +1919,33 @@ reset_peer( } /* - * Now do it in earnest. + * Now do it in earnest. Needs to reload data pointer and item + * counter. (Talos-CAN-0052) */ - + items = INFO_NITEMS(inpkt->err_nitems); - cp = (struct conf_unpeer *)inpkt->data; + datap = inpkt->u.data; while (items-- > 0) { - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (client_v6_capable && cp->v6_flag != 0) { - GET_INADDR6(peeraddr) = cp->peeraddr6; - peeraddr.ss_family = AF_INET6; + ZERO(cp); + memcpy(&cp, datap, item_sz); + ZERO_SOCK(&peeraddr); + if (client_v6_capable && cp.v6_flag) { + AF(&peeraddr) = AF_INET6; + SOCK_ADDR6(&peeraddr) = cp.peeraddr6; } else { - GET_INADDR(peeraddr) = cp->peeraddr; - peeraddr.ss_family = AF_INET; + AF(&peeraddr) = AF_INET; + NSRCADR(&peeraddr) = cp.peeraddr; } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); + SET_PORT(&peeraddr, 123); +#ifdef ISC_PLATFORM_HAVESALEN + peeraddr.sa.sa_len = SOCKLEN(&peeraddr); #endif - peer = findexistingpeer(&peeraddr, (struct peer *)0, -1); - while (peer != 0) { - peer_reset(peer); - peer = findexistingpeer(&peeraddr, (struct peer *)peer, -1); + p = findexistingpeer(&peeraddr, NULL, NULL, -1, 0); + while (p != NULL) { + peer_reset(p); + p = findexistingpeer(&peeraddr, NULL, p, -1, 0); } - cp = (struct conf_unpeer *)((char *)cp + - INFO_ITEMSIZE(inpkt->mbz_itemsize)); + datap += item_sz; } req_ack(srcadr, inter, inpkt, INFO_OKAY); @@ -2143,8 +1957,8 @@ reset_peer( */ static void do_key_reread( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2158,8 +1972,8 @@ do_key_reread( */ static void trust_key( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2172,8 +1986,8 @@ trust_key( */ static void untrust_key( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2186,8 +2000,8 @@ untrust_key( */ static void do_trustkey( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt, u_long trust ) @@ -2196,7 +2010,7 @@ do_trustkey( register int items; items = INFO_NITEMS(inpkt->err_nitems); - kp = (u_long *)inpkt->data; + kp = (u_long *)&inpkt->u; while (items-- > 0) { authtrust(*kp, trust); kp++; @@ -2211,25 +2025,13 @@ do_trustkey( */ static void get_auth_info( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { register struct info_auth *ia; - /* - * Importations from the authentication module - */ - extern u_long authnumkeys; - extern int authnumfreekeys; - extern u_long authkeylookups; - extern u_long authkeynotfound; - extern u_long authencryptions; - extern u_long authdecryptions; - extern u_long authkeyuncached; - extern u_long authkeyexpired; - ia = (struct info_auth *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_auth)); @@ -2253,18 +2055,9 @@ get_auth_info( * reset_auth_stats - reset the authentication stat counters. Done here * to keep ntp-isms out of the authentication module */ -static void +void reset_auth_stats(void) { - /* - * Importations from the authentication module - */ - extern u_long authkeylookups; - extern u_long authkeynotfound; - extern u_long authencryptions; - extern u_long authdecryptions; - extern u_long authkeyuncached; - authkeylookups = 0; authkeynotfound = 0; authencryptions = 0; @@ -2279,20 +2072,14 @@ reset_auth_stats(void) */ static void req_get_traps( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - register struct info_trap *it; - register struct ctl_trap *tr; - register int i; - - /* - * Imported from the control module - */ - extern struct ctl_trap ctl_trap[]; - extern int num_ctl_traps; + struct info_trap *it; + struct ctl_trap *tr; + size_t i; if (num_ctl_traps == 0) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); @@ -2302,23 +2089,23 @@ req_get_traps( it = (struct info_trap *)prepare_pkt(srcadr, inter, inpkt, v6sizeof(struct info_trap)); - for (i = 0, tr = ctl_trap; i < CTL_MAXTRAPS; i++, tr++) { + for (i = 0, tr = ctl_traps; i < COUNTOF(ctl_traps); i++, tr++) { if (tr->tr_flags & TRAP_INUSE) { - if (tr->tr_addr.ss_family == AF_INET) { + if (IS_IPV4(&tr->tr_addr)) { if (tr->tr_localaddr == any_interface) it->local_address = 0; else it->local_address - = GET_INADDR(tr->tr_localaddr->sin); - it->trap_address = GET_INADDR(tr->tr_addr); + = NSRCADR(&tr->tr_localaddr->sin); + it->trap_address = NSRCADR(&tr->tr_addr); if (client_v6_capable) it->v6_flag = 0; } else { if (!client_v6_capable) continue; it->local_address6 - = GET_INADDR6(tr->tr_localaddr->sin); - it->trap_address6 = GET_INADDR6(tr->tr_addr); + = SOCK_ADDR6(&tr->tr_localaddr->sin); + it->trap_address6 = SOCK_ADDR6(&tr->tr_addr); it->v6_flag = 1; } it->trap_port = NSRCPORT(&tr->tr_addr); @@ -2339,8 +2126,8 @@ req_get_traps( */ static void req_set_trap( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2354,8 +2141,8 @@ req_set_trap( */ static void req_clr_trap( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2369,23 +2156,23 @@ req_clr_trap( */ static void do_setclr_trap( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt, int set ) { register struct conf_trap *ct; - register struct interface *linter; + register endpt *linter; int res; - struct sockaddr_storage laddr; + sockaddr_u laddr; /* - * Prepare sockaddr_storage structure + * Prepare sockaddr */ - memset((char *)&laddr, 0, sizeof laddr); - laddr.ss_family = srcadr->ss_family; - NSRCPORT(&laddr) = ntohs(NTP_PORT); + ZERO_SOCK(&laddr); + AF(&laddr) = AF(srcadr); + SET_PORT(&laddr, NTP_PORT); /* * Restrict ourselves to one item only. This eliminates @@ -2396,7 +2183,7 @@ do_setclr_trap( req_ack(srcadr, inter, inpkt, INFO_ERR_FMT); return; } - ct = (struct conf_trap *)inpkt->data; + ct = (struct conf_trap *)&inpkt->u; /* * Look for the local interface. If none, use the default. @@ -2404,25 +2191,25 @@ do_setclr_trap( if (ct->local_address == 0) { linter = any_interface; } else { - if (laddr.ss_family == AF_INET) - GET_INADDR(laddr) = ct->local_address; + if (IS_IPV4(&laddr)) + NSRCADR(&laddr) = ct->local_address; else - GET_INADDR6(laddr) = ct->local_address6; + SOCK_ADDR6(&laddr) = ct->local_address6; linter = findinterface(&laddr); - if (linter == NULL) { + if (NULL == linter) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } } - if (laddr.ss_family == AF_INET) - GET_INADDR(laddr) = ct->trap_address; + if (IS_IPV4(&laddr)) + NSRCADR(&laddr) = ct->trap_address; else - GET_INADDR6(laddr) = ct->trap_address6; - if (ct->trap_port != 0) - NSRCPORT(&laddr) = ct->trap_port; + SOCK_ADDR6(&laddr) = ct->trap_address6; + if (ct->trap_port) + NSRCPORT(&laddr) = ct->trap_port; else - NSRCPORT(&laddr) = htons(TRAPPORT); + SET_PORT(&laddr, TRAPPORT); if (set) { res = ctlsettrap(&laddr, linter, 0, @@ -2446,12 +2233,12 @@ do_setclr_trap( */ static void set_request_keyid( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - keyid_t keyid; + keyid_t *pkeyid; /* * Restrict ourselves to one item only. @@ -2462,8 +2249,8 @@ set_request_keyid( return; } - keyid = ntohl(*((u_int32 *)(inpkt->data))); - info_auth_keyid = keyid; + pkeyid = (keyid_t *)&inpkt->u; + info_auth_keyid = ntohl(*pkeyid); req_ack(srcadr, inter, inpkt, INFO_OKAY); } @@ -2474,13 +2261,12 @@ set_request_keyid( */ static void set_control_keyid( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { - keyid_t keyid; - extern keyid_t ctl_auth_keyid; + keyid_t *pkeyid; /* * Restrict ourselves to one item only. @@ -2491,8 +2277,8 @@ set_control_keyid( return; } - keyid = ntohl(*((u_int32 *)(inpkt->data))); - ctl_auth_keyid = keyid; + pkeyid = (keyid_t *)&inpkt->u; + ctl_auth_keyid = ntohl(*pkeyid); req_ack(srcadr, inter, inpkt, INFO_OKAY); } @@ -2503,32 +2289,13 @@ set_control_keyid( */ static void get_ctl_stats( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { register struct info_control *ic; - /* - * Importations from the control module - */ - extern u_long ctltimereset; - extern u_long numctlreq; - extern u_long numctlbadpkts; - extern u_long numctlresponses; - extern u_long numctlfrags; - extern u_long numctlerrors; - extern u_long numctltooshort; - extern u_long numctlinputresp; - extern u_long numctlinputfrag; - extern u_long numctlinputerr; - extern u_long numctlbadoffset; - extern u_long numctlbadversion; - extern u_long numctldatatooshort; - extern u_long numctlbadop; - extern u_long numasyncmsgs; - ic = (struct info_control *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_control)); @@ -2559,8 +2326,8 @@ get_ctl_stats( */ static void get_kernel_info( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2572,7 +2339,7 @@ get_kernel_info( return; } - memset((char *)&ntx, 0, sizeof(ntx)); + ZERO(ntx); if (ntp_adjtime(&ntx) < 0) msyslog(LOG_ERR, "get_kernel_info: ntp_adjtime() failed: %m"); ik = (struct info_kernel *)prepare_pkt(srcadr, inter, inpkt, @@ -2614,8 +2381,8 @@ get_kernel_info( */ static void get_clock_info( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2623,36 +2390,34 @@ get_clock_info( register u_int32 *clkaddr; register int items; struct refclockstat clock_stat; - struct sockaddr_storage addr; - struct sockaddr_in tmp_clock; + sockaddr_u addr; l_fp ltmp; - memset((char *)&addr, 0, sizeof addr); - addr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); + ZERO_SOCK(&addr); + AF(&addr) = AF_INET; +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif - NSRCPORT(&addr) = htons(NTP_PORT); + SET_PORT(&addr, NTP_PORT); items = INFO_NITEMS(inpkt->err_nitems); - clkaddr = (u_int32 *) inpkt->data; + clkaddr = &inpkt->u.u32[0]; ic = (struct info_clock *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_clock)); while (items-- > 0) { - tmp_clock.sin_addr.s_addr = *clkaddr++; - CAST_V4(addr)->sin_addr = tmp_clock.sin_addr; - if (!ISREFCLOCKADR(&tmp_clock) || - findexistingpeer(&addr, (struct peer *)0, -1) == 0) { + NSRCADR(&addr) = *clkaddr++; + if (!ISREFCLOCKADR(&addr) || NULL == + findexistingpeer(&addr, NULL, NULL, -1, 0)) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } clock_stat.kv_list = (struct ctl_var *)0; - refclock_control(&addr, (struct refclockstat *)0, &clock_stat); + refclock_control(&addr, NULL, &clock_stat); - ic->clockadr = tmp_clock.sin_addr.s_addr; + ic->clockadr = NSRCADR(&addr); ic->type = clock_stat.type; ic->flags = clock_stat.flags; ic->lastevent = clock_stat.lastevent; @@ -2667,7 +2432,7 @@ get_clock_info( DTOLFP(clock_stat.fudgetime2, <mp); HTONL_FP(<mp, &ic->fudgetime2); ic->fudgeval1 = htonl((u_int32)clock_stat.fudgeval1); - ic->fudgeval2 = htonl((u_int32)clock_stat.fudgeval2); + ic->fudgeval2 = htonl(clock_stat.fudgeval2); free_varlist(clock_stat.kv_list); @@ -2683,33 +2448,31 @@ get_clock_info( */ static void set_clock_fudge( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { register struct conf_fudge *cf; register int items; struct refclockstat clock_stat; - struct sockaddr_storage addr; - struct sockaddr_in tmp_clock; + sockaddr_u addr; l_fp ltmp; - memset((char *)&addr, 0, sizeof addr); - memset((char *)&clock_stat, 0, sizeof clock_stat); + ZERO(addr); + ZERO(clock_stat); items = INFO_NITEMS(inpkt->err_nitems); - cf = (struct conf_fudge *) inpkt->data; + cf = (struct conf_fudge *)&inpkt->u; while (items-- > 0) { - tmp_clock.sin_addr.s_addr = cf->clockadr; - *CAST_V4(addr) = tmp_clock; - addr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); + AF(&addr) = AF_INET; + NSRCADR(&addr) = cf->clockadr; +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif - NSRCPORT(&addr) = htons(NTP_PORT); - if (!ISREFCLOCKADR(&tmp_clock) || - findexistingpeer(&addr, (struct peer *)0, -1) == 0) { + SET_PORT(&addr, NTP_PORT); + if (!ISREFCLOCKADR(&addr) || NULL == + findexistingpeer(&addr, NULL, NULL, -1, 0)) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } @@ -2757,8 +2520,8 @@ set_clock_fudge( */ static void get_clkbug_info( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2767,38 +2530,36 @@ get_clkbug_info( register u_int32 *clkaddr; register int items; struct refclockbug bug; - struct sockaddr_storage addr; - struct sockaddr_in tmp_clock; + sockaddr_u addr; - memset((char *)&addr, 0, sizeof addr); - addr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); + ZERO_SOCK(&addr); + AF(&addr) = AF_INET; +#ifdef ISC_PLATFORM_HAVESALEN + addr.sa.sa_len = SOCKLEN(&addr); #endif - NSRCPORT(&addr) = htons(NTP_PORT); + SET_PORT(&addr, NTP_PORT); items = INFO_NITEMS(inpkt->err_nitems); - clkaddr = (u_int32 *) inpkt->data; + clkaddr = (u_int32 *)&inpkt->u; ic = (struct info_clkbug *)prepare_pkt(srcadr, inter, inpkt, sizeof(struct info_clkbug)); while (items-- > 0) { - tmp_clock.sin_addr.s_addr = *clkaddr++; - GET_INADDR(addr) = tmp_clock.sin_addr.s_addr; - if (!ISREFCLOCKADR(&tmp_clock) || - findexistingpeer(&addr, (struct peer *)0, -1) == 0) { + NSRCADR(&addr) = *clkaddr++; + if (!ISREFCLOCKADR(&addr) || NULL == + findexistingpeer(&addr, NULL, NULL, -1, 0)) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } - memset((char *)&bug, 0, sizeof bug); + ZERO(bug); refclock_buginfo(&addr, &bug); if (bug.nvalues == 0 && bug.ntimes == 0) { req_ack(srcadr, inter, inpkt, INFO_ERR_NODATA); return; } - ic->clockadr = tmp_clock.sin_addr.s_addr; + ic->clockadr = NSRCADR(&addr); i = bug.nvalues; if (i > NUMCBUGVALUES) i = NUMCBUGVALUES; @@ -2830,39 +2591,40 @@ fill_info_if_stats(void *data, interface_info_t *interface_info) { struct info_if_stats **ifsp = (struct info_if_stats **)data; struct info_if_stats *ifs = *ifsp; - struct interface *interface = interface_info->interface; + endpt *ep = interface_info->ep; - memset((char*)ifs, 0, sizeof(*ifs)); + ZERO(*ifs); - if (interface->sin.ss_family == AF_INET6) { + if (IS_IPV6(&ep->sin)) { if (!client_v6_capable) { return; } ifs->v6_flag = 1; - memcpy((char *)&ifs->unaddr.addr6, (char *)&CAST_V6(interface->sin)->sin6_addr, sizeof(struct in6_addr)); - memcpy((char *)&ifs->unbcast.addr6, (char *)&CAST_V6(interface->bcast)->sin6_addr, sizeof(struct in6_addr)); - memcpy((char *)&ifs->unmask.addr6, (char *)&CAST_V6(interface->mask)->sin6_addr, sizeof(struct in6_addr)); + ifs->unaddr.addr6 = SOCK_ADDR6(&ep->sin); + ifs->unbcast.addr6 = SOCK_ADDR6(&ep->bcast); + ifs->unmask.addr6 = SOCK_ADDR6(&ep->mask); } else { ifs->v6_flag = 0; - memcpy((char *)&ifs->unaddr.addr, (char *)&CAST_V4(interface->sin)->sin_addr, sizeof(struct in_addr)); - memcpy((char *)&ifs->unbcast.addr, (char *)&CAST_V4(interface->bcast)->sin_addr, sizeof(struct in_addr)); - memcpy((char *)&ifs->unmask.addr, (char *)&CAST_V4(interface->mask)->sin_addr, sizeof(struct in_addr)); + ifs->unaddr.addr = SOCK_ADDR4(&ep->sin); + ifs->unbcast.addr = SOCK_ADDR4(&ep->bcast); + ifs->unmask.addr = SOCK_ADDR4(&ep->mask); } ifs->v6_flag = htonl(ifs->v6_flag); - strcpy(ifs->name, interface->name); - ifs->family = htons(interface->family); - ifs->flags = htonl(interface->flags); - ifs->last_ttl = htonl(interface->last_ttl); - ifs->num_mcast = htonl(interface->num_mcast); - ifs->received = htonl(interface->received); - ifs->sent = htonl(interface->sent); - ifs->notsent = htonl(interface->notsent); - ifs->scopeid = htonl(interface->scopeid); - ifs->ifindex = htonl(interface->ifindex); - ifs->ifnum = htonl(interface->ifnum); - ifs->uptime = htonl(current_time - interface->starttime); - ifs->ignore_packets = interface->ignore_packets; - ifs->peercnt = htonl(interface->peercnt); + strlcpy(ifs->name, ep->name, sizeof(ifs->name)); + ifs->family = htons(ep->family); + ifs->flags = htonl(ep->flags); + ifs->last_ttl = htonl(ep->last_ttl); + ifs->num_mcast = htonl(ep->num_mcast); + ifs->received = htonl(ep->received); + ifs->sent = htonl(ep->sent); + ifs->notsent = htonl(ep->notsent); + ifs->ifindex = htonl(ep->ifindex); + /* scope no longer in endpt, in in6_addr typically */ + ifs->scopeid = ifs->ifindex; + ifs->ifnum = htonl(ep->ifnum); + ifs->uptime = htonl(current_time - ep->starttime); + ifs->ignore_packets = ep->ignore_packets; + ifs->peercnt = htonl(ep->peercnt); ifs->action = interface_info->action; *ifsp = (struct info_if_stats *)more_pkt(); @@ -2873,8 +2635,8 @@ fill_info_if_stats(void *data, interface_info_t *interface_info) */ static void get_if_stats( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { @@ -2892,8 +2654,8 @@ get_if_stats( static void do_if_reload( - struct sockaddr_storage *srcadr, - struct interface *inter, + sockaddr_u *srcadr, + endpt *inter, struct req_pkt *inpkt ) { diff --git a/contrib/ntp/ntpd/ntp_restrict.c b/contrib/ntp/ntpd/ntp_restrict.c index 473e2ce81..82bbaef25 100644 --- a/contrib/ntp/ntpd/ntp_restrict.c +++ b/contrib/ntp/ntpd/ntp_restrict.c @@ -10,7 +10,9 @@ #include "ntpd.h" #include "ntp_if.h" +#include "ntp_lists.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" /* * This code keeps a simple address-and-mask list of hosts we want @@ -41,65 +43,75 @@ * addresses. This is not protocol-independant but for now I can't * find a way to respect this. We'll check this later... JFB 07/2001 */ -#define SET_IPV6_ADDR_MASK(dst, src, msk) \ - do { \ - int idx; \ - for (idx = 0; idx < 16; idx++) { \ - (dst)->s6_addr[idx] = \ - (u_char) ((src)->s6_addr[idx] & (msk)->s6_addr[idx]); \ - } \ +#define MASK_IPV6_ADDR(dst, src, msk) \ + do { \ + int idx; \ + for (idx = 0; idx < (int)COUNTOF((dst)->s6_addr); idx++) { \ + (dst)->s6_addr[idx] = (src)->s6_addr[idx] \ + & (msk)->s6_addr[idx]; \ + } \ } while (0) /* - * Memory allocation parameters. We allocate INITRESLIST entries - * initially, and add INCRESLIST entries to the free list whenever - * we run out. + * We allocate INC_RESLIST{4|6} entries to the free list whenever empty. + * Auto-tune these to be just less than 1KB (leaving at least 16 bytes + * for allocator overhead). */ -#define INITRESLIST 10 -#define INCRESLIST 5 - -#define RES_AVG 8. /* interpacket averaging factor */ +#define INC_RESLIST4 ((1024 - 16) / V4_SIZEOF_RESTRICT_U) +#define INC_RESLIST6 ((1024 - 16) / V6_SIZEOF_RESTRICT_U) /* * The restriction list */ -struct restrictlist *restrictlist; -struct restrictlist6 *restrictlist6; -static int restrictcount; /* count of entries in the res list */ -static int restrictcount6; /* count of entries in the res list 2*/ +restrict_u *restrictlist4; +restrict_u *restrictlist6; +static int restrictcount; /* count in the restrict lists */ /* * The free list and associated counters. Also some uninteresting * stat counters. */ -static struct restrictlist *resfree; -static struct restrictlist6 *resfree6; -static int numresfree; /* number of structures on free list */ -static int numresfree6; /* number of structures on free list 2 */ +static restrict_u *resfree4; /* available entries (free list) */ +static restrict_u *resfree6; -static u_long res_calls; -static u_long res_found; -static u_long res_not_found; +static u_long res_calls; +static u_long res_found; +static u_long res_not_found; /* - * Parameters of the RES_LIMITED restriction option. + * Count number of restriction entries referring to RES_LIMITED, to + * control implicit activation/deactivation of the MRU monlist. */ -u_long res_avg_interval = 5; /* min average interpacket interval */ -u_long res_min_interval = 1; /* min interpacket interval */ +static u_long res_limited_refcnt; /* - * Count number of restriction entries referring to RES_LIMITED controls - * activation/deactivation of monitoring (with respect to RES_LIMITED - * control) + * Our default entries. */ -static u_long res_limited_refcnt; -static u_long res_limited_refcnt6; +static restrict_u restrict_def4; +static restrict_u restrict_def6; /* - * Our initial allocation of lists entries. + * "restrict source ..." enabled knob and restriction bits. */ -static struct restrictlist resinit[INITRESLIST]; -static struct restrictlist6 resinit6[INITRESLIST]; +static int restrict_source_enabled; +static u_short restrict_source_flags; +static u_short restrict_source_mflags; + +/* + * private functions + */ +static restrict_u * alloc_res4(void); +static restrict_u * alloc_res6(void); +static void free_res(restrict_u *, int); +static void inc_res_limited(void); +static void dec_res_limited(void); +static restrict_u * match_restrict4_addr(u_int32, u_short); +static restrict_u * match_restrict6_addr(const struct in6_addr *, + u_short); +static restrict_u * match_restrict_entry(const restrict_u *, int); +static int res_sorts_before4(restrict_u *, restrict_u *); +static int res_sorts_before6(restrict_u *, restrict_u *); + /* * init_restrict - initialize the restriction data structures @@ -107,103 +119,332 @@ static struct restrictlist6 resinit6[INITRESLIST]; void init_restrict(void) { - register int i; - /* - * Zero the list and put all but one on the free list + * The restriction lists begin with a default entry with address + * and mask 0, which will match any entry. The lists are kept + * sorted by descending address followed by descending mask: + * + * address mask + * 192.168.0.0 255.255.255.0 kod limited noquery nopeer + * 192.168.0.0 255.255.0.0 kod limited + * 0.0.0.0 0.0.0.0 kod limited noquery + * + * The first entry which matches an address is used. With the + * example restrictions above, 192.168.0.0/24 matches the first + * entry, the rest of 192.168.0.0/16 matches the second, and + * everything else matches the third (default). + * + * Note this achieves the same result a little more efficiently + * than the documented behavior, which is to keep the lists + * sorted by ascending address followed by ascending mask, with + * the _last_ matching entry used. + * + * An additional wrinkle is we may have multiple entries with + * the same address and mask but differing match flags (mflags). + * At present there is only one, RESM_NTPONLY. Entries with + * RESM_NTPONLY are sorted earlier so they take precedence over + * any otherwise similar entry without. Again, this is the same + * behavior as but reversed implementation compared to the docs. + * */ - resfree = NULL; - memset((char *)resinit, 0, sizeof resinit); - resfree6 = NULL; - memset((char *)resinit6, 0, sizeof resinit6); - for (i = 1; i < INITRESLIST; i++) { - resinit[i].next = resfree; - resinit6[i].next = resfree6; - resfree = &resinit[i]; - resfree6 = &resinit6[i]; + LINK_SLIST(restrictlist4, &restrict_def4, link); + LINK_SLIST(restrictlist6, &restrict_def6, link); + restrictcount = 2; +} + + +static restrict_u * +alloc_res4(void) +{ + const size_t cb = V4_SIZEOF_RESTRICT_U; + const size_t count = INC_RESLIST4; + restrict_u * rl; + restrict_u * res; + int i; + + UNLINK_HEAD_SLIST(res, resfree4, link); + if (res != NULL) + return res; + + rl = emalloc_zero(count * cb); + /* link all but the first onto free list */ + res = (void *)((char *)rl + (count - 1) * cb); + for (i = count - 1; i > 0; i--) { + LINK_SLIST(resfree4, res, link); + res = (void *)((char *)res - cb); } - numresfree = INITRESLIST-1; - numresfree6 = INITRESLIST-1; + INSIST(rl == res); + /* allocate the first */ + return res; +} - /* - * Put the remaining item at the head of the list as our default - * entry. Everything in here should be zero for now. - */ - resinit[0].addr = htonl(INADDR_ANY); - resinit[0].mask = 0; - memset(&resinit6[0].addr6, 0, sizeof(struct in6_addr)); - memset(&resinit6[0].mask6, 0, sizeof(struct in6_addr)); - restrictlist = &resinit[0]; - restrictlist6 = &resinit6[0]; - restrictcount = 1; - restrictcount = 2; - /* - * fix up stat counters - */ - res_calls = 0; - res_found = 0; - res_not_found = 0; +static restrict_u * +alloc_res6(void) +{ + const size_t cb = V6_SIZEOF_RESTRICT_U; + const size_t count = INC_RESLIST6; + restrict_u * rl; + restrict_u * res; + int i; + + UNLINK_HEAD_SLIST(res, resfree6, link); + if (res != NULL) + return res; + + rl = emalloc_zero(count * cb); + /* link all but the first onto free list */ + res = (void *)((char *)rl + (count - 1) * cb); + for (i = count - 1; i > 0; i--) { + LINK_SLIST(resfree6, res, link); + res = (void *)((char *)res - cb); + } + INSIST(rl == res); + /* allocate the first */ + return res; +} - /* - * set default values for RES_LIMIT functionality - */ - res_limited_refcnt = 0; - res_limited_refcnt6 = 0; + +static void +free_res( + restrict_u * res, + int v6 + ) +{ + restrict_u ** plisthead; + restrict_u * unlinked; + + restrictcount--; + if (RES_LIMITED & res->flags) + dec_res_limited(); + + if (v6) + plisthead = &restrictlist6; + else + plisthead = &restrictlist4; + UNLINK_SLIST(unlinked, *plisthead, res, link, restrict_u); + INSIST(unlinked == res); + + if (v6) { + zero_mem(res, V6_SIZEOF_RESTRICT_U); + plisthead = &resfree6; + } else { + zero_mem(res, V4_SIZEOF_RESTRICT_U); + plisthead = &resfree4; + } + LINK_SLIST(*plisthead, res, link); +} + + +static void +inc_res_limited(void) +{ + if (!res_limited_refcnt) + mon_start(MON_RES); + res_limited_refcnt++; +} + + +static void +dec_res_limited(void) +{ + res_limited_refcnt--; + if (!res_limited_refcnt) + mon_stop(MON_RES); +} + + +static restrict_u * +match_restrict4_addr( + u_int32 addr, + u_short port + ) +{ + const int v6 = 0; + restrict_u * res; + restrict_u * next; + + for (res = restrictlist4; res != NULL; res = next) { + next = res->link; + if (res->expire && + res->expire <= current_time) + free_res(res, v6); + if (res->u.v4.addr == (addr & res->u.v4.mask) + && (!(RESM_NTPONLY & res->mflags) + || NTP_PORT == port)) + break; + } + return res; +} + + +static restrict_u * +match_restrict6_addr( + const struct in6_addr * addr, + u_short port + ) +{ + const int v6 = 1; + restrict_u * res; + restrict_u * next; + struct in6_addr masked; + + for (res = restrictlist6; res != NULL; res = next) { + next = res->link; + INSIST(next != res); + if (res->expire && + res->expire <= current_time) + free_res(res, v6); + MASK_IPV6_ADDR(&masked, addr, &res->u.v6.mask); + if (ADDR6_EQ(&masked, &res->u.v6.addr) + && (!(RESM_NTPONLY & res->mflags) + || NTP_PORT == (int)port)) + break; + } + return res; +} + + +/* + * match_restrict_entry - find an exact match on a restrict list. + * + * Exact match is addr, mask, and mflags all equal. + * In order to use more common code for IPv4 and IPv6, this routine + * requires the caller to populate a restrict_u with mflags and either + * the v4 or v6 address and mask as appropriate. Other fields in the + * input restrict_u are ignored. + */ +static restrict_u * +match_restrict_entry( + const restrict_u * pmatch, + int v6 + ) +{ + restrict_u *res; + restrict_u *rlist; + size_t cb; + + if (v6) { + rlist = restrictlist6; + cb = sizeof(pmatch->u.v6); + } else { + rlist = restrictlist4; + cb = sizeof(pmatch->u.v4); + } + + for (res = rlist; res != NULL; res = res->link) + if (res->mflags == pmatch->mflags && + !memcmp(&res->u, &pmatch->u, cb)) + break; + return res; +} + + +/* + * res_sorts_before4 - compare two restrict4 entries + * + * Returns nonzero if r1 sorts before r2. We sort by descending + * address, then descending mask, then descending mflags, so sorting + * before means having a higher value. + */ +static int +res_sorts_before4( + restrict_u *r1, + restrict_u *r2 + ) +{ + int r1_before_r2; + + if (r1->u.v4.addr > r2->u.v4.addr) + r1_before_r2 = 1; + else if (r1->u.v4.addr < r2->u.v4.addr) + r1_before_r2 = 0; + else if (r1->u.v4.mask > r2->u.v4.mask) + r1_before_r2 = 1; + else if (r1->u.v4.mask < r2->u.v4.mask) + r1_before_r2 = 0; + else if (r1->mflags > r2->mflags) + r1_before_r2 = 1; + else + r1_before_r2 = 0; + + return r1_before_r2; +} + + +/* + * res_sorts_before6 - compare two restrict6 entries + * + * Returns nonzero if r1 sorts before r2. We sort by descending + * address, then descending mask, then descending mflags, so sorting + * before means having a higher value. + */ +static int +res_sorts_before6( + restrict_u *r1, + restrict_u *r2 + ) +{ + int r1_before_r2; + int cmp; + + cmp = ADDR6_CMP(&r1->u.v6.addr, &r2->u.v6.addr); + if (cmp > 0) /* r1->addr > r2->addr */ + r1_before_r2 = 1; + else if (cmp < 0) /* r2->addr > r1->addr */ + r1_before_r2 = 0; + else { + cmp = ADDR6_CMP(&r1->u.v6.mask, &r2->u.v6.mask); + if (cmp > 0) /* r1->mask > r2->mask*/ + r1_before_r2 = 1; + else if (cmp < 0) /* r2->mask > r1->mask */ + r1_before_r2 = 0; + else if (r1->mflags > r2->mflags) + r1_before_r2 = 1; + else + r1_before_r2 = 0; + } + + return r1_before_r2; } /* * restrictions - return restrictions for this host */ -int +u_short restrictions( - struct sockaddr_storage *srcadr, - int at_listhead + sockaddr_u *srcadr ) { - struct restrictlist *rl; - struct restrictlist *match = NULL; - struct restrictlist6 *rl6; - struct restrictlist6 *match6 = NULL; - struct in6_addr hostaddr6; - struct in6_addr hostservaddr6; - u_int32 hostaddr; - int flags = 0; - int isntpport; + restrict_u *match; + struct in6_addr *pin6; + u_short flags; res_calls++; - if (srcadr->ss_family == AF_INET) { - /* - * We need the host address in host order. Also need to - * know whether this is from the ntp port or not. - */ - hostaddr = SRCADR(srcadr); - isntpport = (SRCPORT(srcadr) == NTP_PORT); - + flags = 0; + /* IPv4 source address */ + if (IS_IPV4(srcadr)) { /* * Ignore any packets with a multicast source address * (this should be done early in the receive process, - * later!) + * not later!) */ if (IN_CLASSD(SRCADR(srcadr))) return (int)RES_IGNORE; + match = match_restrict4_addr(SRCADR(srcadr), + SRCPORT(srcadr)); + + INSIST(match != NULL); + + match->count++; /* - * Set match to first entry, which is default entry. - * Work our way down from there. + * res_not_found counts only use of the final default + * entry, not any "restrict default ntpport ...", which + * would be just before the final default. */ - match = restrictlist; - for (rl = match->next; rl != NULL && rl->addr <= hostaddr; - rl = rl->next) - if ((hostaddr & rl->mask) == rl->addr) { - if ((rl->mflags & RESM_NTPONLY) && - !isntpport) - continue; - match = rl; - } - match->count++; - if (match == restrictlist) + if (&restrict_def4 == match) res_not_found++; else res_found++; @@ -211,77 +452,25 @@ restrictions( } /* IPv6 source address */ - if (srcadr->ss_family == AF_INET6) { - /* - * Need to know whether this is from the ntp port or - * not. - */ - hostaddr6 = GET_INADDR6(*srcadr); - isntpport = (ntohs(( - (struct sockaddr_in6 *)srcadr)->sin6_port) == - NTP_PORT); + if (IS_IPV6(srcadr)) { + pin6 = PSOCK_ADDR6(srcadr); /* * Ignore any packets with a multicast source address * (this should be done early in the receive process, - * later!) + * not later!) */ - if (IN6_IS_ADDR_MULTICAST(&hostaddr6)) + if (IN6_IS_ADDR_MULTICAST(pin6)) return (int)RES_IGNORE; - /* - * Set match to first entry, which is default entry. - * Work our way down from there. - */ - match6 = restrictlist6; - for (rl6 = match6->next; rl6 != NULL && - (memcmp(&(rl6->addr6), &hostaddr6, - sizeof(hostaddr6)) <= 0); rl6 = rl6->next) { - SET_IPV6_ADDR_MASK(&hostservaddr6, &hostaddr6, - &rl6->mask6); - if (memcmp(&hostservaddr6, &(rl6->addr6), - sizeof(hostservaddr6)) == 0) { - if ((rl6->mflags & RESM_NTPONLY) && - !isntpport) - continue; - match6 = rl6; - } - } - match6->count++; - if (match6 == restrictlist6) + match = match_restrict6_addr(pin6, SRCPORT(srcadr)); + INSIST(match != NULL); + match->count++; + if (&restrict_def6 == match) res_not_found++; else res_found++; - flags = match6->flags; - } - - /* - * The following implements a generalized call gap facility. - * Douse the RES_LIMITED bit only if the interval since the last - * packet is greater than res_min_interval and the average is - * greater thatn res_avg_interval. - */ - if (!at_listhead || mon_enabled == MON_OFF) { - flags &= ~RES_LIMITED; - } else { - struct mon_data *md; - - /* - * At this poin the most recent arrival is first in the - * MRU list. Let the first 10 packets in for free until - * the average stabilizes. - */ - md = mon_mru_list.mru_next; - if (md->avg_interval == 0) - md->avg_interval = md->drop_count; - else - md->avg_interval += (md->drop_count - - md->avg_interval) / RES_AVG; - if (md->count < 10 || (md->drop_count > - res_min_interval && md->avg_interval > - res_avg_interval)) - flags &= ~RES_LIMITED; - md->drop_count = flags; + flags = match->flags; } return (flags); } @@ -292,316 +481,199 @@ restrictions( */ void hack_restrict( - int op, - struct sockaddr_storage *resaddr, - struct sockaddr_storage *resmask, - int mflags, - int flags + int op, + sockaddr_u * resaddr, + sockaddr_u * resmask, + u_short mflags, + u_short flags, + u_long expire ) { - register u_int32 addr = 0; - register u_int32 mask = 0; - struct in6_addr addr6; - struct in6_addr mask6; - register struct restrictlist *rl = NULL; - register struct restrictlist *rlprev = NULL; - register struct restrictlist6 *rl6 = NULL; - register struct restrictlist6 *rlprev6 = NULL; - int i, addr_cmp, mask_cmp; - memset(&addr6, 0, sizeof(struct in6_addr)); - memset(&mask6, 0, sizeof(struct in6_addr)); - - if (resaddr->ss_family == AF_INET) { + int v6; + restrict_u match; + restrict_u * res; + restrict_u ** plisthead; + + DPRINTF(1, ("restrict: op %d addr %s mask %s mflags %08x flags %08x\n", + op, stoa(resaddr), stoa(resmask), mflags, flags)); + + if (NULL == resaddr) { + REQUIRE(NULL == resmask); + REQUIRE(RESTRICT_FLAGS == op); + restrict_source_flags = flags; + restrict_source_mflags = mflags; + restrict_source_enabled = 1; + return; + } + + ZERO(match); + +#if 0 + /* silence VC9 potentially uninit warnings */ + // HMS: let's use a compiler-specific "enable" for this. + res = NULL; + v6 = 0; +#endif + + if (IS_IPV4(resaddr)) { + v6 = 0; /* - * Get address and mask in host byte order + * Get address and mask in host byte order for easy + * comparison as u_int32 */ - addr = SRCADR(resaddr); - mask = SRCADR(resmask); - addr &= mask; /* make sure low bits zero */ + match.u.v4.addr = SRCADR(resaddr); + match.u.v4.mask = SRCADR(resmask); + match.u.v4.addr &= match.u.v4.mask; + } else if (IS_IPV6(resaddr)) { + v6 = 1; /* - * If this is the default address, point at first on - * list. Else go searching for it. + * Get address and mask in network byte order for easy + * comparison as byte sequences (e.g. memcmp()) */ - if (addr == 0) { - rlprev = NULL; - rl = restrictlist; - } else { - rlprev = restrictlist; - rl = rlprev->next; - while (rl != NULL) { - if (rl->addr > addr) { - rl = NULL; - break; - } else if (rl->addr == addr) { - if (rl->mask == mask) { - if ((mflags & - RESM_NTPONLY) == - (rl->mflags & - RESM_NTPONLY)) - break; - - if (!(mflags & - RESM_NTPONLY)) { - rl = NULL; - break; - } - } else if (rl->mask > mask) { - rl = NULL; - break; - } - } - rlprev = rl; - rl = rl->next; - } - } - } + match.u.v6.mask = SOCK_ADDR6(resmask); + MASK_IPV6_ADDR(&match.u.v6.addr, PSOCK_ADDR6(resaddr), + &match.u.v6.mask); - if (resaddr->ss_family == AF_INET6) { - mask6 = GET_INADDR6(*resmask); - SET_IPV6_ADDR_MASK(&addr6, - &GET_INADDR6(*resaddr), &mask6); - if (IN6_IS_ADDR_UNSPECIFIED(&addr6)) { - rlprev6 = NULL; - rl6 = restrictlist6; - } else { - rlprev6 = restrictlist6; - rl6 = rlprev6->next; - while (rl6 != NULL) { - addr_cmp = memcmp(&rl6->addr6, &addr6, - sizeof(addr6)); - if (addr_cmp > 0) { - rl6 = NULL; - break; - } else if (addr_cmp == 0) { - mask_cmp = memcmp(&rl6->mask6, - &mask6, sizeof(mask6)); - if (mask_cmp == 0) { - if ((mflags & - RESM_NTPONLY) == - (rl6->mflags & - RESM_NTPONLY)) - break; - - if (!(mflags & - RESM_NTPONLY)) { - rl6 = NULL; - break; - } - } else if (mask_cmp > 0) { - rl6 = NULL; - break; - } - } - rlprev6 = rl6; - rl6 = rl6->next; - } - } - } + } else /* not IPv4 nor IPv6 */ + REQUIRE(0); - /* - * In case the above wasn't clear :-), either rl now points - * at the entry this call refers to, or rl is zero and rlprev - * points to the entry prior to where this one should go in - * the sort. - */ + match.flags = flags; + match.mflags = mflags; + match.expire = expire; + res = match_restrict_entry(&match, v6); - /* - * Switch based on operation - */ - if (resaddr->ss_family == AF_INET) { - switch (op) { - case RESTRICT_FLAGS: - /* - * Here we add bits to the flags. If this is a - * new restriction add it. - */ - if (rl == NULL) { - if (resfree == NULL) { - rl = (struct restrictlist *) - emalloc(INCRESLIST * - sizeof(struct - restrictlist)); - memset((char *)rl, 0, - INCRESLIST * sizeof(struct - restrictlist)); - for (i = 0; i < INCRESLIST; i++) { - rl->next = resfree; - resfree = rl; - rl++; - } - numresfree = INCRESLIST; - } - - rl = resfree; - resfree = rl->next; - numresfree--; - - rl->addr = addr; - rl->mask = mask; - rl->mflags = (u_short)mflags; - - if (rlprev == NULL) { - rl->next = restrictlist; - restrictlist = rl; - } else { - rl->next = rlprev->next; - rlprev->next = rl; - } - restrictcount++; - } - if ((rl->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt++; - mon_start(MON_RES); - } - rl->flags |= (u_short)flags; - break; + switch (op) { - case RESTRICT_UNFLAG: - /* - * Remove some bits from the flags. If we didn't - * find this one, just return. - */ - if (rl != NULL) { - if ((rl->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt--; - if (res_limited_refcnt == 0) - mon_stop(MON_RES); - } - rl->flags &= (u_short)~flags; - } - break; - - case RESTRICT_REMOVE: - case RESTRICT_REMOVEIF: - /* - * Remove an entry from the table entirely if we - * found one. Don't remove the default entry and - * don't remove an interface entry. - */ - if (rl != NULL - && rl->addr != htonl(INADDR_ANY) - && !(rl->mflags & RESM_INTERFACE && op != RESTRICT_REMOVEIF)) { - if (rlprev != NULL) { - rlprev->next = rl->next; - } else { - restrictlist = rl->next; - } - restrictcount--; - if (rl->flags & RES_LIMITED) { - res_limited_refcnt--; - if (res_limited_refcnt == 0) - mon_stop(MON_RES); - } - memset((char *)rl, 0, - sizeof(struct restrictlist)); - - rl->next = resfree; - resfree = rl; - numresfree++; + case RESTRICT_FLAGS: + /* + * Here we add bits to the flags. If this is a + * new restriction add it. + */ + if (NULL == res) { + if (v6) { + res = alloc_res6(); + memcpy(res, &match, + V6_SIZEOF_RESTRICT_U); + plisthead = &restrictlist6; + } else { + res = alloc_res4(); + memcpy(res, &match, + V4_SIZEOF_RESTRICT_U); + plisthead = &restrictlist4; } - break; + LINK_SORT_SLIST( + *plisthead, res, + (v6) + ? res_sorts_before6(res, L_S_S_CUR()) + : res_sorts_before4(res, L_S_S_CUR()), + link, restrict_u); + restrictcount++; + if (RES_LIMITED & flags) + inc_res_limited(); + } else { + if ((RES_LIMITED & flags) && + !(RES_LIMITED & res->flags)) + inc_res_limited(); + res->flags |= flags; + } + break; - default: - break; + case RESTRICT_UNFLAG: + /* + * Remove some bits from the flags. If we didn't + * find this one, just return. + */ + if (res != NULL) { + if ((RES_LIMITED & res->flags) + && (RES_LIMITED & flags)) + dec_res_limited(); + res->flags &= ~flags; } - } else if (resaddr->ss_family == AF_INET6) { - switch (op) { - case RESTRICT_FLAGS: - /* - * Here we add bits to the flags. If this is a - * new restriction add it. - */ - if (rl6 == NULL) { - if (resfree6 == NULL) { - rl6 = (struct - restrictlist6 *)emalloc( - INCRESLIST * sizeof(struct - restrictlist6)); - memset((char *)rl6, 0, - INCRESLIST * sizeof(struct - restrictlist6)); - - for (i = 0; i < INCRESLIST; - i++) { - rl6->next = resfree6; - resfree6 = rl6; - rl6++; - } - numresfree6 = INCRESLIST; - } - rl6 = resfree6; - resfree6 = rl6->next; - numresfree6--; - rl6->addr6 = addr6; - rl6->mask6 = mask6; - rl6->mflags = (u_short)mflags; - if (rlprev6 != NULL) { - rl6->next = rlprev6->next; - rlprev6->next = rl6; - } else { - rl6->next = restrictlist6; - restrictlist6 = rl6; - } - restrictcount6++; - } - if ((rl6->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt6++; - mon_start(MON_RES); - } - rl6->flags |= (u_short)flags; - break; + break; - case RESTRICT_UNFLAG: - /* - * Remove some bits from the flags. If we didn't - * find this one, just return. - */ - if (rl6 != NULL) { - if ((rl6->flags ^ (u_short)flags) & - RES_LIMITED) { - res_limited_refcnt6--; - if (res_limited_refcnt6 == 0) - mon_stop(MON_RES); - } - rl6->flags &= (u_short)~flags; - } - break; + case RESTRICT_REMOVE: + case RESTRICT_REMOVEIF: + /* + * Remove an entry from the table entirely if we + * found one. Don't remove the default entry and + * don't remove an interface entry. + */ + if (res != NULL + && (RESTRICT_REMOVEIF == op + || !(RESM_INTERFACE & res->mflags)) + && res != &restrict_def4 + && res != &restrict_def6) + free_res(res, v6); + break; + + default: /* unknown op */ + INSIST(0); + break; + } - case RESTRICT_REMOVE: - case RESTRICT_REMOVEIF: - /* - * Remove an entry from the table entirely if we - * found one. Don't remove the default entry and - * don't remove an interface entry. - */ - if (rl6 != NULL && - !IN6_IS_ADDR_UNSPECIFIED(&rl6->addr6) - && !(rl6->mflags & RESM_INTERFACE && op != RESTRICT_REMOVEIF)) { - if (rlprev6 != NULL) { - rlprev6->next = rl6->next; - } else { - restrictlist6 = rl6->next; - } - restrictcount6--; - if (rl6->flags & RES_LIMITED) { - res_limited_refcnt6--; - if (res_limited_refcnt6 == 0) - mon_stop(MON_RES); - } - memset((char *)rl6, 0, - sizeof(struct restrictlist6)); - rl6->next = resfree6; - resfree6 = rl6; - numresfree6++; - } - break; +} - default: - break; - } + +/* + * restrict_source - maintains dynamic "restrict source ..." entries as + * peers come and go. + */ +void +restrict_source( + sockaddr_u * addr, + int farewell, /* 0 to add, 1 to remove */ + u_long expire /* 0 is infinite, valid until */ + ) +{ + sockaddr_u onesmask; + restrict_u * res; + int found_specific; + + if (!restrict_source_enabled || SOCK_UNSPEC(addr) || + IS_MCAST(addr) || ISREFCLOCKADR(addr)) + return; + + REQUIRE(AF_INET == AF(addr) || AF_INET6 == AF(addr)); + + SET_HOSTMASK(&onesmask, AF(addr)); + if (farewell) { + hack_restrict(RESTRICT_REMOVE, addr, &onesmask, + 0, 0, 0); + DPRINTF(1, ("restrict_source: %s removed", stoa(addr))); + return; + } + + /* + * If there is a specific entry for this address, hands + * off, as it is condidered more specific than "restrict + * server ...". + * However, if the specific entry found is a fleeting one + * added by pool_xmit() before soliciting, replace it + * immediately regardless of the expire value to make way + * for the more persistent entry. + */ + if (IS_IPV4(addr)) { + res = match_restrict4_addr(SRCADR(addr), SRCPORT(addr)); + INSIST(res != NULL); + found_specific = (SRCADR(&onesmask) == res->u.v4.mask); + } else { + res = match_restrict6_addr(&SOCK_ADDR6(addr), + SRCPORT(addr)); + INSIST(res != NULL); + found_specific = ADDR6_EQ(&res->u.v6.mask, + &SOCK_ADDR6(&onesmask)); + } + if (!expire && found_specific && res->expire) { + found_specific = 0; + free_res(res, IS_IPV6(addr)); } + if (found_specific) + return; + + hack_restrict(RESTRICT_FLAGS, addr, &onesmask, + restrict_source_mflags, restrict_source_flags, + expire); + DPRINTF(1, ("restrict_source: %s host restriction added\n", + stoa(addr))); } diff --git a/contrib/ntp/ntpd/ntp_scanner.c b/contrib/ntp/ntpd/ntp_scanner.c new file mode 100644 index 000000000..49adf6bfb --- /dev/null +++ b/contrib/ntp/ntpd/ntp_scanner.c @@ -0,0 +1,935 @@ + +/* ntp_scanner.c + * + * The source code for a simple lexical analyzer. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ + +#ifdef HAVE_CONFIG_H +# include +#endif + +#include +#include +#include +#include +#include + +#include "ntpd.h" +#include "ntp_config.h" +#include "ntpsim.h" +#include "ntp_scanner.h" +#include "ntp_parser.h" + +/* ntp_keyword.h declares finite state machine and token text */ +#include "ntp_keyword.h" + + + +/* SCANNER GLOBAL VARIABLES + * ------------------------ + */ + +#define MAX_LEXEME (1024 + 1) /* The maximum size of a lexeme */ +char yytext[MAX_LEXEME]; /* Buffer for storing the input text/lexeme */ +u_int32 conf_file_sum; /* Simple sum of characters read */ + +static struct FILE_INFO * lex_stack = NULL; + + + +/* CONSTANTS + * --------- + */ + + +/* SCANNER GLOBAL VARIABLES + * ------------------------ + */ +const char special_chars[] = "{}(),;|="; + + +/* FUNCTIONS + * --------- + */ + +static int is_keyword(char *lexeme, follby *pfollowedby); + + +/* + * keyword() - Return the keyword associated with token T_ identifier. + * See also token_name() for the string-ized T_ identifier. + * Example: keyword(T_Server) returns "server" + * token_name(T_Server) returns "T_Server" + */ +const char * +keyword( + int token + ) +{ + size_t i; + const char *text; + + i = token - LOWEST_KEYWORD_ID; + + if (i < COUNTOF(keyword_text)) + text = keyword_text[i]; + else + text = NULL; + + return (text != NULL) + ? text + : "(keyword not found)"; +} + + +/* FILE & STRING BUFFER INTERFACE + * ------------------------------ + * + * This set out as a couple of wrapper functions around the standard C + * fgetc and ungetc functions in order to include positional + * bookkeeping. Alas, this is no longer a good solution with nested + * input files and the possibility to send configuration commands via + * 'ntpdc' and 'ntpq'. + * + * Now there are a few functions to maintain a stack of nested input + * sources (though nesting is only allowd for disk files) and from the + * scanner / parser point of view there's no difference between both + * types of sources. + * + * The 'fgetc()' / 'ungetc()' replacements now operate on a FILE_INFO + * structure. Instead of trying different 'ungetc()' strategies for file + * and buffer based parsing, we keep the backup char in our own + * FILE_INFO structure. This is sufficient, as the parser does *not* + * jump around via 'seek' or the like, and there's no need to + * check/clear the backup store in other places than 'lex_getch()'. + */ + +/* + * Allocate an info structure and attach it to a file. + * + * Note: When 'mode' is NULL, then the INFO block will be set up to + * contain a NULL file pointer, as suited for remote config command + * parsing. Otherwise having a NULL file pointer is considered an error, + * and a NULL info block pointer is returned to indicate failure! + * + * Note: We use a variable-sized structure to hold a copy of the file + * name (or, more proper, the input source description). This is more + * secure than keeping a reference to some other storage that might go + * out of scope. + */ +static struct FILE_INFO * +lex_open( + const char *path, + const char *mode + ) +{ + struct FILE_INFO *stream; + size_t nnambuf; + + nnambuf = strlen(path); + stream = emalloc_zero(sizeof(*stream) + nnambuf); + stream->curpos.nline = 1; + stream->backch = EOF; + /* copy name with memcpy -- trailing NUL already there! */ + memcpy(stream->fname, path, nnambuf); + + if (NULL != mode) { + stream->fpi = fopen(path, mode); + if (NULL == stream->fpi) { + free(stream); + stream = NULL; + } + } + return stream; +} + +/* get next character from buffer or file. This will return any putback + * character first; it will also make sure the last line is at least + * virtually terminated with a '\n'. + */ +static int +lex_getch( + struct FILE_INFO *stream + ) +{ + int ch; + + if (NULL == stream || stream->force_eof) + return EOF; + + if (EOF != stream->backch) { + ch = stream->backch; + stream->backch = EOF; + if (stream->fpi) + conf_file_sum += ch; + } else if (stream->fpi) { + /* fetch next 7-bit ASCII char (or EOF) from file */ + while ((ch = fgetc(stream->fpi)) != EOF && ch > SCHAR_MAX) + stream->curpos.ncol++; + if (EOF != ch) { + conf_file_sum += ch; + stream->curpos.ncol++; + } + } else { + /* fetch next 7-bit ASCII char from buffer */ + const char * scan; + scan = &remote_config.buffer[remote_config.pos]; + while ((ch = (u_char)*scan) > SCHAR_MAX) { + scan++; + stream->curpos.ncol++; + } + if ('\0' != ch) { + scan++; + stream->curpos.ncol++; + } else { + ch = EOF; + } + remote_config.pos = (int)(scan - remote_config.buffer); + } + + /* If the last line ends without '\n', generate one. This + * happens most likely on Windows, where editors often have a + * sloppy concept of a line. + */ + if (EOF == ch && stream->curpos.ncol != 0) + ch = '\n'; + + /* update scan position tallies */ + if (ch == '\n') { + stream->bakpos = stream->curpos; + stream->curpos.nline++; + stream->curpos.ncol = 0; + } + + return ch; +} + +/* Note: lex_ungetch will fail to track more than one line of push + * back. But since it guarantees only one char of back storage anyway, + * this should not be a problem. + */ +static int +lex_ungetch( + int ch, + struct FILE_INFO *stream + ) +{ + /* check preconditions */ + if (NULL == stream || stream->force_eof) + return EOF; + if (EOF != stream->backch || EOF == ch) + return EOF; + + /* keep for later reference and update checksum */ + stream->backch = (u_char)ch; + if (stream->fpi) + conf_file_sum -= stream->backch; + + /* update position */ + if (stream->backch == '\n') { + stream->curpos = stream->bakpos; + stream->bakpos.ncol = -1; + } + stream->curpos.ncol--; + return stream->backch; +} + +/* dispose of an input structure. If the file pointer is not NULL, close + * the file. This function does not check the result of 'fclose()'. + */ +static void +lex_close( + struct FILE_INFO *stream + ) +{ + if (NULL != stream) { + if (NULL != stream->fpi) + fclose(stream->fpi); + free(stream); + } +} + +/* INPUT STACK + * ----------- + * + * Nested input sources are a bit tricky at first glance. We deal with + * this problem using a stack of input sources, that is, a forward + * linked list of FILE_INFO structs. + * + * This stack is never empty during parsing; while an encounter with EOF + * can and will remove nested input sources, removing the last element + * in the stack will not work during parsing, and the EOF condition of + * the outermost input file remains until the parser folds up. + */ + +static struct FILE_INFO * +_drop_stack_do( + struct FILE_INFO * head + ) +{ + struct FILE_INFO * tail; + while (NULL != head) { + tail = head->st_next; + lex_close(head); + head = tail; + } + return head; +} + + + +/* Create a singleton input source on an empty lexer stack. This will + * fail if there is already an input source, or if the underlying disk + * file cannot be opened. + * + * Returns TRUE if a new input object was successfully created. + */ +int/*BOOL*/ +lex_init_stack( + const char * path, + const char * mode + ) +{ + if (NULL != lex_stack || NULL == path) + return FALSE; + + lex_stack = lex_open(path, mode); + return (NULL != lex_stack); +} + +/* This removes *all* input sources from the stack, leaving the head + * pointer as NULL. Any attempt to parse in that state is likely to bomb + * with segmentation faults or the like. + * + * In other words: Use this to clean up after parsing, and do not parse + * anything until the next 'lex_init_stack()' succeeded. + */ +void +lex_drop_stack() +{ + lex_stack = _drop_stack_do(lex_stack); +} + +/* Flush the lexer input stack: This will nip all input objects on the + * stack (but keeps the current top-of-stack) and marks the top-of-stack + * as inactive. Any further calls to lex_getch yield only EOF, and it's + * no longer possible to push something back. + * + * Returns TRUE if there is a head element (top-of-stack) that was not + * in the force-eof mode before this call. + */ +int/*BOOL*/ +lex_flush_stack() +{ + int retv = FALSE; + + if (NULL != lex_stack) { + retv = !lex_stack->force_eof; + lex_stack->force_eof = TRUE; + lex_stack->st_next = _drop_stack_do( + lex_stack->st_next); + } + return retv; +} + +/* Push another file on the parsing stack. If the mode is NULL, create a + * FILE_INFO suitable for in-memory parsing; otherwise, create a + * FILE_INFO that is bound to a local/disc file. Note that 'path' must + * not be NULL, or the function will fail. + * + * Returns TRUE if a new info record was pushed onto the stack. + */ +int/*BOOL*/ lex_push_file( + const char * path, + const char * mode + ) +{ + struct FILE_INFO * next = NULL; + + if (NULL != path) { + next = lex_open(path, mode); + if (NULL != next) { + next->st_next = lex_stack; + lex_stack = next; + } + } + return (NULL != next); +} + +/* Pop, close & free the top of the include stack, unless the stack + * contains only a singleton input object. In that case the function + * fails, because the parser does not expect the input stack to be + * empty. + * + * Returns TRUE if an object was successfuly popped from the stack. + */ +int/*BOOL*/ +lex_pop_file(void) +{ + struct FILE_INFO * head = lex_stack; + struct FILE_INFO * tail = NULL; + + if (NULL != head) { + tail = head->st_next; + if (NULL != tail) { + lex_stack = tail; + lex_close(head); + } + } + return (NULL != tail); +} + +/* Get include nesting level. This currently loops over the stack and + * counts elements; but since this is of concern only with an include + * statement and the nesting depth has a small limit, there's no + * bottleneck expected here. + * + * Returns the nesting level of includes, that is, the current depth of + * the lexer input stack. + * + * Note: + */ +size_t +lex_level(void) +{ + size_t cnt = 0; + struct FILE_INFO *ipf = lex_stack; + + while (NULL != ipf) { + cnt++; + ipf = ipf->st_next; + } + return cnt; +} + +/* check if the current input is from a file */ +int/*BOOL*/ +lex_from_file(void) +{ + return (NULL != lex_stack) && (NULL != lex_stack->fpi); +} + +struct FILE_INFO * +lex_current() +{ + /* this became so simple, it could be a macro. But then, + * lex_stack needed to be global... + */ + return lex_stack; +} + + +/* STATE MACHINES + * -------------- + */ + +/* Keywords */ +static int +is_keyword( + char *lexeme, + follby *pfollowedby + ) +{ + follby fb; + int curr_s; /* current state index */ + int token; + int i; + + curr_s = SCANNER_INIT_S; + token = 0; + + for (i = 0; lexeme[i]; i++) { + while (curr_s && (lexeme[i] != SS_CH(sst[curr_s]))) + curr_s = SS_OTHER_N(sst[curr_s]); + + if (curr_s && (lexeme[i] == SS_CH(sst[curr_s]))) { + if ('\0' == lexeme[i + 1] + && FOLLBY_NON_ACCEPTING + != SS_FB(sst[curr_s])) { + fb = SS_FB(sst[curr_s]); + *pfollowedby = fb; + token = curr_s; + break; + } + curr_s = SS_MATCH_N(sst[curr_s]); + } else + break; + } + + return token; +} + + +/* Integer */ +static int +is_integer( + char *lexeme + ) +{ + int i; + int is_neg; + u_int u_val; + + i = 0; + + /* Allow a leading minus sign */ + if (lexeme[i] == '-') { + i++; + is_neg = TRUE; + } else { + is_neg = FALSE; + } + + /* Check that all the remaining characters are digits */ + for (; lexeme[i] != '\0'; i++) { + if (!isdigit((u_char)lexeme[i])) + return FALSE; + } + + if (is_neg) + return TRUE; + + /* Reject numbers that fit in unsigned but not in signed int */ + if (1 == sscanf(lexeme, "%u", &u_val)) + return (u_val <= INT_MAX); + else + return FALSE; +} + + +/* U_int -- assumes is_integer() has returned FALSE */ +static int +is_u_int( + char *lexeme + ) +{ + int i; + int is_hex; + + i = 0; + if ('0' == lexeme[i] && 'x' == tolower((u_char)lexeme[i + 1])) { + i += 2; + is_hex = TRUE; + } else { + is_hex = FALSE; + } + + /* Check that all the remaining characters are digits */ + for (; lexeme[i] != '\0'; i++) { + if (is_hex && !isxdigit((u_char)lexeme[i])) + return FALSE; + if (!is_hex && !isdigit((u_char)lexeme[i])) + return FALSE; + } + + return TRUE; +} + + +/* Double */ +static int +is_double( + char *lexeme + ) +{ + u_int num_digits = 0; /* Number of digits read */ + u_int i; + + i = 0; + + /* Check for an optional '+' or '-' */ + if ('+' == lexeme[i] || '-' == lexeme[i]) + i++; + + /* Read the integer part */ + for (; lexeme[i] && isdigit((u_char)lexeme[i]); i++) + num_digits++; + + /* Check for the optional decimal point */ + if ('.' == lexeme[i]) { + i++; + /* Check for any digits after the decimal point */ + for (; lexeme[i] && isdigit((u_char)lexeme[i]); i++) + num_digits++; + } + + /* + * The number of digits in both the decimal part and the + * fraction part must not be zero at this point + */ + if (!num_digits) + return 0; + + /* Check if we are done */ + if (!lexeme[i]) + return 1; + + /* There is still more input, read the exponent */ + if ('e' == tolower((u_char)lexeme[i])) + i++; + else + return 0; + + /* Read an optional Sign */ + if ('+' == lexeme[i] || '-' == lexeme[i]) + i++; + + /* Now read the exponent part */ + while (lexeme[i] && isdigit((u_char)lexeme[i])) + i++; + + /* Check if we are done */ + if (!lexeme[i]) + return 1; + else + return 0; +} + + +/* is_special() - Test whether a character is a token */ +static inline int +is_special( + int ch + ) +{ + return strchr(special_chars, ch) != NULL; +} + + +static int +is_EOC( + int ch + ) +{ + if ((old_config_style && (ch == '\n')) || + (!old_config_style && (ch == ';'))) + return 1; + return 0; +} + + +char * +quote_if_needed(char *str) +{ + char *ret; + size_t len; + size_t octets; + + len = strlen(str); + octets = len + 2 + 1; + ret = emalloc(octets); + if ('"' != str[0] + && (strcspn(str, special_chars) < len + || strchr(str, ' ') != NULL)) { + snprintf(ret, octets, "\"%s\"", str); + } else + strlcpy(ret, str, octets); + + return ret; +} + + +static int +create_string_token( + char *lexeme + ) +{ + char *pch; + + /* + * ignore end of line whitespace + */ + pch = lexeme; + while (*pch && isspace((u_char)*pch)) + pch++; + + if (!*pch) { + yylval.Integer = T_EOC; + return yylval.Integer; + } + + yylval.String = estrdup(lexeme); + return T_String; +} + + +/* + * yylex() - function that does the actual scanning. + * Bison expects this function to be called yylex and for it to take no + * input and return an int. + * Conceptually yylex "returns" yylval as well as the actual return + * value representing the token or type. + */ +int +yylex(void) +{ + static follby followedby = FOLLBY_TOKEN; + int i; + int instring; + int yylval_was_set; + int converted; + int token; /* The return value */ + int ch; + + instring = FALSE; + yylval_was_set = FALSE; + + do { + /* Ignore whitespace at the beginning */ + while (EOF != (ch = lex_getch(lex_stack)) && + isspace(ch) && + !is_EOC(ch)) + + ; /* Null Statement */ + + if (EOF == ch) { + + if ( ! lex_pop_file()) + return 0; + token = T_EOC; + goto normal_return; + + } else if (is_EOC(ch)) { + + /* end FOLLBY_STRINGS_TO_EOC effect */ + followedby = FOLLBY_TOKEN; + token = T_EOC; + goto normal_return; + + } else if (is_special(ch) && FOLLBY_TOKEN == followedby) { + /* special chars are their own token values */ + token = ch; + /* + * '=' outside simulator configuration implies + * a single string following as in: + * setvar Owner = "The Boss" default + */ + if ('=' == ch && old_config_style) + followedby = FOLLBY_STRING; + yytext[0] = (char)ch; + yytext[1] = '\0'; + goto normal_return; + } else + lex_ungetch(ch, lex_stack); + + /* save the position of start of the token */ + lex_stack->tokpos = lex_stack->curpos; + + /* Read in the lexeme */ + i = 0; + while (EOF != (ch = lex_getch(lex_stack))) { + + yytext[i] = (char)ch; + + /* Break on whitespace or a special character */ + if (isspace(ch) || is_EOC(ch) + || '"' == ch + || (FOLLBY_TOKEN == followedby + && is_special(ch))) + break; + + /* Read the rest of the line on reading a start + of comment character */ + if ('#' == ch) { + while (EOF != (ch = lex_getch(lex_stack)) + && '\n' != ch) + ; /* Null Statement */ + break; + } + + i++; + if (i >= COUNTOF(yytext)) + goto lex_too_long; + } + /* Pick up all of the string inside between " marks, to + * end of line. If we make it to EOL without a + * terminating " assume it for them. + * + * XXX - HMS: I'm not sure we want to assume the closing " + */ + if ('"' == ch) { + instring = TRUE; + while (EOF != (ch = lex_getch(lex_stack)) && + ch != '"' && ch != '\n') { + yytext[i++] = (char)ch; + if (i >= COUNTOF(yytext)) + goto lex_too_long; + } + /* + * yytext[i] will be pushed back as not part of + * this lexeme, but any closing quote should + * not be pushed back, so we read another char. + */ + if ('"' == ch) + ch = lex_getch(lex_stack); + } + /* Pushback the last character read that is not a part + * of this lexeme. This fails silently if ch is EOF, + * but then the EOF condition persists and is handled on + * the next turn by the include stack mechanism. + */ + lex_ungetch(ch, lex_stack); + + yytext[i] = '\0'; + } while (i == 0); + + /* Now return the desired token */ + + /* First make sure that the parser is *not* expecting a string + * as the next token (based on the previous token that was + * returned) and that we haven't read a string. + */ + + if (followedby == FOLLBY_TOKEN && !instring) { + token = is_keyword(yytext, &followedby); + if (token) { + /* + * T_Server is exceptional as it forces the + * following token to be a string in the + * non-simulator parts of the configuration, + * but in the simulator configuration section, + * "server" is followed by "=" which must be + * recognized as a token not a string. + */ + if (T_Server == token && !old_config_style) + followedby = FOLLBY_TOKEN; + goto normal_return; + } else if (is_integer(yytext)) { + yylval_was_set = TRUE; + errno = 0; + if ((yylval.Integer = strtol(yytext, NULL, 10)) == 0 + && ((errno == EINVAL) || (errno == ERANGE))) { + msyslog(LOG_ERR, + "Integer cannot be represented: %s", + yytext); + if (lex_from_file()) { + exit(1); + } else { + /* force end of parsing */ + yylval.Integer = 0; + return 0; + } + } + token = T_Integer; + goto normal_return; + } else if (is_u_int(yytext)) { + yylval_was_set = TRUE; + if ('0' == yytext[0] && + 'x' == tolower((unsigned long)yytext[1])) + converted = sscanf(&yytext[2], "%x", + &yylval.U_int); + else + converted = sscanf(yytext, "%u", + &yylval.U_int); + if (1 != converted) { + msyslog(LOG_ERR, + "U_int cannot be represented: %s", + yytext); + if (lex_from_file()) { + exit(1); + } else { + /* force end of parsing */ + yylval.Integer = 0; + return 0; + } + } + token = T_U_int; + goto normal_return; + } else if (is_double(yytext)) { + yylval_was_set = TRUE; + errno = 0; + if ((yylval.Double = atof(yytext)) == 0 && errno == ERANGE) { + msyslog(LOG_ERR, + "Double too large to represent: %s", + yytext); + exit(1); + } else { + token = T_Double; + goto normal_return; + } + } else { + /* Default: Everything is a string */ + yylval_was_set = TRUE; + token = create_string_token(yytext); + goto normal_return; + } + } + + /* + * Either followedby is not FOLLBY_TOKEN or this lexeme is part + * of a string. Hence, we need to return T_String. + * + * _Except_ we might have a -4 or -6 flag on a an association + * configuration line (server, peer, pool, etc.). + * + * This is a terrible hack, but the grammar is ambiguous so we + * don't have a choice. [SK] + * + * The ambiguity is in the keyword scanner, not ntp_parser.y. + * We do not require server addresses be quoted in ntp.conf, + * complicating the scanner's job. To avoid trying (and + * failing) to match an IP address or DNS name to a keyword, + * the association keywords use FOLLBY_STRING in the keyword + * table, which tells the scanner to force the next token to be + * a T_String, so it does not try to match a keyword but rather + * expects a string when -4/-6 modifiers to server, peer, etc. + * are encountered. + * restrict -4 and restrict -6 parsing works correctly without + * this hack, as restrict uses FOLLBY_TOKEN. [DH] + */ + if ('-' == yytext[0]) { + if ('4' == yytext[1]) { + token = T_Ipv4_flag; + goto normal_return; + } else if ('6' == yytext[1]) { + token = T_Ipv6_flag; + goto normal_return; + } + } + + instring = FALSE; + if (FOLLBY_STRING == followedby) + followedby = FOLLBY_TOKEN; + + yylval_was_set = TRUE; + token = create_string_token(yytext); + +normal_return: + if (T_EOC == token) + DPRINTF(4,("\t\n")); + else + DPRINTF(4, ("yylex: lexeme '%s' -> %s\n", yytext, + token_name(token))); + + if (!yylval_was_set) + yylval.Integer = token; + + return token; + +lex_too_long: + yytext[min(sizeof(yytext) - 1, 50)] = 0; + msyslog(LOG_ERR, + "configuration item on line %d longer than limit of %lu, began with '%s'", + lex_stack->curpos.nline, (u_long)min(sizeof(yytext) - 1, 50), + yytext); + + /* + * If we hit the length limit reading the startup configuration + * file, abort. + */ + if (lex_from_file()) + exit(sizeof(yytext) - 1); + + /* + * If it's runtime configuration via ntpq :config treat it as + * if the configuration text ended before the too-long lexeme, + * hostname, or string. + */ + yylval.Integer = 0; + return 0; +} diff --git a/contrib/ntp/ntpd/ntp_scanner.h b/contrib/ntp/ntpd/ntp_scanner.h new file mode 100644 index 000000000..11bbfe914 --- /dev/null +++ b/contrib/ntp/ntpd/ntp_scanner.h @@ -0,0 +1,142 @@ +/* ntp_scanner.h + * + * The header file for a simple lexical analyzer. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + */ + +#ifndef NTP_SCANNER_H +#define NTP_SCANNER_H + +#include "ntp_config.h" + +/* + * ntp.conf syntax is slightly irregular in that some tokens such as + * hostnames do not require quoting even if they might otherwise be + * recognized as T_ terminal tokens. This hand-crafted lexical scanner + * uses a "followed by" value associated with each keyword to indicate + * normal scanning of the next token, forced scanning of the next token + * alone as a T_String, or forced scanning of all tokens to the end of + * the command as T_String. + * In the past the identifiers for this functionality ended in _ARG: + * + * NO_ARG -> FOLLBY_TOKEN + * SINGLE_ARG -> FOLLBY_STRING + * MULTIPLE_ARG -> FOLLBY_STRINGS_TO_EOC + * + * Note that some tokens use FOLLBY_TOKEN even though they sometimes + * are followed by strings. FOLLBY_STRING is used only when needed to + * avoid the keyword scanner matching a token where a string is needed. + * + * FOLLBY_NON_ACCEPT is an overloading of this field to distinguish + * non-accepting states (where the state number does not match a T_ + * value). + */ +typedef enum { + FOLLBY_TOKEN = 0, + FOLLBY_STRING, + FOLLBY_STRINGS_TO_EOC, + FOLLBY_NON_ACCEPTING +} follby; + +#define MAXLINE 1024 /* maximum length of line */ +#define MAXINCLUDELEVEL 5 /* maximum include file levels */ + +/* STRUCTURES + * ---------- + */ + +/* + * Define a structure to hold the FSA for the keywords. + * The structure is actually a trie. + * + * To save space, a single u_int32 encodes four fields, and a fifth + * (the token completed for terminal states) is implied by the index of + * the rule within the scan state array, taking advantage of the fact + * there are more scan states than the highest T_ token number. + * + * The lowest 8 bits hold the character the state matches on. + * Bits 8 and 9 hold the followedby value (0 - 3). For non-accepting + * states (which do not match a completed token) the followedby + * value 3 (FOLLBY_NONACCEPTING) denotes that fact. For accepting + * states, values 0 - 2 control whether the scanner forces the + * following token(s) to strings. + * Bits 10 through 20 hold the next state to check not matching + * this state's character. + * Bits 21 through 31 hold the next state to check matching the char. + */ + +#define S_ST(ch, fb, match_n, other_n) ( \ + (u_char)((ch) & 0xff) | \ + ((u_int32)(fb) << 8) | \ + ((u_int32)(match_n) << 10) | \ + ((u_int32)(other_n) << 21) \ +) + +#define SS_CH(ss) ((char)(u_char)((ss) & 0xff)) +#define SS_FB(ss) (((u_int)(ss) >> 8) & 0x3) +#define SS_MATCH_N(ss) (((u_int)(ss) >> 10) & 0x7ff) +#define SS_OTHER_N(ss) (((u_int)(ss) >> 21) & 0x7ff) + +typedef u_int32 scan_state; + +struct LCPOS { + int nline; + int ncol; +}; + +/* Structure to hold a filename, file pointer and positional info. + * Instances are dynamically allocated, and the file name is copied by + * value into a dynamic extension of the 'fname' array. (Which *must* be + * the last field for that reason!) + */ +struct FILE_INFO { + struct FILE_INFO * st_next; /* next on stack */ + FILE * fpi; /* File Descriptor */ + int force_eof; /* locked or not */ + int backch; /* ungetch buffer */ + + struct LCPOS curpos; /* current scan position */ + struct LCPOS bakpos; /* last line end for ungetc */ + struct LCPOS tokpos; /* current token position */ + struct LCPOS errpos; /* error position */ + + char fname[1]; /* (formal only) buffered name */ +}; + + +/* SCANNER GLOBAL VARIABLES + * ------------------------ + */ +extern config_tree cfgt; /* Parser output stored here */ + +/* VARIOUS EXTERNAL DECLARATIONS + * ----------------------------- + */ +extern int old_config_style; + +/* VARIOUS SUBROUTINE DECLARATIONS + * ------------------------------- + */ +extern const char *keyword(int token); +extern char *quote_if_needed(char *str); +int yylex(void); + +/* managing the input source stack itself */ +extern int/*BOOL*/ lex_init_stack(const char * path, const char * mode); +extern void lex_drop_stack(void); +extern int/*BOOL*/ lex_flush_stack(void); + +/* add/remove a nested input source */ +extern int/*BOOL*/ lex_push_file(const char * path, const char * mode); +extern int/*BOOL*/ lex_pop_file(void); + +/* input stack state query functions */ +extern size_t lex_level(void); +extern int/*BOOL*/ lex_from_file(void); +extern struct FILE_INFO * lex_current(void); + +#endif /* NTP_SCANNER_H */ diff --git a/contrib/ntp/ntpd/ntp_signd.c b/contrib/ntp/ntpd/ntp_signd.c new file mode 100644 index 000000000..2ba11d086 --- /dev/null +++ b/contrib/ntp/ntpd/ntp_signd.c @@ -0,0 +1,239 @@ +/* Copyright 2008, Red Hat, Inc. + Copyright 2008, Andrew Tridgell. + Licenced under the same terms as NTP itself. + */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#ifdef HAVE_NTP_SIGND + +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_stdlib.h" +#include "ntp_unixtime.h" +#include "ntp_control.h" +#include "ntp_string.h" + +#include +#include +#ifdef HAVE_LIBSCF_H +#include +#include +#endif /* HAVE_LIBSCF_H */ + +#include + +/* socket routines by tridge - from junkcode.samba.org */ + +/* + connect to a unix domain socket +*/ +static int +ux_socket_connect(const char *name) +{ + int fd; + struct sockaddr_un addr; + if (!name) { + return -1; + } + + ZERO(addr); + addr.sun_family = AF_UNIX; + strlcpy(addr.sun_path, name, sizeof(addr.sun_path)); + + fd = socket(AF_UNIX, SOCK_STREAM, 0); + if (fd == -1) { + return -1; + } + + if (connect(fd, (struct sockaddr *)&addr, sizeof(addr)) == -1) { + close(fd); + return -1; + } + + return fd; +} + + +/* + keep writing until its all sent +*/ +static int +write_all(int fd, const void *buf, size_t len) +{ + size_t total = 0; + while (len) { + int n = write(fd, buf, len); + if (n <= 0) return total; + buf = n + (char *)buf; + len -= n; + total += n; + } + return total; +} + +/* + keep reading until its all read +*/ +static int +read_all(int fd, void *buf, size_t len) +{ + size_t total = 0; + while (len) { + int n = read(fd, buf, len); + if (n <= 0) return total; + buf = n + (char *)buf; + len -= n; + total += n; + } + return total; +} + +/* + send a packet in length prefix format +*/ +static int +send_packet(int fd, const char *buf, uint32_t len) +{ + uint32_t net_len = htonl(len); + if (write_all(fd, &net_len, sizeof(net_len)) != sizeof(net_len)) return -1; + if (write_all(fd, buf, len) != len) return -1; + return 0; +} + +/* + receive a packet in length prefix format +*/ +static int +recv_packet(int fd, char **buf, uint32_t *len) +{ + if (read_all(fd, len, sizeof(*len)) != sizeof(*len)) return -1; + *len = ntohl(*len); + (*buf) = emalloc(*len); + if (read_all(fd, *buf, *len) != *len) { + free(*buf); + return -1; + } + return 0; +} + +void +send_via_ntp_signd( + struct recvbuf *rbufp, /* receive packet pointer */ + int xmode, + keyid_t xkeyid, + int flags, + struct pkt *xpkt + ) +{ + + /* We are here because it was detected that the client + * sent an all-zero signature, and we therefore know + * it's windows trying to talk to an AD server + * + * Because we don't want to dive into Samba's secrets + * database just to find the long-term kerberos key + * that is re-used as the NTP key, we instead hand the + * packet over to Samba to sign, and return to us. + * + * The signing method Samba will use is described by + * Microsoft in MS-SNTP, found here: + * http://msdn.microsoft.com/en-us/library/cc212930.aspx + */ + + int fd, sendlen; + struct samba_key_in { + uint32_t version; + uint32_t op; + uint32_t packet_id; + uint32_t key_id_le; + struct pkt pkt; + } samba_pkt; + + struct samba_key_out { + uint32_t version; + uint32_t op; + uint32_t packet_id; + struct pkt pkt; + } samba_reply; + + char full_socket[256]; + + char *reply = NULL; + uint32_t reply_len; + + ZERO(samba_pkt); + samba_pkt.op = 0; /* Sign message */ + /* This will be echoed into the reply - a different + * impelementation might want multiple packets + * awaiting signing */ + + samba_pkt.packet_id = 1; + + /* Swap the byte order back - it's actually little + * endian on the wire, but it was read above as + * network byte order */ + samba_pkt.key_id_le = htonl(xkeyid); + samba_pkt.pkt = *xpkt; + + snprintf(full_socket, sizeof(full_socket), "%s/socket", ntp_signd_socket); + + fd = ux_socket_connect(full_socket); + /* Only continue with this if we can talk to Samba */ + if (fd != -1) { + /* Send old packet to Samba, expect response */ + /* Packet to Samba is quite simple: + All values BIG endian except key ID as noted + [packet size as BE] - 4 bytes + [protocol version (0)] - 4 bytes + [packet ID] - 4 bytes + [operation (sign message=0)] - 4 bytes + [key id] - LITTLE endian (as on wire) - 4 bytes + [message to sign] - as marshalled, without signature + */ + + if (send_packet(fd, (char *)&samba_pkt, offsetof(struct samba_key_in, pkt) + LEN_PKT_NOMAC) != 0) { + /* Huh? could not talk to Samba... */ + close(fd); + return; + } + + if (recv_packet(fd, &reply, &reply_len) != 0) { + if (reply) { + free(reply); + } + close(fd); + return; + } + /* Return packet is also simple: + [packet size] - network byte order - 4 bytes + [protocol version (0)] network byte order - - 4 bytes + [operation (signed success=3, failure=4)] network byte order - - 4 byte + (optional) [signed message] - as provided before, with signature appended + */ + + if (reply_len <= sizeof(samba_reply)) { + memcpy(&samba_reply, reply, reply_len); + if (ntohl(samba_reply.op) == 3 && reply_len > offsetof(struct samba_key_out, pkt)) { + sendlen = reply_len - offsetof(struct samba_key_out, pkt); + xpkt = &samba_reply.pkt; + sendpkt(&rbufp->recv_srcadr, rbufp->dstadr, 0, xpkt, sendlen); +#ifdef DEBUG + if (debug) + printf( + "transmit ntp_signd packet: at %ld %s->%s mode %d keyid %08x len %d\n", + current_time, ntoa(&rbufp->dstadr->sin), + ntoa(&rbufp->recv_srcadr), xmode, xkeyid, sendlen); +#endif + } + } + + if (reply) { + free(reply); + } + close(fd); + + } +} +#endif diff --git a/contrib/ntp/ntpd/ntp_timer.c b/contrib/ntp/ntpd/ntp_timer.c index 812206ad2..828aa8c27 100644 --- a/contrib/ntp/ntpd/ntp_timer.c +++ b/contrib/ntp/ntpd/ntp_timer.c @@ -8,6 +8,13 @@ #include "ntp_machine.h" #include "ntpd.h" #include "ntp_stdlib.h" +#include "ntp_calendar.h" +#include "ntp_leapsec.h" + +#if defined(HAVE_IO_COMPLETION_PORT) +# include "ntp_iocompletionport.h" +# include "ntp_timer.h" +#endif #include #include @@ -18,51 +25,73 @@ # include #endif -#if defined(HAVE_IO_COMPLETION_PORT) -# include "ntp_iocompletionport.h" -# include "ntp_timer.h" +#ifdef KERNEL_PLL +#include "ntp_syscall.h" +#endif /* KERNEL_PLL */ + +#ifdef AUTOKEY +#include +#endif /* AUTOKEY */ + + +/* TC_ERR represents the timer_create() error return value. */ +#ifdef SYS_VXWORKS +#define TC_ERR ERROR +#else +#define TC_ERR (-1) #endif + +static void check_leapsec(u_int32, const time_t*, int/*BOOL*/); + /* - * These routines provide support for the event timer. The timer is + * These routines provide support for the event timer. The timer is * implemented by an interrupt routine which sets a flag once every - * 2**EVENT_TIMEOUT seconds (currently 4), and a timer routine which - * is called when the mainline code gets around to seeing the flag. - * The timer routine dispatches the clock adjustment code if its time - * has come, then searches the timer queue for expiries which are - * dispatched to the transmit procedure. Finally, we call the hourly - * procedure to do cleanup and print a message. + * second, and a timer routine which is called when the mainline code + * gets around to seeing the flag. The timer routine dispatches the + * clock adjustment code if its time has come, then searches the timer + * queue for expiries which are dispatched to the transmit procedure. + * Finally, we call the hourly procedure to do cleanup and print a + * message. */ +volatile int interface_interval; /* init_io() sets def. 300s */ -volatile int interface_interval = 300; /* update interface every 5 minutes as default */ - /* - * Alarm flag. The mainline code imports this. + * Initializing flag. All async routines watch this and only do their + * thing when it is clear. + */ +int initializing; + +/* + * Alarm flag. The mainline code imports this. */ volatile int alarm_flag; /* - * The counters + * The counters and timeouts */ -static u_long adjust_timer; /* second timer */ -static u_long keys_timer; /* minute timer */ -static u_long stats_timer; /* stats timer */ -static u_long huffpuff_timer; /* huff-n'-puff timer */ -static u_long interface_timer; /* interface update timer */ -#ifdef OPENSSL -static u_long revoke_timer; /* keys revoke timer */ -u_char sys_revoke = KEY_REVOKE; /* keys revoke timeout (log2 s) */ -#endif /* OPENSSL */ +static u_long interface_timer; /* interface update timer */ +static u_long adjust_timer; /* second timer */ +static u_long stats_timer; /* stats timer */ +static u_long leapf_timer; /* Report leapfile problems once/day */ +static u_long huffpuff_timer; /* huff-n'-puff timer */ +static u_long worker_idle_timer;/* next check for idle intres */ +u_long leapsec; /* seconds to next leap (proximity class) */ +int leapdif; /* TAI difference step at next leap second*/ +u_long orphwait; /* orphan wait time */ +#ifdef AUTOKEY +static u_long revoke_timer; /* keys revoke timer */ +static u_long keys_timer; /* session key timer */ +u_long sys_revoke = KEY_REVOKE; /* keys revoke timeout (log2 s) */ +u_long sys_automax = NTP_AUTOMAX; /* key list timeout (log2 s) */ +#endif /* AUTOKEY */ /* * Statistics counter for the interested. */ volatile u_long alarm_overflow; -#define MINUTE 60 -#define HOUR (60*60) - -u_long current_time; +u_long current_time; /* seconds since startup */ /* * Stats. Number of overflows and number of calls to transmit(). @@ -76,82 +105,98 @@ static int vmstimer[2]; /* time for next timer AST */ static int vmsinc[2]; /* timer increment */ #endif /* VMS */ -#if defined SYS_WINNT -static HANDLE WaitableTimerHandle = NULL; +#ifdef SYS_WINNT +HANDLE WaitableTimerHandle; #else -static RETSIGTYPE alarming P((int)); +static RETSIGTYPE alarming (int); #endif /* SYS_WINNT */ #if !defined(VMS) # if !defined SYS_WINNT || defined(SYS_CYGWIN32) -# ifndef HAVE_TIMER_SETTIME - struct itimerval itimer; -# else - static timer_t ntpd_timerid; - struct itimerspec itimer; -# endif /* HAVE_TIMER_SETTIME */ -# endif /* SYS_WINNT */ -#endif /* VMS */ +# ifdef HAVE_TIMER_CREATE +static timer_t timer_id; +typedef struct itimerspec intervaltimer; +# define itv_frac tv_nsec +# else +typedef struct itimerval intervaltimer; +# define itv_frac tv_usec +# endif +intervaltimer itimer; +# endif +#endif + +#if !defined(SYS_WINNT) && !defined(VMS) +void set_timer_or_die(const intervaltimer *); +#endif + + +#if !defined(SYS_WINNT) && !defined(VMS) +void +set_timer_or_die( + const intervaltimer * ptimer + ) +{ + const char * setfunc; + int rc; + +# ifdef HAVE_TIMER_CREATE + setfunc = "timer_settime"; + rc = timer_settime(timer_id, 0, &itimer, NULL); +# else + setfunc = "setitimer"; + rc = setitimer(ITIMER_REAL, &itimer, NULL); +# endif + if (-1 == rc) { + msyslog(LOG_ERR, "interval timer %s failed, %m", + setfunc); + exit(1); + } +} +#endif /* !SYS_WINNT && !VMS */ + /* - * reinit_timer - reinitialize interval timer. + * reinit_timer - reinitialize interval timer after a clock step. */ -void +void reinit_timer(void) { #if !defined(SYS_WINNT) && !defined(VMS) -# if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) - timer_gettime(ntpd_timerid, &itimer); - if (itimer.it_value.tv_sec < 0 || itimer.it_value.tv_sec > (1< (1< (1 << EVENT_TIMEOUT)) + itimer.it_value.tv_sec = (1 << EVENT_TIMEOUT); + if (itimer.it_value.itv_frac < 0) + itimer.it_value.itv_frac = 0; + if (0 == itimer.it_value.tv_sec && + 0 == itimer.it_value.itv_frac) + itimer.it_value.tv_sec = (1 << EVENT_TIMEOUT); + itimer.it_interval.tv_sec = (1 << EVENT_TIMEOUT); + itimer.it_interval.itv_frac = 0; + set_timer_or_die(&itimer); # endif /* VMS */ } + /* * init_timer - initialize the timer data structures */ void init_timer(void) { -# if defined SYS_WINNT & !defined(SYS_CYGWIN32) - HANDLE hToken = INVALID_HANDLE_VALUE; - TOKEN_PRIVILEGES tkp; -# endif /* SYS_WINNT */ - /* * Initialize... */ - alarm_flag = 0; + alarm_flag = FALSE; alarm_overflow = 0; adjust_timer = 1; - stats_timer = 0; + stats_timer = SECSPERHR; + leapf_timer = SECSPERDAY; huffpuff_timer = 0; interface_timer = 0; current_time = 0; @@ -159,36 +204,25 @@ init_timer(void) timer_xmtcalls = 0; timer_timereset = 0; -#if !defined(SYS_WINNT) +#ifndef SYS_WINNT /* * Set up the alarm interrupt. The first comes 2**EVENT_TIMEOUT * seconds from now and they continue on every 2**EVENT_TIMEOUT * seconds. */ -# if !defined(VMS) -# if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) - if (timer_create (CLOCK_REALTIME, NULL, &ntpd_timerid) == -# ifdef SYS_VXWORKS - ERROR -# else - -1 -# endif - ) - { - fprintf (stderr, "timer create FAILED\n"); - exit (0); +# ifndef VMS +# ifdef HAVE_TIMER_CREATE + if (TC_ERR == timer_create(CLOCK_REALTIME, NULL, &timer_id)) { + msyslog(LOG_ERR, "timer_create failed, %m"); + exit(1); } - (void) signal_no_reset(SIGALRM, alarming); - itimer.it_interval.tv_sec = itimer.it_value.tv_sec = (1<next; - if (peer->flags & FLAG_REFCLOCK) - refclock_timer(peer); - } + for (p = peer_list; p != NULL; p = next_peer) { + next_peer = p->p_link; + if (FLAG_REFCLOCK & p->flags) + refclock_timer(p); } #endif /* REFCLOCK */ } /* - * Now dispatch any peers whose event timer has expired. Be careful - * here, since the peer structure might go away as the result of - * the call. + * Now dispatch any peers whose event timer has expired. Be + * careful here, since the peer structure might go away as the + * result of the call. */ - for (n = 0; n < NTP_HASH_SIZE; n++) { - for (peer = peer_hash[n]; peer != 0; peer = next_peer) { - next_peer = peer->next; - if (peer->action && peer->nextaction <= current_time) - peer->action(peer); - if (peer->nextdate <= current_time) { + for (p = peer_list; p != NULL; p = next_peer) { + next_peer = p->p_link; + + /* + * Restrain the non-burst packet rate not more + * than one packet every 16 seconds. This is + * usually tripped using iburst and minpoll of + * 128 s or less. + */ + if (p->throttle > 0) + p->throttle--; + if (p->nextdate <= current_time) { #ifdef REFCLOCK - if (peer->flags & FLAG_REFCLOCK) - refclock_transmit(peer); - else - transmit(peer); -#else /* REFCLOCK */ - transmit(peer); -#endif /* REFCLOCK */ - } + if (FLAG_REFCLOCK & p->flags) + refclock_transmit(p); + else +#endif /* REFCLOCK */ + transmit(p); } } /* - * Garbage collect expired keys. + * Orphan mode is active when enabled and when no servers less + * than the orphan stratum are available. A server with no other + * synchronization source is an orphan. It shows offset zero and + * reference ID the loopback address. */ - if (keys_timer <= current_time) { - keys_timer += MINUTE; - auth_agekeys(); + if (sys_orphan < STRATUM_UNSPEC && sys_peer == NULL && + current_time > orphwait) { + if (sys_leap == LEAP_NOTINSYNC) { + set_sys_leap(LEAP_NOWARNING); +#ifdef AUTOKEY + if (crypto_flags) + crypto_update(); +#endif /* AUTOKEY */ + } + sys_stratum = (u_char)sys_orphan; + if (sys_stratum > 1) + sys_refid = htonl(LOOPBACKADR); + else + memcpy(&sys_refid, "LOOP", 4); + sys_offset = 0; + sys_rootdelay = 0; + sys_rootdisp = 0; + } + + get_systime(&now); + time(&tnow); + + /* + * Leapseconds. Get time and defer to worker if either something + * is imminent or every 8th second. + */ + if (leapsec > LSPROX_NOWARN || 0 == (current_time & 7)) + check_leapsec(now.l_ui, &tnow, + (sys_leap == LEAP_NOTINSYNC)); + if (sys_leap != LEAP_NOTINSYNC) { + if (leapsec >= LSPROX_ANNOUNCE && leapdif) { + if (leapdif > 0) + set_sys_leap(LEAP_ADDSECOND); + else + set_sys_leap(LEAP_DELSECOND); + } else { + set_sys_leap(LEAP_NOWARNING); + } } /* - * Huff-n'-puff filter + * Update huff-n'-puff filter. */ if (huffpuff_timer <= current_time) { huffpuff_timer += HUFFPUFF; huffpuff(); } -#ifdef OPENSSL +#ifdef AUTOKEY /* - * Garbage collect old keys and generate new private value + * Garbage collect expired keys. */ - if (revoke_timer <= current_time) { - revoke_timer += RANDPOLL(sys_revoke); - expire_all(); - sprintf(statstr, "refresh ts %u", ntohl(hostval.tstamp)); - record_crypto_stats(NULL, statstr); -#ifdef DEBUG - if (debug) - printf("timer: %s\n", statstr); -#endif + if (keys_timer <= current_time) { + keys_timer += 1 << sys_automax; + auth_agekeys(); } -#endif /* OPENSSL */ /* - * interface update timer + * Generate new private value. This causes all associations + * to regenerate cookies. */ - if (interface_interval && interface_timer <= current_time) { + if (revoke_timer && revoke_timer <= current_time) { + revoke_timer += 1 << sys_revoke; + RAND_bytes((u_char *)&sys_private, 4); + } +#endif /* AUTOKEY */ - timer_interfacetimeout(current_time + interface_interval); - DPRINTF(1, ("timer: interface update\n")); + /* + * Interface update timer + */ + if (interface_interval && interface_timer <= current_time) { + timer_interfacetimeout(current_time + + interface_interval); + DPRINTF(2, ("timer: interface update\n")); interface_update(NULL, NULL); } - + + if (worker_idle_timer && worker_idle_timer <= current_time) + worker_idle_timer_fired(); + /* - * Finally, periodically write stats. + * Finally, write hourly stats and do the hourly + * and daily leapfile checks. */ if (stats_timer <= current_time) { - if (stats_timer != 0) - write_stats(); - stats_timer += stats_write_period; + stats_timer += SECSPERHR; + write_stats(); + if (leapf_timer <= current_time) { + leapf_timer += SECSPERDAY; + check_leap_file(TRUE, now.l_ui, &tnow); + } else { + check_leap_file(FALSE, now.l_ui, &tnow); + } } } @@ -369,24 +451,40 @@ alarming( int sig ) { -#if !defined(VMS) - if (initializing) - return; - if (alarm_flag) - alarm_overflow++; - else - alarm_flag++; -#else /* VMS AST routine */ +# ifdef DEBUG + const char *msg = "alarming: initializing TRUE\n"; +# endif + if (!initializing) { - if (alarm_flag) alarm_overflow++; - else alarm_flag = 1; /* increment is no good */ + if (alarm_flag) { + alarm_overflow++; +# ifdef DEBUG + msg = "alarming: overflow\n"; +# endif + } else { +# ifndef VMS + alarm_flag++; +# else + /* VMS AST routine, increment is no good */ + alarm_flag = 1; +# endif +# ifdef DEBUG + msg = "alarming: normal\n"; +# endif + } } - lib$addx(&vmsinc,&vmstimer,&vmstimer); - sys$setimr(0,&vmstimer,alarming,alarming,0); -#endif /* VMS */ +# ifdef VMS + lib$addx(&vmsinc, &vmstimer, &vmstimer); + sys$setimr(0, &vmstimer, alarming, alarming, 0); +# endif +# ifdef DEBUG + if (debug >= 4) + (void)(-1 == write(1, msg, strlen(msg))); +# endif } #endif /* SYS_WINNT */ + void timer_interfacetimeout(u_long timeout) { @@ -405,3 +503,200 @@ timer_clr_stats(void) timer_timereset = current_time; } + +static void +check_leap_sec_in_progress( const leap_result_t *lsdata ) { + int prv_leap_sec_in_progress = leap_sec_in_progress; + leap_sec_in_progress = lsdata->tai_diff && (lsdata->ddist < 3); + + /* if changed we may have to update the leap status sent to clients */ + if (leap_sec_in_progress != prv_leap_sec_in_progress) + set_sys_leap(sys_leap); +} + + +static void +check_leapsec( + u_int32 now , + const time_t * tpiv , + int/*BOOL*/ reset) +{ + static const char leapmsg_p_step[] = + "Positive leap second, stepped backward."; + static const char leapmsg_p_slew[] = + "Positive leap second, no step correction. " + "System clock will be inaccurate for a long time."; + + static const char leapmsg_n_step[] = + "Negative leap second, stepped forward."; + static const char leapmsg_n_slew[] = + "Negative leap second, no step correction. " + "System clock will be inaccurate for a long time."; + + leap_result_t lsdata; + u_int32 lsprox; +#ifdef AUTOKEY + int/*BOOL*/ update_autokey = FALSE; +#endif + +#ifndef SYS_WINNT /* WinNT port has its own leap second handling */ +# ifdef KERNEL_PLL + leapsec_electric(pll_control && kern_enable); +# else + leapsec_electric(0); +# endif +#endif +#ifdef LEAP_SMEAR + leap_smear.enabled = leap_smear_intv != 0; +#endif + if (reset) { + lsprox = LSPROX_NOWARN; + leapsec_reset_frame(); + memset(&lsdata, 0, sizeof(lsdata)); + } else { + int fired = leapsec_query(&lsdata, now, tpiv); + + DPRINTF(1, ("*** leapsec_query: fired %i, now %u (0x%08X), tai_diff %i, ddist %u\n", + fired, now, now, lsdata.tai_diff, lsdata.ddist)); + +#ifdef LEAP_SMEAR + leap_smear.in_progress = 0; + leap_smear.doffset = 0.0; + + if (leap_smear.enabled) { + if (lsdata.tai_diff) { + if (leap_smear.interval == 0) { + leap_smear.interval = leap_smear_intv; + leap_smear.intv_end = lsdata.ttime.Q_s; + leap_smear.intv_start = leap_smear.intv_end - leap_smear.interval; + DPRINTF(1, ("*** leapsec_query: setting leap_smear interval %li, begin %.0f, end %.0f\n", + leap_smear.interval, leap_smear.intv_start, leap_smear.intv_end)); + } + } + else { + if (leap_smear.interval) + DPRINTF(1, ("*** leapsec_query: clearing leap_smear interval\n")); + leap_smear.interval = 0; + } + + if (leap_smear.interval) { + double dtemp = now; + if (dtemp >= leap_smear.intv_start && dtemp <= leap_smear.intv_end) { + double leap_smear_time = dtemp - leap_smear.intv_start; + /* + * For now we just do a linear interpolation over the smear interval + */ +#if 0 + // linear interpolation + leap_smear.doffset = -(leap_smear_time * lsdata.tai_diff / leap_smear.interval); +#else + // Google approach: lie(t) = (1.0 - cos(pi * t / w)) / 2.0 + leap_smear.doffset = -((double) lsdata.tai_diff - cos( M_PI * leap_smear_time / leap_smear.interval)) / 2.0; +#endif + /* + * TODO see if we're inside an inserted leap second, so we need to compute + * leap_smear.doffset = 1.0 - leap_smear.doffset + */ + leap_smear.in_progress = 1; +#if 0 && defined( DEBUG ) + msyslog(LOG_NOTICE, "*** leapsec_query: [%.0f:%.0f] (%li), now %u (%.0f), smear offset %.6f ms\n", + leap_smear.intv_start, leap_smear.intv_end, leap_smear.interval, + now, leap_smear_time, leap_smear.doffset); +#else + DPRINTF(1, ("*** leapsec_query: [%.0f:%.0f] (%li), now %u (%.0f), smear offset %.6f ms\n", + leap_smear.intv_start, leap_smear.intv_end, leap_smear.interval, + now, leap_smear_time, leap_smear.doffset)); +#endif + + } + } + } + else + leap_smear.interval = 0; + + /* + * Update the current leap smear offset, eventually 0.0 if outside smear interval. + */ + DTOLFP(leap_smear.doffset, &leap_smear.offset); + +#endif /* LEAP_SMEAR */ + + if (fired) { + /* Full hit. Eventually step the clock, but always + * announce the leap event has happened. + */ + const char *leapmsg = NULL; + if (lsdata.warped < 0) { + if (clock_max_back > 0.0 && + clock_max_back < fabs(lsdata.warped)) { + step_systime(lsdata.warped); + leapmsg = leapmsg_p_step; + } else { + leapmsg = leapmsg_p_slew; + } + } else if (lsdata.warped > 0) { + if (clock_max_fwd > 0.0 && + clock_max_fwd < fabs(lsdata.warped)) { + step_systime(lsdata.warped); + leapmsg = leapmsg_n_step; + } else { + leapmsg = leapmsg_n_slew; + } + } + if (leapmsg) + msyslog(LOG_NOTICE, "%s", leapmsg); + report_event(EVNT_LEAP, NULL, NULL); +#ifdef AUTOKEY + update_autokey = TRUE; +#endif + lsprox = LSPROX_NOWARN; + leapsec = LSPROX_NOWARN; + sys_tai = lsdata.tai_offs; + } else { +#ifdef AUTOKEY + update_autokey = (sys_tai != lsdata.tai_offs); +#endif + lsprox = lsdata.proximity; + sys_tai = lsdata.tai_offs; + } + } + + /* We guard against panic alarming during the red alert phase. + * Strange and evil things might happen if we go from stone cold + * to piping hot in one step. If things are already that wobbly, + * we let the normal clock correction take over, even if a jump + * is involved. + * Also make sure the alarming events are edge-triggered, that is, + * ceated only when the threshold is crossed. + */ + if ( (leapsec > 0 || lsprox < LSPROX_ALERT) + && leapsec < lsprox ) { + if ( leapsec < LSPROX_SCHEDULE + && lsprox >= LSPROX_SCHEDULE) { + if (lsdata.dynamic) + report_event(PEVNT_ARMED, sys_peer, NULL); + else + report_event(EVNT_ARMED, NULL, NULL); + } + leapsec = lsprox; + } + if (leapsec > lsprox) { + if ( leapsec >= LSPROX_SCHEDULE + && lsprox < LSPROX_SCHEDULE) { + report_event(EVNT_DISARMED, NULL, NULL); + } + leapsec = lsprox; + } + + if (leapsec >= LSPROX_SCHEDULE) + leapdif = lsdata.tai_diff; + else + leapdif = 0; + + check_leap_sec_in_progress(&lsdata); + +#ifdef AUTOKEY + if (update_autokey) + crypto_update_taichange(); +#endif +} diff --git a/contrib/ntp/ntpd/ntp_util.c b/contrib/ntp/ntpd/ntp_util.c index 91ff8a64f..c4bc9011a 100644 --- a/contrib/ntp/ntpd/ntp_util.c +++ b/contrib/ntp/ntpd/ntp_util.c @@ -1,17 +1,19 @@ /* * ntp_util.c - stuff I didn't have any other place for */ - #ifdef HAVE_CONFIG_H # include #endif #include "ntpd.h" -#include "ntp_io.h" #include "ntp_unixtime.h" #include "ntp_filegen.h" #include "ntp_if.h" #include "ntp_stdlib.h" +#include "ntp_assert.h" +#include "ntp_calendar.h" +#include "ntp_leapsec.h" +#include "lib_strbuf.h" #include #include @@ -19,6 +21,10 @@ #ifdef HAVE_SYS_IOCTL_H # include #endif +#ifdef HAVE_UNISTD_H +# include +#endif +#include #ifdef HAVE_IEEEFP_H # include @@ -27,35 +33,35 @@ # include #endif -#ifdef DOSYNCTODR -# if !defined(VMS) -# include -# endif /* VMS */ -#endif - #if defined(VMS) # include #endif /* VMS */ /* - * This contains odds and ends. Right now the only thing you'll find - * in here is the hourly stats printer and some code to support - * rereading the keys file, but I may eventually put other things in - * here such as code to do something with the leap bits. + * Defines used by the leapseconds stuff */ +#define MAX_TAI 100 /* max TAI offset (s) */ +#define L_DAY 86400UL /* seconds per day */ +#define L_YEAR (L_DAY * 365) /* days per year */ +#define L_LYEAR (L_YEAR + L_DAY) /* days per leap year */ +#define L_4YEAR (L_LYEAR + 3 * L_YEAR) /* days per leap cycle */ +#define L_CENT (L_4YEAR * 25) /* days per century */ + /* - * Name of the keys file + * This contains odds and ends, including the hourly stats, various + * configuration items, leapseconds stuff, etc. */ -static char *key_file_name; - /* - * The name of the drift_comp file and the temporary. + * File names */ -static char *stats_drift_file; -static char *stats_temp_file; -int stats_write_period = 3600; /* # of seconds between writes. */ -double stats_write_tolerance = 0; -static double prev_drift_comp = 99999.; +static char *key_file_name; /* keys file name */ +static char *leapfile_name; /* leapseconds file name */ +static struct stat leapfile_stat; /* leapseconds file stat() buffer */ +static int /*BOOL*/have_leapfile = FALSE; +char *stats_drift_file; /* frequency file name */ +static char *stats_temp_file; /* temp frequency file name */ +static double wander_resid; /* last frequency update */ +double wander_threshold = 1e-7; /* initial frequency threshold */ /* * Statistics file stuff @@ -64,27 +70,20 @@ static double prev_drift_comp = 99999.; # ifndef SYS_WINNT # define NTP_VAR "/var/NTP/" /* NOTE the trailing '/' */ # else -# define NTP_VAR "c:\\var\\ntp\\" /* NOTE the trailing '\\' */ +# define NTP_VAR "c:\\var\\ntp\\" /* NOTE the trailing '\\' */ # endif /* SYS_WINNT */ #endif -#ifndef MAXPATHLEN -# define MAXPATHLEN 256 -#endif - -static char statsdir[MAXPATHLEN] = NTP_VAR; +char statsdir[MAXFILENAME] = NTP_VAR; static FILEGEN peerstats; static FILEGEN loopstats; static FILEGEN clockstats; static FILEGEN rawstats; static FILEGEN sysstats; -#ifdef DEBUG_TIMING -static FILEGEN timingstats; -#endif -#ifdef OPENSSL +static FILEGEN protostats; static FILEGEN cryptostats; -#endif /* OPENSSL */ +static FILEGEN timingstats; /* * This controls whether stats are written to the fileset. Provided @@ -93,37 +92,86 @@ static FILEGEN cryptostats; int stats_control; /* - * Initial frequency offset later passed to the loopfilter. + * Last frequency written to file. */ -double old_drift; +static double prev_drift_comp; /* last frequency update */ /* - * init_util - initialize the utilities + * Function prototypes */ -void -init_util(void) -{ - stats_drift_file = 0; - stats_temp_file = 0; - key_file_name = 0; - - filegen_register(&statsdir[0], "peerstats", &peerstats); +static void record_sys_stats(void); + void ntpd_time_stepped(void); +static void check_leap_expiration(int, uint32_t, const time_t*); - filegen_register(&statsdir[0], "loopstats", &loopstats); - - filegen_register(&statsdir[0], "clockstats", &clockstats); +/* + * Prototypes + */ +#ifdef DEBUG +void uninit_util(void); +#endif - filegen_register(&statsdir[0], "rawstats", &rawstats); +/* + * uninit_util - free memory allocated by init_util + */ +#ifdef DEBUG +void +uninit_util(void) +{ +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif + if (stats_drift_file) { + free(stats_drift_file); + free(stats_temp_file); + stats_drift_file = NULL; + stats_temp_file = NULL; + } + if (key_file_name) { + free(key_file_name); + key_file_name = NULL; + } + filegen_unregister("peerstats"); + filegen_unregister("loopstats"); + filegen_unregister("clockstats"); + filegen_unregister("rawstats"); + filegen_unregister("sysstats"); + filegen_unregister("protostats"); +#ifdef AUTOKEY + filegen_unregister("cryptostats"); +#endif /* AUTOKEY */ +#ifdef DEBUG_TIMING + filegen_unregister("timingstats"); +#endif /* DEBUG_TIMING */ - filegen_register(&statsdir[0], "sysstats", &sysstats); +#if defined(_MSC_VER) && defined (_DEBUG) + _CrtCheckMemory(); +#endif +} +#endif /* DEBUG */ -#ifdef OPENSSL - filegen_register(&statsdir[0], "cryptostats", &cryptostats); -#endif /* OPENSSL */ -#ifdef DEBUG_TIMING - filegen_register(&statsdir[0], "timingstats", &timingstats); -#endif +/* + * init_util - initialize the util module of ntpd + */ +void +init_util(void) +{ + filegen_register(statsdir, "peerstats", &peerstats); + filegen_register(statsdir, "loopstats", &loopstats); + filegen_register(statsdir, "clockstats", &clockstats); + filegen_register(statsdir, "rawstats", &rawstats); + filegen_register(statsdir, "sysstats", &sysstats); + filegen_register(statsdir, "protostats", &protostats); + filegen_register(statsdir, "cryptostats", &cryptostats); + filegen_register(statsdir, "timingstats", &timingstats); + /* + * register with libntp ntp_set_tod() to call us back + * when time is stepped. + */ + step_callback = &ntpd_time_stepped; +#ifdef DEBUG + atexit(&uninit_util); +#endif /* DEBUG */ } @@ -133,17 +181,16 @@ init_util(void) void write_stats(void) { - FILE *fp; - + FILE *fp; #ifdef DOSYNCTODR struct timeval tv; #if !defined(VMS) - int prio_set; + int prio_set; #endif #ifdef HAVE_GETCLOCK - struct timespec ts; + struct timespec ts; #endif - int o_prio; + int o_prio; /* * Sometimes having a Sun can be a drag. @@ -163,12 +210,13 @@ write_stats(void) * thing to do. * * CAVEAT: settimeofday() steps the sun clock by about 800 us, - * so setting DOSYNCTODR seems a bad idea in the - * case of us resolution + * so setting DOSYNCTODR seems a bad idea in the + * case of us resolution */ #if !defined(VMS) - /* (prr) getpriority returns -1 on error, but -1 is also a valid + /* + * (prr) getpriority returns -1 on error, but -1 is also a valid * return value (!), so instead we have to zero errno before the * call and check it for non-zero afterwards. */ @@ -192,37 +240,45 @@ write_stats(void) prio_set = 1; /* overdrive */ #endif /* VMS */ #ifdef HAVE_GETCLOCK - (void) getclock(TIMEOFDAY, &ts); - tv.tv_sec = ts.tv_sec; - tv.tv_usec = ts.tv_nsec / 1000; + (void) getclock(TIMEOFDAY, &ts); + tv.tv_sec = ts.tv_sec; + tv.tv_usec = ts.tv_nsec / 1000; #else /* not HAVE_GETCLOCK */ GETTIMEOFDAY(&tv,(struct timezone *)NULL); #endif /* not HAVE_GETCLOCK */ - if (ntp_set_tod(&tv,(struct timezone *)NULL) != 0) { + if (ntp_set_tod(&tv,(struct timezone *)NULL) != 0) msyslog(LOG_ERR, "can't sync battery time: %m"); - } #if !defined(VMS) if (prio_set) setpriority(PRIO_PROCESS, 0, o_prio); /* downshift */ #endif /* VMS */ #endif /* DOSYNCTODR */ - - NLOG(NLOG_SYSSTATIST) - msyslog(LOG_INFO, - "offset %.6f sec freq %.3f ppm error %.6f poll %d", - last_offset, drift_comp * 1e6, sys_jitter, - sys_poll); - - record_sys_stats(); - if ((u_long)(fabs(prev_drift_comp - drift_comp) * 1e9) <= - (u_long)(fabs(stats_write_tolerance * drift_comp) * 1e9)) { - return; - } - prev_drift_comp = drift_comp; if (stats_drift_file != 0) { + + /* + * When the frequency file is written, initialize the + * prev_drift_comp and wander_resid. Thereafter, + * reduce the wander_resid by half each hour. When + * the difference between the prev_drift_comp and + * drift_comp is less than the wander_resid, update + * the frequncy file. This minimizes the file writes to + * nonvolaile storage. + */ +#ifdef DEBUG + if (debug) + printf("write_stats: frequency %.6lf thresh %.6lf, freq %.6lf\n", + (prev_drift_comp - drift_comp) * 1e6, wander_resid * + 1e6, drift_comp * 1e6); +#endif + if (fabs(prev_drift_comp - drift_comp) < wander_resid) { + wander_resid *= 0.5; + return; + } + prev_drift_comp = drift_comp; + wander_resid = wander_threshold; if ((fp = fopen(stats_temp_file, "w")) == NULL) { - msyslog(LOG_ERR, "can't open %s: %m", + msyslog(LOG_ERR, "frequency file %s: %m", stats_temp_file); return; } @@ -230,19 +286,26 @@ write_stats(void) (void)fclose(fp); /* atomic */ #ifdef SYS_WINNT - (void) _unlink(stats_drift_file); /* rename semantics differ under NT */ + if (_unlink(stats_drift_file)) /* rename semantics differ under NT */ + msyslog(LOG_WARNING, + "Unable to remove prior drift file %s, %m", + stats_drift_file); #endif /* SYS_WINNT */ #ifndef NO_RENAME - (void) rename(stats_temp_file, stats_drift_file); + if (rename(stats_temp_file, stats_drift_file)) + msyslog(LOG_WARNING, + "Unable to rename temp drift file %s to %s, %m", + stats_temp_file, stats_drift_file); #else /* we have no rename NFS of ftp in use */ - if ((fp = fopen(stats_drift_file, "w")) == NULL) { - msyslog(LOG_ERR, "can't open %s: %m", + if ((fp = fopen(stats_drift_file, "w")) == + NULL) { + msyslog(LOG_ERR, + "frequency file %s: %m", stats_drift_file); return; } - #endif #if defined(VMS) @@ -250,9 +313,10 @@ write_stats(void) { $DESCRIPTOR(oldvers,";-1"); struct dsc$descriptor driftdsc = { - strlen(stats_drift_file),0,0,stats_drift_file }; - - while(lib$delete_file(&oldvers,&driftdsc) & 1) ; + strlen(stats_drift_file), 0, 0, + stats_drift_file }; + while(lib$delete_file(&oldvers, + &driftdsc) & 1); } #endif } @@ -268,9 +332,17 @@ stats_config( const char *invalue /* only one type so far */ ) { - FILE *fp; + FILE *fp; const char *value; - int len; + int len; + double old_drift; + l_fp now; + time_t ttnow; +#ifndef VMS + const char temp_ext[] = ".TEMP"; +#else + const char temp_ext[] = "-TEMP"; +#endif /* * Expand environment strings under Windows NT, since the @@ -280,170 +352,192 @@ stats_config( char newvalue[MAX_PATH], parameter[MAX_PATH]; if (!ExpandEnvironmentStrings(invalue, newvalue, MAX_PATH)) { - switch(item) { - case STATS_FREQ_FILE: - strcpy(parameter,"STATS_FREQ_FILE"); + switch (item) { + case STATS_FREQ_FILE: + strlcpy(parameter, "STATS_FREQ_FILE", + sizeof(parameter)); break; - case STATS_STATSDIR: - strcpy(parameter,"STATS_STATSDIR"); + + case STATS_LEAP_FILE: + strlcpy(parameter, "STATS_LEAP_FILE", + sizeof(parameter)); + break; + + case STATS_STATSDIR: + strlcpy(parameter, "STATS_STATSDIR", + sizeof(parameter)); break; - case STATS_PID_FILE: - strcpy(parameter,"STATS_PID_FILE"); + + case STATS_PID_FILE: + strlcpy(parameter, "STATS_PID_FILE", + sizeof(parameter)); break; - default: - strcpy(parameter,"UNKNOWN"); + + default: + strlcpy(parameter, "UNKNOWN", + sizeof(parameter)); break; } value = invalue; - msyslog(LOG_ERR, - "ExpandEnvironmentStrings(%s) failed: %m\n", parameter); + "ExpandEnvironmentStrings(%s) failed: %m\n", + parameter); } else { value = newvalue; } -#else +#else value = invalue; #endif /* SYS_WINNT */ - switch(item) { - case STATS_FREQ_FILE: - if (stats_drift_file != 0) { - (void) free(stats_drift_file); - (void) free(stats_temp_file); - stats_drift_file = 0; - stats_temp_file = 0; - } + switch (item) { - if (value == 0 || (len = strlen(value)) == 0) - break; + /* + * Open and read frequency file. + */ + case STATS_FREQ_FILE: + if (!value || (len = strlen(value)) == 0) + break; - stats_drift_file = (char*)emalloc((u_int)(len + 1)); -#if !defined(VMS) - stats_temp_file = (char*)emalloc((u_int)(len + - sizeof(".TEMP"))); -#else - stats_temp_file = (char*)emalloc((u_int)(len + - sizeof("-TEMP"))); -#endif /* VMS */ - memmove(stats_drift_file, value, (unsigned)(len+1)); - memmove(stats_temp_file, value, (unsigned)len); -#if !defined(VMS) - memmove(stats_temp_file + len, ".TEMP", - sizeof(".TEMP")); -#else - memmove(stats_temp_file + len, "-TEMP", - sizeof("-TEMP")); -#endif /* VMS */ + stats_drift_file = erealloc(stats_drift_file, len + 1); + stats_temp_file = erealloc(stats_temp_file, + len + sizeof(".TEMP")); + memcpy(stats_drift_file, value, (size_t)(len+1)); + memcpy(stats_temp_file, value, (size_t)len); + memcpy(stats_temp_file + len, temp_ext, sizeof(temp_ext)); /* * Open drift file and read frequency. If the file is * missing or contains errors, tell the loop to reset. */ - if ((fp = fopen(stats_drift_file, "r")) == NULL) { - old_drift = 1e9; + if ((fp = fopen(stats_drift_file, "r")) == NULL) break; - } + if (fscanf(fp, "%lf", &old_drift) != 1) { - msyslog(LOG_ERR, "Frequency format error in %s", - stats_drift_file); - old_drift = 1e9; + msyslog(LOG_ERR, + "format error frequency file %s", + stats_drift_file); fclose(fp); break; + } fclose(fp); - prev_drift_comp = old_drift / 1e6; - msyslog(LOG_INFO, - "frequency initialized %.3f PPM from %s", - old_drift, stats_drift_file); + loop_config(LOOP_FREQ, old_drift); + prev_drift_comp = drift_comp; break; - - case STATS_STATSDIR: - if (strlen(value) >= sizeof(statsdir)) { + + /* + * Specify statistics directory. + */ + case STATS_STATSDIR: + + /* - 1 since value may be missing the DIR_SEP. */ + if (strlen(value) >= sizeof(statsdir) - 1) { msyslog(LOG_ERR, - "value for statsdir too long (>%d, sigh)", - (int)sizeof(statsdir)-1); + "statsdir too long (>%d, sigh)", + (int)sizeof(statsdir) - 2); } else { - l_fp now; - - get_systime(&now); - strcpy(statsdir,value); - if(peerstats.prefix == &statsdir[0] && - peerstats.fp != NULL) { - fclose(peerstats.fp); - peerstats.fp = NULL; - filegen_setup(&peerstats, now.l_ui); - } - if(loopstats.prefix == &statsdir[0] && - loopstats.fp != NULL) { - fclose(loopstats.fp); - loopstats.fp = NULL; - filegen_setup(&loopstats, now.l_ui); - } - if(clockstats.prefix == &statsdir[0] && - clockstats.fp != NULL) { - fclose(clockstats.fp); - clockstats.fp = NULL; - filegen_setup(&clockstats, now.l_ui); - } - if(rawstats.prefix == &statsdir[0] && - rawstats.fp != NULL) { - fclose(rawstats.fp); - rawstats.fp = NULL; - filegen_setup(&rawstats, now.l_ui); - } - if(sysstats.prefix == &statsdir[0] && - sysstats.fp != NULL) { - fclose(sysstats.fp); - sysstats.fp = NULL; - filegen_setup(&sysstats, now.l_ui); - } -#ifdef OPENSSL - if(cryptostats.prefix == &statsdir[0] && - cryptostats.fp != NULL) { - fclose(cryptostats.fp); - cryptostats.fp = NULL; - filegen_setup(&cryptostats, now.l_ui); - } -#endif /* OPENSSL */ + int add_dir_sep; + int value_l; + + /* Add a DIR_SEP unless we already have one. */ + value_l = strlen(value); + if (0 == value_l) + add_dir_sep = FALSE; + else + add_dir_sep = (DIR_SEP != + value[value_l - 1]); + + if (add_dir_sep) + snprintf(statsdir, sizeof(statsdir), + "%s%c", value, DIR_SEP); + else + snprintf(statsdir, sizeof(statsdir), + "%s", value); + filegen_statsdir(); } break; - case STATS_PID_FILE: + /* + * Open pid file. + */ + case STATS_PID_FILE: if ((fp = fopen(value, "w")) == NULL) { - msyslog(LOG_ERR, "Can't open %s: %m", value); + msyslog(LOG_ERR, "pid file %s: %m", + value); + break; + } + fprintf(fp, "%d", (int)getpid()); + fclose(fp); + break; + + /* + * Read leapseconds file. + * + * Note: Currently a leap file without SHA1 signature is + * accepted, but if there is a signature line, the signature + * must be valid or the file is rejected. + */ + case STATS_LEAP_FILE: + if (!value || (len = strlen(value)) == 0) break; + + leapfile_name = erealloc(leapfile_name, len + 1); + memcpy(leapfile_name, value, len + 1); + + if (leapsec_load_file( + leapfile_name, &leapfile_stat, TRUE, TRUE)) + { + leap_signature_t lsig; + + get_systime(&now); + time(&ttnow); + leapsec_getsig(&lsig); + mprintf_event(EVNT_TAI, NULL, + "%d leap %s %s %s", + lsig.taiof, + fstostr(lsig.ttime), + leapsec_expired(now.l_ui, NULL) + ? "expired" + : "expires", + fstostr(lsig.etime)); + + have_leapfile = TRUE; + + /* force an immediate daily expiration check of + * the leap seconds table + */ + check_leap_expiration(TRUE, now.l_ui, &ttnow); } - fprintf(fp, "%d", (int) getpid()); - fclose(fp);; break; - default: + default: /* oh well */ break; } } + /* * record_peer_stats - write peer statistics to file * * file format: - * day (mjd) + * day (MJD) * time (s past UTC midnight) - * peer (ip address) - * peer status word (hex) - * peer offset (s) - * peer delay (s) - * peer error bound (s) - * peer error (s) + * IP address + * status word (hex) + * offset + * delay + * dispersion + * jitter */ void record_peer_stats( - struct sockaddr_storage *addr, + sockaddr_u *addr, int status, - double offset, - double delay, - double dispersion, - double skew + double offset, /* offset */ + double delay, /* delay */ + double dispersion, /* dispersion */ + double jitter /* jitter */ ) { l_fp now; @@ -458,29 +552,32 @@ record_peer_stats( now.l_ui %= 86400; if (peerstats.fp != NULL) { fprintf(peerstats.fp, - "%lu %s %s %x %.9f %.9f %.9f %.9f\n", - day, ulfptoa(&now, 3), stoa(addr), status, offset, - delay, dispersion, skew); + "%lu %s %s %x %.9f %.9f %.9f %.9f\n", day, + ulfptoa(&now, 3), stoa(addr), status, offset, + delay, dispersion, jitter); fflush(peerstats.fp); } } + /* * record_loop_stats - write loop filter statistics to file * * file format: - * day (mjd) + * day (MJD) * time (s past midnight) - * offset (s) - * frequency (approx ppm) - * time constant (log base 2) + * offset + * frequency (PPM) + * jitter + * wnder (PPM) + * time constant (log2) */ void record_loop_stats( - double offset, - double freq, - double jitter, - double stability, + double offset, /* offset */ + double freq, /* frequency (PPM) */ + double jitter, /* jitter */ + double wander, /* wander (PPM) */ int spoll ) { @@ -497,24 +594,25 @@ record_loop_stats( if (loopstats.fp != NULL) { fprintf(loopstats.fp, "%lu %s %.9f %.3f %.9f %.6f %d\n", day, ulfptoa(&now, 3), offset, freq * 1e6, jitter, - stability * 1e6, spoll); + wander * 1e6, spoll); fflush(loopstats.fp); } } + /* * record_clock_stats - write clock statistics to file * * file format: - * day (mjd) + * day (MJD) * time (s past midnight) - * peer (ip address) + * IP address * text message */ void record_clock_stats( - struct sockaddr_storage *addr, - const char *text + sockaddr_u *addr, + const char *text /* timecode string */ ) { l_fp now; @@ -528,30 +626,64 @@ record_clock_stats( day = now.l_ui / 86400 + MJD_1900; now.l_ui %= 86400; if (clockstats.fp != NULL) { - fprintf(clockstats.fp, "%lu %s %s %s\n", - day, ulfptoa(&now, 3), stoa(addr), text); + fprintf(clockstats.fp, "%lu %s %s %s\n", day, + ulfptoa(&now, 3), stoa(addr), text); fflush(clockstats.fp); } } + +/* + * mprintf_clock_stats - write clock statistics to file with + * msnprintf-style formatting. + */ +int +mprintf_clock_stats( + sockaddr_u *addr, + const char *fmt, + ... + ) +{ + va_list ap; + int rc; + char msg[512]; + + va_start(ap, fmt); + rc = mvsnprintf(msg, sizeof(msg), fmt, ap); + va_end(ap); + if (stats_control) + record_clock_stats(addr, msg); + + return rc; +} + /* * record_raw_stats - write raw timestamps to file * - * * file format + * day (MJD) * time (s past midnight) * peer ip address - * local ip address + * IP address * t1 t2 t3 t4 timestamps */ void record_raw_stats( - struct sockaddr_storage *srcadr, - struct sockaddr_storage *dstadr, - l_fp *t1, - l_fp *t2, - l_fp *t3, - l_fp *t4 + sockaddr_u *srcadr, + sockaddr_u *dstadr, + l_fp *t1, /* originate timestamp */ + l_fp *t2, /* receive timestamp */ + l_fp *t3, /* transmit timestamp */ + l_fp *t4, /* destination timestamp */ + int leap, + int version, + int mode, + int stratum, + int ppoll, + int precision, + double root_delay, /* seconds */ + double root_dispersion,/* seconds */ + u_int32 refid ) { l_fp now; @@ -565,10 +697,13 @@ record_raw_stats( day = now.l_ui / 86400 + MJD_1900; now.l_ui %= 86400; if (rawstats.fp != NULL) { - fprintf(rawstats.fp, "%lu %s %s %s %s %s %s %s\n", - day, ulfptoa(&now, 3), stoa(srcadr), dstadr ? stoa(dstadr) : "-", - ulfptoa(t1, 9), ulfptoa(t2, 9), ulfptoa(t3, 9), - ulfptoa(t4, 9)); + fprintf(rawstats.fp, "%lu %s %s %s %s %s %s %s %d %d %d %d %d %d %.6f %.6f %s\n", + day, ulfptoa(&now, 3), + stoa(srcadr), dstadr ? stoa(dstadr) : "-", + ulfptoa(t1, 9), ulfptoa(t2, 9), + ulfptoa(t3, 9), ulfptoa(t4, 9), + leap, version, mode, stratum, ppoll, precision, + root_delay, root_dispersion, refid_str(refid, stratum)); fflush(rawstats.fp); } } @@ -578,17 +713,19 @@ record_raw_stats( * record_sys_stats - write system statistics to file * * file format + * day (MJD) * time (s past midnight) - * time since startup (hr) + * time since reset * packets recieved - * packets processed + * packets for this host * current version - * previous version - * bad version + * old version * access denied * bad length or format * bad authentication + * declined * rate exceeded + * KoD sent */ void record_sys_stats(void) @@ -604,33 +741,64 @@ record_sys_stats(void) day = now.l_ui / 86400 + MJD_1900; now.l_ui %= 86400; if (sysstats.fp != NULL) { - fprintf(sysstats.fp, - "%lu %s %lu %lu %lu %lu %lu %lu %lu %lu %lu %lu\n", - day, ulfptoa(&now, 3), sys_stattime / 3600, - sys_received, sys_processed, sys_newversionpkt, - sys_oldversionpkt, sys_unknownversion, - sys_restricted, sys_badlength, sys_badauth, - sys_limitrejected); + fprintf(sysstats.fp, + "%lu %s %lu %lu %lu %lu %lu %lu %lu %lu %lu %lu %lu\n", + day, ulfptoa(&now, 3), current_time - sys_stattime, + sys_received, sys_processed, sys_newversion, + sys_oldversion, sys_restricted, sys_badlength, + sys_badauth, sys_declined, sys_limitrejected, + sys_kodsent); fflush(sysstats.fp); proto_clr_stats(); } } -#ifdef OPENSSL +/* + * record_proto_stats - write system statistics to file + * + * file format + * day (MJD) + * time (s past midnight) + * text message + */ +void +record_proto_stats( + char *str /* text string */ + ) +{ + l_fp now; + u_long day; + + if (!stats_control) + return; + + get_systime(&now); + filegen_setup(&protostats, now.l_ui); + day = now.l_ui / 86400 + MJD_1900; + now.l_ui %= 86400; + if (protostats.fp != NULL) { + fprintf(protostats.fp, "%lu %s %s\n", day, + ulfptoa(&now, 3), str); + fflush(protostats.fp); + } +} + + +#ifdef AUTOKEY /* * record_crypto_stats - write crypto statistics to file * * file format: * day (mjd) * time (s past midnight) - * peer (ip address) + * peer ip address * text message */ void record_crypto_stats( - struct sockaddr_storage *addr, - const char *text + sockaddr_u *addr, + const char *text /* text message */ ) { l_fp now; @@ -645,7 +813,7 @@ record_crypto_stats( now.l_ui %= 86400; if (cryptostats.fp != NULL) { if (addr == NULL) - fprintf(cryptostats.fp, "%lu %s %s\n", + fprintf(cryptostats.fp, "%lu %s 0.0.0.0 %s\n", day, ulfptoa(&now, 3), text); else fprintf(cryptostats.fp, "%lu %s %s %s\n", @@ -653,11 +821,12 @@ record_crypto_stats( fflush(cryptostats.fp); } } -#endif /* OPENSSL */ +#endif /* AUTOKEY */ + #ifdef DEBUG_TIMING /* - * record_crypto_stats - write crypto statistics to file + * record_timing_stats - write timing statistics to file * * file format: * day (mjd) @@ -666,7 +835,7 @@ record_crypto_stats( */ void record_timing_stats( - const char *text + const char *text /* text message */ ) { static unsigned int flshcnt; @@ -681,13 +850,81 @@ record_timing_stats( day = now.l_ui / 86400 + MJD_1900; now.l_ui %= 86400; if (timingstats.fp != NULL) { - fprintf(timingstats.fp, "%lu %s %s\n", - day, lfptoa(&now, 3), text); + fprintf(timingstats.fp, "%lu %s %s\n", day, lfptoa(&now, + 3), text); if (++flshcnt % 100 == 0) fflush(timingstats.fp); } } #endif + + +/* + * check_leap_file - See if the leapseconds file has been updated. + * + * Returns: n/a + * + * Note: This loads a new leapfile on the fly. Currently a leap file + * without SHA1 signature is accepted, but if there is a signature line, + * the signature must be valid or the file is rejected. + */ +void +check_leap_file( + int is_daily_check, + uint32_t ntptime , + const time_t *systime + ) +{ + /* just do nothing if there is no leap file */ + if ( ! (leapfile_name && *leapfile_name)) + return; + + /* try to load leapfile, force it if no leapfile loaded yet */ + if (leapsec_load_file( + leapfile_name, &leapfile_stat, + !have_leapfile, is_daily_check)) + have_leapfile = TRUE; + else if (!have_leapfile) + return; + + check_leap_expiration(is_daily_check, ntptime, systime); +} + +/* + * check expiration of a loaded leap table + */ +static void +check_leap_expiration( + int is_daily_check, + uint32_t ntptime , + const time_t *systime + ) +{ + static const char * const logPrefix = "leapsecond file"; + int rc; + + /* test the expiration of the leap data and log with proper + * level and frequency (once/hour or once/day, depending on the + * state. + */ + rc = leapsec_daystolive(ntptime, systime); + if (rc == 0) { + msyslog(LOG_WARNING, + "%s ('%s'): will expire in less than one day", + logPrefix, leapfile_name); + } else if (is_daily_check && rc < 28) { + if (rc < 0) + msyslog(LOG_ERR, + "%s ('%s'): expired less than %d day%s ago", + logPrefix, leapfile_name, -rc, (rc == -1 ? "" : "s")); + else + msyslog(LOG_WARNING, + "%s ('%s'): will expire in less than %d days", + logPrefix, leapfile_name, 1+rc); + } +} + + /* * getauthkeys - read the authentication keys from the specified file */ @@ -699,31 +936,24 @@ getauthkeys( int len; len = strlen(keyfile); - if (len == 0) + if (!len) return; - if (key_file_name != 0) { - if (len > (int)strlen(key_file_name)) { - (void) free(key_file_name); - key_file_name = 0; - } - } - - if (key_file_name == 0) { #ifndef SYS_WINNT - key_file_name = (char*)emalloc((u_int) (len + 1)); + key_file_name = erealloc(key_file_name, len + 1); + memcpy(key_file_name, keyfile, len + 1); #else - key_file_name = (char*)emalloc((u_int) (MAXPATHLEN)); -#endif - } -#ifndef SYS_WINNT - memmove(key_file_name, keyfile, (unsigned)(len+1)); -#else - if (!ExpandEnvironmentStrings(keyfile, key_file_name, MAXPATHLEN)) - { + key_file_name = erealloc(key_file_name, _MAX_PATH); + if (len + 1 > _MAX_PATH) + return; + if (!ExpandEnvironmentStrings(keyfile, key_file_name, + _MAX_PATH)) { msyslog(LOG_ERR, - "ExpandEnvironmentStrings(KEY_FILE) failed: %m\n"); + "ExpandEnvironmentStrings(KEY_FILE) failed: %m"); + strlcpy(key_file_name, keyfile, _MAX_PATH); } + key_file_name = erealloc(key_file_name, + 1 + strlen(key_file_name)); #endif /* SYS_WINNT */ authreadkeys(key_file_name); @@ -736,66 +966,66 @@ getauthkeys( void rereadkeys(void) { - if (key_file_name != 0) - authreadkeys(key_file_name); + if (NULL != key_file_name) + authreadkeys(key_file_name); } + +#if notyet /* - * sock_hash - hash an sockaddr_storage structure + * ntp_exit - document explicitly that ntpd has exited */ -int -sock_hash( - struct sockaddr_storage *addr - ) +void +ntp_exit(int retval) { - int hashVal; - int i; - int len; - char *ch; - - hashVal = 0; - len = 0; - /* - * We can't just hash the whole thing because there are hidden - * fields in sockaddr_in6 that might be filled in by recvfrom(), - * so just use the family, port and address. - */ - ch = (char *)&addr->ss_family; - hashVal = 37 * hashVal + (int)*ch; - if (sizeof(addr->ss_family) > 1) { - ch++; - hashVal = 37 * hashVal + (int)*ch; - } - switch(addr->ss_family) { - case AF_INET: - ch = (char *)&((struct sockaddr_in *)addr)->sin_addr; - len = sizeof(struct in_addr); - break; - case AF_INET6: - ch = (char *)&((struct sockaddr_in6 *)addr)->sin6_addr; - len = sizeof(struct in6_addr); - break; - } - - for (i = 0; i < len ; i++) - hashVal = 37 * hashVal + (int)*(ch + i); - - hashVal = hashVal % 128; /* % MON_HASH_SIZE hardcoded */ - - if (hashVal < 0) - hashVal += 128; + msyslog(LOG_ERR, "EXITING with return code %d", retval); + exit(retval); +} +#endif - return hashVal; +/* + * fstostr - prettyprint NTP seconds + */ +char * fstostr( + time_t ntp_stamp + ) +{ + char * buf; + struct calendar tm; + + LIB_GETBUF(buf); + if (ntpcal_ntp_to_date(&tm, (u_int32)ntp_stamp, NULL) < 0) + snprintf(buf, LIB_BUFLENGTH, "ntpcal_ntp_to_date: %ld: range error", + (long)ntp_stamp); + else + snprintf(buf, LIB_BUFLENGTH, "%04d%02d%02d%02d%02d", + tm.year, tm.month, tm.monthday, + tm.hour, tm.minute); + return buf; } -#if notyet + /* - * ntp_exit - document explicitly that ntpd has exited + * ntpd_time_stepped is called back by step_systime(), allowing ntpd + * to do any one-time processing necessitated by the step. */ void -ntp_exit(int retval) +ntpd_time_stepped(void) { - msyslog(LOG_ERR, "EXITING with return code %d", retval); - exit(retval); -} + u_int saved_mon_enabled; + + /* + * flush the monitor MRU list which contains l_fp timestamps + * which should not be compared across the step. + */ + if (MON_OFF != mon_enabled) { + saved_mon_enabled = mon_enabled; + mon_stop(MON_OFF); + mon_start(saved_mon_enabled); + } + + /* inform interpolating Windows code to allow time to go back */ +#ifdef SYS_WINNT + win_time_stepped(); #endif +} diff --git a/contrib/ntp/ntpd/ntpd-opts.c b/contrib/ntp/ntpd/ntpd-opts.c index 4d23d6674..1bbecfa04 100644 --- a/contrib/ntp/ntpd/ntpd-opts.c +++ b/contrib/ntp/ntpd/ntpd-opts.c @@ -1,49 +1,66 @@ -/* +/* * EDIT THIS FILE WITH CAUTION (ntpd-opts.c) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:10 AM EST + * + * It has been AutoGen-ed October 21, 2015 at 12:36:00 PM by AutoGen 5.18.5 * From the definitions ntpd-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This source file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpd author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. + * Generated from AutoOpts 41:0:16 templates. * - * This source file is copyrighted and licensed under the following terms: + * AutoOpts is a copyrighted work. This source file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpd author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. * - * ntpd copyright 1970-2009 David L. Mills and/or others - all rights reserved + * The ntpd program is copyrighted and licensed + * under the following terms: * - * see html/copyright.html + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * + * + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. */ - -#include - +#ifndef __doxygen__ #define OPTION_CODE_COMPILE 1 #include "ntpd-opts.h" +#include + +#include +#include +#include #ifdef __cplusplus extern "C" { #endif -tSCC zCopyright[] = - "ntpd copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - -/* extracted from ../include/copyright.def near line 8 */ -"see html/copyright.html"; -extern tUsageProc optionUsage; +extern FILE * option_usage_fp; +#define zCopyright (ntpd_opt_strs+0) +#define zLicenseDescrip (ntpd_opt_strs+340) /* * global included definitions */ +#ifdef __windows + extern int atoi(const char *); +#else +# include +#endif + #ifdef __windows extern int atoi(const char*); #else @@ -53,409 +70,754 @@ extern tUsageProc optionUsage; #ifndef NULL # define NULL 0 #endif -#ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -#endif -#ifndef EXIT_FAILURE -# define EXIT_FAILURE 1 -#endif -/* - * Ipv4 option description: - */ -tSCC zIpv4Text[] = - "Force IPv4 DNS name resolution"; -tSCC zIpv4_NAME[] = "IPV4"; -tSCC zIpv4_Name[] = "ipv4"; -#define IPV4_FLAGS (OPTST_DISABLED) -/* - * Ipv6 option description: +/** + * static const strings for ntpd options */ -tSCC zIpv6Text[] = - "Force IPv6 DNS name resolution"; -tSCC zIpv6_NAME[] = "IPV6"; -tSCC zIpv6_Name[] = "ipv6"; -#define IPV6_FLAGS (OPTST_DISABLED) - -/* - * Authreq option description with +static char const ntpd_opt_strs[3129] = +/* 0 */ "ntpd 4.2.8p4\n" + "Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n" + "This is free software. It is licensed for use, modification and\n" + "redistribution under the terms of the NTP License, copies of which\n" + "can be seen at:\n" + " \n" + " \n\0" +/* 340 */ "Permission to use, copy, modify, and distribute this software and its\n" + "documentation for any purpose with or without fee is hereby granted,\n" + "provided that the above copyright notice appears in all copies and that\n" + "both the copyright notice and this permission notice appear in supporting\n" + "documentation, and that the name The University of Delaware not be used in\n" + "advertising or publicity pertaining to distribution of the software without\n" + "specific, written prior permission. The University of Delaware and Network\n" + "Time Foundation makes no representations about the suitability this\n" + "software for any purpose. It is provided \"as is\" without express or\n" + "implied warranty.\n\0" +/* 1008 */ "Force IPv4 DNS name resolution\0" +/* 1039 */ "IPV4\0" +/* 1044 */ "ipv4\0" +/* 1049 */ "Force IPv6 DNS name resolution\0" +/* 1080 */ "IPV6\0" +/* 1085 */ "ipv6\0" +/* 1090 */ "Require crypto authentication\0" +/* 1120 */ "AUTHREQ\0" +/* 1128 */ "authreq\0" +/* 1136 */ "Do not require crypto authentication\0" +/* 1173 */ "AUTHNOREQ\0" +/* 1183 */ "authnoreq\0" +/* 1193 */ "Allow us to sync to broadcast servers\0" +/* 1231 */ "BCASTSYNC\0" +/* 1241 */ "bcastsync\0" +/* 1251 */ "configuration file name\0" +/* 1275 */ "CONFIGFILE\0" +/* 1286 */ "configfile\0" +/* 1297 */ "Increase debug verbosity level\0" +/* 1328 */ "DEBUG_LEVEL\0" +/* 1340 */ "debug-level\0" +/* 1352 */ "Set the debug verbosity level\0" +/* 1382 */ "SET_DEBUG_LEVEL\0" +/* 1398 */ "set-debug-level\0" +/* 1414 */ "frequency drift file name\0" +/* 1440 */ "DRIFTFILE\0" +/* 1450 */ "driftfile\0" +/* 1460 */ "Allow the first adjustment to be Big\0" +/* 1497 */ "PANICGATE\0" +/* 1507 */ "panicgate\0" +/* 1517 */ "Step any initial offset correction.\0" +/* 1553 */ "FORCE_STEP_ONCE\0" +/* 1569 */ "force-step-once\0" +/* 1585 */ "Jail directory\0" +/* 1600 */ "JAILDIR\0" +/* 1608 */ "jaildir\0" +/* 1616 */ "built without --enable-clockctl or --enable-linuxcaps or --enable-solarisprivs\0" +/* 1695 */ "Listen on an interface name or address\0" +/* 1734 */ "INTERFACE\0" +/* 1744 */ "interface\0" +/* 1754 */ "path to symmetric keys\0" +/* 1777 */ "KEYFILE\0" +/* 1785 */ "keyfile\0" +/* 1793 */ "path to the log file\0" +/* 1814 */ "LOGFILE\0" +/* 1822 */ "logfile\0" +/* 1830 */ "Do not listen to virtual interfaces\0" +/* 1866 */ "NOVIRTUALIPS\0" +/* 1879 */ "novirtualips\0" +/* 1892 */ "Modify Multimedia Timer (Windows only)\0" +/* 1931 */ "MODIFYMMTIMER\0" +/* 1945 */ "modifymmtimer\0" +/* 1959 */ "Do not fork\0" +/* 1971 */ "NOFORK\0" +/* 1978 */ "nofork\0" +/* 1985 */ "Run at high priority\0" +/* 2006 */ "NICE\0" +/* 2011 */ "nice\0" +/* 2016 */ "path to the PID file\0" +/* 2037 */ "PIDFILE\0" +/* 2045 */ "pidfile\0" +/* 2053 */ "Process priority\0" +/* 2070 */ "PRIORITY\0" +/* 2079 */ "priority\0" +/* 2088 */ "Set the time and quit\0" +/* 2110 */ "QUIT\0" +/* 2115 */ "quit\0" +/* 2120 */ "Broadcast/propagation delay\0" +/* 2148 */ "PROPAGATIONDELAY\0" +/* 2165 */ "propagationdelay\0" +/* 2182 */ "Save parsed configuration and quit\0" +/* 2217 */ "SAVECONFIGQUIT\0" +/* 2232 */ "saveconfigquit\0" +/* 2247 */ "Statistics file location\0" +/* 2272 */ "STATSDIR\0" +/* 2281 */ "statsdir\0" +/* 2290 */ "Trusted key number\0" +/* 2309 */ "TRUSTEDKEY\0" +/* 2320 */ "trustedkey\0" +/* 2331 */ "Run as userid (or userid:groupid)\0" +/* 2365 */ "USER\0" +/* 2370 */ "user\0" +/* 2375 */ "interval in seconds between scans for new or dropped interfaces\0" +/* 2439 */ "UPDATEINTERVAL\0" +/* 2454 */ "updateinterval\0" +/* 2469 */ "make ARG an ntp variable (RW)\0" +/* 2499 */ "VAR\0" +/* 2503 */ "var\0" +/* 2507 */ "make ARG an ntp variable (RW|DEF)\0" +/* 2541 */ "DVAR\0" +/* 2546 */ "dvar\0" +/* 2551 */ "Seconds to wait for first clock sync\0" +/* 2588 */ "WAIT_SYNC\0" +/* 2598 */ "wait-sync\0" +/* 2608 */ "Slew up to 600 seconds\0" +/* 2631 */ "SLEW\0" +/* 2636 */ "slew\0" +/* 2641 */ "Use CPU cycle counter (Windows only)\0" +/* 2678 */ "USEPCC\0" +/* 2685 */ "usepcc\0" +/* 2692 */ "Force CPU cycle counter use (Windows only)\0" +/* 2735 */ "PCCFREQ\0" +/* 2743 */ "pccfreq\0" +/* 2751 */ "Register with mDNS as a NTP server\0" +/* 2786 */ "MDNS\0" +/* 2791 */ "mdns\0" +/* 2796 */ "display extended usage information and exit\0" +/* 2840 */ "help\0" +/* 2845 */ "extended usage information passed thru pager\0" +/* 2890 */ "more-help\0" +/* 2900 */ "output version information and exit\0" +/* 2936 */ "version\0" +/* 2944 */ "NTPD\0" +/* 2949 */ "ntpd - NTP daemon program - Ver. 4.2.8p4\n" + "Usage: %s [ - [] | --[{=| }] ]... \\\n" + "\t\t[ ... ]\n\0" +/* 3080 */ "http://bugs.ntp.org, bugs@ntp.org\0" +/* 3114 */ "\n\0" +/* 3116 */ "ntpd 4.2.8p4"; + +/** + * ipv4 option description with + * "Must also have options" and "Incompatible options": + */ +/** Descriptive text for the ipv4 option */ +#define IPV4_DESC (ntpd_opt_strs+1008) +/** Upper-cased name for the ipv4 option */ +#define IPV4_NAME (ntpd_opt_strs+1039) +/** Name string for the ipv4 option */ +#define IPV4_name (ntpd_opt_strs+1044) +/** Other options that appear in conjunction with the ipv4 option */ +static int const aIpv4CantList[] = { + INDEX_OPT_IPV6, NO_EQUIVALENT }; +/** Compiled in flag settings for the ipv4 option */ +#define IPV4_FLAGS (OPTST_DISABLED) + +/** + * ipv6 option description with * "Must also have options" and "Incompatible options": */ -tSCC zAuthreqText[] = - "Require crypto authentication"; -tSCC zAuthreq_NAME[] = "AUTHREQ"; -tSCC zAuthreq_Name[] = "authreq"; -static const int - aAuthreqCantList[] = { +/** Descriptive text for the ipv6 option */ +#define IPV6_DESC (ntpd_opt_strs+1049) +/** Upper-cased name for the ipv6 option */ +#define IPV6_NAME (ntpd_opt_strs+1080) +/** Name string for the ipv6 option */ +#define IPV6_name (ntpd_opt_strs+1085) +/** Other options that appear in conjunction with the ipv6 option */ +static int const aIpv6CantList[] = { + INDEX_OPT_IPV4, NO_EQUIVALENT }; +/** Compiled in flag settings for the ipv6 option */ +#define IPV6_FLAGS (OPTST_DISABLED) + +/** + * authreq option description with + * "Must also have options" and "Incompatible options": + */ +/** Descriptive text for the authreq option */ +#define AUTHREQ_DESC (ntpd_opt_strs+1090) +/** Upper-cased name for the authreq option */ +#define AUTHREQ_NAME (ntpd_opt_strs+1120) +/** Name string for the authreq option */ +#define AUTHREQ_name (ntpd_opt_strs+1128) +/** Other options that appear in conjunction with the authreq option */ +static int const aAuthreqCantList[] = { INDEX_OPT_AUTHNOREQ, NO_EQUIVALENT }; -#define AUTHREQ_FLAGS (OPTST_DISABLED) +/** Compiled in flag settings for the authreq option */ +#define AUTHREQ_FLAGS (OPTST_DISABLED) -/* - * Authnoreq option description with +/** + * authnoreq option description with * "Must also have options" and "Incompatible options": */ -tSCC zAuthnoreqText[] = - "Do not require crypto authentication"; -tSCC zAuthnoreq_NAME[] = "AUTHNOREQ"; -tSCC zAuthnoreq_Name[] = "authnoreq"; -static const int - aAuthnoreqCantList[] = { +/** Descriptive text for the authnoreq option */ +#define AUTHNOREQ_DESC (ntpd_opt_strs+1136) +/** Upper-cased name for the authnoreq option */ +#define AUTHNOREQ_NAME (ntpd_opt_strs+1173) +/** Name string for the authnoreq option */ +#define AUTHNOREQ_name (ntpd_opt_strs+1183) +/** Other options that appear in conjunction with the authnoreq option */ +static int const aAuthnoreqCantList[] = { INDEX_OPT_AUTHREQ, NO_EQUIVALENT }; -#define AUTHNOREQ_FLAGS (OPTST_DISABLED) +/** Compiled in flag settings for the authnoreq option */ +#define AUTHNOREQ_FLAGS (OPTST_DISABLED) -/* - * Bcastsync option description: +/** + * bcastsync option description: */ -tSCC zBcastsyncText[] = - "Allow us to sync to broadcast servers"; -tSCC zBcastsync_NAME[] = "BCASTSYNC"; -tSCC zBcastsync_Name[] = "bcastsync"; -#define BCASTSYNC_FLAGS (OPTST_DISABLED) - -/* - * Configfile option description: +/** Descriptive text for the bcastsync option */ +#define BCASTSYNC_DESC (ntpd_opt_strs+1193) +/** Upper-cased name for the bcastsync option */ +#define BCASTSYNC_NAME (ntpd_opt_strs+1231) +/** Name string for the bcastsync option */ +#define BCASTSYNC_name (ntpd_opt_strs+1241) +/** Compiled in flag settings for the bcastsync option */ +#define BCASTSYNC_FLAGS (OPTST_DISABLED) + +/** + * configfile option description: */ -tSCC zConfigfileText[] = - "configuration file name"; -tSCC zConfigfile_NAME[] = "CONFIGFILE"; -tSCC zConfigfile_Name[] = "configfile"; -#define CONFIGFILE_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the configfile option */ +#define CONFIGFILE_DESC (ntpd_opt_strs+1251) +/** Upper-cased name for the configfile option */ +#define CONFIGFILE_NAME (ntpd_opt_strs+1275) +/** Name string for the configfile option */ +#define CONFIGFILE_name (ntpd_opt_strs+1286) +/** Compiled in flag settings for the configfile option */ +#define CONFIGFILE_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Debug_Level option description: - */ -#ifdef DEBUG -tSCC zDebug_LevelText[] = - "Increase output debug message level"; -tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; -tSCC zDebug_Level_Name[] = "debug-level"; -#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) - -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Set_Debug_Level option description: - */ -#ifdef DEBUG -tSCC zSet_Debug_LevelText[] = - "Set the output debug message level"; -tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; -tSCC zSet_Debug_Level_Name[] = "set-debug-level"; -#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ +/** + * debug-level option description: + */ +/** Descriptive text for the debug-level option */ +#define DEBUG_LEVEL_DESC (ntpd_opt_strs+1297) +/** Upper-cased name for the debug-level option */ +#define DEBUG_LEVEL_NAME (ntpd_opt_strs+1328) +/** Name string for the debug-level option */ +#define DEBUG_LEVEL_name (ntpd_opt_strs+1340) +/** Compiled in flag settings for the debug-level option */ +#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) + +/** + * set-debug-level option description: + */ +/** Descriptive text for the set-debug-level option */ +#define SET_DEBUG_LEVEL_DESC (ntpd_opt_strs+1352) +/** Upper-cased name for the set-debug-level option */ +#define SET_DEBUG_LEVEL_NAME (ntpd_opt_strs+1382) +/** Name string for the set-debug-level option */ +#define SET_DEBUG_LEVEL_name (ntpd_opt_strs+1398) +/** Compiled in flag settings for the set-debug-level option */ +#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) -/* - * Driftfile option description: +/** + * driftfile option description: */ -tSCC zDriftfileText[] = - "frequency drift file name"; -tSCC zDriftfile_NAME[] = "DRIFTFILE"; -tSCC zDriftfile_Name[] = "driftfile"; -#define DRIFTFILE_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the driftfile option */ +#define DRIFTFILE_DESC (ntpd_opt_strs+1414) +/** Upper-cased name for the driftfile option */ +#define DRIFTFILE_NAME (ntpd_opt_strs+1440) +/** Name string for the driftfile option */ +#define DRIFTFILE_name (ntpd_opt_strs+1450) +/** Compiled in flag settings for the driftfile option */ +#define DRIFTFILE_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Panicgate option description: +/** + * panicgate option description: */ -tSCC zPanicgateText[] = - "Allow the first adjustment to be Big"; -tSCC zPanicgate_NAME[] = "PANICGATE"; -tSCC zPanicgate_Name[] = "panicgate"; -#define PANICGATE_FLAGS (OPTST_DISABLED) - -/* - * Jaildir option description: +/** Descriptive text for the panicgate option */ +#define PANICGATE_DESC (ntpd_opt_strs+1460) +/** Upper-cased name for the panicgate option */ +#define PANICGATE_NAME (ntpd_opt_strs+1497) +/** Name string for the panicgate option */ +#define PANICGATE_name (ntpd_opt_strs+1507) +/** Compiled in flag settings for the panicgate option */ +#define PANICGATE_FLAGS (OPTST_DISABLED) + +/** + * force_step_once option description: */ -tSCC zJaildirText[] = - "Jail directory"; -tSCC zJaildir_NAME[] = "JAILDIR"; -tSCC zJaildir_Name[] = "jaildir"; -#define JAILDIR_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the force_step_once option */ +#define FORCE_STEP_ONCE_DESC (ntpd_opt_strs+1517) +/** Upper-cased name for the force_step_once option */ +#define FORCE_STEP_ONCE_NAME (ntpd_opt_strs+1553) +/** Name string for the force_step_once option */ +#define FORCE_STEP_ONCE_name (ntpd_opt_strs+1569) +/** Compiled in flag settings for the force_step_once option */ +#define FORCE_STEP_ONCE_FLAGS (OPTST_DISABLED) + +/** + * jaildir option description: + */ +#ifdef HAVE_DROPROOT +/** Descriptive text for the jaildir option */ +#define JAILDIR_DESC (ntpd_opt_strs+1585) +/** Upper-cased name for the jaildir option */ +#define JAILDIR_NAME (ntpd_opt_strs+1600) +/** Name string for the jaildir option */ +#define JAILDIR_name (ntpd_opt_strs+1608) +/** Compiled in flag settings for the jaildir option */ +#define JAILDIR_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Interface option description: +#else /* disable jaildir */ +#define JAILDIR_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define JAILDIR_NAME NULL +/** Descriptive text for the jaildir option */ +#define JAILDIR_DESC (ntpd_opt_strs+1616) +#define JAILDIR_name (ntpd_opt_strs+1608) +#endif /* HAVE_DROPROOT */ + +/** + * interface option description: */ -tSCC zInterfaceText[] = - "Listen on interface"; -tSCC zInterface_NAME[] = "INTERFACE"; -tSCC zInterface_Name[] = "interface"; -#define INTERFACE_FLAGS (OPTST_DISABLED | OPTST_STACKED \ +/** Descriptive text for the interface option */ +#define INTERFACE_DESC (ntpd_opt_strs+1695) +/** Upper-cased name for the interface option */ +#define INTERFACE_NAME (ntpd_opt_strs+1734) +/** Name string for the interface option */ +#define INTERFACE_name (ntpd_opt_strs+1744) +/** Compiled in flag settings for the interface option */ +#define INTERFACE_FLAGS (OPTST_DISABLED | OPTST_STACKED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Keyfile option description: +/** + * keyfile option description: */ -tSCC zKeyfileText[] = - "path to symmetric keys"; -tSCC zKeyfile_NAME[] = "KEYFILE"; -tSCC zKeyfile_Name[] = "keyfile"; -#define KEYFILE_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the keyfile option */ +#define KEYFILE_DESC (ntpd_opt_strs+1754) +/** Upper-cased name for the keyfile option */ +#define KEYFILE_NAME (ntpd_opt_strs+1777) +/** Name string for the keyfile option */ +#define KEYFILE_name (ntpd_opt_strs+1785) +/** Compiled in flag settings for the keyfile option */ +#define KEYFILE_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Logfile option description: +/** + * logfile option description: */ -tSCC zLogfileText[] = - "path to the log file"; -tSCC zLogfile_NAME[] = "LOGFILE"; -tSCC zLogfile_Name[] = "logfile"; -#define LOGFILE_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the logfile option */ +#define LOGFILE_DESC (ntpd_opt_strs+1793) +/** Upper-cased name for the logfile option */ +#define LOGFILE_NAME (ntpd_opt_strs+1814) +/** Name string for the logfile option */ +#define LOGFILE_name (ntpd_opt_strs+1822) +/** Compiled in flag settings for the logfile option */ +#define LOGFILE_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Novirtualips option description: +/** + * novirtualips option description: */ -tSCC zNovirtualipsText[] = - "Do not listen to virtual IPs"; -tSCC zNovirtualips_NAME[] = "NOVIRTUALIPS"; -tSCC zNovirtualips_Name[] = "novirtualips"; -#define NOVIRTUALIPS_FLAGS (OPTST_DISABLED) - -/* - * Modifymmtimer option description: +/** Descriptive text for the novirtualips option */ +#define NOVIRTUALIPS_DESC (ntpd_opt_strs+1830) +/** Upper-cased name for the novirtualips option */ +#define NOVIRTUALIPS_NAME (ntpd_opt_strs+1866) +/** Name string for the novirtualips option */ +#define NOVIRTUALIPS_name (ntpd_opt_strs+1879) +/** Compiled in flag settings for the novirtualips option */ +#define NOVIRTUALIPS_FLAGS (OPTST_DISABLED) + +/** + * modifymmtimer option description: */ #ifdef SYS_WINNT -tSCC zModifymmtimerText[] = - "Modify Multimedia Timer (Windows only)"; -tSCC zModifymmtimer_NAME[] = "MODIFYMMTIMER"; -tSCC zModifymmtimer_Name[] = "modifymmtimer"; -#define MODIFYMMTIMER_FLAGS (OPTST_DISABLED) - -#else /* disable Modifymmtimer */ -#define VALUE_OPT_MODIFYMMTIMER NO_EQUIVALENT -#define MODIFYMMTIMER_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zModifymmtimerText NULL -#define zModifymmtimer_NAME NULL -#define zModifymmtimer_Name NULL +/** Descriptive text for the modifymmtimer option */ +#define MODIFYMMTIMER_DESC (ntpd_opt_strs+1892) +/** Upper-cased name for the modifymmtimer option */ +#define MODIFYMMTIMER_NAME (ntpd_opt_strs+1931) +/** Name string for the modifymmtimer option */ +#define MODIFYMMTIMER_name (ntpd_opt_strs+1945) +/** Compiled in flag settings for the modifymmtimer option */ +#define MODIFYMMTIMER_FLAGS (OPTST_DISABLED) + +#else /* disable modifymmtimer */ +#define MODIFYMMTIMER_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define MODIFYMMTIMER_NAME NULL +#define MODIFYMMTIMER_DESC NULL +#define MODIFYMMTIMER_name NULL #endif /* SYS_WINNT */ -/* - * Nofork option description: +/** + * nofork option description with + * "Must also have options" and "Incompatible options": */ -tSCC zNoforkText[] = - "Do not fork"; -tSCC zNofork_NAME[] = "NOFORK"; -tSCC zNofork_Name[] = "nofork"; -#define NOFORK_FLAGS (OPTST_DISABLED) - -/* - * Nice option description: +/** Descriptive text for the nofork option */ +#define NOFORK_DESC (ntpd_opt_strs+1959) +/** Upper-cased name for the nofork option */ +#define NOFORK_NAME (ntpd_opt_strs+1971) +/** Name string for the nofork option */ +#define NOFORK_name (ntpd_opt_strs+1978) +/** Other options that appear in conjunction with the nofork option */ +static int const aNoforkCantList[] = { + INDEX_OPT_WAIT_SYNC, NO_EQUIVALENT }; +/** Compiled in flag settings for the nofork option */ +#define NOFORK_FLAGS (OPTST_DISABLED) + +/** + * nice option description: */ -tSCC zNiceText[] = - "Run at high priority"; -tSCC zNice_NAME[] = "NICE"; -tSCC zNice_Name[] = "nice"; -#define NICE_FLAGS (OPTST_DISABLED) - -/* - * Pidfile option description: +/** Descriptive text for the nice option */ +#define NICE_DESC (ntpd_opt_strs+1985) +/** Upper-cased name for the nice option */ +#define NICE_NAME (ntpd_opt_strs+2006) +/** Name string for the nice option */ +#define NICE_name (ntpd_opt_strs+2011) +/** Compiled in flag settings for the nice option */ +#define NICE_FLAGS (OPTST_DISABLED) + +/** + * pidfile option description: */ -tSCC zPidfileText[] = - "path to the PID file"; -tSCC zPidfile_NAME[] = "PIDFILE"; -tSCC zPidfile_Name[] = "pidfile"; -#define PIDFILE_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the pidfile option */ +#define PIDFILE_DESC (ntpd_opt_strs+2016) +/** Upper-cased name for the pidfile option */ +#define PIDFILE_NAME (ntpd_opt_strs+2037) +/** Name string for the pidfile option */ +#define PIDFILE_name (ntpd_opt_strs+2045) +/** Compiled in flag settings for the pidfile option */ +#define PIDFILE_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Priority option description: +/** + * priority option description: */ -tSCC zPriorityText[] = - "Process priority"; -tSCC zPriority_NAME[] = "PRIORITY"; -tSCC zPriority_Name[] = "priority"; -#define PRIORITY_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the priority option */ +#define PRIORITY_DESC (ntpd_opt_strs+2053) +/** Upper-cased name for the priority option */ +#define PRIORITY_NAME (ntpd_opt_strs+2070) +/** Name string for the priority option */ +#define PRIORITY_name (ntpd_opt_strs+2079) +/** Compiled in flag settings for the priority option */ +#define PRIORITY_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) -/* - * Quit option description: +/** + * quit option description with + * "Must also have options" and "Incompatible options": */ -tSCC zQuitText[] = - "Set the time and quit"; -tSCC zQuit_NAME[] = "QUIT"; -tSCC zQuit_Name[] = "quit"; -#define QUIT_FLAGS (OPTST_DISABLED) - -/* - * Propagationdelay option description: +/** Descriptive text for the quit option */ +#define QUIT_DESC (ntpd_opt_strs+2088) +/** Upper-cased name for the quit option */ +#define QUIT_NAME (ntpd_opt_strs+2110) +/** Name string for the quit option */ +#define QUIT_name (ntpd_opt_strs+2115) +/** Other options that appear in conjunction with the quit option */ +static int const aQuitCantList[] = { + INDEX_OPT_SAVECONFIGQUIT, + INDEX_OPT_WAIT_SYNC, NO_EQUIVALENT }; +/** Compiled in flag settings for the quit option */ +#define QUIT_FLAGS (OPTST_DISABLED) + +/** + * propagationdelay option description: */ -tSCC zPropagationdelayText[] = - "Broadcast/propagation delay"; -tSCC zPropagationdelay_NAME[] = "PROPAGATIONDELAY"; -tSCC zPropagationdelay_Name[] = "propagationdelay"; -#define PROPAGATIONDELAY_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the propagationdelay option */ +#define PROPAGATIONDELAY_DESC (ntpd_opt_strs+2120) +/** Upper-cased name for the propagationdelay option */ +#define PROPAGATIONDELAY_NAME (ntpd_opt_strs+2148) +/** Name string for the propagationdelay option */ +#define PROPAGATIONDELAY_name (ntpd_opt_strs+2165) +/** Compiled in flag settings for the propagationdelay option */ +#define PROPAGATIONDELAY_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Updateinterval option description: +/** + * saveconfigquit option description with + * "Must also have options" and "Incompatible options": */ -tSCC zUpdateintervalText[] = - "interval in seconds between scans for new or dropped interfaces"; -tSCC zUpdateinterval_NAME[] = "UPDATEINTERVAL"; -tSCC zUpdateinterval_Name[] = "updateinterval"; -#define UPDATEINTERVAL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) +#ifdef SAVECONFIG +/** Descriptive text for the saveconfigquit option */ +#define SAVECONFIGQUIT_DESC (ntpd_opt_strs+2182) +/** Upper-cased name for the saveconfigquit option */ +#define SAVECONFIGQUIT_NAME (ntpd_opt_strs+2217) +/** Name string for the saveconfigquit option */ +#define SAVECONFIGQUIT_name (ntpd_opt_strs+2232) +/** Other options that appear in conjunction with the saveconfigquit option */ +static int const aSaveconfigquitCantList[] = { + INDEX_OPT_QUIT, + INDEX_OPT_WAIT_SYNC, NO_EQUIVALENT }; +/** Compiled in flag settings for the saveconfigquit option */ +#define SAVECONFIGQUIT_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Statsdir option description: +#else /* disable saveconfigquit */ +#define SAVECONFIGQUIT_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define aSaveconfigquitCantList NULL +#define SAVECONFIGQUIT_NAME NULL +#define SAVECONFIGQUIT_DESC NULL +#define SAVECONFIGQUIT_name NULL +#endif /* SAVECONFIG */ + +/** + * statsdir option description: */ -tSCC zStatsdirText[] = - "Statistics file location"; -tSCC zStatsdir_NAME[] = "STATSDIR"; -tSCC zStatsdir_Name[] = "statsdir"; -#define STATSDIR_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the statsdir option */ +#define STATSDIR_DESC (ntpd_opt_strs+2247) +/** Upper-cased name for the statsdir option */ +#define STATSDIR_NAME (ntpd_opt_strs+2272) +/** Name string for the statsdir option */ +#define STATSDIR_name (ntpd_opt_strs+2281) +/** Compiled in flag settings for the statsdir option */ +#define STATSDIR_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Trustedkey option description: +/** + * trustedkey option description: */ -tSCC zTrustedkeyText[] = - "Trusted key number"; -tSCC zTrustedkey_NAME[] = "TRUSTEDKEY"; -tSCC zTrustedkey_Name[] = "trustedkey"; -#define TRUSTEDKEY_FLAGS (OPTST_DISABLED | OPTST_STACKED \ +/** Descriptive text for the trustedkey option */ +#define TRUSTEDKEY_DESC (ntpd_opt_strs+2290) +/** Upper-cased name for the trustedkey option */ +#define TRUSTEDKEY_NAME (ntpd_opt_strs+2309) +/** Name string for the trustedkey option */ +#define TRUSTEDKEY_name (ntpd_opt_strs+2320) +/** Compiled in flag settings for the trustedkey option */ +#define TRUSTEDKEY_FLAGS (OPTST_DISABLED | OPTST_STACKED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * User option description: +/** + * user option description: */ -tSCC zUserText[] = - "Run as userid (or userid:groupid)"; -tSCC zUser_NAME[] = "USER"; -tSCC zUser_Name[] = "user"; -#define USER_FLAGS (OPTST_DISABLED \ +#ifdef HAVE_DROPROOT +/** Descriptive text for the user option */ +#define USER_DESC (ntpd_opt_strs+2331) +/** Upper-cased name for the user option */ +#define USER_NAME (ntpd_opt_strs+2365) +/** Name string for the user option */ +#define USER_name (ntpd_opt_strs+2370) +/** Compiled in flag settings for the user option */ +#define USER_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Var option description: +#else /* disable user */ +#define USER_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define USER_NAME NULL +/** Descriptive text for the user option */ +#define USER_DESC (ntpd_opt_strs+1616) +#define USER_name (ntpd_opt_strs+2370) +#endif /* HAVE_DROPROOT */ + +/** + * updateinterval option description: */ -tSCC zVarText[] = - "make ARG an ntp variable (RW)"; -tSCC zVar_NAME[] = "VAR"; -tSCC zVar_Name[] = "var"; -#define VAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) +/** Descriptive text for the updateinterval option */ +#define UPDATEINTERVAL_DESC (ntpd_opt_strs+2375) +/** Upper-cased name for the updateinterval option */ +#define UPDATEINTERVAL_NAME (ntpd_opt_strs+2439) +/** Name string for the updateinterval option */ +#define UPDATEINTERVAL_name (ntpd_opt_strs+2454) +/** Compiled in flag settings for the updateinterval option */ +#define UPDATEINTERVAL_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) -/* - * Dvar option description: +/** + * var option description: */ -tSCC zDvarText[] = - "make ARG an ntp variable (RW|DEF)"; -tSCC zDvar_NAME[] = "DVAR"; -tSCC zDvar_Name[] = "dvar"; -#define DVAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ +/** Descriptive text for the var option */ +#define VAR_DESC (ntpd_opt_strs+2469) +/** Upper-cased name for the var option */ +#define VAR_NAME (ntpd_opt_strs+2499) +/** Name string for the var option */ +#define VAR_name (ntpd_opt_strs+2503) +/** Compiled in flag settings for the var option */ +#define VAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Slew option description: +/** + * dvar option description: */ -tSCC zSlewText[] = - "Slew up to 600 seconds"; -tSCC zSlew_NAME[] = "SLEW"; -tSCC zSlew_Name[] = "slew"; -#define SLEW_FLAGS (OPTST_DISABLED) +/** Descriptive text for the dvar option */ +#define DVAR_DESC (ntpd_opt_strs+2507) +/** Upper-cased name for the dvar option */ +#define DVAR_NAME (ntpd_opt_strs+2541) +/** Name string for the dvar option */ +#define DVAR_name (ntpd_opt_strs+2546) +/** Compiled in flag settings for the dvar option */ +#define DVAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Help/More_Help/Version option descriptions: +/** + * wait-sync option description with + * "Must also have options" and "Incompatible options": */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; +#ifdef HAVE_WORKING_FORK +/** Descriptive text for the wait-sync option */ +#define WAIT_SYNC_DESC (ntpd_opt_strs+2551) +/** Upper-cased name for the wait-sync option */ +#define WAIT_SYNC_NAME (ntpd_opt_strs+2588) +/** Name string for the wait-sync option */ +#define WAIT_SYNC_name (ntpd_opt_strs+2598) +/** Other options that appear in conjunction with the wait-sync option */ +static int const aWait_SyncCantList[] = { + INDEX_OPT_NOFORK, + INDEX_OPT_QUIT, + INDEX_OPT_SAVECONFIGQUIT, NO_EQUIVALENT }; +/** Compiled in flag settings for the wait-sync option */ +#define WAIT_SYNC_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; +#else /* disable wait-sync */ +#define WAIT_SYNC_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define aWait_SyncCantList NULL +#define WAIT_SYNC_NAME NULL +#define WAIT_SYNC_DESC NULL +#define WAIT_SYNC_name NULL +#endif /* HAVE_WORKING_FORK */ -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; -/* - * Declare option callback procedures +/** + * slew option description: */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ -#if defined(TEST_NTPD_OPTS) -/* - * Under test, omit argument processing, or call optionStackArg, - * if multiple copies are allowed. +/** Descriptive text for the slew option */ +#define SLEW_DESC (ntpd_opt_strs+2608) +/** Upper-cased name for the slew option */ +#define SLEW_NAME (ntpd_opt_strs+2631) +/** Name string for the slew option */ +#define SLEW_name (ntpd_opt_strs+2636) +/** Compiled in flag settings for the slew option */ +#define SLEW_FLAGS (OPTST_DISABLED) + +/** + * usepcc option description: */ -extern tOptProc - optionNumericVal, optionPagedUsage, optionStackArg, - optionVersionStderr; -static tOptProc - doUsageOpt; +#ifdef SYS_WINNT +/** Descriptive text for the usepcc option */ +#define USEPCC_DESC (ntpd_opt_strs+2641) +/** Upper-cased name for the usepcc option */ +#define USEPCC_NAME (ntpd_opt_strs+2678) +/** Name string for the usepcc option */ +#define USEPCC_name (ntpd_opt_strs+2685) +/** Compiled in flag settings for the usepcc option */ +#define USEPCC_FLAGS (OPTST_DISABLED) + +#else /* disable usepcc */ +#define USEPCC_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define USEPCC_NAME NULL +#define USEPCC_DESC NULL +#define USEPCC_name NULL +#endif /* SYS_WINNT */ -/* - * #define map the "normal" callout procs to the test ones... +/** + * pccfreq option description: */ -#define SET_DEBUG_LEVEL_OPT_PROC optionStackArg +#ifdef SYS_WINNT +/** Descriptive text for the pccfreq option */ +#define PCCFREQ_DESC (ntpd_opt_strs+2692) +/** Upper-cased name for the pccfreq option */ +#define PCCFREQ_NAME (ntpd_opt_strs+2735) +/** Name string for the pccfreq option */ +#define PCCFREQ_name (ntpd_opt_strs+2743) +/** Compiled in flag settings for the pccfreq option */ +#define PCCFREQ_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) +#else /* disable pccfreq */ +#define PCCFREQ_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define PCCFREQ_NAME NULL +#define PCCFREQ_DESC NULL +#define PCCFREQ_name NULL +#endif /* SYS_WINNT */ -#else /* NOT defined TEST_NTPD_OPTS */ -/* - * When not under test, there are different procs to use +/** + * mdns option description: */ -extern tOptProc - optionNumericVal, optionPagedUsage, optionPrintVersion, optionStackArg; -static tOptProc - doUsageOpt; +#ifdef HAVE_DNSREGISTRATION +/** Descriptive text for the mdns option */ +#define MDNS_DESC (ntpd_opt_strs+2751) +/** Upper-cased name for the mdns option */ +#define MDNS_NAME (ntpd_opt_strs+2786) +/** Name string for the mdns option */ +#define MDNS_name (ntpd_opt_strs+2791) +/** Compiled in flag settings for the mdns option */ +#define MDNS_FLAGS (OPTST_DISABLED) + +#else /* disable mdns */ +#define MDNS_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#define MDNS_NAME NULL +#define MDNS_DESC NULL +#define MDNS_name NULL +#endif /* HAVE_DNSREGISTRATION */ /* - * #define map the "normal" callout procs + * Help/More_Help/Version option descriptions: */ -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level - -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level -#endif /* defined(TEST_NTPD_OPTS) */ -#ifdef TEST_NTPD_OPTS -# define DOVERPROC optionVersionStderr +#define HELP_DESC (ntpd_opt_strs+2796) +#define HELP_name (ntpd_opt_strs+2840) +#ifdef HAVE_WORKING_FORK +#define MORE_HELP_DESC (ntpd_opt_strs+2845) +#define MORE_HELP_name (ntpd_opt_strs+2890) +#define MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) #else -# define DOVERPROC optionPrintVersion -#endif /* TEST_NTPD_OPTS */ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpd Option Descriptions. +#define MORE_HELP_DESC HELP_DESC +#define MORE_HELP_name HELP_name +#define MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define VER_FLAGS (OPTST_IMM | OPTST_NO_INIT) +#else +# define VER_FLAGS (OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT) +#endif +#define VER_DESC (ntpd_opt_strs+2900) +#define VER_name (ntpd_opt_strs+2936) +/** + * Declare option callback procedures */ -static tOptDesc optDesc[ OPTION_CT ] = { +extern tOptProc + ntpOptionPrintVersion, optionBooleanVal, optionNestedVal, + optionNumericVal, optionPagedUsage, optionResetOpt, + optionStackArg, optionTimeDate, optionTimeVal, + optionUnstackArg, optionVendorOption; +static tOptProc + doOptDebug_Level, doUsageOpt; +#define VER_PROC ntpOptionPrintVersion + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Define the ntpd Option Descriptions. + * This is an array of OPTION_CT entries, one for each + * option that the ntpd program responds to. + */ +static tOptDesc optDesc[OPTION_CT] = { { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, + /* equiv idx, value */ 0, VALUE_OPT_IPV4, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV4_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --ipv4 */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv4CantList, /* option proc */ NULL, - /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, + /* desc, NAME, name */ IPV4_DESC, IPV4_NAME, IPV4_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, + /* equiv idx, value */ 1, VALUE_OPT_IPV6, + /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV6_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --ipv6 */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv6CantList, /* option proc */ NULL, - /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, + /* desc, NAME, name */ IPV6_DESC, IPV6_NAME, IPV6_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 2, VALUE_OPT_AUTHREQ, @@ -463,11 +825,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ AUTHREQ_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --authreq */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, aAuthreqCantList, /* option proc */ NULL, - /* desc, NAME, name */ zAuthreqText, zAuthreq_NAME, zAuthreq_Name, + /* desc, NAME, name */ AUTHREQ_DESC, AUTHREQ_NAME, AUTHREQ_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 3, VALUE_OPT_AUTHNOREQ, @@ -475,11 +837,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ AUTHNOREQ_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --authnoreq */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, aAuthnoreqCantList, /* option proc */ NULL, - /* desc, NAME, name */ zAuthnoreqText, zAuthnoreq_NAME, zAuthnoreq_Name, + /* desc, NAME, name */ AUTHNOREQ_DESC, AUTHNOREQ_NAME, AUTHNOREQ_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 4, VALUE_OPT_BCASTSYNC, @@ -487,11 +849,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ BCASTSYNC_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --bcastsync */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zBcastsyncText, zBcastsync_NAME, zBcastsync_Name, + /* desc, NAME, name */ BCASTSYNC_DESC, BCASTSYNC_NAME, BCASTSYNC_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 5, VALUE_OPT_CONFIGFILE, @@ -499,11 +861,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ CONFIGFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --configfile */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zConfigfileText, zConfigfile_NAME, zConfigfile_Name, + /* desc, NAME, name */ CONFIGFILE_DESC, CONFIGFILE_NAME, CONFIGFILE_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 6, VALUE_OPT_DEBUG_LEVEL, @@ -511,11 +873,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --debug-level */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zDebug_LevelText, zDebug_Level_NAME, zDebug_Level_Name, + /* option proc */ doOptDebug_Level, + /* desc, NAME, name */ DEBUG_LEVEL_DESC, DEBUG_LEVEL_NAME, DEBUG_LEVEL_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 7, VALUE_OPT_SET_DEBUG_LEVEL, @@ -523,11 +885,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ SET_DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --set-debug-level */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ SET_DEBUG_LEVEL_OPT_PROC, - /* desc, NAME, name */ zSet_Debug_LevelText, zSet_Debug_Level_NAME, zSet_Debug_Level_Name, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ SET_DEBUG_LEVEL_DESC, SET_DEBUG_LEVEL_NAME, SET_DEBUG_LEVEL_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 8, VALUE_OPT_DRIFTFILE, @@ -535,316 +897,383 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ DRIFTFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --driftfile */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zDriftfileText, zDriftfile_NAME, zDriftfile_Name, + /* desc, NAME, name */ DRIFTFILE_DESC, DRIFTFILE_NAME, DRIFTFILE_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 9, VALUE_OPT_PANICGATE, /* equiv idx, value */ 9, VALUE_OPT_PANICGATE, /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, + /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ PANICGATE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --panicgate */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zPanicgateText, zPanicgate_NAME, zPanicgate_Name, + /* desc, NAME, name */ PANICGATE_DESC, PANICGATE_NAME, PANICGATE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 10, VALUE_OPT_JAILDIR, - /* equiv idx, value */ 10, VALUE_OPT_JAILDIR, + { /* entry idx, value */ 10, VALUE_OPT_FORCE_STEP_ONCE, + /* equiv idx, value */ 10, VALUE_OPT_FORCE_STEP_ONCE, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ FORCE_STEP_ONCE_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --force_step_once */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ FORCE_STEP_ONCE_DESC, FORCE_STEP_ONCE_NAME, FORCE_STEP_ONCE_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 11, VALUE_OPT_JAILDIR, + /* equiv idx, value */ 11, VALUE_OPT_JAILDIR, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ JAILDIR_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --jaildir */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zJaildirText, zJaildir_NAME, zJaildir_Name, + /* desc, NAME, name */ JAILDIR_DESC, JAILDIR_NAME, JAILDIR_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 11, VALUE_OPT_INTERFACE, - /* equiv idx, value */ 11, VALUE_OPT_INTERFACE, + { /* entry idx, value */ 12, VALUE_OPT_INTERFACE, + /* equiv idx, value */ 12, VALUE_OPT_INTERFACE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ INTERFACE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --interface */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionStackArg, - /* desc, NAME, name */ zInterfaceText, zInterface_NAME, zInterface_Name, + /* desc, NAME, name */ INTERFACE_DESC, INTERFACE_NAME, INTERFACE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 12, VALUE_OPT_KEYFILE, - /* equiv idx, value */ 12, VALUE_OPT_KEYFILE, + { /* entry idx, value */ 13, VALUE_OPT_KEYFILE, + /* equiv idx, value */ 13, VALUE_OPT_KEYFILE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ KEYFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --keyfile */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zKeyfileText, zKeyfile_NAME, zKeyfile_Name, + /* desc, NAME, name */ KEYFILE_DESC, KEYFILE_NAME, KEYFILE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 13, VALUE_OPT_LOGFILE, - /* equiv idx, value */ 13, VALUE_OPT_LOGFILE, + { /* entry idx, value */ 14, VALUE_OPT_LOGFILE, + /* equiv idx, value */ 14, VALUE_OPT_LOGFILE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ LOGFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --logfile */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zLogfileText, zLogfile_NAME, zLogfile_Name, + /* desc, NAME, name */ LOGFILE_DESC, LOGFILE_NAME, LOGFILE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 14, VALUE_OPT_NOVIRTUALIPS, - /* equiv idx, value */ 14, VALUE_OPT_NOVIRTUALIPS, + { /* entry idx, value */ 15, VALUE_OPT_NOVIRTUALIPS, + /* equiv idx, value */ 15, VALUE_OPT_NOVIRTUALIPS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ NOVIRTUALIPS_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --novirtualips */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zNovirtualipsText, zNovirtualips_NAME, zNovirtualips_Name, + /* desc, NAME, name */ NOVIRTUALIPS_DESC, NOVIRTUALIPS_NAME, NOVIRTUALIPS_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 15, VALUE_OPT_MODIFYMMTIMER, - /* equiv idx, value */ 15, VALUE_OPT_MODIFYMMTIMER, + { /* entry idx, value */ 16, VALUE_OPT_MODIFYMMTIMER, + /* equiv idx, value */ 16, VALUE_OPT_MODIFYMMTIMER, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ MODIFYMMTIMER_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --modifymmtimer */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zModifymmtimerText, zModifymmtimer_NAME, zModifymmtimer_Name, + /* desc, NAME, name */ MODIFYMMTIMER_DESC, MODIFYMMTIMER_NAME, MODIFYMMTIMER_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 16, VALUE_OPT_NOFORK, - /* equiv idx, value */ 16, VALUE_OPT_NOFORK, + { /* entry idx, value */ 17, VALUE_OPT_NOFORK, + /* equiv idx, value */ 17, VALUE_OPT_NOFORK, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ NOFORK_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --nofork */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aNoforkCantList, /* option proc */ NULL, - /* desc, NAME, name */ zNoforkText, zNofork_NAME, zNofork_Name, + /* desc, NAME, name */ NOFORK_DESC, NOFORK_NAME, NOFORK_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 17, VALUE_OPT_NICE, - /* equiv idx, value */ 17, VALUE_OPT_NICE, + { /* entry idx, value */ 18, VALUE_OPT_NICE, + /* equiv idx, value */ 18, VALUE_OPT_NICE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ NICE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --nice */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zNiceText, zNice_NAME, zNice_Name, + /* desc, NAME, name */ NICE_DESC, NICE_NAME, NICE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 18, VALUE_OPT_PIDFILE, - /* equiv idx, value */ 18, VALUE_OPT_PIDFILE, + { /* entry idx, value */ 19, VALUE_OPT_PIDFILE, + /* equiv idx, value */ 19, VALUE_OPT_PIDFILE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ PIDFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --pidfile */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zPidfileText, zPidfile_NAME, zPidfile_Name, + /* desc, NAME, name */ PIDFILE_DESC, PIDFILE_NAME, PIDFILE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 19, VALUE_OPT_PRIORITY, - /* equiv idx, value */ 19, VALUE_OPT_PRIORITY, + { /* entry idx, value */ 20, VALUE_OPT_PRIORITY, + /* equiv idx, value */ 20, VALUE_OPT_PRIORITY, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ PRIORITY_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --priority */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionNumericVal, - /* desc, NAME, name */ zPriorityText, zPriority_NAME, zPriority_Name, + /* desc, NAME, name */ PRIORITY_DESC, PRIORITY_NAME, PRIORITY_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 20, VALUE_OPT_QUIT, - /* equiv idx, value */ 20, VALUE_OPT_QUIT, + { /* entry idx, value */ 21, VALUE_OPT_QUIT, + /* equiv idx, value */ 21, VALUE_OPT_QUIT, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ QUIT_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --quit */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aQuitCantList, /* option proc */ NULL, - /* desc, NAME, name */ zQuitText, zQuit_NAME, zQuit_Name, + /* desc, NAME, name */ QUIT_DESC, QUIT_NAME, QUIT_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 21, VALUE_OPT_PROPAGATIONDELAY, - /* equiv idx, value */ 21, VALUE_OPT_PROPAGATIONDELAY, + { /* entry idx, value */ 22, VALUE_OPT_PROPAGATIONDELAY, + /* equiv idx, value */ 22, VALUE_OPT_PROPAGATIONDELAY, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ PROPAGATIONDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --propagationdelay */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zPropagationdelayText, zPropagationdelay_NAME, zPropagationdelay_Name, + /* desc, NAME, name */ PROPAGATIONDELAY_DESC, PROPAGATIONDELAY_NAME, PROPAGATIONDELAY_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 22, VALUE_OPT_UPDATEINTERVAL, - /* equiv idx, value */ 22, VALUE_OPT_UPDATEINTERVAL, + { /* entry idx, value */ 23, VALUE_OPT_SAVECONFIGQUIT, + /* equiv idx, value */ 23, VALUE_OPT_SAVECONFIGQUIT, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ UPDATEINTERVAL_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* opt state flags */ SAVECONFIGQUIT_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --saveconfigquit */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionNumericVal, - /* desc, NAME, name */ zUpdateintervalText, zUpdateinterval_NAME, zUpdateinterval_Name, + /* must/cannot opts */ NULL, aSaveconfigquitCantList, + /* option proc */ NULL, + /* desc, NAME, name */ SAVECONFIGQUIT_DESC, SAVECONFIGQUIT_NAME, SAVECONFIGQUIT_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 23, VALUE_OPT_STATSDIR, - /* equiv idx, value */ 23, VALUE_OPT_STATSDIR, + { /* entry idx, value */ 24, VALUE_OPT_STATSDIR, + /* equiv idx, value */ 24, VALUE_OPT_STATSDIR, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ STATSDIR_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --statsdir */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zStatsdirText, zStatsdir_NAME, zStatsdir_Name, + /* desc, NAME, name */ STATSDIR_DESC, STATSDIR_NAME, STATSDIR_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 24, VALUE_OPT_TRUSTEDKEY, - /* equiv idx, value */ 24, VALUE_OPT_TRUSTEDKEY, + { /* entry idx, value */ 25, VALUE_OPT_TRUSTEDKEY, + /* equiv idx, value */ 25, VALUE_OPT_TRUSTEDKEY, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ TRUSTEDKEY_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --trustedkey */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionStackArg, - /* desc, NAME, name */ zTrustedkeyText, zTrustedkey_NAME, zTrustedkey_Name, + /* desc, NAME, name */ TRUSTEDKEY_DESC, TRUSTEDKEY_NAME, TRUSTEDKEY_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 25, VALUE_OPT_USER, - /* equiv idx, value */ 25, VALUE_OPT_USER, + { /* entry idx, value */ 26, VALUE_OPT_USER, + /* equiv idx, value */ 26, VALUE_OPT_USER, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ USER_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --user */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zUserText, zUser_NAME, zUser_Name, + /* desc, NAME, name */ USER_DESC, USER_NAME, USER_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 27, VALUE_OPT_UPDATEINTERVAL, + /* equiv idx, value */ 27, VALUE_OPT_UPDATEINTERVAL, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ UPDATEINTERVAL_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --updateinterval */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ UPDATEINTERVAL_DESC, UPDATEINTERVAL_NAME, UPDATEINTERVAL_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 26, VALUE_OPT_VAR, - /* equiv idx, value */ 26, VALUE_OPT_VAR, + { /* entry idx, value */ 28, VALUE_OPT_VAR, + /* equiv idx, value */ 28, VALUE_OPT_VAR, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ VAR_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --var */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionStackArg, - /* desc, NAME, name */ zVarText, zVar_NAME, zVar_Name, + /* desc, NAME, name */ VAR_DESC, VAR_NAME, VAR_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 27, VALUE_OPT_DVAR, - /* equiv idx, value */ 27, VALUE_OPT_DVAR, + { /* entry idx, value */ 29, VALUE_OPT_DVAR, + /* equiv idx, value */ 29, VALUE_OPT_DVAR, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ DVAR_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --dvar */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionStackArg, - /* desc, NAME, name */ zDvarText, zDvar_NAME, zDvar_Name, + /* desc, NAME, name */ DVAR_DESC, DVAR_NAME, DVAR_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 30, VALUE_OPT_WAIT_SYNC, + /* equiv idx, value */ 30, VALUE_OPT_WAIT_SYNC, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ WAIT_SYNC_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --wait-sync */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, aWait_SyncCantList, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ WAIT_SYNC_DESC, WAIT_SYNC_NAME, WAIT_SYNC_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 28, VALUE_OPT_SLEW, - /* equiv idx, value */ 28, VALUE_OPT_SLEW, + { /* entry idx, value */ 31, VALUE_OPT_SLEW, + /* equiv idx, value */ 31, VALUE_OPT_SLEW, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ SLEW_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --slew */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zSlewText, zSlew_NAME, zSlew_Name, + /* desc, NAME, name */ SLEW_DESC, SLEW_NAME, SLEW_name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif + { /* entry idx, value */ 32, VALUE_OPT_USEPCC, + /* equiv idx, value */ 32, VALUE_OPT_USEPCC, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ USEPCC_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --usepcc */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ USEPCC_DESC, USEPCC_NAME, USEPCC_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 33, VALUE_OPT_PCCFREQ, + /* equiv idx, value */ 33, VALUE_OPT_PCCFREQ, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ PCCFREQ_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --pccfreq */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ PCCFREQ_DESC, PCCFREQ_NAME, PCCFREQ_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 34, VALUE_OPT_MDNS, + /* equiv idx, value */ 34, VALUE_OPT_MDNS, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ MDNS_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --mdns */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ MDNS_DESC, MDNS_NAME, MDNS_name, + /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_VERSION, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ VER_FLAGS, AOUSE_VERSION, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ DOVERPROC, - /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, + /* option proc */ VER_PROC, + /* desc, NAME, name */ VER_DESC, NULL, VER_name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_HELP, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, AOUSE_HELP, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ doUsageOpt, - /* desc, NAME, name */ zHelpText, NULL, zHelp_Name, + /* desc, NAME, name */ HELP_DESC, NULL, HELP_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_MORE_HELP, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ MORE_HELP_FLAGS, AOUSE_MORE_HELP, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionPagedUsage, - /* desc, NAME, name */ zMore_HelpText, NULL, zMore_Help_Name, + /* desc, NAME, name */ MORE_HELP_DESC, NULL, MORE_HELP_name, /* disablement strs */ NULL, NULL } }; -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpd Option Environment - */ -tSCC zPROGNAME[] = "NTPD"; -tSCC zUsageTitle[] = -"ntpd - NTP daemon program - Ver. 4.2.4p8\n\ -USAGE: %s [ - [] | --[{=| }] ]...\n"; -#define zRcName NULL -#define apzHomeList NULL -tSCC zBugsAddr[] = "http://bugs.ntp.org, bugs@ntp.org"; -#define zExplain NULL -tSCC zDetail[] = "\n\n"; -tSCC zFullVersion[] = NTPD_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** Reference to the upper cased version of ntpd. */ +#define zPROGNAME (ntpd_opt_strs+2944) +/** Reference to the title line for ntpd usage. */ +#define zUsageTitle (ntpd_opt_strs+2949) +/** There is no ntpd configuration file. */ +#define zRcName NULL +/** There are no directories to search for ntpd config files. */ +#define apzHomeList NULL +/** The ntpd program bug email address. */ +#define zBugsAddr (ntpd_opt_strs+3080) +/** Clarification/explanation of what ntpd does. */ +#define zExplain (ntpd_opt_strs+3114) +/** Extra detail explaining what ntpd does. */ +#define zDetail (NULL) +/** The full version string for ntpd. */ +#define zFullVersion (ntpd_opt_strs+3116) +/* extracted from optcode.tlib near line 364 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -854,6 +1283,90 @@ tSCC zFullVersion[] = NTPD_FULL_VERSION; # define translate_option_strings NULL #endif /* ENABLE_NLS */ +#define ntpd_full_usage (NULL) +#define ntpd_short_usage (NULL) + +#endif /* not defined __doxygen__ */ + +/* + * Create the static procedure(s) declared above. + */ +/** + * The callout function that invokes the optionUsage function. + * + * @param[in] opts the AutoOpts option description structure + * @param[in] od the descriptor for the "help" (usage) option. + * @noreturn + */ +static void +doUsageOpt(tOptions * opts, tOptDesc * od) +{ + int ex_code; + ex_code = NTPD_EXIT_SUCCESS; + optionUsage(&ntpdOptions, ex_code); + /* NOTREACHED */ + exit(1); + (void)opts; + (void)od; +} + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Code to handle the debug-level option. + * + * @param[in] pOptions the ntpd options data structure + * @param[in,out] pOptDesc the option descriptor for this option. + */ +static void +doOptDebug_Level(tOptions* pOptions, tOptDesc* pOptDesc) +{ + /* + * Be sure the flag-code[0] handles special values for the options pointer + * viz. (poptions <= OPTPROC_EMIT_LIMIT) *and also* the special flag bit + * ((poptdesc->fOptState & OPTST_RESET) != 0) telling the option to + * reset its state. + */ + /* extracted from debug-opt.def, line 15 */ +OPT_VALUE_SET_DEBUG_LEVEL++; + (void)pOptDesc; + (void)pOptions; +} +/* extracted from optmain.tlib near line 1250 */ + +/** + * The directory containing the data associated with ntpd. + */ +#ifndef PKGDATADIR +# define PKGDATADIR "" +#endif + +/** + * Information about the person or institution that packaged ntpd + * for the current distribution. + */ +#ifndef WITH_PACKAGER +# define ntpd_packager_info NULL +#else +/** Packager information for ntpd. */ +static char const ntpd_packager_info[] = + "Packaged by " WITH_PACKAGER + +# ifdef WITH_PACKAGER_VERSION + " ("WITH_PACKAGER_VERSION")" +# endif + +# ifdef WITH_PACKAGER_BUG_REPORTS + "\nReport ntpd bugs to " WITH_PACKAGER_BUG_REPORTS +# endif + "\n"; +#endif +#ifndef __doxygen__ + +#endif /* __doxygen__ */ +/** + * The option definitions for ntpd. The one structure that + * binds them all. + */ tOptions ntpdOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -863,158 +1376,608 @@ tOptions ntpdOptions = { + OPTPROC_LONGOPT + OPTPROC_NO_REQ_OPT + OPTPROC_ENVIRON - + OPTPROC_NO_ARGS ), + + OPTPROC_MISUSE ), 0, NULL, /* current option index, current option */ NULL, NULL, zPROGNAME, - zRcName, zCopyright, zCopyrightNotice, + zRcName, zCopyright, zLicenseDescrip, zFullVersion, apzHomeList, zUsageTitle, zExplain, zDetail, optDesc, zBugsAddr, /* address to send bugs to */ NULL, NULL, /* extensions/saved state */ - optionUsage, /* usage procedure */ + optionUsage, /* usage procedure */ translate_option_strings, /* translation procedure */ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - 0 /* no option state saving */, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + NO_EQUIVALENT, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 32 /* full option count */, 29 /* user option count */ + 38 /* full option count */, 35 /* user option count */, + ntpd_full_usage, ntpd_short_usage, + NULL, NULL, + PKGDATADIR, ntpd_packager_info }; -/* - * Create the static procedure(s) declared above. - */ -static void -doUsageOpt( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - USAGE( EXIT_SUCCESS ); -} - -#if ! defined(TEST_NTPD_OPTS) - -/* * * * * * * - * - * For the set-debug-level option, when DEBUG is #define-d. - */ -#ifdef DEBUG -static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - /* extracted from ../include/debug-opt.def, line 29 */ -DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); -} -#endif /* defined DEBUG */ - -#endif /* defined(TEST_NTPD_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ - -#if defined(TEST_NTPD_OPTS) /* TEST MAIN PROCEDURE: */ - -int -main( int argc, char** argv ) -{ - int res = EXIT_SUCCESS; - (void)optionProcess( &ntpdOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpdOptions ); - } - return res; -} -#endif /* defined TEST_NTPD_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ - #if ENABLE_NLS +/** + * This code is designed to translate translatable option text for the + * ntpd program. These translations happen upon entry + * to optionProcess(). + */ #include #include #include #include +#ifdef HAVE_DCGETTEXT +# include +#endif #include -static char* AO_gettext( char const* pz ); -static void coerce_it(void** s); +static char * AO_gettext(char const * pz); +static void coerce_it(void ** s); -static char* -AO_gettext( char const* pz ) +/** + * AutoGen specific wrapper function for gettext. It relies on the macro _() + * to convert from English to the target language, then strdup-duplicates the + * result string. It tries the "libopts" domain first, then whatever has been + * set via the \a textdomain(3) call. + * + * @param[in] pz the input text used as a lookup key. + * @returns the translated text (if there is one), + * or the original text (if not). + */ +static char * +AO_gettext(char const * pz) { - char* pzRes; + char * res; if (pz == NULL) return NULL; - pzRes = _(pz); - if (pzRes == pz) - return pzRes; - pzRes = strdup( pzRes ); - if (pzRes == NULL) { - fputs( _("No memory for duping translated strings\n"), stderr ); - exit( EXIT_FAILURE ); +#ifdef HAVE_DCGETTEXT + /* + * While processing the option_xlateable_txt data, try to use the + * "libopts" domain. Once we switch to the option descriptor data, + * do *not* use that domain. + */ + if (option_xlateable_txt.field_ct != 0) { + res = dgettext("libopts", pz); + if (res == pz) + res = (char *)VOIDP(_(pz)); + } else + res = (char *)VOIDP(_(pz)); +#else + res = (char *)VOIDP(_(pz)); +#endif + if (res == pz) + return res; + res = strdup(res); + if (res == NULL) { + fputs(_("No memory for duping translated strings\n"), stderr); + exit(NTPD_EXIT_FAILURE); } - return pzRes; + return res; } -static void coerce_it(void** s) { *s = AO_gettext(*s); } -#define COERSION(_f) \ - coerce_it((void*)&(ntpdOptions._f)) +/** + * All the pointers we use are marked "* const", but they are stored in + * writable memory. Coerce the mutability and set the pointer. + */ +static void coerce_it(void ** s) { *s = AO_gettext(*s); +} -/* - * This invokes the translation code (e.g. gettext(3)). +/** + * Translate all the translatable strings in the ntpdOptions + * structure defined above. This is done only once. */ static void -translate_option_strings( void ) +translate_option_strings(void) { + tOptions * const opts = &ntpdOptions; + /* * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_xlateable_txt.field_ct != 0) { + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + char ** ppz = (char**)VOIDP(&(option_xlateable_txt)); + int ix = option_xlateable_txt.field_ct; do { - ppz++; + ppz++; /* skip over field_ct */ *ppz = AO_gettext(*ppz); } while (--ix > 0); - } - option_usage_text.field_ct = 0; - - { - tOptDesc* pOD = ntpdOptions.pOptDesc; - int ix = ntpdOptions.optCt; - - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + /* prevent re-translation and disable "libopts" domain lookup */ + option_xlateable_txt.field_ct = 0; + + coerce_it(VOIDP(&(opts->pzCopyright))); + coerce_it(VOIDP(&(opts->pzCopyNotice))); + coerce_it(VOIDP(&(opts->pzFullVersion))); + coerce_it(VOIDP(&(opts->pzUsageTitle))); + coerce_it(VOIDP(&(opts->pzExplain))); + coerce_it(VOIDP(&(opts->pzDetail))); + { + tOptDesc * od = opts->pOptDesc; + for (ix = opts->optCt; ix > 0; ix--, od++) + coerce_it(VOIDP(&(od->pzText))); } } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } - #endif /* ENABLE_NLS */ +#ifdef DO_NOT_COMPILE_THIS_CODE_IT_IS_FOR_GETTEXT +/** I18N function strictly for xgettext. Do not compile. */ +static void bogus_function(void) { + /* TRANSLATORS: + + The following dummy function was crated solely so that xgettext can + extract the correct strings. These strings are actually referenced + by a field name in the ntpdOptions structure noted in the + comments below. The literal text is defined in ntpd_opt_strs. + + NOTE: the strings below are segmented with respect to the source string + ntpd_opt_strs. The strings above are handed off for translation + at run time a paragraph at a time. Consequently, they are presented here + for translation a paragraph at a time. + + ALSO: often the description for an option will reference another option + by name. These are set off with apostrophe quotes (I hope). Do not + translate option names. + */ + /* referenced via ntpdOptions.pzCopyright */ + puts(_("ntpd 4.2.8p4\n\ +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n\ +This is free software. It is licensed for use, modification and\n\ +redistribution under the terms of the NTP License, copies of which\n\ +can be seen at:\n")); + puts(_(" \n\ + \n")); + + /* referenced via ntpdOptions.pzCopyNotice */ + puts(_("Permission to use, copy, modify, and distribute this software and its\n\ +documentation for any purpose with or without fee is hereby granted,\n\ +provided that the above copyright notice appears in all copies and that\n\ +both the copyright notice and this permission notice appear in supporting\n\ +documentation, and that the name The University of Delaware not be used in\n\ +advertising or publicity pertaining to distribution of the software without\n\ +specific, written prior permission. The University of Delaware and Network\n\ +Time Foundation makes no representations about the suitability this\n\ +software for any purpose. It is provided \"as is\" without express or\n\ +implied warranty.\n")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Force IPv4 DNS name resolution")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Force IPv6 DNS name resolution")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Require crypto authentication")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Do not require crypto authentication")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Allow us to sync to broadcast servers")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("configuration file name")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Increase debug verbosity level")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Set the debug verbosity level")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("frequency drift file name")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Allow the first adjustment to be Big")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Step any initial offset correction.")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Jail directory")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("built without --enable-clockctl or --enable-linuxcaps or --enable-solarisprivs")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Listen on an interface name or address")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("path to symmetric keys")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("path to the log file")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Do not listen to virtual interfaces")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Modify Multimedia Timer (Windows only)")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Do not fork")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Run at high priority")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("path to the PID file")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Process priority")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Set the time and quit")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Broadcast/propagation delay")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Save parsed configuration and quit")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Statistics file location")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Trusted key number")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Run as userid (or userid:groupid)")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("built without --enable-clockctl or --enable-linuxcaps or --enable-solarisprivs")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("interval in seconds between scans for new or dropped interfaces")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("make ARG an ntp variable (RW)")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("make ARG an ntp variable (RW|DEF)")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Seconds to wait for first clock sync")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Slew up to 600 seconds")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Use CPU cycle counter (Windows only)")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Force CPU cycle counter use (Windows only)")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("Register with mDNS as a NTP server")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("display extended usage information and exit")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("extended usage information passed thru pager")); + + /* referenced via ntpdOptions.pOptDesc->pzText */ + puts(_("output version information and exit")); + + /* referenced via ntpdOptions.pzUsageTitle */ + puts(_("ntpd - NTP daemon program - Ver. 4.2.8p4\n\ +Usage: %s [ - [] | --[{=| }] ]... \\\n\ +\t\t[ ... ]\n")); + + /* referenced via ntpdOptions.pzExplain */ + puts(_("\n")); + + /* referenced via ntpdOptions.pzFullVersion */ + puts(_("ntpd 4.2.8p4")); + + /* referenced via ntpdOptions.pzFullUsage */ + puts(_("<<>>")); + + /* referenced via ntpdOptions.pzShortUsage */ + puts(_("<<>>")); + /* LIBOPTS-MESSAGES: */ +#line 67 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 93 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 53 "../init.c" + puts(_("AutoOpts function called without option descriptor\n")); +#line 86 "../init.c" + puts(_("\tThis exceeds the compiled library version: ")); +#line 84 "../init.c" + puts(_("Automated Options Processing Error!\n" + "\t%s called AutoOpts function with structure version %d:%d:%d.\n")); +#line 80 "../autoopts.c" + puts(_("realloc of %d bytes at 0x%p failed\n")); +#line 88 "../init.c" + puts(_("\tThis is less than the minimum library version: ")); +#line 121 "../version.c" + puts(_("Automated Options version %s\n" + "\tCopyright (C) 1999-2014 by Bruce Korb - all rights reserved\n")); +#line 87 "../makeshell.c" + puts(_("(AutoOpts bug): %s.\n")); +#line 90 "../reset.c" + puts(_("optionResetOpt() called, but reset-option not configured")); +#line 292 "../usage.c" + puts(_("could not locate the 'help' option")); +#line 336 "../autoopts.c" + puts(_("optionProcess() was called with invalid data")); +#line 748 "../usage.c" + puts(_("invalid argument type specified")); +#line 598 "../find.c" + puts(_("defaulted to option with optional arg")); +#line 76 "../alias.c" + puts(_("aliasing option is out of range.")); +#line 234 "../enum.c" + puts(_("%s error: the keyword '%s' is ambiguous for %s\n")); +#line 108 "../find.c" + puts(_(" The following options match:\n")); +#line 293 "../find.c" + puts(_("%s: ambiguous option name: %s (matches %d options)\n")); +#line 161 "../check.c" + puts(_("%s: Command line arguments required\n")); +#line 43 "../alias.c" + puts(_("%d %s%s options allowed\n")); +#line 94 "../makeshell.c" + puts(_("%s error %d (%s) calling %s for '%s'\n")); +#line 306 "../makeshell.c" + puts(_("interprocess pipe")); +#line 168 "../version.c" + puts(_("error: version option argument '%c' invalid. Use:\n" + "\t'v' - version only\n" + "\t'c' - version and copyright\n" + "\t'n' - version and full copyright notice\n")); +#line 58 "../check.c" + puts(_("%s error: the '%s' and '%s' options conflict\n")); +#line 217 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 430 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 38 "../alias.c" + puts(_("-equivalence")); +#line 469 "../find.c" + puts(_("%s: illegal option -- %c\n")); +#line 110 "../reset.c" + puts(_("%s: illegal option -- %c\n")); +#line 271 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 755 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 118 "../reset.c" + puts(_("%s: illegal option -- %s\n")); +#line 335 "../find.c" + puts(_("%s: unknown vendor extension option -- %s\n")); +#line 159 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 169 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 747 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 1081 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 385 "../find.c" + puts(_("%s: invalid option name: %s\n")); +#line 527 "../find.c" + puts(_("%s: The '%s' option requires an argument.\n")); +#line 156 "../autoopts.c" + puts(_("(AutoOpts bug): Equivalenced option '%s' was equivalenced to both\n" + "\t'%s' and '%s'.")); +#line 94 "../check.c" + puts(_("%s error: The %s option is required\n")); +#line 632 "../find.c" + puts(_("%s: The '%s' option cannot have an argument.\n")); +#line 151 "../check.c" + puts(_("%s: Command line arguments are not allowed.\n")); +#line 535 "../save.c" + puts(_("error %d (%s) creating %s\n")); +#line 234 "../enum.c" + puts(_("%s error: '%s' does not match any %s keywords.\n")); +#line 93 "../reset.c" + puts(_("%s error: The '%s' option requires an argument.\n")); +#line 184 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 238 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 143 "../restore.c" + puts(_("%s error: no saved option state\n")); +#line 231 "../autoopts.c" + puts(_("'%s' is not a command line option.\n")); +#line 111 "../time.c" + puts(_("%s error: '%s' is not a recognizable date/time.\n")); +#line 132 "../save.c" + puts(_("'%s' not defined\n")); +#line 50 "../time.c" + puts(_("%s error: '%s' is not a recognizable time duration.\n")); +#line 92 "../check.c" + puts(_("%s error: The %s option must appear %d times.\n")); +#line 164 "../numeric.c" + puts(_("%s error: '%s' is not a recognizable number.\n")); +#line 200 "../enum.c" + puts(_("%s error: %s exceeds %s keyword count\n")); +#line 330 "../usage.c" + puts(_("Try '%s %s' for more information.\n")); +#line 45 "../alias.c" + puts(_("one %s%s option allowed\n")); +#line 208 "../makeshell.c" + puts(_("standard output")); +#line 943 "../makeshell.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard output")); +#line 415 "../usage.c" + puts(_("standard output")); +#line 625 "../usage.c" + puts(_("standard output")); +#line 175 "../version.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard error")); +#line 415 "../usage.c" + puts(_("standard error")); +#line 625 "../usage.c" + puts(_("standard error")); +#line 175 "../version.c" + puts(_("standard error")); +#line 208 "../makeshell.c" + puts(_("write")); +#line 943 "../makeshell.c" + puts(_("write")); +#line 273 "../usage.c" + puts(_("write")); +#line 414 "../usage.c" + puts(_("write")); +#line 624 "../usage.c" + puts(_("write")); +#line 174 "../version.c" + puts(_("write")); +#line 60 "../numeric.c" + puts(_("%s error: %s option value %ld is out of range.\n")); +#line 44 "../check.c" + puts(_("%s error: %s option requires the %s option\n")); +#line 131 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 183 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 237 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 256 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 534 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); + /* END-LIBOPTS-MESSAGES */ + + /* USAGE-TEXT: */ +#line 873 "../usage.c" + puts(_("\t\t\t\t- an alternate for '%s'\n")); +#line 1148 "../usage.c" + puts(_("Version, usage and configuration options:")); +#line 924 "../usage.c" + puts(_("\t\t\t\t- default option for unnamed options\n")); +#line 837 "../usage.c" + puts(_("\t\t\t\t- disabled as '--%s'\n")); +#line 1117 "../usage.c" + puts(_(" --- %-14s %s\n")); +#line 1115 "../usage.c" + puts(_("This option has been disabled")); +#line 864 "../usage.c" + puts(_("\t\t\t\t- enabled by default\n")); +#line 40 "../alias.c" + puts(_("%s error: only ")); +#line 1194 "../usage.c" + puts(_(" - examining environment variables named %s_*\n")); +#line 168 "../file.c" + puts(_("\t\t\t\t- file must not pre-exist\n")); +#line 172 "../file.c" + puts(_("\t\t\t\t- file must pre-exist\n")); +#line 380 "../usage.c" + puts(_("Options are specified by doubled hyphens and their name or by a single\n" + "hyphen and the flag character.\n")); +#line 921 "../makeshell.c" + puts(_("\n" + "= = = = = = = =\n\n" + "This incarnation of genshell will produce\n" + "a shell script to parse the options for %s:\n\n")); +#line 166 "../enum.c" + puts(_(" or an integer mask with any of the lower %d bits set\n")); +#line 897 "../usage.c" + puts(_("\t\t\t\t- is a set membership option\n")); +#line 918 "../usage.c" + puts(_("\t\t\t\t- must appear between %d and %d times\n")); +#line 382 "../usage.c" + puts(_("Options are specified by single or double hyphens and their name.\n")); +#line 904 "../usage.c" + puts(_("\t\t\t\t- may appear multiple times\n")); +#line 891 "../usage.c" + puts(_("\t\t\t\t- may not be preset\n")); +#line 1309 "../usage.c" + puts(_(" Arg Option-Name Description\n")); +#line 1245 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1303 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1304 "../usage.c" + puts(_(" %3s %s")); +#line 1310 "../usage.c" + puts(_(" %3s %s")); +#line 387 "../usage.c" + puts(_("The '-#' option may omit the hash char\n")); +#line 383 "../usage.c" + puts(_("All arguments are named options.\n")); +#line 971 "../usage.c" + puts(_(" - reading file %s")); +#line 409 "../usage.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 100 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 129 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 903 "../usage.c" + puts(_("\t\t\t\t- may NOT appear - preset only\n")); +#line 944 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 1192 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 682 "../usage.c" + puts(_("prohibits these options:\n")); +#line 677 "../usage.c" + puts(_("prohibits the option '%s'\n")); +#line 81 "../numeric.c" + puts(_("%s%ld to %ld")); +#line 79 "../numeric.c" + puts(_("%sgreater than or equal to %ld")); +#line 75 "../numeric.c" + puts(_("%s%ld exactly")); +#line 68 "../numeric.c" + puts(_("%sit must lie in one of the ranges:\n")); +#line 68 "../numeric.c" + puts(_("%sit must be in the range:\n")); +#line 88 "../numeric.c" + puts(_(", or\n")); +#line 66 "../numeric.c" + puts(_("%sis scalable with a suffix: k/K/m/M/g/G/t/T\n")); +#line 77 "../numeric.c" + puts(_("%sless than or equal to %ld")); +#line 390 "../usage.c" + puts(_("Operands and options may be intermixed. They will be reordered.\n")); +#line 652 "../usage.c" + puts(_("requires the option '%s'\n")); +#line 655 "../usage.c" + puts(_("requires these options:\n")); +#line 1321 "../usage.c" + puts(_(" Arg Option-Name Req? Description\n")); +#line 1315 "../usage.c" + puts(_(" Flg Arg Option-Name Req? Description\n")); +#line 167 "../enum.c" + puts(_("or you may use a numeric representation. Preceding these with a '!'\n" + "will clear the bits, specifying 'none' will clear all bits, and 'all'\n" + "will set them all. Multiple entries may be passed as an option\n" + "argument list.\n")); +#line 910 "../usage.c" + puts(_("\t\t\t\t- may appear up to %d times\n")); +#line 77 "../enum.c" + puts(_("The valid \"%s\" option keywords are:\n")); +#line 1152 "../usage.c" + puts(_("The next option supports vendor supported extra options:")); +#line 773 "../usage.c" + puts(_("These additional options are:")); + /* END-USAGE-TEXT */ +} +#endif /* uncompilable code */ #ifdef __cplusplus } #endif diff --git a/contrib/ntp/ntpd/ntpd-opts.def b/contrib/ntp/ntpd/ntpd-opts.def index 7266e1b2a..00d35115d 100644 --- a/contrib/ntp/ntpd/ntpd-opts.def +++ b/contrib/ntp/ntpd/ntpd-opts.def @@ -4,10 +4,612 @@ autogen definitions options; #include copyright.def -prog-name = "ntpd"; -prog-title = "NTP daemon program"; +prog-name = "ntpd"; +prog-title = "NTP daemon program"; +argument = "[ ... ]"; #include ntpdbase-opts.def -detail = <<- _END_DETAIL - _END_DETAIL; +/* explain: Additional information whenever the usage routine is invoked */ +explain = <<- _END_EXPLAIN + _END_EXPLAIN; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +The +.Nm +utility is an operating system daemon which sets +and maintains the system time of day in synchronism with Internet +standard time servers. +It is a complete implementation of the +Network Time Protocol (NTP) version 4, as defined by RFC-5905, +but also retains compatibility with +version 3, as defined by RFC-1305, and versions 1 +and 2, as defined by RFC-1059 and RFC-1119, respectively. +.Pp +The +.Nm +utility does most computations in 64-bit floating point +arithmetic and does relatively clumsy 64-bit fixed point operations +only when necessary to preserve the ultimate precision, about 232 +picoseconds. +While the ultimate precision is not achievable with +ordinary workstations and networks of today, it may be required +with future gigahertz CPU clocks and gigabit LANs. +.Pp +Ordinarily, +.Nm +reads the +.Xr ntp.conf 5 +configuration file at startup time in order to determine the +synchronization sources and operating modes. +It is also possible to +specify a working, although limited, configuration entirely on the +command line, obviating the need for a configuration file. +This may +be particularly useful when the local host is to be configured as a +broadcast/multicast client, with all peers being determined by +listening to broadcasts at run time. +.Pp +If NetInfo support is built into +.Nm , +then +.Nm +will attempt to read its configuration from the +NetInfo if the default +.Xr ntp.conf 5 +file cannot be read and no file is +specified by the +.Fl c +option. +.Pp +Various internal +.Nm +variables can be displayed and +configuration options altered while the +.Nm +is running +using the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +utility programs. +.Pp +When +.Nm +starts it looks at the value of +.Xr umask 2 , +and if zero +.Nm +will set the +.Xr umask 2 +to 022. + _END_PROG_MDOC_DESCRIP; +}; + +doc-section = { + ds-type = 'USAGE'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_USAGE +.Ss "How NTP Operates" +The +.Nm +utility operates by exchanging messages with +one or more configured servers over a range of designated poll intervals. +When +started, whether for the first or subsequent times, the program +requires several exchanges from the majority of these servers so +the signal processing and mitigation algorithms can accumulate and +groom the data and set the clock. +In order to protect the network +from bursts, the initial poll interval for each server is delayed +an interval randomized over a few seconds. +At the default initial poll +interval of 64s, several minutes can elapse before the clock is +set. +This initial delay to set the clock +can be safely and dramatically reduced using the +.Cm iburst +keyword with the +.Ic server +configuration +command, as described in +.Xr ntp.conf 5 . +.Pp +Most operating systems and hardware of today incorporate a +time-of-year (TOY) chip to maintain the time during periods when +the power is off. +When the machine is booted, the chip is used to +initialize the operating system time. +After the machine has +synchronized to a NTP server, the operating system corrects the +chip from time to time. +In the default case, if +.Nm +detects that the time on the host +is more than 1000s from the server time, +.Nm +assumes something must be terribly wrong and the only +reliable action is for the operator to intervene and set the clock +by hand. +(Reasons for this include there is no TOY chip, +or its battery is dead, or that the TOY chip is just of poor quality.) +This causes +.Nm +to exit with a panic message to +the system log. +The +.Fl g +option overrides this check and the +clock will be set to the server time regardless of the chip time +(up to 68 years in the past or future \(em +this is a limitation of the NTPv4 protocol). +However, and to protect against broken hardware, such as when the +CMOS battery fails or the clock counter becomes defective, once the +clock has been set an error greater than 1000s will cause +.Nm +to exit anyway. +.Pp +Under ordinary conditions, +.Nm +adjusts the clock in +small steps so that the timescale is effectively continuous and +without discontinuities. +Under conditions of extreme network +congestion, the roundtrip delay jitter can exceed three seconds and +the synchronization distance, which is equal to one-half the +roundtrip delay plus error budget terms, can become very large. +The +.Nm +algorithms discard sample offsets exceeding 128 ms, +unless the interval during which no sample offset is less than 128 +ms exceeds 900s. +The first sample after that, no matter what the +offset, steps the clock to the indicated time. +In practice this +reduces the false alarm rate where the clock is stepped in error to +a vanishingly low incidence. +.Pp +As the result of this behavior, once the clock has been set it +very rarely strays more than 128 ms even under extreme cases of +network path congestion and jitter. +Sometimes, in particular when +.Nm +is first started without a valid drift file +on a system with a large intrinsic drift +the error might grow to exceed 128 ms, +which would cause the clock to be set backwards +if the local clock time is more than 128 s +in the future relative to the server. +In some applications, this behavior may be unacceptable. +There are several solutions, however. +If the +.Fl x +option is included on the command line, the clock will +never be stepped and only slew corrections will be used. +But this choice comes with a cost that +should be carefully explored before deciding to use +the +.Fl x +option. +The maximum slew rate possible is limited +to 500 parts-per-million (PPM) as a consequence of the correctness +principles on which the NTP protocol and algorithm design are +based. +As a result, the local clock can take a long time to +converge to an acceptable offset, about 2,000 s for each second the +clock is outside the acceptable range. +During this interval the +local clock will not be consistent with any other network clock and +the system cannot be used for distributed applications that require +correctly synchronized network time. +.Pp +In spite of the above precautions, sometimes when large +frequency errors are present the resulting time offsets stray +outside the 128-ms range and an eventual step or slew time +correction is required. +If following such a correction the +frequency error is so large that the first sample is outside the +acceptable range, +.Nm +enters the same state as when the +.Pa ntp.drift +file is not present. +The intent of this behavior +is to quickly correct the frequency and restore operation to the +normal tracking mode. +In the most extreme cases +(the host +.Cm time.ien.it +comes to mind), there may be occasional +step/slew corrections and subsequent frequency corrections. +It +helps in these cases to use the +.Cm burst +keyword when +configuring the server, but +ONLY +when you have permission to do so from the owner of the target host. +.Pp +Finally, +in the past many startup scripts would run +.Xr ntpdate 1ntpdatemdoc +or +.Xr sntp 1sntpmdoc +to get the system clock close to correct before starting +.Xr ntpd 1ntpdmdoc , +but this was never more than a mediocre hack and is no longer needed. +If you are following the instructions in +.Sx "Starting NTP (Best Current Practice)" +and you still need to set the system time before starting +.Nm , +please open a bug report and document what is going on, +and then look at using +.Xr sntp 1sntpmdoc +if you really need to set the clock before starting +.Nm . +.Pp +There is a way to start +.Xr ntpd 1ntpdmdoc +that often addresses all of the problems mentioned above. +.Ss "Starting NTP (Best Current Practice)" +First, use the +.Cm iburst +option on your +.Cm server +entries. +.Pp +If you can also keep a good +.Pa ntp.drift +file then +.Xr ntpd 1ntpdmdoc +will effectively "warm-start" and your system's clock will +be stable in under 11 seconds' time. +.Pp +As soon as possible in the startup sequence, start +.Xr ntpd 1ntpdmdoc +with at least the +.Fl g +and perhaps the +.Fl N +options. +Then, +start the rest of your "normal" processes. +This will give +.Xr ntpd 1ntpdmdoc +as much time as possible to get the system's clock synchronized and stable. +.Pp +Finally, +if you have processes like +.Cm dovecot +or database servers +that require +monotonically-increasing time, +run +.Xr ntp-wait 1ntp-waitmdoc +as late as possible in the boot sequence +(perhaps with the +.Fl v +flag) +and after +.Xr ntp-wait 1ntp-waitmdoc +exits successfully +it is as safe as it will ever be to start any process that require +stable time. +.Ss "Frequency Discipline" +The +.Nm +behavior at startup depends on whether the +frequency file, usually +.Pa ntp.drift , +exists. +This file +contains the latest estimate of clock frequency error. +When the +.Nm +is started and the file does not exist, the +.Nm +enters a special mode designed to quickly adapt to +the particular system clock oscillator time and frequency error. +This takes approximately 15 minutes, after which the time and +frequency are set to nominal values and the +.Nm +enters +normal mode, where the time and frequency are continuously tracked +relative to the server. +After one hour the frequency file is +created and the current frequency offset written to it. +When the +.Nm +is started and the file does exist, the +.Nm +frequency is initialized from the file and enters normal mode +immediately. +After that the current frequency offset is written to +the file at hourly intervals. +.Ss "Operating Modes" +The +.Nm +utility can operate in any of several modes, including +symmetric active/passive, client/server broadcast/multicast and +manycast, as described in the +.Qq Association Management +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +It normally operates continuously while +monitoring for small changes in frequency and trimming the clock +for the ultimate precision. +However, it can operate in a one-time +mode where the time is set from an external server and frequency is +set from a previously recorded frequency file. +A +broadcast/multicast or manycast client can discover remote servers, +compute server-client propagation delay correction factors and +configure itself automatically. +This makes it possible to deploy a +fleet of workstations without specifying configuration details +specific to the local environment. +.Pp +By default, +.Nm +runs in continuous mode where each of +possibly several external servers is polled at intervals determined +by an intricate state machine. +The state machine measures the +incidental roundtrip delay jitter and oscillator frequency wander +and determines the best poll interval using a heuristic algorithm. +Ordinarily, and in most operating environments, the state machine +will start with 64s intervals and eventually increase in steps to +1024s. +A small amount of random variation is introduced in order to +avoid bunching at the servers. +In addition, should a server become +unreachable for some time, the poll interval is increased in steps +to 1024s in order to reduce network overhead. +.Pp +In some cases it may not be practical for +.Nm +to run continuously. +A common workaround has been to run the +.Xr ntpdate 1ntpdatemdoc +or +.Xr sntp 1sntpmdoc +programs from a +.Xr cron 8 +job at designated +times. +However, these programs do not have the crafted signal +processing, error checking or mitigation algorithms of +.Nm . +The +.Fl q +option is intended for this purpose. +Setting this option will cause +.Nm +to exit just after +setting the clock for the first time. +The procedure for initially +setting the clock is the same as in continuous mode; most +applications will probably want to specify the +.Cm iburst +keyword with the +.Ic server +configuration command. +With this +keyword a volley of messages are exchanged to groom the data and +the clock is set in about 10 s. +If nothing is heard after a +couple of minutes, the daemon times out and exits. +After a suitable +period of mourning, the +.Xr ntpdate 1ntpdatemdoc +program will be +retired. +.Pp +When kernel support is available to discipline the clock +frequency, which is the case for stock Solaris, Tru64, Linux and +.Fx , +a useful feature is available to discipline the clock +frequency. +First, +.Nm +is run in continuous mode with +selected servers in order to measure and record the intrinsic clock +frequency offset in the frequency file. +It may take some hours for +the frequency and offset to settle down. +Then the +.Nm +is +stopped and run in one-time mode as required. +At each startup, the +frequency is read from the file and initializes the kernel +frequency. +.Ss "Poll Interval Control" +This version of NTP includes an intricate state machine to +reduce the network load while maintaining a quality of +synchronization consistent with the observed jitter and wander. +There are a number of ways to tailor the operation in order enhance +accuracy by reducing the interval or to reduce network overhead by +increasing it. +However, the user is advised to carefully consider +the consequences of changing the poll adjustment range from the +default minimum of 64 s to the default maximum of 1,024 s. +The +default minimum can be changed with the +.Ic tinker +.Cm minpoll +command to a value not less than 16 s. +This value is used for all +configured associations, unless overridden by the +.Cm minpoll +option on the configuration command. +Note that most device drivers +will not operate properly if the poll interval is less than 64 s +and that the broadcast server and manycast client associations will +also use the default, unless overridden. +.Pp +In some cases involving dial up or toll services, it may be +useful to increase the minimum interval to a few tens of minutes +and maximum interval to a day or so. +Under normal operation +conditions, once the clock discipline loop has stabilized the +interval will be increased in steps from the minimum to the +maximum. +However, this assumes the intrinsic clock frequency error +is small enough for the discipline loop correct it. +The capture +range of the loop is 500 PPM at an interval of 64s decreasing by a +factor of two for each doubling of interval. +At a minimum of 1,024 +s, for example, the capture range is only 31 PPM. +If the intrinsic +error is greater than this, the drift file +.Pa ntp.drift +will +have to be specially tailored to reduce the residual error below +this limit. +Once this is done, the drift file is automatically +updated once per hour and is available to initialize the frequency +on subsequent daemon restarts. +.Ss "The huff-n'-puff Filter" +In scenarios where a considerable amount of data are to be +downloaded or uploaded over telephone modems, timekeeping quality +can be seriously degraded. +This occurs because the differential +delays on the two directions of transmission can be quite large. +In +many cases the apparent time errors are so large as to exceed the +step threshold and a step correction can occur during and after the +data transfer is in progress. +.Pp +The huff-n'-puff filter is designed to correct the apparent time +offset in these cases. +It depends on knowledge of the propagation +delay when no other traffic is present. +In common scenarios this +occurs during other than work hours. +The filter maintains a shift +register that remembers the minimum delay over the most recent +interval measured usually in hours. +Under conditions of severe +delay, the filter corrects the apparent offset using the sign of +the offset and the difference between the apparent delay and +minimum delay. +The name of the filter reflects the negative (huff) +and positive (puff) correction, which depends on the sign of the +offset. +.Pp +The filter is activated by the +.Ic tinker +command and +.Cm huffpuff +keyword, as described in +.Xr ntp.conf 5 . + _END_MDOC_USAGE; +}; + +doc-section = { + ds-type = 'FILES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_FILES +.Bl -tag -width /etc/ntp.drift -compact +.It Pa /etc/ntp.conf +the default name of the configuration file +.It Pa /etc/ntp.drift +the default name of the drift file +.It Pa /etc/ntp.keys +the default name of the key file +.El + _END_MDOC_FILES; +}; + +doc-section = { + ds-type = 'SEE ALSO'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_SEE_ALSO +.Xr ntp.conf 5 , +.Xr ntpdate 1ntpdatemdoc , +.Xr ntpdc 1ntpdcmdoc , +.Xr ntpq 1ntpqmdoc , +.Xr sntp 1sntpmdoc +.Pp +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +.Li http://www.ntp.org/ . +A snapshot of this documentation is available in HTML format in +.Pa /usr/share/doc/ntp . +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 1) +.%O RFC1059 +.Re +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 2) +.%O RFC1119 +.Re +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 3) +.%O RFC1305 +.Re +.Rs +.%A David L. Mills +.%A J. Martin, Ed. +.%A J. Burbank +.%A W. Kasch +.%T Network Time Protocol Version 4: Protocol and Algorithms Specification +.%O RFC5905 +.Re +.Rs +.%A David L. Mills +.%A B. Haberman, Ed. +.%T Network Time Protocol Version 4: Autokey Specification +.%O RFC5906 +.Re +.Rs +.%A H. Gerstung +.%A C. Elliott +.%A B. Haberman, Ed. +.%T Definitions of Managed Objects for Network Time Protocol Version 4: (NTPv4) +.%O RFC5907 +.Re +.Rs +.%A R. Gayraud +.%A B. Lourdelet +.%T Network Time Protocol (NTP) Server Option for DHCPv6 +.%O RFC5908 +.Re + _END_MDOC_SEE_ALSO; +}; + +doc-section = { + ds-type = 'BUGS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_BUGS +The +.Nm +utility has gotten rather fat. +While not huge, it has gotten +larger than might be desirable for an elevated-priority +.Nm +running on a workstation, particularly since many of +the fancy features which consume the space were designed more with +a busy primary server, rather than a high stratum workstation in +mind. + _END_MDOC_BUGS; +}; + +doc-section = { + ds-type = 'NOTES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_NOTES +Portions of this document came from FreeBSD. + _END_MDOC_NOTES; +}; diff --git a/contrib/ntp/ntpd/ntpd-opts.h b/contrib/ntp/ntpd/ntpd-opts.h index 0347f333a..d87c2216d 100644 --- a/contrib/ntp/ntpd/ntpd-opts.h +++ b/contrib/ntp/ntpd/ntpd-opts.h @@ -1,117 +1,162 @@ -/* +/* * EDIT THIS FILE WITH CAUTION (ntpd-opts.h) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:09 AM EST + * + * It has been AutoGen-ed October 21, 2015 at 12:35:59 PM by AutoGen 5.18.5 * From the definitions ntpd-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This header file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpd author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. + * Generated from AutoOpts 41:0:16 templates. + * + * AutoOpts is a copyrighted work. This header file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpd author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. * - * This source file is copyrighted and licensed under the following terms: + * The ntpd program is copyrighted and licensed + * under the following terms: * - * ntpd copyright 1970-2009 David L. Mills and/or others - all rights reserved + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * * - * see html/copyright.html + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. */ -/* +/** * This file contains the programmatic interface to the Automated * Options generated for the ntpd program. * These macros are documented in the AutoGen info file in the * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_NTPD_OPTS_H_GUARD -#define AUTOOPTS_NTPD_OPTS_H_GUARD +#define AUTOOPTS_NTPD_OPTS_H_GUARD 1 #include "config.h" #include -/* +/** * Ensure that the library used for compiling this generated header is at * least as new as the version current when the header template was released * (not counting patch version increments). Also ensure that the oldest * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 167936 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header Choke Me. #endif -/* - * Enumeration of each option: +/** + * Enumeration of each option type for ntpd */ typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_AUTHREQ = 2, - INDEX_OPT_AUTHNOREQ = 3, - INDEX_OPT_BCASTSYNC = 4, - INDEX_OPT_CONFIGFILE = 5, - INDEX_OPT_DEBUG_LEVEL = 6, - INDEX_OPT_SET_DEBUG_LEVEL = 7, - INDEX_OPT_DRIFTFILE = 8, - INDEX_OPT_PANICGATE = 9, - INDEX_OPT_JAILDIR = 10, - INDEX_OPT_INTERFACE = 11, - INDEX_OPT_KEYFILE = 12, - INDEX_OPT_LOGFILE = 13, - INDEX_OPT_NOVIRTUALIPS = 14, - INDEX_OPT_MODIFYMMTIMER = 15, - INDEX_OPT_NOFORK = 16, - INDEX_OPT_NICE = 17, - INDEX_OPT_PIDFILE = 18, - INDEX_OPT_PRIORITY = 19, - INDEX_OPT_QUIT = 20, - INDEX_OPT_PROPAGATIONDELAY = 21, - INDEX_OPT_UPDATEINTERVAL = 22, - INDEX_OPT_STATSDIR = 23, - INDEX_OPT_TRUSTEDKEY = 24, - INDEX_OPT_USER = 25, - INDEX_OPT_VAR = 26, - INDEX_OPT_DVAR = 27, - INDEX_OPT_SLEW = 28, - INDEX_OPT_VERSION = 29, - INDEX_OPT_HELP = 30, - INDEX_OPT_MORE_HELP = 31 + INDEX_OPT_IPV4 = 0, + INDEX_OPT_IPV6 = 1, + INDEX_OPT_AUTHREQ = 2, + INDEX_OPT_AUTHNOREQ = 3, + INDEX_OPT_BCASTSYNC = 4, + INDEX_OPT_CONFIGFILE = 5, + INDEX_OPT_DEBUG_LEVEL = 6, + INDEX_OPT_SET_DEBUG_LEVEL = 7, + INDEX_OPT_DRIFTFILE = 8, + INDEX_OPT_PANICGATE = 9, + INDEX_OPT_FORCE_STEP_ONCE = 10, + INDEX_OPT_JAILDIR = 11, + INDEX_OPT_INTERFACE = 12, + INDEX_OPT_KEYFILE = 13, + INDEX_OPT_LOGFILE = 14, + INDEX_OPT_NOVIRTUALIPS = 15, + INDEX_OPT_MODIFYMMTIMER = 16, + INDEX_OPT_NOFORK = 17, + INDEX_OPT_NICE = 18, + INDEX_OPT_PIDFILE = 19, + INDEX_OPT_PRIORITY = 20, + INDEX_OPT_QUIT = 21, + INDEX_OPT_PROPAGATIONDELAY = 22, + INDEX_OPT_SAVECONFIGQUIT = 23, + INDEX_OPT_STATSDIR = 24, + INDEX_OPT_TRUSTEDKEY = 25, + INDEX_OPT_USER = 26, + INDEX_OPT_UPDATEINTERVAL = 27, + INDEX_OPT_VAR = 28, + INDEX_OPT_DVAR = 29, + INDEX_OPT_WAIT_SYNC = 30, + INDEX_OPT_SLEW = 31, + INDEX_OPT_USEPCC = 32, + INDEX_OPT_PCCFREQ = 33, + INDEX_OPT_MDNS = 34, + INDEX_OPT_VERSION = 35, + INDEX_OPT_HELP = 36, + INDEX_OPT_MORE_HELP = 37 } teOptIndex; +/** count of all options for ntpd */ +#define OPTION_CT 38 +/** ntpd version */ +#define NTPD_VERSION "4.2.8p4" +/** Full ntpd version text */ +#define NTPD_FULL_VERSION "ntpd 4.2.8p4" -#define OPTION_CT 32 -#define NTPD_VERSION "4.2.4p8" -#define NTPD_FULL_VERSION "ntpd - NTP daemon program - Ver. 4.2.4p8" - -/* +/** * Interface defines for all options. Replace "n" with the UPPER_CASED * option name (as in the teOptIndex enumeration above). - * e.g. HAVE_OPT( IPV4 ) + * e.g. HAVE_OPT(IPV4) */ #define DESC(n) (ntpdOptions.pOptDesc[INDEX_OPT_## n]) +/** 'true' if an option has been specified in any way */ #define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) +/** The string argument to an option. The argument type must be \"string\". */ #define OPT_ARG(n) (DESC(n).optArg.argString) +/** Mask the option state revealing how an option was specified. + * It will be one and only one of \a OPTST_SET, \a OPTST_PRESET, + * \a OPTST_DEFINED, \a OPTST_RESET or zero. + */ #define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) +/** Count of option's occurrances *on the command line*. */ #define COUNT_OPT(n) (DESC(n).optOccCt) +/** mask of \a OPTST_SET and \a OPTST_DEFINED. */ #define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) +/** 'true' if \a HAVE_OPT would yield 'false'. */ #define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) +/** 'true' if OPTST_DISABLED bit not set. */ #define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) +/** number of stacked option arguments. + * Valid only for stacked option arguments. */ #define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) +/** stacked argument vector. + * Valid only for stacked option arguments. */ #define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) +/** Reset an option. */ #define CLEAR_OPT(n) STMTS( \ DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ - if ( (DESC(n).fOptState & OPTST_INITENABLED) == 0) \ + if ((DESC(n).fOptState & OPTST_INITENABLED) == 0) \ DESC(n).fOptState |= OPTST_DISABLED; \ DESC(n).optCookie = NULL ) - -/* +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Enumeration of ntpd exit codes + */ +typedef enum { + NTPD_EXIT_SUCCESS = 0, + NTPD_EXIT_FAILURE = 1, + NTPD_EXIT_USAGE_ERROR = 64, + NTPD_EXIT_LIBOPTS_FAILURE = 70 +} ntpd_exit_code_t; +/** @} */ +/** * Make sure there are no #define name conflicts with the option names */ #ifndef NO_OPTION_NAME_WARNINGS @@ -155,6 +200,10 @@ typedef enum { # warning undefining PANICGATE due to option name conflict # undef PANICGATE # endif +# ifdef FORCE_STEP_ONCE +# warning undefining FORCE_STEP_ONCE due to option name conflict +# undef FORCE_STEP_ONCE +# endif # ifdef JAILDIR # warning undefining JAILDIR due to option name conflict # undef JAILDIR @@ -203,9 +252,9 @@ typedef enum { # warning undefining PROPAGATIONDELAY due to option name conflict # undef PROPAGATIONDELAY # endif -# ifdef UPDATEINTERVAL -# warning undefining UPDATEINTERVAL due to option name conflict -# undef UPDATEINTERVAL +# ifdef SAVECONFIGQUIT +# warning undefining SAVECONFIGQUIT due to option name conflict +# undef SAVECONFIGQUIT # endif # ifdef STATSDIR # warning undefining STATSDIR due to option name conflict @@ -219,6 +268,10 @@ typedef enum { # warning undefining USER due to option name conflict # undef USER # endif +# ifdef UPDATEINTERVAL +# warning undefining UPDATEINTERVAL due to option name conflict +# undef UPDATEINTERVAL +# endif # ifdef VAR # warning undefining VAR due to option name conflict # undef VAR @@ -227,10 +280,26 @@ typedef enum { # warning undefining DVAR due to option name conflict # undef DVAR # endif +# ifdef WAIT_SYNC +# warning undefining WAIT_SYNC due to option name conflict +# undef WAIT_SYNC +# endif # ifdef SLEW # warning undefining SLEW due to option name conflict # undef SLEW # endif +# ifdef USEPCC +# warning undefining USEPCC due to option name conflict +# undef USEPCC +# endif +# ifdef PCCFREQ +# warning undefining PCCFREQ due to option name conflict +# undef PCCFREQ +# endif +# ifdef MDNS +# warning undefining MDNS due to option name conflict +# undef MDNS +# endif #else /* NO_OPTION_NAME_WARNINGS */ # undef IPV4 # undef IPV6 @@ -242,6 +311,7 @@ typedef enum { # undef SET_DEBUG_LEVEL # undef DRIFTFILE # undef PANICGATE +# undef FORCE_STEP_ONCE # undef JAILDIR # undef INTERFACE # undef KEYFILE @@ -254,98 +324,142 @@ typedef enum { # undef PRIORITY # undef QUIT # undef PROPAGATIONDELAY -# undef UPDATEINTERVAL +# undef SAVECONFIGQUIT # undef STATSDIR # undef TRUSTEDKEY # undef USER +# undef UPDATEINTERVAL # undef VAR # undef DVAR +# undef WAIT_SYNC # undef SLEW +# undef USEPCC +# undef PCCFREQ +# undef MDNS #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/** * Interface defines for specific options. + * @{ */ #define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) #define VALUE_OPT_IPV6 '6' #define VALUE_OPT_AUTHREQ 'a' #define VALUE_OPT_AUTHNOREQ 'A' #define VALUE_OPT_BCASTSYNC 'b' #define VALUE_OPT_CONFIGFILE 'c' -#ifdef DEBUG #define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG #define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ + +#define OPT_VALUE_SET_DEBUG_LEVEL (DESC(SET_DEBUG_LEVEL).optArg.argInt) #define VALUE_OPT_DRIFTFILE 'f' #define VALUE_OPT_PANICGATE 'g' +#define VALUE_OPT_FORCE_STEP_ONCE 'G' #define VALUE_OPT_JAILDIR 'i' #define VALUE_OPT_INTERFACE 'I' #define VALUE_OPT_KEYFILE 'k' #define VALUE_OPT_LOGFILE 'l' #define VALUE_OPT_NOVIRTUALIPS 'L' -#ifdef SYS_WINNT #define VALUE_OPT_MODIFYMMTIMER 'M' -#endif /* SYS_WINNT */ #define VALUE_OPT_NOFORK 'n' #define VALUE_OPT_NICE 'N' #define VALUE_OPT_PIDFILE 'p' #define VALUE_OPT_PRIORITY 'P' + #define OPT_VALUE_PRIORITY (DESC(PRIORITY).optArg.argInt) #define VALUE_OPT_QUIT 'q' #define VALUE_OPT_PROPAGATIONDELAY 'r' -#define VALUE_OPT_UPDATEINTERVAL 'U' -#define OPT_VALUE_UPDATEINTERVAL (DESC(UPDATEINTERVAL).optArg.argInt) +#define VALUE_OPT_SAVECONFIGQUIT 0x1001 #define VALUE_OPT_STATSDIR 's' #define VALUE_OPT_TRUSTEDKEY 't' #define VALUE_OPT_USER 'u' -#define VALUE_OPT_VAR 'v' -#define VALUE_OPT_DVAR 'V' -#define VALUE_OPT_SLEW 'x' +#define VALUE_OPT_UPDATEINTERVAL 'U' -#define VALUE_OPT_VERSION 'v' +#define OPT_VALUE_UPDATEINTERVAL (DESC(UPDATEINTERVAL).optArg.argInt) +#define VALUE_OPT_VAR 0x1002 +#define VALUE_OPT_DVAR 0x1003 +#define VALUE_OPT_WAIT_SYNC 'w' +#ifdef HAVE_WORKING_FORK +#define OPT_VALUE_WAIT_SYNC (DESC(WAIT_SYNC).optArg.argInt) +#endif /* HAVE_WORKING_FORK */ +#define VALUE_OPT_SLEW 'x' +#define VALUE_OPT_USEPCC 0x1004 +#define VALUE_OPT_PCCFREQ 0x1005 +#define VALUE_OPT_MDNS 'm' +/** option flag (value) for help-value option */ #define VALUE_OPT_HELP '?' +/** option flag (value) for more-help-value option */ #define VALUE_OPT_MORE_HELP '!' +/** option flag (value) for version-value option */ +#define VALUE_OPT_VERSION 0x1006 /* * Interface defines not associated with particular options */ -#define ERRSKIP_OPTERR STMTS( ntpdOptions.fOptSet &= ~OPTPROC_ERRSTOP ) -#define ERRSTOP_OPTERR STMTS( ntpdOptions.fOptSet |= OPTPROC_ERRSTOP ) +#define ERRSKIP_OPTERR STMTS(ntpdOptions.fOptSet &= ~OPTPROC_ERRSTOP) +#define ERRSTOP_OPTERR STMTS(ntpdOptions.fOptSet |= OPTPROC_ERRSTOP) #define RESTART_OPT(n) STMTS( \ ntpdOptions.curOptIdx = (n); \ ntpdOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) -#define USAGE(c) (*ntpdOptions.pUsageProc)( &ntpdOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +#define USAGE(c) (*ntpdOptions.pUsageProc)(&ntpdOptions, c) + +#ifdef __cplusplus +extern "C" { +#endif + /* * * * * * * * Declare the ntpd option descriptor. */ -#ifdef __cplusplus -extern "C" { -#endif +extern tOptions ntpdOptions; -extern tOptions ntpdOptions; +#if defined(ENABLE_NLS) +# ifndef _ +# include +# ifndef HAVE_GETTEXT + extern char * gettext(char const *); +# else +# include +# endif -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +# ifndef ATTRIBUTE_FORMAT_ARG +# define ATTRIBUTE_FORMAT_ARG(_a) +# endif + +static inline char* aoGetsText(char const* pz) ATTRIBUTE_FORMAT_ARG(1); +static inline char* aoGetsText(char const* pz) { + if (pz == NULL) return NULL; + return (char*)gettext(pz); +} +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpdOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpdOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } #endif #endif /* AUTOOPTS_NTPD_OPTS_H_GUARD */ + /* ntpd-opts.h ends here */ diff --git a/contrib/ntp/ntpd/ntpd-opts.texi b/contrib/ntp/ntpd/ntpd-opts.texi deleted file mode 100644 index 04912945b..000000000 --- a/contrib/ntp/ntpd/ntpd-opts.texi +++ /dev/null @@ -1,496 +0,0 @@ -@node ntpd Invocation -@section Invoking ntpd -@pindex ntpd -@cindex NTP daemon program -@ignore -# -# EDIT THIS FILE WITH CAUTION (ntpd-opts.texi) -# -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:12 AM EST -# From the definitions ntpd-opts.def -# and the template file aginfo.tpl -@end ignore -This program has no explanation. - - - -This section was generated by @strong{AutoGen}, -the aginfo template and the option descriptions for the @command{ntpd} program. It documents the ntpd usage text and option meanings. - -This software is released under a specialized copyright license. - -@menu -* ntpd usage:: ntpd usage help (-?) -* ntpd authnoreq:: authnoreq option (-A) -* ntpd authreq:: authreq option (-a) -* ntpd bcastsync:: bcastsync option (-b) -* ntpd configfile:: configfile option (-c) -* ntpd debug-level:: debug-level option (-d) -* ntpd driftfile:: driftfile option (-f) -* ntpd dvar:: dvar option (-V) -* ntpd interface:: interface option (-I) -* ntpd ipv4:: ipv4 option (-4) -* ntpd ipv6:: ipv6 option (-6) -* ntpd jaildir:: jaildir option (-i) -* ntpd keyfile:: keyfile option (-k) -* ntpd logfile:: logfile option (-l) -* ntpd modifymmtimer:: modifymmtimer option (-M) -* ntpd nice:: nice option (-N) -* ntpd nofork:: nofork option (-n) -* ntpd novirtualips:: novirtualips option (-L) -* ntpd panicgate:: panicgate option (-g) -* ntpd pidfile:: pidfile option (-p) -* ntpd priority:: priority option (-P) -* ntpd propagationdelay:: propagationdelay option (-r) -* ntpd quit:: quit option (-q) -* ntpd set-debug-level:: set-debug-level option (-D) -* ntpd slew:: slew option (-x) -* ntpd statsdir:: statsdir option (-s) -* ntpd trustedkey:: trustedkey option (-t) -* ntpd updateinterval:: updateinterval option (-U) -* ntpd user:: user option (-u) -* ntpd var:: var option (-v) -@end menu - -@node ntpd usage -@subsection ntpd usage help (-?) -@cindex ntpd usage - -This is the automatically generated usage text for ntpd: - -@exampleindent 0 -@example -ntpd - NTP daemon program - Ver. 4.2.5p247-RC -USAGE: ntpd [ - [] | --[@{=| @}] ]... - Flg Arg Option-Name Description - -4 no ipv4 Force IPv4 DNS name resolution - - prohibits these options: - ipv6 - -6 no ipv6 Force IPv6 DNS name resolution - - prohibits these options: - ipv4 - -a no authreq Require crypto authentication - - prohibits these options: - authnoreq - -A no authnoreq Do not require crypto authentication - - prohibits these options: - authreq - -b no bcastsync Allow us to sync to broadcast servers - -c Str configfile configuration file name - -d no debug-level Increase output debug message level - - may appear multiple times - -D Str set-debug-level Set the output debug message level - - may appear multiple times - -f Str driftfile frequency drift file name - -g no panicgate Allow the first adjustment to be Big - - may appear multiple times - -i --- jaildir built without --enable-clockctl or --enable-linuxcaps - -I Str interface Listen on an interface name or address - - may appear multiple times - -k Str keyfile path to symmetric keys - -l Str logfile path to the log file - -L no novirtualips Do not listen to virtual interfaces - -n no nofork Do not fork - -N no nice Run at high priority - -p Str pidfile path to the PID file - -P Num priority Process priority - -q no quit Set the time and quit - -r Str propagationdelay Broadcast/propagation delay - Str saveconfigquit Save parsed configuration and quit - -s Str statsdir Statistics file location - -t Str trustedkey Trusted key number - - may appear multiple times - -u --- user built without --enable-clockctl or --enable-linuxcaps - -U Num updateinterval interval in seconds between scans for new or dropped interfaces - Str var make ARG an ntp variable (RW) - - may appear multiple times - Str dvar make ARG an ntp variable (RW|DEF) - - may appear multiple times - -x no slew Slew up to 600 seconds - opt version Output version information and exit - -? no help Display extended usage information and exit - -! no more-help Extended usage information passed thru pager - -Options are specified by doubled hyphens and their name -or by a single hyphen and the flag character. - -The following option preset mechanisms are supported: - - examining environment variables named NTPD_* - - - -please send bug reports to: http://bugs.ntp.org, bugs@@ntp.org -@end example -@exampleindent 4 - -@node ntpd ipv4 -@subsection ipv4 option (-4) -@cindex ntpd-ipv4 - -This is the ``force ipv4 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv4 namespace. - -@node ntpd ipv6 -@subsection ipv6 option (-6) -@cindex ntpd-ipv6 - -This is the ``force ipv6 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv6 namespace. - -@node ntpd authreq -@subsection authreq option (-a) -@cindex ntpd-authreq - -This is the ``require crypto authentication'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -authnoreq. -@end itemize - -Require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is the default. - -@node ntpd authnoreq -@subsection authnoreq option (-A) -@cindex ntpd-authnoreq - -This is the ``do not require crypto authentication'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -authreq. -@end itemize - -Do not require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is almost never a good idea. - -@node ntpd bcastsync -@subsection bcastsync option (-b) -@cindex ntpd-bcastsync - -This is the ``allow us to sync to broadcast servers'' option. - - -@node ntpd configfile -@subsection configfile option (-c) -@cindex ntpd-configfile - -This is the ``configuration file name'' option. -The name and path of the configuration file, -/etc/ntp.conf -by default. - -@node ntpd debug-level -@subsection debug-level option (-d) -@cindex ntpd-debug-level - -This is the ``increase output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Increase the debugging message output level. - -@node ntpd set-debug-level -@subsection set-debug-level option (-D) -@cindex ntpd-set-debug-level - -This is the ``set the output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). - -@node ntpd driftfile -@subsection driftfile option (-f) -@cindex ntpd-driftfile - -This is the ``frequency drift file name'' option. -The name and path of the frequency file, -/etc/ntp.drift -by default. -This is the same operation as the -driftfile driftfile -configuration specification in the -/etc/ntp.conf -file. - -@node ntpd panicgate -@subsection panicgate option (-g) -@cindex ntpd-panicgate - -This is the ``allow the first adjustment to be big'' option. -Normally, -ntpd -exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, -ntpd -will exit with a message to the system log. This option can be used with the --q -and --x -options. -See the -tinker -configuration file directive for other options. - -@node ntpd jaildir -@subsection jaildir option (-i) -@cindex ntpd-jaildir - -This is the ``jail directory'' option. -Chroot the server to the directory -jaildir -. -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. -You may need to also specify a --u -option. - -@node ntpd interface -@subsection interface option (-I) -@cindex ntpd-interface - -This is the ``listen on interface'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpd keyfile -@subsection keyfile option (-k) -@cindex ntpd-keyfile - -This is the ``path to symmetric keys'' option. -Specify the name and path of the symmetric key file. -/etc/ntp.keys -is the default. -This is the same operation as the -keys keyfile -configuration file directive. - -@node ntpd logfile -@subsection logfile option (-l) -@cindex ntpd-logfile - -This is the ``path to the log file'' option. -Specify the name and path of the log file. -The default is the system log file. -This is the same operation as the -logfile logfile -configuration file directive. - -@node ntpd novirtualips -@subsection novirtualips option (-L) -@cindex ntpd-novirtualips - -This is the ``do not listen to virtual ips'' option. -Do not listen to virtual IPs. The default is to listen. - -@node ntpd modifymmtimer -@subsection modifymmtimer option (-M) -@cindex ntpd-modifymmtimer - -This is the ``modify multimedia timer (windows only)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must be compiled in by defining @code{SYS_WINNT} during the compilation. -@end itemize - -Set the Windows Multimedia Timer to highest resolution. - -@node ntpd nofork -@subsection nofork option (-n) -@cindex ntpd-nofork - -This is the ``do not fork'' option. - - -@node ntpd nice -@subsection nice option (-N) -@cindex ntpd-nice - -This is the ``run at high priority'' option. -To the extent permitted by the operating system, run -ntpd -at the highest priority. - -@node ntpd pidfile -@subsection pidfile option (-p) -@cindex ntpd-pidfile - -This is the ``path to the pid file'' option. -Specify the name and path of the file used to record -ntpd's -process ID. -This is the same operation as the -pidfile pidfile -configuration file directive. - -@node ntpd priority -@subsection priority option (-P) -@cindex ntpd-priority - -This is the ``process priority'' option. -To the extent permitted by the operating system, run -ntpd -at the specified -sched_setscheduler(SCHED_FIFO) -priority. - -@node ntpd quit -@subsection quit option (-q) -@cindex ntpd-quit - -This is the ``set the time and quit'' option. -ntpd -will exit just after the first time the clock is set. This behavior mimics that of the -ntpdate -program, which is to be retired. -The --g -and --x -options can be used with this option. -Note: The kernel time discipline is disabled with this option. - -@node ntpd propagationdelay -@subsection propagationdelay option (-r) -@cindex ntpd-propagationdelay - -This is the ``broadcast/propagation delay'' option. -Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. - -@node ntpd updateinterval -@subsection updateinterval option (-U) -@cindex ntpd-updateinterval - -This is the ``interval in seconds between scans for new or dropped interfaces'' option. -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. - -@node ntpd statsdir -@subsection statsdir option (-s) -@cindex ntpd-statsdir - -This is the ``statistics file location'' option. -Specify the directory path for files created by the statistics facility. -This is the same operation as the -statsdir statsdir -configuration file directive. - -@node ntpd trustedkey -@subsection trustedkey option (-t) -@cindex ntpd-trustedkey - -This is the ``trusted key number'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - -Add a key number to the trusted key list. - -@node ntpd user -@subsection user option (-u) -@cindex ntpd-user - -This is the ``run as userid (or userid:groupid)'' option. -Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with ---enable-clockctl -) and Linux (configure with ---enable-linuxcaps -). - -@node ntpd var -@subsection var option (-v) -@cindex ntpd-var - -This is the ``make arg an ntp variable (rw)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpd dvar -@subsection dvar option (-V) -@cindex ntpd-dvar - -This is the ``make arg an ntp variable (rw|def)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpd slew -@subsection slew option (-x) -@cindex ntpd-slew - -This is the ``slew up to 600 seconds'' option. -Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. -This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. -Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. -Thus, an adjustment as much as 600 s will take almost 14 days to complete. -This option can be used with the --g -and --q -options. -See the -tinker -configuration file directive for other options. -Note: The kernel time discipline is disabled with this option. diff --git a/contrib/ntp/ntpd/ntpd.1 b/contrib/ntp/ntpd/ntpd.1 deleted file mode 100644 index ec0a0ed75..000000000 --- a/contrib/ntp/ntpd/ntpd.1 +++ /dev/null @@ -1,296 +0,0 @@ -.TH NTPD 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" -.\" EDIT THIS FILE WITH CAUTION (ntpd.1) -.\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:11 AM EST -.\" From the definitions ntpd-opts.def -.\" and the template file agman1.tpl -.\" -.SH NAME -ntpd \- NTP daemon program -.SH SYNOPSIS -.B ntpd -.\" Mixture of short (flag) options and long options -.RB [ \-\fIflag\fP " [\fIvalue\fP]]... [" \--\fIopt-name\fP " [[=| ]\fIvalue\fP]]..." -.PP -All arguments must be options. -.SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpd\fP command. - -.SH OPTIONS -.TP -.BR \-4 ", " \--ipv4 -Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv4 namespace. -.TP -.BR \-6 ", " \--ipv6 -Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv6 namespace. -.TP -.BR \-a ", " \--authreq -Require crypto authentication. -This option must not appear in combination with any of the following options: -authnoreq. -.sp -Require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is the default. -.TP -.BR \-A ", " \--authnoreq -Do not require crypto authentication. -This option must not appear in combination with any of the following options: -authreq. -.sp -Do not require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is almost never a good idea. -.TP -.BR \-b ", " \--bcastsync -Allow us to sync to broadcast servers. -.sp - -.TP -.BR \-c " \fIstring\fP, " \--configfile "=" \fIstring\fP -configuration file name. -.sp -The name and path of the configuration file, -/etc/ntp.conf -by default. -.TP -.BR \-d ", " \--debug-level -Increase output debug message level. -This option may appear an unlimited number of times. -.sp -Increase the debugging message output level. -.TP -.BR \-D " \fIstring\fP, " \--set-debug-level "=" \fIstring\fP -Set the output debug message level. -This option may appear an unlimited number of times. -.sp -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). -.TP -.BR \-f " \fIstring\fP, " \--driftfile "=" \fIstring\fP -frequency drift file name. -.sp -The name and path of the frequency file, -/etc/ntp.drift -by default. -This is the same operation as the -driftfile driftfile -configuration specification in the -/etc/ntp.conf -file. -.TP -.BR \-g ", " \--panicgate -Allow the first adjustment to be Big. -.sp -Normally, -ntpd -exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, -ntpd -will exit with a message to the system log. This option can be used with the --q -and --x -options. -See the -tinker -configuration file directive for other options. -.TP -.BR \-i " \fIstring\fP, " \--jaildir "=" \fIstring\fP -Jail directory. -.sp -Chroot the server to the directory -jaildir -. -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. -You may need to also specify a --u -option. -.TP -.BR \-I " \fIiface\fP, " \--interface "=" \fIiface\fP -Listen on interface. -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-k " \fIstring\fP, " \--keyfile "=" \fIstring\fP -path to symmetric keys. -.sp -Specify the name and path of the symmetric key file. -/etc/ntp.keys -is the default. -This is the same operation as the -keys keyfile -configuration file directive. -.TP -.BR \-l " \fIstring\fP, " \--logfile "=" \fIstring\fP -path to the log file. -.sp -Specify the name and path of the log file. -The default is the system log file. -This is the same operation as the -logfile logfile -configuration file directive. -.TP -.BR \-L ", " \--novirtualips -Do not listen to virtual IPs. -.sp -Do not listen to virtual IPs. The default is to listen. -.TP -.BR \-M ", " \--modifymmtimer -Modify Multimedia Timer (Windows only). -.sp -Set the Windows Multimedia Timer to highest resolution. -.TP -.BR \-n ", " \--nofork -Do not fork. -.sp - -.TP -.BR \-N ", " \--nice -Run at high priority. -.sp -To the extent permitted by the operating system, run -ntpd -at the highest priority. -.TP -.BR \-p " \fIstring\fP, " \--pidfile "=" \fIstring\fP -path to the PID file. -.sp -Specify the name and path of the file used to record -ntpd's -process ID. -This is the same operation as the -pidfile pidfile -configuration file directive. -.TP -.BR \-P " \fInumber\fP, " \--priority "=" \fInumber\fP -Process priority. -This option takes an integer number as its argument. -.sp -To the extent permitted by the operating system, run -ntpd -at the specified -sched_setscheduler(SCHED_FIFO) -priority. -.TP -.BR \-q ", " \--quit -Set the time and quit. -.sp -ntpd -will exit just after the first time the clock is set. This behavior mimics that of the -ntpdate -program, which is to be retired. -The --g -and --x -options can be used with this option. -Note: The kernel time discipline is disabled with this option. -.TP -.BR \-r " \fIstring\fP, " \--propagationdelay "=" \fIstring\fP -Broadcast/propagation delay. -.sp -Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. -.TP -.BR \-U " \fInumber\fP, " \--updateinterval "=" \fInumber\fP -interval in seconds between scans for new or dropped interfaces. -This option takes an integer number as its argument. -.sp -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. -.TP -.BR \-s " \fIstring\fP, " \--statsdir "=" \fIstring\fP -Statistics file location. -.sp -Specify the directory path for files created by the statistics facility. -This is the same operation as the -statsdir statsdir -configuration file directive. -.TP -.BR \-t " \fItkey\fP, " \--trustedkey "=" \fItkey\fP -Trusted key number. -This option may appear an unlimited number of times. -.sp -Add a key number to the trusted key list. -.TP -.BR \-u " \fIstring\fP, " \--user "=" \fIstring\fP -Run as userid (or userid:groupid). -.sp -Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with ---enable-clockctl -) and Linux (configure with ---enable-linuxcaps -). -.TP -.BR \-v " \fInvar\fP, " \--var "=" \fInvar\fP -make ARG an ntp variable (RW). -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-V " \fIndvar\fP, " \--dvar "=" \fIndvar\fP -make ARG an ntp variable (RW|DEF). -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-x ", " \--slew -Slew up to 600 seconds. -.sp -Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. -This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. -Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. -Thus, an adjustment as much as 600 s will take almost 14 days to complete. -This option can be used with the --g -and --q -options. -See the -tinker -configuration file directive for other options. -Note: The kernel time discipline is disabled with this option. -.TP -.BR \-? , " \--help" -Display usage information and exit. -.TP -.BR \-! , " \--more-help" -Extended usage information passed thru pager. -.TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" -Output version of program and exit. The default mode is `v', a simple -version. The `c' mode will print copyright information and `n' will -print the full copyright notice. -.SH OPTION PRESETS -Any option that is not marked as \fInot presettable\fP may be preset -by loading values from environment variables named: -.nf - \fBNTPD_\fP or \fBNTPD\fP -.fi -.aj -.SH AUTHOR -David L. Mills and/or others -.br -Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org - -.PP -.nf -.na -see html/copyright.html -.fi -.ad -.PP -This manual page was \fIAutoGen\fP-erated from the \fBntpd\fP -option definitions. diff --git a/contrib/ntp/ntpd/ntpd.1ntpdman b/contrib/ntp/ntpd/ntpd.1ntpdman new file mode 100644 index 000000000..187a79a79 --- /dev/null +++ b/contrib/ntp/ntpd/ntpd.1ntpdman @@ -0,0 +1,1005 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpd 1ntpdman "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-dUaOfK/ag-qUaGeK) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:11 PM by AutoGen 5.18.5 +.\" From the definitions ntpd-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpd\fP +\- NTP daemon program +.SH SYNOPSIS +\f\*[B-Font]ntpd\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[ ... ] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The +\f\*[B-Font]ntpd\fP +utility is an operating system daemon which sets +and maintains the system time of day in synchronism with Internet +standard time servers. +It is a complete implementation of the +Network Time Protocol (NTP) version 4, as defined by RFC-5905, +but also retains compatibility with +version 3, as defined by RFC-1305, and versions 1 +and 2, as defined by RFC-1059 and RFC-1119, respectively. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]ntpd\fP +utility does most computations in 64-bit floating point +arithmetic and does relatively clumsy 64-bit fixed point operations +only when necessary to preserve the ultimate precision, about 232 +picoseconds. +While the ultimate precision is not achievable with +ordinary workstations and networks of today, it may be required +with future gigahertz CPU clocks and gigabit LANs. +.sp \n(Ppu +.ne 2 + +Ordinarily, +\f\*[B-Font]ntpd\fP +reads the +\fCntp.conf\f[]\fR(5)\f[] +configuration file at startup time in order to determine the +synchronization sources and operating modes. +It is also possible to +specify a working, although limited, configuration entirely on the +command line, obviating the need for a configuration file. +This may +be particularly useful when the local host is to be configured as a +broadcast/multicast client, with all peers being determined by +listening to broadcasts at run time. +.sp \n(Ppu +.ne 2 + +If NetInfo support is built into +\f\*[B-Font]ntpd\fP, +then +\f\*[B-Font]ntpd\fP +will attempt to read its configuration from the +NetInfo if the default +\fCntp.conf\f[]\fR(5)\f[] +file cannot be read and no file is +specified by the +\f\*[B-Font]\-c\f[] +option. +.sp \n(Ppu +.ne 2 + +Various internal +\f\*[B-Font]ntpd\fP +variables can be displayed and +configuration options altered while the +\f\*[B-Font]ntpd\fP +is running +using the +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +and +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[] +utility programs. +.sp \n(Ppu +.ne 2 + +When +\f\*[B-Font]ntpd\fP +starts it looks at the value of +\fCumask\f[]\fR(2)\f[], +and if zero +\f\*[B-Font]ntpd\fP +will set the +\fCumask\f[]\fR(2)\f[] +to 022. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.TP +.NOP \f\*[B-Font]\-6\f[], \f\*[B-Font]\-\-ipv6\f[] +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.TP +.NOP \f\*[B-Font]\-a\f[], \f\*[B-Font]\-\-authreq\f[] +Require crypto authentication. +This option must not appear in combination with any of the following options: +authnoreq. +.sp +Require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is the default. +.TP +.NOP \f\*[B-Font]\-A\f[], \f\*[B-Font]\-\-authnoreq\f[] +Do not require crypto authentication. +This option must not appear in combination with any of the following options: +authreq. +.sp +Do not require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is almost never a good idea. +.TP +.NOP \f\*[B-Font]\-b\f[], \f\*[B-Font]\-\-bcastsync\f[] +Allow us to sync to broadcast servers. +.sp +.TP +.NOP \f\*[B-Font]\-c\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-configfile\f[]=\f\*[I-Font]string\f[] +configuration file name. +.sp +The name and path of the configuration file, +\fI/etc/ntp.conf\fP +by default. +.TP +.NOP \f\*[B-Font]\-d\f[], \f\*[B-Font]\-\-debug\-level\f[] +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-D\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-set\-debug\-level\f[]=\f\*[I-Font]number\f[] +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.TP +.NOP \f\*[B-Font]\-f\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-driftfile\f[]=\f\*[I-Font]string\f[] +frequency drift file name. +.sp +The name and path of the frequency file, +\fI/etc/ntp.drift\fP +by default. +This is the same operation as the +\fBdriftfile\fP \fIdriftfile\fP +configuration specification in the +\fI/etc/ntp.conf\fP +file. +.TP +.NOP \f\*[B-Font]\-g\f[], \f\*[B-Font]\-\-panicgate\f[] +Allow the first adjustment to be Big. +This option may appear an unlimited number of times. +.sp +Normally, +\fBntpd\fP +exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, +\fBntpd\fP +will exit with a message to the system log. This option can be used with the +\fB-q\fP +and +\fB-x\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +.TP +.NOP \f\*[B-Font]\-G\f[], \f\*[B-Font]\-\-force\-step\-once\f[] +Step any initial offset correction.. +.sp +Normally, +\fBntpd\fP +steps the time if the time offset exceeds the step threshold, +which is 128 ms by default, and otherwise slews the time. +This option forces the initial offset correction to be stepped, +so the highest time accuracy can be achieved quickly. +However, this may also cause the time to be stepped back +so this option must not be used if +applications requiring monotonic time are running. +See the \fBtinker\fP configuration file directive for other options. +.TP +.NOP \f\*[B-Font]\-i\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-jaildir\f[]=\f\*[I-Font]string\f[] +Jail directory. +.sp +Chroot the server to the directory +\fIjaildir\fP +. +This option also implies that the server attempts to drop root privileges at startup. +You may need to also specify a +\fB-u\fP +option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB--enable-clockctl\fP) or Linux (configure with +\fB--enable-linuxcaps\fP) or Solaris (configure with \fB--enable-solarisprivs\fP). +.TP +.NOP \f\*[B-Font]\-I\f[] \f\*[I-Font]iface\f[], \f\*[B-Font]\-\-interface\f[]=\f\*[I-Font]iface\f[] +Listen on an interface name or address. +This option may appear an unlimited number of times. +.sp +Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +\fBinterface\fP command, which is more versatile. +.TP +.NOP \f\*[B-Font]\-k\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-keyfile\f[]=\f\*[I-Font]string\f[] +path to symmetric keys. +.sp +Specify the name and path of the symmetric key file. +\fI/etc/ntp.keys\fP +is the default. +This is the same operation as the +\fBkeys\fP \fIkeyfile\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-l\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-logfile\f[]=\f\*[I-Font]string\f[] +path to the log file. +.sp +Specify the name and path of the log file. +The default is the system log file. +This is the same operation as the +\fBlogfile\fP \fIlogfile\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-L\f[], \f\*[B-Font]\-\-novirtualips\f[] +Do not listen to virtual interfaces. +.sp +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file \fBinterface\fP command, which +is more versatile. +.TP +.NOP \f\*[B-Font]\-M\f[], \f\*[B-Font]\-\-modifymmtimer\f[] +Modify Multimedia Timer (Windows only). +.sp +Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-nofork\f[] +Do not fork. +This option must not appear in combination with any of the following options: +wait-sync. +.sp +.TP +.NOP \f\*[B-Font]\-N\f[], \f\*[B-Font]\-\-nice\f[] +Run at high priority. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the highest priority. +.TP +.NOP \f\*[B-Font]\-p\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-pidfile\f[]=\f\*[I-Font]string\f[] +path to the PID file. +.sp +Specify the name and path of the file used to record +\fBntpd\fP's +process ID. +This is the same operation as the +\fBpidfile\fP \fIpidfile\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-P\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-priority\f[]=\f\*[I-Font]number\f[] +Process priority. +This option takes an integer number as its argument. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the specified +\fBsched_setscheduler(SCHED_FIFO)\fP +priority. +.TP +.NOP \f\*[B-Font]\-q\f[], \f\*[B-Font]\-\-quit\f[] +Set the time and quit. +This option must not appear in combination with any of the following options: +saveconfigquit, wait-sync. +.sp +\fBntpd\fP +will not daemonize and will exit after the clock is first +synchronized. This behavior mimics that of the +\fBntpdate\fP +program, which will soon be replaced with a shell script. +The +\fB-g\fP +and +\fB-x\fP +options can be used with this option. +Note: The kernel time discipline is disabled with this option. +.TP +.NOP \f\*[B-Font]\-r\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-propagationdelay\f[]=\f\*[I-Font]string\f[] +Broadcast/propagation delay. +.sp +Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. +.TP +.NOP \f\*[B-Font]\-\-saveconfigquit\f[]=\f\*[I-Font]string\f[] +Save parsed configuration and quit. +This option must not appear in combination with any of the following options: +quit, wait-sync. +.sp +Cause \fBntpd\fP to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-statsdir\f[]=\f\*[I-Font]string\f[] +Statistics file location. +.sp +Specify the directory path for files created by the statistics facility. +This is the same operation as the +\fBstatsdir\fP \fIstatsdir\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-t\f[] \f\*[I-Font]tkey\f[], \f\*[B-Font]\-\-trustedkey\f[]=\f\*[I-Font]tkey\f[] +Trusted key number. +This option may appear an unlimited number of times. +.sp +Add the specified key number to the trusted key list. +.TP +.NOP \f\*[B-Font]\-u\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-user\f[]=\f\*[I-Font]string\f[] +Run as userid (or userid:groupid). +.sp +Specify a user, and optionally a group, to switch to. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB--enable-clockctl\fP) or Linux (configure with +\fB--enable-linuxcaps\fP) or Solaris (configure with \fB--enable-solarisprivs\fP). +.TP +.NOP \f\*[B-Font]\-U\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-updateinterval\f[]=\f\*[I-Font]number\f[] +interval in seconds between scans for new or dropped interfaces. +This option takes an integer number as its argument. +.sp +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. +.TP +.NOP \f\*[B-Font]\-\-var\f[]=\f\*[I-Font]nvar\f[] +make ARG an ntp variable (RW). +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-\-dvar\f[]=\f\*[I-Font]ndvar\f[] +make ARG an ntp variable (RW|DEF). +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-w\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-wait\-sync\f[]=\f\*[I-Font]number\f[] +Seconds to wait for first clock sync. +This option must not appear in combination with any of the following options: +nofork, quit, saveconfigquit. +This option takes an integer number as its argument. +.sp +If greater than zero, alters \fBntpd\fP's behavior when forking to +daemonize. Instead of exiting with status 0 immediately after +the fork, the parent waits up to the specified number of +seconds for the child to first synchronize the clock. The exit +status is zero (success) if the clock was synchronized, +otherwise it is \fBETIMEDOUT\fP. +This provides the option for a script starting \fBntpd\fP to easily +wait for the first set of the clock before proceeding. +.TP +.NOP \f\*[B-Font]\-x\f[], \f\*[B-Font]\-\-slew\f[] +Slew up to 600 seconds. +.sp +Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. +This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. +Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. +Thus, an adjustment as much as 600 s will take almost 14 days to complete. +This option can be used with the +\fB-g\fP +and +\fB-q\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +Note: The kernel time discipline is disabled with this option. +.TP +.NOP \f\*[B-Font]\-\-usepcc\f[] +Use CPU cycle counter (Windows only). +.sp +Attempt to substitute the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter and \fBQueryPerformanceCounter\fP are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. +.TP +.NOP \f\*[B-Font]\-\-pccfreq\f[]=\f\*[I-Font]string\f[] +Force CPU cycle counter use (Windows only). +.sp +Force substitution the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). +.TP +.NOP \f\*[B-Font]\-m\f[], \f\*[B-Font]\-\-mdns\f[] +Register with mDNS as a NTP server. +.sp +Registers as an NTP server with the local mDNS server which allows +the server to be discovered via mDNS client lookup. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTPD_\fP or \fBNTPD\fP +.fi +.ad +.SH USAGE +.SS "How NTP Operates" +The +\f\*[B-Font]ntpd\fP +utility operates by exchanging messages with +one or more configured servers over a range of designated poll intervals. +When +started, whether for the first or subsequent times, the program +requires several exchanges from the majority of these servers so +the signal processing and mitigation algorithms can accumulate and +groom the data and set the clock. +In order to protect the network +from bursts, the initial poll interval for each server is delayed +an interval randomized over a few seconds. +At the default initial poll +interval of 64s, several minutes can elapse before the clock is +set. +This initial delay to set the clock +can be safely and dramatically reduced using the +\f\*[B-Font]iburst\f[] +keyword with the +\f\*[B-Font]server\f[] +configuration +command, as described in +\fCntp.conf\f[]\fR(5)\f[]. +.sp \n(Ppu +.ne 2 + +Most operating systems and hardware of today incorporate a +time-of-year (TOY) chip to maintain the time during periods when +the power is off. +When the machine is booted, the chip is used to +initialize the operating system time. +After the machine has +synchronized to a NTP server, the operating system corrects the +chip from time to time. +In the default case, if +\f\*[B-Font]ntpd\fP +detects that the time on the host +is more than 1000s from the server time, +\f\*[B-Font]ntpd\fP +assumes something must be terribly wrong and the only +reliable action is for the operator to intervene and set the clock +by hand. +(Reasons for this include there is no TOY chip, +or its battery is dead, or that the TOY chip is just of poor quality.) +This causes +\f\*[B-Font]ntpd\fP +to exit with a panic message to +the system log. +The +\f\*[B-Font]\-g\f[] +option overrides this check and the +clock will be set to the server time regardless of the chip time +(up to 68 years in the past or future \(em +this is a limitation of the NTPv4 protocol). +However, and to protect against broken hardware, such as when the +CMOS battery fails or the clock counter becomes defective, once the +clock has been set an error greater than 1000s will cause +\f\*[B-Font]ntpd\fP +to exit anyway. +.sp \n(Ppu +.ne 2 + +Under ordinary conditions, +\f\*[B-Font]ntpd\fP +adjusts the clock in +small steps so that the timescale is effectively continuous and +without discontinuities. +Under conditions of extreme network +congestion, the roundtrip delay jitter can exceed three seconds and +the synchronization distance, which is equal to one-half the +roundtrip delay plus error budget terms, can become very large. +The +\f\*[B-Font]ntpd\fP +algorithms discard sample offsets exceeding 128 ms, +unless the interval during which no sample offset is less than 128 +ms exceeds 900s. +The first sample after that, no matter what the +offset, steps the clock to the indicated time. +In practice this +reduces the false alarm rate where the clock is stepped in error to +a vanishingly low incidence. +.sp \n(Ppu +.ne 2 + +As the result of this behavior, once the clock has been set it +very rarely strays more than 128 ms even under extreme cases of +network path congestion and jitter. +Sometimes, in particular when +\f\*[B-Font]ntpd\fP +is first started without a valid drift file +on a system with a large intrinsic drift +the error might grow to exceed 128 ms, +which would cause the clock to be set backwards +if the local clock time is more than 128 s +in the future relative to the server. +In some applications, this behavior may be unacceptable. +There are several solutions, however. +If the +\f\*[B-Font]\-x\f[] +option is included on the command line, the clock will +never be stepped and only slew corrections will be used. +But this choice comes with a cost that +should be carefully explored before deciding to use +the +\f\*[B-Font]\-x\f[] +option. +The maximum slew rate possible is limited +to 500 parts-per-million (PPM) as a consequence of the correctness +principles on which the NTP protocol and algorithm design are +based. +As a result, the local clock can take a long time to +converge to an acceptable offset, about 2,000 s for each second the +clock is outside the acceptable range. +During this interval the +local clock will not be consistent with any other network clock and +the system cannot be used for distributed applications that require +correctly synchronized network time. +.sp \n(Ppu +.ne 2 + +In spite of the above precautions, sometimes when large +frequency errors are present the resulting time offsets stray +outside the 128-ms range and an eventual step or slew time +correction is required. +If following such a correction the +frequency error is so large that the first sample is outside the +acceptable range, +\f\*[B-Font]ntpd\fP +enters the same state as when the +\fIntp.drift\f[] +file is not present. +The intent of this behavior +is to quickly correct the frequency and restore operation to the +normal tracking mode. +In the most extreme cases +(the host +\f\*[B-Font]time.ien.it\f[] +comes to mind), there may be occasional +step/slew corrections and subsequent frequency corrections. +It +helps in these cases to use the +\f\*[B-Font]burst\f[] +keyword when +configuring the server, but +ONLY +when you have permission to do so from the owner of the target host. +.sp \n(Ppu +.ne 2 + +Finally, +in the past many startup scripts would run +\fCntpdate\f[]\fR(1ntpdatemdoc)\f[] +or +\fCsntp\f[]\fR(1sntpmdoc)\f[] +to get the system clock close to correct before starting +\fCntpd\f[]\fR(1ntpdmdoc)\f[], +but this was never more than a mediocre hack and is no longer needed. +If you are following the instructions in +\fIStarting NTP (Best Current Practice)\f[] +and you still need to set the system time before starting +\f\*[B-Font]ntpd\fP, +please open a bug report and document what is going on, +and then look at using +\fCsntp\f[]\fR(1sntpmdoc)\f[] +if you really need to set the clock before starting +\f\*[B-Font]ntpd\fP. +.sp \n(Ppu +.ne 2 + +There is a way to start +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +that often addresses all of the problems mentioned above. +.SS "Starting NTP (Best Current Practice)" +First, use the +\f\*[B-Font]iburst\f[] +option on your +\f\*[B-Font]server\f[] +entries. +.sp \n(Ppu +.ne 2 + +If you can also keep a good +\fIntp.drift\f[] +file then +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +will effectively "warm-start" and your system's clock will +be stable in under 11 seconds' time. +.sp \n(Ppu +.ne 2 + +As soon as possible in the startup sequence, start +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +with at least the +\f\*[B-Font]\-g\f[] +and perhaps the +\f\*[B-Font]\-N\f[] +options. +Then, +start the rest of your "normal" processes. +This will give +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +as much time as possible to get the system's clock synchronized and stable. +.sp \n(Ppu +.ne 2 + +Finally, +if you have processes like +\f\*[B-Font]dovecot\f[] +or database servers +that require +monotonically-increasing time, +run +\fCntp-wait\f[]\fR(1ntp-waitmdoc)\f[] +as late as possible in the boot sequence +(perhaps with the +\f\*[B-Font]\-v\f[] +flag) +and after +\fCntp-wait\f[]\fR(1ntp-waitmdoc)\f[] +exits successfully +it is as safe as it will ever be to start any process that require +stable time. +.SS "Frequency Discipline" +The +\f\*[B-Font]ntpd\fP +behavior at startup depends on whether the +frequency file, usually +\fIntp.drift\f[], +exists. +This file +contains the latest estimate of clock frequency error. +When the +\f\*[B-Font]ntpd\fP +is started and the file does not exist, the +\f\*[B-Font]ntpd\fP +enters a special mode designed to quickly adapt to +the particular system clock oscillator time and frequency error. +This takes approximately 15 minutes, after which the time and +frequency are set to nominal values and the +\f\*[B-Font]ntpd\fP +enters +normal mode, where the time and frequency are continuously tracked +relative to the server. +After one hour the frequency file is +created and the current frequency offset written to it. +When the +\f\*[B-Font]ntpd\fP +is started and the file does exist, the +\f\*[B-Font]ntpd\fP +frequency is initialized from the file and enters normal mode +immediately. +After that the current frequency offset is written to +the file at hourly intervals. +.SS "Operating Modes" +The +\f\*[B-Font]ntpd\fP +utility can operate in any of several modes, including +symmetric active/passive, client/server broadcast/multicast and +manycast, as described in the +"Association Management" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +It normally operates continuously while +monitoring for small changes in frequency and trimming the clock +for the ultimate precision. +However, it can operate in a one-time +mode where the time is set from an external server and frequency is +set from a previously recorded frequency file. +A +broadcast/multicast or manycast client can discover remote servers, +compute server-client propagation delay correction factors and +configure itself automatically. +This makes it possible to deploy a +fleet of workstations without specifying configuration details +specific to the local environment. +.sp \n(Ppu +.ne 2 + +By default, +\f\*[B-Font]ntpd\fP +runs in continuous mode where each of +possibly several external servers is polled at intervals determined +by an intricate state machine. +The state machine measures the +incidental roundtrip delay jitter and oscillator frequency wander +and determines the best poll interval using a heuristic algorithm. +Ordinarily, and in most operating environments, the state machine +will start with 64s intervals and eventually increase in steps to +1024s. +A small amount of random variation is introduced in order to +avoid bunching at the servers. +In addition, should a server become +unreachable for some time, the poll interval is increased in steps +to 1024s in order to reduce network overhead. +.sp \n(Ppu +.ne 2 + +In some cases it may not be practical for +\f\*[B-Font]ntpd\fP +to run continuously. +A common workaround has been to run the +\fCntpdate\f[]\fR(1ntpdatemdoc)\f[] +or +\fCsntp\f[]\fR(1sntpmdoc)\f[] +programs from a +\fCcron\f[]\fR(8)\f[] +job at designated +times. +However, these programs do not have the crafted signal +processing, error checking or mitigation algorithms of +\f\*[B-Font]ntpd\fP. +The +\f\*[B-Font]\-q\f[] +option is intended for this purpose. +Setting this option will cause +\f\*[B-Font]ntpd\fP +to exit just after +setting the clock for the first time. +The procedure for initially +setting the clock is the same as in continuous mode; most +applications will probably want to specify the +\f\*[B-Font]iburst\f[] +keyword with the +\f\*[B-Font]server\f[] +configuration command. +With this +keyword a volley of messages are exchanged to groom the data and +the clock is set in about 10 s. +If nothing is heard after a +couple of minutes, the daemon times out and exits. +After a suitable +period of mourning, the +\fCntpdate\f[]\fR(1ntpdatemdoc)\f[] +program will be +retired. +.sp \n(Ppu +.ne 2 + +When kernel support is available to discipline the clock +frequency, which is the case for stock Solaris, Tru64, Linux and +FreeBSD, +a useful feature is available to discipline the clock +frequency. +First, +\f\*[B-Font]ntpd\fP +is run in continuous mode with +selected servers in order to measure and record the intrinsic clock +frequency offset in the frequency file. +It may take some hours for +the frequency and offset to settle down. +Then the +\f\*[B-Font]ntpd\fP +is +stopped and run in one-time mode as required. +At each startup, the +frequency is read from the file and initializes the kernel +frequency. +.SS "Poll Interval Control" +This version of NTP includes an intricate state machine to +reduce the network load while maintaining a quality of +synchronization consistent with the observed jitter and wander. +There are a number of ways to tailor the operation in order enhance +accuracy by reducing the interval or to reduce network overhead by +increasing it. +However, the user is advised to carefully consider +the consequences of changing the poll adjustment range from the +default minimum of 64 s to the default maximum of 1,024 s. +The +default minimum can be changed with the +\f\*[B-Font]tinker\f[] +\f\*[B-Font]minpoll\f[] +command to a value not less than 16 s. +This value is used for all +configured associations, unless overridden by the +\f\*[B-Font]minpoll\f[] +option on the configuration command. +Note that most device drivers +will not operate properly if the poll interval is less than 64 s +and that the broadcast server and manycast client associations will +also use the default, unless overridden. +.sp \n(Ppu +.ne 2 + +In some cases involving dial up or toll services, it may be +useful to increase the minimum interval to a few tens of minutes +and maximum interval to a day or so. +Under normal operation +conditions, once the clock discipline loop has stabilized the +interval will be increased in steps from the minimum to the +maximum. +However, this assumes the intrinsic clock frequency error +is small enough for the discipline loop correct it. +The capture +range of the loop is 500 PPM at an interval of 64s decreasing by a +factor of two for each doubling of interval. +At a minimum of 1,024 +s, for example, the capture range is only 31 PPM. +If the intrinsic +error is greater than this, the drift file +\fIntp.drift\f[] +will +have to be specially tailored to reduce the residual error below +this limit. +Once this is done, the drift file is automatically +updated once per hour and is available to initialize the frequency +on subsequent daemon restarts. +.SS "The huff-n'-puff Filter" +In scenarios where a considerable amount of data are to be +downloaded or uploaded over telephone modems, timekeeping quality +can be seriously degraded. +This occurs because the differential +delays on the two directions of transmission can be quite large. +In +many cases the apparent time errors are so large as to exceed the +step threshold and a step correction can occur during and after the +data transfer is in progress. +.sp \n(Ppu +.ne 2 + +The huff-n'-puff filter is designed to correct the apparent time +offset in these cases. +It depends on knowledge of the propagation +delay when no other traffic is present. +In common scenarios this +occurs during other than work hours. +The filter maintains a shift +register that remembers the minimum delay over the most recent +interval measured usually in hours. +Under conditions of severe +delay, the filter corrects the apparent offset using the sign of +the offset and the difference between the apparent delay and +minimum delay. +The name of the filter reflects the negative (huff) +and positive (puff) correction, which depends on the sign of the +offset. +.sp \n(Ppu +.ne 2 + +The filter is activated by the +\f\*[B-Font]tinker\f[] +command and +\f\*[B-Font]huffpuff\f[] +keyword, as described in +\fCntp.conf\f[]\fR(5)\f[]. +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH FILES +.TP 15 +.NOP \fI/etc/ntp.conf\f[] +the default name of the configuration file +.br +.ns +.TP 15 +.NOP \fI/etc/ntp.drift\f[] +the default name of the drift file +.br +.ns +.TP 15 +.NOP \fI/etc/ntp.keys\f[] +the default name of the key file +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "SEE ALSO" +\fCntp.conf\f[]\fR(5)\f[], +\fCntpdate\f[]\fR(1ntpdatemdoc)\f[], +\fCntpdc\f[]\fR(1ntpdcmdoc)\f[], +\fCntpq\f[]\fR(1ntpqmdoc)\f[], +\fCsntp\f[]\fR(1sntpmdoc)\f[] +.sp \n(Ppu +.ne 2 + +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +\f[C]http://www.ntp.org/\f[]. +A snapshot of this documentation is available in HTML format in +\fI/usr/share/doc/ntp\f[]. +David L. Mills, +\fINetwork Time Protocol (Version 1)\fR, +RFC1059 +.PP + +David L. Mills, +\fINetwork Time Protocol (Version 2)\fR, +RFC1119 +.PP + +David L. Mills, +\fINetwork Time Protocol (Version 3)\fR, +RFC1305 +.PP + +David L. Mills and J. Martin, Ed. and J. Burbank and W. Kasch, +\fINetwork Time Protocol Version 4: Protocol and Algorithms Specification\fR, +RFC5905 +.PP + +David L. Mills and B. Haberman, Ed., +\fINetwork Time Protocol Version 4: Autokey Specification\fR, +RFC5906 +.PP + +H. Gerstung and C. Elliott and B. Haberman, Ed., +\fIDefinitions of Managed Objects for Network Time Protocol Version 4: (NTPv4)\fR, +RFC5907 +.PP + +R. Gayraud and B. Lourdelet, +\fINetwork Time Protocol (NTP) Server Option for DHCPv6\fR, +RFC5908 +.PP + +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH BUGS +The +\f\*[B-Font]ntpd\fP +utility has gotten rather fat. +While not huge, it has gotten +larger than might be desirable for an elevated-priority +\f\*[B-Font]ntpd\fP +running on a workstation, particularly since many of +the fancy features which consume the space were designed more with +a busy primary server, rather than a high stratum workstation in +mind. +.sp \n(Ppu +.ne 2 + +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +Portions of this document came from FreeBSD. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntpd\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntpd.1ntpdmdoc b/contrib/ntp/ntpd/ntpd.1ntpdmdoc new file mode 100644 index 000000000..139de5277 --- /dev/null +++ b/contrib/ntp/ntpd/ntpd.1ntpdmdoc @@ -0,0 +1,908 @@ +.Dd October 21 2015 +.Dt NTPD 1ntpdmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpd-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:30 PM by AutoGen 5.18.5 +.\" From the definitions ntpd-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpd +.Nd NTP daemon program +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[ ... ] +.Pp +.Sh DESCRIPTION +The +.Nm +utility is an operating system daemon which sets +and maintains the system time of day in synchronism with Internet +standard time servers. +It is a complete implementation of the +Network Time Protocol (NTP) version 4, as defined by RFC\-5905, +but also retains compatibility with +version 3, as defined by RFC\-1305, and versions 1 +and 2, as defined by RFC\-1059 and RFC\-1119, respectively. +.Pp +The +.Nm +utility does most computations in 64\-bit floating point +arithmetic and does relatively clumsy 64\-bit fixed point operations +only when necessary to preserve the ultimate precision, about 232 +picoseconds. +While the ultimate precision is not achievable with +ordinary workstations and networks of today, it may be required +with future gigahertz CPU clocks and gigabit LANs. +.Pp +Ordinarily, +.Nm +reads the +.Xr ntp.conf 5 +configuration file at startup time in order to determine the +synchronization sources and operating modes. +It is also possible to +specify a working, although limited, configuration entirely on the +command line, obviating the need for a configuration file. +This may +be particularly useful when the local host is to be configured as a +broadcast/multicast client, with all peers being determined by +listening to broadcasts at run time. +.Pp +If NetInfo support is built into +.Nm , +then +.Nm +will attempt to read its configuration from the +NetInfo if the default +.Xr ntp.conf 5 +file cannot be read and no file is +specified by the +.Fl c +option. +.Pp +Various internal +.Nm +variables can be displayed and +configuration options altered while the +.Nm +is running +using the +.Xr ntpq 1ntpqmdoc +and +.Xr ntpdc 1ntpdcmdoc +utility programs. +.Pp +When +.Nm +starts it looks at the value of +.Xr umask 2 , +and if zero +.Nm +will set the +.Xr umask 2 +to 022. +.Sh "OPTIONS" +.Bl -tag +.It Fl 4 , Fl \-ipv4 +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.It Fl 6 , Fl \-ipv6 +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.It Fl a , Fl \-authreq +Require crypto authentication. +This option must not appear in combination with any of the following options: +authnoreq. +.sp +Require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is the default. +.It Fl A , Fl \-authnoreq +Do not require crypto authentication. +This option must not appear in combination with any of the following options: +authreq. +.sp +Do not require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is almost never a good idea. +.It Fl b , Fl \-bcastsync +Allow us to sync to broadcast servers. +.sp +.It Fl c Ar string , Fl \-configfile Ns = Ns Ar string +configuration file name. +.sp +The name and path of the configuration file, +\fI/etc/ntp.conf\fP +by default. +.It Fl d , Fl \-debug\-level +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.It Fl D Ar number , Fl \-set\-debug\-level Ns = Ns Ar number +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.It Fl f Ar string , Fl \-driftfile Ns = Ns Ar string +frequency drift file name. +.sp +The name and path of the frequency file, +\fI/etc/ntp.drift\fP +by default. +This is the same operation as the +\fBdriftfile\fP \fIdriftfile\fP +configuration specification in the +\fI/etc/ntp.conf\fP +file. +.It Fl g , Fl \-panicgate +Allow the first adjustment to be Big. +This option may appear an unlimited number of times. +.sp +Normally, +\fBntpd\fP +exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, +\fBntpd\fP +will exit with a message to the system log. This option can be used with the +\fB\-q\fP +and +\fB\-x\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +.It Fl G , Fl \-force\-step\-once +Step any initial offset correction.. +.sp +Normally, +\fBntpd\fP +steps the time if the time offset exceeds the step threshold, +which is 128 ms by default, and otherwise slews the time. +This option forces the initial offset correction to be stepped, +so the highest time accuracy can be achieved quickly. +However, this may also cause the time to be stepped back +so this option must not be used if +applications requiring monotonic time are running. +See the \fBtinker\fP configuration file directive for other options. +.It Fl i Ar string , Fl \-jaildir Ns = Ns Ar string +Jail directory. +.sp +Chroot the server to the directory +\fIjaildir\fP +. +This option also implies that the server attempts to drop root privileges at startup. +You may need to also specify a +\fB\-u\fP +option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB\-\-enable\-clockctl\fP) or Linux (configure with +\fB\-\-enable\-linuxcaps\fP) or Solaris (configure with \fB\-\-enable\-solarisprivs\fP). +.It Fl I Ar iface , Fl \-interface Ns = Ns Ar iface +Listen on an interface name or address. +This option may appear an unlimited number of times. +.sp +Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +\fBinterface\fP command, which is more versatile. +.It Fl k Ar string , Fl \-keyfile Ns = Ns Ar string +path to symmetric keys. +.sp +Specify the name and path of the symmetric key file. +\fI/etc/ntp.keys\fP +is the default. +This is the same operation as the +\fBkeys\fP \fIkeyfile\fP +configuration file directive. +.It Fl l Ar string , Fl \-logfile Ns = Ns Ar string +path to the log file. +.sp +Specify the name and path of the log file. +The default is the system log file. +This is the same operation as the +\fBlogfile\fP \fIlogfile\fP +configuration file directive. +.It Fl L , Fl \-novirtualips +Do not listen to virtual interfaces. +.sp +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file \fBinterface\fP command, which +is more versatile. +.It Fl M , Fl \-modifymmtimer +Modify Multimedia Timer (Windows only). +.sp +Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. +.It Fl n , Fl \-nofork +Do not fork. +This option must not appear in combination with any of the following options: +wait\-sync. +.sp +.It Fl N , Fl \-nice +Run at high priority. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the highest priority. +.It Fl p Ar string , Fl \-pidfile Ns = Ns Ar string +path to the PID file. +.sp +Specify the name and path of the file used to record +\fBntpd\fP's +process ID. +This is the same operation as the +\fBpidfile\fP \fIpidfile\fP +configuration file directive. +.It Fl P Ar number , Fl \-priority Ns = Ns Ar number +Process priority. +This option takes an integer number as its argument. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the specified +\fBsched_setscheduler(SCHED_FIFO)\fP +priority. +.It Fl q , Fl \-quit +Set the time and quit. +This option must not appear in combination with any of the following options: +saveconfigquit, wait\-sync. +.sp +\fBntpd\fP +will not daemonize and will exit after the clock is first +synchronized. This behavior mimics that of the +\fBntpdate\fP +program, which will soon be replaced with a shell script. +The +\fB\-g\fP +and +\fB\-x\fP +options can be used with this option. +Note: The kernel time discipline is disabled with this option. +.It Fl r Ar string , Fl \-propagationdelay Ns = Ns Ar string +Broadcast/propagation delay. +.sp +Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. +.It Fl \-saveconfigquit Ns = Ns Ar string +Save parsed configuration and quit. +This option must not appear in combination with any of the following options: +quit, wait\-sync. +.sp +Cause \fBntpd\fP to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. +.It Fl s Ar string , Fl \-statsdir Ns = Ns Ar string +Statistics file location. +.sp +Specify the directory path for files created by the statistics facility. +This is the same operation as the +\fBstatsdir\fP \fIstatsdir\fP +configuration file directive. +.It Fl t Ar tkey , Fl \-trustedkey Ns = Ns Ar tkey +Trusted key number. +This option may appear an unlimited number of times. +.sp +Add the specified key number to the trusted key list. +.It Fl u Ar string , Fl \-user Ns = Ns Ar string +Run as userid (or userid:groupid). +.sp +Specify a user, and optionally a group, to switch to. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB\-\-enable\-clockctl\fP) or Linux (configure with +\fB\-\-enable\-linuxcaps\fP) or Solaris (configure with \fB\-\-enable\-solarisprivs\fP). +.It Fl U Ar number , Fl \-updateinterval Ns = Ns Ar number +interval in seconds between scans for new or dropped interfaces. +This option takes an integer number as its argument. +.sp +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. +.It Fl \-var Ns = Ns Ar nvar +make ARG an ntp variable (RW). +This option may appear an unlimited number of times. +.sp +.It Fl \-dvar Ns = Ns Ar ndvar +make ARG an ntp variable (RW|DEF). +This option may appear an unlimited number of times. +.sp +.It Fl w Ar number , Fl \-wait\-sync Ns = Ns Ar number +Seconds to wait for first clock sync. +This option must not appear in combination with any of the following options: +nofork, quit, saveconfigquit. +This option takes an integer number as its argument. +.sp +If greater than zero, alters \fBntpd\fP's behavior when forking to +daemonize. Instead of exiting with status 0 immediately after +the fork, the parent waits up to the specified number of +seconds for the child to first synchronize the clock. The exit +status is zero (success) if the clock was synchronized, +otherwise it is \fBETIMEDOUT\fP. +This provides the option for a script starting \fBntpd\fP to easily +wait for the first set of the clock before proceeding. +.It Fl x , Fl \-slew +Slew up to 600 seconds. +.sp +Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. +This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. +Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. +Thus, an adjustment as much as 600 s will take almost 14 days to complete. +This option can be used with the +\fB\-g\fP +and +\fB\-q\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +Note: The kernel time discipline is disabled with this option. +.It Fl \-usepcc +Use CPU cycle counter (Windows only). +.sp +Attempt to substitute the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter and \fBQueryPerformanceCounter\fP are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. +.It Fl \-pccfreq Ns = Ns Ar string +Force CPU cycle counter use (Windows only). +.sp +Force substitution the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). +.It Fl m , Fl \-mdns +Register with mDNS as a NTP server. +.sp +Registers as an NTP server with the local mDNS server which allows +the server to be discovered via mDNS client lookup. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTPD_\fP or \fBNTPD\fP +.fi +.ad +.Sh USAGE +.Ss "How NTP Operates" +The +.Nm +utility operates by exchanging messages with +one or more configured servers over a range of designated poll intervals. +When +started, whether for the first or subsequent times, the program +requires several exchanges from the majority of these servers so +the signal processing and mitigation algorithms can accumulate and +groom the data and set the clock. +In order to protect the network +from bursts, the initial poll interval for each server is delayed +an interval randomized over a few seconds. +At the default initial poll +interval of 64s, several minutes can elapse before the clock is +set. +This initial delay to set the clock +can be safely and dramatically reduced using the +.Cm iburst +keyword with the +.Ic server +configuration +command, as described in +.Xr ntp.conf 5 . +.Pp +Most operating systems and hardware of today incorporate a +time\-of\-year (TOY) chip to maintain the time during periods when +the power is off. +When the machine is booted, the chip is used to +initialize the operating system time. +After the machine has +synchronized to a NTP server, the operating system corrects the +chip from time to time. +In the default case, if +.Nm +detects that the time on the host +is more than 1000s from the server time, +.Nm +assumes something must be terribly wrong and the only +reliable action is for the operator to intervene and set the clock +by hand. +(Reasons for this include there is no TOY chip, +or its battery is dead, or that the TOY chip is just of poor quality.) +This causes +.Nm +to exit with a panic message to +the system log. +The +.Fl g +option overrides this check and the +clock will be set to the server time regardless of the chip time +(up to 68 years in the past or future \(em +this is a limitation of the NTPv4 protocol). +However, and to protect against broken hardware, such as when the +CMOS battery fails or the clock counter becomes defective, once the +clock has been set an error greater than 1000s will cause +.Nm +to exit anyway. +.Pp +Under ordinary conditions, +.Nm +adjusts the clock in +small steps so that the timescale is effectively continuous and +without discontinuities. +Under conditions of extreme network +congestion, the roundtrip delay jitter can exceed three seconds and +the synchronization distance, which is equal to one\-half the +roundtrip delay plus error budget terms, can become very large. +The +.Nm +algorithms discard sample offsets exceeding 128 ms, +unless the interval during which no sample offset is less than 128 +ms exceeds 900s. +The first sample after that, no matter what the +offset, steps the clock to the indicated time. +In practice this +reduces the false alarm rate where the clock is stepped in error to +a vanishingly low incidence. +.Pp +As the result of this behavior, once the clock has been set it +very rarely strays more than 128 ms even under extreme cases of +network path congestion and jitter. +Sometimes, in particular when +.Nm +is first started without a valid drift file +on a system with a large intrinsic drift +the error might grow to exceed 128 ms, +which would cause the clock to be set backwards +if the local clock time is more than 128 s +in the future relative to the server. +In some applications, this behavior may be unacceptable. +There are several solutions, however. +If the +.Fl x +option is included on the command line, the clock will +never be stepped and only slew corrections will be used. +But this choice comes with a cost that +should be carefully explored before deciding to use +the +.Fl x +option. +The maximum slew rate possible is limited +to 500 parts\-per\-million (PPM) as a consequence of the correctness +principles on which the NTP protocol and algorithm design are +based. +As a result, the local clock can take a long time to +converge to an acceptable offset, about 2,000 s for each second the +clock is outside the acceptable range. +During this interval the +local clock will not be consistent with any other network clock and +the system cannot be used for distributed applications that require +correctly synchronized network time. +.Pp +In spite of the above precautions, sometimes when large +frequency errors are present the resulting time offsets stray +outside the 128\-ms range and an eventual step or slew time +correction is required. +If following such a correction the +frequency error is so large that the first sample is outside the +acceptable range, +.Nm +enters the same state as when the +.Pa ntp.drift +file is not present. +The intent of this behavior +is to quickly correct the frequency and restore operation to the +normal tracking mode. +In the most extreme cases +(the host +.Cm time.ien.it +comes to mind), there may be occasional +step/slew corrections and subsequent frequency corrections. +It +helps in these cases to use the +.Cm burst +keyword when +configuring the server, but +ONLY +when you have permission to do so from the owner of the target host. +.Pp +Finally, +in the past many startup scripts would run +.Xr ntpdate 1ntpdatemdoc +or +.Xr sntp 1sntpmdoc +to get the system clock close to correct before starting +.Xr ntpd 1ntpdmdoc , +but this was never more than a mediocre hack and is no longer needed. +If you are following the instructions in +.Sx "Starting NTP (Best Current Practice)" +and you still need to set the system time before starting +.Nm , +please open a bug report and document what is going on, +and then look at using +.Xr sntp 1sntpmdoc +if you really need to set the clock before starting +.Nm . +.Pp +There is a way to start +.Xr ntpd 1ntpdmdoc +that often addresses all of the problems mentioned above. +.Ss "Starting NTP (Best Current Practice)" +First, use the +.Cm iburst +option on your +.Cm server +entries. +.Pp +If you can also keep a good +.Pa ntp.drift +file then +.Xr ntpd 1ntpdmdoc +will effectively "warm\-start" and your system's clock will +be stable in under 11 seconds' time. +.Pp +As soon as possible in the startup sequence, start +.Xr ntpd 1ntpdmdoc +with at least the +.Fl g +and perhaps the +.Fl N +options. +Then, +start the rest of your "normal" processes. +This will give +.Xr ntpd 1ntpdmdoc +as much time as possible to get the system's clock synchronized and stable. +.Pp +Finally, +if you have processes like +.Cm dovecot +or database servers +that require +monotonically\-increasing time, +run +.Xr ntp\-wait 1ntp\-waitmdoc +as late as possible in the boot sequence +(perhaps with the +.Fl v +flag) +and after +.Xr ntp\-wait 1ntp\-waitmdoc +exits successfully +it is as safe as it will ever be to start any process that require +stable time. +.Ss "Frequency Discipline" +The +.Nm +behavior at startup depends on whether the +frequency file, usually +.Pa ntp.drift , +exists. +This file +contains the latest estimate of clock frequency error. +When the +.Nm +is started and the file does not exist, the +.Nm +enters a special mode designed to quickly adapt to +the particular system clock oscillator time and frequency error. +This takes approximately 15 minutes, after which the time and +frequency are set to nominal values and the +.Nm +enters +normal mode, where the time and frequency are continuously tracked +relative to the server. +After one hour the frequency file is +created and the current frequency offset written to it. +When the +.Nm +is started and the file does exist, the +.Nm +frequency is initialized from the file and enters normal mode +immediately. +After that the current frequency offset is written to +the file at hourly intervals. +.Ss "Operating Modes" +The +.Nm +utility can operate in any of several modes, including +symmetric active/passive, client/server broadcast/multicast and +manycast, as described in the +.Qq Association Management +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +It normally operates continuously while +monitoring for small changes in frequency and trimming the clock +for the ultimate precision. +However, it can operate in a one\-time +mode where the time is set from an external server and frequency is +set from a previously recorded frequency file. +A +broadcast/multicast or manycast client can discover remote servers, +compute server\-client propagation delay correction factors and +configure itself automatically. +This makes it possible to deploy a +fleet of workstations without specifying configuration details +specific to the local environment. +.Pp +By default, +.Nm +runs in continuous mode where each of +possibly several external servers is polled at intervals determined +by an intricate state machine. +The state machine measures the +incidental roundtrip delay jitter and oscillator frequency wander +and determines the best poll interval using a heuristic algorithm. +Ordinarily, and in most operating environments, the state machine +will start with 64s intervals and eventually increase in steps to +1024s. +A small amount of random variation is introduced in order to +avoid bunching at the servers. +In addition, should a server become +unreachable for some time, the poll interval is increased in steps +to 1024s in order to reduce network overhead. +.Pp +In some cases it may not be practical for +.Nm +to run continuously. +A common workaround has been to run the +.Xr ntpdate 1ntpdatemdoc +or +.Xr sntp 1sntpmdoc +programs from a +.Xr cron 8 +job at designated +times. +However, these programs do not have the crafted signal +processing, error checking or mitigation algorithms of +.Nm . +The +.Fl q +option is intended for this purpose. +Setting this option will cause +.Nm +to exit just after +setting the clock for the first time. +The procedure for initially +setting the clock is the same as in continuous mode; most +applications will probably want to specify the +.Cm iburst +keyword with the +.Ic server +configuration command. +With this +keyword a volley of messages are exchanged to groom the data and +the clock is set in about 10 s. +If nothing is heard after a +couple of minutes, the daemon times out and exits. +After a suitable +period of mourning, the +.Xr ntpdate 1ntpdatemdoc +program will be +retired. +.Pp +When kernel support is available to discipline the clock +frequency, which is the case for stock Solaris, Tru64, Linux and +.Fx , +a useful feature is available to discipline the clock +frequency. +First, +.Nm +is run in continuous mode with +selected servers in order to measure and record the intrinsic clock +frequency offset in the frequency file. +It may take some hours for +the frequency and offset to settle down. +Then the +.Nm +is +stopped and run in one\-time mode as required. +At each startup, the +frequency is read from the file and initializes the kernel +frequency. +.Ss "Poll Interval Control" +This version of NTP includes an intricate state machine to +reduce the network load while maintaining a quality of +synchronization consistent with the observed jitter and wander. +There are a number of ways to tailor the operation in order enhance +accuracy by reducing the interval or to reduce network overhead by +increasing it. +However, the user is advised to carefully consider +the consequences of changing the poll adjustment range from the +default minimum of 64 s to the default maximum of 1,024 s. +The +default minimum can be changed with the +.Ic tinker +.Cm minpoll +command to a value not less than 16 s. +This value is used for all +configured associations, unless overridden by the +.Cm minpoll +option on the configuration command. +Note that most device drivers +will not operate properly if the poll interval is less than 64 s +and that the broadcast server and manycast client associations will +also use the default, unless overridden. +.Pp +In some cases involving dial up or toll services, it may be +useful to increase the minimum interval to a few tens of minutes +and maximum interval to a day or so. +Under normal operation +conditions, once the clock discipline loop has stabilized the +interval will be increased in steps from the minimum to the +maximum. +However, this assumes the intrinsic clock frequency error +is small enough for the discipline loop correct it. +The capture +range of the loop is 500 PPM at an interval of 64s decreasing by a +factor of two for each doubling of interval. +At a minimum of 1,024 +s, for example, the capture range is only 31 PPM. +If the intrinsic +error is greater than this, the drift file +.Pa ntp.drift +will +have to be specially tailored to reduce the residual error below +this limit. +Once this is done, the drift file is automatically +updated once per hour and is available to initialize the frequency +on subsequent daemon restarts. +.Ss "The huff\-n'\-puff Filter" +In scenarios where a considerable amount of data are to be +downloaded or uploaded over telephone modems, timekeeping quality +can be seriously degraded. +This occurs because the differential +delays on the two directions of transmission can be quite large. +In +many cases the apparent time errors are so large as to exceed the +step threshold and a step correction can occur during and after the +data transfer is in progress. +.Pp +The huff\-n'\-puff filter is designed to correct the apparent time +offset in these cases. +It depends on knowledge of the propagation +delay when no other traffic is present. +In common scenarios this +occurs during other than work hours. +The filter maintains a shift +register that remembers the minimum delay over the most recent +interval measured usually in hours. +Under conditions of severe +delay, the filter corrects the apparent offset using the sign of +the offset and the difference between the apparent delay and +minimum delay. +The name of the filter reflects the negative (huff) +and positive (puff) correction, which depends on the sign of the +offset. +.Pp +The filter is activated by the +.Ic tinker +command and +.Cm huffpuff +keyword, as described in +.Xr ntp.conf 5 . +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh FILES +.Bl -tag -width /etc/ntp.drift -compact +.It Pa /etc/ntp.conf +the default name of the configuration file +.It Pa /etc/ntp.drift +the default name of the drift file +.It Pa /etc/ntp.keys +the default name of the key file +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntp.conf 5 , +.Xr ntpdate 1ntpdatemdoc , +.Xr ntpdc 1ntpdcmdoc , +.Xr ntpq 1ntpqmdoc , +.Xr sntp 1sntpmdoc +.Pp +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +.Li http://www.ntp.org/ . +A snapshot of this documentation is available in HTML format in +.Pa /usr/share/doc/ntp . +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 1) +.%O RFC1059 +.Re +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 2) +.%O RFC1119 +.Re +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 3) +.%O RFC1305 +.Re +.Rs +.%A David L. Mills +.%A J. Martin, Ed. +.%A J. Burbank +.%A W. Kasch +.%T Network Time Protocol Version 4: Protocol and Algorithms Specification +.%O RFC5905 +.Re +.Rs +.%A David L. Mills +.%A B. Haberman, Ed. +.%T Network Time Protocol Version 4: Autokey Specification +.%O RFC5906 +.Re +.Rs +.%A H. Gerstung +.%A C. Elliott +.%A B. Haberman, Ed. +.%T Definitions of Managed Objects for Network Time Protocol Version 4: (NTPv4) +.%O RFC5907 +.Re +.Rs +.%A R. Gayraud +.%A B. Lourdelet +.%T Network Time Protocol (NTP) Server Option for DHCPv6 +.%O RFC5908 +.Re +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh BUGS +The +.Nm +utility has gotten rather fat. +While not huge, it has gotten +larger than might be desirable for an elevated\-priority +.Nm +running on a workstation, particularly since many of +the fancy features which consume the space were designed more with +a busy primary server, rather than a high stratum workstation in +mind. +.Pp +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +Portions of this document came from FreeBSD. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntpd\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntpd.c b/contrib/ntp/ntpd/ntpd.c index 02a5198b0..a517391ba 100644 --- a/contrib/ntp/ntpd/ntpd.c +++ b/contrib/ntp/ntpd/ntpd.c @@ -12,11 +12,27 @@ #include "ntp_stdlib.h" #include +#include "ntp_config.h" +#include "ntp_syslog.h" +#include "ntp_assert.h" +#include "isc/error.h" +#include "isc/strerror.h" +#include "isc/formatcheck.h" +#include "iosignal.h" + #ifdef SIM # include "ntpsim.h" -# include "ntpdsim-opts.h" -#else -# include "ntpd-opts.h" +#endif + +#include "ntp_libopts.h" +#include "ntpd-opts.h" + +/* there's a short treatise below what the thread stuff is for */ +#if defined(HAVE_PTHREADS) && HAVE_PTHREADS && !defined(NO_THREADS) +# ifdef HAVE_PTHREAD_H +# include +# endif +# define NEED_PTHREAD_WARMUP #endif #ifdef HAVE_UNISTD_H @@ -26,11 +42,9 @@ # include #endif #include -#if !defined(VMS) /*wjm*/ -# ifdef HAVE_SYS_PARAM_H -# include -# endif -#endif /* VMS */ +#ifdef HAVE_SYS_PARAM_H +# include +#endif #ifdef HAVE_SYS_SIGNAL_H # include #else @@ -39,13 +53,7 @@ #ifdef HAVE_SYS_IOCTL_H # include #endif /* HAVE_SYS_IOCTL_H */ -#ifdef HAVE_SYS_RESOURCE_H -# include -#endif /* HAVE_SYS_RESOURCE_H */ #if defined(HAVE_RTPRIO) -# ifdef HAVE_SYS_RESOURCE_H -# include -# endif # ifdef HAVE_SYS_LOCK_H # include # endif @@ -78,8 +86,9 @@ # include #endif /* SYS_DOMAINOS */ -#include "recvbuff.h" -#include "ntp_cmdargs.h" + +#include "recvbuff.h" +#include "ntp_cmdargs.h" #if 0 /* HMS: I don't think we need this. 961223 */ #ifdef LOCK_PROCESS @@ -106,30 +115,34 @@ #ifdef HAVE_LINUX_CAPABILITIES # include # include -#endif -#endif - -/* - * Signals we catch for debugging. If not debugging we ignore them. - */ -#define MOREDEBUGSIG SIGUSR1 -#define LESSDEBUGSIG SIGUSR2 +#endif /* HAVE_LINUX_CAPABILITIES */ +#if defined(HAVE_PRIV_H) && defined(HAVE_SOLARIS_PRIVS) +# include +#endif /* HAVE_PRIV_H */ +#endif /* HAVE_DROPROOT */ -/* - * Signals which terminate us gracefully. - */ -#ifndef SYS_WINNT -# define SIGDIE1 SIGHUP -# define SIGDIE3 SIGQUIT -# define SIGDIE2 SIGINT -# define SIGDIE4 SIGTERM -#endif /* SYS_WINNT */ +#if defined (LIBSECCOMP) && (KERN_SECCOMP) +/* # include */ +# include +# include +#endif /* LIBSECCOMP and KERN_SECCOMP */ #ifdef HAVE_DNSREGISTRATION -#include +# include DNSServiceRef mdns; #endif +#ifdef HAVE_SETPGRP_0 +# define ntp_setpgrp(x, y) setpgrp() +#else +# define ntp_setpgrp(x, y) setpgrp(x, y) +#endif + +#ifdef HAVE_SOLARIS_PRIVS +# define LOWPRIVS "basic,sys_time,net_privaddr,proc_setid,!proc_info,!proc_session,!proc_exec" +static priv_set_t *lowprivs = NULL; +static priv_set_t *highprivs = NULL; +#endif /* HAVE_SOLARIS_PRIVS */ /* * Scheduling priority we run at */ @@ -140,38 +153,39 @@ int priority_done = 2; /* 0 - Set priority */ /* 2 - Don't set priority */ /* 1 and 2 are pretty much the same */ -#ifdef DEBUG +int listen_to_virtual_ips = TRUE; + /* - * Debugging flag + * No-fork flag. If set, we do not become a background daemon. */ -volatile int debug = 0; /* No debugging by default */ -#endif - -int listen_to_virtual_ips = 1; -const char *specific_interface = NULL; /* interface name or IP address to bind to */ +int nofork; /* Fork by default */ +#ifdef HAVE_DNSREGISTRATION /* - * No-fork flag. If set, we do not become a background daemon. + * mDNS registration flag. If set, we attempt to register with the mDNS system, but only + * after we have synched the first time. If the attempt fails, then try again once per + * minute for up to 5 times. After all, we may be starting before mDNS. */ -int nofork = 0; /* Fork by default */ +int mdnsreg = FALSE; +int mdnstries = 5; +#endif /* HAVE_DNSREGISTRATION */ #ifdef HAVE_DROPROOT -int droproot = 0; -char *user = NULL; /* User to switch to */ -char *group = NULL; /* group to switch to */ -char *chrootdir = NULL; /* directory to chroot to */ -int sw_uid; -int sw_gid; -char *endp; +int droproot; +int root_dropped; +char *user; /* User to switch to */ +char *group; /* group to switch to */ +const char *chrootdir; /* directory to chroot to */ +uid_t sw_uid; +gid_t sw_gid; +char *endp; struct group *gr; -struct passwd *pw; +struct passwd *pw; #endif /* HAVE_DROPROOT */ -/* - * Initializing flag. All async routines watch this and only do their - * thing when it is clear. - */ -int initializing; +#ifdef HAVE_WORKING_FORK +int waitsync_fd_to_close = -1; /* -w/--wait-sync */ +#endif /* * Version declaration @@ -186,106 +200,129 @@ int was_alarmed; /* * We put this here, since the argument profile is syscall-specific */ -extern int syscall P((int, ...)); +extern int syscall (int, ...); #endif /* DECL_SYSCALL */ -#ifdef SIGDIE2 -static RETSIGTYPE finish P((int)); -#endif /* SIGDIE2 */ +#if !defined(SIM) && defined(SIGDIE1) +static RETSIGTYPE finish (int); +#endif -#ifdef DEBUG -#ifndef SYS_WINNT -static RETSIGTYPE moredebug P((int)); -static RETSIGTYPE lessdebug P((int)); +#if !defined(SIM) && defined(HAVE_WORKING_FORK) +static int wait_child_sync_if (int, long); #endif -#else /* not DEBUG */ -static RETSIGTYPE no_debug P((int)); -#endif /* not DEBUG */ -int ntpdmain P((int, char **)); -static void set_process_priority P((void)); -static void init_logging P((char const *)); -static void setup_logfile P((void)); +#if !defined(SIM) && !defined(SYS_WINNT) +# ifdef DEBUG +static RETSIGTYPE moredebug (int); +static RETSIGTYPE lessdebug (int); +# else /* !DEBUG follows */ +static RETSIGTYPE no_debug (int); +# endif /* !DEBUG */ +#endif /* !SIM && !SYS_WINNT */ + +int saved_argc; +char ** saved_argv; + +#ifndef SIM +int ntpdmain (int, char **); +static void set_process_priority (void); +static void assertion_failed (const char *, int, + isc_assertiontype_t, + const char *) + __attribute__ ((__noreturn__)); +static void library_fatal_error (const char *, int, + const char *, va_list) + ISC_FORMAT_PRINTF(3, 0); +static void library_unexpected_error(const char *, int, + const char *, va_list) + ISC_FORMAT_PRINTF(3, 0); +#endif /* !SIM */ + + +/* Bug2332 unearthed a problem in the interaction of reduced user + * privileges, the limits on memory usage and some versions of the + * pthread library on Linux systems. The 'pthread_cancel()' function and + * likely some others need to track the stack of the thread involved, + * and uses a function that comes from GCC (--> libgcc_s.so) to do + * this. Unfortunately the developers of glibc decided to load the + * library on demand, which speeds up program start but can cause + * trouble here: Due to all the things NTPD does to limit its resource + * usage, this deferred load of libgcc_s does not always work once the + * restrictions are in effect. + * + * One way out of this was attempting a forced link against libgcc_s + * when possible because it makes the library available immediately + * without deferred load. (The symbol resolution would still be dynamic + * and on demand, but the code would already be in the process image.) + * + * This is a tricky thing to do, since it's not necessary everywhere, + * not possible everywhere, has shown to break the build of other + * programs in the NTP suite and is now generally frowned upon. + * + * So we take a different approach here: We creat a worker thread that does + * actually nothing except waiting for cancellation and cancel it. If + * this is done before all the limitations are put in place, the + * machinery is pre-heated and all the runtime stuff should be in place + * and useable when needed. + * + * This uses only the standard pthread API and should work with all + * implementations of pthreads. It is not necessary everywhere, but it's + * cheap enough to go on nearly unnoticed. + */ +#ifdef NEED_PTHREAD_WARMUP -/* - * Initialize the logging +/* simple thread function: sleep until cancelled, just to exercise + * thread cancellation. */ -void -init_logging(char const *name) +static void* +my_pthread_warmup_worker( + void *thread_args) { - const char *cp; - - /* - * Logging. This may actually work on the gizmo board. Find a name - * to log with by using the basename - */ - cp = strrchr(name, '/'); - if (cp == 0) - cp = name; - else - cp++; - -#if !defined(VMS) - -# ifndef LOG_DAEMON - openlog(cp, LOG_PID); -# else /* LOG_DAEMON */ - -# ifndef LOG_NTP -# define LOG_NTP LOG_DAEMON -# endif - openlog(cp, LOG_PID | LOG_NDELAY, LOG_NTP); -# ifdef DEBUG - if (debug) - setlogmask(LOG_UPTO(LOG_DEBUG)); - else -# endif /* DEBUG */ - setlogmask(LOG_UPTO(LOG_DEBUG)); /* @@@ was INFO */ -# endif /* LOG_DAEMON */ -#endif /* !SYS_WINNT && !VMS */ - - NLOG(NLOG_SYSINFO) /* conditional if clause for conditional syslog */ - msyslog(LOG_NOTICE, "%s", Version); + (void)thread_args; + for (;;) + sleep(10); + return NULL; +} + +/* pre-heat threading: create a thread and cancel it, just to exercise + * thread cancellation. + */ +static void +my_pthread_warmup(void) +{ + pthread_t thread; + int rc; + rc = pthread_create( + &thread, NULL, my_pthread_warmup_worker, NULL); + if (0 == rc) { + pthread_cancel(thread); + pthread_join(thread, NULL); + } } +#endif /*defined(NEED_PTHREAD_WARMUP)*/ -/* - * See if we should redirect the logfile - */ void -setup_logfile( - void +parse_cmdline_opts( + int * pargc, + char ***pargv ) { - if (HAVE_OPT( LOGFILE )) { - const char *my_optarg = OPT_ARG( LOGFILE ); - FILE *new_file; - - if(strcmp(my_optarg, "stderr") == 0) - new_file = stderr; - else if(strcmp(my_optarg, "stdout") == 0) - new_file = stdout; - else - new_file = fopen(my_optarg, "a"); - if (new_file != NULL) { - NLOG(NLOG_SYSINFO) - msyslog(LOG_NOTICE, "logging to file %s", my_optarg); - if (syslog_file != NULL && - fileno(syslog_file) != fileno(new_file)) - (void)fclose(syslog_file); - - syslog_file = new_file; - syslogit = 0; - } - else - msyslog(LOG_ERR, - "Cannot open log file %s", - my_optarg); - } + static int parsed; + static int optct; + + if (!parsed) + optct = ntpOptionProcess(&ntpdOptions, *pargc, *pargv); + + parsed = 1; + + *pargc -= optct; + *pargv += optct; } + #ifdef SIM int main( @@ -293,12 +330,19 @@ main( char *argv[] ) { + progname = argv[0]; + parse_cmdline_opts(&argc, &argv); +#ifdef DEBUG + debug = OPT_VALUE_SET_DEBUG_LEVEL; + DPRINTF(1, ("%s\n", Version)); +#endif + return ntpsim(argc, argv); } -#else /* SIM */ +#else /* !SIM follows */ #ifdef NO_MAIN_ALLOWED CALL(ntpd,"ntpd",ntpdmain); -#else +#else /* !NO_MAIN_ALLOWED follows */ #ifndef SYS_WINNT int main( @@ -308,18 +352,18 @@ main( { return ntpdmain(argc, argv); } -#endif /* SYS_WINNT */ -#endif /* NO_MAIN_ALLOWED */ -#endif /* SIM */ +#endif /* !SYS_WINNT */ +#endif /* !NO_MAIN_ALLOWED */ +#endif /* !SIM */ #ifdef _AIX /* * OK. AIX is different than solaris in how it implements plock(). * If you do NOT adjust the stack limit, you will get the MAXIMUM - * stack size allocated and PINNED with you program. To check the - * value, use ulimit -a. + * stack size allocated and PINNED with you program. To check the + * value, use ulimit -a. * - * To fix this, we create an automatic variable and set our stack limit + * To fix this, we create an automatic variable and set our stack limit * to that PLUS 32KB of extra space (we need some headroom). * * This subroutine gets the stack address. @@ -349,11 +393,12 @@ catch_danger(int signo) /* * Set the process priority */ +#ifndef SIM static void set_process_priority(void) { -#ifdef DEBUG +# ifdef DEBUG if (debug > 1) msyslog(LOG_DEBUG, "set_process_priority: %s: priority_done is <%d>", ((priority_done) @@ -361,13 +406,9 @@ set_process_priority(void) : "Attempt to set priority" ), priority_done); -#endif /* DEBUG */ - -#ifdef SYS_WINNT - priority_done += NT_set_process_priority(); -#endif +# endif /* DEBUG */ -#if defined(HAVE_SCHED_SETSCHEDULER) +# if defined(HAVE_SCHED_SETSCHEDULER) if (!priority_done) { extern int config_priority_override, config_priority; int pmax, pmin; @@ -389,9 +430,9 @@ set_process_priority(void) else ++priority_done; } -#endif /* HAVE_SCHED_SETSCHEDULER */ -#if defined(HAVE_RTPRIO) -# ifdef RTP_SET +# endif /* HAVE_SCHED_SETSCHEDULER */ +# ifdef HAVE_RTPRIO +# ifdef RTP_SET if (!priority_done) { struct rtprio srtp; @@ -403,17 +444,17 @@ set_process_priority(void) else ++priority_done; } -# else /* not RTP_SET */ +# else /* !RTP_SET follows */ if (!priority_done) { if (rtprio(0, 120) < 0) msyslog(LOG_ERR, "rtprio() error: %m"); else ++priority_done; } -# endif /* not RTP_SET */ -#endif /* HAVE_RTPRIO */ -#if defined(NTPD_PRIO) && NTPD_PRIO != 0 -# ifdef HAVE_ATT_NICE +# endif /* !RTP_SET */ +# endif /* HAVE_RTPRIO */ +# if defined(NTPD_PRIO) && NTPD_PRIO != 0 +# ifdef HAVE_ATT_NICE if (!priority_done) { errno = 0; if (-1 == nice (NTPD_PRIO) && errno != 0) @@ -421,148 +462,218 @@ set_process_priority(void) else ++priority_done; } -# endif /* HAVE_ATT_NICE */ -# ifdef HAVE_BSD_NICE +# endif /* HAVE_ATT_NICE */ +# ifdef HAVE_BSD_NICE if (!priority_done) { if (-1 == setpriority(PRIO_PROCESS, 0, NTPD_PRIO)) msyslog(LOG_ERR, "setpriority() error: %m"); else ++priority_done; } -# endif /* HAVE_BSD_NICE */ -#endif /* NTPD_PRIO && NTPD_PRIO != 0 */ +# endif /* HAVE_BSD_NICE */ +# endif /* NTPD_PRIO && NTPD_PRIO != 0 */ if (!priority_done) msyslog(LOG_ERR, "set_process_priority: No way found to improve our priority"); } +#endif /* !SIM */ /* * Main program. Initialize us, disconnect us from the tty if necessary, * and loop waiting for I/O and/or timer expiries. */ +#ifndef SIM int ntpdmain( int argc, char *argv[] ) { - l_fp now; + l_fp now; struct recvbuf *rbuf; -#ifdef _AIX /* HMS: ifdef SIGDANGER? */ + const char * logfilename; +# ifdef HAVE_UMASK + mode_t uv; +# endif +# if defined(HAVE_GETUID) && !defined(MPE) /* MPE lacks the concept of root */ + uid_t uid; +# endif +# if defined(HAVE_WORKING_FORK) + long wait_sync = 0; + int pipe_fds[2]; + int rc; + int exit_code; +# ifdef _AIX struct sigaction sa; -#endif +# endif +# if !defined(HAVE_SETSID) && !defined (HAVE_SETPGID) && defined(TIOCNOTTY) + int fid; +# endif +# endif /* HAVE_WORKING_FORK*/ +# ifdef SCO5_CLOCK + int fd; + int zero; +# endif +# ifdef NEED_PTHREAD_WARMUP + my_pthread_warmup(); +# endif + +# ifdef HAVE_UMASK + uv = umask(0); + if (uv) + umask(uv); + else + umask(022); +# endif + saved_argc = argc; + saved_argv = argv; progname = argv[0]; + initializing = TRUE; /* mark that we are initializing */ + parse_cmdline_opts(&argc, &argv); +# ifdef DEBUG + debug = OPT_VALUE_SET_DEBUG_LEVEL; +# ifdef HAVE_SETLINEBUF + setlinebuf(stdout); +# endif +# endif - initializing = 1; /* mark that we are initializing */ - - { - int optct = optionProcess( -#ifdef SIM - &ntpdsimOptions -#else - &ntpdOptions -#endif - , argc, argv); - argc -= optct; - argv += optct; - } - - /* HMS: is this lame? Should we process -l first? */ - - init_logging(progname); /* Open the log file */ - -#ifdef HAVE_UMASK - { - mode_t uv; - - uv = umask(0); - if(uv) - (void) umask(uv); - else - (void) umask(022); + if (HAVE_OPT(NOFORK) || HAVE_OPT(QUIT) +# ifdef DEBUG + || debug +# endif + || HAVE_OPT(SAVECONFIGQUIT)) + nofork = TRUE; + + init_logging(progname, NLOG_SYNCMASK, TRUE); + /* honor -l/--logfile option to log to a file */ + if (HAVE_OPT(LOGFILE)) { + logfilename = OPT_ARG(LOGFILE); + syslogit = FALSE; + change_logfile(logfilename, FALSE); + } else { + logfilename = NULL; + if (nofork) + msyslog_term = TRUE; + if (HAVE_OPT(SAVECONFIGQUIT)) + syslogit = FALSE; } -#endif + msyslog(LOG_NOTICE, "%s: Starting", Version); -#if defined(HAVE_GETUID) && !defined(MPE) /* MPE lacks the concept of root */ { - uid_t uid; - - uid = getuid(); - if (uid) - { - msyslog(LOG_ERR, "ntpd: must be run as root, not uid %ld", (long)uid); - printf("must be run as root, not uid %ld", (long)uid); - exit(1); + int i; + char buf[1024]; /* Secret knowledge of msyslog buf length */ + char *cp = buf; + + /* Note that every arg has an initial space character */ + snprintf(cp, sizeof(buf), "Command line:"); + cp += strlen(cp); + + for (i = 0; i < saved_argc ; ++i) { + snprintf(cp, sizeof(buf) - (cp - buf), + " %s", saved_argv[i]); + cp += strlen(cp); } + msyslog(LOG_INFO, "%s", buf); } -#endif -#ifdef OPENSSL - if ((SSLeay() ^ OPENSSL_VERSION_NUMBER) & ~0xff0L) { + /* + * Install trap handlers to log errors and assertion failures. + * Default handlers print to stderr which doesn't work if detached. + */ + isc_assertion_setcallback(assertion_failed); + isc_error_setfatal(library_fatal_error); + isc_error_setunexpected(library_unexpected_error); + + /* MPE lacks the concept of root */ +# if defined(HAVE_GETUID) && !defined(MPE) + uid = getuid(); + if (uid && !HAVE_OPT( SAVECONFIGQUIT )) { + msyslog_term = TRUE; msyslog(LOG_ERR, - "ntpd: OpenSSL version mismatch. Built against %lx, you have %lx\n", - OPENSSL_VERSION_NUMBER, SSLeay()); + "must be run as root, not uid %ld", (long)uid); exit(1); } -#endif - - /* getstartup(argc, argv); / * startup configuration, may set debug */ - -#ifdef DEBUG - debug = DESC(DEBUG_LEVEL).optOccCt; - if (debug) - printf("%s\n", Version); -#endif +# endif /* * Enable the Multi-Media Timer for Windows? */ -#ifdef SYS_WINNT +# ifdef SYS_WINNT if (HAVE_OPT( MODIFYMMTIMER )) set_mm_timer(MM_TIMER_HIRES); -#endif +# endif - if (HAVE_OPT( NOFORK ) || HAVE_OPT( QUIT )) - nofork = 1; +#ifdef HAVE_DNSREGISTRATION +/* + * Enable mDNS registrations? + */ + if (HAVE_OPT( MDNS )) { + mdnsreg = TRUE; + } +#endif /* HAVE_DNSREGISTRATION */ if (HAVE_OPT( NOVIRTUALIPS )) listen_to_virtual_ips = 0; + /* + * --interface, listen on specified interfaces + */ if (HAVE_OPT( INTERFACE )) { -#if 0 - int ifacect = STACKCT_OPT( INTERFACE ); - char** ifaces = STACKLST_OPT( INTERFACE ); + int ifacect = STACKCT_OPT( INTERFACE ); + const char** ifaces = STACKLST_OPT( INTERFACE ); + sockaddr_u addr; - /* malloc space for the array of names */ while (ifacect-- > 0) { - next_iface = *ifaces++; + add_nic_rule( + is_ip_address(*ifaces, AF_UNSPEC, &addr) + ? MATCH_IFADDR + : MATCH_IFNAME, + *ifaces, -1, ACTION_LISTEN); + ifaces++; } -#else - specific_interface = OPT_ARG( INTERFACE ); -#endif } if (HAVE_OPT( NICE )) priority_done = 0; -#if defined(HAVE_SCHED_SETSCHEDULER) +# ifdef HAVE_SCHED_SETSCHEDULER if (HAVE_OPT( PRIORITY )) { config_priority = OPT_VALUE_PRIORITY; config_priority_override = 1; priority_done = 0; } -#endif +# endif + +# ifdef HAVE_WORKING_FORK + do { /* 'loop' once */ + if (!HAVE_OPT( WAIT_SYNC )) + break; + wait_sync = OPT_VALUE_WAIT_SYNC; + if (wait_sync <= 0) { + wait_sync = 0; + break; + } + /* -w requires a fork() even with debug > 0 */ + nofork = FALSE; + if (pipe(pipe_fds)) { + exit_code = (errno) ? errno : -1; + msyslog(LOG_ERR, + "Pipe creation failed for --wait-sync: %m"); + exit(exit_code); + } + waitsync_fd_to_close = pipe_fds[1]; + } while (0); /* 'loop' once */ +# endif /* HAVE_WORKING_FORK */ -#ifdef SYS_WINNT + init_lib(); +# ifdef SYS_WINNT /* - * Initialize the time structures and variables + * Start interpolation thread, must occur before first + * get_systime() */ init_winnt_time(); -#endif - - setup_logfile(); - +# endif /* * Initialize random generator and public key pair */ @@ -570,256 +681,171 @@ ntpdmain( ntp_srandom((int)(now.l_i * now.l_uf)); -#ifdef HAVE_DNSREGISTRATION - /* HMS: does this have to happen this early? */ - msyslog(LOG_INFO, "Attemping to register mDNS"); - if ( DNSServiceRegister (&mdns, 0, 0, NULL, "_ntp._udp", NULL, NULL, htons(NTP_PORT), 0, NULL, NULL, NULL) != kDNSServiceErr_NoError ) { - msyslog(LOG_ERR, "Unable to register mDNS"); - } -#endif - -#if !defined(VMS) -# ifndef NODETACH /* * Detach us from the terminal. May need an #ifndef GIZMO. */ - if ( -# ifdef DEBUG - !debug && -# endif /* DEBUG */ - !nofork) - { -# ifndef SYS_WINNT -# ifdef HAVE_DAEMON - daemon(0, 0); -# else /* not HAVE_DAEMON */ - if (fork()) /* HMS: What about a -1? */ - exit(0); - - { -#if !defined(F_CLOSEM) - u_long s; - int max_fd; -#endif /* not F_CLOSEM */ + if (!nofork) { + +# ifdef HAVE_WORKING_FORK + rc = fork(); + if (-1 == rc) { + exit_code = (errno) ? errno : -1; + msyslog(LOG_ERR, "fork: %m"); + exit(exit_code); + } + if (rc > 0) { + /* parent */ + exit_code = wait_child_sync_if(pipe_fds[0], + wait_sync); + exit(exit_code); + } + + /* + * child/daemon + * close all open files excepting waitsync_fd_to_close. + * msyslog() unreliable until after init_logging(). + */ + closelog(); + if (syslog_file != NULL) { + fclose(syslog_file); + syslog_file = NULL; + syslogit = TRUE; + } + close_all_except(waitsync_fd_to_close); + INSIST(0 == open("/dev/null", 0) && 1 == dup2(0, 1) \ + && 2 == dup2(0, 2)); -#if defined(F_CLOSEM) - /* - * From 'Writing Reliable AIX Daemons,' SG24-4946-00, - * by Eric Agar (saves us from doing 32767 system - * calls) - */ - if (fcntl(0, F_CLOSEM, 0) == -1) - msyslog(LOG_ERR, "ntpd: failed to close open files(): %m"); -#else /* not F_CLOSEM */ - -# if defined(HAVE_SYSCONF) && defined(_SC_OPEN_MAX) - max_fd = sysconf(_SC_OPEN_MAX); -# else /* HAVE_SYSCONF && _SC_OPEN_MAX */ - max_fd = getdtablesize(); -# endif /* HAVE_SYSCONF && _SC_OPEN_MAX */ - for (s = 0; s < max_fd; s++) - (void) close((int)s); -#endif /* not F_CLOSEM */ - (void) open("/", 0); - (void) dup2(0, 1); - (void) dup2(0, 2); -#ifdef SYS_DOMAINOS - { - uid_$t puid; - status_$t st; + init_logging(progname, 0, TRUE); + /* we lost our logfile (if any) daemonizing */ + setup_logfile(logfilename); - proc2_$who_am_i(&puid); - proc2_$make_server(&puid, &st); - } -#endif /* SYS_DOMAINOS */ -#if defined(HAVE_SETPGID) || defined(HAVE_SETSID) -# ifdef HAVE_SETSID - if (setsid() == (pid_t)-1) - msyslog(LOG_ERR, "ntpd: setsid(): %m"); -# else - if (setpgid(0, 0) == -1) - msyslog(LOG_ERR, "ntpd: setpgid(): %m"); -# endif -#else /* HAVE_SETPGID || HAVE_SETSID */ - { -# if defined(TIOCNOTTY) - int fid; - - fid = open("/dev/tty", 2); - if (fid >= 0) - { - (void) ioctl(fid, (u_long) TIOCNOTTY, (char *) 0); - (void) close(fid); - } -# endif /* defined(TIOCNOTTY) */ -# ifdef HAVE_SETPGRP_0 - (void) setpgrp(); -# else /* HAVE_SETPGRP_0 */ - (void) setpgrp(0, getpid()); -# endif /* HAVE_SETPGRP_0 */ - } -#endif /* HAVE_SETPGID || HAVE_SETSID */ -#ifdef _AIX - /* Don't get killed by low-on-memory signal. */ - sa.sa_handler = catch_danger; - sigemptyset(&sa.sa_mask); - sa.sa_flags = SA_RESTART; +# ifdef SYS_DOMAINOS + { + uid_$t puid; + status_$t st; - (void) sigaction(SIGDANGER, &sa, NULL); -#endif /* _AIX */ + proc2_$who_am_i(&puid); + proc2_$make_server(&puid, &st); + } +# endif /* SYS_DOMAINOS */ +# ifdef HAVE_SETSID + if (setsid() == (pid_t)-1) + msyslog(LOG_ERR, "setsid(): %m"); +# elif defined(HAVE_SETPGID) + if (setpgid(0, 0) == -1) + msyslog(LOG_ERR, "setpgid(): %m"); +# else /* !HAVE_SETSID && !HAVE_SETPGID follows */ +# ifdef TIOCNOTTY + fid = open("/dev/tty", 2); + if (fid >= 0) { + ioctl(fid, (u_long)TIOCNOTTY, NULL); + close(fid); } -# endif /* not HAVE_DAEMON */ -# endif /* SYS_WINNT */ +# endif /* TIOCNOTTY */ + ntp_setpgrp(0, getpid()); +# endif /* !HAVE_SETSID && !HAVE_SETPGID */ +# ifdef _AIX + /* Don't get killed by low-on-memory signal. */ + sa.sa_handler = catch_danger; + sigemptyset(&sa.sa_mask); + sa.sa_flags = SA_RESTART; + sigaction(SIGDANGER, &sa, NULL); +# endif /* _AIX */ +# endif /* HAVE_WORKING_FORK */ } -# endif /* NODETACH */ -#endif /* VMS */ - - setup_logfile(); /* We lost any redirect when we daemonized */ -#ifdef SCO5_CLOCK +# ifdef SCO5_CLOCK /* * SCO OpenServer's system clock offers much more precise timekeeping * on the base CPU than the other CPUs (for multiprocessor systems), * so we must lock to the base CPU. */ - { - int fd = open("/dev/at1", O_RDONLY); - if (fd >= 0) { - int zero = 0; + fd = open("/dev/at1", O_RDONLY); + if (fd >= 0) { + zero = 0; if (ioctl(fd, ACPU_LOCK, &zero) < 0) - msyslog(LOG_ERR, "cannot lock to base CPU: %m"); - close( fd ); - } /* else ... - * If we can't open the device, this probably just isn't - * a multiprocessor system, so we're A-OK. - */ + msyslog(LOG_ERR, "cannot lock to base CPU: %m"); + close(fd); } -#endif +# endif -#if defined(HAVE_MLOCKALL) && defined(MCL_CURRENT) && defined(MCL_FUTURE) -# ifdef HAVE_SETRLIMIT + /* Setup stack size in preparation for locking pages in memory. */ +# if defined(HAVE_MLOCKALL) +# ifdef HAVE_SETRLIMIT + ntp_rlimit(RLIMIT_STACK, DFLT_RLIMIT_STACK * 4096, 4096, "4k"); +# ifdef RLIMIT_MEMLOCK /* - * Set the stack limit to something smaller, so that we don't lock a lot - * of unused stack memory. + * The default RLIMIT_MEMLOCK is very low on Linux systems. + * Unless we increase this limit malloc calls are likely to + * fail if we drop root privilege. To be useful the value + * has to be larger than the largest ntpd resident set size. */ - { - struct rlimit rl; - - /* HMS: must make the rlim_cur amount configurable */ - if (getrlimit(RLIMIT_STACK, &rl) != -1 - && (rl.rlim_cur = 50 * 4096) < rl.rlim_max) - { - if (setrlimit(RLIMIT_STACK, &rl) == -1) - { - msyslog(LOG_ERR, - "Cannot adjust stack limit for mlockall: %m"); - } - } -# ifdef RLIMIT_MEMLOCK - /* - * The default RLIMIT_MEMLOCK is very low on Linux systems. - * Unless we increase this limit malloc calls are likely to - * fail if we drop root privlege. To be useful the value - * has to be larger than the largest ntpd resident set size. - */ - rl.rlim_cur = rl.rlim_max = 32*1024*1024; - if (setrlimit(RLIMIT_MEMLOCK, &rl) == -1) { - msyslog(LOG_ERR, "Cannot set RLIMIT_MEMLOCK: %m"); - } -# endif /* RLIMIT_MEMLOCK */ - } -# endif /* HAVE_SETRLIMIT */ + ntp_rlimit(RLIMIT_MEMLOCK, DFLT_RLIMIT_MEMLOCK * 1024 * 1024, 1024 * 1024, "MB"); +# endif /* RLIMIT_MEMLOCK */ +# endif /* HAVE_SETRLIMIT */ +# else /* !HAVE_MLOCKALL follows */ +# ifdef HAVE_PLOCK +# ifdef PROCLOCK +# ifdef _AIX /* - * lock the process into memory - */ - if (mlockall(MCL_CURRENT|MCL_FUTURE) < 0) - msyslog(LOG_ERR, "mlockall(): %m"); -#else /* not (HAVE_MLOCKALL && MCL_CURRENT && MCL_FUTURE) */ -# ifdef HAVE_PLOCK -# ifdef PROCLOCK -# ifdef _AIX - /* * set the stack limit for AIX for plock(). * see get_aix_stack() for more info. */ - if (ulimit(SET_STACKLIM, (get_aix_stack() - 8*4096)) < 0) - { - msyslog(LOG_ERR,"Cannot adjust stack limit for plock on AIX: %m"); - } -# endif /* _AIX */ - /* - * lock the process into memory - */ - if (plock(PROCLOCK) < 0) - msyslog(LOG_ERR, "plock(PROCLOCK): %m"); -# else /* not PROCLOCK */ -# ifdef TXTLOCK - /* - * Lock text into ram - */ - if (plock(TXTLOCK) < 0) - msyslog(LOG_ERR, "plock(TXTLOCK) error: %m"); -# else /* not TXTLOCK */ - msyslog(LOG_ERR, "plock() - don't know what to lock!"); -# endif /* not TXTLOCK */ -# endif /* not PROCLOCK */ -# endif /* HAVE_PLOCK */ -#endif /* not (HAVE_MLOCKALL && MCL_CURRENT && MCL_FUTURE) */ + if (ulimit(SET_STACKLIM, (get_aix_stack() - 8 * 4096)) < 0) + msyslog(LOG_ERR, + "Cannot adjust stack limit for plock: %m"); +# endif /* _AIX */ +# endif /* PROCLOCK */ +# endif /* HAVE_PLOCK */ +# endif /* !HAVE_MLOCKALL */ /* * Set up signals we pay attention to locally. */ -#ifdef SIGDIE1 - (void) signal_no_reset(SIGDIE1, finish); -#endif /* SIGDIE1 */ -#ifdef SIGDIE2 - (void) signal_no_reset(SIGDIE2, finish); -#endif /* SIGDIE2 */ -#ifdef SIGDIE3 - (void) signal_no_reset(SIGDIE3, finish); -#endif /* SIGDIE3 */ -#ifdef SIGDIE4 - (void) signal_no_reset(SIGDIE4, finish); -#endif /* SIGDIE4 */ - -#ifdef SIGBUS - (void) signal_no_reset(SIGBUS, finish); -#endif /* SIGBUS */ - -#if !defined(SYS_WINNT) && !defined(VMS) -# ifdef DEBUG +# ifdef SIGDIE1 + signal_no_reset(SIGDIE1, finish); + signal_no_reset(SIGDIE2, finish); + signal_no_reset(SIGDIE3, finish); + signal_no_reset(SIGDIE4, finish); +# endif +# ifdef SIGBUS + signal_no_reset(SIGBUS, finish); +# endif + +# if !defined(SYS_WINNT) && !defined(VMS) +# ifdef DEBUG (void) signal_no_reset(MOREDEBUGSIG, moredebug); (void) signal_no_reset(LESSDEBUGSIG, lessdebug); -# else +# else (void) signal_no_reset(MOREDEBUGSIG, no_debug); (void) signal_no_reset(LESSDEBUGSIG, no_debug); -# endif /* DEBUG */ -#endif /* !SYS_WINNT && !VMS */ +# endif /* DEBUG */ +# endif /* !SYS_WINNT && !VMS */ /* * Set up signals we should never pay attention to. */ -#if defined SIGPIPE - (void) signal_no_reset(SIGPIPE, SIG_IGN); -#endif /* SIGPIPE */ +# ifdef SIGPIPE + signal_no_reset(SIGPIPE, SIG_IGN); +# endif /* * Call the init_ routines to initialize the data structures. * * Exactly what command-line options are we expecting here? */ + INIT_SSL(); init_auth(); init_util(); init_restrict(); init_mon(); init_timer(); - init_lib(); init_request(); init_control(); init_peer(); -#ifdef REFCLOCK +# ifdef REFCLOCK init_refclock(); -#endif +# endif set_process_priority(); init_proto(); /* Call at high priority */ init_io(); @@ -831,45 +857,93 @@ ntpdmain( * Get the configuration. This is done in a separate module * since this will definitely be different for the gizmo board. */ - getconfig(argc, argv); - loop_config(LOOP_DRIFTCOMP, old_drift / 1e6); -#ifdef OPENSSL - crypto_setup(); -#endif /* OPENSSL */ - initializing = 0; + if (-1 == cur_memlock) { +# if defined(HAVE_MLOCKALL) + /* + * lock the process into memory + */ + if ( !HAVE_OPT(SAVECONFIGQUIT) +# ifdef RLIMIT_MEMLOCK + && -1 != DFLT_RLIMIT_MEMLOCK +# endif + && 0 != mlockall(MCL_CURRENT|MCL_FUTURE)) + msyslog(LOG_ERR, "mlockall(): %m"); +# else /* !HAVE_MLOCKALL follows */ +# ifdef HAVE_PLOCK +# ifdef PROCLOCK + /* + * lock the process into memory + */ + if (!HAVE_OPT(SAVECONFIGQUIT) && 0 != plock(PROCLOCK)) + msyslog(LOG_ERR, "plock(PROCLOCK): %m"); +# else /* !PROCLOCK follows */ +# ifdef TXTLOCK + /* + * Lock text into ram + */ + if (!HAVE_OPT(SAVECONFIGQUIT) && 0 != plock(TXTLOCK)) + msyslog(LOG_ERR, "plock(TXTLOCK) error: %m"); +# else /* !TXTLOCK follows */ + msyslog(LOG_ERR, "plock() - don't know what to lock!"); +# endif /* !TXTLOCK */ +# endif /* !PROCLOCK */ +# endif /* HAVE_PLOCK */ +# endif /* !HAVE_MLOCKALL */ + } + + loop_config(LOOP_DRIFTINIT, 0); + report_event(EVNT_SYSRESTART, NULL, NULL); + initializing = FALSE; -#ifdef HAVE_DROPROOT - if( droproot ) { +# ifdef HAVE_DROPROOT + if (droproot) { /* Drop super-user privileges and chroot now if the OS supports this */ -#ifdef HAVE_LINUX_CAPABILITIES +# ifdef HAVE_LINUX_CAPABILITIES /* set flag: keep privileges accross setuid() call (we only really need cap_sys_time): */ - if( prctl( PR_SET_KEEPCAPS, 1L, 0L, 0L, 0L ) == -1 ) { + if (prctl( PR_SET_KEEPCAPS, 1L, 0L, 0L, 0L ) == -1) { msyslog( LOG_ERR, "prctl( PR_SET_KEEPCAPS, 1L ) failed: %m" ); exit(-1); } -#else +# elif HAVE_SOLARIS_PRIVS + /* Nothing to do here */ +# else /* we need a user to switch to */ - if( user == NULL ) { + if (user == NULL) { msyslog(LOG_ERR, "Need user name to drop root privileges (see -u flag!)" ); exit(-1); } -#endif /* HAVE_LINUX_CAPABILITIES */ - +# endif /* HAVE_LINUX_CAPABILITIES || HAVE_SOLARIS_PRIVS */ + if (user != NULL) { if (isdigit((unsigned char)*user)) { sw_uid = (uid_t)strtoul(user, &endp, 0); - if (*endp != '\0') + if (*endp != '\0') goto getuser; + + if ((pw = getpwuid(sw_uid)) != NULL) { + free(user); + user = estrdup(pw->pw_name); + sw_gid = pw->pw_gid; + } else { + errno = 0; + msyslog(LOG_ERR, "Cannot find user ID %s", user); + exit (-1); + } + } else { -getuser: +getuser: + errno = 0; if ((pw = getpwnam(user)) != NULL) { sw_uid = pw->pw_uid; + sw_gid = pw->pw_gid; } else { - errno = 0; - msyslog(LOG_ERR, "Cannot find user `%s'", user); + if (errno) + msyslog(LOG_ERR, "getpwnam(%s) failed: %m", user); + else + msyslog(LOG_ERR, "Cannot find user `%s'", user); exit (-1); } } @@ -877,10 +951,10 @@ getuser: if (group != NULL) { if (isdigit((unsigned char)*group)) { sw_gid = (gid_t)strtoul(group, &endp, 0); - if (*endp != '\0') + if (*endp != '\0') goto getgroup; } else { -getgroup: +getgroup: if ((gr = getgrnam(group)) != NULL) { sw_gid = gr->gr_gid; } else { @@ -890,17 +964,41 @@ getgroup: } } } - - if( chrootdir ) { + + if (chrootdir ) { /* make sure cwd is inside the jail: */ - if( chdir(chrootdir) ) { + if (chdir(chrootdir)) { msyslog(LOG_ERR, "Cannot chdir() to `%s': %m", chrootdir); exit (-1); } - if( chroot(chrootdir) ) { + if (chroot(chrootdir)) { msyslog(LOG_ERR, "Cannot chroot() to `%s': %m", chrootdir); exit (-1); } + if (chdir("/")) { + msyslog(LOG_ERR, "Cannot chdir() to`root after chroot(): %m"); + exit (-1); + } + } +# ifdef HAVE_SOLARIS_PRIVS + if ((lowprivs = priv_str_to_set(LOWPRIVS, ",", NULL)) == NULL) { + msyslog(LOG_ERR, "priv_str_to_set() failed:%m"); + exit(-1); + } + if ((highprivs = priv_allocset()) == NULL) { + msyslog(LOG_ERR, "priv_allocset() failed:%m"); + exit(-1); + } + (void) getppriv(PRIV_PERMITTED, highprivs); + (void) priv_intersect(highprivs, lowprivs); + if (setppriv(PRIV_SET, PRIV_PERMITTED, lowprivs) == -1) { + msyslog(LOG_ERR, "setppriv() failed:%m"); + exit(-1); + } +# endif /* HAVE_SOLARIS_PRIVS */ + if (user && initgroups(user, sw_gid)) { + msyslog(LOG_ERR, "Cannot initgroups() to user `%s': %m", user); + exit (-1); } if (group && setgid(sw_gid)) { msyslog(LOG_ERR, "Cannot setgid() to group `%s': %m", group); @@ -910,6 +1008,17 @@ getgroup: msyslog(LOG_ERR, "Cannot setegid() to group `%s': %m", group); exit (-1); } + if (group) { + if (0 != setgroups(1, &sw_gid)) { + msyslog(LOG_ERR, "setgroups(1, %d) failed: %m", sw_gid); + exit (-1); + } + } + else if (pw) + if (0 != initgroups(pw->pw_name, pw->pw_gid)) { + msyslog(LOG_ERR, "initgroups(<%s>, %d) filed: %m", pw->pw_name, pw->pw_gid); + exit (-1); + } if (user && setuid(sw_uid)) { msyslog(LOG_ERR, "Cannot setuid() to user `%s': %m", user); exit (-1); @@ -918,192 +1027,249 @@ getgroup: msyslog(LOG_ERR, "Cannot seteuid() to user `%s': %m", user); exit (-1); } - -#ifndef HAVE_LINUX_CAPABILITIES + +# if !defined(HAVE_LINUX_CAPABILITIES) && !defined(HAVE_SOLARIS_PRIVS) /* * for now assume that the privilege to bind to privileged ports * is associated with running with uid 0 - should be refined on * ports that allow binding to NTP_PORT with uid != 0 */ disable_dynamic_updates |= (sw_uid != 0); /* also notifies routing message listener */ -#endif +# endif /* !HAVE_LINUX_CAPABILITIES && !HAVE_SOLARIS_PRIVS */ if (disable_dynamic_updates && interface_interval) { interface_interval = 0; - msyslog(LOG_INFO, "running in unprivileged mode disables dynamic interface tracking"); + msyslog(LOG_INFO, "running as non-root disables dynamic interface tracking"); } -#ifdef HAVE_LINUX_CAPABILITIES - do { +# ifdef HAVE_LINUX_CAPABILITIES + { /* * We may be running under non-root uid now, but we still hold full root privileges! * We drop all of them, except for the crucial one or two: cap_sys_time and * cap_net_bind_service if doing dynamic interface tracking. */ cap_t caps; - char *captext = interface_interval ? - "cap_sys_time,cap_net_bind_service=ipe" : - "cap_sys_time=ipe"; - if( ! ( caps = cap_from_text( captext ) ) ) { - msyslog( LOG_ERR, "cap_from_text() failed: %m" ); + char *captext; + + captext = (0 != interface_interval) + ? "cap_sys_time,cap_net_bind_service=pe" + : "cap_sys_time=pe"; + caps = cap_from_text(captext); + if (!caps) { + msyslog(LOG_ERR, + "cap_from_text(%s) failed: %m", + captext); exit(-1); } - if( cap_set_proc( caps ) == -1 ) { - msyslog( LOG_ERR, "cap_set_proc() failed to drop root privileges: %m" ); + if (-1 == cap_set_proc(caps)) { + msyslog(LOG_ERR, + "cap_set_proc() failed to drop root privs: %m"); exit(-1); } - cap_free( caps ); - } while(0); -#endif /* HAVE_LINUX_CAPABILITIES */ + cap_free(caps); + } +# endif /* HAVE_LINUX_CAPABILITIES */ +# ifdef HAVE_SOLARIS_PRIVS + if (priv_delset(lowprivs, "proc_setid") == -1) { + msyslog(LOG_ERR, "priv_delset() failed:%m"); + exit(-1); + } + if (setppriv(PRIV_SET, PRIV_PERMITTED, lowprivs) == -1) { + msyslog(LOG_ERR, "setppriv() failed:%m"); + exit(-1); + } + priv_freeset(lowprivs); + priv_freeset(highprivs); +# endif /* HAVE_SOLARIS_PRIVS */ + root_dropped = TRUE; + fork_deferred_worker(); + } /* if (droproot) */ +# endif /* HAVE_DROPROOT */ + +/* libssecomp sandboxing */ +#if defined (LIBSECCOMP) && (KERN_SECCOMP) + scmp_filter_ctx ctx; + + if ((ctx = seccomp_init(SCMP_ACT_KILL)) < 0) + msyslog(LOG_ERR, "%s: seccomp_init(SCMP_ACT_KILL) failed: %m", __func__); + else { + msyslog(LOG_DEBUG, "%s: seccomp_init(SCMP_ACT_KILL) succeeded", __func__); + } - } /* if( droproot ) */ -#endif /* HAVE_DROPROOT */ - - /* - * Report that we're up to any trappers - */ - report_event(EVNT_SYSRESTART, (struct peer *)0); +#ifdef __x86_64__ +int scmp_sc[] = { + SCMP_SYS(adjtimex), + SCMP_SYS(bind), + SCMP_SYS(brk), + SCMP_SYS(chdir), + SCMP_SYS(clock_gettime), + SCMP_SYS(clock_settime), + SCMP_SYS(close), + SCMP_SYS(connect), + SCMP_SYS(exit_group), + SCMP_SYS(fstat), + SCMP_SYS(fsync), + SCMP_SYS(futex), + SCMP_SYS(getitimer), + SCMP_SYS(getsockname), + SCMP_SYS(ioctl), + SCMP_SYS(lseek), + SCMP_SYS(madvise), + SCMP_SYS(mmap), + SCMP_SYS(munmap), + SCMP_SYS(open), + SCMP_SYS(poll), + SCMP_SYS(read), + SCMP_SYS(recvmsg), + SCMP_SYS(rename), + SCMP_SYS(rt_sigaction), + SCMP_SYS(rt_sigprocmask), + SCMP_SYS(rt_sigreturn), + SCMP_SYS(select), + SCMP_SYS(sendto), + SCMP_SYS(setitimer), + SCMP_SYS(setsid), + SCMP_SYS(socket), + SCMP_SYS(stat), + SCMP_SYS(time), + SCMP_SYS(write), +}; +#endif +#ifdef __i386__ +int scmp_sc[] = { + SCMP_SYS(_newselect), + SCMP_SYS(adjtimex), + SCMP_SYS(brk), + SCMP_SYS(chdir), + SCMP_SYS(clock_gettime), + SCMP_SYS(clock_settime), + SCMP_SYS(close), + SCMP_SYS(exit_group), + SCMP_SYS(fsync), + SCMP_SYS(futex), + SCMP_SYS(getitimer), + SCMP_SYS(madvise), + SCMP_SYS(mmap), + SCMP_SYS(mmap2), + SCMP_SYS(munmap), + SCMP_SYS(open), + SCMP_SYS(poll), + SCMP_SYS(read), + SCMP_SYS(rename), + SCMP_SYS(rt_sigaction), + SCMP_SYS(rt_sigprocmask), + SCMP_SYS(select), + SCMP_SYS(setitimer), + SCMP_SYS(setsid), + SCMP_SYS(sigprocmask), + SCMP_SYS(sigreturn), + SCMP_SYS(socketcall), + SCMP_SYS(stat64), + SCMP_SYS(time), + SCMP_SYS(write), +}; +#endif + { + int i; + + for (i = 0; i < COUNTOF(scmp_sc); i++) { + if (seccomp_rule_add(ctx, + SCMP_ACT_ALLOW, scmp_sc[i], 0) < 0) { + msyslog(LOG_ERR, + "%s: seccomp_rule_add() failed: %m", + __func__); + } + } + } - /* - * Use select() on all on all input fd's for unlimited - * time. select() will terminate on SIGALARM or on the - * reception of input. Using select() means we can't do - * robust signal handling and we get a potential race - * between checking for alarms and doing the select(). - * Mostly harmless, I think. - */ - /* On VMS, I suspect that select() can't be interrupted - * by a "signal" either, so I take the easy way out and - * have select() time out after one second. - * System clock updates really aren't time-critical, - * and - lacking a hardware reference clock - I have - * yet to learn about anything else that is. - */ -#if defined(HAVE_IO_COMPLETION_PORT) + if (seccomp_load(ctx) < 0) + msyslog(LOG_ERR, "%s: seccomp_load() failed: %m", + __func__); + else { + msyslog(LOG_DEBUG, "%s: seccomp_load() succeeded", __func__); + } +#endif /* LIBSECCOMP and KERN_SECCOMP */ + +# ifdef HAVE_IO_COMPLETION_PORT for (;;) { GetReceivedBuffers(); -#else /* normal I/O */ +# else /* normal I/O */ BLOCK_IO_AND_ALARM(); - was_alarmed = 0; - for (;;) - { -# if !defined(HAVE_SIGNALED_IO) - extern fd_set activefds; - extern int maxactivefd; - - fd_set rdfdes; - int nfound; -# endif + was_alarmed = FALSE; - if (alarm_flag) /* alarmed? */ - { - was_alarmed = 1; - alarm_flag = 0; + for (;;) { + if (alarm_flag) { /* alarmed? */ + was_alarmed = TRUE; + alarm_flag = FALSE; } - if (!was_alarmed && has_full_recv_buffer() == ISC_FALSE) - { + if (!was_alarmed && !has_full_recv_buffer()) { /* * Nothing to do. Wait for something. */ -# ifndef HAVE_SIGNALED_IO - rdfdes = activefds; -# if defined(VMS) || defined(SYS_VXWORKS) - /* make select() wake up after one second */ - { - struct timeval t1; - - t1.tv_sec = 1; t1.tv_usec = 0; - nfound = select(maxactivefd+1, &rdfdes, (fd_set *)0, - (fd_set *)0, &t1); - } -# else - nfound = select(maxactivefd+1, &rdfdes, (fd_set *)0, - (fd_set *)0, (struct timeval *)0); -# endif /* VMS */ - if (nfound > 0) - { - l_fp ts; - - get_systime(&ts); + io_handler(); + } - (void)input_handler(&ts); - } - else if (nfound == -1 && errno != EINTR) - netsyslog(LOG_ERR, "select() error: %m"); -# ifdef DEBUG - else if (debug > 5) - netsyslog(LOG_DEBUG, "select(): nfound=%d, error: %m", nfound); -# endif /* DEBUG */ -# else /* HAVE_SIGNALED_IO */ - - wait_for_signal(); -# endif /* HAVE_SIGNALED_IO */ - if (alarm_flag) /* alarmed? */ - { - was_alarmed = 1; - alarm_flag = 0; - } + if (alarm_flag) { /* alarmed? */ + was_alarmed = TRUE; + alarm_flag = FALSE; } - if (was_alarmed) - { + if (was_alarmed) { UNBLOCK_IO_AND_ALARM(); /* * Out here, signals are unblocked. Call timer routine * to process expiry. */ timer(); - was_alarmed = 0; - BLOCK_IO_AND_ALARM(); + was_alarmed = FALSE; + BLOCK_IO_AND_ALARM(); } -#endif /* HAVE_IO_COMPLETION_PORT */ +# endif /* !HAVE_IO_COMPLETION_PORT */ -#ifdef DEBUG_TIMING +# ifdef DEBUG_TIMING { l_fp pts; l_fp tsa, tsb; int bufcount = 0; - + get_systime(&pts); tsa = pts; -#endif +# endif rbuf = get_full_recv_buffer(); - while (rbuf != NULL) - { - if (alarm_flag) - { - was_alarmed = 1; - alarm_flag = 0; + while (rbuf != NULL) { + if (alarm_flag) { + was_alarmed = TRUE; + alarm_flag = FALSE; } UNBLOCK_IO_AND_ALARM(); - if (was_alarmed) - { /* avoid timer starvation during lengthy I/O handling */ + if (was_alarmed) { + /* avoid timer starvation during lengthy I/O handling */ timer(); - was_alarmed = 0; + was_alarmed = FALSE; } /* * Call the data procedure to handle each received * packet. */ - if (rbuf->receiver != NULL) /* This should always be true */ - { -#ifdef DEBUG_TIMING + if (rbuf->receiver != NULL) { +# ifdef DEBUG_TIMING l_fp dts = pts; L_SUB(&dts, &rbuf->recv_time); DPRINTF(2, ("processing timestamp delta %s (with prec. fuzz)\n", lfptoa(&dts, 9))); collect_timing(rbuf, "buffer processing delay", 1, &dts); bufcount++; -#endif - (rbuf->receiver)(rbuf); +# endif + (*rbuf->receiver)(rbuf); } else { - msyslog(LOG_ERR, "receive buffer corruption - receiver found to be NULL - ABORTING"); + msyslog(LOG_ERR, "fatal: receive buffer callback NULL"); abort(); } @@ -1111,7 +1277,7 @@ getgroup: freerecvbuf(rbuf); rbuf = get_full_recv_buffer(); } -#ifdef DEBUG_TIMING +# ifdef DEBUG_TIMING get_systime(&tsb); L_SUB(&tsb, &tsa); if (bufcount) { @@ -1119,18 +1285,38 @@ getgroup: DPRINTF(2, ("processing time for %d buffers %s\n", bufcount, lfptoa(&tsb, 9))); } } -#endif +# endif /* * Go around again */ + +# ifdef HAVE_DNSREGISTRATION + if (mdnsreg && (current_time - mdnsreg ) > 60 && mdnstries && sys_leap != LEAP_NOTINSYNC) { + mdnsreg = current_time; + msyslog(LOG_INFO, "Attempting to register mDNS"); + if ( DNSServiceRegister (&mdns, 0, 0, NULL, "_ntp._udp", NULL, NULL, + htons(NTP_PORT), 0, NULL, NULL, NULL) != kDNSServiceErr_NoError ) { + if (!--mdnstries) { + msyslog(LOG_ERR, "Unable to register mDNS, giving up."); + } else { + msyslog(LOG_INFO, "Unable to register mDNS, will try later."); + } + } else { + msyslog(LOG_INFO, "mDNS service registered."); + mdnsreg = FALSE; + } + } +# endif /* HAVE_DNSREGISTRATION */ + } UNBLOCK_IO_AND_ALARM(); return 1; } +#endif /* !SIM */ -#ifdef SIGDIE2 +#if !defined(SIM) && defined(SIGDIE1) /* * finish - exit gracefully */ @@ -1139,32 +1325,185 @@ finish( int sig ) { + const char *sig_desc; - msyslog(LOG_NOTICE, "ntpd exiting on signal %d", sig); - write_stats(); -#ifdef HAVE_DNSREGISTRATION + sig_desc = NULL; +#ifdef HAVE_STRSIGNAL + sig_desc = strsignal(sig); +#endif + if (sig_desc == NULL) + sig_desc = ""; + msyslog(LOG_NOTICE, "%s exiting on signal %d (%s)", progname, + sig, sig_desc); + /* See Bug 2513 and Bug 2522 re the unlink of PIDFILE */ +# ifdef HAVE_DNSREGISTRATION if (mdns != NULL) - DNSServiceRefDeallocate(mdns); + DNSServiceRefDeallocate(mdns); +# endif + peer_cleanup(); + exit(0); +} +#endif /* !SIM && SIGDIE1 */ + + +#ifndef SIM +/* + * wait_child_sync_if - implements parent side of -w/--wait-sync + */ +# ifdef HAVE_WORKING_FORK +static int +wait_child_sync_if( + int pipe_read_fd, + long wait_sync + ) +{ + int rc; + int exit_code; + time_t wait_end_time; + time_t cur_time; + time_t wait_rem; + fd_set readset; + struct timeval wtimeout; + + if (0 == wait_sync) + return 0; + + /* waitsync_fd_to_close used solely by child */ + close(waitsync_fd_to_close); + wait_end_time = time(NULL) + wait_sync; + do { + cur_time = time(NULL); + wait_rem = (wait_end_time > cur_time) + ? (wait_end_time - cur_time) + : 0; + wtimeout.tv_sec = wait_rem; + wtimeout.tv_usec = 0; + FD_ZERO(&readset); + FD_SET(pipe_read_fd, &readset); + rc = select(pipe_read_fd + 1, &readset, NULL, NULL, + &wtimeout); + if (-1 == rc) { + if (EINTR == errno) + continue; + exit_code = (errno) ? errno : -1; + msyslog(LOG_ERR, + "--wait-sync select failed: %m"); + return exit_code; + } + if (0 == rc) { + /* + * select() indicated a timeout, but in case + * its timeouts are affected by a step of the + * system clock, select() again with a zero + * timeout to confirm. + */ + FD_ZERO(&readset); + FD_SET(pipe_read_fd, &readset); + wtimeout.tv_sec = 0; + wtimeout.tv_usec = 0; + rc = select(pipe_read_fd + 1, &readset, NULL, + NULL, &wtimeout); + if (0 == rc) /* select() timeout */ + break; + else /* readable */ + return 0; + } else /* readable */ + return 0; + } while (wait_rem > 0); + + fprintf(stderr, "%s: -w/--wait-sync %ld timed out.\n", + progname, wait_sync); + return ETIMEDOUT; +} +# endif /* HAVE_WORKING_FORK */ + + +/* + * assertion_failed - Redirect assertion failures to msyslog(). + */ +static void +assertion_failed( + const char *file, + int line, + isc_assertiontype_t type, + const char *cond + ) +{ + isc_assertion_setcallback(NULL); /* Avoid recursion */ + + msyslog(LOG_ERR, "%s:%d: %s(%s) failed", + file, line, isc_assertion_typetotext(type), cond); + msyslog(LOG_ERR, "exiting (due to assertion failure)"); + +#if defined(DEBUG) && defined(SYS_WINNT) + if (debug) + DebugBreak(); #endif - switch (sig) - { -# ifdef SIGBUS - case SIGBUS: - printf("\nfinish(SIGBUS)\n"); - exit(0); -# endif - case 0: /* Should never happen... */ - return; - default: - exit(0); - } + abort(); +} + + +/* + * library_fatal_error - Handle fatal errors from our libraries. + */ +static void +library_fatal_error( + const char *file, + int line, + const char *format, + va_list args + ) +{ + char errbuf[256]; + + isc_error_setfatal(NULL); /* Avoid recursion */ + + msyslog(LOG_ERR, "%s:%d: fatal error:", file, line); + vsnprintf(errbuf, sizeof(errbuf), format, args); + msyslog(LOG_ERR, "%s", errbuf); + msyslog(LOG_ERR, "exiting (due to fatal error in library)"); + +#if defined(DEBUG) && defined(SYS_WINNT) + if (debug) + DebugBreak(); +#endif + + abort(); } -#endif /* SIGDIE2 */ -#ifdef DEBUG -#ifndef SYS_WINNT +/* + * library_unexpected_error - Handle non fatal errors from our libraries. + */ +# define MAX_UNEXPECTED_ERRORS 100 +int unexpected_error_cnt = 0; +static void +library_unexpected_error( + const char *file, + int line, + const char *format, + va_list args + ) +{ + char errbuf[256]; + + if (unexpected_error_cnt >= MAX_UNEXPECTED_ERRORS) + return; /* avoid clutter in log */ + + msyslog(LOG_ERR, "%s:%d: unexpected error:", file, line); + vsnprintf(errbuf, sizeof(errbuf), format, args); + msyslog(LOG_ERR, "%s", errbuf); + + if (++unexpected_error_cnt == MAX_UNEXPECTED_ERRORS) + msyslog(LOG_ERR, "Too many errors. Shutting up."); + +} +#endif /* !SIM */ + +#if !defined(SIM) && !defined(SYS_WINNT) +# ifdef DEBUG + /* * moredebug - increase debugging verbosity */ @@ -1183,6 +1522,7 @@ moredebug( errno = saved_errno; } + /* * lessdebug - decrease debugging verbosity */ @@ -1200,9 +1540,10 @@ lessdebug( } errno = saved_errno; } -#endif -#else /* not DEBUG */ -#ifndef SYS_WINNT + +# else /* !DEBUG follows */ + + /* * no_debug - We don't do the debug here. */ @@ -1216,5 +1557,5 @@ no_debug( msyslog(LOG_DEBUG, "ntpd not compiled for debugging (signal %d)", sig); errno = saved_errno; } -#endif /* not SYS_WINNT */ -#endif /* not DEBUG */ +# endif /* !DEBUG */ +#endif /* !SIM && !SYS_WINNT */ diff --git a/contrib/ntp/ntpd/ntpd.html b/contrib/ntp/ntpd/ntpd.html new file mode 100644 index 000000000..8d6f9d6ad --- /dev/null +++ b/contrib/ntp/ntpd/ntpd.html @@ -0,0 +1,1019 @@ + + +ntpd: Network Time Protocol (NTP) Daemon User's Manual + + + + + + + + + +

      ntpd: Network Time Protocol (NTP) Daemon User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      ntpd: Network Time Protocol (NTP) Daemon User Manual

      + +

      The ntpd program is an operating system daemon that synchronizes the +system clock to remote NTP time servers or local reference clocks. +It is a complete implementation of NTP version 4 defined by RFC-5905, but +also retains compatible with version 3 defined by RFC-1305 and versions +1 and 2, defined by RFC-1059 and RFC-1119, respectively. +The program can operate in any of several modes, including client/server, +symmetric and broadcast modes, and with both symmetric-key and public-key +cryptography. + +

      This document applies to version 4.2.8p4 of ntpd. + +

      + +
      +


      + +
      +
      + + +

      Description

      + +

      The ntpd program ordinarily requires +a configuration file described at ntp.conf. +This configuration file contains configuration commands described on +the pages listed above. +However a client can discover remote servers and configure them +automatically. +This makes it possible to deploy a fleet of workstations without +specifying configuration details specific to the local environment. + +

      The ntpd program normally operates continuously while adjusting the +system time and frequency, but in some cases this might not be +practical. +With the -q option ntpd operates as in continuous mode, but +exits just after setting the clock for the first time. +Most applications will probably want to specify the iburst +option with the server command. +With this option an initial volley of messages is exchanged to +groom the data and set the clock in about ten seconds' time. +If nothing is heard after a few minutes' time, +the daemon times out and exits without setting the clock. + +

      +


      + +
      +
      + +

      Invoking ntpd

      + +

      + +

      The +ntpd +utility is an operating system daemon which sets +and maintains the system time of day in synchronism with Internet +standard time servers. +It is a complete implementation of the +Network Time Protocol (NTP) version 4, as defined by RFC-5905, +but also retains compatibility with +version 3, as defined by RFC-1305, and versions 1 +and 2, as defined by RFC-1059 and RFC-1119, respectively. + +

      The +ntpd +utility does most computations in 64-bit floating point +arithmetic and does relatively clumsy 64-bit fixed point operations +only when necessary to preserve the ultimate precision, about 232 +picoseconds. +While the ultimate precision is not achievable with +ordinary workstations and networks of today, it may be required +with future gigahertz CPU clocks and gigabit LANs. + +

      Ordinarily, +ntpd +reads the +ntp.conf(5) +configuration file at startup time in order to determine the +synchronization sources and operating modes. +It is also possible to +specify a working, although limited, configuration entirely on the +command line, obviating the need for a configuration file. +This may +be particularly useful when the local host is to be configured as a +broadcast/multicast client, with all peers being determined by +listening to broadcasts at run time. + +

      If NetInfo support is built into +ntpd +then +ntpd +will attempt to read its configuration from the +NetInfo if the default +ntp.conf(5) +file cannot be read and no file is +specified by the +-c +option. + +

      Various internal +ntpd +variables can be displayed and +configuration options altered while the +ntpd +is running +using the +ntpq(1ntpqmdoc) +and +ntpdc(1ntpdcmdoc) +utility programs. + +

      When +ntpd +starts it looks at the value of +umask(2), +and if zero +ntpd +will set the +umask(2) +to 022. + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntpd program. +This software is released under the NTP license, <http://ntp.org/license>. + +

      + +
      +


      +Next: , +Up: ntpd Invocation +
      +
      + +

      ntpd help/usage (--help)

      + +

      +This is the automatically generated usage text for ntpd. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      ntpd - NTP daemon program - Ver. 4.2.8p4-sec-RC2
      +Usage:  ntpd [ -<flag> [<val>] | --<name>[{=| }<val>] ]... \
      +                [ <server1> ... <serverN> ]
      +  Flg Arg Option-Name    Description
      +   -4 no  ipv4           Force IPv4 DNS name resolution
      +                                - prohibits the option 'ipv6'
      +   -6 no  ipv6           Force IPv6 DNS name resolution
      +                                - prohibits the option 'ipv4'
      +   -a no  authreq        Require crypto authentication
      +                                - prohibits the option 'authnoreq'
      +   -A no  authnoreq      Do not require crypto authentication
      +                                - prohibits the option 'authreq'
      +   -b no  bcastsync      Allow us to sync to broadcast servers
      +   -c Str configfile     configuration file name
      +   -d no  debug-level    Increase debug verbosity level
      +                                - may appear multiple times
      +   -D Num set-debug-level Set the debug verbosity level
      +                                - may appear multiple times
      +   -f Str driftfile      frequency drift file name
      +   -g no  panicgate      Allow the first adjustment to be Big
      +                                - may appear multiple times
      +   -G no  force-step-once Step any initial offset correction.
      +   -i Str jaildir        Jail directory
      +   -I Str interface      Listen on an interface name or address
      +                                - may appear multiple times
      +   -k Str keyfile        path to symmetric keys
      +   -l Str logfile        path to the log file
      +   -L no  novirtualips   Do not listen to virtual interfaces
      +   -n no  nofork         Do not fork
      +                                - prohibits the option 'wait-sync'
      +   -N no  nice           Run at high priority
      +   -p Str pidfile        path to the PID file
      +   -P Num priority       Process priority
      +   -q no  quit           Set the time and quit
      +                                - prohibits these options:
      +                                saveconfigquit
      +                                wait-sync
      +   -r Str propagationdelay Broadcast/propagation delay
      +      Str saveconfigquit Save parsed configuration and quit
      +                                - prohibits these options:
      +                                quit
      +                                wait-sync
      +   -s Str statsdir       Statistics file location
      +   -t Str trustedkey     Trusted key number
      +                                - may appear multiple times
      +   -u Str user           Run as userid (or userid:groupid)
      +   -U Num updateinterval interval in seconds between scans for new or dropped interfaces
      +      Str var            make ARG an ntp variable (RW)
      +                                - may appear multiple times
      +      Str dvar           make ARG an ntp variable (RW|DEF)
      +                                - may appear multiple times
      +   -w Num wait-sync      Seconds to wait for first clock sync
      +                                - prohibits these options:
      +                                nofork
      +                                quit
      +                                saveconfigquit
      +   -x no  slew           Slew up to 600 seconds
      +      opt version        output version information and exit
      +   -? no  help           display extended usage information and exit
      +   -! no  more-help      extended usage information passed thru pager
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      +
      +The following option preset mechanisms are supported:
      + - examining environment variables named NTPD_*
      +
      +Please send bug reports to:  <http://bugs.ntp.org, bugs@ntp.org>
      +
      +
      +


      +Next: , +Previous: ntpd usage, +Up: ntpd Invocation +
      +
      + +

      ipv4 option (-4)

      + +

      +This is the “force ipv4 dns name resolution” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +ipv6. +
      + +

      Force DNS resolution of following host names on the command line +to the IPv4 namespace. +

      +


      +Next: , +Previous: ntpd ipv4, +Up: ntpd Invocation +
      +
      + +

      ipv6 option (-6)

      + +

      +This is the “force ipv6 dns name resolution” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +ipv4. +
      + +

      Force DNS resolution of following host names on the command line +to the IPv6 namespace. +

      +


      +Next: , +Previous: ntpd ipv6, +Up: ntpd Invocation +
      +
      + +

      authreq option (-a)

      + +

      +This is the “require crypto authentication” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +authnoreq. +
      + +

      Require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is the default. +

      +


      +Next: , +Previous: ntpd authreq, +Up: ntpd Invocation +
      +
      + +

      authnoreq option (-A)

      + +

      +This is the “do not require crypto authentication” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +authreq. +
      + +

      Do not require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is almost never a good idea. +

      +


      +Next: , +Previous: ntpd authnoreq, +Up: ntpd Invocation +
      +
      + +

      configfile option (-c)

      + +

      +This is the “configuration file name” option. +This option takes a string argument. +The name and path of the configuration file, +/etc/ntp.conf +by default. +

      +


      +Next: , +Previous: ntpd configfile, +Up: ntpd Invocation +
      +
      + +

      driftfile option (-f)

      + +

      +This is the “frequency drift file name” option. +This option takes a string argument. +The name and path of the frequency file, +/etc/ntp.drift +by default. +This is the same operation as the +driftfile driftfile +configuration specification in the +/etc/ntp.conf +file. +

      +


      +Next: , +Previous: ntpd driftfile, +Up: ntpd Invocation +
      +
      + +

      panicgate option (-g)

      + +

      +This is the “allow the first adjustment to be big” option. + +

      This option has some usage constraints. It: +

        +
      • may appear an unlimited number of times. +
      + +

      Normally, +ntpd +exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, +ntpd +will exit with a message to the system log. This option can be used with the +-q +and +-x +options. +See the +tinker +configuration file directive for other options. +

      +


      +Next: , +Previous: ntpd panicgate, +Up: ntpd Invocation +
      +
      + +

      force-step-once option (-G)

      + +

      +This is the “step any initial offset correction.” option. +Normally, +ntpd +steps the time if the time offset exceeds the step threshold, +which is 128 ms by default, and otherwise slews the time. +This option forces the initial offset correction to be stepped, +so the highest time accuracy can be achieved quickly. +However, this may also cause the time to be stepped back +so this option must not be used if +applications requiring monotonic time are running. +See the tinker configuration file directive for other options. +

      +


      +Next: , +Previous: ntpd force-step-once, +Up: ntpd Invocation +
      +
      + +

      jaildir option (-i)

      + +

      +This is the “jail directory” option. +This option takes a string argument. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining HAVE_DROPROOT during the compilation. +
      + +

      Chroot the server to the directory +jaildir +. +This option also implies that the server attempts to drop root privileges at startup. +You may need to also specify a +-u +option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +--enable-clockctl) or Linux (configure with +--enable-linuxcaps) or Solaris (configure with --enable-solarisprivs). +

      +


      +Next: , +Previous: ntpd jaildir, +Up: ntpd Invocation +
      +
      + +

      interface option (-I)

      + +

      +This is the “listen on an interface name or address” option. +This option takes a string argument iface. + +

      This option has some usage constraints. It: +

        +
      • may appear an unlimited number of times. +
      + +

      Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +interface command, which is more versatile. +

      +


      +Next: , +Previous: ntpd interface, +Up: ntpd Invocation +
      +
      + +

      keyfile option (-k)

      + +

      +This is the “path to symmetric keys” option. +This option takes a string argument. +Specify the name and path of the symmetric key file. +/etc/ntp.keys +is the default. +This is the same operation as the +keys keyfile +configuration file directive. +

      +


      +Next: , +Previous: ntpd keyfile, +Up: ntpd Invocation +
      +
      + +

      logfile option (-l)

      + +

      +This is the “path to the log file” option. +This option takes a string argument. +Specify the name and path of the log file. +The default is the system log file. +This is the same operation as the +logfile logfile +configuration file directive. +

      +


      +Next: , +Previous: ntpd logfile, +Up: ntpd Invocation +
      +
      + +

      novirtualips option (-L)

      + +

      +This is the “do not listen to virtual interfaces” option. +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file interface command, which +is more versatile. +

      +


      +Next: , +Previous: ntpd novirtualips, +Up: ntpd Invocation +
      +
      + +

      modifymmtimer option (-M)

      + +

      +This is the “modify multimedia timer (windows only)” option. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining SYS_WINNT during the compilation. +
      + +

      Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. +

      +


      +Next: , +Previous: ntpd modifymmtimer, +Up: ntpd Invocation +
      +
      + +

      nice option (-N)

      + +

      +This is the “run at high priority” option. +To the extent permitted by the operating system, run +ntpd +at the highest priority. +

      +


      +Next: , +Previous: ntpd nice, +Up: ntpd Invocation +
      +
      + +

      pidfile option (-p)

      + +

      +This is the “path to the pid file” option. +This option takes a string argument. +Specify the name and path of the file used to record +ntpd's +process ID. +This is the same operation as the +pidfile pidfile +configuration file directive. +

      +


      +Next: , +Previous: ntpd pidfile, +Up: ntpd Invocation +
      +
      + +

      priority option (-P)

      + +

      +This is the “process priority” option. +This option takes a number argument. +To the extent permitted by the operating system, run +ntpd +at the specified +sched_setscheduler(SCHED_FIFO) +priority. +

      +


      +Next: , +Previous: ntpd priority, +Up: ntpd Invocation +
      +
      + +

      quit option (-q)

      + +

      +This is the “set the time and quit” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +saveconfigquit, wait-sync. +
      + +

      ntpd +will not daemonize and will exit after the clock is first +synchronized. This behavior mimics that of the +ntpdate +program, which will soon be replaced with a shell script. +The +-g +and +-x +options can be used with this option. +Note: The kernel time discipline is disabled with this option. +

      +


      +Next: , +Previous: ntpd quit, +Up: ntpd Invocation +
      +
      + +

      propagationdelay option (-r)

      + +

      +This is the “broadcast/propagation delay” option. +This option takes a string argument. +Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. +

      +


      +Next: , +Previous: ntpd propagationdelay, +Up: ntpd Invocation +
      +
      + +

      saveconfigquit option

      + +

      +This is the “save parsed configuration and quit” option. +This option takes a string argument. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining SAVECONFIG during the compilation. +
      • must not appear in combination with any of the following options: +quit, wait-sync. +
      + +

      Cause ntpd to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. +

      +


      +Next: , +Previous: ntpd saveconfigquit, +Up: ntpd Invocation +
      +
      + +

      statsdir option (-s)

      + +

      +This is the “statistics file location” option. +This option takes a string argument. +Specify the directory path for files created by the statistics facility. +This is the same operation as the +statsdir statsdir +configuration file directive. +

      +


      +Next: , +Previous: ntpd statsdir, +Up: ntpd Invocation +
      +
      + +

      trustedkey option (-t)

      + +

      +This is the “trusted key number” option. +This option takes a string argument tkey. + +

      This option has some usage constraints. It: +

        +
      • may appear an unlimited number of times. +
      + +

      Add the specified key number to the trusted key list. +

      +


      +Next: , +Previous: ntpd trustedkey, +Up: ntpd Invocation +
      +
      + +

      user option (-u)

      + +

      +This is the “run as userid (or userid:groupid)” option. +This option takes a string argument. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining HAVE_DROPROOT during the compilation. +
      + +

      Specify a user, and optionally a group, to switch to. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +--enable-clockctl) or Linux (configure with +--enable-linuxcaps) or Solaris (configure with --enable-solarisprivs). +

      +


      +Next: , +Previous: ntpd user, +Up: ntpd Invocation +
      +
      + +

      updateinterval option (-U)

      + +

      +This is the “interval in seconds between scans for new or dropped interfaces” option. +This option takes a number argument. +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. +

      +


      +Next: , +Previous: ntpd updateinterval, +Up: ntpd Invocation +
      +
      + +

      wait-sync option (-w)

      + +

      +This is the “seconds to wait for first clock sync” option. +This option takes a number argument. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining HAVE_WORKING_FORK during the compilation. +
      • must not appear in combination with any of the following options: +nofork, quit, saveconfigquit. +
      + +

      If greater than zero, alters ntpd's behavior when forking to +daemonize. Instead of exiting with status 0 immediately after +the fork, the parent waits up to the specified number of +seconds for the child to first synchronize the clock. The exit +status is zero (success) if the clock was synchronized, +otherwise it is ETIMEDOUT. +This provides the option for a script starting ntpd to easily +wait for the first set of the clock before proceeding. +

      +


      +Next: , +Previous: ntpd wait-sync, +Up: ntpd Invocation +
      +
      + +

      slew option (-x)

      + +

      +This is the “slew up to 600 seconds” option. +Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. +This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. +Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. +Thus, an adjustment as much as 600 s will take almost 14 days to complete. +This option can be used with the +-g +and +-q +options. +See the +tinker +configuration file directive for other options. +Note: The kernel time discipline is disabled with this option. +

      +


      +Next: , +Previous: ntpd slew, +Up: ntpd Invocation +
      +
      + +

      usepcc option

      + +

      +This is the “use cpu cycle counter (windows only)” option. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining SYS_WINNT during the compilation. +
      + +

      Attempt to substitute the CPU counter for QueryPerformanceCounter. +The CPU counter and QueryPerformanceCounter are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. +

      +


      +Next: , +Previous: ntpd usepcc, +Up: ntpd Invocation +
      +
      + +

      pccfreq option

      + +

      +This is the “force cpu cycle counter use (windows only)” option. +This option takes a string argument. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining SYS_WINNT during the compilation. +
      + +

      Force substitution the CPU counter for QueryPerformanceCounter. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). +

      +


      +Next: , +Previous: ntpd pccfreq, +Up: ntpd Invocation +
      +
      + +

      mdns option (-m)

      + +

      +This is the “register with mdns as a ntp server” option. + +

      This option has some usage constraints. It: +

        +
      • must be compiled in by defining HAVE_DNSREGISTRATION during the compilation. +
      + +

      Registers as an NTP server with the local mDNS server which allows +the server to be discovered via mDNS client lookup. + +

      +


      +Next: , +Previous: ntpd mdns, +Up: ntpd Invocation +
      +
      + +

      presetting/configuring ntpd

      + +

      Any option that is not marked as not presettable may be preset by +loading values from environment variables named NTPD and NTPD_<OPTION_NAME>. <OPTION_NAME> must be one of +the options listed above in upper case and segmented with underscores. +The NTPD variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + +

      The command line options relating to configuration and/or usage help are: + +

      version (-)
      + +

      Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +

      +
      version
      Only print the version. This is the default. +
      copyright
      Name the copyright usage licensing terms. +
      verbose
      Print the full copyright usage licensing terms. +
      + +
      +


      +Next: , +Previous: ntpd config, +Up: ntpd Invocation +
      +
      + +

      ntpd exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      +
      +


      +Next: , +Previous: ntpd exit status, +Up: ntpd Invocation +
      +
      + +

      ntpd Usage

      + +
      +


      +Next: , +Previous: ntpd Usage, +Up: ntpd Invocation +
      +
      + +

      ntpd Files

      + +
      +


      +Next: , +Previous: ntpd Files, +Up: ntpd Invocation +
      +
      + +

      ntpd See Also

      + +
      +


      +Next: , +Previous: ntpd See Also, +Up: ntpd Invocation +
      +
      + +

      ntpd Bugs

      + +
      +


      +Previous: ntpd Bugs, +Up: ntpd Invocation +
      +
      + +

      ntpd Notes

      + +
      +


      + +
      +
      + + +

      Usage

      + diff --git a/contrib/ntp/ntpd/ntpd.man.in b/contrib/ntp/ntpd/ntpd.man.in new file mode 100644 index 000000000..21bd88473 --- /dev/null +++ b/contrib/ntp/ntpd/ntpd.man.in @@ -0,0 +1,1005 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpd @NTPD_MS@ "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-dUaOfK/ag-qUaGeK) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:11 PM by AutoGen 5.18.5 +.\" From the definitions ntpd-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpd\fP +\- NTP daemon program +.SH SYNOPSIS +\f\*[B-Font]ntpd\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[ ... ] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The +\f\*[B-Font]ntpd\fP +utility is an operating system daemon which sets +and maintains the system time of day in synchronism with Internet +standard time servers. +It is a complete implementation of the +Network Time Protocol (NTP) version 4, as defined by RFC-5905, +but also retains compatibility with +version 3, as defined by RFC-1305, and versions 1 +and 2, as defined by RFC-1059 and RFC-1119, respectively. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]ntpd\fP +utility does most computations in 64-bit floating point +arithmetic and does relatively clumsy 64-bit fixed point operations +only when necessary to preserve the ultimate precision, about 232 +picoseconds. +While the ultimate precision is not achievable with +ordinary workstations and networks of today, it may be required +with future gigahertz CPU clocks and gigabit LANs. +.sp \n(Ppu +.ne 2 + +Ordinarily, +\f\*[B-Font]ntpd\fP +reads the +\fCntp.conf\f[]\fR(5)\f[] +configuration file at startup time in order to determine the +synchronization sources and operating modes. +It is also possible to +specify a working, although limited, configuration entirely on the +command line, obviating the need for a configuration file. +This may +be particularly useful when the local host is to be configured as a +broadcast/multicast client, with all peers being determined by +listening to broadcasts at run time. +.sp \n(Ppu +.ne 2 + +If NetInfo support is built into +\f\*[B-Font]ntpd\fP, +then +\f\*[B-Font]ntpd\fP +will attempt to read its configuration from the +NetInfo if the default +\fCntp.conf\f[]\fR(5)\f[] +file cannot be read and no file is +specified by the +\f\*[B-Font]\-c\f[] +option. +.sp \n(Ppu +.ne 2 + +Various internal +\f\*[B-Font]ntpd\fP +variables can be displayed and +configuration options altered while the +\f\*[B-Font]ntpd\fP +is running +using the +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +and +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[] +utility programs. +.sp \n(Ppu +.ne 2 + +When +\f\*[B-Font]ntpd\fP +starts it looks at the value of +\fCumask\f[]\fR(2)\f[], +and if zero +\f\*[B-Font]ntpd\fP +will set the +\fCumask\f[]\fR(2)\f[] +to 022. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.TP +.NOP \f\*[B-Font]\-6\f[], \f\*[B-Font]\-\-ipv6\f[] +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.TP +.NOP \f\*[B-Font]\-a\f[], \f\*[B-Font]\-\-authreq\f[] +Require crypto authentication. +This option must not appear in combination with any of the following options: +authnoreq. +.sp +Require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is the default. +.TP +.NOP \f\*[B-Font]\-A\f[], \f\*[B-Font]\-\-authnoreq\f[] +Do not require crypto authentication. +This option must not appear in combination with any of the following options: +authreq. +.sp +Do not require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is almost never a good idea. +.TP +.NOP \f\*[B-Font]\-b\f[], \f\*[B-Font]\-\-bcastsync\f[] +Allow us to sync to broadcast servers. +.sp +.TP +.NOP \f\*[B-Font]\-c\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-configfile\f[]=\f\*[I-Font]string\f[] +configuration file name. +.sp +The name and path of the configuration file, +\fI/etc/ntp.conf\fP +by default. +.TP +.NOP \f\*[B-Font]\-d\f[], \f\*[B-Font]\-\-debug\-level\f[] +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-D\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-set\-debug\-level\f[]=\f\*[I-Font]number\f[] +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.TP +.NOP \f\*[B-Font]\-f\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-driftfile\f[]=\f\*[I-Font]string\f[] +frequency drift file name. +.sp +The name and path of the frequency file, +\fI/etc/ntp.drift\fP +by default. +This is the same operation as the +\fBdriftfile\fP \fIdriftfile\fP +configuration specification in the +\fI/etc/ntp.conf\fP +file. +.TP +.NOP \f\*[B-Font]\-g\f[], \f\*[B-Font]\-\-panicgate\f[] +Allow the first adjustment to be Big. +This option may appear an unlimited number of times. +.sp +Normally, +\fBntpd\fP +exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, +\fBntpd\fP +will exit with a message to the system log. This option can be used with the +\fB-q\fP +and +\fB-x\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +.TP +.NOP \f\*[B-Font]\-G\f[], \f\*[B-Font]\-\-force\-step\-once\f[] +Step any initial offset correction.. +.sp +Normally, +\fBntpd\fP +steps the time if the time offset exceeds the step threshold, +which is 128 ms by default, and otherwise slews the time. +This option forces the initial offset correction to be stepped, +so the highest time accuracy can be achieved quickly. +However, this may also cause the time to be stepped back +so this option must not be used if +applications requiring monotonic time are running. +See the \fBtinker\fP configuration file directive for other options. +.TP +.NOP \f\*[B-Font]\-i\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-jaildir\f[]=\f\*[I-Font]string\f[] +Jail directory. +.sp +Chroot the server to the directory +\fIjaildir\fP +. +This option also implies that the server attempts to drop root privileges at startup. +You may need to also specify a +\fB-u\fP +option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB--enable-clockctl\fP) or Linux (configure with +\fB--enable-linuxcaps\fP) or Solaris (configure with \fB--enable-solarisprivs\fP). +.TP +.NOP \f\*[B-Font]\-I\f[] \f\*[I-Font]iface\f[], \f\*[B-Font]\-\-interface\f[]=\f\*[I-Font]iface\f[] +Listen on an interface name or address. +This option may appear an unlimited number of times. +.sp +Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +\fBinterface\fP command, which is more versatile. +.TP +.NOP \f\*[B-Font]\-k\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-keyfile\f[]=\f\*[I-Font]string\f[] +path to symmetric keys. +.sp +Specify the name and path of the symmetric key file. +\fI/etc/ntp.keys\fP +is the default. +This is the same operation as the +\fBkeys\fP \fIkeyfile\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-l\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-logfile\f[]=\f\*[I-Font]string\f[] +path to the log file. +.sp +Specify the name and path of the log file. +The default is the system log file. +This is the same operation as the +\fBlogfile\fP \fIlogfile\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-L\f[], \f\*[B-Font]\-\-novirtualips\f[] +Do not listen to virtual interfaces. +.sp +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file \fBinterface\fP command, which +is more versatile. +.TP +.NOP \f\*[B-Font]\-M\f[], \f\*[B-Font]\-\-modifymmtimer\f[] +Modify Multimedia Timer (Windows only). +.sp +Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-nofork\f[] +Do not fork. +This option must not appear in combination with any of the following options: +wait-sync. +.sp +.TP +.NOP \f\*[B-Font]\-N\f[], \f\*[B-Font]\-\-nice\f[] +Run at high priority. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the highest priority. +.TP +.NOP \f\*[B-Font]\-p\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-pidfile\f[]=\f\*[I-Font]string\f[] +path to the PID file. +.sp +Specify the name and path of the file used to record +\fBntpd\fP's +process ID. +This is the same operation as the +\fBpidfile\fP \fIpidfile\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-P\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-priority\f[]=\f\*[I-Font]number\f[] +Process priority. +This option takes an integer number as its argument. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the specified +\fBsched_setscheduler(SCHED_FIFO)\fP +priority. +.TP +.NOP \f\*[B-Font]\-q\f[], \f\*[B-Font]\-\-quit\f[] +Set the time and quit. +This option must not appear in combination with any of the following options: +saveconfigquit, wait-sync. +.sp +\fBntpd\fP +will not daemonize and will exit after the clock is first +synchronized. This behavior mimics that of the +\fBntpdate\fP +program, which will soon be replaced with a shell script. +The +\fB-g\fP +and +\fB-x\fP +options can be used with this option. +Note: The kernel time discipline is disabled with this option. +.TP +.NOP \f\*[B-Font]\-r\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-propagationdelay\f[]=\f\*[I-Font]string\f[] +Broadcast/propagation delay. +.sp +Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. +.TP +.NOP \f\*[B-Font]\-\-saveconfigquit\f[]=\f\*[I-Font]string\f[] +Save parsed configuration and quit. +This option must not appear in combination with any of the following options: +quit, wait-sync. +.sp +Cause \fBntpd\fP to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-statsdir\f[]=\f\*[I-Font]string\f[] +Statistics file location. +.sp +Specify the directory path for files created by the statistics facility. +This is the same operation as the +\fBstatsdir\fP \fIstatsdir\fP +configuration file directive. +.TP +.NOP \f\*[B-Font]\-t\f[] \f\*[I-Font]tkey\f[], \f\*[B-Font]\-\-trustedkey\f[]=\f\*[I-Font]tkey\f[] +Trusted key number. +This option may appear an unlimited number of times. +.sp +Add the specified key number to the trusted key list. +.TP +.NOP \f\*[B-Font]\-u\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-user\f[]=\f\*[I-Font]string\f[] +Run as userid (or userid:groupid). +.sp +Specify a user, and optionally a group, to switch to. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB--enable-clockctl\fP) or Linux (configure with +\fB--enable-linuxcaps\fP) or Solaris (configure with \fB--enable-solarisprivs\fP). +.TP +.NOP \f\*[B-Font]\-U\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-updateinterval\f[]=\f\*[I-Font]number\f[] +interval in seconds between scans for new or dropped interfaces. +This option takes an integer number as its argument. +.sp +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. +.TP +.NOP \f\*[B-Font]\-\-var\f[]=\f\*[I-Font]nvar\f[] +make ARG an ntp variable (RW). +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-\-dvar\f[]=\f\*[I-Font]ndvar\f[] +make ARG an ntp variable (RW|DEF). +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-w\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-wait\-sync\f[]=\f\*[I-Font]number\f[] +Seconds to wait for first clock sync. +This option must not appear in combination with any of the following options: +nofork, quit, saveconfigquit. +This option takes an integer number as its argument. +.sp +If greater than zero, alters \fBntpd\fP's behavior when forking to +daemonize. Instead of exiting with status 0 immediately after +the fork, the parent waits up to the specified number of +seconds for the child to first synchronize the clock. The exit +status is zero (success) if the clock was synchronized, +otherwise it is \fBETIMEDOUT\fP. +This provides the option for a script starting \fBntpd\fP to easily +wait for the first set of the clock before proceeding. +.TP +.NOP \f\*[B-Font]\-x\f[], \f\*[B-Font]\-\-slew\f[] +Slew up to 600 seconds. +.sp +Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. +This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. +Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. +Thus, an adjustment as much as 600 s will take almost 14 days to complete. +This option can be used with the +\fB-g\fP +and +\fB-q\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +Note: The kernel time discipline is disabled with this option. +.TP +.NOP \f\*[B-Font]\-\-usepcc\f[] +Use CPU cycle counter (Windows only). +.sp +Attempt to substitute the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter and \fBQueryPerformanceCounter\fP are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. +.TP +.NOP \f\*[B-Font]\-\-pccfreq\f[]=\f\*[I-Font]string\f[] +Force CPU cycle counter use (Windows only). +.sp +Force substitution the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). +.TP +.NOP \f\*[B-Font]\-m\f[], \f\*[B-Font]\-\-mdns\f[] +Register with mDNS as a NTP server. +.sp +Registers as an NTP server with the local mDNS server which allows +the server to be discovered via mDNS client lookup. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTPD_\fP or \fBNTPD\fP +.fi +.ad +.SH USAGE +.SS "How NTP Operates" +The +\f\*[B-Font]ntpd\fP +utility operates by exchanging messages with +one or more configured servers over a range of designated poll intervals. +When +started, whether for the first or subsequent times, the program +requires several exchanges from the majority of these servers so +the signal processing and mitigation algorithms can accumulate and +groom the data and set the clock. +In order to protect the network +from bursts, the initial poll interval for each server is delayed +an interval randomized over a few seconds. +At the default initial poll +interval of 64s, several minutes can elapse before the clock is +set. +This initial delay to set the clock +can be safely and dramatically reduced using the +\f\*[B-Font]iburst\f[] +keyword with the +\f\*[B-Font]server\f[] +configuration +command, as described in +\fCntp.conf\f[]\fR(5)\f[]. +.sp \n(Ppu +.ne 2 + +Most operating systems and hardware of today incorporate a +time-of-year (TOY) chip to maintain the time during periods when +the power is off. +When the machine is booted, the chip is used to +initialize the operating system time. +After the machine has +synchronized to a NTP server, the operating system corrects the +chip from time to time. +In the default case, if +\f\*[B-Font]ntpd\fP +detects that the time on the host +is more than 1000s from the server time, +\f\*[B-Font]ntpd\fP +assumes something must be terribly wrong and the only +reliable action is for the operator to intervene and set the clock +by hand. +(Reasons for this include there is no TOY chip, +or its battery is dead, or that the TOY chip is just of poor quality.) +This causes +\f\*[B-Font]ntpd\fP +to exit with a panic message to +the system log. +The +\f\*[B-Font]\-g\f[] +option overrides this check and the +clock will be set to the server time regardless of the chip time +(up to 68 years in the past or future \(em +this is a limitation of the NTPv4 protocol). +However, and to protect against broken hardware, such as when the +CMOS battery fails or the clock counter becomes defective, once the +clock has been set an error greater than 1000s will cause +\f\*[B-Font]ntpd\fP +to exit anyway. +.sp \n(Ppu +.ne 2 + +Under ordinary conditions, +\f\*[B-Font]ntpd\fP +adjusts the clock in +small steps so that the timescale is effectively continuous and +without discontinuities. +Under conditions of extreme network +congestion, the roundtrip delay jitter can exceed three seconds and +the synchronization distance, which is equal to one-half the +roundtrip delay plus error budget terms, can become very large. +The +\f\*[B-Font]ntpd\fP +algorithms discard sample offsets exceeding 128 ms, +unless the interval during which no sample offset is less than 128 +ms exceeds 900s. +The first sample after that, no matter what the +offset, steps the clock to the indicated time. +In practice this +reduces the false alarm rate where the clock is stepped in error to +a vanishingly low incidence. +.sp \n(Ppu +.ne 2 + +As the result of this behavior, once the clock has been set it +very rarely strays more than 128 ms even under extreme cases of +network path congestion and jitter. +Sometimes, in particular when +\f\*[B-Font]ntpd\fP +is first started without a valid drift file +on a system with a large intrinsic drift +the error might grow to exceed 128 ms, +which would cause the clock to be set backwards +if the local clock time is more than 128 s +in the future relative to the server. +In some applications, this behavior may be unacceptable. +There are several solutions, however. +If the +\f\*[B-Font]\-x\f[] +option is included on the command line, the clock will +never be stepped and only slew corrections will be used. +But this choice comes with a cost that +should be carefully explored before deciding to use +the +\f\*[B-Font]\-x\f[] +option. +The maximum slew rate possible is limited +to 500 parts-per-million (PPM) as a consequence of the correctness +principles on which the NTP protocol and algorithm design are +based. +As a result, the local clock can take a long time to +converge to an acceptable offset, about 2,000 s for each second the +clock is outside the acceptable range. +During this interval the +local clock will not be consistent with any other network clock and +the system cannot be used for distributed applications that require +correctly synchronized network time. +.sp \n(Ppu +.ne 2 + +In spite of the above precautions, sometimes when large +frequency errors are present the resulting time offsets stray +outside the 128-ms range and an eventual step or slew time +correction is required. +If following such a correction the +frequency error is so large that the first sample is outside the +acceptable range, +\f\*[B-Font]ntpd\fP +enters the same state as when the +\fIntp.drift\f[] +file is not present. +The intent of this behavior +is to quickly correct the frequency and restore operation to the +normal tracking mode. +In the most extreme cases +(the host +\f\*[B-Font]time.ien.it\f[] +comes to mind), there may be occasional +step/slew corrections and subsequent frequency corrections. +It +helps in these cases to use the +\f\*[B-Font]burst\f[] +keyword when +configuring the server, but +ONLY +when you have permission to do so from the owner of the target host. +.sp \n(Ppu +.ne 2 + +Finally, +in the past many startup scripts would run +\fCntpdate\f[]\fR(@NTPDATE_MS@)\f[] +or +\fCsntp\f[]\fR(@SNTP_MS@)\f[] +to get the system clock close to correct before starting +\fCntpd\f[]\fR(@NTPD_MS@)\f[], +but this was never more than a mediocre hack and is no longer needed. +If you are following the instructions in +\fIStarting NTP (Best Current Practice)\f[] +and you still need to set the system time before starting +\f\*[B-Font]ntpd\fP, +please open a bug report and document what is going on, +and then look at using +\fCsntp\f[]\fR(@SNTP_MS@)\f[] +if you really need to set the clock before starting +\f\*[B-Font]ntpd\fP. +.sp \n(Ppu +.ne 2 + +There is a way to start +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +that often addresses all of the problems mentioned above. +.SS "Starting NTP (Best Current Practice)" +First, use the +\f\*[B-Font]iburst\f[] +option on your +\f\*[B-Font]server\f[] +entries. +.sp \n(Ppu +.ne 2 + +If you can also keep a good +\fIntp.drift\f[] +file then +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +will effectively "warm-start" and your system's clock will +be stable in under 11 seconds' time. +.sp \n(Ppu +.ne 2 + +As soon as possible in the startup sequence, start +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +with at least the +\f\*[B-Font]\-g\f[] +and perhaps the +\f\*[B-Font]\-N\f[] +options. +Then, +start the rest of your "normal" processes. +This will give +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +as much time as possible to get the system's clock synchronized and stable. +.sp \n(Ppu +.ne 2 + +Finally, +if you have processes like +\f\*[B-Font]dovecot\f[] +or database servers +that require +monotonically-increasing time, +run +\fCntp-wait\f[]\fR(@NTP_WAIT_MS@)\f[] +as late as possible in the boot sequence +(perhaps with the +\f\*[B-Font]\-v\f[] +flag) +and after +\fCntp-wait\f[]\fR(@NTP_WAIT_MS@)\f[] +exits successfully +it is as safe as it will ever be to start any process that require +stable time. +.SS "Frequency Discipline" +The +\f\*[B-Font]ntpd\fP +behavior at startup depends on whether the +frequency file, usually +\fIntp.drift\f[], +exists. +This file +contains the latest estimate of clock frequency error. +When the +\f\*[B-Font]ntpd\fP +is started and the file does not exist, the +\f\*[B-Font]ntpd\fP +enters a special mode designed to quickly adapt to +the particular system clock oscillator time and frequency error. +This takes approximately 15 minutes, after which the time and +frequency are set to nominal values and the +\f\*[B-Font]ntpd\fP +enters +normal mode, where the time and frequency are continuously tracked +relative to the server. +After one hour the frequency file is +created and the current frequency offset written to it. +When the +\f\*[B-Font]ntpd\fP +is started and the file does exist, the +\f\*[B-Font]ntpd\fP +frequency is initialized from the file and enters normal mode +immediately. +After that the current frequency offset is written to +the file at hourly intervals. +.SS "Operating Modes" +The +\f\*[B-Font]ntpd\fP +utility can operate in any of several modes, including +symmetric active/passive, client/server broadcast/multicast and +manycast, as described in the +"Association Management" +page +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]). +It normally operates continuously while +monitoring for small changes in frequency and trimming the clock +for the ultimate precision. +However, it can operate in a one-time +mode where the time is set from an external server and frequency is +set from a previously recorded frequency file. +A +broadcast/multicast or manycast client can discover remote servers, +compute server-client propagation delay correction factors and +configure itself automatically. +This makes it possible to deploy a +fleet of workstations without specifying configuration details +specific to the local environment. +.sp \n(Ppu +.ne 2 + +By default, +\f\*[B-Font]ntpd\fP +runs in continuous mode where each of +possibly several external servers is polled at intervals determined +by an intricate state machine. +The state machine measures the +incidental roundtrip delay jitter and oscillator frequency wander +and determines the best poll interval using a heuristic algorithm. +Ordinarily, and in most operating environments, the state machine +will start with 64s intervals and eventually increase in steps to +1024s. +A small amount of random variation is introduced in order to +avoid bunching at the servers. +In addition, should a server become +unreachable for some time, the poll interval is increased in steps +to 1024s in order to reduce network overhead. +.sp \n(Ppu +.ne 2 + +In some cases it may not be practical for +\f\*[B-Font]ntpd\fP +to run continuously. +A common workaround has been to run the +\fCntpdate\f[]\fR(@NTPDATE_MS@)\f[] +or +\fCsntp\f[]\fR(@SNTP_MS@)\f[] +programs from a +\fCcron\f[]\fR(8)\f[] +job at designated +times. +However, these programs do not have the crafted signal +processing, error checking or mitigation algorithms of +\f\*[B-Font]ntpd\fP. +The +\f\*[B-Font]\-q\f[] +option is intended for this purpose. +Setting this option will cause +\f\*[B-Font]ntpd\fP +to exit just after +setting the clock for the first time. +The procedure for initially +setting the clock is the same as in continuous mode; most +applications will probably want to specify the +\f\*[B-Font]iburst\f[] +keyword with the +\f\*[B-Font]server\f[] +configuration command. +With this +keyword a volley of messages are exchanged to groom the data and +the clock is set in about 10 s. +If nothing is heard after a +couple of minutes, the daemon times out and exits. +After a suitable +period of mourning, the +\fCntpdate\f[]\fR(@NTPDATE_MS@)\f[] +program will be +retired. +.sp \n(Ppu +.ne 2 + +When kernel support is available to discipline the clock +frequency, which is the case for stock Solaris, Tru64, Linux and +FreeBSD, +a useful feature is available to discipline the clock +frequency. +First, +\f\*[B-Font]ntpd\fP +is run in continuous mode with +selected servers in order to measure and record the intrinsic clock +frequency offset in the frequency file. +It may take some hours for +the frequency and offset to settle down. +Then the +\f\*[B-Font]ntpd\fP +is +stopped and run in one-time mode as required. +At each startup, the +frequency is read from the file and initializes the kernel +frequency. +.SS "Poll Interval Control" +This version of NTP includes an intricate state machine to +reduce the network load while maintaining a quality of +synchronization consistent with the observed jitter and wander. +There are a number of ways to tailor the operation in order enhance +accuracy by reducing the interval or to reduce network overhead by +increasing it. +However, the user is advised to carefully consider +the consequences of changing the poll adjustment range from the +default minimum of 64 s to the default maximum of 1,024 s. +The +default minimum can be changed with the +\f\*[B-Font]tinker\f[] +\f\*[B-Font]minpoll\f[] +command to a value not less than 16 s. +This value is used for all +configured associations, unless overridden by the +\f\*[B-Font]minpoll\f[] +option on the configuration command. +Note that most device drivers +will not operate properly if the poll interval is less than 64 s +and that the broadcast server and manycast client associations will +also use the default, unless overridden. +.sp \n(Ppu +.ne 2 + +In some cases involving dial up or toll services, it may be +useful to increase the minimum interval to a few tens of minutes +and maximum interval to a day or so. +Under normal operation +conditions, once the clock discipline loop has stabilized the +interval will be increased in steps from the minimum to the +maximum. +However, this assumes the intrinsic clock frequency error +is small enough for the discipline loop correct it. +The capture +range of the loop is 500 PPM at an interval of 64s decreasing by a +factor of two for each doubling of interval. +At a minimum of 1,024 +s, for example, the capture range is only 31 PPM. +If the intrinsic +error is greater than this, the drift file +\fIntp.drift\f[] +will +have to be specially tailored to reduce the residual error below +this limit. +Once this is done, the drift file is automatically +updated once per hour and is available to initialize the frequency +on subsequent daemon restarts. +.SS "The huff-n'-puff Filter" +In scenarios where a considerable amount of data are to be +downloaded or uploaded over telephone modems, timekeeping quality +can be seriously degraded. +This occurs because the differential +delays on the two directions of transmission can be quite large. +In +many cases the apparent time errors are so large as to exceed the +step threshold and a step correction can occur during and after the +data transfer is in progress. +.sp \n(Ppu +.ne 2 + +The huff-n'-puff filter is designed to correct the apparent time +offset in these cases. +It depends on knowledge of the propagation +delay when no other traffic is present. +In common scenarios this +occurs during other than work hours. +The filter maintains a shift +register that remembers the minimum delay over the most recent +interval measured usually in hours. +Under conditions of severe +delay, the filter corrects the apparent offset using the sign of +the offset and the difference between the apparent delay and +minimum delay. +The name of the filter reflects the negative (huff) +and positive (puff) correction, which depends on the sign of the +offset. +.sp \n(Ppu +.ne 2 + +The filter is activated by the +\f\*[B-Font]tinker\f[] +command and +\f\*[B-Font]huffpuff\f[] +keyword, as described in +\fCntp.conf\f[]\fR(5)\f[]. +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH FILES +.TP 15 +.NOP \fI/etc/ntp.conf\f[] +the default name of the configuration file +.br +.ns +.TP 15 +.NOP \fI/etc/ntp.drift\f[] +the default name of the drift file +.br +.ns +.TP 15 +.NOP \fI/etc/ntp.keys\f[] +the default name of the key file +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "SEE ALSO" +\fCntp.conf\f[]\fR(5)\f[], +\fCntpdate\f[]\fR(@NTPDATE_MS@)\f[], +\fCntpdc\f[]\fR(@NTPDC_MS@)\f[], +\fCntpq\f[]\fR(@NTPQ_MS@)\f[], +\fCsntp\f[]\fR(@SNTP_MS@)\f[] +.sp \n(Ppu +.ne 2 + +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +\f[C]http://www.ntp.org/\f[]. +A snapshot of this documentation is available in HTML format in +\fI/usr/share/doc/ntp\f[]. +David L. Mills, +\fINetwork Time Protocol (Version 1)\fR, +RFC1059 +.PP + +David L. Mills, +\fINetwork Time Protocol (Version 2)\fR, +RFC1119 +.PP + +David L. Mills, +\fINetwork Time Protocol (Version 3)\fR, +RFC1305 +.PP + +David L. Mills and J. Martin, Ed. and J. Burbank and W. Kasch, +\fINetwork Time Protocol Version 4: Protocol and Algorithms Specification\fR, +RFC5905 +.PP + +David L. Mills and B. Haberman, Ed., +\fINetwork Time Protocol Version 4: Autokey Specification\fR, +RFC5906 +.PP + +H. Gerstung and C. Elliott and B. Haberman, Ed., +\fIDefinitions of Managed Objects for Network Time Protocol Version 4: (NTPv4)\fR, +RFC5907 +.PP + +R. Gayraud and B. Lourdelet, +\fINetwork Time Protocol (NTP) Server Option for DHCPv6\fR, +RFC5908 +.PP + +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH BUGS +The +\f\*[B-Font]ntpd\fP +utility has gotten rather fat. +While not huge, it has gotten +larger than might be desirable for an elevated-priority +\f\*[B-Font]ntpd\fP +running on a workstation, particularly since many of +the fancy features which consume the space were designed more with +a busy primary server, rather than a high stratum workstation in +mind. +.sp \n(Ppu +.ne 2 + +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +Portions of this document came from FreeBSD. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntpd\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntpd.mdoc.in b/contrib/ntp/ntpd/ntpd.mdoc.in new file mode 100644 index 000000000..ad71af9ad --- /dev/null +++ b/contrib/ntp/ntpd/ntpd.mdoc.in @@ -0,0 +1,908 @@ +.Dd October 21 2015 +.Dt NTPD @NTPD_MS@ User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpd-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:30 PM by AutoGen 5.18.5 +.\" From the definitions ntpd-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpd +.Nd NTP daemon program +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[ ... ] +.Pp +.Sh DESCRIPTION +The +.Nm +utility is an operating system daemon which sets +and maintains the system time of day in synchronism with Internet +standard time servers. +It is a complete implementation of the +Network Time Protocol (NTP) version 4, as defined by RFC\-5905, +but also retains compatibility with +version 3, as defined by RFC\-1305, and versions 1 +and 2, as defined by RFC\-1059 and RFC\-1119, respectively. +.Pp +The +.Nm +utility does most computations in 64\-bit floating point +arithmetic and does relatively clumsy 64\-bit fixed point operations +only when necessary to preserve the ultimate precision, about 232 +picoseconds. +While the ultimate precision is not achievable with +ordinary workstations and networks of today, it may be required +with future gigahertz CPU clocks and gigabit LANs. +.Pp +Ordinarily, +.Nm +reads the +.Xr ntp.conf 5 +configuration file at startup time in order to determine the +synchronization sources and operating modes. +It is also possible to +specify a working, although limited, configuration entirely on the +command line, obviating the need for a configuration file. +This may +be particularly useful when the local host is to be configured as a +broadcast/multicast client, with all peers being determined by +listening to broadcasts at run time. +.Pp +If NetInfo support is built into +.Nm , +then +.Nm +will attempt to read its configuration from the +NetInfo if the default +.Xr ntp.conf 5 +file cannot be read and no file is +specified by the +.Fl c +option. +.Pp +Various internal +.Nm +variables can be displayed and +configuration options altered while the +.Nm +is running +using the +.Xr ntpq @NTPQ_MS@ +and +.Xr ntpdc @NTPDC_MS@ +utility programs. +.Pp +When +.Nm +starts it looks at the value of +.Xr umask 2 , +and if zero +.Nm +will set the +.Xr umask 2 +to 022. +.Sh "OPTIONS" +.Bl -tag +.It Fl 4 , Fl \-ipv4 +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.It Fl 6 , Fl \-ipv6 +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.It Fl a , Fl \-authreq +Require crypto authentication. +This option must not appear in combination with any of the following options: +authnoreq. +.sp +Require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is the default. +.It Fl A , Fl \-authnoreq +Do not require crypto authentication. +This option must not appear in combination with any of the following options: +authreq. +.sp +Do not require cryptographic authentication for broadcast client, +multicast client and symmetric passive associations. +This is almost never a good idea. +.It Fl b , Fl \-bcastsync +Allow us to sync to broadcast servers. +.sp +.It Fl c Ar string , Fl \-configfile Ns = Ns Ar string +configuration file name. +.sp +The name and path of the configuration file, +\fI/etc/ntp.conf\fP +by default. +.It Fl d , Fl \-debug\-level +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.It Fl D Ar number , Fl \-set\-debug\-level Ns = Ns Ar number +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.It Fl f Ar string , Fl \-driftfile Ns = Ns Ar string +frequency drift file name. +.sp +The name and path of the frequency file, +\fI/etc/ntp.drift\fP +by default. +This is the same operation as the +\fBdriftfile\fP \fIdriftfile\fP +configuration specification in the +\fI/etc/ntp.conf\fP +file. +.It Fl g , Fl \-panicgate +Allow the first adjustment to be Big. +This option may appear an unlimited number of times. +.sp +Normally, +\fBntpd\fP +exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, +\fBntpd\fP +will exit with a message to the system log. This option can be used with the +\fB\-q\fP +and +\fB\-x\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +.It Fl G , Fl \-force\-step\-once +Step any initial offset correction.. +.sp +Normally, +\fBntpd\fP +steps the time if the time offset exceeds the step threshold, +which is 128 ms by default, and otherwise slews the time. +This option forces the initial offset correction to be stepped, +so the highest time accuracy can be achieved quickly. +However, this may also cause the time to be stepped back +so this option must not be used if +applications requiring monotonic time are running. +See the \fBtinker\fP configuration file directive for other options. +.It Fl i Ar string , Fl \-jaildir Ns = Ns Ar string +Jail directory. +.sp +Chroot the server to the directory +\fIjaildir\fP +. +This option also implies that the server attempts to drop root privileges at startup. +You may need to also specify a +\fB\-u\fP +option. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB\-\-enable\-clockctl\fP) or Linux (configure with +\fB\-\-enable\-linuxcaps\fP) or Solaris (configure with \fB\-\-enable\-solarisprivs\fP). +.It Fl I Ar iface , Fl \-interface Ns = Ns Ar iface +Listen on an interface name or address. +This option may appear an unlimited number of times. +.sp +Open the network address given, or all the addresses associated with the +given interface name. This option may appear multiple times. This option +also implies not opening other addresses, except wildcard and localhost. +This option is deprecated. Please consider using the configuration file +\fBinterface\fP command, which is more versatile. +.It Fl k Ar string , Fl \-keyfile Ns = Ns Ar string +path to symmetric keys. +.sp +Specify the name and path of the symmetric key file. +\fI/etc/ntp.keys\fP +is the default. +This is the same operation as the +\fBkeys\fP \fIkeyfile\fP +configuration file directive. +.It Fl l Ar string , Fl \-logfile Ns = Ns Ar string +path to the log file. +.sp +Specify the name and path of the log file. +The default is the system log file. +This is the same operation as the +\fBlogfile\fP \fIlogfile\fP +configuration file directive. +.It Fl L , Fl \-novirtualips +Do not listen to virtual interfaces. +.sp +Do not listen to virtual interfaces, defined as those with +names containing a colon. This option is deprecated. Please +consider using the configuration file \fBinterface\fP command, which +is more versatile. +.It Fl M , Fl \-modifymmtimer +Modify Multimedia Timer (Windows only). +.sp +Set the Windows Multimedia Timer to highest resolution. This +ensures the resolution does not change while ntpd is running, +avoiding timekeeping glitches associated with changes. +.It Fl n , Fl \-nofork +Do not fork. +This option must not appear in combination with any of the following options: +wait\-sync. +.sp +.It Fl N , Fl \-nice +Run at high priority. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the highest priority. +.It Fl p Ar string , Fl \-pidfile Ns = Ns Ar string +path to the PID file. +.sp +Specify the name and path of the file used to record +\fBntpd\fP's +process ID. +This is the same operation as the +\fBpidfile\fP \fIpidfile\fP +configuration file directive. +.It Fl P Ar number , Fl \-priority Ns = Ns Ar number +Process priority. +This option takes an integer number as its argument. +.sp +To the extent permitted by the operating system, run +\fBntpd\fP +at the specified +\fBsched_setscheduler(SCHED_FIFO)\fP +priority. +.It Fl q , Fl \-quit +Set the time and quit. +This option must not appear in combination with any of the following options: +saveconfigquit, wait\-sync. +.sp +\fBntpd\fP +will not daemonize and will exit after the clock is first +synchronized. This behavior mimics that of the +\fBntpdate\fP +program, which will soon be replaced with a shell script. +The +\fB\-g\fP +and +\fB\-x\fP +options can be used with this option. +Note: The kernel time discipline is disabled with this option. +.It Fl r Ar string , Fl \-propagationdelay Ns = Ns Ar string +Broadcast/propagation delay. +.sp +Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. +.It Fl \-saveconfigquit Ns = Ns Ar string +Save parsed configuration and quit. +This option must not appear in combination with any of the following options: +quit, wait\-sync. +.sp +Cause \fBntpd\fP to parse its startup configuration file and save an +equivalent to the given filename and exit. This option was +designed for automated testing. +.It Fl s Ar string , Fl \-statsdir Ns = Ns Ar string +Statistics file location. +.sp +Specify the directory path for files created by the statistics facility. +This is the same operation as the +\fBstatsdir\fP \fIstatsdir\fP +configuration file directive. +.It Fl t Ar tkey , Fl \-trustedkey Ns = Ns Ar tkey +Trusted key number. +This option may appear an unlimited number of times. +.sp +Add the specified key number to the trusted key list. +.It Fl u Ar string , Fl \-user Ns = Ns Ar string +Run as userid (or userid:groupid). +.sp +Specify a user, and optionally a group, to switch to. +This option is only available if the OS supports adjusting the clock +without full root privileges. +This option is supported under NetBSD (configure with +\fB\-\-enable\-clockctl\fP) or Linux (configure with +\fB\-\-enable\-linuxcaps\fP) or Solaris (configure with \fB\-\-enable\-solarisprivs\fP). +.It Fl U Ar number , Fl \-updateinterval Ns = Ns Ar number +interval in seconds between scans for new or dropped interfaces. +This option takes an integer number as its argument. +.sp +Give the time in seconds between two scans for new or dropped interfaces. +For systems with routing socket support the scans will be performed shortly after the interface change +has been detected by the system. +Use 0 to disable scanning. 60 seconds is the minimum time between scans. +.It Fl \-var Ns = Ns Ar nvar +make ARG an ntp variable (RW). +This option may appear an unlimited number of times. +.sp +.It Fl \-dvar Ns = Ns Ar ndvar +make ARG an ntp variable (RW|DEF). +This option may appear an unlimited number of times. +.sp +.It Fl w Ar number , Fl \-wait\-sync Ns = Ns Ar number +Seconds to wait for first clock sync. +This option must not appear in combination with any of the following options: +nofork, quit, saveconfigquit. +This option takes an integer number as its argument. +.sp +If greater than zero, alters \fBntpd\fP's behavior when forking to +daemonize. Instead of exiting with status 0 immediately after +the fork, the parent waits up to the specified number of +seconds for the child to first synchronize the clock. The exit +status is zero (success) if the clock was synchronized, +otherwise it is \fBETIMEDOUT\fP. +This provides the option for a script starting \fBntpd\fP to easily +wait for the first set of the clock before proceeding. +.It Fl x , Fl \-slew +Slew up to 600 seconds. +.sp +Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. +This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. +Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. +Thus, an adjustment as much as 600 s will take almost 14 days to complete. +This option can be used with the +\fB\-g\fP +and +\fB\-q\fP +options. +See the +\fBtinker\fP +configuration file directive for other options. +Note: The kernel time discipline is disabled with this option. +.It Fl \-usepcc +Use CPU cycle counter (Windows only). +.sp +Attempt to substitute the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter and \fBQueryPerformanceCounter\fP are compared, and if +they have the same frequency, the CPU counter (RDTSC on x86) is +used directly, saving the overhead of a system call. +.It Fl \-pccfreq Ns = Ns Ar string +Force CPU cycle counter use (Windows only). +.sp +Force substitution the CPU counter for \fBQueryPerformanceCounter\fP. +The CPU counter (RDTSC on x86) is used unconditionally with the +given frequency (in Hz). +.It Fl m , Fl \-mdns +Register with mDNS as a NTP server. +.sp +Registers as an NTP server with the local mDNS server which allows +the server to be discovered via mDNS client lookup. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from environment variables named: +.nf + \fBNTPD_\fP or \fBNTPD\fP +.fi +.ad +.Sh USAGE +.Ss "How NTP Operates" +The +.Nm +utility operates by exchanging messages with +one or more configured servers over a range of designated poll intervals. +When +started, whether for the first or subsequent times, the program +requires several exchanges from the majority of these servers so +the signal processing and mitigation algorithms can accumulate and +groom the data and set the clock. +In order to protect the network +from bursts, the initial poll interval for each server is delayed +an interval randomized over a few seconds. +At the default initial poll +interval of 64s, several minutes can elapse before the clock is +set. +This initial delay to set the clock +can be safely and dramatically reduced using the +.Cm iburst +keyword with the +.Ic server +configuration +command, as described in +.Xr ntp.conf 5 . +.Pp +Most operating systems and hardware of today incorporate a +time\-of\-year (TOY) chip to maintain the time during periods when +the power is off. +When the machine is booted, the chip is used to +initialize the operating system time. +After the machine has +synchronized to a NTP server, the operating system corrects the +chip from time to time. +In the default case, if +.Nm +detects that the time on the host +is more than 1000s from the server time, +.Nm +assumes something must be terribly wrong and the only +reliable action is for the operator to intervene and set the clock +by hand. +(Reasons for this include there is no TOY chip, +or its battery is dead, or that the TOY chip is just of poor quality.) +This causes +.Nm +to exit with a panic message to +the system log. +The +.Fl g +option overrides this check and the +clock will be set to the server time regardless of the chip time +(up to 68 years in the past or future \(em +this is a limitation of the NTPv4 protocol). +However, and to protect against broken hardware, such as when the +CMOS battery fails or the clock counter becomes defective, once the +clock has been set an error greater than 1000s will cause +.Nm +to exit anyway. +.Pp +Under ordinary conditions, +.Nm +adjusts the clock in +small steps so that the timescale is effectively continuous and +without discontinuities. +Under conditions of extreme network +congestion, the roundtrip delay jitter can exceed three seconds and +the synchronization distance, which is equal to one\-half the +roundtrip delay plus error budget terms, can become very large. +The +.Nm +algorithms discard sample offsets exceeding 128 ms, +unless the interval during which no sample offset is less than 128 +ms exceeds 900s. +The first sample after that, no matter what the +offset, steps the clock to the indicated time. +In practice this +reduces the false alarm rate where the clock is stepped in error to +a vanishingly low incidence. +.Pp +As the result of this behavior, once the clock has been set it +very rarely strays more than 128 ms even under extreme cases of +network path congestion and jitter. +Sometimes, in particular when +.Nm +is first started without a valid drift file +on a system with a large intrinsic drift +the error might grow to exceed 128 ms, +which would cause the clock to be set backwards +if the local clock time is more than 128 s +in the future relative to the server. +In some applications, this behavior may be unacceptable. +There are several solutions, however. +If the +.Fl x +option is included on the command line, the clock will +never be stepped and only slew corrections will be used. +But this choice comes with a cost that +should be carefully explored before deciding to use +the +.Fl x +option. +The maximum slew rate possible is limited +to 500 parts\-per\-million (PPM) as a consequence of the correctness +principles on which the NTP protocol and algorithm design are +based. +As a result, the local clock can take a long time to +converge to an acceptable offset, about 2,000 s for each second the +clock is outside the acceptable range. +During this interval the +local clock will not be consistent with any other network clock and +the system cannot be used for distributed applications that require +correctly synchronized network time. +.Pp +In spite of the above precautions, sometimes when large +frequency errors are present the resulting time offsets stray +outside the 128\-ms range and an eventual step or slew time +correction is required. +If following such a correction the +frequency error is so large that the first sample is outside the +acceptable range, +.Nm +enters the same state as when the +.Pa ntp.drift +file is not present. +The intent of this behavior +is to quickly correct the frequency and restore operation to the +normal tracking mode. +In the most extreme cases +(the host +.Cm time.ien.it +comes to mind), there may be occasional +step/slew corrections and subsequent frequency corrections. +It +helps in these cases to use the +.Cm burst +keyword when +configuring the server, but +ONLY +when you have permission to do so from the owner of the target host. +.Pp +Finally, +in the past many startup scripts would run +.Xr ntpdate @NTPDATE_MS@ +or +.Xr sntp @SNTP_MS@ +to get the system clock close to correct before starting +.Xr ntpd @NTPD_MS@ , +but this was never more than a mediocre hack and is no longer needed. +If you are following the instructions in +.Sx "Starting NTP (Best Current Practice)" +and you still need to set the system time before starting +.Nm , +please open a bug report and document what is going on, +and then look at using +.Xr sntp @SNTP_MS@ +if you really need to set the clock before starting +.Nm . +.Pp +There is a way to start +.Xr ntpd @NTPD_MS@ +that often addresses all of the problems mentioned above. +.Ss "Starting NTP (Best Current Practice)" +First, use the +.Cm iburst +option on your +.Cm server +entries. +.Pp +If you can also keep a good +.Pa ntp.drift +file then +.Xr ntpd @NTPD_MS@ +will effectively "warm\-start" and your system's clock will +be stable in under 11 seconds' time. +.Pp +As soon as possible in the startup sequence, start +.Xr ntpd @NTPD_MS@ +with at least the +.Fl g +and perhaps the +.Fl N +options. +Then, +start the rest of your "normal" processes. +This will give +.Xr ntpd @NTPD_MS@ +as much time as possible to get the system's clock synchronized and stable. +.Pp +Finally, +if you have processes like +.Cm dovecot +or database servers +that require +monotonically\-increasing time, +run +.Xr ntp\-wait 1ntp\-waitmdoc +as late as possible in the boot sequence +(perhaps with the +.Fl v +flag) +and after +.Xr ntp\-wait 1ntp\-waitmdoc +exits successfully +it is as safe as it will ever be to start any process that require +stable time. +.Ss "Frequency Discipline" +The +.Nm +behavior at startup depends on whether the +frequency file, usually +.Pa ntp.drift , +exists. +This file +contains the latest estimate of clock frequency error. +When the +.Nm +is started and the file does not exist, the +.Nm +enters a special mode designed to quickly adapt to +the particular system clock oscillator time and frequency error. +This takes approximately 15 minutes, after which the time and +frequency are set to nominal values and the +.Nm +enters +normal mode, where the time and frequency are continuously tracked +relative to the server. +After one hour the frequency file is +created and the current frequency offset written to it. +When the +.Nm +is started and the file does exist, the +.Nm +frequency is initialized from the file and enters normal mode +immediately. +After that the current frequency offset is written to +the file at hourly intervals. +.Ss "Operating Modes" +The +.Nm +utility can operate in any of several modes, including +symmetric active/passive, client/server broadcast/multicast and +manycast, as described in the +.Qq Association Management +page +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) . +It normally operates continuously while +monitoring for small changes in frequency and trimming the clock +for the ultimate precision. +However, it can operate in a one\-time +mode where the time is set from an external server and frequency is +set from a previously recorded frequency file. +A +broadcast/multicast or manycast client can discover remote servers, +compute server\-client propagation delay correction factors and +configure itself automatically. +This makes it possible to deploy a +fleet of workstations without specifying configuration details +specific to the local environment. +.Pp +By default, +.Nm +runs in continuous mode where each of +possibly several external servers is polled at intervals determined +by an intricate state machine. +The state machine measures the +incidental roundtrip delay jitter and oscillator frequency wander +and determines the best poll interval using a heuristic algorithm. +Ordinarily, and in most operating environments, the state machine +will start with 64s intervals and eventually increase in steps to +1024s. +A small amount of random variation is introduced in order to +avoid bunching at the servers. +In addition, should a server become +unreachable for some time, the poll interval is increased in steps +to 1024s in order to reduce network overhead. +.Pp +In some cases it may not be practical for +.Nm +to run continuously. +A common workaround has been to run the +.Xr ntpdate @NTPDATE_MS@ +or +.Xr sntp @SNTP_MS@ +programs from a +.Xr cron 8 +job at designated +times. +However, these programs do not have the crafted signal +processing, error checking or mitigation algorithms of +.Nm . +The +.Fl q +option is intended for this purpose. +Setting this option will cause +.Nm +to exit just after +setting the clock for the first time. +The procedure for initially +setting the clock is the same as in continuous mode; most +applications will probably want to specify the +.Cm iburst +keyword with the +.Ic server +configuration command. +With this +keyword a volley of messages are exchanged to groom the data and +the clock is set in about 10 s. +If nothing is heard after a +couple of minutes, the daemon times out and exits. +After a suitable +period of mourning, the +.Xr ntpdate @NTPDATE_MS@ +program will be +retired. +.Pp +When kernel support is available to discipline the clock +frequency, which is the case for stock Solaris, Tru64, Linux and +.Fx , +a useful feature is available to discipline the clock +frequency. +First, +.Nm +is run in continuous mode with +selected servers in order to measure and record the intrinsic clock +frequency offset in the frequency file. +It may take some hours for +the frequency and offset to settle down. +Then the +.Nm +is +stopped and run in one\-time mode as required. +At each startup, the +frequency is read from the file and initializes the kernel +frequency. +.Ss "Poll Interval Control" +This version of NTP includes an intricate state machine to +reduce the network load while maintaining a quality of +synchronization consistent with the observed jitter and wander. +There are a number of ways to tailor the operation in order enhance +accuracy by reducing the interval or to reduce network overhead by +increasing it. +However, the user is advised to carefully consider +the consequences of changing the poll adjustment range from the +default minimum of 64 s to the default maximum of 1,024 s. +The +default minimum can be changed with the +.Ic tinker +.Cm minpoll +command to a value not less than 16 s. +This value is used for all +configured associations, unless overridden by the +.Cm minpoll +option on the configuration command. +Note that most device drivers +will not operate properly if the poll interval is less than 64 s +and that the broadcast server and manycast client associations will +also use the default, unless overridden. +.Pp +In some cases involving dial up or toll services, it may be +useful to increase the minimum interval to a few tens of minutes +and maximum interval to a day or so. +Under normal operation +conditions, once the clock discipline loop has stabilized the +interval will be increased in steps from the minimum to the +maximum. +However, this assumes the intrinsic clock frequency error +is small enough for the discipline loop correct it. +The capture +range of the loop is 500 PPM at an interval of 64s decreasing by a +factor of two for each doubling of interval. +At a minimum of 1,024 +s, for example, the capture range is only 31 PPM. +If the intrinsic +error is greater than this, the drift file +.Pa ntp.drift +will +have to be specially tailored to reduce the residual error below +this limit. +Once this is done, the drift file is automatically +updated once per hour and is available to initialize the frequency +on subsequent daemon restarts. +.Ss "The huff\-n'\-puff Filter" +In scenarios where a considerable amount of data are to be +downloaded or uploaded over telephone modems, timekeeping quality +can be seriously degraded. +This occurs because the differential +delays on the two directions of transmission can be quite large. +In +many cases the apparent time errors are so large as to exceed the +step threshold and a step correction can occur during and after the +data transfer is in progress. +.Pp +The huff\-n'\-puff filter is designed to correct the apparent time +offset in these cases. +It depends on knowledge of the propagation +delay when no other traffic is present. +In common scenarios this +occurs during other than work hours. +The filter maintains a shift +register that remembers the minimum delay over the most recent +interval measured usually in hours. +Under conditions of severe +delay, the filter corrects the apparent offset using the sign of +the offset and the difference between the apparent delay and +minimum delay. +The name of the filter reflects the negative (huff) +and positive (puff) correction, which depends on the sign of the +offset. +.Pp +The filter is activated by the +.Ic tinker +command and +.Cm huffpuff +keyword, as described in +.Xr ntp.conf 5 . +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh FILES +.Bl -tag -width /etc/ntp.drift -compact +.It Pa /etc/ntp.conf +the default name of the configuration file +.It Pa /etc/ntp.drift +the default name of the drift file +.It Pa /etc/ntp.keys +the default name of the key file +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntp.conf 5 , +.Xr ntpdate @NTPDATE_MS@ , +.Xr ntpdc @NTPDC_MS@ , +.Xr ntpq @NTPQ_MS@ , +.Xr sntp @SNTP_MS@ +.Pp +In addition to the manual pages provided, +comprehensive documentation is available on the world wide web +at +.Li http://www.ntp.org/ . +A snapshot of this documentation is available in HTML format in +.Pa /usr/share/doc/ntp . +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 1) +.%O RFC1059 +.Re +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 2) +.%O RFC1119 +.Re +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 3) +.%O RFC1305 +.Re +.Rs +.%A David L. Mills +.%A J. Martin, Ed. +.%A J. Burbank +.%A W. Kasch +.%T Network Time Protocol Version 4: Protocol and Algorithms Specification +.%O RFC5905 +.Re +.Rs +.%A David L. Mills +.%A B. Haberman, Ed. +.%T Network Time Protocol Version 4: Autokey Specification +.%O RFC5906 +.Re +.Rs +.%A H. Gerstung +.%A C. Elliott +.%A B. Haberman, Ed. +.%T Definitions of Managed Objects for Network Time Protocol Version 4: (NTPv4) +.%O RFC5907 +.Re +.Rs +.%A R. Gayraud +.%A B. Lourdelet +.%T Network Time Protocol (NTP) Server Option for DHCPv6 +.%O RFC5908 +.Re +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh BUGS +The +.Nm +utility has gotten rather fat. +While not huge, it has gotten +larger than might be desirable for an elevated\-priority +.Nm +running on a workstation, particularly since many of +the fancy features which consume the space were designed more with +a busy primary server, rather than a high stratum workstation in +mind. +.Pp +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +Portions of this document came from FreeBSD. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntpd\fP +option definitions. diff --git a/contrib/ntp/ntpd/ntpd.texi b/contrib/ntp/ntpd/ntpd.texi new file mode 100644 index 000000000..0ac091b47 --- /dev/null +++ b/contrib/ntp/ntpd/ntpd.texi @@ -0,0 +1,113 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntpd.info +@settitle ntpd: Network Time Protocol (NTP) Daemon User's Manual +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of the NTP Project's ntpd, a program for +controlling ntpd. +@end ifinfo + +@direntry +* ntpd: (ntpd). NTP Daemon program +@end direntry + +@titlepage +@title ntpd: Network Time Protocol (NTP) Daemon User's Manual +@subtitle ntpd, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, ntpd Description, (dir), (dir) +@top ntpd: Network Time Protocol (NTP) Daemon User Manual + +The @code{ntpd} program is an operating system daemon that synchronizes the +system clock to remote NTP time servers or local reference clocks. +It is a complete implementation of NTP version 4 defined by RFC-5905, but +also retains compatible with version 3 defined by RFC-1305 and versions +1 and 2, defined by RFC-1059 and RFC-1119, respectively. +The program can operate in any of several modes, including client/server, +symmetric and broadcast modes, and with both symmetric-key and public-key +cryptography. + +This document applies to version @value{VERSION} of @code{ntpd}. + +@shortcontents + +@menu +* ntpd Description:: Description +* ntpd Invocation:: Invoking ntpd +* Usage:: Usage +@end menu + +@node ntpd Description +@comment node-name, next, previous, up +@section Description + +The @code{ntpd} program ordinarily requires +a configuration file described at @ref{ntp.conf}. +This configuration file contains configuration commands described on +the pages listed above. +However a client can discover remote servers and configure them +automatically. +This makes it possible to deploy a fleet of workstations without +specifying configuration details specific to the local environment. + +The @code{ntpd} program normally operates continuously while adjusting the +system time and frequency, but in some cases this might not be +practical. +With the @code{-q} option @code{ntpd} operates as in continuous mode, but +exits just after setting the clock for the first time. +Most applications will probably want to specify the @code{iburst} +option with the @code{server} command. +With this option an initial volley of messages is exchanged to +groom the data and set the clock in about ten seconds' time. +If nothing is heard after a few minutes' time, +the daemon times out and exits without setting the clock. + +@include invoke-ntpd.texi + +@node Usage +@comment node-name, next, previous, up +@section Usage + +@multitable @columnfractions .23 .23 .05 .15 +@headitem What @tab Default @tab Flag @tab Option +@item configuration file +@tab @code{/etc/ntp.conf} +@tab @code{-c} +@tab @code{conffile} +@item frequency file +@tab none +@tab @code{-f} +@tab @code{driftfile} +@item leapseconds file +@tab none +@tab +@tab @code{leapfile} +@item process ID file +@tab none +@tab @code{-p} +@tab @code{pidfile} +@item log file +@tab system log +@tab @code{-l} +@tab @code{logfile} +@item include file +@tab none +@tab none +@tab @code{includefile} +@item statistics path +@tab @code{/var/NTP} +@tab @code{-s} +@tab @code{statsdir} +@item keys path +@tab @code{/usr/local/etc} +@tab @code{-k} +@tab @code{keysdir} diff --git a/contrib/ntp/ntpd/ntpdbase-opts.def b/contrib/ntp/ntpd/ntpdbase-opts.def index 852af4568..66b953528 100644 --- a/contrib/ntp/ntpd/ntpdbase-opts.def +++ b/contrib/ntp/ntpd/ntpdbase-opts.def @@ -1,11 +1,17 @@ #include autogen-version.def -test-main; +include = <<- _EOF_ + #ifdef __windows + extern int atoi(const char *); + #else + # include + #endif + _EOF_; flag = { name = ipv4; value = 4; - equivalence = ipv4; + flags-cant = ipv6; descrip = "Force IPv4 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -16,7 +22,7 @@ flag = { flag = { name = ipv6; value = 6; - equivalence = ipv4; + flags-cant = ipv4; descrip = "Force IPv6 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -56,17 +62,6 @@ flag = { _EndOfDoc_; }; -#ifdef SIM -flag = { - name = simbroadcastdelay; - value = B; - arg-type = string; - descrip = "Simulator broadcast delay"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { name = configfile; value = c; @@ -74,22 +69,11 @@ flag = { descrip = "configuration file name"; doc = <<- _EndOfDoc_ The name and path of the configuration file, - /etc/ntp.conf + @file{/etc/ntp.conf} by default. _EndOfDoc_; }; -#ifdef SIM -flag = { - name = phasenoise; - value = C; - arg-type = string; - descrip = "Phase noise level"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - #include debug-opt.def flag = { @@ -99,12 +83,12 @@ flag = { descrip = "frequency drift file name"; doc = <<- _EndOfDoc_ The name and path of the frequency file, - /etc/ntp.drift + @file{/etc/ntp.drift} by default. This is the same operation as the - driftfile driftfile - configuration specification in the - /etc/ntp.conf + @code{driftfile} @kbd{driftfile} + configuration specification in the + @file{/etc/ntp.conf} file. _EndOfDoc_; }; @@ -112,47 +96,62 @@ flag = { flag = { name = panicgate; value = g; + max = NOLIMIT; descrip = "Allow the first adjustment to be Big"; doc = <<- _EndOfDoc_ Normally, - ntpd + @code{ntpd} exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, - ntpd + @code{ntpd} will exit with a message to the system log. This option can be used with the - -q + @code{-q} and - -x + @code{-x} options. See the - tinker + @code{tinker} configuration file directive for other options. _EndOfDoc_; }; -#ifdef SIM flag = { - name = simslew; - value = H; - arg-type = string; - descrip = "Simuator slew"; + name = force_step_once; + value = G; + descrip = "Step any initial offset correction."; doc = <<- _EndOfDoc_ + Normally, + @code{ntpd} + steps the time if the time offset exceeds the step threshold, + which is 128 ms by default, and otherwise slews the time. + This option forces the initial offset correction to be stepped, + so the highest time accuracy can be achieved quickly. + However, this may also cause the time to be stepped back + so this option must not be used if + applications requiring monotonic time are running. + See the @code{tinker} configuration file directive for other options. _EndOfDoc_; }; -#endif flag = { + ifdef = HAVE_DROPROOT; name = jaildir; value = i; arg-type = string; descrip = "Jail directory"; + omitted-usage = "built without --enable-clockctl or --enable-linuxcaps or --enable-solarisprivs"; doc = <<- _EndOfDoc_ Chroot the server to the directory - jaildir + @kbd{jaildir} . - This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. + This option also implies that the server attempts to drop root privileges at startup. You may need to also specify a - -u + @code{-u} option. + This option is only available if the OS supports adjusting the clock + without full root privileges. + This option is supported under NetBSD (configure with + @code{--enable-clockctl}) or Linux (configure with + @code{--enable-linuxcaps}) or Solaris (configure with @code{--enable-solarisprivs}). _EndOfDoc_; }; @@ -160,11 +159,16 @@ flag = { name = interface; value = I; arg-type = string; - descrip = "Listen on interface"; + descrip = "Listen on an interface name or address"; max = NOLIMIT; arg-name = iface; stack-arg; doc = <<- _EndOfDoc_ + Open the network address given, or all the addresses associated with the + given interface name. This option may appear multiple times. This option + also implies not opening other addresses, except wildcard and localhost. + This option is deprecated. Please consider using the configuration file + @code{interface} command, which is more versatile. _EndOfDoc_; }; @@ -175,10 +179,10 @@ flag = { descrip = "path to symmetric keys"; doc = <<- _EndOfDoc_ Specify the name and path of the symmetric key file. - /etc/ntp.keys + @file{/etc/ntp.keys} is the default. This is the same operation as the - keys keyfile + @code{keys} @kbd{keyfile} configuration file directive. _EndOfDoc_; }; @@ -192,7 +196,7 @@ flag = { Specify the name and path of the log file. The default is the system log file. This is the same operation as the - logfile logfile + @code{logfile} @kbd{logfile} configuration file directive. _EndOfDoc_; }; @@ -200,9 +204,12 @@ flag = { flag = { name = novirtualips; value = L; - descrip = "Do not listen to virtual IPs"; + descrip = "Do not listen to virtual interfaces"; doc = <<- _EndOfDoc_ - Do not listen to virtual IPs. The default is to listen. + Do not listen to virtual interfaces, defined as those with + names containing a colon. This option is deprecated. Please + consider using the configuration file @code{interface} command, which + is more versatile. _EndOfDoc_; }; @@ -212,13 +219,16 @@ flag = { value = M; descrip = "Modify Multimedia Timer (Windows only)"; doc = <<- _EndOfDoc_ - Set the Windows Multimedia Timer to highest resolution. + Set the Windows Multimedia Timer to highest resolution. This + ensures the resolution does not change while ntpd is running, + avoiding timekeeping glitches associated with changes. _EndOfDoc_; }; flag = { name = nofork; value = n; + flags-cant = wait-sync; descrip = "Do not fork"; doc = <<- _EndOfDoc_ _EndOfDoc_; @@ -230,22 +240,11 @@ flag = { descrip = "Run at high priority"; doc = <<- _EndOfDoc_ To the extent permitted by the operating system, run - ntpd + @code{ntpd} at the highest priority. _EndOfDoc_; }; -#ifdef SIM -flag = { - name = servertime; - value = O; - arg-type = string; - descrip = "Server time"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { name = pidfile; value = p; @@ -253,10 +252,10 @@ flag = { descrip = "path to the PID file"; doc = <<- _EndOfDoc_ Specify the name and path of the file used to record - ntpd's + @code{ntpd}'s process ID. This is the same operation as the - pidfile pidfile + @code{pidfile} @kbd{pidfile} configuration file directive. _EndOfDoc_; }; @@ -268,9 +267,9 @@ flag = { descrip = "Process priority"; doc = <<- _EndOfDoc_ To the extent permitted by the operating system, run - ntpd + @code{ntpd} at the specified - sched_setscheduler(SCHED_FIFO) + @code{sched_setscheduler(SCHED_FIFO)} priority. _EndOfDoc_; }; @@ -278,16 +277,19 @@ flag = { flag = { name = quit; value = q; + flags-cant = saveconfigquit; + flags-cant = wait-sync; descrip = "Set the time and quit"; doc = <<- _EndOfDoc_ - ntpd - will exit just after the first time the clock is set. This behavior mimics that of the - ntpdate - program, which is to be retired. + @code{ntpd} + will not daemonize and will exit after the clock is first + synchronized. This behavior mimics that of the + @code{ntpdate} + program, which will soon be replaced with a shell script. The - -g + @code{-g} and - -x + @code{-x} options can be used with this option. Note: The kernel time discipline is disabled with this option. _EndOfDoc_; @@ -304,15 +306,16 @@ flag = { }; flag = { - name = updateinterval; - value = U; - arg-type = number; - descrip = "interval in seconds between scans for new or dropped interfaces"; + ifdef = SAVECONFIG; + name = saveconfigquit; + arg-type = string; + flags-cant = quit; + flags-cant = wait-sync; + descrip = "Save parsed configuration and quit"; doc = <<- _EndOfDoc_ - Give the time in seconds between two scans for new or dropped interfaces. - For systems with routing socket support the scans will be performed shortly after the interface change - has been detected by the system. - Use 0 to disable scanning. + Cause @code{ntpd} to parse its startup configuration file and save an + equivalent to the given filename and exit. This option was + designed for automated testing. _EndOfDoc_; }; @@ -324,22 +327,11 @@ flag = { doc = <<- _EndOfDoc_ Specify the directory path for files created by the statistics facility. This is the same operation as the - statsdir statsdir + @code{statsdir} @kbd{statsdir} configuration file directive. _EndOfDoc_; }; -#ifdef SIM -flag = { - name = endsimtime; - value = S; - arg-type = string; - descrip = "Simulation end time"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - flag = { name = trustedkey; value = t; @@ -349,51 +341,43 @@ flag = { arg-name = tkey; stack-arg; doc = <<- _EndOfDoc_ - Add a key number to the trusted key list. + Add the specified key number to the trusted key list. _EndOfDoc_; }; -#ifdef SIM flag = { - name = freqerr; - value = T; - arg-type = string; - descrip = "Simulation frequency error"; - doc = <<- _EndOfDoc_ - _EndOfDoc_; -}; -#endif - -#ifdef SIM -flag = { - name = walknoise; - value = W; + ifdef = HAVE_DROPROOT; + name = user; + value = u; arg-type = string; - descrip = "Simulation random walk noise"; + descrip = "Run as userid (or userid:groupid)"; + omitted-usage = "built without --enable-clockctl or --enable-linuxcaps or --enable-solarisprivs"; doc = <<- _EndOfDoc_ + Specify a user, and optionally a group, to switch to. + This option is only available if the OS supports adjusting the clock + without full root privileges. + This option is supported under NetBSD (configure with + @code{--enable-clockctl}) or Linux (configure with + @code{--enable-linuxcaps}) or Solaris (configure with @code{--enable-solarisprivs}). _EndOfDoc_; }; -#endif flag = { - name = user; - value = u; - arg-type = string; - descrip = "Run as userid (or userid:groupid)"; + name = updateinterval; + value = U; + arg-type = number; + descrip = "interval in seconds between scans for new or dropped interfaces"; doc = <<- _EndOfDoc_ - Specify a user, and optionally a group, to switch to. - This option is only available if the OS supports to run the server without full root privileges. - Currently, this option is supported under NetBSD (configure with - --enable-clockctl - ) and Linux (configure with - --enable-linuxcaps - ). + Give the time in seconds between two scans for new or dropped interfaces. + For systems with routing socket support the scans will be performed shortly after the interface change + has been detected by the system. + Use 0 to disable scanning. 60 seconds is the minimum time between scans. _EndOfDoc_; }; flag = { name = var; - value = v; +/* value = v; Bug 817 */ arg-type = string; descrip = "make ARG an ntp variable (RW)"; max = NOLIMIT; @@ -405,7 +389,7 @@ flag = { flag = { name = dvar; - value = V; +/* value = V; Bug 817 */ arg-type = string; descrip = "make ARG an ntp variable (RW|DEF)"; max = NOLIMIT; @@ -415,6 +399,31 @@ flag = { _EndOfDoc_; }; +flag = { + ifdef = HAVE_WORKING_FORK; + name = wait-sync; + value = w; + arg-type = number; + flags-cant = nofork; + flags-cant = quit; + flags-cant = saveconfigquit; + descrip = "Seconds to wait for first clock sync"; + doc = <<- _EndOfDoc_ + If greater than zero, alters @code{ntpd}'s behavior when forking to + daemonize. Instead of exiting with status 0 immediately after + the fork, the parent waits up to the specified number of + seconds for the child to first synchronize the clock. The exit + status is zero (success) if the clock was synchronized, + otherwise it is @code{ETIMEDOUT}. + This provides the option for a script starting @code{ntpd} to easily + wait for the first set of the clock before proceeding. + _EndOfDoc_; +/* +** XXX: is it "first set" or is it more? If it's only "first set" then +** that's not the same as SYNC. +*/ +}; + flag = { name = slew; value = x; @@ -425,35 +434,48 @@ flag = { Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. Thus, an adjustment as much as 600 s will take almost 14 days to complete. This option can be used with the - -g + @code{-g} and - -q + @code{-q} options. See the - tinker + @code{tinker} configuration file directive for other options. Note: The kernel time discipline is disabled with this option. _EndOfDoc_; }; -#ifdef SIM flag = { - name = ndelay; - value = Y; - arg-type = string; - descrip = "Simulation network delay"; + ifdef = SYS_WINNT; + name = usepcc; + descrip = "Use CPU cycle counter (Windows only)"; doc = <<- _EndOfDoc_ + Attempt to substitute the CPU counter for @code{QueryPerformanceCounter}. + The CPU counter and @code{QueryPerformanceCounter} are compared, and if + they have the same frequency, the CPU counter (RDTSC on x86) is + used directly, saving the overhead of a system call. _EndOfDoc_; }; -#endif -#ifdef SIM flag = { - name = pdelay; - value = Z; + ifdef = SYS_WINNT; + name = pccfreq; arg-type = string; - descrip = "Simulation processing delay"; + descrip = "Force CPU cycle counter use (Windows only)"; + doc = <<- _EndOfDoc_ + Force substitution the CPU counter for @code{QueryPerformanceCounter}. + The CPU counter (RDTSC on x86) is used unconditionally with the + given frequency (in Hz). + _EndOfDoc_; +}; + +flag = { + ifdef = HAVE_DNSREGISTRATION; + name = mdns; + value = m; + descrip = "Register with mDNS as a NTP server"; doc = <<- _EndOfDoc_ + Registers as an NTP server with the local mDNS server which allows + the server to be discovered via mDNS client lookup. _EndOfDoc_; }; -#endif diff --git a/contrib/ntp/ntpd/ntpdsim-opts.c b/contrib/ntp/ntpd/ntpdsim-opts.c deleted file mode 100644 index d9ef1b22e..000000000 --- a/contrib/ntp/ntpd/ntpdsim-opts.c +++ /dev/null @@ -1,1262 +0,0 @@ -/* - * EDIT THIS FILE WITH CAUTION (ntpdsim-opts.c) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:13 AM EST - * From the definitions ntpdsim-opts.def - * and the template file options - * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This source file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpdsim author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. - * - * This source file is copyrighted and licensed under the following terms: - * - * ntpdsim copyright 1970-2009 David L. Mills and/or others - all rights reserved - * - * see html/copyright.html - */ - - -#include - -#define OPTION_CODE_COMPILE 1 -#include "ntpdsim-opts.h" - -#ifdef __cplusplus -extern "C" { -#endif -tSCC zCopyright[] = - "ntpdsim copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - -/* extracted from ../include/copyright.def near line 8 */ -"see html/copyright.html"; -extern tUsageProc optionUsage; - -/* - * global included definitions - */ -#ifdef __windows - extern int atoi(const char*); -#else -# include -#endif - -#ifndef NULL -# define NULL 0 -#endif -#ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -#endif -#ifndef EXIT_FAILURE -# define EXIT_FAILURE 1 -#endif -/* - * Ipv4 option description: - */ -tSCC zIpv4Text[] = - "Force IPv4 DNS name resolution"; -tSCC zIpv4_NAME[] = "IPV4"; -tSCC zIpv4_Name[] = "ipv4"; -#define IPV4_FLAGS (OPTST_DISABLED) - -/* - * Ipv6 option description: - */ -tSCC zIpv6Text[] = - "Force IPv6 DNS name resolution"; -tSCC zIpv6_NAME[] = "IPV6"; -tSCC zIpv6_Name[] = "ipv6"; -#define IPV6_FLAGS (OPTST_DISABLED) - -/* - * Authreq option description with - * "Must also have options" and "Incompatible options": - */ -tSCC zAuthreqText[] = - "Require crypto authentication"; -tSCC zAuthreq_NAME[] = "AUTHREQ"; -tSCC zAuthreq_Name[] = "authreq"; -static const int - aAuthreqCantList[] = { - INDEX_OPT_AUTHNOREQ, NO_EQUIVALENT }; -#define AUTHREQ_FLAGS (OPTST_DISABLED) - -/* - * Authnoreq option description with - * "Must also have options" and "Incompatible options": - */ -tSCC zAuthnoreqText[] = - "Do not require crypto authentication"; -tSCC zAuthnoreq_NAME[] = "AUTHNOREQ"; -tSCC zAuthnoreq_Name[] = "authnoreq"; -static const int - aAuthnoreqCantList[] = { - INDEX_OPT_AUTHREQ, NO_EQUIVALENT }; -#define AUTHNOREQ_FLAGS (OPTST_DISABLED) - -/* - * Bcastsync option description: - */ -tSCC zBcastsyncText[] = - "Allow us to sync to broadcast servers"; -tSCC zBcastsync_NAME[] = "BCASTSYNC"; -tSCC zBcastsync_Name[] = "bcastsync"; -#define BCASTSYNC_FLAGS (OPTST_DISABLED) - -/* - * Simbroadcastdelay option description: - */ -tSCC zSimbroadcastdelayText[] = - "Simulator broadcast delay"; -tSCC zSimbroadcastdelay_NAME[] = "SIMBROADCASTDELAY"; -tSCC zSimbroadcastdelay_Name[] = "simbroadcastdelay"; -#define SIMBROADCASTDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Configfile option description: - */ -tSCC zConfigfileText[] = - "configuration file name"; -tSCC zConfigfile_NAME[] = "CONFIGFILE"; -tSCC zConfigfile_Name[] = "configfile"; -#define CONFIGFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Phasenoise option description: - */ -tSCC zPhasenoiseText[] = - "Phase noise level"; -tSCC zPhasenoise_NAME[] = "PHASENOISE"; -tSCC zPhasenoise_Name[] = "phasenoise"; -#define PHASENOISE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Debug_Level option description: - */ -#ifdef DEBUG -tSCC zDebug_LevelText[] = - "Increase output debug message level"; -tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; -tSCC zDebug_Level_Name[] = "debug-level"; -#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) - -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Set_Debug_Level option description: - */ -#ifdef DEBUG -tSCC zSet_Debug_LevelText[] = - "Set the output debug message level"; -tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; -tSCC zSet_Debug_Level_Name[] = "set-debug-level"; -#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Driftfile option description: - */ -tSCC zDriftfileText[] = - "frequency drift file name"; -tSCC zDriftfile_NAME[] = "DRIFTFILE"; -tSCC zDriftfile_Name[] = "driftfile"; -#define DRIFTFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Panicgate option description: - */ -tSCC zPanicgateText[] = - "Allow the first adjustment to be Big"; -tSCC zPanicgate_NAME[] = "PANICGATE"; -tSCC zPanicgate_Name[] = "panicgate"; -#define PANICGATE_FLAGS (OPTST_DISABLED) - -/* - * Simslew option description: - */ -tSCC zSimslewText[] = - "Simuator slew"; -tSCC zSimslew_NAME[] = "SIMSLEW"; -tSCC zSimslew_Name[] = "simslew"; -#define SIMSLEW_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Jaildir option description: - */ -tSCC zJaildirText[] = - "Jail directory"; -tSCC zJaildir_NAME[] = "JAILDIR"; -tSCC zJaildir_Name[] = "jaildir"; -#define JAILDIR_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Interface option description: - */ -tSCC zInterfaceText[] = - "Listen on interface"; -tSCC zInterface_NAME[] = "INTERFACE"; -tSCC zInterface_Name[] = "interface"; -#define INTERFACE_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Keyfile option description: - */ -tSCC zKeyfileText[] = - "path to symmetric keys"; -tSCC zKeyfile_NAME[] = "KEYFILE"; -tSCC zKeyfile_Name[] = "keyfile"; -#define KEYFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Logfile option description: - */ -tSCC zLogfileText[] = - "path to the log file"; -tSCC zLogfile_NAME[] = "LOGFILE"; -tSCC zLogfile_Name[] = "logfile"; -#define LOGFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Novirtualips option description: - */ -tSCC zNovirtualipsText[] = - "Do not listen to virtual IPs"; -tSCC zNovirtualips_NAME[] = "NOVIRTUALIPS"; -tSCC zNovirtualips_Name[] = "novirtualips"; -#define NOVIRTUALIPS_FLAGS (OPTST_DISABLED) - -/* - * Modifymmtimer option description: - */ -#ifdef SYS_WINNT -tSCC zModifymmtimerText[] = - "Modify Multimedia Timer (Windows only)"; -tSCC zModifymmtimer_NAME[] = "MODIFYMMTIMER"; -tSCC zModifymmtimer_Name[] = "modifymmtimer"; -#define MODIFYMMTIMER_FLAGS (OPTST_DISABLED) - -#else /* disable Modifymmtimer */ -#define VALUE_OPT_MODIFYMMTIMER NO_EQUIVALENT -#define MODIFYMMTIMER_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zModifymmtimerText NULL -#define zModifymmtimer_NAME NULL -#define zModifymmtimer_Name NULL -#endif /* SYS_WINNT */ - -/* - * Nofork option description: - */ -tSCC zNoforkText[] = - "Do not fork"; -tSCC zNofork_NAME[] = "NOFORK"; -tSCC zNofork_Name[] = "nofork"; -#define NOFORK_FLAGS (OPTST_DISABLED) - -/* - * Nice option description: - */ -tSCC zNiceText[] = - "Run at high priority"; -tSCC zNice_NAME[] = "NICE"; -tSCC zNice_Name[] = "nice"; -#define NICE_FLAGS (OPTST_DISABLED) - -/* - * Servertime option description: - */ -tSCC zServertimeText[] = - "Server time"; -tSCC zServertime_NAME[] = "SERVERTIME"; -tSCC zServertime_Name[] = "servertime"; -#define SERVERTIME_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Pidfile option description: - */ -tSCC zPidfileText[] = - "path to the PID file"; -tSCC zPidfile_NAME[] = "PIDFILE"; -tSCC zPidfile_Name[] = "pidfile"; -#define PIDFILE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Priority option description: - */ -tSCC zPriorityText[] = - "Process priority"; -tSCC zPriority_NAME[] = "PRIORITY"; -tSCC zPriority_Name[] = "priority"; -#define PRIORITY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) - -/* - * Quit option description: - */ -tSCC zQuitText[] = - "Set the time and quit"; -tSCC zQuit_NAME[] = "QUIT"; -tSCC zQuit_Name[] = "quit"; -#define QUIT_FLAGS (OPTST_DISABLED) - -/* - * Propagationdelay option description: - */ -tSCC zPropagationdelayText[] = - "Broadcast/propagation delay"; -tSCC zPropagationdelay_NAME[] = "PROPAGATIONDELAY"; -tSCC zPropagationdelay_Name[] = "propagationdelay"; -#define PROPAGATIONDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Updateinterval option description: - */ -tSCC zUpdateintervalText[] = - "interval in seconds between scans for new or dropped interfaces"; -tSCC zUpdateinterval_NAME[] = "UPDATEINTERVAL"; -tSCC zUpdateinterval_Name[] = "updateinterval"; -#define UPDATEINTERVAL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) - -/* - * Statsdir option description: - */ -tSCC zStatsdirText[] = - "Statistics file location"; -tSCC zStatsdir_NAME[] = "STATSDIR"; -tSCC zStatsdir_Name[] = "statsdir"; -#define STATSDIR_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Endsimtime option description: - */ -tSCC zEndsimtimeText[] = - "Simulation end time"; -tSCC zEndsimtime_NAME[] = "ENDSIMTIME"; -tSCC zEndsimtime_Name[] = "endsimtime"; -#define ENDSIMTIME_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Trustedkey option description: - */ -tSCC zTrustedkeyText[] = - "Trusted key number"; -tSCC zTrustedkey_NAME[] = "TRUSTEDKEY"; -tSCC zTrustedkey_Name[] = "trustedkey"; -#define TRUSTEDKEY_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Freqerr option description: - */ -tSCC zFreqerrText[] = - "Simulation frequency error"; -tSCC zFreqerr_NAME[] = "FREQERR"; -tSCC zFreqerr_Name[] = "freqerr"; -#define FREQERR_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Walknoise option description: - */ -tSCC zWalknoiseText[] = - "Simulation random walk noise"; -tSCC zWalknoise_NAME[] = "WALKNOISE"; -tSCC zWalknoise_Name[] = "walknoise"; -#define WALKNOISE_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * User option description: - */ -tSCC zUserText[] = - "Run as userid (or userid:groupid)"; -tSCC zUser_NAME[] = "USER"; -tSCC zUser_Name[] = "user"; -#define USER_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Var option description: - */ -tSCC zVarText[] = - "make ARG an ntp variable (RW)"; -tSCC zVar_NAME[] = "VAR"; -tSCC zVar_Name[] = "var"; -#define VAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Dvar option description: - */ -tSCC zDvarText[] = - "make ARG an ntp variable (RW|DEF)"; -tSCC zDvar_NAME[] = "DVAR"; -tSCC zDvar_Name[] = "dvar"; -#define DVAR_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Slew option description: - */ -tSCC zSlewText[] = - "Slew up to 600 seconds"; -tSCC zSlew_NAME[] = "SLEW"; -tSCC zSlew_Name[] = "slew"; -#define SLEW_FLAGS (OPTST_DISABLED) - -/* - * Ndelay option description: - */ -tSCC zNdelayText[] = - "Simulation network delay"; -tSCC zNdelay_NAME[] = "NDELAY"; -tSCC zNdelay_Name[] = "ndelay"; -#define NDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Pdelay option description: - */ -tSCC zPdelayText[] = - "Simulation processing delay"; -tSCC zPdelay_NAME[] = "PDELAY"; -tSCC zPdelay_Name[] = "pdelay"; -#define PDELAY_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Help/More_Help/Version option descriptions: - */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; - -/* - * Save/Load_Opts option description: - */ -tSCC zSave_OptsText[] = "Save the option state to a config file"; -tSCC zSave_Opts_Name[] = "save-opts"; - -tSCC zLoad_OptsText[] = "Load options from a config file"; -tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; - -tSCC zNotLoad_Opts_Name[] = "no-load-opts"; -tSCC zNotLoad_Opts_Pfx[] = "no"; -#define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) -/* - * Declare option callback procedures - */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ -#if defined(TEST_NTPDSIM_OPTS) -/* - * Under test, omit argument processing, or call optionStackArg, - * if multiple copies are allowed. - */ -extern tOptProc - optionNumericVal, optionPagedUsage, optionStackArg, - optionVersionStderr; -static tOptProc - doUsageOpt; - -/* - * #define map the "normal" callout procs to the test ones... - */ -#define SET_DEBUG_LEVEL_OPT_PROC optionStackArg - - -#else /* NOT defined TEST_NTPDSIM_OPTS */ -/* - * When not under test, there are different procs to use - */ -extern tOptProc - optionNumericVal, optionPagedUsage, optionPrintVersion, optionStackArg; -static tOptProc - doUsageOpt; - -/* - * #define map the "normal" callout procs - */ -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level - -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level -#endif /* defined(TEST_NTPDSIM_OPTS) */ -#ifdef TEST_NTPDSIM_OPTS -# define DOVERPROC optionVersionStderr -#else -# define DOVERPROC optionPrintVersion -#endif /* TEST_NTPDSIM_OPTS */ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpdsim Option Descriptions. - */ -static tOptDesc optDesc[ OPTION_CT ] = { - { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ IPV4_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ IPV6_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 2, VALUE_OPT_AUTHREQ, - /* equiv idx, value */ 2, VALUE_OPT_AUTHREQ, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ AUTHREQ_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aAuthreqCantList, - /* option proc */ NULL, - /* desc, NAME, name */ zAuthreqText, zAuthreq_NAME, zAuthreq_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 3, VALUE_OPT_AUTHNOREQ, - /* equiv idx, value */ 3, VALUE_OPT_AUTHNOREQ, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ AUTHNOREQ_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aAuthnoreqCantList, - /* option proc */ NULL, - /* desc, NAME, name */ zAuthnoreqText, zAuthnoreq_NAME, zAuthnoreq_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 4, VALUE_OPT_BCASTSYNC, - /* equiv idx, value */ 4, VALUE_OPT_BCASTSYNC, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ BCASTSYNC_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zBcastsyncText, zBcastsync_NAME, zBcastsync_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 5, VALUE_OPT_SIMBROADCASTDELAY, - /* equiv idx, value */ 5, VALUE_OPT_SIMBROADCASTDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SIMBROADCASTDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSimbroadcastdelayText, zSimbroadcastdelay_NAME, zSimbroadcastdelay_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 6, VALUE_OPT_CONFIGFILE, - /* equiv idx, value */ 6, VALUE_OPT_CONFIGFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ CONFIGFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zConfigfileText, zConfigfile_NAME, zConfigfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 7, VALUE_OPT_PHASENOISE, - /* equiv idx, value */ 7, VALUE_OPT_PHASENOISE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PHASENOISE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPhasenoiseText, zPhasenoise_NAME, zPhasenoise_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 8, VALUE_OPT_DEBUG_LEVEL, - /* equiv idx, value */ 8, VALUE_OPT_DEBUG_LEVEL, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zDebug_LevelText, zDebug_Level_NAME, zDebug_Level_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 9, VALUE_OPT_SET_DEBUG_LEVEL, - /* equiv idx, value */ 9, VALUE_OPT_SET_DEBUG_LEVEL, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ SET_DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ SET_DEBUG_LEVEL_OPT_PROC, - /* desc, NAME, name */ zSet_Debug_LevelText, zSet_Debug_Level_NAME, zSet_Debug_Level_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 10, VALUE_OPT_DRIFTFILE, - /* equiv idx, value */ 10, VALUE_OPT_DRIFTFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ DRIFTFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zDriftfileText, zDriftfile_NAME, zDriftfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 11, VALUE_OPT_PANICGATE, - /* equiv idx, value */ 11, VALUE_OPT_PANICGATE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PANICGATE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPanicgateText, zPanicgate_NAME, zPanicgate_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 12, VALUE_OPT_SIMSLEW, - /* equiv idx, value */ 12, VALUE_OPT_SIMSLEW, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SIMSLEW_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSimslewText, zSimslew_NAME, zSimslew_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 13, VALUE_OPT_JAILDIR, - /* equiv idx, value */ 13, VALUE_OPT_JAILDIR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ JAILDIR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zJaildirText, zJaildir_NAME, zJaildir_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 14, VALUE_OPT_INTERFACE, - /* equiv idx, value */ 14, VALUE_OPT_INTERFACE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ INTERFACE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zInterfaceText, zInterface_NAME, zInterface_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 15, VALUE_OPT_KEYFILE, - /* equiv idx, value */ 15, VALUE_OPT_KEYFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ KEYFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zKeyfileText, zKeyfile_NAME, zKeyfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 16, VALUE_OPT_LOGFILE, - /* equiv idx, value */ 16, VALUE_OPT_LOGFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ LOGFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zLogfileText, zLogfile_NAME, zLogfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 17, VALUE_OPT_NOVIRTUALIPS, - /* equiv idx, value */ 17, VALUE_OPT_NOVIRTUALIPS, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NOVIRTUALIPS_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNovirtualipsText, zNovirtualips_NAME, zNovirtualips_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 18, VALUE_OPT_MODIFYMMTIMER, - /* equiv idx, value */ 18, VALUE_OPT_MODIFYMMTIMER, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ MODIFYMMTIMER_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zModifymmtimerText, zModifymmtimer_NAME, zModifymmtimer_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 19, VALUE_OPT_NOFORK, - /* equiv idx, value */ 19, VALUE_OPT_NOFORK, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NOFORK_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNoforkText, zNofork_NAME, zNofork_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 20, VALUE_OPT_NICE, - /* equiv idx, value */ 20, VALUE_OPT_NICE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NICE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNiceText, zNice_NAME, zNice_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 21, VALUE_OPT_SERVERTIME, - /* equiv idx, value */ 21, VALUE_OPT_SERVERTIME, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SERVERTIME_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zServertimeText, zServertime_NAME, zServertime_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 22, VALUE_OPT_PIDFILE, - /* equiv idx, value */ 22, VALUE_OPT_PIDFILE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PIDFILE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPidfileText, zPidfile_NAME, zPidfile_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 23, VALUE_OPT_PRIORITY, - /* equiv idx, value */ 23, VALUE_OPT_PRIORITY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PRIORITY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionNumericVal, - /* desc, NAME, name */ zPriorityText, zPriority_NAME, zPriority_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 24, VALUE_OPT_QUIT, - /* equiv idx, value */ 24, VALUE_OPT_QUIT, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ QUIT_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zQuitText, zQuit_NAME, zQuit_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 25, VALUE_OPT_PROPAGATIONDELAY, - /* equiv idx, value */ 25, VALUE_OPT_PROPAGATIONDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PROPAGATIONDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPropagationdelayText, zPropagationdelay_NAME, zPropagationdelay_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 26, VALUE_OPT_UPDATEINTERVAL, - /* equiv idx, value */ 26, VALUE_OPT_UPDATEINTERVAL, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ UPDATEINTERVAL_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionNumericVal, - /* desc, NAME, name */ zUpdateintervalText, zUpdateinterval_NAME, zUpdateinterval_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 27, VALUE_OPT_STATSDIR, - /* equiv idx, value */ 27, VALUE_OPT_STATSDIR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ STATSDIR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zStatsdirText, zStatsdir_NAME, zStatsdir_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 28, VALUE_OPT_ENDSIMTIME, - /* equiv idx, value */ 28, VALUE_OPT_ENDSIMTIME, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ ENDSIMTIME_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zEndsimtimeText, zEndsimtime_NAME, zEndsimtime_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 29, VALUE_OPT_TRUSTEDKEY, - /* equiv idx, value */ 29, VALUE_OPT_TRUSTEDKEY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ TRUSTEDKEY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zTrustedkeyText, zTrustedkey_NAME, zTrustedkey_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 30, VALUE_OPT_FREQERR, - /* equiv idx, value */ 30, VALUE_OPT_FREQERR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ FREQERR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zFreqerrText, zFreqerr_NAME, zFreqerr_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 31, VALUE_OPT_WALKNOISE, - /* equiv idx, value */ 31, VALUE_OPT_WALKNOISE, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ WALKNOISE_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zWalknoiseText, zWalknoise_NAME, zWalknoise_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 32, VALUE_OPT_USER, - /* equiv idx, value */ 32, VALUE_OPT_USER, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ USER_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zUserText, zUser_NAME, zUser_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 33, VALUE_OPT_VAR, - /* equiv idx, value */ 33, VALUE_OPT_VAR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ VAR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zVarText, zVar_NAME, zVar_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 34, VALUE_OPT_DVAR, - /* equiv idx, value */ 34, VALUE_OPT_DVAR, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ DVAR_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zDvarText, zDvar_NAME, zDvar_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 35, VALUE_OPT_SLEW, - /* equiv idx, value */ 35, VALUE_OPT_SLEW, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SLEW_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSlewText, zSlew_NAME, zSlew_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 36, VALUE_OPT_NDELAY, - /* equiv idx, value */ 36, VALUE_OPT_NDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zNdelayText, zNdelay_NAME, zNdelay_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ 37, VALUE_OPT_PDELAY, - /* equiv idx, value */ 37, VALUE_OPT_PDELAY, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PDELAY_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zPdelayText, zPdelay_NAME, zPdelay_Name, - /* disablement strs */ NULL, NULL }, - -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ DOVERPROC, - /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, - /* disablement strs */ NULL, NULL }, - -#undef VERSION_OPT_FLAGS - - - { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ doUsageOpt, - /* desc, NAME, name */ zHelpText, NULL, zHelp_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionPagedUsage, - /* desc, NAME, name */ zMore_HelpText, NULL, zMore_Help_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ INDEX_OPT_SAVE_OPTS, VALUE_OPT_SAVE_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) - | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zSave_OptsText, NULL, zSave_Opts_Name, - /* disablement strs */ NULL, NULL }, - - { /* entry idx, value */ INDEX_OPT_LOAD_OPTS, VALUE_OPT_LOAD_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, - /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ - | OPTST_DISABLE_IMM, 0, - /* last opt argumnt */ { NULL }, - /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ optionLoadOpt, - /* desc, NAME, name */ zLoad_OptsText, zLoad_Opts_NAME, zLoad_Opts_Name, - /* disablement strs */ zNotLoad_Opts_Name, zNotLoad_Opts_Pfx } -}; - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpdsim Option Environment - */ -tSCC zPROGNAME[] = "NTPDSIM"; -tSCC zUsageTitle[] = -"ntpdsim - NTP daemon simulation program - Ver. 4.2.4p8\n\ -USAGE: %s [ - [] | --[{=| }] ]...\n"; -tSCC zRcName[] = ".ntprc"; -tSCC* apzHomeList[] = { - "$HOME", - ".", - NULL }; - -tSCC zBugsAddr[] = "http://bugs.ntp.org, bugs@ntp.org"; -#define zExplain NULL -tSCC zDetail[] = "\n\n"; -tSCC zFullVersion[] = NTPDSIM_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ - -#if defined(ENABLE_NLS) -# define OPTPROC_BASE OPTPROC_TRANSLATE - static tOptionXlateProc translate_option_strings; -#else -# define OPTPROC_BASE OPTPROC_NONE -# define translate_option_strings NULL -#endif /* ENABLE_NLS */ - -tOptions ntpdsimOptions = { - OPTIONS_STRUCT_VERSION, - 0, NULL, /* original argc + argv */ - ( OPTPROC_BASE - + OPTPROC_ERRSTOP - + OPTPROC_SHORTOPT - + OPTPROC_LONGOPT - + OPTPROC_NO_REQ_OPT - + OPTPROC_ENVIRON - + OPTPROC_NO_ARGS - + OPTPROC_HAS_IMMED ), - 0, NULL, /* current option index, current option */ - NULL, NULL, zPROGNAME, - zRcName, zCopyright, zCopyrightNotice, - zFullVersion, apzHomeList, zUsageTitle, - zExplain, zDetail, optDesc, - zBugsAddr, /* address to send bugs to */ - NULL, NULL, /* extensions/saved state */ - optionUsage, /* usage procedure */ - translate_option_strings, /* translation procedure */ - /* - * Indexes to special options - */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, - NO_EQUIVALENT /* index of default opt */ - }, - 43 /* full option count */, 38 /* user option count */ -}; - -/* - * Create the static procedure(s) declared above. - */ -static void -doUsageOpt( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - USAGE( EXIT_SUCCESS ); -} - -#if ! defined(TEST_NTPDSIM_OPTS) - -/* * * * * * * - * - * For the set-debug-level option, when DEBUG is #define-d. - */ -#ifdef DEBUG -static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - /* extracted from ../include/debug-opt.def, line 29 */ -DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); -} -#endif /* defined DEBUG */ - -#endif /* defined(TEST_NTPDSIM_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ - -#if defined(TEST_NTPDSIM_OPTS) /* TEST MAIN PROCEDURE: */ - -int -main( int argc, char** argv ) -{ - int res = EXIT_SUCCESS; - (void)optionProcess( &ntpdsimOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpdsimOptions ); - } - return res; -} -#endif /* defined TEST_NTPDSIM_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ - -#if ENABLE_NLS -#include -#include -#include -#include -#include - -static char* AO_gettext( char const* pz ); -static void coerce_it(void** s); - -static char* -AO_gettext( char const* pz ) -{ - char* pzRes; - if (pz == NULL) - return NULL; - pzRes = _(pz); - if (pzRes == pz) - return pzRes; - pzRes = strdup( pzRes ); - if (pzRes == NULL) { - fputs( _("No memory for duping translated strings\n"), stderr ); - exit( EXIT_FAILURE ); - } - return pzRes; -} - -static void coerce_it(void** s) { *s = AO_gettext(*s); } -#define COERSION(_f) \ - coerce_it((void*)&(ntpdsimOptions._f)) - -/* - * This invokes the translation code (e.g. gettext(3)). - */ -static void -translate_option_strings( void ) -{ - /* - * Guard against re-translation. It won't work. The strings will have - * been changed by the first pass through this code. One shot only. - */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; - - do { - ppz++; - *ppz = AO_gettext(*ppz); - } while (--ix > 0); - } - option_usage_text.field_ct = 0; - - { - tOptDesc* pOD = ntpdsimOptions.pOptDesc; - int ix = ntpdsimOptions.optCt; - - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; - } - } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); -} - -#endif /* ENABLE_NLS */ - -#ifdef __cplusplus -} -#endif -/* ntpdsim-opts.c ends here */ diff --git a/contrib/ntp/ntpd/ntpdsim-opts.def b/contrib/ntp/ntpd/ntpdsim-opts.def deleted file mode 100644 index 093c325cf..000000000 --- a/contrib/ntp/ntpd/ntpdsim-opts.def +++ /dev/null @@ -1,15 +0,0 @@ -/* -*- Mode: Text -*- */ - -autogen definitions options; - -#include copyright.def -#include homerc.def - -prog-name = "ntpdsim"; -prog-title = "NTP daemon simulation program"; - -#define SIM -#include ntpdbase-opts.def - -detail = <<- _END_DETAIL - _END_DETAIL; diff --git a/contrib/ntp/ntpd/ntpdsim-opts.h b/contrib/ntp/ntpd/ntpdsim-opts.h deleted file mode 100644 index 3458bbfd0..000000000 --- a/contrib/ntp/ntpd/ntpdsim-opts.h +++ /dev/null @@ -1,422 +0,0 @@ -/* - * EDIT THIS FILE WITH CAUTION (ntpdsim-opts.h) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:12 AM EST - * From the definitions ntpdsim-opts.def - * and the template file options - * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This header file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpdsim author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. - * - * This source file is copyrighted and licensed under the following terms: - * - * ntpdsim copyright 1970-2009 David L. Mills and/or others - all rights reserved - * - * see html/copyright.html - */ -/* - * This file contains the programmatic interface to the Automated - * Options generated for the ntpdsim program. - * These macros are documented in the AutoGen info file in the - * "AutoOpts" chapter. Please refer to that doc for usage help. - */ -#ifndef AUTOOPTS_NTPDSIM_OPTS_H_GUARD -#define AUTOOPTS_NTPDSIM_OPTS_H_GUARD -#include "config.h" -#include - -/* - * Ensure that the library used for compiling this generated header is at - * least as new as the version current when the header template was released - * (not counting patch version increments). Also ensure that the oldest - * tolerable version is at least as old as what was current when the header - * template was released. - */ -#define AO_TEMPLATE_VERSION 118784 -#if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ - || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) -# error option template version mismatches autoopts/options.h header - Choke Me. -#endif - -/* - * Enumeration of each option: - */ -typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_AUTHREQ = 2, - INDEX_OPT_AUTHNOREQ = 3, - INDEX_OPT_BCASTSYNC = 4, - INDEX_OPT_SIMBROADCASTDELAY = 5, - INDEX_OPT_CONFIGFILE = 6, - INDEX_OPT_PHASENOISE = 7, - INDEX_OPT_DEBUG_LEVEL = 8, - INDEX_OPT_SET_DEBUG_LEVEL = 9, - INDEX_OPT_DRIFTFILE = 10, - INDEX_OPT_PANICGATE = 11, - INDEX_OPT_SIMSLEW = 12, - INDEX_OPT_JAILDIR = 13, - INDEX_OPT_INTERFACE = 14, - INDEX_OPT_KEYFILE = 15, - INDEX_OPT_LOGFILE = 16, - INDEX_OPT_NOVIRTUALIPS = 17, - INDEX_OPT_MODIFYMMTIMER = 18, - INDEX_OPT_NOFORK = 19, - INDEX_OPT_NICE = 20, - INDEX_OPT_SERVERTIME = 21, - INDEX_OPT_PIDFILE = 22, - INDEX_OPT_PRIORITY = 23, - INDEX_OPT_QUIT = 24, - INDEX_OPT_PROPAGATIONDELAY = 25, - INDEX_OPT_UPDATEINTERVAL = 26, - INDEX_OPT_STATSDIR = 27, - INDEX_OPT_ENDSIMTIME = 28, - INDEX_OPT_TRUSTEDKEY = 29, - INDEX_OPT_FREQERR = 30, - INDEX_OPT_WALKNOISE = 31, - INDEX_OPT_USER = 32, - INDEX_OPT_VAR = 33, - INDEX_OPT_DVAR = 34, - INDEX_OPT_SLEW = 35, - INDEX_OPT_NDELAY = 36, - INDEX_OPT_PDELAY = 37, - INDEX_OPT_VERSION = 38, - INDEX_OPT_HELP = 39, - INDEX_OPT_MORE_HELP = 40, - INDEX_OPT_SAVE_OPTS = 41, - INDEX_OPT_LOAD_OPTS = 42 -} teOptIndex; - -#define OPTION_CT 43 -#define NTPDSIM_VERSION "4.2.4p8" -#define NTPDSIM_FULL_VERSION "ntpdsim - NTP daemon simulation program - Ver. 4.2.4p8" - -/* - * Interface defines for all options. Replace "n" with the UPPER_CASED - * option name (as in the teOptIndex enumeration above). - * e.g. HAVE_OPT( IPV4 ) - */ -#define DESC(n) (ntpdsimOptions.pOptDesc[INDEX_OPT_## n]) -#define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) -#define OPT_ARG(n) (DESC(n).optArg.argString) -#define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) -#define COUNT_OPT(n) (DESC(n).optOccCt) -#define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) -#define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) -#define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) -#define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) -#define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) -#define CLEAR_OPT(n) STMTS( \ - DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ - if ( (DESC(n).fOptState & OPTST_INITENABLED) == 0) \ - DESC(n).fOptState |= OPTST_DISABLED; \ - DESC(n).optCookie = NULL ) - -/* - * Make sure there are no #define name conflicts with the option names - */ -#ifndef NO_OPTION_NAME_WARNINGS -# ifdef IPV4 -# warning undefining IPV4 due to option name conflict -# undef IPV4 -# endif -# ifdef IPV6 -# warning undefining IPV6 due to option name conflict -# undef IPV6 -# endif -# ifdef AUTHREQ -# warning undefining AUTHREQ due to option name conflict -# undef AUTHREQ -# endif -# ifdef AUTHNOREQ -# warning undefining AUTHNOREQ due to option name conflict -# undef AUTHNOREQ -# endif -# ifdef BCASTSYNC -# warning undefining BCASTSYNC due to option name conflict -# undef BCASTSYNC -# endif -# ifdef SIMBROADCASTDELAY -# warning undefining SIMBROADCASTDELAY due to option name conflict -# undef SIMBROADCASTDELAY -# endif -# ifdef CONFIGFILE -# warning undefining CONFIGFILE due to option name conflict -# undef CONFIGFILE -# endif -# ifdef PHASENOISE -# warning undefining PHASENOISE due to option name conflict -# undef PHASENOISE -# endif -# ifdef DEBUG_LEVEL -# warning undefining DEBUG_LEVEL due to option name conflict -# undef DEBUG_LEVEL -# endif -# ifdef SET_DEBUG_LEVEL -# warning undefining SET_DEBUG_LEVEL due to option name conflict -# undef SET_DEBUG_LEVEL -# endif -# ifdef DRIFTFILE -# warning undefining DRIFTFILE due to option name conflict -# undef DRIFTFILE -# endif -# ifdef PANICGATE -# warning undefining PANICGATE due to option name conflict -# undef PANICGATE -# endif -# ifdef SIMSLEW -# warning undefining SIMSLEW due to option name conflict -# undef SIMSLEW -# endif -# ifdef JAILDIR -# warning undefining JAILDIR due to option name conflict -# undef JAILDIR -# endif -# ifdef INTERFACE -# warning undefining INTERFACE due to option name conflict -# undef INTERFACE -# endif -# ifdef KEYFILE -# warning undefining KEYFILE due to option name conflict -# undef KEYFILE -# endif -# ifdef LOGFILE -# warning undefining LOGFILE due to option name conflict -# undef LOGFILE -# endif -# ifdef NOVIRTUALIPS -# warning undefining NOVIRTUALIPS due to option name conflict -# undef NOVIRTUALIPS -# endif -# ifdef MODIFYMMTIMER -# warning undefining MODIFYMMTIMER due to option name conflict -# undef MODIFYMMTIMER -# endif -# ifdef NOFORK -# warning undefining NOFORK due to option name conflict -# undef NOFORK -# endif -# ifdef NICE -# warning undefining NICE due to option name conflict -# undef NICE -# endif -# ifdef SERVERTIME -# warning undefining SERVERTIME due to option name conflict -# undef SERVERTIME -# endif -# ifdef PIDFILE -# warning undefining PIDFILE due to option name conflict -# undef PIDFILE -# endif -# ifdef PRIORITY -# warning undefining PRIORITY due to option name conflict -# undef PRIORITY -# endif -# ifdef QUIT -# warning undefining QUIT due to option name conflict -# undef QUIT -# endif -# ifdef PROPAGATIONDELAY -# warning undefining PROPAGATIONDELAY due to option name conflict -# undef PROPAGATIONDELAY -# endif -# ifdef UPDATEINTERVAL -# warning undefining UPDATEINTERVAL due to option name conflict -# undef UPDATEINTERVAL -# endif -# ifdef STATSDIR -# warning undefining STATSDIR due to option name conflict -# undef STATSDIR -# endif -# ifdef ENDSIMTIME -# warning undefining ENDSIMTIME due to option name conflict -# undef ENDSIMTIME -# endif -# ifdef TRUSTEDKEY -# warning undefining TRUSTEDKEY due to option name conflict -# undef TRUSTEDKEY -# endif -# ifdef FREQERR -# warning undefining FREQERR due to option name conflict -# undef FREQERR -# endif -# ifdef WALKNOISE -# warning undefining WALKNOISE due to option name conflict -# undef WALKNOISE -# endif -# ifdef USER -# warning undefining USER due to option name conflict -# undef USER -# endif -# ifdef VAR -# warning undefining VAR due to option name conflict -# undef VAR -# endif -# ifdef DVAR -# warning undefining DVAR due to option name conflict -# undef DVAR -# endif -# ifdef SLEW -# warning undefining SLEW due to option name conflict -# undef SLEW -# endif -# ifdef NDELAY -# warning undefining NDELAY due to option name conflict -# undef NDELAY -# endif -# ifdef PDELAY -# warning undefining PDELAY due to option name conflict -# undef PDELAY -# endif -#else /* NO_OPTION_NAME_WARNINGS */ -# undef IPV4 -# undef IPV6 -# undef AUTHREQ -# undef AUTHNOREQ -# undef BCASTSYNC -# undef SIMBROADCASTDELAY -# undef CONFIGFILE -# undef PHASENOISE -# undef DEBUG_LEVEL -# undef SET_DEBUG_LEVEL -# undef DRIFTFILE -# undef PANICGATE -# undef SIMSLEW -# undef JAILDIR -# undef INTERFACE -# undef KEYFILE -# undef LOGFILE -# undef NOVIRTUALIPS -# undef MODIFYMMTIMER -# undef NOFORK -# undef NICE -# undef SERVERTIME -# undef PIDFILE -# undef PRIORITY -# undef QUIT -# undef PROPAGATIONDELAY -# undef UPDATEINTERVAL -# undef STATSDIR -# undef ENDSIMTIME -# undef TRUSTEDKEY -# undef FREQERR -# undef WALKNOISE -# undef USER -# undef VAR -# undef DVAR -# undef SLEW -# undef NDELAY -# undef PDELAY -#endif /* NO_OPTION_NAME_WARNINGS */ - -/* - * Interface defines for specific options. - */ -#define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) -#define VALUE_OPT_IPV6 '6' -#define VALUE_OPT_AUTHREQ 'a' -#define VALUE_OPT_AUTHNOREQ 'A' -#define VALUE_OPT_BCASTSYNC 'b' -#define VALUE_OPT_SIMBROADCASTDELAY 'B' -#define VALUE_OPT_CONFIGFILE 'c' -#define VALUE_OPT_PHASENOISE 'C' -#ifdef DEBUG -#define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG -#define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ -#define VALUE_OPT_DRIFTFILE 'f' -#define VALUE_OPT_PANICGATE 'g' -#define VALUE_OPT_SIMSLEW 'H' -#define VALUE_OPT_JAILDIR 'i' -#define VALUE_OPT_INTERFACE 'I' -#define VALUE_OPT_KEYFILE 'k' -#define VALUE_OPT_LOGFILE 'l' -#define VALUE_OPT_NOVIRTUALIPS 'L' -#ifdef SYS_WINNT -#define VALUE_OPT_MODIFYMMTIMER 'M' -#endif /* SYS_WINNT */ -#define VALUE_OPT_NOFORK 'n' -#define VALUE_OPT_NICE 'N' -#define VALUE_OPT_SERVERTIME 'O' -#define VALUE_OPT_PIDFILE 'p' -#define VALUE_OPT_PRIORITY 'P' -#define OPT_VALUE_PRIORITY (DESC(PRIORITY).optArg.argInt) -#define VALUE_OPT_QUIT 'q' -#define VALUE_OPT_PROPAGATIONDELAY 'r' -#define VALUE_OPT_UPDATEINTERVAL 'U' -#define OPT_VALUE_UPDATEINTERVAL (DESC(UPDATEINTERVAL).optArg.argInt) -#define VALUE_OPT_STATSDIR 's' -#define VALUE_OPT_ENDSIMTIME 'S' -#define VALUE_OPT_TRUSTEDKEY 't' -#define VALUE_OPT_FREQERR 'T' -#define VALUE_OPT_WALKNOISE 'W' -#define VALUE_OPT_USER 'u' -#define VALUE_OPT_VAR 'v' -#define VALUE_OPT_DVAR 'V' -#define VALUE_OPT_SLEW 'x' -#define VALUE_OPT_NDELAY 'Y' -#define VALUE_OPT_PDELAY 'Z' - -#define VALUE_OPT_VERSION 'v' -#define VALUE_OPT_HELP '?' -#define VALUE_OPT_MORE_HELP '!' -#define VALUE_OPT_SAVE_OPTS '>' -#define VALUE_OPT_LOAD_OPTS '<' -#define SET_OPT_SAVE_OPTS(a) STMTS( \ - DESC(SAVE_OPTS).fOptState &= OPTST_PERSISTENT_MASK; \ - DESC(SAVE_OPTS).fOptState |= OPTST_SET; \ - DESC(SAVE_OPTS).optArg.argString = (char const*)(a) ) -/* - * Interface defines not associated with particular options - */ -#define ERRSKIP_OPTERR STMTS( ntpdsimOptions.fOptSet &= ~OPTPROC_ERRSTOP ) -#define ERRSTOP_OPTERR STMTS( ntpdsimOptions.fOptSet |= OPTPROC_ERRSTOP ) -#define RESTART_OPT(n) STMTS( \ - ntpdsimOptions.curOptIdx = (n); \ - ntpdsimOptions.pzCurOpt = NULL ) -#define START_OPT RESTART_OPT(1) -#define USAGE(c) (*ntpdsimOptions.pUsageProc)( &ntpdsimOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ - -/* * * * * * - * - * Declare the ntpdsim option descriptor. - */ -#ifdef __cplusplus -extern "C" { -#endif - -extern tOptions ntpdsimOptions; - -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif - -#ifdef __cplusplus -} -#endif -#endif /* AUTOOPTS_NTPDSIM_OPTS_H_GUARD */ -/* ntpdsim-opts.h ends here */ diff --git a/contrib/ntp/ntpd/ntpdsim-opts.menu b/contrib/ntp/ntpd/ntpdsim-opts.menu deleted file mode 100644 index c7874583d..000000000 --- a/contrib/ntp/ntpd/ntpdsim-opts.menu +++ /dev/null @@ -1 +0,0 @@ -* ntpdsim Invocation:: Invoking ntpdsim diff --git a/contrib/ntp/ntpd/ntpdsim-opts.texi b/contrib/ntp/ntpd/ntpdsim-opts.texi deleted file mode 100644 index ed5221062..000000000 --- a/contrib/ntp/ntpd/ntpdsim-opts.texi +++ /dev/null @@ -1,568 +0,0 @@ -@node ntpdsim Invocation -@section Invoking ntpdsim -@pindex ntpdsim -@cindex NTP daemon simulation program -@ignore -# -# EDIT THIS FILE WITH CAUTION (ntpdsim-opts.texi) -# -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:15 AM EST -# From the definitions ntpdsim-opts.def -# and the template file aginfo.tpl -@end ignore -This program has no explanation. - - - -This section was generated by @strong{AutoGen}, -the aginfo template and the option descriptions for the @command{ntpdsim} program. It documents the ntpdsim usage text and option meanings. - -This software is released under a specialized copyright license. - -@menu -* ntpdsim usage:: ntpdsim usage help (-?) -* ntpdsim authnoreq:: authnoreq option (-A) -* ntpdsim authreq:: authreq option (-a) -* ntpdsim bcastsync:: bcastsync option (-b) -* ntpdsim configfile:: configfile option (-c) -* ntpdsim debug-level:: debug-level option (-d) -* ntpdsim driftfile:: driftfile option (-f) -* ntpdsim dvar:: dvar option (-V) -* ntpdsim endsimtime:: endsimtime option (-S) -* ntpdsim freqerr:: freqerr option (-T) -* ntpdsim interface:: interface option (-I) -* ntpdsim ipv4:: ipv4 option (-4) -* ntpdsim ipv6:: ipv6 option (-6) -* ntpdsim jaildir:: jaildir option (-i) -* ntpdsim keyfile:: keyfile option (-k) -* ntpdsim logfile:: logfile option (-l) -* ntpdsim modifymmtimer:: modifymmtimer option (-M) -* ntpdsim ndelay:: ndelay option (-Y) -* ntpdsim nice:: nice option (-N) -* ntpdsim nofork:: nofork option (-n) -* ntpdsim novirtualips:: novirtualips option (-L) -* ntpdsim panicgate:: panicgate option (-g) -* ntpdsim pdelay:: pdelay option (-Z) -* ntpdsim phasenoise:: phasenoise option (-C) -* ntpdsim pidfile:: pidfile option (-p) -* ntpdsim priority:: priority option (-P) -* ntpdsim propagationdelay:: propagationdelay option (-r) -* ntpdsim quit:: quit option (-q) -* ntpdsim servertime:: servertime option (-O) -* ntpdsim set-debug-level:: set-debug-level option (-D) -* ntpdsim simbroadcastdelay:: simbroadcastdelay option (-B) -* ntpdsim simslew:: simslew option (-H) -* ntpdsim slew:: slew option (-x) -* ntpdsim statsdir:: statsdir option (-s) -* ntpdsim trustedkey:: trustedkey option (-t) -* ntpdsim updateinterval:: updateinterval option (-U) -* ntpdsim user:: user option (-u) -* ntpdsim var:: var option (-v) -* ntpdsim walknoise:: walknoise option (-W) -@end menu - -@node ntpdsim usage -@subsection ntpdsim usage help (-?) -@cindex ntpdsim usage - -This is the automatically generated usage text for ntpdsim: - -@exampleindent 0 -@example -ntpd - NTP daemon program - Ver. 4.2.5p247-RC -USAGE: ntpdsim [ - [] | --[@{=| @}] ]... - Flg Arg Option-Name Description - -4 no ipv4 Force IPv4 DNS name resolution - - prohibits these options: - ipv6 - -6 no ipv6 Force IPv6 DNS name resolution - - prohibits these options: - ipv4 - -a no authreq Require crypto authentication - - prohibits these options: - authnoreq - -A no authnoreq Do not require crypto authentication - - prohibits these options: - authreq - -b no bcastsync Allow us to sync to broadcast servers - -c Str configfile configuration file name - -d no debug-level Increase output debug message level - - may appear multiple times - -D Str set-debug-level Set the output debug message level - - may appear multiple times - -f Str driftfile frequency drift file name - -g no panicgate Allow the first adjustment to be Big - - may appear multiple times - -i --- jaildir built without --enable-clockctl or --enable-linuxcaps - -I Str interface Listen on an interface name or address - - may appear multiple times - -k Str keyfile path to symmetric keys - -l Str logfile path to the log file - -L no novirtualips Do not listen to virtual interfaces - -n no nofork Do not fork - -N no nice Run at high priority - -p Str pidfile path to the PID file - -P Num priority Process priority - -q no quit Set the time and quit - -r Str propagationdelay Broadcast/propagation delay - Str saveconfigquit Save parsed configuration and quit - -s Str statsdir Statistics file location - -t Str trustedkey Trusted key number - - may appear multiple times - -u --- user built without --enable-clockctl or --enable-linuxcaps - -U Num updateinterval interval in seconds between scans for new or dropped interfaces - Str var make ARG an ntp variable (RW) - - may appear multiple times - Str dvar make ARG an ntp variable (RW|DEF) - - may appear multiple times - -x no slew Slew up to 600 seconds - opt version Output version information and exit - -? no help Display extended usage information and exit - -! no more-help Extended usage information passed thru pager - -Options are specified by doubled hyphens and their name -or by a single hyphen and the flag character. - -The following option preset mechanisms are supported: - - examining environment variables named NTPD_* - - - -please send bug reports to: http://bugs.ntp.org, bugs@@ntp.org -@end example -@exampleindent 4 - -@node ntpdsim ipv4 -@subsection ipv4 option (-4) -@cindex ntpdsim-ipv4 - -This is the ``force ipv4 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv4 namespace. - -@node ntpdsim ipv6 -@subsection ipv6 option (-6) -@cindex ntpdsim-ipv6 - -This is the ``force ipv6 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv6 namespace. - -@node ntpdsim authreq -@subsection authreq option (-a) -@cindex ntpdsim-authreq - -This is the ``require crypto authentication'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -authnoreq. -@end itemize - -Require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is the default. - -@node ntpdsim authnoreq -@subsection authnoreq option (-A) -@cindex ntpdsim-authnoreq - -This is the ``do not require crypto authentication'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -authreq. -@end itemize - -Do not require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is almost never a good idea. - -@node ntpdsim bcastsync -@subsection bcastsync option (-b) -@cindex ntpdsim-bcastsync - -This is the ``allow us to sync to broadcast servers'' option. - - -@node ntpdsim simbroadcastdelay -@subsection simbroadcastdelay option (-B) -@cindex ntpdsim-simbroadcastdelay - -This is the ``simulator broadcast delay'' option. - - -@node ntpdsim configfile -@subsection configfile option (-c) -@cindex ntpdsim-configfile - -This is the ``configuration file name'' option. -The name and path of the configuration file, -/etc/ntp.conf -by default. - -@node ntpdsim phasenoise -@subsection phasenoise option (-C) -@cindex ntpdsim-phasenoise - -This is the ``phase noise level'' option. - - -@node ntpdsim debug-level -@subsection debug-level option (-d) -@cindex ntpdsim-debug-level - -This is the ``increase output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Increase the debugging message output level. - -@node ntpdsim set-debug-level -@subsection set-debug-level option (-D) -@cindex ntpdsim-set-debug-level - -This is the ``set the output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). - -@node ntpdsim driftfile -@subsection driftfile option (-f) -@cindex ntpdsim-driftfile - -This is the ``frequency drift file name'' option. -The name and path of the frequency file, -/etc/ntp.drift -by default. -This is the same operation as the -driftfile driftfile -configuration specification in the -/etc/ntp.conf -file. - -@node ntpdsim panicgate -@subsection panicgate option (-g) -@cindex ntpdsim-panicgate - -This is the ``allow the first adjustment to be big'' option. -Normally, -ntpd -exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, -ntpd -will exit with a message to the system log. This option can be used with the --q -and --x -options. -See the -tinker -configuration file directive for other options. - -@node ntpdsim simslew -@subsection simslew option (-H) -@cindex ntpdsim-simslew - -This is the ``simuator slew'' option. - - -@node ntpdsim jaildir -@subsection jaildir option (-i) -@cindex ntpdsim-jaildir - -This is the ``jail directory'' option. -Chroot the server to the directory -jaildir -. -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. -You may need to also specify a --u -option. - -@node ntpdsim interface -@subsection interface option (-I) -@cindex ntpdsim-interface - -This is the ``listen on interface'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpdsim keyfile -@subsection keyfile option (-k) -@cindex ntpdsim-keyfile - -This is the ``path to symmetric keys'' option. -Specify the name and path of the symmetric key file. -/etc/ntp.keys -is the default. -This is the same operation as the -keys keyfile -configuration file directive. - -@node ntpdsim logfile -@subsection logfile option (-l) -@cindex ntpdsim-logfile - -This is the ``path to the log file'' option. -Specify the name and path of the log file. -The default is the system log file. -This is the same operation as the -logfile logfile -configuration file directive. - -@node ntpdsim novirtualips -@subsection novirtualips option (-L) -@cindex ntpdsim-novirtualips - -This is the ``do not listen to virtual ips'' option. -Do not listen to virtual IPs. The default is to listen. - -@node ntpdsim modifymmtimer -@subsection modifymmtimer option (-M) -@cindex ntpdsim-modifymmtimer - -This is the ``modify multimedia timer (windows only)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must be compiled in by defining @code{SYS_WINNT} during the compilation. -@end itemize - -Set the Windows Multimedia Timer to highest resolution. - -@node ntpdsim nofork -@subsection nofork option (-n) -@cindex ntpdsim-nofork - -This is the ``do not fork'' option. - - -@node ntpdsim nice -@subsection nice option (-N) -@cindex ntpdsim-nice - -This is the ``run at high priority'' option. -To the extent permitted by the operating system, run -ntpd -at the highest priority. - -@node ntpdsim servertime -@subsection servertime option (-O) -@cindex ntpdsim-servertime - -This is the ``server time'' option. - - -@node ntpdsim pidfile -@subsection pidfile option (-p) -@cindex ntpdsim-pidfile - -This is the ``path to the pid file'' option. -Specify the name and path of the file used to record -ntpd's -process ID. -This is the same operation as the -pidfile pidfile -configuration file directive. - -@node ntpdsim priority -@subsection priority option (-P) -@cindex ntpdsim-priority - -This is the ``process priority'' option. -To the extent permitted by the operating system, run -ntpd -at the specified -sched_setscheduler(SCHED_FIFO) -priority. - -@node ntpdsim quit -@subsection quit option (-q) -@cindex ntpdsim-quit - -This is the ``set the time and quit'' option. -ntpd -will exit just after the first time the clock is set. This behavior mimics that of the -ntpdate -program, which is to be retired. -The --g -and --x -options can be used with this option. -Note: The kernel time discipline is disabled with this option. - -@node ntpdsim propagationdelay -@subsection propagationdelay option (-r) -@cindex ntpdsim-propagationdelay - -This is the ``broadcast/propagation delay'' option. -Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. - -@node ntpdsim updateinterval -@subsection updateinterval option (-U) -@cindex ntpdsim-updateinterval - -This is the ``interval in seconds between scans for new or dropped interfaces'' option. -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. - -@node ntpdsim statsdir -@subsection statsdir option (-s) -@cindex ntpdsim-statsdir - -This is the ``statistics file location'' option. -Specify the directory path for files created by the statistics facility. -This is the same operation as the -statsdir statsdir -configuration file directive. - -@node ntpdsim endsimtime -@subsection endsimtime option (-S) -@cindex ntpdsim-endsimtime - -This is the ``simulation end time'' option. - - -@node ntpdsim trustedkey -@subsection trustedkey option (-t) -@cindex ntpdsim-trustedkey - -This is the ``trusted key number'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - -Add a key number to the trusted key list. - -@node ntpdsim freqerr -@subsection freqerr option (-T) -@cindex ntpdsim-freqerr - -This is the ``simulation frequency error'' option. - - -@node ntpdsim walknoise -@subsection walknoise option (-W) -@cindex ntpdsim-walknoise - -This is the ``simulation random walk noise'' option. - - -@node ntpdsim user -@subsection user option (-u) -@cindex ntpdsim-user - -This is the ``run as userid (or userid:groupid)'' option. -Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with ---enable-clockctl -) and Linux (configure with ---enable-linuxcaps -). - -@node ntpdsim var -@subsection var option (-v) -@cindex ntpdsim-var - -This is the ``make arg an ntp variable (rw)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpdsim dvar -@subsection dvar option (-V) -@cindex ntpdsim-dvar - -This is the ``make arg an ntp variable (rw|def)'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - - - -@node ntpdsim slew -@subsection slew option (-x) -@cindex ntpdsim-slew - -This is the ``slew up to 600 seconds'' option. -Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. -This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. -Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. -Thus, an adjustment as much as 600 s will take almost 14 days to complete. -This option can be used with the --g -and --q -options. -See the -tinker -configuration file directive for other options. -Note: The kernel time discipline is disabled with this option. - -@node ntpdsim ndelay -@subsection ndelay option (-Y) -@cindex ntpdsim-ndelay - -This is the ``simulation network delay'' option. - - -@node ntpdsim pdelay -@subsection pdelay option (-Z) -@cindex ntpdsim-pdelay - -This is the ``simulation processing delay'' option. - diff --git a/contrib/ntp/ntpd/ntpdsim.1 b/contrib/ntp/ntpd/ntpdsim.1 deleted file mode 100644 index 202876418..000000000 --- a/contrib/ntp/ntpd/ntpdsim.1 +++ /dev/null @@ -1,357 +0,0 @@ -.TH NTPDSIM 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" -.\" EDIT THIS FILE WITH CAUTION (ntpdsim.1) -.\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:13:14 AM EST -.\" From the definitions ntpdsim-opts.def -.\" and the template file agman1.tpl -.\" -.SH NAME -ntpdsim \- NTP daemon simulation program -.SH SYNOPSIS -.B ntpdsim -.\" Mixture of short (flag) options and long options -.RB [ \-\fIflag\fP " [\fIvalue\fP]]... [" \--\fIopt-name\fP " [[=| ]\fIvalue\fP]]..." -.PP -All arguments must be options. -.SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpdsim\fP command. - -.SH OPTIONS -.TP -.BR \-4 ", " \--ipv4 -Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv4 namespace. -.TP -.BR \-6 ", " \--ipv6 -Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv6 namespace. -.TP -.BR \-a ", " \--authreq -Require crypto authentication. -This option must not appear in combination with any of the following options: -authnoreq. -.sp -Require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is the default. -.TP -.BR \-A ", " \--authnoreq -Do not require crypto authentication. -This option must not appear in combination with any of the following options: -authreq. -.sp -Do not require cryptographic authentication for broadcast client, -multicast client and symmetric passive associations. -This is almost never a good idea. -.TP -.BR \-b ", " \--bcastsync -Allow us to sync to broadcast servers. -.sp - -.TP -.BR \-B " \fIstring\fP, " \--simbroadcastdelay "=" \fIstring\fP -Simulator broadcast delay. -.sp - -.TP -.BR \-c " \fIstring\fP, " \--configfile "=" \fIstring\fP -configuration file name. -.sp -The name and path of the configuration file, -/etc/ntp.conf -by default. -.TP -.BR \-C " \fIstring\fP, " \--phasenoise "=" \fIstring\fP -Phase noise level. -.sp - -.TP -.BR \-d ", " \--debug-level -Increase output debug message level. -This option may appear an unlimited number of times. -.sp -Increase the debugging message output level. -.TP -.BR \-D " \fIstring\fP, " \--set-debug-level "=" \fIstring\fP -Set the output debug message level. -This option may appear an unlimited number of times. -.sp -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). -.TP -.BR \-f " \fIstring\fP, " \--driftfile "=" \fIstring\fP -frequency drift file name. -.sp -The name and path of the frequency file, -/etc/ntp.drift -by default. -This is the same operation as the -driftfile driftfile -configuration specification in the -/etc/ntp.conf -file. -.TP -.BR \-g ", " \--panicgate -Allow the first adjustment to be Big. -.sp -Normally, -ntpd -exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the threshold is exceeded after that, -ntpd -will exit with a message to the system log. This option can be used with the --q -and --x -options. -See the -tinker -configuration file directive for other options. -.TP -.BR \-H " \fIstring\fP, " \--simslew "=" \fIstring\fP -Simuator slew. -.sp - -.TP -.BR \-i " \fIstring\fP, " \--jaildir "=" \fIstring\fP -Jail directory. -.sp -Chroot the server to the directory -jaildir -. -This option also implies that the server attempts to drop root privileges at startup (otherwise, chroot gives very little additional security), and it is only available if the OS supports to run the server without full root privileges. -You may need to also specify a --u -option. -.TP -.BR \-I " \fIiface\fP, " \--interface "=" \fIiface\fP -Listen on interface. -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-k " \fIstring\fP, " \--keyfile "=" \fIstring\fP -path to symmetric keys. -.sp -Specify the name and path of the symmetric key file. -/etc/ntp.keys -is the default. -This is the same operation as the -keys keyfile -configuration file directive. -.TP -.BR \-l " \fIstring\fP, " \--logfile "=" \fIstring\fP -path to the log file. -.sp -Specify the name and path of the log file. -The default is the system log file. -This is the same operation as the -logfile logfile -configuration file directive. -.TP -.BR \-L ", " \--novirtualips -Do not listen to virtual IPs. -.sp -Do not listen to virtual IPs. The default is to listen. -.TP -.BR \-M ", " \--modifymmtimer -Modify Multimedia Timer (Windows only). -.sp -Set the Windows Multimedia Timer to highest resolution. -.TP -.BR \-n ", " \--nofork -Do not fork. -.sp - -.TP -.BR \-N ", " \--nice -Run at high priority. -.sp -To the extent permitted by the operating system, run -ntpd -at the highest priority. -.TP -.BR \-O " \fIstring\fP, " \--servertime "=" \fIstring\fP -Server time. -.sp - -.TP -.BR \-p " \fIstring\fP, " \--pidfile "=" \fIstring\fP -path to the PID file. -.sp -Specify the name and path of the file used to record -ntpd's -process ID. -This is the same operation as the -pidfile pidfile -configuration file directive. -.TP -.BR \-P " \fInumber\fP, " \--priority "=" \fInumber\fP -Process priority. -This option takes an integer number as its argument. -.sp -To the extent permitted by the operating system, run -ntpd -at the specified -sched_setscheduler(SCHED_FIFO) -priority. -.TP -.BR \-q ", " \--quit -Set the time and quit. -.sp -ntpd -will exit just after the first time the clock is set. This behavior mimics that of the -ntpdate -program, which is to be retired. -The --g -and --x -options can be used with this option. -Note: The kernel time discipline is disabled with this option. -.TP -.BR \-r " \fIstring\fP, " \--propagationdelay "=" \fIstring\fP -Broadcast/propagation delay. -.sp -Specify the default propagation delay from the broadcast/multicast server to this client. This is necessary only if the delay cannot be computed automatically by the protocol. -.TP -.BR \-U " \fInumber\fP, " \--updateinterval "=" \fInumber\fP -interval in seconds between scans for new or dropped interfaces. -This option takes an integer number as its argument. -.sp -Give the time in seconds between two scans for new or dropped interfaces. -For systems with routing socket support the scans will be performed shortly after the interface change -has been detected by the system. -Use 0 to disable scanning. -.TP -.BR \-s " \fIstring\fP, " \--statsdir "=" \fIstring\fP -Statistics file location. -.sp -Specify the directory path for files created by the statistics facility. -This is the same operation as the -statsdir statsdir -configuration file directive. -.TP -.BR \-S " \fIstring\fP, " \--endsimtime "=" \fIstring\fP -Simulation end time. -.sp - -.TP -.BR \-t " \fItkey\fP, " \--trustedkey "=" \fItkey\fP -Trusted key number. -This option may appear an unlimited number of times. -.sp -Add a key number to the trusted key list. -.TP -.BR \-T " \fIstring\fP, " \--freqerr "=" \fIstring\fP -Simulation frequency error. -.sp - -.TP -.BR \-W " \fIstring\fP, " \--walknoise "=" \fIstring\fP -Simulation random walk noise. -.sp - -.TP -.BR \-u " \fIstring\fP, " \--user "=" \fIstring\fP -Run as userid (or userid:groupid). -.sp -Specify a user, and optionally a group, to switch to. -This option is only available if the OS supports to run the server without full root privileges. -Currently, this option is supported under NetBSD (configure with ---enable-clockctl -) and Linux (configure with ---enable-linuxcaps -). -.TP -.BR \-v " \fInvar\fP, " \--var "=" \fInvar\fP -make ARG an ntp variable (RW). -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-V " \fIndvar\fP, " \--dvar "=" \fIndvar\fP -make ARG an ntp variable (RW|DEF). -This option may appear an unlimited number of times. -.sp - -.TP -.BR \-x ", " \--slew -Slew up to 600 seconds. -.sp -Normally, the time is slewed if the offset is less than the step threshold, which is 128 ms by default, and stepped if above the threshold. -This option sets the threshold to 600 s, which is well within the accuracy window to set the clock manually. -Note: Since the slew rate of typical Unix kernels is limited to 0.5 ms/s, each second of adjustment requires an amortization interval of 2000 s. -Thus, an adjustment as much as 600 s will take almost 14 days to complete. -This option can be used with the --g -and --q -options. -See the -tinker -configuration file directive for other options. -Note: The kernel time discipline is disabled with this option. -.TP -.BR \-Y " \fIstring\fP, " \--ndelay "=" \fIstring\fP -Simulation network delay. -.sp - -.TP -.BR \-Z " \fIstring\fP, " \--pdelay "=" \fIstring\fP -Simulation processing delay. -.sp - -.TP -.BR \-? , " \--help" -Display usage information and exit. -.TP -.BR \-! , " \--more-help" -Extended usage information passed thru pager. -.TP -.BR \-> " [\fIrcfile\fP]," " \--save-opts" "[=\fIrcfile\fP]" -Save the option state to \fIrcfile\fP. The default is the \fIlast\fP -configuration file listed in the \fBOPTION PRESETS\fP section, below. -.TP -.BR \-< " \fIrcfile\fP," " \--load-opts" "=\fIrcfile\fP," " \--no-load-opts" -Load options from \fIrcfile\fP. -The \fIno-load-opts\fP form will disable the loading -of earlier RC/INI files. \fI--no-load-opts\fP is handled early, -out of order. -.TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" -Output version of program and exit. The default mode is `v', a simple -version. The `c' mode will print copyright information and `n' will -print the full copyright notice. -.SH OPTION PRESETS -Any option that is not marked as \fInot presettable\fP may be preset -by loading values from configuration ("RC" or ".INI") file(s) and values from -environment variables named: -.nf - \fBNTPDSIM_\fP or \fBNTPDSIM\fP -.fi -.aj -The environmental presets take precedence (are processed later than) -the configuration files. -The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". -If any of these are directories, then the file \fI.ntprc\fP -is searched for within those directories. -.SH AUTHOR -David L. Mills and/or others -.br -Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org - -.PP -.nf -.na -see html/copyright.html -.fi -.ad -.PP -This manual page was \fIAutoGen\fP-erated from the \fBntpdsim\fP -option definitions. diff --git a/contrib/ntp/ntpd/ntpsim.c b/contrib/ntp/ntpd/ntpsim.c index d5ed587d5..b7c3218fc 100644 --- a/contrib/ntp/ntpd/ntpsim.c +++ b/contrib/ntp/ntpd/ntpsim.c @@ -1,89 +1,142 @@ -/* - * NTP simulator engine - Harish Nair - * University of Delaware, 2001 +/* ntpdsim.c + * + * The source code for the ntp discrete event simulator. + * + * Written By: Sachin Kamboj + * University of Delaware + * Newark, DE 19711 + * Copyright (c) 2006 + * (Some code shamelessly based on the original NTP discrete event simulator) */ + +#include +#ifdef SIM #include "ntpd.h" -#include "ntpsim.h" -#include "ntpdsim-opts.h" +#include "ntp_config.h" + +/* forward prototypes */ +int determine_event_ordering(const Event *e1, const Event *e2); +int determine_recv_buf_ordering(const struct recvbuf *b1, + const struct recvbuf *b2); +void create_server_associations(void); +void init_sim_io(void); + +/* Global Variable Definitions */ +sim_info simulation; /* Simulation Control Variables */ +local_clock_info simclock; /* Local Clock Variables */ +queue *event_queue; /* Event Queue */ +queue *recv_queue; /* Receive Queue */ +static double sys_residual = 0; /* adjustment residue (s) */ + +void (*event_ptr[]) (Event *) = { + sim_event_beep, sim_update_clocks, sim_event_timer, sim_event_recv_packet +}; /* Function pointer to the events */ -/* - * Defines... - */ -#define SIM_TIME 86400 /* end simulation time */ -#define NET_DLY .001 /* network delay */ -#define PROC_DLY .001 /* processing delay */ -#define BEEP_DLY 3600 /* beep interval (s) */ -#define SLEW 500e-6 /* correction rate (PPM) */ /* - * Function pointers + * Define a function to compare two events to determine which one occurs + * first. */ -void (*funcPtr[]) (Node *, Event) = { - &ndbeep, &ndeclk, &ntptmr, &netpkt -}; +int +determine_event_ordering( + const Event *e1, + const Event *e2 + ) +{ + return (e1->time - e2->time); +} /* - * ntpsim - initialize global variables and event queue and start + * Define a function to compare two received packets to determine which + * one is received first. */ int -ntpsim( - int argc, - char *argv[] +determine_recv_buf_ordering( + const struct recvbuf *b1, + const struct recvbuf *b2 ) { - Event e; - double maxtime; - struct timeval seed; + double recv_time1; + double recv_time2; - /* - * Initialize the global node - */ - ntp_node.time = 0; /* simulation time */ - ntp_node.sim_time = SIM_TIME; /* end simulation time (-S) */ - ntp_node.ntp_time = 0; /* client disciplined time */ - ntp_node.adj = 0; /* remaining time correction */ - ntp_node.slew = SLEW; /* correction rate (-H) */ - - ntp_node.clk_time = 0; /* server time (-O) */ - ntp_node.ferr = 0; /* frequency error (-T) */ - ntp_node.fnse = 0; /* random walk noise (-W) */ - ntp_node.ndly = NET_DLY; /* network delay (-Y) */ - ntp_node.snse = 0; /* phase noise (-C) */ - ntp_node.pdly = PROC_DLY; /* processing delay (-Z) */ - ntp_node.bdly = BEEP_DLY; /* beep interval (-B) */ - - ntp_node.events = NULL; - ntp_node.rbuflist = NULL; + /* Simply convert the time received to double and subtract */ + LFPTOD(&b1->recv_time, recv_time1); + LFPTOD(&b2->recv_time, recv_time2); - /* - * Initialize ntp variables - */ - initializing = 1; - init_auth(); - init_util(); - init_restrict(); - init_mon(); - init_timer(); - init_lib(); - init_request(); - init_control(); - init_peer(); - init_proto(); - init_io(); - init_loopfilter(); - mon_start(MON_OFF); - - { - int optct = optionProcess(&ntpdsimOptions, argc, argv); - argc -= optct; - argv += optct; + return (int)(recv_time1 - recv_time2); +} + + +/* Define a function to create the server associations */ +void create_server_associations(void) +{ + int i; + + for (i = 0; i < simulation.num_of_servers; ++i) { + printf("%s\n", stoa(simulation.servers[i].addr)); + if (peer_config(simulation.servers[i].addr, + NULL, + loopback_interface, + MODE_CLIENT, + NTP_VERSION, + NTP_MINDPOLL, + NTP_MAXDPOLL, + 0, /* peerflags */ + 0, /* ttl */ + 0, /* peerkey */ + NULL /* group ident */) == 0) { + fprintf(stderr, + "ERROR!! Could not create association for: %s\n", + stoa(simulation.servers[i].addr)); + } } +} - getconfig(argc, argv); - initializing = 0; - loop_config(LOOP_DRIFTCOMP, old_drift / 1e6); +/* Main Simulator Code */ + +int +ntpsim( + int argc, + char * argv[] + ) +{ + Event * curr_event; + struct timeval seed; + + /* Initialize the local Clock */ + simclock.local_time = 0; + simclock.adj = 0; + simclock.slew = 500e-6; + + /* Initialize the simulation */ + simulation.num_of_servers = 0; + simulation.beep_delay = BEEP_DLY; + simulation.sim_time = 0; + simulation.end_time = SIM_TIME; + + /* Initialize ntp modules */ + initializing = TRUE; + msyslog_term = TRUE; + init_sim_io(); + init_auth(); + init_util(); + init_restrict(); + init_mon(); + init_timer(); + init_lib(); + init_request(); + init_control(); + init_peer(); + init_proto(); + init_loopfilter(); + mon_start(MON_OFF); + + /* Call getconfig to parse the configuration file */ + getconfig(argc, argv); + loop_config(LOOP_DRIFTINIT, 0); + initializing = FALSE; /* * Watch out here, we want the real time, not the silly stuff. @@ -91,281 +144,514 @@ ntpsim( gettimeofday(&seed, NULL); ntp_srandom(seed.tv_usec); - /* - * Push a beep and timer interrupt on the queue - */ - push(event(0, BEEP), &ntp_node.events); - push(event(ntp_node.time + 1.0, TIMER), &ntp_node.events); + /* Initialize the event queue */ + event_queue = create_priority_queue((q_order_func) + determine_event_ordering); - /* + /* Initialize the receive queue */ + recv_queue = create_priority_queue((q_order_func) + determine_recv_buf_ordering); + + /* Push a beep and a timer on the event queue */ + enqueue(event_queue, event(0, BEEP)); + enqueue(event_queue, event(simulation.sim_time + 1.0, TIMER)); + + /* * Pop the queue until nothing is left or time is exceeded */ - maxtime = ntp_node.time + ntp_node.sim_time; - while (ntp_node.time <= maxtime && ntp_node.events != NULL ) { - e = pop(&ntp_node.events); - ndeclk(&ntp_node, e); - funcPtr[e.function](&ntp_node, e); + /* maxtime = simulation.sim_time + simulation.end_time;*/ + while (simulation.sim_time <= simulation.end_time && + (!empty(event_queue))) { + curr_event = dequeue(event_queue); + /* Update all the clocks to the time on the event */ + sim_update_clocks(curr_event); + + /* Execute the function associated with the event */ + (*event_ptr[curr_event->function])(curr_event); + free_node(curr_event); } + printf("sys_received: %lu\n", sys_received); + printf("sys_badlength: %lu\n", sys_badlength); + printf("sys_declined: %lu\n", sys_declined); + printf("sys_restricted: %lu\n", sys_restricted); + printf("sys_newversion: %lu\n", sys_newversion); + printf("sys_oldversion: %lu\n", sys_oldversion); + printf("sys_limitrejected: %lu\n", sys_limitrejected); + printf("sys_badauth: %lu\n", sys_badauth); + return (0); } -/* - * Return an event - */ -Event -event( - double t, - funcTkn f - ) +void +init_sim_io(void) { - Event e; - - e.time = t; - e.function = f; - return (e); + loopback_interface = emalloc_zero(sizeof(*loopback_interface)); + ep_list = loopback_interface; + strlcpy(loopback_interface->name, "IPv4loop", + sizeof(loopback_interface->name)); + loopback_interface->flags = INT_UP | INT_LOOPBACK; + loopback_interface->fd = -1; + loopback_interface->bfd = -1; + loopback_interface->ifnum = 1; + loopback_interface->family = AF_INET; + AF(&loopback_interface->sin) = AF_INET; + SET_ADDR4(&loopback_interface->sin, LOOPBACKADR); + SET_PORT(&loopback_interface->sin, NTP_PORT); + AF(&loopback_interface->mask) = AF_INET; + SET_ADDR4(&loopback_interface->mask, LOOPNETMASK); } -/* - * Create an event queue - */ -Queue -queue( - Event e, - Queue q - ) + +/* Define a function to create an return an Event */ + +Event *event(double t, funcTkn f) { - Queue ret; + Event *e; - if ((ret = (Queue)malloc(sizeof(struct List))) == NULL) - abortsim("queue-malloc"); - ret->event = e; - ret->next = q; - return (ret); + if ((e = get_node(sizeof(*e))) == NULL) + abortsim("get_node failed in event"); + e->time = t; + e->function = f; + return (e); } +/* NTP SIMULATION FUNCTIONS */ -/* - * Push an event into the event queue +/* Define a function for processing a timer interrupt. + * On every timer interrupt, call the NTP timer to send packets and process + * the clock and then call the receive function to receive packets. */ -void push( - Event e, - Queue *qp - ) +void sim_event_timer(Event *e) { - Queue *tmp = qp; - - while (*tmp != NULL && ((*tmp)->event.time < e.time)) - tmp = &((*tmp)->next); - *tmp = queue(e, (*tmp)); + struct recvbuf *rbuf; + + /* Call the NTP timer. + * This will be responsible for actually "sending the packets." + * Since this is a simulation, the packets sent over the network + * will be processed by the simulate_server routine below. + */ + timer(); + + /* Process received buffers */ + while (!empty(recv_queue)) { + rbuf = (struct recvbuf *)dequeue(recv_queue); + (*rbuf->receiver)(rbuf); + free_node(rbuf); + } + + /* Arm the next timer interrupt. */ + enqueue(event_queue, + event(simulation.sim_time + (1 << EVENT_TIMEOUT), TIMER)); } -/* - * Pop the first event from the event queue + +/* Define a function to simulate a server. + * This function processes the sent packet according to the server script, + * creates a reply packet and pushes the reply packet onto the event queue */ -Event -pop( - Queue *qp - ) +int simulate_server( + sockaddr_u *serv_addr, /* Address of the server */ + endpt * inter, /* Interface on which the reply should + be inserted */ + struct pkt *rpkt /* Packet sent to the server that + needs to be processed. */ + ) { - Event ret; - Queue tmp; - - tmp = *qp; - if (tmp == NULL) - abortsim("pop - empty queue"); - ret = tmp->event; - *qp = tmp->next; - free(tmp); - return (ret); + struct pkt xpkt; /* Packet to be transmitted back + to the client */ + struct recvbuf rbuf; /* Buffer for the received packet */ + Event *e; /* Packet receive event */ + server_info *server; /* Pointer to the server being simulated */ + script_info *curr_script; /* Current script being processed */ + int i; + double d1, d2, d3; /* Delays while the packet is enroute */ + double t1, t2, t3, t4; /* The four timestamps in the packet */ + l_fp lfp_host; /* host-order l_fp */ + + ZERO(xpkt); + ZERO(rbuf); + + /* Search for the server with the desired address */ + server = NULL; + for (i = 0; i < simulation.num_of_servers; ++i) { + if (memcmp(simulation.servers[i].addr, serv_addr, + sizeof(*serv_addr)) == 0) { + server = &simulation.servers[i]; + break; + } + } + + fprintf(stderr, "Received packet from %s on %s\n", + stoa(serv_addr), latoa(inter)); + if (server == NULL) + abortsim("Server with specified address not found!!!"); + + /* Get the current script for the server */ + curr_script = server->curr_script; + + /* Create a server reply packet. + * Masquerade the reply as a stratum-1 server with a GPS clock + */ + xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, NTP_VERSION, + MODE_SERVER); + xpkt.stratum = STRATUM_TO_PKT(((u_char)1)); + memcpy(&xpkt.refid, "GPS", 4); + xpkt.ppoll = rpkt->ppoll; + xpkt.precision = rpkt->precision; + xpkt.rootdelay = 0; + xpkt.rootdisp = 0; + + /* TIMESTAMP CALCULATIONS + t1 t4 + \ / + d1 \ / d3 + \ / + t2 ----------------- t3 + d2 + */ + /* Compute the delays */ + d1 = poisson(curr_script->prop_delay, curr_script->jitter); + d2 = poisson(curr_script->proc_delay, 0); + d3 = poisson(curr_script->prop_delay, curr_script->jitter); + + /* Note: In the transmitted packet: + * 1. t1 and t4 are times in the client according to the local clock. + * 2. t2 and t3 are server times according to the simulated server. + * Compute t1, t2, t3 and t4 + * Note: This function is called at time t1. + */ + + NTOHL_FP(&rpkt->xmt, &lfp_host); + LFPTOD(&lfp_host, t1); + t2 = server->server_time + d1; + t3 = server->server_time + d1 + d2; + t4 = t1 + d1 + d2 + d3; + + /* Save the timestamps */ + xpkt.org = rpkt->xmt; + DTOLFP(t2, &lfp_host); + HTONL_FP(&lfp_host, &xpkt.rec); + DTOLFP(t3, &lfp_host); + HTONL_FP(&lfp_host, &xpkt.xmt); + xpkt.reftime = xpkt.xmt; + + /* + * Ok, we are done with the packet. Now initialize the receive + * buffer for the packet. + */ + rbuf.used = 1; + rbuf.receiver = &receive; /* callback to process the packet */ + rbuf.recv_length = LEN_PKT_NOMAC; + rbuf.recv_pkt = xpkt; + rbuf.dstadr = inter; + rbuf.fd = inter->fd; + memcpy(&rbuf.srcadr, serv_addr, sizeof(rbuf.srcadr)); + memcpy(&rbuf.recv_srcadr, serv_addr, sizeof(rbuf.recv_srcadr)); + + /* + * Create a packet event and insert it onto the event_queue at the + * arrival time (t4) of the packet at the client + */ + e = event(t4, PACKET); + e->rcv_buf = rbuf; + enqueue(event_queue, e); + + /* + * Check if the time of the script has expired. If yes, delete it. + */ + if (curr_script->duration > simulation.sim_time && + NULL == HEAD_PFIFO(server->script)) { + printf("Hello\n"); + /* + * For some reason freeing up the curr_script memory kills the + * simulation. Further debugging is needed to determine why. + * free(curr_script); + */ + UNLINK_FIFO(curr_script, *server->script, link); + } + + return (0); } -/* - * Update clocks +/* Define a function to update all the clocks + * Most of the code is modified from the systime.c file by Prof. Mills */ -void -ndeclk( - Node *n, - Event e - ) + +void sim_update_clocks(Event *e) { - node_clock(n, e.time); + double time_gap; + double adj; + int i; + + /* Compute the time between the last update event and this update */ + time_gap = e->time - simulation.sim_time; + + if (time_gap < 0) + printf("WARNING: e->time %.6g comes before sim_time %.6g (gap %+.6g)\n", + e->time, simulation.sim_time, time_gap); + + /* Advance the client clock */ + if (e->time + time_gap < simclock.local_time) + printf("WARNING: e->time + gap %.6g comes before local_time %.6g\n", + e->time + time_gap, simclock.local_time); + simclock.local_time = e->time + time_gap; + + /* Advance the simulation time */ + simulation.sim_time = e->time; + + /* Advance the server clocks adjusted for systematic and random frequency + * errors. The random error is a random walk computed as the + * integral of samples from a Gaussian distribution. + */ + for (i = 0; i < simulation.num_of_servers; ++i) { + simulation.servers[i].curr_script->freq_offset += + gauss(0, time_gap * simulation.servers[i].curr_script->wander); + + simulation.servers[i].server_time += time_gap * + (1 + simulation.servers[i].curr_script->freq_offset); + } + + /* Perform the adjtime() function. If the adjustment completed + * in the previous interval, amortize the entire amount; if not, + * carry the leftover to the next interval. + */ + + adj = time_gap * simclock.slew; + if (adj < fabs(simclock.adj)) { + if (simclock.adj < 0) { + simclock.adj += adj; + simclock.local_time -= adj; + } else { + simclock.adj -= adj; + simclock.local_time += adj; + } + } else { + simclock.local_time += simclock.adj; + simclock.adj = 0; + } } -/* - * Timer interrupt. Eventually, this results in calling the - * srvr_rplyi() routine below. - */ -void -ntptmr( - Node *n, - Event e - ) +/* Define a function that processes a receive packet event. + * This function simply inserts the packet received onto the receive queue + */ + +void sim_event_recv_packet(Event *e) { - struct recvbuf *rbuf; + struct recvbuf *rbuf; - timer(); + /* Allocate a receive buffer and copy the packet to it */ + if ((rbuf = get_node(sizeof(*rbuf))) == NULL) + abortsim("get_node failed in sim_event_recv_packet"); + memcpy(rbuf, &e->rcv_buf, sizeof(*rbuf)); - /* - * Process buffers received. They had better be in order by - * receive timestamp. Note that there are no additional buffers - * in the current implementation of ntpsim. - */ - while (n->rbuflist != NULL) { - rbuf = n->rbuflist; - n->rbuflist = NULL; - (rbuf->receiver)(rbuf); - free(rbuf); - } + /* Store the local time in the received packet */ + DTOLFP(simclock.local_time, &rbuf->recv_time); - /* - * Arm the next timer interrupt. - */ - push(event(e.time + (1 << EVENT_TIMEOUT), TIMER), &n->events); + /* Insert the packet received onto the receive queue */ + enqueue(recv_queue, rbuf); } -/* - * srvr_rply() - send packet + +/* Define a function to output simulation statistics on a beep event */ -int srvr_rply( - Node *n, - struct sockaddr_storage *dest, - struct interface *inter, struct pkt *rpkt - ) + +/*** TODO: Need to decide on how to output for multiple servers ***/ +void sim_event_beep(Event *e) { - struct pkt xpkt; - struct recvbuf rbuf; - Event xvnt; - double dtemp, etemp; +#if 0 + static int first_time = 1; + char *dash = "-----------------"; +#endif + + fprintf(stderr, "BEEP!!!\n"); + enqueue(event_queue, event(e->time + simulation.beep_delay, BEEP)); +#if 0 + if(simulation.beep_delay > 0) { + if (first_time) { + printf("\t%4c T %4c\t%4c T+ERR %3c\t%5cT+ERR+NTP\n", + ' ', ' ', ' ', ' ',' '); + printf("\t%s\t%s\t%s\n", dash, dash, dash); + first_time = 0; + + printf("\t%16.6f\t%16.6f\t%16.6f\n", + n->time, n->clk_time, n->ntp_time); + return; + } + printf("\t%16.6f\t%16.6f\t%16.6f\n", + simclock.local_time, + n->time, n->clk_time, n->ntp_time); +#endif - /* - * Insert packet header values. We make this look like a - * stratum-1 server with a GPS clock, but nobody will ever - * notice that. - */ - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOWARNING, NTP_VERSION, - MODE_SERVER); - xpkt.stratum = STRATUM_TO_PKT(((u_char)1)); - memcpy(&xpkt.refid, "GPS", 4); - xpkt.ppoll = rpkt->ppoll; - xpkt.precision = rpkt->precision; - xpkt.rootdelay = 0; - xpkt.rootdispersion = 0; +} - /* - * Insert the timestamps. - */ - xpkt.org = rpkt->xmt; - dtemp = poisson(n->ndly, n->snse); /* client->server delay */ - DTOLFP(dtemp + n->clk_time, &xpkt.rec); - dtemp += poisson(n->pdly, 0); /* server delay */ - DTOLFP(dtemp + n->clk_time, &xpkt.xmt); - xpkt.reftime = xpkt.xmt; - dtemp += poisson(n->ndly, n->snse); /* server->client delay */ - /* - * Insert the I/O stuff. - */ - rbuf.receiver = receive; - get_systime(&rbuf.recv_time); - rbuf.recv_length = LEN_PKT_NOMAC; - rbuf.recv_pkt = xpkt; - memcpy(&rbuf.srcadr, dest, sizeof(struct sockaddr_storage)); - memcpy(&rbuf.recv_srcadr, dest, - sizeof(struct sockaddr_storage)); - if ((rbuf.dstadr = malloc(sizeof(struct interface))) == NULL) - abortsim("server-malloc"); - memcpy(rbuf.dstadr, inter, sizeof(struct interface)); +/* Define a function to abort the simulation on an error and spit out an + * error message + */ - /* - * Very carefully predict the time of arrival for the received - * packet. - */ - LFPTOD(&xpkt.org, etemp); - etemp += dtemp; - xvnt = event(etemp, PACKET); - xvnt.rcv_buf = rbuf; - push(xvnt, &n->events); - return (0); +void abortsim(char *errmsg) +{ + perror(errmsg); + exit(1); } + +/* CODE ORIGINALLY IN libntp/systime.c + * ----------------------------------- + * This code was a part of the original NTP simulator and originally + * had its home in the libntp/systime.c file. + * + * It has been shamelessly moved to here and has been modified for the + * purposes of the current simulator. + */ + + /* - * netpkt() - receive packet + * get_systime - return the system time in NTP timestamp format */ void -netpkt( - Node *n, - Event e - ) +get_systime( + l_fp *now /* current system time in l_fp */ ) { - struct recvbuf *rbuf; - struct recvbuf *obuf; - - /* - * Insert the packet on the receive queue and record the arrival - * time. - */ - if ((rbuf = malloc(sizeof(struct recvbuf))) == NULL) - abortsim("ntprcv-malloc"); - memcpy(rbuf, &e.rcv_buf, sizeof(struct recvbuf)); - rbuf->receiver = receive; - DTOLFP(n->ntp_time, &rbuf->recv_time); - obuf = n->rbuflist; - - /* - * In the present incarnation, no more than one buffer can be on - * the queue; - */ - if (obuf == NULL) { - n->rbuflist = rbuf; - } + /* + * To fool the code that determines the local clock precision, + * we advance the clock a minimum of 200 nanoseconds on every + * clock read. This is appropriate for a typical modern machine + * with nanosecond clocks. Note we make no attempt here to + * simulate reading error, since the error is so small. This may + * change when the need comes to implement picosecond clocks. + */ + if (simclock.local_time == simclock.last_read_time) + simclock.local_time += 200e-9; + + simclock.last_read_time = simclock.local_time; + DTOLFP(simclock.local_time, now); +/* OLD Code + if (ntp_node.ntp_time == ntp_node.last_time) + ntp_node.ntp_time += 200e-9; + ntp_node.last_time = ntp_node.ntp_time; + DTOLFP(ntp_node.ntp_time, now); +*/ } - - + + /* - * ndbeep() - progress indicator + * adj_systime - advance or retard the system clock exactly like the + * real thng. */ -void -ndbeep( - Node *n, - Event e - ) +int /* always succeeds */ +adj_systime( + double now /* time adjustment (s) */ + ) { - static int first_time = 1; - char *dash = "-----------------"; - - if(n->bdly > 0) { - if (first_time) { - printf( - "\t%4c T %4c\t%4c T+ERR %3c\t%5cT+ERR+NTP\n", ' ', ' ', ' ', ' ',' '); - printf("\t%s\t%s\t%s\n", dash, dash, dash); - first_time = 0; - push(event(n->bdly, BEEP), &n->events); - push(event(n->sim_time, BEEP), &n->events); - printf("\t%16.6f\t%16.6f\t%16.6f\n", - n->time, n->clk_time, n->ntp_time); - return; - } - printf("\t%16.6f\t%16.6f\t%16.6f\n", - n->time, n->clk_time, n->ntp_time); - push(event(e.time + n->bdly, BEEP), &n->events); - } + struct timeval adjtv; /* new adjustment */ + double dtemp; + long ticks; + int isneg = 0; + + /* + * Most Unix adjtime() implementations adjust the system clock + * in microsecond quanta, but some adjust in 10-ms quanta. We + * carefully round the adjustment to the nearest quantum, then + * adjust in quanta and keep the residue for later. + */ + dtemp = now + sys_residual; + if (dtemp < 0) { + isneg = 1; + dtemp = -dtemp; + } + adjtv.tv_sec = (long)dtemp; + dtemp -= adjtv.tv_sec; + ticks = (long)(dtemp / sys_tick + .5); + adjtv.tv_usec = (long)(ticks * sys_tick * 1e6); + dtemp -= adjtv.tv_usec / 1e6; + sys_residual = dtemp; + + /* + * Convert to signed seconds and microseconds for the Unix + * adjtime() system call. Note we purposely lose the adjtime() + * leftover. + */ + if (isneg) { + adjtv.tv_sec = -adjtv.tv_sec; + adjtv.tv_usec = -adjtv.tv_usec; + sys_residual = -sys_residual; + } + simclock.adj = now; +/* ntp_node.adj = now; */ + return (1); +} + + +/* + * step_systime - step the system clock. We are religious here. + */ +int /* always succeeds */ +step_systime( + double now /* step adjustment (s) */ + ) +{ +#ifdef DEBUG + if (debug) + printf("step_systime: time %.6f adj %.6f\n", + simclock.local_time, now); +#endif + simclock.local_time += now; + return (1); +} + +/* + * gauss() - returns samples from a gaussion distribution + */ +double /* Gaussian sample */ +gauss( + double m, /* sample mean */ + double s /* sample standard deviation (sigma) */ + ) +{ + double q1, q2; + + /* + * Roll a sample from a Gaussian distribution with mean m and + * standard deviation s. For m = 0, s = 1, mean(y) = 0, + * std(y) = 1. + */ + if (s == 0) + return (m); + while ((q1 = drand48()) == 0) + /* empty statement */; + q2 = drand48(); + return (m + s * sqrt(-2. * log(q1)) * cos(2. * PI * q2)); } - + /* - * Abort simulation + * poisson() - returns samples from a network delay distribution */ -void -abortsim( - char *errmsg - ) +double /* delay sample (s) */ +poisson( + double m, /* fixed propagation delay (s) */ + double s /* exponential parameter (mu) */ + ) { - perror(errmsg); - exit(1); + double q1; + + /* + * Roll a sample from a composite distribution with propagation + * delay m and exponential distribution time with parameter s. + * For m = 0, s = 1, mean(y) = std(y) = 1. + */ + if (s == 0) + return (m); + while ((q1 = drand48()) == 0) + /* empty statement */; + return (m - s * log(q1 * s)); } + +#endif diff --git a/contrib/ntp/ntpd/rc_cmdlength.c b/contrib/ntp/ntpd/rc_cmdlength.c new file mode 100644 index 000000000..922312e62 --- /dev/null +++ b/contrib/ntp/ntpd/rc_cmdlength.c @@ -0,0 +1,36 @@ +#include +#include + +#if HAVE_UNISTD_H +# include +#endif + + +/* Bug 2853 */ +/* evaluate the length of the command sequence. This breaks at the first + * char that is not >= SPACE and <= 127 after trimming from the right. + */ +size_t +remoteconfig_cmdlength( + const char *src_buf, + const char *src_end + ) +{ + const char *scan; + unsigned char ch; + + /* trim whitespace & garbage from the right */ + while (src_end != src_buf) { + ch = src_end[-1]; + if (ch > ' ' && ch < 128) + break; + --src_end; + } + /* now do a forward scan */ + for (scan = src_buf; scan != src_end; ++scan) { + ch = scan[0]; + if ((ch < ' ' || ch >= 128) && ch != '\t') + break; + } + return (size_t)(scan - src_buf); +} diff --git a/contrib/ntp/ntpd/refclock_acts.c b/contrib/ntp/ntpd/refclock_acts.c index 57f2ca7c7..f62cc466b 100644 --- a/contrib/ntp/ntpd/refclock_acts.c +++ b/contrib/ntp/ntpd/refclock_acts.c @@ -6,7 +6,7 @@ #include #endif -#if defined(REFCLOCK) && (defined(CLOCK_ACTS) || defined(CLOCK_PTBACTS)) +#if defined(REFCLOCK) && defined(CLOCK_ACTS) #include "ntpd.h" #include "ntp_io.h" @@ -21,6 +21,12 @@ # include #endif /* HAVE_SYS_IOCTL_H */ +#ifdef SYS_WINNT +#undef write /* ports/winnt/include/config.h: #define write _write */ +extern int async_write(int, const void *, unsigned int); +#define write(fd, data, octets) async_write(fd, data, octets) +#endif + /* * This driver supports the US (NIST, USNO) and European (PTB, NPL, * etc.) modem time services, as well as Spectracom GPS and WWVB @@ -33,20 +39,19 @@ * This driver requires a modem with a Hayes-compatible command set and * control over the modem data terminal ready (DTR) control line. The * modem setup string is hard-coded in the driver and may require - * changes for nonstandard modems or special circumstances. For reasons - * unrelated to this driver, the data set ready (DSR) control line - * should not be set when this driver is first started. + * changes for nonstandard modems or special circumstances. * - * The calling program is initiated by setting fudge flag1, either - * manually or automatically. When flag1 is set, the calling program - * dials the first number in the phone command of the configuration - * file. If that call fails, the calling program dials the second number - * and so on. The number is specified by the Hayes ATDT prefix followed - * by the number itself, including the prefix and long-distance digits - * and delay code, if necessary. The flag1 is reset and the calling - * program terminated if (a) a valid clock update has been determined, - * (b) no more numbers remain in the list, (c) a device fault or timeout - * occurs or (d) fudge flag1 is reset manually. + * When enabled, the calling program dials the first number in the + * phones file. If that call fails, it dials the second number and + * so on. The phone number is specified by the Hayes ATDT prefix + * followed by the number itself, including the long-distance prefix + * and delay code, if necessary. The calling program is enabled + * when (a) fudge flag1 is set by ntpdc, (b) at each poll interval + * when no other synchronization sources are present, and (c) at each + * poll interval whether or not other synchronization sources are + * present. The calling program disconnects if (a) the called party + * is busy or does not answer, (b) the called party disconnects + * before a sufficient nuimber of timecodes have been received. * * The driver is transparent to each of the modem time services and * Spectracom radios. It selects the parsing algorithm depending on the @@ -59,18 +64,17 @@ * * flag1 force a call in manual mode * flag2 enable port locking (not verified) - * flag3 no modem; port is directly connected to device + * flag3 not used * flag4 not used * * time1 offset adjustment (s) * - * Ordinarily, the serial port is connected to a modem; however, it can - * be connected directly to a device or another computer for testing and - * calibration. In this case set fudge flag3 and the driver will send a - * single character 'T' at each poll event. In principle, fudge flag2 - * enables port locking, allowing the modem to be shared when not in use - * by this driver. At least on Solaris with the current NTP I/O - * routines, this results only in lots of ugly error messages. + * Ordinarily, the serial port is connected to a modem and the phones + * list is defined. If no phones list is defined, the port can be + * connected directly to a device or another computer. In this case the + * driver will send a single character 'T' at each poll event. If + * fudge flag2 is enabled, port locking allows the modem to be shared + * when not in use by this driver. */ /* * National Institute of Science and Technology (NIST) @@ -89,7 +93,9 @@ * * MJD, DST, DUT1 and UTC are not used by this driver. The "*" or "#" is * the on-time markers echoed by the driver and used by NIST to measure - * and correct for the propagation delay. + * and correct for the propagation delay. Note: the ACTS timecode has + * recently been changed to eliminate the * on-time indicator. The + * reason for this and the long term implications are not clear. * * US Naval Observatory (USNO) * @@ -129,26 +135,26 @@ * Interface definitions */ #define DEVICE "/dev/acts%d" /* device name and unit */ -#define SPEED232 B9600 /* uart speed (9600 baud) */ +#define SPEED232 B19200 /* uart speed (19200 bps) */ #define PRECISION (-10) /* precision assumed (about 1 ms) */ -#define LOCKFILE "/var/spool/locks/LCK..cua%d" +#define LOCKFILE "/var/spool/lock/LCK..cua%d" #define DESCRIPTION "Automated Computer Time Service" /* WRU */ #define REFID "NONE" /* default reference ID */ #define MSGCNT 20 /* max message count */ -#define SMAX 256 /* max clockstats line length */ +#define MAXPHONE 10 /* max number of phone numbers */ /* - * Calling program modes + * Calling program modes (mode) */ -#define MODE_AUTO 0 /* automatic mode */ -#define MODE_BACKUP 1 /* backup mode */ +#define MODE_BACKUP 0 /* backup mode */ +#define MODE_AUTO 1 /* automatic mode */ #define MODE_MANUAL 2 /* manual mode */ /* - * Service identifiers. + * Service identifiers (message length) */ #define REFACTS "NIST" /* NIST reference ID */ -#define LENACTS 50 /* NIST format */ +#define LENACTS 50 /* NIST format A */ #define REFUSNO "USNO" /* USNO reference ID */ #define LENUSNO 20 /* USNO */ #define REFPTB "PTB\0" /* PTB/NPL reference ID */ @@ -159,40 +165,41 @@ #define LF 0x0a /* ASCII LF */ /* - * Modem setup strings. These may have to be changed for some modems. + * Modem setup strings. These may have to be changed for + * some modems. * * AT command prefix * B1 US answer tone * &C0 disable carrier detect * &D2 hang up and return to command mode on DTR transition * E0 modem command echo disabled - * l1 set modem speaker volume to low level + * L1 set modem speaker volume to low level * M1 speaker enabled until carrier detect * Q0 return result codes * V1 return result codes as English words + * Y1 enable long-space disconnect */ -#define MODEM_SETUP "ATB1&C0&D2E0L1M1Q0V1\r" /* modem setup */ -#define MODEM_HANGUP "ATH\r" /* modem disconnect */ +const char def_modem_setup[] = "ATB1&C0&D2E0L1M1Q0V1Y1"; +const char *modem_setup = def_modem_setup; /* * Timeouts (all in seconds) */ #define SETUP 3 /* setup timeout */ -#define DTR 1 /* DTR timeout */ +#define REDIAL 30 /* redial timeout */ #define ANSWER 60 /* answer timeout */ -#define CONNECT 20 /* first valid message timeout */ -#define TIMECODE 30 /* all valid messages timeout */ +#define TIMECODE 60 /* message timeout */ +#define MAXCODE 20 /* max timecodes */ /* * State machine codes */ -#define S_IDLE 0 /* wait for poll */ -#define S_OK 1 /* wait for modem setup */ -#define S_DTR 2 /* wait for modem DTR */ -#define S_CONNECT 3 /* wait for answer*/ -#define S_FIRST 4 /* wait for first valid message */ -#define S_MSG 5 /* wait for all messages */ -#define S_CLOSE 6 /* wait after sending disconnect */ +typedef enum { + S_IDLE, /* wait for poll */ + S_SETUP, /* send modem setup */ + S_CONNECT, /* wait for answer */ + S_MSG /* wait for timecode */ +} teModemState; /* * Unit control structure @@ -204,26 +211,27 @@ struct actsunit { int retry; /* retry index */ int msgcnt; /* count of messages received */ l_fp tstamp; /* on-time timestamp */ - char *bufptr; /* buffer pointer */ + char *bufptr; /* next incoming char stored here */ + char buf[BMAX]; /* bufptr roams within buf[] */ }; /* * Function prototypes */ -static int acts_start P((int, struct peer *)); -static void acts_shutdown P((int, struct peer *)); -static void acts_receive P((struct recvbuf *)); -static void acts_message P((struct peer *)); -static void acts_timecode P((struct peer *, char *)); -static void acts_poll P((int, struct peer *)); -static void acts_timeout P((struct peer *)); -static void acts_disc P((struct peer *)); -static void acts_timer P((int, struct peer *)); +static int acts_start (int, struct peer *); +static void acts_shutdown (int, struct peer *); +static void acts_receive (struct recvbuf *); +static void acts_message (struct peer *, const char *); +static void acts_timecode (struct peer *, const char *); +static void acts_poll (int, struct peer *); +static void acts_timeout (struct peer *, teModemState); +static void acts_timer (int, struct peer *); +static void acts_close (struct peer *); /* * Transfer vector (conditional structure name) */ -struct refclock refclock_acts = { +struct refclock refclock_acts = { acts_start, /* start up driver */ acts_shutdown, /* shut down driver */ acts_poll, /* transmit poll message */ @@ -233,44 +241,45 @@ struct refclock refclock_acts = { acts_timer /* housekeeping timer */ }; -struct refclock refclock_ptb; - /* * Initialize data for processing */ static int -acts_start ( +acts_start( int unit, struct peer *peer ) { struct actsunit *up; struct refclockproc *pp; + const char *setup; /* * Allocate and initialize unit structure */ - up = emalloc(sizeof(struct actsunit)); - if (up == NULL) - return (0); - - memset(up, 0, sizeof(struct actsunit)); + up = emalloc_zero(sizeof(struct actsunit)); up->unit = unit; pp = peer->procptr; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->io.clock_recv = acts_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; + pp->io.fd = -1; /* * Initialize miscellaneous variables */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); peer->sstclktype = CTL_SST_TS_TELEPHONE; - peer->flags &= ~FLAG_FIXPOLL; - up->bufptr = pp->a_lastcode; + up->bufptr = up->buf; + if (def_modem_setup == modem_setup) { + setup = get_ext_sys_var("modemsetup"); + if (setup != NULL) + modem_setup = estrdup(setup); + } + return (1); } @@ -279,7 +288,7 @@ acts_start ( * acts_shutdown - shut down the clock */ static void -acts_shutdown ( +acts_shutdown( int unit, struct peer *peer ) @@ -291,7 +300,8 @@ acts_shutdown ( * Warning: do this only when a call is not in progress. */ pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; + up = pp->unitptr; + acts_close(peer); free(up); } @@ -300,15 +310,16 @@ acts_shutdown ( * acts_receive - receive data from the serial interface */ static void -acts_receive ( +acts_receive( struct recvbuf *rbufp ) { struct actsunit *up; struct refclockproc *pp; struct peer *peer; - char tbuf[BMAX]; - char *tptr; + char tbuf[sizeof(up->buf)]; + char * tptr; + int octets; /* * Initialize pointers and read the timecode and timestamp. Note @@ -317,27 +328,27 @@ acts_receive ( * arbitrary fragments. Capture the timecode at the beginning of * the message and at the '*' and '#' on-time characters. */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; - pp->lencode = refclock_gtraw(rbufp, tbuf, BMAX - (up->bufptr - - pp->a_lastcode), &pp->lastrec); + up = pp->unitptr; + octets = sizeof(up->buf) - (up->bufptr - up->buf); + refclock_gtraw(rbufp, tbuf, octets, &pp->lastrec); for (tptr = tbuf; *tptr != '\0'; tptr++) { if (*tptr == LF) { - if (up->bufptr == pp->a_lastcode) { + if (up->bufptr == up->buf) { up->tstamp = pp->lastrec; continue; - } else { *up->bufptr = '\0'; - acts_message(peer); - up->bufptr = pp->a_lastcode; + up->bufptr = up->buf; + acts_message(peer, up->buf); } - } else if (!iscntrl(*tptr)) { + } else if (!iscntrl((unsigned char)*tptr)) { *up->bufptr++ = *tptr; if (*tptr == '*' || *tptr == '#') { up->tstamp = pp->lastrec; - write(pp->io.fd, tptr, 1); + if (write(pp->io.fd, tptr, 1) < 0) + msyslog(LOG_ERR, "acts: write echo fails %m"); } } } @@ -349,74 +360,361 @@ acts_receive ( */ void acts_message( - struct peer *peer + struct peer *peer, + const char *msg ) { struct actsunit *up; struct refclockproc *pp; - int dtr = TIOCM_DTR; - char tbuf[SMAX]; -#ifdef DEBUG - u_int modem; -#endif + char tbuf[BMAX]; + int dtr = TIOCM_DTR; + + DPRINTF(1, ("acts: %d %s\n", (int)strlen(msg), msg)); /* * What to do depends on the state and the first token in the - * message. A NO token sends the message to the clockstats. + * message. */ pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; -#ifdef DEBUG - ioctl(pp->io.fd, TIOCMGET, (char *)&modem); - sprintf(tbuf, "acts: %04x (%d %d) %lu %s", modem, up->state, - up->timer, strlen(pp->a_lastcode), pp->a_lastcode); - if (debug) - printf("%s\n", tbuf); -#endif - strncpy(tbuf, pp->a_lastcode, SMAX); + up = pp->unitptr; + + /* + * Extract the first token in the line. + */ + strlcpy(tbuf, msg, sizeof(tbuf)); strtok(tbuf, " "); - if (strcmp(tbuf, "NO") == 0) - record_clock_stats(&peer->srcadr, pp->a_lastcode); - switch(up->state) { + switch (up->state) { /* * We are waiting for the OK response to the modem setup - * command. When this happens, raise DTR and dial the number - * followed by \r. + * command. When this happens, dial the number followed. + * If anything other than OK is received, just ignore it + * and wait for timeoue. */ - case S_OK: + case S_SETUP: if (strcmp(tbuf, "OK") != 0) { - msyslog(LOG_ERR, "acts: setup error %s", - pp->a_lastcode); - acts_disc(peer); - return; + /* + * We disable echo with MODEM_SETUP's E0 but + * if the modem was previously E1, we will + * see MODEM_SETUP echoed before the OK/ERROR. + * Ignore it. + */ + if (!strcmp(tbuf, modem_setup)) + return; + break; } - ioctl(pp->io.fd, TIOCMBIS, (char *)&dtr); - up->state = S_DTR; - up->timer = DTR; + + mprintf_event(PEVNT_CLOCK, peer, "DIAL #%d %s", + up->retry, sys_phone[up->retry]); + if (ioctl(pp->io.fd, TIOCMBIS, &dtr) < 0) + msyslog(LOG_ERR, "acts: ioctl(TIOCMBIS) failed: %m"); + if (write(pp->io.fd, sys_phone[up->retry], + strlen(sys_phone[up->retry])) < 0) + msyslog(LOG_ERR, "acts: write DIAL fails %m"); + write(pp->io.fd, "\r", 1); + up->retry++; + up->state = S_CONNECT; + up->timer = ANSWER; return; /* - * We are waiting for the call to be answered. All we care about - * here is token CONNECT. Send the message to the clockstats. + * We are waiting for the CONNECT response to the dial + * command. When this happens, listen for timecodes. If + * somthing other than CONNECT is received, like BUSY + * or NO CARRIER, abort the call. */ case S_CONNECT: - record_clock_stats(&peer->srcadr, pp->a_lastcode); - if (strcmp(tbuf, "CONNECT") != 0) { - acts_disc(peer); + if (strcmp(tbuf, "CONNECT") != 0) + break; + + report_event(PEVNT_CLOCK, peer, msg); + up->state = S_MSG; + up->timer = TIMECODE; + return; + + /* + * We are waiting for a timecode response. Pass it to + * the parser. If NO CARRIER is received, save the + * messages and abort the call. + */ + case S_MSG: + if (strcmp(tbuf, "NO") == 0) + report_event(PEVNT_CLOCK, peer, msg); + if (up->msgcnt < MAXCODE) + acts_timecode(peer, msg); + else + acts_timeout(peer, S_MSG); + return; + } + + /* + * Other response. Tell us about it. + */ + report_event(PEVNT_CLOCK, peer, msg); + acts_close(peer); +} + + +/* + * acts_timeout - called on timeout + */ +static void +acts_timeout( + struct peer *peer, + teModemState dstate + ) +{ + struct actsunit *up; + struct refclockproc *pp; + int fd; + int rc; + char device[20]; + char lockfile[128], pidbuf[8]; + + /* + * The state machine is driven by messages from the modem, + * when first started and at timeout. + */ + pp = peer->procptr; + up = pp->unitptr; + switch (dstate) { + + /* + * System poll event. Lock the modem port, open the device + * and send the setup command. + */ + case S_IDLE: + if (-1 != pp->io.fd) + return; /* port is already open */ + + /* + * Lock the modem port. If busy, retry later. Note: if + * something fails between here and the close, the lock + * file may not be removed. + */ + if (pp->sloppyclockflag & CLK_FLAG2) { + snprintf(lockfile, sizeof(lockfile), LOCKFILE, + up->unit); + fd = open(lockfile, O_WRONLY | O_CREAT | O_EXCL, + 0644); + if (fd < 0) { + report_event(PEVNT_CLOCK, peer, "acts: port busy"); + return; + } + snprintf(pidbuf, sizeof(pidbuf), "%d\n", + (u_int)getpid()); + if (write(fd, pidbuf, strlen(pidbuf)) < 0) + msyslog(LOG_ERR, "acts: write lock fails %m"); + close(fd); + } + + /* + * Open the device in raw mode and link the I/O. + */ + snprintf(device, sizeof(device), DEVICE, + up->unit); + fd = refclock_open(device, SPEED232, LDISC_ACTS | + LDISC_RAW | LDISC_REMOTE); + if (fd < 0) { + msyslog(LOG_ERR, "acts: open fails %m"); + return; + } + pp->io.fd = fd; + if (!io_addclock(&pp->io)) { + msyslog(LOG_ERR, "acts: addclock fails"); + close(fd); + pp->io.fd = -1; + return; + } + up->msgcnt = 0; + up->bufptr = up->buf; + + /* + * If the port is directly connected to the device, skip + * the modem business and send 'T' for Spectrabum. + */ + if (sys_phone[up->retry] == NULL) { + if (write(pp->io.fd, "T", 1) < 0) + msyslog(LOG_ERR, "acts: write T fails %m"); + up->state = S_MSG; + up->timer = TIMECODE; return; } - up->state = S_FIRST; - up->timer = CONNECT; + + /* + * Initialize the modem. This works with Hayes- + * compatible modems. + */ + mprintf_event(PEVNT_CLOCK, peer, "SETUP %s", + modem_setup); + rc = write(pp->io.fd, modem_setup, strlen(modem_setup)); + if (rc < 0) + msyslog(LOG_ERR, "acts: write SETUP fails %m"); + write(pp->io.fd, "\r", 1); + up->state = S_SETUP; + up->timer = SETUP; return; /* - * We are waiting for a timecode. Pass it to the parser. + * In SETUP state the modem did not respond OK to setup string. + */ + case S_SETUP: + report_event(PEVNT_CLOCK, peer, "no modem"); + break; + + /* + * In CONNECT state the call did not complete. Abort the call. + */ + case S_CONNECT: + report_event(PEVNT_CLOCK, peer, "no answer"); + break; + + /* + * In MSG states no further timecodes are expected. If any + * timecodes have arrived, update the clock. In any case, + * terminate the call. */ - case S_FIRST: case S_MSG: - acts_timecode(peer, pp->a_lastcode); + if (up->msgcnt == 0) { + report_event(PEVNT_CLOCK, peer, "no timecodes"); + } else { + pp->lastref = pp->lastrec; + record_clock_stats(&peer->srcadr, pp->a_lastcode); + refclock_receive(peer); + } + break; + } + acts_close(peer); +} + + +/* + * acts_close - close and prepare for next call. + * + * In ClOSE state no further protocol actions are required + * other than to close and release the device and prepare to + * dial the next number if necessary. + */ +void +acts_close( + struct peer *peer + ) +{ + struct actsunit *up; + struct refclockproc *pp; + char lockfile[128]; + int dtr; + + pp = peer->procptr; + up = pp->unitptr; + if (pp->io.fd != -1) { + report_event(PEVNT_CLOCK, peer, "close"); + dtr = TIOCM_DTR; + if (ioctl(pp->io.fd, TIOCMBIC, &dtr) < 0) + msyslog(LOG_ERR, "acts: ioctl(TIOCMBIC) failed: %m"); + io_closeclock(&pp->io); + pp->io.fd = -1; + } + if (pp->sloppyclockflag & CLK_FLAG2) { + snprintf(lockfile, sizeof(lockfile), + LOCKFILE, up->unit); + unlink(lockfile); + } + if (up->msgcnt == 0 && up->retry > 0) { + if (sys_phone[up->retry] != NULL) { + up->state = S_IDLE; + up->timer = REDIAL; + return; + } + } + up->state = S_IDLE; + up->timer = 0; +} + + +/* + * acts_poll - called by the transmit routine + */ +static void +acts_poll( + int unit, + struct peer *peer + ) +{ + struct actsunit *up; + struct refclockproc *pp; + + /* + * This routine is called at every system poll. All it does is + * set flag1 under certain conditions. The real work is done by + * the timeout routine and state machine. + */ + pp = peer->procptr; + up = pp->unitptr; + switch (peer->ttl) { + + /* + * In manual mode the calling program is activated by the ntpdc + * program using the enable flag (fudge flag1), either manually + * or by a cron job. + */ + case MODE_MANUAL: + return; + + /* + * In automatic mode the calling program runs continuously at + * intervals determined by the poll event or specified timeout. + */ + case MODE_AUTO: break; + + /* + * In backup mode the calling program runs continuously as long + * as either no peers are available or this peer is selected. + */ + case MODE_BACKUP: + if (!(sys_peer == NULL || sys_peer == peer)) + return; + + break; + } + pp->polls++; + if (S_IDLE == up->state) { + up->retry = 0; + acts_timeout(peer, S_IDLE); + } +} + + +/* + * acts_timer - called at one-second intervals + */ +static void +acts_timer( + int unit, + struct peer *peer + ) +{ + struct actsunit *up; + struct refclockproc *pp; + + /* + * This routine implments a timeout which runs for a programmed + * interval. The counter is initialized by the state machine and + * counts down to zero. Upon reaching zero, the state machine is + * called. If flag1 is set while timer is zero, force a call. + */ + pp = peer->procptr; + up = pp->unitptr; + if (up->timer == 0) { + if (pp->sloppyclockflag & CLK_FLAG1) { + pp->sloppyclockflag &= ~CLK_FLAG1; + acts_timeout(peer, S_IDLE); + } + } else { + up->timer--; + if (up->timer == 0) + acts_timeout(peer, up->state); } } @@ -425,8 +723,8 @@ acts_message( */ void acts_timecode( - struct peer *peer, /* peer structure pointer */ - char *str /* timecode string */ + struct peer * peer, /* peer structure pointer */ + const char * str /* timecode string */ ) { struct actsunit *up; @@ -448,7 +746,7 @@ acts_timecode( char dstchar; /* WWVB daylight/savings indicator */ int tz; /* WWVB timezone */ - u_int leapmonth; /* PTB/NPL month of leap */ + int leapmonth; /* PTB/NPL month of leap */ char leapdir; /* PTB/NPL leap direction */ /* @@ -457,9 +755,9 @@ acts_timecode( * errors due noise are forgivable. */ pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; + up = pp->unitptr; pp->nsec = 0; - switch(strlen(str)) { + switch (strlen(str)) { /* * For USNO format on-time character '*', which is on a line by @@ -472,8 +770,8 @@ acts_timecode( return; /* - * ACTS format: "jjjjj yy-mm-dd hh:mm:ss ds l uuu aaaaa - * UTC(NIST) *" + * ACTS format A: "jjjjj yy-mm-dd hh:mm:ss ds l uuu aaaaa + * UTC(NIST) *". */ case LENACTS: if (sscanf(str, @@ -484,25 +782,17 @@ acts_timecode( refclock_report(peer, CEVNT_BADREPLY); return; } - - /* - * Wait until ACTS has calculated the roundtrip delay. - * We don't need to do anything, as ACTS adjusts the - * on-time epoch. - */ - if (flag != '#') - return; - pp->day = ymd2yd(pp->year, month, day); pp->leap = LEAP_NOWARNING; if (leap == 1) - pp->leap = LEAP_ADDSECOND; - else if (pp->leap == 2) - pp->leap = LEAP_DELSECOND; + pp->leap = LEAP_ADDSECOND; + else if (leap == 2) + pp->leap = LEAP_DELSECOND; memcpy(&pp->refid, REFACTS, 4); - if (up->msgcnt == 0) - record_clock_stats(&peer->srcadr, str); up->msgcnt++; + if (flag != '#' && up->msgcnt < 10) + return; + break; /* @@ -523,10 +813,8 @@ acts_timecode( */ pp->leap = LEAP_NOWARNING; memcpy(&pp->refid, REFUSNO, 4); - if (up->msgcnt == 0) - record_clock_stats(&peer->srcadr, str); up->msgcnt++; - return; + break; /* * PTB/NPL format: "yyyy-mm-dd hh:mm:ss MEZ" @@ -543,14 +831,12 @@ acts_timecode( pp->leap = LEAP_NOWARNING; if (leapmonth == month) { if (leapdir == '+') - pp->leap = LEAP_ADDSECOND; + pp->leap = LEAP_ADDSECOND; else if (leapdir == '-') - pp->leap = LEAP_DELSECOND; + pp->leap = LEAP_DELSECOND; } pp->day = ymd2yd(pp->year, month, day); memcpy(&pp->refid, REFPTB, 4); - if (up->msgcnt == 0) - record_clock_stats(&peer->srcadr, str); up->msgcnt++; break; @@ -569,8 +855,6 @@ acts_timecode( if (synchar != ' ') pp->leap = LEAP_NOTINSYNC; memcpy(&pp->refid, REFWWVB, 4); - if (up->msgcnt == 0) - record_clock_stats(&peer->srcadr, str); up->msgcnt++; break; @@ -592,8 +876,6 @@ acts_timecode( else if (leapchar == 'L') pp->leap = LEAP_ADDSECOND; memcpy(&pp->refid, REFWWVB, 4); - if (up->msgcnt == 0) - record_clock_stats(&peer->srcadr, str); up->msgcnt++; break; @@ -613,319 +895,17 @@ acts_timecode( */ peer->refid = pp->refid; pp->lastrec = up->tstamp; - if (!refclock_process(pp)) { - refclock_report(peer, CEVNT_BADTIME); - return; - } - pp->lastref = pp->lastrec; - if (peer->disp > MAXDISTANCE) - refclock_receive(peer); - if (up->state != S_MSG) { - up->state = S_MSG; - up->timer = TIMECODE; - } -} - - -/* - * acts_poll - called by the transmit routine - */ -static void -acts_poll ( - int unit, - struct peer *peer - ) -{ - struct actsunit *up; - struct refclockproc *pp; - - /* - * This routine is called at every system poll. All it does is - * set flag1 under certain conditions. The real work is done by - * the timeout routine and state machine. - */ - pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; - switch (peer->ttl) { - - /* - * In manual mode the calling program is activated by the ntpdc - * program using the enable flag (fudge flag1), either manually - * or by a cron job. - */ - case MODE_MANUAL: - /* fall through */ - break; - - /* - * In automatic mode the calling program runs continuously at - * intervals determined by the poll event or specified timeout. - */ - case MODE_AUTO: - pp->sloppyclockflag |= CLK_FLAG1; - break; - - /* - * In backup mode the calling program runs continuously as long - * as either no peers are available or this peer is selected. - */ - case MODE_BACKUP: - if (sys_peer == NULL || sys_peer == peer) - pp->sloppyclockflag |= CLK_FLAG1; - break; - } -} - - -/* - * acts_timer - called at one-second intervals - */ -static void -acts_timer( - int unit, - struct peer *peer - ) -{ - struct actsunit *up; - struct refclockproc *pp; - - /* - * This routine implments a timeout which runs for a programmed - * interval. The counter is initialized by the state machine and - * counts down to zero. Upon reaching zero, the state machine is - * called. If flag1 is set while in S_IDLE state, force a - * timeout. - */ - pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; - if (pp->sloppyclockflag & CLK_FLAG1 && up->state == S_IDLE) { - acts_timeout(peer); - return; - } - if (up->timer == 0) - return; - - up->timer--; - if (up->timer == 0) - acts_timeout(peer); -} - - -/* - * acts_timeout - called on timeout - */ -static void -acts_timeout( - struct peer *peer - ) -{ - struct actsunit *up; - struct refclockproc *pp; - int fd; - char device[20]; - char lockfile[128], pidbuf[8]; - char tbuf[BMAX]; - - /* - * The state machine is driven by messages from the modem, when - * first stated and at timeout. - */ - pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; - pp->sloppyclockflag &= ~CLK_FLAG1; - if (sys_phone[up->retry] == NULL && !(pp->sloppyclockflag & - CLK_FLAG3)) { - msyslog(LOG_ERR, "acts: no phones"); - return; - } - switch(up->state) { - - /* - * System poll event. Lock the modem port and open the device. - */ - case S_IDLE: - - /* - * Lock the modem port. If busy, retry later. Note: if - * something fails between here and the close, the lock - * file may not be removed. - */ - if (pp->sloppyclockflag & CLK_FLAG2) { - sprintf(lockfile, LOCKFILE, up->unit); - fd = open(lockfile, O_WRONLY | O_CREAT | O_EXCL, - 0644); - if (fd < 0) { - msyslog(LOG_ERR, "acts: port busy"); - return; - } - sprintf(pidbuf, "%d\n", (u_int)getpid()); - write(fd, pidbuf, strlen(pidbuf)); - close(fd); - } - - /* - * Open the device in raw mode and link the I/O. - */ - if (!pp->io.fd) { - sprintf(device, DEVICE, up->unit); - fd = refclock_open(device, SPEED232, - LDISC_ACTS | LDISC_RAW | LDISC_REMOTE); - if (fd == 0) { - return; - } - pp->io.fd = fd; - if (!io_addclock(&pp->io)) { - msyslog(LOG_ERR, - "acts: addclock fails"); - close(fd); - pp->io.fd = 0; - return; - } - } - - /* - * If the port is directly connected to the device, skip - * the modem business and send 'T' for Spectrabum. - */ - if (pp->sloppyclockflag & CLK_FLAG3) { - if (write(pp->io.fd, "T", 1) < 0) { - msyslog(LOG_ERR, "acts: write %m"); - return; - } - up->state = S_FIRST; - up->timer = CONNECT; - return; - } - - /* - * Initialize the modem. This works with Hayes commands. - */ -#ifdef DEBUG - if (debug) - printf("acts: setup %s\n", MODEM_SETUP); -#endif - if (write(pp->io.fd, MODEM_SETUP, strlen(MODEM_SETUP)) < - 0) { - msyslog(LOG_ERR, "acts: write %m"); - return; - } - up->state = S_OK; - up->timer = SETUP; - return; - - /* - * In OK state the modem did not respond to setup. - */ - case S_OK: - msyslog(LOG_ERR, "acts: no modem"); - break; - - /* - * In DTR state we are waiting for the modem to settle down - * before hammering it with a dial command. - */ - case S_DTR: - sprintf(tbuf, "DIAL #%d %s", up->retry, - sys_phone[up->retry]); - record_clock_stats(&peer->srcadr, tbuf); -#ifdef DEBUG - if (debug) - printf("%s\n", tbuf); -#endif - write(pp->io.fd, sys_phone[up->retry], - strlen(sys_phone[up->retry])); - write(pp->io.fd, "\r", 1); - up->state = S_CONNECT; - up->timer = ANSWER; + if (up->msgcnt == 0) return; - /* - * In CONNECT state the call did not complete. - */ - case S_CONNECT: - msyslog(LOG_ERR, "acts: no answer"); - break; - - /* - * In FIRST state no messages were received. - */ - case S_FIRST: - msyslog(LOG_ERR, "acts: no messages"); - break; - - /* - * In CLOSE state hangup is complete. Close the doors and - * windows and get some air. - */ - case S_CLOSE: - - /* - * Close the device and unlock a shared modem. - */ - if (pp->io.fd) { - io_closeclock(&pp->io); - close(pp->io.fd); - if (pp->sloppyclockflag & CLK_FLAG2) { - sprintf(lockfile, LOCKFILE, up->unit); - unlink(lockfile); - } - pp->io.fd = 0; - } - - /* - * If messages were received, fold the tent and wait for - * the next poll. If no messages and there are more - * numbers to dial, retry after a short wait. - */ - up->bufptr = pp->a_lastcode; - up->timer = 0; - up->state = S_IDLE; - if ( up->msgcnt == 0) { - up->retry++; - if (sys_phone[up->retry] == NULL) - up->retry = 0; - else - up->timer = SETUP; - } else { - up->retry = 0; - } - up->msgcnt = 0; + strlcpy(pp->a_lastcode, str, sizeof(pp->a_lastcode)); + pp->lencode = strlen(pp->a_lastcode); + if (!refclock_process(pp)) { + refclock_report(peer, CEVNT_BADTIME); return; } - acts_disc(peer); -} - - -/* - * acts_disc - disconnect the call and clean the place up. - */ -static void -acts_disc ( - struct peer *peer - ) -{ - struct actsunit *up; - struct refclockproc *pp; - int dtr = TIOCM_DTR; - - /* - * We get here if the call terminated successfully or if an - * error occured. If the median filter has something in it,feed - * the data to the clock filter. If a modem port, drop DTR to - * force command mode and send modem hangup. - */ - pp = peer->procptr; - up = (struct actsunit *)pp->unitptr; - if (up->msgcnt > 0) - refclock_receive(peer); - if (!(pp->sloppyclockflag & CLK_FLAG3)) { - ioctl(pp->io.fd, TIOCMBIC, (char *)&dtr); - write(pp->io.fd, MODEM_HANGUP, strlen(MODEM_HANGUP)); - } - up->timer = SETUP; - up->state = S_CLOSE; + pp->lastref = pp->lastrec; } - #else int refclock_acts_bs; #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_arbiter.c b/contrib/ntp/ntpd/refclock_arbiter.c index 88a32250d..738be508d 100644 --- a/contrib/ntp/ntpd/refclock_arbiter.c +++ b/contrib/ntp/ntpd/refclock_arbiter.c @@ -17,6 +17,12 @@ #include #include +#ifdef SYS_WINNT +extern int async_write(int, const void *, unsigned int); +#undef write +#define write(fd, data, octets) async_write(fd, data, octets) +#endif + /* * This driver supports the Arbiter 1088A/B Satellite Controlled Clock. * The claimed accuracy of this clock is 100 ns relative to the PPS @@ -97,6 +103,15 @@ #define MAXSTA 40 /* max length of status string */ #define MAXPOS 80 /* max length of position string */ +#ifdef PRE_NTP420 +#define MODE ttlmax +#else +#define MODE ttl +#endif + +#define COMMAND_HALT_BCAST ( (peer->MODE % 2) ? "O0" : "B0" ) +#define COMMAND_START_BCAST ( (peer->MODE % 2) ? "O5" : "B5" ) + /* * ARB unit control structure */ @@ -111,10 +126,10 @@ struct arbunit { /* * Function prototypes */ -static int arb_start P((int, struct peer *)); -static void arb_shutdown P((int, struct peer *)); -static void arb_receive P((struct recvbuf *)); -static void arb_poll P((int, struct peer *)); +static int arb_start (int, struct peer *); +static void arb_shutdown (int, struct peer *); +static void arb_receive (struct recvbuf *); +static void arb_poll (int, struct peer *); /* * Transfer vector @@ -147,29 +162,27 @@ arb_start( /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) + snprintf(device, sizeof(device), DEVICE, unit); + fd = refclock_open(device, SPEED232, LDISC_CLK); + if (fd <= 0) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct arbunit *)emalloc(sizeof(struct arbunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct arbunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = arb_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -177,7 +190,17 @@ arb_start( peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; memcpy((char *)&pp->refid, REFID, 4); - write(pp->io.fd, "B0", 2); + if (peer->MODE > 1) { + msyslog(LOG_NOTICE, "ARBITER: Invalid mode %d", peer->MODE); + close(fd); + pp->io.fd = -1; + free(up); + return (0); + } +#ifdef DEBUG + if(debug) { printf("arbiter: mode = %d.\n", peer->MODE); } +#endif + write(pp->io.fd, COMMAND_HALT_BCAST, 2); return (1); } @@ -195,9 +218,11 @@ arb_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct arbunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -220,10 +245,10 @@ arb_receive( /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct arbunit *)pp->unitptr; - temp = refclock_gtlin(rbufp, tbuf, BMAX, &trtmp); + up = pp->unitptr; + temp = refclock_gtlin(rbufp, tbuf, sizeof(tbuf), &trtmp); /* * Note we get a buffer and timestamp for both a and , @@ -264,39 +289,40 @@ arb_receive( return; } else if (!strncmp(tbuf, "SR", 2)) { - strcpy(up->status, tbuf + 2); + strlcpy(up->status, tbuf + 2, + sizeof(up->status)); if (pp->sloppyclockflag & CLK_FLAG4) write(pp->io.fd, "LA", 2); else - write(pp->io.fd, "B5", 2); + write(pp->io.fd, COMMAND_START_BCAST, 2); return; } else if (!strncmp(tbuf, "LA", 2)) { - strcpy(up->latlon, tbuf + 2); + strlcpy(up->latlon, tbuf + 2, sizeof(up->latlon)); write(pp->io.fd, "LO", 2); return; } else if (!strncmp(tbuf, "LO", 2)) { - strcat(up->latlon, " "); - strcat(up->latlon, tbuf + 2); + strlcat(up->latlon, " ", sizeof(up->latlon)); + strlcat(up->latlon, tbuf + 2, sizeof(up->latlon)); write(pp->io.fd, "LH", 2); return; } else if (!strncmp(tbuf, "LH", 2)) { - strcat(up->latlon, " "); - strcat(up->latlon, tbuf + 2); + strlcat(up->latlon, " ", sizeof(up->latlon)); + strlcat(up->latlon, tbuf + 2, sizeof(up->latlon)); write(pp->io.fd, "DB", 2); return; } else if (!strncmp(tbuf, "DB", 2)) { - strcat(up->latlon, " "); - strcat(up->latlon, tbuf + 2); + strlcat(up->latlon, " ", sizeof(up->latlon)); + strlcat(up->latlon, tbuf + 2, sizeof(up->latlon)); record_clock_stats(&peer->srcadr, up->latlon); #ifdef DEBUG if (debug) printf("arbiter: %s\n", up->latlon); #endif - write(pp->io.fd, "B5", 2); + write(pp->io.fd, COMMAND_START_BCAST, 2); } } @@ -316,16 +342,16 @@ arb_receive( /* * Timecode format B5: "i yy ddd hh:mm:ss.000 " */ - strncpy(pp->a_lastcode, tbuf, BMAX); + strlcpy(pp->a_lastcode, tbuf, sizeof(pp->a_lastcode)); pp->a_lastcode[LENARB - 2] = up->qualchar; - strcat(pp->a_lastcode, up->status); + strlcat(pp->a_lastcode, up->status, sizeof(pp->a_lastcode)); pp->lencode = strlen(pp->a_lastcode); syncchar = ' '; if (sscanf(pp->a_lastcode, "%c%2d %3d %2d:%2d:%2d", &syncchar, &pp->year, &pp->day, &pp->hour, &pp->minute, &pp->second) != 6) { refclock_report(peer, CEVNT_BADREPLY); - write(pp->io.fd, "B0", 2); + write(pp->io.fd, COMMAND_HALT_BCAST, 2); return; } @@ -375,13 +401,13 @@ arb_receive( case 'F': /* clock failure */ pp->disp = MAXDISPERSE; refclock_report(peer, CEVNT_FAULT); - write(pp->io.fd, "B0", 2); + write(pp->io.fd, COMMAND_HALT_BCAST, 2); return; default: pp->disp = MAXDISPERSE; refclock_report(peer, CEVNT_BADREPLY); - write(pp->io.fd, "B0", 2); + write(pp->io.fd, COMMAND_HALT_BCAST, 2); return; } if (syncchar != ' ') @@ -398,9 +424,9 @@ arb_receive( else if (peer->disp > MAXDISTANCE) refclock_receive(peer); - if (up->tcswitch >= MAXSTAGE) { - write(pp->io.fd, "B0", 2); - } + /* if (up->tcswitch >= MAXSTAGE) { */ + write(pp->io.fd, COMMAND_HALT_BCAST, 2); + /* } */ } @@ -425,7 +451,7 @@ arb_poll( * need poll the clock; all others just listen in. */ pp = peer->procptr; - up = (struct arbunit *)pp->unitptr; + up = pp->unitptr; pp->polls++; up->tcswitch = 0; if (write(pp->io.fd, "TQ", 2) != 2) diff --git a/contrib/ntp/ntpd/refclock_arc.c b/contrib/ntp/ntpd/refclock_arc.c index af8062192..7daae8d3a 100644 --- a/contrib/ntp/ntpd/refclock_arc.c +++ b/contrib/ntp/ntpd/refclock_arc.c @@ -6,6 +6,8 @@ #include #endif +#include "ntp_types.h" + #if defined(REFCLOCK) && defined(CLOCK_ARCRON_MSF) static const char arc_version[] = { "V1.3 2003/02/21" }; @@ -138,27 +140,27 @@ GENERAL 2) PRECISION should be -4/-5 (63ms/31ms) for the following reasons: a) The ARC documentation claims the internal clock is (only) - accurate to about 20ms relative to Rugby (plus there must be - noticable drift and delay in the ms range due to transmission - delays and changing atmospheric effects). This clock is not - designed for ms accuracy as NTP has spoilt us all to expect. + accurate to about 20ms relative to Rugby (plus there must be + noticable drift and delay in the ms range due to transmission + delays and changing atmospheric effects). This clock is not + designed for ms accuracy as NTP has spoilt us all to expect. b) The clock oscillator looks like a simple uncompensated quartz - crystal of the sort used in digital watches (ie 32768Hz) which - can have large temperature coefficients and drifts; it is not - clear if this oscillator is properly disciplined to the MSF - transmission, but as the default is to resync only once per - *day*, we can imagine that it is not, and is free-running. We - can minimise drift by resyncing more often (at the cost of - reduced battery life), but drift/wander may still be - significant. + crystal of the sort used in digital watches (ie 32768Hz) which + can have large temperature coefficients and drifts; it is not + clear if this oscillator is properly disciplined to the MSF + transmission, but as the default is to resync only once per + *day*, we can imagine that it is not, and is free-running. We + can minimise drift by resyncing more often (at the cost of + reduced battery life), but drift/wander may still be + significant. c) Note that the bit time of 3.3ms adds to the potential error in - the the clock timestamp, since the bit clock of the serial link - may effectively be free-running with respect to the host clock - and the MSF clock. Actually, the error is probably 1/16th of - the above, since the input data is probably sampled at at least - 16x the bit rate. + the the clock timestamp, since the bit clock of the serial link + may effectively be free-running with respect to the host clock + and the MSF clock. Actually, the error is probably 1/16th of + the above, since the input data is probably sampled at at least + 16x the bit rate. By keeping the clock marked as not very precise, it will have a fairly large dispersion, and thus will tend to be used as a @@ -178,9 +180,9 @@ GENERAL IN ANY CASE, BE SURE TO SET AN APPROPRIATE FUDGE FACTOR TO REMOVE ANY RESIDUAL SKEW, eg: - server 127.127.27.0 # ARCRON MSF radio clock unit 0. - # Fudge timestamps by about 20ms. - fudge 127.127.27.0 time1 0.020 + server 127.127.27.0 # ARCRON MSF radio clock unit 0. + # Fudge timestamps by about 20ms. + fudge 127.127.27.0 time1 0.020 You will need to observe your system's behaviour, assuming you have some other NTP source to compare it with, to work out what the @@ -317,28 +319,28 @@ You have to wait for character echo + 10ms before sending next character. /* 12. year tens */ /* 13. year units */ /* 14. BST/UTC status */ -/* bit 7 parity */ -/* bit 6 always 0 */ -/* bit 5 always 1 */ -/* bit 4 always 1 */ -/* bit 3 always 0 */ -/* bit 2 =1 if UTC is in effect, complementary to the BST bit */ -/* bit 1 =1 if BST is in effect, according to the BST bit */ -/* bit 0 BST/UTC change impending bit=1 in case of change impending */ +/* bit 7 parity */ +/* bit 6 always 0 */ +/* bit 5 always 1 */ +/* bit 4 always 1 */ +/* bit 3 always 0 */ +/* bit 2 =1 if UTC is in effect, complementary to the BST bit */ +/* bit 1 =1 if BST is in effect, according to the BST bit */ +/* bit 0 BST/UTC change impending bit=1 in case of change impending */ /* 15. status */ -/* bit 7 parity */ -/* bit 6 always 0 */ -/* bit 5 always 1 */ -/* bit 4 always 1 */ -/* bit 3 =1 if low battery is detected */ -/* bit 2 =1 if the very last reception attempt failed and a valid */ -/* time information already exists (bit0=1) */ -/* =0 if the last reception attempt was successful */ -/* bit 1 =1 if at least one reception since 2:30 am was successful */ -/* =0 if no reception attempt since 2:30 am was successful */ -/* bit 0 =1 if the RC Computer Clock contains valid time information */ -/* This bit is zero after reset and one after the first */ -/* successful reception attempt */ +/* bit 7 parity */ +/* bit 6 always 0 */ +/* bit 5 always 1 */ +/* bit 4 always 1 */ +/* bit 3 =1 if low battery is detected */ +/* bit 2 =1 if the very last reception attempt failed and a valid */ +/* time information already exists (bit0=1) */ +/* =0 if the last reception attempt was successful */ +/* bit 1 =1 if at least one reception since 2:30 am was successful */ +/* =0 if no reception attempt since 2:30 am was successful */ +/* bit 0 =1 if the RC Computer Clock contains valid time information */ +/* This bit is zero after reset and one after the first */ +/* successful reception attempt */ /* DHD note: Also note g command which confirms that a resync is in progress, and @@ -375,15 +377,15 @@ Also note h command which starts a resync to MSF signal. /* * Interface definitions */ -#define DEVICE "/dev/arc%d" /* Device name and unit. */ -#define SPEED B300 /* UART speed (300 baud) */ -#define PRECISION (-4) /* Precision (~63 ms). */ -#define HIGHPRECISION (-5) /* If things are going well... */ -#define REFID "MSFa" /* Reference ID. */ -#define REFID_MSF "MSF" /* Reference ID. */ -#define REFID_DCF77 "DCF" /* Reference ID. */ -#define REFID_WWVB "WWVB" /* Reference ID. */ -#define DESCRIPTION "ARCRON MSF/DCF/WWVB Receiver" +#define DEVICE "/dev/arc%d" /* Device name and unit. */ +#define SPEED B300 /* UART speed (300 baud) */ +#define PRECISION (-4) /* Precision (~63 ms). */ +#define HIGHPRECISION (-5) /* If things are going well... */ +#define REFID "MSFa" /* Reference ID. */ +#define REFID_MSF "MSF" /* Reference ID. */ +#define REFID_DCF77 "DCF" /* Reference ID. */ +#define REFID_WWVB "WWVB" /* Reference ID. */ +#define DESCRIPTION "ARCRON MSF/DCF/WWVB Receiver" #ifdef PRE_NTP420 #define MODE ttlmax @@ -391,18 +393,18 @@ Also note h command which starts a resync to MSF signal. #define MODE ttl #endif -#define LENARC 16 /* Format `o' timecode length. */ +#define LENARC 16 /* Format `o' timecode length. */ -#define BITSPERCHAR 11 /* Bits per character. */ -#define BITTIME 0x0DA740E /* Time for 1 bit at 300bps. */ -#define CHARTIME10 0x8888888 /* Time for 10-bit char at 300bps. */ -#define CHARTIME11 0x962FC96 /* Time for 11-bit char at 300bps. */ -#define CHARTIME /* Time for char at 300bps. */ \ +#define BITSPERCHAR 11 /* Bits per character. */ +#define BITTIME 0x0DA740E /* Time for 1 bit at 300bps. */ +#define CHARTIME10 0x8888888 /* Time for 10-bit char at 300bps. */ +#define CHARTIME11 0x962FC96 /* Time for 11-bit char at 300bps. */ +#define CHARTIME /* Time for char at 300bps. */ \ ( (BITSPERCHAR == 11) ? CHARTIME11 : ( (BITSPERCHAR == 10) ? CHARTIME10 : \ (BITSPERCHAR * BITTIME) ) ) /* Allow for UART to accept char half-way through final stop bit. */ -#define INITIALOFFSET (u_int32)(-BITTIME/2) +#define INITIALOFFSET ((u_int32)(-BITTIME/2)) /* charoffsets[x] is the time after the start of the second that byte @@ -457,12 +459,12 @@ Also note h command which starts a resync to MSF signal. #endif }; -#define DEFAULT_RESYNC_TIME (57*60) /* Gap between resync attempts (s). */ -#define RETRY_RESYNC_TIME (27*60) /* Gap to emergency resync attempt. */ +#define DEFAULT_RESYNC_TIME (57*60) /* Gap between resync attempts (s). */ +#define RETRY_RESYNC_TIME (27*60) /* Gap to emergency resync attempt. */ #ifdef ARCRON_KEEN -#define INITIAL_RESYNC_DELAY 500 /* Delay before first resync. */ +#define INITIAL_RESYNC_DELAY 500 /* Delay before first resync. */ #else -#define INITIAL_RESYNC_DELAY 50 /* Delay before first resync. */ +#define INITIAL_RESYNC_DELAY 50 /* Delay before first resync. */ #endif static const int moff[12] = @@ -470,30 +472,30 @@ Also note h command which starts a resync to MSF signal. /* Flags for a raw open() of the clock serial device. */ #ifdef O_NOCTTY /* Good, we can avoid tty becoming controlling tty. */ #define OPEN_FLAGS (O_RDWR | O_NOCTTY) -#else /* Oh well, it may not matter... */ +#else /* Oh well, it may not matter... */ #define OPEN_FLAGS (O_RDWR) #endif /* Length of queue of command bytes to be sent. */ -#define CMDQUEUELEN 4 /* Enough for two cmds + each \r. */ +#define CMDQUEUELEN 4 /* Enough for two cmds + each \r. */ /* Queue tick time; interval in seconds between chars taken off queue. */ /* Must be >= 2 to allow o\r response to come back uninterrupted. */ -#define QUEUETICK 2 /* Allow o\r reply to finish. */ +#define QUEUETICK 2 /* Allow o\r reply to finish. */ /* * ARC unit control structure */ struct arcunit { - l_fp lastrec; /* Time tag for the receive time (system). */ - int status; /* Clock status. */ + l_fp lastrec; /* Time tag for the receive time (system). */ + int status; /* Clock status. */ - int quality; /* Quality of reception 0--5 for unit. */ + int quality; /* Quality of reception 0--5 for unit. */ /* We may also use the values -1 or 6 internally. */ u_long quality_stamp; /* Next time to reset quality average. */ u_long next_resync; /* Next resync time (s) compared to current_time. */ - int resyncing; /* Resync in progress if true. */ + int resyncing; /* Resync in progress if true. */ /* In the outgoing queue, cmdqueue[0] is next to be sent. */ char cmdqueue[CMDQUEUELEN+1]; /* Queue of outgoing commands + \0. */ @@ -527,11 +529,11 @@ static int possible_leap = 0; /* No resync required by default. */ #endif #if 0 -static void dummy_event_handler P((struct peer *)); -static void arc_event_handler P((struct peer *)); +static void dummy_event_handler (struct peer *); +static void arc_event_handler (struct peer *); #endif /* 0 */ -#define QUALITY_UNKNOWN -1 /* Indicates unknown clock quality. */ +#define QUALITY_UNKNOWN -1 /* Indicates unknown clock quality. */ #define MIN_CLOCK_QUALITY 0 /* Min quality clock will return. */ #define MIN_CLOCK_QUALITY_OK 3 /* Min quality for OK reception. */ #define MAX_CLOCK_QUALITY 5 /* Max quality clock will return. */ @@ -539,28 +541,28 @@ static void arc_event_handler P((struct peer *)); /* * Function prototypes */ -static int arc_start P((int, struct peer *)); -static void arc_shutdown P((int, struct peer *)); -static void arc_receive P((struct recvbuf *)); -static void arc_poll P((int, struct peer *)); +static int arc_start (int, struct peer *); +static void arc_shutdown (int, struct peer *); +static void arc_receive (struct recvbuf *); +static void arc_poll (int, struct peer *); /* * Transfer vector */ struct refclock refclock_arc = { - arc_start, /* start up driver */ - arc_shutdown, /* shut down driver */ - arc_poll, /* transmit poll message */ - noentry, /* not used (old arc_control) */ - noentry, /* initialize driver (not used) */ - noentry, /* not used (old arc_buginfo) */ - NOFLAGS /* not used */ + arc_start, /* start up driver */ + arc_shutdown, /* shut down driver */ + arc_poll, /* transmit poll message */ + noentry, /* not used (old arc_control) */ + noentry, /* initialize driver (not used) */ + noentry, /* not used (old arc_buginfo) */ + NOFLAGS /* not used */ }; /* Queue us up for the next tick. */ #define ENQUEUE(up) \ do { \ - peer->nextaction = current_time + QUEUETICK; \ + peer->procptr->nextaction = current_time + QUEUETICK; \ } while(0) /* Placeholder event handler---does nothing safely---soaks up loose tick. */ @@ -591,7 +593,7 @@ arc_event_handler( ) { struct refclockproc *pp = peer->procptr; - register struct arcunit *up = (struct arcunit *)pp->unitptr; + register struct arcunit *up = pp->unitptr; int i; char c; #ifdef DEBUG @@ -627,48 +629,52 @@ arc_start( { register struct arcunit *up; struct refclockproc *pp; + int temp_fd; int fd; char device[20]; #ifdef HAVE_TERMIOS struct termios arg; #endif - msyslog(LOG_NOTICE, "ARCRON: %s: opening unit %d", arc_version, unit); -#ifdef DEBUG - if(debug) { - printf("arc: %s: attempt to open unit %d.\n", arc_version, unit); - } -#endif - - /* Prevent a ridiculous device number causing overflow of device[]. */ - if((unit < 0) || (unit > 255)) { return(0); } + msyslog(LOG_NOTICE, "MSF_ARCRON %s: opening unit %d", + arc_version, unit); + DPRINTF(1, ("arc: %s: attempt to open unit %d.\n", arc_version, + unit)); /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); - if (!(fd = refclock_open(device, SPEED, LDISC_CLK))) - return(0); -#ifdef DEBUG - if(debug) { printf("arc: unit %d using open().\n", unit); } -#endif - fd = open(device, OPEN_FLAGS); - if(fd < 0) { -#ifdef DEBUG - if(debug) { printf("arc: failed [open()] to open %s.\n", device); } -#endif - return(0); + snprintf(device, sizeof(device), DEVICE, unit); + temp_fd = refclock_open(device, SPEED, LDISC_CLK); + if (temp_fd <= 0) + return 0; + DPRINTF(1, ("arc: unit %d using tty_open().\n", unit)); + fd = tty_open(device, OPEN_FLAGS, 0777); + if (fd < 0) { + msyslog(LOG_ERR, "MSF_ARCRON(%d): failed second open(%s, 0777): %m.", + unit, device); + close(temp_fd); + return 0; } + close(temp_fd); + temp_fd = -1; /* not used after this, at *this* time. */ + +#ifndef SYS_WINNT + if (-1 == fcntl(fd, F_SETFL, 0)) /* clear the descriptor flags */ + msyslog(LOG_ERR, "MSF_ARCRON(%d): fcntl(F_SETFL, 0): %m.", + unit); - fcntl(fd, F_SETFL, 0); /* clear the descriptor flags */ -#ifdef DEBUG - if(debug) - { printf("arc: opened RS232 port with file descriptor %d.\n", fd); } #endif + DPRINTF(1, ("arc: opened RS232 port with file descriptor %d.\n", fd)); #ifdef HAVE_TERMIOS - tcgetattr(fd, &arg); + if (tcgetattr(fd, &arg) < 0) { + msyslog(LOG_ERR, "MSF_ARCRON(%d): tcgetattr(%s): %m.", + unit, device); + close(fd); + return 0; + } arg.c_iflag = IGNBRK | ISTRIP; arg.c_oflag = 0; @@ -677,28 +683,36 @@ arc_start( arg.c_cc[VMIN] = 1; arg.c_cc[VTIME] = 0; - tcsetattr(fd, TCSANOW, &arg); + if (tcsetattr(fd, TCSANOW, &arg) < 0) { + msyslog(LOG_ERR, "MSF_ARCRON(%d): tcsetattr(%s): %m.", + unit, device); + close(fd); + return 0; + } #else - msyslog(LOG_ERR, "ARCRON: termios not supported in this driver"); + msyslog(LOG_ERR, "ARCRON: termios required by this driver"); (void)close(fd); return 0; #endif - up = (struct arcunit *) emalloc(sizeof(struct arcunit)); - if(!up) { (void) close(fd); return(0); } /* Set structure to all zeros... */ - memset((char *)up, 0, sizeof(struct arcunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = arc_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; - if(!io_addclock(&pp->io)) { (void) close(fd); free(up); return(0); } - pp->unitptr = (caddr_t)up; + if (!io_addclock(&pp->io)) { + close(fd); + pp->io.fd = -1; + free(up); + return(0); + } + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -746,7 +760,7 @@ arc_start( up->quality = MIN_CLOCK_QUALITY;/* Don't trust the clock yet. */ #endif - peer->action = arc_event_handler; + peer->procptr->action = arc_event_handler; ENQUEUE(up); @@ -766,12 +780,14 @@ arc_shutdown( register struct arcunit *up; struct refclockproc *pp; - peer->action = dummy_event_handler; + peer->procptr->action = dummy_event_handler; pp = peer->procptr; - up = (struct arcunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } /* @@ -812,9 +828,9 @@ send_slow( if(spaceleft < sl) { /* Should not normally happen... */ #ifdef DEBUG msyslog(LOG_NOTICE, "ARCRON: send-buffer overrun (%d/%d)", - sl, spaceleft); + sl, spaceleft); #endif - return(0); /* FAILED! */ + return(0); /* FAILED! */ } /* Copy in the command to be sent. */ @@ -827,7 +843,7 @@ send_slow( static int get2(char *p, int *val) { - if (!isdigit((int)p[0]) || !isdigit((int)p[1])) return 0; + if (!isdigit((unsigned char)p[0]) || !isdigit((unsigned char)p[1])) return 0; *val = (p[0] - '0') * 10 + p[1] - '0'; return 1; } @@ -835,7 +851,7 @@ get2(char *p, int *val) static int get1(char *p, int *val) { - if (!isdigit((int)p[0])) return 0; + if (!isdigit((unsigned char)p[0])) return 0; *val = p[0] - '0'; return 1; } @@ -846,10 +862,10 @@ get1(char *p, int *val) (((q) < MIN_CLOCK_QUALITY_OK) ? "TOO POOR, will not use clock" : \ "OK, will use clock")) - /* +/* * arc_receive - receive data from the serial interface */ - static void +static void arc_receive( struct recvbuf *rbufp ) @@ -867,9 +883,9 @@ arc_receive( /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct arcunit *)pp->unitptr; + up = pp->unitptr; /* @@ -927,7 +943,7 @@ arc_receive( #ifdef DEBUG if(debug) { /* Show \r as `R', other non-printing char as `?'. */ printf("arc: stamp -->%c<-- (%d chars rcvd)\n", - ((c == '\r') ? 'R' : (isgraph((int)c) ? c : '?')), + ((c == '\r') ? 'R' : (isgraph((unsigned char)c) ? c : '?')), rbufp->recv_length); } #endif @@ -992,7 +1008,7 @@ arc_receive( diff = up->lastrec; L_SUB(&diff, ×tamp); printf("arc: adjusted timestamp by -%sms.\n", - mfptoms(diff.l_i, diff.l_f, 3)); + mfptoms(diff.l_ui, diff.l_uf, 3)); } #endif } @@ -1005,7 +1021,7 @@ arc_receive( /* Just in case we still have lots of rubbish in the buffer... */ /* ...and to avoid the same timestamp being reused by mistake, */ /* eg on receipt of the \r coming in on its own after the */ - /* timecode. */ + /* timecode. */ if(pp->lencode >= LENARC) { #ifdef DEBUG if(debug && (rbufp->recv_buffer[0] != '\r')) @@ -1083,9 +1099,9 @@ arc_receive( } #endif msyslog(LOG_NOTICE, - "ARCRON: sync finished, signal quality %d: %s", - up->quality, - quality_action(up->quality)); + "ARCRON: sync finished, signal quality %d: %s", + up->quality, + quality_action(up->quality)); up->resyncing = 0; /* Resync is over. */ quality_average = 0; quality_sum = 0; @@ -1210,7 +1226,7 @@ arc_receive( if(pp->year >= YEAR_PIVOT+2000-2 ) { /* Y2KFixes */ /*This should get attention B^> */ msyslog(LOG_NOTICE, - "ARCRON: fix me! EITHER YOUR DATE IS BADLY WRONG or else I will break soon!"); + "ARCRON: fix me! EITHER YOUR DATE IS BADLY WRONG or else I will break soon!"); } #ifdef DEBUG if(debug) { @@ -1271,50 +1287,52 @@ arc_receive( if(peer->MODE > 0) { if(pp->sloppyclockflag & CLK_FLAG1) { struct tm local; - struct tm *gmtp; - time_t unixtime; + struct tm *gmtp; + time_t unixtime; - /* - * Convert to GMT for sites that distribute localtime. + /* + * Convert to GMT for sites that distribute localtime. * This means we have to do Y2K conversion on the * 2-digit year; otherwise, we get the time wrong. - */ - + */ + + memset(&local, 0, sizeof(local)); + local.tm_year = pp->year-1900; - local.tm_mon = month-1; - local.tm_mday = pp->day; - local.tm_hour = pp->hour; - local.tm_min = pp->minute; - local.tm_sec = pp->second; - switch (peer->MODE) { + local.tm_mon = month-1; + local.tm_mday = pp->day; + local.tm_hour = pp->hour; + local.tm_min = pp->minute; + local.tm_sec = pp->second; + switch (peer->MODE) { case 1: local.tm_isdst = (flags & 2); break; case 2: - local.tm_isdst = (flags & 2); + local.tm_isdst = (flags & 2); break; case 3: switch (flags & 3) { case 0: /* It is unclear exactly when the - Arcron changes from DST->ST and + Arcron changes from DST->ST and ST->DST. Testing has shown this to be irregular. For the time being, let the OS decide. */ - local.tm_isdst = 0; + local.tm_isdst = 0; #ifdef DEBUG if (debug) printf ("arc: DST = 00 (0)\n"); #endif break; case 1: /* dst->st time */ - local.tm_isdst = -1; + local.tm_isdst = -1; #ifdef DEBUG if (debug) printf ("arc: DST = 01 (1)\n"); #endif break; case 2: /* st->dst time */ - local.tm_isdst = -1; + local.tm_isdst = -1; #ifdef DEBUG if (debug) printf ("arc: DST = 10 (2)\n"); @@ -1331,26 +1349,26 @@ arc_receive( break; default: msyslog(LOG_NOTICE, "ARCRON: Invalid mode %d", - peer->MODE); + peer->MODE); return; break; } - unixtime = mktime (&local); - if ((gmtp = gmtime (&unixtime)) == NULL) - { + unixtime = mktime (&local); + if ((gmtp = gmtime (&unixtime)) == NULL) + { pp->lencode = 0; - refclock_report (peer, CEVNT_FAULT); - return; - } + refclock_report (peer, CEVNT_FAULT); + return; + } pp->year = gmtp->tm_year+1900; - month = gmtp->tm_mon+1; - pp->day = ymd2yd(pp->year,month,gmtp->tm_mday); - /* pp->day = gmtp->tm_yday; */ - pp->hour = gmtp->tm_hour; - pp->minute = gmtp->tm_min; - pp->second = gmtp->tm_sec; + month = gmtp->tm_mon+1; + pp->day = ymd2yd(pp->year,month,gmtp->tm_mday); + /* pp->day = gmtp->tm_yday; */ + pp->hour = gmtp->tm_hour; + pp->minute = gmtp->tm_min; + pp->second = gmtp->tm_sec; #ifdef DEBUG - if (debug) + if (debug) { printf ("arc: time is %04d/%02d/%02d %02d:%02d:%02d UTC\n", pp->year,month,gmtp->tm_mday,pp->hour,pp->minute, @@ -1359,10 +1377,10 @@ arc_receive( #endif } else { - /* - * For more rational sites distributing UTC - */ - pp->day = ymd2yd(pp->year,month,pp->day); + /* + * For more rational sites distributing UTC + */ + pp->day = ymd2yd(pp->year,month,pp->day); } } @@ -1391,10 +1409,10 @@ arc_receive( if(up->saved_flags != pp->sloppyclockflag) { #ifdef DEBUG msyslog(LOG_NOTICE, "ARCRON: flags enabled: %s%s%s%s", - ((pp->sloppyclockflag & CLK_FLAG1) ? "1" : "."), - ((pp->sloppyclockflag & CLK_FLAG2) ? "2" : "."), - ((pp->sloppyclockflag & CLK_FLAG3) ? "3" : "."), - ((pp->sloppyclockflag & CLK_FLAG4) ? "4" : ".")); + ((pp->sloppyclockflag & CLK_FLAG1) ? "1" : "."), + ((pp->sloppyclockflag & CLK_FLAG2) ? "2" : "."), + ((pp->sloppyclockflag & CLK_FLAG3) ? "3" : "."), + ((pp->sloppyclockflag & CLK_FLAG4) ? "4" : ".")); /* Note effects of flags changing... */ if(debug) { printf("arc: PRECISION = %d.\n", peer->precision); @@ -1436,7 +1454,7 @@ arc_receive( /* request_time() sends a time request to the clock with given peer. */ /* This automatically reports a fault if necessary. */ /* No data should be sent after this until arc_poll() returns. */ -static void request_time P((int, struct peer *)); +static void request_time (int, struct peer *); static void request_time( int unit, @@ -1444,7 +1462,7 @@ request_time( ) { struct refclockproc *pp = peer->procptr; - register struct arcunit *up = (struct arcunit *)pp->unitptr; + register struct arcunit *up = pp->unitptr; #ifdef DEBUG if(debug) { printf("arc: unit %d: requesting time.\n", unit); } #endif @@ -1475,7 +1493,7 @@ arc_poll( int resync_needed; /* Should we start a resync? */ pp = peer->procptr; - up = (struct arcunit *)pp->unitptr; + up = pp->unitptr; #if 0 pp->lencode = 0; memset(pp->a_lastcode, 0, sizeof(pp->a_lastcode)); @@ -1565,5 +1583,5 @@ arc_poll( } #else -int refclock_arc_bs; +NONEMPTY_TRANSLATION_UNIT #endif diff --git a/contrib/ntp/ntpd/refclock_as2201.c b/contrib/ntp/ntpd/refclock_as2201.c index f04d417be..1acf9b208 100644 --- a/contrib/ntp/ntpd/refclock_as2201.c +++ b/contrib/ntp/ntpd/refclock_as2201.c @@ -129,10 +129,10 @@ static char stat_command[][30] = { /* * Function prototypes */ -static int as2201_start P((int, struct peer *)); -static void as2201_shutdown P((int, struct peer *)); -static void as2201_receive P((struct recvbuf *)); -static void as2201_poll P((int, struct peer *)); +static int as2201_start (int, struct peer *); +static void as2201_shutdown (int, struct peer *); +static void as2201_receive (struct recvbuf *); +static void as2201_poll (int, struct peer *); /* * Transfer vector @@ -165,36 +165,32 @@ as2201_start( /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(gpsdev, DEVICE, unit); - if (!(fd = refclock_open(gpsdev, SPEED232, LDISC_CLK))) + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); + fd = refclock_open(gpsdev, SPEED232, LDISC_CLK); + if (fd <= 0) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct as2201unit *) - emalloc(sizeof(struct as2201unit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct as2201unit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = as2201_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables */ peer->precision = PRECISION; - peer->burst = NSTAGE; pp->clockdesc = DESCRIPTION; memcpy((char *)&pp->refid, REFID, 4); up->lastptr = up->stats; @@ -216,9 +212,11 @@ as2201_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct as2201unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -234,13 +232,14 @@ as2201_receive( struct refclockproc *pp; struct peer *peer; l_fp trtmp; + size_t octets; /* * Initialize pointers and read the timecode and timestamp. */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct as2201unit *)pp->unitptr; + up = pp->unitptr; pp->lencode = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &trtmp); #ifdef DEBUG if (debug) @@ -268,7 +267,7 @@ as2201_receive( if ((int)(up->lastptr - up->stats + pp->lencode) > SMAX - 2) return; *up->lastptr++ = ' '; - (void)strcpy(up->lastptr, pp->a_lastcode); + memcpy(up->lastptr, pp->a_lastcode, 1 + pp->lencode); up->lastptr += pp->lencode; return; } else { @@ -329,13 +328,17 @@ as2201_receive( * send the next command. If not, simply write the timecode to * the clockstats file. */ - (void)strcpy(up->lastptr, pp->a_lastcode); + if ((int)(up->lastptr - up->stats + pp->lencode) > SMAX - 2) + return; + memcpy(up->lastptr, pp->a_lastcode, pp->lencode); up->lastptr += pp->lencode; if (pp->sloppyclockflag & CLK_FLAG4) { + octets = strlen(stat_command[up->index]); + if ((int)(up->lastptr - up->stats + 1 + octets) > SMAX - 2) + return; *up->lastptr++ = ' '; - (void)strcpy(up->lastptr, stat_command[up->index]); - up->lastptr += strlen(stat_command[up->index]); - up->lastptr--; + memcpy(up->lastptr, stat_command[up->index], octets); + up->lastptr += octets - 1; *up->lastptr = '\0'; (void)write(pp->io.fd, stat_command[up->index], strlen(stat_command[up->index])); @@ -373,14 +376,11 @@ as2201_poll( if (!(pp->sloppyclockflag & CLK_FLAG2)) get_systime(&pp->lastrec); } - if (peer->burst > 0) - return; if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; } refclock_receive(peer); - peer->burst = NSTAGE; } #else diff --git a/contrib/ntp/ntpd/refclock_atom.c b/contrib/ntp/ntpd/refclock_atom.c index 2e469ecd4..b3c0d6b46 100644 --- a/contrib/ntp/ntpd/refclock_atom.c +++ b/contrib/ntp/ntpd/refclock_atom.c @@ -14,21 +14,23 @@ #include "ntp_refclock.h" #include "ntp_stdlib.h" -#if defined(REFCLOCK) && defined(CLOCK_ATOM) - -#ifdef HAVE_PPSAPI -# include "ppsapi_timepps.h" -#endif /* HAVE_PPSAPI */ +/* + * This driver requires the PPSAPI interface (RFC 2783) + */ +#if defined(REFCLOCK) && defined(CLOCK_ATOM) && defined(HAVE_PPSAPI) +#include "ppsapi_timepps.h" +#include "refclock_atom.h" /* * This driver furnishes an interface for pulse-per-second (PPS) signals * produced by a cesium clock, timing receiver or related equipment. It - * can be used to remove accumulated jitter and retime a secondary - * server when synchronized to a primary server over a congested, wide- - * area network and before redistributing the time to local clients. + * can be used to remove accumulated jitter over a congested link and + * retime a server before redistributing the time to clients. It can + *also be used as a holdover should all other synchronization sources + * beconme unreachable. * * Before this driver becomes active, the local clock must be set to - * within +-500 ms by another means, such as a radio clock or NTP + * within +-0.4 s by another means, such as a radio clock or NTP * itself. There are two ways to connect the PPS signal, normally at TTL * levels, to the computer. One is to shift to EIA levels and connect to * pin 8 (DCD) of a serial port. This requires a level converter and @@ -36,27 +38,13 @@ * to connect the PPS signal directly to pin 10 (ACK) of a PC paralell * port. These methods are architecture dependent. * - * Both methods require a modified device driver and kernel interface - * compatible with the Pulse-per-Second API for Unix-like Operating + * This driver requires the Pulse-per-Second API for Unix-like Operating * Systems, Version 1.0, RFC-2783 (PPSAPI). Implementations are - * available for FreeBSD, Linux, SunOS, Solaris and Alpha. However, at - * present only the Alpha implementation provides the full generality of + * available for FreeBSD, Linux, SunOS, Solaris and Tru64. However, at + * present only the Tru64 implementation provides the full generality of * the API with multiple PPS drivers and multiple handles per driver. If * the PPSAPI is normally implemented in the /usr/include/sys/timepps.h * header file and kernel support specific to each operating system. - * However, this driver can operate without this interface if means are - * proviced to call the pps_sample() routine from another driver. Please - * note; if the PPSAPI interface is present, it must be used. - * - * In many configurations a single port is used for the radio timecode - * and PPS signal. In order to provide for this configuration and others - * involving dedicated multiple serial/parallel ports, the driver first - * attempts to open the device /dev/pps%d, where %d is the unit number. - * If this fails, the driver attempts to open the device specified by - * the pps configuration command. If a port is to be shared, the pps - * command must be placed before the radio device(s) and the radio - * device(s) must be placed before the PPS driver(s) in the - * configuration file. * * This driver normally uses the PLL/FLL clock discipline implemented in * the ntpd code. Ordinarily, this is the most accurate means, as the @@ -65,80 +53,62 @@ * to hundreds of PPM), it's better to used the kernel support, if * available. * + * This deriver is subject to the mitigation rules described in the + * "mitigation rulse and the prefer peer" page. However, there is an + * important difference. If this driver becomes the PPS driver according + * to these rules, it is acrive only if (a) a prefer peer other than + * this driver is among the survivors or (b) there are no survivors and + * the minsane option of the tos command is zero. This is intended to + * support space missions where updates from other spacecraft are + * infrequent, but a reliable PPS signal, such as from an Ultra Stable + * Oscillator (USO) is available. + * * Fudge Factors * - * If flag2 is dim (default), the on-time epoch is the assert edge of - * the PPS signal; if lit, the on-time epoch is the clear edge. If flag2 - * is lit, the assert edge is used; if flag3 is dim (default), the - * kernel PPS support is disabled; if lit it is enabled. The time1 - * parameter can be used to compensate for miscellaneous device driver - * and OS delays. + * The PPS timestamp is captured on the rising (assert) edge if flag2 is + * dim (default) and on the falling (clear) edge if lit. If flag3 is dim + * (default), the kernel PPS support is disabled; if lit it is enabled. + * If flag4 is lit, each timesampt is copied to the clockstats file for + * later analysis. This can be useful when constructing Allan deviation + * plots. The time1 parameter can be used to compensate for + * miscellaneous device driver and OS delays. */ /* * Interface definitions */ -#ifdef HAVE_PPSAPI #define DEVICE "/dev/pps%d" /* device name and unit */ -#endif /* HAVE_PPSAPI */ - #define PRECISION (-20) /* precision assumed (about 1 us) */ #define REFID "PPS\0" /* reference ID */ #define DESCRIPTION "PPS Clock Discipline" /* WRU */ -#define NANOSECOND 1000000000 /* one second (ns) */ -#define RANGEGATE 500000 /* range gate (ns) */ -static struct peer *pps_peer; /* atom driver for PPS sources */ - -#ifdef HAVE_PPSAPI /* * PPS unit control structure */ struct ppsunit { - struct timespec ts; /* last timestamp */ - int fddev; /* pps device descriptor */ - pps_params_t pps_params; /* pps parameters */ - pps_info_t pps_info; /* last pps data */ - pps_handle_t handle; /* pps handlebars */ + struct refclock_atom atom; /* atom structure pointer */ + int fddev; /* file descriptor */ }; -#endif /* HAVE_PPSAPI */ /* * Function prototypes */ -static int atom_start P((int, struct peer *)); -static void atom_poll P((int, struct peer *)); -static void atom_shutdown P((int, struct peer *)); -#ifdef HAVE_PPSAPI -static void atom_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); -static void atom_timer P((int, struct peer *)); -static int atom_ppsapi P((struct peer *, int)); -#endif /* HAVE_PPSAPI */ +static int atom_start (int, struct peer *); +static void atom_shutdown (int, struct peer *); +static void atom_poll (int, struct peer *); +static void atom_timer (int, struct peer *); /* * Transfer vector */ -#ifdef HAVE_PPSAPI struct refclock refclock_atom = { atom_start, /* start up driver */ atom_shutdown, /* shut down driver */ atom_poll, /* transmit poll message */ - atom_control, /* fudge control */ + noentry, /* control (not used) */ noentry, /* initialize driver (not used) */ noentry, /* buginfo (not used) */ atom_timer, /* called once per second */ }; -#else /* HAVE_PPSAPI */ -struct refclock refclock_atom = { - atom_start, /* start up driver */ - atom_shutdown, /* shut down driver */ - atom_poll, /* transmit poll message */ - noentry, /* fudge control (not used) */ - noentry, /* initialize driver (not used) */ - noentry, /* buginfo (not used) */ - NOFLAGS /* not used */ -}; -#endif /* HAVE_PPPSAPI */ /* @@ -151,59 +121,37 @@ atom_start( ) { struct refclockproc *pp; -#ifdef HAVE_PPSAPI - register struct ppsunit *up; + struct ppsunit *up; char device[80]; - int mode; -#endif /* HAVE_PPSAPI */ /* * Allocate and initialize unit structure */ - pps_peer = peer; pp = peer->procptr; peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; pp->stratum = STRATUM_UNSPEC; memcpy((char *)&pp->refid, REFID, 4); -#ifdef HAVE_PPSAPI up = emalloc(sizeof(struct ppsunit)); memset(up, 0, sizeof(struct ppsunit)); - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Open PPS device. This can be any serial or parallel port and * not necessarily the port used for the associated radio. */ - sprintf(device, DEVICE, unit); - up->fddev = open(device, O_RDWR, 0777); + snprintf(device, sizeof(device), DEVICE, unit); + up->fddev = tty_open(device, O_RDWR, 0777); if (up->fddev <= 0) { msyslog(LOG_ERR, - "refclock_atom: %s: %m", device); - return (0); - } - - /* - * Light off the PPSAPI interface. - */ - if (time_pps_create(up->fddev, &up->handle) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_create failed: %m"); + "refclock_atom: %s: %m", device); return (0); } /* - * If the mode is nonzero, use that for the time_pps_setparams() - * mode; otherwise, PPS_CAPTUREASSERT. Enable kernel PPS if - * flag3 is lit. + * Light up the PPSAPI interface. */ - mode = peer->ttl; - if (mode == 0) - mode = PPS_CAPTUREASSERT; - return (atom_ppsapi(peer, mode)); -#else /* HAVE_PPSAPI */ - return (1); -#endif /* HAVE_PPSAPI */ + return (refclock_ppsapi(up->fddev, &up->atom)); } @@ -217,249 +165,44 @@ atom_shutdown( ) { struct refclockproc *pp; - register struct ppsunit *up; + struct ppsunit *up; pp = peer->procptr; - up = (struct ppsunit *)pp->unitptr; -#ifdef HAVE_PPSAPI + up = pp->unitptr; if (up->fddev > 0) close(up->fddev); - if (up->handle != 0) - time_pps_destroy(up->handle); -#endif /* HAVE_PPSAPI */ - if (pps_peer == peer) - pps_peer = NULL; free(up); } - -#ifdef HAVE_PPSAPI -/* - * atom_control - fudge control - */ -static void -atom_control( - int unit, /* unit (not used */ - struct refclockstat *in, /* input parameters (not uded) */ - struct refclockstat *out, /* output parameters (not used) */ - struct peer *peer /* peer structure pointer */ - ) -{ - struct refclockproc *pp; - int mode; - - pp = peer->procptr; - if (peer->ttl != 0) /* all legal modes must be nonzero */ - return; - - if (pp->sloppyclockflag & CLK_FLAG2) - mode = PPS_CAPTURECLEAR; - else - mode = PPS_CAPTUREASSERT; - atom_ppsapi(peer, mode); -} - - -/* - * Initialize PPSAPI - */ -int -atom_ppsapi( - struct peer *peer, /* peer structure pointer */ - int mode /* mode */ - ) -{ - struct refclockproc *pp; - register struct ppsunit *up; - int capability; - - pp = peer->procptr; - up = (struct ppsunit *)pp->unitptr; - if (up->handle == 0) - return (0); - - if (time_pps_getcap(up->handle, &capability) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_getcap failed: %m"); - return (0); - } - memset(&up->pps_params, 0, sizeof(pps_params_t)); - up->pps_params.api_version = PPS_API_VERS_1; - up->pps_params.mode = mode | PPS_TSFMT_TSPEC; - if (time_pps_setparams(up->handle, &up->pps_params) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_setparams failed: %m"); - return (0); - } - if (pp->sloppyclockflag & CLK_FLAG3) { - if (time_pps_kcbind(up->handle, PPS_KC_HARDPPS, - up->pps_params.mode & ~PPS_TSFMT_TSPEC, - PPS_TSFMT_TSPEC) < 0) { - msyslog(LOG_ERR, - "refclock_atom: time_pps_kcbind failed: %m"); - return (0); - } - pps_enable = 1; - } -#if DEBUG - if (debug) { - time_pps_getparams(up->handle, &up->pps_params); - printf( - "refclock_ppsapi: fd %d capability 0x%x version %d mode 0x%x\n", - up->fddev, capability, up->pps_params.api_version, - up->pps_params.mode); - } -#endif - return (1); -} - - /* * atom_timer - called once per second - * - * This routine is called once per second when the PPSAPI interface is - * present. It snatches the PPS timestamp from the kernel and saves the - * sign-extended fraction in a circular buffer for processing at the - * next poll event. */ -static void +void atom_timer( - int unit, /* unit number (not used) */ + int unit, /* unit pointer (not used) */ struct peer *peer /* peer structure pointer */ ) { - register struct ppsunit *up; + struct ppsunit *up; struct refclockproc *pp; - pps_info_t pps_info; - struct timespec timeout, ts; - long sec, nsec; - double dtemp; - char tbuf[80]; /* monitor buffer */ + char tbuf[80]; - /* - * Convert the timespec nanoseconds field to signed double and - * save in the median filter. for billboards. No harm is done if - * previous data are overwritten. If the discipline comes bum or - * the data grow stale, just forget it. A range gate rejects new - * samples if less than a jiggle time from the next second. - */ pp = peer->procptr; - up = (struct ppsunit *)pp->unitptr; - if (up->handle == 0) + up = pp->unitptr; + if (refclock_pps(peer, &up->atom, pp->sloppyclockflag) <= 0) return; - timeout.tv_sec = 0; - timeout.tv_nsec = 0; - memcpy(&pps_info, &up->pps_info, sizeof(pps_info_t)); - if (time_pps_fetch(up->handle, PPS_TSFMT_TSPEC, &up->pps_info, - &timeout) < 0) { - refclock_report(peer, CEVNT_FAULT); - return; - } - if (up->pps_params.mode & PPS_CAPTUREASSERT) { - ts = up->pps_info.assert_timestamp; - } else if (up->pps_params.mode & PPS_CAPTURECLEAR) { - ts = up->pps_info.clear_timestamp; - } else { - refclock_report(peer, CEVNT_FAULT); - return; - } + peer->flags |= FLAG_PPS; /* - * There can be zero, one or two PPS seconds between polls. If - * zero, either the poll clock is slightly faster than the PPS - * clock or the PPS clock has died. If the PPS clock advanced - * once between polls, we make sure the fraction time difference - * since the last sample is within the range gate of 5 ms (500 - * PPM). If the PPS clock advanced twice since the last poll, - * the poll bracketed more than one second and the first second - * was lost to a slip. Since the interval since the last sample - * found is now two seconds, just widen the range gate. If the - * PPS clock advanced three or more times, either the signal has - * failed for a number of seconds or we have runts, in which - * case just ignore them. - * * If flag4 is lit, record each second offset to clockstats. * That's so we can make awesome Allan deviation plots. */ - sec = ts.tv_sec - up->ts.tv_sec; - nsec = ts.tv_nsec - up->ts.tv_nsec; - up->ts = ts; - if (nsec < 0) { - sec --; - nsec += NANOSECOND; - } else if (nsec >= NANOSECOND) { - sec++; - nsec -= NANOSECOND; - } - if (sec * NANOSECOND + nsec > NANOSECOND + RANGEGATE) - return; - - else if (sec * NANOSECOND + nsec < NANOSECOND - RANGEGATE) - return; - - pp->lastrec.l_ui = ts.tv_sec + JAN_1970; - dtemp = ts.tv_nsec * FRAC / 1e9; - if (dtemp >= FRAC) - pp->lastrec.l_ui++; - pp->lastrec.l_uf = (u_int32)dtemp; - if (ts.tv_nsec > NANOSECOND / 2) - ts.tv_nsec -= NANOSECOND; - dtemp = -(double)ts.tv_nsec / NANOSECOND; - SAMPLE(dtemp + pp->fudgetime1); - if (pp->sloppyclockflag & CLK_FLAG4){ - sprintf(tbuf, "%.9f", dtemp); + if (pp->sloppyclockflag & CLK_FLAG4) { + snprintf(tbuf, sizeof(tbuf), "%.9f", + pp->filter[pp->coderecv]); record_clock_stats(&peer->srcadr, tbuf); } -#ifdef DEBUG - if (debug > 1) - printf("atom_timer: %lu %f %f\n", current_time, - dtemp, pp->fudgetime1); -#endif - return; -} -#endif /* HAVE_PPSAPI */ - - -/* - * pps_sample - receive PPS data from some other clock driver - * - * This routine is called once per second when the external clock driver - * processes PPS information. It processes the PPS timestamp and saves - * the sign-extended fraction in a circular buffer for processing at the - * next poll event. This works only for a single PPS device. - * - * The routine should be used by another configured driver ONLY when - * this driver is configured as well and the PPSAPI is NOT in use. - */ -int -pps_sample( - l_fp *offset /* PPS offset */ - ) -{ - register struct peer *peer; - struct refclockproc *pp; - l_fp lftmp; - double doffset; - - peer = pps_peer; - if (peer == NULL) - return (1); - - pp = peer->procptr; - - /* - * Convert the timeval to l_fp and save for billboards. Sign- - * extend the fraction and stash in the buffer. No harm is done - * if previous data are overwritten. If the discipline comes bum - * or the data grow stale, just forget it. - */ - pp->lastrec = *offset; - L_CLR(&lftmp); - L_ADDF(&lftmp, pp->lastrec.l_f); - LFPTOD(&lftmp, doffset); - SAMPLE(-doffset + pp->fudgetime1); - return (0); } @@ -473,45 +216,24 @@ atom_poll( ) { struct refclockproc *pp; - pp = peer->procptr; - pp->polls++; /* - * Valid time is returned only if the prefer peer has survived - * the intersection algorithm and within 0.4 s of local time - * and not too long ago. This ensures the PPS time is within - * 0.5 s of the local time and the seconds numbering is - * unambiguous. Note that the leap bits, stratum and refid are - * set from the prefer peer, unless overriden by a fudge - * command. + * Don't wiggle the clock until some other driver has numbered + * the seconds. */ - if (pp->codeproc == pp->coderecv) { - refclock_report(peer, CEVNT_TIMEOUT); + if (sys_leap == LEAP_NOTINSYNC) return; - } else if (sys_prefer == NULL) { - pp->codeproc = pp->coderecv; - return; - - } else if (fabs(sys_prefer->offset) >= 0.4) { - pp->codeproc = pp->coderecv; + pp = peer->procptr; + pp->polls++; + if (pp->codeproc == pp->coderecv) { + peer->flags &= ~FLAG_PPS; + refclock_report(peer, CEVNT_TIMEOUT); return; } - pp->leap = sys_prefer->leap; - if (pp->stratum >= STRATUM_UNSPEC) - peer->stratum = sys_prefer->stratum; - else - peer->stratum = pp->stratum; pp->lastref = pp->lastrec; refclock_receive(peer); } #else int refclock_atom_bs; -int -pps_sample( - l_fp *offset /* PPS offset */ - ) -{ - return (1); -} #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_bancomm.c b/contrib/ntp/ntpd/refclock_bancomm.c index 9fc8c82c4..49922e393 100644 --- a/contrib/ntp/ntpd/refclock_bancomm.c +++ b/contrib/ntp/ntpd/refclock_bancomm.c @@ -20,26 +20,29 @@ * vme_control() and vme_buginfo() have been deleted because * they are no longer being used. * - * The time on the bc635 TFP must be set to GMT due to the - * fact that NTP makes use of GMT for all its calculations. - * - * Installation of the Datum/Bancomm driver creates the - * device file /dev/btfp0 - * * 04/28/2005 Rob Neal * Modified to add support for Symmetricom bc637PCI-U Time & * Frequency Processor. + * 2/21/2007 Ali Ghorashi + * Modified to add support for Symmetricom bc637PCI-U Time & + * Frequency Processor on Solaris. + * Tested on Solaris 10 with a bc635 card. + * * Card bus type (VME/VXI or PCI) and environment are specified via the * "mode" keyword on the server command in ntp.conf. - * server 127.127.16.u prefer mode m (...) - * Modes currently supported are + * server 127.127.16.u prefer mode M + * where u is the id (usually 0) of the entry in /dev (/dev/stfp0) + * + * and M is one of the following modes: * 1 : FreeBSD PCI 635/637. * 2 : Linux or Windows PCI 635/637. + * 3 : Solaris PCI 635/637 * not specified, or other number: * : Assumed to be VME/VXI legacy Bancomm card on Solaris. * Linux and Windows platforms require Symmetricoms' proprietary driver - * for the TFP card. - * Tested on FreeBSD 5.3 with a 637 card. + * for the TFP card. + * Solaris requires Symmetricom's driver and its header file (freely distributed) to + * be installed and running. */ #ifdef HAVE_CONFIG_H @@ -58,7 +61,6 @@ #include #include -/* STUFF BY RES */ struct btfp_time /* Structure for reading 5 time words */ /* in one ioctl(2) operation. */ { @@ -85,9 +87,37 @@ struct btfp_time /* Structure for reading 5 time words */ #define READTIME _IOR('u', 5, struct btfp_time ) #endif -#define VMEFD "/dev/btfp0" +/* Solaris specific section */ +struct stfp_tm { + int32_t tm_sec; + int32_t tm_min; + int32_t tm_hour; + int32_t tm_mday; + int32_t tm_mon; + int32_t tm_year; + int32_t tm_wday; + int32_t tm_yday; + int32_t tm_isdst; +}; + +struct stfp_time { + struct stfp_tm tm; + int32_t usec; /* usec 0 - 999999 */ + int32_t hnsec; /* hnsec 0 - 9 (hundreds of nsecs) */ + int32_t status; +}; + +#define SELTIMEFORMAT 2 +# define TIME_DECIMAL 0 +# define TIME_BINARY 1 -struct vmedate { /* structure returned by get_vmetime.c */ +#if defined(__sun__) +#undef READTIME +#define READTIME 9 +#endif /** __sun___ **/ +/* end solaris specific section */ + +struct vmedate { /* structure returned by get_vmetime.c */ unsigned short year; unsigned short day; unsigned short hr; @@ -97,7 +127,6 @@ struct vmedate { /* structure returned by get_vmetime.c */ unsigned short status; }; -/* END OF STUFF FROM RES */ typedef void *SYMMT_PCI_HANDLE; /* @@ -116,11 +145,6 @@ typedef void *SYMMT_PCI_HANDLE; */ extern u_long current_time; /* current time(s) */ -/* - * Imported from ntpd module - */ -extern volatile int debug; /* global debug flag */ - /* * VME unit control structure. * Changes made to vmeunit structure. Most members are now available in the @@ -139,7 +163,11 @@ static void vme_shutdown (int, struct peer *); static void vme_receive (struct recvbuf *); static void vme_poll (int unit, struct peer *); struct vmedate *get_datumtime(struct vmedate *); -void tvme_fill(struct vmedate *, uint32_t btm[2]); +void tvme_fill(struct vmedate *, uint32_t btm[2]); +void stfp_time2tvme(struct vmedate *time_vme, struct stfp_time *stfp); +inline const char *DEVICE_NAME(int n); + + /* * Define the bc*() functions as weak so we can compile/link without them. * Only clients with the card will have the proprietary vendor device driver @@ -167,6 +195,15 @@ int regvalue; int tfp_type; /* mode selector, indicate platform and driver interface */ SYMMT_PCI_HANDLE stfp_handle; +/** + * this macro returns the device name based on + * the platform we are running on and the device number + */ +#if defined(__sun__) +inline const char *DEVICE_NAME(int n) {static char s[20]={0}; snprintf(s,19,"/dev/stfp%d",n);return s;} +#else +inline const char* DEVICE_NAME(int n) {static char s[20]={0}; snprintf(s,19,"/dev/btfp%d",n);return s;} +#endif /**__sun__**/ /* * vme_start - open the VME device and initialize data for processing @@ -185,6 +222,7 @@ vme_start( tfp_type = (int)(peer->ttl); switch (tfp_type) { case 1: + case 3: break; case 2: stfp_handle = bcStartPci(); /* init the card in lin/win */ @@ -197,9 +235,9 @@ vme_start( */ #ifdef DEBUG - printf("Opening DATUM VME DEVICE \n"); + printf("Opening DATUM DEVICE %s\n",DEVICE_NAME(peer->refclkunit)); #endif - if ( (fd_vme = open(VMEFD, O_RDWR)) < 0) { + if ( (fd_vme = open(DEVICE_NAME(peer->refclkunit), O_RDWR)) < 0) { msyslog(LOG_ERR, "vme_start: failed open of %s: %m", vmedev); return (0); } @@ -207,6 +245,7 @@ vme_start( switch (tfp_type) { case 1: break; case 2: break; + case 3:break; default: /* Release capture lockout in case it was set before. */ if( ioctl( fd_vme, RUNLOCK, &dummy ) ) @@ -222,21 +261,21 @@ vme_start( /* * Allocate unit structure */ - vme = (struct vmeunit *)emalloc(sizeof(struct vmeunit)); - bzero((char *)vme, sizeof(struct vmeunit)); + vme = emalloc_zero(sizeof(struct vmeunit)); /* * Set up the structures */ pp = peer->procptr; - pp->unitptr = (caddr_t) vme; + pp->unitptr = vme; pp->timestarted = current_time; pp->io.clock_recv = vme_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd_vme; + /* shouldn't there be an io_addclock() call? */ /* * All done. Initialize a few random peer variables, then @@ -265,11 +304,13 @@ vme_shutdown( * Tell the I/O module to turn us off. We're history. */ pp = peer->procptr; - vme = (struct vmeunit *)pp->unitptr; + vme = pp->unitptr; io_closeclock(&pp->io); pp->unitptr = NULL; - free(vme); - if (tfp_type == 2) bcStopPci(stfp_handle); + if (NULL != vme) + free(vme); + if (tfp_type == 2) + bcStopPci(stfp_handle); } @@ -303,7 +344,7 @@ vme_poll( struct tm *tadr; pp = peer->procptr; - vme = (struct vmeunit *)pp->unitptr; /* Here is the structure */ + vme = pp->unitptr; /* Here is the structure */ tptr = &vme->vmedata; if ((tptr = get_datumtime(tptr)) == NULL ) { @@ -324,14 +365,15 @@ vme_poll( tadr = gmtime(&tloc); tptr->year = (unsigned short)(tadr->tm_year + 1900); - sprintf(pp->a_lastcode, - "%3.3d %2.2d:%2.2d:%2.2d.%.6ld %1d", - tptr->day, - tptr->hr, - tptr->mn, - tptr->sec, - tptr->frac, - tptr->status); + snprintf(pp->a_lastcode, + sizeof(pp->a_lastcode), + "%3.3d %2.2d:%2.2d:%2.2d.%.6ld %1d", + tptr->day, + tptr->hr, + tptr->mn, + tptr->sec, + tptr->frac, + tptr->status); pp->lencode = (u_short) strlen(pp->a_lastcode); @@ -376,10 +418,10 @@ get_datumtime(struct vmedate *time_vme) struct btfp_time vts; uint32_t btm[2]; uint8_t dmy; + struct stfp_time stfpm; - if ( time_vme == (struct vmedate *)NULL) { - time_vme = (struct vmedate *)malloc(sizeof(struct vmedate )); - } + if (time_vme == NULL) + time_vme = emalloc(sizeof(*time_vme)); switch (tfp_type) { case 1: /* BSD, PCI, 2 32bit time words */ @@ -397,41 +439,65 @@ get_datumtime(struct vmedate *time_vme) } tvme_fill(time_vme, btm); break; + + case 3: /** solaris **/ + memset(&stfpm,0,sizeof(stfpm)); + + /* we need the time in decimal format */ + /* Here we rudely assume that we are the only user of the driver. + * Other programs will have to set their own time format before reading + * the time. + */ + if(ioctl (fd_vme, SELTIMEFORMAT, TIME_DECIMAL)){ + msyslog(LOG_ERR, "Could not set time format"); + return (NULL); + } + /* read the time */ + if (ioctl(fd_vme, READTIME, &stfpm)) { + msyslog(LOG_ERR, "ioctl error: %m"); + return(NULL); + } + stfp_time2tvme(time_vme, &stfpm); + break; default: /* legacy bancomm card */ if (ioctl(fd_vme, READTIME, &vts)) { - msyslog(LOG_ERR, "get_datumtime error: %m"); + msyslog(LOG_ERR, + "get_datumtime error: %m"); return(NULL); } /* Get day */ - sprintf(cbuf,"%3.3x", ((vts.btfp_time[ 0 ] & 0x000f) <<8) + - ((vts.btfp_time[ 1 ] & 0xff00) >> 8)); + snprintf(cbuf, sizeof(cbuf), "%3.3x", + ((vts.btfp_time[ 0 ] & 0x000f) << 8) + + ((vts.btfp_time[ 1 ] & 0xff00) >> 8)); time_vme->day = (unsigned short)atoi(cbuf); /* Get hour */ - sprintf(cbuf,"%2.2x", vts.btfp_time[ 1 ] & 0x00ff); - + snprintf(cbuf, sizeof(cbuf), "%2.2x", + vts.btfp_time[ 1 ] & 0x00ff); time_vme->hr = (unsigned short)atoi(cbuf); /* Get minutes */ - sprintf(cbuf,"%2.2x", (vts.btfp_time[ 2 ] & 0xff00) >>8); + snprintf(cbuf, sizeof(cbuf), "%2.2x", + (vts.btfp_time[ 2 ] & 0xff00) >> 8); time_vme->mn = (unsigned short)atoi(cbuf); /* Get seconds */ - sprintf(cbuf,"%2.2x", vts.btfp_time[ 2 ] & 0x00ff); + snprintf(cbuf, sizeof(cbuf), "%2.2x", + vts.btfp_time[ 2 ] & 0x00ff); time_vme->sec = (unsigned short)atoi(cbuf); /* Get microseconds. Yes, we ignore the 0.1 microsecond digit so we can use the TVTOTSF function later on...*/ - sprintf(cbuf,"%4.4x%2.2x", vts.btfp_time[ 3 ], - vts.btfp_time[ 4 ]>>8); - + snprintf(cbuf, sizeof(cbuf), "%4.4x%2.2x", + vts.btfp_time[ 3 ], + vts.btfp_time[ 4 ] >> 8); time_vme->frac = (u_long) atoi(cbuf); /* Get status bit */ - time_vme->status = (vts.btfp_time[0] & 0x0010) >>4; + time_vme->status = (vts.btfp_time[0] & 0x0010) >> 4; break; } @@ -462,6 +528,21 @@ tvme_fill(struct vmedate *time_vme, uint32_t btm[2]) return; } + +/* Assign values to time_vme struct. Mostly for readability */ +void +stfp_time2tvme(struct vmedate *time_vme, struct stfp_time *stfp) +{ + + time_vme->day = stfp->tm.tm_yday+1; + time_vme->hr = stfp->tm.tm_hour; + time_vme->mn = stfp->tm.tm_min; + time_vme->sec = stfp->tm.tm_sec; + time_vme->frac = stfp->usec*1000; + time_vme->frac += stfp->hnsec * 100; + time_vme->status = stfp->status; + return; +} #else int refclock_bancomm_bs; #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_chronolog.c b/contrib/ntp/ntpd/refclock_chronolog.c index a1d131ec0..ee54b43a6 100644 --- a/contrib/ntp/ntpd/refclock_chronolog.c +++ b/contrib/ntp/ntpd/refclock_chronolog.c @@ -67,10 +67,10 @@ struct chronolog_unit { /* * Function prototypes */ -static int chronolog_start P((int, struct peer *)); -static void chronolog_shutdown P((int, struct peer *)); -static void chronolog_receive P((struct recvbuf *)); -static void chronolog_poll P((int, struct peer *)); +static int chronolog_start (int, struct peer *); +static void chronolog_shutdown (int, struct peer *); +static void chronolog_receive (struct recvbuf *); +static void chronolog_poll (int, struct peer *); /* * Transfer vector @@ -104,32 +104,30 @@ chronolog_start( * Open serial port. Don't bother with CLK line discipline, since * it's not available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); #ifdef DEBUG if (debug) printf ("starting Chronolog with device %s\n",device); #endif - if (!(fd = refclock_open(device, SPEED232, 0))) + fd = refclock_open(device, SPEED232, 0); + if (fd <= 0) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct chronolog_unit *) - emalloc(sizeof(struct chronolog_unit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct chronolog_unit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->io.clock_recv = chronolog_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -156,9 +154,11 @@ chronolog_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct chronolog_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -184,9 +184,9 @@ chronolog_receive( /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct chronolog_unit *)pp->unitptr; + up = pp->unitptr; temp = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &trtmp); if (temp == 0) { @@ -240,6 +240,8 @@ chronolog_receive( * otherwise, we get the time wrong. */ + memset(&local, 0, sizeof(local)); + local.tm_year = up->year; local.tm_mon = up->month-1; local.tm_mday = up->day; @@ -295,7 +297,7 @@ chronolog_receive( pp->lastref = pp->lastrec; refclock_receive(peer); record_clock_stats(&peer->srcadr, pp->a_lastcode); - up->lasthour = pp->hour; + up->lasthour = (u_char)pp->hour; } @@ -322,7 +324,7 @@ chronolog_poll( char pollchar; pp = peer->procptr; - up = (struct chronolog_unit *)pp->unitptr; + up = pp->unitptr; if (peer->burst == 0 && peer->reach == 0) refclock_report(peer, CEVNT_TIMEOUT); if (up->linect > 0) diff --git a/contrib/ntp/ntpd/refclock_chu.c b/contrib/ntp/ntpd/refclock_chu.c index 843e9aaa4..1f02a1c1f 100644 --- a/contrib/ntp/ntpd/refclock_chu.c +++ b/contrib/ntp/ntpd/refclock_chu.c @@ -5,6 +5,8 @@ #include #endif +#include "ntp_types.h" + #if defined(REFCLOCK) && defined(CLOCK_CHU) #include "ntpd.h" @@ -26,47 +28,47 @@ #ifdef ICOM #include "icom.h" #endif /* ICOM */ - /* * Audio CHU demodulator/decoder * * This driver synchronizes the computer time using data encoded in * radio transmissions from Canadian time/frequency station CHU in * Ottawa, Ontario. Transmissions are made continuously on 3330 kHz, - * 7335 kHz and 14670 kHz in upper sideband, compatible AM mode. An + * 7850 kHz and 14670 kHz in upper sideband, compatible AM mode. An * ordinary shortwave receiver can be tuned manually to one of these * frequencies or, in the case of ICOM receivers, the receiver can be - * tuned automatically using this program as propagation conditions - * change throughout the day and night. + * tuned automatically as propagation conditions change throughout the + * day and season. * - * The driver receives, demodulates and decodes the radio signals when - * connected to the audio codec of a suported workstation hardware and - * operating system. These include Solaris, SunOS, FreeBSD, NetBSD and - * Linux. In this implementation, only one audio driver and codec can be - * supported on a single machine. + * The driver requires an audio codec or sound card with sampling rate 8 + * kHz and mu-law companding. This is the same standard as used by the + * telephone industry and is supported by most hardware and operating + * systems, including Solaris, SunOS, FreeBSD, NetBSD and Linux. In this + * implementation, only one audio driver and codec can be supported on a + * single machine. * * The driver can be compiled to use a Bell 103 compatible modem or * modem chip to receive the radio signal and demodulate the data. * Alternatively, the driver can be compiled to use the audio codec of - * the Sun workstation or another with compatible audio drivers. In the + * the workstation or another with compatible audio drivers. In the * latter case, the driver implements the modem using DSP routines, so * the radio can be connected directly to either the microphone on line * input port. In either case, the driver decodes the data using a - * maximum likelihood technique which exploits the considerable degree + * maximum-likelihood technique which exploits the considerable degree * of redundancy available to maximize accuracy and minimize errors. * * The CHU time broadcast includes an audio signal compatible with the - * Bell 103 modem standard (mark = 2225 Hz, space = 2025 Hz). It consist - * of nine, ten-character bursts transmitted at 300 bps and beginning - * each second from second 31 to second 39 of the minute. Each character - * consists of eight data bits plus one start bit and two stop bits to - * encode two hex digits. The burst data consist of five characters (ten - * hex digits) followed by a repeat of these characters. In format A, - * the characters are repeated in the same polarity; in format B, the - * characters are repeated in the opposite polarity. + * Bell 103 modem standard (mark = 2225 Hz, space = 2025 Hz). The signal + * consists of nine, ten-character bursts transmitted at 300 bps between + * seconds 31 and 39 of each minute. Each character consists of eight + * data bits plus one start bit and two stop bits to encode two hex + * digits. The burst data consist of five characters (ten hex digits) + * followed by a repeat of these characters. In format A, the characters + * are repeated in the same polarity; in format B, the characters are + * repeated in the opposite polarity. * * Format A bursts are sent at seconds 32 through 39 of the minute in - * hex digits + * hex digits (nibble swapped) * * 6dddhhmmss6dddhhmmss * @@ -96,10 +98,10 @@ * By design, the last stop bit of the last character in the burst * coincides with 0.5 second. Since characters have 11 bits and are * transmitted at 300 bps, the last stop bit of the first character - * coincides with 0.5 - 10 * 11/300 = 0.133 second. Depending on the - * UART, character interrupts can vary somewhere between the beginning - * of bit 9 and end of bit 11. These eccentricities can be corrected - * along with the radio propagation delay using fudge time 1. + * coincides with 0.5 - 9 * 11/300 = 0.170 second. Depending on the + * UART, character interrupts can vary somewhere between the end of bit + * 9 and end of bit 11. These eccentricities can be corrected along with + * the radio propagation delay using fudge time 1. * * Debugging aids * @@ -107,11 +109,15 @@ * data helpful in diagnosing problems with the radio signal and serial * connections. With debugging enabled (-d on the ntpd command line), * the driver produces one line for each burst in two formats - * corresponding to format A and B. Following is format A: + * corresponding to format A and B.Each line begins with the format code + * chuA or chuB followed by the status code and signal level (0-9999). + * The remainder of the line is as follows. + * + * Following is format A: * * n b f s m code * - * where n is the number of characters in the burst (0-11), b the burst + * where n is the number of characters in the burst (0-10), b the burst * distance (0-40), f the field alignment (-1, 0, 1), s the * synchronization distance (0-16), m the burst number (2-9) and code * the burst characters as received. Note that the hex digits in each @@ -119,43 +125,50 @@ * * 10 38 0 16 9 06851292930685129293 * - * is interpreted as containing 11 characters with burst distance 38, + * is interpreted as containing 10 characters with burst distance 38, * field alignment 0, synchronization distance 16 and burst number 9. * The nibble-swapped timecode shows day 58, hour 21, minute 29 and * second 39. * - * When the audio driver is compiled, format A is preceded by - * the current gain (0-255) and relative signal level (0-9999). The - * receiver folume control should be set so that the gain is somewhere - * near the middle of the range 0-255, which results in a signal level - * near 1000. - * * Following is format B: * * n b s code * - * where n is the number of characters in the burst (0-11), b the burst + * where n is the number of characters in the burst (0-10), b the burst * distance (0-40), s the synchronization distance (0-40) and code the * burst characters as received. Note that the hex digits in each * character are reversed and the last ten digits inverted, so the burst * - * 11 40 1091891300ef6e76ecff + * 10 40 1091891300ef6e76ec * - * is interpreted as containing 11 characters with burst distance 40. + * is interpreted as containing 10 characters with burst distance 40. * The nibble-swapped timecode shows DUT1 +0.1 second, year 1998 and TAI * - UTC 31 seconds. * + * Each line is preceeded by the code chuA or chuB, as appropriate. If + * the audio driver is compiled, the current gain (0-255) and relative + * signal level (0-9999) follow the code. The receiver volume control + * should be set so that the gain is somewhere near the middle of the + * range 0-255, which results in a signal level near 1000. + * * In addition to the above, the reference timecode is updated and * written to the clockstats file and debug score after the last burst * received in the minute. The format is * - * qq yyyy ddd hh:mm:ss nn dd tt + * sq yyyy ddd hh:mm:ss l s dd t agc ident m b * - * where qq are the error flags, as described below, yyyy is the year, - * ddd the day, hh:mm:ss the time of day, nn the number of format A - * bursts received during the previous minute, dd the decoding distance - * and tt the number of timestamps. The error flags are cleared after - * every update. + * s '?' before first synchronized and ' ' after that + * q status code (see below) + * yyyy year + * ddd day of year + * hh:mm:ss time of day + * l leap second indicator (space, L or D) + * dst Canadian daylight code (opaque) + * t number of minutes since last synchronized + * agc audio gain (0 - 255) + * ident identifier (CHU0 3330 kHz, CHU1 7850 kHz, CHU2 14670 kHz) + * m signal metric (0 - 100) + * b number of timecodes for the previous minute (0 - 59) * * Fudge factors * @@ -184,6 +197,11 @@ * 9600 bps if the high order 0x80 bit of the mode is zero and 1200 bps * if one. The C-IV trace is turned on if the debug level is greater * than one. + * + * Alarm codes + * + * CEVNT_BADTIME invalid date or time + * CEVNT_PROP propagation failure - no stations heard */ /* * Interface definitions @@ -194,8 +212,8 @@ #define DEVICE "/dev/chu%d" /* device name and unit */ #define SPEED232 B300 /* UART speed (300 baud) */ #ifdef ICOM -#define TUNE .001 /* offset for narrow filter (kHz) */ -#define DWELL 5 /* minutes in a probe cycle */ +#define TUNE .001 /* offset for narrow filter (MHz) */ +#define DWELL 5 /* minutes in a dwell */ #define NCHAN 3 /* number of channels */ #define ISTAGE 3 /* number of integrator stages */ #endif /* ICOM */ @@ -210,6 +228,7 @@ #define SIZE 256 /* decompanding table size */ #define MAXAMP 6000. /* maximum signal level */ #define MAXCLP 100 /* max clips above reference per s */ +#define SPAN 800. /* min envelope span */ #define LIMIT 1000. /* soft limiter threshold */ #define AGAIN 6. /* baseband gain */ #define LAG 10 /* discriminator lag */ @@ -224,23 +243,28 @@ * Decoder definitions */ #define CHAR (11. / 300.) /* character time (s) */ -#define FUDGE .185 /* offset to first stop bit (s) */ #define BURST 11 /* max characters per burst */ -#define MINCHAR 9 /* min characters per burst */ +#define MINCHARS 9 /* min characters per burst */ #define MINDIST 28 /* min burst distance (of 40) */ -#define MINBURST 4 /* min bursts in minute */ #define MINSYNC 8 /* min sync distance (of 16) */ #define MINSTAMP 20 /* min timestamps (of 60) */ -#define METRIC 50. /* min channel metric */ -#define PANIC 1440 /* panic timeout (m) */ -#define HOLD 30 /* reach hold (m) */ +#define MINMETRIC 50 /* min channel metric (of 160) */ /* - * Hex extension codes (>= 16) + * The on-time synchronization point for the driver is the last stop bit + * of the first character 170 ms. The modem delay is 0.8 ms, while the + * receiver delay is approxmately 4.7 ms at 2125 Hz. The fudge value 1.3 + * ms due to the codec and other causes was determined by calibrating to + * a PPS signal from a GPS receiver. The additional propagation delay + * specific to each receiver location can be programmed in the fudge + * time1. + * + * The resulting offsets with a 2.4-GHz P4 running FreeBSD 6.1 are + * generally within 0.5 ms short term with 0.3 ms jitter. The long-term + * offsets vary up to 0.3 ms due to ionospheric layer height variations. + * The processor load due to the driver is 0.4 percent. */ -#define HEX_MISS 16 /* miss _ */ -#define HEX_SOFT 17 /* soft error * */ -#define HEX_HARD 18 /* hard error = */ +#define PDELAY ((170 + .8 + 4.7 + 1.3) / 1000) /* system delay (s) */ /* * Status bits (status) @@ -256,6 +280,7 @@ #define AVALID 0x0100 /* valid A frame */ #define BVALID 0x0200 /* valid B frame */ #define INSYNC 0x0400 /* clock synchronized */ +#define METRIC 0x0800 /* one or more stations heard */ /* * Alarm status bits (alarm) @@ -273,12 +298,13 @@ #ifdef HAVE_AUDIO /* - * Maximum likelihood UART structure. There are eight of these + * Maximum-likelihood UART structure. There are eight of these * corresponding to the number of phases. */ struct surv { - double shift[12]; /* mark register */ - double es_max, es_min; /* max/min envelope signals */ + l_fp cstamp; /* last bit timestamp */ + double shift[12]; /* sample shift register */ + double span; /* shift register envelope span */ double dist; /* sample distance */ int uart; /* decoded character */ }; @@ -301,19 +327,19 @@ struct xmtr { * CHU unit control structure */ struct chuunit { - u_char decode[20][16]; /* maximum likelihood decoding matrix */ + u_char decode[20][16]; /* maximum-likelihood decoding matrix */ l_fp cstamp[BURST]; /* character timestamps */ l_fp tstamp[MAXSTAGE]; /* timestamp samples */ l_fp timestamp; /* current buffer timestamp */ l_fp laststamp; /* last buffer timestamp */ l_fp charstamp; /* character time as a l_fp */ + int second; /* counts the seconds of the minute */ int errflg; /* error flags */ int status; /* status bits */ char ident[5]; /* station ID and channel */ #ifdef ICOM int fd_icom; /* ICOM file descriptor */ - int chan; /* data channel */ - int achan; /* active channel */ + int chan; /* radio channel */ int dwell; /* dwell cycle */ struct xmtr xmtr[NCHAN]; /* station metric */ #endif /* ICOM */ @@ -328,6 +354,8 @@ struct chuunit { int burdist; /* burst distance */ int syndist; /* sync distance */ int burstcnt; /* format A bursts this minute */ + double maxsignal; /* signal level (modem only) */ + int gain; /* codec gain (modem only) */ /* * Format particulars @@ -344,7 +372,6 @@ struct chuunit { int fd_audio; /* audio port file descriptor */ double comp[SIZE]; /* decompanding table */ int port; /* codec port */ - int gain; /* codec gain */ int mongain; /* codec monitor gain */ int clipcnt; /* sample clip count */ int seccnt; /* second interval counter */ @@ -357,15 +384,15 @@ struct chuunit { double disc[LAG]; /* discriminator shift register */ double lpf[27]; /* FIR lowpass filter */ double monitor; /* audio monitor */ - double maxsignal; /* signal level */ int discptr; /* discriminator pointer */ /* - * Maximum likelihood UART variables + * Maximum-likelihood UART variables */ double baud; /* baud interval */ struct surv surv[8]; /* UART survivor structures */ int decptr; /* decode pointer */ + int decpha; /* decode phase */ int dbrk; /* holdoff counter */ #endif /* HAVE_AUDIO */ }; @@ -373,31 +400,32 @@ struct chuunit { /* * Function prototypes */ -static int chu_start P((int, struct peer *)); -static void chu_shutdown P((int, struct peer *)); -static void chu_receive P((struct recvbuf *)); -static void chu_poll P((int, struct peer *)); +static int chu_start (int, struct peer *); +static void chu_shutdown (int, struct peer *); +static void chu_receive (struct recvbuf *); +static void chu_second (int, struct peer *); +static void chu_poll (int, struct peer *); /* * More function prototypes */ -static void chu_decode P((struct peer *, int)); -static void chu_burst P((struct peer *)); -static void chu_clear P((struct peer *)); -static void chu_a P((struct peer *, int)); -static void chu_b P((struct peer *, int)); -static int chu_dist P((int, int)); -static double chu_major P((struct peer *)); +static void chu_decode (struct peer *, int, l_fp); +static void chu_burst (struct peer *); +static void chu_clear (struct peer *); +static void chu_a (struct peer *, int); +static void chu_b (struct peer *, int); +static int chu_dist (int, int); +static double chu_major (struct peer *); #ifdef HAVE_AUDIO -static void chu_uart P((struct surv *, double)); -static void chu_rf P((struct peer *, double)); -static void chu_gain P((struct peer *)); -static void chu_audio_receive P((struct recvbuf *rbufp)); +static void chu_uart (struct surv *, double); +static void chu_rf (struct peer *, double); +static void chu_gain (struct peer *); +static void chu_audio_receive (struct recvbuf *rbufp); #endif /* HAVE_AUDIO */ #ifdef ICOM -static int chu_newchan P((struct peer *, double)); +static int chu_newchan (struct peer *, double); #endif /* ICOM */ -static void chu_serial_receive P((struct recvbuf *rbufp)); +static void chu_serial_receive (struct recvbuf *rbufp); /* * Global variables @@ -410,7 +438,7 @@ static char hexchar[] = "0123456789abcdef_*="; * transmits on USB with carrier so we can use AM and the narrow SSB * filter. */ -static double qsy[NCHAN] = {3.330, 7.335, 14.670}; /* freq (MHz) */ +static double qsy[NCHAN] = {3.330, 7.850, 14.670}; /* freq (MHz) */ #endif /* ICOM */ /* @@ -423,7 +451,7 @@ struct refclock refclock_chu = { noentry, /* not used (old chu_control) */ noentry, /* initialize driver (not used) */ noentry, /* not used (old chu_buginfo) */ - NOFLAGS /* not used */ + chu_second /* housekeeping timer */ }; @@ -449,21 +477,22 @@ chu_start( double step; /* codec adjustment */ /* - * Open audio device. + * Open audio device. Don't complain if not there. */ fd_audio = audio_init(DEVICE_AUDIO, AUDIO_BUFSIZ, unit); + #ifdef DEBUG - if (fd_audio > 0 && debug) + if (fd_audio >= 0 && debug) audio_show(); #endif /* - * Open serial port in raw mode. + * If audio is unavailable, Open serial port in raw mode. */ - if (fd_audio > 0) { + if (fd_audio >= 0) { fd = fd_audio; } else { - sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = refclock_open(device, SPEED232, LDISC_RAW); } #else /* HAVE_AUDIO */ @@ -471,30 +500,28 @@ chu_start( /* * Open serial port in raw mode. */ - sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = refclock_open(device, SPEED232, LDISC_RAW); #endif /* HAVE_AUDIO */ - if (fd <= 0) + + if (fd < 0) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct chuunit *) - emalloc(sizeof(struct chuunit)))) { - close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct chuunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->io.clock_recv = chu_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -503,8 +530,8 @@ chu_start( */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - strcpy(up->ident, "CHU"); - memcpy(&peer->refid, up->ident, 4); + strlcpy(up->ident, "CHU", sizeof(up->ident)); + memcpy(&pp->refid, up->ident, 4); DTOLFP(CHAR, &up->charstamp); #ifdef HAVE_AUDIO @@ -543,16 +570,11 @@ chu_start( } if (up->fd_icom > 0) { if (chu_newchan(peer, 0) != 0) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: radio not found"); - up->errflg = CEVNT_FAULT; + msyslog(LOG_NOTICE, "icom: radio not found"); close(up->fd_icom); up->fd_icom = 0; } else { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: autotune enabled"); + msyslog(LOG_NOTICE, "icom: autotune enabled"); } } #endif /* ICOM */ @@ -573,7 +595,7 @@ chu_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; if (up == NULL) return; @@ -599,9 +621,9 @@ chu_receive( struct refclockproc *pp; struct peer *peer; - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * If the audio codec is warmed up, the buffer contains codec @@ -639,9 +661,9 @@ chu_audio_receive( int bufcnt; /* buffer counter */ l_fp ltemp; /* l_fp temp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * Main loop - read until there ain't no more. Note codec @@ -674,7 +696,6 @@ chu_audio_receive( */ up->seccnt = (up->seccnt + 1) % SECOND; if (up->seccnt == 0) { - pp->second = (pp->second + 1) % 60; chu_gain(peer); } } @@ -698,7 +719,7 @@ chu_audio_receive( * * This routine implements a 300-baud Bell 103 modem with mark 2225 Hz * and space 2025 Hz. It uses a bandpass filter followed by a soft - * limiter, FM discriminator and lowpass filter. A maximum likelihood + * limiter, FM discriminator and lowpass filter. A maximum-likelihood * decoder samples the baseband signal at eight times the baud rate and * detects the start bit of each character. * @@ -723,16 +744,16 @@ chu_rf( double limit; /* limiter signal */ double disc; /* discriminator signal */ double lpf; /* lowpass signal */ - double span; /* UART signal span */ double dist; /* UART signal distance */ int i, j; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * Bandpass filter. 4th-order elliptic, 500-Hz bandpass centered - * at 2125 Hz. Passband ripple 0.3 dB, stopband ripple 50 dB. + * at 2125 Hz. Passband ripple 0.3 dB, stopband ripple 50 dB, + * phase delay 0.24 ms. */ signal = (up->bpf[8] = up->bpf[7]) * 5.844676e-01; signal += (up->bpf[7] = up->bpf[6]) * 4.884860e-01; @@ -778,7 +799,7 @@ chu_rf( disc = -SQRT(-disc); /* - * Lowpass filter. Raised cosine, Ts = 1 / 300, beta = 0.1. + * Lowpass filter. Raised cosine FIR, Ts = 1 / 300, beta = 0.1. */ lpf = (up->lpf[26] = up->lpf[25]) * 2.538771e-02; lpf += (up->lpf[25] = up->lpf[24]) * 1.084671e-01; @@ -809,44 +830,68 @@ chu_rf( lpf += up->lpf[0] = disc * 2.538771e-02; /* - * Maximum likelihood decoder. The UART updates each of the + * Maximum-likelihood decoder. The UART updates each of the * eight survivors and determines the span, slice level and * tentative decoded character. Valid 11-bit characters are - * framed so that bit 1 and bit 11 (stop bits) are mark and bit - * 2 (start bit) is space. When a valid character is found, the + * framed so that bit 10 and bit 11 (stop bits) are mark and bit + * 1 (start bit) is space. When a valid character is found, the * survivor with maximum distance determines the final decoded * character. */ up->baud += 1. / SECOND; if (up->baud > 1. / (BAUD * 8.)) { up->baud -= 1. / (BAUD * 8.); + up->decptr = (up->decptr + 1) % 8; sp = &up->surv[up->decptr]; - span = sp->es_max - sp->es_min; - up->maxsignal += (span - up->maxsignal) / 80.; + sp->cstamp = up->timestamp; + chu_uart(sp, -lpf * AGAIN); if (up->dbrk > 0) { up->dbrk--; - } else if ((sp->uart & 0x403) == 0x401 && span > 1000.) - { - dist = 0; - j = 0; - for (i = 0; i < 8; i++) { - if (up->surv[i].dist > dist) { - dist = up->surv[i].dist; - j = i; - } + if (up->dbrk > 0) + return; + + up->decpha = up->decptr; + } + if (up->decptr != up->decpha) + return; + + dist = 0; + j = -1; + for (i = 0; i < 8; i++) { + + /* + * The timestamp is taken at the last bit, so + * for correct decoding we reqire sufficient + * span and correct start bit and two stop bits. + */ + if ((up->surv[i].uart & 0x601) != 0x600 || + up->surv[i].span < SPAN) + continue; + + if (up->surv[i].dist > dist) { + dist = up->surv[i].dist; + j = i; } - chu_decode(peer, (up->surv[j].uart >> 2) & - 0xff); - up->dbrk = 80; } - up->decptr = (up->decptr + 1) % 8; - chu_uart(sp, -lpf * AGAIN); + if (j < 0) + return; + + /* + * Process the character, then blank the decoder until + * the end of the next character.This sets the decoding + * phase of the entire burst from the phase of the first + * character. + */ + up->maxsignal = up->surv[j].span; + chu_decode(peer, (up->surv[j].uart >> 1) & 0xff, + up->surv[j].cstamp); + up->dbrk = 88; } } /* - * chu_uart - maximum likelihood UART + * chu_uart - maximum-likelihood UART * * This routine updates a shift register holding the last 11 envelope * samples. It then computes the slice level and span over these samples @@ -882,12 +927,15 @@ chu_uart( } /* - * Determine the slice level midway beteen the maximum and - * minimum and the span as the maximum less the minimum. Compute - * the distance on the assumption the first and last bits must - * be mark, the second space and the rest either mark or space. + * Determine the span as the maximum less the minimum and the + * slice level as the minimum plus a fraction of the span. Note + * the slight bias toward mark to correct for the modem tendency + * to make more mark than space errors. Compute the distance on + * the assumption the last two bits must be mark, the first + * space and the rest either mark or space. */ - slice = (es_max + es_min) / 2.; + sp->span = es_max - es_min; + slice = es_min + .45 * sp->span; dist = 0; sp->uart = 0; for (i = 1; i < 12; i++) { @@ -895,9 +943,9 @@ chu_uart( dtemp = sp->shift[i]; if (dtemp > slice) sp->uart |= 0x1; - if (i == 1 || i == 11) { + if (i == 1 || i == 2) { dist += dtemp - es_min; - } else if (i == 10) { + } else if (i == 11) { dist += es_max - dtemp; } else { if (dtemp > slice) @@ -906,9 +954,7 @@ chu_uart( dist += es_max - dtemp; } } - sp->es_max = es_max; - sp->es_min = es_min; - sp->dist = dist / (11 * (es_max - es_min)); + sp->dist = dist / (11 * sp->span); } #endif /* HAVE_AUDIO */ @@ -921,22 +967,14 @@ chu_serial_receive( struct recvbuf *rbufp /* receive buffer structure pointer */ ) { - struct chuunit *up; - struct refclockproc *pp; struct peer *peer; u_char *dpt; /* receive buffer pointer */ - peer = (struct peer *)rbufp->recv_srcclock; - pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + peer = rbufp->recv_peer; - /* - * Initialize pointers and read the timecode and timestamp. - */ - up->timestamp = rbufp->recv_time; dpt = (u_char *)&rbufp->recv_space; - chu_decode(peer, *dpt); + chu_decode(peer, *dpt, rbufp->recv_time); } @@ -946,7 +984,8 @@ chu_serial_receive( static void chu_decode( struct peer *peer, /* peer structure pointer */ - int hexhex /* data character */ + int hexhex, /* data character */ + l_fp cstamp /* data character timestamp */ ) { struct refclockproc *pp; @@ -956,7 +995,7 @@ chu_decode( double dtemp; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * If the interval since the last character is greater than the @@ -979,11 +1018,11 @@ chu_decode( /* * Append the character to the current burst and append the - * timestamp to the timestamp list. + * character timestamp to the timestamp list. */ if (up->ndx < BURST) { up->cbuf[up->ndx] = hexhex & 0xff; - up->cstamp[up->ndx] = up->timestamp; + up->cstamp[up->ndx] = cstamp; up->ndx++; } @@ -1004,7 +1043,7 @@ chu_burst( int i; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * Correlate a block of five characters with the next block of @@ -1012,7 +1051,7 @@ chu_burst( * of bits that match in the two blocks for format A and that * match the inverse for format B. */ - if (up->ndx < MINCHAR) { + if (up->ndx < MINCHARS) { up->status |= RUNT; return; } @@ -1061,23 +1100,35 @@ chu_b( u_char code[11]; /* decoded timecode */ char tbuf[80]; /* trace buffer */ - l_fp offset; /* timestamp offset */ + char * p; + size_t chars; + size_t cb; int i; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * In a format B burst, a character is considered valid only if - * the first occurrence matches the last occurrence. The burst - * is considered valid only if all characters are valid; that - * is, only if the distance is 40. Note that once a valid frame - * has been found errors are ignored. + * the first occurence matches the last occurence. The burst is + * considered valid only if all characters are valid; that is, + * only if the distance is 40. Note that once a valid frame has + * been found errors are ignored. */ - sprintf(tbuf, "chuB %04x %2d %2d ", up->status, nchar, - -up->burdist); - for (i = 0; i < nchar; i++) - sprintf(&tbuf[strlen(tbuf)], "%02x", up->cbuf[i]); + snprintf(tbuf, sizeof(tbuf), "chuB %04x %4.0f %2d %2d ", + up->status, up->maxsignal, nchar, -up->burdist); + cb = sizeof(tbuf); + p = tbuf; + for (i = 0; i < nchar; i++) { + chars = strlen(p); + if (cb < chars + 1) { + msyslog(LOG_ERR, "chu_b() fatal out buffer"); + exit(1); + } + cb -= chars; + p += chars; + snprintf(p, cb, "%02x", up->cbuf[i]); + } if (pp->sloppyclockflag & CLK_FLAG4) record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG @@ -1088,11 +1139,10 @@ chu_b( up->status |= BFRAME; return; } - up->status |= BVALID; /* - * Convert the burst data to internal format. If this succeeds, - * save the timestamps for later. + * Convert the burst data to internal format. Don't bother with + * the timestamps. */ for (i = 0; i < 5; i++) { code[2 * i] = hexchar[up->cbuf[i] & 0xf]; @@ -1104,17 +1154,9 @@ chu_b( up->status |= BFORMAT; return; } + up->status |= BVALID; if (up->leap & 0x8) up->dut = -up->dut; - offset.l_ui = 31; - offset.l_f = 0; - for (i = 0; i < nchar && i < 10; i++) { - up->tstamp[up->ntstamp] = up->cstamp[i]; - L_SUB(&up->tstamp[up->ntstamp], &offset); - L_ADD(&offset, &up->charstamp); - if (up->ntstamp < MAXSTAGE - 1) - up->ntstamp++; - } } @@ -1131,25 +1173,28 @@ chu_a( struct chuunit *up; char tbuf[80]; /* trace buffer */ + char * p; + size_t chars; + size_t cb; l_fp offset; /* timestamp offset */ int val; /* distance */ int temp; int i, j, k; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * Determine correct burst phase. There are three cases * corresponding to in-phase, one character early or one * character late. These cases are distinguished by the position - * of the framing digits x6 at positions 0 and 5 and x3 at + * of the framing digits 0x6 at positions 0 and 5 and 0x3 at * positions 4 and 9. The correct phase is when the distance * relative to the framing digits is maximum. The burst is valid * only if the maximum distance is at least MINSYNC. */ up->syndist = k = 0; - val = -16; + // val = -16; for (i = -1; i < 2; i++) { temp = up->cbuf[i + 4] & 0xf; if (i >= 0) @@ -1164,27 +1209,31 @@ chu_a( k = i; } } + + /* + * Extract the second number; it must be in the range 2 through + * 9 and the two repititions must be the same. + */ temp = (up->cbuf[k + 4] >> 4) & 0xf; - if (temp > 9 || k + 9 >= nchar || temp != ((up->cbuf[k + 9] >> - 4) & 0xf)) + if (temp < 2 || temp > 9 || k + 9 >= nchar || temp != + ((up->cbuf[k + 9] >> 4) & 0xf)) temp = 0; -#ifdef HAVE_AUDIO - if (up->fd_audio) - sprintf(tbuf, "chuA %04x %4.0f %2d %2d %2d %2d %1d ", - up->status, up->maxsignal, nchar, up->burdist, k, - up->syndist, temp); - else - sprintf(tbuf, "chuA %04x %2d %2d %2d %2d %1d ", - up->status, nchar, up->burdist, k, up->syndist, - temp); - -#else - sprintf(tbuf, "chuA %04x %2d %2d %2d %2d %1d ", up->status, - nchar, up->burdist, k, up->syndist, temp); -#endif /* HAVE_AUDIO */ - for (i = 0; i < nchar; i++) - sprintf(&tbuf[strlen(tbuf)], "%02x", - up->cbuf[i]); + snprintf(tbuf, sizeof(tbuf), + "chuA %04x %4.0f %2d %2d %2d %2d %1d ", up->status, + up->maxsignal, nchar, up->burdist, k, up->syndist, + temp); + cb = sizeof(tbuf); + p = tbuf; + for (i = 0; i < nchar; i++) { + chars = strlen(p); + if (cb < chars + 1) { + msyslog(LOG_ERR, "chu_a() fatal out buffer"); + exit(1); + } + cb -= chars; + p += chars; + snprintf(p, cb, "%02x", up->cbuf[i]); + } if (pp->sloppyclockflag & CLK_FLAG4) record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG @@ -1203,10 +1252,13 @@ chu_a( * processing. In addition, the seconds decode is advanced from * the previous burst to the current one. */ - if (temp != 0) { - pp->second = 30 + temp; + if (temp == 0) { + up->status |= AFORMAT; + } else { + up->status |= AVALID; + up->second = pp->second = 30 + temp; offset.l_ui = 30 + temp; - offset.l_f = 0; + offset.l_uf = 0; i = 0; if (k < 0) offset = up->charstamp; @@ -1216,7 +1268,7 @@ chu_a( up->tstamp[up->ntstamp] = up->cstamp[i]; L_SUB(&up->tstamp[up->ntstamp], &offset); L_ADD(&offset, &up->charstamp); - if (up->ntstamp < MAXSTAGE - 1) + if (up->ntstamp < MAXSTAGE - 1) up->ntstamp++; } while (temp > up->prevsec) { @@ -1229,6 +1281,10 @@ chu_a( up->prevsec++; } } + + /* + * Stash the data in the decoding matrix. + */ i = -(2 * k); for (j = 0; j < nchar; j++) { if (i < 0 || i > 18) { @@ -1240,7 +1296,6 @@ chu_a( up->decode[i][(up->cbuf[j] >> 4) & 0xf]++; i++; } - up->status |= AVALID; up->burstcnt++; } @@ -1255,6 +1310,22 @@ chu_poll( ) { struct refclockproc *pp; + + pp = peer->procptr; + pp->polls++; +} + + +/* + * chu_second - process minute data + */ +static void +chu_second( + int unit, + struct peer *peer /* peer structure pointer */ + ) +{ + struct refclockproc *pp; struct chuunit *up; l_fp offset; char synchar, qual, leapchar; @@ -1262,41 +1333,25 @@ chu_poll( double dtemp; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; - if (pp->coderecv == pp->codeproc) - up->errflg = CEVNT_TIMEOUT; - else - pp->polls++; + up = pp->unitptr; /* - * If once in sync and the radio has not been heard for awhile - * (30 m), it is no longer reachable. If not heard in a long - * while (one day), turn out the lights and start from scratch. + * This routine is called once per minute to process the + * accumulated burst data. We do a bit of fancy footwork so that + * this doesn't run while burst data are being accumulated. */ - minset = ((current_time - peer->update) + 30) / 60; - if (up->status & INSYNC) { - if (minset > PANIC) - up->status = 0; - else if (minset <= HOLD) - peer->reach |= 1; - } + up->second = (up->second + 1) % 60; + if (up->second != 0) + return; /* * Process the last burst, if still in the burst buffer. - * Don't mess with anything if nothing has been heard. If the - * minute contains a valid A frame and valid B frame, assume - * synchronized; however, believe the time only if within metric - * threshold. Note the quality indicator is only for - * diagnostics; the data are used only if in sync and above - * metric threshold. + * If the minute contains a valid B frame with sufficient A + * frame metric, it is considered valid. However, the timecode + * is sent to clockstats even if invalid. */ chu_burst(peer); - if (up->burstcnt == 0) { -#ifdef ICOM - chu_newchan(peer, 0); -#endif /* ICOM */ - return; - } + minset = ((current_time - peer->update) + 30) / 60; dtemp = chu_major(peer); qual = 0; if (up->status & (BFRAME | AFRAME)) @@ -1307,7 +1362,7 @@ chu_poll( qual |= DECERR; if (up->status & STAMP) qual |= TSPERR; - if (up->status & AVALID && up->status & BVALID) + if (up->status & BVALID && dtemp >= MINMETRIC) up->status |= INSYNC; synchar = leapchar = ' '; if (!(up->status & INSYNC)) { @@ -1322,35 +1377,20 @@ chu_poll( } else { pp->leap = LEAP_NOWARNING; } -#ifdef HAVE_AUDIO - if (up->fd_audio) - sprintf(pp->a_lastcode, - "%c%1X %04d %3d %02d:%02d:%02d %c%x %+d %d %d %s %.0f %d", - synchar, qual, pp->year, pp->day, pp->hour, - pp->minute, pp->second, leapchar, up->dst, up->dut, - minset, up->gain, up->ident, dtemp, up->ntstamp); - else - sprintf(pp->a_lastcode, - "%c%1X %04d %3d %02d:%02d:%02d %c%x %+d %d %s %.0f %d", - synchar, qual, pp->year, pp->day, pp->hour, - pp->minute, pp->second, leapchar, up->dst, up->dut, - minset, up->ident, dtemp, up->ntstamp); -#else - sprintf(pp->a_lastcode, - "%c%1X %04d %3d %02d:%02d:%02d %c%x %+d %d %s %.0f %d", + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%c%1X %04d %03d %02d:%02d:%02d %c%x %+d %d %d %s %.0f %d", synchar, qual, pp->year, pp->day, pp->hour, pp->minute, - pp->second, leapchar, up->dst, up->dut, minset, up->ident, - dtemp, up->ntstamp); -#endif /* HAVE_AUDIO */ + pp->second, leapchar, up->dst, up->dut, minset, up->gain, + up->ident, dtemp, up->ntstamp); pp->lencode = strlen(pp->a_lastcode); /* * If in sync and the signal metric is above threshold, the * timecode is ipso fatso valid and can be selected to - * discipline the clock. Be sure not to leave stray timestamps - * around if signals are too weak or the clock time is invalid. + * discipline the clock. */ - if (up->status & INSYNC && dtemp > METRIC) { + if (up->status & INSYNC && !(up->status & (DECODE | STAMP)) && + dtemp > MINMETRIC) { if (!clocktime(pp->day, pp->hour, pp->minute, 0, GMT, up->tstamp[0].l_ui, &pp->yearstart, &offset.l_ui)) { up->errflg = CEVNT_BADTIME; @@ -1358,15 +1398,14 @@ chu_poll( offset.l_uf = 0; for (i = 0; i < up->ntstamp; i++) refclock_process_offset(pp, offset, - up->tstamp[i], FUDGE + + up->tstamp[i], PDELAY + pp->fudgetime1); pp->lastref = up->timestamp; refclock_receive(peer); } - record_clock_stats(&peer->srcadr, pp->a_lastcode); - } else if (pp->sloppyclockflag & CLK_FLAG4) { - record_clock_stats(&peer->srcadr, pp->a_lastcode); } + if (dtemp > 0) + record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG if (debug) printf("chu: timecode %d %s\n", pp->lencode, @@ -1394,66 +1433,44 @@ chu_major( struct chuunit *up; u_char code[11]; /* decoded timecode */ - int mindist; /* minimum distance */ - int val1, val2; /* maximum distance */ + int metric; /* distance metric */ + int val1; /* maximum distance */ int synchar; /* stray cat */ int temp; int i, j, k; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * Majority decoder. Each burst encodes two replications at each * digit position in the timecode. Each row of the decoding - * matrix encodes the number of occurrences of each digit found + * matrix encodes the number of occurences of each digit found * at the corresponding position. The maximum over all * occurrences at each position is the distance for this - * position and the corresponding digit is the maximum - * likelihood candidate. If the distance is zero, assume a miss - * '_'; if the distance is not more than half the total number - * of occurrences, assume a soft error '*'; if two different - * digits with the same distance are found, assume a hard error - * '='. These will later cause a format error when the timecode - * is interpreted. The decoding distance is defined as the - * minimum distance over the first nine digits. The tenth digit - * varies over the seconds, so we don't count it. + * position and the corresponding digit is the maximum- + * likelihood candidate. If the distance is not more than half + * the total number of occurences, a majority has not been found + * and the data are discarded. The decoding distance is defined + * as the sum of the distances over the first nine digits. The + * tenth digit varies over the seconds, so we don't count it. */ - mindist = 16; + metric = 0; for (i = 0; i < 9; i++) { - val1 = val2 = 0; + val1 = 0; k = 0; for (j = 0; j < 16; j++) { temp = up->decode[i][j] + up->decode[i + 10][j]; if (temp > val1) { - val2 = val1; val1 = temp; k = j; } } - if (val1 == 0) - code[i] = HEX_MISS; - else if (val1 == val2) - code[i] = HEX_HARD; - else if (val1 <= up->burstcnt) - code[i] = HEX_SOFT; - else - code[i] = k; - if (val1 < mindist) - mindist = val1; - code[i] = hexchar[code[i]]; + if (val1 <= up->burstcnt) + up->status |= DECODE; + metric += val1; + code[i] = hexchar[k]; } - code[i] = 0; - - /* - * A valid timecode requires a minimum distance at least half - * the total number of occurrences. A valid timecode also - * requires at least 20 valid timestamps. - */ - if (up->burstcnt < MINBURST || mindist < up->burstcnt) - up->status |= DECODE; - if (up->ntstamp < MINSTAMP) - up->status |= STAMP; /* * Compute the timecode timestamp from the days, hours and @@ -1463,15 +1480,11 @@ chu_major( * for the years and does not use the years of the timecode. */ if (sscanf((char *)code, "%1x%3d%2d%2d", &synchar, &pp->day, - &pp->hour, &pp->minute) != 4) { - up->status |= AFORMAT; - return (0); - } - if (up->status & (DECODE | STAMP)) { - up->errflg = CEVNT_BADREPLY; - return (0); - } - return (mindist * 100. / (2. * up->burstcnt)); + &pp->hour, &pp->minute) != 4) + up->status |= DECODE; + if (up->ntstamp < MINSTAMP) + up->status |= STAMP; + return (metric); } @@ -1488,14 +1501,14 @@ chu_clear( int i, j; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * Clear stuff for the minute. */ up->ndx = up->prevsec = 0; up->burstcnt = up->ntstamp = 0; - up->status &= INSYNC; + up->status &= INSYNC | METRIC; for (i = 0; i < 20; i++) { for (j = 0; j < 16; j++) up->decode[i][j] = 0; @@ -1516,99 +1529,77 @@ chu_newchan( struct chuunit *up; struct refclockproc *pp; struct xmtr *sp; - char tbuf[80]; /* trace buffer */ int rval; double metric; - int i, j; + int i; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * The radio can be tuned to three channels: 0 (3330 kHz), 1 - * (7335 kHz) and 2 (14670 kHz). There are five one-minute + * (7850 kHz) and 2 (14670 kHz). There are five one-minute * dwells in each cycle. During the first dwell the radio is - * tuned to one of three probe channels; during the remaining - * four dwells the radio is tuned to the data channel. The probe - * channel is selects as the least recently used. At the end of - * each dwell the channel metrics are measured and the highest - * one is selected as the data channel. + * tuned to one of the three channels to measure the channel + * metric. The channel is selected as the one least recently + * measured. During the remaining four dwells the radio is tuned + * to the channel with the highest channel metric. */ if (up->fd_icom <= 0) return (0); - sp = &up->xmtr[up->achan]; + /* + * Update the current channel metric and age of all channels. + * Scan all channels for the highest metric. + */ + sp = &up->xmtr[up->chan]; sp->metric -= sp->integ[sp->iptr]; sp->integ[sp->iptr] = met; sp->metric += sp->integ[sp->iptr]; + sp->probe = 0; sp->iptr = (sp->iptr + 1) % ISTAGE; metric = 0; - j = 0; for (i = 0; i < NCHAN; i++) { up->xmtr[i].probe++; - if (i == up->achan) - up->xmtr[i].probe = 0; - if (up->xmtr[i].metric < metric) - continue; - metric = up->xmtr[i].metric; - j = i; - } - if (j != up->chan && metric > 0) { - up->chan = j; - sprintf(tbuf, "chu: QSY to %.3f MHz metric %.0f", - qsy[up->chan], metric); - if (pp->sloppyclockflag & CLK_FLAG4) - record_clock_stats(&peer->srcadr, tbuf); -#ifdef DEBUG - if (debug) - printf("%s\n", tbuf); -#endif + if (up->xmtr[i].metric > metric) { + up->status |= METRIC; + metric = up->xmtr[i].metric; + up->chan = i; + } } /* - * Start the next dwell. We speed up the initial sync a little. - * If not in sync and no bursts were heard the previous dwell, - * restart the probe. + * Start the next dwell. If the first dwell or no stations have + * been heard, continue round-robin scan. */ - rval = 0; - if (up->burstcnt == 0 && !(up->status & INSYNC)) - up->dwell = 0; -#ifdef DEBUG - if (debug) - printf( - "chu: at %ld dwell %d achan %d metric %.0f chan %d\n", - current_time, up->dwell, up->achan, sp->metric, - up->chan); -#endif - if (up->dwell == 0) { + up->dwell = (up->dwell + 1) % DWELL; + if (up->dwell == 0 || metric == 0) { rval = 0; for (i = 0; i < NCHAN; i++) { - if (up->xmtr[i].probe < rval) - continue; - rval = up->xmtr[i].probe; - up->achan = i; - } - rval = icom_freq(up->fd_icom, peer->ttl & 0x7f, - qsy[up->achan] + TUNE); -#ifdef DEBUG - if (debug) - printf("chu: at %ld probe channel %d\n", - current_time, up->achan); -#endif - } else { - if (up->achan != up->chan) { - rval = icom_freq(up->fd_icom, peer->ttl & 0x7f, - qsy[up->chan] + TUNE); - up->achan = up->chan; + if (up->xmtr[i].probe > rval) { + rval = up->xmtr[i].probe; + up->chan = i; + } } } - sprintf(up->ident, "CHU%d", up->achan); - memcpy(&peer->refid, up->ident, 4); - up->dwell = (up->dwell + 1) % DWELL; + + /* Retune the radio at each dwell in case somebody nudges the + * tuning knob. + */ + rval = icom_freq(up->fd_icom, peer->ttl & 0x7f, qsy[up->chan] + + TUNE); + snprintf(up->ident, sizeof(up->ident), "CHU%d", up->chan); + memcpy(&pp->refid, up->ident, 4); + memcpy(&peer->refid, up->ident, 4); + if (metric == 0 && up->status & METRIC) { + up->status &= ~METRIC; + refclock_report(peer, CEVNT_PROP); + } return (rval); } #endif /* ICOM */ + /* * chu_dist - determine the distance of two octet arguments */ @@ -1645,11 +1636,12 @@ chu_dist( /* * chu_gain - adjust codec gain * - * This routine is called once each second. If the signal envelope - * amplitude is too low, the codec gain is bumped up by four units; if - * too high, it is bumped down. The decoder is relatively insensitive to - * amplitude, so this crudity works just fine. The input port is set and - * the error flag is cleared, mostly to be ornery. + * This routine is called at the end of each second. During the second + * the number of signal clips above the MAXAMP threshold (6000). If + * there are no clips, the gain is bumped up; if there are more than + * MAXCLP clips (100), it is bumped down. The decoder is relatively + * insensitive to amplitude, so this crudity works just peachy. The + * routine also jiggles the input port and selectively mutes the */ static void chu_gain( @@ -1660,7 +1652,7 @@ chu_gain( struct chuunit *up; pp = peer->procptr; - up = (struct chuunit *)pp->unitptr; + up = pp->unitptr; /* * Apparently, the codec uses only the high order bits of the @@ -1683,5 +1675,5 @@ chu_gain( #else -int refclock_chu_bs; +NONEMPTY_TRANSLATION_UNIT #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_conf.c b/contrib/ntp/ntpd/refclock_conf.c index dc29d1e79..30cc63206 100644 --- a/contrib/ntp/ntpd/refclock_conf.c +++ b/contrib/ntp/ntpd/refclock_conf.c @@ -24,12 +24,6 @@ extern struct refclock refclock_local; #define refclock_local refclock_none #endif -#if 0 && defined(CLOCK_TRAK) && defined(PPS) -extern struct refclock refclock_trak; -#else -#define refclock_trak refclock_none -#endif - #ifdef CLOCK_PST extern struct refclock refclock_pst; #else @@ -138,7 +132,7 @@ extern struct refclock refclock_nmea; #define refclock_nmea refclock_none #endif -#ifdef CLOCK_ATOM +#if defined (CLOCK_ATOM) && defined(HAVE_PPSAPI) extern struct refclock refclock_atom; #else #define refclock_atom refclock_none @@ -168,8 +162,8 @@ extern struct refclock refclock_shm; #define refclock_shm refclock_none #endif -#ifdef CLOCK_PALISADE -extern struct refclock refclock_palisade; +#ifdef CLOCK_PALISADE +extern struct refclock refclock_palisade; #else #define refclock_palisade refclock_none #endif @@ -258,13 +252,24 @@ extern struct refclock refclock_neoclock4x; #define refclock_neoclock4x refclock_none #endif +#ifdef CLOCK_TSYNCPCI +extern struct refclock refclock_tsyncpci; +#else +#define refclock_tsyncpci refclock_none +#endif + +#if defined(CLOCK_GPSDJSON) && !defined(SYS_WINNT) +extern struct refclock refclock_gpsdjson; +#else +#define refclock_gpsdjson refclock_none +#endif /* * Order is clock_start(), clock_shutdown(), clock_poll(), * clock_control(), clock_init(), clock_buginfo, clock_flags; * * Types are defined in ntp.h. The index must match this. */ -struct refclock *refclock_conf[] = { +struct refclock * const refclock_conf[] = { &refclock_none, /* 0 REFCLK_NONE */ &refclock_local, /* 1 REFCLK_LOCAL */ &refclock_none, /* 2 deprecated: REFCLK_GPS_TRAK */ @@ -309,7 +314,9 @@ struct refclock *refclock_conf[] = { &refclock_tt560, /* 41 REFCLK_TT560 */ &refclock_zyfer, /* 42 REFCLK_ZYFER */ &refclock_ripencc, /* 43 REFCLK_RIPENCC */ - &refclock_neoclock4x /* 44 REFCLK_NEOCLOCK4X */ + &refclock_neoclock4x, /* 44 REFCLK_NEOCLOCK4X */ + &refclock_tsyncpci, /* 45 REFCLK_TSYNCPCI */ + &refclock_gpsdjson /* 46 REFCLK_GPSDJSON */ }; u_char num_refclock_conf = sizeof(refclock_conf)/sizeof(struct refclock *); diff --git a/contrib/ntp/ntpd/refclock_datum.c b/contrib/ntp/ntpd/refclock_datum.c index b26fe73cf..95f13a8c0 100644 --- a/contrib/ntp/ntpd/refclock_datum.c +++ b/contrib/ntp/ntpd/refclock_datum.c @@ -11,6 +11,8 @@ # include #endif +#include "ntp_types.h" + #if defined(REFCLOCK) && defined(CLOCK_DATUM) /* @@ -19,29 +21,16 @@ #include "ntpd.h" #include "ntp_io.h" +#include "ntp_tty.h" #include "ntp_refclock.h" -#include "ntp_unixtime.h" +#include "timevalops.h" #include "ntp_stdlib.h" #include #include -#if defined(HAVE_BSD_TTYS) -#include -#endif /* HAVE_BSD_TTYS */ - -#if defined(HAVE_SYSV_TTYS) -#include -#endif /* HAVE_SYSV_TTYS */ - -#if defined(HAVE_TERMIOS) -#include -#endif #if defined(STREAM) #include -#if defined(WWVBCLK) -#include -#endif /* WWVBCLK */ #endif /* STREAM */ #include "ntp_stdlib.h" @@ -139,7 +128,6 @@ struct datum_pts_unit { struct peer *peer; /* peer used by ntp */ - struct refclockio io; /* io structure used by ntp */ int PTS_fd; /* file descriptor for PTS */ u_int unit; /* id for unit */ u_long timestarted; /* time started */ @@ -166,20 +154,18 @@ struct datum_pts_unit { static char TIME_REQUEST[6]; /* request message sent to datum for time */ static int nunits; /* number of active units */ -static struct datum_pts_unit -**datum_pts_unit; /* dynamic array of datum PTS structures */ /* ** Callback function prototypes that ntpd needs to know about. */ -static int datum_pts_start P((int, struct peer *)); -static void datum_pts_shutdown P((int, struct peer *)); -static void datum_pts_poll P((int, struct peer *)); -static void datum_pts_control P((int, struct refclockstat *, - struct refclockstat *, struct peer *)); -static void datum_pts_init P((void)); -static void datum_pts_buginfo P((int, struct refclockbug *, struct peer *)); +static int datum_pts_start (int, struct peer *); +static void datum_pts_shutdown (int, struct peer *); +static void datum_pts_poll (int, struct peer *); +static void datum_pts_control (int, const struct refclockstat *, + struct refclockstat *, struct peer *); +static void datum_pts_init (void); +static void datum_pts_buginfo (int, struct refclockbug *, struct peer *); /* ** This is the call back function structure that ntpd actually uses for @@ -219,7 +205,7 @@ struct refclock refclock_datum = { ** the adjtime() call. */ -static void datum_pts_receive P((struct recvbuf *)); +static void datum_pts_receive (struct recvbuf *); /*......................................................................*/ /* datum_pts_start - start up the datum PTS. This means open the */ @@ -232,10 +218,11 @@ datum_pts_start( struct peer *peer ) { - struct datum_pts_unit **temp_datum_pts_unit; + struct refclockproc *pp; struct datum_pts_unit *datum_pts; int fd; #ifdef HAVE_TERMIOS + int rc; struct termios arg; #endif @@ -257,24 +244,16 @@ datum_pts_start( /* ** Create the memory for the new unit */ - - temp_datum_pts_unit = (struct datum_pts_unit **) - malloc((nunits+1)*sizeof(struct datum_pts_unit *)); - if (nunits > 0) memcpy(temp_datum_pts_unit, datum_pts_unit, - nunits*sizeof(struct datum_pts_unit *)); - free(datum_pts_unit); - datum_pts_unit = temp_datum_pts_unit; - datum_pts_unit[nunits] = (struct datum_pts_unit *) - malloc(sizeof(struct datum_pts_unit)); - datum_pts = datum_pts_unit[nunits]; - + datum_pts = emalloc_zero(sizeof(*datum_pts)); datum_pts->unit = unit; /* set my unit id */ datum_pts->yearstart = 0; /* initialize the yearstart to 0 */ datum_pts->sigma2 = 0.0; /* initialize the sigma2 to 0 */ datum_pts->PTS_fd = fd; - fcntl(datum_pts->PTS_fd, F_SETFL, 0); /* clear the descriptor flags */ + if (-1 == fcntl(datum_pts->PTS_fd, F_SETFL, 0)) /* clear the descriptor flags */ + msyslog(LOG_ERR, "MSF_ARCRON(%d): fcntl(F_SETFL, 0): %m.", + unit); #ifdef DEBUG_DATUM_PTC if (debug) @@ -290,7 +269,7 @@ datum_pts_start( ** ntp folks so that it can become part of their regular distribution. */ -#ifdef HAVE_TERMIOS + memset(&arg, 0, sizeof(arg)); arg.c_iflag = IGNBRK; arg.c_oflag = 0; @@ -299,43 +278,39 @@ datum_pts_start( arg.c_cc[VMIN] = 0; /* start timeout timer right away (not used) */ arg.c_cc[VTIME] = 30; /* 3 second timout on reads (not used) */ - tcsetattr(datum_pts->PTS_fd, TCSANOW, &arg); - -#else - - msyslog(LOG_ERR, "Datum_PTS: Termios not supported in this driver"); - (void)close(datum_pts->PTS_fd); - - peer->precision = PRECISION; - pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); - - return 0; - -#endif + rc = tcsetattr(datum_pts->PTS_fd, TCSANOW, &arg); + if (rc < 0) { + msyslog(LOG_ERR, "Datum_PTS: tcsetattr(\"%s\") failed: %m", DATUM_DEV); + close(datum_pts->PTS_fd); + free(datum_pts); + return 0; + } /* ** Initialize the ntpd IO structure */ datum_pts->peer = peer; - datum_pts->io.clock_recv = datum_pts_receive; - datum_pts->io.srcclock = (caddr_t)datum_pts; - datum_pts->io.datalen = 0; - datum_pts->io.fd = datum_pts->PTS_fd; - - if (!io_addclock(&(datum_pts->io))) { - + pp = peer->procptr; + pp->io.clock_recv = datum_pts_receive; + pp->io.srcclock = peer; + pp->io.datalen = 0; + pp->io.fd = datum_pts->PTS_fd; + + if (!io_addclock(&pp->io)) { + pp->io.fd = -1; #ifdef DEBUG_DATUM_PTC if (debug) printf("Problem adding clock\n"); #endif msyslog(LOG_ERR, "Datum_PTS: Problem adding clock"); - (void)close(datum_pts->PTS_fd); + close(datum_pts->PTS_fd); + free(datum_pts); return 0; } + peer->procptr->unitptr = datum_pts; /* ** Now add one to the number of units and return a successful code @@ -358,8 +333,8 @@ datum_pts_shutdown( struct peer *peer ) { - int i,j; - struct datum_pts_unit **temp_datum_pts_unit; + struct refclockproc *pp; + struct datum_pts_unit *datum_pts; #ifdef DEBUG_DATUM_PTC if (debug) @@ -369,64 +344,18 @@ datum_pts_shutdown( msyslog(LOG_ERR, "Datum_PTS: Shutdown Datum PTS"); /* - ** First we have to find the right unit (i.e., the one with the same id). - ** We do this by looping through the dynamic array of units intil we find - ** it. Note, that I don't simply use an array with a maximimum number of - ** Datum PTS units. Everything is completely dynamic. + ** We found the unit so close the file descriptor and free up the memory used + ** by the structure. */ - - for (i=0; iunit == unit) { - - /* - ** We found the unit so close the file descriptor and free up the memory used - ** by the structure. - */ - - io_closeclock(&datum_pts_unit[i]->io); - close(datum_pts_unit[i]->PTS_fd); - free(datum_pts_unit[i]); - - /* - ** Now clean up the datum_pts_unit dynamic array so that there are no holes. - ** This may mean moving pointers around, etc., to keep things compact. - */ - - if (nunits > 1) { - - temp_datum_pts_unit = (struct datum_pts_unit **) - malloc((nunits-1)*sizeof(struct datum_pts_unit *)); - if (i!= 0) memcpy(temp_datum_pts_unit, datum_pts_unit, - i*sizeof(struct datum_pts_unit *)); - - for (j=i+1; jprocptr; + datum_pts = pp->unitptr; + if (NULL != datum_pts) { + io_closeclock(&pp->io); + free(datum_pts); } - -#ifdef DEBUG_DATUM_PTC - if (debug) - printf("Error, could not shut down unit %d\n",unit); -#endif - - msyslog(LOG_ERR, "Datum_PTS: Could not shut down Datum PTS unit %d",unit); - } + /*......................................................................*/ /* datum_pts_poll - this routine sends out the time request to the */ /* Datum PTS device. The time will be passed back in the */ @@ -439,11 +368,11 @@ datum_pts_poll( struct peer *peer ) { - int i; - int unit_index; int error_code; struct datum_pts_unit *datum_pts; + datum_pts = peer->procptr->unitptr; + #ifdef DEBUG_DATUM_PTC if (debug) printf("Poll Datum PTS\n"); @@ -452,35 +381,10 @@ datum_pts_poll( /* ** Find the right unit and send out a time request once it is found. */ - - unit_index = -1; - for (i=0; iunit == unit) { - unit_index = i; - datum_pts = datum_pts_unit[i]; - error_code = write(datum_pts->PTS_fd, TIME_REQUEST, 6); - if (error_code != 6) perror("TIME_REQUEST"); - datum_pts->nbytes = 0; - break; - } - } - - /* - ** Print out an error message if we could not find the right unit. - */ - - if (unit_index == -1) { - -#ifdef DEBUG_DATUM_PTC - if (debug) - printf("Error, could not poll unit %d\n",unit); -#endif - - msyslog(LOG_ERR, "Datum_PTS: Could not poll unit %d",unit); - return; - - } - + error_code = write(datum_pts->PTS_fd, TIME_REQUEST, 6); + if (error_code != 6) + perror("TIME_REQUEST"); + datum_pts->nbytes = 0; } @@ -491,7 +395,7 @@ datum_pts_poll( static void datum_pts_control( int unit, - struct refclockstat *in, + const struct refclockstat *in, struct refclockstat *out, struct peer *peer ) @@ -542,7 +446,6 @@ datum_pts_init(void) ** NULL since there are no units defined yet. */ - datum_pts_unit = NULL; nunits = 0; } @@ -584,6 +487,7 @@ datum_pts_receive( { int i; l_fp tstmp; + struct peer *p; struct datum_pts_unit *datum_pts; char *dpt; int dpend; @@ -600,13 +504,14 @@ datum_pts_receive( ** Get the time code (maybe partial) message out of the rbufp buffer. */ - datum_pts = (struct datum_pts_unit *)rbufp->recv_srcclock; + p = rbufp->recv_peer; + datum_pts = p->procptr->unitptr; dpt = (char *)&rbufp->recv_space; dpend = rbufp->recv_length; #ifdef DEBUG_DATUM_PTC if (debug) - printf("Receive Datum PTS: %d bytes\n", dpend); + printf("Receive Datum PTS: %d bytes\n", dpend); #endif /* */ @@ -873,5 +778,5 @@ datum_pts_receive( } #else -int refclock_datum_bs; +NONEMPTY_TRANSLATION_UNIT #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_dumbclock.c b/contrib/ntp/ntpd/refclock_dumbclock.c index 10ff2cfe8..89f0f4748 100644 --- a/contrib/ntp/ntpd/refclock_dumbclock.c +++ b/contrib/ntp/ntpd/refclock_dumbclock.c @@ -35,7 +35,7 @@ extern int async_write(int, const void *, unsigned int); * * Input format: * - * hh:mm:ss + * hh:mm:ss * * hh:mm:ss -- what you'd expect, with a 24 hour clock. (Heck, that's the only * way it could get stupider.) We take time on the . @@ -64,21 +64,21 @@ extern int async_write(int, const void *, unsigned int); * Dumb clock control structure */ struct dumbclock_unit { - u_char tcswitch; /* timecode switch */ - l_fp laststamp; /* last receive timestamp */ - u_char lasthour; /* last hour (for monitor) */ - u_char linect; /* count ignored lines (for monitor */ - struct tm ymd; /* struct tm for y/m/d only */ + u_char tcswitch; /* timecode switch */ + l_fp laststamp; /* last receive timestamp */ + u_char lasthour; /* last hour (for monitor) */ + u_char linect; /* count ignored lines (for monitor */ + struct tm ymd; /* struct tm for y/m/d only */ }; /* * Function prototypes */ -static int dumbclock_start P((int, struct peer *)); -static void dumbclock_shutdown P((int, struct peer *)); -static void dumbclock_receive P((struct recvbuf *)); +static int dumbclock_start (int, struct peer *); +static void dumbclock_shutdown (int, struct peer *); +static void dumbclock_receive (struct recvbuf *); #if 0 -static void dumbclock_poll P((int, struct peer *)); +static void dumbclock_poll (int, struct peer *); #endif /* @@ -115,33 +115,30 @@ dumbclock_start( * Open serial port. Don't bother with CLK line discipline, since * it's not available. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); #ifdef DEBUG if (debug) printf ("starting Dumbclock with device %s\n",device); #endif fd = refclock_open(device, SPEED232, 0); - if (fd < 0) + if (fd <= 0) return (0); /* * Allocate and initialize unit structure */ - up = (struct dumbclock_unit *)emalloc(sizeof(struct dumbclock_unit)); - if (up == NULL) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct dumbclock_unit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->io.clock_recv = dumbclock_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -153,14 +150,10 @@ dumbclock_start( tm_time_p = gmtime(&now); #endif if (tm_time_p) - { - up->ymd = *tm_time_p; - } + up->ymd = *tm_time_p; else - { - return 0; - } - + return 0; + /* * Initialize miscellaneous variables */ @@ -184,9 +177,11 @@ dumbclock_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct dumbclock_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -202,19 +197,19 @@ dumbclock_receive( struct refclockproc *pp; struct peer *peer; - l_fp trtmp; /* arrival timestamp */ - int hours; /* hour-of-day */ - int minutes; /* minutes-past-the-hour */ - int seconds; /* seconds */ - int temp; /* int temp */ - int got_good; /* got a good time flag */ + l_fp trtmp; /* arrival timestamp */ + int hours; /* hour-of-day */ + int minutes; /* minutes-past-the-hour */ + int seconds; /* seconds */ + int temp; /* int temp */ + int got_good; /* got a good time flag */ /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct dumbclock_unit *)pp->unitptr; + up = pp->unitptr; temp = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &trtmp); if (temp == 0) { @@ -222,7 +217,7 @@ dumbclock_receive( up->tcswitch = 1; up->laststamp = trtmp; } else - up->tcswitch = 0; + up->tcswitch = 0; return; } pp->lencode = (u_short)temp; @@ -249,16 +244,18 @@ dumbclock_receive( struct tm asserted_tm; /* the struct tm of the same */ int adjyear; int adjmon; - int reality_delta; + time_t reality_delta; time_t now; /* * Convert to GMT for sites that distribute localtime. This - * means we have to figure out what day it is. Easier said + * means we have to figure out what day it is. Easier said * than done... */ + memset(&asserted_tm, 0, sizeof(asserted_tm)); + asserted_tm.tm_year = up->ymd.tm_year; asserted_tm.tm_mon = up->ymd.tm_mon; asserted_tm.tm_mday = up->ymd.tm_mday; @@ -366,7 +363,7 @@ dumbclock_poll( */ #if 0 pp = peer->procptr; - up = (struct dumbclock_unit *)pp->unitptr; + up = pp->unitptr; if (peer->reach == 0) refclock_report(peer, CEVNT_TIMEOUT); if (up->linect > 0) @@ -383,4 +380,4 @@ dumbclock_poll( #else int refclock_dumbclock_bs; -#endif /* REFCLOCK */ +#endif /* defined(REFCLOCK) && defined(CLOCK_DUMBCLOCK) */ diff --git a/contrib/ntp/ntpd/refclock_fg.c b/contrib/ntp/ntpd/refclock_fg.c index ce5085a75..d5915da3b 100644 --- a/contrib/ntp/ntpd/refclock_fg.c +++ b/contrib/ntp/ntpd/refclock_fg.c @@ -33,20 +33,20 @@ /* * Function prototypes */ -static int fg_init P((int)); -static int fg_start P((int, struct peer *)); -static void fg_shutdown P((int, struct peer *)); -static void fg_poll P((int, struct peer *)); -static void fg_receive P((struct recvbuf *)); +static int fg_init (int); +static int fg_start (int, struct peer *); +static void fg_shutdown (int, struct peer *); +static void fg_poll (int, struct peer *); +static void fg_receive (struct recvbuf *); /* * Forum Graphic unit control structure */ struct fgunit { - int pollnum; /* Use peer.poll instead? */ - int status; /* Hug to check status information on GPS */ - int y2kwarn; /* Y2K bug */ + int pollnum; /* Use peer.poll instead? */ + int status; /* Hug to check status information on GPS */ + int y2kwarn; /* Y2K bug */ }; /* @@ -61,13 +61,13 @@ static char fgdate[] = { 0x10, 0x44, 0x10, 0x0D, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 * Transfer vector */ struct refclock refclock_fg = { - fg_start, /* start up driver */ - fg_shutdown, /* shut down driver */ - fg_poll, /* transmit poll message */ - noentry, /* not used */ - noentry, /* initialize driver (not used) */ - noentry, /* not used */ - NOFLAGS /* not used */ + fg_start, /* start up driver */ + fg_shutdown, /* shut down driver */ + fg_poll, /* transmit poll message */ + noentry, /* not used */ + noentry, /* initialize driver (not used) */ + noentry, /* not used */ + NOFLAGS /* not used */ }; /* @@ -76,14 +76,13 @@ struct refclock refclock_fg = { static int fg_init( - int fd - ) + int fd + ) { if (write(fd, fginit, LENFG) != LENFG) - return 0; - - return (1); + return 0; + return 1; } /* @@ -91,7 +90,7 @@ fg_init( */ static int fg_start( - int unit, + int unit, struct peer *peer ) { @@ -104,35 +103,31 @@ fg_start( /* * Open device file for reading. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); -#ifdef DEBUG - if (debug) - printf ("starting FG with device %s\n",device); -#endif - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) - return (0); + DPRINTF(1, ("starting FG with device %s\n",device)); + + fd = refclock_open(device, SPEED232, LDISC_CLK); + if (fd <= 0) + return (0); - /* - * Allocate and initialize unit structure - */ - - if (!(up = (struct fgunit *) - emalloc(sizeof(struct fgunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct fgunit)); + /* + * Allocate and initialize unit structure + */ + + up = emalloc(sizeof(struct fgunit)); + memset(up, 0, sizeof(struct fgunit)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->io.clock_recv = fg_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); - return (0); - } + close(fd); + pp->io.fd = -1; + return 0; + } /* @@ -140,13 +135,13 @@ fg_start( */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 3); + memcpy(&pp->refid, REFID, 3); up->pollnum = 0; /* * Setup dating station to use GPS receiver. * GPS receiver should work before this operation. - */ + */ if(!fg_init(pp->io.fd)) refclock_report(peer, CEVNT_FAULT); @@ -167,9 +162,11 @@ fg_shutdown( struct fgunit *up; pp = peer->procptr; - up = (struct fgunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (pp->io.fd != -1) + io_closeclock(&pp->io); + if (up != NULL) + free(up); } @@ -186,30 +183,26 @@ fg_poll( pp = peer->procptr; - /* - * Time to poll the clock. The FG clock responds to a - * "D" by returning a timecode in the format specified - * above. If nothing is heard from the clock for two polls, - * declare a timeout and keep going. - */ + /* + * Time to poll the clock. The FG clock responds to a + * "D" by returning a timecode in the format specified + * above. If nothing is heard from the clock for two polls, + * declare a timeout and keep going. + */ if (write(pp->io.fd, fgdate, LENFG) != LENFG) - refclock_report(peer, CEVNT_FAULT); - else - pp->polls++; + refclock_report(peer, CEVNT_FAULT); + else + pp->polls++; - if (peer->burst > 0) - return; /* - if (pp->coderecv == pp->codeproc) { - refclock_report(peer, CEVNT_TIMEOUT); - return; - } + if (pp->coderecv == pp->codeproc) { + refclock_report(peer, CEVNT_TIMEOUT); + return; + } */ - peer->burst = NSTAGE; - record_clock_stats(&peer->srcadr, pp->a_lastcode); - + record_clock_stats(&peer->srcadr, pp->a_lastcode); return; @@ -220,36 +213,34 @@ fg_poll( */ static void fg_receive( - struct recvbuf *rbufp - ) + struct recvbuf *rbufp + ) { - struct refclockproc *pp; + struct refclockproc *pp; struct fgunit *up; - struct peer *peer; + struct peer *peer; char *bpt; - /* - * Initialize pointers and read the timecode and timestamp + /* + * Initialize pointers and read the timecode and timestamp * We can't use gtlin function because we need bynary data in buf */ - peer = (struct peer *)rbufp->recv_srcclock; - pp = peer->procptr; - up = (struct fgunit *)pp->unitptr; + peer = rbufp->recv_peer; + pp = peer->procptr; + up = pp->unitptr; /* - * Below hug to implement receiving of status information - */ - if(!up->pollnum) - { + * Below hug to implement receiving of status information + */ + if(!up->pollnum) { up->pollnum++; return; } - if (rbufp->recv_length < (LENFG-2)) - { + if (rbufp->recv_length < (LENFG - 2)) { refclock_report(peer, CEVNT_BADREPLY); - return; /* The reply is invalid discard it. */ + return; /* The reply is invalid discard it. */ } /* Below I trying to find a correct reply in buffer. @@ -258,30 +249,29 @@ fg_receive( */ bpt = (char *)rbufp->recv_space.X_recv_buffer; - while(*bpt != '') + while (*bpt != '\x10') bpt++; #define BP2(x) ( bpt[x] & 15 ) #define BP1(x) (( bpt[x] & 240 ) >> 4) - pp->year = BP1(2)*10 + BP2(2); + pp->year = BP1(2) * 10 + BP2(2); - if(pp->year == 94) - { + if (pp->year == 94) { refclock_report(peer, CEVNT_BADREPLY); - if(!fg_init(pp->io.fd)) + if (!fg_init(pp->io.fd)) refclock_report(peer, CEVNT_FAULT); - return; + return; /* GPS is just powered up. The date is invalid - discarding it. Initilize GPS one more time */ /* Sorry - this driver will broken in 2094 ;) */ } if (pp->year < 99) - pp->year += 100; + pp->year += 100; - pp->year += 1900; - pp->day = 100 * BP2(3) + 10 * BP1(4) + BP2(4); + pp->year += 1900; + pp->day = 100 * BP2(3) + 10 * BP1(4) + BP2(4); /* After Jan, 10 2000 Forum Graphic GPS receiver had a very strange @@ -290,51 +280,51 @@ fg_receive( Hope it is a problem of my unit only and not a Y2K problem of FG GPS. Below small code to avoid such situation. */ - if(up->y2kwarn > 10) - pp->hour = BP1(6)*10 + BP2(6); + if (up->y2kwarn > 10) + pp->hour = BP1(6)*10 + BP2(6); else - pp->hour = BP1(5)*10 + BP2(5); - - if((up->y2kwarn > 10) && (pp->hour == 10)) - { - pp->minute = BP1(7)*10 + BP2(7); - pp->second = BP1(8)*10 + BP2(8); - pp->nsec = (BP1(9)*10 + BP2(9)) * 1000000; - pp->nsec += BP1(10) * 1000; + pp->hour = BP1(5)*10 + BP2(5); + + if ((up->y2kwarn > 10) && (pp->hour == 10)) { + pp->minute = BP1(7)*10 + BP2(7); + pp->second = BP1(8)*10 + BP2(8); + pp->nsec = (BP1(9)*10 + BP2(9)) * 1000000; + pp->nsec += BP1(10) * 1000; } else { - pp->hour = BP1(5)*10 + BP2(5); - pp->minute = BP1(6)*10 + BP2(6); - pp->second = BP1(7)*10 + BP2(7); - pp->nsec = (BP1(8)*10 + BP2(8)) * 1000000; - pp->nsec += BP1(9) * 1000; + pp->hour = BP1(5)*10 + BP2(5); + pp->minute = BP1(6)*10 + BP2(6); + pp->second = BP1(7)*10 + BP2(7); + pp->nsec = (BP1(8)*10 + BP2(8)) * 1000000; + pp->nsec += BP1(9) * 1000; } - - if((pp->hour == 10) && (pp->minute == 10)) - { + + if ((pp->hour == 10) && (pp->minute == 10)) { up->y2kwarn++; } - sprintf(pp->a_lastcode, "%d %d %d %d %d", pp->year, pp->day, pp->hour, pp->minute, pp->second); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%d %d %d %d %d", pp->year, pp->day, pp->hour, + pp->minute, pp->second); pp->lencode = strlen(pp->a_lastcode); - /*get_systime(&pp->lastrec);*/ + /*get_systime(&pp->lastrec);*/ #ifdef DEBUG - if (debug) - printf ("fg: time is %04d/%03d %02d:%02d:%02d UTC\n", - pp->year, pp->day, pp->hour, pp->minute, pp->second); + if (debug) + printf("fg: time is %04d/%03d %02d:%02d:%02d UTC\n", + pp->year, pp->day, pp->hour, pp->minute, pp->second); #endif - pp->disp = (10e-6); + pp->disp = (10e-6); pp->lastrec = rbufp->recv_time; /* Is it better than get_systime()? */ /* pp->leap = LEAP_NOWARNING; */ - /* - * Process the new sample in the median filter and determine the - * timecode timestamp. - */ + /* + * Process the new sample in the median filter and determine the + * timecode timestamp. + */ - if (!refclock_process(pp)) - refclock_report(peer, CEVNT_BADTIME); - pp->lastref = pp->lastrec; + if (!refclock_process(pp)) + refclock_report(peer, CEVNT_BADTIME); + pp->lastref = pp->lastrec; refclock_receive(peer); return; } diff --git a/contrib/ntp/ntpd/refclock_gpsdjson.c b/contrib/ntp/ntpd/refclock_gpsdjson.c new file mode 100644 index 000000000..c2bf09a80 --- /dev/null +++ b/contrib/ntp/ntpd/refclock_gpsdjson.c @@ -0,0 +1,2210 @@ +/* + * refclock_gpsdjson.c - clock driver as GPSD JSON client + * Juergen Perlinger (perlinger@ntp.org) + * Feb 11, 2014 for the NTP project. + * The contents of 'html/copyright.html' apply. + * + * Heavily inspired by refclock_nmea.c + * + * Special thanks to Gary Miller and Hal Murray for their comments and + * ideas. + * + * Note: This will currently NOT work with Windows due to some + * limitations: + * + * - There is no GPSD for Windows. (There is an unofficial port to + * cygwin, but Windows is not officially supported.) + * + * - To work properly, this driver needs PPS and TPV/TOFF sentences + * from GPSD. I don't see how the cygwin port should deal with the + * PPS signal. + * + * - The device name matching must be done in a different way for + * Windows. (Can be done with COMxx matching, as done for NMEA.) + * + * Apart from those minor hickups, once GPSD has been fully ported to + * Windows, there's no reason why this should not work there ;-) If this + * is ever to happen at all is a different question. + * + * --------------------------------------------------------------------- + * + * This driver works slightly different from most others, as the PPS + * information (if available) is also coming from GPSD via the data + * connection. This makes using both the PPS data and the serial data + * easier, but OTOH it's not possible to use the ATOM driver to feed a + * raw PPS stream to the core of NTPD. + * + * To go around this, the driver can use a secondary clock unit + * (units>=128) that operate in tandem with the primary clock unit + * (unit%128). The primary clock unit does all the IO stuff and data + * decoding; if a a secondary unit is attached to a primary unit, this + * secondary unit is feed with the PPS samples only and can act as a PPS + * source to the clock selection. + * + * The drawback is that the primary unit must be present for the + * secondary unit to work. + * + * This design is a compromise to reduce the IO load for both NTPD and + * GPSD; it also ensures that data is transmitted and evaluated only + * once on the side of NTPD. + * + * --------------------------------------------------------------------- + * + * trouble shooting hints: + * + * Enable and check the clock stats. Check if there are bad replies; + * there should be none. If there are actually bad replies, then the + * driver cannot parse all JSON records from GPSD, and some record + * types are vital for the operation of the driver. This indicates a + * problem on the protocol level. + * + * When started on the command line with a debug level >= 2, the + * driver dumps the raw received data and the parser input to + * stdout. Since the debug level is global, NTPD starts to create a + * *lot* of output. It makes sense to pipe it through '(f)grep + * GPSD_JSON' before writing the result to disk. + * + * A bit less intrusive is using netcat or telnet to connect to GPSD + * and snoop what NTPD would get. If you try this, you have to send a + * WATCH command to GPSD: + * + * ?WATCH={"device":"/dev/gps0","enable":true,"json":true,"pps":true}; + * + * should show you what GPSD has to say to NTPD. Replace "/dev/gps0" + * with the device link used by GPSD, if necessary. + */ + + +#ifdef HAVE_CONFIG_H +#include +#endif + +#include "ntp_types.h" + +#if defined(REFCLOCK) && defined(CLOCK_GPSDJSON) && !defined(SYS_WINNT) + +/* ===================================================================== + * Get the little JSMN library directly into our guts. Use the 'parent + * link' feature for maximum speed. + */ +#define JSMN_PARENT_LINKS +#include "../libjsmn/jsmn.c" + +/* ===================================================================== + * JSON parsing stuff + */ + +#define JSMN_MAXTOK 350 +#define INVALID_TOKEN (-1) + +typedef struct json_ctx { + char * buf; + int ntok; + jsmntok_t tok[JSMN_MAXTOK]; +} json_ctx; + +typedef int tok_ref; + +/* Not all targets have 'long long', and not all of them have 'strtoll'. + * Sigh. We roll our own integer number parser. + */ +#ifdef HAVE_LONG_LONG +typedef signed long long int json_int; +typedef unsigned long long int json_uint; +#define JSON_INT_MAX LLONG_MAX +#define JSON_INT_MIN LLONG_MIN +#else +typedef signed long int json_int; +typedef unsigned long int json_uint; +#define JSON_INT_MAX LONG_MAX +#define JSON_INT_MIN LONG_MIN +#endif + +/* ===================================================================== + * header stuff we need + */ + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#if defined(HAVE_SYS_POLL_H) +# include +#elif defined(HAVE_SYS_SELECT_H) +# include +#else +# error need poll() or select() +#endif + +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_unixtime.h" +#include "ntp_refclock.h" +#include "ntp_stdlib.h" +#include "ntp_calendar.h" +#include "timespecops.h" + +/* get operation modes from mode word. + + * + SERIAL (default) evaluates only serial time information ('STI') as + * provided by TPV and TOFF records. TPV evaluation suffers from a + * bigger jitter than TOFF, sine it does not contain the receive time + * from GPSD and therefore the receive time of NTPD must be + * substituted for it. The network latency makes this a second rate + * guess. + * + * If TOFF records are detected in the data stream, the timing + * information is gleaned from this record -- it contains the local + * receive time stamp from GPSD and therefore eliminates the + * transmission latency between GPSD and NTPD. The timing information + * from TPV is ignored once a TOFF is detected or expected. + * + * TPV is still used to check the fix status, so the driver can stop + * feeding samples when GPSD says that the time information is + * effectively unreliable. + * + * + STRICT means only feed clock samples when a valid STI/PPS pair is + * available. Combines the reference time from STI with the pulse time + * from PPS. Masks the serial data jitter as long PPS is available, + * but can rapidly deteriorate once PPS drops out. + * + * + AUTO tries to use STI/PPS pairs if available for some time, and if + * this fails for too long switches back to STI only until the PPS + * signal becomes available again. See the HTML docs for this driver + * about the gotchas and why this is not the default. + */ +#define MODE_OP_MASK 0x03 +#define MODE_OP_STI 0 +#define MODE_OP_STRICT 1 +#define MODE_OP_AUTO 2 +#define MODE_OP_MAXVAL 2 +#define MODE_OP_MODE(x) ((x) & MODE_OP_MASK) + +#define PRECISION (-9) /* precision assumed (about 2 ms) */ +#define PPS_PRECISION (-20) /* precision assumed (about 1 us) */ +#define REFID "GPSD" /* reference id */ +#define DESCRIPTION "GPSD JSON client clock" /* who we are */ + +#define MAX_PDU_LEN 1600 +#define TICKOVER_LOW 10 +#define TICKOVER_HIGH 120 +#define LOGTHROTTLE 3600 + +/* Primary channel PPS avilability dance: + * Every good PPS sample gets us a credit of PPS_INCCOUNT points, every + * bad/missing PPS sample costs us a debit of PPS_DECCOUNT points. When + * the account reaches the upper limit we change to a mode where only + * PPS-augmented samples are fed to the core; when the account drops to + * zero we switch to a mode where TPV-only timestamps are fed to the + * core. + * This reduces the chance of rapid alternation between raw and + * PPS-augmented time stamps. + */ +#define PPS_MAXCOUNT 60 /* upper limit of account */ +#define PPS_INCCOUNT 3 /* credit for good samples */ +#define PPS_DECCOUNT 1 /* debit for bad samples */ + +/* The secondary (PPS) channel uses a different strategy to avoid old + * PPS samples in the median filter. + */ +#define PPS2_MAXCOUNT 10 + +#ifndef BOOL +# define BOOL int +#endif +#ifndef TRUE +# define TRUE 1 +#endif +#ifndef FALSE +# define FALSE 0 +#endif + +#define PROTO_VERSION(hi,lo) \ + ((((uint32_t)(hi) << 16) & 0xFFFF0000u) | \ + ((uint32_t)(lo) & 0x0FFFFu)) + +/* some local typedefs: The NTPD formatting style cries for short type + * names, and we provide them locally. Note:the suffix '_t' is reserved + * for the standard; I use a capital T instead. + */ +typedef struct peer peerT; +typedef struct refclockproc clockprocT; +typedef struct addrinfo addrinfoT; + +/* ===================================================================== + * We use the same device name scheme as does the NMEA driver; since + * GPSD supports the same links, we can select devices by a fixed name. + */ +static const char * s_dev_stem = "/dev/gps"; + +/* ===================================================================== + * forward declarations for transfer vector and the vector itself + */ + +static void gpsd_init (void); +static int gpsd_start (int, peerT *); +static void gpsd_shutdown (int, peerT *); +static void gpsd_receive (struct recvbuf *); +static void gpsd_poll (int, peerT *); +static void gpsd_control (int, const struct refclockstat *, + struct refclockstat *, peerT *); +static void gpsd_timer (int, peerT *); + +static int myasprintf(char**, char const*, ...) NTP_PRINTF(2, 3); + +static void enter_opmode(peerT *peer, int mode); +static void leave_opmode(peerT *peer, int mode); + +struct refclock refclock_gpsdjson = { + gpsd_start, /* start up driver */ + gpsd_shutdown, /* shut down driver */ + gpsd_poll, /* transmit poll message */ + gpsd_control, /* fudge control */ + gpsd_init, /* initialize driver */ + noentry, /* buginfo */ + gpsd_timer /* called once per second */ +}; + +/* ===================================================================== + * our local clock unit and data + */ +struct gpsd_unit; +typedef struct gpsd_unit gpsd_unitT; + +struct gpsd_unit { + /* links for sharing between master/slave units */ + gpsd_unitT *next_unit; + size_t refcount; + + /* data for the secondary PPS channel */ + peerT *pps_peer; + + /* unit and operation modes */ + int unit; + int mode; + char *logname; /* cached name for log/print */ + char * device; /* device name of unit */ + + /* current line protocol version */ + uint32_t proto_version; + + /* PPS time stamps primary + secondary channel */ + l_fp pps_local; /* when we received the PPS message */ + l_fp pps_stamp; /* related reference time */ + l_fp pps_recvt; /* when GPSD detected the pulse */ + l_fp pps_stamp2;/* related reference time (secondary) */ + l_fp pps_recvt2;/* when GPSD detected the pulse (secondary)*/ + int ppscount; /* PPS counter (primary unit) */ + int ppscount2; /* PPS counter (secondary unit) */ + + /* TPV or TOFF serial time information */ + l_fp sti_local; /* when we received the TPV/TOFF message */ + l_fp sti_stamp; /* effective GPS time stamp */ + l_fp sti_recvt; /* when GPSD got the fix */ + + /* precision estimates */ + int16_t sti_prec; /* serial precision based on EPT */ + int16_t pps_prec; /* PPS precision from GPSD or above */ + + /* fudge values for correction, mirrored as 'l_fp' */ + l_fp pps_fudge; /* PPS fudge primary channel */ + l_fp pps_fudge2; /* PPS fudge secondary channel */ + l_fp sti_fudge; /* TPV/TOFF serial data fudge */ + + /* Flags to indicate available data */ + int fl_nosync: 1; /* GPSD signals bad quality */ + int fl_sti : 1; /* valid TPV/TOFF seen (have time) */ + int fl_pps : 1; /* valid pulse seen */ + int fl_pps2 : 1; /* valid pulse seen for PPS channel */ + int fl_rawsti: 1; /* permit raw TPV/TOFF time stamps */ + int fl_vers : 1; /* have protocol version */ + int fl_watch : 1; /* watch reply seen */ + /* protocol flags */ + int pf_nsec : 1; /* have nanosec PPS info */ + int pf_toff : 1; /* have TOFF record for timing */ + + /* admin stuff for sockets and device selection */ + int fdt; /* current connecting socket */ + addrinfoT * addr; /* next address to try */ + u_int tickover; /* timeout countdown */ + u_int tickpres; /* timeout preset */ + + /* tallies for the various events */ + u_int tc_recv; /* received known records */ + u_int tc_breply; /* bad replies / parsing errors */ + u_int tc_nosync; /* TPV / sample cycles w/o fix */ + u_int tc_sti_recv;/* received serial time info records */ + u_int tc_sti_used;/* used --^-- */ + u_int tc_pps_recv;/* received PPS timing info records */ + u_int tc_pps_used;/* used --^-- */ + + /* log bloat throttle */ + u_int logthrottle;/* seconds to next log slot */ + + /* The parse context for the current record */ + json_ctx json_parse; + + /* record assemby buffer and saved length */ + int buflen; + char buffer[MAX_PDU_LEN]; +}; + +/* ===================================================================== + * static local helpers forward decls + */ +static void gpsd_init_socket(peerT * const peer); +static void gpsd_test_socket(peerT * const peer); +static void gpsd_stop_socket(peerT * const peer); + +static void gpsd_parse(peerT * const peer, + const l_fp * const rtime); +static BOOL convert_ascii_time(l_fp * fp, const char * gps_time); +static void save_ltc(clockprocT * const pp, const char * const tc); +static int syslogok(clockprocT * const pp, gpsd_unitT * const up); +static void log_data(peerT *peer, const char *what, + const char *buf, size_t len); +static int16_t clamped_precision(int rawprec); + +/* ===================================================================== + * local / static stuff + */ + +/* The logon string is actually the ?WATCH command of GPSD, using JSON + * data and selecting the GPS device name we created from our unit + * number. We have an old a newer version that request PPS (and TOFF) + * transmission. + * Note: These are actually format strings! + */ +static const char * const s_req_watch[2] = { + "?WATCH={\"device\":\"%s\",\"enable\":true,\"json\":true};\r\n", + "?WATCH={\"device\":\"%s\",\"enable\":true,\"json\":true,\"pps\":true};\r\n" +}; + +static const char * const s_req_version = + "?VERSION;\r\n"; + +/* We keep a static list of network addresses for 'localhost:gpsd' or a + * fallback alias of it, and we try to connect to them in round-robin + * fashion. The service lookup is done during the driver init + * function to minmise the impact of 'getaddrinfo()'. + * + * Alas, the init function is called even if there are no clocks + * configured for this driver. So it makes sense to defer the logging of + * any errors or other notifications until the first clock unit is + * started -- otherwise there might be syslog entries from a driver that + * is not used at all. + */ +static addrinfoT *s_gpsd_addr; +static gpsd_unitT *s_clock_units; + +/* list of service/socket names we want to resolve against */ +static const char * const s_svctab[][2] = { + { "localhost", "gpsd" }, + { "localhost", "2947" }, + { "127.0.0.1", "2947" }, + { NULL, NULL } +}; + +/* list of address resolution errors and index of service entry that + * finally worked. + */ +static int s_svcerr[sizeof(s_svctab)/sizeof(s_svctab[0])]; +static int s_svcidx; + +/* ===================================================================== + * log throttling + */ +static int/*BOOL*/ +syslogok( + clockprocT * const pp, + gpsd_unitT * const up) +{ + int res = (0 != (pp->sloppyclockflag & CLK_FLAG3)) + || (0 == up->logthrottle ) + || (LOGTHROTTLE == up->logthrottle ); + if (res) + up->logthrottle = LOGTHROTTLE; + return res; +} + +/* ===================================================================== + * the clock functions + */ + +/* --------------------------------------------------------------------- + * Init: This currently just gets the socket address for the GPS daemon + */ +static void +gpsd_init(void) +{ + addrinfoT hints; + int rc, idx; + + memset(s_svcerr, 0, sizeof(s_svcerr)); + memset(&hints, 0, sizeof(hints)); + hints.ai_family = AF_UNSPEC; + hints.ai_protocol = IPPROTO_TCP; + hints.ai_socktype = SOCK_STREAM; + + for (idx = 0; s_svctab[idx][0] && !s_gpsd_addr; idx++) { + rc = getaddrinfo(s_svctab[idx][0], s_svctab[idx][1], + &hints, &s_gpsd_addr); + s_svcerr[idx] = rc; + if (0 == rc) + break; + s_gpsd_addr = NULL; + } + s_svcidx = idx; +} + +/* --------------------------------------------------------------------- + * Init Check: flush pending log messages and check if we can proceed + */ +static int/*BOOL*/ +gpsd_init_check(void) +{ + int idx; + + /* Check if there is something to log */ + if (s_svcidx == 0) + return (s_gpsd_addr != NULL); + + /* spool out the resolver errors */ + for (idx = 0; idx < s_svcidx; ++idx) { + msyslog(LOG_WARNING, + "GPSD_JSON: failed to resolve '%s:%s', rc=%d (%s)", + s_svctab[idx][0], s_svctab[idx][1], + s_svcerr[idx], gai_strerror(s_svcerr[idx])); + } + + /* check if it was fatal, or if we can proceed */ + if (s_gpsd_addr == NULL) + msyslog(LOG_ERR, "%s", + "GPSD_JSON: failed to get socket address, giving up."); + else if (idx != 0) + msyslog(LOG_WARNING, + "GPSD_JSON: using '%s:%s' instead of '%s:%s'", + s_svctab[idx][0], s_svctab[idx][1], + s_svctab[0][0], s_svctab[0][1]); + + /* make sure this gets logged only once and tell if we can + * proceed or not + */ + s_svcidx = 0; + return (s_gpsd_addr != NULL); +} + +/* --------------------------------------------------------------------- + * Start: allocate a unit pointer and set up the runtime data + */ +static int +gpsd_start( + int unit, + peerT * peer) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * up; + gpsd_unitT ** uscan = &s_clock_units; + + struct stat sb; + + /* check if we can proceed at all or if init failed */ + if ( ! gpsd_init_check()) + return FALSE; + + /* search for matching unit */ + while ((up = *uscan) != NULL && up->unit != (unit & 0x7F)) + uscan = &up->next_unit; + if (up == NULL) { + /* alloc unit, add to list and increment use count ASAP. */ + up = emalloc_zero(sizeof(*up)); + *uscan = up; + ++up->refcount; + + /* initialize the unit structure */ + up->logname = estrdup(refnumtoa(&peer->srcadr)); + up->unit = unit & 0x7F; + up->fdt = -1; + up->addr = s_gpsd_addr; + up->tickpres = TICKOVER_LOW; + + /* Create the device name and check for a Character + * Device. It's assumed that GPSD was started with the + * same link, so the names match. (If this is not + * practicable, we will have to read the symlink, if + * any, so we can get the true device file.) + */ + if (-1 == myasprintf(&up->device, "%s%u", + s_dev_stem, up->unit)) { + msyslog(LOG_ERR, "%s: clock device name too long", + up->logname); + goto dev_fail; + } + if (-1 == stat(up->device, &sb) || !S_ISCHR(sb.st_mode)) { + msyslog(LOG_ERR, "%s: '%s' is not a character device", + up->logname, up->device); + goto dev_fail; + } + } else { + /* All set up, just increment use count. */ + ++up->refcount; + } + + /* setup refclock processing */ + pp->unitptr = (caddr_t)up; + pp->io.fd = -1; + pp->io.clock_recv = gpsd_receive; + pp->io.srcclock = peer; + pp->io.datalen = 0; + pp->a_lastcode[0] = '\0'; + pp->lencode = 0; + pp->clockdesc = DESCRIPTION; + memcpy(&pp->refid, REFID, 4); + + /* Initialize miscellaneous variables */ + if (unit >= 128) + peer->precision = PPS_PRECISION; + else + peer->precision = PRECISION; + + /* If the daemon name lookup failed, just give up now. */ + if (NULL == up->addr) { + msyslog(LOG_ERR, "%s: no GPSD socket address, giving up", + up->logname); + goto dev_fail; + } + + LOGIF(CLOCKINFO, + (LOG_NOTICE, "%s: startup, device is '%s'", + refnumtoa(&peer->srcadr), up->device)); + up->mode = MODE_OP_MODE(peer->ttl); + if (up->mode > MODE_OP_MAXVAL) + up->mode = 0; + if (unit >= 128) + up->pps_peer = peer; + else + enter_opmode(peer, up->mode); + return TRUE; + +dev_fail: + /* On failure, remove all UNIT ressources and declare defeat. */ + + INSIST (up); + if (!--up->refcount) { + *uscan = up->next_unit; + free(up->device); + free(up); + } + + pp->unitptr = (caddr_t)NULL; + return FALSE; +} + +/* ------------------------------------------------------------------ */ + +static void +gpsd_shutdown( + int unit, + peerT * peer) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + gpsd_unitT ** uscan = &s_clock_units; + + UNUSED_ARG(unit); + + /* The unit pointer might have been removed already. */ + if (up == NULL) + return; + + /* now check if we must close IO resources */ + if (peer != up->pps_peer) { + if (-1 != pp->io.fd) { + DPRINTF(1, ("%s: closing clock, fd=%d\n", + up->logname, pp->io.fd)); + io_closeclock(&pp->io); + pp->io.fd = -1; + } + if (up->fdt != -1) + close(up->fdt); + } + /* decrement use count and eventually remove this unit. */ + if (!--up->refcount) { + /* unlink this unit */ + while (*uscan != NULL) + if (*uscan == up) + *uscan = up->next_unit; + else + uscan = &(*uscan)->next_unit; + free(up->logname); + free(up->device); + free(up); + } + pp->unitptr = (caddr_t)NULL; + LOGIF(CLOCKINFO, + (LOG_NOTICE, "%s: shutdown", refnumtoa(&peer->srcadr))); +} + +/* ------------------------------------------------------------------ */ + +static void +gpsd_receive( + struct recvbuf * rbufp) +{ + /* declare & init control structure ptrs */ + peerT * const peer = rbufp->recv_peer; + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + const char *psrc, *esrc; + char *pdst, *edst, ch; + + /* log the data stream, if this is enabled */ + log_data(peer, "recv", (const char*)rbufp->recv_buffer, + (size_t)rbufp->recv_length); + + + /* Since we're getting a raw stream data, we must assemble lines + * in our receive buffer. We can't use neither 'refclock_gtraw' + * not 'refclock_gtlin' here... We process chars until we reach + * an EoL (that is, line feed) but we truncate the message if it + * does not fit the buffer. GPSD might truncate messages, too, + * so dealing with truncated buffers is necessary anyway. + */ + psrc = (const char*)rbufp->recv_buffer; + esrc = psrc + rbufp->recv_length; + + pdst = up->buffer + up->buflen; + edst = pdst + sizeof(up->buffer) - 1; /* for trailing NUL */ + + while (psrc != esrc) { + ch = *psrc++; + if (ch == '\n') { + /* trim trailing whitespace & terminate buffer */ + while (pdst != up->buffer && pdst[-1] <= ' ') + --pdst; + *pdst = '\0'; + /* process data and reset buffer */ + up->buflen = pdst - up->buffer; + gpsd_parse(peer, &rbufp->recv_time); + pdst = up->buffer; + } else if (pdst != edst) { + /* add next char, ignoring leading whitespace */ + if (ch > ' ' || pdst != up->buffer) + *pdst++ = ch; + } + } + up->buflen = pdst - up->buffer; + up->tickover = TICKOVER_LOW; +} + +/* ------------------------------------------------------------------ */ + +static void +poll_primary( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + if (pp->coderecv != pp->codeproc) { + /* all is well */ + pp->lastref = pp->lastrec; + refclock_report(peer, CEVNT_NOMINAL); + refclock_receive(peer); + } else { + /* Not working properly, admit to it. If we have no + * connection to GPSD, declare the clock as faulty. If + * there were bad replies, this is handled as the major + * cause, and everything else is just a timeout. + */ + peer->precision = PRECISION; + if (-1 == pp->io.fd) + refclock_report(peer, CEVNT_FAULT); + else if (0 != up->tc_breply) + refclock_report(peer, CEVNT_BADREPLY); + else + refclock_report(peer, CEVNT_TIMEOUT); + } + + if (pp->sloppyclockflag & CLK_FLAG4) + mprintf_clock_stats( + &peer->srcadr,"%u %u %u %u %u %u %u", + up->tc_recv, + up->tc_breply, up->tc_nosync, + up->tc_sti_recv, up->tc_sti_used, + up->tc_pps_recv, up->tc_pps_used); + + /* clear tallies for next round */ + up->tc_breply = 0; + up->tc_recv = 0; + up->tc_nosync = 0; + up->tc_sti_recv = 0; + up->tc_sti_used = 0; + up->tc_pps_recv = 0; + up->tc_pps_used = 0; +} + +static void +poll_secondary( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + if (pp->coderecv != pp->codeproc) { + /* all is well */ + pp->lastref = pp->lastrec; + refclock_report(peer, CEVNT_NOMINAL); + refclock_receive(peer); + } else { + peer->precision = PPS_PRECISION; + peer->flags &= ~FLAG_PPS; + refclock_report(peer, CEVNT_TIMEOUT); + } +} + +static void +gpsd_poll( + int unit, + peerT * peer) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + ++pp->polls; + if (peer == up->pps_peer) + poll_secondary(peer, pp, up); + else + poll_primary(peer, pp, up); +} + +/* ------------------------------------------------------------------ */ + +static void +gpsd_control( + int unit, + const struct refclockstat * in_st, + struct refclockstat * out_st, + peerT * peer ) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + if (peer == up->pps_peer) { + DTOLFP(pp->fudgetime1, &up->pps_fudge2); + if ( ! (pp->sloppyclockflag & CLK_FLAG1)) + peer->flags &= ~FLAG_PPS; + } else { + /* save preprocessed fudge times */ + DTOLFP(pp->fudgetime1, &up->pps_fudge); + DTOLFP(pp->fudgetime2, &up->sti_fudge); + + if (MODE_OP_MODE(up->mode ^ peer->ttl)) { + leave_opmode(peer, up->mode); + up->mode = MODE_OP_MODE(peer->ttl); + enter_opmode(peer, up->mode); + } + } + } + +/* ------------------------------------------------------------------ */ + +static void +timer_primary( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + int rc; + + /* This is used for timeout handling. Nothing that needs + * sub-second precison happens here, so receive/connect/retry + * timeouts are simply handled by a count down, and then we + * decide what to do by the socket values. + * + * Note that the timer stays at zero here, unless some of the + * functions set it to another value. + */ + if (up->logthrottle) + --up->logthrottle; + if (up->tickover) + --up->tickover; + switch (up->tickover) { + case 4: + /* If we are connected to GPSD, try to get a live signal + * by querying the version. Otherwise just check the + * socket to become ready. + */ + if (-1 != pp->io.fd) { + size_t rlen = strlen(s_req_version); + DPRINTF(2, ("%s: timer livecheck: '%s'\n", + up->logname, s_req_version)); + log_data(peer, "send", s_req_version, rlen); + rc = write(pp->io.fd, s_req_version, rlen); + (void)rc; + } else if (-1 != up->fdt) { + gpsd_test_socket(peer); + } + break; + + case 0: + if (-1 != pp->io.fd) + gpsd_stop_socket(peer); + else if (-1 != up->fdt) + gpsd_test_socket(peer); + else if (NULL != s_gpsd_addr) + gpsd_init_socket(peer); + break; + + default: + if (-1 == pp->io.fd && -1 != up->fdt) + gpsd_test_socket(peer); + } +} + +static void +timer_secondary( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + /* Reduce the count by one. Flush sample buffer and clear PPS + * flag when this happens. + */ + up->ppscount2 = max(0, (up->ppscount2 - 1)); + if (0 == up->ppscount2) { + if (pp->coderecv != pp->codeproc) { + refclock_report(peer, CEVNT_TIMEOUT); + pp->coderecv = pp->codeproc; + } + peer->flags &= ~FLAG_PPS; + } +} + +static void +gpsd_timer( + int unit, + peerT * peer) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + if (peer == up->pps_peer) + timer_secondary(peer, pp, up); + else + timer_primary(peer, pp, up); +} + +/* ===================================================================== + * handle opmode switches + */ + +static void +enter_opmode( + peerT *peer, + int mode) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + DPRINTF(1, ("%s: enter operation mode %d\n", + up->logname, MODE_OP_MODE(mode))); + + if (MODE_OP_MODE(mode) == MODE_OP_AUTO) { + up->fl_rawsti = 0; + up->ppscount = PPS_MAXCOUNT / 2; + } + up->fl_pps = 0; + up->fl_sti = 0; +} + +/* ------------------------------------------------------------------ */ + +static void +leave_opmode( + peerT *peer, + int mode) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + DPRINTF(1, ("%s: leaving operation mode %d\n", + up->logname, MODE_OP_MODE(mode))); + + if (MODE_OP_MODE(mode) == MODE_OP_AUTO) { + up->fl_rawsti = 0; + up->ppscount = 0; + } + up->fl_pps = 0; + up->fl_sti = 0; +} + +/* ===================================================================== + * operation mode specific evaluation + */ + +static void +add_clock_sample( + peerT * const peer , + clockprocT * const pp , + l_fp stamp, + l_fp recvt) +{ + pp->lastref = stamp; + if (pp->coderecv == pp->codeproc) + refclock_report(peer, CEVNT_NOMINAL); + refclock_process_offset(pp, stamp, recvt, 0.0); +} + +/* ------------------------------------------------------------------ */ + +static void +eval_strict( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + if (up->fl_sti && up->fl_pps) { + /* use TPV reference time + PPS receive time */ + add_clock_sample(peer, pp, up->sti_stamp, up->pps_recvt); + peer->precision = up->pps_prec; + /* both packets consumed now... */ + up->fl_pps = 0; + up->fl_sti = 0; + ++up->tc_sti_used; + } +} + +/* ------------------------------------------------------------------ */ +/* PPS processing for the secondary channel. GPSD provides us with full + * timing information, so there's no danger of PLL-locking to the wrong + * second. The belts and suspenders needed for the raw ATOM clock are + * unnecessary here. + */ +static void +eval_pps_secondary( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + if (up->fl_pps2) { + /* feed data */ + add_clock_sample(peer, pp, up->pps_stamp2, up->pps_recvt2); + peer->precision = up->pps_prec; + /* PPS peer flag logic */ + up->ppscount2 = min(PPS2_MAXCOUNT, (up->ppscount2 + 2)); + if ((PPS2_MAXCOUNT == up->ppscount2) && + (pp->sloppyclockflag & CLK_FLAG1) ) + peer->flags |= FLAG_PPS; + /* mark time stamp as burned... */ + up->fl_pps2 = 0; + ++up->tc_pps_used; + } +} + +/* ------------------------------------------------------------------ */ + +static void +eval_serial( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + if (up->fl_sti) { + add_clock_sample(peer, pp, up->sti_stamp, up->sti_recvt); + peer->precision = up->sti_prec; + /* mark time stamp as burned... */ + up->fl_sti = 0; + ++up->tc_sti_used; + } +} + +/* ------------------------------------------------------------------ */ +static void +eval_auto( + peerT * const peer , + clockprocT * const pp , + gpsd_unitT * const up ) +{ + /* If there's no TPV available, stop working here... */ + if (!up->fl_sti) + return; + + /* check how to handle STI+PPS: Can PPS be used to augment STI + * (or vice versae), do we drop the sample because there is a + * temporary missing PPS signal, or do we feed on STI time + * stamps alone? + * + * Do a counter/threshold dance to decide how to proceed. + */ + if (up->fl_pps) { + up->ppscount = min(PPS_MAXCOUNT, + (up->ppscount + PPS_INCCOUNT)); + if ((PPS_MAXCOUNT == up->ppscount) && up->fl_rawsti) { + up->fl_rawsti = 0; + msyslog(LOG_INFO, + "%s: expect valid PPS from now", + up->logname); + } + } else { + up->ppscount = max(0, (up->ppscount - PPS_DECCOUNT)); + if ((0 == up->ppscount) && !up->fl_rawsti) { + up->fl_rawsti = -1; + msyslog(LOG_WARNING, + "%s: use TPV alone from now", + up->logname); + } + } + + /* now eventually feed the sample */ + if (up->fl_rawsti) + eval_serial(peer, pp, up); + else + eval_strict(peer, pp, up); +} + +/* ===================================================================== + * JSON parsing stuff + */ + +/* ------------------------------------------------------------------ */ +/* Parse a decimal integer with a possible sign. Works like 'strtoll()' + * or 'strtol()', but with a fixed base of 10 and without eating away + * leading whitespace. For the error codes, the handling of the end + * pointer and the return values see 'strtol()'. + */ +static json_int +strtojint( + const char *cp, char **ep) +{ + json_uint accu, limit_lo, limit_hi; + int flags; /* bit 0: overflow; bit 1: sign */ + const char * hold; + + /* pointer union to circumvent a tricky/sticky const issue */ + union { const char * c; char * v; } vep; + + /* store initial value of 'cp' -- see 'strtol()' */ + vep.c = cp; + + /* Eat away an optional sign and set the limits accordingly: The + * high limit is the maximum absolute value that can be returned, + * and the low limit is the biggest value that does not cause an + * overflow when multiplied with 10. Avoid negation overflows. + */ + if (*cp == '-') { + cp += 1; + flags = 2; + limit_hi = (json_uint)-(JSON_INT_MIN + 1) + 1; + } else { + cp += (*cp == '+'); + flags = 0; + limit_hi = (json_uint)JSON_INT_MAX; + } + limit_lo = limit_hi / 10; + + /* Now try to convert a sequence of digits. */ + hold = cp; + accu = 0; + while (isdigit(*(const u_char*)cp)) { + flags |= (accu > limit_lo); + accu = accu * 10 + (*(const u_char*)cp++ - '0'); + flags |= (accu > limit_hi); + } + /* Check for empty conversion (no digits seen). */ + if (hold != cp) + vep.c = cp; + else + errno = EINVAL; /* accu is still zero */ + /* Check for range overflow */ + if (flags & 1) { + errno = ERANGE; + accu = limit_hi; + } + /* If possible, store back the end-of-conversion pointer */ + if (ep) + *ep = vep.v; + /* If negative, return the negated result if the accu is not + * zero. Avoid negation overflows. + */ + if ((flags & 2) && accu) + return -(json_int)(accu - 1) - 1; + else + return (json_int)accu; +} + +/* ------------------------------------------------------------------ */ + +static tok_ref +json_token_skip( + const json_ctx * ctx, + tok_ref tid) +{ + if (tid >= 0 && tid < ctx->ntok) { + int len = ctx->tok[tid].size; + /* For arrays and objects, the size is the number of + * ITEMS in the compound. Thats the number of objects in + * the array, and the number of key/value pairs for + * objects. In theory, the key must be a string, and we + * could simply skip one token before skipping the + * value, which can be anything. We're a bit paranoid + * and lazy at the same time: We simply double the + * number of tokens to skip and fall through into the + * array processing when encountering an object. + */ + switch (ctx->tok[tid].type) { + case JSMN_OBJECT: + len *= 2; + /* FALLTHROUGH */ + case JSMN_ARRAY: + for (++tid; len; --len) + tid = json_token_skip(ctx, tid); + break; + + default: + ++tid; + break; + } + if (tid > ctx->ntok) /* Impossible? Paranoia rulez. */ + tid = ctx->ntok; + } + return tid; +} + +/* ------------------------------------------------------------------ */ + +static int +json_object_lookup( + const json_ctx * ctx , + tok_ref tid , + const char * key , + int what) +{ + int len; + + if (tid < 0 || tid >= ctx->ntok || + ctx->tok[tid].type != JSMN_OBJECT) + return INVALID_TOKEN; + + len = ctx->tok[tid].size; + for (++tid; len && tid+1 < ctx->ntok; --len) { + if (ctx->tok[tid].type != JSMN_STRING) { /* Blooper! */ + tid = json_token_skip(ctx, tid); /* skip key */ + tid = json_token_skip(ctx, tid); /* skip val */ + } else if (strcmp(key, ctx->buf + ctx->tok[tid].start)) { + tid = json_token_skip(ctx, tid+1); /* skip key+val */ + } else if (what < 0 || what == ctx->tok[tid+1].type) { + return tid + 1; + } else { + break; + } + /* if skipping ahead returned an error, bail out here. */ + if (tid < 0) + break; + } + return INVALID_TOKEN; +} + +/* ------------------------------------------------------------------ */ + +static const char* +json_object_lookup_primitive( + const json_ctx * ctx, + tok_ref tid, + const char * key) +{ + tid = json_object_lookup(ctx, tid, key, JSMN_PRIMITIVE); + if (INVALID_TOKEN != tid) + return ctx->buf + ctx->tok[tid].start; + else + return NULL; +} +/* ------------------------------------------------------------------ */ +/* look up a boolean value. This essentially returns a tribool: + * 0->false, 1->true, (-1)->error/undefined + */ +static int +json_object_lookup_bool( + const json_ctx * ctx, + tok_ref tid, + const char * key) +{ + const char *cp; + cp = json_object_lookup_primitive(ctx, tid, key); + switch ( cp ? *cp : '\0') { + case 't': return 1; + case 'f': return 0; + default : return -1; + } +} + +/* ------------------------------------------------------------------ */ + +static const char* +json_object_lookup_string( + const json_ctx * ctx, + tok_ref tid, + const char * key) +{ + tid = json_object_lookup(ctx, tid, key, JSMN_STRING); + if (INVALID_TOKEN != tid) + return ctx->buf + ctx->tok[tid].start; + return NULL; +} + +static const char* +json_object_lookup_string_default( + const json_ctx * ctx, + tok_ref tid, + const char * key, + const char * def) +{ + tid = json_object_lookup(ctx, tid, key, JSMN_STRING); + if (INVALID_TOKEN != tid) + return ctx->buf + ctx->tok[tid].start; + return def; +} + +/* ------------------------------------------------------------------ */ + +static json_int +json_object_lookup_int( + const json_ctx * ctx, + tok_ref tid, + const char * key) +{ + json_int ret; + const char * cp; + char * ep; + + cp = json_object_lookup_primitive(ctx, tid, key); + if (NULL != cp) { + ret = strtojint(cp, &ep); + if (cp != ep && '\0' == *ep) + return ret; + } else { + errno = EINVAL; + } + return 0; +} + +static json_int +json_object_lookup_int_default( + const json_ctx * ctx, + tok_ref tid, + const char * key, + json_int def) +{ + json_int ret; + const char * cp; + char * ep; + + cp = json_object_lookup_primitive(ctx, tid, key); + if (NULL != cp) { + ret = strtojint(cp, &ep); + if (cp != ep && '\0' == *ep) + return ret; + } + return def; +} + +/* ------------------------------------------------------------------ */ +#if 0 /* currently unused */ +static double +json_object_lookup_float( + const json_ctx * ctx, + tok_ref tid, + const char * key) +{ + double ret; + const char * cp; + char * ep; + + cp = json_object_lookup_primitive(ctx, tid, key); + if (NULL != cp) { + ret = strtod(cp, &ep); + if (cp != ep && '\0' == *ep) + return ret; + } else { + errno = EINVAL; + } + return 0.0; +} +#endif + +static double +json_object_lookup_float_default( + const json_ctx * ctx, + tok_ref tid, + const char * key, + double def) +{ + double ret; + const char * cp; + char * ep; + + cp = json_object_lookup_primitive(ctx, tid, key); + if (NULL != cp) { + ret = strtod(cp, &ep); + if (cp != ep && '\0' == *ep) + return ret; + } + return def; +} + +/* ------------------------------------------------------------------ */ + +static BOOL +json_parse_record( + json_ctx * ctx, + char * buf, + size_t len) +{ + jsmn_parser jsm; + int idx, rc; + + jsmn_init(&jsm); + rc = jsmn_parse(&jsm, buf, len, ctx->tok, JSMN_MAXTOK); + if (rc <= 0) + return FALSE; + ctx->buf = buf; + ctx->ntok = rc; + + if (JSMN_OBJECT != ctx->tok[0].type) + return FALSE; /* not object!?! */ + + /* Make all tokens NUL terminated by overwriting the + * terminator symbol. Makes string compares and number parsing a + * lot easier! + */ + for (idx = 0; idx < ctx->ntok; ++idx) + if (ctx->tok[idx].end > ctx->tok[idx].start) + ctx->buf[ctx->tok[idx].end] = '\0'; + return TRUE; +} + + +/* ===================================================================== + * static local helpers + */ +static BOOL +get_binary_time( + l_fp * const dest , + json_ctx * const jctx , + const char * const time_name, + const char * const frac_name, + long fscale ) +{ + BOOL retv = FALSE; + struct timespec ts; + + errno = 0; + ts.tv_sec = (time_t)json_object_lookup_int(jctx, 0, time_name); + ts.tv_nsec = (long )json_object_lookup_int(jctx, 0, frac_name); + if (0 == errno) { + ts.tv_nsec *= fscale; + *dest = tspec_stamp_to_lfp(ts); + retv = TRUE; + } + return retv; +} + +/* ------------------------------------------------------------------ */ +/* Process a WATCH record + * + * Currently this is only used to recognise that the device is present + * and that we're listed subscribers. + */ +static void +process_watch( + peerT * const peer , + json_ctx * const jctx , + const l_fp * const rtime) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + const char * path; + + path = json_object_lookup_string(jctx, 0, "device"); + if (NULL == path || strcmp(path, up->device)) + return; + + if (json_object_lookup_bool(jctx, 0, "enable") > 0 && + json_object_lookup_bool(jctx, 0, "json" ) > 0 ) + up->fl_watch = -1; + else + up->fl_watch = 0; + DPRINTF(2, ("%s: process_watch, enabled=%d\n", + up->logname, (up->fl_watch & 1))); +} + +/* ------------------------------------------------------------------ */ + +static void +process_version( + peerT * const peer , + json_ctx * const jctx , + const l_fp * const rtime) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + int len; + char * buf; + const char *revision; + const char *release; + uint16_t pvhi, pvlo; + + /* get protocol version number */ + revision = json_object_lookup_string_default( + jctx, 0, "rev", "(unknown)"); + release = json_object_lookup_string_default( + jctx, 0, "release", "(unknown)"); + errno = 0; + pvhi = (uint16_t)json_object_lookup_int(jctx, 0, "proto_major"); + pvlo = (uint16_t)json_object_lookup_int(jctx, 0, "proto_minor"); + + if (0 == errno) { + if ( ! up->fl_vers) + msyslog(LOG_INFO, + "%s: GPSD revision=%s release=%s protocol=%u.%u", + up->logname, revision, release, + pvhi, pvlo); + up->proto_version = PROTO_VERSION(pvhi, pvlo); + up->fl_vers = -1; + } else { + if (syslogok(pp, up)) + msyslog(LOG_INFO, + "%s: could not evaluate version data", + up->logname); + return; + } + /* With the 3.9 GPSD protocol, '*_musec' vanished from the PPS + * record and was replace by '*_nsec'. + */ + up->pf_nsec = -(up->proto_version >= PROTO_VERSION(3,9)); + + /* With the 3.10 protocol we can get TOFF records for better + * timing information. + */ + up->pf_toff = -(up->proto_version >= PROTO_VERSION(3,10)); + + /* request watch for our GPS device if not yet watched. + * + * The version string is also sent as a life signal, if we have + * seen useable data. So if we're already watching the device, + * skip the request. + * + * Reuse the input buffer, which is no longer needed in the + * current cycle. Also assume that we can write the watch + * request in one sweep into the socket; since we do not do + * output otherwise, this should always work. (Unless the + * TCP/IP window size gets lower than the length of the + * request. We handle that when it happens.) + */ + if (up->fl_watch) + return; + + snprintf(up->buffer, sizeof(up->buffer), + s_req_watch[up->pf_toff != 0], up->device); + buf = up->buffer; + len = strlen(buf); + log_data(peer, "send", buf, len); + if (len != write(pp->io.fd, buf, len) && (syslogok(pp, up))) { + /* Note: if the server fails to read our request, the + * resulting data timeout will take care of the + * connection! + */ + msyslog(LOG_ERR, "%s: failed to write watch request (%m)", + up->logname); + } +} + +/* ------------------------------------------------------------------ */ + +static void +process_tpv( + peerT * const peer , + json_ctx * const jctx , + const l_fp * const rtime) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + const char * gps_time; + int gps_mode; + double ept; + int xlog2; + + gps_mode = (int)json_object_lookup_int_default( + jctx, 0, "mode", 0); + + gps_time = json_object_lookup_string( + jctx, 0, "time"); + + /* accept time stamps only in 2d or 3d fix */ + if (gps_mode < 2 || NULL == gps_time) { + /* receiver has no fix; tell about and avoid stale data */ + if ( ! up->pf_toff) + ++up->tc_sti_recv; + ++up->tc_nosync; + up->fl_sti = 0; + up->fl_pps = 0; + up->fl_nosync = -1; + return; + } + up->fl_nosync = 0; + + /* convert clock and set resulting ref time, but only if the + * TOFF sentence is *not* available + */ + if ( ! up->pf_toff) { + ++up->tc_sti_recv; + /* save last time code to clock data */ + save_ltc(pp, gps_time); + /* now parse the time string */ + if (convert_ascii_time(&up->sti_stamp, gps_time)) { + DPRINTF(2, ("%s: process_tpv, stamp='%s'," + " recvt='%s' mode=%u\n", + up->logname, + gmprettydate(&up->sti_stamp), + gmprettydate(&up->sti_recvt), + gps_mode)); + + /* have to use local receive time as substitute + * for the real receive time: TPV does not tell + * us. + */ + up->sti_local = *rtime; + up->sti_recvt = *rtime; + L_SUB(&up->sti_recvt, &up->sti_fudge); + up->fl_sti = -1; + } else { + ++up->tc_breply; + up->fl_sti = 0; + } + } + + /* Set the precision from the GPSD data + * Use the ETP field for an estimation of the precision of the + * serial data. If ETP is not available, use the default serial + * data presion instead. (Note: The PPS branch has a different + * precision estimation, since it gets the proper value directly + * from GPSD!) + */ + ept = json_object_lookup_float_default(jctx, 0, "ept", 2.0e-3); + ept = frexp(fabs(ept)*0.70710678, &xlog2); /* ~ sqrt(0.5) */ + if (ept < 0.25) + xlog2 = INT_MIN; + if (ept > 2.0) + xlog2 = INT_MAX; + up->sti_prec = clamped_precision(xlog2); +} + +/* ------------------------------------------------------------------ */ + +static void +process_pps( + peerT * const peer , + json_ctx * const jctx , + const l_fp * const rtime) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + int xlog2; + + ++up->tc_pps_recv; + + /* Bail out if there's indication that time sync is bad or + * if we're explicitely requested to ignore PPS data. + */ + if (up->fl_nosync) + return; + + up->pps_local = *rtime; + /* Now grab the time values. 'clock_*' is the event time of the + * pulse measured on the local system clock; 'real_*' is the GPS + * reference time GPSD associated with the pulse. + */ + if (up->pf_nsec) { + if ( ! get_binary_time(&up->pps_recvt2, jctx, + "clock_sec", "clock_nsec", 1)) + goto fail; + if ( ! get_binary_time(&up->pps_stamp2, jctx, + "real_sec", "real_nsec", 1)) + goto fail; + } else { + if ( ! get_binary_time(&up->pps_recvt2, jctx, + "clock_sec", "clock_musec", 1000)) + goto fail; + if ( ! get_binary_time(&up->pps_stamp2, jctx, + "real_sec", "real_musec", 1000)) + goto fail; + } + + /* Try to read the precision field from the PPS record. If it's + * not there, take the precision from the serial data. + */ + xlog2 = json_object_lookup_int_default( + jctx, 0, "precision", up->sti_prec); + up->pps_prec = clamped_precision(xlog2); + + /* Get fudged receive times for primary & secondary unit */ + up->pps_recvt = up->pps_recvt2; + L_SUB(&up->pps_recvt , &up->pps_fudge ); + L_SUB(&up->pps_recvt2, &up->pps_fudge2); + pp->lastrec = up->pps_recvt; + + /* Map to nearest full second as reference time stamp for the + * primary channel. Sanity checks are done in evaluation step. + */ + up->pps_stamp = up->pps_recvt; + L_ADDUF(&up->pps_stamp, 0x80000000u); + up->pps_stamp.l_uf = 0; + + if (NULL != up->pps_peer) + save_ltc(up->pps_peer->procptr, + gmprettydate(&up->pps_stamp2)); + DPRINTF(2, ("%s: PPS record processed," + " stamp='%s', recvt='%s'\n", + up->logname, + gmprettydate(&up->pps_stamp2), + gmprettydate(&up->pps_recvt2))); + + up->fl_pps = (0 != (pp->sloppyclockflag & CLK_FLAG2)) - 1; + up->fl_pps2 = -1; + return; + + fail: + DPRINTF(1, ("%s: PPS record processing FAILED\n", + up->logname)); + ++up->tc_breply; +} + +/* ------------------------------------------------------------------ */ + +static void +process_toff( + peerT * const peer , + json_ctx * const jctx , + const l_fp * const rtime) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + ++up->tc_sti_recv; + + /* remember this! */ + up->pf_toff = -1; + + /* bail out if there's indication that time sync is bad */ + if (up->fl_nosync) + return; + + if ( ! get_binary_time(&up->sti_recvt, jctx, + "clock_sec", "clock_nsec", 1)) + goto fail; + if ( ! get_binary_time(&up->sti_stamp, jctx, + "real_sec", "real_nsec", 1)) + goto fail; + L_SUB(&up->sti_recvt, &up->sti_fudge); + up->sti_local = *rtime; + up->fl_sti = -1; + + save_ltc(pp, gmprettydate(&up->sti_stamp)); + DPRINTF(2, ("%s: TOFF record processed," + " stamp='%s', recvt='%s'\n", + up->logname, + gmprettydate(&up->sti_stamp), + gmprettydate(&up->sti_recvt))); + return; + + fail: + DPRINTF(1, ("%s: TOFF record processing FAILED\n", + up->logname)); + ++up->tc_breply; +} + +/* ------------------------------------------------------------------ */ + +static void +gpsd_parse( + peerT * const peer , + const l_fp * const rtime) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + const char * clsid; + + DPRINTF(2, ("%s: gpsd_parse: time %s '%.*s'\n", + up->logname, ulfptoa(rtime, 6), + up->buflen, up->buffer)); + + /* See if we can grab anything potentially useful. JSMN does not + * need a trailing NUL, but it needs the number of bytes to + * process. */ + if (!json_parse_record(&up->json_parse, up->buffer, up->buflen)) { + ++up->tc_breply; + return; + } + + /* Now dispatch over the objects we know */ + clsid = json_object_lookup_string(&up->json_parse, 0, "class"); + if (NULL == clsid) { + ++up->tc_breply; + return; + } + + if (!strcmp("TPV", clsid)) + process_tpv(peer, &up->json_parse, rtime); + else if (!strcmp("PPS", clsid)) + process_pps(peer, &up->json_parse, rtime); + else if (!strcmp("TOFF", clsid)) + process_toff(peer, &up->json_parse, rtime); + else if (!strcmp("VERSION", clsid)) + process_version(peer, &up->json_parse, rtime); + else if (!strcmp("WATCH", clsid)) + process_watch(peer, &up->json_parse, rtime); + else + return; /* nothing we know about... */ + ++up->tc_recv; + + /* if possible, feed the PPS side channel */ + if (up->pps_peer) + eval_pps_secondary( + up->pps_peer, up->pps_peer->procptr, up); + + /* check PPS vs. STI receive times: + * If STI is before PPS, then clearly the STI is too old. If PPS + * is before STI by more than one second, then PPS is too old. + * Weed out stale time stamps & flags. + */ + if (up->fl_pps && up->fl_sti) { + l_fp diff; + diff = up->sti_local; + L_SUB(&diff, &up->pps_local); + if (diff.l_i > 0) + up->fl_pps = 0; /* pps too old */ + else if (diff.l_i < 0) + up->fl_sti = 0; /* serial data too old */ + } + + /* dispatch to the mode-dependent processing functions */ + switch (up->mode) { + default: + case MODE_OP_STI: + eval_serial(peer, pp, up); + break; + + case MODE_OP_STRICT: + eval_strict(peer, pp, up); + break; + + case MODE_OP_AUTO: + eval_auto(peer, pp, up); + break; + } +} + +/* ------------------------------------------------------------------ */ + +static void +gpsd_stop_socket( + peerT * const peer) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + if (-1 != pp->io.fd) { + if (syslogok(pp, up)) + msyslog(LOG_INFO, + "%s: closing socket to GPSD, fd=%d", + up->logname, pp->io.fd); + else + DPRINTF(1, ("%s: closing socket to GPSD, fd=%d\n", + up->logname, pp->io.fd)); + io_closeclock(&pp->io); + pp->io.fd = -1; + } + up->tickover = up->tickpres; + up->tickpres = min(up->tickpres + 5, TICKOVER_HIGH); + up->fl_vers = 0; + up->fl_sti = 0; + up->fl_pps = 0; + up->fl_watch = 0; +} + +/* ------------------------------------------------------------------ */ + +static void +gpsd_init_socket( + peerT * const peer) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + addrinfoT * ai; + int rc; + int ov; + + /* draw next address to try */ + if (NULL == up->addr) + up->addr = s_gpsd_addr; + ai = up->addr; + up->addr = ai->ai_next; + + /* try to create a matching socket */ + up->fdt = socket( + ai->ai_family, ai->ai_socktype, ai->ai_protocol); + if (-1 == up->fdt) { + if (syslogok(pp, up)) + msyslog(LOG_ERR, + "%s: cannot create GPSD socket: %m", + up->logname); + goto no_socket; + } + + /* Make sure the socket is non-blocking. Connect/reconnect and + * IO happen in an event-driven environment, and synchronous + * operations wreak havoc on that. + */ + rc = fcntl(up->fdt, F_SETFL, O_NONBLOCK, 1); + if (-1 == rc) { + if (syslogok(pp, up)) + msyslog(LOG_ERR, + "%s: cannot set GPSD socket to non-blocking: %m", + up->logname); + goto no_socket; + } + /* Disable nagling. The way both GPSD and NTPD handle the + * protocol makes it record-oriented, and in most cases + * complete records (JSON serialised objects) will be sent in + * one sweep. Nagling gives not much advantage but adds another + * delay, which can worsen the situation for some packets. + */ + ov = 1; + rc = setsockopt(up->fdt, IPPROTO_TCP, TCP_NODELAY, + (char*)&ov, sizeof(ov)); + if (-1 == rc) { + if (syslogok(pp, up)) + msyslog(LOG_INFO, + "%s: cannot disable TCP nagle: %m", + up->logname); + } + + /* Start a non-blocking connect. There might be a synchronous + * connection result we have to handle. + */ + rc = connect(up->fdt, ai->ai_addr, ai->ai_addrlen); + if (-1 == rc) { + if (errno == EINPROGRESS) { + DPRINTF(1, ("%s: async connect pending, fd=%d\n", + up->logname, up->fdt)); + return; + } + + if (syslogok(pp, up)) + msyslog(LOG_ERR, + "%s: cannot connect GPSD socket: %m", + up->logname); + goto no_socket; + } + + /* We had a successful synchronous connect, so we add the + * refclock processing ASAP. We still have to wait for the + * version string and apply the watch command later on, but we + * might as well get the show on the road now. + */ + DPRINTF(1, ("%s: new socket connection, fd=%d\n", + up->logname, up->fdt)); + + pp->io.fd = up->fdt; + up->fdt = -1; + if (0 == io_addclock(&pp->io)) { + if (syslogok(pp, up)) + msyslog(LOG_ERR, + "%s: failed to register with I/O engine", + up->logname); + goto no_socket; + } + + return; + + no_socket: + if (-1 != pp->io.fd) + close(pp->io.fd); + if (-1 != up->fdt) + close(up->fdt); + pp->io.fd = -1; + up->fdt = -1; + up->tickover = up->tickpres; + up->tickpres = min(up->tickpres + 5, TICKOVER_HIGH); +} + +/* ------------------------------------------------------------------ */ + +static void +gpsd_test_socket( + peerT * const peer) +{ + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + int ec, rc; + socklen_t lc; + + /* Check if the non-blocking connect was finished by testing the + * socket for writeability. Use the 'poll()' API if available + * and 'select()' otherwise. + */ + DPRINTF(2, ("%s: check connect, fd=%d\n", + up->logname, up->fdt)); + +#if defined(HAVE_SYS_POLL_H) + { + struct pollfd pfd; + + pfd.events = POLLOUT; + pfd.fd = up->fdt; + rc = poll(&pfd, 1, 0); + if (1 != rc || !(pfd.revents & POLLOUT)) + return; + } +#elif defined(HAVE_SYS_SELECT_H) + { + struct timeval tout; + fd_set wset; + + memset(&tout, 0, sizeof(tout)); + FD_ZERO(&wset); + FD_SET(up->fdt, &wset); + rc = select(up->fdt+1, NULL, &wset, NULL, &tout); + if (0 == rc || !(FD_ISSET(up->fdt, &wset))) + return; + } +#else +# error Blooper! That should have been found earlier! +#endif + + /* next timeout is a full one... */ + up->tickover = TICKOVER_LOW; + + /* check for socket error */ + ec = 0; + lc = sizeof(ec); + rc = getsockopt(up->fdt, SOL_SOCKET, SO_ERROR, &ec, &lc); + if (-1 == rc || 0 != ec) { + const char *errtxt; + if (0 == ec) + ec = errno; + errtxt = strerror(ec); + if (syslogok(pp, up)) + msyslog(LOG_ERR, + "%s: async connect to GPSD failed," + " fd=%d, ec=%d(%s)", + up->logname, up->fdt, ec, errtxt); + else + DPRINTF(1, ("%s: async connect to GPSD failed," + " fd=%d, ec=%d(%s)\n", + up->logname, up->fdt, ec, errtxt)); + goto no_socket; + } else { + DPRINTF(1, ("%s: async connect to GPSD succeeded, fd=%d\n", + up->logname, up->fdt)); + } + + /* swap socket FDs, and make sure the clock was added */ + pp->io.fd = up->fdt; + up->fdt = -1; + if (0 == io_addclock(&pp->io)) { + if (syslogok(pp, up)) + msyslog(LOG_ERR, + "%s: failed to register with I/O engine", + up->logname); + goto no_socket; + } + return; + + no_socket: + if (-1 != up->fdt) { + DPRINTF(1, ("%s: closing socket, fd=%d\n", + up->logname, up->fdt)); + close(up->fdt); + } + up->fdt = -1; + up->tickover = up->tickpres; + up->tickpres = min(up->tickpres + 5, TICKOVER_HIGH); +} + +/* ===================================================================== + * helper stuff + */ + +/* ------------------------------------------------------------------- + * store a properly clamped precision value + */ +static int16_t +clamped_precision( + int rawprec) +{ + if (rawprec > 0) + rawprec = 0; + if (rawprec < -32) + rawprec = -32; + return (int16_t)rawprec; +} + +/* ------------------------------------------------------------------- + * Convert a GPSD timestamp (ISO8601 Format) to an l_fp + */ +static BOOL +convert_ascii_time( + l_fp * fp , + const char * gps_time) +{ + char *ep; + struct tm gd; + struct timespec ts; + uint32_t dw; + + /* Use 'strptime' to take the brunt of the work, then parse + * the fractional part manually, starting with a digit weight of + * 10^8 nanoseconds. + */ + ts.tv_nsec = 0; + ep = strptime(gps_time, "%Y-%m-%dT%H:%M:%S", &gd); + if (NULL == ep) + return FALSE; /* could not parse the mandatory stuff! */ + if (*ep == '.') { + dw = 100000000u; + while (isdigit(*(u_char*)++ep)) { + ts.tv_nsec += (*(u_char*)ep - '0') * dw; + dw /= 10u; + } + } + if (ep[0] != 'Z' || ep[1] != '\0') + return FALSE; /* trailing garbage */ + + /* Now convert the whole thing into a 'l_fp'. We do not use + * 'mkgmtime()' since its not standard and going through the + * calendar routines is not much effort, either. + */ + ts.tv_sec = (ntpcal_tm_to_rd(&gd) - DAY_NTP_STARTS) * SECSPERDAY + + ntpcal_tm_to_daysec(&gd); + *fp = tspec_intv_to_lfp(ts); + + return TRUE; +} + +/* ------------------------------------------------------------------- + * Save the last timecode string, making sure it's properly truncated + * if necessary and NUL terminated in any case. + */ +static void +save_ltc( + clockprocT * const pp, + const char * const tc) +{ + size_t len; + + len = (tc) ? strlen(tc) : 0; + if (len >= sizeof(pp->a_lastcode)) + len = sizeof(pp->a_lastcode) - 1; + pp->lencode = (u_short)len; + memcpy(pp->a_lastcode, tc, len); + pp->a_lastcode[len] = '\0'; +} + +/* ------------------------------------------------------------------- + * asprintf replacement... it's not available everywhere... + */ +static int +myasprintf( + char ** spp, + char const * fmt, + ... ) +{ + size_t alen, plen; + + alen = 32; + *spp = NULL; + do { + va_list va; + + alen += alen; + free(*spp); + *spp = (char*)malloc(alen); + if (NULL == *spp) + return -1; + + va_start(va, fmt); + plen = (size_t)vsnprintf(*spp, alen, fmt, va); + va_end(va); + } while (plen >= alen); + + return (int)plen; +} + +/* ------------------------------------------------------------------- + * dump a raw data buffer + */ + +static char * +add_string( + char *dp, + char *ep, + const char *sp) +{ + while (dp != ep && *sp) + *dp++ = *sp++; + return dp; +} + +static void +log_data( + peerT *peer, + const char *what, + const char *buf , + size_t len ) +{ + /* we're running single threaded with regards to the clocks. */ + static char s_lbuf[2048]; + + clockprocT * const pp = peer->procptr; + gpsd_unitT * const up = (gpsd_unitT *)pp->unitptr; + + if (debug > 1) { + const char *sptr = buf; + const char *stop = buf + len; + char *dptr = s_lbuf; + char *dtop = s_lbuf + sizeof(s_lbuf) - 1; /* for NUL */ + + while (sptr != stop && dptr != dtop) { + u_char uch = (u_char)*sptr++; + if (uch == '\\') { + dptr = add_string(dptr, dtop, "\\\\"); + } else if (isprint(uch)) { + *dptr++ = (char)uch; + } else { + char fbuf[6]; + snprintf(fbuf, sizeof(fbuf), "\\%03o", uch); + dptr = add_string(dptr, dtop, fbuf); + } + } + *dptr = '\0'; + mprintf("%s[%s]: '%s'\n", up->logname, what, s_lbuf); + } +} + +#else +NONEMPTY_TRANSLATION_UNIT +#endif /* REFCLOCK && CLOCK_GPSDJSON */ diff --git a/contrib/ntp/ntpd/refclock_gpsvme.c b/contrib/ntp/ntpd/refclock_gpsvme.c index 9f9e85c9f..66ccc9a3e 100644 --- a/contrib/ntp/ntpd/refclock_gpsvme.c +++ b/contrib/ntp/ntpd/refclock_gpsvme.c @@ -104,13 +104,9 @@ psc_start( return 0; } - if (!up) { - msyslog(LOG_ERR, "psc_start: unit: %d, emalloc: %m", unit); - return 0; - } memset(up, '\0', sizeof *up); - sprintf(buf, DEVICE, unit); /* dev file name */ + snprintf(buf, sizeof(buf), DEVICE, unit); /* dev file name */ fd[unit] = open(buf, O_RDONLY); /* open device file */ if (fd[unit] < 0) { msyslog(LOG_ERR, "psc_start: unit: %d, open failed. %m", unit); @@ -126,12 +122,12 @@ psc_start( /* initialize peer variables */ pp = peer->procptr; pp->io.clock_recv = noentry; - pp->io.srcclock = (caddr_t) peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = -1; - pp->unitptr = (caddr_t) up; + pp->unitptr = up; get_systime(&pp->lastrec); - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; up->unit = unit; @@ -149,8 +145,10 @@ psc_shutdown( struct peer *peer ) { - free(peer->procptr->unitptr); - close(fd[unit]); + if (NULL != peer->procptr->unitptr) + free(peer->procptr->unitptr); + if (fd[unit] > 0) + close(fd[unit]); } /* psc_poll: read, decode, and record device time */ @@ -175,7 +173,7 @@ psc_poll( if (!up->msg_flag[unit]) { /* write once to system log */ msyslog(LOG_WARNING, "SYNCHRONIZATION LOST on unit %1d, status %02x\n", - status, unit); + unit, status); up->msg_flag[unit] = 1; } return; @@ -196,9 +194,10 @@ psc_poll( pp->nsec = 1000000*BCD2INT3((tlo & 0x00FFF000) >> 12) + BCD2INT3(tlo & 0x00000FFF); - sprintf(pp->a_lastcode, "%3.3d %2.2d:%2.2d:%2.2d.%09ld %02x %08x %08x", - pp->day, pp->hour, pp->minute, pp->second, pp->nsec, status, thi, - tlo); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%3.3d %2.2d:%2.2d:%2.2d.%09ld %02x %08x %08x", pp->day, + pp->hour, pp->minute, pp->second, pp->nsec, status, thi, + tlo); pp->lencode = strlen(pp->a_lastcode); /* compute the timecode timestamp */ diff --git a/contrib/ntp/ntpd/refclock_heath.c b/contrib/ntp/ntpd/refclock_heath.c index a56b491b4..aed056c91 100644 --- a/contrib/ntp/ntpd/refclock_heath.c +++ b/contrib/ntp/ntpd/refclock_heath.c @@ -186,10 +186,10 @@ static int speed[] = {B1200, B2400, B4800, B9600}; /* * Function prototypes */ -static int heath_start P((int, struct peer *)); -static void heath_shutdown P((int, struct peer *)); -static void heath_receive P((struct recvbuf *)); -static void heath_poll P((int, struct peer *)); +static int heath_start (int, struct peer *); +static void heath_shutdown (int, struct peer *); +static void heath_receive (struct recvbuf *); +static void heath_poll (int, struct peer *); /* * Transfer vector @@ -221,17 +221,19 @@ heath_start( /* * Open serial port */ - sprintf(device, DEVICE, unit); - if (!(fd = refclock_open(device, speed[peer->ttl & 0x3], - LDISC_REMOTE))) + snprintf(device, sizeof(device), DEVICE, unit); + fd = refclock_open(device, speed[peer->ttl & 0x3], + LDISC_REMOTE); + if (fd <= 0) return (0); pp = peer->procptr; pp->io.clock_recv = heath_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; return (0); } @@ -239,9 +241,8 @@ heath_start( * Initialize miscellaneous variables */ peer->precision = PRECISION; - peer->burst = NSTAGE; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); return (1); } @@ -258,7 +259,8 @@ heath_shutdown( struct refclockproc *pp; pp = peer->procptr; - io_closeclock(&pp->io); + if (-1 != pp->io.fd) + io_closeclock(&pp->io); } @@ -280,7 +282,7 @@ heath_receive( /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; pp->lencode = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &trtmp); @@ -377,7 +379,7 @@ heath_receive( /* * Determine synchronization and last update */ - if (!isdigit((int)dsec)) + if (!isdigit((unsigned char)dsec)) pp->leap = LEAP_NOTINSYNC; else { pp->nsec = (dsec - '0') * 100000000; @@ -428,8 +430,6 @@ heath_poll( if (write(pp->io.fd, "T", 1) != 1) refclock_report(peer, CEVNT_FAULT); ioctl(pp->io.fd, TIOCMBIS, (char *)&bits); - if (peer->burst > 0) - return; if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; @@ -442,7 +442,6 @@ heath_poll( printf("heath: timecode %d %s\n", pp->lencode, pp->a_lastcode); #endif - peer->burst = MAXSTAGE; pp->polls++; } diff --git a/contrib/ntp/ntpd/refclock_hopfpci.c b/contrib/ntp/ntpd/refclock_hopfpci.c index 81c186d16..95bcab983 100644 --- a/contrib/ntp/ntpd/refclock_hopfpci.c +++ b/contrib/ntp/ntpd/refclock_hopfpci.c @@ -124,51 +124,38 @@ hopfpci_start( /* * Allocate and initialize unit structure */ - up = (struct hopfclock_unit *) emalloc(sizeof(struct hopfclock_unit)); - - if (!(up)) { - msyslog(LOG_ERR, "hopfPCIClock(%d) emalloc: %m",unit); -#ifdef DEBUG - printf("hopfPCIClock(%d) emalloc\n",unit); -#endif - return (0); - } - memset((char *)up, 0, sizeof(struct hopfclock_unit)); + up = emalloc_zero(sizeof(*up)); #ifndef SYS_WINNT fd = open(DEVICE,O_RDWR); /* try to open hopf clock device */ #else - if (!OpenHopfDevice()){ - msyslog(LOG_ERR,"Start: %s unit: %d failed!",DEVICE,unit); + if (!OpenHopfDevice()) { + msyslog(LOG_ERR, "Start: %s unit: %d failed!", DEVICE, unit); + free(up); return (0); } #endif pp = peer->procptr; pp->io.clock_recv = noentry; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = INVALID_SOCKET; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; get_systime(&pp->lastrec); /* * Initialize miscellaneous peer variables */ - if (pp->unitptr!=0) { - memcpy((char *)&pp->refid, REFID, 4); - peer->precision = PRECISION; - pp->clockdesc = DESCRIPTION; - up->leap_status = 0; - up->unit = (short) unit; - return (1); - } - else { - return 0; - } + memcpy((char *)&pp->refid, REFID, 4); + peer->precision = PRECISION; + pp->clockdesc = DESCRIPTION; + up->leap_status = 0; + up->unit = (short) unit; + return (1); } @@ -187,6 +174,8 @@ hopfpci_shutdown( #else CloseHopfDevice(); #endif + if (NULL != peer->procptr->unitptr) + free(peer->procptr->unitptr); } @@ -205,7 +194,9 @@ hopfpci_poll( pp = peer->procptr; #ifndef SYS_WINNT - ioctl(fd,HOPF_CLOCK_GET_UTC,&m_time); + if (ioctl(fd, HOPF_CLOCK_GET_UTC, &m_time) < 0) + msyslog(LOG_ERR, "HOPF_P(%d): HOPF_CLOCK_GET_UTC: %m", + unit); #else GetHopfSystemTime(&m_time); #endif @@ -221,9 +212,11 @@ hopfpci_poll( else pp->leap = LEAP_NOWARNING; - sprintf(pp->a_lastcode,"ST: %02X T: %02d:%02d:%02d.%03ld D: %02d.%02d.%04d", - m_time.wStatus, pp->hour, pp->minute, pp->second, - pp->nsec / 1000000, m_time.wDay, m_time.wMonth, m_time.wYear); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "ST: %02X T: %02d:%02d:%02d.%03ld D: %02d.%02d.%04d", + m_time.wStatus, pp->hour, pp->minute, pp->second, + pp->nsec / 1000000, m_time.wDay, m_time.wMonth, + m_time.wYear); pp->lencode = (u_short)strlen(pp->a_lastcode); get_systime(&pp->lastrec); diff --git a/contrib/ntp/ntpd/refclock_hopfser.c b/contrib/ntp/ntpd/refclock_hopfser.c index 9037d4a92..dae8b3761 100644 --- a/contrib/ntp/ntpd/refclock_hopfser.c +++ b/contrib/ntp/ntpd/refclock_hopfser.c @@ -95,11 +95,11 @@ struct hopfclock_unit { * Function prototypes */ -static int hopfserial_start P((int, struct peer *)); -static void hopfserial_shutdown P((int, struct peer *)); -static void hopfserial_receive P((struct recvbuf *)); -static void hopfserial_poll P((int, struct peer *)); -/* static void hopfserial_io P((struct recvbuf *)); */ +static int hopfserial_start (int, struct peer *); +static void hopfserial_shutdown (int, struct peer *); +static void hopfserial_receive (struct recvbuf *); +static void hopfserial_poll (int, struct peer *); +/* static void hopfserial_io (struct recvbuf *); */ /* * Transfer vector */ @@ -127,11 +127,8 @@ hopfserial_start ( int fd; char gpsdev[20]; -#ifdef SYS_WINNT - (void) sprintf(gpsdev, "COM%d:", unit); -#else - (void) sprintf(gpsdev, DEVICE, unit); -#endif + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); + /* LDISC_STD, LDISC_RAW * Open serial port. Use CLK line discipline, if available. */ @@ -149,30 +146,21 @@ hopfserial_start ( /* * Allocate and initialize unit structure */ - up = (struct hopfclock_unit *) emalloc(sizeof(struct hopfclock_unit)); - - if (!(up)) { - msyslog(LOG_ERR, "hopfSerialClock(%d) emalloc: %m",unit); -#ifdef DEBUG - printf("hopfSerialClock(%d) emalloc\n",unit); -#endif - (void) close(fd); - return (0); - } - - memset((char *)up, 0, sizeof(struct hopfclock_unit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->io.clock_recv = hopfserial_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { #ifdef DEBUG - printf("hopfSerialClock(%d) io_addclock\n",unit); + printf("hopfSerialClock(%d) io_addclock\n", unit); #endif - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); + pp->unitptr = NULL; return (0); } @@ -181,7 +169,6 @@ hopfserial_start ( */ pp->clockdesc = DESCRIPTION; peer->precision = PRECISION; - peer->burst = NSTAGE; memcpy((char *)&pp->refid, REFID, 4); up->leap_status = 0; @@ -204,9 +191,12 @@ hopfserial_shutdown ( struct refclockproc *pp; pp = peer->procptr; - up = (struct hopfclock_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -224,30 +214,31 @@ hopfserial_receive ( struct refclockproc *pp; struct peer *peer; - int synch; /* synchhronization indicator */ - int DoW; /* Dow */ + int synch; /* synchhronization indicator */ + int DoW; /* Day of Week */ int day, month; /* ddd conversion */ + int converted; /* * Initialize pointers and read the timecode and timestamp. */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct hopfclock_unit *)pp->unitptr; + up = pp->unitptr; if (up->rpt_next == 0 ) return; - up->rpt_next = 0; /* wait until next poll interval occur */ - pp->lencode = (u_short)refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &pp->lastrec); - - if (pp->lencode == 0) + pp->lencode = (u_short)refclock_gtlin(rbufp, pp->a_lastcode, + sizeof(pp->a_lastcode), + &pp->lastrec); + if (pp->lencode == 0) return; - sscanf(pp->a_lastcode, + converted = sscanf(pp->a_lastcode, #if 1 "%1x%1x%2d%2d%2d%2d%2d%2d", /* ...cr,lf */ #else @@ -267,9 +258,9 @@ hopfserial_receive ( Validate received values at least enough to prevent internal array-bounds problems, etc. */ - if((pp->hour < 0) || (pp->hour > 23) || - (pp->minute < 0) || (pp->minute > 59) || - (pp->second < 0) || (pp->second > 60) /*Allow for leap seconds.*/ || + if ((8 != converted) || (pp->hour < 0) || (pp->hour > 23) || + (pp->minute < 0) || (pp->minute > 59) || (pp->second < 0) || + (pp->second > 60) /*Allow for leap seconds.*/ || (day < 1) || (day > 31) || (month < 1) || (month > 12) || (pp->year < 0) || (pp->year > 99)) { @@ -292,7 +283,7 @@ hopfserial_receive ( /* preparation for timecode ntpq rl command ! */ #if 0 - wsprintf(pp->a_lastcode, + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), "STATUS: %1X%1X, DATE: %02d.%02d.%04d TIME: %02d:%02d:%02d", synch, DoW, @@ -364,7 +355,7 @@ hopfserial_poll ( struct refclockproc *pp; pp = peer->procptr; - up = (struct hopfclock_unit *)pp->unitptr; + up = pp->unitptr; pp->polls++; up->rpt_next = 1; diff --git a/contrib/ntp/ntpd/refclock_hpgps.c b/contrib/ntp/ntpd/refclock_hpgps.c index 5efd19eaa..0b45fc74f 100644 --- a/contrib/ntp/ntpd/refclock_hpgps.c +++ b/contrib/ntp/ntpd/refclock_hpgps.c @@ -125,10 +125,10 @@ struct hpgpsunit { /* * Function prototypes */ -static int hpgps_start P((int, struct peer *)); -static void hpgps_shutdown P((int, struct peer *)); -static void hpgps_receive P((struct recvbuf *)); -static void hpgps_poll P((int, struct peer *)); +static int hpgps_start (int, struct peer *); +static void hpgps_shutdown (int, struct peer *); +static void hpgps_receive (struct recvbuf *); +static void hpgps_poll (int, struct peer *); /* * Transfer vector @@ -156,42 +156,40 @@ hpgps_start( register struct hpgpsunit *up; struct refclockproc *pp; int fd; + int speed, ldisc; char device[20]; /* * Open serial port. Use CLK line discipline, if available. * Default is HP 58503A, mode arg selects HP Z3801A */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); + ldisc = LDISC_CLK; + speed = SPEED232; /* mode parameter to server config line shares ttl slot */ - if ((peer->ttl == 1)) { - if (!(fd = refclock_open(device, SPEED232Z, - LDISC_CLK | LDISC_7O1))) - return (0); - } else { - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) - return (0); + if (1 == peer->ttl) { + ldisc |= LDISC_7O1; + speed = SPEED232Z; } + fd = refclock_open(device, speed, ldisc); + if (fd <= 0) + return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct hpgpsunit *) - emalloc(sizeof(struct hpgpsunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct hpgpsunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = hpgps_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -231,9 +229,11 @@ hpgps_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct hpgpsunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -266,9 +266,9 @@ hpgps_receive( /* * Initialize pointers and read the receiver response */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct hpgpsunit *)pp->unitptr; + up = pp->unitptr; *pp->a_lastcode = '\0'; pp->lencode = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &trtmp); @@ -301,7 +301,7 @@ hpgps_receive( if (up->linecnt-- > 0) { if ((int)(pp->lencode + 2) <= (SMAX - (up->lastptr - up->statscrn))) { *up->lastptr++ = '\n'; - (void)strcpy(up->lastptr, pp->a_lastcode); + memcpy(up->lastptr, pp->a_lastcode, pp->lencode); up->lastptr += pp->lencode; } if (up->linecnt == 0) @@ -334,7 +334,7 @@ hpgps_receive( * */ - (void)strcpy(prompt,pp->a_lastcode); + strlcpy(prompt, pp->a_lastcode, sizeof(prompt)); tcp = strrchr(pp->a_lastcode,'>'); if (tcp == NULL) tcp = pp->a_lastcode; @@ -532,18 +532,25 @@ hpgps_receive( pp->leap = LEAP_NOTINSYNC; } else { + pp->leap = LEAP_NOWARNING; switch (leapchar) { - case '+': - pp->leap = LEAP_ADDSECOND; + case '0': break; - case '0': - pp->leap = LEAP_NOWARNING; + /* See http://bugs.ntp.org/1090 + * Ignore leap announcements unless June or December. + * Better would be to use :GPSTime? to find the month, + * but that seems too likely to introduce other bugs. + */ + case '+': + if ((month==6) || (month==12)) + pp->leap = LEAP_ADDSECOND; break; case '-': - pp->leap = LEAP_DELSECOND; + if ((month==6) || (month==12)) + pp->leap = LEAP_DELSECOND; break; default: @@ -602,7 +609,7 @@ hpgps_poll( * declare a timeout and keep going. */ pp = peer->procptr; - up = (struct hpgpsunit *)pp->unitptr; + up = pp->unitptr; if (up->pollcnt == 0) refclock_report(peer, CEVNT_TIMEOUT); else diff --git a/contrib/ntp/ntpd/refclock_irig.c b/contrib/ntp/ntpd/refclock_irig.c index 6be09d9ba..abc94f62e 100644 --- a/contrib/ntp/ntpd/refclock_irig.c +++ b/contrib/ntp/ntpd/refclock_irig.c @@ -25,27 +25,36 @@ /* * Audio IRIG-B/E demodulator/decoder * - * This driver receives, demodulates and decodes IRIG-B/E signals when - * connected to the audio codec /dev/audio. The IRIG signal format is an - * amplitude-modulated carrier with pulse-width modulated data bits. For - * IRIG-B, the carrier frequency is 1000 Hz and bit rate 100 b/s; for - * IRIG-E, the carrier frequenchy is 100 Hz and bit rate 10 b/s. The - * driver automatically recognizes which format is in use. + * This driver synchronizes the computer time using data encoded in + * IRIG-B/E signals commonly produced by GPS receivers and other timing + * devices. The IRIG signal is an amplitude-modulated carrier with + * pulse-width modulated data bits. For IRIG-B, the carrier frequency is + * 1000 Hz and bit rate 100 b/s; for IRIG-E, the carrier frequenchy is + * 100 Hz and bit rate 10 b/s. The driver automatically recognizes which + & format is in use. + * + * The driver requires an audio codec or sound card with sampling rate 8 + * kHz and mu-law companding. This is the same standard as used by the + * telephone industry and is supported by most hardware and operating + * systems, including Solaris, SunOS, FreeBSD, NetBSD and Linux. In this + * implementation, only one audio driver and codec can be supported on a + * single machine. * * The program processes 8000-Hz mu-law companded samples using separate * signal filters for IRIG-B and IRIG-E, a comb filter, envelope * detector and automatic threshold corrector. Cycle crossings relative * to the corrected slice level determine the width of each pulse and - * its value - zero, one or position identifier. The data encode 20 BCD - * digits which determine the second, minute, hour and day of the year - * and sometimes the year and synchronization condition. The comb filter - * exponentially averages the corresponding samples of successive baud - * intervals in order to reliably identify the reference carrier cycle. - * A type-II phase-lock loop (PLL) performs additional integration and - * interpolation to accurately determine the zero crossing of that - * cycle, which determines the reference timestamp. A pulse-width - * discriminator demodulates the data pulses, which are then encoded as - * the BCD digits of the timecode. + * its value - zero, one or position identifier. + * + * The data encode 20 BCD digits which determine the second, minute, + * hour and day of the year and sometimes the year and synchronization + * condition. The comb filter exponentially averages the corresponding + * samples of successive baud intervals in order to reliably identify + * the reference carrier cycle. A type-II phase-lock loop (PLL) performs + * additional integration and interpolation to accurately determine the + * zero crossing of that cycle, which determines the reference + * timestamp. A pulse-width discriminator demodulates the data pulses, + * which are then encoded as the BCD digits of the timecode. * * The timecode and reference timestamp are updated once each second * with IRIG-B (ten seconds with IRIG-E) and local clock offset samples @@ -60,70 +69,60 @@ * decompanded input signal amplitude must be greater than 100 units and * the codec sample frequency error less than 250 PPM (.025 percent). * - * The program performs a number of error checks to protect against - * overdriven or underdriven input signal levels, incorrect signal - * format or improper hardware configuration. Specifically, if any of - * the following errors occur for a time measurement, the data are - * rejected. - * - * o The peak carrier amplitude is less than DRPOUT (100). This usually - * means dead IRIG signal source, broken cable or wrong input port. - * - * o The frequency error is greater than MAXFREQ +-250 PPM (.025%). This - * usually means broken codec hardware or wrong codec configuration. - * - * o The modulation index is less than MODMIN (0.5). This usually means - * overdriven IRIG signal or wrong IRIG format. - * - * o A frame synchronization error has occurred. This usually means - * wrong IRIG signal format or the IRIG signal source has lost - * synchronization (signature control). - * - * o A data decoding error has occurred. This usually means wrong IRIG - * signal format. - * - * o The current second of the day is not exactly one greater than the - * previous one. This usually means a very noisy IRIG signal or - * insufficient CPU resources. + * Monitor Data * - * o An audio codec error (overrun) occurred. This usually means - * insufficient CPU resources, as sometimes happens with Sun SPARC - * IPCs when doing something useful. + * The timecode format used for debugging and data recording includes + * data helpful in diagnosing problems with the IRIG signal and codec + * connections. The driver produces one line for each timecode in the + * following format: * - * Note that additional checks are done elsewhere in the reference clock - * interface routines. + * 00 00 98 23 19:26:52 2782 143 0.694 10 0.3 66.5 3094572411.00027 * - * Debugging aids + * If clockstats is enabled, the most recent line is written to the + * clockstats file every 64 s. If verbose recording is enabled (fudge + * flag 4) each line is written as generated. * - * The timecode format used for debugging and data recording includes - * data helpful in diagnosing problems with the IRIG signal and codec - * connections. With debugging enabled (-d on the ntpd command line), - * the driver produces one line for each timecode in the following - * format: + * The first field containes the error flags in hex, where the hex bits + * are interpreted as below. This is followed by the year of century, + * day of year and time of day. Note that the time of day is for the + * previous minute, not the current time. The status indicator and year + * are not produced by some IRIG devices and appear as zeros. Following + * these fields are the carrier amplitude (0-3000), codec gain (0-255), + * modulation index (0-1), time constant (4-10), carrier phase error + * +-.5) and carrier frequency error (PPM). The last field is the on- + * time timestamp in NTP format. * - * 00 1 98 23 19:26:52 721 143 0.694 20 0.1 66.5 3094572411.00027 + * The error flags are defined as follows in hex: * - * The most recent line is also written to the clockstats file at 64-s - * intervals. + * x01 Low signal. The carrier amplitude is less than 100 units. This + * is usually the result of no signal or wrong input port. + * x02 Frequency error. The codec frequency error is greater than 250 + * PPM. This may be due to wrong signal format or (rarely) + * defective codec. + * x04 Modulation error. The IRIG modulation index is less than 0.5. + * This is usually the result of an overdriven codec, wrong signal + * format or wrong input port. + * x08 Frame synch error. The decoder frame does not match the IRIG + * frame. This is usually the result of an overdriven codec, wrong + * signal format or noisy IRIG signal. It may also be the result of + * an IRIG signature check which indicates a failure of the IRIG + * signal synchronization source. + * x10 Data bit error. The data bit length is out of tolerance. This is + * usually the result of an overdriven codec, wrong signal format + * or noisy IRIG signal. + * x20 Seconds numbering discrepancy. The decoder second does not match + * the IRIG second. This is usually the result of an overdriven + * codec, wrong signal format or noisy IRIG signal. + * x40 Codec error (overrun). The machine is not fast enough to keep up + * with the codec. + * x80 Device status error (Spectracom). * - * The first field contains the error flags in hex, where the hex bits - * are interpreted as below. This is followed by the IRIG status - * indicator, year of century, day of year and time of day. The status - * indicator and year are not produced by some IRIG devices. Following - * these fields are the signal amplitude (0-8100), codec gain (0-255), - * modulation index (0-1), time constant (2-20), carrier phase error - * (us) and carrier frequency error (PPM). The last field is the on-time - * timestamp in NTP format. * - * The fraction part of the on-time timestamp is a good indicator of how - * well the driver is doing. Once upon a time, an UltrSPARC 30 and - * Solaris 2.7 kept the clock within a few tens of microseconds relative - * to the IRIG-B signal. Accuracy with IRIG-E was about ten times worse. - * Unfortunately, Sun broke the 2.7 audio driver in 2.8, which has a 10- - * ms sawtooth modulation. The driver attempts to remove the modulation - * by some clever estimation techniques which mostly work. With the - * "mixerctl -o" command before starting the daemon, the jitter is down - * to about 100 microseconds. Your experience may vary. + * Once upon a time, an UltrSPARC 30 and Solaris 2.7 kept the clock + * within a few tens of microseconds relative to the IRIG-B signal. + * Accuracy with IRIG-E was about ten times worse. Unfortunately, Sun + * broke the 2.7 audio driver in 2.8, which has a 10-ms sawtooth + * modulation. * * Unlike other drivers, which can have multiple instantiations, this * one supports only one. It does not seem likely that more than one @@ -137,8 +136,13 @@ * port, where 0 is the mike port (default) and 1 is the line-in port. * It does not seem useful to select the compact disc player port. Fudge * flag3 enables audio monitoring of the input signal. For this purpose, - * the monitor gain is set to a default value. Fudgetime2 is used as a + * the monitor gain is set t a default value. Fudgetime2 is used as a * frequency vernier for broken codec sample frequency. + * + * Alarm codes + * + * CEVNT_BADTIME invalid date or time + * CEVNT_TIMEOUT no IRIG data since last poll */ /* * Interface definitions @@ -152,26 +156,30 @@ #define BAUD 80 /* samples per baud interval */ #define OFFSET 128 /* companded sample offset */ #define SIZE 256 /* decompanding table size */ -#define CYCLE 8 /* samples per carrier cycle */ -#define SUBFLD 10 /* bits per subfield */ -#define FIELD 10 /* subfields per field */ +#define CYCLE 8 /* samples per bit */ +#define SUBFLD 10 /* bits per frame */ +#define FIELD 100 /* bits per second */ #define MINTC 2 /* min PLL time constant */ -#define MAXTC 20 /* max PLL time constant max */ -#define MAXAMP 6000. /* maximum signal level */ -#define MAXCLP 100 /* max clips above reference per s */ -#define DRPOUT 100. /* dropout signal level */ +#define MAXTC 10 /* max PLL time constant max */ +#define MAXAMP 3000. /* maximum signal amplitude */ +#define MINAMP 2000. /* minimum signal amplitude */ +#define DRPOUT 100. /* dropout signal amplitude */ #define MODMIN 0.5 /* minimum modulation index */ #define MAXFREQ (250e-6 * SECOND) /* freq tolerance (.025%) */ -#define PI 3.1415926535 /* the real thing */ -#ifdef IRIG_SUCKS -#define WIGGLE 11 /* wiggle filter length */ -#endif /* IRIG_SUCKS */ /* - * Experimentally determined filter delays + * The on-time synchronization point is the positive-going zero crossing + * of the first cycle of the second. The IIR baseband filter phase delay + * is 1.03 ms for IRIG-B and 3.47 ms for IRIG-E. The fudge value 2.68 ms + * due to the codec and other causes was determined by calibrating to a + * PPS signal from a GPS receiver. + * + * The results with a 2.4-GHz P4 running FreeBSD 6.1 are generally + * within .02 ms short-term with .02 ms jitter. The processor load due + * to the driver is 0.51 percent. */ -#define IRIG_B .0019 /* IRIG-B filter delay */ -#define IRIG_E .0019 /* IRIG-E filter delay */ +#define IRIG_B ((1.03 + 2.68) / 1000) /* IRIG-B system delay (s) */ +#define IRIG_E ((3.47 + 2.68) / 1000) /* IRIG-E system delay (s) */ /* * Data bit definitions @@ -181,7 +189,7 @@ #define BITP 2 /* position identifier */ /* - * Error flags (up->errflg) + * Error flags */ #define IRIG_ERR_AMP 0x01 /* low carrier amplitude */ #define IRIG_ERR_FREQ 0x02 /* frequency tolerance exceeded */ @@ -192,13 +200,18 @@ #define IRIG_ERR_ERROR 0x40 /* codec error (overrun) */ #define IRIG_ERR_SIGERR 0x80 /* IRIG status error (Spectracom) */ +static char hexchar[] = "0123456789abcdef"; + /* * IRIG unit control structure */ struct irigunit { - u_char timecode[21]; /* timecode string */ + u_char timecode[2 * SUBFLD + 1]; /* timecode string */ l_fp timestamp; /* audio sample timestamp */ l_fp tick; /* audio sample increment */ + l_fp refstamp; /* reference timestamp */ + l_fp chrstamp; /* baud timestamp */ + l_fp prvstamp; /* previous baud timestamp */ double integ[BAUD]; /* baud integrator */ double phase, freq; /* logical clock phase and frequency */ double zxing; /* phase detector integrator */ @@ -212,20 +225,20 @@ struct irigunit { * Audio codec variables */ double comp[SIZE]; /* decompanding table */ + double signal; /* peak signal for AGC */ int port; /* codec port */ int gain; /* codec gain */ int mongain; /* codec monitor gain */ - int clipcnt; /* sample clipped count */ int seccnt; /* second interval counter */ /* * RF variables */ - double hpf[5]; /* IRIG-B filter shift register */ + double bpf[9]; /* IRIG-B filter shift register */ double lpf[5]; /* IRIG-E filter shift register */ + double envmin, envmax; /* envelope min and max */ + double slice; /* envelope slice level */ double intmin, intmax; /* integrated envelope min and max */ - double envmax; /* peak amplitude */ - double envmin; /* noise amplitude */ double maxsignal; /* integrated peak amplitude */ double noise; /* integrated noise amplitude */ double lastenv[CYCLE]; /* last cycle amplitudes */ @@ -235,7 +248,6 @@ struct irigunit { int decim; /* sample decimation factor */ int envphase; /* envelope phase */ int envptr; /* envelope phase pointer */ - int carphase; /* carrier phase */ int envsw; /* envelope state */ int envxing; /* envelope slice crossing */ int tc; /* time constant */ @@ -248,36 +260,30 @@ struct irigunit { int pulse; /* cycle counter */ int cycles; /* carrier cycles */ int dcycles; /* data cycles */ - int xptr; /* translate table pointer */ - int lastbit; /* last code element length */ + int lastbit; /* last code element */ int second; /* previous second */ - int fieldcnt; /* subfield count in field */ + int bitcnt; /* bit count in frame */ + int frmcnt; /* bit count in second */ + int xptr; /* timecode pointer */ int bits; /* demodulated bits */ - int bitcnt; /* bit count in subfield */ -#ifdef IRIG_SUCKS - l_fp wigwag; /* wiggle accumulator */ - int wp; /* wiggle filter pointer */ - l_fp wiggle[WIGGLE]; /* wiggle filter */ - l_fp wigbot[WIGGLE]; /* wiggle bottom fisher*/ -#endif /* IRIG_SUCKS */ - l_fp wuggle; }; /* * Function prototypes */ -static int irig_start P((int, struct peer *)); -static void irig_shutdown P((int, struct peer *)); -static void irig_receive P((struct recvbuf *)); -static void irig_poll P((int, struct peer *)); +static int irig_start (int, struct peer *); +static void irig_shutdown (int, struct peer *); +static void irig_receive (struct recvbuf *); +static void irig_poll (int, struct peer *); /* * More function prototypes */ -static void irig_base P((struct peer *, double)); -static void irig_rf P((struct peer *, double)); -static void irig_decode P((struct peer *, int)); -static void irig_gain P((struct peer *)); +static void irig_base (struct peer *, double); +static void irig_rf (struct peer *, double); +static void irig_baud (struct peer *, int); +static void irig_decode (struct peer *, int); +static void irig_gain (struct peer *); /* * Transfer vector @@ -292,16 +298,6 @@ struct refclock refclock_irig = { NOFLAGS /* not used */ }; -/* - * Global variables - */ -static char hexchar[] = { /* really quick decoding table */ - '0', '8', '4', 'c', /* 0000 0001 0010 0011 */ - '2', 'a', '6', 'e', /* 0100 0101 0110 0111 */ - '1', '9', '5', 'd', /* 1000 1001 1010 1011 */ - '3', 'b', '7', 'f' /* 1100 1101 1110 1111 */ -}; - /* * irig_start - open the devices and initialize data for processing @@ -336,23 +332,19 @@ irig_start( /* * Allocate and initialize unit structure */ - if (!(up = (struct irigunit *) - emalloc(sizeof(struct irigunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct irigunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; pp->io.clock_recv = irig_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void)close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -362,7 +354,6 @@ irig_start( memcpy((char *)&pp->refid, REFID, 4); up->tc = MINTC; up->decim = 1; - up->fdelay = IRIG_B; up->gain = 127; /* @@ -376,7 +367,7 @@ irig_start( for (i = 3; i < OFFSET; i++) { up->comp[i] = up->comp[i - 1] + step; up->comp[OFFSET + i] = -up->comp[i]; - if (i % 16 == 0) + if (i % 16 == 0) step *= 2.; } DTOLFP(1. / SECOND, &up->tick); @@ -397,9 +388,11 @@ irig_shutdown( struct irigunit *up; pp = peer->procptr; - up = (struct irigunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -426,9 +419,9 @@ irig_receive( int bufcnt; /* buffer counter */ l_fp ltemp; /* l_fp temp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct irigunit *)pp->unitptr; + up = pp->unitptr; /* * Main loop - read until there ain't no more. Note codec @@ -441,19 +434,6 @@ irig_receive( for (bufcnt = 0; bufcnt < rbufp->recv_length; bufcnt++) { sample = up->comp[~*dpt++ & 0xff]; - /* - * Clip noise spikes greater than MAXAMP. If no clips, - * increase the gain a tad; if the clips are too high, - * decrease a tad. - */ - if (sample > MAXAMP) { - sample = MAXAMP; - up->clipcnt++; - } else if (sample < -MAXAMP) { - sample = -MAXAMP; - up->clipcnt++; - } - /* * Variable frequency oscillator. The codec oscillator * runs at the nominal rate of 8000 samples per second, @@ -462,7 +442,7 @@ irig_receive( * per second, which results in a frequency change of * 125 PPM. */ - up->phase += up->freq / SECOND; + up->phase += (up->freq + clock_codec) / SECOND; up->phase += pp->fudgetime2 / 1e6; if (up->phase >= .5) { up->phase -= 1.; @@ -474,6 +454,11 @@ irig_receive( irig_rf(peer, sample); } L_ADD(&up->timestamp, &up->tick); + sample = fabs(sample); + if (sample > up->signal) + up->signal = sample; + up->signal += (sample - up->signal) / + 1000; /* * Once each second, determine the IRIG format and gain. @@ -487,8 +472,9 @@ irig_receive( up->decim = 10; up->fdelay = IRIG_E; } - irig_gain(peer); up->irig_b = up->irig_e = 0; + irig_gain(peer); + } } @@ -505,14 +491,14 @@ irig_receive( up->mongain = 0; } + /* * irig_rf - RF processing * - * This routine filters the RF signal using a highpass filter for IRIG-B + * This routine filters the RF signal using a bandass filter for IRIG-B * and a lowpass filter for IRIG-E. In case of IRIG-E, the samples are - * decimated by a factor of ten. The lowpass filter functions also as a - * decimation filter in this case. Note that the codec filters function - * as roofing filters to attenuate both the high and low ends of the + * decimated by a factor of ten. Note that the codec filters function as + * roofing filters to attenuate both the high and low ends of the * passband. IIR filter coefficients were determined using Matlab Signal * Processing Toolkit. */ @@ -531,39 +517,48 @@ irig_rf( double irig_b, irig_e; /* irig filter outputs */ pp = peer->procptr; - up = (struct irigunit *)pp->unitptr; + up = pp->unitptr; /* - * IRIG-B filter. 4th-order elliptic, 800-Hz highpass, 0.3 dB - * passband ripple, -50 dB stopband ripple, phase delay .0022 - * s) + * IRIG-B filter. Matlab 4th-order IIR elliptic, 800-1200 Hz + * bandpass, 0.3 dB passband ripple, -50 dB stopband ripple, + * phase delay 1.03 ms. */ - irig_b = (up->hpf[4] = up->hpf[3]) * 2.322484e-01; - irig_b += (up->hpf[3] = up->hpf[2]) * -1.103929e+00; - irig_b += (up->hpf[2] = up->hpf[1]) * 2.351081e+00; - irig_b += (up->hpf[1] = up->hpf[0]) * -2.335036e+00; - up->hpf[0] = sample - irig_b; - irig_b = up->hpf[0] * 4.335855e-01 - + up->hpf[1] * -1.695859e+00 - + up->hpf[2] * 2.525004e+00 - + up->hpf[3] * -1.695859e+00 - + up->hpf[4] * 4.335855e-01; + irig_b = (up->bpf[8] = up->bpf[7]) * 6.505491e-001; + irig_b += (up->bpf[7] = up->bpf[6]) * -3.875180e+000; + irig_b += (up->bpf[6] = up->bpf[5]) * 1.151180e+001; + irig_b += (up->bpf[5] = up->bpf[4]) * -2.141264e+001; + irig_b += (up->bpf[4] = up->bpf[3]) * 2.712837e+001; + irig_b += (up->bpf[3] = up->bpf[2]) * -2.384486e+001; + irig_b += (up->bpf[2] = up->bpf[1]) * 1.427663e+001; + irig_b += (up->bpf[1] = up->bpf[0]) * -5.352734e+000; + up->bpf[0] = sample - irig_b; + irig_b = up->bpf[0] * 4.952157e-003 + + up->bpf[1] * -2.055878e-002 + + up->bpf[2] * 4.401413e-002 + + up->bpf[3] * -6.558851e-002 + + up->bpf[4] * 7.462108e-002 + + up->bpf[5] * -6.558851e-002 + + up->bpf[6] * 4.401413e-002 + + up->bpf[7] * -2.055878e-002 + + up->bpf[8] * 4.952157e-003; up->irig_b += irig_b * irig_b; /* - * IRIG-E filter. 4th-order elliptic, 130-Hz lowpass, 0.3 dB - * passband ripple, -50 dB stopband ripple, phase delay .0219 s. + * IRIG-E filter. Matlab 4th-order IIR elliptic, 130-Hz lowpass, + * 0.3 dB passband ripple, -50 dB stopband ripple, phase delay + * 3.47 ms. */ - irig_e = (up->lpf[4] = up->lpf[3]) * 8.694604e-01; - irig_e += (up->lpf[3] = up->lpf[2]) * -3.589893e+00; - irig_e += (up->lpf[2] = up->lpf[1]) * 5.570154e+00; - irig_e += (up->lpf[1] = up->lpf[0]) * -3.849667e+00; + irig_e = (up->lpf[4] = up->lpf[3]) * 8.694604e-001; + irig_e += (up->lpf[3] = up->lpf[2]) * -3.589893e+000; + irig_e += (up->lpf[2] = up->lpf[1]) * 5.570154e+000; + irig_e += (up->lpf[1] = up->lpf[0]) * -3.849667e+000; up->lpf[0] = sample - irig_e; - irig_e = up->lpf[0] * 3.215696e-03 - + up->lpf[1] * -1.174951e-02 - + up->lpf[2] * 1.712074e-02 - + up->lpf[3] * -1.174951e-02 - + up->lpf[4] * 3.215696e-03; + irig_e = up->lpf[0] * 3.215696e-003 + + up->lpf[1] * -1.174951e-002 + + up->lpf[2] * 1.712074e-002 + + up->lpf[3] * -1.174951e-002 + + up->lpf[4] * 3.215696e-003; up->irig_e += irig_e * irig_e; /* @@ -583,7 +578,8 @@ irig_rf( * * This routine processes the baseband signal and demodulates the AM * carrier using a synchronous detector. It then synchronizes to the - * data frame at the baud rate and decodes the data pulses. + * data frame at the baud rate and decodes the width-modulated data + * pulses. */ static void irig_base( @@ -597,61 +593,53 @@ irig_base( /* * Local variables */ - double xxing; /* phase detector interpolated output */ double lope; /* integrator output */ double env; /* envelope detector output */ - double dtemp; /* double temp */ + double dtemp; + int carphase; /* carrier phase */ pp = peer->procptr; - up = (struct irigunit *)pp->unitptr; + up = pp->unitptr; /* * Synchronous baud integrator. Corresponding samples of current * and past baud intervals are integrated to refine the envelope - * amplitude and phase estimate. We keep one cycle of both the - * raw and integrated data for later use. + * amplitude and phase estimate. We keep one cycle (1 ms) of the + * raw data and one baud (10 ms) of the integrated data. */ up->envphase = (up->envphase + 1) % BAUD; - up->carphase = (up->carphase + 1) % CYCLE; up->integ[up->envphase] += (sample - up->integ[up->envphase]) / (5 * up->tc); lope = up->integ[up->envphase]; - up->lastenv[up->carphase] = sample; - up->lastint[up->carphase] = lope; + carphase = up->envphase % CYCLE; + up->lastenv[carphase] = sample; + up->lastint[carphase] = lope; /* - * Phase detector. Sample amplitudes are integrated over the - * baud interval. Cycle phase is determined from these - * amplitudes using an eight-sample cyclic buffer. A phase - * change of 360 degrees produces an output change of one unit. + * Phase detector. Find the negative-going zero crossing + * relative to sample 4 in the 8-sample sycle. A phase change of + * 360 degrees produces an output change of one unit. */ - if (up->lastsig > 0 && lope <= 0) { - xxing = lope / (up->lastsig - lope); - up->zxing += (up->carphase - 4 + xxing) / CYCLE; - } + if (up->lastsig > 0 && lope <= 0) + up->zxing += (double)(carphase - 4) / CYCLE; up->lastsig = lope; /* - * Update signal/noise estimates and PLL phase/frequency. + * End of the baud. Update signal/noise estimates and PLL + * phase, frequency and time constant. */ if (up->envphase == 0) { - - /* - * Update envelope signal and noise estimates and mess - * with error bits. - */ - up->maxsignal = up->intmax; - up->noise = up->intmin; + up->maxsignal = up->intmax; up->noise = up->intmin; + up->intmin = 1e6; up->intmax = -1e6; if (up->maxsignal < DRPOUT) up->errflg |= IRIG_ERR_AMP; if (up->maxsignal > 0) - up->modndx = (up->intmax - up->intmin) / - up->intmax; + up->modndx = (up->maxsignal - up->noise) / + up->maxsignal; else up->modndx = 0; if (up->modndx < MODMIN) up->errflg |= IRIG_ERR_MOD; - up->intmin = 1e6; up->intmax = 0; if (up->errflg & (IRIG_ERR_AMP | IRIG_ERR_FREQ | IRIG_ERR_MOD | IRIG_ERR_SYNCH)) { up->tc = MINTC; @@ -681,17 +669,17 @@ irig_base( /* * Synchronous demodulator. There are eight samples in the cycle - * and ten cycles in the baud interval. The amplitude of each - * cycle is determined at the last sample in the cycle. The + * and ten cycles in the baud. Since the PLL has aligned the + * negative-going zero crossing at sample 4, the maximum + * amplitude is at sample 2 and minimum at sample 6. The * beginning of the data pulse is determined from the integrated * samples, while the end of the pulse is determined from the * raw samples. The raw data bits are demodulated relative to * the slice level and left-shifted in the decoding register. */ - if (up->carphase != 7) + if (carphase != 7) return; - env = (up->lastenv[2] - up->lastenv[6]) / 2.; lope = (up->lastint[2] - up->lastint[6]) / 2.; if (lope > up->intmax) up->intmax = lope; @@ -705,91 +693,130 @@ irig_base( * when three correct frames have been found. */ up->pulse = (up->pulse + 1) % 10; - if (up->pulse == 1) - up->envmax = env; - else if (up->pulse == 9) - up->envmin = env; - up->dcycles <<= 1; - if (env >= (up->envmax + up->envmin) / 2.) - up->dcycles |= 1; up->cycles <<= 1; if (lope >= (up->maxsignal + up->noise) / 2.) up->cycles |= 1; if ((up->cycles & 0x303c0f03) == 0x300c0300) { - l_fp ltemp; - int bitz; - - /* - * The PLL time constant starts out small, in order to - * sustain a frequency tolerance of 250 PPM. It - * gradually increases as the loop settles down. Note - * that small wiggles are not believed, unless they - * persist for lots of samples. - */ - if (up->pulse != 9) + if (up->pulse != 0) up->errflg |= IRIG_ERR_SYNCH; - up->pulse = 9; - up->exing = -up->yxing; - if (fabs(up->envxing - up->envphase) <= 1) { - up->tcount++; - if (up->tcount > 50 * up->tc) { - up->tc++; - if (up->tc > MAXTC) - up->tc = MAXTC; - up->tcount = 0; - up->envxing = up->envphase; - } else { - up->exing -= up->envxing - up->envphase; - } - } else { + up->pulse = 0; + } + + /* + * Assemble the baud and max/min to get the slice level for the + * next baud. The slice level is based on the maximum over the + * first two bits and the minimum over the last two bits, with + * the slice level halfway between the maximum and minimum. + */ + env = (up->lastenv[2] - up->lastenv[6]) / 2.; + up->dcycles <<= 1; + if (env >= up->slice) + up->dcycles |= 1; + switch(up->pulse) { + + case 0: + irig_baud(peer, up->dcycles); + if (env < up->envmin) + up->envmin = env; + up->slice = (up->envmax + up->envmin) / 2; + up->envmin = 1e6; up->envmax = -1e6; + break; + + case 1: + up->envmax = env; + break; + + case 2: + if (env > up->envmax) + up->envmax = env; + break; + + case 9: + up->envmin = env; + break; + } +} + +/* + * irig_baud - update the PLL and decode the pulse-width signal + */ +static void +irig_baud( + struct peer *peer, /* peer structure pointer */ + int bits /* decoded bits */ + ) +{ + struct refclockproc *pp; + struct irigunit *up; + double dtemp; + l_fp ltemp; + + pp = peer->procptr; + up = pp->unitptr; + + /* + * The PLL time constant starts out small, in order to + * sustain a frequency tolerance of 250 PPM. It + * gradually increases as the loop settles down. Note + * that small wiggles are not believed, unless they + * persist for lots of samples. + */ + up->exing = -up->yxing; + if (abs(up->envxing - up->envphase) <= 1) { + up->tcount++; + if (up->tcount > 20 * up->tc) { + up->tc++; + if (up->tc > MAXTC) + up->tc = MAXTC; up->tcount = 0; up->envxing = up->envphase; + } else { + up->exing -= up->envxing - up->envphase; } + } else { + up->tcount = 0; + up->envxing = up->envphase; + } - /* - * Determine a reference timestamp, accounting for the - * codec delay and filter delay. Note the timestamp is - * for the previous frame, so we have to backtrack for - * this plus the delay since the last carrier positive - * zero crossing. - */ - dtemp = up->decim * ((up->exing + BAUD) / SECOND + 1.) + - up->fdelay; - DTOLFP(dtemp, <emp); - pp->lastrec = up->timestamp; - L_SUB(&pp->lastrec, <emp); + /* + * Strike the baud timestamp as the positive zero crossing of + * the first bit, accounting for the codec delay and filter + * delay. + */ + up->prvstamp = up->chrstamp; + dtemp = up->decim * (up->exing / SECOND) + up->fdelay; + DTOLFP(dtemp, <emp); + up->chrstamp = up->timestamp; + L_SUB(&up->chrstamp, <emp); - /* - * The data bits are collected in ten-bit frames. The - * first two and last two bits are determined by frame - * sync and ignored here; the resulting patterns - * represent zero (0-1 bits), one (2-4 bits) and - * position identifier (5-6 bits). The remaining - * patterns represent errors and are treated as zeros. - */ - bitz = up->dcycles & 0xfc; - switch(bitz) { - - case 0x00: - case 0x80: - irig_decode(peer, BIT0); - break; - - case 0xc0: - case 0xe0: - case 0xf0: - irig_decode(peer, BIT1); - break; - - case 0xf8: - case 0xfc: - irig_decode(peer, BITP); - break; - - default: - irig_decode(peer, 0); - up->errflg |= IRIG_ERR_DECODE; - } + /* + * The data bits are collected in ten-bit bauds. The first two + * bits are not used. The resulting patterns represent runs of + * 0-1 bits (0), 2-4 bits (1) and 5-7 bits (PI). The remaining + * 8-bit run represents a soft error and is treated as 0. + */ + switch (up->dcycles & 0xff) { + + case 0x00: /* 0-1 bits (0) */ + case 0x80: + irig_decode(peer, BIT0); + break; + + case 0xc0: /* 2-4 bits (1) */ + case 0xe0: + case 0xf0: + irig_decode(peer, BIT1); + break; + + case 0xf8: /* (5-7 bits (PI) */ + case 0xfc: + case 0xfe: + irig_decode(peer, BITP); + break; + + default: /* 8 bits (error) */ + irig_decode(peer, BIT0); + up->errflg |= IRIG_ERR_DECODE; } } @@ -797,11 +824,10 @@ irig_base( /* * irig_decode - decode the data * - * This routine assembles bits into digits, digits into subfields and - * subfields into the timecode field. Bits can have values of zero, one - * or position identifier. There are four bits per digit, two digits per - * subfield and ten subfields per field. The last bit in every subfield - * and the first bit in the first subfield are position identifiers. + * This routine assembles bauds into digits, digits into frames and + * frames into the timecode fields. Bits can have values of zero, one + * or position identifier. There are four bits per digit, ten digits per + * frame and ten frames per second. */ static void irig_decode( @@ -811,115 +837,59 @@ irig_decode( { struct refclockproc *pp; struct irigunit *up; -#ifdef IRIG_SUCKS - int i; -#endif /* IRIG_SUCKS */ /* * Local variables */ - char syncchar; /* sync character (Spectracom) */ - char sbs[6]; /* binary seconds since 0h */ - char spare[2]; /* mulligan digits */ + int syncdig; /* sync digit (Spectracom) */ + char sbs[6 + 1]; /* binary seconds since 0h */ + char spare[2 + 1]; /* mulligan digits */ + int temp; - pp = peer->procptr; - up = (struct irigunit *)pp->unitptr; + syncdig = 0; + pp = peer->procptr; + up = pp->unitptr; /* - * Assemble subfield bits. + * Assemble frame bits. */ - up->bits <<= 1; + up->bits >>= 1; if (bit == BIT1) { - up->bits |= 1; + up->bits |= 0x200; } else if (bit == BITP && up->lastbit == BITP) { /* - * Frame sync - two adjacent position identifiers. - * Monitor the reference timestamp and wiggle the - * clock, but only if no errors have occurred. + * Frame sync - two adjacent position identifiers, which + * mark the beginning of the second. The reference time + * is the beginning of the second position identifier, + * so copy the character timestamp to the reference + * timestamp. */ - up->bitcnt = 1; - up->fieldcnt = 0; - up->lastbit = 0; - if (up->errflg == 0) { -#ifdef IRIG_SUCKS - l_fp ltemp; - - /* - * You really don't wanna know what comes down - * here. Leave it to say Solaris 2.8 broke the - * nice clean audio stream, apparently affected - * by a 5-ms sawtooth jitter. Sundown on - * Solaris. This leaves a little twilight. - * - * The scheme involves differentiation, forward - * learning and integration. The sawtooth has a - * period of 11 seconds. The timestamp - * differences are integrated and subtracted - * from the signal. - */ - ltemp = pp->lastrec; - L_SUB(<emp, &pp->lastref); - if (ltemp.l_f < 0) - ltemp.l_i = -1; - else - ltemp.l_i = 0; - pp->lastref = pp->lastrec; - if (!L_ISNEG(<emp)) - L_CLR(&up->wigwag); - else - L_ADD(&up->wigwag, <emp); - L_SUB(&pp->lastrec, &up->wigwag); - up->wiggle[up->wp] = ltemp; - - /* - * Bottom fisher. To understand this, you have - * to know about velocity microphones and AM - * transmitters. No further explanation is - * offered, as this is truly a black art. - */ - up->wigbot[up->wp] = pp->lastrec; - for (i = 0; i < WIGGLE; i++) { - if (i != up->wp) - up->wigbot[i].l_ui++; - L_SUB(&pp->lastrec, &up->wigbot[i]); - if (L_ISNEG(&pp->lastrec)) - L_ADD(&pp->lastrec, - &up->wigbot[i]); - else - pp->lastrec = up->wigbot[i]; - } - up->wp++; - up->wp %= WIGGLE; - up->wuggle = pp->lastrec; - refclock_process(pp); -#else /* IRIG_SUCKS */ - pp->lastref = pp->lastrec; - up->wuggle = pp->lastrec; - refclock_process(pp); -#endif /* IRIG_SUCKS */ - } - up->errflg = 0; + if (up->frmcnt != 1) + up->errflg |= IRIG_ERR_SYNCH; + up->frmcnt = 1; + up->refstamp = up->prvstamp; } - up->bitcnt = (up->bitcnt + 1) % SUBFLD; - if (up->bitcnt == 0) { + up->lastbit = bit; + if (up->frmcnt % SUBFLD == 0) { /* - * End of subfield. Encode two hexadecimal digits in - * little-endian timecode field. + * End of frame. Encode two hexadecimal digits in + * little-endian timecode field. Note frame 1 is shifted + * right one bit to account for the marker PI. */ - if (up->fieldcnt == 0) - up->bits <<= 1; - if (up->xptr < 2) - up->xptr = 2 * FIELD; - up->timecode[--up->xptr] = hexchar[(up->bits >> 5) & - 0xf]; - up->timecode[--up->xptr] = hexchar[up->bits & 0xf]; - up->fieldcnt = (up->fieldcnt + 1) % FIELD; - if (up->fieldcnt == 0) { + temp = up->bits; + if (up->frmcnt == 10) + temp >>= 1; + if (up->xptr >= 2) { + up->timecode[--up->xptr] = hexchar[temp & 0xf]; + up->timecode[--up->xptr] = hexchar[(temp >> 5) & + 0xf]; + } + if (up->frmcnt == 0) { /* - * End of field. Decode the timecode and wind + * End of second. Decode the timecode and wind * the clock. Not all IRIG generators have the * year; if so, it is nonzero after year 2000. * Not all have the hardware status bit; if so, @@ -931,40 +901,68 @@ irig_decode( * refclock_process() will reject the timecode * as invalid. */ - up->xptr = 2 * FIELD; + up->xptr = 2 * SUBFLD; if (sscanf((char *)up->timecode, - "%6s%2d%c%2s%3d%2d%2d%2d", sbs, &pp->year, - &syncchar, spare, &pp->day, &pp->hour, + "%6s%2d%1d%2s%3d%2d%2d%2d", sbs, &pp->year, + &syncdig, spare, &pp->day, &pp->hour, &pp->minute, &pp->second) != 8) pp->leap = LEAP_NOTINSYNC; else pp->leap = LEAP_NOWARNING; up->second = (up->second + up->decim) % 60; - if (pp->year > 0) - pp->year += 2000; + + /* + * Raise an alarm if the day field is zero, + * which happens when signature control is + * enabled and the device has lost + * synchronization. Raise an alarm if the year + * field is nonzero and the sync indicator is + * zero, which happens when a Spectracom radio + * has lost synchronization. Raise an alarm if + * the expected second does not agree with the + * decoded second, which happens with a garbled + * IRIG signal. We are very particular. + */ + if (pp->day == 0 || (pp->year != 0 && syncdig == + 0)) + up->errflg |= IRIG_ERR_SIGERR; if (pp->second != up->second) up->errflg |= IRIG_ERR_CHECK; up->second = pp->second; - sprintf(pp->a_lastcode, - "%02x %c %2d %3d %02d:%02d:%02d %4.0f %3d %6.3f %2d %6.1f %6.1f %s", - up->errflg, syncchar, pp->year, pp->day, + + /* + * Wind the clock only if there are no errors + * and the time constant has reached the + * maximum. + */ + if (up->errflg == 0 && up->tc == MAXTC) { + pp->lastref = pp->lastrec; + pp->lastrec = up->refstamp; + if (!refclock_process(pp)) + refclock_report(peer, + CEVNT_BADTIME); + } + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%02x %02d %03d %02d:%02d:%02d %4.0f %3d %6.3f %2d %6.2f %6.1f %s", + up->errflg, pp->year, pp->day, pp->hour, pp->minute, pp->second, up->maxsignal, up->gain, up->modndx, up->tc, up->exing * 1e6 / SECOND, up->freq * - 1e6 / SECOND, ulfptoa(&up->wuggle, 6)); + 1e6 / SECOND, ulfptoa(&pp->lastrec, 6)); pp->lencode = strlen(pp->a_lastcode); + up->errflg = 0; if (pp->sloppyclockflag & CLK_FLAG4) { record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG if (debug) - printf("irig: %s\n", + printf("irig %s\n", pp->a_lastcode); #endif /* DEBUG */ } } } - up->lastbit = bit; + up->frmcnt = (up->frmcnt + 1) % FIELD; } @@ -973,8 +971,7 @@ irig_decode( * * This routine sweeps up the timecode updates since the last poll. For * IRIG-B there should be at least 60 updates; for IRIG-E there should - * be at least 6. If nothing is heard, a timeout event is declared and - * any orphaned timecode updates are sent to foster care. + * be at least 6. If nothing is heard, a timeout event is declared. */ static void irig_poll( @@ -983,21 +980,20 @@ irig_poll( ) { struct refclockproc *pp; - struct irigunit *up; pp = peer->procptr; - up = (struct irigunit *)pp->unitptr; if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; - } else { - refclock_receive(peer); + } + refclock_receive(peer); + if (!(pp->sloppyclockflag & CLK_FLAG4)) { record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG if (debug) - printf("irig: %s\n", pp->a_lastcode); + printf("irig %s\n", pp->a_lastcode); #endif /* DEBUG */ } pp->polls++; @@ -1008,11 +1004,10 @@ irig_poll( /* * irig_gain - adjust codec gain * - * This routine is called once each second. If the signal envelope - * amplitude is too low, the codec gain is bumped up by four units; if - * too high, it is bumped down. The decoder is relatively insensitive to - * amplitude, so this crudity works just fine. The input port is set and - * the error flag is cleared, mostly to be ornery. + * This routine is called at the end of each second. It uses the AGC to + * bradket the maximum signal level between MINAMP and MAXAMP to avoid + * hunting. The routine also jiggles the input port and selectively + * mutes the monitor. */ static void irig_gain( @@ -1023,26 +1018,26 @@ irig_gain( struct irigunit *up; pp = peer->procptr; - up = (struct irigunit *)pp->unitptr; + up = pp->unitptr; /* * Apparently, the codec uses only the high order bits of the * gain control field. Thus, it may take awhile for changes to * wiggle the hardware bits. */ - if (up->clipcnt == 0) { + if (up->maxsignal < MINAMP) { up->gain += 4; if (up->gain > MAXGAIN) up->gain = MAXGAIN; - } else if (up->clipcnt > MAXCLP) { + } else if (up->maxsignal > MAXAMP) { up->gain -= 4; if (up->gain < 0) up->gain = 0; } audio_gain(up->gain, up->mongain, up->port); - up->clipcnt = 0; } + #else int refclock_irig_bs; #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_jjy.c b/contrib/ntp/ntpd/refclock_jjy.c index d1707ced0..fef829ca0 100644 --- a/contrib/ntp/ntpd/refclock_jjy.c +++ b/contrib/ntp/ntpd/refclock_jjy.c @@ -3,80 +3,109 @@ */ /**********************************************************************/ -/* */ -/* Copyright (C) 2001-2004, Takao Abe. All rights reserved. */ -/* */ +/* */ +/* Copyright (C) 2001-2015, Takao Abe. All rights reserved. */ +/* */ /* Permission to use, copy, modify, and distribute this software */ -/* and its documentation for any purpose is hereby granted */ +/* and its documentation for any purpose is hereby granted */ /* without fee, provided that the following conditions are met: */ -/* */ +/* */ /* One retains the entire copyright notice properly, and both the */ /* copyright notice and this license. in the documentation and/or */ -/* other materials provided with the distribution. */ -/* */ +/* other materials provided with the distribution. */ +/* */ /* This software and the name of the author must not be used to */ /* endorse or promote products derived from this software without */ -/* prior written permission. */ -/* */ +/* prior written permission. */ +/* */ /* THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESSED OR IMPLIED */ -/* WARRANTIES OF ANY KIND, INCLUDING, BUT NOT LIMITED TO, THE */ -/* IMPLIED WARRANTIES OF MERCHANTABLILITY AND FITNESS FOR A */ -/* PARTICULAR PURPOSE. */ +/* WARRANTIES OF ANY KIND, INCLUDING, BUT NOT LIMITED TO, THE */ +/* IMPLIED WARRANTIES OF MERCHANTABLILITY AND FITNESS FOR A */ +/* PARTICULAR PURPOSE. */ /* IN NO EVENT SHALL THE AUTHOR TAKAO ABE BE LIABLE FOR ANY DIRECT, */ /* INDIRECT, GENERAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */ -/* ( INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ +/* ( INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */ /* GOODS OR SERVICES; LOSS OF USE, DATA OR PROFITS; OR BUSINESS */ /* INTERRUPTION ) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, */ -/* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ( INCLUDING */ +/* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT ( INCLUDING */ /* NEGLIGENCE OR OTHERWISE ) ARISING IN ANY WAY OUT OF THE USE OF */ /* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -/* */ +/* */ /* This driver is developed in my private time, and is opened as */ -/* voluntary contributions for the NTP. */ +/* voluntary contributions for the NTP. */ /* The manufacturer of the JJY receiver has not participated in */ -/* a development of this driver. */ +/* a development of this driver. */ /* The manufacturer does not warrant anything about this driver, */ -/* and is not liable for anything about this driver. */ -/* */ +/* and is not liable for anything about this driver. */ +/* */ /**********************************************************************/ -/* */ -/* Author Takao Abe */ -/* Email abetakao@bea.hi-ho.ne.jp */ -/* Homepage http://www.bea.hi-ho.ne.jp/abetakao/ */ -/* */ +/* */ +/* Author Takao Abe */ +/* Email takao_abe@xurb.jp */ +/* Homepage http://www.bea.hi-ho.ne.jp/abetakao/ */ +/* */ +/* The email address abetakao@bea.hi-ho.ne.jp is never read */ +/* from 2010, because a few filtering rule are provided by the */ +/* "hi-ho.ne.jp", and lots of spam mail are reached. */ +/* New email address for supporting the refclock_jjy is */ +/* takao_abe@xurb.jp */ +/* */ /**********************************************************************/ -/* */ -/* History */ -/* */ -/* 2001/07/15 */ -/* [New] Support the Tristate Ltd. JJY receiver */ -/* */ -/* 2001/08/04 */ -/* [Change] Log to clockstats even if bad reply */ -/* [Fix] PRECISION = (-3) (about 100 ms) */ -/* [Add] Support the C-DEX Co.Ltd. JJY receiver */ -/* */ -/* 2001/12/04 */ +/* */ +/* History */ +/* */ +/* 2001/07/15 */ +/* [New] Support the Tristate Ltd. JJY receiver */ +/* */ +/* 2001/08/04 */ +/* [Change] Log to clockstats even if bad reply */ +/* [Fix] PRECISION = (-3) (about 100 ms) */ +/* [Add] Support the C-DEX Co.Ltd. JJY receiver */ +/* */ +/* 2001/12/04 */ /* [Fix] C-DEX JST2000 ( fukusima@goto.info.waseda.ac.jp ) */ -/* */ -/* 2002/07/12 */ -/* [Fix] Portability for FreeBSD ( patched by the user ) */ -/* */ -/* 2004/10/31 */ +/* */ +/* 2002/07/12 */ +/* [Fix] Portability for FreeBSD ( patched by the user ) */ +/* */ +/* 2004/10/31 */ /* [Change] Command send timing for the Tristate Ltd. JJY receiver */ -/* JJY-01 ( Firmware version 2.01 ) */ -/* Thanks to Andy Taki for testing under FreeBSD */ -/* */ -/* 2004/11/28 */ -/* [Add] Support the Echo Keisokuki LT-2000 receiver */ -/* */ -/* 2006/11/04 */ -/* [Fix] C-DEX JST2000 */ -/* Thanks to Hideo Kuramatsu for the patch */ -/* */ -/* 2009/04/05 */ -/* [Add] Support the CITIZEN T.I.C JJY-200 receiver */ -/* */ +/* JJY-01 ( Firmware version 2.01 ) */ +/* Thanks to Andy Taki for testing under FreeBSD */ +/* */ +/* 2004/11/28 */ +/* [Add] Support the Echo Keisokuki LT-2000 receiver */ +/* */ +/* 2006/11/04 */ +/* [Fix] C-DEX JST2000 */ +/* Thanks to Hideo Kuramatsu for the patch */ +/* */ +/* 2009/04/05 */ +/* [Add] Support the CITIZEN T.I.C JJY-200 receiver */ +/* */ +/* 2010/11/20 */ +/* [Change] Bug 1618 ( Harmless ) */ +/* Code clean up ( Remove unreachable codes ) in */ +/* jjy_start() */ +/* [Change] Change clockstats format of the Tristate JJY01/02 */ +/* Issues more command to get the status of the receiver */ +/* when "fudge 127.127.40.X flag1 1" is specified */ +/* ( DATE,STIM -> DCST,STUS,DATE,STIM ) */ +/* */ +/* 2011/04/30 */ +/* [Add] Support the Tristate Ltd. TS-GPSclock-01 */ +/* */ +/* 2015/03/29 */ +/* [Add] Support the Telephone JJY */ +/* [Change] Split the start up routine into each JJY receivers. */ +/* Change raw data internal bufferring process */ +/* Change over midnight handling of TS-JJY01 and TS-GPS01 */ +/* to put DATE command between before and after TIME's. */ +/* Unify the writing clockstats of all JJY receivers. */ +/* */ +/* 2015/05/15 */ +/* [Add] Support the SEIKO TIME SYSTEMS TDC-300 */ +/* */ /**********************************************************************/ #ifdef HAVE_CONFIG_H @@ -98,133 +127,299 @@ #include "ntp_calendar.h" #include "ntp_stdlib.h" -/**********************************************************************/ -/* */ -/* The Tristate Ltd. JJY receiver JJY01 */ -/* */ -/* Command Response Remarks */ -/* ------------ ---------------------- --------------------- */ -/* date YYYY/MM/DD XXX */ -/* time HH:MM:SS */ -/* stim HH:MM:SS Reply at just second */ -/* */ -/* During synchronization after a receiver is turned on, */ -/* It replies the past time from 2000/01/01 00:00:00. */ -/* The function "refclock_process" checks the time and tells */ -/* as an insanity time. */ -/* */ -/**********************************************************************/ -/* */ -/* The C-DEX Co. Ltd. JJY receiver JST2000 */ -/* */ -/* Command Response Remarks */ -/* ------------ ---------------------- --------------------- */ -/* 1J JYYMMDD HHMMSSS */ -/* */ -/**********************************************************************/ -/* */ -/* The Echo Keisokuki Co. Ltd. JJY receiver LT2000 */ -/* */ -/* Command Response Remarks */ -/* ------------ ---------------------- --------------------- */ -/* # Mode 1 (Request&Send) */ -/* T YYMMDDWHHMMSS */ -/* C Mode 2 (Continuous) */ -/* YYMMDDWHHMMSS */ -/* Second signal */ -/* */ -/**********************************************************************/ -/* */ -/* The CITIZEN T.I.C CO., LTD. JJY receiver JJY200 */ -/* */ -/* Command Response Remarks */ -/* ------------ ---------------------- --------------------- */ -/* 'XX YY/MM/DD W HH:MM:SS */ -/* XX: OK|NG|ER */ -/* W: 0(Monday)-6(Sunday) */ -/* */ /**********************************************************************/ /* * Interface definitions */ -#define DEVICE "/dev/jjy%d" /* device name and unit */ -#define SPEED232 B9600 /* uart speed (9600 baud) */ -#define SPEED232_TRISTATE_JJY01 B9600 /* UART speed (9600 baud) */ -#define SPEED232_CDEX_JST2000 B9600 /* UART speed (9600 baud) */ -#define SPEED232_ECHOKEISOKUKI_LT2000 B9600 /* UART speed (9600 baud) */ -#define SPEED232_CITIZENTIC_JJY200 B4800 /* UART speed (4800 baud) */ -#define REFID "JJY" /* reference ID */ +#define DEVICE "/dev/jjy%d" /* device name and unit */ +#define SPEED232_TRISTATE_JJY01 B9600 /* UART speed (9600 baud) */ +#define SPEED232_CDEX_JST2000 B9600 /* UART speed (9600 baud) */ +#define SPEED232_ECHOKEISOKUKI_LT2000 B9600 /* UART speed (9600 baud) */ +#define SPEED232_CITIZENTIC_JJY200 B4800 /* UART speed (4800 baud) */ +#define SPEED232_TRISTATE_GPSCLOCK01 B38400 /* USB speed (38400 baud) */ +#define SPEED232_SEIKO_TIMESYS_TDC_300 B2400 /* UART speed (2400 baud) */ +#define SPEED232_TELEPHONE B2400 /* UART speed (4800 baud) */ +#define REFID "JJY" /* reference ID */ #define DESCRIPTION "JJY Receiver" -#define PRECISION (-3) /* precision assumed (about 100 ms) */ +#define PRECISION (-3) /* precision assumed (about 100 ms) */ /* * JJY unit control structure */ + +struct jjyRawDataBreak { + char *pString ; + int iLength ; +} ; + +#define MAX_TIMESTAMP 6 +#define MAX_RAWBUF 100 +#define MAX_LOOPBACK 5 + struct jjyunit { - char unittype ; /* UNITTYPE_XXXXXXXXXX */ - short operationmode ; /* Echo Keisokuki LT-2000 : 1 or 2 */ - short version ; - short linediscipline ; /* LDISC_CLK or LDISC_RAW */ - char bPollFlag ; /* Set by jjy_pool and Reset by jjy_receive */ - int linecount ; - int lineerror ; +/* Set up by the function "jjy_start_xxxxxxxx" */ + char unittype ; /* UNITTYPE_XXXXXXXXXX */ + short operationmode ; /* Echo Keisokuki LT-2000 */ + int linespeed ; /* SPEED232_XXXXXXXXXX */ + short linediscipline ; /* LDISC_CLK or LDISC_RAW */ +/* Receiving data */ + char bInitError ; /* Set by jjy_start if any error during initialization */ + short iProcessState ; /* JJY_PROCESS_STATE_XXXXXX */ + char bReceiveFlag ; /* Set and reset by jjy_receive */ + char bLineError ; /* Reset by jjy_poll / Set by jjy_receive_xxxxxxxx*/ + short iCommandSeq ; /* 0:Idle Non-Zero:Issued */ + short iReceiveSeq ; + int iLineCount ; int year, month, day, hour, minute, second, msecond ; + int leapsecond ; + int iTimestampCount ; /* TS-JJY01, TS-GPS01, Telephone-JJY */ + int iTimestamp [ MAX_TIMESTAMP ] ; /* Serial second ( 0 - 86399 ) */ /* LDISC_RAW only */ -#define MAX_LINECOUNT 8 -#define MAX_RAWBUF 64 - int lineexpect ; - int charexpect [ MAX_LINECOUNT ] ; - int charcount ; - char rawbuf [ MAX_RAWBUF ] ; + char sRawBuf [ MAX_RAWBUF ] ; + int iRawBufLen ; + struct jjyRawDataBreak *pRawBreak ; + char bWaitBreakString ; + char sLineBuf [ MAX_RAWBUF ] ; + int iLineBufLen ; + char sTextBuf [ MAX_RAWBUF ] ; + int iTextBufLen ; + char bSkipCntrlCharOnly ; +/* Telephone JJY auto measurement of the loopback delay */ + char bLoopbackMode ; + short iLoopbackCount ; + struct timeval sendTime[MAX_LOOPBACK], delayTime[MAX_LOOPBACK] ; + char bLoopbackTimeout[MAX_LOOPBACK] ; + short iLoopbackValidCount ; +/* Telephone JJY timer */ + short iTeljjySilentTimer ; + short iTeljjyStateTimer ; +/* Telephone JJY control finite state machine */ + short iClockState ; + short iClockEvent ; + short iClockCommandSeq ; +/* Modem timer */ + short iModemSilentCount ; + short iModemSilentTimer ; + short iModemStateTimer ; +/* Modem control finite state machine */ + short iModemState ; + short iModemEvent ; + short iModemCommandSeq ; }; -#define UNITTYPE_TRISTATE_JJY01 1 -#define UNITTYPE_CDEX_JST2000 2 +#define UNITTYPE_TRISTATE_JJY01 1 +#define UNITTYPE_CDEX_JST2000 2 #define UNITTYPE_ECHOKEISOKUKI_LT2000 3 #define UNITTYPE_CITIZENTIC_JJY200 4 +#define UNITTYPE_TRISTATE_GPSCLOCK01 5 +#define UNITTYPE_SEIKO_TIMESYS_TDC_300 6 +#define UNITTYPE_TELEPHONE 100 + +#define JJY_PROCESS_STATE_IDLE 0 +#define JJY_PROCESS_STATE_POLL 1 +#define JJY_PROCESS_STATE_RECEIVE 2 +#define JJY_PROCESS_STATE_DONE 3 +#define JJY_PROCESS_STATE_ERROR 4 + +/**********************************************************************/ /* + * Function calling structure + * + * jjy_start + * |-- jjy_start_tristate_jjy01 + * |-- jjy_start_cdex_jst2000 + * |-- jjy_start_echokeisokuki_lt2000 + * |-- jjy_start_citizentic_jjy200 + * |-- jjy_start_tristate_gpsclock01 + * |-- jjy_start_seiko_tsys_tdc_300 + * |-- jjy_start_telephone + * + * jjy_shutdown + * + * jjy_poll + * |-- jjy_poll_tristate_jjy01 + * |-- jjy_poll_cdex_jst2000 + * |-- jjy_poll_echokeisokuki_lt2000 + * |-- jjy_poll_citizentic_jjy200 + * |-- jjy_poll_tristate_gpsclock01 + * |-- jjy_poll_seiko_tsys_tdc_300 + * |-- jjy_poll_telephone + * |-- teljjy_control + * |-- teljjy_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * |-- modem_connect + * |-- modem_control + * |-- modem_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * + * jjy_receive + * | + * |-- jjy_receive_tristate_jjy01 + * | |-- jjy_synctime + * |-- jjy_receive_cdex_jst2000 + * | |-- jjy_synctime + * |-- jjy_receive_echokeisokuki_lt2000 + * | |-- jjy_synctime + * |-- jjy_receive_citizentic_jjy200 + * | |-- jjy_synctime + * |-- jjy_receive_tristate_gpsclock01 + * | |-- jjy_synctime + * |-- jjy_receive_seiko_tsys_tdc_300 + * | |-- jjy_synctime + * |-- jjy_receive_telephone + * |-- modem_receive + * | |-- modem_control + * | |-- modem_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * |-- teljjy_control + * |-- teljjy_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * |-- jjy_synctime + * |-- modem_disconnect + * |-- modem_control + * |-- modem_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * + * jjy_timer + * |-- jjy_timer_telephone + * |-- modem_timer + * | |-- modem_control + * | |-- modem_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * |-- teljjy_control + * |-- teljjy_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * |-- modem_disconnect + * |-- modem_control + * |-- modem_XXXX_YYYY ( XXXX_YYYY is an event handler name. ) + * * Function prototypes */ -static int jjy_start P((int, struct peer *)); -static void jjy_shutdown P((int, struct peer *)); -static void jjy_poll P((int, struct peer *)); -static void jjy_poll_tristate_jjy01 P((int, struct peer *)); -static void jjy_poll_cdex_jst2000 P((int, struct peer *)); -static void jjy_poll_echokeisokuki_lt2000 P((int, struct peer *)); -static void jjy_poll_citizentic_jjy200 P((int, struct peer *)); -static void jjy_receive P((struct recvbuf *)); -static int jjy_receive_tristate_jjy01 P((struct recvbuf *)); -static int jjy_receive_cdex_jst2000 P((struct recvbuf *)); -static int jjy_receive_echokeisokuki_lt2000 P((struct recvbuf *)); -static int jjy_receive_citizentic_jjy200 P((struct recvbuf *)); + +static int jjy_start (int, struct peer *); +static int jjy_start_tristate_jjy01 (int, struct peer *, struct jjyunit *); +static int jjy_start_cdex_jst2000 (int, struct peer *, struct jjyunit *); +static int jjy_start_echokeisokuki_lt2000 (int, struct peer *, struct jjyunit *); +static int jjy_start_citizentic_jjy200 (int, struct peer *, struct jjyunit *); +static int jjy_start_tristate_gpsclock01 (int, struct peer *, struct jjyunit *); +static int jjy_start_seiko_tsys_tdc_300 (int, struct peer *, struct jjyunit *); +static int jjy_start_telephone (int, struct peer *, struct jjyunit *); + +static void jjy_shutdown (int, struct peer *); + +static void jjy_poll (int, struct peer *); +static void jjy_poll_tristate_jjy01 (int, struct peer *); +static void jjy_poll_cdex_jst2000 (int, struct peer *); +static void jjy_poll_echokeisokuki_lt2000 (int, struct peer *); +static void jjy_poll_citizentic_jjy200 (int, struct peer *); +static void jjy_poll_tristate_gpsclock01 (int, struct peer *); +static void jjy_poll_seiko_tsys_tdc_300 (int, struct peer *); +static void jjy_poll_telephone (int, struct peer *); + +static void jjy_receive (struct recvbuf *); +static int jjy_receive_tristate_jjy01 (struct recvbuf *); +static int jjy_receive_cdex_jst2000 (struct recvbuf *); +static int jjy_receive_echokeisokuki_lt2000 (struct recvbuf *); +static int jjy_receive_citizentic_jjy200 (struct recvbuf *); +static int jjy_receive_tristate_gpsclock01 (struct recvbuf *); +static int jjy_receive_seiko_tsys_tdc_300 (struct recvbuf *); +static int jjy_receive_telephone (struct recvbuf *); + +static void jjy_timer (int, struct peer *); +static void jjy_timer_telephone (int, struct peer *); + +static void jjy_synctime ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static void jjy_write_clockstats ( struct peer *, int, const char* ) ; + +static int getRawDataBreakPosition ( struct jjyunit *, int ) ; + +static short getModemState ( struct jjyunit * ) ; +static int isModemStateConnect ( short ) ; +static int isModemStateDisconnect ( short ) ; +static int isModemStateTimerOn ( struct jjyunit * ) ; +static void modem_connect ( int, struct peer * ) ; +static void modem_disconnect ( int, struct peer * ) ; +static int modem_receive ( struct recvbuf * ) ; +static void modem_timer ( int, struct peer * ); + +static void printableString ( char*, int, const char*, int ) ; /* * Transfer vector */ struct refclock refclock_jjy = { - jjy_start, /* start up driver */ - jjy_shutdown, /* shutdown driver */ - jjy_poll, /* transmit poll message */ - noentry, /* not used */ - noentry, /* not used */ - noentry, /* not used */ - NOFLAGS /* not used */ + jjy_start, /* start up driver */ + jjy_shutdown, /* shutdown driver */ + jjy_poll, /* transmit poll message */ + noentry, /* not used */ + noentry, /* not used */ + noentry, /* not used */ + jjy_timer /* 1 second interval timer */ }; /* * Start up driver return code */ #define RC_START_SUCCESS 1 -#define RC_START_ERROR 0 +#define RC_START_ERROR 0 /* * Local constants definition */ -#define MAX_LOGTEXT 64 +#define MAX_LOGTEXT 100 + +#ifndef TRUE +#define TRUE (0==0) +#endif +#ifndef FALSE +#define FALSE (!TRUE) +#endif +/* Local constants definition for the return code of the jjy_receive_xxxxxxxx */ + +#define JJY_RECEIVE_DONE 0 +#define JJY_RECEIVE_SKIP 1 +#define JJY_RECEIVE_UNPROCESS 2 +#define JJY_RECEIVE_WAIT 3 +#define JJY_RECEIVE_ERROR 4 + +/* Local constants definition for the 2nd parameter of the jjy_write_clockstats */ + +#define JJY_CLOCKSTATS_MARK_NONE 0 +#define JJY_CLOCKSTATS_MARK_JJY 1 +#define JJY_CLOCKSTATS_MARK_SEND 2 +#define JJY_CLOCKSTATS_MARK_RECEIVE 3 +#define JJY_CLOCKSTATS_MARK_INFORMATION 4 +#define JJY_CLOCKSTATS_MARK_ATTENTION 5 +#define JJY_CLOCKSTATS_MARK_WARNING 6 +#define JJY_CLOCKSTATS_MARK_ERROR 7 + +/* Local constants definition for the clockstats messages */ + +#define JJY_CLOCKSTATS_MESSAGE_ECHOBACK "* Echoback" +#define JJY_CLOCKSTATS_MESSAGE_IGNORE_REPLY "* Ignore replay : [%s]" +#define JJY_CLOCKSTATS_MESSAGE_OVER_MIDNIGHT_2 "* Over midnight : timestamp=%d, %d" +#define JJY_CLOCKSTATS_MESSAGE_OVER_MIDNIGHT_3 "* Over midnight : timestamp=%d, %d, %d" +#define JJY_CLOCKSTATS_MESSAGE_TIMESTAMP_UNSURE "* Unsure timestamp : %s" +#define JJY_CLOCKSTATS_MESSAGE_LOOPBACK_DELAY "* Loopback delay : %d.%03d mSec." +#define JJY_CLOCKSTATS_MESSAGE_DELAY_ADJUST "* Delay adjustment : %d mSec. ( valid=%hd/%d )" +#define JJY_CLOCKSTATS_MESSAGE_DELAY_UNADJUST "* Delay adjustment : None ( valid=%hd/%d )" + +#define JJY_CLOCKSTATS_MESSAGE_UNEXPECTED_REPLY "# Unexpected reply : [%s]" +#define JJY_CLOCKSTATS_MESSAGE_INVALID_LENGTH "# Invalid length : length=%d" +#define JJY_CLOCKSTATS_MESSAGE_TOO_MANY_REPLY "# Too many reply : count=%d" +#define JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY "# Invalid reply : [%s]" +#define JJY_CLOCKSTATS_MESSAGE_SLOW_REPLY_2 "# Slow reply : timestamp=%d, %d" +#define JJY_CLOCKSTATS_MESSAGE_SLOW_REPLY_3 "# Slow reply : timestamp=%d, %d, %d" +#define JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATE "# Invalid date : rc=%d year=%d month=%d day=%d" +#define JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_TIME "# Invalid time : rc=%d hour=%d minute=%d second=%d" +#define JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATETIME "# Invalid time : rc=%d year=%d month=%d day=%d hour=%d minute=%d second=%d" +#define JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_LEAP "# Invalid leap : leapsecond=[%s]" +#define JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_STATUS "# Invalid status : status=[%s]" + +/* Debug print macro */ + +#ifdef DEBUG +#define DEBUG_PRINTF_JJY_RECEIVE(sFunc,iLen) { if ( debug ) { printf ( "refclock_jjy.c : %s : iProcessState=%d bLineError=%d iCommandSeq=%d iLineCount=%d iTimestampCount=%d iLen=%d\n", sFunc, up->iProcessState, up->bLineError, up->iCommandSeq, up->iLineCount, up->iTimestampCount, iLen ) ; } } +#else +#define DEBUG_PRINTF_JJY_RECEIVE(sFunc,iLen) +#endif /**************************************************************************************************/ /* jjy_start - open the devices and initialize data for processing */ @@ -233,145 +428,123 @@ static int jjy_start ( int unit, struct peer *peer ) { - struct jjyunit *up ; - struct refclockproc *pp ; + struct refclockproc *pp ; + struct jjyunit *up ; + int rc ; int fd ; - char *pDeviceName ; - short iDiscipline ; - int iSpeed232 ; + char sDeviceName [ sizeof(DEVICE) + 10 ], sLog [ 60 ] ; #ifdef DEBUG if ( debug ) { - printf ( "jjy_start (refclock_jjy.c) : %s mode=%d ", ntoa(&peer->srcadr), peer->ttl ) ; - printf ( DEVICE, unit ) ; - printf ( "\n" ) ; + printf( "refclock_jjy.c : jjy_start : %s mode=%d dev=%s unit=%d\n", + ntoa(&peer->srcadr), peer->ttl, DEVICE, unit ) ; } #endif - /* - * Open serial port - */ - if ( ! ( pDeviceName = (char*) emalloc ( strlen(DEVICE) + 10 ) ) ) { - return RC_START_ERROR ; - } - sprintf ( pDeviceName, DEVICE, unit ) ; - /* - * peer->ttl is a mode number specified by "127.127.40.X mode N" in the ntp.conf - */ - switch ( peer->ttl ) { - case 0 : - case 1 : - iDiscipline = LDISC_CLK ; - iSpeed232 = SPEED232_TRISTATE_JJY01 ; - break ; - case 2 : - iDiscipline = LDISC_RAW ; - iSpeed232 = SPEED232_CDEX_JST2000 ; - break ; - case 3 : - iDiscipline = LDISC_CLK ; - iSpeed232 = SPEED232_ECHOKEISOKUKI_LT2000 ; - break ; - case 4 : - iDiscipline = LDISC_CLK ; - iSpeed232 = SPEED232_CITIZENTIC_JJY200 ; - break ; - default : - msyslog ( LOG_ERR, "JJY receiver [ %s mode %d ] : Unsupported mode", - ntoa(&peer->srcadr), peer->ttl ) ; - free ( (void*) pDeviceName ) ; + /* Allocate memory for the unit structure */ + up = emalloc( sizeof(*up) ) ; + if ( up == NULL ) { + msyslog ( LOG_ERR, "refclock_jjy.c : jjy_start : emalloc" ) ; return RC_START_ERROR ; } + memset ( up, 0, sizeof(*up) ) ; - if ( ! ( fd = refclock_open ( pDeviceName, iSpeed232, iDiscipline ) ) ) { - free ( (void*) pDeviceName ) ; - return RC_START_ERROR ; - } - free ( (void*) pDeviceName ) ; + up->bInitError = FALSE ; + up->iProcessState = JJY_PROCESS_STATE_IDLE ; + up->bReceiveFlag = FALSE ; + up->iCommandSeq = 0 ; + up->iLineCount = 0 ; + up->iTimestampCount = 0 ; + up->bWaitBreakString = FALSE ; + up->iRawBufLen = up->iLineBufLen = up->iTextBufLen = 0 ; + up->bSkipCntrlCharOnly = TRUE ; - /* - * Allocate and initialize unit structure - */ - if ( ! ( up = (struct jjyunit *) emalloc (sizeof(struct jjyunit)) ) ) { - close ( fd ) ; - return RC_START_ERROR ; - } + /* Set up the device name */ + snprintf( sDeviceName, sizeof(sDeviceName), DEVICE, unit ) ; - memset ( (char*)up, 0, sizeof(struct jjyunit) ) ; - up->linediscipline = iDiscipline ; + snprintf( sLog, sizeof(sLog), "mode=%d dev=%s", peer->ttl, sDeviceName ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, sLog ) ; /* * peer->ttl is a mode number specified by "127.127.40.X mode N" in the ntp.conf */ switch ( peer->ttl ) { case 0 : - /* - * The mode 0 is a default clock type at this time. - * But this will be change to auto-detect mode in the future. - */ case 1 : - up->unittype = UNITTYPE_TRISTATE_JJY01 ; - up->version = 100 ; - up->lineexpect = 2 ; - up->charexpect[0] = 14 ; /* YYYY/MM/DD WWW */ - up->charexpect[1] = 8 ; /* HH:MM:SS */ + rc = jjy_start_tristate_jjy01 ( unit, peer, up ) ; break ; case 2 : - up->unittype = UNITTYPE_CDEX_JST2000 ; - up->lineexpect = 1 ; - up->charexpect[0] = 15 ; /* JYYMMDD HHMMSSS */ + rc = jjy_start_cdex_jst2000 ( unit, peer, up ) ; break ; case 3 : - up->unittype = UNITTYPE_ECHOKEISOKUKI_LT2000 ; - up->operationmode = 2 ; /* Mode 2 : Continuous mode */ - up->lineexpect = 1 ; - switch ( up->operationmode ) { - case 1 : - up->charexpect[0] = 15 ; /* YYMMDDWHHMMSS */ - break ; - case 2 : - up->charexpect[0] = 17 ; /* YYMMDDWHHMMSS */ - break ; - } + rc = jjy_start_echokeisokuki_lt2000 ( unit, peer, up ) ; + break ; + case 4 : + rc = jjy_start_citizentic_jjy200 ( unit, peer, up ) ; + break ; + case 5 : + rc = jjy_start_tristate_gpsclock01 ( unit, peer, up ) ; + break ; + case 6 : + rc = jjy_start_seiko_tsys_tdc_300 ( unit, peer, up ) ; + break ; + case 100 : + rc = jjy_start_telephone ( unit, peer, up ) ; break ; - case 4 : - up->unittype = UNITTYPE_CITIZENTIC_JJY200 ; - up->lineexpect = 1 ; - up->charexpect[0] = 23 ; /* 'XX YY/MM/DD W HH:MM:SS */ - break ; default : - msyslog ( LOG_ERR, "JJY receiver [ %s mode %d ] : Unsupported mode", - ntoa(&peer->srcadr), peer->ttl ) ; - close ( fd ) ; + if ( 101 <= peer->ttl && peer->ttl <= 180 ) { + rc = jjy_start_telephone ( unit, peer, up ) ; + } else { + msyslog ( LOG_ERR, "JJY receiver [ %s mode %d ] : Unsupported mode", + ntoa(&peer->srcadr), peer->ttl ) ; + free ( (void*) up ) ; + return RC_START_ERROR ; + } + } + + if ( rc != 0 ) { + msyslog ( LOG_ERR, "JJY receiver [ %s mode %d ] : Initialize error", + ntoa(&peer->srcadr), peer->ttl ) ; + free ( (void*) up ) ; + return RC_START_ERROR ; + } + + /* Open the device */ + fd = refclock_open ( sDeviceName, up->linespeed, up->linediscipline ) ; + if ( fd <= 0 ) { free ( (void*) up ) ; return RC_START_ERROR ; } + /* + * Initialize variables + */ pp = peer->procptr ; - pp->unitptr = (caddr_t) up ; + + pp->clockdesc = DESCRIPTION ; + pp->unitptr = up ; pp->io.clock_recv = jjy_receive ; - pp->io.srcclock = (caddr_t) peer ; - pp->io.datalen = 0 ; - pp->io.fd = fd ; + pp->io.srcclock = peer ; + pp->io.datalen = 0 ; + pp->io.fd = fd ; if ( ! io_addclock(&pp->io) ) { close ( fd ) ; - free ( (void*) up ) ; + pp->io.fd = -1 ; + free ( up ) ; + pp->unitptr = NULL ; return RC_START_ERROR ; } + memcpy( (char*)&pp->refid, REFID, strlen(REFID) ) ; - /* - * Initialize miscellaneous variables - */ peer->precision = PRECISION ; - peer->burst = 1 ; - pp->clockdesc = DESCRIPTION ; - memcpy ( (char*)&pp->refid, REFID, strlen(REFID) ) ; + + snprintf( sLog, sizeof(sLog), "minpoll=%d maxpoll=%d", peer->minpoll, peer->maxpoll ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, sLog ) ; return RC_START_SUCCESS ; } - /**************************************************************************************************/ /* jjy_shutdown - shutdown the clock */ /**************************************************************************************************/ @@ -379,16 +552,24 @@ static void jjy_shutdown ( int unit, struct peer *peer ) { - struct jjyunit *up; + struct jjyunit *up; struct refclockproc *pp; + char sLog [ 60 ] ; + pp = peer->procptr ; - up = (struct jjyunit *) pp->unitptr ; - io_closeclock ( &pp->io ) ; - free ( (void*) up ) ; + up = pp->unitptr ; + if ( -1 != pp->io.fd ) { + io_closeclock ( &pp->io ) ; + } + if ( NULL != up ) { + free ( up ) ; + } -} + snprintf( sLog, sizeof(sLog), "JJY stopped. unit=%d mode=%d", unit, peer->ttl ) ; + record_clock_stats( &peer->srcadr, sLog ) ; +} /**************************************************************************************************/ /* jjy_receive - receive data from the serial interface */ @@ -396,764 +577,3881 @@ jjy_shutdown ( int unit, struct peer *peer ) static void jjy_receive ( struct recvbuf *rbufp ) { +#ifdef DEBUG + static const char *sFunctionName = "jjy_receive" ; +#endif - struct jjyunit *up ; + struct jjyunit *up ; struct refclockproc *pp ; - struct peer *peer; + struct peer *peer; l_fp tRecvTimestamp; /* arrival timestamp */ int rc ; - char sLogText [ MAX_LOGTEXT ] ; - int i, bCntrlChar ; + char *pBuf, sLogText [ MAX_LOGTEXT ] ; + int iLen, iCopyLen ; + int i, j, iReadRawBuf, iBreakPosition ; /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *) rbufp->recv_srcclock ; + peer = rbufp->recv_peer ; pp = peer->procptr ; - up = (struct jjyunit *) pp->unitptr ; + up = pp->unitptr ; /* * Get next input line */ - pp->lencode = refclock_gtlin ( rbufp, pp->a_lastcode, BMAX, &tRecvTimestamp ) ; - if ( up->linediscipline == LDISC_RAW ) { + + pp->lencode = refclock_gtraw ( rbufp, pp->a_lastcode, BMAX-1, &tRecvTimestamp ) ; + /* 3rd argument can be BMAX, but the coverity scan tool claim "Memory - corruptions (OVERRUN)" */ + /* "a_lastcode" is defined as "char a_lastcode[BMAX]" in the ntp_refclock.h */ + /* To avoid its claim, pass the value BMAX-1. */ + /* - * The reply with and may give a blank line - */ - if ( pp->lencode == 0 && up->charcount == 0 ) return ; - /* - * Copy received charaters to temporary buffer + * Append received charaters to temporary buffer */ - for ( i = 0 ; i < pp->lencode && up->charcount < MAX_RAWBUF - 2 ; i ++ , up->charcount ++ ) { - up->rawbuf[up->charcount] = pp->a_lastcode[i] ; - } - while ( up->charcount > 0 && up->rawbuf[0] < ' ' ) { - for ( i = 0 ; i < up->charcount - 1 ; i ++ ) up->rawbuf[i] = up->rawbuf[i+1] ; - up->charcount -- ; - } - bCntrlChar = 0 ; - for ( i = 0 ; i < up->charcount ; i ++ ) { - if ( up->rawbuf[i] < ' ' ) { - bCntrlChar = 1 ; - break ; - } - } - if ( pp->lencode > 0 && up->linecount < up->lineexpect ) { - if ( bCntrlChar == 0 && up->charcount < up->charexpect[up->linecount] ) return ; + for ( i = 0 ; + i < pp->lencode && up->iRawBufLen < MAX_RAWBUF - 2 ; + i ++ , up->iRawBufLen ++ ) { + up->sRawBuf[up->iRawBufLen] = pp->a_lastcode[i] ; } - up->rawbuf[up->charcount] = 0 ; + up->sRawBuf[up->iRawBufLen] = 0 ; + + } else { - /* - * The reply with gives a blank line - */ - if ( pp->lencode == 0 ) return ; + + pp->lencode = refclock_gtlin ( rbufp, pp->a_lastcode, BMAX, &tRecvTimestamp ) ; + } +#ifdef DEBUG + printf( "\nrefclock_jjy.c : %s : Len=%d ", sFunctionName, pp->lencode ) ; + for ( i = 0 ; i < pp->lencode ; i ++ ) { + if ( iscntrl( pp->a_lastcode[i] & 0x7F ) ) { + printf( "", pp->a_lastcode[i] & 0xFF ) ; + } else { + printf( "%c", pp->a_lastcode[i] ) ; + } + } + printf( "\n" ) ; +#endif + /* - * We get down to business + * The reply with gives a blank line */ - pp->lastrec = tRecvTimestamp ; + if ( pp->lencode == 0 ) return ; - up->linecount ++ ; + /* + * Receiving data is not expected + */ - if ( up->lineerror != 0 ) return ; + if ( up->iProcessState == JJY_PROCESS_STATE_IDLE + || up->iProcessState == JJY_PROCESS_STATE_DONE + || up->iProcessState == JJY_PROCESS_STATE_ERROR ) { + /* Discard received data */ + up->iRawBufLen = 0 ; +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : %s : Discard received data\n", sFunctionName ) ; + } +#endif + return ; + } - switch ( up->unittype ) { - - case UNITTYPE_TRISTATE_JJY01 : - rc = jjy_receive_tristate_jjy01 ( rbufp ) ; - break ; + /* + * We get down to business + */ - case UNITTYPE_CDEX_JST2000 : - rc = jjy_receive_cdex_jst2000 ( rbufp ) ; - break ; + pp->lastrec = tRecvTimestamp ; - case UNITTYPE_ECHOKEISOKUKI_LT2000 : - rc = jjy_receive_echokeisokuki_lt2000 ( rbufp ) ; - break ; + up->iLineCount ++ ; - case UNITTYPE_CITIZENTIC_JJY200 : - rc = jjy_receive_citizentic_jjy200 ( rbufp ) ; - break ; + up->iProcessState = JJY_PROCESS_STATE_RECEIVE ; + up->bReceiveFlag = TRUE ; - default : - rc = 0 ; - break ; + iReadRawBuf = 0 ; + iBreakPosition = up->iRawBufLen - 1 ; + for ( ; up->iProcessState == JJY_PROCESS_STATE_RECEIVE ; ) { - } + if ( up->linediscipline == LDISC_RAW ) { - if ( up->linediscipline == LDISC_RAW ) { - if ( up->linecount <= up->lineexpect && up->charcount > up->charexpect[up->linecount-1] ) { - for ( i = 0 ; i < up->charcount - up->charexpect[up->linecount-1] ; i ++ ) { - up->rawbuf[i] = up->rawbuf[i+up->charexpect[up->linecount-1]] ; + if ( up->bWaitBreakString ) { + iBreakPosition = getRawDataBreakPosition( up, iReadRawBuf ) ; + if ( iBreakPosition == -1 ) { + /* Break string have not come yet */ + if ( up->iRawBufLen < MAX_RAWBUF - 2 + || iReadRawBuf > 0 ) { + /* Temporary buffer is not full */ + break ; + } else { + /* Temporary buffer is full */ + iBreakPosition = up->iRawBufLen - 1 ; + } + } + } else { + iBreakPosition = up->iRawBufLen - 1 ; } - up->charcount -= up->charexpect[up->linecount-1] ; - } else { - up->charcount = 0 ; - } - } - if ( rc == 0 ) return ; + /* Copy charaters from temporary buffer to process buffer */ + up->iLineBufLen = up->iTextBufLen = 0 ; + for ( i = iReadRawBuf ; i <= iBreakPosition ; i ++ ) { - up->bPollFlag = 0 ; + /* Copy all characters */ + up->sLineBuf[up->iLineBufLen] = up->sRawBuf[i] ; + up->iLineBufLen ++ ; - if ( up->lineerror != 0 ) { - refclock_report ( peer, CEVNT_BADREPLY ) ; - strcpy ( sLogText, "BAD REPLY [" ) ; - if ( up->linediscipline == LDISC_RAW ) { - strncat ( sLogText, up->rawbuf, MAX_LOGTEXT - strlen ( sLogText ) - 1 ) ; - } else { - strncat ( sLogText, pp->a_lastcode, MAX_LOGTEXT - strlen ( sLogText ) - 1 ) ; - } - sLogText[MAX_LOGTEXT-1] = 0 ; - if ( strlen ( sLogText ) < MAX_LOGTEXT - 2 ) strcat ( sLogText, "]" ) ; - record_clock_stats ( &peer->srcadr, sLogText ) ; - return ; - } + /* Copy printable characters */ + if ( ! iscntrl( up->sRawBuf[i] ) ) { + up->sTextBuf[up->iTextBufLen] = up->sRawBuf[i] ; + up->iTextBufLen ++ ; + } - pp->year = up->year ; - pp->day = ymd2yd ( up->year, up->month, up->day ) ; - pp->hour = up->hour ; - pp->minute = up->minute ; - pp->second = up->second ; - pp->nsec = up->msecond * 1000000; + } + up->sLineBuf[up->iLineBufLen] = 0 ; + up->sTextBuf[up->iTextBufLen] = 0 ; +#ifdef DEBUG + printf( "refclock_jjy.c : %s : up->iLineBufLen=%d up->iTextBufLen=%d\n", + sFunctionName, up->iLineBufLen, up->iTextBufLen ) ; +#endif - /* - * JST to UTC - */ - pp->hour -= 9 ; - if ( pp->hour < 0 ) { - pp->hour += 24 ; - pp->day -- ; - if ( pp->day < 1 ) { - pp->year -- ; - pp->day = ymd2yd ( pp->year, 12, 31 ) ; - } - } + if ( up->bSkipCntrlCharOnly && up->iTextBufLen == 0 ) { #ifdef DEBUG - if ( debug ) { - printf ( "jjy_receive (refclock_jjy.c) : %04d/%02d/%02d %02d:%02d:%02d.%1d JST ", - up->year, up->month, up->day, up->hour, up->minute, up->second, up->msecond/100 ) ; - printf ( "( %04d/%03d %02d:%02d:%02d.%1d UTC )\n", - pp->year, pp->day, pp->hour, pp->minute, pp->second, (int)(pp->nsec/100000000) ) ; - } + printf( "refclock_jjy.c : %s : Skip cntrl char only : up->iRawBufLen=%d iReadRawBuf=%d iBreakPosition=%d\n", + sFunctionName, up->iRawBufLen, iReadRawBuf, iBreakPosition ) ; #endif + if ( iBreakPosition + 1 < up->iRawBufLen ) { + iReadRawBuf = iBreakPosition + 1 ; + continue ; + } else { + break ; + } - /* - * Process the new sample in the median filter and determine the - * timecode timestamp. - */ + } - sprintf ( sLogText, "%04d/%02d/%02d %02d:%02d:%02d.%1d JST", - up->year, up->month, up->day, up->hour, up->minute, up->second, up->msecond/100 ) ; - record_clock_stats ( &peer->srcadr, sLogText ) ; + } - if ( ! refclock_process ( pp ) ) { - refclock_report(peer, CEVNT_BADTIME); - return ; - } + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sLineBuf ; + iLen = up->iLineBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } - pp->lastref = pp->lastrec; - refclock_receive(peer); + iCopyLen = ( iLen <= sizeof(sLogText)-1 ? iLen : sizeof(sLogText)-1 ) ; + strncpy( sLogText, pBuf, iCopyLen ) ; + sLogText[iCopyLen] = 0 ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_RECEIVE, sLogText ) ; -} + switch ( up->unittype ) { -/**************************************************************************************************/ + case UNITTYPE_TRISTATE_JJY01 : + rc = jjy_receive_tristate_jjy01 ( rbufp ) ; + break ; -static int -jjy_receive_tristate_jjy01 ( struct recvbuf *rbufp ) -{ + case UNITTYPE_CDEX_JST2000 : + rc = jjy_receive_cdex_jst2000 ( rbufp ) ; + break ; - static char *sFunctionName = "jjy_receive_tristate_jjy01" ; + case UNITTYPE_ECHOKEISOKUKI_LT2000 : + rc = jjy_receive_echokeisokuki_lt2000 ( rbufp ) ; + break ; - struct jjyunit *up ; - struct refclockproc *pp ; - struct peer *peer; + case UNITTYPE_CITIZENTIC_JJY200 : + rc = jjy_receive_citizentic_jjy200 ( rbufp ) ; + break ; - char *pBuf ; - int iLen ; - int rc ; + case UNITTYPE_TRISTATE_GPSCLOCK01 : + rc = jjy_receive_tristate_gpsclock01 ( rbufp ) ; + break ; - /* - * Initialize pointers and read the timecode and timestamp - */ - peer = (struct peer *) rbufp->recv_srcclock ; - pp = peer->procptr ; - up = (struct jjyunit *) pp->unitptr ; + case UNITTYPE_SEIKO_TIMESYS_TDC_300 : + rc = jjy_receive_seiko_tsys_tdc_300 ( rbufp ) ; + break ; - if ( up->linediscipline == LDISC_RAW ) { - pBuf = up->rawbuf ; - iLen = up->charcount ; - } else { - pBuf = pp->a_lastcode ; - iLen = pp->lencode ; - } + case UNITTYPE_TELEPHONE : + rc = jjy_receive_telephone ( rbufp ) ; + break ; - switch ( up->linecount ) { + default : + rc = JJY_RECEIVE_ERROR ; + break ; - case 1 : /* YYYY/MM/DD WWW */ + } - if ( iLen != 14 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Reply length error ( up->linecount=%d iLen=%d )\n", sFunctionName, up->linecount, iLen ) ; - } -#endif - up->lineerror = 1 ; + switch ( rc ) { + case JJY_RECEIVE_DONE : + case JJY_RECEIVE_SKIP : + up->iProcessState = JJY_PROCESS_STATE_DONE ; break ; - } - rc = sscanf ( pBuf, "%4d/%2d/%2d", &up->year, &up->month, &up->day ) ; - if ( rc != 3 || up->year < 2000 || up->month < 1 || up->month > 12 || up->day < 1 || up->day > 31 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Date error ( up->linecount=%d )\n", sFunctionName, up->linecount ) ; - } -#endif - up->lineerror = 1 ; + case JJY_RECEIVE_ERROR : + up->iProcessState = JJY_PROCESS_STATE_ERROR ; + break ; + default : break ; } - /*** Start of modification on 2004/10/31 */ - /* - * Following codes are moved from the function jjy_poll_tristate_jjy01 in this source. - * The Tristate JJY-01 ( Firmware version 1.01 ) accepts "time" and "stim" commands without any delay. - * But the JJY-01 ( Firmware version 2.01 ) does not accept these commands continuously, - * so this driver issues the second command "stim" after the reply of the first command "date". - */ - - /* - * Send "stim" or "time" command - */ - - - if ( up->version >= 100 ) { -#ifdef DEBUG - if ( debug ) { - printf ( "%s (refclock_jjy.c) : send 'stim'\n", sFunctionName ) ; - } -#endif - if ( write ( pp->io.fd, "stim\r\n",6 ) != 6 ) { - refclock_report ( peer, CEVNT_FAULT ) ; - } - } else { -#ifdef DEBUG - if ( debug ) { - printf ( "%s (refclock_jjy.c) : send 'time'\n", sFunctionName ) ; + if ( up->linediscipline == LDISC_RAW ) { + if ( rc == JJY_RECEIVE_UNPROCESS ) { + break ; } -#endif - if ( write ( pp->io.fd, "time\r\n",6 ) != 6 ) { - refclock_report ( peer, CEVNT_FAULT ) ; + iReadRawBuf = iBreakPosition + 1 ; + if ( iReadRawBuf >= up->iRawBufLen ) { + /* Processed all received data */ + break ; } } - /*** End of modification ***/ - - return 0 ; - case 2 : /* HH:MM:SS */ - - if ( iLen != 8 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Reply length error ( up->linecount=%d iLen=%d )\n", sFunctionName, up->linecount, iLen ) ; - } -#endif - up->lineerror = 1 ; - break ; - } - rc = sscanf ( pBuf, "%2d:%2d:%2d", &up->hour, &up->minute, &up->second ) ; - if ( rc != 3 || up->hour > 23 || up->minute > 59 || up->second > 60 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Time error ( up->linecount=%d )\n", sFunctionName, up->linecount ) ; - } -#endif - up->lineerror = 1 ; + if ( up->linediscipline == LDISC_CLK ) { break ; } - up->msecond = 0 ; - if ( up->hour == 0 && up->minute == 0 && up->second <= 2 ) { - /* - * The command "date" and "time" ( or "stim" ) were sent to the JJY receiver continuously. - * But the JJY receiver replies a date and time separately. - * Just after midnight transitions, we ignore this time. - */ - return 0 ; - } - break ; - - default : /* Unexpected reply */ - up->lineerror = 1 ; - break ; + } + if ( up->linediscipline == LDISC_RAW && iReadRawBuf > 0 ) { + for ( i = 0, j = iReadRawBuf ; j < up->iRawBufLen ; i ++, j++ ) { + up->sRawBuf[i] = up->sRawBuf[j] ; + } + up->iRawBufLen -= iReadRawBuf ; + if ( up->iRawBufLen < 0 ) { + up->iRawBufLen = 0 ; + } } - return 1 ; + up->bReceiveFlag = FALSE ; } /**************************************************************************************************/ static int -jjy_receive_cdex_jst2000 ( struct recvbuf *rbufp ) +getRawDataBreakPosition ( struct jjyunit *up, int iStart ) { - static char *sFunctionName = "jjy_receive_cdex_jst2000" ; + int i, j ; - struct jjyunit *up ; - struct refclockproc *pp ; - struct peer *peer; - - char *pBuf ; - int iLen ; - int rc ; + if ( iStart >= up->iRawBufLen ) { +#ifdef DEBUG + printf( "refclock_jjy.c : getRawDataBreakPosition : iStart=%d return=-1\n", iStart ) ; +#endif + return -1 ; + } - /* - * Initialize pointers and read the timecode and timestamp - */ - peer = (struct peer *) rbufp->recv_srcclock ; - pp = peer->procptr ; - up = (struct jjyunit *) pp->unitptr ; + for ( i = iStart ; i < up->iRawBufLen ; i ++ ) { - if ( up->linediscipline == LDISC_RAW ) { - pBuf = up->rawbuf ; - iLen = up->charcount ; - } else { - pBuf = pp->a_lastcode ; - iLen = pp->lencode ; - } + for ( j = 0 ; up->pRawBreak[j].pString != NULL ; j ++ ) { - switch ( up->linecount ) { + if ( i + up->pRawBreak[j].iLength <= up->iRawBufLen ) { - case 1 : /* JYYMMDD HHMMSSS */ + if ( strncmp( up->sRawBuf + i, + up->pRawBreak[j].pString, + up->pRawBreak[j].iLength ) == 0 ) { - if ( iLen != 15 ) { #ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Reply length error ( iLen=%d )\n", sFunctionName, iLen ) ; - } + printf( "refclock_jjy.c : getRawDataBreakPosition : iStart=%d return=%d\n", + iStart, i + up->pRawBreak[j].iLength - 1 ) ; #endif - up->lineerror = 1 ; - break ; + return i + up->pRawBreak[j].iLength - 1 ; + + } + } } - rc = sscanf ( pBuf, "J%2d%2d%2d%*1d%2d%2d%2d%1d", - &up->year, &up->month, &up->day, &up->hour, &up->minute, &up->second, &up->msecond ) ; - if ( rc != 7 || up->month < 1 || up->month > 12 || up->day < 1 || up->day > 31 - || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + } + #ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Time error (rc=%d) [ %02d %02d %02d * %02d %02d %02d.%1d ]\n", sFunctionName, - rc, up->year, up->month, up->day, up->hour, up->minute, up->second, up->msecond ) ; - } + printf( "refclock_jjy.c : getRawDataBreakPosition : iStart=%d return=-1\n", iStart ) ; #endif - up->lineerror = 1 ; - break ; + return -1 ; + +} + +/**************************************************************************************************/ +/* jjy_poll - called by the transmit procedure */ +/**************************************************************************************************/ +static void +jjy_poll ( int unit, struct peer *peer ) +{ + + char sLog [ 40 ], sReach [ 9 ] ; + + struct jjyunit *up; + struct refclockproc *pp; + + pp = peer->procptr; + up = pp->unitptr ; + + if ( up->bInitError ) { + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, "Ignore polling because of error during initializing" ) ; + return ; + } + + if ( pp->polls > 0 && up->iLineCount == 0 ) { + /* + * No reply for last command + */ + refclock_report ( peer, CEVNT_TIMEOUT ) ; + } + + pp->polls ++ ; + + sReach[0] = peer->reach & 0x80 ? '1' : '0' ; + sReach[1] = peer->reach & 0x40 ? '1' : '0' ; + sReach[2] = peer->reach & 0x20 ? '1' : '0' ; + sReach[3] = peer->reach & 0x10 ? '1' : '0' ; + sReach[4] = peer->reach & 0x08 ? '1' : '0' ; + sReach[5] = peer->reach & 0x04 ? '1' : '0' ; + sReach[6] = peer->reach & 0x02 ? '1' : '0' ; + sReach[7] = 0 ; /* This poll */ + sReach[8] = 0 ; + + snprintf( sLog, sizeof(sLog), "polls=%ld reach=%s", pp->polls, sReach ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ATTENTION, sLog ) ; + + up->iProcessState = JJY_PROCESS_STATE_POLL ; + up->iCommandSeq = 0 ; + up->iReceiveSeq = 0 ; + up->iLineCount = 0 ; + up->bLineError = FALSE ; + up->iRawBufLen = 0 ; + + switch ( up->unittype ) { + + case UNITTYPE_TRISTATE_JJY01 : + jjy_poll_tristate_jjy01 ( unit, peer ) ; + break ; + + case UNITTYPE_CDEX_JST2000 : + jjy_poll_cdex_jst2000 ( unit, peer ) ; + break ; + + case UNITTYPE_ECHOKEISOKUKI_LT2000 : + jjy_poll_echokeisokuki_lt2000 ( unit, peer ) ; + break ; + + case UNITTYPE_CITIZENTIC_JJY200 : + jjy_poll_citizentic_jjy200 ( unit, peer ) ; + break ; + + case UNITTYPE_TRISTATE_GPSCLOCK01 : + jjy_poll_tristate_gpsclock01 ( unit, peer ) ; + break ; + + case UNITTYPE_SEIKO_TIMESYS_TDC_300 : + jjy_poll_seiko_tsys_tdc_300 ( unit, peer ) ; + break ; + + case UNITTYPE_TELEPHONE : + jjy_poll_telephone ( unit, peer ) ; + break ; + + default : + break ; + + } + +} + +/**************************************************************************************************/ +/* jjy_timer - called at one-second intervals */ +/**************************************************************************************************/ +static void +jjy_timer ( int unit, struct peer *peer ) +{ + + struct refclockproc *pp ; + struct jjyunit *up ; + +#ifdef DEBUG + if ( debug ) { + printf ( "refclock_jjy.c : jjy_timer\n" ) ; + } +#endif + + pp = peer->procptr ; + up = pp->unitptr ; + + if ( up->bReceiveFlag ) { +#ifdef DEBUG + if ( debug ) { + printf ( "refclock_jjy.c : jjy_timer : up->bReceiveFlag= TRUE : Timer skipped.\n" ) ; + } +#endif + return ; + } + + switch ( up->unittype ) { + + case UNITTYPE_TELEPHONE : + jjy_timer_telephone ( unit, peer ) ; + break ; + + default : + break ; + + } + +} + +/**************************************************************************************************/ +/* jjy_synctime */ +/**************************************************************************************************/ +static void +jjy_synctime ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + char sLog [ 80 ], cStatus ; + const char *pStatus ; + + pp->year = up->year ; + pp->day = ymd2yd( up->year, up->month, up->day ) ; + pp->hour = up->hour ; + pp->minute = up->minute ; + pp->second = up->second ; + pp->nsec = up->msecond * 1000000 ; + + /* + * JST to UTC + */ + pp->hour -= 9 ; + if ( pp->hour < 0 ) { + pp->hour += 24 ; + pp->day -- ; + if ( pp->day < 1 ) { + pp->year -- ; + pp->day = ymd2yd( pp->year, 12, 31 ) ; + } + } + + /* + * Process the new sample in the median filter and determine the + * timecode timestamp. + */ + + if ( ! refclock_process( pp ) ) { + refclock_report( peer, CEVNT_BADTIME ) ; + return ; + } + + pp->lastref = pp->lastrec ; + + refclock_receive( peer ) ; + + /* + * Write into the clockstats file + */ + snprintf ( sLog, sizeof(sLog), + "%04d/%02d/%02d %02d:%02d:%02d.%03d JST ( %04d/%03d %02d:%02d:%02d.%03d UTC )", + up->year, up->month, up->day, + up->hour, up->minute, up->second, up->msecond, + pp->year, pp->day, pp->hour, pp->minute, pp->second, + (int)(pp->nsec/1000000) ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ATTENTION, sLog ) ; + + cStatus = ' ' ; + pStatus = "" ; + + switch ( peer->status ) { + case 0 : cStatus = ' ' ; pStatus = "Reject" ; break ; + case 1 : cStatus = 'x' ; pStatus = "FalseTick" ; break ; + case 2 : cStatus = '.' ; pStatus = "Excess" ; break ; + case 3 : cStatus = '-' ; pStatus = "Outlier" ; break ; + case 4 : cStatus = '+' ; pStatus = "Candidate" ; break ; + case 5 : cStatus = '#' ; pStatus = "Selected" ; break ; + case 6 : cStatus = '*' ; pStatus = "Sys.Peer" ; break ; + case 7 : cStatus = 'o' ; pStatus = "PPS.Peer" ; break ; + default : break ; + } + + snprintf ( sLog, sizeof(sLog), + "status %d [%c] %s : offset %3.3f mSec. : jitter %3.3f mSec.", + peer->status, cStatus, pStatus, peer->offset * 1000, peer->jitter * 1000 ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_INFORMATION, sLog ) ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## The Tristate Ltd. JJY receiver TS-JJY01, TS-JJY02 ##*/ +/*## ##*/ +/*## server 127.127.40.X mode 1 ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ +/* */ +/* Command Response Remarks */ +/* -------------------- ---------------------------------------- ---------------------------- */ +/* dcst VALID or INVALID */ +/* stus ADJUSTED or UNADJUSTED */ +/* date YYYY/MM/DD XXX XXX is the day of the week */ +/* time HH:MM:SS Not used by this driver */ +/* stim HH:MM:SS Reply at just second */ +/* */ +/*################################################################################################*/ + +#define TS_JJY01_COMMAND_NUMBER_DATE 1 +#define TS_JJY01_COMMAND_NUMBER_TIME 2 +#define TS_JJY01_COMMAND_NUMBER_STIM 3 +#define TS_JJY01_COMMAND_NUMBER_STUS 4 +#define TS_JJY01_COMMAND_NUMBER_DCST 5 + +#define TS_JJY01_REPLY_DATE "yyyy/mm/dd www" +#define TS_JJY01_REPLY_STIM "hh:mm:ss" +#define TS_JJY01_REPLY_STUS_ADJUSTED "adjusted" +#define TS_JJY01_REPLY_STUS_UNADJUSTED "unadjusted" +#define TS_JJY01_REPLY_DCST_VALID "valid" +#define TS_JJY01_REPLY_DCST_INVALID "invalid" + +#define TS_JJY01_REPLY_LENGTH_DATE 14 /* Length without */ +#define TS_JJY01_REPLY_LENGTH_TIME 8 /* Length without */ +#define TS_JJY01_REPLY_LENGTH_STIM 8 /* Length without */ +#define TS_JJY01_REPLY_LENGTH_STUS_ADJUSTED 8 /* Length without */ +#define TS_JJY01_REPLY_LENGTH_STUS_UNADJUSTED 10 /* Length without */ +#define TS_JJY01_REPLY_LENGTH_DCST_VALID 5 /* Length without */ +#define TS_JJY01_REPLY_LENGTH_DCST_INVALID 7 /* Length without */ + +static struct +{ + const char commandNumber ; + const char *command ; + int commandLength ; + int iExpectedReplyLength [ 2 ] ; +} tristate_jjy01_command_sequence[] = +{ + { 0, NULL, 0, { 0, 0 } }, /* Idle */ + { TS_JJY01_COMMAND_NUMBER_DCST, "dcst\r\n", 6, { TS_JJY01_REPLY_LENGTH_DCST_VALID , TS_JJY01_REPLY_LENGTH_DCST_INVALID } }, + { TS_JJY01_COMMAND_NUMBER_STUS, "stus\r\n", 6, { TS_JJY01_REPLY_LENGTH_STUS_ADJUSTED, TS_JJY01_REPLY_LENGTH_STUS_UNADJUSTED } }, + { TS_JJY01_COMMAND_NUMBER_TIME, "time\r\n", 6, { TS_JJY01_REPLY_LENGTH_TIME , TS_JJY01_REPLY_LENGTH_TIME } }, + { TS_JJY01_COMMAND_NUMBER_DATE, "date\r\n", 6, { TS_JJY01_REPLY_LENGTH_DATE , TS_JJY01_REPLY_LENGTH_DATE } }, + { TS_JJY01_COMMAND_NUMBER_STIM, "stim\r\n", 6, { TS_JJY01_REPLY_LENGTH_STIM , TS_JJY01_REPLY_LENGTH_STIM } }, + /* End of command */ + { 0, NULL, 0, { 0, 0 } } +} ; + +/**************************************************************************************************/ + +static int +jjy_start_tristate_jjy01 ( int unit, struct peer *peer, struct jjyunit *up ) +{ + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, "Refclock: Tristate Ltd. TS-JJY01, TS-JJY02" ) ; + + up->unittype = UNITTYPE_TRISTATE_JJY01 ; + up->linespeed = SPEED232_TRISTATE_JJY01 ; + up->linediscipline = LDISC_CLK ; + + return 0 ; + +} + +/**************************************************************************************************/ + +static int +jjy_receive_tristate_jjy01 ( struct recvbuf *rbufp ) +{ + struct jjyunit *up ; + struct refclockproc *pp ; + struct peer *peer; + + char *pBuf, sLog [ 100 ] ; + int iLen ; + int rc ; + + const char *pCmd ; + int iCmdLen ; + + /* Initialize pointers */ + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + DEBUG_PRINTF_JJY_RECEIVE( "jjy_receive_tristate_jjy01", iLen ) ; + + /* Check expected reply */ + + if ( tristate_jjy01_command_sequence[up->iCommandSeq].command == NULL ) { + /* Command sequence has not been started, or has been completed */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_UNEXPECTED_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + /* Check reply length */ + + if ( iLen != tristate_jjy01_command_sequence[up->iCommandSeq].iExpectedReplyLength[0] + && iLen != tristate_jjy01_command_sequence[up->iCommandSeq].iExpectedReplyLength[1] ) { + /* Unexpected reply length */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_LENGTH, + iLen ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + /* Parse reply */ + + switch ( tristate_jjy01_command_sequence[up->iCommandSeq].commandNumber ) { + + case TS_JJY01_COMMAND_NUMBER_DATE : /* YYYY/MM/DD WWW */ + + rc = sscanf ( pBuf, "%4d/%2d/%2d", + &up->year, &up->month, &up->day ) ; + + if ( rc != 3 || up->year < 2000 || 2099 <= up->year + || up->month < 1 || 12 < up->month + || up->day < 1 || 31 < up->day ) { + /* Invalid date */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATE, + rc, up->year, up->month, up->day ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + break ; + + case TS_JJY01_COMMAND_NUMBER_TIME : /* HH:MM:SS */ + case TS_JJY01_COMMAND_NUMBER_STIM : /* HH:MM:SS */ + + if ( up->iTimestampCount >= 2 ) { + /* Too many time reply */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_TOO_MANY_REPLY, + up->iTimestampCount ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + rc = sscanf ( pBuf, "%2d:%2d:%2d", + &up->hour, &up->minute, &up->second ) ; + + if ( rc != 3 || up->hour > 23 || up->minute > 59 || + up->second > 60 ) { + /* Invalid time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_TIME, + rc, up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + up->iTimestamp[up->iTimestampCount] = ( up->hour * 60 + up->minute ) * 60 + up->second ; + + up->iTimestampCount++ ; + + up->msecond = 0 ; + + break ; + + case TS_JJY01_COMMAND_NUMBER_STUS : + + if ( strncmp( pBuf, TS_JJY01_REPLY_STUS_ADJUSTED, + TS_JJY01_REPLY_LENGTH_STUS_ADJUSTED ) == 0 + || strncmp( pBuf, TS_JJY01_REPLY_STUS_UNADJUSTED, + TS_JJY01_REPLY_LENGTH_STUS_UNADJUSTED ) == 0 ) { + /* Good */ + } else { + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + break ; + + case TS_JJY01_COMMAND_NUMBER_DCST : + + if ( strncmp( pBuf, TS_JJY01_REPLY_DCST_VALID, + TS_JJY01_REPLY_LENGTH_DCST_VALID ) == 0 + || strncmp( pBuf, TS_JJY01_REPLY_DCST_INVALID, + TS_JJY01_REPLY_LENGTH_DCST_INVALID ) == 0 ) { + /* Good */ + } else { + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; } - up->year += 2000 ; - up->msecond *= 100 ; + break ; default : /* Unexpected reply */ - up->lineerror = 1 ; - break ; + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + + } + + if ( up->iTimestampCount == 2 ) { + /* Process date and time */ + + if ( up->iTimestamp[1] - 2 <= up->iTimestamp[0] + && up->iTimestamp[0] <= up->iTimestamp[1] ) { + /* 3 commands (time,date,stim) was excuted in two seconds */ + jjy_synctime( peer, pp, up ) ; + return JJY_RECEIVE_DONE ; + } else if ( up->iTimestamp[0] > up->iTimestamp[1] ) { + /* Over midnight, and date is unsure */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_OVER_MIDNIGHT_2, + up->iTimestamp[0], up->iTimestamp[1] ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_INFORMATION, sLog ) ; + return JJY_RECEIVE_SKIP ; + } else { + /* Slow reply */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SLOW_REPLY_2, + up->iTimestamp[0], up->iTimestamp[1] ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + } + + /* Issue next command */ + + if ( tristate_jjy01_command_sequence[up->iCommandSeq].command != NULL ) { + up->iCommandSeq ++ ; + } + + if ( tristate_jjy01_command_sequence[up->iCommandSeq].command == NULL ) { + /* Command sequence completed */ + return JJY_RECEIVE_DONE ; + } + + pCmd = tristate_jjy01_command_sequence[up->iCommandSeq].command ; + iCmdLen = tristate_jjy01_command_sequence[up->iCommandSeq].commandLength ; + if ( write ( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report ( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + + return JJY_RECEIVE_WAIT ; + +} + +/**************************************************************************************************/ + +static void +jjy_poll_tristate_jjy01 ( int unit, struct peer *peer ) +{ +#ifdef DEBUG + static const char *sFunctionName = "jjy_poll_tristate_jjy01" ; +#endif + + struct refclockproc *pp ; + struct jjyunit *up ; + + const char *pCmd ; + int iCmdLen ; + + pp = peer->procptr; + up = pp->unitptr ; + + up->bLineError = FALSE ; + up->iTimestampCount = 0 ; + + if ( ( pp->sloppyclockflag & CLK_FLAG1 ) == 0 ) { + /* Skip "dcst" and "stus" commands */ + up->iCommandSeq = 2 ; + up->iLineCount = 2 ; + } + +#ifdef DEBUG + if ( debug ) { + printf ( "%s (refclock_jjy.c) : flag1=%X CLK_FLAG1=%X up->iLineCount=%d\n", + sFunctionName, pp->sloppyclockflag, CLK_FLAG1, + up->iLineCount ) ; + } +#endif + + /* + * Send a first command + */ + + up->iCommandSeq ++ ; + + pCmd = tristate_jjy01_command_sequence[up->iCommandSeq].command ; + iCmdLen = tristate_jjy01_command_sequence[up->iCommandSeq].commandLength ; + if ( write ( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report ( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## The C-DEX Co. Ltd. JJY receiver JST2000 ##*/ +/*## ##*/ +/*## server 127.127.40.X mode 2 ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ +/* */ +/* Command Response Remarks */ +/* -------------------- ---------------------------------------- ---------------------------- */ +/* 1J JYYMMDD HHMMSSS J is a fixed character */ +/* */ +/*################################################################################################*/ + +static struct jjyRawDataBreak cdex_jst2000_raw_break [ ] = +{ + { "\x03", 1 }, { NULL, 0 } +} ; + +/**************************************************************************************************/ + +static int +jjy_start_cdex_jst2000 ( int unit, struct peer *peer, struct jjyunit *up ) +{ + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, "Refclock: C-DEX Co. Ltd. JST2000" ) ; + + up->unittype = UNITTYPE_CDEX_JST2000 ; + up->linespeed = SPEED232_CDEX_JST2000 ; + up->linediscipline = LDISC_RAW ; + + up->pRawBreak = cdex_jst2000_raw_break ; + up->bWaitBreakString = TRUE ; + + up->bSkipCntrlCharOnly = FALSE ; + + return 0 ; + +} + +/**************************************************************************************************/ + +static int +jjy_receive_cdex_jst2000 ( struct recvbuf *rbufp ) +{ + + struct jjyunit *up ; + struct refclockproc *pp ; + struct peer *peer ; + + char *pBuf, sLog [ 100 ] ; + int iLen ; + int rc ; + + /* Initialize pointers */ + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + DEBUG_PRINTF_JJY_RECEIVE( "jjy_receive_cdex_jst2000", iLen ) ; + + /* Check expected reply */ + + if ( up->iCommandSeq != 1 ) { + /* Command sequence has not been started, or has been completed */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_UNEXPECTED_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + /* Wait until ETX comes */ + + if ( up->iLineBufLen < 17 || up->sLineBuf[up->iLineBufLen-1] != 0x03 ) { + return JJY_RECEIVE_UNPROCESS ; + } + + /* Check reply length */ + + if ( iLen != 15 ) { + /* Unexpected reply length */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_LENGTH, + iLen ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + /* JYYMMDD HHMMSSS */ + + rc = sscanf ( pBuf, "J%2d%2d%2d %2d%2d%2d%1d", + &up->year, &up->month, &up->day, + &up->hour, &up->minute, &up->second, + &up->msecond ) ; + + if ( rc != 7 || up->month < 1 || up->month > 12 || + up->day < 1 || up->day > 31 || up->hour > 23 || + up->minute > 59 || up->second > 60 ) { + /* Invalid date and time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATETIME, + rc, up->year, up->month, up->day, + up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + up->year += 2000 ; + up->msecond *= 100 ; + + jjy_synctime( peer, pp, up ) ; + + return JJY_RECEIVE_DONE ; + +} + +/**************************************************************************************************/ + +static void +jjy_poll_cdex_jst2000 ( int unit, struct peer *peer ) +{ + + struct refclockproc *pp ; + struct jjyunit *up ; + + pp = peer->procptr ; + up = pp->unitptr ; + + up->bLineError = FALSE ; + up->iRawBufLen = 0 ; + up->iLineBufLen = 0 ; + up->iTextBufLen = 0 ; + + /* + * Send "1J" command + */ + + up->iCommandSeq ++ ; + + if ( write ( pp->io.fd, "\0051J\003", 4 ) != 4 ) { + refclock_report ( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, "\0051J\003" ) ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## The Echo Keisokuki Co. Ltd. JJY receiver LT2000 ##*/ +/*## ##*/ +/*## server 127.127.40.X mode 3 ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ +/* */ +/* Command Response Remarks */ +/* -------------------- ---------------------------------------- ---------------------------- */ +/* # Mode 1 ( Request & Send ) */ +/* T YYMMDDWHHMMSS */ +/* C Mode 2 ( Continuous ) */ +/* YYMMDDWHHMMSS 0.5 sec before time stamp */ +/* Second signal */ +/* */ +/*################################################################################################*/ + +#define ECHOKEISOKUKI_LT2000_MODE_REQUEST_SEND 1 +#define ECHOKEISOKUKI_LT2000_MODE_CONTINUOUS 2 +#define ECHOKEISOKUKI_LT2000_MODE_SWITCHING_CONTINUOUS 3 + +#define ECHOKEISOKUKI_LT2000_COMMAND_REQUEST_SEND "#" +#define ECHOKEISOKUKI_LT2000_COMMAND_REQUEST_TIME "T" +#define ECHOKEISOKUKI_LT2000_COMMAND_CONTINUOUS "C" + +/**************************************************************************************************/ + +static int +jjy_start_echokeisokuki_lt2000 ( int unit, struct peer *peer, struct jjyunit *up ) +{ + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, "Refclock: Echo Keisokuki Co. Ltd. LT2000" ) ; + + up->unittype = UNITTYPE_ECHOKEISOKUKI_LT2000 ; + up->linespeed = SPEED232_ECHOKEISOKUKI_LT2000 ; + up->linediscipline = LDISC_CLK ; + + up->operationmode = ECHOKEISOKUKI_LT2000_MODE_SWITCHING_CONTINUOUS ; + + return 0 ; + +} + +/**************************************************************************************************/ + +static int +jjy_receive_echokeisokuki_lt2000 ( struct recvbuf *rbufp ) +{ + + struct jjyunit *up ; + struct refclockproc *pp ; + struct peer *peer; + + char *pBuf, sLog [ 100 ], sErr [ 60 ] ; + int iLen ; + int rc ; + int i, ibcc, ibcc1, ibcc2 ; + + /* Initialize pointers */ + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + DEBUG_PRINTF_JJY_RECEIVE( "jjy_receive_echokeisokuki_lt2000", iLen ) ; + + /* Check reply length */ + + if ( ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_REQUEST_SEND + && iLen != 15 ) + || ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_CONTINUOUS + && iLen != 17 ) + || ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_SWITCHING_CONTINUOUS + && iLen != 17 ) ) { + /* Unexpected reply length */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_LENGTH, + iLen ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + if ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_REQUEST_SEND && iLen == 15 ) { + /* YYMMDDWHHMMSS */ + + for ( i = ibcc = 0 ; i < 13 ; i ++ ) { + ibcc ^= pBuf[i] ; + } + + ibcc1 = 0x30 | ( ( ibcc >> 4 ) & 0xF ) ; + ibcc2 = 0x30 | ( ( ibcc ) & 0xF ) ; + if ( pBuf[13] != ibcc1 || pBuf[14] != ibcc2 ) { + snprintf( sErr, sizeof(sErr)-1, " BCC error : Recv=%02X,%02X / Calc=%02X,%02X ", + pBuf[13] & 0xFF, pBuf[14] & 0xFF, + ibcc1, ibcc2 ) ; + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY, + sErr ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + } + + if ( ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_REQUEST_SEND + && iLen == 15 ) + || ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_CONTINUOUS + && iLen == 17 ) + || ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_SWITCHING_CONTINUOUS + && iLen == 17 ) ) { + /* YYMMDDWHHMMSS or YYMMDDWHHMMSS */ + + rc = sscanf ( pBuf, "%2d%2d%2d%*1d%2d%2d%2d", + &up->year, &up->month, &up->day, + &up->hour, &up->minute, &up->second ) ; + + if ( rc != 6 || up->month < 1 || up->month > 12 + || up->day < 1 || up->day > 31 + || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + /* Invalid date and time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATETIME, + rc, up->year, up->month, up->day, + up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + up->year += 2000 ; + + if ( up->operationmode == ECHOKEISOKUKI_LT2000_MODE_CONTINUOUS + || up->operationmode == ECHOKEISOKUKI_LT2000_MODE_SWITCHING_CONTINUOUS ) { + /* A time stamp comes on every 0.5 second in the mode 2 of the LT-2000. */ + + up->msecond = 500 ; + up->second -- ; + if ( up->second < 0 ) { + up->second = 59 ; + up->minute -- ; + if ( up->minute < 0 ) { + up->minute = 59 ; + up->hour -- ; + if ( up->hour < 0 ) { + up->hour = 23 ; + up->day -- ; + if ( up->day < 1 ) { + up->month -- ; + if ( up->month < 1 ) { + up->month = 12 ; + up->year -- ; + } + } + } + } + } + + } + + jjy_synctime( peer, pp, up ) ; + + + } + + if (up->operationmode == ECHOKEISOKUKI_LT2000_MODE_SWITCHING_CONTINUOUS ) { + /* Switch from mode 2 to mode 1 in order to restraint of useless time stamp. */ + + iLen = strlen( ECHOKEISOKUKI_LT2000_COMMAND_REQUEST_SEND ) ; + if ( write ( pp->io.fd, ECHOKEISOKUKI_LT2000_COMMAND_REQUEST_SEND, iLen ) != iLen ) { + refclock_report ( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, ECHOKEISOKUKI_LT2000_COMMAND_REQUEST_SEND ) ; + + } + + return JJY_RECEIVE_DONE ; + +} + +/**************************************************************************************************/ + +static void +jjy_poll_echokeisokuki_lt2000 ( int unit, struct peer *peer ) +{ + + struct refclockproc *pp ; + struct jjyunit *up ; + + char sCmd[2] ; + + pp = peer->procptr ; + up = pp->unitptr ; + + up->bLineError = FALSE ; + + /* + * Send "T" or "C" command + */ + + switch ( up->operationmode ) { + case ECHOKEISOKUKI_LT2000_MODE_REQUEST_SEND : + sCmd[0] = 'T' ; + break ; + case ECHOKEISOKUKI_LT2000_MODE_CONTINUOUS : + case ECHOKEISOKUKI_LT2000_MODE_SWITCHING_CONTINUOUS : + sCmd[0] = 'C' ; + break ; + } + sCmd[1] = 0 ; + + if ( write ( pp->io.fd, sCmd, 1 ) != 1 ) { + refclock_report ( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, sCmd ) ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## The CITIZEN T.I.C CO., LTD. JJY receiver JJY200 ##*/ +/*## ##*/ +/*## server 127.127.40.X mode 4 ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ +/* */ +/* Command Response Remarks */ +/* -------------------- ---------------------------------------- ---------------------------- */ +/* 'XX YY/MM/DD W HH:MM:SS XX:OK|NG|ER W:0(Mon)-6(Sun) */ +/* */ +/*################################################################################################*/ + +static int +jjy_start_citizentic_jjy200 ( int unit, struct peer *peer, struct jjyunit *up ) +{ + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, "Refclock: CITIZEN T.I.C CO. LTD. JJY200" ) ; + + up->unittype = UNITTYPE_CITIZENTIC_JJY200 ; + up->linespeed = SPEED232_CITIZENTIC_JJY200 ; + up->linediscipline = LDISC_CLK ; + + return 0 ; + +} + +/**************************************************************************************************/ + +static int +jjy_receive_citizentic_jjy200 ( struct recvbuf *rbufp ) +{ + + struct jjyunit *up ; + struct refclockproc *pp ; + struct peer *peer; + + char *pBuf, sLog [ 100 ], sMsg [ 16 ] ; + int iLen ; + int rc ; + char cApostrophe, sStatus[3] ; + int iWeekday ; + + /* Initialize pointers */ + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + DEBUG_PRINTF_JJY_RECEIVE( "jjy_receive_citizentic_jjy200", iLen ) ; + + /* + * JJY-200 sends a timestamp every second. + * So, a timestamp is ignored unless it is right after polled. + */ + + if ( up->iProcessState != JJY_PROCESS_STATE_RECEIVE ) { + return JJY_RECEIVE_SKIP ; + } + + /* Check reply length */ + + if ( iLen != 23 ) { + /* Unexpected reply length */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_LENGTH, + iLen ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + /* 'XX YY/MM/DD W HH:MM:SS */ + + rc = sscanf ( pBuf, "%c%2s %2d/%2d/%2d %1d %2d:%2d:%2d", + &cApostrophe, sStatus, + &up->year, &up->month, &up->day, &iWeekday, + &up->hour, &up->minute, &up->second ) ; + sStatus[2] = 0 ; + + if ( rc != 9 || cApostrophe != '\'' + || ( strcmp( sStatus, "OK" ) != 0 + && strcmp( sStatus, "NG" ) != 0 + && strcmp( sStatus, "ER" ) != 0 ) + || up->month < 1 || up->month > 12 || up->day < 1 || up->day > 31 + || iWeekday > 6 + || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + /* Invalid date and time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATETIME, + rc, up->year, up->month, up->day, + up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } else if ( strcmp( sStatus, "NG" ) == 0 + || strcmp( sStatus, "ER" ) == 0 ) { + /* Timestamp is unsure */ + snprintf( sMsg, sizeof(sMsg)-1, "status=%s", sStatus ) ; + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_TIMESTAMP_UNSURE, + sMsg ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_WARNING, sLog ) ; + return JJY_RECEIVE_SKIP ; + } + + up->year += 2000 ; + up->msecond = 0 ; + + jjy_synctime( peer, pp, up ) ; + + return JJY_RECEIVE_DONE ; + +} + +/**************************************************************************************************/ + +static void +jjy_poll_citizentic_jjy200 ( int unit, struct peer *peer ) +{ + + struct refclockproc *pp ; + struct jjyunit *up ; + + pp = peer->procptr ; + up = pp->unitptr ; + + up->bLineError = FALSE ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## The Tristate Ltd. GPS clock TS-GPS01 ##*/ +/*## ##*/ +/*## server 127.127.40.X mode 5 ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ +/* */ +/* This clock has NMEA mode and command/respose mode. */ +/* When this jjy driver are used, set to command/respose mode of this clock */ +/* by the onboard switch SW4, and make sure the LED-Y is tured on. */ +/* Other than this JJY driver, the refclock driver type 20, generic NMEA driver, */ +/* works with the NMEA mode of this clock. */ +/* */ +/* Command Response Remarks */ +/* -------------------- ---------------------------------------- ---------------------------- */ +/* stus *R|*G|*U|+U */ +/* date YY/MM/DD */ +/* time HH:MM:SS */ +/* */ +/*################################################################################################*/ + +#define TS_GPS01_COMMAND_NUMBER_DATE 1 +#define TS_GPS01_COMMAND_NUMBER_TIME 2 +#define TS_GPS01_COMMAND_NUMBER_STUS 4 + +#define TS_GPS01_REPLY_DATE "yyyy/mm/dd" +#define TS_GPS01_REPLY_TIME "hh:mm:ss" +#define TS_GPS01_REPLY_STUS_RTC "*R" +#define TS_GPS01_REPLY_STUS_GPS "*G" +#define TS_GPS01_REPLY_STUS_UTC "*U" +#define TS_GPS01_REPLY_STUS_PPS "+U" + +#define TS_GPS01_REPLY_LENGTH_DATE 10 /* Length without */ +#define TS_GPS01_REPLY_LENGTH_TIME 8 /* Length without */ +#define TS_GPS01_REPLY_LENGTH_STUS 2 /* Length without */ + +static struct +{ + char commandNumber ; + const char *command ; + int commandLength ; + int iExpectedReplyLength ; +} tristate_gps01_command_sequence[] = +{ + { 0, NULL, 0, 0 }, /* Idle */ + { TS_GPS01_COMMAND_NUMBER_STUS, "stus\r\n", 6, TS_GPS01_REPLY_LENGTH_STUS }, + { TS_GPS01_COMMAND_NUMBER_TIME, "time\r\n", 6, TS_GPS01_REPLY_LENGTH_TIME }, + { TS_GPS01_COMMAND_NUMBER_DATE, "date\r\n", 6, TS_GPS01_REPLY_LENGTH_DATE }, + { TS_GPS01_COMMAND_NUMBER_TIME, "time\r\n", 6, TS_GPS01_REPLY_LENGTH_TIME }, + /* End of command */ + { 0, NULL, 0, 0 } +} ; + +/**************************************************************************************************/ + +static int +jjy_start_tristate_gpsclock01 ( int unit, struct peer *peer, struct jjyunit *up ) +{ + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, "Refclock: Tristate Ltd. TS-GPS01" ) ; + + up->unittype = UNITTYPE_TRISTATE_GPSCLOCK01 ; + up->linespeed = SPEED232_TRISTATE_GPSCLOCK01 ; + up->linediscipline = LDISC_CLK ; + + return 0 ; + +} + +/**************************************************************************************************/ + +static int +jjy_receive_tristate_gpsclock01 ( struct recvbuf *rbufp ) +{ +#ifdef DEBUG + static const char *sFunctionName = "jjy_receive_tristate_gpsclock01" ; +#endif + + struct jjyunit *up ; + struct refclockproc *pp ; + struct peer *peer; + + char *pBuf, sLog [ 100 ] ; + int iLen ; + int rc ; + + const char *pCmd ; + int iCmdLen ; + + /* Initialize pointers */ + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + DEBUG_PRINTF_JJY_RECEIVE( "jjy_receive_tristate_gpsclock01", iLen ) ; + + /* Ignore NMEA data stream */ + + if ( iLen > 5 + && ( strncmp( pBuf, "$GP", 3 ) == 0 || strncmp( pBuf, "$PFEC", 5 ) == 0 ) ) { +#ifdef DEBUG + if ( debug ) { + printf ( "%s (refclock_jjy.c) : Skip NMEA stream [%s]\n", + sFunctionName, pBuf ) ; + } +#endif + return JJY_RECEIVE_WAIT ; + } + + /* + * Skip command prompt '$Cmd>' from the TS-GPSclock-01 + */ + if ( iLen == 5 && strncmp( pBuf, "$Cmd>", 5 ) == 0 ) { + return JJY_RECEIVE_WAIT ; + } else if ( iLen > 5 && strncmp( pBuf, "$Cmd>", 5 ) == 0 ) { + pBuf += 5 ; + iLen -= 5 ; + } + + /* + * Ignore NMEA data stream after command prompt + */ + if ( iLen > 5 + && ( strncmp( pBuf, "$GP", 3 ) == 0 || strncmp( pBuf, "$PFEC", 5 ) == 0 ) ) { +#ifdef DEBUG + if ( debug ) { + printf ( "%s (refclock_jjy.c) : Skip NMEA stream [%s]\n", + sFunctionName, pBuf ) ; + } +#endif + return JJY_RECEIVE_WAIT ; + } + + /* Check expected reply */ + + if ( tristate_gps01_command_sequence[up->iCommandSeq].command == NULL ) { + /* Command sequence has not been started, or has been completed */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_UNEXPECTED_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + /* Check reply length */ + + if ( iLen != tristate_gps01_command_sequence[up->iCommandSeq].iExpectedReplyLength ) { + /* Unexpected reply length */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_LENGTH, + iLen ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + /* Parse reply */ + + switch ( tristate_gps01_command_sequence[up->iCommandSeq].commandNumber ) { + + case TS_GPS01_COMMAND_NUMBER_DATE : /* YYYY/MM/DD */ + + rc = sscanf ( pBuf, "%4d/%2d/%2d", &up->year, &up->month, &up->day ) ; + + if ( rc != 3 || up->year < 2000 || 2099 <= up->year + || up->month < 1 || 12 < up->month + || up->day < 1 || 31 < up->day ) { + /* Invalid date */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATE, + rc, up->year, up->month, up->day ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + break ; + + case TS_GPS01_COMMAND_NUMBER_TIME : /* HH:MM:SS */ + + if ( up->iTimestampCount >= 2 ) { + /* Too many time reply */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_TOO_MANY_REPLY, + up->iTimestampCount ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + rc = sscanf ( pBuf, "%2d:%2d:%2d", + &up->hour, &up->minute, &up->second ) ; + + if ( rc != 3 + || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + /* Invalid time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_TIME, + rc, up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + up->iTimestamp[up->iTimestampCount] = ( up->hour * 60 + up->minute ) * 60 + up->second ; + + up->iTimestampCount++ ; + + up->msecond = 0 ; + + break ; + + case TS_GPS01_COMMAND_NUMBER_STUS : + + if ( strncmp( pBuf, TS_GPS01_REPLY_STUS_RTC, TS_GPS01_REPLY_LENGTH_STUS ) == 0 + || strncmp( pBuf, TS_GPS01_REPLY_STUS_GPS, TS_GPS01_REPLY_LENGTH_STUS ) == 0 + || strncmp( pBuf, TS_GPS01_REPLY_STUS_UTC, TS_GPS01_REPLY_LENGTH_STUS ) == 0 + || strncmp( pBuf, TS_GPS01_REPLY_STUS_PPS, TS_GPS01_REPLY_LENGTH_STUS ) == 0 ) { + /* Good */ + } else { + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + break ; + + default : /* Unexpected reply */ + + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + + } + + if ( up->iTimestampCount == 2 ) { + /* Process date and time */ + + if ( up->iTimestamp[1] - 2 <= up->iTimestamp[0] + && up->iTimestamp[0] <= up->iTimestamp[1] ) { + /* 3 commands (time,date,stim) was excuted in two seconds */ + jjy_synctime( peer, pp, up ) ; + return JJY_RECEIVE_DONE ; + } else if ( up->iTimestamp[0] > up->iTimestamp[1] ) { + /* Over midnight, and date is unsure */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_OVER_MIDNIGHT_2, + up->iTimestamp[0], up->iTimestamp[1] ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_INFORMATION, sLog ) ; + return JJY_RECEIVE_SKIP ; + } else { + /* Slow reply */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SLOW_REPLY_2, + up->iTimestamp[0], up->iTimestamp[1] ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + } + + if ( tristate_gps01_command_sequence[up->iCommandSeq].command == NULL ) { + /* Command sequence completed */ + jjy_synctime( peer, pp, up ) ; + return JJY_RECEIVE_DONE ; + } + + /* Issue next command */ + + if ( tristate_gps01_command_sequence[up->iCommandSeq].command != NULL ) { + up->iCommandSeq ++ ; + } + + if ( tristate_gps01_command_sequence[up->iCommandSeq].command == NULL ) { + /* Command sequence completed */ + up->iProcessState = JJY_PROCESS_STATE_DONE ; + return JJY_RECEIVE_DONE ; + } + + pCmd = tristate_gps01_command_sequence[up->iCommandSeq].command ; + iCmdLen = tristate_gps01_command_sequence[up->iCommandSeq].commandLength ; + if ( write ( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report ( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + + return JJY_RECEIVE_WAIT ; + +} + +/**************************************************************************************************/ + +static void +jjy_poll_tristate_gpsclock01 ( int unit, struct peer *peer ) +{ +#ifdef DEBUG + static const char *sFunctionName = "jjy_poll_tristate_gpsclock01" ; +#endif + + struct refclockproc *pp ; + struct jjyunit *up ; + + const char *pCmd ; + int iCmdLen ; + + pp = peer->procptr ; + up = pp->unitptr ; + + up->iTimestampCount = 0 ; + + if ( ( pp->sloppyclockflag & CLK_FLAG1 ) == 0 ) { + /* Skip "stus" command */ + up->iCommandSeq = 1 ; + up->iLineCount = 1 ; + } + +#ifdef DEBUG + if ( debug ) { + printf ( "%s (refclock_jjy.c) : flag1=%X CLK_FLAG1=%X up->iLineCount=%d\n", + sFunctionName, pp->sloppyclockflag, CLK_FLAG1, + up->iLineCount ) ; + } +#endif + + /* + * Send a first command + */ + + up->iCommandSeq ++ ; + + pCmd = tristate_gps01_command_sequence[up->iCommandSeq].command ; + iCmdLen = tristate_gps01_command_sequence[up->iCommandSeq].commandLength ; + if ( write ( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report ( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## The SEIKO TIME SYSTEMS TDC-300 ##*/ +/*## ##*/ +/*## server 127.127.40.X mode 6 ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ +/* */ +/* Type Response Remarks */ +/* -------------------- ---------------------------------------- ---------------------------- */ +/* Type 1 HH:MM:SS */ +/* Type 2 YYMMDDHHMMSSWLSCU W:0(Sun)-6(Sat) */ +/* Type 3 YYMMDDWHHMMSS W:0(Sun)-6(Sat) */ +/* 5 to 10 mSec. before second */ +/* */ +/*################################################################################################*/ + +static struct jjyRawDataBreak seiko_tsys_tdc_300_raw_break [ ] = +{ + { "\x03", 1 }, { NULL, 0 } +} ; + +/**************************************************************************************************/ + +static int +jjy_start_seiko_tsys_tdc_300 ( int unit, struct peer *peer, struct jjyunit *up ) +{ + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, "Refclock: SEIKO TIME SYSTEMS TDC-300" ) ; + + up->unittype = UNITTYPE_SEIKO_TIMESYS_TDC_300 ; + up->linespeed = SPEED232_SEIKO_TIMESYS_TDC_300 ; + up->linediscipline = LDISC_RAW ; + + up->pRawBreak = seiko_tsys_tdc_300_raw_break ; + up->bWaitBreakString = TRUE ; + + up->bSkipCntrlCharOnly = FALSE ; + + return 0 ; + +} + +/**************************************************************************************************/ + +static int +jjy_receive_seiko_tsys_tdc_300 ( struct recvbuf *rbufp ) +{ + + struct peer *peer; + struct refclockproc *pp ; + struct jjyunit *up ; + + char *pBuf, sLog [ 100 ] ; + int iLen, i ; + int rc, iWeekday ; + time_t now ; + struct tm *pTime ; + + /* Initialize pointers */ + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + DEBUG_PRINTF_JJY_RECEIVE( "jjy_receive_seiko_tsys_tdc_300", iLen ) ; + + /* + * TDC-300 sends a timestamp every second. + * So, a timestamp is ignored unless it is right after polled. + */ + + if ( up->iProcessState != JJY_PROCESS_STATE_RECEIVE ) { + return JJY_RECEIVE_SKIP ; + } + + /* Process timestamp */ + + up->iReceiveSeq ++ ; + + switch ( iLen ) { + + case 8 : /* Type 1 : HH:MM:SS */ + + for ( i = 0 ; i < iLen ; i ++ ) { + pBuf[i] &= 0x7F ; + } + + rc = sscanf ( pBuf+1, "%2d:%2d:%2d", + &up->hour, &up->minute, &up->second ) ; + + if ( rc != 3 + || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + /* Invalid time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_TIME, + rc, up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } else if ( up->hour == 23 && up->minute == 59 && up->second >= 55 ) { + /* Uncertainty date guard */ + return JJY_RECEIVE_WAIT ; + } + + time( &now ) ; + pTime = localtime( &now ) ; + up->year = pTime->tm_year ; + up->month = pTime->tm_mon + 1 ; + up->day = pTime->tm_mday ; + + break ; + + case 17 : /* Type 2 : YYMMDDHHMMSSWLSCU */ + + for ( i = 0 ; i < iLen ; i ++ ) { + pBuf[i] &= 0x7F ; + } + + rc = sscanf ( pBuf+1, "%2d%2d%2d%2d%2d%2d%1d", + &up->year, &up->month, &up->day, + &up->hour, &up->minute, &up->second, &iWeekday ) ; + + if ( rc != 7 + || up->month < 1 || up->month > 12 || up->day < 1 || up->day > 31 + || iWeekday > 6 + || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + /* Invalid date and time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATETIME, + rc, up->year, up->month, up->day, + up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + break ; + + case 13 : /* Type 3 : YYMMDDWHHMMSS */ + + rc = sscanf ( pBuf, "%2d%2d%2d%1d%2d%2d%2d", + &up->year, &up->month, &up->day, &iWeekday, + &up->hour, &up->minute, &up->second ) ; + + if ( rc != 7 + || up->month < 1 || up->month > 12 || up->day < 1 || up->day > 31 + || iWeekday > 6 + || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + /* Invalid date and time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATETIME, + rc, up->year, up->month, up->day, + up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + return JJY_RECEIVE_WAIT ; + + case 1 : /* Type 3 : */ + + if ( ( *pBuf & 0xFF ) != 0xE5 ) { + /* Invalid second signal */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_REPLY, + up->sLineBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } else if ( up->iReceiveSeq == 1 ) { + /* Wait for next timestamp */ + up->iReceiveSeq -- ; + return JJY_RECEIVE_WAIT ; + } else if ( up->iReceiveSeq >= 3 ) { + /* Unexpected second signal */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_UNEXPECTED_REPLY, + up->sLineBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + } + + break ; + + default : /* Unexpected reply length */ + + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_INVALID_LENGTH, + iLen ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + return JJY_RECEIVE_ERROR ; + + } + + up->year += 2000 ; + up->msecond = 0 ; + + jjy_synctime( peer, pp, up ) ; + + return JJY_RECEIVE_DONE ; + +} + +/**************************************************************************************************/ + +static void +jjy_poll_seiko_tsys_tdc_300 ( int unit, struct peer *peer ) +{ + + struct refclockproc *pp ; + struct jjyunit *up ; + + pp = peer->procptr ; + up = pp->unitptr ; + + up->bLineError = FALSE ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## Telephone JJY ##*/ +/*## ##*/ +/*## server 127.127.40.X mode 100 to 180 ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ +/* */ +/* Prompt Command Response Remarks */ +/* -------------------- -------------------- -------------------- -------------------------- */ +/* Name? TJJY Welcome messages TJJY is a guest user ID */ +/* > 4DATE YYYYMMDD */ +/* > LEAPSEC XX One of 0, +1, -1 */ +/* > TIME HHMMSS 3 times on second */ +/* > BYE Sayounara messages */ +/* */ +/*################################################################################################*/ + +static struct jjyRawDataBreak teljjy_raw_break [ ] = +{ + { "\r\n", 2 }, + { "\r" , 1 }, + { "\n" , 1 }, + { "Name ? ", 7 }, + { ">" , 1 }, + { "+++" , 3 }, + { NULL , 0 } +} ; + +#define TELJJY_STATE_IDLE 0 +#define TELJJY_STATE_DAILOUT 1 +#define TELJJY_STATE_LOGIN 2 +#define TELJJY_STATE_CONNECT 3 +#define TELJJY_STATE_BYE 4 + +#define TELJJY_EVENT_NULL 0 +#define TELJJY_EVENT_START 1 +#define TELJJY_EVENT_CONNECT 2 +#define TELJJY_EVENT_DISCONNECT 3 +#define TELJJY_EVENT_COMMAND 4 +#define TELJJY_EVENT_LOGIN 5 /* Posted by the jjy_receive_telephone */ +#define TELJJY_EVENT_PROMPT 6 /* Posted by the jjy_receive_telephone */ +#define TELJJY_EVENT_DATA 7 /* Posted by the jjy_receive_telephone */ +#define TELJJY_EVENT_ERROR 8 /* Posted by the jjy_receive_telephone */ +#define TELJJY_EVENT_SILENT 9 /* Posted by the jjy_timer_telephone */ +#define TELJJY_EVENT_TIMEOUT 10 /* Posted by the jjy_timer_telephone */ + +static void teljjy_control ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; + +static int teljjy_idle_ignore ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_idle_dialout ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_dial_ignore ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_dial_login ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_dial_disc ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_login_ignore ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_login_disc ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_login_conn ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_login_login ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_login_silent ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_login_error ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_conn_ignore ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_conn_disc ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_conn_send ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_conn_data ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_conn_silent ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_conn_error ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_bye_ignore ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_bye_disc ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; +static int teljjy_bye_modem ( struct peer *peer, struct refclockproc *, struct jjyunit * ) ; + +static int ( *pTeljjyHandler [ ] [ 5 ] ) ( ) = +{ /*STATE_IDLE STATE_DAILOUT STATE_LOGIN STATE_CONNECT STATE_BYE */ +/* NULL */ { teljjy_idle_ignore , teljjy_dial_ignore, teljjy_login_ignore, teljjy_conn_ignore, teljjy_bye_ignore }, +/* START */ { teljjy_idle_dialout, teljjy_dial_ignore, teljjy_login_ignore, teljjy_conn_ignore, teljjy_bye_ignore }, +/* CONNECT */ { teljjy_idle_ignore , teljjy_dial_login , teljjy_login_ignore, teljjy_conn_ignore, teljjy_bye_ignore }, +/* DISCONNECT */ { teljjy_idle_ignore , teljjy_dial_disc , teljjy_login_disc , teljjy_conn_disc , teljjy_bye_disc }, +/* COMMAND */ { teljjy_idle_ignore , teljjy_dial_ignore, teljjy_login_ignore, teljjy_conn_ignore, teljjy_bye_modem }, +/* LOGIN */ { teljjy_idle_ignore , teljjy_dial_ignore, teljjy_login_login , teljjy_conn_error , teljjy_bye_ignore }, +/* PROMPT */ { teljjy_idle_ignore , teljjy_dial_ignore, teljjy_login_conn , teljjy_conn_send , teljjy_bye_ignore }, +/* DATA */ { teljjy_idle_ignore , teljjy_dial_ignore, teljjy_login_ignore, teljjy_conn_data , teljjy_bye_ignore }, +/* ERROR */ { teljjy_idle_ignore , teljjy_dial_ignore, teljjy_login_error , teljjy_conn_error , teljjy_bye_ignore }, +/* SILENT */ { teljjy_idle_ignore , teljjy_dial_ignore, teljjy_login_silent, teljjy_conn_silent, teljjy_bye_ignore }, +/* TIMEOUT */ { teljjy_idle_ignore , teljjy_dial_disc , teljjy_login_error , teljjy_conn_error , teljjy_bye_modem } +} ; + +static short iTeljjyNextState [ ] [ 5 ] = +{ /*STATE_IDLE STATE_DAILOUT STATE_LOGIN STATE_CONNECT STATE_BYE */ +/* NULL */ { TELJJY_STATE_IDLE , TELJJY_STATE_DAILOUT, TELJJY_STATE_LOGIN , TELJJY_STATE_CONNECT, TELJJY_STATE_BYE }, +/* START */ { TELJJY_STATE_DAILOUT, TELJJY_STATE_DAILOUT, TELJJY_STATE_LOGIN , TELJJY_STATE_CONNECT, TELJJY_STATE_BYE }, +/* CONNECT */ { TELJJY_STATE_IDLE , TELJJY_STATE_LOGIN , TELJJY_STATE_LOGIN , TELJJY_STATE_CONNECT, TELJJY_STATE_BYE }, +/* DISCONNECT */ { TELJJY_STATE_IDLE , TELJJY_STATE_IDLE , TELJJY_STATE_IDLE , TELJJY_STATE_IDLE , TELJJY_STATE_IDLE }, +/* COMMAND */ { TELJJY_STATE_IDLE , TELJJY_STATE_DAILOUT, TELJJY_STATE_LOGIN , TELJJY_STATE_CONNECT, TELJJY_STATE_BYE }, +/* LOGIN */ { TELJJY_STATE_IDLE , TELJJY_STATE_DAILOUT, TELJJY_STATE_LOGIN , TELJJY_STATE_BYE , TELJJY_STATE_BYE }, +/* PROMPT */ { TELJJY_STATE_IDLE , TELJJY_STATE_DAILOUT, TELJJY_STATE_CONNECT, TELJJY_STATE_BYE , TELJJY_STATE_BYE }, +/* DATA */ { TELJJY_STATE_IDLE , TELJJY_STATE_DAILOUT, TELJJY_STATE_LOGIN , TELJJY_STATE_CONNECT, TELJJY_STATE_BYE }, +/* ERROR */ { TELJJY_STATE_IDLE , TELJJY_STATE_DAILOUT, TELJJY_STATE_BYE , TELJJY_STATE_BYE , TELJJY_STATE_BYE }, +/* SILENT */ { TELJJY_STATE_IDLE , TELJJY_STATE_DAILOUT, TELJJY_STATE_LOGIN , TELJJY_STATE_CONNECT, TELJJY_STATE_BYE }, +/* TIMEOUT */ { TELJJY_STATE_IDLE , TELJJY_STATE_IDLE , TELJJY_STATE_BYE , TELJJY_STATE_BYE , TELJJY_STATE_BYE } +} ; + +static short iTeljjyPostEvent [ ] [ 5 ] = +{ /*STATE_IDLE STATE_DAILOUT STATE_LOGIN STATE_CONNECT STATE_BYE */ +/* NULL */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_NULL , TELJJY_EVENT_NULL }, +/* START */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_NULL , TELJJY_EVENT_NULL }, +/* CONNECT */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_NULL , TELJJY_EVENT_NULL }, +/* DISCONNECT */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_NULL , TELJJY_EVENT_NULL }, +/* COMMAND */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_NULL , TELJJY_EVENT_NULL }, +/* LOGIN */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_COMMAND, TELJJY_EVENT_NULL }, +/* PROMPT */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_PROMPT , TELJJY_EVENT_COMMAND, TELJJY_EVENT_NULL }, +/* DATA */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_NULL , TELJJY_EVENT_NULL }, +/* ERROR */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_COMMAND, TELJJY_EVENT_COMMAND, TELJJY_EVENT_NULL }, +/* SILENT */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_NULL , TELJJY_EVENT_NULL , TELJJY_EVENT_NULL }, +/* TIMEOUT */ { TELJJY_EVENT_NULL, TELJJY_EVENT_NULL, TELJJY_EVENT_COMMAND, TELJJY_EVENT_COMMAND, TELJJY_EVENT_NULL } +} ; + +static short iTeljjySilentTimeout [ 5 ] = { 0, 0, 10, 5, 0 } ; +static short iTeljjyStateTimeout [ 5 ] = { 0, 120, 60, 60, 40 } ; + +#define TELJJY_STAY_CLOCK_STATE 0 +#define TELJJY_CHANGE_CLOCK_STATE 1 + +/* Command and replay */ + +#define TELJJY_REPLY_NONE 0 +#define TELJJY_REPLY_4DATE 1 +#define TELJJY_REPLY_TIME 2 +#define TELJJY_REPLY_LEAPSEC 3 +#define TELJJY_REPLY_LOOP 4 +#define TELJJY_REPLY_PROMPT 5 +#define TELJJY_REPLY_LOOPBACK 6 +#define TELJJY_REPLY_COM 7 + +#define TELJJY_COMMAND_START_SKIP_LOOPBACK 7 + +static struct +{ + const char *command ; + int commandLength ; + int iEchobackReplyLength ; + int iExpectedReplyType ; + int iExpectedReplyLength ; +} teljjy_command_sequence[] = +{ + { NULL, 0, 0, 0, 0 }, /* Idle */ + { "LOOP\r" , 5, 4, TELJJY_REPLY_LOOP , 0 }, /* Getting into loopback mode */ + { ">" , 1, 1, TELJJY_REPLY_LOOPBACK, 0 }, /* Loopback measuring of delay time */ + { ">" , 1, 1, TELJJY_REPLY_LOOPBACK, 0 }, /* Loopback measuring of delay time */ + { ">" , 1, 1, TELJJY_REPLY_LOOPBACK, 0 }, /* Loopback measuring of delay time */ + { ">" , 1, 1, TELJJY_REPLY_LOOPBACK, 0 }, /* Loopback measuring of delay time */ + { ">" , 1, 1, TELJJY_REPLY_LOOPBACK, 0 }, /* Loopback measuring of delay time */ + { "COM\r" , 4, 3, TELJJY_REPLY_COM , 0 }, /* Exit from loopback mode */ + /* TELJJY_COMMAND_START_SKIP_LOOPBACK */ + { "TIME\r" , 5, 4, TELJJY_REPLY_TIME , 6 }, + { "4DATE\r" , 6, 5, TELJJY_REPLY_4DATE , 8 }, + { "LEAPSEC\r", 8, 7, TELJJY_REPLY_LEAPSEC , 2 }, + { "TIME\r" , 5, 4, TELJJY_REPLY_TIME , 6 }, + { "BYE\r" , 4, 3, TELJJY_REPLY_NONE , 0 }, + /* End of command */ + { NULL, 0, 0, 0, 0 } +} ; + +#define TELJJY_LOOPBACK_DELAY_THRESHOLD 700 /* Milli second */ + +#ifdef DEBUG +#define DEBUG_TELJJY_PRINTF(sFunc) { if ( debug ) { printf ( "refclock_jjy.c : %s : iClockState=%d iClockEvent=%d iTeljjySilentTimer=%d iTeljjyStateTimer=%d iClockCommandSeq=%d\n", sFunc, up->iClockState, up->iClockEvent, up->iTeljjySilentTimer, up->iTeljjyStateTimer, up->iClockCommandSeq ) ; } } +#else +#define DEBUG_TELJJY_PRINTF(sFunc) +#endif + +/**************************************************************************************************/ + +static int +jjy_start_telephone ( int unit, struct peer *peer, struct jjyunit *up ) +{ + + char sLog [ 80 ], sFirstThreeDigits [ 4 ] ; + int i, iNumberOfDigitsOfPhoneNumber, iCommaCount, iCommaPosition ; + int iFirstThreeDigitsCount ; + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, "Refclock: Telephone JJY" ) ; + + up->unittype = UNITTYPE_TELEPHONE ; + up->linespeed = SPEED232_TELEPHONE ; + up->linediscipline = LDISC_RAW ; + + up->pRawBreak = teljjy_raw_break ; + up->bWaitBreakString = TRUE ; + + up->bSkipCntrlCharOnly = TRUE ; + + up->iClockState = TELJJY_STATE_IDLE ; + up->iClockEvent = TELJJY_EVENT_NULL ; + + /* Check the telephone number */ + + if ( sys_phone[0] == NULL ) { + msyslog( LOG_ERR, "refclock_jjy.c : jjy_start_telephone : phone in the ntpd.conf must be specified." ) ; + up->bInitError = TRUE ; + return 1 ; + } + + if ( sys_phone[1] != NULL ) { + msyslog( LOG_ERR, "refclock_jjy.c : jjy_start_telephone : phone in the ntpd.conf should be only one." ) ; + up->bInitError = TRUE ; + return 1 ; + } + + iNumberOfDigitsOfPhoneNumber = iCommaCount = iCommaPosition = iFirstThreeDigitsCount = 0 ; + for ( i = 0 ; i < strlen( sys_phone[0] ) ; i ++ ) { + if ( isdigit( *(sys_phone[0]+i) ) ) { + if ( iFirstThreeDigitsCount < sizeof(sFirstThreeDigits)-1 ) { + sFirstThreeDigits[iFirstThreeDigitsCount++] = *(sys_phone[0]+i) ; + } + iNumberOfDigitsOfPhoneNumber ++ ; + } else if ( *(sys_phone[0]+i) == ',' ) { + iCommaCount ++ ; + if ( iCommaCount > 1 ) { + msyslog( LOG_ERR, "refclock_jjy.c : jjy_start_telephone : phone in the ntpd.conf should be zero or one comma." ) ; + up->bInitError = TRUE ; + return 1 ; + } + iFirstThreeDigitsCount = 0 ; + iCommaPosition = i ; + } else if ( *(sys_phone[0]+i) != '-' ) { + msyslog( LOG_ERR, "refclock_jjy.c : jjy_start_telephone : phone in the ntpd.conf should be a number or a hyphen." ) ; + up->bInitError = TRUE ; + return 1 ; + } + } + sFirstThreeDigits[iFirstThreeDigitsCount] = 0 ; + + if ( iCommaCount == 1 ) { + if ( iCommaPosition != 1 || *sys_phone[0] != '0' ) { + msyslog( LOG_ERR, "refclock_jjy.c : jjy_start_telephone : Getting an outside line should be '0,'." ) ; + up->bInitError = TRUE ; + return 1 ; + } + } + + if ( iNumberOfDigitsOfPhoneNumber - iCommaPosition < 6 || 10 < iNumberOfDigitsOfPhoneNumber - iCommaPosition ) { + /* Too short or too long */ + msyslog( LOG_ERR, "refclock_jjy.c : jjy_start_telephone : phone=%s : Number of digits should be 6 to 10.", sys_phone[0] ) ; + up->bInitError = TRUE ; + return 1 ; + } + + if ( strncmp( sFirstThreeDigits + iCommaPosition, "00" , 2 ) == 0 + || strncmp( sFirstThreeDigits + iCommaPosition, "10" , 2 ) == 0 + || strncmp( sFirstThreeDigits + iCommaPosition, "11" , 2 ) == 0 + || strncmp( sFirstThreeDigits + iCommaPosition, "12" , 2 ) == 0 + || strncmp( sFirstThreeDigits + iCommaPosition, "171", 3 ) == 0 + || strncmp( sFirstThreeDigits + iCommaPosition, "177", 3 ) == 0 + || ( sFirstThreeDigits[0] == '0' && sFirstThreeDigits[2] == '0' ) ) { + /* Not allowed because of emergency numbers or special service numbers */ + msyslog( LOG_ERR, "refclock_jjy.c : jjy_start_telephone : phone=%s : First 2 or 3 digits are not allowed.", sys_phone[0] ) ; + up->bInitError = TRUE ; + return 1 ; + } + + snprintf( sLog, sizeof(sLog), "phone=%s", sys_phone[0] ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, sLog ) ; + + if ( peer->minpoll < 8 ) { + /* minpoll must be greater or equal to 8 ( 256 seconds = about 4 minutes ) */ + int oldminpoll = peer->minpoll ; + peer->minpoll = 8 ; + if ( peer->ppoll < peer->minpoll ) { + peer->ppoll = peer->minpoll ; + } + if ( peer->maxpoll < peer->minpoll ) { + peer->maxpoll = peer->minpoll ; + } + snprintf( sLog, sizeof(sLog), "minpoll=%d -> %d", oldminpoll, peer->minpoll ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_JJY, sLog ) ; + } + + return 0 ; + +} + +/**************************************************************************************************/ + +static int +jjy_receive_telephone ( struct recvbuf *rbufp ) +{ +#ifdef DEBUG + static const char *sFunctionName = "jjy_receive_telephone" ; +#endif + + struct peer *peer; + struct refclockproc *pp ; + struct jjyunit *up ; + char *pBuf ; + int iLen ; + short iPreviousModemState ; + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + DEBUG_TELJJY_PRINTF( sFunctionName ) ; + + if ( up->iClockState == TELJJY_STATE_IDLE + || up->iClockState == TELJJY_STATE_DAILOUT + || up->iClockState == TELJJY_STATE_BYE ) { + + iPreviousModemState = getModemState( up ) ; + + modem_receive ( rbufp ) ; + + if ( iPreviousModemState != up->iModemState ) { + /* Modem state is changed just now. */ + if ( isModemStateDisconnect( up->iModemState ) ) { + up->iClockEvent = TELJJY_EVENT_DISCONNECT ; + teljjy_control ( peer, pp, up ) ; + } else if ( isModemStateConnect( up->iModemState ) ) { + up->iClockEvent = TELJJY_EVENT_CONNECT ; + teljjy_control ( peer, pp, up ) ; + } + } + + return JJY_RECEIVE_WAIT ; + + } + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + up->iTeljjySilentTimer = 0 ; + if ( iLen == 7 && strncmp( pBuf, "Name ? ", 7 ) == 0 ) { up->iClockEvent = TELJJY_EVENT_LOGIN ; } + else if ( iLen == 1 && strncmp( pBuf, ">" , 1 ) == 0 ) { up->iClockEvent = TELJJY_EVENT_PROMPT ; } + else if ( iLen >= 1 && strncmp( pBuf, "?" , 1 ) == 0 ) { up->iClockEvent = TELJJY_EVENT_ERROR ; } + else { up->iClockEvent = TELJJY_EVENT_DATA ; } + + teljjy_control ( peer, pp, up ) ; + + return JJY_RECEIVE_WAIT ; + +} + +/**************************************************************************************************/ + +static void +jjy_poll_telephone ( int unit, struct peer *peer ) +{ +#ifdef DEBUG + static const char *sFunctionName = "jjy_poll_telephone" ; +#endif + + struct refclockproc *pp ; + struct jjyunit *up ; + + pp = peer->procptr ; + up = pp->unitptr ; + + DEBUG_TELJJY_PRINTF( sFunctionName ) ; + + if ( up->iClockState == TELJJY_STATE_IDLE ) { + up->iRawBufLen = 0 ; + up->iLineBufLen = 0 ; + up->iTextBufLen = 0 ; + } + + up->iClockEvent = TELJJY_EVENT_START ; + teljjy_control ( peer, pp, up ) ; + +} + +/**************************************************************************************************/ + +static void +jjy_timer_telephone ( int unit, struct peer *peer ) +{ +#ifdef DEBUG + static const char *sFunctionName = "jjy_timer_telephone" ; +#endif + + struct refclockproc *pp ; + struct jjyunit *up ; + short iPreviousModemState ; + + pp = peer->procptr ; + up = pp->unitptr ; + + DEBUG_TELJJY_PRINTF( sFunctionName ) ; + + if ( iTeljjySilentTimeout[up->iClockState] != 0 ) { + up->iTeljjySilentTimer++ ; + if ( iTeljjySilentTimeout[up->iClockState] <= up->iTeljjySilentTimer ) { + up->iClockEvent = TELJJY_EVENT_SILENT ; + teljjy_control ( peer, pp, up ) ; + } + } + + if ( iTeljjyStateTimeout[up->iClockState] != 0 ) { + up->iTeljjyStateTimer++ ; + if ( iTeljjyStateTimeout[up->iClockState] <= up->iTeljjyStateTimer ) { + up->iClockEvent = TELJJY_EVENT_TIMEOUT ; + teljjy_control ( peer, pp, up ) ; + } + } + + if ( isModemStateTimerOn( up ) ) { + + iPreviousModemState = getModemState( up ) ; + + modem_timer ( unit, peer ) ; + + if ( iPreviousModemState != up->iModemState ) { + /* Modem state is changed just now. */ + if ( isModemStateDisconnect( up->iModemState ) ) { + up->iClockEvent = TELJJY_EVENT_DISCONNECT ; + teljjy_control ( peer, pp, up ) ; + } else if ( isModemStateConnect( up->iModemState ) ) { + up->iClockEvent = TELJJY_EVENT_CONNECT ; + teljjy_control ( peer, pp, up ) ; + } + } + + } + +} + +/**************************************************************************************************/ + +static void +teljjy_control ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + int i, rc ; + short iPostEvent = TELJJY_EVENT_NULL ; + + DEBUG_TELJJY_PRINTF( "teljjy_control" ) ; + + rc = (*pTeljjyHandler[up->iClockEvent][up->iClockState])( peer, pp, up ) ; + + if ( rc == TELJJY_CHANGE_CLOCK_STATE ) { + iPostEvent = iTeljjyPostEvent[up->iClockEvent][up->iClockState] ; +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : teljjy_control : iClockState=%hd -> %hd iPostEvent=%hd\n", + up->iClockState, iTeljjyNextState[up->iClockEvent][up->iClockState], iPostEvent ) ; + } +#endif + up->iTeljjySilentTimer = 0 ; + if ( up->iClockState != iTeljjyNextState[up->iClockEvent][up->iClockState] ) { + /* Telephone JJY state is changing now */ + up->iTeljjyStateTimer = 0 ; + up->bLineError = FALSE ; + up->iClockCommandSeq = 0 ; + up->iTimestampCount = 0 ; + up->iLoopbackCount = 0 ; + for ( i = 0 ; i < MAX_LOOPBACK ; i ++ ) { + up->bLoopbackTimeout[i] = FALSE ; + } + if (iTeljjyNextState[up->iClockEvent][up->iClockState] == TELJJY_STATE_IDLE ) { + /* Telephone JJY state is changing to IDLE just now */ + up->iProcessState = JJY_PROCESS_STATE_DONE ; + } + } + up->iClockState = iTeljjyNextState[up->iClockEvent][up->iClockState] ; + + } + + if ( iPostEvent != TELJJY_EVENT_NULL ) { + up->iClockEvent = iPostEvent ; + teljjy_control ( peer, pp, up ) ; + } + + up->iClockEvent = TELJJY_EVENT_NULL ; + +} + +/**************************************************************************************************/ + +static void +teljjy_setDelay ( struct peer *peer, struct jjyunit *up ) +{ + + char sLog [ 60 ] ; + int milliSecond, microSecond ; + + gettimeofday( &(up->delayTime[up->iLoopbackCount]), NULL ) ; + + up->delayTime[up->iLoopbackCount].tv_sec -= up->sendTime[up->iLoopbackCount].tv_sec ; + up->delayTime[up->iLoopbackCount].tv_usec -= up->sendTime[up->iLoopbackCount].tv_usec ; + if ( up->delayTime[up->iLoopbackCount].tv_usec < 0 ) { + up->delayTime[up->iLoopbackCount].tv_sec -- ; + up->delayTime[up->iLoopbackCount].tv_usec += 1000000 ; + } + + milliSecond = up->delayTime[up->iLoopbackCount].tv_usec / 1000 ; + microSecond = up->delayTime[up->iLoopbackCount].tv_usec - milliSecond * 1000 ; + milliSecond += up->delayTime[up->iLoopbackCount].tv_sec * 1000 ; + + snprintf( sLog, sizeof(sLog), JJY_CLOCKSTATS_MESSAGE_LOOPBACK_DELAY, + milliSecond, microSecond ) ; + + if ( milliSecond > TELJJY_LOOPBACK_DELAY_THRESHOLD ) { + /* Delay > 700 mS */ + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_WARNING, sLog ) ; + } else { + /* Delay <= 700 mS */ + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_INFORMATION, sLog ) ; + } + +} + +/**************************************************************************************************/ + +static int +teljjy_getDelay ( struct peer *peer, struct jjyunit *up ) +{ + + struct timeval maxTime, minTime, averTime ; + int i ; + int minIndex = 0, maxIndex = 0, iAverCount = 0 ; + int iThresholdSecond, iThresholdMicroSecond ; + int iPercent ; + + minTime.tv_sec = minTime.tv_usec = 0 ; + maxTime.tv_sec = maxTime.tv_usec = 0 ; + + iThresholdSecond = TELJJY_LOOPBACK_DELAY_THRESHOLD / 1000 ; + iThresholdMicroSecond = ( TELJJY_LOOPBACK_DELAY_THRESHOLD - ( TELJJY_LOOPBACK_DELAY_THRESHOLD / 1000 ) * 1000 ) * 1000 ; + + up->iLoopbackValidCount = 0 ; + + for ( i = 0 ; i < MAX_LOOPBACK && i < up->iLoopbackCount ; i ++ ) { + if ( up->bLoopbackTimeout[i] + || up->delayTime[i].tv_sec > iThresholdSecond + || ( up->delayTime[i].tv_sec == iThresholdSecond + && up->delayTime[i].tv_usec > iThresholdMicroSecond ) ) { + continue ; + } + if ( up->iLoopbackValidCount == 0 ) { + minTime.tv_sec = up->delayTime[i].tv_sec ; + minTime.tv_usec = up->delayTime[i].tv_usec ; + maxTime.tv_sec = up->delayTime[i].tv_sec ; + maxTime.tv_usec = up->delayTime[i].tv_usec ; + minIndex = maxIndex = i ; + } else if ( minTime.tv_sec > up->delayTime[i].tv_sec + || ( minTime.tv_sec == up->delayTime[i].tv_sec + && minTime.tv_usec > up->delayTime[i].tv_usec ) ) { + minTime.tv_sec = up->delayTime[i].tv_sec ; + minTime.tv_usec = up->delayTime[i].tv_usec ; + minIndex = i ; + } else if ( maxTime.tv_sec < up->delayTime[i].tv_sec + || ( maxTime.tv_sec == up->delayTime[i].tv_sec + && maxTime.tv_usec < up->delayTime[i].tv_usec ) ) { + maxTime.tv_sec = up->delayTime[i].tv_sec ; + maxTime.tv_usec = up->delayTime[i].tv_usec ; + maxIndex = i ; + } + up->iLoopbackValidCount ++ ; + } + + if ( up->iLoopbackValidCount < 2 ) { + return -1 ; + } + + averTime.tv_usec = 0; + + for ( i = 0 ; i < MAX_LOOPBACK && i < up->iLoopbackCount ; i ++ ) { + if ( up->bLoopbackTimeout[i] + || up->delayTime[i].tv_sec > iThresholdSecond + || ( up->delayTime[i].tv_sec == iThresholdSecond + && up->delayTime[i].tv_usec > iThresholdMicroSecond ) ) { + continue ; + } + if ( up->iLoopbackValidCount >= 3 && i == maxIndex ) { + continue ; + } + if ( up->iLoopbackValidCount >= 4 && i == minIndex ) { + continue ; + } + averTime.tv_usec += up->delayTime[i].tv_usec ; + iAverCount ++ ; + } + + if ( iAverCount == 0 ) { + /* This is never happened. */ + /* Previous for-if-for blocks assure iAverCount > 0. */ + /* This code avoids a claim by the coverity scan tool. */ + return -1 ; + } + + /* mode 101 = 1%, mode 150 = 50%, mode 180 = 80% */ + + iPercent = ( peer->ttl - 100 ) ; + + /* Average delay time in milli second */ + + return ( ( averTime.tv_usec / iAverCount ) * iPercent ) / 100000 ; + +} + +/******************************/ +static int +teljjy_idle_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_idle_ignore" ) ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_idle_dialout ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_idle_dialout" ) ; + + modem_connect ( peer->refclkunit, peer ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_dial_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_dial_ignore" ) ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_dial_login ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_dial_login" ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_dial_disc ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_dial_disc" ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_login_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_login_ignore" ) ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_login_disc ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_login_disc" ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_login_conn ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + int i ; + + DEBUG_TELJJY_PRINTF( "teljjy_login_conn" ) ; + + up->bLineError = FALSE ; + up->iClockCommandSeq = 0 ; + up->iTimestampCount = 0 ; + up->iLoopbackCount = 0 ; + for ( i = 0 ; i < MAX_LOOPBACK ; i ++ ) { + up->bLoopbackTimeout[i] = FALSE ; + } + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_login_login ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + char *pCmd ; + int iCmdLen ; + + DEBUG_TELJJY_PRINTF( "teljjy_login_login" ) ; + + /* Send a guest user ID */ + pCmd = "TJJY\r" ; + + /* Send login ID */ + iCmdLen = strlen( pCmd ) ; + if ( write( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_login_silent ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_login_silent" ) ; + + if ( write( pp->io.fd, "\r", 1 ) != 1 ) { + refclock_report( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, "\r" ) ; + + up->iTeljjySilentTimer = 0 ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_login_error ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_login_error" ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_conn_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_conn_ignore" ) ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_conn_disc ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_conn_disc" ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_conn_send ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + const char *pCmd ; + int i, iLen, iNextClockState ; + + DEBUG_TELJJY_PRINTF( "teljjy_conn_send" ) ; + + if ( up->iClockCommandSeq > 0 + && teljjy_command_sequence[up->iClockCommandSeq].command == NULL ) { + /* Command sequence has been completed */ + return TELJJY_CHANGE_CLOCK_STATE ; + } + + if ( up->iClockCommandSeq == 0 && peer->ttl == 100 ) { + /* Skip loopback */ + + up->iClockCommandSeq = TELJJY_COMMAND_START_SKIP_LOOPBACK ; + + } else if ( up->iClockCommandSeq == 0 && peer->ttl != 100 ) { + /* Loopback start */ + + up->iLoopbackCount = 0 ; + for ( i = 0 ; i < MAX_LOOPBACK ; i ++ ) { + up->bLoopbackTimeout[i] = FALSE ; + } + + } else if ( up->iClockCommandSeq > 0 && peer->ttl != 100 + && teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_LOOPBACK + && up->iLoopbackCount < MAX_LOOPBACK ) { + /* Loopback character comes */ +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : teljjy_conn_send : iLoopbackCount=%d\n", + up->iLoopbackCount ) ; + } +#endif + + teljjy_setDelay( peer, up ) ; + + up->iLoopbackCount ++ ; + + } + + up->iClockCommandSeq++ ; + + pCmd = teljjy_command_sequence[up->iClockCommandSeq].command ; + iLen = teljjy_command_sequence[up->iClockCommandSeq].commandLength ; + + if ( pCmd != NULL ) { + + if ( write( pp->io.fd, pCmd, iLen ) != iLen ) { + refclock_report( peer, CEVNT_FAULT ) ; + } + + if ( teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_LOOPBACK ) { + /* Loopback character and timestamp */ + gettimeofday( &(up->sendTime[up->iLoopbackCount]), NULL ) ; + up->bLoopbackMode = TRUE ; + } else { + /* Regular command */ + up->bLoopbackMode = FALSE ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + + if ( teljjy_command_sequence[up->iClockCommandSeq+1].command == NULL ) { + /* Last command of the command sequence */ + iNextClockState = TELJJY_CHANGE_CLOCK_STATE ; + } else { + /* More commands to be issued */ + iNextClockState = TELJJY_STAY_CLOCK_STATE ; + } + + } else { + + iNextClockState = TELJJY_CHANGE_CLOCK_STATE ; + + } + + return iNextClockState ; + +} + +/******************************/ +static int +teljjy_conn_data ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + char *pBuf ; + int iLen, rc ; + char sLog [ 80 ] ; + char bAdjustment ; + + + DEBUG_TELJJY_PRINTF( "teljjy_conn_data" ) ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + if ( teljjy_command_sequence[up->iClockCommandSeq].iEchobackReplyLength == iLen + && teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_LOOPBACK + && up->sTextBuf[0] == *(teljjy_command_sequence[up->iClockCommandSeq].command) + && up->iLoopbackCount < MAX_LOOPBACK ) { + /* Loopback */ + + teljjy_setDelay( peer, up ) ; + + up->iLoopbackCount ++ ; + + } else if ( teljjy_command_sequence[up->iClockCommandSeq].iEchobackReplyLength == iLen + && strncmp( pBuf, teljjy_command_sequence[up->iClockCommandSeq].command, iLen ) == 0 ) { + /* Maybe echoback */ + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_INFORMATION, JJY_CLOCKSTATS_MESSAGE_ECHOBACK ) ; + + } else if ( teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyLength == iLen + && teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_4DATE ) { + /* 4DATE -> YYYYMMDD */ + + rc = sscanf ( pBuf, "%4d%2d%2d", &up->year, &up->month, &up->day ) ; + + if ( rc != 3 || up->year < 2000 || 2099 <= up->year + || up->month < 1 || 12 < up->month || up->day < 1 || 31 < up->day ) { + /* Invalid date */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_DATE, + rc, up->year, up->month, up->day ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + } + + } else if ( teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyLength == iLen + && teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_LEAPSEC + && ( strncmp( pBuf, " 0", 2 ) == 0 || strncmp( pBuf, "+1", 2 ) == 0 || strncmp( pBuf, "-1", 2 ) == 0 ) ) { + /* LEAPSEC -> XX ( One of 0, +1, -1 ) */ + + rc = sscanf ( pBuf, "%2d", &up->leapsecond ) ; + + if ( rc != 1 || up->leapsecond < -1 || 1 < up->leapsecond ) { + /* Invalid leap second */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_LEAP, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + } + + } else if ( teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyLength == iLen + && teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_TIME ) { + /* TIME -> HHMMSS ( 3 times on second ) */ + + rc = sscanf ( pBuf, "%2d%2d%2d", &up->hour, &up->minute, &up->second ) ; + + if ( rc != 3 || up->hour > 23 || up->minute > 59 || up->second > 60 ) { + /* Invalid time */ + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_SSCANF_INVALID_TIME, + rc, up->hour, up->minute, up->second ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + up->bLineError = TRUE ; + } + up->iTimestamp[up->iTimestampCount] = ( up->hour * 60 + up->minute ) * 60 + up->second ; + + up->iTimestampCount++ ; + + if ( up->iTimestampCount == 6 && ! up->bLineError ) { +#if DEBUG + printf( "refclock_jjy.c : teljjy_conn_data : bLineError=%d iTimestamp=%d, %d, %d\n", + up->bLineError, + up->iTimestamp[3], up->iTimestamp[4], up->iTimestamp[5] ) ; +#endif + bAdjustment = TRUE ; + + if ( peer->ttl == 100 ) { + /* mode=100 */ + up->msecond = 0 ; + } else { + /* mode=101 to 110 */ + up->msecond = teljjy_getDelay( peer, up ) ; + if (up->msecond < 0 ) { + up->msecond = 0 ; + bAdjustment = FALSE ; + } + } + + if ( ( up->iTimestamp[3] - 15 ) <= up->iTimestamp[2] + && up->iTimestamp[2] <= up->iTimestamp[3] + && ( up->iTimestamp[3] + 1 ) == up->iTimestamp[4] + && ( up->iTimestamp[4] + 1 ) == up->iTimestamp[5] ) { + /* Non over midnight */ + + jjy_synctime( peer, pp, up ) ; + + if ( peer->ttl != 100 ) { + if ( bAdjustment ) { + snprintf( sLog, sizeof(sLog), + JJY_CLOCKSTATS_MESSAGE_DELAY_ADJUST, + up->msecond, up->iLoopbackValidCount, MAX_LOOPBACK ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_INFORMATION, sLog ) ; + } else { + snprintf( sLog, sizeof(sLog), + JJY_CLOCKSTATS_MESSAGE_DELAY_UNADJUST, + up->iLoopbackValidCount, MAX_LOOPBACK ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + } + } + + } + } + + } else if ( teljjy_command_sequence[up->iClockCommandSeq].iEchobackReplyLength != iLen + && teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_LOOPBACK ) { + /* Loopback noise ( Unexpected replay ) */ + + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_IGNORE_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_WARNING, sLog ) ; + + } else { + + up->bLineError = TRUE ; + + snprintf( sLog, sizeof(sLog)-1, JJY_CLOCKSTATS_MESSAGE_UNEXPECTED_REPLY, + pBuf ) ; + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_ERROR, sLog ) ; + + } + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_conn_silent ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + const char *pCmd ; + + DEBUG_TELJJY_PRINTF( "teljjy_conn_silent" ) ; + + if ( up->iClockCommandSeq >= 1 + && up->iClockCommandSeq < TELJJY_COMMAND_START_SKIP_LOOPBACK ) { + /* Loopback */ +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : teljjy_conn_silent : call teljjy_conn_send\n" ) ; + } +#endif + if ( teljjy_command_sequence[up->iClockCommandSeq].iExpectedReplyType == TELJJY_REPLY_LOOPBACK ) { + up->bLoopbackTimeout[up->iLoopbackCount] = TRUE ; + } + up->iTeljjySilentTimer = 0 ; + return teljjy_conn_send( peer, pp, up ) ; + } else { + pCmd = "\r" ; + } + + if ( write( pp->io.fd, pCmd, 1 ) != 1 ) { + refclock_report( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + + up->iTeljjySilentTimer = 0 ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_conn_error ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_conn_error" ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_bye_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_bye_ignore" ) ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_bye_disc ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_bye_disc" ) ; + + return TELJJY_CHANGE_CLOCK_STATE ; + +} + +/******************************/ +static int +teljjy_bye_modem ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_TELJJY_PRINTF( "teljjy_bye_modem" ) ; + + modem_disconnect ( peer->refclkunit, peer ) ; + + return TELJJY_STAY_CLOCK_STATE ; + +} + +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## Modem control finite state machine ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ + +/* struct jjyunit.iModemState */ + +#define MODEM_STATE_DISCONNECT 0 +#define MODEM_STATE_INITIALIZE 1 +#define MODEM_STATE_DAILING 2 +#define MODEM_STATE_CONNECT 3 +#define MODEM_STATE_ESCAPE 4 + +/* struct jjyunit.iModemEvent */ + +#define MODEM_EVENT_NULL 0 +#define MODEM_EVENT_INITIALIZE 1 +#define MODEM_EVENT_DIALOUT 2 +#define MODEM_EVENT_DISCONNECT 3 +#define MODEM_EVENT_RESP_OK 4 +#define MODEM_EVENT_RESP_CONNECT 5 +#define MODEM_EVENT_RESP_RING 6 +#define MODEM_EVENT_RESP_NO_CARRIER 7 +#define MODEM_EVENT_RESP_ERROR 8 +#define MODEM_EVENT_RESP_CONNECT_X 9 +#define MODEM_EVENT_RESP_NO_DAILTONE 10 +#define MODEM_EVENT_RESP_BUSY 11 +#define MODEM_EVENT_RESP_NO_ANSWER 12 +#define MODEM_EVENT_RESP_UNKNOWN 13 +#define MODEM_EVENT_SILENT 14 +#define MODEM_EVENT_TIMEOUT 15 + +/* Function prototypes */ + +static void modem_control ( struct peer *, struct refclockproc *, struct jjyunit * ) ; + +static int modem_disc_ignore ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_disc_init ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_init_ignore ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_init_start ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_init_disc ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_init_resp00 ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_init_resp04 ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_dial_ignore ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_dial_dialout ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_dial_escape ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_dial_connect ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_dial_disc ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_conn_ignore ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_conn_escape ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_esc_ignore ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_esc_escape ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_esc_data ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_esc_silent ( struct peer *, struct refclockproc *, struct jjyunit * ) ; +static int modem_esc_disc ( struct peer *, struct refclockproc *, struct jjyunit * ) ; + +static int ( *pModemHandler [ ] [ 5 ] ) ( ) = +{ /*STATE_DISCONNECT STATE_INITIALIZE STATE_DAILING STATE_CONNECT STATE_ESCAPE */ +/* NULL */ { modem_disc_ignore, modem_init_ignore, modem_dial_ignore , modem_conn_ignore, modem_esc_ignore }, +/* INITIALIZE */ { modem_disc_init , modem_init_start , modem_dial_ignore , modem_conn_ignore, modem_esc_ignore }, +/* DIALOUT */ { modem_disc_ignore, modem_init_ignore, modem_dial_dialout, modem_conn_ignore, modem_esc_ignore }, +/* DISCONNECT */ { modem_disc_ignore, modem_init_disc , modem_dial_escape , modem_conn_escape, modem_esc_escape }, +/* RESP: 0: OK */ { modem_disc_ignore, modem_init_resp00, modem_dial_ignore , modem_conn_ignore, modem_esc_data }, +/* RESP: 1: CONNECT */ { modem_disc_ignore, modem_init_ignore, modem_dial_connect, modem_conn_ignore, modem_esc_data }, +/* RESP: 2: RING */ { modem_disc_ignore, modem_init_ignore, modem_dial_ignore , modem_conn_ignore, modem_esc_data }, +/* RESP: 3: NO CARRIER */ { modem_disc_ignore, modem_init_ignore, modem_dial_disc , modem_conn_ignore, modem_esc_data }, +/* RESP: 4: ERROR */ { modem_disc_ignore, modem_init_resp04, modem_dial_disc , modem_conn_ignore, modem_esc_data }, +/* RESP: 5: CONNECT */ { modem_disc_ignore, modem_init_ignore, modem_dial_connect, modem_conn_ignore, modem_esc_data }, +/* RESP: 6: NO DAILTONE */ { modem_disc_ignore, modem_init_ignore, modem_dial_disc , modem_conn_ignore, modem_esc_data }, +/* RESP: 7: BUSY */ { modem_disc_ignore, modem_init_ignore, modem_dial_disc , modem_conn_ignore, modem_esc_data }, +/* RESP: 8: NO ANSWER */ { modem_disc_ignore, modem_init_ignore, modem_dial_disc , modem_conn_ignore, modem_esc_data }, +/* RESP: 9: UNKNOWN */ { modem_disc_ignore, modem_init_ignore, modem_dial_ignore , modem_conn_ignore, modem_esc_data }, +/* SILENT */ { modem_disc_ignore, modem_init_ignore, modem_dial_ignore , modem_conn_ignore, modem_esc_silent }, +/* TIMEOUT */ { modem_disc_ignore, modem_init_disc , modem_dial_escape , modem_conn_escape, modem_esc_disc } +} ; + +static short iModemNextState [ ] [ 5 ] = +{ /*STATE_DISCONNECT STATE_INITIALIZE STATE_DAILING STATE_CONNECT STATE_ESCAPE */ +/* NULL */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DAILING , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* INITIALIZE */ { MODEM_STATE_INITIALIZE, MODEM_STATE_INITIALIZE, MODEM_STATE_DAILING , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* DIALOUT */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DAILING , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* DISCONNECT */ { MODEM_STATE_DISCONNECT, MODEM_STATE_DISCONNECT, MODEM_STATE_ESCAPE , MODEM_STATE_ESCAPE , MODEM_STATE_ESCAPE }, +/* RESP: 0: OK */ { MODEM_STATE_DISCONNECT, MODEM_STATE_DAILING , MODEM_STATE_DAILING , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 1: CONNECT */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_CONNECT , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 2: RING */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DAILING , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 3: NO CARRIER */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DISCONNECT, MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 4: ERROR */ { MODEM_STATE_DISCONNECT, MODEM_STATE_DAILING , MODEM_STATE_DISCONNECT, MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 5: CONNECT X */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_CONNECT , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 6: NO DAILTONE */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DISCONNECT, MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 7: BUSY */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DISCONNECT, MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 8: NO ANSWER */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DISCONNECT, MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* RESP: 9: UNKNOWN */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DAILING , MODEM_STATE_CONNECT, MODEM_STATE_ESCAPE }, +/* SILENT */ { MODEM_STATE_DISCONNECT, MODEM_STATE_INITIALIZE, MODEM_STATE_DAILING , MODEM_STATE_CONNECT, MODEM_STATE_DISCONNECT }, +/* TIMEOUT */ { MODEM_STATE_DISCONNECT, MODEM_STATE_DISCONNECT, MODEM_STATE_ESCAPE , MODEM_STATE_ESCAPE , MODEM_STATE_DISCONNECT } +} ; + +static short iModemPostEvent [ ] [ 5 ] = +{ /*STATE_DISCONNECT STATE_INITIALIZE STATE_DAILING STATE_CONNECT STATE_ESCAPE */ +/* NULL */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* INITIALIZE */ { MODEM_EVENT_INITIALIZE, MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* DIALOUT */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* DISCONNECT */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_DISCONNECT, MODEM_EVENT_DISCONNECT, MODEM_EVENT_NULL }, +/* RESP: 0: OK */ { MODEM_EVENT_NULL , MODEM_EVENT_DIALOUT, MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 1: CONNECT */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 2: RING */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 3: NO CARRIER */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 4: ERROR */ { MODEM_EVENT_NULL , MODEM_EVENT_DIALOUT, MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 5: CONNECT X */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 6: NO DAILTONE */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 7: BUSY */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 8: NO ANSWER */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* RESP: 9: UNKNOWN */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* SILENT */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_NULL }, +/* TIMEOUT */ { MODEM_EVENT_NULL , MODEM_EVENT_NULL , MODEM_EVENT_DISCONNECT, MODEM_EVENT_DISCONNECT, MODEM_EVENT_NULL } +} ; + +static short iModemSilentTimeout [ 5 ] = { 0, 0, 0, 0, 5 } ; +static short iModemStateTimeout [ 5 ] = { 0, 20, 90, 0, 20 } ; + +#define STAY_MODEM_STATE 0 +#define CHANGE_MODEM_STATE 1 + +#ifdef DEBUG +#define DEBUG_MODEM_PRINTF(sFunc) { if ( debug ) { printf ( "refclock_jjy.c : %s : iModemState=%d iModemEvent=%d iModemSilentTimer=%d iModemStateTimer=%d\n", sFunc, up->iModemState, up->iModemEvent, up->iModemSilentTimer, up->iModemStateTimer ) ; } } +#else +#define DEBUG_MODEM_PRINTF(sFunc) +#endif + +/**************************************************************************************************/ + +static short +getModemState ( struct jjyunit *up ) +{ + return up->iModemState ; +} + +/**************************************************************************************************/ + +static int +isModemStateConnect ( short iCheckState ) +{ + return ( iCheckState == MODEM_STATE_CONNECT ) ; +} + +/**************************************************************************************************/ + +static int +isModemStateDisconnect ( short iCheckState ) +{ + return ( iCheckState == MODEM_STATE_DISCONNECT ) ; +} + +/**************************************************************************************************/ + +static int +isModemStateTimerOn ( struct jjyunit *up ) +{ + return ( iModemSilentTimeout[up->iModemState] != 0 || iModemStateTimeout[up->iModemState] != 0 ) ; +} + +/**************************************************************************************************/ + +static void +modem_connect ( int unit, struct peer *peer ) +{ + struct refclockproc *pp; + struct jjyunit *up; + + pp = peer->procptr ; + up = pp->unitptr ; + + DEBUG_MODEM_PRINTF( "modem_connect" ) ; + + up->iModemEvent = MODEM_EVENT_INITIALIZE ; + + modem_control ( peer, pp, up ) ; + +} + +/**************************************************************************************************/ + +static void +modem_disconnect ( int unit, struct peer *peer ) +{ + struct refclockproc *pp; + struct jjyunit *up; + + pp = peer->procptr ; + up = pp->unitptr ; + + DEBUG_MODEM_PRINTF( "modem_disconnect" ) ; + + up->iModemEvent = MODEM_EVENT_DISCONNECT ; + + modem_control ( peer, pp, up ) ; + +} + +/**************************************************************************************************/ + +static int +modem_receive ( struct recvbuf *rbufp ) +{ + + struct peer *peer; + struct jjyunit *up; + struct refclockproc *pp; + char *pBuf ; + int iLen ; + +#ifdef DEBUG + static const char *sFunctionName = "modem_receive" ; +#endif + + peer = rbufp->recv_peer ; + pp = peer->procptr ; + up = pp->unitptr ; + + DEBUG_MODEM_PRINTF( sFunctionName ) ; + + if ( up->linediscipline == LDISC_RAW ) { + pBuf = up->sTextBuf ; + iLen = up->iTextBufLen ; + } else { + pBuf = pp->a_lastcode ; + iLen = pp->lencode ; + } + + if ( iLen == 2 && strncmp( pBuf, "OK" , 2 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_OK ; } + else if ( iLen == 7 && strncmp( pBuf, "CONNECT" , 7 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_CONNECT ; } + else if ( iLen == 4 && strncmp( pBuf, "RING" , 4 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_RING ; } + else if ( iLen == 10 && strncmp( pBuf, "NO CARRIER" , 10 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_NO_CARRIER ; } + else if ( iLen == 5 && strncmp( pBuf, "ERROR" , 5 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_ERROR ; } + else if ( iLen >= 8 && strncmp( pBuf, "CONNECT " , 8 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_CONNECT_X ; } + else if ( iLen == 11 && strncmp( pBuf, "NO DAILTONE", 11 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_NO_DAILTONE ; } + else if ( iLen == 4 && strncmp( pBuf, "BUSY" , 4 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_BUSY ; } + else if ( iLen == 9 && strncmp( pBuf, "NO ANSWER" , 9 ) == 0 ) { up->iModemEvent = MODEM_EVENT_RESP_NO_ANSWER ; } + else { up->iModemEvent = MODEM_EVENT_RESP_UNKNOWN ; } + +#ifdef DEBUG + if ( debug ) { + char sResp [ 40 ] ; + int iCopyLen ; + iCopyLen = ( iLen <= sizeof(sResp)-1 ? iLen : sizeof(sResp)-1 ) ; + strncpy( sResp, pBuf, iLen <= sizeof(sResp)-1 ? iLen : sizeof(sResp)-1 ) ; + sResp[iCopyLen] = 0 ; + printf ( "refclock_jjy.c : modem_receive : iLen=%d pBuf=[%s] iModemEvent=%d\n", iCopyLen, sResp, up->iModemEvent ) ; + } +#endif + modem_control ( peer, pp, up ) ; + + return 0 ; + +} + +/**************************************************************************************************/ + +static void +modem_timer ( int unit, struct peer *peer ) +{ + + struct refclockproc *pp ; + struct jjyunit *up ; + + pp = peer->procptr ; + up = pp->unitptr ; + + DEBUG_MODEM_PRINTF( "modem_timer" ) ; + + if ( iModemSilentTimeout[up->iModemState] != 0 ) { + up->iModemSilentTimer++ ; + if ( iModemSilentTimeout[up->iModemState] <= up->iModemSilentTimer ) { + up->iModemEvent = MODEM_EVENT_SILENT ; + modem_control ( peer, pp, up ) ; + } + } + + if ( iModemStateTimeout[up->iModemState] != 0 ) { + up->iModemStateTimer++ ; + if ( iModemStateTimeout[up->iModemState] <= up->iModemStateTimer ) { + up->iModemEvent = MODEM_EVENT_TIMEOUT ; + modem_control ( peer, pp, up ) ; + } + } + +} + +/**************************************************************************************************/ + +static void +modem_control ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + int rc ; + short iPostEvent = MODEM_EVENT_NULL ; + + DEBUG_MODEM_PRINTF( "modem_control" ) ; + + rc = (*pModemHandler[up->iModemEvent][up->iModemState])( peer, pp, up ) ; + + if ( rc == CHANGE_MODEM_STATE ) { + iPostEvent = iModemPostEvent[up->iModemEvent][up->iModemState] ; +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : modem_control : iModemState=%d -> %d iPostEvent=%d\n", + up->iModemState, iModemNextState[up->iModemEvent][up->iModemState], iPostEvent ) ; + } +#endif + + if ( up->iModemState != iModemNextState[up->iModemEvent][up->iModemState] ) { + up->iModemSilentCount = 0 ; + up->iModemStateTimer = 0 ; + up->iModemCommandSeq = 0 ; + } + + up->iModemState = iModemNextState[up->iModemEvent][up->iModemState] ; + } + + if ( iPostEvent != MODEM_EVENT_NULL ) { + up->iModemEvent = iPostEvent ; + modem_control ( peer, pp, up ) ; + } + + up->iModemEvent = MODEM_EVENT_NULL ; + +} + +/******************************/ +static int +modem_disc_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_MODEM_PRINTF( "modem_disc_ignore" ) ; + + return STAY_MODEM_STATE ; + +} + +/******************************/ +static int +modem_disc_init ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ - } + DEBUG_MODEM_PRINTF( "modem_disc_init" ) ; - return 1 ; + return CHANGE_MODEM_STATE ; } -/**************************************************************************************************/ - +/******************************/ static int -jjy_receive_echokeisokuki_lt2000 ( struct recvbuf *rbufp ) +modem_init_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) { - static char *sFunctionName = "jjy_receive_echokeisokuki_lt2000" ; + DEBUG_MODEM_PRINTF( "modem_init_ignore" ) ; - struct jjyunit *up ; - struct refclockproc *pp ; - struct peer *peer; - - char *pBuf ; - int iLen ; - int rc ; - int i, ibcc, ibcc1, ibcc2 ; + return STAY_MODEM_STATE ; - /* - * Initialize pointers and read the timecode and timestamp - */ - peer = (struct peer *) rbufp->recv_srcclock ; - pp = peer->procptr ; - up = (struct jjyunit *) pp->unitptr ; +} - if ( up->linediscipline == LDISC_RAW ) { - pBuf = up->rawbuf ; - iLen = up->charcount ; - } else { - pBuf = pp->a_lastcode ; - iLen = pp->lencode ; - } +/******************************/ +static int +modem_init_start ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ - switch ( up->linecount ) { + DEBUG_MODEM_PRINTF( "modem_init_start" ) ; - case 1 : /* YYMMDDWHHMMSS or YYMMDDWHHMMSS */ + up->iModemCommandSeq = 0 ; - if ( ( up->operationmode == 1 && iLen != 15 ) || ( up->operationmode == 2 && iLen != 17 ) ) { #ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Reply length error ( iLen=%d )\n", sFunctionName, iLen ) ; - } -#endif - if ( up->operationmode == 1 ) { -#ifdef DEBUG - if ( debug ) { - printf ( "%s (refclock_jjy.c) : send '#'\n", sFunctionName ) ; - } + if ( debug ) { + printf( "refclock_jjy.c : modem_init_start : call modem_init_resp00\n" ) ; + } #endif - if ( write ( pp->io.fd, "#",1 ) != 1 ) { - refclock_report ( peer, CEVNT_FAULT ) ; - } - } - up->lineerror = 1 ; - break ; - } - if ( up->operationmode == 1 ) { + return modem_init_resp00( peer, pp, up ) ; - for ( i = ibcc = 0 ; i < 13 ; i ++ ) ibcc ^= pBuf[i] ; - ibcc1 = 0x30 | ( ( ibcc >> 4 ) & 0xF ) ; - ibcc2 = 0x30 | ( ( ibcc ) & 0xF ) ; - if ( pBuf[13] != ibcc1 || pBuf[14] != ibcc2 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : BCC error ( Recv=%02X,%02X / Calc=%02X,%02X)\n", sFunctionName, pBuf[13]&0xFF, pBuf[14]&0xFF, ibcc1, ibcc2 ) ; - } -#endif - up->lineerror = 1 ; - break ; - } +} - } +/******************************/ +static int +modem_init_resp00 ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ - rc = sscanf ( pBuf, "%2d%2d%2d%*1d%2d%2d%2d", - &up->year, &up->month, &up->day, &up->hour, &up->minute, &up->second ) ; - if ( rc != 6 || up->month < 1 || up->month > 12 || up->day < 1 || up->day > 31 - || up->hour > 23 || up->minute > 59 || up->second > 60 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Time error (rc=%d) [ %02d %02d %02d * %02d %02d %02d ]\n", sFunctionName, - rc, up->year, up->month, up->day, up->hour, up->minute, up->second ) ; - } -#endif - up->lineerror = 1 ; - break ; - } + char *pCmd, cBuf [ 46 ] ; + int iCmdLen ; + int iErrorCorrection, iSpeakerSwitch, iSpeakerVolume ; + int iNextModemState = STAY_MODEM_STATE ; - up->year += 2000 ; + DEBUG_MODEM_PRINTF( "modem_init_resp00" ) ; - if ( up->operationmode == 2 ) { + up->iModemCommandSeq++ ; - /* A time stamp comes on every 0.5 seccond in the mode 2 of the LT-2000. */ - up->msecond = 500 ; - pp->second -- ; - if ( pp->second < 0 ) { - pp->second = 59 ; - pp->minute -- ; - if ( pp->minute < 0 ) { - pp->minute = 59 ; - pp->hour -- ; - if ( pp->hour < 0 ) { - pp->hour = 23 ; - pp->day -- ; - if ( pp->day < 1 ) { - pp->year -- ; - pp->day = ymd2yd ( pp->year, 12, 31 ) ; - } - } - } - } + switch ( up->iModemCommandSeq ) { - /* Switch from mode 2 to mode 1 in order to restraint of useless time stamp. */ -#ifdef DEBUG - if ( debug ) { - printf ( "%s (refclock_jjy.c) : send '#'\n", sFunctionName ) ; - } -#endif - if ( write ( pp->io.fd, "#",1 ) != 1 ) { - refclock_report ( peer, CEVNT_FAULT ) ; - } + case 1 : + /* En = Echoback 0:Off 1:On */ + /* Qn = Result codes 0:On 1:Off */ + /* Vn = Result codes 0:Numeric 1:Text */ + pCmd = "ATE0Q0V1\r\n" ; + break ; + + case 2 : + /* Mn = Speaker switch 0:Off 1:On until remote carrier detected 2:On */ + if ( ( pp->sloppyclockflag & CLK_FLAG3 ) == 0 ) { + /* fudge 127.127.40.n flag3 0 */ + iSpeakerSwitch = 0 ; + } else { + /* fudge 127.127.40.n flag3 1 */ + iSpeakerSwitch = 2 ; + } + /* Ln = Speaker volume 0:Very low 1:Low 2:Middle 3:High */ + if ( ( pp->sloppyclockflag & CLK_FLAG4 ) == 0 ) { + /* fudge 127.127.40.n flag4 0 */ + iSpeakerVolume = 1 ; + } else { + /* fudge 127.127.40.n flag4 1 */ + iSpeakerVolume = 2 ; } + pCmd = cBuf ; + snprintf( pCmd, sizeof(cBuf), "ATM%dL%d\r\n", iSpeakerSwitch, iSpeakerVolume ) ; break ; - default : /* Unexpected reply */ + case 3 : + /* &Kn = Flow control 4:XON/XOFF */ + pCmd = "AT&K4\r\n" ; + break ; -#ifdef DEBUG - if ( debug ) { - printf ( "%s (refclock_jjy.c) : send '#'\n", sFunctionName ) ; - } -#endif - if ( write ( pp->io.fd, "#",1 ) != 1 ) { - refclock_report ( peer, CEVNT_FAULT ) ; + case 4 : + /* +MS = Protocol V22B:1200,2400bpsiV.22bis) */ + pCmd = "AT+MS=V22B\r\n" ; + break ; + + case 5 : + /* %Cn = Data compression 0:No data compression */ + pCmd = "AT%C0\r\n" ; + break ; + + case 6 : + /* \Nn = Error correction 0:Normal mode 1:Direct mode 2:V42,MNP 3:V42,MNP,Normal */ + if ( ( pp->sloppyclockflag & CLK_FLAG2 ) == 0 ) { + /* fudge 127.127.40.n flag2 0 */ + iErrorCorrection = 0 ; + } else { + /* fudge 127.127.40.n flag2 1 */ + iErrorCorrection = 3 ; } - up->lineerror = 1 ; + pCmd = cBuf ; + snprintf( pCmd, sizeof(cBuf), "AT\\N%d\r\n", iErrorCorrection ) ; + break ; + + case 7 : + /* Hn = Hook 0:Hook-On ( Disconnect ) 1:Hook-Off ( Connect ) */ + pCmd = "ATH1\r\n" ; + break ; + + case 8 : + /* Initialize completion */ + pCmd = NULL ; + iNextModemState = CHANGE_MODEM_STATE ; break ; + default : + pCmd = NULL ; + break ; + + } + + if ( pCmd != NULL ) { + + iCmdLen = strlen( pCmd ) ; + if ( write( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report( peer, CEVNT_FAULT ) ; + } + + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + } - return 1 ; + return iNextModemState ; } -/**************************************************************************************************/ +/******************************/ +static int +modem_init_resp04 ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_MODEM_PRINTF( "modem_init_resp04" ) ; + + return modem_init_resp00( peer, pp, up ) ; + +} +/******************************/ static int -jjy_receive_citizentic_jjy200 ( struct recvbuf *rbufp ) +modem_init_disc ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) { - static char *sFunctionName = "jjy_receive_citizentic_jjy200" ; + DEBUG_MODEM_PRINTF( "modem_init_disc" ) ; +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : modem_init_disc : call modem_esc_disc\n" ) ; + } +#endif - struct jjyunit *up ; - struct refclockproc *pp ; - struct peer *peer; + return CHANGE_MODEM_STATE ; - char *pBuf ; - int iLen ; - int rc ; - char cApostrophe, sStatus[3] ; - int iWeekday ; +} - /* - * Initialize pointers and read the timecode and timestamp - */ - peer = (struct peer *) rbufp->recv_srcclock ; - pp = peer->procptr ; - up = (struct jjyunit *) pp->unitptr ; +/******************************/ +static int +modem_dial_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ - if ( up->linediscipline == LDISC_RAW ) { - pBuf = up->rawbuf ; - iLen = up->charcount ; - } else { - pBuf = pp->a_lastcode ; - iLen = pp->lencode ; - } + DEBUG_MODEM_PRINTF( "modem_dial_ignore" ) ; - /* - * JJY-200 sends a timestamp every second. - * So, a timestamp is ignored unless it is right after polled. - */ - if ( ! up->bPollFlag ) return 0 ; + return STAY_MODEM_STATE ; - switch ( up->linecount ) { +} - case 1 : /* 'XX YY/MM/DD W HH:MM:SS */ +/******************************/ +static int +modem_dial_dialout ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ - if ( iLen != 23 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Reply length error ( iLen=%d )\n", sFunctionName, iLen ) ; - } -#endif - up->lineerror = 1 ; - break ; - } - - rc = sscanf ( pBuf, "%c%2s %2d/%2d/%2d %1d %2d:%2d:%2d", - &cApostrophe, sStatus, - &up->year, &up->month, &up->day, &iWeekday, &up->hour, &up->minute, &up->second ) ; - sStatus[2] = 0 ; - if ( rc != 9 || cApostrophe != '\'' || strcmp( sStatus, "OK" ) != 0 - || up->month < 1 || up->month > 12 || up->day < 1 || up->day > 31 - || iWeekday > 6 - || up->hour > 23 || up->minute > 59 || up->second > 60 ) { -#ifdef DEBUG - if ( debug >= 2 ) { - printf ( "%s (refclock_jjy.c) : Time error (rc=%d) [ %c %2s %02d %02d %02d %d %02d %02d %02d ]\n", sFunctionName, - rc, cApostrophe, sStatus, up->year, up->month, up->day, iWeekday, up->hour, up->minute, up->second ) ; - } -#endif - up->lineerror = 1 ; - break ; - } + char sCmd [ 46 ] ; + int iCmdLen ; + char cToneOrPulse ; - up->year += 2000 ; - up->msecond = 0 ; + DEBUG_MODEM_PRINTF( "modem_dial_dialout" ) ; - break ; + /* Tone or Pulse */ + if ( ( pp->sloppyclockflag & CLK_FLAG1 ) == 0 ) { + /* fudge 127.127.40.n flag1 0 */ + cToneOrPulse = 'T' ; + } else { + /* fudge 127.127.40.n flag1 1 */ + cToneOrPulse = 'P' ; + } - default : /* Unexpected reply */ + /* Connect ( Dial number ) */ + snprintf( sCmd, sizeof(sCmd), "ATDW%c%s\r\n", cToneOrPulse, *sys_phone ) ; - up->lineerror = 1 ; - break ; + /* Send command */ + iCmdLen = strlen( sCmd ) ; + if ( write( pp->io.fd, sCmd, iCmdLen ) != iCmdLen ) { + refclock_report( peer, CEVNT_FAULT ) ; + } - } + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, sCmd ) ; - return 1 ; + return STAY_MODEM_STATE ; } -/**************************************************************************************************/ -/* jjy_poll - called by the transmit procedure */ -/**************************************************************************************************/ -static void -jjy_poll ( int unit, struct peer *peer ) +/******************************/ +static int +modem_dial_escape ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) { - struct jjyunit *up; - struct refclockproc *pp; + DEBUG_MODEM_PRINTF( "modem_dial_escape" ) ; +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : modem_dial_escape : call modem_conn_escape\n" ) ; + } +#endif - pp = peer->procptr; - up = (struct jjyunit *) pp->unitptr ; + return modem_conn_escape( peer, pp, up ) ; - if ( pp->polls > 0 && up->linecount == 0 ) { - /* - * No reply for last command - */ - refclock_report ( peer, CEVNT_TIMEOUT ) ; - } +} + +/******************************/ +static int +modem_dial_connect ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + DEBUG_MODEM_PRINTF( "modem_dial_connect" ) ; + + return CHANGE_MODEM_STATE ; + +} + +/******************************/ +static int +modem_dial_disc ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_MODEM_PRINTF( "modem_dial_disc" ) ; #ifdef DEBUG if ( debug ) { - printf ( "jjy_poll (refclock_jjy.c) : %ld\n", pp->polls ) ; + printf( "refclock_jjy.c : modem_dial_disc : call modem_esc_disc\n" ) ; } #endif - pp->polls ++ ; + modem_esc_disc( peer, pp, up ) ; - up->bPollFlag = 1 ; - up->linecount = 0 ; - up->lineerror = 0 ; - up->charcount = 0 ; + return CHANGE_MODEM_STATE ; - switch ( up->unittype ) { - - case UNITTYPE_TRISTATE_JJY01 : - jjy_poll_tristate_jjy01 ( unit, peer ) ; - break ; +} - case UNITTYPE_CDEX_JST2000 : - jjy_poll_cdex_jst2000 ( unit, peer ) ; - break ; +/******************************/ +static int +modem_conn_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ - case UNITTYPE_ECHOKEISOKUKI_LT2000 : - jjy_poll_echokeisokuki_lt2000 ( unit, peer ) ; - break ; + DEBUG_MODEM_PRINTF( "modem_conn_ignore" ) ; - case UNITTYPE_CITIZENTIC_JJY200 : - jjy_poll_citizentic_jjy200 ( unit, peer ) ; - break ; + return STAY_MODEM_STATE ; - default : - break ; +} - } +/******************************/ +static int +modem_conn_escape ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + DEBUG_MODEM_PRINTF( "modem_conn_escape" ) ; + + return CHANGE_MODEM_STATE ; } -/**************************************************************************************************/ +/******************************/ +static int +modem_esc_ignore ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ -static void -jjy_poll_tristate_jjy01 ( int unit, struct peer *peer ) + DEBUG_MODEM_PRINTF( "modem_esc_ignore" ) ; + + return STAY_MODEM_STATE ; + +} + +/******************************/ +static int +modem_esc_escape ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) { - struct refclockproc *pp; + char *pCmd ; + int iCmdLen ; - pp = peer->procptr; + DEBUG_MODEM_PRINTF( "modem_esc_escape" ) ; - /* - * Send "date" command - */ + /* Escape command ( Go to command mode ) */ + pCmd = "+++" ; -#ifdef DEBUG - if ( debug ) { - printf ( "jjy_poll_tristate_jjy01 (refclock_jjy.c) : send 'date'\n" ) ; + /* Send command */ + iCmdLen = strlen( pCmd ) ; + if ( write( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report( peer, CEVNT_FAULT ) ; } -#endif - if ( write ( pp->io.fd, "date\r\n",6 ) != 6 ) { - refclock_report ( peer, CEVNT_FAULT ) ; - } + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + + return STAY_MODEM_STATE ; } -/**************************************************************************************************/ +/******************************/ +static int +modem_esc_data ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ -static void -jjy_poll_cdex_jst2000 ( int unit, struct peer *peer ) + DEBUG_MODEM_PRINTF( "modem_esc_data" ) ; + + up->iModemSilentTimer = 0 ; + + return STAY_MODEM_STATE ; + +} + +/******************************/ +static int +modem_esc_silent ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) { - struct refclockproc *pp; + DEBUG_MODEM_PRINTF( "modem_esc_silent" ) ; - pp = peer->procptr; + up->iModemSilentCount ++ ; - /* - * Send "1J" command - */ + if ( up->iModemSilentCount < iModemStateTimeout[up->iModemState] / iModemSilentTimeout[up->iModemState] ) { +#ifdef DEBUG + if ( debug ) { + printf( "refclock_jjy.c : modem_esc_silent : call modem_esc_escape\n" ) ; + } +#endif + modem_esc_escape( peer, pp, up ) ; + up->iModemSilentTimer = 0 ; + return STAY_MODEM_STATE ; + } #ifdef DEBUG if ( debug ) { - printf ( "jjy_poll_cdex_jst2000 (refclock_jjy.c) : send '1J'\n" ) ; + printf( "refclock_jjy.c : modem_esc_silent : call modem_esc_disc\n" ) ; } #endif + return modem_esc_disc( peer, pp, up ) ; - if ( write ( pp->io.fd, "\0051J\003", 4 ) != 4 ) { - refclock_report ( peer, CEVNT_FAULT ) ; +} +/******************************/ +static int +modem_esc_disc ( struct peer *peer, struct refclockproc *pp, struct jjyunit *up ) +{ + + char *pCmd ; + int iCmdLen ; + + DEBUG_MODEM_PRINTF( "modem_esc_disc" ) ; + + /* Disconnect */ + pCmd = "ATH0\r\n" ; + + /* Send command */ + iCmdLen = strlen( pCmd ) ; + if ( write( pp->io.fd, pCmd, iCmdLen ) != iCmdLen ) { + refclock_report( peer, CEVNT_FAULT ) ; } + jjy_write_clockstats( peer, JJY_CLOCKSTATS_MARK_SEND, pCmd ) ; + + return CHANGE_MODEM_STATE ; + } -/**************************************************************************************************/ +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## jjy_write_clockstats ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ static void -jjy_poll_echokeisokuki_lt2000 ( int unit, struct peer *peer ) +jjy_write_clockstats ( struct peer *peer, int iMark, const char *pData ) { - struct jjyunit *up; - struct refclockproc *pp; - - char sCmd[2] ; - - pp = peer->procptr; - up = (struct jjyunit *) pp->unitptr ; - - /* - * Send "T" or "C" command - */ + char sLog [ 100 ] ; + char *pMark ; + int iMarkLen, iDataLen ; - switch ( up->operationmode ) { - case 1 : sCmd[0] = 'T' ; break ; - case 2 : sCmd[0] = 'C' ; break ; + switch ( iMark ) { + case JJY_CLOCKSTATS_MARK_JJY : + pMark = "JJY " ; + break ; + case JJY_CLOCKSTATS_MARK_SEND : + pMark = "--> " ; + break ; + case JJY_CLOCKSTATS_MARK_RECEIVE : + pMark = "<-- " ; + break ; + case JJY_CLOCKSTATS_MARK_INFORMATION : + pMark = "--- " ; + break ; + case JJY_CLOCKSTATS_MARK_ATTENTION : + pMark = "=== " ; + break ; + case JJY_CLOCKSTATS_MARK_WARNING : + pMark = "-W- " ; + break ; + case JJY_CLOCKSTATS_MARK_ERROR : + pMark = "-X- " ; + break ; + default : + pMark = "" ; + break ; } - sCmd[1] = 0 ; + + iDataLen = strlen( pData ) ; + iMarkLen = strlen( pMark ) ; + strcpy( sLog, pMark ) ; /* Harmless because of enough length */ + printableString( sLog+iMarkLen, sizeof(sLog)-iMarkLen, pData, iDataLen ) ; #ifdef DEBUG if ( debug ) { - printf ( "jjy_poll_echokeisokuki_lt2000 (refclock_jjy.c) : send '%s'\n", sCmd ) ; + printf( "refclock_jjy.c : clockstats : %s\n", sLog ) ; } #endif - - if ( write ( pp->io.fd, sCmd, 1 ) != 1 ) { - refclock_report ( peer, CEVNT_FAULT ) ; - } + record_clock_stats( &peer->srcadr, sLog ) ; } -/**************************************************************************************************/ +/*################################################################################################*/ +/*################################################################################################*/ +/*## ##*/ +/*## printableString ##*/ +/*## ##*/ +/*################################################################################################*/ +/*################################################################################################*/ static void -jjy_poll_citizentic_jjy200 ( int unit, struct peer *peer ) +printableString ( char *sOutput, int iOutputLen, const char *sInput, int iInputLen ) { + const char *printableControlChar[] = { + "", "", "", "", + "", "", "", "", + "" , "" , "" , "" , + "" , "" , "" , "" , + "", "", "", "", + "", "", "", "", + "", "" , "", "", + "" , "" , "" , "" , + " " } ; + + size_t i, j, n ; + size_t InputLen; + size_t OutputLen; + + InputLen = (size_t)iInputLen; + OutputLen = (size_t)iOutputLen; + for ( i = j = 0 ; i < InputLen && j < OutputLen ; i ++ ) { + if ( isprint( (unsigned char)sInput[i] ) ) { + n = 1 ; + if ( j + 1 >= OutputLen ) + break ; + sOutput[j] = sInput[i] ; + } else if ( ( sInput[i] & 0xFF ) < + COUNTOF(printableControlChar) ) { + n = strlen( printableControlChar[sInput[i] & 0xFF] ) ; + if ( j + n + 1 >= OutputLen ) + break ; + strlcpy( sOutput + j, + printableControlChar[sInput[i] & 0xFF], + OutputLen - j ) ; + } else { + n = 5 ; + if ( j + n + 1 >= OutputLen ) + break ; + snprintf( sOutput + j, OutputLen - j, "", + sInput[i] & 0xFF ) ; + } + j += n ; + } - /* Do nothing ( up->bPollFlag is set by the jjy_poll ) */ + sOutput[min(j, (size_t)iOutputLen - 1)] = '\0' ; } +/**************************************************************************************************/ + #else int refclock_jjy_bs ; #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_jupiter.c b/contrib/ntp/ntpd/refclock_jupiter.c index c10d9fa0d..02b33dfb3 100644 --- a/contrib/ntp/ntpd/refclock_jupiter.c +++ b/contrib/ntp/ntpd/refclock_jupiter.c @@ -52,17 +52,12 @@ # include "ppsapi_timepps.h" #endif -#ifdef XNTP_BIG_ENDIAN +#ifdef WORDS_BIGENDIAN #define getshort(s) ((((s) & 0xff) << 8) | (((s) >> 8) & 0xff)) #define putshort(s) ((((s) & 0xff) << 8) | (((s) >> 8) & 0xff)) #else -#define getshort(s) (s) -#define putshort(s) (s) -#endif - -/* XXX */ -#ifdef sun -char *strerror(int); +#define getshort(s) ((u_short)(s)) +#define putshort(s) ((u_short)(s)) #endif /* @@ -135,28 +130,29 @@ struct instance { /* * Function prototypes */ -static void jupiter_canmsg P((struct instance *, u_int)); -static u_short jupiter_cksum P((u_short *, u_int)); -static int jupiter_config P((struct instance *)); -static void jupiter_debug P((struct peer *, char *, char *, ...)) - __attribute__ ((format (printf, 3, 4))); -static char * jupiter_parse_t P((struct instance *, u_short *)); -static char * jupiter_parse_gpos P((struct instance *, u_short *)); -static void jupiter_platform P((struct instance *, u_int)); -static void jupiter_poll P((int, struct peer *)); -static void jupiter_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); +static void jupiter_canmsg (struct instance *, u_int); +static u_short jupiter_cksum (u_short *, u_int); +static int jupiter_config (struct instance *); +static void jupiter_debug (struct peer *, const char *, + const char *, ...) + __attribute__ ((format (printf, 3, 4))); +static const char * jupiter_parse_t (struct instance *, u_short *); +static const char * jupiter_parse_gpos (struct instance *, u_short *); +static void jupiter_platform (struct instance *, u_int); +static void jupiter_poll (int, struct peer *); +static void jupiter_control (int, const struct refclockstat *, + struct refclockstat *, struct peer *); #ifdef HAVE_PPSAPI -static int jupiter_ppsapi P((struct instance *)); -static int jupiter_pps P((struct instance *)); +static int jupiter_ppsapi (struct instance *); +static int jupiter_pps (struct instance *); #endif /* HAVE_PPSAPI */ -static int jupiter_recv P((struct instance *)); -static void jupiter_receive P((struct recvbuf *rbufp)); -static void jupiter_reqmsg P((struct instance *, u_int, u_int)); -static void jupiter_reqonemsg P((struct instance *, u_int)); -static char * jupiter_send P((struct instance *, struct jheader *)); -static void jupiter_shutdown P((int, struct peer *)); -static int jupiter_start P((int, struct peer *)); +static int jupiter_recv (struct instance *); +static void jupiter_receive (struct recvbuf *rbufp); +static void jupiter_reqmsg (struct instance *, u_int, u_int); +static void jupiter_reqonemsg(struct instance *, u_int); +static char * jupiter_send (struct instance *, struct jheader *); +static void jupiter_shutdown(int, struct peer *); +static int jupiter_start (int, struct peer *); /* * Transfer vector @@ -182,39 +178,35 @@ jupiter_start( { struct refclockproc *pp; struct instance *instance; - int fd = -1; + int fd; char gpsdev[20]; /* * Open serial port */ - (void)sprintf(gpsdev, DEVICE, unit); + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); fd = refclock_open(gpsdev, SPEED232, LDISC_RAW); - if (fd == 0) { - jupiter_debug(peer, "jupiter_start", "open %s: %s", - gpsdev, strerror(errno)); + if (fd <= 0) { + jupiter_debug(peer, "jupiter_start", "open %s: %m", + gpsdev); return (0); } /* Allocate unit structure */ - if ((instance = (struct instance *) - emalloc(sizeof(struct instance))) == NULL) { - (void) close(fd); - return (0); - } - memset((char *)instance, 0, sizeof(struct instance)); + instance = emalloc_zero(sizeof(*instance)); instance->peer = peer; pp = peer->procptr; pp->io.clock_recv = jupiter_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(instance); return (0); } - pp->unitptr = (caddr_t)instance; + pp->unitptr = instance; /* * Initialize miscellaneous variables @@ -261,7 +253,7 @@ jupiter_shutdown(int unit, struct peer *peer) struct refclockproc *pp; pp = peer->procptr; - instance = (struct instance *)pp->unitptr; + instance = pp->unitptr; if (!instance) return; @@ -272,7 +264,8 @@ jupiter_shutdown(int unit, struct peer *peer) } #endif /* HAVE_PPSAPI */ - io_closeclock(&pp->io); + if (pp->io.fd != -1) + io_closeclock(&pp->io); free(instance); } @@ -282,7 +275,7 @@ jupiter_shutdown(int unit, struct peer *peer) static int jupiter_config(struct instance *instance) { - jupiter_debug(instance->peer, "jupiter_config", "init receiver"); + jupiter_debug(instance->peer, __func__, "init receiver"); /* * Initialize the unit variables @@ -290,8 +283,7 @@ jupiter_config(struct instance *instance) instance->sloppyclockflag = instance->peer->procptr->sloppyclockflag; instance->moving = !!(instance->sloppyclockflag & CLK_FLAG2); if (instance->moving) - jupiter_debug(instance->peer, "jupiter_config", - "mobile platform"); + jupiter_debug(instance->peer, __func__, "mobile platform"); instance->pollcnt = 2; instance->polled = 0; @@ -368,14 +360,14 @@ jupiter_ppsapi( "refclock_jupiter: time_pps_kcbind failed: %m"); return (0); } - pps_enable = 1; + hardpps_enable = 1; } /* instance->peer->precision = PPS_PRECISION; */ #if DEBUG if (debug) { time_pps_getparams(instance->pps_handle, &instance->pps_params); - jupiter_debug(instance->peer, "refclock_jupiter", + jupiter_debug(instance->peer, __func__, "pps capability 0x%x version %d mode 0x%x kern %d", capability, instance->pps_params.api_version, instance->pps_params.mode, instance->hardpps); @@ -426,7 +418,7 @@ jupiter_pps(struct instance *instance) return 1; instance->ts = ts; - tstmp.l_ui = ts.tv_sec + JAN_1970; + tstmp.l_ui = (u_int32)ts.tv_sec + JAN_1970; dtemp = ts.tv_nsec * FRAC / 1e9; tstmp.l_uf = (u_int32)dtemp; instance->peer->procptr->lastrec = tstmp; @@ -444,7 +436,7 @@ jupiter_poll(int unit, struct peer *peer) struct refclockproc *pp; pp = peer->procptr; - instance = (struct instance *)pp->unitptr; + instance = pp->unitptr; /* * You don't need to poll this clock. It puts out timecodes @@ -479,7 +471,7 @@ jupiter_poll(int unit, struct peer *peer) static void jupiter_control( int unit, /* unit (not used) */ - struct refclockstat *in, /* input parameters (not used) */ + const struct refclockstat *in, /* input parameters (not used) */ struct refclockstat *out, /* output parameters (not used) */ struct peer *peer /* peer structure pointer */ ) @@ -489,7 +481,7 @@ jupiter_control( u_char sloppyclockflag; pp = peer->procptr; - instance = (struct instance *)pp->unitptr; + instance = pp->unitptr; DTOLFP(pp->fudgetime2, &instance->limit); /* Force positive value. */ @@ -505,8 +497,7 @@ jupiter_control( instance->sloppyclockflag = pp->sloppyclockflag; if ((instance->sloppyclockflag & CLK_FLAG2) != (sloppyclockflag & CLK_FLAG2)) { - jupiter_debug(peer, - "jupiter_control", + jupiter_debug(peer, __func__, "mode switch: reset receiver"); jupiter_config(instance); return; @@ -520,10 +511,11 @@ jupiter_control( static void jupiter_receive(struct recvbuf *rbufp) { - int bpcnt, cc, size, ppsret; + size_t bpcnt; + int cc, size, ppsret; time_t last_timecode; u_int32 laststime; - char *cp; + const char *cp; u_char *bp; u_short *sp; struct jid *ip; @@ -534,9 +526,9 @@ jupiter_receive(struct recvbuf *rbufp) l_fp tstamp; /* Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - instance = (struct instance *)pp->unitptr; + instance = pp->unitptr; bp = (u_char *)rbufp->recv_buffer; bpcnt = rbufp->recv_length; @@ -550,7 +542,7 @@ jupiter_receive(struct recvbuf *rbufp) instance->ssize += bpcnt; /* While there's at least a header and we parse an intact message */ - while (instance->ssize > sizeof(*hp) && (cc = jupiter_recv(instance)) > 0) { + while (instance->ssize > (int)sizeof(*hp) && (cc = jupiter_recv(instance)) > 0) { instance->pollcnt = 2; tstamp = rbufp->recv_time; @@ -561,8 +553,8 @@ jupiter_receive(struct recvbuf *rbufp) case JUPITER_O_PULSE: if (size != sizeof(struct jpulse)) { - jupiter_debug(peer, - "jupiter_receive", "pulse: len %d != %u", + jupiter_debug(peer, __func__, + "pulse: len %d != %u", size, (int)sizeof(struct jpulse)); refclock_report(peer, CEVNT_BADREPLY); break; @@ -581,7 +573,7 @@ jupiter_receive(struct recvbuf *rbufp) laststime = instance->stime; instance->stime = DS2UI(((struct jpulse *)sp)->stime); if (laststime != 0 && instance->stime - laststime <= 21) { - jupiter_debug(peer, "jupiter_receive", + jupiter_debug(peer, __func__, "avoided firmware bug (stime %.2f, laststime %.2f)", (double)instance->stime * 0.01, (double)laststime * 0.01); break; @@ -602,8 +594,8 @@ jupiter_receive(struct recvbuf *rbufp) /* Parse timecode (even when there's no pps) */ last_timecode = instance->timecode; if ((cp = jupiter_parse_t(instance, sp)) != NULL) { - jupiter_debug(peer, - "jupiter_receive", "pulse: %s", cp); + jupiter_debug(peer, __func__, + "pulse: %s", cp); break; } @@ -616,7 +608,7 @@ jupiter_receive(struct recvbuf *rbufp) break; /* Add the new sample to a median filter */ - tstamp.l_ui = JAN_1970 + last_timecode; + tstamp.l_ui = JAN_1970 + (u_int32)last_timecode; tstamp.l_uf = 0; refclock_process_offset(pp, tstamp, pp->lastrec, pp->fudgetime1); @@ -652,24 +644,24 @@ jupiter_receive(struct recvbuf *rbufp) case JUPITER_O_GPOS: if (size != sizeof(struct jgpos)) { - jupiter_debug(peer, - "jupiter_receive", "gpos: len %d != %u", + jupiter_debug(peer, __func__, + "gpos: len %d != %u", size, (int)sizeof(struct jgpos)); refclock_report(peer, CEVNT_BADREPLY); break; } if ((cp = jupiter_parse_gpos(instance, sp)) != NULL) { - jupiter_debug(peer, - "jupiter_receive", "gpos: %s", cp); + jupiter_debug(peer, __func__, + "gpos: %s", cp); break; } break; case JUPITER_O_ID: if (size != sizeof(struct jid)) { - jupiter_debug(peer, - "jupiter_receive", "id: len %d != %u", + jupiter_debug(peer, __func__, + "id: len %d != %u", size, (int)sizeof(struct jid)); refclock_report(peer, CEVNT_BADREPLY); break; @@ -679,8 +671,8 @@ jupiter_receive(struct recvbuf *rbufp) * just powered instance, it needs to be reconfigured. */ ip = (struct jid *)sp; - jupiter_debug(peer, - "jupiter_receive", "%s chan ver %s, %s (%s)", + jupiter_debug(peer, __func__, + "%s chan ver %s, %s (%s)", ip->chans, ip->vers, ip->date, ip->opts); msyslog(LOG_DEBUG, "jupiter_receive: %s chan ver %s, %s (%s)", @@ -688,8 +680,7 @@ jupiter_receive(struct recvbuf *rbufp) if (instance->wantid) instance->wantid = 0; else { - jupiter_debug(peer, - "jupiter_receive", "reset receiver"); + jupiter_debug(peer, __func__, "reset receiver"); jupiter_config(instance); /* * Restore since jupiter_config() just @@ -700,8 +691,7 @@ jupiter_receive(struct recvbuf *rbufp) break; default: - jupiter_debug(peer, - "jupiter_receive", "unknown message id %d", + jupiter_debug(peer, __func__, "unknown message id %d", getshort(hp->id)); break; } @@ -714,7 +704,7 @@ jupiter_receive(struct recvbuf *rbufp) } } -static char * +static const char * jupiter_parse_t(struct instance *instance, u_short *sp) { struct tm *tm; @@ -764,8 +754,8 @@ jupiter_parse_t(struct instance *instance, u_short *sp) } else if (sweek == 0 && instance->lastsweek == WEEKSECS - 1) { ++instance->gweek; - jupiter_debug(instance->peer, - "jupiter_parse_t", "NEW gps week %u", instance->gweek); + jupiter_debug(instance->peer, __func__, + "NEW gps week %u", instance->gweek); } /* @@ -781,14 +771,14 @@ jupiter_parse_t(struct instance *instance, u_short *sp) * Then we warped. */ if (instance->lastsweek == sweek) - jupiter_debug(instance->peer, - "jupiter_parse_t", "gps sweek not incrementing (%d)", + jupiter_debug(instance->peer, __func__, + "gps sweek not incrementing (%d)", sweek); else if (instance->lastsweek != 2 * WEEKSECS && instance->lastsweek + 1 != sweek && !(sweek == 0 && instance->lastsweek == WEEKSECS - 1)) - jupiter_debug(instance->peer, - "jupiter_parse_t", "gps sweek jumped (was %d, now %d)", + jupiter_debug(instance->peer, __func__, + "gps sweek jumped (was %d, now %d)", instance->lastsweek, sweek); instance->lastsweek = sweek; @@ -799,16 +789,16 @@ jupiter_parse_t(struct instance *instance, u_short *sp) if (last_timecode == 0) /* XXX debugging */ - jupiter_debug(instance->peer, - "jupiter_parse_t", "UTC (gweek/sweek %u/%u)", + jupiter_debug(instance->peer, __func__, + "UTC (gweek/sweek %u/%u)", instance->gweek, sweek); else { /* XXX debugging */ tm = gmtime(&last_timecode); cp = asctime(tm); - jupiter_debug(instance->peer, - "jupiter_parse_t", "UTC %.24s (gweek/sweek %u/%u)", + jupiter_debug(instance->peer, __func__, + "UTC %.24s (gweek/sweek %u/%u)", cp, instance->gweek, sweek); /* Billboard last_timecode (which is now the current time) */ @@ -836,7 +826,7 @@ jupiter_parse_t(struct instance *instance, u_short *sp) return (NULL); } -static char * +static const char * jupiter_parse_gpos(struct instance *instance, u_short *sp) { struct jgpos *jg; @@ -868,8 +858,8 @@ jupiter_parse_gpos(struct instance *instance, u_short *sp) tm = gmtime(&t); cp = asctime(tm); - jupiter_debug(instance->peer, - "jupiter_parse_g", "GPS %.24s (gweek/sweek %u/%u)", + jupiter_debug(instance->peer, __func__, + "GPS %.24s (gweek/sweek %u/%u)", cp, instance->gpos_gweek, instance->gpos_sweek); return (NULL); } @@ -877,36 +867,27 @@ jupiter_parse_gpos(struct instance *instance, u_short *sp) /* * jupiter_debug - print debug messages */ -#if defined(__STDC__) || defined(SYS_WINNT) -static void -jupiter_debug(struct peer *peer, char *function, char *fmt, ...) -#else static void -jupiter_debug(peer, function, fmt, va_alist) - struct peer *peer; - char *function; - char *fmt; -#endif /* __STDC__ */ +jupiter_debug( + struct peer * peer, + const char * function, + const char * fmt, + ... + ) { - char buffer[200]; - va_list ap; + char buffer[200]; + va_list ap; -#if defined(__STDC__) || defined(SYS_WINNT) va_start(ap, fmt); -#else - va_start(ap); -#endif /* __STDC__ */ /* * Print debug message to stdout * In the future, we may want to get get more creative... */ - vsnprintf(buffer, sizeof(buffer), fmt, ap); - record_clock_stats(&(peer->srcadr), buffer); + mvsnprintf(buffer, sizeof(buffer), fmt, ap); + record_clock_stats(&peer->srcadr, buffer); #ifdef DEBUG if (debug) { - fprintf(stdout, "%s: ", function); - fprintf(stdout, buffer); - fprintf(stdout, "\n"); + printf("%s: %s\n", function, buffer); fflush(stdout); } #endif @@ -919,7 +900,7 @@ static char * jupiter_send(struct instance *instance, struct jheader *hp) { u_int len, size; - int cc; + ssize_t cc; u_short *sp; static char errstr[132]; @@ -934,10 +915,10 @@ jupiter_send(struct instance *instance, struct jheader *hp) } if ((cc = write(instance->peer->procptr->io.fd, (char *)hp, size)) < 0) { - (void)sprintf(errstr, "write: %s", strerror(errno)); + msnprintf(errstr, sizeof(errstr), "write: %m"); return (errstr); - } else if (cc != size) { - (void)sprintf(errstr, "short write (%d != %d)", cc, size); + } else if (cc != (int)size) { + snprintf(errstr, sizeof(errstr), "short write (%zd != %u)", cc, size); return (errstr); } return (NULL); @@ -970,7 +951,7 @@ jupiter_reqmsg(struct instance *instance, u_int id, rp->trigger = putshort(interval == 0); rp->interval = putshort(interval); if ((cp = jupiter_send(instance, hp)) != NULL) - jupiter_debug(instance->peer, "jupiter_reqmsg", "%u: %s", id, cp); + jupiter_debug(instance->peer, __func__, "%u: %s", id, cp); } /* Cancel periodic message output */ @@ -989,7 +970,7 @@ jupiter_canmsg(struct instance *instance, u_int id) hp = &canmsg; hp->id = putshort(id); if ((cp = jupiter_send(instance, hp)) != NULL) - jupiter_debug(instance->peer, "jupiter_canmsg", "%u: %s", id, cp); + jupiter_debug(instance->peer, __func__, "%u: %s", id, cp); } /* Request a single message output */ @@ -1008,7 +989,7 @@ jupiter_reqonemsg(struct instance *instance, u_int id) hp = &reqonemsg; hp->id = putshort(id); if ((cp = jupiter_send(instance, hp)) != NULL) - jupiter_debug(instance->peer, "jupiter_reqonemsg", "%u: %s", id, cp); + jupiter_debug(instance->peer, __func__, "%u: %s", id, cp); } /* Set the platform dynamics */ @@ -1033,7 +1014,7 @@ jupiter_platform(struct instance *instance, u_int platform) pp = &platmsg.jplat; pp->platform = putshort(platform); if ((cp = jupiter_send(instance, hp)) != NULL) - jupiter_debug(instance->peer, "jupiter_platform", "%u: %s", platform, cp); + jupiter_debug(instance->peer, __func__, "%u: %s", platform, cp); } /* Checksum "len" shorts */ @@ -1070,13 +1051,14 @@ jupiter_recv(struct instance *instance) hp = (struct jheader *)sp; if (getshort(hp->sync) != JUPITER_SYNC) { /* Wasn't at the front, sync up */ - jupiter_debug(instance->peer, "jupiter_recv", "syncing"); + jupiter_debug(instance->peer, __func__, "syncing"); bp = (u_char *)sp; n = size; while (n >= 2) { if (bp[0] != (JUPITER_SYNC & 0xff)) { /* - jupiter_debug(instance->peer, "{0x%x}", bp[0]); + jupiter_debug(instance->peer, __func__, + "{0x%x}", bp[0]); */ ++bp; --n; @@ -1085,13 +1067,14 @@ jupiter_recv(struct instance *instance) if (bp[1] == ((JUPITER_SYNC >> 8) & 0xff)) break; /* - jupiter_debug(instance->peer, "{0x%x 0x%x}", bp[0], bp[1]); + jupiter_debug(instance->peer, __func__, + "{0x%x 0x%x}", bp[0], bp[1]); */ bp += 2; n -= 2; } /* - jupiter_debug(instance->peer, "\n"); + jupiter_debug(instance->peer, __func__, "\n"); */ /* Shuffle data to front of input buffer */ if (n > 0) @@ -1104,7 +1087,7 @@ jupiter_recv(struct instance *instance) if (jupiter_cksum(sp, (cc / sizeof(u_short) - 1)) != getshort(hp->hsum)) { - jupiter_debug(instance->peer, "jupiter_recv", "bad header checksum!"); + jupiter_debug(instance->peer, __func__, "bad header checksum!"); /* This is drastic but checksum errors should be rare */ instance->ssize = 0; return (0); @@ -1122,7 +1105,7 @@ jupiter_recv(struct instance *instance) sp = (u_short *)(hp + 1); if (jupiter_cksum(sp, len) != getshort(sp[len])) { jupiter_debug(instance->peer, - "jupiter_recv", "bad payload checksum!"); + __func__, "bad payload checksum!"); /* This is drastic but checksum errors should be rare */ instance->ssize = 0; return (0); diff --git a/contrib/ntp/ntpd/refclock_leitch.c b/contrib/ntp/ntpd/refclock_leitch.c index e1ba0c409..69ffdc5ed 100644 --- a/contrib/ntp/ntpd/refclock_leitch.c +++ b/contrib/ntp/ntpd/refclock_leitch.c @@ -6,23 +6,17 @@ # include #endif -#if defined(REFCLOCK) && defined(CLOCK_LEITCH) +#include "ntp_types.h" -#include "ntpd.h" -#include "ntp_io.h" -#include "ntp_refclock.h" -#include "ntp_unixtime.h" +#if defined(REFCLOCK) && defined(CLOCK_LEITCH) #include #include -#ifdef STREAM -#include -#if defined(LEITCHCLK) -#include -#endif /* LEITCHCLK */ -#endif /* STREAM */ - +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_refclock.h" +#include "timevalops.h" #include "ntp_stdlib.h" @@ -43,6 +37,7 @@ * STATUS: G (good), D (diag fail), T (time not provided) or * P (last phone update failed) */ +#define PRECISION (-20) /* 1x10-8 */ #define MAXUNITS 1 /* max number of LEITCH units */ #define LEITCHREFID "ATOM" /* reference id */ #define LEITCH_DESCRIPTION "Leitch: CSD 5300 Master Clock System Driver" @@ -96,20 +91,20 @@ struct leitchunit { /* * Function prototypes */ -static void leitch_init P((void)); -static int leitch_start P((int, struct peer *)); -static void leitch_shutdown P((int, struct peer *)); -static void leitch_poll P((int, struct peer *)); -static void leitch_control P((int, struct refclockstat *, struct refclockstat *, struct peer *)); +static void leitch_init (void); +static int leitch_start (int, struct peer *); +static void leitch_shutdown (int, struct peer *); +static void leitch_poll (int, struct peer *); +static void leitch_control (int, const struct refclockstat *, struct refclockstat *, struct peer *); #define leitch_buginfo noentry -static void leitch_receive P((struct recvbuf *)); -static void leitch_process P((struct leitchunit *)); +static void leitch_receive (struct recvbuf *); +static void leitch_process (struct leitchunit *); #if 0 -static void leitch_timeout P((struct peer *)); +static void leitch_timeout (struct peer *); #endif -static int leitch_get_date P((struct recvbuf *, struct leitchunit *)); -static int leitch_get_time P((struct recvbuf *, struct leitchunit *, int)); -static int days_per_year P((int)); +static int leitch_get_date (struct recvbuf *, struct leitchunit *); +static int leitch_get_time (struct recvbuf *, struct leitchunit *, int); +static int days_per_year (int); static struct leitchunit leitchunits[MAXUNITS]; static u_char unitinuse[MAXUNITS]; @@ -149,9 +144,17 @@ leitch_shutdown( struct peer *peer ) { + struct leitchunit *leitch; + + if (unit >= MAXUNITS) { + return; + } + leitch = &leitchunits[unit]; + if (-1 != leitch->leitchio.fd) + io_closeclock(&leitch->leitchio); #ifdef DEBUG if (debug) - fprintf(stderr, "leitch_shutdown()\n"); + fprintf(stderr, "leitch_shutdown()\n"); #endif } @@ -192,7 +195,7 @@ leitch_poll( static void leitch_control( int unit, - struct refclockstat *in, + const struct refclockstat *in, struct refclockstat *out, struct peer *passed_peer ) @@ -257,7 +260,7 @@ leitch_start( /* * Open serial port. */ - (void) sprintf(leitchdev, LEITCH232, unit); + snprintf(leitchdev, sizeof(leitchdev), LEITCH232, unit); fd232 = open(leitchdev, O_RDWR, 0777); if (fd232 == -1) { msyslog(LOG_ERR, @@ -266,7 +269,7 @@ leitch_start( } leitch = &leitchunits[unit]; - memset((char*)leitch, 0, sizeof(*leitch)); + memset(leitch, 0, sizeof(*leitch)); #if defined(HAVE_SYSV_TTYS) /* @@ -294,9 +297,6 @@ leitch_start( #if defined(HAVE_TERMIOS) /* * POSIX serial line parameters (termios interface) - * - * The LEITCHCLK option provides timestamping at the driver level. - * It requires the tty_clk streams module. */ { struct termios ttyb, *ttyp; @@ -323,27 +323,12 @@ leitch_start( } } #endif /* HAVE_TERMIOS */ -#ifdef STREAM -#if defined(LEITCHCLK) - if (ioctl(fd232, I_PUSH, "clk") < 0) - msyslog(LOG_ERR, - "leitch_start: ioctl(%s, I_PUSH, clk): %m", leitchdev); - if (ioctl(fd232, CLK_SETSTR, "\n") < 0) - msyslog(LOG_ERR, - "leitch_start: ioctl(%s, CLK_SETSTR): %m", leitchdev); -#endif /* LEITCHCLK */ -#endif /* STREAM */ #if defined(HAVE_BSD_TTYS) /* * 4.3bsd serial line parameters (sgttyb interface) - * - * The LEITCHCLK option provides timestamping at the driver level. - * It requires the tty_clk line discipline and 4.3bsd or later. */ - { struct sgttyb ttyb; -#if defined(LEITCHCLK) - int ldisc = CLKLDISC; -#endif /* LEITCHCLK */ + { + struct sgttyb ttyb; if (ioctl(fd232, TIOCGETP, &ttyb) < 0) { msyslog(LOG_ERR, @@ -351,25 +336,13 @@ leitch_start( goto screwed; } ttyb.sg_ispeed = ttyb.sg_ospeed = SPEED232; -#if defined(LEITCHCLK) - ttyb.sg_erase = ttyb.sg_kill = '\r'; - ttyb.sg_flags = RAW; -#else ttyb.sg_erase = ttyb.sg_kill = '\0'; ttyb.sg_flags = EVENP|ODDP|CRMOD; -#endif /* LEITCHCLK */ if (ioctl(fd232, TIOCSETP, &ttyb) < 0) { msyslog(LOG_ERR, "leitch_start: ioctl(%s, TIOCSETP): %m", leitchdev); goto screwed; } -#if defined(LEITCHCLK) - if (ioctl(fd232, TIOCSETD, &ldisc) < 0) { - msyslog(LOG_ERR, - "leitch_start: ioctl(%s, TIOCSETD): %m",leitchdev); - goto screwed; - } -#endif /* LEITCHCLK */ } #endif /* HAVE_BSD_TTYS */ @@ -382,10 +355,11 @@ leitch_start( leitch->fudge1 = 15; /* 15ms */ leitch->leitchio.clock_recv = leitch_receive; - leitch->leitchio.srcclock = (caddr_t) leitch; + leitch->leitchio.srcclock = peer; leitch->leitchio.datalen = 0; leitch->leitchio.fd = fd232; if (!io_addclock(&leitch->leitchio)) { + leitch->leitchio.fd = -1; goto screwed; } @@ -393,7 +367,7 @@ leitch_start( * All done. Initialize a few random peer variables, then * return success. */ - peer->precision = 0; + peer->precision = PRECISION; peer->stratum = stratumtouse[unit]; peer->refid = refid[unit]; unitinuse[unit] = 1; @@ -416,7 +390,7 @@ leitch_receive( struct recvbuf *rbufp ) { - struct leitchunit *leitch = (struct leitchunit *)rbufp->recv_srcclock; + struct leitchunit *leitch = rbufp->recv_peer->procptr->unitptr; #ifdef DEBUG if (debug) @@ -622,5 +596,5 @@ leitch_get_time( } #else -int refclock_leitch_bs; +NONEMPTY_TRANSLATION_UNIT #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_local.c b/contrib/ntp/ntpd/refclock_local.c index dc6f1aefd..d816c55c1 100644 --- a/contrib/ntp/ntpd/refclock_local.c +++ b/contrib/ntp/ntpd/refclock_local.c @@ -24,19 +24,20 @@ /* * This is a hack to allow a machine to use its own system clock as a * reference clock, i.e., to free-run using no outside clock discipline - * source. This is useful if you want to use NTP in an isolated - * environment with no radio clock or NIST modem available. Pick a - * machine that you figure has a good clock oscillator and configure it - * with this driver. Set the clock using the best means available, like + * source. Note that the clock selection algorithm will not select this + * driver unless all other sources of synchronization have been lost. + * This is useful if you want to use NTP in an isolated environment + * with no radio clock or NIST modem available. Pick a machine that you + * figure has a good clock oscillator and configure it with this + * driver. Set the clock using the best means available, like * eyeball-and-wristwatch. Then, point all the other machines at this * one or use broadcast (not multicast) mode to distribute time. * * Another application for this driver is if you want to use a * particular server's clock as the clock of last resort when all other * normal synchronization sources have gone away. This is especially - * useful if that server has an ovenized oscillator. For this you would - * configure this driver at a higher stratum (say 5) to prevent the - * server's stratum from falling below that. + * useful if that server has an ovenized oscillator. However, the + * preferred was to do this is using orphan mode. See the documentation. * * A third application for this driver is when an external discipline * source is available, such as the NIST "lockclock" program, which @@ -52,42 +53,9 @@ * oscillator. In extreme cases, this can cause clients to exceed the * 128-ms slew window and drop off the NTP subnet. * - * THis driver includes provisions to telegraph synchronization state - * and related variables by means of kernel variables with specially - * modified kernels. This is done using the ntp_adjtime() syscall. - * In the cases where another protocol or device synchronizes the local - * host, the data given to the kernel can be slurped up by this driver - * and distributed to clients by ordinary NTP messaging. - * - * In the default mode the behavior of the clock selection algorithm is - * modified when this driver is in use. The algorithm is designed so - * that this driver will never be selected unless no other discipline - * source is available. This can be overriden with the prefer keyword of - * the server configuration command, in which case only this driver will - * be selected for synchronization and all other discipline sources will - * be ignored. This behavior is intended for use when an external - * discipline source controls the system clock. - * * Fudge Factors * - * The stratum for this driver set at 5 by default, but it can be - * changed by the fudge command and/or the ntpdc utility. The reference - * ID is 127.0.0.1 by default, but can be changed using the same mechanism. - * *NEVER* configure this driver to operate at a stratum which might - * possibly disrupt a client with access to a bona fide primary server, - * unless the local clock oscillator is reliably disciplined by another - * source. *NEVER NEVER* configure a server which might devolve to an - * undisciplined local clock to use multicast mode. Always remember that - * an improperly configured local clock driver let loose in the Internet - * can cause very serious disruption. This is why most of us who care - * about good time use cryptographic authentication. - * - * This driver provides a mechanism to trim the local clock in both time - * and frequency, as well as a way to manipulate the leap bits. The - * fudge time1 parameter adjusts the time, in seconds, and the fudge - * time2 parameter adjusts the frequency, in ppm. The fudge time1 - * parameter is additive; that is, it adds an increment to the current - * time. The fudge time2 parameter directly sets the frequency. + * None currently supported. */ /* * Local interface definitions @@ -107,20 +75,11 @@ extern u_long current_time; */ extern s_char sys_precision; -#ifdef KERNEL_PLL -/* - * Imported from ntp_loopfilter - */ -extern int pll_control; /* kernel pll control */ -extern int kern_enable; /* kernel pll enabled */ -extern int ext_enable; /* external clock enable */ -#endif /* KERNEL_PLL */ - /* * Function prototypes */ -static int local_start P((int, struct peer *)); -static void local_poll P((int, struct peer *)); +static int local_start (int, struct peer *); +static void local_poll (int, struct peer *); /* * Local variables @@ -191,6 +150,12 @@ local_poll( #endif /* KERNEL_PLL LOCKCLOCK */ struct refclockproc *pp; + /* + * Do no evil unless the house is dark or lit with our own lamp. + */ + if (!(sys_peer == NULL || sys_peer == peer)) + return; + #if defined(VMS) && defined(VMS_LOCALUNIT) if (unit == VMS_LOCALUNIT) { extern void vms_local_poll(struct peer *); @@ -199,22 +164,17 @@ local_poll( return; } #endif /* VMS && VMS_LOCALUNIT */ + pp = peer->procptr; pp->polls++; /* * Ramble through the usual filtering and grooming code, which * is essentially a no-op and included mostly for pretty - * billboards. We allow a one-time time adjustment using fudge - * time1 (s) and a continuous frequency adjustment using fudge - * time 2 (ppm). + * billboards. */ - get_systime(&pp->lastrec); - pp->fudgetime1 += pp->fudgetime2 * 1e-6 * (current_time - - poll_time); poll_time = current_time; - refclock_process_offset(pp, pp->lastrec, pp->lastrec, - pp->fudgetime1); + refclock_process_offset(pp, pp->lastrec, pp->lastrec, 0); /* * If another process is disciplining the system clock, we set @@ -245,13 +205,11 @@ local_poll( pp->disp = 0; pp->jitter = 0; #else /* KERNEL_PLL LOCKCLOCK */ - pp->leap = LEAP_NOWARNING; pp->disp = DISPERSION; pp->jitter = 0; #endif /* KERNEL_PLL LOCKCLOCK */ pp->lastref = pp->lastrec; refclock_receive(peer); - pp->fudgetime1 = 0; } #else int refclock_local_bs; diff --git a/contrib/ntp/ntpd/refclock_msfees.c b/contrib/ntp/ntpd/refclock_msfees.c index 98034b587..8399c96e7 100644 --- a/contrib/ntp/ntpd/refclock_msfees.c +++ b/contrib/ntp/ntpd/refclock_msfees.c @@ -4,6 +4,8 @@ #include #endif +#include "ntp_types.h" + #if defined(REFCLOCK) && defined(CLOCK_MSFEES) && defined(PPS) /* Currently REQUIRES STREAM and PPSCD. CLK and CBREAK modes @@ -14,8 +16,7 @@ #include "ntpd.h" #include "ntp_io.h" #include "ntp_refclock.h" -#include "ntp_unixtime.h" -#include "ntp_calendar.h" +#include "timevalops.h" #include #if defined(HAVE_BSD_TTYS) @@ -349,11 +350,7 @@ static void dump_buf P((l_fp *coffs, int from, int to, char *text)); static void ees_report_event P((struct eesunit *ees, int code)); static void ees_receive P((struct recvbuf *rbufp)); static void ees_process P((struct eesunit *ees)); -#ifdef QSORT_USES_VOID_P static int offcompare P((const void *va, const void *vb)); -#else -static int offcompare P((const l_fp *a, const l_fp *b)); -#endif /* QSORT_USES_VOID_P */ /* @@ -382,11 +379,15 @@ dump_buf( int i; register char *ptr = buff; - sprintf(ptr, text); - for (i=from; i DUMP_BUF_SIZE) msyslog(LOG_DEBUG, "D: %s", ptr=buff); - sprintf(ptr, " %06d", ((int)coffs[i].l_f) / 4295); + snprintf(buff, sizeof(buff), text); + for (i = from; i < to; i++) { + ptr += strlen(ptr); + if ((ptr - buff) > DUMP_BUF_SIZE) { + msyslog(LOG_DEBUG, "D: %s", buff); + ptr = buff; + } + snprintf(ptr, sizeof(buff) - (ptr - buff), + " %06d", ((int)coffs[i].l_f) / 4295); } msyslog(LOG_DEBUG, "D: %s", buff); } @@ -450,7 +451,7 @@ msfees_start( /* Unit okay, attempt to open the devices. We do them both at * once to make sure we can */ - (void) sprintf(eesdev, EES232, unit); + snprintf(eesdev, sizeof(eesdev), EES232, unit); fd232 = open(eesdev, O_RDWR, 0777); if (fd232 == -1) { @@ -533,7 +534,7 @@ msfees_start( ees->timestarted= current_time; ees->ttytype = 0; ees->io.clock_recv= ees_receive; - ees->io.srcclock= (caddr_t)ees; + ees->io.srcclock= peer; ees->io.datalen = 0; ees->io.fd = fd232; @@ -585,7 +586,7 @@ msfees_start( peer->refid = htonl(EESHSREFID); } unitinuse[unit] = 1; - pp->unitptr = (caddr_t) &eesunits[unit]; + pp->unitptr = &eesunits[unit]; pp->clockdesc = EESDESCRIPTION; msyslog(LOG_ERR, "ees clock: %s OK on %d", eesdev, unit); return (1); @@ -673,7 +674,7 @@ ees_receive( #endif /* Get the clock this applies to and a pointer to the data */ - ees = (struct eesunit *)rbufp->recv_srcclock; + ees = (struct eesunit *)rbufp->recv_peer->procptr->unitptr; dpt = (u_char *)&rbufp->recv_space; dpend = dpt + rbufp->recv_length; if ((dbg & DB_LOG_AWAITMORE) && (rbufp->recv_length != LENEESCODE)) @@ -917,9 +918,9 @@ ees_receive( if (pps_step != 1 && pps_step != 2) fprintf(stderr, "PPS step: %d too far off %ld (%d)\n", ppsclockev.serial, ees->last_pps_no, pps_step); - else if (!buftvtots((char *) &(ppsclockev.tv), &pps_arrvstamp)) - fprintf(stderr, "buftvtots failed\n"); - else { /* if ((ABS(time difference) - 0.25) < 0) + else { + pps_arrvstamp = tval_stamp_to_lfp(ppsclockev.tv); + /* if ((ABS(time difference) - 0.25) < 0) * then believe it ... */ l_fp diff; @@ -987,17 +988,20 @@ ees_receive( /* Dump the deltas each minute */ if (dbg & DB_DUMP_DELTAS) - { if (/*0 <= ees->second && */ - ees->second < ((sizeof deltas) / (sizeof deltas[0]))) deltas[ees->second] = delta_sfsec; + { + if (/*0 <= ees->second && */ + ees->second < COUNTOF(deltas)) + deltas[ees->second] = delta_sfsec; /* Dump on second 1, as second 0 sometimes missed */ if (ees->second == 1) { - char text[16 * ((sizeof deltas) / (sizeof deltas[0]))]; + char text[16 * COUNTOF(deltas)]; char *cptr=text; int i; - for (i=0; i<((sizeof deltas) / (sizeof deltas[0])); i++) { - sprintf(cptr, " %d.%04d", - msec(deltas[i]), subms(deltas[i])); - while (*cptr) cptr++; + for (i = 0; i < COUNTOF(deltas); i++) { + snprintf(cptr, sizeof(text) / COUNTOF(deltas), + " %d.%04d", msec(deltas[i]), + subms(deltas[i])); + cptr += strlen(cptr); } msyslog(LOG_ERR, "Deltas: %d.%04d<->%d.%04d: %s", msec(EES_STEP_F - EES_STEP_F_GRACE), subms(EES_STEP_F - EES_STEP_F_GRACE), @@ -1220,7 +1224,6 @@ ees_receive( /* offcompare - auxiliary comparison routine for offset sort */ -#ifdef QSORT_USES_VOID_P static int offcompare( const void *va, @@ -1231,16 +1234,6 @@ offcompare( const l_fp *b = (const l_fp *)vb; return(L_ISGEQ(a, b) ? (L_ISEQU(a, b) ? 0 : 1) : -1); } -#else -static int -offcompare( - const l_fp *a, - const l_fp *b - ) -{ - return(L_ISGEQ(a, b) ? (L_ISEQU(a, b) ? 0 : 1) : -1); -} -#endif /* QSORT_USES_VOID_P */ /* ees_process - process a pile of samples from the clock */ @@ -1282,16 +1275,11 @@ ees_process( if (samples < 1) return; /* If requested, dump the raw data we have in the buffer */ - if (ees->dump_vals) dump_buf(coffs, 0, samples, "Raw data is:"); + if (ees->dump_vals) + dump_buf(coffs, 0, samples, "Raw data is:"); /* Sort the offsets, trim off the extremes, then choose one. */ - qsort( -#ifdef QSORT_USES_VOID_P - (void *) -#else - (char *) -#endif - coffs, (size_t)samples, sizeof(l_fp), offcompare); + qsort(coffs, (size_t)samples, sizeof(coffs[0]), offcompare); noff = samples; i = 0; @@ -1423,7 +1411,7 @@ ees_process( * reference time, and lastsampletime as the receive time. */ if (ees->fix_pending) { - msyslog(LOG_ERR, "MSF%d: fix_pending=%d -> jump %x.%08x\n", + msyslog(LOG_ERR, "MSF%d: fix_pending=%d -> jump %x.%08x", ees->fix_pending, ees->unit, offset.l_i, offset.l_f); ees->fix_pending = 0; } @@ -1458,5 +1446,5 @@ msfees_poll( #else -int refclock_msfees_bs; +NONEMPTY_TRANSLATION_UNIT #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_mx4200.c b/contrib/ntp/ntpd/refclock_mx4200.c index 68150b7c4..c9422290d 100644 --- a/contrib/ntp/ntpd/refclock_mx4200.c +++ b/contrib/ntp/ntpd/refclock_mx4200.c @@ -67,8 +67,6 @@ # include #endif -#include "ntp_sprintf.h" - #ifndef HAVE_STRUCT_PPSCLOCKEV struct ppsclockev { # ifdef HAVE_STRUCT_TIMESPEC @@ -167,28 +165,24 @@ static char pmvxg[] = "PMVXG"; /* * Function prototypes */ -static int mx4200_start P((int, struct peer *)); -static void mx4200_shutdown P((int, struct peer *)); -static void mx4200_receive P((struct recvbuf *)); -static void mx4200_poll P((int, struct peer *)); - -static char * mx4200_parse_t P((struct peer *)); -static char * mx4200_parse_p P((struct peer *)); -static char * mx4200_parse_s P((struct peer *)); -#ifdef QSORT_USES_VOID_P -int mx4200_cmpl_fp P((const void *, const void *)); -#else -int mx4200_cmpl_fp P((const l_fp *, const l_fp *)); -#endif /* not QSORT_USES_VOID_P */ -static int mx4200_config P((struct peer *)); -static void mx4200_ref P((struct peer *)); -static void mx4200_send P((struct peer *, char *, ...)) +static int mx4200_start (int, struct peer *); +static void mx4200_shutdown (int, struct peer *); +static void mx4200_receive (struct recvbuf *); +static void mx4200_poll (int, struct peer *); + +static char * mx4200_parse_t (struct peer *); +static char * mx4200_parse_p (struct peer *); +static char * mx4200_parse_s (struct peer *); +int mx4200_cmpl_fp (const void *, const void *); +static int mx4200_config (struct peer *); +static void mx4200_ref (struct peer *); +static void mx4200_send (struct peer *, char *, ...) __attribute__ ((format (printf, 2, 3))); -static u_char mx4200_cksum P((char *, int)); -static int mx4200_jday P((int, int, int)); -static void mx4200_debug P((struct peer *, char *, ...)) +static u_char mx4200_cksum (char *, int); +static int mx4200_jday (int, int, int); +static void mx4200_debug (struct peer *, char *, ...) __attribute__ ((format (printf, 2, 3))); -static int mx4200_pps P((struct peer *)); +static int mx4200_pps (struct peer *); /* * Transfer vector @@ -222,31 +216,27 @@ mx4200_start( /* * Open serial port */ - (void)sprintf(gpsdev, DEVICE, unit); - if (!(fd = refclock_open(gpsdev, SPEED232, LDISC_PPS))) { - return (0); - } + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); + fd = refclock_open(gpsdev, SPEED232, LDISC_PPS); + if (fd <= 0) + return 0; /* * Allocate unit structure */ - if (!(up = (struct mx4200unit *) emalloc(sizeof(struct mx4200unit)))) { - perror("emalloc"); - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct mx4200unit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = mx4200_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -273,9 +263,11 @@ mx4200_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -294,7 +286,7 @@ mx4200_config( int mode; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; /* * Initialize the unit variables @@ -494,7 +486,7 @@ mx4200_ref( char nsc, ewc; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; /* Should never happen! */ if (up->moving) return; @@ -576,9 +568,9 @@ mx4200_ref( } alt = up->avg_alt; minute = (lat - (double)(int)lat) * 60.0; - sprintf(lats,"%02d%02.4f", (int)lat, minute); + snprintf(lats, sizeof(lats), "%02d%02.4f", (int)lat, minute); minute = (lon - (double)(int)lon) * 60.0; - sprintf(lons,"%03d%02.4f", (int)lon, minute); + snprintf(lons, sizeof(lons), "%03d%02.4f", (int)lon, minute); mx4200_send(peer, "%s,%03d,,,,,%s,%c,%s,%c,%.2f,%d", pmvxg, PMVXG_S_INITMODEA, @@ -612,7 +604,7 @@ mx4200_poll( struct refclockproc *pp; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; /* * You don't need to poll this clock. It puts out timecodes @@ -679,9 +671,9 @@ mx4200_receive( /* * Initialize pointers and read the timecode and timestamp. */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; /* * If operating mode has been changed, then reinitialize the receiver @@ -845,7 +837,7 @@ mx4200_receive( * Capture the last PPS signal. * Precision timestamp is returned in pp->lastrec */ - if (mx4200_pps(peer) != NULL) { + if (0 != mx4200_pps(peer)) { mx4200_debug(peer, "mx4200_receive: pps failure\n"); refclock_report(peer, CEVNT_FAULT); return; @@ -961,18 +953,18 @@ mx4200_parse_t( char time_mark_valid, time_sync, op_mode; int sentence_type, valid; int year, day_of_year, month, day_of_month; - int hour, minute, second, leapsec; + int hour, minute, second, leapsec_warn; int oscillator_offset, time_mark_error, time_bias; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; - leapsec = 0; /* Not all receivers output leap second warnings (!) */ + leapsec_warn = 0; /* Not all receivers output leap second warnings (!) */ sscanf(pp->a_lastcode, "$PMVXG,%d,%c,%d,%d,%d,%d:%d:%d,%c,%c,%d,%d,%d,%d", &sentence_type, &time_mark_valid, &year, &month, &day_of_month, &hour, &minute, &second, &time_sync, &op_mode, - &oscillator_offset, &time_mark_error, &time_bias, &leapsec); + &oscillator_offset, &time_mark_error, &time_bias, &leapsec_warn); if (sentence_type != PMVXG_D_TRECOVOUT) return ("wrong rec-type"); @@ -1005,8 +997,8 @@ mx4200_parse_t( mx4200_debug(peer, "mx4200_parse_t: bad time %02d:%02d:%02d", hour, minute, second); - if (leapsec != 0) - mx4200_debug(peer, " (leap %+d\n)", leapsec); + if (leapsec_warn != 0) + mx4200_debug(peer, " (leap %+d\n)", leapsec_warn); mx4200_debug(peer, "\n"); refclock_report(peer, CEVNT_BADTIME); return ("bad time"); @@ -1068,7 +1060,7 @@ mx4200_parse_t( /* * Setup leap second indicator */ - switch (leapsec) { + switch (leapsec_warn) { case 0: pp->leap = LEAP_NOWARNING; break; @@ -1085,12 +1077,12 @@ mx4200_parse_t( /* * Any change to the leap second warning status? */ - if (leapsec != up->last_leap ) { + if (leapsec_warn != up->last_leap ) { msyslog(LOG_DEBUG, "mx4200: leap second warning: %d to %d (%d)", - up->last_leap, leapsec, pp->leap); + up->last_leap, leapsec_warn, pp->leap); } - up->last_leap = leapsec; + up->last_leap = leapsec_warn; /* * Copy time data for billboard monitoring. @@ -1245,7 +1237,7 @@ mx4200_parse_p( char north_south, east_west; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; /* Should never happen! */ if (up->moving) return ("mobile platform - no pos!"); @@ -1464,7 +1456,7 @@ mx4200_parse_s( int sentence_type; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; sscanf ( pp->a_lastcode, "$PMVXG,%d", &sentence_type); @@ -1509,7 +1501,7 @@ mx4200_pps( struct timespec timeout; pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; /* * Grab the timestamp of the PPS signal. @@ -1520,14 +1512,14 @@ mx4200_pps( if (time_pps_fetch(up->pps_h, PPS_TSFMT_TSPEC, &(up->pps_i), &timeout) < 0) { mx4200_debug(peer, - "mx4200_pps: time_pps_fetch: serial=%ul, %s\n", - (unsigned long)up->pps_i.assert_sequence, strerror(errno)); + "mx4200_pps: time_pps_fetch: serial=%lu, %m\n", + (unsigned long)up->pps_i.assert_sequence); refclock_report(peer, CEVNT_FAULT); return(1); } if (temp_serial == up->pps_i.assert_sequence) { mx4200_debug(peer, - "mx4200_pps: assert_sequence serial not incrementing: %ul\n", + "mx4200_pps: assert_sequence serial not incrementing: %lu\n", (unsigned long)up->pps_i.assert_sequence); refclock_report(peer, CEVNT_FAULT); return(1); @@ -1540,7 +1532,7 @@ mx4200_pps( if (up->pps_i.assert_sequence == up->lastserial) { mx4200_debug(peer, "mx4200_pps: no new pps event\n"); } else { - mx4200_debug(peer, "mx4200_pps: missed %ul pps events\n", + mx4200_debug(peer, "mx4200_pps: missed %lu pps events\n", up->pps_i.assert_sequence - up->lastserial - 1UL); } refclock_report(peer, CEVNT_FAULT); @@ -1562,15 +1554,8 @@ mx4200_pps( /* * mx4200_debug - print debug messages */ -#if defined(__STDC__) static void mx4200_debug(struct peer *peer, char *fmt, ...) -#else -static void -mx4200_debug(peer, fmt, va_alist) - struct peer *peer; - char *fmt; -#endif /* __STDC__ */ { #ifdef DEBUG va_list ap; @@ -1578,22 +1563,16 @@ mx4200_debug(peer, fmt, va_alist) struct mx4200unit *up; if (debug) { - -#if defined(__STDC__) va_start(ap, fmt); -#else - va_start(ap); -#endif /* __STDC__ */ pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; - + up = pp->unitptr; /* * Print debug message to stdout * In the future, we may want to get get more creative... */ - vprintf(fmt, ap); + mvprintf(fmt, ap); va_end(ap); } @@ -1630,7 +1609,7 @@ mx4200_send(peer, fmt, va_alist) #endif /* __STDC__ */ pp = peer->procptr; - up = (struct mx4200unit *)pp->unitptr; + up = pp->unitptr; cp = buf; *cp++ = '$'; diff --git a/contrib/ntp/ntpd/refclock_neoclock4x.c b/contrib/ntp/ntpd/refclock_neoclock4x.c index 374c81aea..6fda0f078 100644 --- a/contrib/ntp/ntpd/refclock_neoclock4x.c +++ b/contrib/ntp/ntpd/refclock_neoclock4x.c @@ -3,18 +3,11 @@ * Refclock_neoclock4x.c * - NeoClock4X driver for DCF77 or FIA Timecode * - * Date: 2006-01-11 v1.15 + * Date: 2009-12-04 v1.16 * * see http://www.linum.com/redir/jump/id=neoclock4x&action=redir * for details about the NeoClock4X device * - * Copyright (C) 2002-2004 by Linum Software GmbH - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * */ #ifdef HAVE_CONFIG_H @@ -109,7 +102,7 @@ #define NEOCLOCK4X_OFFSET_ANTENNA2 33 #define NEOCLOCK4X_OFFSET_CRC 35 -#define NEOCLOCK4X_DRIVER_VERSION "1.15 (2006-01-11)" +#define NEOCLOCK4X_DRIVER_VERSION "1.16 (2009-12-04)" #define NSEC_TO_MILLI 1000000 @@ -138,20 +131,20 @@ struct neoclock4x_unit { int utc_msec; }; -static int neoclock4x_start P((int, struct peer *)); -static void neoclock4x_shutdown P((int, struct peer *)); -static void neoclock4x_receive P((struct recvbuf *)); -static void neoclock4x_poll P((int, struct peer *)); -static void neoclock4x_control P((int, struct refclockstat *, struct refclockstat *, struct peer *)); - -static int neol_atoi_len P((const char str[], int *, int)); -static int neol_hexatoi_len P((const char str[], int *, int)); -static void neol_jdn_to_ymd P((unsigned long, int *, int *, int *)); -static void neol_localtime P((unsigned long, int* , int*, int*, int*, int*, int*)); -static unsigned long neol_mktime P((int, int, int, int, int, int)); +static int neoclock4x_start (int, struct peer *); +static void neoclock4x_shutdown (int, struct peer *); +static void neoclock4x_receive (struct recvbuf *); +static void neoclock4x_poll (int, struct peer *); +static void neoclock4x_control (int, const struct refclockstat *, struct refclockstat *, struct peer *); + +static int neol_atoi_len (const char str[], int *, int); +static int neol_hexatoi_len (const char str[], int *, int); +static void neol_jdn_to_ymd (unsigned long, int *, int *, int *); +static void neol_localtime (unsigned long, int* , int*, int*, int*, int*, int*); +static unsigned long neol_mktime (int, int, int, int, int, int); #if !defined(NEOCLOCK4X_FIRMWARE) -static int neol_query_firmware P((int, int, char *, int)); -static int neol_check_firmware P((int, const char*, char *)); +static int neol_query_firmware (int, int, char *, size_t); +static int neol_check_firmware (int, const char*, char *); #endif struct refclock refclock_neoclock4x = { @@ -301,9 +294,9 @@ neoclock4x_start(int unit, memset((char *)up, 0, sizeof(struct neoclock4x_unit)); pp = peer->procptr; pp->clockdesc = "NeoClock4X"; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->io.clock_recv = neoclock4x_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; /* @@ -319,15 +312,14 @@ neoclock4x_start(int unit, * Initialize miscellaneous variables */ peer->precision = -10; - peer->burst = NSTAGE; memcpy((char *)&pp->refid, "neol", 4); up->leap_status = 0; up->unit = unit; - strcpy(up->firmware, "?"); + strlcpy(up->firmware, "?", sizeof(up->firmware)); up->firmwaretag = '?'; - strcpy(up->serial, "?"); - strcpy(up->radiosignal, "?"); + strlcpy(up->serial, "?", sizeof(up->serial)); + strlcpy(up->radiosignal, "?", sizeof(up->radiosignal)); up->timesource = '?'; up->dststatus = '?'; up->quarzstatus = '?'; @@ -343,7 +335,8 @@ neoclock4x_start(int unit, #if defined(NEOCLOCK4X_FIRMWARE) #if NEOCLOCK4X_FIRMWARE == NEOCLOCK4X_FIRMWARE_VERSION_A - strcpy(up->firmware, "(c) 2002 NEOL S.A. FRANCE / L0.01 NDF:A:* (compile time)"); + strlcpy(up->firmware, "(c) 2002 NEOL S.A. FRANCE / L0.01 NDF:A:* (compile time)", + sizeof(up->firmware)); up->firmwaretag = 'A'; #else msyslog(LOG_EMERG, "NeoClock4X(%d): unknown firmware defined at compile time for NeoClock4X", @@ -407,7 +400,7 @@ neoclock4x_shutdown(int unit, pp = peer->procptr; if(pp != NULL) { - up = (struct neoclock4x_unit *)pp->unitptr; + up = pp->unitptr; if(up != NULL) { if(-1 != pp->io.fd) @@ -461,9 +454,9 @@ neoclock4x_receive(struct recvbuf *rbufp) unsigned char calc_chksum; int recv_chksum; - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct neoclock4x_unit *)pp->unitptr; + up = pp->unitptr; /* wait till poll interval is reached */ if(0 == up->recvnow) @@ -670,7 +663,7 @@ neoclock4x_poll(int unit, struct refclockproc *pp; pp = peer->procptr; - up = (struct neoclock4x_unit *)pp->unitptr; + up = pp->unitptr; pp->polls++; up->recvnow = 1; @@ -678,7 +671,7 @@ neoclock4x_poll(int unit, static void neoclock4x_control(int unit, - struct refclockstat *in, + const struct refclockstat *in, struct refclockstat *out, struct peer *peer) { @@ -698,7 +691,7 @@ neoclock4x_control(int unit, return; } - up = (struct neoclock4x_unit *)pp->unitptr; + up = pp->unitptr; if(NULL == up) { msyslog(LOG_ERR, "NeoClock4X(%d): control: unit invalid/inactive", unit); @@ -792,9 +785,9 @@ neol_hexatoi_len(const char str[], int i; int n = 0; - for(i=0; isxdigit((int)str[i]) && i < maxlen; i++) + for(i=0; isxdigit((unsigned char)str[i]) && i < maxlen; i++) { - hexdigit = isdigit((int)str[i]) ? toupper(str[i]) - '0' : toupper(str[i]) - 'A' + 10; + hexdigit = isdigit((unsigned char)str[i]) ? toupper((unsigned char)str[i]) - '0' : toupper((unsigned char)str[i]) - 'A' + 10; n = 16 * n + hexdigit; } *result = n; @@ -810,7 +803,7 @@ neol_atoi_len(const char str[], int i; int n = 0; - for(i=0; isdigit((int)str[i]) && i < maxlen; i++) + for(i=0; isdigit((unsigned char)str[i]) && i < maxlen; i++) { digit = str[i] - '0'; n = 10 * n + digit; @@ -905,10 +898,10 @@ static int neol_query_firmware(int fd, int unit, char *firmware, - int maxlen) + size_t maxlen) { char tmpbuf[256]; - int len; + size_t len; int lastsearch; unsigned char c; int last_c_was_crlf; @@ -938,20 +931,20 @@ neol_query_firmware(int fd, if(read_errors > 5) { msyslog(LOG_ERR, "NeoClock4X(%d): can't read firmware version (timeout)", unit); - strcpy(tmpbuf, "unknown due to timeout"); + strlcpy(tmpbuf, "unknown due to timeout", sizeof(tmpbuf)); break; } if(chars_read > 500) { msyslog(LOG_ERR, "NeoClock4X(%d): can't read firmware version (garbage)", unit); - strcpy(tmpbuf, "unknown due to garbage input"); + strlcpy(tmpbuf, "unknown due to garbage input", sizeof(tmpbuf)); break; } if(-1 == read(fd, &c, 1)) { if(EAGAIN != errno) { - msyslog(LOG_DEBUG, "NeoClock4x(%d): read: %s", unit ,strerror(errno)); + msyslog(LOG_DEBUG, "NeoClock4x(%d): read: %m", unit); read_errors++; } else @@ -970,7 +963,7 @@ neol_query_firmware(int fd, if(0xA9 != c) /* wait for (c) char in input stream */ continue; - strcpy(tmpbuf, "(c)"); + strlcpy(tmpbuf, "(c)", sizeof(tmpbuf)); len = 3; init = 0; continue; @@ -1008,22 +1001,28 @@ neol_query_firmware(int fd, tmpbuf[len++] = (char) c; } tmpbuf[len] = '\0'; - if(len > sizeof(tmpbuf)-5) + if (len > sizeof(tmpbuf)-5) break; } } else { msyslog(LOG_ERR, "NeoClock4X(%d): can't query firmware version", unit); - strcpy(tmpbuf, "unknown error"); + strlcpy(tmpbuf, "unknown error", sizeof(tmpbuf)); } - strncpy(firmware, tmpbuf, maxlen); - firmware[maxlen] = '\0'; + if (strlcpy(firmware, tmpbuf, maxlen) >= maxlen) + strlcpy(firmware, "buffer too small", maxlen); if(flag) { NLOG(NLOG_CLOCKINFO) msyslog(LOG_INFO, "NeoClock4X(%d): firmware version: %s", unit, firmware); + + if(strstr(firmware, "/R2")) + { + msyslog(LOG_INFO, "NeoClock4X(%d): Your NeoClock4X uses the new R2 firmware release. Please note the changed LED behaviour.", unit); + } + } return (flag); @@ -1110,4 +1109,16 @@ int refclock_neoclock4x_bs; * - remove some unsued #ifdefs * - fix nsec calculation, closes #499 * + * 2009/12/04 cjh + * Revision 1.16 + * - change license to ntp COPYRIGHT notice. This should allow Debian + * to add this refclock driver in further releases. + * - detect R2 hardware + * */ + + + + + + diff --git a/contrib/ntp/ntpd/refclock_nmea.c b/contrib/ntp/ntpd/refclock_nmea.c index a176ee86c..b1ea2946b 100644 --- a/contrib/ntp/ntpd/refclock_nmea.c +++ b/contrib/ntp/ntpd/refclock_nmea.c @@ -2,39 +2,58 @@ * refclock_nmea.c - clock driver for an NMEA GPS CLOCK * Michael Petry Jun 20, 1994 * based on refclock_heathn.c + * + * Updated to add support for Accord GPS Clock + * Venu Gopal Dec 05, 2007 + * neo.venu@gmail.com, venugopal_d@pgad.gov.in + * + * Updated to process 'time1' fudge factor + * Venu Gopal May 05, 2008 + * + * Converted to common PPSAPI code, separate PPS fudge time1 + * from serial timecode fudge time2. + * Dave Hart July 1, 2009 + * hart@ntp.org, davehart@davehart.com */ + #ifdef HAVE_CONFIG_H #include #endif +#include "ntp_types.h" + #if defined(REFCLOCK) && defined(CLOCK_NMEA) +#define NMEA_WRITE_SUPPORT 0 /* no write support at the moment */ + +#include #include #include +#ifdef HAVE_SYS_SOCKET_H +#include +#endif #include "ntpd.h" #include "ntp_io.h" #include "ntp_unixtime.h" #include "ntp_refclock.h" #include "ntp_stdlib.h" +#include "ntp_calendar.h" +#include "timespecops.h" #ifdef HAVE_PPSAPI # include "ppsapi_timepps.h" +# include "refclock_atom.h" #endif /* HAVE_PPSAPI */ -#ifdef SYS_WINNT -extern int async_write(int, const void *, unsigned int); -#undef write -#define write(fd, data, octets) async_write(fd, data, octets) -#endif /* - * This driver supports the NMEA GPS Receiver with + * This driver supports NMEA-compatible GPS receivers * - * Protype was refclock_trak.c, Thanks a lot. + * Prototype was refclock_trak.c, Thanks a lot. * * The receiver used spits out the NMEA sentences for boat navigation. - * And you thought it was an information superhighway. Try a raging river + * And you thought it was an information superhighway. Try a raging river * filled with rapids and whirlpools that rip away your data and warp time. * * If HAVE_PPSAPI is defined code to use the PPSAPI will be compiled in. @@ -52,712 +71,1890 @@ extern int async_write(int, const void *, unsigned int); * bit 0 - enables RMC (1) * bit 1 - enables GGA (2) * bit 2 - enables GLL (4) - * multiple sentences may be selected + * bit 3 - enables ZDA (8) - Standard Time & Date + * bit 3 - enables ZDG (8) - Accord GPS Clock's custom sentence with GPS time + * very close to standard ZDA + * + * Multiple sentences may be selected except when ZDG/ZDA is selected. + * + * bit 4/5/6 - selects the baudrate for serial port : + * 0 for 4800 (default) + * 1 for 9600 + * 2 for 19200 + * 3 for 38400 + * 4 for 57600 + * 5 for 115200 + */ +#define NMEA_MESSAGE_MASK 0x0000FF0FU +#define NMEA_BAUDRATE_MASK 0x00000070U +#define NMEA_BAUDRATE_SHIFT 4 + +#define NMEA_DELAYMEAS_MASK 0x80 +#define NMEA_EXTLOG_MASK 0x00010000U +#define NMEA_DATETRUST_MASK 0x02000000U + +#define NMEA_PROTO_IDLEN 5 /* tag name must be at least 5 chars */ +#define NMEA_PROTO_MINLEN 6 /* min chars in sentence, excluding CS */ +#define NMEA_PROTO_MAXLEN 80 /* max chars in sentence, excluding CS */ +#define NMEA_PROTO_FIELDS 32 /* not official; limit on fields per record */ + +/* + * We check the timecode format and decode its contents. We only care + * about a few of them, the most important being the $GPRMC format: + * + * $GPRMC,hhmmss,a,fddmm.xx,n,dddmmm.xx,w,zz.z,yyy.,ddmmyy,dd,v*CC + * + * mode (0,1,2,3) selects sentence ANY/ALL, RMC, GGA, GLL, ZDA + * $GPGLL,3513.8385,S,14900.7851,E,232420.594,A*21 + * $GPGGA,232420.59,3513.8385,S,14900.7851,E,1,05,3.4,00519,M,,,,*3F + * $GPRMC,232418.19,A,3513.8386,S,14900.7853,E,00.0,000.0,121199,12.,E*77 + * + * Defining GPZDA to support Standard Time & Date + * sentence. The sentence has the following format + * + * $--ZDA,HHMMSS.SS,DD,MM,YYYY,TH,TM,*CS + * + * Apart from the familiar fields, + * 'TH' Time zone Hours + * 'TM' Time zone Minutes + * + * Defining GPZDG to support Accord GPS Clock's custom NMEA + * sentence. The sentence has the following format + * + * $GPZDG,HHMMSS.S,DD,MM,YYYY,AA.BB,V*CS + * + * It contains the GPS timestamp valid for next PPS pulse. + * Apart from the familiar fields, + * 'AA.BB' denotes the signal strength( should be < 05.00 ) + * 'V' denotes the GPS sync status : + * '0' indicates INVALID time, + * '1' indicates accuracy of +/-20 ms + * '2' indicates accuracy of +/-100 ns + * + * Defining PGRMF for Garmin GPS Fix Data + * $PGRMF,WN,WS,DATE,TIME,LS,LAT,LAT_DIR,LON,LON_DIR,MODE,FIX,SPD,DIR,PDOP,TDOP + * WN -- GPS week number (weeks since 1980-01-06, mod 1024) + * WS -- GPS seconds in week + * LS -- GPS leap seconds, accumulated ( UTC + LS == GPS ) + * FIX -- Fix type: 0=nofix, 1=2D, 2=3D + * DATE/TIME are standard date/time strings in UTC time scale + * + * The GPS time can be used to get the full century for the truncated + * date spec. */ /* * Definitions */ -#ifdef SYS_WINNT -# define DEVICE "COM%d:" /* COM 1 - 3 supported */ -#else -# define DEVICE "/dev/gps%d" /* name of radio device */ -#endif +#define DEVICE "/dev/gps%d" /* GPS serial device */ +#define PPSDEV "/dev/gpspps%d" /* PPSAPI device override */ #define SPEED232 B4800 /* uart speed (4800 bps) */ #define PRECISION (-9) /* precision assumed (about 2 ms) */ #define PPS_PRECISION (-20) /* precision assumed (about 1 us) */ #define REFID "GPS\0" /* reference id */ #define DESCRIPTION "NMEA GPS Clock" /* who we are */ -#define NANOSECOND 1000000000 /* one second (ns) */ -#define RANGEGATE 500000 /* range gate (ns) */ +#ifndef O_NOCTTY +#define M_NOCTTY 0 +#else +#define M_NOCTTY O_NOCTTY +#endif +#ifndef O_NONBLOCK +#define M_NONBLOCK 0 +#else +#define M_NONBLOCK O_NONBLOCK +#endif +#define PPSOPENMODE (O_RDWR | M_NOCTTY | M_NONBLOCK) -#define LENNMEA 75 /* min timecode length */ +/* NMEA sentence array indexes for those we use */ +#define NMEA_GPRMC 0 /* recommended min. nav. */ +#define NMEA_GPGGA 1 /* fix and quality */ +#define NMEA_GPGLL 2 /* geo. lat/long */ +#define NMEA_GPZDA 3 /* date/time */ +/* + * $GPZDG is a proprietary sentence that violates the spec, by not + * using $P and an assigned company identifier to prefix the sentence + * identifier. When used with this driver, the system needs to be + * isolated from other NTP networks, as it operates in GPS time, not + * UTC as is much more common. GPS time is >15 seconds different from + * UTC due to not respecting leap seconds since 1970 or so. Other + * than the different timebase, $GPZDG is similar to $GPZDA. + */ +#define NMEA_GPZDG 4 +#define NMEA_PGRMF 5 +#define NMEA_ARRAY_SIZE (NMEA_PGRMF + 1) /* - * Tables to compute the ddd of year form icky dd/mm timecode. Viva la - * leap. + * Sentence selection mode bits + */ +#define USE_GPRMC 0x00000001u +#define USE_GPGGA 0x00000002u +#define USE_GPGLL 0x00000004u +#define USE_GPZDA 0x00000008u +#define USE_PGRMF 0x00000100u + +/* mapping from sentence index to controlling mode bit */ +static const u_int32 sentence_mode[NMEA_ARRAY_SIZE] = +{ + USE_GPRMC, + USE_GPGGA, + USE_GPGLL, + USE_GPZDA, + USE_GPZDA, + USE_PGRMF +}; + +/* date formats we support */ +enum date_fmt { + DATE_1_DDMMYY, /* use 1 field with 2-digit year */ + DATE_3_DDMMYYYY /* use 3 fields with 4-digit year */ +}; + +/* results for 'field_init()' + * + * Note: If a checksum is present, the checksum test must pass OK or the + * sentence is tagged invalid. */ -static int day1tab[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; -static int day2tab[] = {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; +#define CHECK_EMPTY -1 /* no data */ +#define CHECK_INVALID 0 /* not a valid NMEA sentence */ +#define CHECK_VALID 1 /* valid but without checksum */ +#define CHECK_CSVALID 2 /* valid with checksum OK */ /* * Unit control structure */ -struct nmeaunit { - int pollcnt; /* poll message counter */ - int polled; /* Hand in a sample? */ - l_fp tstamp; /* timestamp of last poll */ +typedef struct { #ifdef HAVE_PPSAPI - struct timespec ts; /* last timestamp */ - pps_params_t pps_params; /* pps parameters */ - pps_info_t pps_info; /* last pps data */ - pps_handle_t handle; /* pps handlebars */ + struct refclock_atom atom; /* PPSAPI structure */ + int ppsapi_fd; /* fd used with PPSAPI */ + u_char ppsapi_tried; /* attempt PPSAPI once */ + u_char ppsapi_lit; /* time_pps_create() worked */ + u_char ppsapi_gate; /* system is on PPS */ #endif /* HAVE_PPSAPI */ -}; + u_char gps_time; /* use GPS time, not UTC */ + u_short century_cache; /* cached current century */ + l_fp last_reftime; /* last processed reference stamp */ + short epoch_warp; /* last epoch warp, for logging */ + /* tally stats, reset each poll cycle */ + struct + { + u_int total; + u_int accepted; + u_int rejected; /* GPS said not enough signal */ + u_int malformed; /* Bad checksum, invalid date or time */ + u_int filtered; /* mode bits, not GPZDG, same second */ + u_int pps_used; + } + tally; + /* per sentence checksum seen flag */ + u_char cksum_type[NMEA_ARRAY_SIZE]; +} nmea_unit; + +/* + * helper for faster field access + */ +typedef struct { + char *base; /* buffer base */ + char *cptr; /* current field ptr */ + int blen; /* buffer length */ + int cidx; /* current field index */ +} nmea_data; + +/* + * NMEA gps week/time information + * This record contains the number of weeks since 1980-01-06 modulo + * 1024, the seconds elapsed since start of the week, and the number of + * leap seconds that are the difference between GPS and UTC time scale. + */ +typedef struct { + u_int32 wt_time; /* seconds since weekstart */ + u_short wt_week; /* week number */ + short wt_leap; /* leap seconds */ +} gps_weektm; + +/* + * The GPS week time scale starts on Sunday, 1980-01-06. We need the + * rata die number of this day. + */ +#ifndef DAY_GPS_STARTS +#define DAY_GPS_STARTS 722820 +#endif /* * Function prototypes */ -static int nmea_start P((int, struct peer *)); -static void nmea_shutdown P((int, struct peer *)); +static void nmea_init (void); +static int nmea_start (int, struct peer *); +static void nmea_shutdown (int, struct peer *); +static void nmea_receive (struct recvbuf *); +static void nmea_poll (int, struct peer *); #ifdef HAVE_PPSAPI -static void nmea_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); -static int nmea_ppsapi P((struct peer *, int, int)); -static int nmea_pps P((struct nmeaunit *, l_fp *)); +static void nmea_control (int, const struct refclockstat *, + struct refclockstat *, struct peer *); +#define NMEA_CONTROL nmea_control +#else +#define NMEA_CONTROL noentry #endif /* HAVE_PPSAPI */ -static void nmea_receive P((struct recvbuf *)); -static void nmea_poll P((int, struct peer *)); -static void gps_send P((int, const char *, struct peer *)); -static char *field_parse P((char *, int)); +static void nmea_timer (int, struct peer *); + +/* parsing helpers */ +static int field_init (nmea_data * data, char * cp, int len); +static char * field_parse (nmea_data * data, int fn); +static void field_wipe (nmea_data * data, ...); +static u_char parse_qual (nmea_data * data, int idx, + char tag, int inv); +static int parse_time (struct calendar * jd, long * nsec, + nmea_data *, int idx); +static int parse_date (struct calendar *jd, nmea_data*, + int idx, enum date_fmt fmt); +static int parse_weekdata (gps_weektm *, nmea_data *, + int weekidx, int timeidx, int leapidx); +/* calendar / date helpers */ +static int unfold_day (struct calendar * jd, u_int32 rec_ui); +static int unfold_century (struct calendar * jd, u_int32 rec_ui); +static int gpsfix_century (struct calendar * jd, const gps_weektm * wd, + u_short * ccentury); +static l_fp eval_gps_time (struct peer * peer, const struct calendar * gpst, + const struct timespec * gpso, const l_fp * xrecv); + +static int nmead_open (const char * device); +static void save_ltc (struct refclockproc * const, const char * const, + size_t); /* + * If we want the driver to ouput sentences, too: re-enable the send + * support functions by defining NMEA_WRITE_SUPPORT to non-zero... + */ +#if NMEA_WRITE_SUPPORT + +static void gps_send(int, const char *, struct peer *); +# ifdef SYS_WINNT +# undef write /* ports/winnt/include/config.h: #define write _write */ +extern int async_write(int, const void *, unsigned int); +# define write(fd, data, octets) async_write(fd, data, octets) +# endif /* SYS_WINNT */ + +#endif /* NMEA_WRITE_SUPPORT */ + +static int32_t g_gpsMinBase; +static int32_t g_gpsMinYear; + +/* + * ------------------------------------------------------------------- * Transfer vector + * ------------------------------------------------------------------- */ -struct refclock refclock_nmea = { +struct refclock refclock_nmea = { nmea_start, /* start up driver */ - nmea_shutdown, /* shut down driver */ + nmea_shutdown, /* shut down driver */ nmea_poll, /* transmit poll message */ -#ifdef HAVE_PPSAPI - nmea_control, /* fudge control */ -#else - noentry, /* fudge control */ -#endif /* HAVE_PPSAPI */ - noentry, /* initialize driver */ + NMEA_CONTROL, /* fudge control */ + nmea_init, /* initialize driver */ noentry, /* buginfo */ - NOFLAGS /* not used */ + nmea_timer /* called once per second */ }; /* + * ------------------------------------------------------------------- + * nmea_init - initialise data + * + * calculates a few runtime constants that cannot be made compile time + * constants. + * ------------------------------------------------------------------- + */ +static void +nmea_init(void) +{ + struct calendar date; + + /* - calculate min. base value for GPS epoch & century unfolding + * This assumes that the build system was roughly in sync with + * the world, and that really synchronising to a time before the + * program was created would be unsafe or insane. If the build + * date cannot be stablished, at least use the start of GPS + * (1980-01-06) as minimum, because GPS can surely NOT + * synchronise beyond it's own big bang. We add a little safety + * margin for the fuzziness of the build date, which is in an + * undefined time zone. */ + if (ntpcal_get_build_date(&date)) + g_gpsMinBase = ntpcal_date_to_rd(&date) - 2; + else + g_gpsMinBase = 0; + + if (g_gpsMinBase < DAY_GPS_STARTS) + g_gpsMinBase = DAY_GPS_STARTS; + + ntpcal_rd_to_date(&date, g_gpsMinBase); + g_gpsMinYear = date.year; + g_gpsMinBase -= DAY_NTP_STARTS; +} + +/* + * ------------------------------------------------------------------- * nmea_start - open the GPS devices and initialize data for processing + * + * return 0 on error, 1 on success. Even on error the peer structures + * must be in a state that permits 'nmea_shutdown()' to clean up all + * resources, because it will be called immediately to do so. + * ------------------------------------------------------------------- */ static int nmea_start( - int unit, - struct peer *peer + int unit, + struct peer * peer ) { - register struct nmeaunit *up; - struct refclockproc *pp; - int fd; - char device[20]; - - /* - * Open serial port. Use CLK line discipline, if available. - */ - (void)sprintf(device, DEVICE, unit); - - fd = refclock_open(device, SPEED232, LDISC_CLK); - if (fd <= 0) { -#ifdef HAVE_READLINK - /* nmead support added by Jon Miner (cp_n18@yahoo.com) - * - * See http://home.hiwaay.net/~taylorc/gps/nmea-server/ - * for information about nmead - * - * To use this, you need to create a link from /dev/gpsX to - * the server:port where nmead is running. Something like this: - * - * ln -s server:port /dev/gps1 - */ - char buffer[80]; - char *nmea_host; - int nmea_port; - int len; - struct hostent *he; - struct protoent *p; - struct sockaddr_in so_addr; - - if ((len = readlink(device,buffer,sizeof(buffer))) == -1) - return(0); - buffer[len] = 0; - - if ((nmea_host = strtok(buffer,":")) == NULL) - return(0); - - nmea_port = atoi(strtok(NULL,":")); - - if ((he = gethostbyname(nmea_host)) == NULL) - return(0); - if ((p = getprotobyname("ip")) == NULL) - return(0); - so_addr.sin_family = AF_INET; - so_addr.sin_port = htons(nmea_port); - so_addr.sin_addr = *((struct in_addr *) he->h_addr); - - if ((fd = socket(PF_INET,SOCK_STREAM,p->p_proto)) == -1) - return(0); - if (connect(fd,(struct sockaddr *)&so_addr,SOCKLEN(&so_addr)) == -1) { - close(fd); - return (0); - } -#else - return (0); + struct refclockproc * const pp = peer->procptr; + nmea_unit * const up = emalloc_zero(sizeof(*up)); + char device[20]; + size_t devlen; + u_int32 rate; + int baudrate; + const char * baudtext; + + + /* Get baudrate choice from mode byte bits 4/5/6 */ + rate = (peer->ttl & NMEA_BAUDRATE_MASK) >> NMEA_BAUDRATE_SHIFT; + + switch (rate) { + case 0: + baudrate = SPEED232; + baudtext = "4800"; + break; + case 1: + baudrate = B9600; + baudtext = "9600"; + break; + case 2: + baudrate = B19200; + baudtext = "19200"; + break; + case 3: + baudrate = B38400; + baudtext = "38400"; + break; +#ifdef B57600 + case 4: + baudrate = B57600; + baudtext = "57600"; + break; #endif - } - - /* - * Allocate and initialize unit structure - */ - up = (struct nmeaunit *)emalloc(sizeof(struct nmeaunit)); - if (up == NULL) { - (void) close(fd); - return (0); +#ifdef B115200 + case 5: + baudrate = B115200; + baudtext = "115200"; + break; +#endif + default: + baudrate = SPEED232; + baudtext = "4800 (fallback)"; + break; } - memset((char *)up, 0, sizeof(struct nmeaunit)); - pp = peer->procptr; + + /* Allocate and initialize unit structure */ + pp->unitptr = (caddr_t)up; + pp->io.fd = -1; pp->io.clock_recv = nmea_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; - pp->io.fd = fd; - if (!io_addclock(&pp->io)) { - (void) close(fd); - free(up); - return (0); - } - pp->unitptr = (caddr_t)up; + /* force change detection on first valid message */ + memset(&up->last_reftime, 0xFF, sizeof(up->last_reftime)); + /* force checksum on GPRMC, see below */ + up->cksum_type[NMEA_GPRMC] = CHECK_CSVALID; +#ifdef HAVE_PPSAPI + up->ppsapi_fd = -1; +#endif + ZERO(up->tally); - /* - * Initialize miscellaneous variables - */ + /* Initialize miscellaneous variables */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); - up->pollcnt = 2; - gps_send(pp->io.fd,"$PMOTG,RMC,0000*1D\r\n", peer); - -#ifdef HAVE_PPSAPI - /* - * Start the PPSAPI interface if it is there. Default to use - * the assert edge and do not enable the kernel hardpps. - */ - if (time_pps_create(fd, &up->handle) < 0) { - up->handle = 0; - msyslog(LOG_ERR, - "refclock_nmea: time_pps_create failed: %m"); - return (1); + memcpy(&pp->refid, REFID, 4); + + /* Open serial port. Use CLK line discipline, if available. */ + devlen = snprintf(device, sizeof(device), DEVICE, unit); + if (devlen >= sizeof(device)) { + msyslog(LOG_ERR, "%s clock device name too long", + refnumtoa(&peer->srcadr)); + return FALSE; /* buffer overflow */ } - return(nmea_ppsapi(peer, 0, 0)); -#else - return (1); -#endif /* HAVE_PPSAPI */ + pp->io.fd = refclock_open(device, baudrate, LDISC_CLK); + if (0 >= pp->io.fd) { + pp->io.fd = nmead_open(device); + if (-1 == pp->io.fd) + return FALSE; + } + LOGIF(CLOCKINFO, (LOG_NOTICE, "%s serial %s open at %s bps", + refnumtoa(&peer->srcadr), device, baudtext)); + + /* succeed if this clock can be added */ + return io_addclock(&pp->io) != 0; } + /* + * ------------------------------------------------------------------- * nmea_shutdown - shut down a GPS clock + * + * NOTE this routine is called after nmea_start() returns failure, + * as well as during a normal shutdown due to ntpq :config unpeer. + * ------------------------------------------------------------------- */ static void nmea_shutdown( - int unit, - struct peer *peer + int unit, + struct peer * peer ) { - register struct nmeaunit *up; - struct refclockproc *pp; + struct refclockproc * const pp = peer->procptr; + nmea_unit * const up = (nmea_unit *)pp->unitptr; + + UNUSED_ARG(unit); - pp = peer->procptr; - up = (struct nmeaunit *)pp->unitptr; + if (up != NULL) { #ifdef HAVE_PPSAPI - if (up->handle != 0) - time_pps_destroy(up->handle); -#endif /* HAVE_PPSAPI */ - io_closeclock(&pp->io); - free(up); + if (up->ppsapi_lit) + time_pps_destroy(up->atom.handle); + if (up->ppsapi_tried && up->ppsapi_fd != pp->io.fd) + close(up->ppsapi_fd); +#endif + free(up); + } + pp->unitptr = (caddr_t)NULL; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + pp->io.fd = -1; } -#ifdef HAVE_PPSAPI /* - * nmea_control - fudge control + * ------------------------------------------------------------------- + * nmea_control - configure fudge params + * ------------------------------------------------------------------- */ +#ifdef HAVE_PPSAPI static void nmea_control( - int unit, /* unit (not used */ - struct refclockstat *in, /* input parameters (not uded) */ - struct refclockstat *out, /* output parameters (not used) */ - struct peer *peer /* peer structure pointer */ + int unit, + const struct refclockstat * in_st, + struct refclockstat * out_st, + struct peer * peer ) { - struct refclockproc *pp; + struct refclockproc * const pp = peer->procptr; + nmea_unit * const up = (nmea_unit *)pp->unitptr; - pp = peer->procptr; - nmea_ppsapi(peer, pp->sloppyclockflag & CLK_FLAG2, - pp->sloppyclockflag & CLK_FLAG3); -} + char device[32]; + size_t devlen; + + UNUSED_ARG(in_st); + UNUSED_ARG(out_st); + /* + * PPS control + * + * If /dev/gpspps$UNIT can be opened that will be used for + * PPSAPI. Otherwise, the GPS serial device /dev/gps$UNIT + * already opened is used for PPSAPI as well. (This might not + * work, in which case the PPS API remains unavailable...) + */ + + /* Light up the PPSAPI interface if not yet attempted. */ + if ((CLK_FLAG1 & pp->sloppyclockflag) && !up->ppsapi_tried) { + up->ppsapi_tried = TRUE; + devlen = snprintf(device, sizeof(device), PPSDEV, unit); + if (devlen < sizeof(device)) { + up->ppsapi_fd = open(device, PPSOPENMODE, + S_IRUSR | S_IWUSR); + } else { + up->ppsapi_fd = -1; + msyslog(LOG_ERR, "%s PPS device name too long", + refnumtoa(&peer->srcadr)); + } + if (-1 == up->ppsapi_fd) + up->ppsapi_fd = pp->io.fd; + if (refclock_ppsapi(up->ppsapi_fd, &up->atom)) { + /* use the PPS API for our own purposes now. */ + up->ppsapi_lit = refclock_params( + pp->sloppyclockflag, &up->atom); + if (!up->ppsapi_lit) { + /* failed to configure, drop PPS unit */ + time_pps_destroy(up->atom.handle); + msyslog(LOG_WARNING, + "%s set PPSAPI params fails", + refnumtoa(&peer->srcadr)); + } + /* note: the PPS I/O handle remains valid until + * flag1 is cleared or the clock is shut down. + */ + } else { + msyslog(LOG_WARNING, + "%s flag1 1 but PPSAPI fails", + refnumtoa(&peer->srcadr)); + } + } + + /* shut down PPS API if activated */ + if (!(CLK_FLAG1 & pp->sloppyclockflag) && up->ppsapi_tried) { + /* shutdown PPS API */ + if (up->ppsapi_lit) + time_pps_destroy(up->atom.handle); + up->atom.handle = 0; + /* close/drop PPS fd */ + if (up->ppsapi_fd != pp->io.fd) + close(up->ppsapi_fd); + up->ppsapi_fd = -1; + + /* clear markers and peer items */ + up->ppsapi_gate = FALSE; + up->ppsapi_lit = FALSE; + up->ppsapi_tried = FALSE; + + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + } +} +#endif /* HAVE_PPSAPI */ /* - * Initialize PPSAPI + * ------------------------------------------------------------------- + * nmea_timer - called once per second + * this only polls (older?) Oncore devices now + * + * Usually 'nmea_receive()' can get a timestamp every second, but at + * least one Motorola unit needs prompting each time. Doing so in + * 'nmea_poll()' gives only one sample per poll cycle, which actually + * defeats the purpose of the median filter. Polling once per second + * seems a much better idea. + * ------------------------------------------------------------------- */ -int -nmea_ppsapi( - struct peer *peer, /* peer structure pointer */ - int enb_clear, /* clear enable */ - int enb_hardpps /* hardpps enable */ +static void +nmea_timer( + int unit, + struct peer * peer ) { - struct refclockproc *pp; - struct nmeaunit *up; - int capability; - - pp = peer->procptr; - up = (struct nmeaunit *)pp->unitptr; - if (time_pps_getcap(up->handle, &capability) < 0) { - msyslog(LOG_ERR, - "refclock_nmea: time_pps_getcap failed: %m"); - return (0); - } - memset(&up->pps_params, 0, sizeof(pps_params_t)); - if (enb_clear) - up->pps_params.mode = capability & PPS_CAPTURECLEAR; - else - up->pps_params.mode = capability & PPS_CAPTUREASSERT; - if (!up->pps_params.mode) { - msyslog(LOG_ERR, - "refclock_nmea: invalid capture edge %d", - !enb_clear); - return (0); - } - up->pps_params.mode |= PPS_TSFMT_TSPEC; - if (time_pps_setparams(up->handle, &up->pps_params) < 0) { - msyslog(LOG_ERR, - "refclock_nmea: time_pps_setparams failed: %m"); - return (0); - } - if (enb_hardpps) { - if (time_pps_kcbind(up->handle, PPS_KC_HARDPPS, - up->pps_params.mode & ~PPS_TSFMT_TSPEC, - PPS_TSFMT_TSPEC) < 0) { - msyslog(LOG_ERR, - "refclock_nmea: time_pps_kcbind failed: %m"); - return (0); - } - pps_enable = 1; - } - peer->precision = PPS_PRECISION; +#if NMEA_WRITE_SUPPORT + + struct refclockproc * const pp = peer->procptr; -#if DEBUG - if (debug) { - time_pps_getparams(up->handle, &up->pps_params); - printf( - "refclock_ppsapi: capability 0x%x version %d mode 0x%x kern %d\n", - capability, up->pps_params.api_version, - up->pps_params.mode, enb_hardpps); - } -#endif + UNUSED_ARG(unit); - return (1); + if (-1 != pp->io.fd) /* any mode bits to evaluate here? */ + gps_send(pp->io.fd, "$PMOTG,RMC,0000*1D\r\n", peer); +#else + + UNUSED_ARG(unit); + UNUSED_ARG(peer); + +#endif /* NMEA_WRITE_SUPPORT */ } +#ifdef HAVE_PPSAPI /* - * Get PPSAPI timestamps. + * ------------------------------------------------------------------- + * refclock_ppsrelate(...) -- correlate with PPS edge + * + * This function is used to correlate a receive time stamp and a + * reference time with a PPS edge time stamp. It applies the necessary + * fudges (fudge1 for PPS, fudge2 for receive time) and then tries to + * move the receive time stamp to the corresponding edge. This can warp + * into future, if a transmission delay of more than 500ms is not + * compensated with a corresponding fudge time2 value, because then the + * next PPS edge is nearer than the last. (Similiar to what the PPS ATOM + * driver does, but we deal with full time stamps here, not just phase + * shift information.) Likewise, a negative fudge time2 value must be + * used if the reference time stamp correlates with the *following* PPS + * pulse. * - * Return 0 on failure and 1 on success. + * Note that the receive time fudge value only needs to move the receive + * stamp near a PPS edge but that close proximity is not required; + * +/-100ms precision should be enough. But since the fudge value will + * probably also be used to compensate the transmission delay when no + * PPS edge can be related to the time stamp, it's best to get it as + * close as possible. + * + * It should also be noted that the typical use case is matching to the + * preceeding edge, as most units relate their sentences to the current + * second. + * + * The function returns PPS_RELATE_NONE (0) if no PPS edge correlation + * can be fixed; PPS_RELATE_EDGE (1) when a PPS edge could be fixed, but + * the distance to the reference time stamp is too big (exceeds + * +/-400ms) and the ATOM driver PLL cannot be used to fix the phase; + * and PPS_RELATE_PHASE (2) when the ATOM driver PLL code can be used. + * + * On output, the receive time stamp is replaced with the corresponding + * PPS edge time if a fix could be made; the PPS fudge is updated to + * reflect the proper fudge time to apply. (This implies that + * 'refclock_process_offset()' must be used!) + * ------------------------------------------------------------------- */ +#define PPS_RELATE_NONE 0 /* no pps correlation possible */ +#define PPS_RELATE_EDGE 1 /* recv time fixed, no phase lock */ +#define PPS_RELATE_PHASE 2 /* recv time fixed, phase lock ok */ + static int -nmea_pps( - struct nmeaunit *up, - l_fp *tsptr +refclock_ppsrelate( + const struct refclockproc * pp , /* for sanity */ + const struct refclock_atom * ap , /* for PPS io */ + const l_fp * reftime , + l_fp * rd_stamp, /* i/o read stamp */ + double pp_fudge, /* pps fudge */ + double * rd_fudge /* i/o read fudge */ ) { - pps_info_t pps_info; - struct timespec timeout, ts; - double dtemp; - l_fp tstmp; - - /* - * Convert the timespec nanoseconds field to ntp l_fp units. - */ - if (up->handle == 0) - return (0); - timeout.tv_sec = 0; - timeout.tv_nsec = 0; - memcpy(&pps_info, &up->pps_info, sizeof(pps_info_t)); - if (time_pps_fetch(up->handle, PPS_TSFMT_TSPEC, &up->pps_info, - &timeout) < 0) - return (0); - if (up->pps_params.mode & PPS_CAPTUREASSERT) { - if (pps_info.assert_sequence == - up->pps_info.assert_sequence) - return (0); - ts = up->pps_info.assert_timestamp; - } else if (up->pps_params.mode & PPS_CAPTURECLEAR) { - if (pps_info.clear_sequence == - up->pps_info.clear_sequence) - return (0); - ts = up->pps_info.clear_timestamp; - } else { - return (0); - } - if ((up->ts.tv_sec == ts.tv_sec) && (up->ts.tv_nsec == ts.tv_nsec)) - return (0); - up->ts = ts; - - tstmp.l_ui = ts.tv_sec + JAN_1970; - dtemp = ts.tv_nsec * FRAC / 1e9; - tstmp.l_uf = (u_int32)dtemp; - *tsptr = tstmp; - return (1); + pps_info_t pps_info; + struct timespec timeout; + l_fp pp_stamp, pp_delta; + double delta, idelta; + + if (pp->leap == LEAP_NOTINSYNC) + return PPS_RELATE_NONE; /* clock is insane, no chance */ + + ZERO(timeout); + ZERO(pps_info); + if (time_pps_fetch(ap->handle, PPS_TSFMT_TSPEC, + &pps_info, &timeout) < 0) + return PPS_RELATE_NONE; /* can't get time stamps */ + + /* get last active PPS edge before receive */ + if (ap->pps_params.mode & PPS_CAPTUREASSERT) + timeout = pps_info.assert_timestamp; + else if (ap->pps_params.mode & PPS_CAPTURECLEAR) + timeout = pps_info.clear_timestamp; + else + return PPS_RELATE_NONE; /* WHICH edge, please?!? */ + + /* get delta between receive time and PPS time */ + pp_stamp = tspec_stamp_to_lfp(timeout); + pp_delta = *rd_stamp; + L_SUB(&pp_delta, &pp_stamp); + LFPTOD(&pp_delta, delta); + delta += pp_fudge - *rd_fudge; + if (fabs(delta) > 1.5) + return PPS_RELATE_NONE; /* PPS timeout control */ + + /* eventually warp edges, check phase */ + idelta = floor(delta + 0.5); + pp_fudge -= idelta; + delta -= idelta; + if (fabs(delta) > 0.45) + return PPS_RELATE_NONE; /* dead band control */ + + /* we actually have a PPS edge to relate with! */ + *rd_stamp = pp_stamp; + *rd_fudge = pp_fudge; + + /* if whole system out-of-sync, do not try to PLL */ + if (sys_leap == LEAP_NOTINSYNC) + return PPS_RELATE_EDGE; /* cannot PLL with atom code */ + + /* check against reftime if ATOM PLL can be used */ + pp_delta = *reftime; + L_SUB(&pp_delta, &pp_stamp); + LFPTOD(&pp_delta, delta); + delta += pp_fudge; + if (fabs(delta) > 0.45) + return PPS_RELATE_EDGE; /* cannot PLL with atom code */ + + /* all checks passed, gets an AAA rating here! */ + return PPS_RELATE_PHASE; /* can PLL with atom code */ } -#endif /* HAVE_PPSAPI */ +#endif /* HAVE_PPSAPI */ /* + * ------------------------------------------------------------------- * nmea_receive - receive data from the serial interface + * + * This is the workhorse for NMEA data evaluation: + * + * + it checks all NMEA data, and rejects sentences that are not valid + * NMEA sentences + * + it checks whether a sentence is known and to be used + * + it parses the time and date data from the NMEA data string and + * augments the missing bits. (century in dat, whole date, ...) + * + it rejects data that is not from the first accepted sentence in a + * burst + * + it eventually replaces the receive time with the PPS edge time. + * + it feeds the data to the internal processing stages. + * ------------------------------------------------------------------- */ static void nmea_receive( - struct recvbuf *rbufp + struct recvbuf * rbufp ) { - register struct nmeaunit *up; - struct refclockproc *pp; - struct peer *peer; - int month, day; - int i; - char *cp, *dp; - int cmdtype; - /* Use these variables to hold data until we decide its worth keeping */ - char rd_lastcode[BMAX]; - l_fp rd_tmp; - u_short rd_lencode; - - /* - * Initialize pointers and read the timecode and timestamp - */ - peer = (struct peer *)rbufp->recv_srcclock; - pp = peer->procptr; - up = (struct nmeaunit *)pp->unitptr; - rd_lencode = (u_short)refclock_gtlin(rbufp, rd_lastcode, BMAX, &rd_tmp); + /* declare & init control structure ptrs */ + struct peer * const peer = rbufp->recv_peer; + struct refclockproc * const pp = peer->procptr; + nmea_unit * const up = (nmea_unit*)pp->unitptr; - /* - * There is a case that a gives back a "blank" line + /* Use these variables to hold data until we decide its worth keeping */ + nmea_data rdata; + char rd_lastcode[BMAX]; + l_fp rd_timestamp, rd_reftime; + int rd_lencode; + double rd_fudge; + + /* working stuff */ + struct calendar date; /* to keep & convert the time stamp */ + struct timespec tofs; /* offset to full-second reftime */ + gps_weektm gpsw; /* week time storage */ + /* results of sentence/date/time parsing */ + u_char sentence; /* sentence tag */ + int checkres; + char * cp; + int rc_date; + int rc_time; + + /* make sure data has defined pristine state */ + ZERO(tofs); + ZERO(date); + ZERO(gpsw); + sentence = 0; // Should never be needed. + rc_date = 0; // Should never be needed. + rc_time = 0; // Should never be needed. + + /* + * Read the timecode and timestamp, then initialise field + * processing. The at the NMEA line end is translated + * to by the terminal input routines on most systems, + * and this gives us one spurious empty read per record which we + * better ignore silently. */ - if (rd_lencode == 0) - return; + rd_lencode = refclock_gtlin(rbufp, rd_lastcode, + sizeof(rd_lastcode), &rd_timestamp); + checkres = field_init(&rdata, rd_lastcode, rd_lencode); + switch (checkres) { + + case CHECK_INVALID: + DPRINTF(1, ("%s invalid data: '%s'\n", + refnumtoa(&peer->srcadr), rd_lastcode)); + refclock_report(peer, CEVNT_BADREPLY); + return; -#ifdef DEBUG - if (debug) - printf("nmea: gpsread %d %s\n", rd_lencode, - rd_lastcode); -#endif + case CHECK_EMPTY: + return; - /* - * We check the timecode format and decode its contents. The - * we only care about a few of them. The most important being - * the $GPRMC format - * $GPRMC,hhmmss,a,fddmm.xx,n,dddmmm.xx,w,zz.z,yyy.,ddmmyy,dd,v*CC - * For Magellan (ColorTrak) GLL probably datum (order of sentences) - * also mode (0,1,2,3) select sentence ANY/ALL, RMC, GGA, GLL - * $GPGLL,3513.8385,S,14900.7851,E,232420.594,A*21 - * $GPGGA,232420.59,3513.8385,S,14900.7851,E,1,05,3.4,00519,M,,,,*3F - * $GPRMB,... - * $GPRMC,232418.19,A,3513.8386,S,14900.7853,E,00.0,000.0,121199,12.,E*77 - * $GPAPB,... - * $GPGSA,... - * $GPGSV,... - * $GPGSV,... - */ -#define GPXXX 0 -#define GPRMC 1 -#define GPGGA 2 -#define GPGLL 4 - cp = rd_lastcode; - cmdtype=0; - if(strncmp(cp,"$GPRMC",6)==0) { - cmdtype=GPRMC; - } - else if(strncmp(cp,"$GPGGA",6)==0) { - cmdtype=GPGGA; - } - else if(strncmp(cp,"$GPGLL",6)==0) { - cmdtype=GPGLL; - } - else if(strncmp(cp,"$GPXXX",6)==0) { - cmdtype=GPXXX; + default: + DPRINTF(1, ("%s gpsread: %d '%s'\n", + refnumtoa(&peer->srcadr), rd_lencode, + rd_lastcode)); + break; } + up->tally.total++; + + /* + * --> below this point we have a valid NMEA sentence <-- + * + * Check sentence name. Skip first 2 chars (talker ID) in most + * cases, to allow for $GLGGA and $GPGGA etc. Since the name + * field has at least 5 chars we can simply shift the field + * start. + */ + cp = field_parse(&rdata, 0); + if (strncmp(cp + 2, "RMC,", 4) == 0) + sentence = NMEA_GPRMC; + else if (strncmp(cp + 2, "GGA,", 4) == 0) + sentence = NMEA_GPGGA; + else if (strncmp(cp + 2, "GLL,", 4) == 0) + sentence = NMEA_GPGLL; + else if (strncmp(cp + 2, "ZDA,", 4) == 0) + sentence = NMEA_GPZDA; + else if (strncmp(cp + 2, "ZDG,", 4) == 0) + sentence = NMEA_GPZDG; + else if (strncmp(cp, "PGRMF,", 6) == 0) + sentence = NMEA_PGRMF; else - return; - - + return; /* not something we know about */ + + /* Eventually output delay measurement now. */ + if (peer->ttl & NMEA_DELAYMEAS_MASK) { + mprintf_clock_stats(&peer->srcadr, "delay %0.6f %.*s", + ldexp(rd_timestamp.l_uf, -32), + (int)(strchr(rd_lastcode, ',') - rd_lastcode), + rd_lastcode); + } + /* See if I want to process this message type */ - if ( ((peer->ttl == 0) && (cmdtype != GPRMC)) - || ((peer->ttl != 0) && !(cmdtype & peer->ttl)) ) + if ((peer->ttl & NMEA_MESSAGE_MASK) && + !(peer->ttl & sentence_mode[sentence])) { + up->tally.filtered++; return; + } - pp->lencode = rd_lencode; - strcpy(pp->a_lastcode,rd_lastcode); - cp = pp->a_lastcode; - - pp->lastrec = up->tstamp = rd_tmp; - up->pollcnt = 2; + /* + * make sure it came in clean + * + * Apparently, older NMEA specifications (which are expensive) + * did not require the checksum for all sentences. $GPMRC is + * the only one so far identified which has always been required + * to include a checksum. + * + * Today, most NMEA GPS receivers checksum every sentence. To + * preserve its error-detection capabilities with modern GPSes + * while allowing operation without checksums on all but $GPMRC, + * we keep track of whether we've ever seen a valid checksum on + * a given sentence, and if so, reject future instances without + * checksum. ('up->cksum_type[NMEA_GPRMC]' is set in + * 'nmea_start()' to enforce checksums for $GPRMC right from the + * start.) + */ + if (up->cksum_type[sentence] <= (u_char)checkres) { + up->cksum_type[sentence] = (u_char)checkres; + } else { + DPRINTF(1, ("%s checksum missing: '%s'\n", + refnumtoa(&peer->srcadr), rd_lastcode)); + refclock_report(peer, CEVNT_BADREPLY); + up->tally.malformed++; + return; + } -#ifdef DEBUG - if (debug) - printf("nmea: timecode %d %s\n", pp->lencode, - pp->a_lastcode); -#endif + /* + * $GPZDG provides GPS time not UTC, and the two mix poorly. + * Once have processed a $GPZDG, do not process any further UTC + * sentences (all but $GPZDG currently). + */ + if (up->gps_time && NMEA_GPZDG != sentence) { + up->tally.filtered++; + return; + } + DPRINTF(1, ("%s processing %d bytes, timecode '%s'\n", + refnumtoa(&peer->srcadr), rd_lencode, rd_lastcode)); - /* Grab field depending on clock string type */ - switch( cmdtype ) { - case GPRMC: - /* - * Test for synchronization. Check for quality byte. - */ - dp = field_parse(cp,2); - if( dp[0] != 'A') - pp->leap = LEAP_NOTINSYNC; - else - pp->leap = LEAP_NOWARNING; - - /* Now point at the time field */ - dp = field_parse(cp,1); + /* + * Grab fields depending on clock string type and possibly wipe + * sensitive data from the last timecode. + */ + switch (sentence) { + + case NMEA_GPRMC: + /* Check quality byte, fetch data & time */ + rc_time = parse_time(&date, &tofs.tv_nsec, &rdata, 1); + pp->leap = parse_qual(&rdata, 2, 'A', 0); + rc_date = parse_date(&date, &rdata, 9, DATE_1_DDMMYY) + && unfold_century(&date, rd_timestamp.l_ui); + if (CLK_FLAG4 & pp->sloppyclockflag) + field_wipe(&rdata, 3, 4, 5, 6, -1); break; + case NMEA_GPGGA: + /* Check quality byte, fetch time only */ + rc_time = parse_time(&date, &tofs.tv_nsec, &rdata, 1); + pp->leap = parse_qual(&rdata, 6, '0', 1); + rc_date = unfold_day(&date, rd_timestamp.l_ui); + if (CLK_FLAG4 & pp->sloppyclockflag) + field_wipe(&rdata, 2, 4, -1); + break; - case GPGGA: - /* - * Test for synchronization. Check for quality byte. - */ - dp = field_parse(cp,6); - if( dp[0] == '0') - pp->leap = LEAP_NOTINSYNC; - else - pp->leap = LEAP_NOWARNING; - - /* Now point at the time field */ - dp = field_parse(cp,1); + case NMEA_GPGLL: + /* Check quality byte, fetch time only */ + rc_time = parse_time(&date, &tofs.tv_nsec, &rdata, 5); + pp->leap = parse_qual(&rdata, 6, 'A', 0); + rc_date = unfold_day(&date, rd_timestamp.l_ui); + if (CLK_FLAG4 & pp->sloppyclockflag) + field_wipe(&rdata, 1, 3, -1); + break; + + case NMEA_GPZDA: + /* No quality. Assume best, fetch time & full date */ + pp->leap = LEAP_NOWARNING; + rc_time = parse_time(&date, &tofs.tv_nsec, &rdata, 1); + rc_date = parse_date(&date, &rdata, 2, DATE_3_DDMMYYYY); break; + case NMEA_GPZDG: + /* Check quality byte, fetch time & full date */ + rc_time = parse_time(&date, &tofs.tv_nsec, &rdata, 1); + rc_date = parse_date(&date, &rdata, 2, DATE_3_DDMMYYYY); + pp->leap = parse_qual(&rdata, 4, '0', 1); + tofs.tv_sec = -1; /* GPZDG is following second */ + break; - case GPGLL: - /* - * Test for synchronization. Check for quality byte. + case NMEA_PGRMF: + /* get date, time, qualifier and GPS weektime. We need + * date and time-of-day for the century fix, so we read + * them first. */ - dp = field_parse(cp,6); - if( dp[0] != 'A') - pp->leap = LEAP_NOTINSYNC; - else - pp->leap = LEAP_NOWARNING; - - /* Now point at the time field */ - dp = field_parse(cp,5); + rc_date = parse_weekdata(&gpsw, &rdata, 1, 2, 5) + && parse_date(&date, &rdata, 3, DATE_1_DDMMYY); + rc_time = parse_time(&date, &tofs.tv_nsec, &rdata, 4); + pp->leap = parse_qual(&rdata, 11, '0', 1); + rc_date = rc_date + && gpsfix_century(&date, &gpsw, &up->century_cache); + if (CLK_FLAG4 & pp->sloppyclockflag) + field_wipe(&rdata, 6, 8, -1); break; - - - case GPXXX: - return; - default: + + default: + INVARIANT(0); /* Coverity 97123 */ return; - } - /* - * Check time code format of NMEA - */ - - if( !isdigit((int)dp[0]) || - !isdigit((int)dp[1]) || - !isdigit((int)dp[2]) || - !isdigit((int)dp[3]) || - !isdigit((int)dp[4]) || - !isdigit((int)dp[5]) - ) { - refclock_report(peer, CEVNT_BADREPLY); - return; - } - - - /* - * Convert time and check values. - */ - pp->hour = ((dp[0] - '0') * 10) + dp[1] - '0'; - pp->minute = ((dp[2] - '0') * 10) + dp[3] - '0'; - pp->second = ((dp[4] - '0') * 10) + dp[5] - '0'; - /* Default to 0 milliseconds, if decimal convert milliseconds in - one, two or three digits - */ - pp->nsec = 0; - if (dp[6] == '.') { - if (isdigit((int)dp[7])) { - pp->nsec = (dp[7] - '0') * 100000000; - if (isdigit((int)dp[8])) { - pp->nsec += (dp[8] - '0') * 10000000; - if (isdigit((int)dp[9])) { - pp->nsec += (dp[9] - '0') * 1000000; - } - } - } + /* Check sanity of time-of-day. */ + if (rc_time == 0) { /* no time or conversion error? */ + checkres = CEVNT_BADTIME; + up->tally.malformed++; + } + /* Check sanity of date. */ + else if (rc_date == 0) {/* no date or conversion error? */ + checkres = CEVNT_BADDATE; + up->tally.malformed++; } + /* check clock sanity; [bug 2143] */ + else if (pp->leap == LEAP_NOTINSYNC) { /* no good status? */ + checkres = CEVNT_BADREPLY; + up->tally.rejected++; + } + else + checkres = -1; - if (pp->hour > 23 || pp->minute > 59 || pp->second > 59 - || pp->nsec > 1000000000) { - refclock_report(peer, CEVNT_BADTIME); + if (checkres != -1) { + save_ltc(pp, rd_lastcode, rd_lencode); + refclock_report(peer, checkres); return; } + DPRINTF(1, ("%s effective timecode: %04u-%02u-%02u %02d:%02d:%02d\n", + refnumtoa(&peer->srcadr), + date.year, date.month, date.monthday, + date.hour, date.minute, date.second)); + /* Check if we must enter GPS time mode; log so if we do */ + if (!up->gps_time && (sentence == NMEA_GPZDG)) { + msyslog(LOG_INFO, "%s using GPS time as if it were UTC", + refnumtoa(&peer->srcadr)); + up->gps_time = 1; + } + /* - * Convert date and check values. + * Get the reference time stamp from the calendar buffer. + * Process the new sample in the median filter and determine the + * timecode timestamp, but only if the PPS is not in control. + * Discard sentence if reference time did not change. */ - if (cmdtype==GPRMC) { - dp = field_parse(cp,9); - day = dp[0] - '0'; - day = (day * 10) + dp[1] - '0'; - month = dp[2] - '0'; - month = (month * 10) + dp[3] - '0'; - pp->year = dp[4] - '0'; - pp->year = (pp->year * 10) + dp[5] - '0'; - } - else { - /* only time */ - time_t tt = time(NULL); - struct tm * t = gmtime(&tt); - day = t->tm_mday; - month = t->tm_mon + 1; - pp->year= t->tm_year; - } - - if (month < 1 || month > 12 || day < 1) { - refclock_report(peer, CEVNT_BADTIME); + rd_reftime = eval_gps_time(peer, &date, &tofs, &rd_timestamp); + if (L_ISEQU(&up->last_reftime, &rd_reftime)) { + /* Do not touch pp->a_lastcode on purpose! */ + up->tally.filtered++; return; } + up->last_reftime = rd_reftime; + rd_fudge = pp->fudgetime2; - /* Hmmmm this will be a nono for 2100,2200,2300 but I don't think I'll be here */ - /* good thing that 2000 is a leap year */ - /* pp->year will be 00-99 if read from GPS, 00-> (years since 1900) from tm_year */ - if (pp->year % 4) { - if (day > day1tab[month - 1]) { - refclock_report(peer, CEVNT_BADTIME); - return; - } - for (i = 0; i < month - 1; i++) - day += day1tab[i]; - } else { - if (day > day2tab[month - 1]) { - refclock_report(peer, CEVNT_BADTIME); - return; + DPRINTF(1, ("%s using '%s'\n", + refnumtoa(&peer->srcadr), rd_lastcode)); + + /* Data will be accepted. Update stats & log data. */ + up->tally.accepted++; + save_ltc(pp, rd_lastcode, rd_lencode); + pp->lastrec = rd_timestamp; + +#ifdef HAVE_PPSAPI + /* + * If we have PPS running, we try to associate the sentence + * with the last active edge of the PPS signal. + */ + if (up->ppsapi_lit) + switch (refclock_ppsrelate( + pp, &up->atom, &rd_reftime, &rd_timestamp, + pp->fudgetime1, &rd_fudge)) + { + case PPS_RELATE_PHASE: + up->ppsapi_gate = TRUE; + peer->precision = PPS_PRECISION; + peer->flags |= FLAG_PPS; + DPRINTF(2, ("%s PPS_RELATE_PHASE\n", + refnumtoa(&peer->srcadr))); + up->tally.pps_used++; + break; + + case PPS_RELATE_EDGE: + up->ppsapi_gate = TRUE; + peer->precision = PPS_PRECISION; + DPRINTF(2, ("%s PPS_RELATE_EDGE\n", + refnumtoa(&peer->srcadr))); + break; + + case PPS_RELATE_NONE: + default: + /* + * Resetting precision and PPS flag is done in + * 'nmea_poll', since it might be a glitch. But + * at the end of the poll cycle we know... + */ + DPRINTF(2, ("%s PPS_RELATE_NONE\n", + refnumtoa(&peer->srcadr))); + break; } - for (i = 0; i < month - 1; i++) - day += day2tab[i]; - } - pp->day = day; +#endif /* HAVE_PPSAPI */ + + refclock_process_offset(pp, rd_reftime, rd_timestamp, rd_fudge); +} +/* + * ------------------------------------------------------------------- + * nmea_poll - called by the transmit procedure + * + * Does the necessary bookkeeping stuff to keep the reported state of + * the clock in sync with reality. + * + * We go to great pains to avoid changing state here, since there may + * be more than one eavesdropper receiving the same timecode. + * ------------------------------------------------------------------- + */ +static void +nmea_poll( + int unit, + struct peer * peer + ) +{ + struct refclockproc * const pp = peer->procptr; + nmea_unit * const up = (nmea_unit *)pp->unitptr; + + /* + * Process median filter samples. If none received, declare a + * timeout and keep going. + */ #ifdef HAVE_PPSAPI /* - * If the PPSAPI is working, rather use its timestamps. - * assume that the PPS occurs on the second so blow any msec + * If we don't have PPS pulses and time stamps, turn PPS down + * for now. */ - if (nmea_pps(up, &rd_tmp) == 1) { - pp->lastrec = up->tstamp = rd_tmp; - pp->nsec = 0; + if (!up->ppsapi_gate) { + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + } else { + up->ppsapi_gate = FALSE; } #endif /* HAVE_PPSAPI */ /* - * Process the new sample in the median filter and determine the - * reference clock offset and dispersion. We use lastrec as both - * the reference time and receive time, in order to avoid being - * cute, like setting the reference time later than the receive - * time, which may cause a paranoid protocol module to chuck out - * the data. + * If the median filter is empty, claim a timeout. Else process + * the input data and keep the stats going. */ + if (pp->coderecv == pp->codeproc) { + refclock_report(peer, CEVNT_TIMEOUT); + } else { + pp->polls++; + pp->lastref = pp->lastrec; + refclock_receive(peer); + } + + /* + * If extended logging is required, write the tally stats to the + * clockstats file; otherwise just do a normal clock stats + * record. Clear the tally stats anyway. + */ + if (peer->ttl & NMEA_EXTLOG_MASK) { + /* Log & reset counters with extended logging */ + const char *nmea = pp->a_lastcode; + if (*nmea == '\0') nmea = "(none)"; + mprintf_clock_stats( + &peer->srcadr, "%s %u %u %u %u %u %u", + nmea, + up->tally.total, up->tally.accepted, + up->tally.rejected, up->tally.malformed, + up->tally.filtered, up->tally.pps_used); + } else { + record_clock_stats(&peer->srcadr, pp->a_lastcode); + } + ZERO(up->tally); +} - if (!refclock_process(pp)) { - refclock_report(peer, CEVNT_BADTIME); - return; +/* + * ------------------------------------------------------------------- + * Save the last timecode string, making sure it's properly truncated + * if necessary and NUL terminated in any case. + */ +static void +save_ltc( + struct refclockproc * const pp, + const char * const tc, + size_t len + ) +{ + if (len >= sizeof(pp->a_lastcode)) + len = sizeof(pp->a_lastcode) - 1; + pp->lencode = (u_short)len; + memcpy(pp->a_lastcode, tc, len); + pp->a_lastcode[len] = '\0'; +} + + +#if NMEA_WRITE_SUPPORT +/* + * ------------------------------------------------------------------- + * gps_send(fd, cmd, peer) Sends a command to the GPS receiver. + * as in gps_send(fd, "rqts,u", peer); + * + * If 'cmd' starts with a '$' it is assumed that this command is in raw + * format, that is, starts with '$', ends with '' and that any + * checksum is correctly provided; the command will be send 'as is' in + * that case. Otherwise the function will create the necessary frame + * (start char, chksum, final CRLF) on the fly. + * + * We don't currently send any data, but would like to send RTCM SC104 + * messages for differential positioning. It should also give us better + * time. Without a PPS output, we're Just fooling ourselves because of + * the serial code paths + * ------------------------------------------------------------------- + */ +static void +gps_send( + int fd, + const char * cmd, + struct peer * peer + ) +{ + /* $...*xy add 7 */ + char buf[NMEA_PROTO_MAXLEN + 7]; + int len; + u_char dcs; + const u_char *beg, *end; + + if (*cmd != '$') { + /* get checksum and length */ + beg = end = (const u_char*)cmd; + dcs = 0; + while (*end >= ' ' && *end != '*') + dcs ^= *end++; + len = end - beg; + /* format into output buffer with overflow check */ + len = snprintf(buf, sizeof(buf), "$%.*s*%02X\r\n", + len, beg, dcs); + if ((size_t)len >= sizeof(buf)) { + DPRINTF(1, ("%s gps_send: buffer overflow for command '%s'\n", + refnumtoa(&peer->srcadr), cmd)); + return; /* game over player 1 */ + } + cmd = buf; + } else { + len = strlen(cmd); } + DPRINTF(1, ("%s gps_send: '%.*s'\n", refnumtoa(&peer->srcadr), + len - 2, cmd)); + /* send out the whole stuff */ + if (write(fd, cmd, len) == -1) + refclock_report(peer, CEVNT_FAULT); +} +#endif /* NMEA_WRITE_SUPPORT */ - /* - * Only go on if we had been polled. +/* + * ------------------------------------------------------------------- + * helpers for faster field splitting + * ------------------------------------------------------------------- + * + * set up a field record, check syntax and verify checksum + * + * format is $XXXXX,1,2,3,4*ML + * + * 8-bit XOR of characters between $ and * noninclusive is transmitted + * in last two chars M and L holding most and least significant nibbles + * in hex representation such as: + * + * $GPGLL,5057.970,N,00146.110,E,142451,A*27 + * $GPVTG,089.0,T,,,15.2,N,,*7F + * + * Some other constraints: + * + The field name must at least 5 upcase characters or digits and must + * start with a character. + * + The checksum (if present) must be uppercase hex digits. + * + The length of a sentence is limited to 80 characters (not including + * the final CR/LF nor the checksum, but including the leading '$') + * + * Return values: + * + CHECK_INVALID + * The data does not form a valid NMEA sentence or a checksum error + * occurred. + * + CHECK_VALID + * The data is a valid NMEA sentence but contains no checksum. + * + CHECK_CSVALID + * The data is a valid NMEA sentence and passed the checksum test. + * ------------------------------------------------------------------- + */ +static int +field_init( + nmea_data * data, /* context structure */ + char * cptr, /* start of raw data */ + int dlen /* data len, not counting trailing NUL */ + ) +{ + u_char cs_l; /* checksum local computed */ + u_char cs_r; /* checksum remote given */ + char * eptr; /* buffer end end pointer */ + char tmp; /* char buffer */ + + cs_l = 0; + cs_r = 0; + /* some basic input constraints */ + if (dlen < 0) + dlen = 0; + eptr = cptr + dlen; + *eptr = '\0'; + + /* load data context */ + data->base = cptr; + data->cptr = cptr; + data->cidx = 0; + data->blen = dlen; + + /* syntax check follows here. check allowed character + * sequences, updating the local computed checksum as we go. + * + * regex equiv: '^\$[A-Z][A-Z0-9]{4,}[^*]*(\*[0-9A-F]{2})?$' */ - if (!up->polled) - return; - up->polled = 0; - pp->lastref = pp->lastrec; - refclock_receive(peer); - /* If we get here - what we got from the clock is OK, so say so */ - refclock_report(peer, CEVNT_NOMINAL); + /* -*- start character: '^\$' */ + if (*cptr == '\0') + return CHECK_EMPTY; + if (*cptr++ != '$') + return CHECK_INVALID; + + /* -*- advance context beyond start character */ + data->base++; + data->cptr++; + data->blen--; + + /* -*- field name: '[A-Z][A-Z0-9]{4,},' */ + if (*cptr < 'A' || *cptr > 'Z') + return CHECK_INVALID; + cs_l ^= *cptr++; + while ((*cptr >= 'A' && *cptr <= 'Z') || + (*cptr >= '0' && *cptr <= '9') ) + cs_l ^= *cptr++; + if (*cptr != ',' || (cptr - data->base) < NMEA_PROTO_IDLEN) + return CHECK_INVALID; + cs_l ^= *cptr++; + + /* -*- data: '[^*]*' */ + while (*cptr && *cptr != '*') + cs_l ^= *cptr++; + + /* -*- checksum field: (\*[0-9A-F]{2})?$ */ + if (*cptr == '\0') + return CHECK_VALID; + if (*cptr != '*' || cptr != eptr - 3 || + (cptr - data->base) >= NMEA_PROTO_MAXLEN) + return CHECK_INVALID; + + for (cptr++; (tmp = *cptr) != '\0'; cptr++) { + if (tmp >= '0' && tmp <= '9') + cs_r = (cs_r << 4) + (tmp - '0'); + else if (tmp >= 'A' && tmp <= 'F') + cs_r = (cs_r << 4) + (tmp - 'A' + 10); + else + break; + } - record_clock_stats(&peer->srcadr, pp->a_lastcode); + /* -*- make sure we are at end of string and csum matches */ + if (cptr != eptr || cs_l != cs_r) + return CHECK_INVALID; + return CHECK_CSVALID; } /* - * nmea_poll - called by the transmit procedure + * ------------------------------------------------------------------- + * fetch a data field by index, zero being the name field. If this + * function is called repeatedly with increasing indices, the total load + * is O(n), n being the length of the string; if it is called with + * decreasing indices, the total load is O(n^2). Try not to go backwards + * too often. + * ------------------------------------------------------------------- + */ +static char * +field_parse( + nmea_data * data, + int fn + ) +{ + char tmp; + + if (fn < data->cidx) { + data->cidx = 0; + data->cptr = data->base; + } + while ((fn > data->cidx) && (tmp = *data->cptr) != '\0') { + data->cidx += (tmp == ','); + data->cptr++; + } + return data->cptr; +} + +/* + * ------------------------------------------------------------------- + * Wipe (that is, overwrite with '_') data fields and the checksum in + * the last timecode. The list of field indices is given as integers + * in a varargs list, preferrably in ascending order, in any case + * terminated by a negative field index. + * + * A maximum number of 8 fields can be overwritten at once to guard + * against runaway (that is, unterminated) argument lists. * - * We go to great pains to avoid changing state here, since there may be - * more than one eavesdropper receiving the same timecode. + * This function affects what a remote user can see with + * + * ntpq -c clockvar + * + * Note that this also removes the wiped fields from any clockstats + * log. Some NTP operators monitor their NMEA GPS using the change in + * location in clockstats over time as as a proxy for the quality of + * GPS reception and thereby time reported. + * ------------------------------------------------------------------- */ static void -nmea_poll( - int unit, - struct peer *peer +field_wipe( + nmea_data * data, + ... + ) +{ + va_list va; /* vararg index list */ + int fcnt; /* safeguard against runaway arglist */ + int fidx; /* field to nuke, or -1 for checksum */ + char * cp; /* overwrite destination */ + + fcnt = 8; + cp = NULL; + va_start(va, data); + do { + fidx = va_arg(va, int); + if (fidx >= 0 && fidx <= NMEA_PROTO_FIELDS) { + cp = field_parse(data, fidx); + } else { + cp = data->base + data->blen; + if (data->blen >= 3 && cp[-3] == '*') + cp -= 2; + } + for ( ; '\0' != *cp && '*' != *cp && ',' != *cp; cp++) + if ('.' != *cp) + *cp = '_'; + } while (fcnt-- && fidx >= 0); + va_end(va); +} + +/* + * ------------------------------------------------------------------- + * PARSING HELPERS + * ------------------------------------------------------------------- + * + * Check sync status + * + * If the character at the data field start matches the tag value, + * return LEAP_NOWARNING and LEAP_NOTINSYNC otherwise. If the 'inverted' + * flag is given, just the opposite value is returned. If there is no + * data field (*cp points to the NUL byte) the result is LEAP_NOTINSYNC. + * ------------------------------------------------------------------- + */ +static u_char +parse_qual( + nmea_data * rd, + int idx, + char tag, + int inv + ) +{ + static const u_char table[2] = + { LEAP_NOTINSYNC, LEAP_NOWARNING }; + char * dp; + + dp = field_parse(rd, idx); + + return table[ *dp && ((*dp == tag) == !inv) ]; +} + +/* + * ------------------------------------------------------------------- + * Parse a time stamp in HHMMSS[.sss] format with error checking. + * + * returns 1 on success, 0 on failure + * ------------------------------------------------------------------- + */ +static int +parse_time( + struct calendar * jd, /* result calendar pointer */ + long * ns, /* storage for nsec fraction */ + nmea_data * rd, + int idx ) { - register struct nmeaunit *up; - struct refclockproc *pp; + static const unsigned long weight[4] = { + 0, 100000000, 10000000, 1000000 + }; + + int rc; + u_int h; + u_int m; + u_int s; + int p1; + int p2; + u_long f; + char * dp; + + dp = field_parse(rd, idx); + rc = sscanf(dp, "%2u%2u%2u%n.%3lu%n", &h, &m, &s, &p1, &f, &p2); + if (rc < 3 || p1 != 6) { + DPRINTF(1, ("nmea: invalid time code: '%.6s'\n", dp)); + return FALSE; + } + + /* value sanity check */ + if (h > 23 || m > 59 || s > 60) { + DPRINTF(1, ("nmea: invalid time spec %02u:%02u:%02u\n", + h, m, s)); + return FALSE; + } - pp = peer->procptr; - up = (struct nmeaunit *)pp->unitptr; - if (up->pollcnt == 0) - refclock_report(peer, CEVNT_TIMEOUT); + jd->hour = (u_char)h; + jd->minute = (u_char)m; + jd->second = (u_char)s; + /* if we have a fraction, scale it up to nanoseconds. */ + if (rc == 4) + *ns = f * weight[p2 - p1 - 1]; else - up->pollcnt--; - pp->polls++; - up->polled = 1; + *ns = 0; + + return TRUE; +} + +/* + * ------------------------------------------------------------------- + * Parse a date string from an NMEA sentence. This could either be a + * partial date in DDMMYY format in one field, or DD,MM,YYYY full date + * spec spanning three fields. This function does some extensive error + * checking to make sure the date string was consistent. + * + * returns 1 on success, 0 on failure + * ------------------------------------------------------------------- + */ +static int +parse_date( + struct calendar * jd, /* result pointer */ + nmea_data * rd, + int idx, + enum date_fmt fmt + ) +{ + int rc; + u_int y; + u_int m; + u_int d; + int p; + char * dp; + + dp = field_parse(rd, idx); + switch (fmt) { + + case DATE_1_DDMMYY: + rc = sscanf(dp, "%2u%2u%2u%n", &d, &m, &y, &p); + if (rc != 3 || p != 6) { + DPRINTF(1, ("nmea: invalid date code: '%.6s'\n", + dp)); + return FALSE; + } + break; + + case DATE_3_DDMMYYYY: + rc = sscanf(dp, "%2u,%2u,%4u%n", &d, &m, &y, &p); + if (rc != 3 || p != 10) { + DPRINTF(1, ("nmea: invalid date code: '%.10s'\n", + dp)); + return FALSE; + } + break; + + default: + DPRINTF(1, ("nmea: invalid parse format: %d\n", fmt)); + return FALSE; + } + + /* value sanity check */ + if (d < 1 || d > 31 || m < 1 || m > 12) { + DPRINTF(1, ("nmea: invalid date spec (YMD) %04u:%02u:%02u\n", + y, m, d)); + return FALSE; + } + + /* store results */ + jd->monthday = (u_char)d; + jd->month = (u_char)m; + jd->year = (u_short)y; + + return TRUE; +} + +/* + * ------------------------------------------------------------------- + * Parse GPS week time info from an NMEA sentence. This info contains + * the GPS week number, the GPS time-of-week and the leap seconds GPS + * to UTC. + * + * returns 1 on success, 0 on failure + * ------------------------------------------------------------------- + */ +static int +parse_weekdata( + gps_weektm * wd, + nmea_data * rd, + int weekidx, + int timeidx, + int leapidx + ) +{ + u_long secs; + int fcnt; + + /* parse fields and count success */ + fcnt = sscanf(field_parse(rd, weekidx), "%hu", &wd->wt_week); + fcnt += sscanf(field_parse(rd, timeidx), "%lu", &secs); + fcnt += sscanf(field_parse(rd, leapidx), "%hd", &wd->wt_leap); + if (fcnt != 3 || wd->wt_week >= 1024 || secs >= 7*SECSPERDAY) { + DPRINTF(1, ("nmea: parse_weekdata: invalid weektime spec\n")); + return FALSE; + } + wd->wt_time = (u_int32)secs; + + return TRUE; +} + +/* + * ------------------------------------------------------------------- + * funny calendar-oriented stuff -- perhaps a bit hard to grok. + * ------------------------------------------------------------------- + * + * Unfold a time-of-day (seconds since midnight) around the current + * system time in a manner that guarantees an absolute difference of + * less than 12hrs. + * + * This function is used for NMEA sentences that contain no date + * information. This requires the system clock to be in +/-12hrs + * around the true time, or the clock will synchronize the system 1day + * off if not augmented with a time sources that also provide the + * necessary date information. + * + * The function updates the calendar structure it also uses as + * input to fetch the time from. + * + * returns 1 on success, 0 on failure + * ------------------------------------------------------------------- + */ +static int +unfold_day( + struct calendar * jd, + u_int32 rec_ui + ) +{ + vint64 rec_qw; + ntpcal_split rec_ds; /* - * usually nmea_receive can get a timestamp every second + * basically this is the peridiodic extension of the receive + * time - 12hrs to the time-of-day with a period of 1 day. + * But we would have to execute this in 64bit arithmetic, and we + * cannot assume we can do this; therefore this is done + * in split representation. */ + rec_qw = ntpcal_ntp_to_ntp(rec_ui - SECSPERDAY/2, NULL); + rec_ds = ntpcal_daysplit(&rec_qw); + rec_ds.lo = ntpcal_periodic_extend(rec_ds.lo, + ntpcal_date_to_daysec(jd), + SECSPERDAY); + rec_ds.hi += ntpcal_daysec_to_date(jd, rec_ds.lo); + return (ntpcal_rd_to_date(jd, rec_ds.hi + DAY_NTP_STARTS) >= 0); +} - gps_send(pp->io.fd,"$PMOTG,RMC,0000*1D\r\n", peer); +/* + * ------------------------------------------------------------------- + * A 2-digit year is expanded into full year spec around the year found + * in 'jd->year'. This should be in +79/-19 years around the system time, + * or the result will be off by 100 years. The assymetric behaviour was + * chosen to enable inital sync for systems that do not have a + * battery-backup clock and start with a date that is typically years in + * the past. + * + * Since the GPS epoch starts at 1980-01-06, the resulting year will be + * not be before 1980 in any case. + * + * returns 1 on success, 0 on failure + * ------------------------------------------------------------------- + */ +static int +unfold_century( + struct calendar * jd, + u_int32 rec_ui + ) +{ + struct calendar rec; + int32 baseyear; + + ntpcal_ntp_to_date(&rec, rec_ui, NULL); + baseyear = rec.year - 20; + if (baseyear < g_gpsMinYear) + baseyear = g_gpsMinYear; + jd->year = (u_short)ntpcal_periodic_extend(baseyear, jd->year, + 100); + + return ((baseyear <= jd->year) && (baseyear + 100 > jd->year)); } /* + * ------------------------------------------------------------------- + * A 2-digit year is expanded into a full year spec by correlation with + * a GPS week number and the current leap second count. + * + * The GPS week time scale counts weeks since Sunday, 1980-01-06, modulo + * 1024 and seconds since start of the week. The GPS time scale is based + * on international atomic time (TAI), so the leap second difference to + * UTC is also needed for a proper conversion. * - * gps_send(fd,cmd, peer) Sends a command to the GPS receiver. - * as gps_send(fd,"rqts,u\r", peer); + * A brute-force analysis (that is, test for every date) shows that a + * wrong assignment of the century can not happen between the years 1900 + * to 2399 when comparing the week signatures for different + * centuries. (I *think* that will not happen for 400*1024 years, but I + * have no valid proof. -*-perlinger@ntp.org-*-) * - * We don't currently send any data, but would like to send - * RTCM SC104 messages for differential positioning. It should - * also give us better time. Without a PPS output, we're - * Just fooling ourselves because of the serial code paths + * This function is bound to to work between years 1980 and 2399 + * (inclusive), which should suffice for now ;-) * + * Note: This function needs a full date&time spec on input due to the + * necessary leap second corrections! + * + * returns 1 on success, 0 on failure + * ------------------------------------------------------------------- */ -static void -gps_send( - int fd, - const char *cmd, - struct peer *peer - ) +static int +gpsfix_century( + struct calendar * jd, + const gps_weektm * wd, + u_short * century + ) { + int32 days; + int32 doff; + u_short week; + u_short year; + int loop; + + /* Get day offset. Assumes that the input time is in range and + * that the leap seconds do not shift more than +/-1 day. + */ + doff = ntpcal_date_to_daysec(jd) + wd->wt_leap; + doff = (doff >= SECSPERDAY) - (doff < 0); - if (write(fd, cmd, strlen(cmd)) == -1) { - refclock_report(peer, CEVNT_FAULT); + /* + * Loop over centuries to get a match, starting with the last + * successful one. (Or with the 19th century if the cached value + * is out of range...) + */ + year = jd->year % 100; + for (loop = 5; loop > 0; loop--,(*century)++) { + if (*century < 19 || *century >= 24) + *century = 19; + /* Get days and week in GPS epoch */ + jd->year = year + *century * 100; + days = ntpcal_date_to_rd(jd) - DAY_GPS_STARTS + doff; + week = (days / 7) % 1024; + if (days >= 0 && wd->wt_week == week) + return TRUE; /* matched... */ } + + jd->year = year; + return FALSE; /* match failed... */ } -static char * -field_parse( - char *cp, - int fn +/* + * ------------------------------------------------------------------- + * And now the final execise: Considering the fact that many (most?) + * GPS receivers cannot handle a GPS epoch wrap well, we try to + * compensate for that problem by unwrapping a GPS epoch around the + * receive stamp. Another execise in periodic unfolding, of course, + * but with enough points to take care of. + * + * Note: The integral part of 'tofs' is intended to handle small(!) + * systematic offsets, as -1 for handling $GPZDG, which gives the + * following second. (sigh...) The absolute value shall be less than a + * day (86400 seconds). + * ------------------------------------------------------------------- + */ +static l_fp +eval_gps_time( + struct peer * peer, /* for logging etc */ + const struct calendar * gpst, /* GPS time stamp */ + const struct timespec * tofs, /* GPS frac second & offset */ + const l_fp * xrecv /* receive time stamp */ ) { - char *tp; - int i = fn; + struct refclockproc * const pp = peer->procptr; + nmea_unit * const up = (nmea_unit *)pp->unitptr; + + l_fp retv; + + /* components of calculation */ + int32_t rcv_sec, rcv_day; /* receive ToD and day */ + int32_t gps_sec, gps_day; /* GPS ToD and day in NTP epoch */ + int32_t adj_day, weeks; /* adjusted GPS day and week shift */ + + /* some temporaries to shuffle data */ + vint64 vi64; + ntpcal_split rs64; + + /* evaluate time stamp from receiver. */ + gps_sec = ntpcal_date_to_daysec(gpst); + gps_day = ntpcal_date_to_rd(gpst) - DAY_NTP_STARTS; + + /* merge in fractional offset */ + retv = tspec_intv_to_lfp(*tofs); + gps_sec += retv.l_i; + + /* If we fully trust the GPS receiver, just combine days and + * seconds and be done. */ + if (peer->ttl & NMEA_DATETRUST_MASK) { + retv.l_ui = ntpcal_dayjoin(gps_day, gps_sec).D_s.lo; + return retv; + } - for (tp = cp; *tp != '\0'; tp++) { - if (*tp == ',') - i--; - if (i == 0) - break; + /* So we do not trust the GPS receiver to deliver a correct date + * due to the GPS epoch changes. We map the date from the + * receiver into the +/-512 week interval around the receive + * time in that case. This would be a tad easier with 64bit + * calculations, but again, we restrict the code to 32bit ops + * when possible. */ + + /* - make sure the GPS fractional day is normalised + * Applying the offset value might have put us slightly over the + * edge of the allowed range for seconds-of-day. Doing a full + * division with floor correction is overkill here; a simple + * addition or subtraction step is sufficient. Using WHILE loops + * gives the right result even if the offset exceeds one day, + * which is NOT what it's intented for! */ + while (gps_sec >= SECSPERDAY) { + gps_sec -= SECSPERDAY; + gps_day += 1; } - return (++tp); + while (gps_sec < 0) { + gps_sec += SECSPERDAY; + gps_day -= 1; + } + + /* - get unfold base: day of full recv time - 512 weeks */ + vi64 = ntpcal_ntp_to_ntp(xrecv->l_ui, NULL); + rs64 = ntpcal_daysplit(&vi64); + rcv_sec = rs64.lo; + rcv_day = rs64.hi - 512 * 7; + + /* - take the fractional days into account + * If the fractional day of the GPS time is smaller than the + * fractional day of the receive time, we shift the base day for + * the unfold by 1. */ + if ( gps_sec < rcv_sec + || (gps_sec == rcv_sec && retv.l_uf < xrecv->l_uf)) + rcv_day += 1; + + /* - don't warp ahead of GPS invention! */ + if (rcv_day < g_gpsMinBase) + rcv_day = g_gpsMinBase; + + /* - let the magic happen: */ + adj_day = ntpcal_periodic_extend(rcv_day, gps_day, 1024*7); + + /* - check if we should log a GPS epoch warp */ + weeks = (adj_day - gps_day) / 7; + if (weeks != up->epoch_warp) { + up->epoch_warp = weeks; + LOGIF(CLOCKINFO, (LOG_INFO, + "%s Changed GPS epoch warp to %d weeks", + refnumtoa(&peer->srcadr), weeks)); + } + + /* - build result and be done */ + retv.l_ui = ntpcal_dayjoin(adj_day, gps_sec).D_s.lo; + return retv; +} + +/* + * =================================================================== + * + * NMEAD support + * + * original nmead support added by Jon Miner (cp_n18@yahoo.com) + * + * See http://home.hiwaay.net/~taylorc/gps/nmea-server/ + * for information about nmead + * + * To use this, you need to create a link from /dev/gpsX to + * the server:port where nmead is running. Something like this: + * + * ln -s server:port /dev/gps1 + * + * Split into separate function by Juergen Perlinger + * (perlinger-at-ntp-dot-org) + * + * =================================================================== + */ +static int +nmead_open( + const char * device + ) +{ + int fd = -1; /* result file descriptor */ + +#ifdef HAVE_READLINK + char host[80]; /* link target buffer */ + char * port; /* port name or number */ + int rc; /* result code (several)*/ + int sh; /* socket handle */ + struct addrinfo ai_hint; /* resolution hint */ + struct addrinfo *ai_list; /* resolution result */ + struct addrinfo *ai; /* result scan ptr */ + + fd = -1; + + /* try to read as link, make sure no overflow occurs */ + rc = readlink(device, host, sizeof(host)); + if ((size_t)rc >= sizeof(host)) + return fd; /* error / overflow / truncation */ + host[rc] = '\0'; /* readlink does not place NUL */ + + /* get port */ + port = strchr(host, ':'); + if (!port) + return fd; /* not 'host:port' syntax ? */ + *port++ = '\0'; /* put in separator */ + + /* get address infos and try to open socket + * + * This getaddrinfo() is naughty in ntpd's nonblocking main + * thread, but you have to go out of your wary to use this code + * and typically the blocking is at startup where its impact is + * reduced. The same holds for the 'connect()', as it is + * blocking, too... + */ + ZERO(ai_hint); + ai_hint.ai_protocol = IPPROTO_TCP; + ai_hint.ai_socktype = SOCK_STREAM; + if (getaddrinfo(host, port, &ai_hint, &ai_list)) + return fd; + + for (ai = ai_list; ai && (fd == -1); ai = ai->ai_next) { + sh = socket(ai->ai_family, ai->ai_socktype, + ai->ai_protocol); + if (INVALID_SOCKET == sh) + continue; + rc = connect(sh, ai->ai_addr, ai->ai_addrlen); + if (-1 != rc) + fd = sh; + else + close(sh); + } + freeaddrinfo(ai_list); +#else + fd = -1; +#endif + + return fd; } #else -int refclock_nmea_bs; -#endif /* REFCLOCK */ +NONEMPTY_TRANSLATION_UNIT +#endif /* REFCLOCK && CLOCK_NMEA */ diff --git a/contrib/ntp/ntpd/refclock_oncore.c b/contrib/ntp/ntpd/refclock_oncore.c index e1d23a991..30924b8bb 100644 --- a/contrib/ntp/ntpd/refclock_oncore.c +++ b/contrib/ntp/ntpd/refclock_oncore.c @@ -11,7 +11,7 @@ * Driver for some of the various the Motorola Oncore GPS receivers. * should work with Basic, PVT6, VP, UT, UT+, GT, GT+, SL, M12, M12+T * The receivers with TRAIM (VP, UT, UT+, M12+T), will be more accurate - * than the others. + * than the others. * The receivers without position hold (GT, GT+) will be less accurate. * * Tested with: @@ -52,6 +52,48 @@ * MANUFACTUR DATE 2J17 MANUFACTUR DATE 3G15 * * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * BUG[1220] OK, big patch, but mostly done mechanically. Change direct calls to write + * to clockstats to a call to oncore_log, which now calls the old routine plus msyslog. + * Have to set the LOG_LEVELS of the calls for msyslog, and this was done by hand. New + * routine oncore_log. + * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * BUG[1218] The comment on where the oncore driver gets its input file does not + * agree with the code. Change the comment. + * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * change exit statements to return(0) in main program. I had assumed that if the + * PPS driver did not start for some reason, we shuould stop NTPD itelf. Others + * disagree. We now give an ERR log message and stop this driver. + * -------------------------------------------------------------------------- + * Reg Clemens (June 2009) + * A bytes available message for the input subsystem (Debug message). + * -------------------------------------------------------------------------- + * Reg Clemens (Nov 2008) + * This code adds a message for TRAIM messages. Users often worry about the + * driver not starting up, and it is often because of signal strength being low. + * Low signal strength will give TRAIM messages. + * -------------------------------------------------------------------------- + * Reg Clemens (Nov 2008) + * Add waiting on Almanac Message. + * -------------------------------------------------------------------------- + * Reg Clemens (Nov 2008) + * Add back in @@Bl code to do the @@Bj/@@Gj that is in later ONCOREs + * LEAP SECONDS: All of the ONCORE receivers, VP -> M12T have the @@Bj command + * that says 'Leap Pending'. As documented it only becomes true in the month + * before the leap second is to be applied, but in practice at least some of + * the receivers turn this indicator on as soon as the message is posted, which + * can be 6months early. As such, we use the Bj command to turn on the + * instance->pp->leap indicator but only run this test in December and June for + * updates on 1Jan and 1July. + * + * The @@Gj command exists in later ONCOREs, and it gives the exact date + * and size of the Leap Update. It can be emulated in the VP using the @@Bl + * command which reads the raw Satellite Broadcast Messages. + * We use these two commands to print informative messages in the clockstats + * file once per day as soon as the message appears on the satellites. + * -------------------------------------------------------------------------- * Reg Clemens (Feb 2006) * Fix some gcc4 compiler complaints * Fix possible segfault in oncore_init_shmem @@ -119,9 +161,11 @@ #include "ntp_io.h" #include "ntp_unixtime.h" #include "ntp_refclock.h" +#include "ntp_calendar.h" #include "ntp_stdlib.h" #include +#include #include #include #ifdef ONCORE_SHMEM_STATUS @@ -137,9 +181,17 @@ # include "ppsapi_timepps.h" #endif -#ifdef HAVE_SYS_SIO_H -# include -#endif +struct Bl { + int dt_ls; + int dt_lsf; + int WN; + int DN; + int WN_lsf; + int DN_lsf; + int wn_flg; + int lsf_flg; + int Bl_day; +} Bl; enum receive_state { ONCORE_NO_IDEA, @@ -265,14 +317,18 @@ struct instance { u_char count4; /* cycles thru leap after Gj to issue Bj */ u_char count5; /* cycles thru get_timestamp waiting for valid UTC correction */ u_char count5_set; /* only set count5 once */ + u_char counta; /* count for waiting on almanac message */ u_char pollcnt; u_char timeout; /* count to retry Cj after Fa self-test */ + u_char max_len; /* max length message seen by oncore_log, for debugging */ + u_char max_count; /* count for message statistics */ struct RSM rsm; /* bits extracted from Receiver Status Msg in @@Ea */ + struct Bl Bl; /* Satellite Broadcast Data Message */ u_char printed; u_char polled; u_long ev_serial; - int Rcvptr; + unsigned Rcvptr; u_char Rcvbuf[500]; u_char BEHa[160]; /* Ba, Ea or Ha */ u_char BEHn[80]; /* Bn , En , or Hn */ @@ -281,6 +337,7 @@ struct instance { u_char saw_At; u_char saw_Ay; u_char saw_Az; + s_char saw_Bj; s_char saw_Gj; u_char have_dH; u_char init_type; @@ -294,60 +351,67 @@ struct instance { u_char once; /* one pass code at top of BaEaHa */ s_char assert; u_char hardpps; + s_char pps_control; /* PPS control, M12 only */ + s_char pps_control_msg_seen; }; #define rcvbuf instance->Rcvbuf #define rcvptr instance->Rcvptr -static int oncore_start P((int, struct peer *)); -static void oncore_poll P((int, struct peer *)); -static void oncore_shutdown P((int, struct peer *)); -static void oncore_consume P((struct instance *)); -static void oncore_read_config P((struct instance *)); -static void oncore_receive P((struct recvbuf *)); -static int oncore_ppsapi P((struct instance *)); -static void oncore_get_timestamp P((struct instance *, long, long)); -static void oncore_init_shmem P((struct instance *)); - -static void oncore_antenna_report P((struct instance *, enum antenna_state)); -static void oncore_chan_test P((struct instance *)); -static void oncore_check_almanac P((struct instance *)); -static void oncore_check_antenna P((struct instance *)); -static void oncore_check_leap_sec P((struct instance *)); -static int oncore_checksum_ok P((u_char *, int)); -static void oncore_compute_dH P((struct instance *)); -static void oncore_load_almanac P((struct instance *)); -static void oncore_print_Cb P((struct instance *, u_char *)); -/* static void oncore_print_array P((u_char *, int)); */ -static void oncore_print_posn P((struct instance *)); -static void oncore_sendmsg P((int, u_char *, size_t)); -static void oncore_set_posn P((struct instance *)); -static void oncore_set_traim P((struct instance *)); -static void oncore_shmem_get_3D P((struct instance *)); -static void oncore_ss P((struct instance *)); -static int oncore_wait_almanac P((struct instance *)); - -static void oncore_msg_any P((struct instance *, u_char *, size_t, int)); -static void oncore_msg_Adef P((struct instance *, u_char *, size_t)); -static void oncore_msg_Ag P((struct instance *, u_char *, size_t)); -static void oncore_msg_As P((struct instance *, u_char *, size_t)); -static void oncore_msg_At P((struct instance *, u_char *, size_t)); -static void oncore_msg_Ay P((struct instance *, u_char *, size_t)); -static void oncore_msg_Az P((struct instance *, u_char *, size_t)); -static void oncore_msg_BaEaHa P((struct instance *, u_char *, size_t)); -static void oncore_msg_Bd P((struct instance *, u_char *, size_t)); -static void oncore_msg_Bj P((struct instance *, u_char *, size_t)); -static void oncore_msg_BnEnHn P((struct instance *, u_char *, size_t)); -static void oncore_msg_CaFaIa P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cb P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cf P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cj P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cj_id P((struct instance *, u_char *, size_t)); -static void oncore_msg_Cj_init P((struct instance *, u_char *, size_t)); -static void oncore_msg_Ga P((struct instance *, u_char *, size_t)); -static void oncore_msg_Gb P((struct instance *, u_char *, size_t)); -static void oncore_msg_Gj P((struct instance *, u_char *, size_t)); -static void oncore_msg_Sz P((struct instance *, u_char *, size_t)); +static int oncore_start (int, struct peer *); +static void oncore_poll (int, struct peer *); +static void oncore_shutdown (int, struct peer *); +static void oncore_consume (struct instance *); +static void oncore_read_config (struct instance *); +static void oncore_receive (struct recvbuf *); +static int oncore_ppsapi (struct instance *); +static void oncore_get_timestamp (struct instance *, long, long); +static void oncore_init_shmem (struct instance *); + +static void oncore_antenna_report (struct instance *, enum antenna_state); +static void oncore_chan_test (struct instance *); +static void oncore_check_almanac (struct instance *); +static void oncore_check_antenna (struct instance *); +static void oncore_check_leap_sec (struct instance *); +static int oncore_checksum_ok (u_char *, int); +static void oncore_compute_dH (struct instance *); +static void oncore_load_almanac (struct instance *); +static void oncore_log (struct instance *, int, const char *); +static int oncore_log_f (struct instance *, int, const char *, ...) + NTP_PRINTF(3, 4); +static void oncore_print_Cb (struct instance *, u_char *); +/* static void oncore_print_array (u_char *, int); */ +static void oncore_print_posn (struct instance *); +static void oncore_sendmsg (struct instance *, u_char *, size_t); +static void oncore_set_posn (struct instance *); +static void oncore_set_traim (struct instance *); +static void oncore_shmem_get_3D (struct instance *); +static void oncore_ss (struct instance *); +static int oncore_wait_almanac (struct instance *); + +static void oncore_msg_any (struct instance *, u_char *, size_t, int); +static void oncore_msg_Adef (struct instance *, u_char *, size_t); +static void oncore_msg_Ag (struct instance *, u_char *, size_t); +static void oncore_msg_As (struct instance *, u_char *, size_t); +static void oncore_msg_At (struct instance *, u_char *, size_t); +static void oncore_msg_Ay (struct instance *, u_char *, size_t); +static void oncore_msg_Az (struct instance *, u_char *, size_t); +static void oncore_msg_BaEaHa (struct instance *, u_char *, size_t); +static void oncore_msg_Bd (struct instance *, u_char *, size_t); +static void oncore_msg_Bj (struct instance *, u_char *, size_t); +static void oncore_msg_Bl (struct instance *, u_char *, size_t); +static void oncore_msg_BnEnHn (struct instance *, u_char *, size_t); +static void oncore_msg_CaFaIa (struct instance *, u_char *, size_t); +static void oncore_msg_Cb (struct instance *, u_char *, size_t); +static void oncore_msg_Cf (struct instance *, u_char *, size_t); +static void oncore_msg_Cj (struct instance *, u_char *, size_t); +static void oncore_msg_Cj_id (struct instance *, u_char *, size_t); +static void oncore_msg_Cj_init (struct instance *, u_char *, size_t); +static void oncore_msg_Ga (struct instance *, u_char *, size_t); +static void oncore_msg_Gb (struct instance *, u_char *, size_t); +static void oncore_msg_Gc (struct instance *, u_char *, size_t); +static void oncore_msg_Gj (struct instance *, u_char *, size_t); +static void oncore_msg_Sz (struct instance *, u_char *, size_t); struct refclock refclock_oncore = { oncore_start, /* start up driver */ @@ -367,51 +431,52 @@ struct refclock refclock_oncore = { static struct msg_desc { const char flag[3]; const int len; - void (*handler) P((struct instance *, u_char *, size_t)); + void (*handler) (struct instance *, u_char *, size_t); const char *fmt; int shmem; } oncore_messages[] = { /* Ea and En first since they're most common */ - { "Ea", 76, oncore_msg_BaEaHa, "mdyyhmsffffaaaaoooohhhhmmmmvvhhddtntimsdimsdimsdimsdimsdimsdimsdimsdsC" }, - { "Ba", 68, oncore_msg_BaEaHa, "mdyyhmsffffaaaaoooohhhhmmmmvvhhddtntimsdimsdimsdimsdimsdimsdsC" }, - { "Ha", 154, oncore_msg_BaEaHa, "mdyyhmsffffaaaaoooohhhhmmmmaaaaoooohhhhmmmmVVvvhhddntimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddssrrccooooTTushmvvvvvvC" }, - { "Bn", 59, oncore_msg_BnEnHn, "otaapxxxxxxxxxxpysreensffffsffffsffffsffffsffffsffffC" }, - { "En", 69, oncore_msg_BnEnHn, "otaapxxxxxxxxxxpysreensffffsffffsffffsffffsffffsffffsffffsffffC" }, - { "Hn", 78, oncore_msg_BnEnHn, "" }, - { "Ab", 10, 0, "" }, - { "Ac", 11, 0, "" }, - { "Ad", 11, oncore_msg_Adef, "" }, - { "Ae", 11, oncore_msg_Adef, "" }, - { "Af", 15, oncore_msg_Adef, "" }, - { "Ag", 8, oncore_msg_Ag, "" }, /* Satellite mask angle */ - { "As", 20, oncore_msg_As, "" }, - { "At", 8, oncore_msg_At, "" }, - { "Au", 12, 0, "" }, - { "Av", 8, 0, "" }, - { "Aw", 8, 0, "" }, - { "Ay", 11, oncore_msg_Ay, "" }, - { "Az", 11, oncore_msg_Az, "" }, - { "AB", 8, 0, "" }, - { "Bb", 92, 0, "" }, - { "Bd", 23, oncore_msg_Bd, "" }, - { "Bj", 8, oncore_msg_Bj, "" }, - { "Ca", 9, oncore_msg_CaFaIa, "" }, - { "Cb", 33, oncore_msg_Cb, "" }, - { "Cf", 7, oncore_msg_Cf, "" }, - { "Cg", 8, 0, "" }, - { "Ch", 9, 0, "" }, - { "Cj", 294, oncore_msg_Cj, "" }, - { "Ek", 71, 0, "" }, - { "Fa", 9, oncore_msg_CaFaIa, "" }, - { "Ga", 20, oncore_msg_Ga, "" }, - { "Gb", 17, oncore_msg_Gb, "" }, - { "Gc", 8, 0, "" }, - { "Gd", 8, 0, "" }, - { "Ge", 8, 0, "" }, - { "Gj", 21, oncore_msg_Gj, "" }, - { "Ia", 10, oncore_msg_CaFaIa, "" }, - { "Sz", 8, oncore_msg_Sz, "" }, - { {0}, 7, 0, "" } + { "Ea", 76, oncore_msg_BaEaHa, "mdyyhmsffffaaaaoooohhhhmmmmvvhhddtntimsdimsdimsdimsdimsdimsdimsdimsdsC", 0 }, + { "Ba", 68, oncore_msg_BaEaHa, "mdyyhmsffffaaaaoooohhhhmmmmvvhhddtntimsdimsdimsdimsdimsdimsdsC", 0 }, + { "Ha", 154, oncore_msg_BaEaHa, "mdyyhmsffffaaaaoooohhhhmmmmaaaaoooohhhhmmmmVVvvhhddntimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddimsiddssrrccooooTTushmvvvvvvC", 0 }, + { "Bn", 59, oncore_msg_BnEnHn, "otaapxxxxxxxxxxpysreensffffsffffsffffsffffsffffsffffC", 0 }, + { "En", 69, oncore_msg_BnEnHn, "otaapxxxxxxxxxxpysreensffffsffffsffffsffffsffffsffffsffffsffffC", 0 }, + { "Hn", 78, oncore_msg_BnEnHn, "", 0 }, + { "Ab", 10, 0, "", 0 }, + { "Ac", 11, 0, "", 0 }, + { "Ad", 11, oncore_msg_Adef, "", 0 }, + { "Ae", 11, oncore_msg_Adef, "", 0 }, + { "Af", 15, oncore_msg_Adef, "", 0 }, + { "Ag", 8, oncore_msg_Ag, "", 0 }, /* Satellite mask angle */ + { "As", 20, oncore_msg_As, "", 0 }, + { "At", 8, oncore_msg_At, "", 0 }, + { "Au", 12, 0, "", 0 }, + { "Av", 8, 0, "", 0 }, + { "Aw", 8, 0, "", 0 }, + { "Ay", 11, oncore_msg_Ay, "", 0 }, + { "Az", 11, oncore_msg_Az, "", 0 }, + { "AB", 8, 0, "", 0 }, + { "Bb", 92, 0, "", 0 }, + { "Bd", 23, oncore_msg_Bd, "", 0 }, + { "Bj", 8, oncore_msg_Bj, "", 0 }, + { "Bl", 41, oncore_msg_Bl, "", 0 }, + { "Ca", 9, oncore_msg_CaFaIa, "", 0 }, + { "Cb", 33, oncore_msg_Cb, "", 0 }, + { "Cf", 7, oncore_msg_Cf, "", 0 }, + { "Cg", 8, 0, "", 0 }, + { "Ch", 9, 0, "", 0 }, + { "Cj", 294, oncore_msg_Cj, "", 0 }, + { "Ek", 71, 0, "", 0 }, + { "Fa", 9, oncore_msg_CaFaIa, "", 0 }, + { "Ga", 20, oncore_msg_Ga, "", 0 }, + { "Gb", 17, oncore_msg_Gb, "", 0 }, + { "Gc", 8, oncore_msg_Gc, "", 0 }, + { "Gd", 8, 0, "", 0 }, + { "Ge", 8, 0, "", 0 }, + { "Gj", 21, oncore_msg_Gj, "", 0 }, + { "Ia", 10, oncore_msg_CaFaIa, "", 0 }, + { "Sz", 8, oncore_msg_Sz, "", 0 }, + { {0}, 7, 0, "", 0 } }; @@ -446,6 +511,7 @@ static u_char oncore_cmd_Bb[] = { 'B', 'b', 1 }; /* 6/8/12 Visible Satel static u_char oncore_cmd_Bd[] = { 'B', 'd', 1 }; /* 6/8/12? Almanac Status Msg. */ static u_char oncore_cmd_Be[] = { 'B', 'e', 1 }; /* 6/8/12 Request Almanac Data */ static u_char oncore_cmd_Bj[] = { 'B', 'j', 0 }; /* 6/8 Leap Second Pending */ +static u_char oncore_cmd_Bl[] = { 'B', 'l', 1 }; /* VP Satellite Broadcast Data Msg */ static u_char oncore_cmd_Bn0[] = { 'B', 'n', 0, 1, 0,10, 2, 0,0,0, 0,0,0,0,0,0,0 }; /* 6 TRAIM setup/status: msg off, traim on */ static u_char oncore_cmd_Bn[] = { 'B', 'n', 1, 1, 0,10, 2, 0,0,0, 0,0,0,0,0,0,0 }; /* 6 TRAIM setup/status: msg on, traim on */ static u_char oncore_cmd_Bnx[] = { 'B', 'n', 0, 0, 0,10, 2, 0,0,0, 0,0,0,0,0,0,0 }; /* 6 TRAIM setup/status: msg off, traim off */ @@ -465,7 +531,7 @@ static u_char oncore_cmd_Gax[] = { 'G', 'a', 0xff, 0xff, 0xff, 0xff, /* 12 0xff, 0xff, 0xff, 0xff, /* */ 0xff, 0xff, 0xff, 0xff, 0xff }; /* */ static u_char oncore_cmd_Gb[] = { 'G', 'b', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; /* 12 set Date/Time */ -static u_char oncore_cmd_Gc[] = { 'G', 'c', 1 }; /* 12 PPS Control: On Cont */ +static u_char oncore_cmd_Gc[] = { 'G', 'c', 0 }; /* 12 PPS Control: Off, On, 1+satellite,TRAIM */ static u_char oncore_cmd_Gd0[] = { 'G', 'd', 0 }; /* 12 Position Control: 3D (no hold) */ static u_char oncore_cmd_Gd1[] = { 'G', 'd', 1 }; /* 12 Position Control: 0D (3D hold) */ static u_char oncore_cmd_Gd2[] = { 'G', 'd', 2 }; /* 12 Position Control: 2D (Alt Hold) */ @@ -487,9 +553,6 @@ static u_char oncore_cmd_Ia[] = { 'I', 'a' }; /* 12 Self Test */ * Gj in UT as of 3.0, 1999 , Bj as of 1.3 */ -static char *Month[] = {"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jly", - "Aug", "Sep", "Oct", "Nov", "Dec" }; - #define DEVICE1 "/dev/oncore.serial.%d" /* name of serial device */ #define DEVICE2 "/dev/oncore.pps.%d" /* name of pps device */ @@ -531,23 +594,20 @@ oncore_start( #define STRING_LEN 32 register struct instance *instance; struct refclockproc *pp; - int fd1, fd2, num; - char device1[STRING_LEN], device2[STRING_LEN], Msg[160]; - const char *cp; + int fd1, fd2; + char device1[STRING_LEN], device2[STRING_LEN]; +#ifndef SYS_WINNT struct stat stat1, stat2; +#endif /* create instance structure for this unit */ - if (!(instance = (struct instance *) malloc(sizeof *instance))) { - perror("malloc"); - return (0); - } - memset((char *) instance, 0, sizeof *instance); + instance = emalloc(sizeof(*instance)); + memset(instance, 0, sizeof(*instance)); /* initialize miscellaneous variables */ pp = peer->procptr; - pp->unitptr = (caddr_t) instance; instance->pp = pp; instance->unit = unit; instance->peer = peer; @@ -558,32 +618,32 @@ oncore_start( instance->traim = -1; instance->traim_in = -1; instance->chan_in = -1; + instance->pps_control = -1; /* PPS control, M12 only */ + instance->pps_control_msg_seen = -1; /* Have seen response to Gc msg */ instance->model = ONCORE_UNKNOWN; instance->mode = MODE_UNKNOWN; instance->site_survey = ONCORE_SS_UNKNOWN; instance->Ag = 0xff; /* Satellite mask angle, unset by user */ instance->ant_state = ONCORE_ANTENNA_UNKNOWN; + peer->flags &= ~FLAG_PPS; /* PPS not active yet */ peer->precision = -26; peer->minpoll = 4; peer->maxpoll = 4; pp->clockdesc = "Motorola Oncore GPS Receiver"; memcpy((char *)&pp->refid, "GPS\0", (size_t) 4); - cp = "ONCORE DRIVER -- CONFIGURING"; - record_clock_stats(&(instance->peer->srcadr), cp); - + oncore_log(instance, LOG_NOTICE, "ONCORE DRIVER -- CONFIGURING"); instance->o_state = ONCORE_NO_IDEA; - cp = "state = ONCORE_NO_IDEA"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_NO_IDEA"); /* Now open files. * This is a bit complicated, a we dont want to open the same file twice * (its a problem on some OS), and device2 may not exist for the new PPS */ - (void)sprintf(device1, DEVICE1, unit); - (void)sprintf(device2, DEVICE2, unit); + (void)snprintf(device1, sizeof(device1), DEVICE1, unit); + (void)snprintf(device2, sizeof(device2), DEVICE2, unit); /* OPEN DEVICES */ /* opening different devices for fd1 and fd2 presents no problems */ @@ -594,42 +654,64 @@ oncore_start( Since things ALWAYS work if we only open the device once, we check to see if the two devices are in fact the same, then proceed to do one open or two. - */ + For use with linuxPPS we assume that the N_TTY file has been opened + and that the line discipline has been changed to N_PPS by another + program (say ppsldisc) so that the two files expected by the oncore + driver can be opened. + + Note that the linuxPPS N_PPS file is just like a N_TTY, so we can do + the stat below without error even though the file has already had its + line discipline changed by another process. + + The Windows port of ntpd arranges to return duplicate handles for + multiple opens of the same serial device, and doesn't have inodes + for serial handles, so we just open both on Windows. + */ +#ifndef SYS_WINNT if (stat(device1, &stat1)) { - sprintf(Msg, "Can't stat fd1 (%s)\n", device1); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + oncore_log_f(instance, LOG_ERR, "Can't stat fd1 (%s)", + device1); + return(0); /* exit, no file, can't start driver */ } if (stat(device2, &stat2)) { - sprintf(Msg, "Can't stat fd2 (%s)\n", device2); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + stat2.st_dev = stat2.st_ino = -2; + oncore_log_f(instance, LOG_ERR, "Can't stat fd2 (%s) %d %m", + device2, errno); } +#endif /* !SYS_WINNT */ - if (!(fd1 = refclock_open(device1, SPEED, LDISC_RAW))) { - sprintf(Msg, "Can't open fd1 (%s)\n", device1); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + fd1 = refclock_open(device1, SPEED, LDISC_RAW); + if (fd1 <= 0) { + oncore_log_f(instance, LOG_ERR, "Can't open fd1 (%s)", + device1); + return(0); /* exit, can't open file, can't start driver */ } + /* for LINUX the PPS device is the result of a line discipline. + It seems simplest to let an external program create the appropriate + /dev/pps file, and only check (carefully) for its existance here + */ + +#ifndef SYS_WINNT if ((stat1.st_dev == stat2.st_dev) && (stat1.st_ino == stat2.st_ino)) /* same device here */ fd2 = fd1; - else { /* different devices here */ - if ((fd2=open(device2, O_RDWR)) < 0) { - sprintf(Msg, "Can't open fd2 (%s)\n", device2); - record_clock_stats(&(instance->peer->srcadr), Msg); - exit(1); + else +#endif /* !SYS_WINNT */ + { /* different devices here */ + if ((fd2=tty_open(device2, O_RDWR, 0777)) < 0) { + oncore_log_f(instance, LOG_ERR, + "Can't open fd2 (%s)", device2); + return(0); /* exit, can't open PPS file, can't start driver */ } } - num = fd2; - /* open ppsapi soure */ + /* open ppsapi source */ - if (time_pps_create(num, &instance->pps_h) < 0) { - record_clock_stats(&(instance->peer->srcadr), "PPSAPI not found in kernel"); - return(0); + if (time_pps_create(fd2, &instance->pps_h) < 0) { + oncore_log(instance, LOG_ERR, "exit, PPSAPI not found in kernel"); + return(0); /* exit, don't find PPSAPI in kernel */ } /* continue initialization */ @@ -645,15 +727,17 @@ oncore_start( return(0); pp->io.clock_recv = oncore_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd1; if (!io_addclock(&pp->io)) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: io_addclock"); - (void) close(fd1); + oncore_log(instance, LOG_ERR, "can't do io_addclock"); + close(fd1); + pp->io.fd = -1; free(instance); return (0); } + pp->unitptr = instance; #ifdef ONCORE_SHMEM_STATUS /* @@ -671,12 +755,11 @@ oncore_start( */ instance->o_state = ONCORE_CHECK_ID; - cp = "state = ONCORE_CHECK_ID"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_CHECK_ID"); instance->timeout = 4; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Set Posn Fix mode (not Idle (VP)) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Set Posn Fix mode (not Idle (VP)) */ + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); instance->pollcnt = 2; return (1); @@ -697,21 +780,24 @@ oncore_shutdown( struct refclockproc *pp; pp = peer->procptr; - instance = (struct instance *) pp->unitptr; + instance = pp->unitptr; - io_closeclock(&pp->io); + if (pp->io.fd != -1) + io_closeclock(&pp->io); - time_pps_destroy (instance->pps_h); + if (instance != NULL) { + time_pps_destroy (instance->pps_h); - close(instance->ttyfd); + close(instance->ttyfd); - if ((instance->ppsfd != -1) && (instance->ppsfd != instance->ttyfd)) - close(instance->ppsfd); + if ((instance->ppsfd != -1) && (instance->ppsfd != instance->ttyfd)) + close(instance->ppsfd); - if (instance->shmemfd) - close(instance->shmemfd); + if (instance->shmemfd) + close(instance->shmemfd); - free(instance); + free(instance); + } } @@ -728,19 +814,16 @@ oncore_poll( { struct instance *instance; - instance = (struct instance *) peer->procptr->unitptr; + instance = peer->procptr->unitptr; if (instance->timeout) { - char *cp; - instance->timeout--; if (instance->timeout == 0) { - cp = "Oncore: No response from @@Cj, shutting down driver"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_ERR, + "Oncore: No response from @@Cj, shutting down driver"); oncore_shutdown(unit, peer); } else { - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); - cp = "Oncore: Resend @@Cj"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_log(instance, LOG_WARNING, "Oncore: Resend @@Cj"); } return; } @@ -765,15 +848,15 @@ oncore_ppsapi( ) { int cap, mode, mode1; - char *cp, Msg[160]; + const char *cp; if (time_pps_getcap(instance->pps_h, &cap) < 0) { - msyslog(LOG_ERR, "time_pps_getcap failed: %m"); + oncore_log_f(instance, LOG_ERR, "time_pps_getcap failed: %m"); return (0); } if (time_pps_getparams(instance->pps_h, &instance->pps_p) < 0) { - msyslog(LOG_ERR, "time_pps_getparams failed: %m"); + oncore_log_f(instance, LOG_ERR, "time_pps_getparams failed: %m"); return (0); } @@ -782,26 +865,27 @@ oncore_ppsapi( */ if (instance->assert) { - cp = "Assert."; + cp = "Assert"; mode = PPS_CAPTUREASSERT; mode1 = PPS_OFFSETASSERT; } else { - cp = "Clear."; + cp = "Clear"; mode = PPS_CAPTURECLEAR; mode1 = PPS_OFFSETCLEAR; } - sprintf(Msg, "Initializing timeing to %s.", cp); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, "Initializing timing to %s.", + cp); if (!(mode & cap)) { - sprintf(Msg, "Can't set timeing to %s, exiting...", cp); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_ERR, + "Can't set timing to %s, exiting...", cp); return(0); } if (!(mode1 & cap)) { - sprintf(Msg, "Can't set PPS_%sCLEAR, this will increase jitter.", cp); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "Can't set %s, this will increase jitter.", + cp); mode1 = 0; } @@ -810,8 +894,8 @@ oncore_ppsapi( instance->pps_p.mode = (mode | mode1 | PPS_TSFMT_TSPEC) & cap; if (time_pps_setparams(instance->pps_h, &instance->pps_p) < 0) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: time_pps_setparams fails"); - exit(1); + oncore_log_f(instance, LOG_ERR, "ONCORE: time_pps_setparams fails %m"); + return(0); /* exit, can't do time_pps_setparans on PPS file */ } /* If HARDPPS is on, we tell kernel */ @@ -819,7 +903,7 @@ oncore_ppsapi( if (instance->hardpps) { int i; - record_clock_stats(&(instance->peer->srcadr), "HARDPPS Set."); + oncore_log(instance, LOG_INFO, "HARDPPS Set."); if (instance->assert) i = PPS_CAPTUREASSERT; @@ -830,11 +914,12 @@ oncore_ppsapi( if (time_pps_kcbind(instance->pps_h, PPS_KC_HARDPPS, i, PPS_TSFMT_TSPEC) < 0) { - msyslog(LOG_ERR, "time_pps_kcbind failed: %m"); - record_clock_stats(&(instance->peer->srcadr), "HARDPPS failed, abort..."); + oncore_log_f(instance, LOG_ERR, "time_pps_kcbind failed: %m"); + oncore_log(instance, LOG_ERR, "HARDPPS failed, abort..."); return (0); } - pps_enable = 1; + + hardpps_enable = 1; } return(1); } @@ -847,14 +932,13 @@ oncore_init_shmem( struct instance *instance ) { - int i, l, n, fd, shmem_old_size, n1; - char Msg[160]; + int l, fd; u_char *cp, *cp1, *buf, *shmem_old; struct msg_desc *mp; struct stat sbuf; - size_t shmem_length; + size_t i, n, n1, shmem_length, shmem_old_size; - /* + /* * The first thing we do is see if there is an instance->shmem_fname file (still) * out there from a previous run. If so, we copy it in and use it to initialize * shmem (so we won't lose our almanac if we need it). @@ -863,16 +947,13 @@ oncore_init_shmem( shmem_old = 0; shmem_old_size = 0; if ((fd = open(instance->shmem_fname, O_RDONLY)) < 0) - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't open SHMEM file"); + oncore_log(instance, LOG_WARNING, "ONCORE: Can't open SHMEM file"); else { fstat(fd, &sbuf); shmem_old_size = sbuf.st_size; if (shmem_old_size != 0) { - shmem_old = (u_char *) malloc((unsigned) sbuf.st_size); - if (shmem_old == NULL) - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't malloc buffer for shmem_old"); - else - read(fd, shmem_old, shmem_old_size); + shmem_old = emalloc((unsigned) sbuf.st_size); + read(fd, shmem_old, shmem_old_size); } close(fd); } @@ -880,7 +961,7 @@ oncore_init_shmem( /* OK, we now create the NEW SHMEM. */ if ((instance->shmemfd = open(instance->shmem_fname, O_RDWR|O_CREAT|O_TRUNC, 0644)) < 0) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't open shmem"); + oncore_log(instance, LOG_WARNING, "ONCORE: Can't open shmem"); if (shmem_old) free(shmem_old); @@ -913,16 +994,7 @@ oncore_init_shmem( } shmem_length = n + 2; - buf = malloc(shmem_length); - if (buf == NULL) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Can't malloc buffer for shmem"); - close(instance->shmemfd); - if (shmem_old) - free(shmem_old); - - return; - } - + buf = emalloc(shmem_length); memset(buf, 0, shmem_length); /* next build the new SHMEM buffer in memory */ @@ -977,7 +1049,7 @@ oncore_init_shmem( free(buf); if (i != shmem_length) { - record_clock_stats(&(instance->peer->srcadr), "ONCORE: error writing shmem"); + oncore_log(instance, LOG_ERR, "ONCORE: error writing shmem"); close(instance->shmemfd); return; } @@ -995,9 +1067,9 @@ oncore_init_shmem( return; } - sprintf(Msg, "SHMEM (size = %ld) is CONFIGURED and available as %s", - (u_long) shmem_length, instance->shmem_fname); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "SHMEM (size = %ld) is CONFIGURED and available as %s", + (u_long) shmem_length, instance->shmem_fname); } #endif /* ONCORE_SHMEM_STATUS */ @@ -1014,10 +1086,10 @@ oncore_read_config( { /* * First we try to open the configuration file - * /etc/oncoreN + * /etc/ntp.oncore.N * where N is the unit number viz 127.127.30.N. * If we don't find it we try - * /etc/ntp.oncore.N + * /etc/ntp.oncoreN * and then * /etc/ntp.oncore * @@ -1092,7 +1164,7 @@ oncore_read_config( * For Flag2, ASSERT=0, and hence is default. * * There is an optional line, with HARDPPS on it. Including this line causes - * the PPS signal to control the kernel PLL. + * the PPS signal to control the kernel PLL. * HARDPPS can also be set with FLAG3 of the ntp.conf input. * For Flag3, 0 is disabled, and the default. * @@ -1118,6 +1190,17 @@ oncore_read_config( * elevation angle for satellites to be tracked by the receiver. The default value * is 10 deg for the VP and 0 deg for all other receivers. * + * There is an optional line with PPSCONTROL on it (only valid for M12 or M12+T + * receivers, the option is read, but ignored for all others) + * and it is followed by: + * ON Turn PPS on. This is the default and the default for other + * oncore receivers. The PPS is on even if not tracking + * any satellites. + * SATELLITE Turns PPS on if tracking at least 1 satellite, else off. + * TRAIM Turns PPS on or off controlled by TRAIM. + * The OFF option is NOT implemented, since the Oncore driver will not work + * without the PPS signal. + * * So acceptable input would be * # these are my coordinates (RWC) * LON -106 34.610 @@ -1127,22 +1210,25 @@ oncore_read_config( */ FILE *fd; - char *cp, *cc, *ca, line[100], units[2], device[20], Msg[160], **cpp; - char *dirs[] = { "/etc/ntp", "/etc", 0 }; + char *cc, *ca, line[100], units[2], device[64]; + const char *dirs[] = { "/etc/ntp", "/etc", 0 }; + const char *cp, **cpp; int i, sign, lat_flg, long_flg, ht_flg, mode, mask; double f1, f2, f3; fd = NULL; /* just to shutup gcc complaint */ for (cpp=dirs; *cpp; cpp++) { cp = *cpp; - sprintf(device, "%s/ntp.oncore.%d", cp, instance->unit); /* try "ntp.oncore.0 */ + snprintf(device, sizeof(device), "%s/ntp.oncore.%d", + cp, instance->unit); /* try "ntp.oncore.0 */ if ((fd=fopen(device, "r"))) break; - sprintf(device, "%s/ntp.oncore%d", cp, instance->unit); /* try "ntp.oncore0" */ + snprintf(device, sizeof(device), "%s/ntp.oncore%d", + cp, instance->unit); /* try "ntp.oncore0" */ if ((fd=fopen(device, "r"))) break; - sprintf(device, "%s/ntp.oncore", cp); /* and finally "ntp.oncore" */ - if ((fd=fopen(device, "r"))) + snprintf(device, sizeof(device), "%s/ntp.oncore", cp); + if ((fd=fopen(device, "r"))) /* last try "ntp.oncore" */ break; } @@ -1154,19 +1240,20 @@ oncore_read_config( mode = mask = 0; lat_flg = long_flg = ht_flg = 0; while (fgets(line, 100, fd)) { + char *cpw; /* Remove comments */ - if ((cp = strchr(line, '#'))) - *cp = '\0'; + if ((cpw = strchr(line, '#'))) + *cpw = '\0'; /* Remove trailing space */ for (i = strlen(line); - i > 0 && isascii((int)line[i - 1]) && isspace((int)line[i - 1]); + i > 0 && isascii((unsigned char)line[i - 1]) && isspace((unsigned char)line[i - 1]); ) line[--i] = '\0'; /* Remove leading space */ - for (cc = line; *cc && isascii((int)*cc) && isspace((int)*cc); cc++) + for (cc = line; *cc && isascii((unsigned char)*cc) && isspace((unsigned char)*cc); cc++) continue; /* Stop if nothing left */ @@ -1175,29 +1262,27 @@ oncore_read_config( /* Uppercase the command and find the arg */ for (ca = cc; *ca; ca++) { - if (isascii((int)*ca)) { - if (islower((int)*ca)) { - *ca = toupper(*ca); - } else if (isspace((int)*ca) || (*ca == '=')) + if (isascii((unsigned char)*ca)) { + if (islower((unsigned char)*ca)) { + *ca = toupper((unsigned char)*ca); + } else if (isspace((unsigned char)*ca) || (*ca == '=')) break; } } /* Remove space (and possible =) leading the arg */ - for (; *ca && isascii((int)*ca) && (isspace((int)*ca) || (*ca == '=')); ca++) + for (; *ca && isascii((unsigned char)*ca) && (isspace((unsigned char)*ca) || (*ca == '=')); ca++) continue; if (!strncmp(cc, "STATUS", (size_t) 6) || !strncmp(cc, "SHMEM", (size_t) 5)) { - i = strlen(ca); - instance->shmem_fname = (char *) malloc((unsigned) (i+1)); - strcpy(instance->shmem_fname, ca); + instance->shmem_fname = estrdup(ca); continue; } /* Uppercase argument as well */ - for (cp = ca; *cp; cp++) - if (isascii((int)*cp) && islower((int)*cp)) - *cp = toupper(*cp); + for (cpw = ca; *cpw; cpw++) + if (isascii((unsigned char)*cpw) && islower((unsigned char)*cpw)) + *cpw = toupper((unsigned char)*cpw); if (!strncmp(cc, "LAT", (size_t) 3)) { f1 = f2 = f3 = 0; @@ -1241,10 +1326,11 @@ oncore_read_config( f1 = 1000000000 * f1; if (f1 < 0 || f1 > 1.e9) f1 = 0; - if (f1 < 0 || f1 > 999999) { - sprintf(Msg, "PPS Cable delay of %fns out of Range, ignored", f1); - record_clock_stats(&(instance->peer->srcadr), Msg); - } else + if (f1 < 0 || f1 > 999999) + oncore_log_f(instance, LOG_WARNING, + "PPS Cable delay of %fns out of Range, ignored", + f1); + else instance->delay = f1; /* delay in ns */ } else if (!strncmp(cc, "OFFSET", (size_t) 6)) { f1 = 0; @@ -1260,10 +1346,11 @@ oncore_read_config( f1 = 1000000000 * f1; if (f1 < 0 || f1 > 1.e9) f1 = 0; - if (f1 < 0 || f1 > 999999999.) { - sprintf(Msg, "PPS Offset of %fns out of Range, ignored", f1); - record_clock_stats(&(instance->peer->srcadr), Msg); - } else + if (f1 < 0 || f1 > 999999999.) + oncore_log_f(instance, LOG_WARNING, + "PPS Offset of %fns out of Range, ignored", + f1); + else instance->offset = f1; /* offset in ns */ } else if (!strncmp(cc, "MODE", (size_t) 4)) { sscanf(ca, "%d", &mode); @@ -1291,6 +1378,18 @@ oncore_read_config( sscanf(ca, "%d", &mask); if (mask > -1 && mask < 90) instance->Ag = mask; /* Satellite mask angle */ + } else if (!strncmp(cc,"PPSCONTROL",10)) { /* pps control M12 only */ + if (!strcmp(ca,"ON") || !strcmp(ca, "CONTINUOUS")) { + instance->pps_control = 1; /* PPS always on */ + } else if (!strcmp(ca,"SATELLITE")) { + instance->pps_control = 2; /* PPS on when satellite is available */ + } else if (!strcmp(ca,"TRAIM")) { + instance->pps_control = 3; /* PPS on when TRAIM status is OK */ + } else { + oncore_log_f(instance, LOG_WARNING, + "Unknown value \"%s\" for PPSCONTROL, ignored", + cc); + } } } fclose(fd); @@ -1302,18 +1401,19 @@ oncore_read_config( instance->posn_set = 1; if (!( lat_flg && long_flg && ht_flg )) { - printf("ONCORE: incomplete data on %s\n", device); + oncore_log_f(instance, LOG_WARNING, + "ONCORE: incomplete data on %s", device); instance->posn_set = 0; if (mode == 1 || mode == 3) { - sprintf(Msg, "Input Mode = %d, but no/incomplete position, mode set to %d", mode, mode+1); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_WARNING, + "Input Mode = %d, but no/incomplete position, mode set to %d", + mode, mode+1); mode++; } } instance->init_type = mode; - sprintf(Msg, "Input mode = %d", mode); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, "Input mode = %d", mode); } @@ -1332,21 +1432,31 @@ oncore_receive( struct peer *peer; struct instance *instance; - peer = (struct peer *)rbufp->recv_srcclock; - instance = (struct instance *) peer->procptr->unitptr; + peer = rbufp->recv_peer; + instance = peer->procptr->unitptr; p = (u_char *) &rbufp->recv_space; -#if 0 +#ifdef ONCORE_VERBOSE_RECEIVE if (debug > 4) { int i; - printf("ONCORE: >>>"); - for(i=0; irecv_length; i++) - printf("%02x ", p[i]); - printf("\n"); - printf("ONCORE: >>>"); - for(i=0; irecv_length; i++) - printf("%03o ", p[i]); - printf("\n"); + char Msg[120], Msg2[10]; + + oncore_log_f(instance, LOG_DEBUG, + ">>> %d bytes available", + rbufp->recv_length); + strlcpy(Msg, ">>>", sizeof(Msg)); + for (i = 0; i < rbufp->recv_length; i++) { + snprintf(Msg2, sizeof(Msg2), "%02x ", p[i]); + strlcat(Msg, Msg2, sizeof(Msg)); + } + oncore_log(instance, LOG_DEBUG, Msg); + + strlcpy(Msg, ">>>", sizeof(Msg)); + for (i = 0; i < rbufp->recv_length; i++) { + snprintf(Msg2, sizeof(Msg2), "%03o ", p[i]); + strlcat(Msg, Msg2, sizeof(Msg)); + } + oncore_log(instance, LOG_DEBUG, Msg); } #endif @@ -1369,8 +1479,7 @@ oncore_consume( struct instance *instance ) { - int i, m; - unsigned l; + unsigned i, m, l; while (rcvptr >= 7) { if (rcvbuf[0] != '@' || rcvbuf[1] != '@') { @@ -1378,9 +1487,11 @@ oncore_consume( for (i=1; i < rcvptr-1; i++) if (rcvbuf[i] == '@' && rcvbuf[i+1] == '@') break; -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_CONSUME if (debug > 4) - printf("ONCORE[%d]: >>> skipping %d chars\n", instance->unit, i); + oncore_log_f(instance, LOG_DEBUG, + ">>> skipping %d chars", + i); #endif if (i != rcvptr) memcpy(rcvbuf, rcvbuf+i, (size_t)(rcvptr-i)); @@ -1394,9 +1505,11 @@ oncore_consume( if (!strncmp(oncore_messages[m].flag, (char *)(rcvbuf+2), (size_t) 2)) break; if (m == l) { -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_CONSUME if (debug > 4) - printf("ONCORE[%d]: >>> Unknown MSG, skipping 4 (%c%c)\n", instance->unit, rcvbuf[2], rcvbuf[3]); + oncore_log_f(instance, LOG_DEBUG, + ">>> Unknown MSG, skipping 4 (%c%c)", + rcvbuf[2], rcvbuf[3]); #endif memcpy(rcvbuf, rcvbuf+4, (size_t) 4); rcvptr -= 4; @@ -1404,9 +1517,12 @@ oncore_consume( } l = oncore_messages[m].len; -#if 0 +#ifdef ONCORE_VERBOSE_CONSUME if (debug > 3) - printf("ONCORE[%d]: GOT: %c%c %d of %d entry %d\n", instance->unit, rcvbuf[2], rcvbuf[3], rcvptr, l, m); + oncore_log_f(instance, LOG_DEBUG, + "GOT: %c%c %d of %d entry %d", + instance->unit, rcvbuf[2], + rcvbuf[3], rcvptr, l, m); #endif /* Got the entire message ? */ @@ -1416,9 +1532,9 @@ oncore_consume( /* are we at the end of message? should be */ if (rcvbuf[l-2] != '\r' || rcvbuf[l-1] != '\n') { -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_CONSUME if (debug) - printf("ONCORE[%d]: NO at end of message\n", instance->unit); + oncore_log(instance, LOG_DEBUG, "NO at end of message"); #endif } else { /* check the CheckSum */ if (oncore_checksum_ok(rcvbuf, l)) { @@ -1431,13 +1547,18 @@ oncore_consume( if (oncore_messages[m].handler) oncore_messages[m].handler(instance, rcvbuf, (size_t) (l-3)); } -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_CONSUME else if (debug) { - printf("ONCORE[%d]: Checksum mismatch!\n", instance->unit); - printf("ONCORE[%d]: @@%c%c ", instance->unit, rcvbuf[2], rcvbuf[3]); - for (i=4; ipeer; #if 1 /* If we are in SiteSurvey mode, then we are in 3D mode, and we fall thru. @@ -1479,18 +1603,22 @@ oncore_get_timestamp( * This gives good time, which gets better when the SS is done. */ - if ((instance->site_survey == ONCORE_SS_DONE) && (instance->mode != MODE_0D)) + if ((instance->site_survey == ONCORE_SS_DONE) && (instance->mode != MODE_0D)) { #else /* old check, only fall thru for SS_DONE and 0D mode, 2h45m wait for ticks */ - if ((instance->site_survey != ONCORE_SS_DONE) || (instance->mode != MODE_0D)) + if ((instance->site_survey != ONCORE_SS_DONE) || (instance->mode != MODE_0D)) { #endif + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; + } /* Don't do anything without an almanac to define the GPS->UTC delta */ - if (instance->rsm.bad_almanac) + if (instance->rsm.bad_almanac) { + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; + } /* Once the Almanac is valid, the M12+T does not produce valid UTC * immediately. @@ -1500,6 +1628,7 @@ oncore_get_timestamp( if (instance->count5) { instance->count5--; + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; } @@ -1508,51 +1637,66 @@ oncore_get_timestamp( timeout.tv_nsec = 0; if (time_pps_fetch(instance->pps_h, PPS_TSFMT_TSPEC, &pps_i, &timeout) < 0) { - printf("ONCORE: time_pps_fetch failed\n"); + oncore_log_f(instance, LOG_ERR, + "time_pps_fetch failed %m"); + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; } if (instance->assert) { tsp = &pps_i.assert_timestamp; -#ifdef DEBUG +#ifdef ONCORE_VERBOSE_GET_TIMESTAMP if (debug > 2) { + u_long i; + i = (u_long) pps_i.assert_sequence; # ifdef HAVE_STRUCT_TIMESPEC - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%09ld\n", - instance->unit, i, j, - (long)tsp->tv_sec, (long)tsp->tv_nsec); + oncore_log_f(instance, LOG_DEBUG, + "serial/j (%lu, %lu) %ld.%09ld", i, + j, (long)tsp->tv_sec, + (long)tsp->tv_nsec); # else - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%06ld\n", - instance->unit, i, j, - (long)tsp->tv_sec, (long)tsp->tv_usec); + oncore_log_f(instance, LOG_DEBUG, + "serial/j (%lu, %lu) %ld.%06ld", i, + j, (long)tsp->tv_sec, + (long)tsp->tv_usec); # endif } #endif if (pps_i.assert_sequence == j) { - printf("ONCORE: oncore_get_timestamp, error serial pps\n"); + oncore_log(instance, LOG_NOTICE, "ONCORE: oncore_get_timestamp, error serial pps"); + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; } + instance->ev_serial = pps_i.assert_sequence; } else { tsp = &pps_i.clear_timestamp; -#ifdef DEBUG +#if 0 if (debug > 2) { + u_long i; + i = (u_long) pps_i.clear_sequence; # ifdef HAVE_STRUCT_TIMESPEC - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%09ld\n", - instance->unit, i, j, (long)tsp->tv_sec, (long)tsp->tv_nsec); + oncore_log_f(instance, LOG_DEBUG, + "serial/j (%lu, %lu) %ld.%09ld", i, + j, (long)tsp->tv_sec, + (long)tsp->tv_nsec); # else - printf("ONCORE[%d]: serial/j (%lu, %lu) %ld.%06ld\n", - instance->unit, i, j, (long)tsp->tv_sec, (long)tsp->tv_usec); + oncore_log_f(instance, LOG_DEBUG, + "serial/j (%lu, %lu) %ld.%06ld", i, + j, (long)tsp->tv_sec, + (long)tsp->tv_usec); # endif } #endif if (pps_i.clear_sequence == j) { - printf("ONCORE: oncore_get_timestamp, error serial pps\n"); + oncore_log(instance, LOG_ERR, "oncore_get_timestamp, error serial pps"); + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; } instance->ev_serial = pps_i.clear_sequence; @@ -1611,12 +1755,16 @@ oncore_get_timestamp( */ if (time_pps_getcap(instance->pps_h, ¤t_mode) < 0) { - msyslog(LOG_ERR, "time_pps_getcap failed: %m"); + oncore_log_f(instance, LOG_ERR, + "time_pps_getcap failed: %m"); + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; } if (time_pps_getparams(instance->pps_h, ¤t_params) < 0) { - msyslog(LOG_ERR, "time_pps_getparams failed: %m"); + oncore_log_f(instance, LOG_ERR, + "time_pps_getparams failed: %m"); + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; } @@ -1631,7 +1779,7 @@ oncore_get_timestamp( current_params.clear_offset.tv_nsec = -dt2; if (time_pps_setparams(instance->pps_h, ¤t_params)) - record_clock_stats(&(instance->peer->srcadr), "ONCORE: Error doing time_pps_setparams"); + oncore_log(instance, LOG_ERR, "ONCORE: Error doing time_pps_setparams"); /* have time from UNIX origin, convert to NTP origin. */ @@ -1656,17 +1804,22 @@ oncore_get_timestamp( if (instance->chan == 6 || instance->chan == 8) { char f1[5], f2[5], f3[5], f4[5]; if (instance->traim) { - sprintf(f1, "%d", instance->BEHn[21]); - sprintf(f2, "%d", instance->BEHn[22]); - sprintf(f3, "%2d", instance->BEHn[23]*256+instance->BEHn[24]); - sprintf(f4, "%3d", (s_char) instance->BEHn[25]); + snprintf(f1, sizeof(f1), "%d", + instance->BEHn[21]); + snprintf(f2, sizeof(f2), "%d", + instance->BEHn[22]); + snprintf(f3, sizeof(f3), "%2d", + instance->BEHn[23] * 256 + + instance->BEHn[24]); + snprintf(f4, sizeof(f4), "%3d", + (s_char)instance->BEHn[25]); } else { - strcpy(f1, "x"); - strcpy(f2, "x"); - strcpy(f3, "xx"); - strcpy(f4, "xxx"); + strlcpy(f1, "x", sizeof(f1)); + strlcpy(f2, "x", sizeof(f2)); + strlcpy(f3, "xx", sizeof(f3)); + strlcpy(f4, "xxx", sizeof(f4)); } - sprintf(instance->pp->a_lastcode, /* MAX length 128, currently at 121 */ + snprintf(Msg, sizeof(Msg), /* MAX length 128, currently at 127 */ "%u.%09lu %d %d %2d %2d %2d %2ld rstat %02x dop %4.1f nsat %2d,%d traim %d,%s,%s sigma %s neg-sawtooth %s sat %d%d%d%d%d%d%d%d", ts.l_ui, j, instance->pp->year, instance->pp->day, @@ -1684,17 +1837,22 @@ oncore_get_timestamp( } else if (instance->chan == 12) { char f1[5], f2[5], f3[5], f4[5]; if (instance->traim) { - sprintf(f1, "%d", instance->BEHn[6]); - sprintf(f2, "%d", instance->BEHn[7]); - sprintf(f3, "%d", instance->BEHn[12]*256+instance->BEHn[13]); - sprintf(f4, "%3d", (s_char) instance->BEHn[14]); + snprintf(f1, sizeof(f1), "%d", + instance->BEHn[6]); + snprintf(f2, sizeof(f2), "%d", + instance->BEHn[7]); + snprintf(f3, sizeof(f3), "%d", + instance->BEHn[12] * 256 + + instance->BEHn[13]); + snprintf(f4, sizeof(f4), "%3d", + (s_char)instance->BEHn[14]); } else { - strcpy(f1, "x"); - strcpy(f2, "x"); - strcpy(f3, "x"); - strcpy(f4, "xxx"); + strlcpy(f1, "x", sizeof(f1)); + strlcpy(f2, "x", sizeof(f2)); + strlcpy(f3, "xx", sizeof(f3)); + strlcpy(f4, "xxx", sizeof(f4)); } - sprintf(instance->pp->a_lastcode, + snprintf(Msg, sizeof(Msg), "%u.%09lu %d %d %2d %2d %2d %2ld rstat %02x dop %4.1f nsat %2d,%d traim %d,%s,%s sigma %s neg-sawtooth %s sat %d%d%d%d%d%d%d%d%d%d%d%d", ts.l_ui, j, instance->pp->year, instance->pp->day, @@ -1712,23 +1870,15 @@ oncore_get_timestamp( ); } -#ifdef DEBUG - if (debug > 2) { - int n; - - n = strlen(instance->pp->a_lastcode); - printf("ONCORE[%d]: len = %d %s\n", instance->unit, n, instance->pp->a_lastcode); - } -#endif - /* and some things I dont understand (magic ntp things) */ if (!refclock_process(instance->pp)) { refclock_report(instance->peer, CEVNT_BADTIME); + peer->flags &= ~FLAG_PPS; /* problem - clear PPS FLAG */ return; } - record_clock_stats(&(instance->peer->srcadr), instance->pp->a_lastcode); + oncore_log(instance, LOG_INFO, Msg); /* this is long message above */ instance->pollcnt = 2; if (instance->polled) { @@ -1737,6 +1887,7 @@ oncore_get_timestamp( instance->pp->lastref = instance->pp->lastrec; refclock_receive(instance->peer); } + peer->flags |= FLAG_PPS; } @@ -1755,15 +1906,18 @@ oncore_msg_any( int idx ) { +#ifdef ONCORE_VERBOSE_MSG_ANY int i; const char *fmt = oncore_messages[idx].fmt; const char *p; + char *q; + char *qlim; #ifdef HAVE_GETCLOCK struct timespec ts; #endif struct timeval tv; + char Msg[120], Msg2[10]; -#ifdef DEBUG if (debug > 3) { # ifdef HAVE_GETCLOCK (void) getclock(TIMEOFDAY, &ts); @@ -1772,26 +1926,36 @@ oncore_msg_any( # else GETTIMEOFDAY(&tv, 0); # endif - printf("ONCORE[%d]: %ld.%06ld\n", instance->unit, (long) tv.tv_sec, (long) tv.tv_usec); + oncore_log(instance, LOG_DEBUG, "%ld.%06ld", + (long)tv.tv_sec, (long)tv.tv_usec); if (!*fmt) { - printf(">>@@%c%c ", buf[2], buf[3]); - for(i=2; i < len && i < 2400 ; i++) - printf("%02x", buf[i]); - printf("\n"); + snprintf(Msg, sizeof(Msg), ">>@@%c%c ", buf[2], + buf[3]); + for(i = 2; i < len && i < 2400 ; i++) { + snprintf(Msg2, sizeof(Msg2), "%02x", + buf[i]); + strlcat(Msg, Msg2, sizeof(Msg)); + } + oncore_log(instance, LOG_DEBUG, Msg); return; } else { - printf("##"); - for (p = fmt; *p; p++) { - putchar(*p); - putchar('_'); + strlcpy(Msg, "##", sizeof(Msg)); + qlim = Msg + sizeof(Msg) - 3; + for (p = fmt, q = Msg + 2; q < qlim && *p; ) { + *q++ = *p++; + *q++ = '_'; } - printf("\n%c%c", buf[2], buf[3]); + *q = '\0'; + oncore_log(instance, LOG_DEBUG, Msg); + snprintf(Msg, sizeof(Msg), "%c%c", buf[2], + buf[3]); i = 4; for (p = fmt; *p; p++) { - printf("%02x", buf[i++]); + snprintf(Msg2, "%02x", buf[i++]); + strlcat(Msg, Msg2, sizeof(Msg)); } - printf("\n"); + oncore_log(instance, LOG_DEBUG, Msg); } } #endif @@ -1820,15 +1984,17 @@ oncore_msg_Ag( u_char *buf, size_t len ) -{ char Msg[160], *cp; +{ + const char *cp; - cp = "set to"; - if (instance->o_state == ONCORE_RUN) - cp = "is"; + cp = "set to"; + if (instance->o_state == ONCORE_RUN) + cp = "is"; - instance->Ag = buf[4]; - sprintf(Msg, "Satellite mask angle %s %d degrees", cp, (int) instance->Ag); - record_clock_stats(&(instance->peer->srcadr), Msg); + instance->Ag = buf[4]; + oncore_log_f(instance, LOG_INFO, + "Satellite mask angle %s %d degrees", cp, + (int)instance->Ag); } @@ -1866,16 +2032,13 @@ oncore_msg_At( size_t len ) { - char *cp; - instance->saw_At = 1; if (instance->site_survey == ONCORE_SS_TESTING) { if (buf[4] == 2) { - record_clock_stats(&(instance->peer->srcadr), + oncore_log(instance, LOG_NOTICE, "Initiating hardware 3D site survey"); - cp = "SSstate = ONCORE_SS_HW"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_HW"); instance->site_survey = ONCORE_SS_HW; } } @@ -1895,8 +2058,6 @@ oncore_msg_Ay( size_t len ) { - char Msg[120]; - if (instance->saw_Ay) return; @@ -1904,8 +2065,8 @@ oncore_msg_Ay( instance->offset = buf_w32(&buf[4]); - sprintf(Msg, "PPS Offset is set to %ld ns", instance->offset); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, "PPS Offset is set to %ld ns", + instance->offset); } @@ -1921,8 +2082,6 @@ oncore_msg_Az( size_t len ) { - char Msg[120]; - if (instance->saw_Az) return; @@ -1930,8 +2089,8 @@ oncore_msg_Az( instance->delay = buf_w32(&buf[4]); - sprintf(Msg, "Cable delay is set to %ld ns", instance->delay); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, "Cable delay is set to %ld ns", + instance->delay); } @@ -1946,7 +2105,6 @@ oncore_msg_BaEaHa( ) { const char *cp; - char Msg[160]; int mode; /* OK, we are close to the RUN state now. @@ -1977,21 +2135,20 @@ oncore_msg_BaEaHa( else /* set from test */ instance->chan = instance->chan_ck; - sprintf(Msg, "Input says chan = %d", instance->chan_in); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Model # says chan = %d", instance->chan_id); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Testing says chan = %d", instance->chan_ck); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Using chan = %d", instance->chan); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, "Input says chan = %d", + instance->chan_in); + oncore_log_f(instance, LOG_INFO, "Model # says chan = %d", + instance->chan_id); + oncore_log_f(instance, LOG_INFO, "Testing says chan = %d", + instance->chan_ck); + oncore_log_f(instance, LOG_INFO, "Using chan = %d", + instance->chan); instance->o_state = ONCORE_HAVE_CHAN; - cp = "state = ONCORE_HAVE_CHAN"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_HAVE_CHAN"); instance->timeout = 4; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); return; } @@ -2008,6 +2165,15 @@ oncore_msg_BaEaHa( memcpy(instance->BEHa, buf, (size_t) (len+3)); /* Ba, Ea or Ha */ + /* check if we saw a response to Gc (M12 or M12+T */ + + if (instance->pps_control_msg_seen != -2) { + if ((instance->pps_control_msg_seen == -1) && (instance->pps_control != -1)) { + oncore_log(instance, LOG_INFO, "PPSCONTROL set, but not implemented (not M12)"); + } + instance->pps_control_msg_seen = -2; + } + /* check the antenna (did it get unplugged) and almanac (is it ready) for changes. */ oncore_check_almanac(instance); @@ -2030,9 +2196,9 @@ oncore_msg_BaEaHa( /* if not, message out */ if (instance->chan != 12 && !instance->saw_At) { - cp = "Not Good, no @@At command (no Position Hold), must be a GT/GT+"; - record_clock_stats(&(instance->peer->srcadr), cp); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); + oncore_log(instance, LOG_NOTICE, + "Not Good, no @@At command (no Position Hold), must be a GT/GT+"); + oncore_sendmsg(instance, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); } /* have an Almanac, can start the SiteSurvey @@ -2046,35 +2212,33 @@ oncore_msg_BaEaHa( case 1: /* Use given Position */ case 3: instance->site_survey = ONCORE_SS_DONE; - cp = "SSstate = ONCORE_SS_DONE"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_DONE"); break; case 2: case 4: /* Site Survey */ - cp = "SSstate = ONCORE_SS_TESTING"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_TESTING"); instance->site_survey = ONCORE_SS_TESTING; instance->count1 = 1; if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd3, sizeof(oncore_cmd_Gd3)); /* M12+T */ + oncore_sendmsg(instance, oncore_cmd_Gd3, sizeof(oncore_cmd_Gd3)); /* M12+T */ else - oncore_sendmsg(instance->ttyfd, oncore_cmd_At2, sizeof(oncore_cmd_At2)); /* not GT, arg not VP */ + oncore_sendmsg(instance, oncore_cmd_At2, sizeof(oncore_cmd_At2)); /* not GT, arg not VP */ break; } /* Read back PPS Offset for Output */ /* Nb. This will fail silently for early UT (no plus) and M12 models */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ayx, sizeof(oncore_cmd_Ayx)); + oncore_sendmsg(instance, oncore_cmd_Ayx, sizeof(oncore_cmd_Ayx)); /* Read back Cable Delay for Output */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Azx, sizeof(oncore_cmd_Azx)); + oncore_sendmsg(instance, oncore_cmd_Azx, sizeof(oncore_cmd_Azx)); /* Read back Satellite Mask Angle for Output */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Agx, sizeof(oncore_cmd_Agx)); + oncore_sendmsg(instance, oncore_cmd_Agx, sizeof(oncore_cmd_Agx)); } @@ -2091,13 +2255,13 @@ oncore_msg_BaEaHa( if (instance->count1++ > 5 || instance->BEHa[130]&0x10) { instance->count1 = 0; if (instance->BEHa[130]&0x10) { - record_clock_stats(&(instance->peer->srcadr), + oncore_log(instance, LOG_NOTICE, "Initiating hardware 3D site survey"); - record_clock_stats(&(instance->peer->srcadr), "SSstate = ONCORE_SS_HW"); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_HW"); instance->site_survey = ONCORE_SS_HW; } else { - record_clock_stats(&(instance->peer->srcadr), "SSstate = ONCORE_SS_SW"); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_SW"); instance->site_survey = ONCORE_SS_SW; } } @@ -2124,19 +2288,19 @@ oncore_msg_BaEaHa( * We will have to do it ourselves (done above) */ - sprintf(Msg, "Initiating software 3D site survey (%d samples)", - POS_HOLD_AVERAGE); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, + "Initiating software 3D site survey (%d samples)", + POS_HOLD_AVERAGE); - record_clock_stats(&(instance->peer->srcadr), "SSstate = ONCORE_SS_SW"); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_SW"); instance->site_survey = ONCORE_SS_SW; instance->ss_lat = instance->ss_long = instance->ss_ht = 0; if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* disable */ + oncore_sendmsg(instance, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* disable */ else { - oncore_sendmsg(instance->ttyfd, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* disable */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* disable */ + oncore_sendmsg(instance, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* disable */ + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* disable */ } } } @@ -2208,7 +2372,7 @@ oncore_msg_BaEaHa( instance->traim = 0; instance->traim_delay = 0; cp = "ONCORE: Did not detect TRAIM response, TRAIM = OFF"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_INFO, cp); oncore_set_traim(instance); } else @@ -2249,8 +2413,7 @@ oncore_msg_BaEaHa( /* if not, and non-zero offset, zero the offset, and send message */ if (!instance->saw_Ay && instance->offset) { - cp = "No @@Ay command, PPS OFFSET ignored"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_INFO, "No @@Ay command, PPS OFFSET ignored"); instance->offset = 0; } } @@ -2284,11 +2447,10 @@ oncore_msg_Bd( size_t len ) { - char Msg[160]; - - sprintf(Msg, "Bd: Almanac %s, week = %d, t = %d, %d SVs: %x", - ((buf[4]) ? "LOADED" : "(NONE)"), buf[5], buf[6], buf[7], w32(&buf[8]) ); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "Bd: Almanac %s, week = %d, t = %d, %d SVs: %x", + ((buf[4]) ? "LOADED" : "(NONE)"), buf[5], buf[6], + buf[7], w32(&buf[8])); } @@ -2313,6 +2475,8 @@ oncore_msg_Bj( { const char *cp; + instance->saw_Bj = 1; + switch(buf[4]) { case 1: instance->pp->leap = LEAP_ADDSECOND; @@ -2328,11 +2492,133 @@ oncore_msg_Bj( cp = "Set pp.leap to LEAP_NOWARNING"; break; } - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, cp); } +static void +oncore_msg_Bl( + struct instance *instance, + u_char *buf, + size_t len + ) +{ + int subframe, valid, page, i, j, tow; + int day_now, day_lsf; + const char *cp; + enum { + WARN_NOT_YET, + WARN_0, + WARN_PLUS, + WARN_MINUS + } warn; + + day_now = day_lsf = 0; + cp = NULL; /* keep gcc happy */ + + subframe = buf[6] & 017; + valid = (buf[6] >> 4) & 017; + page = buf[7]; + + if ((!instance->Bl.lsf_flg && !instance->Bl.wn_flg) && (subframe == 4 && page == 18 && valid == 10)) { + instance->Bl.dt_ls = buf[32]; + instance->Bl.WN_lsf = buf[33]; + instance->Bl.DN_lsf = buf[34]; + instance->Bl.dt_lsf = buf[35]; + instance->Bl.lsf_flg++; + } + if ((instance->Bl.lsf_flg && !instance->Bl.wn_flg) && (subframe == 1 && valid == 10)) { + i = (buf[7+7]<<8) + buf[7+8]; + instance->Bl.WN = i >> 6; + tow = (buf[7+4]<<16) + (buf[7+5]<<8) + buf[7+6]; + tow >>= 7; + tow = tow & 0377777; + tow <<= 2; + instance->Bl.DN = tow/57600L + 1; + instance->Bl.wn_flg++; + } + if (instance->Bl.wn_flg && instance->Bl.lsf_flg) { + instance->Bl.wn_flg = instance->Bl.lsf_flg = 0; + oncore_cmd_Bl[2] = 0; + oncore_sendmsg(instance, oncore_cmd_Bl, sizeof oncore_cmd_Bl); + oncore_cmd_Bl[2] = 1; + + i = instance->Bl.WN&01400; + instance->Bl.WN_lsf |= i; + + /* have everything I need, doit */ + + i = (instance->Bl.WN_lsf - instance->Bl.WN); + if (i < 0) + i += 1024; + day_now = instance->Bl.DN; + day_lsf = 7*i + instance->Bl.DN_lsf; + + /* ignore if in past or more than a month in future */ + + warn = WARN_NOT_YET; + if (day_lsf >= day_now && day_lsf - day_now < 32) { + /* if < 28d, doit, if 28-31, ck day-of-month < 20 (not at end of prev month) */ + if (day_lsf - day_now < 28 || instance->BEHa[5] < 20) { + i = instance->Bl.dt_lsf - instance->Bl.dt_ls; + switch (i) { + case -1: + warn = WARN_MINUS; + break; + case 0: + warn = WARN_0; + break; + case 1: + warn = WARN_PLUS; + break; + } + } + } + + switch (warn) { + case WARN_0: + case WARN_NOT_YET: + instance->peer->leap = LEAP_NOWARNING; + cp = "Set peer.leap to LEAP_NOWARNING"; + break; + case WARN_MINUS: + instance->peer->leap = LEAP_DELSECOND; + cp = "Set peer.leap to LEAP_DELSECOND"; + break; + case WARN_PLUS: + instance->peer->leap = LEAP_ADDSECOND; + cp = "Set peer.leap to LEAP_ADDSECOND"; + break; + } + oncore_log(instance, LOG_NOTICE, cp); + + i = instance->Bl.dt_lsf-instance->Bl.dt_ls; + if (i) { + j = (i >= 0) ? i : -i; /* abs(i) */ + oncore_log_f(instance, LOG_NOTICE, + "see Leap_Second (%c%d) in %d days", + ((i >= 0) ? '+' : '-'), j, + day_lsf-day_now); + } + } + +/* + * Reg only wants the following output for "deeper" driver debugging. + * See Bug 2142 and Bug 1866 + */ +#if 0 + oncore_log_f(instance, LOG_DEBUG, + "dt_ls = %d dt_lsf = %d WN = %d DN = %d WN_lsf = %d DNlsf = %d wn_flg = %d lsf_flg = %d Bl_day = %d", + instance->Bl.dt_ls, instance->Bl.dt_lsf, + instance->Bl.WN, instance->Bl.DN, + instance->Bl.WN_lsf, instance->Bl.DN_lsf, + instance->Bl.wn_flg, instance->Bl.lsf_flg, + instance->Bl.Bl_day); +#endif +} + + static void oncore_msg_BnEnHn( struct instance *instance, @@ -2341,7 +2627,6 @@ oncore_msg_BnEnHn( ) { long dt1, dt2; - char *cp; if (instance->o_state != ONCORE_RUN) return; @@ -2349,8 +2634,7 @@ oncore_msg_BnEnHn( if (instance->traim_delay) { /* flag that @@Bn/@@En/Hn returned */ instance->traim_ck = 1; instance->traim_delay = 0; - cp = "ONCORE: Detected TRAIM, TRAIM = ON"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "ONCORE: Detected TRAIM, TRAIM = ON"); oncore_set_traim(instance); } @@ -2363,8 +2647,10 @@ oncore_msg_BnEnHn( /* If Time RAIM doesn't like it, don't trust it */ if (buf[2] == 'H') { - if (instance->BEHn[6]) /* bad TRAIM */ + if (instance->BEHn[6]) { /* bad TRAIM */ + oncore_log(instance, LOG_WARNING, "BAD TRAIM"); return; + } dt1 = instance->saw_tooth + instance->offset; /* dt this time step */ instance->saw_tooth = (s_char) instance->BEHn[14]; /* update for next time Hn[14] */ @@ -2406,7 +2692,6 @@ oncore_msg_CaFaIa( size_t len ) { - char *cp; int i; if (instance->o_state == ONCORE_TEST_SENT) { @@ -2414,12 +2699,16 @@ oncore_msg_CaFaIa( instance->timeout = 0; -#ifdef DEBUG +#if ONCORE_VERBOSE_SELF_TEST if (debug > 2) { if (buf[2] == 'I') - printf("ONCORE[%d]: >>@@%ca %x %x %x\n", instance->unit, buf[2], buf[4], buf[5], buf[6]); + oncore_log_f(instance, LOG_DEBUG, + ">>@@%ca %x %x %x", buf[2], + buf[4], buf[5], buf[6]); else - printf("ONCORE[%d]: >>@@%ca %x %x\n", instance->unit, buf[2], buf[4], buf[5]); + oncore_log_f(instance, LOG_DEBUG, + ">>@@%ca %x %x", buf[2], + buf[4], buf[5]); } #endif @@ -2429,15 +2718,17 @@ oncore_msg_CaFaIa( i = buf[4] || buf[5]; if (buf[2] == 'I') i = i || buf[6]; if (i) { - if (buf[2] == 'I') { - msyslog(LOG_ERR, "ONCORE[%d]: self test failed: result %02x %02x %02x", - instance->unit, buf[4], buf[5], buf[6]); - } else { - msyslog(LOG_ERR, "ONCORE[%d]: self test failed: result %02x %02x", - instance->unit, buf[4], buf[5]); - } - cp = "ONCORE: self test failed, shutting down driver"; - record_clock_stats(&instance->peer->srcadr, cp); + if (buf[2] == 'I') + oncore_log_f(instance, LOG_ERR, + "self test failed: result %02x %02x %02x", + buf[4], buf[5], buf[6]); + else + oncore_log_f(instance, LOG_ERR, + "self test failed: result %02x %02x", + buf[4], buf[5]); + + oncore_log(instance, LOG_ERR, + "ONCORE: self test failed, shutting down driver"); refclock_report(instance->peer, CEVNT_FAULT); oncore_shutdown(instance->unit, instance->peer); @@ -2449,11 +2740,10 @@ oncore_msg_CaFaIa( oncore_antenna_report(instance, antenna); instance->o_state = ONCORE_INIT; - cp = "state = ONCORE_INIT"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_INIT"); instance->timeout = 4; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); } } @@ -2484,10 +2774,7 @@ oncore_msg_Cb( else if (buf[4] == 4 && buf[5] == 25) i = 34; else { - char *cp; - - cp = "Cb: Response is NO ALMANAC"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "Cb: Response is NO ALMANAC"); return; } @@ -2495,12 +2782,9 @@ oncore_msg_Cb( instance->shmem[instance->shmem_Cb + i + 2]++; memcpy(instance->shmem + instance->shmem_Cb + i + 3, buf, (size_t) (len + 3)); -#if 1 - { - char Msg[160]; - sprintf(Msg, "See Cb [%d,%d]", buf[4], buf[5]); - record_clock_stats(&(instance->peer->srcadr), Msg); - } +#ifdef ONCORE_VERBOSE_MSG_CB + oncore_log_f(instance, LOG_DEBUG, "See Cb [%d,%d]", buf[4], + buf[5]); #endif } @@ -2518,16 +2802,13 @@ oncore_msg_Cf( size_t len ) { - const char *cp; - if (instance->o_state == ONCORE_RESET_SENT) { - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ + oncore_sendmsg(instance, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ /* Reset set VP to IDLE */ instance->o_state = ONCORE_TEST_SENT; - cp = "state = ONCORE_TEST_SENT"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_TEST_SENT"); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); + oncore_sendmsg(instance, oncore_cmd_Cj, sizeof(oncore_cmd_Cj)); } } @@ -2556,7 +2837,6 @@ oncore_msg_Cj( ) { int mode; - char *cp; memcpy(instance->Cj, buf, len); @@ -2568,23 +2848,21 @@ oncore_msg_Cj( mode = instance->init_type; if (mode == 3 || mode == 4) { /* Cf will return here to check for TEST */ instance->o_state = ONCORE_RESET_SENT; - cp = "state = ONCORE_RESET_SENT"; - record_clock_stats(&(instance->peer->srcadr), cp); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cf, sizeof(oncore_cmd_Cf)); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_RESET_SENT"); + oncore_sendmsg(instance, oncore_cmd_Cf, sizeof(oncore_cmd_Cf)); } else { instance->o_state = ONCORE_TEST_SENT; - cp = "state = ONCORE_TEST_SENT"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_TEST_SENT"); } } if (instance->o_state == ONCORE_TEST_SENT) { if (instance->chan == 6) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ca, sizeof(oncore_cmd_Ca)); + oncore_sendmsg(instance, oncore_cmd_Ca, sizeof(oncore_cmd_Ca)); else if (instance->chan == 8) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Fa, sizeof(oncore_cmd_Fa)); + oncore_sendmsg(instance, oncore_cmd_Fa, sizeof(oncore_cmd_Fa)); else if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ia, sizeof(oncore_cmd_Ia)); + oncore_sendmsg(instance, oncore_cmd_Ia, sizeof(oncore_cmd_Ia)); } else if (instance->o_state == ONCORE_INIT) oncore_msg_Cj_init(instance, buf, len); } @@ -2610,19 +2888,20 @@ oncore_msg_Cj_id( size_t len ) { - char *cp, *cp1, *cp2, Model[21], Msg[160]; + char *cp2, Model[21]; + const char *cp, *cp1; /* Write Receiver ID message to clockstats file */ instance->Cj[294] = '\0'; - for (cp=(char *)instance->Cj; cp< (char *) &instance->Cj[294]; ) { - cp1 = strchr(cp, '\r'); - if (!cp1) - cp1 = (char *)&instance->Cj[294]; - *cp1 = '\0'; - record_clock_stats(&(instance->peer->srcadr), cp); - *cp1 = '\r'; - cp = cp1+2; + for (cp= (char *)instance->Cj; cp< (char *) &instance->Cj[294]; ) { + char *cpw = strchr(cp, '\r'); + if (!cpw) + cpw = (char *)&instance->Cj[294]; + *cpw = '\0'; + oncore_log(instance, LOG_NOTICE, cp); + *cpw = '\r'; + cp = cpw+2; } /* next, the Firmware Version and Revision numbers */ @@ -2637,7 +2916,7 @@ oncore_msg_Cj_id( ; cp1 = cp; cp2 = Model; - for (; !isspace((int)*cp) && cp-cp1 < 20; cp++, cp2++) + for (; !isspace((unsigned char)*cp) && cp-cp1 < 20; cp++, cp2++) *cp2 = *cp; *cp2 = '\0'; @@ -2681,8 +2960,9 @@ oncore_msg_Cj_id( /* use MODEL to set CHAN and TRAIM and possibly zero SHMEM */ - sprintf(Msg, "This looks like an Oncore %s with version %d.%d firmware.", cp, instance->version, instance->revision); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, + "This looks like an Oncore %s with version %d.%d firmware.", + cp, instance->version, instance->revision); instance->chan_id = 8; /* default */ if (instance->model == ONCORE_BASIC || instance->model == ONCORE_PVT6) @@ -2700,9 +2980,13 @@ oncore_msg_Cj_id( else if (instance->model == ONCORE_M12) instance->traim_id = -1; - sprintf(Msg, "Channels = %d, TRAIM = %s", instance->chan_id, - ((instance->traim_id < 0) ? "UNKNOWN" : ((instance->traim_id > 0) ? "ON" : "OFF"))); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, "Channels = %d, TRAIM = %s", + instance->chan_id, + ((instance->traim_id < 0) + ? "UNKNOWN" + : (instance->traim_id > 0) + ? "ON" + : "OFF")); } @@ -2720,8 +3004,7 @@ oncore_msg_Cj_init( size_t len ) { - char *cp, Msg[160]; - u_char Cmd[20]; + u_char Cmd[20]; int mode; @@ -2733,17 +3016,18 @@ oncore_msg_Cj_init( if (instance->chan == 12) { instance->shmem_bad_Ea = 1; - sprintf(Msg, "*** SHMEM partially enabled for ONCORE M12 s/w v%d.%d ***", instance->version, instance->revision); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "*** SHMEM partially enabled for ONCORE M12 s/w v%d.%d ***", + instance->version, instance->revision); } - oncore_sendmsg(instance->ttyfd, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bb, sizeof(oncore_cmd_Bb)); /* turn on for shmem (6/8/12) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ek, sizeof(oncore_cmd_Ek)); /* turn off (VP) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Aw, sizeof(oncore_cmd_Aw)); /* UTC time (6/8/12) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_AB, sizeof(oncore_cmd_AB)); /* Appl type static (VP) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Be, sizeof(oncore_cmd_Be)); /* Tell us the Almanac for shmem (6/8/12) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bd, sizeof(oncore_cmd_Bd)); /* Tell us when Almanac changes */ + oncore_sendmsg(instance, oncore_cmd_Cg, sizeof(oncore_cmd_Cg)); /* Return to Posn Fix mode */ + oncore_sendmsg(instance, oncore_cmd_Bb, sizeof(oncore_cmd_Bb)); /* turn on for shmem (6/8/12) */ + oncore_sendmsg(instance, oncore_cmd_Ek, sizeof(oncore_cmd_Ek)); /* turn off (VP) */ + oncore_sendmsg(instance, oncore_cmd_Aw, sizeof(oncore_cmd_Aw)); /* UTC time (6/8/12) */ + oncore_sendmsg(instance, oncore_cmd_AB, sizeof(oncore_cmd_AB)); /* Appl type static (VP) */ + oncore_sendmsg(instance, oncore_cmd_Be, sizeof(oncore_cmd_Be)); /* Tell us the Almanac for shmem (6/8/12) */ + oncore_sendmsg(instance, oncore_cmd_Bd, sizeof(oncore_cmd_Bd)); /* Tell us when Almanac changes */ mode = instance->init_type; @@ -2753,31 +3037,29 @@ oncore_msg_Cj_init( */ if (instance->posn_set) { - record_clock_stats(&(instance->peer->srcadr), "Setting Posn from input data"); + oncore_log(instance, LOG_INFO, "Setting Posn from input data"); oncore_set_posn(instance); /* this should print posn indirectly thru the As cmd */ } else /* must issue an @@At here to check on 6/8 Position Hold, set_posn would have */ if (instance->chan != 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Atx, sizeof(oncore_cmd_Atx)); + oncore_sendmsg(instance, oncore_cmd_Atx, sizeof(oncore_cmd_Atx)); if (mode != 0) { /* cable delay in ns */ memcpy(Cmd, oncore_cmd_Az, (size_t) sizeof(oncore_cmd_Az)); - w32_buf(&Cmd[-2+4], instance->delay); - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Az)); /* 6,8,12 */ + w32_buf(&Cmd[-2+4], (int)instance->delay); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Az)); /* 6,8,12 */ /* PPS offset in ns */ - if (instance->offset) { - memcpy(Cmd, oncore_cmd_Ay, (size_t) sizeof(oncore_cmd_Ay)); /* some have it, some don't */ - w32_buf(&Cmd[-2+4], instance->offset); /* will check for hw response */ - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ay)); - } + memcpy(Cmd, oncore_cmd_Ay, (size_t) sizeof(oncore_cmd_Ay)); /* some have it, some don't */ + w32_buf(&Cmd[-2+4], instance->offset); /* will check for hw response */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ay)); /* Satellite mask angle */ if (instance->Ag != 0xff) { /* will have 0xff in it if not set by user */ memcpy(Cmd, oncore_cmd_Ag, (size_t) sizeof(oncore_cmd_Ag)); Cmd[-2+4] = instance->Ag; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ag)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ag)); } } @@ -2789,29 +3071,30 @@ oncore_msg_Cj_init( */ if (instance->chan == 6) { /* start 6chan, kill 8,12chan commands, possibly testing VP in 6chan mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_En0, sizeof(oncore_cmd_En0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba, sizeof(oncore_cmd_Ba )); + oncore_sendmsg(instance, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); + oncore_sendmsg(instance, oncore_cmd_En0, sizeof(oncore_cmd_En0)); + oncore_sendmsg(instance, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); + oncore_sendmsg(instance, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); + oncore_sendmsg(instance, oncore_cmd_Ba, sizeof(oncore_cmd_Ba )); } else if (instance->chan == 8) { /* start 8chan, kill 6,12chan commands */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea, sizeof(oncore_cmd_Ea )); + oncore_sendmsg(instance, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); + oncore_sendmsg(instance, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); + oncore_sendmsg(instance, oncore_cmd_Ha0, sizeof(oncore_cmd_Ha0)); + oncore_sendmsg(instance, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); + oncore_sendmsg(instance, oncore_cmd_Ea, sizeof(oncore_cmd_Ea )); } else if (instance->chan == 12){ /* start 12chan, kill 6,12chan commands */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_En0, sizeof(oncore_cmd_En0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha, sizeof(oncore_cmd_Ha )); + oncore_sendmsg(instance, oncore_cmd_Ba0, sizeof(oncore_cmd_Ba0)); + oncore_sendmsg(instance, oncore_cmd_Bn0, sizeof(oncore_cmd_Bn0)); + oncore_sendmsg(instance, oncore_cmd_Ea0, sizeof(oncore_cmd_Ea0)); + oncore_sendmsg(instance, oncore_cmd_En0, sizeof(oncore_cmd_En0)); + oncore_sendmsg(instance, oncore_cmd_Ha, sizeof(oncore_cmd_Ha )); + oncore_cmd_Gc[2] = (instance->pps_control < 0) ? 1 : instance->pps_control; + oncore_sendmsg(instance, oncore_cmd_Gc, sizeof(oncore_cmd_Gc)); /* PPS off/continuous/Tracking 1+sat/TRAIM */ } instance->count = 1; instance->o_state = ONCORE_ALMANAC; - cp = "state = ONCORE_ALMANAC"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_ALMANAC"); } @@ -2825,7 +3108,6 @@ oncore_msg_Ga( size_t len ) { - char Msg[160]; long lat, lon, ht; double Lat, Lon, Ht; @@ -2842,9 +3124,9 @@ oncore_msg_Ga( Lon /= 3600000; Ht /= 100; - - sprintf(Msg, "Ga Posn Lat = %.7f, Lon = %.7f, Ht = %.2f", Lat, Lon, Ht); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "Ga Posn Lat = %.7f, Lon = %.7f, Ht = %.2f", Lat, + Lon, Ht); instance->ss_lat = lat; instance->ss_long = lon; @@ -2864,7 +3146,7 @@ oncore_msg_Gb( size_t len ) { - char Msg[160], *gmts; + const char * gmts; int mo, d, y, h, m, s, gmth, gmtm; mo = buf[4]; @@ -2879,9 +3161,27 @@ oncore_msg_Gb( gmth = buf[12]; gmtm = buf[13]; - sprintf(Msg, "Date/Time set to: %d%s%d %2d:%02d:%02d GMT (GMT offset is %s%02d:%02d)", - d, Month[mo-1], y, h, m, s, gmts, gmth, gmtm); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "Date/Time set to: %d%s%d %2d:%02d:%02d GMT (GMT offset is %s%02d:%02d)", + d, months[mo-1], y, h, m, s, gmts, gmth, gmtm); +} + + + +/* Response to PPS Control message (M12 and M12+T only ) */ + +static void +oncore_msg_Gc( + struct instance *instance, + u_char *buf, + size_t len + ) +{ + const char *tbl[] = {"OFF", "ON", "SATELLITE", "TRAIM" }; + + instance->pps_control_msg_seen = 1; + oncore_log_f(instance, LOG_INFO, "PPS Control set to %s", + tbl[buf[4]]); } @@ -2896,8 +3196,13 @@ oncore_msg_Gj( size_t len ) { + static const char * insrem[2] = { + "removed", + "inserted" + }; + int dt; - char Msg[160], *cp; + const char *cp; instance->saw_Gj = 1; /* flag, saw_Gj, dont need to try Bj in check_leap */ @@ -2905,21 +3210,32 @@ oncore_msg_Gj( dt = buf[5] - buf[4]; -#if 1 - sprintf(Msg, "ONCORE[%d]: Leap Sec Msg: %d %d %d %d %d %d %d %d %d %d", - instance->unit, - buf[4], buf[5], 256*buf[6]+buf[7], buf[8], buf[9], buf[10], - (buf[14]+256*(buf[13]+256*(buf[12]+256*buf[11]))), - buf[15], buf[16], buf[17]); - record_clock_stats(&(instance->peer->srcadr), Msg); -#endif - if (dt) { - sprintf(Msg, "ONCORE[%d]: Leap second (%d) scheduled for %d%s%d at %d:%d:%d", - instance->unit, - dt, buf[9], Month[buf[8]-1], 256*buf[6]+buf[7], - buf[15], buf[16], buf[17]); - record_clock_stats(&(instance->peer->srcadr), Msg); - } + oncore_log_f(instance, LOG_INFO, + "Leap Sec Msg: %d %d %d %d %d %d %d %d %d %d", + buf[4], buf[5], 256 * buf[6] + buf[7], buf[8], + buf[9], buf[10], + (buf[14] + 256 * + (buf[13] + 256 * (buf[12] + 256 * buf[11]))), + buf[15], buf[16], buf[17]); + + /* There seems to be eternal confusion about when a leap second + * takes place. It's the second *before* the new TAI offset + * becomes effective. But since the ONCORE receiver tells us + * just that, we would have to do some time/date calculations to + * get the actual leap second -- that is, the one that is + * deleted or inserted. + * + * Going through all this for a simple log is probably overkill, + * so for fixing bug#1050 the message output is changed to + * reflect the fact that it tells the second after the leap + * second. + */ + if (dt) + oncore_log_f(instance, LOG_NOTICE, + "Leap second %s (%d) before %04u-%02u-%02u/%02u:%02u:%02u", + insrem[(dt > 0)], dt, + 256u * buf[6] + buf[7], buf[8], buf[9], + buf[15], buf[16], buf[17]); /* Only raise warning within a month of the leap second */ @@ -2938,7 +3254,7 @@ oncore_msg_Gj( } } } - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_INFO, cp); } @@ -2952,11 +3268,8 @@ oncore_msg_Sz( size_t len ) { - const char *cp; - - cp = "Oncore: System Failure at Power On"; if (instance && instance->peer) { - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_ERR, "Oncore: System Failure at Power On"); oncore_shutdown(instance->unit, instance->peer); } } @@ -2969,7 +3282,7 @@ oncore_antenna_report( struct instance *instance, enum antenna_state new_state) { - char *cp; + const char *cp; if (instance->ant_state == new_state) return; @@ -2983,7 +3296,7 @@ oncore_antenna_report( } instance->ant_state = new_state; - record_clock_stats(&instance->peer->srcadr, cp); + oncore_log(instance, LOG_NOTICE, cp); } @@ -2993,8 +3306,6 @@ oncore_chan_test( struct instance *instance ) { - char *cp; - /* subroutine oncore_Cj_id has determined the number of channels from the * model number of the attached oncore. This is not always correct since * the oncore could have non-standard firmware. Here we check (independently) by @@ -3005,13 +3316,12 @@ oncore_chan_test( */ instance->o_state = ONCORE_CHECK_CHAN; - cp = "state = ONCORE_CHECK_CHAN"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_CHECK_CHAN"); instance->count3 = 1; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ba, sizeof(oncore_cmd_Ba)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ea, sizeof(oncore_cmd_Ea)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ha, sizeof(oncore_cmd_Ha)); + oncore_sendmsg(instance, oncore_cmd_Ba, sizeof(oncore_cmd_Ba)); + oncore_sendmsg(instance, oncore_cmd_Ea, sizeof(oncore_cmd_Ea)); + oncore_sendmsg(instance, oncore_cmd_Ha, sizeof(oncore_cmd_Ha)); } @@ -3040,20 +3350,20 @@ oncore_check_almanac( bits3 = instance->BEHa[141]; /* UTC parameters */ if (!instance->count5_set && (bits3 & 0xC0)) { - instance->count5 = 2; + instance->count5 = 4; /* was 2 [Bug 1766] */ instance->count5_set = 1; } -#if 0 -{ - char Msg[160]; - - sprintf(Msg, "ONCORE[%d]: DEBUG BITS: (%x %x), (%x %x %x), %x %x %x %x %x\n", - instance->unit, - instance->BEHa[129], instance->BEHa[130], bits1, bits2, bits3, instance->mode == MODE_0D, - instance->mode == MODE_2D, instance->mode == MODE_3D, - instance->rsm.bad_almanac, instance->rsm.bad_fix); - record_clock_stats(&(instance->peer->srcadr), Msg); -} +#ifdef ONCORE_VERBOSE_CHECK_ALMANAC + oncore_log_f(instance, LOG_DEBUG, + "DEBUG BITS: (%x %x), (%x %x %x), %x %x %x %x %x", + instance->BEHa[129], instance->BEHa[130], + bits1, bits2, bits3, + instance->mode == MODE_0D, + instance->mode == MODE_2D, + instance->mode == MODE_3D, + instance->rsm.bad_almanac, + instance->rsm.bad_fix); + } #endif } } @@ -3108,19 +3418,21 @@ oncore_check_leap_sec( struct instance *instance ) { - if (instance->Bj_day != instance->BEHa[5]) { /* do this 1/day */ + oncore_cmd_Bl[2] = 1; /* just to be sure */ + if (instance->Bj_day != instance->BEHa[5]) { /* do this 1/day */ instance->Bj_day = instance->BEHa[5]; if (instance->saw_Gj < 0) { /* -1 DONT have Gj use Bj */ if ((instance->BEHa[4] == 6) || (instance->BEHa[4] == 12)) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + oncore_sendmsg(instance, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + oncore_sendmsg(instance, oncore_cmd_Bl, sizeof(oncore_cmd_Bl)); return; } if (instance->saw_Gj == 0) /* 0 is dont know if we have Gj */ instance->count4 = 1; - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gj, sizeof(oncore_cmd_Gj)); + oncore_sendmsg(instance, oncore_cmd_Gj, sizeof(oncore_cmd_Gj)); return; } @@ -3134,8 +3446,10 @@ oncore_check_leap_sec( else if (instance->count4++ > 5) { /* delay, waiting for Gj response */ instance->saw_Gj = -1; /* didnt see it, will use Bj */ instance->count4 = 0; - if ((instance->BEHa[4] == 6) || (instance->BEHa[4] == 12)) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + if ((instance->BEHa[4] == 6) || (instance->BEHa[4] == 12)) { + oncore_sendmsg(instance, oncore_cmd_Bj, sizeof(oncore_cmd_Bj)); + oncore_sendmsg(instance, oncore_cmd_Bl, sizeof(oncore_cmd_Bl)); + } } } } @@ -3170,7 +3484,6 @@ oncore_compute_dH( ) { int GPS, MSL; - char Msg[160]; /* Here calculate dH = GPS - MSL for output message */ /* also set Altitude Hold mode if GT */ @@ -3188,10 +3501,9 @@ oncore_compute_dH( /* if MSL is not set, the calculation is meaningless */ - if (MSL) { /* not set ! */ - sprintf(Msg, "dH = (GPS - MSL) = %.2fm", instance->dH); - record_clock_stats(&(instance->peer->srcadr), Msg); - } + if (MSL) /* not set ! */ + oncore_log_f(instance, LOG_INFO, + "dH = (GPS - MSL) = %.2fm", instance->dH); } @@ -3213,44 +3525,40 @@ oncore_load_almanac( if (!instance->shmem) return; -#if 1 - for (cp=instance->shmem+4; (n = 256*(*(cp-3)) + *(cp-2)); cp+=(n+3)) { +#ifndef ONCORE_VERBOSE_LOAD_ALMANAC + for (cp = instance->shmem + 4; (n = 256 * (*(cp-3)) + *(cp-2)); + cp += (n + 3)) { if (!strncmp((char *) cp, "@@Cb", 4) && oncore_checksum_ok(cp, 33) && (*(cp+4) == 4 || *(cp+4) == 5)) { write(instance->ttyfd, cp, n); -#if 1 oncore_print_Cb(instance, cp); -#endif } } -#else -/************DEBUG************/ - for (cp=instance->shmem+4; (n = 256*(*(cp-3)) + *(cp-2)); cp+=(n+3)) { - char Msg[160]; - - sprintf(Msg, "See %c%c%c%c %d", *(cp), *(cp+1), *(cp+2), *(cp+3), *(cp+4)); - record_clock_stats(&(instance->peer->srcadr), Msg); +#else /* ONCORE_VERBOSE_LOAD_ALMANAC follows */ + for (cp = instance->shmem + 4; (n = 256 * (*(cp-3)) + *(cp-2)); + cp += (n+3)) { + oncore_log_f(instance, LOG_DEBUG, "See %c%c%c%c %d", + *(cp), *(cp+1), *(cp+2), *(cp+3), *(cp+4)); if (!strncmp(cp, "@@Cb", 4)) { oncore_print_Cb(instance, cp); if (oncore_checksum_ok(cp, 33)) { if (*(cp+4) == 4 || *(cp+4) == 5) { - record_clock_stats(&(instance->peer->srcadr), "GOOD SF"); + oncore_log(instance, LOG_DEBUG, "GOOD SF"); write(instance->ttyfd, cp, n); } else - record_clock_stats(&(instance->peer->srcadr), "BAD SF"); + oncore_log(instance, LOG_DEBUG, "BAD SF"); } else - record_clock_stats(&(instance->peer->srcadr), "BAD CHECKSUM"); + oncore_log(instance, LOG_DEBUG, "BAD CHECKSUM"); } } -/************DEBUG************/ #endif /* Must load position and time or the Almanac doesn't do us any good */ if (!instance->posn_set) { /* if we input a posn use it, else from SHMEM */ - record_clock_stats(&(instance->peer->srcadr), "Loading Posn from SHMEM"); + oncore_log(instance, LOG_NOTICE, "Loading Posn from SHMEM"); for (cp=instance->shmem+4; (n = 256*(*(cp-3)) + *(cp-2)); cp+=(n+3)) { if ((instance->chan == 6 && (!strncmp((char *) cp, "@@Ba", 4) && oncore_checksum_ok(cp, 68))) || (instance->chan == 8 && (!strncmp((char *) cp, "@@Ea", 4) && oncore_checksum_ok(cp, 76))) || @@ -3261,12 +3569,11 @@ oncore_load_almanac( ii = buf_w32(cp + 15); jj = buf_w32(cp + 19); kk = buf_w32(cp + 23); -#if 0 -{ -char Msg[160]; -sprintf(Msg, "SHMEM posn = %ld (%d, %d, %d)", (long) (cp-instance->shmem), ii, jj, kk); -record_clock_stats(&(instance->peer->srcadr), Msg); -} +#ifdef ONCORE_VERBOSE_LOAD_ALMANAC + oncore_log_f(instance, LOG_DEBUG, + "SHMEM posn = %ld (%d, %d, %d)", + (long)(cp-instance->shmem), + ii, jj, kk); #endif if (ii != 0 || jj != 0 || kk != 0) { /* phk asked for this test */ instance->ss_lat = ii; @@ -3280,15 +3587,13 @@ record_clock_stats(&(instance->peer->srcadr), Msg); /* and set time to time from Computer clock */ - gettimeofday(&tv, 0); + GETTIMEOFDAY(&tv, 0); tm = gmtime((const time_t *) &tv.tv_sec); -#if 1 - { - char Msg[160]; - sprintf(Msg, "DATE %d %d %d, %d %d %d", 1900+tm->tm_year, tm->tm_mon, tm->tm_mday, - tm->tm_hour, tm->tm_min, tm->tm_sec); - record_clock_stats(&(instance->peer->srcadr), Msg); - } + +#ifdef ONCORE_VERBOSE_LOAD_ALMANAC + oncore_log_f(instance, LOG_DEBUG, "DATE %d %d %d, %d %d %d", + 1900 + tm->tm_year, tm->tm_mon, tm->tm_mday, + tm->tm_hour, tm->tm_min, tm->tm_sec); #endif if (instance->chan == 12) { memcpy(Cmd, oncore_cmd_Gb, (size_t) sizeof(oncore_cmd_Gb)); @@ -3302,27 +3607,27 @@ record_clock_stats(&(instance->peer->srcadr), Msg); Cmd[-2+11] = 0; Cmd[-2+12] = 0; Cmd[-2+13] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Gb)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Gb)); } else { /* First set GMT offset to zero */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ab, sizeof(oncore_cmd_Ab)); + oncore_sendmsg(instance, oncore_cmd_Ab, sizeof(oncore_cmd_Ab)); memcpy(Cmd, oncore_cmd_Ac, (size_t) sizeof(oncore_cmd_Ac)); Cmd[-2+4] = tm->tm_mon + 1; Cmd[-2+5] = tm->tm_mday; Cmd[-2+6] = (1900+tm->tm_year)/256; Cmd[-2+7] = (1900+tm->tm_year)%256; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ac)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ac)); memcpy(Cmd, oncore_cmd_Aa, (size_t) sizeof(oncore_cmd_Aa)); Cmd[-2+4] = tm->tm_hour; Cmd[-2+5] = tm->tm_min; Cmd[-2+6] = tm->tm_sec; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Aa)); + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Aa)); } - record_clock_stats(&(instance->peer->srcadr), "Setting Posn and Time after Loading Almanac"); + oncore_log(instance, LOG_INFO, "Setting Posn and Time after Loading Almanac"); } @@ -3335,18 +3640,23 @@ oncore_print_Cb( u_char *cp ) { -#if 0 +#ifdef ONCORE_VERBOSE_CB int ii; - char Msg[160]; + char Msg[160], Msg2[10]; + + oncore_log_f(instance, LOG_DEBUG, "DEBUG: See: %c%c%c%c", *(cp), + *(cp+1), *(cp+2), *(cp+3)); - printf("DEBUG: See: %c%c%c%c\n", *(cp), *(cp+1), *(cp+2), *(cp+3)); - printf("DEBUG: Cb: [%d,%d]", *(cp+4), *(cp+5)); - for(ii=0; ii<33; ii++) - printf(" %d", *(cp+ii)); - printf("\n"); + snprintf(Msg, sizeof(Msg), "DEBUG: Cb: [%d,%d]", *(cp+4), + *(cp+5)); + for (ii = 0; ii < 33; ii++) { + snprintf(Msg2, sizeof(Msg2), " %d", *(cp+ii)); + strlcat(Msg, Msg2, sizeof(Msg)); + } + oncore_log(instance, LOG_DEBUG, Msg); - sprintf(Msg, "Debug: Cb: [%d,%d]", *(cp+4), *(cp+5)); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_DEBUG, "Debug: Cb: [%d,%d]", *(cp+4), + *(cp+5)); #endif } @@ -3379,12 +3689,12 @@ oncore_print_posn( struct instance *instance ) { - char Msg[120], ew, ns; + char ew, ns; double xd, xm, xs, yd, ym, ys, hm, hft; int idx, idy, is, imx, imy; long lat, lon; - record_clock_stats(&(instance->peer->srcadr), "Posn:"); + oncore_log(instance, LOG_INFO, "Posn:"); ew = 'E'; lon = instance->ss_long; if (lon < 0) { @@ -3404,8 +3714,9 @@ oncore_print_posn( xd = lat/3600000.; /* lat, lon in int msec arc, ht in cm. */ yd = lon/3600000.; - sprintf(Msg, "Lat = %c %11.7fdeg, Long = %c %11.7fdeg, Alt = %5.2fm (%5.2fft) GPS", ns, xd, ew, yd, hm, hft); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, + "Lat = %c %11.7fdeg, Long = %c %11.7fdeg, Alt = %5.2fm (%5.2fft) GPS", + ns, xd, ew, yd, hm, hft); idx = xd; idy = yd; @@ -3413,9 +3724,9 @@ oncore_print_posn( imy = lon%3600000; xm = imx/60000.; ym = imy/60000.; - sprintf(Msg, - "Lat = %c %3ddeg %7.4fm, Long = %c %3ddeg %8.5fm, Alt = %7.2fm (%7.2fft) GPS", ns, idx, xm, ew, idy, ym, hm, hft); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, + "Lat = %c %3ddeg %7.4fm, Long = %c %3ddeg %8.5fm, Alt = %7.2fm (%7.2fft) GPS", + ns, idx, xm, ew, idy, ym, hm, hft); imx = xm; imy = ym; @@ -3423,9 +3734,9 @@ oncore_print_posn( xs = is/1000.; is = lon%60000; ys = is/1000.; - sprintf(Msg, - "Lat = %c %3ddeg %2dm %5.2fs, Long = %c %3ddeg %2dm %5.2fs, Alt = %7.2fm (%7.2fft) GPS", ns, idx, imx, xs, ew, idy, imy, ys, hm, hft); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, + "Lat = %c %3ddeg %2dm %5.2fs, Long = %c %3ddeg %2dm %5.2fs, Alt = %7.2fm (%7.2fft) GPS", + ns, idx, imx, xs, ew, idy, imy, ys, hm, hft); } @@ -3436,16 +3747,20 @@ oncore_print_posn( static void oncore_sendmsg( - int fd, + struct instance *instance, u_char *ptr, size_t len ) { + int fd; u_char cs = 0; -#ifdef DEBUG - if (debug > 4) - printf("ONCORE: Send @@%c%c %d\n", ptr[0], ptr[1], (int) len); + fd = instance->ttyfd; +#ifdef ONCORE_VERBOSE_SENDMSG + if (debug > 4) { + oncore_log_f(instance, LOG_DEBUG, "ONCORE: Send @@%c%c %d", + ptr[0], ptr[1], (int)len); + } #endif write(fd, "@@", (size_t) 2); write(fd, ptr, len); @@ -3469,10 +3784,10 @@ oncore_set_posn( will get set ON in @@Ea later */ if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* (12) */ + oncore_sendmsg(instance, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* (12) */ else { - oncore_sendmsg(instance->ttyfd, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* (6/8) */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* (6/8) */ + oncore_sendmsg(instance, oncore_cmd_At0, sizeof(oncore_cmd_At0)); /* (6/8) */ + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); /* (6/8) */ } mode = instance->init_type; @@ -3483,12 +3798,12 @@ oncore_set_posn( w32_buf(&Cmd[-2+8], (int) instance->ss_long); w32_buf(&Cmd[-2+12], (int) instance->ss_ht); Cmd[-2+16] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_As)); /* posn hold 3D posn (6/8/12) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_As)); /* posn hold 3D posn (6/8/12) */ memcpy(Cmd, oncore_cmd_Au, (size_t) sizeof(oncore_cmd_Au)); w32_buf(&Cmd[-2+4], (int) instance->ss_ht); Cmd[-2+8] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Au)); /* altitude hold (6/8/12 not UT, M12T) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Au)); /* altitude hold (6/8/12 not UT, M12T) */ /* next set current position */ @@ -3498,28 +3813,28 @@ oncore_set_posn( w32_buf(&Cmd[-2+8], (int) instance->ss_long); w32_buf(&Cmd[-2+12],(int) instance->ss_ht); Cmd[-2+16] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ga)); /* 3d posn (12) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ga)); /* 3d posn (12) */ } else { memcpy(Cmd, oncore_cmd_Ad, (size_t) sizeof(oncore_cmd_Ad)); w32_buf(&Cmd[-2+4], (int) instance->ss_lat); - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ad)); /* lat (6/8) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ad)); /* lat (6/8) */ memcpy(Cmd, oncore_cmd_Ae, (size_t) sizeof(oncore_cmd_Ae)); w32_buf(&Cmd[-2+4], (int) instance->ss_long); - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Ae)); /* long (6/8) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Ae)); /* long (6/8) */ memcpy(Cmd, oncore_cmd_Af, (size_t) sizeof(oncore_cmd_Af)); w32_buf(&Cmd[-2+4], (int) instance->ss_ht); Cmd[-2+8] = 0; - oncore_sendmsg(instance->ttyfd, Cmd, sizeof(oncore_cmd_Af)); /* ht (6/8) */ + oncore_sendmsg(instance, Cmd, sizeof(oncore_cmd_Af)); /* ht (6/8) */ } /* Finally, turn on position hold */ if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); + oncore_sendmsg(instance, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); else - oncore_sendmsg(instance->ttyfd, oncore_cmd_At1, sizeof(oncore_cmd_At1)); + oncore_sendmsg(instance, oncore_cmd_At1, sizeof(oncore_cmd_At1)); } } @@ -3530,32 +3845,30 @@ oncore_set_traim( struct instance *instance ) { - char Msg[160]; - if (instance->traim_in != -1) /* set in Input */ instance->traim = instance->traim_in; else instance->traim = instance->traim_ck; - sprintf(Msg, "Input says TRAIM = %d", instance->traim_in); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Model # says TRAIM = %d", instance->traim_id); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Testing says TRAIM = %d", instance->traim_ck); - record_clock_stats(&(instance->peer->srcadr), Msg); - sprintf(Msg, "Using TRAIM = %d", instance->traim); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_INFO, "Input says TRAIM = %d", + instance->traim_in); + oncore_log_f(instance, LOG_INFO, "Model # says TRAIM = %d", + instance->traim_id); + oncore_log_f(instance, LOG_INFO, "Testing says TRAIM = %d", + instance->traim_ck); + oncore_log_f(instance, LOG_INFO, "Using TRAIM = %d", + instance->traim); if (instance->traim_ck == 1 && instance->traim == 0) { /* if it should be off, and I turned it on during testing, then turn it off again */ if (instance->chan == 6) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bnx, sizeof(oncore_cmd_Bnx)); + oncore_sendmsg(instance, oncore_cmd_Bnx, sizeof(oncore_cmd_Bnx)); else if (instance->chan == 8) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Enx, sizeof(oncore_cmd_Enx)); + oncore_sendmsg(instance, oncore_cmd_Enx, sizeof(oncore_cmd_Enx)); else /* chan == 12 */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ge0, sizeof(oncore_cmd_Ge0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); + oncore_sendmsg(instance, oncore_cmd_Ge0, sizeof(oncore_cmd_Ge0)); + oncore_sendmsg(instance, oncore_cmd_Hn0, sizeof(oncore_cmd_Hn0)); } } @@ -3574,28 +3887,28 @@ oncore_shmem_get_3D( instance->shmem_reset = 1; if (instance->chan == 12) { if (instance->shmem_Posn == 2) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd2, sizeof(oncore_cmd_Gd2)); /* 2D */ + oncore_sendmsg(instance, oncore_cmd_Gd2, sizeof(oncore_cmd_Gd2)); /* 2D */ else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* 3D */ + oncore_sendmsg(instance, oncore_cmd_Gd0, sizeof(oncore_cmd_Gd0)); /* 3D */ } else { if (instance->saw_At) { /* out of 0D -> 3D mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_At0, sizeof(oncore_cmd_At0)); + oncore_sendmsg(instance, oncore_cmd_At0, sizeof(oncore_cmd_At0)); if (instance->shmem_Posn == 2) /* 3D -> 2D mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); + oncore_sendmsg(instance, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); } else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); } } else if (instance->shmem_reset || (instance->mode != MODE_0D)) { instance->shmem_reset = 0; if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); /* 0D */ + oncore_sendmsg(instance, oncore_cmd_Gd1, sizeof(oncore_cmd_Gd1)); /* 0D */ else { if (instance->saw_At) { if (instance->mode == MODE_2D) /* 2D -> 3D or 0D mode */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); - oncore_sendmsg(instance->ttyfd, oncore_cmd_At1, sizeof(oncore_cmd_At1)); /* to 0D mode */ + oncore_sendmsg(instance, oncore_cmd_Av0, sizeof(oncore_cmd_Av0)); + oncore_sendmsg(instance, oncore_cmd_At1, sizeof(oncore_cmd_At1)); /* to 0D mode */ } else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); + oncore_sendmsg(instance, oncore_cmd_Av1, sizeof(oncore_cmd_Av1)); } } } @@ -3614,7 +3927,6 @@ oncore_ss( struct instance *instance ) { - char *cp, Msg[160]; double lat, lon, ht; @@ -3625,15 +3937,14 @@ oncore_ss( if ((instance->chan == 8 && !(instance->BEHa[37] & 0x20)) || (instance->chan == 12 && !(instance->BEHa[130] & 0x10))) { - record_clock_stats(&(instance->peer->srcadr), "Now in 0D mode"); + oncore_log(instance, LOG_INFO, "Now in 0D mode"); if (instance->chan == 12) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gax, sizeof(oncore_cmd_Gax)); + oncore_sendmsg(instance, oncore_cmd_Gax, sizeof(oncore_cmd_Gax)); else - oncore_sendmsg(instance->ttyfd, oncore_cmd_Asx, sizeof(oncore_cmd_Asx)); + oncore_sendmsg(instance, oncore_cmd_Asx, sizeof(oncore_cmd_Asx)); - cp = "SSstate = ONCORE_SS_DONE"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_DONE"); instance->site_survey = ONCORE_SS_DONE; } } else { @@ -3659,22 +3970,22 @@ oncore_ss( instance->ss_long /= POS_HOLD_AVERAGE; instance->ss_ht /= POS_HOLD_AVERAGE; - sprintf(Msg, "Surveyed posn: lat %.3f (mas) long %.3f (mas) ht %.3f (cm)", - instance->ss_lat, instance->ss_long, instance->ss_ht); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "Surveyed posn: lat %.3f (mas) long %.3f (mas) ht %.3f (cm)", + instance->ss_lat, instance->ss_long, + instance->ss_ht); lat = instance->ss_lat/3600000.; lon = instance->ss_long/3600000.; ht = instance->ss_ht/100; - sprintf(Msg, "Surveyed posn: lat %.7f (deg) long %.7f (deg) ht %.2f (m)", - lat, lon, ht); - record_clock_stats(&(instance->peer->srcadr), Msg); + oncore_log_f(instance, LOG_NOTICE, + "Surveyed posn: lat %.7f (deg) long %.7f (deg) ht %.2f (m)", + lat, lon, ht); oncore_set_posn(instance); - record_clock_stats(&(instance->peer->srcadr), "Now in 0D mode"); + oncore_log(instance, LOG_INFO, "Now in 0D mode"); - cp = "SSstate = ONCORE_SS_DONE"; - record_clock_stats(&(instance->peer->srcadr), cp); + oncore_log(instance, LOG_NOTICE, "SSstate = ONCORE_SS_DONE"); instance->site_survey = ONCORE_SS_DONE; } } @@ -3687,10 +3998,9 @@ oncore_wait_almanac( ) { if (instance->rsm.bad_almanac) { -#ifdef DEBUG - if (debug) - printf("ONCORE[%d]: waiting for almanac\n", instance->unit); -#endif + instance->counta++; + if (instance->counta%5 == 0) + oncore_log(instance, LOG_INFO, "Waiting for Almanac"); /* * If we get here (first time) then we don't have an almanac in memory. @@ -3707,26 +4017,67 @@ oncore_wait_almanac( (5sec) and wait for things to settle down */ if (instance->chan == 6) - oncore_sendmsg(instance->ttyfd, oncore_cmd_Bn, sizeof(oncore_cmd_Bn)); + oncore_sendmsg(instance, oncore_cmd_Bn, sizeof(oncore_cmd_Bn)); else if (instance->chan == 8) - oncore_sendmsg(instance->ttyfd, oncore_cmd_En, sizeof(oncore_cmd_En)); + oncore_sendmsg(instance, oncore_cmd_En, sizeof(oncore_cmd_En)); else if (instance->chan == 12) { - oncore_sendmsg(instance->ttyfd, oncore_cmd_Gc, sizeof(oncore_cmd_Gc)); /* 1PPS on, continuous */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Ge, sizeof(oncore_cmd_Ge)); /* TRAIM on */ - oncore_sendmsg(instance->ttyfd, oncore_cmd_Hn, sizeof(oncore_cmd_Hn)); /* TRAIM status 1/s */ + oncore_sendmsg(instance, oncore_cmd_Gc, sizeof(oncore_cmd_Gc)); /* 1PPS on, continuous */ + oncore_sendmsg(instance, oncore_cmd_Ge, sizeof(oncore_cmd_Ge)); /* TRAIM on */ + oncore_sendmsg(instance, oncore_cmd_Hn, sizeof(oncore_cmd_Hn)); /* TRAIM status 1/s */ } instance->traim_delay = 1; - record_clock_stats(&(instance->peer->srcadr), "Have now loaded an ALMANAC"); + oncore_log(instance, LOG_NOTICE, "Have now loaded an ALMANAC"); instance->o_state = ONCORE_RUN; - record_clock_stats(&(instance->peer->srcadr), "state = ONCORE_RUN"); + oncore_log(instance, LOG_NOTICE, "state = ONCORE_RUN"); } return(0); } +static void +oncore_log ( + struct instance *instance, + int log_level, + const char *msg + ) +{ + msyslog(log_level, "ONCORE[%d]: %s", instance->unit, msg); + mprintf_clock_stats(&instance->peer->srcadr, "ONCORE[%d]: %s", + instance->unit, msg); +} + + +static int +oncore_log_f( + struct instance * instance, + int log_level, + const char * fmt, + ... + ) +{ + va_list ap; + int rc; + char msg[512]; + + va_start(ap, fmt); + rc = mvsnprintf(msg, sizeof(msg), fmt, ap); + va_end(ap); + oncore_log(instance, log_level, msg); + +#ifdef ONCORE_VERBOSE_ONCORE_LOG + instance->max_len = max(strlen(msg), instance->max_len); + instance->max_count++; + if (instance->max_count % 100 == 0) + oncore_log_f(instance, LOG_INFO, + "Max Message Length so far is %d", + instance->max_len); +#endif + return rc; +} + #else int refclock_oncore_bs; -#endif /* REFCLOCK */ +#endif /* REFCLOCK && CLOCK_ONCORE */ diff --git a/contrib/ntp/ntpd/refclock_palisade.c b/contrib/ntp/ntpd/refclock_palisade.c index adb4659f9..921c815ce 100644 --- a/contrib/ntp/ntpd/refclock_palisade.c +++ b/contrib/ntp/ntpd/refclock_palisade.c @@ -50,13 +50,28 @@ * * Version 2.45; July 14, 1999 * + * + * + * 31/03/06: Added support for Thunderbolt GPS Disciplined Clock. + * Contact: Fernando Pablo Hauscarriaga + * E-mail: fernandoph@iar.unlp.edu.ar + * Home page: www.iar.unlp.edu.ar/~fernandoph + * Instituto Argentino de Radioastronomia + * www.iar.unlp.edu.ar + * + * 14/01/07: Conditinal compilation for Thunderbolt support no longer needed + * now we use mode 2 for decode thunderbolt packets. + * Fernando P. Hauscarriaga + * + * 30/08/09: Added support for Trimble Acutime Gold Receiver. + * Fernando P. Hauscarriaga (fernandoph@iar.unlp.edu.ar) */ #ifdef HAVE_CONFIG_H -#include "config.h" +# include "config.h" #endif -#if defined(REFCLOCK) && (defined(PALISADE) || defined(CLOCK_PALISADE)) +#if defined(REFCLOCK) && defined(CLOCK_PALISADE) #ifdef SYS_WINNT extern int async_write(int, const void *, unsigned int); @@ -72,11 +87,11 @@ const int days_of_year [12] = { #ifdef DEBUG const char * Tracking_Status[15][15] = { - { "Doing Fixes\0" }, { "Good 1SV\0" }, { "Approx. 1SV\0" }, - {"Need Time\0" }, { "Need INIT\0" }, { "PDOP too High\0" }, - { "Bad 1SV\0" }, { "0SV Usable\0" }, { "1SV Usable\0" }, - { "2SV Usable\0" }, { "3SV Usable\0" }, { "No Integrity\0" }, - { "Diff Corr\0" }, { "Overdet Clock\0" }, { "Invalid\0" } }; + { "Doing Fixes\0" }, { "Good 1SV\0" }, { "Approx. 1SV\0" }, + {"Need Time\0" }, { "Need INIT\0" }, { "PDOP too High\0" }, + { "Bad 1SV\0" }, { "0SV Usable\0" }, { "1SV Usable\0" }, + { "2SV Usable\0" }, { "3SV Usable\0" }, { "No Integrity\0" }, + { "Diff Corr\0" }, { "Overdet Clock\0" }, { "Invalid\0" } }; #endif /* @@ -92,7 +107,7 @@ struct refclock refclock_palisade = { NOFLAGS /* not used */ }; -int day_of_year P((char *dt)); +int day_of_year (char *dt); /* Extract the clock type from the mode setting */ #define CLK_TYPE(x) ((int)(((x)->ttl) & 0x7F)) @@ -100,49 +115,170 @@ int day_of_year P((char *dt)); /* Supported clock types */ #define CLK_TRIMBLE 0 /* Trimble Palisade */ #define CLK_PRAECIS 1 /* Endrun Technologies Praecis */ +#define CLK_THUNDERBOLT 2 /* Trimble Thunderbolt GPS Receiver */ +#define CLK_ACUTIME 3 /* Trimble Acutime Gold */ +#define CLK_ACUTIMEB 4 /* Trimble Actutime Gold Port B */ int praecis_msg; static void praecis_parse(struct recvbuf *rbufp, struct peer *peer); +/* These routines are for sending packets to the Thunderbolt receiver + * They are taken from Markus Prosch + */ + +#ifdef PALISADE_SENDCMD_RESURRECTED +/* + * sendcmd - Build data packet for sending + */ +static void +sendcmd ( + struct packettx *buffer, + int c + ) +{ + *buffer->data = DLE; + *(buffer->data + 1) = (unsigned char)c; + buffer->size = 2; +} +#endif /* PALISADE_SENDCMD_RESURRECTED */ + +/* + * sendsupercmd - Build super data packet for sending + */ +static void +sendsupercmd ( + struct packettx *buffer, + int c1, + int c2 + ) +{ + *buffer->data = DLE; + *(buffer->data + 1) = (unsigned char)c1; + *(buffer->data + 2) = (unsigned char)c2; + buffer->size = 3; +} + +/* + * sendbyte - + */ +static void +sendbyte ( + struct packettx *buffer, + int b + ) +{ + if (b == DLE) + *(buffer->data+buffer->size++) = DLE; + *(buffer->data+buffer->size++) = (unsigned char)b; +} + +/* + * sendint - + */ +static void +sendint ( + struct packettx *buffer, + int a + ) +{ + sendbyte(buffer, (unsigned char)((a>>8) & 0xff)); + sendbyte(buffer, (unsigned char)(a & 0xff)); +} + +/* + * sendetx - Send packet or super packet to the device + */ +static int +sendetx ( + struct packettx *buffer, + int fd + ) +{ + int result; + + *(buffer->data+buffer->size++) = DLE; + *(buffer->data+buffer->size++) = ETX; + result = write(fd, buffer->data, (unsigned long)buffer->size); + + if (result != -1) + return (result); + else + return (-1); +} + +/* + * init_thunderbolt - Prepares Thunderbolt receiver to be used with + * NTP (also taken from Markus Prosch). + */ +static void +init_thunderbolt ( + int fd + ) +{ + struct packettx tx; + + tx.size = 0; + tx.data = (u_char *) emalloc(100); + + /* set UTC time */ + sendsupercmd (&tx, 0x8E, 0xA2); + sendbyte (&tx, 0x3); + sendetx (&tx, fd); + + /* activate packets 0x8F-AB and 0x8F-AC */ + sendsupercmd (&tx, 0x8F, 0xA5); + sendint (&tx, 0x5); + sendetx (&tx, fd); + + free(tx.data); +} + +/* + * init_acutime - Prepares Acutime Receiver to be used with NTP + */ +static void +init_acutime ( + int fd + ) +{ + /* Disable all outputs, Enable Event-Polling on PortA so + we can ask for time packets */ + struct packettx tx; + + tx.size = 0; + tx.data = (u_char *) emalloc(100); + + sendsupercmd(&tx, 0x8E, 0xA5); + sendbyte(&tx, 0x02); + sendbyte(&tx, 0x00); + sendbyte(&tx, 0x00); + sendbyte(&tx, 0x00); + sendetx(&tx, fd); + + free(tx.data); +} + /* * palisade_start - open the devices and initialize data for processing */ static int palisade_start ( -#ifdef PALISADE - unit, peer - ) - int unit; - struct peer *peer; -#else /* ANSI */ int unit, struct peer *peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; int fd; char gpsdev[20]; - struct termios tio; -#ifdef SYS_WINNT - (void) sprintf(gpsdev, "COM%d:", unit); -#else - (void) sprintf(gpsdev, DEVICE, unit); -#endif + + snprintf(gpsdev, sizeof(gpsdev), DEVICE, unit); + /* * Open serial port. */ -#if defined PALISADE - fd = open(gpsdev, O_RDWR -#ifdef O_NONBLOCK - | O_NONBLOCK -#endif - ); -#else /* NTP 4.x */ fd = refclock_open(gpsdev, SPEED232, LDISC_RAW); -#endif if (fd <= 0) { #ifdef DEBUG printf("Palisade(%d) start: open %s failed\n", unit, gpsdev); @@ -153,87 +289,67 @@ palisade_start ( msyslog(LOG_NOTICE, "Palisade(%d) fd: %d dev: %s", unit, fd, gpsdev); -#if defined PALISADE - tio.c_cflag = (CS8|CLOCAL|CREAD|PARENB|PARODD); - tio.c_iflag = (IGNBRK); - tio.c_oflag = (0); - tio.c_lflag = (0); - - if (cfsetispeed(&tio, SPEED232) == -1) { - msyslog(LOG_ERR,"Palisade(%d) cfsetispeed(fd, &tio): %m",unit); -#ifdef DEBUG - printf("Palisade(%d) cfsetispeed(fd, &tio)\n",unit); -#endif - return 0; - } - if (cfsetospeed(&tio, SPEED232) == -1) { -#ifdef DEBUG - printf("Palisade(%d) cfsetospeed(fd, &tio)\n",unit); -#endif - msyslog(LOG_ERR,"Palisade(%d) cfsetospeed(fd, &tio): %m",unit); - return 0; - } -#else /* NTP 4.x */ - if (tcgetattr(fd, &tio) < 0) { - msyslog(LOG_ERR, + if (tcgetattr(fd, &tio) < 0) { + msyslog(LOG_ERR, "Palisade(%d) tcgetattr(fd, &tio): %m",unit); #ifdef DEBUG - printf("Palisade(%d) tcgetattr(fd, &tio)\n",unit); + printf("Palisade(%d) tcgetattr(fd, &tio)\n",unit); #endif - return (0); - } - - tio.c_cflag |= (PARENB|PARODD); - tio.c_iflag &= ~ICRNL; -#endif /* NTP 4.x */ + close(fd); + return (0); + } - if (tcsetattr(fd, TCSANOW, &tio) == -1) { - msyslog(LOG_ERR, "Palisade(%d) tcsetattr(fd, &tio): %m",unit); -#ifdef DEBUG - printf("Palisade(%d) tcsetattr(fd, &tio)\n",unit); -#endif - return 0; - } + tio.c_cflag |= (PARENB|PARODD); + tio.c_iflag &= ~ICRNL; /* * Allocate and initialize unit structure */ - up = (struct palisade_unit *) emalloc(sizeof(struct palisade_unit)); - - if (!(up)) { - msyslog(LOG_ERR, "Palisade(%d) emalloc: %m",unit); -#ifdef DEBUG - printf("Palisade(%d) emalloc\n",unit); -#endif - (void) close(fd); - return (0); - } - - memset((char *)up, 0, sizeof(struct palisade_unit)); + up = emalloc_zero(sizeof(*up)); up->type = CLK_TYPE(peer); switch (up->type) { - case CLK_TRIMBLE: - /* Normal mode, do nothing */ - break; - case CLK_PRAECIS: - msyslog(LOG_NOTICE, "Palisade(%d) Praecis mode enabled\n",unit); - break; - default: - msyslog(LOG_NOTICE, "Palisade(%d) mode unknown\n",unit); - break; + case CLK_TRIMBLE: + /* Normal mode, do nothing */ + break; + case CLK_PRAECIS: + msyslog(LOG_NOTICE, "Palisade(%d) Praecis mode enabled" + ,unit); + break; + case CLK_THUNDERBOLT: + msyslog(LOG_NOTICE, "Palisade(%d) Thunderbolt mode enabled" + ,unit); + tio.c_cflag = (CS8|CLOCAL|CREAD); + break; + case CLK_ACUTIME: + msyslog(LOG_NOTICE, "Palisade(%d) Acutime Gold mode enabled" + ,unit); + break; + default: + msyslog(LOG_NOTICE, "Palisade(%d) mode unknown",unit); + break; + } + if (tcsetattr(fd, TCSANOW, &tio) == -1) { + msyslog(LOG_ERR, "Palisade(%d) tcsetattr(fd, &tio): %m",unit); +#ifdef DEBUG + printf("Palisade(%d) tcsetattr(fd, &tio)\n",unit); +#endif + close(fd); + free(up); + return 0; } pp = peer->procptr; pp->io.clock_recv = palisade_io; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { #ifdef DEBUG - printf("Palisade(%d) io_addclock\n",unit); + printf("Palisade(%d) io_addclock\n",unit); #endif - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } @@ -241,7 +357,7 @@ palisade_start ( /* * Initialize miscellaneous variables */ - pp->unitptr = (caddr_t)up; + pp->unitptr = up; pp->clockdesc = DESCRIPTION; peer->precision = PRECISION; @@ -253,7 +369,12 @@ palisade_start ( up->leap_status = 0; up->unit = (short) unit; up->rpt_status = TSIP_PARSED_EMPTY; - up->rpt_cnt = 0; + up->rpt_cnt = 0; + + if (up->type == CLK_THUNDERBOLT) + init_thunderbolt(fd); + if (up->type == CLK_ACUTIME) + init_acutime(fd); return 1; } @@ -264,23 +385,18 @@ palisade_start ( */ static void palisade_shutdown ( -#ifdef PALISADE - unit, peer - ) - int unit; - struct peer *peer; -#else /* ANSI */ int unit, struct peer *peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; pp = peer->procptr; - up = (struct palisade_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -290,29 +406,23 @@ palisade_shutdown ( */ int day_of_year ( -#ifdef PALISADE - dt - ) - char * dt; -#else char * dt ) -#endif { int day, mon, year; mon = dt[1]; - /* Check month is inside array bounds */ - if ((mon < 1) || (mon > 12)) + /* Check month is inside array bounds */ + if ((mon < 1) || (mon > 12)) return -1; day = dt[0] + days_of_year[mon - 1]; year = getint((u_char *) (dt + 2)); if ( !(year % 4) && ((year % 100) || - (!(year % 100) && !(year%400))) - &&(mon > 2)) - day ++; /* leap year and March or later */ + (!(year % 100) && !(year%400))) + &&(mon > 2)) + day ++; /* leap year and March or later */ return day; } @@ -323,14 +433,8 @@ day_of_year ( */ int TSIP_decode ( -#ifdef PALISADE - peer - ) - struct peer *peer; -#else struct peer *peer ) -#endif { int st; long secint; @@ -342,7 +446,7 @@ TSIP_decode ( struct refclockproc *pp; pp = peer->procptr; - up = (struct palisade_unit *)pp->unitptr; + up = pp->unitptr; /* * Check the time packet, decode its contents. @@ -350,182 +454,436 @@ TSIP_decode ( * proper format, declare bad format and exit. */ - if ((up->rpt_buf[0] == (char) 0x41) || - (up->rpt_buf[0] == (char) 0x46) || - (up->rpt_buf[0] == (char) 0x54) || - (up->rpt_buf[0] == (char) 0x4B) || - (up->rpt_buf[0] == (char) 0x6D)) { + if ((up->type != CLK_THUNDERBOLT) & (up->type != CLK_ACUTIME)){ + if ((up->rpt_buf[0] == (char) 0x41) || + (up->rpt_buf[0] == (char) 0x46) || + (up->rpt_buf[0] == (char) 0x54) || + (up->rpt_buf[0] == (char) 0x4B) || + (up->rpt_buf[0] == (char) 0x6D)) { - /* standard time packet - GPS time and GPS week number */ + /* standard time packet - GPS time and GPS week number */ #ifdef DEBUG printf("Palisade Port B packets detected. Connect to Port A\n"); #endif - return 0; + return 0; + } } /* * We cast both to u_char to as 0x8f uses the sign bit on a char */ if ((u_char) up->rpt_buf[0] == (u_char) 0x8f) { - /* - * Superpackets - */ - event = (unsigned short) (getint((u_char *) &mb(1)) & 0xffff); - if (!((pp->sloppyclockflag & CLK_FLAG2) || event)) - /* Ignore Packet */ + /* + * Superpackets + */ + event = (unsigned short) (getint((u_char *) &mb(1)) & 0xffff); + if (!((pp->sloppyclockflag & CLK_FLAG2) || event)) + /* Ignore Packet */ return 0; - switch (mb(0) & 0xff) { - int GPS_UTC_Offset; - case PACKET_8F0B: + switch (mb(0) & 0xff) { + int GPS_UTC_Offset; + long tow; - if (up->polled <= 0) - return 0; + case PACKET_8F0B: - if (up->rpt_cnt != LENCODE_8F0B) /* check length */ - break; + if (up->polled <= 0) + return 0; + + if (up->rpt_cnt != LENCODE_8F0B) /* check length */ + break; #ifdef DEBUG -if (debug > 1) { - int ts; - double lat, lon, alt; - lat = getdbl((u_char *) &mb(42)) * R2D; - lon = getdbl((u_char *) &mb(50)) * R2D; - alt = getdbl((u_char *) &mb(58)); - - printf("TSIP_decode: unit %d: Latitude: %03.4f Longitude: %03.4f Alt: %05.2f m\n", - up->unit, lat,lon,alt); - printf("TSIP_decode: unit %d: Sats:", up->unit); - for (st = 66, ts = 0; st <= 73; st++) if (mb(st)) { - if (mb(st) > 0) ts++; - printf(" %02d", mb(st)); - } - printf(" : Tracking %d\n", ts); - } + if (debug > 1) { + int ts; + double lat, lon, alt; + lat = getdbl((u_char *) &mb(42)) * R2D; + lon = getdbl((u_char *) &mb(50)) * R2D; + alt = getdbl((u_char *) &mb(58)); + + printf("TSIP_decode: unit %d: Latitude: %03.4f Longitude: %03.4f Alt: %05.2f m\n", + up->unit, lat,lon,alt); + printf("TSIP_decode: unit %d: Sats:", + up->unit); + for (st = 66, ts = 0; st <= 73; st++) + if (mb(st)) { + if (mb(st) > 0) ts++; + printf(" %02d", mb(st)); + } + printf(" : Tracking %d\n", ts); + } #endif - GPS_UTC_Offset = getint((u_char *) &mb(16)); - if (GPS_UTC_Offset == 0) { /* Check UTC offset */ + GPS_UTC_Offset = getint((u_char *) &mb(16)); + if (GPS_UTC_Offset == 0) { /* Check UTC offset */ #ifdef DEBUG - printf("TSIP_decode: UTC Offset Unknown\n"); + printf("TSIP_decode: UTC Offset Unknown\n"); #endif - break; - } + break; + } - secs = getdbl((u_char *) &mb(3)); - secint = (long) secs; - secfrac = secs - secint; /* 0.0 <= secfrac < 1.0 */ + secs = getdbl((u_char *) &mb(3)); + secint = (long) secs; + secfrac = secs - secint; /* 0.0 <= secfrac < 1.0 */ - pp->nsec = (long) (secfrac * 1000000000); + pp->nsec = (long) (secfrac * 1000000000); - secint %= 86400; /* Only care about today */ - pp->hour = secint / 3600; - secint %= 3600; - pp->minute = secint / 60; - secint %= 60; - pp->second = secint % 60; + secint %= 86400; /* Only care about today */ + pp->hour = secint / 3600; + secint %= 3600; + pp->minute = secint / 60; + secint %= 60; + pp->second = secint % 60; - if ((pp->day = day_of_year(&mb(11))) < 0) break; + if ((pp->day = day_of_year(&mb(11))) < 0) break; - pp->year = getint((u_char *) &mb(13)); + pp->year = getint((u_char *) &mb(13)); #ifdef DEBUG - if (debug > 1) - printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d UTC %02d\n", - up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, - pp->second, pp->nsec, mb(12), mb(11), pp->year, GPS_UTC_Offset); + if (debug > 1) + printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%09ld %02d/%02d/%04d UTC %02d\n", + up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, + pp->second, pp->nsec, mb(12), mb(11), pp->year, GPS_UTC_Offset); #endif - /* Only use this packet when no - * 8F-AD's are being received - */ + /* Only use this packet when no + * 8F-AD's are being received + */ - if (up->leap_status) { - up->leap_status = 0; - return 0; - } + if (up->leap_status) { + up->leap_status = 0; + return 0; + } - return 2; - break; + return 2; + break; - case PACKET_NTP: - /* Palisade-NTP Packet */ + case PACKET_NTP: + /* Palisade-NTP Packet */ - if (up->rpt_cnt != LENCODE_NTP) /* check length */ - break; + if (up->rpt_cnt != LENCODE_NTP) /* check length */ + break; - up->leap_status = mb(19); + up->leap_status = mb(19); - if (up->polled <= 0) - return 0; + if (up->polled <= 0) + return 0; - /* Check Tracking Status */ - st = mb(18); - if (st < 0 || st > 14) st = 14; - if ((st >= 2 && st <= 7) || st == 11 || st == 12) { + /* Check Tracking Status */ + st = mb(18); + if (st < 0 || st > 14) + st = 14; + if ((st >= 2 && st <= 7) || st == 11 || st == 12) { #ifdef DEBUG - printf("TSIP_decode: Not Tracking Sats : %s\n", - *Tracking_Status[st]); + printf("TSIP_decode: Not Tracking Sats : %s\n", + *Tracking_Status[st]); #endif - refclock_report(peer, CEVNT_BADTIME); - up->polled = -1; - return 0; - break; - } + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; + return 0; + break; + } - if (up->leap_status & PALISADE_LEAP_PENDING) { - if (up->leap_status & PALISADE_UTC_TIME) - pp->leap = LEAP_ADDSECOND; - else - pp->leap = LEAP_DELSECOND; - } - else if (up->leap_status) - pp->leap = LEAP_NOWARNING; + up->month = mb(15); + if ( (up->leap_status & PALISADE_LEAP_PENDING) && + /* Avoid early announce: https://bugs.ntp.org/2773 */ + (6 == up->month || 12 == up->month) ) { + if (up->leap_status & PALISADE_UTC_TIME) + pp->leap = LEAP_ADDSECOND; + else + pp->leap = LEAP_DELSECOND; + } + else if (up->leap_status) + pp->leap = LEAP_NOWARNING; - else { /* UTC flag is not set: - * Receiver may have been reset, and lost - * its UTC almanac data */ - pp->leap = LEAP_NOTINSYNC; + else { /* UTC flag is not set: + * Receiver may have been reset, and lost + * its UTC almanac data */ + pp->leap = LEAP_NOTINSYNC; #ifdef DEBUG - printf("TSIP_decode: UTC Almanac unavailable: %d\n", - mb(19)); + printf("TSIP_decode: UTC Almanac unavailable: %d\n", + mb(19)); #endif - refclock_report(peer, CEVNT_BADTIME); - up->polled = -1; + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; + return 0; + } + + pp->nsec = (long) (getdbl((u_char *) &mb(3)) + * 1000000000); + + if ((pp->day = day_of_year(&mb(14))) < 0) + break; + pp->year = getint((u_char *) &mb(16)); + pp->hour = mb(11); + pp->minute = mb(12); + pp->second = mb(13); + up->month = mb(14); /* Save for LEAP check */ + +#ifdef DEBUG + if (debug > 1) + printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%09ld %02d/%02d/%04d UTC %02x %s\n", + up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, + pp->second, pp->nsec, mb(15), mb(14), pp->year, + mb(19), *Tracking_Status[st]); +#endif + return 1; + break; + + case PACKET_8FAC: + if (up->polled <= 0) + return 0; + + if (up->rpt_cnt != LENCODE_8FAC)/* check length */ + break; + +#ifdef DEBUG + if (debug > 1) { + double lat, lon, alt; + lat = getdbl((u_char *) &mb(36)) * R2D; + lon = getdbl((u_char *) &mb(44)) * R2D; + alt = getdbl((u_char *) &mb(52)); + + printf("TSIP_decode: unit %d: Latitude: %03.4f Longitude: %03.4f Alt: %05.2f m\n", + up->unit, lat,lon,alt); + printf("TSIP_decode: unit %d\n", up->unit); + } +#endif + if ( (getint((u_char *) &mb(10)) & 0x80) && + /* Avoid early announce: https://bugs.ntp.org/2773 */ + (6 == up->month || 12 == up->month) ) + pp->leap = LEAP_ADDSECOND; /* we ASSUME addsecond */ + else + pp->leap = LEAP_NOWARNING; + +#ifdef DEBUG + if (debug > 1) + printf("TSIP_decode: unit %d: 0x%02x leap %d\n", + up->unit, mb(0) & 0xff, pp->leap); + if (debug > 1) { + printf("Receiver MODE: 0x%02X\n", (u_char)mb(1)); + if (mb(1) == 0x00) + printf(" AUTOMATIC\n"); + if (mb(1) == 0x01) + printf(" SINGLE SATELLITE\n"); + if (mb(1) == 0x03) + printf(" HORIZONTAL(2D)\n"); + if (mb(1) == 0x04) + printf(" FULL POSITION(3D)\n"); + if (mb(1) == 0x05) + printf(" DGPR REFERENCE\n"); + if (mb(1) == 0x06) + printf(" CLOCK HOLD(2D)\n"); + if (mb(1) == 0x07) + printf(" OVERDETERMINED CLOCK\n"); + + printf("\n** Disciplining MODE 0x%02X:\n", (u_char)mb(2)); + if (mb(2) == 0x00) + printf(" NORMAL\n"); + if (mb(2) == 0x01) + printf(" POWER-UP\n"); + if (mb(2) == 0x02) + printf(" AUTO HOLDOVER\n"); + if (mb(2) == 0x03) + printf(" MANUAL HOLDOVER\n"); + if (mb(2) == 0x04) + printf(" RECOVERY\n"); + if (mb(2) == 0x06) + printf(" DISCIPLINING DISABLED\n"); + } +#endif return 0; - } + break; + + case PACKET_8FAB: + /* Thunderbolt Primary Timing Packet */ + + if (up->rpt_cnt != LENCODE_8FAB) /* check length */ + break; + + if (up->polled <= 0) + return 0; + + GPS_UTC_Offset = getint((u_char *) &mb(7)); + + if (GPS_UTC_Offset == 0){ /* Check UTC Offset */ +#ifdef DEBUG + printf("TSIP_decode: UTC Offset Unknown\n"); +#endif + break; + } - pp->nsec = (long) (getdbl((u_char *) &mb(3)) * 1000000000); - if ((pp->day = day_of_year(&mb(14))) < 0) + if ((mb(9) & 0x1d) == 0x0) { + /* if we know the GPS time and the UTC offset, + we expect UTC timing information !!! */ + + pp->leap = LEAP_NOTINSYNC; + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; + return 0; + } + + pp->nsec = 0; +#ifdef DEBUG + printf("\nTiming Flags are:\n"); + printf("Timing flag value is: 0x%X\n", mb(9)); + if ((mb(9) & 0x01) != 0) + printf (" Getting UTC time\n"); + else + printf (" Getting GPS time\n"); + if ((mb(9) & 0x02) != 0) + printf (" PPS is from UTC\n"); + else + printf (" PPS is from GPS\n"); + if ((mb(9) & 0x04) != 0) + printf (" Time is not Set\n"); + else + printf (" Time is Set\n"); + if ((mb(9) & 0x08) != 0) + printf(" I dont have UTC info\n"); + else + printf (" I have UTC info\n"); + if ((mb(9) & 0x10) != 0) + printf (" Time is from USER\n\n"); + else + printf (" Time is from GPS\n\n"); +#endif + + if ((pp->day = day_of_year(&mb(13))) < 0) + break; + tow = getlong((u_char *) &mb(1)); +#ifdef DEBUG + if (debug > 1) { + printf("pp->day: %d\n", pp->day); + printf("TOW: %ld\n", tow); + printf("DAY: %d\n", mb(13)); + } +#endif + pp->year = getint((u_char *) &mb(15)); + pp->hour = mb(12); + pp->minute = mb(11); + pp->second = mb(10); + + +#ifdef DEBUG + if (debug > 1) + printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%09ld %02d/%02d/%04d ",up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, pp->second, pp->nsec, mb(14), mb(13), pp->year); +#endif + return 1; break; - pp->year = getint((u_char *) &mb(16)); - pp->hour = mb(11); - pp->minute = mb(12); - pp->second = mb(13); + default: + /* Ignore Packet */ + return 0; + } /* switch */ + } /* if 8F packets */ + + else if (up->rpt_buf[0] == (u_char)0x42) { + printf("0x42\n"); + return 0; + } + else if (up->rpt_buf[0] == (u_char)0x43) { + printf("0x43\n"); + return 0; + } + else if ((up->rpt_buf[0] == PACKET_41) & (up->type == CLK_THUNDERBOLT)){ + printf("Undocumented 0x41 packet on Thunderbolt\n"); + return 0; + } + else if ((up->rpt_buf[0] == PACKET_41A) & (up->type == CLK_ACUTIME)) { #ifdef DEBUG - if (debug > 1) -printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d UTC %02x %s\n", - up->unit, mb(0) & 0xff, event, pp->hour, pp->minute, - pp->second, pp->nsec, mb(15), mb(14), pp->year, - mb(19), *Tracking_Status[st]); + printf("GPS TOW: %ld\n", (long)getlong((u_char *) &mb(0))); + printf("GPS WN: %d\n", getint((u_char *) &mb(4))); + printf("GPS UTC-GPS Offser: %ld\n", (long)getlong((u_char *) &mb(6))); #endif - return 1; - break; + return 0; + } - default: - /* Ignore Packet */ + /* Health Status for Acutime Receiver */ + else if ((up->rpt_buf[0] == PACKET_46) & (up->type == CLK_ACUTIME)) { +#ifdef DEBUG + if (debug > 1) + /* Status Codes */ + switch (mb(0)) { + case 0x00: + printf ("Doing Position Fixes\n"); + break; + case 0x01: + printf ("Do no have GPS time yet\n"); + break; + case 0x03: + printf ("PDOP is too high\n"); + break; + case 0x08: + printf ("No usable satellites\n"); + break; + case 0x09: + printf ("Only 1 usable satellite\n"); + break; + case 0x0A: + printf ("Only 2 usable satellites\n"); + break; + case 0x0B: + printf ("Only 3 usable satellites\n"); + break; + case 0x0C: + printf("The Chosen satellite is unusable\n"); + break; + } +#endif + /* Error Codes */ + if (mb(1) != 0) { + + refclock_report(peer, CEVNT_BADTIME); + up->polled = -1; +#ifdef DEBUG + if (debug > 1) { + if (mb(1) & 0x01) + printf ("Signal Processor Error, reset unit.\n"); + if (mb(1) & 0x02) + printf ("Alignment error, channel or chip 1, reset unit.\n"); + if (mb(1) & 0x03) + printf ("Alignment error, channel or chip 2, reset unit.\n"); + if (mb(1) & 0x04) + printf ("Antenna feed line fault (open or short)\n"); + if (mb(1) & 0x05) + printf ("Excessive reference frequency error, refer to packet 0x2D and packet 0x4D documentation for further information\n"); + } +#endif + + return 0; + } + } + else if (up->rpt_buf[0] == 0x54) return 0; - } /* switch */ - }/* if 8F packets */ + else if (up->rpt_buf[0] == PACKET_6D) { +#ifdef DEBUG + int sats; + + if ((mb(0) & 0x01) && (mb(0) & 0x02)) + printf("2d Fix Dimension\n"); + if (mb(0) & 0x04) + printf("3d Fix Dimension\n"); + + if (mb(0) & 0x08) + printf("Fix Mode is MANUAL\n"); + else + printf("Fix Mode is AUTO\n"); + + sats = mb(0) & 0xF0; + sats = sats >> 4; + printf("Tracking %d Satellites\n", sats); +#endif + return 0; + } /* else if not super packet */ refclock_report(peer, CEVNT_BADREPLY); up->polled = -1; #ifdef DEBUG printf("TSIP_decode: unit %d: bad packet %02x-%02x event %d len %d\n", - up->unit, up->rpt_buf[0] & 0xff, mb(0) & 0xff, - event, up->rpt_cnt); + up->unit, up->rpt_buf[0] & 0xff, mb(0) & 0xff, + event, up->rpt_cnt); #endif return 0; } @@ -536,14 +894,8 @@ printf("TSIP_decode: unit %d: %02X #%d %02d:%02d:%02d.%06ld %02d/%02d/%04d UTC % static void palisade_receive ( -#ifdef PALISADE - peer - ) - struct peer * peer; -#else /* ANSI */ struct peer * peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; @@ -552,19 +904,19 @@ palisade_receive ( * Initialize pointers and read the timecode and timestamp. */ pp = peer->procptr; - up = (struct palisade_unit *)pp->unitptr; + up = pp->unitptr; if (! TSIP_decode(peer)) return; if (up->polled <= 0) - return; /* no poll pending, already received or timeout */ + return; /* no poll pending, already received or timeout */ up->polled = 0; /* Poll reply received */ pp->lencode = 0; /* clear time code */ #ifdef DEBUG if (debug) printf( - "palisade_receive: unit %d: %4d %03d %02d:%02d:%02d.%06ld\n", + "palisade_receive: unit %d: %4d %03d %02d:%02d:%02d.%09ld\n", up->unit, pp->year, pp->day, pp->hour, pp->minute, pp->second, pp->nsec); #endif @@ -575,23 +927,18 @@ palisade_receive ( * report and process */ - (void) sprintf(pp->a_lastcode,"%4d %03d %02d:%02d:%02d.%06ld", - pp->year,pp->day,pp->hour,pp->minute, pp->second,pp->nsec); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%4d %03d %02d:%02d:%02d.%09ld", + pp->year, pp->day, + pp->hour,pp->minute, pp->second, pp->nsec); pp->lencode = 24; -#ifdef PALISADE - pp->lasttime = current_time; -#endif - if (!refclock_process(pp -#ifdef PALISADE - , PALISADE_SAMPLES, PALISADE_SAMPLES * 3 / 5 -#endif - )) { + if (!refclock_process(pp)) { refclock_report(peer, CEVNT_BADTIME); #ifdef DEBUG printf("palisade_receive: unit %d: refclock_process failed!\n", - up->unit); + up->unit); #endif return; } @@ -600,16 +947,11 @@ palisade_receive ( #ifdef DEBUG if (debug) - printf("palisade_receive: unit %d: %s\n", - up->unit, prettydate(&pp->lastrec)); + printf("palisade_receive: unit %d: %s\n", + up->unit, prettydate(&pp->lastrec)); #endif pp->lastref = pp->lastrec; - refclock_receive(peer -#ifdef PALISADE - , &pp->offset, 0, pp->dispersion, - &pp->lastrec, &pp->lastrec, pp->leap -#endif - ); + refclock_receive(peer); } @@ -619,38 +961,31 @@ palisade_receive ( */ static void palisade_poll ( -#ifdef PALISADE - unit, peer - ) - int unit; - struct peer *peer; -#else int unit, struct peer *peer ) -#endif { struct palisade_unit *up; struct refclockproc *pp; pp = peer->procptr; - up = (struct palisade_unit *)pp->unitptr; + up = pp->unitptr; pp->polls++; if (up->polled > 0) /* last reply never arrived or error */ - refclock_report(peer, CEVNT_TIMEOUT); + refclock_report(peer, CEVNT_TIMEOUT); up->polled = 2; /* synchronous packet + 1 event */ #ifdef DEBUG if (debug) - printf("palisade_poll: unit %d: polling %s\n", unit, - (pp->sloppyclockflag & CLK_FLAG2) ? - "synchronous packet" : "event"); + printf("palisade_poll: unit %d: polling %s\n", unit, + (pp->sloppyclockflag & CLK_FLAG2) ? + "synchronous packet" : "event"); #endif if (pp->sloppyclockflag & CLK_FLAG2) - return; /* using synchronous packet input */ + return; /* using synchronous packet input */ if(up->type == CLK_PRAECIS) { if(write(peer->procptr->io.fd,"SPSTAT\r\n",8) < 0) @@ -662,11 +997,14 @@ palisade_poll ( } if (HW_poll(pp) < 0) - refclock_report(peer, CEVNT_FAULT); + refclock_report(peer, CEVNT_FAULT); } static void -praecis_parse(struct recvbuf *rbufp, struct peer *peer) +praecis_parse ( + struct recvbuf *rbufp, + struct peer *peer + ) { static char buf[100]; static int p = 0; @@ -692,14 +1030,8 @@ praecis_parse(struct recvbuf *rbufp, struct peer *peer) static void palisade_io ( -#ifdef PALISADE - rbufp - ) - struct recvbuf *rbufp; -#else /* ANSI */ struct recvbuf *rbufp ) -#endif { /* * Initialize pointers and read the timecode and timestamp. @@ -710,9 +1042,9 @@ palisade_io ( char * c, * d; - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct palisade_unit *)pp->unitptr; + up = pp->unitptr; if(up->type == CLK_PRAECIS) { if(praecis_msg) { @@ -748,21 +1080,21 @@ palisade_io ( case TSIP_PARSED_DATA: if (*c == DLE) - up->rpt_status = TSIP_PARSED_DLE_2; + up->rpt_status = TSIP_PARSED_DLE_2; else - mb(up->rpt_cnt++) = *c; + mb(up->rpt_cnt++) = *c; break; case TSIP_PARSED_DLE_2: if (*c == DLE) { up->rpt_status = TSIP_PARSED_DATA; mb(up->rpt_cnt++) = - *c; - } + *c; + } else if (*c == ETX) - up->rpt_status = TSIP_PARSED_FULL; + up->rpt_status = TSIP_PARSED_FULL; else { - /* error: start new report packet */ + /* error: start new report packet */ up->rpt_status = TSIP_PARSED_DLE_1; up->rpt_buf[0] = *c; } @@ -771,23 +1103,23 @@ palisade_io ( case TSIP_PARSED_FULL: case TSIP_PARSED_EMPTY: default: - if ( *c != DLE) - up->rpt_status = TSIP_PARSED_EMPTY; - else - up->rpt_status = TSIP_PARSED_DLE_1; - break; + if ( *c != DLE) + up->rpt_status = TSIP_PARSED_EMPTY; + else + up->rpt_status = TSIP_PARSED_DLE_1; + break; } c++; if (up->rpt_status == TSIP_PARSED_DLE_1) { - up->rpt_cnt = 0; + up->rpt_cnt = 0; if (pp->sloppyclockflag & CLK_FLAG2) - /* stamp it */ - get_systime(&pp->lastrec); + /* stamp it */ + get_systime(&pp->lastrec); } else if (up->rpt_status == TSIP_PARSED_EMPTY) - up->rpt_cnt = 0; + up->rpt_cnt = 0; else if (up->rpt_cnt > BMAX) up->rpt_status =TSIP_PARSED_EMPTY; @@ -807,26 +1139,18 @@ palisade_io ( */ long HW_poll ( -#ifdef PALISADE - pp /* pointer to unit structure */ - ) - struct refclockproc * pp; /* pointer to unit structure */ -#else struct refclockproc * pp /* pointer to unit structure */ ) -#endif { int x; /* state before & after RTS set */ struct palisade_unit *up; - up = (struct palisade_unit *) pp->unitptr; + up = pp->unitptr; /* read the current status, so we put things back right */ if (ioctl(pp->io.fd, TIOCMGET, &x) < 0) { -#ifdef DEBUG - if (debug) - printf("Palisade HW_poll: unit %d: GET %s\n", up->unit, strerror(errno)); -#endif + DPRINTF(1, ("Palisade HW_poll: unit %d: GET %m\n", + up->unit)); msyslog(LOG_ERR, "Palisade(%d) HW_poll: ioctl(fd,GET): %m", up->unit); return -1; @@ -835,10 +1159,13 @@ HW_poll ( x |= TIOCM_RTS; /* turn on RTS */ /* Edge trigger */ + if (up->type == CLK_ACUTIME) + write (pp->io.fd, "", 1); + if (ioctl(pp->io.fd, TIOCMSET, &x) < 0) { #ifdef DEBUG - if (debug) - printf("Palisade HW_poll: unit %d: SET \n", up->unit); + if (debug) + printf("Palisade HW_poll: unit %d: SET \n", up->unit); #endif msyslog(LOG_ERR, "Palisade(%d) HW_poll: ioctl(fd, SET, RTS_on): %m", @@ -853,8 +1180,8 @@ HW_poll ( if (ioctl(pp->io.fd, TIOCMSET, &x) == -1) { #ifdef DEBUG - if (debug) - printf("Palisade HW_poll: unit %d: UNSET \n", up->unit); + if (debug) + printf("Palisade HW_poll: unit %d: UNSET \n", up->unit); #endif msyslog(LOG_ERR, "Palisade(%d) HW_poll: ioctl(fd, UNSET, RTS_off): %m", @@ -865,91 +1192,68 @@ HW_poll ( return 0; } -#if 0 /* unused */ /* - * this 'casts' a character array into a float + * copy/swap a big-endian palisade double into a host double */ -float -getfloat ( -#ifdef PALISADE - bp - ) - u_char *bp; -#else +static double +getdbl ( u_char *bp ) -#endif { - float sval; -#ifdef WORDS_BIGENDIAN - ((char *) &sval)[0] = *bp++; - ((char *) &sval)[1] = *bp++; - ((char *) &sval)[2] = *bp++; - ((char *) &sval)[3] = *bp++; +#ifdef WORDS_BIGENDIAN + double out; + + memcpy(&out, bp, sizeof(out)); + return out; #else - ((char *) &sval)[3] = *bp++; - ((char *) &sval)[2] = *bp++; - ((char *) &sval)[1] = *bp++; - ((char *) &sval)[0] = *bp; -#endif /* ! XNTP_BIG_ENDIAN */ - return sval; -} + union { + u_char ch[8]; + u_int32 u32[2]; + } ui; + + union { + double out; + u_int32 u32[2]; + } uo; + + memcpy(ui.ch, bp, sizeof(ui.ch)); + /* least-significant 32 bits of double from swapped bp[4] to bp[7] */ + uo.u32[0] = ntohl(ui.u32[1]); + /* most-significant 32 bits from swapped bp[0] to bp[3] */ + uo.u32[1] = ntohl(ui.u32[0]); + + return uo.out; #endif +} /* - * this 'casts' a character array into a double + * copy/swap a big-endian palisade short into a host short */ -double -getdbl ( -#ifdef PALISADE - bp - ) - u_char *bp; -#else +static short +getint ( u_char *bp ) -#endif { - double dval; -#ifdef WORDS_BIGENDIAN - ((char *) &dval)[0] = *bp++; - ((char *) &dval)[1] = *bp++; - ((char *) &dval)[2] = *bp++; - ((char *) &dval)[3] = *bp++; - ((char *) &dval)[4] = *bp++; - ((char *) &dval)[5] = *bp++; - ((char *) &dval)[6] = *bp++; - ((char *) &dval)[7] = *bp; -#else - ((char *) &dval)[7] = *bp++; - ((char *) &dval)[6] = *bp++; - ((char *) &dval)[5] = *bp++; - ((char *) &dval)[4] = *bp++; - ((char *) &dval)[3] = *bp++; - ((char *) &dval)[2] = *bp++; - ((char *) &dval)[1] = *bp++; - ((char *) &dval)[0] = *bp; -#endif /* ! XNTP_BIG_ENDIAN */ - return dval; + u_short us; + + memcpy(&us, bp, sizeof(us)); + return (short)ntohs(us); } /* - * cast a 16 bit character array into a short (16 bit) int + * copy/swap a big-endian palisade 32-bit int into a host 32-bit int */ -short -getint ( -#ifdef PALISADE - bp - ) - u_char *bp; -#else +static int32 +getlong( u_char *bp ) -#endif { -return (short) (bp[1] + (bp[0] << 8)); + u_int32 u32; + + memcpy(&u32, bp, sizeof(u32)); + return (int32)(u_int32)ntohl(u32); } -#else -int refclock_palisade_bs; -#endif /* REFCLOCK */ +#else /* REFCLOCK && CLOCK_PALISADE*/ +int refclock_palisade_c_notempty; +#endif diff --git a/contrib/ntp/ntpd/refclock_palisade.h b/contrib/ntp/ntpd/refclock_palisade.h index e63f3da36..3782a5eb9 100644 --- a/contrib/ntp/ntpd/refclock_palisade.h +++ b/contrib/ntp/ntpd/refclock_palisade.h @@ -50,12 +50,8 @@ * */ -#ifndef _REFCLOCK_PALISADE_H -#define _REFCLOCK_PALISADE_H - -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif +#ifndef REFCLOCK_PALISADE_H +#define REFCLOCK_PALISADE_H #if defined HAVE_SYS_MODEM_H #include @@ -71,6 +67,7 @@ # define _SVID3 # endif # include +# include # ifdef TERMIOS_NEEDS__SVID3 # undef _SVID3 # endif @@ -108,10 +105,23 @@ #define LENCODE_8F0B 74 /* Length of TSIP 8F-0B Packet & header */ #define LENCODE_NTP 22 /* Length of Palisade NTP Packet */ +#define LENCODE_8FAC 68 /* Length of Thunderbolt 8F-AC Position Packet*/ +#define LENCODE_8FAB 17 /* Length of Thunderbolt Primary Timing Packet*/ + /* Allowed Sub-Packet ID's */ #define PACKET_8F0B 0x0B #define PACKET_NTP 0xAD +/* Thunderbolt Packets */ +#define PACKET_8FAC 0xAC /* Supplementary Thunderbolt Time Packet */ +#define PACKET_8FAB 0xAB /* Primary Thunderbolt Time Packet */ +#define PACKET_6D 0x6D /* Supplementary Thunderbolt Tracking Stats */ +#define PACKET_41 0x41 /* Thunderbolt I dont know what this packet is, it's not documented on my manual*/ + +/* Acutime Packets */ +#define PACKET_41A 0x41 /* GPS time */ +#define PACKET_46 0x46 /* Receiver Health */ + #define DLE 0x10 #define ETX 0x03 @@ -138,6 +148,16 @@ #define GPS_PI (3.1415926535898) #define R2D (180.0/GPS_PI) +/* + * Structure for build data packets for send (thunderbolt uses it only) + * taken from Markus Prosch + */ +struct packettx +{ + short size; + u_char *data; +}; + /* * Palisade unit control structure. */ @@ -147,24 +167,36 @@ struct palisade_unit { char leap_status; /* leap second flag */ char rpt_status; /* TSIP Parser State */ short rpt_cnt; /* TSIP packet length so far */ - char rpt_buf[BMAX]; /* packet assembly buffer */ + char rpt_buf[BMAX]; /* packet assembly buffer */ int type; /* Clock mode type */ + int month; /* for LEAP filter */ }; /* * Function prototypes */ -static int palisade_start P((int, struct peer *)); -static void palisade_shutdown P((int, struct peer *)); -static void palisade_receive P((struct peer *)); -static void palisade_poll P((int, struct peer *)); -static void palisade_io P((struct recvbuf *)); -int palisade_configure P((int, struct peer *)); -int TSIP_decode P((struct peer *)); -long HW_poll P((struct refclockproc *)); -float getfloat P((u_char *)); -double getdbl P((u_char *)); -short getint P((u_char *)); - -#endif /* PALISADE_H */ +static int palisade_start (int, struct peer *); +static void palisade_shutdown (int, struct peer *); +static void palisade_receive (struct peer *); +static void palisade_poll (int, struct peer *); +static void palisade_io (struct recvbuf *); +int palisade_configure (int, struct peer *); +int TSIP_decode (struct peer *); +long HW_poll (struct refclockproc *); +static double getdbl (u_char *); +static short getint (u_char *); +static int32 getlong (u_char *); + + +#ifdef PALISADE_SENDCMD_RESURRECTED +static void sendcmd (struct packettx *buffer, int c); +#endif +static void sendsupercmd (struct packettx *buffer, int c1, int c2); +static void sendbyte (struct packettx *buffer, int b); +static void sendint (struct packettx *buffer, int a); +static int sendetx (struct packettx *buffer, int fd); +static void init_thunderbolt (int fd); +static void init_acutime (int fd); + +#endif /* REFCLOCK_PALISADE_H */ diff --git a/contrib/ntp/ntpd/refclock_parse.c b/contrib/ntp/ntpd/refclock_parse.c index 0b0109cf6..8e9059573 100644 --- a/contrib/ntp/ntpd/refclock_parse.c +++ b/contrib/ntp/ntpd/refclock_parse.c @@ -1,7 +1,7 @@ /* - * /src/NTP/REPOSITORY/ntp4-dev/ntpd/refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp + * /src/NTP/REPOSITORY/ntp4-dev/ntpd/refclock_parse.c,v 4.81 2009/05/01 10:15:29 kardel RELEASE_20090105_A * - * refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp + * refclock_parse.c,v 4.81 2009/05/01 10:15:29 kardel RELEASE_20090105_A * * generic reference clock driver for several DCF/GPS/MSF/... receivers * @@ -15,8 +15,8 @@ * Currently the STREAMS module is only available for Suns running * SunOS 4.x and SunOS5.x. * - * Copyright (c) 1995-2007 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2015 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -48,40 +48,42 @@ # include "config.h" #endif +#include "ntp_types.h" + #if defined(REFCLOCK) && defined(CLOCK_PARSE) /* * This driver currently provides the support for - * - Meinberg receiver DCF77 PZF 535 (TCXO version) (DCF) - * - Meinberg receiver DCF77 PZF 535 (OCXO version) (DCF) - * - Meinberg receiver DCF77 PZF 509 (DCF) + * - Meinberg receiver DCF77 PZF535 (TCXO version) (DCF) + * - Meinberg receiver DCF77 PZF535 (OCXO version) (DCF) + * - Meinberg receiver DCF77 PZF509 (DCF) * - Meinberg receiver DCF77 AM receivers (e.g. C51) (DCF) * - IGEL CLOCK (DCF) * - ELV DCF7000 (DCF) * - Schmid clock (DCF) * - Conrad DCF77 receiver module (DCF) * - FAU DCF77 NTP receiver (TimeBrick) (DCF) - * - WHARTON 400A Series clock (DCF) + * - WHARTON 400A Series clock (DCF) * - * - Meinberg GPS166/GPS167 (GPS) + * - Meinberg GPS receivers (GPS) * - Trimble (TSIP and TAIP protocol) (GPS) * * - RCC8000 MSF Receiver (MSF) - * - VARITEXT clock (MSF) + * - VARITEXT clock (MSF) */ /* * Meinberg receivers are usually connected via a - * 9600 baud serial line + * 9600/7E1 or 19200/8N1 serial line. * * The Meinberg GPS receivers also have a special NTP time stamp * format. The firmware release is Uni-Erlangen. * * Meinberg generic receiver setup: - * output time code every second - * Baud rate 9600 7E2S + * output time code every second + * Baud rate 9600 7E2S * - * Meinberg GPS16x setup: + * Meinberg GPS receiver setup: * output time code every second * Baudrate 19200 8N1 * @@ -89,14 +91,16 @@ * in Meinberg receivers. * * Special software versions are only sensible for the - * GPS 16x family of receivers. + * oldest GPS receiver, GPS16x. For newer receiver types + * the output string format can be configured at the device, + * and the device name is generally GPSxxx instead of GPS16x. * * Meinberg can be reached via: http://www.meinberg.de/ */ #include "ntpd.h" #include "ntp_refclock.h" -#include "ntp_unixtime.h" /* includes */ +#include "timevalops.h" /* includes */ #include "ntp_control.h" #include "ntp_string.h" @@ -120,6 +124,7 @@ #endif #ifdef HAVE_TERMIOS +# include # define TTY_GETATTR(_FD_, _ARG_) tcgetattr((_FD_), (_ARG_)) # define TTY_SETATTR(_FD_, _ARG_) tcsetattr((_FD_), TCSANOW, (_ARG_)) # undef HAVE_SYSV_TTYS @@ -141,6 +146,7 @@ #ifdef HAVE_PPSAPI # include "ppsapi_timepps.h" +# include "refclock_atom.h" #endif #ifdef PPS @@ -152,13 +158,13 @@ # endif #endif -#define BUFFER_SIZE(_BUF, _PTR) ((_BUF) + sizeof(_BUF) - (_PTR)) -#define BUFFER_SIZES(_BUF, _PTR, _SZ) ((_BUF) + (_SZ) - (_PTR)) +# define BUFFER_SIZE(_BUF, _PTR) ((int)((_BUF) + sizeof(_BUF) - (_PTR))) +# define BUFFER_SIZES(_BUF, _PTR, _SZ) ((int)((_BUF) + (_SZ) - (_PTR))) /* * document type of PPS interfacing - copy of ifdef mechanism in local_input() */ -#undef PPS_METHOD +#undef PPS_METHOD #ifdef HAVE_PPSAPI #define PPS_METHOD "PPS API" @@ -177,6 +183,18 @@ #endif /* TIOCDCDTIMESTAMP */ #endif /* HAVE_PPSAPI */ +/* + * COND_DEF can be conditionally defined as DEF or 0. If defined as DEF + * then some more parse-specific variables are flagged to be printed with + * "ntpq -c cv ". This can be lengthy, so by default COND_DEF + * should be defined as 0. + */ +#if 0 +# define COND_DEF DEF // enable this for testing +#else +# define COND_DEF 0 // enable this by default +#endif + #include "ntp_io.h" #include "ntp_stdlib.h" @@ -188,16 +206,16 @@ #include "ieee754io.h" #include "recvbuff.h" -static char rcsid[] = "refclock_parse.c,v 4.80 2007/08/11 12:06:29 kardel Exp"; +static char rcsid[] = "refclock_parse.c,v 4.81 2009/05/01 10:15:29 kardel RELEASE_20090105_A+POWERUPTRUST"; /**=========================================================================== ** external interface to ntp mechanism **/ -static int parse_start P((int, struct peer *)); -static void parse_shutdown P((int, struct peer *)); -static void parse_poll P((int, struct peer *)); -static void parse_control P((int, struct refclockstat *, struct refclockstat *, struct peer *)); +static int parse_start (int, struct peer *); +static void parse_shutdown (int, struct peer *); +static void parse_poll (int, struct peer *); +static void parse_control (int, const struct refclockstat *, struct refclockstat *, struct peer *); struct refclock refclock_parse = { parse_start, @@ -231,16 +249,16 @@ struct parseunit; /* to keep inquiring minds happy */ typedef struct bind { const char *bd_description; /* name of type of binding */ - int (*bd_init) P((struct parseunit *)); /* initialize */ - void (*bd_end) P((struct parseunit *)); /* end */ - int (*bd_setcs) P((struct parseunit *, parsectl_t *)); /* set character size */ - int (*bd_disable) P((struct parseunit *)); /* disable */ - int (*bd_enable) P((struct parseunit *)); /* enable */ - int (*bd_getfmt) P((struct parseunit *, parsectl_t *)); /* get format */ - int (*bd_setfmt) P((struct parseunit *, parsectl_t *)); /* setfmt */ - int (*bd_timecode) P((struct parseunit *, parsectl_t *)); /* get time code */ - void (*bd_receive) P((struct recvbuf *)); /* receive operation */ - int (*bd_io_input) P((struct recvbuf *)); /* input operation */ + int (*bd_init) (struct parseunit *); /* initialize */ + void (*bd_end) (struct parseunit *); /* end */ + int (*bd_setcs) (struct parseunit *, parsectl_t *); /* set character size */ + int (*bd_disable) (struct parseunit *); /* disable */ + int (*bd_enable) (struct parseunit *); /* enable */ + int (*bd_getfmt) (struct parseunit *, parsectl_t *); /* get format */ + int (*bd_setfmt) (struct parseunit *, parsectl_t *); /* setfmt */ + int (*bd_timecode) (struct parseunit *, parsectl_t *); /* get time code */ + void (*bd_receive) (struct recvbuf *); /* receive operation */ + int (*bd_io_input) (struct recvbuf *); /* input operation */ } bind_t; #define PARSE_END(_X_) (*(_X_)->binding->bd_end)(_X_) @@ -252,12 +270,11 @@ typedef struct bind #define PARSE_GETTIMECODE(_X_, _DCT_) (*(_X_)->binding->bd_timecode)(_X_, _DCT_) /* - * io modes + * special handling flags */ -#define PARSE_F_PPSPPS 0x0001 /* use loopfilter PPS code (CIOGETEV) */ -#define PARSE_F_PPSONSECOND 0x0002 /* PPS pulses are on second */ - - +#define PARSE_F_PPSONSECOND 0x00000001 /* PPS pulses are on second */ +#define PARSE_F_POWERUPTRUST 0x00000100 /* POWERUP state ist trusted for */ + /* trusttime after SYNC was seen */ /**=========================================================================== ** error message regression handling ** @@ -379,7 +396,7 @@ struct parseunit * PARSE io */ bind_t *binding; /* io handling binding */ - + /* * parse state */ @@ -405,9 +422,8 @@ struct parseunit u_long ppsserial; /* magic cookie for ppsclock serials (avoids stale ppsclock data) */ int ppsfd; /* fd to ise for PPS io */ #ifdef HAVE_PPSAPI - pps_handle_t ppshandle; /* store PPSAPI handle */ - pps_params_t ppsparams; /* current PPS parameters */ int hardppsstate; /* current hard pps state */ + struct refclock_atom atom; /* PPSAPI structure */ #endif parsetime_t timedata; /* last (parse module) data */ void *localdata; /* optional local, receiver-specific data */ @@ -423,9 +439,9 @@ struct parseunit ** includes NTP parameters, TTY parameters and IO handling parameters **/ -static void poll_dpoll P((struct parseunit *)); -static void poll_poll P((struct peer *)); -static int poll_init P((struct parseunit *)); +static void poll_dpoll (struct parseunit *); +static void poll_poll (struct peer *); +static int poll_init (struct parseunit *); typedef struct poll_info { @@ -448,23 +464,23 @@ typedef struct poll_info #define DCF_P_ID "DCFp" /* psuedo random phase shift */ #define GPS_ID "GPS" /* GPS receiver */ -#define NOCLOCK_ROOTDELAY 0.0 -#define NOCLOCK_BASEDELAY 0.0 -#define NOCLOCK_DESCRIPTION 0 +#define NOCLOCK_ROOTDELAY 0.0 +#define NOCLOCK_BASEDELAY 0.0 +#define NOCLOCK_DESCRIPTION 0 #define NOCLOCK_MAXUNSYNC 0 #define NOCLOCK_CFLAG 0 #define NOCLOCK_IFLAG 0 #define NOCLOCK_OFLAG 0 #define NOCLOCK_LFLAG 0 -#define NOCLOCK_ID "TILT" -#define NOCLOCK_POLL NO_POLL -#define NOCLOCK_INIT NO_INIT -#define NOCLOCK_END NO_END -#define NOCLOCK_DATA NO_LCLDATA -#define NOCLOCK_FORMAT "" -#define NOCLOCK_TYPE CTL_SST_TS_UNSPEC -#define NOCLOCK_SAMPLES 0 -#define NOCLOCK_KEEP 0 +#define NOCLOCK_ID "TILT" +#define NOCLOCK_POLL NO_POLL +#define NOCLOCK_INIT NO_INIT +#define NOCLOCK_END NO_END +#define NOCLOCK_DATA NO_LCLDATA +#define NOCLOCK_FORMAT "" +#define NOCLOCK_TYPE CTL_SST_TS_UNSPEC +#define NOCLOCK_SAMPLES 0 +#define NOCLOCK_KEEP 0 #define DCF_TYPE CTL_SST_TS_LF #define GPS_TYPE CTL_SST_TS_UHF @@ -534,14 +550,14 @@ typedef struct poll_info #define DCFPZF535OCXO_FORMAT "Meinberg Standard" /* - * Meinberg GPS16X receiver + * Meinberg GPS receivers */ -static void gps16x_message P((struct parseunit *, parsetime_t *)); -static int gps16x_poll_init P((struct parseunit *)); +static void gps16x_message (struct parseunit *, parsetime_t *); +static int gps16x_poll_init (struct parseunit *); #define GPS16X_ROOTDELAY 0.0 /* nothing here */ #define GPS16X_BASEDELAY 0.001968 /* XXX to be fixed ! 1.968ms +- 104us (oscilloscope) - relative to start (end of STX) */ -#define GPS16X_DESCRIPTION "Meinberg GPS16x receiver" +#define GPS16X_DESCRIPTION "Meinberg GPS receiver" #define GPS16X_MAXUNSYNC 60*60*96 /* only trust clock for 4 days * @ 5e-9df/f we have accumulated * at most an error of 1.73 ms @@ -677,16 +693,18 @@ static poll_info_t wsdcf_pollinfo = { WS_POLLRATE, WS_POLLCMD, WS_CMDSIZE }; * RAWDCF receivers that need to be powered from DTR * (like Expert mouse clock) */ -static int rawdcf_init_1 P((struct parseunit *)); +static int rawdcf_init_1 (struct parseunit *); #define RAWDCFDTRSET_DESCRIPTION "RAW DCF77 CODE (DTR SET/RTS CLR)" +#define RAWDCFDTRSET75_DESCRIPTION "RAW DCF77 CODE (DTR SET/RTS CLR @ 75 baud)" #define RAWDCFDTRSET_INIT rawdcf_init_1 /* * RAWDCF receivers that need to be powered from * DTR CLR and RTS SET */ -static int rawdcf_init_2 P((struct parseunit *)); +static int rawdcf_init_2 (struct parseunit *); #define RAWDCFDTRCLRRTSSET_DESCRIPTION "RAW DCF77 CODE (DTR CLR/RTS SET)" +#define RAWDCFDTRCLRRTSSET75_DESCRIPTION "RAW DCF77 CODE (DTR CLR/RTS SET @ 75 baud)" #define RAWDCFDTRCLRRTSSET_INIT rawdcf_init_2 /* @@ -700,17 +718,17 @@ static int rawdcf_init_2 P((struct parseunit *)); #define TRIM_TAIPCMDSIZE (sizeof(TRIM_TAIPPOLLCMD)-1) static poll_info_t trimbletaip_pollinfo = { TRIM_POLLRATE, TRIM_TAIPPOLLCMD, TRIM_TAIPCMDSIZE }; -static int trimbletaip_init P((struct parseunit *)); -static void trimbletaip_event P((struct parseunit *, int)); +static int trimbletaip_init (struct parseunit *); +static void trimbletaip_event (struct parseunit *, int); /* query time & UTC correction data */ static char tsipquery[] = { DLE, 0x21, DLE, ETX, DLE, 0x2F, DLE, ETX }; static poll_info_t trimbletsip_pollinfo = { TRIM_POLLRATE, tsipquery, sizeof(tsipquery) }; -static int trimbletsip_init P((struct parseunit *)); -static void trimbletsip_end P((struct parseunit *)); -static void trimbletsip_message P((struct parseunit *, parsetime_t *)); -static void trimbletsip_event P((struct parseunit *, int)); +static int trimbletsip_init (struct parseunit *); +static void trimbletsip_end (struct parseunit *); +static void trimbletsip_message (struct parseunit *, parsetime_t *); +static void trimbletsip_event (struct parseunit *, int); #define TRIMBLETSIP_IDLE_TIME (300) /* 5 minutes silence at most */ #define TRIMBLE_RESET_HOLDOFF TRIMBLETSIP_IDLE_TIME @@ -741,9 +759,9 @@ static void trimbletsip_event P((struct parseunit *, int)); #define TRIMBLETAIP_INIT trimbletaip_init #define TRIMBLETSIP_INIT trimbletsip_init -#define TRIMBLETAIP_EVENT trimbletaip_event +#define TRIMBLETAIP_EVENT trimbletaip_event -#define TRIMBLETSIP_EVENT trimbletsip_event +#define TRIMBLETSIP_EVENT trimbletsip_event #define TRIMBLETSIP_MESSAGE trimbletsip_message #define TRIMBLETAIP_END 0 @@ -800,7 +818,7 @@ static poll_info_t rcc8000_pollinfo = { RCC_POLLRATE, RCC_POLLCMD, RCC_CMDSIZE } #define RCC8000_KEEP 3 /* - * Hopf Radio clock 6021 Format + * Hopf Radio clock 6021 Format * */ #define HOPF6021_ROOTDELAY 0.0 @@ -855,14 +873,43 @@ static poll_info_t rcc8000_pollinfo = { RCC_POLLRATE, RCC_POLLCMD, RCC_CMDSIZE } #define VARITEXT_SAMPLES 32 #define VARITEXT_KEEP 20 +/* + * SEL240x Satellite Sychronized Clock + */ +#define SEL240X_POLLRATE 0 /* only true direct polling */ +#define SEL240X_POLLCMD "BUB8" +#define SEL240X_CMDSIZE 4 + +static poll_info_t sel240x_pollinfo = { SEL240X_POLLRATE, + SEL240X_POLLCMD, + SEL240X_CMDSIZE }; +#define SEL240X_FLAGS (PARSE_F_PPSONSECOND) +#define SEL240X_POLL poll_dpoll +#define SEL240X_INIT poll_init +#define SEL240X_END 0 +#define SEL240X_DATA ((void *)(&sel240x_pollinfo)) +#define SEL240X_ROOTDELAY 0.0 +#define SEL240X_BASEDELAY 0.0 +#define SEL240X_ID GPS_ID +#define SEL240X_DESCRIPTION "SEL240x Satellite Synchronized Clock" +#define SEL240X_FORMAT "SEL B8" +#define SEL240X_MAXUNSYNC 60*60*12 /* only trust clock for 12 hours */ +#define SEL240X_SPEED (B9600) +#define SEL240X_CFLAG (CS8|CREAD|CLOCAL) +#define SEL240X_IFLAG (IGNBRK|IGNPAR) +#define SEL240X_OFLAG (0) +#define SEL240X_LFLAG (0) +#define SEL240X_SAMPLES 5 +#define SEL240X_KEEP 3 + static struct parse_clockinfo { - u_long cl_flags; /* operation flags (io modes) */ - void (*cl_poll) P((struct parseunit *)); /* active poll routine */ - int (*cl_init) P((struct parseunit *)); /* active poll init routine */ - void (*cl_event) P((struct parseunit *, int)); /* special event handling (e.g. reset clock) */ - void (*cl_end) P((struct parseunit *)); /* active poll end routine */ - void (*cl_message) P((struct parseunit *, parsetime_t *)); /* process a lower layer message */ + u_long cl_flags; /* operation flags (PPS interpretation, trust handling) */ + void (*cl_poll) (struct parseunit *); /* active poll routine */ + int (*cl_init) (struct parseunit *); /* active poll init routine */ + void (*cl_event) (struct parseunit *, int); /* special event handling (e.g. reset clock) */ + void (*cl_end) (struct parseunit *); /* active poll end routine */ + void (*cl_message) (struct parseunit *, parsetime_t *); /* process a lower layer message */ void *cl_data; /* local data area for "poll" mechanism */ double cl_rootdelay; /* rootdelay */ double cl_basedelay; /* current offset by which the RS232 @@ -1167,7 +1214,7 @@ static struct parse_clockinfo }, { /* mode 12 */ HOPF6021_FLAGS, - NO_POLL, + NO_POLL, NO_INIT, NO_EVENT, NO_END, @@ -1351,6 +1398,122 @@ static struct parse_clockinfo RAWDCF_SAMPLES, RAWDCF_KEEP }, + { /* mode 20, like mode 14 but driven by 75 baud */ + RAWDCF_FLAGS, + NO_POLL, + RAWDCFDTRSET_INIT, + NO_EVENT, + NO_END, + NO_MESSAGE, + NO_LCLDATA, + RAWDCF_ROOTDELAY, + RAWDCF_BASEDELAY, + DCF_A_ID, + RAWDCFDTRSET75_DESCRIPTION, + RAWDCF_FORMAT, + DCF_TYPE, + RAWDCF_MAXUNSYNC, + B75, + RAWDCF_CFLAG, + RAWDCF_IFLAG, + RAWDCF_OFLAG, + RAWDCF_LFLAG, + RAWDCF_SAMPLES, + RAWDCF_KEEP + }, + { /* mode 21, like mode 16 but driven by 75 baud + - RAWDCF RTS set, DTR clr */ + RAWDCF_FLAGS, + NO_POLL, + RAWDCFDTRCLRRTSSET_INIT, + NO_EVENT, + NO_END, + NO_MESSAGE, + NO_LCLDATA, + RAWDCF_ROOTDELAY, + RAWDCF_BASEDELAY, + DCF_A_ID, + RAWDCFDTRCLRRTSSET75_DESCRIPTION, + RAWDCF_FORMAT, + DCF_TYPE, + RAWDCF_MAXUNSYNC, + B75, + RAWDCF_CFLAG, + RAWDCF_IFLAG, + RAWDCF_OFLAG, + RAWDCF_LFLAG, + RAWDCF_SAMPLES, + RAWDCF_KEEP + }, + { /* mode 22 - like 2 with POWERUP trust */ + MBG_FLAGS | PARSE_F_POWERUPTRUST, + NO_POLL, + NO_INIT, + NO_EVENT, + NO_END, + NO_MESSAGE, + NO_LCLDATA, + DCFUA31_ROOTDELAY, + DCFUA31_BASEDELAY, + DCF_A_ID, + DCFUA31_DESCRIPTION, + DCFUA31_FORMAT, + DCF_TYPE, + DCFUA31_MAXUNSYNC, + DCFUA31_SPEED, + DCFUA31_CFLAG, + DCFUA31_IFLAG, + DCFUA31_OFLAG, + DCFUA31_LFLAG, + DCFUA31_SAMPLES, + DCFUA31_KEEP + }, + { /* mode 23 - like 7 with POWERUP trust */ + MBG_FLAGS | PARSE_F_POWERUPTRUST, + GPS16X_POLL, + GPS16X_INIT, + NO_EVENT, + GPS16X_END, + GPS16X_MESSAGE, + GPS16X_DATA, + GPS16X_ROOTDELAY, + GPS16X_BASEDELAY, + GPS16X_ID, + GPS16X_DESCRIPTION, + GPS16X_FORMAT, + GPS_TYPE, + GPS16X_MAXUNSYNC, + GPS16X_SPEED, + GPS16X_CFLAG, + GPS16X_IFLAG, + GPS16X_OFLAG, + GPS16X_LFLAG, + GPS16X_SAMPLES, + GPS16X_KEEP + }, + { /* mode 24 */ + SEL240X_FLAGS, + SEL240X_POLL, + SEL240X_INIT, + NO_EVENT, + SEL240X_END, + NO_MESSAGE, + SEL240X_DATA, + SEL240X_ROOTDELAY, + SEL240X_BASEDELAY, + SEL240X_ID, + SEL240X_DESCRIPTION, + SEL240X_FORMAT, + GPS_TYPE, + SEL240X_MAXUNSYNC, + SEL240X_SPEED, + SEL240X_CFLAG, + SEL240X_IFLAG, + SEL240X_OFLAG, + SEL240X_LFLAG, + SEL240X_SAMPLES, + SEL240X_KEEP + }, }; static int ncltypes = sizeof(parse_clockinfo) / sizeof(struct parse_clockinfo); @@ -1371,11 +1534,11 @@ static int notice = 0; #define PARSE_STATETIME(parse, i) ((parse->generic->currentstatus == i) ? parse->statetime[i] + current_time - parse->lastchange : parse->statetime[i]) -static void parse_event P((struct parseunit *, int)); -static void parse_process P((struct parseunit *, parsetime_t *)); -static void clear_err P((struct parseunit *, u_long)); -static int list_err P((struct parseunit *, u_long)); -static char * l_mktime P((u_long)); +static void parse_event (struct parseunit *, int); +static void parse_process (struct parseunit *, parsetime_t *); +static void clear_err (struct parseunit *, u_long); +static int list_err (struct parseunit *, u_long); +static char * l_mktime (u_long); /**=========================================================================== ** implementation error message regression module @@ -1388,7 +1551,7 @@ clear_err( { if (lstate == ERR_ALL) { - int i; + size_t i; for (i = 0; i < ERR_CNT; i++) { @@ -1427,7 +1590,7 @@ list_err( if (do_it) err->err_cnt++; - + if (err->err_stage->err_count && (err->err_cnt >= err->err_stage->err_count)) { @@ -1451,7 +1614,7 @@ list_err( l_mktime(current_time - err->err_started)); err->err_suppressed = 0; } - + return do_it; } @@ -1473,13 +1636,14 @@ mkreadable( int hex ) { + static const char ellipsis[] = "..."; char *b = buffer; - char *endb = (char *)0; + char *endb = NULL; if (blen < 4) - return (char *)0; /* don't bother with mini buffers */ + return NULL; /* don't bother with mini buffers */ - endb = buffer + blen - 4; + endb = buffer + blen - sizeof(ellipsis); blen--; /* account for '\0' */ @@ -1488,7 +1652,7 @@ mkreadable( if (!hex && /* no binary only */ (*src != '\\') && /* no plain \ */ (*src != '"') && /* no " */ - isprint((int)*src)) /* only printables */ + isprint((unsigned char)*src)) /* only printables */ { /* they are easy... */ *buffer++ = *src++; blen--; @@ -1508,21 +1672,21 @@ mkreadable( { if (*src == '\\') { - strcpy(buffer,"\\\\"); + memcpy(buffer, "\\\\", 2); buffer += 2; blen -= 2; src++; } else { - sprintf(buffer, "\\x%02x", *src++); + snprintf(buffer, blen, "\\x%02x", *src++); blen -= 4; buffer += 4; } } } if (srclen && !blen && endb) /* overflow - set last chars to ... */ - strcpy(endb, "..."); + memcpy(endb, ellipsis, sizeof(ellipsis)); } *buffer = '\0'; @@ -1554,27 +1718,27 @@ mkascii( * define possible io handling methods */ #ifdef STREAM -static int ppsclock_init P((struct parseunit *)); -static int stream_init P((struct parseunit *)); -static void stream_end P((struct parseunit *)); -static int stream_enable P((struct parseunit *)); -static int stream_disable P((struct parseunit *)); -static int stream_setcs P((struct parseunit *, parsectl_t *)); -static int stream_getfmt P((struct parseunit *, parsectl_t *)); -static int stream_setfmt P((struct parseunit *, parsectl_t *)); -static int stream_timecode P((struct parseunit *, parsectl_t *)); -static void stream_receive P((struct recvbuf *)); +static int ppsclock_init (struct parseunit *); +static int stream_init (struct parseunit *); +static void stream_end (struct parseunit *); +static int stream_enable (struct parseunit *); +static int stream_disable (struct parseunit *); +static int stream_setcs (struct parseunit *, parsectl_t *); +static int stream_getfmt (struct parseunit *, parsectl_t *); +static int stream_setfmt (struct parseunit *, parsectl_t *); +static int stream_timecode (struct parseunit *, parsectl_t *); +static void stream_receive (struct recvbuf *); #endif - -static int local_init P((struct parseunit *)); -static void local_end P((struct parseunit *)); -static int local_nop P((struct parseunit *)); -static int local_setcs P((struct parseunit *, parsectl_t *)); -static int local_getfmt P((struct parseunit *, parsectl_t *)); -static int local_setfmt P((struct parseunit *, parsectl_t *)); -static int local_timecode P((struct parseunit *, parsectl_t *)); -static void local_receive P((struct recvbuf *)); -static int local_input P((struct recvbuf *)); + +static int local_init (struct parseunit *); +static void local_end (struct parseunit *); +static int local_nop (struct parseunit *); +static int local_setcs (struct parseunit *, parsectl_t *); +static int local_getfmt (struct parseunit *, parsectl_t *); +static int local_setfmt (struct parseunit *, parsectl_t *); +static int local_timecode (struct parseunit *, parsectl_t *); +static void local_receive (struct recvbuf *); +static int local_input (struct recvbuf *); static bind_t io_bindings[] = { @@ -1621,34 +1785,21 @@ static bind_t io_bindings[] = }, { (char *)0, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, + NULL, } }; #ifdef STREAM -#define fix_ts(_X_) \ - if ((&(_X_))->tv.tv_usec >= 1000000) \ - { \ - (&(_X_))->tv.tv_usec -= 1000000; \ - (&(_X_))->tv.tv_sec += 1; \ - } - -#define cvt_ts(_X_, _Y_) \ - { \ - l_fp ts; \ - fix_ts((_X_)); \ - if (!buftvtots((const char *)&(&(_X_))->tv, &ts)) \ - { \ - ERR(ERR_BADDATA) \ - msyslog(LOG_ERR,"parse: stream_receive: timestamp conversion error (buftvtots) (%s) (%ld.%06ld) ", (_Y_), (long)(&(_X_))->tv.tv_sec, (long)(&(_X_))->tv.tv_usec);\ - return; \ - } \ - else \ - { \ - (&(_X_))->fp = ts; \ - } \ - } - /*-------------------------------------------------- * ppsclock STREAM init */ @@ -1659,7 +1810,7 @@ ppsclock_init( { static char m1[] = "ppsclocd"; static char m2[] = "ppsclock"; - + /* * now push the parse streams module * it will ensure exclusive access to the device @@ -1748,7 +1899,7 @@ stream_setcs( ) { struct strioctl strioc; - + strioc.ic_cmd = PARSEIOC_SETCS; strioc.ic_timout = 0; strioc.ic_dp = (char *)tcl; @@ -1771,7 +1922,7 @@ stream_enable( ) { struct strioctl strioc; - + strioc.ic_cmd = PARSEIOC_ENABLE; strioc.ic_timout = 0; strioc.ic_dp = (char *)0; @@ -1795,7 +1946,7 @@ stream_disable( ) { struct strioctl strioc; - + strioc.ic_cmd = PARSEIOC_DISABLE; strioc.ic_timout = 0; strioc.ic_dp = (char *)0; @@ -1820,7 +1971,7 @@ stream_getfmt( ) { struct strioctl strioc; - + strioc.ic_cmd = PARSEIOC_GETFMT; strioc.ic_timout = 0; strioc.ic_dp = (char *)tcl; @@ -1843,7 +1994,7 @@ stream_setfmt( ) { struct strioctl strioc; - + strioc.ic_cmd = PARSEIOC_SETFMT; strioc.ic_timout = 0; strioc.ic_dp = (char *)tcl; @@ -1868,12 +2019,12 @@ stream_timecode( ) { struct strioctl strioc; - + strioc.ic_cmd = PARSEIOC_TIMECODE; strioc.ic_timout = 0; strioc.ic_dp = (char *)tcl; strioc.ic_len = sizeof (*tcl); - + if (ioctl(parse->generic->io.fd, I_STR, (caddr_t)&strioc) == -1) { ERR(ERR_INTERNAL) @@ -1892,9 +2043,10 @@ stream_receive( struct recvbuf *rbufp ) { - struct parseunit *parse = (struct parseunit *)((void *)rbufp->recv_srcclock); + struct parseunit * parse; parsetime_t parsetime; + parse = (struct parseunit *)rbufp->recv_peer->procptr->unitptr; if (!parse->peer) return; @@ -1907,7 +2059,7 @@ stream_receive( return; } clear_err(parse, ERR_BADIO); - + memmove((caddr_t)&parsetime, (caddr_t)rbufp->recv_buffer, sizeof(parsetime_t)); @@ -1933,15 +2085,17 @@ stream_receive( * errors. */ - cvt_ts(parsetime.parse_stime, "parse_stime"); + parsetime.parse_stime.fp = tval_stamp_to_lfp(parsetime.parse_stime.tv); if (PARSE_TIMECODE(parsetime.parse_state)) { - cvt_ts(parsetime.parse_time, "parse_time"); + parsetime.parse_time.fp = tval_stamp_to_lfp(parsetime.parse_time.tv); } if (PARSE_PPS(parsetime.parse_state)) - cvt_ts(parsetime.parse_ptime, "parse_ptime"); + { + parsetime.parse_ptime.fp = tval_stamp_to_lfp(parsetime.parse_ptime.tv); + } parse_process(parse, &parsetime); } @@ -2038,11 +2192,13 @@ local_input( struct recvbuf *rbufp ) { - struct parseunit *parse = (struct parseunit *)((void *)rbufp->recv_srcclock); + struct parseunit * parse; + int count; unsigned char *s; timestamp_t ts; + parse = (struct parseunit *)rbufp->recv_peer->procptr->unitptr; if (!parse->peer) return 0; @@ -2069,11 +2225,11 @@ local_input( { struct timespec pps_timeout; pps_info_t pps_info; - + pps_timeout.tv_sec = 0; pps_timeout.tv_nsec = 0; - if (time_pps_fetch(parse->ppshandle, PPS_TSFMT_TSPEC, &pps_info, + if (time_pps_fetch(parse->atom.handle, PPS_TSFMT_TSPEC, &pps_info, &pps_timeout) == 0) { if (pps_info.assert_sequence + pps_info.clear_sequence != parse->ppsserial) @@ -2090,9 +2246,9 @@ local_input( else pts = pps_info.assert_timestamp; - parse->parseio.parse_dtime.parse_ptime.fp.l_ui = pts.tv_sec + JAN_1970; + parse->parseio.parse_dtime.parse_ptime.fp.l_ui = (uint32_t) (pts.tv_sec + JAN_1970); - dtemp = pts.tv_nsec / 1e9; + dtemp = (double) pts.tv_nsec / 1e9; if (dtemp < 0.) { dtemp += 1; parse->parseio.parse_dtime.parse_ptime.fp.l_ui--; @@ -2101,9 +2257,9 @@ local_input( dtemp -= 1; parse->parseio.parse_dtime.parse_ptime.fp.l_ui++; } - parse->parseio.parse_dtime.parse_ptime.fp.l_uf = dtemp * FRAC; + parse->parseio.parse_dtime.parse_ptime.fp.l_uf = (uint32_t)(dtemp * FRAC); - parse->parseio.parse_dtime.parse_state |= PARSEB_PPS|PARSEB_S_PPS; + parse->parseio.parse_dtime.parse_state |= PARSEB_PPS|PARSEB_S_PPS; #ifdef DEBUG if (debug > 3) { @@ -2145,11 +2301,11 @@ local_input( #else #ifdef TIOCDCDTIMESTAMP struct timeval dcd_time; - + if (ioctl(parse->ppsfd, TIOCDCDTIMESTAMP, &dcd_time) != -1) { l_fp tstmp; - + TVTOTS(&dcd_time, &tstmp); tstmp.l_ui += JAN_1970; L_SUB(&ts.fp, &tstmp); @@ -2217,12 +2373,19 @@ local_input( sizeof(parsetime_t)); buf->recv_length = sizeof(parsetime_t); buf->recv_time = rbufp->recv_time; +#ifndef HAVE_IO_COMPLETION_PORT buf->srcadr = rbufp->srcadr; +#endif buf->dstadr = rbufp->dstadr; buf->receiver = rbufp->receiver; buf->fd = rbufp->fd; buf->X_from_where = rbufp->X_from_where; + parse->generic->io.recvcount++; + packets_received++; add_full_recv_buffer(buf); +#ifdef HAVE_IO_COMPLETION_PORT + SetEvent(WaitableIoEventHandle); +#endif } parse_iodone(&parse->parseio); } @@ -2248,9 +2411,10 @@ local_receive( struct recvbuf *rbufp ) { - struct parseunit *parse = (struct parseunit *)((void *)rbufp->recv_srcclock); + struct parseunit * parse; parsetime_t parsetime; + parse = (struct parseunit *)rbufp->recv_peer->procptr->unitptr; if (!parse->peer) return; @@ -2263,7 +2427,7 @@ local_receive( return; } clear_err(parse, ERR_BADIO); - + memmove((caddr_t)&parsetime, (caddr_t)rbufp->recv_buffer, sizeof(parsetime_t)); @@ -2312,6 +2476,31 @@ init_iobinding( ** support routines **/ +static NTP_PRINTF(4, 5) char * +ap(char *buffer, size_t len, char *pos, const char *fmt, ...) +{ + va_list va; + int l; + size_t rem = len - (pos - buffer); + + if (rem == 0) + return pos; + + va_start(va, fmt); + l = vsnprintf(pos, rem, fmt, va); + va_end(va); + + if (l != -1) { + rem--; + if (rem >= (size_t)l) + pos += l; + else + pos += rem; + } + + return pos; +} + /*-------------------------------------------------- * convert a flag field to a string */ @@ -2336,11 +2525,11 @@ parsestate( { PARSEB_LEAPADD, "LEAP ADD WARNING" }, { PARSEB_LEAPDEL, "LEAP DELETE WARNING" }, { PARSEB_LEAPSECOND, "LEAP SECOND" }, - { PARSEB_ALTERNATE, "ALTERNATE ANTENNA" }, + { PARSEB_CALLBIT, "CALL BIT" }, { PARSEB_TIMECODE, "TIME CODE" }, { PARSEB_PPS, "PPS" }, { PARSEB_POSITION, "POSITION" }, - { 0 } + { 0, NULL } }; static struct sbits @@ -2351,14 +2540,13 @@ parsestate( { { PARSEB_S_LEAP, "LEAP INDICATION" }, { PARSEB_S_PPS, "PPS SIGNAL" }, - { PARSEB_S_ANTENNA, "ANTENNA" }, + { PARSEB_S_CALLBIT, "CALLBIT" }, { PARSEB_S_POSITION, "POSITION" }, - { 0 } + { 0, NULL } }; int i; char *s, *t; - *buffer = '\0'; s = t = buffer; @@ -2368,23 +2556,20 @@ parsestate( if (flagstrings[i].bit & lstate) { if (s != t) - strncpy(t, "; ", BUFFER_SIZES(buffer, t, size)); - strncat(t, flagstrings[i].name, BUFFER_SIZES(buffer, t, size)); - t += strlen(t); + t = ap(buffer, size, t, "; "); + t = ap(buffer, size, t, "%s", flagstrings[i].name); } i++; } - if (lstate & (PARSEB_S_LEAP|PARSEB_S_ANTENNA|PARSEB_S_PPS|PARSEB_S_POSITION)) + if (lstate & (PARSEB_S_LEAP|PARSEB_S_CALLBIT|PARSEB_S_PPS|PARSEB_S_POSITION)) { if (s != t) - strncpy(t, "; ", BUFFER_SIZES(buffer, t, size)); - - t += strlen(t); + t = ap(buffer, size, t, "; "); - strncpy(t, "(", BUFFER_SIZES(buffer, t, size)); + t = ap(buffer, size, t, "("); - s = t = t + strlen(t); + s = t; i = 0; while (sflagstrings[i].bit) @@ -2393,16 +2578,18 @@ parsestate( { if (t != s) { - strncpy(t, "; ", BUFFER_SIZES(buffer, t, size)); - t += 2; + t = ap(buffer, size, t, "; "); } - - strncpy(t, sflagstrings[i].name, BUFFER_SIZES(buffer, t, size)); - t += strlen(t); + + t = ap(buffer, size, t, "%s", + sflagstrings[i].name); } i++; } - strncpy(t, ")", BUFFER_SIZES(buffer, t, size)); + t = ap(buffer, size, t, ")"); + /* t is unused here, but if we don't track it and + * need it later, that's a bug waiting to happen. + */ } return buffer; } @@ -2430,10 +2617,12 @@ parsestatus( { CVT_BADDATE, "DATE ILLEGAL" }, { CVT_BADTIME, "TIME ILLEGAL" }, { CVT_ADDITIONAL, "ADDITIONAL DATA" }, - { 0 } + { 0, NULL } }; int i; + char *t; + t = buffer; *buffer = '\0'; i = 0; @@ -2441,9 +2630,9 @@ parsestatus( { if (flagstrings[i].bit & lstate) { - if (buffer[0]) - strncat(buffer, "; ", size); - strncat(buffer, flagstrings[i].name, size); + if (t != buffer) + t = ap(buffer, size, t, "; "); + t = ap(buffer, size, t, "%s", flagstrings[i].name); } i++; } @@ -2473,12 +2662,12 @@ clockstatus( { CEVNT_PROP, "PROPAGATION DELAY" }, { CEVNT_BADDATE, "ILLEGAL DATE" }, { CEVNT_BADTIME, "ILLEGAL TIME" }, - { (unsigned)~0L } + { (unsigned)~0L, NULL } }; int i; i = 0; - while (flagstrings[i].value != ~0) + while (flagstrings[i].value != (u_int)~0) { if (flagstrings[i].value == lstate) { @@ -2506,10 +2695,11 @@ l_mktime( char *t; buffer[0] = '\0'; + t = buffer; if ((tmp = delta / (60*60*24)) != 0) { - snprintf(buffer, BUFFER_SIZE(buffer, buffer), "%ldd+", (u_long)tmp); + t = ap(buffer, sizeof(buffer), t, "%ldd+", (u_long)tmp); delta -= tmp * 60*60*24; } @@ -2518,10 +2708,8 @@ l_mktime( m = delta % 60; delta /= 60; - t = buffer + strlen(buffer); - - snprintf(t, BUFFER_SIZE(buffer, t), "%02d:%02d:%02d", - (int)delta, (int)m, (int)s); + t = ap(buffer, sizeof(buffer), t, "%02d:%02d:%02d", + (int)delta, (int)m, (int)s); return buffer; } @@ -2601,10 +2789,10 @@ parse_shutdown( struct peer *peer ) { - struct parseunit *parse = (struct parseunit *)0; + struct parseunit *parse = NULL; if (peer && peer->procptr) - parse = (struct parseunit *)peer->procptr->unitptr; + parse = peer->procptr->unitptr; if (!parse) { @@ -2612,7 +2800,7 @@ parse_shutdown( return; } - if (!parse->peer) + if (!parse->peer) { msyslog(LOG_INFO, "PARSE receiver #%d: INTERNAL ERROR - unit already inactive - shutdown ignored", unit); return; @@ -2621,11 +2809,11 @@ parse_shutdown( #ifdef HAVE_PPSAPI if (parse->flags & PARSE_PPSCLOCK) { - (void)time_pps_destroy(parse->ppshandle); + (void)time_pps_destroy(parse->atom.handle); } #endif if (parse->generic->io.fd != parse->ppsfd && parse->ppsfd != -1) - (void)close(parse->ppsfd); /* close separate PPS source */ + (void)closeserial(parse->ppsfd); /* close separate PPS source */ /* * print statistics a last time and @@ -2637,7 +2825,7 @@ parse_shutdown( { parse->parse_type->cl_end(parse); } - + /* * cleanup before leaving this world */ @@ -2650,7 +2838,7 @@ parse_shutdown( io_closeclock(&parse->generic->io); free_varlist(parse->kv); - + NLOG(NLOG_CLOCKINFO) /* conditional if clause for conditional syslog */ msyslog(LOG_INFO, "PARSE receiver #%d: reference clock \"%s\" removed", CLK_UNIT(parse->peer), parse->parse_type->cl_description); @@ -2676,15 +2864,15 @@ parse_hardpps( if (CLK_PPS(parse->peer) && (parse->flags & PARSE_PPSKERNEL)) { int i = 0; - if (mode == PARSE_HARDPPS_ENABLE) + if (mode == PARSE_HARDPPS_ENABLE) { if (parse->flags & PARSE_CLEAR) i = PPS_CAPTURECLEAR; else i = PPS_CAPTUREASSERT; } - - if (time_pps_kcbind(parse->ppshandle, PPS_KC_HARDPPS, i, + + if (time_pps_kcbind(parse->atom.handle, PPS_KC_HARDPPS, i, PPS_TSFMT_TSPEC) < 0) { msyslog(LOG_ERR, "PARSE receiver #%d: time_pps_kcbind failed: %m", CLK_UNIT(parse->peer)); @@ -2696,7 +2884,7 @@ parse_hardpps( * tell the rest, that we have a kernel PPS source, iff we ever enable HARDPPS */ if (mode == PARSE_HARDPPS_ENABLE) - pps_enable = 1; + hardpps_enable = 1; } } @@ -2711,23 +2899,30 @@ parse_ppsapi( struct parseunit *parse ) { - int cap, mode, mode1; - char *cp; - - parse->flags &= ~PARSE_PPSCLOCK; + int cap, mode_ppsoffset; + const char *cp; + + parse->flags &= (u_char) (~PARSE_PPSCLOCK); - if (time_pps_getcap(parse->ppshandle, &cap) < 0) { + /* + * collect PPSAPI offset capability - should move into generic handling + */ + if (time_pps_getcap(parse->atom.handle, &cap) < 0) { msyslog(LOG_ERR, "PARSE receiver #%d: parse_ppsapi: time_pps_getcap failed: %m", CLK_UNIT(parse->peer)); - + return 0; } - if (time_pps_getparams(parse->ppshandle, &parse->ppsparams) < 0) { - msyslog(LOG_ERR, "PARSE receiver #%d: parse_ppsapi: time_pps_getparams failed: %m", - CLK_UNIT(parse->peer)); + /* + * initialize generic PPSAPI interface + * + * we leave out CLK_FLAG3 as time_pps_kcbind() + * is handled here for now. Ideally this should also + * be part of the generic PPSAPI interface + */ + if (!refclock_params(parse->flags & (CLK_FLAG1|CLK_FLAG2|CLK_FLAG4), &parse->atom)) return 0; - } /* nb. only turn things on, if someone else has turned something * on before we get here, leave it alone! @@ -2735,47 +2930,36 @@ parse_ppsapi( if (parse->flags & PARSE_CLEAR) { cp = "CLEAR"; - mode = PPS_CAPTURECLEAR; - mode1 = PPS_OFFSETCLEAR; + mode_ppsoffset = PPS_OFFSETCLEAR; } else { cp = "ASSERT"; - mode = PPS_CAPTUREASSERT; - mode1 = PPS_OFFSETASSERT; + mode_ppsoffset = PPS_OFFSETASSERT; } msyslog(LOG_INFO, "PARSE receiver #%d: initializing PPS to %s", CLK_UNIT(parse->peer), cp); - if (!(mode & cap)) { - msyslog(LOG_ERR, "PARSE receiver #%d: FAILED to initialize PPS to %s (PPS API capabilities=0x%x)", - CLK_UNIT(parse->peer), cp, cap); - - return 0; - } - - if (!(mode1 & cap)) { + if (!(mode_ppsoffset & cap)) { msyslog(LOG_WARNING, "PARSE receiver #%d: Cannot set PPS_%sCLEAR, this will increase jitter (PPS API capabilities=0x%x)", CLK_UNIT(parse->peer), cp, cap); - mode1 = 0; + mode_ppsoffset = 0; } else { - if (mode1 == PPS_OFFSETCLEAR) - { - parse->ppsparams.clear_offset.tv_sec = -parse->ppsphaseadjust; - parse->ppsparams.clear_offset.tv_nsec = -1e9*(parse->ppsphaseadjust - (long)parse->ppsphaseadjust); + if (mode_ppsoffset == PPS_OFFSETCLEAR) + { + parse->atom.pps_params.clear_offset.tv_sec = (time_t)(-parse->ppsphaseadjust); + parse->atom.pps_params.clear_offset.tv_nsec = (long)(-1e9*(parse->ppsphaseadjust - (double)(long)parse->ppsphaseadjust)); } - - if (mode1 == PPS_OFFSETASSERT) - { - parse->ppsparams.assert_offset.tv_sec = -parse->ppsphaseadjust; - parse->ppsparams.assert_offset.tv_nsec = -1e9*(parse->ppsphaseadjust - (long)parse->ppsphaseadjust); + + if (mode_ppsoffset == PPS_OFFSETASSERT) + { + parse->atom.pps_params.assert_offset.tv_sec = (time_t)(-parse->ppsphaseadjust); + parse->atom.pps_params.assert_offset.tv_nsec = (long)(-1e9*(parse->ppsphaseadjust - (double)(long)parse->ppsphaseadjust)); } } - - /* only set what is legal */ - parse->ppsparams.mode = (mode | mode1 | PPS_TSFMT_TSPEC) & cap; + parse->atom.pps_params.mode |= mode_ppsoffset; - if (time_pps_setparams(parse->ppshandle, &parse->ppsparams) < 0) { + if (time_pps_setparams(parse->atom.handle, &parse->atom.pps_params) < 0) { msyslog(LOG_ERR, "PARSE receiver #%d: FAILED set PPS parameters: %m", CLK_UNIT(parse->peer)); return 0; @@ -2817,14 +3001,14 @@ parse_start( if (!notice) { NLOG(NLOG_CLOCKINFO) /* conditional if clause for conditional syslog */ - msyslog(LOG_INFO, "NTP PARSE support: Copyright (c) 1989-2006, Frank Kardel"); + msyslog(LOG_INFO, "NTP PARSE support: Copyright (c) 1989-2015, Frank Kardel"); notice = 1; } type = CLK_TYPE(peer); unit = CLK_UNIT(peer); - if ((type == ~0) || (parse_clockinfo[type].cl_description == (char *)0)) + if ((type == (u_int)~0) || (parse_clockinfo[type].cl_description == (char *)0)) { msyslog(LOG_ERR, "PARSE receiver #%d: parse_start: unsupported clock type %d (max %d)", unit, CLK_REALTYPE(peer), ncltypes-1); @@ -2840,12 +3024,11 @@ parse_start( #ifndef O_NOCTTY #define O_NOCTTY 0 #endif - - fd232 = open(parsedev, O_RDWR | O_NOCTTY -#ifdef O_NONBLOCK - | O_NONBLOCK +#ifndef O_NONBLOCK +#define O_NONBLOCK 0 #endif - , 0777); + + fd232 = tty_open(parsedev, O_RDWR | O_NOCTTY | O_NONBLOCK, 0777); if (fd232 == -1) { @@ -2853,9 +3036,7 @@ parse_start( return 0; } - parse = (struct parseunit *)emalloc(sizeof(struct parseunit)); - - memset((char *)parse, 0, sizeof(struct parseunit)); + parse = emalloc_zero(sizeof(*parse)); parse->generic = peer->procptr; /* link up */ parse->generic->unitptr = (caddr_t)parse; /* link down */ @@ -2879,9 +3060,9 @@ parse_start( parse->kv = (struct ctl_var *)0; clear_err(parse, ERR_ALL); - + parse->parse_type = &parse_clockinfo[type]; - + parse->maxunsync = parse->parse_type->cl_maxunsync; parse->generic->fudgetime1 = parse->parse_type->cl_basedelay; @@ -2894,16 +3075,16 @@ parse_start( peer->rootdelay = parse->parse_type->cl_rootdelay; peer->sstclktype = parse->parse_type->cl_type; peer->precision = sys_precision; - + peer->stratum = STRATUM_REFCLOCK; if (peer->stratum <= 1) memmove((char *)&parse->generic->refid, parse->parse_type->cl_id, 4); else parse->generic->refid = htonl(PARSEHSREFID); - + parse->generic->io.fd = fd232; - + parse->peer = peer; /* marks it also as busy */ /* @@ -2946,15 +3127,15 @@ parse_start( } #endif - tio.c_cflag = parse_clockinfo[type].cl_cflag; - tio.c_iflag = parse_clockinfo[type].cl_iflag; - tio.c_oflag = parse_clockinfo[type].cl_oflag; - tio.c_lflag = parse_clockinfo[type].cl_lflag; - + tio.c_cflag = (tcflag_t) parse_clockinfo[type].cl_cflag; + tio.c_iflag = (tcflag_t) parse_clockinfo[type].cl_iflag; + tio.c_oflag = (tcflag_t) parse_clockinfo[type].cl_oflag; + tio.c_lflag = (tcflag_t) parse_clockinfo[type].cl_lflag; + #ifdef HAVE_TERMIOS - if ((cfsetospeed(&tio, parse_clockinfo[type].cl_speed) == -1) || - (cfsetispeed(&tio, parse_clockinfo[type].cl_speed) == -1)) + if ((cfsetospeed(&tio, (speed_t) parse_clockinfo[type].cl_speed) == -1) || + (cfsetispeed(&tio, (speed_t) parse_clockinfo[type].cl_speed) == -1)) { msyslog(LOG_ERR, "PARSE receiver #%d: parse_start: tcset{i,o}speed(&tio, speed): %m", unit); parse_shutdown(CLK_UNIT(parse->peer), peer); /* let our cleaning staff do the work */ @@ -2969,11 +3150,7 @@ parse_start( * if the PARSEPPSDEVICE can be opened that will be used * for PPS else PARSEDEVICE will be used */ - parse->ppsfd = open(parseppsdev, O_RDWR | O_NOCTTY -#ifdef O_NONBLOCK - | O_NONBLOCK -#endif - , 0777); + parse->ppsfd = tty_open(parseppsdev, O_RDWR | O_NOCTTY | O_NONBLOCK, 0777); if (parse->ppsfd == -1) { @@ -3018,7 +3195,7 @@ parse_start( if (CLK_PPS(parse->peer)) { int i = 1; - + if (ioctl(parse->ppsfd, TIOCSPPS, (caddr_t)&i) == 0) { parse->flags |= PARSE_PPSCLOCK; @@ -3033,7 +3210,7 @@ parse_start( parse->hardppsstate = PARSE_HARDPPS_DISABLE; if (CLK_PPS(parse->peer)) { - if (time_pps_create(parse->ppsfd, &parse->ppshandle) < 0) + if (!refclock_ppsapi(parse->ppsfd, &parse->atom)) { msyslog(LOG_NOTICE, "PARSE receiver #%d: parse_start: could not set up PPS: %m", CLK_UNIT(parse->peer)); } @@ -3055,9 +3232,9 @@ parse_start( /* * pick correct input machine */ - parse->generic->io.srcclock = (caddr_t)parse; + parse->generic->io.srcclock = peer; parse->generic->io.datalen = 0; - + parse->binding = init_iobinding(parse); if (parse->binding == (bind_t *)0) @@ -3065,7 +3242,7 @@ parse_start( msyslog(LOG_ERR, "PARSE receiver #%d: parse_start: io sub system initialisation failed.", CLK_UNIT(parse->peer)); parse_shutdown(CLK_UNIT(parse->peer), peer); /* let our cleaning staff do the work */ return 0; /* well, ok - special initialisation broke */ - } + } parse->generic->io.clock_recv = parse->binding->bd_receive; /* pick correct receive routine */ parse->generic->io.io_input = parse->binding->bd_io_input; /* pick correct input routine */ @@ -3103,9 +3280,9 @@ parse_start( parse_shutdown(CLK_UNIT(parse->peer), peer); /* let our cleaning staff do the work */ return 0; /* well, ok - special initialisation broke */ } - - strncpy(tmp_ctl.parseformat.parse_buffer, parse->parse_type->cl_format, sizeof(tmp_ctl.parseformat.parse_buffer)); - tmp_ctl.parseformat.parse_count = strlen(tmp_ctl.parseformat.parse_buffer); + + strlcpy(tmp_ctl.parseformat.parse_buffer, parse->parse_type->cl_format, sizeof(tmp_ctl.parseformat.parse_buffer)); + tmp_ctl.parseformat.parse_count = (u_short) strlen(tmp_ctl.parseformat.parse_buffer); if (!PARSE_SETFMT(parse, &tmp_ctl)) { @@ -3113,7 +3290,7 @@ parse_start( parse_shutdown(CLK_UNIT(parse->peer), peer); /* let our cleaning staff do the work */ return 0; /* well, ok - special initialisation broke */ } - + /* * get rid of all IO accumulated so far */ @@ -3140,7 +3317,7 @@ parse_start( return 0; /* well, ok - special initialisation broke */ } } - + /* * Insert in async io device list. */ @@ -3198,15 +3375,15 @@ parse_start( static void parse_ctl( struct parseunit *parse, - struct refclockstat *in + const struct refclockstat *in ) { if (in) { if (in->haveflags & (CLK_HAVEFLAG1|CLK_HAVEFLAG2|CLK_HAVEFLAG3|CLK_HAVEFLAG4)) { - parse->flags = (parse->flags & ~(CLK_FLAG1|CLK_FLAG2|CLK_FLAG3|CLK_FLAG4)) | - (in->flags & (CLK_FLAG1|CLK_FLAG2|CLK_FLAG3|CLK_FLAG4)); + u_char mask = CLK_FLAG1|CLK_FLAG2|CLK_FLAG3|CLK_FLAG4; + parse->flags = (parse->flags & (u_char)(~mask)) | (in->flags & mask); #if defined(HAVE_PPSAPI) if (CLK_PPS(parse->peer)) { @@ -3214,7 +3391,7 @@ parse_ctl( } #endif } - + if (in->haveflags & CLK_HAVETIME1) { parse->generic->fudgetime1 = in->fudgetime1; @@ -3222,11 +3399,11 @@ parse_ctl( CLK_UNIT(parse->peer), parse->generic->fudgetime1); } - + if (in->haveflags & CLK_HAVETIME2) { parse->generic->fudgetime2 = in->fudgetime2; - if (parse->flags & PARSE_TRUSTTIME) + if (parse->flags & PARSE_TRUSTTIME) { parse->maxunsync = (u_long)ABS(in->fudgetime2); msyslog(LOG_INFO, "PARSE receiver #%d: new trust time %s", @@ -3259,7 +3436,7 @@ parse_poll( struct peer *peer ) { - struct parseunit *parse = (struct parseunit *)peer->procptr->unitptr; + struct parseunit *parse = peer->procptr->unitptr; if (peer != parse->peer) { @@ -3274,8 +3451,8 @@ parse_poll( */ parse->generic->polls++; - if (parse->pollneeddata && - ((current_time - parse->pollneeddata) > (1<<(max(min(parse->peer->hpoll, parse->peer->ppoll), parse->peer->minpoll))))) + if (parse->pollneeddata && + ((int)(current_time - parse->pollneeddata) > (1<<(max(min(parse->peer->hpoll, parse->peer->ppoll), parse->peer->minpoll))))) { /* * start worrying when exceeding a poll inteval @@ -3283,7 +3460,7 @@ parse_poll( */ parse->lastmissed = current_time; parse_event(parse, CEVNT_TIMEOUT); - + ERR(ERR_NODATA) msyslog(LOG_WARNING, "PARSE receiver #%d: no data from device within poll interval (check receiver / wiring)", CLK_UNIT(parse->peer)); } @@ -3311,12 +3488,12 @@ parse_poll( static void parse_control( int unit, - struct refclockstat *in, + const struct refclockstat *in, struct refclockstat *out, struct peer *peer ) { - struct parseunit *parse = (struct parseunit *)peer->procptr->unitptr; + struct parseunit *parse = peer->procptr->unitptr; parsectl_t tmpctl; static char outstatus[400]; /* status output buffer */ @@ -3341,7 +3518,7 @@ parse_control( * handle changes */ parse_ctl(parse, in); - + /* * supply data */ @@ -3388,16 +3565,16 @@ parse_control( } start = tt = add_var(&out->kv_list, 128, RO|DEF); - snprintf(tt, 128, "refclock_time=\""); - tt += strlen(tt); + tt = ap(start, 128, tt, "refclock_time=\""); if (parse->timedata.parse_time.fp.l_ui == 0) { - strncpy(tt, "\"", BUFFER_SIZES(start, tt, 128)); + tt = ap(start, 128, tt, "\""); } else { - snprintf(tt, 128, "%s\"", gmprettydate(&parse->timedata.parse_time.fp)); + tt = ap(start, 128, tt, "%s\"", + gmprettydate(&parse->timedata.parse_time.fp)); } if (!PARSE_GETTIMECODE(parse, &tmpctl)) @@ -3408,8 +3585,7 @@ parse_control( else { start = tt = add_var(&out->kv_list, 512, RO|DEF); - snprintf(tt, 512, "refclock_status=\""); - tt += strlen(tt); + tt = ap(start, 512, tt, "refclock_status=\""); /* * copy PPS flags from last read transaction (informational only) @@ -3417,18 +3593,20 @@ parse_control( tmpctl.parsegettc.parse_state |= parse->timedata.parse_state & (PARSEB_PPS|PARSEB_S_PPS); - (void) parsestate(tmpctl.parsegettc.parse_state, tt, BUFFER_SIZES(start, tt, 512)); + (void)parsestate(tmpctl.parsegettc.parse_state, tt, BUFFER_SIZES(start, tt, 512)); + + tt += strlen(tt); - strncat(tt, "\"", BUFFER_SIZES(start, tt, 512)); + tt = ap(start, 512, tt, "\""); if (tmpctl.parsegettc.parse_count) mkascii(outstatus+strlen(outstatus), (int)(sizeof(outstatus)- strlen(outstatus) - 1), tmpctl.parsegettc.parse_buffer, (unsigned)(tmpctl.parsegettc.parse_count)); } - + tmpctl.parseformat.parse_format = tmpctl.parsegettc.parse_format; - + if (!PARSE_GETFMT(parse, &tmpctl)) { ERR(ERR_INTERNAL) @@ -3436,11 +3614,19 @@ parse_control( } else { - tt = add_var(&out->kv_list, 80, RO|DEF); - snprintf(tt, 80, "refclock_format=\""); + int count = tmpctl.parseformat.parse_count - 1; + + start = tt = add_var(&out->kv_list, 80, RO|DEF); + tt = ap(start, 80, tt, "refclock_format=\""); + + if (count > 0) { + tt = ap(start, 80, tt, "%*.*s", + count, + count, + tmpctl.parseformat.parse_buffer); + } - strncat(tt, tmpctl.parseformat.parse_buffer, tmpctl.parseformat.parse_count); - strncat(tt,"\"", 80); + tt = ap(start, 80, tt, "\""); } /* @@ -3448,8 +3634,7 @@ parse_control( */ start = tt = add_var(&out->kv_list, LEN_STATES, RO|DEF); - strncpy(tt, "refclock_states=\"", LEN_STATES); - tt += strlen(tt); + tt = ap(start, LEN_STATES, tt, "refclock_states=\""); for (i = 0; i <= CEVNT_MAX; i++) { @@ -3464,7 +3649,7 @@ parse_control( percent /= 10; d /= 10; } - + if (d) percent = (percent * 10000) / d; else @@ -3474,36 +3659,37 @@ parse_control( { char item[80]; int count; - + snprintf(item, 80, "%s%s%s: %s (%d.%02d%%)", sum ? "; " : "", (parse->generic->currentstatus == i) ? "*" : "", clockstatus((unsigned int)i), l_mktime(s_time), (int)(percent / 100), (int)(percent % 100)); - if ((count = strlen(item)) < (LEN_STATES - 40 - (tt - start))) + if ((count = (int) strlen(item)) < (LEN_STATES - 40 - (tt - start))) { - strncpy(tt, item, BUFFER_SIZES(start, tt, LEN_STATES)); - tt += count; + tt = ap(start, LEN_STATES, tt, + "%s", item); } sum += s_time; } } - - snprintf(tt, BUFFER_SIZES(start, tt, LEN_STATES), "; running time: %s\"", l_mktime(sum)); - + + tt = ap(start, LEN_STATES, tt, + "; running time: %s\"", l_mktime(sum)); + tt = add_var(&out->kv_list, 32, RO); snprintf(tt, 32, "refclock_id=\"%s\"", parse->parse_type->cl_id); - + tt = add_var(&out->kv_list, 80, RO); snprintf(tt, 80, "refclock_iomode=\"%s\"", parse->binding->bd_description); tt = add_var(&out->kv_list, 128, RO); snprintf(tt, 128, "refclock_driver_version=\"%s\"", rcsid); - + { struct ctl_var *k; - + k = parse->kv; while (k && !(k->flags & EOV)) { @@ -3511,8 +3697,8 @@ parse_control( k++; } } - - out->lencode = strlen(outstatus); + + out->lencode = (u_short) strlen(outstatus); out->p_lastcode = outstatus; } } @@ -3538,7 +3724,7 @@ parse_event( if (parse->parse_type->cl_event) parse->parse_type->cl_event(parse, event); - + if (event == CEVNT_NOMINAL) { NLOG(NLOG_CLOCKSTATUS) @@ -3561,7 +3747,10 @@ parse_process( { l_fp off, rectime, reftime; double fudge; - + + /* silence warning: 'off.Ul_i.Xl_i' may be used uninitialized in this function */ + ZERO(off); + /* * check for changes in conversion status * (only one for each new status !) @@ -3571,11 +3760,11 @@ parse_process( (parse->timedata.parse_status != parsetime->parse_status)) { char buffer[400]; - + NLOG(NLOG_CLOCKINFO) /* conditional if clause for conditional syslog */ msyslog(LOG_WARNING, "PARSE receiver #%d: conversion status \"%s\"", CLK_UNIT(parse->peer), parsestatus(parsetime->parse_status, buffer, sizeof(buffer))); - + if ((parsetime->parse_status & CVT_MASK) == CVT_FAIL) { /* @@ -3584,7 +3773,7 @@ parse_process( * the time code might be overwritten by the next packet */ parsectl_t tmpctl; - + if (!PARSE_GETTIMECODE(parse, &tmpctl)) { ERR(ERR_INTERNAL) @@ -3596,6 +3785,8 @@ parse_process( msyslog(LOG_WARNING, "PARSE receiver #%d: FAILED TIMECODE: \"%s\" (check receiver configuration / wiring)", CLK_UNIT(parse->peer), mkascii(buffer, sizeof buffer, tmpctl.parsegettc.parse_buffer, (unsigned)(tmpctl.parsegettc.parse_count - 1))); } + /* copy status to show only changes in case of failures */ + parse->timedata.parse_status = parsetime->parse_status; } } @@ -3622,7 +3813,7 @@ parse_process( parse->timedata.parse_ptime = parsetime->parse_ptime; } break; /* well, still waiting - timeout is handled at higher levels */ - + case CVT_FAIL: if (parsetime->parse_status & CVT_BADFMT) { @@ -3653,7 +3844,7 @@ parse_process( if (parse->lastformat != parsetime->parse_format) { parsectl_t tmpctl; - + tmpctl.parseformat.parse_format = parsetime->parse_format; if (!PARSE_GETFMT(parse, &tmpctl)) @@ -3681,10 +3872,10 @@ parse_process( /* * something happend - except for PPS events */ - + (void) parsestate(parsetime->parse_state, tmp1, sizeof(tmp1)); (void) parsestate(parse->timedata.parse_state, tmp2, sizeof(tmp2)); - + NLOG(NLOG_CLOCKINFO) /* conditional if clause for conditional syslog */ msyslog(LOG_INFO,"PARSE receiver #%d: STATE CHANGE: %s -> %s", CLK_UNIT(parse->peer), tmp2, tmp1); @@ -3716,7 +3907,7 @@ parse_process( * for PARSE Meinberg DCF77 receivers the lost synchronisation * is true as it is the powerup state and the time is taken * from a crude real time clock chip - * for the PZF series this is only partly true, as + * for the PZF/GPS series this is only partly true, as * PARSE_POWERUP only means that the pseudo random * phase shift sequence cannot be found. this is only * bad, if we have never seen the clock in the SYNC @@ -3734,11 +3925,14 @@ parse_process( * interval. fortunately powerdowns last usually longer than 64 * seconds and the receiver is at least 2 minutes in the * POWERUP or NOSYNC state before switching to SYNC + * for GPS receivers this can mean antenna problems and other causes. + * the additional grace period can be enables by a clock + * mode having the PARSE_F_POWERUPTRUST flag in cl_flag set. */ parse_event(parse, CEVNT_FAULT); NLOG(NLOG_CLOCKSTATUS) ERR(ERR_BADSTATUS) - msyslog(LOG_ERR,"PARSE receiver #%d: NOT SYNCHRONIZED", + msyslog(LOG_ERR,"PARSE receiver #%d: NOT SYNCHRONIZED/RECEIVER PROBLEMS", CLK_UNIT(parse->peer)); } else @@ -3784,12 +3978,12 @@ parse_process( } fudge = parse->generic->fudgetime1; /* standard RS232 Fudgefactor */ - + if (PARSE_TIMECODE(parsetime->parse_state)) { rectime = parsetime->parse_stime.fp; off = reftime = parsetime->parse_time.fp; - + L_SUB(&off, &rectime); /* prepare for PPS adjustments logic */ #ifdef DEBUG @@ -3811,7 +4005,7 @@ parse_process( /* * set fudge = 0.0 if already included in PPS time stamps */ - if (parse->ppsparams.mode & (PPS_OFFSETCLEAR|PPS_OFFSETASSERT)) + if (parse->atom.pps_params.mode & (PPS_OFFSETCLEAR|PPS_OFFSETASSERT)) { ppsphaseadjust = 0.0; } @@ -3830,11 +4024,11 @@ parse_process( #endif if (PARSE_TIMECODE(parsetime->parse_state)) { - if (M_ISGEQ(off.l_i, off.l_f, -1, 0x80000000) && - M_ISGEQ(0, 0x7fffffff, off.l_i, off.l_f)) + if (M_ISGEQ(off.l_i, off.l_uf, -1, 0x80000000) && + M_ISGEQ(0, 0x7fffffff, off.l_i, off.l_uf)) { fudge = ppsphaseadjust; /* pick PPS fudge factor */ - + /* * RS232 offsets within [-0.5..0.5[ - take PPS offsets */ @@ -3842,16 +4036,16 @@ parse_process( if (parse->parse_type->cl_flags & PARSE_F_PPSONSECOND) { reftime = off = offset; - if (reftime.l_uf & (unsigned)0x80000000) + if (reftime.l_uf & 0x80000000) reftime.l_ui++; reftime.l_uf = 0; - + /* * implied on second offset */ off.l_uf = ~off.l_uf; /* map [0.5..1[ -> [-0.5..0[ */ - off.l_ui = (off.l_f < 0) ? ~0 : 0; /* sign extend */ + off.l_i = (off.l_uf & 0x80000000) ? -1 : 0; /* sign extend */ } else { @@ -3876,14 +4070,14 @@ parse_process( */ off = offset; reftime = offset; - if (reftime.l_uf & (unsigned)0x80000000) + if (reftime.l_uf & 0x80000000) reftime.l_ui++; reftime.l_uf = 0; /* * implied on second offset */ off.l_uf = ~off.l_uf; /* map [0.5..1[ -> [-0.5..0[ */ - off.l_ui = (off.l_f < 0) ? ~0 : 0; /* sign extend */ + off.l_i = (off.l_uf & 0x80000000) ? -1 : 0; /* sign extend */ } } else @@ -3912,7 +4106,7 @@ parse_process( rectime = reftime; L_SUB(&rectime, &off); /* just to keep the ntp interface happy */ - + #ifdef DEBUG if (debug > 3) printf("PARSE receiver #%d: calculated Reftime %s, Recvtime %s\n", @@ -3937,20 +4131,21 @@ parse_process( clear_err(parse, ERR_BADDATA); clear_err(parse, ERR_NODATA); clear_err(parse, ERR_INTERNAL); - + /* * and now stick it into the clock machine * samples are only valid iff lastsync is not too old and * we have seen the clock in sync at least once * after the last time we didn't see an expected data telegram * at startup being not in sync is also bad just like - * POWERUP state + * POWERUP state unless PARSE_F_POWERUPTRUST is set * see the clock states section above for more reasoning */ - if (((current_time - parse->lastsync) > parse->maxunsync) || - (parse->lastsync < parse->lastmissed) || + if (((current_time - parse->lastsync) > parse->maxunsync) || + (parse->lastsync < parse->lastmissed) || ((parse->lastsync == 0) && !PARSE_SYNC(parsetime->parse_state)) || - PARSE_POWERUP(parsetime->parse_state)) + (((parse->parse_type->cl_flags & PARSE_F_POWERUPTRUST) == 0) && + PARSE_POWERUP(parsetime->parse_state))) { parse->generic->leap = LEAP_NOTINSYNC; parse->lastsync = 0; /* wait for full sync again */ @@ -3983,9 +4178,9 @@ parse_process( * only good/trusted samples are interesting */ #ifdef DEBUG - if (debug > 2) - { - printf("PARSE receiver #%d: refclock_process_offset(reftime=%s, rectime=%s, Fudge=%f)\n", + if (debug > 2) + { + printf("PARSE receiver #%d: refclock_process_offset(reftime=%s, rectime=%s, Fudge=%f)\n", CLK_UNIT(parse->peer), prettydate(&reftime), prettydate(&rectime), @@ -3993,23 +4188,26 @@ parse_process( } #endif parse->generic->lastref = reftime; - + refclock_process_offset(parse->generic, reftime, rectime, fudge); +#ifdef HAVE_PPSAPI /* * pass PPS information on to PPS clock */ if (PARSE_PPS(parsetime->parse_state) && CLK_PPS(parse->peer)) - { - (void) pps_sample(&parse->timedata.parse_ptime.fp); + { + parse->peer->flags |= (FLAG_PPS | FLAG_TSTAMP_PPS); parse_hardpps(parse, PARSE_HARDPPS_ENABLE); } +#endif } else { - parse_hardpps(parse, PARSE_HARDPPS_DISABLE); + parse_hardpps(parse, PARSE_HARDPPS_DISABLE); + parse->peer->flags &= ~(FLAG_PPS | FLAG_TSTAMP_PPS); } /* - * ready, unless the machine wants a sample or + * ready, unless the machine wants a sample or * we are in fast startup mode (peer->dist > MAXDISTANCE) */ if (!parse->pollneeddata && parse->peer->disp <= MAXDISTANCE) @@ -4021,56 +4219,71 @@ parse_process( refclock_receive(parse->peer); } - + /**=========================================================================== ** special code for special clocks **/ static void mk_utcinfo( - char *t, + char *t, // pointer to the output string buffer int wnt, int wnlsf, int dn, int dtls, int dtlsf, - int size + int size // size of the output string buffer ) { - l_fp leapdate; - char *start = t; - - snprintf(t, size, "current correction %d sec", dtls); - t += strlen(t); - - if (wnlsf < 990) - wnlsf += 1024; - - if (wnt < 990) - wnt += 1024; - - gpstolfp((unsigned short)wnlsf, (unsigned short)dn, 0, &leapdate); - - if ((dtlsf != dtls) && - ((wnlsf - wnt) < 52)) - { - snprintf(t, BUFFER_SIZES(start, t, size), ", next correction %d sec on %s, new GPS-UTC offset %d", - dtlsf - dtls, gmprettydate(&leapdate), dtlsf); - } - else - { - snprintf(t, BUFFER_SIZES(start, t, size), ", last correction on %s", - gmprettydate(&leapdate)); - } + /* + * The week number transmitted by the GPS satellites for the leap date + * is truncated to 8 bits only. If the nearest leap second date is off + * the current date by more than +/- 128 weeks then conversion to a + * calendar date is ambiguous. On the other hand, if a leap second is + * currently being announced (i.e. dtlsf != dtls) then the week number + * wnlsf is close enough, and we can unambiguously determine the date + * for which the leap second is scheduled. + */ + if ( dtlsf != dtls ) + { + time_t t_ls; + struct tm *tm; + int n = 0; + + if (wnlsf < GPSWRAP) + wnlsf += GPSWEEKS; + + if (wnt < GPSWRAP) + wnt += GPSWEEKS; + + t_ls = (time_t) wnlsf * SECSPERWEEK + + (time_t) dn * SECSPERDAY + + GPS_SEC_BIAS - 1; + + tm = gmtime( &t_ls ); + if (tm == NULL) // gmtime() failed + { + snprintf( t, size, "** (gmtime() failed in mk_utcinfo())" ); + return; + } + + n += snprintf( t, size, "UTC offset transition from %is to %is due to leap second %s", + dtls, dtlsf, ( dtls < dtlsf ) ? "insertion" : "deletion" ); + n += snprintf( t + n, size - n, " at UTC midnight at the end of %s, %04i-%02i-%02i", + daynames[tm->tm_wday], tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday ); + } + else + snprintf( t, size, "UTC offset parameter: %is, no leap second announced.\n", dtls ); + } #ifdef CLOCK_MEINBERG /**=========================================================================== - ** Meinberg GPS166/GPS167 support + ** Meinberg GPS receiver support **/ /*------------------------------------------------------------ - * gps16x_message - process GPS16x messages + * gps16x_message - process messages from Meinberg GPS receiver */ static void gps16x_message( @@ -4082,12 +4295,12 @@ gps16x_message( { GPS_MSG_HDR header; unsigned char *bufp = (unsigned char *)parsetime->parse_msg + 1; - + #ifdef DEBUG if (debug > 2) { char msgbuffer[600]; - + mkreadable(msgbuffer, sizeof(msgbuffer), (char *)parsetime->parse_msg, parsetime->parse_msglen, 1); printf("PARSE receiver #%d: received message (%d bytes) >%s<\n", CLK_UNIT(parse->peer), @@ -4096,21 +4309,21 @@ gps16x_message( } #endif get_mbg_header(&bufp, &header); - if (header.gps_hdr_csum == mbg_csum(parsetime->parse_msg + 1, 6) && - (header.gps_len == 0 || - (header.gps_len < sizeof(parsetime->parse_msg) && - header.gps_data_csum == mbg_csum(bufp, header.gps_len)))) + if (header.hdr_csum == mbg_csum(parsetime->parse_msg + 1, 6) && + (header.len == 0 || + (header.len < sizeof(parsetime->parse_msg) && + header.data_csum == mbg_csum(bufp, header.len)))) { /* * clean message */ - switch (header.gps_cmd) + switch (header.cmd) { case GPS_SW_REV: { char buffer[64]; SW_REV gps_sw_rev; - + get_mbg_sw_rev(&bufp, &gps_sw_rev); snprintf(buffer, sizeof(buffer), "meinberg_gps_version=\"%x.%02x%s%s\"", (gps_sw_rev.code >> 8) & 0xFF, @@ -4121,54 +4334,56 @@ gps16x_message( } break; - case GPS_STAT: + case GPS_BVAR_STAT: { static struct state { - unsigned short flag; /* status flag */ - unsigned const char *string; /* bit name */ + BVAR_STAT flag; /* status flag */ + const char *string; /* bit name */ } states[] = { - { TM_ANT_DISCONN, (const unsigned char *)"ANTENNA FAULTY" }, - { TM_SYN_FLAG, (const unsigned char *)"NO SYNC SIGNAL" }, - { TM_NO_SYNC, (const unsigned char *)"NO SYNC POWERUP" }, - { TM_NO_POS, (const unsigned char *)"NO POSITION" }, - { 0, (const unsigned char *)"" } + { BVAR_CFGH_INVALID, "Configuration/Health" }, + { BVAR_ALM_NOT_COMPLETE, "Almanachs" }, + { BVAR_UTC_INVALID, "UTC Correction" }, + { BVAR_IONO_INVALID, "Ionospheric Correction" }, + { BVAR_RCVR_POS_INVALID, "Receiver Position" }, + { 0, "" } }; - unsigned short status; + BVAR_STAT status; struct state *s = states; char buffer[512]; char *p, *b; - - status = get_lsb_short(&bufp); - snprintf(buffer, sizeof(buffer), "meinberg_gps_status=\"[0x%04x] ", status); - + + status = (BVAR_STAT) get_lsb_short(&bufp); + p = b = buffer; + p = ap(buffer, sizeof(buffer), p, + "meinberg_gps_status=\"[0x%04x] ", + status); + if (status) { - p = b = buffer + strlen(buffer); + p = ap(buffer, sizeof(buffer), p, "incomplete buffered data: "); + b = p; while (s->flag) { if (status & s->flag) { if (p != b) { - *p++ = ','; - *p++ = ' '; + p = ap(buffer, sizeof(buffer), p, ", "); } - - strncat(p, (const char *)s->string, sizeof(buffer)); + + p = ap(buffer, sizeof(buffer), p, "%s", (const char *)s->string); } s++; } - - *p++ = '"'; - *p = '\0'; + p = ap(buffer, sizeof(buffer), p, "\""); } else { - strncat(buffer, "\"", sizeof(buffer)); + p = ap(buffer, sizeof(buffer), p, "\""); } - + set_var(&parse->kv, buffer, strlen(buffer)+1, RO|DEF); } break; @@ -4177,282 +4392,259 @@ gps16x_message( { XYZ xyz; char buffer[256]; - + get_mbg_xyz(&bufp, xyz); snprintf(buffer, sizeof(buffer), "gps_position(XYZ)=\"%s m, %s m, %s m\"", mfptoa(xyz[XP].l_ui, xyz[XP].l_uf, 1), mfptoa(xyz[YP].l_ui, xyz[YP].l_uf, 1), mfptoa(xyz[ZP].l_ui, xyz[ZP].l_uf, 1)); - + set_var(&parse->kv, buffer, sizeof(buffer), RO|DEF); } break; - + case GPS_POS_LLA: { LLA lla; char buffer[256]; - + get_mbg_lla(&bufp, lla); - + snprintf(buffer, sizeof(buffer), "gps_position(LLA)=\"%s deg, %s deg, %s m\"", mfptoa(lla[LAT].l_ui, lla[LAT].l_uf, 4), - mfptoa(lla[LON].l_ui, lla[LON].l_uf, 4), + mfptoa(lla[LON].l_ui, lla[LON].l_uf, 4), mfptoa(lla[ALT].l_ui, lla[ALT].l_uf, 1)); - + set_var(&parse->kv, buffer, sizeof(buffer), RO|DEF); } break; - + case GPS_TZDL: break; - + case GPS_PORT_PARM: break; - + case GPS_SYNTH: break; - + case GPS_ANT_INFO: { ANT_INFO antinfo; char buffer[512]; - char *p; - + char *p, *q; + get_mbg_antinfo(&bufp, &antinfo); - snprintf(buffer, sizeof(buffer), "meinberg_antenna_status=\""); - p = buffer + strlen(buffer); - + p = buffer; + p = ap(buffer, sizeof(buffer), p, "meinberg_antenna_status=\""); switch (antinfo.status) { - case ANT_INVALID: - strncat(p, "", BUFFER_SIZE(buffer, p)); - p += strlen(p); + case ANT_INVALID: // No other fields valid since antenna has not yet been disconnected + p = ap(buffer, sizeof(buffer), + p, ""); break; - - case ANT_DISCONN: - strncat(p, "DISCONNECTED since ", BUFFER_SIZE(buffer, p)); + + case ANT_DISCONN: // Antenna is disconnected, tm_reconn and delta_t not yet set + q = ap(buffer, sizeof(buffer), + p, "DISCONNECTED since "); NLOG(NLOG_CLOCKSTATUS) ERR(ERR_BADSTATUS) msyslog(LOG_ERR,"PARSE receiver #%d: ANTENNA FAILURE: %s", CLK_UNIT(parse->peer), p); - - p += strlen(p); - mbg_tm_str(&p, &antinfo.tm_disconn, BUFFER_SIZE(buffer, p)); + + p = q; + mbg_tm_str(&p, &antinfo.tm_disconn, BUFFER_SIZE(buffer, p), 0); *p = '\0'; break; - - case ANT_RECONN: - strncat(p, "RECONNECTED on ", BUFFER_SIZE(buffer, p)); - p += strlen(p); - mbg_tm_str(&p, &antinfo.tm_reconn, BUFFER_SIZE(buffer, p)); - snprintf(p, BUFFER_SIZE(buffer, p), ", reconnect clockoffset %c%ld.%07ld s, disconnect time ", + + case ANT_RECONN: // Antenna had been disconnect, but receiver sync. after reconnect, so all fields valid + p = ap(buffer, sizeof(buffer), + p, "SYNC AFTER RECONNECT on "); + mbg_tm_str(&p, &antinfo.tm_reconn, BUFFER_SIZE(buffer, p), 0); + p = ap(buffer, sizeof(buffer), + p, ", clock offset at reconnect %c%ld.%07ld s, disconnect time ", (antinfo.delta_t < 0) ? '-' : '+', - ABS(antinfo.delta_t) / 10000, - ABS(antinfo.delta_t) % 10000); - p += strlen(p); - mbg_tm_str(&p, &antinfo.tm_disconn, BUFFER_SIZE(buffer, p)); + (long) ABS(antinfo.delta_t) / 10000, + (long) ABS(antinfo.delta_t) % 10000); + mbg_tm_str(&p, &antinfo.tm_disconn, BUFFER_SIZE(buffer, p), 0); *p = '\0'; break; - + default: - snprintf(p, BUFFER_SIZE(buffer, p), "bad status 0x%04x", antinfo.status); - p += strlen(p); + p = ap(buffer, sizeof(buffer), + p, "bad status 0x%04x", + antinfo.status); break; } - - strncat(p, "\"", BUFFER_SIZE(buffer, p)); - - set_var(&parse->kv, buffer, strlen(buffer)+1, RO|DEF); + + p = ap(buffer, sizeof(buffer), p, "\""); + + set_var(&parse->kv, buffer, sizeof(buffer), RO|DEF); } break; - + case GPS_UCAP: break; - + case GPS_CFGH: { CFGH cfgh; char buffer[512]; char *p; - + get_mbg_cfgh(&bufp, &cfgh); if (cfgh.valid) { + const char *cp; + uint16_t tmp_val; int i; - + p = buffer; - strncpy(buffer, "gps_tot_51=\"", BUFFER_SIZE(buffer, p)); - p += strlen(p); + p = ap(buffer, sizeof(buffer), + p, "gps_tot_51=\""); mbg_tgps_str(&p, &cfgh.tot_51, BUFFER_SIZE(buffer, p)); - strncpy(p, "\"", BUFFER_SIZE(buffer, p)); - set_var(&parse->kv, buffer, strlen(buffer)+1, RO); - + p = ap(buffer, sizeof(buffer), + p, "\""); + set_var(&parse->kv, buffer, sizeof(buffer), RO|COND_DEF); + p = buffer; - strncpy(buffer, "gps_tot_63=\"", BUFFER_SIZE(buffer, p)); - p += strlen(p); + p = ap(buffer, sizeof(buffer), + p, "gps_tot_63=\""); mbg_tgps_str(&p, &cfgh.tot_63, BUFFER_SIZE(buffer, p)); - strncpy(p, "\"", BUFFER_SIZE(buffer, p)); - set_var(&parse->kv, buffer, strlen(buffer)+1, RO); - + p = ap(buffer, sizeof(buffer), + p, "\""); + set_var(&parse->kv, buffer, sizeof(buffer), RO|COND_DEF); + p = buffer; - strncpy(buffer, "gps_t0a=\"", BUFFER_SIZE(buffer, p)); - p += strlen(p); + p = ap(buffer, sizeof(buffer), + p, "gps_t0a=\""); mbg_tgps_str(&p, &cfgh.t0a, BUFFER_SIZE(buffer, p)); - strncpy(p, "\"", BUFFER_SIZE(buffer, p)); - set_var(&parse->kv, buffer, strlen(buffer)+1, RO); - - for (i = MIN_SVNO; i < MAX_SVNO; i++) + p = ap(buffer, sizeof(buffer), + p, "\""); + set_var(&parse->kv, buffer, sizeof(buffer), RO|COND_DEF); + + for (i = 0; i < N_SVNO_GPS; i++) { p = buffer; - snprintf(p, BUFFER_SIZE(buffer, p), "gps_cfg[%d]=\"[0x%x] ", i, cfgh.cfg[i]); - p += strlen(p); - switch (cfgh.cfg[i] & 0x7) - { - case 0: - strncpy(p, "BLOCK I", BUFFER_SIZE(buffer, p)); - break; - case 1: - strncpy(p, "BLOCK II", BUFFER_SIZE(buffer, p)); - break; - default: - strncpy(p, "bad CFG", BUFFER_SIZE(buffer, p)); - break; - } - strncat(p, "\"", BUFFER_SIZE(buffer, p)); - set_var(&parse->kv, buffer, strlen(buffer)+1, RO); - - p = buffer; - snprintf(p, BUFFER_SIZE(buffer, p), "gps_health[%d]=\"[0x%x] ", i, cfgh.health[i]); - p += strlen(p); - switch ((cfgh.health[i] >> 5) & 0x7 ) - { - case 0: - strncpy(p, "OK;", BUFFER_SIZE(buffer, p)); - break; - case 1: - strncpy(p, "PARITY;", BUFFER_SIZE(buffer, p)); - break; - case 2: - strncpy(p, "TLM/HOW;", BUFFER_SIZE(buffer, p)); - break; - case 3: - strncpy(p, "Z-COUNT;", BUFFER_SIZE(buffer, p)); - break; - case 4: - strncpy(p, "SUBFRAME 1,2,3;", BUFFER_SIZE(buffer, p)); - break; - case 5: - strncpy(p, "SUBFRAME 4,5;", BUFFER_SIZE(buffer, p)); - break; - case 6: - strncpy(p, "UPLOAD BAD;", BUFFER_SIZE(buffer, p)); - break; - case 7: - strncpy(p, "DATA BAD;", BUFFER_SIZE(buffer, p)); - break; + p = ap(buffer, sizeof(buffer), p, "sv_info[%d]=\"PRN%d", i, i + N_SVNO_GPS); + + tmp_val = cfgh.health[i]; /* a 6 bit SV health code */ + p = ap(buffer, sizeof(buffer), p, "; health=0x%02x (", tmp_val); + /* "All Ones" has a special meaning" */ + if (tmp_val == 0x3F) /* satellite is unusable or doesn't even exist */ + cp = "SV UNAVAILABLE"; + else { + /* The MSB contains a summary of the 3 MSBs of the 8 bit health code, + * indicating if the data sent by the satellite is OK or not. */ + p = ap(buffer, sizeof(buffer), p, "DATA %s, ", (tmp_val & 0x20) ? "BAD" : "OK" ); + + /* The 5 LSBs contain the status of the different signals sent by the satellite. */ + switch (tmp_val & 0x1F) + { + case 0x00: cp = "SIGNAL OK"; break; + /* codes 0x01 through 0x1B indicate that one or more + * specific signal components are weak or dead. + * We don't decode this here in detail. */ + case 0x1C: cp = "SV IS TEMP OUT"; break; + case 0x1D: cp = "SV WILL BE TEMP OUT"; break; + default: cp = "TRANSMISSION PROBLEMS"; break; + } } - - p += strlen(p); - - switch (cfgh.health[i] & 0x1F) + p = ap(buffer, sizeof(buffer), p, "%s)", cp ); + + tmp_val = cfgh.cfg[i]; /* a 4 bit SV configuration/type code */ + p = ap(buffer, sizeof(buffer), p, "; cfg=0x%02x (", tmp_val); + switch (tmp_val & 0x7) { - case 0: - strncpy(p, "SIGNAL OK", BUFFER_SIZE(buffer, p)); - break; - case 0x1C: - strncpy(p, "SV TEMP OUT", BUFFER_SIZE(buffer, p)); - break; - case 0x1D: - strncpy(p, "SV WILL BE TEMP OUT", BUFFER_SIZE(buffer, p)); - break; - case 0x1E: - break; - case 0x1F: - strncpy(p, "MULTIPLE ERRS", BUFFER_SIZE(buffer, p)); - break; - default: - strncpy(p, "TRANSMISSION PROBLEMS", BUFFER_SIZE(buffer, p)); - break; + case 0x00: cp = "(reserved)"; break; + case 0x01: cp = "BLOCK II/IIA/IIR"; break; + case 0x02: cp = "BLOCK IIR-M"; break; + case 0x03: cp = "BLOCK IIF"; break; + case 0x04: cp = "BLOCK III"; break; + default: cp = "unknown SV type"; break; } - - strncat(p, "\"", sizeof(buffer)); - set_var(&parse->kv, buffer, strlen(buffer)+1, RO); + p = ap(buffer, sizeof(buffer), p, "%s", cp ); + if (tmp_val & 0x08) /* A-S is on, P-code is encrypted */ + p = ap( buffer, sizeof(buffer), p, ", A-S on" ); + + p = ap(buffer, sizeof(buffer), p, ")\""); + set_var(&parse->kv, buffer, sizeof(buffer), RO|COND_DEF); } } } break; - + case GPS_ALM: break; - + case GPS_EPH: break; - + case GPS_UTC: { UTC utc; char buffer[512]; char *p; - + p = buffer; - + get_mbg_utc(&bufp, &utc); - + if (utc.valid) { - strncpy(p, "gps_utc_correction=\"", sizeof(buffer)); - p += strlen(p); + p = ap(buffer, sizeof(buffer), p, "gps_utc_correction=\""); mk_utcinfo(p, utc.t0t.wn, utc.WNlsf, utc.DNt, utc.delta_tls, utc.delta_tlsf, BUFFER_SIZE(buffer, p)); - strncat(p, "\"", BUFFER_SIZE(buffer, p)); + p += strlen(p); + p = ap(buffer, sizeof(buffer), p, "\""); } else { - strncpy(p, "gps_utc_correction=\"\"", BUFFER_SIZE(buffer, p)); + p = ap(buffer, sizeof(buffer), p, "gps_utc_correction=\"\""); } - set_var(&parse->kv, buffer, strlen(buffer)+1, RO|DEF); + set_var(&parse->kv, buffer, sizeof(buffer), RO|DEF); } break; - + case GPS_IONO: break; - + case GPS_ASCII_MSG: { ASCII_MSG gps_ascii_msg; char buffer[128]; - + get_mbg_ascii_msg(&bufp, &gps_ascii_msg); - + if (gps_ascii_msg.valid) { char buffer1[128]; mkreadable(buffer1, sizeof(buffer1), gps_ascii_msg.s, strlen(gps_ascii_msg.s), (int)0); - + snprintf(buffer, sizeof(buffer), "gps_message=\"%s\"", buffer1); } else - strncpy(buffer, "gps_message=", sizeof(buffer)); - - set_var(&parse->kv, buffer, strlen(buffer)+1, RO|DEF); + snprintf(buffer, sizeof(buffer), "gps_message="); + + set_var(&parse->kv, buffer, sizeof(buffer), RO|DEF); } - + break; - + default: break; } } else { - msyslog(LOG_DEBUG, "PARSE receiver #%d: gps16x_message: message checksum error: hdr_csum = 0x%x (expected 0x%lx), data_len = %d, data_csum = 0x%x (expected 0x%lx)", + msyslog(LOG_DEBUG, "PARSE receiver #%d: gps16x_message: message checksum error: hdr_csum = 0x%x (expected 0x%x), " + "data_len = %d, data_csum = 0x%x (expected 0x%x)", CLK_UNIT(parse->peer), - header.gps_hdr_csum, mbg_csum(parsetime->parse_msg + 1, 6), - header.gps_len, - header.gps_data_csum, mbg_csum(bufp, (unsigned)((header.gps_len < sizeof(parsetime->parse_msg)) ? header.gps_len : 0))); + header.hdr_csum, mbg_csum(parsetime->parse_msg + 1, 6), + header.len, + header.data_csum, mbg_csum(bufp, (unsigned)((header.len < sizeof(parsetime->parse_msg)) ? header.len : 0))); } } - + return; } @@ -4464,12 +4656,12 @@ gps16x_poll( struct peer *peer ) { - struct parseunit *parse = (struct parseunit *)peer->procptr->unitptr; - - static GPS_MSG_HDR sequence[] = + struct parseunit *parse = peer->procptr->unitptr; + + static GPS_MSG_HDR sequence[] = { { GPS_SW_REV, 0, 0, 0 }, - { GPS_STAT, 0, 0, 0 }, + { GPS_BVAR_STAT, 0, 0, 0 }, { GPS_UTC, 0, 0, 0 }, { GPS_ASCII_MSG, 0, 0, 0 }, { GPS_ANT_INFO, 0, 0, 0 }, @@ -4478,46 +4670,46 @@ gps16x_poll( { GPS_POS_LLA, 0, 0, 0 }, { (unsigned short)~0, 0, 0, 0 } }; - + int rtc; unsigned char cmd_buffer[64]; unsigned char *outp = cmd_buffer; GPS_MSG_HDR *header; - + if (((poll_info_t *)parse->parse_type->cl_data)->rate) { - parse->peer->nextaction = current_time + ((poll_info_t *)parse->parse_type->cl_data)->rate; + parse->peer->procptr->nextaction = current_time + ((poll_info_t *)parse->parse_type->cl_data)->rate; } - if (sequence[parse->localstate].gps_cmd == (unsigned short)~0) + if (sequence[parse->localstate].cmd == (unsigned short)~0) parse->localstate = 0; - + header = sequence + parse->localstate++; - + *outp++ = SOH; /* start command */ - + put_mbg_header(&outp, header); outp = cmd_buffer + 1; - - header->gps_hdr_csum = (short)mbg_csum(outp, 6); + + header->hdr_csum = (short)mbg_csum(outp, 6); put_mbg_header(&outp, header); - + #ifdef DEBUG if (debug > 2) { char buffer[128]; - + mkreadable(buffer, sizeof(buffer), (char *)cmd_buffer, (unsigned)(outp - cmd_buffer), 1); printf("PARSE receiver #%d: transmitted message #%ld (%d bytes) >%s<\n", CLK_UNIT(parse->peer), parse->localstate - 1, (int)(outp - cmd_buffer), - buffer); + buffer); } #endif - - rtc = write(parse->generic->io.fd, cmd_buffer, (unsigned long)(outp - cmd_buffer)); - + + rtc = (int) write(parse->generic->io.fd, cmd_buffer, (unsigned long)(outp - cmd_buffer)); + if (rtc < 0) { ERR(ERR_BADIO) @@ -4544,7 +4736,7 @@ gps16x_poll_init( { if (((poll_info_t *)parse->parse_type->cl_data)->rate) { - parse->peer->action = gps16x_poll; + parse->peer->procptr->action = gps16x_poll; gps16x_poll(parse->peer); } @@ -4566,7 +4758,7 @@ gps16x_poll_init( return 1; } #endif /* CLOCK_MEINBERG */ - + /**=========================================================================== ** clock polling support **/ @@ -4579,11 +4771,11 @@ poll_dpoll( struct parseunit *parse ) { - int rtc; + long rtc; const char *ps = ((poll_info_t *)parse->parse_type->cl_data)->string; - int ct = ((poll_info_t *)parse->parse_type->cl_data)->count; + long ct = ((poll_info_t *)parse->parse_type->cl_data)->count; - rtc = write(parse->generic->io.fd, ps, (unsigned long)ct); + rtc = write(parse->generic->io.fd, ps, ct); if (rtc < 0) { ERR(ERR_BADIO) @@ -4593,7 +4785,7 @@ poll_dpoll( if (rtc != ct) { ERR(ERR_BADIO) - msyslog(LOG_ERR, "PARSE receiver #%d: poll_dpoll: failed to send cmd incomplete (%d of %d bytes sent)", CLK_UNIT(parse->peer), rtc, ct); + msyslog(LOG_ERR, "PARSE receiver #%d: poll_dpoll: failed to send cmd incomplete (%ld of %ld bytes sent)", CLK_UNIT(parse->peer), rtc, ct); } clear_err(parse, ERR_BADIO); } @@ -4606,14 +4798,14 @@ poll_poll( struct peer *peer ) { - struct parseunit *parse = (struct parseunit *)peer->procptr->unitptr; - + struct parseunit *parse = peer->procptr->unitptr; + if (parse->parse_type->cl_poll) parse->parse_type->cl_poll(parse); if (((poll_info_t *)parse->parse_type->cl_data)->rate) { - parse->peer->nextaction = current_time + ((poll_info_t *)parse->parse_type->cl_data)->rate; + parse->peer->procptr->nextaction = current_time + ((poll_info_t *)parse->parse_type->cl_data)->rate; } } @@ -4627,13 +4819,13 @@ poll_init( { if (((poll_info_t *)parse->parse_type->cl_data)->rate) { - parse->peer->action = poll_poll; + parse->peer->procptr->action = poll_poll; poll_poll(parse->peer); } return 0; } - + /**=========================================================================== ** Trimble support **/ @@ -4663,7 +4855,7 @@ trimbletaip_init( else { tio.c_cc[VEOL] = TRIMBLETAIP_EOL; - + if (TTY_SETATTR(parse->generic->io.fd, &tio) == -1) { msyslog(LOG_ERR, "PARSE receiver #%d: trimbletaip_init: tcsetattr(fd, &tio): %m", CLK_UNIT(parse->peer)); @@ -4682,7 +4874,7 @@ static const char *taipinit[] = { ">FTM00020001<", (char *)0 }; - + static void trimbletaip_event( struct parseunit *parse, @@ -4699,7 +4891,7 @@ trimbletaip_event( iv = taipinit; while (*iv) { - int rtc = write(parse->generic->io.fd, *iv, strlen(*iv)); + int rtc = (int) write(parse->generic->io.fd, *iv, strlen(*iv)); if (rtc < 0) { msyslog(LOG_ERR, "PARSE receiver #%d: trimbletaip_event: failed to send cmd to clock: %m", CLK_UNIT(parse->peer)); @@ -4707,7 +4899,7 @@ trimbletaip_event( } else { - if (rtc != strlen(*iv)) + if (rtc != (int)strlen(*iv)) { msyslog(LOG_ERR, "PARSE receiver #%d: trimbletaip_event: failed to send cmd incomplete (%d of %d bytes sent)", CLK_UNIT(parse->peer), rtc, (int)strlen(*iv)); @@ -4827,19 +5019,19 @@ union uval { float fv; double dv; }; - + struct txbuf { short idx; /* index to first unused byte */ u_char *txt; /* pointer to actual data buffer */ }; -void sendcmd P((struct txbuf *buf, int c)); -void sendbyte P((struct txbuf *buf, int b)); -void sendetx P((struct txbuf *buf, struct parseunit *parse)); -void sendint P((struct txbuf *buf, int a)); -void sendflt P((struct txbuf *buf, double a)); - +void sendcmd (struct txbuf *buf, int c); +void sendbyte (struct txbuf *buf, int b); +void sendetx (struct txbuf *buf, struct parseunit *parse); +void sendint (struct txbuf *buf, int a); +void sendflt (struct txbuf *buf, double a); + void sendcmd( struct txbuf *buf, @@ -4851,12 +5043,12 @@ sendcmd( buf->idx = 2; } -void sendcmd P((struct txbuf *buf, int c)); -void sendbyte P((struct txbuf *buf, int b)); -void sendetx P((struct txbuf *buf, struct parseunit *parse)); -void sendint P((struct txbuf *buf, int a)); -void sendflt P((struct txbuf *buf, double a)); - +void sendcmd (struct txbuf *buf, int c); +void sendbyte (struct txbuf *buf, int b); +void sendetx (struct txbuf *buf, struct parseunit *parse); +void sendint (struct txbuf *buf, int a); +void sendflt (struct txbuf *buf, double a); + void sendbyte( struct txbuf *buf, @@ -4888,18 +5080,18 @@ sendetx( if (debug > 2) { char buffer[256]; - + mkreadable(buffer, sizeof(buffer), (char *)buf->txt, (unsigned)buf->idx, 1); printf("PARSE receiver #%d: transmitted message (%d bytes) >%s<\n", CLK_UNIT(parse->peer), - buf->idx, buffer); + buf->idx, buffer); } #endif clear_err(parse, ERR_BADIO); } } -void +void sendint( struct txbuf *buf, int a @@ -4919,7 +5111,7 @@ sendflt( int i; union uval uval; - uval.fv = a; + uval.fv = (float) a; #ifdef WORDS_BIGENDIAN for (i=0; i<=3; i++) #else @@ -4951,12 +5143,12 @@ trimbletsip_setup( if (t) t->last_reset = current_time; - + buf.txt = buffer; - + sendcmd(&buf, CMD_CVERSION); /* request software versions */ sendetx(&buf, parse); - + sendcmd(&buf, CMD_COPERPARAM); /* set operating parameters */ sendbyte(&buf, 4); /* static */ sendflt(&buf, 5.0*D2R); /* elevation angle mask = 10 deg XXX */ @@ -4964,25 +5156,25 @@ trimbletsip_setup( sendflt(&buf, 12.0); /* PDOP mask = 12 */ sendflt(&buf, 8.0); /* PDOP switch level = 8 */ sendetx(&buf, parse); - + sendcmd(&buf, CMD_CMODESEL); /* fix mode select */ sendbyte(&buf, 1); /* time transfer mode */ sendetx(&buf, parse); - + sendcmd(&buf, CMD_CMESSAGE); /* request system message */ sendetx(&buf, parse); - + sendcmd(&buf, CMD_CSUPER); /* superpacket fix */ sendbyte(&buf, 0x2); /* binary mode */ sendetx(&buf, parse); - + sendcmd(&buf, CMD_CIOOPTIONS); /* set I/O options */ sendbyte(&buf, TRIM_POS_OPT); /* position output */ sendbyte(&buf, 0x00); /* no velocity output */ sendbyte(&buf, TRIM_TIME_OPT); /* UTC, compute on seconds */ sendbyte(&buf, 0x00); /* no raw measurements */ sendetx(&buf, parse); - + sendcmd(&buf, CMD_CUTCPARAM); /* request UTC correction data */ sendetx(&buf, parse); @@ -5001,12 +5193,12 @@ trimble_check( struct peer *peer ) { - struct parseunit *parse = (struct parseunit *)peer->procptr->unitptr; + struct parseunit *parse = peer->procptr->unitptr; trimble_t *t = parse->localdata; u_char buffer[256]; struct txbuf buf; buf.txt = buffer; - + if (t) { if (current_time > t->last_msg + TRIMBLETSIP_IDLE_TIME) @@ -5014,18 +5206,18 @@ trimble_check( } poll_poll(parse->peer); /* emit query string and re-arm timer */ - + if (t && t->qtracking) { u_long oldsats = t->ltrack & ~t->ctrack; - + t->qtracking = 0; t->ltrack = t->ctrack; - + if (oldsats) { int i; - + for (i = 0; oldsats; i++) { if (oldsats & (1 << i)) { @@ -5036,7 +5228,7 @@ trimble_check( oldsats &= ~(1 << i); } } - + sendcmd(&buf, CMD_CSTATTRACK); sendbyte(&buf, 0x00); /* current tracking set */ sendetx(&buf, parse); @@ -5051,14 +5243,14 @@ trimbletsip_end( struct parseunit *parse ) { trimble_t *t = parse->localdata; - + if (t) { free(t); - parse->localdata = (void *)0; + parse->localdata = NULL; } - parse->peer->nextaction = 0; - parse->peer->action = (void (*) P((struct peer *)))0; + parse->peer->procptr->nextaction = 0; + parse->peer->procptr->action = NULL; } /*-------------------------------------------------- @@ -5082,9 +5274,9 @@ trimbletsip_init( if (!parse->localdata) { trimble_t *t; - + t = (trimble_t *)(parse->localdata = emalloc(sizeof(trimble_t))); - + if (t) { memset((char *)t, 0, sizeof(trimble_t)); @@ -5092,8 +5284,8 @@ trimbletsip_init( } } - parse->peer->action = trimble_check; - parse->peer->nextaction = current_time; + parse->peer->procptr->action = trimble_check; + parse->peer->procptr->nextaction = current_time; /* * configure terminal line for ICANON mode with VEOL characters @@ -5164,7 +5356,7 @@ getflt( ) { union uval uval; - + #ifdef WORDS_BIGENDIAN uval.bd[0] = *bp++; uval.bd[1] = *bp++; @@ -5185,7 +5377,7 @@ getdbl( ) { union uval uval; - + #ifdef WORDS_BIGENDIAN uval.bd[0] = *bp++; uval.bd[1] = *bp++; @@ -5213,7 +5405,7 @@ getshort( unsigned char *p ) { - return get_msb_short(&p); + return (int) get_msb_short(&p); } /*-------------------------------------------------- @@ -5230,7 +5422,7 @@ trimbletsip_message( { unsigned char *buffer = parsetime->parse_msg; unsigned int size = parsetime->parse_msglen; - + if ((size < 4) || (buffer[0] != DLE) || (buffer[size-1] != ETX) || @@ -5238,7 +5430,7 @@ trimbletsip_message( { #ifdef DEBUG if (debug > 2) { - int i; + size_t i; printf("TRIMBLE BAD packet, size %d:\n ", size); for (i = 0; i < size; i++) { @@ -5252,16 +5444,16 @@ trimbletsip_message( } else { - int var_flag; + u_short var_flag; trimble_t *tr = parse->localdata; unsigned int cmd = buffer[1]; char pbuffer[200]; char *t = pbuffer; cmd_info_t *s; - + #ifdef DEBUG if (debug > 3) { - int i; + size_t i; printf("TRIMBLE packet 0x%02x, size %d:\n ", cmd, size); for (i = 0; i < size; i++) { @@ -5274,12 +5466,12 @@ trimbletsip_message( if (tr) tr->last_msg = current_time; - + s = trimble_convert(cmd, trimble_rcmds); - + if (s) { - snprintf(t, BUFFER_SIZE(pbuffer, t), "%s=\"", s->varname); + t = ap(pbuffer, sizeof(pbuffer), t, "%s=\"", s->varname); } else { @@ -5287,47 +5479,43 @@ trimbletsip_message( return; } - var_flag = s->varmode; + var_flag = (u_short) s->varmode; - t += strlen(t); - switch(cmd) { case CMD_RCURTIME: - snprintf(t, BUFFER_SIZE(pbuffer, t), "%f, %d, %f", + t = ap(pbuffer, sizeof(pbuffer), t, "%f, %d, %f", getflt((unsigned char *)&mb(0)), getshort((unsigned char *)&mb(4)), getflt((unsigned char *)&mb(6))); break; - + case CMD_RBEST4: - strncpy(t, "mode: ", BUFFER_SIZE(pbuffer, t)); - t += strlen(t); + t = ap(pbuffer, sizeof(pbuffer), t, "mode: "); switch (mb(0) & 0xF) { default: - snprintf(t, BUFFER_SIZE(pbuffer, t), "0x%x", mb(0) & 0x7); + t = ap(pbuffer, sizeof(pbuffer), t, + "0x%x", mb(0) & 0x7); break; case 1: - strncpy(t, "0D", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "0D"); break; - + case 3: - strncpy(t, "2D", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "2D"); break; - + case 4: - strncpy(t, "3D", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "3D"); break; } - t += strlen(t); if (mb(0) & 0x10) - strncpy(t, "-MANUAL, ", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "-MANUAL, "); else - strncpy(t, "-AUTO, ", BUFFER_SIZE(pbuffer, t)); - t += strlen(t); - - snprintf(t, BUFFER_SIZE(pbuffer, t), "satellites %02d %02d %02d %02d, PDOP %.2f, HDOP %.2f, VDOP %.2f, TDOP %.2f", + t = ap(pbuffer, sizeof(pbuffer), t, "-AUTO, "); + + t = ap(pbuffer, sizeof(pbuffer), t, "satellites %02d %02d %02d %02d, PDOP %.2f, HDOP %.2f, VDOP %.2f, TDOP %.2f", mb(1), mb(2), mb(3), mb(4), getflt((unsigned char *)&mb(5)), getflt((unsigned char *)&mb(9)), @@ -5335,12 +5523,12 @@ trimbletsip_message( getflt((unsigned char *)&mb(17))); break; - + case CMD_RVERSION: - snprintf(t, BUFFER_SIZE(pbuffer, t), "%d.%d (%d/%d/%d)", + t = ap(pbuffer, sizeof(pbuffer), t, "%d.%d (%d/%d/%d)", mb(0)&0xff, mb(1)&0xff, 1900+(mb(4)&0xff), mb(2)&0xff, mb(3)&0xff); break; - + case CMD_RRECVHEALTH: { static const char *msgs[] = @@ -5354,57 +5542,54 @@ trimbletsip_message( "", "" }; - + int i, bits; - + switch (mb(0) & 0xFF) { default: - snprintf(t, BUFFER_SIZE(pbuffer, t), "illegal value 0x%02x", mb(0) & 0xFF); + t = ap(pbuffer, sizeof(pbuffer), t, "illegal value 0x%02x", mb(0) & 0xFF); break; case 0x00: - strncpy(t, "doing position fixes", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "doing position fixes"); break; case 0x01: - strncpy(t, "no GPS time yet", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "no GPS time yet"); break; case 0x03: - strncpy(t, "PDOP too high", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "PDOP too high"); break; case 0x08: - strncpy(t, "no usable satellites", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "no usable satellites"); break; case 0x09: - strncpy(t, "only ONE usable satellite", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "only ONE usable satellite"); break; case 0x0A: - strncpy(t, "only TWO usable satellites", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "only TWO usable satellites"); break; case 0x0B: - strncpy(t, "only THREE usable satellites", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "only THREE usable satellites"); break; case 0x0C: - strncpy(t, "the chosen satellite is unusable", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "the chosen satellite is unusable"); break; } - t += strlen(t); - bits = mb(1) & 0xFF; - + for (i = 0; i < 8; i++) if (bits & (0x1<", "" }; - + int i, bits; - snprintf(t, BUFFER_SIZE(pbuffer, t), "machine id 0x%02x", mb(0) & 0xFF); - t += strlen(t); - + t = ap(pbuffer, sizeof(pbuffer), t, "machine id 0x%02x", mb(0) & 0xFF); bits = mb(1) & 0xFF; - + for (i = 0; i < 8; i++) if (bits & (0x1<", BUFFER_SIZE(pbuffer, t)); - } + { + t = ap(pbuffer, sizeof(pbuffer), t, ""); + } } break; case CMD_RSAT1BIAS: - snprintf(t, BUFFER_SIZE(pbuffer, t), "%.1fm %.2fm/s at %.1fs", + t = ap(pbuffer, sizeof(pbuffer), t, "%.1fm %.2fm/s at %.1fs", getflt(&mb(0)), getflt(&mb(4)), getflt(&mb(8))); break; case CMD_RIOOPTIONS: { - snprintf(t, BUFFER_SIZE(pbuffer, t), "%02x %02x %02x %02x", + t = ap(pbuffer, sizeof(pbuffer), t, "%02x %02x %02x %02x", mb(0), mb(1), mb(2), mb(3)); if (mb(0) != TRIM_POS_OPT || mb(2) != TRIM_TIME_OPT) @@ -5479,20 +5661,20 @@ trimbletsip_message( } } break; - + case CMD_RSPOSXYZ: { double x = getflt((unsigned char *)&mb(0)); double y = getflt((unsigned char *)&mb(4)); double z = getflt((unsigned char *)&mb(8)); double f = getflt((unsigned char *)&mb(12)); - + if (f > 0.0) - snprintf(t, BUFFER_SIZE(pbuffer, t), "x= %.1fm, y= %.1fm, z= %.1fm, time_of_fix= %f sec", + t = ap(pbuffer, sizeof(pbuffer), t, "x= %.1fm, y= %.1fm, z= %.1fm, time_of_fix= %f sec", x, y, z, f); else - return; + return; } break; @@ -5501,14 +5683,14 @@ trimbletsip_message( double lat = getflt((unsigned char *)&mb(0)); double lng = getflt((unsigned char *)&mb(4)); double f = getflt((unsigned char *)&mb(12)); - + if (f > 0.0) - snprintf(t, BUFFER_SIZE(pbuffer, t), "lat %f %c, long %f %c, alt %.2fm", + t = ap(pbuffer, sizeof(pbuffer), t, "lat %f %c, long %f %c, alt %.2fm", ((lat < 0.0) ? (-lat) : (lat))*RTOD, (lat < 0.0 ? 'S' : 'N'), ((lng < 0.0) ? (-lng) : (lng))*RTOD, (lng < 0.0 ? 'W' : 'E'), getflt((unsigned char *)&mb(8))); else - return; + return; } break; @@ -5517,16 +5699,16 @@ trimbletsip_message( double x = getdbl((unsigned char *)&mb(0)); double y = getdbl((unsigned char *)&mb(8)); double z = getdbl((unsigned char *)&mb(16)); - snprintf(t, BUFFER_SIZE(pbuffer, t), "x= %.1fm, y= %.1fm, z= %.1fm", + t = ap(pbuffer, sizeof(pbuffer), t, "x= %.1fm, y= %.1fm, z= %.1fm", x, y, z); } break; - + case CMD_RDOUBLELLA: { double lat = getdbl((unsigned char *)&mb(0)); double lng = getdbl((unsigned char *)&mb(8)); - snprintf(t, BUFFER_SIZE(pbuffer, t), "lat %f %c, lon %f %c, alt %.2fm", + t = ap(pbuffer, sizeof(pbuffer), t, "lat %f %c, lon %f %c, alt %.2fm", ((lat < 0.0) ? (-lat) : (lat))*RTOD, (lat < 0.0 ? 'S' : 'N'), ((lng < 0.0) ? (-lng) : (lng))*RTOD, (lng < 0.0 ? 'W' : 'E'), getdbl((unsigned char *)&mb(16))); @@ -5536,108 +5718,97 @@ trimbletsip_message( case CMD_RALLINVIEW: { int i, sats; - - strncpy(t, "mode: ", BUFFER_SIZE(pbuffer, t)); - t += strlen(t); + + t = ap(pbuffer, sizeof(pbuffer), t, "mode: "); switch (mb(0) & 0x7) { default: - snprintf(t, BUFFER_SIZE(pbuffer, t), "0x%x", mb(0) & 0x7); + t = ap(pbuffer, sizeof(pbuffer), t, "0x%x", mb(0) & 0x7); break; case 3: - strncpy(t, "2D", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "2D"); break; - + case 4: - strncpy(t, "3D", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "3D"); break; } - t += strlen(t); if (mb(0) & 0x8) - strncpy(t, "-MANUAL, ", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "-MANUAL, "); else - strncpy(t, "-AUTO, ", BUFFER_SIZE(pbuffer, t)); - t += strlen(t); - + t = ap(pbuffer, sizeof(pbuffer), t, "-AUTO, "); + sats = (mb(0)>>4) & 0xF; - - snprintf(t, BUFFER_SIZE(pbuffer, t), "PDOP %.2f, HDOP %.2f, VDOP %.2f, TDOP %.2f, %d satellite%s in view: ", + + t = ap(pbuffer, sizeof(pbuffer), t, "PDOP %.2f, HDOP %.2f, VDOP %.2f, TDOP %.2f, %d satellite%s in view: ", getflt((unsigned char *)&mb(1)), getflt((unsigned char *)&mb(5)), getflt((unsigned char *)&mb(9)), getflt((unsigned char *)&mb(13)), sats, (sats == 1) ? "" : "s"); - t += strlen(t); for (i=0; i < sats; i++) { - snprintf(t, BUFFER_SIZE(pbuffer, t), "%s%02d", i ? ", " : "", mb(17+i)); - t += strlen(t); + t = ap(pbuffer, sizeof(pbuffer), t, "%s%02d", i ? ", " : "", mb(17+i)); if (tr) tr->ctrack |= (1 << (mb(17+i)-1)); } if (tr) - { /* mark for tracking status query */ + { /* mark for tracking status query */ tr->qtracking = 1; } } break; - + case CMD_RSTATTRACK: { - snprintf(t-2, BUFFER_SIZE(pbuffer, t-2), "[%02d]=\"", mb(0)); /* add index to var name */ - t += strlen(t); - + t = ap(pbuffer, sizeof(pbuffer), t-2, "[%02d]=\"", mb(0)); /* add index to var name */ if (getflt((unsigned char *)&mb(4)) < 0.0) { - strncpy(t, "", BUFFER_SIZE(pbuffer, t)); - var_flag &= ~DEF; + t = ap(pbuffer, sizeof(pbuffer), t, ""); + var_flag &= (u_short)(~DEF); } else - { - snprintf(t, BUFFER_SIZE(pbuffer, t), "ch=%d, acq=%s, eph=%d, signal_level= %5.2f, elevation= %5.2f, azimuth= %6.2f", + { + t = ap(pbuffer, sizeof(pbuffer), t, "ch=%d, acq=%s, eph=%d, signal_level= %5.2f, elevation= %5.2f, azimuth= %6.2f", (mb(1) & 0xFF)>>3, mb(2) ? ((mb(2) == 1) ? "ACQ" : "SRCH") : "NEVER", mb(3), getflt((unsigned char *)&mb(4)), getflt((unsigned char *)&mb(12)) * RTOD, getflt((unsigned char *)&mb(16)) * RTOD); - t += strlen(t); if (mb(20)) { - var_flag &= ~DEF; - strncpy(t, ", OLD", BUFFER_SIZE(pbuffer, t)); + var_flag &= (u_short)(~DEF); + t = ap(pbuffer, sizeof(pbuffer), t, ", OLD"); } - t += strlen(t); if (mb(22)) { if (mb(22) == 1) - strncpy(t, ", BAD PARITY", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, ", BAD PARITY"); else if (mb(22) == 2) - strncpy(t, ", BAD EPH HEALTH", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, ", BAD EPH HEALTH"); } - t += strlen(t); if (mb(23)) - strncpy(t, ", collecting data", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, ", collecting data"); } } break; - + default: - strncpy(t, "", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, ""); break; } - t += strlen(t); - strncpy(t,"\"", BUFFER_SIZE(pbuffer, t)); + t = ap(pbuffer, sizeof(pbuffer), t, "\""); set_var(&parse->kv, pbuffer, sizeof(pbuffer), var_flag); } } - + /**============================================================ ** RAWDCF support **/ @@ -5737,13 +5908,16 @@ rawdcf_init_2( #endif /* DTR initialisation type */ #else /* defined(REFCLOCK) && defined(PARSE) */ -int refclock_parse_bs; +NONEMPTY_TRANSLATION_UNIT #endif /* defined(REFCLOCK) && defined(PARSE) */ /* * History: * * refclock_parse.c,v + * Revision 4.81 2009/05/01 10:15:29 kardel + * use new refclock_ppsapi interface + * * Revision 4.80 2007/08/11 12:06:29 kardel * update comments wrt/ to PPS * @@ -5858,7 +6032,7 @@ int refclock_parse_bs; * implement fast refclock startup * * Revision 4.50 2005/04/16 20:51:35 kardel - * set pps_enable = 1 when binding a kernel PPS source + * set hardpps_enable = 1 when binding a kernel PPS source * * Revision 4.49 2005/04/16 17:29:26 kardel * add non polling clock type 18 for just listenning to Meinberg clocks diff --git a/contrib/ntp/ntpd/refclock_pcf.c b/contrib/ntp/ntpd/refclock_pcf.c index d4e9fd17a..45b3475c0 100644 --- a/contrib/ntp/ntpd/refclock_pcf.c +++ b/contrib/ntp/ntpd/refclock_pcf.c @@ -38,9 +38,9 @@ /* * Function prototypes */ -static int pcf_start P((int, struct peer *)); -static void pcf_shutdown P((int, struct peer *)); -static void pcf_poll P((int, struct peer *)); +static int pcf_start (int, struct peer *); +static void pcf_shutdown (int, struct peer *); +static void pcf_poll (int, struct peer *); /* * Transfer vector @@ -72,10 +72,10 @@ pcf_start( /* * Open device file for reading. */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = open(device, O_RDONLY); if (fd == -1) { - (void)sprintf(device, OLDDEVICE, unit); + snprintf(device, sizeof(device), OLDDEVICE, unit); fd = open(device, O_RDONLY); } #ifdef DEBUG @@ -88,7 +88,7 @@ pcf_start( pp = peer->procptr; pp->io.clock_recv = noentry; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; @@ -118,7 +118,8 @@ pcf_shutdown( struct refclockproc *pp; pp = peer->procptr; - (void)close(pp->io.fd); + if (NULL != pp) + close(pp->io.fd); } @@ -139,11 +140,13 @@ pcf_poll( pp = peer->procptr; buf[0] = 0; - if (read(pp->io.fd, buf, sizeof(buf)) < sizeof(buf) || buf[0] != 9) { + if (read(pp->io.fd, buf, sizeof(buf)) < (ssize_t)sizeof(buf) || buf[0] != 9) { refclock_report(peer, CEVNT_FAULT); return; } + ZERO(tm); + tm.tm_mday = buf[11] * 10 + buf[10]; tm.tm_mon = buf[13] * 10 + buf[12] - 1; tm.tm_year = buf[15] * 10 + buf[14]; diff --git a/contrib/ntp/ntpd/refclock_pst.c b/contrib/ntp/ntpd/refclock_pst.c index 776e28eaf..39be05138 100644 --- a/contrib/ntp/ntpd/refclock_pst.c +++ b/contrib/ntp/ntpd/refclock_pst.c @@ -91,10 +91,10 @@ struct pstunit { /* * Function prototypes */ -static int pst_start P((int, struct peer *)); -static void pst_shutdown P((int, struct peer *)); -static void pst_receive P((struct recvbuf *)); -static void pst_poll P((int, struct peer *)); +static int pst_start (int, struct peer *); +static void pst_shutdown (int, struct peer *); +static void pst_receive (struct recvbuf *); +static void pst_poll (int, struct peer *); /* * Transfer vector @@ -127,29 +127,27 @@ pst_start( /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) + snprintf(device, sizeof(device), DEVICE, unit); + fd = refclock_open(device, SPEED232, LDISC_CLK); + if (fd <= 0) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct pstunit *)emalloc(sizeof(struct pstunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct pstunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = pst_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -157,7 +155,6 @@ pst_start( peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; memcpy((char *)&pp->refid, WWVREFID, 4); - peer->burst = MAXSTAGE; return (1); } @@ -175,9 +172,11 @@ pst_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct pstunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -202,9 +201,9 @@ pst_receive( /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct pstunit *)pp->unitptr; + up = pp->unitptr; up->lastptr += refclock_gtlin(rbufp, up->lastptr, pp->a_lastcode + BMAX - 2 - up->lastptr, &trtmp); *up->lastptr++ = ' '; @@ -295,13 +294,11 @@ pst_poll( * becomes unreachable, declare a timeout and keep going. */ pp = peer->procptr; - up = (struct pstunit *)pp->unitptr; + up = pp->unitptr; up->tcswitch = 0; up->lastptr = pp->a_lastcode; if (write(pp->io.fd, "QTQDQMT", 6) != 6) refclock_report(peer, CEVNT_FAULT); - if (peer->burst > 0) - return; if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; @@ -313,7 +310,6 @@ pst_poll( printf("pst: timecode %d %s\n", pp->lencode, pp->a_lastcode); #endif - peer->burst = MAXSTAGE; pp->polls++; } diff --git a/contrib/ntp/ntpd/refclock_ripencc.c b/contrib/ntp/ntpd/refclock_ripencc.c index d9fa2044c..602ca9d6a 100644 --- a/contrib/ntp/ntpd/refclock_ripencc.c +++ b/contrib/ntp/ntpd/refclock_ripencc.c @@ -90,7 +90,7 @@ #define TSIP_PARSED_DATA 3 #define TSIP_PARSED_DLE_2 4 -#define UTCF_UTC_AVAIL (unsigned char) (1) /* UTC available */ +#define UTCF_UTC_AVAIL (unsigned char) (1) /* UTC available */ #define UTCF_LEAP_SCHD (unsigned char) (1<<4) /* Leap scheduled */ #define UTCF_LEAP_PNDG (unsigned char) (1<<5) /* Leap pending, will occur at end of day */ @@ -109,128 +109,128 @@ /* TSIP packets have the following structure, whether report or command. */ typedef struct { short - counter, /* counter */ - len; /* size of buf; < MAX_RPTBUF unsigned chars */ + counter, /* counter */ + len; /* size of buf; < MAX_RPTBUF unsigned chars */ unsigned char - status, /* TSIP packet format/parse status */ - code, /* TSIP code */ - buf[MAX_RPTBUF];/* report or command string */ + status, /* TSIP packet format/parse status */ + code, /* TSIP code */ + buf[MAX_RPTBUF]; /* report or command string */ } TSIPPKT; /* TSIP binary data structures */ typedef struct { unsigned char - t_oa_raw, SV_health; + t_oa_raw, SV_health; float - e, t_oa, i_0, OMEGADOT, sqrt_A, - OMEGA_0, omega, M_0, a_f0, a_f1, - Axis, n, OMEGA_n, ODOT_n, t_zc; + e, t_oa, i_0, OMEGADOT, sqrt_A, + OMEGA_0, omega, M_0, a_f0, a_f1, + Axis, n, OMEGA_n, ODOT_n, t_zc; short - weeknum, wn_oa; + weeknum, wn_oa; } ALM_INFO; -typedef struct { /* Almanac health page (25) parameters */ +typedef struct { /* Almanac health page (25) parameters */ unsigned char - WN_a, SV_health[32], t_oa; + WN_a, SV_health[32], t_oa; } ALH_PARMS; -typedef struct { /* Universal Coordinated Time (UTC) parms */ +typedef struct { /* Universal Coordinated Time (UTC) parms */ double - A_0; + A_0; float - A_1; + A_1; short - delta_t_LS; + delta_t_LS; float - t_ot; + t_ot; short - WN_t, WN_LSF, DN, delta_t_LSF; + WN_t, WN_LSF, DN, delta_t_LSF; } UTC_INFO; -typedef struct { /* Ionospheric info (float) */ +typedef struct { /* Ionospheric info (float) */ float - alpha_0, alpha_1, alpha_2, alpha_3, - beta_0, beta_1, beta_2, beta_3; + alpha_0, alpha_1, alpha_2, alpha_3, + beta_0, beta_1, beta_2, beta_3; } ION_INFO; -typedef struct { /* Subframe 1 info (float) */ +typedef struct { /* Subframe 1 info (float) */ short - weeknum; + weeknum; unsigned char - codeL2, L2Pdata, SVacc_raw, SV_health; + codeL2, L2Pdata, SVacc_raw, SV_health; short - IODC; + IODC; float - T_GD, t_oc, a_f2, a_f1, a_f0, SVacc; + T_GD, t_oc, a_f2, a_f1, a_f0, SVacc; } EPHEM_CLOCK; -typedef struct { /* Ephemeris info (float) */ +typedef struct { /* Ephemeris info (float) */ unsigned char - IODE, fit_interval; + IODE, fit_interval; float - C_rs, delta_n; + C_rs, delta_n; double - M_0; + M_0; float - C_uc; + C_uc; double - e; + e; float - C_us; + C_us; double - sqrt_A; + sqrt_A; float - t_oe, C_ic; + t_oe, C_ic; double - OMEGA_0; + OMEGA_0; float - C_is; + C_is; double - i_0; + i_0; float - C_rc; + C_rc; double - omega; + omega; float - OMEGADOT, IDOT; + OMEGADOT, IDOT; double - Axis, n, r1me2, OMEGA_n, ODOT_n; + Axis, n, r1me2, OMEGA_n, ODOT_n; } EPHEM_ORBIT; -typedef struct { /* Navigation data structure */ +typedef struct { /* Navigation data structure */ short - sv_number; /* SV number (0 = no entry) */ + sv_number; /* SV number (0 = no entry) */ float - t_ephem; /* time of ephemeris collection */ + t_ephem; /* time of ephemeris collection */ EPHEM_CLOCK - ephclk; /* subframe 1 data */ + ephclk; /* subframe 1 data */ EPHEM_ORBIT - ephorb; /* ephemeris data */ + ephorb; /* ephemeris data */ } NAV_INFO; typedef struct { unsigned char - bSubcode, - operating_mode, - dgps_mode, - dyn_code, - trackmode; + bSubcode, + operating_mode, + dgps_mode, + dyn_code, + trackmode; float - elev_mask, - cno_mask, - dop_mask, - dop_switch; + elev_mask, + cno_mask, + dop_mask, + dop_switch; unsigned char - dgps_age_limit; + dgps_age_limit; } TSIP_RCVR_CFG; #ifdef TRIMBLE_OUTPUT_FUNC static char - *dayname[7] = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}, + *dayname[7] = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}, old_baudnum[] = {0, 1, 4, 5, 6, 8, 9, 11, 28, 12}, *st_baud_text_app [] = {"", "", " 300", " 600", " 1200", " 2400", - " 4800", " 9600", "19200", "38400"}, + " 4800", " 9600", "19200", "38400"}, *old_parity_text[] = {"EVEN", "ODD", "", "", "NONE"}, *parity_text [] = {"NONE", "ODD", "EVEN"}, *old_input_ch[] = { "TSIP", "RTCM (6 of 8 bits)"}, @@ -240,12 +240,12 @@ static char *rcvr_port_text [] = { "Port A ", "Port B ", "Current Port"}, *dyn_text [] = {"Unchanged", "Land", "Sea", "Air", "Static"}, *NavModeText0xBB[] = {"automatic", "time only (0-D)", "", "2-D", - "3-D", "", "", "OverDetermined Time"}, + "3-D", "", "", "OverDetermined Time"}, *PPSTimeBaseText[] = {"GPS", "UTC", "USER"}, *PPSPolarityText[] = {"Positive", "Negative"}, *MaskText[] = { "Almanac ", "Ephemeris", "UTC ", "Iono ", - "GPS Msg ", "Alm Hlth ", "Time Fix ", "SV Select", - "Ext Event", "Pos Fix ", "Raw Meas "}; + "GPS Msg ", "Alm Hlth ", "Time Fix ", "SV Select", + "Ext Event", "Pos Fix ", "Raw Meas "}; #endif /* TRIMBLE_OUTPUT_FUNC */ @@ -272,116 +272,116 @@ struct ripencc_unit { /* prototypes for report parsing primitives */ short rpt_0x3D (TSIPPKT *rpt, unsigned char *tx_baud_index, - unsigned char *rx_baud_index, unsigned char *char_format_index, - unsigned char *stop_bits, unsigned char *tx_mode_index, - unsigned char *rx_mode_index); + unsigned char *rx_baud_index, unsigned char *char_format_index, + unsigned char *stop_bits, unsigned char *tx_mode_index, + unsigned char *rx_mode_index); short rpt_0x40 (TSIPPKT *rpt, unsigned char *sv_prn, short *week_num, - float *t_zc, float *eccentricity, float *t_oa, float *i_0, - float *OMEGA_dot, float *sqrt_A, float *OMEGA_0, float *omega, - float *M_0); + float *t_zc, float *eccentricity, float *t_oa, float *i_0, + float *OMEGA_dot, float *sqrt_A, float *OMEGA_0, float *omega, + float *M_0); short rpt_0x41 (TSIPPKT *rpt, float *time_of_week, float *UTC_offset, - short *week_num); + short *week_num); short rpt_0x42 (TSIPPKT *rpt, float ECEF_pos[3], float *time_of_fix); short rpt_0x43 (TSIPPKT *rpt, float ECEF_vel[3], float *freq_offset, - float *time_of_fix); + float *time_of_fix); short rpt_0x45 (TSIPPKT *rpt, unsigned char *major_nav_version, - unsigned char *minor_nav_version, unsigned char *nav_day, - unsigned char *nav_month, unsigned char *nav_year, - unsigned char *major_dsp_version, unsigned char *minor_dsp_version, - unsigned char *dsp_day, unsigned char *dsp_month, - unsigned char *dsp_year); + unsigned char *minor_nav_version, unsigned char *nav_day, + unsigned char *nav_month, unsigned char *nav_year, + unsigned char *major_dsp_version, unsigned char *minor_dsp_version, + unsigned char *dsp_day, unsigned char *dsp_month, + unsigned char *dsp_year); short rpt_0x46 (TSIPPKT *rpt, unsigned char *status1, unsigned char *status2); short rpt_0x47 (TSIPPKT *rpt, unsigned char *nsvs, unsigned char *sv_prn, - float *snr); + float *snr); short rpt_0x48 (TSIPPKT *rpt, unsigned char *message); short rpt_0x49 (TSIPPKT *rpt, unsigned char *sv_health); short rpt_0x4A (TSIPPKT *rpt, float *lat, float *lon, float *alt, - float *clock_bias, float *time_of_fix); + float *clock_bias, float *time_of_fix); short rpt_0x4A_2 (TSIPPKT *rpt, float *alt, float *dummy, - unsigned char *alt_flag); + unsigned char *alt_flag); short rpt_0x4B (TSIPPKT *rpt, unsigned char *machine_id, - unsigned char *status3, unsigned char *status4); + unsigned char *status3, unsigned char *status4); short rpt_0x4C (TSIPPKT *rpt, unsigned char *dyn_code, float *el_mask, - float *snr_mask, float *dop_mask, float *dop_switch); + float *snr_mask, float *dop_mask, float *dop_switch); short rpt_0x4D (TSIPPKT *rpt, float *osc_offset); short rpt_0x4E (TSIPPKT *rpt, unsigned char *response); short rpt_0x4F (TSIPPKT *rpt, double *a0, float *a1, float *time_of_data, - short *dt_ls, short *wn_t, short *wn_lsf, short *dn, short *dt_lsf); + short *dt_ls, short *wn_t, short *wn_lsf, short *dn, short *dt_lsf); short rpt_0x54 (TSIPPKT *rpt, float *clock_bias, float *freq_offset, - float *time_of_fix); + float *time_of_fix); short rpt_0x55 (TSIPPKT *rpt, unsigned char *pos_code, unsigned char *vel_code, - unsigned char *time_code, unsigned char *aux_code); + unsigned char *time_code, unsigned char *aux_code); short rpt_0x56 (TSIPPKT *rpt, float vel_ENU[3], float *freq_offset, - float *time_of_fix); + float *time_of_fix); short rpt_0x57 (TSIPPKT *rpt, unsigned char *source_code, - unsigned char *diag_code, short *week_num, float *time_of_fix); + unsigned char *diag_code, short *week_num, float *time_of_fix); short rpt_0x58 (TSIPPKT *rpt, unsigned char *op_code, unsigned char *data_type, - unsigned char *sv_prn, unsigned char *data_length, - unsigned char *data_packet); + unsigned char *sv_prn, unsigned char *data_length, + unsigned char *data_packet); short rpt_0x59 (TSIPPKT *rpt, unsigned char *code_type, - unsigned char status_code[32]); + unsigned char status_code[32]); short rpt_0x5A (TSIPPKT *rpt, unsigned char *sv_prn, float *sample_length, - float *signal_level, float *code_phase, float *Doppler, - double *time_of_fix); + float *signal_level, float *code_phase, float *Doppler, + double *time_of_fix); short rpt_0x5B (TSIPPKT *rpt, unsigned char *sv_prn, unsigned char *sv_health, - unsigned char *sv_iode, unsigned char *fit_interval_flag, - float *time_of_collection, float *time_of_eph, float *sv_accy); + unsigned char *sv_iode, unsigned char *fit_interval_flag, + float *time_of_collection, float *time_of_eph, float *sv_accy); short rpt_0x5C (TSIPPKT *rpt, unsigned char *sv_prn, unsigned char *slot, - unsigned char *chan, unsigned char *acq_flag, unsigned char *eph_flag, - float *signal_level, float *time_of_last_msmt, float *elev, - float *azim, unsigned char *old_msmt_flag, - unsigned char *integer_msec_flag, unsigned char *bad_data_flag, - unsigned char *data_collect_flag); + unsigned char *chan, unsigned char *acq_flag, unsigned char *eph_flag, + float *signal_level, float *time_of_last_msmt, float *elev, + float *azim, unsigned char *old_msmt_flag, + unsigned char *integer_msec_flag, unsigned char *bad_data_flag, + unsigned char *data_collect_flag); short rpt_0x6D (TSIPPKT *rpt, unsigned char *manual_mode, unsigned char *nsvs, - unsigned char *ndim, unsigned char sv_prn[], float *pdop, - float *hdop, float *vdop, float *tdop); + unsigned char *ndim, unsigned char sv_prn[], float *pdop, + float *hdop, float *vdop, float *tdop); short rpt_0x82 (TSIPPKT *rpt, unsigned char *diff_mode); short rpt_0x83 (TSIPPKT *rpt, double ECEF_pos[3], double *clock_bias, - float *time_of_fix); + float *time_of_fix); short rpt_0x84 (TSIPPKT *rpt, double *lat, double *lon, double *alt, - double *clock_bias, float *time_of_fix); + double *clock_bias, float *time_of_fix); short rpt_Paly0xBB(TSIPPKT *rpt, TSIP_RCVR_CFG *TsipxBB); short rpt_0xBC (TSIPPKT *rpt, unsigned char *port_num, - unsigned char *in_baud, unsigned char *out_baud, - unsigned char *data_bits, unsigned char *parity, - unsigned char *stop_bits, unsigned char *flow_control, - unsigned char *protocols_in, unsigned char *protocols_out, - unsigned char *reserved); + unsigned char *in_baud, unsigned char *out_baud, + unsigned char *data_bits, unsigned char *parity, + unsigned char *stop_bits, unsigned char *flow_control, + unsigned char *protocols_in, unsigned char *protocols_out, + unsigned char *reserved); /* prototypes for superpacket parsers */ short rpt_0x8F0B (TSIPPKT *rpt, unsigned short *event, double *tow, - unsigned char *date, unsigned char *month, short *year, - unsigned char *dim_mode, short *utc_offset, double *bias, double *drift, - float *bias_unc, float *dr_unc, double *lat, double *lon, double *alt, - char sv_id[8]); + unsigned char *date, unsigned char *month, short *year, + unsigned char *dim_mode, short *utc_offset, double *bias, double *drift, + float *bias_unc, float *dr_unc, double *lat, double *lon, double *alt, + char sv_id[8]); short rpt_0x8F14 (TSIPPKT *rpt, short *datum_idx, double datum_coeffs[5]); short rpt_0x8F15 (TSIPPKT *rpt, short *datum_idx, double datum_coeffs[5]); short rpt_0x8F20 (TSIPPKT *rpt, unsigned char *info, double *lat, - double *lon, double *alt, double vel_enu[], double *time_of_fix, - short *week_num, unsigned char *nsvs, unsigned char sv_prn[], - short sv_IODC[], short *datum_index); + double *lon, double *alt, double vel_enu[], double *time_of_fix, + short *week_num, unsigned char *nsvs, unsigned char sv_prn[], + short sv_IODC[], short *datum_index); short rpt_0x8F41 (TSIPPKT *rpt, unsigned char *bSearchRange, - unsigned char *bBoardOptions, unsigned long *iiSerialNumber, - unsigned char *bBuildYear, unsigned char *bBuildMonth, - unsigned char *bBuildDay, unsigned char *bBuildHour, - float *fOscOffset, unsigned short *iTestCodeId); + unsigned char *bBoardOptions, unsigned long *iiSerialNumber, + unsigned char *bBuildYear, unsigned char *bBuildMonth, + unsigned char *bBuildDay, unsigned char *bBuildHour, + float *fOscOffset, unsigned short *iTestCodeId); short rpt_0x8F42 (TSIPPKT *rpt, unsigned char *bProdOptionsPre, - unsigned char *bProdNumberExt, unsigned short *iCaseSerialNumberPre, - unsigned long *iiCaseSerialNumber, unsigned long *iiProdNumber, - unsigned short *iPremiumOptions, unsigned short *iMachineID, - unsigned short *iKey); + unsigned char *bProdNumberExt, unsigned short *iCaseSerialNumberPre, + unsigned long *iiCaseSerialNumber, unsigned long *iiProdNumber, + unsigned short *iPremiumOptions, unsigned short *iMachineID, + unsigned short *iKey); short rpt_0x8F45 (TSIPPKT *rpt, unsigned char *bSegMask); short rpt_0x8F4A_16 (TSIPPKT *rpt, unsigned char *pps_enabled, - unsigned char *pps_timebase, unsigned char *pos_polarity, - double *pps_offset, float *bias_unc_threshold); + unsigned char *pps_timebase, unsigned char *pos_polarity, + double *pps_offset, float *bias_unc_threshold); short rpt_0x8F4B (TSIPPKT *rpt, unsigned long *decorr_max); short rpt_0x8F4D (TSIPPKT *rpt, unsigned long *event_mask); short rpt_0x8FA5 (TSIPPKT *rpt, unsigned char *spktmask); short rpt_0x8FAD (TSIPPKT *rpt, unsigned short *COUNT, double *FracSec, - unsigned char *Hour, unsigned char *Minute, unsigned char *Second, - unsigned char *Day, unsigned char *Month, unsigned short *Year, - unsigned char *Status, unsigned char *Flags); + unsigned char *Hour, unsigned char *Minute, unsigned char *Second, + unsigned char *Day, unsigned char *Month, unsigned short *Year, + unsigned char *Status, unsigned char *Flags); /**/ /* prototypes for command-encode primitives with suffix convention: */ @@ -390,11 +390,11 @@ void cmd_0x1F (TSIPPKT *cmd); void cmd_0x26 (TSIPPKT *cmd); void cmd_0x2F (TSIPPKT *cmd); void cmd_0x35s (TSIPPKT *cmd, unsigned char pos_code, unsigned char vel_code, - unsigned char time_code, unsigned char opts_code); + unsigned char time_code, unsigned char opts_code); void cmd_0x3C (TSIPPKT *cmd, unsigned char sv_prn); void cmd_0x3Ds (TSIPPKT *cmd, unsigned char baud_out, unsigned char baud_inp, - unsigned char char_code, unsigned char stopbitcode, - unsigned char output_mode, unsigned char input_mode); + unsigned char char_code, unsigned char stopbitcode, + unsigned char output_mode, unsigned char input_mode); void cmd_0xBBq (TSIPPKT *cmd, unsigned char subcode) ; /* prototypes 8E commands */ @@ -403,7 +403,7 @@ void cmd_0x8E41q (TSIPPKT *cmd); void cmd_0x8E42q (TSIPPKT *cmd); void cmd_0x8E4Aq (TSIPPKT *cmd); void cmd_0x8E4As (TSIPPKT *cmd, unsigned char PPSOnOff, unsigned char TimeBase, - unsigned char Polarity, double PPSOffset, float Uncertainty); + unsigned char Polarity, double PPSOffset, float Uncertainty); void cmd_0x8E4Bq (TSIPPKT *cmd); void cmd_0x8E4Ds (TSIPPKT *cmd, unsigned long AutoOutputMask); void cmd_0x8EADq (TSIPPKT *cmd); @@ -411,33 +411,33 @@ void cmd_0x8EADq (TSIPPKT *cmd); /* header/source border XXXXXXXXXXXXXXXXXXXXXXXXXX */ /* Trimble parse functions */ -static int parse0x8FAD P((TSIPPKT *, struct peer *)); -static int parse0x8F0B P((TSIPPKT *, struct peer *)); +static int parse0x8FAD (TSIPPKT *, struct peer *); +static int parse0x8F0B (TSIPPKT *, struct peer *); #ifdef TRIMBLE_OUTPUT_FUNC -static int parseany P((TSIPPKT *, struct peer *)); -static void TranslateTSIPReportToText P((TSIPPKT *, char *)); +static int parseany (TSIPPKT *, struct peer *); +static void TranslateTSIPReportToText (TSIPPKT *, char *); #endif /* TRIMBLE_OUTPUT_FUNC */ -static int parse0x5C P((TSIPPKT *, struct peer *)); -static int parse0x4F P((TSIPPKT *, struct peer *)); -static void tsip_input_proc P((TSIPPKT *, int)); +static int parse0x5C (TSIPPKT *, struct peer *); +static int parse0x4F (TSIPPKT *, struct peer *); +static void tsip_input_proc (TSIPPKT *, int); /* Trimble helper functions */ -static void bPutFloat P((float *, unsigned char *)); -static void bPutDouble P((double *, unsigned char *)); -static void bPutULong P((unsigned long *, unsigned char *)); -static int print_msg_table_header P((int rptcode, char *HdrStr, int force)); -static char * show_time P((float time_of_week)); +static void bPutFloat (float *, unsigned char *); +static void bPutDouble (double *, unsigned char *); +static void bPutULong (unsigned long *, unsigned char *); +static int print_msg_table_header (int rptcode, char *HdrStr, int force); +static char * show_time (float time_of_week); /* RIPE NCC functions */ -static void ripencc_control P((int, struct refclockstat *, struct - refclockstat *, struct peer *)); -static int ripencc_ppsapi P((struct peer *, int, int)); -static int ripencc_get_pps_ts P((struct ripencc_unit *, l_fp *)); -static int ripencc_start P((int, struct peer *)); -static void ripencc_shutdown P((int, struct peer *)); -static void ripencc_poll P((int, struct peer *)); -static void ripencc_send P((struct peer *, TSIPPKT spt)); -static void ripencc_receive P((struct recvbuf *)); +static void ripencc_control (int, const struct refclockstat *, + struct refclockstat *, struct peer *); +static int ripencc_ppsapi (struct peer *, int, int); +static int ripencc_get_pps_ts (struct ripencc_unit *, l_fp *); +static int ripencc_start (int, struct peer *); +static void ripencc_shutdown (int, struct peer *); +static void ripencc_poll (int, struct peer *); +static void ripencc_send (struct peer *, TSIPPKT spt); +static void ripencc_receive (struct recvbuf *); /* fill in reflock structure for our clock */ struct refclock refclock_ripencc = { @@ -471,12 +471,19 @@ ripencc_start(int unit, struct peer *peer) struct termios tio; TSIPPKT spt; + pp = peer->procptr; + /* * Open serial port */ (void)snprintf(device, sizeof(device), DEVICE, unit); - if (!(fd = refclock_open(device, SPEED232, LDISC_RAW))) + fd = refclock_open(device, SPEED232, LDISC_RAW); + if (fd <= 0) { + pp->io.fd = -1; return (0); + } + + pp->io.fd = fd; /* from refclock_palisade.c */ if (tcgetattr(fd, &tio) < 0) { @@ -497,23 +504,18 @@ ripencc_start(int unit, struct peer *peer) /* * Allocate and initialize unit structure */ - if (!(up = (struct ripencc_unit *) - emalloc(sizeof(struct ripencc_unit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct ripencc_unit)); - pp = peer->procptr; + up = emalloc_zero(sizeof(*up)); + pp->io.clock_recv = ripencc_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; - pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + pp->io.fd = -1; + close(fd); free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -548,47 +550,47 @@ ripencc_start(int unit, struct peer *peer) /* i/o opts */ /* trimble manual page A30 */ cmd_0x35s(&spt, - 0x1C, /* position */ - 0x00, /* velocity */ - 0x05, /* timing */ - 0x0a); /* auxilary */ + 0x1C, /* position */ + 0x00, /* velocity */ + 0x05, /* timing */ + 0x0a); /* auxilary */ ripencc_send(peer, spt); /* turn off port A */ cmd_0x3Ds (&spt, - 0x0B, /* baud_out */ - 0x0B, /* baud_inp */ - 0x07, /* char_code */ - 0x07, /* stopbitcode */ - 0x01, /* output_mode */ - 0x00); /* input_mode */ + 0x0B, /* baud_out */ + 0x0B, /* baud_inp */ + 0x07, /* char_code */ + 0x07, /* stopbitcode */ + 0x01, /* output_mode */ + 0x00); /* input_mode */ ripencc_send(peer, spt); /* set i/o options */ cmd_0x8E4As (&spt, - 0x01, /* PPS on */ - 0x01, /* Timebase UTC */ - 0x00, /* polarity positive */ - 0., /* 100 ft. cable XXX make flag */ - 1e-6 * GPS_C); /* turn of biasuncert. > (1us) */ + 0x01, /* PPS on */ + 0x01, /* Timebase UTC */ + 0x00, /* polarity positive */ + 0., /* 100 ft. cable XXX make flag */ + 1e-6 * GPS_C); /* turn of biasuncert. > (1us) */ ripencc_send(peer,spt); /* all outomatic packet output off */ cmd_0x8E4Ds(&spt, - 0x00000000); /* AutoOutputMask */ + 0x00000000); /* AutoOutputMask */ ripencc_send(peer, spt); cmd_0xBBq (&spt, - 0x00); /* query primary configuration */ + 0x00); /* query primary configuration */ ripencc_send(peer,spt); /* query PPS parameters */ - cmd_0x8E4Aq (&spt); /* query PPS params */ + cmd_0x8E4Aq (&spt); /* query PPS params */ ripencc_send(peer,spt); /* query survey limit */ - cmd_0x8E4Bq (&spt); /* query survey limit */ + cmd_0x8E4Bq (&spt); /* query survey limit */ ripencc_send(peer,spt); #ifdef DEBUG_NCC @@ -615,7 +617,7 @@ ripencc_start(int unit, struct peer *peer) static void ripencc_control( int unit, /* unit (not used) */ - struct refclockstat *in, /* input parameters (not used) */ + const struct refclockstat *in, /* input parameters (not used) */ struct refclockstat *out, /* output parameters (not used) */ struct peer *peer /* peer structure pointer */ ) @@ -628,7 +630,7 @@ ripencc_control( pp = peer->procptr; ripencc_ppsapi(peer, pp->sloppyclockflag & CLK_FLAG2, - pp->sloppyclockflag & CLK_FLAG3); + pp->sloppyclockflag & CLK_FLAG3); } @@ -647,10 +649,10 @@ ripencc_ppsapi( int capability; pp = peer->procptr; - up = (struct ripencc_unit *)pp->unitptr; + up = pp->unitptr; if (time_pps_getcap(up->handle, &capability) < 0) { msyslog(LOG_ERR, - "refclock_ripencc: time_pps_getcap failed: %m"); + "refclock_ripencc: time_pps_getcap failed: %m"); return (0); } memset(&up->pps_params, 0, sizeof(pps_params_t)); @@ -660,14 +662,14 @@ ripencc_ppsapi( up->pps_params.mode = capability & PPS_CAPTUREASSERT; if (!up->pps_params.mode) { msyslog(LOG_ERR, - "refclock_ripencc: invalid capture edge %d", - !enb_clear); + "refclock_ripencc: invalid capture edge %d", + !enb_clear); return (0); } up->pps_params.mode |= PPS_TSFMT_TSPEC; if (time_pps_setparams(up->handle, &up->pps_params) < 0) { msyslog(LOG_ERR, - "refclock_ripencc: time_pps_setparams failed: %m"); + "refclock_ripencc: time_pps_setparams failed: %m"); return (0); } if (enb_hardpps) { @@ -675,10 +677,10 @@ ripencc_ppsapi( up->pps_params.mode & ~PPS_TSFMT_TSPEC, PPS_TSFMT_TSPEC) < 0) { msyslog(LOG_ERR, - "refclock_ripencc: time_pps_kcbind failed: %m"); + "refclock_ripencc: time_pps_kcbind failed: %m"); return (0); } - pps_enable = 1; + hardpps_enable = 1; } peer->precision = PPS_PRECISION; @@ -686,9 +688,9 @@ ripencc_ppsapi( if (debug) { time_pps_getparams(up->handle, &up->pps_params); printf( - "refclock_ripencc: capability 0x%x version %d mode 0x%x kern %d\n", - capability, up->pps_params.api_version, - up->pps_params.mode, enb_hardpps); + "refclock_ripencc: capability 0x%x version %d mode 0x%x kern %d\n", + capability, up->pps_params.api_version, + up->pps_params.mode, enb_hardpps); } #endif /* DEBUG_NCC */ @@ -713,7 +715,7 @@ ripencc_get_pps_ts( l_fp tstmp; #ifdef DEBUG_PPS - msyslog(LOG_INFO,"ripencc_get_pps_ts\n"); + msyslog(LOG_INFO,"ripencc_get_pps_ts"); #endif /* DEBUG_PPS */ @@ -726,7 +728,7 @@ ripencc_get_pps_ts( timeout.tv_nsec = 0; memcpy(&pps_info, &up->pps_info, sizeof(pps_info_t)); if (time_pps_fetch(up->handle, PPS_TSFMT_TSPEC, &up->pps_info, - &timeout) < 0) + &timeout) < 0) return (0); if (up->pps_params.mode & PPS_CAPTUREASSERT) { if (pps_info.assert_sequence == @@ -750,8 +752,8 @@ ripencc_get_pps_ts( tstmp.l_uf = (u_int32)dtemp; #ifdef DEBUG_PPS - msyslog(LOG_INFO,"ts.tv_sec: %d\n",(int)ts.tv_sec); - msyslog(LOG_INFO,"ts.tv_nsec: %ld\n",ts.tv_nsec); + msyslog(LOG_INFO,"ts.tv_sec: %d",(int)ts.tv_sec); + msyslog(LOG_INFO,"ts.tv_nsec: %ld",ts.tv_nsec); #endif /* DEBUG_PPS */ *tsptr = tstmp; @@ -768,14 +770,17 @@ ripencc_shutdown(int unit, struct peer *peer) struct refclockproc *pp; pp = peer->procptr; - up = (struct ripencc_unit *)pp->unitptr; + up = pp->unitptr; - if (up->handle != 0) - time_pps_destroy(up->handle); - - io_closeclock(&pp->io); + if (up != NULL) { + if (up->handle != 0) + time_pps_destroy(up->handle); + free(up); + } + if (-1 != pp->io.fd) + io_closeclock(&pp->io); - free(up); + return; } /* @@ -793,7 +798,7 @@ ripencc_poll(int unit, struct peer *peer) fprintf(stderr, "ripencc_poll(%d)\n", unit); #endif /* DEBUG_NCC */ pp = peer->procptr; - up = (struct ripencc_unit *)pp->unitptr; + up = pp->unitptr; if (up->pollcnt == 0) refclock_report(peer, CEVNT_TIMEOUT); else @@ -824,7 +829,7 @@ ripencc_send(struct peer *peer, TSIPPKT spt) register struct refclockproc *pp; pp = peer->procptr; - up = (struct ripencc_unit *)pp->unitptr; + up = pp->unitptr; if (debug) printf("ripencc_send(%d, %02X)\n", up->unit, cmd); } @@ -843,7 +848,7 @@ ripencc_send(struct peer *peer, TSIPPKT spt) return; } - if (*ip == 0x10) /* byte stuffing */ + if (*ip == 0x10) /* byte stuffing */ *op++ = 0x10; *op++ = *ip++; } @@ -867,7 +872,7 @@ ripencc_send(struct peer *peer, TSIPPKT spt) #endif /* DEBUG_RAW */ if (write(peer->procptr->io.fd, obuf, op-obuf) == -1) { - refclock_report(peer, CEVNT_FAULT); + refclock_report(peer, CEVNT_FAULT); } } @@ -884,12 +889,12 @@ ripencc_receive(struct recvbuf *rbufp) register struct ripencc_unit *up; register struct refclockproc *pp; struct peer *peer; - static TSIPPKT rpt; /* structure for current incoming TSIP report */ - TSIPPKT spt; /* send packet */ + static TSIPPKT rpt; /* for current incoming TSIP report */ + TSIPPKT spt; /* send packet */ int ns_since_pps; int i; char *cp; - /* Use these variables to hold data until we decide its worth keeping */ + /* these variables hold data until we decide it's worth keeping */ char rd_lastcode[BMAX]; l_fp rd_tmp; u_short rd_lencode; @@ -899,9 +904,9 @@ ripencc_receive(struct recvbuf *rbufp) /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct ripencc_unit *)pp->unitptr; + up = pp->unitptr; rd_lencode = refclock_gtlin(rbufp, rd_lastcode, BMAX, &rd_tmp); #ifdef DEBUG_RAW @@ -910,12 +915,14 @@ ripencc_receive(struct recvbuf *rbufp) #endif /* DEBUG_RAW */ #ifdef DEBUG_RAW - if (debug) { /* print raw packet */ + if (debug) { /* print raw packet */ int i; unsigned char *cp; printf("ripencc_receive: len %d\n", rbufp->recv_length); - for (i=1, cp=(char*)&rbufp->recv_space; i <= rbufp->recv_length; i++, cp++) { + for (i=1, cp=(char*)&rbufp->recv_space; + i <= rbufp->recv_length; + i++, cp++) { printf(" %02X", *cp); if (i%10 == 0) printf("\n"); @@ -927,7 +934,7 @@ ripencc_receive(struct recvbuf *rbufp) cp = (char*) &rbufp->recv_space; i=rbufp->recv_length; - while (i--) { /* loop over received chars */ + while (i--) { /* loop over received chars */ tsip_input_proc(&rpt, (unsigned char) *cp++); @@ -936,30 +943,32 @@ ripencc_receive(struct recvbuf *rbufp) switch (rpt.code) { - case 0x8F: /* superpacket */ + case 0x8F: /* superpacket */ switch (rpt.buf[0]) { - case 0xAD: /* UTC Time */ + case 0xAD: /* UTC Time */ /* - * When polling on port B the timecode - * is the time of the previous PPS. - * If we completed receiving the packet - * less than 150ms after the turn of the second, - * it may have the code of the previous second. - * We do not trust that and simply poll again - * without even parsing it. - * - * More elegant would be to re-schedule the poll, - * but I do not know (yet) how to do that cleanly. - * - */ + ** When polling on port B the timecode is + ** the time of the previous PPS. If we + ** completed receiving the packet less than + ** 150ms after the turn of the second, it + ** may have the code of the previous second. + ** We do not trust that and simply poll + ** again without even parsing it. + ** + ** More elegant would be to re-schedule the + ** poll, but I do not know (yet) how to do + ** that cleanly. + ** + */ /* BLA ns_since_pps = ncc_tstmp(rbufp, &trtmp); */ /* if (up->polled && ns_since_pps > -1 && ns_since_pps < 150) { */ - ns_since_pps=200; + ns_since_pps = 200; if (up->polled && ns_since_pps < 150) { - msyslog(LOG_INFO, "%s(): up->polled",__FUNCTION__); + msyslog(LOG_INFO, "%s(): up->polled", + __FUNCTION__); ripencc_poll(up->unit, peer); break; } @@ -970,9 +979,9 @@ ripencc_receive(struct recvbuf *rbufp) * from results. */ if (parse0x8FAD(&rpt, peer) < 0) { - msyslog(LOG_INFO, "%s(): parse0x8FAD < 0",__FUNCTION__); - refclock_report(peer, CEVNT_BADREPLY); - break; + msyslog(LOG_INFO, "%s(): parse0x8FAD < 0",__FUNCTION__); + refclock_report(peer, CEVNT_BADREPLY); + break; } /* * If the PPSAPI is working, rather use its @@ -985,11 +994,11 @@ ripencc_receive(struct recvbuf *rbufp) pp->nsec = 0; } else - msyslog(LOG_INFO, "%s(): ripencc_get_pps_ts returns failure\n",__FUNCTION__); + msyslog(LOG_INFO, "%s(): ripencc_get_pps_ts returns failure",__FUNCTION__); if (!up->polled) { - msyslog(LOG_INFO, "%s(): unrequested packet\n",__FUNCTION__); + msyslog(LOG_INFO, "%s(): unrequested packet",__FUNCTION__); /* unrequested packet */ break; } @@ -1009,9 +1018,10 @@ ripencc_receive(struct recvbuf *rbufp) } /* - * Process the new sample in the median filter and determine the - * reference clock offset and dispersion. - */ + ** Process the new sample in the median + ** filter and determine the reference clock + ** offset and dispersion. + */ if (!refclock_process(pp)) { msyslog(LOG_INFO, "%s(): !refclock_process",__FUNCTION__); refclock_report(peer, CEVNT_BADTIME); @@ -1021,13 +1031,14 @@ ripencc_receive(struct recvbuf *rbufp) refclock_receive(peer); break; - case 0x0B: /* comprehensive time packet */ + case 0x0B: /* comprehensive time packet */ parse0x8F0B(&rpt, peer); break; - default: /* other superpackets */ + default: /* other superpackets */ #ifdef DEBUG_NCC - msyslog(LOG_INFO, "%s(): calling parseany",__FUNCTION__); + msyslog(LOG_INFO, "%s(): calling parseany", + __FUNCTION__); #endif /* DEBUG_NCC */ #ifdef TRIMBLE_OUTPUT_FUNC parseany(&rpt, peer); @@ -1036,15 +1047,15 @@ ripencc_receive(struct recvbuf *rbufp) } break; - case 0x4F: /* UTC parameters, for leap info */ + case 0x4F: /* UTC parameters, for leap info */ parse0x4F(&rpt, peer); break; - case 0x5C: /* sat tracking data */ + case 0x5C: /* sat tracking data */ parse0x5C(&rpt, peer); break; - default: /* other packets */ + default: /* other packets */ #ifdef TRIMBLE_OUTPUT_FUNC parseany(&rpt, peer); #endif /* TRIMBLE_OUTPUT_FUNC */ @@ -1059,33 +1070,45 @@ ripencc_receive(struct recvbuf *rbufp) * (so not from parseany) */ -void cmd_0x1F (TSIPPKT *cmd) /* request software versions */ +void +cmd_0x1F( + TSIPPKT *cmd + ) { cmd->len = 0; cmd->code = 0x1F; } -void cmd_0x26 (TSIPPKT *cmd) /* request receiver health */ +void +cmd_0x26( + TSIPPKT *cmd + ) { cmd->len = 0; cmd->code = 0x26; } - - - -void cmd_0x2F (TSIPPKT *cmd) /* request UTC params */ +void +cmd_0x2F( + TSIPPKT *cmd + ) { cmd->len = 0; cmd->code = 0x2F; } -void cmd_0x35s (TSIPPKT *cmd, unsigned char pos_code, unsigned char vel_code, - unsigned char time_code, unsigned char opts_code) /* set serial I/O options */ +void +cmd_0x35s( + TSIPPKT *cmd, + unsigned char pos_code, + unsigned char vel_code, + unsigned char time_code, + unsigned char opts_code + ) { cmd->buf[0] = pos_code; cmd->buf[1] = vel_code; @@ -1094,24 +1117,34 @@ void cmd_0x35s (TSIPPKT *cmd, unsigned char pos_code, unsigned char vel_code, cmd->len = 4; cmd->code = 0x35; } -void cmd_0x3C (TSIPPKT *cmd, unsigned char sv_prn) + /* request tracking status */ +void +cmd_0x3C( + TSIPPKT *cmd, + unsigned char sv_prn + ) { cmd->buf[0] = sv_prn; cmd->len = 1; cmd->code = 0x3C; } - -void cmd_0x3Ds (TSIPPKT *cmd, - unsigned char baud_out, unsigned char baud_inp, - unsigned char char_code, unsigned char stopbitcode, - unsigned char output_mode, unsigned char input_mode) /* set Channel A configuration for dual-port operation */ +void +cmd_0x3Ds( + TSIPPKT *cmd, + unsigned char baud_out, + unsigned char baud_inp, + unsigned char char_code, + unsigned char stopbitcode, + unsigned char output_mode, + unsigned char input_mode + ) { cmd->buf[0] = baud_out; /* XMT baud rate */ cmd->buf[1] = baud_inp; /* RCV baud rate */ - cmd->buf[2] = char_code; /* parity and #bits per byte */ + cmd->buf[2] = char_code; /* parity and #bits per byte */ cmd->buf[3] = stopbitcode; /* number of stop bits code */ cmd->buf[4] = output_mode; /* Ch. A transmission mode */ cmd->buf[5] = input_mode; /* Ch. A reception mode */ @@ -1121,10 +1154,12 @@ void cmd_0x3Ds (TSIPPKT *cmd, /* query primary configuration */ -void cmd_0xBBq (TSIPPKT *cmd, - unsigned char subcode) +void +cmd_0xBBq( + TSIPPKT *cmd, + unsigned char subcode + ) { - cmd->len = 1; cmd->code = 0xBB; cmd->buf[0] = subcode; @@ -1132,36 +1167,47 @@ void cmd_0xBBq (TSIPPKT *cmd, /**** Superpackets ****/ -void cmd_0x8E0Bq (TSIPPKT *cmd) /* 8E-0B to query 8F-0B controls */ +void +cmd_0x8E0Bq( + TSIPPKT *cmd + ) { - cmd->len = 1; cmd->code = 0x8E; cmd->buf[0] = 0x0B; } -void cmd_0x8E41q (TSIPPKT *cmd) /* 8F-41 to query board serial number */ +void +cmd_0x8E41q( + TSIPPKT *cmd + ) { - cmd->len = 1; cmd->code = 0x8E; cmd->buf[0] = 0x41; } -void cmd_0x8E42q (TSIPPKT *cmd) /* 8F-42 to query product serial number */ +void +cmd_0x8E42q( + TSIPPKT *cmd + ) { - cmd->len = 1; cmd->code = 0x8E; cmd->buf[0] = 0x42; } -void cmd_0x8E4Aq (TSIPPKT *cmd) + + /* 8F-4A to query PPS parameters */ +void +cmd_0x8E4Aq( + TSIPPKT *cmd + ) { cmd->len = 1; cmd->code = 0x8E; @@ -1170,12 +1216,15 @@ void cmd_0x8E4Aq (TSIPPKT *cmd) /* set i/o options */ -void cmd_0x8E4As (TSIPPKT *cmd, - unsigned char PPSOnOff, - unsigned char TimeBase, - unsigned char Polarity, - double PPSOffset, - float Uncertainty) +void +cmd_0x8E4As( + TSIPPKT *cmd, + unsigned char PPSOnOff, + unsigned char TimeBase, + unsigned char Polarity, + double PPSOffset, + float Uncertainty + ) { cmd->len = 16; cmd->code = 0x8E; @@ -1186,18 +1235,24 @@ void cmd_0x8E4As (TSIPPKT *cmd, bPutDouble (&PPSOffset, &cmd->buf[4]); bPutFloat (&Uncertainty, &cmd->buf[12]); } -void cmd_0x8E4Bq (TSIPPKT *cmd) + /* 8F-4B query survey limit */ +void +cmd_0x8E4Bq( + TSIPPKT *cmd + ) { cmd->len = 1; cmd->code = 0x8E; cmd->buf[0] = 0x4B; } - /* poll for UTC superpacket */ -void cmd_0x8EADq (TSIPPKT *cmd) /* 8E-AD to query 8F-AD controls */ +void +cmd_0x8EADq( + TSIPPKT *cmd + ) { cmd->len = 1; cmd->code = 0x8E; @@ -1205,8 +1260,11 @@ void cmd_0x8EADq (TSIPPKT *cmd) } /* all outomatic packet output off */ -void cmd_0x8E4Ds (TSIPPKT *cmd, - unsigned long AutoOutputMask) +void +cmd_0x8E4Ds( + TSIPPKT *cmd, + unsigned long AutoOutputMask + ) { cmd->len = 5; cmd->code = 0x8E; @@ -1215,88 +1273,106 @@ void cmd_0x8E4Ds (TSIPPKT *cmd, } - - -/* for DOS machines, reverse order of bytes as they come through the - * serial port. */ +/* + * for DOS machines, reverse order of bytes as they come through the + * serial port. + */ #ifdef BYTESWAP -static short bGetShort (unsigned char *bp) +static short +bGetShort( + unsigned char *bp + ) { short outval; - unsigned char *optr; + unsigned char *optr; - optr = (unsigned char*)&outval + 1; - *optr-- = *bp++; - *optr = *bp; + optr = (unsigned char*)&outval + 1; + *optr-- = *bp++; + *optr = *bp; return outval; } #ifdef TRIMBLE_OUTPUT_FUNC -static unsigned short bGetUShort (unsigned char *bp) +static unsigned short +bGetUShort( + unsigned char *bp + ) { unsigned short outval; - unsigned char *optr; + unsigned char *optr; - optr = (unsigned char*)&outval + 1; - *optr-- = *bp++; - *optr = *bp; + optr = (unsigned char*)&outval + 1; + *optr-- = *bp++; + *optr = *bp; return outval; } -static long bGetLong (unsigned char *bp) +static long +bGetLong( + unsigned char *bp + ) { long outval; - unsigned char *optr; + unsigned char *optr; - optr = (unsigned char*)&outval + 3; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr = *bp; + optr = (unsigned char*)&outval + 3; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr = *bp; return outval; } -static unsigned long bGetULong (unsigned char *bp) +static unsigned long +bGetULong( + unsigned char *bp + ) { unsigned long outval; - unsigned char *optr; + unsigned char *optr; - optr = (unsigned char*)&outval + 3; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr = *bp; + optr = (unsigned char*)&outval + 3; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr = *bp; return outval; } #endif /* TRIMBLE_OUTPUT_FUNC */ -static float bGetSingle (unsigned char *bp) +static float +bGetSingle( + unsigned char *bp + ) { float outval; - unsigned char *optr; + unsigned char *optr; - optr = (unsigned char*)&outval + 3; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr = *bp; + optr = (unsigned char*)&outval + 3; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr = *bp; return outval; } -static double bGetDouble (unsigned char *bp) +static double +bGetDouble( + unsigned char *bp + ) { double outval; - unsigned char *optr; - - optr = (unsigned char*)&outval + 7; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr-- = *bp++; - *optr = *bp; + unsigned char *optr; + + optr = (unsigned char*)&outval + 7; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr-- = *bp++; + *optr = *bp; return outval; } @@ -1316,43 +1392,52 @@ static double bGetDouble (unsigned char *bp) #ifdef BYTESWAP void -bPutFloat (float *in, unsigned char *out) +bPutFloat( + float *in, + unsigned char *out + ) { unsigned char *inptr; - inptr = (unsigned char*)in + 3; - *out++ = *inptr--; - *out++ = *inptr--; - *out++ = *inptr--; - *out = *inptr; + inptr = (unsigned char*)in + 3; + *out++ = *inptr--; + *out++ = *inptr--; + *out++ = *inptr--; + *out = *inptr; } static void -bPutULong (unsigned long *in, unsigned char *out) +bPutULong( + unsigned long *in, + unsigned char *out + ) { unsigned char *inptr; - inptr = (unsigned char*)in + 3; - *out++ = *inptr--; - *out++ = *inptr--; - *out++ = *inptr--; - *out = *inptr; + inptr = (unsigned char*)in + 3; + *out++ = *inptr--; + *out++ = *inptr--; + *out++ = *inptr--; + *out = *inptr; } static void -bPutDouble (double *in, unsigned char *out) +bPutDouble( + double *in, + unsigned char *out + ) { unsigned char *inptr; - inptr = (unsigned char*)in + 7; - *out++ = *inptr--; - *out++ = *inptr--; - *out++ = *inptr--; - *out++ = *inptr--; - *out++ = *inptr--; - *out++ = *inptr--; - *out++ = *inptr--; - *out = *inptr; + inptr = (unsigned char*)in + 7; + *out++ = *inptr--; + *out++ = *inptr--; + *out++ = *inptr--; + *out++ = *inptr--; + *out++ = *inptr--; + *out++ = *inptr--; + *out++ = *inptr--; + *out = *inptr; } #else /* not BYTESWAP */ @@ -1374,9 +1459,10 @@ void bPutDouble (double a, unsigned char *cmdbuf){*(double*) cmdbuf = a;} */ static int -parse0x8FAD(rpt, peer) - TSIPPKT *rpt; - struct peer *peer; +parse0x8FAD( + TSIPPKT *rpt, + struct peer *peer + ) { register struct refclockproc *pp; register struct ripencc_unit *up; @@ -1403,7 +1489,6 @@ parse0x8FAD(rpt, peer) return(-1); } - if (bGetDouble(&buf[3]) != 0.0) { #ifdef DEBUG_NCC if (debug) @@ -1412,14 +1497,14 @@ parse0x8FAD(rpt, peer) return(-1); } - hour = (unsigned int) buf[11]; - minute = (unsigned int) buf[12]; - second = (unsigned int) buf[13]; + hour = (unsigned int) buf[11]; + minute = (unsigned int) buf[12]; + second = (unsigned int) buf[13]; day = (unsigned int) buf[14]; month = (unsigned int) buf[15]; year = bGetShort(&buf[16]); - trackstat = buf[18]; - utcflags = buf[19]; + trackstat = buf[18]; + utcflags = buf[19]; sprintf(logbuf, "U1 %d.%d.%d %02d:%02d:%02d %d %02x", @@ -1438,7 +1523,7 @@ parse0x8FAD(rpt, peer) /* poll for UTC parameters once and then if UTC flag changed */ up = (struct ripencc_unit *) pp->unitptr; if (utcflags != up->utcflags) { - TSIPPKT spt; /* local structure for send packet */ + TSIPPKT spt; /* local structure for send packet */ cmd_0x2F (&spt); /* request UTC params */ ripencc_send(peer,spt); up->utcflags = utcflags; @@ -1458,7 +1543,7 @@ parse0x8FAD(rpt, peer) if (month < 1 || month > 12 || day < 1 || day > 31) return(-1); - if (pp->year % 4) { + if (pp->year % 4) { /* XXX: use is_leapyear() ? */ if (day > day1tab[month - 1]) return(-1); for (i = 0; i < month - 1; i++) @@ -1476,7 +1561,9 @@ parse0x8FAD(rpt, peer) pp->nsec = 0; if ((utcflags&UTCF_LEAP_PNDG) && up->leapdelta != 0) - pp-> leap = (up->leapdelta > 0 ? LEAP_ADDSECOND : LEAP_DELSECOND); + pp-> leap = (up->leapdelta > 0) + ? LEAP_ADDSECOND + : LEAP_DELSECOND; else pp-> leap = LEAP_NOWARNING; @@ -1486,13 +1573,15 @@ parse0x8FAD(rpt, peer) /* * Parse comprehensive time packet * - * 0 = success + * 0 = success * -1 = errors */ -int parse0x8F0B(rpt, peer) - TSIPPKT *rpt; - struct peer *peer; +int +parse0x8F0B( + TSIPPKT *rpt, + struct peer *peer + ) { register struct refclockproc *pp; @@ -1539,7 +1628,6 @@ int parse0x8F0B(rpt, peer) hour = (unsigned int )fmod(tow / 3600., 24.); } - day = (unsigned int) buf[11]; month = (unsigned int) buf[12]; year = bGetShort(&buf[13]); @@ -1587,9 +1675,10 @@ int parse0x8F0B(rpt, peer) sprintf(logbuf, "C1 %02d%02d%04d %02d%02d%02d %d %7.0f %.1f %.0f %.1f %d %02d%09.6f %c %02d%09.6f %c %.0f %d %d %d %d %d %d %d %d", - day, month, year, hour, minute, second, mode, bias, biasunc, rate, rateunc, utcoff, - lat_deg, lat_min, north_south, lon_deg, lon_min, east_west, alt, - sv[0], sv[1], sv[2], sv[3], sv[4], sv[5], sv[6], sv[7]); + day, month, year, hour, minute, second, mode, bias, biasunc, + rate, rateunc, utcoff, lat_deg, lat_min, north_south, lon_deg, + lon_min, east_west, alt, sv[0], sv[1], sv[2], sv[3], sv[4], + sv[5], sv[6], sv[7]); #ifdef DEBUG_NCC if (debug) @@ -1605,9 +1694,11 @@ int parse0x8F0B(rpt, peer) /* * Parse any packet using Trimble machinery */ -int parseany(rpt, peer) - TSIPPKT *rpt; - struct peer *peer; +int +parseany( + TSIPPKT *rpt, + struct peer *peer + ) { static char logbuf[1024]; /* logging string buffer */ @@ -1631,9 +1722,11 @@ int parseany(rpt, peer) * -1 = errors */ -int parse0x4F(rpt, peer) - TSIPPKT *rpt; - struct peer *peer; +int +parse0x4F( + TSIPPKT *rpt, + struct peer *peer + ) { register struct ripencc_unit *up; @@ -1680,9 +1773,11 @@ int parse0x4F(rpt, peer) * -1 = errors */ -int parse0x5C(rpt, peer) - TSIPPKT *rpt; - struct peer *peer; +int +parse0x5C( + TSIPPKT *rpt, + struct peer *peer + ) { unsigned char prn, channel, aqflag, ephstat; float snr, azinuth, elevation; @@ -1784,13 +1879,15 @@ int parse0x5C(rpt, peer) */ -/**/ -static void tsip_input_proc ( - TSIPPKT *rpt, - int inbyte) -/* reads bytes until serial buffer is empty or a complete report +/* + * reads bytes until serial buffer is empty or a complete report * has been received; end of report is signified by DLE ETX. */ +static void +tsip_input_proc( + TSIPPKT *rpt, + int inbyte + ) { unsigned char newbyte; @@ -1799,71 +1896,71 @@ static void tsip_input_proc ( newbyte = (unsigned char)(inbyte); switch (rpt->status) { - case TSIP_PARSED_DLE_1: + case TSIP_PARSED_DLE_1: switch (newbyte) { - case 0: - case ETX: - /* illegal TSIP IDs */ - rpt->len = 0; + case 0: + case ETX: + /* illegal TSIP IDs */ + rpt->len = 0; rpt->status = TSIP_PARSED_EMPTY; break; - case DLE: - /* try normal message start again */ + case DLE: + /* try normal message start again */ rpt->len = 0; rpt->status = TSIP_PARSED_DLE_1; break; - default: - /* legal TSIP ID; start message */ + default: + /* legal TSIP ID; start message */ rpt->code = newbyte; - rpt->len = 0; + rpt->len = 0; rpt->status = TSIP_PARSED_DATA; break; } break; - case TSIP_PARSED_DATA: + case TSIP_PARSED_DATA: switch (newbyte) { - case DLE: - /* expect DLE or ETX next */ + case DLE: + /* expect DLE or ETX next */ rpt->status = TSIP_PARSED_DLE_2; break; - default: - /* normal data byte */ + default: + /* normal data byte */ rpt->buf[rpt->len] = newbyte; rpt->len++; - /* no change in rpt->status */ + /* no change in rpt->status */ break; } break; - case TSIP_PARSED_DLE_2: + case TSIP_PARSED_DLE_2: switch (newbyte) { - case DLE: - /* normal data byte */ + case DLE: + /* normal data byte */ rpt->buf[rpt->len] = newbyte; rpt->len++; rpt->status = TSIP_PARSED_DATA; break; - case ETX: + case ETX: /* end of message; return TRUE here. */ rpt->status = TSIP_PARSED_FULL; break; - default: + default: /* error: treat as TSIP_PARSED_DLE_1; start new report packet */ rpt->code = newbyte; - rpt->len = 0; + rpt->len = 0; rpt->status = TSIP_PARSED_DATA; } break; - case TSIP_PARSED_FULL: - case TSIP_PARSED_EMPTY: - default: + case TSIP_PARSED_FULL: + case TSIP_PARSED_EMPTY: + default: switch (newbyte) { - case DLE: - /* normal message start */ + case DLE: + /* normal message start */ rpt->len = 0; rpt->status = TSIP_PARSED_DLE_1; break; - default: + default: /* error: ignore newbyte */ rpt->len = 0; rpt->status = TSIP_PARSED_EMPTY; @@ -1880,14 +1977,17 @@ static void tsip_input_proc ( #ifdef TRIMBLE_OUTPUT_FUNC /**/ -short rpt_0x3D (TSIPPKT *rpt, - unsigned char *tx_baud_index, - unsigned char *rx_baud_index, - unsigned char *char_format_index, - unsigned char *stop_bits, - unsigned char *tx_mode_index, - unsigned char *rx_mode_index) /* Channel A configuration for dual port operation */ +short +rpt_0x3D( + TSIPPKT *rpt, + unsigned char *tx_baud_index, + unsigned char *rx_baud_index, + unsigned char *char_format_index, + unsigned char *stop_bits, + unsigned char *tx_mode_index, + unsigned char *rx_mode_index + ) { unsigned char *buf; buf = rpt->buf; @@ -1903,19 +2003,22 @@ short rpt_0x3D (TSIPPKT *rpt, } /**/ -short rpt_0x40 (TSIPPKT *rpt, - unsigned char *sv_prn, - short *week_num, - float *t_zc, - float *eccentricity, - float *t_oa, - float *i_0, - float *OMEGA_dot, - float *sqrt_A, - float *OMEGA_0, - float *omega, - float *M_0) /* almanac data for specified satellite */ +short +rpt_0x40( + TSIPPKT *rpt, + unsigned char *sv_prn, + short *week_num, + float *t_zc, + float *eccentricity, + float *t_oa, + float *i_0, + float *OMEGA_dot, + float *sqrt_A, + float *OMEGA_0, + float *omega, + float *M_0 + ) { unsigned char *buf; buf = rpt->buf; @@ -1935,11 +2038,14 @@ short rpt_0x40 (TSIPPKT *rpt, return FALSE; } -short rpt_0x41 (TSIPPKT *rpt, - float *time_of_week, - float *UTC_offset, - short *week_num) /* GPS time */ +short +rpt_0x41( + TSIPPKT *rpt, + float *time_of_week, + float *UTC_offset, + short *week_num + ) { unsigned char *buf; buf = rpt->buf; @@ -1951,10 +2057,13 @@ short rpt_0x41 (TSIPPKT *rpt, return FALSE; } -short rpt_0x42 (TSIPPKT *rpt, - float pos_ECEF[3], - float *time_of_fix) /* position in ECEF, single precision */ +short +rpt_0x42( + TSIPPKT *rpt, + float pos_ECEF[3], + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -1967,11 +2076,14 @@ short rpt_0x42 (TSIPPKT *rpt, return FALSE; } -short rpt_0x43 (TSIPPKT *rpt, - float ECEF_vel[3], - float *freq_offset, - float *time_of_fix) /* velocity in ECEF, single precision */ +short +rpt_0x43( + TSIPPKT *rpt, + float ECEF_vel[3], + float *freq_offset, + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -1985,18 +2097,21 @@ short rpt_0x43 (TSIPPKT *rpt, return FALSE; } -short rpt_0x45 (TSIPPKT *rpt, - unsigned char *major_nav_version, - unsigned char *minor_nav_version, - unsigned char *nav_day, - unsigned char *nav_month, - unsigned char *nav_year, - unsigned char *major_dsp_version, - unsigned char *minor_dsp_version, - unsigned char *dsp_day, - unsigned char *dsp_month, - unsigned char *dsp_year) /* software versions */ +short +rpt_0x45( + TSIPPKT *rpt, + unsigned char *major_nav_version, + unsigned char *minor_nav_version, + unsigned char *nav_day, + unsigned char *nav_month, + unsigned char *nav_year, + unsigned char *major_dsp_version, + unsigned char *minor_dsp_version, + unsigned char *dsp_day, + unsigned char *dsp_month, + unsigned char *dsp_year + ) { unsigned char *buf; buf = rpt->buf; @@ -2015,10 +2130,13 @@ short rpt_0x45 (TSIPPKT *rpt, return FALSE; } -short rpt_0x46 (TSIPPKT *rpt, - unsigned char *status1, - unsigned char *status2) /* receiver health and status */ +short +rpt_0x46( + TSIPPKT *rpt, + unsigned char *status1, + unsigned char *status2 + ) { unsigned char *buf; buf = rpt->buf; @@ -2029,10 +2147,14 @@ short rpt_0x46 (TSIPPKT *rpt, return FALSE; } -short rpt_0x47 (TSIPPKT *rpt, - unsigned char *nsvs, unsigned char *sv_prn, - float *snr) /* signal levels for all satellites tracked */ +short +rpt_0x47( + TSIPPKT *rpt, + unsigned char *nsvs, + unsigned char *sv_prn, + float *snr + ) { short isv; unsigned char *buf; @@ -2047,9 +2169,12 @@ short rpt_0x47 (TSIPPKT *rpt, return FALSE; } -short rpt_0x48 (TSIPPKT *rpt, - unsigned char *message) /* GPS system message */ +short +rpt_0x48( + TSIPPKT *rpt, + unsigned char *message + ) { unsigned char *buf; buf = rpt->buf; @@ -2060,9 +2185,12 @@ short rpt_0x48 (TSIPPKT *rpt, return FALSE; } -short rpt_0x49 (TSIPPKT *rpt, - unsigned char *sv_health) /* health for all satellites from almanac health page */ +short +rpt_0x49( + TSIPPKT *rpt, + unsigned char *sv_health + ) { short i; unsigned char *buf; @@ -2073,13 +2201,16 @@ short rpt_0x49 (TSIPPKT *rpt, return FALSE; } -short rpt_0x4A (TSIPPKT *rpt, - float *lat, - float *lon, - float *alt, - float *clock_bias, - float *time_of_fix) /* position in lat-lon-alt, single precision */ +short +rpt_0x4A( + TSIPPKT *rpt, + float *lat, + float *lon, + float *alt, + float *clock_bias, + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -2093,9 +2224,14 @@ short rpt_0x4A (TSIPPKT *rpt, return FALSE; } -short rpt_0x4A_2 (TSIPPKT *rpt, - float *alt, float *dummy , unsigned char *alt_flag) /* reference altitude parameters */ +short +rpt_0x4A_2( + TSIPPKT *rpt, + float *alt, + float *dummy, + unsigned char *alt_flag + ) { unsigned char *buf; @@ -2108,11 +2244,14 @@ short rpt_0x4A_2 (TSIPPKT *rpt, return FALSE; } -short rpt_0x4B (TSIPPKT *rpt, - unsigned char *machine_id, - unsigned char *status3, - unsigned char *status4) /* machine ID code, status */ +short +rpt_0x4B( + TSIPPKT *rpt, + unsigned char *machine_id, + unsigned char *status3, + unsigned char *status4 + ) { unsigned char *buf; buf = rpt->buf; @@ -2124,13 +2263,16 @@ short rpt_0x4B (TSIPPKT *rpt, return FALSE; } -short rpt_0x4C (TSIPPKT *rpt, - unsigned char *dyn_code, - float *el_mask, - float *snr_mask, - float *dop_mask, - float *dop_switch) /* operating parameters and masks */ +short +rpt_0x4C( + TSIPPKT *rpt, + unsigned char *dyn_code, + float *el_mask, + float *snr_mask, + float *dop_mask, + float *dop_switch + ) { unsigned char *buf; buf = rpt->buf; @@ -2144,9 +2286,12 @@ short rpt_0x4C (TSIPPKT *rpt, return FALSE; } -short rpt_0x4D (TSIPPKT *rpt, - float *osc_offset) /* oscillator offset */ +short +rpt_0x4D( + TSIPPKT *rpt, + float *osc_offset + ) { unsigned char *buf; buf = rpt->buf; @@ -2156,9 +2301,12 @@ short rpt_0x4D (TSIPPKT *rpt, return FALSE; } -short rpt_0x4E (TSIPPKT *rpt, - unsigned char *response) /* yes/no response to command to set GPS time */ +short +rpt_0x4E( + TSIPPKT *rpt, + unsigned char *response + ) { unsigned char *buf; buf = rpt->buf; @@ -2168,16 +2316,19 @@ short rpt_0x4E (TSIPPKT *rpt, return FALSE; } -short rpt_0x4F (TSIPPKT *rpt, - double *a0, - float *a1, - float *time_of_data, - short *dt_ls, - short *wn_t, - short *wn_lsf, - short *dn, - short *dt_lsf) /* UTC data */ +short +rpt_0x4F( + TSIPPKT *rpt, + double *a0, + float *a1, + float *time_of_data, + short *dt_ls, + short *wn_t, + short *wn_lsf, + short *dn, + short *dt_lsf + ) { unsigned char *buf; buf = rpt->buf; @@ -2195,11 +2346,14 @@ short rpt_0x4F (TSIPPKT *rpt, } /**/ -short rpt_0x54 (TSIPPKT *rpt, - float *clock_bias, - float *freq_offset, - float *time_of_fix) /* clock offset and frequency offset in 1-SV (0-D) mode */ +short +rpt_0x54( + TSIPPKT *rpt, + float *clock_bias, + float *freq_offset, + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -2211,12 +2365,15 @@ short rpt_0x54 (TSIPPKT *rpt, return FALSE; } -short rpt_0x55 (TSIPPKT *rpt, - unsigned char *pos_code, - unsigned char *vel_code, - unsigned char *time_code, - unsigned char *aux_code) /* I/O serial options */ +short +rpt_0x55( + TSIPPKT *rpt, + unsigned char *pos_code, + unsigned char *vel_code, + unsigned char *time_code, + unsigned char *aux_code + ) { unsigned char *buf; buf = rpt->buf; @@ -2229,9 +2386,14 @@ short rpt_0x55 (TSIPPKT *rpt, return FALSE; } -short rpt_0x56 (TSIPPKT *rpt, - float vel_ENU[3], float *freq_offset, float *time_of_fix) /* velocity in east-north-up coordinates */ +short +rpt_0x56( + TSIPPKT *rpt, + float vel_ENU[3], + float *freq_offset, + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -2248,11 +2410,15 @@ short rpt_0x56 (TSIPPKT *rpt, return FALSE; } -short rpt_0x57 (TSIPPKT *rpt, - unsigned char *source_code, unsigned char *diag_code, - short *week_num, - float *time_of_fix) /* info about last computed fix */ +short +rpt_0x57( + TSIPPKT *rpt, + unsigned char *source_code, + unsigned char *diag_code, + short *week_num, + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -2265,10 +2431,16 @@ short rpt_0x57 (TSIPPKT *rpt, return FALSE; } -short rpt_0x58 (TSIPPKT *rpt, - unsigned char *op_code, unsigned char *data_type, unsigned char *sv_prn, - unsigned char *data_length, unsigned char *data_packet) /* GPS system data or acknowledgment of GPS system data load */ +short +rpt_0x58( + TSIPPKT *rpt, + unsigned char *op_code, + unsigned char *data_type, + unsigned char *sv_prn, + unsigned char *data_length, + unsigned char *data_packet + ) { unsigned char *buf, *buf4; short dl; @@ -2294,7 +2466,7 @@ short rpt_0x58 (TSIPPKT *rpt, *data_length = (unsigned char)dl; buf4 = &buf[4]; switch (*data_type) { - case 2: + case 2: /* Almanac */ if (*data_length != sizeof (ALM_INFO)) return TRUE; alminfo = (ALM_INFO*)data_packet; @@ -2319,7 +2491,7 @@ short rpt_0x58 (TSIPPKT *rpt, alminfo->wn_oa = bGetShort(&buf4[64]); break; - case 3: + case 3: /* Almanac health page */ if (*data_length != sizeof (ALH_PARMS) + 3) return TRUE; @@ -2327,7 +2499,7 @@ short rpt_0x58 (TSIPPKT *rpt, memcpy (data_packet, buf4, dl); break; - case 4: + case 4: /* Ionosphere */ if (*data_length != sizeof (ION_INFO) + 8) return TRUE; ioninfo = (ION_INFO*)data_packet; @@ -2341,7 +2513,7 @@ short rpt_0x58 (TSIPPKT *rpt, ioninfo->beta_3 = bGetSingle (&buf4[36]); break; - case 5: + case 5: /* UTC */ if (*data_length != sizeof (UTC_INFO) + 13) return TRUE; utcinfo = (UTC_INFO*)data_packet; @@ -2355,7 +2527,7 @@ short rpt_0x58 (TSIPPKT *rpt, utcinfo->delta_t_LSF = bGetShort (&buf4[37]); break; - case 6: + case 6: /* Ephemeris */ if (*data_length != sizeof (NAV_INFO) - 1) return TRUE; @@ -2406,10 +2578,13 @@ short rpt_0x58 (TSIPPKT *rpt, return FALSE; } -short rpt_0x59 (TSIPPKT *rpt, - unsigned char *code_type, - unsigned char status_code[32]) /* satellite enable/disable or health heed/ignore list */ +short +rpt_0x59( + TSIPPKT *rpt, + unsigned char *code_type, + unsigned char status_code[32] + ) { short iprn; unsigned char *buf; @@ -2422,14 +2597,17 @@ short rpt_0x59 (TSIPPKT *rpt, return FALSE; } -short rpt_0x5A (TSIPPKT *rpt, - unsigned char *sv_prn, - float *sample_length, - float *signal_level, - float *code_phase, - float *Doppler, - double *time_of_fix) /* raw measurement data - code phase/Doppler */ +short +rpt_0x5A( + TSIPPKT *rpt, + unsigned char *sv_prn, + float *sample_length, + float *signal_level, + float *code_phase, + float *Doppler, + double *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -2444,15 +2622,18 @@ short rpt_0x5A (TSIPPKT *rpt, return FALSE; } -short rpt_0x5B (TSIPPKT *rpt, - unsigned char *sv_prn, - unsigned char *sv_health, - unsigned char *sv_iode, - unsigned char *fit_interval_flag, - float *time_of_collection, - float *time_of_eph, - float *sv_accy) /* satellite ephorb status */ +short +rpt_0x5B( + TSIPPKT *rpt, + unsigned char *sv_prn, + unsigned char *sv_health, + unsigned char *sv_iode, + unsigned char *fit_interval_flag, + float *time_of_collection, + float *time_of_eph, + float *sv_accy + ) { unsigned char *buf; buf = rpt->buf; @@ -2468,21 +2649,24 @@ short rpt_0x5B (TSIPPKT *rpt, return FALSE; } -short rpt_0x5C (TSIPPKT *rpt, - unsigned char *sv_prn, - unsigned char *slot, - unsigned char *chan, - unsigned char *acq_flag, - unsigned char *eph_flag, - float *signal_level, - float *time_of_last_msmt, - float *elev, - float *azim, - unsigned char *old_msmt_flag, - unsigned char *integer_msec_flag, - unsigned char *bad_data_flag, - unsigned char *data_collect_flag) /* satellite tracking status */ +short +rpt_0x5C( + TSIPPKT *rpt, + unsigned char *sv_prn, + unsigned char *slot, + unsigned char *chan, + unsigned char *acq_flag, + unsigned char *eph_flag, + float *signal_level, + float *time_of_last_msmt, + float *elev, + float *azim, + unsigned char *old_msmt_flag, + unsigned char *integer_msec_flag, + unsigned char *bad_data_flag, + unsigned char *data_collect_flag + ) { unsigned char *buf; buf = rpt->buf; @@ -2507,16 +2691,19 @@ short rpt_0x5C (TSIPPKT *rpt, } /**/ -short rpt_0x6D (TSIPPKT *rpt, - unsigned char *manual_mode, - unsigned char *nsvs, - unsigned char *ndim, - unsigned char sv_prn[], - float *pdop, - float *hdop, - float *vdop, - float *tdop) /* over-determined satellite selection for position fixes, PDOP, fix mode */ +short +rpt_0x6D( + TSIPPKT *rpt, + unsigned char *manual_mode, + unsigned char *nsvs, + unsigned char *ndim, + unsigned char sv_prn[], + float *pdop, + float *hdop, + float *vdop, + float *tdop + ) { short islot; unsigned char *buf; @@ -2538,9 +2725,12 @@ short rpt_0x6D (TSIPPKT *rpt, } /**/ -short rpt_0x82 (TSIPPKT *rpt, - unsigned char *diff_mode) /* differential fix mode */ +short +rpt_0x82( + TSIPPKT *rpt, + unsigned char *diff_mode + ) { unsigned char *buf; buf = rpt->buf; @@ -2550,11 +2740,14 @@ short rpt_0x82 (TSIPPKT *rpt, return FALSE; } -short rpt_0x83 (TSIPPKT *rpt, - double ECEF_pos[3], - double *clock_bias, - float *time_of_fix) /* position, ECEF double precision */ +short +rpt_0x83( + TSIPPKT *rpt, + double ECEF_pos[3], + double *clock_bias, + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -2568,13 +2761,16 @@ short rpt_0x83 (TSIPPKT *rpt, return FALSE; } -short rpt_0x84 (TSIPPKT *rpt, - double *lat, - double *lon, - double *alt, - double *clock_bias, - float *time_of_fix) /* position, lat-lon-alt double precision */ +short +rpt_0x84( + TSIPPKT *rpt, + double *lat, + double *lon, + double *alt, + double *clock_bias, + float *time_of_fix + ) { unsigned char *buf; buf = rpt->buf; @@ -2588,39 +2784,44 @@ short rpt_0x84 (TSIPPKT *rpt, return FALSE; } -short rpt_Paly0xBB(TSIPPKT *rpt, - TSIP_RCVR_CFG *TsipxBB) +short +rpt_Paly0xBB( + TSIPPKT *rpt, + TSIP_RCVR_CFG *TsipxBB + ) { - unsigned char *buf; buf = rpt->buf; - /* Palisade is inconsistent with other TSIP, which has a kength of 40 */ + /* Palisade is inconsistent with other TSIP, which has a length of 40 */ /* if (rpt->len != 40) return TRUE; */ if (rpt->len != 43) return TRUE; - TsipxBB->bSubcode = buf[0]; - TsipxBB->operating_mode = buf[1] ; - TsipxBB->dyn_code = buf[3] ; - TsipxBB->elev_mask = bGetSingle (&buf[5]); - TsipxBB->cno_mask = bGetSingle (&buf[9]); - TsipxBB->dop_mask = bGetSingle (&buf[13]); + TsipxBB->bSubcode = buf[0]; + TsipxBB->operating_mode = buf[1]; + TsipxBB->dyn_code = buf[3]; + TsipxBB->elev_mask = bGetSingle (&buf[5]); + TsipxBB->cno_mask = bGetSingle (&buf[9]); + TsipxBB->dop_mask = bGetSingle (&buf[13]); TsipxBB->dop_switch = bGetSingle (&buf[17]); return FALSE; } -short rpt_0xBC (TSIPPKT *rpt, - unsigned char *port_num, - unsigned char *in_baud, - unsigned char *out_baud, - unsigned char *data_bits, - unsigned char *parity, - unsigned char *stop_bits, - unsigned char *flow_control, - unsigned char *protocols_in, - unsigned char *protocols_out, - unsigned char *reserved) /* Receiver serial port configuration */ +short +rpt_0xBC( + TSIPPKT *rpt, + unsigned char *port_num, + unsigned char *in_baud, + unsigned char *out_baud, + unsigned char *data_bits, + unsigned char *parity, + unsigned char *stop_bits, + unsigned char *flow_control, + unsigned char *protocols_in, + unsigned char *protocols_out, + unsigned char *reserved + ) { unsigned char *buf; buf = rpt->buf; @@ -2642,51 +2843,57 @@ short rpt_0xBC (TSIPPKT *rpt, /**** Superpackets ****/ -short rpt_0x8F0B(TSIPPKT *rpt, - unsigned short *event, - double *tow, - unsigned char *date, - unsigned char *month, - short *year, - unsigned char *dim_mode, - short *utc_offset, - double *bias, - double *drift, - float *bias_unc, - float *dr_unc, - double *lat, - double *lon, - double *alt, - char sv_id[8]) -{ - short local_index; - unsigned char *buf; +short +rpt_0x8F0B( + TSIPPKT *rpt, + unsigned short *event, + double *tow, + unsigned char *date, + unsigned char *month, + short *year, + unsigned char *dim_mode, + short *utc_offset, + double *bias, + double *drift, + float *bias_unc, + float *dr_unc, + double *lat, + double *lon, + double *alt, + char sv_id[8] + ) +{ + short local_index; + unsigned char *buf; buf = rpt->buf; - if (rpt->len != 74) return TRUE; - *event = bGetShort(&buf[1]); - *tow = bGetDouble(&buf[3]); - *date = buf[11]; - *month = buf[12]; - *year = bGetShort(&buf[13]); - *dim_mode = buf[15]; - *utc_offset = bGetShort(&buf[16]); - *bias = bGetDouble(&buf[18]); - *drift = bGetDouble(&buf[26]); - *bias_unc = bGetSingle(&buf[34]); - *dr_unc = bGetSingle(&buf[38]); - *lat = bGetDouble(&buf[42]); - *lon = bGetDouble(&buf[50]); - *alt = bGetDouble(&buf[58]); - - for (local_index=0; local_index<8; local_index++) sv_id[local_index] = buf[local_index + 66]; - return FALSE; -} - -short rpt_0x8F14 (TSIPPKT *rpt, - short *datum_idx, - double datum_coeffs[5]) -/* datum index and coefficients */ + if (rpt->len != 74) return TRUE; + *event = bGetShort(&buf[1]); + *tow = bGetDouble(&buf[3]); + *date = buf[11]; + *month = buf[12]; + *year = bGetShort(&buf[13]); + *dim_mode = buf[15]; + *utc_offset = bGetShort(&buf[16]); + *bias = bGetDouble(&buf[18]); + *drift = bGetDouble(&buf[26]); + *bias_unc = bGetSingle(&buf[34]); + *dr_unc = bGetSingle(&buf[38]); + *lat = bGetDouble(&buf[42]); + *lon = bGetDouble(&buf[50]); + *alt = bGetDouble(&buf[58]); + + for (local_index=0; local_index<8; local_index++) sv_id[local_index] = buf[local_index + 66]; + return FALSE; +} + +/* datum index and coefficients */ +short +rpt_0x8F14( + TSIPPKT *rpt, + short *datum_idx, + double datum_coeffs[5] + ) { unsigned char *buf; buf = rpt->buf; @@ -2702,10 +2909,13 @@ short rpt_0x8F14 (TSIPPKT *rpt, } -short rpt_0x8F15 (TSIPPKT *rpt, - short *datum_idx, - double datum_coeffs[5]) -/* datum index and coefficients */ +/* datum index and coefficients */ +short +rpt_0x8F15( + TSIPPKT *rpt, + short *datum_idx, + double datum_coeffs[5] + ) { unsigned char *buf; buf = rpt->buf; @@ -2723,29 +2933,32 @@ short rpt_0x8F15 (TSIPPKT *rpt, #define MAX_LONG (2147483648.) /* 2**31 */ -short rpt_0x8F20 (TSIPPKT *rpt, - unsigned char *info, - double *lat, - double *lon, - double *alt, - double vel_enu[], - double *time_of_fix, - short *week_num, - unsigned char *nsvs, - unsigned char sv_prn[], - short sv_IODC[], - short *datum_index) +short +rpt_0x8F20( + TSIPPKT *rpt, + unsigned char *info, + double *lat, + double *lon, + double *alt, + double vel_enu[], + double *time_of_fix, + short *week_num, + unsigned char *nsvs, + unsigned char sv_prn[], + short sv_IODC[], + short *datum_index + ) { short - isv; + isv; unsigned char - *buf, prnx, iode; + *buf, prnx, iode; unsigned long - ulongtemp; + ulongtemp; long - longtemp; + longtemp; double - vel_scale; + vel_scale; buf = rpt->buf; @@ -2774,24 +2987,27 @@ short rpt_0x8F20 (TSIPPKT *rpt, for (isv = 0; isv < 8; isv++) { prnx = buf[32+2*isv]; sv_prn[isv] = (unsigned char)(prnx&0x3F); - iode = buf[33+2*isv]; + iode = buf[33+2*isv]; sv_IODC[isv] = (short)(iode | ((prnx>>6)<<8)); } return FALSE; } -short rpt_0x8F41 (TSIPPKT *rpt, - unsigned char *bSearchRange, - unsigned char *bBoardOptions, - unsigned long *iiSerialNumber, - unsigned char *bBuildYear, - unsigned char *bBuildMonth, - unsigned char *bBuildDay, - unsigned char *bBuildHour, - float *fOscOffset, - unsigned short *iTestCodeId) +short +rpt_0x8F41( + TSIPPKT *rpt, + unsigned char *bSearchRange, + unsigned char *bBoardOptions, + unsigned long *iiSerialNumber, + unsigned char *bBuildYear, + unsigned char *bBuildMonth, + unsigned char *bBuildDay, + unsigned char *bBuildHour, + float *fOscOffset, + unsigned short *iTestCodeId + ) { - if(rpt->len != 17) return FALSE; + if (rpt->len != 17) return FALSE; *bSearchRange = rpt->buf[1]; *bBoardOptions = rpt->buf[2]; *iiSerialNumber = bGetLong(&rpt->buf[3]); @@ -2805,17 +3021,20 @@ short rpt_0x8F41 (TSIPPKT *rpt, return TRUE; } -short rpt_0x8F42 (TSIPPKT *rpt, - unsigned char *bProdOptionsPre, - unsigned char *bProdNumberExt, - unsigned short *iCaseSerialNumberPre, - unsigned long *iiCaseSerialNumber, - unsigned long *iiProdNumber, - unsigned short *iPremiumOptions, - unsigned short *iMachineID, - unsigned short *iKey) +short +rpt_0x8F42( + TSIPPKT *rpt, + unsigned char *bProdOptionsPre, + unsigned char *bProdNumberExt, + unsigned short *iCaseSerialNumberPre, + unsigned long *iiCaseSerialNumber, + unsigned long *iiProdNumber, + unsigned short *iPremiumOptions, + unsigned short *iMachineID, + unsigned short *iKey + ) { - if(rpt->len != 19) return FALSE; + if (rpt->len != 19) return FALSE; *bProdOptionsPre = rpt->buf[1]; *bProdNumberExt = rpt->buf[2]; *iCaseSerialNumberPre = bGetShort(&rpt->buf[3]); @@ -2827,100 +3046,117 @@ short rpt_0x8F42 (TSIPPKT *rpt, return TRUE; } -short rpt_0x8F45(TSIPPKT *rpt, - unsigned char *bSegMask) +short +rpt_0x8F45( + TSIPPKT *rpt, + unsigned char *bSegMask + ) { - if(rpt->len != 2) return FALSE; + if (rpt->len != 2) return FALSE; *bSegMask = rpt->buf[1]; return TRUE; } -short rpt_0x8F4A_16(TSIPPKT *rpt, - unsigned char *pps_enabled, - unsigned char *pps_timebase, - unsigned char *pos_polarity, - double *pps_offset, - float *bias_unc_threshold) /* Stinger PPS definition */ +short +rpt_0x8F4A_16( + TSIPPKT *rpt, + unsigned char *pps_enabled, + unsigned char *pps_timebase, + unsigned char *pos_polarity, + double *pps_offset, + float *bias_unc_threshold + ) { unsigned char - *buf; - - buf = rpt->buf; - if (rpt->len != 16) return TRUE; - *pps_enabled = buf[1]; - *pps_timebase = buf[2]; - *pos_polarity = buf[3]; - *pps_offset = bGetDouble(&buf[4]); - *bias_unc_threshold = bGetSingle(&buf[12]); + *buf; + + buf = rpt->buf; + if (rpt->len != 16) return TRUE; + *pps_enabled = buf[1]; + *pps_timebase = buf[2]; + *pos_polarity = buf[3]; + *pps_offset = bGetDouble(&buf[4]); + *bias_unc_threshold = bGetSingle(&buf[12]); return FALSE; } -short rpt_0x8F4B(TSIPPKT *rpt, - unsigned long *decorr_max) +short +rpt_0x8F4B( + TSIPPKT *rpt, + unsigned long *decorr_max + ) { unsigned char - *buf; + *buf; - buf = rpt->buf; - if (rpt->len != 5) return TRUE; - *decorr_max = bGetLong(&buf[1]); - return FALSE; + buf = rpt->buf; + if (rpt->len != 5) return TRUE; + *decorr_max = bGetLong(&buf[1]); + return FALSE; } -short rpt_0x8F4D(TSIPPKT *rpt, - unsigned long *event_mask) +short +rpt_0x8F4D( + TSIPPKT *rpt, + unsigned long *event_mask + ) { unsigned char - *buf; + *buf; - buf = rpt->buf; - if (rpt->len != 5) return TRUE; - *event_mask = bGetULong (&buf[1]); - return FALSE; + buf = rpt->buf; + if (rpt->len != 5) return TRUE; + *event_mask = bGetULong (&buf[1]); + return FALSE; } -short rpt_0x8FA5(TSIPPKT *rpt, - unsigned char *spktmask) +short +rpt_0x8FA5( + TSIPPKT *rpt, + unsigned char *spktmask + ) { unsigned char - *buf; - - buf = rpt->buf; - if (rpt->len != 5) return TRUE; - spktmask[0] = buf[1]; - spktmask[1] = buf[2]; - spktmask[2] = buf[3]; - spktmask[3] = buf[4]; - return FALSE; -} - -short rpt_0x8FAD (TSIPPKT *rpt, - unsigned short *COUNT, - double *FracSec, - unsigned char *Hour, - unsigned char *Minute, - unsigned char *Second, - unsigned char *Day, - unsigned char *Month, - unsigned short *Year, - unsigned char *Status, - unsigned char *Flags) -{ + *buf; + + buf = rpt->buf; + if (rpt->len != 5) return TRUE; + spktmask[0] = buf[1]; + spktmask[1] = buf[2]; + spktmask[2] = buf[3]; + spktmask[3] = buf[4]; + return FALSE; +} +short +rpt_0x8FAD( + TSIPPKT *rpt, + unsigned short *COUNT, + double *FracSec, + unsigned char *Hour, + unsigned char *Minute, + unsigned char *Second, + unsigned char *Day, + unsigned char *Month, + unsigned short *Year, + unsigned char *Status, + unsigned char *Flags + ) +{ if (rpt->len != 22) return TRUE; - *COUNT = bGetUShort(&rpt->buf[1]); - *FracSec = bGetDouble(&rpt->buf[3]); - *Hour = rpt->buf[11]; - *Minute = rpt->buf[12]; - *Second = rpt->buf[13]; - *Day = rpt->buf[14]; - *Month = rpt->buf[15]; - *Year = bGetUShort(&rpt->buf[16]); - *Status = rpt->buf[18]; - *Flags = rpt->buf[19]; - return FALSE; + *COUNT = bGetUShort(&rpt->buf[1]); + *FracSec = bGetDouble(&rpt->buf[3]); + *Hour = rpt->buf[11]; + *Minute = rpt->buf[12]; + *Second = rpt->buf[13]; + *Day = rpt->buf[14]; + *Month = rpt->buf[15]; + *Year = bGetUShort(&rpt->buf[16]); + *Status = rpt->buf[18]; + *Flags = rpt->buf[19]; + return FALSE; } @@ -2976,31 +3212,34 @@ short rpt_0x8FAD (TSIPPKT *rpt, /* pbuf is the pointer to the current location of the text output */ static char - *pbuf; +*pbuf; /* keep track of whether the message has been successfully parsed */ static short - parsed; +parsed; /* convert time of week into day-hour-minute-second and print */ -char* show_time (float time_of_week) +char * +show_time( + float time_of_week + ) { short days, hours, minutes; float seconds; double tow = 0; - static char timestring [80]; + static char timestring [80]; if (time_of_week == -1.0) - { + { sprintf(timestring, " "); } else if ((time_of_week >= 604800.0) || (time_of_week < 0.0)) - { + { sprintf(timestring, " "); } - else - { + else + { if (time_of_week < 604799.9) tow = time_of_week + .00000001; seconds = (float)fmod(tow, 60.); @@ -3008,42 +3247,45 @@ char* show_time (float time_of_week) hours = (short)fmod(tow / 3600., 24.); days = (short)(tow / 86400.0); sprintf(timestring, " %s %02d:%02d:%05.2f ", - dayname[days], hours, minutes, seconds); - } - return timestring; + dayname[days], hours, minutes, seconds); + } + return timestring; } /**/ /* 0x3D */ -static void rpt_chan_A_config (TSIPPKT *rpt) +static void +rpt_chan_A_config( + TSIPPKT *rpt + ) { unsigned char - tx_baud_index, rx_baud_index, - char_format_index, stop_bits, - tx_mode_index, rx_mode_index, - databits, parity; + tx_baud_index, rx_baud_index, + char_format_index, stop_bits, + tx_mode_index, rx_mode_index, + databits, parity; int - i, nbaud; + i, nbaud; /* unload rptbuf */ if (rpt_0x3D (rpt, - &tx_baud_index, &rx_baud_index, &char_format_index, - &stop_bits, &tx_mode_index, &rx_mode_index)) { + &tx_baud_index, &rx_baud_index, &char_format_index, + &stop_bits, &tx_mode_index, &rx_mode_index)) { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nChannel A Configuration"); - nbaud = sizeof(old_baudnum); + nbaud = sizeof(old_baudnum); for (i = 0; i < nbaud; ++i) if (tx_baud_index == old_baudnum[i]) break; pbuf += sprintf(pbuf, "\n Transmit speed: %s at %s", - old_output_ch[tx_mode_index], st_baud_text_app[i]); + old_output_ch[tx_mode_index], st_baud_text_app[i]); for (i = 0; i < nbaud; ++i) if (rx_baud_index == old_baudnum[i]) break; pbuf += sprintf(pbuf, "\n Receive speed: %s at %s", - old_input_ch[rx_mode_index], st_baud_text_app[i]); + old_input_ch[rx_mode_index], st_baud_text_app[i]); databits = (unsigned char)((char_format_index & 0x03) + 5); @@ -3051,43 +3293,46 @@ static void rpt_chan_A_config (TSIPPKT *rpt) if (parity > 4) parity = 2; pbuf += sprintf(pbuf, "\n Character format (bits/char, parity, stop bits): %d-%s-%d", - databits, old_parity_text[parity], stop_bits); + databits, old_parity_text[parity], stop_bits); } /**/ /* 0x40 */ -static void rpt_almanac_data_page (TSIPPKT *rpt) +static void +rpt_almanac_data_page( + TSIPPKT *rpt + ) { unsigned char - sv_prn; + sv_prn; short - week_num; + week_num; float - t_zc, - eccentricity, - t_oa, - i_0, - OMEGA_dot, - sqrt_A, - OMEGA_0, - omega, - M_0; + t_zc, + eccentricity, + t_oa, + i_0, + OMEGA_dot, + sqrt_A, + OMEGA_0, + omega, + M_0; /* unload rptbuf */ if (rpt_0x40 (rpt, - &sv_prn, &week_num, &t_zc, &eccentricity, &t_oa, - &i_0, &OMEGA_dot, &sqrt_A, &OMEGA_0, &omega, &M_0)) { + &sv_prn, &week_num, &t_zc, &eccentricity, &t_oa, + &i_0, &OMEGA_dot, &sqrt_A, &OMEGA_0, &omega, &M_0)) { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nAlmanac for SV %02d", sv_prn); pbuf += sprintf(pbuf, "\n Captured:%15.0f %s", - t_zc, show_time (t_zc)); + t_zc, show_time (t_zc)); pbuf += sprintf(pbuf, "\n week:%15d", week_num); pbuf += sprintf(pbuf, "\n Eccentricity:%15g", eccentricity); pbuf += sprintf(pbuf, "\n T_oa:%15.0f %s", - t_oa, show_time (t_oa)); + t_oa, show_time (t_oa)); pbuf += sprintf(pbuf, "\n i 0:%15g", i_0); pbuf += sprintf(pbuf, "\n OMEGA dot:%15g", OMEGA_dot); pbuf += sprintf(pbuf, "\n sqrt A:%15g", sqrt_A); @@ -3097,12 +3342,15 @@ static void rpt_almanac_data_page (TSIPPKT *rpt) } /* 0x41 */ -static void rpt_GPS_time (TSIPPKT *rpt) +static void +rpt_GPS_time( + TSIPPKT *rpt + ) { float - time_of_week, UTC_offset; + time_of_week, UTC_offset; short - week_num; + week_num; /* unload rptbuf */ if (rpt_0x41 (rpt, &time_of_week, &UTC_offset, &week_num)) { @@ -3111,15 +3359,18 @@ static void rpt_GPS_time (TSIPPKT *rpt) } pbuf += sprintf(pbuf, "\nGPS time:%s GPS week: %d UTC offset %.1f", - show_time(time_of_week), week_num, UTC_offset); + show_time(time_of_week), week_num, UTC_offset); } /* 0x42 */ -static void rpt_single_ECEF_position (TSIPPKT *rpt) +static void +rpt_single_ECEF_position( + TSIPPKT *rpt + ) { float - ECEF_pos[3], time_of_fix; + ECEF_pos[3], time_of_fix; /* unload rptbuf */ if (rpt_0x42 (rpt, ECEF_pos, &time_of_fix)) { @@ -3128,16 +3379,19 @@ static void rpt_single_ECEF_position (TSIPPKT *rpt) } pbuf += sprintf(pbuf, "\nSXYZ: %15.0f %15.0f %15.0f %s", - ECEF_pos[0], ECEF_pos[1], ECEF_pos[2], - show_time(time_of_fix)); + ECEF_pos[0], ECEF_pos[1], ECEF_pos[2], + show_time(time_of_fix)); } /* 0x43 */ -static void rpt_single_ECEF_velocity (TSIPPKT *rpt) +static void +rpt_single_ECEF_velocity( + TSIPPKT *rpt + ) { float - ECEF_vel[3], freq_offset, time_of_fix; + ECEF_vel[3], freq_offset, time_of_fix; /* unload rptbuf */ if (rpt_0x43 (rpt, ECEF_vel, &freq_offset, &time_of_fix)) { @@ -3146,54 +3400,63 @@ static void rpt_single_ECEF_velocity (TSIPPKT *rpt) } pbuf += sprintf(pbuf, "\nVelECEF: %11.3f %11.3f %11.3f %12.3f%s", - ECEF_vel[0], ECEF_vel[1], ECEF_vel[2], freq_offset, - show_time(time_of_fix)); + ECEF_vel[0], ECEF_vel[1], ECEF_vel[2], freq_offset, + show_time(time_of_fix)); } /* 0x45 */ -static void rpt_SW_version (TSIPPKT *rpt) { +static void +rpt_SW_version( + TSIPPKT *rpt + ) +{ unsigned char - major_nav_version, minor_nav_version, - nav_day, nav_month, nav_year, - major_dsp_version, minor_dsp_version, - dsp_day, dsp_month, dsp_year; + major_nav_version, minor_nav_version, + nav_day, nav_month, nav_year, + major_dsp_version, minor_dsp_version, + dsp_day, dsp_month, dsp_year; /* unload rptbuf */ if (rpt_0x45 (rpt, - &major_nav_version, &minor_nav_version, - &nav_day, &nav_month, &nav_year, - &major_dsp_version, &minor_dsp_version, - &dsp_day, &dsp_month, &dsp_year)) { + &major_nav_version, &minor_nav_version, + &nav_day, &nav_month, &nav_year, + &major_dsp_version, &minor_dsp_version, + &dsp_day, &dsp_month, &dsp_year)) { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, -"\nFW Versions: Nav Proc %2d.%02d %2d/%2d/%2d Sig Proc %2d.%02d %2d/%2d/%2d", - major_nav_version, minor_nav_version, nav_day, nav_month, nav_year, - major_dsp_version, minor_dsp_version, dsp_day, dsp_month, dsp_year); + "\nFW Versions: Nav Proc %2d.%02d %2d/%2d/%2d Sig Proc %2d.%02d %2d/%2d/%2d", + major_nav_version, minor_nav_version, nav_day, nav_month, nav_year, + major_dsp_version, minor_dsp_version, dsp_day, dsp_month, dsp_year); } /* 0x46 */ -static void rpt_rcvr_health (TSIPPKT *rpt) +static void +rpt_rcvr_health( + TSIPPKT *rpt + ) { unsigned char - status1, status2; - static char - *sc_text[] = { - "Doing position fixes", - "Don't have GPS time yet", - "Waiting for almanac collection", - "DOP too high ", - "No satellites available", - "Only 1 satellite available", - "Only 2 satellites available", - "Only 3 satellites available", - "No satellites usable ", - "Only 1 satellite usable", - "Only 2 satellites usable", - "Only 3 satellites usable", - "Chosen satellite unusable"}; + status1, status2; + const char + *text; + static const char const + *sc_text[] = { + "Doing position fixes", + "Don't have GPS time yet", + "Waiting for almanac collection", + "DOP too high ", + "No satellites available", + "Only 1 satellite available", + "Only 2 satellites available", + "Only 3 satellites available", + "No satellites usable ", + "Only 1 satellite usable", + "Only 2 satellites usable", + "Only 3 satellites usable", + "Chosen satellite unusable"}; /* unload rptbuf */ @@ -3203,49 +3466,58 @@ static void rpt_rcvr_health (TSIPPKT *rpt) return; } + text = (status1 < COUNTOF(sc_text)) + ? sc_text[status1] + : "(out of range)"; pbuf += sprintf(pbuf, "\nRcvr status1: %s (%02Xh); ", - sc_text[rpt->buf[0]], status1); + text, status1); pbuf += sprintf(pbuf, "status2: %s, %s (%02Xh)", - (status2 & 0x01)?"No BBRAM":"BBRAM OK", - (status2 & 0x10)?"No Ant":"Ant OK", - status2); + (status2 & 0x01)?"No BBRAM":"BBRAM OK", + (status2 & 0x10)?"No Ant":"Ant OK", + status2); } /* 0x47 */ -static void rpt_SNR_all_SVs (TSIPPKT *rpt) +static void +rpt_SNR_all_SVs( + TSIPPKT *rpt + ) { unsigned char - nsvs, sv_prn[12]; + nsvs, sv_prn[12]; short - isv; + isv; float - snr[12]; + snr[12]; /* unload rptbuf */ if (rpt_0x47 (rpt, &nsvs, sv_prn, snr)) - { + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nSNR for satellites: %d", nsvs); for (isv = 0; isv < nsvs; isv++) - { + { pbuf += sprintf(pbuf, "\n SV %02d %6.2f", - sv_prn[isv], snr[isv]); + sv_prn[isv], snr[isv]); } } /* 0x48 */ -static void rpt_GPS_system_message (TSIPPKT *rpt) +static void +rpt_GPS_system_message( + TSIPPKT *rpt + ) { unsigned char - message[23]; + message[23]; /* unload rptbuf */ if (rpt_0x48 (rpt, message)) - { + { parsed = BADLEN_PARSE; return; } @@ -3254,43 +3526,50 @@ static void rpt_GPS_system_message (TSIPPKT *rpt) } /* 0x49 */ -static void rpt_almanac_health_page (TSIPPKT *rpt) +static void +rpt_almanac_health_page( + TSIPPKT *rpt + ) { short - iprn; + iprn; unsigned char - sv_health [32]; + sv_health [32]; /* unload rptbuf */ if (rpt_0x49 (rpt, sv_health)) - { + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nAlmanac health page:"); for (iprn = 0; iprn < 32; iprn++) - { + { if (!(iprn%5)) *pbuf++ = '\n'; pbuf += sprintf(pbuf, " SV%02d %2X", - (iprn+1) , sv_health[iprn]); + (iprn+1) , sv_health[iprn]); } } /* 0x4A */ -static void rpt_single_lla_position (TSIPPKT *rpt) { +static void +rpt_single_lla_position( + TSIPPKT *rpt + ) +{ short - lat_deg, lon_deg; + lat_deg, lon_deg; float - lat, lon, - alt, clock_bias, time_of_fix; + lat, lon, + alt, clock_bias, time_of_fix; double lat_min, lon_min; unsigned char - north_south, east_west; + north_south, east_west; if (rpt_0x4A (rpt, - &lat, &lon, &alt, &clock_bias, &time_of_fix)) - { + &lat, &lon, &alt, &clock_bias, &time_of_fix)) + { parsed = BADLEN_PARSE; return; } @@ -3299,7 +3578,7 @@ static void rpt_single_lla_position (TSIPPKT *rpt) { lat *= (float)R2D; north_south = 'N'; if (lat < 0.0) - { + { north_south = 'S'; lat = -lat; } @@ -3309,7 +3588,7 @@ static void rpt_single_lla_position (TSIPPKT *rpt) { lon *= (float)R2D; east_west = 'E'; if (lon < 0.0) - { + { east_west = 'W'; lon = -lon; } @@ -3317,136 +3596,152 @@ static void rpt_single_lla_position (TSIPPKT *rpt) { lon_min = (lon - lon_deg) * 60.0; pbuf += sprintf(pbuf, "\nSLLA: %4d: %06.3f %c%5d:%06.3f %c%10.2f %12.2f%s", - lat_deg, lat_min, north_south, - lon_deg, lon_min, east_west, - alt, clock_bias, - show_time(time_of_fix)); + lat_deg, lat_min, north_south, + lon_deg, lon_min, east_west, + alt, clock_bias, + show_time(time_of_fix)); } /* 0x4A */ -static void rpt_ref_alt (TSIPPKT *rpt) { - +static void +rpt_ref_alt( + TSIPPKT *rpt + ) +{ float - alt, dummy; + alt, dummy; unsigned char - alt_flag; + alt_flag; - if (rpt_0x4A_2 (rpt, - &alt, &dummy, &alt_flag)) - { + if (rpt_0x4A_2 (rpt, &alt, &dummy, &alt_flag)) + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nReference Alt: %.1f m; %s", - alt, alt_flag?"ON":"OFF"); + alt, alt_flag?"ON":"OFF"); } /* 0x4B */ -static void rpt_rcvr_id_and_status (TSIPPKT *rpt) +static void +rpt_rcvr_id_and_status( + TSIPPKT *rpt + ) { unsigned char - machine_id, status3, status4; + machine_id, status3, status4; /* unload rptbuf */ if (rpt_0x4B (rpt, &machine_id, &status3, &status4)) - { + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nRcvr Machine ID: %d; Status3 = %s, %s (%02Xh)", - machine_id, - (status3 & 0x02)?"No RTC":"RTC OK", - (status3 & 0x08)?"No Alm":"Alm OK", - status3); + machine_id, + (status3 & 0x02)?"No RTC":"RTC OK", + (status3 & 0x08)?"No Alm":"Alm OK", + status3); } /* 0x4C */ -static void rpt_operating_parameters (TSIPPKT *rpt) +static void +rpt_operating_parameters( + TSIPPKT *rpt + ) { unsigned char - dyn_code; + dyn_code; float - el_mask, snr_mask, dop_mask, dop_switch; + el_mask, snr_mask, dop_mask, dop_switch; /* unload rptbuf */ if (rpt_0x4C (rpt, &dyn_code, &el_mask, - &snr_mask, &dop_mask, &dop_switch)) - { + &snr_mask, &dop_mask, &dop_switch)) + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nOperating Parameters:"); pbuf += sprintf(pbuf, "\n Dynamics code = %d %s", - dyn_code, dyn_text[dyn_code]); - pbuf += sprintf(pbuf, "\n Elevation mask = %.2fø", el_mask * R2D); + dyn_code, dyn_text[dyn_code]); + pbuf += sprintf(pbuf, "\n Elevation mask = %.2f", el_mask * R2D); pbuf += sprintf(pbuf, "\n SNR mask = %.2f", snr_mask); pbuf += sprintf(pbuf, "\n DOP mask = %.2f", dop_mask); pbuf += sprintf(pbuf, "\n DOP switch = %.2f", dop_switch); } /* 0x4D */ -static void rpt_oscillator_offset (TSIPPKT *rpt) +static void +rpt_oscillator_offset( + TSIPPKT *rpt + ) { float - osc_offset; + osc_offset; /* unload rptbuf */ if (rpt_0x4D (rpt, &osc_offset)) - { + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nOscillator offset: %.2f Hz = %.3f PPM", - osc_offset, osc_offset/1575.42); + osc_offset, osc_offset/1575.42); } /* 0x4E */ -static void rpt_GPS_time_set_response (TSIPPKT *rpt) +static void +rpt_GPS_time_set_response( + TSIPPKT *rpt + ) { - unsigned char - response; + response; /* unload rptbuf */ if (rpt_0x4E (rpt, &response)) - { + { parsed = BADLEN_PARSE; return; } switch (response) - { - case 'Y': + { + case 'Y': pbuf += sprintf(pbuf, "\nTime set accepted"); break; - case 'N': + case 'N': pbuf += sprintf(pbuf, "\nTime set rejected or not required"); break; - default: + default: parsed = BADDATA_PARSE; } } /* 0x4F */ -static void rpt_UTC_offset (TSIPPKT *rpt) +static void +rpt_UTC_offset( + TSIPPKT *rpt + ) { double - a0; + a0; float - a1, time_of_data; + a1, time_of_data; short - dt_ls, wn_t, wn_lsf, dn, dt_lsf; + dt_ls, wn_t, wn_lsf, dn, dt_lsf; /* unload rptbuf */ if (rpt_0x4F (rpt, &a0, &a1, &time_of_data, - &dt_ls, &wn_t, &wn_lsf, &dn, &dt_lsf)) { + &dt_ls, &wn_t, &wn_lsf, &dn, &dt_lsf)) { parsed = BADLEN_PARSE; return; } @@ -3464,10 +3759,13 @@ static void rpt_UTC_offset (TSIPPKT *rpt) /**/ /* 0x54 */ -static void rpt_1SV_bias (TSIPPKT *rpt) +static void +rpt_1SV_bias( + TSIPPKT *rpt + ) { float - clock_bias, freq_offset, time_of_fix; + clock_bias, freq_offset, time_of_fix; /* unload rptbuf */ if (rpt_0x54 (rpt, &clock_bias, &freq_offset, &time_of_fix)) { @@ -3476,25 +3774,28 @@ static void rpt_1SV_bias (TSIPPKT *rpt) } pbuf += sprintf (pbuf, "\nTime Fix Clock Bias: %6.2f m Freq Bias: %6.2f m/s%s", - clock_bias, freq_offset, show_time (time_of_fix)); + clock_bias, freq_offset, show_time (time_of_fix)); } /* 0x55 */ -static void rpt_io_opt (TSIPPKT *rpt) +static void +rpt_io_opt( + TSIPPKT *rpt + ) { unsigned char - pos_code, vel_code, time_code, aux_code; + pos_code, vel_code, time_code, aux_code; /* unload rptbuf */ if (rpt_0x55 (rpt, - &pos_code, &vel_code, &time_code, &aux_code)) { + &pos_code, &vel_code, &time_code, &aux_code)) { parsed = BADLEN_PARSE; return; } /* rptbuf unloaded */ pbuf += sprintf(pbuf, "\nI/O Options: %2X %2X %2X %2X", - pos_code, vel_code, time_code, aux_code); + pos_code, vel_code, time_code, aux_code); if (pos_code & 0x01) { pbuf += sprintf(pbuf, "\n ECEF XYZ position output"); @@ -3505,16 +3806,16 @@ static void rpt_io_opt (TSIPPKT *rpt) } pbuf += sprintf(pbuf, (pos_code & 0x04)? - "\n MSL altitude output (Geoid height) ": - "\n WGS-84 altitude output"); + "\n MSL altitude output (Geoid height) ": + "\n WGS-84 altitude output"); pbuf += sprintf(pbuf, (pos_code & 0x08)? - "\n MSL altitude input": - "\n WGS-84 altitude input"); + "\n MSL altitude input": + "\n WGS-84 altitude input"); pbuf += sprintf(pbuf, (pos_code & 0x10)? - "\n Double precision": - "\n Single precision"); + "\n Double precision": + "\n Single precision"); if (pos_code & 0x20) { pbuf += sprintf(pbuf, "\n All Enabled Superpackets"); @@ -3529,8 +3830,8 @@ static void rpt_io_opt (TSIPPKT *rpt) } pbuf += sprintf(pbuf, (time_code & 0x01)? - "\n Time tags in UTC": - "\n Time tags in GPS time"); + "\n Time tags in UTC": + "\n Time tags in GPS time"); if (time_code & 0x02) { pbuf += sprintf(pbuf, "\n Fixes delayed to integer seconds"); @@ -3548,9 +3849,9 @@ static void rpt_io_opt (TSIPPKT *rpt) pbuf += sprintf(pbuf, "\n Minimize measurement propagation"); } - pbuf += sprintf(pbuf, (time_code & 0x20) ? - "\n PPS output at all times" : - "\n PPS output during fixes"); + pbuf += sprintf(pbuf, (time_code & 0x20) ? + "\n PPS output at all times" : + "\n PPS output during fixes"); if (aux_code & 0x01) { pbuf += sprintf(pbuf, "\n Raw measurement output"); @@ -3565,15 +3866,18 @@ static void rpt_io_opt (TSIPPKT *rpt) } pbuf += sprintf(pbuf, (aux_code & 0x08)? - "\n Signal Strength Output as dBHz" : - "\n Signal Strength Output as AMU"); + "\n Signal Strength Output as dBHz" : + "\n Signal Strength Output as AMU"); } /* 0x56 */ -static void rpt_ENU_velocity (TSIPPKT *rpt) +static void +rpt_ENU_velocity( + TSIPPKT *rpt + ) { float - vel_ENU[3], freq_offset, time_of_fix; + vel_ENU[3], freq_offset, time_of_fix; /* unload rptbuf */ if (rpt_0x56 (rpt, vel_ENU, &freq_offset, &time_of_fix)) { @@ -3582,19 +3886,22 @@ static void rpt_ENU_velocity (TSIPPKT *rpt) } pbuf += sprintf(pbuf, "\nVel ENU: %11.3f %11.3f %11.3f %12.3f%s", - vel_ENU[0], vel_ENU[1], vel_ENU[2], freq_offset, - show_time (time_of_fix)); + vel_ENU[0], vel_ENU[1], vel_ENU[2], freq_offset, + show_time (time_of_fix)); } /* 0x57 */ -static void rpt_last_fix_info (TSIPPKT *rpt) +static void +rpt_last_fix_info( + TSIPPKT *rpt + ) { unsigned char - source_code, diag_code; + source_code, diag_code; short - week_num; + week_num; float - time_of_fix; + time_of_fix; /* unload rptbuf */ if (rpt_0x57 (rpt, &source_code, &diag_code, &week_num, &time_of_fix)) { @@ -3603,61 +3910,64 @@ static void rpt_last_fix_info (TSIPPKT *rpt) } pbuf += sprintf(pbuf, "\n source code %d; diag code: %2Xh", - source_code, diag_code); + source_code, diag_code); pbuf += sprintf(pbuf, "\n Time of last fix:%s", show_time(time_of_fix)); pbuf += sprintf(pbuf, "\n Week of last fix: %d", week_num); } /* 0x58 */ -static void rpt_GPS_system_data (TSIPPKT *rpt) +static void +rpt_GPS_system_data( + TSIPPKT *rpt + ) { unsigned char - iprn, - op_code, data_type, sv_prn, - data_length, data_packet[250]; + iprn, + op_code, data_type, sv_prn, + data_length, data_packet[250]; ALM_INFO - *almanac; + *almanac; ALH_PARMS - *almh; + *almh; UTC_INFO - *utc; + *utc; ION_INFO - *ionosphere; + *ionosphere; EPHEM_CLOCK - *cdata; + *cdata; EPHEM_ORBIT - *edata; + *edata; NAV_INFO - *nav_data; + *nav_data; unsigned char - curr_t_oa; + curr_t_oa; unsigned short - curr_wn_oa; + curr_wn_oa; static char - *datname[] = - {"", "", "Almanac Orbit", - "Health Page & Ref Time", "Ionosphere", "UTC ", - "Ephemeris"}; + *datname[] = + {"", "", "Almanac Orbit", + "Health Page & Ref Time", "Ionosphere", "UTC ", + "Ephemeris"}; /* unload rptbuf */ if (rpt_0x58 (rpt, &op_code, &data_type, &sv_prn, - &data_length, data_packet)) - { + &data_length, data_packet)) + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nSystem data [%d]: %s SV%02d", - data_type, datname[data_type], sv_prn); + data_type, datname[data_type], sv_prn); switch (op_code) { - case 1: + case 1: pbuf += sprintf(pbuf, " Acknowledgment"); break; - case 2: + case 2: pbuf += sprintf(pbuf, " length = %d bytes", data_length); switch (data_type) { - case 2: + case 2: /* Almanac */ if (sv_prn == 0 || sv_prn > 32) { pbuf += sprintf(pbuf, " Binary PRN invalid"); @@ -3665,57 +3975,57 @@ static void rpt_GPS_system_data (TSIPPKT *rpt) } almanac = (ALM_INFO*)data_packet; pbuf += sprintf(pbuf, "\n t_oa_raw = % -12d SV_hlth = % -12d ", - almanac->t_oa_raw , almanac->SV_health ); + almanac->t_oa_raw , almanac->SV_health ); pbuf += sprintf(pbuf, "\n e = % -12g t_oa = % -12g ", - almanac->e , almanac->t_oa ); + almanac->e , almanac->t_oa ); pbuf += sprintf(pbuf, "\n i_0 = % -12g OMEGADOT = % -12g ", - almanac->i_0 , almanac->OMEGADOT ); + almanac->i_0 , almanac->OMEGADOT ); pbuf += sprintf(pbuf, "\n sqrt_A = % -12g OMEGA_0 = % -12g ", - almanac->sqrt_A , almanac->OMEGA_0 ); + almanac->sqrt_A , almanac->OMEGA_0 ); pbuf += sprintf(pbuf, "\n omega = % -12g M_0 = % -12g ", - almanac->omega , almanac->M_0 ); + almanac->omega , almanac->M_0 ); pbuf += sprintf(pbuf, "\n a_f0 = % -12g a_f1 = % -12g ", - almanac->a_f0 , almanac->a_f1 ); + almanac->a_f0 , almanac->a_f1 ); pbuf += sprintf(pbuf, "\n Axis = % -12g n = % -12g ", - almanac->Axis , almanac->n ); + almanac->Axis , almanac->n ); pbuf += sprintf(pbuf, "\n OMEGA_n = % -12g ODOT_n = % -12g ", - almanac->OMEGA_n , almanac->ODOT_n ); + almanac->OMEGA_n , almanac->ODOT_n ); pbuf += sprintf(pbuf, "\n t_zc = % -12g weeknum = % -12d ", - almanac->t_zc , almanac->weeknum ); + almanac->t_zc , almanac->weeknum ); pbuf += sprintf(pbuf, "\n wn_oa = % -12d", almanac->wn_oa ); break; - case 3: + case 3: /* Almanac health page */ almh = (ALH_PARMS*)data_packet; pbuf += sprintf(pbuf, "\n t_oa = %d, wn_oa&0xFF = %d ", - almh->t_oa, almh->WN_a); + almh->t_oa, almh->WN_a); pbuf += sprintf(pbuf, "\nAlmanac health page:"); for (iprn = 0; iprn < 32; iprn++) { if (!(iprn%5)) *pbuf++ = '\n'; pbuf += sprintf(pbuf, " SV%02d %2X", - (iprn+1) , almh->SV_health[iprn]); + (iprn+1) , almh->SV_health[iprn]); } curr_t_oa = data_packet[34]; curr_wn_oa = (unsigned short)((data_packet[35]<<8) + data_packet[36]); pbuf += sprintf(pbuf, "\n current t_oa = %d, wn_oa = %d ", - curr_t_oa, curr_wn_oa); + curr_t_oa, curr_wn_oa); break; - case 4: + case 4: /* Ionosphere */ ionosphere = (ION_INFO*)data_packet; pbuf += sprintf(pbuf, "\n alpha_0 = % -12g alpha_1 = % -12g ", - ionosphere->alpha_0, ionosphere->alpha_1); + ionosphere->alpha_0, ionosphere->alpha_1); pbuf += sprintf(pbuf, "\n alpha_2 = % -12g alpha_3 = % -12g ", - ionosphere->alpha_2, ionosphere->alpha_3); + ionosphere->alpha_2, ionosphere->alpha_3); pbuf += sprintf(pbuf, "\n beta_0 = % -12g beta_1 = % -12g ", - ionosphere->beta_0, ionosphere->beta_1); + ionosphere->beta_0, ionosphere->beta_1); pbuf += sprintf(pbuf, "\n beta_2 = % -12g beta_3 = % -12g ", - ionosphere->beta_2, ionosphere->beta_3); + ionosphere->beta_2, ionosphere->beta_3); break; - case 5: + case 5: /* UTC */ utc = (UTC_INFO*)data_packet; pbuf += sprintf(pbuf, "\n A_0 = %g ", utc->A_0); @@ -3728,7 +4038,7 @@ static void rpt_GPS_system_data (TSIPPKT *rpt) pbuf += sprintf(pbuf, "\n delta_t_LSF = %d ", utc->delta_t_LSF ); break; - case 6: /* Ephemeris */ + case 6: /* Ephemeris */ if (sv_prn == 0 || sv_prn > 32) { pbuf += sprintf(pbuf, " Binary PRN invalid"); return; @@ -3736,45 +4046,45 @@ static void rpt_GPS_system_data (TSIPPKT *rpt) nav_data = (NAV_INFO*)data_packet; pbuf += sprintf(pbuf, "\n SV_PRN = % -12d . t_ephem = % -12g . ", - nav_data->sv_number , nav_data->t_ephem ); + nav_data->sv_number , nav_data->t_ephem ); cdata = &(nav_data->ephclk); pbuf += sprintf(pbuf, - "\n weeknum = % -12d . codeL2 = % -12d . L2Pdata = % -12d", - cdata->weeknum , cdata->codeL2 , cdata->L2Pdata ); + "\n weeknum = % -12d . codeL2 = % -12d . L2Pdata = % -12d", + cdata->weeknum , cdata->codeL2 , cdata->L2Pdata ); pbuf += sprintf(pbuf, - "\n SVacc_raw = % -12d .SV_health = % -12d . IODC = % -12d", - cdata->SVacc_raw, cdata->SV_health, cdata->IODC ); + "\n SVacc_raw = % -12d .SV_health = % -12d . IODC = % -12d", + cdata->SVacc_raw, cdata->SV_health, cdata->IODC ); pbuf += sprintf(pbuf, - "\n T_GD = % -12g . t_oc = % -12g . a_f2 = % -12g", - cdata->T_GD, cdata->t_oc, cdata->a_f2 ); + "\n T_GD = % -12g . t_oc = % -12g . a_f2 = % -12g", + cdata->T_GD, cdata->t_oc, cdata->a_f2 ); pbuf += sprintf(pbuf, - "\n a_f1 = % -12g . a_f0 = % -12g . SVacc = % -12g", - cdata->a_f1, cdata->a_f0, cdata->SVacc ); + "\n a_f1 = % -12g . a_f0 = % -12g . SVacc = % -12g", + cdata->a_f1, cdata->a_f0, cdata->SVacc ); edata = &(nav_data->ephorb); pbuf += sprintf(pbuf, - "\n IODE = % -12d .fit_intvl = % -12d . C_rs = % -12g", - edata->IODE, edata->fit_interval, edata->C_rs ); + "\n IODE = % -12d .fit_intvl = % -12d . C_rs = % -12g", + edata->IODE, edata->fit_interval, edata->C_rs ); pbuf += sprintf(pbuf, - "\n delta_n = % -12g . M_0 = % -12g . C_uc = % -12g", - edata->delta_n, edata->M_0, edata->C_uc ); + "\n delta_n = % -12g . M_0 = % -12g . C_uc = % -12g", + edata->delta_n, edata->M_0, edata->C_uc ); pbuf += sprintf(pbuf, - "\n ecc = % -12g . C_us = % -12g . sqrt_A = % -12g", - edata->e, edata->C_us, edata->sqrt_A ); + "\n ecc = % -12g . C_us = % -12g . sqrt_A = % -12g", + edata->e, edata->C_us, edata->sqrt_A ); pbuf += sprintf(pbuf, - "\n t_oe = % -12g . C_ic = % -12g . OMEGA_0 = % -12g", - edata->t_oe, edata->C_ic, edata->OMEGA_0 ); + "\n t_oe = % -12g . C_ic = % -12g . OMEGA_0 = % -12g", + edata->t_oe, edata->C_ic, edata->OMEGA_0 ); pbuf += sprintf(pbuf, - "\n C_is = % -12g . i_0 = % -12g . C_rc = % -12g", - edata->C_is, edata->i_0, edata->C_rc ); + "\n C_is = % -12g . i_0 = % -12g . C_rc = % -12g", + edata->C_is, edata->i_0, edata->C_rc ); pbuf += sprintf(pbuf, - "\n omega = % -12g . OMEGADOT = % -12g . IDOT = % -12g", - edata->omega, edata->OMEGADOT, edata->IDOT ); + "\n omega = % -12g . OMEGADOT = % -12g . IDOT = % -12g", + edata->omega, edata->OMEGADOT, edata->IDOT ); pbuf += sprintf(pbuf, - "\n Axis = % -12g . n = % -12g . r1me2 = % -12g", - edata->Axis, edata->n, edata->r1me2 ); + "\n Axis = % -12g . n = % -12g . r1me2 = % -12g", + edata->Axis, edata->n, edata->r1me2 ); pbuf += sprintf(pbuf, - "\n OMEGA_n = % -12g . ODOT_n = % -12g", - edata->OMEGA_n, edata->ODOT_n ); + "\n OMEGA_n = % -12g . ODOT_n = % -12g", + edata->OMEGA_n, edata->ODOT_n ); break; } } @@ -3782,173 +4092,191 @@ static void rpt_GPS_system_data (TSIPPKT *rpt) /* 0x59: */ -static void rpt_SVs_enabled (TSIPPKT *rpt) +static void +rpt_SVs_enabled( + TSIPPKT *rpt + ) { unsigned char - numsvs, - code_type, - status_code[32]; + numsvs, + code_type, + status_code[32]; short - iprn; + iprn; /* unload rptbuf */ if (rpt_0x59 (rpt, &code_type, status_code)) - { + { parsed = BADLEN_PARSE; return; } - switch (code_type) - { - case 3: pbuf += sprintf(pbuf, "\nSVs Disabled:\n"); break; - case 6: pbuf += sprintf(pbuf, "\nSVs with Health Ignored:\n"); break; - default: return; - } - numsvs = 0; - for (iprn=0; iprn<32; iprn++) - { - if (status_code[iprn]) - { - pbuf += sprintf(pbuf, " %02d", iprn+1); - numsvs++; - } - } - if (numsvs == 0) pbuf += sprintf(pbuf, "None"); + switch (code_type) + { + case 3: pbuf += sprintf(pbuf, "\nSVs Disabled:\n"); break; + case 6: pbuf += sprintf(pbuf, "\nSVs with Health Ignored:\n"); break; + default: return; + } + numsvs = 0; + for (iprn = 0; iprn < 32; iprn++) + { + if (status_code[iprn]) + { + pbuf += sprintf(pbuf, " %02d", iprn+1); + numsvs++; + } + } + if (numsvs == 0) pbuf += sprintf(pbuf, "None"); } /* 0x5A */ -static void rpt_raw_msmt (TSIPPKT *rpt) +static void +rpt_raw_msmt( + TSIPPKT *rpt + ) { unsigned char - sv_prn; + sv_prn; float - sample_length, signal_level, code_phase, Doppler; + sample_length, signal_level, code_phase, Doppler; double - time_of_fix; + time_of_fix; /* unload rptbuf */ if (rpt_0x5A (rpt, &sv_prn, &sample_length, &signal_level, - &code_phase, &Doppler, &time_of_fix)) - { + &code_phase, &Doppler, &time_of_fix)) + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\n %02d %5.0f %7.1f %10.2f %10.2f %12.3f %s", - sv_prn, sample_length, signal_level, code_phase, Doppler, time_of_fix, - show_time ((float)time_of_fix)); + sv_prn, sample_length, signal_level, code_phase, Doppler, time_of_fix, + show_time ((float)time_of_fix)); } /* 0x5B */ -static void rpt_SV_ephemeris_status (TSIPPKT *rpt) +static void +rpt_SV_ephemeris_status( + TSIPPKT *rpt + ) { unsigned char - sv_prn, sv_health, sv_iode, fit_interval_flag; + sv_prn, sv_health, sv_iode, fit_interval_flag; float - time_of_collection, time_of_eph, sv_accy; + time_of_collection, time_of_eph, sv_accy; /* unload rptbuf */ if (rpt_0x5B (rpt, &sv_prn, &sv_health, &sv_iode, &fit_interval_flag, - &time_of_collection, &time_of_eph, &sv_accy)) - { + &time_of_collection, &time_of_eph, &sv_accy)) + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\n SV%02d %s %2Xh %2Xh ", - sv_prn, show_time (time_of_collection), sv_health, sv_iode); + sv_prn, show_time (time_of_collection), sv_health, sv_iode); /* note: cannot use show_time twice in same call */ pbuf += sprintf(pbuf, "%s %1d %4.1f", - show_time (time_of_eph), fit_interval_flag, sv_accy); + show_time (time_of_eph), fit_interval_flag, sv_accy); } /* 0x5C */ -static void rpt_SV_tracking_status (TSIPPKT *rpt) +static void +rpt_SV_tracking_status( + TSIPPKT *rpt + ) { unsigned char - sv_prn, chan, slot, acq_flag, eph_flag, - old_msmt_flag, integer_msec_flag, bad_data_flag, - data_collect_flag; + sv_prn, chan, slot, acq_flag, eph_flag, + old_msmt_flag, integer_msec_flag, bad_data_flag, + data_collect_flag; float - signal_level, time_of_last_msmt, - elev, azim; + signal_level, time_of_last_msmt, + elev, azim; /* unload rptbuf */ if (rpt_0x5C (rpt, - &sv_prn, &slot, &chan, &acq_flag, &eph_flag, - &signal_level, &time_of_last_msmt, &elev, &azim, - &old_msmt_flag, &integer_msec_flag, &bad_data_flag, - &data_collect_flag)) - { + &sv_prn, &slot, &chan, &acq_flag, &eph_flag, + &signal_level, &time_of_last_msmt, &elev, &azim, + &old_msmt_flag, &integer_msec_flag, &bad_data_flag, + &data_collect_flag)) + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, -"\n SV%2d %1d %1d %1d %4.1f %s %5.1f %5.1f", - sv_prn, chan, - acq_flag, eph_flag, signal_level, - show_time(time_of_last_msmt), - elev*R2D, azim*R2D); + "\n SV%2d %1d %1d %1d %4.1f %s %5.1f %5.1f", + sv_prn, chan, + acq_flag, eph_flag, signal_level, + show_time(time_of_last_msmt), + elev*R2D, azim*R2D); } /**/ /* 0x6D */ -static void rpt_allSV_selection (TSIPPKT *rpt) +static void +rpt_allSV_selection( + TSIPPKT *rpt + ) { unsigned char - manual_mode, nsvs, sv_prn[8], ndim; + manual_mode, nsvs, sv_prn[8], ndim; short - islot; + islot; float - pdop, hdop, vdop, tdop; + pdop, hdop, vdop, tdop; /* unload rptbuf */ if (rpt_0x6D (rpt, - &manual_mode, &nsvs, &ndim, sv_prn, - &pdop, &hdop, &vdop, &tdop)) - { + &manual_mode, &nsvs, &ndim, sv_prn, + &pdop, &hdop, &vdop, &tdop)) + { parsed = BADLEN_PARSE; return; } switch (ndim) - { - case 0: + { + case 0: pbuf += sprintf(pbuf, "\nMode: Searching, %d-SV:", nsvs); - break; - case 1: + break; + case 1: pbuf += sprintf(pbuf, "\nMode: One-SV Timing:"); - break; - case 3: case 4: + break; + case 3: case 4: pbuf += sprintf(pbuf, "\nMode: %c-%dD, %d-SV:", - manual_mode ? 'M' : 'A', ndim - 1, nsvs); - break; - case 5: + manual_mode ? 'M' : 'A', ndim - 1, nsvs); + break; + case 5: pbuf += sprintf(pbuf, "\nMode: Timing, %d-SV:", nsvs); - break; - default: + break; + default: pbuf += sprintf(pbuf, "\nMode: Unknown = %d:", ndim); - break; - } + break; + } for (islot = 0; islot < nsvs; islot++) - { + { if (sv_prn[islot]) pbuf += sprintf(pbuf, " %02d", sv_prn[islot]); } - if (ndim == 3 || ndim == 4) - { + if (ndim == 3 || ndim == 4) + { pbuf += sprintf(pbuf, "; DOPs: P %.1f H %.1f V %.1f T %.1f", - pdop, hdop, vdop, tdop); - } + pdop, hdop, vdop, tdop); + } } /**/ /* 0x82 */ -static void rpt_DGPS_position_mode (TSIPPKT *rpt) +static void +rpt_DGPS_position_mode( + TSIPPKT *rpt + ) { unsigned char - diff_mode; + diff_mode; /* unload rptbuf */ if (rpt_0x82 (rpt, &diff_mode)) { @@ -3957,49 +4285,54 @@ static void rpt_DGPS_position_mode (TSIPPKT *rpt) } pbuf += sprintf(pbuf, "\nFix is%s DGPS-corrected (%s mode) (%d)", - (diff_mode&1) ? "" : " not", - (diff_mode&2) ? "auto" : "manual", - diff_mode); + (diff_mode&1) ? "" : " not", + (diff_mode&2) ? "auto" : "manual", + diff_mode); } /* 0x83 */ -static void rpt_double_ECEF_position (TSIPPKT *rpt) +static void +rpt_double_ECEF_position( + TSIPPKT *rpt + ) { - double - ECEF_pos[3], clock_bias; + ECEF_pos[3], clock_bias; float - time_of_fix; + time_of_fix; /* unload rptbuf */ if (rpt_0x83 (rpt, ECEF_pos, &clock_bias, &time_of_fix)) - { + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nDXYZ:%12.2f %13.2f %13.2f %12.2f%s", - ECEF_pos[0], ECEF_pos[1], ECEF_pos[2], clock_bias, - show_time(time_of_fix)); + ECEF_pos[0], ECEF_pos[1], ECEF_pos[2], clock_bias, + show_time(time_of_fix)); } /* 0x84 */ -static void rpt_double_lla_position (TSIPPKT *rpt) +static void +rpt_double_lla_position( + TSIPPKT *rpt + ) { short - lat_deg, lon_deg; + lat_deg, lon_deg; double - lat, lon, lat_min, lon_min, - alt, clock_bias; + lat, lon, lat_min, lon_min, + alt, clock_bias; float - time_of_fix; + time_of_fix; unsigned char - north_south, east_west; + north_south, east_west; /* unload rptbuf */ if (rpt_0x84 (rpt, - &lat, &lon, &alt, &clock_bias, &time_of_fix)) - { + &lat, &lon, &alt, &clock_bias, &time_of_fix)) + { parsed = BADLEN_PARSE; return; } @@ -4024,14 +4357,17 @@ static void rpt_double_lla_position (TSIPPKT *rpt) lon_deg = (short)lon; lon_min = (lon - lon_deg) * 60.0; pbuf += sprintf(pbuf, "\nDLLA: %2d:%08.5f %c; %3d:%08.5f %c; %10.2f %12.2f%s", - lat_deg, lat_min, north_south, - lon_deg, lon_min, east_west, - alt, clock_bias, - show_time(time_of_fix)); + lat_deg, lat_min, north_south, + lon_deg, lon_min, east_west, + alt, clock_bias, + show_time(time_of_fix)); } /* 0xBB */ -static void rpt_complete_rcvr_config (TSIPPKT *rpt) +static void +rpt_complete_rcvr_config( + TSIPPKT *rpt + ) { TSIP_RCVR_CFG TsipxBB ; /* unload rptbuf */ @@ -4042,49 +4378,52 @@ static void rpt_complete_rcvr_config (TSIPPKT *rpt) } pbuf += sprintf(pbuf, "\n operating mode: %s", - NavModeText0xBB[TsipxBB.operating_mode]); + NavModeText0xBB[TsipxBB.operating_mode]); pbuf += sprintf(pbuf, "\n dynamics: %s", - dyn_text[TsipxBB.dyn_code]); + dyn_text[TsipxBB.dyn_code]); pbuf += sprintf(pbuf, "\n elev angle mask: %g deg", - TsipxBB.elev_mask * R2D); + TsipxBB.elev_mask * R2D); pbuf += sprintf(pbuf, "\n SNR mask: %g AMU", - TsipxBB.cno_mask); + TsipxBB.cno_mask); pbuf += sprintf(pbuf, "\n DOP mask: %g", - TsipxBB.dop_mask); + TsipxBB.dop_mask); pbuf += sprintf(pbuf, "\n DOP switch: %g", - TsipxBB.dop_switch); + TsipxBB.dop_switch); return ; } /* 0xBC */ -static void rpt_rcvr_serial_port_config (TSIPPKT *rpt) +static void +rpt_rcvr_serial_port_config( + TSIPPKT *rpt + ) { unsigned char - port_num, in_baud, out_baud, data_bits, parity, stop_bits, flow_control, - protocols_in, protocols_out, reserved; + port_num, in_baud, out_baud, data_bits, parity, stop_bits, flow_control, + protocols_in, protocols_out, reserved; unsigned char known; /* unload rptbuf */ if (rpt_0xBC (rpt, &port_num, &in_baud, &out_baud, &data_bits, &parity, - &stop_bits, &flow_control, &protocols_in, &protocols_out, &reserved)) { + &stop_bits, &flow_control, &protocols_in, &protocols_out, &reserved)) { parsed = BADLEN_PARSE; return; } /* rptbuf unloaded */ pbuf += sprintf(pbuf, "\n RECEIVER serial port %s config:", - rcvr_port_text[port_num]); + rcvr_port_text[port_num]); pbuf += sprintf(pbuf, "\n I/O Baud %s/%s, %d - %s - %d", - st_baud_text_app[in_baud], - st_baud_text_app[out_baud], - data_bits+5, - parity_text[parity], - stop_bits=1); + st_baud_text_app[in_baud], + st_baud_text_app[out_baud], + data_bits+5, + parity_text[parity], + stop_bits=1); pbuf += sprintf(pbuf, "\n Input protocols: "); known = FALSE; if (protocols_in&B_TSIP) - { + { pbuf += sprintf(pbuf, "%s ", protocols_in_text[1]); known = TRUE; } @@ -4093,98 +4432,101 @@ static void rpt_rcvr_serial_port_config (TSIPPKT *rpt) pbuf += sprintf(pbuf, "\n Output protocols: "); known = FALSE; if (protocols_out&B_TSIP) - { + { pbuf += sprintf(pbuf, "%s ", protocols_out_text[1]); known = TRUE; } if (protocols_out&B_NMEA) - { + { pbuf += sprintf(pbuf, "%s ", protocols_out_text[2]); known = TRUE; } if (known == FALSE) pbuf += sprintf(pbuf, "No known"); reserved = reserved; - } +} /* 0x8F */ /* 8F0B */ -static void rpt_8F0B(TSIPPKT *rpt) +static void +rpt_8F0B( + TSIPPKT *rpt + ) { const char - *oprtng_dim[7] = { - "horizontal (2-D)", - "full position (3-D)", - "single satellite (0-D)", - "automatic", - "N/A", - "N/A", - "overdetermined clock"}; - char - sv_id[8]; - unsigned char - month, - date, - dim_mode, - north_south, - east_west; - unsigned short - event; - short - utc_offset, - year, - local_index; + *oprtng_dim[7] = { + "horizontal (2-D)", + "full position (3-D)", + "single satellite (0-D)", + "automatic", + "N/A", + "N/A", + "overdetermined clock"}; + char + sv_id[8]; + unsigned char + month, + date, + dim_mode, + north_south, + east_west; + unsigned short + event; short - lat_deg, - lon_deg; - float - bias_unc, - dr_unc; - double - tow, - bias, - drift, - lat, - lon, - alt, - lat_min, - lon_min; - int - numfix, - numnotfix; + utc_offset, + year, + local_index; + short + lat_deg, + lon_deg; + float + bias_unc, + dr_unc; + double + tow, + bias, + drift, + lat, + lon, + alt, + lat_min, + lon_min; + int + numfix, + numnotfix; if (rpt_0x8F0B(rpt, - &event, - &tow, - &date, - &month, - &year, - &dim_mode, - &utc_offset, - &bias, - &drift, - &bias_unc, - &dr_unc, - &lat, - &lon, - &alt, - sv_id)) - { + &event, + &tow, + &date, + &month, + &year, + &dim_mode, + &utc_offset, + &bias, + &drift, + &bias_unc, + &dr_unc, + &lat, + &lon, + &alt, + sv_id)) + { parsed = BADLEN_PARSE; return; } if (event == 0) - { - pbuf += sprintf(pbuf, "\nNew partial+full meas"); + { + pbuf += sprintf(pbuf, "\nNew partial+full meas"); } - else - { + else + { pbuf += sprintf(pbuf, "\nEvent count: %5d", event); - } + } pbuf += sprintf(pbuf, "\nGPS time : %s %2d/%2d/%2d (DMY)", - show_time(tow), date, month, year); + show_time(tow), date, month, year); pbuf += sprintf(pbuf, "\nMode : %s", oprtng_dim[dim_mode]); pbuf += sprintf(pbuf, "\nUTC offset: %2d", utc_offset); pbuf += sprintf(pbuf, "\nClock Bias: %6.2f m", bias); @@ -4195,24 +4537,24 @@ static void rpt_8F0B(TSIPPKT *rpt) lat *= R2D; /* convert from radians to degrees */ lon *= R2D; if (lat < 0.0) - { + { north_south = 'S'; lat = -lat; } - else - { + else + { north_south = 'N'; } lat_deg = (short)lat; lat_min = (lat - lat_deg) * 60.0; if (lon < 0.0) - { + { east_west = 'W'; lon = -lon; } - else - { + else + { east_west = 'E'; } @@ -4223,79 +4565,85 @@ static void rpt_8F0B(TSIPPKT *rpt) pbuf += sprintf(pbuf, " %5d %6.3f %c", lon_deg, lon_min, east_west); pbuf += sprintf(pbuf, " %10.2f", alt); - numfix = numnotfix = 0; + numfix = numnotfix = 0; for (local_index=0; local_index<8; local_index++) - { + { if (sv_id[local_index] < 0) numnotfix++; if (sv_id[local_index] > 0) numfix++; - } - if (numfix > 0) - { + } + if (numfix > 0) + { pbuf += sprintf(pbuf, "\nSVs used in fix : "); for (local_index=0; local_index<8; local_index++) - { + { if (sv_id[local_index] > 0) - { - pbuf += sprintf(pbuf, "%2d ", sv_id[local_index]); - } - } - } - if (numnotfix > 0) - { + { + pbuf += sprintf(pbuf, "%2d ", sv_id[local_index]); + } + } + } + if (numnotfix > 0) + { pbuf += sprintf(pbuf, "\nOther SVs tracked: "); for (local_index=0; local_index<8; local_index++) - { + { if (sv_id[local_index] < 0) - { - pbuf += sprintf(pbuf, "%2d ", sv_id[local_index]); - } - } - } + { + pbuf += sprintf(pbuf, "%2d ", sv_id[local_index]); + } + } + } } /* 0x8F14 */ -static void rpt_8F14 (TSIPPKT *rpt) /* Datum parameters */ +static void +rpt_8F14( + TSIPPKT *rpt + ) { double - datum_coeffs[5]; + datum_coeffs[5]; short - datum_idx; + datum_idx; /* unload rptbuf */ if (rpt_0x8F14 (rpt, &datum_idx, datum_coeffs)) - { + { parsed = BADLEN_PARSE; return; } if (datum_idx == -1) - { - pbuf += sprintf(pbuf, "\nUser-Entered Datum:"); + { + pbuf += sprintf(pbuf, "\nUser-Entered Datum:"); pbuf += sprintf(pbuf, "\n dx = %6.1f", datum_coeffs[0]); pbuf += sprintf(pbuf, "\n dy = %6.1f", datum_coeffs[1]); pbuf += sprintf(pbuf, "\n dz = %6.1f", datum_coeffs[2]); pbuf += sprintf(pbuf, "\n a-axis = %10.3f", datum_coeffs[3]); pbuf += sprintf(pbuf, "\n e-squared = %16.14f", datum_coeffs[4]); - } - else if (datum_idx == 0) - { - pbuf += sprintf(pbuf, "\nWGS-84 datum, Index 0 "); - } - else - { - pbuf += sprintf(pbuf, "\nStandard Datum, Index %3d ", datum_idx); - } + } + else if (datum_idx == 0) + { + pbuf += sprintf(pbuf, "\nWGS-84 datum, Index 0 "); + } + else + { + pbuf += sprintf(pbuf, "\nStandard Datum, Index %3d ", datum_idx); + } } /* 0x8F15 */ -static void rpt_8F15 (TSIPPKT *rpt) /* Datum parameters */ +static void +rpt_8F15( + TSIPPKT *rpt + ) { double - datum_coeffs[5]; + datum_coeffs[5]; short - datum_idx; + datum_idx; /* unload rptbuf */ if (rpt_0x8F15 (rpt, &datum_idx, datum_coeffs)) { @@ -4304,22 +4652,22 @@ static void rpt_8F15 (TSIPPKT *rpt) } if (datum_idx == -1) - { - pbuf += sprintf(pbuf, "\nUser-Entered Datum:"); + { + pbuf += sprintf(pbuf, "\nUser-Entered Datum:"); pbuf += sprintf(pbuf, "\n dx = %6.1f", datum_coeffs[0]); pbuf += sprintf(pbuf, "\n dy = %6.1f", datum_coeffs[1]); pbuf += sprintf(pbuf, "\n dz = %6.1f", datum_coeffs[2]); pbuf += sprintf(pbuf, "\n a-axis = %10.3f", datum_coeffs[3]); pbuf += sprintf(pbuf, "\n e-squared = %16.14f", datum_coeffs[4]); - } - else if (datum_idx == 0) - { - pbuf += sprintf(pbuf, "\nWGS-84 datum, Index 0 "); - } - else - { - pbuf += sprintf(pbuf, "\nStandard Datum, Index %3d ", datum_idx); - } + } + else if (datum_idx == 0) + { + pbuf += sprintf(pbuf, "\nWGS-84 datum, Index 0 "); + } + else + { + pbuf += sprintf(pbuf, "\nStandard Datum, Index %3d ", datum_idx); + } } /* 0x8F20 */ @@ -4327,72 +4675,75 @@ static void rpt_8F15 (TSIPPKT *rpt) #define INFO_2D 0x04 #define INFO_ALTSET 0x08 #define INFO_FILTERED 0x10 -static void rpt_8F20 (TSIPPKT *rpt) +static void +rpt_8F20( + TSIPPKT *rpt + ) { unsigned char - info, nsvs, sv_prn[32]; + info, nsvs, sv_prn[32]; short - week_num, datum_index, sv_IODC[32]; + week_num, datum_index, sv_IODC[32]; double - lat, lon, alt, time_of_fix; + lat, lon, alt, time_of_fix; double - londeg, latdeg, vel[3]; + londeg, latdeg, vel[3]; short - isv; - char - datum_string[20]; + isv; + char + datum_string[20]; /* unload rptbuf */ if (rpt_0x8F20 (rpt, - &info, &lat, &lon, &alt, vel, - &time_of_fix, - &week_num, &nsvs, sv_prn, sv_IODC, &datum_index)) + &info, &lat, &lon, &alt, vel, + &time_of_fix, + &week_num, &nsvs, sv_prn, sv_IODC, &datum_index)) { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, - "\nFix at: %04d:%3s:%02d:%02d:%06.3f GPS (=UTC+%2ds) FixType: %s%s%s", - week_num, - dayname[(short)(time_of_fix/86400.0)], - (short)fmod(time_of_fix/3600., 24.), - (short)fmod(time_of_fix/60., 60.), - fmod(time_of_fix, 60.), - (char)rpt->buf[29], /* UTC offset */ - (info & INFO_DGPS)?"Diff":"", - (info & INFO_2D)?"2D":"3D", - (info & INFO_FILTERED)?"-Filtrd":""); - - if (datum_index > 0) - { + "\nFix at: %04d:%3s:%02d:%02d:%06.3f GPS (=UTC+%2ds) FixType: %s%s%s", + week_num, + dayname[(short)(time_of_fix/86400.0)], + (short)fmod(time_of_fix/3600., 24.), + (short)fmod(time_of_fix/60., 60.), + fmod(time_of_fix, 60.), + (char)rpt->buf[29], /* UTC offset */ + (info & INFO_DGPS)?"Diff":"", + (info & INFO_2D)?"2D":"3D", + (info & INFO_FILTERED)?"-Filtrd":""); + + if (datum_index > 0) + { sprintf(datum_string, "Datum%3d", datum_index); - } - else if (datum_index) - { + } + else if (datum_index) + { sprintf(datum_string, "Unknown "); - } - else - { + } + else + { sprintf(datum_string, "WGS-84"); - } + } /* convert from radians to degrees */ latdeg = R2D * fabs(lat); londeg = R2D * fabs(lon); pbuf += sprintf(pbuf, - "\n Pos: %4d:%09.6f %c %5d:%09.6f %c %10.2f m HAE (%s)", - (short)latdeg, fmod (latdeg, 1.)*60.0, - (lat<0.0)?'S':'N', - (short)londeg, fmod (londeg, 1.)*60.0, - (lon<0.0)?'W':'E', - alt, - datum_string); + "\n Pos: %4d:%09.6f %c %5d:%09.6f %c %10.2f m HAE (%s)", + (short)latdeg, fmod (latdeg, 1.)*60.0, + (lat<0.0)?'S':'N', + (short)londeg, fmod (londeg, 1.)*60.0, + (lon<0.0)?'W':'E', + alt, + datum_string); pbuf += sprintf(pbuf, - "\n Vel: %9.3f E %9.3f N %9.3f U (m/sec)", - vel[0], vel[1], vel[2]); + "\n Vel: %9.3f E %9.3f N %9.3f U (m/sec)", + vel[0], vel[1], vel[2]); pbuf += sprintf(pbuf, - "\n SVs: "); + "\n SVs: "); for (isv = 0; isv < nsvs; isv++) { pbuf += sprintf(pbuf, " %02d", sv_prn[isv]); } @@ -4404,361 +4755,394 @@ static void rpt_8F20 (TSIPPKT *rpt) } /* 0x8F41 */ -static void rpt_8F41(TSIPPKT *rpt) +static void +rpt_8F41( + TSIPPKT *rpt + ) { unsigned char - bSearchRange, - bBoardOptions, - bBuildYear, - bBuildMonth, - bBuildDay, - bBuildHour; + bSearchRange, + bBoardOptions, + bBuildYear, + bBuildMonth, + bBuildDay, + bBuildHour; float - fOscOffset; + fOscOffset; unsigned short - iTestCodeId; + iTestCodeId; unsigned long - iiSerialNumber; - - if (!rpt_0x8F41(rpt, - &bSearchRange, - &bBoardOptions, - &iiSerialNumber, - &bBuildYear, - &bBuildMonth, - &bBuildDay, - &bBuildHour, - &fOscOffset, - &iTestCodeId)) - { + iiSerialNumber; + + if (!rpt_0x8F41(rpt, + &bSearchRange, + &bBoardOptions, + &iiSerialNumber, + &bBuildYear, + &bBuildMonth, + &bBuildDay, + &bBuildHour, + &fOscOffset, + &iTestCodeId)) + { parsed = BADLEN_PARSE; - return; - } - - pbuf += sprintf(pbuf, "\n search range: %d", - bSearchRange); - pbuf += sprintf(pbuf, "\n board options: %d", - bBoardOptions); - pbuf += sprintf(pbuf, "\n board serial #: %ld", - iiSerialNumber); - pbuf += sprintf(pbuf, "\n build date/hour: %02d/%02d/%02d %02d:00", - bBuildDay, bBuildMonth, bBuildYear, bBuildHour); - pbuf += sprintf(pbuf, "\n osc offset: %.3f PPM (%.0f Hz)", - fOscOffset/1575.42, fOscOffset); - pbuf += sprintf(pbuf, "\n test code: %d", - iTestCodeId); + return; + } + + pbuf += sprintf(pbuf, "\n search range: %d", + bSearchRange); + pbuf += sprintf(pbuf, "\n board options: %d", + bBoardOptions); + pbuf += sprintf(pbuf, "\n board serial #: %ld", + iiSerialNumber); + pbuf += sprintf(pbuf, "\n build date/hour: %02d/%02d/%02d %02d:00", + bBuildDay, bBuildMonth, bBuildYear, bBuildHour); + pbuf += sprintf(pbuf, "\n osc offset: %.3f PPM (%.0f Hz)", + fOscOffset/1575.42, fOscOffset); + pbuf += sprintf(pbuf, "\n test code: %d", + iTestCodeId); } /* 0x8F42 */ -static void rpt_8F42(TSIPPKT *rpt) +static void +rpt_8F42( + TSIPPKT *rpt + ) { unsigned char - bProdOptionsPre, - bProdNumberExt; + bProdOptionsPre, + bProdNumberExt; unsigned short - iCaseSerialNumberPre, - iPremiumOptions, - iMachineID, - iKey; + iCaseSerialNumberPre, + iPremiumOptions, + iMachineID, + iKey; unsigned long - iiCaseSerialNumber, - iiProdNumber; - - if (!rpt_0x8F42(rpt, - &bProdOptionsPre, - &bProdNumberExt, - &iCaseSerialNumberPre, - &iiCaseSerialNumber, - &iiProdNumber, - &iPremiumOptions, - &iMachineID, - &iKey)) - { + iiCaseSerialNumber, + iiProdNumber; + + if (!rpt_0x8F42(rpt, + &bProdOptionsPre, + &bProdNumberExt, + &iCaseSerialNumberPre, + &iiCaseSerialNumber, + &iiProdNumber, + &iPremiumOptions, + &iMachineID, + &iKey)) + { parsed = BADLEN_PARSE; - return; - } + return; + } pbuf += sprintf(pbuf, "\nProduct ID 8F42"); - pbuf += sprintf(pbuf, "\n extension: %d", bProdNumberExt); - pbuf += sprintf(pbuf, "\n case serial # prefix: %d", iCaseSerialNumberPre); - pbuf += sprintf(pbuf, "\n case serial #: %ld", iiCaseSerialNumber); - pbuf += sprintf(pbuf, "\n prod. #: %ld", iiProdNumber); + pbuf += sprintf(pbuf, "\n extension: %d", bProdNumberExt); + pbuf += sprintf(pbuf, "\n case serial # prefix: %d", iCaseSerialNumberPre); + pbuf += sprintf(pbuf, "\n case serial #: %ld", iiCaseSerialNumber); + pbuf += sprintf(pbuf, "\n prod. #: %ld", iiProdNumber); pbuf += sprintf(pbuf, "\n premium options: %Xh", iPremiumOptions); - pbuf += sprintf(pbuf, "\n machine ID: %d", iMachineID); - pbuf += sprintf(pbuf, "\n key: %Xh", iKey); + pbuf += sprintf(pbuf, "\n machine ID: %d", iMachineID); + pbuf += sprintf(pbuf, "\n key: %Xh", iKey); } /* 0x8F45 */ -static void rpt_8F45(TSIPPKT *rpt) +static void +rpt_8F45( + TSIPPKT *rpt + ) { - unsigned char bSegMask; + unsigned char bSegMask; - if (!rpt_0x8F45(rpt, - &bSegMask)) - { + if (!rpt_0x8F45(rpt, + &bSegMask)) + { parsed = BADLEN_PARSE; return; } pbuf += sprintf(pbuf, "\nCleared Segment Mask: %Xh", bSegMask); } -static void rpt_8F4A(TSIPPKT *rpt) /* Stinger PPS def */ +static void +rpt_8F4A( + TSIPPKT *rpt + ) { unsigned char - pps_enabled, - pps_timebase, - pps_polarity; - float - bias_unc_threshold; - double - pps_offset; + pps_enabled, + pps_timebase, + pps_polarity; + float + bias_unc_threshold; + double + pps_offset; if (rpt_0x8F4A_16 (rpt, - &pps_enabled, - &pps_timebase, - &pps_polarity, - &pps_offset, - &bias_unc_threshold)) - { - parsed = BADLEN_PARSE; - return; - } + &pps_enabled, + &pps_timebase, + &pps_polarity, + &pps_offset, + &bias_unc_threshold)) + { + parsed = BADLEN_PARSE; + return; + } pbuf += sprintf(pbuf, "\nPPS is %s", pps_enabled?"enabled":"disabled"); - pbuf += sprintf(pbuf, "\n timebase: %s", PPSTimeBaseText[pps_timebase]); - pbuf += sprintf(pbuf, "\n polarity: %s", PPSPolarityText[pps_polarity]); - pbuf += sprintf(pbuf, "\n offset: %.1f ns, ", pps_offset*1.e9); - pbuf += sprintf(pbuf, "\n biasunc: %.1f ns", bias_unc_threshold/GPS_C*1.e9); + pbuf += sprintf(pbuf, "\n timebase: %s", PPSTimeBaseText[pps_timebase]); + pbuf += sprintf(pbuf, "\n polarity: %s", PPSPolarityText[pps_polarity]); + pbuf += sprintf(pbuf, "\n offset: %.1f ns, ", pps_offset*1.e9); + pbuf += sprintf(pbuf, "\n biasunc: %.1f ns", bias_unc_threshold/GPS_C*1.e9); } -static void rpt_8F4B(TSIPPKT *rpt) /* fast-SA decorrolation time for self-survey */ +static void +rpt_8F4B( + TSIPPKT *rpt + ) { unsigned long - decorr_max; + decorr_max; - if (rpt_0x8F4B(rpt, &decorr_max)) - { + if (rpt_0x8F4B(rpt, &decorr_max)) + { parsed = BADLEN_PARSE; - return; - } + return; + } - pbuf += sprintf(pbuf, - "\nMax # of position fixes for self-survey : %ld", - decorr_max); + pbuf += sprintf(pbuf, + "\nMax # of position fixes for self-survey : %ld", + decorr_max); } -static void rpt_8F4D(TSIPPKT *rpt) +static void +rpt_8F4D( + TSIPPKT *rpt + ) { static char - *linestart; + *linestart; unsigned long - OutputMask; - static unsigned long - MaskBit[] = { - 0x00000001, 0x00000002, 0x00000004, 0x00000008, 0x00000010, 0x00000020, - 0x00000100L, 0x00000800L, 0x00001000L, - 0x40000000L, 0x80000000L}; - int - ichoice, - numchoices; - - if (rpt_0x8F4D(rpt, &OutputMask)) - { + OutputMask; + static unsigned long + MaskBit[] = { + 0x00000001, 0x00000002, 0x00000004, 0x00000008, 0x00000010, + 0x00000020, + 0x00000100L, 0x00000800L, 0x00001000L, + 0x40000000L, 0x80000000L}; + int + ichoice, + numchoices; + + if (rpt_0x8F4D(rpt, &OutputMask)) + { parsed = BADLEN_PARSE; - return; - } - - pbuf += sprintf(pbuf, "\nAuto-Report Mask: %02X %02X %02X %02X", - (unsigned char)(OutputMask>>24), - (unsigned char)(OutputMask>>16), - (unsigned char)(OutputMask>>8), - (unsigned char)OutputMask); - - numchoices = sizeof(MaskText)/sizeof(char*); - pbuf += sprintf(pbuf, "\nAuto-Reports scheduled for Output:"); - linestart = pbuf; - for (ichoice=0; ichoice>24), + (unsigned char)(OutputMask>>16), + (unsigned char)(OutputMask>>8), + (unsigned char)OutputMask); + + numchoices = sizeof(MaskText)/sizeof(char*); + pbuf += sprintf(pbuf, "\nAuto-Reports scheduled for Output:"); + linestart = pbuf; + for (ichoice = 0; ichoice < numchoices; ichoice++) + { + if (OutputMask&MaskBit[ichoice]) + { + pbuf += sprintf(pbuf, "%s %s", + (pbuf==linestart)?"\n ":",", + MaskText[ichoice]); if (pbuf-linestart > 60) linestart = pbuf; - } - } - - pbuf += sprintf(pbuf, "\nAuto-Reports NOT scheduled for Output:"); - linestart = pbuf; - for (ichoice=0; ichoice 60) linestart = pbuf; - } + } } -static void rpt_8FA5(TSIPPKT *rpt) +static void +rpt_8FA5( + TSIPPKT *rpt + ) { unsigned char - spktmask[4]; + spktmask[4]; - if (rpt_0x8FA5(rpt, spktmask)) - { + if (rpt_0x8FA5(rpt, spktmask)) + { parsed = BADLEN_PARSE; - return; - } - - pbuf += sprintf(pbuf, "\nSuperpacket auto-output mask: %02X %02X %02X %02X", - spktmask[0], spktmask[1], spktmask[2], spktmask[3]); - - if (spktmask[0]&0x01) pbuf+= sprintf (pbuf, "\n PPS 8F-0B"); - if (spktmask[0]&0x02) pbuf+= sprintf (pbuf, "\n Event 8F-0B"); - if (spktmask[0]&0x10) pbuf+= sprintf (pbuf, "\n PPS 8F-AD"); - if (spktmask[0]&0x20) pbuf+= sprintf (pbuf, "\n Event 8F-AD"); - if (spktmask[2]&0x01) pbuf+= sprintf (pbuf, "\n ppos Fix 8F-20"); -} - -static void rpt_8FAD (TSIPPKT *rpt) -{ - unsigned short - Count, - Year; - double - FracSec; - unsigned char - Hour, - Minute, - Second, - Day, - Month, - Status, - Flags; + return; + } + + pbuf += sprintf(pbuf, "\nSuperpacket auto-output mask: %02X %02X %02X %02X", + spktmask[0], spktmask[1], spktmask[2], spktmask[3]); + + if (spktmask[0]&0x01) pbuf+= sprintf (pbuf, "\n PPS 8F-0B"); + if (spktmask[0]&0x02) pbuf+= sprintf (pbuf, "\n Event 8F-0B"); + if (spktmask[0]&0x10) pbuf+= sprintf (pbuf, "\n PPS 8F-AD"); + if (spktmask[0]&0x20) pbuf+= sprintf (pbuf, "\n Event 8F-AD"); + if (spktmask[2]&0x01) pbuf+= sprintf (pbuf, "\n ppos Fix 8F-20"); +} + +static void +rpt_8FAD( + TSIPPKT *rpt + ) +{ + unsigned short + Count, + Year; + double + FracSec; + unsigned char + Hour, + Minute, + Second, + Day, + Month, + Status, + Flags; static char* Status8FADText[] = { - "CODE_DOING_FIXES", - "CODE_GOOD_1_SV", - "CODE_APPX_1SV", - "CODE_NEED_TIME", - "CODE_NEED_INITIALIZATION", - "CODE_PDOP_HIGH", - "CODE_BAD_1SV", - "CODE_0SVS", - "CODE_1SV", - "CODE_2SVS", - "CODE_3SVS", - "CODE_NO_INTEGRITY", - "CODE_DCORR_GEN", - "CODE_OVERDET_CLK", - "Invalid Status"}, - *LeapStatusText[] = { - " UTC Avail", " ", " ", " ", - " Scheduled", " Pending", " Warning", " In Progress"}; - int i; + "CODE_DOING_FIXES", + "CODE_GOOD_1_SV", + "CODE_APPX_1SV", + "CODE_NEED_TIME", + "CODE_NEED_INITIALIZATION", + "CODE_PDOP_HIGH", + "CODE_BAD_1SV", + "CODE_0SVS", + "CODE_1SV", + "CODE_2SVS", + "CODE_3SVS", + "CODE_NO_INTEGRITY", + "CODE_DCORR_GEN", + "CODE_OVERDET_CLK", + "Invalid Status"}, + *LeapStatusText[] = { + " UTC Avail", " ", " ", " ", + " Scheduled", " Pending", " Warning", " In Progress"}; + int i; if (rpt_0x8FAD (rpt, - &Count, - &FracSec, - &Hour, - &Minute, - &Second, - &Day, - &Month, - &Year, - &Status, - &Flags)) - { + &Count, + &FracSec, + &Hour, + &Minute, + &Second, + &Day, + &Month, + &Year, + &Status, + &Flags)) + { parsed = BADLEN_PARSE; return; - } + } pbuf += sprintf(pbuf, "\n8FAD Count: %d Status: %s", - Count, Status8FADText[Status]); - - pbuf += sprintf(pbuf, "\n Leap Flags:"); - if (Flags) - { - for (i=0; i<8; i++) - { - if (Flags&(1<code, rpt->len); - } + rpt->code, rpt->len); + } if (parsed == BADID_PARSE) - { + { pbuf += sprintf(pbuf, - "\nTSIP report packet ID %2Xh, length %d: translation not supported", - rpt->code, rpt->len); - } + "\nTSIP report packet ID %2Xh, length %d: translation not supported", + rpt->code, rpt->len); + } if (parsed == BADDATA_PARSE) - { + { pbuf += sprintf(pbuf, - "\nTSIP report packet ID %2Xh, length %d: data content incorrect", - rpt->code, rpt->len); - } + "\nTSIP report packet ID %2Xh, length %d: data content incorrect", + rpt->code, rpt->len); + } for (i = 0; i < rpt->len; i++) { if ((i % 20) == 0) *pbuf++ = '\n'; @@ -4766,96 +5150,101 @@ static void unknown_rpt (TSIPPKT *rpt) } } /**/ + /* ** main subroutine, called from ProcessInputBytesWhileWaitingForKBHit() */ -void TranslateTSIPReportToText (TSIPPKT *rpt, char *TextOutputBuffer) +void +TranslateTSIPReportToText( + TSIPPKT *rpt, + char *TextOutputBuffer + ) { /* pbuf is the pointer to the current location of the text output */ pbuf = TextOutputBuffer; - /* keep track of whether the message has been successfully parsed */ + /* keep track of whether the message has been successfully parsed */ parsed = GOOD_PARSE; /* print a header if this is the first of a series of messages */ pbuf += print_msg_table_header (rpt->code, pbuf, FALSE); - /* process incoming TSIP report according to code */ + /* process incoming TSIP report according to code */ switch (rpt->code) - { - case 0x3D: rpt_chan_A_config (rpt); break; - case 0x40: rpt_almanac_data_page (rpt); break; - case 0x41: rpt_GPS_time (rpt); break; - case 0x42: rpt_single_ECEF_position (rpt); break; - case 0x43: rpt_single_ECEF_velocity (rpt); break; - case 0x45: rpt_SW_version (rpt); break; - case 0x46: rpt_rcvr_health (rpt); break; - case 0x47: rpt_SNR_all_SVs (rpt); break; - case 0x48: rpt_GPS_system_message (rpt); break; - case 0x49: rpt_almanac_health_page (rpt); break; - case 0x4A: switch (rpt->len) { - /* - ** special case (=slip-up) in the TSIP protocol; - ** parsing method depends on length - */ - case 20: rpt_single_lla_position (rpt); break; - case 9: rpt_ref_alt (rpt); break; + { + case 0x3D: rpt_chan_A_config (rpt); break; + case 0x40: rpt_almanac_data_page (rpt); break; + case 0x41: rpt_GPS_time (rpt); break; + case 0x42: rpt_single_ECEF_position (rpt); break; + case 0x43: rpt_single_ECEF_velocity (rpt); break; + case 0x45: rpt_SW_version (rpt); break; + case 0x46: rpt_rcvr_health (rpt); break; + case 0x47: rpt_SNR_all_SVs (rpt); break; + case 0x48: rpt_GPS_system_message (rpt); break; + case 0x49: rpt_almanac_health_page (rpt); break; + case 0x4A: switch (rpt->len) { + /* + ** special case (=slip-up) in the TSIP protocol; + ** parsing method depends on length + */ + case 20: rpt_single_lla_position (rpt); break; + case 9: rpt_ref_alt (rpt); break; } break; - case 0x4B: rpt_rcvr_id_and_status (rpt);break; - case 0x4C: rpt_operating_parameters (rpt); break; - case 0x4D: rpt_oscillator_offset (rpt); break; - case 0x4E: rpt_GPS_time_set_response (rpt); break; - case 0x4F: rpt_UTC_offset (rpt); break; - case 0x54: rpt_1SV_bias (rpt); break; - case 0x55: rpt_io_opt (rpt); break; - case 0x56: rpt_ENU_velocity (rpt); break; - case 0x57: rpt_last_fix_info (rpt); break; - case 0x58: rpt_GPS_system_data (rpt); break; - case 0x59: rpt_SVs_enabled (rpt); break; - case 0x5A: rpt_raw_msmt (rpt); break; - case 0x5B: rpt_SV_ephemeris_status (rpt); break; - case 0x5C: rpt_SV_tracking_status (rpt); break; - case 0x6D: rpt_allSV_selection (rpt); break; - case 0x82: rpt_DGPS_position_mode (rpt); break; - case 0x83: rpt_double_ECEF_position (rpt); break; - case 0x84: rpt_double_lla_position (rpt); break; - case 0xBB: rpt_complete_rcvr_config (rpt); break; - case 0xBC: rpt_rcvr_serial_port_config (rpt); break; - - case 0x8F: switch (rpt->buf[0]) - { - /* superpackets; parsed according to subcodes */ - case 0x0B: rpt_8F0B(rpt); break; - case 0x14: rpt_8F14(rpt); break; - case 0x15: rpt_8F15(rpt); break; - case 0x20: rpt_8F20(rpt); break; - case 0x41: rpt_8F41(rpt); break; - case 0x42: rpt_8F42(rpt); break; - case 0x45: rpt_8F45(rpt); break; - case 0x4A: rpt_8F4A(rpt); break; - case 0x4B: rpt_8F4B(rpt); break; - case 0x4D: rpt_8F4D(rpt); break; - case 0xA5: rpt_8FA5(rpt); break; - case 0xAD: rpt_8FAD(rpt); break; - default: parsed = BADID_PARSE; break; + case 0x4B: rpt_rcvr_id_and_status (rpt);break; + case 0x4C: rpt_operating_parameters (rpt); break; + case 0x4D: rpt_oscillator_offset (rpt); break; + case 0x4E: rpt_GPS_time_set_response (rpt); break; + case 0x4F: rpt_UTC_offset (rpt); break; + case 0x54: rpt_1SV_bias (rpt); break; + case 0x55: rpt_io_opt (rpt); break; + case 0x56: rpt_ENU_velocity (rpt); break; + case 0x57: rpt_last_fix_info (rpt); break; + case 0x58: rpt_GPS_system_data (rpt); break; + case 0x59: rpt_SVs_enabled (rpt); break; + case 0x5A: rpt_raw_msmt (rpt); break; + case 0x5B: rpt_SV_ephemeris_status (rpt); break; + case 0x5C: rpt_SV_tracking_status (rpt); break; + case 0x6D: rpt_allSV_selection (rpt); break; + case 0x82: rpt_DGPS_position_mode (rpt); break; + case 0x83: rpt_double_ECEF_position (rpt); break; + case 0x84: rpt_double_lla_position (rpt); break; + case 0xBB: rpt_complete_rcvr_config (rpt); break; + case 0xBC: rpt_rcvr_serial_port_config (rpt); break; + + case 0x8F: switch (rpt->buf[0]) + { + /* superpackets; parsed according to subcodes */ + case 0x0B: rpt_8F0B(rpt); break; + case 0x14: rpt_8F14(rpt); break; + case 0x15: rpt_8F15(rpt); break; + case 0x20: rpt_8F20(rpt); break; + case 0x41: rpt_8F41(rpt); break; + case 0x42: rpt_8F42(rpt); break; + case 0x45: rpt_8F45(rpt); break; + case 0x4A: rpt_8F4A(rpt); break; + case 0x4B: rpt_8F4B(rpt); break; + case 0x4D: rpt_8F4D(rpt); break; + case 0xA5: rpt_8FA5(rpt); break; + case 0xAD: rpt_8FAD(rpt); break; + default: parsed = BADID_PARSE; break; } break; - default: parsed = BADID_PARSE; break; + default: parsed = BADID_PARSE; break; } if (parsed != GOOD_PARSE) { - /* - **The message has TSIP structure (DLEs, etc.) - ** but could not be parsed by above routines - */ + /* + **The message has TSIP structure (DLEs, etc.) + ** but could not be parsed by above routines + */ unknown_rpt (rpt); } - /* close TextOutputBuffer */ - pbuf = '\0'; + /* close TextOutputBuffer */ + pbuf = '\0'; } #endif /* TRIMBLE_OUTPUT_FUNC */ diff --git a/contrib/ntp/ntpd/refclock_shm.c b/contrib/ntp/ntpd/refclock_shm.c index 7be263d1b..6ab5d0267 100644 --- a/contrib/ntp/ntpd/refclock_shm.c +++ b/contrib/ntp/ntpd/refclock_shm.c @@ -1,5 +1,5 @@ /* - * refclock_shm - clock driver for utc via shared memory + * refclock_shm - clock driver for utc via shared memory * - under construction - * To add new modes: Extend or union the shmTime-struct. Do not * extend/shrink size, because otherwise existing implementations @@ -11,21 +11,24 @@ # include #endif +#include "ntp_types.h" + #if defined(REFCLOCK) && defined(CLOCK_SHM) #include "ntpd.h" -#undef fileno +#undef fileno #include "ntp_io.h" -#undef fileno +#undef fileno #include "ntp_refclock.h" -#undef fileno -#include "ntp_unixtime.h" -#undef fileno +#undef fileno +#include "timespecops.h" +#undef fileno #include "ntp_stdlib.h" +#include "ntp_assert.h" -#undef fileno +#undef fileno #include -#undef fileno +#undef fileno #ifndef SYS_WINNT # include @@ -35,9 +38,13 @@ # include #endif +#ifdef HAVE_STDATOMIC_H +# include +#endif /* HAVE_STDATOMIC_H */ + /* * This driver supports a reference clock attached thru shared memory - */ + */ /* * SHM interface definitions @@ -48,12 +55,21 @@ #define NSAMPLES 3 /* stages of median filter */ +/* + * Mode flags + */ +#define SHM_MODE_PRIVATE 0x0001 + /* * Function prototypes */ -static int shm_start (int, struct peer *); -static void shm_shutdown (int, struct peer *); -static void shm_poll (int unit, struct peer *); +static int shm_start (int unit, struct peer *peer); +static void shm_shutdown (int unit, struct peer *peer); +static void shm_poll (int unit, struct peer *peer); +static void shm_timer (int unit, struct peer *peer); +static void shm_clockstats (int unit, struct peer *peer); +static void shm_control (int unit, const struct refclockstat * in_st, + struct refclockstat * out_st, struct peer *peer); /* * Transfer vector @@ -61,98 +77,138 @@ static void shm_poll (int unit, struct peer *); struct refclock refclock_shm = { shm_start, /* start up driver */ shm_shutdown, /* shut down driver */ - shm_poll, /* transmit poll message */ - noentry, /* not used */ - noentry, /* initialize driver (not used) */ - noentry, /* not used */ - NOFLAGS /* not used */ + shm_poll, /* transmit poll message */ + shm_control, /* control settings */ + noentry, /* not used: init */ + noentry, /* not used: buginfo */ + shm_timer, /* once per second */ }; + struct shmTime { - int mode; /* 0 - if valid set - * use values, + int mode; /* 0 - if valid is set: + * use values, * clear valid - * 1 - if valid set + * 1 - if valid is set: * if count before and after read of values is equal, - * use values + * use values * clear valid */ - int count; - time_t clockTimeStampSec; - int clockTimeStampUSec; - time_t receiveTimeStampSec; - int receiveTimeStampUSec; - int leap; - int precision; - int nsamples; - int valid; - int dummy[10]; + volatile int count; + time_t clockTimeStampSec; + int clockTimeStampUSec; + time_t receiveTimeStampSec; + int receiveTimeStampUSec; + int leap; + int precision; + int nsamples; + volatile int valid; + unsigned clockTimeStampNSec; /* Unsigned ns timestamps */ + unsigned receiveTimeStampNSec; /* Unsigned ns timestamps */ + int dummy[8]; }; -struct shmTime *getShmTime(int); +struct shmunit { + struct shmTime *shm; /* pointer to shared memory segment */ + int forall; /* access for all UIDs? */ + + /* debugging/monitoring counters - reset when printed */ + int ticks; /* number of attempts to read data*/ + int good; /* number of valid samples */ + int notready; /* number of peeks without data ready */ + int bad; /* number of invalid samples */ + int clash; /* number of access clashes while reading */ + + time_t max_delta; /* difference limit */ + time_t max_delay; /* age/stale limit */ +}; + + +static struct shmTime* +getShmTime( + int unit, + int/*BOOL*/ forall + ) +{ + struct shmTime *p = NULL; -struct shmTime *getShmTime (int unit) { #ifndef SYS_WINNT - int shmid=0; - assert (unit<10); /* MAXUNIT is 4, so should never happen */ - shmid=shmget (0x4e545030+unit, sizeof (struct shmTime), - IPC_CREAT|(unit<2?0700:0777)); - if (shmid==-1) { /*error */ - msyslog(LOG_ERR,"SHM shmget (unit %d): %s",unit,strerror(errno)); - return 0; + int shmid; + + /* 0x4e545030 is NTP0. + * Big units will give non-ascii but that's OK + * as long as everybody does it the same way. + */ + shmid=shmget(0x4e545030 + unit, sizeof (struct shmTime), + IPC_CREAT | (forall ? 0666 : 0600)); + if (shmid == -1) { /* error */ + msyslog(LOG_ERR, "SHM shmget (unit %d): %m", unit); + return NULL; } - else { /* no error */ - struct shmTime *p=(struct shmTime *)shmat (shmid, 0, 0); - if ((int)(long)p==-1) { /* error */ - msyslog(LOG_ERR,"SHM shmat (unit %d): %s",unit,strerror(errno)); - return 0; - } - return p; + p = (struct shmTime *)shmat (shmid, 0, 0); + if (p == (struct shmTime *)-1) { /* error */ + msyslog(LOG_ERR, "SHM shmat (unit %d): %m", unit); + return NULL; } + + return p; #else - char buf[10]; - LPSECURITY_ATTRIBUTES psec=0; - HANDLE shmid=0; + + static const char * nspref[2] = { "Local", "Global" }; + char buf[20]; + LPSECURITY_ATTRIBUTES psec = 0; + HANDLE shmid = 0; SECURITY_DESCRIPTOR sd; SECURITY_ATTRIBUTES sa; - sprintf (buf,"NTP%d",unit); - if (unit>=2) { /* world access */ + unsigned int numch; + + numch = snprintf(buf, sizeof(buf), "%s\\NTP%d", + nspref[forall != 0], (unit & 0xFF)); + if (numch >= sizeof(buf)) { + msyslog(LOG_ERR, "SHM name too long (unit %d)", unit); + return NULL; + } + if (forall) { /* world access */ if (!InitializeSecurityDescriptor(&sd, SECURITY_DESCRIPTOR_REVISION)) { - msyslog(LOG_ERR,"SHM InitializeSecurityDescriptor (unit %d): %m",unit); - return 0; + msyslog(LOG_ERR,"SHM InitializeSecurityDescriptor (unit %d): %m", unit); + return NULL; } - if (!SetSecurityDescriptorDacl(&sd,1,0,0)) { - msyslog(LOG_ERR,"SHM SetSecurityDescriptorDacl (unit %d): %m",unit); - return 0; + if (!SetSecurityDescriptorDacl(&sd, TRUE, NULL, FALSE)) { + msyslog(LOG_ERR, "SHM SetSecurityDescriptorDacl (unit %d): %m", unit); + return NULL; } - sa.nLength=sizeof (SECURITY_ATTRIBUTES); - sa.lpSecurityDescriptor=&sd; - sa.bInheritHandle=0; - psec=&sa; + sa.nLength = sizeof(SECURITY_ATTRIBUTES); + sa.lpSecurityDescriptor = &sd; + sa.bInheritHandle = FALSE; + psec = &sa; } - shmid=CreateFileMapping ((HANDLE)0xffffffff, psec, PAGE_READWRITE, - 0, sizeof (struct shmTime),buf); - if (!shmid) { /*error*/ - char buf[1000]; + shmid = CreateFileMapping ((HANDLE)0xffffffff, psec, PAGE_READWRITE, + 0, sizeof (struct shmTime), buf); + if (shmid == NULL) { /*error*/ + char buf[1000]; FormatMessage (FORMAT_MESSAGE_FROM_SYSTEM, 0, GetLastError (), 0, buf, sizeof (buf), 0); - msyslog(LOG_ERR,"SHM CreateFileMapping (unit %d): %s",unit,buf); - return 0; + msyslog(LOG_ERR, "SHM CreateFileMapping (unit %d): %s", unit, buf); + return NULL; } - else { - struct shmTime *p=(struct shmTime *) MapViewOfFile (shmid, - FILE_MAP_WRITE, 0, 0, sizeof (struct shmTime)); - if (p==0) { /*error*/ - char buf[1000]; - FormatMessage (FORMAT_MESSAGE_FROM_SYSTEM, - 0, GetLastError (), 0, buf, sizeof (buf), 0); - msyslog(LOG_ERR,"SHM MapViewOfFile (unit %d): %s",unit,buf); - return 0; - } - return p; + p = (struct shmTime *)MapViewOfFile(shmid, FILE_MAP_WRITE, 0, 0, + sizeof (struct shmTime)); + if (p == NULL) { /*error*/ + char buf[1000]; + FormatMessage (FORMAT_MESSAGE_FROM_SYSTEM, + 0, GetLastError (), 0, buf, sizeof (buf), 0); + msyslog(LOG_ERR,"SHM MapViewOfFile (unit %d): %s", unit, buf); + return NULL; } + + return p; #endif + + /* NOTREACHED */ + ENSURE(!"getShmTime(): Not reached."); } + + /* * shm_start - attach to shared memory */ @@ -162,32 +218,73 @@ shm_start( struct peer *peer ) { - struct refclockproc *pp; - pp = peer->procptr; + struct refclockproc * const pp = peer->procptr; + struct shmunit * const up = emalloc_zero(sizeof(*up)); + pp->io.clock_recv = noentry; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = -1; - pp->unitptr = (caddr_t)getShmTime(unit); + + up->forall = (unit >= 2) && !(peer->ttl & SHM_MODE_PRIVATE); + + up->shm = getShmTime(unit, up->forall); /* * Initialize miscellaneous peer variables */ memcpy((char *)&pp->refid, REFID, 4); - if (pp->unitptr!=0) { - ((struct shmTime*)pp->unitptr)->precision=PRECISION; - peer->precision = ((struct shmTime*)pp->unitptr)->precision; - ((struct shmTime*)pp->unitptr)->valid=0; - ((struct shmTime*)pp->unitptr)->nsamples=NSAMPLES; + if (up->shm != 0) { + pp->unitptr = up; + up->shm->precision = PRECISION; + peer->precision = up->shm->precision; + up->shm->valid = 0; + up->shm->nsamples = NSAMPLES; pp->clockdesc = DESCRIPTION; - return (1); - } - else { + /* items to be changed later in 'shm_control()': */ + up->max_delay = 5; + up->max_delta = 4*3600; + return 1; + } else { + free(up); + pp->unitptr = NULL; return 0; } } +/* + * shm_control - configure flag1/time2 params + * + * These are not yet available during 'shm_start', so we have to do any + * pre-computations we want to avoid during regular poll/timer callbacks + * in this callback. + */ +static void +shm_control( + int unit, + const struct refclockstat * in_st, + struct refclockstat * out_st, + struct peer * peer + ) +{ + struct refclockproc * const pp = peer->procptr; + struct shmunit * const up = pp->unitptr; + + UNUSED_ARG(unit); + UNUSED_ARG(in_st); + UNUSED_ARG(out_st); + if (NULL == up) + return; + if (pp->sloppyclockflag & CLK_FLAG1) + up->max_delta = 0; + else if (pp->fudgetime2 < 1. || pp->fudgetime2 > 86400.) + up->max_delta = 4*3600; + else + up->max_delta = (time_t)floor(pp->fudgetime2 + 0.5); +} + + /* * shm_shutdown - shut down the clock */ @@ -197,17 +294,23 @@ shm_shutdown( struct peer *peer ) { - register struct shmTime *up; - struct refclockproc *pp; + struct refclockproc * const pp = peer->procptr; + struct shmunit * const up = pp->unitptr; - pp = peer->procptr; - up = (struct shmTime *)pp->unitptr; + UNUSED_ARG(unit); + if (NULL == up) + return; #ifndef SYS_WINNT - /* HMS: shmdt()wants char* or const void * */ - (void) shmdt (up); + + /* HMS: shmdt() wants char* or const void * */ + (void)shmdt((char *)up->shm); + #else - UnmapViewOfFile (up); + + UnmapViewOfFile(up->shm); + #endif + free(up); } @@ -220,93 +323,340 @@ shm_poll( struct peer *peer ) { - register struct shmTime *up; - struct refclockproc *pp; + struct refclockproc * const pp = peer->procptr; + struct shmunit * const up = pp->unitptr; + int major_error; - /* - * This is the main routine. It snatches the time from the shm - * board and tacks on a local timestamp. - */ - pp = peer->procptr; - up = (struct shmTime*)pp->unitptr; - if (up==0) { /* try to map again - this may succeed if meanwhile some- - body has ipcrm'ed the old (unaccessible) shared mem - segment */ - pp->unitptr = (caddr_t)getShmTime(unit); - up = (struct shmTime*)pp->unitptr; - } - if (up==0) { + pp->polls++; + + /* get dominant reason if we have no samples at all */ + major_error = max(up->notready, up->bad); + major_error = max(major_error, up->clash); + + /* + * Process median filter samples. If none received, see what + * happened, tell the core and keep going. + */ + if (pp->coderecv != pp->codeproc) { + /* have some samples, everything OK */ + pp->lastref = pp->lastrec; + refclock_receive(peer); + } else if (NULL == up->shm) { /* is this possible at all? */ + /* we're out of business without SHM access */ refclock_report(peer, CEVNT_FAULT); - return; + } else if (major_error == up->clash) { + /* too many collisions is like a bad signal */ + refclock_report(peer, CEVNT_PROP); + } else if (major_error == up->bad) { + /* too much stale/bad/garbled data */ + refclock_report(peer, CEVNT_BADREPLY); + } else { + /* in any other case assume it's just a timeout */ + refclock_report(peer, CEVNT_TIMEOUT); + } + /* shm_clockstats() clears the tallies, so it must be last... */ + shm_clockstats(unit, peer); +} + + +enum segstat_t { + OK, NO_SEGMENT, NOT_READY, BAD_MODE, CLASH +}; + +struct shm_stat_t { + int status; + int mode; + struct timespec tvc, tvr, tvt; + int precision; + int leap; +}; + +static inline void memory_barrier(void) +{ +#ifdef HAVE_ATOMIC_THREAD_FENCE + atomic_thread_fence(memory_order_seq_cst); +#endif /* HAVE_ATOMIC_THREAD_FENCE */ +} + +static enum segstat_t shm_query(volatile struct shmTime *shm_in, struct shm_stat_t *shm_stat) +/* try to grab a sample from the specified SHM segment */ +{ + volatile struct shmTime shmcopy, *shm = shm_in; + volatile int cnt; + + unsigned int cns_new, rns_new; + + /* + * This is the main routine. It snatches the time from the shm + * board and tacks on a local timestamp. + */ + if (shm == NULL) { + shm_stat->status = NO_SEGMENT; + return NO_SEGMENT; + } + + /*@-type@*//* splint is confused about struct timespec */ + shm_stat->tvc.tv_sec = shm_stat->tvc.tv_nsec = 0; + { + time_t now; + + time(&now); + shm_stat->tvc.tv_sec = now; + } + + /* relying on word access to be atomic here */ + if (shm->valid == 0) { + shm_stat->status = NOT_READY; + return NOT_READY; + } + + cnt = shm->count; + + /* + * This is proof against concurrency issues if either + * (a) the memory_barrier() call works on this host, or + * (b) memset compiles to an uninterruptible single-instruction bitblt. + */ + memory_barrier(); + memcpy((void *)&shmcopy, (void *)shm, sizeof(struct shmTime)); + shm->valid = 0; + memory_barrier(); + + /* + * Clash detection in case neither (a) nor (b) was true. + * Not supported in mode 0, and word access to the count field + * must be atomic for this to work. + */ + if (shmcopy.mode > 0 && cnt != shm->count) { + shm_stat->status = CLASH; + return shm_stat->status; + } + + shm_stat->status = OK; + shm_stat->mode = shmcopy.mode; + + switch (shmcopy.mode) { + case 0: + shm_stat->tvr.tv_sec = shmcopy.receiveTimeStampSec; + shm_stat->tvr.tv_nsec = shmcopy.receiveTimeStampUSec * 1000; + rns_new = shmcopy.receiveTimeStampNSec; + shm_stat->tvt.tv_sec = shmcopy.clockTimeStampSec; + shm_stat->tvt.tv_nsec = shmcopy.clockTimeStampUSec * 1000; + cns_new = shmcopy.clockTimeStampNSec; + + /* Since the following comparisons are between unsigned + ** variables they are always well defined, and any + ** (signed) underflow will turn into very large unsigned + ** values, well above the 1000 cutoff. + ** + ** Note: The usecs *must* be a *truncated* + ** representation of the nsecs. This code will fail for + ** *rounded* usecs, and the logic to deal with + ** wrap-arounds in the presence of rounded values is + ** much more convoluted. + */ + if ( ((cns_new - (unsigned)shm_stat->tvt.tv_nsec) < 1000) + && ((rns_new - (unsigned)shm_stat->tvr.tv_nsec) < 1000)) { + shm_stat->tvt.tv_nsec = cns_new; + shm_stat->tvr.tv_nsec = rns_new; } - if (up->valid) { - struct timeval tvr; - struct timeval tvt; - struct tm *t; - int ok=1; - tvr.tv_sec = 0; - tvr.tv_usec = 0; - tvt.tv_sec = 0; - tvt.tv_usec = 0; - switch (up->mode) { - case 0: { - tvr.tv_sec=up->receiveTimeStampSec; - tvr.tv_usec=up->receiveTimeStampUSec; - tvt.tv_sec=up->clockTimeStampSec; - tvt.tv_usec=up->clockTimeStampUSec; - } - break; - case 1: { - int cnt=up->count; - tvr.tv_sec=up->receiveTimeStampSec; - tvr.tv_usec=up->receiveTimeStampUSec; - tvt.tv_sec=up->clockTimeStampSec; - tvt.tv_usec=up->clockTimeStampUSec; - ok=(cnt==up->count); - } - break; - default: - msyslog (LOG_ERR, "SHM: bad mode found in shared memory: %d",up->mode); - } - up->valid=0; - if (ok) { - time_t help; /* XXX NetBSD has incompatible tv_sec */ - - TVTOTS(&tvr,&pp->lastrec); - pp->lastrec.l_ui += JAN_1970; - /* pp->lasttime = current_time; */ - pp->polls++; - help = tvt.tv_sec; - t = gmtime (&help); - pp->day=t->tm_yday+1; - pp->hour=t->tm_hour; - pp->minute=t->tm_min; - pp->second=t->tm_sec; - pp->nsec=tvt.tv_usec * 1000; - peer->precision=up->precision; - pp->leap=up->leap; - } - else { - refclock_report(peer, CEVNT_FAULT); - msyslog (LOG_NOTICE, "SHM: access clash in shared memory"); + /* At this point shm_stat->tvr and shm_stat->tvt contain valid ns-level + ** timestamps, possibly generated by extending the old + ** us-level timestamps + */ + break; + + case 1: + + shm_stat->tvr.tv_sec = shmcopy.receiveTimeStampSec; + shm_stat->tvr.tv_nsec = shmcopy.receiveTimeStampUSec * 1000; + rns_new = shmcopy.receiveTimeStampNSec; + shm_stat->tvt.tv_sec = shmcopy.clockTimeStampSec; + shm_stat->tvt.tv_nsec = shmcopy.clockTimeStampUSec * 1000; + cns_new = shmcopy.clockTimeStampNSec; + + /* See the case above for an explanation of the + ** following test. + */ + if ( ((cns_new - (unsigned)shm_stat->tvt.tv_nsec) < 1000) + && ((rns_new - (unsigned)shm_stat->tvr.tv_nsec) < 1000)) { + shm_stat->tvt.tv_nsec = cns_new; + shm_stat->tvr.tv_nsec = rns_new; + } + /* At this point shm_stat->tvr and shm_stat->tvt contains valid ns-level + ** timestamps, possibly generated by extending the old + ** us-level timestamps + */ + break; + + default: + shm_stat->status = BAD_MODE; + break; + } + /*@-type@*/ + + /* + * leap field is not a leap offset but a leap notification code. + * The values are magic numbers used by NTP and set by GPSD, if at all, in + * the subframe code. + */ + shm_stat->leap = shmcopy.leap; + shm_stat->precision = shmcopy.precision; + + return shm_stat->status; +} + +/* + * shm_timer - called once every second. + * + * This tries to grab a sample from the SHM segment, filtering bad ones + */ +static void +shm_timer( + int unit, + struct peer *peer + ) +{ + struct refclockproc * const pp = peer->procptr; + struct shmunit * const up = pp->unitptr; + + volatile struct shmTime *shm; + + l_fp tsrcv; + l_fp tsref; + int c; + + /* for formatting 'a_lastcode': */ + struct calendar cd; + time_t tt; + vint64 ts; + + enum segstat_t status; + struct shm_stat_t shm_stat; + + up->ticks++; + if ((shm = up->shm) == NULL) { + /* try to map again - this may succeed if meanwhile some- + body has ipcrm'ed the old (unaccessible) shared mem segment */ + shm = up->shm = getShmTime(unit, up->forall); + if (shm == NULL) { + DPRINTF(1, ("%s: no SHM segment\n", + refnumtoa(&peer->srcadr))); return; } } - else { - refclock_report(peer, CEVNT_TIMEOUT); - /* - msyslog (LOG_NOTICE, "SHM: no new value found in shared memory"); - */ + + /* query the segment, atomically */ + status = shm_query(shm, &shm_stat); + + switch (status) { + case OK: + DPRINTF(2, ("%s: SHM type %d sample\n", + refnumtoa(&peer->srcadr), shm_stat.mode)); + break; + case NO_SEGMENT: + /* should never happen, but is harmless */ + return; + case NOT_READY: + DPRINTF(1, ("%s: SHM not ready\n",refnumtoa(&peer->srcadr))); + up->notready++; + return; + case BAD_MODE: + DPRINTF(1, ("%s: SHM type blooper, mode=%d\n", + refnumtoa(&peer->srcadr), shm->mode)); + up->bad++; + msyslog (LOG_ERR, "SHM: bad mode found in shared memory: %d", + shm->mode); + return; + case CLASH: + DPRINTF(1, ("%s: type 1 access clash\n", + refnumtoa(&peer->srcadr))); + msyslog (LOG_NOTICE, "SHM: access clash in shared memory"); + up->clash++; + return; + default: + DPRINTF(1, ("%s: internal error, unknown SHM fetch status\n", + refnumtoa(&peer->srcadr))); + msyslog (LOG_NOTICE, "internal error, unknown SHM fetch status"); + up->bad++; + return; + } + + + /* format the last time code in human-readable form into + * 'pp->a_lastcode'. Someone claimed: "NetBSD has incompatible + * tv_sec". I can't find a base for this claim, but we can work + * around that potential problem. BTW, simply casting a pointer + * is a receipe for disaster on some architectures. + */ + tt = (time_t)shm_stat.tvt.tv_sec; + ts = time_to_vint64(&tt); + ntpcal_time_to_date(&cd, &ts); + + /* add ntpq -c cv timecode in ISO 8601 format */ + c = snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%04u-%02u-%02uT%02u:%02u:%02u.%09ldZ", + cd.year, cd.month, cd.monthday, + cd.hour, cd.minute, cd.second, + (long)shm_stat.tvt.tv_nsec); + pp->lencode = (c < sizeof(pp->a_lastcode)) ? c : 0; + + /* check 1: age control of local time stamp */ + tt = shm_stat.tvc.tv_sec - shm_stat.tvr.tv_sec; + if (tt < 0 || tt > up->max_delay) { + DPRINTF(1, ("%s:SHM stale/bad receive time, delay=%llds\n", + refnumtoa(&peer->srcadr), (long long)tt)); + up->bad++; + msyslog (LOG_ERR, "SHM: stale/bad receive time, delay=%llds", + (long long)tt); return; } - if (!refclock_process(pp)) { - refclock_report(peer, CEVNT_BADTIME); + + /* check 2: delta check */ + tt = shm_stat.tvr.tv_sec - shm_stat.tvt.tv_sec - (shm_stat.tvr.tv_nsec < shm_stat.tvt.tv_nsec); + if (tt < 0) + tt = -tt; + if (up->max_delta > 0 && tt > up->max_delta) { + DPRINTF(1, ("%s: SHM diff limit exceeded, delta=%llds\n", + refnumtoa(&peer->srcadr), (long long)tt)); + up->bad++; + msyslog (LOG_ERR, "SHM: difference limit exceeded, delta=%llds\n", + (long long)tt); return; } - pp->lastref = pp->lastrec; - refclock_receive(peer); + + /* if we really made it to this point... we're winners! */ + DPRINTF(2, ("%s: SHM feeding data\n", + refnumtoa(&peer->srcadr))); + tsrcv = tspec_stamp_to_lfp(shm_stat.tvr); + tsref = tspec_stamp_to_lfp(shm_stat.tvt); + pp->leap = shm_stat.leap; + peer->precision = shm_stat.precision; + refclock_process_offset(pp, tsref, tsrcv, pp->fudgetime1); + up->good++; +} + +/* + * shm_clockstats - dump and reset counters + */ +static void shm_clockstats( + int unit, + struct peer *peer + ) +{ + struct refclockproc * const pp = peer->procptr; + struct shmunit * const up = pp->unitptr; + + UNUSED_ARG(unit); + if (pp->sloppyclockflag & CLK_FLAG4) { + mprintf_clock_stats( + &peer->srcadr, "%3d %3d %3d %3d %3d", + up->ticks, up->good, up->notready, + up->bad, up->clash); + } + up->ticks = up->good = up->notready = up->bad = up->clash = 0; } #else -int refclock_shm_bs; +NONEMPTY_TRANSLATION_UNIT #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_tpro.c b/contrib/ntp/ntpd/refclock_tpro.c index 3c425684e..ac511bb4b 100644 --- a/contrib/ntp/ntpd/refclock_tpro.c +++ b/contrib/ntp/ntpd/refclock_tpro.c @@ -42,9 +42,9 @@ struct tprounit { /* * Function prototypes */ -static int tpro_start P((int, struct peer *)); -static void tpro_shutdown P((int, struct peer *)); -static void tpro_poll P((int unit, struct peer *)); +static int tpro_start (int, struct peer *); +static void tpro_shutdown (int, struct peer *); +static void tpro_poll (int unit, struct peer *); /* * Transfer vector @@ -77,7 +77,7 @@ tpro_start( /* * Open TPRO device */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = open(device, O_RDONLY | O_NDELAY, 0777); if (fd == -1) { msyslog(LOG_ERR, "tpro_start: open of %s: %m", device); @@ -87,23 +87,18 @@ tpro_start( /* * Allocate and initialize unit structure */ - if (!(up = (struct tprounit *) emalloc(sizeof(struct tprounit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct tprounit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = noentry; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous peer variables */ peer->precision = PRECISION; - peer->burst = NSTAGE; pp->clockdesc = DESCRIPTION; memcpy((char *)&pp->refid, REFID, 4); return (1); @@ -123,9 +118,10 @@ tpro_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct tprounit *)pp->unitptr; + up = pp->unitptr; io_closeclock(&pp->io); - free(up); + if (NULL != up) + free(up); } @@ -147,7 +143,7 @@ tpro_poll( * board and tacks on a local timestamp. */ pp = peer->procptr; - up = (struct tprounit *)pp->unitptr; + up = pp->unitptr; tp = &up->tprodata; if (read(pp->io.fd, (char *)tp, sizeof(struct tproval)) < 0) { @@ -163,20 +159,20 @@ tpro_poll( * proper format, we declare bad format and exit. Note: we * can't use the sec/usec conversion produced by the driver, * since the year may be suspect. All format error checking is - * done by the sprintf() and sscanf() routines. + * done by the snprintf() and sscanf() routines. * * Note that the refclockproc usec member has now become nsec. * We could either multiply the read-in usec value by 1000 or * we could pad the written string appropriately and read the * resulting value in already scaled. */ - sprintf(pp->a_lastcode, - "%1x%1x%1x %1x%1x:%1x%1x:%1x%1x.%1x%1x%1x%1x%1x%1x %1x", - tp->day100, tp->day10, tp->day1, tp->hour10, tp->hour1, - tp->min10, tp->min1, tp->sec10, tp->sec1, tp->ms100, - tp->ms10, tp->ms1, tp->usec100, tp->usec10, tp->usec1, - tp->status); - pp->lencode = strlen(pp->a_lastcode); + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), + "%1x%1x%1x %1x%1x:%1x%1x:%1x%1x.%1x%1x%1x%1x%1x%1x %1x", + tp->day100, tp->day10, tp->day1, tp->hour10, tp->hour1, + tp->min10, tp->min1, tp->sec10, tp->sec1, tp->ms100, + tp->ms10, tp->ms1, tp->usec100, tp->usec10, tp->usec1, + tp->status); + pp->lencode = strlen(pp->a_lastcode); #ifdef DEBUG if (debug) printf("tpro: time %s timecode %d %s\n", @@ -198,17 +194,13 @@ tpro_poll( refclock_report(peer, CEVNT_BADTIME); return; } - if (peer->burst > 0) - return; if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; } - refclock_receive(peer); pp->lastref = pp->lastrec; record_clock_stats(&peer->srcadr, pp->a_lastcode); refclock_receive(peer); - peer->burst = NSTAGE; } #else diff --git a/contrib/ntp/ntpd/refclock_trak.c b/contrib/ntp/ntpd/refclock_trak.c deleted file mode 100644 index 3a4a54e65..000000000 --- a/contrib/ntp/ntpd/refclock_trak.c +++ /dev/null @@ -1,359 +0,0 @@ -/* - * refclock_trak - clock driver for the TRAK 8810 GPS Station Clock - * - * Tomoaki TSURUOKA - * original version Dec, 1993 - * revised version Sep, 1994 for ntp3.4e or later - */ - -#ifdef HAVE_CONFIG_H -#include -#endif - -#if defined(REFCLOCK) && defined(CLOCK_TRAK) && defined(PPS) - -#include "ntpd.h" -#include "ntp_io.h" -#include "ntp_refclock.h" -#include "ntp_stdlib.h" -#include "ntp_unixtime.h" - -#include -#include - -#ifdef HAVE_SYS_TERMIOS_H -# include -#endif -#ifdef HAVE_SYS_PPSCLOCK_H -# include -#endif - -/* - * This driver supports the TRAK 8810/8820 GPS Station Clock. The claimed - * accuracy at the 1-pps output is 200-300 ns relative to the broadcast - * signal; however, in most cases the actual accuracy is limited by the - * precision of the timecode and the latencies of the serial interface - * and operating system. - * - * For best accuracy, this radio requires the LDISC_ACTS line - * discipline, which captures a timestamp at the '*' on-time character - * of the timecode. Using this discipline the jitter is in the order of - * 1 ms and systematic error about 0.5 ms. If unavailable, the buffer - * timestamp is used, which is captured at the \r ending the timecode - * message. This introduces a systematic error of 23 character times, or - * about 24 ms at 9600 bps, together with a jitter well over 8 ms on Sun - * IPC-class machines. - * - * Using the memus, the radio should be set for 9600 bps, one stop bit - * and no parity. It should be set to operate in computer (no echo) - * mode. The timecode format includes neither the year nor leap-second - * warning. No provisions are included in this preliminary version of - * the driver to read and record detailed internal radio status. - * - * In operation, this driver sends a RQTS\r request to the radio at - * initialization in order to put it in continuous time output mode. The - * radio then sends the following message once each second: - * - * *RQTS U,ddd:hh:mm:ss.0,q - * - * on-time = '*' * ddd = day of year - * hh:mm:ss = hours, minutes, seconds - * q = quality indicator (phase error), 0-6: - * 0 > 20 us - * 6 > 10 us - * 5 > 1 us - * 4 > 100 ns - * 3 > 10 ns - * 2 < 10 ns - * - * The alarm condition is indicated by '0' at Q, which means the radio - * has a phase error than 20 usec relative to the broadcast time. The - * absence of year, DST and leap-second warning in this format is also - * alarming. - * - * The continuous time mode is disabled using the RQTX request, - * following which the radio sends a RQTX DONE response. In the - * normal mode, other control and status requests are effective, - * including the leap-second status request RQLS. The radio responds - * wtih RQLS yy,mm,dd, where yy,mm,dd are the year, month and - * day. Presumably, this gives the epoch of the next leap second, - * RQLS 00,00,00 if none is specified in the GPS message. Specified in - * this form, the information is generally useless and is ignored by - * the driver. - * - * Fudge Factors - * - * There are no special fudge factors other than the generic. - */ - -/* - * Interface definitions - */ -#define DEVICE "/dev/trak%d" /* device name and unit */ -#define SPEED232 B9600 /* uart speed (9600 baud) */ -#define PRECISION (-20) /* precision assumed (about 1 us) */ -#define REFID "GPS\0" /* reference ID */ -#define DESCRIPTION "TRACK 8810/8820 Station Clock" /* WRU */ - -#define LENTRAK 24 /* timecode length */ -#define C_CTO "RQTS\r" /* start continuous time output */ - -/* - * Unit control structure - */ -struct trakunit { - int polled; /* poll message flag */ - l_fp tstamp; /* timestamp of last poll */ -}; - -/* - * Function prototypes - */ -static int trak_start P((int, struct peer *)); -static void trak_shutdown P((int, struct peer *)); -static void trak_receive P((struct recvbuf *)); -static void trak_poll P((int, struct peer *)); - -/* - * Transfer vector - */ -struct refclock refclock_trak = { - trak_start, /* start up driver */ - trak_shutdown, /* shut down driver */ - trak_poll, /* transmit poll message */ - noentry, /* not used (old trak_control) */ - noentry, /* initialize driver (not used) */ - noentry, /* not used (old trak_buginfo) */ - NOFLAGS /* not used */ -}; - - -/* - * trak_start - open the devices and initialize data for processing - */ -static int -trak_start( - int unit, - struct peer *peer - ) -{ - register struct trakunit *up; - struct refclockproc *pp; - int fd; - char device[20]; - - /* - * Open serial port. The LDISC_ACTS line discipline inserts a - * timestamp following the "*" on-time character of the - * timecode. - */ - (void)sprintf(device, DEVICE, unit); - if ( -#ifdef PPS - !(fd = refclock_open(device, SPEED232, LDISC_CLK)) -#else - !(fd = refclock_open(device, SPEED232, 0)) -#endif /* PPS */ - ) - return (0); - - /* - * Allocate and initialize unit structure - */ - if (!(up = (struct trakunit *) - emalloc(sizeof(struct trakunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct trakunit)); - pp = peer->procptr; - pp->io.clock_recv = trak_receive; - pp->io.srcclock = (caddr_t)peer; - pp->io.datalen = 0; - pp->io.fd = fd; - if (!io_addclock(&pp->io)) { - (void) close(fd); - free(up); - return (0); - } - pp->unitptr = (caddr_t)up; - - /* - * Initialize miscellaneous variables - */ - peer->precision = PRECISION; - pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); - up->polled = 0; - - /* - * Start continuous time output. If something breaks, fold the - * tent and go home. - */ - if (write(pp->io.fd, C_CTO, sizeof(C_CTO)) != sizeof(C_CTO)) { - refclock_report(peer, CEVNT_FAULT); - (void) close(fd); - free(up); - return (0); - } - return (1); -} - - -/* - * trak_shutdown - shut down the clock - */ -static void -trak_shutdown( - int unit, - struct peer *peer - ) -{ - register struct trakunit *up; - struct refclockproc *pp; - - pp = peer->procptr; - up = (struct trakunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); -} - - -/* - * trak_receive - receive data from the serial interface - */ -static void -trak_receive( - struct recvbuf *rbufp - ) -{ - register struct trakunit *up; - struct refclockproc *pp; - struct peer *peer; - l_fp trtmp; - char *dpt, *dpend; - char qchar; -#ifdef PPS - struct ppsclockev ppsev; - int request; -#ifdef HAVE_CIOGETEV - request = CIOGETEV; -#endif -#ifdef HAVE_TIOCGPPSEV - request = TIOCGPPSEV; -#endif -#endif /* PPS */ - - /* - * Initialize pointers and read the timecode and timestamp. We - * then chuck out everything, including runts, except one - * message each poll interval. - */ - peer = (struct peer *)rbufp->recv_srcclock; - pp = peer->procptr; - up = (struct trakunit *)pp->unitptr; - pp->lencode = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, - &pp->lastrec); - - /* - * We get a buffer and timestamp following the '*' on-time - * character. If a valid timestamp, we use that in place of the - * buffer timestamp and edit out the timestamp for prettyprint - * billboards. - */ - dpt = pp->a_lastcode; - dpend = dpt + pp->lencode; - if (*dpt == '*' && buftvtots(dpt + 1, &trtmp)) { - if (trtmp.l_i == pp->lastrec.l_i || trtmp.l_i == - pp->lastrec.l_i + 1) { - pp->lastrec = trtmp; - dpt += 9; - while (dpt < dpend) { - *(dpt - 8) = *dpt; - ++dpt; - } - } - } - if (up->polled == 0) return; - up->polled = 0; -#ifndef PPS - get_systime(&up->tstamp); -#endif - record_clock_stats(&peer->srcadr, pp->a_lastcode); -#ifdef DEBUG - if (debug) - printf("trak: timecode %d %s\n", pp->lencode, - pp->a_lastcode); -#endif - - /* - * We get down to business, check the timecode format and decode - * its contents. If the timecode has invalid length or is not in - * proper format, we declare bad format and exit. - */ - if (pp->lencode < LENTRAK) { - refclock_report(peer, CEVNT_BADREPLY); - return; - } - - /* - * Timecode format: "*RQTS U,ddd:hh:mm:ss.0,q" - */ - if (sscanf(pp->a_lastcode, "*RQTS U,%3d:%2d:%2d:%2d.0,%c", - &pp->day, &pp->hour, &pp->minute, &pp->second, &qchar) != 5) { - refclock_report(peer, CEVNT_BADREPLY); - return; - } - - /* - * Decode quality and leap characters. If unsynchronized, set - * the leap bits accordingly and exit. - */ - if (qchar == '0') { - pp->leap = LEAP_NOTINSYNC; - return; - } -#ifdef PPS - if(ioctl(fdpps,request,(caddr_t) &ppsev) >=0) { - ppsev.tv.tv_sec += (u_int32) JAN_1970; - TVTOTS(&ppsev.tv,&up->tstamp); - } -#endif /* PPS */ - /* record the last ppsclock event time stamp */ - pp->lastrec = up->tstamp; - if (!refclock_process(pp)) { - refclock_report(peer, CEVNT_BADTIME); - return; - } - pp->lastref = pp->lastrec; - refclock_receive(peer); -} - - -/* - * trak_poll - called by the transmit procedure - */ -static void -trak_poll( - int unit, - struct peer *peer - ) -{ - register struct trakunit *up; - struct refclockproc *pp; - - /* - * We don't really do anything here, except arm the receiving - * side to capture a sample and check for timeouts. - */ - pp = peer->procptr; - up = (struct trakunit *)pp->unitptr; - if (up->polled) - refclock_report(peer, CEVNT_TIMEOUT); - pp->polls++; - up->polled = 1; -} - -#else -int refclock_trak_bs; -#endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_true.c b/contrib/ntp/ntpd/refclock_true.c index dd355d902..67ba6dfbe 100644 --- a/contrib/ntp/ntpd/refclock_true.c +++ b/contrib/ntp/ntpd/refclock_true.c @@ -1,9 +1,8 @@ /* - * refclock_true - clock driver for the Kinemetrics Truetime receivers + * refclock_true - clock driver for the Kinemetrics/TrueTime receivers * Receiver Version 3.0C - tested plain, with CLKLDISC - * Developement work being done: - * - Properly handle varying satellite positions (more acurately) - * - Integrate GPSTM and/or OMEGA and/or TRAK and/or ??? drivers + * Development work being done: + * - Support TL-3 WWV TOD receiver */ #ifdef HAVE_CONFIG_H @@ -12,14 +11,20 @@ #if defined(REFCLOCK) && defined(CLOCK_TRUETIME) +#include +#include + #include "ntpd.h" #include "ntp_io.h" #include "ntp_refclock.h" #include "ntp_unixtime.h" #include "ntp_stdlib.h" -#include -#include +#ifdef SYS_WINNT +extern int async_write(int, const void *, unsigned int); +#undef write +#define write(fd, data, octets) async_write(fd, data, octets) +#endif /* This should be an atom clock but those are very hard to build. * @@ -44,10 +49,11 @@ /* * Support for Kinemetrics Truetime Receivers - * GOES - * GPS/TM-TMD - * XL-DC (a 151-602-210, reported by the driver as a GPS/TM-TMD) - * GPS-800 TCU (an 805-957 with the RS232 Talker/Listener module) + * GOES: (468-DC, usable with GPS->GOES converting antenna) + * GPS/TM-TMD: + * XL-DC: (a 151-602-210, reported by the driver as a GPS/TM-TMD) + * GPS-800 TCU: (an 805-957 with the RS232 Talker/Listener module) + * TL-3: 3 channel WWV/H receiver w/ IRIG and RS-232 outputs * OM-DC: getting stale ("OMEGA") * * Most of this code is originally from refclock_wwvb.c with thanks. @@ -65,15 +71,18 @@ * ? +/- 1 milliseconds # +/- 100 microseconds * * +/- 10 microseconds . +/- 1 microsecond * space less than 1 microsecond + * TL-3 Receiver: (default quality codes for TL-3) + * ? unknown quality (receiver is unlocked) + * space +/- 5 milliseconds * OM-DC OMEGA Receiver: (default quality codes for OMEGA) * WARNING OMEGA navigation system is no longer existent * > >+- 5 seconds * ? >+/- 500 milliseconds # >+/- 50 milliseconds * * >+/- 5 milliseconds . >+/- 1 millisecond * A-H less than 1 millisecond. Character indicates which station - * is being received as follows: - * A = Norway, B = Liberia, C = Hawaii, D = North Dakota, - * E = La Reunion, F = Argentina, G = Australia, H = Japan. + * is being received as follows: + * A = Norway, B = Liberia, C = Hawaii, D = North Dakota, + * E = La Reunion, F = Argentina, G = Australia, H = Japan. * * The carriage return start bit begins on 0 seconds and extends to 1 bit time. * @@ -97,16 +106,27 @@ * This corrects the 4 milliseconds advance and 8 milliseconds retard * needed. The software will ask the clock which satellite it sees. * - * Ntp.conf parameters: - * time1 - offset applied to samples when reading WEST satellite (default = 0) - * time2 - offset applied to samples when reading EAST satellite (default = 0) - * val1 - stratum to assign to this clock (default = 0) - * val2 - refid assigned to this clock (default = "TRUE", see below) - * flag1 - will silence the clock side of ntpd, just reading the clock - * without trying to write to it. (default = 0) - * flag2 - generate a debug file /tmp/true%d. - * flag3 - enable ppsclock streams module - * flag4 - use the PCL-720 (BSD/OS only) + * Notes on the TrueTime TimeLink TL-3 WWV TOD receiver: + * + * This clock may be polled, or send one timecode per second. + * That mode may be toggled via the front panel ("C" mode), or controlled + * from the RS-232 port. Send the receiver "ST1" to turn it on, and + * "ST0" to turn it off. Send "QV" to get the firmware revision (useful + * for identifying this model.) + * + * Note that it can take several polling cycles, especially if the receiver + * was in the continuous timecode mode. (It can be slow to leave that mode.) + * + * ntp.conf parameters: + * time1 - offset applied to samples when reading WEST satellite (default = 0) + * time2 - offset applied to samples when reading EAST satellite (default = 0) + * stratum - stratum to assign to this clock (default = 0) + * refid - refid assigned to this clock (default = "TRUE", see below) + * flag1 - will silence the clock side of ntpd, just reading the clock + * without trying to write to it. (default = 0) + * flag2 - generate a debug file /tmp/true%d. + * flag3 - enable ppsclock streams module + * flag4 - use the PCL-720 (BSD/OS only) */ @@ -133,19 +153,19 @@ * used by the state machine */ enum true_event {e_Init, e_Huh, e_F18, e_F50, e_F51, e_Satellite, - e_Poll, e_Location, e_TS, e_Max}; + e_TL3, e_Poll, e_Location, e_TS, e_Max}; const char *events[] = {"Init", "Huh", "F18", "F50", "F51", "Satellite", - "Poll", "Location", "TS"}; + "TL3", "Poll", "Location", "TS"}; #define eventStr(x) (((int)x<(int)e_Max) ? events[(int)x] : "?") enum true_state {s_Base, s_InqTM, s_InqTCU, s_InqOmega, s_InqGOES, - s_Init, s_F18, s_F50, s_Start, s_Auto, s_Max}; + s_InqTL3, s_Init, s_F18, s_F50, s_Start, s_Auto, s_Max}; const char *states[] = {"Base", "InqTM", "InqTCU", "InqOmega", "InqGOES", - "Init", "F18", "F50", "Start", "Auto"}; + "InqTL3", "Init", "F18", "F50", "Start", "Auto"}; #define stateStr(x) (((int)x<(int)s_Max) ? states[(int)x] : "?") -enum true_type {t_unknown, t_goes, t_tm, t_tcu, t_omega, t_Max}; -const char *types[] = {"unknown", "goes", "tm", "tcu", "omega"}; +enum true_type {t_unknown, t_goes, t_tm, t_tcu, t_omega, t_tl3, t_Max}; +const char *types[] = {"unknown", "goes", "tm", "tcu", "omega", "tl3"}; #define typeStr(x) (((int)x<(int)t_Max) ? types[(int)x] : "?") /* @@ -167,15 +187,15 @@ struct true_unit { /* * Function prototypes */ -static int true_start P((int, struct peer *)); -static void true_shutdown P((int, struct peer *)); -static void true_receive P((struct recvbuf *)); -static void true_poll P((int, struct peer *)); -static void true_send P((struct peer *, const char *)); -static void true_doevent P((struct peer *, enum true_event)); +static int true_start (int, struct peer *); +static void true_shutdown (int, struct peer *); +static void true_receive (struct recvbuf *); +static void true_poll (int, struct peer *); +static void true_send (struct peer *, const char *); +static void true_doevent (struct peer *, enum true_event); #ifdef CLOCK_PPS720 -static u_long true_sample720 P((void)); +static u_long true_sample720 (void); #endif /* @@ -195,6 +215,7 @@ struct refclock refclock_true = { #if !defined(__STDC__) # define true_debug (void) #else +NTP_PRINTF(2, 3) static void true_debug(struct peer *peer, const char *fmt, ...) { @@ -205,36 +226,40 @@ true_debug(struct peer *peer, const char *fmt, ...) va_start(ap, fmt); pp = peer->procptr; - up = (struct true_unit *)pp->unitptr; + up = pp->unitptr; want_debugging = (pp->sloppyclockflag & CLK_FLAG2) != 0; now_debugging = (up->debug != NULL); if (want_debugging != now_debugging) { if (want_debugging) { - char filename[40]; - int fd; - - snprintf(filename, sizeof(filename), "/tmp/true%d.debug", up->unit); - fd = open(filename, O_CREAT | O_WRONLY | O_EXCL, 0600); - if (fd >= 0 && (up->debug = fdopen(fd, "r+"))) { + char filename[40]; + int fd; + + snprintf(filename, sizeof(filename), + "/tmp/true%d.debug", up->unit); + fd = open(filename, O_CREAT | O_WRONLY | O_EXCL, + 0600); + if (fd >= 0 && (up->debug = fdopen(fd, "w"))) { #ifdef HAVE_SETVBUF - static char buf[BUFSIZ]; - setvbuf(up->debug, buf, _IOLBF, BUFSIZ); + static char buf[BUFSIZ]; + + setvbuf(up->debug, buf, _IOLBF, BUFSIZ); #else - setlinebuf(up->debug); + setlinebuf(up->debug); #endif - } - } else { - fclose(up->debug); - up->debug = NULL; - } + } + } else { + fclose(up->debug); + up->debug = NULL; + } } if (up->debug) { fprintf(up->debug, "true%d: ", up->unit); vfprintf(up->debug, fmt, ap); } + va_end(ap); } #endif /*STDC*/ @@ -255,44 +280,51 @@ true_start( /* * Open serial port */ - (void)snprintf(device, sizeof(device), DEVICE, unit); - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) - return (0); + snprintf(device, sizeof(device), DEVICE, unit); + fd = refclock_open(device, SPEED232, LDISC_CLK); + if (fd <= 0) + return 0; /* * Allocate and initialize unit structure */ - if (!(up = (struct true_unit *) - emalloc(sizeof(struct true_unit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct true_unit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; pp->io.clock_recv = true_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); up->pollcnt = 2; up->type = t_unknown; up->state = s_Base; + + /* + * Send a CTRL-C character at the start, + * just in case the clock is already + * sending timecodes + */ + true_send(peer, "\03\r"); + true_doevent(peer, e_Init); + return (1); } + /* * true_shutdown - shut down the clock */ @@ -306,9 +338,11 @@ true_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct true_unit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (pp->io.fd != -1) + io_closeclock(&pp->io); + if (up != NULL) + free(up); } @@ -327,33 +361,34 @@ true_receive( char synced; int i; int lat, lon, off; /* GOES Satellite position */ - /* Use these variable to hold data until we decide its worth keeping */ - char rd_lastcode[BMAX]; - l_fp rd_tmp; - u_short rd_lencode; + /* These variables hold data until we decide to keep it */ + char rd_lastcode[BMAX]; + l_fp rd_tmp; + u_short rd_lencode; /* * Get the clock this applies to and pointers to the data. */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct true_unit *)pp->unitptr; + up = pp->unitptr; /* * Read clock output. Automatically handles STREAMS, CLKLDISC. */ - rd_lencode = refclock_gtlin(rbufp, rd_lastcode, BMAX, &rd_tmp); - rd_lastcode[rd_lencode] = '\0'; + rd_lencode = refclock_gtlin(rbufp, rd_lastcode, BMAX, &rd_tmp); + rd_lastcode[rd_lencode] = '\0'; /* * There is a case where generates 2 timestamps. */ - if (rd_lencode == 0) - return; - pp->lencode = rd_lencode; - strcpy(pp->a_lastcode, rd_lastcode); - pp->lastrec = rd_tmp; - true_debug(peer, "receive(%s) [%d]\n", pp->a_lastcode, pp->lencode); + if (rd_lencode == 0) + return; + pp->lencode = rd_lencode; + strlcpy(pp->a_lastcode, rd_lastcode, sizeof(pp->a_lastcode)); + pp->lastrec = rd_tmp; + true_debug(peer, "receive(%s) [%d]\n", pp->a_lastcode, + pp->lencode); up->pollcnt = 2; record_clock_stats(&peer->srcadr, pp->a_lastcode); @@ -424,24 +459,37 @@ true_receive( */ if (sscanf(pp->a_lastcode, "F%2d", &i) == 1 && i > 0 && i < 80) { switch (i) { - case 50: + case 50: true_doevent(peer, e_F50); break; - case 51: + case 51: true_doevent(peer, e_F51); break; - default: + default: true_debug(peer, "got F%02d - ignoring\n", i); break; } return; } + /* + * Timecode: "VER xx.xx" + * (from a TL3 when sent "QV", so id's it during initialization.) + */ + if (pp->a_lastcode[0] == 'V' && pp->a_lastcode[1] == 'E' && + pp->a_lastcode[2] == 'R' && pp->a_lastcode[6] == '.') { + true_doevent(peer, e_TL3); + NLOG(NLOG_CLOCKSTATUS) { + msyslog(LOG_INFO, "TL3: %s", pp->a_lastcode); + } + return; + } + /* * Timecode: " TRUETIME Mk III" or " TRUETIME XL" * (from a TM/TMD/XL clock during initialization.) */ - if (strcmp(pp->a_lastcode, " TRUETIME Mk III") == 0 || + if (strncmp(pp->a_lastcode, " TRUETIME Mk III ", 17) == 0 || strncmp(pp->a_lastcode, " TRUETIME XL", 12) == 0) { true_doevent(peer, e_F18); NLOG(NLOG_CLOCKSTATUS) { @@ -452,8 +500,8 @@ true_receive( /* * Timecode: "N03726428W12209421+000033" - * 1 2 - * 0123456789012345678901234 + * 1 2 + * index 0123456789012345678901234 * (from a TCU during initialization) */ if ((pp->a_lastcode[0] == 'N' || pp->a_lastcode[0] == 'S') && @@ -467,6 +515,8 @@ true_receive( } /* * Timecode: "ddd:hh:mm:ssQ" + * 1 2 + * index 0123456789012345678901234 * (from all clocks supported by this driver.) */ if (pp->a_lastcode[3] == ':' && @@ -480,10 +530,11 @@ true_receive( * Adjust the synchronize indicator according to timecode * say were OK, and then say not if we really are not OK */ - if (synced == '>' || synced == '#' || synced == '?') - pp->leap = LEAP_NOTINSYNC; + if (synced == '>' || synced == '#' || synced == '?' + || synced == 'X') + pp->leap = LEAP_NOTINSYNC; else - pp->leap = LEAP_NOWARNING; + pp->leap = LEAP_NOWARNING; true_doevent(peer, e_TS); @@ -535,9 +586,15 @@ true_receive( * want one when polled. If we havn't been polled, bail out. */ if (!up->polled) - return; + return; + + /* We only call doevent if additional things need be done + * at poll interval. Currently, its only for GOES. We also + * call it for clock unknown so that it gets logged. + */ + if (up->type == t_goes || up->type == t_unknown) + true_doevent(peer, e_Poll); - true_doevent(peer, e_Poll); if (!refclock_process(pp)) { refclock_report(peer, CEVNT_BADTIME); return; @@ -546,7 +603,7 @@ true_receive( * If clock is good we send a NOMINAL message so that * any previous BAD messages are nullified */ - pp->lastref = pp->lastrec; + pp->lastref = pp->lastrec; refclock_receive(peer); refclock_report(peer, CEVNT_NOMINAL); @@ -580,13 +637,13 @@ true_send( pp = peer->procptr; if (!(pp->sloppyclockflag & CLK_FLAG1)) { - register int len = strlen(cmd); + int len = strlen(cmd); true_debug(peer, "Send '%s'\n", cmd); if (write(pp->io.fd, cmd, (unsigned)len) != len) - refclock_report(peer, CEVNT_FAULT); + refclock_report(peer, CEVNT_FAULT); else - pp->polls++; + pp->polls++; } } @@ -604,7 +661,7 @@ true_doevent( struct refclockproc *pp; pp = peer->procptr; - up = (struct true_unit *)pp->unitptr; + up = pp->unitptr; if (event != e_TS) { NLOG(NLOG_CLOCKSTATUS) { msyslog(LOG_INFO, "TRUE: clock %s, state %s, event %s", @@ -616,176 +673,233 @@ true_doevent( true_debug(peer, "clock %s, state %s, event %s\n", typeStr(up->type), stateStr(up->state), eventStr(event)); switch (up->type) { - case t_goes: + case t_goes: switch (event) { - case e_Init: /* FALLTHROUGH */ - case e_Satellite: + case e_Init: /* FALLTHROUGH */ + case e_Satellite: /* * Switch back to on-second time codes and return. */ true_send(peer, "C"); up->state = s_Start; break; - case e_Poll: + case e_Poll: /* * After each poll, check the station (satellite). */ true_send(peer, "P"); /* No state change needed. */ break; - default: + default: break; } /* FALLTHROUGH */ - case t_omega: + case t_omega: switch (event) { - case e_Init: + case e_Init: true_send(peer, "C"); up->state = s_Start; break; - case e_TS: + case e_TS: if (up->state != s_Start && up->state != s_Auto) { true_send(peer, "\03\r"); break; } up->state = s_Auto; break; - default: + default: break; } break; - case t_tm: + case t_tm: switch (event) { - case e_Init: + case e_Init: true_send(peer, "F18\r"); up->state = s_Init; break; - case e_F18: + case e_F18: true_send(peer, "F50\r"); + /* + * Timecode: " TRUETIME Mk III" or " TRUETIME XL" + * (from a TM/TMD/XL clock during initialization.) + */ + if ( strcmp(pp->a_lastcode, " TRUETIME Mk III") == 0 || + strncmp(pp->a_lastcode, " TRUETIME XL", 12) == 0) { + true_doevent(peer, e_F18); + NLOG(NLOG_CLOCKSTATUS) { + msyslog(LOG_INFO, "TM/TMD/XL: %s", + pp->a_lastcode); + } + return; + } up->state = s_F18; break; - case e_F50: + case e_F50: true_send(peer, "F51\r"); up->state = s_F50; break; - case e_F51: + case e_F51: true_send(peer, "F08\r"); up->state = s_Start; break; - case e_TS: + case e_TS: if (up->state != s_Start && up->state != s_Auto) { true_send(peer, "\03\r"); break; } up->state = s_Auto; break; - default: + default: break; } break; - case t_tcu: + case t_tcu: switch (event) { - case e_Init: + case e_Init: true_send(peer, "MD3\r"); /* GPS Synch'd Gen. */ true_send(peer, "TSU\r"); /* UTC, not GPS. */ true_send(peer, "AU\r"); /* Auto Timestamps. */ up->state = s_Start; break; - case e_TS: + case e_TS: if (up->state != s_Start && up->state != s_Auto) { true_send(peer, "\03\r"); break; } up->state = s_Auto; break; - default: + default: break; } break; - case t_unknown: + case t_tl3: + switch (event) { + case e_Init: + true_send(peer, "ST1"); /* Turn on continuous stream */ + break; + case e_TS: + up->state = s_Auto; + break; + default: + break; + } + break; + case t_unknown: + if (event == e_Poll) + break; switch (up->state) { - case s_Base: + case s_Base: if (event != e_Init) abort(); true_send(peer, "P\r"); up->state = s_InqGOES; break; - case s_InqGOES: + case s_InqGOES: switch (event) { - case e_Satellite: + case e_Satellite: up->type = t_goes; true_doevent(peer, e_Init); break; - case e_Init: /*FALLTHROUGH*/ - case e_Huh: /*FALLTHROUGH*/ - case e_TS: + case e_Init: /*FALLTHROUGH*/ + case e_Huh: + case e_TS: + true_send(peer, "ST0"); /* turn off TL3 auto */ + sleep(1); /* wait for it */ + up->state = s_InqTL3; + true_send(peer, "QV"); /* see if its a TL3 */ + break; + default: + abort(); + } + break; + case s_InqTL3: + switch (event) { + case e_TL3: + up->type = t_tl3; + up->state = s_Auto; /* Inq side-effect. */ + true_send(peer, "ST1"); /* Turn on 1/sec data */ + break; + case e_Init: /*FALLTHROUGH*/ + case e_Huh: up->state = s_InqOmega; true_send(peer, "C\r"); break; + case e_TS: + up->type = t_tl3; /* Already sending data */ + up->state = s_Auto; + break; default: - abort(); + msyslog(LOG_INFO, + "TRUE: TL3 init fellthrough! (%d)", event); + break; } break; - case s_InqOmega: + case s_InqOmega: switch (event) { - case e_TS: + case e_TS: up->type = t_omega; up->state = s_Auto; /* Inq side-effect. */ break; - case e_Init: /*FALLTHROUGH*/ - case e_Huh: + case e_Init: /*FALLTHROUGH*/ + case e_Huh: up->state = s_InqTM; true_send(peer, "F18\r"); break; - default: + default: abort(); } break; - case s_InqTM: + case s_InqTM: switch (event) { - case e_F18: + case e_F18: up->type = t_tm; true_doevent(peer, e_Init); break; - case e_Init: /*FALLTHROUGH*/ - case e_Huh: + case e_Init: /*FALLTHROUGH*/ + case e_Huh: true_send(peer, "PO\r"); up->state = s_InqTCU; break; - default: - abort(); + default: + msyslog(LOG_INFO, + "TRUE: TM/TMD init fellthrough!"); + break; } break; - case s_InqTCU: + case s_InqTCU: switch (event) { - case e_Location: + case e_Location: up->type = t_tcu; true_doevent(peer, e_Init); break; - case e_Init: /*FALLTHROUGH*/ - case e_Huh: + case e_Init: /*FALLTHROUGH*/ + case e_Huh: up->state = s_Base; sleep(1); /* XXX */ break; - default: - abort(); + default: + msyslog(LOG_INFO, + "TRUE: TCU init fellthrough!"); + break; } break; /* * An expedient hack to prevent lint complaints, * these don't actually need to be used here... */ - case s_Init: - case s_F18: - case s_F50: - case s_Start: - case s_Auto: - case s_Max: - msyslog(LOG_INFO, "TRUE: state %s is unexpected!", stateStr(up->state)); + case s_Init: + case s_F18: + case s_F50: + case s_Start: + case s_Auto: + case s_Max: + msyslog(LOG_INFO, "TRUE: state %s is unexpected!", + stateStr(up->state)); } break; - default: - abort(); + default: + msyslog(LOG_INFO, "TRUE: cannot identify refclock!"); + abort(); /* NOTREACHED */ } @@ -825,10 +939,10 @@ true_poll( * The next time a timecode comes in, it will be fed back. */ pp = peer->procptr; - up = (struct true_unit *)pp->unitptr; - if (up->pollcnt > 0) - up->pollcnt--; - else { + up = pp->unitptr; + if (up->pollcnt > 0) { + up->pollcnt--; + } else { true_doevent(peer, e_Init); refclock_report(peer, CEVNT_TIMEOUT); } diff --git a/contrib/ntp/ntpd/refclock_tsyncpci.c b/contrib/ntp/ntpd/refclock_tsyncpci.c new file mode 100644 index 000000000..e70a7cf9c --- /dev/null +++ b/contrib/ntp/ntpd/refclock_tsyncpci.c @@ -0,0 +1,912 @@ +/******************************************************************************* +* +* Module : refclock_tsyncpci.c +* Date : 09/08/08 +* Purpose : Implements a reference clock driver for the NTP daemon. This +* reference clock driver provides a means to communicate with +* the Spectracom TSYNC PCI timing devices and use them as a time +* source. +* +* (C) Copyright 2008 Spectracom Corporation +* +* This software is provided by Spectracom Corporation 'as is' and +* any express or implied warranties, including, but not limited to, the +* implied warranties of merchantability and fitness for a particular purpose +* are disclaimed. In no event shall Spectracom Corporation be liable +* for any direct, indirect, incidental, special, exemplary, or consequential +* damages (including, but not limited to, procurement of substitute goods +* or services; loss of use, data, or profits; or business interruption) +* however caused and on any theory of liability, whether in contract, strict +* liability, or tort (including negligence or otherwise) arising in any way +* out of the use of this software, even if advised of the possibility of +* such damage. +* +* This software is released for distribution according to the NTP copyright +* and license contained in html/copyright.html of NTP source. +* +*******************************************************************************/ +#ifdef HAVE_CONFIG_H +#include +#endif + +#if defined(REFCLOCK) && defined(CLOCK_TSYNCPCI) + +#include +#ifdef HAVE_SYS_IOCTL_H +# include +#endif + +#include +#include +#include + + +#include "ntpd.h" +#include "ntp_io.h" +#include "ntp_refclock.h" +#include "ntp_unixtime.h" +#include "ntp_stdlib.h" +#include "ntp_calendar.h" + + +/******************************************************************************* +** +** This driver supports the Spectracom TSYNC PCI GPS receiver. It requires +** that the tsyncpci.o device driver be installed and loaded. +** +*******************************************************************************/ + +#define TSYNC_PCI_REVISION "1.11" + +/* +** TPRO interface definitions +*/ +#define DEVICE "/dev/tsyncpci" /* device name */ +#define PRECISION (-20) /* precision assumed (1 us) */ +#define DESCRIPTION "Spectracom TSYNC-PCI" /* WRU */ + +#define SECONDS_1900_TO_1970 (2208988800U) + +#define TSYNC_REF_IID (0x2500) // SS CAI, REF IID +#define TSYNC_REF_DEST_ID (0x0001) // KTS Firmware +#define TSYNC_REF_IN_PYLD_OFF (0) +#define TSYNC_REF_IN_LEN (0) +#define TSYNC_REF_OUT_PYLD_OFF (0) +#define TSYNC_REF_OUT_LEN (8) +#define TSYNC_REF_MAX_OUT_LEN (16) +#define TSYNC_REF_PYLD_LEN (TSYNC_REF_IN_LEN + \ + TSYNC_REF_MAX_OUT_LEN) +#define TSYNC_REF_LEN (4) +#define TSYNC_REF_LOCAL ("LOCL") + +#define TSYNC_TMSCL_IID (0x2301) // CS CAI, TIMESCALE IID +#define TSYNC_TMSCL_DEST_ID (0x0001) // KTS Firmware +#define TSYNC_TMSCL_IN_PYLD_OFF (0) +#define TSYNC_TMSCL_IN_LEN (0) +#define TSYNC_TMSCL_OUT_PYLD_OFF (0) +#define TSYNC_TMSCL_OUT_LEN (4) +#define TSYNC_TMSCL_MAX_OUT_LEN (12) +#define TSYNC_TMSCL_PYLD_LEN (TSYNC_TMSCL_IN_LEN + \ + TSYNC_TMSCL_MAX_OUT_LEN) + +#define TSYNC_LEAP_IID (0x2307) // CS CAI, LEAP SEC IID +#define TSYNC_LEAP_DEST_ID (0x0001) // KTS Firmware +#define TSYNC_LEAP_IN_PYLD_OFF (0) +#define TSYNC_LEAP_IN_LEN (0) +#define TSYNC_LEAP_OUT_PYLD_OFF (0) +#define TSYNC_LEAP_OUT_LEN (28) +#define TSYNC_LEAP_MAX_OUT_LEN (36) +#define TSYNC_LEAP_PYLD_LEN (TSYNC_LEAP_IN_LEN + \ + TSYNC_LEAP_MAX_OUT_LEN) + +// These define the base date/time of the system clock. The system time will +// be tracked as the number of seconds from this date/time. +#define TSYNC_TIME_BASE_YEAR (1970) // earliest acceptable year + +#define TSYNC_LCL_STRATUM (0) + +/* +** TSYNC Time Scales type +*/ +typedef enum +{ + TIME_SCALE_UTC = 0, // Universal Coordinated Time + TIME_SCALE_TAI = 1, // International Atomic Time + TIME_SCALE_GPS = 2, // Global Positioning System + TIME_SCALE_LOCAL = 3, // UTC w/local rules for time zone and DST + NUM_TIME_SCALES = 4, // Number of time scales + + TIME_SCALE_MAX = 15 // Maximum number of timescales + +} TIME_SCALE; + +/* +** TSYNC Board Object +*/ +typedef struct BoardObj { + + int file_descriptor; + unsigned short devid; + unsigned short options; + unsigned char firmware[5]; + unsigned char FPGA[5]; + unsigned char driver[7]; + +} BoardObj; + +/* +** TSYNC Time Object +*/ +typedef struct TimeObj { + + unsigned char syncOption; /* -M option */ + unsigned int secsDouble; /* seconds floating pt */ + unsigned char seconds; /* seconds whole num */ + unsigned char minutes; + unsigned char hours; + unsigned short days; + unsigned short year; + unsigned short flags; /* bit 2 SYNC, bit 1 TCODE; all others 0 */ + +} TimeObj; + +/* +** NTP Time Object +*/ +typedef struct NtpTimeObj { + + TimeObj timeObj; + struct timeval tv; + unsigned int refId; + +} NtpTimeObj; +/* +** TSYNC Supervisor Reference Object +*/ +typedef struct ReferenceObj { + + char time[TSYNC_REF_LEN]; + char pps[TSYNC_REF_LEN]; + +} ReferenceObj; + +/* +** TSYNC Seconds Time Object +*/ +typedef struct SecTimeObj +{ + unsigned int seconds; + unsigned int ns; +} +SecTimeObj; + +/* +** TSYNC DOY Time Object +*/ +typedef struct DoyTimeObj +{ + unsigned int year; + unsigned int doy; + unsigned int hour; + unsigned int minute; + unsigned int second; + unsigned int ns; +} +DoyTimeObj; + +/* +** TSYNC Leap Second Object +*/ +typedef struct LeapSecondObj +{ + int offset; + DoyTimeObj utcDate; +} +LeapSecondObj; + +/* + * structures for ioctl interactions with driver + */ +#define DI_PAYLOADS_STARTER_LENGTH 4 +typedef struct ioctl_trans_di { + + // input parameters + uint16_t dest; + uint16_t iid; + + uint32_t inPayloadOffset; + uint32_t inLength; + uint32_t outPayloadOffset; + uint32_t maxOutLength; + + // output parameters + uint32_t actualOutLength; + int32_t status; + + // Input and output + + // The payloads field MUST be last in ioctl_trans_di. + uint8_t payloads[DI_PAYLOADS_STARTER_LENGTH]; + +}ioctl_trans_di; + +/* + * structure for looking up a reference ID from a reference name + */ +typedef struct +{ + const char* pRef; // KTS Reference Name + const char* pRefId; // NTP Reference ID + +} RefIdLookup; + +/* + * unit control structure + */ +typedef struct { + uint32_t refPrefer; // Reference prefer flag + uint32_t refId; // Host peer reference ID + uint8_t refStratum; // Host peer reference stratum + +} TsyncUnit; + +/* +** Function prototypes +*/ +static void tsync_poll (int unit, struct peer *); +static void tsync_shutdown (int, struct peer *); +static int tsync_start (int, struct peer *); + +/* +** Helper functions +*/ +static void ApplyTimeOffset (DoyTimeObj* pDt, int off); +static void SecTimeFromDoyTime (SecTimeObj* pSt, DoyTimeObj* pDt); +static void DoyTimeFromSecTime (DoyTimeObj* pDt, SecTimeObj* pSt); + +/* +** Transfer vector +*/ +struct refclock refclock_tsyncpci = { + tsync_start, /* start up driver */ + tsync_shutdown, /* shut down driver */ + tsync_poll, /* transmit poll message */ + noentry, /* not used (old tsync_control) */ + noentry, /* initialize driver (not used) */ + noentry, /* not used (old tsync_buginfo) */ + NOFLAGS /* not used */ +}; + +/* + * Reference ID lookup table + */ +static RefIdLookup RefIdLookupTbl[] = +{ + {"gps", "GPS"}, + {"ir", "IRIG"}, + {"hvq", "HVQ"}, + {"frq", "FREQ"}, + {"mdm", "ACTS"}, + {"epp", "PPS"}, + {"ptp", "PTP"}, + {"asc", "ATC"}, + {"hst0", "USER"}, + {"hst", TSYNC_REF_LOCAL}, + {"self", TSYNC_REF_LOCAL}, + {NULL, NULL} +}; + +/******************************************************************************* +** IOCTL DEFINITIONS +*******************************************************************************/ +#define IOCTL_TPRO_ID 't' +#define IOCTL_TPRO_OPEN _IOWR(IOCTL_TPRO_ID, 0, BoardObj) +#define IOCTL_TPRO_GET_NTP_TIME _IOWR(IOCTL_TPRO_ID, 25, NtpTimeObj) +#define IOCTL_TSYNC_GET _IOWR(IOCTL_TPRO_ID, 26, ioctl_trans_di) + +/****************************************************************************** + * + * Function: tsync_start() + * Description: Used to intialize the Spectracom TSYNC reference driver. + * + * Parameters: + * IN: unit - not used. + * *peer - pointer to this reference clock's peer structure + * Returns: 0 - unsuccessful + * 1 - successful + * +*******************************************************************************/ +static int tsync_start(int unit, struct peer *peer) +{ + struct refclockproc *pp; + TsyncUnit *up; + + + /* + ** initialize reference clock and peer parameters + */ + pp = peer->procptr; + pp->clockdesc = DESCRIPTION; + pp->io.clock_recv = noentry; + pp->io.srcclock = peer; + pp->io.datalen = 0; + peer->precision = PRECISION; + + // Allocate and initialize unit structure + if (!(up = (TsyncUnit*)emalloc(sizeof(TsyncUnit)))) + { + return (0); + } + + // Store reference preference + up->refPrefer = peer->flags & FLAG_PREFER; + + // Initialize reference stratum level and ID + up->refStratum = STRATUM_UNSPEC; + strncpy((char *)&up->refId, TSYNC_REF_LOCAL, TSYNC_REF_LEN); + + // Attach unit structure + pp->unitptr = (caddr_t)up; + + /* Declare our refId as local in the beginning because we do not know + * what our actual refid is yet. + */ + strncpy((char *)&pp->refid, TSYNC_REF_LOCAL, TSYNC_REF_LEN); + + return (1); + +} /* End - tsync_start() */ + +/******************************************************************************* +** +** Function: tsync_shutdown() +** Description: Handles anything related to shutting down the reference clock +** driver. Nothing at this point in time. +** +** Parameters: +** IN: unit - not used. +** *peer - pointer to this reference clock's peer structure +** Returns: none. +** +*******************************************************************************/ +static void tsync_shutdown(int unit, struct peer *peer) +{ + +} /* End - tsync_shutdown() */ + +/****************************************************************************** + * + * Function: tsync_poll() + * Description: Retrieve time from the TSYNC device. + * + * Parameters: + * IN: unit - not used. + * *peer - pointer to this reference clock's peer structure + * Returns: none. + * +*******************************************************************************/ +static void tsync_poll(int unit, struct peer *peer) +{ + char device[32]; + struct refclockproc *pp; + struct calendar jt; + TsyncUnit *up; + unsigned char synch; + double seconds; + int err; + int err1; + int err2; + int err3; + int i; + int j; + unsigned int itAllocationLength; + unsigned int itAllocationLength1; + unsigned int itAllocationLength2; + NtpTimeObj TimeContext; + BoardObj hBoard; + char timeRef[TSYNC_REF_LEN + 1]; + char ppsRef [TSYNC_REF_LEN + 1]; + TIME_SCALE tmscl = TIME_SCALE_UTC; + LeapSecondObj leapSec; + ioctl_trans_di *it; + ioctl_trans_di *it1; + ioctl_trans_di *it2; + l_fp offset; + l_fp ltemp; + ReferenceObj * pRefObj; + + + /* Construct the device name */ + sprintf(device, "%s%d", DEVICE, (int)peer->refclkunit); + + printf("Polling device number %d...\n", (int)peer->refclkunit); + + /* Open the TSYNC device */ + hBoard.file_descriptor = open(device, O_RDONLY | O_NDELAY, 0777); + + /* If error opening TSYNC device... */ + if (hBoard.file_descriptor < 0) + { + msyslog(LOG_ERR, "Couldn't open device"); + return; + } + + /* If error while initializing the board... */ + if (ioctl(hBoard.file_descriptor, IOCTL_TPRO_OPEN, &hBoard) < 0) + { + msyslog(LOG_ERR, "Couldn't initialize device"); + close(hBoard.file_descriptor); + return; + } + + /* Allocate memory for ioctl message */ + itAllocationLength = + (sizeof(ioctl_trans_di) - DI_PAYLOADS_STARTER_LENGTH) + + TSYNC_REF_IN_LEN + TSYNC_REF_MAX_OUT_LEN; + + it = (ioctl_trans_di*)alloca(itAllocationLength); + if (it == NULL) { + msyslog(LOG_ERR, "Couldn't allocate transaction memory - Reference"); + return; + } + + /* Build SS_GetRef ioctl message */ + it->dest = TSYNC_REF_DEST_ID; + it->iid = TSYNC_REF_IID; + it->inPayloadOffset = TSYNC_REF_IN_PYLD_OFF; + it->inLength = TSYNC_REF_IN_LEN; + it->outPayloadOffset = TSYNC_REF_OUT_PYLD_OFF; + it->maxOutLength = TSYNC_REF_MAX_OUT_LEN; + it->actualOutLength = 0; + it->status = 0; + memset(it->payloads, 0, TSYNC_REF_MAX_OUT_LEN); + + /* Read the reference from the TSYNC-PCI device */ + err = ioctl(hBoard.file_descriptor, + IOCTL_TSYNC_GET, + (char *)it); + + /* Allocate memory for ioctl message */ + itAllocationLength1 = + (sizeof(ioctl_trans_di) - DI_PAYLOADS_STARTER_LENGTH) + + TSYNC_TMSCL_IN_LEN + TSYNC_TMSCL_MAX_OUT_LEN; + + it1 = (ioctl_trans_di*)alloca(itAllocationLength1); + if (it1 == NULL) { + msyslog(LOG_ERR, "Couldn't allocate transaction memory - Time Scale"); + return; + } + + /* Build CS_GetTimeScale ioctl message */ + it1->dest = TSYNC_TMSCL_DEST_ID; + it1->iid = TSYNC_TMSCL_IID; + it1->inPayloadOffset = TSYNC_TMSCL_IN_PYLD_OFF; + it1->inLength = TSYNC_TMSCL_IN_LEN; + it1->outPayloadOffset = TSYNC_TMSCL_OUT_PYLD_OFF; + it1->maxOutLength = TSYNC_TMSCL_MAX_OUT_LEN; + it1->actualOutLength = 0; + it1->status = 0; + memset(it1->payloads, 0, TSYNC_TMSCL_MAX_OUT_LEN); + + /* Read the Time Scale info from the TSYNC-PCI device */ + err1 = ioctl(hBoard.file_descriptor, + IOCTL_TSYNC_GET, + (char *)it1); + + /* Allocate memory for ioctl message */ + itAllocationLength2 = + (sizeof(ioctl_trans_di) - DI_PAYLOADS_STARTER_LENGTH) + + TSYNC_LEAP_IN_LEN + TSYNC_LEAP_MAX_OUT_LEN; + + it2 = (ioctl_trans_di*)alloca(itAllocationLength2); + if (it2 == NULL) { + msyslog(LOG_ERR, "Couldn't allocate transaction memory - Leap Second"); + return; + } + + /* Build CS_GetLeapSec ioctl message */ + it2->dest = TSYNC_LEAP_DEST_ID; + it2->iid = TSYNC_LEAP_IID; + it2->inPayloadOffset = TSYNC_LEAP_IN_PYLD_OFF; + it2->inLength = TSYNC_LEAP_IN_LEN; + it2->outPayloadOffset = TSYNC_LEAP_OUT_PYLD_OFF; + it2->maxOutLength = TSYNC_LEAP_MAX_OUT_LEN; + it2->actualOutLength = 0; + it2->status = 0; + memset(it2->payloads, 0, TSYNC_LEAP_MAX_OUT_LEN); + + /* Read the leap seconds info from the TSYNC-PCI device */ + err2 = ioctl(hBoard.file_descriptor, + IOCTL_TSYNC_GET, + (char *)it2); + + pp = peer->procptr; + up = (TsyncUnit*)pp->unitptr; + + /* Read the time from the TSYNC-PCI device */ + err3 = ioctl(hBoard.file_descriptor, + IOCTL_TPRO_GET_NTP_TIME, + (char *)&TimeContext); + + /* Close the TSYNC device */ + close(hBoard.file_descriptor); + + // Check for errors + if ((err < 0) ||(err1 < 0) || (err2 < 0) || (err3 < 0) || + (it->status != 0) || (it1->status != 0) || (it2->status != 0) || + (it->actualOutLength != TSYNC_REF_OUT_LEN) || + (it1->actualOutLength != TSYNC_TMSCL_OUT_LEN) || + (it2->actualOutLength != TSYNC_LEAP_OUT_LEN)) { + refclock_report(peer, CEVNT_FAULT); + return; + } + + // Extract reference identifiers from ioctl payload + memset(timeRef, '\0', sizeof(timeRef)); + memset(ppsRef, '\0', sizeof(ppsRef)); + pRefObj = (void *)it->payloads; + memcpy(timeRef, pRefObj->time, TSYNC_REF_LEN); + memcpy(ppsRef, pRefObj->pps, TSYNC_REF_LEN); + + // Extract the Clock Service Time Scale and convert to correct byte order + memcpy(&tmscl, ((TIME_SCALE*)(it1->payloads)), sizeof(tmscl)); + tmscl = ntohl(tmscl); + + // Extract leap second info from ioctl payload and perform byte swapping + for (i = 0; i < (sizeof(leapSec) / 4); i++) + { + for (j = 0; j < 4; j++) + { + ((unsigned char*)&leapSec)[(i * 4) + j] = + ((unsigned char*)(it2->payloads))[(i * 4) + (3 - j)]; + } + } + + // Determine time reference ID from reference name + for (i = 0; RefIdLookupTbl[i].pRef != NULL; i++) + { + // Search RefID table + if (strstr(timeRef, RefIdLookupTbl[i].pRef) != NULL) + { + // Found the matching string + break; + } + } + + // Determine pps reference ID from reference name + for (j = 0; RefIdLookupTbl[j].pRef != NULL; j++) + { + // Search RefID table + if (strstr(ppsRef, RefIdLookupTbl[j].pRef) != NULL) + { + // Found the matching string + break; + } + } + + // Determine synchronization state from flags + synch = (TimeContext.timeObj.flags == 0x4) ? 1 : 0; + + // Pull seconds information from time object + seconds = (double) (TimeContext.timeObj.secsDouble); + seconds /= (double) 1000000.0; + + /* + ** Convert the number of microseconds to double and then place in the + ** peer's last received long floating point format. + */ + DTOLFP(((double)TimeContext.tv.tv_usec / 1000000.0), &pp->lastrec); + + /* + ** The specTimeStamp is the number of seconds since 1/1/1970, while the + ** peer's lastrec time should be compatible with NTP which is seconds since + ** 1/1/1900. So Add the number of seconds between 1900 and 1970 to the + ** specTimeStamp and place in the peer's lastrec long floating point struct. + */ + pp->lastrec.Ul_i.Xl_ui += (unsigned int)TimeContext.tv.tv_sec + + SECONDS_1900_TO_1970; + + pp->polls++; + + /* + ** set the reference clock object + */ + sprintf(pp->a_lastcode, "%03d %02d:%02d:%02.6f", + TimeContext.timeObj.days, TimeContext.timeObj.hours, + TimeContext.timeObj.minutes, seconds); + + pp->lencode = strlen (pp->a_lastcode); + pp->day = TimeContext.timeObj.days; + pp->hour = TimeContext.timeObj.hours; + pp->minute = TimeContext.timeObj.minutes; + pp->second = (int) seconds; + seconds = (seconds - (double) (pp->second / 1.0)) * 1000000000; + pp->nsec = (long) seconds; + + /* + ** calculate year start + */ + jt.year = TimeContext.timeObj.year; + jt.yearday = 1; + jt.monthday = 1; + jt.month = 1; + jt.hour = 0; + jt.minute = 0; + jt.second = 0; + pp->yearstart = caltontp(&jt); + + // Calculate and report reference clock offset + offset.l_ui = (long)(((pp->day - 1) * 24) + pp->hour + GMT); + offset.l_ui = (offset.l_ui * 60) + (long)pp->minute; + offset.l_ui = (offset.l_ui * 60) + (long)pp->second; + offset.l_ui = offset.l_ui + (long)pp->yearstart; + offset.l_uf = 0; + DTOLFP(pp->nsec / 1e9, <emp); + L_ADD(&offset, <emp); + refclock_process_offset(pp, offset, pp->lastrec, + pp->fudgetime1); + + // KTS in sync + if (synch) { + // Subtract leap second info by one second to determine effective day + ApplyTimeOffset(&(leapSec.utcDate), -1); + + // If there is a leap second today and the KTS is using a time scale + // which handles leap seconds then + if ((tmscl != TIME_SCALE_GPS) && (tmscl != TIME_SCALE_TAI) && + (leapSec.utcDate.year == (unsigned int)TimeContext.timeObj.year) && + (leapSec.utcDate.doy == (unsigned int)TimeContext.timeObj.days)) + { + // If adding a second + if (leapSec.offset == 1) + { + pp->leap = LEAP_ADDSECOND; + } + // Else if removing a second + else if (leapSec.offset == -1) + { + pp->leap = LEAP_DELSECOND; + } + // Else report no leap second pending (no handling of offsets + // other than +1 or -1) + else + { + pp->leap = LEAP_NOWARNING; + } + } + // Else report no leap second pending + else + { + pp->leap = LEAP_NOWARNING; + } + + peer->leap = pp->leap; + refclock_report(peer, CEVNT_NOMINAL); + + // If reference name reported, then not in holdover + if ((RefIdLookupTbl[i].pRef != NULL) && + (RefIdLookupTbl[j].pRef != NULL)) + { + // Determine if KTS being synchronized by host (identified as + // "LOCL") + if ((strcmp(RefIdLookupTbl[i].pRefId, TSYNC_REF_LOCAL) == 0) || + (strcmp(RefIdLookupTbl[j].pRefId, TSYNC_REF_LOCAL) == 0)) + { + // Clear prefer flag + peer->flags &= ~FLAG_PREFER; + + // Set reference clock stratum level as unusable + pp->stratum = STRATUM_UNSPEC; + peer->stratum = pp->stratum; + + // If a valid peer is available + if ((sys_peer != NULL) && (sys_peer != peer)) + { + // Store reference peer stratum level and ID + up->refStratum = sys_peer->stratum; + up->refId = addr2refid(&sys_peer->srcadr); + } + } + else + { + // Restore prefer flag + peer->flags |= up->refPrefer; + + // Store reference stratum as local clock + up->refStratum = TSYNC_LCL_STRATUM; + strncpy((char *)&up->refId, RefIdLookupTbl[j].pRefId, + TSYNC_REF_LEN); + + // Set reference clock stratum level as local clock + pp->stratum = TSYNC_LCL_STRATUM; + peer->stratum = pp->stratum; + } + + // Update reference name + strncpy((char *)&pp->refid, RefIdLookupTbl[j].pRefId, + TSYNC_REF_LEN); + peer->refid = pp->refid; + } + // Else in holdover + else + { + // Restore prefer flag + peer->flags |= up->refPrefer; + + // Update reference ID to saved ID + pp->refid = up->refId; + peer->refid = pp->refid; + + // Update stratum level to saved stratum level + pp->stratum = up->refStratum; + peer->stratum = pp->stratum; + } + } + // Else KTS not in sync + else { + // Place local identifier in peer RefID + strncpy((char *)&pp->refid, TSYNC_REF_LOCAL, TSYNC_REF_LEN); + peer->refid = pp->refid; + + // Report not in sync + pp->leap = LEAP_NOTINSYNC; + peer->leap = pp->leap; + } + + if (pp->coderecv == pp->codeproc) { + refclock_report(peer, CEVNT_TIMEOUT); + return; + } + + record_clock_stats(&peer->srcadr, pp->a_lastcode); + refclock_receive(peer); + + /* Increment the number of times the reference has been polled */ + pp->polls++; + +} /* End - tsync_poll() */ + + +//////////////////////////////////////////////////////////////////////////////// +// Function: ApplyTimeOffset +// Description: The ApplyTimeOffset function adds an offset (in seconds) to a +// specified date and time. The specified date and time is passed +// back after being modified. +// +// Assumptions: 1. Every fourth year is a leap year. Therefore, this function +// is only accurate through Feb 28, 2100. +//////////////////////////////////////////////////////////////////////////////// +void ApplyTimeOffset(DoyTimeObj* pDt, int off) +{ + SecTimeObj st; // Time, in seconds + + + // Convert date and time to seconds + SecTimeFromDoyTime(&st, pDt); + + // Apply offset + st.seconds = (int)((signed long long)st.seconds + (signed long long)off); + + // Convert seconds to date and time + DoyTimeFromSecTime(pDt, &st); + +} // End ApplyTimeOffset + + +//////////////////////////////////////////////////////////////////////////////// +// Function: SecTimeFromDoyTime +// Description: The SecTimeFromDoyTime function converts a specified date +// and time into a count of seconds since the base time. This +// function operates across the range Base Time to Max Time for +// the system. +// +// Assumptions: 1. A leap year is any year evenly divisible by 4. Therefore, +// this function is only accurate through Feb 28, 2100. +// 2. Conversion does not account for leap seconds. +//////////////////////////////////////////////////////////////////////////////// +void SecTimeFromDoyTime(SecTimeObj* pSt, DoyTimeObj* pDt) +{ + unsigned int yrs; // Years + unsigned int lyrs; // Leap years + + + // Start with accumulated time of 0 + pSt->seconds = 0; + + // Calculate the number of years and leap years + yrs = pDt->year - TSYNC_TIME_BASE_YEAR; + lyrs = (yrs + 1) / 4; + + // Convert leap years and years + pSt->seconds += lyrs * SECSPERLEAPYEAR; + pSt->seconds += (yrs - lyrs) * SECSPERYEAR; + + // Convert days, hours, minutes and seconds + pSt->seconds += (pDt->doy - 1) * SECSPERDAY; + pSt->seconds += pDt->hour * SECSPERHR; + pSt->seconds += pDt->minute * SECSPERMIN; + pSt->seconds += pDt->second; + + // Copy the subseconds count + pSt->ns = pDt->ns; + +} // End SecTimeFromDoyTime + + +//////////////////////////////////////////////////////////////////////////////// +// Function: DoyTimeFromSecTime +// Description: The DoyTimeFromSecTime function converts a specified count +// of seconds since the start of our base time into a SecTimeObj +// structure. +// +// Assumptions: 1. A leap year is any year evenly divisible by 4. Therefore, +// this function is only accurate through Feb 28, 2100. +// 2. Conversion does not account for leap seconds. +//////////////////////////////////////////////////////////////////////////////// +void DoyTimeFromSecTime(DoyTimeObj* pDt, SecTimeObj* pSt) +{ + signed long long secs; // Seconds accumulator variable + unsigned int yrs; // Years accumulator variable + unsigned int doys; // Days accumulator variable + unsigned int hrs; // Hours accumulator variable + unsigned int mins; // Minutes accumulator variable + + + // Convert the seconds count into a signed 64-bit number for calculations + secs = (signed long long)(pSt->seconds); + + // Calculate the number of 4 year chunks + yrs = (unsigned int)((secs / + ((SECSPERYEAR * 3) + SECSPERLEAPYEAR)) * 4); + secs %= ((SECSPERYEAR * 3) + SECSPERLEAPYEAR); + + // If there is at least a normal year worth of time left + if (secs >= SECSPERYEAR) + { + // Increment the number of years and subtract a normal year of time + yrs++; + secs -= SECSPERYEAR; + } + + // If there is still at least a normal year worth of time left + if (secs >= SECSPERYEAR) + { + // Increment the number of years and subtract a normal year of time + yrs++; + secs -= SECSPERYEAR; + } + + // If there is still at least a leap year worth of time left + if (secs >= SECSPERLEAPYEAR) + { + // Increment the number of years and subtract a leap year of time + yrs++; + secs -= SECSPERLEAPYEAR; + } + + // Calculate the day of year as the number of days left, then add 1 + // because months start on the 1st. + doys = (unsigned int)((secs / SECSPERDAY) + 1); + secs %= SECSPERDAY; + + // Calculate the hour + hrs = (unsigned int)(secs / SECSPERHR); + secs %= SECSPERHR; + + // Calculate the minute + mins = (unsigned int)(secs / SECSPERMIN); + secs %= SECSPERMIN; + + // Fill in the doytime structure + pDt->year = yrs + TSYNC_TIME_BASE_YEAR; + pDt->doy = doys; + pDt->hour = hrs; + pDt->minute = mins; + pDt->second = (unsigned int)secs; + pDt->ns = pSt->ns; + +} // End DoyTimeFromSecTime + +#else +int refclock_tsyncpci_bs; +#endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_tt560.c b/contrib/ntp/ntpd/refclock_tt560.c index f3d7bc17a..171ba5c8c 100644 --- a/contrib/ntp/ntpd/refclock_tt560.c +++ b/contrib/ntp/ntpd/refclock_tt560.c @@ -47,9 +47,9 @@ typedef union byteswap_u /* * Function prototypes */ -static int tt560_start P((int, struct peer *)); -static void tt560_shutdown P((int, struct peer *)); -static void tt560_poll P((int unit, struct peer *)); +static int tt560_start (int, struct peer *); +static void tt560_shutdown (int, struct peer *); +static void tt560_poll (int unit, struct peer *); /* * Transfer vector @@ -76,14 +76,14 @@ tt560_start( { register struct tt560unit *up; struct refclockproc *pp; - char device[20]; - int fd; - caddr_t membase; + char device[20]; + int fd; + caddr_t membase; /* * Open TT560 device */ - (void)sprintf(device, DEVICE, unit); + snprintf(device, sizeof(device), DEVICE, unit); fd = open(device, O_RDWR); if (fd == -1) { msyslog(LOG_ERR, "tt560_start: open of %s: %m", device); @@ -123,7 +123,6 @@ tt560_start( * Initialize miscellaneous peer variables */ peer->precision = PRECISION; - peer->burst = NSTAGE; pp->clockdesc = DESCRIPTION; memcpy((char *)&pp->refid, REFID, 4); return (1); @@ -195,9 +194,9 @@ tt560_poll( * proper format, we declare bad format and exit. Note: we * can't use the sec/usec conversion produced by the driver, * since the year may be suspect. All format error checking is - * done by the sprintf() and sscanf() routines. + * done by the snprintf() and sscanf() routines. */ - sprintf(pp->a_lastcode, + snprintf(pp->a_lastcode, sizeof(pp->a_lastcode), "%1x%1x%1x %1x%1x:%1x%1x:%1x%1x.%1x%1x%1x%1x%1x%1x %1x", tp->hun_day, tp->tens_day, tp->unit_day, tp->tens_hour, tp->unit_hour, @@ -227,15 +226,12 @@ tt560_poll( refclock_report(peer, CEVNT_BADTIME); return; } - if (peer->burst > 0) - return; if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; } record_clock_stats(&peer->srcadr, pp->a_lastcode); refclock_receive(peer); - peer->burst = NSTAGE; } /****************************************************************** diff --git a/contrib/ntp/ntpd/refclock_ulink.c b/contrib/ntp/ntpd/refclock_ulink.c index d7a62fef3..d8f24a506 100644 --- a/contrib/ntp/ntpd/refclock_ulink.c +++ b/contrib/ntp/ntpd/refclock_ulink.c @@ -2,23 +2,6 @@ * refclock_ulink - clock driver for Ultralink WWVB receiver */ -/*********************************************************************** - * * - * Copyright (c) David L. Mills 1992-1998 * - * * - * Permission to use, copy, modify, and distribute this software and * - * its documentation for any purpose and without fee is hereby * - * granted, provided that the above copyright notice appears in all * - * copies and that both the copyright notice and this permission * - * notice appear in supporting documentation, and that the name * - * University of Delaware not be used in advertising or publicity * - * pertaining to distribution of the software without specific, * - * written prior permission. The University of Delaware makes no * - * representations about the suitability this software for any * - * purpose. It is provided "as is" without express or implied * - * warranty. * - **********************************************************************/ - #ifdef HAVE_CONFIG_H #include #endif @@ -106,10 +89,10 @@ struct ulinkunit { /* * Function prototypes */ -static int ulink_start P((int, struct peer *)); -static void ulink_shutdown P((int, struct peer *)); -static void ulink_receive P((struct recvbuf *)); -static void ulink_poll P((int, struct peer *)); +static int ulink_start (int, struct peer *); +static void ulink_shutdown (int, struct peer *); +static void ulink_receive (struct recvbuf *); +static void ulink_poll (int, struct peer *); /* * Transfer vector @@ -142,36 +125,33 @@ ulink_start( /* * Open serial port. Use CLK line discipline, if available. */ - (void)sprintf(device, DEVICE, unit); - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) + snprintf(device, sizeof(device), DEVICE, unit); + fd = refclock_open(device, SPEED232, LDISC_CLK); + if (fd <= 0) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct ulinkunit *) - emalloc(sizeof(struct ulinkunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct ulinkunit)); + up = emalloc(sizeof(struct ulinkunit)); + memset(up, 0, sizeof(struct ulinkunit)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; pp->io.clock_recv = ulink_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } + pp->unitptr = up; /* * Initialize miscellaneous variables */ peer->precision = PRECISION; - peer->burst = NSTAGE; pp->clockdesc = DESCRIPTION; memcpy((char *)&pp->refid, REFID, 4); return (1); @@ -191,9 +171,11 @@ ulink_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct ulinkunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (pp->io.fd != -1) + io_closeclock(&pp->io); + if (up != NULL) + free(up); } @@ -209,21 +191,21 @@ ulink_receive( struct refclockproc *pp; struct peer *peer; - l_fp trtmp; /* arrival timestamp */ - int quality; /* quality indicator */ - int temp; /* int temp */ - char syncchar; /* synchronization indicator */ - char leapchar; /* leap indicator */ - char modechar; /* model 320 mode flag */ - char siglchar; /* model difference between 33x/325 */ + l_fp trtmp; /* arrival timestamp */ + int quality = INT_MAX; /* quality indicator */ + int temp; /* int temp */ + char syncchar; /* synchronization indicator */ + char leapchar; /* leap indicator */ + char modechar; /* model 320 mode flag */ + char siglchar; /* model difference between 33x/325 */ char char_quality[2]; /* temp quality flag */ /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct ulinkunit *)pp->unitptr; + up = pp->unitptr; temp = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &trtmp); /* @@ -571,8 +553,6 @@ ulink_poll( else pp->polls++; - if (peer->burst > 0) - return; if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; @@ -580,7 +560,6 @@ ulink_poll( pp->lastref = pp->lastrec; refclock_receive(peer); record_clock_stats(&peer->srcadr, pp->a_lastcode); - peer->burst = NSTAGE; } diff --git a/contrib/ntp/ntpd/refclock_wwv.c b/contrib/ntp/ntpd/refclock_wwv.c index b7e0d9a6b..2736cfa32 100644 --- a/contrib/ntp/ntpd/refclock_wwv.c +++ b/contrib/ntp/ntpd/refclock_wwv.c @@ -39,11 +39,12 @@ * tuned automatically using this program as propagation conditions * change throughout the weasons, both day and night. * - * The driver receives, demodulates and decodes the radio signals when - * connected to the audio codec of a workstation running Solaris, SunOS - * FreeBSD or Linux, and with a little help, other workstations with - * similar codecs or sound cards. In this implementation, only one audio - * driver and codec can be supported on a single machine. + * The driver requires an audio codec or sound card with sampling rate 8 + * kHz and mu-law companding. This is the same standard as used by the + * telephone industry and is supported by most hardware and operating + * systems, including Solaris, SunOS, FreeBSD, NetBSD and Linux. In this + * implementation, only one audio driver and codec can be supported on a + * single machine. * * The demodulation and decoding algorithms used in this driver are * based on those developed for the TAPR DSP93 development board and the @@ -62,12 +63,16 @@ * * Fudge factors * - * Fudge flag4 causes the dubugging output described above to be + * Fudge flag4 causes the debugging output described above to be * recorded in the clockstats file. Fudge flag2 selects the audio input * port, where 0 is the mike port (default) and 1 is the line-in port. * It does not seem useful to select the compact disc player port. Fudge * flag3 enables audio monitoring of the input signal. For this purpose, * the monitor gain is set to a default value. + * + * CEVNT_BADTIME invalid date or time + * CEVNT_PROP propagation failure - no stations heard + * CEVNT_TIMEOUT timeout (see newgame() below) */ /* * General definitions. These ordinarily do not need to be changed. @@ -76,8 +81,8 @@ #define AUDIO_BUFSIZ 320 /* audio buffer size (50 ms) */ #define PRECISION (-10) /* precision assumed (about 1 ms) */ #define DESCRIPTION "WWV/H Audio Demodulator/Decoder" /* WRU */ -#define SECOND 8000 /* second epoch (sample rate) (Hz) */ -#define MINUTE (SECOND * 60) /* minute epoch */ +#define WWV_SEC 8000 /* second epoch (sample rate) (Hz) */ +#define WWV_MIN (WWV_SEC * 60) /* minute epoch */ #define OFFSET 128 /* companded sample offset */ #define SIZE 256 /* decompanding table size */ #define MAXAMP 6000. /* max signal level reference */ @@ -92,6 +97,7 @@ #define TCKSIZ (TCKCYC * MS) /* tick filter size */ #define NCHAN 5 /* number of radio channels */ #define AUDIO_PHI 5e-6 /* dispersion growth factor */ +#define TBUF 128 /* max monitor line length */ /* * Tunable parameters. The DGAIN parameter can be changed to fit the @@ -102,12 +108,10 @@ * radio is not tunable, the DCHAN parameter can be changed to fit the * expected best propagation frequency: higher if further from the * transmitter, lower if nearer. The compromise value works for the US - * right coast. The FREQ_OFFSET parameter can be used as a frequency - * vernier to correct codec requency if greater than MAXFREQ. + * right coast. */ #define DCHAN 3 /* default radio channel (15 Mhz) */ #define DGAIN 5. /* subcarrier gain */ -#define FREQ_OFFSET 0. /* codec frequency correction (PPM) */ /* * General purpose status bits (status) @@ -133,6 +137,7 @@ #define FGATE 0x0010 /* frequency gate */ #define DGATE 0x0020 /* data pulse amplitude error */ #define BGATE 0x0040 /* data pulse width error */ +#define METRIC 0x0080 /* one or more stations heard */ #define LEPSEC 0x1000 /* leap minute */ /* @@ -150,10 +155,10 @@ * These bits indicate various alarm conditions, which are decoded to * form the quality character included in the timecode. */ -#define CMPERR 1 /* digit or misc bit compare error */ -#define LOWERR 2 /* low bit or digit amplitude or SNR */ -#define NINERR 4 /* less than nine digits in minute */ -#define SYNERR 8 /* not tracking second sync */ +#define CMPERR 0x1 /* digit or misc bit compare error */ +#define LOWERR 0x2 /* low bit or digit amplitude or SNR */ +#define NINERR 0x4 /* less than nine digits in minute */ +#define SYNERR 0x8 /* not tracking second sync */ /* * Watchcat timeouts (watch) @@ -196,10 +201,10 @@ * Tone frequency definitions. The increments are for 4.5-deg sine * table. */ -#define MS (SECOND / 1000) /* samples per millisecond */ -#define IN100 ((100 * 80) / SECOND) /* 100 Hz increment */ -#define IN1000 ((1000 * 80) / SECOND) /* 1000 Hz increment */ -#define IN1200 ((1200 * 80) / SECOND) /* 1200 Hz increment */ +#define MS (WWV_SEC / 1000) /* samples per millisecond */ +#define IN100 ((100 * 80) / WWV_SEC) /* 100 Hz increment */ +#define IN1000 ((1000 * 80) / WWV_SEC) /* 1000 Hz increment */ +#define IN1200 ((1200 * 80) / WWV_SEC) /* 1200 Hz increment */ /* * Acquisition and tracking time constants @@ -225,15 +230,21 @@ #define SECWAR 0x40 /* 3 leap second warning */ /* - * The on-time synchronization point for the driver is the second epoch - * sync pulse produced by the FIR matched filters. As the 5-ms delay of - * these filters is compensated, the program delay is 1.1 ms due to the - * 600-Hz IIR bandpass filter. The measured receiver delay is 4.7 ms and - * the codec delay less than 0.2 ms. The additional propagation delay - * specific to each receiver location can be programmed in the fudge - * time1 and time2 values for WWV and WWVH, respectively. + * The on-time synchronization point is the positive-going zero crossing + * of the first cycle of the 5-ms second pulse. The IIR baseband filter + * phase delay is 0.91 ms, while the receiver delay is approximately 4.7 + * ms at 1000 Hz. The fudge value -0.45 ms due to the codec and other + * causes was determined by calibrating to a PPS signal from a GPS + * receiver. The additional propagation delay specific to each receiver + * location can be programmed in the fudge time1 and time2 values for + * WWV and WWVH, respectively. + * + * The resulting offsets with a 2.4-GHz P4 running FreeBSD 6.1 are + * generally within .02 ms short-term with .02 ms jitter. The long-term + * offsets vary up to 0.3 ms due to ionosperhic layer height variations. + * The processor load due to the driver is 5.8 percent. */ -#define PDELAY (.0011 + .0047 + .0002) /* net system delay (s) */ +#define PDELAY ((.91 + 4.7 - 0.45) / 1000) /* system delay (s) */ /* * Table of sine values at 4.5-degree increments. This is used by the @@ -365,7 +376,7 @@ struct progx progx[] = { }; /* - * BCD coefficients for maximum likelihood digit decode + * BCD coefficients for maximum-likelihood digit decode */ #define P15 1. /* max positive number */ #define N15 -1. /* max negative number */ @@ -447,14 +458,13 @@ char dstcod[] = { /* * The decoding matrix consists of nine row vectors, one for each digit * of the timecode. The digits are stored from least to most significant - * order. The maximum likelihood timecode is formed from the digits - * corresponding to the maximum likelihood values reading in the + * order. The maximum-likelihood timecode is formed from the digits + * corresponding to the maximum-likelihood values reading in the * opposite order: yy ddd hh:mm. */ struct decvec { int radix; /* radix (3, 4, 6, 10) */ int digit; /* current clock digit */ - int mldigit; /* maximum likelihood digit */ int count; /* match count */ double digprb; /* max digit probability */ double digsnr; /* likelihood function (dB) */ @@ -503,6 +513,7 @@ struct wwvunit { l_fp tick; /* audio sample increment */ double phase, freq; /* logical clock phase and frequency */ double monitor; /* audio monitor point */ + double pdelay; /* propagation delay (s) */ #ifdef ICOM int fd_icom; /* ICOM file descriptor */ #endif /* ICOM */ @@ -513,7 +524,7 @@ struct wwvunit { * Audio codec variables */ double comp[SIZE]; /* decompanding table */ - int port; /* codec port */ + int port; /* codec port */ int gain; /* codec gain */ int mongain; /* codec monitor gain */ int clipcnt; /* sample clipped count */ @@ -568,32 +579,32 @@ struct wwvunit { /* * Function prototypes */ -static int wwv_start P((int, struct peer *)); -static void wwv_shutdown P((int, struct peer *)); -static void wwv_receive P((struct recvbuf *)); -static void wwv_poll P((int, struct peer *)); +static int wwv_start (int, struct peer *); +static void wwv_shutdown (int, struct peer *); +static void wwv_receive (struct recvbuf *); +static void wwv_poll (int, struct peer *); /* * More function prototypes */ -static void wwv_epoch P((struct peer *)); -static void wwv_rf P((struct peer *, double)); -static void wwv_endpoc P((struct peer *, int)); -static void wwv_rsec P((struct peer *, double)); -static void wwv_qrz P((struct peer *, struct sync *, int)); -static void wwv_corr4 P((struct peer *, struct decvec *, - double [], double [][4])); -static void wwv_gain P((struct peer *)); -static void wwv_tsec P((struct peer *)); -static int timecode P((struct wwvunit *, char *)); -static double wwv_snr P((double, double)); -static int carry P((struct decvec *)); -static int wwv_newchan P((struct peer *)); -static void wwv_newgame P((struct peer *)); -static double wwv_metric P((struct sync *)); -static void wwv_clock P((struct peer *)); +static void wwv_epoch (struct peer *); +static void wwv_rf (struct peer *, double); +static void wwv_endpoc (struct peer *, int); +static void wwv_rsec (struct peer *, double); +static void wwv_qrz (struct peer *, struct sync *, int); +static void wwv_corr4 (struct peer *, struct decvec *, + double [], double [][4]); +static void wwv_gain (struct peer *); +static void wwv_tsec (struct peer *); +static int timecode (struct wwvunit *, char *, size_t); +static double wwv_snr (double, double); +static int carry (struct decvec *); +static int wwv_newchan (struct peer *); +static void wwv_newgame (struct peer *); +static double wwv_metric (struct sync *); +static void wwv_clock (struct peer *); #ifdef ICOM -static int wwv_qsy P((struct peer *, int)); +static int wwv_qsy (struct peer *, int); #endif /* ICOM */ static double qsy[NCHAN] = {2.5, 5, 10, 15, 20}; /* frequencies (MHz) */ @@ -648,15 +659,10 @@ wwv_start( /* * Allocate and initialize unit structure */ - if (!(up = (struct wwvunit *)emalloc(sizeof(struct wwvunit)))) { - close(fd); - return (0); - } - memset(up, 0, sizeof(struct wwvunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; pp->io.clock_recv = wwv_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { @@ -664,6 +670,7 @@ wwv_start( free(up); return (0); } + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -682,10 +689,10 @@ wwv_start( for (i = 3; i < OFFSET; i++) { up->comp[i] = up->comp[i - 1] + step; up->comp[OFFSET + i] = -up->comp[i]; - if (i % 16 == 0) - step *= 2.; + if (i % 16 == 0) + step *= 2.; } - DTOLFP(1. / SECOND, &up->tick); + DTOLFP(1. / WWV_SEC, &up->tick); /* * Initialize the decoding matrix with the radix for each digit @@ -705,7 +712,9 @@ wwv_start( /* * Initialize autotune if available. Note that the ICOM select * code must be less than 128, so the high order bit can be used - * to select the line speed 0 (9600 bps) or 1 (1200 bps). + * to select the line speed 0 (9600 bps) or 1 (1200 bps). Note + * we don't complain if the ICOM device is not there; but, if it + * is, the radio better be working. */ temp = 0; #ifdef DEBUG @@ -719,25 +728,14 @@ wwv_start( else up->fd_icom = icom_init("/dev/icom", B9600, temp); - if (up->fd_icom < 0) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: %m"); - up->errflg = CEVNT_FAULT; - } } if (up->fd_icom > 0) { if (wwv_qsy(peer, DCHAN) != 0) { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: radio not found"); - up->errflg = CEVNT_FAULT; + msyslog(LOG_NOTICE, "icom: radio not found"); close(up->fd_icom); up->fd_icom = 0; } else { - NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT) - msyslog(LOG_NOTICE, - "icom: autotune enabled"); + msyslog(LOG_NOTICE, "icom: autotune enabled"); } } #endif /* ICOM */ @@ -763,7 +761,7 @@ wwv_shutdown( struct wwvunit *up; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; if (up == NULL) return; @@ -801,15 +799,15 @@ wwv_receive( int bufcnt; /* buffer counter */ l_fp ltemp; - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Main loop - read until there ain't no more. Note codec * samples are bit-inverted. */ - DTOLFP((double)rbufp->recv_length / SECOND, <emp); + DTOLFP((double)rbufp->recv_length / WWV_SEC, <emp); L_SUB(&rbufp->recv_time, <emp); up->timestamp = rbufp->recv_time; dpt = rbufp->recv_buffer; @@ -837,8 +835,7 @@ wwv_receive( * per second, which results in a frequency change of * 125 PPM. */ - up->phase += up->freq / SECOND; - up->phase += FREQ_OFFSET / 1e6; + up->phase += (up->freq + clock_codec) / WWV_SEC; if (up->phase >= .5) { up->phase -= 1.; } else if (up->phase < -.5) { @@ -883,9 +880,7 @@ wwv_poll( struct wwvunit *up; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; - if (pp->coderecv == pp->codeproc) - up->errflg = CEVNT_TIMEOUT; + up = pp->unitptr; if (up->errflg) refclock_report(peer, up->errflg); up->errflg = 0; @@ -969,18 +964,17 @@ wwv_rf( static double hsiamp; /* wwvh I tick amplitude */ static double hsqamp; /* wwvh Q tick amplitude */ - static double epobuf[SECOND]; /* second sync comb filter */ + static double epobuf[WWV_SEC]; /* second sync comb filter */ static double epomax, nxtmax; /* second sync amplitude buffer */ static int epopos; /* epoch second sync position buffer */ static int iniflg; /* initialization flag */ - int pdelay; /* propagation delay (samples) */ int epoch; /* comb filter index */ double dtemp; int i; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; if (!iniflg) { iniflg = 1; @@ -1012,7 +1006,7 @@ wwv_rf( * compensate for the radio audio response at 100 Hz. * * Matlab IIR 4th-order IIR elliptic, 150 Hz lowpass, 0.2 dB - * passband ripple, -50 dB stopband ripple. + * passband ripple, -50 dB stopband ripple, phase delay 0.97 ms. */ data = (lpf[4] = lpf[3]) * 8.360961e-01; data += (lpf[3] = lpf[2]) * -3.481740e+00; @@ -1056,7 +1050,7 @@ wwv_rf( * tones and most of the noise and voice modulation components. * * Matlab 4th-order IIR elliptic, 800-1400 Hz bandpass, 0.2 dB - * passband ripple, -50 dB stopband ripple. + * passband ripple, -50 dB stopband ripple, phase delay 0.91 ms. */ syncx = (bpf[8] = bpf[7]) * 4.897278e-01; syncx += (bpf[7] = bpf[6]) * -2.765914e+00; @@ -1097,8 +1091,8 @@ wwv_rf( * while the second counter (epoch) counts the samples in the * second. */ - up->mphase = (up->mphase + 1) % MINUTE; - epoch = up->mphase % SECOND; + up->mphase = (up->mphase + 1) % WWV_MIN; + epoch = up->mphase % WWV_SEC; /* * WWV @@ -1126,7 +1120,7 @@ wwv_rf( sp = &up->mitig[up->achan].wwv; sp->amp = sqrt(ciamp * ciamp + cqamp * cqamp) / SYNCYC; if (!(up->status & MSYNC)) - wwv_qrz(peer, sp, (int)(pp->fudgetime1 * SECOND)); + wwv_qrz(peer, sp, (int)(pp->fudgetime1 * WWV_SEC)); /* * WWVH @@ -1154,7 +1148,7 @@ wwv_rf( rp = &up->mitig[up->achan].wwvh; rp->amp = sqrt(hiamp * hiamp + hqamp * hqamp) / SYNCYC; if (!(up->status & MSYNC)) - wwv_qrz(peer, rp, (int)(pp->fudgetime2 * SECOND)); + wwv_qrz(peer, rp, (int)(pp->fudgetime2 * WWV_SEC)); jptr = (jptr + 1) % SYNSIZ; kptr = (kptr + 1) % TCKSIZ; @@ -1174,10 +1168,6 @@ wwv_rf( */ if (!wwv_newchan(peer)) up->watch = 0; -#ifdef ICOM - if (up->fd_icom > 0) - wwv_qsy(peer, up->dchan); -#endif /* ICOM */ } else { /* @@ -1186,9 +1176,9 @@ wwv_rf( * don't miss a beat. */ if (up->status & LEPSEC) { - up->mphase -= SECOND; + up->mphase -= WWV_SEC; if (up->mphase < 0) - up->mphase += MINUTE; + up->mphase += WWV_MIN; } } } @@ -1212,8 +1202,9 @@ wwv_rf( wwv_epoch(peer); } else if (up->sptr != NULL) { sp = up->sptr; - if (sp->metric >= TTHR && epoch == sp->mepoch % SECOND) { - up->rsec = (60 - sp->mepoch / SECOND) % 60; + if (sp->metric >= TTHR && epoch == sp->mepoch % WWV_SEC) + { + up->rsec = (60 - sp->mepoch / WWV_SEC) % 60; up->rphase = 0; up->status |= MSYNC; up->watch = 0; @@ -1232,18 +1223,14 @@ wwv_rf( * provides a resolution of one sample (125 us). The filters run * only if the station has been reliably determined. */ - if (up->status & SELV) { - pdelay = (int)(pp->fudgetime1 * SECOND); + if (up->status & SELV) mfsync = sqrt(csiamp * csiamp + csqamp * csqamp) / TCKCYC; - } else if (up->status & SELH) { - pdelay = (int)(pp->fudgetime2 * SECOND); + else if (up->status & SELH) mfsync = sqrt(hsiamp * hsiamp + hsqamp * hsqamp) / TCKCYC; - } else { - pdelay = 0; + else mfsync = 0; - } /* * Enhance the seconds sync pulse using a 1-s (8000-sample) comb @@ -1265,15 +1252,15 @@ wwv_rf( epopos = epoch; j = epoch - 6 * MS; if (j < 0) - j += SECOND; + j += WWV_SEC; nxtmax = fabs(epobuf[j]); } if (epoch == 0) { up->epomax = epomax; up->eposnr = wwv_snr(epomax, nxtmax); - epopos -= pdelay + TCKCYC * MS; + epopos -= TCKCYC * MS; if (epopos < 0) - epopos += SECOND; + epopos += WWV_SEC; wwv_endpoc(peer, epopos); if (!(up->status & SSYNC)) up->alarm |= SYNERR; @@ -1313,11 +1300,11 @@ wwv_qrz( { struct refclockproc *pp; struct wwvunit *up; - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ long epoch; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Find the sample with peak amplitude, which defines the minute @@ -1326,7 +1313,7 @@ wwv_qrz( */ epoch = up->mphase - pdelay - SYNSIZ; if (epoch < 0) - epoch += MINUTE; + epoch += WWV_MIN; if (sp->amp > sp->maxeng) { sp->maxeng = sp->amp; sp->pos = epoch; @@ -1343,15 +1330,15 @@ wwv_qrz( if (up->mphase == 0) { sp->synmax = sp->maxeng; sp->synsnr = wwv_snr(sp->synmax, (sp->noieng - - sp->synmax) / MINUTE); + sp->synmax) / WWV_MIN); if (sp->count == 0) sp->lastpos = sp->pos; - epoch = (sp->pos - sp->lastpos) % MINUTE; + epoch = (sp->pos - sp->lastpos) % WWV_MIN; sp->reach <<= 1; if (sp->reach & (1 << AMAX)) sp->count--; if (sp->synmax > ATHR && sp->synsnr > ASNR) { - if (abs(epoch) < AWND * MS) { + if (labs(epoch) < AWND * MS) { sp->reach |= 1; sp->count++; sp->mepoch = sp->lastpos = sp->pos; @@ -1364,11 +1351,11 @@ wwv_qrz( else sp->metric = wwv_metric(sp); if (pp->sloppyclockflag & CLK_FLAG4) { - sprintf(tbuf, - "wwv8 %04x %3d %s %04x %.0f %.0f/%.1f %4ld %4ld", + snprintf(tbuf, sizeof(tbuf), + "wwv8 %04x %3d %s %04x %.0f %.0f/%.1f %ld %ld", up->status, up->gain, sp->refid, sp->reach & 0xffff, sp->metric, sp->synmax, - sp->synsnr, sp->pos % SECOND, epoch); + sp->synsnr, sp->pos % WWV_SEC, epoch); record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG if (debug) @@ -1413,15 +1400,15 @@ wwv_endpoc( static int avgcnt; /* averaging interval counter */ static int avginc; /* averaging ratchet */ static int iniflg; /* initialization flag */ - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ double dtemp; int tmp2; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; if (!iniflg) { iniflg = 1; - memset((char *)epoch_mf, 0, sizeof(epoch_mf)); + ZERO(epoch_mf); } /* @@ -1475,7 +1462,7 @@ wwv_endpoc( * interval while the comb filter charges up and noise * dissapates.. */ - tmp2 = (tepoch - xepoch) % SECOND; + tmp2 = (tepoch - xepoch) % WWV_SEC; if (tmp2 == 0) { syncnt++; if (syncnt > SCMP && up->status & MSYNC && (up->status & @@ -1489,9 +1476,9 @@ wwv_endpoc( mepoch = xepoch; syncnt = 0; } - if ((pp->sloppyclockflag & CLK_FLAG4) && !(up->status & MSYNC)) - { - sprintf(tbuf, + if ((pp->sloppyclockflag & CLK_FLAG4) && !(up->status & + MSYNC)) { + snprintf(tbuf, sizeof(tbuf), "wwv1 %04x %3d %4d %5.0f %5.1f %5d %4d %4d %4d", up->status, up->gain, tepoch, up->epomax, up->eposnr, tmp2, avgcnt, syncnt, @@ -1551,16 +1538,16 @@ wwv_endpoc( * to zero; if it decrements to -3, the interval is halved and * the counter set to zero. */ - dtemp = (mepoch - zepoch) % SECOND; + dtemp = (mepoch - zepoch) % WWV_SEC; if (up->status & FGATE) { - if (abs(dtemp) < MAXFREQ * MINAVG) { + if (fabs(dtemp) < MAXFREQ * MINAVG) { up->freq += (dtemp / 2.) / ((mcount - zcount) * FCONST); if (up->freq > MAXFREQ) up->freq = MAXFREQ; else if (up->freq < -MAXFREQ) up->freq = -MAXFREQ; - if (abs(dtemp) < MAXFREQ * MINAVG / 2.) { + if (fabs(dtemp) < MAXFREQ * MINAVG / 2.) { if (avginc < 3) { avginc++; } else { @@ -1582,11 +1569,11 @@ wwv_endpoc( } } if (pp->sloppyclockflag & CLK_FLAG4) { - sprintf(tbuf, + snprintf(tbuf, sizeof(tbuf), "wwv2 %04x %5.0f %5.1f %5d %4d %4d %4d %4.0f %7.2f", up->status, up->epomax, up->eposnr, mepoch, up->avgint, maxrun, mcount - zcount, dtemp, - up->freq * 1e6 / SECOND); + up->freq * 1e6 / WWV_SEC); record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG if (debug) @@ -1634,7 +1621,7 @@ wwv_epoch( static double sigmin, sigzer, sigone, engmax, engmin; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Find the maximum minute sync pulse energy for both the @@ -1708,7 +1695,7 @@ wwv_epoch( * next pulse. */ up->rphase++; - if (up->mphase % SECOND == up->repoch) { + if (up->mphase % WWV_SEC == up->repoch) { up->status &= ~(DGATE | BGATE); engmin = sqrt(up->irig * up->irig + up->qrig * up->qrig); @@ -1768,14 +1755,14 @@ wwv_rsec( struct wwvunit *up; struct chan *cp; struct sync *sp, *rp; - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ int sw, arg, nsec; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; if (!iniflg) { iniflg = 1; - memset((char *)bitvec, 0, sizeof(bitvec)); + ZERO(bitvec); } /* @@ -1869,7 +1856,7 @@ wwv_rsec( } rp->metric = wwv_metric(rp); if (pp->sloppyclockflag & CLK_FLAG4) { - sprintf(tbuf, + snprintf(tbuf, sizeof(tbuf), "wwv5 %04x %3d %4d %.0f/%.1f %.0f/%.1f %s %04x %.0f %.0f/%.1f %s %04x %.0f %.0f/%.1f", up->status, up->gain, up->yepoch, up->epomax, up->eposnr, up->datsig, @@ -1887,35 +1874,28 @@ wwv_rsec( up->errcnt = up->digcnt = up->alarm = 0; /* - * We now begin the minute scan. If not yet synchronized - * to a station, restart if the units digit has not been - * found within the DATA timeout (15 m) or if not - * synchronized within the SYNCH timeout (40 m). After - * synchronizing to a station, restart if no stations - * are found within the PANIC timeout (2 days). + * If synchronized to a station, restart if no stations + * have been heard within the PANIC timeout (2 days). If + * not and the minute digit has been found, restart if + * not synchronized withing the SYNCH timeout (40 m). If + * not, restart if the unit digit has not been found + * within the DATA timeout (15 m). */ if (up->status & INSYNC) { if (up->watch > PANIC) { wwv_newgame(peer); return; } - } else { - if (!(up->status & DSYNC)) { - if (up->watch > DATA) { - wwv_newgame(peer); - return; - } - } + } else if (up->status & DSYNC) { if (up->watch > SYNCH) { wwv_newgame(peer); return; } + } else if (up->watch > DATA) { + wwv_newgame(peer); + return; } wwv_newchan(peer); -#ifdef ICOM - if (up->fd_icom > 0) - wwv_qsy(peer, up->dchan); -#endif /* ICOM */ break; /* @@ -1987,7 +1967,7 @@ wwv_rsec( /* * Save the data channel gain, then QSY to the probe channel and - * dim the seconds comb filters. The newchan() routine will + * dim the seconds comb filters. The www_newchan() routine will * light them back up. */ case MSC21: /* 58 */ @@ -2041,7 +2021,7 @@ wwv_rsec( } if ((pp->sloppyclockflag & CLK_FLAG4) && !(up->status & DSYNC)) { - sprintf(tbuf, + snprintf(tbuf, sizeof(tbuf), "wwv3 %2d %04x %3d %4d %5.0f %5.1f %5.0f %5.1f %5.0f", nsec, up->status, up->gain, up->yepoch, up->epomax, up->eposnr, up->datsig, up->datsnr, bit); @@ -2075,7 +2055,7 @@ wwv_clock( l_fp offset; /* offset in NTP seconds */ pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; if (!(up->status & SSYNC)) up->alarm |= SYNERR; if (up->digcnt < 9) @@ -2107,11 +2087,12 @@ wwv_clock( pp->disp = 0; pp->lastref = up->timestamp; refclock_process_offset(pp, offset, - up->timestamp, PDELAY); + up->timestamp, PDELAY + up->pdelay); refclock_receive(peer); } } - pp->lencode = timecode(up, pp->a_lastcode); + pp->lencode = timecode(up, pp->a_lastcode, + sizeof(pp->a_lastcode)); record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG if (debug) @@ -2122,12 +2103,12 @@ wwv_clock( /* - * wwv_corr4 - determine maximum likelihood digit + * wwv_corr4 - determine maximum-likelihood digit * * This routine correlates the received digit vector with the BCD * coefficient vectors corresponding to all valid digits at the given * position in the decoding matrix. The maximum value corresponds to the - * maximum likelihood digit, while the ratio of this value to the next + * maximum-likelihood digit, while the ratio of this value to the next * lower value determines the likelihood function. Note that, if the * digit is invalid, the likelihood vector is averaged toward a miss. */ @@ -2143,12 +2124,12 @@ wwv_corr4( struct wwvunit *up; double topmax, nxtmax; /* metrics */ double acc; /* accumulator */ - char tbuf[80]; /* monitor buffer */ + char tbuf[TBUF]; /* monitor buffer */ int mldigit; /* max likelihood digit */ int i, j; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Correlate digit vector with each BCD coefficient vector. If @@ -2176,9 +2157,9 @@ wwv_corr4( vp->digsnr = wwv_snr(topmax, nxtmax); /* - * The current maximum likelihood digit is compared to the last - * maximum likelihood digit. If different, the compare counter - * and maximum likelihood digit are reset. When the compare + * The current maximum-likelihood digit is compared to the last + * maximum-likelihood digit. If different, the compare counter + * and maximum-likelihood digit are reset. When the compare * counter reaches the BCMP threshold (3), the digit is assumed * correct. When the compare counter of all nine digits have * reached threshold, the clock is assumed correct. @@ -2188,34 +2169,31 @@ wwv_corr4( * not considered correct until all nine clock digits have * reached threshold. This is intended as eye candy, but avoids * mistakes when the signal is low and the SNR is very marginal. - * once correctly set, the maximum likelihood digit is ignored - * on the assumption the clock will always be correct unless for - * some reason it drifts to a different second. */ - vp->mldigit = mldigit; if (vp->digprb < BTHR || vp->digsnr < BSNR) { - vp->count = 0; up->status |= BGATE; } else { - up->status |= DSYNC; if (vp->digit != mldigit) { - vp->count = 0; up->alarm |= CMPERR; - if (!(up->status & INSYNC)) + if (vp->count > 0) + vp->count--; + if (vp->count == 0) vp->digit = mldigit; } else { if (vp->count < BCMP) vp->count++; - else + if (vp->count == BCMP) { + up->status |= DSYNC; up->digcnt++; + } } } if ((pp->sloppyclockflag & CLK_FLAG4) && !(up->status & INSYNC)) { - sprintf(tbuf, + snprintf(tbuf, sizeof(tbuf), "wwv4 %2d %04x %3d %4d %5.0f %2d %d %d %d %5.0f %5.1f", up->rsec - 1, up->status, up->gain, up->yepoch, - up->epomax, vp->radix, vp->digit, vp->mldigit, + up->epomax, vp->radix, vp->digit, mldigit, vp->count, vp->digprb, vp->digsnr); record_clock_stats(&peer->srcadr, tbuf); #ifdef DEBUG @@ -2244,7 +2222,7 @@ wwv_tsec( int temp; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Advance minute unit of the day. Don't propagate carries until @@ -2263,6 +2241,7 @@ wwv_tsec( temp = carry(&up->decvec[HR]); if (temp == 0) temp = carry(&up->decvec[HR + 1]); + // XXX: Does temp have an expected value here? /* * Decode the current minute and day. Set leap day if the @@ -2293,7 +2272,7 @@ wwv_tsec( if (minute != 1440) return; - minute = 0; + // minute = 0; while (carry(&up->decvec[HR]) != 0); /* advance to minute 0 */ while (carry(&up->decvec[HR + 1]) != 0); day++; @@ -2302,6 +2281,7 @@ wwv_tsec( temp = carry(&up->decvec[DA + 1]); if (temp == 0) temp = carry(&up->decvec[DA + 2]); + // XXX: Is there an expected value of temp here? /* * Roll the year if this the first day and propagate carries @@ -2310,7 +2290,7 @@ wwv_tsec( if (day != (isleap ? 365 : 366)) return; - day = 1; + // day = 1; while (carry(&up->decvec[DA]) != 1); /* advance to day 1 */ while (carry(&up->decvec[DA + 1]) != 0); while (carry(&up->decvec[DA + 2]) != 0); @@ -2326,7 +2306,7 @@ wwv_tsec( * This routine rotates a likelihood vector one position and increments * the clock digit modulo the radix. It returns the new clock digit or * zero if a carry occurred. Once synchronized, the clock digit will - * match the maximum likelihood digit corresponding to that position. + * match the maximum-likelihood digit corresponding to that position. */ static int carry( @@ -2420,16 +2400,14 @@ wwv_newchan( struct wwvunit *up; struct sync *sp, *rp; double rank, dtemp; - int i, j; + int i, j, rval; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Search all five station pairs looking for the channel with - * maximum metric. If no station is found above thresholds, tune - * to WWV on 15 MHz, set the reference ID to NONE and wait for - * hotter ions. + * maximum metric. */ sp = NULL; j = 0; @@ -2453,39 +2431,57 @@ wwv_newchan( /* * If the strongest signal is less than the MTHR threshold (13), - * we are beneath the waves, so squelch the second sync. If the - * strongest signal is greater than the threshold, tune to that - * frequency and transmitter QTH. + * we are beneath the waves, so squelch the second sync and + * advance to the next station. This makes sure all stations are + * scanned when the ions grow dim. If the strongest signal is + * greater than the threshold, tune to that frequency and + * transmitter QTH. */ + up->status &= ~(SELV | SELH); if (rank < MTHR) { up->dchan = (up->dchan + 1) % NCHAN; - up->status &= ~(SELV | SELH); - return (FALSE); + if (up->status & METRIC) { + up->status &= ~METRIC; + refclock_report(peer, CEVNT_PROP); + } + rval = FALSE; + } else { + up->dchan = j; + up->sptr = sp; + memcpy(&pp->refid, sp->refid, 4); + peer->refid = pp->refid; + up->status |= METRIC; + if (sp->select & SELV) { + up->status |= SELV; + up->pdelay = pp->fudgetime1; + } else if (sp->select & SELH) { + up->status |= SELH; + up->pdelay = pp->fudgetime2; + } else { + up->pdelay = 0; + } + rval = TRUE; } - up->dchan = j; - up->status |= SELV | SELH; - up->sptr = sp; - memcpy(&pp->refid, sp->refid, 4); - peer->refid = pp->refid; - return (TRUE); +#ifdef ICOM + if (up->fd_icom > 0) + wwv_qsy(peer, up->dchan); +#endif /* ICOM */ + return (rval); } /* * wwv_newgame - reset and start over * - * There are four conditions resulting in a new game: - * - * 1 During initial acquisition (MSYNC dark) going 6 minutes (ACQSN) - * without reliably finding the minute pulse (MSYNC lit). + * There are three conditions resulting in a new game: * - * 2 After finding the minute pulse (MSYNC lit), going 15 minutes + * 1 After finding the minute pulse (MSYNC lit), going 15 minutes * (DATA) without finding the unit seconds digit. * - * 3 After finding good data (DATA lit), going more than 40 minutes + * 2 After finding good data (DSYNC lit), going more than 40 minutes * (SYNCH) without finding station sync (INSYNC lit). * - * 4 After finding station sync (INSYNC lit), going more than 2 days + * 3 After finding station sync (INSYNC lit), going more than 2 days * (PANIC) without finding any station. */ static void @@ -2499,12 +2495,14 @@ wwv_newgame( int i; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Initialize strategic values. Note we set the leap bits * NOTINSYNC and the refid "NONE". */ + if (up->status) + up->errflg = CEVNT_TIMEOUT; peer->leap = LEAP_NOTINSYNC; up->watch = up->status = up->alarm = 0; up->avgint = MINAVG; @@ -2514,24 +2512,23 @@ wwv_newgame( /* * Initialize the station processes for audio gain, select bit, * station/frequency identifier and reference identifier. Start - * probing at the next channel after the data channel. + * probing at the strongest channel or the default channel if + * nothing heard. */ memset(up->mitig, 0, sizeof(up->mitig)); for (i = 0; i < NCHAN; i++) { cp = &up->mitig[i]; cp->gain = up->gain; cp->wwv.select = SELV; - sprintf(cp->wwv.refid, "WV%.0f", floor(qsy[i])); + snprintf(cp->wwv.refid, sizeof(cp->wwv.refid), "WV%.0f", + floor(qsy[i])); cp->wwvh.select = SELH; - sprintf(cp->wwvh.refid, "WH%.0f", floor(qsy[i])); + snprintf(cp->wwvh.refid, sizeof(cp->wwvh.refid), "WH%.0f", + floor(qsy[i])); } - up->dchan = (DCHAN + NCHAN - 1) % NCHAN;; + up->dchan = (DCHAN + NCHAN - 1) % NCHAN; wwv_newchan(peer); - up->achan = up->schan = up->dchan; -#ifdef ICOM - if (up->fd_icom > 0) - wwv_qsy(peer, up->dchan); -#endif /* ICOM */ + up->schan = up->dchan; } /* @@ -2577,7 +2574,7 @@ wwv_qsy( struct wwvunit *up; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; if (up->fd_icom > 0) { up->mitig[up->achan].gain = up->gain; rval = icom_freq(up->fd_icom, peer->ttl & 0x7f, @@ -2618,7 +2615,8 @@ wwv_qsy( static int timecode( struct wwvunit *up, /* driver structure pointer */ - char *ptr /* target string */ + char * tc, /* target string */ + size_t tcsiz /* target max chars */ ) { struct sync *sp; @@ -2643,20 +2641,23 @@ timecode( dut = up->misc & 0x7; if (!(up->misc & DUTS)) dut = -dut; - sprintf(ptr, "%c%1X", synchar, up->alarm); - sprintf(cptr, " %4d %03d %02d:%02d:%02d %c%c %+d", - year, day, hour, minute, second, leapchar, dst, dut); - strcat(ptr, cptr); + snprintf(tc, tcsiz, "%c%1X", synchar, up->alarm); + snprintf(cptr, sizeof(cptr), + " %4d %03d %02d:%02d:%02d %c%c %+d", + year, day, hour, minute, second, leapchar, dst, dut); + strlcat(tc, cptr, tcsiz); /* * Specific variable-format fields */ sp = up->sptr; - sprintf(cptr, " %d %d %s %.0f %d %.1f %d", up->watch, - up->mitig[up->dchan].gain, sp->refid, sp->metric, - up->errcnt, up->freq / SECOND * 1e6, up->avgint); - strcat(ptr, cptr); - return (strlen(ptr)); + snprintf(cptr, sizeof(cptr), " %d %d %s %.0f %d %.1f %d", + up->watch, up->mitig[up->dchan].gain, sp->refid, + sp->metric, up->errcnt, up->freq / WWV_SEC * 1e6, + up->avgint); + strlcat(tc, cptr, tcsiz); + + return strlen(tc); } @@ -2668,7 +2669,8 @@ timecode( * there are no clips, the gain is bumped up; if there are more than * MAXCLP clips (100), it is bumped down. The decoder is relatively * insensitive to amplitude, so this crudity works just peachy. The - * input port is set and the error flag is cleared, mostly to be ornery. + * routine also jiggles the input port and selectively mutes the + * monitor. */ static void wwv_gain( @@ -2679,7 +2681,7 @@ wwv_gain( struct wwvunit *up; pp = peer->procptr; - up = (struct wwvunit *)pp->unitptr; + up = pp->unitptr; /* * Apparently, the codec uses only the high order bits of the diff --git a/contrib/ntp/ntpd/refclock_wwvb.c b/contrib/ntp/ntpd/refclock_wwvb.c index 7bddd3a37..75897fcc5 100644 --- a/contrib/ntp/ntpd/refclock_wwvb.c +++ b/contrib/ntp/ntpd/refclock_wwvb.c @@ -17,6 +17,11 @@ #include #include +#ifdef HAVE_PPSAPI +#include "ppsapi_timepps.h" +#include "refclock_atom.h" +#endif /* HAVE_PPSAPI */ + /* * This driver supports the Spectracom Model 8170 and Netclock/2 WWVB * Synchronized Clocks and the Netclock/GPS Master Clock. Both the WWVB @@ -49,7 +54,7 @@ * hh:mm:ss = hours, minutes, seconds * i = synchronization flag (' ' = in synch, '?' = out of synch) * - * The alarm condition is indicated by other than ' ' at a, which occurs + * The alarm condition is indicated by other than ' ' at i, which occurs * during initial synchronization and when received signal is lost for * about ten hours. * @@ -64,7 +69,7 @@ * ddd = day of year * hh:mm:ss.fff = hours, minutes, seconds, milliseconds * - * The alarm condition is indicated by other than ' ' at a, which occurs + * The alarm condition is indicated by other than ' ' at i, which occurs * during initial synchronization and when received signal is lost for * about ten hours. The unlock condition is indicated by other than ' ' * at q. @@ -84,6 +89,16 @@ * makes no attempt to correct for the intrinsic jitter of the radio * itself, which is a known problem with the older radios. * + * PPS Signal Processing + * + * When PPS signal processing is enabled, and when the system clock has + * been set by this or another driver and the PPS signal offset is + * within 0.4 s of the system clock offset, the PPS signal replaces the + * timecode for as long as the PPS signal is active. If for some reason + * the PPS signal fails for one or more poll intervals, the driver + * reverts to the timecode. If the timecode fails for one or more poll + * intervals, the PPS signal is disconnected. + * * Fudge Factors * * This driver can retrieve a table of quality data maintained @@ -100,20 +115,28 @@ #define DEVICE "/dev/wwvb%d" /* device name and unit */ #define SPEED232 B9600 /* uart speed (9600 baud) */ #define PRECISION (-13) /* precision assumed (about 100 us) */ +#define PPS_PRECISION (-13) /* precision assumed (about 100 us) */ #define REFID "WWVB" /* reference ID */ #define DESCRIPTION "Spectracom WWVB/GPS Receiver" /* WRU */ #define LENWWVB0 22 /* format 0 timecode length */ -#define LENWWVB1 22 /* format 1 timecode length */ #define LENWWVB2 24 /* format 2 timecode length */ -#define LENWWVB3 29 /* format 3 timecode length */ +#define LENWWVB3 29 /* format 3 timecode length */ #define MONLIN 15 /* number of monitoring lines */ /* * WWVB unit control structure */ struct wwvbunit { - l_fp laststamp; /* last receive timestamp */ +#ifdef HAVE_PPSAPI + struct refclock_atom atom; /* PPSAPI structure */ + int ppsapi_tried; /* attempt PPSAPI once */ + int ppsapi_lit; /* time_pps_create() worked */ + int tcount; /* timecode sample counter */ + int pcount; /* PPS sample counter */ +#endif /* HAVE_PPSAPI */ + l_fp laststamp; /* last timestamp */ + int prev_eol_cr; /* was last EOL (not )? */ u_char lasthour; /* last hour (for monitor) */ u_char linect; /* count ignored lines (for monitor */ }; @@ -121,11 +144,18 @@ struct wwvbunit { /* * Function prototypes */ -static int wwvb_start P((int, struct peer *)); -static void wwvb_shutdown P((int, struct peer *)); -static void wwvb_receive P((struct recvbuf *)); -static void wwvb_poll P((int, struct peer *)); -static void wwvb_timer P((int, struct peer *)); +static int wwvb_start (int, struct peer *); +static void wwvb_shutdown (int, struct peer *); +static void wwvb_receive (struct recvbuf *); +static void wwvb_poll (int, struct peer *); +static void wwvb_timer (int, struct peer *); +#ifdef HAVE_PPSAPI +static void wwvb_control (int, const struct refclockstat *, + struct refclockstat *, struct peer *); +#define WWVB_CONTROL wwvb_control +#else +#define WWVB_CONTROL noentry +#endif /* HAVE_PPSAPI */ /* * Transfer vector @@ -134,7 +164,7 @@ struct refclock refclock_wwvb = { wwvb_start, /* start up driver */ wwvb_shutdown, /* shut down driver */ wwvb_poll, /* transmit poll message */ - noentry, /* not used (old wwvb_control) */ + WWVB_CONTROL, /* fudge set/change notification */ noentry, /* initialize driver (not used) */ noentry, /* not used (old wwvb_buginfo) */ wwvb_timer /* called once per second */ @@ -158,37 +188,34 @@ wwvb_start( /* * Open serial port. Use CLK line discipline, if available. */ - sprintf(device, DEVICE, unit); - if (!(fd = refclock_open(device, SPEED232, LDISC_CLK))) + snprintf(device, sizeof(device), DEVICE, unit); + fd = refclock_open(device, SPEED232, LDISC_CLK); + if (fd <= 0) return (0); /* * Allocate and initialize unit structure */ - if (!(up = (struct wwvbunit *) - emalloc(sizeof(struct wwvbunit)))) { - close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct wwvbunit)); + up = emalloc_zero(sizeof(*up)); pp = peer->procptr; - pp->unitptr = (caddr_t)up; pp->io.clock_recv = wwvb_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { close(fd); + pp->io.fd = -1; free(up); return (0); } + pp->unitptr = up; /* * Initialize miscellaneous variables */ peer->precision = PRECISION; pp->clockdesc = DESCRIPTION; - memcpy((char *)&pp->refid, REFID, 4); + memcpy(&pp->refid, REFID, 4); return (1); } @@ -202,13 +229,15 @@ wwvb_shutdown( struct peer *peer ) { - register struct wwvbunit *up; - struct refclockproc *pp; + struct refclockproc * pp; + struct wwvbunit * up; pp = peer->procptr; - up = (struct wwvbunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (-1 != pp->io.fd) + io_closeclock(&pp->io); + if (NULL != up) + free(up); } @@ -237,9 +266,9 @@ wwvb_receive( /* * Initialize pointers and read the timecode and timestamp */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct wwvbunit *)pp->unitptr; + up = pp->unitptr; temp = refclock_gtlin(rbufp, pp->a_lastcode, BMAX, &trtmp); /* @@ -251,13 +280,37 @@ wwvb_receive( * reading precision is only to the millisecond. Thus, unless * you have a PPS gadget and don't have to have the year, format * 0 provides the lowest jitter. + * Save the timestamp of each in up->laststamp. Lines with + * no characters occur for every , and for some s when + * format 0 is used. Format 0 starts and ends each cycle with a + * pair, format 2 starts each cycle with its only pair. + * The preceding is the on-time character for both formats. + * The timestamp provided with non-empty lines corresponds to + * the following the timecode, which is ultimately not used + * with format 0 and is used for the following timecode for + * format 2. */ if (temp == 0) { - up->laststamp = trtmp; + if (up->prev_eol_cr) { + DPRINTF(2, ("wwvb: @ %s\n", + prettydate(&trtmp))); + } else { + up->laststamp = trtmp; + DPRINTF(2, ("wwvb: @ %s\n", + prettydate(&trtmp))); + } + up->prev_eol_cr = !up->prev_eol_cr; return; } pp->lencode = temp; pp->lastrec = up->laststamp; + up->laststamp = trtmp; + up->prev_eol_cr = TRUE; + DPRINTF(2, ("wwvb: code @ %s\n" + " using %s minus one char\n", + prettydate(&trtmp), prettydate(&pp->lastrec))); + if (L_ISZERO(&pp->lastrec)) + return; /* * We get down to business, check the timecode format and decode @@ -277,9 +330,11 @@ wwvb_receive( if (sscanf(pp->a_lastcode, "%c %3d %2d:%2d:%2d%c%cTZ=%2d", &syncchar, &pp->day, &pp->hour, &pp->minute, - &pp->second, &tmpchar, &dstchar, &tz) == 8) + &pp->second, &tmpchar, &dstchar, &tz) == 8) { pp->nsec = 0; break; + } + goto bad_format; case LENWWVB2: @@ -289,14 +344,19 @@ wwvb_receive( "%c%c %2d %3d %2d:%2d:%2d.%3ld %c", &syncchar, &qualchar, &pp->year, &pp->day, &pp->hour, &pp->minute, &pp->second, &pp->nsec, - &leapchar) == 9) + &leapchar) == 9) { pp->nsec *= 1000000; break; + } + goto bad_format; case LENWWVB3: - /* + /* * Timecode format 3: "0003I yyyymmdd hhmmss+0000SL#" + * WARNING: Undocumented, and the on-time character # is + * not yet handled correctly by this driver. It may be + * as simple as compensating for an additional 1/960 s. */ if (sscanf(pp->a_lastcode, "0003%c %4d%2d%2d %2d%2d%2d+0000%c%c", @@ -307,8 +367,10 @@ wwvb_receive( pp->nsec = 0; break; } + goto bad_format; default: + bad_format: /* * Unknown format: If dumping internal table, record @@ -333,28 +395,28 @@ wwvb_receive( */ switch (qualchar) { - case ' ': + case ' ': pp->disp = .001; pp->lastref = pp->lastrec; break; - case 'A': + case 'A': pp->disp = .01; break; - case 'B': + case 'B': pp->disp = .1; break; - case 'C': + case 'C': pp->disp = .5; break; - case 'D': + case 'D': pp->disp = MAXDISPERSE; break; - default: + default: pp->disp = MAXDISPERSE; refclock_report(peer, CEVNT_BADREPLY); break; @@ -368,12 +430,16 @@ wwvb_receive( /* * Process the new sample in the median filter and determine the - * timecode timestamp. + * timecode timestamp, but only if the PPS is not in control. */ - if (!refclock_process(pp)) +#ifdef HAVE_PPSAPI + up->tcount++; + if (peer->flags & FLAG_PPS) + return; + +#endif /* HAVE_PPSAPI */ + if (!refclock_process_f(pp, pp->fudgetime2)) refclock_report(peer, CEVNT_BADTIME); - if (peer->disp > MAXDISTANCE) - refclock_receive(peer); } @@ -389,6 +455,9 @@ wwvb_timer( register struct wwvbunit *up; struct refclockproc *pp; char pollchar; /* character sent to clock */ +#ifdef DEBUG + l_fp now; +#endif /* * Time to poll the clock. The Spectracom clock responds to a @@ -398,13 +467,26 @@ wwvb_timer( * the clock; all others just listen in. */ pp = peer->procptr; - up = (struct wwvbunit *)pp->unitptr; + up = pp->unitptr; if (up->linect > 0) pollchar = 'R'; else pollchar = 'T'; if (write(pp->io.fd, &pollchar, 1) != 1) refclock_report(peer, CEVNT_FAULT); +#ifdef DEBUG + get_systime(&now); + if (debug) + printf("%c poll at %s\n", pollchar, prettydate(&now)); +#endif +#ifdef HAVE_PPSAPI + if (up->ppsapi_lit && + refclock_pps(peer, &up->atom, pp->sloppyclockflag) > 0) { + up->pcount++, + peer->flags |= FLAG_PPS; + peer->precision = PPS_PRECISION; + } +#endif /* HAVE_PPSAPI */ } @@ -425,7 +507,7 @@ wwvb_poll( * are received, declare a timeout and keep going. */ pp = peer->procptr; - up = (struct wwvbunit *)pp->unitptr; + up = pp->unitptr; pp->polls++; /* @@ -435,16 +517,29 @@ wwvb_poll( if (pp->sloppyclockflag & CLK_FLAG4 && pp->hour < (int)up->lasthour) up->linect = MONLIN; - up->lasthour = pp->hour; + up->lasthour = (u_char)pp->hour; /* * Process median filter samples. If none received, declare a * timeout and keep going. */ +#ifdef HAVE_PPSAPI + if (up->pcount == 0) { + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + } + if (up->tcount == 0) { + pp->coderecv = pp->codeproc; + refclock_report(peer, CEVNT_TIMEOUT); + return; + } + up->pcount = up->tcount = 0; +#else /* HAVE_PPSAPI */ if (pp->coderecv == pp->codeproc) { refclock_report(peer, CEVNT_TIMEOUT); return; } +#endif /* HAVE_PPSAPI */ refclock_receive(peer); record_clock_stats(&peer->srcadr, pp->a_lastcode); #ifdef DEBUG @@ -454,6 +549,55 @@ wwvb_poll( #endif } + +/* + * wwvb_control - fudge parameters have been set or changed + */ +#ifdef HAVE_PPSAPI +static void +wwvb_control( + int unit, + const struct refclockstat *in_st, + struct refclockstat *out_st, + struct peer *peer + ) +{ + register struct wwvbunit *up; + struct refclockproc *pp; + + pp = peer->procptr; + up = pp->unitptr; + + if (!(pp->sloppyclockflag & CLK_FLAG1)) { + if (!up->ppsapi_tried) + return; + up->ppsapi_tried = 0; + if (!up->ppsapi_lit) + return; + peer->flags &= ~FLAG_PPS; + peer->precision = PRECISION; + time_pps_destroy(up->atom.handle); + up->atom.handle = 0; + up->ppsapi_lit = 0; + return; + } + + if (up->ppsapi_tried) + return; + /* + * Light up the PPSAPI interface. + */ + up->ppsapi_tried = 1; + if (refclock_ppsapi(pp->io.fd, &up->atom)) { + up->ppsapi_lit = 1; + return; + } + + msyslog(LOG_WARNING, "%s flag1 1 but PPSAPI fails", + refnumtoa(&peer->srcadr)); +} +#endif /* HAVE_PPSAPI */ + #else int refclock_wwvb_bs; #endif /* REFCLOCK */ diff --git a/contrib/ntp/ntpd/refclock_zyfer.c b/contrib/ntp/ntpd/refclock_zyfer.c index 44f2c4d35..7b79da32c 100644 --- a/contrib/ntp/ntpd/refclock_zyfer.c +++ b/contrib/ntp/ntpd/refclock_zyfer.c @@ -19,7 +19,9 @@ #include #include -#ifdef HAVE_SYS_TERMIOS_H +#if defined(HAVE_TERMIOS_H) +# include +#elif defined(HAVE_SYS_TERMIOS_H) # include #endif #ifdef HAVE_SYS_PPSCLOCK_H @@ -97,10 +99,10 @@ struct zyferunit { /* * Function prototypes */ -static int zyfer_start P((int, struct peer *)); -static void zyfer_shutdown P((int, struct peer *)); -static void zyfer_receive P((struct recvbuf *)); -static void zyfer_poll P((int, struct peer *)); +static int zyfer_start (int, struct peer *); +static void zyfer_shutdown (int, struct peer *); +static void zyfer_receive (struct recvbuf *); +static void zyfer_poll (int, struct peer *); /* * Transfer vector @@ -134,32 +136,30 @@ zyfer_start( * Open serial port. * Something like LDISC_ACTS that looked for ! would be nice... */ - (void)sprintf(device, DEVICE, unit); - if ( !(fd = refclock_open(device, SPEED232, LDISC_RAW)) ) - return (0); + snprintf(device, sizeof(device), DEVICE, unit); + fd = refclock_open(device, SPEED232, LDISC_RAW); + if (fd <= 0) + return (0); msyslog(LOG_NOTICE, "zyfer(%d) fd: %d dev <%s>", unit, fd, device); /* * Allocate and initialize unit structure */ - if (!(up = (struct zyferunit *) - emalloc(sizeof(struct zyferunit)))) { - (void) close(fd); - return (0); - } - memset((char *)up, 0, sizeof(struct zyferunit)); + up = emalloc(sizeof(struct zyferunit)); + memset(up, 0, sizeof(struct zyferunit)); pp = peer->procptr; pp->io.clock_recv = zyfer_receive; - pp->io.srcclock = (caddr_t)peer; + pp->io.srcclock = peer; pp->io.datalen = 0; pp->io.fd = fd; if (!io_addclock(&pp->io)) { - (void) close(fd); + close(fd); + pp->io.fd = -1; free(up); return (0); } - pp->unitptr = (caddr_t)up; + pp->unitptr = up; /* * Initialize miscellaneous variables @@ -187,9 +187,11 @@ zyfer_shutdown( struct refclockproc *pp; pp = peer->procptr; - up = (struct zyferunit *)pp->unitptr; - io_closeclock(&pp->io); - free(up); + up = pp->unitptr; + if (pp->io.fd != -1) + io_closeclock(&pp->io); + if (up != NULL) + free(up); } @@ -208,20 +210,10 @@ zyfer_receive( int tfom; /* Time Figure Of Merit */ int omode; /* Operation mode */ u_char *p; -#ifdef PPS - struct ppsclockev ppsev; - int request; -#ifdef HAVE_CIOGETEV - request = CIOGETEV; -#endif -#ifdef HAVE_TIOCGPPSEV - request = TIOCGPPSEV; -#endif -#endif /* PPS */ - peer = (struct peer *)rbufp->recv_srcclock; + peer = rbufp->recv_peer; pp = peer->procptr; - up = (struct zyferunit *)pp->unitptr; + up = pp->unitptr; p = (u_char *) &rbufp->recv_space; /* * If lencode is 0: @@ -290,14 +282,7 @@ zyfer_receive( pp->leap = LEAP_NOTINSYNC; return; } -#ifdef PPS - if(ioctl(fdpps,request,(caddr_t) &ppsev) >=0) { - ppsev.tv.tv_sec += (u_int32) JAN_1970; - TVTOTS(&ppsev.tv,&up->tstamp); - } - /* record the last ppsclock event time stamp */ - pp->lastrec = up->tstamp; -#endif /* PPS */ + if (!refclock_process(pp)) { refclock_report(peer, CEVNT_BADTIME); return; @@ -332,7 +317,7 @@ zyfer_poll( * side to capture a sample and check for timeouts. */ pp = peer->procptr; - up = (struct zyferunit *)pp->unitptr; + up = pp->unitptr; if (!up->pollcnt) refclock_report(peer, CEVNT_TIMEOUT); else diff --git a/contrib/ntp/ntpdate/Makefile.am b/contrib/ntp/ntpdate/Makefile.am index 3372f49f2..774cf2978 100644 --- a/contrib/ntp/ntpdate/Makefile.am +++ b/contrib/ntp/ntpdate/Makefile.am @@ -1,28 +1,40 @@ -#AUTOMAKE_OPTIONS= ../util/ansi2knr +NULL = -bindir= ${exec_prefix}/${BINSUBDIR} -#bin_PROGRAMS= ntpdate ntptimeset -bin_PROGRAMS= ntpdate -EXTRA_PROGRAMS= ntptimeset +BUILT_SOURCES = +CLEANFILES = + +bin_PROGRAMS = $(NTPDATE_DB) +libexec_PROGRAMS = $(NTPDATE_DL) +sbin_PROGRAMS = $(NTPDATE_DS) + +EXTRA_PROGRAMS = ntpdate + +AM_CFLAGS = $(CFLAGS_NTP) + +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +AM_LDFLAGS = $(LDFLAGS_NTP) -ntptimeset_SOURCES= ntptimeset.c ntptime_config.c -AM_CPPFLAGS= -I$(top_srcdir)/include # LDADD might need RESLIB and ADJLIB -LDADD= version.o ../libntp/libntp.a +LDADD = version.o ../libntp/libntp.a +ntpdate_LDADD = $(LDADD) $(LDADD_LIBNTP) $(PTHREAD_LIBS) $(LIBOPTS_LDADD) +ntpdate_LDADD += $(LIBM) $(LDADD_NTP) DISTCLEANFILES= .version version.c stamp-v noinst_HEADERS= ntpdate.h -ETAGS_ARGS= Makefile.am $(PROGRAMS): $(LDADD) -../libntp/libntp.a: - cd ../libntp && $(MAKE) - -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev -version.o: $(ntpdate_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpdate - $(COMPILE) -c version.c +version.c: $(ntpdate_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpdate + +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o -include ../bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/ntpdate/Makefile.in b/contrib/ntp/ntpdate/Makefile.in index d127815b0..79f52514e 100644 --- a/contrib/ntp/ntpdate/Makefile.in +++ b/contrib/ntp/ntpdate/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -15,14 +14,67 @@ @SET_MAKE@ -#AUTOMAKE_OPTIONS= ../util/ansi2knr - # we traditionally installed software in bindir, while it should have gone # in sbindir. Now that we offer a choice, look in the "other" installation # subdir to warn folks if there is another version there. VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -41,89 +93,203 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -bin_PROGRAMS = ntpdate$(EXEEXT) -EXTRA_PROGRAMS = ntptimeset$(EXEEXT) -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/../bincheck.mf \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in +EXTRA_PROGRAMS = ntpdate$(EXEEXT) subdir = ntpdate ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" -PROGRAMS = $(bin_PROGRAMS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" +PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(sbin_PROGRAMS) ntpdate_SOURCES = ntpdate.c ntpdate_OBJECTS = ntpdate.$(OBJEXT) -ntpdate_LDADD = $(LDADD) -ntpdate_DEPENDENCIES = version.o ../libntp/libntp.a -am_ntptimeset_OBJECTS = ntptimeset.$(OBJEXT) ntptime_config.$(OBJEXT) -ntptimeset_OBJECTS = $(am_ntptimeset_OBJECTS) -ntptimeset_LDADD = $(LDADD) -ntptimeset_DEPENDENCIES = version.o ../libntp/libntp.a +am__DEPENDENCIES_1 = +ntpdate_DEPENDENCIES = $(LDADD) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ -SOURCES = ntpdate.c $(ntptimeset_SOURCES) -DIST_SOURCES = ntpdate.c $(ntptimeset_SOURCES) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = ntpdate.c +DIST_SOURCES = ntpdate.c +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/bincheck.mf \ + $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf \ + $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -131,8 +297,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -142,15 +311,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -158,29 +388,65 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -221,18 +487,31 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -ntptimeset_SOURCES = ntptimeset.c ntptime_config.c -AM_CPPFLAGS = -I$(top_srcdir)/include +NULL = +BUILT_SOURCES = check-libntp .deps-ver +CLEANFILES = check-libntp .deps-ver +bin_PROGRAMS = $(NTPDATE_DB) +libexec_PROGRAMS = $(NTPDATE_DL) +sbin_PROGRAMS = $(NTPDATE_DS) +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(CPPFLAGS_NTP) +AM_LDFLAGS = $(LDFLAGS_NTP) + # LDADD might need RESLIB and ADJLIB LDADD = version.o ../libntp/libntp.a +ntpdate_LDADD = $(LDADD) $(LDADD_LIBNTP) $(PTHREAD_LIBS) \ + $(LIBOPTS_LDADD) $(LIBM) $(LDADD_NTP) DISTCLEANFILES = .version version.c stamp-v noinst_HEADERS = ntpdate.h -ETAGS_ARGS = Makefile.am -all: all-am +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -244,7 +523,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__con echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ntpdate/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign ntpdate/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -253,6 +531,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/bincheck.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -264,14 +543,19 @@ $(ACLOCAL_M4): $(am__aclocal_m4_deps) $(am__aclocal_m4_deps): install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p || test -f $$p1; \ - then echo "$$p"; echo "$$p"; else :; fi; \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ - sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ @@ -292,7 +576,8 @@ uninstall-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' `; \ + -e 's/$$/$(EXEEXT)/' \ + `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files @@ -305,12 +590,108 @@ clean-binPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -ntpdate$(EXEEXT): $(ntpdate_OBJECTS) $(ntpdate_DEPENDENCIES) +install-libexecPROGRAMS: $(libexec_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(libexecdir)" && rm -f $$files + +clean-libexecPROGRAMS: + @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +ntpdate$(EXEEXT): $(ntpdate_OBJECTS) $(ntpdate_DEPENDENCIES) $(EXTRA_ntpdate_DEPENDENCIES) @rm -f ntpdate$(EXEEXT) - $(LINK) $(ntpdate_OBJECTS) $(ntpdate_LDADD) $(LIBS) -ntptimeset$(EXEEXT): $(ntptimeset_OBJECTS) $(ntptimeset_DEPENDENCIES) - @rm -f ntptimeset$(EXEEXT) - $(LINK) $(ntptimeset_OBJECTS) $(ntptimeset_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(ntpdate_OBJECTS) $(ntpdate_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) @@ -319,29 +700,27 @@ distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdate.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntptime_config.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntptimeset.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo @@ -349,26 +728,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -380,15 +748,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -397,6 +761,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -432,13 +811,15 @@ distdir: $(DISTFILES) fi; \ done check-am: all-am -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) $(HEADERS) installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -448,13 +829,19 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -464,9 +851,11 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -492,7 +881,8 @@ install-dvi: install-dvi-am install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-libexecPROGRAMS \ + install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -533,49 +923,119 @@ ps: ps-am ps-am: -uninstall-am: uninstall-binPROGRAMS - -.MAKE: install-am install-exec-am install-strip +uninstall-am: uninstall-binPROGRAMS uninstall-libexecPROGRAMS \ + uninstall-sbinPROGRAMS + +.MAKE: all check install install-am install-exec-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ + clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS cscopelist-am ctags ctags-am \ + distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-binPROGRAMS \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-exec-hook install-html \ + install-html-am install-info install-info-am \ + install-libexecPROGRAMS install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-sbinPROGRAMS install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-libexecPROGRAMS uninstall-sbinPROGRAMS -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am uninstall-binPROGRAMS +.PRECIOUS: Makefile $(PROGRAMS): $(LDADD) -../libntp/libntp.a: - cd ../libntp && $(MAKE) +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +version.c: $(ntpdate_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpdate -version.o: $(ntpdate_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpdate - $(COMPILE) -c version.c +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ - || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ - test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ + done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ done # +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/contrib/ntp/ntpdate/ntpdate.c b/contrib/ntp/ntpdate/ntpdate.c index a0a90cebf..9831929c4 100644 --- a/contrib/ntp/ntpdate/ntpdate.c +++ b/contrib/ntp/ntpdate/ntpdate.c @@ -14,15 +14,14 @@ #include "ntp_fp.h" #include "ntp.h" #include "ntp_io.h" -#include "ntp_unixtime.h" +#include "timevalops.h" #include "ntpdate.h" #include "ntp_string.h" #include "ntp_syslog.h" #include "ntp_select.h" #include "ntp_stdlib.h" +#include -/* Don't include ISC's version of IPv6 variables and structures */ -#define ISC_IPV6_H 1 #include "isc/net.h" #include "isc/result.h" #include "isc/sockaddr.h" @@ -37,19 +36,15 @@ #ifdef HAVE_POLL_H # include #endif -#ifndef SYS_WINNT -# ifdef HAVE_SYS_SIGNAL_H -# include -# else -# include -# endif -# ifdef HAVE_SYS_IOCTL_H -# include -# endif -#endif /* SYS_WINNT */ +#ifdef HAVE_SYS_SIGNAL_H +# include +#endif +#ifdef HAVE_SYS_IOCTL_H +# include +#endif #ifdef HAVE_SYS_RESOURCE_H # include -#endif /* HAVE_SYS_RESOURCE_H */ +#endif #include @@ -63,9 +58,9 @@ struct timeval timeout = {0,0}; #elif defined(SYS_WINNT) /* * Windows does not abort a select select call if SIGALRM goes off - * so a 200 ms timeout is needed + * so a 200 ms timeout is needed (TIMER_HZ is 5). */ -struct timeval timeout = {0,1000000/TIMER_HZ}; +struct sock_timeval timeout = {0,1000000/TIMER_HZ}; #else struct timeval timeout = {60,0}; #endif @@ -77,9 +72,6 @@ struct timeval timeout = {60,0}; #include "recvbuff.h" #ifdef SYS_WINNT -#define EPROTONOSUPPORT WSAEPROTONOSUPPORT -#define EAFNOSUPPORT WSAEAFNOSUPPORT -#define EPFNOSUPPORT WSAEPFNOSUPPORT #define TARGET_RESOLUTION 1 /* Try for 1-millisecond accuracy on Windows NT timers. */ #pragma comment(lib, "winmm") @@ -96,7 +88,7 @@ UINT wTimerRes; # define NTPDATE_PRIO (100) #endif -#if defined(HAVE_TIMER_SETTIME) || defined (HAVE_TIMER_CREATE) +#ifdef HAVE_TIMER_CREATE /* POSIX TIMERS - vxWorks doesn't have itimer - casey */ static timer_t ntpdate_timerid; #endif @@ -117,19 +109,14 @@ static timer_t ntpdate_timerid; */ s_char sys_precision; /* local clock precision (log2 s) */ -/* - * Debugging flag - */ -volatile int debug = 0; - /* * File descriptor masks etc. for call to select */ int ai_fam_templ; -int nbsock; /* the number of sockets used */ +int nbsock; /* the number of sockets used */ SOCKET fd[MAX_AF]; -int fd_family[MAX_AF]; /* to remember the socket family */ +int fd_family[MAX_AF]; /* to remember the socket family */ #ifdef HAVE_POLL_H struct pollfd fdmask[MAX_AF]; #else @@ -162,7 +149,7 @@ int unpriv_port = 0; /* * Program name. */ -char *progname; +char const *progname; /* * Systemwide parameters and flags @@ -211,35 +198,34 @@ int verbose = 0; int always_step = 0; int never_step = 0; -int ntpdatemain P((int, char **)); - -static void transmit P((struct server *)); -static void receive P((struct recvbuf *)); -static void server_data P((struct server *, s_fp, l_fp *, u_fp)); -static void clock_filter P((struct server *)); -static struct server *clock_select P((void)); -static int clock_adjust P((void)); -static void addserver P((char *)); -static struct server *findserver P((struct sockaddr_storage *)); -void timer P((void)); -static void init_alarm P((void)); +int ntpdatemain (int, char **); + +static void transmit (struct server *); +static void receive (struct recvbuf *); +static void server_data (struct server *, s_fp, l_fp *, u_fp); +static void clock_filter (struct server *); +static struct server *clock_select (void); +static int clock_adjust (void); +static void addserver (char *); +static struct server *findserver (sockaddr_u *); + void timer (void); +static void init_alarm (void); #ifndef SYS_WINNT -static RETSIGTYPE alarming P((int)); +static RETSIGTYPE alarming (int); #endif /* SYS_WINNT */ -static void init_io P((void)); -static void sendpkt P((struct sockaddr_storage *, struct pkt *, int)); -void input_handler P((void)); +static void init_io (void); +static void sendpkt (sockaddr_u *, struct pkt *, int); +void input_handler (void); -static int l_adj_systime P((l_fp *)); -static int l_step_systime P((l_fp *)); +static int l_adj_systime (l_fp *); +static int l_step_systime (l_fp *); -static void printserver P((struct server *, FILE *)); +static void printserver (struct server *, FILE *); #ifdef SYS_WINNT int on = 1; WORD wVersionRequested; WSADATA wsaData; -HANDLE TimerThreadHandle = NULL; #endif /* SYS_WINNT */ #ifdef NO_MAIN_ALLOWED @@ -299,7 +285,7 @@ void clear_globals() #endif #ifdef HAVE_NETINFO -static ni_namelist *getnetinfoservers P((void)); +static ni_namelist *getnetinfoservers (void); #endif /* @@ -335,31 +321,23 @@ ntpdatemain ( ni_namelist *netinfoservers; #endif #ifdef SYS_WINNT - HANDLE process_handle; - - wVersionRequested = MAKEWORD(1,1); - if (WSAStartup(wVersionRequested, &wsaData)) { - netsyslog(LOG_ERR, "No useable winsock.dll: %m"); - exit(1); - } - key_file = key_file_storage; if (!ExpandEnvironmentStrings(KEYFILE, key_file, MAX_PATH)) - { - msyslog(LOG_ERR, "ExpandEnvironmentStrings(KEYFILE) failed: %m\n"); - } + msyslog(LOG_ERR, "ExpandEnvironmentStrings(KEYFILE) failed: %m"); + + ssl_applink(); #endif /* SYS_WINNT */ #ifdef NO_MAIN_ALLOWED clear_globals(); #endif + init_lib(); /* sets up ipv4_works, ipv6_works */ - /* Check to see if we have IPv6. Otherwise force the -4 flag */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) { + /* Check to see if we have IPv6. Otherwise default to IPv4 */ + if (!ipv6_works) ai_fam_templ = AF_INET; - } errflg = 0; progname = argv[0]; @@ -436,8 +414,7 @@ ntpdatemain ( } else { sys_timeout = ((LFPTOFP(&tmp) * TIMER_HZ) + 0x8000) >> 16; - if (sys_timeout == 0) - sys_timeout = 1; + sys_timeout = max(sys_timeout, MINTIMEOUT); } break; case 'v': @@ -463,12 +440,7 @@ ntpdatemain ( if (debug || simple_query) { #ifdef HAVE_SETVBUF static char buf[BUFSIZ]; -#ifdef SYS_WINNT - /* Win32 does not implement line buffering */ - setvbuf(stdout, NULL, _IONBF, BUFSIZ); -#else setvbuf(stdout, buf, _IOLBF, BUFSIZ); -#endif /* SYS_WINNT */ #else setlinebuf(stdout); #endif @@ -561,13 +533,6 @@ ntpdatemain ( #if defined(HAVE_BSD_NICE) (void) setpriority(PRIO_PROCESS, 0, NTPDATE_PRIO); #endif -#ifdef SYS_WINNT - process_handle = GetCurrentProcess(); - if (!SetPriorityClass(process_handle, (DWORD) REALTIME_PRIORITY_CLASS)) { - msyslog(LOG_ERR, "SetPriorityClass failed: %m"); - } -#endif /* SYS_WINNT */ - initializing = 0; @@ -608,7 +573,7 @@ ntpdatemain ( #else if (WSAGetLastError() != WSAEINTR) #endif - netsyslog(LOG_ERR, + msyslog(LOG_ERR, #ifdef HAVE_POLL_H "poll() error: %m" #else @@ -617,7 +582,7 @@ ntpdatemain ( ); } else if (errno != 0) { #ifndef SYS_VXWORKS - netsyslog(LOG_DEBUG, + msyslog(LOG_DEBUG, #ifdef HAVE_POLL_H "poll(): nfound = %d, error: %m", #else @@ -687,7 +652,7 @@ transmit( struct pkt xpkt; if (debug) - printf("transmit(%s)\n", stoa(&(server->srcadr))); + printf("transmit(%s)\n", stoa(&server->srcadr)); if (server->filter_nextpt < server->xmtcnt) { l_fp ts; @@ -719,7 +684,7 @@ transmit( xpkt.ppoll = NTP_MINPOLL; xpkt.precision = NTPDATE_PRECISION; xpkt.rootdelay = htonl(NTPDATE_DISTANCE); - xpkt.rootdispersion = htonl(NTPDATE_DISP); + xpkt.rootdisp = htonl(NTPDATE_DISP); xpkt.refid = htonl(NTPDATE_REFID); L_CLR(&xpkt.reftime); L_CLR(&xpkt.org); @@ -738,18 +703,18 @@ transmit( L_ADDUF(&server->xmt, sys_authdelay); HTONL_FP(&server->xmt, &xpkt.xmt); len = authencrypt(sys_authkey, (u_int32 *)&xpkt, LEN_PKT_NOMAC); - sendpkt(&(server->srcadr), &xpkt, (int)(LEN_PKT_NOMAC + len)); + sendpkt(&server->srcadr, &xpkt, (int)(LEN_PKT_NOMAC + len)); if (debug > 1) printf("transmit auth to %s\n", - stoa(&(server->srcadr))); + stoa(&server->srcadr)); } else { get_systime(&(server->xmt)); HTONL_FP(&server->xmt, &xpkt.xmt); - sendpkt(&(server->srcadr), &xpkt, LEN_PKT_NOMAC); + sendpkt(&server->srcadr, &xpkt, LEN_PKT_NOMAC); if (debug > 1) - printf("transmit to %s\n", stoa(&(server->srcadr))); + printf("transmit to %s\n", stoa(&server->srcadr)); } /* @@ -786,7 +751,7 @@ receive( */ if (rbufp->recv_length == LEN_PKT_NOMAC) has_mac = 0; - else if (rbufp->recv_length >= LEN_PKT_NOMAC) + else if (rbufp->recv_length >= (int)LEN_PKT_NOMAC) has_mac = 1; else { if (debug) @@ -857,6 +822,19 @@ receive( if (!is_authentic) server->trust |= 1; + /* + * Check for a KoD (rate limiting) response, cease and decist. + */ + if (LEAP_NOTINSYNC == PKT_LEAP(rpkt->li_vn_mode) && + STRATUM_PKT_UNSPEC == rpkt->stratum && + !memcmp("RATE", &rpkt->refid, 4)) { + msyslog(LOG_ERR, "%s rate limit response from server.", + stoa(&rbufp->recv_srcadr)); + server->event_time = 0; + complete_servers++; + return; + } + /* * Looks good. Record info from the packet. */ @@ -864,7 +842,7 @@ receive( server->stratum = PKT_TO_STRATUM(rpkt->stratum); server->precision = rpkt->precision; server->rootdelay = ntohl(rpkt->rootdelay); - server->rootdispersion = ntohl(rpkt->rootdispersion); + server->rootdisp = ntohl(rpkt->rootdisp); server->refid = rpkt->refid; NTOHL_FP(&rpkt->reftime, &server->reftime); NTOHL_FP(&rpkt->rec, &rec); @@ -875,7 +853,7 @@ receive( * again. */ if (L_ISZERO(&rec) || !L_ISHIS(&server->org, &rec)) { - transmit(server); + server->event_time = current_time + sys_timeout; return; } @@ -924,10 +902,21 @@ receive( } /* - * Shift this data in, then transmit again. + * Shift this data in, then schedule another transmit. */ server_data(server, (s_fp) di, &ci, 0); - transmit(server); + + if ((int)server->filter_nextpt >= sys_samples) { + /* + * Got all the data we need. Mark this guy + * completed and return. + */ + server->event_time = 0; + complete_servers++; + return; + } + + server->event_time = current_time + sys_timeout; } @@ -1035,12 +1024,14 @@ clock_filter( static struct server * clock_select(void) { - register struct server *server; - register int i; - register int nlist; - register s_fp d; - register int j; - register int n; + struct server *server; + u_int nlist; + s_fp d; + u_int count; + u_int i; + u_int j; + u_int k; + int n; s_fp local_threshold; struct server *server_list[NTP_MAXCLOCK]; u_fp server_badness[NTP_MAXCLOCK]; @@ -1136,12 +1127,14 @@ clock_select(void) * Got the five-or-less best. Cut the list where the number of * strata exceeds two. */ - j = 0; + count = 0; for (i = 1; i < nlist; i++) - if (server_list[i]->stratum > server_list[i-1]->stratum) - if (++j == 2) { - nlist = i; - break; + if (server_list[i]->stratum > server_list[i-1]->stratum) { + count++; + if (2 == count) { + nlist = i; + break; + } } /* @@ -1151,9 +1144,9 @@ clock_select(void) * detection. */ - if (nlist == 0) - sys_server = 0; - else if (nlist == 1) { + if (0 == nlist) + sys_server = NULL; + else if (1 == nlist) { sys_server = server_list[0]; } else { /* @@ -1162,12 +1155,13 @@ clock_select(void) */ for (i = 0; i < nlist-1; i++) for (j = i+1; j < nlist; j++) { - if (server_list[i]->stratum - < server_list[j]->stratum) - break; /* already sorted by stratum */ - if (server_list[i]->delay - < server_list[j]->delay) - continue; + if (server_list[i]->stratum < + server_list[j]->stratum) + /* already sorted by stratum */ + break; + if (server_list[i]->delay < + server_list[j]->delay) + continue; server = server_list[i]; server_list[i] = server_list[j]; server_list[j] = server; @@ -1183,14 +1177,14 @@ clock_select(void) * Now drop samples until we're down to one. */ while (nlist > 1) { - for (n = 0; n < nlist; n++) { - server_badness[n] = 0; + for (k = 0; k < nlist; k++) { + server_badness[k] = 0; for (j = 0; j < nlist; j++) { - if (j == n) /* with self? */ + if (j == k) /* with self? */ continue; - d = server_list[j]->soffset - - server_list[n]->soffset; - if (d < 0) /* absolute value */ + d = server_list[j]->soffset - + server_list[k]->soffset; + if (d < 0) /* abs value */ d = -d; /* * XXX This code *knows* that @@ -1198,7 +1192,7 @@ clock_select(void) */ for (i = 0; i < j; i++) d = (d>>1) + (d>>2); - server_badness[n] += d; + server_badness[k] += d; } } @@ -1289,7 +1283,7 @@ clock_adjust(void) lfptoa(&server->offset, 6)); } } else { -#if !defined SYS_WINNT && !defined SYS_CYGWIN32 +#ifndef SYS_WINNT if (simple_query || l_adj_systime(&server->offset)) { msyslog(LOG_NOTICE, "adjust time server %s offset %s sec", stoa(&server->srcadr), @@ -1318,16 +1312,16 @@ clock_adjust(void) * (non-blocking). */ static int -is_reachable (struct sockaddr_storage *dst) +is_reachable (sockaddr_u *dst) { SOCKET sockfd; - sockfd = socket(dst->ss_family, SOCK_DGRAM, 0); + sockfd = socket(AF(dst), SOCK_DGRAM, 0); if (sockfd == -1) { return 0; } - if(connect(sockfd, (struct sockaddr *)dst, SOCKLEN(dst))) { + if (connect(sockfd, &dst->sa, SOCKLEN(dst))) { closesocket(sockfd); return 0; } @@ -1356,10 +1350,12 @@ addserver( int error; /* Service name */ char service[5]; - strcpy(service, "ntp"); + sockaddr_u addr; + + strlcpy(service, "ntp", sizeof(service)); /* Get host address. Looking for UDP datagram connection. */ - memset(&hints, 0, sizeof(hints)); + ZERO(hints); hints.ai_family = ai_fam_templ; hints.ai_socktype = SOCK_DGRAM; @@ -1375,28 +1371,35 @@ addserver( /* Name server is unusable. Exit after failing on the first server, in order to shorten the timeout caused by waiting for resolution of several servers */ - fprintf(stderr, "Name server cannot be used, exiting"); - msyslog(LOG_ERR, "name server cannot be used, reason: %s\n", gai_strerror(error)); + fprintf(stderr, "Exiting, name server cannot be used: %s (%d)", + gai_strerror(error), error); + msyslog(LOG_ERR, "name server cannot be used: %s (%d)", + gai_strerror(error), error); exit(1); } - fprintf(stderr, "Error : %s\n", gai_strerror(error)); - msyslog(LOG_ERR, "can't find host %s\n", serv); + fprintf(stderr, "Error resolving %s: %s (%d)\n", serv, + gai_strerror(error), error); + msyslog(LOG_ERR, "Can't find host %s: %s (%d)", serv, + gai_strerror(error), error); return; } #ifdef DEBUG - else if (debug) { - fprintf(stderr, "host found : %s\n", stohost((struct sockaddr_storage*)addrResult->ai_addr)); + if (debug) { + ZERO(addr); + INSIST(addrResult->ai_addrlen <= sizeof(addr)); + memcpy(&addr, addrResult->ai_addr, addrResult->ai_addrlen); + fprintf(stderr, "host found : %s\n", stohost(&addr)); } #endif /* We must get all returned server in case the first one fails */ for (ptr = addrResult; ptr != NULL; ptr = ptr->ai_next) { - if (is_reachable ((struct sockaddr_storage *)ptr->ai_addr)) { - server = (struct server *)emalloc(sizeof(struct server)); - memset((char *)server, 0, sizeof(struct server)); - - memset(&(server->srcadr), 0, sizeof(struct sockaddr_storage)); - memcpy(&(server->srcadr), ptr->ai_addr, ptr->ai_addrlen); + ZERO(addr); + INSIST(ptr->ai_addrlen <= sizeof(addr)); + memcpy(&addr, ptr->ai_addr, ptr->ai_addrlen); + if (is_reachable(&addr)) { + server = emalloc_zero(sizeof(*server)); + memcpy(&server->srcadr, ptr->ai_addr, ptr->ai_addrlen); server->event_time = ++sys_numservers; if (sys_servers == NULL) sys_servers = server; @@ -1404,7 +1407,8 @@ addserver( struct server *sp; for (sp = sys_servers; sp->next_server != NULL; - sp = sp->next_server) ; + sp = sp->next_server) + /* empty */; sp->next_server = server; } } @@ -1420,40 +1424,23 @@ addserver( */ static struct server * findserver( - struct sockaddr_storage *addr + sockaddr_u *addr ) { struct server *server; struct server *mc_server; - isc_sockaddr_t laddr; - isc_sockaddr_t saddr; - - if(addr->ss_family == AF_INET) { - isc_sockaddr_fromin( &laddr, &((struct sockaddr_in*)addr)->sin_addr, 0); - } - else { - isc_sockaddr_fromin6(&laddr, &((struct sockaddr_in6*)addr)->sin6_addr, 0); - } - mc_server = NULL; - if (htons(((struct sockaddr_in*)addr)->sin_port) != NTP_PORT) + if (SRCPORT(addr) != NTP_PORT) return 0; for (server = sys_servers; server != NULL; server = server->next_server) { - - if(server->srcadr.ss_family == AF_INET) { - isc_sockaddr_fromin(&saddr, &((struct sockaddr_in*)&server->srcadr)->sin_addr, 0); - } - else { - isc_sockaddr_fromin6(&saddr, &((struct sockaddr_in6*)&server->srcadr)->sin6_addr, 0); - } - if (isc_sockaddr_eqaddr(&laddr, &saddr) == ISC_TRUE) + if (SOCK_EQ(addr, &server->srcadr)) return server; - if(addr->ss_family == server->srcadr.ss_family) { - if (isc_sockaddr_ismulticast(&saddr) == ISC_TRUE) + if (AF(addr) == AF(&server->srcadr)) { + if (IS_MCAST(&server->srcadr)) mc_server = server; } } @@ -1467,15 +1454,15 @@ findserver( complete_servers++; } - server = (struct server *)emalloc(sizeof(struct server)); - memset((char *)server, 0, sizeof(struct server)); + server = emalloc_zero(sizeof(*server)); - memcpy(&server->srcadr, addr, sizeof(struct sockaddr_storage)); + server->srcadr = *addr; server->event_time = ++sys_numservers; for (sp = sys_servers; sp->next_server != NULL; - sp = sp->next_server) ; + sp = sp->next_server) + /* empty */; sp->next_server = server; transmit(server); } @@ -1526,16 +1513,16 @@ alarming( { alarm_flag++; } -#else +#else /* SYS_WINNT follows */ void CALLBACK alarming(UINT uTimerID, UINT uMsg, DWORD dwUser, DWORD dw1, DWORD dw2) { + UNUSED_ARG(uTimerID); UNUSED_ARG(uMsg); UNUSED_ARG(dwUser); + UNUSED_ARG(dw1); UNUSED_ARG(dw2); + alarm_flag++; } -#endif /* SYS_WINNT */ - -#ifdef SYS_WINNT static void callTimeEndPeriod(void) { @@ -1552,16 +1539,14 @@ static void init_alarm(void) { #ifndef SYS_WINNT -# ifndef HAVE_TIMER_SETTIME - struct itimerval itimer; +# ifdef HAVE_TIMER_CREATE + struct itimerspec its; # else - struct itimerspec ntpdate_itimer; + struct itimerval itv; # endif -#else +#else /* SYS_WINNT follows */ TIMECAPS tc; UINT wTimerID; -# endif /* SYS_WINNT */ -#if defined SYS_CYGWIN32 || defined SYS_WINNT HANDLE hToken; TOKEN_PRIVILEGES tkp; DWORD dwUser = 0; @@ -1570,7 +1555,7 @@ init_alarm(void) alarm_flag = 0; #ifndef SYS_WINNT -# if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) +# ifdef HAVE_TIMER_CREATE alarm_flag = 0; /* this code was put in as setitimer() is non existant this us the * POSIX "equivalents" setup - casey @@ -1592,44 +1577,26 @@ init_alarm(void) * Set up the alarm interrupt. The first comes 1/(2*TIMER_HZ) * seconds from now and they continue on every 1/TIMER_HZ seconds. */ - (void) signal_no_reset(SIGALRM, alarming); - ntpdate_itimer.it_interval.tv_sec = ntpdate_itimer.it_value.tv_sec = 0; - ntpdate_itimer.it_interval.tv_nsec = 1000000000/TIMER_HZ; - ntpdate_itimer.it_value.tv_nsec = 1000000000/(TIMER_HZ<<1); - timer_settime(ntpdate_timerid, 0 /* !TIMER_ABSTIME */, &ntpdate_itimer, NULL); -# else + signal_no_reset(SIGALRM, alarming); + its.it_interval.tv_sec = 0; + its.it_value.tv_sec = 0; + its.it_interval.tv_nsec = 1000000000/TIMER_HZ; + its.it_value.tv_nsec = 1000000000/(TIMER_HZ<<1); + timer_settime(ntpdate_timerid, 0 /* !TIMER_ABSTIME */, &its, NULL); +# else /* !HAVE_TIMER_CREATE follows */ /* * Set up the alarm interrupt. The first comes 1/(2*TIMER_HZ) * seconds from now and they continue on every 1/TIMER_HZ seconds. */ - (void) signal_no_reset(SIGALRM, alarming); - itimer.it_interval.tv_sec = itimer.it_value.tv_sec = 0; - itimer.it_interval.tv_usec = 1000000/TIMER_HZ; - itimer.it_value.tv_usec = 1000000/(TIMER_HZ<<1); - - setitimer(ITIMER_REAL, &itimer, (struct itimerval *)0); -# endif -#if defined SYS_CYGWIN32 - /* - * Get privileges needed for fiddling with the clock - */ - - /* get the current process token handle */ - if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY, &hToken)) { - msyslog(LOG_ERR, "OpenProcessToken failed: %m"); - exit(1); - } - /* get the LUID for system-time privilege. */ - LookupPrivilegeValue(NULL, SE_SYSTEMTIME_NAME, &tkp.Privileges[0].Luid); - tkp.PrivilegeCount = 1; /* one privilege to set */ - tkp.Privileges[0].Attributes = SE_PRIVILEGE_ENABLED; - /* get set-time privilege for this process. */ - AdjustTokenPrivileges(hToken, FALSE, &tkp, 0,(PTOKEN_PRIVILEGES) NULL, 0); - /* cannot test return value of AdjustTokenPrivileges. */ - if (GetLastError() != ERROR_SUCCESS) - msyslog(LOG_ERR, "AdjustTokenPrivileges failed: %m"); -#endif -#else /* SYS_WINNT */ + signal_no_reset(SIGALRM, alarming); + itv.it_interval.tv_sec = 0; + itv.it_value.tv_sec = 0; + itv.it_interval.tv_usec = 1000000/TIMER_HZ; + itv.it_value.tv_usec = 1000000/(TIMER_HZ<<1); + + setitimer(ITIMER_REAL, &itv, NULL); +# endif /* !HAVE_TIMER_CREATE */ +#else /* SYS_WINNT follows */ _tzset(); /* @@ -1707,7 +1674,9 @@ init_io(void) { struct addrinfo *res, *ressave; struct addrinfo hints; + sockaddr_u addr; char service[5]; + int rc; int optval = 1; int check_ntp_port_in_use = !debug && !simple_query && !unpriv_port; @@ -1720,25 +1689,25 @@ init_io(void) * Open the socket */ - strcpy(service, "ntp"); + strlcpy(service, "ntp", sizeof(service)); /* * Init hints addrinfo structure */ - memset(&hints, 0, sizeof(hints)); + ZERO(hints); hints.ai_family = ai_fam_templ; hints.ai_flags = AI_PASSIVE; hints.ai_socktype = SOCK_DGRAM; - if(getaddrinfo(NULL, service, &hints, &res) != 0) { - msyslog(LOG_ERR, "getaddrinfo() failed: %m"); - exit(1); - /*NOTREACHED*/ + if (getaddrinfo(NULL, service, &hints, &res) != 0) { + msyslog(LOG_ERR, "getaddrinfo() failed: %m"); + exit(1); + /*NOTREACHED*/ } #ifdef SYS_WINNT if (check_ntp_port_in_use && ntp_port_inuse(AF_INET, NTP_PORT)){ - netsyslog(LOG_ERR, "the NTP socket is in use, exiting: %m"); + msyslog(LOG_ERR, "the NTP socket is in use, exiting: %m"); exit(1); } #endif @@ -1762,13 +1731,13 @@ init_io(void) err == WSAEPFNOSUPPORT) #endif continue; - netsyslog(LOG_ERR, "socket() failed: %m"); + msyslog(LOG_ERR, "socket() failed: %m"); exit(1); /*NOTREACHED*/ } /* set socket to reuse address */ if (setsockopt(fd[nbsock], SOL_SOCKET, SO_REUSEADDR, (void*) &optval, sizeof(optval)) < 0) { - netsyslog(LOG_ERR, "setsockopt() SO_REUSEADDR failed: %m"); + msyslog(LOG_ERR, "setsockopt() SO_REUSEADDR failed: %m"); exit(1); /*NOTREACHED*/ } @@ -1776,7 +1745,7 @@ init_io(void) /* Restricts AF_INET6 socket to IPv6 communications (see RFC 2553bis-03) */ if (res->ai_family == AF_INET6) if (setsockopt(fd[nbsock], IPPROTO_IPV6, IPV6_V6ONLY, (void*) &optval, sizeof(optval)) < 0) { - netsyslog(LOG_ERR, "setsockopt() IPV6_V6ONLY failed: %m"); + msyslog(LOG_ERR, "setsockopt() IPV6_V6ONLY failed: %m"); exit(1); /*NOTREACHED*/ } @@ -1789,15 +1758,15 @@ init_io(void) * bind the socket to the NTP port */ if (check_ntp_port_in_use) { - if (bind(fd[nbsock], res->ai_addr, SOCKLEN(res->ai_addr)) < 0) { -#ifndef SYS_WINNT - if (errno == EADDRINUSE) -#else - if (WSAGetLastError() == WSAEADDRINUSE) -#endif /* SYS_WINNT */ - netsyslog(LOG_ERR, "the NTP socket is in use, exiting"); + ZERO(addr); + INSIST(res->ai_addrlen <= sizeof(addr)); + memcpy(&addr, res->ai_addr, res->ai_addrlen); + rc = bind(fd[nbsock], &addr.sa, SOCKLEN(&addr)); + if (rc < 0) { + if (EADDRINUSE == socket_errno()) + msyslog(LOG_ERR, "the NTP socket is in use, exiting"); else - netsyslog(LOG_ERR, "bind() fails: %m"); + msyslog(LOG_ERR, "bind() fails: %m"); exit(1); } } @@ -1818,24 +1787,24 @@ init_io(void) #ifndef SYS_WINNT # ifdef SYS_VXWORKS { - int on = TRUE; + int on = TRUE; - if (ioctl(fd[nbsock],FIONBIO, &on) == ERROR) { - netsyslog(LOG_ERR, "ioctl(FIONBIO) fails: %m"); - exit(1); - } + if (ioctl(fd[nbsock],FIONBIO, &on) == ERROR) { + msyslog(LOG_ERR, "ioctl(FIONBIO) fails: %m"); + exit(1); + } } # else /* not SYS_VXWORKS */ # if defined(O_NONBLOCK) if (fcntl(fd[nbsock], F_SETFL, O_NONBLOCK) < 0) { - netsyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); + msyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); exit(1); /*NOTREACHED*/ } # else /* not O_NONBLOCK */ # if defined(FNDELAY) if (fcntl(fd[nbsock], F_SETFL, FNDELAY) < 0) { - netsyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); + msyslog(LOG_ERR, "fcntl(FNDELAY|FASYNC) fails: %m"); exit(1); /*NOTREACHED*/ } @@ -1846,7 +1815,7 @@ init_io(void) # endif /* SYS_VXWORKS */ #else /* SYS_WINNT */ if (ioctlsocket(fd[nbsock], FIONBIO, (u_long *) &on) == SOCKET_ERROR) { - netsyslog(LOG_ERR, "ioctlsocket(FIONBIO) fails: %m"); + msyslog(LOG_ERR, "ioctlsocket(FIONBIO) fails: %m"); exit(1); } #endif /* SYS_WINNT */ @@ -1860,7 +1829,7 @@ init_io(void) */ static void sendpkt( - struct sockaddr_storage *dest, + sockaddr_u *dest, struct pkt *pkt, int len ) @@ -1875,14 +1844,14 @@ sendpkt( /* Find a local family compatible socket to send ntp packet to ntp server */ for(i = 0; (i < MAX_AF); i++) { - if(dest->ss_family == fd_family[i]) { + if(AF(dest) == fd_family[i]) { sock = fd[i]; break; } } - if ( sock == INVALID_SOCKET ) { - netsyslog(LOG_ERR, "cannot find family compatible socket to send ntp packet"); + if (INVALID_SOCKET == sock) { + msyslog(LOG_ERR, "cannot find family compatible socket to send ntp packet"); exit(1); /*NOTREACHED*/ } @@ -1890,14 +1859,14 @@ sendpkt( cc = sendto(sock, (char *)pkt, len, 0, (struct sockaddr *)dest, SOCKLEN(dest)); - if (cc == SOCKET_ERROR) { + if (SOCKET_ERROR == cc) { #ifndef SYS_WINNT if (errno != EWOULDBLOCK && errno != ENOBUFS) #else err = WSAGetLastError(); if (err != WSAEWOULDBLOCK && err != WSAENOBUFS) #endif /* SYS_WINNT */ - netsyslog(LOG_ERR, "sendto(%s): %m", stohost(dest)); + msyslog(LOG_ERR, "sendto(%s): %m", stohost(dest)); } } @@ -1910,8 +1879,8 @@ input_handler(void) { register int n; register struct recvbuf *rb; - struct timeval tvzero; - int fromlen; + struct sock_timeval tvzero; + GETSOCKNAME_SOCKLEN_TYPE fromlen; l_fp ts; int i; #ifdef HAVE_POLL_H @@ -1967,7 +1936,7 @@ input_handler(void) return; else if (n == -1) { if (errno != EINTR) - netsyslog(LOG_ERR, + msyslog(LOG_ERR, #ifdef HAVE_POLL_H "poll() error: %m" #else @@ -2002,7 +1971,7 @@ input_handler(void) rb = get_free_recv_buffer(); - fromlen = sizeof(struct sockaddr_storage); + fromlen = sizeof(rb->recv_srcadr); rb->recv_length = recvfrom(fdc, (char *)&rb->recv_pkt, sizeof(rb->recv_pkt), 0, (struct sockaddr *)&rb->recv_srcadr, &fromlen); @@ -2069,7 +2038,7 @@ l_adj_systime( if (adjtv.tv_usec != 0 && !debug) { if (adjtime(&adjtv, &oadjtv) < 0) { msyslog(LOG_ERR, "Can't adjust the time of day: %m"); - return 0; + exit(1); } } return 1; @@ -2150,7 +2119,7 @@ printserver( { register int i; char junk[5]; - char *str; + const char *str; if (!debug) { (void) fprintf(fp, "server %s, stratum %d, offset %s, delay %s\n", @@ -2213,57 +2182,6 @@ printserver( lfptoa(&pp->offset, 6)); } -#if !defined(HAVE_VSPRINTF) -int -vsprintf( - char *str, - const char *fmt, - va_list ap - ) -{ - FILE f; - int len; - - f._flag = _IOWRT+_IOSTRG; - f._ptr = str; - f._cnt = 32767; - len = _doprnt(fmt, ap, &f); - *f._ptr = 0; - return (len); -} -#endif - -#if 0 -/* override function in library since SA_RESTART makes ALL syscalls restart */ -#ifdef SA_RESTART -void -signal_no_reset( - int sig, - void (*func)() - ) -{ - int n; - struct sigaction vec; - - vec.sa_handler = func; - sigemptyset(&vec.sa_mask); - vec.sa_flags = 0; - - while (1) - { - n = sigaction(sig, &vec, NULL); - if (n == -1 && errno == EINTR) - continue; - break; - } - if (n == -1) - { - perror("sigaction"); - exit(1); - } -} -#endif -#endif #ifdef HAVE_NETINFO static ni_namelist * @@ -2272,7 +2190,7 @@ getnetinfoservers(void) ni_status status; void *domain; ni_id confdir; - ni_namelist *namelist = (ni_namelist*)malloc(sizeof(ni_namelist)); + ni_namelist *namelist = emalloc(sizeof(ni_namelist)); /* Find a time server in NetInfo */ if ((status = ni_open(NULL, ".", &domain)) != NI_OK) return NULL; diff --git a/contrib/ntp/ntpdate/ntpdate.h b/contrib/ntp/ntpdate/ntpdate.h index f3531b3f2..df9c49eb4 100644 --- a/contrib/ntp/ntpdate/ntpdate.h +++ b/contrib/ntp/ntpdate/ntpdate.h @@ -4,7 +4,7 @@ #include "ntp_malloc.h" -extern void loadservers P((char *cfgpath)); +extern void loadservers (char *cfgpath); /* * The server structure is a much simplified version of the @@ -15,14 +15,14 @@ extern void loadservers P((char *cfgpath)); */ struct server { struct server *next_server; /* next server in build list */ - struct sockaddr_storage srcadr; /* address of remote host */ + sockaddr_u srcadr; /* address of remote host */ u_char version; /* version to use */ u_char leap; /* leap indicator */ u_char stratum; /* stratum of remote server */ s_char precision; /* server's clock precision */ u_char trust; /* trustability of the filtered data */ u_fp rootdelay; /* distance from primary clock */ - u_fp rootdispersion; /* peer clock dispersion */ + u_fp rootdisp; /* peer clock dispersion */ u_int32 refid; /* peer reference ID */ l_fp reftime; /* time of peer's last update */ u_long event_time; /* time for next timeout */ @@ -89,9 +89,13 @@ struct server { /* - * Some defaults + * No less than 2s between requests to a server to stay within ntpd's + * default "discard minimum 1" (and 1s enforcement slop). That is + * enforced only if the nondefault limited restriction is in place, such + * as with "restrict ... limited" and "restrict ... kod limited". */ -#define DEFTIMEOUT 5 /* 5 timer increments */ +#define MINTIMEOUT (1 * TIMER_HZ) /* 1s min. between packets */ +#define DEFTIMEOUT (2 * TIMER_HZ) /* 2s by default */ #define DEFSAMPLES 4 /* get 4 samples per server */ #define DEFPRECISION (-5) /* the precision we claim */ #define DEFMAXPERIOD 60 /* maximum time to wait */ diff --git a/contrib/ntp/ntpdate/ntptime_config.c b/contrib/ntp/ntpdate/ntptime_config.c deleted file mode 100644 index e784d2803..000000000 --- a/contrib/ntp/ntpdate/ntptime_config.c +++ /dev/null @@ -1,552 +0,0 @@ -/* - * ntptime_config.c - * - * What follows is a simplified version of the config parsing code - * in ntpd/ntp_config.c. We only parse a subset of the configuration - * syntax, and don't bother whining about things we don't understand. - * - */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "ntp_fp.h" -#include "ntp.h" -#include "ntp_io.h" -#include "ntp_unixtime.h" -#include "ntp_filegen.h" -#include "ntpdate.h" -#include "ntp_syslog.h" -#include "ntp_stdlib.h" - -#include -#include -#include - -/* - * These routines are used to read the configuration file at - * startup time. An entry in the file must fit on a single line. - * Entries are processed as multiple tokens separated by white space - * Lines are considered terminated when a '#' is encountered. Blank - * lines are ignored. - */ - -/* - * Configuration file name - */ -#ifndef CONFIG_FILE -# ifndef SYS_WINNT -# define CONFIG_FILE "/etc/ntp.conf" -# else /* SYS_WINNT */ -# define CONFIG_FILE "%windir%\\ntp.conf" -# define ALT_CONFIG_FILE "%windir%\\ntp.ini" -# endif /* SYS_WINNT */ -#endif /* not CONFIG_FILE */ - -/* - * - * We understand the following configuration entries and defaults. - * - * peer [ addr ] [ version 3 ] [ key 0 ] [ minpoll 6 ] [ maxpoll 10 ] - * server [ addr ] [ version 3 ] [ key 0 ] [ minpoll 6 ] [ maxpoll 10 ] - * keys file_name - */ - -#define CONFIG_UNKNOWN 0 - -#define CONFIG_PEER 1 -#define CONFIG_SERVER 2 -#define CONFIG_KEYS 8 - -#define CONF_MOD_VERSION 1 -#define CONF_MOD_KEY 2 -#define CONF_MOD_MINPOLL 3 -#define CONF_MOD_MAXPOLL 4 -#define CONF_MOD_PREFER 5 -#define CONF_MOD_BURST 6 -#define CONF_MOD_SKEY 7 -#define CONF_MOD_TTL 8 -#define CONF_MOD_MODE 9 - -/* - * Translation table - keywords to function index - */ -struct keyword { - const char *text; - int keytype; -}; - -/* - * Command keywords - */ -static struct keyword keywords[] = { - { "peer", CONFIG_PEER }, - { "server", CONFIG_SERVER }, - { "keys", CONFIG_KEYS }, - { "", CONFIG_UNKNOWN } -}; - -/* - * "peer", "server", "broadcast" modifier keywords - */ -static struct keyword mod_keywords[] = { - { "version", CONF_MOD_VERSION }, - { "key", CONF_MOD_KEY }, - { "minpoll", CONF_MOD_MINPOLL }, - { "maxpoll", CONF_MOD_MAXPOLL }, - { "prefer", CONF_MOD_PREFER }, - { "burst", CONF_MOD_BURST }, - { "autokey", CONF_MOD_SKEY }, - { "mode", CONF_MOD_MODE }, /* reference clocks */ - { "ttl", CONF_MOD_TTL }, /* NTP peers */ - { "", CONFIG_UNKNOWN } -}; - -/* - * Limits on things - */ -#define MAXTOKENS 20 /* 20 tokens on line */ -#define MAXLINE 1024 /* maximum length of line */ -#define MAXFILENAME 128 /* maximum length of a file name (alloca()?) */ - -/* - * Miscellaneous macros - */ -#define STRSAME(s1, s2) (*(s1) == *(s2) && strcmp((s1), (s2)) == 0) -#define ISEOL(c) ((c) == '#' || (c) == '\n' || (c) == '\0') -#define ISSPACE(c) ((c) == ' ' || (c) == '\t') -#define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) - -/* - * Systemwide parameters and flags - */ -extern struct server **sys_servers; /* the server list */ -extern int sys_numservers; /* number of servers to poll */ -extern char *key_file; - -/* - * Function prototypes - */ -static int gettokens P((FILE *, char *, char **, int *)); -static int matchkey P((char *, struct keyword *)); -static int getnetnum P((const char *num, struct sockaddr_in *addr, - int complain)); - - -/* - * loadservers - load list of NTP servers from configuration file - */ -void -loadservers( - char *cfgpath - ) -{ - register int i; - int errflg; - int peerversion; - int minpoll; - int maxpoll; - /* int ttl; */ - int srvcnt; - /* u_long peerkey; */ - int peerflags; - struct sockaddr_in peeraddr; - FILE *fp; - char line[MAXLINE]; - char *(tokens[MAXTOKENS]); - int ntokens; - int tok; - const char *config_file; -#ifdef SYS_WINNT - char *alt_config_file; - LPTSTR temp; - char config_file_storage[MAX_PATH]; - char alt_config_file_storage[MAX_PATH]; -#endif /* SYS_WINNT */ - struct server *server, *srvlist; - - /* - * Initialize, initialize - */ - srvcnt = 0; - srvlist = 0; - errflg = 0; -#ifdef DEBUG - debug = 0; -#endif /* DEBUG */ -#ifndef SYS_WINNT - config_file = cfgpath ? cfgpath : CONFIG_FILE; -#else - if (cfgpath) { - config_file = cfgpath; - } else { - temp = CONFIG_FILE; - if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)config_file_storage, (DWORD)sizeof(config_file_storage))) { - msyslog(LOG_ERR, "ExpandEnvironmentStrings CONFIG_FILE failed: %m\n"); - exit(1); - } - config_file = config_file_storage; - } - - temp = ALT_CONFIG_FILE; - if (!ExpandEnvironmentStrings((LPCTSTR)temp, (LPTSTR)alt_config_file_storage, (DWORD)sizeof(alt_config_file_storage))) { - msyslog(LOG_ERR, "ExpandEnvironmentStrings ALT_CONFIG_FILE failed: %m\n"); - exit(1); - } - alt_config_file = alt_config_file_storage; -M -#endif /* SYS_WINNT */ - - if ((fp = fopen(FindConfig(config_file), "r")) == NULL) - { - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(config_file)); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(config_file)); -#ifdef SYS_WINNT - /* Under WinNT try alternate_config_file name, first NTP.CONF, then NTP.INI */ - - if ((fp = fopen(FindConfig(alt_config_file), "r")) == NULL) { - - /* - * Broadcast clients can sometimes run without - * a configuration file. - */ - - fprintf(stderr, "getconfig: Couldn't open <%s>\n", FindConfig(alt_config_file)); - msyslog(LOG_INFO, "getconfig: Couldn't open <%s>", FindConfig(alt_config_file)); - return; - } -#else /* not SYS_WINNT */ - return; -#endif /* not SYS_WINNT */ - } - - while ((tok = gettokens(fp, line, tokens, &ntokens)) - != CONFIG_UNKNOWN) { - switch(tok) { - case CONFIG_PEER: - case CONFIG_SERVER: - - if (ntokens < 2) { - msyslog(LOG_ERR, - "No address for %s, line ignored", - tokens[0]); - break; - } - - if (!getnetnum(tokens[1], &peeraddr, 1)) { - /* Resolve now, or lose! */ - break; - } else { - errflg = 0; - - /* Shouldn't be able to specify multicast */ - if (IN_CLASSD(ntohl(peeraddr.sin_addr.s_addr)) - || ISBADADR(&peeraddr)) { - msyslog(LOG_ERR, - "attempt to configure invalid address %s", - ntoa(&peeraddr)); - break; - } - } - - peerversion = NTP_VERSION; - minpoll = NTP_MINDPOLL; - maxpoll = NTP_MAXDPOLL; - /* peerkey = 0; */ - peerflags = 0; - /* ttl = 0; */ - for (i = 2; i < ntokens; i++) - switch (matchkey(tokens[i], mod_keywords)) { - case CONF_MOD_VERSION: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "peer/server version requires an argument"); - errflg = 1; - break; - } - peerversion = atoi(tokens[++i]); - if ((u_char)peerversion > NTP_VERSION - || (u_char)peerversion < NTP_OLDVERSION) { - msyslog(LOG_ERR, - "inappropriate version number %s, line ignored", - tokens[i]); - errflg = 1; - } - break; - - case CONF_MOD_KEY: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "key: argument required"); - errflg = 1; - break; - } - ++i; - /* peerkey = (int)atol(tokens[i]); */ - peerflags |= FLAG_AUTHENABLE; - break; - - case CONF_MOD_MINPOLL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "minpoll: argument required"); - errflg = 1; - break; - } - minpoll = atoi(tokens[++i]); - if (minpoll < NTP_MINPOLL) - minpoll = NTP_MINPOLL; - break; - - case CONF_MOD_MAXPOLL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "maxpoll: argument required" - ); - errflg = 1; - break; - } - maxpoll = atoi(tokens[++i]); - if (maxpoll > NTP_MAXPOLL) - maxpoll = NTP_MAXPOLL; - break; - - case CONF_MOD_PREFER: - peerflags |= FLAG_PREFER; - break; - - case CONF_MOD_BURST: - peerflags |= FLAG_BURST; - break; - - case CONF_MOD_SKEY: - peerflags |= FLAG_SKEY | FLAG_AUTHENABLE; - break; - - case CONF_MOD_TTL: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "ttl: argument required"); - errflg = 1; - break; - } - ++i; - /* ttl = atoi(tokens[i]); */ - break; - - case CONF_MOD_MODE: - if (i >= ntokens-1) { - msyslog(LOG_ERR, - "mode: argument required"); - errflg = 1; - break; - } - ++i; - /* ttl = atoi(tokens[i]); */ - break; - - case CONFIG_UNKNOWN: - errflg = 1; - break; - } - if (minpoll > maxpoll) { - msyslog(LOG_ERR, "config error: minpoll > maxpoll"); - errflg = 1; - } - if (errflg == 0) { - server = (struct server *)emalloc(sizeof(struct server)); - memset((char *)server, 0, sizeof(struct server)); - server->srcadr = peeraddr; - server->version = peerversion; - server->dispersion = PEER_MAXDISP; - server->next_server = srvlist; - srvlist = server; - srvcnt++; - } - break; - - case CONFIG_KEYS: - if (ntokens >= 2) { - key_file = (char *) emalloc(strlen(tokens[1]) + 1); - strcpy(key_file, tokens[1]); - } - break; - } - } - (void) fclose(fp); - - /* build final list */ - sys_numservers = srvcnt; - sys_servers = (struct server **) - emalloc(sys_numservers * sizeof(struct server *)); - for(i=0;inext_server; - } -} - - - -/* - * gettokens - read a line and return tokens - */ -static int -gettokens( - FILE *fp, - char *line, - char **tokenlist, - int *ntokens - ) -{ - register char *cp; - register int eol; - register int ntok; - register int quoted = 0; - - /* - * Find start of first token - */ - again: - while ((cp = fgets(line, MAXLINE, fp)) != NULL) { - cp = line; - while (ISSPACE(*cp)) - cp++; - if (!ISEOL(*cp)) - break; - } - if (cp == NULL) { - *ntokens = 0; - return CONFIG_UNKNOWN; /* hack. Is recognized as EOF */ - } - - /* - * Now separate out the tokens - */ - eol = 0; - ntok = 0; - while (!eol) { - tokenlist[ntok++] = cp; - while (!ISEOL(*cp) && (!ISSPACE(*cp) || quoted)) - quoted ^= (*cp++ == '"'); - - if (ISEOL(*cp)) { - *cp = '\0'; - eol = 1; - } else { /* must be space */ - *cp++ = '\0'; - while (ISSPACE(*cp)) - cp++; - if (ISEOL(*cp)) - eol = 1; - } - if (ntok == MAXTOKENS) - eol = 1; - } - - /* - * Return the match - */ - *ntokens = ntok; - ntok = matchkey(tokenlist[0], keywords); - if (ntok == CONFIG_UNKNOWN) - goto again; - return ntok; -} - - - -/* - * matchkey - match a keyword to a list - */ -static int -matchkey( - register char *word, - register struct keyword *keys - ) -{ - for (;;) { - if (keys->keytype == CONFIG_UNKNOWN) { - return CONFIG_UNKNOWN; - } - if (STRSAME(word, keys->text)) - return keys->keytype; - keys++; - } -} - - -/* - * getnetnum - return a net number (this is crude, but careful) - */ -static int -getnetnum( - const char *num, - struct sockaddr_in *addr, - int complain - ) -{ - register const char *cp; - register char *bp; - register int i; - register int temp; - char buf[80]; /* will core dump on really stupid stuff */ - u_int32 netnum; - - /* XXX ELIMINATE replace with decodenetnum */ - cp = num; - netnum = 0; - for (i = 0; i < 4; i++) { - bp = buf; - while (isdigit((int)*cp)) - *bp++ = *cp++; - if (bp == buf) - break; - - if (i < 3) { - if (*cp++ != '.') - break; - } else if (*cp != '\0') - break; - - *bp = '\0'; - temp = atoi(buf); - if (temp > 255) - break; - netnum <<= 8; - netnum += temp; -#ifdef DEBUG - if (debug > 3) - printf("getnetnum %s step %d buf %s temp %d netnum %lu\n", - num, i, buf, temp, (u_long)netnum); -#endif - } - - if (i < 4) { - if (complain) - msyslog(LOG_ERR, - "getnetnum: \"%s\" invalid host number, line ignored", - num); -#ifdef DEBUG - if (debug > 3) - printf( - "getnetnum: \"%s\" invalid host number, line ignored\n", - num); -#endif - return 0; - } - - /* - * make up socket address. Clear it out for neatness. - */ - memset((void *)addr, 0, sizeof(struct sockaddr_in)); - addr->sin_family = AF_INET; - addr->sin_port = htons(NTP_PORT); - addr->sin_addr.s_addr = htonl(netnum); -#ifdef DEBUG - if (debug > 1) - printf("getnetnum given %s, got %s (%lx)\n", - num, ntoa(addr), (u_long)netnum); -#endif - return 1; -} diff --git a/contrib/ntp/ntpdate/ntptimeset.c b/contrib/ntp/ntpdate/ntptimeset.c deleted file mode 100644 index 2485aadb6..000000000 --- a/contrib/ntp/ntpdate/ntptimeset.c +++ /dev/null @@ -1,2164 +0,0 @@ -/* - * ntptimeset - get/set the time via ntp - * - * GOAL: - * The goal of ntptime is to set the current time on system startup - * to the best possible time using the network very wisely. It is assumed - * that after a resonable time has been sett then ntp daemon will - * maintain it. - * - * PROBLEM DOMAIN: - * We have three sets of issues related to acheiving the goal. The first - * issue is using the network when normal traffic is happening or when - * the entire network world is recovering from a campus wide power failure - * and is restarting. The second issue is the class of machine whether it - * is a user's office workstation being handled by an uneducated user or - * a server computer being handled by a trained operations staff. The third - * issue is whether the ratio of people to computers and whether the - * environment is stable and viable or not. - * - * NETWORK USAGE: - * The first issue of using the network wisely is a question of whether - * the network load and time server load and state are normal. If things - * are normal ntptime can do what ntpdate does of sending out 4 packets - * quickly to each server (new transmit done with each ack). However - * if network or time load is high then this scheme will simply contribute - * to problems. Given we have minimal state, we simply weight lost packets - * significantly and make sure we throttle output as much as possible - * without performance lost for quick startups. - * - * TRAINING AND KNOWLEDGE: - * The second issue of uneducated user of a office workstation versus a - * trained operation staff of a server machine translates into simply an - * issue of untrained and trained users. - * - * The training issue implies that for the sake of the users involved in the - * handling of their office workstation, problems and options should be - * communicated simply and effectively and not in terse expert related - * descriptions without possible options to be taken. The operator's training - * and education enables them to deal with either type of communication and - * control. - * - * AUTOMATION AND MANUAL CONTROL: - * The last issue boils down to a design problem. If the design tends to go - * into a manual mode when the environment is non-viable then one person - * handling many computers all at the same time will be heavily impacted. On - * the other hand, if the design tends to be automatic and does not indicate - * a way for the user to take over control then the computer will be - * unavailable for the user until the proble is resolved by someone else or - * the user. - * - * NOTE: Please do not have this program print out every minute some line, - * of output. If this happens and the environment is in trouble then - * many pages of paper on many different machines will be filled up. - * Save some tress in your lifetime. - * - * CONCLUSION: - * The behavior of the program derived from these three issues should be - * that during normal situations it quickly sets the time and allow the - * system to startup. - * - * However during abnormal conditions as detected by unresponsive servers, - * out-of-sync or bad responses and other detections, it should print out - * a simple but clear message and continue in a mellow way to get the best - * possible time. It may never get the time and if so should also indicate - * this. - * - * Rudy Nedved - * 18-May-1993 - * - **************************************************************** - * - * Much of the above is confusing or no longer relevant. For example, - * it is rare these days for a machine's console to be a printing terminal, - * so the comment about saving trees doesn't mean much. Nonetheless, - * the basic principles still stand: - * - * - Work automatically, without human control or intervention. To - * this end, we use the same configuration file as ntpd itself, so - * you don't have to specify servers or other information on the - * command line. We also recognize that sometimes we won't be able - * to contact any servers, and give up in that event instead of - * hanging forever. - * - * - Behave in a sane way, both internally and externally, even in the - * face of insane conditions. That means we back off quickly when - * we don't hear a response, to avoid network congestion. Like - * ntpd, we verify responses from several servers before accepting - * the new time data. - * - * However, we don't assume that the local clock is right, or even - * close, because it might not be at boot time, and we want to catch - * and correct that situation. This behaviour has saved us in several - * instances. On HP-UX 9.0x, there used to be a bug in adjtimed which - * would cause the time to be set to some wild value, making the machine - * essentially unusable (we use Kerberos authentication pervasively, - * and it requires workstations and servers to have a time within five - * minutes of the Kerberos server). We also have problems on PC's - * running both Linux and some Microsoft OS -- they tend to disagree - * on what the BIOS clock should say, and who should update it, and - * when. On those systems, we not only run ntptimeset at boot, we - * also reset the BIOS clock based on the result, so the correct - * time will be retained across reboots. - * - * For these reasons, and others, we have continued to use this tool - * rather than ntpdate. It is run automatically at boot time on every - * workstation and server in our facility. - * - * In the past, we called this program 'ntptime'. Unfortunately, the - * ntp v4 distribution also includes a program with that name. In - * order to avoid confusion, we have renamed our program 'ntptimeset', - * which more accurately describes what it does. - * - * Jeffrey T. Hutzelman (N3NHS) - * School of Computer Science - Research Computing Facility - * Carnegie Mellon University - Pittsburgh, PA - * 16-Aug-1999 - * - */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "ntp_machine.h" -#include "ntp_fp.h" -#include "ntp.h" -#include "ntp_io.h" -#include "iosignal.h" -#include "ntp_unixtime.h" -#include "ntpdate.h" -#include "ntp_string.h" -#include "ntp_syslog.h" -#include "ntp_select.h" -#include "ntp_stdlib.h" - -#ifdef HAVE_UNISTD_H -# include -#endif - -#include -#include -#include -#ifndef SYS_WINNT -# ifdef HAVE_SYS_SIGNAL_H -# include -# else -# include -# endif -# include -#endif /* SYS_WINNT */ - -#ifdef HAVE_SYS_RESOURCE_H -# include -#endif /* HAVE_SYS_RESOURCE_H */ - -#ifdef SYS_VXWORKS -# include "ioLib.h" -# include "sockLib.h" -# include "timers.h" -#endif - -#include "recvbuff.h" - -#ifdef SYS_WINNT -# define TARGET_RESOLUTION 1 /* Try for 1-millisecond accuracy - on Windows NT timers. */ -#pragma comment(lib, "winmm") -#endif /* SYS_WINNT */ - -/* - * Scheduling priority we run at - */ -#ifndef SYS_VXWORKS -# define NTPDATE_PRIO (-12) -#else -# define NTPDATE_PRIO (100) -#endif - -#if defined(HAVE_TIMER_SETTIME) || defined (HAVE_TIMER_CREATE) -/* POSIX TIMERS - vxWorks doesn't have itimer - casey */ -static timer_t ntpdate_timerid; -#endif - -/* - * Compatibility stuff for Version 2 - */ -#define NTP_MAXSKW 0x28f /* 0.01 sec in fp format */ -#define NTP_MINDIST 0x51f /* 0.02 sec in fp format */ -#define NTP_INFIN 15 /* max stratum, infinity a la Bellman-Ford */ -#define NTP_MAXWGT (8*FP_SECOND) /* maximum select weight 8 seconds */ -#define NTP_MAXLIST 5 /* maximum select list size */ -#define PEER_SHIFT 8 /* 8 suitable for crystal time base */ - -/* - * Debugging flag - */ -volatile int debug = 0; - -/* - * File descriptor masks etc. for call to select - */ -int fd; -fd_set fdmask; - -/* - * Initializing flag. All async routines watch this and only do their - * thing when it is clear. - */ -int initializing = 1; - -/* - * Alarm flag. Set when an alarm occurs - */ -volatile int alarm_flag = 0; - -/* - * Set the time if valid time determined - */ -int set_time = 0; - -/* - * transmission rate control - */ -#define MINTRANSMITS (3) /* minimum total packets per server */ -#define MAXXMITCOUNT (2) /* maximum packets per time interrupt */ - -/* - * time setting constraints - */ -#define DESIREDDISP (4*FP_SECOND) /* desired dispersion, (fp 4) */ -int max_period = DEFMAXPERIOD; -int min_servers = DEFMINSERVERS; -int min_valid = DEFMINVALID; - -/* - * counters related to time setting constraints - */ -int contacted = 0; /* # of servers we have sent to */ -int responding = 0; /* servers responding */ -int validcount = 0; /* servers with valid time */ -int valid_n_low = 0; /* valid time servers with low dispersion */ - -/* - * Unpriviledged port flag. - */ -int unpriv_port = 0; - -/* - * Program name. - */ -char *progname; - -/* - * Systemwide parameters and flags - */ -struct server **sys_servers; /* the server list */ -int sys_numservers = 0; /* number of servers to poll */ -int sys_authenticate = 0; /* true when authenticating */ -u_int32 sys_authkey = 0; /* set to authentication key in use */ -u_long sys_authdelay = 0; /* authentication delay */ - -/* - * The current internal time - */ -u_long current_time = 0; - -/* - * File of encryption keys - */ - -#ifndef KEYFILE -# ifndef SYS_WINNT -#define KEYFILE "/etc/ntp.keys" -# else -#define KEYFILE "%windir%\\ntp.keys" -# endif /* SYS_WINNT */ -#endif /* KEYFILE */ - -#ifndef SYS_WINNT -const char *key_file = KEYFILE; -#else -char key_file_storage[MAX_PATH+1], *key_file ; -#endif /* SYS_WINNT */ - -/* - * total packet counts - */ -u_long total_xmit = 0; -u_long total_recv = 0; - -/* - * Miscellaneous flags - */ -int verbose = 0; -#define HORRIBLEOK 3 /* how many packets to let out */ -int horrible = 0; /* how many packets we drop for testing */ -int secondhalf = 0; /* second half of timeout period */ -int printmsg = 0; /* print time response analysis */ - -/* - * The half time and finish time in internal time - */ -u_long half_time = 0; -u_long finish_time = 0; - - -int ntptimesetmain P((int argc, char *argv[])); -static void analysis P((int final)); -static int have_enough P((void)); -static void transmit P((register struct server *server)); -static void receive P((struct recvbuf *rbufp)); -static void clock_filter P((register struct server *server, s_fp d, l_fp *c)); -static void clock_count P((void)); -static struct server *clock_select P((void)); -static void set_local_clock P((void)); -static struct server *findserver P((struct sockaddr_in *addr)); -static void timer P((void)); -#ifndef SYS_WINNT -static RETSIGTYPE alarming P((int sig)); -#endif /* SYS_WINNT */ -static void init_alarm P((void)); -static void init_io P((void)); -static int sendpkt P((struct sockaddr_in *dest, struct pkt *pkt, int len)); - void input_handler P((l_fp *xts)); -static void printserver P((register struct server *pp, FILE *fp)); -#if !defined(HAVE_VSPRINTF) -int vsprintf P((char *str, const char *fmt, va_list ap)); -#endif - -#ifdef HAVE_SIGNALED_IO -extern void wait_for_signal P((void)); -extern void unblock_io_and_alarm P((void)); -extern void block_io_and_alarm P((void)); -#endif - - -#ifdef NO_MAIN_ALLOWED -CALL(ntptimeset,"ntptimeset",ntptimesetmain); - -void clear_globals() -{ - /* - * Debugging flag - */ - debug = 0; - - ntp_optind = 0; - - /* - * Initializing flag. All async routines watch this and only do their - * thing when it is clear. - */ - initializing = 1; - - /* - * Alarm flag. Set when an alarm occurs - */ - alarm_flag = 0; - - /* - * Unpriviledged port flag. - */ - unpriv_port = 0; - - /* - * Systemwide parameters and flags - */ - sys_numservers = 0; /* number of servers to poll */ - sys_authenticate = 0; /* true when authenticating */ - sys_authkey = 0; /* set to authentication key in use */ - sys_authdelay = 0; /* authentication delay */ - - /* - * The current internal time - */ - current_time = 0; - - verbose = 0; -} -#endif /* NO_MAIN_ALLOWED */ - -/* - * Main program. Initialize us and loop waiting for I/O and/or - * timer expiries. - */ -#ifndef NO_MAIN_ALLOWED -int -main( - int argc, - char *argv[] - ) -{ - return ntptimesetmain(argc, argv); -} -#endif /* NO_MAIN_ALLOWED */ - - -int -ntptimesetmain( - int argc, - char *argv[] - ) -{ - int was_alarmed; - int tot_recvbufs; - struct recvbuf *rbuf; - l_fp tmp; - int errflg; - int c; - extern char *ntp_optarg; - extern int ntp_optind; - int ltmp; - char *cfgpath; - -#ifdef SYS_WINNT - HANDLE process_handle; - - wVersionRequested = MAKEWORD(1,1); - if (WSAStartup(wVersionRequested, &wsaData)) { - msyslog(LOG_ERR, "No useable winsock.dll: %m"); - exit(1); - } -#endif /* SYS_WINNT */ - -#ifdef NO_MAIN_ALLOWED - clear_globals(); -#endif - - errflg = 0; - cfgpath = 0; - progname = argv[0]; - syslogit = 0; - - /* - * Decode argument list - */ - while ((c = ntp_getopt(argc, argv, "a:c:de:slt:uvHS:V:")) != EOF) - switch (c) - { - case 'a': - c = atoi(ntp_optarg); - sys_authenticate = 1; - sys_authkey = c; - break; - case 'c': - cfgpath = ntp_optarg; - break; - case 'd': - ++debug; - break; - case 'e': - if (!atolfp(ntp_optarg, &tmp) - || tmp.l_ui != 0) { - (void) fprintf(stderr, - "%s: encryption delay %s is unlikely\n", - progname, ntp_optarg); - errflg++; - } else { - sys_authdelay = tmp.l_uf; - } - break; - case 's': - set_time = 1; - break; - case 'l': - syslogit = 1; - break; - case 't': - ltmp = atoi(ntp_optarg); - if (ltmp <= 0) { - (void) fprintf(stderr, - "%s: maximum time period (%d) is invalid\n", - progname, ltmp); - errflg++; - } - else - max_period = ltmp; - break; - case 'u': - unpriv_port = 1; - break; - case 'v': - ++verbose; - break; - case 'H': - horrible++; - break; - case 'S': - ltmp = atoi(ntp_optarg); - if (ltmp <= 0) { - (void) fprintf(stderr, - "%s: minimum responding (%d) is invalid\n", - progname, ltmp); - errflg++; - } - else - min_servers = ltmp; - break; - case 'V': - ltmp = atoi(ntp_optarg); - if (ltmp <= 0) { - (void) fprintf(stderr, - "%s: minimum valid (%d) is invalid\n", - progname, ltmp); - errflg++; - } - else - min_valid = ltmp; - break; - case '?': - ++errflg; - break; - default: - break; - } - - - if (errflg || ntp_optind < argc) { - fprintf(stderr,"usage: %s [switches...]\n",progname); - fprintf(stderr," -v (verbose)\n"); - fprintf(stderr," -c path (set config file path)\n"); - fprintf(stderr," -a key (authenticate using key)\n"); - fprintf(stderr," -e delay (authentication delay)\n"); - fprintf(stderr," -S num (# of servers that must respond)\n"); - fprintf(stderr," -V num (# of servers that must valid)\n"); - fprintf(stderr," -s (set the time based if okay)\n"); - fprintf(stderr," -t secs (time period before ending)\n"); - fprintf(stderr," -l (use syslog facility)\n"); - fprintf(stderr," -u (use unprivileged port)\n"); - fprintf(stderr," -H (drop packets for debugging)\n"); - fprintf(stderr," -d (debug output)\n"); - exit(2); - } - - /* - * Logging. Open the syslog if we have to - */ - if (syslogit) { -#if !defined (SYS_WINNT) && !defined (SYS_VXWORKS) && !defined SYS_CYGWIN32 -# ifndef LOG_DAEMON - openlog("ntptimeset", LOG_PID); -# else - -# ifndef LOG_NTP -# define LOG_NTP LOG_DAEMON -# endif - openlog("ntptimeset", LOG_PID | LOG_NDELAY, LOG_NTP); - if (debug) - setlogmask(LOG_UPTO(LOG_DEBUG)); - else - setlogmask(LOG_UPTO(LOG_INFO)); -# endif /* LOG_DAEMON */ -#endif /* SYS_WINNT */ - } - - if (debug || verbose) - msyslog(LOG_INFO, "%s", Version); - - if (horrible) - msyslog(LOG_INFO, "Dropping %d out of %d packets", - horrible,horrible+HORRIBLEOK); - /* - * Add servers we are going to be polling - */ - loadservers(cfgpath); - - if (sys_numservers < min_servers) { - msyslog(LOG_ERR, "Found %d servers, require %d servers", - sys_numservers,min_servers); - exit(2); - } - - /* - * determine when we will end at least - */ - finish_time = max_period * TIMER_HZ; - half_time = finish_time >> 1; - - /* - * Initialize the time of day routines and the I/O subsystem - */ - if (sys_authenticate) { - init_auth(); -#ifdef SYS_WINNT - if (!key_file) key_file = KEYFILE; - if (!ExpandEnvironmentStrings(key_file, key_file_storage, MAX_PATH)) - { - msyslog(LOG_ERR, "ExpandEnvironmentStrings(%s) failed: %m\n", - key_file); - } else { - key_file = key_file_storage; - } -#endif /* SYS_WINNT */ - - if (!authreadkeys(key_file)) { - msyslog(LOG_ERR, "no key file, exiting"); - exit(1); - } - if (!authistrusted(sys_authkey)) { - char buf[10]; - - (void) sprintf(buf, "%lu", (unsigned long)sys_authkey); - msyslog(LOG_ERR, "authentication key %s unknown", buf); - exit(1); - } - } - init_io(); - init_alarm(); - - /* - * Set the priority. - */ -#ifdef SYS_VXWORKS - taskPrioritySet( taskIdSelf(), NTPDATE_PRIO); -#endif -#if defined(HAVE_ATT_NICE) - nice (NTPDATE_PRIO); -#endif -#if defined(HAVE_BSD_NICE) - (void) setpriority(PRIO_PROCESS, 0, NTPDATE_PRIO); -#endif -#ifdef SYS_WINNT - process_handle = GetCurrentProcess(); - if (!SetPriorityClass(process_handle, (DWORD) REALTIME_PRIORITY_CLASS)) { - msyslog(LOG_ERR, "SetPriorityClass failed: %m"); - } -#endif /* SYS_WINNT */ - - initializing = 0; - - /* - * Use select() on all on all input fd's for unlimited - * time. select() will terminate on SIGALARM or on the - * reception of input. Using select() means we can't do - * robust signal handling and we get a potential race - * between checking for alarms and doing the select(). - * Mostly harmless, I think. - * Keep going until we have enough information, or time is up. - */ - /* On VMS, I suspect that select() can't be interrupted - * by a "signal" either, so I take the easy way out and - * have select() time out after one second. - * System clock updates really aren't time-critical, - * and - lacking a hardware reference clock - I have - * yet to learn about anything else that is. - */ - was_alarmed = 0; - while (finish_time > current_time) { -#if !defined(HAVE_SIGNALED_IO) - fd_set rdfdes; - int nfound; -#elif defined(HAVE_SIGNALED_IO) - block_io_and_alarm(); -#endif - - tot_recvbufs = full_recvbuffs(); /* get received buffers */ - if (printmsg) { - printmsg = 0; - analysis(0); - } - if (alarm_flag) { /* alarmed? */ - was_alarmed = 1; - alarm_flag = 0; - } - - if (!was_alarmed && tot_recvbufs > 0) { - /* - * Nothing to do. Wait for something. - */ -#ifndef HAVE_SIGNALED_IO - rdfdes = fdmask; -# if defined(VMS) || defined(SYS_VXWORKS) - /* make select() wake up after one second */ - { - struct timeval t1; - - t1.tv_sec = 1; t1.tv_usec = 0; - nfound = select(fd+1, &rdfdes, (fd_set *)0, - (fd_set *)0, &t1); - } -# else - nfound = select(fd+1, &rdfdes, (fd_set *)0, - (fd_set *)0, (struct timeval *)0); -# endif /* VMS */ - if (nfound > 0) { - l_fp ts; - get_systime(&ts); - (void)input_handler(&ts); - } - else if (nfound == -1 && errno != EINTR) - msyslog(LOG_ERR, "select() error: %m"); - else if (debug) { -# if !defined SYS_VXWORKS && !defined SYS_CYGWIN32 /* to unclutter log */ - msyslog(LOG_DEBUG, "select(): nfound=%d, error: %m", nfound); -# endif - } -#else /* HAVE_SIGNALED_IO */ - - wait_for_signal(); -#endif /* HAVE_SIGNALED_IO */ - if (alarm_flag) /* alarmed? */ - { - was_alarmed = 1; - alarm_flag = 0; - } - tot_recvbufs = full_recvbuffs(); /* get received buffers */ - } -#ifdef HAVE_SIGNALED_IO - unblock_io_and_alarm(); -#endif /* HAVE_SIGNALED_IO */ - - /* - * Out here, signals are unblocked. Call timer routine - * to process expiry. - */ - if (was_alarmed) - { - timer(); - was_alarmed = 0; - } - - /* - * Call the data procedure to handle each received - * packet. - */ - rbuf = get_full_recv_buffer(); - while (rbuf != NULL) - { - receive(rbuf); - freerecvbuf(rbuf); - rbuf = get_full_recv_buffer(); - } - - /* - * Do we have enough information to stop now? - */ - if (have_enough()) - break; /* time to end */ - - /* - * Go around again - */ - } - - /* - * adjust the clock and exit accordingly - */ - set_local_clock(); - - /* - * if we get here then we are in trouble - */ - return(1); -} - - -/* - * analysis - print a message indicating what is happening with time service - * must mimic have_enough() procedure. - */ -static void -analysis( - int final - ) -{ - if (contacted < sys_numservers) { - printf("%d servers of %d have been probed with %d packets\n", - contacted,sys_numservers,MINTRANSMITS); - return; - } - if (!responding) { - printf("No response from any of %d servers, network problem?\n", - sys_numservers); - return; - } - else if (responding < min_servers) { - printf("%d servers out of %d responding, need at least %d.\n", - responding, sys_numservers, min_servers); - return; - } - if (!validcount) { - printf("%d servers responding but none have valid time\n", - responding); - return; - } - else if (validcount < min_valid) { - printf("%d servers responding, %d are valid, need %d valid\n", - responding,validcount,min_valid); - return; - } - if (!final && valid_n_low != validcount) { - printf("%d valid servers but only %d have low dispersion\n", - validcount,valid_n_low); - return; - } -} - - -/* have_enough - see if we have enough information to terminate probing - */ -static int -have_enough(void) -{ - /* have we contacted all servers yet? */ - if (contacted < sys_numservers) - return 0; /* no...try some more */ - - /* have we got at least minimum servers responding? */ - if (responding < min_servers) - return 0; /* no...try some more */ - - /* count the clocks */ - (void) clock_count(); - - /* have we got at least minimum valid clocks? */ - if (validcount <= 0 || validcount < min_valid) - return 0; /* no...try some more */ - - /* do we have all valid servers with low dispersion */ - if (!secondhalf && valid_n_low != validcount) - return 0; - - /* if we get into the secondhalf then we ignore dispersion */ - - /* all conditions have been met...end */ - return 1; -} - - -/* - * transmit - transmit a packet to the given server, or mark it completed. - * This is called by the timeout routine and by the receive - * procedure. - */ -static void -transmit( - register struct server *server - ) -{ - struct pkt xpkt; - int timeout; - - if (debug > 2) - printf("transmit(%s)\n", ntoa(&server->srcadr)); - - if ((server->reach & 01) == 0) { - l_fp ts; - /* - * Last message to this server timed out. Shift - * zeros into the filter. - */ - L_CLR(&ts); - clock_filter(server, 0, &ts); - } - - /* - * shift reachable register over - */ - server->reach <<= 1; - - /* - * If we're here, send another message to the server. Fill in - * the packet and let 'er rip. - */ - xpkt.li_vn_mode = PKT_LI_VN_MODE(LEAP_NOTINSYNC, - server->version, MODE_CLIENT); - xpkt.stratum = STRATUM_TO_PKT(STRATUM_UNSPEC); - xpkt.ppoll = NTP_MINPOLL; - xpkt.precision = NTPDATE_PRECISION; - xpkt.rootdelay = htonl(NTPDATE_DISTANCE); - xpkt.rootdispersion = htonl(NTPDATE_DISP); - xpkt.refid = htonl(NTPDATE_REFID); - L_CLR(&xpkt.reftime); - L_CLR(&xpkt.org); - L_CLR(&xpkt.rec); - - /* - * Determine whether to authenticate or not. If so, - * fill in the extended part of the packet and do it. - * If not, just timestamp it and send it away. - */ - if (sys_authenticate) { - int len; - - xpkt.exten[0] = htonl(sys_authkey); - get_systime(&server->xmt); - L_ADDUF(&server->xmt, sys_authdelay); - HTONL_FP(&server->xmt, &xpkt.xmt); - len = authencrypt(sys_authkey, (u_int32 *)&xpkt, LEN_PKT_NOMAC); - if (sendpkt(&(server->srcadr), &xpkt, (int)(LEN_PKT_NOMAC + len))) { - if (debug > 1) - printf("failed transmit auth to %s\n", - ntoa(&(server->srcadr))); - return; - } - - if (debug > 1) - printf("transmit auth to %s\n", - ntoa(&(server->srcadr))); - } else { - get_systime(&(server->xmt)); - HTONL_FP(&server->xmt, &xpkt.xmt); - if (sendpkt(&(server->srcadr), &xpkt, LEN_PKT_NOMAC)) { - if (debug > 1) - printf("failed transmit to %s\n", - ntoa(&(server->srcadr))); - return; - } - - if (debug > 1) - printf("transmit to %s\n", ntoa(&(server->srcadr))); - } - - /* - * count transmits, record contacted count and set transmit time - */ - if (++server->xmtcnt == MINTRANSMITS) - contacted++; - server->last_xmit = current_time; - - /* - * determine timeout for this packet. The more packets we send - * to the host, the slower we get. If the host indicates that - * it is not "sane" then we expect even less. - */ - if (server->xmtcnt < MINTRANSMITS) { - /* we have not sent enough */ - timeout = TIMER_HZ; /* 1 second probe */ - } - else if (server->rcvcnt <= 0) { - /* we have heard nothing */ - if (secondhalf) - timeout = TIMER_HZ<<4; /* 16 second probe */ - else - timeout = TIMER_HZ<<3; /* 8 second probe */ - } - else { - /* if we have low dispersion then probe infrequently */ - if (server->dispersion <= DESIREDDISP) - timeout = TIMER_HZ<<4; /* 16 second probe */ - /* if the server is not in sync then let it alone */ - else if (server->leap == LEAP_NOTINSYNC) - timeout = TIMER_HZ<<4; /* 16 second probe */ - /* if the server looks broken ignore it */ - else if (server->org.l_ui < server->reftime.l_ui) - timeout = TIMER_HZ<<5; /* 32 second probe */ - else if (secondhalf) - timeout = TIMER_HZ<<2; /* 4 second probe */ - else - timeout = TIMER_HZ<<1; /* 2 second probe */ - } - - /* - * set next transmit time based on timeout - */ - server->event_time = current_time + timeout; -} - - -/* - * receive - receive and process an incoming frame - */ -static void -receive( - struct recvbuf *rbufp - ) -{ - register struct pkt *rpkt; - register struct server *server; - register s_fp di; - l_fp t10, t23; - l_fp org; - l_fp rec; - l_fp ci; - int has_mac; - int is_authentic; - - if (debug > 2) - printf("receive(%s)\n", ntoa(&rbufp->srcadr)); - /* - * Check to see if the packet basically looks like something - * intended for us. - */ - if (rbufp->recv_length == LEN_PKT_NOMAC) - has_mac = 0; - else if (rbufp->recv_length >= LEN_PKT_NOMAC) - has_mac = 1; - else { - if (debug > 2) - printf("receive: packet length %d\n", - rbufp->recv_length); - return; /* funny length packet */ - } - - rpkt = &(rbufp->recv_pkt); - if (PKT_VERSION(rpkt->li_vn_mode) < NTP_OLDVERSION || - PKT_VERSION(rpkt->li_vn_mode) > NTP_VERSION) { - if (debug > 1) - printf("receive: bad version %d\n", - PKT_VERSION(rpkt->li_vn_mode)); - return; - } - - if ((PKT_MODE(rpkt->li_vn_mode) != MODE_SERVER - && PKT_MODE(rpkt->li_vn_mode) != MODE_PASSIVE) - || rpkt->stratum >=STRATUM_UNSPEC) { - if (debug > 1) - printf("receive: mode %d stratum %d\n", - PKT_MODE(rpkt->li_vn_mode), rpkt->stratum); - return; - } - - /* - * So far, so good. See if this is from a server we know. - */ - server = findserver(&(rbufp->srcadr)); - if (server == NULL) { - if (debug > 1) - printf("receive: server not found\n"); - return; - } - - /* - * Decode the org timestamp and make sure we're getting a response - * to our last request. - */ - NTOHL_FP(&rpkt->org, &org); - if (!L_ISEQU(&org, &server->xmt)) { - if (debug > 1) - printf("receive: pkt.org and peer.xmt differ\n"); - return; - } - - /* - * Check out the authenticity if we're doing that. - */ - if (!sys_authenticate) - is_authentic = 1; - else { - is_authentic = 0; - - if (debug > 3) - printf("receive: rpkt keyid=%ld sys_authkey=%ld decrypt=%ld\n", - (long int)ntohl(rpkt->exten[0]), (long int)sys_authkey, - (long int)authdecrypt(sys_authkey, (u_int32 *)rpkt, - LEN_PKT_NOMAC, (int)(rbufp->recv_length - LEN_PKT_NOMAC))); - - if (has_mac && ntohl(rpkt->exten[0]) == sys_authkey && - authdecrypt(sys_authkey, (u_int32 *)rpkt, LEN_PKT_NOMAC, - (int)(rbufp->recv_length - LEN_PKT_NOMAC))) - is_authentic = 1; - if (debug) - printf("receive: authentication %s\n", - is_authentic ? "passed" : "failed"); - } - server->trust <<= 1; - if (!is_authentic) - server->trust |= 1; - - /* - * Looks good. Record info from the packet. - */ - server->leap = PKT_LEAP(rpkt->li_vn_mode); - server->stratum = PKT_TO_STRATUM(rpkt->stratum); - server->precision = rpkt->precision; - server->rootdelay = ntohl(rpkt->rootdelay); - server->rootdispersion = ntohl(rpkt->rootdispersion); - server->refid = rpkt->refid; - NTOHL_FP(&rpkt->reftime, &server->reftime); - NTOHL_FP(&rpkt->rec, &rec); - NTOHL_FP(&rpkt->xmt, &server->org); - - /* - * count this guy as responding - */ - server->reach |= 1; - if (server->rcvcnt++ == 0) - responding++; - - /* - * Make sure the server is at least somewhat sane. If not, ignore - * it for later. - */ - if (L_ISZERO(&rec) || !L_ISHIS(&server->org, &rec)) { - if (debug > 1) - printf("receive: pkt insane\n"); - return; - } - - /* - * Calculate the round trip delay (di) and the clock offset (ci). - * We use the equations (reordered from those in the spec): - * - * d = (t2 - t3) - (t1 - t0) - * c = ((t2 - t3) + (t1 - t0)) / 2 - */ - t10 = server->org; /* pkt.xmt == t1 */ - L_SUB(&t10, &rbufp->recv_time); /* recv_time == t0*/ - - t23 = rec; /* pkt.rec == t2 */ - L_SUB(&t23, &org); /* pkt->org == t3 */ - - /* now have (t2 - t3) and (t0 - t1). Calculate (ci) and (di) */ - ci = t10; - L_ADD(&ci, &t23); - L_RSHIFT(&ci); - - /* - * Calculate di in t23 in full precision, then truncate - * to an s_fp. - */ - L_SUB(&t23, &t10); - di = LFPTOFP(&t23); - - if (debug > 3) - printf("offset: %s, delay %s\n", lfptoa(&ci, 6), fptoa(di, 5)); - - di += (FP_SECOND >> (-(int)NTPDATE_PRECISION)) - + (FP_SECOND >> (-(int)server->precision)) + NTP_MAXSKW; - - if (di <= 0) { /* value still too raunchy to use? */ - L_CLR(&ci); - di = 0; - } else { - di = max(di, NTP_MINDIST); - } - - - /* - * This one is valid. Give it to clock_filter(), - */ - clock_filter(server, di, &ci); - if (debug > 1) - printf("receive from %s\n", ntoa(&rbufp->srcadr)); - - /* - * See if we should goes the transmission. If not return now - * otherwise have the next event time be shortened - */ - if (server->stratum <= NTP_INFIN) - return; /* server does not have a stratum */ - if (server->leap == LEAP_NOTINSYNC) - return; /* just booted server or out of sync */ - if (!L_ISHIS(&server->org, &server->reftime)) - return; /* broken host */ - if (server->trust != 0) - return; /* can not trust it */ - - if (server->dispersion < DESIREDDISP) - return; /* we have the desired dispersion */ - - server->event_time -= (TIMER_HZ+1); -} - - -/* - * clock_filter - add clock sample, determine a server's delay, dispersion - * and offset - */ -static void -clock_filter( - register struct server *server, - s_fp di, - l_fp *c - ) -{ - register int i, j; - int ord[NTP_SHIFT]; - - /* - * Insert sample and increment nextpt - */ - - i = server->filter_nextpt; - server->filter_delay[i] = di; - server->filter_offset[i] = *c; - server->filter_soffset[i] = LFPTOFP(c); - server->filter_nextpt++; - if (server->filter_nextpt >= NTP_SHIFT) - server->filter_nextpt = 0; - - /* - * Sort indices into increasing delay order - */ - for (i = 0; i < NTP_SHIFT; i++) - ord[i] = i; - - for (i = 0; i < (NTP_SHIFT-1); i++) { - for (j = i+1; j < NTP_SHIFT; j++) { - if (server->filter_delay[ord[j]] == 0) - continue; - if (server->filter_delay[ord[i]] == 0 - || (server->filter_delay[ord[i]] - > server->filter_delay[ord[j]])) { - register int tmp; - - tmp = ord[i]; - ord[i] = ord[j]; - ord[j] = tmp; - } - } - } - - /* - * Now compute the dispersion, and assign values to delay and - * offset. If there are no samples in the register, delay and - * offset go to zero and dispersion is set to the maximum. - */ - if (server->filter_delay[ord[0]] == 0) { - server->delay = 0; - L_CLR(&server->offset); - server->soffset = 0; - server->dispersion = PEER_MAXDISP; - } else { - register s_fp d; - - server->delay = server->filter_delay[ord[0]]; - server->offset = server->filter_offset[ord[0]]; - server->soffset = LFPTOFP(&server->offset); - server->dispersion = 0; - for (i = 1; i < NTP_SHIFT; i++) { - if (server->filter_delay[ord[i]] == 0) - d = PEER_MAXDISP; - else { - d = server->filter_soffset[ord[i]] - - server->filter_soffset[ord[0]]; - if (d < 0) - d = -d; - if (d > PEER_MAXDISP) - d = PEER_MAXDISP; - } - /* - * XXX This *knows* PEER_FILTER is 1/2 - */ - server->dispersion += (u_fp)(d) >> i; - } - } - /* - * We're done - */ -} - - -/* clock_count - count the clock sources we have - */ -static void -clock_count(void) -{ - register struct server *server; - register int n; - - /* reset counts */ - validcount = valid_n_low = 0; - - /* go through the list of servers and count the clocks we believe - * and that have low dispersion - */ - for (n = 0; n < sys_numservers; n++) { - server = sys_servers[n]; - if (server->delay == 0) { - continue; /* no data */ - } - if (server->stratum > NTP_INFIN) { - continue; /* stratum no good */ - } - if (server->delay > NTP_MAXWGT) { - continue; /* too far away */ - } - if (server->leap == LEAP_NOTINSYNC) - continue; /* he's in trouble */ - if (!L_ISHIS(&server->org, &server->reftime)) { - continue; /* very broken host */ - } - if ((server->org.l_ui - server->reftime.l_ui) >= NTP_MAXAGE) { - continue; /* too long without sync */ - } - if (server->trust != 0) { - continue; - } - - /* - * This one is a valid time source.. - */ - validcount++; - - /* - * See if this one has a okay low dispersion - */ - if (server->dispersion <= DESIREDDISP) - valid_n_low++; - } - - if (debug > 1) - printf("have %d, valid %d, low %d\n", - responding, validcount, valid_n_low); -} - - -/* - * clock_select - select the pick-of-the-litter clock from the samples - * we've got. - */ -static struct server * -clock_select(void) -{ - register struct server *server; - register int i; - register int nlist; - register s_fp d; - register int j; - register int n; - s_fp local_threshold; - struct server *server_list[NTP_MAXCLOCK]; - u_fp server_badness[NTP_MAXCLOCK]; - struct server *sys_server; - - /* - * This first chunk of code is supposed to go through all - * servers we know about to find the NTP_MAXLIST servers which - * are most likely to succeed. We run through the list - * doing the sanity checks and trying to insert anyone who - * looks okay. We are at all times aware that we should - * only keep samples from the top two strata and we only need - * NTP_MAXLIST of them. - */ - nlist = 0; /* none yet */ - for (n = 0; n < sys_numservers; n++) { - server = sys_servers[n]; - if (server->delay == 0) - continue; /* no data */ - if (server->stratum > NTP_INFIN) - continue; /* stratum no good */ - if (server->delay > NTP_MAXWGT) { - continue; /* too far away */ - } - if (server->leap == LEAP_NOTINSYNC) - continue; /* he's in trouble */ - if (!L_ISHIS(&server->org, &server->reftime)) { - continue; /* very broken host */ - } - if ((server->org.l_ui - server->reftime.l_ui) - >= NTP_MAXAGE) { - continue; /* too long without sync */ - } - if (server->trust != 0) { - continue; - } - - /* - * This one seems sane. Find where he belongs - * on the list. - */ - d = server->dispersion + server->dispersion; - for (i = 0; i < nlist; i++) - if (server->stratum <= server_list[i]->stratum) - break; - for ( ; i < nlist; i++) { - if (server->stratum < server_list[i]->stratum) - break; - if (d < (s_fp) server_badness[i]) - break; - } - - /* - * If i points past the end of the list, this - * guy is a loser, else stick him in. - */ - if (i >= NTP_MAXLIST) - continue; - for (j = nlist; j > i; j--) - if (j < NTP_MAXLIST) { - server_list[j] = server_list[j-1]; - server_badness[j] - = server_badness[j-1]; - } - - server_list[i] = server; - server_badness[i] = d; - if (nlist < NTP_MAXLIST) - nlist++; - } - - /* - * Got the five-or-less best. Cut the list where the number of - * strata exceeds two. - */ - j = 0; - for (i = 1; i < nlist; i++) - if (server_list[i]->stratum > server_list[i-1]->stratum) - if (++j == 2) { - nlist = i; - break; - } - - /* - * Whew! What we should have by now is 0 to 5 candidates for - * the job of syncing us. If we have none, we're out of luck. - * If we have one, he's a winner. If we have more, do falseticker - * detection. - */ - - if (nlist == 0) - sys_server = 0; - else if (nlist == 1) { - sys_server = server_list[0]; - } else { - /* - * Re-sort by stratum, bdelay estimate quality and - * server.delay. - */ - for (i = 0; i < nlist-1; i++) - for (j = i+1; j < nlist; j++) { - if (server_list[i]->stratum - < server_list[j]->stratum) - break; /* already sorted by stratum */ - if (server_list[i]->delay - < server_list[j]->delay) - continue; - server = server_list[i]; - server_list[i] = server_list[j]; - server_list[j] = server; - } - - /* - * Calculate the fixed part of the dispersion limit - */ - local_threshold = (FP_SECOND >> (-(int)NTPDATE_PRECISION)) - + NTP_MAXSKW; - - /* - * Now drop samples until we're down to one. - */ - while (nlist > 1) { - for (n = 0; n < nlist; n++) { - server_badness[n] = 0; - for (j = 0; j < nlist; j++) { - if (j == n) /* with self? */ - continue; - d = server_list[j]->soffset - - server_list[n]->soffset; - if (d < 0) /* absolute value */ - d = -d; - /* - * XXX This code *knows* that - * NTP_SELECT is 3/4 - */ - for (i = 0; i < j; i++) - d = (d>>1) + (d>>2); - server_badness[n] += d; - } - } - - /* - * We now have an array of nlist badness - * coefficients. Find the badest. Find - * the minimum precision while we're at - * it. - */ - i = 0; - n = server_list[0]->precision;; - for (j = 1; j < nlist; j++) { - if (server_badness[j] >= server_badness[i]) - i = j; - if (n > server_list[j]->precision) - n = server_list[j]->precision; - } - - /* - * i is the index of the server with the worst - * dispersion. If his dispersion is less than - * the threshold, stop now, else delete him and - * continue around again. - */ - if (server_badness[i] < (local_threshold - + (FP_SECOND >> (-n)))) - break; - for (j = i + 1; j < nlist; j++) - server_list[j-1] = server_list[j]; - nlist--; - } - - /* - * What remains is a list of less than 5 servers. Take - * the best. - */ - sys_server = server_list[0]; - } - - /* - * That's it. Return our server. - */ - return sys_server; -} - - -/* - * set_local_clock -- handle setting the local clock or displaying info. - */ -static void -set_local_clock(void) -{ - register int i; - register struct server *server; - time_t tmp; - double dtemp; - - /* - * if setting time then print final analysis - */ - if (set_time) - analysis(1); - - /* - * pick a clock - */ - server = clock_select(); - - /* - * do some display of information - */ - if (debug || verbose) { - for (i = 0; i < sys_numservers; i++) - printserver(sys_servers[i], stdout); - if (debug) - printf("packets sent %ld, received %ld\n", - total_xmit, total_recv); - } - - /* - * see if we have a server to set the time with - */ - if (server == 0) { - if (!set_time || verbose) - fprintf(stdout,"No servers available to sync time with\n"); - exit(1); - } - - /* - * we have a valid and selected time to use!!!!! - */ - - /* - * if we are not setting the time then display offset and exit - */ - if (!set_time) { - fprintf(stdout, - "Your clock is off by %s seconds. (%s) [%ld/%ld]\n", - lfptoa(&server->offset, 7), - ntoa(&server->srcadr), - total_xmit, total_recv); - exit(0); - } - - /* - * set the clock - * XXX: Examine the more flexible approach used by ntpdate. - * Note that a design consideration here is that we sometimes - * _want_ to step the clock by a _huge_ amount in either - * direction, because the local clock is completely bogus. - * This condition must be recognized and dealt with, so - * that we always get a good time when this completes. - * -- jhutz+@cmu.edu, 16-Aug-1999 - */ - LFPTOD(&server->offset, dtemp); - step_systime(dtemp); - time(&tmp); - fprintf(stdout,"Time set to %.20s [%s %s %ld/%ld]\n", - ctime(&tmp)+4, - ntoa(&server->srcadr), - lfptoa(&server->offset, 7), - total_xmit, total_recv); - exit(0); -} - - -/* - * findserver - find a server in the list given its address - */ -static struct server * -findserver( - struct sockaddr_in *addr - ) -{ - register int i; - register u_int32 netnum; - - if (htons(addr->sin_port) != NTP_PORT) - return 0; - netnum = addr->sin_addr.s_addr; - - for (i = 0; i < sys_numservers; i++) { - if (netnum == sys_servers[i]->srcadr.sin_addr.s_addr) - return sys_servers[i]; - } - return 0; -} - - -/* - * timer - process a timer interrupt - */ -static void -timer(void) -{ - register int k; - - /* - * Bump the current idea of the time - */ - current_time++; - - /* - * see if we have reached half time - */ - if (current_time >= half_time && !secondhalf) { - secondhalf++; - if (debug) - printf("\nSecond Half of Timeout!\n"); - printmsg++; - } - - /* - * We only want to send a few packets per transmit interrupt - * to throttle things - */ - for(k = 0;k < MAXXMITCOUNT;k++) { - register int i, oldi; - register u_long oldxtime; - - /* - * We want to send a packet out for a server that has an - * expired event time. However to be mellow about this, we only - * use one expired event timer and to avoid starvation we use - * the one with the oldest last transmit time. - */ - oldi = -1; - oldxtime = 0; - for (i = 0; i < sys_numservers; i++) { - if (sys_servers[i]->event_time <= current_time) { - if (oldi < 0 || oldxtime > sys_servers[i]->last_xmit) { - oldxtime = sys_servers[i]->last_xmit; - oldi = i; - } - } - } - if (oldi >= 0) - transmit(sys_servers[oldi]); - else - break; /* no expired event */ - } /* end of transmit loop */ -} - - -#ifndef SYS_WINNT -/* - * alarming - record the occurance of an alarm interrupt - */ -static RETSIGTYPE -alarming( - int sig - ) -#else -void CALLBACK -alarming(UINT uTimerID, UINT uMsg, DWORD dwUser, DWORD dw1, DWORD dw2) -#endif /* SYS_WINNT */ -{ - alarm_flag++; -} - - -/* - * init_alarm - set up the timer interrupt - */ -static void -init_alarm(void) -{ -#ifndef SYS_WINNT -# ifndef HAVE_TIMER_SETTIME - struct itimerval itimer; -# else - struct itimerspec ntpdate_itimer; -# endif -#else - TIMECAPS tc; - UINT wTimerRes, wTimerID; -# endif /* SYS_WINNT */ -#if defined SYS_CYGWIN32 || defined SYS_WINNT - HANDLE hToken; - TOKEN_PRIVILEGES tkp; - DWORD dwUser = 0; -#endif /* SYS_WINNT */ - - alarm_flag = 0; - -#ifndef SYS_WINNT -# if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) - alarm_flag = 0; - /* this code was put in as setitimer() is non existant this us the - * POSIX "equivalents" setup - casey - */ - /* ntpdate_timerid is global - so we can kill timer later */ - if (timer_create (CLOCK_REALTIME, NULL, &ntpdate_timerid) == -# ifdef SYS_VXWORKS - ERROR -# else - -1 -# endif - ) - { - fprintf (stderr, "init_alarm(): timer_create (...) FAILED\n"); - return; - } - - /* TIMER_HZ = (5) - * Set up the alarm interrupt. The first comes 1/(2*TIMER_HZ) - * seconds from now and they continue on every 1/TIMER_HZ seconds. - */ - (void) signal_no_reset(SIGALRM, alarming); - ntpdate_itimer.it_interval.tv_sec = ntpdate_itimer.it_value.tv_sec = 0; - ntpdate_itimer.it_interval.tv_nsec = 1000000000/TIMER_HZ; - ntpdate_itimer.it_value.tv_nsec = 1000000000/(TIMER_HZ<<1); - timer_settime(ntpdate_timerid, 0 /* !TIMER_ABSTIME */, &ntpdate_itimer, NULL); -# else - /* - * Set up the alarm interrupt. The first comes 1/(2*TIMER_HZ) - * seconds from now and they continue on every 1/TIMER_HZ seconds. - */ - (void) signal_no_reset(SIGALRM, alarming); - itimer.it_interval.tv_sec = itimer.it_value.tv_sec = 0; - itimer.it_interval.tv_usec = 1000000/TIMER_HZ; - itimer.it_value.tv_usec = 1000000/(TIMER_HZ<<1); - setitimer(ITIMER_REAL, &itimer, (struct itimerval *)0); -# endif -#if defined SYS_CYGWIN32 - /* - * Get previleges needed for fiddling with the clock - */ - - /* get the current process token handle */ - if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY, &hToken)) { - msyslog(LOG_ERR, "OpenProcessToken failed: %m"); - exit(1); - } - /* get the LUID for system-time privilege. */ - LookupPrivilegeValue(NULL, SE_SYSTEMTIME_NAME, &tkp.Privileges[0].Luid); - tkp.PrivilegeCount = 1; /* one privilege to set */ - tkp.Privileges[0].Attributes = SE_PRIVILEGE_ENABLED; - /* get set-time privilege for this process. */ - AdjustTokenPrivileges(hToken, FALSE, &tkp, 0,(PTOKEN_PRIVILEGES) NULL, 0); - /* cannot test return value of AdjustTokenPrivileges. */ - if (GetLastError() != ERROR_SUCCESS) - msyslog(LOG_ERR, "AdjustTokenPrivileges failed: %m"); -#endif -#else /* SYS_WINNT */ - _tzset(); - - /* - * Get previleges needed for fiddling with the clock - */ - - /* get the current process token handle */ - if (!OpenProcessToken(GetCurrentProcess(), TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY, &hToken)) { - msyslog(LOG_ERR, "OpenProcessToken failed: %m"); - exit(1); - } - /* get the LUID for system-time privilege. */ - LookupPrivilegeValue(NULL, SE_SYSTEMTIME_NAME, &tkp.Privileges[0].Luid); - tkp.PrivilegeCount = 1; /* one privilege to set */ - tkp.Privileges[0].Attributes = SE_PRIVILEGE_ENABLED; - /* get set-time privilege for this process. */ - AdjustTokenPrivileges(hToken, FALSE, &tkp, 0,(PTOKEN_PRIVILEGES) NULL, 0); - /* cannot test return value of AdjustTokenPrivileges. */ - if (GetLastError() != ERROR_SUCCESS) - msyslog(LOG_ERR, "AdjustTokenPrivileges failed: %m"); - - /* - * Set up timer interrupts for every 2**EVENT_TIMEOUT seconds - * Under Win/NT, expiry of timer interval leads to invocation - * of a callback function (on a different thread) rather than - * generating an alarm signal - */ - - /* determine max and min resolution supported */ - if(timeGetDevCaps(&tc, sizeof(TIMECAPS)) != TIMERR_NOERROR) { - msyslog(LOG_ERR, "timeGetDevCaps failed: %m"); - exit(1); - } - wTimerRes = min(max(tc.wPeriodMin, TARGET_RESOLUTION), tc.wPeriodMax); - /* establish the minimum timer resolution that we'll use */ - timeBeginPeriod(wTimerRes); - - /* start the timer event */ - wTimerID = timeSetEvent( - (UINT) (1000/TIMER_HZ), /* Delay */ - wTimerRes, /* Resolution */ - (LPTIMECALLBACK) alarming, /* Callback function */ - (DWORD) dwUser, /* User data */ - TIME_PERIODIC); /* Event type (periodic) */ - if (wTimerID == 0) { - msyslog(LOG_ERR, "timeSetEvent failed: %m"); - exit(1); - } -#endif /* SYS_WINNT */ -} - - -/* - * init_io - initialize I/O data and open socket - */ -static void -init_io(void) -{ -#ifdef SYS_WINNT - WORD wVersionRequested; - WSADATA wsaData; - init_transmitbuff(); -#endif /* SYS_WINNT */ - - /* - * Init buffer free list and stat counters - */ - init_recvbuff(sys_numservers + 2); - -#if defined(HAVE_SIGNALED_IO) - set_signal(); -#endif - -#ifdef SYS_WINNT - wVersionRequested = MAKEWORD(1,1); - if (WSAStartup(wVersionRequested, &wsaData)) - { - msyslog(LOG_ERR, "No useable winsock.dll: %m"); - exit(1); - } -#endif /* SYS_WINNT */ - - BLOCKIO(); - - /* create a datagram (UDP) socket */ - if ((fd = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { - msyslog(LOG_ERR, "socket() failed: %m"); - exit(1); - /*NOTREACHED*/ - } - - /* - * bind the socket to the NTP port - */ - if (!debug && set_time && !unpriv_port) { - struct sockaddr_in addr; - - memset((char *)&addr, 0, sizeof addr); - addr.sin_family = AF_INET; - addr.sin_port = htons(NTP_PORT); - addr.sin_addr.s_addr = htonl(INADDR_ANY); - if (bind(fd, (struct sockaddr *)&addr, sizeof(addr)) < 0) { -#ifndef SYS_WINNT - if (errno == EADDRINUSE) -#else - if (WSAGetLastError() == WSAEADDRINUSE) -#endif - msyslog(LOG_ERR, - "the NTP socket is in use, exiting"); - else - msyslog(LOG_ERR, "bind() fails: %m"); - exit(1); - } - } - - FD_ZERO(&fdmask); - FD_SET(fd, &fdmask); - - /* - * set non-blocking, - */ - -#ifdef USE_FIONBIO - /* in vxWorks we use FIONBIO, but the others are defined for old systems, so - * all hell breaks loose if we leave them defined - */ -#undef O_NONBLOCK -#undef FNDELAY -#undef O_NDELAY -#endif - -#if defined(O_NONBLOCK) /* POSIX */ - if (fcntl(fd, F_SETFL, O_NONBLOCK) < 0) - { - msyslog(LOG_ERR, "fcntl(O_NONBLOCK) fails: %m"); - exit(1); - /*NOTREACHED*/ - } -#elif defined(FNDELAY) - if (fcntl(fd, F_SETFL, FNDELAY) < 0) - { - msyslog(LOG_ERR, "fcntl(FNDELAY) fails: %m"); - exit(1); - /*NOTREACHED*/ - } -#elif defined(O_NDELAY) /* generally the same as FNDELAY */ - if (fcntl(fd, F_SETFL, O_NDELAY) < 0) - { - msyslog(LOG_ERR, "fcntl(O_NDELAY) fails: %m"); - exit(1); - /*NOTREACHED*/ - } -#elif defined(FIONBIO) - if ( -# if defined(VMS) - (ioctl(fd,FIONBIO,&1) < 0) -# elif defined(SYS_WINNT) - (ioctlsocket(fd,FIONBIO,(u_long *) &on) == SOCKET_ERROR) -# else - (ioctl(fd,FIONBIO,&on) < 0) -# endif - ) - { - msyslog(LOG_ERR, "ioctl(FIONBIO) fails: %m"); - exit(1); - /*NOTREACHED*/ - } -#elif defined(FIOSNBIO) - if (ioctl(fd,FIOSNBIO,&on) < 0) - { - msyslog(LOG_ERR, "ioctl(FIOSNBIO) fails: %m"); - exit(1); - /*NOTREACHED*/ - } -#else -# include "Bletch: Need non-blocking I/O!" -#endif - -#ifdef HAVE_SIGNALED_IO - init_socket_sig(fd); -#endif /* not HAVE_SIGNALED_IO */ - - UNBLOCKIO(); -} - - -/* - * sendpkt - send a packet to the specified destination - */ -static int -sendpkt( - struct sockaddr_in *dest, - struct pkt *pkt, - int len - ) -{ - int cc; - static int horriblecnt = 0; -#ifdef SYS_WINNT - DWORD err; -#endif /* SYS_WINNT */ - - total_xmit++; /* count it */ - - if (horrible) { - if (++horriblecnt > HORRIBLEOK) { - if (debug > 3) - printf("dropping send (%s)\n", ntoa(dest)); - if (horriblecnt >= HORRIBLEOK+horrible) - horriblecnt = 0; - return 0; - } - } - - - cc = sendto(fd, (char *)pkt, (size_t)len, 0, (struct sockaddr *)dest, - sizeof(struct sockaddr_in)); -#ifndef SYS_WINNT - if (cc == -1) { - if (errno != EWOULDBLOCK && errno != ENOBUFS) -#else - if (cc == SOCKET_ERROR) { - err = WSAGetLastError(); - if (err != WSAEWOULDBLOCK && err != WSAENOBUFS) -#endif /* SYS_WINNT */ - msyslog(LOG_ERR, "sendto(%s): %m", ntoa(dest)); - return -1; - } - return 0; -} - - -/* - * input_handler - receive packets asynchronously - */ -void -input_handler(l_fp *xts) -{ - register int n; - register struct recvbuf *rb; - struct timeval tvzero; - int fromlen; - fd_set fds; - l_fp ts; - ts = *xts; /* we ignore xts, but make the compiler happy */ - - /* - * Do a poll to see if we have data - */ - for (;;) { - fds = fdmask; - tvzero.tv_sec = tvzero.tv_usec = 0; - n = select(fd+1, &fds, (fd_set *)0, (fd_set *)0, &tvzero); - - /* - * If nothing to do, just return. If an error occurred, - * complain and return. If we've got some, freeze a - * timestamp. - */ - if (n == 0) - return; - else if (n == -1) { - if (errno != EINTR) { - msyslog(LOG_ERR, "select() error: %m"); - } - return; - } - get_systime(&ts); - - /* - * Get a buffer and read the frame. If we - * haven't got a buffer, or this is received - * on the wild card socket, just dump the packet. - */ - if (initializing || free_recvbuffs == 0) { - char buf[100]; - -#ifndef SYS_WINNT - (void) read(fd, buf, sizeof buf); -#else - /* NT's _read does not operate on nonblocking sockets - * either recvfrom or ReadFile() has to be used here. - * ReadFile is used in [ntpd]ntp_intres() and ntpdc, - * just to be different use recvfrom() here - */ - recvfrom(fd, buf, sizeof(buf), 0, (struct sockaddr *)0, NULL); -#endif /* SYS_WINNT */ - continue; - } - - rb = get_free_recv_buffer(); - - fromlen = sizeof(struct sockaddr_in); - rb->recv_length = recvfrom(fd, (char *)&rb->recv_pkt, - sizeof(rb->recv_pkt), 0, - (struct sockaddr *)&rb->srcadr, &fromlen); - if (rb->recv_length == -1) { - freerecvbuf(rb); - continue; - } - - /* - * Got one. Mark how and when it got here, - * put it on the full list. - */ - rb->recv_time = ts; - add_full_recv_buffer(rb); - total_recv++; /* count it */ - } -} - - -/* XXX ELIMINATE printserver similar in ntptrace.c, ntpdate.c */ -/* - * printserver - print detail information for a server - */ -static void -printserver( - register struct server *pp, - FILE *fp - ) -{ - register int i; - char junk[5]; - char *str; - - if (!debug) { - (void) fprintf(fp, - "%-15s %d/%d %03o v%d s%d offset %9s delay %s disp %s\n", - ntoa(&pp->srcadr), - pp->xmtcnt,pp->rcvcnt,pp->reach, - pp->version,pp->stratum, - lfptoa(&pp->offset, 6), ufptoa(pp->delay, 5), - ufptoa(pp->dispersion, 4)); - return; - } - - (void) fprintf(fp, "server %s, port %d\n", - ntoa(&pp->srcadr), ntohs(pp->srcadr.sin_port)); - - (void) fprintf(fp, "stratum %d, precision %d, leap %c%c, trust %03o\n", - pp->stratum, pp->precision, - pp->leap & 0x2 ? '1' : '0', - pp->leap & 0x1 ? '1' : '0', - pp->trust); - - if (pp->stratum == 1) { - junk[4] = 0; - memmove(junk, (char *)&pp->refid, 4); - str = junk; - } else { - str = numtoa(pp->refid); - } - (void) fprintf(fp, - "refid [%s], delay %s, dispersion %s\n", - str, fptoa((s_fp)pp->delay, 5), - ufptoa(pp->dispersion, 5)); - - (void) fprintf(fp, "transmitted %d, received %d, reachable %03o\n", - pp->xmtcnt, pp->rcvcnt, pp->reach); - - (void) fprintf(fp, "reference time: %s\n", - prettydate(&pp->reftime)); - (void) fprintf(fp, "originate timestamp: %s\n", - prettydate(&pp->org)); - (void) fprintf(fp, "transmit timestamp: %s\n", - prettydate(&pp->xmt)); - - (void) fprintf(fp, "filter delay: "); - for (i = 0; i < NTP_SHIFT; i++) { - (void) fprintf(fp, " %-8.8s", fptoa(pp->filter_delay[i], 5)); - if (i == (NTP_SHIFT>>1)-1) - (void) fprintf(fp, "\n "); - } - (void) fprintf(fp, "\n"); - - (void) fprintf(fp, "filter offset:"); - for (i = 0; i < PEER_SHIFT; i++) { - (void) fprintf(fp, " %-8.8s", lfptoa(&pp->filter_offset[i], 6)); - if (i == (PEER_SHIFT>>1)-1) - (void) fprintf(fp, "\n "); - } - (void) fprintf(fp, "\n"); - - (void) fprintf(fp, "delay %s, dispersion %s\n", - fptoa((s_fp)pp->delay, 5), ufptoa(pp->dispersion, 5)); - - (void) fprintf(fp, "offset %s\n\n", - lfptoa(&pp->offset, 6)); -} - -#if !defined(HAVE_VSPRINTF) -int -vsprintf( - char *str, - const char *fmt, - va_list ap - ) -{ - FILE f; - int len; - - f._flag = _IOWRT+_IOSTRG; - f._ptr = str; - f._cnt = 32767; - len = _doprnt(fmt, ap, &f); - *f._ptr = 0; - return (len); -} -#endif diff --git a/contrib/ntp/ntpdc/Makefile.am b/contrib/ntp/ntpdc/Makefile.am index 858c52326..a61dab99d 100644 --- a/contrib/ntp/ntpdc/Makefile.am +++ b/contrib/ntp/ntpdc/Makefile.am @@ -1,40 +1,122 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr +NULL= -bindir= ${exec_prefix}/${BINSUBDIR} -bin_PROGRAMS= ntpdc -EXTRA_PROGRAMS= ntpdc-layout +bin_PROGRAMS= $(NTPDC_DB) +libexec_PROGRAMS= $(NTPDC_DL) +sbin_PROGRAMS= $(NTPDC_DS) + +EXTRA_PROGRAMS= ntpdc ntpdc-layout EXTRA_DATA= check-layout -BUILT_SOURCES= @MAKE_CHECK_LAYOUT@ -AM_CPPFLAGS= -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +BUILT_SOURCES= @MAKE_CHECK_LAYOUT@ ntpdc-opts.c ntpdc-opts.h + +AM_CFLAGS = $(CFLAGS_NTP) + +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(LIBOPTS_CFLAGS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +AM_LDFLAGS = $(LDFLAGS_NTP) + # LDADD might need RESLIB and ADJLIB -ntpdc_LDADD= version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a +ntpdc_LDADD = version.o $(LIBOPTS_LDADD) +ntpdc_LDADD += ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) +ntpdc_LDADD += $(PTHREAD_LIBS) $(EDITLINE_LIBS) +ntpdc_LDADD += $(LDADD_NTP) # ntpdc-layout doesn't need any additional libraries at all ntpdc_layout_LDADD= -DISTCLEANFILES= .version version.c + +DISTCLEANFILES= .version version.c config.log $(man_MANS) CLEANFILES= check-layout layout.here nl.c ntpdc-layout noinst_HEADERS= ntpdc.h ETAGS_ARGS= Makefile.am -EXTRA_DIST= nl_in.c nl.pl layout.std \ - ntpdc-opts.def ntpdc.1 ntpdc-opts.texi ntpdc-opts.menu -BUILT_SOURCES+= ntpdc-opts.c ntpdc-opts.h ntpdc.1 ntpdc-opts.texi \ - ntpdc-opts.menu -man_MANS= ntpdc.1 -run_ag= cd $(srcdir) && autogen -L ../include --writable -std_def_list= $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ - $(top_srcdir)/include/copyright.def \ - $(top_srcdir)/include/homerc.def \ - $(top_srcdir)/include/version.def +EXTRA_DIST= \ + invoke-ntpdc.menu \ + invoke-ntpdc.texi \ + layout.std \ + nl_in.c \ + nl.pl \ + ntpdc-opts.def \ + ntpdc.1ntpdcman \ + ntpdc.1ntpdcmdoc \ + ntpdc.man.in \ + ntpdc.mdoc.in \ + ntpdc.html \ + ntpdc.texi \ + $(NULL) + +man1_MANS= +man8_MANS= +man_MANS= ntpdc.$(NTPDC_MS) + +## HMS: Real Soon Now... +##info_TEXINFOS= ntpdc.texi +##ntpdc_TEXINFOS= ntpdc-opts.texi + +html_DATA= \ + $(srcdir)/ntpdc.html \ + $(NULL) + +noinst_DATA= \ + $(srcdir)/invoke-ntpdc.menu \ + $(srcdir)/invoke-ntpdc.texi \ + $(srcdir)/ntpdc.man.in \ + $(srcdir)/ntpdc.mdoc.in \ + $(NULL) + +install-data-local: install-html + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) $(srcdir)/ntpdc-opts.h: $(srcdir)/ntpdc-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpdc-opts.c: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) ntpdc-opts.def -$(srcdir)/ntpdc.1: $(srcdir)/ntpdc-opts.def $(std_def_list) - $(run_ag) -Tagman1.tpl -bntpdc ntpdc-opts.def +### + +$(srcdir)/ntpdc.1ntpdcman: $(srcdir)/ntpdc-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdcman -Tagman-cmd.tpl ntpdc-opts.def + +$(srcdir)/ntpdc.man.in: $(srcdir)/ntpdc.1ntpdcman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpdc.1ntpdcman > $(srcdir)/ntpdc.man.in+ + mv $(srcdir)/ntpdc.man.in+ $(srcdir)/ntpdc.man.in + +### + +$(srcdir)/ntpdc.1ntpdcmdoc: $(srcdir)/ntpdc-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdcmdoc -Tagmdoc-cmd.tpl ntpdc-opts.def + +$(srcdir)/ntpdc.mdoc.in: $(srcdir)/ntpdc.1ntpdcmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpdc.1ntpdcmdoc > $(srcdir)/ntpdc.mdoc.in+ + mv $(srcdir)/ntpdc.mdoc.in+ $(srcdir)/ntpdc.mdoc.in -$(srcdir)/ntpdc-opts.texi $(srcdir)/ntpdc-opts.menu: $(srcdir)/ntpdc-opts.def $(std_def_list) - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdc-opts.def +### + +ntpdc.$(NTPDC_MS): $(srcdir)/ntpdc.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpdc.$(NTPDC_MS)+:$(srcdir)/ntpdc.$(MANTAGFMT).in + mv ntpdc.$(NTPDC_MS)+ ntpdc.$(NTPDC_MS) + +### + +$(srcdir)/invoke-ntpdc.menu: $(srcdir)/invoke-ntpdc.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpdc.texi: $(srcdir)/ntpdc-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpdc-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +$(srcdir)/ntpdc.html: $(srcdir)/invoke-ntpdc.menu $(srcdir)/invoke-ntpdc.texi $(srcdir)/ntpdc.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntpdc.html ntpdc.texi || true ) ntpdc_SOURCES = ntpdc.c ntpdc_ops.c ntpdc-opts.c ntpdc-opts.h @@ -43,24 +125,27 @@ ntpdc-layout.o: nl.c layout.here: ntpdc-layout ./ntpdc-layout > $@ -check-layout: ntpdc-layout layout.std layout.here +check-layout: ntpdc-layout $(srcdir)/layout.std layout.here cmp $(srcdir)/layout.std layout.here && echo stamp > $@ -$(PROGRAMS): $(LDADD) - -../libntp/libntp.a: - cd ../libntp && $(MAKE) +$(PROGRAMS): version.o -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev -version.o: $(ntpdc_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpdc - $(COMPILE) -c version.c +version.c: $(ntpdc_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpdc + +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o # I ran nl_in.c (attached, to be installed into ntpdc) through # $(CC) -E nl_in.c | nl.pl > nl.c -nl.c: nl_in.c nl.pl Makefile.am +nl.c: nl_in.c nl.pl Makefile.am ../config.h ../include/ntp_request.h ntpdc.h $(CC) -E $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(srcdir)/nl_in.c | ./nl.pl > nl.c -include ../bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/check-libopts.mf +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/ntpdc/Makefile.in b/contrib/ntp/ntpdc/Makefile.in index 0e4ce77f0..c85588e8c 100644 --- a/contrib/ntp/ntpdc/Makefile.in +++ b/contrib/ntp/ntpdc/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -20,7 +19,63 @@ # subdir to warn folks if there is another version there. + VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -39,50 +94,115 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr -bin_PROGRAMS = ntpdc$(EXEEXT) -EXTRA_PROGRAMS = ntpdc-layout$(EXEEXT) -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/../bincheck.mf \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in $(srcdir)/nl.pl.in +EXTRA_PROGRAMS = ntpdc$(EXEEXT) ntpdc-layout$(EXEEXT) subdir = ntpdc ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = nl.pl CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) -am_ntpdc_OBJECTS = ntpdc$U.$(OBJEXT) ntpdc_ops$U.$(OBJEXT) \ - ntpdc-opts$U.$(OBJEXT) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(sbin_PROGRAMS) +am_ntpdc_OBJECTS = ntpdc.$(OBJEXT) ntpdc_ops.$(OBJEXT) \ + ntpdc-opts.$(OBJEXT) ntpdc_OBJECTS = $(am_ntpdc_OBJECTS) am__DEPENDENCIES_1 = ntpdc_DEPENDENCIES = version.o $(am__DEPENDENCIES_1) \ - ../libntp/libntp.a + ../libntp/libntp.a $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = ntpdc_layout_SOURCES = ntpdc-layout.c -ntpdc_layout_OBJECTS = ntpdc-layout$U.$(OBJEXT) +ntpdc_layout_OBJECTS = ntpdc-layout.$(OBJEXT) ntpdc_layout_DEPENDENCIES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = SOURCES = $(ntpdc_SOURCES) ntpdc-layout.c DIST_SOURCES = $(ntpdc_SOURCES) ntpdc-layout.c +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -104,50 +224,112 @@ am__nobase_list = $(am__nobase_strip_setup); \ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 NROFF = nroff -MANS = $(man_MANS) +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/nl.pl.in \ + $(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf \ + $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf \ + $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -155,8 +337,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -166,15 +351,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -182,29 +428,65 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -245,37 +527,79 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +bin_PROGRAMS = $(NTPDC_DB) +libexec_PROGRAMS = $(NTPDC_DL) +sbin_PROGRAMS = $(NTPDC_DS) EXTRA_DATA = check-layout -BUILT_SOURCES = @MAKE_CHECK_LAYOUT@ ntpdc-opts.c ntpdc-opts.h ntpdc.1 \ - ntpdc-opts.texi ntpdc-opts.menu -AM_CPPFLAGS = -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +BUILT_SOURCES = @MAKE_CHECK_LAYOUT@ ntpdc-opts.c ntpdc-opts.h \ + check-libopts check-libntp .deps-ver +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(LIBOPTS_CFLAGS) $(CPPFLAGS_NTP) +AM_LDFLAGS = $(LDFLAGS_NTP) + # LDADD might need RESLIB and ADJLIB -ntpdc_LDADD = version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a +ntpdc_LDADD = version.o $(LIBOPTS_LDADD) ../libntp/libntp.a \ + $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) $(EDITLINE_LIBS) \ + $(LDADD_NTP) # ntpdc-layout doesn't need any additional libraries at all ntpdc_layout_LDADD = -DISTCLEANFILES = .version version.c -CLEANFILES = check-layout layout.here nl.c ntpdc-layout +DISTCLEANFILES = .version version.c config.log $(man_MANS) +CLEANFILES = check-layout layout.here nl.c ntpdc-layout check-libopts \ + check-libntp .deps-ver noinst_HEADERS = ntpdc.h ETAGS_ARGS = Makefile.am -EXTRA_DIST = nl_in.c nl.pl layout.std \ - ntpdc-opts.def ntpdc.1 ntpdc-opts.texi ntpdc-opts.menu - -man_MANS = ntpdc.1 -run_ag = cd $(srcdir) && autogen -L ../include --writable -std_def_list = $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ - $(top_srcdir)/include/copyright.def \ - $(top_srcdir)/include/homerc.def \ - $(top_srcdir)/include/version.def +EXTRA_DIST = \ + invoke-ntpdc.menu \ + invoke-ntpdc.texi \ + layout.std \ + nl_in.c \ + nl.pl \ + ntpdc-opts.def \ + ntpdc.1ntpdcman \ + ntpdc.1ntpdcmdoc \ + ntpdc.man.in \ + ntpdc.mdoc.in \ + ntpdc.html \ + ntpdc.texi \ + $(NULL) + +man1_MANS = +man8_MANS = +man_MANS = ntpdc.$(NTPDC_MS) +html_DATA = \ + $(srcdir)/ntpdc.html \ + $(NULL) + +noinst_DATA = \ + $(srcdir)/invoke-ntpdc.menu \ + $(srcdir)/invoke-ntpdc.texi \ + $(srcdir)/ntpdc.man.in \ + $(srcdir)/ntpdc.mdoc.in \ + $(NULL) + +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) ntpdc_SOURCES = ntpdc.c ntpdc_ops.c ntpdc-opts.c ntpdc-opts.h +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include all: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -287,7 +611,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/../bincheck.mf $(am__con echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ntpdc/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign ntpdc/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -296,6 +619,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -309,14 +633,19 @@ nl.pl: $(top_builddir)/config.status $(srcdir)/nl.pl.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p || test -f $$p1; \ - then echo "$$p"; echo "$$p"; else :; fi; \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ - sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ @@ -337,7 +666,8 @@ uninstall-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' `; \ + -e 's/$$/$(EXEEXT)/' \ + `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files @@ -350,73 +680,164 @@ clean-binPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -ntpdc$(EXEEXT): $(ntpdc_OBJECTS) $(ntpdc_DEPENDENCIES) +install-libexecPROGRAMS: $(libexec_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(libexecdir)" && rm -f $$files + +clean-libexecPROGRAMS: + @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +ntpdc$(EXEEXT): $(ntpdc_OBJECTS) $(ntpdc_DEPENDENCIES) $(EXTRA_ntpdc_DEPENDENCIES) @rm -f ntpdc$(EXEEXT) - $(LINK) $(ntpdc_OBJECTS) $(ntpdc_LDADD) $(LIBS) -ntpdc-layout$(EXEEXT): $(ntpdc_layout_OBJECTS) $(ntpdc_layout_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(ntpdc_OBJECTS) $(ntpdc_LDADD) $(LIBS) + +ntpdc-layout$(EXEEXT): $(ntpdc_layout_OBJECTS) $(ntpdc_layout_DEPENDENCIES) $(EXTRA_ntpdc_layout_DEPENDENCIES) @rm -f ntpdc-layout$(EXEEXT) - $(LINK) $(ntpdc_layout_OBJECTS) $(ntpdc_layout_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(ntpdc_layout_OBJECTS) $(ntpdc_layout_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-layout$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc_ops$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-layout.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpdc_ops.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -ntpdc_.c: ntpdc.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc.c; then echo $(srcdir)/ntpdc.c; else echo ntpdc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc-layout_.c: ntpdc-layout.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc-layout.c; then echo $(srcdir)/ntpdc-layout.c; else echo ntpdc-layout.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc-opts_.c: ntpdc-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc-opts.c; then echo $(srcdir)/ntpdc-opts.c; else echo ntpdc-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc_ops_.c: ntpdc_ops.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpdc_ops.c; then echo $(srcdir)/ntpdc_ops.c; else echo ntpdc_ops.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpdc_.$(OBJEXT) ntpdc_.lo ntpdc-layout_.$(OBJEXT) ntpdc-layout_.lo \ -ntpdc-opts_.$(OBJEXT) ntpdc-opts_.lo ntpdc_ops_.$(OBJEXT) \ -ntpdc_ops_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs -install-man1: $(man_MANS) +install-man1: $(man1_MANS) $(man_MANS) @$(NORMAL_INSTALL) - test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" - @list=''; test -n "$(man1dir)" || exit 0; \ - { for i in $$list; do echo "$$i"; done; \ - l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ - sed -n '/\.1[a-z]*$$/p'; \ + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ } | while read p; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; echo "$$p"; \ @@ -439,36 +860,87 @@ install-man1: $(man_MANS) uninstall-man1: @$(NORMAL_UNINSTALL) - @list=''; test -n "$(man1dir)" || exit 0; \ + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ files=`{ for i in $$list; do echo "$$i"; done; \ l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ - test -z "$$files" || { \ - echo " ( cd '$(DESTDIR)$(man1dir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(man1dir)" && rm -f $$files; } - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -480,15 +952,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -497,24 +965,26 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) - @list='$(MANS)'; if test -n "$$list"; then \ - list=`for p in $$list; do \ - if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ - if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \ - if test -n "$$list" && \ - grep 'ab help2man is required to generate this page' $$list >/dev/null; then \ - echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \ - grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \ - echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \ - echo " typically \`make maintainer-clean' will remove them" >&2; \ - exit 1; \ - else :; fi; \ - else :; fi @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -547,9 +1017,9 @@ distdir: $(DISTFILES) check-am: all-am check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am -all-am: Makefile $(PROGRAMS) $(MANS) $(HEADERS) +all-am: Makefile $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -563,10 +1033,15 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: @@ -583,7 +1058,8 @@ maintainer-clean-generic: -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -603,13 +1079,14 @@ info: info-am info-am: -install-data-am: install-man +install-data-am: install-data-local install-htmlDATA install-man install-dvi: install-dvi-am install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-libexecPROGRAMS \ + install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am @@ -620,7 +1097,7 @@ install-info: install-info-am install-info-am: -install-man: install-man1 +install-man: install-man1 install-man8 install-pdf: install-pdf-am @@ -639,7 +1116,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -650,74 +1127,184 @@ ps: ps-am ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-htmlDATA \ + uninstall-libexecPROGRAMS uninstall-man uninstall-sbinPROGRAMS -uninstall-man: uninstall-man1 +uninstall-man: uninstall-man1 uninstall-man8 -.MAKE: ../util/ansi2knr all check install install-am install-exec-am \ - install-strip +.MAKE: all check install install-am install-exec-am install-strip -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ + clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS cscopelist-am ctags ctags-am \ + distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-binPROGRAMS \ + install-data install-data-am install-data-local install-dvi \ install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-man1 install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-kr mostlyclean-libtool pdf pdf-am ps ps-am tags \ - uninstall uninstall-am uninstall-binPROGRAMS uninstall-man \ - uninstall-man1 + install-html install-html-am install-htmlDATA install-info \ + install-info-am install-libexecPROGRAMS install-man \ + install-man1 install-man8 install-pdf install-pdf-am \ + install-ps install-ps-am install-sbinPROGRAMS install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-htmlDATA uninstall-libexecPROGRAMS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinPROGRAMS + +.PRECIOUS: Makefile + +install-data-local: install-html $(srcdir)/ntpdc-opts.h: $(srcdir)/ntpdc-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpdc-opts.c: $(srcdir)/ntpdc-opts.def $(std_def_list) $(run_ag) ntpdc-opts.def -$(srcdir)/ntpdc.1: $(srcdir)/ntpdc-opts.def $(std_def_list) - $(run_ag) -Tagman1.tpl -bntpdc ntpdc-opts.def +### + +$(srcdir)/ntpdc.1ntpdcman: $(srcdir)/ntpdc-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdcman -Tagman-cmd.tpl ntpdc-opts.def + +$(srcdir)/ntpdc.man.in: $(srcdir)/ntpdc.1ntpdcman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpdc.1ntpdcman > $(srcdir)/ntpdc.man.in+ + mv $(srcdir)/ntpdc.man.in+ $(srcdir)/ntpdc.man.in + +### + +$(srcdir)/ntpdc.1ntpdcmdoc: $(srcdir)/ntpdc-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpdcmdoc -Tagmdoc-cmd.tpl ntpdc-opts.def + +$(srcdir)/ntpdc.mdoc.in: $(srcdir)/ntpdc.1ntpdcmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpdc.1ntpdcmdoc > $(srcdir)/ntpdc.mdoc.in+ + mv $(srcdir)/ntpdc.mdoc.in+ $(srcdir)/ntpdc.mdoc.in + +### + +ntpdc.$(NTPDC_MS): $(srcdir)/ntpdc.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpdc.$(NTPDC_MS)+:$(srcdir)/ntpdc.$(MANTAGFMT).in + mv ntpdc.$(NTPDC_MS)+ ntpdc.$(NTPDC_MS) + +### + +$(srcdir)/invoke-ntpdc.menu: $(srcdir)/invoke-ntpdc.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi -$(srcdir)/ntpdc-opts.texi $(srcdir)/ntpdc-opts.menu: $(srcdir)/ntpdc-opts.def $(std_def_list) - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpdc-opts.def +$(srcdir)/invoke-ntpdc.texi: $(srcdir)/ntpdc-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpdc-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +$(srcdir)/ntpdc.html: $(srcdir)/invoke-ntpdc.menu $(srcdir)/invoke-ntpdc.texi $(srcdir)/ntpdc.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntpdc.html ntpdc.texi || true ) ntpdc-layout.o: nl.c layout.here: ntpdc-layout ./ntpdc-layout > $@ -check-layout: ntpdc-layout layout.std layout.here +check-layout: ntpdc-layout $(srcdir)/layout.std layout.here cmp $(srcdir)/layout.std layout.here && echo stamp > $@ -$(PROGRAMS): $(LDADD) +$(PROGRAMS): version.o -../libntp/libntp.a: - cd ../libntp && $(MAKE) +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +version.c: $(ntpdc_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpdc -version.o: $(ntpdc_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpdc - $(COMPILE) -c version.c +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o # I ran nl_in.c (attached, to be installed into ntpdc) through # $(CC) -E nl_in.c | nl.pl > nl.c -nl.c: nl_in.c nl.pl Makefile.am +nl.c: nl_in.c nl.pl Makefile.am ../config.h ../include/ntp_request.h ntpdc.h $(CC) -E $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(srcdir)/nl_in.c | ./nl.pl > nl.c install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ - || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ - test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ + done + +# + +check-libopts: ../sntp/libopts/libopts.la + @echo stamp > $@ + +../sntp/libopts/libopts.la: + -cd ../sntp/libopts && $(MAKE) $(AM_MAKEFLAGS) libopts.la + +check-libntp: ../libntp/libntp.a + @echo stamp > $@ +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. # # Tell versions [3.59,3.63) of GNU make to not export all variables. diff --git a/contrib/ntp/ntpdc/ntpdc-opts.menu b/contrib/ntp/ntpdc/invoke-ntpdc.menu similarity index 100% rename from contrib/ntp/ntpdc/ntpdc-opts.menu rename to contrib/ntp/ntpdc/invoke-ntpdc.menu diff --git a/contrib/ntp/ntpdc/invoke-ntpdc.texi b/contrib/ntp/ntpdc/invoke-ntpdc.texi new file mode 100644 index 000000000..014606903 --- /dev/null +++ b/contrib/ntp/ntpdc/invoke-ntpdc.texi @@ -0,0 +1,349 @@ +@node ntpdc Invocation +@section Invoking ntpdc +@pindex ntpdc +@cindex vendor-specific NTPD control program +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntpdc.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:38:54 PM by AutoGen 5.18.5 +# From the definitions ntpdc-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + + +@code{ntpdc} +is deprecated. +Please use +@code{ntpq(1ntpqmdoc)} instead - it can do everything +@code{ntpdc} +used to do, and it does so using a much more sane interface. + +@code{ntpdc} +is a utility program used to query +@code{ntpd(1ntpdmdoc)} +about its +current state and to request changes in that state. +It uses NTP mode 7 control message formats described in the source code. +The program may +be run either in interactive mode or controlled using command line +arguments. +Extensive state and statistics information is available +through the +@code{ntpdc} +interface. +In addition, nearly all the +configuration options which can be specified at startup using +ntpd's configuration file may also be specified at run time using +@code{ntpdc} + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntpdc} program. +This software is released under the NTP license, . + +@menu +* ntpdc usage:: ntpdc help/usage (@option{--help}) +* ntpdc ipv4:: ipv4 option (-4) +* ntpdc ipv6:: ipv6 option (-6) +* ntpdc command:: command option (-c) +* ntpdc interactive:: interactive option (-i) +* ntpdc listpeers:: listpeers option (-l) +* ntpdc numeric:: numeric option (-n) +* ntpdc peers:: peers option (-p) +* ntpdc showpeers:: showpeers option (-s) +* ntpdc config:: presetting/configuring ntpdc +* ntpdc exit status:: exit status +* ntpdc Usage:: Usage +* ntpdc See Also:: See Also +* ntpdc Authors:: Authors +* ntpdc Bugs:: Bugs +@end menu + +@node ntpdc usage +@subsection ntpdc help/usage (@option{--help}) +@cindex ntpdc help + +This is the automatically generated usage text for ntpdc. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +ntpdc - vendor-specific NTPD control program - Ver. 4.2.8p4 +Usage: ntpdc [ - [] | --[@{=| @}] ]... [ host ...] + Flg Arg Option-Name Description + -4 no ipv4 Force IPv4 DNS name resolution + - prohibits the option 'ipv6' + -6 no ipv6 Force IPv6 DNS name resolution + - prohibits the option 'ipv4' + -c Str command run a command and exit + - may appear multiple times + -d no debug-level Increase debug verbosity level + - may appear multiple times + -D Num set-debug-level Set the debug verbosity level + - may appear multiple times + -i no interactive Force ntpq to operate in interactive mode + - prohibits these options: + command + listpeers + peers + showpeers + -l no listpeers Print a list of the peers + - prohibits the option 'command' + -n no numeric numeric host addresses + -p no peers Print a list of the peers + - prohibits the option 'command' + -s no showpeers Show a list of the peers + - prohibits the option 'command' + opt version output version information and exit + -? no help display extended usage information and exit + -! no more-help extended usage information passed thru pager + -> opt save-opts save the option state to a config file + -< Str load-opts load options from a config file + - disabled as '--no-load-opts' + - may appear multiple times + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. + + +The following option preset mechanisms are supported: + - reading file $HOME/.ntprc + - reading file ./.ntprc + - examining environment variables named NTPDC_* + +Please send bug reports to: +@end example +@exampleindent 4 + +@node ntpdc ipv4 +@subsection ipv4 option (-4) +@cindex ntpdc-ipv4 + +This is the ``force ipv4 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv6. +@end itemize + +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +@node ntpdc ipv6 +@subsection ipv6 option (-6) +@cindex ntpdc-ipv6 + +This is the ``force ipv6 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv4. +@end itemize + +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +@node ntpdc command +@subsection command option (-c) +@cindex ntpdc-command + +This is the ``run a command and exit'' option. +This option takes a string argument @file{cmd}. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +@node ntpdc interactive +@subsection interactive option (-i) +@cindex ntpdc-interactive + +This is the ``force ntpq to operate in interactive mode'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +command, listpeers, peers, showpeers. +@end itemize + +Force ntpq to operate in interactive mode. Prompts will be written +to the standard output and commands read from the standard input. +@node ntpdc listpeers +@subsection listpeers option (-l) +@cindex ntpdc-listpeers + +This is the ``print a list of the peers'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +command. +@end itemize + +Print a list of the peers known to the server as well as a summary of +their state. This is equivalent to the 'listpeers' interactive command. +@node ntpdc numeric +@subsection numeric option (-n) +@cindex ntpdc-numeric + +This is the ``numeric host addresses'' option. +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +@node ntpdc peers +@subsection peers option (-p) +@cindex ntpdc-peers + +This is the ``print a list of the peers'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +command. +@end itemize + +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +@node ntpdc showpeers +@subsection showpeers option (-s) +@cindex ntpdc-showpeers + +This is the ``show a list of the peers'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +command. +@end itemize + +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'dmpeers' interactive command. + + +@node ntpdc config +@subsection presetting/configuring ntpdc + +Any option that is not marked as @i{not presettable} may be preset by +loading values from configuration ("rc" or "ini") files, and values from environment variables named @code{NTPDC} and @code{NTPDC_}. @code{} must be one of +the options listed above in upper case and segmented with underscores. +The @code{NTPDC} variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + + +@noindent +@code{libopts} will search in 2 places for configuration files: +@itemize @bullet +@item +$HOME +@item +$PWD +@end itemize +The environment variables @code{HOME}, and @code{PWD} +are expanded and replaced when @file{ntpdc} runs. +For any of these that are plain files, they are simply processed. +For any that are directories, then a file named @file{.ntprc} is searched for +within that directory and processed. + +Configuration files may be in a wide variety of formats. +The basic format is an option name followed by a value (argument) on the +same line. Values may be separated from the option name with a colon, +equal sign or simply white space. Values may be continued across multiple +lines by escaping the newline with a backslash. + +Multiple programs may also share the same initialization file. +Common options are collected at the top, followed by program specific +segments. The segments are separated by lines like: +@example +[NTPDC] +@end example +@noindent +or by +@example + +@end example +@noindent +Do not mix these styles within one configuration file. + +Compound values and carefully constructed string values may also be +specified using XML syntax: +@example + + ...<...>... + +@end example +@noindent +yielding an @code{option-name.sub-opt} string value of +@example +"...<...>..." +@end example +@code{AutoOpts} does not track suboptions. You simply note that it is a +hierarchicly valued option. @code{AutoOpts} does provide a means for searching +the associated name/value pair list (see: optionFindValue). + +The command line options relating to configuration and/or usage help are: + +@subsubheading version (-) + +Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +@table @samp +@item version +Only print the version. This is the default. +@item copyright +Name the copyright usage licensing terms. +@item verbose +Print the full copyright usage licensing terms. +@end table + +@node ntpdc exit status +@subsection ntpdc exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@item 66 (EX_NOINPUT) +A specified configuration file could not be loaded. +@item 70 (EX_SOFTWARE) +libopts had an internal operational error. Please report +it to autogen-users@@lists.sourceforge.net. Thank you. +@end table +@node ntpdc Usage +@subsection ntpdc Usage +@node ntpdc See Also +@subsection ntpdc See Also +@node ntpdc Authors +@subsection ntpdc Authors +@node ntpdc Bugs +@subsection ntpdc Bugs diff --git a/contrib/ntp/ntpdc/layout.std b/contrib/ntp/ntpdc/layout.std index daff63678..6117f5215 100644 --- a/contrib/ntp/ntpdc/layout.std +++ b/contrib/ntp/ntpdc/layout.std @@ -1,20 +1,28 @@ -sizeof(struct req_pkt) = 212 +sizeof(union req_data_u_tag) = 176 +offsetof(u32) = 0 +offsetof(data) = 0 + +sizeof(struct req_pkt) = 216 offsetof(rm_vn_mode) = 0 offsetof(auth_seq) = 1 offsetof(implementation) = 2 offsetof(request) = 3 offsetof(err_nitems) = 4 offsetof(mbz_itemsize) = 6 -offsetof(data) = 8 +offsetof(u) = 8 offsetof(tstamp) = 184 offsetof(keyid) = 192 offsetof(mac) = 196 -sizeof(struct req_pkt_tail) = 28 +sizeof(struct req_pkt_tail) = 32 offsetof(tstamp) = 0 offsetof(keyid) = 8 offsetof(mac) = 12 +sizeof(union resp_pkt_u_tag) = 500 +offsetof(data) = 0 +offsetof(u32) = 0 + sizeof(struct resp_pkt) = 508 offsetof(rm_vn_mode) = 0 offsetof(auth_seq) = 1 @@ -22,7 +30,7 @@ offsetof(implementation) = 2 offsetof(request) = 3 offsetof(err_nitems) = 4 offsetof(mbz_itemsize) = 6 -offsetof(data) = 8 +offsetof(u) = 8 sizeof(struct info_peer_list) = 32 offsetof(addr) = 0 @@ -269,9 +277,9 @@ offsetof(addr6) = 16 offsetof(mask6) = 32 sizeof(struct info_monitor_1) = 72 -offsetof(lasttime) = 0 -offsetof(firsttime) = 4 -offsetof(lastdrop) = 8 +offsetof(avg_int) = 0 +offsetof(last_int) = 4 +offsetof(restr) = 8 offsetof(count) = 12 offsetof(addr) = 16 offsetof(daddr) = 20 @@ -285,9 +293,9 @@ offsetof(addr6) = 40 offsetof(daddr6) = 56 sizeof(struct info_monitor) = 48 -offsetof(lasttime) = 0 -offsetof(firsttime) = 4 -offsetof(lastdrop) = 8 +offsetof(avg_int) = 0 +offsetof(last_int) = 4 +offsetof(restr) = 8 offsetof(count) = 12 offsetof(addr) = 16 offsetof(port) = 20 diff --git a/contrib/ntp/ntpdc/nl.pl b/contrib/ntp/ntpdc/nl.pl index afea8b755..73da2a840 100755 --- a/contrib/ntp/ntpdc/nl.pl +++ b/contrib/ntp/ntpdc/nl.pl @@ -7,7 +7,7 @@ $debug = 0; while (<>) { next if /^#/; next if /^\s*$/; - if (/^struct req_pkt/) { + if (/^typedef union req_data_u_tag/) { $found = 1; } if (/^struct info_dns_assoc/) { @@ -20,13 +20,19 @@ while (<>) { printf " printf(\"sizeof($type) = %%d\\n\", \n\t (int) sizeof($type));\n"; next; } + if (/^typedef (union\s*\w*)\s*{\s*$/) { + $type = $1; + print STDERR "union = '$type'\n" if $debug; + printf " printf(\"sizeof($type) = %%d\\n\", \n\t (int) sizeof($type));\n"; + next; + } if (/\s*\w+\s+(\w*)\s*(\[.*\])?\s*;\s*$/) { $field = $1; print STDERR "\tfield = '$field'\n" if $debug; printf " printf(\"offsetof($field) = %%d\\n\", \n\t (int) offsetof($type, $field));\n"; next; } - if (/^}\s*;\s*$/) { + if (/^}\s*\w*\s*;\s*$/) { printf " printf(\"\\n\");\n\n"; $found = 0 if $last; next; diff --git a/contrib/ntp/ntpdc/nl.pl.in b/contrib/ntp/ntpdc/nl.pl.in index 813dc1f10..8007538dc 100644 --- a/contrib/ntp/ntpdc/nl.pl.in +++ b/contrib/ntp/ntpdc/nl.pl.in @@ -7,7 +7,7 @@ $debug = 0; while (<>) { next if /^#/; next if /^\s*$/; - if (/^struct req_pkt/) { + if (/^typedef union req_data_u_tag/) { $found = 1; } if (/^struct info_dns_assoc/) { @@ -20,13 +20,19 @@ while (<>) { printf " printf(\"sizeof($type) = %%d\\n\", \n\t (int) sizeof($type));\n"; next; } + if (/^typedef (union\s*\w*)\s*{\s*$/) { + $type = $1; + print STDERR "union = '$type'\n" if $debug; + printf " printf(\"sizeof($type) = %%d\\n\", \n\t (int) sizeof($type));\n"; + next; + } if (/\s*\w+\s+(\w*)\s*(\[.*\])?\s*;\s*$/) { $field = $1; print STDERR "\tfield = '$field'\n" if $debug; printf " printf(\"offsetof($field) = %%d\\n\", \n\t (int) offsetof($type, $field));\n"; next; } - if (/^}\s*;\s*$/) { + if (/^}\s*\w*\s*;\s*$/) { printf " printf(\"\\n\");\n\n"; $found = 0 if $last; next; diff --git a/contrib/ntp/ntpdc/ntpdc-layout.c b/contrib/ntp/ntpdc/ntpdc-layout.c index b05fbf384..017148884 100644 --- a/contrib/ntp/ntpdc/ntpdc-layout.c +++ b/contrib/ntp/ntpdc/ntpdc-layout.c @@ -2,6 +2,7 @@ * ntpdc-layout - print layout of NTP mode 7 request/response packets */ +#include #include #include diff --git a/contrib/ntp/ntpdc/ntpdc-opts.c b/contrib/ntp/ntpdc/ntpdc-opts.c index 41be37ec9..6b4617aa9 100644 --- a/contrib/ntp/ntpdc/ntpdc-opts.c +++ b/contrib/ntp/ntpdc/ntpdc-opts.c @@ -1,45 +1,56 @@ -/* +/* * EDIT THIS FILE WITH CAUTION (ntpdc-opts.c) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:00 AM EST + * + * It has been AutoGen-ed October 21, 2015 at 12:38:40 PM by AutoGen 5.18.5 * From the definitions ntpdc-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This source file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpdc author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. + * Generated from AutoOpts 41:0:16 templates. + * + * AutoOpts is a copyrighted work. This source file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpdc author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. * - * This source file is copyrighted and licensed under the following terms: + * The ntpdc program is copyrighted and licensed + * under the following terms: * - * ntpdc copyright 1970-2009 David L. Mills and/or others - all rights reserved + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * * - * see html/copyright.html + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. */ - -#include - +#ifndef __doxygen__ #define OPTION_CODE_COMPILE 1 #include "ntpdc-opts.h" +#include + +#include +#include +#include #ifdef __cplusplus extern "C" { #endif -tSCC zCopyright[] = - "ntpdc copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - -/* extracted from ../include/copyright.def near line 8 */ -"see html/copyright.html"; -extern tUsageProc optionUsage; +extern FILE * option_usage_fp; +#define zCopyright (ntpdc_opt_strs+0) +#define zLicenseDescrip (ntpdc_opt_strs+341) /* * global included definitions @@ -53,238 +64,298 @@ extern tUsageProc optionUsage; #ifndef NULL # define NULL 0 #endif -#ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -#endif -#ifndef EXIT_FAILURE -# define EXIT_FAILURE 1 -#endif -/* - * Ipv4 option description: - */ -tSCC zIpv4Text[] = - "Force IPv4 DNS name resolution"; -tSCC zIpv4_NAME[] = "IPV4"; -tSCC zIpv4_Name[] = "ipv4"; -#define IPV4_FLAGS (OPTST_DISABLED) -/* - * Ipv6 option description: +/** + * static const strings for ntpdc options */ -tSCC zIpv6Text[] = - "Force IPv6 DNS name resolution"; -tSCC zIpv6_NAME[] = "IPV6"; -tSCC zIpv6_Name[] = "ipv6"; -#define IPV6_FLAGS (OPTST_DISABLED) - -/* - * Command option description: - */ -tSCC zCommandText[] = - "run a command and exit"; -tSCC zCommand_NAME[] = "COMMAND"; -tSCC zCommand_Name[] = "command"; -#define COMMAND_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Listpeers option description with +static char const ntpdc_opt_strs[1911] = +/* 0 */ "ntpdc 4.2.8p4\n" + "Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n" + "This is free software. It is licensed for use, modification and\n" + "redistribution under the terms of the NTP License, copies of which\n" + "can be seen at:\n" + " \n" + " \n\0" +/* 341 */ "Permission to use, copy, modify, and distribute this software and its\n" + "documentation for any purpose with or without fee is hereby granted,\n" + "provided that the above copyright notice appears in all copies and that\n" + "both the copyright notice and this permission notice appear in supporting\n" + "documentation, and that the name The University of Delaware not be used in\n" + "advertising or publicity pertaining to distribution of the software without\n" + "specific, written prior permission. The University of Delaware and Network\n" + "Time Foundation makes no representations about the suitability this\n" + "software for any purpose. It is provided \"as is\" without express or\n" + "implied warranty.\n\0" +/* 1009 */ "Force IPv4 DNS name resolution\0" +/* 1040 */ "IPV4\0" +/* 1045 */ "ipv4\0" +/* 1050 */ "Force IPv6 DNS name resolution\0" +/* 1081 */ "IPV6\0" +/* 1086 */ "ipv6\0" +/* 1091 */ "run a command and exit\0" +/* 1114 */ "COMMAND\0" +/* 1122 */ "command\0" +/* 1130 */ "Increase debug verbosity level\0" +/* 1161 */ "DEBUG_LEVEL\0" +/* 1173 */ "debug-level\0" +/* 1185 */ "Set the debug verbosity level\0" +/* 1215 */ "SET_DEBUG_LEVEL\0" +/* 1231 */ "set-debug-level\0" +/* 1247 */ "Force ntpq to operate in interactive mode\0" +/* 1289 */ "INTERACTIVE\0" +/* 1301 */ "interactive\0" +/* 1313 */ "Print a list of the peers\0" +/* 1339 */ "LISTPEERS\0" +/* 1349 */ "listpeers\0" +/* 1359 */ "numeric host addresses\0" +/* 1382 */ "NUMERIC\0" +/* 1390 */ "numeric\0" +/* 1398 */ "PEERS\0" +/* 1404 */ "peers\0" +/* 1410 */ "Show a list of the peers\0" +/* 1435 */ "SHOWPEERS\0" +/* 1445 */ "showpeers\0" +/* 1455 */ "display extended usage information and exit\0" +/* 1499 */ "help\0" +/* 1504 */ "extended usage information passed thru pager\0" +/* 1549 */ "more-help\0" +/* 1559 */ "output version information and exit\0" +/* 1595 */ "version\0" +/* 1603 */ "save the option state to a config file\0" +/* 1642 */ "save-opts\0" +/* 1652 */ "load options from a config file\0" +/* 1684 */ "LOAD_OPTS\0" +/* 1694 */ "no-load-opts\0" +/* 1707 */ "no\0" +/* 1710 */ "NTPDC\0" +/* 1716 */ "ntpdc - vendor-specific NTPD control program - Ver. 4.2.8p4\n" + "Usage: %s [ - [] | --[{=| }] ]... [ host ...]\n\0" +/* 1846 */ "$HOME\0" +/* 1852 */ ".\0" +/* 1854 */ ".ntprc\0" +/* 1861 */ "http://bugs.ntp.org, bugs@ntp.org\0" +/* 1895 */ "\n\0" +/* 1897 */ "ntpdc 4.2.8p4"; + +/** + * ipv4 option description with * "Must also have options" and "Incompatible options": */ -tSCC zListpeersText[] = - "Print a list of the peers"; -tSCC zListpeers_NAME[] = "LISTPEERS"; -tSCC zListpeers_Name[] = "listpeers"; -static const int - aListpeersCantList[] = { - INDEX_OPT_COMMAND, NO_EQUIVALENT }; -#define LISTPEERS_FLAGS (OPTST_DISABLED) - -/* - * Peers option description with +/** Descriptive text for the ipv4 option */ +#define IPV4_DESC (ntpdc_opt_strs+1009) +/** Upper-cased name for the ipv4 option */ +#define IPV4_NAME (ntpdc_opt_strs+1040) +/** Name string for the ipv4 option */ +#define IPV4_name (ntpdc_opt_strs+1045) +/** Other options that appear in conjunction with the ipv4 option */ +static int const aIpv4CantList[] = { + INDEX_OPT_IPV6, NO_EQUIVALENT }; +/** Compiled in flag settings for the ipv4 option */ +#define IPV4_FLAGS (OPTST_DISABLED) + +/** + * ipv6 option description with * "Must also have options" and "Incompatible options": */ -tSCC zPeersText[] = - "Print a list of the peers"; -tSCC zPeers_NAME[] = "PEERS"; -tSCC zPeers_Name[] = "peers"; -static const int - aPeersCantList[] = { - INDEX_OPT_COMMAND, NO_EQUIVALENT }; -#define PEERS_FLAGS (OPTST_DISABLED) - -/* - * Showpeers option description with - * "Must also have options" and "Incompatible options": +/** Descriptive text for the ipv6 option */ +#define IPV6_DESC (ntpdc_opt_strs+1050) +/** Upper-cased name for the ipv6 option */ +#define IPV6_NAME (ntpdc_opt_strs+1081) +/** Name string for the ipv6 option */ +#define IPV6_name (ntpdc_opt_strs+1086) +/** Other options that appear in conjunction with the ipv6 option */ +static int const aIpv6CantList[] = { + INDEX_OPT_IPV4, NO_EQUIVALENT }; +/** Compiled in flag settings for the ipv6 option */ +#define IPV6_FLAGS (OPTST_DISABLED) + +/** + * command option description: */ -tSCC zShowpeersText[] = - "Show a list of the peers"; -tSCC zShowpeers_NAME[] = "SHOWPEERS"; -tSCC zShowpeers_Name[] = "showpeers"; -static const int - aShowpeersCantList[] = { - INDEX_OPT_COMMAND, NO_EQUIVALENT }; -#define SHOWPEERS_FLAGS (OPTST_DISABLED) +/** Descriptive text for the command option */ +#define COMMAND_DESC (ntpdc_opt_strs+1091) +/** Upper-cased name for the command option */ +#define COMMAND_NAME (ntpdc_opt_strs+1114) +/** Name string for the command option */ +#define COMMAND_name (ntpdc_opt_strs+1122) +/** Compiled in flag settings for the command option */ +#define COMMAND_FLAGS (OPTST_DISABLED | OPTST_STACKED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -/* - * Interactive option description with +/** + * debug-level option description: + */ +/** Descriptive text for the debug-level option */ +#define DEBUG_LEVEL_DESC (ntpdc_opt_strs+1130) +/** Upper-cased name for the debug-level option */ +#define DEBUG_LEVEL_NAME (ntpdc_opt_strs+1161) +/** Name string for the debug-level option */ +#define DEBUG_LEVEL_name (ntpdc_opt_strs+1173) +/** Compiled in flag settings for the debug-level option */ +#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) + +/** + * set-debug-level option description: + */ +/** Descriptive text for the set-debug-level option */ +#define SET_DEBUG_LEVEL_DESC (ntpdc_opt_strs+1185) +/** Upper-cased name for the set-debug-level option */ +#define SET_DEBUG_LEVEL_NAME (ntpdc_opt_strs+1215) +/** Name string for the set-debug-level option */ +#define SET_DEBUG_LEVEL_name (ntpdc_opt_strs+1231) +/** Compiled in flag settings for the set-debug-level option */ +#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) + +/** + * interactive option description with * "Must also have options" and "Incompatible options": */ -tSCC zInteractiveText[] = - "Force ntpq to operate in interactive mode"; -tSCC zInteractive_NAME[] = "INTERACTIVE"; -tSCC zInteractive_Name[] = "interactive"; -static const int - aInteractiveCantList[] = { +/** Descriptive text for the interactive option */ +#define INTERACTIVE_DESC (ntpdc_opt_strs+1247) +/** Upper-cased name for the interactive option */ +#define INTERACTIVE_NAME (ntpdc_opt_strs+1289) +/** Name string for the interactive option */ +#define INTERACTIVE_name (ntpdc_opt_strs+1301) +/** Other options that appear in conjunction with the interactive option */ +static int const aInteractiveCantList[] = { INDEX_OPT_COMMAND, INDEX_OPT_LISTPEERS, INDEX_OPT_PEERS, INDEX_OPT_SHOWPEERS, NO_EQUIVALENT }; -#define INTERACTIVE_FLAGS (OPTST_DISABLED) +/** Compiled in flag settings for the interactive option */ +#define INTERACTIVE_FLAGS (OPTST_DISABLED) -/* - * Debug_Level option description: +/** + * listpeers option description with + * "Must also have options" and "Incompatible options": */ -#ifdef DEBUG -tSCC zDebug_LevelText[] = - "Increase output debug message level"; -tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; -tSCC zDebug_Level_Name[] = "debug-level"; -#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) - -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ +/** Descriptive text for the listpeers option */ +#define LISTPEERS_DESC (ntpdc_opt_strs+1313) +/** Upper-cased name for the listpeers option */ +#define LISTPEERS_NAME (ntpdc_opt_strs+1339) +/** Name string for the listpeers option */ +#define LISTPEERS_name (ntpdc_opt_strs+1349) +/** Other options that appear in conjunction with the listpeers option */ +static int const aListpeersCantList[] = { + INDEX_OPT_COMMAND, NO_EQUIVALENT }; +/** Compiled in flag settings for the listpeers option */ +#define LISTPEERS_FLAGS (OPTST_DISABLED) -/* - * Set_Debug_Level option description: +/** + * numeric option description: */ -#ifdef DEBUG -tSCC zSet_Debug_LevelText[] = - "Set the output debug message level"; -tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; -tSCC zSet_Debug_Level_Name[] = "set-debug-level"; -#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Numeric option description: +/** Descriptive text for the numeric option */ +#define NUMERIC_DESC (ntpdc_opt_strs+1359) +/** Upper-cased name for the numeric option */ +#define NUMERIC_NAME (ntpdc_opt_strs+1382) +/** Name string for the numeric option */ +#define NUMERIC_name (ntpdc_opt_strs+1390) +/** Compiled in flag settings for the numeric option */ +#define NUMERIC_FLAGS (OPTST_DISABLED) + +/** + * peers option description with + * "Must also have options" and "Incompatible options": */ -tSCC zNumericText[] = - "numeric host addresses"; -tSCC zNumeric_NAME[] = "NUMERIC"; -tSCC zNumeric_Name[] = "numeric"; -#define NUMERIC_FLAGS (OPTST_DISABLED) +/** Descriptive text for the peers option */ +#define PEERS_DESC (ntpdc_opt_strs+1313) +/** Upper-cased name for the peers option */ +#define PEERS_NAME (ntpdc_opt_strs+1398) +/** Name string for the peers option */ +#define PEERS_name (ntpdc_opt_strs+1404) +/** Other options that appear in conjunction with the peers option */ +static int const aPeersCantList[] = { + INDEX_OPT_COMMAND, NO_EQUIVALENT }; +/** Compiled in flag settings for the peers option */ +#define PEERS_FLAGS (OPTST_DISABLED) -/* - * Help/More_Help/Version option descriptions: +/** + * showpeers option description with + * "Must also have options" and "Incompatible options": */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; +/** Descriptive text for the showpeers option */ +#define SHOWPEERS_DESC (ntpdc_opt_strs+1410) +/** Upper-cased name for the showpeers option */ +#define SHOWPEERS_NAME (ntpdc_opt_strs+1435) +/** Name string for the showpeers option */ +#define SHOWPEERS_name (ntpdc_opt_strs+1445) +/** Other options that appear in conjunction with the showpeers option */ +static int const aShowpeersCantList[] = { + INDEX_OPT_COMMAND, NO_EQUIVALENT }; +/** Compiled in flag settings for the showpeers option */ +#define SHOWPEERS_FLAGS (OPTST_DISABLED) /* - * Save/Load_Opts option description: + * Help/More_Help/Version option descriptions: */ -tSCC zSave_OptsText[] = "Save the option state to a config file"; -tSCC zSave_Opts_Name[] = "save-opts"; - -tSCC zLoad_OptsText[] = "Load options from a config file"; -tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; - -tSCC zNotLoad_Opts_Name[] = "no-load-opts"; -tSCC zNotLoad_Opts_Pfx[] = "no"; -#define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) -/* +#define HELP_DESC (ntpdc_opt_strs+1455) +#define HELP_name (ntpdc_opt_strs+1499) +#ifdef HAVE_WORKING_FORK +#define MORE_HELP_DESC (ntpdc_opt_strs+1504) +#define MORE_HELP_name (ntpdc_opt_strs+1549) +#define MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +#else +#define MORE_HELP_DESC HELP_DESC +#define MORE_HELP_name HELP_name +#define MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define VER_FLAGS (OPTST_IMM | OPTST_NO_INIT) +#else +# define VER_FLAGS (OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT) +#endif +#define VER_DESC (ntpdc_opt_strs+1559) +#define VER_name (ntpdc_opt_strs+1595) +#define SAVE_OPTS_DESC (ntpdc_opt_strs+1603) +#define SAVE_OPTS_name (ntpdc_opt_strs+1642) +#define LOAD_OPTS_DESC (ntpdc_opt_strs+1652) +#define LOAD_OPTS_NAME (ntpdc_opt_strs+1684) +#define NO_LOAD_OPTS_name (ntpdc_opt_strs+1694) +#define LOAD_OPTS_pfx (ntpdc_opt_strs+1707) +#define LOAD_OPTS_name (NO_LOAD_OPTS_name + 3) +/** * Declare option callback procedures */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ -#if defined(TEST_NTPDC_OPTS) -/* - * Under test, omit argument processing, or call optionStackArg, - * if multiple copies are allowed. - */ -extern tOptProc - optionPagedUsage, optionStackArg, optionVersionStderr; -static tOptProc - doUsageOpt; - -/* - * #define map the "normal" callout procs to the test ones... - */ -#define SET_DEBUG_LEVEL_OPT_PROC optionStackArg - - -#else /* NOT defined TEST_NTPDC_OPTS */ -/* - * When not under test, there are different procs to use - */ extern tOptProc - optionPagedUsage, optionPrintVersion, optionStackArg; + ntpOptionPrintVersion, optionBooleanVal, optionNestedVal, + optionNumericVal, optionPagedUsage, optionResetOpt, + optionStackArg, optionTimeDate, optionTimeVal, + optionUnstackArg, optionVendorOption; static tOptProc - doUsageOpt; - -/* - * #define map the "normal" callout procs + doOptDebug_Level, doUsageOpt; +#define VER_PROC ntpOptionPrintVersion + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Define the ntpdc Option Descriptions. + * This is an array of OPTION_CT entries, one for each + * option that the ntpdc program responds to. */ -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level - -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level -#endif /* defined(TEST_NTPDC_OPTS) */ -#ifdef TEST_NTPDC_OPTS -# define DOVERPROC optionVersionStderr -#else -# define DOVERPROC optionPrintVersion -#endif /* TEST_NTPDC_OPTS */ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpdc Option Descriptions. - */ -static tOptDesc optDesc[ OPTION_CT ] = { +static tOptDesc optDesc[OPTION_CT] = { { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, + /* equiv idx, value */ 0, VALUE_OPT_IPV4, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV4_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --ipv4 */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv4CantList, /* option proc */ NULL, - /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, + /* desc, NAME, name */ IPV4_DESC, IPV4_NAME, IPV4_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, + /* equiv idx, value */ 1, VALUE_OPT_IPV6, + /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV6_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --ipv6 */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv6CantList, /* option proc */ NULL, - /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, + /* desc, NAME, name */ IPV6_DESC, IPV6_NAME, IPV6_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 2, VALUE_OPT_COMMAND, @@ -292,205 +363,184 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ COMMAND_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --command */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionStackArg, - /* desc, NAME, name */ zCommandText, zCommand_NAME, zCommand_Name, + /* desc, NAME, name */ COMMAND_DESC, COMMAND_NAME, COMMAND_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 3, VALUE_OPT_LISTPEERS, - /* equiv idx, value */ 3, VALUE_OPT_LISTPEERS, + { /* entry idx, value */ 3, VALUE_OPT_DEBUG_LEVEL, + /* equiv idx, value */ 3, VALUE_OPT_DEBUG_LEVEL, /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ LISTPEERS_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* min, max, act ct */ 0, NOLIMIT, 0, + /* opt state flags */ DEBUG_LEVEL_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --debug-level */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aListpeersCantList, - /* option proc */ NULL, - /* desc, NAME, name */ zListpeersText, zListpeers_NAME, zListpeers_Name, + /* must/cannot opts */ NULL, NULL, + /* option proc */ doOptDebug_Level, + /* desc, NAME, name */ DEBUG_LEVEL_DESC, DEBUG_LEVEL_NAME, DEBUG_LEVEL_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 4, VALUE_OPT_PEERS, - /* equiv idx, value */ 4, VALUE_OPT_PEERS, + { /* entry idx, value */ 4, VALUE_OPT_SET_DEBUG_LEVEL, + /* equiv idx, value */ 4, VALUE_OPT_SET_DEBUG_LEVEL, /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PEERS_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* min, max, act ct */ 0, NOLIMIT, 0, + /* opt state flags */ SET_DEBUG_LEVEL_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --set-debug-level */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aPeersCantList, - /* option proc */ NULL, - /* desc, NAME, name */ zPeersText, zPeers_NAME, zPeers_Name, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ SET_DEBUG_LEVEL_DESC, SET_DEBUG_LEVEL_NAME, SET_DEBUG_LEVEL_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 5, VALUE_OPT_SHOWPEERS, - /* equiv idx, value */ 5, VALUE_OPT_SHOWPEERS, + { /* entry idx, value */ 5, VALUE_OPT_INTERACTIVE, + /* equiv idx, value */ 5, VALUE_OPT_INTERACTIVE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ SHOWPEERS_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* opt state flags */ INTERACTIVE_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --interactive */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aShowpeersCantList, + /* must/cannot opts */ NULL, aInteractiveCantList, /* option proc */ NULL, - /* desc, NAME, name */ zShowpeersText, zShowpeers_NAME, zShowpeers_Name, + /* desc, NAME, name */ INTERACTIVE_DESC, INTERACTIVE_NAME, INTERACTIVE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 6, VALUE_OPT_INTERACTIVE, - /* equiv idx, value */ 6, VALUE_OPT_INTERACTIVE, + { /* entry idx, value */ 6, VALUE_OPT_LISTPEERS, + /* equiv idx, value */ 6, VALUE_OPT_LISTPEERS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ INTERACTIVE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* opt state flags */ LISTPEERS_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --listpeers */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aInteractiveCantList, + /* must/cannot opts */ NULL, aListpeersCantList, /* option proc */ NULL, - /* desc, NAME, name */ zInteractiveText, zInteractive_NAME, zInteractive_Name, + /* desc, NAME, name */ LISTPEERS_DESC, LISTPEERS_NAME, LISTPEERS_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 7, VALUE_OPT_DEBUG_LEVEL, - /* equiv idx, value */ 7, VALUE_OPT_DEBUG_LEVEL, + { /* entry idx, value */ 7, VALUE_OPT_NUMERIC, + /* equiv idx, value */ 7, VALUE_OPT_NUMERIC, /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ NUMERIC_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --numeric */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zDebug_LevelText, zDebug_Level_NAME, zDebug_Level_Name, + /* desc, NAME, name */ NUMERIC_DESC, NUMERIC_NAME, NUMERIC_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 8, VALUE_OPT_SET_DEBUG_LEVEL, - /* equiv idx, value */ 8, VALUE_OPT_SET_DEBUG_LEVEL, + { /* entry idx, value */ 8, VALUE_OPT_PEERS, + /* equiv idx, value */ 8, VALUE_OPT_PEERS, /* equivalenced to */ NO_EQUIVALENT, - /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ SET_DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ PEERS_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --peers */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, - /* option proc */ SET_DEBUG_LEVEL_OPT_PROC, - /* desc, NAME, name */ zSet_Debug_LevelText, zSet_Debug_Level_NAME, zSet_Debug_Level_Name, + /* must/cannot opts */ NULL, aPeersCantList, + /* option proc */ NULL, + /* desc, NAME, name */ PEERS_DESC, PEERS_NAME, PEERS_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 9, VALUE_OPT_NUMERIC, - /* equiv idx, value */ 9, VALUE_OPT_NUMERIC, + { /* entry idx, value */ 9, VALUE_OPT_SHOWPEERS, + /* equiv idx, value */ 9, VALUE_OPT_SHOWPEERS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NUMERIC_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* opt state flags */ SHOWPEERS_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --showpeers */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aShowpeersCantList, /* option proc */ NULL, - /* desc, NAME, name */ zNumericText, zNumeric_NAME, zNumeric_Name, + /* desc, NAME, name */ SHOWPEERS_DESC, SHOWPEERS_NAME, SHOWPEERS_name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif - { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_VERSION, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ VER_FLAGS, AOUSE_VERSION, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ DOVERPROC, - /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, + /* option proc */ VER_PROC, + /* desc, NAME, name */ VER_DESC, NULL, VER_name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_HELP, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, AOUSE_HELP, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ doUsageOpt, - /* desc, NAME, name */ zHelpText, NULL, zHelp_Name, + /* desc, NAME, name */ HELP_DESC, NULL, HELP_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_MORE_HELP, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ MORE_HELP_FLAGS, AOUSE_MORE_HELP, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionPagedUsage, - /* desc, NAME, name */ zMore_HelpText, NULL, zMore_Help_Name, + /* desc, NAME, name */ MORE_HELP_DESC, NULL, MORE_HELP_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_SAVE_OPTS, VALUE_OPT_SAVE_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_SAVE_OPTS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) - | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, 0, + | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, AOUSE_SAVE_OPTS, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zSave_OptsText, NULL, zSave_Opts_Name, + /* desc, NAME, name */ SAVE_OPTS_DESC, NULL, SAVE_OPTS_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_LOAD_OPTS, VALUE_OPT_LOAD_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_LOAD_OPTS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ - | OPTST_DISABLE_IMM, 0, + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) + | OPTST_DISABLE_IMM, AOUSE_LOAD_OPTS, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionLoadOpt, - /* desc, NAME, name */ zLoad_OptsText, zLoad_Opts_NAME, zLoad_Opts_Name, - /* disablement strs */ zNotLoad_Opts_Name, zNotLoad_Opts_Pfx } + /* desc, NAME, name */ LOAD_OPTS_DESC, LOAD_OPTS_NAME, LOAD_OPTS_name, + /* disablement strs */ NO_LOAD_OPTS_name, LOAD_OPTS_pfx } }; -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpdc Option Environment - */ -tSCC zPROGNAME[] = "NTPDC"; -tSCC zUsageTitle[] = -"ntpdc - vendor-specific NTP query program - Ver. 4.2.4p8\n\ -USAGE: %s [ - [] | --[{=| }] ]... [ host ...]\n"; -tSCC zRcName[] = ".ntprc"; -tSCC* apzHomeList[] = { - "$HOME", - ".", - NULL }; - -tSCC zBugsAddr[] = "http://bugs.ntp.org, bugs@ntp.org"; -#define zExplain NULL -tSCC zDetail[] = "\n\ -The\n\ -[= prog-name =]\n\ -utility program is used to query an NTP daemon about its\n\ -current state and to request changes in that state.\n\ -It uses NTP mode 7 control message formats described in the source code.\n\ -The program may\n\ -be run either in interactive mode or controlled using command line\n\ -arguments.\n\ -Extensive state and statistics information is available\n\ -through the\n\ -[= prog-name =]\n\ -interface.\n\ -In addition, nearly all the\n\ -configuration options which can be specified at startup using\n\ -ntpd's configuration file may also be specified at run time using\n\ -[= prog-name =] .\n"; -tSCC zFullVersion[] = NTPDC_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** Reference to the upper cased version of ntpdc. */ +#define zPROGNAME (ntpdc_opt_strs+1710) +/** Reference to the title line for ntpdc usage. */ +#define zUsageTitle (ntpdc_opt_strs+1716) +/** ntpdc configuration file name. */ +#define zRcName (ntpdc_opt_strs+1854) +/** Directories to search for ntpdc config files. */ +static char const * const apzHomeList[3] = { + ntpdc_opt_strs+1846, + ntpdc_opt_strs+1852, + NULL }; +/** The ntpdc program bug email address. */ +#define zBugsAddr (ntpdc_opt_strs+1861) +/** Clarification/explanation of what ntpdc does. */ +#define zExplain (ntpdc_opt_strs+1895) +/** Extra detail explaining what ntpdc does. */ +#define zDetail (NULL) +/** The full version string for ntpdc. */ +#define zFullVersion (ntpdc_opt_strs+1897) +/* extracted from optcode.tlib near line 364 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -500,6 +550,90 @@ tSCC zFullVersion[] = NTPDC_FULL_VERSION; # define translate_option_strings NULL #endif /* ENABLE_NLS */ +#define ntpdc_full_usage (NULL) +#define ntpdc_short_usage (NULL) + +#endif /* not defined __doxygen__ */ + +/* + * Create the static procedure(s) declared above. + */ +/** + * The callout function that invokes the optionUsage function. + * + * @param[in] opts the AutoOpts option description structure + * @param[in] od the descriptor for the "help" (usage) option. + * @noreturn + */ +static void +doUsageOpt(tOptions * opts, tOptDesc * od) +{ + int ex_code; + ex_code = NTPDC_EXIT_SUCCESS; + optionUsage(&ntpdcOptions, ex_code); + /* NOTREACHED */ + exit(1); + (void)opts; + (void)od; +} + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Code to handle the debug-level option. + * + * @param[in] pOptions the ntpdc options data structure + * @param[in,out] pOptDesc the option descriptor for this option. + */ +static void +doOptDebug_Level(tOptions* pOptions, tOptDesc* pOptDesc) +{ + /* + * Be sure the flag-code[0] handles special values for the options pointer + * viz. (poptions <= OPTPROC_EMIT_LIMIT) *and also* the special flag bit + * ((poptdesc->fOptState & OPTST_RESET) != 0) telling the option to + * reset its state. + */ + /* extracted from debug-opt.def, line 15 */ +OPT_VALUE_SET_DEBUG_LEVEL++; + (void)pOptDesc; + (void)pOptions; +} +/* extracted from optmain.tlib near line 1250 */ + +/** + * The directory containing the data associated with ntpdc. + */ +#ifndef PKGDATADIR +# define PKGDATADIR "" +#endif + +/** + * Information about the person or institution that packaged ntpdc + * for the current distribution. + */ +#ifndef WITH_PACKAGER +# define ntpdc_packager_info NULL +#else +/** Packager information for ntpdc. */ +static char const ntpdc_packager_info[] = + "Packaged by " WITH_PACKAGER + +# ifdef WITH_PACKAGER_VERSION + " ("WITH_PACKAGER_VERSION")" +# endif + +# ifdef WITH_PACKAGER_BUG_REPORTS + "\nReport ntpdc bugs to " WITH_PACKAGER_BUG_REPORTS +# endif + "\n"; +#endif +#ifndef __doxygen__ + +#endif /* __doxygen__ */ +/** + * The option definitions for ntpdc. The one structure that + * binds them all. + */ tOptions ntpdcOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -509,158 +643,532 @@ tOptions ntpdcOptions = { + OPTPROC_LONGOPT + OPTPROC_NO_REQ_OPT + OPTPROC_ENVIRON - + OPTPROC_HAS_IMMED ), + + OPTPROC_MISUSE ), 0, NULL, /* current option index, current option */ NULL, NULL, zPROGNAME, - zRcName, zCopyright, zCopyrightNotice, + zRcName, zCopyright, zLicenseDescrip, zFullVersion, apzHomeList, zUsageTitle, zExplain, zDetail, optDesc, zBugsAddr, /* address to send bugs to */ NULL, NULL, /* extensions/saved state */ - optionUsage, /* usage procedure */ + optionUsage, /* usage procedure */ translate_option_strings, /* translation procedure */ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 15 /* full option count */, 10 /* user option count */ + 15 /* full option count */, 10 /* user option count */, + ntpdc_full_usage, ntpdc_short_usage, + NULL, NULL, + PKGDATADIR, ntpdc_packager_info }; -/* - * Create the static procedure(s) declared above. - */ -static void -doUsageOpt( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - USAGE( EXIT_SUCCESS ); -} - -#if ! defined(TEST_NTPDC_OPTS) - -/* * * * * * * - * - * For the set-debug-level option, when DEBUG is #define-d. - */ -#ifdef DEBUG -static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - /* extracted from ../include/debug-opt.def, line 29 */ -DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); -} -#endif /* defined DEBUG */ - -#endif /* defined(TEST_NTPDC_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ - -#if defined(TEST_NTPDC_OPTS) /* TEST MAIN PROCEDURE: */ - -int -main( int argc, char** argv ) -{ - int res = EXIT_SUCCESS; - (void)optionProcess( &ntpdcOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpdcOptions ); - } - return res; -} -#endif /* defined TEST_NTPDC_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ - #if ENABLE_NLS +/** + * This code is designed to translate translatable option text for the + * ntpdc program. These translations happen upon entry + * to optionProcess(). + */ #include #include #include #include +#ifdef HAVE_DCGETTEXT +# include +#endif #include -static char* AO_gettext( char const* pz ); -static void coerce_it(void** s); +static char * AO_gettext(char const * pz); +static void coerce_it(void ** s); -static char* -AO_gettext( char const* pz ) +/** + * AutoGen specific wrapper function for gettext. It relies on the macro _() + * to convert from English to the target language, then strdup-duplicates the + * result string. It tries the "libopts" domain first, then whatever has been + * set via the \a textdomain(3) call. + * + * @param[in] pz the input text used as a lookup key. + * @returns the translated text (if there is one), + * or the original text (if not). + */ +static char * +AO_gettext(char const * pz) { - char* pzRes; + char * res; if (pz == NULL) return NULL; - pzRes = _(pz); - if (pzRes == pz) - return pzRes; - pzRes = strdup( pzRes ); - if (pzRes == NULL) { - fputs( _("No memory for duping translated strings\n"), stderr ); - exit( EXIT_FAILURE ); +#ifdef HAVE_DCGETTEXT + /* + * While processing the option_xlateable_txt data, try to use the + * "libopts" domain. Once we switch to the option descriptor data, + * do *not* use that domain. + */ + if (option_xlateable_txt.field_ct != 0) { + res = dgettext("libopts", pz); + if (res == pz) + res = (char *)VOIDP(_(pz)); + } else + res = (char *)VOIDP(_(pz)); +#else + res = (char *)VOIDP(_(pz)); +#endif + if (res == pz) + return res; + res = strdup(res); + if (res == NULL) { + fputs(_("No memory for duping translated strings\n"), stderr); + exit(NTPDC_EXIT_FAILURE); } - return pzRes; + return res; } -static void coerce_it(void** s) { *s = AO_gettext(*s); } -#define COERSION(_f) \ - coerce_it((void*)&(ntpdcOptions._f)) +/** + * All the pointers we use are marked "* const", but they are stored in + * writable memory. Coerce the mutability and set the pointer. + */ +static void coerce_it(void ** s) { *s = AO_gettext(*s); +} -/* - * This invokes the translation code (e.g. gettext(3)). +/** + * Translate all the translatable strings in the ntpdcOptions + * structure defined above. This is done only once. */ static void -translate_option_strings( void ) +translate_option_strings(void) { + tOptions * const opts = &ntpdcOptions; + /* * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_xlateable_txt.field_ct != 0) { + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + char ** ppz = (char**)VOIDP(&(option_xlateable_txt)); + int ix = option_xlateable_txt.field_ct; do { - ppz++; + ppz++; /* skip over field_ct */ *ppz = AO_gettext(*ppz); } while (--ix > 0); - } - option_usage_text.field_ct = 0; - - { - tOptDesc* pOD = ntpdcOptions.pOptDesc; - int ix = ntpdcOptions.optCt; - - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + /* prevent re-translation and disable "libopts" domain lookup */ + option_xlateable_txt.field_ct = 0; + + coerce_it(VOIDP(&(opts->pzCopyright))); + coerce_it(VOIDP(&(opts->pzCopyNotice))); + coerce_it(VOIDP(&(opts->pzFullVersion))); + coerce_it(VOIDP(&(opts->pzUsageTitle))); + coerce_it(VOIDP(&(opts->pzExplain))); + coerce_it(VOIDP(&(opts->pzDetail))); + { + tOptDesc * od = opts->pOptDesc; + for (ix = opts->optCt; ix > 0; ix--, od++) + coerce_it(VOIDP(&(od->pzText))); } } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } - #endif /* ENABLE_NLS */ +#ifdef DO_NOT_COMPILE_THIS_CODE_IT_IS_FOR_GETTEXT +/** I18N function strictly for xgettext. Do not compile. */ +static void bogus_function(void) { + /* TRANSLATORS: + + The following dummy function was crated solely so that xgettext can + extract the correct strings. These strings are actually referenced + by a field name in the ntpdcOptions structure noted in the + comments below. The literal text is defined in ntpdc_opt_strs. + + NOTE: the strings below are segmented with respect to the source string + ntpdc_opt_strs. The strings above are handed off for translation + at run time a paragraph at a time. Consequently, they are presented here + for translation a paragraph at a time. + + ALSO: often the description for an option will reference another option + by name. These are set off with apostrophe quotes (I hope). Do not + translate option names. + */ + /* referenced via ntpdcOptions.pzCopyright */ + puts(_("ntpdc 4.2.8p4\n\ +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n\ +This is free software. It is licensed for use, modification and\n\ +redistribution under the terms of the NTP License, copies of which\n\ +can be seen at:\n")); + puts(_(" \n\ + \n")); + + /* referenced via ntpdcOptions.pzCopyNotice */ + puts(_("Permission to use, copy, modify, and distribute this software and its\n\ +documentation for any purpose with or without fee is hereby granted,\n\ +provided that the above copyright notice appears in all copies and that\n\ +both the copyright notice and this permission notice appear in supporting\n\ +documentation, and that the name The University of Delaware not be used in\n\ +advertising or publicity pertaining to distribution of the software without\n\ +specific, written prior permission. The University of Delaware and Network\n\ +Time Foundation makes no representations about the suitability this\n\ +software for any purpose. It is provided \"as is\" without express or\n\ +implied warranty.\n")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Force IPv4 DNS name resolution")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Force IPv6 DNS name resolution")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("run a command and exit")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Increase debug verbosity level")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Set the debug verbosity level")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Force ntpq to operate in interactive mode")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Print a list of the peers")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("numeric host addresses")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Print a list of the peers")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("Show a list of the peers")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("display extended usage information and exit")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("extended usage information passed thru pager")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("output version information and exit")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("save the option state to a config file")); + + /* referenced via ntpdcOptions.pOptDesc->pzText */ + puts(_("load options from a config file")); + + /* referenced via ntpdcOptions.pzUsageTitle */ + puts(_("ntpdc - vendor-specific NTPD control program - Ver. 4.2.8p4\n\ +Usage: %s [ - [] | --[{=| }] ]... [ host ...]\n")); + + /* referenced via ntpdcOptions.pzExplain */ + puts(_("\n")); + + /* referenced via ntpdcOptions.pzFullVersion */ + puts(_("ntpdc 4.2.8p4")); + + /* referenced via ntpdcOptions.pzFullUsage */ + puts(_("<<>>")); + + /* referenced via ntpdcOptions.pzShortUsage */ + puts(_("<<>>")); + /* LIBOPTS-MESSAGES: */ +#line 67 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 93 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 53 "../init.c" + puts(_("AutoOpts function called without option descriptor\n")); +#line 86 "../init.c" + puts(_("\tThis exceeds the compiled library version: ")); +#line 84 "../init.c" + puts(_("Automated Options Processing Error!\n" + "\t%s called AutoOpts function with structure version %d:%d:%d.\n")); +#line 80 "../autoopts.c" + puts(_("realloc of %d bytes at 0x%p failed\n")); +#line 88 "../init.c" + puts(_("\tThis is less than the minimum library version: ")); +#line 121 "../version.c" + puts(_("Automated Options version %s\n" + "\tCopyright (C) 1999-2014 by Bruce Korb - all rights reserved\n")); +#line 87 "../makeshell.c" + puts(_("(AutoOpts bug): %s.\n")); +#line 90 "../reset.c" + puts(_("optionResetOpt() called, but reset-option not configured")); +#line 292 "../usage.c" + puts(_("could not locate the 'help' option")); +#line 336 "../autoopts.c" + puts(_("optionProcess() was called with invalid data")); +#line 748 "../usage.c" + puts(_("invalid argument type specified")); +#line 598 "../find.c" + puts(_("defaulted to option with optional arg")); +#line 76 "../alias.c" + puts(_("aliasing option is out of range.")); +#line 234 "../enum.c" + puts(_("%s error: the keyword '%s' is ambiguous for %s\n")); +#line 108 "../find.c" + puts(_(" The following options match:\n")); +#line 293 "../find.c" + puts(_("%s: ambiguous option name: %s (matches %d options)\n")); +#line 161 "../check.c" + puts(_("%s: Command line arguments required\n")); +#line 43 "../alias.c" + puts(_("%d %s%s options allowed\n")); +#line 94 "../makeshell.c" + puts(_("%s error %d (%s) calling %s for '%s'\n")); +#line 306 "../makeshell.c" + puts(_("interprocess pipe")); +#line 168 "../version.c" + puts(_("error: version option argument '%c' invalid. Use:\n" + "\t'v' - version only\n" + "\t'c' - version and copyright\n" + "\t'n' - version and full copyright notice\n")); +#line 58 "../check.c" + puts(_("%s error: the '%s' and '%s' options conflict\n")); +#line 217 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 430 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 38 "../alias.c" + puts(_("-equivalence")); +#line 469 "../find.c" + puts(_("%s: illegal option -- %c\n")); +#line 110 "../reset.c" + puts(_("%s: illegal option -- %c\n")); +#line 271 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 755 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 118 "../reset.c" + puts(_("%s: illegal option -- %s\n")); +#line 335 "../find.c" + puts(_("%s: unknown vendor extension option -- %s\n")); +#line 159 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 169 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 747 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 1081 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 385 "../find.c" + puts(_("%s: invalid option name: %s\n")); +#line 527 "../find.c" + puts(_("%s: The '%s' option requires an argument.\n")); +#line 156 "../autoopts.c" + puts(_("(AutoOpts bug): Equivalenced option '%s' was equivalenced to both\n" + "\t'%s' and '%s'.")); +#line 94 "../check.c" + puts(_("%s error: The %s option is required\n")); +#line 632 "../find.c" + puts(_("%s: The '%s' option cannot have an argument.\n")); +#line 151 "../check.c" + puts(_("%s: Command line arguments are not allowed.\n")); +#line 535 "../save.c" + puts(_("error %d (%s) creating %s\n")); +#line 234 "../enum.c" + puts(_("%s error: '%s' does not match any %s keywords.\n")); +#line 93 "../reset.c" + puts(_("%s error: The '%s' option requires an argument.\n")); +#line 184 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 238 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 143 "../restore.c" + puts(_("%s error: no saved option state\n")); +#line 231 "../autoopts.c" + puts(_("'%s' is not a command line option.\n")); +#line 111 "../time.c" + puts(_("%s error: '%s' is not a recognizable date/time.\n")); +#line 132 "../save.c" + puts(_("'%s' not defined\n")); +#line 50 "../time.c" + puts(_("%s error: '%s' is not a recognizable time duration.\n")); +#line 92 "../check.c" + puts(_("%s error: The %s option must appear %d times.\n")); +#line 164 "../numeric.c" + puts(_("%s error: '%s' is not a recognizable number.\n")); +#line 200 "../enum.c" + puts(_("%s error: %s exceeds %s keyword count\n")); +#line 330 "../usage.c" + puts(_("Try '%s %s' for more information.\n")); +#line 45 "../alias.c" + puts(_("one %s%s option allowed\n")); +#line 208 "../makeshell.c" + puts(_("standard output")); +#line 943 "../makeshell.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard output")); +#line 415 "../usage.c" + puts(_("standard output")); +#line 625 "../usage.c" + puts(_("standard output")); +#line 175 "../version.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard error")); +#line 415 "../usage.c" + puts(_("standard error")); +#line 625 "../usage.c" + puts(_("standard error")); +#line 175 "../version.c" + puts(_("standard error")); +#line 208 "../makeshell.c" + puts(_("write")); +#line 943 "../makeshell.c" + puts(_("write")); +#line 273 "../usage.c" + puts(_("write")); +#line 414 "../usage.c" + puts(_("write")); +#line 624 "../usage.c" + puts(_("write")); +#line 174 "../version.c" + puts(_("write")); +#line 60 "../numeric.c" + puts(_("%s error: %s option value %ld is out of range.\n")); +#line 44 "../check.c" + puts(_("%s error: %s option requires the %s option\n")); +#line 131 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 183 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 237 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 256 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 534 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); + /* END-LIBOPTS-MESSAGES */ + + /* USAGE-TEXT: */ +#line 873 "../usage.c" + puts(_("\t\t\t\t- an alternate for '%s'\n")); +#line 1148 "../usage.c" + puts(_("Version, usage and configuration options:")); +#line 924 "../usage.c" + puts(_("\t\t\t\t- default option for unnamed options\n")); +#line 837 "../usage.c" + puts(_("\t\t\t\t- disabled as '--%s'\n")); +#line 1117 "../usage.c" + puts(_(" --- %-14s %s\n")); +#line 1115 "../usage.c" + puts(_("This option has been disabled")); +#line 864 "../usage.c" + puts(_("\t\t\t\t- enabled by default\n")); +#line 40 "../alias.c" + puts(_("%s error: only ")); +#line 1194 "../usage.c" + puts(_(" - examining environment variables named %s_*\n")); +#line 168 "../file.c" + puts(_("\t\t\t\t- file must not pre-exist\n")); +#line 172 "../file.c" + puts(_("\t\t\t\t- file must pre-exist\n")); +#line 380 "../usage.c" + puts(_("Options are specified by doubled hyphens and their name or by a single\n" + "hyphen and the flag character.\n")); +#line 921 "../makeshell.c" + puts(_("\n" + "= = = = = = = =\n\n" + "This incarnation of genshell will produce\n" + "a shell script to parse the options for %s:\n\n")); +#line 166 "../enum.c" + puts(_(" or an integer mask with any of the lower %d bits set\n")); +#line 897 "../usage.c" + puts(_("\t\t\t\t- is a set membership option\n")); +#line 918 "../usage.c" + puts(_("\t\t\t\t- must appear between %d and %d times\n")); +#line 382 "../usage.c" + puts(_("Options are specified by single or double hyphens and their name.\n")); +#line 904 "../usage.c" + puts(_("\t\t\t\t- may appear multiple times\n")); +#line 891 "../usage.c" + puts(_("\t\t\t\t- may not be preset\n")); +#line 1309 "../usage.c" + puts(_(" Arg Option-Name Description\n")); +#line 1245 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1303 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1304 "../usage.c" + puts(_(" %3s %s")); +#line 1310 "../usage.c" + puts(_(" %3s %s")); +#line 387 "../usage.c" + puts(_("The '-#' option may omit the hash char\n")); +#line 383 "../usage.c" + puts(_("All arguments are named options.\n")); +#line 971 "../usage.c" + puts(_(" - reading file %s")); +#line 409 "../usage.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 100 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 129 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 903 "../usage.c" + puts(_("\t\t\t\t- may NOT appear - preset only\n")); +#line 944 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 1192 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 682 "../usage.c" + puts(_("prohibits these options:\n")); +#line 677 "../usage.c" + puts(_("prohibits the option '%s'\n")); +#line 81 "../numeric.c" + puts(_("%s%ld to %ld")); +#line 79 "../numeric.c" + puts(_("%sgreater than or equal to %ld")); +#line 75 "../numeric.c" + puts(_("%s%ld exactly")); +#line 68 "../numeric.c" + puts(_("%sit must lie in one of the ranges:\n")); +#line 68 "../numeric.c" + puts(_("%sit must be in the range:\n")); +#line 88 "../numeric.c" + puts(_(", or\n")); +#line 66 "../numeric.c" + puts(_("%sis scalable with a suffix: k/K/m/M/g/G/t/T\n")); +#line 77 "../numeric.c" + puts(_("%sless than or equal to %ld")); +#line 390 "../usage.c" + puts(_("Operands and options may be intermixed. They will be reordered.\n")); +#line 652 "../usage.c" + puts(_("requires the option '%s'\n")); +#line 655 "../usage.c" + puts(_("requires these options:\n")); +#line 1321 "../usage.c" + puts(_(" Arg Option-Name Req? Description\n")); +#line 1315 "../usage.c" + puts(_(" Flg Arg Option-Name Req? Description\n")); +#line 167 "../enum.c" + puts(_("or you may use a numeric representation. Preceding these with a '!'\n" + "will clear the bits, specifying 'none' will clear all bits, and 'all'\n" + "will set them all. Multiple entries may be passed as an option\n" + "argument list.\n")); +#line 910 "../usage.c" + puts(_("\t\t\t\t- may appear up to %d times\n")); +#line 77 "../enum.c" + puts(_("The valid \"%s\" option keywords are:\n")); +#line 1152 "../usage.c" + puts(_("The next option supports vendor supported extra options:")); +#line 773 "../usage.c" + puts(_("These additional options are:")); + /* END-USAGE-TEXT */ +} +#endif /* uncompilable code */ #ifdef __cplusplus } #endif diff --git a/contrib/ntp/ntpdc/ntpdc-opts.def b/contrib/ntp/ntpdc/ntpdc-opts.def index 0b5aefee9..df3350eb8 100644 --- a/contrib/ntp/ntpdc/ntpdc-opts.def +++ b/contrib/ntp/ntpdc/ntpdc-opts.def @@ -2,20 +2,19 @@ autogen definitions options; +#include autogen-version.def +#include copyright.def + prog-name = "ntpdc"; -prog-title = "vendor-specific NTP query program"; +prog-title = "vendor-specific NTPD control program"; argument = '[ host ...]'; -#include copyright.def #include homerc.def -#include autogen-version.def - -test-main; flag = { name = ipv4; value = 4; - equivalence = ipv4; + flags-cant = ipv6; descrip = "Force IPv4 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -26,7 +25,7 @@ flag = { flag = { name = ipv6; value = 6; - equivalence = ipv4; + flags-cant = ipv4; descrip = "Force IPv6 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -49,6 +48,19 @@ flag = { _EndOfDoc_; }; +#include debug-opt.def + +flag = { + name = interactive; + value = i; + flags-cant = command, listpeers, peers, showpeers; + descrip = "Force ntpq to operate in interactive mode"; + doc = <<- _EndOfDoc_ + Force ntpq to operate in interactive mode. Prompts will be written + to the standard output and commands read from the standard input. + _EndOfDoc_; +}; + flag = { name = listpeers; value = l; @@ -60,6 +72,16 @@ flag = { _EndOfDoc_; }; +flag = { + name = numeric; + value = n; + descrip = "numeric host addresses"; + doc = <<- _EndOfDoc_ + Output all host addresses in dotted-quad numeric format rather than + converting to the canonical host names. + _EndOfDoc_; +}; + flag = { name = peers; value = p; @@ -82,46 +104,709 @@ flag = { _EndOfDoc_; }; -flag = { - name = interactive; - value = i; - flags-cant = command, listpeers, peers, showpeers; - descrip = "Force ntpq to operate in interactive mode"; - doc = <<- _EndOfDoc_ - Force ntpq to operate in interactive mode. Prompts will be written - to the standard output and commands read from the standard input. - _EndOfDoc_; +/* explain: Additional information whenever the usage routine is invoked */ +explain = <<- _END_EXPLAIN + _END_EXPLAIN; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +.Nm +is deprecated. +Please use +.Xr ntpq 1ntpqmdoc instead - it can do everything +.Nm +used to do, and it does so using a much more sane interface. +.Pp +.Nm +is a utility program used to query +.Xr ntpd 1ntpdmdoc +about its +current state and to request changes in that state. +It uses NTP mode 7 control message formats described in the source code. +The program may +be run either in interactive mode or controlled using command line +arguments. +Extensive state and statistics information is available +through the +.Nm +interface. +In addition, nearly all the +configuration options which can be specified at startup using +ntpd's configuration file may also be specified at run time using +.Nm . + _END_PROG_MDOC_DESCRIP; }; -#include debug-opt.def -flag = { - name = numeric; - value = n; - descrip = "numeric host addresses"; - doc = <<- _EndOfDoc_ - Output all host addresses in dotted-quad numeric format rather than - converting to the canonical host names. - _EndOfDoc_; +doc-section = { + ds-type = 'USAGE'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_USAGE +If one or more request options are included on the command line +when +.Nm +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +.Nm +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +.Nm +utility will prompt for +commands if the standard input is a terminal device. +.Pp +The +.Nm +utility uses NTP mode 7 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +.Nm +utility makes +no attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +.Pp +The operation of +.Nm +are specific to the particular +implementation of the +.Xr ntpd 1ntpdmdoc +daemon and can be expected to +work only with this and maybe some previous versions of the daemon. +Requests from a remote +.Nm +utility which affect the +state of the local server must be authenticated, which requires +both the remote program and local server share a common key and key +identifier. +.Pp +Note that in contexts where a host name is expected, a +.Fl 4 +qualifier preceding the host name forces DNS resolution to the IPv4 namespace, +while a +.Fl 6 +qualifier forces DNS resolution to the IPv6 namespace. +Specifying a command line option other than +.Fl i +or +.Fl n +will cause the specified query (queries) to be sent to +the indicated host(s) immediately. +Otherwise, +.Nm +will +attempt to read interactive format commands from the standard +input. +.Ss "Interactive Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +The output of a +command is normally sent to the standard output, but optionally the +output of individual commands may be sent to a file by appending a +.Ql \&> , +followed by a file name, to the command line. +.Pp +A number of interactive format commands are executed entirely +within the +.Nm +utility itself and do not result in NTP +mode 7 requests being sent to a server. +These are described +following. +.Bl -tag -width indent +.It Ic \&? Ar command_keyword +.It Ic help Ar command_keyword +A +.Sq Ic \&? +will print a list of all the command +keywords known to this incarnation of +.Nm . +A +.Sq Ic \&? +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +.Xr ntpq 1ntpqmdoc +than this manual +page. +.It Ic delay Ar milliseconds +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.It Ic host Ar hostname +Set the host to which future queries will be sent. +Hostname may +be either a host name or a numeric address. +.It Ic hostnames Op Cm yes | Cm no +If +.Cm yes +is specified, host names are printed in +information displays. +If +.Cm no +is specified, numeric +addresses are printed instead. +The default is +.Cm yes , +unless +modified using the command line +.Fl n +switch. +.It Ic keyid Ar keyid +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to a key number the server has been configured to use for this +purpose. +.It Ic quit +Exit +.Nm . +.It Ic passwd +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.It Ic timeout Ar milliseconds +Specify a timeout period for responses to server queries. +The +default is about 8000 milliseconds. +Note that since +.Nm +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.El +.Ss "Control Message Commands" +Query commands result in NTP mode 7 packets containing requests for +information being sent to the server. +These are read-only commands +in that they make no modification of the server configuration +state. +.Bl -tag -width indent +.It Ic listpeers +Obtains and prints a brief list of the peers for which the +server is maintaining state. +These should include all configured +peer associations as well as those peers whose stratum is such that +they are considered by the server to be possible future +synchronization candidates. +.It Ic peers +Obtains a list of peers for which the server is maintaining +state, along with a summary of that state. +Summary information +includes the address of the remote peer, the local interface +address (0.0.0.0 if a local address has yet to be determined), the +stratum of the remote peer (a stratum of 16 indicates the remote +peer is unsynchronized), the polling interval, in seconds, the +reachability register, in octal, and the current estimated delay, +offset and dispersion of the peer, all in seconds. +.Pp +The character in the left margin indicates the mode this peer +entry is operating in. +A +.Ql \&+ +denotes symmetric active, a +.Ql \&- +indicates symmetric passive, a +.Ql \&= +means the +remote server is being polled in client mode, a +.Ql \&^ +indicates that the server is broadcasting to this address, a +.Ql \&~ +denotes that the remote peer is sending broadcasts and a +.Ql \&~ +denotes that the remote peer is sending broadcasts and a +.Ql \&* +marks the peer the server is currently synchronizing +to. +.Pp +The contents of the host field may be one of four forms. +It may +be a host name, an IP address, a reference clock implementation +name with its parameter or +.Fn REFCLK "implementation_number" "parameter" . +On +.Ic hostnames +.Cm no +only IP-addresses +will be displayed. +.It Ic dmpeers +A slightly different peer summary list. +Identical to the output +of the +.Ic peers +command, except for the character in the +leftmost column. +Characters only appear beside peers which were +included in the final stage of the clock selection algorithm. +A +.Ql \&. +indicates that this peer was cast off in the falseticker +detection, while a +.Ql \&+ +indicates that the peer made it +through. +A +.Ql \&* +denotes the peer the server is currently +synchronizing with. +.It Ic showpeer Ar peer_address Oo Ar ... Oc +Shows a detailed display of the current peer variables for one +or more peers. +Most of these values are described in the NTP +Version 2 specification. +.It Ic pstats Ar peer_address Oo Ar ... Oc +Show per-peer statistic counters associated with the specified +peer(s). +.It Ic clockstat Ar clock_peer_address Oo Ar ... Oc +Obtain and print information concerning a peer clock. +The +values obtained provide information on the setting of fudge factors +and other clock performance information. +.It Ic kerninfo +Obtain and print kernel phase-lock loop operating parameters. +This information is available only if the kernel has been specially +modified for a precision timekeeping function. +.It Ic loopinfo Op Cm oneline | Cm multiline +Print the values of selected loop filter variables. +The loop +filter is the part of NTP which deals with adjusting the local +system clock. +The +.Sq offset +is the last offset given to the +loop filter by the packet processing code. +The +.Sq frequency +is the frequency error of the local clock in parts-per-million +(ppm). +The +.Sq time_const +controls the stiffness of the +phase-lock loop and thus the speed at which it can adapt to +oscillator drift. +The +.Sq watchdog timer +value is the number +of seconds which have elapsed since the last sample offset was +given to the loop filter. +The +.Cm oneline +and +.Cm multiline +options specify the format in which this +information is to be printed, with +.Cm multiline +as the +default. +.It Ic sysinfo +Print a variety of system state variables, i.e., state related +to the local server. +All except the last four lines are described +in the NTP Version 3 specification, RFC-1305. +.Pp +The +.Sq system flags +show various system flags, some of +which can be set and cleared by the +.Ic enable +and +.Ic disable +configuration commands, respectively. +These are +the +.Cm auth , +.Cm bclient , +.Cm monitor , +.Cm pll , +.Cm pps +and +.Cm stats +flags. +See the +.Xr ntpd 1ntpdmdoc +documentation for the meaning of these flags. +There +are two additional flags which are read only, the +.Cm kernel_pll +and +.Cm kernel_pps . +These flags indicate +the synchronization status when the precision time kernel +modifications are in use. +The +.Sq kernel_pll +indicates that +the local clock is being disciplined by the kernel, while the +.Sq kernel_pps +indicates the kernel discipline is provided by the PPS +signal. +.Pp +The +.Sq stability +is the residual frequency error remaining +after the system frequency correction is applied and is intended for +maintenance and debugging. +In most architectures, this value will +initially decrease from as high as 500 ppm to a nominal value in +the range .01 to 0.1 ppm. +If it remains high for some time after +starting the daemon, something may be wrong with the local clock, +or the value of the kernel variable +.Va kern.clockrate.tick +may be +incorrect. +.Pp +The +.Sq broadcastdelay +shows the default broadcast delay, +as set by the +.Ic broadcastdelay +configuration command. +.Pp +The +.Sq authdelay +shows the default authentication delay, +as set by the +.Ic authdelay +configuration command. +.It Ic sysstats +Print statistics counters maintained in the protocol +module. +.It Ic memstats +Print statistics counters related to memory allocation +code. +.It Ic iostats +Print statistics counters maintained in the input-output +module. +.It Ic timerstats +Print statistics counters maintained in the timer/event queue +support code. +.It Ic reslist +Obtain and print the server's restriction list. +This list is +(usually) printed in sorted order and may help to understand how +the restrictions are applied. +.It Ic monlist Op Ar version +Obtain and print traffic counts collected and maintained by the +monitor facility. +The version number should not normally need to be +specified. +.It Ic clkbug Ar clock_peer_address Oo Ar ... Oc +Obtain debugging information for a reference clock driver. +This +information is provided only by some clock drivers and is mostly +undecodable without a copy of the driver source in hand. +.El +.Ss "Runtime Configuration Requests" +All requests which cause state changes in the server are +authenticated by the server using a configured NTP key (the +facility can also be disabled by the server by not configuring a +key). +The key number and the corresponding key must also be made +known to +.Nm . +This can be done using the +.Ic keyid +and +.Ic passwd +commands, the latter of which will prompt at the terminal for a +password to use as the encryption key. +You will also be prompted +automatically for both the key number and password the first time a +command which would result in an authenticated request to the +server is given. +Authentication not only provides verification that +the requester has permission to make such changes, but also gives +an extra degree of protection again transmission errors. +.Pp +Authenticated requests always include a timestamp in the packet +data, which is included in the computation of the authentication +code. +This timestamp is compared by the server to its receive time +stamp. +If they differ by more than a small amount the request is +rejected. +This is done for two reasons. +First, it makes simple +replay attacks on the server, by someone who might be able to +overhear traffic on your LAN, much more difficult. +Second, it makes +it more difficult to request configuration changes to your server +from topologically remote hosts. +While the reconfiguration facility +will work well with a server on the local host, and may work +adequately between time-synchronized hosts on the same LAN, it will +work very poorly for more distant hosts. +As such, if reasonable +passwords are chosen, care is taken in the distribution and +protection of keys and appropriate source address restrictions are +applied, the run time reconfiguration facility should provide an +adequate level of security. +.Pp +The following commands all make authenticated requests. +.Bl -tag -width indent +.It Xo Ic addpeer Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Add a configured peer association at the given address and +operating in symmetric active mode. +Note that an existing +association with the same peer may be deleted when this command is +executed, or may simply be converted to conform to the new +configuration, as appropriate. +If the optional +.Ar keyid +is a +nonzero integer, all outgoing packets to the remote server will +have an authentication field attached encrypted with this key. +If +the value is 0 (or not given) no authentication will be done. +The +.Ar version +can be 1, 2 or 3 and defaults to 3. +The +.Cm prefer +keyword indicates a preferred peer (and thus will +be used primarily for clock synchronisation if possible). +The +preferred peer also determines the validity of the PPS signal - if +the preferred peer is suitable for synchronisation so is the PPS +signal. +.It Xo Ic addserver Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Identical to the addpeer command, except that the operating +mode is client. +.It Xo Ic broadcast Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Identical to the addpeer command, except that the operating +mode is broadcast. +In this case a valid key identifier and key are +required. +The +.Ar peer_address +parameter can be the broadcast +address of the local network or a multicast group address assigned +to NTP. +If a multicast address, a multicast-capable kernel is +required. +.It Ic unconfig Ar peer_address Oo Ar ... Oc +This command causes the configured bit to be removed from the +specified peer(s). +In many cases this will cause the peer +association to be deleted. +When appropriate, however, the +association may persist in an unconfigured mode if the remote peer +is willing to continue on in this fashion. +.It Xo Ic fudge Ar peer_address +.Op Cm time1 +.Op Cm time2 +.Op Ar stratum +.Op Ar refid +.Xc +This command provides a way to set certain data for a reference +clock. +See the source listing for further information. +.It Xo Ic enable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm monitor | Cm ntp | +.Cm pps | Cm stats +.Oc +.Xc +.It Xo Ic disable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm monitor | Cm ntp | +.Cm pps | Cm stats +.Oc +.Xc +These commands operate in the same way as the +.Ic enable +and +.Ic disable +configuration file commands of +.Xr ntpd 1ntpdmdoc . +.Bl -tag -width indent +.It Cm auth +Enables the server to synchronize with unconfigured peers only +if the peer has been correctly authenticated using either public key +or private key cryptography. +The default for this flag is enable. +.It Cm bclient +Enables the server to listen for a message from a broadcast or +multicast server, as in the multicastclient command with +default address. +The default for this flag is disable. +.It Cm calibrate +Enables the calibrate feature for reference clocks. +The default for this flag is disable. +.It Cm kernel +Enables the kernel time discipline, if available. +The default for this flag is enable if support is available, otherwise disable. +.It Cm monitor +Enables the monitoring facility. +See the documentation here about the +.Cm monlist +command or further information. +The default for this flag is enable. +.It Cm ntp +Enables time and frequency discipline. +In effect, this switch opens and closes the feedback loop, +which is useful for testing. +The default for this flag is enable. +.It Cm pps +Enables the pulse-per-second (PPS) signal when frequency +and time is disciplined by the precision time kernel modifications. +See the +.Qq A Kernel Model for Precision Timekeeping +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +page for further information. +The default for this flag is disable. +.It Cm stats +Enables the statistics facility. +See the +.Sx Monitoring Options +section of +.Xr ntp.conf 5 +for further information. +The default for this flag is disable. +.El +.It Xo Ic restrict Ar address Ar mask +.Ar flag Oo Ar ... Oc +.Xc +This command operates in the same way as the +.Ic restrict +configuration file commands of +.Xr ntpd 1ntpdmdoc . +.It Xo Ic unrestrict Ar address Ar mask +.Ar flag Oo Ar ... Oc +.Xc +Unrestrict the matching entry from the restrict list. +.It Xo Ic delrestrict Ar address Ar mask +.Op Cm ntpport +.Xc +Delete the matching entry from the restrict list. +.It Ic readkeys +Causes the current set of authentication keys to be purged and +a new set to be obtained by rereading the keys file (which must +have been specified in the +.Xr ntpd 1ntpdmdoc +configuration file). +This +allows encryption keys to be changed without restarting the +server. +.It Ic trustedkey Ar keyid Oo Ar ... Oc +.It Ic untrustedkey Ar keyid Oo Ar ... Oc +These commands operate in the same way as the +.Ic trustedkey +and +.Ic untrustedkey +configuration file +commands of +.Xr ntpd 1ntpdmdoc . +.It Ic authinfo +Returns information concerning the authentication module, +including known keys and counts of encryptions and decryptions +which have been done. +.It Ic traps +Display the traps set in the server. +See the source listing for +further information. +.It Xo Ic addtrap Ar address +.Op Ar port +.Op Ar interface +.Xc +Set a trap for asynchronous messages. +See the source listing +for further information. +.It Xo Ic clrtrap Ar address +.Op Ar port +.Op Ar interface +.Xc +Clear a trap for asynchronous messages. +See the source listing +for further information. +.It Ic reset +Clear the statistics counters in various modules of the server. +See the source listing for further information. +.El + _END_MDOC_USAGE; +}; + + +doc-section = { + ds-type = 'SEE ALSO'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_SEEALSO +.Xr ntp.conf 5 , +.Xr ntpd 1ntpdmdoc +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 3) +.%O RFC1305 +.Re + _END_MDOC_SEEALSO; }; -detail = <<- _END_DETAIL - The - [= prog-name =] - utility program is used to query an NTP daemon about its - current state and to request changes in that state. - It uses NTP mode 7 control message formats described in the source code. - The program may - be run either in interactive mode or controlled using command line - arguments. - Extensive state and statistics information is available - through the - [= prog-name =] - interface. - In addition, nearly all the - configuration options which can be specified at startup using - ntpd's configuration file may also be specified at run time using - [= prog-name =] . - - - _END_DETAIL; + +doc-section = { + ds-type = 'AUTHORS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_AUTHORS +The formatting directives in this document came from FreeBSD. + _END_MDOC_AUTHORS; +}; + + +doc-section = { + ds-type = 'BUGS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_BUGS +The +.Nm +utility is a crude hack. +Much of the information it shows is +deadly boring and could only be loved by its implementer. +The +program was designed so that new (and temporary) features were easy +to hack in, at great expense to the program's ease of use. +Despite +this, the program is occasionally useful. +.Pp +Please report bugs to http://bugs.ntp.org . + _END_MDOC_BUGS; +}; diff --git a/contrib/ntp/ntpdc/ntpdc-opts.h b/contrib/ntp/ntpdc/ntpdc-opts.h index f6eef6575..d2494fef0 100644 --- a/contrib/ntp/ntpdc/ntpdc-opts.h +++ b/contrib/ntp/ntpdc/ntpdc-opts.h @@ -1,100 +1,140 @@ -/* +/* * EDIT THIS FILE WITH CAUTION (ntpdc-opts.h) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:00 AM EST + * + * It has been AutoGen-ed October 21, 2015 at 12:38:39 PM by AutoGen 5.18.5 * From the definitions ntpdc-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This header file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpdc author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. + * Generated from AutoOpts 41:0:16 templates. + * + * AutoOpts is a copyrighted work. This header file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpdc author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. * - * This source file is copyrighted and licensed under the following terms: + * The ntpdc program is copyrighted and licensed + * under the following terms: * - * ntpdc copyright 1970-2009 David L. Mills and/or others - all rights reserved + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * * - * see html/copyright.html + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. */ -/* +/** * This file contains the programmatic interface to the Automated * Options generated for the ntpdc program. * These macros are documented in the AutoGen info file in the * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_NTPDC_OPTS_H_GUARD -#define AUTOOPTS_NTPDC_OPTS_H_GUARD +#define AUTOOPTS_NTPDC_OPTS_H_GUARD 1 #include "config.h" #include -/* +/** * Ensure that the library used for compiling this generated header is at * least as new as the version current when the header template was released * (not counting patch version increments). Also ensure that the oldest * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 167936 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header Choke Me. #endif -/* - * Enumeration of each option: +/** + * Enumeration of each option type for ntpdc */ typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_COMMAND = 2, - INDEX_OPT_LISTPEERS = 3, - INDEX_OPT_PEERS = 4, - INDEX_OPT_SHOWPEERS = 5, - INDEX_OPT_INTERACTIVE = 6, - INDEX_OPT_DEBUG_LEVEL = 7, - INDEX_OPT_SET_DEBUG_LEVEL = 8, - INDEX_OPT_NUMERIC = 9, - INDEX_OPT_VERSION = 10, - INDEX_OPT_HELP = 11, - INDEX_OPT_MORE_HELP = 12, - INDEX_OPT_SAVE_OPTS = 13, - INDEX_OPT_LOAD_OPTS = 14 + INDEX_OPT_IPV4 = 0, + INDEX_OPT_IPV6 = 1, + INDEX_OPT_COMMAND = 2, + INDEX_OPT_DEBUG_LEVEL = 3, + INDEX_OPT_SET_DEBUG_LEVEL = 4, + INDEX_OPT_INTERACTIVE = 5, + INDEX_OPT_LISTPEERS = 6, + INDEX_OPT_NUMERIC = 7, + INDEX_OPT_PEERS = 8, + INDEX_OPT_SHOWPEERS = 9, + INDEX_OPT_VERSION = 10, + INDEX_OPT_HELP = 11, + INDEX_OPT_MORE_HELP = 12, + INDEX_OPT_SAVE_OPTS = 13, + INDEX_OPT_LOAD_OPTS = 14 } teOptIndex; - +/** count of all options for ntpdc */ #define OPTION_CT 15 -#define NTPDC_VERSION "4.2.4p8" -#define NTPDC_FULL_VERSION "ntpdc - vendor-specific NTP query program - Ver. 4.2.4p8" +/** ntpdc version */ +#define NTPDC_VERSION "4.2.8p4" +/** Full ntpdc version text */ +#define NTPDC_FULL_VERSION "ntpdc 4.2.8p4" -/* +/** * Interface defines for all options. Replace "n" with the UPPER_CASED * option name (as in the teOptIndex enumeration above). - * e.g. HAVE_OPT( IPV4 ) + * e.g. HAVE_OPT(IPV4) */ #define DESC(n) (ntpdcOptions.pOptDesc[INDEX_OPT_## n]) +/** 'true' if an option has been specified in any way */ #define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) +/** The string argument to an option. The argument type must be \"string\". */ #define OPT_ARG(n) (DESC(n).optArg.argString) +/** Mask the option state revealing how an option was specified. + * It will be one and only one of \a OPTST_SET, \a OPTST_PRESET, + * \a OPTST_DEFINED, \a OPTST_RESET or zero. + */ #define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) +/** Count of option's occurrances *on the command line*. */ #define COUNT_OPT(n) (DESC(n).optOccCt) +/** mask of \a OPTST_SET and \a OPTST_DEFINED. */ #define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) +/** 'true' if \a HAVE_OPT would yield 'false'. */ #define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) +/** 'true' if OPTST_DISABLED bit not set. */ #define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) +/** number of stacked option arguments. + * Valid only for stacked option arguments. */ #define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) +/** stacked argument vector. + * Valid only for stacked option arguments. */ #define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) +/** Reset an option. */ #define CLEAR_OPT(n) STMTS( \ DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ - if ( (DESC(n).fOptState & OPTST_INITENABLED) == 0) \ + if ((DESC(n).fOptState & OPTST_INITENABLED) == 0) \ DESC(n).fOptState |= OPTST_DISABLED; \ DESC(n).optCookie = NULL ) - -/* +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Enumeration of ntpdc exit codes + */ +typedef enum { + NTPDC_EXIT_SUCCESS = 0, + NTPDC_EXIT_FAILURE = 1, + NTPDC_EXIT_USAGE_ERROR = 64, + NTPDC_EXIT_NO_CONFIG_INPUT = 66, + NTPDC_EXIT_LIBOPTS_FAILURE = 70 +} ntpdc_exit_code_t; +/** @} */ +/** * Make sure there are no #define name conflicts with the option names */ #ifndef NO_OPTION_NAME_WARNINGS @@ -110,22 +150,6 @@ typedef enum { # warning undefining COMMAND due to option name conflict # undef COMMAND # endif -# ifdef LISTPEERS -# warning undefining LISTPEERS due to option name conflict -# undef LISTPEERS -# endif -# ifdef PEERS -# warning undefining PEERS due to option name conflict -# undef PEERS -# endif -# ifdef SHOWPEERS -# warning undefining SHOWPEERS due to option name conflict -# undef SHOWPEERS -# endif -# ifdef INTERACTIVE -# warning undefining INTERACTIVE due to option name conflict -# undef INTERACTIVE -# endif # ifdef DEBUG_LEVEL # warning undefining DEBUG_LEVEL due to option name conflict # undef DEBUG_LEVEL @@ -134,89 +158,137 @@ typedef enum { # warning undefining SET_DEBUG_LEVEL due to option name conflict # undef SET_DEBUG_LEVEL # endif +# ifdef INTERACTIVE +# warning undefining INTERACTIVE due to option name conflict +# undef INTERACTIVE +# endif +# ifdef LISTPEERS +# warning undefining LISTPEERS due to option name conflict +# undef LISTPEERS +# endif # ifdef NUMERIC # warning undefining NUMERIC due to option name conflict # undef NUMERIC # endif +# ifdef PEERS +# warning undefining PEERS due to option name conflict +# undef PEERS +# endif +# ifdef SHOWPEERS +# warning undefining SHOWPEERS due to option name conflict +# undef SHOWPEERS +# endif #else /* NO_OPTION_NAME_WARNINGS */ # undef IPV4 # undef IPV6 # undef COMMAND -# undef LISTPEERS -# undef PEERS -# undef SHOWPEERS -# undef INTERACTIVE # undef DEBUG_LEVEL # undef SET_DEBUG_LEVEL +# undef INTERACTIVE +# undef LISTPEERS # undef NUMERIC +# undef PEERS +# undef SHOWPEERS #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/** * Interface defines for specific options. + * @{ */ #define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) #define VALUE_OPT_IPV6 '6' #define VALUE_OPT_COMMAND 'c' -#define VALUE_OPT_LISTPEERS 'l' -#define VALUE_OPT_PEERS 'p' -#define VALUE_OPT_SHOWPEERS 's' -#define VALUE_OPT_INTERACTIVE 'i' -#ifdef DEBUG #define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG #define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ -#define VALUE_OPT_NUMERIC 'n' -#define VALUE_OPT_VERSION 'v' +#define OPT_VALUE_SET_DEBUG_LEVEL (DESC(SET_DEBUG_LEVEL).optArg.argInt) +#define VALUE_OPT_INTERACTIVE 'i' +#define VALUE_OPT_LISTPEERS 'l' +#define VALUE_OPT_NUMERIC 'n' +#define VALUE_OPT_PEERS 'p' +#define VALUE_OPT_SHOWPEERS 's' +/** option flag (value) for help-value option */ #define VALUE_OPT_HELP '?' +/** option flag (value) for more-help-value option */ #define VALUE_OPT_MORE_HELP '!' +/** option flag (value) for version-value option */ +#define VALUE_OPT_VERSION 0x1001 +/** option flag (value) for save-opts-value option */ #define VALUE_OPT_SAVE_OPTS '>' +/** option flag (value) for load-opts-value option */ #define VALUE_OPT_LOAD_OPTS '<' #define SET_OPT_SAVE_OPTS(a) STMTS( \ DESC(SAVE_OPTS).fOptState &= OPTST_PERSISTENT_MASK; \ DESC(SAVE_OPTS).fOptState |= OPTST_SET; \ - DESC(SAVE_OPTS).optArg.argString = (char const*)(a) ) + DESC(SAVE_OPTS).optArg.argString = (char const*)(a)) /* * Interface defines not associated with particular options */ -#define ERRSKIP_OPTERR STMTS( ntpdcOptions.fOptSet &= ~OPTPROC_ERRSTOP ) -#define ERRSTOP_OPTERR STMTS( ntpdcOptions.fOptSet |= OPTPROC_ERRSTOP ) +#define ERRSKIP_OPTERR STMTS(ntpdcOptions.fOptSet &= ~OPTPROC_ERRSTOP) +#define ERRSTOP_OPTERR STMTS(ntpdcOptions.fOptSet |= OPTPROC_ERRSTOP) #define RESTART_OPT(n) STMTS( \ ntpdcOptions.curOptIdx = (n); \ ntpdcOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) -#define USAGE(c) (*ntpdcOptions.pUsageProc)( &ntpdcOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +#define USAGE(c) (*ntpdcOptions.pUsageProc)(&ntpdcOptions, c) + +#ifdef __cplusplus +extern "C" { +#endif + /* * * * * * * * Declare the ntpdc option descriptor. */ -#ifdef __cplusplus -extern "C" { -#endif +extern tOptions ntpdcOptions; -extern tOptions ntpdcOptions; - -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include +# ifndef HAVE_GETTEXT + extern char * gettext(char const *); +# else +# include +# endif + +# ifndef ATTRIBUTE_FORMAT_ARG +# define ATTRIBUTE_FORMAT_ARG(_a) +# endif + +static inline char* aoGetsText(char const* pz) ATTRIBUTE_FORMAT_ARG(1); +static inline char* aoGetsText(char const* pz) { + if (pz == NULL) return NULL; + return (char*)gettext(pz); +} +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpdcOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpdcOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpdcOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpdcOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } #endif #endif /* AUTOOPTS_NTPDC_OPTS_H_GUARD */ + /* ntpdc-opts.h ends here */ diff --git a/contrib/ntp/ntpdc/ntpdc-opts.texi b/contrib/ntp/ntpdc/ntpdc-opts.texi deleted file mode 100644 index 121c270df..000000000 --- a/contrib/ntp/ntpdc/ntpdc-opts.texi +++ /dev/null @@ -1,278 +0,0 @@ -@node ntpdc Invocation -@section Invoking ntpdc -@pindex ntpdc -@cindex vendor-specific NTP query program -@ignore -# -# EDIT THIS FILE WITH CAUTION (ntpdc-opts.texi) -# -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:02 AM EST -# From the definitions ntpdc-opts.def -# and the template file aginfo.tpl -@end ignore -This program has no explanation. - -The -[= prog-name =] -utility program is used to query an NTP daemon about its -current state and to request changes in that state. -It uses NTP mode 7 control message formats described in the source code. -The program may -be run either in interactive mode or controlled using command line -arguments. -Extensive state and statistics information is available -through the -[= prog-name =] -interface. -In addition, nearly all the -configuration options which can be specified at startup using -ntpd's configuration file may also be specified at run time using -[= prog-name =] . - - - -This section was generated by @strong{AutoGen}, -the aginfo template and the option descriptions for the @command{ntpdc} program. It documents the ntpdc usage text and option meanings. - -This software is released under a specialized copyright license. - -@menu -* ntpdc usage:: ntpdc usage help (-?) -* ntpdc command:: command option (-c) -* ntpdc debug-level:: debug-level option (-d) -* ntpdc interactive:: interactive option (-i) -* ntpdc ipv4:: ipv4 option (-4) -* ntpdc ipv6:: ipv6 option (-6) -* ntpdc listpeers:: listpeers option (-l) -* ntpdc numeric:: numeric option (-n) -* ntpdc peers:: peers option (-p) -* ntpdc set-debug-level:: set-debug-level option (-D) -* ntpdc showpeers:: showpeers option (-s) -@end menu - -@node ntpdc usage -@subsection ntpdc usage help (-?) -@cindex ntpdc usage - -This is the automatically generated usage text for ntpdc: - -@exampleindent 0 -@example -ntpdc - vendor-specific NTP query program - Ver. 4.2.5p247-RC -USAGE: ntpdc [ - [] | --[@{=| @}] ]... [ host ...] - Flg Arg Option-Name Description - -4 no ipv4 Force IPv4 DNS name resolution - - prohibits these options: - ipv6 - -6 no ipv6 Force IPv6 DNS name resolution - - prohibits these options: - ipv4 - -c Str command run a command and exit - - may appear multiple times - -l no listpeers Print a list of the peers - - prohibits these options: - command - -p no peers Print a list of the peers - - prohibits these options: - command - -s no showpeers Show a list of the peers - - prohibits these options: - command - -i no interactive Force ntpq to operate in interactive mode - - prohibits these options: - command - listpeers - peers - showpeers - -d no debug-level Increase output debug message level - - may appear multiple times - -D Str set-debug-level Set the output debug message level - - may appear multiple times - -n no numeric numeric host addresses - opt version Output version information and exit - -? no help Display extended usage information and exit - -! no more-help Extended usage information passed thru pager - -> opt save-opts Save the option state to a config file - -< Str load-opts Load options from a config file - - disabled as --no-load-opts - - may appear multiple times - -Options are specified by doubled hyphens and their name -or by a single hyphen and the flag character. - -The following option preset mechanisms are supported: - - reading file /users/stenn/.ntprc - - reading file /deacon/backroom/snaps/ntp-stable/ntpdc/.ntprc - - examining environment variables named NTPDC_* - -The -[= prog-name =] -utility program is used to query an NTP daemon about its -current state and to request changes in that state. -It uses NTP mode 7 control message formats described in the source code. -The program may -be run either in interactive mode or controlled using command line -arguments. -Extensive state and statistics information is available -through the -[= prog-name =] -interface. -In addition, nearly all the -configuration options which can be specified at startup using -ntpd's configuration file may also be specified at run time using -[= prog-name =] . - -please send bug reports to: http://bugs.ntp.org, bugs@@ntp.org -@end example -@exampleindent 4 - -@node ntpdc ipv4 -@subsection ipv4 option (-4) -@cindex ntpdc-ipv4 - -This is the ``force ipv4 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv4 namespace. - -@node ntpdc ipv6 -@subsection ipv6 option (-6) -@cindex ntpdc-ipv6 - -This is the ``force ipv6 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv6 namespace. - -@node ntpdc command -@subsection command option (-c) -@cindex ntpdc-command - -This is the ``run a command and exit'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - -The following argument is interpreted as an interactive format command -and is added to the list of commands to be executed on the specified -host(s). - -@node ntpdc listpeers -@subsection listpeers option (-l) -@cindex ntpdc-listpeers - -This is the ``print a list of the peers'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -command. -@end itemize - -Print a list of the peers known to the server as well as a summary of -their state. This is equivalent to the 'listpeers' interactive command. - -@node ntpdc peers -@subsection peers option (-p) -@cindex ntpdc-peers - -This is the ``print a list of the peers'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -command. -@end itemize - -Print a list of the peers known to the server as well as a summary -of their state. This is equivalent to the 'peers' interactive command. - -@node ntpdc showpeers -@subsection showpeers option (-s) -@cindex ntpdc-showpeers - -This is the ``show a list of the peers'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -command. -@end itemize - -Print a list of the peers known to the server as well as a summary -of their state. This is equivalent to the 'dmpeers' interactive command. - -@node ntpdc interactive -@subsection interactive option (-i) -@cindex ntpdc-interactive - -This is the ``force ntpq to operate in interactive mode'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -command, listpeers, peers, showpeers. -@end itemize - -Force ntpq to operate in interactive mode. Prompts will be written -to the standard output and commands read from the standard input. - -@node ntpdc debug-level -@subsection debug-level option (-d) -@cindex ntpdc-debug-level - -This is the ``increase output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Increase the debugging message output level. - -@node ntpdc set-debug-level -@subsection set-debug-level option (-D) -@cindex ntpdc-set-debug-level - -This is the ``set the output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). - -@node ntpdc numeric -@subsection numeric option (-n) -@cindex ntpdc-numeric - -This is the ``numeric host addresses'' option. -Output all host addresses in dotted-quad numeric format rather than -converting to the canonical host names. diff --git a/contrib/ntp/ntpdc/ntpdc.1 b/contrib/ntp/ntpdc/ntpdc.1 deleted file mode 100644 index 422706518..000000000 --- a/contrib/ntp/ntpdc/ntpdc.1 +++ /dev/null @@ -1,158 +0,0 @@ -.TH NTPDC 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" -.\" EDIT THIS FILE WITH CAUTION (ntpdc.1) -.\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:01 AM EST -.\" From the definitions ntpdc-opts.def -.\" and the template file agman1.tpl -.\" -.SH NAME -ntpdc \- vendor-specific NTP query program -.SH SYNOPSIS -.B ntpdc -.\" Mixture of short (flag) options and long options -.RB [ \-\fIflag\fP " [\fIvalue\fP]]... [" \--\fIopt-name\fP " [[=| ]\fIvalue\fP]]..." -.br -.in +8 -[ host ...] -.SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpdc\fP command. -The -[= prog-name =] -utility program is used to query an NTP daemon about its -current state and to request changes in that state. -It uses NTP mode 7 control message formats described in the source code. -The program may -be run either in interactive mode or controlled using command line -arguments. -Extensive state and statistics information is available -through the -[= prog-name =] -interface. -In addition, nearly all the -configuration options which can be specified at startup using -ntpd's configuration file may also be specified at run time using -[= prog-name =] . - - -.SH OPTIONS -.TP -.BR \-4 ", " \--ipv4 -Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv4 namespace. -.TP -.BR \-6 ", " \--ipv6 -Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv6 namespace. -.TP -.BR \-c " \fIcmd\fP, " \--command "=" \fIcmd\fP -run a command and exit. -This option may appear an unlimited number of times. -.sp -The following argument is interpreted as an interactive format command -and is added to the list of commands to be executed on the specified -host(s). -.TP -.BR \-l ", " \--listpeers -Print a list of the peers. -This option must not appear in combination with any of the following options: -command. -.sp -Print a list of the peers known to the server as well as a summary of -their state. This is equivalent to the 'listpeers' interactive command. -.TP -.BR \-p ", " \--peers -Print a list of the peers. -This option must not appear in combination with any of the following options: -command. -.sp -Print a list of the peers known to the server as well as a summary -of their state. This is equivalent to the 'peers' interactive command. -.TP -.BR \-s ", " \--showpeers -Show a list of the peers. -This option must not appear in combination with any of the following options: -command. -.sp -Print a list of the peers known to the server as well as a summary -of their state. This is equivalent to the 'dmpeers' interactive command. -.TP -.BR \-i ", " \--interactive -Force ntpq to operate in interactive mode. -This option must not appear in combination with any of the following options: -command, listpeers, peers, showpeers. -.sp -Force ntpq to operate in interactive mode. Prompts will be written -to the standard output and commands read from the standard input. -.TP -.BR \-d ", " \--debug-level -Increase output debug message level. -This option may appear an unlimited number of times. -.sp -Increase the debugging message output level. -.TP -.BR \-D " \fIstring\fP, " \--set-debug-level "=" \fIstring\fP -Set the output debug message level. -This option may appear an unlimited number of times. -.sp -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). -.TP -.BR \-n ", " \--numeric -numeric host addresses. -.sp -Output all host addresses in dotted-quad numeric format rather than -converting to the canonical host names. -.TP -.BR \-? , " \--help" -Display usage information and exit. -.TP -.BR \-! , " \--more-help" -Extended usage information passed thru pager. -.TP -.BR \-> " [\fIrcfile\fP]," " \--save-opts" "[=\fIrcfile\fP]" -Save the option state to \fIrcfile\fP. The default is the \fIlast\fP -configuration file listed in the \fBOPTION PRESETS\fP section, below. -.TP -.BR \-< " \fIrcfile\fP," " \--load-opts" "=\fIrcfile\fP," " \--no-load-opts" -Load options from \fIrcfile\fP. -The \fIno-load-opts\fP form will disable the loading -of earlier RC/INI files. \fI--no-load-opts\fP is handled early, -out of order. -.TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" -Output version of program and exit. The default mode is `v', a simple -version. The `c' mode will print copyright information and `n' will -print the full copyright notice. -.SH OPTION PRESETS -Any option that is not marked as \fInot presettable\fP may be preset -by loading values from configuration ("RC" or ".INI") file(s) and values from -environment variables named: -.nf - \fBNTPDC_\fP or \fBNTPDC\fP -.fi -.aj -The environmental presets take precedence (are processed later than) -the configuration files. -The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". -If any of these are directories, then the file \fI.ntprc\fP -is searched for within those directories. -.SH AUTHOR -David L. Mills and/or others -.br -Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org - -.PP -.nf -.na -see html/copyright.html -.fi -.ad -.PP -This manual page was \fIAutoGen\fP-erated from the \fBntpdc\fP -option definitions. diff --git a/contrib/ntp/ntpdc/ntpdc.1ntpdcman b/contrib/ntp/ntpdc/ntpdc.1ntpdcman new file mode 100644 index 000000000..71fd5452d --- /dev/null +++ b/contrib/ntp/ntpdc/ntpdc.1ntpdcman @@ -0,0 +1,874 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpdc 1ntpdcman "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-Gvay7L/ag-Svaq6L) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:51 PM by AutoGen 5.18.5 +.\" From the definitions ntpdc-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpdc\fP +\- vendor-specific NTPD control program +.SH SYNOPSIS +\f\*[B-Font]ntpdc\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[ host ...] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntpdc\fP +is deprecated. +Please use +\fCntpq\f[]\fR(1ntpqmdoc)\f[] instead \- it can do everything +\f\*[B-Font]ntpdc\fP +used to do, and it does so using a much more sane interface. +.sp \n(Ppu +.ne 2 + +\f\*[B-Font]ntpdc\fP +is a utility program used to query +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +about its +current state and to request changes in that state. +It uses NTP mode 7 control message formats described in the source code. +The program may +be run either in interactive mode or controlled using command line +arguments. +Extensive state and statistics information is available +through the +\f\*[B-Font]ntpdc\fP +interface. +In addition, nearly all the +configuration options which can be specified at startup using +ntpd's configuration file may also be specified at run time using +\f\*[B-Font]ntpdc\fP. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.TP +.NOP \f\*[B-Font]\-6\f[], \f\*[B-Font]\-\-ipv6\f[] +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.TP +.NOP \f\*[B-Font]\-c\f[] \f\*[I-Font]cmd\f[], \f\*[B-Font]\-\-command\f[]=\f\*[I-Font]cmd\f[] +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.TP +.NOP \f\*[B-Font]\-d\f[], \f\*[B-Font]\-\-debug\-level\f[] +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-D\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-set\-debug\-level\f[]=\f\*[I-Font]number\f[] +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.TP +.NOP \f\*[B-Font]\-i\f[], \f\*[B-Font]\-\-interactive\f[] +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, listpeers, peers, showpeers. +.sp +Force ntpq to operate in interactive mode. Prompts will be written +to the standard output and commands read from the standard input. +.TP +.NOP \f\*[B-Font]\-l\f[], \f\*[B-Font]\-\-listpeers\f[] +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary of +their state. This is equivalent to the 'listpeers' interactive command. +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-numeric\f[] +numeric host addresses. +.sp +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-peers\f[] +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.TP +.NOP \f\*[B-Font]\-s\f[], \f\*[B-Font]\-\-showpeers\f[] +Show a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'dmpeers' interactive command. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\->\f[] [\f\*[I-Font]cfgfile\f[]], \f\*[B-Font]\-\-save-opts\f[] [=\f\*[I-Font]cfgfile\f[]] +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.TP +.NOP \f\*[B-Font]\-<\f[] \f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-load-opts\f[]=\f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-no-load-opts\f[] +Load options from \fIcfgfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early, +out of order. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPDC_\fP or \fBNTPDC\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.SH USAGE +If one or more request options are included on the command line +when +\f\*[B-Font]ntpdc\fP +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +\f\*[B-Font]ntpdc\fP +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +\f\*[B-Font]ntpdc\fP +utility will prompt for +commands if the standard input is a terminal device. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]ntpdc\fP +utility uses NTP mode 7 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +\f\*[B-Font]ntpdc\fP +utility makes +no attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +.sp \n(Ppu +.ne 2 + +The operation of +\f\*[B-Font]ntpdc\fP +are specific to the particular +implementation of the +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +daemon and can be expected to +work only with this and maybe some previous versions of the daemon. +Requests from a remote +\f\*[B-Font]ntpdc\fP +utility which affect the +state of the local server must be authenticated, which requires +both the remote program and local server share a common key and key +identifier. +.sp \n(Ppu +.ne 2 + +Note that in contexts where a host name is expected, a +\f\*[B-Font]\-4\f[] +qualifier preceding the host name forces DNS resolution to the IPv4 namespace, +while a +\f\*[B-Font]\-6\f[] +qualifier forces DNS resolution to the IPv6 namespace. +Specifying a command line option other than +\f\*[B-Font]\-i\f[] +or +\f\*[B-Font]\-n\f[] +will cause the specified query (queries) to be sent to +the indicated host(s) immediately. +Otherwise, +\f\*[B-Font]ntpdc\fP +will +attempt to read interactive format commands from the standard +input. +.SS "Interactive Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +The output of a +command is normally sent to the standard output, but optionally the +output of individual commands may be sent to a file by appending a +\[oq]\&>\[cq], +followed by a file name, to the command line. +.sp \n(Ppu +.ne 2 + +A number of interactive format commands are executed entirely +within the +\f\*[B-Font]ntpdc\fP +utility itself and do not result in NTP +mode 7 requests being sent to a server. +These are described +following. +.TP 7 +.NOP \f\*[B-Font]\&?\f[] \f\*[I-Font]command_keyword\f[] +.TP 7 +.NOP \f\*[B-Font]help\f[] \f\*[I-Font]command_keyword\f[] +A +\[oq]\f\*[B-Font]\&?\f[]\[cq] +will print a list of all the command +keywords known to this incarnation of +\f\*[B-Font]ntpdc\fP. +A +\[oq]\f\*[B-Font]\&?\f[]\[cq] +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +\fCntpq\f[]\fR(1ntpqmdoc)\f[] +than this manual +page. +.TP 7 +.NOP \f\*[B-Font]delay\f[] \f\*[I-Font]milliseconds\f[] +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.TP 7 +.NOP \f\*[B-Font]host\f[] \f\*[I-Font]hostname\f[] +Set the host to which future queries will be sent. +Hostname may +be either a host name or a numeric address. +.TP 7 +.NOP \f\*[B-Font]hostnames\f[] [\f\*[B-Font]yes\f[] | \f\*[B-Font]no\f[]] +If +\f\*[B-Font]yes\f[] +is specified, host names are printed in +information displays. +If +\f\*[B-Font]no\f[] +is specified, numeric +addresses are printed instead. +The default is +\f\*[B-Font]yes\f[], +unless +modified using the command line +\f\*[B-Font]\-n\f[] +switch. +.TP 7 +.NOP \f\*[B-Font]keyid\f[] \f\*[I-Font]keyid\f[] +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to a key number the server has been configured to use for this +purpose. +.TP 7 +.NOP \f\*[B-Font]quit\f[] +Exit +\f\*[B-Font]ntpdc\fP. +.TP 7 +.NOP \f\*[B-Font]passwd\f[] +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.TP 7 +.NOP \f\*[B-Font]timeout\f[] \f\*[I-Font]milliseconds\f[] +Specify a timeout period for responses to server queries. +The +default is about 8000 milliseconds. +Note that since +\f\*[B-Font]ntpdc\fP +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.PP +.SS "Control Message Commands" +Query commands result in NTP mode 7 packets containing requests for +information being sent to the server. +These are read-only commands +in that they make no modification of the server configuration +state. +.TP 7 +.NOP \f\*[B-Font]listpeers\f[] +Obtains and prints a brief list of the peers for which the +server is maintaining state. +These should include all configured +peer associations as well as those peers whose stratum is such that +they are considered by the server to be possible future +synchronization candidates. +.TP 7 +.NOP \f\*[B-Font]peers\f[] +Obtains a list of peers for which the server is maintaining +state, along with a summary of that state. +Summary information +includes the address of the remote peer, the local interface +address (0.0.0.0 if a local address has yet to be determined), the +stratum of the remote peer (a stratum of 16 indicates the remote +peer is unsynchronized), the polling interval, in seconds, the +reachability register, in octal, and the current estimated delay, +offset and dispersion of the peer, all in seconds. +.sp \n(Ppu +.ne 2 + +The character in the left margin indicates the mode this peer +entry is operating in. +A +\[oq]\&+\[cq] +denotes symmetric active, a +\[oq]\&-\[cq] +indicates symmetric passive, a +\[oq]\&=\[cq] +means the +remote server is being polled in client mode, a +\[oq]\&^\[cq] +indicates that the server is broadcasting to this address, a +\[oq]\&~\[cq] +denotes that the remote peer is sending broadcasts and a +\[oq]\&~\[cq] +denotes that the remote peer is sending broadcasts and a +\[oq]\&*\[cq] +marks the peer the server is currently synchronizing +to. +.sp \n(Ppu +.ne 2 + +The contents of the host field may be one of four forms. +It may +be a host name, an IP address, a reference clock implementation +name with its parameter or +\fBREFCLK\f[]\fR()\f[] +On +\f\*[B-Font]hostnames\f[] +\f\*[B-Font]no\f[] +only IP-addresses +will be displayed. +.TP 7 +.NOP \f\*[B-Font]dmpeers\f[] +A slightly different peer summary list. +Identical to the output +of the +\f\*[B-Font]peers\f[] +command, except for the character in the +leftmost column. +Characters only appear beside peers which were +included in the final stage of the clock selection algorithm. +A +\[oq]\&.\[cq] +indicates that this peer was cast off in the falseticker +detection, while a +\[oq]\&+\[cq] +indicates that the peer made it +through. +A +\[oq]\&*\[cq] +denotes the peer the server is currently +synchronizing with. +.TP 7 +.NOP \f\*[B-Font]showpeer\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]...\f[]] +Shows a detailed display of the current peer variables for one +or more peers. +Most of these values are described in the NTP +Version 2 specification. +.TP 7 +.NOP \f\*[B-Font]pstats\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]...\f[]] +Show per-peer statistic counters associated with the specified +peer(s). +.TP 7 +.NOP \f\*[B-Font]clockstat\f[] \f\*[I-Font]clock_peer_address\f[] [\f\*[I-Font]...\f[]] +Obtain and print information concerning a peer clock. +The +values obtained provide information on the setting of fudge factors +and other clock performance information. +.TP 7 +.NOP \f\*[B-Font]kerninfo\f[] +Obtain and print kernel phase-lock loop operating parameters. +This information is available only if the kernel has been specially +modified for a precision timekeeping function. +.TP 7 +.NOP \f\*[B-Font]loopinfo\f[] [\f\*[B-Font]oneline\f[] | \f\*[B-Font]multiline\f[]] +Print the values of selected loop filter variables. +The loop +filter is the part of NTP which deals with adjusting the local +system clock. +The +\[oq]offset\[cq] +is the last offset given to the +loop filter by the packet processing code. +The +\[oq]frequency\[cq] +is the frequency error of the local clock in parts-per-million +(ppm). +The +\[oq]time_const\[cq] +controls the stiffness of the +phase-lock loop and thus the speed at which it can adapt to +oscillator drift. +The +\[oq]watchdog timer\[cq] +value is the number +of seconds which have elapsed since the last sample offset was +given to the loop filter. +The +\f\*[B-Font]oneline\f[] +and +\f\*[B-Font]multiline\f[] +options specify the format in which this +information is to be printed, with +\f\*[B-Font]multiline\f[] +as the +default. +.TP 7 +.NOP \f\*[B-Font]sysinfo\f[] +Print a variety of system state variables, i.e., state related +to the local server. +All except the last four lines are described +in the NTP Version 3 specification, RFC-1305. +.sp \n(Ppu +.ne 2 + +The +\[oq]system flags\[cq] +show various system flags, some of +which can be set and cleared by the +\f\*[B-Font]enable\f[] +and +\f\*[B-Font]disable\f[] +configuration commands, respectively. +These are +the +\f\*[B-Font]auth\f[], +\f\*[B-Font]bclient\f[], +\f\*[B-Font]monitor\f[], +\f\*[B-Font]pll\f[], +\f\*[B-Font]pps\f[] +and +\f\*[B-Font]stats\f[] +flags. +See the +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +documentation for the meaning of these flags. +There +are two additional flags which are read only, the +\f\*[B-Font]kernel_pll\f[] +and +\f\*[B-Font]kernel_pps\f[]. +These flags indicate +the synchronization status when the precision time kernel +modifications are in use. +The +\[oq]kernel_pll\[cq] +indicates that +the local clock is being disciplined by the kernel, while the +\[oq]kernel_pps\[cq] +indicates the kernel discipline is provided by the PPS +signal. +.sp \n(Ppu +.ne 2 + +The +\[oq]stability\[cq] +is the residual frequency error remaining +after the system frequency correction is applied and is intended for +maintenance and debugging. +In most architectures, this value will +initially decrease from as high as 500 ppm to a nominal value in +the range .01 to 0.1 ppm. +If it remains high for some time after +starting the daemon, something may be wrong with the local clock, +or the value of the kernel variable +\fIkern.clockrate.tick\f[] +may be +incorrect. +.sp \n(Ppu +.ne 2 + +The +\[oq]broadcastdelay\[cq] +shows the default broadcast delay, +as set by the +\f\*[B-Font]broadcastdelay\f[] +configuration command. +.sp \n(Ppu +.ne 2 + +The +\[oq]authdelay\[cq] +shows the default authentication delay, +as set by the +\f\*[B-Font]authdelay\f[] +configuration command. +.TP 7 +.NOP \f\*[B-Font]sysstats\f[] +Print statistics counters maintained in the protocol +module. +.TP 7 +.NOP \f\*[B-Font]memstats\f[] +Print statistics counters related to memory allocation +code. +.TP 7 +.NOP \f\*[B-Font]iostats\f[] +Print statistics counters maintained in the input-output +module. +.TP 7 +.NOP \f\*[B-Font]timerstats\f[] +Print statistics counters maintained in the timer/event queue +support code. +.TP 7 +.NOP \f\*[B-Font]reslist\f[] +Obtain and print the server's restriction list. +This list is +(usually) printed in sorted order and may help to understand how +the restrictions are applied. +.TP 7 +.NOP \f\*[B-Font]monlist\f[] [\f\*[I-Font]version\f[]] +Obtain and print traffic counts collected and maintained by the +monitor facility. +The version number should not normally need to be +specified. +.TP 7 +.NOP \f\*[B-Font]clkbug\f[] \f\*[I-Font]clock_peer_address\f[] [\f\*[I-Font]...\f[]] +Obtain debugging information for a reference clock driver. +This +information is provided only by some clock drivers and is mostly +undecodable without a copy of the driver source in hand. +.PP +.SS "Runtime Configuration Requests" +All requests which cause state changes in the server are +authenticated by the server using a configured NTP key (the +facility can also be disabled by the server by not configuring a +key). +The key number and the corresponding key must also be made +known to +\f\*[B-Font]ntpdc\fP. +This can be done using the +\f\*[B-Font]keyid\f[] +and +\f\*[B-Font]passwd\f[] +commands, the latter of which will prompt at the terminal for a +password to use as the encryption key. +You will also be prompted +automatically for both the key number and password the first time a +command which would result in an authenticated request to the +server is given. +Authentication not only provides verification that +the requester has permission to make such changes, but also gives +an extra degree of protection again transmission errors. +.sp \n(Ppu +.ne 2 + +Authenticated requests always include a timestamp in the packet +data, which is included in the computation of the authentication +code. +This timestamp is compared by the server to its receive time +stamp. +If they differ by more than a small amount the request is +rejected. +This is done for two reasons. +First, it makes simple +replay attacks on the server, by someone who might be able to +overhear traffic on your LAN, much more difficult. +Second, it makes +it more difficult to request configuration changes to your server +from topologically remote hosts. +While the reconfiguration facility +will work well with a server on the local host, and may work +adequately between time-synchronized hosts on the same LAN, it will +work very poorly for more distant hosts. +As such, if reasonable +passwords are chosen, care is taken in the distribution and +protection of keys and appropriate source address restrictions are +applied, the run time reconfiguration facility should provide an +adequate level of security. +.sp \n(Ppu +.ne 2 + +The following commands all make authenticated requests. +.TP 7 +.NOP \f\*[B-Font]addpeer\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]keyid\f[]] [\f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] +Add a configured peer association at the given address and +operating in symmetric active mode. +Note that an existing +association with the same peer may be deleted when this command is +executed, or may simply be converted to conform to the new +configuration, as appropriate. +If the optional +\f\*[I-Font]keyid\f[] +is a +nonzero integer, all outgoing packets to the remote server will +have an authentication field attached encrypted with this key. +If +the value is 0 (or not given) no authentication will be done. +The +\f\*[I-Font]version\f[] +can be 1, 2 or 3 and defaults to 3. +The +\f\*[B-Font]prefer\f[] +keyword indicates a preferred peer (and thus will +be used primarily for clock synchronisation if possible). +The +preferred peer also determines the validity of the PPS signal \- if +the preferred peer is suitable for synchronisation so is the PPS +signal. +.TP 7 +.NOP \f\*[B-Font]addserver\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]keyid\f[]] [\f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] +Identical to the addpeer command, except that the operating +mode is client. +.TP 7 +.NOP \f\*[B-Font]broadcast\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]keyid\f[]] [\f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] +Identical to the addpeer command, except that the operating +mode is broadcast. +In this case a valid key identifier and key are +required. +The +\f\*[I-Font]peer_address\f[] +parameter can be the broadcast +address of the local network or a multicast group address assigned +to NTP. +If a multicast address, a multicast-capable kernel is +required. +.TP 7 +.NOP \f\*[B-Font]unconfig\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]...\f[]] +This command causes the configured bit to be removed from the +specified peer(s). +In many cases this will cause the peer +association to be deleted. +When appropriate, however, the +association may persist in an unconfigured mode if the remote peer +is willing to continue on in this fashion. +.TP 7 +.NOP \f\*[B-Font]fudge\f[] \f\*[I-Font]peer_address\f[] [\f\*[B-Font]time1\f[]] [\f\*[B-Font]time2\f[]] [\f\*[I-Font]stratum\f[]] [\f\*[I-Font]refid\f[]] +This command provides a way to set certain data for a reference +clock. +See the source listing for further information. +.TP 7 +.NOP \f\*[B-Font]enable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]pps\f[] | \f\*[B-Font]stats\f[]] +.TP 7 +.NOP \f\*[B-Font]disable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]pps\f[] | \f\*[B-Font]stats\f[]] +These commands operate in the same way as the +\f\*[B-Font]enable\f[] +and +\f\*[B-Font]disable\f[] +configuration file commands of +\fCntpd\f[]\fR(1ntpdmdoc)\f[]. +.RS +.TP 7 +.NOP \f\*[B-Font]auth\f[] +Enables the server to synchronize with unconfigured peers only +if the peer has been correctly authenticated using either public key +or private key cryptography. +The default for this flag is enable. +.TP 7 +.NOP \f\*[B-Font]bclient\f[] +Enables the server to listen for a message from a broadcast or +multicast server, as in the multicastclient command with +default address. +The default for this flag is disable. +.TP 7 +.NOP \f\*[B-Font]calibrate\f[] +Enables the calibrate feature for reference clocks. +The default for this flag is disable. +.TP 7 +.NOP \f\*[B-Font]kernel\f[] +Enables the kernel time discipline, if available. +The default for this flag is enable if support is available, otherwise disable. +.TP 7 +.NOP \f\*[B-Font]monitor\f[] +Enables the monitoring facility. +See the documentation here about the +\f\*[B-Font]monlist\f[] +command or further information. +The default for this flag is enable. +.TP 7 +.NOP \f\*[B-Font]ntp\f[] +Enables time and frequency discipline. +In effect, this switch opens and closes the feedback loop, +which is useful for testing. +The default for this flag is enable. +.TP 7 +.NOP \f\*[B-Font]pps\f[] +Enables the pulse-per-second (PPS) signal when frequency +and time is disciplined by the precision time kernel modifications. +See the +"A Kernel Model for Precision Timekeeping" +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +page for further information. +The default for this flag is disable. +.TP 7 +.NOP \f\*[B-Font]stats\f[] +Enables the statistics facility. +See the +\fIMonitoring\f[] \fIOptions\f[] +section of +\fCntp.conf\f[]\fR(5)\f[] +for further information. +The default for this flag is disable. +.RE +.TP 7 +.NOP \f\*[B-Font]restrict\f[] \f\*[I-Font]address\f[] \f\*[I-Font]mask\f[] \f\*[I-Font]flag\f[] [\f\*[I-Font]...\f[]] +This command operates in the same way as the +\f\*[B-Font]restrict\f[] +configuration file commands of +\fCntpd\f[]\fR(1ntpdmdoc)\f[]. +.TP 7 +.NOP \f\*[B-Font]unrestrict\f[] \f\*[I-Font]address\f[] \f\*[I-Font]mask\f[] \f\*[I-Font]flag\f[] [\f\*[I-Font]...\f[]] +Unrestrict the matching entry from the restrict list. +.TP 7 +.NOP \f\*[B-Font]delrestrict\f[] \f\*[I-Font]address\f[] \f\*[I-Font]mask\f[] [\f\*[B-Font]ntpport\f[]] +Delete the matching entry from the restrict list. +.TP 7 +.NOP \f\*[B-Font]readkeys\f[] +Causes the current set of authentication keys to be purged and +a new set to be obtained by rereading the keys file (which must +have been specified in the +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +configuration file). +This +allows encryption keys to be changed without restarting the +server. +.TP 7 +.NOP \f\*[B-Font]trustedkey\f[] \f\*[I-Font]keyid\f[] [\f\*[I-Font]...\f[]] +.TP 7 +.NOP \f\*[B-Font]untrustedkey\f[] \f\*[I-Font]keyid\f[] [\f\*[I-Font]...\f[]] +These commands operate in the same way as the +\f\*[B-Font]trustedkey\f[] +and +\f\*[B-Font]untrustedkey\f[] +configuration file +commands of +\fCntpd\f[]\fR(1ntpdmdoc)\f[]. +.TP 7 +.NOP \f\*[B-Font]authinfo\f[] +Returns information concerning the authentication module, +including known keys and counts of encryptions and decryptions +which have been done. +.TP 7 +.NOP \f\*[B-Font]traps\f[] +Display the traps set in the server. +See the source listing for +further information. +.TP 7 +.NOP \f\*[B-Font]addtrap\f[] \f\*[I-Font]address\f[] [\f\*[I-Font]port\f[]] [\f\*[I-Font]interface\f[]] +Set a trap for asynchronous messages. +See the source listing +for further information. +.TP 7 +.NOP \f\*[B-Font]clrtrap\f[] \f\*[I-Font]address\f[] [\f\*[I-Font]port\f[]] [\f\*[I-Font]interface\f[]] +Clear a trap for asynchronous messages. +See the source listing +for further information. +.TP 7 +.NOP \f\*[B-Font]reset\f[] +Clear the statistics counters in various modules of the server. +See the source listing for further information. +.PP +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "SEE ALSO" +\fCntp.conf\f[]\fR(5)\f[], +\fCntpd\f[]\fR(1ntpdmdoc)\f[] +David L. Mills, +\fINetwork Time Protocol (Version 3)\fR, +RFC1305 +.PP + +.SH AUTHORS +The formatting directives in this document came from FreeBSD. +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH BUGS +The +\f\*[B-Font]ntpdc\fP +utility is a crude hack. +Much of the information it shows is +deadly boring and could only be loved by its implementer. +The +program was designed so that new (and temporary) features were easy +to hack in, at great expense to the program's ease of use. +Despite +this, the program is occasionally useful. +.sp \n(Ppu +.ne 2 + +Please report bugs to http://bugs.ntp.org . +.sp \n(Ppu +.ne 2 + +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntpdc\fP +option definitions. diff --git a/contrib/ntp/ntpdc/ntpdc.1ntpdcmdoc b/contrib/ntp/ntpdc/ntpdc.1ntpdcmdoc new file mode 100644 index 000000000..ff7656c9f --- /dev/null +++ b/contrib/ntp/ntpdc/ntpdc.1ntpdcmdoc @@ -0,0 +1,809 @@ +.Dd October 21 2015 +.Dt NTPDC 1ntpdcmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpdc-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:57 PM by AutoGen 5.18.5 +.\" From the definitions ntpdc-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpdc +.Nd vendor-specific NTPD control program +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[ host ...] +.Pp +.Sh DESCRIPTION +.Nm +is deprecated. +Please use +.Xr ntpq 1ntpqmdoc instead \- it can do everything +.Nm +used to do, and it does so using a much more sane interface. +.Pp +.Nm +is a utility program used to query +.Xr ntpd 1ntpdmdoc +about its +current state and to request changes in that state. +It uses NTP mode 7 control message formats described in the source code. +The program may +be run either in interactive mode or controlled using command line +arguments. +Extensive state and statistics information is available +through the +.Nm +interface. +In addition, nearly all the +configuration options which can be specified at startup using +ntpd's configuration file may also be specified at run time using +.Nm . +.Sh "OPTIONS" +.Bl -tag +.It Fl 4 , Fl \-ipv4 +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.It Fl 6 , Fl \-ipv6 +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.It Fl c Ar cmd , Fl \-command Ns = Ns Ar cmd +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.It Fl d , Fl \-debug\-level +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.It Fl D Ar number , Fl \-set\-debug\-level Ns = Ns Ar number +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.It Fl i , Fl \-interactive +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, listpeers, peers, showpeers. +.sp +Force ntpq to operate in interactive mode. Prompts will be written +to the standard output and commands read from the standard input. +.It Fl l , Fl \-listpeers +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary of +their state. This is equivalent to the 'listpeers' interactive command. +.It Fl n , Fl \-numeric +numeric host addresses. +.sp +Output all host addresses in dotted\-quad numeric format rather than +converting to the canonical host names. +.It Fl p , Fl \-peers +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.It Fl s , Fl \-showpeers +Show a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'dmpeers' interactive command. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl > Oo Ar cfgfile Oc , Fl \-save\-opts Oo Ns = Ns Ar cfgfile Oc +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.It Fl < Ar cfgfile , Fl \-load\-opts Ns = Ns Ar cfgfile , Fl \-no\-load\-opts +Load options from \fIcfgfile\fP. +The \fIno\-load\-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no\-load\-opts\fP is handled early, +out of order. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPDC_\fP or \fBNTPDC\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.Sh USAGE +If one or more request options are included on the command line +when +.Nm +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +.Nm +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +.Nm +utility will prompt for +commands if the standard input is a terminal device. +.Pp +The +.Nm +utility uses NTP mode 7 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +.Nm +utility makes +no attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +.Pp +The operation of +.Nm +are specific to the particular +implementation of the +.Xr ntpd 1ntpdmdoc +daemon and can be expected to +work only with this and maybe some previous versions of the daemon. +Requests from a remote +.Nm +utility which affect the +state of the local server must be authenticated, which requires +both the remote program and local server share a common key and key +identifier. +.Pp +Note that in contexts where a host name is expected, a +.Fl 4 +qualifier preceding the host name forces DNS resolution to the IPv4 namespace, +while a +.Fl 6 +qualifier forces DNS resolution to the IPv6 namespace. +Specifying a command line option other than +.Fl i +or +.Fl n +will cause the specified query (queries) to be sent to +the indicated host(s) immediately. +Otherwise, +.Nm +will +attempt to read interactive format commands from the standard +input. +.Ss "Interactive Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +The output of a +command is normally sent to the standard output, but optionally the +output of individual commands may be sent to a file by appending a +.Ql \&> , +followed by a file name, to the command line. +.Pp +A number of interactive format commands are executed entirely +within the +.Nm +utility itself and do not result in NTP +mode 7 requests being sent to a server. +These are described +following. +.Bl -tag -width indent +.It Ic \&? Ar command_keyword +.It Ic help Ar command_keyword +A +.Sq Ic \&? +will print a list of all the command +keywords known to this incarnation of +.Nm . +A +.Sq Ic \&? +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +.Xr ntpq 1ntpqmdoc +than this manual +page. +.It Ic delay Ar milliseconds +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.It Ic host Ar hostname +Set the host to which future queries will be sent. +Hostname may +be either a host name or a numeric address. +.It Ic hostnames Op Cm yes | Cm no +If +.Cm yes +is specified, host names are printed in +information displays. +If +.Cm no +is specified, numeric +addresses are printed instead. +The default is +.Cm yes , +unless +modified using the command line +.Fl n +switch. +.It Ic keyid Ar keyid +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to a key number the server has been configured to use for this +purpose. +.It Ic quit +Exit +.Nm . +.It Ic passwd +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.It Ic timeout Ar milliseconds +Specify a timeout period for responses to server queries. +The +default is about 8000 milliseconds. +Note that since +.Nm +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.El +.Ss "Control Message Commands" +Query commands result in NTP mode 7 packets containing requests for +information being sent to the server. +These are read\-only commands +in that they make no modification of the server configuration +state. +.Bl -tag -width indent +.It Ic listpeers +Obtains and prints a brief list of the peers for which the +server is maintaining state. +These should include all configured +peer associations as well as those peers whose stratum is such that +they are considered by the server to be possible future +synchronization candidates. +.It Ic peers +Obtains a list of peers for which the server is maintaining +state, along with a summary of that state. +Summary information +includes the address of the remote peer, the local interface +address (0.0.0.0 if a local address has yet to be determined), the +stratum of the remote peer (a stratum of 16 indicates the remote +peer is unsynchronized), the polling interval, in seconds, the +reachability register, in octal, and the current estimated delay, +offset and dispersion of the peer, all in seconds. +.Pp +The character in the left margin indicates the mode this peer +entry is operating in. +A +.Ql \&+ +denotes symmetric active, a +.Ql \&\- +indicates symmetric passive, a +.Ql \&= +means the +remote server is being polled in client mode, a +.Ql \&^ +indicates that the server is broadcasting to this address, a +.Ql \&~ +denotes that the remote peer is sending broadcasts and a +.Ql \&~ +denotes that the remote peer is sending broadcasts and a +.Ql \&* +marks the peer the server is currently synchronizing +to. +.Pp +The contents of the host field may be one of four forms. +It may +be a host name, an IP address, a reference clock implementation +name with its parameter or +.Fn REFCLK "implementation_number" "parameter" . +On +.Ic hostnames +.Cm no +only IP\-addresses +will be displayed. +.It Ic dmpeers +A slightly different peer summary list. +Identical to the output +of the +.Ic peers +command, except for the character in the +leftmost column. +Characters only appear beside peers which were +included in the final stage of the clock selection algorithm. +A +.Ql \&. +indicates that this peer was cast off in the falseticker +detection, while a +.Ql \&+ +indicates that the peer made it +through. +A +.Ql \&* +denotes the peer the server is currently +synchronizing with. +.It Ic showpeer Ar peer_address Oo Ar ... Oc +Shows a detailed display of the current peer variables for one +or more peers. +Most of these values are described in the NTP +Version 2 specification. +.It Ic pstats Ar peer_address Oo Ar ... Oc +Show per\-peer statistic counters associated with the specified +peer(s). +.It Ic clockstat Ar clock_peer_address Oo Ar ... Oc +Obtain and print information concerning a peer clock. +The +values obtained provide information on the setting of fudge factors +and other clock performance information. +.It Ic kerninfo +Obtain and print kernel phase\-lock loop operating parameters. +This information is available only if the kernel has been specially +modified for a precision timekeeping function. +.It Ic loopinfo Op Cm oneline | Cm multiline +Print the values of selected loop filter variables. +The loop +filter is the part of NTP which deals with adjusting the local +system clock. +The +.Sq offset +is the last offset given to the +loop filter by the packet processing code. +The +.Sq frequency +is the frequency error of the local clock in parts\-per\-million +(ppm). +The +.Sq time_const +controls the stiffness of the +phase\-lock loop and thus the speed at which it can adapt to +oscillator drift. +The +.Sq watchdog timer +value is the number +of seconds which have elapsed since the last sample offset was +given to the loop filter. +The +.Cm oneline +and +.Cm multiline +options specify the format in which this +information is to be printed, with +.Cm multiline +as the +default. +.It Ic sysinfo +Print a variety of system state variables, i.e., state related +to the local server. +All except the last four lines are described +in the NTP Version 3 specification, RFC\-1305. +.Pp +The +.Sq system flags +show various system flags, some of +which can be set and cleared by the +.Ic enable +and +.Ic disable +configuration commands, respectively. +These are +the +.Cm auth , +.Cm bclient , +.Cm monitor , +.Cm pll , +.Cm pps +and +.Cm stats +flags. +See the +.Xr ntpd 1ntpdmdoc +documentation for the meaning of these flags. +There +are two additional flags which are read only, the +.Cm kernel_pll +and +.Cm kernel_pps . +These flags indicate +the synchronization status when the precision time kernel +modifications are in use. +The +.Sq kernel_pll +indicates that +the local clock is being disciplined by the kernel, while the +.Sq kernel_pps +indicates the kernel discipline is provided by the PPS +signal. +.Pp +The +.Sq stability +is the residual frequency error remaining +after the system frequency correction is applied and is intended for +maintenance and debugging. +In most architectures, this value will +initially decrease from as high as 500 ppm to a nominal value in +the range .01 to 0.1 ppm. +If it remains high for some time after +starting the daemon, something may be wrong with the local clock, +or the value of the kernel variable +.Va kern.clockrate.tick +may be +incorrect. +.Pp +The +.Sq broadcastdelay +shows the default broadcast delay, +as set by the +.Ic broadcastdelay +configuration command. +.Pp +The +.Sq authdelay +shows the default authentication delay, +as set by the +.Ic authdelay +configuration command. +.It Ic sysstats +Print statistics counters maintained in the protocol +module. +.It Ic memstats +Print statistics counters related to memory allocation +code. +.It Ic iostats +Print statistics counters maintained in the input\-output +module. +.It Ic timerstats +Print statistics counters maintained in the timer/event queue +support code. +.It Ic reslist +Obtain and print the server's restriction list. +This list is +(usually) printed in sorted order and may help to understand how +the restrictions are applied. +.It Ic monlist Op Ar version +Obtain and print traffic counts collected and maintained by the +monitor facility. +The version number should not normally need to be +specified. +.It Ic clkbug Ar clock_peer_address Oo Ar ... Oc +Obtain debugging information for a reference clock driver. +This +information is provided only by some clock drivers and is mostly +undecodable without a copy of the driver source in hand. +.El +.Ss "Runtime Configuration Requests" +All requests which cause state changes in the server are +authenticated by the server using a configured NTP key (the +facility can also be disabled by the server by not configuring a +key). +The key number and the corresponding key must also be made +known to +.Nm . +This can be done using the +.Ic keyid +and +.Ic passwd +commands, the latter of which will prompt at the terminal for a +password to use as the encryption key. +You will also be prompted +automatically for both the key number and password the first time a +command which would result in an authenticated request to the +server is given. +Authentication not only provides verification that +the requester has permission to make such changes, but also gives +an extra degree of protection again transmission errors. +.Pp +Authenticated requests always include a timestamp in the packet +data, which is included in the computation of the authentication +code. +This timestamp is compared by the server to its receive time +stamp. +If they differ by more than a small amount the request is +rejected. +This is done for two reasons. +First, it makes simple +replay attacks on the server, by someone who might be able to +overhear traffic on your LAN, much more difficult. +Second, it makes +it more difficult to request configuration changes to your server +from topologically remote hosts. +While the reconfiguration facility +will work well with a server on the local host, and may work +adequately between time\-synchronized hosts on the same LAN, it will +work very poorly for more distant hosts. +As such, if reasonable +passwords are chosen, care is taken in the distribution and +protection of keys and appropriate source address restrictions are +applied, the run time reconfiguration facility should provide an +adequate level of security. +.Pp +The following commands all make authenticated requests. +.Bl -tag -width indent +.It Xo Ic addpeer Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Add a configured peer association at the given address and +operating in symmetric active mode. +Note that an existing +association with the same peer may be deleted when this command is +executed, or may simply be converted to conform to the new +configuration, as appropriate. +If the optional +.Ar keyid +is a +nonzero integer, all outgoing packets to the remote server will +have an authentication field attached encrypted with this key. +If +the value is 0 (or not given) no authentication will be done. +The +.Ar version +can be 1, 2 or 3 and defaults to 3. +The +.Cm prefer +keyword indicates a preferred peer (and thus will +be used primarily for clock synchronisation if possible). +The +preferred peer also determines the validity of the PPS signal \- if +the preferred peer is suitable for synchronisation so is the PPS +signal. +.It Xo Ic addserver Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Identical to the addpeer command, except that the operating +mode is client. +.It Xo Ic broadcast Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Identical to the addpeer command, except that the operating +mode is broadcast. +In this case a valid key identifier and key are +required. +The +.Ar peer_address +parameter can be the broadcast +address of the local network or a multicast group address assigned +to NTP. +If a multicast address, a multicast\-capable kernel is +required. +.It Ic unconfig Ar peer_address Oo Ar ... Oc +This command causes the configured bit to be removed from the +specified peer(s). +In many cases this will cause the peer +association to be deleted. +When appropriate, however, the +association may persist in an unconfigured mode if the remote peer +is willing to continue on in this fashion. +.It Xo Ic fudge Ar peer_address +.Op Cm time1 +.Op Cm time2 +.Op Ar stratum +.Op Ar refid +.Xc +This command provides a way to set certain data for a reference +clock. +See the source listing for further information. +.It Xo Ic enable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm monitor | Cm ntp | +.Cm pps | Cm stats +.Oc +.Xc +.It Xo Ic disable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm monitor | Cm ntp | +.Cm pps | Cm stats +.Oc +.Xc +These commands operate in the same way as the +.Ic enable +and +.Ic disable +configuration file commands of +.Xr ntpd 1ntpdmdoc . +.Bl -tag -width indent +.It Cm auth +Enables the server to synchronize with unconfigured peers only +if the peer has been correctly authenticated using either public key +or private key cryptography. +The default for this flag is enable. +.It Cm bclient +Enables the server to listen for a message from a broadcast or +multicast server, as in the multicastclient command with +default address. +The default for this flag is disable. +.It Cm calibrate +Enables the calibrate feature for reference clocks. +The default for this flag is disable. +.It Cm kernel +Enables the kernel time discipline, if available. +The default for this flag is enable if support is available, otherwise disable. +.It Cm monitor +Enables the monitoring facility. +See the documentation here about the +.Cm monlist +command or further information. +The default for this flag is enable. +.It Cm ntp +Enables time and frequency discipline. +In effect, this switch opens and closes the feedback loop, +which is useful for testing. +The default for this flag is enable. +.It Cm pps +Enables the pulse\-per\-second (PPS) signal when frequency +and time is disciplined by the precision time kernel modifications. +See the +.Qq A Kernel Model for Precision Timekeeping +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +page for further information. +The default for this flag is disable. +.It Cm stats +Enables the statistics facility. +See the +.Sx Monitoring Options +section of +.Xr ntp.conf 5 +for further information. +The default for this flag is disable. +.El +.It Xo Ic restrict Ar address Ar mask +.Ar flag Oo Ar ... Oc +.Xc +This command operates in the same way as the +.Ic restrict +configuration file commands of +.Xr ntpd 1ntpdmdoc . +.It Xo Ic unrestrict Ar address Ar mask +.Ar flag Oo Ar ... Oc +.Xc +Unrestrict the matching entry from the restrict list. +.It Xo Ic delrestrict Ar address Ar mask +.Op Cm ntpport +.Xc +Delete the matching entry from the restrict list. +.It Ic readkeys +Causes the current set of authentication keys to be purged and +a new set to be obtained by rereading the keys file (which must +have been specified in the +.Xr ntpd 1ntpdmdoc +configuration file). +This +allows encryption keys to be changed without restarting the +server. +.It Ic trustedkey Ar keyid Oo Ar ... Oc +.It Ic untrustedkey Ar keyid Oo Ar ... Oc +These commands operate in the same way as the +.Ic trustedkey +and +.Ic untrustedkey +configuration file +commands of +.Xr ntpd 1ntpdmdoc . +.It Ic authinfo +Returns information concerning the authentication module, +including known keys and counts of encryptions and decryptions +which have been done. +.It Ic traps +Display the traps set in the server. +See the source listing for +further information. +.It Xo Ic addtrap Ar address +.Op Ar port +.Op Ar interface +.Xc +Set a trap for asynchronous messages. +See the source listing +for further information. +.It Xo Ic clrtrap Ar address +.Op Ar port +.Op Ar interface +.Xc +Clear a trap for asynchronous messages. +See the source listing +for further information. +.It Ic reset +Clear the statistics counters in various modules of the server. +See the source listing for further information. +.El +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntp.conf 5 , +.Xr ntpd 1ntpdmdoc +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 3) +.%O RFC1305 +.Re +.Sh AUTHORS +The formatting directives in this document came from FreeBSD. +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh BUGS +The +.Nm +utility is a crude hack. +Much of the information it shows is +deadly boring and could only be loved by its implementer. +The +program was designed so that new (and temporary) features were easy +to hack in, at great expense to the program's ease of use. +Despite +this, the program is occasionally useful. +.Pp +Please report bugs to http://bugs.ntp.org . +.Pp +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntpdc\fP +option definitions. diff --git a/contrib/ntp/ntpdc/ntpdc.c b/contrib/ntp/ntpdc/ntpdc.c index 912653339..ab177885b 100644 --- a/contrib/ntp/ntpdc/ntpdc.c +++ b/contrib/ntp/ntpdc/ntpdc.c @@ -1,36 +1,38 @@ /* * ntpdc - control and monitor your ntpd daemon */ - +#include #include - +#include #include #include #include +#ifdef HAVE_UNISTD_H +# include +#endif +#ifdef HAVE_FCNTL_H +# include +#endif +#ifdef SYS_WINNT +# include +#endif +#include +#include #include "ntpdc.h" #include "ntp_select.h" -#include "ntp_io.h" #include "ntp_stdlib.h" -/* Don't include ISC's version of IPv6 variables and structures */ -#define ISC_IPV6_H 1 -#include "isc/net.h" -#include "isc/result.h" +#include "ntp_assert.h" +#include "ntp_lineedit.h" +#ifdef OPENSSL +#include "openssl/evp.h" +#include "openssl/objects.h" +#endif +#include +#include "ntp_libopts.h" #include "ntpdc-opts.h" -#ifdef SYS_WINNT -# include -# include -#else -# define closesocket close -#endif /* SYS_WINNT */ - -#if defined(HAVE_LIBREADLINE) || defined (HAVE_LIBEDIT) -# include -# include -#endif /* HAVE_LIBREADLINE || HAVE_LIBEDIT */ - #ifdef SYS_VXWORKS /* vxWorks needs mode flag -casey*/ # define open(name, flags) open(name, flags, 0777) @@ -56,12 +58,8 @@ static const char * prompt = "ntpdc> "; /* prompt to ask him about */ static u_long info_auth_keyid; static int keyid_entered = 0; -/* - * Type of key md5 - */ -#define KEY_TYPE_MD5 4 - -static int info_auth_keytype = KEY_TYPE_MD5; /* MD5 */ +static int info_auth_keytype = NID_md5; /* MD5 */ +static size_t info_auth_hashlen = 16; /* MD5 */ u_long current_time; /* needed by authkeys; not used */ /* @@ -69,42 +67,40 @@ u_long current_time; /* needed by authkeys; not used */ */ s_char sys_precision; /* local clock precision (log2 s) */ -int ntpdcmain P((int, char **)); +int ntpdcmain (int, char **); /* * Built in command handler declarations */ -static int openhost P((const char *)); -static int sendpkt P((char *, int)); -static void growpktdata P((void)); -static int getresponse P((int, int, int *, int *, char **, int)); -static int sendrequest P((int, int, int, int, int, char *)); -static void getcmds P((void)); -static RETSIGTYPE abortcmd P((int)); -static void docmd P((const char *)); -static void tokenize P((const char *, char **, int *)); -static int findcmd P((char *, struct xcmd *, struct xcmd *, struct xcmd **)); -static int getarg P((char *, int, arg_v *)); -static int getnetnum P((const char *, struct sockaddr_storage *, char *, int)); -static void help P((struct parse *, FILE *)); -#ifdef QSORT_USES_VOID_P -static int helpsort P((const void *, const void *)); -#else -static int helpsort P((char **, char **)); -#endif -static void printusage P((struct xcmd *, FILE *)); -static void timeout P((struct parse *, FILE *)); -static void my_delay P((struct parse *, FILE *)); -static void host P((struct parse *, FILE *)); -static void keyid P((struct parse *, FILE *)); -static void keytype P((struct parse *, FILE *)); -static void passwd P((struct parse *, FILE *)); -static void hostnames P((struct parse *, FILE *)); -static void setdebug P((struct parse *, FILE *)); -static void quit P((struct parse *, FILE *)); -static void version P((struct parse *, FILE *)); -static void warning P((const char *, const char *, const char *)); -static void error P((const char *, const char *, const char *)); -static u_long getkeyid P((const char *)); +static int openhost (const char *); +static int sendpkt (void *, size_t); +static void growpktdata (void); +static int getresponse (int, int, int *, int *, char **, int); +static int sendrequest (int, int, int, u_int, size_t, char *); +static void getcmds (void); +static RETSIGTYPE abortcmd (int); +static void docmd (const char *); +static void tokenize (const char *, char **, int *); +static int findcmd (char *, struct xcmd *, struct xcmd *, struct xcmd **); +static int getarg (char *, int, arg_v *); +static int getnetnum (const char *, sockaddr_u *, char *, int); +static void help (struct parse *, FILE *); +static int helpsort (const void *, const void *); +static void printusage (struct xcmd *, FILE *); +static void timeout (struct parse *, FILE *); +static void my_delay (struct parse *, FILE *); +static void host (struct parse *, FILE *); +static void keyid (struct parse *, FILE *); +static void keytype (struct parse *, FILE *); +static void passwd (struct parse *, FILE *); +static void hostnames (struct parse *, FILE *); +static void setdebug (struct parse *, FILE *); +static void quit (struct parse *, FILE *); +static void version (struct parse *, FILE *); +static void warning (const char *, ...) + __attribute__((__format__(__printf__, 1, 2))); +static void error (const char *, ...) + __attribute__((__format__(__printf__, 1, 2))); +static u_long getkeyid (const char *); @@ -159,10 +155,10 @@ static struct xcmd builtins[] = { /* * Default values we use. */ +#define DEFHOST "localhost" /* default host name */ #define DEFTIMEOUT (5) /* 5 second time out */ #define DEFSTIMEOUT (2) /* 2 second time out after first */ #define DEFDELAY 0x51EB852 /* 20 milliseconds, l_fp fraction */ -#define DEFHOST "localhost" /* default host name */ #define LENHOSTNAME 256 /* host name is 256 characters long */ #define MAXCMDS 100 /* maximum commands on cmd line */ #define MAXHOSTS 200 /* maximum hosts on cmd line */ @@ -173,8 +169,8 @@ static struct xcmd builtins[] = { /* * Some variables used and manipulated locally */ -static struct timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ -static struct timeval tvsout = { DEFSTIMEOUT, 0 }; /* secondary time out */ +static struct sock_timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ +static struct sock_timeval tvsout = { DEFSTIMEOUT, 0 };/* secondary time out */ static l_fp delay_time; /* delay time */ static char currenthost[LENHOSTNAME]; /* current host name */ int showhostnames = 1; /* show host names by default */ @@ -185,18 +181,6 @@ static SOCKET sockfd; /* fd socket is opened on */ static int havehost = 0; /* set to 1 when host open */ int s_port = 0; -#if defined (SYS_WINNT) || defined (SYS_VXWORKS) -char password[9]; -#endif /* SYS_WINNT || SYS_VXWORKS */ - -#ifdef SYS_WINNT -DWORD NumberOfBytesWritten; - -HANDLE TimerThreadHandle = NULL; /* 1998/06/03 - Used in ntplib/machines.c */ -void timer(void) { ; }; /* 1998/06/03 - Used in ntplib/machines.c */ - -#endif /* SYS_WINNT */ - /* * Holds data returned from queries. We allocate INITDATASIZE * octets to begin with, increasing this as we need to. @@ -240,11 +224,6 @@ static const char *chosts[MAXHOSTS]; #define ISEOL(c) ((c) == '\n' || (c) == '\r' || (c) == '\0') #define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) -/* - * For converting time stamps to dates - */ -#define JAN_1970 2208988800 /* 1970 - 1900 in seconds */ - /* * Jump buffer for longjumping back to the command level */ @@ -261,8 +240,7 @@ static FILE *current_output; */ extern struct xcmd opcmds[]; -char *progname; -volatile int debug; +char const *progname; #ifdef NO_MAIN_ALLOWED CALL(ntpdc,"ntpdc",ntpdcmain); @@ -296,7 +274,6 @@ ntpdcmain( char *argv[] ) { - extern int ntp_optind; delay_time.l_ui = 0; delay_time.l_uf = DEFDELAY; @@ -306,38 +283,28 @@ ntpdcmain( taskPrioritySet(taskIdSelf(), 100 ); #endif -#ifdef SYS_WINNT - if (!Win32InitSockets()) - { - fprintf(stderr, "No useable winsock.dll:"); - exit(1); - } -#endif /* SYS_WINNT */ + init_lib(); /* sets up ipv4_works, ipv6_works */ + ssl_applink(); + init_auth(); - /* Check to see if we have IPv6. Otherwise force the -4 flag */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) { + /* Check to see if we have IPv6. Otherwise default to IPv4 */ + if (!ipv6_works) ai_fam_default = AF_INET; - } progname = argv[0]; { - int optct = optionProcess(&ntpdcOptions, argc, argv); + int optct = ntpOptionProcess(&ntpdcOptions, argc, argv); argc -= optct; argv += optct; } - switch (WHICH_IDX_IPV4) { - case INDEX_OPT_IPV4: + if (HAVE_OPT(IPV4)) ai_fam_templ = AF_INET; - break; - case INDEX_OPT_IPV6: + else if (HAVE_OPT(IPV6)) ai_fam_templ = AF_INET6; - break; - default: + else ai_fam_templ = ai_fam_default; - break; - } if (HAVE_OPT(COMMAND)) { int cmdct = STACKCT_OPT( COMMAND ); @@ -348,7 +315,7 @@ ntpdcmain( } } - debug = DESC(DEBUG_LEVEL).optOccCt; + debug = OPT_VALUE_SET_DEBUG_LEVEL; if (HAVE_OPT(INTERACTIVE)) { interactive = 1; @@ -382,62 +349,6 @@ ntpdcmain( interactive = 1; } -#if 0 - ai_fam_templ = ai_fam_default; - while ((c = ntp_getopt(argc, argv, "46c:dilnps")) != EOF) - switch (c) { - case '4': - ai_fam_templ = AF_INET; - break; - case '6': - ai_fam_templ = AF_INET6; - break; - case 'c': - ADDCMD(ntp_optarg); - break; - case 'd': - ++debug; - break; - case 'i': - interactive = 1; - break; - case 'l': - ADDCMD("listpeers"); - break; - case 'n': - showhostnames = 0; - break; - case 'p': - ADDCMD("peers"); - break; - case 's': - ADDCMD("dmpeers"); - break; - default: - errflg++; - break; - } - - if (errflg) { - (void) fprintf(stderr, - "usage: %s [-46dilnps] [-c cmd] host ...\n", - progname); - exit(2); - } - - if (ntp_optind == argc) { - ADDHOST(DEFHOST); - } else { - for (; ntp_optind < argc; ntp_optind++) - ADDHOST(argv[ntp_optind]); - } - - if (numcmds == 0 && interactive == 0 - && isatty(fileno(stdin)) && isatty(fileno(stderr))) { - interactive = 1; - } -#endif - #ifndef SYS_WINNT /* Under NT cannot handle SIGINT, WIN32 spawns a handler */ if (interactive) (void) signal_no_reset(SIGINT, abortcmd); @@ -446,12 +357,8 @@ ntpdcmain( /* * Initialize the packet data buffer */ - pktdata = (char *)malloc(INITDATASIZE); - if (pktdata == NULL) { - (void) fprintf(stderr, "%s: malloc() failed!\n", progname); - exit(1); - } pktdatasize = INITDATASIZE; + pktdata = emalloc(INITDATASIZE); if (numcmds == 0) { (void) openhost(chosts[0]); @@ -487,6 +394,8 @@ openhost( char temphost[LENHOSTNAME]; int a_info, i; struct addrinfo hints, *ai = NULL; + sockaddr_u addr; + size_t octets; register const char *cp; char name[LENHOSTNAME]; char service[5]; @@ -499,10 +408,14 @@ openhost( if (*cp == '[') { cp++; - for(i = 0; *cp != ']'; cp++, i++) - name[i] = *cp; - name[i] = '\0'; - hname = name; + for (i = 0; *cp && *cp != ']'; cp++, i++) + name[i] = *cp; + if (*cp == ']') { + name[i] = '\0'; + hname = name; + } else { + return 0; + } } /* @@ -512,12 +425,12 @@ openhost( * will return an "IPv4-mapped IPv6 address" address if you * give it an IPv4 address to lookup. */ - strcpy(service, "ntp"); - memset((char *)&hints, 0, sizeof(struct addrinfo)); + strlcpy(service, "ntp", sizeof(service)); + ZERO(hints); hints.ai_family = ai_fam_templ; hints.ai_protocol = IPPROTO_UDP; hints.ai_socktype = SOCK_DGRAM; - hints.ai_flags = AI_NUMERICHOST; + hints.ai_flags = Z_AI_NUMERICHOST; a_info = getaddrinfo(hname, service, &hints, &ai); if (a_info == EAI_NONAME @@ -537,34 +450,39 @@ openhost( a_info = getaddrinfo(hname, service, &hints, &ai); } if (a_info != 0) { - (void) fprintf(stderr, "%s\n", gai_strerror(a_info)); + fprintf(stderr, "%s\n", gai_strerror(a_info)); if (ai != NULL) freeaddrinfo(ai); return 0; } - if (ai->ai_canonname == NULL) { - strncpy(temphost, stoa((struct sockaddr_storage *)ai->ai_addr), - LENHOSTNAME); - temphost[LENHOSTNAME-1] = '\0'; - } else { - strncpy(temphost, ai->ai_canonname, LENHOSTNAME); - temphost[LENHOSTNAME-1] = '\0'; - } + /* + * getaddrinfo() has returned without error so ai should not + * be NULL. + */ + INSIST(ai != NULL); + ZERO(addr); + octets = min(sizeof(addr), ai->ai_addrlen); + memcpy(&addr, ai->ai_addr, octets); + + if (ai->ai_canonname == NULL) + strlcpy(temphost, stoa(&addr), sizeof(temphost)); + else + strlcpy(temphost, ai->ai_canonname, sizeof(temphost)); if (debug > 2) - printf("Opening host %s\n", temphost); + printf("Opening host %s\n", temphost); if (havehost == 1) { if (debug > 2) - printf("Closing old host %s\n", currenthost); - (void) closesocket(sockfd); + printf("Closing old host %s\n", currenthost); + closesocket(sockfd); havehost = 0; } - (void) strcpy(currenthost, temphost); + strlcpy(currenthost, temphost, sizeof(currenthost)); /* port maps to the same in both families */ - s_port = ((struct sockaddr_in6 *)ai->ai_addr)->sin6_port; + s_port = NSRCPORT(&addr);; #ifdef SYS_VXWORKS ((struct sockaddr_in6 *)&hostaddr)->sin6_port = htons(SERVER_PORT_NUM); if (ai->ai_family == AF_INET) @@ -586,18 +504,13 @@ openhost( exit(1); } } +#endif /* SYS_WINNT */ sockfd = socket(ai->ai_family, SOCK_DGRAM, 0); if (sockfd == INVALID_SOCKET) { - error("socket", "", ""); + error("socket"); exit(-1); } -#else - sockfd = socket(ai->ai_family, SOCK_DGRAM, 0); - if (sockfd == -1) - error("socket", "", ""); -#endif /* SYS_WINNT */ - #ifdef NEED_RCVBUF_SLOP # ifdef SO_RCVBUF @@ -606,21 +519,22 @@ openhost( if (setsockopt(sockfd, SOL_SOCKET, SO_RCVBUF, &rbufsize, sizeof(int)) == -1) - error("setsockopt", "", ""); + error("setsockopt"); } # endif #endif #ifdef SYS_VXWORKS if (connect(sockfd, (struct sockaddr *)&hostaddr, - sizeof(hostaddr)) == -1) + sizeof(hostaddr)) == -1) { #else - if (connect(sockfd, (struct sockaddr *)ai->ai_addr, - ai->ai_addrlen) == -1) + if (connect(sockfd, ai->ai_addr, ai->ai_addrlen) == -1) { #endif /* SYS_VXWORKS */ - error("connect", "", ""); - if (ai != NULL) - freeaddrinfo(ai); + error("connect"); + exit(-1); + } + + freeaddrinfo(ai); havehost = 1; req_pkt_size = REQ_LEN_NOMAC; impl_ver = IMPL_XNTPD; @@ -634,12 +548,12 @@ openhost( */ static int sendpkt( - char *xdata, - int xdatalen + void * xdata, + size_t xdatalen ) { - if (send(sockfd, xdata, (size_t)xdatalen, 0) == -1) { - warning("write to %s failed", currenthost, ""); + if (send(sockfd, xdata, xdatalen, 0) == -1) { + warning("write to %s failed", currenthost); return -1; } @@ -653,12 +567,11 @@ sendpkt( static void growpktdata(void) { + size_t priorsz; + + priorsz = (size_t)pktdatasize; pktdatasize += INCDATASIZE; - pktdata = (char *)realloc(pktdata, (unsigned)pktdatasize); - if (pktdata == 0) { - (void) fprintf(stderr, "%s: realloc() failed!\n", progname); - exit(1); - } + pktdata = erealloc_zero(pktdata, (size_t)pktdatasize, priorsz); } @@ -676,7 +589,7 @@ getresponse( ) { struct resp_pkt rpkt; - struct timeval tvo; + struct sock_timeval tvo; int items; int i; int size; @@ -689,7 +602,7 @@ getresponse( int numrecv; int seq; fd_set fds; - int n; + ssize_t n; int pad; /* @@ -705,20 +618,20 @@ getresponse( numrecv = 0; *rdata = datap = pktdata; lastseq = 999; /* too big to be a sequence number */ - memset(haveseq, 0, sizeof(haveseq)); + ZERO(haveseq); FD_ZERO(&fds); again: if (firstpkt) - tvo = tvout; + tvo = tvout; else - tvo = tvsout; + tvo = tvsout; FD_SET(sockfd, &fds); n = select(sockfd+1, &fds, (fd_set *)0, (fd_set *)0, &tvo); if (n == -1) { - warning("select fails", "", ""); + warning("select fails"); return -1; } if (n == 0) { @@ -737,7 +650,7 @@ getresponse( printf("Received sequence numbers"); for (n = 0; n <= MAXSEQ; n++) if (haveseq[n]) - printf(" %d,", n); + printf(" %zd,", n); if (lastseq != 999) printf(" last frame received\n"); else @@ -749,7 +662,7 @@ getresponse( n = recv(sockfd, (char *)&rpkt, sizeof(rpkt), 0); if (n == -1) { - warning("read", "", ""); + warning("read"); return -1; } @@ -757,37 +670,37 @@ getresponse( /* * Check for format errors. Bug proofing. */ - if (n < RESP_HEADER_SIZE) { + if (n < (ssize_t)RESP_HEADER_SIZE) { if (debug) - printf("Short (%d byte) packet received\n", n); + printf("Short (%zd byte) packet received\n", n); goto again; } if (INFO_VERSION(rpkt.rm_vn_mode) > NTP_VERSION || INFO_VERSION(rpkt.rm_vn_mode) < NTP_OLDVERSION) { if (debug) - printf("Packet received with version %d\n", - INFO_VERSION(rpkt.rm_vn_mode)); + printf("Packet received with version %d\n", + INFO_VERSION(rpkt.rm_vn_mode)); goto again; } if (INFO_MODE(rpkt.rm_vn_mode) != MODE_PRIVATE) { if (debug) - printf("Packet received with mode %d\n", - INFO_MODE(rpkt.rm_vn_mode)); + printf("Packet received with mode %d\n", + INFO_MODE(rpkt.rm_vn_mode)); goto again; } if (INFO_IS_AUTH(rpkt.auth_seq)) { if (debug) - printf("Encrypted packet received\n"); + printf("Encrypted packet received\n"); goto again; } if (!ISRESPONSE(rpkt.rm_vn_mode)) { if (debug) - printf("Received request packet, wanted response\n"); + printf("Received request packet, wanted response\n"); goto again; } if (INFO_MBZ(rpkt.mbz_itemsize) != 0) { if (debug) - printf("Received packet with nonzero MBZ field!\n"); + printf("Received packet with nonzero MBZ field!\n"); goto again; } @@ -796,7 +709,7 @@ getresponse( */ if (rpkt.implementation != implcode || rpkt.request != reqcode) { if (debug) - printf( + printf( "Received implementation/request of %d/%d, wanted %d/%d", rpkt.implementation, rpkt.request, implcode, reqcode); @@ -823,10 +736,11 @@ getresponse( pad = esize - size; else pad = 0; - if ((datasize = items*size) > (n-RESP_HEADER_SIZE)) { + datasize = items * size; + if ((size_t)datasize > (n-RESP_HEADER_SIZE)) { if (debug) printf( - "Received items %d, size %d (total %d), data in packet is %d\n", + "Received items %d, size %d (total %d), data in packet is %zu\n", items, size, datasize, n-RESP_HEADER_SIZE); goto again; } @@ -835,7 +749,7 @@ getresponse( * If this isn't our first packet, make sure the size matches * the other ones. */ - if (!firstpkt && esize != *rsize) { + if (!firstpkt && size != *rsize) { if (debug) printf("Received itemsize %d, previous %d\n", size, *rsize); @@ -869,7 +783,7 @@ getresponse( if ((datap + datasize + (pad * items)) > (pktdata + pktdatasize)) { int offset = datap - pktdata; growpktdata(); - *rdata = pktdata; /* might have been realloced ! */ + *rdata = pktdata; /* might have been realloced ! */ datap = pktdata + offset; } /* @@ -877,11 +791,11 @@ getresponse( * items. This is so we can play nice with older implementations */ - tmp_data = (char *)rpkt.data; - for(i = 0; i keyid > 0) - info_auth_keyid = ((struct conf_peer *)qpkt.data)->keyid; - else { - maclen = getkeyid("Keyid: "); - if (maclen == 0) { - (void) fprintf(stderr, - "Invalid key identifier\n"); - return 1; - } - info_auth_keyid = maclen; - } + if (info_auth_keyid == 0) { + key_id = getkeyid("Keyid: "); + if (!key_id) { + fprintf(stderr, "Invalid key identifier\n"); + return 1; } - if (!authistrusted(info_auth_keyid)) { - pass = getpass("MD5 Password: "); - if (*pass == '\0') { - (void) fprintf(stderr, - "Invalid password\n"); - return (1); - } + info_auth_keyid = key_id; + } + if (!authistrusted(info_auth_keyid)) { + pass = getpass_keytype(info_auth_keytype); + if ('\0' == pass[0]) { + fprintf(stderr, "Invalid password\n"); + return 1; } - authusekey(info_auth_keyid, info_auth_keytype, (const u_char *)pass); + authusekey(info_auth_keyid, info_auth_keytype, + (u_char *)pass); authtrust(info_auth_keyid, 1); - qpkt.auth_seq = AUTH_SEQ(1, 0); - qpktail->keyid = htonl(info_auth_keyid); - get_systime(&ts); - L_ADD(&ts, &delay_time); - HTONL_FP(&ts, &qpktail->tstamp); - maclen = authencrypt(info_auth_keyid, (u_int32 *)&qpkt, - req_pkt_size); - if (maclen == 0) { - (void) fprintf(stderr, "Key not found\n"); - return (1); - } - return sendpkt((char *)&qpkt, (int)(req_pkt_size + maclen)); } - /*NOTREACHED*/ + qpkt.auth_seq = AUTH_SEQ(1, 0); + if (info_auth_hashlen > 16) { + /* + * Only ntpd which expects REQ_LEN_NOMAC plus maclen + * octets in an authenticated request using a 16 octet + * digest (that is, a newer ntpd) will handle digests + * larger than 16 octets, so for longer digests, do + * not attempt to shorten the requests for downlevel + * ntpd compatibility. + */ + if (REQ_LEN_NOMAC != req_pkt_size) + return 1; + reqsize = REQ_LEN_HDR + datasize + sizeof(*ptstamp); + /* align to 32 bits */ + reqsize = (reqsize + 3) & ~3; + } else + reqsize = req_pkt_size; + ptstamp = (void *)((char *)&qpkt + reqsize); + ptstamp--; + get_systime(&ts); + L_ADD(&ts, &delay_time); + HTONL_FP(&ts, ptstamp); + maclen = authencrypt(info_auth_keyid, (void *)&qpkt, reqsize); + if (!maclen) { + fprintf(stderr, "Key not found\n"); + return 1; + } else if (maclen != (int)(info_auth_hashlen + sizeof(keyid_t))) { + fprintf(stderr, + "%d octet MAC, %zu expected with %zu octet digest\n", + maclen, (info_auth_hashlen + sizeof(keyid_t)), + info_auth_hashlen); + return 1; + } + return sendpkt(&qpkt, reqsize + maclen); } @@ -1007,7 +954,7 @@ doquery( int res; char junk[512]; fd_set fds; - struct timeval tvzero; + struct sock_timeval tvzero; /* * Check to make sure host is open @@ -1028,7 +975,7 @@ again: res = select(sockfd+1, &fds, (fd_set *)0, (fd_set *)0, &tvzero); if (res == -1) { - warning("polling select", "", ""); + warning("polling select"); return -1; } else if (res > 0) @@ -1041,7 +988,7 @@ again: */ res = sendrequest(implcode, reqcode, auth, qitems, qsize, qdata); if (res != 0) - return res; + return res; /* * Get the response. If we got a standard error, print a message @@ -1079,36 +1026,36 @@ again: /* log error message if not told to be quiet */ if ((res > 0) && (((1 << res) & quiet_mask) == 0)) { switch(res) { - case INFO_ERR_IMPL: + case INFO_ERR_IMPL: /* Give us a chance to try the older implementation. */ if (implcode == IMPL_XNTPD) break; (void) fprintf(stderr, - "***Server implementation incompatable with our own\n"); + "***Server implementation incompatible with our own\n"); break; - case INFO_ERR_REQ: + case INFO_ERR_REQ: (void) fprintf(stderr, "***Server doesn't implement this request\n"); break; - case INFO_ERR_FMT: + case INFO_ERR_FMT: (void) fprintf(stderr, "***Server reports a format error in the received packet (shouldn't happen)\n"); break; - case INFO_ERR_NODATA: + case INFO_ERR_NODATA: (void) fprintf(stderr, "***Server reports data not found\n"); break; - case INFO_ERR_AUTH: + case INFO_ERR_AUTH: (void) fprintf(stderr, "***Permission denied\n"); break; - case ERR_TIMEOUT: + case ERR_TIMEOUT: (void) fprintf(stderr, "***Request timed out\n"); break; - case ERR_INCOMPLETE: + case ERR_INCOMPLETE: (void) fprintf(stderr, "***Response from server was incomplete\n"); break; - default: + default: (void) fprintf(stderr, "***Server returns unknown error code %d\n", res); break; @@ -1124,33 +1071,20 @@ again: static void getcmds(void) { -#if defined(HAVE_LIBREADLINE) || defined(HAVE_LIBEDIT) - char *line; + char * line; + int count; + + ntp_readline_init(interactive ? prompt : NULL); for (;;) { - if ((line = readline(interactive?prompt:"")) == NULL) return; - if (*line) add_history(line); + line = ntp_readline(&count); + if (NULL == line) + break; docmd(line); free(line); } -#else /* not (HAVE_LIBREADLINE || HAVE_LIBEDIT) */ - char line[MAXLINE]; - for (;;) { - if (interactive) { -#ifdef VMS /* work around a problem with mixing stdout & stderr */ - fputs("",stdout); -#endif - (void) fputs(prompt, stderr); - (void) fflush(stderr); - } - - if (fgets(line, sizeof line, stdin) == NULL) - return; - - docmd(line); - } -#endif /* not HAVE_LIBREADLINE || HAVE_LIBEDIT */ + ntp_readline_uninit(); } @@ -1191,6 +1125,11 @@ docmd( /* * Tokenize the command line. If nothing on it, return. */ + if (strlen(cmdline) >= MAXLINE) { + fprintf(stderr, "***Command ignored, more than %d characters:\n%s\n", + MAXLINE - 1, cmdline); + return; + } tokenize(cmdline, tokens, &ntok); if (ntok == 0) return; @@ -1408,8 +1347,7 @@ getarg( char *cp, *np; static const char *digits = "0123456789"; - memset(argp, 0, sizeof(*argp)); - + ZERO(*argp); argp->string = str; argp->type = code & ~OPT; @@ -1482,58 +1420,63 @@ getarg( static int getnetnum( const char *hname, - struct sockaddr_storage *num, + sockaddr_u *num, char *fullhost, int af ) { - int sockaddr_len; struct addrinfo hints, *ai = NULL; - sockaddr_len = (af == AF_INET) - ? sizeof(struct sockaddr_in) - : sizeof(struct sockaddr_in6); - memset((char *)&hints, 0, sizeof(struct addrinfo)); + ZERO(hints); hints.ai_flags = AI_CANONNAME; #ifdef AI_ADDRCONFIG hints.ai_flags |= AI_ADDRCONFIG; #endif - /* decodenetnum only works with addresses */ + /* + * decodenetnum only works with addresses, but handles syntax + * that getaddrinfo doesn't: [2001::1]:1234 + */ if (decodenetnum(hname, num)) { - if (fullhost != 0) { - getnameinfo((struct sockaddr *)num, sockaddr_len, - fullhost, sizeof(fullhost), NULL, 0, - NI_NUMERICHOST); - } + if (fullhost != NULL) + getnameinfo(&num->sa, SOCKLEN(num), fullhost, + LENHOSTNAME, NULL, 0, 0); return 1; } else if (getaddrinfo(hname, "ntp", &hints, &ai) == 0) { - memmove((char *)num, ai->ai_addr, ai->ai_addrlen); - if (fullhost != 0) - (void) strcpy(fullhost, ai->ai_canonname); + INSIST(sizeof(*num) >= ai->ai_addrlen); + memcpy(num, ai->ai_addr, ai->ai_addrlen); + if (fullhost != NULL) { + if (ai->ai_canonname != NULL) + strlcpy(fullhost, ai->ai_canonname, + LENHOSTNAME); + else + getnameinfo(&num->sa, SOCKLEN(num), + fullhost, LENHOSTNAME, NULL, + 0, 0); + } return 1; - } else { - (void) fprintf(stderr, "***Can't find host %s\n", hname); - return 0; } - /*NOTREACHED*/ + fprintf(stderr, "***Can't find host %s\n", hname); + + return 0; } + /* * nntohost - convert network number to host name. This routine enforces * the showhostnames setting. */ -char * +const char * nntohost( - struct sockaddr_storage *netnum + sockaddr_u *netnum ) { - if (!showhostnames) - return stoa(netnum); - - if ((netnum->ss_family == AF_INET) && ISREFCLOCKADR(netnum)) + if (!showhostnames || SOCK_UNSPEC(netnum)) + return stoa(netnum); + else if (ISREFCLOCKADR(netnum)) return refnumtoa(netnum); - return socktohost(netnum); + else + return socktohost(netnum); } @@ -1553,58 +1496,51 @@ help( struct xcmd *xcp; char *cmd; const char *list[100]; - int word, words; - int row, rows; - int col, cols; + size_t word, words; + size_t row, rows; + size_t col, cols; + size_t length; if (pcmd->nargs == 0) { words = 0; for (xcp = builtins; xcp->keyword != 0; xcp++) { if (*(xcp->keyword) != '?') - list[words++] = xcp->keyword; + list[words++] = xcp->keyword; } - for (xcp = opcmds; xcp->keyword != 0; xcp++) - list[words++] = xcp->keyword; + for (xcp = opcmds; xcp->keyword != 0; xcp++) + list[words++] = xcp->keyword; - qsort( -#ifdef QSORT_USES_VOID_P - (void *) -#else - (char *) -#endif - (list), (size_t)(words), sizeof(char *), helpsort); + qsort((void *)list, words, sizeof(list[0]), helpsort); col = 0; for (word = 0; word < words; word++) { - int length = strlen(list[word]); - if (col < length) { - col = length; - } + length = strlen(list[word]); + col = max(col, length); } cols = SCREENWIDTH / ++col; - rows = (words + cols - 1) / cols; + rows = (words + cols - 1) / cols; - (void) fprintf(fp, "ntpdc commands:\n"); + fprintf(fp, "ntpdc commands:\n"); for (row = 0; row < rows; row++) { - for (word = row; word < words; word += rows) { - (void) fprintf(fp, "%-*.*s", col, col-1, list[word]); - } - (void) fprintf(fp, "\n"); + for (word = row; word < words; word += rows) + fprintf(fp, "%-*.*s", (int)col, + (int)col - 1, list[word]); + fprintf(fp, "\n"); } } else { cmd = pcmd->argval[0].string; words = findcmd(cmd, builtins, opcmds, &xcp); if (words == 0) { - (void) fprintf(stderr, - "Command `%s' is unknown\n", cmd); + fprintf(stderr, + "Command `%s' is unknown\n", cmd); return; } else if (words >= 2) { - (void) fprintf(stderr, - "Command `%s' is ambiguous\n", cmd); + fprintf(stderr, + "Command `%s' is ambiguous\n", cmd); return; } - (void) fprintf(fp, "function: %s\n", xcp->comment); + fprintf(fp, "function: %s\n", xcp->comment); printusage(xcp, fp); } } @@ -1613,28 +1549,17 @@ help( /* * helpsort - do hostname qsort comparisons */ -#ifdef QSORT_USES_VOID_P static int helpsort( const void *t1, const void *t2 ) { - char const * const * name1 = (char const * const *)t1; - char const * const * name2 = (char const * const *)t2; + const char * const * name1 = t1; + const char * const * name2 = t2; return strcmp(*name1, *name2); } -#else -static int -helpsort( - char **name1, - char **name2 - ) -{ - return strcmp(*name1, *name2); -} -#endif /* @@ -1799,21 +1724,34 @@ keytype( FILE *fp ) { - if (pcmd->nargs == 0) - fprintf(fp, "keytype is %s\n", - (info_auth_keytype == KEY_TYPE_MD5) ? "MD5" : "???"); - else - switch (*(pcmd->argval[0].string)) { - case 'm': - case 'M': - info_auth_keytype = KEY_TYPE_MD5; - break; + const char * digest_name; + size_t digest_len; + int key_type; + + if (!pcmd->nargs) { + fprintf(fp, "keytype is %s with %lu octet digests\n", + keytype_name(info_auth_keytype), + (u_long)info_auth_hashlen); + return; + } - default: - fprintf(fp, "keytype must be 'md5'\n"); - } -} + digest_name = pcmd->argval[0].string; + digest_len = 0; + key_type = keytype_from_text(digest_name, &digest_len); + if (!key_type) { + fprintf(fp, "keytype must be 'md5'%s\n", +#ifdef OPENSSL + " or a digest type provided by OpenSSL"); +#else + ""); +#endif + return; + } + + info_auth_keytype = key_type; + info_auth_hashlen = digest_len; +} /* @@ -1835,20 +1773,17 @@ passwd( return; } } - if (!interactive) { - authusekey(info_auth_keyid, info_auth_keytype, - (u_char *)pcmd->argval[0].string); - authtrust(info_auth_keyid, 1); - } else { - pass = getpass("MD5 Password: "); - if (*pass == '\0') - (void) fprintf(fp, "Password unchanged\n"); - else { - authusekey(info_auth_keyid, info_auth_keytype, - (u_char *)pass); - authtrust(info_auth_keyid, 1); + if (pcmd->nargs >= 1) + pass = pcmd->argval[0].string; + else { + pass = getpass_keytype(info_auth_keytype); + if ('\0' == *pass) { + fprintf(fp, "Password unchanged\n"); + return; } } + authusekey(info_auth_keyid, info_auth_keytype, (u_char *)pass); + authtrust(info_auth_keyid, 1); } @@ -1935,34 +1870,44 @@ version( } +static void __attribute__((__format__(__printf__, 1, 0))) +vwarning(const char *fmt, va_list ap) +{ + int serrno = errno; + (void) fprintf(stderr, "%s: ", progname); + vfprintf(stderr, fmt, ap); + (void) fprintf(stderr, ": %s\n", strerror(serrno)); +} + /* * warning - print a warning message */ -static void +static void __attribute__((__format__(__printf__, 1, 2))) warning( const char *fmt, - const char *st1, - const char *st2 + ... ) { - (void) fprintf(stderr, "%s: ", progname); - (void) fprintf(stderr, fmt, st1, st2); - (void) fprintf(stderr, ": "); - perror(""); + va_list ap; + va_start(ap, fmt); + vwarning(fmt, ap); + va_end(ap); } /* * error - print a message and exit */ -static void +static void __attribute__((__format__(__printf__, 1, 2))) error( const char *fmt, - const char *st1, - const char *st2 + ... ) { - warning(fmt, st1, st2); + va_list ap; + va_start(ap, fmt); + vwarning(fmt, ap); + va_end(ap); exit(1); } @@ -1974,26 +1919,28 @@ getkeyid( const char *keyprompt ) { - register char *p; - register int c; + int c; FILE *fi; char pbuf[20]; + size_t i; + size_t ilim; #ifndef SYS_WINNT if ((fi = fdopen(open("/dev/tty", 2), "r")) == NULL) #else - if ((fi = _fdopen((int)GetStdHandle(STD_INPUT_HANDLE), "r")) == NULL) + if ((fi = _fdopen(open("CONIN$", _O_TEXT), "r")) == NULL) #endif /* SYS_WINNT */ fi = stdin; - else + else setbuf(fi, (char *)NULL); fprintf(stderr, "%s", keyprompt); fflush(stderr); - for (p=pbuf; (c = getc(fi))!='\n' && c!=EOF;) { - if (p < &pbuf[18]) - *p++ = (char) c; - } - *p = '\0'; + for (i = 0, ilim = COUNTOF(pbuf) - 1; + i < ilim && (c = getc(fi)) != '\n' && c != EOF; + ) + pbuf[i++] = (char)c; + pbuf[i] = '\0'; if (fi != stdin) - fclose(fi); - return (u_int32)atoi(pbuf); + fclose(fi); + + return (u_long) atoi(pbuf); } diff --git a/contrib/ntp/ntpdc/ntpdc.h b/contrib/ntp/ntpdc/ntpdc.h index 785c31242..6da4a5cb7 100644 --- a/contrib/ntp/ntpdc/ntpdc.h +++ b/contrib/ntp/ntpdc/ntpdc.h @@ -34,7 +34,7 @@ typedef struct { char *string; long ival; u_long uval; - struct sockaddr_storage netnum; + sockaddr_u netnum; } arg_v; /* @@ -43,7 +43,7 @@ typedef struct { struct parse { char *keyword; arg_v argval[MAXARGS + MOREARGS]; - int nargs; + size_t nargs; }; /* @@ -53,7 +53,7 @@ struct parse { */ struct xcmd { const char *keyword; /* command key word */ - void (*handler) P((struct parse *, FILE *)); /* command handler */ + void (*handler) (struct parse *, FILE *); /* command handler */ u_char arg[MAXARGS]; /* descriptors for arguments */ const char *desc[MAXARGS]; /* descriptions for arguments */ const char *comment; @@ -63,5 +63,5 @@ extern int impl_ver; extern int showhostnames; extern int s_port; -extern int doquery P((int, int, int, int, int, char *, int *, int *, char **, int, int)); -extern char * nntohost P((struct sockaddr_storage *)); +extern int doquery (int, int, int, int, int, char *, int *, int *, char **, int, int); +extern const char * nntohost (sockaddr_u *); diff --git a/contrib/ntp/ntpdc/ntpdc.html b/contrib/ntp/ntpdc/ntpdc.html new file mode 100644 index 000000000..cc552cae3 --- /dev/null +++ b/contrib/ntp/ntpdc/ntpdc.html @@ -0,0 +1,515 @@ + + +ntpdc: NTPD Control User's Manual + + + + + + + + + +

      ntpdc: NTPD Control User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      ntpdc: NTPD Control User Manual

      + +

      This document describes the use of the NTP Project's ntpdc program, +that can be used to query a Network Time Protocol (NTP) server and +display the time offset of the system clock relative to the server +clock. Run as root, it can correct the system clock to this offset as +well. It can be run as an interactive command or from a cron job. + +

      This document applies to version 4.2.8p4 of ntpdc. + +

      The program implements the SNTP protocol as defined by RFC 5905, the NTPv4 +IETF specification. + +

      +

      Short Contents

      + +
      + + + +
      +


      + +
      +
      + + +

      Description

      + +

      By default, ntpdc writes the local data and time (i.e., not UTC) to the +standard output in the format: + +

           1996-10-15 20:17:25.123 (+0800) +4.567 +/- 0.089 secs
      +
      +

      where +YYYY-MM-DD HH:MM:SS.SUBSEC is the local date and time, +(+0800) is the local timezone adjustment (so we would add 8 hours and 0 minutes to convert the reported local time to UTC), +and +the +4.567 +/- 0.089 secs indicates the time offset and +error bound of the system clock relative to the server clock. + +

      +


      + +
      +
      + +

      Invoking ntpdc

      + +

      + +

      ntpdc +is deprecated. +Please use +ntpq(1ntpqmdoc) instead - it can do everything +ntpdc +used to do, and it does so using a much more sane interface. + +

      ntpdc +is a utility program used to query +ntpd(1ntpdmdoc) +about its +current state and to request changes in that state. +It uses NTP mode 7 control message formats described in the source code. +The program may +be run either in interactive mode or controlled using command line +arguments. +Extensive state and statistics information is available +through the +ntpdc +interface. +In addition, nearly all the +configuration options which can be specified at startup using +ntpd's configuration file may also be specified at run time using +ntpdc + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntpdc program. +This software is released under the NTP license, <http://ntp.org/license>. + +

      + +
      +


      +Next: , +Up: ntpdc Invocation +
      +
      + +

      ntpdc help/usage (--help)

      + +

      +This is the automatically generated usage text for ntpdc. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      ntpdc - vendor-specific NTPD control program - Ver. 4.2.8p4
      +Usage:  ntpdc [ -<flag> [<val>] | --<name>[{=| }<val>] ]... [ host ...]
      +  Flg Arg Option-Name    Description
      +   -4 no  ipv4           Force IPv4 DNS name resolution
      +                                - prohibits the option 'ipv6'
      +   -6 no  ipv6           Force IPv6 DNS name resolution
      +                                - prohibits the option 'ipv4'
      +   -c Str command        run a command and exit
      +                                - may appear multiple times
      +   -d no  debug-level    Increase debug verbosity level
      +                                - may appear multiple times
      +   -D Num set-debug-level Set the debug verbosity level
      +                                - may appear multiple times
      +   -i no  interactive    Force ntpq to operate in interactive mode
      +                                - prohibits these options:
      +                                command
      +                                listpeers
      +                                peers
      +                                showpeers
      +   -l no  listpeers      Print a list of the peers
      +                                - prohibits the option 'command'
      +   -n no  numeric        numeric host addresses
      +   -p no  peers          Print a list of the peers
      +                                - prohibits the option 'command'
      +   -s no  showpeers      Show a list of the peers
      +                                - prohibits the option 'command'
      +      opt version        output version information and exit
      +   -? no  help           display extended usage information and exit
      +   -! no  more-help      extended usage information passed thru pager
      +   -> opt save-opts      save the option state to a config file
      +   -< Str load-opts      load options from a config file
      +                                - disabled as '--no-load-opts'
      +                                - may appear multiple times
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      +
      +The following option preset mechanisms are supported:
      + - reading file $HOME/.ntprc
      + - reading file ./.ntprc
      + - examining environment variables named NTPDC_*
      +
      +Please send bug reports to:  <http://bugs.ntp.org, bugs@ntp.org>
      +
      +
      +


      +Next: , +Previous: ntpdc usage, +Up: ntpdc Invocation +
      +
      + +

      ipv4 option (-4)

      + +

      +This is the “force ipv4 dns name resolution” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +ipv6. +
      + +

      Force DNS resolution of following host names on the command line +to the IPv4 namespace. +

      +


      +Next: , +Previous: ntpdc ipv4, +Up: ntpdc Invocation +
      +
      + +

      ipv6 option (-6)

      + +

      +This is the “force ipv6 dns name resolution” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +ipv4. +
      + +

      Force DNS resolution of following host names on the command line +to the IPv6 namespace. +

      +


      +Next: , +Previous: ntpdc ipv6, +Up: ntpdc Invocation +
      +
      + +

      command option (-c)

      + +

      +This is the “run a command and exit” option. +This option takes a string argument cmd. + +

      This option has some usage constraints. It: +

        +
      • may appear an unlimited number of times. +
      + +

      The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +

      +


      +Next: , +Previous: ntpdc command, +Up: ntpdc Invocation +
      +
      + +

      interactive option (-i)

      + +

      +This is the “force ntpq to operate in interactive mode” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +command, listpeers, peers, showpeers. +
      + +

      Force ntpq to operate in interactive mode. Prompts will be written +to the standard output and commands read from the standard input. +

      +


      +Next: , +Previous: ntpdc interactive, +Up: ntpdc Invocation +
      +
      + +

      listpeers option (-l)

      + +

      +This is the “print a list of the peers” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +command. +
      + +

      Print a list of the peers known to the server as well as a summary of +their state. This is equivalent to the 'listpeers' interactive command. +

      +


      +Next: , +Previous: ntpdc listpeers, +Up: ntpdc Invocation +
      +
      + +

      numeric option (-n)

      + +

      +This is the “numeric host addresses” option. +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +

      +


      +Next: , +Previous: ntpdc numeric, +Up: ntpdc Invocation +
      +
      + +

      peers option (-p)

      + +

      +This is the “print a list of the peers” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +command. +
      + +

      Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +

      +


      +Next: , +Previous: ntpdc peers, +Up: ntpdc Invocation +
      +
      + +

      showpeers option (-s)

      + +

      +This is the “show a list of the peers” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +command. +
      + +

      Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'dmpeers' interactive command. + +

      +


      +Next: , +Previous: ntpdc showpeers, +Up: ntpdc Invocation +
      +
      + +

      presetting/configuring ntpdc

      + +

      Any option that is not marked as not presettable may be preset by +loading values from configuration ("rc" or "ini") files, and values from environment variables named NTPDC and NTPDC_<OPTION_NAME>. <OPTION_NAME> must be one of +the options listed above in upper case and segmented with underscores. +The NTPDC variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + +

      libopts will search in 2 places for configuration files: +

        +
      • $HOME +
      • $PWD +
      + The environment variables HOME, and PWD +are expanded and replaced when ntpdc runs. +For any of these that are plain files, they are simply processed. +For any that are directories, then a file named .ntprc is searched for +within that directory and processed. + +

      Configuration files may be in a wide variety of formats. +The basic format is an option name followed by a value (argument) on the +same line. Values may be separated from the option name with a colon, +equal sign or simply white space. Values may be continued across multiple +lines by escaping the newline with a backslash. + +

      Multiple programs may also share the same initialization file. +Common options are collected at the top, followed by program specific +segments. The segments are separated by lines like: +

          [NTPDC]
      +
      +

      or by +

          <?program ntpdc>
      +
      +

      Do not mix these styles within one configuration file. + +

      Compound values and carefully constructed string values may also be +specified using XML syntax: +

          <option-name>
      +       <sub-opt>...&lt;...&gt;...</sub-opt>
      +    </option-name>
      +
      +

      yielding an option-name.sub-opt string value of +

          "...<...>..."
      +
      +

      AutoOpts does not track suboptions. You simply note that it is a +hierarchicly valued option. AutoOpts does provide a means for searching +the associated name/value pair list (see: optionFindValue). + +

      The command line options relating to configuration and/or usage help are: + +

      version (-)
      + +

      Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +

      +
      version
      Only print the version. This is the default. +
      copyright
      Name the copyright usage licensing terms. +
      verbose
      Print the full copyright usage licensing terms. +
      + +
      +


      +Next: , +Previous: ntpdc config, +Up: ntpdc Invocation +
      +
      + +

      ntpdc exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      66 (EX_NOINPUT)
      A specified configuration file could not be loaded. +
      70 (EX_SOFTWARE)
      libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +
      +
      +


      +Next: , +Previous: ntpdc exit status, +Up: ntpdc Invocation +
      +
      + +

      ntpdc Usage

      + +
      +


      +Next: , +Previous: ntpdc Usage, +Up: ntpdc Invocation +
      +
      + +

      ntpdc See Also

      + +
      +


      +Next: , +Previous: ntpdc See Also, +Up: ntpdc Invocation +
      +
      + +

      ntpdc Authors

      + +
      +


      +Previous: ntpdc Authors, +Up: ntpdc Invocation +
      +
      + +

      ntpdc Bugs

      + +
      +


      + +
      +
      + + +

      Usage

      + +

      The simplest use of this program is as an unprivileged command to +check the current time, offset, and error in the local clock. +For example: + +

          ntpdc ntpserver.somewhere
      +
      +

      With suitable privilege, it can be run as a command or in a +cron job to reset the local clock from a reliable server, like +the ntpdate and rdate commands. +For example: + +

          ntpdc -a ntpserver.somewhere
      +
      + + diff --git a/contrib/ntp/ntpdc/ntpdc.man.in b/contrib/ntp/ntpdc/ntpdc.man.in new file mode 100644 index 000000000..f5df74457 --- /dev/null +++ b/contrib/ntp/ntpdc/ntpdc.man.in @@ -0,0 +1,874 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpdc @NTPDC_MS@ "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-Gvay7L/ag-Svaq6L) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:51 PM by AutoGen 5.18.5 +.\" From the definitions ntpdc-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpdc\fP +\- vendor-specific NTPD control program +.SH SYNOPSIS +\f\*[B-Font]ntpdc\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[ host ...] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntpdc\fP +is deprecated. +Please use +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] instead \- it can do everything +\f\*[B-Font]ntpdc\fP +used to do, and it does so using a much more sane interface. +.sp \n(Ppu +.ne 2 + +\f\*[B-Font]ntpdc\fP +is a utility program used to query +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +about its +current state and to request changes in that state. +It uses NTP mode 7 control message formats described in the source code. +The program may +be run either in interactive mode or controlled using command line +arguments. +Extensive state and statistics information is available +through the +\f\*[B-Font]ntpdc\fP +interface. +In addition, nearly all the +configuration options which can be specified at startup using +ntpd's configuration file may also be specified at run time using +\f\*[B-Font]ntpdc\fP. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.TP +.NOP \f\*[B-Font]\-6\f[], \f\*[B-Font]\-\-ipv6\f[] +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.TP +.NOP \f\*[B-Font]\-c\f[] \f\*[I-Font]cmd\f[], \f\*[B-Font]\-\-command\f[]=\f\*[I-Font]cmd\f[] +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.TP +.NOP \f\*[B-Font]\-d\f[], \f\*[B-Font]\-\-debug\-level\f[] +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-D\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-set\-debug\-level\f[]=\f\*[I-Font]number\f[] +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.TP +.NOP \f\*[B-Font]\-i\f[], \f\*[B-Font]\-\-interactive\f[] +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, listpeers, peers, showpeers. +.sp +Force ntpq to operate in interactive mode. Prompts will be written +to the standard output and commands read from the standard input. +.TP +.NOP \f\*[B-Font]\-l\f[], \f\*[B-Font]\-\-listpeers\f[] +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary of +their state. This is equivalent to the 'listpeers' interactive command. +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-numeric\f[] +numeric host addresses. +.sp +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-peers\f[] +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.TP +.NOP \f\*[B-Font]\-s\f[], \f\*[B-Font]\-\-showpeers\f[] +Show a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'dmpeers' interactive command. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\->\f[] [\f\*[I-Font]cfgfile\f[]], \f\*[B-Font]\-\-save-opts\f[] [=\f\*[I-Font]cfgfile\f[]] +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.TP +.NOP \f\*[B-Font]\-<\f[] \f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-load-opts\f[]=\f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-no-load-opts\f[] +Load options from \fIcfgfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early, +out of order. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPDC_\fP or \fBNTPDC\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.SH USAGE +If one or more request options are included on the command line +when +\f\*[B-Font]ntpdc\fP +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +\f\*[B-Font]ntpdc\fP +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +\f\*[B-Font]ntpdc\fP +utility will prompt for +commands if the standard input is a terminal device. +.sp \n(Ppu +.ne 2 + +The +\f\*[B-Font]ntpdc\fP +utility uses NTP mode 7 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +\f\*[B-Font]ntpdc\fP +utility makes +no attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +.sp \n(Ppu +.ne 2 + +The operation of +\f\*[B-Font]ntpdc\fP +are specific to the particular +implementation of the +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +daemon and can be expected to +work only with this and maybe some previous versions of the daemon. +Requests from a remote +\f\*[B-Font]ntpdc\fP +utility which affect the +state of the local server must be authenticated, which requires +both the remote program and local server share a common key and key +identifier. +.sp \n(Ppu +.ne 2 + +Note that in contexts where a host name is expected, a +\f\*[B-Font]\-4\f[] +qualifier preceding the host name forces DNS resolution to the IPv4 namespace, +while a +\f\*[B-Font]\-6\f[] +qualifier forces DNS resolution to the IPv6 namespace. +Specifying a command line option other than +\f\*[B-Font]\-i\f[] +or +\f\*[B-Font]\-n\f[] +will cause the specified query (queries) to be sent to +the indicated host(s) immediately. +Otherwise, +\f\*[B-Font]ntpdc\fP +will +attempt to read interactive format commands from the standard +input. +.SS "Interactive Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +The output of a +command is normally sent to the standard output, but optionally the +output of individual commands may be sent to a file by appending a +\[oq]\&>\[cq], +followed by a file name, to the command line. +.sp \n(Ppu +.ne 2 + +A number of interactive format commands are executed entirely +within the +\f\*[B-Font]ntpdc\fP +utility itself and do not result in NTP +mode 7 requests being sent to a server. +These are described +following. +.TP 7 +.NOP \f\*[B-Font]\&?\f[] \f\*[I-Font]command_keyword\f[] +.TP 7 +.NOP \f\*[B-Font]help\f[] \f\*[I-Font]command_keyword\f[] +A +\[oq]\f\*[B-Font]\&?\f[]\[cq] +will print a list of all the command +keywords known to this incarnation of +\f\*[B-Font]ntpdc\fP. +A +\[oq]\f\*[B-Font]\&?\f[]\[cq] +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +\fCntpq\f[]\fR(@NTPQ_MS@)\f[] +than this manual +page. +.TP 7 +.NOP \f\*[B-Font]delay\f[] \f\*[I-Font]milliseconds\f[] +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.TP 7 +.NOP \f\*[B-Font]host\f[] \f\*[I-Font]hostname\f[] +Set the host to which future queries will be sent. +Hostname may +be either a host name or a numeric address. +.TP 7 +.NOP \f\*[B-Font]hostnames\f[] [\f\*[B-Font]yes\f[] | \f\*[B-Font]no\f[]] +If +\f\*[B-Font]yes\f[] +is specified, host names are printed in +information displays. +If +\f\*[B-Font]no\f[] +is specified, numeric +addresses are printed instead. +The default is +\f\*[B-Font]yes\f[], +unless +modified using the command line +\f\*[B-Font]\-n\f[] +switch. +.TP 7 +.NOP \f\*[B-Font]keyid\f[] \f\*[I-Font]keyid\f[] +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to a key number the server has been configured to use for this +purpose. +.TP 7 +.NOP \f\*[B-Font]quit\f[] +Exit +\f\*[B-Font]ntpdc\fP. +.TP 7 +.NOP \f\*[B-Font]passwd\f[] +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.TP 7 +.NOP \f\*[B-Font]timeout\f[] \f\*[I-Font]milliseconds\f[] +Specify a timeout period for responses to server queries. +The +default is about 8000 milliseconds. +Note that since +\f\*[B-Font]ntpdc\fP +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.PP +.SS "Control Message Commands" +Query commands result in NTP mode 7 packets containing requests for +information being sent to the server. +These are read-only commands +in that they make no modification of the server configuration +state. +.TP 7 +.NOP \f\*[B-Font]listpeers\f[] +Obtains and prints a brief list of the peers for which the +server is maintaining state. +These should include all configured +peer associations as well as those peers whose stratum is such that +they are considered by the server to be possible future +synchronization candidates. +.TP 7 +.NOP \f\*[B-Font]peers\f[] +Obtains a list of peers for which the server is maintaining +state, along with a summary of that state. +Summary information +includes the address of the remote peer, the local interface +address (0.0.0.0 if a local address has yet to be determined), the +stratum of the remote peer (a stratum of 16 indicates the remote +peer is unsynchronized), the polling interval, in seconds, the +reachability register, in octal, and the current estimated delay, +offset and dispersion of the peer, all in seconds. +.sp \n(Ppu +.ne 2 + +The character in the left margin indicates the mode this peer +entry is operating in. +A +\[oq]\&+\[cq] +denotes symmetric active, a +\[oq]\&-\[cq] +indicates symmetric passive, a +\[oq]\&=\[cq] +means the +remote server is being polled in client mode, a +\[oq]\&^\[cq] +indicates that the server is broadcasting to this address, a +\[oq]\&~\[cq] +denotes that the remote peer is sending broadcasts and a +\[oq]\&~\[cq] +denotes that the remote peer is sending broadcasts and a +\[oq]\&*\[cq] +marks the peer the server is currently synchronizing +to. +.sp \n(Ppu +.ne 2 + +The contents of the host field may be one of four forms. +It may +be a host name, an IP address, a reference clock implementation +name with its parameter or +\fBREFCLK\f[]\fR()\f[] +On +\f\*[B-Font]hostnames\f[] +\f\*[B-Font]no\f[] +only IP-addresses +will be displayed. +.TP 7 +.NOP \f\*[B-Font]dmpeers\f[] +A slightly different peer summary list. +Identical to the output +of the +\f\*[B-Font]peers\f[] +command, except for the character in the +leftmost column. +Characters only appear beside peers which were +included in the final stage of the clock selection algorithm. +A +\[oq]\&.\[cq] +indicates that this peer was cast off in the falseticker +detection, while a +\[oq]\&+\[cq] +indicates that the peer made it +through. +A +\[oq]\&*\[cq] +denotes the peer the server is currently +synchronizing with. +.TP 7 +.NOP \f\*[B-Font]showpeer\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]...\f[]] +Shows a detailed display of the current peer variables for one +or more peers. +Most of these values are described in the NTP +Version 2 specification. +.TP 7 +.NOP \f\*[B-Font]pstats\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]...\f[]] +Show per-peer statistic counters associated with the specified +peer(s). +.TP 7 +.NOP \f\*[B-Font]clockstat\f[] \f\*[I-Font]clock_peer_address\f[] [\f\*[I-Font]...\f[]] +Obtain and print information concerning a peer clock. +The +values obtained provide information on the setting of fudge factors +and other clock performance information. +.TP 7 +.NOP \f\*[B-Font]kerninfo\f[] +Obtain and print kernel phase-lock loop operating parameters. +This information is available only if the kernel has been specially +modified for a precision timekeeping function. +.TP 7 +.NOP \f\*[B-Font]loopinfo\f[] [\f\*[B-Font]oneline\f[] | \f\*[B-Font]multiline\f[]] +Print the values of selected loop filter variables. +The loop +filter is the part of NTP which deals with adjusting the local +system clock. +The +\[oq]offset\[cq] +is the last offset given to the +loop filter by the packet processing code. +The +\[oq]frequency\[cq] +is the frequency error of the local clock in parts-per-million +(ppm). +The +\[oq]time_const\[cq] +controls the stiffness of the +phase-lock loop and thus the speed at which it can adapt to +oscillator drift. +The +\[oq]watchdog timer\[cq] +value is the number +of seconds which have elapsed since the last sample offset was +given to the loop filter. +The +\f\*[B-Font]oneline\f[] +and +\f\*[B-Font]multiline\f[] +options specify the format in which this +information is to be printed, with +\f\*[B-Font]multiline\f[] +as the +default. +.TP 7 +.NOP \f\*[B-Font]sysinfo\f[] +Print a variety of system state variables, i.e., state related +to the local server. +All except the last four lines are described +in the NTP Version 3 specification, RFC-1305. +.sp \n(Ppu +.ne 2 + +The +\[oq]system flags\[cq] +show various system flags, some of +which can be set and cleared by the +\f\*[B-Font]enable\f[] +and +\f\*[B-Font]disable\f[] +configuration commands, respectively. +These are +the +\f\*[B-Font]auth\f[], +\f\*[B-Font]bclient\f[], +\f\*[B-Font]monitor\f[], +\f\*[B-Font]pll\f[], +\f\*[B-Font]pps\f[] +and +\f\*[B-Font]stats\f[] +flags. +See the +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +documentation for the meaning of these flags. +There +are two additional flags which are read only, the +\f\*[B-Font]kernel_pll\f[] +and +\f\*[B-Font]kernel_pps\f[]. +These flags indicate +the synchronization status when the precision time kernel +modifications are in use. +The +\[oq]kernel_pll\[cq] +indicates that +the local clock is being disciplined by the kernel, while the +\[oq]kernel_pps\[cq] +indicates the kernel discipline is provided by the PPS +signal. +.sp \n(Ppu +.ne 2 + +The +\[oq]stability\[cq] +is the residual frequency error remaining +after the system frequency correction is applied and is intended for +maintenance and debugging. +In most architectures, this value will +initially decrease from as high as 500 ppm to a nominal value in +the range .01 to 0.1 ppm. +If it remains high for some time after +starting the daemon, something may be wrong with the local clock, +or the value of the kernel variable +\fIkern.clockrate.tick\f[] +may be +incorrect. +.sp \n(Ppu +.ne 2 + +The +\[oq]broadcastdelay\[cq] +shows the default broadcast delay, +as set by the +\f\*[B-Font]broadcastdelay\f[] +configuration command. +.sp \n(Ppu +.ne 2 + +The +\[oq]authdelay\[cq] +shows the default authentication delay, +as set by the +\f\*[B-Font]authdelay\f[] +configuration command. +.TP 7 +.NOP \f\*[B-Font]sysstats\f[] +Print statistics counters maintained in the protocol +module. +.TP 7 +.NOP \f\*[B-Font]memstats\f[] +Print statistics counters related to memory allocation +code. +.TP 7 +.NOP \f\*[B-Font]iostats\f[] +Print statistics counters maintained in the input-output +module. +.TP 7 +.NOP \f\*[B-Font]timerstats\f[] +Print statistics counters maintained in the timer/event queue +support code. +.TP 7 +.NOP \f\*[B-Font]reslist\f[] +Obtain and print the server's restriction list. +This list is +(usually) printed in sorted order and may help to understand how +the restrictions are applied. +.TP 7 +.NOP \f\*[B-Font]monlist\f[] [\f\*[I-Font]version\f[]] +Obtain and print traffic counts collected and maintained by the +monitor facility. +The version number should not normally need to be +specified. +.TP 7 +.NOP \f\*[B-Font]clkbug\f[] \f\*[I-Font]clock_peer_address\f[] [\f\*[I-Font]...\f[]] +Obtain debugging information for a reference clock driver. +This +information is provided only by some clock drivers and is mostly +undecodable without a copy of the driver source in hand. +.PP +.SS "Runtime Configuration Requests" +All requests which cause state changes in the server are +authenticated by the server using a configured NTP key (the +facility can also be disabled by the server by not configuring a +key). +The key number and the corresponding key must also be made +known to +\f\*[B-Font]ntpdc\fP. +This can be done using the +\f\*[B-Font]keyid\f[] +and +\f\*[B-Font]passwd\f[] +commands, the latter of which will prompt at the terminal for a +password to use as the encryption key. +You will also be prompted +automatically for both the key number and password the first time a +command which would result in an authenticated request to the +server is given. +Authentication not only provides verification that +the requester has permission to make such changes, but also gives +an extra degree of protection again transmission errors. +.sp \n(Ppu +.ne 2 + +Authenticated requests always include a timestamp in the packet +data, which is included in the computation of the authentication +code. +This timestamp is compared by the server to its receive time +stamp. +If they differ by more than a small amount the request is +rejected. +This is done for two reasons. +First, it makes simple +replay attacks on the server, by someone who might be able to +overhear traffic on your LAN, much more difficult. +Second, it makes +it more difficult to request configuration changes to your server +from topologically remote hosts. +While the reconfiguration facility +will work well with a server on the local host, and may work +adequately between time-synchronized hosts on the same LAN, it will +work very poorly for more distant hosts. +As such, if reasonable +passwords are chosen, care is taken in the distribution and +protection of keys and appropriate source address restrictions are +applied, the run time reconfiguration facility should provide an +adequate level of security. +.sp \n(Ppu +.ne 2 + +The following commands all make authenticated requests. +.TP 7 +.NOP \f\*[B-Font]addpeer\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]keyid\f[]] [\f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] +Add a configured peer association at the given address and +operating in symmetric active mode. +Note that an existing +association with the same peer may be deleted when this command is +executed, or may simply be converted to conform to the new +configuration, as appropriate. +If the optional +\f\*[I-Font]keyid\f[] +is a +nonzero integer, all outgoing packets to the remote server will +have an authentication field attached encrypted with this key. +If +the value is 0 (or not given) no authentication will be done. +The +\f\*[I-Font]version\f[] +can be 1, 2 or 3 and defaults to 3. +The +\f\*[B-Font]prefer\f[] +keyword indicates a preferred peer (and thus will +be used primarily for clock synchronisation if possible). +The +preferred peer also determines the validity of the PPS signal \- if +the preferred peer is suitable for synchronisation so is the PPS +signal. +.TP 7 +.NOP \f\*[B-Font]addserver\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]keyid\f[]] [\f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] +Identical to the addpeer command, except that the operating +mode is client. +.TP 7 +.NOP \f\*[B-Font]broadcast\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]keyid\f[]] [\f\*[I-Font]version\f[]] [\f\*[B-Font]prefer\f[]] +Identical to the addpeer command, except that the operating +mode is broadcast. +In this case a valid key identifier and key are +required. +The +\f\*[I-Font]peer_address\f[] +parameter can be the broadcast +address of the local network or a multicast group address assigned +to NTP. +If a multicast address, a multicast-capable kernel is +required. +.TP 7 +.NOP \f\*[B-Font]unconfig\f[] \f\*[I-Font]peer_address\f[] [\f\*[I-Font]...\f[]] +This command causes the configured bit to be removed from the +specified peer(s). +In many cases this will cause the peer +association to be deleted. +When appropriate, however, the +association may persist in an unconfigured mode if the remote peer +is willing to continue on in this fashion. +.TP 7 +.NOP \f\*[B-Font]fudge\f[] \f\*[I-Font]peer_address\f[] [\f\*[B-Font]time1\f[]] [\f\*[B-Font]time2\f[]] [\f\*[I-Font]stratum\f[]] [\f\*[I-Font]refid\f[]] +This command provides a way to set certain data for a reference +clock. +See the source listing for further information. +.TP 7 +.NOP \f\*[B-Font]enable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]pps\f[] | \f\*[B-Font]stats\f[]] +.TP 7 +.NOP \f\*[B-Font]disable\f[] [\f\*[B-Font]auth\f[] | \f\*[B-Font]bclient\f[] | \f\*[B-Font]calibrate\f[] | \f\*[B-Font]kernel\f[] | \f\*[B-Font]monitor\f[] | \f\*[B-Font]ntp\f[] | \f\*[B-Font]pps\f[] | \f\*[B-Font]stats\f[]] +These commands operate in the same way as the +\f\*[B-Font]enable\f[] +and +\f\*[B-Font]disable\f[] +configuration file commands of +\fCntpd\f[]\fR(@NTPD_MS@)\f[]. +.RS +.TP 7 +.NOP \f\*[B-Font]auth\f[] +Enables the server to synchronize with unconfigured peers only +if the peer has been correctly authenticated using either public key +or private key cryptography. +The default for this flag is enable. +.TP 7 +.NOP \f\*[B-Font]bclient\f[] +Enables the server to listen for a message from a broadcast or +multicast server, as in the multicastclient command with +default address. +The default for this flag is disable. +.TP 7 +.NOP \f\*[B-Font]calibrate\f[] +Enables the calibrate feature for reference clocks. +The default for this flag is disable. +.TP 7 +.NOP \f\*[B-Font]kernel\f[] +Enables the kernel time discipline, if available. +The default for this flag is enable if support is available, otherwise disable. +.TP 7 +.NOP \f\*[B-Font]monitor\f[] +Enables the monitoring facility. +See the documentation here about the +\f\*[B-Font]monlist\f[] +command or further information. +The default for this flag is enable. +.TP 7 +.NOP \f\*[B-Font]ntp\f[] +Enables time and frequency discipline. +In effect, this switch opens and closes the feedback loop, +which is useful for testing. +The default for this flag is enable. +.TP 7 +.NOP \f\*[B-Font]pps\f[] +Enables the pulse-per-second (PPS) signal when frequency +and time is disciplined by the precision time kernel modifications. +See the +"A Kernel Model for Precision Timekeeping" +(available as part of the HTML documentation +provided in +\fI/usr/share/doc/ntp\f[]) +page for further information. +The default for this flag is disable. +.TP 7 +.NOP \f\*[B-Font]stats\f[] +Enables the statistics facility. +See the +\fIMonitoring\f[] \fIOptions\f[] +section of +\fCntp.conf\f[]\fR(5)\f[] +for further information. +The default for this flag is disable. +.RE +.TP 7 +.NOP \f\*[B-Font]restrict\f[] \f\*[I-Font]address\f[] \f\*[I-Font]mask\f[] \f\*[I-Font]flag\f[] [\f\*[I-Font]...\f[]] +This command operates in the same way as the +\f\*[B-Font]restrict\f[] +configuration file commands of +\fCntpd\f[]\fR(@NTPD_MS@)\f[]. +.TP 7 +.NOP \f\*[B-Font]unrestrict\f[] \f\*[I-Font]address\f[] \f\*[I-Font]mask\f[] \f\*[I-Font]flag\f[] [\f\*[I-Font]...\f[]] +Unrestrict the matching entry from the restrict list. +.TP 7 +.NOP \f\*[B-Font]delrestrict\f[] \f\*[I-Font]address\f[] \f\*[I-Font]mask\f[] [\f\*[B-Font]ntpport\f[]] +Delete the matching entry from the restrict list. +.TP 7 +.NOP \f\*[B-Font]readkeys\f[] +Causes the current set of authentication keys to be purged and +a new set to be obtained by rereading the keys file (which must +have been specified in the +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +configuration file). +This +allows encryption keys to be changed without restarting the +server. +.TP 7 +.NOP \f\*[B-Font]trustedkey\f[] \f\*[I-Font]keyid\f[] [\f\*[I-Font]...\f[]] +.TP 7 +.NOP \f\*[B-Font]untrustedkey\f[] \f\*[I-Font]keyid\f[] [\f\*[I-Font]...\f[]] +These commands operate in the same way as the +\f\*[B-Font]trustedkey\f[] +and +\f\*[B-Font]untrustedkey\f[] +configuration file +commands of +\fCntpd\f[]\fR(@NTPD_MS@)\f[]. +.TP 7 +.NOP \f\*[B-Font]authinfo\f[] +Returns information concerning the authentication module, +including known keys and counts of encryptions and decryptions +which have been done. +.TP 7 +.NOP \f\*[B-Font]traps\f[] +Display the traps set in the server. +See the source listing for +further information. +.TP 7 +.NOP \f\*[B-Font]addtrap\f[] \f\*[I-Font]address\f[] [\f\*[I-Font]port\f[]] [\f\*[I-Font]interface\f[]] +Set a trap for asynchronous messages. +See the source listing +for further information. +.TP 7 +.NOP \f\*[B-Font]clrtrap\f[] \f\*[I-Font]address\f[] [\f\*[I-Font]port\f[]] [\f\*[I-Font]interface\f[]] +Clear a trap for asynchronous messages. +See the source listing +for further information. +.TP 7 +.NOP \f\*[B-Font]reset\f[] +Clear the statistics counters in various modules of the server. +See the source listing for further information. +.PP +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "SEE ALSO" +\fCntp.conf\f[]\fR(5)\f[], +\fCntpd\f[]\fR(@NTPD_MS@)\f[] +David L. Mills, +\fINetwork Time Protocol (Version 3)\fR, +RFC1305 +.PP + +.SH AUTHORS +The formatting directives in this document came from FreeBSD. +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH BUGS +The +\f\*[B-Font]ntpdc\fP +utility is a crude hack. +Much of the information it shows is +deadly boring and could only be loved by its implementer. +The +program was designed so that new (and temporary) features were easy +to hack in, at great expense to the program's ease of use. +Despite +this, the program is occasionally useful. +.sp \n(Ppu +.ne 2 + +Please report bugs to http://bugs.ntp.org . +.sp \n(Ppu +.ne 2 + +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntpdc\fP +option definitions. diff --git a/contrib/ntp/ntpdc/ntpdc.mdoc.in b/contrib/ntp/ntpdc/ntpdc.mdoc.in new file mode 100644 index 000000000..5a6e29244 --- /dev/null +++ b/contrib/ntp/ntpdc/ntpdc.mdoc.in @@ -0,0 +1,809 @@ +.Dd October 21 2015 +.Dt NTPDC @NTPDC_MS@ User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpdc-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:38:57 PM by AutoGen 5.18.5 +.\" From the definitions ntpdc-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpdc +.Nd vendor-specific NTPD control program +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[ host ...] +.Pp +.Sh DESCRIPTION +.Nm +is deprecated. +Please use +.Xr ntpq @NTPQ_MS@ instead \- it can do everything +.Nm +used to do, and it does so using a much more sane interface. +.Pp +.Nm +is a utility program used to query +.Xr ntpd @NTPD_MS@ +about its +current state and to request changes in that state. +It uses NTP mode 7 control message formats described in the source code. +The program may +be run either in interactive mode or controlled using command line +arguments. +Extensive state and statistics information is available +through the +.Nm +interface. +In addition, nearly all the +configuration options which can be specified at startup using +ntpd's configuration file may also be specified at run time using +.Nm . +.Sh "OPTIONS" +.Bl -tag +.It Fl 4 , Fl \-ipv4 +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.It Fl 6 , Fl \-ipv6 +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.It Fl c Ar cmd , Fl \-command Ns = Ns Ar cmd +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.It Fl d , Fl \-debug\-level +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.It Fl D Ar number , Fl \-set\-debug\-level Ns = Ns Ar number +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.It Fl i , Fl \-interactive +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, listpeers, peers, showpeers. +.sp +Force ntpq to operate in interactive mode. Prompts will be written +to the standard output and commands read from the standard input. +.It Fl l , Fl \-listpeers +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary of +their state. This is equivalent to the 'listpeers' interactive command. +.It Fl n , Fl \-numeric +numeric host addresses. +.sp +Output all host addresses in dotted\-quad numeric format rather than +converting to the canonical host names. +.It Fl p , Fl \-peers +Print a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.It Fl s , Fl \-showpeers +Show a list of the peers. +This option must not appear in combination with any of the following options: +command. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'dmpeers' interactive command. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl > Oo Ar cfgfile Oc , Fl \-save\-opts Oo Ns = Ns Ar cfgfile Oc +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.It Fl < Ar cfgfile , Fl \-load\-opts Ns = Ns Ar cfgfile , Fl \-no\-load\-opts +Load options from \fIcfgfile\fP. +The \fIno\-load\-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no\-load\-opts\fP is handled early, +out of order. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPDC_\fP or \fBNTPDC\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.Sh USAGE +If one or more request options are included on the command line +when +.Nm +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +.Nm +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +.Nm +utility will prompt for +commands if the standard input is a terminal device. +.Pp +The +.Nm +utility uses NTP mode 7 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +.Nm +utility makes +no attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +.Pp +The operation of +.Nm +are specific to the particular +implementation of the +.Xr ntpd @NTPD_MS@ +daemon and can be expected to +work only with this and maybe some previous versions of the daemon. +Requests from a remote +.Nm +utility which affect the +state of the local server must be authenticated, which requires +both the remote program and local server share a common key and key +identifier. +.Pp +Note that in contexts where a host name is expected, a +.Fl 4 +qualifier preceding the host name forces DNS resolution to the IPv4 namespace, +while a +.Fl 6 +qualifier forces DNS resolution to the IPv6 namespace. +Specifying a command line option other than +.Fl i +or +.Fl n +will cause the specified query (queries) to be sent to +the indicated host(s) immediately. +Otherwise, +.Nm +will +attempt to read interactive format commands from the standard +input. +.Ss "Interactive Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +The output of a +command is normally sent to the standard output, but optionally the +output of individual commands may be sent to a file by appending a +.Ql \&> , +followed by a file name, to the command line. +.Pp +A number of interactive format commands are executed entirely +within the +.Nm +utility itself and do not result in NTP +mode 7 requests being sent to a server. +These are described +following. +.Bl -tag -width indent +.It Ic \&? Ar command_keyword +.It Ic help Ar command_keyword +A +.Sq Ic \&? +will print a list of all the command +keywords known to this incarnation of +.Nm . +A +.Sq Ic \&? +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +.Xr ntpq @NTPQ_MS@ +than this manual +page. +.It Ic delay Ar milliseconds +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.It Ic host Ar hostname +Set the host to which future queries will be sent. +Hostname may +be either a host name or a numeric address. +.It Ic hostnames Op Cm yes | Cm no +If +.Cm yes +is specified, host names are printed in +information displays. +If +.Cm no +is specified, numeric +addresses are printed instead. +The default is +.Cm yes , +unless +modified using the command line +.Fl n +switch. +.It Ic keyid Ar keyid +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to a key number the server has been configured to use for this +purpose. +.It Ic quit +Exit +.Nm . +.It Ic passwd +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.It Ic timeout Ar milliseconds +Specify a timeout period for responses to server queries. +The +default is about 8000 milliseconds. +Note that since +.Nm +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.El +.Ss "Control Message Commands" +Query commands result in NTP mode 7 packets containing requests for +information being sent to the server. +These are read\-only commands +in that they make no modification of the server configuration +state. +.Bl -tag -width indent +.It Ic listpeers +Obtains and prints a brief list of the peers for which the +server is maintaining state. +These should include all configured +peer associations as well as those peers whose stratum is such that +they are considered by the server to be possible future +synchronization candidates. +.It Ic peers +Obtains a list of peers for which the server is maintaining +state, along with a summary of that state. +Summary information +includes the address of the remote peer, the local interface +address (0.0.0.0 if a local address has yet to be determined), the +stratum of the remote peer (a stratum of 16 indicates the remote +peer is unsynchronized), the polling interval, in seconds, the +reachability register, in octal, and the current estimated delay, +offset and dispersion of the peer, all in seconds. +.Pp +The character in the left margin indicates the mode this peer +entry is operating in. +A +.Ql \&+ +denotes symmetric active, a +.Ql \&\- +indicates symmetric passive, a +.Ql \&= +means the +remote server is being polled in client mode, a +.Ql \&^ +indicates that the server is broadcasting to this address, a +.Ql \&~ +denotes that the remote peer is sending broadcasts and a +.Ql \&~ +denotes that the remote peer is sending broadcasts and a +.Ql \&* +marks the peer the server is currently synchronizing +to. +.Pp +The contents of the host field may be one of four forms. +It may +be a host name, an IP address, a reference clock implementation +name with its parameter or +.Fn REFCLK "implementation_number" "parameter" . +On +.Ic hostnames +.Cm no +only IP\-addresses +will be displayed. +.It Ic dmpeers +A slightly different peer summary list. +Identical to the output +of the +.Ic peers +command, except for the character in the +leftmost column. +Characters only appear beside peers which were +included in the final stage of the clock selection algorithm. +A +.Ql \&. +indicates that this peer was cast off in the falseticker +detection, while a +.Ql \&+ +indicates that the peer made it +through. +A +.Ql \&* +denotes the peer the server is currently +synchronizing with. +.It Ic showpeer Ar peer_address Oo Ar ... Oc +Shows a detailed display of the current peer variables for one +or more peers. +Most of these values are described in the NTP +Version 2 specification. +.It Ic pstats Ar peer_address Oo Ar ... Oc +Show per\-peer statistic counters associated with the specified +peer(s). +.It Ic clockstat Ar clock_peer_address Oo Ar ... Oc +Obtain and print information concerning a peer clock. +The +values obtained provide information on the setting of fudge factors +and other clock performance information. +.It Ic kerninfo +Obtain and print kernel phase\-lock loop operating parameters. +This information is available only if the kernel has been specially +modified for a precision timekeeping function. +.It Ic loopinfo Op Cm oneline | Cm multiline +Print the values of selected loop filter variables. +The loop +filter is the part of NTP which deals with adjusting the local +system clock. +The +.Sq offset +is the last offset given to the +loop filter by the packet processing code. +The +.Sq frequency +is the frequency error of the local clock in parts\-per\-million +(ppm). +The +.Sq time_const +controls the stiffness of the +phase\-lock loop and thus the speed at which it can adapt to +oscillator drift. +The +.Sq watchdog timer +value is the number +of seconds which have elapsed since the last sample offset was +given to the loop filter. +The +.Cm oneline +and +.Cm multiline +options specify the format in which this +information is to be printed, with +.Cm multiline +as the +default. +.It Ic sysinfo +Print a variety of system state variables, i.e., state related +to the local server. +All except the last four lines are described +in the NTP Version 3 specification, RFC\-1305. +.Pp +The +.Sq system flags +show various system flags, some of +which can be set and cleared by the +.Ic enable +and +.Ic disable +configuration commands, respectively. +These are +the +.Cm auth , +.Cm bclient , +.Cm monitor , +.Cm pll , +.Cm pps +and +.Cm stats +flags. +See the +.Xr ntpd @NTPD_MS@ +documentation for the meaning of these flags. +There +are two additional flags which are read only, the +.Cm kernel_pll +and +.Cm kernel_pps . +These flags indicate +the synchronization status when the precision time kernel +modifications are in use. +The +.Sq kernel_pll +indicates that +the local clock is being disciplined by the kernel, while the +.Sq kernel_pps +indicates the kernel discipline is provided by the PPS +signal. +.Pp +The +.Sq stability +is the residual frequency error remaining +after the system frequency correction is applied and is intended for +maintenance and debugging. +In most architectures, this value will +initially decrease from as high as 500 ppm to a nominal value in +the range .01 to 0.1 ppm. +If it remains high for some time after +starting the daemon, something may be wrong with the local clock, +or the value of the kernel variable +.Va kern.clockrate.tick +may be +incorrect. +.Pp +The +.Sq broadcastdelay +shows the default broadcast delay, +as set by the +.Ic broadcastdelay +configuration command. +.Pp +The +.Sq authdelay +shows the default authentication delay, +as set by the +.Ic authdelay +configuration command. +.It Ic sysstats +Print statistics counters maintained in the protocol +module. +.It Ic memstats +Print statistics counters related to memory allocation +code. +.It Ic iostats +Print statistics counters maintained in the input\-output +module. +.It Ic timerstats +Print statistics counters maintained in the timer/event queue +support code. +.It Ic reslist +Obtain and print the server's restriction list. +This list is +(usually) printed in sorted order and may help to understand how +the restrictions are applied. +.It Ic monlist Op Ar version +Obtain and print traffic counts collected and maintained by the +monitor facility. +The version number should not normally need to be +specified. +.It Ic clkbug Ar clock_peer_address Oo Ar ... Oc +Obtain debugging information for a reference clock driver. +This +information is provided only by some clock drivers and is mostly +undecodable without a copy of the driver source in hand. +.El +.Ss "Runtime Configuration Requests" +All requests which cause state changes in the server are +authenticated by the server using a configured NTP key (the +facility can also be disabled by the server by not configuring a +key). +The key number and the corresponding key must also be made +known to +.Nm . +This can be done using the +.Ic keyid +and +.Ic passwd +commands, the latter of which will prompt at the terminal for a +password to use as the encryption key. +You will also be prompted +automatically for both the key number and password the first time a +command which would result in an authenticated request to the +server is given. +Authentication not only provides verification that +the requester has permission to make such changes, but also gives +an extra degree of protection again transmission errors. +.Pp +Authenticated requests always include a timestamp in the packet +data, which is included in the computation of the authentication +code. +This timestamp is compared by the server to its receive time +stamp. +If they differ by more than a small amount the request is +rejected. +This is done for two reasons. +First, it makes simple +replay attacks on the server, by someone who might be able to +overhear traffic on your LAN, much more difficult. +Second, it makes +it more difficult to request configuration changes to your server +from topologically remote hosts. +While the reconfiguration facility +will work well with a server on the local host, and may work +adequately between time\-synchronized hosts on the same LAN, it will +work very poorly for more distant hosts. +As such, if reasonable +passwords are chosen, care is taken in the distribution and +protection of keys and appropriate source address restrictions are +applied, the run time reconfiguration facility should provide an +adequate level of security. +.Pp +The following commands all make authenticated requests. +.Bl -tag -width indent +.It Xo Ic addpeer Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Add a configured peer association at the given address and +operating in symmetric active mode. +Note that an existing +association with the same peer may be deleted when this command is +executed, or may simply be converted to conform to the new +configuration, as appropriate. +If the optional +.Ar keyid +is a +nonzero integer, all outgoing packets to the remote server will +have an authentication field attached encrypted with this key. +If +the value is 0 (or not given) no authentication will be done. +The +.Ar version +can be 1, 2 or 3 and defaults to 3. +The +.Cm prefer +keyword indicates a preferred peer (and thus will +be used primarily for clock synchronisation if possible). +The +preferred peer also determines the validity of the PPS signal \- if +the preferred peer is suitable for synchronisation so is the PPS +signal. +.It Xo Ic addserver Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Identical to the addpeer command, except that the operating +mode is client. +.It Xo Ic broadcast Ar peer_address +.Op Ar keyid +.Op Ar version +.Op Cm prefer +.Xc +Identical to the addpeer command, except that the operating +mode is broadcast. +In this case a valid key identifier and key are +required. +The +.Ar peer_address +parameter can be the broadcast +address of the local network or a multicast group address assigned +to NTP. +If a multicast address, a multicast\-capable kernel is +required. +.It Ic unconfig Ar peer_address Oo Ar ... Oc +This command causes the configured bit to be removed from the +specified peer(s). +In many cases this will cause the peer +association to be deleted. +When appropriate, however, the +association may persist in an unconfigured mode if the remote peer +is willing to continue on in this fashion. +.It Xo Ic fudge Ar peer_address +.Op Cm time1 +.Op Cm time2 +.Op Ar stratum +.Op Ar refid +.Xc +This command provides a way to set certain data for a reference +clock. +See the source listing for further information. +.It Xo Ic enable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm monitor | Cm ntp | +.Cm pps | Cm stats +.Oc +.Xc +.It Xo Ic disable +.Oo +.Cm auth | Cm bclient | +.Cm calibrate | Cm kernel | +.Cm monitor | Cm ntp | +.Cm pps | Cm stats +.Oc +.Xc +These commands operate in the same way as the +.Ic enable +and +.Ic disable +configuration file commands of +.Xr ntpd @NTPD_MS@ . +.Bl -tag -width indent +.It Cm auth +Enables the server to synchronize with unconfigured peers only +if the peer has been correctly authenticated using either public key +or private key cryptography. +The default for this flag is enable. +.It Cm bclient +Enables the server to listen for a message from a broadcast or +multicast server, as in the multicastclient command with +default address. +The default for this flag is disable. +.It Cm calibrate +Enables the calibrate feature for reference clocks. +The default for this flag is disable. +.It Cm kernel +Enables the kernel time discipline, if available. +The default for this flag is enable if support is available, otherwise disable. +.It Cm monitor +Enables the monitoring facility. +See the documentation here about the +.Cm monlist +command or further information. +The default for this flag is enable. +.It Cm ntp +Enables time and frequency discipline. +In effect, this switch opens and closes the feedback loop, +which is useful for testing. +The default for this flag is enable. +.It Cm pps +Enables the pulse\-per\-second (PPS) signal when frequency +and time is disciplined by the precision time kernel modifications. +See the +.Qq A Kernel Model for Precision Timekeeping +(available as part of the HTML documentation +provided in +.Pa /usr/share/doc/ntp ) +page for further information. +The default for this flag is disable. +.It Cm stats +Enables the statistics facility. +See the +.Sx Monitoring Options +section of +.Xr ntp.conf 5 +for further information. +The default for this flag is disable. +.El +.It Xo Ic restrict Ar address Ar mask +.Ar flag Oo Ar ... Oc +.Xc +This command operates in the same way as the +.Ic restrict +configuration file commands of +.Xr ntpd @NTPD_MS@ . +.It Xo Ic unrestrict Ar address Ar mask +.Ar flag Oo Ar ... Oc +.Xc +Unrestrict the matching entry from the restrict list. +.It Xo Ic delrestrict Ar address Ar mask +.Op Cm ntpport +.Xc +Delete the matching entry from the restrict list. +.It Ic readkeys +Causes the current set of authentication keys to be purged and +a new set to be obtained by rereading the keys file (which must +have been specified in the +.Xr ntpd @NTPD_MS@ +configuration file). +This +allows encryption keys to be changed without restarting the +server. +.It Ic trustedkey Ar keyid Oo Ar ... Oc +.It Ic untrustedkey Ar keyid Oo Ar ... Oc +These commands operate in the same way as the +.Ic trustedkey +and +.Ic untrustedkey +configuration file +commands of +.Xr ntpd @NTPD_MS@ . +.It Ic authinfo +Returns information concerning the authentication module, +including known keys and counts of encryptions and decryptions +which have been done. +.It Ic traps +Display the traps set in the server. +See the source listing for +further information. +.It Xo Ic addtrap Ar address +.Op Ar port +.Op Ar interface +.Xc +Set a trap for asynchronous messages. +See the source listing +for further information. +.It Xo Ic clrtrap Ar address +.Op Ar port +.Op Ar interface +.Xc +Clear a trap for asynchronous messages. +See the source listing +for further information. +.It Ic reset +Clear the statistics counters in various modules of the server. +See the source listing for further information. +.El +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "SEE ALSO" +.Xr ntp.conf 5 , +.Xr ntpd @NTPD_MS@ +.Rs +.%A David L. Mills +.%T Network Time Protocol (Version 3) +.%O RFC1305 +.Re +.Sh AUTHORS +The formatting directives in this document came from FreeBSD. +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh BUGS +The +.Nm +utility is a crude hack. +Much of the information it shows is +deadly boring and could only be loved by its implementer. +The +program was designed so that new (and temporary) features were easy +to hack in, at great expense to the program's ease of use. +Despite +this, the program is occasionally useful. +.Pp +Please report bugs to http://bugs.ntp.org . +.Pp +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntpdc\fP +option definitions. diff --git a/contrib/ntp/ntpdc/ntpdc.texi b/contrib/ntp/ntpdc/ntpdc.texi new file mode 100644 index 000000000..3a828065a --- /dev/null +++ b/contrib/ntp/ntpdc/ntpdc.texi @@ -0,0 +1,88 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntpdc.info +@settitle ntpdc: NTPD Control User's Manual +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of the NTP Project's ntpdc, a program for +controlling ntpd. +@end ifinfo + +@direntry +* ntpdc: (ntpdc). ntpd Control program +@end direntry + +@titlepage +@title ntpdc: NTPD Control User's Manual +@subtitle ntpdc, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, ntpdc Description, (dir), (dir) +@top ntpdc: NTPD Control User Manual + +This document describes the use of the NTP Project's @code{ntpdc} program, +that can be used to query a Network Time Protocol (NTP) server and +display the time offset of the system clock relative to the server +clock. Run as root, it can correct the system clock to this offset as +well. It can be run as an interactive command or from a cron job. + +This document applies to version @value{VERSION} of @code{ntpdc}. + +The program implements the SNTP protocol as defined by RFC 5905, the NTPv4 +IETF specification. + +@shortcontents + +@menu +* ntpdc Description:: Description +* ntpdc Invocation:: Invoking ntpdc +* Usage:: Usage +@end menu + +@node ntpdc Description +@comment node-name, next, previous, up +@section Description + +By default, @code{ntpdc} writes the local data and time (i.e., not UTC) to the +standard output in the format: + +@example +1996-10-15 20:17:25.123 (+0800) +4.567 +/- 0.089 secs +@end example + +where +YYYY-MM-DD HH:MM:SS.SUBSEC is the local date and time, +(+0800) is the local timezone adjustment (so we would add 8 hours and 0 minutes to convert the reported local time to UTC), +and +the +4.567 +/- 0.089 secs indicates the time offset and +error bound of the system clock relative to the server clock. + +@include invoke-ntpdc.texi + +@node Usage +@comment node-name, next, previous, up +@section Usage + +The simplest use of this program is as an unprivileged command to +check the current time, offset, and error in the local clock. +For example: + +@example +ntpdc ntpserver.somewhere +@end example + +With suitable privilege, it can be run as a command or in a +@code{cron} job to reset the local clock from a reliable server, like +the @code{ntpdate} and @code{rdate} commands. +For example: + +@example +ntpdc -a ntpserver.somewhere +@end example diff --git a/contrib/ntp/ntpdc/ntpdc_ops.c b/contrib/ntp/ntpdc/ntpdc_ops.c index e40016b90..be8ffa24a 100644 --- a/contrib/ntp/ntpdc/ntpdc_ops.c +++ b/contrib/ntp/ntpdc/ntpdc_ops.c @@ -1,5 +1,6 @@ /* - * ntpdc_ops.c - subroutines which are called to perform operations by xntpdc + * ntpdc_ops.c - subroutines which are called to perform operations by + * ntpdc */ #ifdef HAVE_CONFIG_H @@ -10,6 +11,7 @@ #include #include "ntpdc.h" +#include "ntp_net.h" #include "ntp_control.h" #include "ntp_refclock.h" #include "ntp_stdlib.h" @@ -19,67 +21,73 @@ # include #endif #if !defined(__bsdi__) && !defined(apollo) +#ifdef HAVE_NETINET_IN_H #include #endif +#endif #include +/* + * utility functions + */ +static int checkitems (int, FILE *); +static int checkitemsize (int, int); +static int check1item (int, FILE *); + /* * Declarations for command handlers in here */ -static int checkitems P((int, FILE *)); -static int checkitemsize P((int, int)); -static int check1item P((int, FILE *)); -static void peerlist P((struct parse *, FILE *)); -static void peers P((struct parse *, FILE *)); -static void doconfig P((struct parse *pcmd, FILE *fp, int mode, int refc)); -static void dmpeers P((struct parse *, FILE *)); -static void dopeers P((struct parse *, FILE *, int)); -static void printpeer P((struct info_peer *, FILE *)); -static void showpeer P((struct parse *, FILE *)); -static void peerstats P((struct parse *, FILE *)); -static void loopinfo P((struct parse *, FILE *)); -static void sysinfo P((struct parse *, FILE *)); -static void sysstats P((struct parse *, FILE *)); -static void iostats P((struct parse *, FILE *)); -static void memstats P((struct parse *, FILE *)); -static void timerstats P((struct parse *, FILE *)); -static void addpeer P((struct parse *, FILE *)); -static void addserver P((struct parse *, FILE *)); -static void addrefclock P((struct parse *, FILE *)); -static void broadcast P((struct parse *, FILE *)); -static void doconfig P((struct parse *, FILE *, int, int)); -static void unconfig P((struct parse *, FILE *)); -static void set P((struct parse *, FILE *)); -static void sys_clear P((struct parse *, FILE *)); -static void doset P((struct parse *, FILE *, int)); -static void reslist P((struct parse *, FILE *)); -static void new_restrict P((struct parse *, FILE *)); -static void unrestrict P((struct parse *, FILE *)); -static void delrestrict P((struct parse *, FILE *)); -static void do_restrict P((struct parse *, FILE *, int)); -static void monlist P((struct parse *, FILE *)); -static void reset P((struct parse *, FILE *)); -static void preset P((struct parse *, FILE *)); -static void readkeys P((struct parse *, FILE *)); -static void trustkey P((struct parse *, FILE *)); -static void untrustkey P((struct parse *, FILE *)); -static void do_trustkey P((struct parse *, FILE *, int)); -static void authinfo P((struct parse *, FILE *)); -static void traps P((struct parse *, FILE *)); -static void addtrap P((struct parse *, FILE *)); -static void clrtrap P((struct parse *, FILE *)); -static void do_addclr_trap P((struct parse *, FILE *, int)); -static void requestkey P((struct parse *, FILE *)); -static void controlkey P((struct parse *, FILE *)); -static void do_changekey P((struct parse *, FILE *, int)); -static void ctlstats P((struct parse *, FILE *)); -static void clockstat P((struct parse *, FILE *)); -static void fudge P((struct parse *, FILE *)); -static void clkbug P((struct parse *, FILE *)); -static void kerninfo P((struct parse *, FILE *)); -static void get_if_stats P((struct parse *, FILE *)); -static void do_if_reload P((struct parse *, FILE *)); +static void peerlist (struct parse *, FILE *); +static void peers (struct parse *, FILE *); +static void doconfig (struct parse *pcmd, FILE *fp, int mode, int refc); +static void dmpeers (struct parse *, FILE *); +static void dopeers (struct parse *, FILE *, int); +static void printpeer (struct info_peer *, FILE *); +static void showpeer (struct parse *, FILE *); +static void peerstats (struct parse *, FILE *); +static void loopinfo (struct parse *, FILE *); +static void sysinfo (struct parse *, FILE *); +static void sysstats (struct parse *, FILE *); +static void iostats (struct parse *, FILE *); +static void memstats (struct parse *, FILE *); +static void timerstats (struct parse *, FILE *); +static void addpeer (struct parse *, FILE *); +static void addserver (struct parse *, FILE *); +static void addrefclock (struct parse *, FILE *); +static void broadcast (struct parse *, FILE *); +static void doconfig (struct parse *, FILE *, int, int); +static void unconfig (struct parse *, FILE *); +static void set (struct parse *, FILE *); +static void sys_clear (struct parse *, FILE *); +static void doset (struct parse *, FILE *, int); +static void reslist (struct parse *, FILE *); +static void new_restrict (struct parse *, FILE *); +static void unrestrict (struct parse *, FILE *); +static void delrestrict (struct parse *, FILE *); +static void do_restrict (struct parse *, FILE *, int); +static void monlist (struct parse *, FILE *); +static void reset (struct parse *, FILE *); +static void preset (struct parse *, FILE *); +static void readkeys (struct parse *, FILE *); +static void trustkey (struct parse *, FILE *); +static void untrustkey (struct parse *, FILE *); +static void do_trustkey (struct parse *, FILE *, int); +static void authinfo (struct parse *, FILE *); +static void traps (struct parse *, FILE *); +static void addtrap (struct parse *, FILE *); +static void clrtrap (struct parse *, FILE *); +static void do_addclr_trap (struct parse *, FILE *, int); +static void requestkey (struct parse *, FILE *); +static void controlkey (struct parse *, FILE *); +static void do_changekey (struct parse *, FILE *, int); +static void ctlstats (struct parse *, FILE *); +static void clockstat (struct parse *, FILE *); +static void fudge (struct parse *, FILE *); +static void clkbug (struct parse *, FILE *); +static void kerninfo (struct parse *, FILE *); +static void get_if_stats (struct parse *, FILE *); +static void do_if_reload (struct parse *, FILE *); /* * Commands we understand. Ntpdc imports this. @@ -136,7 +144,7 @@ struct xcmd opcmds[] = { { "enable", set, { NTP_STR, OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR }, { "auth|bclient|monitor|pll|kernel|stats", "...", "...", "..." }, "set a system flag (auth, bclient, monitor, pll, kernel, stats)" }, - { "disable", sys_clear, { NTP_STR, OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR }, + { "disable", sys_clear, { NTP_STR, OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR }, { "auth|bclient|monitor|pll|kernel|stats", "...", "...", "..." }, "clear a system flag (auth, bclient, monitor, pll, kernel, stats)" }, { "reslist", reslist, {OPT|IP_VERSION, NO, NO, NO }, @@ -159,7 +167,7 @@ struct xcmd opcmds[] = { { "version", "", "", "" }, "display data the server's monitor routines have collected" }, { "reset", reset, { NTP_STR, OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR }, - { "io|sys|mem|timer|auth|allpeers", "...", "...", "..." }, + { "io|sys|mem|timer|auth|ctl|allpeers", "...", "...", "..." }, "reset various subsystem statistics counters" }, { "preset", preset, { NTP_ADD, OPT|NTP_ADD, OPT|NTP_ADD, OPT|NTP_ADD }, { "peer_address", "peer2_addr", "peer3_addr", "peer4_addr" }, @@ -221,6 +229,59 @@ struct xcmd opcmds[] = { */ #define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) +/* + * SET_SS_LEN_IF_PRESENT - used by SET_ADDR, SET_ADDRS macros + */ + +#ifdef ISC_PLATFORM_HAVESALEN +#define SET_SS_LEN_IF_PRESENT(psau) \ + do { \ + (psau)->sa.sa_len = SOCKLEN(psau); \ + } while (0) +#else +#define SET_SS_LEN_IF_PRESENT(psau) do { } while (0) +#endif + +/* + * SET_ADDR - setup address for v4/v6 as needed + */ +#define SET_ADDR(address, v6flag, v4addr, v6addr) \ +do { \ + ZERO(address); \ + if (v6flag) { \ + AF(&(address)) = AF_INET6; \ + SOCK_ADDR6(&(address)) = (v6addr); \ + } else { \ + AF(&(address)) = AF_INET; \ + NSRCADR(&(address)) = (v4addr); \ + } \ + SET_SS_LEN_IF_PRESENT(&(address)); \ +} while (0) + + +/* + * SET_ADDRS - setup source and destination addresses for + * v4/v6 as needed + */ +#define SET_ADDRS(a1, a2, info, a1prefix, a2prefix) \ +do { \ + ZERO(a1); \ + ZERO(a2); \ + if ((info)->v6_flag) { \ + AF(&(a1)) = AF_INET6; \ + AF(&(a2)) = AF_INET6; \ + SOCK_ADDR6(&(a1)) = (info)->a1prefix##6; \ + SOCK_ADDR6(&(a2)) = (info)->a2prefix##6; \ + } else { \ + AF(&(a1)) = AF_INET; \ + AF(&(a2)) = AF_INET; \ + NSRCADR(&(a1)) = (info)->a1prefix; \ + NSRCADR(&(a2)) = (info)->a2prefix; \ + } \ + SET_SS_LEN_IF_PRESENT(&(a1)); \ + SET_SS_LEN_IF_PRESENT(&(a2)); \ +} while (0) + /* * checkitems - utility to print a message if no items were returned @@ -280,7 +341,6 @@ check1item( } - /* * peerlist - get a short list of peers */ @@ -292,7 +352,7 @@ peerlist( ) { struct info_peer_list *plist; - struct sockaddr_storage paddr; + sockaddr_u paddr; int items; int itemsize; int res; @@ -318,17 +378,7 @@ again: return; while (items > 0) { - memset((char *)&paddr, 0, sizeof(paddr)); - if (plist->v6_flag != 0) { - GET_INADDR6(paddr) = plist->addr6; - paddr.ss_family = AF_INET6; - } else { - GET_INADDR(paddr) = plist->addr; - paddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - paddr.ss_len = SOCKLEN(&paddr); -#endif + SET_ADDR(paddr, plist->v6_flag, plist->addr, plist->addr6); if ((pcmd->nargs == 0) || ((pcmd->argval->ival == 6) && (plist->v6_flag != 0)) || ((pcmd->argval->ival == 4) && (plist->v6_flag == 0))) @@ -378,8 +428,8 @@ dopeers( ) { struct info_peer_summary *plist; - struct sockaddr_storage dstadr; - struct sockaddr_storage srcadr; + sockaddr_u dstadr; + sockaddr_u srcadr; int items; int itemsize; int ntp_poll; @@ -440,28 +490,12 @@ again: NTOHL_FP(&(plist->offset), &tempts); ntp_poll = 1<ppoll, plist->hpoll, NTP_MAXPOLL), NTP_MINPOLL); - memset((char *)&dstadr, 0, sizeof(dstadr)); - memset((char *)&srcadr, 0, sizeof(srcadr)); - if (plist->v6_flag != 0) { - GET_INADDR6(dstadr) = plist->dstadr6; - GET_INADDR6(srcadr) = plist->srcadr6; - srcadr.ss_family = AF_INET6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(dstadr) = plist->dstadr; - GET_INADDR(srcadr) = plist->srcadr; - srcadr.ss_family = AF_INET; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - srcadr.ss_len = SOCKLEN(&srcadr); - dstadr.ss_len = SOCKLEN(&dstadr); -#endif + SET_ADDRS(dstadr, srcadr, plist, dstadr, srcadr); if ((pcmd->nargs == 0) || ((pcmd->argval->ival == 6) && (plist->v6_flag != 0)) || ((pcmd->argval->ival == 4) && (plist->v6_flag == 0))) (void) fprintf(fp, - "%c%-15.15s %-15.15s %2d %4d %3o %7.7s %9.9s %7.7s\n", + "%c%-15.15s %-15.15s %2u %4d %3o %7.7s %9.9s %7.7s\n", c, nntohost(&srcadr), stoa(&dstadr), plist->stratum, ntp_poll, plist->reach, fptoa(NTOHS_FP(plist->delay), 5), @@ -473,7 +507,7 @@ again: } /* Convert a refid & stratum (in host order) to a string */ -static char* +static char * refid_string( u_int32 refid, int stratum @@ -482,7 +516,7 @@ refid_string( if (stratum <= 1) { static char junk[5]; junk[4] = 0; - memmove(junk, (char *)&refid, 4); + memcpy(junk, &refid, 4); return junk; } @@ -491,49 +525,56 @@ refid_string( static void print_pflag( - FILE *fp, - u_int32 flags - ) + FILE * fp, + u_int32 flags + ) { - const char *str; + static const char none[] = ""; + static const char comma[] = ","; + const char *dlim; - if (flags == 0) { - (void) fprintf(fp, " none\n"); - } else { - str = ""; - if (flags & INFO_FLAG_SYSPEER) { - (void) fprintf(fp, " system_peer"); - str = ","; - } - if (flags & INFO_FLAG_CONFIG) { - (void) fprintf(fp, "%s config", str); - str = ","; - } - if (flags & INFO_FLAG_REFCLOCK) { - (void) fprintf(fp, "%s refclock", str); - str = ","; - } - if (flags & INFO_FLAG_AUTHENABLE) { - (void) fprintf(fp, "%s auth", str); - str = ","; - } - if (flags & INFO_FLAG_BCLIENT) { - (void) fprintf(fp, "%s bclient", str); - str = ","; - } - if (flags & INFO_FLAG_PREFER) { - (void) fprintf(fp, "%s prefer", str); - str = ","; - } - if (flags & INFO_FLAG_IBURST) { - (void) fprintf(fp, "%s iburst", str); - str = ","; - } - if (flags & INFO_FLAG_BURST) { - (void) fprintf(fp, "%s burst", str); - } - (void) fprintf(fp, "\n"); + if (0 == flags) { + fprintf(fp, " none\n"); + return; + } + dlim = none; + if (flags & INFO_FLAG_SYSPEER) { + fprintf(fp, " system_peer"); + dlim = comma; } + if (flags & INFO_FLAG_CONFIG) { + fprintf(fp, "%s config", dlim); + dlim = comma; + } + if (flags & INFO_FLAG_REFCLOCK) { + fprintf(fp, "%s refclock", dlim); + dlim = comma; + } + if (flags & INFO_FLAG_AUTHENABLE) { + fprintf(fp, "%s auth", dlim); + dlim = comma; + } + if (flags & INFO_FLAG_PREFER) { + fprintf(fp, "%s prefer", dlim); + dlim = comma; + } + if (flags & INFO_FLAG_IBURST) { + fprintf(fp, "%s iburst", dlim); + dlim = comma; + } + if (flags & INFO_FLAG_BURST) { + fprintf(fp, "%s burst", dlim); + dlim = comma; + } + if (flags & INFO_FLAG_SEL_CANDIDATE) { + fprintf(fp, "%s candidate", dlim); + dlim = comma; + } + if (flags & INFO_FLAG_SHORTLIST) { + fprintf(fp, "%s shortlist", dlim); + dlim = comma; + } + fprintf(fp, "\n"); } /* * printpeer - print detail information for a peer @@ -546,25 +587,10 @@ printpeer( { register int i; l_fp tempts; - struct sockaddr_storage srcadr, dstadr; + sockaddr_u srcadr, dstadr; + + SET_ADDRS(dstadr, srcadr, pp, dstadr, srcadr); - memset((char *)&srcadr, 0, sizeof(srcadr)); - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (pp->v6_flag != 0) { - srcadr.ss_family = AF_INET6; - dstadr.ss_family = AF_INET6; - GET_INADDR6(srcadr) = pp->srcadr6; - GET_INADDR6(dstadr) = pp->dstadr6; - } else { - srcadr.ss_family = AF_INET; - dstadr.ss_family = AF_INET; - GET_INADDR(srcadr) = pp->srcadr; - GET_INADDR(dstadr) = pp->dstadr; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - srcadr.ss_len = SOCKLEN(&srcadr); - dstadr.ss_len = SOCKLEN(&dstadr); -#endif (void) fprintf(fp, "remote %s, local %s\n", stoa(&srcadr), stoa(&dstadr)); (void) fprintf(fp, "hmode %s, pmode %s, stratum %d, precision %d\n", @@ -653,6 +679,7 @@ showpeer( struct info_peer *pp; /* 4 is the maximum number of peers which will fit in a packet */ struct info_peer_list *pl, plist[min(MAXARGS, 4)]; + int qitemlim; int qitems; int items; int itemsize; @@ -665,9 +692,10 @@ again: else sendsize = v4sizeof(struct info_peer_list); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 4); qitems++) { - if (pcmd->argval[qitems].netnum.ss_family == AF_INET) { - pl->addr = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[qitems].netnum)) { + pl->addr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -676,12 +704,12 @@ again: "***Server doesn't understand IPv6 addresses\n"); return; } - pl->addr6 = GET_INADDR6(pcmd->argval[qitems].netnum); + pl->addr6 = SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } pl->port = (u_short)s_port; pl->hmode = pl->flags = 0; - pl = (struct info_peer_list *)((char *)pl + sendsize); + pl = (void *)((char *)pl + sendsize); } res = doquery(impl_ver, REQ_PEER_INFO, 0, qitems, @@ -694,19 +722,19 @@ again: } if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (!checkitemsize(itemsize, sizeof(struct info_peer)) && !checkitemsize(itemsize, v4sizeof(struct info_peer))) - return; + return; while (items-- > 0) { printpeer(pp, fp); if (items > 0) - (void) fprintf(fp, "\n"); + fprintf(fp, "\n"); pp++; } } @@ -724,7 +752,8 @@ peerstats( struct info_peer_stats *pp; /* 4 is the maximum number of peers which will fit in a packet */ struct info_peer_list *pl, plist[min(MAXARGS, 4)]; - struct sockaddr_storage src, dst; + sockaddr_u src, dst; + int qitemlim; int qitems; int items; int itemsize; @@ -737,10 +766,12 @@ again: else sendsize = v4sizeof(struct info_peer_list); - memset((char *)plist, 0, sizeof(struct info_peer_list) * min(MAXARGS, 4)); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 4); qitems++) { - if (pcmd->argval[qitems].netnum.ss_family == AF_INET) { - pl->addr = GET_INADDR(pcmd->argval[qitems].netnum); + ZERO(plist); + + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[qitems].netnum)) { + pl->addr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -749,12 +780,12 @@ again: "***Server doesn't understand IPv6 addresses\n"); return; } - pl->addr6 = GET_INADDR6(pcmd->argval[qitems].netnum); + pl->addr6 = SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } pl->port = (u_short)s_port; pl->hmode = plist[qitems].flags = 0; - pl = (struct info_peer_list *)((char *)pl + sendsize); + pl = (void *)((char *)pl + sendsize); } res = doquery(impl_ver, REQ_PEER_STATS, 0, qitems, @@ -768,7 +799,7 @@ again: } if (res != 0) - return; + return; if (!checkitems(items, fp)) return; @@ -778,54 +809,54 @@ again: return; while (items-- > 0) { - memset((char *)&src, 0, sizeof(src)); - memset((char *)&dst, 0, sizeof(dst)); + ZERO_SOCK(&dst); + ZERO_SOCK(&src); if (pp->v6_flag != 0) { - GET_INADDR6(src) = pp->srcadr6; - GET_INADDR6(dst) = pp->dstadr6; - src.ss_family = AF_INET6; - dst.ss_family = AF_INET6; + AF(&dst) = AF_INET6; + AF(&src) = AF_INET6; + SOCK_ADDR6(&dst) = pp->dstadr6; + SOCK_ADDR6(&src) = pp->srcadr6; } else { - GET_INADDR(src) = pp->srcadr; - GET_INADDR(dst) = pp->dstadr; - src.ss_family = AF_INET; - dst.ss_family = AF_INET; + AF(&dst) = AF_INET; + AF(&src) = AF_INET; + NSRCADR(&dst) = pp->dstadr; + NSRCADR(&src) = pp->srcadr; } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - src.ss_len = SOCKLEN(&src); - dst.ss_len = SOCKLEN(&dst); +#ifdef ISC_PLATFORM_HAVESALEN + src.sa.sa_len = SOCKLEN(&src); + dst.sa.sa_len = SOCKLEN(&dst); #endif - (void) fprintf(fp, "remote host: %s\n", - nntohost(&src)); - (void) fprintf(fp, "local interface: %s\n", - stoa(&dst)); - (void) fprintf(fp, "time last received: %lds\n", - (long)ntohl(pp->timereceived)); - (void) fprintf(fp, "time until next send: %lds\n", - (long)ntohl(pp->timetosend)); - (void) fprintf(fp, "reachability change: %lds\n", - (long)ntohl(pp->timereachable)); - (void) fprintf(fp, "packets sent: %ld\n", - (long)ntohl(pp->sent)); - (void) fprintf(fp, "packets received: %ld\n", - (long)ntohl(pp->processed)); - (void) fprintf(fp, "bad authentication: %ld\n", - (long)ntohl(pp->badauth)); - (void) fprintf(fp, "bogus origin: %ld\n", - (long)ntohl(pp->bogusorg)); - (void) fprintf(fp, "duplicate: %ld\n", - (long)ntohl(pp->oldpkt)); - (void) fprintf(fp, "bad dispersion: %ld\n", - (long)ntohl(pp->seldisp)); - (void) fprintf(fp, "bad reference time: %ld\n", - (long)ntohl(pp->selbroken)); - (void) fprintf(fp, "candidate order: %d\n", - (int)pp->candidate); + fprintf(fp, "remote host: %s\n", + nntohost(&src)); + fprintf(fp, "local interface: %s\n", + stoa(&dst)); + fprintf(fp, "time last received: %lus\n", + (u_long)ntohl(pp->timereceived)); + fprintf(fp, "time until next send: %lus\n", + (u_long)ntohl(pp->timetosend)); + fprintf(fp, "reachability change: %lus\n", + (u_long)ntohl(pp->timereachable)); + fprintf(fp, "packets sent: %lu\n", + (u_long)ntohl(pp->sent)); + fprintf(fp, "packets received: %lu\n", + (u_long)ntohl(pp->processed)); + fprintf(fp, "bad authentication: %lu\n", + (u_long)ntohl(pp->badauth)); + fprintf(fp, "bogus origin: %lu\n", + (u_long)ntohl(pp->bogusorg)); + fprintf(fp, "duplicate: %lu\n", + (u_long)ntohl(pp->oldpkt)); + fprintf(fp, "bad dispersion: %lu\n", + (u_long)ntohl(pp->seldisp)); + fprintf(fp, "bad reference time: %lu\n", + (u_long)ntohl(pp->selbroken)); + fprintf(fp, "candidate order: %u\n", + pp->candidate); if (items > 0) - (void) fprintf(fp, "\n"); - (void) fprintf(fp, "flags: "); + fprintf(fp, "\n"); + fprintf(fp, "flags: "); print_pflag(fp, ntohs(pp->flags)); - pp++; + pp++; } } @@ -886,7 +917,7 @@ again: "offset %s, frequency %s, time_const %ld, watchdog %ld\n", lfptoa(&tempts, 6), lfptoa(&temp2ts, 3), - (long)(int32_t)ntohl((u_long)il->compliance), + (long)(int32)ntohl((u_long)il->compliance), (u_long)ntohl((u_long)il->watchdog_timer)); } else { NTOHL_FP(&il->last_offset, &tempts); @@ -896,7 +927,7 @@ again: (void) fprintf(fp, "frequency: %s ppm\n", lfptoa(&tempts, 3)); (void) fprintf(fp, "poll adjust: %ld\n", - (long)(int32_t)ntohl(il->compliance)); + (long)(int32)ntohl(il->compliance)); (void) fprintf(fp, "watchdog timer: %ld s\n", (u_long)ntohl(il->watchdog_timer)); } @@ -914,7 +945,7 @@ sysinfo( ) { struct info_sys *is; - struct sockaddr_storage peeraddr; + sockaddr_u peeraddr; int items; int itemsize; int res; @@ -940,17 +971,8 @@ again: !checkitemsize(itemsize, v4sizeof(struct info_sys))) return; - memset((char *)&peeraddr, 0, sizeof(peeraddr)); - if (is->v6_flag != 0) { - GET_INADDR6(peeraddr) = is->peer6; - peeraddr.ss_family = AF_INET6; - } else { - GET_INADDR(peeraddr) = is->peer; - peeraddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - peeraddr.ss_len = SOCKLEN(&peeraddr); -#endif + SET_ADDR(peeraddr, is->v6_flag, is->peer, is->peer6); + (void) fprintf(fp, "system peer: %s\n", nntohost(&peeraddr)); (void) fprintf(fp, "system peer mode: %s\n", modetoa(is->peer_mode)); (void) fprintf(fp, "leap indicator: %c%c\n", @@ -1039,30 +1061,30 @@ again: checkitemsize(itemsize, sizeof(struct info_sys_stats)); return; } - fprintf(fp, "time since restart: %ld\n", - (u_long)ntohl(ss->timeup)); - fprintf(fp, "time since reset: %ld\n", + fprintf(fp, "time since restart: %lu\n", + (u_long)ntohl(ss->timeup)); + fprintf(fp, "time since reset: %lu\n", (u_long)ntohl(ss->timereset)); - fprintf(fp, "packets received: %ld\n", + fprintf(fp, "packets received: %lu\n", (u_long)ntohl(ss->received)); - fprintf(fp, "packets processed: %ld\n", + fprintf(fp, "packets processed: %lu\n", (u_long)ntohl(ss->processed)); - fprintf(fp, "current version: %ld\n", - (u_long)ntohl(ss->newversionpkt)); - fprintf(fp, "previous version: %ld\n", - (u_long)ntohl(ss->oldversionpkt)); - fprintf(fp, "bad version: %ld\n", - (u_long)ntohl(ss->unknownversion)); - fprintf(fp, "access denied: %ld\n", + fprintf(fp, "current version: %lu\n", + (u_long)ntohl(ss->newversionpkt)); + fprintf(fp, "previous version: %lu\n", + (u_long)ntohl(ss->oldversionpkt)); + fprintf(fp, "declined: %lu\n", + (u_long)ntohl(ss->unknownversion)); + fprintf(fp, "access denied: %lu\n", (u_long)ntohl(ss->denied)); - fprintf(fp, "bad length or format: %ld\n", - (u_long)ntohl(ss->badlength)); - fprintf(fp, "bad authentication: %ld\n", - (u_long)ntohl(ss->badauth)); + fprintf(fp, "bad length or format: %lu\n", + (u_long)ntohl(ss->badlength)); + fprintf(fp, "bad authentication: %lu\n", + (u_long)ntohl(ss->badauth)); if (itemsize != sizeof(struct info_sys_stats)) return; - fprintf(fp, "rate exceeded: %ld\n", + fprintf(fp, "rate exceeded: %lu\n", (u_long)ntohl(ss->limitrejected)); } @@ -1084,9 +1106,8 @@ iostats( int res; again: - res = doquery(impl_ver, REQ_IO_STATS, 0, 0, 0, (char *)NULL, - &items, &itemsize, (void *)&io, 0, - sizeof(struct info_io_stats)); + res = doquery(impl_ver, REQ_IO_STATS, 0, 0, 0, NULL, &items, + &itemsize, (void *)&io, 0, sizeof(*io)); if (res == INFO_ERR_IMPL && impl_ver == IMPL_XNTPD) { impl_ver = IMPL_XNTPD_OLD; @@ -1094,38 +1115,38 @@ again: } if (res != 0) - return; + return; if (!check1item(items, fp)) - return; + return; - if (!checkitemsize(itemsize, sizeof(struct info_io_stats))) - return; + if (!checkitemsize(itemsize, sizeof(*io))) + return; - (void) fprintf(fp, "time since reset: %ld\n", - (u_long)ntohl(io->timereset)); - (void) fprintf(fp, "receive buffers: %d\n", - ntohs(io->totalrecvbufs)); - (void) fprintf(fp, "free receive buffers: %d\n", - ntohs(io->freerecvbufs)); - (void) fprintf(fp, "used receive buffers: %d\n", - ntohs(io->fullrecvbufs)); - (void) fprintf(fp, "low water refills: %d\n", - ntohs(io->lowwater)); - (void) fprintf(fp, "dropped packets: %ld\n", - (u_long)ntohl(io->dropped)); - (void) fprintf(fp, "ignored packets: %ld\n", - (u_long)ntohl(io->ignored)); - (void) fprintf(fp, "received packets: %ld\n", - (u_long)ntohl(io->received)); - (void) fprintf(fp, "packets sent: %ld\n", - (u_long)ntohl(io->sent)); - (void) fprintf(fp, "packets not sent: %ld\n", - (u_long)ntohl(io->notsent)); - (void) fprintf(fp, "interrupts handled: %ld\n", - (u_long)ntohl(io->interrupts)); - (void) fprintf(fp, "received by int: %ld\n", - (u_long)ntohl(io->int_received)); + fprintf(fp, "time since reset: %lu\n", + (u_long)ntohl(io->timereset)); + fprintf(fp, "receive buffers: %u\n", + (u_int)ntohs(io->totalrecvbufs)); + fprintf(fp, "free receive buffers: %u\n", + (u_int)ntohs(io->freerecvbufs)); + fprintf(fp, "used receive buffers: %u\n", + (u_int)ntohs(io->fullrecvbufs)); + fprintf(fp, "low water refills: %u\n", + (u_int)ntohs(io->lowwater)); + fprintf(fp, "dropped packets: %lu\n", + (u_long)ntohl(io->dropped)); + fprintf(fp, "ignored packets: %lu\n", + (u_long)ntohl(io->ignored)); + fprintf(fp, "received packets: %lu\n", + (u_long)ntohl(io->received)); + fprintf(fp, "packets sent: %lu\n", + (u_long)ntohl(io->sent)); + fprintf(fp, "packets not sent: %lu\n", + (u_long)ntohl(io->notsent)); + fprintf(fp, "interrupts handled: %lu\n", + (u_long)ntohl(io->interrupts)); + fprintf(fp, "received by int: %lu\n", + (u_long)ntohl(io->int_received)); } @@ -1146,9 +1167,8 @@ memstats( int res; again: - res = doquery(impl_ver, REQ_MEM_STATS, 0, 0, 0, (char *)NULL, - &items, &itemsize, (void *)&mem, 0, - sizeof(struct info_mem_stats)); + res = doquery(impl_ver, REQ_MEM_STATS, 0, 0, 0, NULL, &items, + &itemsize, (void *)&mem, 0, sizeof(*mem)); if (res == INFO_ERR_IMPL && impl_ver == IMPL_XNTPD) { impl_ver = IMPL_XNTPD_OLD; @@ -1156,35 +1176,34 @@ again: } if (res != 0) - return; + return; if (!check1item(items, fp)) - return; + return; - if (!checkitemsize(itemsize, sizeof(struct info_mem_stats))) - return; + if (!checkitemsize(itemsize, sizeof(*mem))) + return; - (void) fprintf(fp, "time since reset: %ld\n", - (u_long)ntohl(mem->timereset)); - (void) fprintf(fp, "total peer memory: %d\n", - ntohs(mem->totalpeermem)); - (void) fprintf(fp, "free peer memory: %d\n", - ntohs(mem->freepeermem)); - (void) fprintf(fp, "calls to findpeer: %ld\n", - (u_long)ntohl(mem->findpeer_calls)); - (void) fprintf(fp, "new peer allocations: %ld\n", - (u_long)ntohl(mem->allocations)); - (void) fprintf(fp, "peer demobilizations: %ld\n", - (u_long)ntohl(mem->demobilizations)); - - (void) fprintf(fp, "hash table counts: "); + fprintf(fp, "time since reset: %lu\n", + (u_long)ntohl(mem->timereset)); + fprintf(fp, "total peer memory: %u\n", + (u_int)ntohs(mem->totalpeermem)); + fprintf(fp, "free peer memory: %u\n", + (u_int)ntohs(mem->freepeermem)); + fprintf(fp, "calls to findpeer: %lu\n", + (u_long)ntohl(mem->findpeer_calls)); + fprintf(fp, "new peer allocations: %lu\n", + (u_long)ntohl(mem->allocations)); + fprintf(fp, "peer demobilizations: %lu\n", + (u_long)ntohl(mem->demobilizations)); + + fprintf(fp, "hash table counts: "); for (i = 0; i < NTP_HASH_SIZE; i++) { - (void) fprintf(fp, "%4d", (int)mem->hashcount[i]); - if ((i % 8) == 7 && i != (NTP_HASH_SIZE-1)) { - (void) fprintf(fp, "\n "); - } + fprintf(fp, "%4d", (int)mem->hashcount[i]); + if ((i % 8) == 7 && i != (NTP_HASH_SIZE-1)) + fprintf(fp, "\n "); } - (void) fprintf(fp, "\n"); + fprintf(fp, "\n"); } @@ -1205,9 +1224,8 @@ timerstats( int res; again: - res = doquery(impl_ver, REQ_TIMER_STATS, 0, 0, 0, (char *)NULL, - &items, &itemsize, (void *)&tim, 0, - sizeof(struct info_timer_stats)); + res = doquery(impl_ver, REQ_TIMER_STATS, 0, 0, 0, NULL, &items, + &itemsize, (void *)&tim, 0, sizeof(*tim)); if (res == INFO_ERR_IMPL && impl_ver == IMPL_XNTPD) { impl_ver = IMPL_XNTPD_OLD; @@ -1215,22 +1233,22 @@ again: } if (res != 0) - return; + return; if (!check1item(items, fp)) - return; + return; - if (!checkitemsize(itemsize, sizeof(struct info_timer_stats))) - return; + if (!checkitemsize(itemsize, sizeof(*tim))) + return; - (void) fprintf(fp, "time since reset: %ld\n", - (u_long)ntohl(tim->timereset)); - (void) fprintf(fp, "alarms handled: %ld\n", - (u_long)ntohl(tim->alarms)); - (void) fprintf(fp, "alarm overruns: %ld\n", - (u_long)ntohl(tim->overflows)); - (void) fprintf(fp, "calls to transmit: %ld\n", - (u_long)ntohl(tim->xmtcalls)); + fprintf(fp, "time since reset: %lu\n", + (u_long)ntohl(tim->timereset)); + fprintf(fp, "alarms handled: %lu\n", + (u_long)ntohl(tim->alarms)); + fprintf(fp, "alarm overruns: %lu\n", + (u_long)ntohl(tim->overflows)); + fprintf(fp, "calls to transmit: %lu\n", + (u_long)ntohl(tim->xmtcalls)); } @@ -1292,7 +1310,7 @@ doconfig( struct parse *pcmd, FILE *fp, int mode, - int refc + int refc ) { struct conf_peer cpeer; @@ -1308,18 +1326,19 @@ doconfig( int res; int sendsize; int numtyp; + long val; again: keyid = 0; version = 3; flags = 0; - res = 0; + res = FALSE; cmode = 0; minpoll = NTP_MINDPOLL; maxpoll = NTP_MAXDPOLL; numtyp = 1; if (refc) - numtyp = 5; + numtyp = 5; if (impl_ver == IMPL_XNTPD) sendsize = sizeof(struct conf_peer); @@ -1327,91 +1346,87 @@ again: sendsize = v4sizeof(struct conf_peer); items = 1; - while (pcmd->nargs > items) { + while (pcmd->nargs > (size_t)items) { if (STREQ(pcmd->argval[items].string, "prefer")) - flags |= CONF_FLAG_PREFER; + flags |= CONF_FLAG_PREFER; else if (STREQ(pcmd->argval[items].string, "burst")) - flags |= CONF_FLAG_BURST; - else if (STREQ(pcmd->argval[items].string, "dynamic")) - (void) fprintf(fp, "Warning: the \"dynamic\" keyword has been obsoleted and will be removed in the next release\n"); + flags |= CONF_FLAG_BURST; else if (STREQ(pcmd->argval[items].string, "iburst")) - flags |= CONF_FLAG_IBURST; + flags |= CONF_FLAG_IBURST; else if (!refc && STREQ(pcmd->argval[items].string, "keyid")) - numtyp = 1; + numtyp = 1; else if (!refc && STREQ(pcmd->argval[items].string, "version")) - numtyp = 2; + numtyp = 2; else if (STREQ(pcmd->argval[items].string, "minpoll")) - numtyp = 3; + numtyp = 3; else if (STREQ(pcmd->argval[items].string, "maxpoll")) - numtyp = 4; + numtyp = 4; else { - long val; if (!atoint(pcmd->argval[items].string, &val)) - numtyp = 0; + numtyp = 0; switch (numtyp) { case 1: - keyid = val; - numtyp = 2; - break; - + keyid = val; + numtyp = 2; + break; + case 2: - version = (u_int) val; - numtyp = 0; - break; + version = (u_int)val; + numtyp = 0; + break; case 3: - minpoll = (u_char)val; - numtyp = 0; - break; + minpoll = (u_char)val; + numtyp = 0; + break; case 4: - maxpoll = (u_char)val; - numtyp = 0; - break; + maxpoll = (u_char)val; + numtyp = 0; + break; case 5: - cmode = (u_char)val; - numtyp = 0; - break; + cmode = (u_char)val; + numtyp = 0; + break; default: - (void) fprintf(fp, "*** '%s' not understood\n", - pcmd->argval[items].string); - res++; - numtyp = 0; + fprintf(fp, "*** '%s' not understood\n", + pcmd->argval[items].string); + res = TRUE; + numtyp = 0; } if (val < 0) { - (void) fprintf(stderr, - "***Value '%s' should be unsigned\n", - pcmd->argval[items].string); - res++; + fprintf(stderr, + "*** Value '%s' should be unsigned\n", + pcmd->argval[items].string); + res = TRUE; } - } - items++; + } + items++; } if (keyid > 0) - flags |= CONF_FLAG_AUTHENABLE; - if (version > NTP_VERSION || - version < NTP_OLDVERSION) { - (void)fprintf(fp, "***invalid version number: %u\n", - version); - res++; + flags |= CONF_FLAG_AUTHENABLE; + if (version > NTP_VERSION || version < NTP_OLDVERSION) { + fprintf(fp, "***invalid version number: %u\n", + version); + res = TRUE; } if (minpoll < NTP_MINPOLL || minpoll > NTP_MAXPOLL || maxpoll < NTP_MINPOLL || maxpoll > NTP_MAXPOLL || minpoll > maxpoll) { - (void) fprintf(fp, "***min/max-poll must be within %d..%d\n", - NTP_MINPOLL, NTP_MAXPOLL); - res++; + fprintf(fp, "***min/max-poll must be within %d..%d\n", + NTP_MINPOLL, NTP_MAXPOLL); + res = TRUE; } if (res) - return; + return; - memset((void *)&cpeer, 0, sizeof(cpeer)); + ZERO(cpeer); - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - cpeer.peeraddr = GET_INADDR(pcmd->argval[0].netnum); + if (IS_IPV4(&pcmd->argval[0].netnum)) { + cpeer.peeraddr = NSRCADR(&pcmd->argval[0].netnum); if (impl_ver == IMPL_XNTPD) cpeer.v6_flag = 0; } else { @@ -1420,7 +1435,7 @@ again: "***Server doesn't understand IPv6 addresses\n"); return; } - cpeer.peeraddr6 = GET_INADDR6(pcmd->argval[0].netnum); + cpeer.peeraddr6 = SOCK_ADDR6(&pcmd->argval[0].netnum); cpeer.v6_flag = 1; } cpeer.hmode = (u_char) mode; @@ -1465,6 +1480,7 @@ unconfig( { /* 8 is the maximum number of peers which will fit in a packet */ struct conf_unpeer *pl, plist[min(MAXARGS, 8)]; + int qitemlim; int qitems; int items; int itemsize; @@ -1478,9 +1494,10 @@ again: else sendsize = v4sizeof(struct conf_unpeer); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 8); qitems++) { - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - pl->peeraddr = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[0].netnum)) { + pl->peeraddr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -1490,10 +1507,10 @@ again: return; } pl->peeraddr6 = - GET_INADDR6(pcmd->argval[qitems].netnum); + SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } - pl = (struct conf_unpeer *)((char *)pl + sendsize); + pl = (void *)((char *)pl + sendsize); } res = doquery(impl_ver, REQ_UNCONFIG, 1, qitems, @@ -1546,7 +1563,6 @@ doset( int req ) { - /* 8 is the maximum number of peers which will fit in a packet */ struct conf_sys_flags sys; int items; int itemsize; @@ -1555,7 +1571,7 @@ doset( sys.flags = 0; res = 0; - for (items = 0; items < pcmd->nargs; items++) { + for (items = 0; (size_t)items < pcmd->nargs; items++) { if (STREQ(pcmd->argval[items].string, "auth")) sys.flags |= SYS_FLAG_AUTH; else if (STREQ(pcmd->argval[items].string, "bclient")) @@ -1632,8 +1648,8 @@ static struct resflags resflagsV3[] = { { "lptrap", RES_LPTRAP }, { "limited", RES_LIMITED }, { "version", RES_VERSION }, - { "kod", RES_DEMOBILIZE }, - { "timeout", RES_TIMEOUT }, + { "kod", RES_KOD }, + { "flake", RES_FLAKE }, { "", 0 } }; @@ -1641,6 +1657,7 @@ static struct resflags resflagsV3[] = { static struct resflags resmflags[] = { { "ntpport", RESM_NTPONLY }, { "interface", RESM_INTERFACE }, + { "source", RESM_SOURCE }, { "", 0 } }; @@ -1656,14 +1673,14 @@ reslist( ) { struct info_restrict *rl; - struct sockaddr_storage resaddr; - struct sockaddr_storage maskaddr; + sockaddr_u resaddr; + sockaddr_u maskaddr; int items; int itemsize; int res; int skip; - char *addr; - char *mask; + const char *addr; + const char *mask; struct resflags *rf; u_int32 count; u_short flags; @@ -1682,42 +1699,27 @@ again: } if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (!checkitemsize(itemsize, sizeof(struct info_restrict)) && !checkitemsize(itemsize, v4sizeof(struct info_restrict))) - return; + return; - (void) fprintf(fp, - " address mask count flags\n"); - (void) fprintf(fp, - "=====================================================================\n"); + fprintf(fp, + " address mask count flags\n"); + fprintf(fp, + "=====================================================================\n"); while (items > 0) { - memset((char *)&resaddr, 0, sizeof(resaddr)); - memset((char *)&maskaddr, 0, sizeof(maskaddr)); + SET_ADDRS(resaddr, maskaddr, rl, addr, mask); if (rl->v6_flag != 0) { - GET_INADDR6(resaddr) = rl->addr6; - GET_INADDR6(maskaddr) = rl->mask6; - resaddr.ss_family = AF_INET6; - maskaddr.ss_family = AF_INET6; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - resaddr.ss_len = SOCKLEN(&resaddr); -#endif addr = nntohost(&resaddr); } else { - GET_INADDR(resaddr) = rl->addr; - GET_INADDR(maskaddr) = rl->mask; - resaddr.ss_family = AF_INET; - maskaddr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - resaddr.ss_len = SOCKLEN(&resaddr); -#endif - if ((rl->mask == (u_int32)0xffffffff)) - addr = nntohost(&resaddr); + if (rl->mask == (u_int32)0xffffffff) + addr = nntohost(&resaddr); else addr = stoa(&resaddr); } @@ -1737,33 +1739,37 @@ again: while (rf->bit != 0) { if (mflags & rf->bit) { if (!res) - (void) strcat(flagstr, comma); + strlcat(flagstr, comma, + sizeof(flagstr)); res = 0; - (void) strcat(flagstr, rf->str); + strlcat(flagstr, rf->str, + sizeof(flagstr)); } rf++; } rf = (impl_ver == IMPL_XNTPD_OLD) - ? &resflagsV2[0] - : &resflagsV3[0] - ; + ? &resflagsV2[0] + : &resflagsV3[0]; + while (rf->bit != 0) { if (flags & rf->bit) { if (!res) - (void) strcat(flagstr, comma); + strlcat(flagstr, comma, + sizeof(flagstr)); res = 0; - (void) strcat(flagstr, rf->str); + strlcat(flagstr, rf->str, + sizeof(flagstr)); } rf++; } if (flagstr[0] == '\0') - (void) strcpy(flagstr, "none"); + strlcpy(flagstr, "none", sizeof(flagstr)); if (!skip) - (void) fprintf(fp, "%-15.15s %-15.15s %9ld %s\n", - addr, mask, (u_long)count, flagstr); + fprintf(fp, "%-15.15s %-15.15s %9lu %s\n", + addr, mask, (u_long)count, flagstr); rl++; items--; } @@ -1827,7 +1833,7 @@ do_restrict( u_int32 num; u_long bit; int i; - int res; + size_t res; int err; int sendsize; @@ -1844,23 +1850,23 @@ again: else sendsize = v4sizeof(struct conf_restrict); - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - cres.addr = GET_INADDR(pcmd->argval[0].netnum); - cres.mask = GET_INADDR(pcmd->argval[1].netnum); + if (IS_IPV4(&pcmd->argval[0].netnum)) { + cres.addr = NSRCADR(&pcmd->argval[0].netnum); + cres.mask = NSRCADR(&pcmd->argval[1].netnum); if (impl_ver == IMPL_XNTPD) cres.v6_flag = 0; } else { if (impl_ver == IMPL_XNTPD_OLD) { fprintf(stderr, - "***Server doesn't understand IPv6 addresses\n"); + "***Server doesn't understand IPv6 addresses\n"); return; } - cres.addr6 = GET_INADDR6(pcmd->argval[0].netnum); + cres.addr6 = SOCK_ADDR6(&pcmd->argval[0].netnum); cres.v6_flag = 1; } cres.flags = 0; cres.mflags = 0; - err = 0; + err = FALSE; for (res = 2; res < pcmd->nargs; res++) { if (STREQ(pcmd->argval[res].string, "ntpport")) { cres.mflags |= RESM_NTPONLY; @@ -1868,20 +1874,20 @@ again: for (i = 0; resflagsV3[i].bit != 0; i++) { if (STREQ(pcmd->argval[res].string, resflagsV3[i].str)) - break; + break; } if (resflagsV3[i].bit != 0) { cres.flags |= resflagsV3[i].bit; if (req_code == REQ_UNRESTRICT) { - (void) fprintf(fp, - "Flag %s inappropriate\n", - resflagsV3[i].str); - err++; + fprintf(fp, + "Flag %s inappropriate\n", + resflagsV3[i].str); + err = TRUE; } } else { - (void) fprintf(fp, "Unknown flag %s\n", - pcmd->argval[res].string); - err++; + fprintf(fp, "Unknown flag %s\n", + pcmd->argval[res].string); + err = TRUE; } } } @@ -1892,21 +1898,21 @@ again: * Make sure mask for default address is zero. Otherwise, * make sure mask bits are contiguous. */ - if (pcmd->argval[0].netnum.ss_family == AF_INET) { + if (IS_IPV4(&pcmd->argval[0].netnum)) { if (cres.addr == 0) { cres.mask = 0; } else { num = ntohl(cres.mask); for (bit = 0x80000000; bit != 0; bit >>= 1) - if ((num & bit) == 0) - break; + if ((num & bit) == 0) + break; for ( ; bit != 0; bit >>= 1) - if ((num & bit) != 0) - break; + if ((num & bit) != 0) + break; if (bit != 0) { - (void) fprintf(fp, "Invalid mask %s\n", - numtoa(cres.mask)); - err++; + fprintf(fp, "Invalid mask %s\n", + numtoa(cres.mask)); + err = TRUE; } } } else { @@ -1914,11 +1920,10 @@ again: } if (err) - return; + return; - res = doquery(impl_ver, req_code, 1, 1, - sendsize, (char *)&cres, &items, - &itemsize, &dummy, 0, sizeof(struct conf_restrict)); + res = doquery(impl_ver, req_code, 1, 1, sendsize, (char *)&cres, + &items, &itemsize, &dummy, 0, sizeof(cres)); if (res == INFO_ERR_IMPL && impl_ver == IMPL_XNTPD) { impl_ver = IMPL_XNTPD_OLD; @@ -1942,21 +1947,23 @@ monlist( ) { char *struct_star; - struct sockaddr_storage addr; - struct sockaddr_storage dstadr; + struct info_monitor *ml; + struct info_monitor_1 *m1; + struct old_info_monitor *oml; + sockaddr_u addr; + sockaddr_u dstadr; int items; int itemsize; int res; int version = -1; - if (pcmd->nargs > 0) { + if (pcmd->nargs > 0) version = pcmd->argval[0].ival; - } again: res = doquery(impl_ver, (version == 1 || version == -1) ? REQ_MON_GETLIST_1 : - REQ_MON_GETLIST, 0, 0, 0, (char *)NULL, + REQ_MON_GETLIST, 0, 0, 0, NULL, &items, &itemsize, &struct_star, (version < 0) ? (1 << INFO_ERR_REQ) : 0, sizeof(struct info_monitor_1)); @@ -1967,121 +1974,86 @@ again: } if (res == INFO_ERR_REQ && version < 0) - res = doquery(impl_ver, REQ_MON_GETLIST, 0, 0, 0, (char *)NULL, - &items, &itemsize, &struct_star, 0, - sizeof(struct info_monitor)); + res = doquery(impl_ver, REQ_MON_GETLIST, 0, 0, 0, NULL, + &items, &itemsize, &struct_star, 0, + sizeof(struct info_monitor)); if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (itemsize == sizeof(struct info_monitor_1) || itemsize == v4sizeof(struct info_monitor_1)) { - struct info_monitor_1 *ml = (struct info_monitor_1 *) struct_star; - (void) fprintf(fp, - "remote address port local address count m ver code avgint lstint\n"); - (void) fprintf(fp, - "===============================================================================\n"); + m1 = (void *)struct_star; + fprintf(fp, + "remote address port local address count m ver rstr avgint lstint\n"); + fprintf(fp, + "===============================================================================\n"); while (items > 0) { - memset((char *)&addr, 0, sizeof(addr)); - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (ml->v6_flag != 0) { - GET_INADDR6(addr) = ml->addr6; - addr.ss_family = AF_INET6; - GET_INADDR6(dstadr) = ml->daddr6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(addr) = ml->addr; - addr.ss_family = AF_INET; - GET_INADDR(dstadr) = ml->daddr; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - addr.ss_len = SOCKLEN(&addr); - dstadr.ss_len = SOCKLEN(&dstadr); -#endif + SET_ADDRS(dstadr, addr, m1, daddr, addr); if ((pcmd->nargs == 0) || - ((pcmd->argval->ival == 6) && (ml->v6_flag != 0)) || - ((pcmd->argval->ival == 4) && (ml->v6_flag == 0))) - (void) fprintf(fp, - "%-22.22s %5d %-15s %8ld %1d %1d %6lx %6lu %7lu\n", + ((pcmd->argval->ival == 6) && (m1->v6_flag != 0)) || + ((pcmd->argval->ival == 4) && (m1->v6_flag == 0))) + fprintf(fp, + "%-22.22s %5d %-15s %8lu %1u %1u %6lx %6lu %7lu\n", nntohost(&addr), - ntohs(ml->port), + ntohs(m1->port), stoa(&dstadr), - (u_long)ntohl(ml->count), - ml->mode, - ml->version, - (u_long)ntohl(ml->lastdrop), - (u_long)ntohl(ml->lasttime), - (u_long)ntohl(ml->firsttime)); - ml++; + (u_long)ntohl(m1->count), + m1->mode, + m1->version, + (u_long)ntohl(m1->restr), + (u_long)ntohl(m1->avg_int), + (u_long)ntohl(m1->last_int)); + m1++; items--; } } else if (itemsize == sizeof(struct info_monitor) || itemsize == v4sizeof(struct info_monitor)) { - struct info_monitor *ml = (struct info_monitor *) struct_star; - (void) fprintf(fp, - " address port count mode ver code avgint lstint\n"); - (void) fprintf(fp, - "===============================================================================\n"); + ml = (void *) struct_star; + fprintf(fp, + " address port count mode ver rstr avgint lstint\n"); + fprintf(fp, + "===============================================================================\n"); while (items > 0) { - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (ml->v6_flag != 0) { - GET_INADDR6(dstadr) = ml->addr6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(dstadr) = ml->addr; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - dstadr.ss_len = SOCKLEN(&dstadr); -#endif + SET_ADDR(dstadr, ml->v6_flag, ml->addr, ml->addr6); if ((pcmd->nargs == 0) || ((pcmd->argval->ival == 6) && (ml->v6_flag != 0)) || ((pcmd->argval->ival == 4) && (ml->v6_flag == 0))) - (void) fprintf(fp, - "%-25.25s %5d %9ld %4d %2d %9lx %9lu %9lu\n", + fprintf(fp, + "%-25.25s %5u %9lu %4u %2u %9lx %9lu %9lu\n", nntohost(&dstadr), ntohs(ml->port), (u_long)ntohl(ml->count), ml->mode, ml->version, - (u_long)ntohl(ml->lastdrop), - (u_long)ntohl(ml->lasttime), - (u_long)ntohl(ml->firsttime)); + (u_long)ntohl(ml->restr), + (u_long)ntohl(ml->avg_int), + (u_long)ntohl(ml->last_int)); ml++; items--; } } else if (itemsize == sizeof(struct old_info_monitor)) { - struct old_info_monitor *oml = (struct old_info_monitor *)struct_star; - (void) fprintf(fp, - " address port count mode version lasttime firsttime\n"); - (void) fprintf(fp, - "======================================================================\n"); + + oml = (void *)struct_star; + fprintf(fp, + " address port count mode version lasttime firsttime\n"); + fprintf(fp, + "======================================================================\n"); while (items > 0) { - memset((char *)&dstadr, 0, sizeof(dstadr)); - if (oml->v6_flag != 0) { - GET_INADDR6(dstadr) = oml->addr6; - dstadr.ss_family = AF_INET6; - } else { - GET_INADDR(dstadr) = oml->addr; - dstadr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - dstadr.ss_len = SOCKLEN(&dstadr); -#endif - (void) fprintf(fp, "%-20.20s %5d %9ld %4d %3d %9lu %9lu\n", - nntohost(&dstadr), - ntohs(oml->port), - (u_long)ntohl(oml->count), - oml->mode, - oml->version, - (u_long)ntohl(oml->lasttime), - (u_long)ntohl(oml->firsttime)); + SET_ADDR(dstadr, oml->v6_flag, oml->addr, oml->addr6); + fprintf(fp, "%-20.20s %5u %9lu %4u %3u %9lu %9lu\n", + nntohost(&dstadr), + ntohs(oml->port), + (u_long)ntohl(oml->count), + oml->mode, + oml->version, + (u_long)ntohl(oml->lasttime), + (u_long)ntohl(oml->firsttime)); oml++; items--; } @@ -2096,15 +2068,16 @@ again: * Mapping between command line strings and stat reset flags */ struct statreset { - const char *str; - int flag; + const char * const str; + const int flag; } sreset[] = { + { "allpeers", RESET_FLAG_ALLPEERS }, { "io", RESET_FLAG_IO }, { "sys", RESET_FLAG_SYS }, { "mem", RESET_FLAG_MEM }, { "timer", RESET_FLAG_TIMER }, { "auth", RESET_FLAG_AUTH }, - { "allpeers", RESET_FLAG_ALLPEERS }, + { "ctl", RESET_FLAG_CTL }, { "", 0 } }; @@ -2122,7 +2095,7 @@ reset( int itemsize; char *dummy; int i; - int res; + size_t res; int err; err = 0; @@ -2130,11 +2103,11 @@ reset( for (res = 0; res < pcmd->nargs; res++) { for (i = 0; sreset[i].flag != 0; i++) { if (STREQ(pcmd->argval[res].string, sreset[i].str)) - break; + break; } if (sreset[i].flag == 0) { - (void) fprintf(fp, "Flag %s unknown\n", - pcmd->argval[res].string); + fprintf(fp, "Flag %s unknown\n", + pcmd->argval[res].string); err++; } else { rflags.flags |= sreset[i].flag; @@ -2175,6 +2148,7 @@ preset( { /* 8 is the maximum number of peers which will fit in a packet */ struct conf_unpeer *pl, plist[min(MAXARGS, 8)]; + int qitemlim; int qitems; int items; int itemsize; @@ -2188,9 +2162,10 @@ again: else sendsize = v4sizeof(struct conf_unpeer); - for (qitems = 0, pl = plist; qitems < min(pcmd->nargs, 8); qitems++) { - if (pcmd->argval[qitems].netnum.ss_family == AF_INET) { - pl->peeraddr = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(plist)); + for (qitems = 0, pl = plist; qitems < qitemlim; qitems++) { + if (IS_IPV4(&pcmd->argval[qitems].netnum)) { + pl->peeraddr = NSRCADR(&pcmd->argval[qitems].netnum); if (impl_ver == IMPL_XNTPD) pl->v6_flag = 0; } else { @@ -2200,10 +2175,10 @@ again: return; } pl->peeraddr6 = - GET_INADDR6(pcmd->argval[qitems].netnum); + SOCK_ADDR6(&pcmd->argval[qitems].netnum); pl->v6_flag = 1; } - pl = (struct conf_unpeer *)((char *)pl + sendsize); + pl = (void *)((char *)pl + sendsize); } res = doquery(impl_ver, REQ_RESET_PEER, 1, qitems, @@ -2287,7 +2262,7 @@ do_trustkey( ) { u_long keyids[MAXARGS]; - int i; + size_t i; int items; int itemsize; char *dummy; @@ -2332,9 +2307,8 @@ authinfo( int res; again: - res = doquery(impl_ver, REQ_AUTHINFO, 0, 0, 0, (char *)NULL, - &items, &itemsize, (void *)&ia, 0, - sizeof(struct info_auth)); + res = doquery(impl_ver, REQ_AUTHINFO, 0, 0, 0, NULL, &items, + &itemsize, (void *)&ia, 0, sizeof(*ia)); if (res == INFO_ERR_IMPL && impl_ver == IMPL_XNTPD) { impl_ver = IMPL_XNTPD_OLD; @@ -2342,32 +2316,32 @@ again: } if (res != 0) - return; + return; if (!check1item(items, fp)) - return; + return; - if (!checkitemsize(itemsize, sizeof(struct info_auth))) - return; + if (!checkitemsize(itemsize, sizeof(*ia))) + return; - (void) fprintf(fp, "time since reset: %ld\n", - (u_long)ntohl(ia->timereset)); - (void) fprintf(fp, "stored keys: %ld\n", - (u_long)ntohl(ia->numkeys)); - (void) fprintf(fp, "free keys: %ld\n", - (u_long)ntohl(ia->numfreekeys)); - (void) fprintf(fp, "key lookups: %ld\n", - (u_long)ntohl(ia->keylookups)); - (void) fprintf(fp, "keys not found: %ld\n", - (u_long)ntohl(ia->keynotfound)); - (void) fprintf(fp, "uncached keys: %ld\n", - (u_long)ntohl(ia->keyuncached)); - (void) fprintf(fp, "encryptions: %ld\n", - (u_long)ntohl(ia->encryptions)); - (void) fprintf(fp, "decryptions: %ld\n", - (u_long)ntohl(ia->decryptions)); - (void) fprintf(fp, "expired keys: %ld\n", - (u_long)ntohl(ia->expired)); + fprintf(fp, "time since reset: %lu\n", + (u_long)ntohl(ia->timereset)); + fprintf(fp, "stored keys: %lu\n", + (u_long)ntohl(ia->numkeys)); + fprintf(fp, "free keys: %lu\n", + (u_long)ntohl(ia->numfreekeys)); + fprintf(fp, "key lookups: %lu\n", + (u_long)ntohl(ia->keylookups)); + fprintf(fp, "keys not found: %lu\n", + (u_long)ntohl(ia->keynotfound)); + fprintf(fp, "uncached keys: %lu\n", + (u_long)ntohl(ia->keyuncached)); + fprintf(fp, "encryptions: %lu\n", + (u_long)ntohl(ia->encryptions)); + fprintf(fp, "decryptions: %lu\n", + (u_long)ntohl(ia->decryptions)); + fprintf(fp, "expired keys: %lu\n", + (u_long)ntohl(ia->expired)); } @@ -2384,15 +2358,14 @@ traps( { int i; struct info_trap *it; - struct sockaddr_storage trap_addr, local_addr; + sockaddr_u trap_addr, local_addr; int items; int itemsize; int res; again: - res = doquery(impl_ver, REQ_TRAPS, 0, 0, 0, (char *)NULL, - &items, &itemsize, (void *)&it, 0, - sizeof(struct info_trap)); + res = doquery(impl_ver, REQ_TRAPS, 0, 0, 0, NULL, &items, + &itemsize, (void *)&it, 0, sizeof(*it)); if (res == INFO_ERR_IMPL && impl_ver == IMPL_XNTPD) { impl_ver = IMPL_XNTPD_OLD; @@ -2400,55 +2373,38 @@ again: } if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (!checkitemsize(itemsize, sizeof(struct info_trap)) && !checkitemsize(itemsize, v4sizeof(struct info_trap))) - return; + return; for (i = 0; i < items; i++ ) { - if (i != 0) - (void) fprintf(fp, "\n"); - memset((char *)&trap_addr, 0, sizeof(trap_addr)); - memset((char *)&local_addr, 0, sizeof(local_addr)); - if (it->v6_flag != 0) { - GET_INADDR6(trap_addr) = it->trap_address6; - GET_INADDR6(local_addr) = it->local_address6; - trap_addr.ss_family = AF_INET6; - local_addr.ss_family = AF_INET6; - } else { - GET_INADDR(trap_addr) = it->trap_address; - GET_INADDR(local_addr) = it->local_address; - trap_addr.ss_family = AF_INET; - local_addr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - trap_addr.ss_len = SOCKLEN(&trap_addr); - local_addr.ss_len = SOCKLEN(&local_addr); -#endif - (void) fprintf(fp, "address %s, port %d\n", - stoa(&trap_addr), - ntohs(it->trap_port)); - (void) fprintf(fp, "interface: %s, ", - (it->local_address == 0) - ? "wildcard" - : stoa(&local_addr)); + SET_ADDRS(trap_addr, local_addr, it, trap_address, local_address); + fprintf(fp, "%saddress %s, port %d\n", + (0 == i) + ? "" + : "\n", + stoa(&trap_addr), ntohs(it->trap_port)); + fprintf(fp, "interface: %s, ", + (0 == it->local_address) + ? "wildcard" + : stoa(&local_addr)); if (ntohl(it->flags) & TRAP_CONFIGURED) - (void) fprintf(fp, "configured\n"); + fprintf(fp, "configured\n"); else if (ntohl(it->flags) & TRAP_NONPRIO) - (void) fprintf(fp, "low priority\n"); + fprintf(fp, "low priority\n"); else - (void) fprintf(fp, "normal priority\n"); + fprintf(fp, "normal priority\n"); - (void) fprintf(fp, "set for %ld secs, last set %ld secs ago\n", - (long)ntohl(it->origtime), - (long)ntohl(it->settime)); - (void) fprintf(fp, "sequence %d, number of resets %ld\n", - ntohs(it->sequence), - (long)ntohl(it->resets)); + fprintf(fp, "set for %ld secs, last set %ld secs ago\n", + (long)ntohl(it->origtime), + (long)ntohl(it->settime)); + fprintf(fp, "sequence %d, number of resets %ld\n", + ntohs(it->sequence), (long)ntohl(it->resets)); } } @@ -2502,8 +2458,8 @@ again: else sendsize = v4sizeof(struct conf_trap); - if (pcmd->argval[0].netnum.ss_family == AF_INET) { - ctrap.trap_address = GET_INADDR(pcmd->argval[0].netnum); + if (IS_IPV4(&pcmd->argval[0].netnum)) { + ctrap.trap_address = NSRCADR(&pcmd->argval[0].netnum); if (impl_ver == IMPL_XNTPD) ctrap.v6_flag = 0; } else { @@ -2512,7 +2468,7 @@ again: "***Server doesn't understand IPv6 addresses\n"); return; } - ctrap.trap_address6 = GET_INADDR6(pcmd->argval[0].netnum); + ctrap.trap_address6 = SOCK_ADDR6(&pcmd->argval[0].netnum); ctrap.v6_flag = 1; } ctrap.local_address = 0; @@ -2520,19 +2476,18 @@ again: ctrap.unused = 0; if (pcmd->nargs > 1) { - ctrap.trap_port - = htons((u_short)(pcmd->argval[1].uval & 0xffff)); + ctrap.trap_port = htons((u_short)pcmd->argval[1].uval); if (pcmd->nargs > 2) { - if (pcmd->argval[2].netnum.ss_family != - pcmd->argval[0].netnum.ss_family) { + if (AF(&pcmd->argval[2].netnum) != + AF(&pcmd->argval[0].netnum)) { fprintf(stderr, "***Cannot mix IPv4 and IPv6 addresses\n"); return; } - if (pcmd->argval[2].netnum.ss_family == AF_INET) - ctrap.local_address = GET_INADDR(pcmd->argval[2].netnum); + if (IS_IPV4(&pcmd->argval[2].netnum)) + ctrap.local_address = NSRCADR(&pcmd->argval[2].netnum); else - ctrap.local_address6 = GET_INADDR6(pcmd->argval[2].netnum); + ctrap.local_address6 = SOCK_ADDR6(&pcmd->argval[2].netnum); } } @@ -2631,9 +2586,8 @@ ctlstats( int res; again: - res = doquery(impl_ver, REQ_GET_CTLSTATS, 0, 0, 0, (char *)NULL, - &items, &itemsize, (void *)&ic, 0, - sizeof(struct info_control)); + res = doquery(impl_ver, REQ_GET_CTLSTATS, 0, 0, 0, NULL, &items, + &itemsize, (void *)&ic, 0, sizeof(*ic)); if (res == INFO_ERR_IMPL && impl_ver == IMPL_XNTPD) { impl_ver = IMPL_XNTPD_OLD; @@ -2641,44 +2595,44 @@ again: } if (res != 0) - return; + return; if (!check1item(items, fp)) - return; + return; - if (!checkitemsize(itemsize, sizeof(struct info_control))) - return; + if (!checkitemsize(itemsize, sizeof(*ic))) + return; - (void) fprintf(fp, "time since reset: %ld\n", - (u_long)ntohl(ic->ctltimereset)); - (void) fprintf(fp, "requests received: %ld\n", - (u_long)ntohl(ic->numctlreq)); - (void) fprintf(fp, "responses sent: %ld\n", - (u_long)ntohl(ic->numctlresponses)); - (void) fprintf(fp, "fragments sent: %ld\n", - (u_long)ntohl(ic->numctlfrags)); - (void) fprintf(fp, "async messages sent: %ld\n", - (u_long)ntohl(ic->numasyncmsgs)); - (void) fprintf(fp, "error msgs sent: %ld\n", - (u_long)ntohl(ic->numctlerrors)); - (void) fprintf(fp, "total bad pkts: %ld\n", - (u_long)ntohl(ic->numctlbadpkts)); - (void) fprintf(fp, "packet too short: %ld\n", - (u_long)ntohl(ic->numctltooshort)); - (void) fprintf(fp, "response on input: %ld\n", - (u_long)ntohl(ic->numctlinputresp)); - (void) fprintf(fp, "fragment on input: %ld\n", - (u_long)ntohl(ic->numctlinputfrag)); - (void) fprintf(fp, "error set on input: %ld\n", - (u_long)ntohl(ic->numctlinputerr)); - (void) fprintf(fp, "bad offset on input: %ld\n", - (u_long)ntohl(ic->numctlbadoffset)); - (void) fprintf(fp, "bad version packets: %ld\n", - (u_long)ntohl(ic->numctlbadversion)); - (void) fprintf(fp, "data in pkt too short: %ld\n", - (u_long)ntohl(ic->numctldatatooshort)); - (void) fprintf(fp, "unknown op codes: %ld\n", - (u_long)ntohl(ic->numctlbadop)); + fprintf(fp, "time since reset: %lu\n", + (u_long)ntohl(ic->ctltimereset)); + fprintf(fp, "requests received: %lu\n", + (u_long)ntohl(ic->numctlreq)); + fprintf(fp, "responses sent: %lu\n", + (u_long)ntohl(ic->numctlresponses)); + fprintf(fp, "fragments sent: %lu\n", + (u_long)ntohl(ic->numctlfrags)); + fprintf(fp, "async messages sent: %lu\n", + (u_long)ntohl(ic->numasyncmsgs)); + fprintf(fp, "error msgs sent: %lu\n", + (u_long)ntohl(ic->numctlerrors)); + fprintf(fp, "total bad pkts: %lu\n", + (u_long)ntohl(ic->numctlbadpkts)); + fprintf(fp, "packet too short: %lu\n", + (u_long)ntohl(ic->numctltooshort)); + fprintf(fp, "response on input: %lu\n", + (u_long)ntohl(ic->numctlinputresp)); + fprintf(fp, "fragment on input: %lu\n", + (u_long)ntohl(ic->numctlinputfrag)); + fprintf(fp, "error set on input: %lu\n", + (u_long)ntohl(ic->numctlinputerr)); + fprintf(fp, "bad offset on input: %lu\n", + (u_long)ntohl(ic->numctlbadoffset)); + fprintf(fp, "bad version packets: %lu\n", + (u_long)ntohl(ic->numctlbadversion)); + fprintf(fp, "data in pkt too short: %lu\n", + (u_long)ntohl(ic->numctldatatooshort)); + fprintf(fp, "unknown op codes: %lu\n", + (u_long)ntohl(ic->numctlbadop)); } @@ -2694,6 +2648,7 @@ clockstat( struct info_clock *cl; /* 8 is the maximum number of clocks which will fit in a packet */ u_long clist[min(MAXARGS, 8)]; + int qitemlim; int qitems; int items; int itemsize; @@ -2701,8 +2656,9 @@ clockstat( l_fp ts; struct clktype *clk; - for (qitems = 0; qitems < min(pcmd->nargs, 8); qitems++) - clist[qitems] = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(clist)); + for (qitems = 0; qitems < qitemlim; qitems++) + clist[qitems] = NSRCADR(&pcmd->argval[qitems].netnum); again: res = doquery(impl_ver, REQ_GET_CLOCKINFO, 0, qitems, @@ -2715,13 +2671,13 @@ again: } if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (!checkitemsize(itemsize, sizeof(struct info_clock))) - return; + return; while (items-- > 0) { (void) fprintf(fp, "clock address: %s\n", @@ -2790,8 +2746,8 @@ fudge( err = 0; - memset((char *)&fudgedata, 0, sizeof fudgedata); - fudgedata.clockadr = GET_INADDR(pcmd->argval[0].netnum); + ZERO(fudgedata); + fudgedata.clockadr = NSRCADR(&pcmd->argval[0].netnum); if (STREQ(pcmd->argval[1].string, "time1")) { fudgedata.which = htonl(FUDGE_TIME1); @@ -2866,6 +2822,7 @@ clkbug( /* 8 is the maximum number of clocks which will fit in a packet */ u_long clist[min(MAXARGS, 8)]; u_int32 ltemp; + int qitemlim; int qitems; int items; int itemsize; @@ -2873,8 +2830,9 @@ clkbug( int needsp; l_fp ts; - for (qitems = 0; qitems < min(pcmd->nargs, 8); qitems++) - clist[qitems] = GET_INADDR(pcmd->argval[qitems].netnum); + qitemlim = min(pcmd->nargs, COUNTOF(clist)); + for (qitems = 0; qitems < qitemlim; qitems++) + clist[qitems] = NSRCADR(&pcmd->argval[qitems].netnum); again: res = doquery(impl_ver, REQ_GET_CLKBUGINFO, 0, qitems, @@ -2887,13 +2845,13 @@ again: } if (res != 0) - return; + return; if (!checkitems(items, fp)) - return; + return; if (!checkitemsize(itemsize, sizeof(struct info_clkbug))) - return; + return; while (items-- > 0) { (void) fprintf(fp, "clock address: %s\n", @@ -2990,13 +2948,13 @@ again: tscale = 1e-9; #endif (void)fprintf(fp, "pll offset: %g s\n", - (int32_t)ntohl(ik->offset) * tscale); + (int32)ntohl(ik->offset) * tscale); (void)fprintf(fp, "pll frequency: %s ppm\n", fptoa((s_fp)ntohl(ik->freq), 3)); (void)fprintf(fp, "maximum error: %g s\n", - (u_long)ntohl(ik->maxerror) * 1e-6); + (u_long)ntohl(ik->maxerror) * tscale); (void)fprintf(fp, "estimated error: %g s\n", - (u_long)ntohl(ik->esterror) * 1e-6); + (u_long)ntohl(ik->esterror) * tscale); (void)fprintf(fp, "status: %04x ", status); #ifdef STA_PLL if (status & STA_PLL) (void)fprintf(fp, " pll"); @@ -3082,11 +3040,11 @@ again: (u_long)ntohl(ik->errcnt)); } -#define IF_LIST_FMT "%2d %c %48s %c %c %12.12s %03x %3d %2d %5d %5d %5d %2d %2d %3d %7d\n" -#define IF_LIST_FMT_STR "%2s %c %48s %c %c %12.12s %3s %3s %2s %5s %5s %5s %2s %2s %3s %7s\n" +#define IF_LIST_FMT "%2d %c %48s %c %c %12.12s %03lx %3lu %2lu %5lu %5lu %5lu %2lu %3lu %7lu\n" +#define IF_LIST_FMT_STR "%2s %c %48s %c %c %12.12s %3s %3s %2s %5s %5s %5s %2s %3s %7s\n" #define IF_LIST_AFMT_STR " %48s %c\n" -#define IF_LIST_LABELS "#", 'A', "Address/Mask/Broadcast", 'T', 'E', "IF name", "Flg", "TL", "#M", "recv", "sent", "drop", "S", "IX", "PC", "uptime" -#define IF_LIST_LINE "=====================================================================================================================\n" +#define IF_LIST_LABELS "#", 'A', "Address/Mask/Broadcast", 'T', 'E', "IF name", "Flg", "TL", "#M", "recv", "sent", "drop", "S", "PC", "uptime" +#define IF_LIST_LINE "==================================================================================================================\n" static void iflist( @@ -3097,8 +3055,8 @@ iflist( int res ) { - static char *actions = "?.+-"; - struct sockaddr_storage saddr; + static const char *actions = "?.+-"; + sockaddr_u saddr; if (res != 0) return; @@ -3113,51 +3071,31 @@ iflist( fprintf(fp, IF_LIST_LINE); while (items > 0) { - if (ntohl(ifs->v6_flag)) { - memcpy((char *)&GET_INADDR6(saddr), (char *)&ifs->unaddr.addr6, sizeof(ifs->unaddr.addr6)); - saddr.ss_family = AF_INET6; - } else { - memcpy((char *)&GET_INADDR(saddr), (char *)&ifs->unaddr.addr, sizeof(ifs->unaddr.addr)); - saddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - saddr.ss_len = SOCKLEN(&saddr); -#endif + SET_ADDR(saddr, ntohl(ifs->v6_flag), + ifs->unaddr.addr.s_addr, ifs->unaddr.addr6); fprintf(fp, IF_LIST_FMT, ntohl(ifs->ifnum), actions[(ifs->action >= 1 && ifs->action < 4) ? ifs->action : 0], stoa((&saddr)), 'A', ifs->ignore_packets ? 'D' : 'E', ifs->name, - ntohl(ifs->flags), - ntohl(ifs->last_ttl), - ntohl(ifs->num_mcast), - ntohl(ifs->received), - ntohl(ifs->sent), - ntohl(ifs->notsent), - ntohl(ifs->scopeid), - ntohl(ifs->ifindex), - ntohl(ifs->peercnt), - ntohl(ifs->uptime)); - - if (ntohl(ifs->v6_flag)) { - memcpy((char *)&GET_INADDR6(saddr), (char *)&ifs->unmask.addr6, sizeof(ifs->unmask.addr6)); - saddr.ss_family = AF_INET6; - } else { - memcpy((char *)&GET_INADDR(saddr), (char *)&ifs->unmask.addr, sizeof(ifs->unmask.addr)); - saddr.ss_family = AF_INET; - } -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - saddr.ss_len = SOCKLEN(&saddr); -#endif + (u_long)ntohl(ifs->flags), + (u_long)ntohl(ifs->last_ttl), + (u_long)ntohl(ifs->num_mcast), + (u_long)ntohl(ifs->received), + (u_long)ntohl(ifs->sent), + (u_long)ntohl(ifs->notsent), + (u_long)ntohl(ifs->scopeid), + (u_long)ntohl(ifs->peercnt), + (u_long)ntohl(ifs->uptime)); + + SET_ADDR(saddr, ntohl(ifs->v6_flag), + ifs->unmask.addr.s_addr, ifs->unmask.addr6); fprintf(fp, IF_LIST_AFMT_STR, stoa(&saddr), 'M'); if (!ntohl(ifs->v6_flag) && ntohl(ifs->flags) & (INT_BCASTOPEN)) { - memcpy((char *)&GET_INADDR(saddr), (char *)&ifs->unbcast.addr, sizeof(ifs->unbcast.addr)); - saddr.ss_family = AF_INET; -#ifdef HAVE_SA_LEN_IN_STRUCT_SOCKADDR - saddr.ss_len = SOCKLEN(&saddr); -#endif + SET_ADDR(saddr, ntohl(ifs->v6_flag), + ifs->unbcast.addr.s_addr, ifs->unbcast.addr6); fprintf(fp, IF_LIST_AFMT_STR, stoa(&saddr), 'B'); } diff --git a/contrib/ntp/ntpq/Makefile.am b/contrib/ntp/ntpq/Makefile.am index 7cd3f0aa0..50c072a0f 100644 --- a/contrib/ntp/ntpq/Makefile.am +++ b/contrib/ntp/ntpq/Makefile.am @@ -1,42 +1,131 @@ -AUTOMAKE_OPTIONS= ../util/ansi2knr +NULL= -bin_PROGRAMS= ntpq -AM_CPPFLAGS= -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +EXTRA_PROGRAMS= ntpq +bin_PROGRAMS= $(NTPQ_DB) +libexec_PROGRAMS= $(NTPQ_DL) +sbin_PROGRAMS= $(NTPQ_DS) + +AM_CFLAGS = $(CFLAGS_NTP) + +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(LIBOPTS_CFLAGS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +AM_LDFLAGS = $(LDFLAGS_NTP) # LDADD might need RESLIB and ADJLIB -ntpq_LDADD= version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a -DISTCLEANFILES= .version version.c +ntpq_LDADD = version.o $(LIBOPTS_LDADD) +ntpq_LDADD += ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) +ntpq_LDADD += $(PTHREAD_LIBS) $(EDITLINE_LIBS) +ntpq_LDADD += $(LDADD_NTP) noinst_HEADERS= ntpq.h +noinst_LIBRARIES= libntpq.a +libntpq_a_CFLAGS= -DNO_MAIN_ALLOWED -DBUILD_AS_LIB +CLEANFILES= +DISTCLEANFILES= .version version.c config.log $(man_MANS) ETAGS_ARGS= Makefile.am -EXTRA_DIST= ntpq-opts.def ntpq.1 ntpq-opts.texi ntpq-opts.menu -BUILT_SOURCES= ntpq-opts.c ntpq-opts.h ntpq.1 ntpq-opts.texi ntpq-opts.menu -man_MANS= ntpq.1 -run_ag= cd $(srcdir) && autogen -L ../include --writable -std_def_list= $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ - $(top_srcdir)/include/copyright.def \ - $(top_srcdir)/include/homerc.def \ - $(top_srcdir)/include/version.def +EXTRA_DIST= \ + invoke-ntpq.menu \ + invoke-ntpq.texi \ + ntpq-opts.def \ + ntpq.1ntpqman \ + ntpq.1ntpqmdoc \ + ntpq.man.in \ + ntpq.mdoc.in \ + ntpq.html \ + ntpq.texi \ + $(NULL) + +BUILT_SOURCES= ntpq-opts.c ntpq-opts.h + +html_DATA= \ + $(srcdir)/ntpq.html \ + $(NULL) + +noinst_DATA= \ + $(srcdir)/invoke-ntpq.menu \ + $(srcdir)/invoke-ntpq.texi \ + $(srcdir)/ntpq.man.in \ + $(srcdir)/ntpq.mdoc.in \ + $(NULL) + +install-data-local: install-html + +man1_MANS= +man8_MANS= +man_MANS= ntpq.$(NTPQ_MS) + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) ntpq_SOURCES= ntpq.c ntpq-subs.c ntpq-opts.c ntpq-opts.h +libntpq_a_SOURCES = libntpq.c libntpq.h libntpq_subs.c + $(srcdir)/ntpq-opts.h: $(srcdir)/ntpq-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpq-opts.c: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) ntpq-opts.def -$(srcdir)/ntpq.1: $(srcdir)/ntpq-opts.def $(std_def_list) - $(run_ag) -Tagman1.tpl -bntpq ntpq-opts.def +### + +$(srcdir)/ntpq.1ntpqman: $(srcdir)/ntpq-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpqman -Tagman-cmd.tpl ntpq-opts.def + +$(srcdir)/ntpq.man.in: $(srcdir)/ntpq.1ntpqman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpq.1ntpqman > $(srcdir)/ntpq.man.in+ + mv $(srcdir)/ntpq.man.in+ $(srcdir)/ntpq.man.in + +### + +$(srcdir)/ntpq.1ntpqmdoc: $(srcdir)/ntpq-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpqmdoc -Tagmdoc-cmd.tpl ntpq-opts.def + +$(srcdir)/ntpq.mdoc.in: $(srcdir)/ntpq.1ntpqmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpq.1ntpqmdoc > $(srcdir)/ntpq.mdoc.in+ + mv $(srcdir)/ntpq.mdoc.in+ $(srcdir)/ntpq.mdoc.in + +### + +ntpq.$(NTPQ_MS): $(srcdir)/ntpq.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpq.$(NTPQ_MS)+:$(srcdir)/ntpq.$(MANTAGFMT).in + mv ntpq.$(NTPQ_MS)+ ntpq.$(NTPQ_MS) + +### + +$(srcdir)/invoke-ntpq.menu: $(srcdir)/invoke-ntpq.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpq.texi: $(srcdir)/ntpq-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpq-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +$(srcdir)/ntpq.html: $(srcdir)/ntpq.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntpq.html ntpq.texi || true ) -$(srcdir)/ntpq-opts.texi $(srcdir)/ntpq-opts.menu: $(srcdir)/ntpq-opts.def $(std_def_list) - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpq-opts.def +### -$(PROGRAMS): $(LDADD) +$(PROGRAMS): version.o -../libntp/libntp.a: - cd ../libntp && $(MAKE) +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +version.c: $(ntpq_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpq + +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o -version.o: $(ntpq_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpq - $(COMPILE) -c version.c +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/check-libopts.mf +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/ntpq/Makefile.in b/contrib/ntp/ntpq/Makefile.in index 0c5fcaeb6..c93c677bb 100644 --- a/contrib/ntp/ntpq/Makefile.in +++ b/contrib/ntp/ntpq/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -15,8 +14,69 @@ @SET_MAKE@ +# we traditionally installed software in bindir, while it should have gone +# in sbindir. Now that we offer a choice, look in the "other" installation +# subdir to warn folks if there is another version there. + + + VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -35,45 +95,123 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr -bin_PROGRAMS = ntpq$(EXEEXT) +EXTRA_PROGRAMS = ntpq$(EXEEXT) subdir = ntpq -DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) -am_ntpq_OBJECTS = ntpq$U.$(OBJEXT) ntpq-subs$U.$(OBJEXT) \ - ntpq-opts$U.$(OBJEXT) +LIBRARIES = $(noinst_LIBRARIES) +ARFLAGS = cru +AM_V_AR = $(am__v_AR_@AM_V@) +am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@) +am__v_AR_0 = @echo " AR " $@; +am__v_AR_1 = +libntpq_a_AR = $(AR) $(ARFLAGS) +libntpq_a_LIBADD = +am_libntpq_a_OBJECTS = libntpq_a-libntpq.$(OBJEXT) \ + libntpq_a-libntpq_subs.$(OBJEXT) +libntpq_a_OBJECTS = $(am_libntpq_a_OBJECTS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(sbin_PROGRAMS) +am_ntpq_OBJECTS = ntpq.$(OBJEXT) ntpq-subs.$(OBJEXT) \ + ntpq-opts.$(OBJEXT) ntpq_OBJECTS = $(am_ntpq_OBJECTS) am__DEPENDENCIES_1 = -ntpq_DEPENDENCIES = version.o $(am__DEPENDENCIES_1) ../libntp/libntp.a +ntpq_DEPENDENCIES = version.o $(am__DEPENDENCIES_1) ../libntp/libntp.a \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ -SOURCES = $(ntpq_SOURCES) -DIST_SOURCES = $(ntpq_SOURCES) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libntpq_a_SOURCES) $(ntpq_SOURCES) +DIST_SOURCES = $(libntpq_a_SOURCES) $(ntpq_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -95,50 +233,111 @@ am__nobase_list = $(am__nobase_strip_setup); \ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 NROFF = nroff -MANS = $(man_MANS) +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/bincheck.mf \ + $(top_srcdir)/check-libopts.mf $(top_srcdir)/depsver.mf \ + $(top_srcdir)/includes.mf $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -146,8 +345,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -157,15 +359,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -173,23 +436,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -236,31 +535,75 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = ../util/ansi2knr -AM_CPPFLAGS = -I$(top_srcdir)/include $(LIBOPTS_CFLAGS) +NULL = +bin_PROGRAMS = $(NTPQ_DB) +libexec_PROGRAMS = $(NTPQ_DL) +sbin_PROGRAMS = $(NTPQ_DS) +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(LIBOPTS_CFLAGS) $(CPPFLAGS_NTP) +AM_LDFLAGS = $(LDFLAGS_NTP) # LDADD might need RESLIB and ADJLIB -ntpq_LDADD = version.o @READLINE_LIBS@ $(LIBOPTS_LDADD) ../libntp/libntp.a -DISTCLEANFILES = .version version.c +ntpq_LDADD = version.o $(LIBOPTS_LDADD) ../libntp/libntp.a \ + $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) $(EDITLINE_LIBS) \ + $(LDADD_NTP) noinst_HEADERS = ntpq.h +noinst_LIBRARIES = libntpq.a +libntpq_a_CFLAGS = -DNO_MAIN_ALLOWED -DBUILD_AS_LIB +CLEANFILES = check-libopts check-libntp .deps-ver +DISTCLEANFILES = .version version.c config.log $(man_MANS) ETAGS_ARGS = Makefile.am -EXTRA_DIST = ntpq-opts.def ntpq.1 ntpq-opts.texi ntpq-opts.menu -BUILT_SOURCES = ntpq-opts.c ntpq-opts.h ntpq.1 ntpq-opts.texi ntpq-opts.menu -man_MANS = ntpq.1 -run_ag = cd $(srcdir) && autogen -L ../include --writable -std_def_list = $(top_srcdir)/include/debug-opt.def \ - $(top_srcdir)/include/autogen-version.def \ - $(top_srcdir)/include/copyright.def \ - $(top_srcdir)/include/homerc.def \ - $(top_srcdir)/include/version.def +EXTRA_DIST = \ + invoke-ntpq.menu \ + invoke-ntpq.texi \ + ntpq-opts.def \ + ntpq.1ntpqman \ + ntpq.1ntpqmdoc \ + ntpq.man.in \ + ntpq.mdoc.in \ + ntpq.html \ + ntpq.texi \ + $(NULL) + +BUILT_SOURCES = ntpq-opts.c ntpq-opts.h check-libopts check-libntp \ + .deps-ver +html_DATA = \ + $(srcdir)/ntpq.html \ + $(NULL) + +noinst_DATA = \ + $(srcdir)/invoke-ntpq.menu \ + $(srcdir)/invoke-ntpq.texi \ + $(srcdir)/ntpq.man.in \ + $(srcdir)/ntpq.mdoc.in \ + $(NULL) + +man1_MANS = +man8_MANS = +man_MANS = ntpq.$(NTPQ_MS) +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) ntpq_SOURCES = ntpq.c ntpq-subs.c ntpq-opts.c ntpq-opts.h +libntpq_a_SOURCES = libntpq.c libntpq.h libntpq_subs.c +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include all: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -272,7 +615,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ntpq/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign ntpq/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -281,6 +623,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/bincheck.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -290,16 +633,29 @@ $(top_srcdir)/configure: $(am__configure_deps) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): + +clean-noinstLIBRARIES: + -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) + +libntpq.a: $(libntpq_a_OBJECTS) $(libntpq_a_DEPENDENCIES) $(EXTRA_libntpq_a_DEPENDENCIES) + $(AM_V_at)-rm -f libntpq.a + $(AM_V_AR)$(libntpq_a_AR) libntpq.a $(libntpq_a_OBJECTS) $(libntpq_a_LIBADD) + $(AM_V_at)$(RANLIB) libntpq.a install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p || test -f $$p1; \ - then echo "$$p"; echo "$$p"; else :; fi; \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ - sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ @@ -320,7 +676,8 @@ uninstall-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' `; \ + -e 's/$$/$(EXEEXT)/' \ + `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files @@ -333,66 +690,189 @@ clean-binPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -ntpq$(EXEEXT): $(ntpq_OBJECTS) $(ntpq_DEPENDENCIES) +install-libexecPROGRAMS: $(libexec_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(libexecdir)" && rm -f $$files + +clean-libexecPROGRAMS: + @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +ntpq$(EXEEXT): $(ntpq_OBJECTS) $(ntpq_DEPENDENCIES) $(EXTRA_ntpq_DEPENDENCIES) @rm -f ntpq$(EXEEXT) - $(LINK) $(ntpq_OBJECTS) $(ntpq_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(ntpq_OBJECTS) $(ntpq_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-opts$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-subs$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libntpq_a-libntpq.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libntpq_a-libntpq_subs.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq-subs.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpq.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +libntpq_a-libntpq.o: libntpq.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq.o -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq.Tpo -c -o libntpq_a-libntpq.o `test -f 'libntpq.c' || echo '$(srcdir)/'`libntpq.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libntpq_a-libntpq.Tpo $(DEPDIR)/libntpq_a-libntpq.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='libntpq.c' object='libntpq_a-libntpq.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -ntpq_.c: ntpq.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpq.c; then echo $(srcdir)/ntpq.c; else echo ntpq.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpq-opts_.c: ntpq-opts.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpq-opts.c; then echo $(srcdir)/ntpq-opts.c; else echo ntpq-opts.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpq-subs_.c: ntpq-subs.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/ntpq-subs.c; then echo $(srcdir)/ntpq-subs.c; else echo ntpq-subs.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -ntpq_.$(OBJEXT) ntpq_.lo ntpq-opts_.$(OBJEXT) ntpq-opts_.lo \ -ntpq-subs_.$(OBJEXT) ntpq-subs_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq.o `test -f 'libntpq.c' || echo '$(srcdir)/'`libntpq.c + +libntpq_a-libntpq.obj: libntpq.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq.obj -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq.Tpo -c -o libntpq_a-libntpq.obj `if test -f 'libntpq.c'; then $(CYGPATH_W) 'libntpq.c'; else $(CYGPATH_W) '$(srcdir)/libntpq.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libntpq_a-libntpq.Tpo $(DEPDIR)/libntpq_a-libntpq.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='libntpq.c' object='libntpq_a-libntpq.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq.obj `if test -f 'libntpq.c'; then $(CYGPATH_W) 'libntpq.c'; else $(CYGPATH_W) '$(srcdir)/libntpq.c'; fi` + +libntpq_a-libntpq_subs.o: libntpq_subs.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq_subs.o -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq_subs.Tpo -c -o libntpq_a-libntpq_subs.o `test -f 'libntpq_subs.c' || echo '$(srcdir)/'`libntpq_subs.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libntpq_a-libntpq_subs.Tpo $(DEPDIR)/libntpq_a-libntpq_subs.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='libntpq_subs.c' object='libntpq_a-libntpq_subs.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq_subs.o `test -f 'libntpq_subs.c' || echo '$(srcdir)/'`libntpq_subs.c + +libntpq_a-libntpq_subs.obj: libntpq_subs.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -MT libntpq_a-libntpq_subs.obj -MD -MP -MF $(DEPDIR)/libntpq_a-libntpq_subs.Tpo -c -o libntpq_a-libntpq_subs.obj `if test -f 'libntpq_subs.c'; then $(CYGPATH_W) 'libntpq_subs.c'; else $(CYGPATH_W) '$(srcdir)/libntpq_subs.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libntpq_a-libntpq_subs.Tpo $(DEPDIR)/libntpq_a-libntpq_subs.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='libntpq_subs.c' object='libntpq_a-libntpq_subs.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libntpq_a_CFLAGS) $(CFLAGS) -c -o libntpq_a-libntpq_subs.obj `if test -f 'libntpq_subs.c'; then $(CYGPATH_W) 'libntpq_subs.c'; else $(CYGPATH_W) '$(srcdir)/libntpq_subs.c'; fi` mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs -install-man1: $(man_MANS) +install-man1: $(man1_MANS) $(man_MANS) @$(NORMAL_INSTALL) - test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" - @list=''; test -n "$(man1dir)" || exit 0; \ - { for i in $$list; do echo "$$i"; done; \ - l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ - sed -n '/\.1[a-z]*$$/p'; \ + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ } | while read p; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; echo "$$p"; \ @@ -415,36 +895,87 @@ install-man1: $(man_MANS) uninstall-man1: @$(NORMAL_UNINSTALL) - @list=''; test -n "$(man1dir)" || exit 0; \ + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ files=`{ for i in $$list; do echo "$$i"; done; \ l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ - test -z "$$files" || { \ - echo " ( cd '$(DESTDIR)$(man1dir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(man1dir)" && rm -f $$files; } - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -456,15 +987,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -473,24 +1000,26 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) - @list='$(MANS)'; if test -n "$$list"; then \ - list=`for p in $$list; do \ - if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ - if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \ - if test -n "$$list" && \ - grep 'ab help2man is required to generate this page' $$list >/dev/null; then \ - echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \ - grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \ - echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \ - echo " typically \`make maintainer-clean' will remove them" >&2; \ - exit 1; \ - else :; fi; \ - else :; fi @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -523,9 +1052,9 @@ distdir: $(DISTFILES) check-am: all-am check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-am -all-am: Makefile $(PROGRAMS) $(MANS) $(HEADERS) +all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -539,13 +1068,19 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -558,7 +1093,9 @@ maintainer-clean-generic: -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-noinstLIBRARIES clean-sbinPROGRAMS \ + mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) @@ -578,14 +1115,16 @@ info: info-am info-am: -install-data-am: install-man +install-data-am: install-data-local install-htmlDATA install-man install-dvi: install-dvi-am install-dvi-am: -install-exec-am: install-binPROGRAMS - +install-exec-am: install-binPROGRAMS install-libexecPROGRAMS \ + install-sbinPROGRAMS + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-am install-html-am: @@ -594,7 +1133,7 @@ install-info: install-info-am install-info-am: -install-man: install-man1 +install-man: install-man1 install-man8 install-pdf: install-pdf-am @@ -613,7 +1152,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -624,49 +1163,175 @@ ps: ps-am ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man +uninstall-am: uninstall-binPROGRAMS uninstall-htmlDATA \ + uninstall-libexecPROGRAMS uninstall-man uninstall-sbinPROGRAMS -uninstall-man: uninstall-man1 +uninstall-man: uninstall-man1 uninstall-man8 -.MAKE: ../util/ansi2knr all check install install-am install-strip +.MAKE: all check install install-am install-exec-am install-strip -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags distclean distclean-compile \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ + clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-noinstLIBRARIES clean-sbinPROGRAMS \ + cscopelist-am ctags ctags-am distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-man1 install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-kr mostlyclean-libtool pdf pdf-am ps ps-am tags \ - uninstall uninstall-am uninstall-binPROGRAMS uninstall-man \ - uninstall-man1 + install-binPROGRAMS install-data install-data-am \ + install-data-local install-dvi install-dvi-am install-exec \ + install-exec-am install-exec-hook install-html install-html-am \ + install-htmlDATA install-info install-info-am \ + install-libexecPROGRAMS install-man install-man1 install-man8 \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-htmlDATA uninstall-libexecPROGRAMS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinPROGRAMS +.PRECIOUS: Makefile + + +install-data-local: install-html $(srcdir)/ntpq-opts.h: $(srcdir)/ntpq-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + $(srcdir)/ntpq-opts.c: $(srcdir)/ntpq-opts.def $(std_def_list) $(run_ag) ntpq-opts.def -$(srcdir)/ntpq.1: $(srcdir)/ntpq-opts.def $(std_def_list) - $(run_ag) -Tagman1.tpl -bntpq ntpq-opts.def +### -$(srcdir)/ntpq-opts.texi $(srcdir)/ntpq-opts.menu: $(srcdir)/ntpq-opts.def $(std_def_list) - $(run_ag) -Taginfo.tpl -DLEVEL=section ntpq-opts.def +$(srcdir)/ntpq.1ntpqman: $(srcdir)/ntpq-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpqman -Tagman-cmd.tpl ntpq-opts.def -$(PROGRAMS): $(LDADD) +$(srcdir)/ntpq.man.in: $(srcdir)/ntpq.1ntpqman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpq.1ntpqman > $(srcdir)/ntpq.man.in+ + mv $(srcdir)/ntpq.man.in+ $(srcdir)/ntpq.man.in -../libntp/libntp.a: - cd ../libntp && $(MAKE) +### + +$(srcdir)/ntpq.1ntpqmdoc: $(srcdir)/ntpq-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpqmdoc -Tagmdoc-cmd.tpl ntpq-opts.def + +$(srcdir)/ntpq.mdoc.in: $(srcdir)/ntpq.1ntpqmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpq.1ntpqmdoc > $(srcdir)/ntpq.mdoc.in+ + mv $(srcdir)/ntpq.mdoc.in+ $(srcdir)/ntpq.mdoc.in + +### + +ntpq.$(NTPQ_MS): $(srcdir)/ntpq.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpq.$(NTPQ_MS)+:$(srcdir)/ntpq.$(MANTAGFMT).in + mv ntpq.$(NTPQ_MS)+ ntpq.$(NTPQ_MS) -$(top_srcdir)/version : - cd $(top_srcdir) && $(MAKE) version +### -version.o: $(ntpq_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/version - env CSET=`cat $(top_srcdir)/version` $(top_builddir)/scripts/mkver ntpq - $(COMPILE) -c version.c +$(srcdir)/invoke-ntpq.menu: $(srcdir)/invoke-ntpq.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpq.texi: $(srcdir)/ntpq-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpq-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +$(srcdir)/ntpq.html: $(srcdir)/ntpq.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntpq.html ntpq.texi || true ) + +### + +$(PROGRAMS): version.o + +$(top_srcdir)/sntp/scm-rev: + cd ../sntp && $(MAKE) $(AM_MAKEFLAGS) check-scm-rev + +version.c: $(ntpq_OBJECTS) ../libntp/libntp.a Makefile $(top_srcdir)/sntp/scm-rev + env CSET=`cat $(top_srcdir)/sntp/scm-rev` $(top_builddir)/scripts/build/mkver ntpq + +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o + +install-exec-hook: + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ + done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ + done + +# + +check-libopts: ../sntp/libopts/libopts.la + @echo stamp > $@ + +../sntp/libopts/libopts.la: + -cd ../sntp/libopts && $(MAKE) $(AM_MAKEFLAGS) libopts.la + +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/contrib/ntp/ntpq/ntpq-opts.menu b/contrib/ntp/ntpq/invoke-ntpq.menu similarity index 100% rename from contrib/ntp/ntpq/ntpq-opts.menu rename to contrib/ntp/ntpq/invoke-ntpq.menu diff --git a/contrib/ntp/ntpq/invoke-ntpq.texi b/contrib/ntp/ntpq/invoke-ntpq.texi new file mode 100644 index 000000000..fa0f5d7db --- /dev/null +++ b/contrib/ntp/ntpq/invoke-ntpq.texi @@ -0,0 +1,1098 @@ +@node ntpq Invocation +@section Invoking ntpq +@pindex ntpq +@cindex standard NTP query program +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntpq.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:39:27 PM by AutoGen 5.18.5 +# From the definitions ntpq-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + +The +@code{ntpq} +utility program is used to query NTP servers which +implement the standard NTP mode 6 control message formats defined +in Appendix B of the NTPv3 specification RFC1305, requesting +information about current state and/or changes in that state. +The same formats are used in NTPv4, although some of the +variables have changed and new ones added. The description on this +page is for the NTPv4 variables. +The program may be run either in interactive mode or controlled using +command line arguments. +Requests to read and write arbitrary +variables can be assembled, with raw and pretty-printed output +options being available. +The +@code{ntpq} +utility can also obtain and print a +list of peers in a common format by sending multiple queries to the +server. + +If one or more request options is included on the command line +when +@code{ntpq} +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +@code{ntpq} +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +@code{ntpq} +utility will prompt for +commands if the standard input is a terminal device. + +@code{ntpq} +uses NTP mode 6 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +@code{ntpq} +utility makes +one attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. + +Specifying a +command line option other than +@code{-i} +or +@code{-n} +will +cause the specified query (queries) to be sent to the indicated +host(s) immediately. +Otherwise, +@code{ntpq} +will attempt to read +interactive format commands from the standard input. +@subsubsection Internal Commands +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. + +A +number of interactive format commands are executed entirely within +the +@code{ntpq} +utility itself and do not result in NTP mode 6 +requests being sent to a server. +These are described following. +@table @asis +@item @code{?} @code{[@kbd{command_keyword}]} +@item @code{help} @code{[@kbd{command_keyword}]} +A +@quoteleft{}?@quoteright{} +by itself will print a list of all the command +keywords known to this incarnation of +@code{ntpq} +A +@quoteleft{}?@quoteright{} +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +@code{ntpq} +than this manual +page. +@item @code{addvars} @kbd{variable_name}@code{[@code{=value}]} @code{...} +@item @code{rmvars} @kbd{variable_name} @code{...} +@item @code{clearvars} +@item @code{showvars} +The data carried by NTP mode 6 messages consists of a list of +items of the form +@quoteleft{}variable_name=value@quoteright{}, +where the +@quoteleft{}=value@quoteright{} +is ignored, and can be omitted, +in requests to the server to read variables. +The +@code{ntpq} +utility maintains an internal list in which data to be included in control +messages can be assembled, and sent using the +@code{readlist} +and +@code{writelist} +commands described below. +The +@code{addvars} +command allows variables and their optional values to be added to +the list. +If more than one variable is to be added, the list should +be comma-separated and not contain white space. +The +@code{rmvars} +command can be used to remove individual variables from the list, +while the +@code{clearlist} +command removes all variables from the +list. +The +@code{showvars} +command displays the current list of optional variables. +@item @code{authenticate} @code{[yes | no]} +Normally +@code{ntpq} +does not authenticate requests unless +they are write requests. +The command +@quoteleft{}authenticate yes@quoteright{} +causes +@code{ntpq} +to send authentication with all requests it +makes. +Authenticated requests causes some servers to handle +requests slightly differently, and can occasionally melt the CPU in +fuzzballs if you turn authentication on before doing a +@code{peer} +display. +The command +@quoteleft{}authenticate@quoteright{} +causes +@code{ntpq} +to display whether or not +@code{ntpq} +is currently autheinticating requests. +@item @code{cooked} +Causes output from query commands to be "cooked", so that +variables which are recognized by +@code{ntpq} +will have their +values reformatted for human consumption. +Variables which +@code{ntpq} +thinks should have a decodable value but didn't are +marked with a trailing +@quoteleft{}?@quoteright{}. +@item @code{debug} @code{[@code{more} | @code{less} | @code{off}]} +With no argument, displays the current debug level. +Otherwise, the debug level is changed to the indicated level. +@item @code{delay} @kbd{milliseconds} +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +@item @code{exit} +Exit +@code{ntpq} +@item @code{host} @kbd{hostname} +Set the host to which future queries will be sent. +@kbd{hostname} +may be either a host name or a numeric address. +@item @code{hostnames} @code{[@code{yes} | @code{no}]} +If +@code{yes} +is specified, host names are printed in +information displays. +If +@code{no} +is specified, numeric +addresses are printed instead. +The default is +@code{yes}, +unless +modified using the command line +@code{-n} +switch. +@item @code{keyid} @kbd{keyid} +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to the +@code{controlkey} +key number the server has been configured to use for this +purpose. +@item @code{keytype} @code{[@code{md5} | @code{OpenSSLDigestType}]} +Specify the type of key to use for authenticating requests. +@code{md5} +is alway supported. +If +@code{ntpq} +was built with OpenSSL support, +any digest type supported by OpenSSL can also be provided. +If no argument is given, the current +@code{keytype} +is displayed. +@item @code{ntpversion} @code{[@code{1} | @code{2} | @code{3} | @code{4}]} +Sets the NTP version number which +@code{ntpq} +claims in +packets. +Defaults to 3, and note that mode 6 control messages (and +modes, for that matter) didn't exist in NTP version 1. +There appear +to be no servers left which demand version 1. +With no argument, displays the current NTP version that will be used +when communicating with servers. +@item @code{passwd} +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +@code{poll} +@kbd{n} +@code{verbose} +@item @code{quit} +Exit +@code{ntpq} +@item @code{raw} +Causes all output from query commands is printed as received +from the remote server. +The only formating/interpretation done on +the data is to transform nonascii data into a printable (but barely +understandable) form. +@item @code{timeout} @kbd{milliseconds} +Specify a timeout period for responses to server queries. +The +default is about 5000 milliseconds. +Note that since +@code{ntpq} +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +@item @code{version} +Print the version of the +@code{ntpq} +program. +@end table + +@subsubsection Control Message Commands +Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode-6 message to the server and expect a single response message. +The exceptions are the +@code{peers} +command, which sends a series of messages, +and the +@code{mreadlist} +and +@code{mreadvar} +commands, which iterate over a range of associations. +@table @asis +@item @code{associations} +Display a list of mobilized associations in the form: +@example +ind assid status conf reach auth condition last_event cnt +@end example +@table @asis +@item Sy String Ta Sy Description +@item @code{ind} @code{Ta} @code{index} @code{on} @code{this} @code{list} +@item @code{assid} @code{Ta} @code{association} @code{ID} +@item @code{status} @code{Ta} @code{peer} @code{status} @code{word} +@item @code{conf} @code{Ta} @code{yes}: @code{persistent,} @code{no}: @code{ephemeral} +@item @code{reach} @code{Ta} @code{yes}: @code{reachable,} @code{no}: @code{unreachable} +@item @code{auth} @code{Ta} @code{ok}, @code{yes}, @code{bad} @code{and} @code{none} +@item @code{condition} @code{Ta} @code{selection} @code{status} @code{(see} @code{the} @code{select} @code{field} @code{of} @code{the} @code{peer} @code{status} @code{word)} +@item @code{last_event} @code{Ta} @code{event} @code{report} @code{(see} @code{the} @code{event} @code{field} @code{of} @code{the} @code{peer} @code{status} @code{word)} +@item @code{cnt} @code{Ta} @code{event} @code{count} @code{(see} @code{the} @code{count} @code{field} @code{of} @code{the} @code{peer} @code{status} @code{word)} +@end table +@item @code{authinfo} +Display the authentication statistics. +@item @code{clockvar} @kbd{assocID} @code{[@kbd{name}@code{[@code{=}@kbd{value}]}]} @code{[...]} +@item @code{cv} @kbd{assocID} @code{[@kbd{name}@code{[@code{=}@kbd{value}]}]} @code{[...]} +Display a list of clock variables for those associations supporting a reference clock. +@item @code{:config} @code{[...]} +Send the remainder of the command line, including whitespace, to the server as a run-time configuration command in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is of course required. +@item @code{config-from-file} @kbd{filename} +Send the each line of +@kbd{filename} +to the server as run-time configuration commands in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is required. +@item @code{ifstats} +Display statistics for each local network address. Authentication is required. +@item @code{iostats} +Display network and reference clock I/O statistics. +@item @code{kerninfo} +Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable. +@item @code{lassociations} +Perform the same function as the associations command, except display mobilized and unmobilized associations. +@item @code{lopeers} @code{[@code{-4} | @code{-6}]} +Obtain and print a list of all peers and clients showing +@kbd{dstadr} +(associated with any given IP version). +@item @code{lpeers} @code{[@code{-4} | @code{-6}]} +Print a peer spreadsheet for the appropriate IP version(s). +@kbd{dstadr} +(associated with any given IP version). +@item @code{monstats} +Display monitor facility statistics. +@item @code{mrulist} @code{[@code{limited} | @code{kod} | @code{mincount}=@kbd{count} | @code{laddr}=@kbd{localaddr} | @code{sort}=@kbd{sortorder} | @code{resany}=@kbd{hexmask} | @code{resall}=@kbd{hexmask}]} +Obtain and print traffic counts collected and maintained by the monitor facility. +With the exception of +@code{sort}=@kbd{sortorder}, +the options filter the list returned by +@code{ntpd.} +The +@code{limited} +and +@code{kod} +options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. +The +@code{mincount}=@kbd{count} +option filters entries representing less than +@kbd{count} +packets. +The +@code{laddr}=@kbd{localaddr} +option filters entries for packets received on any local address other than +@kbd{localaddr}. +@code{resany}=@kbd{hexmask} +and +@code{resall}=@kbd{hexmask} +filter entries containing none or less than all, respectively, of the bits in +@kbd{hexmask}, +which must begin with +@code{0x}. +The +@kbd{sortorder} +defaults to +@code{lstint} +and may be any of +@code{addr}, +@code{count}, +@code{avgint}, +@code{lstint}, +or any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: +@table @asis +@item Column +Description +@item @code{lstint} +Interval in s between the receipt of the most recent packet from this address and the completion of the retrieval of the MRU list by +@code{ntpq} +@item @code{avgint} +Average interval in s between packets from this address. +@item @code{rstr} +Restriction flags associated with this address. +Most are copied unchanged from the matching +@code{restrict} +command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this address triggered a rate control response. +@item @code{r} +Rate control indicator, either +a period, +@code{L} +or +@code{K} +for no rate control response, +rate limiting by discarding, or rate limiting with a KoD response, respectively. +@item @code{m} +Packet mode. +@item @code{v} +Packet version number. +@item @code{count} +Packets received from this address. +@item @code{rport} +Source port of last packet from this address. +@item @code{remote} @code{address} +DNS name, numeric address, or address followed by +claimed DNS name which could not be verified in parentheses. +@end table +@item @code{mreadvar} @code{assocID} @code{assocID} @code{[@kbd{variable_name}@code{[=@kbd{value}]} ...]} +@item @code{mrv} @code{assocID} @code{assocID} @code{[@kbd{variable_name}@code{[=@kbd{value}]} ...]} +Perform the same function as the +@code{readvar} +command, except for a range of association IDs. +This range is determined from the association list cached by the most recent +@code{associations} +command. +@item @code{opeers} @code{[@code{-4} | @code{-6}]} +Obtain and print the old-style list of all peers and clients showing +@kbd{dstadr} +(associated with any given IP version), +rather than the +@kbd{refid}. +@item @code{passociations} +Perform the same function as the +@code{associations} +command, +except that it uses previously stored data rather than making a new query. +@item @code{peers} +Display a list of peers in the form: +@example +[tally]remote refid st t when pool reach delay offset jitter +@end example +@table @asis +@item Variable +Description +@item @code{[tally]} +single-character code indicating current value of the +@code{select} +field of the +.Lk decode.html#peer "peer status word" +@item @code{remote} +host name (or IP number) of peer. +The value displayed will be truncated to 15 characters unless the +@code{-w} +flag is given, in which case the full value will be displayed +on the first line, +and the remaining data is displayed on the next line. +@item @code{refid} +association ID or +.Lk decode.html#kiss "'kiss code" +@item @code{st} +stratum +@item @code{t} +@code{u}: +unicast or manycast client, +@code{b}: +broadcast or multicast client, +@code{l}: +local (reference clock), +@code{s}: +symmetric (peer), +@code{A}: +manycast server, +@code{B}: +broadcast server, +@code{M}: +multicast server +@item @code{when} +sec/min/hr since last received packet +@item @code{poll} +poll interval (log2 s) +@item @code{reach} +reach shift register (octal) +@item @code{delay} +roundtrip delay +@item @code{offset} +offset of server relative to this host +@item @code{jitter} +jitter +@end table +@item @code{apeers} +Display a list of peers in the form: +@example +[tally]remote refid assid st t when pool reach delay offset jitter +@end example +where the output is just like the +@code{peers} +command except that the +@code{refid} +is displayed in hex format and the association number is also displayed. +@item @code{pstats} @kbd{assocID} +Show the statistics for the peer with the given +@kbd{assocID}. +@item @code{readlist} @kbd{assocID} +@item @code{rl} @kbd{assocID} +Read the system or peer variables included in the variable list. +@item @code{readvar} @kbd{assocID} @kbd{name}@code{[=@kbd{value}]} @code{[, ...]} +@item @code{rv} @kbd{assocID} @kbd{name}@code{[=@kbd{value}]} @code{[, ...]} +Display the specified variables. +If +@kbd{assocID} +is zero, the variables are from the +@ref{System Variables} +name space, otherwise they are from the +@ref{Peer Variables} +name space. +The +@kbd{assocID} +is required, as the same name can occur in both spaces. +If no +@kbd{name} +is included, all operative variables in the name space are displayed. + +In this case only, if the +@kbd{assocID} +is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds +and frequency values in parts-per-million (PPM). +Some NTP timestamps are represented in the format +YYYYMMDDTTTT , +where YYYY is the year, +MM the month of year, +DD the day of month and +TTTT the time of day. +@item @code{reslist} +Show the access control (restrict) list for +@code{ntpq} + +@item @code{saveconfig} @kbd{filename} +Write the current configuration, +including any runtime modifications given with +@code{:config} +or +@code{config-from-file}, +to the ntpd host's file +@kbd{filename}. +This command will be rejected by the server unless +.Lk miscopt.html#saveconfigdir "saveconfigdir" +appears in the +@code{ntpd} +configuration file. +@kbd{filename} +can use +@code{strftime()} +format specifies to substitute the current date and time, for example, +@code{q]saveconfig} @code{ntp-%Y%m%d-%H%M%S.confq]}. +The filename used is stored in system variable +@code{savedconfig}. +Authentication is required. +@item @code{timerstats} +Display interval timer counters. +@item @code{writelist} @kbd{assocID} +Write the system or peer variables included in the variable list. +@item @code{writevar} @kbd{assocID} @kbd{name}=@kbd{value} @code{[, ...]} +Write the specified variables. +If the +@kbd{assocID} +is zero, the variables are from the +@ref{System Variables} +name space, otherwise they are from the +@ref{Peer Variables} +name space. +The +@kbd{assocID} +is required, as the same name can occur in both spaces. +@item @code{sysinfo} +Display operational summary. +@item @code{sysstats} +Print statistics counters maintained in the protocol module. +@end table + +@subsubsection Status Words and Kiss Codes + +The current state of the operating program is shown +in a set of status words +maintained by the system. +Status information is also available on a per-association basis. +These words are displayed in the +@code{rv} +and +@code{as} +commands both in hexadecimal and in decoded short tip strings. +The codes, tips and short explanations are documented on the +.Lk decode.html "Event Messages and Status Words" +page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. + +Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +.Lk decode.html#kiss "kiss codes" . +The original purpose was for kiss-o'-death (KoD) packets +sent by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. + +@subsubsection System Variables +The following system variables appear in the +@code{rv} +billboard. +Not all variables are displayed in some configurations. +@table @asis +@item Variable +Description +@item @code{status} +.Lk decode.html#sys "system status word" +@item @code{version} +NTP software version and build time +@item @code{processor} +hardware platform and version +@item @code{system} +operating system and version +@item @code{leap} +leap warning indicator (0-3) +@item @code{stratum} +stratum (1-15) +@item @code{precision} +precision (log2 s) +@item @code{rootdelay} +total roundtrip delay to the primary reference clock +@item @code{rootdisp} +total dispersion to the primary reference clock +@item @code{peer} +system peer association ID +@item @code{tc} +time constant and poll exponent (log2 s) (3-17) +@item @code{mintc} +minimum time constant (log2 s) (3-10) +@item @code{clock} +date and time of day +@item @code{refid} +reference ID or +.Lk decode.html#kiss "kiss code" +@item @code{reftime} +reference time +@item @code{offset} +combined offset of server relative to this host +@item @code{sys_jitter} +combined system jitter +@item @code{frequency} +frequency offset (PPM) relative to hardware clock +@item @code{clk_wander} +clock frequency wander (PPM) +@item @code{clk_jitter} +clock jitter +@item @code{tai} +TAI-UTC offset (s) +@item @code{leapsec} +NTP seconds when the next leap second is/was inserted +@item @code{expire} +NTP seconds when the NIST leapseconds file expires +@end table +The jitter and wander statistics are exponentially-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, +including some or all of the following, +depending on the particular Autokey dance: + +@table @asis +@item Variable +Description +@item @code{host} +Autokey host name for this host +@item @code{ident} +Autokey group name for this host +@item @code{flags} +host flags (see Autokey specification) +@item @code{digest} +OpenSSL message digest algorithm +@item @code{signature} +OpenSSL digest/signature scheme +@item @code{update} +NTP seconds at last signature update +@item @code{cert} +certificate subject, issuer and certificate flags +@item @code{until} +NTP seconds when the certificate expires +@end table +@subsubsection Peer Variables +The following peer variables appear in the +@code{rv} +billboard for each association. +Not all variables are displayed in some configurations. + +@table @asis +@item Variable +Description +@item @code{associd} +association ID +@item @code{status} +.Lk decode.html#peer "peer status word" +@item @code{srcadr} +source (remote) IP address +@item @code{srcport} +source (remote) port +@item @code{dstadr} +destination (local) IP address +@item @code{dstport} +destination (local) port +@item @code{leap} +leap indicator (0-3) +@item @code{stratum} +stratum (0-15) +@item @code{precision} +precision (log2 s) +@item @code{rootdelay} +total roundtrip delay to the primary reference clock +@item @code{rootdisp} +total root dispersion to the primary reference clock +@item @code{refid} +reference ID or +.Lk decode.html#kiss "kiss code" +@item @code{reftime} +reference time +@item @code{reach} +reach register (octal) +@item @code{unreach} +unreach counter +@item @code{hmode} +host mode (1-6) +@item @code{pmode} +peer mode (1-5) +@item @code{hpoll} +host poll exponent (log2 s) (3-17) +@item @code{ppoll} +peer poll exponent (log2 s) (3-17) +@item @code{headway} +headway (see +.Lk rate.html "Rate Management and the Kiss-o'-Death Packet" ) +@item @code{flash} +.Lk decode.html#flash "flash status word" +@item @code{offset} +filter offset +@item @code{delay} +filter delay +@item @code{dispersion} +filter dispersion +@item @code{jitter} +filter jitter +@item @code{ident} +Autokey group name for this association +@item @code{bias} +unicast/broadcast bias +@item @code{xleave} +interleave delay (see +.Lk xleave.html "NTP Interleaved Modes" ) +@end table +The +@code{bias} +variable is calculated when the first broadcast packet is received +after the calibration volley. +It represents the offset of the broadcast subgraph relative to the unicast subgraph. +The +@code{xleave} +variable appears only for the interleaved symmetric and interleaved modes. +It represents the internal queuing, buffering and transmission delays +for the preceding packet. + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: +@table @asis +@item Variable +Description +@item @code{flags} +peer flags (see Autokey specification) +@item @code{host} +Autokey server name +@item @code{flags} +peer flags (see Autokey specification) +@item @code{signature} +OpenSSL digest/signature scheme +@item @code{initsequence} +initial key ID +@item @code{initkey} +initial key index +@item @code{timestamp} +Autokey signature timestamp +@end table + +@subsubsection Clock Variables +The following clock variables appear in the +@code{cv} +billboard for each association with a reference clock. +Not all variables are displayed in some configurations. +@table @asis +@item Variable +Description +@item @code{associd} +association ID +@item @code{status} +.Lk decode.html#clock "clock status word" +@item @code{device} +device description +@item @code{timecode} +ASCII time code string (specific to device) +@item @code{poll} +poll messages sent +@item @code{noreply} +no reply +@item @code{badformat} +bad format +@item @code{baddata} +bad date or time +@item @code{fudgetime1} +fudge time 1 +@item @code{fudgetime2} +fudge time 2 +@item @code{stratum} +driver stratum +@item @code{refid} +driver reference ID +@item @code{flags} +driver flags +@end table + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntpq} program. +This software is released under the NTP license, . + +@menu +* ntpq usage:: ntpq help/usage (@option{--help}) +* ntpq ipv4:: ipv4 option (-4) +* ntpq ipv6:: ipv6 option (-6) +* ntpq command:: command option (-c) +* ntpq interactive:: interactive option (-i) +* ntpq numeric:: numeric option (-n) +* ntpq old-rv:: old-rv option +* ntpq peers:: peers option (-p) +* ntpq wide:: wide option (-w) +* ntpq config:: presetting/configuring ntpq +* ntpq exit status:: exit status +@end menu + +@node ntpq usage +@subsection ntpq help/usage (@option{--help}) +@cindex ntpq help + +This is the automatically generated usage text for ntpq. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +ntpq - standard NTP query program - Ver. 4.2.8p4 +Usage: ntpq [ - [] | --[@{=| @}] ]... [ host ...] + Flg Arg Option-Name Description + -4 no ipv4 Force IPv4 DNS name resolution + - prohibits the option 'ipv6' + -6 no ipv6 Force IPv6 DNS name resolution + - prohibits the option 'ipv4' + -c Str command run a command and exit + - may appear multiple times + -d no debug-level Increase debug verbosity level + - may appear multiple times + -D Num set-debug-level Set the debug verbosity level + - may appear multiple times + -i no interactive Force ntpq to operate in interactive mode + - prohibits these options: + command + peers + -n no numeric numeric host addresses + no old-rv Always output status line with readvar + -p no peers Print a list of the peers + - prohibits the option 'interactive' + -w no wide Display the full 'remote' value + opt version output version information and exit + -? no help display extended usage information and exit + -! no more-help extended usage information passed thru pager + -> opt save-opts save the option state to a config file + -< Str load-opts load options from a config file + - disabled as '--no-load-opts' + - may appear multiple times + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. + +The following option preset mechanisms are supported: + - reading file $HOME/.ntprc + - reading file ./.ntprc + - examining environment variables named NTPQ_* + +Please send bug reports to: +@end example +@exampleindent 4 + +@node ntpq ipv4 +@subsection ipv4 option (-4) +@cindex ntpq-ipv4 + +This is the ``force ipv4 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv6. +@end itemize + +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +@node ntpq ipv6 +@subsection ipv6 option (-6) +@cindex ntpq-ipv6 + +This is the ``force ipv6 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv4. +@end itemize + +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +@node ntpq command +@subsection command option (-c) +@cindex ntpq-command + +This is the ``run a command and exit'' option. +This option takes a string argument @file{cmd}. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +@node ntpq interactive +@subsection interactive option (-i) +@cindex ntpq-interactive + +This is the ``force ntpq to operate in interactive mode'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +command, peers. +@end itemize + +Force @code{ntpq} to operate in interactive mode. +Prompts will be written to the standard output and +commands read from the standard input. +@node ntpq numeric +@subsection numeric option (-n) +@cindex ntpq-numeric + +This is the ``numeric host addresses'' option. +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +@node ntpq old-rv +@subsection old-rv option +@cindex ntpq-old-rv + +This is the ``always output status line with readvar'' option. +By default, @code{ntpq} now suppresses the @code{associd=...} +line that precedes the output of @code{readvar} +(alias @code{rv}) when a single variable is requested, such as +@code{ntpq -c "rv 0 offset"}. +This option causes @code{ntpq} to include both lines of output +for a single-variable @code{readvar}. +Using an environment variable to +preset this option in a script will enable both older and +newer @code{ntpq} to behave identically in this regard. +@node ntpq peers +@subsection peers option (-p) +@cindex ntpq-peers + +This is the ``print a list of the peers'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +interactive. +@end itemize + +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +@node ntpq wide +@subsection wide option (-w) +@cindex ntpq-wide + +This is the ``display the full 'remote' value'' option. +Display the full value of the 'remote' value. If this requires +more than 15 characters, display the full value, emit a newline, +and continue the data display properly indented on the next line. + + +@node ntpq config +@subsection presetting/configuring ntpq + +Any option that is not marked as @i{not presettable} may be preset by +loading values from configuration ("rc" or "ini") files, and values from environment variables named @code{NTPQ} and @code{NTPQ_}. @code{} must be one of +the options listed above in upper case and segmented with underscores. +The @code{NTPQ} variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + + +@noindent +@code{libopts} will search in 2 places for configuration files: +@itemize @bullet +@item +$HOME +@item +$PWD +@end itemize +The environment variables @code{HOME}, and @code{PWD} +are expanded and replaced when @file{ntpq} runs. +For any of these that are plain files, they are simply processed. +For any that are directories, then a file named @file{.ntprc} is searched for +within that directory and processed. + +Configuration files may be in a wide variety of formats. +The basic format is an option name followed by a value (argument) on the +same line. Values may be separated from the option name with a colon, +equal sign or simply white space. Values may be continued across multiple +lines by escaping the newline with a backslash. + +Multiple programs may also share the same initialization file. +Common options are collected at the top, followed by program specific +segments. The segments are separated by lines like: +@example +[NTPQ] +@end example +@noindent +or by +@example + +@end example +@noindent +Do not mix these styles within one configuration file. + +Compound values and carefully constructed string values may also be +specified using XML syntax: +@example + + ...<...>... + +@end example +@noindent +yielding an @code{option-name.sub-opt} string value of +@example +"...<...>..." +@end example +@code{AutoOpts} does not track suboptions. You simply note that it is a +hierarchicly valued option. @code{AutoOpts} does provide a means for searching +the associated name/value pair list (see: optionFindValue). + +The command line options relating to configuration and/or usage help are: + +@subsubheading version (-) + +Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +@table @samp +@item version +Only print the version. This is the default. +@item copyright +Name the copyright usage licensing terms. +@item verbose +Print the full copyright usage licensing terms. +@end table + +@node ntpq exit status +@subsection ntpq exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@item 66 (EX_NOINPUT) +A specified configuration file could not be loaded. +@item 70 (EX_SOFTWARE) +libopts had an internal operational error. Please report +it to autogen-users@@lists.sourceforge.net. Thank you. +@end table diff --git a/contrib/ntp/ntpq/libntpq.c b/contrib/ntp/ntpq/libntpq.c new file mode 100644 index 000000000..becd956f2 --- /dev/null +++ b/contrib/ntp/ntpq/libntpq.c @@ -0,0 +1,771 @@ +/***************************************************************************** + * + * libntpq.c + * + * This is the wrapper library for ntpq, the NTP query utility. + * This library reuses the sourcecode from ntpq and exports a number + * of useful functions in a library that can be linked against applications + * that need to query the status of a running ntpd. The whole + * communcation is based on mode 6 packets. + * + ****************************************************************************/ +#define LIBNTPQ_C +#define NO_MAIN_ALLOWED 1 +/* #define BUILD_AS_LIB Already provided by the Makefile */ + +#include "ntpq.c" +#include "libntpq.h" + +/* Function Prototypes */ + + +const char *Version = "libntpq 0.3beta"; + +/* global variables used for holding snapshots of data */ +char peervars[NTPQ_BUFLEN]; +int peervarlen = 0; +associd_t peervar_assoc = 0; +char clockvars[NTPQ_BUFLEN]; +int clockvarlen = 0; +int clockvar_assoc = 0; +char sysvars[NTPQ_BUFLEN]; +int sysvarlen = 0; +char *ntpq_resultbuffer[NTPQ_BUFLEN]; +unsigned short ntpq_associations[MAXASSOC]; +struct ntpq_varlist ntpq_varlist[MAXLIST]; + +/***************************************************************************** + * + * ntpq_stripquotes + * + * Parses a given character buffer srcbuf and removes all quoted + * characters. The resulting string is copied to the specified + * resultbuf character buffer. E.g. \" will be translated into " + * + **************************************************************************** + * Parameters: + * resultbuf char* The resulting string without quoted + * characters + * srcbuf char* The buffer holding the original string + * datalen int The number of bytes stored in srcbuf + * maxlen int Max. number of bytes for resultbuf + * + * Returns: + * int number of chars that have been copied to + * resultbuf + ****************************************************************************/ + +int ntpq_stripquotes ( char *resultbuf, char *srcbuf, int datalen, int maxlen ) +{ + char* tmpbuf = srcbuf; + + while ( *tmpbuf != 0 ) + { + if ( *tmpbuf == '\"' ) + { + tmpbuf++; + continue; + } + + if ( *tmpbuf == '\\' ) + { + tmpbuf++; + switch ( *tmpbuf ) + { + /* ignore if end of string */ + case 0: + continue; + /* skip and do not copy */ + case '\"': /* quotes */ + case 'n': /*newline*/ + case 'r': /*carriage return*/ + case 'g': /*bell*/ + case 't': /*tab*/ + tmpbuf++; + continue; + } + } + + *resultbuf++ = *tmpbuf++; + + } + + *resultbuf = 0; + return strlen(resultbuf); +} + + +/***************************************************************************** + * + * ntpq_getvar + * + * This function parses a given buffer for a variable/value pair and + * copies the value of the requested variable into the specified + * varvalue buffer. + * + * It returns the number of bytes copied or zero for an empty result + * (=no matching variable found or empty value) + * + **************************************************************************** + * Parameters: + * resultbuf char* The resulting string without quoted + * characters + * datalen size_t The number of bytes stored in + * resultbuf + * varname char* Name of the required variable + * varvalue char* Where the value of the variable should + * be stored + * maxlen size_t Max. number of bytes for varvalue + * + * Returns: + * size_t number of chars that have been copied to + * varvalue + ****************************************************************************/ + +size_t +ntpq_getvar( + const char * resultbuf, + size_t datalen, + const char * varname, + char * varvalue, + size_t maxlen) +{ + char * name; + char * value; + int idatalen; + + value = NULL; + idatalen = (int)datalen; + + while (nextvar(&idatalen, &resultbuf, &name, &value)) { + if (strcmp(varname, name) == 0) { + ntpq_stripquotes(varvalue, value, strlen(value), maxlen); + + return strlen(varvalue); + } + } + + return 0; +} + + +/***************************************************************************** + * + * ntpq_queryhost + * + * Sends a mode 6 query packet to the current open host (see + * ntpq_openhost) and stores the requested variable set in the specified + * character buffer. + * It returns the number of bytes read or zero for an empty result + * (=no answer or empty value) + * + **************************************************************************** + * Parameters: + * VARSET u_short Which variable set should be + * read (PEERVARS or CLOCKVARS) + * association int The association ID that should be read + * 0 represents the ntpd instance itself + * resultbuf char* The resulting string without quoted + * characters + * maxlen int Max. number of bytes for varvalue + * + * Returns: + * int number of bytes that have been copied to + * resultbuf + * - OR - + * 0 (zero) if no reply has been received or + * another failure occured + ****************************************************************************/ + +int ntpq_queryhost(unsigned short VARSET, unsigned short association, char *resultbuf, int maxlen) +{ + const char *datap; + int res; + int dsize; + u_short rstatus; + + if ( numhosts > 0 ) + res = doquery(VARSET,association,0,0, (char *)0, &rstatus, &dsize, &datap); + else + return 0; + + if ( ( res != 0) || ( dsize == 0 ) ) /* no data */ + return 0; + + if ( dsize > maxlen) + dsize = maxlen; + + + /* fill result resultbuf */ + memcpy(resultbuf, datap, dsize); + + return dsize; +} + + + +/***************************************************************************** + * + * ntpq_openhost + * + * Sets up a connection to the ntpd instance of a specified host. Note: + * There is no real "connection" established because NTP solely works + * based on UDP. + * + **************************************************************************** + * Parameters: + * hostname char* Hostname/IP of the host running ntpd + * fam int Address Family (AF_INET, AF_INET6, or 0) + * + * Returns: + * int 1 if the host connection could be set up, i.e. + * name resolution was succesful and/or IP address + * has been validated + * - OR - + * 0 (zero) if a failure occured + ****************************************************************************/ + +int +ntpq_openhost( + char *hostname, + int fam + ) +{ + if ( openhost(hostname, fam) ) + { + numhosts = 1; + } else { + numhosts = 0; + } + + return numhosts; + +} + + +/***************************************************************************** + * + * ntpq_closehost + * + * Cleans up a connection by closing the used socket. Should be called + * when no further queries are required for the currently used host. + * + **************************************************************************** + * Parameters: + * - none - + * + * Returns: + * int 0 (zero) if no host has been opened before + * - OR - + * the resultcode from the closesocket function call + ****************************************************************************/ + +int ntpq_closehost(void) +{ + if ( numhosts ) + return closesocket(sockfd); + + return 0; +} + + +/***************************************************************************** + * + * ntpq_read_associations + * + * This function queries the ntp host for its associations and returns the + * number of associations found. + * + * It takes an u_short array as its first parameter, this array holds the + * IDs of the associations, + * the function will not write more entries than specified with the + * max_entries parameter. + * + * However, if more than max_entries associations were found, the return + * value of this function will reflect the real number, even if not all + * associations have been stored in the array. + * + **************************************************************************** + * Parameters: + * resultbuf u_short*Array that should hold the list of + * association IDs + * maxentries int maximum number of association IDs that can + * be stored in resultbuf + * + * Returns: + * int number of association IDs stored in resultbuf + * - OR - + * 0 (zero) if a failure occured or no association has + * been returned. + ****************************************************************************/ + + int ntpq_read_associations ( u_short resultbuf[], int max_entries ) +{ + int i = 0; + + if (ntpq_dogetassoc()) { + + if(numassoc < max_entries) + max_entries = numassoc; + + for (i=0;i 1) + fprintf(stderr, "server=%s ", currenthost); + fprintf(stderr, + "***No information returned for association %d\n", + associd); + + return 0; + } + if (dsize > maxsize) + dsize = maxsize; + memcpy(resultbuf, datap, dsize); + + return dsize; +} + + + + +/***************************************************************************** + * + * ntpq_read_sysvars + * + * This function reads the sysvars variable-set from a NTP host and writes it + * to the result buffer specified, honoring the maxsize limit. + * + * It returns the number of bytes written or 0 when the variable-set is empty + * or could not be read. + * + **************************************************************************** + * Parameters: + * resultbuf char* character buffer where the variable set + * should be stored + * maxsize int the maximum number of bytes that can be + * written to resultbuf + * + * Returns: + * int number of chars that have been copied to + * resultbuf + * - OR - + * 0 (zero) if an error occured + ****************************************************************************/ +size_t +ntpq_read_sysvars( + char * resultbuf, + size_t maxsize + ) +{ + const char * datap; + int res; + int i_dsize; + size_t dsize; + u_short rstatus; + + res = doquery(CTL_OP_READVAR, 0, 0, 0, NULL, &rstatus, + &i_dsize, &datap); + + if (res != 0) + return 0; + + if (i_dsize == 0) { + if (numhosts > 1) + fprintf(stderr, "server=%s ", currenthost); + fprintf(stderr, "***No sysvar information returned\n"); + + return 0; + } else { + dsize = max(0, i_dsize); + dsize = min(dsize, maxsize); + memcpy(resultbuf, datap, dsize); + } + + return dsize; +} + + +/***************************************************************************** + * ntpq_get_assoc_allvars + * + * With this function all association variables for the specified association + * ID can be requested from a NTP host. They are stored internally and can be + * read by using the ntpq_get_peervar or ntpq_get_clockvar functions. + * + * Basically this is only a combination of the ntpq_get_assoc_peervars and + * ntpq_get_assoc_clockvars functions. + * + * It returns 1 if both variable-sets (peervars and clockvars) were + * received successfully. If one variable-set or both of them weren't + * received, + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * + * Returns: + * int nonzero if at least one variable set could be read + * - OR - + * 0 (zero) if an error occured and both variable sets + * could not be read + ****************************************************************************/ + int ntpq_get_assoc_allvars( associd_t associd ) +{ + return ntpq_get_assoc_peervars ( associd ) & + ntpq_get_assoc_clockvars( associd ); +} + + + + +/***************************************************************************** + * + * ntpq_get_sysvars + * + * The system variables of a NTP host can be requested by using this function + * and afterwards using ntpq_get_sysvar to read the single variable values. + * + **************************************************************************** + * Parameters: + * - none - + * + * Returns: + * int nonzero if the variable set could be read + * - OR - + * 0 (zero) if an error occured and the sysvars + * could not be read + ****************************************************************************/ +int +ntpq_get_sysvars(void) +{ + sysvarlen = ntpq_read_sysvars(sysvars, sizeof(sysvars)); + if (sysvarlen <= 0) + return 0; + else + return 1; +} + + +/***************************************************************************** + * + * ntp_get_peervar + * + * This function uses the variable-set which was read by using + * ntp_get_peervars and searches for a variable specified with varname. If + * such a variable exists, it writes its value into + * varvalue (maxlen specifies the size of this target buffer). + * + **************************************************************************** + * Parameters: + * varname char* requested variable name + * varvalue char* the buffer where the value should go into + * maxlen int maximum number of bytes that can be copied to + * varvalue + * + * Returns: + * int number of bytes copied to varvalue + * - OR - + * 0 (zero) if an error occured or the variable could + * not be found + ****************************************************************************/ +int ntpq_get_peervar( const char *varname, char *varvalue, int maxlen) +{ + return ( ntpq_getvar(peervars,peervarlen,varname,varvalue,maxlen) ); +} + + + +/***************************************************************************** + * + * ntpq_get_assoc_peervars + * + * This function requests the peer variables of the specified association + * from a NTP host. In order to access the variable values, the function + * ntpq_get_peervar must be used. + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * + * Returns: + * int 1 (one) if the peervars have been read + * - OR - + * 0 (zero) if an error occured and the variable set + * could not be read + ****************************************************************************/ +int +ntpq_get_assoc_peervars( + associd_t associd + ) +{ + peervarlen = ntpq_read_assoc_peervars(associd, peervars, + sizeof(peervars)); + if (peervarlen <= 0) { + peervar_assoc = 0; + + return 0; + } + peervar_assoc = associd; + + return 1; +} + + +/***************************************************************************** + * + * ntp_read_assoc_clockvars + * + * This function reads the clockvars variable-set of a specified association + * from a NTP host and writes it to the result buffer specified, honoring + * the maxsize limit. + * + * It returns the number of bytes written or 0 when the variable-set is + * empty or failed to read. + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * resultbuf char* character buffer where the variable set + * should be stored + * maxsize int the maximum number of bytes that can be + * written to resultbuf + * + * Returns: + * int number of chars that have been copied to + * resultbuf + * - OR - + * 0 (zero) if an error occured + ****************************************************************************/ + +int +ntpq_read_assoc_clockvars( + associd_t associd, + char * resultbuf, + int maxsize + ) +{ + const char *datap; + int res; + int dsize; + u_short rstatus; + + res = ntpq_doquerylist(ntpq_varlist, CTL_OP_READCLOCK, associd, + 0, &rstatus, &dsize, &datap); + if (res != 0) + return 0; + + if (dsize == 0) { + if (numhosts > 1) /* no information returned from server */ + return 0; + } else { + if (dsize > maxsize) + dsize = maxsize; + memcpy(resultbuf, datap, dsize); + } + + return dsize; +} + + + +/***************************************************************************** + * + * ntpq_get_assoc_clocktype + * + * This function returns a clocktype value for a given association number + * (not ID!): + * + * NTP_CLOCKTYPE_UNKNOWN Unknown clock type + * NTP_CLOCKTYPE_BROADCAST Broadcast server + * NTP_CLOCKTYPE_LOCAL Local clock + * NTP_CLOCKTYPE_UNICAST Unicast server + * NTP_CLOCKTYPE_MULTICAST Multicast server + * + ****************************************************************************/ +int +ntpq_get_assoc_clocktype( + int assoc_index + ) +{ + associd_t associd; + int i; + int rc; + sockaddr_u dum_store; + char dstadr[LENHOSTNAME]; + char resultbuf[NTPQ_BUFLEN]; + + if (assoc_index < 0 || assoc_index >= numassoc) + return -1; + + associd = assoc_cache[assoc_index].assid; + if (associd == peervar_assoc) { + rc = ntpq_get_peervar("dstadr", dstadr, sizeof(dstadr)); + } else { + i = ntpq_read_assoc_peervars(associd, resultbuf, + sizeof(resultbuf)); + if (i <= 0) + return -1; + rc = ntpq_getvar(resultbuf, i, "dstadr", dstadr, + sizeof(dstadr)); + } + + if (0 != rc && decodenetnum(dstadr, &dum_store)) + return ntpq_decodeaddrtype(&dum_store); + + return -1; +} + + + +/***************************************************************************** + * + * ntpq_get_assoc_clockvars + * + * With this function the clock variables of the specified association are + * requested from a NTP host. This makes only sense for associations with + * the type 'l' (Local Clock) and you should check this with + * ntpq_get_assoc_clocktype for each association, before you use this function + * on it. + * + **************************************************************************** + * Parameters: + * associd int requested associaton ID + * + * Returns: + * int 1 (one) if the clockvars have been read + * - OR - + * 0 (zero) if an error occured and the variable set + * could not be read + ****************************************************************************/ +int ntpq_get_assoc_clockvars( associd_t associd ) +{ + if (NTP_CLOCKTYPE_LOCAL != ntpq_get_assoc_clocktype( + ntpq_get_assoc_number(associd))) + return 0; + clockvarlen = ntpq_read_assoc_clockvars( associd, clockvars, + sizeof(clockvars) ); + if ( clockvarlen <= 0 ) { + clockvar_assoc = 0; + return 0; + } else { + clockvar_assoc = associd; + return 1; + } +} + + diff --git a/contrib/ntp/ntpq/libntpq.h b/contrib/ntp/ntpq/libntpq.h new file mode 100644 index 000000000..84a622bba --- /dev/null +++ b/contrib/ntp/ntpq/libntpq.h @@ -0,0 +1,109 @@ +/***************************************************************************** + * + * libntpq.h + * + * This is the wrapper library for ntpq, the NTP query utility. + * This library reuses the sourcecode from ntpq and exports a number + * of useful functions in a library that can be linked against applications + * that need to query the status of a running ntpd. The whole + * communcation is based on mode 6 packets. + * + * This header file can be used in applications that want to link against + * libntpq. + * + ****************************************************************************/ + +#include "ntp_net.h" + +/* general purpose buffer size */ +#define NTPQ_BUFLEN 2048 + +/* max. number of associations */ +#ifndef MAXASSOC +#define MAXASSOC 1024 +#endif + +/* general purpose max array size definition */ +#ifndef MAXLIST +#define MAXLIST 64 +#endif + +#ifndef LENHOSTNAME +#define LENHOSTNAME 256 /* host name is max. 256 characters long */ +#endif + +/* NTP Status codes */ +#define NTP_STATUS_INVALID 0 +#define NTP_STATUS_FALSETICKER 1 +#define NTP_STATUS_EXCESS 2 +#define NTP_STATUS_OUTLIER 3 +#define NTP_STATUS_CANDIDATE 4 +#define NTP_STATUS_SELECTED 5 +#define NTP_STATUS_SYSPEER 6 +#define NTP_STATUS_PPSPEER 7 + +/* NTP association type identifier */ +#define NTP_CLOCKTYPE_UNKNOWN '-' +#define NTP_CLOCKTYPE_BROADCAST 'b' +#define NTP_CLOCKTYPE_LOCAL 'l' +#define NTP_CLOCKTYPE_UNICAST 'u' +#define NTP_CLOCKTYPE_MULTICAST 'm' + +/* Variable Sets */ +#define PEERVARS CTL_OP_READVAR +#define CLOCKVARS CTL_OP_CLOCKVAR + +/* Variable list struct */ +struct ntpq_varlist { + char *name; + char *value; +}; + +/* global variables used for holding snapshots of data */ +#ifndef LIBNTPQ_C +extern char peervars[]; +extern int peervarlen; +extern int peervar_assoc; +extern char clockvars[]; +extern int clockvarlen; +extern int clockvar_assoc; +extern char sysvars[]; +extern int sysvarlen; +extern char *ntpq_resultbuffer[]; +extern struct ntpq_varlist ntpq_varlist[MAXLIST]; +#endif + + + +/* + * Prototypes of exported libary functions + */ + +/* from libntpq.c */ +extern int ntpq_openhost(char *, int); +extern int ntpq_closehost(void); +extern int ntpq_queryhost(unsigned short VARSET, associd_t association, + char *resultbuf, int maxlen); +extern size_t ntpq_getvar(const char *resultbuf, size_t datalen, + const char *varname, char *varvalue, + size_t maxlen); +extern int ntpq_stripquotes ( char *resultbuf, char *srcbuf, int datalen, int maxlen ); +extern int ntpq_queryhost_peervars(associd_t association, char *resultbuf, int maxlen); +extern int ntpq_get_peervar( const char *varname, char *varvalue, int maxlen); +extern size_t ntpq_read_sysvars(char *resultbuf, size_t maxsize); +extern int ntpq_get_sysvars( void ); +extern int ntpq_read_associations ( unsigned short resultbuf[], int max_entries ); +extern int ntpq_get_assocs ( void ); +extern int ntpq_get_assoc_number ( associd_t associd ); +extern int ntpq_get_assoc_peervars( associd_t associd ); +extern int ntpq_get_assoc_clockvars( associd_t associd ); +extern int ntpq_get_assoc_allvars( associd_t associd ); +extern int ntpq_get_assoc_clocktype(int assoc_index); +extern int ntpq_read_assoc_peervars( associd_t associd, char *resultbuf, int maxsize ); +extern int ntpq_read_assoc_clockvars( associd_t associd, char *resultbuf, int maxsize ); + +/* in libntpq_subs.c */ +extern int ntpq_dogetassoc(void); +extern char ntpq_decodeaddrtype(sockaddr_u *sock); +extern int ntpq_doquerylist(struct ntpq_varlist *, int, associd_t, int, + u_short *, int *, const char **datap); diff --git a/contrib/ntp/ntpq/libntpq_subs.c b/contrib/ntp/ntpq/libntpq_subs.c new file mode 100644 index 000000000..e53b4193c --- /dev/null +++ b/contrib/ntp/ntpq/libntpq_subs.c @@ -0,0 +1,52 @@ +/***************************************************************************** + * + * libntpq_subs.c + * + * This is the second part of the wrapper library for ntpq, the NTP query utility. + * This library reuses the sourcecode from ntpq and exports a number + * of useful functions in a library that can be linked against applications + * that need to query the status of a running ntpd. The whole + * communcation is based on mode 6 packets. + * + * This source file exports the (private) functions from ntpq-subs.c + * + ****************************************************************************/ + + +#include "ntpq-subs.c" +#include "libntpq.h" + + +int ntpq_dogetassoc(void) +{ + + if (dogetassoc(NULL)) + return numassoc; + else + return 0; +} + +/* the following functions are required internally by a number of libntpq functions + * and since they are defined as static in ntpq-subs.c, they need to be exported here + */ + +char ntpq_decodeaddrtype(sockaddr_u *sock) +{ + return decodeaddrtype(sock); +} + +int +ntpq_doquerylist( + struct ntpq_varlist *vlist, + int op, + associd_t associd, + int auth, + u_short *rstatus, + int *dsize, + const char **datap + ) +{ + return doquerylist((struct varlist *)vlist, op, associd, auth, + rstatus, dsize, datap); +} + diff --git a/contrib/ntp/ntpq/ntpq-opts.c b/contrib/ntp/ntpq/ntpq-opts.c index 868ef29a0..223292878 100644 --- a/contrib/ntp/ntpq/ntpq-opts.c +++ b/contrib/ntp/ntpq/ntpq-opts.c @@ -1,45 +1,56 @@ -/* +/* * EDIT THIS FILE WITH CAUTION (ntpq-opts.c) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:26 AM EST + * + * It has been AutoGen-ed October 21, 2015 at 12:39:00 PM by AutoGen 5.18.5 * From the definitions ntpq-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This source file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpq author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. + * Generated from AutoOpts 41:0:16 templates. + * + * AutoOpts is a copyrighted work. This source file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpq author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. * - * This source file is copyrighted and licensed under the following terms: + * The ntpq program is copyrighted and licensed + * under the following terms: * - * ntpq copyright 1970-2009 David L. Mills and/or others - all rights reserved + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * * - * see html/copyright.html + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. */ - -#include - +#ifndef __doxygen__ #define OPTION_CODE_COMPILE 1 #include "ntpq-opts.h" +#include + +#include +#include +#include #ifdef __cplusplus extern "C" { #endif -tSCC zCopyright[] = - "ntpq copyright (c) 1970-2009 David L. Mills and/or others, all rights reserved"; -tSCC zCopyrightNotice[] = - -/* extracted from ../include/copyright.def near line 8 */ -"see html/copyright.html"; -extern tUsageProc optionUsage; +extern FILE * option_usage_fp; +#define zCopyright (ntpq_opt_strs+0) +#define zLicenseDescrip (ntpq_opt_strs+340) /* * global included definitions @@ -53,210 +64,288 @@ extern tUsageProc optionUsage; #ifndef NULL # define NULL 0 #endif -#ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -#endif -#ifndef EXIT_FAILURE -# define EXIT_FAILURE 1 -#endif -/* - * Ipv4 option description: - */ -tSCC zIpv4Text[] = - "Force IPv4 DNS name resolution"; -tSCC zIpv4_NAME[] = "IPV4"; -tSCC zIpv4_Name[] = "ipv4"; -#define IPV4_FLAGS (OPTST_DISABLED) -/* - * Ipv6 option description: +/** + * static const strings for ntpq options */ -tSCC zIpv6Text[] = - "Force IPv6 DNS name resolution"; -tSCC zIpv6_NAME[] = "IPV6"; -tSCC zIpv6_Name[] = "ipv6"; -#define IPV6_FLAGS (OPTST_DISABLED) - -/* - * Command option description: +static char const ntpq_opt_strs[1925] = +/* 0 */ "ntpq 4.2.8p4\n" + "Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n" + "This is free software. It is licensed for use, modification and\n" + "redistribution under the terms of the NTP License, copies of which\n" + "can be seen at:\n" + " \n" + " \n\0" +/* 340 */ "Permission to use, copy, modify, and distribute this software and its\n" + "documentation for any purpose with or without fee is hereby granted,\n" + "provided that the above copyright notice appears in all copies and that\n" + "both the copyright notice and this permission notice appear in supporting\n" + "documentation, and that the name The University of Delaware not be used in\n" + "advertising or publicity pertaining to distribution of the software without\n" + "specific, written prior permission. The University of Delaware and Network\n" + "Time Foundation makes no representations about the suitability this\n" + "software for any purpose. It is provided \"as is\" without express or\n" + "implied warranty.\n\0" +/* 1008 */ "Force IPv4 DNS name resolution\0" +/* 1039 */ "IPV4\0" +/* 1044 */ "ipv4\0" +/* 1049 */ "Force IPv6 DNS name resolution\0" +/* 1080 */ "IPV6\0" +/* 1085 */ "ipv6\0" +/* 1090 */ "run a command and exit\0" +/* 1113 */ "COMMAND\0" +/* 1121 */ "command\0" +/* 1129 */ "Increase debug verbosity level\0" +/* 1160 */ "DEBUG_LEVEL\0" +/* 1172 */ "debug-level\0" +/* 1184 */ "Set the debug verbosity level\0" +/* 1214 */ "SET_DEBUG_LEVEL\0" +/* 1230 */ "set-debug-level\0" +/* 1246 */ "Force ntpq to operate in interactive mode\0" +/* 1288 */ "INTERACTIVE\0" +/* 1300 */ "interactive\0" +/* 1312 */ "numeric host addresses\0" +/* 1335 */ "NUMERIC\0" +/* 1343 */ "numeric\0" +/* 1351 */ "Always output status line with readvar\0" +/* 1390 */ "OLD_RV\0" +/* 1397 */ "old-rv\0" +/* 1404 */ "Print a list of the peers\0" +/* 1430 */ "PEERS\0" +/* 1436 */ "peers\0" +/* 1442 */ "Display the full 'remote' value\0" +/* 1474 */ "WIDE\0" +/* 1479 */ "wide\0" +/* 1484 */ "display extended usage information and exit\0" +/* 1528 */ "help\0" +/* 1533 */ "extended usage information passed thru pager\0" +/* 1578 */ "more-help\0" +/* 1588 */ "output version information and exit\0" +/* 1624 */ "version\0" +/* 1632 */ "save the option state to a config file\0" +/* 1671 */ "save-opts\0" +/* 1681 */ "load options from a config file\0" +/* 1713 */ "LOAD_OPTS\0" +/* 1723 */ "no-load-opts\0" +/* 1736 */ "no\0" +/* 1739 */ "NTPQ\0" +/* 1744 */ "ntpq - standard NTP query program - Ver. 4.2.8p4\n" + "Usage: %s [ - [] | --[{=| }] ]... [ host ...]\n\0" +/* 1863 */ "$HOME\0" +/* 1869 */ ".\0" +/* 1871 */ ".ntprc\0" +/* 1878 */ "http://bugs.ntp.org, bugs@ntp.org\0" +/* 1912 */ "ntpq 4.2.8p4"; + +/** + * ipv4 option description with + * "Must also have options" and "Incompatible options": */ -tSCC zCommandText[] = - "run a command and exit"; -tSCC zCommand_NAME[] = "COMMAND"; -tSCC zCommand_Name[] = "command"; -#define COMMAND_FLAGS (OPTST_DISABLED | OPTST_STACKED \ - | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) - -/* - * Debug_Level option description: +/** Descriptive text for the ipv4 option */ +#define IPV4_DESC (ntpq_opt_strs+1008) +/** Upper-cased name for the ipv4 option */ +#define IPV4_NAME (ntpq_opt_strs+1039) +/** Name string for the ipv4 option */ +#define IPV4_name (ntpq_opt_strs+1044) +/** Other options that appear in conjunction with the ipv4 option */ +static int const aIpv4CantList[] = { + INDEX_OPT_IPV6, NO_EQUIVALENT }; +/** Compiled in flag settings for the ipv4 option */ +#define IPV4_FLAGS (OPTST_DISABLED) + +/** + * ipv6 option description with + * "Must also have options" and "Incompatible options": */ -#ifdef DEBUG -tSCC zDebug_LevelText[] = - "Increase output debug message level"; -tSCC zDebug_Level_NAME[] = "DEBUG_LEVEL"; -tSCC zDebug_Level_Name[] = "debug-level"; -#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) - -#else /* disable Debug_Level */ -#define VALUE_OPT_DEBUG_LEVEL NO_EQUIVALENT -#define DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zDebug_LevelText NULL -#define zDebug_Level_NAME NULL -#define zDebug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Set_Debug_Level option description: +/** Descriptive text for the ipv6 option */ +#define IPV6_DESC (ntpq_opt_strs+1049) +/** Upper-cased name for the ipv6 option */ +#define IPV6_NAME (ntpq_opt_strs+1080) +/** Name string for the ipv6 option */ +#define IPV6_name (ntpq_opt_strs+1085) +/** Other options that appear in conjunction with the ipv6 option */ +static int const aIpv6CantList[] = { + INDEX_OPT_IPV4, NO_EQUIVALENT }; +/** Compiled in flag settings for the ipv6 option */ +#define IPV6_FLAGS (OPTST_DISABLED) + +/** + * command option description: */ -#ifdef DEBUG -tSCC zSet_Debug_LevelText[] = - "Set the output debug message level"; -tSCC zSet_Debug_Level_NAME[] = "SET_DEBUG_LEVEL"; -tSCC zSet_Debug_Level_Name[] = "set-debug-level"; -#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ +/** Descriptive text for the command option */ +#define COMMAND_DESC (ntpq_opt_strs+1090) +/** Upper-cased name for the command option */ +#define COMMAND_NAME (ntpq_opt_strs+1113) +/** Name string for the command option */ +#define COMMAND_name (ntpq_opt_strs+1121) +/** Compiled in flag settings for the command option */ +#define COMMAND_FLAGS (OPTST_DISABLED \ | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) -#else /* disable Set_Debug_Level */ -#define VALUE_OPT_SET_DEBUG_LEVEL NO_EQUIVALENT -#define SET_DEBUG_LEVEL_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) -#define zSet_Debug_LevelText NULL -#define zSet_Debug_Level_NAME NULL -#define zSet_Debug_Level_Name NULL -#endif /* DEBUG */ - -/* - * Peers option description with - * "Must also have options" and "Incompatible options": +/** + * debug-level option description: */ -tSCC zPeersText[] = - "Print a list of the peers"; -tSCC zPeers_NAME[] = "PEERS"; -tSCC zPeers_Name[] = "peers"; -static const int - aPeersCantList[] = { - INDEX_OPT_INTERACTIVE, NO_EQUIVALENT }; -#define PEERS_FLAGS (OPTST_DISABLED) - -/* - * Interactive option description with +/** Descriptive text for the debug-level option */ +#define DEBUG_LEVEL_DESC (ntpq_opt_strs+1129) +/** Upper-cased name for the debug-level option */ +#define DEBUG_LEVEL_NAME (ntpq_opt_strs+1160) +/** Name string for the debug-level option */ +#define DEBUG_LEVEL_name (ntpq_opt_strs+1172) +/** Compiled in flag settings for the debug-level option */ +#define DEBUG_LEVEL_FLAGS (OPTST_DISABLED) + +/** + * set-debug-level option description: + */ +/** Descriptive text for the set-debug-level option */ +#define SET_DEBUG_LEVEL_DESC (ntpq_opt_strs+1184) +/** Upper-cased name for the set-debug-level option */ +#define SET_DEBUG_LEVEL_NAME (ntpq_opt_strs+1214) +/** Name string for the set-debug-level option */ +#define SET_DEBUG_LEVEL_name (ntpq_opt_strs+1230) +/** Compiled in flag settings for the set-debug-level option */ +#define SET_DEBUG_LEVEL_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_NUMERIC)) + +/** + * interactive option description with * "Must also have options" and "Incompatible options": */ -tSCC zInteractiveText[] = - "Force ntpq to operate in interactive mode"; -tSCC zInteractive_NAME[] = "INTERACTIVE"; -tSCC zInteractive_Name[] = "interactive"; -static const int - aInteractiveCantList[] = { +/** Descriptive text for the interactive option */ +#define INTERACTIVE_DESC (ntpq_opt_strs+1246) +/** Upper-cased name for the interactive option */ +#define INTERACTIVE_NAME (ntpq_opt_strs+1288) +/** Name string for the interactive option */ +#define INTERACTIVE_name (ntpq_opt_strs+1300) +/** Other options that appear in conjunction with the interactive option */ +static int const aInteractiveCantList[] = { INDEX_OPT_COMMAND, INDEX_OPT_PEERS, NO_EQUIVALENT }; -#define INTERACTIVE_FLAGS (OPTST_DISABLED) +/** Compiled in flag settings for the interactive option */ +#define INTERACTIVE_FLAGS (OPTST_DISABLED) -/* - * Numeric option description: +/** + * numeric option description: */ -tSCC zNumericText[] = - "numeric host addresses"; -tSCC zNumeric_NAME[] = "NUMERIC"; -tSCC zNumeric_Name[] = "numeric"; -#define NUMERIC_FLAGS (OPTST_DISABLED) - -/* - * Help/More_Help/Version option descriptions: +/** Descriptive text for the numeric option */ +#define NUMERIC_DESC (ntpq_opt_strs+1312) +/** Upper-cased name for the numeric option */ +#define NUMERIC_NAME (ntpq_opt_strs+1335) +/** Name string for the numeric option */ +#define NUMERIC_name (ntpq_opt_strs+1343) +/** Compiled in flag settings for the numeric option */ +#define NUMERIC_FLAGS (OPTST_DISABLED) + +/** + * old-rv option description: */ -tSCC zHelpText[] = "Display usage information and exit"; -tSCC zHelp_Name[] = "help"; - -tSCC zMore_HelpText[] = "Extended usage information passed thru pager"; -tSCC zMore_Help_Name[] = "more-help"; - -tSCC zVersionText[] = "Output version information and exit"; -tSCC zVersion_Name[] = "version"; - -/* - * Save/Load_Opts option description: +/** Descriptive text for the old-rv option */ +#define OLD_RV_DESC (ntpq_opt_strs+1351) +/** Upper-cased name for the old-rv option */ +#define OLD_RV_NAME (ntpq_opt_strs+1390) +/** Name string for the old-rv option */ +#define OLD_RV_name (ntpq_opt_strs+1397) +/** Compiled in flag settings for the old-rv option */ +#define OLD_RV_FLAGS (OPTST_DISABLED) + +/** + * peers option description with + * "Must also have options" and "Incompatible options": */ -tSCC zSave_OptsText[] = "Save the option state to a config file"; -tSCC zSave_Opts_Name[] = "save-opts"; - -tSCC zLoad_OptsText[] = "Load options from a config file"; -tSCC zLoad_Opts_NAME[] = "LOAD_OPTS"; +/** Descriptive text for the peers option */ +#define PEERS_DESC (ntpq_opt_strs+1404) +/** Upper-cased name for the peers option */ +#define PEERS_NAME (ntpq_opt_strs+1430) +/** Name string for the peers option */ +#define PEERS_name (ntpq_opt_strs+1436) +/** Other options that appear in conjunction with the peers option */ +static int const aPeersCantList[] = { + INDEX_OPT_INTERACTIVE, NO_EQUIVALENT }; +/** Compiled in flag settings for the peers option */ +#define PEERS_FLAGS (OPTST_DISABLED) -tSCC zNotLoad_Opts_Name[] = "no-load-opts"; -tSCC zNotLoad_Opts_Pfx[] = "no"; -#define zLoad_Opts_Name (zNotLoad_Opts_Name + 3) -/* - * Declare option callback procedures +/** + * wide option description: */ -#ifdef DEBUG - static tOptProc doOptSet_Debug_Level; -#else /* not DEBUG */ -# define doOptSet_Debug_Level NULL -#endif /* def/not DEBUG */ -#if defined(TEST_NTPQ_OPTS) -/* - * Under test, omit argument processing, or call optionStackArg, - * if multiple copies are allowed. - */ -extern tOptProc - optionPagedUsage, optionStackArg, optionVersionStderr; -static tOptProc - doUsageOpt; +/** Descriptive text for the wide option */ +#define WIDE_DESC (ntpq_opt_strs+1442) +/** Upper-cased name for the wide option */ +#define WIDE_NAME (ntpq_opt_strs+1474) +/** Name string for the wide option */ +#define WIDE_name (ntpq_opt_strs+1479) +/** Compiled in flag settings for the wide option */ +#define WIDE_FLAGS (OPTST_DISABLED) /* - * #define map the "normal" callout procs to the test ones... + * Help/More_Help/Version option descriptions: */ -#define SET_DEBUG_LEVEL_OPT_PROC optionStackArg - - -#else /* NOT defined TEST_NTPQ_OPTS */ -/* - * When not under test, there are different procs to use +#define HELP_DESC (ntpq_opt_strs+1484) +#define HELP_name (ntpq_opt_strs+1528) +#ifdef HAVE_WORKING_FORK +#define MORE_HELP_DESC (ntpq_opt_strs+1533) +#define MORE_HELP_name (ntpq_opt_strs+1578) +#define MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +#else +#define MORE_HELP_DESC HELP_DESC +#define MORE_HELP_name HELP_name +#define MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define VER_FLAGS (OPTST_IMM | OPTST_NO_INIT) +#else +# define VER_FLAGS (OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT) +#endif +#define VER_DESC (ntpq_opt_strs+1588) +#define VER_name (ntpq_opt_strs+1624) +#define SAVE_OPTS_DESC (ntpq_opt_strs+1632) +#define SAVE_OPTS_name (ntpq_opt_strs+1671) +#define LOAD_OPTS_DESC (ntpq_opt_strs+1681) +#define LOAD_OPTS_NAME (ntpq_opt_strs+1713) +#define NO_LOAD_OPTS_name (ntpq_opt_strs+1723) +#define LOAD_OPTS_pfx (ntpq_opt_strs+1736) +#define LOAD_OPTS_name (NO_LOAD_OPTS_name + 3) +/** + * Declare option callback procedures */ extern tOptProc - optionPagedUsage, optionPrintVersion, optionStackArg; + ntpOptionPrintVersion, ntpq_custom_opt_handler, optionBooleanVal, + optionNestedVal, optionNumericVal, optionPagedUsage, + optionResetOpt, optionStackArg, optionTimeDate, + optionTimeVal, optionUnstackArg, optionVendorOption; static tOptProc - doUsageOpt; - -/* - * #define map the "normal" callout procs - */ -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level - -#define SET_DEBUG_LEVEL_OPT_PROC doOptSet_Debug_Level -#endif /* defined(TEST_NTPQ_OPTS) */ -#ifdef TEST_NTPQ_OPTS -# define DOVERPROC optionVersionStderr -#else -# define DOVERPROC optionPrintVersion -#endif /* TEST_NTPQ_OPTS */ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpq Option Descriptions. + doOptDebug_Level, doUsageOpt; +#define VER_PROC ntpOptionPrintVersion + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Define the ntpq Option Descriptions. + * This is an array of OPTION_CT entries, one for each + * option that the ntpq program responds to. */ -static tOptDesc optDesc[ OPTION_CT ] = { +static tOptDesc optDesc[OPTION_CT] = { { /* entry idx, value */ 0, VALUE_OPT_IPV4, - /* equiv idx, value */ NO_EQUIVALENT, 0, + /* equiv idx, value */ 0, VALUE_OPT_IPV4, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV4_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --ipv4 */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv4CantList, /* option proc */ NULL, - /* desc, NAME, name */ zIpv4Text, zIpv4_NAME, zIpv4_Name, + /* desc, NAME, name */ IPV4_DESC, IPV4_NAME, IPV4_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 1, VALUE_OPT_IPV6, - /* equiv idx, value */ NOLIMIT, NOLIMIT, - /* equivalenced to */ INDEX_OPT_IPV4, + /* equiv idx, value */ 1, VALUE_OPT_IPV6, + /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ IPV6_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --ipv6 */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, NULL, + /* must/cannot opts */ NULL, aIpv6CantList, /* option proc */ NULL, - /* desc, NAME, name */ zIpv6Text, zIpv6_NAME, zIpv6_Name, + /* desc, NAME, name */ IPV6_DESC, IPV6_NAME, IPV6_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 2, VALUE_OPT_COMMAND, @@ -264,11 +353,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ COMMAND_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --command */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ optionStackArg, - /* desc, NAME, name */ zCommandText, zCommand_NAME, zCommand_Name, + /* option proc */ ntpq_custom_opt_handler, + /* desc, NAME, name */ COMMAND_DESC, COMMAND_NAME, COMMAND_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 3, VALUE_OPT_DEBUG_LEVEL, @@ -276,11 +365,11 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --debug-level */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ NULL, - /* desc, NAME, name */ zDebug_LevelText, zDebug_Level_NAME, zDebug_Level_Name, + /* option proc */ doOptDebug_Level, + /* desc, NAME, name */ DEBUG_LEVEL_DESC, DEBUG_LEVEL_NAME, DEBUG_LEVEL_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ 4, VALUE_OPT_SET_DEBUG_LEVEL, @@ -288,149 +377,160 @@ static tOptDesc optDesc[ OPTION_CT ] = { /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, /* opt state flags */ SET_DEBUG_LEVEL_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* last opt argumnt */ { NULL }, /* --set-debug-level */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ SET_DEBUG_LEVEL_OPT_PROC, - /* desc, NAME, name */ zSet_Debug_LevelText, zSet_Debug_Level_NAME, zSet_Debug_Level_Name, + /* option proc */ optionNumericVal, + /* desc, NAME, name */ SET_DEBUG_LEVEL_DESC, SET_DEBUG_LEVEL_NAME, SET_DEBUG_LEVEL_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 5, VALUE_OPT_PEERS, - /* equiv idx, value */ 5, VALUE_OPT_PEERS, + { /* entry idx, value */ 5, VALUE_OPT_INTERACTIVE, + /* equiv idx, value */ 5, VALUE_OPT_INTERACTIVE, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ PEERS_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* opt state flags */ INTERACTIVE_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --interactive */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aPeersCantList, + /* must/cannot opts */ NULL, aInteractiveCantList, /* option proc */ NULL, - /* desc, NAME, name */ zPeersText, zPeers_NAME, zPeers_Name, + /* desc, NAME, name */ INTERACTIVE_DESC, INTERACTIVE_NAME, INTERACTIVE_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 6, VALUE_OPT_INTERACTIVE, - /* equiv idx, value */ 6, VALUE_OPT_INTERACTIVE, + { /* entry idx, value */ 6, VALUE_OPT_NUMERIC, + /* equiv idx, value */ 6, VALUE_OPT_NUMERIC, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ INTERACTIVE_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* opt state flags */ NUMERIC_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --numeric */ /* arg list/cookie */ NULL, - /* must/cannot opts */ NULL, aInteractiveCantList, + /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zInteractiveText, zInteractive_NAME, zInteractive_Name, + /* desc, NAME, name */ NUMERIC_DESC, NUMERIC_NAME, NUMERIC_name, /* disablement strs */ NULL, NULL }, - { /* entry idx, value */ 7, VALUE_OPT_NUMERIC, - /* equiv idx, value */ 7, VALUE_OPT_NUMERIC, + { /* entry idx, value */ 7, VALUE_OPT_OLD_RV, + /* equiv idx, value */ 7, VALUE_OPT_OLD_RV, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ NUMERIC_FLAGS, 0, - /* last opt argumnt */ { NULL }, + /* opt state flags */ OLD_RV_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --old-rv */ /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zNumericText, zNumeric_NAME, zNumeric_Name, + /* desc, NAME, name */ OLD_RV_DESC, OLD_RV_NAME, OLD_RV_name, /* disablement strs */ NULL, NULL }, -#ifdef NO_OPTIONAL_OPT_ARGS -# define VERSION_OPT_FLAGS OPTST_IMM | OPTST_NO_INIT -#else -# define VERSION_OPT_FLAGS OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ - OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT -#endif + { /* entry idx, value */ 8, VALUE_OPT_PEERS, + /* equiv idx, value */ 8, VALUE_OPT_PEERS, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ PEERS_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --peers */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, aPeersCantList, + /* option proc */ ntpq_custom_opt_handler, + /* desc, NAME, name */ PEERS_DESC, PEERS_NAME, PEERS_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 9, VALUE_OPT_WIDE, + /* equiv idx, value */ 9, VALUE_OPT_WIDE, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ WIDE_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --wide */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ WIDE_DESC, WIDE_NAME, WIDE_name, + /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_VERSION, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ VERSION_OPT_FLAGS, 0, + /* opt state flags */ VER_FLAGS, AOUSE_VERSION, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, - /* option proc */ DOVERPROC, - /* desc, NAME, name */ zVersionText, NULL, zVersion_Name, + /* option proc */ VER_PROC, + /* desc, NAME, name */ VER_DESC, NULL, VER_name, /* disablement strs */ NULL, NULL }, -#undef VERSION_OPT_FLAGS { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_HELP, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, AOUSE_HELP, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ doUsageOpt, - /* desc, NAME, name */ zHelpText, NULL, zHelp_Name, + /* desc, NAME, name */ HELP_DESC, NULL, HELP_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_MORE_HELP, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, - /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, 0, + /* opt state flags */ MORE_HELP_FLAGS, AOUSE_MORE_HELP, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionPagedUsage, - /* desc, NAME, name */ zMore_HelpText, NULL, zMore_Help_Name, + /* desc, NAME, name */ MORE_HELP_DESC, NULL, MORE_HELP_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_SAVE_OPTS, VALUE_OPT_SAVE_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_SAVE_OPTS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, 1, 0, /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) - | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, 0, + | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, AOUSE_SAVE_OPTS, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ NULL, - /* desc, NAME, name */ zSave_OptsText, NULL, zSave_Opts_Name, + /* desc, NAME, name */ SAVE_OPTS_DESC, NULL, SAVE_OPTS_name, /* disablement strs */ NULL, NULL }, { /* entry idx, value */ INDEX_OPT_LOAD_OPTS, VALUE_OPT_LOAD_OPTS, - /* equiv idx value */ NO_EQUIVALENT, 0, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_LOAD_OPTS, /* equivalenced to */ NO_EQUIVALENT, /* min, max, act ct */ 0, NOLIMIT, 0, - /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) \ - | OPTST_DISABLE_IMM, 0, + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) + | OPTST_DISABLE_IMM, AOUSE_LOAD_OPTS, /* last opt argumnt */ { NULL }, /* arg list/cookie */ NULL, /* must/cannot opts */ NULL, NULL, /* option proc */ optionLoadOpt, - /* desc, NAME, name */ zLoad_OptsText, zLoad_Opts_NAME, zLoad_Opts_Name, - /* disablement strs */ zNotLoad_Opts_Name, zNotLoad_Opts_Pfx } + /* desc, NAME, name */ LOAD_OPTS_DESC, LOAD_OPTS_NAME, LOAD_OPTS_name, + /* disablement strs */ NO_LOAD_OPTS_name, LOAD_OPTS_pfx } }; -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * - * Define the Ntpq Option Environment - */ -tSCC zPROGNAME[] = "NTPQ"; -tSCC zUsageTitle[] = -"ntpq - standard NTP query program - Ver. 4.2.4p8\n\ -USAGE: %s [ - [] | --[{=| }] ]... [ host ...]\n"; -tSCC zRcName[] = ".ntprc"; -tSCC* apzHomeList[] = { - "$HOME", - ".", - NULL }; - -tSCC zBugsAddr[] = "http://bugs.ntp.org, bugs@ntp.org"; -#define zExplain NULL -tSCC zDetail[] = "\n\ -The\n\ -[= prog-name =]\n\ -utility program is used to query NTP servers which\n\ -implement the standard NTP mode 6 control message formats defined\n\ -in Appendix B of the NTPv3 specification RFC1305, requesting\n\ -information about current state and/or changes in that state.\n\ -The same formats are used in NTPv4, although some of the\n\ -variables have changed and new ones added.\n"; -tSCC zFullVersion[] = NTPQ_FULL_VERSION; -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 408 */ + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** Reference to the upper cased version of ntpq. */ +#define zPROGNAME (ntpq_opt_strs+1739) +/** Reference to the title line for ntpq usage. */ +#define zUsageTitle (ntpq_opt_strs+1744) +/** ntpq configuration file name. */ +#define zRcName (ntpq_opt_strs+1871) +/** Directories to search for ntpq config files. */ +static char const * const apzHomeList[3] = { + ntpq_opt_strs+1863, + ntpq_opt_strs+1869, + NULL }; +/** The ntpq program bug email address. */ +#define zBugsAddr (ntpq_opt_strs+1878) +/** Clarification/explanation of what ntpq does. */ +#define zExplain (NULL) +/** Extra detail explaining what ntpq does. */ +#define zDetail (NULL) +/** The full version string for ntpq. */ +#define zFullVersion (ntpq_opt_strs+1912) +/* extracted from optcode.tlib near line 364 */ #if defined(ENABLE_NLS) # define OPTPROC_BASE OPTPROC_TRANSLATE @@ -440,6 +540,90 @@ tSCC zFullVersion[] = NTPQ_FULL_VERSION; # define translate_option_strings NULL #endif /* ENABLE_NLS */ +#define ntpq_full_usage (NULL) +#define ntpq_short_usage (NULL) + +#endif /* not defined __doxygen__ */ + +/* + * Create the static procedure(s) declared above. + */ +/** + * The callout function that invokes the optionUsage function. + * + * @param[in] opts the AutoOpts option description structure + * @param[in] od the descriptor for the "help" (usage) option. + * @noreturn + */ +static void +doUsageOpt(tOptions * opts, tOptDesc * od) +{ + int ex_code; + ex_code = NTPQ_EXIT_SUCCESS; + optionUsage(&ntpqOptions, ex_code); + /* NOTREACHED */ + exit(1); + (void)opts; + (void)od; +} + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Code to handle the debug-level option. + * + * @param[in] pOptions the ntpq options data structure + * @param[in,out] pOptDesc the option descriptor for this option. + */ +static void +doOptDebug_Level(tOptions* pOptions, tOptDesc* pOptDesc) +{ + /* + * Be sure the flag-code[0] handles special values for the options pointer + * viz. (poptions <= OPTPROC_EMIT_LIMIT) *and also* the special flag bit + * ((poptdesc->fOptState & OPTST_RESET) != 0) telling the option to + * reset its state. + */ + /* extracted from debug-opt.def, line 15 */ +OPT_VALUE_SET_DEBUG_LEVEL++; + (void)pOptDesc; + (void)pOptions; +} +/* extracted from optmain.tlib near line 1250 */ + +/** + * The directory containing the data associated with ntpq. + */ +#ifndef PKGDATADIR +# define PKGDATADIR "" +#endif + +/** + * Information about the person or institution that packaged ntpq + * for the current distribution. + */ +#ifndef WITH_PACKAGER +# define ntpq_packager_info NULL +#else +/** Packager information for ntpq. */ +static char const ntpq_packager_info[] = + "Packaged by " WITH_PACKAGER + +# ifdef WITH_PACKAGER_VERSION + " ("WITH_PACKAGER_VERSION")" +# endif + +# ifdef WITH_PACKAGER_BUG_REPORTS + "\nReport ntpq bugs to " WITH_PACKAGER_BUG_REPORTS +# endif + "\n"; +#endif +#ifndef __doxygen__ + +#endif /* __doxygen__ */ +/** + * The option definitions for ntpq. The one structure that + * binds them all. + */ tOptions ntpqOptions = { OPTIONS_STRUCT_VERSION, 0, NULL, /* original argc + argv */ @@ -449,158 +633,529 @@ tOptions ntpqOptions = { + OPTPROC_LONGOPT + OPTPROC_NO_REQ_OPT + OPTPROC_ENVIRON - + OPTPROC_HAS_IMMED ), + + OPTPROC_MISUSE ), 0, NULL, /* current option index, current option */ NULL, NULL, zPROGNAME, - zRcName, zCopyright, zCopyrightNotice, + zRcName, zCopyright, zLicenseDescrip, zFullVersion, apzHomeList, zUsageTitle, zExplain, zDetail, optDesc, zBugsAddr, /* address to send bugs to */ NULL, NULL, /* extensions/saved state */ - optionUsage, /* usage procedure */ + optionUsage, /* usage procedure */ translate_option_strings, /* translation procedure */ /* * Indexes to special options */ - { INDEX_OPT_MORE_HELP, - INDEX_OPT_SAVE_OPTS, - NO_EQUIVALENT /* index of '-#' option */, + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ NO_EQUIVALENT /* index of default opt */ }, - 13 /* full option count */, 8 /* user option count */ + 15 /* full option count */, 10 /* user option count */, + ntpq_full_usage, ntpq_short_usage, + NULL, NULL, + PKGDATADIR, ntpq_packager_info }; -/* - * Create the static procedure(s) declared above. - */ -static void -doUsageOpt( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - USAGE( EXIT_SUCCESS ); -} - -#if ! defined(TEST_NTPQ_OPTS) - -/* * * * * * * - * - * For the set-debug-level option, when DEBUG is #define-d. - */ -#ifdef DEBUG -static void -doOptSet_Debug_Level( - tOptions* pOptions, - tOptDesc* pOptDesc ) -{ - /* extracted from ../include/debug-opt.def, line 29 */ -DESC(DEBUG_LEVEL).optOccCt = atoi( pOptDesc->pzLastArg ); -} -#endif /* defined DEBUG */ - -#endif /* defined(TEST_NTPQ_OPTS) */ - -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optmain.tpl near line 92 */ - -#if defined(TEST_NTPQ_OPTS) /* TEST MAIN PROCEDURE: */ - -int -main( int argc, char** argv ) -{ - int res = EXIT_SUCCESS; - (void)optionProcess( &ntpqOptions, argc, argv ); - { - void optionPutShell( tOptions* ); - optionPutShell( &ntpqOptions ); - } - return res; -} -#endif /* defined TEST_NTPQ_OPTS */ -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/optcode.tpl near line 514 */ - #if ENABLE_NLS +/** + * This code is designed to translate translatable option text for the + * ntpq program. These translations happen upon entry + * to optionProcess(). + */ #include #include #include #include +#ifdef HAVE_DCGETTEXT +# include +#endif #include -static char* AO_gettext( char const* pz ); -static void coerce_it(void** s); +static char * AO_gettext(char const * pz); +static void coerce_it(void ** s); -static char* -AO_gettext( char const* pz ) +/** + * AutoGen specific wrapper function for gettext. It relies on the macro _() + * to convert from English to the target language, then strdup-duplicates the + * result string. It tries the "libopts" domain first, then whatever has been + * set via the \a textdomain(3) call. + * + * @param[in] pz the input text used as a lookup key. + * @returns the translated text (if there is one), + * or the original text (if not). + */ +static char * +AO_gettext(char const * pz) { - char* pzRes; + char * res; if (pz == NULL) return NULL; - pzRes = _(pz); - if (pzRes == pz) - return pzRes; - pzRes = strdup( pzRes ); - if (pzRes == NULL) { - fputs( _("No memory for duping translated strings\n"), stderr ); - exit( EXIT_FAILURE ); +#ifdef HAVE_DCGETTEXT + /* + * While processing the option_xlateable_txt data, try to use the + * "libopts" domain. Once we switch to the option descriptor data, + * do *not* use that domain. + */ + if (option_xlateable_txt.field_ct != 0) { + res = dgettext("libopts", pz); + if (res == pz) + res = (char *)VOIDP(_(pz)); + } else + res = (char *)VOIDP(_(pz)); +#else + res = (char *)VOIDP(_(pz)); +#endif + if (res == pz) + return res; + res = strdup(res); + if (res == NULL) { + fputs(_("No memory for duping translated strings\n"), stderr); + exit(NTPQ_EXIT_FAILURE); } - return pzRes; + return res; } -static void coerce_it(void** s) { *s = AO_gettext(*s); } -#define COERSION(_f) \ - coerce_it((void*)&(ntpqOptions._f)) +/** + * All the pointers we use are marked "* const", but they are stored in + * writable memory. Coerce the mutability and set the pointer. + */ +static void coerce_it(void ** s) { *s = AO_gettext(*s); +} -/* - * This invokes the translation code (e.g. gettext(3)). +/** + * Translate all the translatable strings in the ntpqOptions + * structure defined above. This is done only once. */ static void -translate_option_strings( void ) +translate_option_strings(void) { + tOptions * const opts = &ntpqOptions; + /* * Guard against re-translation. It won't work. The strings will have * been changed by the first pass through this code. One shot only. */ - if (option_usage_text.field_ct == 0) - return; - /* - * Do the translations. The first pointer follows the field count field. - * The field count field is the size of a pointer. - */ - { - char** ppz = (char**)(void*)&(option_usage_text); - int ix = option_usage_text.field_ct; + if (option_xlateable_txt.field_ct != 0) { + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + char ** ppz = (char**)VOIDP(&(option_xlateable_txt)); + int ix = option_xlateable_txt.field_ct; do { - ppz++; + ppz++; /* skip over field_ct */ *ppz = AO_gettext(*ppz); } while (--ix > 0); - } - option_usage_text.field_ct = 0; - - { - tOptDesc* pOD = ntpqOptions.pOptDesc; - int ix = ntpqOptions.optCt; - - for (;;) { - pOD->pzText = AO_gettext(pOD->pzText); - pOD->pz_NAME = AO_gettext(pOD->pz_NAME); - pOD->pz_Name = AO_gettext(pOD->pz_Name); - pOD->pz_DisableName = AO_gettext(pOD->pz_DisableName); - pOD->pz_DisablePfx = AO_gettext(pOD->pz_DisablePfx); - if (--ix <= 0) - break; - pOD++; + /* prevent re-translation and disable "libopts" domain lookup */ + option_xlateable_txt.field_ct = 0; + + coerce_it(VOIDP(&(opts->pzCopyright))); + coerce_it(VOIDP(&(opts->pzCopyNotice))); + coerce_it(VOIDP(&(opts->pzFullVersion))); + coerce_it(VOIDP(&(opts->pzUsageTitle))); + coerce_it(VOIDP(&(opts->pzExplain))); + coerce_it(VOIDP(&(opts->pzDetail))); + { + tOptDesc * od = opts->pOptDesc; + for (ix = opts->optCt; ix > 0; ix--, od++) + coerce_it(VOIDP(&(od->pzText))); } } - COERSION(pzCopyright); - COERSION(pzCopyNotice); - COERSION(pzFullVersion); - COERSION(pzUsageTitle); - COERSION(pzExplain); - COERSION(pzDetail); } - #endif /* ENABLE_NLS */ +#ifdef DO_NOT_COMPILE_THIS_CODE_IT_IS_FOR_GETTEXT +/** I18N function strictly for xgettext. Do not compile. */ +static void bogus_function(void) { + /* TRANSLATORS: + + The following dummy function was crated solely so that xgettext can + extract the correct strings. These strings are actually referenced + by a field name in the ntpqOptions structure noted in the + comments below. The literal text is defined in ntpq_opt_strs. + + NOTE: the strings below are segmented with respect to the source string + ntpq_opt_strs. The strings above are handed off for translation + at run time a paragraph at a time. Consequently, they are presented here + for translation a paragraph at a time. + + ALSO: often the description for an option will reference another option + by name. These are set off with apostrophe quotes (I hope). Do not + translate option names. + */ + /* referenced via ntpqOptions.pzCopyright */ + puts(_("ntpq 4.2.8p4\n\ +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n\ +This is free software. It is licensed for use, modification and\n\ +redistribution under the terms of the NTP License, copies of which\n\ +can be seen at:\n")); + puts(_(" \n\ + \n")); + + /* referenced via ntpqOptions.pzCopyNotice */ + puts(_("Permission to use, copy, modify, and distribute this software and its\n\ +documentation for any purpose with or without fee is hereby granted,\n\ +provided that the above copyright notice appears in all copies and that\n\ +both the copyright notice and this permission notice appear in supporting\n\ +documentation, and that the name The University of Delaware not be used in\n\ +advertising or publicity pertaining to distribution of the software without\n\ +specific, written prior permission. The University of Delaware and Network\n\ +Time Foundation makes no representations about the suitability this\n\ +software for any purpose. It is provided \"as is\" without express or\n\ +implied warranty.\n")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Force IPv4 DNS name resolution")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Force IPv6 DNS name resolution")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("run a command and exit")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Increase debug verbosity level")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Set the debug verbosity level")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Force ntpq to operate in interactive mode")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("numeric host addresses")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Always output status line with readvar")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Print a list of the peers")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("Display the full 'remote' value")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("display extended usage information and exit")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("extended usage information passed thru pager")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("output version information and exit")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("save the option state to a config file")); + + /* referenced via ntpqOptions.pOptDesc->pzText */ + puts(_("load options from a config file")); + + /* referenced via ntpqOptions.pzUsageTitle */ + puts(_("ntpq - standard NTP query program - Ver. 4.2.8p4\n\ +Usage: %s [ - [] | --[{=| }] ]... [ host ...]\n")); + + /* referenced via ntpqOptions.pzFullVersion */ + puts(_("ntpq 4.2.8p4")); + + /* referenced via ntpqOptions.pzFullUsage */ + puts(_("<<>>")); + + /* referenced via ntpqOptions.pzShortUsage */ + puts(_("<<>>")); + /* LIBOPTS-MESSAGES: */ +#line 67 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 93 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 53 "../init.c" + puts(_("AutoOpts function called without option descriptor\n")); +#line 86 "../init.c" + puts(_("\tThis exceeds the compiled library version: ")); +#line 84 "../init.c" + puts(_("Automated Options Processing Error!\n" + "\t%s called AutoOpts function with structure version %d:%d:%d.\n")); +#line 80 "../autoopts.c" + puts(_("realloc of %d bytes at 0x%p failed\n")); +#line 88 "../init.c" + puts(_("\tThis is less than the minimum library version: ")); +#line 121 "../version.c" + puts(_("Automated Options version %s\n" + "\tCopyright (C) 1999-2014 by Bruce Korb - all rights reserved\n")); +#line 87 "../makeshell.c" + puts(_("(AutoOpts bug): %s.\n")); +#line 90 "../reset.c" + puts(_("optionResetOpt() called, but reset-option not configured")); +#line 292 "../usage.c" + puts(_("could not locate the 'help' option")); +#line 336 "../autoopts.c" + puts(_("optionProcess() was called with invalid data")); +#line 748 "../usage.c" + puts(_("invalid argument type specified")); +#line 598 "../find.c" + puts(_("defaulted to option with optional arg")); +#line 76 "../alias.c" + puts(_("aliasing option is out of range.")); +#line 234 "../enum.c" + puts(_("%s error: the keyword '%s' is ambiguous for %s\n")); +#line 108 "../find.c" + puts(_(" The following options match:\n")); +#line 293 "../find.c" + puts(_("%s: ambiguous option name: %s (matches %d options)\n")); +#line 161 "../check.c" + puts(_("%s: Command line arguments required\n")); +#line 43 "../alias.c" + puts(_("%d %s%s options allowed\n")); +#line 94 "../makeshell.c" + puts(_("%s error %d (%s) calling %s for '%s'\n")); +#line 306 "../makeshell.c" + puts(_("interprocess pipe")); +#line 168 "../version.c" + puts(_("error: version option argument '%c' invalid. Use:\n" + "\t'v' - version only\n" + "\t'c' - version and copyright\n" + "\t'n' - version and full copyright notice\n")); +#line 58 "../check.c" + puts(_("%s error: the '%s' and '%s' options conflict\n")); +#line 217 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 430 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 38 "../alias.c" + puts(_("-equivalence")); +#line 469 "../find.c" + puts(_("%s: illegal option -- %c\n")); +#line 110 "../reset.c" + puts(_("%s: illegal option -- %c\n")); +#line 271 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 755 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 118 "../reset.c" + puts(_("%s: illegal option -- %s\n")); +#line 335 "../find.c" + puts(_("%s: unknown vendor extension option -- %s\n")); +#line 159 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 169 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 747 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 1081 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 385 "../find.c" + puts(_("%s: invalid option name: %s\n")); +#line 527 "../find.c" + puts(_("%s: The '%s' option requires an argument.\n")); +#line 156 "../autoopts.c" + puts(_("(AutoOpts bug): Equivalenced option '%s' was equivalenced to both\n" + "\t'%s' and '%s'.")); +#line 94 "../check.c" + puts(_("%s error: The %s option is required\n")); +#line 632 "../find.c" + puts(_("%s: The '%s' option cannot have an argument.\n")); +#line 151 "../check.c" + puts(_("%s: Command line arguments are not allowed.\n")); +#line 535 "../save.c" + puts(_("error %d (%s) creating %s\n")); +#line 234 "../enum.c" + puts(_("%s error: '%s' does not match any %s keywords.\n")); +#line 93 "../reset.c" + puts(_("%s error: The '%s' option requires an argument.\n")); +#line 184 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 238 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 143 "../restore.c" + puts(_("%s error: no saved option state\n")); +#line 231 "../autoopts.c" + puts(_("'%s' is not a command line option.\n")); +#line 111 "../time.c" + puts(_("%s error: '%s' is not a recognizable date/time.\n")); +#line 132 "../save.c" + puts(_("'%s' not defined\n")); +#line 50 "../time.c" + puts(_("%s error: '%s' is not a recognizable time duration.\n")); +#line 92 "../check.c" + puts(_("%s error: The %s option must appear %d times.\n")); +#line 164 "../numeric.c" + puts(_("%s error: '%s' is not a recognizable number.\n")); +#line 200 "../enum.c" + puts(_("%s error: %s exceeds %s keyword count\n")); +#line 330 "../usage.c" + puts(_("Try '%s %s' for more information.\n")); +#line 45 "../alias.c" + puts(_("one %s%s option allowed\n")); +#line 208 "../makeshell.c" + puts(_("standard output")); +#line 943 "../makeshell.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard output")); +#line 415 "../usage.c" + puts(_("standard output")); +#line 625 "../usage.c" + puts(_("standard output")); +#line 175 "../version.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard error")); +#line 415 "../usage.c" + puts(_("standard error")); +#line 625 "../usage.c" + puts(_("standard error")); +#line 175 "../version.c" + puts(_("standard error")); +#line 208 "../makeshell.c" + puts(_("write")); +#line 943 "../makeshell.c" + puts(_("write")); +#line 273 "../usage.c" + puts(_("write")); +#line 414 "../usage.c" + puts(_("write")); +#line 624 "../usage.c" + puts(_("write")); +#line 174 "../version.c" + puts(_("write")); +#line 60 "../numeric.c" + puts(_("%s error: %s option value %ld is out of range.\n")); +#line 44 "../check.c" + puts(_("%s error: %s option requires the %s option\n")); +#line 131 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 183 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 237 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 256 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 534 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); + /* END-LIBOPTS-MESSAGES */ + + /* USAGE-TEXT: */ +#line 873 "../usage.c" + puts(_("\t\t\t\t- an alternate for '%s'\n")); +#line 1148 "../usage.c" + puts(_("Version, usage and configuration options:")); +#line 924 "../usage.c" + puts(_("\t\t\t\t- default option for unnamed options\n")); +#line 837 "../usage.c" + puts(_("\t\t\t\t- disabled as '--%s'\n")); +#line 1117 "../usage.c" + puts(_(" --- %-14s %s\n")); +#line 1115 "../usage.c" + puts(_("This option has been disabled")); +#line 864 "../usage.c" + puts(_("\t\t\t\t- enabled by default\n")); +#line 40 "../alias.c" + puts(_("%s error: only ")); +#line 1194 "../usage.c" + puts(_(" - examining environment variables named %s_*\n")); +#line 168 "../file.c" + puts(_("\t\t\t\t- file must not pre-exist\n")); +#line 172 "../file.c" + puts(_("\t\t\t\t- file must pre-exist\n")); +#line 380 "../usage.c" + puts(_("Options are specified by doubled hyphens and their name or by a single\n" + "hyphen and the flag character.\n")); +#line 921 "../makeshell.c" + puts(_("\n" + "= = = = = = = =\n\n" + "This incarnation of genshell will produce\n" + "a shell script to parse the options for %s:\n\n")); +#line 166 "../enum.c" + puts(_(" or an integer mask with any of the lower %d bits set\n")); +#line 897 "../usage.c" + puts(_("\t\t\t\t- is a set membership option\n")); +#line 918 "../usage.c" + puts(_("\t\t\t\t- must appear between %d and %d times\n")); +#line 382 "../usage.c" + puts(_("Options are specified by single or double hyphens and their name.\n")); +#line 904 "../usage.c" + puts(_("\t\t\t\t- may appear multiple times\n")); +#line 891 "../usage.c" + puts(_("\t\t\t\t- may not be preset\n")); +#line 1309 "../usage.c" + puts(_(" Arg Option-Name Description\n")); +#line 1245 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1303 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1304 "../usage.c" + puts(_(" %3s %s")); +#line 1310 "../usage.c" + puts(_(" %3s %s")); +#line 387 "../usage.c" + puts(_("The '-#' option may omit the hash char\n")); +#line 383 "../usage.c" + puts(_("All arguments are named options.\n")); +#line 971 "../usage.c" + puts(_(" - reading file %s")); +#line 409 "../usage.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 100 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 129 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 903 "../usage.c" + puts(_("\t\t\t\t- may NOT appear - preset only\n")); +#line 944 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 1192 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 682 "../usage.c" + puts(_("prohibits these options:\n")); +#line 677 "../usage.c" + puts(_("prohibits the option '%s'\n")); +#line 81 "../numeric.c" + puts(_("%s%ld to %ld")); +#line 79 "../numeric.c" + puts(_("%sgreater than or equal to %ld")); +#line 75 "../numeric.c" + puts(_("%s%ld exactly")); +#line 68 "../numeric.c" + puts(_("%sit must lie in one of the ranges:\n")); +#line 68 "../numeric.c" + puts(_("%sit must be in the range:\n")); +#line 88 "../numeric.c" + puts(_(", or\n")); +#line 66 "../numeric.c" + puts(_("%sis scalable with a suffix: k/K/m/M/g/G/t/T\n")); +#line 77 "../numeric.c" + puts(_("%sless than or equal to %ld")); +#line 390 "../usage.c" + puts(_("Operands and options may be intermixed. They will be reordered.\n")); +#line 652 "../usage.c" + puts(_("requires the option '%s'\n")); +#line 655 "../usage.c" + puts(_("requires these options:\n")); +#line 1321 "../usage.c" + puts(_(" Arg Option-Name Req? Description\n")); +#line 1315 "../usage.c" + puts(_(" Flg Arg Option-Name Req? Description\n")); +#line 167 "../enum.c" + puts(_("or you may use a numeric representation. Preceding these with a '!'\n" + "will clear the bits, specifying 'none' will clear all bits, and 'all'\n" + "will set them all. Multiple entries may be passed as an option\n" + "argument list.\n")); +#line 910 "../usage.c" + puts(_("\t\t\t\t- may appear up to %d times\n")); +#line 77 "../enum.c" + puts(_("The valid \"%s\" option keywords are:\n")); +#line 1152 "../usage.c" + puts(_("The next option supports vendor supported extra options:")); +#line 773 "../usage.c" + puts(_("These additional options are:")); + /* END-USAGE-TEXT */ +} +#endif /* uncompilable code */ #ifdef __cplusplus } #endif diff --git a/contrib/ntp/ntpq/ntpq-opts.def b/contrib/ntp/ntpq/ntpq-opts.def index 928bd9df9..bac20d79a 100644 --- a/contrib/ntp/ntpq/ntpq-opts.def +++ b/contrib/ntp/ntpq/ntpq-opts.def @@ -10,12 +10,10 @@ prog-name = "ntpq"; prog-title = "standard NTP query program"; argument = '[ host ...]'; -test-main; - flag = { name = ipv4; + flags-cant = ipv6; value = 4; - equivalence = ipv4; descrip = "Force IPv4 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -25,8 +23,8 @@ flag = { flag = { name = ipv6; + flags-cant = ipv4; value = 6; - equivalence = ipv4; descrip = "Force IPv6 DNS name resolution"; doc = <<- _EndOfDoc_ Force DNS resolution of following host names on the command line @@ -41,7 +39,7 @@ flag = { descrip = "run a command and exit"; max = NOLIMIT; arg-name = cmd; - stack-arg; + call-proc = ntpq_custom_opt_handler; doc = <<- _EndOfDoc_ The following argument is interpreted as an interactive format command and is added to the list of commands to be executed on the specified @@ -51,25 +49,15 @@ flag = { #include debug-opt.def -flag = { - name = peers; - value = p; - descrip = "Print a list of the peers"; - flags-cant = interactive; - doc = <<- _EndOfDoc_ - Print a list of the peers known to the server as well as a summary - of their state. This is equivalent to the 'peers' interactive command. - _EndOfDoc_; -}; - flag = { name = interactive; value = i; flags-cant = command, peers; descrip = "Force ntpq to operate in interactive mode"; doc = <<- _EndOfDoc_ - Force ntpq to operate in interactive mode. Prompts will be written - to the standard output and commands read from the standard input. + Force @code{ntpq} to operate in interactive mode. + Prompts will be written to the standard output and + commands read from the standard input. _EndOfDoc_; }; @@ -83,263 +71,878 @@ flag = { _EndOfDoc_; }; -detail = <<- _END_DETAIL - The - [= prog-name =] - utility program is used to query NTP servers which - implement the standard NTP mode 6 control message formats defined - in Appendix B of the NTPv3 specification RFC1305, requesting - information about current state and/or changes in that state. - The same formats are used in NTPv4, although some of the - variables have changed and new ones added. - _END_DETAIL; +flag = { + name = old-rv; + descrip = "Always output status line with readvar"; + doc = <<- _EndOfDoc_ + By default, @code{ntpq} now suppresses the @code{associd=...} + line that precedes the output of @code{readvar} + (alias @code{rv}) when a single variable is requested, such as + @code{ntpq -c "rv 0 offset"}. + This option causes @code{ntpq} to include both lines of output + for a single-variable @code{readvar}. + Using an environment variable to + preset this option in a script will enable both older and + newer @code{ntpq} to behave identically in this regard. + _EndOfDoc_; +}; + +flag = { + name = peers; + value = p; + descrip = "Print a list of the peers"; + flags-cant = interactive; + call-proc = ntpq_custom_opt_handler; + doc = <<- _EndOfDoc_ + Print a list of the peers known to the server as well as a summary + of their state. This is equivalent to the 'peers' interactive command. + _EndOfDoc_; +}; + +flag = { + name = wide; + value = w; + descrip = "Display the full 'remote' value"; + doc = <<- _EndOfDoc_ + Display the full value of the 'remote' value. If this requires + more than 15 characters, display the full value, emit a newline, + and continue the data display properly indented on the next line. + _EndOfDoc_; +}; -prog-man-descrip = <<- _END_PROG_MAN_DESCRIP - The - [= prog-name =] - utility program is used to query NTP servers which - implement the standard NTP mode 6 control message formats defined - in Appendix B of the NTPv3 specification RFC1305, requesting - information about current state and/or changes in that state. - The same formats are used in NTPv4, although some of the - variables have changed and new ones added. The description on this - page is for the NTPv4 variables. - The program may be run either in interactive mode or controlled using - command line arguments. - Requests to read and write arbitrary - variables can be assembled, with raw and pretty-printed output - options being available. - The - [= prog-name =] - utility can also obtain and print a - list of peers in a common format by sending multiple queries to the - server. +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP - If one or more request options is included on the command line - when - [= prog-name =] - is executed, each of the requests will be sent - to the NTP servers running on each of the hosts given as command - line arguments, or on localhost by default. - If no request options - are given, - [= prog-name =] - will attempt to read commands from the - standard input and execute these on the NTP server running on the - first host given on the command line, again defaulting to localhost - when no other host is specified. - The - [= prog-name =] - utility will prompt for - commands if the standard input is a terminal device. +The +.Nm +utility program is used to query NTP servers which +implement the standard NTP mode 6 control message formats defined +in Appendix B of the NTPv3 specification RFC1305, requesting +information about current state and/or changes in that state. +The same formats are used in NTPv4, although some of the +variables have changed and new ones added. The description on this +page is for the NTPv4 variables. +The program may be run either in interactive mode or controlled using +command line arguments. +Requests to read and write arbitrary +variables can be assembled, with raw and pretty-printed output +options being available. +The +.Nm +utility can also obtain and print a +list of peers in a common format by sending multiple queries to the +server. - The - [= prog-name =] - utility uses NTP mode 6 packets to communicate with the - NTP server, and hence can be used to query any compatible server on - the network which permits it. - Note that since NTP is a UDP protocol - this communication will be somewhat unreliable, especially over - large distances in terms of network topology. - The - [= prog-name =] - utility makes - one attempt to retransmit requests, and will time requests out if - the remote host is not heard from within a suitable timeout - time. +If one or more request options is included on the command line +when +.Nm +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +.Nm +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +.Nm +utility will prompt for +commands if the standard input is a terminal device. - Specifying a - command line option other than - .Fl i - or - .Fl n - will - cause the specified query (queries) to be sent to the indicated - host(s) immediately. - Otherwise, - [= prog-name =] - will attempt to read - interactive format commands from the standard input. - .Ss "Internal Commands" - Interactive format commands consist of a keyword followed by zero - to four arguments. - Only enough characters of the full keyword to - uniquely identify the command need be typed. +.Nm +uses NTP mode 6 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +.Nm +utility makes +one attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. - A - number of interactive format commands are executed entirely within - the - [= prog-name =] - utility itself and do not result in NTP mode 6 - requests being sent to a server. - These are described following. - @table @code - @item ? [command_keyword] - @itemx help [command_keyword] - A - .Ql \&? - by itself will print a list of all the command - keywords known to this incarnation of - [= prog-name =] . - A - .Ql \&? - followed by a command keyword will print function and usage - information about the command. - This command is probably a better - source of information about - [= prog-name =] - than this manual - page. - @item addvars - .Ar variable_name [=value] ... - .Xc - @item rmvars variable_name ... - @item clearvars - The data carried by NTP mode 6 messages consists of a list of - items of the form - .Ql variable_name=value , - where the - .Ql =value - is ignored, and can be omitted, - in requests to the server to read variables. - The - [= prog-name =] - utility maintains an internal list in which data to be included in control - messages can be assembled, and sent using the - .Ic readlist - and - .Ic writelist - commands described below. - The - .Ic addvars - command allows variables and their optional values to be added to - the list. - If more than one variable is to be added, the list should - be comma-separated and not contain white space. - The - .Ic rmvars - command can be used to remove individual variables from the list, - while the - .Ic clearlist - command removes all variables from the - list. - @item authenticate [ yes | no ] - Normally - [= prog-name =] - does not authenticate requests unless - they are write requests. - The command - .Ql authenticate yes - causes - [= prog-name =] - to send authentication with all requests it - makes. - Authenticated requests causes some servers to handle - requests slightly differently, and can occasionally melt the CPU in - fuzzballs if you turn authentication on before doing a - .Ic peer - display. - The command - .Ql authenticate - causes - [= prog-name =] - to display whether or not - [= prog-name =] - is currently autheinticating requests. - @item cooked - Causes output from query commands to be "cooked", so that - variables which are recognized by - [= prog-name =] - will have their - values reformatted for human consumption. - Variables which - [= prog-name =] - thinks should have a decodable value but didn't are - marked with a trailing - .Ql \&? . - .@item debug [ - .Cm more | - .Cm less | - .Cm off - ] - .Xc - With no argument, displays the current debug level. - Otherwise, the debug level is changed to the indicated level. - @item delay milliseconds - Specify a time interval to be added to timestamps included in - requests which require authentication. - This is used to enable - (unreliable) server reconfiguration over long delay network paths - or between machines whose clocks are unsynchronized. - Actually the - server does not now require timestamps in authenticated requests, - so this command may be obsolete. - @item host hostname - Set the host to which future queries will be sent. - Hostname may - be either a host name or a numeric address. - @item hostnames Cm yes | Cm no - If - .Cm yes - is specified, host names are printed in - information displays. - If - .Cm no - is specified, numeric - addresses are printed instead. - The default is - .Cm yes , - unless - modified using the command line - .Fl n - switch. - @item keyid keyid - This command allows the specification of a key number to be - used to authenticate configuration requests. - This must correspond - to a key number the server has been configured to use for this - purpose. - @item ntpversion [ - .Cm 1 | - .Cm 2 | - .Cm 3 | - .Cm 4 - ] - .Xc - Sets the NTP version number which - [= prog-name =] - claims in - packets. - Defaults to 3, Note that mode 6 control messages (and - modes, for that matter) didn't exist in NTP version 1. - There appear - to be no servers left which demand version 1. - With no argument, displays the current NTP version that will be used - when communicating with servers. - @item quit - Exit - [= prog-name =] . - @item passwd - This command prompts you to type in a password (which will not - be echoed) which will be used to authenticate configuration - requests. - The password must correspond to the key configured for - use by the NTP server for this purpose if such requests are to be - successful. - @item raw - Causes all output from query commands is printed as received - from the remote server. - The only formating/interpretation done on - the data is to transform nonascii data into a printable (but barely - understandable) form. - @item timeout Ar milliseconds - Specify a timeout period for responses to server queries. - The - default is about 5000 milliseconds. - Note that since - [= prog-name =] - retries each query once after a timeout, the total waiting time for - a timeout will be twice the timeout value set. - @end table +Specifying a +command line option other than +.Fl i +or +.Fl n +will +cause the specified query (queries) to be sent to the indicated +host(s) immediately. +Otherwise, +.Nm +will attempt to read +interactive format commands from the standard input. +.Ss "Internal Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. - _END_PROG_MAN_DESCRIP; +A +number of interactive format commands are executed entirely within +the +.Nm +utility itself and do not result in NTP mode 6 +requests being sent to a server. +These are described following. +.Bl -tag -width "? [command_keyword]" -compact -offset indent +.It Ic ? Op Ar command_keyword +.It Ic help Op Ar command_keyword +A +.Ql \&? +by itself will print a list of all the command +keywords known to this incarnation of +.Nm . +A +.Ql \&? +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +.Nm +than this manual +page. +.It Ic addvars Ar variable_name Ns Xo Op Ic =value +.Ic ... +.Xc +.It Ic rmvars Ar variable_name Ic ... +.It Ic clearvars +.It Ic showvars +The data carried by NTP mode 6 messages consists of a list of +items of the form +.Ql variable_name=value , +where the +.Ql =value +is ignored, and can be omitted, +in requests to the server to read variables. +The +.Nm +utility maintains an internal list in which data to be included in control +messages can be assembled, and sent using the +.Ic readlist +and +.Ic writelist +commands described below. +The +.Ic addvars +command allows variables and their optional values to be added to +the list. +If more than one variable is to be added, the list should +be comma-separated and not contain white space. +The +.Ic rmvars +command can be used to remove individual variables from the list, +while the +.Ic clearlist +command removes all variables from the +list. +The +.Ic showvars +command displays the current list of optional variables. +.It Ic authenticate Op yes | no +Normally +.Nm +does not authenticate requests unless +they are write requests. +The command +.Ql authenticate yes +causes +.Nm +to send authentication with all requests it +makes. +Authenticated requests causes some servers to handle +requests slightly differently, and can occasionally melt the CPU in +fuzzballs if you turn authentication on before doing a +.Ic peer +display. +The command +.Ql authenticate +causes +.Nm +to display whether or not +.Nm +is currently autheinticating requests. +.It Ic cooked +Causes output from query commands to be "cooked", so that +variables which are recognized by +.Nm +will have their +values reformatted for human consumption. +Variables which +.Nm +thinks should have a decodable value but didn't are +marked with a trailing +.Ql \&? . +.It Xo +.Ic debug +.Oo +.Cm more | +.Cm less | +.Cm off +.Oc +.Xc +With no argument, displays the current debug level. +Otherwise, the debug level is changed to the indicated level. +.It Ic delay Ar milliseconds +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.It Ic exit +Exit +.Nm . +.It Ic host Ar hostname +Set the host to which future queries will be sent. +.Ar hostname +may be either a host name or a numeric address. +.It Ic hostnames Op Cm yes | Cm no +If +.Cm yes +is specified, host names are printed in +information displays. +If +.Cm no +is specified, numeric +addresses are printed instead. +The default is +.Cm yes , +unless +modified using the command line +.Fl n +switch. +.It Ic keyid Ar keyid +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to the +.Cm controlkey +key number the server has been configured to use for this +purpose. +.It Ic keytype Xo Oo +.Cm md5 | +.Cm OpenSSLDigestType +.Oc +.Xc +Specify the type of key to use for authenticating requests. +.Cm md5 +is alway supported. +If +.Nm +was built with OpenSSL support, +any digest type supported by OpenSSL can also be provided. +If no argument is given, the current +.Ic keytype +is displayed. +.It Ic ntpversion Xo Oo +.Cm 1 | +.Cm 2 | +.Cm 3 | +.Cm 4 +.Oc +.Xc +Sets the NTP version number which +.Nm +claims in +packets. +Defaults to 3, and note that mode 6 control messages (and +modes, for that matter) didn't exist in NTP version 1. +There appear +to be no servers left which demand version 1. +With no argument, displays the current NTP version that will be used +when communicating with servers. +.It Ic passwd +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.\" Not yet implemented. +.\" .It Ic poll +.\" .Op Ar n +.\" .Op Ic verbose +.\" Poll an NTP server in client mode +.\" .Ar n +.\" times. +.It Ic quit +Exit +.Nm . +.It Ic raw +Causes all output from query commands is printed as received +from the remote server. +The only formating/interpretation done on +the data is to transform nonascii data into a printable (but barely +understandable) form. +.It Ic timeout Ar milliseconds +Specify a timeout period for responses to server queries. +The +default is about 5000 milliseconds. +Note that since +.Nm +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.It Ic version +Print the version of the +.Nm +program. +.El + +.Ss "Control Message Commands" +Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode-6 message to the server and expect a single response message. +The exceptions are the +.Li peers +command, which sends a series of messages, +and the +.Li mreadlist +and +.Li mreadvar +commands, which iterate over a range of associations. +.Bl -tag -width "something" -compact -offset indent +.It Cm associations +Display a list of mobilized associations in the form: +.Dl ind assid status conf reach auth condition last_event cnt +.Bl -column -offset indent ".Sy Variable" ".Sy Description" +.It Sy String Ta Sy Description +.It Li ind Ta index on this list +.It Li assid Ta association ID +.It Li status Ta peer status word +.It Li conf Ta Li yes : persistent, Li no : ephemeral +.It Li reach Ta Li yes : reachable, Li no : unreachable +.It Li auth Ta Li ok , Li yes , Li bad and Li none +.It Li condition Ta selection status (see the Li select field of the peer status word) +.It Li last_event Ta event report (see the Li event field of the peer status word) +.It Li cnt Ta event count (see the Li count field of the peer status word) +.El +.It Cm authinfo +Display the authentication statistics. +.It Cm clockvar Ar assocID Oo Ar name Ns Oo Cm = Ns Ar value Oc Oc Op ... +.It Cm cv Ar assocID Oo Ar name Ns Oo Cm = Ns Ar value Oc Oc Op ... +Display a list of clock variables for those associations supporting a reference clock. +.It Cm :config Op ... +Send the remainder of the command line, including whitespace, to the server as a run-time configuration command in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is of course required. +.It Cm config-from-file Ar filename +Send the each line of +.Ar filename +to the server as run-time configuration commands in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is required. +.It Ic ifstats +Display statistics for each local network address. Authentication is required. +.It Ic iostats +Display network and reference clock I/O statistics. +.It Ic kerninfo +Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable. +.It Ic lassociations +Perform the same function as the associations command, except display mobilized and unmobilized associations. +.It Ic lopeers Xo +.Oo Ic -4 | +.Ic -6 +.Oc +.Xc +Obtain and print a list of all peers and clients showing +.Ar dstadr +(associated with any given IP version). +.It Ic lpeers Xo +.Oo Ic -4 | +.Ic -6 +.Oc +.Xc +Print a peer spreadsheet for the appropriate IP version(s). +.Ar dstadr +(associated with any given IP version). +.It Ic monstats +Display monitor facility statistics. +.It Ic mrulist Oo Ic limited | Ic kod | Ic mincount Ns = Ns Ar count | Ic laddr Ns = Ns Ar localaddr | Ic sort Ns = Ns Ar sortorder | Ic resany Ns = Ns Ar hexmask | Ic resall Ns = Ns Ar hexmask Oc +Obtain and print traffic counts collected and maintained by the monitor facility. +With the exception of +.Cm sort Ns = Ns Ar sortorder , +the options filter the list returned by +.Cm ntpd. +The +.Cm limited +and +.Cm kod +options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. +The +.Cm mincount Ns = Ns Ar count +option filters entries representing less than +.Ar count +packets. +The +.Cm laddr Ns = Ns Ar localaddr +option filters entries for packets received on any local address other than +.Ar localaddr . +.Cm resany Ns = Ns Ar hexmask +and +.Cm resall Ns = Ns Ar hexmask +filter entries containing none or less than all, respectively, of the bits in +.Ar hexmask , +which must begin with +.Cm 0x . +The +.Ar sortorder +defaults to +.Cm lstint +and may be any of +.Cm addr , +.Cm count , +.Cm avgint , +.Cm lstint , +or any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: +.Bl -tag -width "something" -compact -offset indent +.It Column +Description +.It Ic lstint +Interval in s between the receipt of the most recent packet from this address and the completion of the retrieval of the MRU list by +.Nm . +.It Ic avgint +Average interval in s between packets from this address. +.It Ic rstr +Restriction flags associated with this address. +Most are copied unchanged from the matching +.Ic restrict +command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this address triggered a rate control response. +.It Ic r +Rate control indicator, either +a period, +.Ic L +or +.Ic K +for no rate control response, +rate limiting by discarding, or rate limiting with a KoD response, respectively. +.It Ic m +Packet mode. +.It Ic v +Packet version number. +.It Ic count +Packets received from this address. +.It Ic rport +Source port of last packet from this address. +.It Ic remote address +DNS name, numeric address, or address followed by +claimed DNS name which could not be verified in parentheses. +.El +.It Ic mreadvar assocID assocID Oo Ar variable_name Ns Oo = Ns Ar value Oc Oc ... +.It Ic mrv assocID assocID Oo Ar variable_name Ns Oo = Ns Ar value Oc Oc ... +Perform the same function as the +.Ic readvar +command, except for a range of association IDs. +This range is determined from the association list cached by the most recent +.Ic associations +command. +.It Ic opeers Xo +.Oo Ic -4 | +.Ic -6 +.Oc +.Xc +Obtain and print the old-style list of all peers and clients showing +.Ar dstadr +(associated with any given IP version), +rather than the +.Ar refid . +.It Ic passociations +Perform the same function as the +.Ic associations +command, +except that it uses previously stored data rather than making a new query. +.It Ic peers +Display a list of peers in the form: +.Dl [tally]remote refid st t when pool reach delay offset jitter +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic [tally] +single-character code indicating current value of the +.Ic select +field of the +.Lk decode.html#peer "peer status word" +.It Ic remote +host name (or IP number) of peer. +The value displayed will be truncated to 15 characters unless the +.Fl w +flag is given, in which case the full value will be displayed +on the first line, +and the remaining data is displayed on the next line. +.It Ic refid +association ID or +.Lk decode.html#kiss "'kiss code" +.It Ic st +stratum +.It Ic t +.Ic u : +unicast or manycast client, +.Ic b : +broadcast or multicast client, +.Ic l : +local (reference clock), +.Ic s : +symmetric (peer), +.Ic A : +manycast server, +.Ic B : +broadcast server, +.Ic M : +multicast server +.It Ic when +sec/min/hr since last received packet +.It Ic poll +poll interval (log2 s) +.It Ic reach +reach shift register (octal) +.It Ic delay +roundtrip delay +.It Ic offset +offset of server relative to this host +.It Ic jitter +jitter +.El +.It Ic apeers +Display a list of peers in the form: +.Dl [tally]remote refid assid st t when pool reach delay offset jitter +where the output is just like the +.Ic peers +command except that the +.Ic refid +is displayed in hex format and the association number is also displayed. +.It Ic pstats Ar assocID +Show the statistics for the peer with the given +.Ar assocID . +.It Ic readlist Ar assocID +.It Ic rl Ar assocID +Read the system or peer variables included in the variable list. +.It Ic readvar Ar assocID Ar name Ns Oo Ns = Ns Ar value Oc Oo , ... Oc +.It Ic rv Ar assocID Ar name Ns Oo Ns = Ns Ar value Oc Oo , ... Oc +Display the specified variables. +If +.Ar assocID +is zero, the variables are from the +.Sx System Variables +name space, otherwise they are from the +.Sx Peer Variables +name space. +The +.Ar assocID +is required, as the same name can occur in both spaces. +If no +.Ar name +is included, all operative variables in the name space are displayed. + +In this case only, if the +.Ar assocID +is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds +and frequency values in parts-per-million (PPM). +Some NTP timestamps are represented in the format +YYYYMMDDTTTT , +where YYYY is the year, +MM the month of year, +DD the day of month and +TTTT the time of day. +.It Ic reslist +Show the access control (restrict) list for +.Nm . + +.It Ic saveconfig Ar filename +Write the current configuration, +including any runtime modifications given with +.Ic :config +or +.Ic config-from-file , +to the ntpd host's file +.Ar filename . +This command will be rejected by the server unless +.Lk miscopt.html#saveconfigdir "saveconfigdir" +appears in the +.Ic ntpd +configuration file. +.Ar filename +can use +.Xr strftime +format specifies to substitute the current date and time, for example, +.Ic q]saveconfig ntp-%Y%m%d-%H%M%S.confq] . +The filename used is stored in system variable +.Ic savedconfig . +Authentication is required. +.It Ic timerstats +Display interval timer counters. +.It Ic writelist Ar assocID +Write the system or peer variables included in the variable list. +.It Ic writevar Ar assocID Ar name Ns = Ns Ar value Op , ... +Write the specified variables. +If the +.Ar assocID +is zero, the variables are from the +.Sx System Variables +name space, otherwise they are from the +.Sx Peer Variables +name space. +The +.Ar assocID +is required, as the same name can occur in both spaces. +.It Ic sysinfo +Display operational summary. +.It Ic sysstats +Print statistics counters maintained in the protocol module. +.El + +.Ss Status Words and Kiss Codes + +The current state of the operating program is shown +in a set of status words +maintained by the system. +Status information is also available on a per-association basis. +These words are displayed in the +.Ic rv +and +.Ic as +commands both in hexadecimal and in decoded short tip strings. +The codes, tips and short explanations are documented on the +.Lk decode.html "Event Messages and Status Words" +page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. +.Pp +Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +.Lk decode.html#kiss "kiss codes" . +The original purpose was for kiss-o'-death (KoD) packets +sent by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. + +.Ss System Variables +The following system variables appear in the +.Ic rv +billboard. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic status +.Lk decode.html#sys "system status word" +.It Ic version +NTP software version and build time +.It Ic processor +hardware platform and version +.It Ic system +operating system and version +.It Ic leap +leap warning indicator (0-3) +.It Ic stratum +stratum (1-15) +.It Ic precision +precision (log2 s) +.It Ic rootdelay +total roundtrip delay to the primary reference clock +.It Ic rootdisp +total dispersion to the primary reference clock +.It Ic peer +system peer association ID +.It Ic tc +time constant and poll exponent (log2 s) (3-17) +.It Ic mintc +minimum time constant (log2 s) (3-10) +.It Ic clock +date and time of day +.It Ic refid +reference ID or +.Lk decode.html#kiss "kiss code" +.It Ic reftime +reference time +.It Ic offset +combined offset of server relative to this host +.It Ic sys_jitter +combined system jitter +.It Ic frequency +frequency offset (PPM) relative to hardware clock +.It Ic clk_wander +clock frequency wander (PPM) +.It Ic clk_jitter +clock jitter +.It Ic tai +TAI-UTC offset (s) +.It Ic leapsec +NTP seconds when the next leap second is/was inserted +.It Ic expire +NTP seconds when the NIST leapseconds file expires +.El +The jitter and wander statistics are exponentially-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. +.Pp +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, +including some or all of the following, +depending on the particular Autokey dance: + +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic host +Autokey host name for this host +.It Ic ident +Autokey group name for this host +.It Ic flags +host flags (see Autokey specification) +.It Ic digest +OpenSSL message digest algorithm +.It Ic signature +OpenSSL digest/signature scheme +.It Ic update +NTP seconds at last signature update +.It Ic cert +certificate subject, issuer and certificate flags +.It Ic until +NTP seconds when the certificate expires +.El +.Ss Peer Variables +The following peer variables appear in the +.Ic rv +billboard for each association. +Not all variables are displayed in some configurations. + +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic associd +association ID +.It Ic status +.Lk decode.html#peer "peer status word" +.It Ic srcadr +source (remote) IP address +.It Ic srcport +source (remote) port +.It Ic dstadr +destination (local) IP address +.It Ic dstport +destination (local) port +.It Ic leap +leap indicator (0-3) +.It Ic stratum +stratum (0-15) +.It Ic precision +precision (log2 s) +.It Ic rootdelay +total roundtrip delay to the primary reference clock +.It Ic rootdisp +total root dispersion to the primary reference clock +.It Ic refid +reference ID or +.Lk decode.html#kiss "kiss code" +.It Ic reftime +reference time +.It Ic reach +reach register (octal) +.It Ic unreach +unreach counter +.It Ic hmode +host mode (1-6) +.It Ic pmode +peer mode (1-5) +.It Ic hpoll +host poll exponent (log2 s) (3-17) +.It Ic ppoll +peer poll exponent (log2 s) (3-17) +.It Ic headway +headway (see +.Lk rate.html "Rate Management and the Kiss-o'-Death Packet" ) +.It Ic flash +.Lk decode.html#flash "flash status word" +.It Ic offset +filter offset +.It Ic delay +filter delay +.It Ic dispersion +filter dispersion +.It Ic jitter +filter jitter +.It Ic ident +Autokey group name for this association +.It Ic bias +unicast/broadcast bias +.It Ic xleave +interleave delay (see +.Lk xleave.html "NTP Interleaved Modes" ) +.El +The +.Ic bias +variable is calculated when the first broadcast packet is received +after the calibration volley. +It represents the offset of the broadcast subgraph relative to the unicast subgraph. +The +.Ic xleave +variable appears only for the interleaved symmetric and interleaved modes. +It represents the internal queuing, buffering and transmission delays +for the preceding packet. +.Pp +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic flags +peer flags (see Autokey specification) +.It Ic host +Autokey server name +.It Ic flags +peer flags (see Autokey specification) +.It Ic signature +OpenSSL digest/signature scheme +.It Ic initsequence +initial key ID +.It Ic initkey +initial key index +.It Ic timestamp +Autokey signature timestamp +.El + +.Ss Clock Variables +The following clock variables appear in the +.Ic cv +billboard for each association with a reference clock. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic associd +association ID +.It Ic status +.Lk decode.html#clock "clock status word" +.It Ic device +device description +.It Ic timecode +ASCII time code string (specific to device) +.It Ic poll +poll messages sent +.It Ic noreply +no reply +.It Ic badformat +bad format +.It Ic baddata +bad date or time +.It Ic fudgetime1 +fudge time 1 +.It Ic fudgetime2 +fudge time 2 +.It Ic stratum +driver stratum +.It Ic refid +driver reference ID +.It Ic flags +driver flags +.El + _END_PROG_MDOC_DESCRIP; +}; diff --git a/contrib/ntp/ntpq/ntpq-opts.h b/contrib/ntp/ntpq/ntpq-opts.h index 2badce790..f82ccae8a 100644 --- a/contrib/ntp/ntpq/ntpq-opts.h +++ b/contrib/ntp/ntpq/ntpq-opts.h @@ -1,98 +1,140 @@ -/* +/* * EDIT THIS FILE WITH CAUTION (ntpq-opts.h) - * - * It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:26 AM EST + * + * It has been AutoGen-ed October 21, 2015 at 12:39:00 PM by AutoGen 5.18.5 * From the definitions ntpq-opts.def * and the template file options * - * Generated from AutoOpts 29:0:4 templates. - */ - -/* - * This file was produced by an AutoOpts template. AutoOpts is a - * copyrighted work. This header file is not encumbered by AutoOpts - * licensing, but is provided under the licensing terms chosen by the - * ntpq author or copyright holder. AutoOpts is licensed under - * the terms of the LGPL. The redistributable library (``libopts'') is - * licensed under the terms of either the LGPL or, at the users discretion, - * the BSD license. See the AutoOpts and/or libopts sources for details. + * Generated from AutoOpts 41:0:16 templates. + * + * AutoOpts is a copyrighted work. This header file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpq author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. * - * This source file is copyrighted and licensed under the following terms: + * The ntpq program is copyrighted and licensed + * under the following terms: * - * ntpq copyright 1970-2009 David L. Mills and/or others - all rights reserved + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * * - * see html/copyright.html + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. */ -/* +/** * This file contains the programmatic interface to the Automated * Options generated for the ntpq program. * These macros are documented in the AutoGen info file in the * "AutoOpts" chapter. Please refer to that doc for usage help. */ #ifndef AUTOOPTS_NTPQ_OPTS_H_GUARD -#define AUTOOPTS_NTPQ_OPTS_H_GUARD +#define AUTOOPTS_NTPQ_OPTS_H_GUARD 1 #include "config.h" #include -/* +/** * Ensure that the library used for compiling this generated header is at * least as new as the version current when the header template was released * (not counting patch version increments). Also ensure that the oldest * tolerable version is at least as old as what was current when the header * template was released. */ -#define AO_TEMPLATE_VERSION 118784 +#define AO_TEMPLATE_VERSION 167936 #if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) # error option template version mismatches autoopts/options.h header Choke Me. #endif -/* - * Enumeration of each option: +/** + * Enumeration of each option type for ntpq */ typedef enum { - INDEX_OPT_IPV4 = 0, - INDEX_OPT_IPV6 = 1, - INDEX_OPT_COMMAND = 2, - INDEX_OPT_DEBUG_LEVEL = 3, - INDEX_OPT_SET_DEBUG_LEVEL = 4, - INDEX_OPT_PEERS = 5, - INDEX_OPT_INTERACTIVE = 6, - INDEX_OPT_NUMERIC = 7, - INDEX_OPT_VERSION = 8, - INDEX_OPT_HELP = 9, - INDEX_OPT_MORE_HELP = 10, - INDEX_OPT_SAVE_OPTS = 11, - INDEX_OPT_LOAD_OPTS = 12 + INDEX_OPT_IPV4 = 0, + INDEX_OPT_IPV6 = 1, + INDEX_OPT_COMMAND = 2, + INDEX_OPT_DEBUG_LEVEL = 3, + INDEX_OPT_SET_DEBUG_LEVEL = 4, + INDEX_OPT_INTERACTIVE = 5, + INDEX_OPT_NUMERIC = 6, + INDEX_OPT_OLD_RV = 7, + INDEX_OPT_PEERS = 8, + INDEX_OPT_WIDE = 9, + INDEX_OPT_VERSION = 10, + INDEX_OPT_HELP = 11, + INDEX_OPT_MORE_HELP = 12, + INDEX_OPT_SAVE_OPTS = 13, + INDEX_OPT_LOAD_OPTS = 14 } teOptIndex; +/** count of all options for ntpq */ +#define OPTION_CT 15 +/** ntpq version */ +#define NTPQ_VERSION "4.2.8p4" +/** Full ntpq version text */ +#define NTPQ_FULL_VERSION "ntpq 4.2.8p4" -#define OPTION_CT 13 -#define NTPQ_VERSION "4.2.4p8" -#define NTPQ_FULL_VERSION "ntpq - standard NTP query program - Ver. 4.2.4p8" - -/* +/** * Interface defines for all options. Replace "n" with the UPPER_CASED * option name (as in the teOptIndex enumeration above). - * e.g. HAVE_OPT( IPV4 ) + * e.g. HAVE_OPT(IPV4) */ #define DESC(n) (ntpqOptions.pOptDesc[INDEX_OPT_## n]) +/** 'true' if an option has been specified in any way */ #define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) +/** The string argument to an option. The argument type must be \"string\". */ #define OPT_ARG(n) (DESC(n).optArg.argString) +/** Mask the option state revealing how an option was specified. + * It will be one and only one of \a OPTST_SET, \a OPTST_PRESET, + * \a OPTST_DEFINED, \a OPTST_RESET or zero. + */ #define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) +/** Count of option's occurrances *on the command line*. */ #define COUNT_OPT(n) (DESC(n).optOccCt) +/** mask of \a OPTST_SET and \a OPTST_DEFINED. */ #define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) +/** 'true' if \a HAVE_OPT would yield 'false'. */ #define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) +/** 'true' if OPTST_DISABLED bit not set. */ #define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) +/** number of stacked option arguments. + * Valid only for stacked option arguments. */ #define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) +/** stacked argument vector. + * Valid only for stacked option arguments. */ #define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) +/** Reset an option. */ #define CLEAR_OPT(n) STMTS( \ DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ - if ( (DESC(n).fOptState & OPTST_INITENABLED) == 0) \ + if ((DESC(n).fOptState & OPTST_INITENABLED) == 0) \ DESC(n).fOptState |= OPTST_DISABLED; \ DESC(n).optCookie = NULL ) - -/* +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Enumeration of ntpq exit codes + */ +typedef enum { + NTPQ_EXIT_SUCCESS = 0, + NTPQ_EXIT_FAILURE = 1, + NTPQ_EXIT_USAGE_ERROR = 64, + NTPQ_EXIT_NO_CONFIG_INPUT = 66, + NTPQ_EXIT_LIBOPTS_FAILURE = 70 +} ntpq_exit_code_t; +/** @} */ +/** * Make sure there are no #define name conflicts with the option names */ #ifndef NO_OPTION_NAME_WARNINGS @@ -116,10 +158,6 @@ typedef enum { # warning undefining SET_DEBUG_LEVEL due to option name conflict # undef SET_DEBUG_LEVEL # endif -# ifdef PEERS -# warning undefining PEERS due to option name conflict -# undef PEERS -# endif # ifdef INTERACTIVE # warning undefining INTERACTIVE due to option name conflict # undef INTERACTIVE @@ -128,81 +166,129 @@ typedef enum { # warning undefining NUMERIC due to option name conflict # undef NUMERIC # endif +# ifdef OLD_RV +# warning undefining OLD_RV due to option name conflict +# undef OLD_RV +# endif +# ifdef PEERS +# warning undefining PEERS due to option name conflict +# undef PEERS +# endif +# ifdef WIDE +# warning undefining WIDE due to option name conflict +# undef WIDE +# endif #else /* NO_OPTION_NAME_WARNINGS */ # undef IPV4 # undef IPV6 # undef COMMAND # undef DEBUG_LEVEL # undef SET_DEBUG_LEVEL -# undef PEERS # undef INTERACTIVE # undef NUMERIC +# undef OLD_RV +# undef PEERS +# undef WIDE #endif /* NO_OPTION_NAME_WARNINGS */ -/* +/** * Interface defines for specific options. + * @{ */ #define VALUE_OPT_IPV4 '4' -#define WHICH_OPT_IPV4 (DESC(IPV4).optActualValue) -#define WHICH_IDX_IPV4 (DESC(IPV4).optActualIndex) #define VALUE_OPT_IPV6 '6' #define VALUE_OPT_COMMAND 'c' -#ifdef DEBUG #define VALUE_OPT_DEBUG_LEVEL 'd' -#endif /* DEBUG */ -#ifdef DEBUG #define VALUE_OPT_SET_DEBUG_LEVEL 'D' -#endif /* DEBUG */ -#define VALUE_OPT_PEERS 'p' + +#define OPT_VALUE_SET_DEBUG_LEVEL (DESC(SET_DEBUG_LEVEL).optArg.argInt) #define VALUE_OPT_INTERACTIVE 'i' #define VALUE_OPT_NUMERIC 'n' - -#define VALUE_OPT_VERSION 'v' +#define VALUE_OPT_OLD_RV 0x1001 +#define VALUE_OPT_PEERS 'p' +#define VALUE_OPT_WIDE 'w' +/** option flag (value) for help-value option */ #define VALUE_OPT_HELP '?' +/** option flag (value) for more-help-value option */ #define VALUE_OPT_MORE_HELP '!' +/** option flag (value) for version-value option */ +#define VALUE_OPT_VERSION 0x1002 +/** option flag (value) for save-opts-value option */ #define VALUE_OPT_SAVE_OPTS '>' +/** option flag (value) for load-opts-value option */ #define VALUE_OPT_LOAD_OPTS '<' #define SET_OPT_SAVE_OPTS(a) STMTS( \ DESC(SAVE_OPTS).fOptState &= OPTST_PERSISTENT_MASK; \ DESC(SAVE_OPTS).fOptState |= OPTST_SET; \ - DESC(SAVE_OPTS).optArg.argString = (char const*)(a) ) + DESC(SAVE_OPTS).optArg.argString = (char const*)(a)) /* * Interface defines not associated with particular options */ -#define ERRSKIP_OPTERR STMTS( ntpqOptions.fOptSet &= ~OPTPROC_ERRSTOP ) -#define ERRSTOP_OPTERR STMTS( ntpqOptions.fOptSet |= OPTPROC_ERRSTOP ) +#define ERRSKIP_OPTERR STMTS(ntpqOptions.fOptSet &= ~OPTPROC_ERRSTOP) +#define ERRSTOP_OPTERR STMTS(ntpqOptions.fOptSet |= OPTPROC_ERRSTOP) #define RESTART_OPT(n) STMTS( \ ntpqOptions.curOptIdx = (n); \ ntpqOptions.pzCurOpt = NULL ) #define START_OPT RESTART_OPT(1) -#define USAGE(c) (*ntpqOptions.pUsageProc)( &ntpqOptions, c ) -/* extracted from /usr/local/gnu/autogen-5.9.1/share/autogen/opthead.tpl near line 360 */ +#define USAGE(c) (*ntpqOptions.pUsageProc)(&ntpqOptions, c) + +#ifdef __cplusplus +extern "C" { +#endif + /* * * * * * * * Declare the ntpq option descriptor. */ -#ifdef __cplusplus -extern "C" { -#endif +extern tOptions ntpqOptions; -extern tOptions ntpqOptions; - -#ifndef _ -# if ENABLE_NLS -# include - static inline char* aoGetsText( char const* pz ) { - if (pz == NULL) return NULL; - return (char*)gettext( pz ); - } -# define _(s) aoGetsText(s) -# else /* ENABLE_NLS */ -# define _(s) s -# endif /* ENABLE_NLS */ -#endif +#if defined(ENABLE_NLS) +# ifndef _ +# include +# ifndef HAVE_GETTEXT + extern char * gettext(char const *); +# else +# include +# endif + +# ifndef ATTRIBUTE_FORMAT_ARG +# define ATTRIBUTE_FORMAT_ARG(_a) +# endif + +static inline char* aoGetsText(char const* pz) ATTRIBUTE_FORMAT_ARG(1); +static inline char* aoGetsText(char const* pz) { + if (pz == NULL) return NULL; + return (char*)gettext(pz); +} +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpqOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpqOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpqOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpqOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ #ifdef __cplusplus } #endif #endif /* AUTOOPTS_NTPQ_OPTS_H_GUARD */ + /* ntpq-opts.h ends here */ diff --git a/contrib/ntp/ntpq/ntpq-opts.texi b/contrib/ntp/ntpq/ntpq-opts.texi deleted file mode 100644 index a0618cead..000000000 --- a/contrib/ntp/ntpq/ntpq-opts.texi +++ /dev/null @@ -1,219 +0,0 @@ -@node ntpq Invocation -@section Invoking ntpq -@pindex ntpq -@cindex standard NTP query program -@ignore -# -# EDIT THIS FILE WITH CAUTION (ntpq-opts.texi) -# -# It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:28 AM EST -# From the definitions ntpq-opts.def -# and the template file aginfo.tpl -@end ignore -This program has no explanation. - -The -[= prog-name =] -utility program is used to query NTP servers which -implement the standard NTP mode 6 control message formats defined -in Appendix B of the NTPv3 specification RFC1305, requesting -information about current state and/or changes in that state. -The same formats are used in NTPv4, although some of the -variables have changed and new ones added. - -This section was generated by @strong{AutoGen}, -the aginfo template and the option descriptions for the @command{ntpq} program. It documents the ntpq usage text and option meanings. - -This software is released under a specialized copyright license. - -@menu -* ntpq usage:: ntpq usage help (-?) -* ntpq command:: command option (-c) -* ntpq debug-level:: debug-level option (-d) -* ntpq interactive:: interactive option (-i) -* ntpq ipv4:: ipv4 option (-4) -* ntpq ipv6:: ipv6 option (-6) -* ntpq numeric:: numeric option (-n) -* ntpq peers:: peers option (-p) -* ntpq set-debug-level:: set-debug-level option (-D) -@end menu - -@node ntpq usage -@subsection ntpq usage help (-?) -@cindex ntpq usage - -This is the automatically generated usage text for ntpq: - -@exampleindent 0 -@example -ntpq - standard NTP query program - Ver. 4.2.5p247-RC -USAGE: ntpq [ - [] | --[@{=| @}] ]... [ host ...] - Flg Arg Option-Name Description - -4 no ipv4 Force IPv4 DNS name resolution - - prohibits these options: - ipv6 - -6 no ipv6 Force IPv6 DNS name resolution - - prohibits these options: - ipv4 - -c Str command run a command and exit - - may appear multiple times - -d no debug-level Increase output debug message level - - may appear multiple times - -D Str set-debug-level Set the output debug message level - - may appear multiple times - -p no peers Print a list of the peers - - prohibits these options: - interactive - -i no interactive Force ntpq to operate in interactive mode - - prohibits these options: - command - peers - -n no numeric numeric host addresses - no old-rv Always output status line with readvar - opt version Output version information and exit - -? no help Display extended usage information and exit - -! no more-help Extended usage information passed thru pager - -> opt save-opts Save the option state to a config file - -< Str load-opts Load options from a config file - - disabled as --no-load-opts - - may appear multiple times - -Options are specified by doubled hyphens and their name -or by a single hyphen and the flag character. - -The following option preset mechanisms are supported: - - reading file /users/stenn/.ntprc - - reading file /deacon/backroom/snaps/ntp-stable/ntpq/.ntprc - - examining environment variables named NTPQ_* - -The -[= prog-name =] -utility program is used to query NTP servers which -implement the standard NTP mode 6 control message formats defined -in Appendix B of the NTPv3 specification RFC1305, requesting -information about current state and/or changes in that state. -The same formats are used in NTPv4, although some of the -variables have changed and new ones added. - -please send bug reports to: http://bugs.ntp.org, bugs@@ntp.org -@end example -@exampleindent 4 - -@node ntpq ipv4 -@subsection ipv4 option (-4) -@cindex ntpq-ipv4 - -This is the ``force ipv4 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv4 namespace. - -@node ntpq ipv6 -@subsection ipv6 option (-6) -@cindex ntpq-ipv6 - -This is the ``force ipv6 dns name resolution'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -is a member of the ipv4 class of options. -@end itemize - -Force DNS resolution of following host names on the command line -to the IPv6 namespace. - -@node ntpq command -@subsection command option (-c) -@cindex ntpq-command - -This is the ``run a command and exit'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@end itemize - -The following argument is interpreted as an interactive format command -and is added to the list of commands to be executed on the specified -host(s). - -@node ntpq debug-level -@subsection debug-level option (-d) -@cindex ntpq-debug-level - -This is the ``increase output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Increase the debugging message output level. - -@node ntpq set-debug-level -@subsection set-debug-level option (-D) -@cindex ntpq-set-debug-level - -This is the ``set the output debug message level'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -may appear an unlimited number of times. -@item -must be compiled in by defining @code{DEBUG} during the compilation. -@end itemize - -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). - -@node ntpq peers -@subsection peers option (-p) -@cindex ntpq-peers - -This is the ``print a list of the peers'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -interactive. -@end itemize - -Print a list of the peers known to the server as well as a summary -of their state. This is equivalent to the 'peers' interactive command. - -@node ntpq interactive -@subsection interactive option (-i) -@cindex ntpq-interactive - -This is the ``force ntpq to operate in interactive mode'' option. - -This option has some usage constraints. It: -@itemize @bullet -@item -must not appear in combination with any of the following options: -command, peers. -@end itemize - -Force ntpq to operate in interactive mode. Prompts will be written -to the standard output and commands read from the standard input. - -@node ntpq numeric -@subsection numeric option (-n) -@cindex ntpq-numeric - -This is the ``numeric host addresses'' option. -Output all host addresses in dotted-quad numeric format rather than -converting to the canonical host names. diff --git a/contrib/ntp/ntpq/ntpq-subs.c b/contrib/ntp/ntpq/ntpq-subs.c index 07f25cece..78143b351 100644 --- a/contrib/ntp/ntpq/ntpq-subs.c +++ b/contrib/ntp/ntpq/ntpq-subs.c @@ -1,74 +1,91 @@ /* - * ntpq_ops.c - subroutines which are called to perform operations by ntpq + * ntpq-subs.c - subroutines which are called to perform ntpq commands. */ - +#include #include #include #include #include #include "ntpq.h" -#include "ntp_stdlib.h" +#include "ntpq-opts.h" -extern char * chosts[]; -extern char currenthost[]; -extern int numhosts; -int maxhostlen; +extern char currenthost[]; +extern int currenthostisnum; +size_t maxhostlen; /* * Declarations for command handlers in here */ -static int checkassocid P((u_int32)); -static char * strsave P((char *)); -static struct varlist *findlistvar P((struct varlist *, char *)); -static void doaddvlist P((struct varlist *, char *)); -static void dormvlist P((struct varlist *, char *)); -static void doclearvlist P((struct varlist *)); -static void makequerydata P((struct varlist *, int *, char *)); -static int doquerylist P((struct varlist *, int, int, int, u_short *, int *, char **)); -static void doprintvlist P((struct varlist *, FILE *)); -static void addvars P((struct parse *, FILE *)); -static void rmvars P((struct parse *, FILE *)); -static void clearvars P((struct parse *, FILE *)); -static void showvars P((struct parse *, FILE *)); -static int dolist P((struct varlist *, int, int, int, FILE *)); -static void readlist P((struct parse *, FILE *)); -static void writelist P((struct parse *, FILE *)); -static void readvar P((struct parse *, FILE *)); -static void writevar P((struct parse *, FILE *)); -static void clocklist P((struct parse *, FILE *)); -static void clockvar P((struct parse *, FILE *)); -static int findassidrange P((u_int32, u_int32, int *, int *)); -static void mreadlist P((struct parse *, FILE *)); -static void mreadvar P((struct parse *, FILE *)); -static int dogetassoc P((FILE *)); -static void printassoc P((int, FILE *)); -static void associations P((struct parse *, FILE *)); -static void lassociations P((struct parse *, FILE *)); -static void passociations P((struct parse *, FILE *)); -static void lpassociations P((struct parse *, FILE *)); +static associd_t checkassocid (u_int32); +static struct varlist *findlistvar (struct varlist *, char *); +static void doaddvlist (struct varlist *, const char *); +static void dormvlist (struct varlist *, const char *); +static void doclearvlist (struct varlist *); +static void makequerydata (struct varlist *, int *, char *); +static int doquerylist (struct varlist *, int, associd_t, int, + u_short *, int *, const char **); +static void doprintvlist (struct varlist *, FILE *); +static void addvars (struct parse *, FILE *); +static void rmvars (struct parse *, FILE *); +static void clearvars (struct parse *, FILE *); +static void showvars (struct parse *, FILE *); +static int dolist (struct varlist *, associd_t, int, int, + FILE *); +static void readlist (struct parse *, FILE *); +static void writelist (struct parse *, FILE *); +static void readvar (struct parse *, FILE *); +static void writevar (struct parse *, FILE *); +static void clocklist (struct parse *, FILE *); +static void clockvar (struct parse *, FILE *); +static int findassidrange (u_int32, u_int32, int *, int *, + FILE *); +static void mreadlist (struct parse *, FILE *); +static void mreadvar (struct parse *, FILE *); +static void printassoc (int, FILE *); +static void associations (struct parse *, FILE *); +static void lassociations (struct parse *, FILE *); +static void passociations (struct parse *, FILE *); +static void lpassociations (struct parse *, FILE *); #ifdef UNUSED -static void radiostatus P((struct parse *, FILE *)); +static void radiostatus (struct parse *, FILE *); #endif /* UNUSED */ -static void pstatus P((struct parse *, FILE *)); -static long when P((l_fp *, l_fp *, l_fp *)); -static char * prettyinterval P((char *, long)); -static int doprintpeers P((struct varlist *, int, int, int, char *, FILE *, int)); -static int dogetpeers P((struct varlist *, int, FILE *, int)); -static void dopeers P((int, FILE *, int)); -static void peers P((struct parse *, FILE *)); -static void lpeers P((struct parse *, FILE *)); -static void doopeers P((int, FILE *, int)); -static void opeers P((struct parse *, FILE *)); -static void lopeers P((struct parse *, FILE *)); - +static void authinfo (struct parse *, FILE *); +static void pstats (struct parse *, FILE *); +static long when (l_fp *, l_fp *, l_fp *); +static char * prettyinterval (char *, size_t, long); +static int doprintpeers (struct varlist *, int, int, int, const char *, FILE *, int); +static int dogetpeers (struct varlist *, associd_t, FILE *, int); +static void dopeers (int, FILE *, int); +static void peers (struct parse *, FILE *); +static void doapeers (int, FILE *, int); +static void apeers (struct parse *, FILE *); +static void lpeers (struct parse *, FILE *); +static void doopeers (int, FILE *, int); +static void opeers (struct parse *, FILE *); +static void lopeers (struct parse *, FILE *); +static void config (struct parse *, FILE *); +static void saveconfig (struct parse *, FILE *); +static void config_from_file(struct parse *, FILE *); +static void mrulist (struct parse *, FILE *); +static void ifstats (struct parse *, FILE *); +static void reslist (struct parse *, FILE *); +static void sysstats (struct parse *, FILE *); +static void sysinfo (struct parse *, FILE *); +static void kerninfo (struct parse *, FILE *); +static void monstats (struct parse *, FILE *); +static void iostats (struct parse *, FILE *); +static void timerstats (struct parse *, FILE *); /* * Commands we understand. Ntpdc imports this. */ struct xcmd opcmds[] = { + { "saveconfig", saveconfig, { NTP_STR, NO, NO, NO }, + { "filename", "", "", ""}, + "save ntpd configuration to file, . for current config file"}, { "associations", associations, { NO, NO, NO, NO }, { "", "", "", "" }, "print list of association ID's and statuses for the server's peers" }, @@ -102,26 +119,26 @@ struct xcmd opcmds[] = { { "writelist", writelist, { OPT|NTP_UINT, NO, NO, NO }, { "assocID", "", "", "" }, "write the system or peer variables included in the variable list" }, - { "readvar", readvar, { OPT|NTP_UINT, OPT|NTP_STR, NO, NO }, - { "assocID", "name=value[,...]", "", "" }, + { "readvar", readvar, { OPT|NTP_UINT, OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR, }, + { "assocID", "varname1", "varname2", "varname3" }, "read system or peer variables" }, - { "rv", readvar, { OPT|NTP_UINT, OPT|NTP_STR, NO, NO }, - { "assocID", "name=value[,...]", "", "" }, + { "rv", readvar, { OPT|NTP_UINT, OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR, }, + { "assocID", "varname1", "varname2", "varname3" }, "read system or peer variables" }, { "writevar", writevar, { NTP_UINT, NTP_STR, NO, NO }, { "assocID", "name=value,[...]", "", "" }, "write system or peer variables" }, { "mreadlist", mreadlist, { NTP_UINT, NTP_UINT, NO, NO }, - { "assocID", "assocID", "", "" }, + { "assocIDlow", "assocIDhigh", "", "" }, "read the peer variables in the variable list for multiple peers" }, { "mrl", mreadlist, { NTP_UINT, NTP_UINT, NO, NO }, - { "assocID", "assocID", "", "" }, + { "assocIDlow", "assocIDhigh", "", "" }, "read the peer variables in the variable list for multiple peers" }, { "mreadvar", mreadvar, { NTP_UINT, NTP_UINT, OPT|NTP_STR, NO }, - { "assocID", "assocID", "name=value[,...]", "" }, + { "assocIDlow", "assocIDhigh", "name=value[,...]", "" }, "read peer variables from multiple peers" }, { "mrv", mreadvar, { NTP_UINT, NTP_UINT, OPT|NTP_STR, NO }, - { "assocID", "assocID", "name=value[,...]", "" }, + { "assocIDlow", "assocIDhigh", "name=value[,...]", "" }, "read peer variables from multiple peers" }, { "clocklist", clocklist, { OPT|NTP_UINT, NO, NO, NO }, { "assocID", "", "", "" }, @@ -135,12 +152,15 @@ struct xcmd opcmds[] = { { "cv", clockvar, { OPT|NTP_UINT, OPT|NTP_STR, NO, NO }, { "assocID", "name=value[,...]", "", "" }, "read clock variables" }, - { "pstatus", pstatus, { NTP_UINT, NO, NO, NO }, + { "pstats", pstats, { NTP_UINT, NO, NO, NO }, { "assocID", "", "", "" }, - "print status information returned for a peer" }, + "show statistics for a peer" }, { "peers", peers, { OPT|IP_VERSION, NO, NO, NO }, { "-4|-6", "", "", "" }, "obtain and print a list of the server's peers [IP version]" }, + { "apeers", apeers, { OPT|IP_VERSION, NO, NO, NO }, + { "-4|-6", "", "", "" }, + "obtain and print a list of the server's peers and their assocIDs [IP version]" }, { "lpeers", lpeers, { OPT|IP_VERSION, NO, NO, NO }, { "-4|-6", "", "", "" }, "obtain and print a list of all peers and clients [IP version]" }, @@ -150,6 +170,42 @@ struct xcmd opcmds[] = { { "lopeers", lopeers, { OPT|IP_VERSION, NO, NO, NO }, { "-4|-6", "", "", "" }, "obtain and print a list of all peers and clients showing dstadr [IP version]" }, + { ":config", config, { NTP_STR, NO, NO, NO }, + { "", "", "", "" }, + "send a remote configuration command to ntpd" }, + { "config-from-file", config_from_file, { NTP_STR, NO, NO, NO }, + { "", "", "", "" }, + "configure ntpd using the configuration filename" }, + { "mrulist", mrulist, { OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR, OPT|NTP_STR }, + { "tag=value", "tag=value", "tag=value", "tag=value" }, + "display the list of most recently seen source addresses, tags mincount=... resall=0x... resany=0x..." }, + { "ifstats", ifstats, { NO, NO, NO, NO }, + { "", "", "", "" }, + "show statistics for each local address ntpd is using" }, + { "reslist", reslist, { NO, NO, NO, NO }, + { "", "", "", "" }, + "show ntpd access control list" }, + { "sysinfo", sysinfo, { NO, NO, NO, NO }, + { "", "", "", "" }, + "display system summary" }, + { "kerninfo", kerninfo, { NO, NO, NO, NO }, + { "", "", "", "" }, + "display kernel loop and PPS statistics" }, + { "sysstats", sysstats, { NO, NO, NO, NO }, + { "", "", "", "" }, + "display system uptime and packet counts" }, + { "monstats", monstats, { NO, NO, NO, NO }, + { "", "", "", "" }, + "display monitor (mrulist) counters and limits" }, + { "authinfo", authinfo, { NO, NO, NO, NO }, + { "", "", "", "" }, + "display symmetric authentication counters" }, + { "iostats", iostats, { NO, NO, NO, NO }, + { "", "", "", "" }, + "display network input and output counters" }, + { "timerstats", timerstats, { NO, NO, NO, NO }, + { "", "", "", "" }, + "display interval timer counters" }, { 0, 0, { NO, NO, NO, NO }, { "-4|-6", "", "", "" }, "" } }; @@ -158,89 +214,203 @@ struct xcmd opcmds[] = { /* * Variable list data space */ -#define MAXLIST 64 /* maximum number of variables in list */ -#define LENHOSTNAME 256 /* host name is 256 characters long */ +#define MAXLINE 512 /* maximum length of a line */ +#define MAXLIST 128 /* maximum variables in list */ +#define LENHOSTNAME 256 /* host name limit */ + +#define MRU_GOT_COUNT 0x1 +#define MRU_GOT_LAST 0x2 +#define MRU_GOT_FIRST 0x4 +#define MRU_GOT_MV 0x8 +#define MRU_GOT_RS 0x10 +#define MRU_GOT_ADDR 0x20 +#define MRU_GOT_ALL (MRU_GOT_COUNT | MRU_GOT_LAST | MRU_GOT_FIRST \ + | MRU_GOT_MV | MRU_GOT_RS | MRU_GOT_ADDR) + +/* + * mrulist() depends on MRUSORT_DEF and MRUSORT_RDEF being the first two + */ +typedef enum mru_sort_order_tag { + MRUSORT_DEF = 0, /* lstint ascending */ + MRUSORT_R_DEF, /* lstint descending */ + MRUSORT_AVGINT, /* avgint ascending */ + MRUSORT_R_AVGINT, /* avgint descending */ + MRUSORT_ADDR, /* IPv4 asc. then IPv6 asc. */ + MRUSORT_R_ADDR, /* IPv6 desc. then IPv4 desc. */ + MRUSORT_COUNT, /* hit count ascending */ + MRUSORT_R_COUNT, /* hit count descending */ + MRUSORT_MAX, /* special: count of this enum */ +} mru_sort_order; + +const char * const mru_sort_keywords[MRUSORT_MAX] = { + "lstint", /* MRUSORT_DEF */ + "-lstint", /* MRUSORT_R_DEF */ + "avgint", /* MRUSORT_AVGINT */ + "-avgint", /* MRUSORT_R_AVGINT */ + "addr", /* MRUSORT_ADDR */ + "-addr", /* MRUSORT_R_ADDR */ + "count", /* MRUSORT_COUNT */ + "-count", /* MRUSORT_R_COUNT */ +}; + +typedef int (*qsort_cmp)(const void *, const void *); + /* * Old CTL_PST defines for version 2. */ -#define OLD_CTL_PST_CONFIG 0x80 +#define OLD_CTL_PST_CONFIG 0x80 #define OLD_CTL_PST_AUTHENABLE 0x40 #define OLD_CTL_PST_AUTHENTIC 0x20 -#define OLD_CTL_PST_REACH 0x10 -#define OLD_CTL_PST_SANE 0x08 -#define OLD_CTL_PST_DISP 0x04 +#define OLD_CTL_PST_REACH 0x10 +#define OLD_CTL_PST_SANE 0x08 +#define OLD_CTL_PST_DISP 0x04 + #define OLD_CTL_PST_SEL_REJECT 0 #define OLD_CTL_PST_SEL_SELCAND 1 #define OLD_CTL_PST_SEL_SYNCCAND 2 #define OLD_CTL_PST_SEL_SYSPEER 3 - char flash2[] = " .+* "; /* flash decode for version 2 */ char flash3[] = " x.-+#*o"; /* flash decode for peer status version 3 */ struct varlist { - char *name; + const char *name; char *value; -} varlist[MAXLIST] = { { 0, 0 } }; +} g_varlist[MAXLIST] = { { 0, 0 } }; /* * Imported from ntpq.c */ extern int showhostnames; +extern int wideremote; extern int rawmode; extern struct servent *server_entry; -extern struct association assoc_cache[]; -extern int numassoc; +extern struct association *assoc_cache; extern u_char pktversion; -extern struct ctl_var peer_var[]; + +typedef struct mru_tag mru; +struct mru_tag { + mru * hlink; /* next in hash table bucket */ + DECL_DLIST_LINK(mru, mlink); + int count; + l_fp last; + l_fp first; + u_char mode; + u_char ver; + u_short rs; + sockaddr_u addr; +}; + +typedef struct ifstats_row_tag { + u_int ifnum; + sockaddr_u addr; + sockaddr_u bcast; + int enabled; + u_int flags; + int mcast_count; + char name[32]; + int peer_count; + int received; + int sent; + int send_errors; + u_int ttl; + u_int uptime; +} ifstats_row; + +typedef struct reslist_row_tag { + u_int idx; + sockaddr_u addr; + sockaddr_u mask; + u_long hits; + char flagstr[128]; +} reslist_row; + +typedef struct var_display_collection_tag { + const char * const tag; /* system variable */ + const char * const display; /* descriptive text */ + u_char type; /* NTP_STR, etc */ + union { + char * str; + sockaddr_u sau; /* NTP_ADD */ + l_fp lfp; /* NTP_LFP */ + } v; /* retrieved value */ +} vdc; +#if !defined(MISSING_C99_STRUCT_INIT) +# define VDC_INIT(a, b, c) { .tag = a, .display = b, .type = c } +#else +# define VDC_INIT(a, b, c) { a, b, c } +#endif +/* + * other local function prototypes + */ +void mrulist_ctrl_c_hook(void); +static mru * add_mru(mru *); +static int collect_mru_list(const char *, l_fp *); +static int fetch_nonce(char *, size_t); +static int qcmp_mru_avgint(const void *, const void *); +static int qcmp_mru_r_avgint(const void *, const void *); +static int qcmp_mru_addr(const void *, const void *); +static int qcmp_mru_r_addr(const void *, const void *); +static int qcmp_mru_count(const void *, const void *); +static int qcmp_mru_r_count(const void *, const void *); +static void validate_ifnum(FILE *, u_int, int *, ifstats_row *); +static void another_ifstats_field(int *, ifstats_row *, FILE *); +static void collect_display_vdc(associd_t as, vdc *table, + int decodestatus, FILE *fp); /* - * For quick string comparisons + * static globals */ -#define STREQ(a, b) (*(a) == *(b) && strcmp((a), (b)) == 0) +static u_int mru_count; +static u_int mru_dupes; +volatile int mrulist_interrupted; +static mru mru_list; /* listhead */ +static mru ** hash_table; +/* + * qsort comparison function table for mrulist(). The first two + * entries are NULL because they are handled without qsort(). + */ +static const qsort_cmp mru_qcmp_table[MRUSORT_MAX] = { + NULL, /* MRUSORT_DEF unused */ + NULL, /* MRUSORT_R_DEF unused */ + &qcmp_mru_avgint, /* MRUSORT_AVGINT */ + &qcmp_mru_r_avgint, /* MRUSORT_R_AVGINT */ + &qcmp_mru_addr, /* MRUSORT_ADDR */ + &qcmp_mru_r_addr, /* MRUSORT_R_ADDR */ + &qcmp_mru_count, /* MRUSORT_COUNT */ + &qcmp_mru_r_count, /* MRUSORT_R_COUNT */ +}; /* * checkassocid - return the association ID, checking to see if it is valid */ -static int +static associd_t checkassocid( u_int32 value ) { - if (value == 0 || value >= 65536) { - (void) fprintf(stderr, "***Invalid association ID specified\n"); + associd_t associd; + u_long ulvalue; + + associd = (associd_t)value; + if (0 == associd || value != associd) { + ulvalue = value; + fprintf(stderr, + "***Invalid association ID %lu specified\n", + ulvalue); return 0; } - return (int)value; -} - - -/* - * strsave - save a string - * XXX - should be in libntp.a - */ -static char * -strsave( - char *str - ) -{ - char *cp; - u_int len; - - len = strlen(str) + 1; - if ((cp = (char *)malloc(len)) == NULL) { - (void) fprintf(stderr, "Malloc failed!!\n"); - exit(1); - } - memmove(cp, str, len); - return (cp); + return associd; } /* - * findlistvar - look for the named variable in a list and return if found + * findlistvar - Look for the named variable in a varlist. If found, + * return a pointer to it. Otherwise, if the list has + * slots available, return the pointer to the first free + * slot, or NULL if it's full. */ static struct varlist * findlistvar( @@ -248,14 +418,15 @@ findlistvar( char *name ) { - register struct varlist *vl; + struct varlist *vl; - for (vl = list; vl < list + MAXLIST && vl->name != 0; vl++) - if (STREQ(name, vl->name)) - return vl; + for (vl = list; vl < list + MAXLIST && vl->name != NULL; vl++) + if (!strcmp(name, vl->name)) + return vl; if (vl < list + MAXLIST) return vl; - return (struct varlist *)0; + + return NULL; } @@ -265,10 +436,10 @@ findlistvar( static void doaddvlist( struct varlist *vlist, - char *vars + const char *vars ) { - register struct varlist *vl; + struct varlist *vl; int len; char *name; char *value; @@ -276,20 +447,20 @@ doaddvlist( len = strlen(vars); while (nextvar(&len, &vars, &name, &value)) { vl = findlistvar(vlist, name); - if (vl == 0) { - (void) fprintf(stderr, "Variable list full\n"); + if (NULL == vl) { + fprintf(stderr, "Variable list full\n"); return; } - if (vl->name == 0) { - vl->name = strsave(name); - } else if (vl->value != 0) { + if (NULL == vl->name) { + vl->name = estrdup(name); + } else if (vl->value != NULL) { free(vl->value); - vl->value = 0; + vl->value = NULL; } - if (value != 0) - vl->value = strsave(value); + if (value != NULL) + vl->value = estrdup(value); } } @@ -300,10 +471,10 @@ doaddvlist( static void dormvlist( struct varlist *vlist, - char *vars + const char *vars ) { - register struct varlist *vl; + struct varlist *vl; int len; char *name; char *value; @@ -315,10 +486,10 @@ dormvlist( (void) fprintf(stderr, "Variable `%s' not found\n", name); } else { - free((void *)vl->name); + free((void *)(intptr_t)vl->name); if (vl->value != 0) free(vl->value); - for ( ; (vl+1) < (varlist+MAXLIST) + for ( ; (vl+1) < (g_varlist + MAXLIST) && (vl+1)->name != 0; vl++) { vl->name = (vl+1)->name; vl->value = (vl+1)->value; @@ -340,7 +511,7 @@ doclearvlist( register struct varlist *vl; for (vl = vlist; vl < vlist + MAXLIST && vl->name != 0; vl++) { - free((void *)vl->name); + free((void *)(intptr_t)vl->name); vl->name = 0; if (vl->value != 0) { free(vl->value); @@ -375,16 +546,20 @@ makequerydata( else valuelen = strlen(vl->value); totallen = namelen + valuelen + (valuelen != 0) + (cp != data); - if (cp + totallen > cpend) - break; + if (cp + totallen > cpend) { + fprintf(stderr, + "***Ignoring variables starting with `%s'\n", + vl->name); + break; + } if (cp != data) *cp++ = ','; - memmove(cp, vl->name, (unsigned)namelen); + memcpy(cp, vl->name, (size_t)namelen); cp += namelen; if (valuelen != 0) { *cp++ = '='; - memmove(cp, vl->value, (unsigned)valuelen); + memcpy(cp, vl->value, (size_t)valuelen); cp += valuelen; } } @@ -399,11 +574,11 @@ static int doquerylist( struct varlist *vlist, int op, - int associd, + associd_t associd, int auth, u_short *rstatus, int *dsize, - char **datap + const char **datap ) { char data[CTL_MAX_DATA_LEN]; @@ -412,8 +587,8 @@ doquerylist( datalen = sizeof(data); makequerydata(vlist, &datalen, data); - return doquery(op, associd, auth, datalen, data, rstatus, - dsize, datap); + return doquery(op, associd, auth, datalen, data, rstatus, dsize, + datap); } @@ -426,23 +601,21 @@ doprintvlist( FILE *fp ) { - register struct varlist *vl; + size_t n; - if (vlist->name == 0) { - (void) fprintf(fp, "No variables on list\n"); - } else { - for (vl = vlist; vl < vlist + MAXLIST && vl->name != 0; vl++) { - if (vl->value == 0) { - (void) fprintf(fp, "%s\n", vl->name); - } else { - (void) fprintf(fp, "%s=%s\n", - vl->name, vl->value); - } - } + if (NULL == vlist->name) { + fprintf(fp, "No variables on list\n"); + return; + } + for (n = 0; n < MAXLIST && vlist[n].name != NULL; n++) { + if (NULL == vlist[n].value) + fprintf(fp, "%s\n", vlist[n].name); + else + fprintf(fp, "%s=%s\n", vlist[n].name, + vlist[n].value); } } - /* * addvars - add variables to the variable list */ @@ -453,7 +626,7 @@ addvars( FILE *fp ) { - doaddvlist(varlist, pcmd->argval[0].string); + doaddvlist(g_varlist, pcmd->argval[0].string); } @@ -467,7 +640,7 @@ rmvars( FILE *fp ) { - dormvlist(varlist, pcmd->argval[0].string); + dormvlist(g_varlist, pcmd->argval[0].string); } @@ -481,7 +654,7 @@ clearvars( FILE *fp ) { - doclearvlist(varlist); + doclearvlist(g_varlist); } @@ -495,7 +668,7 @@ showvars( FILE *fp ) { - doprintvlist(varlist, fp); + doprintvlist(g_varlist, fp); } @@ -505,16 +678,26 @@ showvars( static int dolist( struct varlist *vlist, - int associd, + associd_t associd, int op, int type, FILE *fp ) { - char *datap; + const char *datap; int res; int dsize; u_short rstatus; + int quiet; + + /* + * if we're asking for specific variables don't include the + * status header line in the output. + */ + if (old_rv) + quiet = 0; + else + quiet = (vlist->name != NULL); res = doquerylist(vlist, op, associd, 0, &rstatus, &dsize, &datap); @@ -522,20 +705,22 @@ dolist( return 0; if (numhosts > 1) - (void) fprintf(fp, "server=%s ", currenthost); + fprintf(fp, "server=%s ", currenthost); if (dsize == 0) { if (associd == 0) - (void) fprintf(fp, "No system%s variables returned\n", - (type == TYPE_CLOCK) ? " clock" : ""); + fprintf(fp, "No system%s variables returned\n", + (type == TYPE_CLOCK) ? " clock" : ""); else - (void) fprintf(fp, - "No information returned for%s association %u\n", - (type == TYPE_CLOCK) ? " clock" : "", associd); + fprintf(fp, + "No information returned for%s association %u\n", + (type == TYPE_CLOCK) ? " clock" : "", + associd); return 1; } - (void) fprintf(fp,"assID=%d ",associd); - printvars(dsize, datap, (int)rstatus, type, fp); + if (!quiet) + fprintf(fp, "associd=%u ", associd); + printvars(dsize, datap, (int)rstatus, type, quiet, fp); return 1; } @@ -549,7 +734,8 @@ readlist( FILE *fp ) { - int associd; + associd_t associd; + int type; if (pcmd->nargs == 0) { associd = 0; @@ -561,8 +747,10 @@ readlist( return; } - (void) dolist(varlist, associd, CTL_OP_READVAR, - (associd == 0) ? TYPE_SYS : TYPE_PEER, fp); + type = (0 == associd) + ? TYPE_SYS + : TYPE_PEER; + dolist(g_varlist, associd, CTL_OP_READVAR, type, fp); } @@ -575,9 +763,9 @@ writelist( FILE *fp ) { - char *datap; + const char *datap; int res; - int associd; + associd_t associd; int dsize; u_short rstatus; @@ -591,7 +779,7 @@ writelist( return; } - res = doquerylist(varlist, CTL_OP_WRITEVAR, associd, 1, &rstatus, + res = doquerylist(g_varlist, CTL_OP_WRITEVAR, associd, 1, &rstatus, &dsize, &datap); if (res != 0) @@ -602,9 +790,9 @@ writelist( if (dsize == 0) (void) fprintf(fp, "done! (no data returned)\n"); else { - (void) fprintf(fp,"assID=%d ",associd); + (void) fprintf(fp,"associd=%u ", associd); printvars(dsize, datap, (int)rstatus, - (associd != 0) ? TYPE_PEER : TYPE_SYS, fp); + (associd != 0) ? TYPE_PEER : TYPE_SYS, 0, fp); } return; } @@ -619,8 +807,12 @@ readvar( FILE *fp ) { - int associd; - struct varlist tmplist[MAXLIST]; + associd_t associd; + u_int tmpcount; + u_int u; + int type; + struct varlist tmplist[MAXLIST]; + /* HMS: uval? */ if (pcmd->nargs == 0 || pcmd->argval[0].uval == 0) @@ -628,12 +820,17 @@ readvar( else if ((associd = checkassocid(pcmd->argval[0].uval)) == 0) return; - memset((char *)tmplist, 0, sizeof(tmplist)); - if (pcmd->nargs >= 2) - doaddvlist(tmplist, pcmd->argval[1].string); + ZERO(tmplist); + if (pcmd->nargs > 1) { + tmpcount = pcmd->nargs - 1; + for (u = 0; u < tmpcount; u++) + doaddvlist(tmplist, pcmd->argval[1 + u].string); + } - (void) dolist(tmplist, associd, CTL_OP_READVAR, - (associd == 0) ? TYPE_SYS : TYPE_PEER, fp); + type = (0 == associd) + ? TYPE_SYS + : TYPE_PEER; + dolist(tmplist, associd, CTL_OP_READVAR, type, fp); doclearvlist(tmplist); } @@ -648,9 +845,10 @@ writevar( FILE *fp ) { - char *datap; + const char *datap; int res; - int associd; + associd_t associd; + int type; int dsize; u_short rstatus; struct varlist tmplist[MAXLIST]; @@ -661,7 +859,7 @@ writevar( else if ((associd = checkassocid(pcmd->argval[0].uval)) == 0) return; - memset((char *)tmplist, 0, sizeof(tmplist)); + ZERO(tmplist); doaddvlist(tmplist, pcmd->argval[1].string); res = doquerylist(tmplist, CTL_OP_WRITEVAR, associd, 1, &rstatus, @@ -673,13 +871,15 @@ writevar( return; if (numhosts > 1) - (void) fprintf(fp, "server=%s ", currenthost); + fprintf(fp, "server=%s ", currenthost); if (dsize == 0) - (void) fprintf(fp, "done! (no data returned)\n"); + fprintf(fp, "done! (no data returned)\n"); else { - (void) fprintf(fp,"assID=%d ",associd); - printvars(dsize, datap, (int)rstatus, - (associd != 0) ? TYPE_PEER : TYPE_SYS, fp); + fprintf(fp,"associd=%u ", associd); + type = (0 == associd) + ? TYPE_SYS + : TYPE_PEER; + printvars(dsize, datap, (int)rstatus, type, 0, fp); } return; } @@ -694,7 +894,7 @@ clocklist( FILE *fp ) { - int associd; + associd_t associd; /* HMS: uval? */ if (pcmd->nargs == 0) { @@ -706,7 +906,7 @@ clocklist( return; } - (void) dolist(varlist, associd, CTL_OP_READCLOCK, TYPE_CLOCK, fp); + dolist(g_varlist, associd, CTL_OP_READCLOCK, TYPE_CLOCK, fp); } @@ -719,7 +919,7 @@ clockvar( FILE *fp ) { - int associd; + associd_t associd; struct varlist tmplist[MAXLIST]; /* HMS: uval? */ @@ -728,11 +928,11 @@ clockvar( else if ((associd = checkassocid(pcmd->argval[0].uval)) == 0) return; - memset((char *)tmplist, 0, sizeof(tmplist)); + ZERO(tmplist); if (pcmd->nargs >= 2) doaddvlist(tmplist, pcmd->argval[1].string); - (void) dolist(tmplist, associd, CTL_OP_READCLOCK, TYPE_CLOCK, fp); + dolist(tmplist, associd, CTL_OP_READCLOCK, TYPE_CLOCK, fp); doclearvlist(tmplist); } @@ -743,54 +943,49 @@ clockvar( */ static int findassidrange( - u_int32 assid1, - u_int32 assid2, - int *from, - int *to + u_int32 assid1, + u_int32 assid2, + int * from, + int * to, + FILE * fp ) { - register int i; - int f, t; - - if (assid1 == 0 || assid1 > 65535) { - (void) fprintf(stderr, - "***Invalid association ID %lu specified\n", (u_long)assid1); - return 0; - } + associd_t assids[2]; + int ind[COUNTOF(assids)]; + u_int i; + size_t a; - if (assid2 == 0 || assid2 > 65535) { - (void) fprintf(stderr, - "***Invalid association ID %lu specified\n", (u_long)assid2); - return 0; - } - f = t = -1; - for (i = 0; i < numassoc; i++) { - if (assoc_cache[i].assid == assid1) { - f = i; - if (t != -1) - break; - } - if (assoc_cache[i].assid == assid2) { - t = i; - if (f != -1) - break; - } - } + if (0 == numassoc) + dogetassoc(fp); - if (f == -1 || t == -1) { - (void) fprintf(stderr, - "***Association ID %lu not found in list\n", - (f == -1) ? (u_long)assid1 : (u_long)assid2); + assids[0] = checkassocid(assid1); + if (0 == assids[0]) return 0; + assids[1] = checkassocid(assid2); + if (0 == assids[1]) + return 0; + + for (a = 0; a < COUNTOF(assids); a++) { + ind[a] = -1; + for (i = 0; i < numassoc; i++) + if (assoc_cache[i].assid == assids[a]) + ind[a] = i; } + for (a = 0; a < COUNTOF(assids); a++) + if (-1 == ind[a]) { + fprintf(stderr, + "***Association ID %u not found in list\n", + assids[a]); + return 0; + } - if (f < t) { - *from = f; - *to = t; + if (ind[0] < ind[1]) { + *from = ind[0]; + *to = ind[1]; } else { - *from = t; - *to = f; + *to = ind[0]; + *from = ind[1]; } return 1; } @@ -810,16 +1005,15 @@ mreadlist( int from; int to; - /* HMS: uval? */ if (!findassidrange(pcmd->argval[0].uval, pcmd->argval[1].uval, - &from, &to)) + &from, &to, fp)) return; for (i = from; i <= to; i++) { if (i != from) - (void) fprintf(fp, "\n"); - if (!dolist(varlist, (int)assoc_cache[i].assid, - CTL_OP_READVAR, TYPE_PEER, fp)) + fprintf(fp, "\n"); + if (!dolist(g_varlist, assoc_cache[i].assid, + CTL_OP_READVAR, TYPE_PEER, fp)) return; } return; @@ -839,24 +1033,29 @@ mreadvar( int from; int to; struct varlist tmplist[MAXLIST]; + struct varlist *pvars; - /* HMS: uval? */ if (!findassidrange(pcmd->argval[0].uval, pcmd->argval[1].uval, - &from, &to)) + &from, &to, fp)) return; - memset((char *)tmplist, 0, sizeof(tmplist)); - if (pcmd->nargs >= 3) + ZERO(tmplist); + if (pcmd->nargs >= 3) { doaddvlist(tmplist, pcmd->argval[2].string); + pvars = tmplist; + } else { + pvars = g_varlist; + } for (i = from; i <= to; i++) { - if (i != from) - (void) fprintf(fp, "\n"); - if (!dolist(varlist, (int)assoc_cache[i].assid, - CTL_OP_READVAR, TYPE_PEER, fp)) + if (!dolist(pvars, assoc_cache[i].assid, CTL_OP_READVAR, + TYPE_PEER, fp)) break; } - doclearvlist(tmplist); + + if (pvars == tmplist) + doclearvlist(tmplist); + return; } @@ -864,12 +1063,13 @@ mreadvar( /* * dogetassoc - query the host for its list of associations */ -static int +int dogetassoc( FILE *fp ) { - char *datap; + const char *datap; + const u_short *pus; int res; int dsize; u_short rstatus; @@ -882,29 +1082,41 @@ dogetassoc( if (dsize == 0) { if (numhosts > 1) - (void) fprintf(fp, "server=%s ", currenthost); - (void) fprintf(fp, "No association ID's returned\n"); + fprintf(fp, "server=%s ", currenthost); + fprintf(fp, "No association ID's returned\n"); return 0; } if (dsize & 0x3) { if (numhosts > 1) - (void) fprintf(stderr, "server=%s ", currenthost); - (void) fprintf(stderr, - "***Server returned %d octets, should be multiple of 4\n", - dsize); + fprintf(stderr, "server=%s ", currenthost); + fprintf(stderr, + "***Server returned %d octets, should be multiple of 4\n", + dsize); return 0; } numassoc = 0; + while (dsize > 0) { - assoc_cache[numassoc].assid = ntohs(*((u_short *)datap)); - datap += sizeof(u_short); - assoc_cache[numassoc].status = ntohs(*((u_short *)datap)); - datap += sizeof(u_short); - if (++numassoc >= MAXASSOC) - break; - dsize -= sizeof(u_short) + sizeof(u_short); + if (numassoc >= assoc_cache_slots) { + grow_assoc_cache(); + } + pus = (const void *)datap; + assoc_cache[numassoc].assid = ntohs(*pus); + datap += sizeof(*pus); + pus = (const void *)datap; + assoc_cache[numassoc].status = ntohs(*pus); + datap += sizeof(*pus); + dsize -= 2 * sizeof(*pus); + if (debug) { + fprintf(stderr, "[%u] ", + assoc_cache[numassoc].assid); + } + numassoc++; + } + if (debug) { + fprintf(stderr, "\n%d associations total\n", numassoc); } sortassoc(); return 1; @@ -921,7 +1133,7 @@ printassoc( ) { register char *bp; - int i; + u_int i; u_char statval; int event; u_long event_count; @@ -930,7 +1142,6 @@ printassoc( const char *auth; const char *condition = ""; const char *last_event; - const char *cnt; char buf[128]; if (numassoc == 0) { @@ -942,7 +1153,7 @@ printassoc( * Output a header */ (void) fprintf(fp, - "\nind assID status conf reach auth condition last_event cnt\n"); + "\nind assid status conf reach auth condition last_event cnt\n"); (void) fprintf(fp, "===========================================================\n"); for (i = 0; i < numassoc; i++) { @@ -955,112 +1166,150 @@ printassoc( conf = "yes"; else conf = "no"; - if (statval & CTL_PST_REACH || 1) { - reach = "yes"; + if (statval & CTL_PST_BCAST) { + reach = "none"; + if (statval & CTL_PST_AUTHENABLE) + auth = "yes"; + else + auth = "none"; + } else { + if (statval & CTL_PST_REACH) + reach = "yes"; + else + reach = "no"; if (statval & CTL_PST_AUTHENABLE) { if (statval & CTL_PST_AUTHENTIC) auth = "ok "; else auth = "bad"; - } else + } else { auth = "none"; + } + } + if (pktversion > NTP_OLDVERSION) { + switch (statval & 0x7) { - if (pktversion > NTP_OLDVERSION) - switch (statval & 0x7) { - case CTL_PST_SEL_REJECT: - condition = "reject"; - break; - case CTL_PST_SEL_SANE: - condition = "falsetick"; - break; - case CTL_PST_SEL_CORRECT: - condition = "excess"; - break; - case CTL_PST_SEL_SELCAND: - condition = "outlyer"; - break; - case CTL_PST_SEL_SYNCCAND: - condition = "candidat"; - break; - case CTL_PST_SEL_DISTSYSPEER: - condition = "selected"; - break; - case CTL_PST_SEL_SYSPEER: - condition = "sys.peer"; - break; - case CTL_PST_SEL_PPS: - condition = "pps.peer"; - break; - } - else - switch (statval & 0x3) { - case OLD_CTL_PST_SEL_REJECT: - if (!(statval & OLD_CTL_PST_SANE)) + case CTL_PST_SEL_REJECT: + condition = "reject"; + break; + + case CTL_PST_SEL_SANE: + condition = "falsetick"; + break; + + case CTL_PST_SEL_CORRECT: + condition = "excess"; + break; + + case CTL_PST_SEL_SELCAND: + condition = "outlier"; + break; + + case CTL_PST_SEL_SYNCCAND: + condition = "candidate"; + break; + + case CTL_PST_SEL_EXCESS: + condition = "backup"; + break; + + case CTL_PST_SEL_SYSPEER: + condition = "sys.peer"; + break; + + case CTL_PST_SEL_PPS: + condition = "pps.peer"; + break; + } + } else { + switch (statval & 0x3) { + + case OLD_CTL_PST_SEL_REJECT: + if (!(statval & OLD_CTL_PST_SANE)) condition = "insane"; - else if (!(statval & OLD_CTL_PST_DISP)) + else if (!(statval & OLD_CTL_PST_DISP)) condition = "hi_disp"; - else + else condition = ""; - break; - case OLD_CTL_PST_SEL_SELCAND: - condition = "sel_cand"; - break; - case OLD_CTL_PST_SEL_SYNCCAND: - condition = "sync_cand"; - break; - case OLD_CTL_PST_SEL_SYSPEER: - condition = "sys_peer"; - break; - } + break; - } else { - reach = "no"; - auth = condition = ""; - } + case OLD_CTL_PST_SEL_SELCAND: + condition = "sel_cand"; + break; + case OLD_CTL_PST_SEL_SYNCCAND: + condition = "sync_cand"; + break; + + case OLD_CTL_PST_SEL_SYSPEER: + condition = "sys_peer"; + break; + } + } switch (PEER_EVENT|event) { - case EVNT_PEERIPERR: - last_event = "IP error"; - break; - case EVNT_PEERAUTH: - last_event = "auth fail"; + + case PEVNT_MOBIL: + last_event = "mobilize"; break; - case EVNT_UNREACH: - last_event = "lost reach"; + + case PEVNT_DEMOBIL: + last_event = "demobilize"; break; - case EVNT_REACH: + + case PEVNT_REACH: last_event = "reachable"; break; - case EVNT_PEERCLOCK: - last_event = "clock expt"; + + case PEVNT_UNREACH: + last_event = "unreachable"; break; -#if 0 - case EVNT_PEERSTRAT: - last_event = "stratum chg"; + + case PEVNT_RESTART: + last_event = "restart"; break; -#endif - default: + + case PEVNT_REPLY: + last_event = "no_reply"; + break; + + case PEVNT_RATE: + last_event = "rate_exceeded"; + break; + + case PEVNT_DENY: + last_event = "access_denied"; + break; + + case PEVNT_ARMED: + last_event = "leap_armed"; + break; + + case PEVNT_NEWPEER: + last_event = "sys_peer"; + break; + + case PEVNT_CLOCK: + last_event = "clock_alarm"; + break; + + default: last_event = ""; break; } - - if (event_count != 0) - cnt = uinttoa(event_count); - else - cnt = ""; - (void) sprintf(buf, - "%3d %5u %04x %3.3s %4s %4.4s %9.9s %11s %2s", - i+1, assoc_cache[i].assid, assoc_cache[i].status, - conf, reach, auth, condition, last_event, cnt); - bp = &buf[strlen(buf)]; - while (bp > buf && *(bp-1) == ' ') - *(--bp) = '\0'; - (void) fprintf(fp, "%s\n", buf); + snprintf(buf, sizeof(buf), + "%3d %5u %04x %3.3s %4s %4.4s %9.9s %11s %2lu", + i + 1, assoc_cache[i].assid, + assoc_cache[i].status, conf, reach, auth, + condition, last_event, event_count); + bp = buf + strlen(buf); + while (bp > buf && ' ' == bp[-1]) + --bp; + bp[0] = '\0'; + fprintf(fp, "%s\n", buf); } } - /* * associations - get, record and print a list of associations */ @@ -1119,59 +1368,55 @@ lpassociations( } -#ifdef UNUSED /* - * radiostatus - print the radio status returned by the server + * saveconfig - dump ntp server configuration to server file */ -/*ARGSUSED*/ static void -radiostatus( +saveconfig( struct parse *pcmd, FILE *fp ) { - char *datap; + const char *datap; int res; int dsize; u_short rstatus; - res = doquery(CTL_OP_READCLOCK, 0, 0, 0, (char *)0, &rstatus, - &dsize, &datap); - - if (res != 0) + if (0 == pcmd->nargs) return; + + res = doquery(CTL_OP_SAVECONFIG, 0, 1, + strlen(pcmd->argval[0].string), + pcmd->argval[0].string, &rstatus, &dsize, + &datap); - if (numhosts > 1) - (void) fprintf(fp, "server=%s ", currenthost); - if (dsize == 0) { - (void) fprintf(fp, "No radio status string returned\n"); + if (res != 0) return; - } - asciize(dsize, datap, fp); + if (0 == dsize) + fprintf(fp, "(no response message, curiously)"); + else + fprintf(fp, "%.*s", dsize, datap); } -#endif /* UNUSED */ + +#ifdef UNUSED /* - * pstatus - print peer status returned by the server + * radiostatus - print the radio status returned by the server */ +/*ARGSUSED*/ static void -pstatus( +radiostatus( struct parse *pcmd, FILE *fp ) { char *datap; int res; - int associd; int dsize; u_short rstatus; - /* HMS: uval? */ - if ((associd = checkassocid(pcmd->argval[0].uval)) == 0) - return; - - res = doquery(CTL_OP_READSTAT, associd, 0, 0, (char *)0, &rstatus, + res = doquery(CTL_OP_READCLOCK, 0, 0, 0, (char *)0, &rstatus, &dsize, &datap); if (res != 0) @@ -1180,16 +1425,13 @@ pstatus( if (numhosts > 1) (void) fprintf(fp, "server=%s ", currenthost); if (dsize == 0) { - (void) fprintf(fp, - "No information returned for association %u\n", - associd); + (void) fprintf(fp, "No radio status string returned\n"); return; } - (void) fprintf(fp,"assID=%d ",associd); - printvars(dsize, datap, (int)rstatus, TYPE_PEER, fp); + asciize(dsize, datap, fp); } - +#endif /* UNUSED */ /* * when - print how long its been since his last packet arrived @@ -1220,6 +1462,7 @@ when( static char * prettyinterval( char *buf, + size_t cb, long diff ) { @@ -1230,40 +1473,38 @@ prettyinterval( } if (diff <= 2048) { - (void) sprintf(buf, "%ld", (long int)diff); + snprintf(buf, cb, "%ld", diff); return buf; } diff = (diff + 29) / 60; if (diff <= 300) { - (void) sprintf(buf, "%ldm", (long int)diff); + snprintf(buf, cb, "%ldm", diff); return buf; } diff = (diff + 29) / 60; if (diff <= 96) { - (void) sprintf(buf, "%ldh", (long int)diff); + snprintf(buf, cb, "%ldh", diff); return buf; } diff = (diff + 11) / 24; - (void) sprintf(buf, "%ldd", (long int)diff); + snprintf(buf, cb, "%ldd", diff); return buf; } static char decodeaddrtype( - struct sockaddr_storage *sock + sockaddr_u *sock ) { char ch = '-'; u_int32 dummy; - struct sockaddr_in6 *sin6; - switch(sock->ss_family) { + switch(AF(sock)) { case AF_INET: - dummy = ((struct sockaddr_in *)sock)->sin_addr.s_addr; - dummy = ntohl(dummy); + dummy = SRCADR(sock); ch = (char)(((dummy&0xf0000000)==0xe0000000) ? 'm' : ((dummy&0x000000ff)==0x000000ff) ? 'b' : ((dummy&0xffffffff)==0x7f000001) ? 'l' : @@ -1271,8 +1512,7 @@ decodeaddrtype( 'u'); break; case AF_INET6: - sin6 = (struct sockaddr_in6 *)sock; - if (IN6_IS_ADDR_MULTICAST(&sin6->sin6_addr)) + if (IN6_IS_ADDR_MULTICAST(PSOCK_ADDR6(sock))) ch = 'm'; else ch = 'u'; @@ -1288,54 +1528,62 @@ decodeaddrtype( * A list of variables required by the peers command */ struct varlist opeervarlist[] = { - { "srcadr", 0 }, /* 0 */ - { "dstadr", 0 }, /* 1 */ - { "stratum", 0 }, /* 2 */ - { "hpoll", 0 }, /* 3 */ - { "ppoll", 0 }, /* 4 */ - { "reach", 0 }, /* 5 */ - { "delay", 0 }, /* 6 */ - { "offset", 0 }, /* 7 */ - { "jitter", 0 }, /* 8 */ - { "dispersion", 0 }, /* 9 */ - { "rec", 0 }, /* 10 */ - { "reftime", 0 }, /* 11 */ - { "srcport", 0 }, /* 12 */ + { "srcadr", 0 }, /* 0 */ + { "dstadr", 0 }, /* 1 */ + { "stratum", 0 }, /* 2 */ + { "hpoll", 0 }, /* 3 */ + { "ppoll", 0 }, /* 4 */ + { "reach", 0 }, /* 5 */ + { "delay", 0 }, /* 6 */ + { "offset", 0 }, /* 7 */ + { "jitter", 0 }, /* 8 */ + { "dispersion", 0 }, /* 9 */ + { "rec", 0 }, /* 10 */ + { "reftime", 0 }, /* 11 */ + { "srcport", 0 }, /* 12 */ + { "hmode", 0 }, /* 13 */ { 0, 0 } }; struct varlist peervarlist[] = { - { "srcadr", 0 }, /* 0 */ - { "refid", 0 }, /* 1 */ - { "stratum", 0 }, /* 2 */ - { "hpoll", 0 }, /* 3 */ - { "ppoll", 0 }, /* 4 */ - { "reach", 0 }, /* 5 */ - { "delay", 0 }, /* 6 */ - { "offset", 0 }, /* 7 */ - { "jitter", 0 }, /* 8 */ - { "dispersion", 0 }, /* 9 */ - { "rec", 0 }, /* 10 */ - { "reftime", 0 }, /* 11 */ - { "srcport", 0 }, /* 12 */ + { "srcadr", 0 }, /* 0 */ + { "refid", 0 }, /* 1 */ + { "stratum", 0 }, /* 2 */ + { "hpoll", 0 }, /* 3 */ + { "ppoll", 0 }, /* 4 */ + { "reach", 0 }, /* 5 */ + { "delay", 0 }, /* 6 */ + { "offset", 0 }, /* 7 */ + { "jitter", 0 }, /* 8 */ + { "dispersion", 0 }, /* 9 */ + { "rec", 0 }, /* 10 */ + { "reftime", 0 }, /* 11 */ + { "srcport", 0 }, /* 12 */ + { "hmode", 0 }, /* 13 */ + { "srchost", 0 }, /* 14 */ + { 0, 0 } +}; + +struct varlist apeervarlist[] = { + { "srcadr", 0 }, /* 0 */ + { "refid", 0 }, /* 1 */ + { "assid", 0 }, /* 2 */ + { "stratum", 0 }, /* 3 */ + { "hpoll", 0 }, /* 4 */ + { "ppoll", 0 }, /* 5 */ + { "reach", 0 }, /* 6 */ + { "delay", 0 }, /* 7 */ + { "offset", 0 }, /* 8 */ + { "jitter", 0 }, /* 9 */ + { "dispersion", 0 }, /* 10 */ + { "rec", 0 }, /* 11 */ + { "reftime", 0 }, /* 12 */ + { "srcport", 0 }, /* 13 */ + { "hmode", 0 }, /* 14 */ + { "srchost", 0 }, /* 15 */ { 0, 0 } }; -#define HAVE_SRCADR 0 -#define HAVE_DSTADR 1 -#define HAVE_REFID 1 -#define HAVE_STRATUM 2 -#define HAVE_HPOLL 3 -#define HAVE_PPOLL 4 -#define HAVE_REACH 5 -#define HAVE_DELAY 6 -#define HAVE_OFFSET 7 -#define HAVE_JITTER 8 -#define HAVE_DISPERSION 9 -#define HAVE_REC 10 -#define HAVE_REFTIME 11 -#define HAVE_SRCPORT 12 -#define MAXHAVE 13 /* * Decode an incoming data buffer and print a line in the peer list @@ -1346,20 +1594,29 @@ doprintpeers( int associd, int rstatus, int datalen, - char *data, + const char *data, FILE *fp, int af ) { char *name; char *value = NULL; - int i; int c; - - struct sockaddr_storage srcadr; - struct sockaddr_storage dstadr; + int len; + int have_srchost; + int have_dstadr; + int have_da_rid; + int have_jitter; + sockaddr_u srcadr; + sockaddr_u dstadr; + sockaddr_u dum_store; + sockaddr_u refidadr; + long hmode = 0; u_long srcport = 0; - char *dstadr_refid = "0.0.0.0"; + u_int32 u32; + const char *dstadr_refid = "0.0.0.0"; + const char *serverlocal; + size_t drlen; u_long stratum = 0; long ppoll = 0; long hpoll = 0; @@ -1371,180 +1628,244 @@ doprintpeers( l_fp reftime; l_fp rec; l_fp ts; - u_char havevar[MAXHAVE]; u_long poll_sec; char type = '?'; - char refid_string[10]; char whenbuf[8], pollbuf[8]; char clock_name[LENHOSTNAME]; - memset((char *)havevar, 0, sizeof(havevar)); get_systime(&ts); - memset((char *)&srcadr, 0, sizeof(struct sockaddr_storage)); - memset((char *)&dstadr, 0, sizeof(struct sockaddr_storage)); - - /* Initialize by zeroing out estimate variables */ - memset((char *)&estoffset, 0, sizeof(l_fp)); - memset((char *)&estdelay, 0, sizeof(l_fp)); - memset((char *)&estjitter, 0, sizeof(l_fp)); - memset((char *)&estdisp, 0, sizeof(l_fp)); + have_srchost = FALSE; + have_dstadr = FALSE; + have_da_rid = FALSE; + have_jitter = FALSE; + ZERO_SOCK(&srcadr); + ZERO_SOCK(&dstadr); + clock_name[0] = '\0'; + ZERO(estoffset); + ZERO(estdelay); + ZERO(estjitter); + ZERO(estdisp); while (nextvar(&datalen, &data, &name, &value)) { - struct sockaddr_storage dum_store; - - i = findvar(name, peer_var, 1); - if (i == 0) - continue; /* don't know this one */ - switch (i) { - case CP_SRCADR: - if (decodenetnum(value, &srcadr)) - havevar[HAVE_SRCADR] = 1; - break; - case CP_DSTADR: - if (decodenetnum(value, &dum_store)) + if (!strcmp("srcadr", name) || + !strcmp("peeradr", name)) { + if (!decodenetnum(value, &srcadr)) + fprintf(stderr, "malformed %s=%s\n", + name, value); + } else if (!strcmp("srchost", name)) { + if (pvl == peervarlist || pvl == apeervarlist) { + len = strlen(value); + if (2 < len && + (size_t)len < sizeof(clock_name)) { + /* strip quotes */ + value++; + len -= 2; + memcpy(clock_name, value, len); + clock_name[len] = '\0'; + have_srchost = TRUE; + } + } + } else if (!strcmp("dstadr", name)) { + if (decodenetnum(value, &dum_store)) { type = decodeaddrtype(&dum_store); - if (pvl == opeervarlist) { - if (decodenetnum(value, &dstadr)) { - havevar[HAVE_DSTADR] = 1; - dstadr_refid = stoa(&dstadr); + have_dstadr = TRUE; + dstadr = dum_store; + if (pvl == opeervarlist) { + have_da_rid = TRUE; + dstadr_refid = trunc_left(stoa(&dstadr), 15); } } - break; - case CP_REFID: + } else if (!strcmp("hmode", name)) { + decodeint(value, &hmode); + } else if (!strcmp("refid", name)) { if (pvl == peervarlist) { - havevar[HAVE_REFID] = 1; - if (*value == '\0') { - dstadr_refid = "0.0.0.0"; - } else if ((int)strlen(value) <= 4) { - refid_string[0] = '.'; - (void) strcpy(&refid_string[1], value); - i = strlen(refid_string); - refid_string[i] = '.'; - refid_string[i+1] = '\0'; - dstadr_refid = refid_string; - } else if (decodenetnum(value, &dstadr)) { - if (SOCKNUL(&dstadr)) + have_da_rid = TRUE; + drlen = strlen(value); + if (0 == drlen) { + dstadr_refid = ""; + } else if (drlen <= 4) { + ZERO(u32); + memcpy(&u32, value, drlen); + dstadr_refid = refid_str(u32, 1); + } else if (decodenetnum(value, &refidadr)) { + if (SOCK_UNSPEC(&refidadr)) dstadr_refid = "0.0.0.0"; - else if ((dstadr.ss_family == AF_INET) - && ISREFCLOCKADR(&dstadr)) - dstadr_refid = - refnumtoa(&dstadr); + else if (ISREFCLOCKADR(&refidadr)) + dstadr_refid = + refnumtoa(&refidadr); else dstadr_refid = - stoa(&dstadr); + stoa(&refidadr); } else { - havevar[HAVE_REFID] = 0; + have_da_rid = FALSE; + } + } else if (pvl == apeervarlist) { + have_da_rid = TRUE; + drlen = strlen(value); + if (0 == drlen) { + dstadr_refid = ""; + } else if (drlen <= 4) { + ZERO(u32); + memcpy(&u32, value, drlen); + dstadr_refid = refid_str(u32, 1); + //fprintf(stderr, "apeervarlist S1 refid: value=<%s>\n", value); + } else if (decodenetnum(value, &refidadr)) { + if (SOCK_UNSPEC(&refidadr)) + dstadr_refid = "0.0.0.0"; + else if (ISREFCLOCKADR(&refidadr)) + dstadr_refid = + refnumtoa(&refidadr); + else { + char *buf = emalloc(10); + int i = ntohl(refidadr.sa4.sin_addr.s_addr); + + snprintf(buf, 10, + "%0x", i); + dstadr_refid = buf; + //fprintf(stderr, "apeervarlist refid: value=<%x>\n", i); + } + //fprintf(stderr, "apeervarlist refid: value=<%s>\n", value); + } else { + have_da_rid = FALSE; } } - break; - case CP_STRATUM: - if (decodeuint(value, &stratum)) - havevar[HAVE_STRATUM] = 1; - break; - case CP_HPOLL: - if (decodeint(value, &hpoll)) { - havevar[HAVE_HPOLL] = 1; - if (hpoll < 0) - hpoll = NTP_MINPOLL; - } - break; - case CP_PPOLL: - if (decodeint(value, &ppoll)) { - havevar[HAVE_PPOLL] = 1; - if (ppoll < 0) - ppoll = NTP_MINPOLL; - } - break; - case CP_REACH: - if (decodeuint(value, &reach)) - havevar[HAVE_REACH] = 1; - break; - case CP_DELAY: - if (decodetime(value, &estdelay)) - havevar[HAVE_DELAY] = 1; - break; - case CP_OFFSET: - if (decodetime(value, &estoffset)) - havevar[HAVE_OFFSET] = 1; - break; - case CP_JITTER: - if (pvl == peervarlist) - if (decodetime(value, &estjitter)) - havevar[HAVE_JITTER] = 1; - break; - case CP_DISPERSION: - if (decodetime(value, &estdisp)) - havevar[HAVE_DISPERSION] = 1; - break; - case CP_REC: - if (decodets(value, &rec)) - havevar[HAVE_REC] = 1; - break; - case CP_SRCPORT: - if (decodeuint(value, &srcport)) - havevar[HAVE_SRCPORT] = 1; - break; - case CP_REFTIME: - havevar[HAVE_REFTIME] = 1; + } else if (!strcmp("stratum", name)) { + decodeuint(value, &stratum); + } else if (!strcmp("hpoll", name)) { + if (decodeint(value, &hpoll) && hpoll < 0) + hpoll = NTP_MINPOLL; + } else if (!strcmp("ppoll", name)) { + if (decodeint(value, &ppoll) && ppoll < 0) + ppoll = NTP_MINPOLL; + } else if (!strcmp("reach", name)) { + decodeuint(value, &reach); + } else if (!strcmp("delay", name)) { + decodetime(value, &estdelay); + } else if (!strcmp("offset", name)) { + decodetime(value, &estoffset); + } else if (!strcmp("jitter", name)) { + if ((pvl == peervarlist || pvl == apeervarlist) + && decodetime(value, &estjitter)) + have_jitter = 1; + } else if (!strcmp("rootdisp", name) || + !strcmp("dispersion", name)) { + decodetime(value, &estdisp); + } else if (!strcmp("rec", name)) { + decodets(value, &rec); + } else if (!strcmp("srcport", name) || + !strcmp("peerport", name)) { + decodeuint(value, &srcport); + } else if (!strcmp("reftime", name)) { if (!decodets(value, &reftime)) L_CLR(&reftime); - break; - default: - break; + } else { + // fprintf(stderr, "UNRECOGNIZED name=%s ", name); } } /* - * Check to see if the srcport is NTP's port. If not this probably - * isn't a valid peer association. + * hmode gives the best guidance for the t column. If the response + * did not include hmode we'll use the old decodeaddrtype() result. */ - if (havevar[HAVE_SRCPORT] && srcport != NTP_PORT) - return (1); + switch (hmode) { + + case MODE_BCLIENT: + /* broadcastclient or multicastclient */ + type = 'b'; + break; + + case MODE_BROADCAST: + /* broadcast or multicast server */ + if (IS_MCAST(&srcadr)) + type = 'M'; + else + type = 'B'; + break; + + case MODE_CLIENT: + if (ISREFCLOCKADR(&srcadr)) + type = 'l'; /* local refclock*/ + else if (SOCK_UNSPEC(&srcadr)) + type = 'p'; /* pool */ + else if (IS_MCAST(&srcadr)) + type = 'a'; /* manycastclient */ + else + type = 'u'; /* unicast */ + break; + + case MODE_ACTIVE: + type = 's'; /* symmetric active */ + break; /* configured */ + + case MODE_PASSIVE: + type = 'S'; /* symmetric passive */ + break; /* ephemeral */ + } /* * Got everything, format the line */ - poll_sec = 1< NTP_OLDVERSION) c = flash3[CTL_PEER_STATVAL(rstatus) & 0x7]; else c = flash2[CTL_PEER_STATVAL(rstatus) & 0x3]; - if (numhosts > 1) - (void) fprintf(fp, "%-*s ", maxhostlen, currenthost); - if (af == 0 || srcadr.ss_family == af){ - strcpy(clock_name, nntohost(&srcadr)); - - (void) fprintf(fp, - "%c%-15.15s %-15.15s %2ld %c %4.4s %4.4s %3lo %7.7s %8.7s %7.7s\n", - c, clock_name, dstadr_refid, stratum, type, - prettyinterval(whenbuf, when(&ts, &rec, &reftime)), - prettyinterval(pollbuf, (int)poll_sec), reach, - lfptoms(&estdelay, 3), lfptoms(&estoffset, 3), - havevar[HAVE_JITTER] ? lfptoms(&estjitter, 3) : - lfptoms(&estdisp, 3)); - return (1); + if (numhosts > 1) { + if ((pvl == peervarlist || pvl == apeervarlist) + && have_dstadr) { + serverlocal = nntohost_col(&dstadr, + (size_t)min(LIB_BUFLENGTH - 1, maxhostlen), + TRUE); + } else { + if (currenthostisnum) + serverlocal = trunc_left(currenthost, + maxhostlen); + else + serverlocal = currenthost; + } + fprintf(fp, "%-*s ", (int)maxhostlen, serverlocal); } - else + if (AF_UNSPEC == af || AF(&srcadr) == af) { + if (!have_srchost) + strlcpy(clock_name, nntohost(&srcadr), + sizeof(clock_name)); + if (wideremote && 15 < strlen(clock_name)) + fprintf(fp, "%c%s\n ", c, clock_name); + else + fprintf(fp, "%c%-15.15s ", c, clock_name); + if (!have_da_rid) { + drlen = 0; + } else { + drlen = strlen(dstadr_refid); + makeascii(drlen, dstadr_refid, fp); + } + if (pvl == apeervarlist) { + while (drlen++ < 9) + fputc(' ', fp); + fprintf(fp, "%-6d", associd); + } else { + while (drlen++ < 15) + fputc(' ', fp); + } + fprintf(fp, + " %2ld %c %4.4s %4.4s %3lo %7.7s %8.7s %7.7s\n", + stratum, type, + prettyinterval(whenbuf, sizeof(whenbuf), + when(&ts, &rec, &reftime)), + prettyinterval(pollbuf, sizeof(pollbuf), + (int)poll_sec), + reach, lfptoms(&estdelay, 3), + lfptoms(&estoffset, 3), + (have_jitter) + ? lfptoms(&estjitter, 3) + : lfptoms(&estdisp, 3)); + return (1); + } + else return(1); } -#undef HAVE_SRCADR -#undef HAVE_DSTADR -#undef HAVE_STRATUM -#undef HAVE_PPOLL -#undef HAVE_HPOLL -#undef HAVE_REACH -#undef HAVE_ESTDELAY -#undef HAVE_ESTOFFSET -#undef HAVE_JITTER -#undef HAVE_ESTDISP -#undef HAVE_REFID -#undef HAVE_REC -#undef HAVE_SRCPORT -#undef HAVE_REFTIME -#undef MAXHAVE - /* * dogetpeers - given an association ID, read and print the spreadsheet @@ -1553,12 +1874,12 @@ doprintpeers( static int dogetpeers( struct varlist *pvl, - int associd, + associd_t associd, FILE *fp, int af ) { - char *datap; + const char *datap; int res; int dsize; u_short rstatus; @@ -1570,7 +1891,7 @@ dogetpeers( /* * Damn fuzzballs */ - res = doquery(CTL_OP_READVAR, associd, 0, 0, (char *)0, &rstatus, + res = doquery(CTL_OP_READVAR, associd, 0, 0, NULL, &rstatus, &dsize, &datap); #endif @@ -1579,14 +1900,15 @@ dogetpeers( if (dsize == 0) { if (numhosts > 1) - (void) fprintf(stderr, "server=%s ", currenthost); - (void) fprintf(stderr, - "***No information returned for association %d\n", - associd); + fprintf(stderr, "server=%s ", currenthost); + fprintf(stderr, + "***No information returned for association %u\n", + associd); return 0; } - return doprintpeers(pvl, associd, (int)rstatus, dsize, datap, fp, af); + return doprintpeers(pvl, associd, (int)rstatus, dsize, datap, + fp, af); } @@ -1600,36 +1922,99 @@ dopeers( int af ) { - register int i; - char fullname[LENHOSTNAME]; - struct sockaddr_storage netnum; + u_int u; + char fullname[LENHOSTNAME]; + sockaddr_u netnum; + const char * name_or_num; + size_t sl; if (!dogetassoc(fp)) return; - for (i = 0; i < numhosts; ++i) { - if (getnetnum(chosts[i], &netnum, fullname, af)) - if ((int)strlen(fullname) > maxhostlen) - maxhostlen = strlen(fullname); + for (u = 0; u < numhosts; u++) { + if (getnetnum(chosts[u].name, &netnum, fullname, af)) { + name_or_num = nntohost(&netnum); + sl = strlen(name_or_num); + maxhostlen = max(maxhostlen, sl); + } } if (numhosts > 1) - (void) fprintf(fp, "%-*.*s ", maxhostlen, maxhostlen, "server"); - (void) fprintf(fp, - " remote refid st t when poll reach delay offset jitter\n"); + fprintf(fp, "%-*.*s ", (int)maxhostlen, (int)maxhostlen, + "server (local)"); + fprintf(fp, + " remote refid st t when poll reach delay offset jitter\n"); if (numhosts > 1) - for (i = 0; i <= maxhostlen; ++i) - (void) fprintf(fp, "="); - (void) fprintf(fp, - "==============================================================================\n"); + for (u = 0; u <= maxhostlen; u++) + fprintf(fp, "="); + fprintf(fp, + "==============================================================================\n"); - for (i = 0; i < numassoc; i++) { + for (u = 0; u < numassoc; u++) { if (!showall && - !(CTL_PEER_STATVAL(assoc_cache[i].status) - & (CTL_PST_CONFIG|CTL_PST_REACH))) + !(CTL_PEER_STATVAL(assoc_cache[u].status) + & (CTL_PST_CONFIG|CTL_PST_REACH))) { + if (debug) + fprintf(stderr, "eliding [%d]\n", + (int)assoc_cache[u].assid); continue; - if (!dogetpeers(peervarlist, (int)assoc_cache[i].assid, fp, af)) { + } + if (!dogetpeers(peervarlist, (int)assoc_cache[u].assid, + fp, af)) return; + } + return; +} + + +/* + * doapeers - print a peer spreadsheet with assocIDs + */ +static void +doapeers( + int showall, + FILE *fp, + int af + ) +{ + u_int u; + char fullname[LENHOSTNAME]; + sockaddr_u netnum; + const char * name_or_num; + size_t sl; + + if (!dogetassoc(fp)) + return; + + for (u = 0; u < numhosts; u++) { + if (getnetnum(chosts[u].name, &netnum, fullname, af)) { + name_or_num = nntohost(&netnum); + sl = strlen(name_or_num); + maxhostlen = max(maxhostlen, sl); + } + } + if (numhosts > 1) + fprintf(fp, "%-*.*s ", (int)maxhostlen, (int)maxhostlen, + "server (local)"); + fprintf(fp, + " remote refid assid st t when poll reach delay offset jitter\n"); + if (numhosts > 1) + for (u = 0; u <= maxhostlen; u++) + fprintf(fp, "="); + fprintf(fp, + "==============================================================================\n"); + + for (u = 0; u < numassoc; u++) { + if (!showall && + !(CTL_PEER_STATVAL(assoc_cache[u].status) + & (CTL_PST_CONFIG|CTL_PST_REACH))) { + if (debug) + fprintf(stderr, "eliding [%d]\n", + (int)assoc_cache[u].assid); + continue; } + if (!dogetpeers(apeervarlist, (int)assoc_cache[u].assid, + fp, af)) + return; } return; } @@ -1657,6 +2042,28 @@ peers( } +/* + * apeers - print a peer spreadsheet, with assocIDs + */ +/*ARGSUSED*/ +static void +apeers( + struct parse *pcmd, + FILE *fp + ) +{ + int af = 0; + + if (pcmd->nargs == 1) { + if (pcmd->argval->ival == 6) + af = AF_INET6; + else + af = AF_INET; + } + doapeers(0, fp, af); +} + + /* * lpeers - print a peer spreadsheet including all fuzzball peers */ @@ -1689,36 +2096,36 @@ doopeers( int af ) { - register int i; + u_int i; char fullname[LENHOSTNAME]; - struct sockaddr_storage netnum; + sockaddr_u netnum; if (!dogetassoc(fp)) return; for (i = 0; i < numhosts; ++i) { - if (getnetnum(chosts[i], &netnum, fullname, af)) - if ((int)strlen(fullname) > maxhostlen) + if (getnetnum(chosts[i].name, &netnum, fullname, af)) + if (strlen(fullname) > maxhostlen) maxhostlen = strlen(fullname); } if (numhosts > 1) - (void) fprintf(fp, "%-*.*s ", maxhostlen, maxhostlen, "server"); - (void) fprintf(fp, - " remote local st t when poll reach delay offset disp\n"); + fprintf(fp, "%-*.*s ", (int)maxhostlen, (int)maxhostlen, + "server"); + fprintf(fp, + " remote local st t when poll reach delay offset disp\n"); if (numhosts > 1) for (i = 0; i <= maxhostlen; ++i) - (void) fprintf(fp, "="); - (void) fprintf(fp, - "==============================================================================\n"); + fprintf(fp, "="); + fprintf(fp, + "==============================================================================\n"); for (i = 0; i < numassoc; i++) { if (!showall && - !(CTL_PEER_STATVAL(assoc_cache[i].status) - & (CTL_PST_CONFIG|CTL_PST_REACH))) + !(CTL_PEER_STATVAL(assoc_cache[i].status) & + (CTL_PST_CONFIG | CTL_PST_REACH))) continue; - if (!dogetpeers(opeervarlist, (int)assoc_cache[i].assid, fp, af)) { + if (!dogetpeers(opeervarlist, assoc_cache[i].assid, fp, af)) return; - } } return; } @@ -1766,3 +2173,1842 @@ lopeers( } doopeers(1, fp, af); } + + +/* + * config - send a configuration command to a remote host + */ +static void +config ( + struct parse *pcmd, + FILE *fp + ) +{ + const char *cfgcmd; + u_short rstatus; + int rsize; + const char *rdata; + char *resp; + int res; + int col; + int i; + + cfgcmd = pcmd->argval[0].string; + + if (debug > 2) + fprintf(stderr, + "In Config\n" + "Keyword = %s\n" + "Command = %s\n", pcmd->keyword, cfgcmd); + + res = doquery(CTL_OP_CONFIGURE, 0, 1, strlen(cfgcmd), cfgcmd, + &rstatus, &rsize, &rdata); + + if (res != 0) + return; + + if (rsize > 0 && '\n' == rdata[rsize - 1]) + rsize--; + + resp = emalloc(rsize + 1); + memcpy(resp, rdata, rsize); + resp[rsize] = '\0'; + + col = -1; + if (1 == sscanf(resp, "column %d syntax error", &col) + && col >= 0 && (size_t)col <= strlen(cfgcmd) + 1) { + if (interactive) { + printf("______"); /* "ntpq> " */ + printf("________"); /* ":config " */ + } else + printf("%s\n", cfgcmd); + for (i = 1; i < col; i++) + putchar('_'); + printf("^\n"); + } + printf("%s\n", resp); + free(resp); +} + + +/* + * config_from_file - remotely configure an ntpd daemon using the + * specified configuration file + * SK: This function is a kludge at best and is full of bad design + * bugs: + * 1. ntpq uses UDP, which means that there is no guarantee of in-order, + * error-free delivery. + * 2. The maximum length of a packet is constrained, and as a result, the + * maximum length of a line in a configuration file is constrained. + * Longer lines will lead to unpredictable results. + * 3. Since this function is sending a line at a time, we can't update + * the control key through the configuration file (YUCK!!) + */ +static void +config_from_file ( + struct parse *pcmd, + FILE *fp + ) +{ + u_short rstatus; + int rsize; + const char *rdata; + int res; + FILE *config_fd; + char config_cmd[MAXLINE]; + size_t config_len; + int i; + int retry_limit; + + if (debug > 2) + fprintf(stderr, + "In Config\n" + "Keyword = %s\n" + "Filename = %s\n", pcmd->keyword, + pcmd->argval[0].string); + + config_fd = fopen(pcmd->argval[0].string, "r"); + if (NULL == config_fd) { + printf("ERROR!! Couldn't open file: %s\n", + pcmd->argval[0].string); + return; + } + + printf("Sending configuration file, one line at a time.\n"); + i = 0; + while (fgets(config_cmd, MAXLINE, config_fd) != NULL) { + config_len = strlen(config_cmd); + /* ensure even the last line has newline, if possible */ + if (config_len > 0 && + config_len + 2 < sizeof(config_cmd) && + '\n' != config_cmd[config_len - 1]) + config_cmd[config_len++] = '\n'; + ++i; + retry_limit = 2; + do + res = doquery(CTL_OP_CONFIGURE, 0, 1, + strlen(config_cmd), config_cmd, + &rstatus, &rsize, &rdata); + while (res != 0 && retry_limit--); + if (res != 0) { + printf("Line No: %d query failed: %s", i, + config_cmd); + printf("Subsequent lines not sent.\n"); + fclose(config_fd); + return; + } + + if (rsize > 0 && '\n' == rdata[rsize - 1]) + rsize--; + if (rsize > 0 && '\r' == rdata[rsize - 1]) + rsize--; + printf("Line No: %d %.*s: %s", i, rsize, rdata, + config_cmd); + } + printf("Done sending file\n"); + fclose(config_fd); +} + + +static int +fetch_nonce( + char * nonce, + size_t cb_nonce + ) +{ + const char nonce_eq[] = "nonce="; + int qres; + u_short rstatus; + int rsize; + const char * rdata; + int chars; + + /* + * Retrieve a nonce specific to this client to demonstrate to + * ntpd that we're capable of receiving responses to our source + * IP address, and thereby unlikely to be forging the source. + */ + qres = doquery(CTL_OP_REQ_NONCE, 0, 0, 0, NULL, &rstatus, + &rsize, &rdata); + if (qres) { + fprintf(stderr, "nonce request failed\n"); + return FALSE; + } + + if ((size_t)rsize <= sizeof(nonce_eq) - 1 || + strncmp(rdata, nonce_eq, sizeof(nonce_eq) - 1)) { + fprintf(stderr, "unexpected nonce response format: %.*s\n", + rsize, rdata); + return FALSE; + } + chars = rsize - (sizeof(nonce_eq) - 1); + if (chars >= (int)cb_nonce) + return FALSE; + memcpy(nonce, rdata + sizeof(nonce_eq) - 1, chars); + nonce[chars] = '\0'; + while (chars > 0 && + ('\r' == nonce[chars - 1] || '\n' == nonce[chars - 1])) { + chars--; + nonce[chars] = '\0'; + } + + return TRUE; +} + + +/* + * add_mru Add and entry to mru list, hash table, and allocate + * and return a replacement. + * This is a helper for collect_mru_list(). + */ +static mru * +add_mru( + mru *add + ) +{ + u_short hash; + mru *mon; + mru *unlinked; + + + hash = NTP_HASH_ADDR(&add->addr); + /* see if we have it among previously received entries */ + for (mon = hash_table[hash]; mon != NULL; mon = mon->hlink) + if (SOCK_EQ(&mon->addr, &add->addr)) + break; + if (mon != NULL) { + if (!L_ISGEQ(&add->first, &mon->first)) { + fprintf(stderr, + "add_mru duplicate %s new first ts %08x.%08x precedes prior %08x.%08x\n", + sptoa(&add->addr), add->last.l_ui, + add->last.l_uf, mon->last.l_ui, + mon->last.l_uf); + exit(1); + } + UNLINK_DLIST(mon, mlink); + UNLINK_SLIST(unlinked, hash_table[hash], mon, hlink, mru); + INSIST(unlinked == mon); + mru_dupes++; + TRACE(2, ("(updated from %08x.%08x) ", mon->last.l_ui, + mon->last.l_uf)); + } + LINK_DLIST(mru_list, add, mlink); + LINK_SLIST(hash_table[hash], add, hlink); + TRACE(2, ("add_mru %08x.%08x c %d m %d v %d rest %x first %08x.%08x %s\n", + add->last.l_ui, add->last.l_uf, add->count, + (int)add->mode, (int)add->ver, (u_int)add->rs, + add->first.l_ui, add->first.l_uf, sptoa(&add->addr))); + /* if we didn't update an existing entry, alloc replacement */ + if (NULL == mon) { + mon = emalloc(sizeof(*mon)); + mru_count++; + } + ZERO(*mon); + + return mon; +} + + +/* MGOT macro is specific to collect_mru_list() */ +#define MGOT(bit) \ + do { \ + got |= (bit); \ + if (MRU_GOT_ALL == got) { \ + got = 0; \ + mon = add_mru(mon); \ + ci++; \ + } \ + } while (0) + + +void +mrulist_ctrl_c_hook(void) +{ + mrulist_interrupted = TRUE; +} + + +static int +collect_mru_list( + const char * parms, + l_fp * pnow + ) +{ + const u_int sleep_msecs = 5; + static int ntpd_row_limit = MRU_ROW_LIMIT; + int c_mru_l_rc; /* this function's return code */ + u_char got; /* MRU_GOT_* bits */ + time_t next_report; + size_t cb; + mru *mon; + mru *head; + mru *recent; + int list_complete; + char nonce[128]; + char buf[128]; + char req_buf[CTL_MAX_DATA_LEN]; + char *req; + char *req_end; + int chars; + int qres; + u_short rstatus; + int rsize; + const char *rdata; + int limit; + int frags; + int cap_frags; + char *tag; + char *val; + int si; /* server index in response */ + int ci; /* client (our) index for validation */ + int ri; /* request index (.# suffix) */ + int mv; + l_fp newest; + l_fp last_older; + sockaddr_u addr_older; + int have_now; + int have_addr_older; + int have_last_older; + u_int restarted_count; + u_int nonce_uses; + u_short hash; + mru *unlinked; + + if (!fetch_nonce(nonce, sizeof(nonce))) + return FALSE; + + nonce_uses = 0; + restarted_count = 0; + mru_count = 0; + INIT_DLIST(mru_list, mlink); + cb = NTP_HASH_SIZE * sizeof(*hash_table); + INSIST(NULL == hash_table); + hash_table = emalloc_zero(cb); + + c_mru_l_rc = FALSE; + list_complete = FALSE; + have_now = FALSE; + cap_frags = TRUE; + got = 0; + ri = 0; + cb = sizeof(*mon); + mon = emalloc_zero(cb); + ZERO(*pnow); + ZERO(last_older); + mrulist_interrupted = FALSE; + set_ctrl_c_hook(&mrulist_ctrl_c_hook); + fprintf(stderr, + "Ctrl-C will stop MRU retrieval and display partial results.\n"); + fflush(stderr); + next_report = time(NULL) + MRU_REPORT_SECS; + + limit = min(3 * MAXFRAGS, ntpd_row_limit); + frags = MAXFRAGS; + snprintf(req_buf, sizeof(req_buf), "nonce=%s, frags=%d%s", + nonce, frags, parms); + nonce_uses++; + + while (TRUE) { + if (debug) + fprintf(stderr, "READ_MRU parms: %s\n", req_buf); + + qres = doqueryex(CTL_OP_READ_MRU, 0, 0, strlen(req_buf), + req_buf, &rstatus, &rsize, &rdata, TRUE); + + if (CERR_UNKNOWNVAR == qres && ri > 0) { + /* + * None of the supplied prior entries match, so + * toss them from our list and try again. + */ + if (debug) + fprintf(stderr, + "no overlap between %d prior entries and server MRU list\n", + ri); + while (ri--) { + recent = HEAD_DLIST(mru_list, mlink); + INSIST(recent != NULL); + if (debug) + fprintf(stderr, + "tossing prior entry %s to resync\n", + sptoa(&recent->addr)); + UNLINK_DLIST(recent, mlink); + hash = NTP_HASH_ADDR(&recent->addr); + UNLINK_SLIST(unlinked, hash_table[hash], + recent, hlink, mru); + INSIST(unlinked == recent); + free(recent); + mru_count--; + } + if (NULL == HEAD_DLIST(mru_list, mlink)) { + restarted_count++; + if (restarted_count > 8) { + fprintf(stderr, + "Giving up after 8 restarts from the beginning.\n" + "With high-traffic NTP servers, this can occur if the\n" + "MRU list is limited to less than about 16 seconds' of\n" + "entries. See the 'mru' ntp.conf directive to adjust.\n"); + goto cleanup_return; + } + if (debug) + fprintf(stderr, + "---> Restarting from the beginning, retry #%u\n", + restarted_count); + } + } else if (CERR_UNKNOWNVAR == qres) { + fprintf(stderr, + "CERR_UNKNOWNVAR from ntpd but no priors given.\n"); + goto cleanup_return; + } else if (CERR_BADVALUE == qres) { + if (cap_frags) { + cap_frags = FALSE; + if (debug) + fprintf(stderr, + "Reverted to row limit from fragments limit.\n"); + } else { + /* ntpd has lower cap on row limit */ + ntpd_row_limit--; + limit = min(limit, ntpd_row_limit); + if (debug) + fprintf(stderr, + "Row limit reduced to %d following CERR_BADVALUE.\n", + limit); + } + } else if (ERR_INCOMPLETE == qres || + ERR_TIMEOUT == qres) { + /* + * Reduce the number of rows/frags requested by + * half to recover from lost response fragments. + */ + if (cap_frags) { + frags = max(2, frags / 2); + if (debug) + fprintf(stderr, + "Frag limit reduced to %d following incomplete response.\n", + frags); + } else { + limit = max(2, limit / 2); + if (debug) + fprintf(stderr, + "Row limit reduced to %d following incomplete response.\n", + limit); + } + } else if (qres) { + show_error_msg(qres, 0); + goto cleanup_return; + } + /* + * This is a cheap cop-out implementation of rawmode + * output for mrulist. A better approach would be to + * dump similar output after the list is collected by + * ntpq with a continuous sequence of indexes. This + * cheap approach has indexes resetting to zero for + * each query/response, and duplicates are not + * coalesced. + */ + if (!qres && rawmode) + printvars(rsize, rdata, rstatus, TYPE_SYS, 1, stdout); + ci = 0; + have_addr_older = FALSE; + have_last_older = FALSE; + while (!qres && nextvar(&rsize, &rdata, &tag, &val)) { + if (debug > 1) + fprintf(stderr, "nextvar gave: %s = %s\n", + tag, val); + switch(tag[0]) { + + case 'a': + if (!strcmp(tag, "addr.older")) { + if (!have_last_older) { + fprintf(stderr, + "addr.older %s before last.older\n", + val); + goto cleanup_return; + } + if (!decodenetnum(val, &addr_older)) { + fprintf(stderr, + "addr.older %s garbled\n", + val); + goto cleanup_return; + } + hash = NTP_HASH_ADDR(&addr_older); + for (recent = hash_table[hash]; + recent != NULL; + recent = recent->hlink) + if (ADDR_PORT_EQ( + &addr_older, + &recent->addr)) + break; + if (NULL == recent) { + fprintf(stderr, + "addr.older %s not in hash table\n", + val); + goto cleanup_return; + } + if (!L_ISEQU(&last_older, + &recent->last)) { + fprintf(stderr, + "last.older %08x.%08x mismatches %08x.%08x expected.\n", + last_older.l_ui, + last_older.l_uf, + recent->last.l_ui, + recent->last.l_uf); + goto cleanup_return; + } + have_addr_older = TRUE; + } else if (1 != sscanf(tag, "addr.%d", &si) + || si != ci) + goto nomatch; + else if (decodenetnum(val, &mon->addr)) + MGOT(MRU_GOT_ADDR); + break; + + case 'l': + if (!strcmp(tag, "last.older")) { + if ('0' != val[0] || + 'x' != val[1] || + !hextolfp(val + 2, &last_older)) { + fprintf(stderr, + "last.older %s garbled\n", + val); + goto cleanup_return; + } + have_last_older = TRUE; + } else if (!strcmp(tag, "last.newest")) { + if (0 != got) { + fprintf(stderr, + "last.newest %s before complete row, got = 0x%x\n", + val, (u_int)got); + goto cleanup_return; + } + if (!have_now) { + fprintf(stderr, + "last.newest %s before now=\n", + val); + goto cleanup_return; + } + head = HEAD_DLIST(mru_list, mlink); + if (NULL != head) { + if ('0' != val[0] || + 'x' != val[1] || + !hextolfp(val + 2, &newest) || + !L_ISEQU(&newest, + &head->last)) { + fprintf(stderr, + "last.newest %s mismatches %08x.%08x", + val, + head->last.l_ui, + head->last.l_uf); + goto cleanup_return; + } + } + list_complete = TRUE; + } else if (1 != sscanf(tag, "last.%d", &si) || + si != ci || '0' != val[0] || + 'x' != val[1] || + !hextolfp(val + 2, &mon->last)) { + goto nomatch; + } else { + MGOT(MRU_GOT_LAST); + /* + * allow interrupted retrieval, + * using most recent retrieved + * entry's last seen timestamp + * as the end of operation. + */ + *pnow = mon->last; + } + break; + + case 'f': + if (1 != sscanf(tag, "first.%d", &si) || + si != ci || '0' != val[0] || + 'x' != val[1] || + !hextolfp(val + 2, &mon->first)) + goto nomatch; + MGOT(MRU_GOT_FIRST); + break; + + case 'n': + if (!strcmp(tag, "nonce")) { + strlcpy(nonce, val, sizeof(nonce)); + nonce_uses = 0; + break; /* case */ + } else if (strcmp(tag, "now") || + '0' != val[0] || + 'x' != val[1] || + !hextolfp(val + 2, pnow)) + goto nomatch; + have_now = TRUE; + break; + + case 'c': + if (1 != sscanf(tag, "ct.%d", &si) || + si != ci || + 1 != sscanf(val, "%d", &mon->count) + || mon->count < 1) + goto nomatch; + MGOT(MRU_GOT_COUNT); + break; + + case 'm': + if (1 != sscanf(tag, "mv.%d", &si) || + si != ci || + 1 != sscanf(val, "%d", &mv)) + goto nomatch; + mon->mode = PKT_MODE(mv); + mon->ver = PKT_VERSION(mv); + MGOT(MRU_GOT_MV); + break; + + case 'r': + if (1 != sscanf(tag, "rs.%d", &si) || + si != ci || + 1 != sscanf(val, "0x%hx", &mon->rs)) + goto nomatch; + MGOT(MRU_GOT_RS); + break; + + default: + nomatch: + /* empty stmt */ ; + /* ignore unknown tags */ + } + } + if (have_now) + list_complete = TRUE; + if (list_complete) { + INSIST(0 == ri || have_addr_older); + } + if (mrulist_interrupted) { + printf("mrulist retrieval interrupted by operator.\n" + "Displaying partial client list.\n"); + fflush(stdout); + } + if (list_complete || mrulist_interrupted) { + fprintf(stderr, + "\rRetrieved %u unique MRU entries and %u updates.\n", + mru_count, mru_dupes); + fflush(stderr); + break; + } + if (time(NULL) >= next_report) { + next_report += MRU_REPORT_SECS; + fprintf(stderr, "\r%u (%u updates) ", mru_count, + mru_dupes); + fflush(stderr); + } + + /* + * Snooze for a bit between queries to let ntpd catch + * up with other duties. + */ +#ifdef SYS_WINNT + Sleep(sleep_msecs); +#elif !defined(HAVE_NANOSLEEP) + sleep((sleep_msecs / 1000) + 1); +#else + { + struct timespec interv = { 0, + 1000 * sleep_msecs }; + nanosleep(&interv, NULL); + } +#endif + /* + * If there were no errors, increase the number of rows + * to a maximum of 3 * MAXFRAGS (the most packets ntpq + * can handle in one response), on the assumption that + * no less than 3 rows fit in each packet, capped at + * our best guess at the server's row limit. + */ + if (!qres) { + if (cap_frags) { + frags = min(MAXFRAGS, frags + 1); + } else { + limit = min3(3 * MAXFRAGS, + ntpd_row_limit, + max(limit + 1, + limit * 33 / 32)); + } + } + /* + * prepare next query with as many address and last-seen + * timestamps as will fit in a single packet. + */ + req = req_buf; + req_end = req_buf + sizeof(req_buf); +#define REQ_ROOM (req_end - req) + snprintf(req, REQ_ROOM, "nonce=%s, %s=%d%s", nonce, + (cap_frags) + ? "frags" + : "limit", + (cap_frags) + ? frags + : limit, + parms); + req += strlen(req); + nonce_uses++; + if (nonce_uses >= 4) { + if (!fetch_nonce(nonce, sizeof(nonce))) + goto cleanup_return; + nonce_uses = 0; + } + + + for (ri = 0, recent = HEAD_DLIST(mru_list, mlink); + recent != NULL; + ri++, recent = NEXT_DLIST(mru_list, recent, mlink)) { + + snprintf(buf, sizeof(buf), + ", addr.%d=%s, last.%d=0x%08x.%08x", + ri, sptoa(&recent->addr), ri, + recent->last.l_ui, recent->last.l_uf); + chars = strlen(buf); + if (REQ_ROOM - chars < 1) + break; + memcpy(req, buf, chars + 1); + req += chars; + } + } + + set_ctrl_c_hook(NULL); + c_mru_l_rc = TRUE; + goto retain_hash_table; + +cleanup_return: + free(hash_table); + hash_table = NULL; + +retain_hash_table: + if (mon != NULL) + free(mon); + + return c_mru_l_rc; +} + + +/* + * qcmp_mru_addr - sort MRU entries by remote address. + * + * All IPv4 addresses sort before any IPv6, addresses are sorted by + * value within address family. + */ +static int +qcmp_mru_addr( + const void *v1, + const void *v2 + ) +{ + const mru * const * ppm1 = v1; + const mru * const * ppm2 = v2; + const mru * pm1; + const mru * pm2; + u_short af1; + u_short af2; + size_t cmplen; + size_t addr_off; + + pm1 = *ppm1; + pm2 = *ppm2; + + af1 = AF(&pm1->addr); + af2 = AF(&pm2->addr); + + if (af1 != af2) + return (AF_INET == af1) + ? -1 + : 1; + + cmplen = SIZEOF_INADDR(af1); + addr_off = (AF_INET == af1) + ? offsetof(struct sockaddr_in, sin_addr) + : offsetof(struct sockaddr_in6, sin6_addr); + + return memcmp((const char *)&pm1->addr + addr_off, + (const char *)&pm2->addr + addr_off, + cmplen); +} + + +static int +qcmp_mru_r_addr( + const void *v1, + const void *v2 + ) +{ + return -qcmp_mru_addr(v1, v2); +} + + +/* + * qcmp_mru_count - sort MRU entries by times seen (hit count). + */ +static int +qcmp_mru_count( + const void *v1, + const void *v2 + ) +{ + const mru * const * ppm1 = v1; + const mru * const * ppm2 = v2; + const mru * pm1; + const mru * pm2; + + pm1 = *ppm1; + pm2 = *ppm2; + + return (pm1->count < pm2->count) + ? -1 + : ((pm1->count == pm2->count) + ? 0 + : 1); +} + + +static int +qcmp_mru_r_count( + const void *v1, + const void *v2 + ) +{ + return -qcmp_mru_count(v1, v2); +} + + +/* + * qcmp_mru_avgint - sort MRU entries by average interval. + */ +static int +qcmp_mru_avgint( + const void *v1, + const void *v2 + ) +{ + const mru * const * ppm1 = v1; + const mru * const * ppm2 = v2; + const mru * pm1; + const mru * pm2; + l_fp interval; + double avg1; + double avg2; + + pm1 = *ppm1; + pm2 = *ppm2; + + interval = pm1->last; + L_SUB(&interval, &pm1->first); + LFPTOD(&interval, avg1); + avg1 /= pm1->count; + + interval = pm2->last; + L_SUB(&interval, &pm2->first); + LFPTOD(&interval, avg2); + avg2 /= pm2->count; + + if (avg1 < avg2) + return -1; + else if (avg1 > avg2) + return 1; + + /* secondary sort on lstint - rarely tested */ + if (L_ISEQU(&pm1->last, &pm2->last)) + return 0; + else if (L_ISGEQ(&pm1->last, &pm2->last)) + return -1; + else + return 1; +} + + +static int +qcmp_mru_r_avgint( + const void *v1, + const void *v2 + ) +{ + return -qcmp_mru_avgint(v1, v2); +} + + +/* + * mrulist - ntpq's mrulist command to fetch an arbitrarily large Most + * Recently Used (seen) remote address list from ntpd. + * + * Similar to ntpdc's monlist command, but not limited to a single + * request/response, and thereby not limited to a few hundred remote + * addresses. + * + * See ntpd/ntp_control.c read_mru_list() for comments on the way + * CTL_OP_READ_MRU is designed to be used. + * + * mrulist intentionally differs from monlist in the way the avgint + * column is calculated. monlist includes the time after the last + * packet from the client until the monlist query time in the average, + * while mrulist excludes it. That is, monlist's average interval grows + * over time for remote addresses not heard from in some time, while it + * remains unchanged in mrulist. This also affects the avgint value for + * entries representing a single packet, with identical first and last + * timestamps. mrulist shows 0 avgint, monlist shows a value identical + * to lstint. + */ +static void +mrulist( + struct parse * pcmd, + FILE * fp + ) +{ + const char mincount_eq[] = "mincount="; + const char resall_eq[] = "resall="; + const char resany_eq[] = "resany="; + const char maxlstint_eq[] = "maxlstint="; + const char laddr_eq[] = "laddr="; + const char sort_eq[] = "sort="; + mru_sort_order order; + size_t n; + char parms_buf[128]; + char buf[24]; + char *parms; + const char *arg; + size_t cb; + mru **sorted; + mru **ppentry; + mru *recent; + l_fp now; + l_fp interval; + double favgint; + double flstint; + int avgint; + int lstint; + size_t i; + + order = MRUSORT_DEF; + parms_buf[0] = '\0'; + parms = parms_buf; + for (i = 0; i < pcmd->nargs; i++) { + arg = pcmd->argval[i].string; + if (arg != NULL) { + cb = strlen(arg) + 1; + if ((!strncmp(resall_eq, arg, sizeof(resall_eq) + - 1) || !strncmp(resany_eq, arg, + sizeof(resany_eq) - 1) || !strncmp( + mincount_eq, arg, sizeof(mincount_eq) - 1) + || !strncmp(laddr_eq, arg, sizeof(laddr_eq) + - 1) || !strncmp(maxlstint_eq, arg, + sizeof(laddr_eq) - 1)) && parms + cb + 2 <= + parms_buf + sizeof(parms_buf)) { + /* these are passed intact to ntpd */ + memcpy(parms, ", ", 2); + parms += 2; + memcpy(parms, arg, cb); + parms += cb - 1; + } else if (!strncmp(sort_eq, arg, + sizeof(sort_eq) - 1)) { + arg += sizeof(sort_eq) - 1; + for (n = 0; + n < COUNTOF(mru_sort_keywords); + n++) + if (!strcmp(mru_sort_keywords[n], + arg)) + break; + if (n < COUNTOF(mru_sort_keywords)) + order = n; + } else if (!strcmp("limited", arg) || + !strcmp("kod", arg)) { + /* transform to resany=... */ + snprintf(buf, sizeof(buf), + ", resany=0x%x", + ('k' == arg[0]) + ? RES_KOD + : RES_LIMITED); + cb = 1 + strlen(buf); + if (parms + cb < + parms_buf + sizeof(parms_buf)) { + memcpy(parms, buf, cb); + parms += cb - 1; + } + } else + fprintf(stderr, + "ignoring unrecognized mrulist parameter: %s\n", + arg); + } + } + parms = parms_buf; + + if (!collect_mru_list(parms, &now)) + return; + + /* display the results */ + if (rawmode) + goto cleanup_return; + + /* construct an array of entry pointers in default order */ + sorted = eallocarray(mru_count, sizeof(*sorted)); + ppentry = sorted; + if (MRUSORT_R_DEF != order) { + ITER_DLIST_BEGIN(mru_list, recent, mlink, mru) + INSIST(ppentry < sorted + mru_count); + *ppentry = recent; + ppentry++; + ITER_DLIST_END() + } else { + REV_ITER_DLIST_BEGIN(mru_list, recent, mlink, mru) + INSIST(ppentry < sorted + mru_count); + *ppentry = recent; + ppentry++; + REV_ITER_DLIST_END() + } + + if (ppentry - sorted != (int)mru_count) { + fprintf(stderr, + "mru_count %u should match MRU list depth %ld.\n", + mru_count, (long)(ppentry - sorted)); + free(sorted); + goto cleanup_return; + } + + /* re-sort sorted[] if not default or reverse default */ + if (MRUSORT_R_DEF < order) + qsort(sorted, mru_count, sizeof(sorted[0]), + mru_qcmp_table[order]); + + printf( "lstint avgint rstr r m v count rport remote address\n" + "==============================================================================\n"); + /* '=' x 78 */ + for (ppentry = sorted; ppentry < sorted + mru_count; ppentry++) { + recent = *ppentry; + interval = now; + L_SUB(&interval, &recent->last); + LFPTOD(&interval, flstint); + lstint = (int)(flstint + 0.5); + interval = recent->last; + L_SUB(&interval, &recent->first); + LFPTOD(&interval, favgint); + favgint /= recent->count; + avgint = (int)(favgint + 0.5); + fprintf(fp, "%6d %6d %4hx %c %d %d %6d %5u %s\n", + lstint, avgint, recent->rs, + (RES_KOD & recent->rs) + ? 'K' + : (RES_LIMITED & recent->rs) + ? 'L' + : '.', + (int)recent->mode, (int)recent->ver, + recent->count, SRCPORT(&recent->addr), + nntohost(&recent->addr)); + if (showhostnames) + fflush(fp); + } + fflush(fp); + if (debug) { + fprintf(stderr, + "--- completed, freeing sorted[] pointers\n"); + fflush(stderr); + } + free(sorted); + +cleanup_return: + if (debug) { + fprintf(stderr, "... freeing MRU entries\n"); + fflush(stderr); + } + ITER_DLIST_BEGIN(mru_list, recent, mlink, mru) + free(recent); + ITER_DLIST_END() + if (debug) { + fprintf(stderr, "... freeing hash_table[]\n"); + fflush(stderr); + } + free(hash_table); + hash_table = NULL; + INIT_DLIST(mru_list, mlink); +} + + +/* + * validate_ifnum - helper for ifstats() + * + * Ensures rows are received in order and complete. + */ +static void +validate_ifnum( + FILE * fp, + u_int ifnum, + int * pfields, + ifstats_row * prow + ) +{ + if (prow->ifnum == ifnum) + return; + if (prow->ifnum + 1 <= ifnum) { + if (*pfields < IFSTATS_FIELDS) + fprintf(fp, "Warning: incomplete row with %d (of %d) fields", + *pfields, IFSTATS_FIELDS); + *pfields = 0; + prow->ifnum = ifnum; + return; + } + fprintf(stderr, + "received if index %u, have %d of %d fields for index %u, aborting.\n", + ifnum, *pfields, IFSTATS_FIELDS, prow->ifnum); + exit(1); +} + + +/* + * another_ifstats_field - helper for ifstats() + * + * If all fields for the row have been received, print it. + */ +static void +another_ifstats_field( + int * pfields, + ifstats_row * prow, + FILE * fp + ) +{ + u_int ifnum; + + (*pfields)++; + /* we understand 12 tags */ + if (IFSTATS_FIELDS > *pfields) + return; + /* + " interface name send\n" + " # address/broadcast drop flag ttl mc received sent failed peers uptime\n" + "==============================================================================\n"); + */ + fprintf(fp, + "%3u %-24.24s %c %4x %3d %2d %6d %6d %6d %5d %8d\n" + " %s\n", + prow->ifnum, prow->name, + (prow->enabled) + ? '.' + : 'D', + prow->flags, prow->ttl, prow->mcast_count, + prow->received, prow->sent, prow->send_errors, + prow->peer_count, prow->uptime, sptoa(&prow->addr)); + if (!SOCK_UNSPEC(&prow->bcast)) + fprintf(fp, " %s\n", sptoa(&prow->bcast)); + ifnum = prow->ifnum; + ZERO(*prow); + prow->ifnum = ifnum; +} + + +/* + * ifstats - ntpq -c ifstats modeled on ntpdc -c ifstats. + */ +static void +ifstats( + struct parse * pcmd, + FILE * fp + ) +{ + const char addr_fmt[] = "addr.%u"; + const char bcast_fmt[] = "bcast.%u"; + const char en_fmt[] = "en.%u"; /* enabled */ + const char flags_fmt[] = "flags.%u"; + const char mc_fmt[] = "mc.%u"; /* mcast count */ + const char name_fmt[] = "name.%u"; + const char pc_fmt[] = "pc.%u"; /* peer count */ + const char rx_fmt[] = "rx.%u"; + const char tl_fmt[] = "tl.%u"; /* ttl */ + const char tx_fmt[] = "tx.%u"; + const char txerr_fmt[] = "txerr.%u"; + const char up_fmt[] = "up.%u"; /* uptime */ + const char * datap; + int qres; + int dsize; + u_short rstatus; + char * tag; + char * val; + int fields; + u_int ui; + ifstats_row row; + int comprende; + size_t len; + + qres = doquery(CTL_OP_READ_ORDLIST_A, 0, TRUE, 0, NULL, &rstatus, + &dsize, &datap); + if (qres) /* message already displayed */ + return; + + fprintf(fp, + " interface name send\n" + " # address/broadcast drop flag ttl mc received sent failed peers uptime\n" + "==============================================================================\n"); + /* '=' x 78 */ + + ZERO(row); + fields = 0; + ui = 0; + while (nextvar(&dsize, &datap, &tag, &val)) { + if (debug > 1) + fprintf(stderr, "nextvar gave: %s = %s\n", tag, + (NULL == val) + ? "" + : val); + comprende = FALSE; + switch(tag[0]) { + + case 'a': + if (1 == sscanf(tag, addr_fmt, &ui) && + decodenetnum(val, &row.addr)) + comprende = TRUE; + break; + + case 'b': + if (1 == sscanf(tag, bcast_fmt, &ui) && + (NULL == val || + decodenetnum(val, &row.bcast))) + comprende = TRUE; + break; + + case 'e': + if (1 == sscanf(tag, en_fmt, &ui) && + 1 == sscanf(val, "%d", &row.enabled)) + comprende = TRUE; + break; + + case 'f': + if (1 == sscanf(tag, flags_fmt, &ui) && + 1 == sscanf(val, "0x%x", &row.flags)) + comprende = TRUE; + break; + + case 'm': + if (1 == sscanf(tag, mc_fmt, &ui) && + 1 == sscanf(val, "%d", &row.mcast_count)) + comprende = TRUE; + break; + + case 'n': + if (1 == sscanf(tag, name_fmt, &ui)) { + /* strip quotes */ + INSIST(val); + len = strlen(val); + if (len >= 2 && + len - 2 < sizeof(row.name)) { + len -= 2; + memcpy(row.name, val + 1, len); + row.name[len] = '\0'; + comprende = TRUE; + } + } + break; + + case 'p': + if (1 == sscanf(tag, pc_fmt, &ui) && + 1 == sscanf(val, "%d", &row.peer_count)) + comprende = TRUE; + break; + + case 'r': + if (1 == sscanf(tag, rx_fmt, &ui) && + 1 == sscanf(val, "%d", &row.received)) + comprende = TRUE; + break; + + case 't': + if (1 == sscanf(tag, tl_fmt, &ui) && + 1 == sscanf(val, "%d", &row.ttl)) + comprende = TRUE; + else if (1 == sscanf(tag, tx_fmt, &ui) && + 1 == sscanf(val, "%d", &row.sent)) + comprende = TRUE; + else if (1 == sscanf(tag, txerr_fmt, &ui) && + 1 == sscanf(val, "%d", &row.send_errors)) + comprende = TRUE; + break; + + case 'u': + if (1 == sscanf(tag, up_fmt, &ui) && + 1 == sscanf(val, "%d", &row.uptime)) + comprende = TRUE; + break; + } + + if (comprende) { + /* error out if rows out of order */ + validate_ifnum(fp, ui, &fields, &row); + /* if the row is complete, print it */ + another_ifstats_field(&fields, &row, fp); + } + } + if (fields != IFSTATS_FIELDS) + fprintf(fp, "Warning: incomplete row with %d (of %d) fields", + fields, IFSTATS_FIELDS); + + fflush(fp); +} + + +/* + * validate_reslist_idx - helper for reslist() + * + * Ensures rows are received in order and complete. + */ +static void +validate_reslist_idx( + FILE * fp, + u_int idx, + int * pfields, + reslist_row * prow + ) +{ + if (prow->idx == idx) + return; + if (prow->idx + 1 == idx) { + if (*pfields < RESLIST_FIELDS) + fprintf(fp, "Warning: incomplete row with %d (of %d) fields", + *pfields, RESLIST_FIELDS); + *pfields = 0; + prow->idx = idx; + return; + } + fprintf(stderr, + "received reslist index %u, have %d of %d fields for index %u, aborting.\n", + idx, *pfields, RESLIST_FIELDS, prow->idx); + exit(1); +} + + +/* + * another_reslist_field - helper for reslist() + * + * If all fields for the row have been received, print it. + */ +static void +another_reslist_field( + int * pfields, + reslist_row * prow, + FILE * fp + ) +{ + char addrmaskstr[128]; + int prefix; /* subnet mask as prefix bits count */ + u_int idx; + + (*pfields)++; + /* we understand 4 tags */ + if (RESLIST_FIELDS > *pfields) + return; + + prefix = sockaddr_masktoprefixlen(&prow->mask); + if (prefix >= 0) + snprintf(addrmaskstr, sizeof(addrmaskstr), "%s/%d", + stoa(&prow->addr), prefix); + else + snprintf(addrmaskstr, sizeof(addrmaskstr), "%s %s", + stoa(&prow->addr), stoa(&prow->mask)); + + /* + " hits addr/prefix or addr mask\n" + " restrictions\n" + "==============================================================================\n"); + */ + fprintf(fp, + "%10lu %s\n" + " %s\n", + prow->hits, addrmaskstr, prow->flagstr); + idx = prow->idx; + ZERO(*prow); + prow->idx = idx; +} + + +/* + * reslist - ntpq -c reslist modeled on ntpdc -c reslist. + */ +static void +reslist( + struct parse * pcmd, + FILE * fp + ) +{ + const char addr_fmtu[] = "addr.%u"; + const char mask_fmtu[] = "mask.%u"; + const char hits_fmt[] = "hits.%u"; + const char flags_fmt[] = "flags.%u"; + const char qdata[] = "addr_restrictions"; + const int qdata_chars = COUNTOF(qdata) - 1; + const char * datap; + int qres; + int dsize; + u_short rstatus; + char * tag; + char * val; + int fields; + u_int ui; + reslist_row row; + int comprende; + size_t len; + + qres = doquery(CTL_OP_READ_ORDLIST_A, 0, TRUE, qdata_chars, + qdata, &rstatus, &dsize, &datap); + if (qres) /* message already displayed */ + return; + + fprintf(fp, + " hits addr/prefix or addr mask\n" + " restrictions\n" + "==============================================================================\n"); + /* '=' x 78 */ + + ZERO(row); + fields = 0; + ui = 0; + while (nextvar(&dsize, &datap, &tag, &val)) { + if (debug > 1) + fprintf(stderr, "nextvar gave: %s = %s\n", tag, + (NULL == val) + ? "" + : val); + comprende = FALSE; + switch(tag[0]) { + + case 'a': + if (1 == sscanf(tag, addr_fmtu, &ui) && + decodenetnum(val, &row.addr)) + comprende = TRUE; + break; + + case 'f': + if (1 == sscanf(tag, flags_fmt, &ui)) { + if (NULL == val) { + row.flagstr[0] = '\0'; + comprende = TRUE; + } else { + len = strlen(val); + memcpy(row.flagstr, val, len); + row.flagstr[len] = '\0'; + comprende = TRUE; + } + } + break; + + case 'h': + if (1 == sscanf(tag, hits_fmt, &ui) && + 1 == sscanf(val, "%lu", &row.hits)) + comprende = TRUE; + break; + + case 'm': + if (1 == sscanf(tag, mask_fmtu, &ui) && + decodenetnum(val, &row.mask)) + comprende = TRUE; + break; + } + + if (comprende) { + /* error out if rows out of order */ + validate_reslist_idx(fp, ui, &fields, &row); + /* if the row is complete, print it */ + another_reslist_field(&fields, &row, fp); + } + } + if (fields != RESLIST_FIELDS) + fprintf(fp, "Warning: incomplete row with %d (of %d) fields", + fields, RESLIST_FIELDS); + + fflush(fp); +} + + +/* + * collect_display_vdc + */ +static void +collect_display_vdc( + associd_t as, + vdc * table, + int decodestatus, + FILE * fp + ) +{ + static const char * const suf[2] = { "adr", "port" }; + static const char * const leapbits[4] = { "00", "01", + "10", "11" }; + struct varlist vl[MAXLIST]; + char tagbuf[32]; + vdc *pvdc; + u_short rstatus; + int rsize; + const char *rdata; + int qres; + char *tag; + char *val; + u_int n; + size_t len; + int match; + u_long ul; + int vtype; + + ZERO(vl); + for (pvdc = table; pvdc->tag != NULL; pvdc++) { + ZERO(pvdc->v); + if (NTP_ADD != pvdc->type) { + doaddvlist(vl, pvdc->tag); + } else { + for (n = 0; n < COUNTOF(suf); n++) { + snprintf(tagbuf, sizeof(tagbuf), "%s%s", + pvdc->tag, suf[n]); + doaddvlist(vl, tagbuf); + } + } + } + qres = doquerylist(vl, CTL_OP_READVAR, as, 0, &rstatus, &rsize, + &rdata); + doclearvlist(vl); + if (qres) + return; /* error msg already displayed */ + + /* + * iterate over the response variables filling vdc_table with + * the retrieved values. + */ + while (nextvar(&rsize, &rdata, &tag, &val)) { + if (NULL == val) + continue; + n = 0; + for (pvdc = table; pvdc->tag != NULL; pvdc++) { + len = strlen(pvdc->tag); + if (strncmp(tag, pvdc->tag, len)) + continue; + if (NTP_ADD != pvdc->type) { + if ('\0' != tag[len]) + continue; + break; + } + match = FALSE; + for (n = 0; n < COUNTOF(suf); n++) { + if (strcmp(tag + len, suf[n])) + continue; + match = TRUE; + break; + } + if (match) + break; + } + if (NULL == pvdc->tag) + continue; + switch (pvdc->type) { + + case NTP_STR: + /* strip surrounding double quotes */ + if ('"' == val[0]) { + len = strlen(val); + if (len > 0 && '"' == val[len - 1]) { + val[len - 1] = '\0'; + val++; + } + } + /* fallthru */ + case NTP_MODE: /* fallthru */ + case NTP_2BIT: + pvdc->v.str = estrdup(val); + break; + + case NTP_LFP: + decodets(val, &pvdc->v.lfp); + break; + + case NTP_ADP: + if (!decodenetnum(val, &pvdc->v.sau)) + fprintf(stderr, "malformed %s=%s\n", + pvdc->tag, val); + break; + + case NTP_ADD: + if (0 == n) { /* adr */ + if (!decodenetnum(val, &pvdc->v.sau)) + fprintf(stderr, + "malformed %s=%s\n", + pvdc->tag, val); + } else { /* port */ + if (atouint(val, &ul)) + SET_PORT(&pvdc->v.sau, + (u_short)ul); + } + break; + } + } + + /* and display */ + if (decodestatus) { + vtype = (0 == as) + ? TYPE_SYS + : TYPE_PEER; + fprintf(fp, "associd=%u status=%04x %s,\n", as, rstatus, + statustoa(vtype, rstatus)); + } + + for (pvdc = table; pvdc->tag != NULL; pvdc++) { + switch (pvdc->type) { + + case NTP_STR: + if (pvdc->v.str != NULL) { + fprintf(fp, "%s %s\n", pvdc->display, + pvdc->v.str); + free(pvdc->v.str); + pvdc->v.str = NULL; + } + break; + + case NTP_ADD: /* fallthru */ + case NTP_ADP: + fprintf(fp, "%s %s\n", pvdc->display, + nntohostp(&pvdc->v.sau)); + break; + + case NTP_LFP: + fprintf(fp, "%s %s\n", pvdc->display, + prettydate(&pvdc->v.lfp)); + break; + + case NTP_MODE: + atouint(pvdc->v.str, &ul); + fprintf(fp, "%s %s\n", pvdc->display, + modetoa((int)ul)); + break; + + case NTP_2BIT: + atouint(pvdc->v.str, &ul); + fprintf(fp, "%s %s\n", pvdc->display, + leapbits[ul & 0x3]); + break; + + default: + fprintf(stderr, "unexpected vdc type %d for %s\n", + pvdc->type, pvdc->tag); + break; + } + } +} + + +/* + * sysstats - implements ntpq -c sysstats modeled on ntpdc -c sysstats + */ +static void +sysstats( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc sysstats_vdc[] = { + VDC_INIT("ss_uptime", "uptime: ", NTP_STR), + VDC_INIT("ss_reset", "sysstats reset: ", NTP_STR), + VDC_INIT("ss_received", "packets received: ", NTP_STR), + VDC_INIT("ss_thisver", "current version: ", NTP_STR), + VDC_INIT("ss_oldver", "older version: ", NTP_STR), + VDC_INIT("ss_badformat", "bad length or format: ", NTP_STR), + VDC_INIT("ss_badauth", "authentication failed:", NTP_STR), + VDC_INIT("ss_declined", "declined: ", NTP_STR), + VDC_INIT("ss_restricted", "restricted: ", NTP_STR), + VDC_INIT("ss_limited", "rate limited: ", NTP_STR), + VDC_INIT("ss_kodsent", "KoD responses: ", NTP_STR), + VDC_INIT("ss_processed", "processed for time: ", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + + collect_display_vdc(0, sysstats_vdc, FALSE, fp); +} + + +/* + * sysinfo - modeled on ntpdc's sysinfo + */ +static void +sysinfo( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc sysinfo_vdc[] = { + VDC_INIT("peeradr", "system peer: ", NTP_ADP), + VDC_INIT("peermode", "system peer mode: ", NTP_MODE), + VDC_INIT("leap", "leap indicator: ", NTP_2BIT), + VDC_INIT("stratum", "stratum: ", NTP_STR), + VDC_INIT("precision", "log2 precision: ", NTP_STR), + VDC_INIT("rootdelay", "root delay: ", NTP_STR), + VDC_INIT("rootdisp", "root dispersion: ", NTP_STR), + VDC_INIT("refid", "reference ID: ", NTP_STR), + VDC_INIT("reftime", "reference time: ", NTP_LFP), + VDC_INIT("sys_jitter", "system jitter: ", NTP_STR), + VDC_INIT("clk_jitter", "clock jitter: ", NTP_STR), + VDC_INIT("clk_wander", "clock wander: ", NTP_STR), + VDC_INIT("bcastdelay", "broadcast delay: ", NTP_STR), + VDC_INIT("authdelay", "symm. auth. delay:", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + + collect_display_vdc(0, sysinfo_vdc, TRUE, fp); +} + + +/* + * kerninfo - modeled on ntpdc's kerninfo + */ +static void +kerninfo( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc kerninfo_vdc[] = { + VDC_INIT("koffset", "pll offset: ", NTP_STR), + VDC_INIT("kfreq", "pll frequency: ", NTP_STR), + VDC_INIT("kmaxerr", "maximum error: ", NTP_STR), + VDC_INIT("kesterr", "estimated error: ", NTP_STR), + VDC_INIT("kstflags", "kernel status: ", NTP_STR), + VDC_INIT("ktimeconst", "pll time constant: ", NTP_STR), + VDC_INIT("kprecis", "precision: ", NTP_STR), + VDC_INIT("kfreqtol", "frequency tolerance: ", NTP_STR), + VDC_INIT("kppsfreq", "pps frequency: ", NTP_STR), + VDC_INIT("kppsstab", "pps stability: ", NTP_STR), + VDC_INIT("kppsjitter", "pps jitter: ", NTP_STR), + VDC_INIT("kppscalibdur", "calibration interval ", NTP_STR), + VDC_INIT("kppscalibs", "calibration cycles: ", NTP_STR), + VDC_INIT("kppsjitexc", "jitter exceeded: ", NTP_STR), + VDC_INIT("kppsstbexc", "stability exceeded: ", NTP_STR), + VDC_INIT("kppscaliberrs", "calibration errors: ", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + + collect_display_vdc(0, kerninfo_vdc, TRUE, fp); +} + + +/* + * monstats - implements ntpq -c monstats + */ +static void +monstats( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc monstats_vdc[] = { + VDC_INIT("mru_enabled", "enabled: ", NTP_STR), + VDC_INIT("mru_depth", "addresses: ", NTP_STR), + VDC_INIT("mru_deepest", "peak addresses: ", NTP_STR), + VDC_INIT("mru_maxdepth", "maximum addresses: ", NTP_STR), + VDC_INIT("mru_mindepth", "reclaim above count:", NTP_STR), + VDC_INIT("mru_maxage", "reclaim older than: ", NTP_STR), + VDC_INIT("mru_mem", "kilobytes: ", NTP_STR), + VDC_INIT("mru_maxmem", "maximum kilobytes: ", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + + collect_display_vdc(0, monstats_vdc, FALSE, fp); +} + + +/* + * iostats - ntpq -c iostats - network input and output counters + */ +static void +iostats( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc iostats_vdc[] = { + VDC_INIT("iostats_reset", "time since reset: ", NTP_STR), + VDC_INIT("total_rbuf", "receive buffers: ", NTP_STR), + VDC_INIT("free_rbuf", "free receive buffers: ", NTP_STR), + VDC_INIT("used_rbuf", "used receive buffers: ", NTP_STR), + VDC_INIT("rbuf_lowater", "low water refills: ", NTP_STR), + VDC_INIT("io_dropped", "dropped packets: ", NTP_STR), + VDC_INIT("io_ignored", "ignored packets: ", NTP_STR), + VDC_INIT("io_received", "received packets: ", NTP_STR), + VDC_INIT("io_sent", "packets sent: ", NTP_STR), + VDC_INIT("io_sendfailed", "packet send failures: ", NTP_STR), + VDC_INIT("io_wakeups", "input wakeups: ", NTP_STR), + VDC_INIT("io_goodwakeups", "useful input wakeups: ", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + + collect_display_vdc(0, iostats_vdc, FALSE, fp); +} + + +/* + * timerstats - ntpq -c timerstats - interval timer counters + */ +static void +timerstats( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc timerstats_vdc[] = { + VDC_INIT("timerstats_reset", "time since reset: ", NTP_STR), + VDC_INIT("timer_overruns", "timer overruns: ", NTP_STR), + VDC_INIT("timer_xmts", "calls to transmit: ", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + + collect_display_vdc(0, timerstats_vdc, FALSE, fp); +} + + +/* + * authinfo - implements ntpq -c authinfo + */ +static void +authinfo( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc authinfo_vdc[] = { + VDC_INIT("authreset", "time since reset:", NTP_STR), + VDC_INIT("authkeys", "stored keys: ", NTP_STR), + VDC_INIT("authfreek", "free keys: ", NTP_STR), + VDC_INIT("authklookups", "key lookups: ", NTP_STR), + VDC_INIT("authknotfound", "keys not found: ", NTP_STR), + VDC_INIT("authkuncached", "uncached keys: ", NTP_STR), + VDC_INIT("authkexpired", "expired keys: ", NTP_STR), + VDC_INIT("authencrypts", "encryptions: ", NTP_STR), + VDC_INIT("authdecrypts", "decryptions: ", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + + collect_display_vdc(0, authinfo_vdc, FALSE, fp); +} + + +/* + * pstats - show statistics for a peer + */ +static void +pstats( + struct parse *pcmd, + FILE *fp + ) +{ + static vdc pstats_vdc[] = { + VDC_INIT("src", "remote host: ", NTP_ADD), + VDC_INIT("dst", "local address: ", NTP_ADD), + VDC_INIT("timerec", "time last received: ", NTP_STR), + VDC_INIT("timer", "time until next send:", NTP_STR), + VDC_INIT("timereach", "reachability change: ", NTP_STR), + VDC_INIT("sent", "packets sent: ", NTP_STR), + VDC_INIT("received", "packets received: ", NTP_STR), + VDC_INIT("badauth", "bad authentication: ", NTP_STR), + VDC_INIT("bogusorg", "bogus origin: ", NTP_STR), + VDC_INIT("oldpkt", "duplicate: ", NTP_STR), + VDC_INIT("seldisp", "bad dispersion: ", NTP_STR), + VDC_INIT("selbroken", "bad reference time: ", NTP_STR), + VDC_INIT("candidate", "candidate order: ", NTP_STR), + VDC_INIT(NULL, NULL, 0) + }; + associd_t associd; + + associd = checkassocid(pcmd->argval[0].uval); + if (0 == associd) + return; + + collect_display_vdc(associd, pstats_vdc, TRUE, fp); +} diff --git a/contrib/ntp/ntpq/ntpq.1 b/contrib/ntp/ntpq/ntpq.1 deleted file mode 100644 index f65ae9aa4..000000000 --- a/contrib/ntp/ntpq/ntpq.1 +++ /dev/null @@ -1,385 +0,0 @@ -.TH NTPQ 1 2009-12-08 "( 4.2.4p8)" "Programmer's Manual" -.\" EDIT THIS FILE WITH CAUTION (ntpq.1) -.\" -.\" It has been AutoGen-ed Tuesday December 8, 2009 at 08:14:27 AM EST -.\" From the definitions ntpq-opts.def -.\" and the template file agman1.tpl -.\" -.SH NAME -ntpq \- standard NTP query program -.SH SYNOPSIS -.B ntpq -.\" Mixture of short (flag) options and long options -.RB [ \-\fIflag\fP " [\fIvalue\fP]]... [" \--\fIopt-name\fP " [[=| ]\fIvalue\fP]]..." -.br -.in +8 -[ host ...] -.SH "DESCRIPTION" -This manual page documents, briefly, the \fBntpq\fP command. -The -[= prog-name =] -utility program is used to query NTP servers which -implement the standard NTP mode 6 control message formats defined -in Appendix B of the NTPv3 specification RFC1305, requesting -information about current state and/or changes in that state. -The same formats are used in NTPv4, although some of the -variables have changed and new ones added. The description on this -page is for the NTPv4 variables. -The program may be run either in interactive mode or controlled using -command line arguments. -Requests to read and write arbitrary -variables can be assembled, with raw and pretty-printed output -options being available. -The -[= prog-name =] -utility can also obtain and print a -list of peers in a common format by sending multiple queries to the -server. - -If one or more request options is included on the command line -when -[= prog-name =] -is executed, each of the requests will be sent -to the NTP servers running on each of the hosts given as command -line arguments, or on localhost by default. -If no request options -are given, -[= prog-name =] -will attempt to read commands from the -standard input and execute these on the NTP server running on the -first host given on the command line, again defaulting to localhost -when no other host is specified. -The -[= prog-name =] -utility will prompt for -commands if the standard input is a terminal device. - -The -[= prog-name =] -utility uses NTP mode 6 packets to communicate with the -NTP server, and hence can be used to query any compatible server on -the network which permits it. -Note that since NTP is a UDP protocol -this communication will be somewhat unreliable, especially over -large distances in terms of network topology. -The -[= prog-name =] -utility makes -one attempt to retransmit requests, and will time requests out if -the remote host is not heard from within a suitable timeout -time. - -Specifying a -command line option other than -.Fl i -or -.Fl n -will -cause the specified query (queries) to be sent to the indicated -host(s) immediately. -Otherwise, -[= prog-name =] -will attempt to read -interactive format commands from the standard input. -.Ss "Internal Commands" -Interactive format commands consist of a keyword followed by zero -to four arguments. -Only enough characters of the full keyword to -uniquely identify the command need be typed. - -A -number of interactive format commands are executed entirely within -the -[= prog-name =] -utility itself and do not result in NTP mode 6 -requests being sent to a server. -These are described following. -.sp -.IR "? [command_keyword]" -.sp 1x help [command_keyword] -A -.Ql \&? -by itself will print a list of all the command -keywords known to this incarnation of -[= prog-name =] . -A -.Ql \&? -followed by a command keyword will print function and usage -information about the command. -This command is probably a better -source of information about -[= prog-name =] -than this manual -page. -.sp -.IR "addvars" -.Ar variable_name [=value] ... -.Xc -.sp -.IR "rmvars variable_name ..." -.sp -.IR "clearvars" -The data carried by NTP mode 6 messages consists of a list of -items of the form -.Ql variable_name=value , -where the -.Ql =value -is ignored, and can be omitted, -in requests to the server to read variables. -The -[= prog-name =] -utility maintains an internal list in which data to be included in control -messages can be assembled, and sent using the -.Ic readlist -and -.Ic writelist -commands described below. -The -.Ic addvars -command allows variables and their optional values to be added to -the list. -If more than one variable is to be added, the list should -be comma-separated and not contain white space. -The -.Ic rmvars -command can be used to remove individual variables from the list, -while the -.Ic clearlist -command removes all variables from the -list. -.sp -.IR "authenticate [ yes | no ]" -Normally -[= prog-name =] -does not authenticate requests unless -they are write requests. -The command -.Ql authenticate yes -causes -[= prog-name =] -to send authentication with all requests it -makes. -Authenticated requests causes some servers to handle -requests slightly differently, and can occasionally melt the CPU in -fuzzballs if you turn authentication on before doing a -.Ic peer -display. -The command -.Ql authenticate -causes -[= prog-name =] -to display whether or not -[= prog-name =] -is currently autheinticating requests. -.sp -.IR "cooked" -Causes output from query commands to be "cooked", so that -variables which are recognized by -[= prog-name =] -will have their -values reformatted for human consumption. -Variables which -[= prog-name =] -thinks should have a decodable value but didn't are -marked with a trailing -.Ql \&? . -.@item debug [ -.Cm more | -.Cm less | -.Cm off -] -.Xc -With no argument, displays the current debug level. -Otherwise, the debug level is changed to the indicated level. -.sp -.IR "delay milliseconds" -Specify a time interval to be added to timestamps included in -requests which require authentication. -This is used to enable -(unreliable) server reconfiguration over long delay network paths -or between machines whose clocks are unsynchronized. -Actually the -server does not now require timestamps in authenticated requests, -so this command may be obsolete. -.sp -.IR "host hostname" -Set the host to which future queries will be sent. -Hostname may -be either a host name or a numeric address. -.sp -.IR "hostnames Cm yes | Cm no" -If -.Cm yes -is specified, host names are printed in -information displays. -If -.Cm no -is specified, numeric -addresses are printed instead. -The default is -.Cm yes , -unless -modified using the command line -.Fl n -switch. -.sp -.IR "keyid keyid" -This command allows the specification of a key number to be -used to authenticate configuration requests. -This must correspond -to a key number the server has been configured to use for this -purpose. -.sp -.IR "ntpversion [" -.Cm 1 | -.Cm 2 | -.Cm 3 | -.Cm 4 -] -.Xc -Sets the NTP version number which -[= prog-name =] -claims in -packets. -Defaults to 3, Note that mode 6 control messages (and -modes, for that matter) didn't exist in NTP version 1. -There appear -to be no servers left which demand version 1. -With no argument, displays the current NTP version that will be used -when communicating with servers. -.sp -.IR "quit" -Exit -[= prog-name =] . -.sp -.IR "passwd" -This command prompts you to type in a password (which will not -be echoed) which will be used to authenticate configuration -requests. -The password must correspond to the key configured for -use by the NTP server for this purpose if such requests are to be -successful. -.sp -.IR "raw" -Causes all output from query commands is printed as received -from the remote server. -The only formating/interpretation done on -the data is to transform nonascii data into a printable (but barely -understandable) form. -.sp -.IR "timeout Ar milliseconds" -Specify a timeout period for responses to server queries. -The -default is about 5000 milliseconds. -Note that since -[= prog-name =] -retries each query once after a timeout, the total waiting time for -a timeout will be twice the timeout value set. -.br - -.SH OPTIONS -.TP -.BR \-4 ", " \--ipv4 -Force IPv4 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv4 namespace. -.TP -.BR \-6 ", " \--ipv6 -Force IPv6 DNS name resolution. -This option is a member of the ipv4 class of options. -.sp -Force DNS resolution of following host names on the command line -to the IPv6 namespace. -.TP -.BR \-c " \fIcmd\fP, " \--command "=" \fIcmd\fP -run a command and exit. -This option may appear an unlimited number of times. -.sp -The following argument is interpreted as an interactive format command -and is added to the list of commands to be executed on the specified -host(s). -.TP -.BR \-d ", " \--debug-level -Increase output debug message level. -This option may appear an unlimited number of times. -.sp -Increase the debugging message output level. -.TP -.BR \-D " \fIstring\fP, " \--set-debug-level "=" \fIstring\fP -Set the output debug message level. -This option may appear an unlimited number of times. -.sp -Set the output debugging level. Can be supplied multiple times, -but each overrides the previous value(s). -.TP -.BR \-p ", " \--peers -Print a list of the peers. -This option must not appear in combination with any of the following options: -interactive. -.sp -Print a list of the peers known to the server as well as a summary -of their state. This is equivalent to the 'peers' interactive command. -.TP -.BR \-i ", " \--interactive -Force ntpq to operate in interactive mode. -This option must not appear in combination with any of the following options: -command, peers. -.sp -Force ntpq to operate in interactive mode. Prompts will be written -to the standard output and commands read from the standard input. -.TP -.BR \-n ", " \--numeric -numeric host addresses. -.sp -Output all host addresses in dotted-quad numeric format rather than -converting to the canonical host names. -.TP -.BR \-? , " \--help" -Display usage information and exit. -.TP -.BR \-! , " \--more-help" -Extended usage information passed thru pager. -.TP -.BR \-> " [\fIrcfile\fP]," " \--save-opts" "[=\fIrcfile\fP]" -Save the option state to \fIrcfile\fP. The default is the \fIlast\fP -configuration file listed in the \fBOPTION PRESETS\fP section, below. -.TP -.BR \-< " \fIrcfile\fP," " \--load-opts" "=\fIrcfile\fP," " \--no-load-opts" -Load options from \fIrcfile\fP. -The \fIno-load-opts\fP form will disable the loading -of earlier RC/INI files. \fI--no-load-opts\fP is handled early, -out of order. -.TP -.BR \-v " [{\fIv|c|n\fP}]," " \--version" "[=\fI{v|c|n}\fP]" -Output version of program and exit. The default mode is `v', a simple -version. The `c' mode will print copyright information and `n' will -print the full copyright notice. -.SH OPTION PRESETS -Any option that is not marked as \fInot presettable\fP may be preset -by loading values from configuration ("RC" or ".INI") file(s) and values from -environment variables named: -.nf - \fBNTPQ_\fP or \fBNTPQ\fP -.fi -.aj -The environmental presets take precedence (are processed later than) -the configuration files. -The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". -If any of these are directories, then the file \fI.ntprc\fP -is searched for within those directories. -.SH AUTHOR -David L. Mills and/or others -.br -Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org - -.PP -.nf -.na -see html/copyright.html -.fi -.ad -.PP -This manual page was \fIAutoGen\fP-erated from the \fBntpq\fP -option definitions. diff --git a/contrib/ntp/ntpq/ntpq.1ntpqman b/contrib/ntp/ntpq/ntpq.1ntpqman new file mode 100644 index 000000000..b4e45b2d9 --- /dev/null +++ b/contrib/ntp/ntpq/ntpq.1ntpqman @@ -0,0 +1,1421 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpq 1ntpqman "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-joa4fN/ag-voaWeN) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:23 PM by AutoGen 5.18.5 +.\" From the definitions ntpq-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpq\fP +\- standard NTP query program +.SH SYNOPSIS +\f\*[B-Font]ntpq\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[ host ...] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The +\f\*[B-Font]ntpq\fP +utility program is used to query NTP servers which +implement the standard NTP mode 6 control message formats defined +in Appendix B of the NTPv3 specification RFC1305, requesting +information about current state and/or changes in that state. +The same formats are used in NTPv4, although some of the +variables have changed and new ones added. The description on this +page is for the NTPv4 variables. +The program may be run either in interactive mode or controlled using +command line arguments. +Requests to read and write arbitrary +variables can be assembled, with raw and pretty-printed output +options being available. +The +\f\*[B-Font]ntpq\fP +utility can also obtain and print a +list of peers in a common format by sending multiple queries to the +server. +If one or more request options is included on the command line +when +\f\*[B-Font]ntpq\fP +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +\f\*[B-Font]ntpq\fP +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +\f\*[B-Font]ntpq\fP +utility will prompt for +commands if the standard input is a terminal device. +\f\*[B-Font]ntpq\fP +uses NTP mode 6 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +\f\*[B-Font]ntpq\fP +utility makes +one attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +Specifying a +command line option other than +\f\*[B-Font]\-i\f[] +or +\f\*[B-Font]\-n\f[] +will +cause the specified query (queries) to be sent to the indicated +host(s) immediately. +Otherwise, +\f\*[B-Font]ntpq\fP +will attempt to read +interactive format commands from the standard input. +.SS "Internal Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +A +number of interactive format commands are executed entirely within +the +\f\*[B-Font]ntpq\fP +utility itself and do not result in NTP mode 6 +requests being sent to a server. +These are described following. +.TP 20 +.NOP \f\*[B-Font]?\f[] [\f\*[I-Font]command_keyword\f[]] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]help\f[] [\f\*[I-Font]command_keyword\f[]] +A +\[oq]\&?\[cq] +by itself will print a list of all the command +keywords known to this incarnation of +\f\*[B-Font]ntpq\fP. +A +\[oq]\&?\[cq] +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +\f\*[B-Font]ntpq\fP +than this manual +page. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]addvars\f[] \f\*[I-Font]variable_name\f[][\f\*[B-Font]=value\f[]] \f\*[B-Font]...\f[] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]rmvars\f[] \f\*[I-Font]variable_name\f[] \f\*[B-Font]...\f[] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]clearvars\f[] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]showvars\f[] +The data carried by NTP mode 6 messages consists of a list of +items of the form +\[oq]variable_name=value\[cq], +where the +\[oq]=value\[cq] +is ignored, and can be omitted, +in requests to the server to read variables. +The +\f\*[B-Font]ntpq\fP +utility maintains an internal list in which data to be included in control +messages can be assembled, and sent using the +\f\*[B-Font]readlist\f[] +and +\f\*[B-Font]writelist\f[] +commands described below. +The +\f\*[B-Font]addvars\f[] +command allows variables and their optional values to be added to +the list. +If more than one variable is to be added, the list should +be comma-separated and not contain white space. +The +\f\*[B-Font]rmvars\f[] +command can be used to remove individual variables from the list, +while the +\f\*[B-Font]clearlist\f[] +command removes all variables from the +list. +The +\f\*[B-Font]showvars\f[] +command displays the current list of optional variables. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]authenticate\f[] [yes | no] +Normally +\f\*[B-Font]ntpq\fP +does not authenticate requests unless +they are write requests. +The command +\[oq]authenticate yes\[cq] +causes +\f\*[B-Font]ntpq\fP +to send authentication with all requests it +makes. +Authenticated requests causes some servers to handle +requests slightly differently, and can occasionally melt the CPU in +fuzzballs if you turn authentication on before doing a +\f\*[B-Font]peer\f[] +display. +The command +\[oq]authenticate\[cq] +causes +\f\*[B-Font]ntpq\fP +to display whether or not +\f\*[B-Font]ntpq\fP +is currently autheinticating requests. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]cooked\f[] +Causes output from query commands to be "cooked", so that +variables which are recognized by +\f\*[B-Font]ntpq\fP +will have their +values reformatted for human consumption. +Variables which +\f\*[B-Font]ntpq\fP +thinks should have a decodable value but didn't are +marked with a trailing +\[oq]\&?\[cq]. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]debug\f[] [\f\*[B-Font]more\f[] | \f\*[B-Font]less\f[] | \f\*[B-Font]off\f[]] +With no argument, displays the current debug level. +Otherwise, the debug level is changed to the indicated level. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]delay\f[] \f\*[I-Font]milliseconds\f[] +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]exit\f[] +Exit +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]host\f[] \f\*[I-Font]hostname\f[] +Set the host to which future queries will be sent. +\f\*[I-Font]hostname\f[] +may be either a host name or a numeric address. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]hostnames\f[] [\f\*[B-Font]yes\f[] | \f\*[B-Font]no\f[]] +If +\f\*[B-Font]yes\f[] +is specified, host names are printed in +information displays. +If +\f\*[B-Font]no\f[] +is specified, numeric +addresses are printed instead. +The default is +\f\*[B-Font]yes\f[], +unless +modified using the command line +\f\*[B-Font]\-n\f[] +switch. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]keyid\f[] \f\*[I-Font]keyid\f[] +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to the +\f\*[B-Font]controlkey\f[] +key number the server has been configured to use for this +purpose. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]keytype\f[] [\f\*[B-Font]md5\f[] | \f\*[B-Font]OpenSSLDigestType\f[]] +Specify the type of key to use for authenticating requests. +\f\*[B-Font]md5\f[] +is alway supported. +If +\f\*[B-Font]ntpq\fP +was built with OpenSSL support, +any digest type supported by OpenSSL can also be provided. +If no argument is given, the current +\f\*[B-Font]keytype\f[] +is displayed. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]ntpversion\f[] [\f\*[B-Font]1\f[] | \f\*[B-Font]2\f[] | \f\*[B-Font]3\f[] | \f\*[B-Font]4\f[]] +Sets the NTP version number which +\f\*[B-Font]ntpq\fP +claims in +packets. +Defaults to 3, and note that mode 6 control messages (and +modes, for that matter) didn't exist in NTP version 1. +There appear +to be no servers left which demand version 1. +With no argument, displays the current NTP version that will be used +when communicating with servers. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]passwd\f[] +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.\" Not yet implemented. +.\" .It Ic poll +.\" .Op Ar n +.\" .Op Ic verbose +.\" Poll an NTP server in client mode +.\" .Ar n +.\" times. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]quit\f[] +Exit +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]raw\f[] +Causes all output from query commands is printed as received +from the remote server. +The only formating/interpretation done on +the data is to transform nonascii data into a printable (but barely +understandable) form. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]timeout\f[] \f\*[I-Font]milliseconds\f[] +Specify a timeout period for responses to server queries. +The +default is about 5000 milliseconds. +Note that since +\f\*[B-Font]ntpq\fP +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]version\f[] +Print the version of the +\f\*[B-Font]ntpq\fP +program. +.PP +.SS "Control Message Commands" +Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode-6 message to the server and expect a single response message. +The exceptions are the +\f[C]peers\f[] +command, which sends a series of messages, +and the +\f[C]mreadlist\f[] +and +\f[C]mreadvar\f[] +commands, which iterate over a range of associations. +.TP 10 +.NOP \f\*[B-Font]associations\f[] +Display a list of mobilized associations in the form: +.Dl ind assid status conf reach auth condition last_event cnt +.RS +.IP \fB\(bu\fP 2 +.IP \fB\(bu\fP 2 \f[C]ind\f[] \f[C]Ta\f[] \f[C]index\f[] \f[C]on\f[] \f[C]this\f[] \f[C]list\f[] +.IP \fB\(bu\fP 2 \f[C]assid\f[] \f[C]Ta\f[] \f[C]association\f[] \f[C]ID\f[] +.IP \fB\(bu\fP 2 \f[C]status\f[] \f[C]Ta\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word\f[] +.IP \fB\(bu\fP 2 \f[C]conf\f[] \f[C]Ta\f[] \f[C]yes\f[]: \f[C]persistent,\f[] \f[C]no\f[]: \f[C]ephemeral\f[] +.IP \fB\(bu\fP 2 \f[C]reach\f[] \f[C]Ta\f[] \f[C]yes\f[]: \f[C]reachable,\f[] \f[C]no\f[]: \f[C]unreachable\f[] +.IP \fB\(bu\fP 2 \f[C]auth\f[] \f[C]Ta\f[] \f[C]ok\f[], \f[C]yes\f[], \f[C]bad\f[] \f[C]and\f[] \f[C]none\f[] +.IP \fB\(bu\fP 2 \f[C]condition\f[] \f[C]Ta\f[] \f[C]selection\f[] \f[C]status\f[] \f[C](see\f[] \f[C]the\f[] \f[C]select\f[] \f[C]field\f[] \f[C]of\f[] \f[C]the\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word)\f[] +.IP \fB\(bu\fP 2 \f[C]last_event\f[] \f[C]Ta\f[] \f[C]event\f[] \f[C]report\f[] \f[C](see\f[] \f[C]the\f[] \f[C]event\f[] \f[C]field\f[] \f[C]of\f[] \f[C]the\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word)\f[] +.IP \fB\(bu\fP 2 \f[C]cnt\f[] \f[C]Ta\f[] \f[C]event\f[] \f[C]count\f[] \f[C](see\f[] \f[C]the\f[] \f[C]count\f[] \f[C]field\f[] \f[C]of\f[] \f[C]the\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word)\f[] +.RE +.br +.ns +.TP 10 +.NOP \f\*[B-Font]authinfo\f[] +Display the authentication statistics. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clockvar\f[] \f\*[I-Font]assocID\f[] [\f\*[I-Font]name\f[][\f\*[B-Font]=\f[]\f\*[I-Font]value\f[]] [] ...] +.br +.ns +.TP 10 +.NOP \f\*[B-Font]cv\f[] \f\*[I-Font]assocID\f[] [\f\*[I-Font]name\f[][\f\*[B-Font]=\f[]\f\*[I-Font]value\f[]] [] ...] +Display a list of clock variables for those associations supporting a reference clock. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]:config\f[] [...] +Send the remainder of the command line, including whitespace, to the server as a run-time configuration command in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is of course required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]config-from-file\f[] \f\*[I-Font]filename\f[] +Send the each line of +\f\*[I-Font]filename\f[] +to the server as run-time configuration commands in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ifstats\f[] +Display statistics for each local network address. Authentication is required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]iostats\f[] +Display network and reference clock I/O statistics. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]kerninfo\f[] +Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lassociations\f[] +Perform the same function as the associations command, except display mobilized and unmobilized associations. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lopeers\f[] [\f\*[B-Font]\-4\f[] | \f\*[B-Font]\-6\f[]] +Obtain and print a list of all peers and clients showing +\f\*[I-Font]dstadr\f[] +(associated with any given IP version). +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lpeers\f[] [\f\*[B-Font]\-4\f[] | \f\*[B-Font]\-6\f[]] +Print a peer spreadsheet for the appropriate IP version(s). +\f\*[I-Font]dstadr\f[] +(associated with any given IP version). +.br +.ns +.TP 10 +.NOP \f\*[B-Font]monstats\f[] +Display monitor facility statistics. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mrulist\f[] [\f\*[B-Font]limited\f[] | \f\*[B-Font]kod\f[] | \f\*[B-Font]mincount\f[]=\f\*[I-Font]count\f[] | \f\*[B-Font]laddr\f[]=\f\*[I-Font]localaddr\f[] | \f\*[B-Font]sort\f[]=\f\*[I-Font]sortorder\f[] | \f\*[B-Font]resany\f[]=\f\*[I-Font]hexmask\f[] | \f\*[B-Font]resall\f[]=\f\*[I-Font]hexmask\f[]] +Obtain and print traffic counts collected and maintained by the monitor facility. +With the exception of +\f\*[B-Font]sort\f[]=\f\*[I-Font]sortorder\f[], +the options filter the list returned by +\f\*[B-Font]ntpd.\f[] +The +\f\*[B-Font]limited\f[] +and +\f\*[B-Font]kod\f[] +options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. +The +\f\*[B-Font]mincount\f[]=\f\*[I-Font]count\f[] +option filters entries representing less than +\f\*[I-Font]count\f[] +packets. +The +\f\*[B-Font]laddr\f[]=\f\*[I-Font]localaddr\f[] +option filters entries for packets received on any local address other than +\f\*[I-Font]localaddr\f[]. +\f\*[B-Font]resany\f[]=\f\*[I-Font]hexmask\f[] +and +\f\*[B-Font]resall\f[]=\f\*[I-Font]hexmask\f[] +filter entries containing none or less than all, respectively, of the bits in +\f\*[I-Font]hexmask\f[], +which must begin with +\f\*[B-Font]0x\f[]. +The +\f\*[I-Font]sortorder\f[] +defaults to +\f\*[B-Font]lstint\f[] +and may be any of +\f\*[B-Font]addr\f[], +\f\*[B-Font]count\f[], +\f\*[B-Font]avgint\f[], +\f\*[B-Font]lstint\f[], +or any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: +.RS +.TP 10 +.NOP Column +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lstint\f[] +Interval in s between the receipt of the most recent packet from this address and the completion of the retrieval of the MRU list by +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]avgint\f[] +Average interval in s between packets from this address. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rstr\f[] +Restriction flags associated with this address. +Most are copied unchanged from the matching +\f\*[B-Font]restrict\f[] +command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this address triggered a rate control response. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]r\f[] +Rate control indicator, either +a period, +\f\*[B-Font]L\f[] +or +\f\*[B-Font]K\f[] +for no rate control response, +rate limiting by discarding, or rate limiting with a KoD response, respectively. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]m\f[] +Packet mode. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]v\f[] +Packet version number. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]count\f[] +Packets received from this address. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rport\f[] +Source port of last packet from this address. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]remote\f[] \f\*[B-Font]address\f[] +DNS name, numeric address, or address followed by +claimed DNS name which could not be verified in parentheses. +.RE +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mreadvar\f[] \f\*[B-Font]assocID\f[] \f\*[B-Font]assocID\f[] [\f\*[I-Font]variable_name\f[][=\f\*[I-Font]value\f[]]] ... +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mrv\f[] \f\*[B-Font]assocID\f[] \f\*[B-Font]assocID\f[] [\f\*[I-Font]variable_name\f[][=\f\*[I-Font]value\f[]]] ... +Perform the same function as the +\f\*[B-Font]readvar\f[] +command, except for a range of association IDs. +This range is determined from the association list cached by the most recent +\f\*[B-Font]associations\f[] +command. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]opeers\f[] [\f\*[B-Font]\-4\f[] | \f\*[B-Font]\-6\f[]] +Obtain and print the old-style list of all peers and clients showing +\f\*[I-Font]dstadr\f[] +(associated with any given IP version), +rather than the +\f\*[I-Font]refid\f[]. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]passociations\f[] +Perform the same function as the +\f\*[B-Font]associations\f[] +command, +except that it uses previously stored data rather than making a new query. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]peers\f[] +Display a list of peers in the form: +.Dl [tally]remote refid st t when pool reach delay offset jitter +.RS +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font][tally]\f[] +single-character code indicating current value of the +\f\*[B-Font]select\f[] +field of the +.Lk decode.html#peer "peer status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]remote\f[] +host name (or IP number) of peer. +The value displayed will be truncated to 15 characters unless the +\f\*[B-Font]\-w\f[] +flag is given, in which case the full value will be displayed +on the first line, +and the remaining data is displayed on the next line. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +association ID or +.Lk decode.html#kiss "'kiss code" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]st\f[] +stratum +.br +.ns +.TP 10 +.NOP \f\*[B-Font]t\f[] +\f\*[B-Font]u\f[]: +unicast or manycast client, +\f\*[B-Font]b\f[]: +broadcast or multicast client, +\f\*[B-Font]l\f[]: +local (reference clock), +\f\*[B-Font]s\f[]: +symmetric (peer), +\f\*[B-Font]A\f[]: +manycast server, +\f\*[B-Font]B\f[]: +broadcast server, +\f\*[B-Font]M\f[]: +multicast server +.br +.ns +.TP 10 +.NOP \f\*[B-Font]when\f[] +sec/min/hr since last received packet +.br +.ns +.TP 10 +.NOP \f\*[B-Font]poll\f[] +poll interval (log2 s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reach\f[] +reach shift register (octal) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]delay\f[] +roundtrip delay +.br +.ns +.TP 10 +.NOP \f\*[B-Font]offset\f[] +offset of server relative to this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]jitter\f[] +jitter +.RE +.br +.ns +.TP 10 +.NOP \f\*[B-Font]apeers\f[] +Display a list of peers in the form: +.Dl [tally]remote refid assid st t when pool reach delay offset jitter +where the output is just like the +\f\*[B-Font]peers\f[] +command except that the +\f\*[B-Font]refid\f[] +is displayed in hex format and the association number is also displayed. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]pstats\f[] \f\*[I-Font]assocID\f[] +Show the statistics for the peer with the given +\f\*[I-Font]assocID\f[]. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]readlist\f[] \f\*[I-Font]assocID\f[] +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rl\f[] \f\*[I-Font]assocID\f[] +Read the system or peer variables included in the variable list. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]readvar\f[] \f\*[I-Font]assocID\f[] \f\*[I-Font]name\f[][=\f\*[I-Font]value\f[]] [, ...] +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rv\f[] \f\*[I-Font]assocID\f[] \f\*[I-Font]name\f[][=\f\*[I-Font]value\f[]] [, ...] +Display the specified variables. +If +\f\*[I-Font]assocID\f[] +is zero, the variables are from the +\fISystem\f[] \fIVariables\f[] +name space, otherwise they are from the +\fIPeer\f[] \fIVariables\f[] +name space. +The +\f\*[I-Font]assocID\f[] +is required, as the same name can occur in both spaces. +If no +\f\*[I-Font]name\f[] +is included, all operative variables in the name space are displayed. +In this case only, if the +\f\*[I-Font]assocID\f[] +is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds +and frequency values in parts-per-million (PPM). +Some NTP timestamps are represented in the format +YYYYMMDDTTTT , +where YYYY is the year, +MM the month of year, +DD the day of month and +TTTT the time of day. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reslist\f[] +Show the access control (restrict) list for +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]saveconfig\f[] \f\*[I-Font]filename\f[] +Write the current configuration, +including any runtime modifications given with +\f\*[B-Font]:config\f[] +or +\f\*[B-Font]config-from-file\f[], +to the ntpd host's file +\f\*[I-Font]filename\f[]. +This command will be rejected by the server unless +.Lk miscopt.html#saveconfigdir "saveconfigdir" +appears in the +\f\*[B-Font]ntpd\f[] +configuration file. +\f\*[I-Font]filename\f[] +can use +\fCstrftime\f[]\fR()\f[] +format specifies to substitute the current date and time, for example, +\f\*[B-Font]q]saveconfig\f[] \f\*[B-Font]ntp-%Y%m%d-%H%M%S.confq]\f[]. +The filename used is stored in system variable +\f\*[B-Font]savedconfig\f[]. +Authentication is required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]timerstats\f[] +Display interval timer counters. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]writelist\f[] \f\*[I-Font]assocID\f[] +Write the system or peer variables included in the variable list. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]writevar\f[] \f\*[I-Font]assocID\f[] \f\*[I-Font]name\f[]=\f\*[I-Font]value\f[] [, ...] +Write the specified variables. +If the +\f\*[I-Font]assocID\f[] +is zero, the variables are from the +\fISystem\f[] \fIVariables\f[] +name space, otherwise they are from the +\fIPeer\f[] \fIVariables\f[] +name space. +The +\f\*[I-Font]assocID\f[] +is required, as the same name can occur in both spaces. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]sysinfo\f[] +Display operational summary. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]sysstats\f[] +Print statistics counters maintained in the protocol module. +.PP +.SS Status Words and Kiss Codes +The current state of the operating program is shown +in a set of status words +maintained by the system. +Status information is also available on a per-association basis. +These words are displayed in the +\f\*[B-Font]rv\f[] +and +\f\*[B-Font]as\f[] +commands both in hexadecimal and in decoded short tip strings. +The codes, tips and short explanations are documented on the +.Lk decode.html "Event Messages and Status Words" +page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. +.sp \n(Ppu +.ne 2 + +Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +.Lk decode.html#kiss "kiss codes" . +The original purpose was for kiss-o'-death (KoD) packets +sent by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. +.SS System Variables +The following system variables appear in the +\f\*[B-Font]rv\f[] +billboard. +Not all variables are displayed in some configurations. +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]status\f[] +.Lk decode.html#sys "system status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]version\f[] +NTP software version and build time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]processor\f[] +hardware platform and version +.br +.ns +.TP 10 +.NOP \f\*[B-Font]system\f[] +operating system and version +.br +.ns +.TP 10 +.NOP \f\*[B-Font]leap\f[] +leap warning indicator (0-3) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]stratum\f[] +stratum (1-15) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]precision\f[] +precision (log2 s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdelay\f[] +total roundtrip delay to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdisp\f[] +total dispersion to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]peer\f[] +system peer association ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]tc\f[] +time constant and poll exponent (log2 s) (3-17) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mintc\f[] +minimum time constant (log2 s) (3-10) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clock\f[] +date and time of day +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +reference ID or +.Lk decode.html#kiss "kiss code" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reftime\f[] +reference time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]offset\f[] +combined offset of server relative to this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]sys_jitter\f[] +combined system jitter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]frequency\f[] +frequency offset (PPM) relative to hardware clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clk_wander\f[] +clock frequency wander (PPM) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clk_jitter\f[] +clock jitter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]tai\f[] +TAI-UTC offset (s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]leapsec\f[] +NTP seconds when the next leap second is/was inserted +.br +.ns +.TP 10 +.NOP \f\*[B-Font]expire\f[] +NTP seconds when the NIST leapseconds file expires +.PP +The jitter and wander statistics are exponentially-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. +.sp \n(Ppu +.ne 2 + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, +including some or all of the following, +depending on the particular Autokey dance: +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]host\f[] +Autokey host name for this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ident\f[] +Autokey group name for this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +host flags (see Autokey specification) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]digest\f[] +OpenSSL message digest algorithm +.br +.ns +.TP 10 +.NOP \f\*[B-Font]signature\f[] +OpenSSL digest/signature scheme +.br +.ns +.TP 10 +.NOP \f\*[B-Font]update\f[] +NTP seconds at last signature update +.br +.ns +.TP 10 +.NOP \f\*[B-Font]cert\f[] +certificate subject, issuer and certificate flags +.br +.ns +.TP 10 +.NOP \f\*[B-Font]until\f[] +NTP seconds when the certificate expires +.PP +.SS Peer Variables +The following peer variables appear in the +\f\*[B-Font]rv\f[] +billboard for each association. +Not all variables are displayed in some configurations. +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]associd\f[] +association ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]status\f[] +.Lk decode.html#peer "peer status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]srcadr\f[] +source (remote) IP address +.br +.ns +.TP 10 +.NOP \f\*[B-Font]srcport\f[] +source (remote) port +.br +.ns +.TP 10 +.NOP \f\*[B-Font]dstadr\f[] +destination (local) IP address +.br +.ns +.TP 10 +.NOP \f\*[B-Font]dstport\f[] +destination (local) port +.br +.ns +.TP 10 +.NOP \f\*[B-Font]leap\f[] +leap indicator (0-3) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]stratum\f[] +stratum (0-15) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]precision\f[] +precision (log2 s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdelay\f[] +total roundtrip delay to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdisp\f[] +total root dispersion to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +reference ID or +.Lk decode.html#kiss "kiss code" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reftime\f[] +reference time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reach\f[] +reach register (octal) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]unreach\f[] +unreach counter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]hmode\f[] +host mode (1-6) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]pmode\f[] +peer mode (1-5) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]hpoll\f[] +host poll exponent (log2 s) (3-17) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ppoll\f[] +peer poll exponent (log2 s) (3-17) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]headway\f[] +headway (see +.Lk rate.html "Rate Management and the Kiss-o'-Death Packet" ) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flash\f[] +.Lk decode.html#flash "flash status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]offset\f[] +filter offset +.br +.ns +.TP 10 +.NOP \f\*[B-Font]delay\f[] +filter delay +.br +.ns +.TP 10 +.NOP \f\*[B-Font]dispersion\f[] +filter dispersion +.br +.ns +.TP 10 +.NOP \f\*[B-Font]jitter\f[] +filter jitter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ident\f[] +Autokey group name for this association +.br +.ns +.TP 10 +.NOP \f\*[B-Font]bias\f[] +unicast/broadcast bias +.br +.ns +.TP 10 +.NOP \f\*[B-Font]xleave\f[] +interleave delay (see +.Lk xleave.html "NTP Interleaved Modes" ) +.PP +The +\f\*[B-Font]bias\f[] +variable is calculated when the first broadcast packet is received +after the calibration volley. +It represents the offset of the broadcast subgraph relative to the unicast subgraph. +The +\f\*[B-Font]xleave\f[] +variable appears only for the interleaved symmetric and interleaved modes. +It represents the internal queuing, buffering and transmission delays +for the preceding packet. +.sp \n(Ppu +.ne 2 + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +peer flags (see Autokey specification) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]host\f[] +Autokey server name +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +peer flags (see Autokey specification) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]signature\f[] +OpenSSL digest/signature scheme +.br +.ns +.TP 10 +.NOP \f\*[B-Font]initsequence\f[] +initial key ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]initkey\f[] +initial key index +.br +.ns +.TP 10 +.NOP \f\*[B-Font]timestamp\f[] +Autokey signature timestamp +.PP +.SS Clock Variables +The following clock variables appear in the +\f\*[B-Font]cv\f[] +billboard for each association with a reference clock. +Not all variables are displayed in some configurations. +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]associd\f[] +association ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]status\f[] +.Lk decode.html#clock "clock status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]device\f[] +device description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]timecode\f[] +ASCII time code string (specific to device) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]poll\f[] +poll messages sent +.br +.ns +.TP 10 +.NOP \f\*[B-Font]noreply\f[] +no reply +.br +.ns +.TP 10 +.NOP \f\*[B-Font]badformat\f[] +bad format +.br +.ns +.TP 10 +.NOP \f\*[B-Font]baddata\f[] +bad date or time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]fudgetime1\f[] +fudge time 1 +.br +.ns +.TP 10 +.NOP \f\*[B-Font]fudgetime2\f[] +fudge time 2 +.br +.ns +.TP 10 +.NOP \f\*[B-Font]stratum\f[] +driver stratum +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +driver reference ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +driver flags +.PP +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.TP +.NOP \f\*[B-Font]\-6\f[], \f\*[B-Font]\-\-ipv6\f[] +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.TP +.NOP \f\*[B-Font]\-c\f[] \f\*[I-Font]cmd\f[], \f\*[B-Font]\-\-command\f[]=\f\*[I-Font]cmd\f[] +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.TP +.NOP \f\*[B-Font]\-d\f[], \f\*[B-Font]\-\-debug\-level\f[] +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-D\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-set\-debug\-level\f[]=\f\*[I-Font]number\f[] +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.TP +.NOP \f\*[B-Font]\-i\f[], \f\*[B-Font]\-\-interactive\f[] +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, peers. +.sp +Force \fBntpq\fP to operate in interactive mode. +Prompts will be written to the standard output and +commands read from the standard input. +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-numeric\f[] +numeric host addresses. +.sp +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +.TP +.NOP \f\*[B-Font]\-\-old\-rv\f[] +Always output status line with readvar. +.sp +By default, \fBntpq\fP now suppresses the \fBassocid=...\fP +line that precedes the output of \fBreadvar\fP +(alias \fBrv\fP) when a single variable is requested, such as +\fBntpq \-c "rv 0 offset"\fP. +This option causes \fBntpq\fP to include both lines of output +for a single-variable \fBreadvar\fP. +Using an environment variable to +preset this option in a script will enable both older and +newer \fBntpq\fP to behave identically in this regard. +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-peers\f[] +Print a list of the peers. +This option must not appear in combination with any of the following options: +interactive. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.TP +.NOP \f\*[B-Font]\-w\f[], \f\*[B-Font]\-\-wide\f[] +Display the full 'remote' value. +.sp +Display the full value of the 'remote' value. If this requires +more than 15 characters, display the full value, emit a newline, +and continue the data display properly indented on the next line. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\->\f[] [\f\*[I-Font]cfgfile\f[]], \f\*[B-Font]\-\-save-opts\f[] [=\f\*[I-Font]cfgfile\f[]] +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.TP +.NOP \f\*[B-Font]\-<\f[] \f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-load-opts\f[]=\f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-no-load-opts\f[] +Load options from \fIcfgfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early, +out of order. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPQ_\fP or \fBNTPQ\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntpq\fP +option definitions. diff --git a/contrib/ntp/ntpq/ntpq.1ntpqmdoc b/contrib/ntp/ntpq/ntpq.1ntpqmdoc new file mode 100644 index 000000000..823943457 --- /dev/null +++ b/contrib/ntp/ntpq/ntpq.1ntpqmdoc @@ -0,0 +1,964 @@ +.Dd October 21 2015 +.Dt NTPQ 1ntpqmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpq-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:29 PM by AutoGen 5.18.5 +.\" From the definitions ntpq-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpq +.Nd standard NTP query program +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[ host ...] +.Pp +.Sh DESCRIPTION +The +.Nm +utility program is used to query NTP servers which +implement the standard NTP mode 6 control message formats defined +in Appendix B of the NTPv3 specification RFC1305, requesting +information about current state and/or changes in that state. +The same formats are used in NTPv4, although some of the +variables have changed and new ones added. The description on this +page is for the NTPv4 variables. +The program may be run either in interactive mode or controlled using +command line arguments. +Requests to read and write arbitrary +variables can be assembled, with raw and pretty\-printed output +options being available. +The +.Nm +utility can also obtain and print a +list of peers in a common format by sending multiple queries to the +server. +If one or more request options is included on the command line +when +.Nm +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +.Nm +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +.Nm +utility will prompt for +commands if the standard input is a terminal device. +.Nm +uses NTP mode 6 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +.Nm +utility makes +one attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +Specifying a +command line option other than +.Fl i +or +.Fl n +will +cause the specified query (queries) to be sent to the indicated +host(s) immediately. +Otherwise, +.Nm +will attempt to read +interactive format commands from the standard input. +.Ss "Internal Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +A +number of interactive format commands are executed entirely within +the +.Nm +utility itself and do not result in NTP mode 6 +requests being sent to a server. +These are described following. +.Bl -tag -width "? [command_keyword]" -compact -offset indent +.It Ic ? Op Ar command_keyword +.It Ic help Op Ar command_keyword +A +.Ql \&? +by itself will print a list of all the command +keywords known to this incarnation of +.Nm . +A +.Ql \&? +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +.Nm +than this manual +page. +.It Ic addvars Ar variable_name Ns Xo Op Ic =value +.Ic ... +.Xc +.It Ic rmvars Ar variable_name Ic ... +.It Ic clearvars +.It Ic showvars +The data carried by NTP mode 6 messages consists of a list of +items of the form +.Ql variable_name=value , +where the +.Ql =value +is ignored, and can be omitted, +in requests to the server to read variables. +The +.Nm +utility maintains an internal list in which data to be included in control +messages can be assembled, and sent using the +.Ic readlist +and +.Ic writelist +commands described below. +The +.Ic addvars +command allows variables and their optional values to be added to +the list. +If more than one variable is to be added, the list should +be comma\-separated and not contain white space. +The +.Ic rmvars +command can be used to remove individual variables from the list, +while the +.Ic clearlist +command removes all variables from the +list. +The +.Ic showvars +command displays the current list of optional variables. +.It Ic authenticate Op yes | no +Normally +.Nm +does not authenticate requests unless +they are write requests. +The command +.Ql authenticate yes +causes +.Nm +to send authentication with all requests it +makes. +Authenticated requests causes some servers to handle +requests slightly differently, and can occasionally melt the CPU in +fuzzballs if you turn authentication on before doing a +.Ic peer +display. +The command +.Ql authenticate +causes +.Nm +to display whether or not +.Nm +is currently autheinticating requests. +.It Ic cooked +Causes output from query commands to be "cooked", so that +variables which are recognized by +.Nm +will have their +values reformatted for human consumption. +Variables which +.Nm +thinks should have a decodable value but didn't are +marked with a trailing +.Ql \&? . +.It Xo +.Ic debug +.Oo +.Cm more | +.Cm less | +.Cm off +.Oc +.Xc +With no argument, displays the current debug level. +Otherwise, the debug level is changed to the indicated level. +.It Ic delay Ar milliseconds +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.It Ic exit +Exit +.Nm . +.It Ic host Ar hostname +Set the host to which future queries will be sent. +.Ar hostname +may be either a host name or a numeric address. +.It Ic hostnames Op Cm yes | Cm no +If +.Cm yes +is specified, host names are printed in +information displays. +If +.Cm no +is specified, numeric +addresses are printed instead. +The default is +.Cm yes , +unless +modified using the command line +.Fl n +switch. +.It Ic keyid Ar keyid +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to the +.Cm controlkey +key number the server has been configured to use for this +purpose. +.It Ic keytype Xo Oo +.Cm md5 | +.Cm OpenSSLDigestType +.Oc +.Xc +Specify the type of key to use for authenticating requests. +.Cm md5 +is alway supported. +If +.Nm +was built with OpenSSL support, +any digest type supported by OpenSSL can also be provided. +If no argument is given, the current +.Ic keytype +is displayed. +.It Ic ntpversion Xo Oo +.Cm 1 | +.Cm 2 | +.Cm 3 | +.Cm 4 +.Oc +.Xc +Sets the NTP version number which +.Nm +claims in +packets. +Defaults to 3, and note that mode 6 control messages (and +modes, for that matter) didn't exist in NTP version 1. +There appear +to be no servers left which demand version 1. +With no argument, displays the current NTP version that will be used +when communicating with servers. +.It Ic passwd +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.\" Not yet implemented. +.\" .It Ic poll +.\" .Op Ar n +.\" .Op Ic verbose +.\" Poll an NTP server in client mode +.\" .Ar n +.\" times. +.It Ic quit +Exit +.Nm . +.It Ic raw +Causes all output from query commands is printed as received +from the remote server. +The only formating/interpretation done on +the data is to transform nonascii data into a printable (but barely +understandable) form. +.It Ic timeout Ar milliseconds +Specify a timeout period for responses to server queries. +The +default is about 5000 milliseconds. +Note that since +.Nm +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.It Ic version +Print the version of the +.Nm +program. +.El +.Ss "Control Message Commands" +Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode\-6 message to the server and expect a single response message. +The exceptions are the +.Li peers +command, which sends a series of messages, +and the +.Li mreadlist +and +.Li mreadvar +commands, which iterate over a range of associations. +.Bl -tag -width "something" -compact -offset indent +.It Cm associations +Display a list of mobilized associations in the form: +.Dl ind assid status conf reach auth condition last_event cnt +.Bl -column -offset indent ".Sy Variable" ".Sy Description" +.It Sy String Ta Sy Description +.It Li ind Ta index on this list +.It Li assid Ta association ID +.It Li status Ta peer status word +.It Li conf Ta Li yes : persistent, Li no : ephemeral +.It Li reach Ta Li yes : reachable, Li no : unreachable +.It Li auth Ta Li ok , Li yes , Li bad and Li none +.It Li condition Ta selection status (see the Li select field of the peer status word) +.It Li last_event Ta event report (see the Li event field of the peer status word) +.It Li cnt Ta event count (see the Li count field of the peer status word) +.El +.It Cm authinfo +Display the authentication statistics. +.It Cm clockvar Ar assocID Oo Ar name Ns Oo Cm = Ns Ar value Oc Oc Op ... +.It Cm cv Ar assocID Oo Ar name Ns Oo Cm = Ns Ar value Oc Oc Op ... +Display a list of clock variables for those associations supporting a reference clock. +.It Cm :config Op ... +Send the remainder of the command line, including whitespace, to the server as a run\-time configuration command in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is of course required. +.It Cm config\-from\-file Ar filename +Send the each line of +.Ar filename +to the server as run\-time configuration commands in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is required. +.It Ic ifstats +Display statistics for each local network address. Authentication is required. +.It Ic iostats +Display network and reference clock I/O statistics. +.It Ic kerninfo +Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable. +.It Ic lassociations +Perform the same function as the associations command, except display mobilized and unmobilized associations. +.It Ic lopeers Xo +.Oo Ic \-4 | +.Ic \-6 +.Oc +.Xc +Obtain and print a list of all peers and clients showing +.Ar dstadr +(associated with any given IP version). +.It Ic lpeers Xo +.Oo Ic \-4 | +.Ic \-6 +.Oc +.Xc +Print a peer spreadsheet for the appropriate IP version(s). +.Ar dstadr +(associated with any given IP version). +.It Ic monstats +Display monitor facility statistics. +.It Ic mrulist Oo Ic limited | Ic kod | Ic mincount Ns = Ns Ar count | Ic laddr Ns = Ns Ar localaddr | Ic sort Ns = Ns Ar sortorder | Ic resany Ns = Ns Ar hexmask | Ic resall Ns = Ns Ar hexmask Oc +Obtain and print traffic counts collected and maintained by the monitor facility. +With the exception of +.Cm sort Ns = Ns Ar sortorder , +the options filter the list returned by +.Cm ntpd. +The +.Cm limited +and +.Cm kod +options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. +The +.Cm mincount Ns = Ns Ar count +option filters entries representing less than +.Ar count +packets. +The +.Cm laddr Ns = Ns Ar localaddr +option filters entries for packets received on any local address other than +.Ar localaddr . +.Cm resany Ns = Ns Ar hexmask +and +.Cm resall Ns = Ns Ar hexmask +filter entries containing none or less than all, respectively, of the bits in +.Ar hexmask , +which must begin with +.Cm 0x . +The +.Ar sortorder +defaults to +.Cm lstint +and may be any of +.Cm addr , +.Cm count , +.Cm avgint , +.Cm lstint , +or any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: +.Bl -tag -width "something" -compact -offset indent +.It Column +Description +.It Ic lstint +Interval in s between the receipt of the most recent packet from this address and the completion of the retrieval of the MRU list by +.Nm . +.It Ic avgint +Average interval in s between packets from this address. +.It Ic rstr +Restriction flags associated with this address. +Most are copied unchanged from the matching +.Ic restrict +command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this address triggered a rate control response. +.It Ic r +Rate control indicator, either +a period, +.Ic L +or +.Ic K +for no rate control response, +rate limiting by discarding, or rate limiting with a KoD response, respectively. +.It Ic m +Packet mode. +.It Ic v +Packet version number. +.It Ic count +Packets received from this address. +.It Ic rport +Source port of last packet from this address. +.It Ic remote address +DNS name, numeric address, or address followed by +claimed DNS name which could not be verified in parentheses. +.El +.It Ic mreadvar assocID assocID Oo Ar variable_name Ns Oo = Ns Ar value Oc Oc ... +.It Ic mrv assocID assocID Oo Ar variable_name Ns Oo = Ns Ar value Oc Oc ... +Perform the same function as the +.Ic readvar +command, except for a range of association IDs. +This range is determined from the association list cached by the most recent +.Ic associations +command. +.It Ic opeers Xo +.Oo Ic \-4 | +.Ic \-6 +.Oc +.Xc +Obtain and print the old\-style list of all peers and clients showing +.Ar dstadr +(associated with any given IP version), +rather than the +.Ar refid . +.It Ic passociations +Perform the same function as the +.Ic associations +command, +except that it uses previously stored data rather than making a new query. +.It Ic peers +Display a list of peers in the form: +.Dl [tally]remote refid st t when pool reach delay offset jitter +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic [tally] +single\-character code indicating current value of the +.Ic select +field of the +.Lk decode.html#peer "peer status word" +.It Ic remote +host name (or IP number) of peer. +The value displayed will be truncated to 15 characters unless the +.Fl w +flag is given, in which case the full value will be displayed +on the first line, +and the remaining data is displayed on the next line. +.It Ic refid +association ID or +.Lk decode.html#kiss "'kiss code" +.It Ic st +stratum +.It Ic t +.Ic u : +unicast or manycast client, +.Ic b : +broadcast or multicast client, +.Ic l : +local (reference clock), +.Ic s : +symmetric (peer), +.Ic A : +manycast server, +.Ic B : +broadcast server, +.Ic M : +multicast server +.It Ic when +sec/min/hr since last received packet +.It Ic poll +poll interval (log2 s) +.It Ic reach +reach shift register (octal) +.It Ic delay +roundtrip delay +.It Ic offset +offset of server relative to this host +.It Ic jitter +jitter +.El +.It Ic apeers +Display a list of peers in the form: +.Dl [tally]remote refid assid st t when pool reach delay offset jitter +where the output is just like the +.Ic peers +command except that the +.Ic refid +is displayed in hex format and the association number is also displayed. +.It Ic pstats Ar assocID +Show the statistics for the peer with the given +.Ar assocID . +.It Ic readlist Ar assocID +.It Ic rl Ar assocID +Read the system or peer variables included in the variable list. +.It Ic readvar Ar assocID Ar name Ns Oo Ns = Ns Ar value Oc Oo , ... Oc +.It Ic rv Ar assocID Ar name Ns Oo Ns = Ns Ar value Oc Oo , ... Oc +Display the specified variables. +If +.Ar assocID +is zero, the variables are from the +.Sx System Variables +name space, otherwise they are from the +.Sx Peer Variables +name space. +The +.Ar assocID +is required, as the same name can occur in both spaces. +If no +.Ar name +is included, all operative variables in the name space are displayed. +In this case only, if the +.Ar assocID +is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds +and frequency values in parts\-per\-million (PPM). +Some NTP timestamps are represented in the format +YYYYMMDDTTTT , +where YYYY is the year, +MM the month of year, +DD the day of month and +TTTT the time of day. +.It Ic reslist +Show the access control (restrict) list for +.Nm . +.It Ic saveconfig Ar filename +Write the current configuration, +including any runtime modifications given with +.Ic :config +or +.Ic config\-from\-file , +to the ntpd host's file +.Ar filename . +This command will be rejected by the server unless +.Lk miscopt.html#saveconfigdir "saveconfigdir" +appears in the +.Ic ntpd +configuration file. +.Ar filename +can use +.Xr strftime +format specifies to substitute the current date and time, for example, +.Ic q]saveconfig ntp\-%Y%m%d\-%H%M%S.confq] . +The filename used is stored in system variable +.Ic savedconfig . +Authentication is required. +.It Ic timerstats +Display interval timer counters. +.It Ic writelist Ar assocID +Write the system or peer variables included in the variable list. +.It Ic writevar Ar assocID Ar name Ns = Ns Ar value Op , ... +Write the specified variables. +If the +.Ar assocID +is zero, the variables are from the +.Sx System Variables +name space, otherwise they are from the +.Sx Peer Variables +name space. +The +.Ar assocID +is required, as the same name can occur in both spaces. +.It Ic sysinfo +Display operational summary. +.It Ic sysstats +Print statistics counters maintained in the protocol module. +.El +.Ss Status Words and Kiss Codes +The current state of the operating program is shown +in a set of status words +maintained by the system. +Status information is also available on a per\-association basis. +These words are displayed in the +.Ic rv +and +.Ic as +commands both in hexadecimal and in decoded short tip strings. +The codes, tips and short explanations are documented on the +.Lk decode.html "Event Messages and Status Words" +page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. +.Pp +Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +.Lk decode.html#kiss "kiss codes" . +The original purpose was for kiss\-o'\-death (KoD) packets +sent by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. +.Ss System Variables +The following system variables appear in the +.Ic rv +billboard. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic status +.Lk decode.html#sys "system status word" +.It Ic version +NTP software version and build time +.It Ic processor +hardware platform and version +.It Ic system +operating system and version +.It Ic leap +leap warning indicator (0\-3) +.It Ic stratum +stratum (1\-15) +.It Ic precision +precision (log2 s) +.It Ic rootdelay +total roundtrip delay to the primary reference clock +.It Ic rootdisp +total dispersion to the primary reference clock +.It Ic peer +system peer association ID +.It Ic tc +time constant and poll exponent (log2 s) (3\-17) +.It Ic mintc +minimum time constant (log2 s) (3\-10) +.It Ic clock +date and time of day +.It Ic refid +reference ID or +.Lk decode.html#kiss "kiss code" +.It Ic reftime +reference time +.It Ic offset +combined offset of server relative to this host +.It Ic sys_jitter +combined system jitter +.It Ic frequency +frequency offset (PPM) relative to hardware clock +.It Ic clk_wander +clock frequency wander (PPM) +.It Ic clk_jitter +clock jitter +.It Ic tai +TAI\-UTC offset (s) +.It Ic leapsec +NTP seconds when the next leap second is/was inserted +.It Ic expire +NTP seconds when the NIST leapseconds file expires +.El +The jitter and wander statistics are exponentially\-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. +.Pp +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, +including some or all of the following, +depending on the particular Autokey dance: +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic host +Autokey host name for this host +.It Ic ident +Autokey group name for this host +.It Ic flags +host flags (see Autokey specification) +.It Ic digest +OpenSSL message digest algorithm +.It Ic signature +OpenSSL digest/signature scheme +.It Ic update +NTP seconds at last signature update +.It Ic cert +certificate subject, issuer and certificate flags +.It Ic until +NTP seconds when the certificate expires +.El +.Ss Peer Variables +The following peer variables appear in the +.Ic rv +billboard for each association. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic associd +association ID +.It Ic status +.Lk decode.html#peer "peer status word" +.It Ic srcadr +source (remote) IP address +.It Ic srcport +source (remote) port +.It Ic dstadr +destination (local) IP address +.It Ic dstport +destination (local) port +.It Ic leap +leap indicator (0\-3) +.It Ic stratum +stratum (0\-15) +.It Ic precision +precision (log2 s) +.It Ic rootdelay +total roundtrip delay to the primary reference clock +.It Ic rootdisp +total root dispersion to the primary reference clock +.It Ic refid +reference ID or +.Lk decode.html#kiss "kiss code" +.It Ic reftime +reference time +.It Ic reach +reach register (octal) +.It Ic unreach +unreach counter +.It Ic hmode +host mode (1\-6) +.It Ic pmode +peer mode (1\-5) +.It Ic hpoll +host poll exponent (log2 s) (3\-17) +.It Ic ppoll +peer poll exponent (log2 s) (3\-17) +.It Ic headway +headway (see +.Lk rate.html "Rate Management and the Kiss\-o'\-Death Packet" ) +.It Ic flash +.Lk decode.html#flash "flash status word" +.It Ic offset +filter offset +.It Ic delay +filter delay +.It Ic dispersion +filter dispersion +.It Ic jitter +filter jitter +.It Ic ident +Autokey group name for this association +.It Ic bias +unicast/broadcast bias +.It Ic xleave +interleave delay (see +.Lk xleave.html "NTP Interleaved Modes" ) +.El +The +.Ic bias +variable is calculated when the first broadcast packet is received +after the calibration volley. +It represents the offset of the broadcast subgraph relative to the unicast subgraph. +The +.Ic xleave +variable appears only for the interleaved symmetric and interleaved modes. +It represents the internal queuing, buffering and transmission delays +for the preceding packet. +.Pp +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic flags +peer flags (see Autokey specification) +.It Ic host +Autokey server name +.It Ic flags +peer flags (see Autokey specification) +.It Ic signature +OpenSSL digest/signature scheme +.It Ic initsequence +initial key ID +.It Ic initkey +initial key index +.It Ic timestamp +Autokey signature timestamp +.El +.Ss Clock Variables +The following clock variables appear in the +.Ic cv +billboard for each association with a reference clock. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic associd +association ID +.It Ic status +.Lk decode.html#clock "clock status word" +.It Ic device +device description +.It Ic timecode +ASCII time code string (specific to device) +.It Ic poll +poll messages sent +.It Ic noreply +no reply +.It Ic badformat +bad format +.It Ic baddata +bad date or time +.It Ic fudgetime1 +fudge time 1 +.It Ic fudgetime2 +fudge time 2 +.It Ic stratum +driver stratum +.It Ic refid +driver reference ID +.It Ic flags +driver flags +.El +.Sh "OPTIONS" +.Bl -tag +.It Fl 4 , Fl \-ipv4 +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.It Fl 6 , Fl \-ipv6 +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.It Fl c Ar cmd , Fl \-command Ns = Ns Ar cmd +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.It Fl d , Fl \-debug\-level +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.It Fl D Ar number , Fl \-set\-debug\-level Ns = Ns Ar number +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.It Fl i , Fl \-interactive +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, peers. +.sp +Force \fBntpq\fP to operate in interactive mode. +Prompts will be written to the standard output and +commands read from the standard input. +.It Fl n , Fl \-numeric +numeric host addresses. +.sp +Output all host addresses in dotted\-quad numeric format rather than +converting to the canonical host names. +.It Fl \-old\-rv +Always output status line with readvar. +.sp +By default, \fBntpq\fP now suppresses the \fBassocid=...\fP +line that precedes the output of \fBreadvar\fP +(alias \fBrv\fP) when a single variable is requested, such as +\fBntpq \-c "rv 0 offset"\fP. +This option causes \fBntpq\fP to include both lines of output +for a single\-variable \fBreadvar\fP. +Using an environment variable to +preset this option in a script will enable both older and +newer \fBntpq\fP to behave identically in this regard. +.It Fl p , Fl \-peers +Print a list of the peers. +This option must not appear in combination with any of the following options: +interactive. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.It Fl w , Fl \-wide +Display the full 'remote' value. +.sp +Display the full value of the 'remote' value. If this requires +more than 15 characters, display the full value, emit a newline, +and continue the data display properly indented on the next line. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl > Oo Ar cfgfile Oc , Fl \-save\-opts Oo Ns = Ns Ar cfgfile Oc +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.It Fl < Ar cfgfile , Fl \-load\-opts Ns = Ns Ar cfgfile , Fl \-no\-load\-opts +Load options from \fIcfgfile\fP. +The \fIno\-load\-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no\-load\-opts\fP is handled early, +out of order. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPQ_\fP or \fBNTPQ\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntpq\fP +option definitions. diff --git a/contrib/ntp/ntpq/ntpq.c b/contrib/ntp/ntpq/ntpq.c index 2e51b35ef..c8d5eced8 100644 --- a/contrib/ntp/ntpq/ntpq.c +++ b/contrib/ntp/ntpq/ntpq.c @@ -1,42 +1,46 @@ /* * ntpq - query an NTP server using mode 6 commands */ - +#include #include - #include #include #include #include #include +#ifdef HAVE_UNISTD_H +# include +#endif +#ifdef HAVE_FCNTL_H +# include +#endif +#ifdef SYS_WINNT +# include +#endif +#include +#include #include "ntpq.h" +#include "ntp_assert.h" +#include "ntp_stdlib.h" #include "ntp_unixtime.h" #include "ntp_calendar.h" -#include "ntp_io.h" #include "ntp_select.h" -#include "ntp_stdlib.h" -/* Don't include ISC's version of IPv6 variables and structures */ -#define ISC_IPV6_H 1 -#include "isc/net.h" -#include "isc/result.h" +#include "ntp_assert.h" +#include "lib_strbuf.h" +#include "ntp_lineedit.h" +#include "ntp_debug.h" +#ifdef OPENSSL +#include "openssl/evp.h" +#include "openssl/objects.h" +#include "openssl/err.h" +#endif +#include +#include "ntp_libopts.h" #include "ntpq-opts.h" -#ifdef SYS_WINNT -# include -# include -#else -# define closesocket close -#endif /* SYS_WINNT */ - -#if defined(HAVE_LIBREADLINE) || defined(HAVE_LIBEDIT) -# include -# include -#endif /* HAVE_LIBREADLINE || HAVE_LIBEDIT */ - -#ifdef SYS_VXWORKS - /* vxWorks needs mode flag -casey*/ +#ifdef SYS_VXWORKS /* vxWorks needs mode flag -casey*/ # define open(name, flags) open(name, flags, 0777) # define SERVER_PORT_NUM 123 #endif @@ -53,6 +57,15 @@ int interactive = 0; /* set to 1 when we should prompt */ const char *prompt = "ntpq> "; /* prompt to ask him about */ +/* + * use old readvars behavior? --old-rv processing in ntpq resets + * this value based on the presence or absence of --old-rv. It is + * initialized to 1 here to maintain backward compatibility with + * libntpq clients such as ntpsnmpd, which are free to reset it as + * desired. + */ +int old_rv = 1; + /* * for get_systime() @@ -64,12 +77,8 @@ s_char sys_precision; /* local clock precision (log2 s) */ */ u_long info_auth_keyid = 0; -/* - * Type of key md5 - */ -#define KEY_TYPE_MD5 4 - -static int info_auth_keytype = KEY_TYPE_MD5; /* MD5 */ +static int info_auth_keytype = NID_md5; /* MD5 */ +static size_t info_auth_hashlen = 16; /* MD5 */ u_long current_time; /* needed by authkeys; not used */ /* @@ -96,127 +105,41 @@ volatile int jump = 0; * Format values */ #define PADDING 0 -#define TS 1 /* time stamp */ -#define FL 2 /* l_fp type value */ -#define FU 3 /* u_fp type value */ -#define FS 4 /* s_fp type value */ -#define UI 5 /* unsigned integer value */ -#define SI 6 /* signed integer value */ -#define HA 7 /* host address */ -#define NA 8 /* network address */ -#define ST 9 /* string value */ -#define RF 10 /* refid (sometimes string, sometimes not) */ -#define LP 11 /* leap (print in binary) */ -#define OC 12 /* integer, print in octal */ -#define MD 13 /* mode */ -#define AR 14 /* array of times */ -#define FX 15 /* test flags */ +#define HA 1 /* host address */ +#define NA 2 /* network address */ +#define LP 3 /* leap (print in binary) */ +#define RF 4 /* refid (sometimes string, sometimes not) */ +#define AR 5 /* array of times */ +#define FX 6 /* test flags */ +#define TS 7 /* l_fp timestamp in hex */ +#define OC 8 /* integer, print in octal */ #define EOV 255 /* end of table */ - -/* - * System variable values. The array can be indexed by - * the variable index to find the textual name. - */ -struct ctl_var sys_var[] = { - { 0, PADDING, "" }, /* 0 */ - { CS_LEAP, LP, "leap" }, /* 1 */ - { CS_STRATUM, UI, "stratum" }, /* 2 */ - { CS_PRECISION, SI, "precision" }, /* 3 */ - { CS_ROOTDELAY, FS, "rootdelay" }, /* 4 */ - { CS_ROOTDISPERSION, FU, "rootdispersion" }, /* 5 */ - { CS_REFID, RF, "refid" }, /* 6 */ - { CS_REFTIME, TS, "reftime" }, /* 7 */ - { CS_POLL, UI, "poll" }, /* 8 */ - { CS_PEERID, UI, "peer" }, /* 9 */ - { CS_STATE, UI, "state" }, /* 10 */ - { CS_OFFSET, FL, "offset" }, /* 11 */ - { CS_DRIFT, FS, "frequency" }, /* 12 */ - { CS_JITTER, FU, "jitter" }, /* 13 */ - { CS_CLOCK, TS, "clock" }, /* 14 */ - { CS_PROCESSOR, ST, "processor" }, /* 15 */ - { CS_SYSTEM, ST, "system" }, /* 16 */ - { CS_VERSION, ST, "version" }, /* 17 */ - { CS_STABIL, FS, "stability" }, /* 18 */ - { CS_VARLIST, ST, "sys_var_list" }, /* 19 */ - { 0, EOV, "" } -}; - - /* - * Peer variable list - */ -struct ctl_var peer_var[] = { - { 0, PADDING, "" }, /* 0 */ - { CP_CONFIG, UI, "config" }, /* 1 */ - { CP_AUTHENABLE, UI, "authenable" }, /* 2 */ - { CP_AUTHENTIC, UI, "authentic" }, /* 3 */ - { CP_SRCADR, HA, "srcadr" }, /* 4 */ - { CP_SRCPORT, UI, "srcport" }, /* 5 */ - { CP_DSTADR, NA, "dstadr" }, /* 6 */ - { CP_DSTPORT, UI, "dstport" }, /* 7 */ - { CP_LEAP, LP, "leap" }, /* 8 */ - { CP_HMODE, MD, "hmode" }, /* 9 */ - { CP_STRATUM, UI, "stratum" }, /* 10 */ - { CP_PPOLL, UI, "ppoll" }, /* 11 */ - { CP_HPOLL, UI, "hpoll" }, /* 12 */ - { CP_PRECISION, SI, "precision" }, /* 13 */ - { CP_ROOTDELAY, FS, "rootdelay" }, /* 14 */ - { CP_ROOTDISPERSION, FU, "rootdispersion" }, /* 15 */ - { CP_REFID, RF, "refid" }, /* 16 */ - { CP_REFTIME, TS, "reftime" }, /* 17 */ - { CP_ORG, TS, "org" }, /* 18 */ - { CP_REC, TS, "rec" }, /* 19 */ - { CP_XMT, TS, "xmt" }, /* 20 */ - { CP_REACH, OC, "reach" }, /* 21 */ - { CP_UNREACH, UI, "unreach" }, /* 22 */ - { CP_TIMER, UI, "timer" }, /* 23 */ - { CP_DELAY, FS, "delay" }, /* 24 */ - { CP_OFFSET, FL, "offset" }, /* 25 */ - { CP_JITTER, FU, "jitter" }, /* 26 */ - { CP_DISPERSION, FU, "dispersion" }, /* 27 */ - { CP_KEYID, UI, "keyid" }, /* 28 */ - { CP_FILTDELAY, AR, "filtdelay" }, /* 29 */ - { CP_FILTOFFSET, AR, "filtoffset" }, /* 30 */ - { CP_PMODE, ST, "pmode" }, /* 31 */ - { CP_RECEIVED, UI, "received" }, /* 32 */ - { CP_SENT, UI, "sent" }, /* 33 */ - { CP_FILTERROR, AR, "filtdisp" }, /* 34 */ - { CP_FLASH, FX, "flash" }, /* 35 */ - { CP_TTL, UI, "ttl" }, /* 36 */ - /* - * These are duplicate entries so that we can - * process deviant version of the ntp protocol. - */ - { CP_SRCADR, HA, "peeraddr" }, /* 4 */ - { CP_SRCPORT, UI, "peerport" }, /* 5 */ - { CP_PPOLL, UI, "peerpoll" }, /* 11 */ - { CP_HPOLL, UI, "hostpoll" }, /* 12 */ - { CP_FILTERROR, AR, "filterror" }, /* 34 */ - { 0, EOV, "" } + * For the most part ntpq simply displays what ntpd provides in the + * mostly plain-text mode 6 responses. A few variable names are by + * default "cooked" to provide more human-friendly output. + */ +const var_format cookedvars[] = { + { "leap", LP }, + { "reach", OC }, + { "refid", RF }, + { "reftime", TS }, + { "clock", TS }, + { "org", TS }, + { "rec", TS }, + { "xmt", TS }, + { "flash", FX }, + { "srcadr", HA }, + { "peeradr", HA }, /* compat with others */ + { "dstadr", NA }, + { "filtdelay", AR }, + { "filtoffset", AR }, + { "filtdisp", AR }, + { "filterror", AR }, /* compat with others */ }; -/* - * Clock variable list - */ -struct ctl_var clock_var[] = { - { 0, PADDING, "" }, /* 0 */ - { CC_TYPE, UI, "type" }, /* 1 */ - { CC_TIMECODE, ST, "timecode" }, /* 2 */ - { CC_POLL, UI, "poll" }, /* 3 */ - { CC_NOREPLY, UI, "noreply" }, /* 4 */ - { CC_BADFORMAT, UI, "badformat" }, /* 5 */ - { CC_BADDATA, UI, "baddata" }, /* 6 */ - { CC_FUDGETIME1, FL, "fudgetime1" }, /* 7 */ - { CC_FUDGETIME2, FL, "fudgetime2" }, /* 8 */ - { CC_FUDGEVAL1, UI, "stratum" }, /* 9 */ - { CC_FUDGEVAL2, RF, "refid" }, /* 10 */ - { CC_FLAGS, UI, "flags" }, /* 11 */ - { CC_DEVICE, ST, "device" }, /* 12 */ - { 0, EOV, "" } -}; - /* * flasher bits @@ -224,76 +147,85 @@ struct ctl_var clock_var[] = { static const char *tstflagnames[] = { "pkt_dup", /* TEST1 */ "pkt_bogus", /* TEST2 */ - "pkt_proto", /* TEST3 */ + "pkt_unsync", /* TEST3 */ "pkt_denied", /* TEST4 */ "pkt_auth", /* TEST5 */ - "pkt_synch", /* TEST6 */ - "pkt_dist", /* TEST7 */ + "pkt_stratum", /* TEST6 */ + "pkt_header", /* TEST7 */ "pkt_autokey", /* TEST8 */ "pkt_crypto", /* TEST9 */ "peer_stratum", /* TEST10 */ "peer_dist", /* TEST11 */ "peer_loop", /* TEST12 */ - "peer_unfit" /* TEST13 */ + "peer_unreach" /* TEST13 */ }; -int ntpqmain P((int, char **)); +int ntpqmain (int, char **); /* * Built in command handler declarations */ -static int openhost P((const char *)); -static int sendpkt P((char *, int)); -static int getresponse P((int, int, u_short *, int *, char **, int)); -static int sendrequest P((int, int, int, int, char *)); -static char * tstflags P((u_long)); -static void getcmds P((void)); -static RETSIGTYPE abortcmd P((int)); -static void docmd P((const char *)); -static void tokenize P((const char *, char **, int *)); -static int findcmd P((char *, struct xcmd *, struct xcmd *, struct xcmd **)); -static int getarg P((char *, int, arg_v *)); -static int rtdatetolfp P((char *, l_fp *)); -static int decodearr P((char *, int *, l_fp *)); -static void help P((struct parse *, FILE *)); -#ifdef QSORT_USES_VOID_P -static int helpsort P((const void *, const void *)); -#else -static int helpsort P((char **, char **)); +static int openhost (const char *, int); +static void dump_hex_printable(const void *, size_t); +static int sendpkt (void *, size_t); +static int getresponse (int, int, u_short *, int *, const char **, int); +static int sendrequest (int, associd_t, int, int, const char *); +static char * tstflags (u_long); +#ifndef BUILD_AS_LIB +static void getcmds (void); +#ifndef SYS_WINNT +static RETSIGTYPE abortcmd (int); +#endif /* SYS_WINNT */ +static void docmd (const char *); +static void tokenize (const char *, char **, int *); +static int getarg (const char *, int, arg_v *); +#endif /* BUILD_AS_LIB */ +static int findcmd (const char *, struct xcmd *, + struct xcmd *, struct xcmd **); +static int rtdatetolfp (char *, l_fp *); +static int decodearr (char *, int *, l_fp *); +static void help (struct parse *, FILE *); +static int helpsort (const void *, const void *); +static void printusage (struct xcmd *, FILE *); +static void timeout (struct parse *, FILE *); +static void auth_delay (struct parse *, FILE *); +static void host (struct parse *, FILE *); +static void ntp_poll (struct parse *, FILE *); +static void keyid (struct parse *, FILE *); +static void keytype (struct parse *, FILE *); +static void passwd (struct parse *, FILE *); +static void hostnames (struct parse *, FILE *); +static void setdebug (struct parse *, FILE *); +static void quit (struct parse *, FILE *); +static void version (struct parse *, FILE *); +static void raw (struct parse *, FILE *); +static void cooked (struct parse *, FILE *); +static void authenticate (struct parse *, FILE *); +static void ntpversion (struct parse *, FILE *); +static void warning (const char *, ...) + __attribute__((__format__(__printf__, 1, 2))); +static void error (const char *, ...) + __attribute__((__format__(__printf__, 1, 2))); +static u_long getkeyid (const char *); +static void atoascii (const char *, size_t, char *, size_t); +static void cookedprint (int, int, const char *, int, int, FILE *); +static void rawprint (int, int, const char *, int, int, FILE *); +static void startoutput (void); +static void output (FILE *, const char *, const char *); +static void endoutput (FILE *); +static void outputarr (FILE *, char *, int, l_fp *); +static int assoccmp (const void *, const void *); + u_short varfmt (const char *); + +void ntpq_custom_opt_handler (tOptions *, tOptDesc *); + +#ifdef OPENSSL +# ifdef HAVE_EVP_MD_DO_ALL_SORTED +static void list_md_fn(const EVP_MD *m, const char *from, + const char *to, void *arg ); +# endif #endif -static void printusage P((struct xcmd *, FILE *)); -static void timeout P((struct parse *, FILE *)); -static void auth_delay P((struct parse *, FILE *)); -static void host P((struct parse *, FILE *)); -static void ntp_poll P((struct parse *, FILE *)); -static void keyid P((struct parse *, FILE *)); -static void keytype P((struct parse *, FILE *)); -static void passwd P((struct parse *, FILE *)); -static void hostnames P((struct parse *, FILE *)); -static void setdebug P((struct parse *, FILE *)); -static void quit P((struct parse *, FILE *)); -static void version P((struct parse *, FILE *)); -static void raw P((struct parse *, FILE *)); -static void cooked P((struct parse *, FILE *)); -static void authenticate P((struct parse *, FILE *)); -static void ntpversion P((struct parse *, FILE *)); -static void warning P((const char *, const char *, const char *)); -static void error P((const char *, const char *, const char *)); -static u_long getkeyid P((const char *)); -static void atoascii P((int, char *, char *)); -static void makeascii P((int, char *, FILE *)); -static void rawprint P((int, int, char *, int, FILE *)); -static void startoutput P((void)); -static void output P((FILE *, char *, char *)); -static void endoutput P((FILE *)); -static void outputarr P((FILE *, char *, int, l_fp *)); -static void cookedprint P((int, int, char *, int, FILE *)); -#ifdef QSORT_USES_VOID_P -static int assoccmp P((const void *, const void *)); -#else -static int assoccmp P((struct association *, struct association *)); -#endif /* sgi || bsdi */ - +static char *list_digest_names(void); /* * Built-in commands we understand @@ -317,7 +249,7 @@ struct xcmd builtins[] = { { "poll", ntp_poll, { OPT|NTP_UINT, OPT|NTP_STR, NO, NO }, { "n", "verbose", "", "" }, "poll an NTP server in client mode `n' times" }, - { "passwd", passwd, { NO, NO, NO, NO }, + { "passwd", passwd, { OPT|NTP_STR, NO, NO, NO }, { "", "", "", "" }, "specify a password to use for authenticated requests"}, { "hostnames", hostnames, { OPT|NTP_STR, NO, NO, NO }, @@ -351,8 +283,8 @@ struct xcmd builtins[] = { { "version number", "", "", "" }, "set the NTP version number to use for requests" }, { "keytype", keytype, { OPT|NTP_STR, NO, NO, NO }, - { "key type (md5|des)", "", "", "" }, - "set key type to use for authenticated requests (des|md5)" }, + { "key type %s", "", "", "" }, + NULL }, { 0, 0, { NO, NO, NO, NO }, { "", "", "", "" }, "" } }; @@ -361,29 +293,41 @@ struct xcmd builtins[] = { /* * Default values we use. */ -#define DEFTIMEOUT (5) /* 5 second time out */ -#define DEFSTIMEOUT (2) /* 2 second time out after first */ -#define DEFDELAY 0x51EB852 /* 20 milliseconds, l_fp fraction */ #define DEFHOST "localhost" /* default host name */ +#define DEFTIMEOUT 5 /* wait 5 seconds for 1st pkt */ +#define DEFSTIMEOUT 3 /* and 3 more for each additional */ +/* + * Requests are automatically retried once, so total timeout with no + * response is a bit over 2 * DEFTIMEOUT, or 10 seconds. At the other + * extreme, a request eliciting 32 packets of responses each for some + * reason nearly DEFSTIMEOUT seconds after the prior in that series, + * with a single packet dropped, would take around 32 * DEFSTIMEOUT, or + * 93 seconds to fail each of two times, or 186 seconds. + * Some commands involve a series of requests, such as "peers" and + * "mrulist", so the cumulative timeouts are even longer for those. + */ +#define DEFDELAY 0x51EB852 /* 20 milliseconds, l_fp fraction */ #define LENHOSTNAME 256 /* host name is 256 characters long */ #define MAXCMDS 100 /* maximum commands on cmd line */ #define MAXHOSTS 200 /* maximum hosts on cmd line */ #define MAXLINE 512 /* maximum line length */ #define MAXTOKENS (1+MAXARGS+2) /* maximum number of usable tokens */ #define MAXVARLEN 256 /* maximum length of a variable name */ -#define MAXVALLEN 400 /* maximum length of a variable value */ +#define MAXVALLEN 2048 /* maximum length of a variable value */ #define MAXOUTLINE 72 /* maximum length of an output line */ -#define SCREENWIDTH 76 /* nominal screen width in columns */ +#define SCREENWIDTH 76 /* nominal screen width in columns */ /* * Some variables used and manipulated locally */ -struct timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ -struct timeval tvsout = { DEFSTIMEOUT, 0 }; /* secondary time out */ +struct sock_timeval tvout = { DEFTIMEOUT, 0 }; /* time out for reads */ +struct sock_timeval tvsout = { DEFSTIMEOUT, 0 };/* secondary time out */ l_fp delay_time; /* delay time */ char currenthost[LENHOSTNAME]; /* current host name */ -struct sockaddr_in hostaddr = { 0 }; /* host address */ +int currenthostisnum; /* is prior text from IP? */ +struct sockaddr_in hostaddr; /* host address */ int showhostnames = 1; /* show host names by default */ +int wideremote = 0; /* show wide remote names? */ int ai_fam_templ; /* address family */ int ai_fam_default; /* default address family */ @@ -392,13 +336,6 @@ int havehost = 0; /* set to 1 when host open */ int s_port = 0; struct servent *server_entry = NULL; /* server entry for ntp */ -#ifdef SYS_WINNT -DWORD NumberOfBytesWritten; - -HANDLE TimerThreadHandle = NULL; /* 1998/06/03 - Used in ntplib/machines.c */ -void timer(void) { ; }; /* 1998/06/03 - Used in ntplib/machines.c */ - -#endif /* SYS_WINNT */ /* * Sequence number used for requests. It is incremented before @@ -410,15 +347,18 @@ u_short sequence; * Holds data returned from queries. Declare buffer long to be sure of * alignment. */ -#define MAXFRAGS 24 /* maximum number of fragments */ #define DATASIZE (MAXFRAGS*480) /* maximum amount of data */ long pktdata[DATASIZE/sizeof(long)]; /* - * Holds association data for use with the &n operator. + * assoc_cache[] is a dynamic array which allows references to + * associations using &1 ... &N for n associations, avoiding manual + * lookup of the current association IDs for a given ntpd. It also + * caches the status word for each association, retrieved incidentally. */ -struct association assoc_cache[MAXASSOC]; -int numassoc = 0; /* number of cached associations */ +struct association * assoc_cache; +u_int assoc_cache_slots;/* count of allocated array entries */ +u_int numassoc; /* number of cached associations */ /* * For commands typed on the command line (with the -c option) @@ -430,17 +370,18 @@ const char *ccmds[MAXCMDS]; /* * When multiple hosts are specified. */ -int numhosts = 0; -const char *chosts[MAXHOSTS]; -#define ADDHOST(cp) if (numhosts < MAXHOSTS) chosts[numhosts++] = (cp) -/* - * Error codes for internal use - */ -#define ERR_UNSPEC 256 -#define ERR_INCOMPLETE 257 -#define ERR_TIMEOUT 258 -#define ERR_TOOMUCH 259 +u_int numhosts; + +chost chosts[MAXHOSTS]; +#define ADDHOST(cp) \ + do { \ + if (numhosts < MAXHOSTS) { \ + chosts[numhosts].name = (cp); \ + chosts[numhosts].fam = ai_fam_templ; \ + numhosts++; \ + } \ + } while (0) /* * Macro definitions we use @@ -464,24 +405,25 @@ FILE *current_output; */ extern struct xcmd opcmds[]; -char *progname; -volatile int debug; +char const *progname; #ifdef NO_MAIN_ALLOWED +#ifndef BUILD_AS_LIB CALL(ntpq,"ntpq",ntpqmain); void clear_globals(void) { - extern int ntp_optind; - showhostnames = 0; /* don'tshow host names by default */ - ntp_optind = 0; - server_entry = NULL; /* server entry for ntp */ - havehost = 0; /* set to 1 when host open */ - numassoc = 0; /* number of cached associations */ - numcmds = 0; - numhosts = 0; + extern int ntp_optind; + showhostnames = 0; /* don'tshow host names by default */ + ntp_optind = 0; + server_entry = NULL; /* server entry for ntp */ + havehost = 0; /* set to 1 when host open */ + numassoc = 0; /* number of cached associations */ + numcmds = 0; + numhosts = 0; } -#endif +#endif /* !BUILD_AS_LIB */ +#endif /* NO_MAIN_ALLOWED */ /* * main - parse arguments and handle options @@ -497,13 +439,16 @@ main( } #endif +#ifndef BUILD_AS_LIB int ntpqmain( int argc, char *argv[] ) { - extern int ntp_optind; + u_int ihost; + int icmd; + #ifdef SYS_VXWORKS clear_globals(); @@ -513,102 +458,99 @@ ntpqmain( delay_time.l_ui = 0; delay_time.l_uf = DEFDELAY; -#ifdef SYS_WINNT - if (!Win32InitSockets()) - { - fprintf(stderr, "No useable winsock.dll:"); - exit(1); - } -#endif /* SYS_WINNT */ + init_lib(); /* sets up ipv4_works, ipv6_works */ + ssl_applink(); + init_auth(); - /* Check to see if we have IPv6. Otherwise force the -4 flag */ - if (isc_net_probeipv6() != ISC_R_SUCCESS) { + /* Check to see if we have IPv6. Otherwise default to IPv4 */ + if (!ipv6_works) ai_fam_default = AF_INET; + + /* Fixup keytype's help based on available digest names */ + + { + char *list; + char *msg, *fmt; + + list = list_digest_names(); + for (icmd = 0; icmd < sizeof(builtins)/sizeof(builtins[0]); icmd++) { + if (strcmp("keytype", builtins[icmd].keyword) == 0) + break; + } + + /* CID: 1295478 */ + /* This should only "trip" if "keytype" is removed from builtins */ + INSIST(icmd < sizeof(builtins)/sizeof(builtins[0])); + +#ifdef OPENSSL + builtins[icmd].desc[0] = "digest-name"; + fmt = "set key type to use for authenticated requests, one of:%s"; +#else + builtins[icmd].desc[0] = "md5"; + fmt = "set key type to use for authenticated requests (%s)"; +#endif + msg = emalloc(strlen(fmt) + strlen(list) - strlen("%s") +1); + sprintf(msg, fmt, list); + builtins[icmd].comment = msg; + free(list); } progname = argv[0]; { - int optct = optionProcess(&ntpqOptions, argc, argv); + int optct = ntpOptionProcess(&ntpqOptions, argc, argv); argc -= optct; argv += optct; } - switch (WHICH_IDX_IPV4) { - case INDEX_OPT_IPV4: + /* + * Process options other than -c and -p, which are specially + * handled by ntpq_custom_opt_handler(). + */ + + debug = OPT_VALUE_SET_DEBUG_LEVEL; + + if (HAVE_OPT(IPV4)) ai_fam_templ = AF_INET; - break; - case INDEX_OPT_IPV6: + else if (HAVE_OPT(IPV6)) ai_fam_templ = AF_INET6; - break; - default: + else ai_fam_templ = ai_fam_default; - break; - } - - if (HAVE_OPT(COMMAND)) { - int cmdct = STACKCT_OPT( COMMAND ); - const char** cmds = STACKLST_OPT( COMMAND ); - - while (cmdct-- > 0) { - ADDCMD(*cmds++); - } - } - - debug = DESC(DEBUG_LEVEL).optOccCt; - if (HAVE_OPT(INTERACTIVE)) { + if (HAVE_OPT(INTERACTIVE)) interactive = 1; - } - if (HAVE_OPT(NUMERIC)) { + if (HAVE_OPT(NUMERIC)) showhostnames = 0; - } - if (HAVE_OPT(PEERS)) { - ADDCMD("peers"); - } + if (HAVE_OPT(WIDE)) + wideremote = 1; -#if 0 - while ((c = ntp_getopt(argc, argv, "46c:dinp")) != EOF) - switch (c) { - case '4': - ai_fam_templ = AF_INET; - break; - case '6': - ai_fam_templ = AF_INET6; - break; - case 'c': - ADDCMD(ntp_optarg); - break; - case 'd': - ++debug; - break; - case 'i': - interactive = 1; - break; - case 'n': - showhostnames = 0; - break; - case 'p': - ADDCMD("peers"); - break; - default: - errflg++; - break; - } - if (errflg) { - (void) fprintf(stderr, - "usage: %s [-46dinp] [-c cmd] host ...\n", - progname); - exit(2); - } -#endif - if (ntp_optind == argc) { + old_rv = HAVE_OPT(OLD_RV); + + if (0 == argc) { ADDHOST(DEFHOST); } else { - for (; ntp_optind < argc; ntp_optind++) - ADDHOST(argv[ntp_optind]); + for (ihost = 0; ihost < (u_int)argc; ihost++) { + if ('-' == *argv[ihost]) { + // + // If I really cared I'd also check: + // 0 == argv[ihost][2] + // + // and there are other cases as well... + // + if ('4' == argv[ihost][1]) { + ai_fam_templ = AF_INET; + continue; + } else if ('6' == argv[ihost][1]) { + ai_fam_templ = AF_INET6; + continue; + } else { + // XXX Throw a usage error + } + } + ADDHOST(argv[ihost]); + } } if (numcmds == 0 && interactive == 0 @@ -622,16 +564,13 @@ ntpqmain( #endif /* SYS_WINNT */ if (numcmds == 0) { - (void) openhost(chosts[0]); + (void) openhost(chosts[0].name, chosts[0].fam); getcmds(); } else { - int ihost; - int icmd; - for (ihost = 0; ihost < numhosts; ihost++) { - if (openhost(chosts[ihost])) - for (icmd = 0; icmd < numcmds; icmd++) - docmd(ccmds[icmd]); + if (openhost(chosts[ihost].name, chosts[ihost].fam)) + for (icmd = 0; icmd < numcmds; icmd++) + docmd(ccmds[icmd]); } } #ifdef SYS_WINNT @@ -639,35 +578,42 @@ ntpqmain( #endif /* SYS_WINNT */ return 0; } - +#endif /* !BUILD_AS_LIB */ /* * openhost - open a socket to a host */ -static int +static int openhost( - const char *hname + const char *hname, + int fam ) { + const char svc[] = "ntp"; char temphost[LENHOSTNAME]; int a_info, i; - struct addrinfo hints, *ai = NULL; + struct addrinfo hints, *ai; + sockaddr_u addr; + size_t octets; register const char *cp; char name[LENHOSTNAME]; - char service[5]; /* * We need to get by the [] if they were entered */ - + cp = hname; - - if(*cp == '[') { + + if (*cp == '[') { cp++; - for(i = 0; *cp != ']'; cp++, i++) + for (i = 0; *cp && *cp != ']'; cp++, i++) name[i] = *cp; - name[i] = '\0'; - hname = name; + if (*cp == ']') { + name[i] = '\0'; + hname = name; + } else { + return 0; + } } /* @@ -677,14 +623,14 @@ openhost( * will return an "IPv4-mapped IPv6 address" address if you * give it an IPv4 address to lookup. */ - strcpy(service, "ntp"); - memset((char *)&hints, 0, sizeof(struct addrinfo)); - hints.ai_family = ai_fam_templ; + ZERO(hints); + hints.ai_family = fam; hints.ai_protocol = IPPROTO_UDP; hints.ai_socktype = SOCK_DGRAM; - hints.ai_flags = AI_NUMERICHOST; + hints.ai_flags = Z_AI_NUMERICHOST; + ai = NULL; - a_info = getaddrinfo(hname, service, &hints, &ai); + a_info = getaddrinfo(hname, svc, &hints, &ai); if (a_info == EAI_NONAME #ifdef EAI_NODATA || a_info == EAI_NODATA @@ -694,41 +640,53 @@ openhost( #ifdef AI_ADDRCONFIG hints.ai_flags |= AI_ADDRCONFIG; #endif - a_info = getaddrinfo(hname, service, &hints, &ai); + a_info = getaddrinfo(hname, svc, &hints, &ai); } +#ifdef AI_ADDRCONFIG /* Some older implementations don't like AI_ADDRCONFIG. */ if (a_info == EAI_BADFLAGS) { - hints.ai_flags = AI_CANONNAME; - a_info = getaddrinfo(hname, service, &hints, &ai); + hints.ai_flags &= ~AI_ADDRCONFIG; + a_info = getaddrinfo(hname, svc, &hints, &ai); } +#endif if (a_info != 0) { - (void) fprintf(stderr, "%s\n", gai_strerror(a_info)); + fprintf(stderr, "%s\n", gai_strerror(a_info)); return 0; } - if (ai->ai_canonname == NULL) { - strncpy(temphost, stoa((struct sockaddr_storage *)ai->ai_addr), - LENHOSTNAME); - temphost[LENHOSTNAME-1] = '\0'; + INSIST(ai != NULL); + ZERO(addr); + octets = min(sizeof(addr), ai->ai_addrlen); + memcpy(&addr, ai->ai_addr, octets); + if (ai->ai_canonname == NULL) { + strlcpy(temphost, stoa(&addr), sizeof(temphost)); + currenthostisnum = TRUE; } else { - strncpy(temphost, ai->ai_canonname, LENHOSTNAME); - temphost[LENHOSTNAME-1] = '\0'; + strlcpy(temphost, ai->ai_canonname, sizeof(temphost)); + currenthostisnum = FALSE; } if (debug > 2) - printf("Opening host %s\n", temphost); + printf("Opening host %s (%s)\n", + temphost, + (ai->ai_family == AF_INET) + ? "AF_INET" + : (ai->ai_family == AF_INET6) + ? "AF_INET6" + : "AF-???" + ); if (havehost == 1) { if (debug > 2) - printf("Closing old host %s\n", currenthost); - (void) closesocket(sockfd); + printf("Closing old host %s\n", currenthost); + closesocket(sockfd); havehost = 0; } - (void) strcpy(currenthost, temphost); + strlcpy(currenthost, temphost, sizeof(currenthost)); /* port maps to the same location in both families */ - s_port = ((struct sockaddr_in6 *)ai->ai_addr)->sin6_port; + s_port = NSRCPORT(&addr); #ifdef SYS_VXWORKS ((struct sockaddr_in6 *)&hostaddr)->sin6_port = htons(SERVER_PORT_NUM); if (ai->ai_family == AF_INET) @@ -744,81 +702,118 @@ openhost( int optionValue = SO_SYNCHRONOUS_NONALERT; int err; - err = setsockopt(INVALID_SOCKET, SOL_SOCKET, SO_OPENTYPE, (char *)&optionValue, sizeof(optionValue)); - if (err != NO_ERROR) { - (void) fprintf(stderr, "cannot open nonoverlapped sockets\n"); + err = setsockopt(INVALID_SOCKET, SOL_SOCKET, SO_OPENTYPE, + (char *)&optionValue, sizeof(optionValue)); + if (err) { + mfprintf(stderr, + "setsockopt(SO_SYNCHRONOUS_NONALERT)" + " error: %m\n"); + freeaddrinfo(ai); exit(1); } } #endif /* SYS_WINNT */ - sockfd = socket(ai->ai_family, SOCK_DGRAM, 0); + sockfd = socket(ai->ai_family, ai->ai_socktype, + ai->ai_protocol); if (sockfd == INVALID_SOCKET) { - error("socket", "", ""); + error("socket"); + freeaddrinfo(ai); + return 0; } - + #ifdef NEED_RCVBUF_SLOP # ifdef SO_RCVBUF { int rbufsize = DATASIZE + 2048; /* 2K for slop */ if (setsockopt(sockfd, SOL_SOCKET, SO_RCVBUF, &rbufsize, sizeof(int)) == -1) - error("setsockopt", "", ""); + error("setsockopt"); } # endif #endif + if #ifdef SYS_VXWORKS - if (connect(sockfd, (struct sockaddr *)&hostaddr, + (connect(sockfd, (struct sockaddr *)&hostaddr, sizeof(hostaddr)) == -1) #else - if (connect(sockfd, (struct sockaddr *)ai->ai_addr, + (connect(sockfd, (struct sockaddr *)ai->ai_addr, ai->ai_addrlen) == -1) #endif /* SYS_VXWORKS */ - error("connect", "", ""); - if (a_info == 0) + { + error("connect"); freeaddrinfo(ai); + return 0; + } + freeaddrinfo(ai); havehost = 1; + numassoc = 0; + return 1; } +static void +dump_hex_printable( + const void * data, + size_t len + ) +{ + const char * cdata; + const char * rowstart; + size_t idx; + size_t rowlen; + u_char uch; + + cdata = data; + while (len > 0) { + rowstart = cdata; + rowlen = min(16, len); + for (idx = 0; idx < rowlen; idx++) { + uch = *(cdata++); + printf("%02x ", uch); + } + for ( ; idx < 16 ; idx++) + printf(" "); + cdata = rowstart; + for (idx = 0; idx < rowlen; idx++) { + uch = *(cdata++); + printf("%c", (isprint(uch)) + ? uch + : '.'); + } + printf("\n"); + len -= rowlen; + } +} + + /* XXX ELIMINATE sendpkt similar in ntpq.c, ntpdc.c, ntp_io.c, ntptrace.c */ /* * sendpkt - send a packet to the remote host */ static int sendpkt( - char *xdata, - int xdatalen + void * xdata, + size_t xdatalen ) { if (debug >= 3) - printf("Sending %d octets\n", xdatalen); - + printf("Sending %zu octets\n", xdatalen); if (send(sockfd, xdata, (size_t)xdatalen, 0) == -1) { - warning("write to %s failed", currenthost, ""); + warning("write to %s failed", currenthost); return -1; } if (debug >= 4) { - int first = 8; - printf("Packet data:\n"); - while (xdatalen-- > 0) { - if (first-- == 0) { - printf("\n"); - first = 7; - } - printf(" %02x", *xdata++ & 0xff); - } - printf("\n"); + printf("Request packet:\n"); + dump_hex_printable(xdata, xdatalen); } return 0; } - - /* * getresponse - get a (series of) response packet(s) and return the data */ @@ -828,20 +823,24 @@ getresponse( int associd, u_short *rstatus, int *rsize, - char **rdata, + const char **rdata, int timeo ) { struct ntp_control rpkt; - struct timeval tvo; + struct sock_timeval tvo; u_short offsets[MAXFRAGS+1]; u_short counts[MAXFRAGS+1]; u_short offset; u_short count; - int numfrags; + size_t numfrags; + size_t f; + size_t ff; int seenlastfrag; + int shouldbesize; fd_set fds; int n; + int errcode; /* * This is pretty tricky. We may get between 1 and MAXFRAG packets @@ -852,7 +851,7 @@ getresponse( */ *rsize = 0; if (rstatus) - *rstatus = 0; + *rstatus = 0; *rdata = (char *)pktdata; numfrags = 0; @@ -860,305 +859,308 @@ getresponse( FD_ZERO(&fds); - again: - if (numfrags == 0) - tvo = tvout; - else - tvo = tvsout; - - FD_SET(sockfd, &fds); - n = select(sockfd+1, &fds, (fd_set *)0, (fd_set *)0, &tvo); - -#if 0 - if (debug >= 1) - printf("select() returns %d\n", n); -#endif + /* + * Loop until we have an error or a complete response. Nearly all + * code paths to loop again use continue. + */ + for (;;) { - if (n == -1) { - warning("select fails", "", ""); - return -1; - } - if (n == 0) { - /* - * Timed out. Return what we have - */ - if (numfrags == 0) { - if (timeo) - (void) fprintf(stderr, - "%s: timed out, nothing received\n", - currenthost); - return ERR_TIMEOUT; - } else { + if (numfrags == 0) + tvo = tvout; + else + tvo = tvsout; + + FD_SET(sockfd, &fds); + n = select(sockfd + 1, &fds, NULL, NULL, &tvo); + + if (n == -1) { + warning("select fails"); + return -1; + } + if (n == 0) { + /* + * Timed out. Return what we have + */ + if (numfrags == 0) { + if (timeo) + fprintf(stderr, + "%s: timed out, nothing received\n", + currenthost); + return ERR_TIMEOUT; + } if (timeo) - (void) fprintf(stderr, - "%s: timed out with incomplete data\n", - currenthost); + fprintf(stderr, + "%s: timed out with incomplete data\n", + currenthost); if (debug) { - printf("Received fragments:\n"); - for (n = 0; n < numfrags; n++) - printf("%4d %d\n", offsets[n], - counts[n]); - if (seenlastfrag) - printf("last fragment received\n"); - else - printf("last fragment not received\n"); + fprintf(stderr, + "ERR_INCOMPLETE: Received fragments:\n"); + for (f = 0; f < numfrags; f++) + fprintf(stderr, + "%2u: %5d %5d\t%3d octets\n", + (u_int)f, offsets[f], + offsets[f] + + counts[f], + counts[f]); + fprintf(stderr, + "last fragment %sreceived\n", + (seenlastfrag) + ? "" + : "not "); } return ERR_INCOMPLETE; } - } - - n = recv(sockfd, (char *)&rpkt, sizeof(rpkt), 0); - if (n == -1) { - warning("read", "", ""); - return -1; - } - if (debug >= 4) { - int len = n, first = 8; - char *data = (char *)&rpkt; - - printf("Packet data:\n"); - while (len-- > 0) { - if (first-- == 0) { - printf("\n"); - first = 7; - } - printf(" %02x", *data++ & 0xff); + n = recv(sockfd, (char *)&rpkt, sizeof(rpkt), 0); + if (n == -1) { + warning("read"); + return -1; } - printf("\n"); - } - /* - * Check for format errors. Bug proofing. - */ - if (n < CTL_HEADER_LEN) { - if (debug) - printf("Short (%d byte) packet received\n", n); - goto again; - } - if (PKT_VERSION(rpkt.li_vn_mode) > NTP_VERSION - || PKT_VERSION(rpkt.li_vn_mode) < NTP_OLDVERSION) { - if (debug) - printf("Packet received with version %d\n", - PKT_VERSION(rpkt.li_vn_mode)); - goto again; - } - if (PKT_MODE(rpkt.li_vn_mode) != MODE_CONTROL) { - if (debug) - printf("Packet received with mode %d\n", - PKT_MODE(rpkt.li_vn_mode)); - goto again; - } - if (!CTL_ISRESPONSE(rpkt.r_m_e_op)) { - if (debug) - printf("Received request packet, wanted response\n"); - goto again; - } + if (debug >= 4) { + printf("Response packet:\n"); + dump_hex_printable(&rpkt, n); + } - /* - * Check opcode and sequence number for a match. - * Could be old data getting to us. - */ - if (ntohs(rpkt.sequence) != sequence) { - if (debug) - printf( - "Received sequnce number %d, wanted %d\n", - ntohs(rpkt.sequence), sequence); - goto again; - } - if (CTL_OP(rpkt.r_m_e_op) != opcode) { - if (debug) - printf( - "Received opcode %d, wanted %d (sequence number okay)\n", - CTL_OP(rpkt.r_m_e_op), opcode); - goto again; - } + /* + * Check for format errors. Bug proofing. + */ + if (n < (int)CTL_HEADER_LEN) { + if (debug) + printf("Short (%d byte) packet received\n", n); + continue; + } + if (PKT_VERSION(rpkt.li_vn_mode) > NTP_VERSION + || PKT_VERSION(rpkt.li_vn_mode) < NTP_OLDVERSION) { + if (debug) + printf("Packet received with version %d\n", + PKT_VERSION(rpkt.li_vn_mode)); + continue; + } + if (PKT_MODE(rpkt.li_vn_mode) != MODE_CONTROL) { + if (debug) + printf("Packet received with mode %d\n", + PKT_MODE(rpkt.li_vn_mode)); + continue; + } + if (!CTL_ISRESPONSE(rpkt.r_m_e_op)) { + if (debug) + printf("Received request packet, wanted response\n"); + continue; + } - /* - * Check the error code. If non-zero, return it. - */ - if (CTL_ISERROR(rpkt.r_m_e_op)) { - int errcode; + /* + * Check opcode and sequence number for a match. + * Could be old data getting to us. + */ + if (ntohs(rpkt.sequence) != sequence) { + if (debug) + printf("Received sequnce number %d, wanted %d\n", + ntohs(rpkt.sequence), sequence); + continue; + } + if (CTL_OP(rpkt.r_m_e_op) != opcode) { + if (debug) + printf( + "Received opcode %d, wanted %d (sequence number okay)\n", + CTL_OP(rpkt.r_m_e_op), opcode); + continue; + } - errcode = (ntohs(rpkt.status) >> 8) & 0xff; - if (debug && CTL_ISMORE(rpkt.r_m_e_op)) { - printf("Error code %d received on not-final packet\n", - errcode); + /* + * Check the error code. If non-zero, return it. + */ + if (CTL_ISERROR(rpkt.r_m_e_op)) { + errcode = (ntohs(rpkt.status) >> 8) & 0xff; + if (CTL_ISMORE(rpkt.r_m_e_op)) + TRACE(1, ("Error code %d received on not-final packet\n", + errcode)); + if (errcode == CERR_UNSPEC) + return ERR_UNSPEC; + return errcode; } - if (errcode == CERR_UNSPEC) - return ERR_UNSPEC; - return errcode; - } - /* - * Check the association ID to make sure it matches what - * we sent. - */ - if (ntohs(rpkt.associd) != associd) { - if (debug) - printf("Association ID %d doesn't match expected %d\n", - ntohs(rpkt.associd), associd); /* - * Hack for silly fuzzballs which, at the time of writing, - * return an assID of sys.peer when queried for system variables. + * Check the association ID to make sure it matches what + * we sent. */ + if (ntohs(rpkt.associd) != associd) { + TRACE(1, ("Association ID %d doesn't match expected %d\n", + ntohs(rpkt.associd), associd)); + /* + * Hack for silly fuzzballs which, at the time of writing, + * return an assID of sys.peer when queried for system variables. + */ #ifdef notdef - goto again; + continue; #endif - } - - /* - * Collect offset and count. Make sure they make sense. - */ - offset = ntohs(rpkt.offset); - count = ntohs(rpkt.count); + } - if (debug >= 3) { - int shouldbesize; - u_long key; - u_long *lpkt; - int maclen; + /* + * Collect offset and count. Make sure they make sense. + */ + offset = ntohs(rpkt.offset); + count = ntohs(rpkt.count); /* - * Usually we ignore authentication, but for debugging purposes - * we watch it here. + * validate received payload size is padded to next 32-bit + * boundary and no smaller than claimed by rpkt.count */ - shouldbesize = CTL_HEADER_LEN + count; + if (n & 0x3) { + TRACE(1, ("Response packet not padded, size = %d\n", + n)); + continue; + } - /* round to 8 octet boundary */ - shouldbesize = (shouldbesize + 7) & ~7; + shouldbesize = (CTL_HEADER_LEN + count + 3) & ~3; - if (n & 0x3) { - printf("Packet not padded, size = %d\n", n); - } if ((maclen = n - shouldbesize) >= MIN_MAC_LEN) { - printf( - "Packet shows signs of authentication (total %d, data %d, mac %d)\n", - n, shouldbesize, maclen); - lpkt = (u_long *)&rpkt; - printf("%08lx %08lx %08lx %08lx %08lx %08lx\n", - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) - 3]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) - 2]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) - 1]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long)]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) + 1]), - (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_long) + 2])); - key = ntohl(lpkt[(n - maclen) / sizeof(u_long)]); - printf("Authenticated with keyid %lu\n", (u_long)key); - if (key != 0 && key != info_auth_keyid) { - printf("We don't know that key\n"); - } else { - if (authdecrypt(key, (u_int32 *)&rpkt, - n - maclen, maclen)) { - printf("Auth okay!\n"); + if (n < shouldbesize) { + printf("Response packet claims %u octets payload, above %ld received\n", + count, (long)n - CTL_HEADER_LEN); + return ERR_INCOMPLETE; + } + + if (debug >= 3 && shouldbesize > n) { + u_int32 key; + u_int32 *lpkt; + int maclen; + + /* + * Usually we ignore authentication, but for debugging purposes + * we watch it here. + */ + /* round to 8 octet boundary */ + shouldbesize = (shouldbesize + 7) & ~7; + + maclen = n - shouldbesize; + if (maclen >= (int)MIN_MAC_LEN) { + printf( + "Packet shows signs of authentication (total %d, data %d, mac %d)\n", + n, shouldbesize, maclen); + lpkt = (u_int32 *)&rpkt; + printf("%08lx %08lx %08lx %08lx %08lx %08lx\n", + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) - 3]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) - 2]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) - 1]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32)]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) + 1]), + (u_long)ntohl(lpkt[(n - maclen)/sizeof(u_int32) + 2])); + key = ntohl(lpkt[(n - maclen) / sizeof(u_int32)]); + printf("Authenticated with keyid %lu\n", (u_long)key); + if (key != 0 && key != info_auth_keyid) { + printf("We don't know that key\n"); } else { - printf("Auth failed!\n"); + if (authdecrypt(key, (u_int32 *)&rpkt, + n - maclen, maclen)) { + printf("Auth okay!\n"); + } else { + printf("Auth failed!\n"); + } } } } - } - if (debug >= 2) - printf("Got packet, size = %d\n", n); - if (count > (u_short)(n-CTL_HEADER_LEN)) { - if (debug) - printf( - "Received count of %d octets, data in packet is %d\n", - count, n-CTL_HEADER_LEN); - goto again; - } - if (count == 0 && CTL_ISMORE(rpkt.r_m_e_op)) { - if (debug) - printf("Received count of 0 in non-final fragment\n"); - goto again; - } - if (offset + count > sizeof(pktdata)) { - if (debug) - printf("Offset %d, count %d, too big for buffer\n", - offset, count); - return ERR_TOOMUCH; - } - if (seenlastfrag && !CTL_ISMORE(rpkt.r_m_e_op)) { - if (debug) - printf("Received second last fragment packet\n"); - goto again; - } - - /* - * So far, so good. Record this fragment, making sure it doesn't - * overlap anything. - */ - if (debug >= 2) - printf("Packet okay\n");; - - if (numfrags == MAXFRAGS) { - if (debug) - printf("Number of fragments exceeds maximum\n"); - return ERR_TOOMUCH; - } - - for (n = 0; n < numfrags; n++) { - if (offset == offsets[n]) - goto again; /* duplicate */ - if (offset < offsets[n]) - break; - } - - if ((u_short)(n > 0 && offsets[n-1] + counts[n-1]) > offset) - goto overlap; - if (n < numfrags && (u_short)(offset + count) > offsets[n]) - goto overlap; - - { - register int i; - - for (i = numfrags; i > n; i--) { - offsets[i] = offsets[i-1]; - counts[i] = counts[i-1]; + TRACE(2, ("Got packet, size = %d\n", n)); + if (count > (n - CTL_HEADER_LEN)) { + TRACE(1, ("Received count of %u octets, data in packet is %ld\n", + count, (long)n - CTL_HEADER_LEN)); + continue; + } + if (count == 0 && CTL_ISMORE(rpkt.r_m_e_op)) { + TRACE(1, ("Received count of 0 in non-final fragment\n")); + continue; + } + if (offset + count > sizeof(pktdata)) { + TRACE(1, ("Offset %u, count %u, too big for buffer\n", + offset, count)); + return ERR_TOOMUCH; + } + if (seenlastfrag && !CTL_ISMORE(rpkt.r_m_e_op)) { + TRACE(1, ("Received second last fragment packet\n")); + continue; } - } - offsets[n] = offset; - counts[n] = count; - numfrags++; - /* - * Got that stuffed in right. Figure out if this was the last. - * Record status info out of the last packet. - */ - if (!CTL_ISMORE(rpkt.r_m_e_op)) { - seenlastfrag = 1; - if (rstatus != 0) - *rstatus = ntohs(rpkt.status); - } + /* + * So far, so good. Record this fragment, making sure it doesn't + * overlap anything. + */ + TRACE(2, ("Packet okay\n")); - /* - * Copy the data into the data buffer. - */ - memmove((char *)pktdata + offset, (char *)rpkt.data, count); + if (numfrags > (MAXFRAGS - 1)) { + TRACE(2, ("Number of fragments exceeds maximum %d\n", + MAXFRAGS - 1)); + return ERR_TOOMUCH; + } - /* - * If we've seen the last fragment, look for holes in the sequence. - * If there aren't any, we're done. - */ - if (seenlastfrag && offsets[0] == 0) { - for (n = 1; n < numfrags; n++) { - if (offsets[n-1] + counts[n-1] != offsets[n]) - break; + /* + * Find the position for the fragment relative to any + * previously received. + */ + for (f = 0; + f < numfrags && offsets[f] < offset; + f++) { + /* empty body */ ; } - if (n == numfrags) { - *rsize = offsets[numfrags-1] + counts[numfrags-1]; - return 0; + + if (f < numfrags && offset == offsets[f]) { + TRACE(1, ("duplicate %u octets at %u ignored, prior %u at %u\n", + count, offset, counts[f], offsets[f])); + continue; } - } - goto again; - overlap: - /* - * Print debugging message about overlapping fragments - */ - if (debug) - printf("Overlapping fragments returned in response\n"); - goto again; -} + if (f > 0 && (offsets[f-1] + counts[f-1]) > offset) { + TRACE(1, ("received frag at %u overlaps with %u octet frag at %u\n", + offset, counts[f-1], offsets[f-1])); + continue; + } + + if (f < numfrags && (offset + count) > offsets[f]) { + TRACE(1, ("received %u octet frag at %u overlaps with frag at %u\n", + count, offset, offsets[f])); + continue; + } + + for (ff = numfrags; ff > f; ff--) { + offsets[ff] = offsets[ff-1]; + counts[ff] = counts[ff-1]; + } + offsets[f] = offset; + counts[f] = count; + numfrags++; + + /* + * Got that stuffed in right. Figure out if this was the last. + * Record status info out of the last packet. + */ + if (!CTL_ISMORE(rpkt.r_m_e_op)) { + seenlastfrag = 1; + if (rstatus != 0) + *rstatus = ntohs(rpkt.status); + } + + /* + * Copy the data into the data buffer. + */ + memcpy((char *)pktdata + offset, &rpkt.u, count); + + /* + * If we've seen the last fragment, look for holes in the sequence. + * If there aren't any, we're done. + */ + if (seenlastfrag && offsets[0] == 0) { + for (f = 1; f < numfrags; f++) + if (offsets[f-1] + counts[f-1] != + offsets[f]) + break; + if (f == numfrags) { + *rsize = offsets[f-1] + counts[f-1]; + TRACE(1, ("%lu packets reassembled into response\n", + (u_long)numfrags)); + return 0; + } + } + } /* giant for (;;) collecting response packets */ +} /* getresponse() */ /* @@ -1167,22 +1169,25 @@ getresponse( static int sendrequest( int opcode, - int associd, + associd_t associd, int auth, int qsize, - char *qdata + const char *qdata ) { struct ntp_control qpkt; - int pktsize; + int pktsize; + u_long key_id; + char * pass; + int maclen; /* * Check to make sure the data will fit in one packet */ if (qsize > CTL_MAX_DATA_LEN) { - (void) fprintf(stderr, - "***Internal error! qsize (%d) too large\n", - qsize); + fprintf(stderr, + "***Internal error! qsize (%d) too large\n", + qsize); return 1; } @@ -1197,19 +1202,18 @@ sendrequest( qpkt.offset = 0; qpkt.count = htons((u_short)qsize); + pktsize = CTL_HEADER_LEN; + /* - * If we have data, copy it in and pad it out to a 64 - * bit boundary. + * If we have data, copy and pad it out to a 32-bit boundary. */ if (qsize > 0) { - memmove((char *)qpkt.data, qdata, (unsigned)qsize); - pktsize = qsize + CTL_HEADER_LEN; - while (pktsize & (sizeof(u_long) - 1)) { - qpkt.data[qsize++] = 0; + memcpy(&qpkt.u, qdata, (size_t)qsize); + pktsize += qsize; + while (pktsize & (sizeof(u_int32) - 1)) { + qpkt.u.data[qsize++] = 0; pktsize++; } - } else { - pktsize = CTL_HEADER_LEN; } /* @@ -1217,76 +1221,167 @@ sendrequest( * we're going to have to think about it a little. */ if (!auth && !always_auth) { - return sendpkt((char *)&qpkt, pktsize); - } else { - const char *pass = "\0"; - int maclen = 0; - u_long my_keyid; + return sendpkt(&qpkt, pktsize); + } - /* - * Pad out packet to a multiple of 8 octets to be sure - * receiver can handle it. - */ - while (pktsize & 7) { - qpkt.data[qsize++] = 0; - pktsize++; - } + /* + * Pad out packet to a multiple of 8 octets to be sure + * receiver can handle it. + */ + while (pktsize & 7) { + qpkt.u.data[qsize++] = 0; + pktsize++; + } - /* - * Get the keyid and the password if we don't have one. - */ - if (info_auth_keyid == 0) { - int u_keyid = getkeyid("Keyid: "); - if (u_keyid == 0 || u_keyid > NTP_MAXKEY) { - (void) fprintf(stderr, - "Invalid key identifier\n"); - return 1; - } - info_auth_keyid = u_keyid; - } - if (!authistrusted(info_auth_keyid)) { - pass = getpass("MD5 Password: "); - if (*pass == '\0') { - (void) fprintf(stderr, - "Invalid password\n"); - return (1); - } + /* + * Get the keyid and the password if we don't have one. + */ + if (info_auth_keyid == 0) { + key_id = getkeyid("Keyid: "); + if (key_id == 0 || key_id > NTP_MAXKEY) { + fprintf(stderr, + "Invalid key identifier\n"); + return 1; } - authusekey(info_auth_keyid, info_auth_keytype, (const u_char *)pass); + info_auth_keyid = key_id; + } + if (!authistrusted(info_auth_keyid)) { + pass = getpass_keytype(info_auth_keytype); + if ('\0' == pass[0]) { + fprintf(stderr, "Invalid password\n"); + return 1; + } + authusekey(info_auth_keyid, info_auth_keytype, + (u_char *)pass); authtrust(info_auth_keyid, 1); + } - /* - * Stick the keyid in the packet where - * cp currently points. Cp should be aligned - * properly. Then do the encryptions. - */ - my_keyid = htonl(info_auth_keyid); - memcpy(&qpkt.data[qsize], &my_keyid, sizeof my_keyid); - maclen = authencrypt(info_auth_keyid, (u_int32 *)&qpkt, - pktsize); - if (maclen == 0) { - (void) fprintf(stderr, "Key not found\n"); - return (1); - } - return sendpkt((char *)&qpkt, pktsize + maclen); + /* + * Do the encryption. + */ + maclen = authencrypt(info_auth_keyid, (void *)&qpkt, pktsize); + if (!maclen) { + fprintf(stderr, "Key not found\n"); + return 1; + } else if ((size_t)maclen != (info_auth_hashlen + sizeof(keyid_t))) { + fprintf(stderr, + "%d octet MAC, %zu expected with %zu octet digest\n", + maclen, (info_auth_hashlen + sizeof(keyid_t)), + info_auth_hashlen); + return 1; } - /*NOTREACHED*/ + + return sendpkt((char *)&qpkt, pktsize + maclen); } /* - * doquery - send a request and process the response + * show_error_msg - display the error text for a mode 6 error response. + */ +void +show_error_msg( + int m6resp, + associd_t associd + ) +{ + if (numhosts > 1) + fprintf(stderr, "server=%s ", currenthost); + + switch(m6resp) { + + case CERR_BADFMT: + fprintf(stderr, + "***Server reports a bad format request packet\n"); + break; + + case CERR_PERMISSION: + fprintf(stderr, + "***Server disallowed request (authentication?)\n"); + break; + + case CERR_BADOP: + fprintf(stderr, + "***Server reports a bad opcode in request\n"); + break; + + case CERR_BADASSOC: + fprintf(stderr, + "***Association ID %d unknown to server\n", + associd); + break; + + case CERR_UNKNOWNVAR: + fprintf(stderr, + "***A request variable unknown to the server\n"); + break; + + case CERR_BADVALUE: + fprintf(stderr, + "***Server indicates a request variable was bad\n"); + break; + + case ERR_UNSPEC: + fprintf(stderr, + "***Server returned an unspecified error\n"); + break; + + case ERR_TIMEOUT: + fprintf(stderr, "***Request timed out\n"); + break; + + case ERR_INCOMPLETE: + fprintf(stderr, + "***Response from server was incomplete\n"); + break; + + case ERR_TOOMUCH: + fprintf(stderr, + "***Buffer size exceeded for returned data\n"); + break; + + default: + fprintf(stderr, + "***Server returns unknown error code %d\n", + m6resp); + } +} + +/* + * doquery - send a request and process the response, displaying + * error messages for any error responses. */ int doquery( int opcode, - int associd, + associd_t associd, + int auth, + int qsize, + const char *qdata, + u_short *rstatus, + int *rsize, + const char **rdata + ) +{ + return doqueryex(opcode, associd, auth, qsize, qdata, rstatus, + rsize, rdata, FALSE); +} + + +/* + * doqueryex - send a request and process the response, optionally + * displaying error messages for any error responses. + */ +int +doqueryex( + int opcode, + associd_t associd, int auth, int qsize, - char *qdata, + const char *qdata, u_short *rstatus, int *rsize, - char **rdata + const char **rdata, + int quiet ) { int res; @@ -1296,7 +1391,7 @@ doquery( * Check to make sure host is open */ if (!havehost) { - (void) fprintf(stderr, "***No host open, use `host' command\n"); + fprintf(stderr, "***No host open, use `host' command\n"); return -1; } @@ -1309,8 +1404,8 @@ doquery( */ res = sendrequest(opcode, associd, auth, qsize, qdata); if (res != 0) - return res; - + return res; + /* * Get the response. If we got a standard error, print a message */ @@ -1328,94 +1423,40 @@ doquery( done = 1; goto again; } - if (numhosts > 1) - (void) fprintf(stderr, "server=%s ", currenthost); - switch(res) { - case CERR_BADFMT: - (void) fprintf(stderr, - "***Server reports a bad format request packet\n"); - break; - case CERR_PERMISSION: - (void) fprintf(stderr, - "***Server disallowed request (authentication?)\n"); - break; - case CERR_BADOP: - (void) fprintf(stderr, - "***Server reports a bad opcode in request\n"); - break; - case CERR_BADASSOC: - (void) fprintf(stderr, - "***Association ID %d unknown to server\n",associd); - break; - case CERR_UNKNOWNVAR: - (void) fprintf(stderr, - "***A request variable unknown to the server\n"); - break; - case CERR_BADVALUE: - (void) fprintf(stderr, - "***Server indicates a request variable was bad\n"); - break; - case ERR_UNSPEC: - (void) fprintf(stderr, - "***Server returned an unspecified error\n"); - break; - case ERR_TIMEOUT: - (void) fprintf(stderr, "***Request timed out\n"); - break; - case ERR_INCOMPLETE: - (void) fprintf(stderr, - "***Response from server was incomplete\n"); - break; - case ERR_TOOMUCH: - (void) fprintf(stderr, - "***Buffer size exceeded for returned data\n"); - break; - default: - (void) fprintf(stderr, - "***Server returns unknown error code %d\n", res); - break; - } + if (!quiet) + show_error_msg(res, associd); + } return res; } +#ifndef BUILD_AS_LIB /* * getcmds - read commands from the standard input and execute them */ static void getcmds(void) { -#if defined(HAVE_LIBREADLINE) || defined(HAVE_LIBEDIT) - char *line; - - for (;;) { - if ((line = readline(interactive?prompt:"")) == NULL) return; - if (*line) add_history(line); - docmd(line); - free(line); - } -#else /* not (HAVE_LIBREADLINE || HAVE_LIBEDIT) */ - char line[MAXLINE]; - - for (;;) { - if (interactive) { -#ifdef VMS /* work around a problem with mixing stdout & stderr */ - fputs("",stdout); -#endif - (void) fputs(prompt, stderr); - (void) fflush(stderr); - } + char * line; + int count; + + ntp_readline_init(interactive ? prompt : NULL); - if (fgets(line, sizeof line, stdin) == NULL) - return; + for (;;) { + line = ntp_readline(&count); + if (NULL == line) + break; + docmd(line); + free(line); + } - docmd(line); - } -#endif /* not (HAVE_LIBREADLINE || HAVE_LIBEDIT) */ + ntp_readline_uninit(); } +#endif /* !BUILD_AS_LIB */ -#ifndef SYS_WINNT /* Under NT cannot handle SIGINT, WIN32 spawns a handler */ + +#if !defined(SYS_WINNT) && !defined(BUILD_AS_LIB) /* * abortcmd - catch interrupts and abort the current command */ @@ -1430,8 +1471,10 @@ abortcmd( (void) fflush(stderr); if (jump) longjmp(interrupt_buf, 1); } -#endif /* SYS_WINNT */ +#endif /* !SYS_WINNT && !BUILD_AS_LIB */ + +#ifndef BUILD_AS_LIB /* * docmd - decode the command line and execute a command */ @@ -1452,7 +1495,7 @@ docmd( tokenize(cmdline, tokens, &ntok); if (ntok == 0) return; - + /* * Find the appropriate command description. */ @@ -1466,7 +1509,12 @@ docmd( tokens[0]); return; } - + + /* Warn about ignored extra args */ + for (i = MAXARGS + 1; i < ntok ; ++i) { + fprintf(stderr, "***Extra arg `%s' ignored\n", tokens[i]); + } + /* * Save the keyword, then walk through the arguments, interpreting * as we go. @@ -1482,9 +1530,9 @@ docmd( break; } if ((xcmd->arg[i] & OPT) && (*tokens[i+1] == '>')) - break; + break; if (!getarg(tokens[i+1], (int)xcmd->arg[i], &pcmd.argval[i])) - return; + return; pcmd.nargs++; } @@ -1493,9 +1541,9 @@ docmd( char *fname; if (*(tokens[i]+1) != '\0') - fname = tokens[i]+1; + fname = tokens[i]+1; else if ((i+1) < ntok) - fname = tokens[i+1]; + fname = tokens[i+1]; else { (void) fprintf(stderr, "***No file for redirect\n"); return; @@ -1522,12 +1570,20 @@ docmd( jump = 0; /* HMS: 961106: was after fclose() */ if (i) (void) fclose(current_output); } + + return; } /* * tokenize - turn a command line into tokens + * + * SK: Modified to allow a quoted string + * + * HMS: If the first character of the first token is a ':' then (after + * eating inter-token whitespace) the 2nd token is the rest of the line. */ + static void tokenize( const char *line, @@ -1543,33 +1599,151 @@ tokenize( cp = line; for (*ntok = 0; *ntok < MAXTOKENS; (*ntok)++) { tokens[*ntok] = sp; + + /* Skip inter-token whitespace */ while (ISSPACE(*cp)) cp++; + + /* If we're at EOL we're done */ if (ISEOL(*cp)) break; - do { - *sp++ = *cp++; - } while (!ISSPACE(*cp) && !ISEOL(*cp)); + /* If this is the 2nd token and the first token begins + * with a ':', then just grab to EOL. + */ + + if (*ntok == 1 && tokens[0][0] == ':') { + do { + if (sp - tspace >= MAXLINE) + goto toobig; + *sp++ = *cp++; + } while (!ISEOL(*cp)); + } + + /* Check if this token begins with a double quote. + * If yes, continue reading till the next double quote + */ + else if (*cp == '\"') { + ++cp; + do { + if (sp - tspace >= MAXLINE) + goto toobig; + *sp++ = *cp++; + } while ((*cp != '\"') && !ISEOL(*cp)); + /* HMS: a missing closing " should be an error */ + } + else { + do { + if (sp - tspace >= MAXLINE) + goto toobig; + *sp++ = *cp++; + } while ((*cp != '\"') && !ISSPACE(*cp) && !ISEOL(*cp)); + /* HMS: Why check for a " in the previous line? */ + } + + if (sp - tspace >= MAXLINE) + goto toobig; *sp++ = '\0'; } + return; + + toobig: + *ntok = 0; + fprintf(stderr, + "***Line `%s' is too big\n", + line); + return; } +/* + * getarg - interpret an argument token + */ +static int +getarg( + const char *str, + int code, + arg_v *argp + ) +{ + u_long ul; + + switch (code & ~OPT) { + case NTP_STR: + argp->string = str; + break; + + case NTP_ADD: + if (!getnetnum(str, &argp->netnum, NULL, 0)) + return 0; + break; + + case NTP_UINT: + if ('&' == str[0]) { + if (!atouint(&str[1], &ul)) { + fprintf(stderr, + "***Association index `%s' invalid/undecodable\n", + str); + return 0; + } + if (0 == numassoc) { + dogetassoc(stdout); + if (0 == numassoc) { + fprintf(stderr, + "***No associations found, `%s' unknown\n", + str); + return 0; + } + } + ul = min(ul, numassoc); + argp->uval = assoc_cache[ul - 1].assid; + break; + } + if (!atouint(str, &argp->uval)) { + fprintf(stderr, "***Illegal unsigned value %s\n", + str); + return 0; + } + break; + + case NTP_INT: + if (!atoint(str, &argp->ival)) { + fprintf(stderr, "***Illegal integer value %s\n", + str); + return 0; + } + break; + + case IP_VERSION: + if (!strcmp("-6", str)) { + argp->ival = 6; + } else if (!strcmp("-4", str)) { + argp->ival = 4; + } else { + fprintf(stderr, "***Version must be either 4 or 6\n"); + return 0; + } + break; + } + + return 1; +} +#endif /* !BUILD_AS_LIB */ + /* * findcmd - find a command in a command description table */ static int findcmd( - register char *str, - struct xcmd *clist1, - struct xcmd *clist2, - struct xcmd **cmd + const char * str, + struct xcmd * clist1, + struct xcmd * clist2, + struct xcmd ** cmd ) { - register struct xcmd *cl; - register int clen; + struct xcmd *cl; + int clen; int nmatch; struct xcmd *nearmatch = NULL; struct xcmd *clist; @@ -1624,98 +1798,6 @@ findcmd( } -/* - * getarg - interpret an argument token - */ -static int -getarg( - char *str, - int code, - arg_v *argp - ) -{ - int isneg; - char *cp, *np; - static const char *digits = "0123456789"; - - switch (code & ~OPT) { - case NTP_STR: - argp->string = str; - break; - case NTP_ADD: - if (!getnetnum(str, &(argp->netnum), (char *)0, 0)) { - return 0; - } - break; - case NTP_INT: - case NTP_UINT: - isneg = 0; - np = str; - if (*np == '&') { - np++; - isneg = atoi(np); - if (isneg <= 0) { - (void) fprintf(stderr, - "***Association value `%s' invalid/undecodable\n", str); - return 0; - } - if (isneg > numassoc) { - if (numassoc == 0) { - (void) fprintf(stderr, - "***Association for `%s' unknown (max &%d)\n", - str, numassoc); - return 0; - } else { - isneg = numassoc; - } - } - argp->uval = assoc_cache[isneg-1].assid; - break; - } - - if (*np == '-') { - np++; - isneg = 1; - } - - argp->uval = 0; - do { - cp = strchr(digits, *np); - if (cp == NULL) { - (void) fprintf(stderr, - "***Illegal integer value %s\n", str); - return 0; - } - argp->uval *= 10; - argp->uval += (cp - digits); - } while (*(++np) != '\0'); - - if (isneg) { - if ((code & ~OPT) == NTP_UINT) { - (void) fprintf(stderr, - "***Value %s should be unsigned\n", str); - return 0; - } - argp->ival = -argp->ival; - } - break; - case IP_VERSION: - if (!strcmp("-6", str)) - argp->ival = 6 ; - else if (!strcmp("-4", str)) - argp->ival = 4 ; - else { - (void) fprintf(stderr, - "***Version must be either 4 or 6\n"); - return 0; - } - break; - } - - return 1; -} - - /* * getnetnum - given a host name, return its net number * and (optional) full name @@ -1723,59 +1805,116 @@ getarg( int getnetnum( const char *hname, - struct sockaddr_storage *num, + sockaddr_u *num, char *fullhost, int af ) { - int sockaddr_len; struct addrinfo hints, *ai = NULL; - sockaddr_len = (af == AF_INET) - ? sizeof(struct sockaddr_in) - : sizeof(struct sockaddr_in6); - memset((char *)&hints, 0, sizeof(struct addrinfo)); + ZERO(hints); hints.ai_flags = AI_CANONNAME; #ifdef AI_ADDRCONFIG hints.ai_flags |= AI_ADDRCONFIG; #endif - - /* decodenetnum works with addresses only */ + + /* + * decodenetnum only works with addresses, but handles syntax + * that getaddrinfo doesn't: [2001::1]:1234 + */ if (decodenetnum(hname, num)) { - if (fullhost != 0) { - getnameinfo((struct sockaddr *)num, sockaddr_len, - fullhost, sizeof(fullhost), NULL, 0, - NI_NUMERICHOST); - } + if (fullhost != NULL) + getnameinfo(&num->sa, SOCKLEN(num), fullhost, + LENHOSTNAME, NULL, 0, 0); return 1; } else if (getaddrinfo(hname, "ntp", &hints, &ai) == 0) { - memmove((char *)num, ai->ai_addr, ai->ai_addrlen); - if (ai->ai_canonname != 0) - (void) strcpy(fullhost, ai->ai_canonname); + INSIST(sizeof(*num) >= ai->ai_addrlen); + memcpy(num, ai->ai_addr, ai->ai_addrlen); + if (fullhost != NULL) { + if (ai->ai_canonname != NULL) + strlcpy(fullhost, ai->ai_canonname, + LENHOSTNAME); + else + getnameinfo(&num->sa, SOCKLEN(num), + fullhost, LENHOSTNAME, NULL, + 0, 0); + } + freeaddrinfo(ai); return 1; + } + fprintf(stderr, "***Can't find host %s\n", hname); + + return 0; +} + + +/* + * nntohost - convert network number to host name. This routine enforces + * the showhostnames setting. + */ +const char * +nntohost( + sockaddr_u *netnum + ) +{ + return nntohost_col(netnum, LIB_BUFLENGTH - 1, FALSE); +} + + +/* + * nntohost_col - convert network number to host name in fixed width. + * This routine enforces the showhostnames setting. + * When displaying hostnames longer than the width, + * the first part of the hostname is displayed. When + * displaying numeric addresses longer than the width, + * Such as IPv6 addresses, the caller decides whether + * the first or last of the numeric address is used. + */ +const char * +nntohost_col( + sockaddr_u * addr, + size_t width, + int preserve_lowaddrbits + ) +{ + const char * out; + + if (!showhostnames || SOCK_UNSPEC(addr)) { + if (preserve_lowaddrbits) + out = trunc_left(stoa(addr), width); + else + out = trunc_right(stoa(addr), width); + } else if (ISREFCLOCKADR(addr)) { + out = refnumtoa(addr); } else { - (void) fprintf(stderr, "***Can't find host %s\n", hname); - return 0; + out = trunc_right(socktohost(addr), width); } - /*NOTREACHED*/ + return out; } + /* - * nntohost - convert network number to host name. This routine enforces - * the showhostnames setting. + * nntohostp() is the same as nntohost() plus a :port suffix */ -char * -nntohost( - struct sockaddr_storage *netnum +const char * +nntohostp( + sockaddr_u *netnum ) { - if (!showhostnames) - return stoa(netnum); - if ((netnum->ss_family == AF_INET) && ISREFCLOCKADR(netnum)) - return refnumtoa(netnum); - return socktohost(netnum); -} + const char * hostn; + char * buf; + + if (!showhostnames || SOCK_UNSPEC(netnum)) + return sptoa(netnum); + else if (ISREFCLOCKADR(netnum)) + return refnumtoa(netnum); + + hostn = socktohost(netnum); + LIB_GETBUF(buf); + snprintf(buf, LIB_BUFLENGTH, "%s:%u", hostn, SRCPORT(netnum)); + return buf; +} /* * rtdatetolfp - decode an RT-11 date into an l_fp @@ -1790,10 +1929,6 @@ rtdatetolfp( register int i; struct calendar cal; char buf[4]; - static const char *months[12] = { - "Jan", "Feb", "Mar", "Apr", "May", "Jun", - "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" - }; cal.yearday = 0; @@ -1826,7 +1961,7 @@ rtdatetolfp( if (*cp++ != '-') return 0; - + for (i = 0; i < 3; i++) buf[i] = *cp++; buf[3] = '\0'; @@ -1840,7 +1975,7 @@ rtdatetolfp( if (*cp++ != '-') return 0; - + if (!isdigit((int)*cp)) return 0; cal.year = (u_short)(*cp++ - '0'); @@ -1913,24 +2048,26 @@ decodets( l_fp *lfp ) { + char *cp; + char buf[30]; + size_t b; + /* * If it starts with a 0x, decode as hex. */ if (*str == '0' && (*(str+1) == 'x' || *(str+1) == 'X')) - return hextolfp(str+2, lfp); + return hextolfp(str+2, lfp); /* * If it starts with a '"', try it as an RT-11 date. */ if (*str == '"') { - register char *cp = str+1; - register char *bp; - char buf[30]; - - bp = buf; - while (*cp != '"' && *cp != '\0' && bp < &buf[29]) - *bp++ = *cp++; - *bp = '\0'; + cp = str + 1; + b = 0; + while ('"' != *cp && '\0' != *cp && + b < COUNTOF(buf) - 1) + buf[b++] = *cp++; + buf[b] = '\0'; return rtdatetolfp(buf, lfp); } @@ -1939,14 +2076,15 @@ decodets( * about heuristics! */ if ((*str >= 'A' && *str <= 'F') || (*str >= 'a' && *str <= 'f')) - return hextolfp(str, lfp); + return hextolfp(str, lfp); /* * Try it as a decimal. If this fails, try as an unquoted * RT-11 date. This code should go away eventually. */ if (atolfp(str, lfp)) - return 1; + return 1; + return rtdatetolfp(str, lfp); } @@ -1975,8 +2113,8 @@ decodeint( { if (*str == '0') { if (*(str+1) == 'x' || *(str+1) == 'X') - return hextoint(str+2, val); - return octtoint(str, val); + return hextoint(str+2, (u_long *)val); + return octtoint(str, (u_long *)val); } return atoint(str, val); } @@ -2051,61 +2189,56 @@ help( FILE *fp ) { - struct xcmd *xcp; - char *cmd; + struct xcmd *xcp = NULL; /* quiet warning */ + const char *cmd; const char *list[100]; - int word, words; - int row, rows; - int col, cols; + size_t word, words; + size_t row, rows; + size_t col, cols; + size_t length; if (pcmd->nargs == 0) { words = 0; - for (xcp = builtins; xcp->keyword != 0; xcp++) { - if (*(xcp->keyword) != '?') - list[words++] = xcp->keyword; + for (xcp = builtins; xcp->keyword != NULL; xcp++) { + if (*(xcp->keyword) != '?' && + words < COUNTOF(list)) + list[words++] = xcp->keyword; } - for (xcp = opcmds; xcp->keyword != 0; xcp++) - list[words++] = xcp->keyword; + for (xcp = opcmds; xcp->keyword != NULL; xcp++) + if (words < COUNTOF(list)) + list[words++] = xcp->keyword; - qsort( -#ifdef QSORT_USES_VOID_P - (void *) -#else - (char *) -#endif - (list), (size_t)(words), sizeof(char *), helpsort); + qsort((void *)list, words, sizeof(list[0]), helpsort); col = 0; for (word = 0; word < words; word++) { - int length = strlen(list[word]); - if (col < length) { - col = length; - } + length = strlen(list[word]); + col = max(col, length); } cols = SCREENWIDTH / ++col; - rows = (words + cols - 1) / cols; + rows = (words + cols - 1) / cols; - (void) fprintf(fp, "ntpq commands:\n"); + fprintf(fp, "ntpq commands:\n"); for (row = 0; row < rows; row++) { - for (word = row; word < words; word += rows) { - (void) fprintf(fp, "%-*.*s", col, col-1, list[word]); - } - (void) fprintf(fp, "\n"); - } + for (word = row; word < words; word += rows) + fprintf(fp, "%-*.*s", (int)col, + (int)col - 1, list[word]); + fprintf(fp, "\n"); + } } else { cmd = pcmd->argval[0].string; words = findcmd(cmd, builtins, opcmds, &xcp); if (words == 0) { - (void) fprintf(stderr, - "Command `%s' is unknown\n", cmd); + fprintf(stderr, + "Command `%s' is unknown\n", cmd); return; } else if (words >= 2) { - (void) fprintf(stderr, - "Command `%s' is ambiguous\n", cmd); + fprintf(stderr, + "Command `%s' is ambiguous\n", cmd); return; } - (void) fprintf(fp, "function: %s\n", xcp->comment); + fprintf(fp, "function: %s\n", xcp->comment); printusage(xcp, fp); } } @@ -2114,29 +2247,18 @@ help( /* * helpsort - do hostname qsort comparisons */ -#ifdef QSORT_USES_VOID_P static int helpsort( const void *t1, const void *t2 ) { - char const * const * name1 = (char const * const *)t1; - char const * const * name2 = (char const * const *)t2; + const char * const * name1 = t1; + const char * const * name2 = t2; return strcmp(*name1, *name2); } -#else -static int -helpsort( - char **name1, - char **name2 - ) -{ - return strcmp(*name1, *name2); -} -#endif /* * printusage - print usage information for a command @@ -2149,6 +2271,8 @@ printusage( { register int i; + /* XXX: Do we need to warn about extra args here too? */ + (void) fprintf(fp, "usage: %s", xcp->keyword); for (i = 0; i < MAXARGS && xcp->arg[i] != NO; i++) { if (xcp->arg[i] & OPT) @@ -2172,11 +2296,11 @@ timeout( int val; if (pcmd->nargs == 0) { - val = tvout.tv_sec * 1000 + tvout.tv_usec / 1000; + val = (int)tvout.tv_sec * 1000 + tvout.tv_usec / 1000; (void) fprintf(fp, "primary timeout %d ms\n", val); } else { tvout.tv_sec = pcmd->argval[0].uval / 1000; - tvout.tv_usec = (pcmd->argval[0].uval - (tvout.tv_sec * 1000)) + tvout.tv_usec = (pcmd->argval[0].uval - ((long)tvout.tv_sec * 1000)) * 1000; } } @@ -2229,9 +2353,10 @@ host( if (pcmd->nargs == 0) { if (havehost) - (void) fprintf(fp, "current host is %s\n", currenthost); + (void) fprintf(fp, "current host is %s\n", + currenthost); else - (void) fprintf(fp, "no current host\n"); + (void) fprintf(fp, "no current host\n"); return; } @@ -2242,25 +2367,19 @@ host( ai_fam_templ = AF_INET; else if (!strcmp("-6", pcmd->argval[i].string)) ai_fam_templ = AF_INET6; - else { - if (havehost) - (void) fprintf(fp, - "current host remains %s\n", currenthost); - else - (void) fprintf(fp, "still no current host\n"); - return; - } + else + goto no_change; i = 1; } - if (openhost(pcmd->argval[i].string)) { - (void) fprintf(fp, "current host set to %s\n", currenthost); - numassoc = 0; + if (openhost(pcmd->argval[i].string, ai_fam_templ)) { + fprintf(fp, "current host set to %s\n", currenthost); } else { + no_change: if (havehost) - (void) fprintf(fp, - "current host remains %s\n", currenthost); + fprintf(fp, "current host remains %s\n", + currenthost); else - (void) fprintf(fp, "still no current host\n"); + fprintf(fp, "still no current host\n"); } } @@ -2310,21 +2429,34 @@ keytype( FILE *fp ) { - if (pcmd->nargs == 0) - fprintf(fp, "keytype is %s\n", - (info_auth_keytype == KEY_TYPE_MD5) ? "MD5" : "???"); - else - switch (*(pcmd->argval[0].string)) { - case 'm': - case 'M': - info_auth_keytype = KEY_TYPE_MD5; - break; + const char * digest_name; + size_t digest_len; + int key_type; + + if (!pcmd->nargs) { + fprintf(fp, "keytype is %s with %lu octet digests\n", + keytype_name(info_auth_keytype), + (u_long)info_auth_hashlen); + return; + } - default: - fprintf(fp, "keytype must be 'md5'\n"); - } -} + digest_name = pcmd->argval[0].string; + digest_len = 0; + key_type = keytype_from_text(digest_name, &digest_len); + + if (!key_type) { + fprintf(fp, "keytype is not valid. " +#ifdef OPENSSL + "Type \"help keytype\" for the available digest types.\n"); +#else + "Only \"md5\" is available.\n"); +#endif + return; + } + info_auth_keytype = key_type; + info_auth_hashlen = digest_len; +} /* @@ -2337,23 +2469,27 @@ passwd( FILE *fp ) { - char *pass; + const char *pass; if (info_auth_keyid == 0) { - int u_keyid = getkeyid("Keyid: "); - if (u_keyid == 0 || u_keyid > NTP_MAXKEY) { - (void)fprintf(fp, "Invalid key identifier\n"); + info_auth_keyid = getkeyid("Keyid: "); + if (info_auth_keyid == 0) { + (void)fprintf(fp, "Keyid must be defined\n"); return; } - info_auth_keyid = u_keyid; } - pass = getpass("MD5 Password: "); - if (*pass == '\0') - (void) fprintf(fp, "Password unchanged\n"); + if (pcmd->nargs >= 1) + pass = pcmd->argval[0].string; else { - authusekey(info_auth_keyid, info_auth_keytype, (u_char *)pass); - authtrust(info_auth_keyid, 1); + pass = getpass_keytype(info_auth_keytype); + if ('\0' == pass[0]) { + fprintf(fp, "Password unchanged\n"); + return; + } } + authusekey(info_auth_keyid, info_auth_keytype, + (const u_char *)pass); + authtrust(info_auth_keyid, 1); } @@ -2523,37 +2659,46 @@ ntpversion( } +static void __attribute__((__format__(__printf__, 1, 0))) +vwarning(const char *fmt, va_list ap) +{ + int serrno = errno; + (void) fprintf(stderr, "%s: ", progname); + vfprintf(stderr, fmt, ap); + (void) fprintf(stderr, ": %s", strerror(serrno)); +} + /* * warning - print a warning message */ -static void +static void __attribute__((__format__(__printf__, 1, 2))) warning( const char *fmt, - const char *st1, - const char *st2 + ... ) { - (void) fprintf(stderr, "%s: ", progname); - (void) fprintf(stderr, fmt, st1, st2); - (void) fprintf(stderr, ": "); - perror(""); + va_list ap; + va_start(ap, fmt); + vwarning(fmt, ap); + va_end(ap); } /* * error - print a message and exit */ -static void +static void __attribute__((__format__(__printf__, 1, 2))) error( const char *fmt, - const char *st1, - const char *st2 + ... ) { - warning(fmt, st1, st2); + va_list ap; + va_start(ap, fmt); + vwarning(fmt, ap); + va_end(ap); exit(1); } - /* * getkeyid - prompt the user for a keyid to use */ @@ -2562,29 +2707,28 @@ getkeyid( const char *keyprompt ) { - register char *p; - register int c; + int c; FILE *fi; char pbuf[20]; + size_t i; + size_t ilim; #ifndef SYS_WINNT if ((fi = fdopen(open("/dev/tty", 2), "r")) == NULL) #else - if ((fi = _fdopen((int)GetStdHandle(STD_INPUT_HANDLE), "r")) == NULL) + if ((fi = _fdopen(open("CONIN$", _O_TEXT), "r")) == NULL) #endif /* SYS_WINNT */ fi = stdin; - else + else setbuf(fi, (char *)NULL); fprintf(stderr, "%s", keyprompt); fflush(stderr); - for (p=pbuf; (c = getc(fi))!='\n' && c!=EOF;) { - if (p < &pbuf[18]) - *p++ = (char)c; - } - *p = '\0'; + for (i = 0, ilim = COUNTOF(pbuf) - 1; + i < ilim && (c = getc(fi)) != '\n' && c != EOF; + ) + pbuf[i++] = (char)c; + pbuf[i] = '\0'; if (fi != stdin) - fclose(fi); - if (strcmp(pbuf, "0") == 0) - return 0; + fclose(fi); return (u_long) atoi(pbuf); } @@ -2596,82 +2740,93 @@ getkeyid( */ static void atoascii( - int length, - char *data, - char *outdata + const char *in, + size_t in_octets, + char *out, + size_t out_octets ) { - register u_char *cp; - register u_char *ocp; - register u_char c; - - if (!data) - { - *outdata = '\0'; + const u_char * pchIn; + const u_char * pchInLimit; + u_char * pchOut; + u_char c; + + pchIn = (const u_char *)in; + pchInLimit = pchIn + in_octets; + pchOut = (u_char *)out; + + if (NULL == pchIn) { + if (0 < out_octets) + *pchOut = '\0'; return; } - ocp = (u_char *)outdata; - for (cp = (u_char *)data; cp < (u_char *)data + length; cp++) { - c = *cp; - if (c == '\0') - break; - if (c == '\0') - break; - if (c > 0177) { - *ocp++ = 'M'; - *ocp++ = '-'; - c &= 0177; - } +#define ONEOUT(c) \ +do { \ + if (0 == --out_octets) { \ + *pchOut = '\0'; \ + return; \ + } \ + *pchOut++ = (c); \ +} while (0) - if (c < ' ') { - *ocp++ = '^'; - *ocp++ = (u_char)(c + '@'); - } else if (c == 0177) { - *ocp++ = '^'; - *ocp++ = '?'; - } else { - *ocp++ = c; + for ( ; pchIn < pchInLimit; pchIn++) { + c = *pchIn; + if ('\0' == c) + break; + if (c & 0x80) { + ONEOUT('M'); + ONEOUT('-'); + c &= 0x7f; } - if (ocp >= ((u_char *)outdata + length - 4)) - break; + if (c < ' ') { + ONEOUT('^'); + ONEOUT((u_char)(c + '@')); + } else if (0x7f == c) { + ONEOUT('^'); + ONEOUT('?'); + } else + ONEOUT(c); } - *ocp++ = '\0'; -} + ONEOUT('\0'); +#undef ONEOUT +} /* * makeascii - print possibly ascii data using the character * transformations that cat -v uses. */ -static void +void makeascii( int length, - char *data, + const char *data, FILE *fp ) { - register u_char *cp; - register int c; + const u_char *data_u_char; + const u_char *cp; + int c; + + data_u_char = (const u_char *)data; - for (cp = (u_char *)data; cp < (u_char *)data + length; cp++) { + for (cp = data_u_char; cp < data_u_char + length; cp++) { c = (int)*cp; - if (c > 0177) { + if (c & 0x80) { putc('M', fp); putc('-', fp); - c &= 0177; + c &= 0x7f; } if (c < ' ') { putc('^', fp); - putc(c+'@', fp); - } else if (c == 0177) { + putc(c + '@', fp); + } else if (0x7f == c) { putc('^', fp); putc('?', fp); - } else { + } else putc(c, fp); - } } } @@ -2691,6 +2846,62 @@ asciize( } +/* + * truncate string to fit clipping excess at end. + * "too long" -> "too l" + * Used for hostnames. + */ +const char * +trunc_right( + const char * src, + size_t width + ) +{ + size_t sl; + char * out; + + + sl = strlen(src); + if (sl > width && LIB_BUFLENGTH - 1 > width && width > 0) { + LIB_GETBUF(out); + memcpy(out, src, width); + out[width] = '\0'; + + return out; + } + + return src; +} + + +/* + * truncate string to fit by preserving right side and using '_' to hint + * "too long" -> "_long" + * Used for local IPv6 addresses, where low bits differentiate. + */ +const char * +trunc_left( + const char * src, + size_t width + ) +{ + size_t sl; + char * out; + + + sl = strlen(src); + if (sl > width && LIB_BUFLENGTH - 1 > width && width > 1) { + LIB_GETBUF(out); + out[0] = '_'; + memcpy(&out[1], &src[sl + 1 - width], width); + + return out; + } + + return src; +} + + /* * Some circular buffer space */ @@ -2706,16 +2917,16 @@ int nextcb = 0; int nextvar( int *datalen, - char **datap, + const char **datap, char **vname, char **vvalue ) { - register char *cp; - register char *np; - register char *cpend; - register char *npend; /* character after last */ - int quoted = 0; + const char *cp; + const char *np; + const char *cpend; + size_t srclen; + size_t len; static char name[MAXVARLEN]; static char value[MAXVALLEN]; @@ -2726,40 +2937,34 @@ nextvar( * Space past commas and white space */ while (cp < cpend && (*cp == ',' || isspace((int)*cp))) - cp++; - if (cp == cpend) - return 0; - + cp++; + if (cp >= cpend) + return 0; + /* * Copy name until we hit a ',', an '=', a '\r' or a '\n'. Backspace * over any white space and terminate it. */ - np = name; - npend = &name[MAXVARLEN]; - while (cp < cpend && np < npend && *cp != ',' && *cp != '=' - && *cp != '\r' && *cp != '\n') - *np++ = *cp++; - /* - * Check if we ran out of name space, without reaching the end or a - * terminating character - */ - if (np == npend && !(cp == cpend || *cp == ',' || *cp == '=' || - *cp == '\r' || *cp == '\n')) - return 0; - while (isspace((int)(*(np-1)))) - np--; - *np = '\0'; + srclen = strcspn(cp, ",=\r\n"); + srclen = min(srclen, (size_t)(cpend - cp)); + len = srclen; + while (len > 0 && isspace((unsigned char)cp[len - 1])) + len--; + if (len > 0) + memcpy(name, cp, len); + name[len] = '\0'; *vname = name; + cp += srclen; /* * Check if we hit the end of the buffer or a ','. If so we are done. */ - if (cp == cpend || *cp == ',' || *cp == '\r' || *cp == '\n') { - if (cp != cpend) - cp++; + if (cp >= cpend || *cp == ',' || *cp == '\r' || *cp == '\n') { + if (cp < cpend) + cp++; *datap = cp; *datalen = cpend - cp; - *vvalue = (char *)0; + *vvalue = NULL; return 1; } @@ -2767,68 +2972,54 @@ nextvar( * So far, so good. Copy out the value */ cp++; /* past '=' */ - while (cp < cpend && (isspace((int)*cp) && *cp != '\r' && *cp != '\n')) - cp++; - np = value; - npend = &value[MAXVALLEN]; - while (cp < cpend && np < npend && ((*cp != ',') || quoted)) - { - quoted ^= ((*np++ = *cp++) == '"'); + while (cp < cpend && (isspace((unsigned char)*cp) && *cp != '\r' && *cp != '\n')) + cp++; + np = cp; + if ('"' == *np) { + do { + np++; + } while (np < cpend && '"' != *np); + if (np < cpend && '"' == *np) + np++; + } else { + while (np < cpend && ',' != *np && '\r' != *np) + np++; } - - /* - * Check if we overran the value buffer while still in a quoted string - * or without finding a comma - */ - if (np == npend && (quoted || *cp != ',')) - return 0; + len = np - cp; + if (np > cpend || len >= sizeof(value) || + (np < cpend && ',' != *np && '\r' != *np)) + return 0; + memcpy(value, cp, len); /* * Trim off any trailing whitespace */ - while (np > value && isspace((int)(*(np-1)))) - np--; - *np = '\0'; + while (len > 0 && isspace((unsigned char)value[len - 1])) + len--; + value[len] = '\0'; /* * Return this. All done. */ - if (cp != cpend) - cp++; - *datap = cp; - *datalen = cpend - cp; + if (np < cpend && ',' == *np) + np++; + *datap = np; + *datalen = cpend - np; *vvalue = value; return 1; } -/* - * findvar - see if this variable is known to us. - * If "code" is 1, return ctl_var->code. - * Otherwise return the ordinal position of the found variable. - */ -int -findvar( - char *varname, - struct ctl_var *varlist, - int code - ) +u_short +varfmt(const char * varname) { - register char *np; - register struct ctl_var *vl; + u_int n; - vl = varlist; - np = varname; - while (vl->fmt != EOV) { - if (vl->fmt != PADDING && STREQ(np, vl->text)) - return (code) - ? vl->code - : (vl - varlist) - ; - vl++; - } - return 0; -} + for (n = 0; n < COUNTOF(cookedvars); n++) + if (!strcmp(varname, cookedvars[n].varname)) + return cookedvars[n].fmt; + return PADDING; +} /* @@ -2837,16 +3028,17 @@ findvar( void printvars( int length, - char *data, + const char *data, int status, int sttype, + int quiet, FILE *fp ) { if (rawmode) - rawprint(sttype, length, data, status, fp); + rawprint(sttype, length, data, status, quiet, fp); else - cookedprint(sttype, length, data, status, fp); + cookedprint(sttype, length, data, status, quiet, fp); } @@ -2857,13 +3049,14 @@ static void rawprint( int datatype, int length, - char *data, + const char *data, int status, + int quiet, FILE *fp ) { - register char *cp; - register char *cpend; + const char *cp; + const char *cpend; /* * Essentially print the data as is. We reformat unprintables, though. @@ -2871,7 +3064,8 @@ rawprint( cp = data; cpend = data + length; - (void) fprintf(fp, "status=0x%04x,\n", status); + if (!quiet) + (void) fprintf(fp, "status=0x%04x,\n", status); while (cp < cpend) { if (*cp == '\r') { @@ -2880,13 +3074,12 @@ rawprint( * \n, supress this, else pretty print it. Otherwise * just output the character. */ - if (cp == (cpend-1) || *(cp+1) != '\n') + if (cp == (cpend - 1) || *(cp + 1) != '\n') makeascii(1, cp, fp); - } else if (isspace((int)*cp) || isprint((int)*cp)) { + } else if (isspace((unsigned char)*cp) || isprint((unsigned char)*cp)) putc(*cp, fp); - } else { + else makeascii(1, cp, fp); - } cp++; } } @@ -2916,36 +3109,31 @@ startoutput(void) static void output( FILE *fp, - char *name, - char *value + const char *name, + const char *value ) { - int lenname; - int lenvalue; + size_t len; - lenname = strlen(name); - lenvalue = strlen(value); + /* strlen of "name=value" */ + len = strlen(name) + 1 + strlen(value); if (out_chars != 0) { - putc(',', fp); - out_chars++; - out_linecount++; - if ((out_linecount + lenname + lenvalue + 3) > MAXOUTLINE) { - putc('\n', fp); - out_chars++; + out_chars += 2; + if ((out_linecount + len + 2) > MAXOUTLINE) { + fputs(",\n", fp); out_linecount = 0; } else { - putc(' ', fp); - out_chars++; - out_linecount++; + fputs(", ", fp); + out_linecount += 2; } } fputs(name, fp); putc('=', fp); fputs(value, fp); - out_chars += lenname + 1 + lenvalue; - out_linecount += lenname + 1 + lenvalue; + out_chars += len; + out_linecount += len; } @@ -2958,7 +3146,7 @@ endoutput( ) { if (out_chars != 0) - putc('\n', fp); + putc('\n', fp); } @@ -2985,7 +3173,7 @@ outputarr( */ for (i = (int)strlen(name); i < 11; i++) *bp++ = ' '; - + for (i = narr; i > 0; i--) { if (i != narr) *bp++ = ' '; @@ -3012,33 +3200,43 @@ tstflags( u_long val ) { - register char *cb, *s; + register char *cp, *s; + size_t cb; register int i; register const char *sep; sep = ""; - i = 0; - s = cb = &circ_buf[nextcb][0]; + s = cp = circ_buf[nextcb]; if (++nextcb >= NUMCB) - nextcb = 0; + nextcb = 0; + cb = sizeof(circ_buf[0]); - sprintf(cb, "%02lx", val); - cb += strlen(cb); + snprintf(cp, cb, "%02lx", val); + cp += strlen(cp); + cb -= strlen(cp); if (!val) { - strcat(cb, " ok"); - cb += strlen(cb); + strlcat(cp, " ok", cb); + cp += strlen(cp); + cb -= strlen(cp); } else { - *cb++ = ' '; - for (i = 0; i < 13; i++) { + if (cb) { + *cp++ = ' '; + cb--; + } + for (i = 0; i < (int)COUNTOF(tstflagnames); i++) { if (val & 0x1) { - sprintf(cb, "%s%s", sep, tstflagnames[i]); + snprintf(cp, cb, "%s%s", sep, + tstflagnames[i]); sep = ", "; - cb += strlen(cb); + cp += strlen(cp); + cb -= strlen(cp); } val >>= 1; } } - *cb = '\0'; + if (cb) + *cp = '\0'; + return s; } @@ -3049,189 +3247,131 @@ static void cookedprint( int datatype, int length, - char *data, + const char *data, int status, + int quiet, FILE *fp ) { - register int varid; char *name; char *value; char output_raw; int fmt; - struct ctl_var *varlist; l_fp lfp; - long ival; - struct sockaddr_storage hval; + sockaddr_u hval; u_long uval; - l_fp lfparr[8]; int narr; + size_t len; + l_fp lfparr[8]; + char b[12]; + char bn[2 * MAXVARLEN]; + char bv[2 * MAXVALLEN]; - switch (datatype) { - case TYPE_PEER: - varlist = peer_var; - break; - case TYPE_SYS: - varlist = sys_var; - break; - case TYPE_CLOCK: - varlist = clock_var; - break; - default: - (void) fprintf(stderr, "Unknown datatype(0x%x) in cookedprint\n", datatype); - return; - } + UNUSED_ARG(datatype); - (void) fprintf(fp, "status=%04x %s,\n", status, - statustoa(datatype, status)); + if (!quiet) + fprintf(fp, "status=%04x %s,\n", status, + statustoa(datatype, status)); startoutput(); while (nextvar(&length, &data, &name, &value)) { - varid = findvar(name, varlist, 0); - if (varid == 0) { + fmt = varfmt(name); + output_raw = 0; + switch (fmt) { + + case PADDING: output_raw = '*'; - } else { - output_raw = 0; - fmt = varlist[varid].fmt; - switch(fmt) { - case TS: - if (!decodets(value, &lfp)) - output_raw = '?'; - else - output(fp, name, prettydate(&lfp)); - break; - case FL: - case FU: - case FS: - if (!decodetime(value, &lfp)) - output_raw = '?'; - else { - switch (fmt) { - case FL: - output(fp, name, - lfptoms(&lfp, 3)); - break; - case FU: - output(fp, name, - ulfptoms(&lfp, 3)); - break; - case FS: - output(fp, name, - lfptoms(&lfp, 3)); - break; - } - } - break; - - case UI: - if (!decodeuint(value, &uval)) - output_raw = '?'; - else - output(fp, name, uinttoa(uval)); - break; - - case SI: - if (!decodeint(value, &ival)) - output_raw = '?'; - else - output(fp, name, inttoa(ival)); - break; - - case HA: - case NA: - if (!decodenetnum(value, &hval)) - output_raw = '?'; - else if (fmt == HA){ - output(fp, name, nntohost(&hval)); - } else { - output(fp, name, stoa(&hval)); - } - break; - - case ST: - output_raw = '*'; - break; - - case RF: - if (decodenetnum(value, &hval)) { - if ((hval.ss_family == AF_INET) && - ISREFCLOCKADR(&hval)) - output(fp, name, - refnumtoa(&hval)); - else - output(fp, name, stoa(&hval)); - } else if ((int)strlen(value) <= 4) - output(fp, name, value); - else - output_raw = '?'; - break; - - case LP: - if (!decodeuint(value, &uval) || uval > 3) - output_raw = '?'; - else { - char b[3]; - b[0] = b[1] = '0'; - if (uval & 0x2) - b[0] = '1'; - if (uval & 0x1) - b[1] = '1'; - b[2] = '\0'; - output(fp, name, b); - } - break; + break; - case OC: - if (!decodeuint(value, &uval)) - output_raw = '?'; - else { - char b[12]; + case TS: + if (!decodets(value, &lfp)) + output_raw = '?'; + else + output(fp, name, prettydate(&lfp)); + break; - (void) snprintf(b, sizeof b, "%03lo", uval); - output(fp, name, b); - } - break; - - case MD: - if (!decodeuint(value, &uval)) - output_raw = '?'; - else - output(fp, name, uinttoa(uval)); - break; - - case AR: - if (!decodearr(value, &narr, lfparr)) - output_raw = '?'; - else - outputarr(fp, name, narr, lfparr); - break; + case HA: /* fallthru */ + case NA: + if (!decodenetnum(value, &hval)) { + output_raw = '?'; + } else if (fmt == HA){ + output(fp, name, nntohost(&hval)); + } else { + output(fp, name, stoa(&hval)); + } + break; - case FX: - if (!decodeuint(value, &uval)) - output_raw = '?'; + case RF: + if (decodenetnum(value, &hval)) { + if (ISREFCLOCKADR(&hval)) + output(fp, name, + refnumtoa(&hval)); else - output(fp, name, tstflags(uval)); - break; - - default: - (void) fprintf(stderr, - "Internal error in cookedprint, %s=%s, fmt %d\n", - name, value, fmt); - break; + output(fp, name, stoa(&hval)); + } else if (strlen(value) <= 4) { + output(fp, name, value); + } else { + output_raw = '?'; + } + break; + + case LP: + if (!decodeuint(value, &uval) || uval > 3) { + output_raw = '?'; + } else { + b[0] = (0x2 & uval) + ? '1' + : '0'; + b[1] = (0x1 & uval) + ? '1' + : '0'; + b[2] = '\0'; + output(fp, name, b); + } + break; + + case OC: + if (!decodeuint(value, &uval)) { + output_raw = '?'; + } else { + snprintf(b, sizeof(b), "%03lo", uval); + output(fp, name, b); } + break; + + case AR: + if (!decodearr(value, &narr, lfparr)) + output_raw = '?'; + else + outputarr(fp, name, narr, lfparr); + break; + + case FX: + if (!decodeuint(value, &uval)) + output_raw = '?'; + else + output(fp, name, tstflags(uval)); + break; + default: + fprintf(stderr, "Internal error in cookedprint, %s=%s, fmt %d\n", + name, value, fmt); + output_raw = '?'; + break; } - if (output_raw != 0) { - char bn[401]; - char bv[401]; - int len; - atoascii(400, name, bn); - atoascii(400, value, bv); + if (output_raw != 0) { + /* TALOS-CAN-0063: avoid buffer overrun */ + atoascii(name, MAXVARLEN, bn, sizeof(bn)); if (output_raw != '*') { + atoascii(value, MAXVALLEN, + bv, sizeof(bv) - 1); len = strlen(bv); bv[len] = output_raw; bv[len+1] = '\0'; + } else { + atoascii(value, MAXVALLEN, + bv, sizeof(bv)); } output(fp, bn, bv); } @@ -3247,47 +3387,182 @@ void sortassoc(void) { if (numassoc > 1) - qsort( -#ifdef QSORT_USES_VOID_P - (void *) -#else - (char *) -#endif - assoc_cache, (size_t)numassoc, - sizeof(struct association), assoccmp); + qsort(assoc_cache, (size_t)numassoc, + sizeof(assoc_cache[0]), &assoccmp); } /* * assoccmp - compare two associations */ -#ifdef QSORT_USES_VOID_P static int assoccmp( const void *t1, const void *t2 ) { - const struct association *ass1 = (const struct association *)t1; - const struct association *ass2 = (const struct association *)t2; + const struct association *ass1 = t1; + const struct association *ass2 = t2; if (ass1->assid < ass2->assid) - return -1; + return -1; if (ass1->assid > ass2->assid) - return 1; + return 1; return 0; } -#else -static int -assoccmp( - struct association *ass1, - struct association *ass2 + + +/* + * grow_assoc_cache() - enlarge dynamic assoc_cache array + * + * The strategy is to add an assumed 4k page size at a time, leaving + * room for malloc() bookkeeping overhead equivalent to 4 pointers. + */ +void +grow_assoc_cache(void) +{ + static size_t prior_sz; + size_t new_sz; + + new_sz = prior_sz + 4 * 1024; + if (0 == prior_sz) { + new_sz -= 4 * sizeof(void *); + } + assoc_cache = erealloc_zero(assoc_cache, new_sz, prior_sz); + prior_sz = new_sz; + assoc_cache_slots = new_sz / sizeof(assoc_cache[0]); +} + + +/* + * ntpq_custom_opt_handler - autoopts handler for -c and -p + * + * By default, autoopts loses the relative order of -c and -p options + * on the command line. This routine replaces the default handler for + * those routines and builds a list of commands to execute preserving + * the order. + */ +void +ntpq_custom_opt_handler( + tOptions *pOptions, + tOptDesc *pOptDesc ) { - if (ass1->assid < ass2->assid) - return -1; - if (ass1->assid > ass2->assid) - return 1; - return 0; + switch (pOptDesc->optValue) { + + default: + fprintf(stderr, + "ntpq_custom_opt_handler unexpected option '%c' (%d)\n", + pOptDesc->optValue, pOptDesc->optValue); + exit(1); + + case 'c': + ADDCMD(pOptDesc->pzLastArg); + break; + + case 'p': + ADDCMD("peers"); + break; + } +} +/* + * Obtain list of digest names + */ + +#ifdef OPENSSL +# ifdef HAVE_EVP_MD_DO_ALL_SORTED +struct hstate { + char *list; + const char **seen; + int idx; +}; +#define K_PER_LINE 8 +#define K_NL_PFX_STR "\n " +#define K_DELIM_STR ", " +static void list_md_fn(const EVP_MD *m, const char *from, const char *to, void *arg ) +{ + size_t len, n; + const char *name, *cp, **seen; + struct hstate *hstate = arg; + EVP_MD_CTX ctx; + u_int digest_len; + u_char digest[EVP_MAX_MD_SIZE]; + + if (!m) + return; /* Ignore aliases */ + + name = EVP_MD_name(m); + + /* Lowercase names aren't accepted by keytype_from_text in ssl_init.c */ + + for( cp = name; *cp; cp++ ) { + if( islower(*cp) ) + return; + } + len = (cp - name) + 1; + + /* There are duplicates. Discard if name has been seen. */ + + for (seen = hstate->seen; *seen; seen++) + if (!strcmp(*seen, name)) + return; + n = (seen - hstate->seen) + 2; + hstate->seen = erealloc(hstate->seen, n * sizeof(*seen)); + hstate->seen[n-2] = name; + hstate->seen[n-1] = NULL; + + /* Discard MACs that NTP won't accept. + * Keep this consistent with keytype_from_text() in ssl_init.c. + */ + + EVP_DigestInit(&ctx, EVP_get_digestbyname(name)); + EVP_DigestFinal(&ctx, digest, &digest_len); + if (digest_len > (MAX_MAC_LEN - sizeof(keyid_t))) + return; + + if (hstate->list != NULL) + len += strlen(hstate->list); + len += (hstate->idx >= K_PER_LINE)? strlen(K_NL_PFX_STR): strlen(K_DELIM_STR); + + if (hstate->list == NULL) { + hstate->list = (char *)emalloc(len); + hstate->list[0] = '\0'; + } else + hstate->list = (char *)erealloc(hstate->list, len); + + sprintf(hstate->list + strlen(hstate->list), "%s%s", + ((hstate->idx >= K_PER_LINE)? K_NL_PFX_STR : K_DELIM_STR), + name); + if (hstate->idx >= K_PER_LINE) + hstate->idx = 1; + else + hstate->idx++; +} +# endif +#endif + +static char *list_digest_names(void) +{ + char *list = NULL; + +#ifdef OPENSSL +# ifdef HAVE_EVP_MD_DO_ALL_SORTED + struct hstate hstate = { NULL, NULL, K_PER_LINE+1 }; + + hstate.seen = (const char **) emalloc_zero(1*sizeof( const char * )); // replaces -> calloc(1, sizeof( const char * )); + + INIT_SSL(); + EVP_MD_do_all_sorted(list_md_fn, &hstate); + list = hstate.list; + free(hstate.seen); +# else + list = (char *)emalloc(sizeof("md5, others (upgrade to OpenSSL-1.0 for full list)")); + strcpy(list, "md5, others (upgrade to OpenSSL-1.0 for full list)"); +# endif +#else + list = (char *)emalloc(sizeof("md5")); + strcpy(list, "md5"); +#endif + + return list; } -#endif /* not QSORT_USES_VOID_P */ diff --git a/contrib/ntp/ntpq/ntpq.h b/contrib/ntp/ntpq/ntpq.h index 0f29fd53c..2575b885c 100644 --- a/contrib/ntp/ntpq/ntpq.h +++ b/contrib/ntp/ntpq/ntpq.h @@ -1,11 +1,17 @@ /* * ntpq.h - definitions of interest to ntpq */ +#ifdef HAVE_UNISTD_H +# include +#endif #include "ntp_fp.h" #include "ntp.h" -#include "ntp_control.h" +#include "ntp_stdlib.h" #include "ntp_string.h" #include "ntp_malloc.h" +#include "ntp_assert.h" +#include "ntp_control.h" +#include "lib_strbuf.h" /* * Maximum number of arguments @@ -13,8 +19,34 @@ #define MAXARGS 4 /* - * Flags for forming descriptors. + * Limit on packets in a single response. Increasing this value to + * 96 will marginally speed "mrulist" operation on lossless networks + * but it has been observed to cause loss on WiFi networks and with + * an IPv6 go6.net tunnel over UDP. That loss causes the request + * row limit to be cut in half, and it grows back very slowly to + * ensure forward progress is made and loss isn't triggered too quickly + * afterward. While the lossless case gains only marginally with + * MAXFRAGS == 96, the lossy case is a lot slower due to the repeated + * timeouts. Empirally, MAXFRAGS == 32 avoids most of the routine loss + * on both the WiFi and UDP v6 tunnel tests and seems a good compromise. + * This suggests some device in the path has a limit of 32 ~512 byte UDP + * packets in queue. + * Lowering MAXFRAGS may help with particularly lossy networks, but some + * ntpq commands may rely on the longtime value of 24 implicitly, + * assuming a single multipacket response will be large enough for any + * needs. In contrast, the "mrulist" command is implemented as a series + * of requests and multipacket responses to each. + */ +#define MAXFRAGS 32 + +/* + * Error codes for internal use */ +#define ERR_UNSPEC 256 +#define ERR_INCOMPLETE 257 +#define ERR_TIMEOUT 258 +#define ERR_TOOMUCH 259 + /* * Flags for forming descriptors. */ @@ -26,15 +58,19 @@ #define NTP_INT 0x3 /* signed integer */ #define NTP_ADD 0x4 /* IP network address */ #define IP_VERSION 0x5 /* IP version */ +#define NTP_ADP 0x6 /* IP address and port */ +#define NTP_LFP 0x7 /* NTP timestamp */ +#define NTP_MODE 0x8 /* peer mode */ +#define NTP_2BIT 0x9 /* leap bits */ /* * Arguments are returned in a union */ typedef union { - char *string; + const char *string; long ival; u_long uval; - struct sockaddr_storage netnum; + sockaddr_u netnum; } arg_v; /* @@ -43,7 +79,7 @@ typedef union { struct parse { const char *keyword; arg_v argval[MAXARGS]; - int nargs; + size_t nargs; }; /* @@ -53,7 +89,7 @@ struct parse { */ struct xcmd { const char *keyword; /* command key word */ - void (*handler) P((struct parse *, FILE *)); /* command handler */ + void (*handler) (struct parse *, FILE *); /* command handler */ u_char arg[MAXARGS]; /* descriptors for arguments */ const char *desc[MAXARGS]; /* descriptions for arguments */ const char *comment; @@ -63,31 +99,56 @@ struct xcmd { * Structure to hold association data */ struct association { - u_short assid; + associd_t assid; u_short status; }; -#define MAXASSOC 1024 +/* + * mrulist terminal status interval + */ +#define MRU_REPORT_SECS 5 /* - * Structure for translation tables between text format - * variable indices and text format. + * var_format is used to override cooked formatting for selected vars. */ -struct ctl_var { - u_short code; - u_short fmt; - const char *text; +typedef struct var_format_tag { + const char * varname; + u_short fmt; +} var_format; + +typedef struct chost_tag chost; +struct chost_tag { + const char *name; + int fam; }; -extern void asciize P((int, char *, FILE *)); -extern int getnetnum P((const char *, struct sockaddr_storage *, char *, int)); -extern void sortassoc P((void)); -extern int doquery P((int, int, int, int, char *, u_short *, int *, char **)); -extern char * nntohost P((struct sockaddr_storage *)); -extern int decodets P((char *, l_fp *)); -extern int decodeuint P((char *, u_long *)); -extern int nextvar P((int *, char **, char **, char **)); -extern int decodetime P((char *, l_fp *)); -extern void printvars P((int, char *, int, int, FILE *)); -extern int decodeint P((char *, long *)); -extern int findvar P((char *, struct ctl_var *, int code)); +extern chost chosts[]; + +extern int interactive; /* are we prompting? */ +extern int old_rv; /* use old rv behavior? --old-rv */ +extern u_int assoc_cache_slots;/* count of allocated array entries */ +extern u_int numassoc; /* number of cached associations */ +extern u_int numhosts; + +extern void grow_assoc_cache(void); +extern void asciize (int, char *, FILE *); +extern int getnetnum (const char *, sockaddr_u *, char *, int); +extern void sortassoc (void); +extern void show_error_msg (int, associd_t); +extern int dogetassoc (FILE *); +extern int doquery (int, associd_t, int, int, const char *, + u_short *, int *, const char **); +extern int doqueryex (int, associd_t, int, int, const char *, + u_short *, int *, const char **, int); +extern const char * nntohost (sockaddr_u *); +extern const char * nntohost_col (sockaddr_u *, size_t, int); +extern const char * nntohostp (sockaddr_u *); +extern int decodets (char *, l_fp *); +extern int decodeuint (char *, u_long *); +extern int nextvar (int *, const char **, char **, char **); +extern int decodetime (char *, l_fp *); +extern void printvars (int, const char *, int, int, int, FILE *); +extern int decodeint (char *, long *); +extern void makeascii (int, const char *, FILE *); +extern const char * trunc_left (const char *, size_t); +extern const char * trunc_right(const char *, size_t); diff --git a/contrib/ntp/ntpq/ntpq.html b/contrib/ntp/ntpq/ntpq.html new file mode 100644 index 000000000..e2c374049 --- /dev/null +++ b/contrib/ntp/ntpq/ntpq.html @@ -0,0 +1,1824 @@ + + +ntpq: Network Time Protocol Query User's Manual + + + + + + + + + +

      ntpq: Network Time Protocol Query User's Manual

      + + + + +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      ntpq: Network Time Protocol Query User Manual

      + +

      The ntpq utility program is used to +monitor the operational status +and determine the performance of +ntpd, the NTP daemon. + +

      This document applies to version 4.2.8p4 of ntpq. + +

      + +
      +


      +Next: , +Previous: Top, +Up: Top +
      +
      + + +

      Description

      + +

      The ntpq utility program is used to monitor NTP daemon ntpd operations and determine performance. +It uses the standard NTP mode 6 control message formats defined in +Appendix B of the NTPv3 specification RFC1305. +The same formats are used in NTPv4, although some of the variable names have changed and new ones added. +The description on this page is for the NTPv4 variables. + +

      The program can be run either in interactive mode or controlled using command line arguments. Requests to read and write arbitrary variables can be assembled, with raw and pretty-printed output options being available. The ntpq can also obtain and print a list of peers in a common format by sending multiple queries to the server. + +

      If one or more request options is included on the command line when ntpq is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, ntpq will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. ntpq will prompt for commands if the standard input is a terminal device. + +

      ntpq uses NTP mode 6 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. ntpq makes one attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time. + +

      Note that in contexts where a host name is expected, a -4 qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a -6 qualifier forces DNS resolution to the IPv6 namespace. + +

      For examples and usage, see the NTP Debugging Techniques page. + +

      +


      + +
      +
      + +

      Invoking ntpq

      + +

      + +

      The +ntpq +utility program is used to query NTP servers which +implement the standard NTP mode 6 control message formats defined +in Appendix B of the NTPv3 specification RFC1305, requesting +information about current state and/or changes in that state. +The same formats are used in NTPv4, although some of the +variables have changed and new ones added. The description on this +page is for the NTPv4 variables. +The program may be run either in interactive mode or controlled using +command line arguments. +Requests to read and write arbitrary +variables can be assembled, with raw and pretty-printed output +options being available. +The +ntpq +utility can also obtain and print a +list of peers in a common format by sending multiple queries to the +server. + +

      If one or more request options is included on the command line +when +ntpq +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +ntpq +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +ntpq +utility will prompt for +commands if the standard input is a terminal device. + +

      ntpq +uses NTP mode 6 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +ntpq +utility makes +one attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. + +

      Specifying a +command line option other than +-i +or +-n +will +cause the specified query (queries) to be sent to the indicated +host(s) immediately. +Otherwise, +ntpq +will attempt to read +interactive format commands from the standard input. + +

      Internal Commands
      + +

      Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. + +

      A +number of interactive format commands are executed entirely within +the +ntpq +utility itself and do not result in NTP mode 6 +requests being sent to a server. +These are described following. +

      +
      ? [command_keyword]
      help [command_keyword]
      A +? +by itself will print a list of all the command +keywords known to this incarnation of +ntpq +A +? +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +ntpq +than this manual +page. +
      addvars variable_name[=value] ...
      rmvars variable_name ...
      clearvars
      showvars
      The data carried by NTP mode 6 messages consists of a list of +items of the form +variable_name=value, +where the +=value +is ignored, and can be omitted, +in requests to the server to read variables. +The +ntpq +utility maintains an internal list in which data to be included in control +messages can be assembled, and sent using the +readlist +and +writelist +commands described below. +The +addvars +command allows variables and their optional values to be added to +the list. +If more than one variable is to be added, the list should +be comma-separated and not contain white space. +The +rmvars +command can be used to remove individual variables from the list, +while the +clearlist +command removes all variables from the +list. +The +showvars +command displays the current list of optional variables. +
      authenticate [yes | no]
      Normally +ntpq +does not authenticate requests unless +they are write requests. +The command +authenticate yes +causes +ntpq +to send authentication with all requests it +makes. +Authenticated requests causes some servers to handle +requests slightly differently, and can occasionally melt the CPU in +fuzzballs if you turn authentication on before doing a +peer +display. +The command +authenticate +causes +ntpq +to display whether or not +ntpq +is currently autheinticating requests. +
      cooked
      Causes output from query commands to be "cooked", so that +variables which are recognized by +ntpq +will have their +values reformatted for human consumption. +Variables which +ntpq +thinks should have a decodable value but didn't are +marked with a trailing +?. +
      debug [more | less | off]
      With no argument, displays the current debug level. +Otherwise, the debug level is changed to the indicated level. +
      delay milliseconds
      Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +
      exit
      Exit +ntpq +
      host hostname
      Set the host to which future queries will be sent. +hostname +may be either a host name or a numeric address. +
      hostnames [yes | no]
      If +yes +is specified, host names are printed in +information displays. +If +no +is specified, numeric +addresses are printed instead. +The default is +yes, +unless +modified using the command line +-n +switch. +
      keyid keyid
      This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to the +controlkey +key number the server has been configured to use for this +purpose. +
      keytype [md5 | OpenSSLDigestType]
      Specify the type of key to use for authenticating requests. +md5 +is alway supported. +If +ntpq +was built with OpenSSL support, +any digest type supported by OpenSSL can also be provided. +If no argument is given, the current +keytype +is displayed. +
      ntpversion [1 | 2 | 3 | 4]
      Sets the NTP version number which +ntpq +claims in +packets. +Defaults to 3, and note that mode 6 control messages (and +modes, for that matter) didn't exist in NTP version 1. +There appear +to be no servers left which demand version 1. +With no argument, displays the current NTP version that will be used +when communicating with servers. +
      passwd
      This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +poll +n +verbose +
      quit
      Exit +ntpq +
      raw
      Causes all output from query commands is printed as received +from the remote server. +The only formating/interpretation done on +the data is to transform nonascii data into a printable (but barely +understandable) form. +
      timeout milliseconds
      Specify a timeout period for responses to server queries. +The +default is about 5000 milliseconds. +Note that since +ntpq +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +
      version
      Print the version of the +ntpq +program. +
      + +
      Control Message Commands
      + +

      Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode-6 message to the server and expect a single response message. +The exceptions are the +peers +command, which sends a series of messages, +and the +mreadlist +and +mreadvar +commands, which iterate over a range of associations. +

      +
      associations
      Display a list of mobilized associations in the form: +
                ind assid status conf reach auth condition last_event cnt
      +     
      +
      +
      Sy String Ta Sy Description
      ind Ta index on this list
      assid Ta association ID
      status Ta peer status word
      conf Ta yes: persistent, no: ephemeral
      reach Ta yes: reachable, no: unreachable
      auth Ta ok, yes, bad and none
      condition Ta selection status (see the select field of the peer status word)
      last_event Ta event report (see the event field of the peer status word)
      cnt Ta event count (see the count field of the peer status word)
      +
      authinfo
      Display the authentication statistics. +
      clockvar assocID [name[=value]] [...]
      cv assocID [name[=value]] [...]
      Display a list of clock variables for those associations supporting a reference clock. +
      :config [...]
      Send the remainder of the command line, including whitespace, to the server as a run-time configuration command in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is of course required. +
      config-from-file filename
      Send the each line of +filename +to the server as run-time configuration commands in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is required. +
      ifstats
      Display statistics for each local network address. Authentication is required. +
      iostats
      Display network and reference clock I/O statistics. +
      kerninfo
      Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable. +
      lassociations
      Perform the same function as the associations command, except display mobilized and unmobilized associations. +
      lopeers [-4 | -6]
      Obtain and print a list of all peers and clients showing +dstadr +(associated with any given IP version). +
      lpeers [-4 | -6]
      Print a peer spreadsheet for the appropriate IP version(s). +dstadr +(associated with any given IP version). +
      monstats
      Display monitor facility statistics. +
      mrulist [limited | kod | mincount=count | laddr=localaddr | sort=sortorder | resany=hexmask | resall=hexmask]
      Obtain and print traffic counts collected and maintained by the monitor facility. +With the exception of +sort=sortorder, +the options filter the list returned by +ntpd. +The +limited +and +kod +options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. +The +mincount=count +option filters entries representing less than +count +packets. +The +laddr=localaddr +option filters entries for packets received on any local address other than +localaddr. +resany=hexmask +and +resall=hexmask +filter entries containing none or less than all, respectively, of the bits in +hexmask, +which must begin with +0x. +The +sortorder +defaults to +lstint +and may be any of +addr, +count, +avgint, +lstint, +or any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: +
      +
      Column
      Description +
      lstint
      Interval in s between the receipt of the most recent packet from this address and the completion of the retrieval of the MRU list by +ntpq +
      avgint
      Average interval in s between packets from this address. +
      rstr
      Restriction flags associated with this address. +Most are copied unchanged from the matching +restrict +command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this address triggered a rate control response. +
      r
      Rate control indicator, either +a period, +L +or +K +for no rate control response, +rate limiting by discarding, or rate limiting with a KoD response, respectively. +
      m
      Packet mode. +
      v
      Packet version number. +
      count
      Packets received from this address. +
      rport
      Source port of last packet from this address. +
      remote address
      DNS name, numeric address, or address followed by +claimed DNS name which could not be verified in parentheses. +
      +
      mreadvar assocID assocID [variable_name[=value] ...]
      mrv assocID assocID [variable_name[=value] ...]
      Perform the same function as the +readvar +command, except for a range of association IDs. +This range is determined from the association list cached by the most recent +associations +command. +
      opeers [-4 | -6]
      Obtain and print the old-style list of all peers and clients showing +dstadr +(associated with any given IP version), +rather than the +refid. +
      passociations
      Perform the same function as the +associations +command, +except that it uses previously stored data rather than making a new query. +
      peers
      Display a list of peers in the form: +
                [tally]remote refid st t when pool reach delay offset jitter
      +     
      +
      +
      Variable
      Description +
      [tally]
      single-character code indicating current value of the +select +field of the +.Lk decode.html#peer "peer status word" +
      remote
      host name (or IP number) of peer. +The value displayed will be truncated to 15 characters unless the +-w +flag is given, in which case the full value will be displayed +on the first line, +and the remaining data is displayed on the next line. +
      refid
      association ID or +.Lk decode.html#kiss "'kiss code" +
      st
      stratum +
      t
      u: +unicast or manycast client, +b: +broadcast or multicast client, +l: +local (reference clock), +s: +symmetric (peer), +A: +manycast server, +B: +broadcast server, +M: +multicast server +
      when
      sec/min/hr since last received packet +
      poll
      poll interval (log2 s) +
      reach
      reach shift register (octal) +
      delay
      roundtrip delay +
      offset
      offset of server relative to this host +
      jitter
      jitter +
      +
      apeers
      Display a list of peers in the form: +
                [tally]remote refid assid st t when pool reach delay offset jitter
      +     
      +

      where the output is just like the +peers +command except that the +refid +is displayed in hex format and the association number is also displayed. +

      pstats assocID
      Show the statistics for the peer with the given +assocID. +
      readlist assocID
      rl assocID
      Read the system or peer variables included in the variable list. +
      readvar assocID name[=value] [, ...]
      rv assocID name[=value] [, ...]
      Display the specified variables. +If +assocID +is zero, the variables are from the +System Variables +name space, otherwise they are from the +Peer Variables +name space. +The +assocID +is required, as the same name can occur in both spaces. +If no +name +is included, all operative variables in the name space are displayed. + +

      In this case only, if the +assocID +is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds +and frequency values in parts-per-million (PPM). +Some NTP timestamps are represented in the format +YYYYMMDDTTTT , +where YYYY is the year, +MM the month of year, +DD the day of month and +TTTT the time of day. +

      reslist
      Show the access control (restrict) list for +ntpq + +
      saveconfig filename
      Write the current configuration, +including any runtime modifications given with +:config +or +config-from-file, +to the ntpd host's file +filename. +This command will be rejected by the server unless +.Lk miscopt.html#saveconfigdir "saveconfigdir" +appears in the +ntpd +configuration file. +filename +can use +strftime() +format specifies to substitute the current date and time, for example, +q]saveconfig ntp-%Y%m%d-%H%M%S.confq]. +The filename used is stored in system variable +savedconfig. +Authentication is required. +
      timerstats
      Display interval timer counters. +
      writelist assocID
      Write the system or peer variables included in the variable list. +
      writevar assocID name=value [, ...]
      Write the specified variables. +If the +assocID +is zero, the variables are from the +System Variables +name space, otherwise they are from the +Peer Variables +name space. +The +assocID +is required, as the same name can occur in both spaces. +
      sysinfo
      Display operational summary. +
      sysstats
      Print statistics counters maintained in the protocol module. +
      + +
      Status Words and Kiss Codes
      + +

      The current state of the operating program is shown +in a set of status words +maintained by the system. +Status information is also available on a per-association basis. +These words are displayed in the +rv +and +as +commands both in hexadecimal and in decoded short tip strings. +The codes, tips and short explanations are documented on the +.Lk decode.html "Event Messages and Status Words" +page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. + +

      Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +.Lk decode.html#kiss "kiss codes" . +The original purpose was for kiss-o'-death (KoD) packets +sent by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. + +

      System Variables
      + +

      The following system variables appear in the +rv +billboard. +Not all variables are displayed in some configurations. +

      +
      Variable
      Description +
      status
      .Lk decode.html#sys "system status word" +
      version
      NTP software version and build time +
      processor
      hardware platform and version +
      system
      operating system and version +
      leap
      leap warning indicator (0-3) +
      stratum
      stratum (1-15) +
      precision
      precision (log2 s) +
      rootdelay
      total roundtrip delay to the primary reference clock +
      rootdisp
      total dispersion to the primary reference clock +
      peer
      system peer association ID +
      tc
      time constant and poll exponent (log2 s) (3-17) +
      mintc
      minimum time constant (log2 s) (3-10) +
      clock
      date and time of day +
      refid
      reference ID or +.Lk decode.html#kiss "kiss code" +
      reftime
      reference time +
      offset
      combined offset of server relative to this host +
      sys_jitter
      combined system jitter +
      frequency
      frequency offset (PPM) relative to hardware clock +
      clk_wander
      clock frequency wander (PPM) +
      clk_jitter
      clock jitter +
      tai
      TAI-UTC offset (s) +
      leapsec
      NTP seconds when the next leap second is/was inserted +
      expire
      NTP seconds when the NIST leapseconds file expires +
      + The jitter and wander statistics are exponentially-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. + +

      When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, +including some or all of the following, +depending on the particular Autokey dance: + +

      +
      Variable
      Description +
      host
      Autokey host name for this host +
      ident
      Autokey group name for this host +
      flags
      host flags (see Autokey specification) +
      digest
      OpenSSL message digest algorithm +
      signature
      OpenSSL digest/signature scheme +
      update
      NTP seconds at last signature update +
      cert
      certificate subject, issuer and certificate flags +
      until
      NTP seconds when the certificate expires +
      + +
      Peer Variables
      + +

      The following peer variables appear in the +rv +billboard for each association. +Not all variables are displayed in some configurations. + +

      +
      Variable
      Description +
      associd
      association ID +
      status
      .Lk decode.html#peer "peer status word" +
      srcadr
      source (remote) IP address +
      srcport
      source (remote) port +
      dstadr
      destination (local) IP address +
      dstport
      destination (local) port +
      leap
      leap indicator (0-3) +
      stratum
      stratum (0-15) +
      precision
      precision (log2 s) +
      rootdelay
      total roundtrip delay to the primary reference clock +
      rootdisp
      total root dispersion to the primary reference clock +
      refid
      reference ID or +.Lk decode.html#kiss "kiss code" +
      reftime
      reference time +
      reach
      reach register (octal) +
      unreach
      unreach counter +
      hmode
      host mode (1-6) +
      pmode
      peer mode (1-5) +
      hpoll
      host poll exponent (log2 s) (3-17) +
      ppoll
      peer poll exponent (log2 s) (3-17) +
      headway
      headway (see +.Lk rate.html "Rate Management and the Kiss-o'-Death Packet" ) +
      flash
      .Lk decode.html#flash "flash status word" +
      offset
      filter offset +
      delay
      filter delay +
      dispersion
      filter dispersion +
      jitter
      filter jitter +
      ident
      Autokey group name for this association +
      bias
      unicast/broadcast bias +
      xleave
      interleave delay (see +.Lk xleave.html "NTP Interleaved Modes" ) +
      + The +bias +variable is calculated when the first broadcast packet is received +after the calibration volley. +It represents the offset of the broadcast subgraph relative to the unicast subgraph. +The +xleave +variable appears only for the interleaved symmetric and interleaved modes. +It represents the internal queuing, buffering and transmission delays +for the preceding packet. + +

      When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: +

      +
      Variable
      Description +
      flags
      peer flags (see Autokey specification) +
      host
      Autokey server name +
      flags
      peer flags (see Autokey specification) +
      signature
      OpenSSL digest/signature scheme +
      initsequence
      initial key ID +
      initkey
      initial key index +
      timestamp
      Autokey signature timestamp +
      + +
      Clock Variables
      + +

      The following clock variables appear in the +cv +billboard for each association with a reference clock. +Not all variables are displayed in some configurations. +

      +
      Variable
      Description +
      associd
      association ID +
      status
      .Lk decode.html#clock "clock status word" +
      device
      device description +
      timecode
      ASCII time code string (specific to device) +
      poll
      poll messages sent +
      noreply
      no reply +
      badformat
      bad format +
      baddata
      bad date or time +
      fudgetime1
      fudge time 1 +
      fudgetime2
      fudge time 2 +
      stratum
      driver stratum +
      refid
      driver reference ID +
      flags
      driver flags +
      + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntpq program. +This software is released under the NTP license, <http://ntp.org/license>. + +

      + +
      +


      +Next: , +Up: ntpq Invocation +
      +
      + +

      ntpq help/usage (--help)

      + +

      +This is the automatically generated usage text for ntpq. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      ntpq - standard NTP query program - Ver. 4.2.8p4-sec-RC2
      +Usage:  ntpq [ -<flag> [<val>] | --<name>[{=| }<val>] ]... [ host ...]
      +  Flg Arg Option-Name    Description
      +   -4 no  ipv4           Force IPv4 DNS name resolution
      +                                - prohibits the option 'ipv6'
      +   -6 no  ipv6           Force IPv6 DNS name resolution
      +                                - prohibits the option 'ipv4'
      +   -c Str command        run a command and exit
      +                                - may appear multiple times
      +   -d no  debug-level    Increase debug verbosity level
      +                                - may appear multiple times
      +   -D Num set-debug-level Set the debug verbosity level
      +                                - may appear multiple times
      +   -i no  interactive    Force ntpq to operate in interactive mode
      +                                - prohibits these options:
      +                                command
      +                                peers
      +   -n no  numeric        numeric host addresses
      +      no  old-rv         Always output status line with readvar
      +   -p no  peers          Print a list of the peers
      +                                - prohibits the option 'interactive'
      +   -w no  wide           Display the full 'remote' value
      +      opt version        output version information and exit
      +   -? no  help           display extended usage information and exit
      +   -! no  more-help      extended usage information passed thru pager
      +   -> opt save-opts      save the option state to a config file
      +   -< Str load-opts      load options from a config file
      +                                - disabled as '--no-load-opts'
      +                                - may appear multiple times
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      +The following option preset mechanisms are supported:
      + - reading file $HOME/.ntprc
      + - reading file ./.ntprc
      + - examining environment variables named NTPQ_*
      +
      +Please send bug reports to:  <http://bugs.ntp.org, bugs@ntp.org>
      +
      +
      +


      +Next: , +Previous: ntpq usage, +Up: ntpq Invocation +
      +
      + +

      ipv4 option (-4)

      + +

      +This is the “force ipv4 dns name resolution” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +ipv6. +
      + +

      Force DNS resolution of following host names on the command line +to the IPv4 namespace. +

      +


      +Next: , +Previous: ntpq ipv4, +Up: ntpq Invocation +
      +
      + +

      ipv6 option (-6)

      + +

      +This is the “force ipv6 dns name resolution” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +ipv4. +
      + +

      Force DNS resolution of following host names on the command line +to the IPv6 namespace. +

      +


      +Next: , +Previous: ntpq ipv6, +Up: ntpq Invocation +
      +
      + +

      command option (-c)

      + +

      +This is the “run a command and exit” option. +This option takes a string argument cmd. + +

      This option has some usage constraints. It: +

        +
      • may appear an unlimited number of times. +
      + +

      The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +

      +


      +Next: , +Previous: ntpq command, +Up: ntpq Invocation +
      +
      + +

      interactive option (-i)

      + +

      +This is the “force ntpq to operate in interactive mode” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +command, peers. +
      + +

      Force ntpq to operate in interactive mode. +Prompts will be written to the standard output and +commands read from the standard input. +

      +


      +Next: , +Previous: ntpq interactive, +Up: ntpq Invocation +
      +
      + +

      numeric option (-n)

      + +

      +This is the “numeric host addresses” option. +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +

      +


      +Next: , +Previous: ntpq numeric, +Up: ntpq Invocation +
      +
      + +

      old-rv option

      + +

      +This is the “always output status line with readvar” option. +By default, ntpq now suppresses the associd=... +line that precedes the output of readvar +(alias rv) when a single variable is requested, such as +ntpq -c "rv 0 offset". +This option causes ntpq to include both lines of output +for a single-variable readvar. +Using an environment variable to +preset this option in a script will enable both older and +newer ntpq to behave identically in this regard. +

      +


      +Next: , +Previous: ntpq old-rv, +Up: ntpq Invocation +
      +
      + +

      peers option (-p)

      + +

      +This is the “print a list of the peers” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +interactive. +
      + +

      Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +

      +


      +Next: , +Previous: ntpq peers, +Up: ntpq Invocation +
      +
      + +

      wide option (-w)

      + +

      +This is the “display the full 'remote' value” option. +Display the full value of the 'remote' value. If this requires +more than 15 characters, display the full value, emit a newline, +and continue the data display properly indented on the next line. + +

      +


      +Next: , +Previous: ntpq wide, +Up: ntpq Invocation +
      +
      + +

      presetting/configuring ntpq

      + +

      Any option that is not marked as not presettable may be preset by +loading values from configuration ("rc" or "ini") files, and values from environment variables named NTPQ and NTPQ_<OPTION_NAME>. <OPTION_NAME> must be one of +the options listed above in upper case and segmented with underscores. +The NTPQ variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + +

      libopts will search in 2 places for configuration files: +

        +
      • $HOME +
      • $PWD +
      + The environment variables HOME, and PWD +are expanded and replaced when ntpq runs. +For any of these that are plain files, they are simply processed. +For any that are directories, then a file named .ntprc is searched for +within that directory and processed. + +

      Configuration files may be in a wide variety of formats. +The basic format is an option name followed by a value (argument) on the +same line. Values may be separated from the option name with a colon, +equal sign or simply white space. Values may be continued across multiple +lines by escaping the newline with a backslash. + +

      Multiple programs may also share the same initialization file. +Common options are collected at the top, followed by program specific +segments. The segments are separated by lines like: +

          [NTPQ]
      +
      +

      or by +

          <?program ntpq>
      +
      +

      Do not mix these styles within one configuration file. + +

      Compound values and carefully constructed string values may also be +specified using XML syntax: +

          <option-name>
      +       <sub-opt>...&lt;...&gt;...</sub-opt>
      +    </option-name>
      +
      +

      yielding an option-name.sub-opt string value of +

          "...<...>..."
      +
      +

      AutoOpts does not track suboptions. You simply note that it is a +hierarchicly valued option. AutoOpts does provide a means for searching +the associated name/value pair list (see: optionFindValue). + +

      The command line options relating to configuration and/or usage help are: + +

      version (-)
      + +

      Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +

      +
      version
      Only print the version. This is the default. +
      copyright
      Name the copyright usage licensing terms. +
      verbose
      Print the full copyright usage licensing terms. +
      + +
      +


      +Previous: ntpq config, +Up: ntpq Invocation +
      +
      + +

      ntpq exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      66 (EX_NOINPUT)
      A specified configuration file could not be loaded. +
      70 (EX_SOFTWARE)
      libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +
      + +
      +


      +Next: , +Previous: ntpq Description, +Up: Top +
      +
      + + +

      Usage

      + +

      What Default Flag Option +
      configuration file +/etc/ntp.conf +-c +conffile +
      frequency file +none +-f +driftfile +
      leapseconds file +none + +leapfile +
      process ID file +none +-p +pidfile +
      log file +system log +-l +logfile +
      include file +none +none +includefile +
      statistics path +/var/NTP +-s +statsdir +
      keys path +/usr/local/etc +-k +keysdir +
      + +

      +


      +Next: , +Previous: Usage, +Up: Top +
      +
      + + +

      Internal Commands

      + +

      Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a >, followed by a file name, to the command line. A number of interactive format commands are executed entirely within the ntpq program itself and do not result in NTP mode-6 requests being sent to a server. These are described following. + +

      +
      ? [command_keyword]
      help [command_keyword]
      A ? by itself will print a list of all the command keywords known to ntpq. A ? followed by a command keyword will print function and usage information about the command. + +
      >addvars name [ = value] [...]
      rmvars name [...]
      clearvars</dt>
      The arguments to these commands consist of a list of items of the form +name = value, where the = value is ignored, +and can be omitted in read requests. +ntpq maintains an internal list in which data to be included +in control messages can be assembled, and sent using the readlist +and writelist commands described below. +The addvars command allows variables and optional values +to be added to the list. +If more than one variable is to be added +the list should be comma-separated and not contain white space. +The rmvars command can be used to remove individual variables +from the list, +while the clearlist command removes all variables from the list. + +
      cooked
      Display server messages in prettyprint format. + +
      debug more | less | off
      Turns internal query program debugging on and off. + +
      delay milliseconds
      Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete. + +
      host name
      Set the host to which future queries will be sent. +The name may be either a DNS name or a numeric address. + +
      hostnames [yes | no]
      If yes is specified, host names are printed in information displays. +If no is specified, numeric addresses are printed instead. +The default is yes, +unless modified using the command line -n switch. + +
      keyid keyid
      This command specifies the key number to be used +to authenticate configuration requests. +This must correspond to a key ID configured in ntp.conf for this purpose. + +
      keytype
      Specify the digest algorithm to use for authenticated requests, +with default MD5. +If the OpenSSL library is installed, +digest can be be any message digest algorithm supported by the library. +The current selections are: MD2, MD4, MD5, MDC2, RIPEMD160, SHA and SHA1. + +
      ntpversion 1 | 2 | 3 | 4
      Sets the NTP version number which ntpq claims in packets. +Defaults to 2. +Note that mode-6 control messages (and modes, for that matter) +didn't exist in NTP version 1. + +
      passwd
      This command prompts for a password to authenticate requests. +The password must correspond to the key ID configured in ntp.conf for this purpose. + +
      quit
      Exit ntpq. + +
      raw
      Display server messages as received and without reformatting. + +
      timeout millseconds
      Specify a timeout period for responses to server queries. +The default is about 5000 milliseconds. +Note that since ntpq retries each query once after a timeout +the total waiting time for a timeout will be twice the timeout value set. + +
      + +
      +


      +Next: , +Previous: Internal Commands, +Up: Top +
      +
      + + +

      Control Message Commands

      + +

      Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, +while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode-6 message to the server +and expect a single response message. +The exceptions are the peers command, +which sends a series of messages, +and the mreadlist and mreadvar commands, +which iterate over a range of associations. + +

      +

      +
      associations
      Display a list of mobilized associations in the form: +
      +ind assid status conf reach auth condition last_event cnt + +

      Variable Description + +


      ind +index on this list + +


      assid +association ID + +


      status +peer status word + +


      conf +yes: persistent, no: ephemeral + +


      reach +yes: reachable, no: unreachable + +


      auth +ok, yes, bad and none + +


      condition +selection status (see the select field of the peer status word) + +


      last_event +event report (see the event field of the peer status word) + +


      cnt +event count (see the count field of the peer status word) + +
      + +

      clockvar assocID [name [ = value [...]] [...]]
      cv assocID [name [ = value [...] ][...]]
      Display a list of clock variables for those associations supporting a reference clock. + +
      :config [...]
      Send the remainder of the command line, including whitespace, to the server +as a run-time configuration command in the same format +as the configuration file. +This command is experimental until further notice and clarification. +Authentication is of course required. + +
      config-from-file filename
      Send the each line of filename to the server as +run-time configuration commands in the same format as the configuration file. +This command is experimental until further notice and clarification. +Authentication is required. + +
      ifstats
      Display statistics for each local network address. +Authentication is required. + +
      iostats
      Display network and reference clock I/O statistics. + +
      kerninfo
      Display kernel loop and PPS statistics. +As with other ntpq output, times are in milliseconds. +The precision value displayed is in milliseconds as well, +unlike the precision system variable. + +
      lassociations
      Perform the same function as the associations command, +except display mobilized and unmobilized associations. + +
      monstats
      Display monitor facility statistics. + +
      mrulist [limited | kod | mincount=count | laddr=localaddr | sort=sortorder | resany=hexmask | resall=hexmask]
      Obtain and print traffic counts collected and maintained by +the monitor facility. +With the exception of sort=sortorder, +the options filter the list returned by ntpd. +The limited and kod options return only entries +representing client addresses from which the last packet received +triggered either discarding or a KoD response. +The mincount=count option filters entries representing +less than count packets. +The laddr=localaddr option filters entries for packets +received on any local address other than localaddr. +resany=hexmask and resall=hexmask +filter entries containing none or less than all, respectively, +of the bits in hexmask, which must begin with 0x. +
      +The sortorder defaults to lstint and may be any of +addr, count, avgint, lstint, or +any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: + +

      Column Description + +


      lstint + +Interval in s between the receipt of the most recent packet from this +address and the completion of the retrieval of the MRU list by ntpq + +


      avgint + +Average interval in s between packets from this address. + +


      rstr + +Restriction flags associated with this address. +Most are copied unchanged from the matching restrict command, +however 0x400 (kod) and 0x20 (limited) flags are cleared unless +the last packet from this address triggered a rate control response. + +


      r + +Rate control indicator, either a period, L or K for +no rate control response, rate limiting by discarding, or +rate limiting with a KoD response, respectively. + +


      m + +Packet mode. +
      v + +Packet version number. + +


      count + +Packets received from this address. + +


      rport + +Source port of last packet from this address. + +


      remote address + +DNS name, numeric address, or address followed by claimed DNS name which +could not be verified in parentheses. + +
      + +

      mreadvar assocID assocID [ variable_name [ = value[ ... ]
      mrv assocID assocID [ variable_name [ = value[ ... ]
      Perform the same function as the readvar command, +except for a range of association IDs. +This range is determined from the association list cached by +the most recent associations command. + +
      passociations
      Perform the same function as the associations command, except that +it uses previously stored data rather than making a new query. + +
      peers
      Display a list of peers in the form: +
      +[tally]remote refid st t when pool reach delay offset jitter + +

      Variable Description +
      [tally] + +single-character code indicating current value of the select field +of the peer status word. + +


      remote + +host name (or IP number) of peer + +


      refid + +association ID or kiss code. + +


      st + +stratum + +


      t + +u: unicast or manycast client, +b: broadcast or multicast client, +l: local (reference clock), +s: symmetric (peer), +A: manycast server, +B: broadcast server, +M: multicast server. + +


      when + +sec/min/hr since last received packet + +


      poll + +poll interval (log(2) s) + +


      reach + +reach shift register (octal) + +


      delay + +roundtrip delay + +


      offset + +offset of server relative to this host + +


      jitter + +jitter + +
      + +

      readvar assocID name [ = value ] [,...]
      rv assocID [ name ] [,...]
      Display the specified variables. +If assocID is zero, +the variables are from the system variables name space, +otherwise they are from the peer variables name space. +The assocID is required, as the same name can occur in both spaces. +If no name is included, +all operative variables in the name space are displayed. +In this case only, if the assocID is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds and +frequency values in parts-per-million (PPM). +Some NTP timestamps are represented in the format YYYYMMDDTTTT, +where YYYY is the year, MM the month of year, DD the day of month and +TTTT the time of day. + +
      saveconfig filename
      Write the current configuration, including any runtime modifications +given with :config or config-from-file, +to the ntpd host's file filename. +This command will be rejected by the server unless +saveconfigdir +appears in the ntpd configuration file. +filename can use strftime() format specifiers +to substitute the current date and time, for example, +saveconfig ntp-%Y%m%d-%H%M%S.conf. +The filename used is stored in system variable savedconfig. +Authentication is required. + +
      writevar assocID name = value [,...]
      Write the specified variables. +If the assocID is zero, the variables are from the +system variables name space, otherwise they are from the +peer variables name space. +The assocID is required, +as the same name can occur in both spaces. + +
      sysinfo
      Display operational summary. + +
      sysstats
      Print statistics counters maintained in the protocol module. + +
      + +
      +


      +Next: , +Previous: Control Message Commands, +Up: Top +
      +
      + + +

      Status Words and Kiss Codes

      + +

      The current state of the operating program is shown +in a set of status words maintained by the system +and each association separately. +These words are displayed in the rv and as commands +both in hexadecimal and decoded short tip strings. +The codes, tips and short explanations are on the +Event Messages and Status Words page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. + +

      Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +kiss codes. +The original purpose was for kiss-o'-death (KoD) packets sent +by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. + +

      +


      +Next: , +Previous: Status Words and Kiss Codes, +Up: Top +
      +
      + + +

      System Variables

      + +

      The following system variables appear in the rv billboard. +Not all variables are displayed in some configurations. + +

      Variable Description + +


      status + +system status word + +


      version + +NTP software version and build time + +


      processor + +hardware platform and version + +


      system + +operating system and version + +


      leap + +leap warning indicator (0-3) + +


      stratum + +stratum (1-15) + +


      precision + +precision (log(2) s) + +


      rootdelay + +total roundtrip delay to the primary reference clock + +


      rootdisp + +total dispersion to the primary reference clock + +


      peer + +system peer association ID + +


      tc +time constant and poll exponent (log(2) s) (3-17) + +


      mintc +minimum time constant (log(2) s) (3-10) + +


      clock + +date and time of day + +


      refid +reference ID or kiss code + +


      reftime + +reference time + +


      offset + +combined offset of server relative to this host + +


      sys_jitter + +combined system jitter + +


      frequency + +frequency offset (PPM) relative to hardware clock + +


      clk_wander + +clock frequency wander (PPM) + +


      clk_jitter + +clock jitter + +


      tai + +TAI-UTC offset (s) + +


      leapsec + +NTP seconds when the next leap second is/was inserted + +


      expire + +NTP seconds when the NIST leapseconds file expires + +
      + +

      The jitter and wander statistics are exponentially-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. + +

      When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, including some or all of the +following, depending on the particular Autokey dance: + +

      Variable Description + +


      host + +Autokey host name for this host + +


      ident + +Autokey group name for this host + +


      flags + +host flags (see Autokey specification) + +


      digest + +OpenSSL message digest algorithm + +


      signature + +OpenSSL digest/signature scheme + +


      update + +NTP seconds at last signature update + +


      cert + +certificate subject, issuer and certificate flags + +


      until + +NTP seconds when the certificate expires + +
      + +

      +


      +Next: , +Previous: System Variables, +Up: Top +
      +
      + + +

      Peer Variables

      + +

      The following peer variables appear in the rv billboard +for each association. +Not all variables are displayed in some configurations. + +

      Variable Description + +


      associd + +association ID + +


      status + +peer status word + +


      srcadr +
      srcport + +source (remote) IP address and port + +


      dstadr +
      dstport + +destination (local) IP address and port + +


      leap + +leap indicator (0-3) + +


      stratum + +stratum (0-15) + +


      precision + +precision (log(2) s) + +


      rootdelay + +total roundtrip delay to the primary reference clock + +


      rootdisp +total root dispersion to the primary reference clock + +


      refid + +reference ID or kiss code + +


      reftime + +reference time + +


      reach + +reach register (octal) + +


      unreach + +unreach counter + +


      hmode + +host mode (1-6) + +


      pmode + +peer mode (1-5) + +


      hpoll + +host poll exponent (log(2) s) (3-17) +
      ppoll + +peer poll exponent (log(2) s) (3-17) + +


      headway + +headway (see Rate Management and the Kiss-o'-Death Packet) + +


      flash + +flash status word + +


      offset + +filter offset + +


      delay + +filter delay + +


      dispersion + +filter dispersion + +


      jitter + +filter jitter + +


      ident + +Autokey group name for this association + +


      bias + +unicast/broadcast bias + +


      xleave + +interleave delay (see NTP Interleaved Modes) + +
      + +

      The bias variable is calculated when the first broadcast packet is received +after the calibration volley. It represents the offset of the broadcast +subgraph relative to the unicast subgraph. The xleave variable appears +only the interleaved symmetric and interleaved modes. It represents +the internal queuing, buffering and transmission delays for the preceding +packet. + +

      When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: + +

      Variable Description + +


      flags + +peer flags (see Autokey specification) + +


      host + +Autokey server name + +


      flags + +peer flags (see Autokey specification) + +


      signature + +OpenSSL digest/signature scheme + +


      initsequence + +initial key ID + +


      initkey + +initial key index + +


      timestamp + +Autokey signature timestamp + +
      + +

      +


      +Previous: Peer Variables, +Up: Top +
      +
      + + +

      Clock Variables

      + +

      The following clock variables appear in the cv billboard for each association with a reference clock. Not all variables are displayed in some configurations. + +

      Variable Description +
      associd +association ID +
      status +clock status word +
      device +device description +
      timecode +ASCII time code string (specific to device) +
      poll +poll messages sent +
      noreply +no reply +
      badformat +bad format +
      baddata +bad date or time +
      fudgetime1 +fudge time 1 +
      fudgetime2 +fudge time 2 +
      stratum +driver stratum +
      refid +driver reference ID +
      flags +driver flags +
      + + + diff --git a/contrib/ntp/ntpq/ntpq.man.in b/contrib/ntp/ntpq/ntpq.man.in new file mode 100644 index 000000000..0c0af5b90 --- /dev/null +++ b/contrib/ntp/ntpq/ntpq.man.in @@ -0,0 +1,1421 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpq @NTPQ_MS@ "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-joa4fN/ag-voaWeN) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:23 PM by AutoGen 5.18.5 +.\" From the definitions ntpq-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpq\fP +\- standard NTP query program +.SH SYNOPSIS +\f\*[B-Font]ntpq\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[ host ...] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The +\f\*[B-Font]ntpq\fP +utility program is used to query NTP servers which +implement the standard NTP mode 6 control message formats defined +in Appendix B of the NTPv3 specification RFC1305, requesting +information about current state and/or changes in that state. +The same formats are used in NTPv4, although some of the +variables have changed and new ones added. The description on this +page is for the NTPv4 variables. +The program may be run either in interactive mode or controlled using +command line arguments. +Requests to read and write arbitrary +variables can be assembled, with raw and pretty-printed output +options being available. +The +\f\*[B-Font]ntpq\fP +utility can also obtain and print a +list of peers in a common format by sending multiple queries to the +server. +If one or more request options is included on the command line +when +\f\*[B-Font]ntpq\fP +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +\f\*[B-Font]ntpq\fP +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +\f\*[B-Font]ntpq\fP +utility will prompt for +commands if the standard input is a terminal device. +\f\*[B-Font]ntpq\fP +uses NTP mode 6 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +\f\*[B-Font]ntpq\fP +utility makes +one attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +Specifying a +command line option other than +\f\*[B-Font]\-i\f[] +or +\f\*[B-Font]\-n\f[] +will +cause the specified query (queries) to be sent to the indicated +host(s) immediately. +Otherwise, +\f\*[B-Font]ntpq\fP +will attempt to read +interactive format commands from the standard input. +.SS "Internal Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +A +number of interactive format commands are executed entirely within +the +\f\*[B-Font]ntpq\fP +utility itself and do not result in NTP mode 6 +requests being sent to a server. +These are described following. +.TP 20 +.NOP \f\*[B-Font]?\f[] [\f\*[I-Font]command_keyword\f[]] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]help\f[] [\f\*[I-Font]command_keyword\f[]] +A +\[oq]\&?\[cq] +by itself will print a list of all the command +keywords known to this incarnation of +\f\*[B-Font]ntpq\fP. +A +\[oq]\&?\[cq] +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +\f\*[B-Font]ntpq\fP +than this manual +page. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]addvars\f[] \f\*[I-Font]variable_name\f[][\f\*[B-Font]=value\f[]] \f\*[B-Font]...\f[] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]rmvars\f[] \f\*[I-Font]variable_name\f[] \f\*[B-Font]...\f[] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]clearvars\f[] +.br +.ns +.TP 20 +.NOP \f\*[B-Font]showvars\f[] +The data carried by NTP mode 6 messages consists of a list of +items of the form +\[oq]variable_name=value\[cq], +where the +\[oq]=value\[cq] +is ignored, and can be omitted, +in requests to the server to read variables. +The +\f\*[B-Font]ntpq\fP +utility maintains an internal list in which data to be included in control +messages can be assembled, and sent using the +\f\*[B-Font]readlist\f[] +and +\f\*[B-Font]writelist\f[] +commands described below. +The +\f\*[B-Font]addvars\f[] +command allows variables and their optional values to be added to +the list. +If more than one variable is to be added, the list should +be comma-separated and not contain white space. +The +\f\*[B-Font]rmvars\f[] +command can be used to remove individual variables from the list, +while the +\f\*[B-Font]clearlist\f[] +command removes all variables from the +list. +The +\f\*[B-Font]showvars\f[] +command displays the current list of optional variables. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]authenticate\f[] [yes | no] +Normally +\f\*[B-Font]ntpq\fP +does not authenticate requests unless +they are write requests. +The command +\[oq]authenticate yes\[cq] +causes +\f\*[B-Font]ntpq\fP +to send authentication with all requests it +makes. +Authenticated requests causes some servers to handle +requests slightly differently, and can occasionally melt the CPU in +fuzzballs if you turn authentication on before doing a +\f\*[B-Font]peer\f[] +display. +The command +\[oq]authenticate\[cq] +causes +\f\*[B-Font]ntpq\fP +to display whether or not +\f\*[B-Font]ntpq\fP +is currently autheinticating requests. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]cooked\f[] +Causes output from query commands to be "cooked", so that +variables which are recognized by +\f\*[B-Font]ntpq\fP +will have their +values reformatted for human consumption. +Variables which +\f\*[B-Font]ntpq\fP +thinks should have a decodable value but didn't are +marked with a trailing +\[oq]\&?\[cq]. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]debug\f[] [\f\*[B-Font]more\f[] | \f\*[B-Font]less\f[] | \f\*[B-Font]off\f[]] +With no argument, displays the current debug level. +Otherwise, the debug level is changed to the indicated level. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]delay\f[] \f\*[I-Font]milliseconds\f[] +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]exit\f[] +Exit +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]host\f[] \f\*[I-Font]hostname\f[] +Set the host to which future queries will be sent. +\f\*[I-Font]hostname\f[] +may be either a host name or a numeric address. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]hostnames\f[] [\f\*[B-Font]yes\f[] | \f\*[B-Font]no\f[]] +If +\f\*[B-Font]yes\f[] +is specified, host names are printed in +information displays. +If +\f\*[B-Font]no\f[] +is specified, numeric +addresses are printed instead. +The default is +\f\*[B-Font]yes\f[], +unless +modified using the command line +\f\*[B-Font]\-n\f[] +switch. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]keyid\f[] \f\*[I-Font]keyid\f[] +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to the +\f\*[B-Font]controlkey\f[] +key number the server has been configured to use for this +purpose. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]keytype\f[] [\f\*[B-Font]md5\f[] | \f\*[B-Font]OpenSSLDigestType\f[]] +Specify the type of key to use for authenticating requests. +\f\*[B-Font]md5\f[] +is alway supported. +If +\f\*[B-Font]ntpq\fP +was built with OpenSSL support, +any digest type supported by OpenSSL can also be provided. +If no argument is given, the current +\f\*[B-Font]keytype\f[] +is displayed. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]ntpversion\f[] [\f\*[B-Font]1\f[] | \f\*[B-Font]2\f[] | \f\*[B-Font]3\f[] | \f\*[B-Font]4\f[]] +Sets the NTP version number which +\f\*[B-Font]ntpq\fP +claims in +packets. +Defaults to 3, and note that mode 6 control messages (and +modes, for that matter) didn't exist in NTP version 1. +There appear +to be no servers left which demand version 1. +With no argument, displays the current NTP version that will be used +when communicating with servers. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]passwd\f[] +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.\" Not yet implemented. +.\" .It Ic poll +.\" .Op Ar n +.\" .Op Ic verbose +.\" Poll an NTP server in client mode +.\" .Ar n +.\" times. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]quit\f[] +Exit +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]raw\f[] +Causes all output from query commands is printed as received +from the remote server. +The only formating/interpretation done on +the data is to transform nonascii data into a printable (but barely +understandable) form. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]timeout\f[] \f\*[I-Font]milliseconds\f[] +Specify a timeout period for responses to server queries. +The +default is about 5000 milliseconds. +Note that since +\f\*[B-Font]ntpq\fP +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.br +.ns +.TP 20 +.NOP \f\*[B-Font]version\f[] +Print the version of the +\f\*[B-Font]ntpq\fP +program. +.PP +.SS "Control Message Commands" +Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode-6 message to the server and expect a single response message. +The exceptions are the +\f[C]peers\f[] +command, which sends a series of messages, +and the +\f[C]mreadlist\f[] +and +\f[C]mreadvar\f[] +commands, which iterate over a range of associations. +.TP 10 +.NOP \f\*[B-Font]associations\f[] +Display a list of mobilized associations in the form: +.Dl ind assid status conf reach auth condition last_event cnt +.RS +.IP \fB\(bu\fP 2 +.IP \fB\(bu\fP 2 \f[C]ind\f[] \f[C]Ta\f[] \f[C]index\f[] \f[C]on\f[] \f[C]this\f[] \f[C]list\f[] +.IP \fB\(bu\fP 2 \f[C]assid\f[] \f[C]Ta\f[] \f[C]association\f[] \f[C]ID\f[] +.IP \fB\(bu\fP 2 \f[C]status\f[] \f[C]Ta\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word\f[] +.IP \fB\(bu\fP 2 \f[C]conf\f[] \f[C]Ta\f[] \f[C]yes\f[]: \f[C]persistent,\f[] \f[C]no\f[]: \f[C]ephemeral\f[] +.IP \fB\(bu\fP 2 \f[C]reach\f[] \f[C]Ta\f[] \f[C]yes\f[]: \f[C]reachable,\f[] \f[C]no\f[]: \f[C]unreachable\f[] +.IP \fB\(bu\fP 2 \f[C]auth\f[] \f[C]Ta\f[] \f[C]ok\f[], \f[C]yes\f[], \f[C]bad\f[] \f[C]and\f[] \f[C]none\f[] +.IP \fB\(bu\fP 2 \f[C]condition\f[] \f[C]Ta\f[] \f[C]selection\f[] \f[C]status\f[] \f[C](see\f[] \f[C]the\f[] \f[C]select\f[] \f[C]field\f[] \f[C]of\f[] \f[C]the\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word)\f[] +.IP \fB\(bu\fP 2 \f[C]last_event\f[] \f[C]Ta\f[] \f[C]event\f[] \f[C]report\f[] \f[C](see\f[] \f[C]the\f[] \f[C]event\f[] \f[C]field\f[] \f[C]of\f[] \f[C]the\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word)\f[] +.IP \fB\(bu\fP 2 \f[C]cnt\f[] \f[C]Ta\f[] \f[C]event\f[] \f[C]count\f[] \f[C](see\f[] \f[C]the\f[] \f[C]count\f[] \f[C]field\f[] \f[C]of\f[] \f[C]the\f[] \f[C]peer\f[] \f[C]status\f[] \f[C]word)\f[] +.RE +.br +.ns +.TP 10 +.NOP \f\*[B-Font]authinfo\f[] +Display the authentication statistics. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clockvar\f[] \f\*[I-Font]assocID\f[] [\f\*[I-Font]name\f[][\f\*[B-Font]=\f[]\f\*[I-Font]value\f[]] [] ...] +.br +.ns +.TP 10 +.NOP \f\*[B-Font]cv\f[] \f\*[I-Font]assocID\f[] [\f\*[I-Font]name\f[][\f\*[B-Font]=\f[]\f\*[I-Font]value\f[]] [] ...] +Display a list of clock variables for those associations supporting a reference clock. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]:config\f[] [...] +Send the remainder of the command line, including whitespace, to the server as a run-time configuration command in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is of course required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]config-from-file\f[] \f\*[I-Font]filename\f[] +Send the each line of +\f\*[I-Font]filename\f[] +to the server as run-time configuration commands in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ifstats\f[] +Display statistics for each local network address. Authentication is required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]iostats\f[] +Display network and reference clock I/O statistics. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]kerninfo\f[] +Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lassociations\f[] +Perform the same function as the associations command, except display mobilized and unmobilized associations. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lopeers\f[] [\f\*[B-Font]\-4\f[] | \f\*[B-Font]\-6\f[]] +Obtain and print a list of all peers and clients showing +\f\*[I-Font]dstadr\f[] +(associated with any given IP version). +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lpeers\f[] [\f\*[B-Font]\-4\f[] | \f\*[B-Font]\-6\f[]] +Print a peer spreadsheet for the appropriate IP version(s). +\f\*[I-Font]dstadr\f[] +(associated with any given IP version). +.br +.ns +.TP 10 +.NOP \f\*[B-Font]monstats\f[] +Display monitor facility statistics. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mrulist\f[] [\f\*[B-Font]limited\f[] | \f\*[B-Font]kod\f[] | \f\*[B-Font]mincount\f[]=\f\*[I-Font]count\f[] | \f\*[B-Font]laddr\f[]=\f\*[I-Font]localaddr\f[] | \f\*[B-Font]sort\f[]=\f\*[I-Font]sortorder\f[] | \f\*[B-Font]resany\f[]=\f\*[I-Font]hexmask\f[] | \f\*[B-Font]resall\f[]=\f\*[I-Font]hexmask\f[]] +Obtain and print traffic counts collected and maintained by the monitor facility. +With the exception of +\f\*[B-Font]sort\f[]=\f\*[I-Font]sortorder\f[], +the options filter the list returned by +\f\*[B-Font]ntpd.\f[] +The +\f\*[B-Font]limited\f[] +and +\f\*[B-Font]kod\f[] +options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. +The +\f\*[B-Font]mincount\f[]=\f\*[I-Font]count\f[] +option filters entries representing less than +\f\*[I-Font]count\f[] +packets. +The +\f\*[B-Font]laddr\f[]=\f\*[I-Font]localaddr\f[] +option filters entries for packets received on any local address other than +\f\*[I-Font]localaddr\f[]. +\f\*[B-Font]resany\f[]=\f\*[I-Font]hexmask\f[] +and +\f\*[B-Font]resall\f[]=\f\*[I-Font]hexmask\f[] +filter entries containing none or less than all, respectively, of the bits in +\f\*[I-Font]hexmask\f[], +which must begin with +\f\*[B-Font]0x\f[]. +The +\f\*[I-Font]sortorder\f[] +defaults to +\f\*[B-Font]lstint\f[] +and may be any of +\f\*[B-Font]addr\f[], +\f\*[B-Font]count\f[], +\f\*[B-Font]avgint\f[], +\f\*[B-Font]lstint\f[], +or any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: +.RS +.TP 10 +.NOP Column +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]lstint\f[] +Interval in s between the receipt of the most recent packet from this address and the completion of the retrieval of the MRU list by +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]avgint\f[] +Average interval in s between packets from this address. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rstr\f[] +Restriction flags associated with this address. +Most are copied unchanged from the matching +\f\*[B-Font]restrict\f[] +command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this address triggered a rate control response. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]r\f[] +Rate control indicator, either +a period, +\f\*[B-Font]L\f[] +or +\f\*[B-Font]K\f[] +for no rate control response, +rate limiting by discarding, or rate limiting with a KoD response, respectively. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]m\f[] +Packet mode. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]v\f[] +Packet version number. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]count\f[] +Packets received from this address. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rport\f[] +Source port of last packet from this address. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]remote\f[] \f\*[B-Font]address\f[] +DNS name, numeric address, or address followed by +claimed DNS name which could not be verified in parentheses. +.RE +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mreadvar\f[] \f\*[B-Font]assocID\f[] \f\*[B-Font]assocID\f[] [\f\*[I-Font]variable_name\f[][=\f\*[I-Font]value\f[]]] ... +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mrv\f[] \f\*[B-Font]assocID\f[] \f\*[B-Font]assocID\f[] [\f\*[I-Font]variable_name\f[][=\f\*[I-Font]value\f[]]] ... +Perform the same function as the +\f\*[B-Font]readvar\f[] +command, except for a range of association IDs. +This range is determined from the association list cached by the most recent +\f\*[B-Font]associations\f[] +command. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]opeers\f[] [\f\*[B-Font]\-4\f[] | \f\*[B-Font]\-6\f[]] +Obtain and print the old-style list of all peers and clients showing +\f\*[I-Font]dstadr\f[] +(associated with any given IP version), +rather than the +\f\*[I-Font]refid\f[]. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]passociations\f[] +Perform the same function as the +\f\*[B-Font]associations\f[] +command, +except that it uses previously stored data rather than making a new query. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]peers\f[] +Display a list of peers in the form: +.Dl [tally]remote refid st t when pool reach delay offset jitter +.RS +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font][tally]\f[] +single-character code indicating current value of the +\f\*[B-Font]select\f[] +field of the +.Lk decode.html#peer "peer status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]remote\f[] +host name (or IP number) of peer. +The value displayed will be truncated to 15 characters unless the +\f\*[B-Font]\-w\f[] +flag is given, in which case the full value will be displayed +on the first line, +and the remaining data is displayed on the next line. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +association ID or +.Lk decode.html#kiss "'kiss code" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]st\f[] +stratum +.br +.ns +.TP 10 +.NOP \f\*[B-Font]t\f[] +\f\*[B-Font]u\f[]: +unicast or manycast client, +\f\*[B-Font]b\f[]: +broadcast or multicast client, +\f\*[B-Font]l\f[]: +local (reference clock), +\f\*[B-Font]s\f[]: +symmetric (peer), +\f\*[B-Font]A\f[]: +manycast server, +\f\*[B-Font]B\f[]: +broadcast server, +\f\*[B-Font]M\f[]: +multicast server +.br +.ns +.TP 10 +.NOP \f\*[B-Font]when\f[] +sec/min/hr since last received packet +.br +.ns +.TP 10 +.NOP \f\*[B-Font]poll\f[] +poll interval (log2 s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reach\f[] +reach shift register (octal) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]delay\f[] +roundtrip delay +.br +.ns +.TP 10 +.NOP \f\*[B-Font]offset\f[] +offset of server relative to this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]jitter\f[] +jitter +.RE +.br +.ns +.TP 10 +.NOP \f\*[B-Font]apeers\f[] +Display a list of peers in the form: +.Dl [tally]remote refid assid st t when pool reach delay offset jitter +where the output is just like the +\f\*[B-Font]peers\f[] +command except that the +\f\*[B-Font]refid\f[] +is displayed in hex format and the association number is also displayed. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]pstats\f[] \f\*[I-Font]assocID\f[] +Show the statistics for the peer with the given +\f\*[I-Font]assocID\f[]. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]readlist\f[] \f\*[I-Font]assocID\f[] +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rl\f[] \f\*[I-Font]assocID\f[] +Read the system or peer variables included in the variable list. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]readvar\f[] \f\*[I-Font]assocID\f[] \f\*[I-Font]name\f[][=\f\*[I-Font]value\f[]] [, ...] +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rv\f[] \f\*[I-Font]assocID\f[] \f\*[I-Font]name\f[][=\f\*[I-Font]value\f[]] [, ...] +Display the specified variables. +If +\f\*[I-Font]assocID\f[] +is zero, the variables are from the +\fISystem\f[] \fIVariables\f[] +name space, otherwise they are from the +\fIPeer\f[] \fIVariables\f[] +name space. +The +\f\*[I-Font]assocID\f[] +is required, as the same name can occur in both spaces. +If no +\f\*[I-Font]name\f[] +is included, all operative variables in the name space are displayed. +In this case only, if the +\f\*[I-Font]assocID\f[] +is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds +and frequency values in parts-per-million (PPM). +Some NTP timestamps are represented in the format +YYYYMMDDTTTT , +where YYYY is the year, +MM the month of year, +DD the day of month and +TTTT the time of day. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reslist\f[] +Show the access control (restrict) list for +\f\*[B-Font]ntpq\fP. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]saveconfig\f[] \f\*[I-Font]filename\f[] +Write the current configuration, +including any runtime modifications given with +\f\*[B-Font]:config\f[] +or +\f\*[B-Font]config-from-file\f[], +to the ntpd host's file +\f\*[I-Font]filename\f[]. +This command will be rejected by the server unless +.Lk miscopt.html#saveconfigdir "saveconfigdir" +appears in the +\f\*[B-Font]ntpd\f[] +configuration file. +\f\*[I-Font]filename\f[] +can use +\fCstrftime\f[]\fR()\f[] +format specifies to substitute the current date and time, for example, +\f\*[B-Font]q]saveconfig\f[] \f\*[B-Font]ntp-%Y%m%d-%H%M%S.confq]\f[]. +The filename used is stored in system variable +\f\*[B-Font]savedconfig\f[]. +Authentication is required. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]timerstats\f[] +Display interval timer counters. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]writelist\f[] \f\*[I-Font]assocID\f[] +Write the system or peer variables included in the variable list. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]writevar\f[] \f\*[I-Font]assocID\f[] \f\*[I-Font]name\f[]=\f\*[I-Font]value\f[] [, ...] +Write the specified variables. +If the +\f\*[I-Font]assocID\f[] +is zero, the variables are from the +\fISystem\f[] \fIVariables\f[] +name space, otherwise they are from the +\fIPeer\f[] \fIVariables\f[] +name space. +The +\f\*[I-Font]assocID\f[] +is required, as the same name can occur in both spaces. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]sysinfo\f[] +Display operational summary. +.br +.ns +.TP 10 +.NOP \f\*[B-Font]sysstats\f[] +Print statistics counters maintained in the protocol module. +.PP +.SS Status Words and Kiss Codes +The current state of the operating program is shown +in a set of status words +maintained by the system. +Status information is also available on a per-association basis. +These words are displayed in the +\f\*[B-Font]rv\f[] +and +\f\*[B-Font]as\f[] +commands both in hexadecimal and in decoded short tip strings. +The codes, tips and short explanations are documented on the +.Lk decode.html "Event Messages and Status Words" +page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. +.sp \n(Ppu +.ne 2 + +Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +.Lk decode.html#kiss "kiss codes" . +The original purpose was for kiss-o'-death (KoD) packets +sent by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. +.SS System Variables +The following system variables appear in the +\f\*[B-Font]rv\f[] +billboard. +Not all variables are displayed in some configurations. +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]status\f[] +.Lk decode.html#sys "system status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]version\f[] +NTP software version and build time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]processor\f[] +hardware platform and version +.br +.ns +.TP 10 +.NOP \f\*[B-Font]system\f[] +operating system and version +.br +.ns +.TP 10 +.NOP \f\*[B-Font]leap\f[] +leap warning indicator (0-3) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]stratum\f[] +stratum (1-15) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]precision\f[] +precision (log2 s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdelay\f[] +total roundtrip delay to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdisp\f[] +total dispersion to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]peer\f[] +system peer association ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]tc\f[] +time constant and poll exponent (log2 s) (3-17) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]mintc\f[] +minimum time constant (log2 s) (3-10) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clock\f[] +date and time of day +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +reference ID or +.Lk decode.html#kiss "kiss code" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reftime\f[] +reference time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]offset\f[] +combined offset of server relative to this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]sys_jitter\f[] +combined system jitter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]frequency\f[] +frequency offset (PPM) relative to hardware clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clk_wander\f[] +clock frequency wander (PPM) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]clk_jitter\f[] +clock jitter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]tai\f[] +TAI-UTC offset (s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]leapsec\f[] +NTP seconds when the next leap second is/was inserted +.br +.ns +.TP 10 +.NOP \f\*[B-Font]expire\f[] +NTP seconds when the NIST leapseconds file expires +.PP +The jitter and wander statistics are exponentially-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. +.sp \n(Ppu +.ne 2 + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, +including some or all of the following, +depending on the particular Autokey dance: +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]host\f[] +Autokey host name for this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ident\f[] +Autokey group name for this host +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +host flags (see Autokey specification) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]digest\f[] +OpenSSL message digest algorithm +.br +.ns +.TP 10 +.NOP \f\*[B-Font]signature\f[] +OpenSSL digest/signature scheme +.br +.ns +.TP 10 +.NOP \f\*[B-Font]update\f[] +NTP seconds at last signature update +.br +.ns +.TP 10 +.NOP \f\*[B-Font]cert\f[] +certificate subject, issuer and certificate flags +.br +.ns +.TP 10 +.NOP \f\*[B-Font]until\f[] +NTP seconds when the certificate expires +.PP +.SS Peer Variables +The following peer variables appear in the +\f\*[B-Font]rv\f[] +billboard for each association. +Not all variables are displayed in some configurations. +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]associd\f[] +association ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]status\f[] +.Lk decode.html#peer "peer status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]srcadr\f[] +source (remote) IP address +.br +.ns +.TP 10 +.NOP \f\*[B-Font]srcport\f[] +source (remote) port +.br +.ns +.TP 10 +.NOP \f\*[B-Font]dstadr\f[] +destination (local) IP address +.br +.ns +.TP 10 +.NOP \f\*[B-Font]dstport\f[] +destination (local) port +.br +.ns +.TP 10 +.NOP \f\*[B-Font]leap\f[] +leap indicator (0-3) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]stratum\f[] +stratum (0-15) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]precision\f[] +precision (log2 s) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdelay\f[] +total roundtrip delay to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]rootdisp\f[] +total root dispersion to the primary reference clock +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +reference ID or +.Lk decode.html#kiss "kiss code" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reftime\f[] +reference time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]reach\f[] +reach register (octal) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]unreach\f[] +unreach counter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]hmode\f[] +host mode (1-6) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]pmode\f[] +peer mode (1-5) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]hpoll\f[] +host poll exponent (log2 s) (3-17) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ppoll\f[] +peer poll exponent (log2 s) (3-17) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]headway\f[] +headway (see +.Lk rate.html "Rate Management and the Kiss-o'-Death Packet" ) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flash\f[] +.Lk decode.html#flash "flash status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]offset\f[] +filter offset +.br +.ns +.TP 10 +.NOP \f\*[B-Font]delay\f[] +filter delay +.br +.ns +.TP 10 +.NOP \f\*[B-Font]dispersion\f[] +filter dispersion +.br +.ns +.TP 10 +.NOP \f\*[B-Font]jitter\f[] +filter jitter +.br +.ns +.TP 10 +.NOP \f\*[B-Font]ident\f[] +Autokey group name for this association +.br +.ns +.TP 10 +.NOP \f\*[B-Font]bias\f[] +unicast/broadcast bias +.br +.ns +.TP 10 +.NOP \f\*[B-Font]xleave\f[] +interleave delay (see +.Lk xleave.html "NTP Interleaved Modes" ) +.PP +The +\f\*[B-Font]bias\f[] +variable is calculated when the first broadcast packet is received +after the calibration volley. +It represents the offset of the broadcast subgraph relative to the unicast subgraph. +The +\f\*[B-Font]xleave\f[] +variable appears only for the interleaved symmetric and interleaved modes. +It represents the internal queuing, buffering and transmission delays +for the preceding packet. +.sp \n(Ppu +.ne 2 + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +peer flags (see Autokey specification) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]host\f[] +Autokey server name +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +peer flags (see Autokey specification) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]signature\f[] +OpenSSL digest/signature scheme +.br +.ns +.TP 10 +.NOP \f\*[B-Font]initsequence\f[] +initial key ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]initkey\f[] +initial key index +.br +.ns +.TP 10 +.NOP \f\*[B-Font]timestamp\f[] +Autokey signature timestamp +.PP +.SS Clock Variables +The following clock variables appear in the +\f\*[B-Font]cv\f[] +billboard for each association with a reference clock. +Not all variables are displayed in some configurations. +.TP 10 +.NOP Variable +Description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]associd\f[] +association ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]status\f[] +.Lk decode.html#clock "clock status word" +.br +.ns +.TP 10 +.NOP \f\*[B-Font]device\f[] +device description +.br +.ns +.TP 10 +.NOP \f\*[B-Font]timecode\f[] +ASCII time code string (specific to device) +.br +.ns +.TP 10 +.NOP \f\*[B-Font]poll\f[] +poll messages sent +.br +.ns +.TP 10 +.NOP \f\*[B-Font]noreply\f[] +no reply +.br +.ns +.TP 10 +.NOP \f\*[B-Font]badformat\f[] +bad format +.br +.ns +.TP 10 +.NOP \f\*[B-Font]baddata\f[] +bad date or time +.br +.ns +.TP 10 +.NOP \f\*[B-Font]fudgetime1\f[] +fudge time 1 +.br +.ns +.TP 10 +.NOP \f\*[B-Font]fudgetime2\f[] +fudge time 2 +.br +.ns +.TP 10 +.NOP \f\*[B-Font]stratum\f[] +driver stratum +.br +.ns +.TP 10 +.NOP \f\*[B-Font]refid\f[] +driver reference ID +.br +.ns +.TP 10 +.NOP \f\*[B-Font]flags\f[] +driver flags +.PP +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.TP +.NOP \f\*[B-Font]\-6\f[], \f\*[B-Font]\-\-ipv6\f[] +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.TP +.NOP \f\*[B-Font]\-c\f[] \f\*[I-Font]cmd\f[], \f\*[B-Font]\-\-command\f[]=\f\*[I-Font]cmd\f[] +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.TP +.NOP \f\*[B-Font]\-d\f[], \f\*[B-Font]\-\-debug\-level\f[] +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.TP +.NOP \f\*[B-Font]\-D\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-set\-debug\-level\f[]=\f\*[I-Font]number\f[] +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.TP +.NOP \f\*[B-Font]\-i\f[], \f\*[B-Font]\-\-interactive\f[] +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, peers. +.sp +Force \fBntpq\fP to operate in interactive mode. +Prompts will be written to the standard output and +commands read from the standard input. +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-numeric\f[] +numeric host addresses. +.sp +Output all host addresses in dotted-quad numeric format rather than +converting to the canonical host names. +.TP +.NOP \f\*[B-Font]\-\-old\-rv\f[] +Always output status line with readvar. +.sp +By default, \fBntpq\fP now suppresses the \fBassocid=...\fP +line that precedes the output of \fBreadvar\fP +(alias \fBrv\fP) when a single variable is requested, such as +\fBntpq \-c "rv 0 offset"\fP. +This option causes \fBntpq\fP to include both lines of output +for a single-variable \fBreadvar\fP. +Using an environment variable to +preset this option in a script will enable both older and +newer \fBntpq\fP to behave identically in this regard. +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-peers\f[] +Print a list of the peers. +This option must not appear in combination with any of the following options: +interactive. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.TP +.NOP \f\*[B-Font]\-w\f[], \f\*[B-Font]\-\-wide\f[] +Display the full 'remote' value. +.sp +Display the full value of the 'remote' value. If this requires +more than 15 characters, display the full value, emit a newline, +and continue the data display properly indented on the next line. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\->\f[] [\f\*[I-Font]cfgfile\f[]], \f\*[B-Font]\-\-save-opts\f[] [=\f\*[I-Font]cfgfile\f[]] +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.TP +.NOP \f\*[B-Font]\-<\f[] \f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-load-opts\f[]=\f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-no-load-opts\f[] +Load options from \fIcfgfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early, +out of order. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPQ_\fP or \fBNTPQ\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "AUTHORS" +The University of Delaware and Network Time Foundation +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntpq\fP +option definitions. diff --git a/contrib/ntp/ntpq/ntpq.mdoc.in b/contrib/ntp/ntpq/ntpq.mdoc.in new file mode 100644 index 000000000..2b20ddc5b --- /dev/null +++ b/contrib/ntp/ntpq/ntpq.mdoc.in @@ -0,0 +1,964 @@ +.Dd October 21 2015 +.Dt NTPQ @NTPQ_MS@ User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpq-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:29 PM by AutoGen 5.18.5 +.\" From the definitions ntpq-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpq +.Nd standard NTP query program +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[ host ...] +.Pp +.Sh DESCRIPTION +The +.Nm +utility program is used to query NTP servers which +implement the standard NTP mode 6 control message formats defined +in Appendix B of the NTPv3 specification RFC1305, requesting +information about current state and/or changes in that state. +The same formats are used in NTPv4, although some of the +variables have changed and new ones added. The description on this +page is for the NTPv4 variables. +The program may be run either in interactive mode or controlled using +command line arguments. +Requests to read and write arbitrary +variables can be assembled, with raw and pretty\-printed output +options being available. +The +.Nm +utility can also obtain and print a +list of peers in a common format by sending multiple queries to the +server. +If one or more request options is included on the command line +when +.Nm +is executed, each of the requests will be sent +to the NTP servers running on each of the hosts given as command +line arguments, or on localhost by default. +If no request options +are given, +.Nm +will attempt to read commands from the +standard input and execute these on the NTP server running on the +first host given on the command line, again defaulting to localhost +when no other host is specified. +The +.Nm +utility will prompt for +commands if the standard input is a terminal device. +.Nm +uses NTP mode 6 packets to communicate with the +NTP server, and hence can be used to query any compatible server on +the network which permits it. +Note that since NTP is a UDP protocol +this communication will be somewhat unreliable, especially over +large distances in terms of network topology. +The +.Nm +utility makes +one attempt to retransmit requests, and will time requests out if +the remote host is not heard from within a suitable timeout +time. +Specifying a +command line option other than +.Fl i +or +.Fl n +will +cause the specified query (queries) to be sent to the indicated +host(s) immediately. +Otherwise, +.Nm +will attempt to read +interactive format commands from the standard input. +.Ss "Internal Commands" +Interactive format commands consist of a keyword followed by zero +to four arguments. +Only enough characters of the full keyword to +uniquely identify the command need be typed. +A +number of interactive format commands are executed entirely within +the +.Nm +utility itself and do not result in NTP mode 6 +requests being sent to a server. +These are described following. +.Bl -tag -width "? [command_keyword]" -compact -offset indent +.It Ic ? Op Ar command_keyword +.It Ic help Op Ar command_keyword +A +.Ql \&? +by itself will print a list of all the command +keywords known to this incarnation of +.Nm . +A +.Ql \&? +followed by a command keyword will print function and usage +information about the command. +This command is probably a better +source of information about +.Nm +than this manual +page. +.It Ic addvars Ar variable_name Ns Xo Op Ic =value +.Ic ... +.Xc +.It Ic rmvars Ar variable_name Ic ... +.It Ic clearvars +.It Ic showvars +The data carried by NTP mode 6 messages consists of a list of +items of the form +.Ql variable_name=value , +where the +.Ql =value +is ignored, and can be omitted, +in requests to the server to read variables. +The +.Nm +utility maintains an internal list in which data to be included in control +messages can be assembled, and sent using the +.Ic readlist +and +.Ic writelist +commands described below. +The +.Ic addvars +command allows variables and their optional values to be added to +the list. +If more than one variable is to be added, the list should +be comma\-separated and not contain white space. +The +.Ic rmvars +command can be used to remove individual variables from the list, +while the +.Ic clearlist +command removes all variables from the +list. +The +.Ic showvars +command displays the current list of optional variables. +.It Ic authenticate Op yes | no +Normally +.Nm +does not authenticate requests unless +they are write requests. +The command +.Ql authenticate yes +causes +.Nm +to send authentication with all requests it +makes. +Authenticated requests causes some servers to handle +requests slightly differently, and can occasionally melt the CPU in +fuzzballs if you turn authentication on before doing a +.Ic peer +display. +The command +.Ql authenticate +causes +.Nm +to display whether or not +.Nm +is currently autheinticating requests. +.It Ic cooked +Causes output from query commands to be "cooked", so that +variables which are recognized by +.Nm +will have their +values reformatted for human consumption. +Variables which +.Nm +thinks should have a decodable value but didn't are +marked with a trailing +.Ql \&? . +.It Xo +.Ic debug +.Oo +.Cm more | +.Cm less | +.Cm off +.Oc +.Xc +With no argument, displays the current debug level. +Otherwise, the debug level is changed to the indicated level. +.It Ic delay Ar milliseconds +Specify a time interval to be added to timestamps included in +requests which require authentication. +This is used to enable +(unreliable) server reconfiguration over long delay network paths +or between machines whose clocks are unsynchronized. +Actually the +server does not now require timestamps in authenticated requests, +so this command may be obsolete. +.It Ic exit +Exit +.Nm . +.It Ic host Ar hostname +Set the host to which future queries will be sent. +.Ar hostname +may be either a host name or a numeric address. +.It Ic hostnames Op Cm yes | Cm no +If +.Cm yes +is specified, host names are printed in +information displays. +If +.Cm no +is specified, numeric +addresses are printed instead. +The default is +.Cm yes , +unless +modified using the command line +.Fl n +switch. +.It Ic keyid Ar keyid +This command allows the specification of a key number to be +used to authenticate configuration requests. +This must correspond +to the +.Cm controlkey +key number the server has been configured to use for this +purpose. +.It Ic keytype Xo Oo +.Cm md5 | +.Cm OpenSSLDigestType +.Oc +.Xc +Specify the type of key to use for authenticating requests. +.Cm md5 +is alway supported. +If +.Nm +was built with OpenSSL support, +any digest type supported by OpenSSL can also be provided. +If no argument is given, the current +.Ic keytype +is displayed. +.It Ic ntpversion Xo Oo +.Cm 1 | +.Cm 2 | +.Cm 3 | +.Cm 4 +.Oc +.Xc +Sets the NTP version number which +.Nm +claims in +packets. +Defaults to 3, and note that mode 6 control messages (and +modes, for that matter) didn't exist in NTP version 1. +There appear +to be no servers left which demand version 1. +With no argument, displays the current NTP version that will be used +when communicating with servers. +.It Ic passwd +This command prompts you to type in a password (which will not +be echoed) which will be used to authenticate configuration +requests. +The password must correspond to the key configured for +use by the NTP server for this purpose if such requests are to be +successful. +.\" Not yet implemented. +.\" .It Ic poll +.\" .Op Ar n +.\" .Op Ic verbose +.\" Poll an NTP server in client mode +.\" .Ar n +.\" times. +.It Ic quit +Exit +.Nm . +.It Ic raw +Causes all output from query commands is printed as received +from the remote server. +The only formating/interpretation done on +the data is to transform nonascii data into a printable (but barely +understandable) form. +.It Ic timeout Ar milliseconds +Specify a timeout period for responses to server queries. +The +default is about 5000 milliseconds. +Note that since +.Nm +retries each query once after a timeout, the total waiting time for +a timeout will be twice the timeout value set. +.It Ic version +Print the version of the +.Nm +program. +.El +.Ss "Control Message Commands" +Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode\-6 message to the server and expect a single response message. +The exceptions are the +.Li peers +command, which sends a series of messages, +and the +.Li mreadlist +and +.Li mreadvar +commands, which iterate over a range of associations. +.Bl -tag -width "something" -compact -offset indent +.It Cm associations +Display a list of mobilized associations in the form: +.Dl ind assid status conf reach auth condition last_event cnt +.Bl -column -offset indent ".Sy Variable" ".Sy Description" +.It Sy String Ta Sy Description +.It Li ind Ta index on this list +.It Li assid Ta association ID +.It Li status Ta peer status word +.It Li conf Ta Li yes : persistent, Li no : ephemeral +.It Li reach Ta Li yes : reachable, Li no : unreachable +.It Li auth Ta Li ok , Li yes , Li bad and Li none +.It Li condition Ta selection status (see the Li select field of the peer status word) +.It Li last_event Ta event report (see the Li event field of the peer status word) +.It Li cnt Ta event count (see the Li count field of the peer status word) +.El +.It Cm authinfo +Display the authentication statistics. +.It Cm clockvar Ar assocID Oo Ar name Ns Oo Cm = Ns Ar value Oc Oc Op ... +.It Cm cv Ar assocID Oo Ar name Ns Oo Cm = Ns Ar value Oc Oc Op ... +Display a list of clock variables for those associations supporting a reference clock. +.It Cm :config Op ... +Send the remainder of the command line, including whitespace, to the server as a run\-time configuration command in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is of course required. +.It Cm config\-from\-file Ar filename +Send the each line of +.Ar filename +to the server as run\-time configuration commands in the same format as a line in the configuration file. This command is experimental until further notice and clarification. Authentication is required. +.It Ic ifstats +Display statistics for each local network address. Authentication is required. +.It Ic iostats +Display network and reference clock I/O statistics. +.It Ic kerninfo +Display kernel loop and PPS statistics. As with other ntpq output, times are in milliseconds. The precision value displayed is in milliseconds as well, unlike the precision system variable. +.It Ic lassociations +Perform the same function as the associations command, except display mobilized and unmobilized associations. +.It Ic lopeers Xo +.Oo Ic \-4 | +.Ic \-6 +.Oc +.Xc +Obtain and print a list of all peers and clients showing +.Ar dstadr +(associated with any given IP version). +.It Ic lpeers Xo +.Oo Ic \-4 | +.Ic \-6 +.Oc +.Xc +Print a peer spreadsheet for the appropriate IP version(s). +.Ar dstadr +(associated with any given IP version). +.It Ic monstats +Display monitor facility statistics. +.It Ic mrulist Oo Ic limited | Ic kod | Ic mincount Ns = Ns Ar count | Ic laddr Ns = Ns Ar localaddr | Ic sort Ns = Ns Ar sortorder | Ic resany Ns = Ns Ar hexmask | Ic resall Ns = Ns Ar hexmask Oc +Obtain and print traffic counts collected and maintained by the monitor facility. +With the exception of +.Cm sort Ns = Ns Ar sortorder , +the options filter the list returned by +.Cm ntpd. +The +.Cm limited +and +.Cm kod +options return only entries representing client addresses from which the last packet received triggered either discarding or a KoD response. +The +.Cm mincount Ns = Ns Ar count +option filters entries representing less than +.Ar count +packets. +The +.Cm laddr Ns = Ns Ar localaddr +option filters entries for packets received on any local address other than +.Ar localaddr . +.Cm resany Ns = Ns Ar hexmask +and +.Cm resall Ns = Ns Ar hexmask +filter entries containing none or less than all, respectively, of the bits in +.Ar hexmask , +which must begin with +.Cm 0x . +The +.Ar sortorder +defaults to +.Cm lstint +and may be any of +.Cm addr , +.Cm count , +.Cm avgint , +.Cm lstint , +or any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: +.Bl -tag -width "something" -compact -offset indent +.It Column +Description +.It Ic lstint +Interval in s between the receipt of the most recent packet from this address and the completion of the retrieval of the MRU list by +.Nm . +.It Ic avgint +Average interval in s between packets from this address. +.It Ic rstr +Restriction flags associated with this address. +Most are copied unchanged from the matching +.Ic restrict +command, however 0x400 (kod) and 0x20 (limited) flags are cleared unless the last packet from this address triggered a rate control response. +.It Ic r +Rate control indicator, either +a period, +.Ic L +or +.Ic K +for no rate control response, +rate limiting by discarding, or rate limiting with a KoD response, respectively. +.It Ic m +Packet mode. +.It Ic v +Packet version number. +.It Ic count +Packets received from this address. +.It Ic rport +Source port of last packet from this address. +.It Ic remote address +DNS name, numeric address, or address followed by +claimed DNS name which could not be verified in parentheses. +.El +.It Ic mreadvar assocID assocID Oo Ar variable_name Ns Oo = Ns Ar value Oc Oc ... +.It Ic mrv assocID assocID Oo Ar variable_name Ns Oo = Ns Ar value Oc Oc ... +Perform the same function as the +.Ic readvar +command, except for a range of association IDs. +This range is determined from the association list cached by the most recent +.Ic associations +command. +.It Ic opeers Xo +.Oo Ic \-4 | +.Ic \-6 +.Oc +.Xc +Obtain and print the old\-style list of all peers and clients showing +.Ar dstadr +(associated with any given IP version), +rather than the +.Ar refid . +.It Ic passociations +Perform the same function as the +.Ic associations +command, +except that it uses previously stored data rather than making a new query. +.It Ic peers +Display a list of peers in the form: +.Dl [tally]remote refid st t when pool reach delay offset jitter +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic [tally] +single\-character code indicating current value of the +.Ic select +field of the +.Lk decode.html#peer "peer status word" +.It Ic remote +host name (or IP number) of peer. +The value displayed will be truncated to 15 characters unless the +.Fl w +flag is given, in which case the full value will be displayed +on the first line, +and the remaining data is displayed on the next line. +.It Ic refid +association ID or +.Lk decode.html#kiss "'kiss code" +.It Ic st +stratum +.It Ic t +.Ic u : +unicast or manycast client, +.Ic b : +broadcast or multicast client, +.Ic l : +local (reference clock), +.Ic s : +symmetric (peer), +.Ic A : +manycast server, +.Ic B : +broadcast server, +.Ic M : +multicast server +.It Ic when +sec/min/hr since last received packet +.It Ic poll +poll interval (log2 s) +.It Ic reach +reach shift register (octal) +.It Ic delay +roundtrip delay +.It Ic offset +offset of server relative to this host +.It Ic jitter +jitter +.El +.It Ic apeers +Display a list of peers in the form: +.Dl [tally]remote refid assid st t when pool reach delay offset jitter +where the output is just like the +.Ic peers +command except that the +.Ic refid +is displayed in hex format and the association number is also displayed. +.It Ic pstats Ar assocID +Show the statistics for the peer with the given +.Ar assocID . +.It Ic readlist Ar assocID +.It Ic rl Ar assocID +Read the system or peer variables included in the variable list. +.It Ic readvar Ar assocID Ar name Ns Oo Ns = Ns Ar value Oc Oo , ... Oc +.It Ic rv Ar assocID Ar name Ns Oo Ns = Ns Ar value Oc Oo , ... Oc +Display the specified variables. +If +.Ar assocID +is zero, the variables are from the +.Sx System Variables +name space, otherwise they are from the +.Sx Peer Variables +name space. +The +.Ar assocID +is required, as the same name can occur in both spaces. +If no +.Ar name +is included, all operative variables in the name space are displayed. +In this case only, if the +.Ar assocID +is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds +and frequency values in parts\-per\-million (PPM). +Some NTP timestamps are represented in the format +YYYYMMDDTTTT , +where YYYY is the year, +MM the month of year, +DD the day of month and +TTTT the time of day. +.It Ic reslist +Show the access control (restrict) list for +.Nm . +.It Ic saveconfig Ar filename +Write the current configuration, +including any runtime modifications given with +.Ic :config +or +.Ic config\-from\-file , +to the ntpd host's file +.Ar filename . +This command will be rejected by the server unless +.Lk miscopt.html#saveconfigdir "saveconfigdir" +appears in the +.Ic ntpd +configuration file. +.Ar filename +can use +.Xr strftime +format specifies to substitute the current date and time, for example, +.Ic q]saveconfig ntp\-%Y%m%d\-%H%M%S.confq] . +The filename used is stored in system variable +.Ic savedconfig . +Authentication is required. +.It Ic timerstats +Display interval timer counters. +.It Ic writelist Ar assocID +Write the system or peer variables included in the variable list. +.It Ic writevar Ar assocID Ar name Ns = Ns Ar value Op , ... +Write the specified variables. +If the +.Ar assocID +is zero, the variables are from the +.Sx System Variables +name space, otherwise they are from the +.Sx Peer Variables +name space. +The +.Ar assocID +is required, as the same name can occur in both spaces. +.It Ic sysinfo +Display operational summary. +.It Ic sysstats +Print statistics counters maintained in the protocol module. +.El +.Ss Status Words and Kiss Codes +The current state of the operating program is shown +in a set of status words +maintained by the system. +Status information is also available on a per\-association basis. +These words are displayed in the +.Ic rv +and +.Ic as +commands both in hexadecimal and in decoded short tip strings. +The codes, tips and short explanations are documented on the +.Lk decode.html "Event Messages and Status Words" +page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. +.Pp +Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +.Lk decode.html#kiss "kiss codes" . +The original purpose was for kiss\-o'\-death (KoD) packets +sent by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. +.Ss System Variables +The following system variables appear in the +.Ic rv +billboard. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic status +.Lk decode.html#sys "system status word" +.It Ic version +NTP software version and build time +.It Ic processor +hardware platform and version +.It Ic system +operating system and version +.It Ic leap +leap warning indicator (0\-3) +.It Ic stratum +stratum (1\-15) +.It Ic precision +precision (log2 s) +.It Ic rootdelay +total roundtrip delay to the primary reference clock +.It Ic rootdisp +total dispersion to the primary reference clock +.It Ic peer +system peer association ID +.It Ic tc +time constant and poll exponent (log2 s) (3\-17) +.It Ic mintc +minimum time constant (log2 s) (3\-10) +.It Ic clock +date and time of day +.It Ic refid +reference ID or +.Lk decode.html#kiss "kiss code" +.It Ic reftime +reference time +.It Ic offset +combined offset of server relative to this host +.It Ic sys_jitter +combined system jitter +.It Ic frequency +frequency offset (PPM) relative to hardware clock +.It Ic clk_wander +clock frequency wander (PPM) +.It Ic clk_jitter +clock jitter +.It Ic tai +TAI\-UTC offset (s) +.It Ic leapsec +NTP seconds when the next leap second is/was inserted +.It Ic expire +NTP seconds when the NIST leapseconds file expires +.El +The jitter and wander statistics are exponentially\-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. +.Pp +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, +including some or all of the following, +depending on the particular Autokey dance: +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic host +Autokey host name for this host +.It Ic ident +Autokey group name for this host +.It Ic flags +host flags (see Autokey specification) +.It Ic digest +OpenSSL message digest algorithm +.It Ic signature +OpenSSL digest/signature scheme +.It Ic update +NTP seconds at last signature update +.It Ic cert +certificate subject, issuer and certificate flags +.It Ic until +NTP seconds when the certificate expires +.El +.Ss Peer Variables +The following peer variables appear in the +.Ic rv +billboard for each association. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic associd +association ID +.It Ic status +.Lk decode.html#peer "peer status word" +.It Ic srcadr +source (remote) IP address +.It Ic srcport +source (remote) port +.It Ic dstadr +destination (local) IP address +.It Ic dstport +destination (local) port +.It Ic leap +leap indicator (0\-3) +.It Ic stratum +stratum (0\-15) +.It Ic precision +precision (log2 s) +.It Ic rootdelay +total roundtrip delay to the primary reference clock +.It Ic rootdisp +total root dispersion to the primary reference clock +.It Ic refid +reference ID or +.Lk decode.html#kiss "kiss code" +.It Ic reftime +reference time +.It Ic reach +reach register (octal) +.It Ic unreach +unreach counter +.It Ic hmode +host mode (1\-6) +.It Ic pmode +peer mode (1\-5) +.It Ic hpoll +host poll exponent (log2 s) (3\-17) +.It Ic ppoll +peer poll exponent (log2 s) (3\-17) +.It Ic headway +headway (see +.Lk rate.html "Rate Management and the Kiss\-o'\-Death Packet" ) +.It Ic flash +.Lk decode.html#flash "flash status word" +.It Ic offset +filter offset +.It Ic delay +filter delay +.It Ic dispersion +filter dispersion +.It Ic jitter +filter jitter +.It Ic ident +Autokey group name for this association +.It Ic bias +unicast/broadcast bias +.It Ic xleave +interleave delay (see +.Lk xleave.html "NTP Interleaved Modes" ) +.El +The +.Ic bias +variable is calculated when the first broadcast packet is received +after the calibration volley. +It represents the offset of the broadcast subgraph relative to the unicast subgraph. +The +.Ic xleave +variable appears only for the interleaved symmetric and interleaved modes. +It represents the internal queuing, buffering and transmission delays +for the preceding packet. +.Pp +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic flags +peer flags (see Autokey specification) +.It Ic host +Autokey server name +.It Ic flags +peer flags (see Autokey specification) +.It Ic signature +OpenSSL digest/signature scheme +.It Ic initsequence +initial key ID +.It Ic initkey +initial key index +.It Ic timestamp +Autokey signature timestamp +.El +.Ss Clock Variables +The following clock variables appear in the +.Ic cv +billboard for each association with a reference clock. +Not all variables are displayed in some configurations. +.Bl -tag -width "something" -compact -offset indent +.It Variable +Description +.It Ic associd +association ID +.It Ic status +.Lk decode.html#clock "clock status word" +.It Ic device +device description +.It Ic timecode +ASCII time code string (specific to device) +.It Ic poll +poll messages sent +.It Ic noreply +no reply +.It Ic badformat +bad format +.It Ic baddata +bad date or time +.It Ic fudgetime1 +fudge time 1 +.It Ic fudgetime2 +fudge time 2 +.It Ic stratum +driver stratum +.It Ic refid +driver reference ID +.It Ic flags +driver flags +.El +.Sh "OPTIONS" +.Bl -tag +.It Fl 4 , Fl \-ipv4 +Force IPv4 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp +Force DNS resolution of following host names on the command line +to the IPv4 namespace. +.It Fl 6 , Fl \-ipv6 +Force IPv6 DNS name resolution. +This option must not appear in combination with any of the following options: +ipv4. +.sp +Force DNS resolution of following host names on the command line +to the IPv6 namespace. +.It Fl c Ar cmd , Fl \-command Ns = Ns Ar cmd +run a command and exit. +This option may appear an unlimited number of times. +.sp +The following argument is interpreted as an interactive format command +and is added to the list of commands to be executed on the specified +host(s). +.It Fl d , Fl \-debug\-level +Increase debug verbosity level. +This option may appear an unlimited number of times. +.sp +.It Fl D Ar number , Fl \-set\-debug\-level Ns = Ns Ar number +Set the debug verbosity level. +This option may appear an unlimited number of times. +This option takes an integer number as its argument. +.sp +.It Fl i , Fl \-interactive +Force ntpq to operate in interactive mode. +This option must not appear in combination with any of the following options: +command, peers. +.sp +Force \fBntpq\fP to operate in interactive mode. +Prompts will be written to the standard output and +commands read from the standard input. +.It Fl n , Fl \-numeric +numeric host addresses. +.sp +Output all host addresses in dotted\-quad numeric format rather than +converting to the canonical host names. +.It Fl \-old\-rv +Always output status line with readvar. +.sp +By default, \fBntpq\fP now suppresses the \fBassocid=...\fP +line that precedes the output of \fBreadvar\fP +(alias \fBrv\fP) when a single variable is requested, such as +\fBntpq \-c "rv 0 offset"\fP. +This option causes \fBntpq\fP to include both lines of output +for a single\-variable \fBreadvar\fP. +Using an environment variable to +preset this option in a script will enable both older and +newer \fBntpq\fP to behave identically in this regard. +.It Fl p , Fl \-peers +Print a list of the peers. +This option must not appear in combination with any of the following options: +interactive. +.sp +Print a list of the peers known to the server as well as a summary +of their state. This is equivalent to the 'peers' interactive command. +.It Fl w , Fl \-wide +Display the full 'remote' value. +.sp +Display the full value of the 'remote' value. If this requires +more than 15 characters, display the full value, emit a newline, +and continue the data display properly indented on the next line. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl > Oo Ar cfgfile Oc , Fl \-save\-opts Oo Ns = Ns Ar cfgfile Oc +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.It Fl < Ar cfgfile , Fl \-load\-opts Ns = Ns Ar cfgfile , Fl \-no\-load\-opts +Load options from \fIcfgfile\fP. +The \fIno\-load\-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no\-load\-opts\fP is handled early, +out of order. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPQ_\fP or \fBNTPQ\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "AUTHORS" +The University of Delaware and Network Time Foundation +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntpq\fP +option definitions. diff --git a/contrib/ntp/ntpq/ntpq.texi b/contrib/ntp/ntpq/ntpq.texi new file mode 100644 index 000000000..ac79dcc49 --- /dev/null +++ b/contrib/ntp/ntpq/ntpq.texi @@ -0,0 +1,834 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntpq.info +@settitle ntpq: Network Time Protocol Query User's Manual +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of the NTP Project's ntpq, a program for +querying the state of an NTP server. +@end ifinfo + +@direntry +* ntpq: (ntpq). NTP Query program +@end direntry + +@titlepage +@title ntpq: Network Time Protocol Query User's Manual +@subtitle ntpq, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@shortcontents + +@node Top, ntpq Description, (dir), (dir) +@top ntpq: Network Time Protocol Query User Manual + +The @code{ntpq} utility program is used to +monitor the operational status +and determine the performance of +@code{ntpd}, the NTP daemon. + +This document applies to version @value{VERSION} of @code{ntpq}. + +@menu +* ntpq Description:: +* ntpq Invocation:: Invoking ntpq +* Usage:: +* Internal Commands:: +* Control Message Commands:: +* Status Words and Kiss Codes:: +* System Variables:: +* Peer Variables:: +* Clock Variables:: +@end menu + +@node ntpq Description, Usage, Top, Top +@comment node-name, next, previous, up +@section Description + +The @code{ntpq} utility program is used to monitor NTP daemon @code{ntpd} operations and determine performance. +It uses the standard NTP mode 6 control message formats defined in +Appendix B of the NTPv3 specification RFC1305. +The same formats are used in NTPv4, although some of the variable names have changed and new ones added. +The description on this page is for the NTPv4 variables. + +The program can be run either in interactive mode or controlled using command line arguments. Requests to read and write arbitrary variables can be assembled, with raw and pretty-printed output options being available. The @code{ntpq} can also obtain and print a list of peers in a common format by sending multiple queries to the server. + +If one or more request options is included on the command line when @code{ntpq} is executed, each of the requests will be sent to the NTP servers running on each of the hosts given as command line arguments, or on localhost by default. If no request options are given, @code{ntpq} will attempt to read commands from the standard input and execute these on the NTP server running on the first host given on the command line, again defaulting to localhost when no other host is specified. @code{ntpq} will prompt for commands if the standard input is a terminal device. + +@code{ntpq} uses NTP mode 6 packets to communicate with the NTP server, and hence can be used to query any compatible server on the network which permits it. Note that since NTP is a UDP protocol this communication will be somewhat unreliable, especially over large distances in terms of network topology. @code{ntpq} makes one attempt to retransmit requests, and will time requests out if the remote host is not heard from within a suitable timeout time. + +Note that in contexts where a host name is expected, a @code{-4} qualifier preceding the host name forces DNS resolution to the IPv4 namespace, while a @code{-6} qualifier forces DNS resolution to the IPv6 namespace. + +For examples and usage, see the @url{debug.html, NTP Debugging Techniques} page. + +@include invoke-ntpq.texi + +@node Usage, Internal Commands, ntpq Description, Top +@comment node-name, next, previous, up +@section Usage + +@multitable @columnfractions .23 .23 .05 .15 +@headitem What @tab Default @tab Flag @tab Option +@item configuration file +@tab @code{/etc/ntp.conf} +@tab @code{-c} +@tab @code{conffile} +@item frequency file +@tab none +@tab @code{-f} +@tab @code{driftfile} +@item leapseconds file +@tab none +@tab +@tab @code{leapfile} +@item process ID file +@tab none +@tab @code{-p} +@tab @code{pidfile} +@item log file +@tab system log +@tab @code{-l} +@tab @code{logfile} +@item include file +@tab none +@tab none +@tab @code{includefile} +@item statistics path +@tab @code{/var/NTP} +@tab @code{-s} +@tab @code{statsdir} +@item keys path +@tab @code{/usr/local/etc} +@tab @code{-k} +@tab @code{keysdir} +@end multitable + +@node Internal Commands, Control Message Commands, Usage, Top +@comment node-name, next, previous, up +@section Internal Commands + +Interactive format commands consist of a keyword followed by zero to four arguments. Only enough characters of the full keyword to uniquely identify the command need be typed. The output of a command is normally sent to the standard output, but optionally the output of individual commands may be sent to a file by appending a @code{>}, followed by a file name, to the command line. A number of interactive format commands are executed entirely within the @code{ntpq} program itself and do not result in NTP mode-6 requests being sent to a server. These are described following. + +@table @code + +@item @anchor{help} @code{? [}@kbd{command_keyword}@code{]} +@itemx @code{help [}@kbd{command_keyword}@code{]} +A @code{?} by itself will print a list of all the command keywords known to @code{ntpq}. A @code{?} followed by a command keyword will print function and usage information about the command. + +@item @anchor{addvars} >@code{addvars @kbd{name} [ = @kbd{value}] [...]} +@itemx @code{rmvars @kbd{name} [...]} +@itemx @code{clearvars} +The arguments to these commands consist of a list of items of the form +@code{@kbd{name} = @kbd{value}}, where the @code{= @kbd{value}} is ignored, +and can be omitted in read requests. +@code{ntpq} maintains an internal list in which data to be included +in control messages can be assembled, and sent using the @code{readlist} +and @code{writelist} commands described below. +The @code{addvars} command allows variables and optional values +to be added to the list. +If more than one variable is to be added +the list should be comma-separated and not contain white space. +The @code{rmvars} command can be used to remove individual variables +from the list, +while the @code{clearlist} command removes all variables from the list. + +@item @anchor{cooked} @code{cooked} +Display server messages in prettyprint format. + +@item @anchor{debug} @code{debug more | less | off} +Turns internal query program debugging on and off. + +@item @anchor{delay} @code{delay @kbd{milliseconds}} +Specify a time interval to be added to timestamps included in requests which require authentication. This is used to enable (unreliable) server reconfiguration over long delay network paths or between machines whose clocks are unsynchronized. Actually the server does not now require timestamps in authenticated requests, so this command may be obsolete. + +@item @anchor{host} @code{host @kbd{name}} +Set the host to which future queries will be sent. +The name may be either a DNS name or a numeric address. + +@item @anchor{hostnames} @code{hostnames [yes | no]} +If @code{yes} is specified, host names are printed in information displays. +If @code{no} is specified, numeric addresses are printed instead. +The default is @code{yes}, +unless modified using the command line @code{-n} switch. + +@item @anchor{keyid} @code{keyid @kbd{keyid}} +This command specifies the key number to be used +to authenticate configuration requests. +This must correspond to a key ID configured in @code{ntp.conf} for this purpose. + +@item @anchor{keytype} @code{keytype} +Specify the digest algorithm to use for authenticated requests, +with default @code{MD5}. +If the OpenSSL library is installed, +digest can be be any message digest algorithm supported by the library. +The current selections are: @code{MD2}, @code{MD4}, @code{MD5}, @code{MDC2}, @code{RIPEMD160}, @code{SHA} and @code{SHA1}. + +@item @anchor{ntpversion} @code{ntpversion 1 | 2 | 3 | 4} +Sets the NTP version number which @code{ntpq} claims in packets. +Defaults to 2. +Note that mode-6 control messages (and modes, for that matter) +didn't exist in NTP version 1. + +@item @anchor{passwd} @code{passwd} +This command prompts for a password to authenticate requests. +The password must correspond to the key ID configured in @code{ntp.conf} for this purpose. + +@item @anchor{quit} @code{quit} +Exit @code{ntpq}. + +@item @anchor{raw} @code{raw} +Display server messages as received and without reformatting. + +@item @anchor{timeout} @code{timeout @kbd{millseconds}} +Specify a timeout period for responses to server queries. +The default is about 5000 milliseconds. +Note that since @code{ntpq} retries each query once after a timeout +the total waiting time for a timeout will be twice the timeout value set. + +@end table + +@node Control Message Commands, Status Words and Kiss Codes, Internal Commands, Top +@comment node-name, next, previous, up +@section Control Message Commands + +Association IDs are used to identify system, peer and clock variables. +System variables are assigned an association ID of zero and system name space, +while each association is assigned a nonzero association ID and peer namespace. +Most control commands send a single mode-6 message to the server +and expect a single response message. +The exceptions are the @code{peers} command, +which sends a series of messages, +and the @code{mreadlist} and @code{mreadvar} commands, +which iterate over a range of associations. + +@anchor{as} +@table @code +@item @code{associations} +Display a list of mobilized associations in the form: +@* +@code{ind assid status conf reach auth condition last_event cnt} + +@multitable @columnfractions .1 .4 +@headitem Variable @tab Description + +@item @code{ind} +@tab index on this list + +@item @code{assid} +@tab association ID + +@item @code{status} +@tab @url{decode.html#peer, peer status word} + +@item @code{conf} +@tab @code{yes}: persistent, @code{no}: ephemeral + +@item @code{reach} +@tab @code{yes}: reachable, @code{no}: unreachable + +@item @code{auth} +@tab @code{ok}, @code{yes}, @code{bad} and @code{none} + +@item @code{condition} +@tab selection status (see the @code{select} field of the @url{decode.html#peer, peer status word}) + +@item @code{last_event} +@tab event report (see the @code{event} field of the @url{decode.html#peer, peer status word}) + +@item @code{cnt} +event count (see the @code{count} field of the @url{decode.html#peer, peer status word}) + +@end multitable + +@item @anchor{cv} clockvar @kbd{assocID} [@kbd{name} [ = @kbd{value} [...]] [...]] +@itemx cv @kbd{assocID} [@kbd{name} [ = @kbd{value} [...] ][...]] +Display a list of @ref{clock,,clock variables} for those associations supporting a reference clock. + +@item @anchor{:config} :config [...] +Send the remainder of the command line, including whitespace, to the server +as a run-time configuration command in the same format +as the configuration file. +This command is experimental until further notice and clarification. +Authentication is of course required. + +@item @anchor{config-from-file} config-from-file @kbd{filename} +Send the each line of @kbd{filename} to the server as +run-time configuration commands in the same format as the configuration file. +This command is experimental until further notice and clarification. +Authentication is required. + +@item @anchor{ifstats} ifstats +Display statistics for each local network address. +Authentication is required. + +@item @anchor{iostats} iostats +Display network and reference clock I/O statistics. + +@item @anchor{kerninfo} kerninfo +Display kernel loop and PPS statistics. +As with other ntpq output, times are in milliseconds. +The precision value displayed is in milliseconds as well, +unlike the precision system variable. + +@item @anchor{lassoc} lassociations +Perform the same function as the associations command, +except display mobilized and unmobilized associations. + +@item @anchor{monstats} monstats +Display monitor facility statistics. + +@item @anchor{mrulist} mrulist [limited | kod | mincount=@kbd{count} | laddr=@kbd{localaddr} | sort=@kbd{sortorder} | resany=@kbd{hexmask} | resall=@kbd{hexmask}] +Obtain and print traffic counts collected and maintained by +the monitor facility. +With the exception of @code{sort=@kbd{sortorder}}, +the options filter the list returned by @code{ntpd}. +The @code{limited} and @code{kod} options return only entries +representing client addresses from which the last packet received +triggered either discarding or a KoD response. +The @code{mincount=@kbd{count}} option filters entries representing +less than @code{@kbd{count}} packets. +The @code{laddr=@kbd{localaddr}} option filters entries for packets +received on any local address other than @code{@kbd{localaddr}}. +@code{resany=@kbd{hexmask}} and @code{resall=@kbd{hexmask}} +filter entries containing none or less than all, respectively, +of the bits in @code{@kbd{hexmask}}, which must begin with @code{0x}. +@* +The @code{@kbd{sortorder}} defaults to @code{lstint} and may be any of +@code{addr}, @code{count}, @code{avgint}, @code{lstint}, or +any of those preceded by a minus sign (hyphen) to reverse the sort order. +The output columns are: + +@multitable @columnfractions .1 .4 +@headitem Column @tab Description + +@item @code{lstint} +@tab +Interval in s between the receipt of the most recent packet from this +address and the completion of the retrieval of the MRU list by @code{ntpq} + +@item @code{avgint} +@tab +Average interval in s between packets from this address. + +@item @code{rstr} +@tab +Restriction flags associated with this address. +Most are copied unchanged from the matching @code{restrict} command, +however 0x400 (kod) and 0x20 (limited) flags are cleared unless +the last packet from this address triggered a rate control response. + +@item @code{r} +@tab +Rate control indicator, either a period, @code{L} or @code{K} for +no rate control response, rate limiting by discarding, or +rate limiting with a KoD response, respectively. + +@item @code{m} +@tab +Packet mode. +@item @code{v} +@tab +Packet version number. + +@item @code{count} +@tab +Packets received from this address. + +@item @code{rport} +@tab +Source port of last packet from this address. + +@item @code{remote address} +@tab +DNS name, numeric address, or address followed by claimed DNS name which +could not be verified in parentheses. + +@end multitable + +@item @anchor{mreadvar} @code{mreadvar @kbd{assocID} @kbd{assocID} [ @kbd{variable_name} [ = @kbd{value}[ ... ]} +@itemx @anchor{mrv} @code{mrv @kbd{assocID} @kbd{assocID} [ @kbd{variable_name} [ = @kbd{value}[ ... ]} +Perform the same function as the @code{readvar} command, +except for a range of association IDs. +This range is determined from the association list cached by +the most recent @code{associations} command. + +@item @anchor{passoc} @code{passociations} +Perform the same function as the @code{associations command}, except that +it uses previously stored data rather than making a new query. + +@item @anchor{pe} @code{peers} +Display a list of peers in the form: +@* +@code{[tally]remote refid st t when pool reach delay offset jitter} + +@multitable @columnfractions .1 .2 +@headitem Variable @tab Description +@item @code{[tally]} +@tab +single-character code indicating current value of the @code{select} field +of the @url{decode.html#peer, peer status word}. + +@item @code{remote} +@tab +host name (or IP number) of peer + +@item @code{refid} +@tab +association ID or @url{decode.html#kiss, kiss code}. + +@item @code{st} +@tab +stratum + +@item @code{t} +@tab +@code{u}: unicast or manycast client, +@code{b}: broadcast or multicast client, +@code{l}: local (reference clock), +@code{s}: symmetric (peer), +@code{A}: manycast server, +@code{B}: broadcast server, +@code{M}: multicast server. + +@item @code{when} +@tab +sec/min/hr since last received packet + +@item @code{poll} +@tab +poll interval (log(2) s) + +@item @code{reach} +@tab +reach shift register (octal) + +@item @code{delay} +@tab +roundtrip delay + +@item @code{offset} +@tab +offset of server relative to this host + +@item @code{jitter} +@tab +jitter + +@end multitable + +@item @anchor{rv} readvar @kbd{assocID} @kbd{name} [ = @kbd{value} ] [,...] +@itemx rv @kbd{assocID} [ @kbd{name} ] [,...] +Display the specified variables. +If @code{@kbd{assocID}} is zero, +the variables are from the @ref{system, system variables} name space, +otherwise they are from the @ref{peer, peer variables} name space. +The @kbd{assocID} is required, as the same name can occur in both spaces. +If no @kbd{name} is included, +all operative variables in the name space are displayed. +In this case only, if the @code{@kbd{assocID}} is omitted, it is assumed zero. +Multiple names are specified with comma separators and without whitespace. +Note that time values are represented in milliseconds and +frequency values in parts-per-million (PPM). +Some NTP timestamps are represented in the format YYYYMMDDTTTT, +where YYYY is the year, MM the month of year, DD the day of month and +TTTT the time of day. + +@item @anchor{saveconfig} @code{saveconfig @kbd{filename}} +Write the current configuration, including any runtime modifications +given with @code{:config} or @code{config-from-file}, +to the ntpd host's file @kbd{filename}. +This command will be rejected by the server unless +@url{miscopt.html#saveconfigdir, saveconfigdir} +appears in the @code{ntpd} configuration file. +@kbd{filename} can use @code{strftime()} format specifiers +to substitute the current date and time, for example, +@code{saveconfig ntp-%Y%m%d-%H%M%S.conf}. +The filename used is stored in system variable @code{savedconfig}. +Authentication is required. + +@item @anchor{writevar} writevar @kbd{assocID} @kbd{name} = @kbd{value} [,...] +Write the specified variables. +If the @code{@kbd{assocID}} is zero, the variables are from the +@ref{system, system variables} name space, otherwise they are from the +@ref{peer, peer variables} name space. +The @code{@kbd{assocID}} is required, +as the same name can occur in both spaces. + +@item @anchor{sysinfo} @code{sysinfo} +Display operational summary. + +@item @anchor{sysstats} @code{sysstats} +Print statistics counters maintained in the protocol module. + +@end table + +@node Status Words and Kiss Codes, System Variables, Control Message Commands, Top +@comment node-name, next, previous, up +@section Status Words and Kiss Codes + +The current state of the operating program is shown +in a set of status words maintained by the system +and each association separately. +These words are displayed in the @code{rv} and @code{as} commands +both in hexadecimal and decoded short tip strings. +The codes, tips and short explanations are on the +@url{decode.html, Event Messages and Status Words} page. +The page also includes a list of system and peer messages, +the code for the latest of which is included in the status word. + +Information resulting from protocol machine state transitions +is displayed using an informal set of ASCII strings called +@url{decode.html#kiss, kiss codes}. +The original purpose was for kiss-o'-death (KoD) packets sent +by the server to advise the client of an unusual condition. +They are now displayed, when appropriate, +in the reference identifier field in various billboards. + +@node System Variables, Peer Variables, Status Words and Kiss Codes, Top +@comment node-name, next, previous, up +@section System Variables + +The following system variables appear in the @code{rv} billboard. +Not all variables are displayed in some configurations. + +@multitable @columnfractions .1 .2 +@headitem Variable @tab Description + +@item @code{status} +@tab +@url{decode.html#sys, system status word} + +@item @code{version} +@tab +NTP software version and build time + +@item @code{processor} +@tab +hardware platform and version + +@item @code{system} +@tab +operating system and version + +@item @code{leap} +@tab +leap warning indicator (0-3) + +@item @code{stratum} +@tab +stratum (1-15) + +@item @code{precision} +@tab +precision (log(2) s) + +@item @code{rootdelay} +@tab +total roundtrip delay to the primary reference clock + +@item @code{rootdisp} +@tab +total dispersion to the primary reference clock + +@item @code{peer} +@tab +system peer association ID + +@item @code{tc} +time constant and poll exponent (log(2) s) (3-17) + +@item @code{mintc} +minimum time constant (log(2) s) (3-10) + +@item @code{clock} +@tab +date and time of day + +@item @code{refid} +reference ID or @url{decode.html#kiss, kiss code} + +@item @code{reftime} +@tab +reference time + +@item @code{offset} +@tab +combined offset of server relative to this host + +@item @code{sys_jitter} +@tab +combined system jitter + +@item @code{frequency} +@tab +frequency offset (PPM) relative to hardware clock + +@item @code{clk_wander} +@tab +clock frequency wander (PPM) + +@item @code{clk_jitter} +@tab +clock jitter + +@item @code{tai} +@tab +TAI-UTC offset (s) + +@item @code{leapsec} +@tab +NTP seconds when the next leap second is/was inserted + +@item @code{expire} +@tab +NTP seconds when the NIST leapseconds file expires + +@end multitable + +The jitter and wander statistics are exponentially-weighted RMS averages. +The system jitter is defined in the NTPv4 specification; +the clock jitter statistic is computed by the clock discipline module. + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional system variables are displayed, including some or all of the +following, depending on the particular Autokey dance: + +@multitable @columnfractions .1 .2 +@headitem Variable @tab Description + +@item @code{host} +@tab +Autokey host name for this host + +@item @code{ident} +@tab +Autokey group name for this host + +@item @code{flags} +@tab +host flags (see Autokey specification) + +@item @code{digest} +@tab +OpenSSL message digest algorithm + +@item @code{signature} +@tab +OpenSSL digest/signature scheme + +@item @code{update} +@tab +NTP seconds at last signature update + +@item @code{cert} +@tab +certificate subject, issuer and certificate flags + +@item @code{until} +@tab +NTP seconds when the certificate expires + +@end multitable + +@node Peer Variables, Clock Variables, System Variables, Top +@comment node-name, next, previous, up +@section Peer Variables + +The following peer variables appear in the @code{rv} billboard +for each association. +Not all variables are displayed in some configurations. + +@multitable @columnfractions .1 .2 +@headitem Variable @tab Description + +@item @code{associd} +@tab +association ID + +@item @code{status} +@tab +@url{decode.html#peer, peer status word} + +@item @code{srcadr} +@itemx @code{srcport} +@tab +source (remote) IP address and port + +@item @code{dstadr} +@itemx @code{dstport} +@tab +destination (local) IP address and port + +@item @code{leap} +@tab +leap indicator (0-3) + +@item @code{stratum} +@tab +stratum (0-15) + +@item @code{precision} +@tab +precision (log(2) s) + +@item @code{rootdelay} +@tab +total roundtrip delay to the primary reference clock + +@item @code{rootdisp} +@tab total root dispersion to the primary reference clock + +@item @code{refid} +@tab +reference ID or @url{decode.html#kiss, kiss code} + +@item @code{reftime} +@tab +reference time + +@item @code{reach} +@tab +reach register (octal) + +@item @code{unreach} +@tab +unreach counter + +@item @code{hmode} +@tab +host mode (1-6) + +@item @code{pmode} +@tab +peer mode (1-5) + +@item @code{hpoll} +@tab +host poll exponent (log(2) s) (3-17) +@item @code{ppoll} +@tab +peer poll exponent (log(2) s) (3-17) + +@item @code{headway} +@tab +headway (see @url{rate.html, Rate Management and the Kiss-o'-Death Packet}) + +@item @code{flash} +@tab +@url{decode.html#flash, flash status word} + +@item @code{offset} +@tab +filter offset + +@item @code{delay} +@tab +filter delay + +@item @code{dispersion} +@tab +filter dispersion + +@item @code{jitter} +@tab +filter jitter + +@item @code{ident} +@tab +Autokey group name for this association + +@item @code{bias} +@tab +unicast/broadcast bias + +@item @code{xleave} +@tab +interleave delay (see @url{xleave.html, NTP Interleaved Modes}) + +@end multitable + +The bias variable is calculated when the first broadcast packet is received +after the calibration volley. It represents the offset of the broadcast +subgraph relative to the unicast subgraph. The xleave variable appears +only the interleaved symmetric and interleaved modes. It represents +the internal queuing, buffering and transmission delays for the preceding +packet. + +When the NTPv4 daemon is compiled with the OpenSSL software library, +additional peer variables are displayed, including the following: + +@multitable @columnfractions .1 .2 +@headitem Variable @tab Description + +@item @code{flags} +@tab +peer flags (see Autokey specification) + +@item @code{host} +@tab +Autokey server name + +@item @code{flags} +@tab +peer flags (see Autokey specification) + +@item @code{signature} +@tab +OpenSSL digest/signature scheme + +@item @code{initsequence} +@tab +initial key ID + +@item @code{initkey} +@tab +initial key index + +@item @code{timestamp} +@tab +Autokey signature timestamp + +@end multitable + +@node Clock Variables, , Peer Variables, Top +@comment node-name, next, previous, up +@section Clock Variables + +The following clock variables appear in the @code{cv} billboard for each association with a reference clock. Not all variables are displayed in some configurations. + +@multitable @columnfractions .1 .2 +@headitem Variable @tab Description +@item @code{associd} +@tab association ID +@item @code{status} +@tab @url{decode.html#clock, clock status word} +@item @code{device} +@tab device description +@item @code{timecode} +@tab ASCII time code string (specific to device) +@item @code{poll} +@tab poll messages sent +@item @code{noreply} +@tab no reply +@item @code{badformat} +@tab bad format +@item @code{baddata} +@tab bad date or time +@item @code{fudgetime1} +@tab fudge time 1 +@item @code{fudgetime2} +@tab fudge time 2 +@item @code{stratum} +@tab driver stratum +@item @code{refid} +@tab driver reference ID +@item @code{flags} +@tab driver flags +@end multitable diff --git a/contrib/ntp/ntpsnmpd/Makefile.am b/contrib/ntp/ntpsnmpd/Makefile.am new file mode 100644 index 000000000..11ecf1b0d --- /dev/null +++ b/contrib/ntp/ntpsnmpd/Makefile.am @@ -0,0 +1,117 @@ +NULL= + +bin_PROGRAMS= $(NTPSNMPD_DB) +libexec_PROGRAMS= $(NTPSNMPD_DL) +sbin_PROGRAMS= $(NTPSNMPD_DS) + +EXTRA_PROGRAMS= ntpsnmpd +ntpsnmpd_SOURCES= netsnmp_daemonize.c ntpsnmpd.c ntpSnmpSubagentObject.c \ + ntpsnmpd-opts.c ntpsnmpd-opts.h ntpSnmpSubagentObject.h \ + ntp_snmp.h +# HMS: we probably want a version.o file here, too. +LDADD = ../ntpq/libntpq.a ../libntp/libntp.a +LDADD += $(SNMP_LIBS) $(LDADD_LIBNTP) $(LIBM) +LDADD += $(PTHREAD_LIBS) $(LDADD_NTP) $(LIBOPTS_LDADD) + +AM_CFLAGS = $(SNMP_CFLAGS) $(CFLAGS_NTP) + +AM_CPPFLAGS = -I$(top_srcdir)/ntpq +AM_CPPFLAGS += $(NTP_INCS) +AM_CPPFLAGS += $(LIBOPTS_CFLAGS) +AM_CPPFLAGS += $(SNMP_CPPFLAGS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +AM_LDFLAGS = $(LDFLAGS_NTP) + +EXTRA_DIST= \ + invoke-ntpsnmpd.menu \ + invoke-ntpsnmpd.texi \ + ntpsnmpd-opts.def \ + ntpsnmpd.1ntpsnmpdman \ + ntpsnmpd.1ntpsnmpdmdoc \ + ntpsnmpd.man.in \ + ntpsnmpd.mdoc.in \ + ntpsnmpd.html \ + ntpsnmpd.texi \ + ntpv4-mib.mib \ + $(NULL) + +BUILT_SOURCES= ntpsnmpd-opts.c ntpsnmpd-opts.h +CLEANFILES= +DISTCLEANFILES= config.log $(man_MANS) + +html_DATA= \ + $(srcdir)/ntpsnmpd.html \ + $(NULL) + +noinst_DATA= \ + $(srcdir)/invoke-ntpsnmpd.menu \ + $(srcdir)/invoke-ntpsnmpd.texi \ + $(srcdir)/ntpsnmpd.man.in \ + $(srcdir)/ntpsnmpd.mdoc.in \ + $(NULL) + +install-data-local: install-html + +man1_MANS= +man8_MANS= +man_MANS= ntpsnmpd.$(NTPSNMPD_MS) + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +$(srcdir)/ntpsnmpd-opts.h: $(srcdir)/ntpsnmpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/ntpsnmpd-opts.c: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) ntpsnmpd-opts.def + +### + +$(srcdir)/ntpsnmpd.1ntpsnmpdman: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpsnmpdman -Tagman-cmd.tpl ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd.man.in: $(srcdir)/ntpsnmpd.1ntpsnmpdman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpsnmpd.1ntpsnmpdman > $(srcdir)/ntpsnmpd.man.in+ + mv $(srcdir)/ntpsnmpd.man.in+ $(srcdir)/ntpsnmpd.man.in + +### + +$(srcdir)/ntpsnmpd.1ntpsnmpdmdoc: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpsnmpdmdoc -Tagmdoc-cmd.tpl ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd.mdoc.in: $(srcdir)/ntpsnmpd.1ntpsnmpdmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpsnmpd.1ntpsnmpdmdoc > $(srcdir)/ntpsnmpd.mdoc.in+ + mv $(srcdir)/ntpsnmpd.mdoc.in+ $(srcdir)/ntpsnmpd.mdoc.in + +### + +ntpsnmpd.$(NTPSNMPD_MS): $(srcdir)/ntpsnmpd.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpsnmpd.$(NTPSNMPD_MS)+:$(srcdir)/ntpsnmpd.$(MANTAGFMT).in + mv ntpsnmpd.$(NTPSNMPD_MS)+ ntpsnmpd.$(NTPSNMPD_MS) + +### + +$(srcdir)/invoke-ntpsnmpd.menu: $(srcdir)/invoke-ntpsnmpd.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpsnmpd.texi: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpsnmpd-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +$(srcdir)/ntpsnmpd.html: $(srcdir)/ntpsnmpd.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntpsnmpd.html ntpsnmpd.texi || true ) + +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/sntp/check-libntp.mf +include $(top_srcdir)/check-libopts.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/ntpsnmpd/Makefile.in b/contrib/ntp/ntpsnmpd/Makefile.in new file mode 100644 index 000000000..7b7f56628 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/Makefile.in @@ -0,0 +1,1271 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +# we traditionally installed software in bindir, while it should have gone +# in sbindir. Now that we offer a choice, look in the "other" installation +# subdir to warn folks if there is another version there. + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +EXTRA_PROGRAMS = ntpsnmpd$(EXEEXT) +subdir = ntpsnmpd +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(sbin_PROGRAMS) +am_ntpsnmpd_OBJECTS = netsnmp_daemonize.$(OBJEXT) ntpsnmpd.$(OBJEXT) \ + ntpSnmpSubagentObject.$(OBJEXT) ntpsnmpd-opts.$(OBJEXT) +ntpsnmpd_OBJECTS = $(am_ntpsnmpd_OBJECTS) +ntpsnmpd_LDADD = $(LDADD) +am__DEPENDENCIES_1 = +ntpsnmpd_DEPENDENCIES = ../ntpq/libntpq.a ../libntp/libntp.a \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(ntpsnmpd_SOURCES) +DIST_SOURCES = $(ntpsnmpd_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 +NROFF = nroff +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/bincheck.mf \ + $(top_srcdir)/check-libopts.mf $(top_srcdir)/depsver.mf \ + $(top_srcdir)/includes.mf $(top_srcdir)/sntp/check-libntp.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +bin_PROGRAMS = $(NTPSNMPD_DB) +libexec_PROGRAMS = $(NTPSNMPD_DL) +sbin_PROGRAMS = $(NTPSNMPD_DS) +ntpsnmpd_SOURCES = netsnmp_daemonize.c ntpsnmpd.c ntpSnmpSubagentObject.c \ + ntpsnmpd-opts.c ntpsnmpd-opts.h ntpSnmpSubagentObject.h \ + ntp_snmp.h + +# HMS: we probably want a version.o file here, too. +LDADD = ../ntpq/libntpq.a ../libntp/libntp.a $(SNMP_LIBS) \ + $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) $(LDADD_NTP) \ + $(LIBOPTS_LDADD) +AM_CFLAGS = $(SNMP_CFLAGS) $(CFLAGS_NTP) +AM_CPPFLAGS = -I$(top_srcdir)/ntpq $(NTP_INCS) $(LIBOPTS_CFLAGS) \ + $(SNMP_CPPFLAGS) $(CPPFLAGS_NTP) +AM_LDFLAGS = $(LDFLAGS_NTP) +EXTRA_DIST = \ + invoke-ntpsnmpd.menu \ + invoke-ntpsnmpd.texi \ + ntpsnmpd-opts.def \ + ntpsnmpd.1ntpsnmpdman \ + ntpsnmpd.1ntpsnmpdmdoc \ + ntpsnmpd.man.in \ + ntpsnmpd.mdoc.in \ + ntpsnmpd.html \ + ntpsnmpd.texi \ + ntpv4-mib.mib \ + $(NULL) + +BUILT_SOURCES = ntpsnmpd-opts.c ntpsnmpd-opts.h check-libntp \ + check-libopts .deps-ver +CLEANFILES = check-libntp check-libopts .deps-ver +DISTCLEANFILES = config.log $(man_MANS) +html_DATA = \ + $(srcdir)/ntpsnmpd.html \ + $(NULL) + +noinst_DATA = \ + $(srcdir)/invoke-ntpsnmpd.menu \ + $(srcdir)/invoke-ntpsnmpd.texi \ + $(srcdir)/ntpsnmpd.man.in \ + $(srcdir)/ntpsnmpd.mdoc.in \ + $(NULL) + +man1_MANS = +man8_MANS = +man_MANS = ntpsnmpd.$(NTPSNMPD_MS) +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am + +.SUFFIXES: +.SUFFIXES: .c .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ntpsnmpd/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign ntpsnmpd/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; +$(top_srcdir)/bincheck.mf $(top_srcdir)/sntp/check-libntp.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +install-binPROGRAMS: $(bin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(bindir)" && rm -f $$files + +clean-binPROGRAMS: + @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-libexecPROGRAMS: $(libexec_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(libexecdir)" && rm -f $$files + +clean-libexecPROGRAMS: + @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +ntpsnmpd$(EXEEXT): $(ntpsnmpd_OBJECTS) $(ntpsnmpd_DEPENDENCIES) $(EXTRA_ntpsnmpd_DEPENDENCIES) + @rm -f ntpsnmpd$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(ntpsnmpd_OBJECTS) $(ntpsnmpd_LDADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netsnmp_daemonize.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpSnmpSubagentObject.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpsnmpd-opts.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ntpsnmpd.Po@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< + +.c.obj: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-man1: $(man1_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am +all-am: Makefile $(PROGRAMS) $(MANS) $(DATA) +installdirs: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) +clean: clean-am + +clean-am: clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-data-local install-htmlDATA install-man + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-binPROGRAMS install-libexecPROGRAMS \ + install-sbinPROGRAMS + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-exec-hook +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: install-man1 install-man8 + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-binPROGRAMS uninstall-htmlDATA \ + uninstall-libexecPROGRAMS uninstall-man uninstall-sbinPROGRAMS + +uninstall-man: uninstall-man1 uninstall-man8 + +.MAKE: all check install install-am install-exec-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ + clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-sbinPROGRAMS cscopelist-am ctags ctags-am \ + distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-binPROGRAMS \ + install-data install-data-am install-data-local install-dvi \ + install-dvi-am install-exec install-exec-am install-exec-hook \ + install-html install-html-am install-htmlDATA install-info \ + install-info-am install-libexecPROGRAMS install-man \ + install-man1 install-man8 install-pdf install-pdf-am \ + install-ps install-ps-am install-sbinPROGRAMS install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-htmlDATA uninstall-libexecPROGRAMS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinPROGRAMS + +.PRECIOUS: Makefile + + +install-data-local: install-html + +$(srcdir)/ntpsnmpd-opts.h: $(srcdir)/ntpsnmpd-opts.c + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/ntpsnmpd-opts.c: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) ntpsnmpd-opts.def + +### + +$(srcdir)/ntpsnmpd.1ntpsnmpdman: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpsnmpdman -Tagman-cmd.tpl ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd.man.in: $(srcdir)/ntpsnmpd.1ntpsnmpdman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpsnmpd.1ntpsnmpdman > $(srcdir)/ntpsnmpd.man.in+ + mv $(srcdir)/ntpsnmpd.man.in+ $(srcdir)/ntpsnmpd.man.in + +### + +$(srcdir)/ntpsnmpd.1ntpsnmpdmdoc: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpsnmpdmdoc -Tagmdoc-cmd.tpl ntpsnmpd-opts.def + +$(srcdir)/ntpsnmpd.mdoc.in: $(srcdir)/ntpsnmpd.1ntpsnmpdmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpsnmpd.1ntpsnmpdmdoc > $(srcdir)/ntpsnmpd.mdoc.in+ + mv $(srcdir)/ntpsnmpd.mdoc.in+ $(srcdir)/ntpsnmpd.mdoc.in + +### + +ntpsnmpd.$(NTPSNMPD_MS): $(srcdir)/ntpsnmpd.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpsnmpd.$(NTPSNMPD_MS)+:$(srcdir)/ntpsnmpd.$(MANTAGFMT).in + mv ntpsnmpd.$(NTPSNMPD_MS)+ ntpsnmpd.$(NTPSNMPD_MS) + +### + +$(srcdir)/invoke-ntpsnmpd.menu: $(srcdir)/invoke-ntpsnmpd.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpsnmpd.texi: $(srcdir)/ntpsnmpd-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpsnmpd-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +$(srcdir)/ntpsnmpd.html: $(srcdir)/ntpsnmpd.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o ntpsnmpd.html ntpsnmpd.texi || true ) + +install-exec-hook: + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ + done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ + done + +# + +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a + +check-libopts: ../sntp/libopts/libopts.la + @echo stamp > $@ + +../sntp/libopts/libopts.la: + -cd ../sntp/libopts && $(MAKE) $(AM_MAKEFLAGS) libopts.la +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/ntpsnmpd/README b/contrib/ntp/ntpsnmpd/README new file mode 100644 index 000000000..5227f40d3 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/README @@ -0,0 +1,40 @@ +NTP SNMP subagent for Net-SNMP + +Installation Guides: + +- install net-snmp from source (configure, make;, make install) +- edit the snmpd configuration file (/usr/local/share/snmp/snmpd.conf): + add the lines + master agentx + agentXSocket tcp:localhost:705 + and check which read-only community is configured (should be "rocommunity public") +- start snmpd (sudo /usr/local/sbin/snmpd) and check that it is running correctly by running the command + snmpwalk -v2c -c public localhost + (which should output a lot of data values for the supported built-in MIBs of net-snmp) +- build the libntpq and the libntp library +- build the ntpsnmpd application (make) and run it (./ntpsnmpd) +- now you can run + snmpwalk -v2c -c public localhost enterprises.5597.99 + which should give you a list of all currently supported NTP MIB objects and their current values + +Please note that currently I use a private MIB OID (enterprises.5597 is the Meinberg top level OEM OID and 99 is my temporary working space for this project). +The final OID has to be registered with IANA and this is done by the RFC Editor when the NTPv4 MIB RFC is standardized. +I will try to do this earlier in order to be able to have a working solution at the end of this project. + +In its current state the daemon supports these objects: + +ntpEntSoftwareName +ntpEntSoftwareVersion +ntpEntSoftwareVersionVal +ntpEntSoftwareVendor +ntpEntSystemType +ntpEntTimeResolution +ntpEntTimeResolutionVal +ntpEntTimePrecision +ntpEntTimePrecisionVal +ntpEntTimeDistance + +They all use the libntpq library to access information from the ntpd instance with mode 6 packets. + +Next step is to implement the status section of the MIB (section 2). + diff --git a/contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.menu b/contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.menu new file mode 100644 index 000000000..886e80a73 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.menu @@ -0,0 +1 @@ +* ntpsnmpd Invocation:: Invoking ntpsnmpd diff --git a/contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.texi b/contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.texi new file mode 100644 index 000000000..ac8e69c19 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/invoke-ntpsnmpd.texi @@ -0,0 +1,188 @@ +@node ntpsnmpd Invocation +@section Invoking ntpsnmpd +@pindex ntpsnmpd +@cindex NTP SNMP MIB agent +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntpsnmpd.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:39:43 PM by AutoGen 5.18.5 +# From the definitions ntpsnmpd-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + + +@code{ntpsnmpd} +is an SNMP MIB agent designed to interface with +@code{ntpd(1ntpdmdoc)}. + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntpsnmpd} program. +This software is released under the NTP license, . + +@menu +* ntpsnmpd usage:: ntpsnmpd help/usage (@option{--help}) +* ntpsnmpd agentxsocket:: agentxsocket option +* ntpsnmpd config:: presetting/configuring ntpsnmpd +* ntpsnmpd exit status:: exit status +* ntpsnmpd Usage:: Usage +* ntpsnmpd Notes:: Notes +* ntpsnmpd Authors:: Authors +@end menu + +@node ntpsnmpd usage +@subsection ntpsnmpd help/usage (@option{--help}) +@cindex ntpsnmpd help + +This is the automatically generated usage text for ntpsnmpd. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +ntpsnmpd - NTP SNMP MIB agent - Ver. 4.2.8p4 +Usage: ntpsnmpd [ - [] | --[@{=| @}] ]... + Flg Arg Option-Name Description + -n no nofork Do not fork + -p no syslog Log to syslog() + Str agentxsocket The socket address ntpsnmpd uses to connect to net-snmpd + opt version output version information and exit + -? no help display extended usage information and exit + -! no more-help extended usage information passed thru pager + -> opt save-opts save the option state to a config file + -< Str load-opts load options from a config file + - disabled as '--no-load-opts' + - may appear multiple times + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. + + +The following option preset mechanisms are supported: + - reading file $HOME/.ntprc + - reading file ./.ntprc + - examining environment variables named NTPSNMPD_* + +Please send bug reports to: +@end example +@exampleindent 4 + +@node ntpsnmpd agentxsocket +@subsection agentxsocket option +@cindex ntpsnmpd-agentxsocket + +This is the ``the socket address ntpsnmpd uses to connect to net-snmpd'' option. +This option takes a string argument. +[:] +The default "agent X socket" is the Unix Domain socket +@file{unix:/var/agentx/master}. +Another common alternative is @file{tcp:localhost:705}. + + +@node ntpsnmpd config +@subsection presetting/configuring ntpsnmpd + +Any option that is not marked as @i{not presettable} may be preset by +loading values from configuration ("rc" or "ini") files, and values from environment variables named @code{NTPSNMPD} and @code{NTPSNMPD_}. @code{} must be one of +the options listed above in upper case and segmented with underscores. +The @code{NTPSNMPD} variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + + +@noindent +@code{libopts} will search in 2 places for configuration files: +@itemize @bullet +@item +$HOME +@item +$PWD +@end itemize +The environment variables @code{HOME}, and @code{PWD} +are expanded and replaced when @file{ntpsnmpd} runs. +For any of these that are plain files, they are simply processed. +For any that are directories, then a file named @file{.ntprc} is searched for +within that directory and processed. + +Configuration files may be in a wide variety of formats. +The basic format is an option name followed by a value (argument) on the +same line. Values may be separated from the option name with a colon, +equal sign or simply white space. Values may be continued across multiple +lines by escaping the newline with a backslash. + +Multiple programs may also share the same initialization file. +Common options are collected at the top, followed by program specific +segments. The segments are separated by lines like: +@example +[NTPSNMPD] +@end example +@noindent +or by +@example + +@end example +@noindent +Do not mix these styles within one configuration file. + +Compound values and carefully constructed string values may also be +specified using XML syntax: +@example + + ...<...>... + +@end example +@noindent +yielding an @code{option-name.sub-opt} string value of +@example +"...<...>..." +@end example +@code{AutoOpts} does not track suboptions. You simply note that it is a +hierarchicly valued option. @code{AutoOpts} does provide a means for searching +the associated name/value pair list (see: optionFindValue). + +The command line options relating to configuration and/or usage help are: + +@subsubheading version (-) + +Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +@table @samp +@item version +Only print the version. This is the default. +@item copyright +Name the copyright usage licensing terms. +@item verbose +Print the full copyright usage licensing terms. +@end table + +@node ntpsnmpd exit status +@subsection ntpsnmpd exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@item 66 (EX_NOINPUT) +A specified configuration file could not be loaded. +@item 70 (EX_SOFTWARE) +libopts had an internal operational error. Please report +it to autogen-users@@lists.sourceforge.net. Thank you. +@end table +@node ntpsnmpd Usage +@subsection ntpsnmpd Usage +@node ntpsnmpd Notes +@subsection ntpsnmpd Notes +@node ntpsnmpd Authors +@subsection ntpsnmpd Authors diff --git a/contrib/ntp/ntpsnmpd/netsnmp_daemonize.c b/contrib/ntp/ntpsnmpd/netsnmp_daemonize.c new file mode 100644 index 000000000..4311bac09 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/netsnmp_daemonize.c @@ -0,0 +1,271 @@ +/* + * system.c + */ +/* Portions of this file are subject to the following copyright(s). See + * the Net-SNMP's COPYING file for more details and other copyrights + * that may apply: + */ +/*********************************************************** + Copyright 1992 by Carnegie Mellon University + + All Rights Reserved + +Permission to use, copy, modify, and distribute this software and its +documentation for any purpose and without fee is hereby granted, +provided that the above copyright notice appear in all copies and that +both that copyright notice and this permission notice appear in +supporting documentation, and that the name of CMU not be +used in advertising or publicity pertaining to distribution of the +software without specific, written prior permission. + +CMU DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING +ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL +CMU BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR +ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS +SOFTWARE. +******************************************************************/ +/* + * Portions of this file are copyrighted by: + * Copyright © 2003 Sun Microsystems, Inc. All rights reserved. + * Use is subject to license terms specified in the COPYING file + * distributed with the Net-SNMP package. + */ +/* + * System dependent routines go here + */ +#include +#undef PACKAGE_BUGREPORT +#undef PACKAGE_NAME +#undef PACKAGE_STRING +#undef PACKAGE_TARNAME +#undef PACKAGE_URL +#undef PACKAGE_VERSION +#include + +#ifdef NEED_NETSNMP_DAEMONIZE + +#include +#include +#include + +#if HAVE_UNISTD_H +#include +#endif +#if HAVE_STDLIB_H +#include +#endif + +#if TIME_WITH_SYS_TIME +# ifdef WIN32 +# include +# else +# include +# endif +# include +#else +# if HAVE_SYS_TIME_H +# include +# else +# include +# endif +#endif + +#include + +#if HAVE_NETINET_IN_H +#include +#endif + +#if HAVE_WINSOCK_H +#include +#endif +#if HAVE_SYS_SOCKET_H +#include +#endif +#if HAVE_NET_IF_H +#include +#endif + +#if HAVE_SYS_SOCKIO_H +#include +#endif + +#if HAVE_SYS_IOCTL_H +#include +#endif + +#ifdef HAVE_NLIST_H +#include +#endif + +#if HAVE_SYS_FILE_H +#include +#endif + +#if HAVE_KSTAT_H +#include +#endif + +#if HAVE_SYS_PARAM_H +#include +#endif +#if HAVE_SYS_SYSCTL_H +#include +#endif + +#if HAVE_STRING_H +#include +#else +#include +#endif + +#if HAVE_DMALLOC_H +#include +#endif + +#ifdef HAVE_SYS_STAT_H +#include +#endif +#if HAVE_FCNTL_H +#include +#endif + +#if defined(hpux10) || defined(hpux11) +#include +#endif + +#if HAVE_SYS_UTSNAME_H +#include +#endif + +#if HAVE_SYS_SYSTEMCFG_H +#include +#endif + +#if HAVE_SYS_SYSTEMINFO_H +#include +#endif + +#include +#include +#include +#include /* for "internal" definitions */ + +#include +#include /* for get_temp_file_pattern() */ + +#ifndef IFF_LOOPBACK +# define IFF_LOOPBACK 0 +#endif + +#ifdef INADDR_LOOPBACK +# define LOOPBACK INADDR_LOOPBACK +#else +# define LOOPBACK 0x7f000001 +#endif + +/** + * fork current process into the background. + * + * This function forks a process into the background, in order to + * become a daemon process. It does a few things along the way: + * + * - becoming a process/session group leader, and forking a second time so + * that process/session group leader can exit. + * + * - changing the working directory to / + * + * - closing stdin, stdout and stderr (unless stderr_log is set) and + * redirecting them to /dev/null + * + * @param quit_immediately : indicates if the parent process should + * exit after a successful fork. + * @param stderr_log : indicates if stderr is being used for + * logging and shouldn't be closed + * @returns -1 : fork error + * 0 : child process returning + * >0 : parent process returning. returned value is the child PID. + */ +int +netsnmp_daemonize(int quit_immediately, int stderr_log) +{ + int i = 0; + int saved_errno; + + DEBUGMSGT(("daemonize","deamonizing...\n")); +#ifdef HAVE_WORKING_FORK + /* + * Fork to return control to the invoking process and to + * guarantee that we aren't a process group leader. + */ + i = fork(); + if (i != 0) { + /* Parent. */ + saved_errno = errno; + DEBUGMSGT(("daemonize","first fork returned %d.\n", i)); + if(i == -1) { + snmp_log(LOG_ERR,"first fork failed (errno %d) in " + "netsnmp_daemonize()\n", saved_errno); + return -1; + } + if (quit_immediately) { + DEBUGMSGT(("daemonize","parent exiting\n")); + exit(0); + } + } else { + /* Child. */ +#ifdef HAVE_SETSID + /* Become a process/session group leader. */ + setsid(); +#endif + /* + * Fork to let the process/session group leader exit. + */ + if ((i = fork()) != 0) { + saved_errno = errno; + DEBUGMSGT(("daemonize","second fork returned %d.\n", i)); + if(i == -1) { + snmp_log(LOG_ERR,"second fork failed (errno %d) in " + "netsnmp_daemonize()\n", saved_errno); + } + /* Parent. */ + exit(0); + } +#ifndef WIN32 + else { + /* Child. */ + + DEBUGMSGT(("daemonize","child continuing\n")); + + /* Avoid keeping any directory in use. */ + chdir("/"); + + if (!stderr_log) { + /* + * Close inherited file descriptors to avoid + * keeping unnecessary references. + */ + close(0); + close(1); + close(2); + + /* + * Redirect std{in,out,err} to /dev/null, just in + * case. + */ + open("/dev/null", O_RDWR); + dup(0); + dup(0); + } + } +#endif /* !WIN32 */ + } +#endif /* HAVE_WORKING_FORK */ + return i; +} + +#else /* !NEED_NETSNMP_DAEMONIZE */ +int netsnp_daemonize_bs; +#endif diff --git a/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c b/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c new file mode 100644 index 000000000..f65fedf60 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.c @@ -0,0 +1,549 @@ +/***************************************************************************** + * + * ntpSnmpSubAgentObject.c + * + * This file provides the callback functions for net-snmp and registers the + * serviced MIB objects with the master agent. + * + * Each object has its own callback function that is called by the + * master agent process whenever someone queries the corresponding MIB + * object. + * + * At the moment this triggers a full send/receive procedure for each + * queried MIB object, one of the things that are still on my todo list: + * a caching mechanism that reduces the number of requests sent to the + * ntpd process. + * + ****************************************************************************/ +#include +#include +#include +#include + +/* general purpose buffer length definition */ +#define NTPQ_BUFLEN 2048 + +char ntpvalue[NTPQ_BUFLEN]; + + +/***************************************************************************** + * + * ntpsnmpd_parse_string + * + * This function will parse a given NULL terminated string and cut it + * into a fieldname and a value part (using the '=' as the delimiter. + * The fieldname will be converted to uppercase and all whitespace + * characters are removed from it. + * The value part is stripped, e.g. all whitespace characters are removed + * from the beginning and end of the string. + * If the value is started and ended with quotes ("), they will be removed + * and everything between the quotes is left untouched (including + * whitespace) + * Example: + * server host name = hello world! + * will result in a field string "SERVERHOSTNAME" and a value + * of "hello world!". + * My first Parameter = " is this! " + * results in a field string "MYFIRSTPARAMETER" and a value " is this! " + **************************************************************************** + * Parameters: + * string const char * The source string to parse. + * NOTE: must be NULL terminated! + * field char * The buffer for the field name. + * fieldsize size_t The size of the field buffer. + * value char * The buffer for the value. + * valuesize size_t The size of the value buffer. + * + * Returns: + * size_t length of value string + ****************************************************************************/ + +size_t +ntpsnmpd_parse_string( + const char * string, + char * field, + size_t fieldsize, + char * value, + size_t valuesize + ) +{ + int i; + int j; + int loop; + size_t str_cnt; + size_t val_cnt; + + /* we need at least one byte to work with to simplify */ + if (fieldsize < 1 || valuesize < 1) + return 0; + + str_cnt = strlen(string); + + /* Parsing the field name */ + j = 0; + loop = TRUE; + for (i = 0; loop && i <= str_cnt; i++) { + switch (string[i]) { + + case '\t': /* Tab */ + case '\n': /* LF */ + case '\r': /* CR */ + case ' ': /* Space */ + break; + + case '=': + loop = FALSE; + break; + + default: + if (j < fieldsize) + field[j++] = toupper(string[i]); + } + } + + j = min(j, fieldsize - 1); + field[j] = '\0'; + + /* Now parsing the value */ + value[0] = '\0'; + j = 0; + for (val_cnt = 0; i < str_cnt; i++) { + if (string[i] > 0x0D && string[i] != ' ') + val_cnt = min(j + 1, valuesize - 1); + + if (value[0] != '\0' || + (string[i] > 0x0D && string[i] != ' ')) { + if (j < valuesize) + value[j++] = string[i]; + } + } + value[val_cnt] = '\0'; + + if (value[0] == '"') { + val_cnt--; + strlcpy(value, &value[1], valuesize); + if (val_cnt > 0 && value[val_cnt - 1] == '"') { + val_cnt--; + value[val_cnt] = '\0'; + } + } + + return val_cnt; +} + + +/***************************************************************************** + * + * ntpsnmpd_cut_string + * + * This function will parse a given NULL terminated string and cut it + * into fields using the specified delimiter character. + * It will then copy the requested field into a destination buffer + * Example: + * ntpsnmpd_cut_string(read:my:lips:fool, RESULT, ':', 2, sizeof(RESULT)) + * will copy "lips" to RESULT. + **************************************************************************** + * Parameters: + * src const char * The name of the source string variable + * NOTE: must be NULL terminated! + * dest char * The name of the string which takes the + * requested field content + * delim char The delimiter character + * fieldnumber int The number of the required field + * (start counting with 0) + * maxsize size_t The maximum size of dest + * + * Returns: + * size_t length of resulting dest string + ****************************************************************************/ + +size_t +ntpsnmpd_cut_string( + const char * string, + char * dest, + char delim, + int fieldnumber, + size_t maxsize + ) +{ + size_t i; + size_t j; + int l; + size_t str_cnt; + + if (maxsize < 1) + return 0; + + str_cnt = strlen(string); + j = 0; + memset(dest, 0, maxsize); + + /* Parsing the field name */ + for (i = 0, l = 0; i < str_cnt && l <= fieldnumber; i++) { + if (string[i] == delim) + l++; /* next field */ + else if (l == fieldnumber && j < maxsize) + dest[j++] = string[i]; + } + j = min(j, maxsize - 1); + dest[j] = '\0'; + + return j; +} + + +/***************************************************************************** + * + * read_ntp_value + * + * This function retrieves the value for a given variable, currently + * this only supports sysvars. It starts a full mode 6 send/receive/parse + * iteration and needs to be optimized, e.g. by using a caching mechanism + * + **************************************************************************** + * Parameters: + * variable char* The name of the required variable + * rbuffer char* The buffer where the value goes + * maxlength int Max. number of bytes for resultbuf + * + * Returns: + * u_int number of chars that have been copied to + * rbuffer + ****************************************************************************/ + +size_t +read_ntp_value( + const char * variable, + char * value, + size_t valuesize + ) +{ + size_t sv_len; + char sv_data[NTPQ_BUFLEN]; + + memset(sv_data, 0, sizeof(sv_data)); + sv_len = ntpq_read_sysvars(sv_data, sizeof(sv_data)); + + if (0 == sv_len) + return 0; + else + return ntpq_getvar(sv_data, sv_len, variable, value, + valuesize); +} + + +/***************************************************************************** + * + * The get_xxx functions + * + * The following function calls are callback functions that will be + * used by the master agent process to retrieve a value for a requested + * MIB object. + * + ****************************************************************************/ + + +int get_ntpEntSoftwareName (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + char ntp_softwarename[NTPQ_BUFLEN]; + + memset (ntp_softwarename, 0, NTPQ_BUFLEN); + + switch (reqinfo->mode) { + case MODE_GET: + { + if ( read_ntp_value("product", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } + else if ( read_ntp_value("version", ntpvalue, NTPQ_BUFLEN) ) + { + ntpsnmpd_cut_string(ntpvalue, ntp_softwarename, ' ', 0, sizeof(ntp_softwarename)-1); + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntp_softwarename, + strlen(ntp_softwarename) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntSoftwareVersion (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("version", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntSoftwareVendor (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("vendor", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + } + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntSystemType (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("systemtype", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } + + if ( read_ntp_value("system", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +/* + * ntpEntTimeResolution + * "The time resolution in integer format, where the resolution + * is represented as divisions of a second, e.g., a value of 1000 + * translates to 1.0 ms." + * + * ntpEntTimeResolution is a challenge for ntpd, as the resolution is + * not known nor exposed by ntpd, only the measured precision (time to + * read the clock). + * + * Logically the resolution must be at least the precision, so report + * it as our best approximation of resolution until/unless ntpd provides + * better. + */ +int +get_ntpEntTimeResolution( + netsnmp_mib_handler * handler, + netsnmp_handler_registration * reginfo, + netsnmp_agent_request_info * reqinfo, + netsnmp_request_info * requests + ) +{ + int precision; + u_int32 resolution; + + switch (reqinfo->mode) { + + case MODE_GET: + if (!read_ntp_value("precision", ntpvalue, + sizeof(ntpvalue))) + return SNMP_ERR_GENERR; + if (1 != sscanf(ntpvalue, "%d", &precision)) + return SNMP_ERR_GENERR; + if (precision >= 0) + return SNMP_ERR_GENERR; + precision = max(precision, -31); + resolution = 1 << -precision; + snmp_set_var_typed_value( + requests->requestvb, + ASN_UNSIGNED, + (void *)&resolution, + sizeof(resolution)); + break; + + default: + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +/* + * ntpEntTimePrecision + * "The entity's precision in integer format, shows the precision. + * A value of -5 would mean 2^-5 = 31.25 ms." + */ +int +get_ntpEntTimePrecision( + netsnmp_mib_handler * handler, + netsnmp_handler_registration * reginfo, + netsnmp_agent_request_info * reqinfo, + netsnmp_request_info * requests + ) +{ + int precision; + int32 precision32; + + switch (reqinfo->mode) { + + case MODE_GET: + if (!read_ntp_value("precision", ntpvalue, + sizeof(ntpvalue))) + return SNMP_ERR_GENERR; + if (1 != sscanf(ntpvalue, "%d", &precision)) + return SNMP_ERR_GENERR; + precision32 = (int32)precision; + snmp_set_var_typed_value( + requests->requestvb, + ASN_INTEGER, + (void *)&precision32, + sizeof(precision32)); + break; + + default: + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +int get_ntpEntTimeDistance (netsnmp_mib_handler *handler, + netsnmp_handler_registration *reginfo, + netsnmp_agent_request_info *reqinfo, + netsnmp_request_info *requests) +{ + switch (reqinfo->mode) { + case MODE_GET: + { + + if ( read_ntp_value("rootdelay", ntpvalue, NTPQ_BUFLEN) ) + { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)ntpvalue, + strlen(ntpvalue) + ); + } else { + snmp_set_var_typed_value(requests->requestvb, ASN_OCTET_STR, + (u_char *)"N/A", + 3 + ); + } + break; + + } + + + default: + /* If we cannot get the information we need, we will return a generic error to the SNMP client */ + return SNMP_ERR_GENERR; + } + + return SNMP_ERR_NOERROR; +} + + +/* + * + * Initialize sub agent + */ + +void +init_ntpSnmpSubagentObject(void) +{ + /* Register all MIB objects with the agentx master */ + NTP_OID_RO( ntpEntSoftwareName, 1, 1, 1, 0); + NTP_OID_RO( ntpEntSoftwareVersion, 1, 1, 2, 0); + NTP_OID_RO( ntpEntSoftwareVendor, 1, 1, 3, 0); + NTP_OID_RO( ntpEntSystemType, 1, 1, 4, 0); + NTP_OID_RO( ntpEntTimeResolution, 1, 1, 5, 0); + NTP_OID_RO( ntpEntTimePrecision, 1, 1, 6, 0); + NTP_OID_RO( ntpEntTimeDistance, 1, 1, 7, 0); +} + diff --git a/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h b/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h new file mode 100644 index 000000000..41d5ac976 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpSnmpSubagentObject.h @@ -0,0 +1,81 @@ +/***************************************************************************** + * + * ntpSnmpSubAgentObject.h + * + * Definitions and macros for ntpSnmpSubAgentObject.c + * + ****************************************************************************/ + + +#ifndef NTPSNMPSUBAGENTOBJECT_H +#define NTPSNMPSUBAGENTOBJECT_H + +/* Function Prototypes */ +size_t ntpsnmpd_parse_string(const char *string, char *field, size_t + fieldsize, char *value, size_t valuesize); +size_t ntpsnmpd_cut_string(const char *string, char *dest, char delim, + int fieldnumber, size_t maxsize); +size_t read_ntp_value(const char *variable, char *value, + size_t valuesize); + +/* Initialization */ +void init_ntpSnmpSubagentObject(void); + +/* MIB Section 1 Callback Functions*/ +Netsnmp_Node_Handler get_ntpEntSoftwareName; +Netsnmp_Node_Handler get_ntpEntSoftwareVersion; +Netsnmp_Node_Handler get_ntpEntSoftwareVendor; +Netsnmp_Node_Handler get_ntpEntSystemType; +Netsnmp_Node_Handler get_ntpEntTimeResolution; +Netsnmp_Node_Handler get_ntpEntTimePrecision; +Netsnmp_Node_Handler get_ntpEntTimeDistance; + +/* MIB Section 2 Callback Functions (TODO) */ +Netsnmp_Node_Handler get_ntpEntStatusCurrentMode; +Netsnmp_Node_Handler get_ntpEntStatusCurrentModeVal; +Netsnmp_Node_Handler get_ntpEntStatusStratum; +Netsnmp_Node_Handler get_ntpEntStatusActiveRefSourceId; +Netsnmp_Node_Handler get_ntpEntStatusActiveRefSourceName; +Netsnmp_Node_Handler get_ntpEntStatusActiveOffset; + +#define NTPV4_OID 1,3,6,1,2,1,197 /* mib-2 197 */ + + +/* + * The following macros simplify the registration of the callback + * functions and register the name and OID of either read-only (RO) or + * read-write (RW) functions. + */ + +#define SETUP_OID_RO(oidname, ...) \ +static oid oidname##_oid [] = { __VA_ARGS__ }; \ +{ \ + netsnmp_register_read_only_instance( \ + netsnmp_create_handler_registration( \ + "#oidname", \ + get_##oidname, \ + oidname##_oid, \ + OID_LENGTH \ + ( oidname##_oid ), \ + HANDLER_CAN_RONLY)); \ +} + +#define SETUP_OID_RW(oidname, ...) \ +static oid oidname##_oid [] = { __VA_ARGS__ }; \ +{ \ + netsnmp_register_instance( \ + netsnmp_create_handler_registration( \ + "#oidname", \ + do_##oidname, \ + oidname##_oid, \ + OID_LENGTH \ + ( oidname##_oid ), \ + HANDLER_CAN_RWRITE)); \ +} + +#define NTP_OID_RO(oidname, w, x, y, z) \ + SETUP_OID_RO(oidname, NTPV4_OID, w, x, y, z) +#define NTP_OID_RW(oidname, w, x, y, z) \ + SETUP_OID_RW(oidname, NTPV4_OID, w, x, y, z) + +#endif diff --git a/contrib/ntp/ntpsnmpd/ntp_snmp.h b/contrib/ntp/ntpsnmpd/ntp_snmp.h new file mode 100644 index 000000000..b6057582c --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntp_snmp.h @@ -0,0 +1,37 @@ +/* + * ntp_snmp.h -- common net-snmp header includes and workaround + * for Autoconf-related PACKAGE_* redefinitions between + * net-snmp and NTP. + * + * Currently ntpsnmpd *.c files are exceptions to the rule that every .c + * file should include before any other headers. It would be + * ideal to rearrange its includes so that our config.h is first, but + * that is complicated by the redefinitions between our config.h and + * net-snmp/net-snmp-config.h. + */ + +#include +#include +#include + +#ifdef PACKAGE_BUGREPORT +# undef PACKAGE_BUGREPORT +#endif +#ifdef PACKAGE_NAME +# undef PACKAGE_NAME +#endif +#ifdef PACKAGE_STRING +# undef PACKAGE_STRING +#endif +#ifdef PACKAGE_TARNAME +# undef PACKAGE_TARNAME +#endif +#ifdef PACKAGE_URL +# undef PACKAGE_URL +#endif +#ifdef PACKAGE_VERSION +# undef PACKAGE_VERSION +#endif + +#include +#include diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c b/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c new file mode 100644 index 000000000..01013fb8f --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.c @@ -0,0 +1,912 @@ +/* + * EDIT THIS FILE WITH CAUTION (ntpsnmpd-opts.c) + * + * It has been AutoGen-ed October 21, 2015 at 12:39:32 PM by AutoGen 5.18.5 + * From the definitions ntpsnmpd-opts.def + * and the template file options + * + * Generated from AutoOpts 41:0:16 templates. + * + * AutoOpts is a copyrighted work. This source file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpsnmpd author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. + * + * The ntpsnmpd program is copyrighted and licensed + * under the following terms: + * + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * + * + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. + */ + +#ifndef __doxygen__ +#define OPTION_CODE_COMPILE 1 +#include "ntpsnmpd-opts.h" +#include + +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif +extern FILE * option_usage_fp; +#define zCopyright (ntpsnmpd_opt_strs+0) +#define zLicenseDescrip (ntpsnmpd_opt_strs+344) + + +#ifndef NULL +# define NULL 0 +#endif + +/** + * static const strings for ntpsnmpd options + */ +static char const ntpsnmpd_opt_strs[1610] = +/* 0 */ "ntpsnmpd 4.2.8p4\n" + "Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n" + "This is free software. It is licensed for use, modification and\n" + "redistribution under the terms of the NTP License, copies of which\n" + "can be seen at:\n" + " \n" + " \n\0" +/* 344 */ "Permission to use, copy, modify, and distribute this software and its\n" + "documentation for any purpose with or without fee is hereby granted,\n" + "provided that the above copyright notice appears in all copies and that\n" + "both the copyright notice and this permission notice appear in supporting\n" + "documentation, and that the name The University of Delaware not be used in\n" + "advertising or publicity pertaining to distribution of the software without\n" + "specific, written prior permission. The University of Delaware and Network\n" + "Time Foundation makes no representations about the suitability this\n" + "software for any purpose. It is provided \"as is\" without express or\n" + "implied warranty.\n\0" +/* 1012 */ "Do not fork\0" +/* 1024 */ "NOFORK\0" +/* 1031 */ "nofork\0" +/* 1038 */ "Log to syslog()\0" +/* 1054 */ "SYSLOG\0" +/* 1061 */ "syslog\0" +/* 1068 */ "The socket address ntpsnmpd uses to connect to net-snmpd\0" +/* 1125 */ "AGENTXSOCKET\0" +/* 1138 */ "agentxsocket\0" +/* 1151 */ "unix:/var/agentx/master\0" +/* 1175 */ "display extended usage information and exit\0" +/* 1219 */ "help\0" +/* 1224 */ "extended usage information passed thru pager\0" +/* 1269 */ "more-help\0" +/* 1279 */ "output version information and exit\0" +/* 1315 */ "version\0" +/* 1323 */ "save the option state to a config file\0" +/* 1362 */ "save-opts\0" +/* 1372 */ "load options from a config file\0" +/* 1404 */ "LOAD_OPTS\0" +/* 1414 */ "no-load-opts\0" +/* 1427 */ "no\0" +/* 1430 */ "NTPSNMPD\0" +/* 1439 */ "ntpsnmpd - NTP SNMP MIB agent - Ver. 4.2.8p4\n" + "Usage: %s [ - [] | --[{=| }] ]...\n\0" +/* 1542 */ "$HOME\0" +/* 1548 */ ".\0" +/* 1550 */ ".ntprc\0" +/* 1557 */ "http://bugs.ntp.org, bugs@ntp.org\0" +/* 1591 */ "\n\0" +/* 1593 */ "ntpsnmpd 4.2.8p4"; + +/** + * nofork option description: + */ +/** Descriptive text for the nofork option */ +#define NOFORK_DESC (ntpsnmpd_opt_strs+1012) +/** Upper-cased name for the nofork option */ +#define NOFORK_NAME (ntpsnmpd_opt_strs+1024) +/** Name string for the nofork option */ +#define NOFORK_name (ntpsnmpd_opt_strs+1031) +/** Compiled in flag settings for the nofork option */ +#define NOFORK_FLAGS (OPTST_DISABLED) + +/** + * syslog option description: + */ +/** Descriptive text for the syslog option */ +#define SYSLOG_DESC (ntpsnmpd_opt_strs+1038) +/** Upper-cased name for the syslog option */ +#define SYSLOG_NAME (ntpsnmpd_opt_strs+1054) +/** Name string for the syslog option */ +#define SYSLOG_name (ntpsnmpd_opt_strs+1061) +/** Compiled in flag settings for the syslog option */ +#define SYSLOG_FLAGS (OPTST_DISABLED) + +/** + * agentXSocket option description: + */ +/** Descriptive text for the agentXSocket option */ +#define AGENTXSOCKET_DESC (ntpsnmpd_opt_strs+1068) +/** Upper-cased name for the agentXSocket option */ +#define AGENTXSOCKET_NAME (ntpsnmpd_opt_strs+1125) +/** Name string for the agentXSocket option */ +#define AGENTXSOCKET_name (ntpsnmpd_opt_strs+1138) +/** The compiled in default value for the agentXSocket option argument */ +#define AGENTXSOCKET_DFT_ARG (ntpsnmpd_opt_strs+1151) +/** Compiled in flag settings for the agentXSocket option */ +#define AGENTXSOCKET_FLAGS (OPTST_DISABLED \ + | OPTST_SET_ARGTYPE(OPARG_TYPE_STRING)) + +/* + * Help/More_Help/Version option descriptions: + */ +#define HELP_DESC (ntpsnmpd_opt_strs+1175) +#define HELP_name (ntpsnmpd_opt_strs+1219) +#ifdef HAVE_WORKING_FORK +#define MORE_HELP_DESC (ntpsnmpd_opt_strs+1224) +#define MORE_HELP_name (ntpsnmpd_opt_strs+1269) +#define MORE_HELP_FLAGS (OPTST_IMM | OPTST_NO_INIT) +#else +#define MORE_HELP_DESC HELP_DESC +#define MORE_HELP_name HELP_name +#define MORE_HELP_FLAGS (OPTST_OMITTED | OPTST_NO_INIT) +#endif +#ifdef NO_OPTIONAL_OPT_ARGS +# define VER_FLAGS (OPTST_IMM | OPTST_NO_INIT) +#else +# define VER_FLAGS (OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) | \ + OPTST_ARG_OPTIONAL | OPTST_IMM | OPTST_NO_INIT) +#endif +#define VER_DESC (ntpsnmpd_opt_strs+1279) +#define VER_name (ntpsnmpd_opt_strs+1315) +#define SAVE_OPTS_DESC (ntpsnmpd_opt_strs+1323) +#define SAVE_OPTS_name (ntpsnmpd_opt_strs+1362) +#define LOAD_OPTS_DESC (ntpsnmpd_opt_strs+1372) +#define LOAD_OPTS_NAME (ntpsnmpd_opt_strs+1404) +#define NO_LOAD_OPTS_name (ntpsnmpd_opt_strs+1414) +#define LOAD_OPTS_pfx (ntpsnmpd_opt_strs+1427) +#define LOAD_OPTS_name (NO_LOAD_OPTS_name + 3) +/** + * Declare option callback procedures + */ +extern tOptProc + ntpOptionPrintVersion, optionBooleanVal, optionNestedVal, + optionNumericVal, optionPagedUsage, optionResetOpt, + optionStackArg, optionTimeDate, optionTimeVal, + optionUnstackArg, optionVendorOption; +static tOptProc + doUsageOpt; +#define VER_PROC ntpOptionPrintVersion + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Define the ntpsnmpd Option Descriptions. + * This is an array of OPTION_CT entries, one for each + * option that the ntpsnmpd program responds to. + */ +static tOptDesc optDesc[OPTION_CT] = { + { /* entry idx, value */ 0, VALUE_OPT_NOFORK, + /* equiv idx, value */ 0, VALUE_OPT_NOFORK, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ NOFORK_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --nofork */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ NOFORK_DESC, NOFORK_NAME, NOFORK_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 1, VALUE_OPT_SYSLOG, + /* equiv idx, value */ 1, VALUE_OPT_SYSLOG, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ SYSLOG_FLAGS, 0, + /* last opt argumnt */ { NULL }, /* --syslog */ + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ SYSLOG_DESC, SYSLOG_NAME, SYSLOG_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ 2, VALUE_OPT_AGENTXSOCKET, + /* equiv idx, value */ 2, VALUE_OPT_AGENTXSOCKET, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ AGENTXSOCKET_FLAGS, 0, + /* last opt argumnt */ { AGENTXSOCKET_DFT_ARG }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ AGENTXSOCKET_DESC, AGENTXSOCKET_NAME, AGENTXSOCKET_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_VERSION, VALUE_OPT_VERSION, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_VERSION, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ VER_FLAGS, AOUSE_VERSION, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ VER_PROC, + /* desc, NAME, name */ VER_DESC, NULL, VER_name, + /* disablement strs */ NULL, NULL }, + + + + { /* entry idx, value */ INDEX_OPT_HELP, VALUE_OPT_HELP, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_HELP, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ OPTST_IMM | OPTST_NO_INIT, AOUSE_HELP, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ doUsageOpt, + /* desc, NAME, name */ HELP_DESC, NULL, HELP_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_MORE_HELP, VALUE_OPT_MORE_HELP, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_MORE_HELP, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ MORE_HELP_FLAGS, AOUSE_MORE_HELP, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionPagedUsage, + /* desc, NAME, name */ MORE_HELP_DESC, NULL, MORE_HELP_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_SAVE_OPTS, VALUE_OPT_SAVE_OPTS, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_SAVE_OPTS, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, 1, 0, + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) + | OPTST_ARG_OPTIONAL | OPTST_NO_INIT, AOUSE_SAVE_OPTS, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ NULL, + /* desc, NAME, name */ SAVE_OPTS_DESC, NULL, SAVE_OPTS_name, + /* disablement strs */ NULL, NULL }, + + { /* entry idx, value */ INDEX_OPT_LOAD_OPTS, VALUE_OPT_LOAD_OPTS, + /* equiv idx value */ NO_EQUIVALENT, VALUE_OPT_LOAD_OPTS, + /* equivalenced to */ NO_EQUIVALENT, + /* min, max, act ct */ 0, NOLIMIT, 0, + /* opt state flags */ OPTST_SET_ARGTYPE(OPARG_TYPE_STRING) + | OPTST_DISABLE_IMM, AOUSE_LOAD_OPTS, + /* last opt argumnt */ { NULL }, + /* arg list/cookie */ NULL, + /* must/cannot opts */ NULL, NULL, + /* option proc */ optionLoadOpt, + /* desc, NAME, name */ LOAD_OPTS_DESC, LOAD_OPTS_NAME, LOAD_OPTS_name, + /* disablement strs */ NO_LOAD_OPTS_name, LOAD_OPTS_pfx } +}; + + +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** Reference to the upper cased version of ntpsnmpd. */ +#define zPROGNAME (ntpsnmpd_opt_strs+1430) +/** Reference to the title line for ntpsnmpd usage. */ +#define zUsageTitle (ntpsnmpd_opt_strs+1439) +/** ntpsnmpd configuration file name. */ +#define zRcName (ntpsnmpd_opt_strs+1550) +/** Directories to search for ntpsnmpd config files. */ +static char const * const apzHomeList[3] = { + ntpsnmpd_opt_strs+1542, + ntpsnmpd_opt_strs+1548, + NULL }; +/** The ntpsnmpd program bug email address. */ +#define zBugsAddr (ntpsnmpd_opt_strs+1557) +/** Clarification/explanation of what ntpsnmpd does. */ +#define zExplain (ntpsnmpd_opt_strs+1591) +/** Extra detail explaining what ntpsnmpd does. */ +#define zDetail (NULL) +/** The full version string for ntpsnmpd. */ +#define zFullVersion (ntpsnmpd_opt_strs+1593) +/* extracted from optcode.tlib near line 364 */ + +#if defined(ENABLE_NLS) +# define OPTPROC_BASE OPTPROC_TRANSLATE + static tOptionXlateProc translate_option_strings; +#else +# define OPTPROC_BASE OPTPROC_NONE +# define translate_option_strings NULL +#endif /* ENABLE_NLS */ + +#define ntpsnmpd_full_usage (NULL) +#define ntpsnmpd_short_usage (NULL) + +#endif /* not defined __doxygen__ */ + +/* + * Create the static procedure(s) declared above. + */ +/** + * The callout function that invokes the optionUsage function. + * + * @param[in] opts the AutoOpts option description structure + * @param[in] od the descriptor for the "help" (usage) option. + * @noreturn + */ +static void +doUsageOpt(tOptions * opts, tOptDesc * od) +{ + int ex_code; + ex_code = NTPSNMPD_EXIT_SUCCESS; + optionUsage(&ntpsnmpdOptions, ex_code); + /* NOTREACHED */ + exit(1); + (void)opts; + (void)od; +} +/* extracted from optmain.tlib near line 1250 */ + +/** + * The directory containing the data associated with ntpsnmpd. + */ +#ifndef PKGDATADIR +# define PKGDATADIR "" +#endif + +/** + * Information about the person or institution that packaged ntpsnmpd + * for the current distribution. + */ +#ifndef WITH_PACKAGER +# define ntpsnmpd_packager_info NULL +#else +/** Packager information for ntpsnmpd. */ +static char const ntpsnmpd_packager_info[] = + "Packaged by " WITH_PACKAGER + +# ifdef WITH_PACKAGER_VERSION + " ("WITH_PACKAGER_VERSION")" +# endif + +# ifdef WITH_PACKAGER_BUG_REPORTS + "\nReport ntpsnmpd bugs to " WITH_PACKAGER_BUG_REPORTS +# endif + "\n"; +#endif +#ifndef __doxygen__ + +#endif /* __doxygen__ */ +/** + * The option definitions for ntpsnmpd. The one structure that + * binds them all. + */ +tOptions ntpsnmpdOptions = { + OPTIONS_STRUCT_VERSION, + 0, NULL, /* original argc + argv */ + ( OPTPROC_BASE + + OPTPROC_ERRSTOP + + OPTPROC_SHORTOPT + + OPTPROC_LONGOPT + + OPTPROC_NO_REQ_OPT + + OPTPROC_ENVIRON + + OPTPROC_NO_ARGS + + OPTPROC_MISUSE ), + 0, NULL, /* current option index, current option */ + NULL, NULL, zPROGNAME, + zRcName, zCopyright, zLicenseDescrip, + zFullVersion, apzHomeList, zUsageTitle, + zExplain, zDetail, optDesc, + zBugsAddr, /* address to send bugs to */ + NULL, NULL, /* extensions/saved state */ + optionUsage, /* usage procedure */ + translate_option_strings, /* translation procedure */ + /* + * Indexes to special options + */ + { INDEX_OPT_MORE_HELP, /* more-help option index */ + INDEX_OPT_SAVE_OPTS, /* save option index */ + NO_EQUIVALENT, /* '-#' option index */ + NO_EQUIVALENT /* index of default opt */ + }, + 8 /* full option count */, 3 /* user option count */, + ntpsnmpd_full_usage, ntpsnmpd_short_usage, + NULL, NULL, + PKGDATADIR, ntpsnmpd_packager_info +}; + +#if ENABLE_NLS +/** + * This code is designed to translate translatable option text for the + * ntpsnmpd program. These translations happen upon entry + * to optionProcess(). + */ +#include +#include +#include +#include +#ifdef HAVE_DCGETTEXT +# include +#endif +#include + +static char * AO_gettext(char const * pz); +static void coerce_it(void ** s); + +/** + * AutoGen specific wrapper function for gettext. It relies on the macro _() + * to convert from English to the target language, then strdup-duplicates the + * result string. It tries the "libopts" domain first, then whatever has been + * set via the \a textdomain(3) call. + * + * @param[in] pz the input text used as a lookup key. + * @returns the translated text (if there is one), + * or the original text (if not). + */ +static char * +AO_gettext(char const * pz) +{ + char * res; + if (pz == NULL) + return NULL; +#ifdef HAVE_DCGETTEXT + /* + * While processing the option_xlateable_txt data, try to use the + * "libopts" domain. Once we switch to the option descriptor data, + * do *not* use that domain. + */ + if (option_xlateable_txt.field_ct != 0) { + res = dgettext("libopts", pz); + if (res == pz) + res = (char *)VOIDP(_(pz)); + } else + res = (char *)VOIDP(_(pz)); +#else + res = (char *)VOIDP(_(pz)); +#endif + if (res == pz) + return res; + res = strdup(res); + if (res == NULL) { + fputs(_("No memory for duping translated strings\n"), stderr); + exit(NTPSNMPD_EXIT_FAILURE); + } + return res; +} + +/** + * All the pointers we use are marked "* const", but they are stored in + * writable memory. Coerce the mutability and set the pointer. + */ +static void coerce_it(void ** s) { *s = AO_gettext(*s); +} + +/** + * Translate all the translatable strings in the ntpsnmpdOptions + * structure defined above. This is done only once. + */ +static void +translate_option_strings(void) +{ + tOptions * const opts = &ntpsnmpdOptions; + + /* + * Guard against re-translation. It won't work. The strings will have + * been changed by the first pass through this code. One shot only. + */ + if (option_xlateable_txt.field_ct != 0) { + /* + * Do the translations. The first pointer follows the field count + * field. The field count field is the size of a pointer. + */ + char ** ppz = (char**)VOIDP(&(option_xlateable_txt)); + int ix = option_xlateable_txt.field_ct; + + do { + ppz++; /* skip over field_ct */ + *ppz = AO_gettext(*ppz); + } while (--ix > 0); + /* prevent re-translation and disable "libopts" domain lookup */ + option_xlateable_txt.field_ct = 0; + + coerce_it(VOIDP(&(opts->pzCopyright))); + coerce_it(VOIDP(&(opts->pzCopyNotice))); + coerce_it(VOIDP(&(opts->pzFullVersion))); + coerce_it(VOIDP(&(opts->pzUsageTitle))); + coerce_it(VOIDP(&(opts->pzExplain))); + coerce_it(VOIDP(&(opts->pzDetail))); + { + tOptDesc * od = opts->pOptDesc; + for (ix = opts->optCt; ix > 0; ix--, od++) + coerce_it(VOIDP(&(od->pzText))); + } + } +} +#endif /* ENABLE_NLS */ + +#ifdef DO_NOT_COMPILE_THIS_CODE_IT_IS_FOR_GETTEXT +/** I18N function strictly for xgettext. Do not compile. */ +static void bogus_function(void) { + /* TRANSLATORS: + + The following dummy function was crated solely so that xgettext can + extract the correct strings. These strings are actually referenced + by a field name in the ntpsnmpdOptions structure noted in the + comments below. The literal text is defined in ntpsnmpd_opt_strs. + + NOTE: the strings below are segmented with respect to the source string + ntpsnmpd_opt_strs. The strings above are handed off for translation + at run time a paragraph at a time. Consequently, they are presented here + for translation a paragraph at a time. + + ALSO: often the description for an option will reference another option + by name. These are set off with apostrophe quotes (I hope). Do not + translate option names. + */ + /* referenced via ntpsnmpdOptions.pzCopyright */ + puts(_("ntpsnmpd 4.2.8p4\n\ +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved.\n\ +This is free software. It is licensed for use, modification and\n\ +redistribution under the terms of the NTP License, copies of which\n\ +can be seen at:\n")); + puts(_(" \n\ + \n")); + + /* referenced via ntpsnmpdOptions.pzCopyNotice */ + puts(_("Permission to use, copy, modify, and distribute this software and its\n\ +documentation for any purpose with or without fee is hereby granted,\n\ +provided that the above copyright notice appears in all copies and that\n\ +both the copyright notice and this permission notice appear in supporting\n\ +documentation, and that the name The University of Delaware not be used in\n\ +advertising or publicity pertaining to distribution of the software without\n\ +specific, written prior permission. The University of Delaware and Network\n\ +Time Foundation makes no representations about the suitability this\n\ +software for any purpose. It is provided \"as is\" without express or\n\ +implied warranty.\n")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("Do not fork")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("Log to syslog()")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("The socket address ntpsnmpd uses to connect to net-snmpd")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("display extended usage information and exit")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("extended usage information passed thru pager")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("output version information and exit")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("save the option state to a config file")); + + /* referenced via ntpsnmpdOptions.pOptDesc->pzText */ + puts(_("load options from a config file")); + + /* referenced via ntpsnmpdOptions.pzUsageTitle */ + puts(_("ntpsnmpd - NTP SNMP MIB agent - Ver. 4.2.8p4\n\ +Usage: %s [ - [] | --[{=| }] ]...\n")); + + /* referenced via ntpsnmpdOptions.pzExplain */ + puts(_("\n")); + + /* referenced via ntpsnmpdOptions.pzFullVersion */ + puts(_("ntpsnmpd 4.2.8p4")); + + /* referenced via ntpsnmpdOptions.pzFullUsage */ + puts(_("<<>>")); + + /* referenced via ntpsnmpdOptions.pzShortUsage */ + puts(_("<<>>")); + /* LIBOPTS-MESSAGES: */ +#line 67 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 93 "../autoopts.c" + puts(_("allocation of %d bytes failed\n")); +#line 53 "../init.c" + puts(_("AutoOpts function called without option descriptor\n")); +#line 86 "../init.c" + puts(_("\tThis exceeds the compiled library version: ")); +#line 84 "../init.c" + puts(_("Automated Options Processing Error!\n" + "\t%s called AutoOpts function with structure version %d:%d:%d.\n")); +#line 80 "../autoopts.c" + puts(_("realloc of %d bytes at 0x%p failed\n")); +#line 88 "../init.c" + puts(_("\tThis is less than the minimum library version: ")); +#line 121 "../version.c" + puts(_("Automated Options version %s\n" + "\tCopyright (C) 1999-2014 by Bruce Korb - all rights reserved\n")); +#line 87 "../makeshell.c" + puts(_("(AutoOpts bug): %s.\n")); +#line 90 "../reset.c" + puts(_("optionResetOpt() called, but reset-option not configured")); +#line 292 "../usage.c" + puts(_("could not locate the 'help' option")); +#line 336 "../autoopts.c" + puts(_("optionProcess() was called with invalid data")); +#line 748 "../usage.c" + puts(_("invalid argument type specified")); +#line 598 "../find.c" + puts(_("defaulted to option with optional arg")); +#line 76 "../alias.c" + puts(_("aliasing option is out of range.")); +#line 234 "../enum.c" + puts(_("%s error: the keyword '%s' is ambiguous for %s\n")); +#line 108 "../find.c" + puts(_(" The following options match:\n")); +#line 293 "../find.c" + puts(_("%s: ambiguous option name: %s (matches %d options)\n")); +#line 161 "../check.c" + puts(_("%s: Command line arguments required\n")); +#line 43 "../alias.c" + puts(_("%d %s%s options allowed\n")); +#line 94 "../makeshell.c" + puts(_("%s error %d (%s) calling %s for '%s'\n")); +#line 306 "../makeshell.c" + puts(_("interprocess pipe")); +#line 168 "../version.c" + puts(_("error: version option argument '%c' invalid. Use:\n" + "\t'v' - version only\n" + "\t'c' - version and copyright\n" + "\t'n' - version and full copyright notice\n")); +#line 58 "../check.c" + puts(_("%s error: the '%s' and '%s' options conflict\n")); +#line 217 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 430 "../find.c" + puts(_("%s: The '%s' option has been disabled.")); +#line 38 "../alias.c" + puts(_("-equivalence")); +#line 469 "../find.c" + puts(_("%s: illegal option -- %c\n")); +#line 110 "../reset.c" + puts(_("%s: illegal option -- %c\n")); +#line 271 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 755 "../find.c" + puts(_("%s: illegal option -- %s\n")); +#line 118 "../reset.c" + puts(_("%s: illegal option -- %s\n")); +#line 335 "../find.c" + puts(_("%s: unknown vendor extension option -- %s\n")); +#line 159 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 169 "../enum.c" + puts(_(" or an integer from %d through %d\n")); +#line 747 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 1081 "../usage.c" + puts(_("%s error: invalid option descriptor for %s\n")); +#line 385 "../find.c" + puts(_("%s: invalid option name: %s\n")); +#line 527 "../find.c" + puts(_("%s: The '%s' option requires an argument.\n")); +#line 156 "../autoopts.c" + puts(_("(AutoOpts bug): Equivalenced option '%s' was equivalenced to both\n" + "\t'%s' and '%s'.")); +#line 94 "../check.c" + puts(_("%s error: The %s option is required\n")); +#line 632 "../find.c" + puts(_("%s: The '%s' option cannot have an argument.\n")); +#line 151 "../check.c" + puts(_("%s: Command line arguments are not allowed.\n")); +#line 535 "../save.c" + puts(_("error %d (%s) creating %s\n")); +#line 234 "../enum.c" + puts(_("%s error: '%s' does not match any %s keywords.\n")); +#line 93 "../reset.c" + puts(_("%s error: The '%s' option requires an argument.\n")); +#line 184 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 238 "../save.c" + puts(_("error %d (%s) stat-ing %s\n")); +#line 143 "../restore.c" + puts(_("%s error: no saved option state\n")); +#line 231 "../autoopts.c" + puts(_("'%s' is not a command line option.\n")); +#line 111 "../time.c" + puts(_("%s error: '%s' is not a recognizable date/time.\n")); +#line 132 "../save.c" + puts(_("'%s' not defined\n")); +#line 50 "../time.c" + puts(_("%s error: '%s' is not a recognizable time duration.\n")); +#line 92 "../check.c" + puts(_("%s error: The %s option must appear %d times.\n")); +#line 164 "../numeric.c" + puts(_("%s error: '%s' is not a recognizable number.\n")); +#line 200 "../enum.c" + puts(_("%s error: %s exceeds %s keyword count\n")); +#line 330 "../usage.c" + puts(_("Try '%s %s' for more information.\n")); +#line 45 "../alias.c" + puts(_("one %s%s option allowed\n")); +#line 208 "../makeshell.c" + puts(_("standard output")); +#line 943 "../makeshell.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard output")); +#line 415 "../usage.c" + puts(_("standard output")); +#line 625 "../usage.c" + puts(_("standard output")); +#line 175 "../version.c" + puts(_("standard output")); +#line 274 "../usage.c" + puts(_("standard error")); +#line 415 "../usage.c" + puts(_("standard error")); +#line 625 "../usage.c" + puts(_("standard error")); +#line 175 "../version.c" + puts(_("standard error")); +#line 208 "../makeshell.c" + puts(_("write")); +#line 943 "../makeshell.c" + puts(_("write")); +#line 273 "../usage.c" + puts(_("write")); +#line 414 "../usage.c" + puts(_("write")); +#line 624 "../usage.c" + puts(_("write")); +#line 174 "../version.c" + puts(_("write")); +#line 60 "../numeric.c" + puts(_("%s error: %s option value %ld is out of range.\n")); +#line 44 "../check.c" + puts(_("%s error: %s option requires the %s option\n")); +#line 131 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 183 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 237 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 256 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); +#line 534 "../save.c" + puts(_("%s warning: cannot save options - %s not regular file\n")); + /* END-LIBOPTS-MESSAGES */ + + /* USAGE-TEXT: */ +#line 873 "../usage.c" + puts(_("\t\t\t\t- an alternate for '%s'\n")); +#line 1148 "../usage.c" + puts(_("Version, usage and configuration options:")); +#line 924 "../usage.c" + puts(_("\t\t\t\t- default option for unnamed options\n")); +#line 837 "../usage.c" + puts(_("\t\t\t\t- disabled as '--%s'\n")); +#line 1117 "../usage.c" + puts(_(" --- %-14s %s\n")); +#line 1115 "../usage.c" + puts(_("This option has been disabled")); +#line 864 "../usage.c" + puts(_("\t\t\t\t- enabled by default\n")); +#line 40 "../alias.c" + puts(_("%s error: only ")); +#line 1194 "../usage.c" + puts(_(" - examining environment variables named %s_*\n")); +#line 168 "../file.c" + puts(_("\t\t\t\t- file must not pre-exist\n")); +#line 172 "../file.c" + puts(_("\t\t\t\t- file must pre-exist\n")); +#line 380 "../usage.c" + puts(_("Options are specified by doubled hyphens and their name or by a single\n" + "hyphen and the flag character.\n")); +#line 921 "../makeshell.c" + puts(_("\n" + "= = = = = = = =\n\n" + "This incarnation of genshell will produce\n" + "a shell script to parse the options for %s:\n\n")); +#line 166 "../enum.c" + puts(_(" or an integer mask with any of the lower %d bits set\n")); +#line 897 "../usage.c" + puts(_("\t\t\t\t- is a set membership option\n")); +#line 918 "../usage.c" + puts(_("\t\t\t\t- must appear between %d and %d times\n")); +#line 382 "../usage.c" + puts(_("Options are specified by single or double hyphens and their name.\n")); +#line 904 "../usage.c" + puts(_("\t\t\t\t- may appear multiple times\n")); +#line 891 "../usage.c" + puts(_("\t\t\t\t- may not be preset\n")); +#line 1309 "../usage.c" + puts(_(" Arg Option-Name Description\n")); +#line 1245 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1303 "../usage.c" + puts(_(" Flg Arg Option-Name Description\n")); +#line 1304 "../usage.c" + puts(_(" %3s %s")); +#line 1310 "../usage.c" + puts(_(" %3s %s")); +#line 387 "../usage.c" + puts(_("The '-#' option may omit the hash char\n")); +#line 383 "../usage.c" + puts(_("All arguments are named options.\n")); +#line 971 "../usage.c" + puts(_(" - reading file %s")); +#line 409 "../usage.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 100 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 129 "../version.c" + puts(_("\n" + "Please send bug reports to: <%s>\n")); +#line 903 "../usage.c" + puts(_("\t\t\t\t- may NOT appear - preset only\n")); +#line 944 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 1192 "../usage.c" + puts(_("\n" + "The following option preset mechanisms are supported:\n")); +#line 682 "../usage.c" + puts(_("prohibits these options:\n")); +#line 677 "../usage.c" + puts(_("prohibits the option '%s'\n")); +#line 81 "../numeric.c" + puts(_("%s%ld to %ld")); +#line 79 "../numeric.c" + puts(_("%sgreater than or equal to %ld")); +#line 75 "../numeric.c" + puts(_("%s%ld exactly")); +#line 68 "../numeric.c" + puts(_("%sit must lie in one of the ranges:\n")); +#line 68 "../numeric.c" + puts(_("%sit must be in the range:\n")); +#line 88 "../numeric.c" + puts(_(", or\n")); +#line 66 "../numeric.c" + puts(_("%sis scalable with a suffix: k/K/m/M/g/G/t/T\n")); +#line 77 "../numeric.c" + puts(_("%sless than or equal to %ld")); +#line 390 "../usage.c" + puts(_("Operands and options may be intermixed. They will be reordered.\n")); +#line 652 "../usage.c" + puts(_("requires the option '%s'\n")); +#line 655 "../usage.c" + puts(_("requires these options:\n")); +#line 1321 "../usage.c" + puts(_(" Arg Option-Name Req? Description\n")); +#line 1315 "../usage.c" + puts(_(" Flg Arg Option-Name Req? Description\n")); +#line 167 "../enum.c" + puts(_("or you may use a numeric representation. Preceding these with a '!'\n" + "will clear the bits, specifying 'none' will clear all bits, and 'all'\n" + "will set them all. Multiple entries may be passed as an option\n" + "argument list.\n")); +#line 910 "../usage.c" + puts(_("\t\t\t\t- may appear up to %d times\n")); +#line 77 "../enum.c" + puts(_("The valid \"%s\" option keywords are:\n")); +#line 1152 "../usage.c" + puts(_("The next option supports vendor supported extra options:")); +#line 773 "../usage.c" + puts(_("These additional options are:")); + /* END-USAGE-TEXT */ +} +#endif /* uncompilable code */ +#ifdef __cplusplus +} +#endif +/* ntpsnmpd-opts.c ends here */ diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def b/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def new file mode 100644 index 000000000..b3162e58e --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.def @@ -0,0 +1,146 @@ +/* -*- Mode: Text -*- */ + +autogen definitions options; + +#include copyright.def +#include homerc.def +#include autogen-version.def + +prog-name = "ntpsnmpd"; +prog-title = "NTP SNMP MIB agent"; + +flag = { + name = nofork; + value = n; + descrip = "Do not fork"; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = syslog; + value = p; + descrip = "Log to syslog()"; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = agentXSocket; +/* value = x; */ + arg-type = string; + arg-default = "unix:/var/agentx/master"; + descrip = "The socket address ntpsnmpd uses to connect to net-snmpd"; + doc = <<- _EndOfDoc_ + [:] + The default "agent X socket" is the Unix Domain socket + @file{unix:/var/agentx/master}. + Another common alternative is @file{tcp:localhost:705}. + _EndOfDoc_; +}; + +/* explain: Additional information whenever the usage routine is invoked */ +explain = <<- _END_EXPLAIN + _END_EXPLAIN; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP + .Nm + is an SNMP MIB agent designed to interface with + .Xr ntpd 1ntpdmdoc . + _END_PROG_MDOC_DESCRIP; +}; + +/* +prog-info-descrip = <<- _END_PROG_INFO_DESCRIP + _END_PROG_INFO_DESCRIP; +*/ + +doc-section = { + ds-type = 'USAGE'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_USAGE + .Nm + currently uses a private MIB OID, + .Ql enterprises.5597 , + which is the Meinberg top level OEM OID, and + .Ql 99 + is the temporary working space for this project. + The final OID has to be registered with IANA + and this is done by the RFC Editor + when the NTPv4 MIB RFC is standardized. + .Pp + If you have + .Xr snmpwalk 1 + installed you can run + .Dl % snmpwalk -v2c -c public localhost enterprises.5597.99 + to see a list of all currently supported NTP MIB objects + and their current values. + _END_MDOC_USAGE; +}; + +doc-section = { + ds-type = 'NOTES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_NOTES +The following objects are currently supported: +.Pp +.Bl -tag -width ".Li ntpEntSoftwareVersionVal" -compact -offset indent +.It Li ntpEntSoftwareName +please fill me in... +.It Li ntpEntSoftwareVersion +please fill me in... +.It Li ntpEntSoftwareVersionVal +please fill me in... +.It Li ntpEntSoftwareVendor +please fill me in... +.It Li ntpEntSystemType +please fill me in... +.It Li ntpEntTimeResolution +please fill me in... +.It Li ntpEntTimeResolutionVal +please fill me in... +.It Li ntpEntTimePrecision +please fill me in... +.It Li ntpEntTimePrecisionVal +please fill me in... +.It Li ntpEntTimeDistance +please fill me in... +.El + _END_MDOC_NOTES; +}; + +doc-section = { + ds-type = 'AUTHORS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_AUTHORS +.An "Heiko Gerstung" + _END_MDOC_AUTHORS; +}; + +/* +doc-section = { + ds-type = 'SEE ALSO'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_SEE_ALSO +.Rs +.%A H. Gerstung +.%A C. Elliott +.%A B. Haberman, Ed. +.%T Definitions of Managed Objects for Network Time Protocol Version 4: (NTPv4) +.%O RFC5907 +.Re + _END_MDOC_SEE_ALSO; +}; +*/ + +/* +doc-section = { + ds-type = 'BUGS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_BUGS + _END_MDOC_BUGS; +}; +*/ diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h b/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h new file mode 100644 index 000000000..07756dd59 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd-opts.h @@ -0,0 +1,243 @@ +/* + * EDIT THIS FILE WITH CAUTION (ntpsnmpd-opts.h) + * + * It has been AutoGen-ed October 21, 2015 at 12:39:32 PM by AutoGen 5.18.5 + * From the definitions ntpsnmpd-opts.def + * and the template file options + * + * Generated from AutoOpts 41:0:16 templates. + * + * AutoOpts is a copyrighted work. This header file is not encumbered + * by AutoOpts licensing, but is provided under the licensing terms chosen + * by the ntpsnmpd author or copyright holder. AutoOpts is + * licensed under the terms of the LGPL. The redistributable library + * (``libopts'') is licensed under the terms of either the LGPL or, at the + * users discretion, the BSD license. See the AutoOpts and/or libopts sources + * for details. + * + * The ntpsnmpd program is copyrighted and licensed + * under the following terms: + * + * Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation, all rights reserved. + * This is free software. It is licensed for use, modification and + * redistribution under the terms of the NTP License, copies of which + * can be seen at: + * + * + * + * Permission to use, copy, modify, and distribute this software and its + * documentation for any purpose with or without fee is hereby granted, + * provided that the above copyright notice appears in all copies and that + * both the copyright notice and this permission notice appear in + * supporting documentation, and that the name The University of Delaware not be used in + * advertising or publicity pertaining to distribution of the software + * without specific, written prior permission. The University of Delaware and Network Time Foundation makes no + * representations about the suitability this software for any purpose. It + * is provided "as is" without express or implied warranty. + */ +/** + * This file contains the programmatic interface to the Automated + * Options generated for the ntpsnmpd program. + * These macros are documented in the AutoGen info file in the + * "AutoOpts" chapter. Please refer to that doc for usage help. + */ +#ifndef AUTOOPTS_NTPSNMPD_OPTS_H_GUARD +#define AUTOOPTS_NTPSNMPD_OPTS_H_GUARD 1 +#include "config.h" +#include + +/** + * Ensure that the library used for compiling this generated header is at + * least as new as the version current when the header template was released + * (not counting patch version increments). Also ensure that the oldest + * tolerable version is at least as old as what was current when the header + * template was released. + */ +#define AO_TEMPLATE_VERSION 167936 +#if (AO_TEMPLATE_VERSION < OPTIONS_MINIMUM_VERSION) \ + || (AO_TEMPLATE_VERSION > OPTIONS_STRUCT_VERSION) +# error option template version mismatches autoopts/options.h header + Choke Me. +#endif + +/** + * Enumeration of each option type for ntpsnmpd + */ +typedef enum { + INDEX_OPT_NOFORK = 0, + INDEX_OPT_SYSLOG = 1, + INDEX_OPT_AGENTXSOCKET = 2, + INDEX_OPT_VERSION = 3, + INDEX_OPT_HELP = 4, + INDEX_OPT_MORE_HELP = 5, + INDEX_OPT_SAVE_OPTS = 6, + INDEX_OPT_LOAD_OPTS = 7 +} teOptIndex; +/** count of all options for ntpsnmpd */ +#define OPTION_CT 8 +/** ntpsnmpd version */ +#define NTPSNMPD_VERSION "4.2.8p4" +/** Full ntpsnmpd version text */ +#define NTPSNMPD_FULL_VERSION "ntpsnmpd 4.2.8p4" + +/** + * Interface defines for all options. Replace "n" with the UPPER_CASED + * option name (as in the teOptIndex enumeration above). + * e.g. HAVE_OPT(NOFORK) + */ +#define DESC(n) (ntpsnmpdOptions.pOptDesc[INDEX_OPT_## n]) +/** 'true' if an option has been specified in any way */ +#define HAVE_OPT(n) (! UNUSED_OPT(& DESC(n))) +/** The string argument to an option. The argument type must be \"string\". */ +#define OPT_ARG(n) (DESC(n).optArg.argString) +/** Mask the option state revealing how an option was specified. + * It will be one and only one of \a OPTST_SET, \a OPTST_PRESET, + * \a OPTST_DEFINED, \a OPTST_RESET or zero. + */ +#define STATE_OPT(n) (DESC(n).fOptState & OPTST_SET_MASK) +/** Count of option's occurrances *on the command line*. */ +#define COUNT_OPT(n) (DESC(n).optOccCt) +/** mask of \a OPTST_SET and \a OPTST_DEFINED. */ +#define ISSEL_OPT(n) (SELECTED_OPT(&DESC(n))) +/** 'true' if \a HAVE_OPT would yield 'false'. */ +#define ISUNUSED_OPT(n) (UNUSED_OPT(& DESC(n))) +/** 'true' if OPTST_DISABLED bit not set. */ +#define ENABLED_OPT(n) (! DISABLED_OPT(& DESC(n))) +/** number of stacked option arguments. + * Valid only for stacked option arguments. */ +#define STACKCT_OPT(n) (((tArgList*)(DESC(n).optCookie))->useCt) +/** stacked argument vector. + * Valid only for stacked option arguments. */ +#define STACKLST_OPT(n) (((tArgList*)(DESC(n).optCookie))->apzArgs) +/** Reset an option. */ +#define CLEAR_OPT(n) STMTS( \ + DESC(n).fOptState &= OPTST_PERSISTENT_MASK; \ + if ((DESC(n).fOptState & OPTST_INITENABLED) == 0) \ + DESC(n).fOptState |= OPTST_DISABLED; \ + DESC(n).optCookie = NULL ) +/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ +/** + * Enumeration of ntpsnmpd exit codes + */ +typedef enum { + NTPSNMPD_EXIT_SUCCESS = 0, + NTPSNMPD_EXIT_FAILURE = 1, + NTPSNMPD_EXIT_USAGE_ERROR = 64, + NTPSNMPD_EXIT_NO_CONFIG_INPUT = 66, + NTPSNMPD_EXIT_LIBOPTS_FAILURE = 70 +} ntpsnmpd_exit_code_t; +/** @} */ +/** + * Make sure there are no #define name conflicts with the option names + */ +#ifndef NO_OPTION_NAME_WARNINGS +# ifdef NOFORK +# warning undefining NOFORK due to option name conflict +# undef NOFORK +# endif +# ifdef SYSLOG +# warning undefining SYSLOG due to option name conflict +# undef SYSLOG +# endif +# ifdef AGENTXSOCKET +# warning undefining AGENTXSOCKET due to option name conflict +# undef AGENTXSOCKET +# endif +#else /* NO_OPTION_NAME_WARNINGS */ +# undef NOFORK +# undef SYSLOG +# undef AGENTXSOCKET +#endif /* NO_OPTION_NAME_WARNINGS */ + +/** + * Interface defines for specific options. + * @{ + */ +#define VALUE_OPT_NOFORK 'n' +#define VALUE_OPT_SYSLOG 'p' +#define VALUE_OPT_AGENTXSOCKET 0x1001 +/** option flag (value) for help-value option */ +#define VALUE_OPT_HELP '?' +/** option flag (value) for more-help-value option */ +#define VALUE_OPT_MORE_HELP '!' +/** option flag (value) for version-value option */ +#define VALUE_OPT_VERSION 0x1002 +/** option flag (value) for save-opts-value option */ +#define VALUE_OPT_SAVE_OPTS '>' +/** option flag (value) for load-opts-value option */ +#define VALUE_OPT_LOAD_OPTS '<' +#define SET_OPT_SAVE_OPTS(a) STMTS( \ + DESC(SAVE_OPTS).fOptState &= OPTST_PERSISTENT_MASK; \ + DESC(SAVE_OPTS).fOptState |= OPTST_SET; \ + DESC(SAVE_OPTS).optArg.argString = (char const*)(a)) +/* + * Interface defines not associated with particular options + */ +#define ERRSKIP_OPTERR STMTS(ntpsnmpdOptions.fOptSet &= ~OPTPROC_ERRSTOP) +#define ERRSTOP_OPTERR STMTS(ntpsnmpdOptions.fOptSet |= OPTPROC_ERRSTOP) +#define RESTART_OPT(n) STMTS( \ + ntpsnmpdOptions.curOptIdx = (n); \ + ntpsnmpdOptions.pzCurOpt = NULL ) +#define START_OPT RESTART_OPT(1) +#define USAGE(c) (*ntpsnmpdOptions.pUsageProc)(&ntpsnmpdOptions, c) + +#ifdef __cplusplus +extern "C" { +#endif + + +/* * * * * * + * + * Declare the ntpsnmpd option descriptor. + */ +extern tOptions ntpsnmpdOptions; + +#if defined(ENABLE_NLS) +# ifndef _ +# include +# ifndef HAVE_GETTEXT + extern char * gettext(char const *); +# else +# include +# endif + +# ifndef ATTRIBUTE_FORMAT_ARG +# define ATTRIBUTE_FORMAT_ARG(_a) +# endif + +static inline char* aoGetsText(char const* pz) ATTRIBUTE_FORMAT_ARG(1); +static inline char* aoGetsText(char const* pz) { + if (pz == NULL) return NULL; + return (char*)gettext(pz); +} +# define _(s) aoGetsText(s) +# endif /* _() */ + +# define OPT_NO_XLAT_CFG_NAMES STMTS(ntpsnmpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT_CFG;) +# define OPT_NO_XLAT_OPT_NAMES STMTS(ntpsnmpdOptions.fOptSet |= \ + OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG;) + +# define OPT_XLAT_CFG_NAMES STMTS(ntpsnmpdOptions.fOptSet &= \ + ~(OPTPROC_NXLAT_OPT|OPTPROC_NXLAT_OPT_CFG);) +# define OPT_XLAT_OPT_NAMES STMTS(ntpsnmpdOptions.fOptSet &= \ + ~OPTPROC_NXLAT_OPT;) + +#else /* ENABLE_NLS */ +# define OPT_NO_XLAT_CFG_NAMES +# define OPT_NO_XLAT_OPT_NAMES + +# define OPT_XLAT_CFG_NAMES +# define OPT_XLAT_OPT_NAMES + +# ifndef _ +# define _(_s) _s +# endif +#endif /* ENABLE_NLS */ + +#ifdef __cplusplus +} +#endif +#endif /* AUTOOPTS_NTPSNMPD_OPTS_H_GUARD */ + +/* ntpsnmpd-opts.h ends here */ diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdman b/contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdman new file mode 100644 index 000000000..1a5dff3d6 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdman @@ -0,0 +1,203 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpsnmpd 1ntpsnmpdman "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-Xna4nO/ag-9naWmO) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:39 PM by AutoGen 5.18.5 +.\" From the definitions ntpsnmpd-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpsnmpd\fP +\- NTP SNMP MIB agent +.SH SYNOPSIS +\f\*[B-Font]ntpsnmpd\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntpsnmpd\fP +is an SNMP MIB agent designed to interface with +\fCntpd\f[]\fR(1ntpdmdoc)\f[]. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-nofork\f[] +Do not fork. +.sp +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-syslog\f[] +Log to syslog(). +.sp +.TP +.NOP \f\*[B-Font]\-\-agentxsocket\f[]=\f\*[I-Font]string\f[] +The socket address ntpsnmpd uses to connect to net-snmpd. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + unix:/var/agentx/master +.sp +[:] +The default "agent X socket" is the Unix Domain socket +\fIunix:/var/agentx/master\fP. +Another common alternative is \fItcp:localhost:705\fP. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\->\f[] [\f\*[I-Font]cfgfile\f[]], \f\*[B-Font]\-\-save-opts\f[] [=\f\*[I-Font]cfgfile\f[]] +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.TP +.NOP \f\*[B-Font]\-<\f[] \f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-load-opts\f[]=\f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-no-load-opts\f[] +Load options from \fIcfgfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early, +out of order. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPSNMPD_\fP or \fBNTPSNMPD\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.SH USAGE +\f\*[B-Font]ntpsnmpd\fP +currently uses a private MIB OID, +\[oq]enterprises.5597\[cq], +which is the Meinberg top level OEM OID, and +\[oq]99\[cq] +is the temporary working space for this project. +The final OID has to be registered with IANA +and this is done by the RFC Editor +when the NTPv4 MIB RFC is standardized. +.sp \n(Ppu +.ne 2 + +If you have +\fCsnmpwalk\f[]\fR(1)\f[] +installed you can run +.Dl % snmpwalk \-v2c \-c public localhost enterprises.5597.99 +to see a list of all currently supported NTP MIB objects +and their current values. +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH AUTHORS +.NOP "Heiko Gerstung" +.br +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +The following objects are currently supported: +.sp \n(Ppu +.ne 2 + +.TP 29 +.NOP \f[C]ntpEntSoftwareName\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSoftwareVersion\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSoftwareVersionVal\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSoftwareVendor\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSystemType\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimeResolution\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimeResolutionVal\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimePrecision\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimePrecisionVal\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimeDistance\f[] +please fill me in... +.PP +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntpsnmpd\fP +option definitions. diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc b/contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc new file mode 100644 index 000000000..e13b8165d --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd.1ntpsnmpdmdoc @@ -0,0 +1,144 @@ +.Dd October 21 2015 +.Dt NTPSNMPD 1ntpsnmpdmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpsnmpd-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:45 PM by AutoGen 5.18.5 +.\" From the definitions ntpsnmpd-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpsnmpd +.Nd NTP SNMP MIB agent +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.Nm +is an SNMP MIB agent designed to interface with +.Xr ntpd 1ntpdmdoc . +.Sh "OPTIONS" +.Bl -tag +.It Fl n , Fl \-nofork +Do not fork. +.sp +.It Fl p , Fl \-syslog +Log to syslog(). +.sp +.It Fl \-agentxsocket Ns = Ns Ar string +The socket address ntpsnmpd uses to connect to net\-snmpd. +The default +.Ar string +for this option is: +.ti +4 + unix:/var/agentx/master +.sp +[:] +The default "agent X socket" is the Unix Domain socket +\fIunix:/var/agentx/master\fP. +Another common alternative is \fItcp:localhost:705\fP. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl > Oo Ar cfgfile Oc , Fl \-save\-opts Oo Ns = Ns Ar cfgfile Oc +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.It Fl < Ar cfgfile , Fl \-load\-opts Ns = Ns Ar cfgfile , Fl \-no\-load\-opts +Load options from \fIcfgfile\fP. +The \fIno\-load\-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no\-load\-opts\fP is handled early, +out of order. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPSNMPD_\fP or \fBNTPSNMPD\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.Sh USAGE +.Nm +currently uses a private MIB OID, +.Ql enterprises.5597 , +which is the Meinberg top level OEM OID, and +.Ql 99 +is the temporary working space for this project. +The final OID has to be registered with IANA +and this is done by the RFC Editor +when the NTPv4 MIB RFC is standardized. +.Pp +If you have +.Xr snmpwalk 1 +installed you can run +.Dl % snmpwalk \-v2c \-c public localhost enterprises.5597.99 +to see a list of all currently supported NTP MIB objects +and their current values. +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh AUTHORS +.An "Heiko Gerstung" +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +The following objects are currently supported: +.Pp +.Bl -tag -width ".Li ntpEntSoftwareVersionVal" -compact -offset indent +.It Li ntpEntSoftwareName +please fill me in... +.It Li ntpEntSoftwareVersion +please fill me in... +.It Li ntpEntSoftwareVersionVal +please fill me in... +.It Li ntpEntSoftwareVendor +please fill me in... +.It Li ntpEntSystemType +please fill me in... +.It Li ntpEntTimeResolution +please fill me in... +.It Li ntpEntTimeResolutionVal +please fill me in... +.It Li ntpEntTimePrecision +please fill me in... +.It Li ntpEntTimePrecisionVal +please fill me in... +.It Li ntpEntTimeDistance +please fill me in... +.El +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntpsnmpd\fP +option definitions. diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd.c b/contrib/ntp/ntpsnmpd/ntpsnmpd.c new file mode 100644 index 000000000..d96ad3af4 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd.c @@ -0,0 +1,118 @@ +/***************************************************************************** + * + * ntpsnmpd.c + * + * The NTP SNMP daemon is an Agent X subagent application that + * registers itself with a running SNMP Agent X master process running + * on the same machine on port TCP 705. It utilizes the libntqp library + * which accesses status and general data of a running ntpd process on + * the same machine and enables the user to monitor the status of a + * ntp daemon process via SNMP. + * + * This started as a Google Summer of Code 2008 project, + * including the ntpsnmpd sub agent and the libntpq library. + * + * For more information please visit + * http://support.ntp.org/bin/view/Dev/GSoC2008snmp + * Or contact: + * Harlan Stenn (Mentor) at stenn@ntp.org + * Heiko Gerstung (Student) at gerstung@ntp.org + * + ****************************************************************************/ + +#include +#include +#include + +#ifdef SOLARIS /* needed with at least Solaris 8 */ +#include +#endif + +#include +#include + +static int keep_running; +RETSIGTYPE stop_server(int); + +RETSIGTYPE +stop_server(int a) { + keep_running = 0; +} + +/* The main function just sets up a few things and then enters a loop in which it will + * wait for SNMP requests coming from the master agent + */ + +int +main (int argc, char **argv) { + int background = 0; /* start as background process */ + int use_syslog = 1; /* use syslog for logging */ + + { + int optct = optionProcess(&ntpsnmpdOptions, argc, argv); + argc -= optct; + argv += optct; + } + + if (!HAVE_OPT(NOFORK)) + background = 1; + + if (!HAVE_OPT(SYSLOG)) + use_syslog = 0; + + /* using the net-snmp syslog facility */ + if (use_syslog) + snmp_enable_calllog(); + else + snmp_enable_stderrlog(); + + /* Become Subagent */ + netsnmp_ds_set_boolean(NETSNMP_DS_APPLICATION_ID, NETSNMP_DS_AGENT_ROLE, 1); + + /* go into background mode, if requested */ + if (background && netsnmp_daemonize(1, !use_syslog)) + exit(1); + + /* Now register with the master Agent X process */ + + /* call Netsnmp socket startup macro, which will initialize the network stuff if required */ + SOCK_STARTUP; + + /* Set AgentX socket interface */ + netsnmp_ds_set_string(NETSNMP_DS_APPLICATION_ID, + NETSNMP_DS_AGENT_X_SOCKET, OPT_ARG( AGENTXSOCKET )); + + init_agent("ntpsnmpd"); + + /* Try to connect to ntpd */ + if ( ntpq_openhost("localhost", 0) == 0 ) + { + fprintf(stderr, "Error: Could not connect to ntpd. Aborting.\n"); + exit(1); + } + + + /* Register callback functions ... */ + init_ntpSnmpSubagentObject(); + init_snmp("ntpsnmpd"); + + /* Signal handler */ + keep_running = 1; + signal(SIGTERM, stop_server); + signal(SIGINT, stop_server); + + snmp_log(LOG_INFO,"ntpsnmpd started.\n"); + + /* main loop here... */ + while(keep_running) { + agent_check_and_process(1); /* 0 == don't block */ + } + + /* at shutdown time */ + ntpq_closehost(); + snmp_shutdown("ntpsnmpd"); + SOCK_CLEANUP; + + return 0; +} + diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd.html b/contrib/ntp/ntpsnmpd/ntpsnmpd.html new file mode 100644 index 000000000..1ad4ffcd9 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd.html @@ -0,0 +1,79 @@ + + +ntpsnmpd: Network Time Protocol SNMP Daemon User's Manual + + + + + + + + + +

      ntpsnmpd: Network Time Protocol SNMP Daemon User's Manual

      + + + + +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      ntpsnmpd: Network Time Protocol Query User Manual

      + +

      The ntpsnmpd utility program is used to monitor NTP daemon ntpd +operations and determine performance. It uses the standard NTP mode 6 control + +

      This document applies to version 4.2.8p4 of ntpsnmpd. + +

      + +
      +


      +Next: , +Previous: Top, +Up: Top +
      +
      + + +

      Description

      + +

      The ntpsnmpd utility program provides an SNMP MIB agent for ntpd. + +

      +


      +Previous: ntpsnmpd Description, +Up: Top +
      +
      + + +

      Usage

      + +

      (what should we say here?) + + + diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd.man.in b/contrib/ntp/ntpsnmpd/ntpsnmpd.man.in new file mode 100644 index 000000000..0da76ff3f --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd.man.in @@ -0,0 +1,203 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpsnmpd @NTPSNMPD_MS@ "21 Oct 2015" "4.2.8p4" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-Xna4nO/ag-9naWmO) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:39 PM by AutoGen 5.18.5 +.\" From the definitions ntpsnmpd-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpsnmpd\fP +\- NTP SNMP MIB agent +.SH SYNOPSIS +\f\*[B-Font]ntpsnmpd\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntpsnmpd\fP +is an SNMP MIB agent designed to interface with +\fCntpd\f[]\fR(@NTPD_MS@)\f[]. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-nofork\f[] +Do not fork. +.sp +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-syslog\f[] +Log to syslog(). +.sp +.TP +.NOP \f\*[B-Font]\-\-agentxsocket\f[]=\f\*[I-Font]string\f[] +The socket address ntpsnmpd uses to connect to net-snmpd. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + unix:/var/agentx/master +.sp +[:] +The default "agent X socket" is the Unix Domain socket +\fIunix:/var/agentx/master\fP. +Another common alternative is \fItcp:localhost:705\fP. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\->\f[] [\f\*[I-Font]cfgfile\f[]], \f\*[B-Font]\-\-save-opts\f[] [=\f\*[I-Font]cfgfile\f[]] +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.TP +.NOP \f\*[B-Font]\-<\f[] \f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-load-opts\f[]=\f\*[I-Font]cfgfile\f[], \f\*[B-Font]\-\-no-load-opts\f[] +Load options from \fIcfgfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early, +out of order. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPSNMPD_\fP or \fBNTPSNMPD\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.SH USAGE +\f\*[B-Font]ntpsnmpd\fP +currently uses a private MIB OID, +\[oq]enterprises.5597\[cq], +which is the Meinberg top level OEM OID, and +\[oq]99\[cq] +is the temporary working space for this project. +The final OID has to be registered with IANA +and this is done by the RFC Editor +when the NTPv4 MIB RFC is standardized. +.sp \n(Ppu +.ne 2 + +If you have +\fCsnmpwalk\f[]\fR(1)\f[] +installed you can run +.Dl % snmpwalk \-v2c \-c public localhost enterprises.5597.99 +to see a list of all currently supported NTP MIB objects +and their current values. +.SH "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.SH "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH AUTHORS +.NOP "Heiko Gerstung" +.br +.SH "COPYRIGHT" +Copyright (C) 1992-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.SH "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.SH NOTES +The following objects are currently supported: +.sp \n(Ppu +.ne 2 + +.TP 29 +.NOP \f[C]ntpEntSoftwareName\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSoftwareVersion\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSoftwareVersionVal\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSoftwareVendor\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntSystemType\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimeResolution\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimeResolutionVal\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimePrecision\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimePrecisionVal\f[] +please fill me in... +.br +.ns +.TP 29 +.NOP \f[C]ntpEntTimeDistance\f[] +please fill me in... +.PP +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntpsnmpd\fP +option definitions. diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd.mdoc.in b/contrib/ntp/ntpsnmpd/ntpsnmpd.mdoc.in new file mode 100644 index 000000000..d2cebc452 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd.mdoc.in @@ -0,0 +1,144 @@ +.Dd October 21 2015 +.Dt NTPSNMPD @NTPSNMPD_MS@ User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpsnmpd-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:39:45 PM by AutoGen 5.18.5 +.\" From the definitions ntpsnmpd-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpsnmpd +.Nd NTP SNMP MIB agent +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.Nm +is an SNMP MIB agent designed to interface with +.Xr ntpd @NTPD_MS@ . +.Sh "OPTIONS" +.Bl -tag +.It Fl n , Fl \-nofork +Do not fork. +.sp +.It Fl p , Fl \-syslog +Log to syslog(). +.sp +.It Fl \-agentxsocket Ns = Ns Ar string +The socket address ntpsnmpd uses to connect to net\-snmpd. +The default +.Ar string +for this option is: +.ti +4 + unix:/var/agentx/master +.sp +[:] +The default "agent X socket" is the Unix Domain socket +\fIunix:/var/agentx/master\fP. +Another common alternative is \fItcp:localhost:705\fP. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl > Oo Ar cfgfile Oc , Fl \-save\-opts Oo Ns = Ns Ar cfgfile Oc +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.It Fl < Ar cfgfile , Fl \-load\-opts Ns = Ns Ar cfgfile , Fl \-no\-load\-opts +Load options from \fIcfgfile\fP. +The \fIno\-load\-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no\-load\-opts\fP is handled early, +out of order. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "OPTION PRESETS" +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from configuration ("RC" or ".INI") file(s) and values from +environment variables named: +.nf + \fBNTPSNMPD_\fP or \fBNTPSNMPD\fP +.fi +.ad +The environmental presets take precedence (are processed later than) +the configuration files. +The \fIhomerc\fP files are "\fI$HOME\fP", and "\fI.\fP". +If any of these are directories, then the file \fI.ntprc\fP +is searched for within those directories. +.Sh USAGE +.Nm +currently uses a private MIB OID, +.Ql enterprises.5597 , +which is the Meinberg top level OEM OID, and +.Ql 99 +is the temporary working space for this project. +The final OID has to be registered with IANA +and this is done by the RFC Editor +when the NTPv4 MIB RFC is standardized. +.Pp +If you have +.Xr snmpwalk 1 +installed you can run +.Dl % snmpwalk \-v2c \-c public localhost enterprises.5597.99 +to see a list of all currently supported NTP MIB objects +and their current values. +.Sh "ENVIRONMENT" +See \fBOPTION PRESETS\fP for configuration environment variables. +.Sh "FILES" +See \fBOPTION PRESETS\fP for configuration files. +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 66 " (EX_NOINPUT)" +A specified configuration file could not be loaded. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh AUTHORS +.An "Heiko Gerstung" +.Sh "COPYRIGHT" +Copyright (C) 1992\-2015 The University of Delaware and Network Time Foundation all rights reserved. +This program is released under the terms of the NTP license, . +.Sh "BUGS" +Please send bug reports to: http://bugs.ntp.org, bugs@ntp.org +.Sh NOTES +The following objects are currently supported: +.Pp +.Bl -tag -width ".Li ntpEntSoftwareVersionVal" -compact -offset indent +.It Li ntpEntSoftwareName +please fill me in... +.It Li ntpEntSoftwareVersion +please fill me in... +.It Li ntpEntSoftwareVersionVal +please fill me in... +.It Li ntpEntSoftwareVendor +please fill me in... +.It Li ntpEntSystemType +please fill me in... +.It Li ntpEntTimeResolution +please fill me in... +.It Li ntpEntTimeResolutionVal +please fill me in... +.It Li ntpEntTimePrecision +please fill me in... +.It Li ntpEntTimePrecisionVal +please fill me in... +.It Li ntpEntTimeDistance +please fill me in... +.El +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntpsnmpd\fP +option definitions. diff --git a/contrib/ntp/ntpsnmpd/ntpsnmpd.texi b/contrib/ntp/ntpsnmpd/ntpsnmpd.texi new file mode 100644 index 000000000..693559670 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpsnmpd.texi @@ -0,0 +1,53 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntpsnmpd.info +@settitle ntpsnmpd: Network Time Protocol SNMP Daemon User's Manual +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of the NTP Project's ntpsnmpd, a program for +querying the state of an NTP server via SNMP. +@end ifinfo + +@direntry +* ntpsnmpd: (ntpsnmpd). NTP SNMP Daemon program +@end direntry + +@titlepage +@title ntpsnmpd: Network Time Protocol SNMP Daemon User's Manual +@subtitle ntpsnmpd, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@shortcontents + +@node Top, ntpsnmpd Description, (dir), (dir) +@top ntpsnmpd: Network Time Protocol Query User Manual + +The @code{ntpsnmpd} utility program is used to monitor NTP daemon @code{ntpd} +operations and determine performance. It uses the standard NTP mode 6 control + +This document applies to version @value{VERSION} of @code{ntpsnmpd}. + +@menu +* ntpsnmpd Description:: Description +* ntpsnmpd Invocation:: Invoking ntpsnmpd +* Usage:: Usage +@end menu + +@node ntpsnmpd Description, Usage, Top, Top +@comment node-name, next, previous, up +@section Description + +The @code{ntpsnmpd} utility program provides an SNMP MIB agent for @code{ntpd}. + +@node Usage, , ntpsnmpd Description, Top +@comment node-name, next, previous, up +@section Usage + +(what should we say here?) diff --git a/contrib/ntp/ntpsnmpd/ntpv4-mib.mib b/contrib/ntp/ntpsnmpd/ntpv4-mib.mib new file mode 100644 index 000000000..e8cb01658 --- /dev/null +++ b/contrib/ntp/ntpsnmpd/ntpv4-mib.mib @@ -0,0 +1,892 @@ +-- ********************************************************************* +-- +-- The Network Time Protocol Version 4 +-- Management Information Base (MIB) +-- +-- Authors: Heiko Gerstung (heiko.gerstung@meinberg.de) +-- Chris Elliott (chelliot@pobox.com) +-- +-- for the Internet Engineering Task Force (IETF) +-- NTP Working Group (ntpwg) +-- +-- +-- ********************************************************************* +-- Rev 1.00 +-- Published as RFC 5907 +-- +-- ********************************************************************* + +NTPv4-MIB DEFINITIONS ::= BEGIN + +IMPORTS + MODULE-IDENTITY, OBJECT-TYPE , mib-2, Integer32, NOTIFICATION-TYPE, + Unsigned32, Counter32, TimeTicks + FROM SNMPv2-SMI -- RFC 2578 + MODULE-COMPLIANCE, OBJECT-GROUP, NOTIFICATION-GROUP + FROM SNMPv2-CONF -- RFC 2580 + DisplayString, TEXTUAL-CONVENTION + FROM SNMPv2-TC -- RFC 2579 + InetAddressType, InetAddress + FROM INET-ADDRESS-MIB -- RFC 4001 + Utf8String + FROM SYSAPPL-MIB; -- RFC 2287 + +ntpSnmpMIB MODULE-IDENTITY + LAST-UPDATED "201005170000Z" -- May 17, 2010 + ORGANIZATION "The IETF NTP Working Group (ntpwg)" + CONTACT-INFO + " WG Email: ntpwg@lists.ntp.isc.org + Subscribe: + https://lists.ntp.isc.org/mailman/listinfo/ntpwg + + Heiko Gerstung + Meinberg Funkuhren Gmbh & Co. KG + Lange Wand 9 + Bad Pyrmont 31812 + Germany + + Phone: +49 5281 9309 25 + Email: heiko.gerstung@meinberg.de + + Chris Elliott + 1516 Kent St. + Durham, NC 27707 + USA + + Phone: +1-919-308-1216 + Email: chelliot@pobox.com + + Brian Haberman + 11100 Johns Hopkins Road + Laurel, MD 20723 + USA + + Phone: +1-443-778-1319 + Email: brian@innovationslab.net" + DESCRIPTION + "The Management Information Base for NTP time entities. + + Copyright (c) 2010 IETF Trust and the persons identified as + authors of the code. All rights reserved. + + Redistribution and use in source and binary forms, with or + without modification, is permitted pursuant to, and subject + to the license terms contained in, the Simplified BSD License + set forth in Section 4.c of the IETF Trust's Legal Provisions + Relating to IETF Documents + (http://trustee.ietf.org/license-info)." + + REVISION "201005170000Z" + DESCRIPTION + "This revision of the MIB module is published as RFC 5907." + + ::= { mib-2 197 } + +ntpSnmpMIBObjects OBJECT IDENTIFIER ::= { ntpSnmpMIB 1 } + +-- MIB contains 6 groups + +ntpEntInfo OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 1 } +ntpEntStatus OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 2 } +ntpAssociation OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 3 } +ntpEntControl OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 4 } +ntpEntNotifObjects OBJECT IDENTIFIER ::= { ntpSnmpMIBObjects 5 } + +-- +-- Textual Conventions +-- + +NtpStratum ::= TEXTUAL-CONVENTION + DISPLAY-HINT "d" + STATUS current + DESCRIPTION + "The NTP stratum, with 16 representing no stratum." + SYNTAX Unsigned32 (1..16) + +NtpDateTime ::= TEXTUAL-CONVENTION + DISPLAY-HINT "4d:4d:4d.4d" + STATUS current + DESCRIPTION + "NTP date/time on the device, in 128-bit + NTP date format. If time is not syncronized, this + field shall be a zero-length string. + + This trusted certificate (TC) is not to be used for objects + that are used to set the time of the node querying this + object. NTP should be used for this -- or at least SNTP." + REFERENCE "RFC 5905, section 6" + SYNTAX OCTET STRING (SIZE (0 | 16)) + +-- +-- Section 1: General NTP Entity information objects +-- (relatively static information) +-- + +ntpEntSoftwareName OBJECT-TYPE + SYNTAX Utf8String + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The product name of the running NTP version, e.g., 'ntpd'." + ::= { ntpEntInfo 1 } + +ntpEntSoftwareVersion OBJECT-TYPE + SYNTAX Utf8String + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The software version of the installed NTP implementation + as a full version string, e.g., 'ntpd-4.2.0b@1.1433 ...'" + ::= { ntpEntInfo 2 } + +ntpEntSoftwareVendor OBJECT-TYPE + SYNTAX Utf8String + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The vendor/author of the installed NTP version." + ::= { ntpEntInfo 3 } + +ntpEntSystemType OBJECT-TYPE + SYNTAX Utf8String + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "General hardware/os platform information, + e.g., 'Linux 2.6.12 / x86'." + -- freely configurable, default is OS Version / Hardware platform + ::= { ntpEntInfo 4 } + +ntpEntTimeResolution OBJECT-TYPE + SYNTAX Unsigned32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The time resolution in integer format, where the resolution + is represented as divisions of a second, e.g., a value of 1000 + translates to 1.0 ms." + ::= { ntpEntInfo 5 } + +ntpEntTimePrecision OBJECT-TYPE + SYNTAX Integer32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The entity's precision in integer format, shows the precision. + A value of -5 would mean 2^-5 = 31.25 ms." + ::= { ntpEntInfo 6 } + +ntpEntTimeDistance OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The distance from this NTP entity to the root time reference + (stratum 0) source including the unit, e.g., '13.243 ms'." + ::= { ntpEntInfo 7 } + +-- +-- Section 2: Current NTP status (dynamic information) +-- + +ntpEntStatusCurrentMode OBJECT-TYPE + SYNTAX INTEGER { + notRunning(1), + notSynchronized(2), + noneConfigured(3), + syncToLocal(4), + syncToRefclock(5), + syncToRemoteServer(6), + unknown(99) + } + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The current mode of the NTP. The definition of each possible + value is: + notRunning(1) - NTP is not running. + notSynchronized(2) - NTP is not synchronized to any time + source (stratum = 16). + noneConfigured(3) - NTP is not synchronized and does not + have a reference configured + (stratum = 16). + syncToLocal(4) - NTP is distributing time based on its + local clock (degraded accuracy and/or + reliability). + syncToRefclock(5) - NTP is synchronized to a local + hardware refclock (e.g., GPS). + syncToRemoteServer(6) - NTP is synchronized to a remote + NTP server ('upstream' server). + unknown(99) - The state of NTP is unknown." + ::= { ntpEntStatus 1 } + +ntpEntStatusStratum OBJECT-TYPE + SYNTAX NtpStratum + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The NTP entity's own stratum value. Should be a stratum of + syspeer + 1 (or 16 if no syspeer)." + ::= { ntpEntStatus 2 } + +ntpEntStatusActiveRefSourceId OBJECT-TYPE + SYNTAX Unsigned32 ( 0..99999 ) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The association ID of the current syspeer." + ::= { ntpEntStatus 3 } + +ntpEntStatusActiveRefSourceName OBJECT-TYPE + SYNTAX Utf8String + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The hostname/descriptive name of the current reference source + selected as syspeer, e.g., 'ntp1.ptb.de' or 'GPS' or + 'DCFi', ..." + ::= { ntpEntStatus 4 } + +ntpEntStatusActiveOffset OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The time offset to the current selected reference time source + as a string including unit, e.g., '0.032 ms' or '1.232 s'." + ::= { ntpEntStatus 5 } + +ntpEntStatusNumberOfRefSources OBJECT-TYPE + SYNTAX Unsigned32 (0..99) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of reference sources configured for NTP." + ::= { ntpEntStatus 6 } + +ntpEntStatusDispersion OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The root dispersion of the running NTP entity, e.g., '6.927'." + ::= { ntpEntStatus 7 } + +ntpEntStatusEntityUptime OBJECT-TYPE + SYNTAX TimeTicks + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The uptime of the NTP entity, (i.e., the time since ntpd was + (re-)initialized not sysUptime!). The time is represented in + hundreds of seconds since Jan 1, 1970 (00:00:00.000) UTC." + ::= { ntpEntStatus 8 } + +ntpEntStatusDateTime OBJECT-TYPE + SYNTAX NtpDateTime + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The current NTP date/time on the device, in 128-bit + NTP date format. If time is not syncronized, this + field shall be a zero-length string. + + This object can be used to timestamp events on this + node and allow a management station to correlate + different time objects. For example, a management + station could query this object and sysUpTime in + the same operation to be able to relate sysUpTime + to NTP time. + + This object is not to be used to set the time of + the node querying this object. NTP should be used + for this -- or at least SNTP." + REFERENCE "RFC 5905, section 6" + ::= { ntpEntStatus 9 } + +ntpEntStatusLeapSecond OBJECT-TYPE + SYNTAX NtpDateTime + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "Date the next known leap second will occur. If there is + no leap second announced, then this object should be 0." + ::= { ntpEntStatus 10 } + +ntpEntStatusLeapSecDirection OBJECT-TYPE + SYNTAX Integer32 (-1..1) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "Direction of next known leap second. If there is no + leap second announced, then this object should be 0." + ::= { ntpEntStatus 11 } + +ntpEntStatusInPkts OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + NTP entity from the transport service. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpEntStatus 12 } + +ntpEntStatusOutPkts OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + transport service by this NTP entity. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpEntStatus 13 } + +ntpEntStatusBadVersion OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages that were delivered + to this NTP entity and were for an unsupported NTP + version. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpEntStatus 14 } + +ntpEntStatusProtocolError OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages that were delivered + to this NTP entity and this entity was not able to + process due to an NTP protocol error. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpEntStatus 15 } + +ntpEntStatusNotifications OBJECT-TYPE + SYNTAX Counter32 + UNITS "notifications" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of SNMP notifications that this NTP + entity has generated. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpEntStatus 16 } + +ntpEntStatPktModeTable OBJECT-TYPE + SYNTAX SEQUENCE OF NtpEntStatPktModeEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The number of packets sent and received by packet mode. + One entry per packet mode." + ::= { ntpEntStatus 17 } + +ntpEntStatPktModeEntry OBJECT-TYPE + SYNTAX NtpEntStatPktModeEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "A statistical record of the number of packets sent and + received for each packet mode." + INDEX { ntpEntStatPktMode } + ::= { ntpEntStatPktModeTable 1 } + +NtpEntStatPktModeEntry ::= SEQUENCE { + ntpEntStatPktMode INTEGER, + ntpEntStatPktSent Counter32, + ntpEntStatPktReceived Counter32 +} + +ntpEntStatPktMode OBJECT-TYPE + SYNTAX INTEGER { + symetricactive(1), + symetricpassive(2), + client(3), + server(4), + broadcastserver(5), + broadcastclient(6) + } + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The NTP packet mode." + ::= { ntpEntStatPktModeEntry 1 } + +ntpEntStatPktSent OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of NTP packets sent with this packet mode. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpEntStatPktModeEntry 2 } + +ntpEntStatPktReceived OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of NTP packets received with this packet mode. + + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpEntStatPktModeEntry 3 } + +-- +-- Section 3: The status of all currently mobilized associations +-- + +ntpAssociationTable OBJECT-TYPE + SYNTAX SEQUENCE OF NtpAssociationEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table of currently mobilized associations." + ::= { ntpAssociation 1 } + +ntpAssociationEntry OBJECT-TYPE + SYNTAX NtpAssociationEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table entry of currently mobilized associations." + INDEX { ntpAssocId } + ::= { ntpAssociationTable 1 } + +NtpAssociationEntry ::= SEQUENCE { + ntpAssocId Unsigned32, + ntpAssocName Utf8String, + ntpAssocRefId DisplayString, + ntpAssocAddressType InetAddressType, + ntpAssocAddress InetAddress, + ntpAssocOffset DisplayString, + ntpAssocStratum NtpStratum, + ntpAssocStatusJitter DisplayString, + ntpAssocStatusDelay DisplayString, + ntpAssocStatusDispersion DisplayString +} + +ntpAssocId OBJECT-TYPE + SYNTAX Unsigned32 ( 1..99999 ) + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The association ID. This is an internal, unique ID." + ::= { ntpAssociationEntry 1 } + +ntpAssocName OBJECT-TYPE + SYNTAX Utf8String + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The hostname or other descriptive name for the association." + ::= { ntpAssociationEntry 2 } + +ntpAssocRefId OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The refclock driver ID, if available." + -- a refclock driver ID like "127.127.1.0" for non + -- uni/multi/broadcast associations + ::= { ntpAssociationEntry 3 } + +ntpAssocAddressType OBJECT-TYPE + SYNTAX InetAddressType { ipv4(1), ipv6(2), ipv4z(3), ipv6z(4) } + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The type of address of the association. Can be either IPv4 or + IPv6 (both with or without zone index) and contains the type of + address for unicast, multicast, and broadcast associations." + ::= { ntpAssociationEntry 4 } + +ntpAssocAddress OBJECT-TYPE + SYNTAX InetAddress (SIZE (4|8|16|20)) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The IP address (IPv4 or IPv6, with or without zone index) of + the association. The type and size depends on the + ntpAssocAddressType object. Represents the IP address of a + uni/multi/broadcast association." + ::= { ntpAssociationEntry 5 } + +ntpAssocOffset OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The time offset to the association as a string." + -- including unit, e.g., "0.032 ms" or "1.232 s" + ::= { ntpAssociationEntry 6 } + +ntpAssocStratum OBJECT-TYPE + SYNTAX NtpStratum + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The association stratum value." + ::= { ntpAssociationEntry 7 } + +ntpAssocStatusJitter OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The jitter in milliseconds as a string." + ::= { ntpAssociationEntry 8 } + +ntpAssocStatusDelay OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The network delay in milliseconds as a string." + ::= { ntpAssociationEntry 9 } + +ntpAssocStatusDispersion OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The root dispersion of the association." + -- e.g., "6.927" + ::= { ntpAssociationEntry 10 } + +ntpAssociationStatisticsTable OBJECT-TYPE + SYNTAX SEQUENCE OF NtpAssociationStatisticsEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table of statistics for current associations." + ::= { ntpAssociation 2 } + +ntpAssociationStatisticsEntry OBJECT-TYPE + SYNTAX NtpAssociationStatisticsEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "The table entry of statistics for current associations." + INDEX { ntpAssocId } + ::= { ntpAssociationStatisticsTable 1 } + +NtpAssociationStatisticsEntry ::= SEQUENCE { + ntpAssocStatInPkts Counter32, + ntpAssocStatOutPkts Counter32, + ntpAssocStatProtocolError Counter32 +} + +ntpAssocStatInPkts OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + NTP entity from this association. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpAssociationStatisticsEntry 1 } + +ntpAssocStatOutPkts OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages delivered to the + transport service by this NTP entity for this + association. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpAssociationStatisticsEntry 2 } + +ntpAssocStatProtocolError OBJECT-TYPE + SYNTAX Counter32 + UNITS "packets" + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The total number of NTP messages that were delivered + to this NTP entity from this association and this entity + was not able to process due to an NTP protocol error. + Discountinuities in the value of this counter can occur + upon cold start or reinitialization of the NTP entity, the + management system and at other times as indicated by + discontinuities in the value of sysUpTime." + ::= { ntpAssociationStatisticsEntry 3 } + +-- +-- Section 4: Control objects +-- + +ntpEntHeartbeatInterval OBJECT-TYPE + SYNTAX Unsigned32 + UNITS "seconds" + MAX-ACCESS read-write + STATUS current + DESCRIPTION + "The interval at which the ntpEntNotifHeartbeat notification + should be sent, in seconds. If set to 0 and the + entNotifHeartbeat bit in ntpEntNotifBits is 1, then + ntpEntNotifHeartbeat is sent once. + This value is stored persistently and will be restored to its + last set value upon cold start or restart." + DEFVAL { 60 } + ::= { ntpEntControl 1 } + +ntpEntNotifBits OBJECT-TYPE + SYNTAX BITS { + notUsed(0), -- Used to sync up bit and notification + -- indices + entNotifModeChange(1), + entNotifStratumChange(2), + entNotifSyspeerChanged(3), + entNotifAddAssociation(4), + entNotifRemoveAssociation(5), + entNotifConfigChanged(6), + entNotifLeapSecondAnnounced(7), + entNotifHeartbeat(8) + } + MAX-ACCESS read-write + STATUS current + DESCRIPTION + "A bit for each notification. A 1 for a particular bit enables + that particular notification, a 0 disables it. + This value is stored persistently and will be restored to its + last set value upon cold start or restart." + ::= { ntpEntControl 2 } + +-- +-- Section 5: Notification objects +-- + +ntpEntNotifMessage OBJECT-TYPE + SYNTAX Utf8String + MAX-ACCESS accessible-for-notify + STATUS current + DESCRIPTION + "Used as a payload object for all notifications. Holds a + cleartext event message." + DEFVAL { "no event" } + ::= { ntpEntNotifObjects 1 } + +-- +-- SNMP notification definitions +-- + +ntpEntNotifications OBJECT IDENTIFIER ::= { ntpSnmpMIB 0 } + +ntpEntNotifModeChange NOTIFICATION-TYPE + OBJECTS { ntpEntStatusCurrentMode } + STATUS current + DESCRIPTION + "The notification to be sent when the NTP entity changes mode, + including starting and stopping (if possible)." + ::= { ntpEntNotifications 1 } + +ntpEntNotifStratumChange NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntStatusStratum, + ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when stratum level of NTP changes." + ::= { ntpEntNotifications 2 } + +ntpEntNotifSyspeerChanged NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntStatusActiveRefSourceId, + ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when a (new) syspeer has been + selected." + ::= { ntpEntNotifications 3 } + +ntpEntNotifAddAssociation NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpAssocName, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when a new association is + mobilized." + ::= { ntpEntNotifications 4 } + +ntpEntNotifRemoveAssociation NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpAssocName, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when an association is + demobilized." + ::= { ntpEntNotifications 5 } + +ntpEntNotifConfigChanged NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when the NTP configuration has + changed, e.g., when the system connected to the Internet and + was assigned a new IP address by the ISPs DHCP server." + ::= { ntpEntNotifications 6 } + +ntpEntNotifLeapSecondAnnounced NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent when a leap second has been + announced." + ::= { ntpEntNotifications 7 } + +ntpEntNotifHeartbeat NOTIFICATION-TYPE + OBJECTS { ntpEntStatusDateTime, ntpEntStatusCurrentMode, + ntpEntHeartbeatInterval, ntpEntNotifMessage } + STATUS current + DESCRIPTION + "The notification to be sent periodically (as defined by + ntpEntHeartbeatInterval) to indicate that the NTP entity is + still alive." + ::= { ntpEntNotifications 8 } + +-- +-- Conformance/Compliance statements +-- + +ntpEntConformance OBJECT IDENTIFIER ::= { ntpSnmpMIB 2 } + +ntpEntCompliances OBJECT IDENTIFIER ::= { ntpEntConformance 1 } +ntpEntGroups OBJECT IDENTIFIER ::= { ntpEntConformance 2 } + +ntpEntNTPCompliance MODULE-COMPLIANCE + STATUS current + DESCRIPTION + "The compliance statement for SNMP entities that use NTP and + implement the NTP MIB." + MODULE -- this module + MANDATORY-GROUPS { + ntpEntObjectsGroup1 + } + ::= { ntpEntCompliances 1 } + +ntpEntSNTPCompliance MODULE-COMPLIANCE + STATUS current + DESCRIPTION + "The compliance statement for SNMP entities that use SNTP and + implement the NTP MIB." + MODULE -- this module + MANDATORY-GROUPS { + ntpEntObjectsGroup1 + } + GROUP ntpEntObjectsGroup2 + DESCRIPTION + "Optional object group." + GROUP ntpEntNotifGroup + DESCRIPTION + "Optional notifications for this MIB." + ::= { ntpEntCompliances 2 } + +ntpEntObjectsGroup1 OBJECT-GROUP + OBJECTS { + ntpEntSoftwareName, + ntpEntSoftwareVersion, + ntpEntSoftwareVendor, + ntpEntSystemType, + ntpEntStatusEntityUptime, + ntpEntStatusDateTime, + ntpAssocName, + ntpAssocRefId, + ntpAssocAddressType, + ntpAssocAddress + } + STATUS current + DESCRIPTION + "A collection of objects for the NTP MIB." + ::= { ntpEntGroups 1 } + +ntpEntObjectsGroup2 OBJECT-GROUP + OBJECTS { + ntpEntTimeResolution, + ntpEntTimePrecision, + ntpEntTimeDistance, + ntpEntStatusCurrentMode, + ntpEntStatusStratum, + ntpEntStatusActiveRefSourceId, + ntpEntStatusActiveRefSourceName, + ntpEntStatusActiveOffset, + ntpEntStatusNumberOfRefSources, + ntpEntStatusDispersion, + ntpEntStatusLeapSecond, + ntpEntStatusLeapSecDirection, + ntpEntStatusInPkts, + ntpEntStatusOutPkts, + ntpEntStatusBadVersion, + ntpEntStatusProtocolError, + ntpEntStatusNotifications, + ntpEntStatPktSent, + ntpEntStatPktReceived, + ntpAssocOffset, + ntpAssocStratum, + ntpAssocStatusJitter, + ntpAssocStatusDelay, + ntpAssocStatusDispersion, + ntpAssocStatInPkts, + ntpAssocStatOutPkts, + ntpAssocStatProtocolError, + ntpEntHeartbeatInterval, + ntpEntNotifBits, + ntpEntNotifMessage + } + STATUS current + DESCRIPTION + "A collection of objects for the NTP MIB." + ::= { ntpEntGroups 2 } + +ntpEntNotifGroup NOTIFICATION-GROUP + NOTIFICATIONS { + ntpEntNotifModeChange, + ntpEntNotifStratumChange, + ntpEntNotifSyspeerChanged, + ntpEntNotifAddAssociation, + ntpEntNotifRemoveAssociation, + ntpEntNotifConfigChanged, + ntpEntNotifLeapSecondAnnounced, + ntpEntNotifHeartbeat + } + STATUS current + DESCRIPTION + "A collection of notifications for the NTP MIB" + ::= { ntpEntGroups 3 } + +END diff --git a/contrib/ntp/packageinfo.sh b/contrib/ntp/packageinfo.sh index 702373fd3..1e0a2289d 100644 --- a/contrib/ntp/packageinfo.sh +++ b/contrib/ntp/packageinfo.sh @@ -1,31 +1,107 @@ +# +# packageinfo.sh - set shell variables with version components +# +# This file is sourced by other scripts and does not need execute +# permission or the #! shell selector. +# +# Most changes to this file are fully or semi-automated using the +# UpdatePoint script on the ntp.org tarball build machine. Changes +# required by the typical ntp.org release sequences are below. +# +## DEV: +# +# To bump the -dev point (p) number, UpdatePoint needs no changes here. +# +# To start a -RC cycle in -dev leading to the next -stable release, +# set prerelease=rc. +# +# To move from dev -RC to new -stable and -dev major/minor version, set +# minor and/or major to the new version, repotype to match the new +# minor version, empty prerelease, and set point=NEW. UpdatePoint +# will empty point and rcpoint, and set betapoint=0. +# +## STABLE: +# +# To start a -stable beta cycle, which normally occurs before a -stable +# -RC1 during the runup to a -stable point release, UpdatePoint needs +# no changes here. Both betapoint and point will be incremented, and +# prerelease will be set to beta. +# +# To move on from -stable beta to RC set prerelease=rc. +# +# To fall back from -stable RC to beta set prerelease=beta. +# +# To skip over -stable beta1 directly to -RC1, set prerelease=rc. +# +# To skip all -stable prereleases and move from one primary or point +# release directly to the next point release, set rcpoint=GO. +# +## +# +# To see what UpdatePoint will do without modifying packageinfo.sh as it +# does by default, use the -t/--test option before the repo type: +# +# shell# scripts/build/UpdatePoint -t stable +# + +# repotype must be stable or dev repotype=stable + +# post-4.2.8: +# version=Major.Minor +# 4.2.8 and before: # version=Protocol.Major.Minor # odd minor numbers are for -dev, even minor numbers are for -stable +# UpdatePoint will fail if repotype is inconsistent with minor. proto=4 major=2 -minor=4 -version=${proto}.${major}.${minor} -# Point. 3 cases: -# - Numeric values increment -# - empty 'increments' to 1 -# - NEW 'increments' to empty -point=8 +minor=8 + +case "${proto}.${major}" in + 4.[012]) + version=${proto}.${major}.${minor} + ;; + *) version=${major}.${minor} + ;; +esac + # Special. Normally unused. A suffix. #special=ag special= -# [???] To start an RC cycle: RC->yes -# To release from an RC cycle: rcpoint-> GO -# ReleaseCandidate. 'yes' or 'no'. -#releasecandidate=yes -releasecandidate=no -# ChangeLog tag + +# prerelease can be empty, 'beta', or 'rc'. +prerelease= + +# ChangeLog starting tag (see also CommitLog-4.1.0) CLTAG=NTP_4_2_0 -### -# The following is for ntp-stable. 2 cases: + +### post-4.2.8: +### Point number, after "major.minor.", normally modified by script. +### 4.2.8 and before: +### Point number, after "p", normally modified by script. +# 3 cases: +# - Numeric values increment +# - empty 'increments' to 1 +# - NEW 'increments' to empty +point=4 + +### betapoint is normally modified by script. +# ntp-stable Beta number (betapoint) +# Should be zeroed at release, and left at zero until first beta. +# The first beta is -beta1. +# betapoint is always zero in ntp-dev. +betapoint=0 + +### rcpoint is normally modified by script except for GO. +# RC number (rcpoint) +# for ntp-dev, always empty as RC numbers are not used, nor is GO. +# For ntp-stable: +# if prerelease is 'rc': # - Numeric values increment -# - GO triggers a release (from releasecandidate=yes) -# - - rcpoint gets set to 0 -# - - releasecandidate gets set to no -# - GRONK is for -dev +# - GO triggers a release +# - - rcpoint is emptied +# - - betapoint is set to 0 +# - - prerelease is emptied +# else (not in RC) +# - rcpoint is empty and unused (for now). rcpoint= -#rcpoint=GRONK diff --git a/contrib/ntp/parseutil/Makefile.am b/contrib/ntp/parseutil/Makefile.am index 01f6bd264..99fb3d196 100644 --- a/contrib/ntp/parseutil/Makefile.am +++ b/contrib/ntp/parseutil/Makefile.am @@ -1,13 +1,24 @@ -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL= + +BUILT_SOURCES = +CLEANFILES = noinst_PROGRAMS = @TESTDCF@ @DCFD@ EXTRA_PROGRAMS = testdcf dcfd -INCLUDES = -I$(top_srcdir)/include + +AM_CFLAGS = $(CFLAGS_NTP) + +AM_CPPFLAGS = $(NTP_INCS) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) + ETAGS_ARGS = Makefile.am DISTCLEANFILES = $(EXTRA_PROGRAMS) -#EXTRA_DIST= TAGS check-local: @DCFD@ case "$(noinst_PROGRAMS)" in \ *dcfd*) ./dcfd -Y ;; \ esac + +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/parseutil/Makefile.in b/contrib/ntp/parseutil/Makefile.in index 3f56f677c..a23d6e42b 100644 --- a/contrib/ntp/parseutil/Makefile.in +++ b/contrib/ntp/parseutil/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -16,6 +15,61 @@ @SET_MAKE@ VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -34,84 +88,203 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -ANSI2KNR = ../util/ansi2knr EXTRA_PROGRAMS = testdcf$(EXEEXT) dcfd$(EXEEXT) subdir = parseutil -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = PROGRAMS = $(noinst_PROGRAMS) dcfd_SOURCES = dcfd.c -dcfd_OBJECTS = dcfd$U.$(OBJEXT) +dcfd_OBJECTS = dcfd.$(OBJEXT) dcfd_LDADD = $(LDADD) +am__DEPENDENCIES_1 = +dcfd_DEPENDENCIES = ../libntp/libntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = testdcf_SOURCES = testdcf.c -testdcf_OBJECTS = testdcf$U.$(OBJEXT) +testdcf_OBJECTS = testdcf.$(OBJEXT) testdcf_LDADD = $(LDADD) +testdcf_DEPENDENCIES = ../libntp/libntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/sntp/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = SOURCES = dcfd.c testdcf.c DIST_SOURCES = dcfd.c testdcf.c +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depsver.mf \ + $(top_srcdir)/includes.mf \ + $(top_srcdir)/sntp/libevent/build-aux/depcomp README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -119,8 +292,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -130,15 +306,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -146,23 +383,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -209,18 +482,24 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ - -#AUTOMAKE_OPTIONS = ../util/ansi2knr no-dependencies -AUTOMAKE_OPTIONS = ../util/ansi2knr +NULL = +BUILT_SOURCES = .deps-ver +CLEANFILES = .deps-ver noinst_PROGRAMS = @TESTDCF@ @DCFD@ -INCLUDES = -I$(top_srcdir)/include +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(NTP_INCS) $(CPPFLAGS_NTP) +LDADD = ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) ETAGS_ARGS = Makefile.am DISTCLEANFILES = $(EXTRA_PROGRAMS) -all: all-am +NTP_INCS = -I$(top_srcdir)/include -I$(top_srcdir)/lib/isc/include \ + -I$(top_srcdir)/lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/lib/isc/unix/include +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -232,7 +511,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign parseutil/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign parseutil/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -241,6 +519,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh @@ -259,52 +538,44 @@ clean-noinstPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -dcfd$(EXEEXT): $(dcfd_OBJECTS) $(dcfd_DEPENDENCIES) + +dcfd$(EXEEXT): $(dcfd_OBJECTS) $(dcfd_DEPENDENCIES) $(EXTRA_dcfd_DEPENDENCIES) @rm -f dcfd$(EXEEXT) - $(LINK) $(dcfd_OBJECTS) $(dcfd_LDADD) $(LIBS) -testdcf$(EXEEXT): $(testdcf_OBJECTS) $(testdcf_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(dcfd_OBJECTS) $(dcfd_LDADD) $(LIBS) + +testdcf$(EXEEXT): $(testdcf_OBJECTS) $(testdcf_DEPENDENCIES) $(EXTRA_testdcf_DEPENDENCIES) @rm -f testdcf$(EXEEXT) - $(LINK) $(testdcf_OBJECTS) $(testdcf_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(testdcf_OBJECTS) $(testdcf_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c -../util/ansi2knr: - $(am__cd) ../util && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr - -mostlyclean-kr: - -test "$U" = "" || rm -f *_.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dcfd$U.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testdcf$U.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dcfd.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/testdcf.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< -dcfd_.c: dcfd.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/dcfd.c; then echo $(srcdir)/dcfd.c; else echo dcfd.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -testdcf_.c: testdcf.c $(ANSI2KNR) - $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/testdcf.c; then echo $(srcdir)/testdcf.c; else echo testdcf.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@ -dcfd_.$(OBJEXT) dcfd_.lo testdcf_.$(OBJEXT) testdcf_.lo : $(ANSI2KNR) +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo @@ -312,26 +583,15 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -343,15 +603,11 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -360,6 +616,21 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags @@ -396,10 +667,12 @@ distdir: $(DISTFILES) done check-am: all-am $(MAKE) $(AM_MAKEFLAGS) check-local -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am all-am: Makefile $(PROGRAMS) installdirs: -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -409,13 +682,19 @@ install-am: all-am installcheck: installcheck-am install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -425,6 +704,7 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \ @@ -483,7 +763,7 @@ maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-compile mostlyclean-generic mostlyclean-kr \ +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am @@ -496,11 +776,11 @@ ps-am: uninstall-am: -.MAKE: ../util/ansi2knr check-am install-am install-strip +.MAKE: all check check-am install install-am install-strip -.PHONY: CTAGS GTAGS all all-am check check-am check-local clean \ - clean-generic clean-libtool clean-noinstPROGRAMS ctags \ - distclean distclean-compile distclean-generic \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am check-local clean \ + clean-generic clean-libtool clean-noinstPROGRAMS cscopelist-am \ + ctags ctags-am distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am html \ html-am info info-am install install-am install-data \ install-data-am install-dvi install-dvi-am install-exec \ @@ -509,15 +789,73 @@ uninstall-am: install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-kr mostlyclean-libtool pdf \ - pdf-am ps ps-am tags uninstall uninstall-am + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile -#EXTRA_DIST= TAGS check-local: @DCFD@ case "$(noinst_PROGRAMS)" in \ *dcfd*) ./dcfd -Y ;; \ esac +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/contrib/ntp/parseutil/dcfd.c b/contrib/ntp/parseutil/dcfd.c index c87ab357e..969c1e386 100644 --- a/contrib/ntp/parseutil/dcfd.c +++ b/contrib/ntp/parseutil/dcfd.c @@ -1,6 +1,6 @@ /* * /src/NTP/REPOSITORY/ntp4-dev/parseutil/dcfd.c,v 4.18 2005/10/07 22:08:18 kardel RELEASE_20051008_A - * + * * dcfd.c,v 4.18 2005/10/07 22:08:18 kardel RELEASE_20051008_A * * DCF77 100/200ms pulse synchronisation daemon program (via 50Baud serial line) @@ -13,8 +13,8 @@ * Lacks: * Leap second handling (at that level you should switch to NTP Version 4 - really!) * - * Copyright (c) 1995-2005 by Frank Kardel ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2015 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -185,7 +185,7 @@ static char pat[] = "-\\|/"; #define R_SHIFT(_X_, _Y_) (((_X_) < 0) ? -(-(_X_) >> (_Y_)) : ((_X_) >> (_Y_))) -static struct timeval max_adj_offset = { 0, 128000 }; +static long max_adj_offset_usec = 128000; static long clock_adjust = 0; /* current adjustment value (usec * 2^USECSCALE) */ static long accum_drift = 0; /* accumulated drift value (usec / ADJINTERVAL) */ @@ -195,10 +195,10 @@ static char skip_adjust = 1; /* discard first adjustment (bad samples) */ /* * DCF77 state flags */ -#define DCFB_ANNOUNCE 0x0001 /* switch time zone warning (DST switch) */ -#define DCFB_DST 0x0002 /* DST in effect */ +#define DCFB_ANNOUNCE 0x0001 /* switch time zone warning (DST switch) */ +#define DCFB_DST 0x0002 /* DST in effect */ #define DCFB_LEAP 0x0004 /* LEAP warning (1 hour prior to occurrence) */ -#define DCFB_ALTERNATE 0x0008 /* alternate antenna used */ +#define DCFB_CALLBIT 0x0008 /* "call bit" used to signalize irregularities in the control facilities */ struct clocktime /* clock time broken up from time code */ { @@ -219,9 +219,16 @@ typedef struct clocktime clocktime_t; /* * (usually) quick constant multiplications */ +#ifndef TIMES10 #define TIMES10(_X_) (((_X_) << 3) + ((_X_) << 1)) /* *8 + *2 */ +#endif +#ifndef TIMES24 #define TIMES24(_X_) (((_X_) << 4) + ((_X_) << 3)) /* *16 + *8 */ +#endif +#ifndef TIMES60 #define TIMES60(_X_) ((((_X_) << 4) - (_X_)) << 2) /* *(16 - 1) *4 */ +#endif + /* * generic l_abs() function */ @@ -260,7 +267,8 @@ typedef struct clocktime clocktime_t; * Second Contents * 0 - 10 AM: free, FM: 0 * 11 - 14 free - * 15 R - alternate antenna + * 15 R - "call bit" used to signalize irregularities in the control facilities + * (until 2003 indicated transmission via alternate antenna) * 16 A1 - expect zone change (1 hour before) * 17 - 18 Z1,Z2 - time zone * 0 0 illegal @@ -294,7 +302,7 @@ typedef struct clocktime clocktime_t; * while the length is given as the difference between the start index and * the start index of the following field. */ -static struct rawdcfcode +static struct rawdcfcode { char offset; /* start bit */ } rawdcfcode[] = @@ -361,7 +369,7 @@ static struct dcfparam { unsigned char onebits[60]; unsigned char zerobits[60]; -} dcfparam = +} dcfparam = { "###############RADMLS1248124P124812P1248121241248112481248P", /* 'ONE' representation */ "--------------------s-------p------p----------------------p" /* 'ZERO' representation */ @@ -384,7 +392,7 @@ ext_bf( register int i, first; first = rawdcfcode[idx].offset; - + for (i = rawdcfcode[idx+1].offset - 1; i >= first; i--) { sum <<= 1; @@ -438,7 +446,7 @@ convert_rawdcf( PRINTF("%-30s", "*** INCOMPLETE"); return CVT_NONE; } - + /* * check Start and Parity bits */ @@ -495,7 +503,7 @@ convert_rawdcf( clock_time->flags |= DCFB_LEAP; if (ext_bf(buffer, DCF_R)) - clock_time->flags |= DCFB_ALTERNATE; + clock_time->flags |= DCFB_CALLBIT; return CVT_OK; } @@ -587,7 +595,8 @@ cvt_rawdcf( /* * invalid character (no consecutive bit sequence) */ - dprintf(("parse: cvt_rawdcf: character check for 0x%x@%d FAILED\n", *s, s - buffer)); + dprintf(("parse: cvt_rawdcf: character check for 0x%x@%ld FAILED\n", + (u_int)*s, (long)(s - buffer))); *s = (unsigned char)~0; rtc = CVT_FAIL|CVT_BADFMT; } @@ -738,7 +747,7 @@ cvt_rawdcf( * if everything went well so far return the result of the symbolic * conversion routine else just the accumulated errors */ - if (rtc != CVT_NONE) + if (rtc != CVT_NONE) { PRINTF("%-30s", "*** BAD DATA"); } @@ -757,13 +766,13 @@ dcf_to_unixtime( ) { #define SETRTC(_X_) { if (cvtrtc) *cvtrtc = (_X_); } - static int days_of_month[] = + static int days_of_month[] = { 0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }; register int i; time_t t; - + /* * map 2 digit years to 19xx (DCF77 is a 20th century item) */ @@ -846,7 +855,7 @@ dcf_to_unixtime( */ t = TIMES60(t) + clock_time->minute; /* sec */ - + /* * calculate UTC in minutes */ @@ -898,15 +907,19 @@ static const char *wday[8] = */ static char * pr_timeval( - struct timeval *val - ) + struct timeval *val + ) { static char buf[20]; if (val->tv_sec == 0) - sprintf(buf, "%c0.%06ld", (val->tv_usec < 0) ? '-' : '+', (long int)l_abs(val->tv_usec)); + snprintf(buf, sizeof(buf), "%c0.%06ld", + (val->tv_usec < 0) ? '-' : '+', + (long int)l_abs(val->tv_usec)); else - sprintf(buf, "%ld.%06ld", (long int)val->tv_sec, (long int)l_abs(val->tv_usec)); + snprintf(buf, sizeof(buf), "%ld.%06ld", + (long int)val->tv_sec, + (long int)l_abs(val->tv_usec)); return buf; } @@ -1042,7 +1055,8 @@ adjust_clock( toffset = *offset; toffset.tv_sec = l_abs(toffset.tv_sec); toffset.tv_usec = l_abs(toffset.tv_usec); - if (timercmp(&toffset, &max_adj_offset, >)) + if (toffset.tv_sec || + (!toffset.tv_sec && toffset.tv_usec > max_adj_offset_usec)) { /* * hopeless - set the clock - and clear the timing @@ -1241,7 +1255,7 @@ usage( */ static int check_y2k( void ) -{ +{ int year; /* current working year */ int year0 = 1900; /* sarting year for NTP time */ int yearend; /* ending year we test for NTP time. @@ -1300,7 +1314,7 @@ check_y2k( void ) * *a minor difference to arg2 type */ if ( ct.year != year ) { - fprintf( stdout, + fprintf( stdout, "%04d: dcf_to_unixtime(,%d) CORRUPTED ct.year: was %d\n", (int)year, (int)Flag, (int)ct.year ); Error(year); @@ -1310,52 +1324,15 @@ check_y2k( void ) Expected = t * 24 * 60 * 60; if ( Observed != Expected || Flag ) { /* time difference */ - fprintf( stdout, + fprintf( stdout, "%04d: dcf_to_unixtime(,%d) FAILURE: was=%lu s/b=%lu (%ld)\n", - year, (int)Flag, + year, (int)Flag, (unsigned long)Observed, (unsigned long)Expected, ((long)Observed - (long)Expected) ); Error(year); break; } - if ( year >= YEAR_PIVOT+1900 ) - { - /* check year % 100 code we put into dcf_to_unixtime() */ - ct.year = year % 100; - Flag = 0; - - Observed = dcf_to_unixtime( &ct, &Flag ); - - if ( Observed != Expected || Flag ) - { /* time difference */ - fprintf( stdout, -"%04d: dcf_to_unixtime(%d,%d) FAILURE: was=%lu s/b=%lu (%ld)\n", - year, (int)ct.year, (int)Flag, - (unsigned long)Observed, (unsigned long)Expected, - ((long)Observed - (long)Expected) ); - Error(year); - break; - } - - /* check year - 1900 code we put into dcf_to_unixtime() */ - ct.year = year - 1900; - Flag = 0; - - Observed = dcf_to_unixtime( &ct, &Flag ); - - if ( Observed != Expected || Flag ) { /* time difference */ - fprintf( stdout, - "%04d: dcf_to_unixtime(%d,%d) FAILURE: was=%lu s/b=%lu (%ld)\n", - year, (int)ct.year, (int)Flag, - (unsigned long)Observed, (unsigned long)Expected, - ((long)Observed - (long)Expected) ); - Error(year); - break; - } - - - } } return ( Fatals ); @@ -1375,7 +1352,7 @@ rawdcf_init( * Here a voltage between the DTR and the RTS line is used. Unfortunately * the name has changed from CIOCM_DTR to TIOCM_DTR recently. */ - + #ifdef TIOCM_DTR int sl232 = TIOCM_DTR; /* turn on DTR for power supply */ #else @@ -1469,7 +1446,7 @@ main( errs=1; } break; - + case 'd': if (ac > 1) { @@ -1482,8 +1459,8 @@ main( errs=1; } break; - - case 'Y': + + case 'Y': errs=check_y2k(); exit( errs ? 1 : 0 ); @@ -1550,7 +1527,7 @@ main( unsigned int rtc = CVT_NONE; rawdcf_init(fd); - + timeout.tv_sec = 1; timeout.tv_usec = 500000; @@ -1591,7 +1568,7 @@ main( */ if (!interactive) detach(); - + /* * get syslog() initialized */ @@ -1609,7 +1586,7 @@ main( struct sigaction act; # ifdef HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION - act.sa_sigaction = (void (*) P((int, siginfo_t *, void *)))0; + act.sa_sigaction = (void (*) (int, siginfo_t *, void *))0; # endif /* HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION */ act.sa_handler = tick; sigemptyset(&act.sa_mask); @@ -1649,7 +1626,7 @@ main( it.it_interval.tv_usec = 0; it.it_value.tv_sec = 1< ntp.org> - * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universität Erlangen-Nürnberg, Germany + * Copyright (c) 1995-2015 by Frank Kardel ntp.org> + * Copyright (c) 1989-1994 by Frank Kardel, Friedrich-Alexander Universitaet Erlangen-Nuernberg, Germany * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -34,6 +34,7 @@ * */ +#include #include "ntp_stdlib.h" #include @@ -45,10 +46,10 @@ /* * state flags */ -#define DCFB_ANNOUNCE 0x0001 /* switch time zone warning (DST switch) */ -#define DCFB_DST 0x0002 /* DST in effect */ -#define DCFB_LEAP 0x0004 /* LEAP warning (1 hour prior to occurrence) */ -#define DCFB_ALTERNATE 0x0008 /* alternate antenna used */ +#define DCFB_ANNOUNCE 0x0001 /* switch time zone warning (DST switch) */ +#define DCFB_DST 0x0002 /* DST in effect */ +#define DCFB_LEAP 0x0004 /* LEAP warning (1 hour prior to occurrence) */ +#define DCFB_CALLBIT 0x0008 /* "call bit" used to signalize irregularities in the control facilities */ struct clocktime /* clock time broken up from time code */ { @@ -101,7 +102,8 @@ static char type(unsigned int); * Second Contents * 0 - 10 AM: free, FM: 0 * 11 - 14 free - * 15 R - alternate antenna + * 15 R - "call bit" used to signalize irregularities in the control facilities + * (until 2003 indicated transmission via alternate antenna) * 16 A1 - expect zone change (1 hour before) * 17 - 18 Z1,Z2 - time zone * 0 0 illegal @@ -129,7 +131,7 @@ static char type(unsigned int); static char revision[] = "4.10"; -static struct rawdcfcode +static struct rawdcfcode { char offset; /* start bit */ } rawdcfcode[] = @@ -184,7 +186,7 @@ ext_bf( register int i, first; first = rawdcfcode[idx].offset; - + for (i = rawdcfcode[idx+1].offset - 1; i >= first; i--) { sum <<= 1; @@ -222,7 +224,7 @@ convert_rawdcf( printf("%-30s", "*** INCOMPLETE"); return CVT_NONE; } - + /* * check Start and Parity bits */ @@ -273,7 +275,7 @@ convert_rawdcf( clock_time->flags |= DCFB_LEAP; if (ext_bf(buffer, DCF_R)) - clock_time->flags |= DCFB_ALTERNATE; + clock_time->flags |= DCFB_CALLBIT; return CVT_OK; } @@ -489,7 +491,7 @@ main( wday[clock_time.wday], (int)clock_time.hour, (int)clock_time.minute, (int)i, (int)clock_time.day, (int)clock_time.month, (int)clock_time.year, - (clock_time.flags & DCFB_ALTERNATE) ? "R" : "_", + (clock_time.flags & DCFB_CALLBIT) ? "R" : "_", (clock_time.flags & DCFB_ANNOUNCE) ? "A" : "_", (clock_time.flags & DCFB_DST) ? "D" : "_", (clock_time.flags & DCFB_LEAP) ? "L" : "_" diff --git a/contrib/ntp/readme.y2kfixes b/contrib/ntp/readme.y2kfixes index e9a63c1e81c93dc443ab93be5ca73117277605ec..4518770fda888d0752acc54936858e71c8d4b4a8 100644 GIT binary patch delta 7 OcmZp0=u+FjB@6%xhyp$U literal 8192 zcmeHL-)|eo5$-QUJ)(`NHEo=iZ#TUo)iiZyoc5I|DymeVY^}AWBDvNjtq&ye z-KupUJa3ebVhR8;#u(e%rOy#Dg3^L5f;&Mc}~eS}SC}#Yrxrg^!)ozOyDLn|6(= zaV5l=0XnG02zk(CP|%M}siF>}OLA6IE1!;m?>Wm;2!*r3l-k3jrO|*ET)VzXZP4V} z$S<-(K7Bc`fq)sY#G6B(gq$8Gg4YV?J$P}6ED?pW2MTTznfjN=xu{!|Vhb=DWqem_ zTM}}K;ga^IuBp;>Lk~ zK~~_KDk9`dgrS|*Xil6pzN2{}#O-`KyIam^wV;p7SqdOE12-{{g$HziwkV0z1LP5i zR4ghmmUS+%Ue2l~WoiZR`nKsvzHZTsTydrrC&Qf$-gl4pdQHJZEjG9zQ=p{@(HoqF zY63TuuW-%5n{5St*2=I(SoE9x!xT8M+XMtq3IK*xmx@Z+ErQ)CP#!YK2^`zH)XB7i zUBjX!=TD9*S4&5EEisFC!KAgxZi%Sa$j_j$21Swq$Q@V)Aes&-Nq?cHBLEJLp5#-KjqduS*keQlvybbt=vnC+?-dlRHHA z1l@T#jB<&NXnHK}w{PFR6-nx3i{s_)6{Q=o0E3!ggu;tN4C~M}3qp*lh~0Un&daR2 zxz|UyYtb~1S~p@3#tm>7Xl=5_sue3}rv#I{4yEoy8V(o^g`_&k*FZcmV&)r;P@^Dd z-BV*9NjMNRjMZL?xO;d=;RtsLM1Ei-O&txE9|$~iI}>4BcxeUUBLX`yoNdMqktTSC<2hu9) z(g`qTp2seONgzXlSPlvv;dn{xbi?Ji5}gK6!y{PJ>kmxXe{2Tt}P^yrt z7;`Wx@mH2ERhAeNvV0vK;tT8p9qx=%bPW&hi12Kg7%c4EsYfUc!vmI@C`9EBRW@K7 z5#pqnB!1BVVAr|i-Gf(1e8Zy3=XhE(^+UVf8Au9-SL)`|gcT7D6;Beha@WKRBN!p{ z>X`xhp!>yfPvk}&I7G%-l~2lI;lW#jy+`~;S$rCZ5O~wAUg=ZF^ZbS4BsoZ851wo> z#+jv(Lkdm&C*hZ!NW_#O-C#|K)Oi{B4Q{6~%VbchD8~gQKoij5pS4f_{>q(Y_ZaU) ztl(GlI)C-u8_Mon&U*Zic9W z1ck?};k_e654CmVl5seFG|J=-p=oSNW8nBtfn7k%Tbnf;x4*f zVy&qiwhj=1MzW6JCIdcL832p{3LX_!LxZsj-IHpgzNya>#biv?Sgz`ROa<3^XjP97 z?hM90VKv9Oufz*oHS|6GDepEQO6aFYa*IBZ4c8C^$P0CUbygUn)@)EUu4cbpNM*p@ z-`A4Qc_Ygv@7~S1btkvPU_N}D@~0(I$iBUx*>m(c|6$!@8Z!>@5qWAu>9_<{=AMEh>Uci&ymyxZ2LgdqCKR_Evlp2rG4QLq&kS*B2Nm`_50EU&FQleYAlFUJ32xuy3tR&5mq-X&&bOj9Y$di4WnT$U}0_ zd-Szj1rI%9c>m1>EqJW4fOU6-9??trk{2rO8@7s@IPRo1g~FQ#mmf>dd@I@L$R_J{kZ3 diff --git a/contrib/ntp/scripts/Makefile.am b/contrib/ntp/scripts/Makefile.am index 76d765505..2664bef4d 100644 --- a/contrib/ntp/scripts/Makefile.am +++ b/contrib/ntp/scripts/Makefile.am @@ -1,5 +1,175 @@ -bin_SCRIPTS= ntp-wait ntptrace -noinst_SCRIPTS= calc_tickadj checktime freq_adj html2man mkver ntpsweep ntpver plot_summary summary -EXTRA_DIST = VersionName fixautomakedepsmagic genCommitLog genver \ - hpadjtime.sh monitoring ntp-close ntp-groper ntp-restart \ - ntp-status rc1 rc2 stats +NULL= +SUBDIRS= \ + build \ + calc_tickadj \ + ntp-wait \ + ntpsweep \ + ntptrace \ + lib \ + update-leap \ + $(NULL) + +man1_MANS= +man8_MANS= + +DISTCLEANFILES= config.log $(man_MANS) + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +noinst_SCRIPTS = \ + ntpver \ + plot_summary \ + summary \ + $(NULL) + +install-data-local: install-html + +EXTRA_DIST = \ + deprecated \ + monitoring \ + invoke-plot_summary.texi \ + invoke-plot_summary.menu \ + plot_summary.1plot_summaryman \ + plot_summary.1plot_summarymdoc \ + plot_summary.mdoc.in \ + plot_summary.man.in \ + plot_summary.texi \ + plot_summary.html \ + plot_summary-opts \ + plot_summary-opts.def \ + rc \ + invoke-summary.texi \ + invoke-summary.menu \ + summary.1summaryman \ + summary.1summarymdoc \ + summary.mdoc.in \ + summary.man.in \ + summary.texi \ + summary.html \ + summary-opts \ + summary-opts.def \ + stats \ + $(NULL) + +noinst_DATA = \ + invoke-plot_summary.texi \ + invoke-plot_summary.menu \ + plot_summary.1plot_summaryman \ + plot_summary.1plot_summarymdoc \ + plot_summary.mdoc.in \ + plot_summary.man.in \ + plot_summary.texi \ + plot_summary.html \ + invoke-summary.texi \ + invoke-summary.menu \ + summary.1summaryman \ + summary.1summarymdoc \ + summary.mdoc.in \ + summary.man.in \ + summary.texi \ + summary.html \ + $(NULL) + +#OPTTPL = ../sntp/ag-tpl/perlopt.tpl +OPTTPL = $(std_def_list) + +## + +plot_summary: $(srcdir)/plot_summary-opts + +$(srcdir)/plot_summary-opts: plot_summary-opts.def $(OPTTPL) + $(run_ag) plot_summary-opts.def + +### Nroff + +$(srcdir)/plot_summary.1plot_summaryman: $(srcdir)/plot_summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1plot_summaryman -Tagman-cmd.tpl plot_summary-opts.def + +$(srcdir)/plot_summary.man.in: $(srcdir)/plot_summary.1plot_summaryman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/plot_summary.1plot_summaryman > $(srcdir)/plot_summary.man.in+ + mv $(srcdir)/plot_summary.man.in+ $(srcdir)/plot_summary.man.in + +### Mdoc + +$(srcdir)/plot_summary.1plot_summarymdoc: $(srcdir)/plot_summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1plot_summarymdoc -Tagmdoc-cmd.tpl plot_summary-opts.def + +$(srcdir)/plot_summary.mdoc.in: $(srcdir)/plot_summary.1plot_summarymdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/plot_summary.1plot_summarymdoc > $(srcdir)/plot_summary.mdoc.in+ + mv $(srcdir)/plot_summary.mdoc.in+ $(srcdir)/plot_summary.mdoc.in + +### Manpage (local) + +plot_summary.1: $(srcdir)/plot_summary.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=plot_summary.1+:$(srcdir)/plot_summary.$(MANTAGFMT).in + mv plot_summary.1+ plot_summary.1 + +### Texinfo + +$(srcdir)/invoke-plot_summary.menu: $(srcdir)/invoke-plot_summary.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-plot_summary.texi: plot_summary-opts $(srcdir)/plot_summary-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section plot_summary-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/plot_summary.html: $(srcdir)/invoke-plot_summary.menu $(srcdir)/invoke-plot_summary.texi $(srcdir)/plot_summary.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o plot_summary.html plot_summary.texi || true ) + + +## + +summary: $(srcdir)/summary-opts + +$(srcdir)/summary-opts: summary-opts.def $(OPTTPL) + $(run_ag) summary-opts.def + +### Nroff + +$(srcdir)/summary.1summaryman: $(srcdir)/summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1summaryman -Tagman-cmd.tpl summary-opts.def + +$(srcdir)/summary.man.in: $(srcdir)/summary.1summaryman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/summary.1summaryman > $(srcdir)/summary.man.in+ + mv $(srcdir)/summary.man.in+ $(srcdir)/summary.man.in + +### Mdoc + +$(srcdir)/summary.1summarymdoc: $(srcdir)/summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1summarymdoc -Tagmdoc-cmd.tpl summary-opts.def + +$(srcdir)/summary.mdoc.in: $(srcdir)/summary.1summarymdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/summary.1summarymdoc > $(srcdir)/summary.mdoc.in+ + mv $(srcdir)/summary.mdoc.in+ $(srcdir)/summary.mdoc.in + +### Manpage (local) + +summary.1: $(srcdir)/summary.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=summary.1+:$(srcdir)/summary.$(MANTAGFMT).in + mv summary.1+ summary.1 + +### Texinfo + +$(srcdir)/invoke-summary.menu: $(srcdir)/invoke-summary.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-summary.texi: summary-opts $(srcdir)/summary-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section summary-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/summary.html: $(srcdir)/invoke-summary.menu $(srcdir)/invoke-summary.texi $(srcdir)/summary.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o summary.html summary.texi || true ) + diff --git a/contrib/ntp/scripts/Makefile.in b/contrib/ntp/scripts/Makefile.in index 8577e771b..447a1b30c 100644 --- a/contrib/ntp/scripts/Makefile.in +++ b/contrib/ntp/scripts/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -15,7 +14,63 @@ @SET_MAKE@ + VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -35,25 +90,80 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = scripts -DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(srcdir)/calc_tickadj.in $(srcdir)/checktime.in \ - $(srcdir)/freq_adj.in $(srcdir)/html2man.in $(srcdir)/mkver.in \ - $(srcdir)/ntp-wait.in $(srcdir)/ntpsweep.in \ - $(srcdir)/ntptrace.in $(srcdir)/ntpver.in \ - $(srcdir)/plot_summary.in $(srcdir)/summary.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ - $(top_srcdir)/m4/define_dir.m4 \ - $(top_srcdir)/m4/hs_ulong_const.m4 \ - $(top_srcdir)/m4/os_cflags.m4 $(top_srcdir)/version.m4 \ - $(top_srcdir)/configure.ac +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = calc_tickadj checktime freq_adj html2man mkver \ - ntp-wait ntpsweep ntptrace ntpver plot_summary summary +CONFIG_CLEAN_FILES = ntpver plot_summary summary CONFIG_CLEAN_VPATH_FILES = +SCRIPTS = $(noinst_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -75,48 +185,143 @@ am__nobase_list = $(am__nobase_strip_setup); \ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__installdirs = "$(DESTDIR)$(bindir)" -SCRIPTS = $(bin_SCRIPTS) $(noinst_SCRIPTS) -SOURCES = -DIST_SOURCES = +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +man1dir = $(mandir)/man1 +am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" +man8dir = $(mandir)/man8 +NROFF = nroff +MANS = $(man1_MANS) $(man8_MANS) +DATA = $(noinst_DATA) +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/ntpver.in \ + $(srcdir)/plot_summary.in $(srcdir)/summary.in README DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -ARLIB_DIR = @ARLIB_DIR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CHUTEST = @CHUTEST@ -CLKTEST = @CLKTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DCFD = @DCFD@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ -EF_LIBS = @EF_LIBS@ -EF_PROGS = @EF_PROGS@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCRYPTO = @LCRYPTO@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ @@ -124,8 +329,11 @@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBPARSE = @LIBPARSE@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ LN_S = @LN_S@ LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MAKE_ADJTIMED = @MAKE_ADJTIMED@ @@ -135,15 +343,76 @@ MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ MAKE_LIBPARSE = @MAKE_LIBPARSE@ MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ MAKE_NTPTIME = @MAKE_NTPTIME@ MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ MAKE_TICKADJ = @MAKE_TICKADJ@ MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OPENSSL = @OPENSSL@ -OPENSSL_INC = @OPENSSL_INC@ -OPENSSL_LIB = @OPENSSL_LIB@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -151,23 +420,59 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ -PATH_SH = @PATH_SH@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ -READLINE_LIBS = @READLINE_LIBS@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ TESTDCF = @TESTDCF@ -U = @U@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -214,13 +519,88 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -bin_SCRIPTS = ntp-wait ntptrace -noinst_SCRIPTS = calc_tickadj checktime freq_adj html2man mkver ntpsweep ntpver plot_summary summary -EXTRA_DIST = VersionName fixautomakedepsmagic genCommitLog genver \ - hpadjtime.sh monitoring ntp-close ntp-groper ntp-restart \ - ntp-status rc1 rc2 stats +NULL = +SUBDIRS = \ + build \ + calc_tickadj \ + ntp-wait \ + ntpsweep \ + ntptrace \ + lib \ + update-leap \ + $(NULL) + +man1_MANS = +man8_MANS = +DISTCLEANFILES = config.log $(man_MANS) +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +noinst_SCRIPTS = \ + ntpver \ + plot_summary \ + summary \ + $(NULL) + +EXTRA_DIST = \ + deprecated \ + monitoring \ + invoke-plot_summary.texi \ + invoke-plot_summary.menu \ + plot_summary.1plot_summaryman \ + plot_summary.1plot_summarymdoc \ + plot_summary.mdoc.in \ + plot_summary.man.in \ + plot_summary.texi \ + plot_summary.html \ + plot_summary-opts \ + plot_summary-opts.def \ + rc \ + invoke-summary.texi \ + invoke-summary.menu \ + summary.1summaryman \ + summary.1summarymdoc \ + summary.mdoc.in \ + summary.man.in \ + summary.texi \ + summary.html \ + summary-opts \ + summary-opts.def \ + stats \ + $(NULL) + +noinst_DATA = \ + invoke-plot_summary.texi \ + invoke-plot_summary.menu \ + plot_summary.1plot_summaryman \ + plot_summary.1plot_summarymdoc \ + plot_summary.mdoc.in \ + plot_summary.man.in \ + plot_summary.texi \ + plot_summary.html \ + invoke-summary.texi \ + invoke-summary.menu \ + summary.1summaryman \ + summary.1summarymdoc \ + summary.mdoc.in \ + summary.man.in \ + summary.texi \ + summary.html \ + $(NULL) -all: all-am + +#OPTTPL = ../sntp/ag-tpl/perlopt.tpl +OPTTPL = $(std_def_list) +all: all-recursive .SUFFIXES: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @@ -235,7 +615,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign scripts/Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -253,74 +632,199 @@ $(top_srcdir)/configure: $(am__configure_deps) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): -calc_tickadj: $(top_builddir)/config.status $(srcdir)/calc_tickadj.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -checktime: $(top_builddir)/config.status $(srcdir)/checktime.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -freq_adj: $(top_builddir)/config.status $(srcdir)/freq_adj.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -html2man: $(top_builddir)/config.status $(srcdir)/html2man.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -mkver: $(top_builddir)/config.status $(srcdir)/mkver.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -ntp-wait: $(top_builddir)/config.status $(srcdir)/ntp-wait.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -ntpsweep: $(top_builddir)/config.status $(srcdir)/ntpsweep.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -ntptrace: $(top_builddir)/config.status $(srcdir)/ntptrace.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ ntpver: $(top_builddir)/config.status $(srcdir)/ntpver.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ plot_summary: $(top_builddir)/config.status $(srcdir)/plot_summary.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ summary: $(top_builddir)/config.status $(srcdir)/summary.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ -install-binSCRIPTS: $(bin_SCRIPTS) - @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" - @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ - for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ - done | \ - sed -e 'p;s,.*/,,;n' \ - -e 'h;s|.*|.|' \ - -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ - $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ - { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ - if ($$2 == $$4) { files[d] = files[d] " " $$1; \ - if (++n[d] == $(am__install_max)) { \ - print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ - else { print "f", d "/" $$4, $$1 } } \ - END { for (d in files) print "f", d, files[d] }' | \ - while read type dir files; do \ - if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ - test -z "$$files" || { \ - echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ - $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ - } \ - ; done - -uninstall-binSCRIPTS: - @$(NORMAL_UNINSTALL) - @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ - files=`for p in $$list; do echo "$$p"; done | \ - sed -e 's,.*/,,;$(transform)'`; \ - test -n "$$list" || exit 0; \ - echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(bindir)" && rm -f $$files mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs -tags: TAGS -TAGS: +install-man1: $(man1_MANS) + @$(NORMAL_INSTALL) + @list1='$(man1_MANS)'; \ + list2=''; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2=''; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive -ctags: CTAGS -CTAGS: +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ @@ -352,27 +856,58 @@ distdir: $(DISTFILES) || exit 1; \ fi; \ done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done check-am: all-am -check: check-am -all-am: Makefile $(SCRIPTS) -installdirs: - for dir in "$(DESTDIR)$(bindir)"; do \ +check: check-recursive +all-am: Makefile $(SCRIPTS) $(MANS) $(DATA) +installdirs: installdirs-recursive +installdirs-am: + for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am -installcheck: installcheck-am +installcheck: installcheck-recursive install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: @@ -380,90 +915,186 @@ clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." -clean: clean-am +clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am -distclean: distclean-am +distclean: distclean-recursive -rm -f Makefile -distclean-am: clean-am distclean-generic +distclean-am: clean-am distclean-generic distclean-tags -dvi: dvi-am +dvi: dvi-recursive dvi-am: -html: html-am +html: html-recursive html-am: -info: info-am +info: info-recursive info-am: -install-data-am: +install-data-am: install-data-local install-man -install-dvi: install-dvi-am +install-dvi: install-dvi-recursive install-dvi-am: -install-exec-am: install-binSCRIPTS +install-exec-am: -install-html: install-html-am +install-html: install-html-recursive install-html-am: -install-info: install-info-am +install-info: install-info-recursive install-info-am: -install-man: +install-man: install-man1 install-man8 -install-pdf: install-pdf-am +install-pdf: install-pdf-recursive install-pdf-am: -install-ps: install-ps-am +install-ps: install-ps-recursive install-ps-am: installcheck-am: -maintainer-clean: maintainer-clean-am +maintainer-clean: maintainer-clean-recursive -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic -mostlyclean: mostlyclean-am +mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic mostlyclean-libtool -pdf: pdf-am +pdf: pdf-recursive pdf-am: -ps: ps-am +ps: ps-recursive ps-am: -uninstall-am: uninstall-binSCRIPTS +uninstall-am: uninstall-man + +uninstall-man: uninstall-man1 uninstall-man8 -.MAKE: install-am install-strip +.MAKE: $(am__recursive_targets) install-am install-strip -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - distclean distclean-generic distclean-libtool distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-binSCRIPTS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am \ + install-data-local install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-man1 install-man8 \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - uninstall uninstall-am uninstall-binSCRIPTS + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am uninstall-man \ + uninstall-man1 uninstall-man8 + +.PRECIOUS: Makefile + + +install-data-local: install-html + +plot_summary: $(srcdir)/plot_summary-opts + +$(srcdir)/plot_summary-opts: plot_summary-opts.def $(OPTTPL) + $(run_ag) plot_summary-opts.def + +### Nroff + +$(srcdir)/plot_summary.1plot_summaryman: $(srcdir)/plot_summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1plot_summaryman -Tagman-cmd.tpl plot_summary-opts.def + +$(srcdir)/plot_summary.man.in: $(srcdir)/plot_summary.1plot_summaryman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/plot_summary.1plot_summaryman > $(srcdir)/plot_summary.man.in+ + mv $(srcdir)/plot_summary.man.in+ $(srcdir)/plot_summary.man.in + +### Mdoc + +$(srcdir)/plot_summary.1plot_summarymdoc: $(srcdir)/plot_summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1plot_summarymdoc -Tagmdoc-cmd.tpl plot_summary-opts.def + +$(srcdir)/plot_summary.mdoc.in: $(srcdir)/plot_summary.1plot_summarymdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/plot_summary.1plot_summarymdoc > $(srcdir)/plot_summary.mdoc.in+ + mv $(srcdir)/plot_summary.mdoc.in+ $(srcdir)/plot_summary.mdoc.in + +### Manpage (local) + +plot_summary.1: $(srcdir)/plot_summary.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=plot_summary.1+:$(srcdir)/plot_summary.$(MANTAGFMT).in + mv plot_summary.1+ plot_summary.1 + +### Texinfo + +$(srcdir)/invoke-plot_summary.menu: $(srcdir)/invoke-plot_summary.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-plot_summary.texi: plot_summary-opts $(srcdir)/plot_summary-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section plot_summary-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/plot_summary.html: $(srcdir)/invoke-plot_summary.menu $(srcdir)/invoke-plot_summary.texi $(srcdir)/plot_summary.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o plot_summary.html plot_summary.texi || true ) + +summary: $(srcdir)/summary-opts + +$(srcdir)/summary-opts: summary-opts.def $(OPTTPL) + $(run_ag) summary-opts.def + +### Nroff + +$(srcdir)/summary.1summaryman: $(srcdir)/summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1summaryman -Tagman-cmd.tpl summary-opts.def + +$(srcdir)/summary.man.in: $(srcdir)/summary.1summaryman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/summary.1summaryman > $(srcdir)/summary.man.in+ + mv $(srcdir)/summary.man.in+ $(srcdir)/summary.man.in + +### Mdoc + +$(srcdir)/summary.1summarymdoc: $(srcdir)/summary-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1summarymdoc -Tagmdoc-cmd.tpl summary-opts.def + +$(srcdir)/summary.mdoc.in: $(srcdir)/summary.1summarymdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/summary.1summarymdoc > $(srcdir)/summary.mdoc.in+ + mv $(srcdir)/summary.mdoc.in+ $(srcdir)/summary.mdoc.in + +### Manpage (local) + +summary.1: $(srcdir)/summary.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=summary.1+:$(srcdir)/summary.$(MANTAGFMT).in + mv summary.1+ summary.1 + +### Texinfo + +$(srcdir)/invoke-summary.menu: $(srcdir)/invoke-summary.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-summary.texi: summary-opts $(srcdir)/summary-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section summary-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML +$(srcdir)/summary.html: $(srcdir)/invoke-summary.menu $(srcdir)/invoke-summary.texi $(srcdir)/summary.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o summary.html summary.texi || true ) # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. diff --git a/contrib/ntp/scripts/README b/contrib/ntp/scripts/README index 673ddb449..9f70a6362 100644 --- a/contrib/ntp/scripts/README +++ b/contrib/ntp/scripts/README @@ -6,38 +6,26 @@ files in the parent directory for directions on how to use these files. calc_tickadj Calculates "optimal" value for tick given ntp.drift file -freq_adj Calculates and optionally sets the clock frequency - based on ntp.drift . For FreeBSD systems. - -mkver.in script to create new version numbers for all sources - monitoring directory containing perl scripts useful for monitoring operations -rc1 start/stop scripts for NTP - -rc2 start/stop script for NTP - -ntp-close find public stratum 2 servers that don't respond - -ntp-groper script useful for reaching out and rattling the cages of - NTP peers to see if animals are inside the bars - -ntp-restart script useful for killing and restarting the NTP daemon +rc start/stop scripts for NTP ntp-wait Blocks until ntpd is in state 4 (synchronized). - Hopefully useful at boot time, to delay the boot sequence + Useful at boot time, to delay the boot sequence until after "ntpd -g" has set the time. ntpsweep prints per host given in the NTP stratum level, the clock offset in seconds, the daemon version, the operating system and the processor. -ntpver What version of the NTP daemon is running? +ntptrace Trace ntp peers of a server up to stratum 1. stats directory containing awk and shell scripts useful for maintaining statistics summaries of clockstats, loopstats and peerstats files -support directory containing shell and perl scripts useful for - configuration and monitoring of NTP subnets +summary Generate summary files out of stat files produced by NTP + daemon. + +plot_summary Plot summaries generated by summary script. diff --git a/contrib/ntp/scripts/VersionName b/contrib/ntp/scripts/VersionName deleted file mode 100755 index f601cc348..000000000 --- a/contrib/ntp/scripts/VersionName +++ /dev/null @@ -1,41 +0,0 @@ -#! /bin/sh - -# This script must be executed from the TLD of the source tree... -. ./packageinfo.sh - -NAME="$version" -case $point in - [0-9]*) - NAME="${NAME}p$point" - ;; - NEW) ;; - '') ;; - *) echo "Unexpected value for 'point' <$point>!" - exit 1 - ;; -esac - -case $special in - '') ;; - *) NAME="${NAME}-$special" ;; -esac - -case $releasecandidate in - [Nn][Oo]) ;; - [Yy][Ee][Ss]) NAME="${NAME}-RC" ;; - *) echo "Unexpected value for 'releasecandidate' <$releasecandidate>!" - exit 1 - ;; -esac - -case $repotype in - stable) - case $rcpoint in - [0-9]*) - NAME="${NAME}$rcpoint" - ;; - esac - ;; -esac - -echo "$NAME" diff --git a/contrib/ntp/scripts/build/Makefile.am b/contrib/ntp/scripts/build/Makefile.am new file mode 100644 index 000000000..51a1bbccf --- /dev/null +++ b/contrib/ntp/scripts/build/Makefile.am @@ -0,0 +1,17 @@ +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl + +noinst_SCRIPTS = mkver + +NULL= +EXTRA_DIST = \ + check--help \ + checkChangeLog \ + checkHtmlFileDates \ + fixautomakedepsmagic \ + genCommitLog \ + genver \ + updateBEDate \ + UpdatePoint \ + VersionName \ + $(NULL) diff --git a/contrib/ntp/scripts/build/Makefile.in b/contrib/ntp/scripts/build/Makefile.in new file mode 100644 index 000000000..d758d613f --- /dev/null +++ b/contrib/ntp/scripts/build/Makefile.in @@ -0,0 +1,640 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = scripts/build +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = mkver +CONFIG_CLEAN_VPATH_FILES = +SCRIPTS = $(noinst_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/mkver.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../sntp/include -L ../sntp/ag-tpl + +noinst_SCRIPTS = mkver +NULL = +EXTRA_DIST = \ + check--help \ + checkChangeLog \ + checkHtmlFileDates \ + fixautomakedepsmagic \ + genCommitLog \ + genver \ + updateBEDate \ + UpdatePoint \ + VersionName \ + $(NULL) + +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/build/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign scripts/build/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +mkver: $(top_builddir)/config.status $(srcdir)/mkver.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(SCRIPTS) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/scripts/build/UpdatePoint b/contrib/ntp/scripts/build/UpdatePoint new file mode 100755 index 000000000..61c034983 --- /dev/null +++ b/contrib/ntp/scripts/build/UpdatePoint @@ -0,0 +1,337 @@ +#! /bin/sh + +# showusage is set to 1 on any command-line syntax error +showusage=0 +# are we playing by stable or dev rules? +repo= +# test is set to 1 if -t/--test is given to prevent modifications +test=0 + +case "$#" in + 1) repo=$1 + ;; + 2) repo=$2 + case $1 in + -t|--test) + test=1 + ;; + *) + showusage=1 + ;; + esac + ;; + *) showusage=1 + ;; +esac + +case "$repo" in + dev|stable) + ;; + '') + showusage=1 + ;; + *) echo "Unexpected repo type: <$repo>!" + showusage=1 + ;; +esac + +case "$showusage" in + 1) echo "Usage: $0 [-t] " + echo "No changes are made to packageinfo.sh if -t is given." + exit 1 + ;; +esac + + +set -e + +. ./packageinfo.sh + +case "$repotype" in + $repo) + ;; + *) echo "You indicated repo type <$repo> but packageinfo.sh" + echo "indicates <$repotype>." + exit 1 + ;; +esac + +ver_repo_mismatch=1 + +case "$minor" in + 1|3|5|7|9) + case "$repo" in + dev) + ver_repo_mismatch=0 + ;; + stable) + ;; + esac + ;; + 0|2|4|6|8) + case "$repo" in + dev) + ;; + stable) + ver_repo_mismatch=0 + ;; + esac + ;; +esac + +case "$ver_repo_mismatch" in + 1) echo "Minor version <$minor> mismatches repotype <$repo>." + exit 1 + ;; +esac + +# Do we want to bump the point? +bp=1 +# Do we want to bump the beta point? +bbp=0 +# Do we want to change the RC point? (n=no, z=empty rcpoint and zero +# betapoint, i=incr) +crcp=n +# Do we want to change the prerelease value? +setpr=0 + +# for stable: +# if we are not in a beta or RC state, enter beta unless point is NEW. +# if we are in a beta state: +# - bump the beta point +# else if we are in an RC state: +# - if rcpoint is GO: +# - - set rcpoint= (empty) +# - - set prerelease= (empty) +# - - set betapoint=0 +# - else +# - - if rcpoint==(empty) +# - - - (bump-point) and set rcpoint to 0 (and fall thru, so -RC1 is first) +# - - bump the RC point + +# for dev, we only want to bump-point and possibly clear prerelease, +# but we do not modify rcpoint nor betapoint. + +case "$repo" in + dev) + case "$point" in + [Nn][Ee][Ww]) + crcp=z + ;; + *) + # crcp=n + ;; + esac + # bp=1 + ;; + stable) + case "$prerelease" in + '') + case "$betapoint::$rcpoint::$point" in + *::*::NEW) + # new minor release (no p) + crcp=z + # bp=1 + ;; + 0::::*) + # start of first beta cycle for the next point release + setpr=1 + newpr=beta + # bp=1 + bbp=1 + ;; + 0::[Gg][Oo]::*) + # skip all -beta and -RC prereleases to the next point. + crcp=z + setpr=1 + newpr= + # bp=1 + # bbp=0 + ;; + *) echo "betapoint is <$betapoint>, rcpoint is <$rcpoint>" + echo "betapoint must be 0 and rcpoint must be empty to start the" + echo "beta cycle." + exit 1 + ;; + esac + ;; + beta) + case "$betapoint::$rcpoint" in + [1-9]*::*) + bp=0 + bbp=1 + ;; + 0::) echo "betapoint is 0, rcpoint emtpy, and prerelease is beta." + echo "You probably intended prerelease= (that is, empty). It" + echo "will then be changed to beta by this script, starting the" + echo "first beta for the next point release." + exit 1 + ;; + *) + bp=0 + bbp=1 + ;; + esac + case "$rcpoint" in + [Gg][Oo]) + echo "prerelease is beta, rcpoint is GO, disallowed." + echo "rcpoint GO is allowed only when prerelease is RC or empty." + exit 1 + ;; + esac + ;; + rc|RC) + case "$rcpoint" in + '') + case "$betapoint" in + 0) # bp=1 + ;; + *) bp=0 + ;; + esac + crcp=i + ;; + [1-9]*) + bp=0 + crcp=i + ;; + [Gg][Oo]) + bp=0 + crcp=z + setpr=1 + newpr= + ;; + *) echo "Unexpected value for 'rcpoint' <$rcpoint>!" + exit 1 + ;; + esac + ;; + *) + echo "prerelease <$prerelease> unexpected" + exit 1 + ;; + esac + ;; + *) echo "impossible: repo <$repo>!" + exit 1 + ;; +esac + +case "$repo::$bp::$point" in + *::0::*) + newpoint=$point + ;; + dev::1::0) + newpoint=`expr $point + 1` + ;; + *::1::[1-9]*) + newpoint=`expr $point + 1` + ;; + dev::1::) + newpoint=0 + ;; + stable::1::) + newpoint=1 + ;; + *::1::[Nn][Ee][Ww]) + newpoint= + ;; + *) echo "Unexpected value for 'point' <$point>! (repo::bp::point is $repo::$bp::$point)" + exit 1 + ;; +esac + +case "$bbp::$betapoint" in + 0::*) + newbetapoint=$betapoint + ;; + 1::[0-9]*) + newbetapoint=`expr $betapoint + 1` + ;; + *) echo "Unexpected value for 'betapoint' <$betapoint>!" + exit 1 + ;; +esac + +case "$crcp::$rcpoint" in + n::*) + newrcpoint=$rcpoint + ;; + i::) + newrcpoint=1 + ;; + i::[0-9]*) + newrcpoint=`expr $rcpoint + 1` + ;; + z::*) + newrcpoint= + newbetapoint=0 + ;; + *) echo "Unexpected value for 'crcp::rcpoint' <$crcp::$rcpoint>!" + exit 1 + ;; +esac + +case "$setpr" in + 0) + newpr=$prerelease +esac + +# display results +printf "prerelease $prerelease" +case "$newpr" in + $prerelease) + printf "\n" + ;; + *) printf " -> $newpr\n" + ;; +esac +printf "point $point" +case "$newpoint" in + $point) + printf "\n" + ;; + *) printf " -> $newpoint\n" + ;; +esac +printf "betapoint $betapoint" +case "$newbetapoint" in + $betapoint) + printf "\n" + ;; + *) printf " -> $newbetapoint\n" + ;; +esac +printf "rcpoint $rcpoint" +case "$newrcpoint" in + $rcpoint) + printf "\n" + ;; + *) printf " -> $newrcpoint\n" + ;; +esac + +printf "Previous version: " +scripts/build/VersionName + +# apply packageinfo.sh changes + +sed -e "s/^point=.*/point=$newpoint/" \ + -e "s/^betapoint=.*/betapoint=$newbetapoint/" \ + -e "s/^rcpoint=.*/rcpoint=$newrcpoint/" \ + -e "s/^prerelease=.*/prerelease=$newpr/" \ + < packageinfo.sh \ + > packageinfo.sh+ + +case "$test" in + 0) + mv packageinfo.sh+ packageinfo.sh + printf "Updated version: " + scripts/build/VersionName + ;; + *) + printf "Next version would be: " + scripts/build/VersionName -p ./packageinfo.sh+ + rm packageinfo.sh+ + ;; +esac diff --git a/contrib/ntp/scripts/build/VersionName b/contrib/ntp/scripts/build/VersionName new file mode 100755 index 000000000..84b597226 --- /dev/null +++ b/contrib/ntp/scripts/build/VersionName @@ -0,0 +1,70 @@ +#! /bin/sh + +packageinfo='./packageinfo.sh' +case "$#" in + 2) + case "$1" in + -p|--packageinfo) + packageinfo="$2" + esac + ;; + 0) + ;; + *) echo "Usage: $0 [-p packageinfo.sh]" + exit 1 + ;; +esac + +# This script must be executed from the TLD of the source tree... +. "$packageinfo" + +NAME="$version" +case "$repotype::$point" in + dev::) + case "${proto}.${major}" in + 4.[012]) + NAME="${NAME}p${point}" + ;; + *) NAME="${NAME}" + ;; + esac + ;; + stable::[1-9]* | dev::[0-9]*) + case "${proto}.${major}" in + 4.[012]) + NAME="${NAME}p${point}" + ;; + *) NAME="${NAME}.${point}" + ;; + esac + ;; + NEW) ;; + '') ;; + *) echo "Unexpected value for 'point' <$point>! (repotype is <$repotype>)" + exit 1 + ;; +esac + +case $special in + '') ;; + *) NAME="${NAME}-${special}" ;; +esac + +case "$prerelease::$repotype" in + ''::*) + ;; + beta::stable) + NAME="${NAME}-beta${betapoint}" + ;; + rc::dev|RC::dev) + NAME="${NAME}-RC" + ;; + rc::stable|RC::stable) + NAME="${NAME}-RC${rcpoint}" + ;; + *) echo "Unexpected value for 'prerelease::repotype' <$prerelease::$repotype>!" + exit 1 + ;; +esac + +echo "$NAME" diff --git a/contrib/ntp/scripts/build/check--help b/contrib/ntp/scripts/build/check--help new file mode 100755 index 000000000..1524675b4 --- /dev/null +++ b/contrib/ntp/scripts/build/check--help @@ -0,0 +1,22 @@ +#! /bin/sh + +# Look at the file specified in $1 to see if it contains 'no --help'. +# If it does: +# - Squawk +# - rename the file to ($1)- +# - exit with a non-zero status. +# otherwise: +# - exit with a 0 status. + +if test ! -f $1 +then + echo "$0: $1 is not a regular file!" 2>&3 + exit 1 +fi + +if grep -q 'no --help' $1 +then + echo "$0: $1 contains 'no --help'!" 2>&3 + mv ${1} ${1}- + exit 1 +fi diff --git a/contrib/ntp/scripts/build/checkChangeLog b/contrib/ntp/scripts/build/checkChangeLog new file mode 100755 index 000000000..46c56c44b --- /dev/null +++ b/contrib/ntp/scripts/build/checkChangeLog @@ -0,0 +1,29 @@ +#! /bin/sh + +. ./packageinfo.sh + +# HMS: Irix doesn't have 'head'... +cl1=`head -1 ChangeLog || sed -e 1q ChangeLog` + +case "$repotype" in + dev) ;; + stable) ;; + *) echo "Unexpected repotype <$repotype>" + exit 1 + ;; +esac + +case "$repotype$cl1" in + dev---) + echo "Dev repo ChangeLog must not begin with '---'!" + exit 1 + ;; + dev*) + ;; + stable---) + ;; + stable*) + echo "Stable repo Changelog must begin with '---'!" + exit 1 + ;; +esac diff --git a/contrib/ntp/scripts/build/checkHtmlFileDates b/contrib/ntp/scripts/build/checkHtmlFileDates new file mode 100755 index 000000000..9d9a2f262 --- /dev/null +++ b/contrib/ntp/scripts/build/checkHtmlFileDates @@ -0,0 +1,16 @@ +#! /bin/sh + +bk version > /dev/null 2>&1 || exit 0 + +for i in `find * -type f -name '*.html' -print | grep -v SCCS/` +do + # echo $i + set `bk diffs $i | wc -l` + lines=$1 + case "$lines" in + 0) ;; + *) echo "Processing <$i>" + ../scripts/build/updateBEDate $i + ;; + esac +done diff --git a/contrib/ntp/scripts/fixautomakedepsmagic b/contrib/ntp/scripts/build/fixautomakedepsmagic old mode 100644 new mode 100755 similarity index 100% rename from contrib/ntp/scripts/fixautomakedepsmagic rename to contrib/ntp/scripts/build/fixautomakedepsmagic diff --git a/contrib/ntp/scripts/build/genCommitLog b/contrib/ntp/scripts/build/genCommitLog new file mode 100755 index 000000000..318e2866a --- /dev/null +++ b/contrib/ntp/scripts/build/genCommitLog @@ -0,0 +1,16 @@ +#! /bin/sh + +set -e + +GCL_REMOVEWRITE=0 +. ./packageinfo.sh +if [ ! -w . ] ; then + GCL_REMOVEWRITE=1 + chmod u+w . + [ -f CommitLog -a ! -w CommitLog ] && chmod u+w CommitLog +fi +bk changes -v -m -r${CLTAG}.. > CommitLog.new +mv CommitLog.new CommitLog +case "$GCL_REMOVEWRITE" in + 1) chmod a-w CommitLog . +esac diff --git a/contrib/ntp/scripts/build/genver b/contrib/ntp/scripts/build/genver new file mode 100755 index 000000000..c07324392 --- /dev/null +++ b/contrib/ntp/scripts/build/genver @@ -0,0 +1,96 @@ +#! /bin/sh + +# possible usage: $0 [-f] [version.m4] [version.def] +# +# -f would be 'force the update' + +force=0 +outputs= +for i in $* +do + case "$i" in + -f) + force=1 + ;; + *version.m4) + outputs="m4/version.m4 $outputs" + ;; + *version.def) + outputs="include/version.def $outputs" + ;; + *version.texi) + outputs="include/version.texi $outputs" + ;; + *) echo "Unrecognized option: $i" + exit 1 + ;; + esac +done + +case "$outputs" in + '') outputs="m4/version.m4 include/version.def include/version.texi" ;; +esac + +set -e + +. ../packageinfo.sh + +dversion=`../scripts/build/VersionName -p ../packageinfo.sh` + +set +e + +# Create intermediate files in $TEMPDIR defaulting it to /tmp +# if not set. This avoids races when multiple builds run in +# parallel on shared source. + +TEMPDIR=${TEMPDIR=/tmp} + +case "$outputs" in + *version.m4*) + echo "m4_define([VERSION_NUMBER],[${dversion}])" > "${TEMPDIR}/version.m4+" + cmp -s "${TEMPDIR}/version.m4+" m4/version.m4 + rc=$? + case "$force$rc" in + 00) + rm -f "${TEMPDIR}/version.m4+" + ;; + *) + mv "${TEMPDIR}/version.m4+" m4/version.m4 + ;; + esac + ;; +esac + +case "$outputs" in + *version.def*) + echo "version = '${dversion}';" > "${TEMPDIR}/version.def+" + cmp -s "${TEMPDIR}/version.def+" include/version.def + rc=$? + case "$force$rc" in + 00) + rm -f "${TEMPDIR}/version.def+" + ;; + *) + mv "${TEMPDIR}/version.def+" include/version.def + ;; + esac + ;; +esac + +case "$outputs" in + *version.texi*) + echo "@set UPDATED `date +'%d %B %Y'`" > "${TEMPDIR}/version.texi+" + echo "@set EDITION $dversion" >> "${TEMPDIR}/version.texi+" + echo "@set VERSION $dversion" >> "${TEMPDIR}/version.texi+" + cmp -s "${TEMPDIR}/version.texi+" include/version.texi + rc=$? + case "$force$rc" in + 00) + rm -f "${TEMPDIR}/version.texi+" + ;; + *) + mv "${TEMPDIR}/version.texi+" include/version.texi + ;; + esac + ;; +esac diff --git a/contrib/ntp/scripts/mkver.in b/contrib/ntp/scripts/build/mkver.in similarity index 78% rename from contrib/ntp/scripts/mkver.in rename to contrib/ntp/scripts/build/mkver.in index e8d9892bd..3aef1c816 100644 --- a/contrib/ntp/scripts/mkver.in +++ b/contrib/ntp/scripts/build/mkver.in @@ -1,4 +1,4 @@ -#!@PATH_SH@ +#!@CONFIG_SHELL@ PROG=${1-UNKNOWN} ConfStr="$PROG" @@ -10,13 +10,13 @@ case "$CSET" in *) ConfStr="$ConfStr@$CSET" ;; esac -case "@LCRYPTO@" in +case "@VER_SUFFIX@" in '') ;; - -lcrypto) - ConfStr="${ConfStr}-o" ;; - *) ConfStr="${ConfStr}-?" ;; + *) ConfStr="${ConfStr}-@VER_SUFFIX@" ;; esac +ConfStr="$ConfStr `LC_TIME=C TZ=UTC date`" + if [ ! -f .version ]; then echo 0 > .version fi diff --git a/contrib/ntp/scripts/build/updateBEDate b/contrib/ntp/scripts/build/updateBEDate new file mode 100755 index 000000000..467e7070a --- /dev/null +++ b/contrib/ntp/scripts/build/updateBEDate @@ -0,0 +1,53 @@ +#! /usr/bin/env perl +use warnings; +use strict; + +# for each filename on the command line +# get the modtime +# make a backup of the file +# - error if there is already a backup? +# flush the live version(?) +# start a line-by-line copy of the backup to the new file, +# doing the BeginDate/EndDate substitution + +# 3-oct-11 18:20 +# 01-Aug-2011 17:56 +# without the 'm' no minutes are included. + +my $i; +my $mod_time; +my $stamp; +my @m_abbr = qw(Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec); + +foreach ( @ARGV ) { + $i = $_; + $mod_time = (stat ($i))[9]; + $stamp = localtime($mod_time); + my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = + localtime($mod_time); + $year += 1900; + + # print "<$i> at <$stamp>\n"; + + open(my $IFILE, "<", $i) or die "Cannot open < $i: $!"; + open(my $OFILE, ">", $i.".new") or die "Cannot open > $i.new: $!"; + while(<$IFILE>) { + if (/(.*).*(.*)/) { + # print "Got: $_"; + # print "as: <$1><$2><$3>...<$4>\n"; + print { $OFILE } $1,$2,$3; + printf { $OFILE } "%s-%s-%s %02d:%02d", $mday,$m_abbr[$mon],$year,$hour,$min; + print { $OFILE } $4,"\n"; + } + else { + print { $OFILE } $_; + } + } + close($IFILE); + close($OFILE); + # + utime(time, $mod_time, "$i.new") || die "touch $i.new failed: $!"; + # + rename $i,"$i.old" || die "rename $i,$i.old failed: $!"; + rename "$i.new",$i || die "rename $i.new,$i failed: $!"; +} diff --git a/contrib/ntp/scripts/calc_tickadj.in b/contrib/ntp/scripts/calc_tickadj.in deleted file mode 100644 index 32eae1296..000000000 --- a/contrib/ntp/scripts/calc_tickadj.in +++ /dev/null @@ -1,38 +0,0 @@ -#! @PATH_PERL@ -# -# drift of 104.8576 -> +1 tick. Base of 10000 ticks. -# -# 970306 HMS Deal with nanoseconds. Fix sign of adjustments. - -$df="/etc/ntp.drift"; -# Assumes a 100Hz box with "tick" of 10000 -# Someday, we might call "tickadj" for better values... -$base=10000; # tick: 1,000,000 / HZ -$cvt=104.8576; # 2 ** 20 / $base -$v1=0.; -$v2=""; - -if (open(DF, $df)) - { - if ($_=) - { - ($v1, $v2) = split; - } - - while ($v1 < 0) - { - $v1 += $cvt; - $base--; - } - - while ($v1 > $cvt) - { - $v1 -= $cvt; - $base++; - } - } - -printf("%.3f (drift)\n", $v1); - -printf("%d usec; %d nsec\n", $base, ($base + ($v1/$cvt)) * 1000); - diff --git a/contrib/ntp/scripts/calc_tickadj/Makefile.am b/contrib/ntp/scripts/calc_tickadj/Makefile.am new file mode 100644 index 000000000..b98bc8771 --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/Makefile.am @@ -0,0 +1,104 @@ +NULL= +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + + +bin_SCRIPTS= $(CALC_TICKADJ_DB) +libexec_SCRIPTS= $(CALC_TICKADJ_DL) +sbin_SCRIPTS= $(CALC_TICKADJ_DS) +EXTRA_SCRIPTS= calc_tickadj + +man1_MANS= +man8_MANS= +manpage_HACK= +if WANT_CALC_TICKADJ_MS +man_MANS= calc_tickadj.$(CALC_TICKADJ_MS) +else +manpage_HACK+= calc_tickadj. +# Note that if we don't WANT_CALC_TICKADJ then CALC_TICKADJ_MS will +# be empty. But we still need the .texi and other files to be built, as +# they are general prerequisites. +# The manpage_HACK is listed in noinst_DATA so that takes care of these. +endif + +DISTCLEANFILES = config.log $(man_MANS) calc_tickadj. + +EXTRA_DIST = \ + calc_tickadj.in \ + calc_tickadj.1calc_tickadjman \ + calc_tickadj.1calc_tickadjmdoc \ + calc_tickadj.man.in \ + calc_tickadj.mdoc.in \ + calc_tickadj.texi \ + calc_tickadj.html \ + calc_tickadj-opts.def \ + calc_tickadj-opts \ + invoke-calc_tickadj.texi \ + invoke-calc_tickadj.menu \ + $(NULL) + +noinst_DATA = \ + calc_tickadj.1calc_tickadjman \ + calc_tickadj.1calc_tickadjmdoc \ + calc_tickadj.man.in \ + calc_tickadj.mdoc.in \ + calc_tickadj.texi \ + calc_tickadj.html \ + calc_tickadj-opts.def \ + calc_tickadj-opts \ + invoke-calc_tickadj.texi \ + invoke-calc_tickadj.menu \ + $(manpage_HACK) \ + $(NULL) + +calc_tickadj: $(srcdir)/calc_tickadj-opts + +$(srcdir)/calc_tickadj-opts: $(srcdir)/calc_tickadj-opts.def + $(run_ag) calc_tickadj-opts.def + +### Nroff + +$(srcdir)/calc_tickadj.1calc_tickadjman: $(srcdir)/calc_tickadj-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1calc_tickadjman -Tagman-cmd.tpl calc_tickadj-opts.def + +$(srcdir)/calc_tickadj.man.in: $(srcdir)/calc_tickadj.1calc_tickadjman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/calc_tickadj.1calc_tickadjman > $(srcdir)/calc_tickadj.man.in+ + mv $(srcdir)/calc_tickadj.man.in+ $(srcdir)/calc_tickadj.man.in + +### Mdoc + +$(srcdir)/calc_tickadj.1calc_tickadjmdoc: $(srcdir)/calc_tickadj-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1calc_tickadjmdoc -Tagmdoc-cmd.tpl calc_tickadj-opts.def + +$(srcdir)/calc_tickadj.mdoc.in: $(srcdir)/calc_tickadj.1calc_tickadjmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/calc_tickadj.1calc_tickadjmdoc > $(srcdir)/calc_tickadj.mdoc.in+ + mv $(srcdir)/calc_tickadj.mdoc.in+ $(srcdir)/calc_tickadj.mdoc.in + +### Manpage + +calc_tickadj.$(CALC_TICKADJ_MS): $(srcdir)/calc_tickadj.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=calc_tickadj.$(CALC_TICKADJ_MS)+:$(srcdir)/calc_tickadj.$(MANTAGFMT).in + mv calc_tickadj.$(CALC_TICKADJ_MS)+ calc_tickadj.$(CALC_TICKADJ_MS) + +### Texinfo + +$(srcdir)/invoke-calc_tickadj.menu: $(srcdir)/invoke-calc_tickadj.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-calc_tickadj.texi: $(srcdir)/calc_tickadj-opts $(srcdir)/calc_tickadj-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section calc_tickadj-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/calc_tickadj.html: $(srcdir)/invoke-calc_tickadj.menu $(srcdir)/invoke-calc_tickadj.texi $(srcdir)/calc_tickadj.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o calc_tickadj.html calc_tickadj.texi || true ) diff --git a/contrib/ntp/scripts/calc_tickadj/Makefile.in b/contrib/ntp/scripts/calc_tickadj/Makefile.in new file mode 100644 index 000000000..c68c31dfd --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/Makefile.in @@ -0,0 +1,961 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +@WANT_CALC_TICKADJ_MS_FALSE@am__append_1 = calc_tickadj. +subdir = scripts/calc_tickadj +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = calc_tickadj +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" +SCRIPTS = $(bin_SCRIPTS) $(libexec_SCRIPTS) $(sbin_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 +NROFF = nroff +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(noinst_DATA) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/calc_tickadj.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +bin_SCRIPTS = $(CALC_TICKADJ_DB) +libexec_SCRIPTS = $(CALC_TICKADJ_DL) +sbin_SCRIPTS = $(CALC_TICKADJ_DS) +EXTRA_SCRIPTS = calc_tickadj +man1_MANS = +man8_MANS = +manpage_HACK = $(am__append_1) +@WANT_CALC_TICKADJ_MS_TRUE@man_MANS = calc_tickadj.$(CALC_TICKADJ_MS) +# Note that if we don't WANT_CALC_TICKADJ then CALC_TICKADJ_MS will +# be empty. But we still need the .texi and other files to be built, as +# they are general prerequisites. +# The manpage_HACK is listed in noinst_DATA so that takes care of these. +DISTCLEANFILES = config.log $(man_MANS) calc_tickadj. +EXTRA_DIST = \ + calc_tickadj.in \ + calc_tickadj.1calc_tickadjman \ + calc_tickadj.1calc_tickadjmdoc \ + calc_tickadj.man.in \ + calc_tickadj.mdoc.in \ + calc_tickadj.texi \ + calc_tickadj.html \ + calc_tickadj-opts.def \ + calc_tickadj-opts \ + invoke-calc_tickadj.texi \ + invoke-calc_tickadj.menu \ + $(NULL) + +noinst_DATA = \ + calc_tickadj.1calc_tickadjman \ + calc_tickadj.1calc_tickadjmdoc \ + calc_tickadj.man.in \ + calc_tickadj.mdoc.in \ + calc_tickadj.texi \ + calc_tickadj.html \ + calc_tickadj-opts.def \ + calc_tickadj-opts \ + invoke-calc_tickadj.texi \ + invoke-calc_tickadj.menu \ + $(manpage_HACK) \ + $(NULL) + +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/calc_tickadj/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign scripts/calc_tickadj/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +calc_tickadj: $(top_builddir)/config.status $(srcdir)/calc_tickadj.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +install-binSCRIPTS: $(bin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir) +install-libexecSCRIPTS: $(libexec_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(libexecdir)'; $(am__uninstall_files_from_dir) +install-sbinSCRIPTS: $(sbin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(sbindir)'; $(am__uninstall_files_from_dir) + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-man1: $(man1_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(SCRIPTS) $(MANS) $(DATA) +installdirs: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-man + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-binSCRIPTS install-libexecSCRIPTS \ + install-sbinSCRIPTS + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: install-man1 install-man8 + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-binSCRIPTS uninstall-libexecSCRIPTS \ + uninstall-man uninstall-sbinSCRIPTS + +uninstall-man: uninstall-man1 uninstall-man8 + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-binSCRIPTS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-libexecSCRIPTS install-man \ + install-man1 install-man8 install-pdf install-pdf-am \ + install-ps install-ps-am install-sbinSCRIPTS install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \ + uninstall-am uninstall-binSCRIPTS uninstall-libexecSCRIPTS \ + uninstall-man uninstall-man1 uninstall-man8 \ + uninstall-sbinSCRIPTS + +.PRECIOUS: Makefile + + +calc_tickadj: $(srcdir)/calc_tickadj-opts + +$(srcdir)/calc_tickadj-opts: $(srcdir)/calc_tickadj-opts.def + $(run_ag) calc_tickadj-opts.def + +### Nroff + +$(srcdir)/calc_tickadj.1calc_tickadjman: $(srcdir)/calc_tickadj-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1calc_tickadjman -Tagman-cmd.tpl calc_tickadj-opts.def + +$(srcdir)/calc_tickadj.man.in: $(srcdir)/calc_tickadj.1calc_tickadjman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/calc_tickadj.1calc_tickadjman > $(srcdir)/calc_tickadj.man.in+ + mv $(srcdir)/calc_tickadj.man.in+ $(srcdir)/calc_tickadj.man.in + +### Mdoc + +$(srcdir)/calc_tickadj.1calc_tickadjmdoc: $(srcdir)/calc_tickadj-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1calc_tickadjmdoc -Tagmdoc-cmd.tpl calc_tickadj-opts.def + +$(srcdir)/calc_tickadj.mdoc.in: $(srcdir)/calc_tickadj.1calc_tickadjmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/calc_tickadj.1calc_tickadjmdoc > $(srcdir)/calc_tickadj.mdoc.in+ + mv $(srcdir)/calc_tickadj.mdoc.in+ $(srcdir)/calc_tickadj.mdoc.in + +### Manpage + +calc_tickadj.$(CALC_TICKADJ_MS): $(srcdir)/calc_tickadj.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=calc_tickadj.$(CALC_TICKADJ_MS)+:$(srcdir)/calc_tickadj.$(MANTAGFMT).in + mv calc_tickadj.$(CALC_TICKADJ_MS)+ calc_tickadj.$(CALC_TICKADJ_MS) + +### Texinfo + +$(srcdir)/invoke-calc_tickadj.menu: $(srcdir)/invoke-calc_tickadj.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-calc_tickadj.texi: $(srcdir)/calc_tickadj-opts $(srcdir)/calc_tickadj-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section calc_tickadj-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/calc_tickadj.html: $(srcdir)/invoke-calc_tickadj.menu $(srcdir)/invoke-calc_tickadj.texi $(srcdir)/calc_tickadj.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o calc_tickadj.html calc_tickadj.texi || true ) + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts b/contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts new file mode 100644 index 000000000..c8a8c0d85 --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts @@ -0,0 +1,60 @@ +# EDIT THIS FILE WITH CAUTION (calc_tickadj-opts) +# +# It has been AutoGen-ed August 31, 2014 at 04:52:46 AM by AutoGen 5.18.4 +# From the definitions calc_tickadj-opts.def +# and the template file perlopt + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + 'drift-file' => '/etc/ntp/drift', + 'tick' => '', + 'help' => '', 'more-help' => '' + }; + my $argument = ''; + my $ret = GetOptionsFromArray($args, $opts, ( + 'drift-file|d=s', 'tick|t=i', + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +calc_tickadj - Calculates "optimal" value for tick given ntp drift file. - Ver. 4.2.7p467 +USAGE: calc_tickadj [ - [] | --[{=| }] ]... + + -d, --drift-file=str Ntp drift file to use + -t, --tick=num Tick value of this host + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'}; + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts.def b/contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts.def new file mode 100644 index 000000000..cdb50efeb --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj-opts.def @@ -0,0 +1,60 @@ +/* -*- Mode: Text -*- */ +AutoGen Definitions perlopt; + +#include autogen-version.def + +prog-name = calc_tickadj; +prog-title = 'Calculates "optimal" value for tick given ntp drift file.'; +package = ntp; +#include version.def + +long-opts; +gnu-usage; + +flag = { + name = drift-file; + value = d; + arg-type = string; + arg-default = '/etc/ntp/drift'; + descrip = 'Ntp drift file to use'; + doc = 'Use the specified drift file for calculations'; +}; + +flag = { + name = tick; + value = t; + arg-type = number; + descrip = 'Tick value of this host'; + doc = 'The current tick which to adjustment will be calculated'; +}; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'texi'; + ds-text = <<- _EndOfDoc +The @code{calc_tickadj} script uses provided ntp drift file to generate optimal +tick value. Generally, ntpd can do better job if the drift value is the +smallest possible number. + +The example output of +@example +$ ./calc_tickadj +81.699 (drift) +9999 usec; 9999779 nsec +$ cat /etc/ntp/drift +-23.159 +@end example + +means the following. If tick on that box is 10,000, by making the value 9999 +we'll shift the box from its current drift of -23.159 to a drift of 81.699, and +in doing so we'll speed the clock up a little every second instead of slowing +the clock down a little. + +If 'tick' on that box is 10,000,000 then by setting it to 9999779 the drift +value will be somewhere around 0.0. + +@code{calc_tickadj} tries to determine the the tick value by using +@code{tickadj} program from ntp package. If this doesn't work you can specify +current tick manually on command line. + _EndOfDoc; +}; diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjman b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjman new file mode 100644 index 000000000..9057b89bb --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjman @@ -0,0 +1,108 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH calc_tickadj 1calc_tickadjman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-3baGnz/ag-dcaOmz) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:33:58 PM by AutoGen 5.18.5 +.\" From the definitions calc_tickadj-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]calc_tickadj\fP +\- Calculates optimal value for tick given ntp drift file. +.SH SYNOPSIS +\f\*[B-Font]calc_tickadj\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The \fBcalc_tickadj\fP script uses provided ntp drift file to generate optimal +tick value. Generally, ntpd can do better job if the drift value is the +smallest possible number. +.sp +The example output of +.br +.in +4 +.nf +$ ./calc_tickadj +81.699 (drift) +9999 usec; 9999779 nsec +$ cat /etc/ntp/drift +-23.159 +.in -4 +.fi +.sp +means the following. If tick on that box is 10,000, by making the value 9999 +we'll shift the box from its current drift of \-23.159 to a drift of 81.699, and +in doing so we'll speed the clock up a little every second instead of slowing +the clock down a little. +.sp +If 'tick' on that box is 10,000,000 then by setting it to 9999779 the drift +value will be somewhere around 0.0. +.sp +\fBcalc_tickadj\fP tries to determine the the tick value by using +\fBtickadj\fP program from ntp package. If this doesn't work you can specify +current tick manually on command line. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-d\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-drift\-file\f[]=\f\*[I-Font]string\f[] +Ntp drift file to use. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + /etc/ntp/drift +.sp +Use the specified drift file for calculations +.TP +.NOP \f\*[B-Font]\-t\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-tick\f[]=\f\*[I-Font]number\f[] +Tick value of this host. +This option takes an integer number as its argument. +.sp +The current tick which to adjustment will be calculated +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBcalc_tickadj\fP +option definitions. diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc new file mode 100644 index 000000000..9c1245b9c --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.1calc_tickadjmdoc @@ -0,0 +1,84 @@ +.Dd October 21 2015 +.Dt CALC_TICKADJ 1calc_tickadjmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (calc_tickadj-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:02 PM by AutoGen 5.18.5 +.\" From the definitions calc_tickadj-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm calc_tickadj +.Nd Calculates "optimal" value for tick given ntp drift file. +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +The \fBcalc_tickadj\fP script uses provided ntp drift file to generate optimal +tick value. Generally, ntpd can do better job if the drift value is the +smallest possible number. +.sp +The example output of +.Bd -literal -offset indent +$ ./calc_tickadj +81.699 (drift) +9999 usec; 9999779 nsec +$ cat /etc/ntp/drift +-23.159 +.Ed +.sp +means the following. If tick on that box is 10,000, by making the value 9999 +we'll shift the box from its current drift of \-23.159 to a drift of 81.699, and +in doing so we'll speed the clock up a little every second instead of slowing +the clock down a little. +.sp +If 'tick' on that box is 10,000,000 then by setting it to 9999779 the drift +value will be somewhere around 0.0. +.sp +\fBcalc_tickadj\fP tries to determine the the tick value by using +\fBtickadj\fP program from ntp package. If this doesn't work you can specify +current tick manually on command line. +.Sh "OPTIONS" +.Bl -tag +.It Fl d Ar string , Fl \-drift\-file Ns = Ns Ar string +Ntp drift file to use. +The default +.Ar string +for this option is: +.ti +4 + /etc/ntp/drift +.sp +Use the specified drift file for calculations +.It Fl t Ar number , Fl \-tick Ns = Ns Ar number +Tick value of this host. +This option takes an integer number as its argument. +.sp +The current tick which to adjustment will be calculated +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBcalc_tickadj\fP +option definitions. diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj.html b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.html new file mode 100644 index 000000000..a88e28fc2 --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.html @@ -0,0 +1,166 @@ + + +calc_tickadj User's Manual + + + + + + + + + +

      calc_tickadj User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      calc_tickadj User's Manual

      + +

      This document describes the use of the NTP Project's calc_tickadj program. +This document applies to version 4.2.8p4 of calc_tickadj. + +

      +

      Short Contents

      + +
      + + + +
      +


      +Previous: calc_tickadj Description, +Up: Top +
      +
      + +

      Invoking calc_tickadj

      + +

      +The calc_tickadj script uses provided ntp drift file to generate optimal +tick value. Generally, ntpd can do better job if the drift value is the +smallest possible number. + +

      The example output of +

           $ ./calc_tickadj
      +     81.699 (drift)
      +     9999 usec; 9999779 nsec
      +     $ cat /etc/ntp/drift
      +     -23.159
      +
      +

      means the following. If tick on that box is 10,000, by making the value 9999 +we'll shift the box from its current drift of -23.159 to a drift of 81.699, and +in doing so we'll speed the clock up a little every second instead of slowing +the clock down a little. + +

      If 'tick' on that box is 10,000,000 then by setting it to 9999779 the drift +value will be somewhere around 0.0. + +

      calc_tickadj tries to determine the the tick value by using +tickadj program from ntp package. If this doesn't work you can specify +current tick manually on command line. + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the calc_tickadj program. + +

      + + + +

      calc_tickadj help/usage (--help)

      + +

      +This is the automatically generated usage text for calc_tickadj. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      calc_tickadj - Calculates "optimal" value for tick given ntp drift file. - Ver. 4.2.7p467
      +USAGE: calc_tickadj [ -<flag> [<val>] | --<name>[{=| }<val>] ]...
      +
      +    -d, --drift-file=str         Ntp drift file to use
      +    -t, --tick=num               Tick value of this host
      +    -?, --help                   Display usage information and exit
      +        --more-help              Pass the extended usage text through a pager
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      + + +

      drift-file option (-d)

      + +

      +This is the “ntp drift file to use” option. +This option takes a string argument. +Use the specified drift file for calculations +

      + +

      tick option (-t)

      + +

      +This is the “tick value of this host” option. +This option takes a number argument. +The current tick which to adjustment will be calculated +

      +


      +Previous: calc_tickadj tick, +Up: calc_tickadj Invocation +
      +
      + +

      calc_tickadj exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      + + + diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj.in b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.in new file mode 100644 index 000000000..38b826eb2 --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.in @@ -0,0 +1,59 @@ +#! @PATH_PERL@ -w +# +# drift of 104.8576 -> +1 tick. Base of 10000 ticks. +# +# 970306 HMS Deal with nanoseconds. Fix sign of adjustments. +package calc_tickadj; +use strict; + +exit run(@ARGV) unless caller; + +sub run { + my $opts; + if (!processOptions(\@_, $opts)) { + usage(1); + }; + my $drift_file = $opts->{'drift-file'}; + my $tick = $opts->{'tick'}; + + if (!$tick) { + my ($fl) = `tickadj`; + if (defined $fl && $fl =~ /(?:KERNEL|PRESET)?\s*tick\s+=\s+(\d+)/) { + $tick = $1; + } + else { + die "Could not get tick value, try manually with -t/--tick\n"; + } + } + + # Drift file is in PPM where Milion is actually 2**20 + my $cvt = (2 ** 20) / $tick; + my $drift = 0.; + + open my $dfh, $drift_file or die "Could not open $drift_file: $!\n"; + + $drift = <$dfh>; + + close $dfh; + die "Invalid drift file value <$drift>" if $drift !~ /[+-]?\d+\.?[0-9]+/; + + while ($drift < 0) { + $drift += $cvt; + $tick--; + } + + while ($drift > $cvt) { + $drift -= $cvt; + $tick++; + } + + printf "%.3f (drift)\n", $drift; + printf "%d usec; %d nsec\n", $tick, ($tick + ($drift/$cvt)) * 1000; + + return 0; +} + +@calc_tickadj_opts@ + +1; +__END__ diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj.man.in b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.man.in new file mode 100644 index 000000000..9057b89bb --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.man.in @@ -0,0 +1,108 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH calc_tickadj 1calc_tickadjman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-3baGnz/ag-dcaOmz) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:33:58 PM by AutoGen 5.18.5 +.\" From the definitions calc_tickadj-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]calc_tickadj\fP +\- Calculates optimal value for tick given ntp drift file. +.SH SYNOPSIS +\f\*[B-Font]calc_tickadj\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +The \fBcalc_tickadj\fP script uses provided ntp drift file to generate optimal +tick value. Generally, ntpd can do better job if the drift value is the +smallest possible number. +.sp +The example output of +.br +.in +4 +.nf +$ ./calc_tickadj +81.699 (drift) +9999 usec; 9999779 nsec +$ cat /etc/ntp/drift +-23.159 +.in -4 +.fi +.sp +means the following. If tick on that box is 10,000, by making the value 9999 +we'll shift the box from its current drift of \-23.159 to a drift of 81.699, and +in doing so we'll speed the clock up a little every second instead of slowing +the clock down a little. +.sp +If 'tick' on that box is 10,000,000 then by setting it to 9999779 the drift +value will be somewhere around 0.0. +.sp +\fBcalc_tickadj\fP tries to determine the the tick value by using +\fBtickadj\fP program from ntp package. If this doesn't work you can specify +current tick manually on command line. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-d\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-drift\-file\f[]=\f\*[I-Font]string\f[] +Ntp drift file to use. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + /etc/ntp/drift +.sp +Use the specified drift file for calculations +.TP +.NOP \f\*[B-Font]\-t\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-tick\f[]=\f\*[I-Font]number\f[] +Tick value of this host. +This option takes an integer number as its argument. +.sp +The current tick which to adjustment will be calculated +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBcalc_tickadj\fP +option definitions. diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj.mdoc.in b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.mdoc.in new file mode 100644 index 000000000..9c1245b9c --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.mdoc.in @@ -0,0 +1,84 @@ +.Dd October 21 2015 +.Dt CALC_TICKADJ 1calc_tickadjmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (calc_tickadj-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:02 PM by AutoGen 5.18.5 +.\" From the definitions calc_tickadj-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm calc_tickadj +.Nd Calculates "optimal" value for tick given ntp drift file. +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +The \fBcalc_tickadj\fP script uses provided ntp drift file to generate optimal +tick value. Generally, ntpd can do better job if the drift value is the +smallest possible number. +.sp +The example output of +.Bd -literal -offset indent +$ ./calc_tickadj +81.699 (drift) +9999 usec; 9999779 nsec +$ cat /etc/ntp/drift +-23.159 +.Ed +.sp +means the following. If tick on that box is 10,000, by making the value 9999 +we'll shift the box from its current drift of \-23.159 to a drift of 81.699, and +in doing so we'll speed the clock up a little every second instead of slowing +the clock down a little. +.sp +If 'tick' on that box is 10,000,000 then by setting it to 9999779 the drift +value will be somewhere around 0.0. +.sp +\fBcalc_tickadj\fP tries to determine the the tick value by using +\fBtickadj\fP program from ntp package. If this doesn't work you can specify +current tick manually on command line. +.Sh "OPTIONS" +.Bl -tag +.It Fl d Ar string , Fl \-drift\-file Ns = Ns Ar string +Ntp drift file to use. +The default +.Ar string +for this option is: +.ti +4 + /etc/ntp/drift +.sp +Use the specified drift file for calculations +.It Fl t Ar number , Fl \-tick Ns = Ns Ar number +Tick value of this host. +This option takes an integer number as its argument. +.sp +The current tick which to adjustment will be calculated +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBcalc_tickadj\fP +option definitions. diff --git a/contrib/ntp/scripts/calc_tickadj/calc_tickadj.texi b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.texi new file mode 100644 index 000000000..d15b428ec --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/calc_tickadj.texi @@ -0,0 +1,37 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename calc_tickadj.info +@settitle calc_tickadj User's Manual +@include ../../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of @code{calc_tickadj}, a program from the NTP +Project, that is used calculate optimal tick value based on given drift file. +@end ifinfo + +@direntry +* calc_tickadj: (calc_tickadj). Calculate optimal tick value from a drift file. +@end direntry + +@titlepage +@title calc_tickadj User's Manual +@subtitle calc_tickadj, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@node Top, calc_tickadj Description, (dir), (dir) +@top calc_tickadj User's Manual + +This document describes the use of the NTP Project's @code{calc_tickadj} program. +This document applies to version @value{VERSION} of @code{calc_tickadj}. + +@shortcontents + +@menu +* calc_tickadj Description:: Description +* calc_tickadj Invocation:: Invoking calc_tickadj +@end menu + +@include invoke-calc_tickadj.texi diff --git a/contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.menu b/contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.menu new file mode 100644 index 000000000..865a0d72d --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.menu @@ -0,0 +1 @@ +* calc_tickadj Invocation:: Invoking calc_tickadj diff --git a/contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.texi b/contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.texi new file mode 100644 index 000000000..2c666341d --- /dev/null +++ b/contrib/ntp/scripts/calc_tickadj/invoke-calc_tickadj.texi @@ -0,0 +1,102 @@ +@node calc_tickadj Invocation +@section Invoking calc_tickadj +@pindex calc_tickadj +@cindex Calculates "optimal" value for tick given ntp drift file. +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-calc_tickadj.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:04 PM by AutoGen 5.18.5 +# From the definitions calc_tickadj-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + +The @code{calc_tickadj} script uses provided ntp drift file to generate optimal +tick value. Generally, ntpd can do better job if the drift value is the +smallest possible number. + +The example output of +@example +$ ./calc_tickadj +81.699 (drift) +9999 usec; 9999779 nsec +$ cat /etc/ntp/drift +-23.159 +@end example + +means the following. If tick on that box is 10,000, by making the value 9999 +we'll shift the box from its current drift of -23.159 to a drift of 81.699, and +in doing so we'll speed the clock up a little every second instead of slowing +the clock down a little. + +If 'tick' on that box is 10,000,000 then by setting it to 9999779 the drift +value will be somewhere around 0.0. + +@code{calc_tickadj} tries to determine the the tick value by using +@code{tickadj} program from ntp package. If this doesn't work you can specify +current tick manually on command line. + + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{calc_tickadj} program. + +@menu +* calc_tickadj usage:: calc_tickadj help/usage (@option{--help}) +* calc_tickadj drift-file:: drift-file option (-d) +* calc_tickadj tick:: tick option (-t) +* calc_tickadj exit status:: exit status +@end menu + +@node calc_tickadj usage +@subsection calc_tickadj help/usage (@option{--help}) +@cindex calc_tickadj help + +This is the automatically generated usage text for calc_tickadj. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +calc_tickadj - Calculates "optimal" value for tick given ntp drift file. - Ver. 4.2.7p467 +USAGE: calc_tickadj [ - [] | --[@{=| @}] ]... + + -d, --drift-file=str Ntp drift file to use + -t, --tick=num Tick value of this host + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +@end example +@exampleindent 4 + +@node calc_tickadj drift-file +@subsection drift-file option (-d) +@cindex calc_tickadj-drift-file + +This is the ``ntp drift file to use'' option. +This option takes a string argument. +Use the specified drift file for calculations +@node calc_tickadj tick +@subsection tick option (-t) +@cindex calc_tickadj-tick + +This is the ``tick value of this host'' option. +This option takes a number argument. +The current tick which to adjustment will be calculated +@node calc_tickadj exit status +@subsection calc_tickadj exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table diff --git a/contrib/ntp/scripts/checktime.in b/contrib/ntp/scripts/checktime.in deleted file mode 100644 index 2fe8f711b..000000000 --- a/contrib/ntp/scripts/checktime.in +++ /dev/null @@ -1,79 +0,0 @@ -#! @PATH_PERL@ -#! @PATH_PERL@ -d -# -# This script compares the time of several machines with the -# time on the local host. -# -# Use or modify it as you wish. -# -# As the original author is only expecting 14 minutes of fame, -# leaving his name attached would be appreciated. -# -# R. Gary Cutbill -# 21 April 1999 -# -$tol=2.0; -$|=1; -print "Time Check"; - -open(HOSTS,"ypcat hosts.byaddr |"); # get a list of hosts from the yp server. - -while ($line=) { # loop for each host getting the offset compared to localhost - ($addr,$host,$aliases)=split(/\s+/,$line,3); - $res=`/usr/local/bin/ntptrace -m 1 -r 1 -t 1 $host`; - print "."; - chop $res; - push (@results,$res); -} -print "\n"; - - -# -# Sort the list of hosts, and print out there offsets -# from the local host. -# -@list=sort appropriately @results; -foreach $i ( @list ) { - - @dargs=split(/\s+/,$i); - if ( $dargs[1] eq "\*Timeout\*" ) { - print "$i\n"; - chop $dargs[0]; - push(@down,$dargs[0]); - } else { - printf "%-25s %7s %3s %6s %10s %5s %8s %8s\n",@dargs; - if ( ( $dargs[4] > $tol ) || ( $dargs[4] < -$tol ) ) { - chop $dargs[0]; - push(@toofarout,$dargs[0]); } - } -} -# -# When the above list finishes, hosts that are different by +/- $tol (two seconds) -# are in @toofarout. Hosts that are down are in @down. They are treated the same -# way here, but you might want to do something different depending on your site. -# -# print a set of suggested rsh commands to run on the hosts that -# don't have "good" time. "restartntp" is left as an excersize to the reader. -# I usually use it to kill a running xntpd, ntpdate some server, and the start xntp -# again. -# -print "\nConsider:\n"; -foreach $i ( (@down,@toofarout) ) { - print " rsh $i sudo restartntp\n"; -} - - -# -# sort the results from the list. First by stratum, then by time deviation -# Put hosts that didn't respond (timed out) on the bottom. -# -sub appropriately { - @af=split(/\s+/,$a); - @bf=split(/\s+/,$b); - $aba= ($af[4]<0)?-$af[4]:$af[4]; - $abb= ($bf[4]<0)?-$bf[4]:$bf[4]; - - ( $af[1] ne $bf[1] ) ? $bf[1] cmp $af[1] : - ( ( $af[2] != $bf[2] ) ? ( $bf[2] <=> $af[2] ) : - ( ( $aba != $abb ) ? ( $abb <=> $aba ) : ($af[0] cmp $bf[0] ) ) ); -} diff --git a/contrib/ntp/scripts/freq_adj.in b/contrib/ntp/scripts/deprecated/freq_adj.in similarity index 100% rename from contrib/ntp/scripts/freq_adj.in rename to contrib/ntp/scripts/deprecated/freq_adj.in diff --git a/contrib/ntp/scripts/hpadjtime.sh b/contrib/ntp/scripts/deprecated/hpadjtime.sh similarity index 100% rename from contrib/ntp/scripts/hpadjtime.sh rename to contrib/ntp/scripts/deprecated/hpadjtime.sh diff --git a/contrib/ntp/scripts/html2man.in b/contrib/ntp/scripts/deprecated/html2man.in similarity index 51% rename from contrib/ntp/scripts/html2man.in rename to contrib/ntp/scripts/deprecated/html2man.in index b7cebce32..adc484820 100755 --- a/contrib/ntp/scripts/html2man.in +++ b/contrib/ntp/scripts/deprecated/html2man.in @@ -19,32 +19,34 @@ $MANDIR = "./man"; # HTML files to convert. Also include per-file info here: # name of man page, man section, 'see also' section %manfiles = ( - 'ntpd' => ['ntpd', 8, 'ntp.conf(5), ntpq(8), ntpdc(8)'], - 'ntpq' => ['ntpq', 8, 'ntpd(8), ntpdc(8)'], - 'ntpdate' => ['ntpdate', 8, 'ntpd(8)'], - 'ntpdc' => ['ntpdc', 8, 'ntpd(8)'], - 'ntptime' => ['ntpdtime', 8, 'ntpd(8), ntpdate(8)'], - 'ntptrace' => ['ntptrace', 8, 'ntpd(8)'], - 'keygen' => ['ntp-keygen', 8, 'ntpd(8), ntp_auth(5)'], - 'confopt' => ['ntp.conf', 5, 'ntpd(8)'], - 'authopt' => ['ntp_auth', 5, 'ntp.conf(5), ntpd(8)'], - 'monopt' => ['ntp_mon', 5, 'ntp.conf(5)'], + 'ntpd' => ['ntpd', @NTPD_MS@, 'ntp.conf(5), ntpq(@NTPQ_MS@), ntpdc(@NTPDC_MS@)'], + 'ntpq' => ['ntpq', @NTPQ_MS@, 'ntp_decode(5), ntpd(@NTPD_MS@), ntpdc(@NTPDC_MS@)'], + 'ntpdate' => ['ntpdate', @NTPDATE_MS@, 'ntpd(@NTPD_MS@)'], + 'ntpdc' => ['ntpdc', @NTPDC_MS@, 'ntpd(@NTPD_MS@)'], + 'ntptime' => ['ntptime', @NTPTIME_MS@, 'ntpd(@NTPD_MS@), ntpdate(@NTPDATE_MS@)'], + 'ntptrace' => ['ntptrace', @NTPTRACE_MS@, 'ntpd(@NTPD_MS@)'], + 'ntp-wait' => ['ntp-wait', @NTP_WAIT_MS@, 'ntpd(@NTPD_MS@)'], + 'keygen' => ['ntp-keygen', @NTP_KEYGEN_MS@, 'ntpd(@NTPD_MS@), ntp_auth(5)'], + 'tickadj' => ['tickadj', @TICKADJ_MS@, 'ntpd(@NTPD_MS@)'], + 'confopt' => ['ntp.conf', 5, 'ntpd(@NTPD_MS@), ntp_auth(5), ntp_mon(5), ntp_acc(5), ntp_clock(5), ntp_misc(5)'], + 'authopt' => ['ntp_auth', 5, 'ntp.conf(5), ntpd(@NTPD_MS@)'], + 'monopt' => ['ntp_mon', 5, 'ntp.conf(5), ntp_decode(5)'], 'accopt' => ['ntp_acc', 5, 'ntp.conf(5)'], 'clockopt' => ['ntp_clock', 5, 'ntp.conf(5)'], + 'decode' => ['ntp_decode', 5, 'ntpq(@NTPQ_MS@), ntp_mon(5)'], 'miscopt' => ['ntp_misc', 5, 'ntp.conf(5)']); -# Disclaimer to go in SEE ALSO section of the man page -$seealso_disclaimer = 'These man pages are automatically hacked from the main NTP ' . - 'documentation pages, which are maintained in HTML format. These files are ' . - 'included in the NTP source distribution. If you installed NTP from a binary ' . - 'package, or it came pre-installed on your system, chances are the documentation ' . - 'was also included in the usual place for your system. The HTML files are more ' . - 'correct and complete than these man pages, which are provided for your reference ' . - 'only.'; +%table_headers = ( + 'ntpd' => 'l l l l.', + 'ntpq' => 'l l.', + 'monopt' => 'l l l.', + 'decode' => 'l l l l.', + 'authopt' => 'c c c c c c.' +); -# Disclaimer to go right at the top -$top_disclaimer = 'This file was automatically generated from HTML source, and may be ' . - 'incorrect. See the SEE ALSO section at the end of this file for more info'; +# Disclaimer to go in SEE ALSO section of the man page +$seealso_disclaimer = "The official HTML documentation.\n\n" . + "This file was automatically generated from HTML source.\n"; mkdir $MANDIR, 0777; mkdir "$MANDIR/man8", 0777; @@ -64,7 +66,8 @@ sub process { $fileinfo = $manfiles{$filename}; $p = HTML::TokeParser->new("$filename.html") || die "Can't open $filename.html: $!"; - open(MANOUT, ">$MANDIR/man$fileinfo->[1]/$fileinfo->[0].$fileinfo->[1]") + $fileout = "$MANDIR/man$fileinfo->[1]/$fileinfo->[0].$fileinfo->[1]"; + open(MANOUT, ">$fileout") || die "Can't open: $!"; $p->get_tag("title"); @@ -73,7 +76,6 @@ sub process { # Setup man header print MANOUT ".TH " . $fileinfo->[0] . " " . $fileinfo->[1] . "\n"; - print MANOUT ".UC 4\n"; print MANOUT ".SH NAME\n"; $pat = $fileinfo->[0]; if ($name =~ /$pat/) { @@ -81,10 +83,13 @@ sub process { # Add the manpage name, if not in the HTML title already print MANOUT "$fileinfo->[0] - "; } - print MANOUT "$name\n\n"; - - print MANOUT "$top_disclaimer\n"; + print MANOUT "$name\n.SH \\ \n\n"; + @fontstack = (); + $deflevel = 0; + $pre = 0; + $ignore = 0; + $first_td = 1; # Now start scanning. We basically print everything after translating some tags. # $token->[0] has "T", "S", "E" for Text, Start, End # $token->[1] has the tag name, or text (for "T" case) @@ -92,19 +97,37 @@ sub process { while (my $token = $p->get_token) { if($token->[0] eq "T") { my $text = $token->[1]; - if($tag) { - $text =~ s/^[\n ]*//; - $text =~ s/[\n ]*$/ /; + if (!$pre) { + if($tag) { + $text =~ s/^[\n\t ]*//; + } + $text =~ s/^[\n\t ][\n\t ]+$//; + $text =~ s/[\n\t ]+/ /g; + $text =~ s/ \;/ /g; + $text =~ s/>\;/>/g; + $text =~ s/<\;/[0] eq "S") { if($token->[1] eq "h4") { my $text = uc($p->get_trimmed_text("/h4")); - print MANOUT ".SH $text\n"; + # ignore these sections in ntpd.html + if ($filename eq "ntpd" && + ($text eq "CONFIGURATION OPTIONS")) { + $ignore = 1; + close(MANOUT); + open(MANOUT, ">/dev/null"); + } elsif ($ignore) { + $ignore = 0; + close(MANOUT); + open(MANOUT, ">>$fileout"); + } + print MANOUT "\n\n.SH $text\n"; } if($token->[1] eq "tt") { push @fontstack, "tt"; @@ -118,22 +141,42 @@ sub process { my $text = $p->get_trimmed_text("/address"); print MANOUT "\n.SH AUTHOR\n$text\n"; } - if($token->[1] eq "dt") { - $tmp = $deflevel-4; - print MANOUT "\n.RS $tmp\n"; + if($token->[1] eq "dt" || $token->[1] eq "br" && $deflevel > 0) { + print MANOUT "\n.TP 8\n"; $tag = 1; } if($token->[1] eq "dd") { - print MANOUT "\n.RS $deflevel\n"; + print MANOUT "\n"; $tag = 1; } if($token->[1] eq "dl") { - $deflevel+=4; + $deflevel+=1; + if ($deflevel > 0) { + print MANOUT "\n.RS ", $deflevel > 1 ? 8 : 0; + } + } + if($token->[1] eq "p") { + print MANOUT "\n"; + } + if($token->[1] eq "pre") { + print MANOUT "\n.nf"; + $pre = 1; + } + if($token->[1] eq "table") { + print MANOUT "\n.TS\n"; + print MANOUT "expand allbox tab(%);\n"; + print MANOUT $table_headers{$filename}; + print MANOUT "\n"; + } + if($token->[1] eq "td") { + if ($first_td == 0) { + print MANOUT " % "; + } + $first_td = 0; } } elsif($token->[0] eq "E") { - if($token->[1] eq "dd") { - print MANOUT "\n.RE\n"; + if($token->[1] eq "h4") { $tag = 1; } if($token->[1] eq "tt") { @@ -157,15 +200,34 @@ sub process { print MANOUT "$fontswitch"; } if($token->[1] eq "dl") { - $deflevel-=4; + if ($deflevel > 0) { + print MANOUT "\n.RE"; + } + print MANOUT "\n"; + $deflevel-=1; } - if($token->[1] eq "dt") { - print MANOUT "\n.RE"; + if($token->[1] eq "p") { + print MANOUT "\n"; $tag = 1; } + if($token->[1] eq "pre") { + print MANOUT "\n.fi"; + $pre = 0; + } + if($token->[1] eq "table") { + print MANOUT ".TE\n"; + } + if($token->[1] eq "tr") { + print MANOUT "\n"; + $first_td = 1; + } } } - print MANOUT ".SH SEE ALSO\n\n"; + if ($ignore) { + close(MANOUT); + open(MANOUT, ">>$fileout"); + } + print MANOUT "\n.SH SEE ALSO\n\n"; print MANOUT "$fileinfo->[2]\n\n"; print MANOUT "$seealso_disclaimer\n"; close(MANOUT); diff --git a/contrib/ntp/scripts/ntp-close b/contrib/ntp/scripts/deprecated/ntp-close similarity index 100% rename from contrib/ntp/scripts/ntp-close rename to contrib/ntp/scripts/deprecated/ntp-close diff --git a/contrib/ntp/scripts/ntp-groper b/contrib/ntp/scripts/deprecated/ntp-groper similarity index 100% rename from contrib/ntp/scripts/ntp-groper rename to contrib/ntp/scripts/deprecated/ntp-groper diff --git a/contrib/ntp/scripts/ntp-restart b/contrib/ntp/scripts/deprecated/ntp-restart similarity index 100% rename from contrib/ntp/scripts/ntp-restart rename to contrib/ntp/scripts/deprecated/ntp-restart diff --git a/contrib/ntp/scripts/ntp-status b/contrib/ntp/scripts/deprecated/ntp-status similarity index 100% rename from contrib/ntp/scripts/ntp-status rename to contrib/ntp/scripts/deprecated/ntp-status diff --git a/contrib/ntp/scripts/genCommitLog b/contrib/ntp/scripts/genCommitLog deleted file mode 100755 index 2a258add4..000000000 --- a/contrib/ntp/scripts/genCommitLog +++ /dev/null @@ -1,7 +0,0 @@ -#! /bin/sh - -set -e - -. packageinfo.sh -bk -R prs -hr${CLTAG}.. -nd':I:' | bk changes -m -v - > CommitLog.new -mv CommitLog.new CommitLog diff --git a/contrib/ntp/scripts/genver b/contrib/ntp/scripts/genver deleted file mode 100755 index 0ce192213..000000000 --- a/contrib/ntp/scripts/genver +++ /dev/null @@ -1,67 +0,0 @@ -#! /bin/sh - -# possible usage: $0 [-f] [version.m4] [version.def] -# -# -f would be 'force the update' - -force=0 -outputs= -for i in $* -do - case "$i" in - -f) force=1 ;; - version.m4) - outputs="version.m4 $outputs" - ;; - *version.def) - outputs="include/version.def $outputs" - ;; - *) echo "Unrecognized option: $i" - exit 1 - ;; - esac -done - -case "$outputs" in - '') outputs="version.m4 include/version.def" ;; -esac - -set -e - -. ./packageinfo.sh - -dversion=`scripts/VersionName` - -set +e - -case "$outputs" in - *version.m4*) - echo "m4_define([VERSION_NUMBER],[${dversion}])" > /tmp/version.m4+ - cmp -s /tmp/version.m4+ version.m4 - rc=$? - case "$force$rc" in - 00) - rm -f /tmp/version.m4+ - ;; - *) - mv /tmp/version.m4+ version.m4 - ;; - esac - ;; -esac - -case "$outputs" in - *version.def*) - echo "version = '${dversion}';" > /tmp/version.def+ - cmp -s /tmp/version.def+ include/version.def - rc=$? - case "$force$rc" in - 00) - rm -f /tmp/version.def+ - ;; - *) - mv /tmp/version.def+ include/version.def - ;; - esac - ;; -esac diff --git a/contrib/ntp/scripts/invoke-plot_summary.menu b/contrib/ntp/scripts/invoke-plot_summary.menu new file mode 100644 index 000000000..b287f20a0 --- /dev/null +++ b/contrib/ntp/scripts/invoke-plot_summary.menu @@ -0,0 +1 @@ +* plot_summary Invocation:: Invoking plot_summary diff --git a/contrib/ntp/scripts/invoke-plot_summary.texi b/contrib/ntp/scripts/invoke-plot_summary.texi new file mode 100644 index 000000000..914c37b92 --- /dev/null +++ b/contrib/ntp/scripts/invoke-plot_summary.texi @@ -0,0 +1,121 @@ +@node plot_summary Invocation +@section Invoking plot_summary +@pindex plot_summary +@cindex plot statistics generated by summary script +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-plot_summary.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:48 PM by AutoGen 5.18.5 +# From the definitions plot_summary-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{plot_summary} program. + +@menu +* plot_summary usage:: plot_summary help/usage (@option{--help}) +* plot_summary directory:: directory option +* plot_summary identifier:: identifier option +* plot_summary peer:: peer option +* plot_summary plot-term:: plot-term option +* plot_summary output-file:: output-file option +* plot_summary exit status:: exit status +@end menu + +@node plot_summary usage +@subsection plot_summary help/usage (@option{--help}) +@cindex plot_summary help + +This is the automatically generated usage text for plot_summary. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +plot_summary - plot statistics generated by summary script - Ver. 4.2.8p4 +USAGE: plot_summary [ - [] | --[@{=| @}] ]... + + --directory=str Where the summary files are + --identifier=str Origin of the data + --offset-limit=float Limit of absolute offset + --peer=str Peers to generate plots for + - may appear multiple times + --plot-term=str Gnuplot terminal + --output-file=str Output file + --dont-wait Don't wait for keystroke between plots + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +@end example +@exampleindent 4 + +@node plot_summary directory +@subsection directory option +@cindex plot_summary-directory + +This is the ``where the summary files are'' option. +This option takes a string argument. + The directory where the @code{plot_summary} will search for the + *_summary files generated by @code{summary} script. +@node plot_summary identifier +@subsection identifier option +@cindex plot_summary-identifier + +This is the ``origin of the data'' option. +This option takes a string argument. + Where does the plotted data come from, default to string "host" plus + current hostname +@node plot_summary peer +@subsection peer option +@cindex plot_summary-peer + +This is the ``peers to generate plots for'' option. +This option takes a string argument. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + + By default the peer_summary plots are not generated. Use this option to + specify list of peers if you want to generate plots for them. +@node plot_summary plot-term +@subsection plot-term option +@cindex plot_summary-plot-term + +This is the ``gnuplot terminal'' option. +This option takes a string argument. + This is string is passed directly to the @code{gnuplot set terminal} + command. Default is @code{x11} if @code{DISPLAY} is set and + @code{dumb} is it's not'. See output from @code(gnuplot -e "set + terminal") for the list of avalaible options. +@node plot_summary output-file +@subsection output-file option +@cindex plot_summary-output-file + +This is the ``output file'' option. +This option takes a str argument. + Output file for @code{gnuplot}, default to stdout. +@node plot_summary exit status +@subsection plot_summary exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table diff --git a/contrib/ntp/scripts/invoke-summary.menu b/contrib/ntp/scripts/invoke-summary.menu new file mode 100644 index 000000000..f6adfe1d1 --- /dev/null +++ b/contrib/ntp/scripts/invoke-summary.menu @@ -0,0 +1 @@ +* summary Invocation:: Invoking summary diff --git a/contrib/ntp/scripts/invoke-summary.texi b/contrib/ntp/scripts/invoke-summary.texi new file mode 100644 index 000000000..dc0dca731 --- /dev/null +++ b/contrib/ntp/scripts/invoke-summary.texi @@ -0,0 +1,103 @@ +@node summary Invocation +@section Invoking summary +@pindex summary +@cindex compute various stastics from NTP stat files +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-summary.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:54 PM by AutoGen 5.18.5 +# From the definitions summary-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + + + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{summary} program. + +@menu +* summary usage:: summary help/usage (@option{--help}) +* summary directory:: directory option +* summary end-date:: end-date option +* summary output-directory:: output-directory option +* summary start-date:: start-date option +* summary exit status:: exit status +@end menu + +@node summary usage +@subsection summary help/usage (@option{--help}) +@cindex summary help + +This is the automatically generated usage text for summary. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +summary - compute various stastics from NTP stat files - Ver. 4.2.8p4 +USAGE: summary [ - [] | --[@{=| @}] ]... + + --directory=str Directory containing stat files + --end-date=num End date + --output-directory=str Output directory + --peer-dist-limit=float Peer dist limit + --skip-time-steps=float Ignore time offsets larger that this + --start-date=num Start date + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +@end example +@exampleindent 4 + +@node summary directory +@subsection directory option +@cindex summary-directory + +This is the ``directory containing stat files'' option. +This option takes a string argument. + The directory where @code{ntpd} will search for .stat files generated + by @code{ntpd}. +@node summary end-date +@subsection end-date option +@cindex summary-end-date + +This is the ``end date'' option. +This option takes a number argument. + Process all files with the date suffix less or equal to value of this + option. Defaults to today minus one day (Use @code{date -u +%Y%m%d}) + to get the timestamp. +@node summary output-directory +@subsection output-directory option +@cindex summary-output-directory + +This is the ``output directory'' option. +This option takes a str argument. + The output directory @code{summary} will write all output files to. +@node summary start-date +@subsection start-date option +@cindex summary-start-date + +This is the ``start date'' option. +This option takes a num argument. + Process all files with the date suffix more or equal to value of + this option. Defaults to 197000101. +@node summary exit status +@subsection summary exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table diff --git a/contrib/ntp/scripts/lib/Makefile.am b/contrib/ntp/scripts/lib/Makefile.am new file mode 100644 index 000000000..d7c0c0e2c --- /dev/null +++ b/contrib/ntp/scripts/lib/Makefile.am @@ -0,0 +1,5 @@ +perllibdir = @PERLLIBDIR@ + +nobase_perllib_DATA = NTP/Util.pm + +EXTRA_DIST = ${nobase_perllib_DATA} diff --git a/contrib/ntp/scripts/lib/Makefile.in b/contrib/ntp/scripts/lib/Makefile.in new file mode 100644 index 000000000..4a4161033 --- /dev/null +++ b/contrib/ntp/scripts/lib/Makefile.in @@ -0,0 +1,680 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = scripts/lib +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(perllibdir)" +DATA = $(nobase_perllib_DATA) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +perllibdir = @PERLLIBDIR@ +nobase_perllib_DATA = NTP/Util.pm +EXTRA_DIST = ${nobase_perllib_DATA} +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/lib/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign scripts/lib/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-nobase_perllibDATA: $(nobase_perllib_DATA) + @$(NORMAL_INSTALL) + @list='$(nobase_perllib_DATA)'; test -n "$(perllibdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(perllibdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(perllibdir)" || exit 1; \ + fi; \ + $(am__nobase_list) | while read dir files; do \ + xfiles=; for file in $$files; do \ + if test -f "$$file"; then xfiles="$$xfiles $$file"; \ + else xfiles="$$xfiles $(srcdir)/$$file"; fi; done; \ + test -z "$$xfiles" || { \ + test "x$$dir" = x. || { \ + echo " $(MKDIR_P) '$(DESTDIR)$(perllibdir)/$$dir'"; \ + $(MKDIR_P) "$(DESTDIR)$(perllibdir)/$$dir"; }; \ + echo " $(INSTALL_DATA) $$xfiles '$(DESTDIR)$(perllibdir)/$$dir'"; \ + $(INSTALL_DATA) $$xfiles "$(DESTDIR)$(perllibdir)/$$dir" || exit $$?; }; \ + done + +uninstall-nobase_perllibDATA: + @$(NORMAL_UNINSTALL) + @list='$(nobase_perllib_DATA)'; test -n "$(perllibdir)" || list=; \ + $(am__nobase_strip_setup); files=`$(am__nobase_strip)`; \ + dir='$(DESTDIR)$(perllibdir)'; $(am__uninstall_files_from_dir) +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(DATA) +installdirs: + for dir in "$(DESTDIR)$(perllibdir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-nobase_perllibDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-nobase_perllibDATA + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-nobase_perllibDATA install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \ + uninstall-am uninstall-nobase_perllibDATA + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/scripts/lib/NTP/Util.pm b/contrib/ntp/scripts/lib/NTP/Util.pm new file mode 100644 index 000000000..69d4df1c9 --- /dev/null +++ b/contrib/ntp/scripts/lib/NTP/Util.pm @@ -0,0 +1,155 @@ +package NTP::Util; +use strict; +use warnings; +use Exporter 'import'; +use Carp; +use version 0.77; + +our @EXPORT_OK = qw(ntp_read_vars do_dns ntp_peers ntp_sntp_line); + +my $ntpq_path = 'ntpq'; +my $sntp_path = 'sntp'; + +our $IP_AGNOSTIC; + +BEGIN { + require Socket; + if (version->parse($Socket::VERSION) >= version->parse(1.94)) { + Socket->import(qw(getaddrinfo getnameinfo SOCK_RAW AF_INET)); + $IP_AGNOSTIC = 1; + } + else { + Socket->import(qw(inet_aton SOCK_RAW AF_INET)); + } +} + +my %obsolete_vars = ( + phase => 'offset', + rootdispersion => 'rootdisp', +); + +sub ntp_read_vars { + my ($peer, $vars, $host) = @_; + my $do_all = !@$vars; + my %out_vars = map {; $_ => undef } @$vars; + + $out_vars{status_line} = {} if $do_all; + + my $cmd = "$ntpq_path -n -c 'rv $peer ".(join ',', @$vars)."'"; + $cmd .= " $host" if defined $host; + $cmd .= " |"; + + open my $fh, $cmd or croak "Could not start ntpq: $!"; + + while (<$fh>) { + return undef if /Connection refused/; + + if (/^asso?c?id=0 status=(\S{4}) (\S+), (\S+),/gi) { + $out_vars{status_line}{status} = $1; + $out_vars{status_line}{leap} = $2; + $out_vars{status_line}{sync} = $3; + } + + while (/(\w+)=([^,]+),?\s/g) { + my ($var, $val) = ($1, $2); + $val =~ s/^"([^"]+)"$/$1/; + $var = $obsolete_vars{$var} if exists $obsolete_vars{$var}; + if ($do_all) { + $out_vars{$var} = $val + } + else { + $out_vars{$var} = $val if exists $out_vars{$var}; + } + } + } + + close $fh or croak "running ntpq failed: $! (exit status $?)"; + return \%out_vars; +} + +sub do_dns { + my ($host) = @_; + + if ($IP_AGNOSTIC) { + my ($err, $res); + + ($err, $res) = getaddrinfo($host, '', {socktype => SOCK_RAW}); + die "getaddrinfo failed: $err\n" if $err; + + ($err, $res) = getnameinfo($res->{addr}, 0); + die "getnameinfo failed: $err\n" if $err; + + return $res; + } + # Too old perl, do only ipv4 + elsif ($host =~ /^(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})$/) { + return gethostbyaddr inet_aton($host), AF_INET; + } + else { + return; + } +} + +sub ntp_peers { + my ($host) = @_; + + $host ||= ''; + my $cmd = "$ntpq_path -npw $host |"; + + open my $fh, $cmd or croak "Could not start ntpq: $!"; + + <$fh> for 1 .. 2; + + my @columns = qw(tally host refid st t when poll reach delay offset jitter); + my @peers; + while (<$fh>) { + if (/^([ x+#*o-])((?:[\w.*:-]+\s+){10}|([\w.*:-]+\s+))$/) { + my $col = 0; + my @line = ($1, split /\s+/, $2); + if( @line == 2 ) { + defined ($_ = <$fh>) or last; + s/^\s+//; + push @line, split /\s+/; + } + my $r = { map {; $columns[ $col++ ] => $_ } @line }; + $r->{remote} = $r->{tally} . $r->{host}; + push @peers, $r; + } + else { + #TODO return error (but not needed anywhere now) + warn "ERROR: $_"; + } + } + + close $fh or croak "running ntpq failed: $! (exit status $?)"; + return \@peers; +} + +# TODO: we don't need this but it would be nice to have all the line parsed +sub ntp_sntp_line { + my ($host) = @_; + + my $cmd = "$sntp_path $host |"; + open my $fh, $cmd or croak "Could not start sntp: $!"; + + my ($offset, $stratum); + while (<$fh>) { + next if !/^\d{4}-\d\d-\d\d/; + chomp; + my @output = split / /; + + $offset = $output[3]; + if (0) { + } elsif ($output[7] =~ /s(\d{1,2})/) { + $stratum = $1; + # warn "Found stratum at #7\n"; + } elsif ($output[8] =~ /s(\d{1,2})/) { + $stratum = $1; + # warn "Found stratum at #8\n"; + } + } + close $fh or croak "running sntp failed: $! (exit status $?)"; + return ($offset, $stratum); +} + +1; diff --git a/contrib/ntp/scripts/monitoring/ntp.pl b/contrib/ntp/scripts/monitoring/ntp.pl index b23f396ee..3478f71bc 100644 --- a/contrib/ntp/scripts/monitoring/ntp.pl +++ b/contrib/ntp/scripts/monitoring/ntp.pl @@ -148,24 +148,34 @@ sub ssw_SECode { return $_[$[] & 0xf; } %LI = ( 0, "leap_none", 1, "leap_add_sec", 2, "leap_del_sec", 3, "sync_alarm", "-", "leap"); %ClockSource = (0, "sync_unspec", - 1, "sync_lf_clock", - 2, "sync_uhf_clock", + 1, "sync_pps", + 2, "sync_lf_clock", 3, "sync_hf_clock", - 4, "sync_local_proto", - 5, "sync_ntp", - 6, "sync_udp/time", - 7, "sync_wristwatch", + 4, "sync_uhf_clock", + 5, "sync_local_proto", + 6, "sync_ntp", + 7, "sync_udp/time", + 8, "sync_wristwatch", + 9, "sync_telephone", "-", "ClockSource", ); %SystemEvent = (0, "event_unspec", - 1, "event_restart", - 2, "event_fault", - 3, "event_sync_chg", - 4, "event_sync/strat_chg", - 5, "event_clock_reset", - 6, "event_bad_date", - 7, "event_clock_excptn", + 1, "event_freq_not_set", + 2, "event_freq_set", + 3, "event_spike_detect", + 4, "event_freq_mode", + 5, "event_clock_sync", + 6, "event_restart", + 7, "event_panic_stop", + 8, "event_no_sys_peer", + 9, "event_leap_armed", + 10, "event_leap_disarmed", + 11, "event_leap_event", + 12, "event_clock_step", + 13, "event_kern", + 14, "event_loaded_leaps", + 15, "event_stale_leaps", "-", "event", ); sub LI @@ -196,26 +206,38 @@ sub psw_PStat_config { return ($_[$[] & 0x8000) == 0x8000; } sub psw_PStat_authenable { return ($_[$[] & 0x4000) == 0x4000; } sub psw_PStat_authentic { return ($_[$[] & 0x2000) == 0x2000; } sub psw_PStat_reach { return ($_[$[] & 0x1000) == 0x1000; } -sub psw_PStat_sane { return ($_[$[] & 0x0800) == 0x0800; } -sub psw_PStat_dispok { return ($_[$[] & 0x0400) == 0x0400; } +sub psw_PStat_bcast { return ($_[$[] & 0x0800) == 0x0800; } sub psw_PStat { return ($_[$[] >> 10) & 0x3f; } sub psw_PSel { return ($_[$[] >> 8) & 0x3; } sub psw_PCnt { return ($_[$[] >> 4) & 0xf; } sub psw_PCode { return $_[$[] & 0xf; } %PeerSelection = (0, "sel_reject", - 1, "sel_candidate", - 2, "sel_selcand", - 3, "sel_sys.peer", + 1, "sel_falsetick", + 2, "sel_excess", + 3, "sel_outlier", + 4, "sel_candidate", + 5, "sel_backup", + 6, "sel_sys.peer", + 6, "sel_pps.peer", "-", "PeerSel", ); %PeerEvent = (0, "event_unspec", - 1, "event_ip_err", - 2, "event_authen", + 1, "event_mobilize", + 2, "event_demobilize", 3, "event_unreach", 4, "event_reach", - 5, "event_clock_excptn", - 6, "event_stratum_chg", + 5, "event_restart", + 6, "event_no_reply", + 7, "event_rate_exceed", + 8, "event_denied", + 9, "event_leap_armed", + 10, "event_sys_peer", + 11, "event_clock_event", + 12, "event_bad_auth", + 13, "event_popcorn", + 14, "event_intlv_mode", + 15, "event_intlv_err", "-", "event", ); @@ -236,8 +258,7 @@ sub peer_status $x .= "authenable," if &psw_PStat_authenable($_[$[]); $x .= "authentic," if &psw_PStat_authentic($_[$[]); $x .= "reach," if &psw_PStat_reach($_[$[]); - $x .= &psw_PStat_sane($_[$[]) ? "sane," : "insane,"; - $x .= "hi_disp," unless &psw_PStat_dispok($_[$[]); + $x .= "bcast," if &psw_PStat_bcast($_[$[]); $x .= sprintf(" %s, %d event%s, %s", &PeerSelection($_[$[]), &psw_PCnt($_[$[]), ((&psw_PCnt($_[$[]) == 1) ? "" : "s"), @@ -256,7 +277,7 @@ sub csw_CEvnt { return $_[$[] & 0xff; } 1, "clk_timeout", 2, "clk_badreply", 3, "clk_fault", - 4, "clk_prop", + 4, "clk_badsig", 5, "clk_baddate", 6, "clk_badtime", "-", "clk", @@ -295,13 +316,19 @@ sub error_status ;# ;# cntrl op name translation -%CntrlOpName = (1, "read_status", +%CntrlOpName = (0, "reserved", + 1, "read_status", 2, "read_variables", 3, "write_variables", 4, "read_clock_variables", 5, "write_clock_variables", 6, "set_trap", 7, "trap_response", + 8, "configure", + 9, "saveconf", + 10, "read_mru", + 11, "read_ordlist", + 12, "rqst_nonce", 31, "unset_trap", # !!! unofficial !!! "-", "cntrlop", ); @@ -393,7 +420,7 @@ sub handle_packet $STAT_frag++; $lastseen = 1 if !&pkt_M($r_e_m_op); - if (!defined(%FRAGS)) + if (!%FRAGS) { print((&pkt_M($r_e_m_op) ? " more" : "")."\n"); $FRAGS{$offset} = $data; diff --git a/contrib/ntp/scripts/monitoring/ntptrap b/contrib/ntp/scripts/monitoring/ntptrap index 5a1bcb1b2..f2abef950 100644 --- a/contrib/ntp/scripts/monitoring/ntptrap +++ b/contrib/ntp/scripts/monitoring/ntptrap @@ -45,15 +45,17 @@ $ntp'timeout if 0; ;# sub usage { - die("usage: $0 [-n] [-p ] [-l ] [host] ...\n"); + die("usage: $0 [-p ] [-l ] [host] ...\n"); } -$opt_l = "/dev/null"; # where to write debug messages to -$opt_p = 0; # port to use locally - (0 does mean: will be choosen by kernel) - &usage unless &Getopts('l:p:'); &Getopts if 0; # make -w happy +$opt_l = "/dev/null" # where to write debug messages to + if (!$opt_l); +$opt_p = 0 # port to use locally - (0 does mean: will be chosen by kernel) + if (!$opt_p); + @Hosts = ($#ARGV < $[) ? ("localhost") : @ARGV; ;# setup for debug output diff --git a/contrib/ntp/scripts/ntp-wait.in b/contrib/ntp/scripts/ntp-wait.in deleted file mode 100644 index a26630beb..000000000 --- a/contrib/ntp/scripts/ntp-wait.in +++ /dev/null @@ -1,42 +0,0 @@ -#! @PATH_PERL@ -w - -die "perl5 needed\n" unless ($] > 5); - -use Getopt::Std; - -$opt_f = 0; # 'Hard' failure if 'state' is unknown -$opt_n = 1000; # How many tries before we give up? (10 min+) -$opt_s = 6; # Seconds to sleep between tries (6s = 10/min) -$opt_v = 0; # Be verbose? - -getopts('fn:s:v'); - -$cmd = 'ntpq -c "rv 0 state"'; - -$| = 1; # Autoflush output. - -print "Waiting for ntpd to synchronize... " if ($opt_v); -for ($i = 0; $i < $opt_n; ++$i) { - open(Q, $cmd." 2>&1 |") || die "Can't start ntpq: $!"; - while() { - if (/^state=4/) { - print "\bOK!\n" if ($opt_v); - exit 0; - } - - if (/request variable was unknown/) { - print "\bCan't tell!\nPerhaps you are running an old version of ntpd.\n" if ($opt_v); - exit $opt_f; - } - - if (/Connection refused/) { - print "\bntpd is not running!\n" if ($opt_v); - exit 1; - } - } - close(Q); - print "\b".substr("*+:.", $i % 4, 1) if ($opt_v); - sleep($opt_s); -} -print "\bNo!\nntpd did not synchronize.\n" if ($opt_v); -exit 1; diff --git a/contrib/ntp/scripts/ntp-wait/Makefile.am b/contrib/ntp/scripts/ntp-wait/Makefile.am new file mode 100644 index 000000000..b819329ea --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/Makefile.am @@ -0,0 +1,96 @@ +NULL= + +bin_SCRIPTS = $(NTP_WAIT_DB) +libexec_SCRIPTS = $(NTP_WAIT_DL) +sbin_SCRIPTS = $(NTP_WAIT_DS) + +man1_MANS= +man8_MANS= +man_MANS= ntp-wait.$(NTP_WAIT_MS) + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" PERL5LIB="$(abs_top_srcdir)/scripts/lib" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +EXTRA_SCRIPTS = ntp-wait + +DISTCLEANFILES = config.log $(man_MANS) +EXTRA_DIST = \ + ntp-wait.in \ + ntp-wait.1ntp-waitman \ + ntp-wait.1ntp-waitmdoc \ + ntp-wait.man.in \ + ntp-wait.mdoc.in \ + ntp-wait.texi \ + ntp-wait.html \ + ntp-wait-opts.def \ + ntp-wait-opts \ + invoke-ntp-wait.texi \ + invoke-ntp-wait.menu \ + $(NULL) + +html_DATA = $(srcdir)/ntp-wait.html + +noinst_DATA = \ + ntp-wait.1ntp-waitman \ + ntp-wait.1ntp-waitmdoc \ + ntp-wait.man.in \ + ntp-wait.mdoc.in \ + ntp-wait.texi \ + ntp-wait.html \ + ntp-wait-opts.def \ + ntp-wait-opts \ + invoke-ntp-wait.texi \ + invoke-ntp-wait.menu \ + $(NULL) + +ntp-wait: $(srcdir)/ntp-wait-opts + +$(srcdir)/ntp-wait-opts: $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) ntp-wait-opts.def + +### Nroff + +$(srcdir)/ntp-wait.1ntp-waitman: $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntp-waitman -Tagman-cmd.tpl ntp-wait-opts.def + +$(srcdir)/ntp-wait.man.in: $(srcdir)/ntp-wait.1ntp-waitman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp-wait.1ntp-waitman > $(srcdir)/ntp-wait.man.in+ + mv $(srcdir)/ntp-wait.man.in+ $(srcdir)/ntp-wait.man.in + +### Mdoc + +$(srcdir)/ntp-wait.1ntp-waitmdoc: $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntp-waitmdoc -Tagmdoc-cmd.tpl ntp-wait-opts.def + +$(srcdir)/ntp-wait.mdoc.in: $(srcdir)/ntp-wait.1ntp-waitmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp-wait.1ntp-waitmdoc > $(srcdir)/ntp-wait.mdoc.in+ + mv $(srcdir)/ntp-wait.mdoc.in+ $(srcdir)/ntp-wait.mdoc.in + +### Manpage + +ntp-wait.$(NTP_WAIT_MS): $(srcdir)/ntp-wait.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntp-wait.$(NTP_WAIT_MS)+:$(srcdir)/ntp-wait.$(MANTAGFMT).in + mv ntp-wait.$(NTP_WAIT_MS)+ ntp-wait.$(NTP_WAIT_MS) + +### Texinfo + +$(srcdir)/invoke-ntp-wait.menu: $(srcdir)/invoke-ntp-wait.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntp-wait.texi: ntp-wait-opts $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntp-wait-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/ntp-wait.html: $(srcdir)/invoke-ntp-wait.menu $(srcdir)/invoke-ntp-wait.texi $(srcdir)/ntp-wait.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntp-wait.html ntp-wait.texi || true ) diff --git a/contrib/ntp/scripts/ntp-wait/Makefile.in b/contrib/ntp/scripts/ntp-wait/Makefile.in new file mode 100644 index 000000000..a16d91fa7 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/Makefile.in @@ -0,0 +1,976 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = scripts/ntp-wait +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = ntp-wait +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +SCRIPTS = $(bin_SCRIPTS) $(libexec_SCRIPTS) $(sbin_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 +NROFF = nroff +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/ntp-wait.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +bin_SCRIPTS = $(NTP_WAIT_DB) +libexec_SCRIPTS = $(NTP_WAIT_DL) +sbin_SCRIPTS = $(NTP_WAIT_DS) +man1_MANS = +man8_MANS = +man_MANS = ntp-wait.$(NTP_WAIT_MS) +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" PERL5LIB="$(abs_top_srcdir)/scripts/lib" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +EXTRA_SCRIPTS = ntp-wait +DISTCLEANFILES = config.log $(man_MANS) +EXTRA_DIST = \ + ntp-wait.in \ + ntp-wait.1ntp-waitman \ + ntp-wait.1ntp-waitmdoc \ + ntp-wait.man.in \ + ntp-wait.mdoc.in \ + ntp-wait.texi \ + ntp-wait.html \ + ntp-wait-opts.def \ + ntp-wait-opts \ + invoke-ntp-wait.texi \ + invoke-ntp-wait.menu \ + $(NULL) + +html_DATA = $(srcdir)/ntp-wait.html +noinst_DATA = \ + ntp-wait.1ntp-waitman \ + ntp-wait.1ntp-waitmdoc \ + ntp-wait.man.in \ + ntp-wait.mdoc.in \ + ntp-wait.texi \ + ntp-wait.html \ + ntp-wait-opts.def \ + ntp-wait-opts \ + invoke-ntp-wait.texi \ + invoke-ntp-wait.menu \ + $(NULL) + +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/ntp-wait/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign scripts/ntp-wait/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +ntp-wait: $(top_builddir)/config.status $(srcdir)/ntp-wait.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +install-binSCRIPTS: $(bin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir) +install-libexecSCRIPTS: $(libexec_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(libexecdir)'; $(am__uninstall_files_from_dir) +install-sbinSCRIPTS: $(sbin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(sbindir)'; $(am__uninstall_files_from_dir) + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-man1: $(man1_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(SCRIPTS) $(MANS) $(DATA) +installdirs: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-htmlDATA install-man + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-binSCRIPTS install-libexecSCRIPTS \ + install-sbinSCRIPTS + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: install-man1 install-man8 + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-binSCRIPTS uninstall-htmlDATA \ + uninstall-libexecSCRIPTS uninstall-man uninstall-sbinSCRIPTS + +uninstall-man: uninstall-man1 uninstall-man8 + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-binSCRIPTS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-htmlDATA \ + install-info install-info-am install-libexecSCRIPTS \ + install-man install-man1 install-man8 install-pdf \ + install-pdf-am install-ps install-ps-am install-sbinSCRIPTS \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags-am uninstall uninstall-am uninstall-binSCRIPTS \ + uninstall-htmlDATA uninstall-libexecSCRIPTS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinSCRIPTS + +.PRECIOUS: Makefile + + +ntp-wait: $(srcdir)/ntp-wait-opts + +$(srcdir)/ntp-wait-opts: $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) ntp-wait-opts.def + +### Nroff + +$(srcdir)/ntp-wait.1ntp-waitman: $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntp-waitman -Tagman-cmd.tpl ntp-wait-opts.def + +$(srcdir)/ntp-wait.man.in: $(srcdir)/ntp-wait.1ntp-waitman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp-wait.1ntp-waitman > $(srcdir)/ntp-wait.man.in+ + mv $(srcdir)/ntp-wait.man.in+ $(srcdir)/ntp-wait.man.in + +### Mdoc + +$(srcdir)/ntp-wait.1ntp-waitmdoc: $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntp-waitmdoc -Tagmdoc-cmd.tpl ntp-wait-opts.def + +$(srcdir)/ntp-wait.mdoc.in: $(srcdir)/ntp-wait.1ntp-waitmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntp-wait.1ntp-waitmdoc > $(srcdir)/ntp-wait.mdoc.in+ + mv $(srcdir)/ntp-wait.mdoc.in+ $(srcdir)/ntp-wait.mdoc.in + +### Manpage + +ntp-wait.$(NTP_WAIT_MS): $(srcdir)/ntp-wait.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntp-wait.$(NTP_WAIT_MS)+:$(srcdir)/ntp-wait.$(MANTAGFMT).in + mv ntp-wait.$(NTP_WAIT_MS)+ ntp-wait.$(NTP_WAIT_MS) + +### Texinfo + +$(srcdir)/invoke-ntp-wait.menu: $(srcdir)/invoke-ntp-wait.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntp-wait.texi: ntp-wait-opts $(srcdir)/ntp-wait-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntp-wait-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/ntp-wait.html: $(srcdir)/invoke-ntp-wait.menu $(srcdir)/invoke-ntp-wait.texi $(srcdir)/ntp-wait.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntp-wait.html ntp-wait.texi || true ) + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.menu b/contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.menu new file mode 100644 index 000000000..bb51936ef --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.menu @@ -0,0 +1 @@ +* ntp-wait Invocation:: Invoking ntp-wait diff --git a/contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.texi b/contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.texi new file mode 100644 index 000000000..f626f3380 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/invoke-ntp-wait.texi @@ -0,0 +1,114 @@ +@node ntp-wait Invocation +@section Invoking ntp-wait +@pindex ntp-wait +@cindex Wait for ntpd to stabilize the system clock +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntp-wait.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:12 PM by AutoGen 5.18.5 +# From the definitions ntp-wait-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + + +@code{ntp-wait} +will send at most +@kbd{num-tries} +queries to +@code{ntpd(8)}, +sleeping for +@kbd{secs-between-tries} +after each status return that says +@code{ntpd(8)} +has not yet produced a synchronized and stable system clock. + +@code{ntp-wait} +will do this quietly, unless the +@code{-v} +flag is provided. +This can be useful at boot time, to delay the boot sequence until after +@kbd{ntpd} @kbd{-g} +has set the time. + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntp-wait} program. + +@menu +* ntp-wait usage:: ntp-wait help/usage (@option{--help}) +* ntp-wait tries:: tries option (-n) +* ntp-wait sleep:: sleep option (-s) +* ntp-wait verbose:: verbose option (-v) +* ntp-wait exit status:: exit status +* ntp-wait Authors:: Authors +* ntp-wait Notes:: Notes +@end menu + +@node ntp-wait usage +@subsection ntp-wait help/usage (@option{--help}) +@cindex ntp-wait help + +This is the automatically generated usage text for ntp-wait. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +ntp-wait - Wait for ntpd to stabilize the system clock - Ver. 4.2.8p4 +USAGE: ntp-wait [ - [] | --[@{=| @}] ]... + + -n, --tries=num Number of times to check ntpd + -s, --sleep=num How long to sleep between tries + -v, --verbose Be verbose + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +@end example +@exampleindent 4 + +@node ntp-wait tries +@subsection tries option (-n) +@cindex ntp-wait-tries + +This is the ``number of times to check ntpd'' option. +This option takes a number argument. + The maximum number of times we will check @code{ntpd} to see if + it has been able to synchronize and stabilize the system clock. +@node ntp-wait sleep +@subsection sleep option (-s) +@cindex ntp-wait-sleep + +This is the ``how long to sleep between tries'' option. +This option takes a number argument @file{secs-between-tries}. + We will sleep for @file{secs-between-tries} after each query + of @code{ntpd} that returns "the time is not yet stable". +@node ntp-wait verbose +@subsection verbose option (-v) +@cindex ntp-wait-verbose + +This is the ``be verbose'' option. + By default, @code{ntp-wait} is silent. + With this option, @code{ntp-wait} will provide status information. +@node ntp-wait exit status +@subsection ntp-wait exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table +@node ntp-wait Authors +@subsection ntp-wait Authors +@node ntp-wait Notes +@subsection ntp-wait Notes diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait-opts b/contrib/ntp/scripts/ntp-wait/ntp-wait-opts new file mode 100644 index 000000000..e2e2897bd --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait-opts @@ -0,0 +1,62 @@ +# EDIT THIS FILE WITH CAUTION (ntp-wait-opts) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:06 PM by AutoGen 5.18.5 +# From the definitions ntp-wait-opts.def +# and the template file perlopt + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + 'tries' => '100', + 'sleep' => '6', + 'verbose' => '', + 'help' => '', 'more-help' => '' + }; + my $argument = ''; + my $ret = GetOptionsFromArray($args, $opts, ( + 'tries|n=i', 'sleep|s=i', 'verbose|v', + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +ntp-wait - Wait for ntpd to stabilize the system clock - Ver. 4.2.8p4 +USAGE: ntp-wait [ - [] | --[{=| }] ]... + + -n, --tries=num Number of times to check ntpd + -s, --sleep=num How long to sleep between tries + -v, --verbose Be verbose + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'}; + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait-opts.def b/contrib/ntp/scripts/ntp-wait/ntp-wait-opts.def new file mode 100644 index 000000000..14eebbc91 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait-opts.def @@ -0,0 +1,109 @@ +/* -*- Mode: Text -*- */ +AutoGen Definitions perlopt; + +#include autogen-version.def + +prog-name = "ntp-wait"; +prog-title = "Wait for ntpd to stabilize the system clock"; +package = ntp; +#include version.def + +long-opts; +gnu-usage; + +flag = { + name = tries; + value = n; + arg-type = number; + arg-default = 100; + descrip = "Number of times to check ntpd"; + doc = <<- _EndOfDoc_ + The maximum number of times we will check @code{ntpd} to see if + it has been able to synchronize and stabilize the system clock. + _EndOfDoc_; +}; + +flag = { + name = sleep; + value = s; + arg-type = number; + arg-name = "secs-between-tries"; + arg-default = 6; + descrip = "How long to sleep between tries"; + doc = <<- _EndOfDoc_ + We will sleep for @file{secs-between-tries} after each query + of @code{ntpd} that returns "the time is not yet stable". + _EndOfDoc_; +}; + +flag = { + name = verbose; + value = v; + descrip = "Be verbose"; + doc = <<- _EndOfDoc_ + By default, @code{ntp-wait} is silent. + With this option, @code{ntp-wait} will provide status information. + _EndOfDoc_; +}; + +explain = <<- _END_EXPLAIN + _END_EXPLAIN; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +.Nm +will send at most +.Ar num-tries +queries to +.Xr ntpd 8 , +sleeping for +.Ar secs-between-tries +after each status return that says +.Xr ntpd 8 +has not yet produced a synchronized and stable system clock. +.Pp +.Nm +will do this quietly, unless the +.Fl v +flag is provided. +This can be useful at boot time, to delay the boot sequence until after +.Ar ntpd -g +has set the time. + _END_PROG_MDOC_DESCRIP; +}; + +/* +doc-section = { + ds-type = 'USAGE'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_USAGE + _END_MDOC_USAGE; +}; +*/ + +doc-section = { + ds-type = 'AUTHORS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_AUTH +.An "Harlan Stenn" + _END_MDOC_AUTH; +}; + +doc-section = { + ds-type = 'NOTES'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_NOTES +This document corresponds to version @VERSION@ of NTP. + _END_MDOC_NOTES; +}; + +/* +doc-section = { + ds-type = 'BUGS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_BUGS + _END_MDOC_BUGS; +}; +*/ diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitman b/contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitman new file mode 100644 index 000000000..5a0d3cc05 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitman @@ -0,0 +1,122 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntp-wait 1ntp-waitman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-fzaONA/ag-rzaWMA) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:08 PM by AutoGen 5.18.5 +.\" From the definitions ntp-wait-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntp-wait\fP +\- Wait for ntpd to stabilize the system clock +.SH SYNOPSIS +\f\*[B-Font]ntp-wait\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntp-wait\fP +will send at most +\f\*[I-Font]num-tries\f[] +queries to +\fCntpd\f[]\fR(8)\f[], +sleeping for +\f\*[I-Font]secs-between-tries\f[] +after each status return that says +\fCntpd\f[]\fR(8)\f[] +has not yet produced a synchronized and stable system clock. +.sp \n(Ppu +.ne 2 + +\f\*[B-Font]ntp-wait\fP +will do this quietly, unless the +\f\*[B-Font]\-v\f[] +flag is provided. +This can be useful at boot time, to delay the boot sequence until after +\f\*[I-Font]ntpd\f[] \f\*[I-Font]\-g\f[] +has set the time. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-n\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-tries\f[]=\f\*[I-Font]number\f[] +Number of times to check ntpd. +This option takes an integer number as its argument. +The default +\f\*[I-Font]number\f[] +for this option is: +.ti +4 + 100 +.sp + The maximum number of times we will check \fBntpd\fP to see if + it has been able to synchronize and stabilize the system clock. +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]secs\-between\-tries\f[], \f\*[B-Font]\-\-sleep\f[]=\f\*[I-Font]secs\-between\-tries\f[] +How long to sleep between tries. +This option takes an integer number as its argument. +The default +\f\*[I-Font]secs\-between\-tries\f[] +for this option is: +.ti +4 + 6 +.sp + We will sleep for \fIsecs-between-tries\fP after each query + of \fBntpd\fP that returns "the time is not yet stable". +.TP +.NOP \f\*[B-Font]\-v\f[], \f\*[B-Font]\-\-verbose\f[] +Be verbose. +.sp + By default, \fBntp-wait\fP is silent. + With this option, \fBntp-wait\fP will provide status information. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH AUTHORS +.NOP "Harlan Stenn" +.br +.SH NOTES +This document corresponds to version @VERSION@ of NTP. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntp-wait\fP +option definitions. diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitmdoc b/contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitmdoc new file mode 100644 index 000000000..aedeec866 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait.1ntp-waitmdoc @@ -0,0 +1,95 @@ +.Dd October 21 2015 +.Dt NTP_WAIT 1ntp-waitmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntp-wait-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:14 PM by AutoGen 5.18.5 +.\" From the definitions ntp-wait-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntp-wait +.Nd Wait for ntpd to stabilize the system clock +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.Nm +will send at most +.Ar num\-tries +queries to +.Xr ntpd 8 , +sleeping for +.Ar secs\-between\-tries +after each status return that says +.Xr ntpd 8 +has not yet produced a synchronized and stable system clock. +.Pp +.Nm +will do this quietly, unless the +.Fl v +flag is provided. +This can be useful at boot time, to delay the boot sequence until after +.Ar ntpd \-g +has set the time. +.Sh "OPTIONS" +.Bl -tag +.It Fl n Ar number , Fl \-tries Ns = Ns Ar number +Number of times to check ntpd. +This option takes an integer number as its argument. +The default +.Ar number +for this option is: +.ti +4 + 100 +.sp + The maximum number of times we will check \fBntpd\fP to see if + it has been able to synchronize and stabilize the system clock. +.It Fl s Ar secs\-between\-tries , Fl \-sleep Ns = Ns Ar secs\-between\-tries +How long to sleep between tries. +This option takes an integer number as its argument. +The default +.Ar secs\-between\-tries +for this option is: +.ti +4 + 6 +.sp + We will sleep for \fIsecs\-between\-tries\fP after each query + of \fBntpd\fP that returns "the time is not yet stable". +.It Fl v , Fl \-verbose +Be verbose. +.sp + By default, \fBntp\-wait\fP is silent. + With this option, \fBntp\-wait\fP will provide status information. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh AUTHORS +.An "Harlan Stenn" +.Sh NOTES +This document corresponds to version @VERSION@ of NTP. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntp\-wait\fP +option definitions. diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait.html b/contrib/ntp/scripts/ntp-wait/ntp-wait.html new file mode 100644 index 000000000..1a9ca501e --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait.html @@ -0,0 +1,208 @@ + + +Ntp-wait User's Manual + + + + + + + + + +

      Ntp-wait User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      This document describes the use of the NTP Project's ntp-wait program. + +

      If there are time-sensitive applications, +the proper sequence of events is to +run ntpd -g as early as possible, +then invoke all of the non-time-sensitive process, +run ntp-wait to block +until the system's time has stabilized and synchronized, +and only then start any applicaitons (like database servers) that require +accurate and stable time. + +

      This document applies to version 4.2.8p4 of ntp-wait. + +

      +

      Short Contents

      +
        +
      +
      + + + +
      +


      + +
      +
      + +

      0.1 Invoking ntp-wait

      + +

      + +

      ntp-wait +will send at most +num-tries +queries to +ntpd(8), +sleeping for +secs-between-tries +after each status return that says +ntpd(8) +has not yet produced a synchronized and stable system clock. + +

      ntp-wait +will do this quietly, unless the +-v +flag is provided. +This can be useful at boot time, to delay the boot sequence until after +ntpd -g +has set the time. + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntp-wait program. + +

      + +
      +


      +Next: , +Up: ntp-wait Invocation +
      +
      + +

      0.1.1 ntp-wait help/usage (--help)

      + +

      +This is the automatically generated usage text for ntp-wait. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      ntp-wait - Wait for ntpd to stabilize the system clock - Ver. 4.2.8p4
      +USAGE: ntp-wait [ -<flag> [<val>] | --<name>[{=| }<val>] ]...
      +
      +    -n, --tries=num              Number of times to check ntpd
      +    -s, --sleep=num              How long to sleep between tries
      +    -v, --verbose                Be verbose
      +    -?, --help                   Display usage information and exit
      +        --more-help              Pass the extended usage text through a pager
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      +
      +


      +Next: , +Previous: ntp-wait usage, +Up: ntp-wait Invocation +
      +
      + +

      0.1.2 tries option (-n)

      + +

      +This is the “number of times to check ntpd” option. +This option takes a number argument. + The maximum number of times we will check ntpd to see if + it has been able to synchronize and stabilize the system clock. +

      +


      +Next: , +Previous: ntp-wait tries, +Up: ntp-wait Invocation +
      +
      + +

      0.1.3 sleep option (-s)

      + +

      +This is the “how long to sleep between tries” option. +This option takes a number argument secs-between-tries. + We will sleep for secs-between-tries after each query + of ntpd that returns "the time is not yet stable". +

      +


      +Next: , +Previous: ntp-wait sleep, +Up: ntp-wait Invocation +
      +
      + +

      0.1.4 verbose option (-v)

      + +

      +This is the “be verbose” option. + By default, ntp-wait is silent. + With this option, ntp-wait will provide status information. +

      +


      +Next: , +Previous: ntp-wait verbose, +Up: ntp-wait Invocation +
      +
      + +

      0.1.5 ntp-wait exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      +
      +


      +Next: , +Previous: ntp-wait exit status, +Up: ntp-wait Invocation +
      +
      + +

      0.1.6 ntp-wait Authors

      + +
      +


      +Previous: ntp-wait Authors, +Up: ntp-wait Invocation +
      +
      + +

      0.1.7 ntp-wait Notes

      + + + diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait.in b/contrib/ntp/scripts/ntp-wait/ntp-wait.in new file mode 100644 index 000000000..b35828a16 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait.in @@ -0,0 +1,66 @@ +#! @PATH_PERL@ + +package ntp_wait; +use 5.006_000; +use strict; +use warnings; +use lib "@PERLLIBDIR@"; +use NTP::Util qw(ntp_read_vars); + +exit run(@ARGV) unless caller; + +sub run { + my $opts; + if (!processOptions(\@_, $opts)) { + usage(1); + }; + + my $tries = $opts->{tries}; # How many tries before we give up? (10 min+) + my $sleep = $opts->{sleep}; # Seconds to sleep between tries (6s = 10/min) + my $verbose = $opts->{verbose}; # Be verbose? + + # Autoflush stdout + $| = 1; + + print "Waiting for ntpd to synchronize... " if $verbose; + + for my $i (1 .. $tries) { + my $info = ntp_read_vars(0, []); + + if (!defined $info) { + print "\bntpd is not running!\n" if $verbose; + return 1; + } + + if (!exists $info->{status_line}{leap}) { + print "\bLeap status not avalaible\n"; + return 1; + } + + my $leap = $info->{status_line}{leap}; + my $sync = $info->{status_line}{sync}; + + if ($leap =~ /(sync|leap)_alarm/) { + print "\b".(substr "*+:.", $i % 4, 1) if $verbose; + sleep $sleep if $i < $tries; + next; + } + + if ($leap =~ /leap_(none|((add|del)_sec))/) { + # We could check $sync here to make sure we like the source... + print "\bOK!\n" if $verbose; + return 0; + } + + print "\bUnexpected 'leap' status <$leap>\n"; + return 1; + } + + print "\bNo!\nntpd did not synchronize.\n" if $verbose; + return 1; +} + +@ntp_wait_opts@ + +1; +__END__ diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait.man.in b/contrib/ntp/scripts/ntp-wait/ntp-wait.man.in new file mode 100644 index 000000000..12395fce2 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait.man.in @@ -0,0 +1,122 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntp-wait @NTP_WAIT_MS@ "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-fzaONA/ag-rzaWMA) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:08 PM by AutoGen 5.18.5 +.\" From the definitions ntp-wait-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntp-wait\fP +\- Wait for ntpd to stabilize the system clock +.SH SYNOPSIS +\f\*[B-Font]ntp-wait\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntp-wait\fP +will send at most +\f\*[I-Font]num-tries\f[] +queries to +\fCntpd\f[]\fR(8)\f[], +sleeping for +\f\*[I-Font]secs-between-tries\f[] +after each status return that says +\fCntpd\f[]\fR(8)\f[] +has not yet produced a synchronized and stable system clock. +.sp \n(Ppu +.ne 2 + +\f\*[B-Font]ntp-wait\fP +will do this quietly, unless the +\f\*[B-Font]\-v\f[] +flag is provided. +This can be useful at boot time, to delay the boot sequence until after +\f\*[I-Font]ntpd\f[] \f\*[I-Font]\-g\f[] +has set the time. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-n\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-tries\f[]=\f\*[I-Font]number\f[] +Number of times to check ntpd. +This option takes an integer number as its argument. +The default +\f\*[I-Font]number\f[] +for this option is: +.ti +4 + 100 +.sp + The maximum number of times we will check \fBntpd\fP to see if + it has been able to synchronize and stabilize the system clock. +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]secs\-between\-tries\f[], \f\*[B-Font]\-\-sleep\f[]=\f\*[I-Font]secs\-between\-tries\f[] +How long to sleep between tries. +This option takes an integer number as its argument. +The default +\f\*[I-Font]secs\-between\-tries\f[] +for this option is: +.ti +4 + 6 +.sp + We will sleep for \fIsecs-between-tries\fP after each query + of \fBntpd\fP that returns "the time is not yet stable". +.TP +.NOP \f\*[B-Font]\-v\f[], \f\*[B-Font]\-\-verbose\f[] +Be verbose. +.sp + By default, \fBntp-wait\fP is silent. + With this option, \fBntp-wait\fP will provide status information. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH AUTHORS +.NOP "Harlan Stenn" +.br +.SH NOTES +This document corresponds to version @VERSION@ of NTP. +.sp \n(Ppu +.ne 2 + +This manual page was \fIAutoGen\fP-erated from the \fBntp-wait\fP +option definitions. diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait.mdoc.in b/contrib/ntp/scripts/ntp-wait/ntp-wait.mdoc.in new file mode 100644 index 000000000..079828224 --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait.mdoc.in @@ -0,0 +1,95 @@ +.Dd October 21 2015 +.Dt NTP_WAIT @NTP_WAIT_MS@ User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntp-wait-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:14 PM by AutoGen 5.18.5 +.\" From the definitions ntp-wait-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntp-wait +.Nd Wait for ntpd to stabilize the system clock +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.Nm +will send at most +.Ar num\-tries +queries to +.Xr ntpd 8 , +sleeping for +.Ar secs\-between\-tries +after each status return that says +.Xr ntpd 8 +has not yet produced a synchronized and stable system clock. +.Pp +.Nm +will do this quietly, unless the +.Fl v +flag is provided. +This can be useful at boot time, to delay the boot sequence until after +.Ar ntpd \-g +has set the time. +.Sh "OPTIONS" +.Bl -tag +.It Fl n Ar number , Fl \-tries Ns = Ns Ar number +Number of times to check ntpd. +This option takes an integer number as its argument. +The default +.Ar number +for this option is: +.ti +4 + 100 +.sp + The maximum number of times we will check \fBntpd\fP to see if + it has been able to synchronize and stabilize the system clock. +.It Fl s Ar secs\-between\-tries , Fl \-sleep Ns = Ns Ar secs\-between\-tries +How long to sleep between tries. +This option takes an integer number as its argument. +The default +.Ar secs\-between\-tries +for this option is: +.ti +4 + 6 +.sp + We will sleep for \fIsecs\-between\-tries\fP after each query + of \fBntpd\fP that returns "the time is not yet stable". +.It Fl v , Fl \-verbose +Be verbose. +.sp + By default, \fBntp\-wait\fP is silent. + With this option, \fBntp\-wait\fP will provide status information. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh AUTHORS +.An "Harlan Stenn" +.Sh NOTES +This document corresponds to version @VERSION@ of NTP. +.Pp +This manual page was \fIAutoGen\fP\-erated from the \fBntp\-wait\fP +option definitions. diff --git a/contrib/ntp/scripts/ntp-wait/ntp-wait.texi b/contrib/ntp/scripts/ntp-wait/ntp-wait.texi new file mode 100644 index 000000000..208639b3d --- /dev/null +++ b/contrib/ntp/scripts/ntp-wait/ntp-wait.texi @@ -0,0 +1,52 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntp-wait.info +@settitle Ntp-wait User's Manual +@include ../../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of @code{ntp-wait}, +a program from +the NTP Project, +that is used to wait until @code{ntpd} has been able to +synchronize and stabilize the time on the current host. +@end ifinfo + +@direntry +* ntp-wait: (ntp-wait). Wait for ntpd to synchronize and stabilize the system clock. +@end direntry + +@titlepage +@title ntp-wait User's Manual +@subtitle ntp-wait, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, ntp-wait Description, (dir), (dir) + +This document describes the use of the NTP Project's @code{ntp-wait} program. + +If there are time-sensitive applications, +the proper sequence of events is to +run @code{ntpd -g} as early as possible, +then invoke all of the non-time-sensitive process, +run @code{ntp-wait} to block +until the system's time has stabilized and synchronized, +and only then start any applicaitons (like database servers) that require +accurate and stable time. + +This document applies to version @value{VERSION} of @code{ntp-wait}. + +@shortcontents + +@menu +* ntp-wait Description:: Description +* ntp-wait Invocation:: Invoking ntp-wait +@end menu + +@include invoke-ntp-wait.texi diff --git a/contrib/ntp/scripts/ntpsweep.in b/contrib/ntp/scripts/ntpsweep.in deleted file mode 100644 index e503a0637..000000000 --- a/contrib/ntp/scripts/ntpsweep.in +++ /dev/null @@ -1,300 +0,0 @@ -#! @PATH_PERL@ -w -# -# $Id$ -# -# DISCLAIMER -# -# Copyright (C) 1999,2000 Hans Lambermont and Origin B.V. -# -# Permission to use, copy, modify and distribute this software and its -# documentation for any purpose and without fee is hereby granted, -# provided that the above copyright notice appears in all copies and -# that both the copyright notice and this permission notice appear in -# supporting documentation. This software is supported as is and without -# any express or implied warranties, including, without limitation, the -# implied warranties of merchantability and fitness for a particular -# purpose. The name Origin B.V. must not be used to endorse or promote -# products derived from this software without prior written permission. -# -# Hans Lambermont - -require 5.0; # But actually tested on 5.004 ;) -use Getopt::Long; # GetOptions() -use strict; - -my $version = 1.3; -(my $program = $0) =~ s%.*/(.+?)(.pl)?$%$1%; - -# Hardcoded paths/program names -my $ntpdate = "ntpdate"; -my $ntpq = "ntpq"; - -# no STDOUT buffering -$| = 1; - -my ($help, $single_host, $showpeers, $maxlevel, $strip, $askversion); -my $res = GetOptions("help!" => \$help, - "host=s" => \$single_host, - "peers!" => \$showpeers, - "maxlevel=s" => \$maxlevel, - "strip=s" => \$strip, - "version!" => \$askversion); - -if ($askversion) { - print("$version\n"); - exit 0; -} - -if ($help || ((@ARGV != 1) && !$single_host)) { - warn <|--maxlevel |--version] \\ - |[--host ] - -Description: - $program prints per host given in the NTP stratum level, the - clock offset in seconds, the daemon version, the operating system and - the processor. Optionally recursing through all peers. - -Options: ---help - Print this short help text and exit. ---version - Print version ($version) and exit. - - Specify hosts file. File format is one hostname or ip number per line. - Lines beginning with # are considered as comment. ---host - Speficy a single host, bypassing the need for a hosts file. ---peers - Recursively list all peers a host synchronizes to. - An '= ' before a peer means a loop. Recursion stops here. ---maxlevel - Traverse peers up to this level (4 is a reasonable number). ---strip - Strip from hostnames. - -Examples: - $program myhosts.txt --strip .foo.com - $program --host some.host --peers --maxlevel 4 -EOF - exit 1; -} - -my $hostsfile = shift; -my (@hosts, @known_hosts); -my (%known_host_info, %known_host_peers); - -sub read_hosts() -{ - local *HOSTS; - open (HOSTS, $hostsfile) || - die "$program: FATAL: unable to read $hostsfile: $!\n"; - while () { - next if /^\s*(#|$)/; # comment/empty - chomp; - push(@hosts, $_); - } - close(HOSTS); -} - -# translate IP to hostname if possible -sub ip2name { - my($ip) = @_; - my($addr, $name, $aliases, $addrtype, $length, @addrs); - $addr = pack('C4', split(/\./, $ip)); - ($name, $aliases, $addrtype, $length, @addrs) = gethostbyaddr($addr, 2); - if ($name) { - # return lower case name - return("\L$name"); - } else { - return($ip); - } -} - -# item_in_list($item, @list): returns 1 if $item is in @list, 0 if not -sub item_in_list { - my($item, @list) = @_; - my($i); - foreach $i (@list) { - return 1 if ($item eq $i); - } - return 0; -} - -sub scan_host($;$;$) { - my($host, $level, @trace) = @_; - my $stratum = 0; - my $offset = 0; - my $daemonversion = ""; - my $system = ""; - my $processor = ""; - my @peers; - my $known_host = 0; - - if (&item_in_list($host, @known_hosts)) { - $known_host = 1; - } else { - # ntpdate part - open(NTPDATE, "$ntpdate -bd $host 2>/dev/null |") || - die "Cannot open ntpdate pipe: $!\n"; - while () { - /^stratum\s+(\d+).*$/ && do { - $stratum = $1; - }; - /^offset\s+([0-9.-]+)$/ && do { - $offset = $1; - }; - } - close(NTPDATE); - - # got answers ? If so, go on. - if ($stratum) { - # ntpq part - my $ntpqparams = "-c 'rv 0 processor,system,daemon_version'"; - open(NTPQ, "$ntpq $ntpqparams $host 2>/dev/null |") || - die "Cannot open ntpq pipe: $!\n"; - while () { - /daemon_version="(.*)"/ && do { - $daemonversion = $1; - }; - /system="([^"]*)"/ && do { - $system = $1; - }; - /processor="([^"]*)"/ && do { - $processor = $1; - }; - } - close(NTPQ); - - # Shorten daemon_version string. - $daemonversion =~ s/(;|Mon|Tue|Wed|Thu|Fri|Sat|Sun).*$//; - $daemonversion =~ s/version=//; - $daemonversion =~ s/(x|)ntpd //; - $daemonversion =~ s/(\(|\))//g; - $daemonversion =~ s/beta/b/; - $daemonversion =~ s/multicast/mc/; - - # Shorten system string - $system =~ s/UNIX\///; - $system =~ s/RELEASE/r/; - $system =~ s/CURRENT/c/; - - # Shorten processor string - $processor =~ s/unknown//; - } - - # got answers ? If so, go on. - if ($daemonversion) { - # ntpq again, find out the peers this time - if ($showpeers) { - my $ntpqparams = "-pn"; - open(NTPQ, "$ntpq $ntpqparams $host 2>/dev/null |") || - die "Cannot open ntpq pipe: $!\n"; - while () { - /^No association ID's returned$/ && do { - last; - }; - /^ remote/ && do { - next; - }; - /^==/ && do { - next; - }; - /^( |x|\.|-|\+|#|\*|o)([^ ]+)/ && do { - push(@peers, ip2name($2)); - next; - }; - print "ERROR: $_"; - } - close(NTPQ); - } - } - - # Add scanned host to known_hosts array - push(@known_hosts, $host); - if ($stratum) { - $known_host_info{$host} = sprintf("%2d %9.3f %-11s %-12s %s", - $stratum, $offset, substr($daemonversion,0,11), - substr($system,0,12), substr($processor,0,9)); - } else { - # Stratum level 0 is consider invalid - $known_host_info{$host} = sprintf(" ?"); - } - $known_host_peers{$host} = [@peers]; - } - - if ($stratum || $known_host) { # Valid or known host - my $printhost = ' ' x $level . $host; - # Shorten host string - if ($strip) { - $printhost =~ s/$strip//; - } - # append number of peers in brackets if requested and valid - if ($showpeers && ($known_host_info{$host} ne " ?")) { - $printhost .= " (" . @{$known_host_peers{$host}} . ")"; - } - # Finally print complete host line - printf("%-32s %s\n", - substr($printhost,0,32), $known_host_info{$host}); - if ($showpeers && (eval($maxlevel ? $level < $maxlevel : 1))) { - my $peer; - push(@trace, $host); - # Loop through peers - foreach $peer (@{$known_host_peers{$host}}) { - if (&item_in_list($peer, @trace)) { - # we've detected a loop ! - $printhost = ' ' x ($level + 1) . "= " . $peer; - # Shorten host string - if ($strip) { - $printhost =~ s/$strip//; - } - printf("%-32s %s\n", - substr($printhost,0,32)); - } else { - if (substr($peer,0,3) ne "127") { - &scan_host($peer, $level + 1, @trace); - } - } - } - } - } else { # We did not get answers from this host - my $printhost = ' ' x $level . $host; - # Shorten host string - if ($strip) { - $printhost =~ s/$strip//; - } - printf("%-32s ?\n", substr($printhost,0,32)); - } -} - -sub scan_hosts() -{ - my $host; - for $host (@hosts) { - my @trace; - push(@trace, $host); - scan_host($host, 0, @trace); - } -} - -# Main program - -if ($single_host) { - push(@hosts, $single_host); -} else { - &read_hosts($hostsfile); -} - -# Print header -print < $(srcdir)/ntpsweep.man.in+ + mv $(srcdir)/ntpsweep.man.in+ $(srcdir)/ntpsweep.man.in + +### Mdoc + +$(srcdir)/ntpsweep.1ntpsweepmdoc: ntpsweep-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpsweepmdoc -Tagmdoc-cmd.tpl ntpsweep-opts.def + +$(srcdir)/ntpsweep.mdoc.in: ntpsweep.1ntpsweepmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpsweep.1ntpsweepmdoc > $(srcdir)/ntpsweep.mdoc.in+ + mv $(srcdir)/ntpsweep.mdoc.in+ $(srcdir)/ntpsweep.mdoc.in + +### Manpage + +ntpsweep.1: ntpsweep.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpsweep.1+:$(srcdir)/ntpsweep.$(MANTAGFMT).in + mv ntpsweep.1+ ntpsweep.1 + +### Texinfo + +$(srcdir)/invoke-ntpsweep.menu: invoke-ntpsweep.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpsweep.texi: ntpsweep-opts ntpsweep-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpsweep-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/ntpsweep.html: invoke-ntpsweep.menu invoke-ntpsweep.texi ntpsweep.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntpsweep.html ntpsweep.texi || true ) diff --git a/contrib/ntp/scripts/ntpsweep/Makefile.in b/contrib/ntp/scripts/ntpsweep/Makefile.in new file mode 100644 index 000000000..337340ca7 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/Makefile.in @@ -0,0 +1,982 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = scripts/ntpsweep +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = ntpsweep +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +SCRIPTS = $(bin_SCRIPTS) $(libexec_SCRIPTS) $(noinst_SCRIPTS) \ + $(sbin_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 +NROFF = nroff +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/ntpsweep.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" PERL5LIB="$(abs_top_srcdir)/scripts/lib" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +bin_SCRIPTS = $(NTPSWEEP_DB) +sbin_SCRIPTS = $(NTPSWEEP_DS) +libexec_SCRIPTS = $(NTPSWEEP_DL) +noinst_SCRIPTS = $(NTPSWEEP_NI) +EXTRA_SCRIPTS = ntpsweep +man1_MANS = +man8_MANS = +@INSTALL_NTPSWEEP_TRUE@man_MANS = ntpsweep.$(NTPSWEEP_MS) +@INSTALL_NTPSWEEP_FALSE@noinst_MANS = ntpsweep.$(NTPSWEEP_MS) +EXTRA_DIST = \ + ntpsweep.in \ + ntpsweep.1ntpsweepman \ + ntpsweep.1ntpsweepmdoc \ + ntpsweep.man.in \ + ntpsweep.mdoc.in \ + ntpsweep.texi \ + ntpsweep.html \ + ntpsweep-opts.def \ + ntpsweep-opts \ + invoke-ntpsweep.texi \ + invoke-ntpsweep.menu \ + $(NULL) + +html_DATA = ntpsweep.html +CLEANFILES = ntpsweep.1 +DISTCLEANFILES = config.log $(man_MANS) $(noinst_MANS) +noinst_DATA = \ + ntpsweep.1 \ + ntpsweep.1ntpsweepman \ + ntpsweep.1ntpsweepmdoc \ + ntpsweep.man.in \ + ntpsweep.mdoc.in \ + ntpsweep.texi \ + ntpsweep.html \ + ntpsweep-opts.def \ + ntpsweep-opts \ + invoke-ntpsweep.texi \ + invoke-ntpsweep.menu \ + $(NULL) + +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/ntpsweep/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign scripts/ntpsweep/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +ntpsweep: $(top_builddir)/config.status $(srcdir)/ntpsweep.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +install-binSCRIPTS: $(bin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir) +install-libexecSCRIPTS: $(libexec_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(libexecdir)'; $(am__uninstall_files_from_dir) +install-sbinSCRIPTS: $(sbin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(sbindir)'; $(am__uninstall_files_from_dir) + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-man1: $(man1_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(SCRIPTS) $(MANS) $(DATA) +installdirs: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-htmlDATA install-man + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-binSCRIPTS install-libexecSCRIPTS \ + install-sbinSCRIPTS + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: install-man1 install-man8 + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-binSCRIPTS uninstall-htmlDATA \ + uninstall-libexecSCRIPTS uninstall-man uninstall-sbinSCRIPTS + +uninstall-man: uninstall-man1 uninstall-man8 + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-binSCRIPTS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-htmlDATA \ + install-info install-info-am install-libexecSCRIPTS \ + install-man install-man1 install-man8 install-pdf \ + install-pdf-am install-ps install-ps-am install-sbinSCRIPTS \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags-am uninstall uninstall-am uninstall-binSCRIPTS \ + uninstall-htmlDATA uninstall-libexecSCRIPTS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinSCRIPTS + +.PRECIOUS: Makefile + + +ntpsweep: $(srcdir)/ntpsweep-opts + +$(srcdir)/ntpsweep-opts: ntpsweep-opts.def $(std_def_list) + $(run_ag) ntpsweep-opts.def + +### Nroff + +$(srcdir)/ntpsweep.1ntpsweepman: ntpsweep-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpsweepman -Tagman-cmd.tpl ntpsweep-opts.def + +$(srcdir)/ntpsweep.man.in: ntpsweep.1ntpsweepman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpsweep.1ntpsweepman > $(srcdir)/ntpsweep.man.in+ + mv $(srcdir)/ntpsweep.man.in+ $(srcdir)/ntpsweep.man.in + +### Mdoc + +$(srcdir)/ntpsweep.1ntpsweepmdoc: ntpsweep-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntpsweepmdoc -Tagmdoc-cmd.tpl ntpsweep-opts.def + +$(srcdir)/ntpsweep.mdoc.in: ntpsweep.1ntpsweepmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntpsweep.1ntpsweepmdoc > $(srcdir)/ntpsweep.mdoc.in+ + mv $(srcdir)/ntpsweep.mdoc.in+ $(srcdir)/ntpsweep.mdoc.in + +### Manpage + +ntpsweep.1: ntpsweep.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntpsweep.1+:$(srcdir)/ntpsweep.$(MANTAGFMT).in + mv ntpsweep.1+ ntpsweep.1 + +### Texinfo + +$(srcdir)/invoke-ntpsweep.menu: invoke-ntpsweep.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntpsweep.texi: ntpsweep-opts ntpsweep-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntpsweep-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/ntpsweep.html: invoke-ntpsweep.menu invoke-ntpsweep.texi ntpsweep.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntpsweep.html ntpsweep.texi || true ) + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.menu b/contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.menu new file mode 100644 index 000000000..6a1faea64 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.menu @@ -0,0 +1 @@ +* ntpsweep Invocation:: Invoking ntpsweep diff --git a/contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.texi b/contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.texi new file mode 100644 index 000000000..5a2112da9 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/invoke-ntpsweep.texi @@ -0,0 +1,118 @@ +@node ntpsweep Invocation +@section Invoking ntpsweep +@pindex ntpsweep +@cindex Print various informations about given ntp servers +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntpsweep.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:18 PM by AutoGen 5.18.5 +# From the definitions ntpsweep-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + +@code{ntpsweep} +prints per host the NTP stratum level, the clock offset in seconds, the daemon +version, the operating system and the processor. Optionally recursing through +all peers. + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntpsweep} program. + +@menu +* ntpsweep usage:: ntpsweep help/usage (@option{--help}) +* ntpsweep host-list:: host-list option (-l) +* ntpsweep peers:: peers option (-p) +* ntpsweep maxlevel:: maxlevel option (-m) +* ntpsweep strip:: strip option (-s) +* ntpsweep host:: host option (-h) +* ntpsweep exit status:: exit status +@end menu + +@node ntpsweep usage +@subsection ntpsweep help/usage (@option{--help}) +@cindex ntpsweep help + +This is the automatically generated usage text for ntpsweep. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +ntpsweep - Print various informations about given ntp servers - Ver. 4.2.8p4 +USAGE: ntpsweep [ - [] | --[@{=| @}] ]... [hostfile] + + -l, --host-list=str Host to execute actions on + - may appear multiple times + -p, --peers Recursively list all peers a host synchronizes to + -m, --maxlevel=num Traverse peers up to this level (4 is a reasonable number) + -s, --strip=str Strip this string from hostnames + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +@end example +@exampleindent 4 + +@node ntpsweep host-list +@subsection host-list option (-l) +@cindex ntpsweep-host-list + +This is the ``host to execute actions on'' option. +This option takes a string argument. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + + Use this option to specify the host on which this script operates. + May appear multiple times. +@node ntpsweep peers +@subsection peers option (-p) +@cindex ntpsweep-peers + +This is the ``recursively list all peers a host synchronizes to'' option. +This option has no @samp{doc} documentation. +@node ntpsweep maxlevel +@subsection maxlevel option (-m) +@cindex ntpsweep-maxlevel + +This is the ``traverse peers up to this level (4 is a reasonable number)'' option. +This option takes a number argument. +This option has no @samp{doc} documentation. +@node ntpsweep strip +@subsection strip option (-s) +@cindex ntpsweep-strip + +This is the ``strip this string from hostnames'' option. +This option takes a string argument. +This option has no @samp{doc} documentation. +@node ntpsweep host +@subsection host option (-h) +@cindex ntpsweep-host + +This is the ``specify a single host'' option. +This option takes a string argument. +This option has no @samp{doc} documentation. + +@strong{NOTE}@strong{: THIS OPTION IS DEPRECATED} +@node ntpsweep exit status +@subsection ntpsweep exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep-opts b/contrib/ntp/scripts/ntpsweep/ntpsweep-opts new file mode 100644 index 000000000..54d7f0d38 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep-opts @@ -0,0 +1,67 @@ +# EDIT THIS FILE WITH CAUTION (ntpsweep-opts) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:16 PM by AutoGen 5.18.5 +# From the definitions ntpsweep-opts.def +# and the template file perlopt + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + 'host-list' => [], + 'peers' => '', + 'maxlevel' => '', + 'strip' => '', + 'host' => '', + 'help' => '', 'more-help' => '' + }; + my $argument = '[hostfile]'; + my $ret = GetOptionsFromArray($args, $opts, ( + 'host-list|l=s', 'peers|p', 'maxlevel|m=i', + 'strip|s=s', 'host|h=s', + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +ntpsweep - Print various informations about given ntp servers - Ver. 4.2.8p4 +USAGE: ntpsweep [ - [] | --[{=| }] ]... [hostfile] + + -l, --host-list=str Host to execute actions on + - may appear multiple times + -p, --peers Recursively list all peers a host synchronizes to + -m, --maxlevel=num Traverse peers up to this level (4 is a reasonable number) + -s, --strip=str Strip this string from hostnames + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'}; + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep-opts.def b/contrib/ntp/scripts/ntpsweep/ntpsweep-opts.def new file mode 100644 index 000000000..23dc020e9 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep-opts.def @@ -0,0 +1,66 @@ +/* -*- Mode: Text -*- */ +autogen definitions perlopt; + +#include autogen-version.def + +prog-name = 'ntpsweep'; +prog-title = 'Print various informations about given ntp servers'; +package = ntp; +#include version.def + +argument = '[hostfile]'; +long-opts; +gnu-usage; + +flag = { + name = host-list; + value = l; + arg-type = string; + max = NOLIMIT; + stack-arg; + descrip = 'Host to execute actions on'; + doc = <<- _EndOfDoc_ + Use this option to specify the host on which this script operates. + May appear multiple times. + _EndOfDoc_; +}; + +flag = { + name = peers; + value = p; + descrip = 'Recursively list all peers a host synchronizes to'; +}; + +flag = { + name = maxlevel; + value = m; + arg-type = number; + descrip = 'Traverse peers up to this level (4 is a reasonable number)'; +}; + +flag = { + name = strip; + value = s; + arg-type = string; + descrip = 'Strip this string from hostnames'; +}; + +/* Deprecated options */ +flag = { + name = host; + value = h; + arg-type = string; + descrip = 'Specify a single host'; + deprecated; +}; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +.Nm +prints per host the NTP stratum level, the clock offset in seconds, the daemon +version, the operating system and the processor. Optionally recursing through +all peers. + _END_PROG_MDOC_DESCRIP; +}; diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepman b/contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepman new file mode 100644 index 000000000..66deebaac --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepman @@ -0,0 +1,97 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpsweep 1ntpsweepman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-kqaGdC/ag-xqaOcC) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:20 PM by AutoGen 5.18.5 +.\" From the definitions ntpsweep-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpsweep\fP +\- Print various informations about given ntp servers +.SH SYNOPSIS +\f\*[B-Font]ntpsweep\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[hostfile] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntpsweep\fP +prints per host the NTP stratum level, the clock offset in seconds, the daemon +version, the operating system and the processor. Optionally recursing through +all peers. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-l\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-host\-list\f[]=\f\*[I-Font]string\f[] +Host to execute actions on. +This option may appear an unlimited number of times. +.sp + Use this option to specify the host on which this script operates. + May appear multiple times. +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-peers\f[] +Recursively list all peers a host synchronizes to. +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-m\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-maxlevel\f[]=\f\*[I-Font]number\f[] +Traverse peers up to this level (4 is a reasonable number). +This option takes an integer number as its argument. +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-strip\f[]=\f\*[I-Font]string\f[] +Strip this string from hostnames. +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-h\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-host\f[]=\f\*[I-Font]string\f[] +Specify a single host. +.sp +This option has not been fully documented. +.sp +.B +NOTE: THIS OPTION IS DEPRECATED +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntpsweep\fP +option definitions. diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepmdoc b/contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepmdoc new file mode 100644 index 000000000..a0f7e8738 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep.1ntpsweepmdoc @@ -0,0 +1,75 @@ +.Dd October 21 2015 +.Dt NTPSWEEP 1ntpsweepmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpsweep-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:23 PM by AutoGen 5.18.5 +.\" From the definitions ntpsweep-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpsweep +.Nd Print various informations about given ntp servers +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[hostfile] +.Pp +.Sh DESCRIPTION +.Nm +prints per host the NTP stratum level, the clock offset in seconds, the daemon +version, the operating system and the processor. Optionally recursing through +all peers. +.Sh "OPTIONS" +.Bl -tag +.It Fl l Ar string , Fl \-host\-list Ns = Ns Ar string +Host to execute actions on. +This option may appear an unlimited number of times. +.sp + Use this option to specify the host on which this script operates. + May appear multiple times. +.It Fl p , Fl \-peers +Recursively list all peers a host synchronizes to. +.sp +This option has not been fully documented. +.It Fl m Ar number , Fl \-maxlevel Ns = Ns Ar number +Traverse peers up to this level (4 is a reasonable number). +This option takes an integer number as its argument. +.sp +This option has not been fully documented. +.It Fl s Ar string , Fl \-strip Ns = Ns Ar string +Strip this string from hostnames. +.sp +This option has not been fully documented. +.It Fl h Ar string , Fl \-host Ns = Ns Ar string +Specify a single host. +.sp +This option has not been fully documented. +.sp +.B +NOTE: THIS OPTION IS DEPRECATED +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntpsweep\fP +option definitions. diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep.html b/contrib/ntp/scripts/ntpsweep/ntpsweep.html new file mode 100644 index 000000000..fed2e2a23 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep.html @@ -0,0 +1,201 @@ + + +ntpsweep User's Manual + + + + + + + + + +

      ntpsweep User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      This document describes the use of the NTP Project's ntpsweep program. + +

      This document applies to version 4.2.8p4 of ntpsweep. + +

      +

      Short Contents

      +
        +
      +
      + + + +
      +


      + +
      +
      + +

      0.1 Invoking ntpsweep

      + +

      +ntpsweep +prints per host the NTP stratum level, the clock offset in seconds, the daemon +version, the operating system and the processor. Optionally recursing through +all peers. + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntpsweep program. + +

      + + + +

      0.1.1 ntpsweep help/usage (--help)

      + +

      +This is the automatically generated usage text for ntpsweep. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      ntpsweep - Print various informations about given ntp servers - Ver. 4.2.8p4
      +USAGE: ntpsweep [ -<flag> [<val>] | --<name>[{=| }<val>] ]... [hostfile]
      +
      +    -l, --host-list=str          Host to execute actions on
      +                                   - may appear multiple times
      +    -p, --peers                  Recursively list all peers a host synchronizes to
      +    -m, --maxlevel=num           Traverse peers up to this level (4 is a reasonable number)
      +    -s, --strip=str              Strip this string from hostnames
      +    -?, --help                   Display usage information and exit
      +        --more-help              Pass the extended usage text through a pager
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      +
      +


      +Next: , +Previous: ntpsweep usage, +Up: ntpsweep Invocation +
      +
      + +

      0.1.2 host-list option (-l)

      + +

      +This is the “host to execute actions on” option. +This option takes a string argument. + +

      This option has some usage constraints. It: +

        +
      • may appear an unlimited number of times. +
      + +

      Use this option to specify the host on which this script operates. + May appear multiple times. +

      +


      +Next: , +Previous: ntpsweep host-list, +Up: ntpsweep Invocation +
      +
      + +

      0.1.3 peers option (-p)

      + +

      +This is the “recursively list all peers a host synchronizes to” option. +This option has no doc documentation. +

      +


      +Next: , +Previous: ntpsweep peers, +Up: ntpsweep Invocation +
      +
      + +

      0.1.4 maxlevel option (-m)

      + +

      +This is the “traverse peers up to this level (4 is a reasonable number)” option. +This option takes a number argument. +This option has no doc documentation. +

      +


      +Next: , +Previous: ntpsweep maxlevel, +Up: ntpsweep Invocation +
      +
      + +

      0.1.5 strip option (-s)

      + +

      +This is the “strip this string from hostnames” option. +This option takes a string argument. +This option has no doc documentation. +

      +


      +Next: , +Previous: ntpsweep strip, +Up: ntpsweep Invocation +
      +
      + +

      0.1.6 host option (-h)

      + +

      +This is the “specify a single host” option. +This option takes a string argument. +This option has no doc documentation. + +

      NOTE: THIS OPTION IS DEPRECATED +

      +


      +Previous: ntpsweep host, +Up: ntpsweep Invocation +
      +
      + +

      0.1.7 ntpsweep exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      + + + diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep.in b/contrib/ntp/scripts/ntpsweep/ntpsweep.in new file mode 100644 index 000000000..75ac0c8b0 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep.in @@ -0,0 +1,205 @@ +#! @PATH_PERL@ -w +# +# $Id$ +# +# DISCLAIMER +# +# Copyright (C) 1999,2000 Hans Lambermont and Origin B.V. +# +# Permission to use, copy, modify and distribute this software and its +# documentation for any purpose and without fee is hereby granted, +# provided that the above copyright notice appears in all copies and +# that both the copyright notice and this permission notice appear in +# supporting documentation. This software is supported as is and without +# any express or implied warranties, including, without limitation, the +# implied warranties of merchantability and fitness for a particular +# purpose. The name Origin B.V. must not be used to endorse or promote +# products derived from this software without prior written permission. +# +# Hans Lambermont + +package ntpsweep; +use 5.006_000; +use strict; +use lib "@PERLLIBDIR@"; +use NTP::Util qw(do_dns ntp_read_vars ntp_peers ntp_sntp_line); + +(my $program = $0) =~ s%.*/(.+?)(.pl)?$%$1%; +my ($showpeers, $maxlevel, $strip); +my (%known_host_info, %known_host_peers); + +exit run(@ARGV) unless caller; + +sub run { + my $opts; + if (!processOptions(\@_, $opts) || + (((@_ != 1) && !$opts->{host} && !@{$opts->{'host-list'}}))) { + usage(1); + }; + + # no STDOUT buffering + $| = 1; + ($showpeers, $maxlevel, $strip) = + ($opts->{peers}, $opts->{maxlevel}, $opts->{strip}); + + my $hostsfile = shift; + + # Main program + + my @hosts; + + if ($opts->{host}) { + push @hosts, $opts->{host}; + } + else { + @hosts = read_hosts($hostsfile) if $hostsfile; + push @hosts, @{$opts->{'host-list'}}; + } + + # Print header + print < 1); + } +} + +sub read_hosts { + my ($hostsfile) = @_; + my @hosts; + + open my $hosts, $hostsfile + or die "$program: FATAL: unable to read $hostsfile: $!\n"; + + while (<$hosts>) { + next if /^\s*(#|$)/; # comment/empty + chomp; + push @hosts, $_; + } + + close $hosts; + return @hosts; +} + +sub scan_host { + my ($host, $level, %trace) = @_; + my $stratum = 0; + my $offset = 0; + my $daemonversion = ""; + my $system = ""; + my $processor = ""; + my @peers; + my $known_host = 0; + + if (exists $known_host_info{$host}) { + $known_host = 1; + } + else { + ($offset, $stratum) = ntp_sntp_line($host); + + # got answers ? If so, go on. + if ($stratum) { + my $vars = ntp_read_vars(0, [qw(processor system daemon_version)], $host) || {}; + $daemonversion = $vars->{daemon_version}; + $system = $vars->{system}; + $processor = $vars->{processor}; + + # Shorten daemon_version string. + $daemonversion =~ s/(;|Mon|Tue|Wed|Thu|Fri|Sat|Sun).*$//; + $daemonversion =~ s/version=//; + $daemonversion =~ s/(x|)ntpd //; + $daemonversion =~ s/(\(|\))//g; + $daemonversion =~ s/beta/b/; + $daemonversion =~ s/multicast/mc/; + + # Shorten system string + $system =~ s/UNIX\///; + $system =~ s/RELEASE/r/; + $system =~ s/CURRENT/c/; + + # Shorten processor string + $processor =~ s/unknown//; + } + + # got answers ? If so, go on. + if ($daemonversion) { + if ($showpeers) { + my $peers_ref = ntp_peers($host); + my @peers_tmp = @$peers_ref; + for (@peers_tmp) { + $_->{remote} =~ s/^(?: |x|\.|-|\+|#|\*|o)([^ ]+)/$1/; + push @peers, $_->{remote}; + } + } + } + + # Add scanned host to known_hosts array + #push @known_hosts, $host; + if ($stratum) { + $known_host_info{$host} = sprintf "%2d %9.3f %-11s %-12s %s", + $stratum, $offset, (substr $daemonversion, 0, 11), + (substr $system, 0, 12), (substr $processor, 0, 9); + } + else { + # Stratum level 0 is consider invalid + $known_host_info{$host} = " ?"; + } + $known_host_peers{$host} = [@peers]; + } + + if ($stratum || $known_host) { # Valid or known host + my $printhost = ' ' x $level . (do_dns($host) || $host); + # Shorten host string + if ($strip) { + $printhost =~ s/$strip//; + } + # append number of peers in brackets if requested and valid + if ($showpeers && ($known_host_info{$host} ne " ?")) { + $printhost .= " (" . @{$known_host_peers{$host}} . ")"; + } + # Finally print complete host line + printf "%-32s %s\n", + (substr $printhost, 0, 32), $known_host_info{$host}; + if ($showpeers && ($maxlevel ? $level < $maxlevel : 1)) { + $trace{$host} = 1; + # Loop through peers + foreach my $peer (@{$known_host_peers{$host}}) { + if (exists $trace{$peer}) { + # we've detected a loop ! + $printhost = ' ' x ($level + 1) . "= " . $peer; + # Shorten host string + $printhost =~ s/$strip// if $strip; + printf "%-32s\n", substr $printhost, 0, 32; + } else { + if ((substr $peer, 0, 3) ne "127") { + scan_host($peer, $level + 1, %trace); + } + } + } + } + } + else { # We did not get answers from this host + my $printhost = ' ' x $level . (do_dns($host) || $host); + $printhost =~ s/$strip// if $strip; + printf "%-32s ?\n", substr $printhost, 0, 32; + } +} + +@ntpsweep_opts@ + +1; +__END__ diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep.man.in b/contrib/ntp/scripts/ntpsweep/ntpsweep.man.in new file mode 100644 index 000000000..66deebaac --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep.man.in @@ -0,0 +1,97 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntpsweep 1ntpsweepman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-kqaGdC/ag-xqaOcC) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:20 PM by AutoGen 5.18.5 +.\" From the definitions ntpsweep-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntpsweep\fP +\- Print various informations about given ntp servers +.SH SYNOPSIS +\f\*[B-Font]ntpsweep\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[hostfile] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]ntpsweep\fP +prints per host the NTP stratum level, the clock offset in seconds, the daemon +version, the operating system and the processor. Optionally recursing through +all peers. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-l\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-host\-list\f[]=\f\*[I-Font]string\f[] +Host to execute actions on. +This option may appear an unlimited number of times. +.sp + Use this option to specify the host on which this script operates. + May appear multiple times. +.TP +.NOP \f\*[B-Font]\-p\f[], \f\*[B-Font]\-\-peers\f[] +Recursively list all peers a host synchronizes to. +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-m\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-maxlevel\f[]=\f\*[I-Font]number\f[] +Traverse peers up to this level (4 is a reasonable number). +This option takes an integer number as its argument. +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-strip\f[]=\f\*[I-Font]string\f[] +Strip this string from hostnames. +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-h\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-host\f[]=\f\*[I-Font]string\f[] +Specify a single host. +.sp +This option has not been fully documented. +.sp +.B +NOTE: THIS OPTION IS DEPRECATED +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntpsweep\fP +option definitions. diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep.mdoc.in b/contrib/ntp/scripts/ntpsweep/ntpsweep.mdoc.in new file mode 100644 index 000000000..a0f7e8738 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep.mdoc.in @@ -0,0 +1,75 @@ +.Dd October 21 2015 +.Dt NTPSWEEP 1ntpsweepmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntpsweep-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:23 PM by AutoGen 5.18.5 +.\" From the definitions ntpsweep-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntpsweep +.Nd Print various informations about given ntp servers +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[hostfile] +.Pp +.Sh DESCRIPTION +.Nm +prints per host the NTP stratum level, the clock offset in seconds, the daemon +version, the operating system and the processor. Optionally recursing through +all peers. +.Sh "OPTIONS" +.Bl -tag +.It Fl l Ar string , Fl \-host\-list Ns = Ns Ar string +Host to execute actions on. +This option may appear an unlimited number of times. +.sp + Use this option to specify the host on which this script operates. + May appear multiple times. +.It Fl p , Fl \-peers +Recursively list all peers a host synchronizes to. +.sp +This option has not been fully documented. +.It Fl m Ar number , Fl \-maxlevel Ns = Ns Ar number +Traverse peers up to this level (4 is a reasonable number). +This option takes an integer number as its argument. +.sp +This option has not been fully documented. +.It Fl s Ar string , Fl \-strip Ns = Ns Ar string +Strip this string from hostnames. +.sp +This option has not been fully documented. +.It Fl h Ar string , Fl \-host Ns = Ns Ar string +Specify a single host. +.sp +This option has not been fully documented. +.sp +.B +NOTE: THIS OPTION IS DEPRECATED +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntpsweep\fP +option definitions. diff --git a/contrib/ntp/scripts/ntpsweep/ntpsweep.texi b/contrib/ntp/scripts/ntpsweep/ntpsweep.texi new file mode 100644 index 000000000..e408065a6 --- /dev/null +++ b/contrib/ntp/scripts/ntpsweep/ntpsweep.texi @@ -0,0 +1,43 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntpsweep.info +@settitle ntpsweep User's Manual +@include ../../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of @code{ntpsweep}, +a program from +the NTP Project, +that is used to wait until @code{ntpd} has been able to +synchronize and stabilize the time on the current host. +@end ifinfo + +@direntry +* ntpsweep: (ntpsweep). Wait for ntpd to synchronize and stabilize the system clock. +@end direntry + +@titlepage +@title ntpsweep User's Manual +@subtitle ntpsweep, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, ntpsweep Description, (dir), (dir) + +This document describes the use of the NTP Project's @code{ntpsweep} program. + +This document applies to version @value{VERSION} of @code{ntpsweep}. + +@shortcontents + +@menu +* ntpsweep Description:: Description +* ntpsweep Invocation:: Invoking ntpsweep +@end menu + +@include invoke-ntpsweep.texi diff --git a/contrib/ntp/scripts/ntptrace.in b/contrib/ntp/scripts/ntptrace.in deleted file mode 100755 index c3c2a20fd..000000000 --- a/contrib/ntp/scripts/ntptrace.in +++ /dev/null @@ -1,70 +0,0 @@ -#! @PATH_PERL@ -w - -# John Hay -- John.Hay@icomtek.csir.co.za / jhay@FreeBSD.org - -use Socket; -use Getopt::Std; -use vars qw($opt_n $opt_m); - -$ntpq = "ntpq"; - -getopts('nm:'); - -$dodns = 1; -$dodns = 0 if (defined($opt_n)); - -$max_hosts = (defined($opt_m) ? $opt_m : 99); -$max_hosts = 0 if ( $max_hosts !~ /^\d+$/ ); -$nb_host = 1; - -$host = shift; -$host ||= "127.0.0.1"; - -for (;;) { - $nb_host++; - $rootdelay = 0; - $rootdispersion = 0; - $stratum = 255; - $cmd = "$ntpq -n -c rv $host"; - open(PH, $cmd . "|") || die "failed to start command $cmd: $!"; - while () { - $stratum = $1 if (/stratum=(\d+)/); - $peer = $1 if (/peer=(\d+)/); - # Very old servers report phase and not offset. - $offset = $1 if (/(?:offset|phase)=([^\s,]+)/); - $rootdelay = $1 if (/rootdelay=([^\s,]+)/); - $rootdispersion = $1 if (/rootdispersion=([^\s,]+)/); - $refid = $1 if (/refid=([^\s,]+)/); - } - close(PH) || die "$cmd failed"; - last if ($stratum == 255); - $offset /= 1000; - $syncdistance = ($rootdispersion + ($rootdelay / 2)) / 1000; - $dhost = $host; - # Only do lookups of IPv4 addresses. The standard lookup functions - # of perl only do IPv4 and I don't know if we should require extras. - if ($dodns && $host =~ /^(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})$/) { - $iaddr = inet_aton($host); - $name = (gethostbyaddr($iaddr, AF_INET))[0]; - $dhost = $name if (defined($name)); - } - printf("%s: stratum %d, offset %f, synch distance %f", - $dhost, $stratum, $offset, $syncdistance); - printf(", refid '%s'", $refid) if ($stratum == 1); - printf("\n"); - last if ($stratum == 0 || $stratum == 1 || $stratum == 16); - last if ($refid =~ /^127\.127\.\d{1,3}\.\d{1,3}$/); - last if ($nb_host > $max_hosts); - - $cmd = "$ntpq -n -c \"pstat $peer\" $host"; - open(PH, $cmd . "|") || die "failed to start command $cmd: $!"; - $thost = ""; - while () { - $thost = $1, last if (/srcadr=(\S+),/); - } - close(PH) || die "$cmd failed"; - last if ($thost eq ""); - last if ($thost =~ /^127\.127\.\d{1,3}\.\d{1,3}$/); - $host = $thost; -} - diff --git a/contrib/ntp/scripts/ntptrace/Makefile.am b/contrib/ntp/scripts/ntptrace/Makefile.am new file mode 100644 index 000000000..19300e8cb --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/Makefile.am @@ -0,0 +1,95 @@ +NULL= +man1_MANS= +man8_MANS= +man_MANS= ntptrace.$(NTPTRACE_MS) + +bin_SCRIPTS = $(NTPTRACE_DB) +libexec_SCRIPTS = $(NTPTRACE_DL) +sbin_SCRIPTS = $(NTPTRACE_DS) + +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" PERL5LIB="$(abs_top_srcdir)/scripts/lib" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +EXTRA_SCRIPTS = ntptrace + +EXTRA_DIST = \ + ntptrace.1ntptraceman \ + ntptrace.1ntptracemdoc \ + ntptrace.mdoc.in \ + ntptrace.man.in \ + ntptrace.texi \ + ntptrace.html \ + ntptrace-opts.def \ + ntptrace-opts \ + invoke-ntptrace.texi \ + invoke-ntptrace.menu \ + $(NULL) + +DISTCLEANFILES = config.log $(man_MANS) + +html_DATA = $(srcdir)/ntptrace.html + +noinst_DATA = \ + ntptrace.1ntptraceman \ + ntptrace.1ntptracemdoc \ + ntptrace.mdoc.in \ + ntptrace.man.in \ + ntptrace.texi \ + ntptrace.html \ + ntptrace-opts.def \ + ntptrace-opts \ + invoke-ntptrace.texi \ + invoke-ntptrace.menu \ + $(NULL) + +ntptrace: $(srcdir)/ntptrace-opts + +$(srcdir)/ntptrace-opts: $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) ntptrace-opts.def + +### Nroff + +$(srcdir)/ntptrace.1ntptraceman: $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntptraceman -Tagman-cmd.tpl ntptrace-opts.def + +$(srcdir)/ntptrace.man.in: $(srcdir)/ntptrace.1ntptraceman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntptrace.1ntptraceman > $(srcdir)/ntptrace.man.in+ + mv $(srcdir)/ntptrace.man.in+ $(srcdir)/ntptrace.man.in + +### Mdoc + +$(srcdir)/ntptrace.1ntptracemdoc: $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntptracemdoc -Tagmdoc-cmd.tpl ntptrace-opts.def + +$(srcdir)/ntptrace.mdoc.in: $(srcdir)/ntptrace.1ntptracemdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntptrace.1ntptracemdoc > $(srcdir)/ntptrace.mdoc.in+ + mv $(srcdir)/ntptrace.mdoc.in+ $(srcdir)/ntptrace.mdoc.in + +### Manpage (local) + +ntptrace.$(NTPTRACE_MS): $(srcdir)/ntptrace.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntptrace.$(NTPTRACE_MS)+:$(srcdir)/ntptrace.$(MANTAGFMT).in + mv ntptrace.$(NTPTRACE_MS)+ ntptrace.$(NTPTRACE_MS) + +### Texinfo + +$(srcdir)/invoke-ntptrace.menu: $(srcdir)/invoke-ntptrace.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntptrace.texi: ntptrace-opts $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntptrace-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/ntptrace.html: $(srcdir)/invoke-ntptrace.menu $(srcdir)/invoke-ntptrace.texi $(srcdir)/ntptrace.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntptrace.html ntptrace.texi || true ) diff --git a/contrib/ntp/scripts/ntptrace/Makefile.in b/contrib/ntp/scripts/ntptrace/Makefile.in new file mode 100644 index 000000000..f8d36ce3a --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/Makefile.in @@ -0,0 +1,975 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = scripts/ntptrace +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = ntptrace +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +SCRIPTS = $(bin_SCRIPTS) $(libexec_SCRIPTS) $(sbin_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 +NROFF = nroff +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/ntptrace.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +man1_MANS = +man8_MANS = +man_MANS = ntptrace.$(NTPTRACE_MS) +bin_SCRIPTS = $(NTPTRACE_DB) +libexec_SCRIPTS = $(NTPTRACE_DL) +sbin_SCRIPTS = $(NTPTRACE_DS) +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" PERL5LIB="$(abs_top_srcdir)/scripts/lib" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +EXTRA_SCRIPTS = ntptrace +EXTRA_DIST = \ + ntptrace.1ntptraceman \ + ntptrace.1ntptracemdoc \ + ntptrace.mdoc.in \ + ntptrace.man.in \ + ntptrace.texi \ + ntptrace.html \ + ntptrace-opts.def \ + ntptrace-opts \ + invoke-ntptrace.texi \ + invoke-ntptrace.menu \ + $(NULL) + +DISTCLEANFILES = config.log $(man_MANS) +html_DATA = $(srcdir)/ntptrace.html +noinst_DATA = \ + ntptrace.1ntptraceman \ + ntptrace.1ntptracemdoc \ + ntptrace.mdoc.in \ + ntptrace.man.in \ + ntptrace.texi \ + ntptrace.html \ + ntptrace-opts.def \ + ntptrace-opts \ + invoke-ntptrace.texi \ + invoke-ntptrace.menu \ + $(NULL) + +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/ntptrace/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign scripts/ntptrace/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +ntptrace: $(top_builddir)/config.status $(srcdir)/ntptrace.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +install-binSCRIPTS: $(bin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir) +install-libexecSCRIPTS: $(libexec_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(libexecdir)'; $(am__uninstall_files_from_dir) +install-sbinSCRIPTS: $(sbin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(sbindir)'; $(am__uninstall_files_from_dir) + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-man1: $(man1_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(SCRIPTS) $(MANS) $(DATA) +installdirs: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-htmlDATA install-man + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-binSCRIPTS install-libexecSCRIPTS \ + install-sbinSCRIPTS + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: install-man1 install-man8 + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-binSCRIPTS uninstall-htmlDATA \ + uninstall-libexecSCRIPTS uninstall-man uninstall-sbinSCRIPTS + +uninstall-man: uninstall-man1 uninstall-man8 + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-binSCRIPTS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-htmlDATA \ + install-info install-info-am install-libexecSCRIPTS \ + install-man install-man1 install-man8 install-pdf \ + install-pdf-am install-ps install-ps-am install-sbinSCRIPTS \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags-am uninstall uninstall-am uninstall-binSCRIPTS \ + uninstall-htmlDATA uninstall-libexecSCRIPTS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinSCRIPTS + +.PRECIOUS: Makefile + + +ntptrace: $(srcdir)/ntptrace-opts + +$(srcdir)/ntptrace-opts: $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) ntptrace-opts.def + +### Nroff + +$(srcdir)/ntptrace.1ntptraceman: $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntptraceman -Tagman-cmd.tpl ntptrace-opts.def + +$(srcdir)/ntptrace.man.in: $(srcdir)/ntptrace.1ntptraceman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntptrace.1ntptraceman > $(srcdir)/ntptrace.man.in+ + mv $(srcdir)/ntptrace.man.in+ $(srcdir)/ntptrace.man.in + +### Mdoc + +$(srcdir)/ntptrace.1ntptracemdoc: $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1ntptracemdoc -Tagmdoc-cmd.tpl ntptrace-opts.def + +$(srcdir)/ntptrace.mdoc.in: $(srcdir)/ntptrace.1ntptracemdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/ntptrace.1ntptracemdoc > $(srcdir)/ntptrace.mdoc.in+ + mv $(srcdir)/ntptrace.mdoc.in+ $(srcdir)/ntptrace.mdoc.in + +### Manpage (local) + +ntptrace.$(NTPTRACE_MS): $(srcdir)/ntptrace.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=ntptrace.$(NTPTRACE_MS)+:$(srcdir)/ntptrace.$(MANTAGFMT).in + mv ntptrace.$(NTPTRACE_MS)+ ntptrace.$(NTPTRACE_MS) + +### Texinfo + +$(srcdir)/invoke-ntptrace.menu: $(srcdir)/invoke-ntptrace.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-ntptrace.texi: ntptrace-opts $(srcdir)/ntptrace-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section ntptrace-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/ntptrace.html: $(srcdir)/invoke-ntptrace.menu $(srcdir)/invoke-ntptrace.texi $(srcdir)/ntptrace.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o ntptrace.html ntptrace.texi || true ) + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/scripts/ntptrace/invoke-ntptrace.menu b/contrib/ntp/scripts/ntptrace/invoke-ntptrace.menu new file mode 100644 index 000000000..bea3b8b23 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/invoke-ntptrace.menu @@ -0,0 +1 @@ +* ntptrace Invocation:: Invoking ntptrace diff --git a/contrib/ntp/scripts/ntptrace/invoke-ntptrace.texi b/contrib/ntp/scripts/ntptrace/invoke-ntptrace.texi new file mode 100644 index 000000000..4360728a6 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/invoke-ntptrace.texi @@ -0,0 +1,109 @@ +@node ntptrace Invocation +@section Invoking ntptrace +@pindex ntptrace +@cindex Trace peers of an NTP server +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-ntptrace.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:30 PM by AutoGen 5.18.5 +# From the definitions ntptrace-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + +@code{ntptrace} is a perl script that uses the ntpq utility program to follow +the chain of NTP servers from a given host back to the primary time source. For +ntptrace to work properly, each of these servers must implement the NTP Control +and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets. + +If given no arguments, ntptrace starts with localhost. Here is an example of +the output from ntptrace: + +@example +% ntptrace localhost: stratum 4, offset 0.0019529, synch distance 0.144135 +server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784 usndh.edu: +stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB' +@end example + +On each line, the fields are (left to right): the host name, the host stratum, +the time offset between that host and the local host (as measured by +@code{ntptrace}; this is why it is not always zero for "localhost"), the host +synchronization distance, and (only for stratum-1 servers) the reference clock +ID. All times are given in seconds. Note that the stratum is the server hop +count to the primary source, while the synchronization distance is the +estimated error relative to the primary source. These terms are precisely +defined in RFC-1305. + + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{ntptrace} program. + +@menu +* ntptrace usage:: ntptrace help/usage (@option{--help}) +* ntptrace numeric:: numeric option (-n) +* ntptrace max-hosts:: max-hosts option (-m) +* ntptrace host:: host option (-r) +* ntptrace exit status:: exit status +@end menu + +@node ntptrace usage +@subsection ntptrace help/usage (@option{--help}) +@cindex ntptrace help + +This is the automatically generated usage text for ntptrace. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +ntptrace - Trace peers of an NTP server - Ver. 4.2.8p4 +USAGE: ntptrace [ - [] | --[@{=| @}] ]... [host] + + -n, --numeric Print IP addresses instead of hostnames + -m, --max-hosts=num Maximum number of peers to trace + -r, --host=str Single remote host + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +@end example +@exampleindent 4 + +@node ntptrace numeric +@subsection numeric option (-n) +@cindex ntptrace-numeric + +This is the ``print ip addresses instead of hostnames'' option. +Output hosts as dotted-quad numeric format rather than converting to +the canonical host names. +@node ntptrace max-hosts +@subsection max-hosts option (-m) +@cindex ntptrace-max-hosts + +This is the ``maximum number of peers to trace'' option. +This option takes a number argument. +This option has no @samp{doc} documentation. +@node ntptrace host +@subsection host option (-r) +@cindex ntptrace-host + +This is the ``single remote host'' option. +This option takes a string argument. +This option has no @samp{doc} documentation. +@node ntptrace exit status +@subsection ntptrace exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table diff --git a/contrib/ntp/scripts/ntptrace/ntptrace-opts b/contrib/ntp/scripts/ntptrace/ntptrace-opts new file mode 100644 index 000000000..d6dbc5333 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace-opts @@ -0,0 +1,62 @@ +# EDIT THIS FILE WITH CAUTION (ntptrace-opts) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:25 PM by AutoGen 5.18.5 +# From the definitions ntptrace-opts.def +# and the template file perlopt + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + 'numeric' => '', + 'max-hosts' => '99', + 'host' => '127.0.0.1', + 'help' => '', 'more-help' => '' + }; + my $argument = '[host]'; + my $ret = GetOptionsFromArray($args, $opts, ( + 'numeric|n', 'max-hosts|m=i', 'host|r=s', + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +ntptrace - Trace peers of an NTP server - Ver. 4.2.8p4 +USAGE: ntptrace [ - [] | --[{=| }] ]... [host] + + -n, --numeric Print IP addresses instead of hostnames + -m, --max-hosts=num Maximum number of peers to trace + -r, --host=str Single remote host + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'}; + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/scripts/ntptrace/ntptrace-opts.def b/contrib/ntp/scripts/ntptrace/ntptrace-opts.def new file mode 100644 index 000000000..81ddda3b2 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace-opts.def @@ -0,0 +1,69 @@ +/* -*- Mode: Text -*- */ +AutoGen Definitions perlopt; + +//#include copyright.def +#include autogen-version.def + +prog-name = 'ntptrace'; +prog-title = 'Trace peers of an NTP server'; +package = ntp; +#include version.def +argument = '[host]'; + +long-opts; +gnu-usage; + +flag = { + name = numeric; + value = n; + descrip = 'Print IP addresses instead of hostnames'; + doc = <<- _EndOfDoc_ + Output hosts as dotted-quad numeric format rather than converting to + the canonical host names. + _EndOfDoc_; +}; + +flag = { + name = max-hosts; + value = m; + arg-type = number; + arg-default = 99; + descrip = 'Maximum number of peers to trace'; +}; + +flag = { + name = host; + value = r; + arg-type = string; + arg-default = '127.0.0.1'; + descrip = 'Single remote host'; +}; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'texi'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +@code{ntptrace} is a perl script that uses the ntpq utility program to follow +the chain of NTP servers from a given host back to the primary time source. For +ntptrace to work properly, each of these servers must implement the NTP Control +and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets. + +If given no arguments, ntptrace starts with localhost. Here is an example of +the output from ntptrace: + +@example +% ntptrace localhost: stratum 4, offset 0.0019529, synch distance 0.144135 +server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784 usndh.edu: +stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB' +@end example + +On each line, the fields are (left to right): the host name, the host stratum, +the time offset between that host and the local host (as measured by +@code{ntptrace}; this is why it is not always zero for "localhost"), the host +synchronization distance, and (only for stratum-1 servers) the reference clock +ID. All times are given in seconds. Note that the stratum is the server hop +count to the primary source, while the synchronization distance is the +estimated error relative to the primary source. These terms are precisely +defined in RFC-1305. + _END_PROG_MDOC_DESCRIP; +}; diff --git a/contrib/ntp/scripts/ntptrace/ntptrace.1ntptraceman b/contrib/ntp/scripts/ntptrace/ntptrace.1ntptraceman new file mode 100644 index 000000000..c2362b7a0 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace.1ntptraceman @@ -0,0 +1,114 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntptrace 1ntptraceman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-h.aOvD/ag-u.aWuD) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:27 PM by AutoGen 5.18.5 +.\" From the definitions ntptrace-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntptrace\fP +\- Trace peers of an NTP server +.SH SYNOPSIS +\f\*[B-Font]ntptrace\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[host] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\fBntptrace\fP is a perl script that uses the ntpq utility program to follow +the chain of NTP servers from a given host back to the primary time source. For +ntptrace to work properly, each of these servers must implement the NTP Control +and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets. +.sp +If given no arguments, ntptrace starts with localhost. Here is an example of +the output from ntptrace: +.sp +.br +.in +4 +.nf +% ntptrace localhost: stratum 4, offset 0.0019529, synch distance 0.144135 +server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784 usndh.edu: +stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB' +.in -4 +.fi +.sp +On each line, the fields are (left to right): the host name, the host stratum, +the time offset between that host and the local host (as measured by +\fBntptrace\fP; this is why it is not always zero for "localhost"), the host +synchronization distance, and (only for stratum\-1 servers) the reference clock +ID. All times are given in seconds. Note that the stratum is the server hop +count to the primary source, while the synchronization distance is the +estimated error relative to the primary source. These terms are precisely +defined in RFC\-1305. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-numeric\f[] +Print IP addresses instead of hostnames. +.sp +Output hosts as dotted-quad numeric format rather than converting to +the canonical host names. +.TP +.NOP \f\*[B-Font]\-m\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-max\-hosts\f[]=\f\*[I-Font]number\f[] +Maximum number of peers to trace. +This option takes an integer number as its argument. +The default +\f\*[I-Font]number\f[] +for this option is: +.ti +4 + 99 +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-r\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-host\f[]=\f\*[I-Font]string\f[] +Single remote host. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + 127.0.0.1 +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntptrace\fP +option definitions. diff --git a/contrib/ntp/scripts/ntptrace/ntptrace.1ntptracemdoc b/contrib/ntp/scripts/ntptrace/ntptrace.1ntptracemdoc new file mode 100644 index 000000000..1734bcc7e --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace.1ntptracemdoc @@ -0,0 +1,91 @@ +.Dd October 21 2015 +.Dt NTPTRACE 1ntptracemdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntptrace-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:32 PM by AutoGen 5.18.5 +.\" From the definitions ntptrace-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntptrace +.Nd Trace peers of an NTP server +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[host] +.Pp +.Sh DESCRIPTION +\fBntptrace\fP is a perl script that uses the ntpq utility program to follow +the chain of NTP servers from a given host back to the primary time source. For +ntptrace to work properly, each of these servers must implement the NTP Control +and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets. +.sp +If given no arguments, ntptrace starts with localhost. Here is an example of +the output from ntptrace: +.sp +.Bd -literal -offset indent +% ntptrace localhost: stratum 4, offset 0.0019529, synch distance 0.144135 +server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784 usndh.edu: +stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB' +.Ed +.sp +On each line, the fields are (left to right): the host name, the host stratum, +the time offset between that host and the local host (as measured by +\fBntptrace\fP; this is why it is not always zero for "localhost"), the host +synchronization distance, and (only for stratum\-1 servers) the reference clock +ID. All times are given in seconds. Note that the stratum is the server hop +count to the primary source, while the synchronization distance is the +estimated error relative to the primary source. These terms are precisely +defined in RFC\-1305. +.Sh "OPTIONS" +.Bl -tag +.It Fl n , Fl \-numeric +Print IP addresses instead of hostnames. +.sp +Output hosts as dotted\-quad numeric format rather than converting to +the canonical host names. +.It Fl m Ar number , Fl \-max\-hosts Ns = Ns Ar number +Maximum number of peers to trace. +This option takes an integer number as its argument. +The default +.Ar number +for this option is: +.ti +4 + 99 +.sp +This option has not been fully documented. +.It Fl r Ar string , Fl \-host Ns = Ns Ar string +Single remote host. +The default +.Ar string +for this option is: +.ti +4 + 127.0.0.1 +.sp +This option has not been fully documented. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntptrace\fP +option definitions. diff --git a/contrib/ntp/scripts/ntptrace/ntptrace.html b/contrib/ntp/scripts/ntptrace/ntptrace.html new file mode 100644 index 000000000..4a4b7464d --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace.html @@ -0,0 +1,180 @@ + + +Ntptrace User's Manual + + + + + + + + + +

      Ntptrace User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      Simple Network Time Protocol User Manual

      + +

      This document describes the use of the NTP Project's ntptrace program. +This document applies to version 4.2.8p4 of ntptrace. + +

      + + + +
      +


      +Previous: ntptrace Description, +Up: Top +
      +
      + +

      Invoking ntptrace

      + +

      +ntptrace is a perl script that uses the ntpq utility program to follow +the chain of NTP servers from a given host back to the primary time source. For +ntptrace to work properly, each of these servers must implement the NTP Control +and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets. + +

      If given no arguments, ntptrace starts with localhost. Here is an example of +the output from ntptrace: + +

           % ntptrace localhost: stratum 4, offset 0.0019529, synch distance 0.144135
      +     server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784 usndh.edu:
      +     stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB'
      +
      +

      On each line, the fields are (left to right): the host name, the host stratum, +the time offset between that host and the local host (as measured by +ntptrace; this is why it is not always zero for "localhost"), the host +synchronization distance, and (only for stratum-1 servers) the reference clock +ID. All times are given in seconds. Note that the stratum is the server hop +count to the primary source, while the synchronization distance is the +estimated error relative to the primary source. These terms are precisely +defined in RFC-1305. + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the ntptrace program. + +

      + + + +

      ntptrace help/usage (--help)

      + +

      +This is the automatically generated usage text for ntptrace. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      ntptrace - Trace peers of an NTP server - Ver. 4.2.8p4
      +USAGE: ntptrace [ -<flag> [<val>] | --<name>[{=| }<val>] ]... [host]
      +
      +    -n, --numeric                Print IP addresses instead of hostnames
      +    -m, --max-hosts=num          Maximum number of peers to trace
      +    -r, --host=str               Single remote host
      +    -?, --help                   Display usage information and exit
      +        --more-help              Pass the extended usage text through a pager
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      +
      +


      +Next: , +Previous: ntptrace usage, +Up: ntptrace Invocation +
      +
      + +

      numeric option (-n)

      + +

      +This is the “print ip addresses instead of hostnames” option. +Output hosts as dotted-quad numeric format rather than converting to +the canonical host names. +

      +


      +Next: , +Previous: ntptrace numeric, +Up: ntptrace Invocation +
      +
      + +

      max-hosts option (-m)

      + +

      +This is the “maximum number of peers to trace” option. +This option takes a number argument. +This option has no doc documentation. +

      + +

      host option (-r)

      + +

      +This is the “single remote host” option. +This option takes a string argument. +This option has no doc documentation. +

      +


      +Previous: ntptrace host, +Up: ntptrace Invocation +
      +
      + +

      ntptrace exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      + + + diff --git a/contrib/ntp/scripts/ntptrace/ntptrace.in b/contrib/ntp/scripts/ntptrace/ntptrace.in new file mode 100755 index 000000000..7cc5ce7f7 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace.in @@ -0,0 +1,80 @@ +#! @PATH_PERL@ -w +# John Hay -- John.Hay@icomtek.csir.co.za / jhay@FreeBSD.org + +package ntptrace; +use 5.006_000; +use strict; +use lib "@PERLLIBDIR@"; +use NTP::Util qw(ntp_read_vars do_dns); + +exit run(@ARGV) unless caller; + +sub run { + my $opts; + if (!processOptions(\@_, $opts)) { + usage(1); + }; + + my $dodns = $opts->{numeric} ? 0 : 1; + my $max_hosts = $opts->{'max-hosts'}; + my $host = shift || $opts->{host}; + my $nb_host = 0; + + for (;;) { + $nb_host++; + + my %info = get_info($host); + last if not %info; + + my $dhost = $host; + if ($dodns) { + my $name = do_dns($host); + $dhost = $name if defined $name; + } + + printf "%s: stratum %d, offset %f, synch distance %f", + $dhost, $info{stratum}, $info{offset}, $info{syncdistance}; + printf ", refid '%s'", $info{refid} if $info{stratum} == 1; + print "\n"; + + last if $info{stratum} == 0 || $info{stratum} == 1 || + $info{stratum} == 16; + last if $info{refid} =~ /^127\.127\.\d{1,3}\.\d{1,3}$/; + last if $nb_host == $max_hosts; + + my $next_host = get_next_host($info{peer}, $host); + last if $next_host eq ''; + last if $next_host =~ /^127\.127\.\d{1,3}\.\d{1,3}$/; + + $host = $next_host; + } + return 0; +} + +sub get_info { + my ($host) = @_; + my ($rootdelay, $rootdisp, $info) = (0, 0); + + $info = ntp_read_vars(0, [], $host); + return if not defined $info; + return if not exists $info->{stratum}; + + $info->{offset} /= 1000; + $info->{syncdistance} = ($info->{rootdisp} + ($info->{rootdelay} / 2)) / 1000; + + return %$info; +} + + +sub get_next_host { + my ($peer, $host) = @_; + + my $info = ntp_read_vars($peer, [qw(srcadr)], $host); + return if not defined $info; + return $info->{srcadr}; +} + +@ntptrace_opts@ + +1; +__END__ diff --git a/contrib/ntp/scripts/ntptrace/ntptrace.man.in b/contrib/ntp/scripts/ntptrace/ntptrace.man.in new file mode 100644 index 000000000..5aca4557c --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace.man.in @@ -0,0 +1,114 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH ntptrace @NTPTRACE_MS@ "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-h.aOvD/ag-u.aWuD) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:27 PM by AutoGen 5.18.5 +.\" From the definitions ntptrace-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]ntptrace\fP +\- Trace peers of an NTP server +.SH SYNOPSIS +\f\*[B-Font]ntptrace\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +[host] +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\fBntptrace\fP is a perl script that uses the ntpq utility program to follow +the chain of NTP servers from a given host back to the primary time source. For +ntptrace to work properly, each of these servers must implement the NTP Control +and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets. +.sp +If given no arguments, ntptrace starts with localhost. Here is an example of +the output from ntptrace: +.sp +.br +.in +4 +.nf +% ntptrace localhost: stratum 4, offset 0.0019529, synch distance 0.144135 +server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784 usndh.edu: +stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB' +.in -4 +.fi +.sp +On each line, the fields are (left to right): the host name, the host stratum, +the time offset between that host and the local host (as measured by +\fBntptrace\fP; this is why it is not always zero for "localhost"), the host +synchronization distance, and (only for stratum\-1 servers) the reference clock +ID. All times are given in seconds. Note that the stratum is the server hop +count to the primary source, while the synchronization distance is the +estimated error relative to the primary source. These terms are precisely +defined in RFC\-1305. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-n\f[], \f\*[B-Font]\-\-numeric\f[] +Print IP addresses instead of hostnames. +.sp +Output hosts as dotted-quad numeric format rather than converting to +the canonical host names. +.TP +.NOP \f\*[B-Font]\-m\f[] \f\*[I-Font]number\f[], \f\*[B-Font]\-\-max\-hosts\f[]=\f\*[I-Font]number\f[] +Maximum number of peers to trace. +This option takes an integer number as its argument. +The default +\f\*[I-Font]number\f[] +for this option is: +.ti +4 + 99 +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-r\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-host\f[]=\f\*[I-Font]string\f[] +Single remote host. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + 127.0.0.1 +.sp +This option has not been fully documented. +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBntptrace\fP +option definitions. diff --git a/contrib/ntp/scripts/ntptrace/ntptrace.mdoc.in b/contrib/ntp/scripts/ntptrace/ntptrace.mdoc.in new file mode 100644 index 000000000..34be2a550 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace.mdoc.in @@ -0,0 +1,91 @@ +.Dd October 21 2015 +.Dt NTPTRACE @NTPTRACE_MS@ User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (ntptrace-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:32 PM by AutoGen 5.18.5 +.\" From the definitions ntptrace-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm ntptrace +.Nd Trace peers of an NTP server +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[host] +.Pp +.Sh DESCRIPTION +\fBntptrace\fP is a perl script that uses the ntpq utility program to follow +the chain of NTP servers from a given host back to the primary time source. For +ntptrace to work properly, each of these servers must implement the NTP Control +and Monitoring Protocol specified in RFC 1305 and enable NTP Mode 6 packets. +.sp +If given no arguments, ntptrace starts with localhost. Here is an example of +the output from ntptrace: +.sp +.Bd -literal -offset indent +% ntptrace localhost: stratum 4, offset 0.0019529, synch distance 0.144135 +server2ozo.com: stratum 2, offset 0.0124263, synch distance 0.115784 usndh.edu: +stratum 1, offset 0.0019298, synch distance 0.011993, refid 'WWVB' +.Ed +.sp +On each line, the fields are (left to right): the host name, the host stratum, +the time offset between that host and the local host (as measured by +\fBntptrace\fP; this is why it is not always zero for "localhost"), the host +synchronization distance, and (only for stratum\-1 servers) the reference clock +ID. All times are given in seconds. Note that the stratum is the server hop +count to the primary source, while the synchronization distance is the +estimated error relative to the primary source. These terms are precisely +defined in RFC\-1305. +.Sh "OPTIONS" +.Bl -tag +.It Fl n , Fl \-numeric +Print IP addresses instead of hostnames. +.sp +Output hosts as dotted\-quad numeric format rather than converting to +the canonical host names. +.It Fl m Ar number , Fl \-max\-hosts Ns = Ns Ar number +Maximum number of peers to trace. +This option takes an integer number as its argument. +The default +.Ar number +for this option is: +.ti +4 + 99 +.sp +This option has not been fully documented. +.It Fl r Ar string , Fl \-host Ns = Ns Ar string +Single remote host. +The default +.Ar string +for this option is: +.ti +4 + 127.0.0.1 +.sp +This option has not been fully documented. +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBntptrace\fP +option definitions. diff --git a/contrib/ntp/scripts/ntptrace/ntptrace.texi b/contrib/ntp/scripts/ntptrace/ntptrace.texi new file mode 100644 index 000000000..b1851f2a8 --- /dev/null +++ b/contrib/ntp/scripts/ntptrace/ntptrace.texi @@ -0,0 +1,40 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename ntptrace.info +@settitle Ntptrace User's Manual +@include ../../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of @code{ntptrace}, +a program from the NTP Project +@end ifinfo + +@direntry +* ntptrace: (ntptrace). Trace the ntp server to the primary time source. +@end direntry + +@titlepage +@title ntptrace User's Manual +@subtitle ntptrace, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, ntptrace Description, (dir), (dir) +@top Simple Network Time Protocol User Manual + +This document describes the use of the NTP Project's @code{ntptrace} program. +This document applies to version @value{VERSION} of @code{ntptrace}. + +@shortcontents + +@menu +* ntptrace Description:: Description +* ntptrace Invocation:: Invoking ntptrace +@end menu + +@include invoke-ntptrace.texi diff --git a/contrib/ntp/scripts/ntpver.in b/contrib/ntp/scripts/ntpver.in index be36897c4..9615e66d6 100644 --- a/contrib/ntp/scripts/ntpver.in +++ b/contrib/ntp/scripts/ntpver.in @@ -1,7 +1,7 @@ -#!@PATH_SH@ +#!@CONFIG_SHELL@ # print version string of NTP daemon # Copyright (c) 1997 by Ulrich Windl # Modified 970318: Harlan Stenn: rewritten... # usage: ntpver hostname -ntpq -c "rv 0 daemon_version" $* | awk '/daemon_version/ { print $2 }' +ntpq -c "rv 0 daemon_version" $* | @AWK@ '/daemon_version/ { print $2 }' diff --git a/contrib/ntp/scripts/plot_summary-opts b/contrib/ntp/scripts/plot_summary-opts new file mode 100644 index 000000000..2cb86c41d --- /dev/null +++ b/contrib/ntp/scripts/plot_summary-opts @@ -0,0 +1,73 @@ +# EDIT THIS FILE WITH CAUTION (plot_summary-opts) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:45 PM by AutoGen 5.18.5 +# From the definitions plot_summary-opts.def +# and the template file perlopt + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + 'directory' => '/tmp', + 'identifier' => '', + 'offset-limit' => '0.128', + 'peer' => [], + 'plot-term' => '', + 'output-file' => '', + 'dont-wait' => '', + 'help' => '', 'more-help' => '' + }; + my $argument = ''; + my $ret = GetOptionsFromArray($args, $opts, ( + 'directory=s', 'identifier=s', 'offset-limit=f', + 'peer=s', 'plot-term=s', 'output-file=s', + 'dont-wait', + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +plot_summary - plot statistics generated by summary script - Ver. 4.2.8p4 +USAGE: plot_summary [ - [] | --[{=| }] ]... + + --directory=str Where the summary files are + --identifier=str Origin of the data + --offset-limit=float Limit of absolute offset + --peer=str Peers to generate plots for + - may appear multiple times + --plot-term=str Gnuplot terminal + --output-file=str Output file + --dont-wait Don't wait for keystroke between plots + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'}; + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/scripts/plot_summary-opts.def b/contrib/ntp/scripts/plot_summary-opts.def new file mode 100644 index 000000000..61f028bce --- /dev/null +++ b/contrib/ntp/scripts/plot_summary-opts.def @@ -0,0 +1,83 @@ +/* -*- Mode: Text -*- */ +AutoGen Definitions perlopt; + +#include autogen-version.def + +prog-name = 'plot_summary'; +prog-title = 'plot statistics generated by summary script'; +package = ntp; +#include version.def + +long-opts; +gnu-usage; + +flag = { + name = directory; + arg-type = string; + arg-default = '/tmp'; + descrip = 'Where the summary files are'; + doc = <<- _EndOfDoc_ + The directory where the @code{plot_summary} will search for the + *_summary files generated by @code{summary} script. + _EndOfDoc_; +}; + +flag = { + name = identifier; + arg-type = string; + descrip = 'Origin of the data'; + doc = <<- _EndOfDoc_ + Where does the plotted data come from, default to string "host" plus + current hostname + _EndOfDoc_; +}; + +flag = { + name = offset-limit; + arg-type = string; + arg-name = float; + arg-default = "0.128"; + descrip = 'Limit of absolute offset'; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = peer; + arg-type = string; + stack-arg; + max = NOLIMIT; + descrip = 'Peers to generate plots for'; + doc = <<- _EndOfDoc_ + By default the peer_summary plots are not generated. Use this option to + specify list of peers if you want to generate plots for them. + _EndOfDoc_; +}; + +flag = { + name = plot-term; + arg-type = string; + descrip = 'Gnuplot terminal'; + doc = <<- _EndOfDoc_ + This is string is passed directly to the @code{gnuplot set terminal} + command. Default is @code{x11} if @code{DISPLAY} is set and + @code{dumb} is it's not'. See output from @code(gnuplot -e "set + terminal") for the list of avalaible options. + _EndOfDoc_; +}; + +flag = { + name = output-file; + arg-type = str; + descrip = 'Output file'; + doc = <<- _EndOfDoc_ + Output file for @code{gnuplot}, default to stdout. + _EndOfDoc_; +}; + +flag = { + name = dont-wait; + descrip = "Don't wait for keystroke between plots"; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; diff --git a/contrib/ntp/scripts/plot_summary.1plot_summaryman b/contrib/ntp/scripts/plot_summary.1plot_summaryman new file mode 100644 index 000000000..fea03df8f --- /dev/null +++ b/contrib/ntp/scripts/plot_summary.1plot_summaryman @@ -0,0 +1,114 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH plot_summary 1plot_summaryman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-EXaylG/ag-RXaGkG) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:51 PM by AutoGen 5.18.5 +.\" From the definitions plot_summary-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]plot_summary\fP +\- plot statistics generated by summary script +.SH SYNOPSIS +\f\*[B-Font]plot_summary\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH "DESCRIPTION" +There is no description for this command. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-\-directory\f[]=\f\*[I-Font]string\f[] +Where the summary files are. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + /tmp +.sp + The directory where the \fBplot_summary\fP will search for the + *_summary files generated by \fBsummary\fP script. +.TP +.NOP \f\*[B-Font]\-\-identifier\f[]=\f\*[I-Font]string\f[] +Origin of the data. +.sp + Where does the plotted data come from, default to string "host" plus + current hostname +.TP +.NOP \f\*[B-Font]\-\-offset\-limit\f[]=\f\*[I-Font]float\f[] +Limit of absolute offset. +The default +\f\*[I-Font]float\f[] +for this option is: +.ti +4 + 0.128 +.sp +.TP +.NOP \f\*[B-Font]\-\-peer\f[]=\f\*[I-Font]string\f[] +Peers to generate plots for. +This option may appear an unlimited number of times. +.sp + By default the peer_summary plots are not generated. Use this option to + specify list of peers if you want to generate plots for them. +.TP +.NOP \f\*[B-Font]\-\-plot\-term\f[]=\f\*[I-Font]string\f[] +Gnuplot terminal. +.sp + This is string is passed directly to the \fBgnuplot set terminal\fP + command. Default is \fBx11\fP if \fBDISPLAY\fP is set and + \fBdumb\fP is it's not'. See output from @code(gnuplot \-e "set + terminal") for the list of avalaible options. +.TP +.NOP \f\*[B-Font]\-\-output\-file\f[]=\f\*[I-Font]str\f[] +Output file. +.sp + Output file for \fBgnuplot\fP, default to stdout. +.TP +.NOP \f\*[B-Font]\-\-dont\-wait\f[] +Don't wait for keystroke between plots. +.sp +.TP +.NOP \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBplot_summary\fP +option definitions. diff --git a/contrib/ntp/scripts/plot_summary.1plot_summarymdoc b/contrib/ntp/scripts/plot_summary.1plot_summarymdoc new file mode 100644 index 000000000..0eff78f7d --- /dev/null +++ b/contrib/ntp/scripts/plot_summary.1plot_summarymdoc @@ -0,0 +1,88 @@ +.Dd October 21 2015 +.Dt PLOT_SUMMARY 1plot_summarymdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (plot_summary-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:53 PM by AutoGen 5.18.5 +.\" From the definitions plot_summary-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm plot_summary +.Nd plot statistics generated by summary script +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh "DESCRIPTION" +There is no description for this command. +.Sh "OPTIONS" +.Bl -tag +.It Fl \-directory Ns = Ns Ar string +Where the summary files are. +The default +.Ar string +for this option is: +.ti +4 + /tmp +.sp + The directory where the \fBplot_summary\fP will search for the + *_summary files generated by \fBsummary\fP script. +.It Fl \-identifier Ns = Ns Ar string +Origin of the data. +.sp + Where does the plotted data come from, default to string "host" plus + current hostname +.It Fl \-offset\-limit Ns = Ns Ar float +Limit of absolute offset. +The default +.Ar float +for this option is: +.ti +4 + 0.128 +.sp +.It Fl \-peer Ns = Ns Ar string +Peers to generate plots for. +This option may appear an unlimited number of times. +.sp + By default the peer_summary plots are not generated. Use this option to + specify list of peers if you want to generate plots for them. +.It Fl \-plot\-term Ns = Ns Ar string +Gnuplot terminal. +.sp + This is string is passed directly to the \fBgnuplot set terminal\fP + command. Default is \fBx11\fP if \fBDISPLAY\fP is set and + \fBdumb\fP is it's not'. See output from @code(gnuplot \-e "set + terminal") for the list of avalaible options. +.It Fl \-output\-file Ns = Ns Ar str +Output file. +.sp + Output file for \fBgnuplot\fP, default to stdout. +.It Fl \-dont\-wait +Don't wait for keystroke between plots. +.sp +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBplot_summary\fP +option definitions. diff --git a/contrib/ntp/scripts/plot_summary.html b/contrib/ntp/scripts/plot_summary.html new file mode 100644 index 000000000..7f0a594fc --- /dev/null +++ b/contrib/ntp/scripts/plot_summary.html @@ -0,0 +1,207 @@ + + +Plot_summary User's Manual + + + + + + + + + +

      Plot_summary User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      Plot_summary User Manual

      + +

      This document describes the use of the NTP Project's plot_summary program. +This document applies to version 4.2.8p4 of plot_summary. + +

      +

      Short Contents

      + +
      + + + +
      +


      +Previous: plot_summary Description, +Up: Top +
      +
      + +

      Invoking plot_summary

      + +

      + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the plot_summary program. + +

      + + + +

      plot_summary help/usage (--help)

      + +

      +This is the automatically generated usage text for plot_summary. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      plot_summary - plot statistics generated by summary script - Ver. 4.2.8p4
      +USAGE: plot_summary [ -<flag> [<val>] | --<name>[{=| }<val>] ]...
      +
      +        --directory=str          Where the summary files are
      +        --identifier=str         Origin of the data
      +        --offset-limit=float     Limit of absolute offset
      +        --peer=str               Peers to generate plots for
      +                                   - may appear multiple times
      +        --plot-term=str          Gnuplot terminal
      +        --output-file=str        Output file
      +        --dont-wait              Don't wait for keystroke between plots
      +    -?, --help                   Display usage information and exit
      +        --more-help              Pass the extended usage text through a pager
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      + + +

      directory option

      + +

      +This is the “where the summary files are” option. +This option takes a string argument. + The directory where the plot_summary will search for the + *_summary files generated by summary script. +

      + +

      identifier option

      + +

      +This is the “origin of the data” option. +This option takes a string argument. + Where does the plotted data come from, default to string "host" plus + current hostname +

      + +

      peer option

      + +

      +This is the “peers to generate plots for” option. +This option takes a string argument. + +

      This option has some usage constraints. It: +

        +
      • may appear an unlimited number of times. +
      + +

      By default the peer_summary plots are not generated. Use this option to + specify list of peers if you want to generate plots for them. +

      + +

      plot-term option

      + +

      +This is the “gnuplot terminal” option. +This option takes a string argument. + This is string is passed directly to the gnuplot set terminal + command. Default is x11 if DISPLAY is set and + dumb is it's not'. See output from -e "set + terminal") for the list of avalaible options. +

      + +

      output-file option

      + +

      +This is the “output file” option. +This option takes a str argument. + Output file for gnuplot, default to stdout. +

      + +

      plot_summary exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      + + + diff --git a/contrib/ntp/scripts/plot_summary.in b/contrib/ntp/scripts/plot_summary.in index 3b46a0401..3401b0d0b 100644 --- a/contrib/ntp/scripts/plot_summary.in +++ b/contrib/ntp/scripts/plot_summary.in @@ -19,53 +19,48 @@ # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - -require 5.003; # "never tested with any other version of Perl" +package plot_summary; +use 5.006_000; use strict; - use Time::Local; -use Getopt::Long; -# parse command line -my $summary_dir = "/tmp"; -my $identifier = "host " . `hostname`; # origin of these data -chomp $identifier; # remove newline -my $offset_limit = 0.128; # limit of absolute offset -my $output_file = ""; # output file defaults to stdout -my $output_file_number = 1; # numbering of output files -my $gnuplot_terminal = $ENV{DISPLAY} ? "x11" : "dumb"; -my $wait_after_plot = 1; -my @peer_list = (); +my ($identifier, $offset_limit, $gnuplot_terminal, $wait_after_plot, + $output_file, $output_file_number); -my %options = ("directory|input-directory=s" => \$summary_dir, - "identifier=s" => \$identifier, - "offset-limit=f" => \$offset_limit, - "output-file=s" => \$output_file, - "peer=s@" => \@peer_list, - "plot-term|gnuplot-term=s" => \$gnuplot_terminal, - "wait-after-plot!" => \$wait_after_plot, - ); +exit run(@ARGV) unless caller; -if ( !GetOptions(%options) ) -{ - print STDERR "valid options for $0 are:\n"; - my $opt; - foreach $opt (sort(keys %options)) { - print STDERR "\t--$opt\t(default is "; - if ( ref($options{$opt}) eq "ARRAY" ) { - print STDERR join(", ", map { "'$_'" } @{$options{$opt}}); - } else { - print STDERR "'${$options{$opt}}'"; - } - print STDERR ")\n"; +sub run { + my $opts; + if (!processOptions(\@_, $opts)) { + usage(1); } - print STDERR "\n"; - die; -} -chomp $identifier; -die "illegal offset-limit: $offset_limit" unless $offset_limit > 0.0; -$offset_limit *= 1e6; # scale to microseconds + $identifier = $opts->{'identifier'}; + if (!$identifier) { + $identifier = "host".`hostname`; + chomp $identifier; + } + $offset_limit = $opts->{'offset-limit'}; + $output_file = $opts->{'output-file'}; + $output_file_number = 1; + $gnuplot_terminal = $opts->{'plot-terminal'} + || ( $ENV{DISPLAY} ? "x11" : "dumb" ); + $wait_after_plot = !$opts->{'dont-wait'}; + + die "illegal offset-limit: $offset_limit" unless $offset_limit > 0.0; + $offset_limit *= 1e6; # scale to microseconds + + my $summary_dir = $opts->{'directory'}; + + my $loop_summary ="$summary_dir/loop_summary"; + my $peer_summary ="$summary_dir/peer_summary"; + my $clock_summary="$summary_dir/clock_summary"; + + my @peer_list = @{$opts->{'peer'}}; + + do_loop($loop_summary); + do_peer($peer_summary, $_) for @peer_list; +} # return the smallest value in the given list sub min @@ -176,7 +171,7 @@ sub do_loop "Daily mean values since $first_day\\n" . "(Offset limit is $offset_limit microseconds)\"\n"; print "set ylabel \"[us]\"\n"; - print "set data style yerrorbars\n"; + print "set style data yerrorbars\n"; print "set multiplot\n"; print "set size 1, 0.5\n"; print "set lmargin 8\n"; @@ -224,7 +219,7 @@ sub do_loop print "set xlabel\n"; print "set ylabel \"[us]\"\n"; print "set origin 0, 0.5\n"; - print "set data style linespoints\n"; + print "set style data linespoints\n"; print "set multiplot\n"; print "plot $ylimit \"$out_file\" using 1:6 title \"Offset\", "; print "\"$out_file\" using 1:6 smooth bezier " . @@ -296,7 +291,7 @@ sub do_peer print "set origin 0, 0.66\n"; print "set title " . "\"Peer Summary for $peer on $identifier since $first_day\"\n"; - print "set data style linespoints\n"; + print "set style data linespoints\n"; print "set ylabel \"[us]\"\n"; print "plot \"$out_file\" using 1:3 title \"mean offset\", "; print "\"$out_file\" using 1:3 smooth bezier " . @@ -328,10 +323,7 @@ sub do_peer unlink $out_file; } +@plot_summary_opts@ -my $loop_summary ="$summary_dir/loop_summary"; -my $peer_summary ="$summary_dir/peer_summary"; -my $clock_summary="$summary_dir/clock_summary"; - -do_loop $loop_summary; -map { do_peer $peer_summary, $_ } @peer_list; +1; +__END__ diff --git a/contrib/ntp/scripts/plot_summary.man.in b/contrib/ntp/scripts/plot_summary.man.in new file mode 100644 index 000000000..fea03df8f --- /dev/null +++ b/contrib/ntp/scripts/plot_summary.man.in @@ -0,0 +1,114 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH plot_summary 1plot_summaryman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-EXaylG/ag-RXaGkG) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:51 PM by AutoGen 5.18.5 +.\" From the definitions plot_summary-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]plot_summary\fP +\- plot statistics generated by summary script +.SH SYNOPSIS +\f\*[B-Font]plot_summary\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH "DESCRIPTION" +There is no description for this command. +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-\-directory\f[]=\f\*[I-Font]string\f[] +Where the summary files are. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + /tmp +.sp + The directory where the \fBplot_summary\fP will search for the + *_summary files generated by \fBsummary\fP script. +.TP +.NOP \f\*[B-Font]\-\-identifier\f[]=\f\*[I-Font]string\f[] +Origin of the data. +.sp + Where does the plotted data come from, default to string "host" plus + current hostname +.TP +.NOP \f\*[B-Font]\-\-offset\-limit\f[]=\f\*[I-Font]float\f[] +Limit of absolute offset. +The default +\f\*[I-Font]float\f[] +for this option is: +.ti +4 + 0.128 +.sp +.TP +.NOP \f\*[B-Font]\-\-peer\f[]=\f\*[I-Font]string\f[] +Peers to generate plots for. +This option may appear an unlimited number of times. +.sp + By default the peer_summary plots are not generated. Use this option to + specify list of peers if you want to generate plots for them. +.TP +.NOP \f\*[B-Font]\-\-plot\-term\f[]=\f\*[I-Font]string\f[] +Gnuplot terminal. +.sp + This is string is passed directly to the \fBgnuplot set terminal\fP + command. Default is \fBx11\fP if \fBDISPLAY\fP is set and + \fBdumb\fP is it's not'. See output from @code(gnuplot \-e "set + terminal") for the list of avalaible options. +.TP +.NOP \f\*[B-Font]\-\-output\-file\f[]=\f\*[I-Font]str\f[] +Output file. +.sp + Output file for \fBgnuplot\fP, default to stdout. +.TP +.NOP \f\*[B-Font]\-\-dont\-wait\f[] +Don't wait for keystroke between plots. +.sp +.TP +.NOP \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBplot_summary\fP +option definitions. diff --git a/contrib/ntp/scripts/plot_summary.mdoc.in b/contrib/ntp/scripts/plot_summary.mdoc.in new file mode 100644 index 000000000..0eff78f7d --- /dev/null +++ b/contrib/ntp/scripts/plot_summary.mdoc.in @@ -0,0 +1,88 @@ +.Dd October 21 2015 +.Dt PLOT_SUMMARY 1plot_summarymdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (plot_summary-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:53 PM by AutoGen 5.18.5 +.\" From the definitions plot_summary-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm plot_summary +.Nd plot statistics generated by summary script +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh "DESCRIPTION" +There is no description for this command. +.Sh "OPTIONS" +.Bl -tag +.It Fl \-directory Ns = Ns Ar string +Where the summary files are. +The default +.Ar string +for this option is: +.ti +4 + /tmp +.sp + The directory where the \fBplot_summary\fP will search for the + *_summary files generated by \fBsummary\fP script. +.It Fl \-identifier Ns = Ns Ar string +Origin of the data. +.sp + Where does the plotted data come from, default to string "host" plus + current hostname +.It Fl \-offset\-limit Ns = Ns Ar float +Limit of absolute offset. +The default +.Ar float +for this option is: +.ti +4 + 0.128 +.sp +.It Fl \-peer Ns = Ns Ar string +Peers to generate plots for. +This option may appear an unlimited number of times. +.sp + By default the peer_summary plots are not generated. Use this option to + specify list of peers if you want to generate plots for them. +.It Fl \-plot\-term Ns = Ns Ar string +Gnuplot terminal. +.sp + This is string is passed directly to the \fBgnuplot set terminal\fP + command. Default is \fBx11\fP if \fBDISPLAY\fP is set and + \fBdumb\fP is it's not'. See output from @code(gnuplot \-e "set + terminal") for the list of avalaible options. +.It Fl \-output\-file Ns = Ns Ar str +Output file. +.sp + Output file for \fBgnuplot\fP, default to stdout. +.It Fl \-dont\-wait +Don't wait for keystroke between plots. +.sp +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBplot_summary\fP +option definitions. diff --git a/contrib/ntp/scripts/plot_summary.texi b/contrib/ntp/scripts/plot_summary.texi new file mode 100644 index 000000000..33fa1fdc8 --- /dev/null +++ b/contrib/ntp/scripts/plot_summary.texi @@ -0,0 +1,40 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename plot_summary.info +@settitle Plot_summary User's Manual +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of @code{plot_summary}, +a program from the NTP Project +@end ifinfo + +@direntry +* plot_summary: (plot_summary). Summarize (something) +@end direntry + +@titlepage +@title plot_summary User's Manual +@subtitle plot_summary, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, plot_summary Description, (dir), (dir) +@top Plot_summary User Manual + +This document describes the use of the NTP Project's @code{plot_summary} program. +This document applies to version @value{VERSION} of @code{plot_summary}. + +@shortcontents + +@menu +* plot_summary Description:: Description +* plot_summary Invocation:: Invoking plot_summary +@end menu + +@include invoke-plot_summary.texi diff --git a/contrib/ntp/scripts/rc/README b/contrib/ntp/scripts/rc/README new file mode 100644 index 000000000..f5b82bcbc --- /dev/null +++ b/contrib/ntp/scripts/rc/README @@ -0,0 +1,13 @@ +This directory contains some example rc scripts for ntpd. + +In general, ntpd should be started as soon as possible in the boot process. If +any services require stable system clock, the ntpwait script should be run +before them as late as possible. + +The rc.d contains scripts for systems using rc.d init system (originated in +NetBSD). If a service requires stable system time, indicate it with TIMESYNC +dependency and set ntpwait_enable to YES. + +For SysV init systems, you'll have to create links as /etc/rc2.d/S20ntpd and +/etc/rc2.d/S80ntpwait yourself. (The numbers are just examples, try to give +ntpd as much time as possible to synchronize before running ntpwait). diff --git a/contrib/ntp/scripts/rc/ntpd b/contrib/ntp/scripts/rc/ntpd new file mode 100644 index 000000000..9896247e7 --- /dev/null +++ b/contrib/ntp/scripts/rc/ntpd @@ -0,0 +1,88 @@ +#!/bin/sh + +NTPD=/usr/sbin/ntpd +PIDFILE=/var/run/ntpd.pid +USER=ntp +GROUP=ntp +NTPD_OPTS="-g -u $USER:$GROUP -p $PIDFILE" + +ntpd_start() { + if [ -r $PIDFILE ]; then + echo "ntpd seems to be already running under pid `cat $PIDFILE`." + echo "Delete $PIDFILE if this is not the case."; + return 1; + fi + echo -n "Starting NTP daemon... " + + $NTPD $NTPD_OPTS + + # You can't always rely on the ntpd exit code, see Bug #2420 + # case "$?" in + # 0) echo "OK!" + # return 0;; + # *) echo "FAILED!" + # return 1;; + # esac + + sleep 1 + + if ps -Ao args|grep -q "^$NTPD $NTPD_OPTS"; then + echo "OK!" + return 0 + else + echo "FAILED!" + [ -e $PIDFILE ] && rm $PIDFILE + return 1 + fi +} + +ntpd_stop() { + if [ ! -r $PIDFILE ]; then + echo "ntpd doesn't seem to be running, cannot read the pid file." + return 1; + fi + echo -n "Stopping NTP daemon..."; + PID=`cat $PIDFILE` + + if kill -TERM $PID 2> /dev/null;then + # Give ntp 15 seconds to exit + for i in `seq 1 15`; do + if [ -n "`ps -p $PID|grep -v PID`" ]; then + echo -n . + sleep 1 + else + echo " OK!" + rm $PIDFILE + return 0 + fi + done + fi + + echo " FAILED! ntpd is still running"; + return 1 +} + +ntpd_status() { + if [ -r $PIDFILE ]; then + echo "NTP daemon is running as `cat $PIDFILE`" + else + echo "NTP daemon is not running" + fi +} + +case "$1" in + 'start') + ntpd_start + ;; + 'stop') + ntpd_stop + ;; + 'restart') + ntpd_stop && ntpd_start + ;; + 'status') + ntpd_status + ;; + *) + echo "Usage: $0 (start|stop|restart|status)" +esac diff --git a/contrib/ntp/scripts/rc/ntpwait b/contrib/ntp/scripts/rc/ntpwait new file mode 100644 index 000000000..2542b2add --- /dev/null +++ b/contrib/ntp/scripts/rc/ntpwait @@ -0,0 +1,15 @@ +#!/bin/sh + +NTPWAIT=/usr/sbin/ntpwait + +ntpwait_start() { + $NTPWAIT -v +} + +case "$1" in + 'start') + ntpwait_start + ;; + *) + echo "Usage: $0 (start)" +esac diff --git a/contrib/ntp/scripts/rc/rc.d/TIMESYNC b/contrib/ntp/scripts/rc/rc.d/TIMESYNC new file mode 100644 index 000000000..a8c074fd4 --- /dev/null +++ b/contrib/ntp/scripts/rc/rc.d/TIMESYNC @@ -0,0 +1,8 @@ +#!/bin/sh + +# PROVIDE: TIMESYNC +# REQUIRE: LOGIN ntpwait + +# This depedency ensures that all services which require stable system clock +# are run after ntpd is synchronized. It's run as late as possible, if you need +# stable clock before login use BEFORE: LOGIN diff --git a/contrib/ntp/scripts/rc/rc.d/ntpd b/contrib/ntp/scripts/rc/rc.d/ntpd new file mode 100644 index 000000000..ea33458bc --- /dev/null +++ b/contrib/ntp/scripts/rc/rc.d/ntpd @@ -0,0 +1,32 @@ +#!/bin/sh + +# PROVIDE: ntpd +# REQUIRE: syslogd cleanvar devfs +# BEFORE: SERVERS + +. /etc/rc.subr + +name="ntpd" +rcvar="ntpd_enable" +command="/usr/sbin/${name}" +pidfile="/var/run/${name}.pid" +start_precmd="ntpd_precmd" + +load_rc_config $name + +ntpd_precmd() +{ + rc_flags="-c ${ntpd_config} ${ntpd_flags}" + + if checkyesno ntpd_sync_on_start; then + rc_flags="-g $rc_flags" + fi + + if [ -z "$ntpd_chrootdir" ]; then + return 0; + fi + + rc_flags="-u ntpd:ntpd -i ${ntpd_chrootdir} $rc_flags" +} + +run_rc_command "$1" diff --git a/contrib/ntp/scripts/rc/rc.d/ntpwait b/contrib/ntp/scripts/rc/rc.d/ntpwait new file mode 100644 index 000000000..891d0dbd6 --- /dev/null +++ b/contrib/ntp/scripts/rc/rc.d/ntpwait @@ -0,0 +1,21 @@ +#!/bin/sh +# This script, when run, runs ntp-wait if ntpd is enabled. + +# PROVIDE: ntpwait + +. /etc/rc.subr + +name="ntpwait" +rcvar="ntpwait_enable" +start_cmd="ntpwait_start" +ntp_wait="/usr/sbin/ntp-wait" + +load_rc_config "$name" + +ntpwait_start() { + if checkyesno ntpd_enable; then + $ntp_wait -v + fi +} + +run_rc_command "$1" diff --git a/contrib/ntp/scripts/rc1/postinstall b/contrib/ntp/scripts/rc1/postinstall deleted file mode 100644 index d84b8c517..000000000 --- a/contrib/ntp/scripts/rc1/postinstall +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -/etc/init.d/xntp start diff --git a/contrib/ntp/scripts/rc1/preinstall b/contrib/ntp/scripts/rc1/preinstall deleted file mode 100644 index aa18639c2..000000000 --- a/contrib/ntp/scripts/rc1/preinstall +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh -if [ -x /etc/init.d/xntp ] -then - /etc/init.d/xntp stop -fi -exit 0 diff --git a/contrib/ntp/scripts/rc1/preremove b/contrib/ntp/scripts/rc1/preremove deleted file mode 100644 index b870151a2..000000000 --- a/contrib/ntp/scripts/rc1/preremove +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -/etc/init.d/xntp stop - -exit 0 diff --git a/contrib/ntp/scripts/rc1/prototype b/contrib/ntp/scripts/rc1/prototype deleted file mode 100644 index 3de20b076..000000000 --- a/contrib/ntp/scripts/rc1/prototype +++ /dev/null @@ -1,19 +0,0 @@ -!default 755 root bin -i pkginfo -i preinstall -i postinstall -i preremove -f none /etc/init.d/xntp=xntp 0755 root other -l none /etc/rc2.d/S79xntp=/etc/init.d/xntp -l none /etc/rc1.d/K79xntp=/etc/init.d/xntp -l none /etc/rc0.d/K79xntp=/etc/init.d/xntp -f none /usr/sbin/xntpd=xntpd/xntpd 0555 root other -f none /usr/sbin/xntpdc=xntpdc/xntpdc 0555 root other -f none /usr/sbin/ntpq=ntpq/ntpq 0555 root other -f none /usr/sbin/ntptrace=ntptrace/ntptrace 0555 root other -f none /usr/sbin/ntpdate=ntpdate/ntpdate 0555 root other -f none /usr/share/man/man1m/xntpd.1m=doc/xntpd.8 0444 root other -f none /usr/share/man/man1m/xntpdc.1m=doc/xntpdc.8 0444 root other -f none /usr/share/man/man1m/ntpdate.1m=doc/ntpdate.8 0444 root other -f none /usr/share/man/man1m/ntpq.1m=doc/ntpq.8 0444 root other -f none /usr/share/man/man1m/ntptrace.1m=doc/ntptrace.8 0444 root other diff --git a/contrib/ntp/scripts/rc1/xntp b/contrib/ntp/scripts/rc1/xntp deleted file mode 100644 index 227b943aa..000000000 --- a/contrib/ntp/scripts/rc1/xntp +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh - -killproc() { # kill named processes - pid=`/usr/bin/ps -e | - /usr/bin/grep $1 | - /usr/bin/sed -e 's/^ *//' -e 's/ .*//'` - [ "$pid" != "" ] && kill $pid -} - -case "$1" in -'start') - ps -e | grep xntpd > /dev/null 2>&1 - if [ $? -eq 0 ] - then - echo "ntp daemon already running. ntp start aborted" - exit 0 - fi - if [ -f /etc/inet/ntp.conf -a -x /usr/sbin/xntpd ] - then - /usr/sbin/xntpd -c /etc/inet/ntp.conf - fi - ;; -'stop') - killproc xntpd - ;; -*) - echo "Usage: /etc/init.d/xntp { start | stop }" - ;; -esac diff --git a/contrib/ntp/scripts/rc2/local.ntpd b/contrib/ntp/scripts/rc2/local.ntpd deleted file mode 100644 index ba53e05ad..000000000 --- a/contrib/ntp/scripts/rc2/local.ntpd +++ /dev/null @@ -1,64 +0,0 @@ -#! /usr/bin/perl -w -# 980904 Harlan Stenn - created - -# vvv CHANGE THESE vvv - -$ps = "/bin/ps x |"; - -$ntp_conf = "/etc/ntp.conf"; -$ntpd = "/usr/local/bin/xntpd"; -$ntpdate = "/usr/local/bin/ntpdate -b -s 10.0.0.1 10.0.0.2"; - -# ^^^ CHANGE THESE ^^^ - -{ - if (0) - { - } - elsif ($ARGV[0] eq "start") - { - @pidlist = pidlist($ntpd); - if (defined(@pidlist)) - { - warn "NTP is already running\n"; - } - else - { - if ( -f $ntp_conf && -x $ntpd ) - { - system ($ntpdate); - system ($ntpd." -c ".$ntp_conf); - } - } - } - elsif ($ARGV[0] eq "stop") - { - @pidlist = pidlist($ntpd); - kill 'TERM', @pidlist if (scalar(@pidlist) > 0); - } - else - { - die "Usage: $0 {start,stop}\n"; - } -} - -sub pidlist ($) - { - my ($target) = @_; - my ($qt) = quotemeta($target); - my @pids; - - open(PS, $ps) || die "Can't run ps: $!\n"; - while () - { - chomp; - next unless (/$qt/); - print "Got <$_>\n"; - if (/^\s*(\d+)\s+/) - { - push @pids, $1; - } - } - close(PS); - return @pids; - } diff --git a/contrib/ntp/scripts/summary-opts b/contrib/ntp/scripts/summary-opts new file mode 100644 index 000000000..22f2c49ab --- /dev/null +++ b/contrib/ntp/scripts/summary-opts @@ -0,0 +1,69 @@ +# EDIT THIS FILE WITH CAUTION (summary-opts) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:47 PM by AutoGen 5.18.5 +# From the definitions summary-opts.def +# and the template file perlopt + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + 'directory' => '/var/log/ntp', + 'end-date' => '', + 'output-directory' => '/tmp', + 'peer-dist-limit' => '400', + 'skip-time-steps' => '3600', + 'start-date' => '19700101', + 'help' => '', 'more-help' => '' + }; + my $argument = ''; + my $ret = GetOptionsFromArray($args, $opts, ( + 'directory=s', 'end-date=i', 'output-directory=s', + 'peer-dist-limit=f', 'skip-time-steps=f', 'start-date=i', + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +summary - compute various stastics from NTP stat files - Ver. 4.2.8p4 +USAGE: summary [ - [] | --[{=| }] ]... + + --directory=str Directory containing stat files + --end-date=num End date + --output-directory=str Output directory + --peer-dist-limit=float Peer dist limit + --skip-time-steps=float Ignore time offsets larger that this + --start-date=num Start date + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'}; + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/scripts/summary-opts.def b/contrib/ntp/scripts/summary-opts.def new file mode 100644 index 000000000..82c31eb24 --- /dev/null +++ b/contrib/ntp/scripts/summary-opts.def @@ -0,0 +1,82 @@ +/* -*- Mode: Text -*- */ +AutoGen Definitions perlopt; + +#include autogen-version.def + +prog-name = 'summary'; +prog-title = 'compute various stastics from NTP stat files'; +package = ntp; +#include version.def + +long-opts; +gnu-usage; + +flag = { + name = directory; + arg-type = string; + arg-default = '/var/log/ntp'; + descrip = 'Directory containing stat files'; + doc = <<- _EndOfDoc_ + The directory where @code{ntpd} will search for .stat files generated + by @code{ntpd}. + _EndOfDoc_; +}; + +flag = { + name = end-date; + arg-type = number; + descrip = 'End date'; + doc = <<- _EndOfDoc_ + Process all files with the date suffix less or equal to value of this + option. Defaults to today minus one day (Use @code{date -u +%Y%m%d}) + to get the timestamp. + _EndOfDoc_; +}; + +flag = { + name = output-directory; + arg-type = str; + arg-default = '/tmp'; + descrip = 'Output directory'; + doc = <<- _EndOfDoc_ + The output directory @code{summary} will write all output files to. + _EndOfDoc_; +}; + +flag = { + name = peer-dist-limit; + arg-type = string; + arg-name = float; + arg-default = 400; + descrip = 'Peer dist limit'; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = skip-time-steps; + arg-type = string; + arg-name = float; + arg-default = 3600; + descrip = 'Ignore time offsets larger that this'; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = start-date; + arg-type = num; + arg-default = 19700101; + descrip = 'Start date'; + doc = <<- _EndOfDoc_ + Process all files with the date suffix more or equal to value of + this option. Defaults to 197000101. + _EndOfDoc_; +}; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'texi'; + ds-text = <<- _EndOfDoc + _EndOfDoc; +}; diff --git a/contrib/ntp/scripts/summary.1summaryman b/contrib/ntp/scripts/summary.1summaryman new file mode 100644 index 000000000..65b0eecdc --- /dev/null +++ b/contrib/ntp/scripts/summary.1summaryman @@ -0,0 +1,123 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH summary 1summaryman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-ghaazG/ag-shaiyG) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:56 PM by AutoGen 5.18.5 +.\" From the definitions summary-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]summary\fP +\- compute various stastics from NTP stat files +.SH SYNOPSIS +\f\*[B-Font]summary\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +.sp +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-\-directory\f[]=\f\*[I-Font]string\f[] +Directory containing stat files. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + /var/log/ntp +.sp + The directory where \fBntpd\fP will search for .stat files generated + by \fBntpd\fP. +.TP +.NOP \f\*[B-Font]\-\-end\-date\f[]=\f\*[I-Font]number\f[] +End date. +This option takes an integer number as its argument. +.sp + Process all files with the date suffix less or equal to value of this + option. Defaults to today minus one day (Use \fBdate \-u +%Y%m%d\fP) + to get the timestamp. +.TP +.NOP \f\*[B-Font]\-\-output\-directory\f[]=\f\*[I-Font]str\f[] +Output directory. +The default +\f\*[I-Font]str\f[] +for this option is: +.ti +4 + /tmp +.sp + The output directory \fBsummary\fP will write all output files to. +.TP +.NOP \f\*[B-Font]\-\-peer\-dist\-limit\f[]=\f\*[I-Font]float\f[] +Peer dist limit. +The default +\f\*[I-Font]float\f[] +for this option is: +.ti +4 + 400 +.sp +.TP +.NOP \f\*[B-Font]\-\-skip\-time\-steps\f[]=\f\*[I-Font]float\f[] +Ignore time offsets larger that this. +The default +\f\*[I-Font]float\f[] +for this option is: +.ti +4 + 3600 +.sp +.TP +.NOP \f\*[B-Font]\-\-start\-date\f[]=\f\*[I-Font]num\f[] +Start date. +This option takes an integer number as its argument. +The default +\f\*[I-Font]num\f[] +for this option is: +.ti +4 + 19700101 +.sp + Process all files with the date suffix more or equal to value of + this option. Defaults to 197000101. +.TP +.NOP \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBsummary\fP +option definitions. diff --git a/contrib/ntp/scripts/summary.1summarymdoc b/contrib/ntp/scripts/summary.1summarymdoc new file mode 100644 index 000000000..8bb1dfbba --- /dev/null +++ b/contrib/ntp/scripts/summary.1summarymdoc @@ -0,0 +1,98 @@ +.Dd October 21 2015 +.Dt SUMMARY 1summarymdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (summary-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:58 PM by AutoGen 5.18.5 +.\" From the definitions summary-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm summary +.Nd compute various stastics from NTP stat files +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.sp +.Sh "OPTIONS" +.Bl -tag +.It Fl \-directory Ns = Ns Ar string +Directory containing stat files. +The default +.Ar string +for this option is: +.ti +4 + /var/log/ntp +.sp + The directory where \fBntpd\fP will search for .stat files generated + by \fBntpd\fP. +.It Fl \-end\-date Ns = Ns Ar number +End date. +This option takes an integer number as its argument. +.sp + Process all files with the date suffix less or equal to value of this + option. Defaults to today minus one day (Use \fBdate \-u +%Y%m%d\fP) + to get the timestamp. +.It Fl \-output\-directory Ns = Ns Ar str +Output directory. +The default +.Ar str +for this option is: +.ti +4 + /tmp +.sp + The output directory \fBsummary\fP will write all output files to. +.It Fl \-peer\-dist\-limit Ns = Ns Ar float +Peer dist limit. +The default +.Ar float +for this option is: +.ti +4 + 400 +.sp +.It Fl \-skip\-time\-steps Ns = Ns Ar float +Ignore time offsets larger that this. +The default +.Ar float +for this option is: +.ti +4 + 3600 +.sp +.It Fl \-start\-date Ns = Ns Ar num +Start date. +This option takes an integer number as its argument. +The default +.Ar num +for this option is: +.ti +4 + 19700101 +.sp + Process all files with the date suffix more or equal to value of + this option. Defaults to 197000101. +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBsummary\fP +option definitions. diff --git a/contrib/ntp/scripts/summary.html b/contrib/ntp/scripts/summary.html new file mode 100644 index 000000000..13299056d --- /dev/null +++ b/contrib/ntp/scripts/summary.html @@ -0,0 +1,182 @@ + + +Summary User's Manual + + + + + + + + + +

      Summary User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      Summary User Manual

      + +

      This document describes the use of the NTP Project's summary program. +This document applies to version 4.2.8p4 of summary. + +

      +

      Short Contents

      + +
      + + + +
      +


      +Previous: summary Description, +Up: Top +
      +
      + +

      Invoking summary

      + +

      + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the summary program. + +

      + + + +

      summary help/usage (--help)

      + +

      +This is the automatically generated usage text for summary. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

      summary - compute various stastics from NTP stat files - Ver. 4.2.8p4
      +USAGE: summary [ -<flag> [<val>] | --<name>[{=| }<val>] ]...
      +
      +        --directory=str          Directory containing stat files
      +        --end-date=num           End date
      +        --output-directory=str   Output directory
      +        --peer-dist-limit=float  Peer dist limit
      +        --skip-time-steps=float  Ignore time offsets larger that this
      +        --start-date=num         Start date
      +    -?, --help                   Display usage information and exit
      +        --more-help              Pass the extended usage text through a pager
      +
      +Options are specified by doubled hyphens and their name or by a single
      +hyphen and the flag character.
      +
      +
      +


      +Next: , +Previous: summary usage, +Up: summary Invocation +
      +
      + +

      directory option

      + +

      +This is the “directory containing stat files” option. +This option takes a string argument. + The directory where ntpd will search for .stat files generated + by ntpd. +

      + +

      end-date option

      + +

      +This is the “end date” option. +This option takes a number argument. + Process all files with the date suffix less or equal to value of this + option. Defaults to today minus one day (Use date -u +%Y%m%d) + to get the timestamp. +

      +


      +Next: , +Previous: summary end-date, +Up: summary Invocation +
      +
      + +

      output-directory option

      + +

      +This is the “output directory” option. +This option takes a str argument. + The output directory summary will write all output files to. +

      + +

      start-date option

      + +

      +This is the “start date” option. +This option takes a num argument. + Process all files with the date suffix more or equal to value of + this option. Defaults to 197000101. +

      +


      +Previous: summary start-date, +Up: summary Invocation +
      +
      + +

      summary exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      + + + diff --git a/contrib/ntp/scripts/summary.in b/contrib/ntp/scripts/summary.in index 515dfc6b5..a99f8df0e 100644 --- a/contrib/ntp/scripts/summary.in +++ b/contrib/ntp/scripts/summary.in @@ -18,55 +18,90 @@ # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - -require 5.003; # "never tested with any other version of Perl" +package summary; +use 5.006_000; use strict; -use Getopt::Long; +my ($log_date_pattern, $statsdir, $outputdir, $skip_time_steps, $startdate, + $enddate, $peer_dist_limit); -my $log_date_pattern = '[12]\d{3}[01]\d[0-3]\d'; -my $statsdir = "/var/log/ntp"; # directory with input files -my $outputdir = "/tmp"; # directory for output files -my $skip_time_steps = 3600.0; # ignore time offsets larger that this -my $startdate = "19700101"; # first data file to use (YYYYMMDD) -my $enddate=`date -u +%Y%m%d`; chomp $enddate; --$enddate; -my $peer_dist_limit = 400.0; +exit run(@ARGV) unless caller; -my %options = ("directory|input-directory=s" => \$statsdir, - "output-directory=s" => \$outputdir, - "skip-time-steps:f" => \$skip_time_steps, - "start-date=s" => \$startdate, - "end-date=s" => \$enddate, - "peer-dist-limit=f" => \$peer_dist_limit); +sub run { + my $opts; + if (!processOptions(\@ARGV, $opts)) { + usage(1); + }; -if ( !GetOptions(%options) ) -{ - print STDERR "valid options for $0 are:\n"; - my $opt; - foreach $opt (sort(keys %options)) { - print STDERR "\t--$opt\t(default is "; - if ( ref($options{$opt}) eq "ARRAY" ) { - print STDERR join(", ", map { "'$_'" } @{$options{$opt}}); - } else { - print STDERR "'${$options{$opt}}'"; - } - print STDERR ")\n"; + $log_date_pattern = '[12]\d{3}[01]\d[0-3]\d'; + $statsdir = $opts->{directory}; + $outputdir = $opts->{'output-directory'}; + $skip_time_steps = $opts->{'skip-time-steps'}; + $startdate = $opts->{'start-date'}; + $enddate = $opts->{'end-date'}; + if (!$enddate){ + $enddate = `date -u +%Y%m%d`; + chomp $enddate; + --$enddate; } - print STDERR "\n"; - die; -} + $peer_dist_limit = $opts->{'peer-dist-limit'}; + + # check possibly current values of options + die "$statsdir: no such directory" unless (-d $statsdir); + die "$outputdir: no such directory" unless (-d $outputdir); + die "$skip_time_steps: skip-time-steps must be positive" + unless ($skip_time_steps >= 0.0); + die "$startdate: invalid start date|$`|$&|$'" + unless ($startdate =~ m/.*$log_date_pattern$/); + die "$enddate: invalid end date" + unless ($enddate =~ m/.*$log_date_pattern$/); + + $skip_time_steps = 0.128 if ($skip_time_steps == 0); + + my $loop_summary="$outputdir/loop_summary"; + my $peer_summary="$outputdir/peer_summary"; + my $clock_summary="$outputdir/clock_summary"; + my (@loopfiles, @peerfiles, @clockfiles); -# check possibly current values of options -die "$statsdir: no such directory" unless (-d $statsdir); -die "$outputdir: no such directory" unless (-d $outputdir); -die "$skip_time_steps: skip-time-steps must be positive" - unless ($skip_time_steps >= 0.0); -die "$startdate: invalid start date|$`|$&|$'" - unless ($startdate =~ m/.*$log_date_pattern$/); -die "$enddate: invalid end date" - unless ($enddate =~ m/.*$log_date_pattern$/); + print STDERR "Creating summaries from $statsdir ($startdate to $enddate)\n"; -$skip_time_steps = 0.128 if ($skip_time_steps == 0); + opendir SDIR, $statsdir or die "directory ${statsdir}: $!"; + rewinddir SDIR; + @loopfiles=sort grep /loop.*$log_date_pattern/, readdir SDIR; + rewinddir SDIR; + @peerfiles=sort grep /peer.*$log_date_pattern/, readdir SDIR; + rewinddir SDIR; + @clockfiles=sort grep /clock.*$log_date_pattern/, readdir SDIR; + closedir SDIR; + + # remove old summary files + for ($loop_summary, $peer_summary, $clock_summary) { unlink $_ if -f $_ }; + + my $date; + for (@loopfiles) { + $date = $_; $date =~ s/.*($log_date_pattern)$/$1/; + if ($date ge $startdate && $date le $enddate) { + do_loop($statsdir, $_, $loop_summary); + } + } + + for (@peerfiles) { + $date = $_; $date =~ s/.*($log_date_pattern)$/$1/; + if ($date ge $startdate && $date le $enddate) { + do_peer($statsdir, $_, $peer_summary); + } + } + + for (@clockfiles) { + $date = $_; $date =~ s/.*($log_date_pattern)$/$1/; + if ($date ge $startdate && $date le $enddate) { + do_clock($statsdir, $_, $clock_summary); + } + } + + print STDERR "Creating peer summary with limit $peer_dist_limit\n"; + peer_summary($peer_summary) if (-f $peer_summary); +} sub min { @@ -328,46 +363,7 @@ sub peer_summary print sort @lines; } -my $loop_summary="$outputdir/loop_summary"; -my $peer_summary="$outputdir/peer_summary"; -my $clock_summary="$outputdir/clock_summary"; -my (@loopfiles, @peerfiles, @clockfiles); - -print STDERR "Creating summaries from $statsdir ($startdate to $enddate)\n"; - -opendir SDIR, $statsdir or die "directory ${statsdir}: $!"; -rewinddir SDIR; -@loopfiles=sort grep /loop.*$log_date_pattern/, readdir SDIR; -rewinddir SDIR; -@peerfiles=sort grep /peer.*$log_date_pattern/, readdir SDIR; -rewinddir SDIR; -@clockfiles=sort grep /clock.*$log_date_pattern/, readdir SDIR; -closedir SDIR; - -# remove old summary files -map { unlink $_ if -f $_ } ($loop_summary, $peer_summary, $clock_summary); - -my $date; -map { - $date = $_; $date =~ s/.*($log_date_pattern)$/$1/; - if ($date ge $startdate && $date le $enddate) { - do_loop $statsdir, $_, $loop_summary; - } -} @loopfiles; - -map { - $date = $_; $date =~ s/.*($log_date_pattern)$/$1/; - if ($date ge $startdate && $date le $enddate) { - do_peer $statsdir, $_, $peer_summary; - } -} @peerfiles; - -map { - $date = $_; $date =~ s/.*($log_date_pattern)$/$1/; - if ($date ge $startdate && $date le $enddate) { - do_clock $statsdir, $_, $clock_summary; - } -} @clockfiles; +@summary_opts@ -print STDERR "Creating peer summary with limit $peer_dist_limit\n"; -peer_summary $peer_summary if (-f $peer_summary); +1; +__END__ diff --git a/contrib/ntp/scripts/summary.man.in b/contrib/ntp/scripts/summary.man.in new file mode 100644 index 000000000..65b0eecdc --- /dev/null +++ b/contrib/ntp/scripts/summary.man.in @@ -0,0 +1,123 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH summary 1summaryman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-ghaazG/ag-shaiyG) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:56 PM by AutoGen 5.18.5 +.\" From the definitions summary-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]summary\fP +\- compute various stastics from NTP stat files +.SH SYNOPSIS +\f\*[B-Font]summary\fP +[\f\*[B-Font]\-\-option-name\f[]] +[\f\*[B-Font]\-\-option-name\f[] \f\*[I-Font]value\f[]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +.sp +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-\-directory\f[]=\f\*[I-Font]string\f[] +Directory containing stat files. +The default +\f\*[I-Font]string\f[] +for this option is: +.ti +4 + /var/log/ntp +.sp + The directory where \fBntpd\fP will search for .stat files generated + by \fBntpd\fP. +.TP +.NOP \f\*[B-Font]\-\-end\-date\f[]=\f\*[I-Font]number\f[] +End date. +This option takes an integer number as its argument. +.sp + Process all files with the date suffix less or equal to value of this + option. Defaults to today minus one day (Use \fBdate \-u +%Y%m%d\fP) + to get the timestamp. +.TP +.NOP \f\*[B-Font]\-\-output\-directory\f[]=\f\*[I-Font]str\f[] +Output directory. +The default +\f\*[I-Font]str\f[] +for this option is: +.ti +4 + /tmp +.sp + The output directory \fBsummary\fP will write all output files to. +.TP +.NOP \f\*[B-Font]\-\-peer\-dist\-limit\f[]=\f\*[I-Font]float\f[] +Peer dist limit. +The default +\f\*[I-Font]float\f[] +for this option is: +.ti +4 + 400 +.sp +.TP +.NOP \f\*[B-Font]\-\-skip\-time\-steps\f[]=\f\*[I-Font]float\f[] +Ignore time offsets larger that this. +The default +\f\*[I-Font]float\f[] +for this option is: +.ti +4 + 3600 +.sp +.TP +.NOP \f\*[B-Font]\-\-start\-date\f[]=\f\*[I-Font]num\f[] +Start date. +This option takes an integer number as its argument. +The default +\f\*[I-Font]num\f[] +for this option is: +.ti +4 + 19700101 +.sp + Process all files with the date suffix more or equal to value of + this option. Defaults to 197000101. +.TP +.NOP \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBsummary\fP +option definitions. diff --git a/contrib/ntp/scripts/summary.mdoc.in b/contrib/ntp/scripts/summary.mdoc.in new file mode 100644 index 000000000..8bb1dfbba --- /dev/null +++ b/contrib/ntp/scripts/summary.mdoc.in @@ -0,0 +1,98 @@ +.Dd October 21 2015 +.Dt SUMMARY 1summarymdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (summary-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:58 PM by AutoGen 5.18.5 +.\" From the definitions summary-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm summary +.Nd compute various stastics from NTP stat files +.Sh SYNOPSIS +.Nm +.Op Fl \-option\-name +.Op Fl \-option\-name Ar value +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.sp +.Sh "OPTIONS" +.Bl -tag +.It Fl \-directory Ns = Ns Ar string +Directory containing stat files. +The default +.Ar string +for this option is: +.ti +4 + /var/log/ntp +.sp + The directory where \fBntpd\fP will search for .stat files generated + by \fBntpd\fP. +.It Fl \-end\-date Ns = Ns Ar number +End date. +This option takes an integer number as its argument. +.sp + Process all files with the date suffix less or equal to value of this + option. Defaults to today minus one day (Use \fBdate \-u +%Y%m%d\fP) + to get the timestamp. +.It Fl \-output\-directory Ns = Ns Ar str +Output directory. +The default +.Ar str +for this option is: +.ti +4 + /tmp +.sp + The output directory \fBsummary\fP will write all output files to. +.It Fl \-peer\-dist\-limit Ns = Ns Ar float +Peer dist limit. +The default +.Ar float +for this option is: +.ti +4 + 400 +.sp +.It Fl \-skip\-time\-steps Ns = Ns Ar float +Ignore time offsets larger that this. +The default +.Ar float +for this option is: +.ti +4 + 3600 +.sp +.It Fl \-start\-date Ns = Ns Ar num +Start date. +This option takes an integer number as its argument. +The default +.Ar num +for this option is: +.ti +4 + 19700101 +.sp + Process all files with the date suffix more or equal to value of + this option. Defaults to 197000101. +.It Fl \-help +Display usage information and exit. +.It Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBsummary\fP +option definitions. diff --git a/contrib/ntp/scripts/summary.texi b/contrib/ntp/scripts/summary.texi new file mode 100644 index 000000000..5f1548ac4 --- /dev/null +++ b/contrib/ntp/scripts/summary.texi @@ -0,0 +1,40 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename summary.info +@settitle Summary User's Manual +@include ../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of @code{summary}, +a program from the NTP Project +@end ifinfo + +@direntry +* summary: (summary). Summarize (something) +@end direntry + +@titlepage +@title summary User's Manual +@subtitle summary, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, summary Description, (dir), (dir) +@top Summary User Manual + +This document describes the use of the NTP Project's @code{summary} program. +This document applies to version @value{VERSION} of @code{summary}. + +@shortcontents + +@menu +* summary Description:: Description +* summary Invocation:: Invoking summary +@end menu + +@include invoke-summary.texi diff --git a/contrib/ntp/scripts/update-leap/Makefile.am b/contrib/ntp/scripts/update-leap/Makefile.am new file mode 100644 index 000000000..9b5829a0b --- /dev/null +++ b/contrib/ntp/scripts/update-leap/Makefile.am @@ -0,0 +1,98 @@ +NULL= +run_ag= cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" PERL5LIB="$(abs_top_srcdir)/scripts/lib" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +bin_SCRIPTS= $(UPDATE_LEAP_DB) +sbin_SCRIPTS= $(UPDATE_LEAP_DS) +libexec_SCRIPTS= $(UPDATE_LEAP_DL) +noinst_SCRIPTS= $(UPDATE_LEAP_NI) +EXTRA_SCRIPTS= update-leap + +man1_MANS= +man8_MANS= +if INSTALL_UPDATE_LEAP +man_MANS= update-leap.$(UPDATE_LEAP_MS) +else +noinst_MANS= update-leap.$(UPDATE_LEAP_MS) +endif + +EXTRA_DIST = \ + invoke-update-leap.menu \ + invoke-update-leap.texi \ + update-leap-opts.def \ + update-leap-opts \ + update-leap.1update-leapman \ + update-leap.1update-leapmdoc \ + update-leap.in \ + update-leap.man.in \ + update-leap.mdoc.in \ + update-leap.sh \ + update-leap.texi \ + update-leap.html \ + $(NULL) + +html_DATA = update-leap.html + +#CLEANFILES = update-leap.1 +DISTCLEANFILES = config.log $(man_MANS) $(noinst_MANS) + +noinst_DATA = \ + invoke-update-leap.menu \ + invoke-update-leap.texi \ + update-leap.man.in \ + update-leap.mdoc.in \ + update-leap-opts \ + $(NULL) + +$(srcdir)/update-leap: $(srcdir)/update-leap-opts + @: do-nothing action to avoid default SCCS get + +$(srcdir)/update-leap-opts: update-leap-opts.def $(std_def_list) + $(run_ag) update-leap-opts.def + +### Man + +$(srcdir)/update-leap.1update-leapman: $(srcdir)/update-leap-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1update-leapman -Tagman-cmd.tpl update-leap-opts.def + +$(srcdir)/update-leap.man.in: $(srcdir)/update-leap.1update-leapman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/update-leap.1update-leapman > $(srcdir)/update-leap.man.in+ + mv $(srcdir)/update-leap.man.in+ $(srcdir)/update-leap.man.in + +### Mdoc + +$(srcdir)/update-leap.1update-leapmdoc: $(srcdir)/update-leap-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1update-leapmdoc -Tagmdoc-cmd.tpl update-leap-opts.def + +$(srcdir)/update-leap.mdoc.in: $(srcdir)/update-leap.1update-leapmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/update-leap.1update-leapmdoc > $(srcdir)/update-leap.mdoc.in+ + mv $(srcdir)/update-leap.mdoc.in+ $(srcdir)/update-leap.mdoc.in + +### Manpage + +update-leap.$(UPDATE_LEAP_MS): $(srcdir)/update-leap.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=update-leap.$(UPDATE_LEAP_MS)+:$(srcdir)/update-leap.$(MANTAGFMT).in + mv update-leap.$(UPDATE_LEAP_MS)+ update-leap.$(UPDATE_LEAP_MS) + +### Texinfo + +$(srcdir)/invoke-update-leap.menu: $(srcdir)/invoke-update-leap.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-update-leap.texi: $(srcdir)/update-leap-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section update-leap-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/update-leap.html: $(srcdir)/update-leap.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o update-leap.html update-leap.texi || true ) diff --git a/contrib/ntp/scripts/update-leap/Makefile.in b/contrib/ntp/scripts/update-leap/Makefile.in new file mode 100644 index 000000000..dc4f56814 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/Makefile.in @@ -0,0 +1,978 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = scripts/update-leap +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/sntp/libopts/m4/libopts.m4 \ + $(top_srcdir)/sntp/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/sntp/m4/ax_c99_struct_init.m4 \ + $(top_srcdir)/sntp/m4/define_dir.m4 \ + $(top_srcdir)/sntp/m4/hms_search_lib.m4 \ + $(top_srcdir)/sntp/m4/libtool.m4 \ + $(top_srcdir)/sntp/m4/ltoptions.m4 \ + $(top_srcdir)/sntp/m4/ltsugar.m4 \ + $(top_srcdir)/sntp/m4/ltversion.m4 \ + $(top_srcdir)/sntp/m4/lt~obsolete.m4 \ + $(top_srcdir)/sntp/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/sntp/m4/ntp_compiler.m4 \ + $(top_srcdir)/sntp/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/sntp/m4/ntp_crypto_rand.m4 \ + $(top_srcdir)/sntp/m4/ntp_debug.m4 \ + $(top_srcdir)/sntp/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/sntp/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/sntp/m4/ntp_googletest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ipv6.m4 \ + $(top_srcdir)/sntp/m4/ntp_lib_m.m4 \ + $(top_srcdir)/sntp/m4/ntp_libevent.m4 \ + $(top_srcdir)/sntp/m4/ntp_libntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/sntp/m4/ntp_locinfo.m4 \ + $(top_srcdir)/sntp/m4/ntp_openssl.m4 \ + $(top_srcdir)/sntp/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/sntp/m4/ntp_problemtests.m4 \ + $(top_srcdir)/sntp/m4/ntp_prog_cc.m4 \ + $(top_srcdir)/sntp/m4/ntp_rlimit.m4 \ + $(top_srcdir)/sntp/m4/ntp_sntp.m4 \ + $(top_srcdir)/sntp/m4/ntp_unitytest.m4 \ + $(top_srcdir)/sntp/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/sntp/m4/ntp_vpathhack.m4 \ + $(top_srcdir)/sntp/m4/openldap-thread-check.m4 \ + $(top_srcdir)/sntp/m4/openldap.m4 \ + $(top_srcdir)/sntp/m4/os_cflags.m4 \ + $(top_srcdir)/sntp/m4/snprintf.m4 \ + $(top_srcdir)/sntp/m4/version.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = update-leap +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +SCRIPTS = $(bin_SCRIPTS) $(libexec_SCRIPTS) $(noinst_SCRIPTS) \ + $(sbin_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 +NROFF = nroff +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/update-leap.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CHUTEST = @CHUTEST@ +CONFIG_SHELL = @CONFIG_SHELL@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCFD = @DCFD@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +HAVE_LEAPSMEARINTERVAL = @HAVE_LEAPSMEARINTERVAL@ +HAVE_RLIMIT_MEMLOCK = @HAVE_RLIMIT_MEMLOCK@ +HAVE_RLIMIT_STACK = @HAVE_RLIMIT_STACK@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NLIST = @LDADD_NLIST@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBPARSE = @LIBPARSE@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LSCF = @LSCF@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKE_ADJTIMED = @MAKE_ADJTIMED@ +MAKE_CHECK_LAYOUT = @MAKE_CHECK_LAYOUT@ +MAKE_CHECK_Y2K = @MAKE_CHECK_Y2K@ +MAKE_LIBNTPSIM = @MAKE_LIBNTPSIM@ +MAKE_LIBPARSE = @MAKE_LIBPARSE@ +MAKE_LIBPARSE_KERNEL = @MAKE_LIBPARSE_KERNEL@ +MAKE_NTPDSIM = @MAKE_NTPDSIM@ +MAKE_NTPSNMPD = @MAKE_NTPSNMPD@ +MAKE_NTPTIME = @MAKE_NTPTIME@ +MAKE_PARSEKMODULE = @MAKE_PARSEKMODULE@ +MAKE_TICKADJ = @MAKE_TICKADJ@ +MAKE_TIMETRIM = @MAKE_TIMETRIM@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_KEYSDIR = @NTP_KEYSDIR@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_NET_SNMP_CONFIG = @PATH_NET_SNMP_CONFIG@ +PATH_PERL = @PATH_PERL@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PATH_TEST = @PATH_TEST@ +PERLLIBDIR = @PERLLIBDIR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PROPDELAY = @PROPDELAY@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNMP_CFLAGS = @SNMP_CFLAGS@ +SNMP_CPPFLAGS = @SNMP_CPPFLAGS@ +SNMP_LIBS = @SNMP_LIBS@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TESTDCF = @TESTDCF@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +YACC = @YACC@ +YFLAGS = @YFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" PERL5LIB="$(abs_top_srcdir)/scripts/lib" AUTOGEN_DNE_DATE=-D \ + autogen -L ../../sntp/include -L ../../sntp/ag-tpl \ + --writable + +std_def_list = \ + $(top_srcdir)/sntp/include/debug-opt.def \ + $(top_srcdir)/sntp/include/autogen-version.def \ + $(top_srcdir)/sntp/include/copyright.def \ + $(top_srcdir)/sntp/include/homerc.def \ + $(top_srcdir)/sntp/include/ntp.lic \ + $(top_srcdir)/sntp/include/version.def \ + $(NULL) + +bin_SCRIPTS = $(UPDATE_LEAP_DB) +sbin_SCRIPTS = $(UPDATE_LEAP_DS) +libexec_SCRIPTS = $(UPDATE_LEAP_DL) +noinst_SCRIPTS = $(UPDATE_LEAP_NI) +EXTRA_SCRIPTS = update-leap +man1_MANS = +man8_MANS = +@INSTALL_UPDATE_LEAP_TRUE@man_MANS = update-leap.$(UPDATE_LEAP_MS) +@INSTALL_UPDATE_LEAP_FALSE@noinst_MANS = update-leap.$(UPDATE_LEAP_MS) +EXTRA_DIST = \ + invoke-update-leap.menu \ + invoke-update-leap.texi \ + update-leap-opts.def \ + update-leap-opts \ + update-leap.1update-leapman \ + update-leap.1update-leapmdoc \ + update-leap.in \ + update-leap.man.in \ + update-leap.mdoc.in \ + update-leap.sh \ + update-leap.texi \ + update-leap.html \ + $(NULL) + +html_DATA = update-leap.html + +#CLEANFILES = update-leap.1 +DISTCLEANFILES = config.log $(man_MANS) $(noinst_MANS) +noinst_DATA = \ + invoke-update-leap.menu \ + invoke-update-leap.texi \ + update-leap.man.in \ + update-leap.mdoc.in \ + update-leap-opts \ + $(NULL) + +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/update-leap/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign scripts/update-leap/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +update-leap: $(top_builddir)/config.status $(srcdir)/update-leap.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +install-binSCRIPTS: $(bin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir) +install-libexecSCRIPTS: $(libexec_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_SCRIPTS)'; test -n "$(libexecdir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(libexecdir)'; $(am__uninstall_files_from_dir) +install-sbinSCRIPTS: $(sbin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_SCRIPTS)'; test -n "$(sbindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(sbindir)'; $(am__uninstall_files_from_dir) + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-man1: $(man1_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ + done; } + +uninstall-man1: + @$(NORMAL_UNINSTALL) + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.1[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(SCRIPTS) $(MANS) $(DATA) +installdirs: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-htmlDATA install-man + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-binSCRIPTS install-libexecSCRIPTS \ + install-sbinSCRIPTS + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: install-man1 install-man8 + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-binSCRIPTS uninstall-htmlDATA \ + uninstall-libexecSCRIPTS uninstall-man uninstall-sbinSCRIPTS + +uninstall-man: uninstall-man1 uninstall-man8 + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-binSCRIPTS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-htmlDATA \ + install-info install-info-am install-libexecSCRIPTS \ + install-man install-man1 install-man8 install-pdf \ + install-pdf-am install-ps install-ps-am install-sbinSCRIPTS \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags-am uninstall uninstall-am uninstall-binSCRIPTS \ + uninstall-htmlDATA uninstall-libexecSCRIPTS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinSCRIPTS + +.PRECIOUS: Makefile + + +$(srcdir)/update-leap: $(srcdir)/update-leap-opts + @: do-nothing action to avoid default SCCS get + +$(srcdir)/update-leap-opts: update-leap-opts.def $(std_def_list) + $(run_ag) update-leap-opts.def + +### Man + +$(srcdir)/update-leap.1update-leapman: $(srcdir)/update-leap-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1update-leapman -Tagman-cmd.tpl update-leap-opts.def + +$(srcdir)/update-leap.man.in: $(srcdir)/update-leap.1update-leapman $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/update-leap.1update-leapman > $(srcdir)/update-leap.man.in+ + mv $(srcdir)/update-leap.man.in+ $(srcdir)/update-leap.man.in + +### Mdoc + +$(srcdir)/update-leap.1update-leapmdoc: $(srcdir)/update-leap-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1update-leapmdoc -Tagmdoc-cmd.tpl update-leap-opts.def + +$(srcdir)/update-leap.mdoc.in: $(srcdir)/update-leap.1update-leapmdoc $(top_srcdir)/sntp/scripts/mansec2subst.sed + sed -f $(top_srcdir)/sntp/scripts/mansec2subst.sed $(srcdir)/update-leap.1update-leapmdoc > $(srcdir)/update-leap.mdoc.in+ + mv $(srcdir)/update-leap.mdoc.in+ $(srcdir)/update-leap.mdoc.in + +### Manpage + +update-leap.$(UPDATE_LEAP_MS): $(srcdir)/update-leap.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=update-leap.$(UPDATE_LEAP_MS)+:$(srcdir)/update-leap.$(MANTAGFMT).in + mv update-leap.$(UPDATE_LEAP_MS)+ update-leap.$(UPDATE_LEAP_MS) + +### Texinfo + +$(srcdir)/invoke-update-leap.menu: $(srcdir)/invoke-update-leap.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-update-leap.texi: $(srcdir)/update-leap-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section update-leap-opts.def + $(top_srcdir)/scripts/build/check--help $@ + +### HTML + +$(srcdir)/update-leap.html: $(srcdir)/update-leap.texi $(top_srcdir)/sntp/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -I ../sntp -o update-leap.html update-leap.texi || true ) + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/scripts/update-leap/invoke-update-leap.menu b/contrib/ntp/scripts/update-leap/invoke-update-leap.menu new file mode 100644 index 000000000..e27e34925 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/invoke-update-leap.menu @@ -0,0 +1 @@ +* update-leap Invocation:: Invoking update-leap diff --git a/contrib/ntp/scripts/update-leap/invoke-update-leap.texi b/contrib/ntp/scripts/update-leap/invoke-update-leap.texi new file mode 100644 index 000000000..da6df52f0 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/invoke-update-leap.texi @@ -0,0 +1,219 @@ +@node update-leap Invocation +@section Invoking update-leap +@pindex update-leap +@cindex leap-seconds file manager/updater +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-update-leap.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:38 PM by AutoGen 5.18.5 +# From the definitions update-leap-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + + +@code{update-leap} +will validate the file currently on the local system +and if necessary, updates leap-second definition file. + +Ordinarily, the file is found using the "leapfile" directive in +@code{ntp.conf(5)}. +However, an alternate location can be specified on the command line. + +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. + +If the current file is acceptable, no download or restart occurs. + +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. +.PP +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. +.PP +For cron-friendly behavior, define CRONJOB=1 in the crontab. +.PP +This script depends on$REQUIREDCMDS + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{update-leap} program. + +@menu +* update-leap usage:: update-leap help/usage (@option{--help}) +* update-leap source-url:: source-url option (-s) +* update-leap ipv4:: ipv4 option (-4) +* update-leap destination:: destination option (-d) +* update-leap expiration:: expiration option (-e) +* update-leap ntp-conf-file:: ntp-conf-file option (-f) +* update-leap force-update:: force-update option (-F) +* update-leap exit status:: exit status +* update-leap Usage:: Usage +* update-leap Authors:: Authors +@end menu + +@node update-leap usage +@subsection update-leap help/usage (@option{--help}) +@cindex update-leap help + +This is the automatically generated usage text for update-leap. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example + update-leap + Usage: $0 [options] [leapfile] + + Verifies and if necessary, updates leap-second definition file + + All arguments are optional: Default (or current value) shown: -s + Specify the URL of the master copy to download $LEAPSRC -d Specify + the filename on the local system $LEAPFILE -e Specify how long (in + days) before expiration the file is to be refreshed. Note that + larger values imply more frequent refreshes. "$PREFETCH" -f Specify + location of ntp.conf (used to make sure leapfile directive is + present and to default leapfile) $NTPCONF -F Force update even if + current file is OK and not close to expiring. -r Specify number of + times to retry on get failure $MAXTRIES -i Specify number of minutes + between retries $INTERVAL -l Use syslog for output (Implied if + CRONJOB is set) -L Don't use syslog for output -P Specify the syslog + facility for logging $LOGFAC -t Name of temporary file used in + validation $TMPFILE -q Only report errors to stdout -v Verbose + output + + The following options are not (yet) implemented in the perl version: + -4 Use only IPv4 -6 Use only IPv6 -c Command to restart NTP after + installing a new file - ntpd checks file daily -p 4|6 Prefer + IPv4 or IPv6 (as specified) addresses, but use either -z Specify + path for utilities $PATHLIST -Z Only use system path + + $0 will validate the file currently on the local system + + Ordinarily, the file is found using the "leapfile" directive in + $NTPCONF. However, an alternate location can be specified on the + command line. + + If the file does not exist, is not valid, has expired, or is + expiring soon, a new copy will be downloaded. If the new copy + validates, it is installed and NTP is (optionally) restarted. + + If the current file is acceptable, no download or restart occurs. + + -c can also be used to invoke another script to perform + administrative functions, e.g. to copy the file to other local + systems. + + This can be run as a cron job. As the file is rarely updated, and + leap seconds are announced at least one month in advance (usually + longer), it need not be run more frequently than about once every + three weeks. + + For cron-friendly behavior, define CRONJOB=1 in the crontab. + + Version $VERSION +@end example +@exampleindent 4 + +@node update-leap source-url +@subsection source-url option (-s) +@cindex update-leap-source-url + +This is the ``the url of the master copy of the leapseconds file'' option. +This option takes a string argument. +Specify the URL of the master copy to download +$LEAPSRC +@node update-leap ipv4 +@subsection ipv4 option (-4) +@cindex update-leap-ipv4 + +This is the ``use only ipv4 addresses for dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv6. +@end itemize + + Force DNS resolution of following host names on the command line + to the IPv4 namespace. + _EndOfDoc_; +}; + +flag = { + name = ipv6; + flags-cant = ipv4, prefer; + value = 6; + descrip = "Use only IPv6 addresses for DNS name resolution"; + doc = <<- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv6 namespace. + _EndOfDoc_; +}; + +flag = { + name = prefer; + flags-cant = ipv4, ipv6; + value = p; + arg-type = keyword; + keyword = 4, 6; + descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either'; + doc = <<- _EndOfDoc_ +Prefer IPv4 or IPv6 (as specified) addresses, but use either. +@node update-leap destination +@subsection destination option (-d) +@cindex update-leap-destination + +This is the ``filename on the local system'' option. +This option takes a string argument @file{float}. +The name to use to store the leapfile on the local system. +$LEAPFILE +@node update-leap expiration +@subsection expiration option (-e) +@cindex update-leap-expiration + +This is the ``refresh the leapfile this long before it expires'' option. +This option takes a string argument. +Specify how long before expiration the file is to be refreshed +Units are required, e.g. "-e 60 days" Note that larger values +imply more frequent refreshes. +"$PREFETCH" +@node update-leap ntp-conf-file +@subsection ntp-conf-file option (-f) +@cindex update-leap-ntp-conf-file + +This is the ``location of the ntp.conf file'' option. +This option takes a string argument. +Specify location of ntp.conf (used to make sure leapfile directive is +present and to default leapfile) +/etc/ntp.conf +@node update-leap force-update +@subsection force-update option (-F) +@cindex update-leap-force-update + +This is the ``force update of the leapfile'' option. +Force update even if current file is OK and not close to expiring. +@node update-leap exit status +@subsection update-leap exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@end table +@node update-leap Usage +@subsection update-leap Usage +@node update-leap Authors +@subsection update-leap Authors diff --git a/contrib/ntp/scripts/update-leap/update-leap-opts b/contrib/ntp/scripts/update-leap/update-leap-opts new file mode 100644 index 000000000..debf33339 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap-opts @@ -0,0 +1,72 @@ +# EDIT THIS FILE WITH CAUTION (update-leap-opts) +# +# It has been AutoGen-ed October 21, 2015 at 12:34:44 PM by AutoGen 5.18.5 +# From the definitions update-leap-opts.def +# and the template file perlopt + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + 'source-url' => '', + 'ipv4' => '', + 'destination' => '', + 'expiration' => '', + 'ntp-conf-file' => '', + 'force-update' => '', + 'dont-wait' => '', + 'help' => '', 'more-help' => '' + }; + my $argument = ''; + my $ret = GetOptionsFromArray($args, $opts, ( + 'source-url|s=s', 'ipv4|4', 'destination|d=f', + 'expiration|e=s', 'ntp-conf-file|f=s', 'force-update|F', + 'dont-wait', + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +update-leap - leap-seconds file manager/updater - Ver. 4.2.8p4 +USAGE: update-leap [ - [] | --[{=| }] ]... + + -s, --source-url=str The URL of the master copy of the leapseconds file + -4, --ipv4 Use only IPv4 addresses for DNS name resolution + -d, --destination=float Filename on the local system + -e, --expiration=str Refresh the leapfile this long before it expires + -f, --ntp-conf-file=str Location of the ntp.conf file + -F, --force-update Force update of the leapfile + --dont-wait Don't wait for keystroke between plots + -?, --help Display usage information and exit + --more-help Pass the extended usage text through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'}; + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/scripts/update-leap/update-leap-opts.def b/contrib/ntp/scripts/update-leap/update-leap-opts.def new file mode 100644 index 000000000..9e73916ba --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap-opts.def @@ -0,0 +1,163 @@ +/* -*- Mode: Text -*- */ +autogen definitions perlopt; + +#include autogen-version.def + +prog-name = 'update-leap'; +prog-title = 'leap-seconds file manager/updater'; +package = ntp; +#include version.def + +long-opts; +gnu-usage; + +flag = { + name = source-url; + value = s; + arg-type = string; + descrip = 'The URL of the master copy of the leapseconds file'; + doc = <<- _EndOfDoc_ + Specify the URL of the master copy to download + $LEAPSRC + _EndOfDoc_; +}; +flag = { + name = ipv4; + flags-cant = ipv6; + value = 4; + descrip = "Use only IPv4 addresses for DNS name resolution"; + doc = <<- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv4 namespace. + _EndOfDoc_; +}; + +flag = { + name = ipv6; + flags-cant = ipv4, prefer; + value = 6; + descrip = "Use only IPv6 addresses for DNS name resolution"; + doc = <<- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv6 namespace. + _EndOfDoc_; +}; + +flag = { + name = prefer; + flags-cant = ipv4, ipv6; + value = p; + arg-type = keyword; + keyword = 4, 6; + descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either'; + doc = <<- _EndOfDoc_ + Prefer IPv4 or IPv6 (as specified) addresses, but use either. + _EndOfDoc_; +}; + +flag = { + name = destination; + value = d; + arg-type = string; + arg-name = float; + descrip = 'Filename on the local system'; + doc = <<- _EndOfDoc_ + The name to use to store the leapfile on the local system. + $LEAPFILE + _EndOfDoc_; +}; + +flag = { + name = expiration; + value = e; + arg-type = string; + descrip = 'Refresh the leapfile this long before it expires'; + doc = <<- _EndOfDoc_ + Specify how long before expiration the file is to be refreshed + Units are required, e.g. "-e 60 days" Note that larger values + imply more frequent refreshes. + "$PREFETCH" + _EndOfDoc_; +}; + +flag = { + name = ntp-conf-file; + value = f; + arg-type = string; + descrip = 'Location of the ntp.conf file'; + doc = <<- _EndOfDoc_ + Specify location of ntp.conf (used to make sure leapfile directive is + present and to default leapfile) + /etc/ntp.conf + _EndOfDoc_; +}; + +flag = { + name = force-update; + value = F; + descrip = 'Force update of the leapfile'; + doc = <<- _EndOfDoc_ + Force update even if current file is OK and not close to expiring. + _EndOfDoc_; +}; + +flag = { + name = dont-wait; + descrip = "Don't wait for keystroke between plots"; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +/* explain: Additional information whenever the usage routine is invoked */ +explain = <<- _END_EXPLAIN + _END_EXPLAIN; + +doc-section = { + ds-type = 'DESCRIPTION'; + ds-format = 'mdoc'; + ds-text = <<- _END_PROG_MDOC_DESCRIP +.Nm +will validate the file currently on the local system +and if necessary, updates leap-second definition file. +.Pp +Ordinarily, the file is found using the "leapfile" directive in +.Xr ntp.conf 5 . +However, an alternate location can be specified on the command line. +.Pp +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. +.Pp +If the current file is acceptable, no download or restart occurs. +.Pp +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. +.PP +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. +.PP +For cron-friendly behavior, define CRONJOB=1 in the crontab. +.PP +This script depends on$REQUIREDCMDS + _END_PROG_MDOC_DESCRIP; +}; + + +doc-section = { + ds-type = 'USAGE'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_USAGE + +Usage stuff + + _END_MDOC_USAGE; +}; + +doc-section = { + ds-type = 'AUTHORS'; + ds-format = 'mdoc'; + ds-text = <<- _END_MDOC_AUTHORS +.An "Timothe Litt" + _END_MDOC_AUTHORS; +}; diff --git a/contrib/ntp/scripts/update-leap/update-leap.1update-leapman b/contrib/ntp/scripts/update-leap/update-leap.1update-leapman new file mode 100644 index 000000000..dbe113c78 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.1update-leapman @@ -0,0 +1,169 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH update-leap 1update-leapman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-tXaylE/ag-FXaGkE) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:34 PM by AutoGen 5.18.5 +.\" From the definitions update-leap-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]update-leap\fP +\- leap-seconds file manager/updater +.SH SYNOPSIS +\f\*[B-Font]update-leap\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]update-leap\fP +will validate the file currently on the local system +and if necessary, updates leap-second definition file. +.sp \n(Ppu +.ne 2 + +Ordinarily, the file is found using the "leapfile" directive in +\fCntp.conf\f[]\fR(5)\f[]. +However, an alternate location can be specified on the command line. +.sp \n(Ppu +.ne 2 + +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. +.sp \n(Ppu +.ne 2 + +If the current file is acceptable, no download or restart occurs. +.sp \n(Ppu +.ne 2 + +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. +.PP +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. +.PP +For cron-friendly behavior, define CRONJOB=1 in the crontab. +.PP +This script depends on$REQUIREDCMDS +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-source\-url\f[]=\f\*[I-Font]string\f[] +The URL of the master copy of the leapseconds file. +.sp +Specify the URL of the master copy to download +$LEAPSRC +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Use only IPv4 addresses for DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp + Force DNS resolution of following host names on the command line + to the IPv4 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = ipv6; + flags-cant = ipv4, prefer; + value = 6; + descrip = "Use only IPv6 addresses for DNS name resolution"; + doc = <<- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv6 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = prefer; + flags-cant = ipv4, ipv6; + value = p; + arg-type = keyword; + keyword = 4, 6; + descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either'; + doc = <<- _EndOfDoc_ +Prefer IPv4 or IPv6 (as specified) addresses, but use either. +.TP +.NOP \f\*[B-Font]\-d\f[] \f\*[I-Font]float\f[], \f\*[B-Font]\-\-destination\f[]=\f\*[I-Font]float\f[] +Filename on the local system. +.sp +The name to use to store the leapfile on the local system. +$LEAPFILE +.TP +.NOP \f\*[B-Font]\-e\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-expiration\f[]=\f\*[I-Font]string\f[] +Refresh the leapfile this long before it expires. +.sp +Specify how long before expiration the file is to be refreshed +Units are required, e.g. "-e 60 days" Note that larger values +imply more frequent refreshes. +"$PREFETCH" +.TP +.NOP \f\*[B-Font]\-f\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-ntp\-conf\-file\f[]=\f\*[I-Font]string\f[] +Location of the ntp.conf file. +.sp +Specify location of ntp.conf (used to make sure leapfile directive is +present and to default leapfile) +/etc/ntp.conf +.TP +.NOP \f\*[B-Font]\-F\f[], \f\*[B-Font]\-\-force\-update\f[] +Force update of the leapfile. +.sp +Force update even if current file is OK and not close to expiring. +.TP +.NOP \f\*[B-Font]\-\-dont\-wait\f[] +Don't wait for keystroke between plots. +.sp +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH USAGE +Usage stuff +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH AUTHORS +.NOP "Timothe Litt" +.br +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBupdate-leap\fP +option definitions. diff --git a/contrib/ntp/scripts/update-leap/update-leap.1update-leapmdoc b/contrib/ntp/scripts/update-leap/update-leap.1update-leapmdoc new file mode 100644 index 000000000..cfbe34a74 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.1update-leapmdoc @@ -0,0 +1,134 @@ +.Dd October 21 2015 +.Dt UPDATE_LEAP 1update-leapmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (update-leap-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:42 PM by AutoGen 5.18.5 +.\" From the definitions update-leap-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm update-leap +.Nd leap-seconds file manager/updater +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.Nm +will validate the file currently on the local system +and if necessary, updates leap\-second definition file. +.Pp +Ordinarily, the file is found using the "leapfile" directive in +.Xr ntp.conf 5 . +However, an alternate location can be specified on the command line. +.Pp +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. +.Pp +If the current file is acceptable, no download or restart occurs. +.Pp +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. +.PP +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. +.PP +For cron\-friendly behavior, define CRONJOB=1 in the crontab. +.PP +This script depends on$REQUIREDCMDS +.Sh "OPTIONS" +.Bl -tag +.It Fl s Ar string , Fl \-source\-url Ns = Ns Ar string +The URL of the master copy of the leapseconds file. +.sp +Specify the URL of the master copy to download +$LEAPSRC +.It Fl 4 , Fl \-ipv4 +Use only IPv4 addresses for DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp + Force DNS resolution of following host names on the command line + to the IPv4 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = ipv6; + flags\-cant = ipv4, prefer; + value = 6; + descrip = "Use only IPv6 addresses for DNS name resolution"; + doc = <<\- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv6 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = prefer; + flags\-cant = ipv4, ipv6; + value = p; + arg\-type = keyword; + keyword = 4, 6; + descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either'; + doc = <<\- _EndOfDoc_ +Prefer IPv4 or IPv6 (as specified) addresses, but use either. +.It Fl d Ar float , Fl \-destination Ns = Ns Ar float +Filename on the local system. +.sp +The name to use to store the leapfile on the local system. +$LEAPFILE +.It Fl e Ar string , Fl \-expiration Ns = Ns Ar string +Refresh the leapfile this long before it expires. +.sp +Specify how long before expiration the file is to be refreshed +Units are required, e.g. "\-e 60 days" Note that larger values +imply more frequent refreshes. +"$PREFETCH" +.It Fl f Ar string , Fl \-ntp\-conf\-file Ns = Ns Ar string +Location of the ntp.conf file. +.sp +Specify location of ntp.conf (used to make sure leapfile directive is +present and to default leapfile) +/etc/ntp.conf +.It Fl F , Fl \-force\-update +Force update of the leapfile. +.sp +Force update even if current file is OK and not close to expiring. +.It Fl \-dont\-wait +Don't wait for keystroke between plots. +.sp +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh USAGE +Usage stuff +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh AUTHORS +.An "Timothe Litt" +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBupdate\-leap\fP +option definitions. diff --git a/contrib/ntp/scripts/update-leap/update-leap.html b/contrib/ntp/scripts/update-leap/update-leap.html new file mode 100644 index 000000000..bea57b8c7 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.html @@ -0,0 +1,323 @@ + + +update-leap User's Manual + + + + + + + + + +

      update-leap User's Manual

      +
      +


      +Next: , +Previous: (dir), +Up: (dir) +
      +
      + +

      This document describes the use of the NTP Project's update-leap program. + +

      This document applies to version 4.2.8p4 of update-leap. + +

      +

      Short Contents

      +
        +
      +
      + + + +
      +


      + +
      +
      + +

      0.1 Invoking update-leap

      + +

      + +

      update-leap +will validate the file currently on the local system +and if necessary, updates leap-second definition file. + +

      Ordinarily, the file is found using the "leapfile" directive in +ntp.conf(5). +However, an alternate location can be specified on the command line. + +

      If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. + +

      If the current file is acceptable, no download or restart occurs. + +

      -c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. +.PP +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. +.PP +For cron-friendly behavior, define CRONJOB=1 in the crontab. +.PP +This script depends on$REQUIREDCMDS + +

      This section was generated by AutoGen, +using the agtexi-cmd template and the option descriptions for the update-leap program. + +

      + + + +

      0.1.1 update-leap help/usage (--help)

      + +

      +This is the automatically generated usage text for update-leap. + +

      The text printed is the same whether selected with the help option +(--help) or the more-help option (--more-help). more-help will print +the usage text by passing it through a pager program. +more-help is disabled on platforms without a working +fork(2) function. The PAGER environment variable is +used to select the program, defaulting to more. Both will exit +with a status code of 0. + +

          update-leap
      +        Usage: $0 [options] [leapfile]
      +
      +        Verifies and if necessary, updates leap-second definition file
      +
      +        All arguments are optional: Default (or current value) shown: -s
      +        Specify the URL of the master copy to download $LEAPSRC -d Specify
      +        the filename on the local system $LEAPFILE -e Specify how long (in
      +        days) before expiration the file is to be refreshed. Note that
      +        larger values imply more frequent refreshes. "$PREFETCH" -f Specify
      +        location of ntp.conf (used to make sure leapfile directive is
      +        present and to default leapfile) $NTPCONF -F Force update even if
      +        current file is OK and not close to expiring. -r Specify number of
      +        times to retry on get failure $MAXTRIES -i Specify number of minutes
      +        between retries $INTERVAL -l Use syslog for output (Implied if
      +        CRONJOB is set) -L Don't use syslog for output -P Specify the syslog
      +        facility for logging $LOGFAC -t Name of temporary file used in
      +        validation $TMPFILE -q Only report errors to stdout -v Verbose
      +        output
      +
      +        The following options are not (yet) implemented in the perl version:
      +        -4 Use only IPv4 -6 Use only IPv6 -c Command to restart NTP after
      +        installing a new file <none> - ntpd checks file daily -p 4|6 Prefer
      +        IPv4 or IPv6 (as specified) addresses, but use either -z Specify
      +        path for utilities $PATHLIST -Z Only use system path
      +
      +        $0 will validate the file currently on the local system
      +
      +        Ordinarily, the file is found using the "leapfile" directive in
      +        $NTPCONF. However, an alternate location can be specified on the
      +        command line.
      +
      +        If the file does not exist, is not valid, has expired, or is
      +        expiring soon, a new copy will be downloaded. If the new copy
      +        validates, it is installed and NTP is (optionally) restarted.
      +
      +        If the current file is acceptable, no download or restart occurs.
      +
      +        -c can also be used to invoke another script to perform
      +        administrative functions, e.g. to copy the file to other local
      +        systems.
      +
      +        This can be run as a cron job. As the file is rarely updated, and
      +        leap seconds are announced at least one month in advance (usually
      +        longer), it need not be run more frequently than about once every
      +        three weeks.
      +
      +        For cron-friendly behavior, define CRONJOB=1 in the crontab.
      +
      +        Version $VERSION
      +
      +
      +


      +Next: , +Previous: update-leap usage, +Up: update-leap Invocation +
      +
      + +

      0.1.2 source-url option (-s)

      + +

      +This is the “the url of the master copy of the leapseconds file” option. +This option takes a string argument. +Specify the URL of the master copy to download +$LEAPSRC +

      + +

      0.1.3 ipv4 option (-4)

      + +

      +This is the “use only ipv4 addresses for dns name resolution” option. + +

      This option has some usage constraints. It: +

        +
      • must not appear in combination with any of the following options: +ipv6. +
      + +

      Force DNS resolution of following host names on the command line + to the IPv4 namespace. + _EndOfDoc_; +; + +

      flag = + name = ipv6; + flags-cant = ipv4, prefer; + value = 6; + descrip = "Use only IPv6 addresses for DNS name resolution"; + doc = <<- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv6 namespace. + _EndOfDoc_; +; + +

      flag = + name = prefer; + flags-cant = ipv4, ipv6; + value = p; + arg-type = keyword; + keyword = 4, 6; + descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either'; + doc = <<- _EndOfDoc_ +Prefer IPv4 or IPv6 (as specified) addresses, but use either. +

      + +

      0.1.4 destination option (-d)

      + +

      +This is the “filename on the local system” option. +This option takes a string argument float. +The name to use to store the leapfile on the local system. +$LEAPFILE +

      + +

      0.1.5 expiration option (-e)

      + +

      +This is the “refresh the leapfile this long before it expires” option. +This option takes a string argument. +Specify how long before expiration the file is to be refreshed +Units are required, e.g. "-e 60 days" Note that larger values +imply more frequent refreshes. +"$PREFETCH" +

      + +

      0.1.6 ntp-conf-file option (-f)

      + +

      +This is the “location of the ntp.conf file” option. +This option takes a string argument. +Specify location of ntp.conf (used to make sure leapfile directive is +present and to default leapfile) +/etc/ntp.conf +

      + +

      0.1.7 force-update option (-F)

      + +

      +This is the “force update of the leapfile” option. +Force update even if current file is OK and not close to expiring. +

      + +

      0.1.8 update-leap exit status

      + +

      One of the following exit values will be returned: +

      +
      0 (EXIT_SUCCESS)
      Successful program execution. +
      1 (EXIT_FAILURE)
      The operation failed or the command syntax was not valid. +
      + + +

      0.1.9 update-leap Usage

      + +
      +


      +Previous: update-leap Usage, +Up: update-leap Invocation +
      +
      + +

      0.1.10 update-leap Authors

      + + + diff --git a/contrib/ntp/scripts/update-leap/update-leap.in b/contrib/ntp/scripts/update-leap/update-leap.in new file mode 100755 index 000000000..a22b50a5a --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.in @@ -0,0 +1,424 @@ +#! @PATH_PERL@ -w + +# Copyright (C) 2015 Network Time Foundation +# Author: Harlan Stenn + +# Original shell version: +# Copyright (C) 2014 Timothe Litt litt at acm dot org + +# This script may be freely copied, used and modified providing that +# this notice and the copyright statement are included in all copies +# and derivative works. No warranty is offered, and use is entirely at +# your own risk. Bugfixes and improvements would be appreciated by the +# author. + +use strict; + +use Digest::SHA qw(sha1_hex); +use File::Copy qw(move); +use File::Fetch; +use Getopt::Long qw(:config auto_help no_ignore_case bundling); +use Sys::Syslog; + +my $VERSION="1.003"; + +# leap-seconds file manager/updater + +# ########## Default configuration ########## +# + +my $CRONJOB = $ENV{'CRONJOB'}; +$CRONJOB = "" unless defined($CRONJOB); +my $LOGGER; +my $QUIET = ""; +my $VERBOSE = ""; + +# Where to get the file +my $LEAPSRC="ftp://time.nist.gov/pub/leap-seconds.list"; +my $LEAPFILE; + +# How many times to try to download new file +my $MAXTRIES=6; +my $INTERVAL=10; + +# Where to find ntp config file +my $NTPCONF="/etc/ntp.conf"; + +# How long (in days) before expiration to get updated file +my $PREFETCH="60"; + +# How to restart NTP - older NTP: service ntpd? try-restart | condrestart +# Recent NTP checks for new file daily, so there's nothing to do +my $RESTART=""; + +my $EXPIRES; +my $FORCE = ""; + +# Where to put temporary copy before it's validated +my $TMPFILE="/tmp/leap-seconds.$$.tmp"; + +# Syslog facility +my $LOGFAC="daemon"; + +# ########################################### + +=item update-leap + +Usage: $0 [options] [leapfile] + +Verifies and if necessary, updates leap-second definition file + +All arguments are optional: Default (or current value) shown: + -s Specify the URL of the master copy to download + $LEAPSRC + -d Specify the filename on the local system + $LEAPFILE + -e Specify how long (in days) before expiration the file is to be + refreshed. Note that larger values imply more frequent refreshes. + "$PREFETCH" + -f Specify location of ntp.conf (used to make sure leapfile directive is + present and to default leapfile) + $NTPCONF + -F Force update even if current file is OK and not close to expiring. + -r Specify number of times to retry on get failure + $MAXTRIES + -i Specify number of minutes between retries + $INTERVAL + -l Use syslog for output (Implied if CRONJOB is set) + -L Don't use syslog for output + -P Specify the syslog facility for logging + $LOGFAC + -t Name of temporary file used in validation + $TMPFILE + -q Only report errors to stdout + -v Verbose output + +The following options are not (yet) implemented in the perl version: + -4 Use only IPv4 + -6 Use only IPv6 + -c Command to restart NTP after installing a new file + - ntpd checks file daily + -p 4|6 + Prefer IPv4 or IPv6 (as specified) addresses, but use either + -z Specify path for utilities + $PATHLIST + -Z Only use system path + +$0 will validate the file currently on the local system + +Ordinarily, the file is found using the "leapfile" directive in $NTPCONF. +However, an alternate location can be specified on the command line. + +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. + +If the current file is acceptable, no download or restart occurs. + +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. + +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. + +For cron-friendly behavior, define CRONJOB=1 in the crontab. + +Version $VERSION +=cut + +# Default: Use syslog for logging if running under cron + +my $SYSLOG = $CRONJOB; + +# Parse options + +our(%opt); + +GetOptions(\%opt, + 'c=s', + 'e:60', + 'F', + 'f=s', + 'i:10', + 'L', + 'l', + 'P=s', + 'q', + 'r:6', + 's=s', + 't=s', + 'v' + ); + +$LOGFAC=$opt{P} if (defined($opt{P})); +$LEAPSRC=$opt{s} if (defined($opt{s})); +$PREFETCH=$opt{e} if (defined($opt{e})); +$NTPCONF=$opt{f} if (defined($opt{f})); +$FORCE="Y" if (defined($opt{F})); +$RESTART=$opt{c} if (defined($opt{c})); +$MAXTRIES=$opt{r} if (defined($opt{r})); +$INTERVAL=$opt{i} if (defined($opt{i})); +$TMPFILE=$opt{t} if (defined($opt{t})); +$SYSLOG="Y" if (defined($opt{l})); +$SYSLOG="" if (defined($opt{L})); +$QUIET="Y" if (defined($opt{q})); +$VERBOSE="Y" if (defined($opt{v})); + +# export PATH="$PATHLIST$PATH" + +# Handle logging + +openlog($0, 'pid', $LOGFAC); + +sub logger { + my ($priority, $message) = @_; + + # "priority" "message" + # + # Stdout unless syslog specified or logger isn't available + # + if ($SYSLOG eq "" or $LOGGER eq "") { + if ($QUIET ne "" and ( $priority eq "info" or $priority eq "notice" or $priority eq "debug" ) ) { + return 0 + } + printf "%s: $message\n", uc $priority; + return 0; + } + + # Also log to stdout if cron job && notice or higher + if (($CRONJOB ne "" and ($priority ne "info" ) and ($priority ne "debug" )) || ($VERBOSE ne "")) { + # Log to stderr as well + print STDERR "$0: $priority: $message\n"; + } + syslog($priority, $message); +} + +# Verify interval +# INTERVAL=$(( $INTERVAL *1 )) + +# Validate a leap-seconds file checksum +# +# File format: (full description in files) +# # marks comments, except: +# #$ number : the NTP date of the last update +# #@ number : the NTP date that the file expires +# Date (seconds since 1900) leaps : leaps is the # of seconds to add for times >= Date +# Date lines have comments. +# #h hex hex hex hex hex is the SHA-1 checksum of the data & dates, excluding whitespace w/o leading zeroes +# +# Returns: +# 0 File is valid +# 1 Invalid Checksum +# 2 Expired + +sub verifySHA { + my ($file, $verbose) = @_; + + my $raw = ""; + my $data = ""; + my $FSHA; + + # Remove comments, except those that are markers for last update, + # expires and hash + + unless (open(LF, $file)) { + warn "Can't open <$file>: $!\n"; + print "Will try and create that file.\n"; + return 1; + }; + while () { + if (/^#\$/) { + $raw .= $_; + s/^..//; + $data .= $_; + } + elsif (/^#\@/) { + $raw .= $_; + s/^..//; + $data .= $_; + s/\s+//g; + $EXPIRES = $_ - 2208988800; + } + elsif (/^#h\s+([[:xdigit:]]+)\s+([[:xdigit:]]+)\s+([[:xdigit:]]+)\s+([[:xdigit:]]+)\s+([[:xdigit:]]+)/) { + chomp; + $raw .= $_; + $FSHA = sprintf("%08s%08s%08s%08s%08s", $1, $2, $3, $4, $5); + } + elsif (/^#/) { + # ignore it + } + elsif (/^\d/) { + s/#.*$//; + $raw .= $_; + $data .= $_; + } else { + chomp; + print "Unexpected line: <$_>\n"; + } + } + close LF; + + # Remove all white space + $data =~ s/\s//g; + + # Compute the SHA hash of the data, removing the marker and filename + # Computed in binary mode, which shouldn't matter since whitespace has been removed + + my $DSHA = sha1_hex($data); + + # Extract the file's hash. Restore any leading zeroes in hash segments. + + if ( ( "$FSHA" ne "" ) && ( $FSHA eq $DSHA ) ) { + if ( $verbose ne "" ) { + logger("info", "Checksum of $file validated"); + } + } else { + logger("error", "Checksum of $file is invalid:"); + $FSHA="(no checksum record found in file)" + if ( $FSHA eq ""); + logger("error", "EXPECTED: $FSHA"); + logger("error", "COMPUTED: $DSHA"); + return 1; + } + + # Check the expiration date, converting NTP epoch to Unix epoch used by date + + if ( $EXPIRES < time() ) { + logger("notice", "File expired on " . gmtime($EXPIRES)); + return 2; + } + return 0; +} + +# Verify ntp.conf + +-r $NTPCONF || die "Missing ntp configuration: $NTPCONF\n"; + +# Parse ntp.conf for leapfile directive + +open(LF, $NTPCONF) || die "Can't open <$NTPCONF>: $!\n"; +while () { + chomp; + if (/^ *leapfile\s+(\S+)/) { + $LEAPFILE = $1; + } +} +close LF; + +-s $LEAPFILE || warn "$NTPCONF specifies $LEAPFILE as a leapfile, which is empty.\n"; + +# Allow placing the file someplace else - testing + +if ( defined $ARGV[0] ) { + if ( $ARGV[0] ne $LEAPFILE ) { + logger("notice", "Requested install to $ARGV[0], but $NTPCONF specifies $LEAPFILE"); + } + $LEAPFILE = $ARGV[0]; +} + +# Verify the current file +# If it is missing, doesn't validate or expired +# Or is expiring soon +# Download a new one + +if ( $FORCE ne "" || verifySHA($LEAPFILE, $VERBOSE) || ( $EXPIRES lt ( $PREFETCH * 86400 + time() ) )) { + my $TRY = 0; + my $ff = File::Fetch->new(uri => $LEAPSRC) || die "Fetch failed.\n"; + while (1) { + ++$TRY; + logger("info", "Attempting download from $LEAPSRC, try $TRY..") + if ($VERBOSE ne ""); + my $where = $ff->fetch( to => '/tmp' ); + + if ($where) { + logger("info", "Download of $LEAPSRC succeeded"); + + if ( verifySHA($where, $VERBOSE )) { + # There is no point in retrying, as the file on the + # server is almost certainly corrupt. + + logger("warning", "Downloaded file $where rejected -- saved for diagnosis"); + exit 1; + } + + # While the shell script version will set correct permissions + # on temporary file, for the perl version that's harder, so + # for now at least one should run this script as the + # appropriate user. + + # REFFILE="$LEAPFILE" + # if [ ! -f $LEAPFILE ]; then + # logger "notice" "$LEAPFILE was missing, creating new copy - check permissions" + # touch $LEAPFILE + # # Can't copy permissions from old file, copy from NTPCONF instead + # REFFILE="$NTPCONF" + # fi + # chmod --reference $REFFILE $TMPFILE + # chown --reference $REFFILE $TMPFILE + # ( which selinuxenabled && selinuxenabled && which chcon ) >/dev/null 2>&1 + # if [ $? == 0 ] ; then + # chcon --reference $REFFILE $TMPFILE + # fi + + # Replace current file with validated new one + + if ( move $where, $LEAPFILE ) { + logger("notice", "Installed new $LEAPFILE from $LEAPSRC"); + } else { + logger("error", "Install $where => $LEAPFILE failed -- saved for diagnosis: $!"); + exit 1; + } + + # Restart NTP (or whatever else is specified) + + if ( $RESTART ne "" ) { + if ( $VERBOSE ne "" ) { + logger("info", "Attempting restart action: $RESTART"); + } + +# XXX + #R="$( 2>&1 $RESTART )" + #if [ $? -eq 0 ]; then + # logger "notice" "Restart action succeeded" + # if [ -n "$VERBOSE" -a -n "$R" ]; then + # logger "info" "$R" + # fi + #else + # logger "error" "Restart action failed" + # if [ -n "$R" ]; then + # logger "error" "$R" + # fi + # exit 2 + #fi + } + exit 0; + } + + # Failed to download. See about trying again + + # rm -f $TMPFILE + if ( $TRY ge $MAXTRIES ) { + last; + } + if ( $VERBOSE ne "" ) { + logger("info", "Waiting $INTERVAL minutes before retrying..."); + } + sleep $INTERVAL * 60 ; + } + + # Failed and out of retries + + logger("warning", "Download from $LEAPSRC failed after $TRY attempts"); + exit 1; +} + +print "FORCE is <$FORCE>\n"; +print "verifySHA is " . verifySHA($LEAPFILE, "") . "\n"; +print "EXPIRES <$EXPIRES> vs ". ( $PREFETCH * 86400 + time() ) . "\n"; + +logger("info", "Not time to replace $LEAPFILE"); + +exit 0; + +# EOF diff --git a/contrib/ntp/scripts/update-leap/update-leap.man.in b/contrib/ntp/scripts/update-leap/update-leap.man.in new file mode 100644 index 000000000..dbe113c78 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.man.in @@ -0,0 +1,169 @@ +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +.TH update-leap 1update-leapman "21 Oct 2015" "ntp (4.2.8p4)" "User Commands" +.\" +.\" EDIT THIS FILE WITH CAUTION (/tmp/.ag-tXaylE/ag-FXaGkE) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:34 PM by AutoGen 5.18.5 +.\" From the definitions update-leap-opts.def +.\" and the template file agman-cmd.tpl +.SH NAME +\f\*[B-Font]update-leap\fP +\- leap-seconds file manager/updater +.SH SYNOPSIS +\f\*[B-Font]update-leap\fP +.\" Mixture of short (flag) options and long options +[\f\*[B-Font]\-flags\f[]] +[\f\*[B-Font]\-flag\f[] [\f\*[I-Font]value\f[]]] +[\f\*[B-Font]\-\-option-name\f[][[=| ]\f\*[I-Font]value\f[]]] +.sp \n(Ppu +.ne 2 + +All arguments must be options. +.sp \n(Ppu +.ne 2 + +.SH DESCRIPTION +\f\*[B-Font]update-leap\fP +will validate the file currently on the local system +and if necessary, updates leap-second definition file. +.sp \n(Ppu +.ne 2 + +Ordinarily, the file is found using the "leapfile" directive in +\fCntp.conf\f[]\fR(5)\f[]. +However, an alternate location can be specified on the command line. +.sp \n(Ppu +.ne 2 + +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. +.sp \n(Ppu +.ne 2 + +If the current file is acceptable, no download or restart occurs. +.sp \n(Ppu +.ne 2 + +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. +.PP +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. +.PP +For cron-friendly behavior, define CRONJOB=1 in the crontab. +.PP +This script depends on$REQUIREDCMDS +.SH "OPTIONS" +.TP +.NOP \f\*[B-Font]\-s\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-source\-url\f[]=\f\*[I-Font]string\f[] +The URL of the master copy of the leapseconds file. +.sp +Specify the URL of the master copy to download +$LEAPSRC +.TP +.NOP \f\*[B-Font]\-4\f[], \f\*[B-Font]\-\-ipv4\f[] +Use only IPv4 addresses for DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp + Force DNS resolution of following host names on the command line + to the IPv4 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = ipv6; + flags-cant = ipv4, prefer; + value = 6; + descrip = "Use only IPv6 addresses for DNS name resolution"; + doc = <<- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv6 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = prefer; + flags-cant = ipv4, ipv6; + value = p; + arg-type = keyword; + keyword = 4, 6; + descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either'; + doc = <<- _EndOfDoc_ +Prefer IPv4 or IPv6 (as specified) addresses, but use either. +.TP +.NOP \f\*[B-Font]\-d\f[] \f\*[I-Font]float\f[], \f\*[B-Font]\-\-destination\f[]=\f\*[I-Font]float\f[] +Filename on the local system. +.sp +The name to use to store the leapfile on the local system. +$LEAPFILE +.TP +.NOP \f\*[B-Font]\-e\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-expiration\f[]=\f\*[I-Font]string\f[] +Refresh the leapfile this long before it expires. +.sp +Specify how long before expiration the file is to be refreshed +Units are required, e.g. "-e 60 days" Note that larger values +imply more frequent refreshes. +"$PREFETCH" +.TP +.NOP \f\*[B-Font]\-f\f[] \f\*[I-Font]string\f[], \f\*[B-Font]\-\-ntp\-conf\-file\f[]=\f\*[I-Font]string\f[] +Location of the ntp.conf file. +.sp +Specify location of ntp.conf (used to make sure leapfile directive is +present and to default leapfile) +/etc/ntp.conf +.TP +.NOP \f\*[B-Font]\-F\f[], \f\*[B-Font]\-\-force\-update\f[] +Force update of the leapfile. +.sp +Force update even if current file is OK and not close to expiring. +.TP +.NOP \f\*[B-Font]\-\-dont\-wait\f[] +Don't wait for keystroke between plots. +.sp +.TP +.NOP \f\*[B-Font]\-\&?\f[], \f\*[B-Font]\-\-help\f[] +Display usage information and exit. +.TP +.NOP \f\*[B-Font]\-\&!\f[], \f\*[B-Font]\-\-more-help\f[] +Pass the extended usage information through a pager. +.TP +.NOP \f\*[B-Font]\-v\f[] [{\f\*[I-Font]v|c|n\f[] \f\*[B-Font]\-\-version\f[] [{\f\*[I-Font]v|c|n\f[]}]}] +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.PP +.SH USAGE +Usage stuff +.SH "EXIT STATUS" +One of the following exit values will be returned: +.TP +.NOP 0 " (EXIT_SUCCESS)" +Successful program execution. +.TP +.NOP 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.TP +.NOP 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you. +.PP +.SH AUTHORS +.NOP "Timothe Litt" +.br +.SH "NOTES" +This manual page was \fIAutoGen\fP-erated from the \fBupdate-leap\fP +option definitions. diff --git a/contrib/ntp/scripts/update-leap/update-leap.mdoc.in b/contrib/ntp/scripts/update-leap/update-leap.mdoc.in new file mode 100644 index 000000000..cfbe34a74 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.mdoc.in @@ -0,0 +1,134 @@ +.Dd October 21 2015 +.Dt UPDATE_LEAP 1update-leapmdoc User Commands +.Os +.\" EDIT THIS FILE WITH CAUTION (update-leap-opts.mdoc) +.\" +.\" It has been AutoGen-ed October 21, 2015 at 12:34:42 PM by AutoGen 5.18.5 +.\" From the definitions update-leap-opts.def +.\" and the template file agmdoc-cmd.tpl +.Sh NAME +.Nm update-leap +.Nd leap-seconds file manager/updater +.Sh SYNOPSIS +.Nm +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option\-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +.Pp +All arguments must be options. +.Pp +.Sh DESCRIPTION +.Nm +will validate the file currently on the local system +and if necessary, updates leap\-second definition file. +.Pp +Ordinarily, the file is found using the "leapfile" directive in +.Xr ntp.conf 5 . +However, an alternate location can be specified on the command line. +.Pp +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. +.Pp +If the current file is acceptable, no download or restart occurs. +.Pp +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. +.PP +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. +.PP +For cron\-friendly behavior, define CRONJOB=1 in the crontab. +.PP +This script depends on$REQUIREDCMDS +.Sh "OPTIONS" +.Bl -tag +.It Fl s Ar string , Fl \-source\-url Ns = Ns Ar string +The URL of the master copy of the leapseconds file. +.sp +Specify the URL of the master copy to download +$LEAPSRC +.It Fl 4 , Fl \-ipv4 +Use only IPv4 addresses for DNS name resolution. +This option must not appear in combination with any of the following options: +ipv6. +.sp + Force DNS resolution of following host names on the command line + to the IPv4 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = ipv6; + flags\-cant = ipv4, prefer; + value = 6; + descrip = "Use only IPv6 addresses for DNS name resolution"; + doc = <<\- _EndOfDoc_ + Force DNS resolution of following host names on the command line + to the IPv6 namespace. + _EndOfDoc_; +}; +.sp +flag = { + name = prefer; + flags\-cant = ipv4, ipv6; + value = p; + arg\-type = keyword; + keyword = 4, 6; + descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either'; + doc = <<\- _EndOfDoc_ +Prefer IPv4 or IPv6 (as specified) addresses, but use either. +.It Fl d Ar float , Fl \-destination Ns = Ns Ar float +Filename on the local system. +.sp +The name to use to store the leapfile on the local system. +$LEAPFILE +.It Fl e Ar string , Fl \-expiration Ns = Ns Ar string +Refresh the leapfile this long before it expires. +.sp +Specify how long before expiration the file is to be refreshed +Units are required, e.g. "\-e 60 days" Note that larger values +imply more frequent refreshes. +"$PREFETCH" +.It Fl f Ar string , Fl \-ntp\-conf\-file Ns = Ns Ar string +Location of the ntp.conf file. +.sp +Specify location of ntp.conf (used to make sure leapfile directive is +present and to default leapfile) +/etc/ntp.conf +.It Fl F , Fl \-force\-update +Force update of the leapfile. +.sp +Force update even if current file is OK and not close to expiring. +.It Fl \-dont\-wait +Don't wait for keystroke between plots. +.sp +.It Fl \&? , Fl \-help +Display usage information and exit. +.It Fl \&! , Fl \-more\-help +Pass the extended usage information through a pager. +.It Fl v Op Brq Ar v|c|n Fl \-version Op Brq Ar v|c|n +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice. +.El +.Sh USAGE +Usage stuff +.Sh "EXIT STATUS" +One of the following exit values will be returned: +.Bl -tag +.It 0 " (EXIT_SUCCESS)" +Successful program execution. +.It 1 " (EXIT_FAILURE)" +The operation failed or the command syntax was not valid. +.It 70 " (EX_SOFTWARE)" +libopts had an internal operational error. Please report +it to autogen\-users@lists.sourceforge.net. Thank you. +.El +.Sh AUTHORS +.An "Timothe Litt" +.Sh "NOTES" +This manual page was \fIAutoGen\fP\-erated from the \fBupdate\-leap\fP +option definitions. diff --git a/contrib/ntp/scripts/update-leap/update-leap.sh b/contrib/ntp/scripts/update-leap/update-leap.sh new file mode 100755 index 000000000..2dab4eca3 --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.sh @@ -0,0 +1,434 @@ +#!/bin/bash + +# Copyright (C) 2014 Timothe Litt litt at acm dot org + +# This script may be freely copied, used and modified providing that +# this notice and the copyright statement are included in all copies +# and derivative works. No warranty is offered, and use is entirely at +# your own risk. Bugfixes and improvements would be appreciated by the +# author. + +VERSION="1.003" + +# leap-seconds file manager/updater + +# Depends on: +# wget sed, tr, shasum, logger + +# ########## Default configuration ########## +# +# Where to get the file +LEAPSRC="ftp://time.nist.gov/pub/leap-seconds.list" + +# How many times to try to download new file +MAXTRIES=6 +INTERVAL=10 + +# Where to find ntp config file +NTPCONF=/etc/ntp.conf + +# How long before expiration to get updated file +PREFETCH="60 days" + +# How to restart NTP - older NTP: service ntpd? try-restart | condrestart +# Recent NTP checks for new file daily, so there's nothing to do +RESTART= + +# Where to put temporary copy before it's validated +TMPFILE="/tmp/leap-seconds.$$.tmp" + +# Syslog facility +LOGFAC=daemon +# ########################################### + +# Places to look for commands. Allows for CRON having path to +# old utilities on embedded systems + +PATHLIST="/opt/sbin:/opt/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:" + +REQUIREDCMDS=" wget logger tr sed shasum" + +SELF="`basename $0`" + +function displayHelp { + cat < - ntpd checks file daily + -r Specify number of times to retry on get failure + $MAXTRIES + -i Specify number of minutes between retries + $INTERVAL + -l Use syslog for output (Implied if CRONJOB is set) + -L Don't use syslog for output + -P Specify the syslog facility for logging + $LOGFAC + -t Name of temporary file used in validation + $TMPFILE + -q Only report errors to stdout + -v Verbose output + -z Specify path for utilities + $PATHLIST + -Z Only use system path + +$SELF will validate the file currently on the local system + +Ordinarily, the file is found using the "leapfile" directive in $NTPCONF. +However, an alternate location can be specified on the command line. + +If the file does not exist, is not valid, has expired, or is expiring soon, +a new copy will be downloaded. If the new copy validates, it is installed and +NTP is (optionally) restarted. + +If the current file is acceptable, no download or restart occurs. + +-c can also be used to invoke another script to perform administrative +functions, e.g. to copy the file to other local systems. + +This can be run as a cron job. As the file is rarely updated, and leap +seconds are announced at least one month in advance (usually longer), it +need not be run more frequently than about once every three weeks. + +For cron-friendly behavior, define CRONJOB=1 in the crontab. + +This script depends on$REQUIREDCMDS + +Version $VERSION +EOF + return 0 +} + +# Default: Use syslog for logging if running under cron + +SYSLOG="$CRONJOB" + +if [ "$1" = "--help" ]; then + displayHelp + exit 0 +fi + +# Parse options + +while getopts 46p:P:s:e:f:Fc:r:i:lLt:hqvz:Z opt; do + case $opt in + 4) + PROTO="-4" + ;; + 6) + PROTO="-6" + ;; + p) + if [ "$OPTARG" = '4' -o "$OPTARG" = '6' ]; then + PREFER="--prefer-family=IPv$OPTARG" + else + echo "Invalid -p $OPTARG" >&2 + exit 1; + fi + ;; + P) + LOGFAC="$OPTARG" + ;; + s) + LEAPSRC="$OPTARG" + ;; + e) + PREFETCH="$OPTARG" + ;; + f) + NTPCONF="$OPTARG" + ;; + F) + FORCE="Y" + ;; + c) + RESTART="$OPTARG" + ;; + r) + MAXTRIES="$OPTARG" + ;; + i) + INTERVAL="$OPTARG" + ;; + t) + TMPFILE="$OPTARG" + ;; + l) + SYSLOG="y" + ;; + L) + SYSLOG= + ;; + h) + displayHelp + exit 0 + ;; + q) + QUIET="Y" + ;; + v) + VERBOSE="Y" + ;; + z) + PATHLIST="$OPTARG:" + ;; + Z) + PATHLIST= + ;; + *) + echo "$SELF -h for usage" >&2 + exit 1 + ;; + esac +done +shift $((OPTIND-1)) + +export PATH="$PATHLIST$PATH" + +# Add to path to deal with embedded systems +# +for P in $REQUIREDCMDS ; do + if >/dev/null 2>&1 which "$P" ; then + continue + fi + [ "$P" = "logger" ] && continue + echo "FATAL: missing $P command, please install" + exit 1 +done + +# Handle logging + +if ! LOGGER="`2>/dev/null which logger`" ; then + LOGGER= +fi + +function log { + # "priority" "message" + # + # Stdout unless syslog specified or logger isn't available + # + if [ -z "$SYSLOG" -o -z "$LOGGER" ]; then + if [ -n "$QUIET" -a \( "$1" = "info" -o "$1" = "notice" -o "$1" = "debug" \) ]; then + return 0 + fi + echo "`echo \"$1\" | tr a-z A-Z`: $2" + return 0 + fi + + # Also log to stdout if cron job && notice or higher + local S + if [ -n "$CRONJOB" -a \( "$1" != "info" \) -a \( "$1" != "debug" \) ] || [ -n "$VERBOSE" ]; then + S="-s" + fi + $LOGGER $S -t "$SELF[$$]" -p "$LOGFAC.$1" "$2" +} + +# Verify interval +INTERVAL=$(( $INTERVAL *1 )) + +# Validate a leap-seconds file checksum +# +# File format: (full description in files) +# # marks comments, except: +# #$ number : the NTP date of the last update +# #@ number : the NTP date that the file expires +# Date (seconds since 1900) leaps : leaps is the # of seconds to add for times >= Date +# Date lines have comments. +# #h hex hex hex hex hex is the SHA-1 checksum of the data & dates, excluding whitespace w/o leading zeroes + +function verifySHA { + + if [ ! -f "$1" ]; then + return 1 + fi + + # Remove comments, except those that are markers for last update, expires and hash + + local RAW="`sed $1 -e'/^\\([0-9]\\|#[\$@h]\)/!d' -e'/^#[\$@h]/!s/#.*\$//g'`" + + # Extract just the data, removing all whitespace + + local DATA="`echo \"$RAW\" | sed -e'/^#h/d' -e's/^#[\$@]//g' | tr -d '[:space:]'`" + + # Compute the SHA hash of the data, removing the marker and filename + # Computed in binary mode, which shouldn't matter since whitespace has been removed + # shasum comes in several flavors; a portable one is available in Perl (with Digest::SHA) + + local DSHA="`echo -n \"$DATA\" | shasum | sed -e's/[? *].*$//'`" + + # Extract the file's hash. Restore any leading zeroes in hash segments. + + # The sed [] includes a tab (\t) and space; #h is followed by a tab and space + local FSHA="`echo \"$RAW\" | sed -e'/^#h/!d' -e's/^#h//' -e's/[ ] */ 0x/g'`" + FSHA=`printf '%08x%08x%08x%08x%08x' $FSHA` + + if [ -n "$FSHA" -a \( "$FSHA" = "$DSHA" \) ]; then + if [ -n "$2" ]; then + log "info" "Checksum of $1 validated" + fi + else + log "error" "Checksum of $1 is invalid:" + [ -z "$FSHA" ] && FSHA="(no checksum record found in file)" + log "error" "EXPECTED: $FSHA" + log "error" "COMPUTED: $DSHA" + return 1 + fi + + # Check the expiration date, converting NTP epoch to Unix epoch used by date + + EXPIRES="`echo \"$RAW\" | sed -e'/^#@/!d' -e's/^#@//' | tr -d '[:space:]'`" + EXPIRES="$(($EXPIRES - 2208988800 ))" + + if [ $EXPIRES -lt `date -u +%s` ]; then + log "notice" "File expired on `date -u -d \"Jan 1, 1970 00:00:00 +0000 + $EXPIRES seconds\"`" + return 2 + fi + +} + +# Verify ntp.conf + +if ! [ -f "$NTPCONF" ]; then + log "critical" "Missing ntp configuration $NTPCONF" + exit 1 +fi + +# Parse ntp.conf for leapfile directive + +LEAPFILE="`sed $NTPCONF -e'/^ *leapfile *.*$/!d' -e's/^ *leapfile *//'`" +if [ -z "$LEAPFILE" ]; then + log "error" "$NTPCONF does not specify a leapfile" +fi + +# Allow placing the file someplace else - testing + +if [ -n "$1" ]; then + if [ "$1" != "$LEAPFILE" ]; then + log "notice" "Requested install to $1, but $NTPCONF specifies $LEAPFILE" + fi + LEAPFILE="$1" +fi + +# Verify the current file +# If it is missing, doesn't validate or expired +# Or is expiring soon +# Download a new one + +if [ -n "$FORCE" ] || ! verifySHA $LEAPFILE "$VERBOSE" || [ $EXPIRES -lt `date -d "NOW + $PREFETCH" +%s` ] ; then + TRY=0 + while true; do + TRY=$(( $TRY + 1 )) + if [ -n "$VERBOSE" ]; then + log "info" "Attempting download from $LEAPSRC, try $TRY.." + fi + if wget $PROTO $PREFER -o ${TMPFILE}.log $LEAPSRC -O $TMPFILE ; then + log "info" "Download of $LEAPSRC succeeded" + if [ -n "$VERBOSE" ]; then + cat ${TMPFILE}.log + fi + + if ! verifySHA $TMPFILE "$VERBOSE" ; then + # There is no point in retrying, as the file on the server is almost + # certainly corrupt. + + log "warning" "Downloaded file $TMPFILE rejected -- saved for diagnosis" + cat ${TMPFILE}.log + rm -f ${TMPFILE}.log + exit 1 + fi + rm -f ${TMPFILE}.log + + # Set correct permissions on temporary file + + REFFILE="$LEAPFILE" + if [ ! -f $LEAPFILE ]; then + log "notice" "$LEAPFILE was missing, creating new copy - check permissions" + touch $LEAPFILE + # Can't copy permissions from old file, copy from NTPCONF instead + REFFILE="$NTPCONF" + fi + chmod --reference $REFFILE $TMPFILE + chown --reference $REFFILE $TMPFILE + ( which selinuxenabled && selinuxenabled && which chcon ) >/dev/null 2>&1 + if [ $? == 0 ] ; then + chcon --reference $REFFILE $TMPFILE + fi + + # Replace current file with validated new one + + if mv -f $TMPFILE $LEAPFILE ; then + log "notice" "Installed new $LEAPFILE from $LEAPSRC" + else + log "error" "Install $TMPFILE => $LEAPFILE failed -- saved for diagnosis" + exit 1 + fi + + # Restart NTP (or whatever else is specified) + + if [ -n "$RESTART" ]; then + if [ -n "$VERBOSE" ]; then + log "info" "Attempting restart action: $RESTART" + fi + R="$( 2>&1 $RESTART )" + if [ $? -eq 0 ]; then + log "notice" "Restart action succeeded" + if [ -n "$VERBOSE" -a -n "$R" ]; then + log "info" "$R" + fi + else + log "error" "Restart action failed" + if [ -n "$R" ]; then + log "error" "$R" + fi + exit 2 + fi + fi + exit 0 + fi + + # Failed to download. See about trying again + + rm -f $TMPFILE + if [ $TRY -ge $MAXTRIES ]; then + break; + fi + if [ -n "$VERBOSE" ]; then + cat ${TMPFILE}.log + log "info" "Waiting $INTERVAL minutes before retrying..." + fi + sleep $(( $INTERVAL * 60)) + done + + # Failed and out of retries + + log "warning" "Download from $LEAPSRC failed after $TRY attempts" + if [ -f ${TMPFILE}.log ]; then + cat ${TMPFILE}.log + rm -f ${TMPFILE}.log $TMPFILE + fi + exit 1 +fi +log "info" "Not time to replace $LEAPFILE" + +exit 0 + +# EOF \ No newline at end of file diff --git a/contrib/ntp/scripts/update-leap/update-leap.texi b/contrib/ntp/scripts/update-leap/update-leap.texi new file mode 100644 index 000000000..1a96ae09b --- /dev/null +++ b/contrib/ntp/scripts/update-leap/update-leap.texi @@ -0,0 +1,43 @@ +\input texinfo @c -*-texinfo-*- +@c %**start of header +@setfilename update-leap.info +@settitle update-leap User's Manual +@include ../../sntp/include/version.texi +@paragraphindent 2 +@c %**end of header + +@ifinfo +This file documents the use of @code{update-leap}, +a program from +the NTP Project, +that is used to wait until @code{ntpd} has been able to +synchronize and stabilize the time on the current host. +@end ifinfo + +@direntry +* update-leap: (update-leap). Check the leapfile and update it if needed. +@end direntry + +@titlepage +@title update-leap User's Manual +@subtitle update-leap, version @value{VERSION}, @value{UPDATED} +@c @author Max @email{foo@ntp.org} +@end titlepage + +@c @page +@c @vskip 0pt plus 1filll + +@node Top, update-leap Description, (dir), (dir) + +This document describes the use of the NTP Project's @code{update-leap} program. + +This document applies to version @value{VERSION} of @code{update-leap}. + +@shortcontents + +@menu +* update-leap Description:: Description +* update-leap Invocation:: Invoking update-leap +@end menu + +@include invoke-update-leap.texi diff --git a/contrib/ntp/sntp/COPYRIGHT b/contrib/ntp/sntp/COPYRIGHT index c4f6f5de9..9c1a0f839 100644 --- a/contrib/ntp/sntp/COPYRIGHT +++ b/contrib/ntp/sntp/COPYRIGHT @@ -1,80 +1,229 @@ - General Public Licence for the software known as MSNTP - ------------------------------------------------------ - - (c) Copyright, N.M. Maclaren, 1996, 1997, 2000 - (c) Copyright, University of Cambridge, 1996, 1997, 2000 - - - -Free use of MSNTP in source and binary forms is permitted, provided that this -entire licence is duplicated in all copies, and that any documentation, -announcements, and other materials related to use acknowledge that the software -was developed by N.M. Maclaren (hereafter refered to as the Author) at the -University of Cambridge. Neither the name of the Author nor the University of -Cambridge may be used to endorse or promote products derived from this material -without specific prior written permission. - -The Author and the University of Cambridge retain the copyright and all other -legal rights to the software and make it available non-exclusively. All users -must ensure that the software in all its derivations carries a copyright notice -in the form: - (c) Copyright N.M. Maclaren, - (c) Copyright University of Cambridge. - - - - NO WARRANTY - -Because the MSNTP software is licensed free of charge, the Author and the -University of Cambridge provide absolutely no warranty, either expressed or -implied, including, but not limited to, the implied warranties of -merchantability and fitness for a particular purpose. The entire risk as to -the quality and performance of the MSNTP software is with you. Should MSNTP -prove defective, you assume the cost of all necessary servicing or repair. - -In no event, unless required by law, will the Author or the University of -Cambridge, or any other party who may modify and redistribute this software as -permitted in accordance with the provisions below, be liable for damages for -any losses whatsoever, including but not limited to lost profits, lost monies, -lost or corrupted data, or other special, incidental or consequential losses -that may arise out of the use or inability to use the MSNTP software. - - - - COPYING POLICY - -Permission is hereby granted for copying and distribution of copies of the -MSNTP source and binary files, and of any part thereof, subject to the -following licence conditions: - -1. You may distribute MSNTP or components of MSNTP, with or without additions -developed by you or by others. No charge, other than an "at-cost" distribution -fee, may be charged for copies, derivations, or distributions of this material -without the express written consent of the copyright holders. - -2. You may also distribute MSNTP along with any other product for sale, -provided that the cost of the bundled package is the same regardless of whether -MSNTP is included or not, and provided that those interested only in MSNTP must -be notified that it is a product freely available from the University of -Cambridge. - -3. If you distribute MSNTP software or parts of MSNTP, with or without -additions developed by you or others, then you must either make available the -source to all portions of the MSNTP system (exclusive of any additions made by -you or by others) upon request, or instead you may notify anyone requesting -source that it is freely available from the University of Cambridge. - -4. You may not omit any of the copyright notices on either the source files, -the executable files, or the documentation. - -5. You may not omit transmission of this License agreement with whatever -portions of MSNTP that are distributed. - -6. Any users of this software must be notified that it is without warranty or -guarantee of any nature, express or implied, nor is there any fitness for use -represented. - - -October 1996 -April 1997 -October 2000 +This file is automatically generated from html/copyright.html + + Copyright Notice + + jpg "Clone me," says Dolly sheepishly. + + Last update: 17-Jan-2015 00:16 UTC + _________________________________________________________________ + + The following copyright notice applies to all files collectively + called the Network Time Protocol Version 4 Distribution. Unless + specifically declared otherwise in an individual file, this entire + notice applies as if the text was explicitly included in the file. +*********************************************************************** +* * +* Copyright (c) University of Delaware 1992-2015 * +* * +* Permission to use, copy, modify, and distribute this software and * +* its documentation for any purpose with or without fee is hereby * +* granted, provided that the above copyright notice appears in all * +* copies and that both the copyright notice and this permission * +* notice appear in supporting documentation, and that the name * +* University of Delaware not be used in advertising or publicity * +* pertaining to distribution of the software without specific, * +* written prior permission. The University of Delaware makes no * +* representations about the suitability this software for any * +* purpose. It is provided "as is" without express or implied * +* warranty. * +* * +*********************************************************************** + + Content starting in 2011 from Harlan Stenn, Danny Mayer, and Martin + Burnicki is: +*********************************************************************** +* * +* Copyright (c) Network Time Foundation 2011-2015 * +* * +* All Rights Reserved * +* * +* Redistribution and use in source and binary forms, with or without * +* modification, are permitted provided that the following conditions * +* are met: * +* 1. Redistributions of source code must retain the above copyright * +* notice, this list of conditions and the following disclaimer. * +* 2. Redistributions in binary form must reproduce the above * +* copyright notice, this list of conditions and the following * +* disclaimer in the documentation and/or other materials provided * +* with the distribution. * +* * +* THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS * +* OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED * +* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * +* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE * +* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT * +* OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR * +* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * +* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * +* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE * +* USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH * +* DAMAGE. * +*********************************************************************** + + The following individuals contributed in part to the Network Time + Protocol Distribution Version 4 and are acknowledged as authors of + this work. + 1. [1]Takao Abe Clock driver for JJY receivers + 2. [2]Mark Andrews Leitch atomic clock + controller + 3. [3]Bernd Altmeier hopf Elektronik serial + line and PCI-bus devices + 4. [4]Viraj Bais and [5]Clayton Kirkwood + port to WindowsNT 3.5 + 5. [6]Michael Barone GPSVME fixes + 6. [7]Karl Berry syslog to file option + 7. [8]Greg Brackley Major rework of WINNT + port. Clean up recvbuf and iosignal code into separate modules. + 8. [9]Marc Brett Magnavox GPS clock driver + 9. [10]Piete Brooks MSF clock driver, + Trimble PARSE support + 10. [11]Nelson B Bolyard update and complete + broadcast and crypto features in sntp + 11. [12]Jean-Francois Boudreault + IPv6 support + 12. [13]Reg Clemens Oncore driver (Current maintainer) + 13. [14]Steve Clift OMEGA clock driver + 14. [15]Casey Crellin vxWorks (Tornado) port and + help with target configuration + 15. [16]Sven Dietrich Palisade reference + clock driver, NT adj. residuals, integrated Greg's Winnt port. + 16. [17]John A. Dundas III Apple A/UX port + 17. [18]Torsten Duwe Linux + port + 18. [19]Dennis Ferguson foundation code for + NTP Version 2 as specified in RFC-1119 + 19. [20]John Hay IPv6 support and testing + 20. [21]Dave Hart General maintenance, Windows + port interpolation rewrite + 21. [22]Claas Hilbrecht NeoClock4X clock driver + 22. [23]Glenn Hollinger GOES clock driver + 23. [24]Mike Iglesias DEC Alpha port + 24. [25]Jim Jagielski A/UX port + 25. [26]Jeff Johnson massive prototyping + overhaul + 26. [27]Hans Lambermont or + [28] ntpsweep + 27. [29]Poul-Henning Kamp Oncore driver (Original + author) + 28. [30]Frank Kardel [31] PARSE + (driver 14 reference clocks), STREAMS modules for PARSE, support + scripts, syslog cleanup, dynamic interface handling + 29. [32]Johannes Maximilian Kuehn Rewrote sntp to + comply with NTPv4 specification, ntpq saveconfig + 30. [33]William L. Jones RS/6000 AIX + modifications, HPUX modifications + 31. [34]Dave Katz RS/6000 AIX port + 32. [35]Craig Leres 4.4BSD port, ppsclock, Magnavox + GPS clock driver + 33. [36]George Lindholm SunOS 5.1 port + 34. [37]Louis A. Mamakos MD5-based authentication + 35. [38]Lars H. Mathiesen adaptation of foundation + code for Version 3 as specified in RFC-1305 + 36. [39]Danny Mayer Network I/O, Windows Port, Code + Maintenance + 37. [40]David L. Mills Version 4 foundation, + precision kernel; clock drivers: 1, 3, 4, 6, 7, 11, 13, 18, 19, + 22, 36 + 38. [41]Wolfgang Moeller VMS port + 39. [42]Jeffrey Mogul ntptrace utility + 40. [43]Tom Moore i386 svr4 port + 41. [44]Kamal A Mostafa SCO OpenServer port + 42. [45]Derek Mulcahy and [46]Damon + Hart-Davis ARCRON MSF clock driver + 43. [47]Rob Neal Bancomm refclock and config/parse code + maintenance + 44. [48]Rainer Pruy + monitoring/trap scripts, statistics file handling + 45. [49]Dirce Richards Digital UNIX V4.0 port + 46. [50]Wilfredo Sánchez added support for + NetInfo + 47. [51]Nick Sayer SunOS streams modules + 48. [52]Jack Sasportas Saved a Lot of + space on the stuff in the html/pic/ subdirectory + 49. [53]Ray Schnitzler Unixware1 port + 50. [54]Michael Shields USNO clock driver + 51. [55]Jeff Steinman Datum PTS clock + driver + 52. [56]Harlan Stenn GNU automake/autoconfigure + makeover, various other bits (see the ChangeLog) + 53. [57]Kenneth Stone HP-UX port + 54. [58]Ajit Thyagarajan IP multicast/anycast + support + 55. [59]Tomoaki TSURUOKA TRAK clock + driver + 56. [60]Brian Utterback General codebase, + Solaris issues + 57. [61]Loganaden Velvindron Sandboxing + (libseccomp) support + 58. [62]Paul A Vixie TrueTime GPS driver, generic + TrueTime clock driver + 59. [63]Ulrich Windl corrected and + validated HTML documents according to the HTML DTD + _________________________________________________________________ + +References + + 1. mailto:%20takao_abe@xurb.jp + 2. mailto:%20mark_andrews@isc.org + 3. mailto:%20altmeier@atlsoft.de + 4. mailto:%20vbais@mailman1.intel.co + 5. mailto:%20kirkwood@striderfm.intel.com + 6. mailto:%20michael.barone@lmco.com + 7. mailto:%20karl@owl.HQ.ileaf.com + 8. mailto:%20greg.brackley@bigfoot.com + 9. mailto:%20Marc.Brett@westgeo.com + 10. mailto:%20Piete.Brooks@cl.cam.ac.uk + 11. mailto:%20nelson@bolyard.me + 12. mailto:%20Jean-Francois.Boudreault@viagenie.qc.ca + 13. mailto:%20reg@dwf.com + 14. mailto:%20clift@ml.csiro.au + 15. mailto:%20casey@csc.co.za + 16. mailto:%20Sven_Dietrich@trimble.COM + 17. mailto:%20dundas@salt.jpl.nasa.gov + 18. mailto:%20duwe@immd4.informatik.uni-erlangen.de + 19. mailto:%20dennis@mrbill.canet.ca + 20. mailto:%20jhay@icomtek.csir.co.za + 21. mailto:%20davehart@davehart.com + 22. mailto:%20neoclock4x@linum.com + 23. mailto:%20glenn@herald.usask.ca + 24. mailto:%20iglesias@uci.edu + 25. mailto:%20jagubox.gsfc.nasa.gov + 26. mailto:%20jbj@chatham.usdesign.com + 27. mailto:%20Hans.Lambermont@nl.origin-it.com + 28. mailto:H.Lambermont@chello.nl + 29. mailto:%20phk@FreeBSD.ORG + 30. http://www4.informatik.uni-erlangen.de/%7ekardel + 31. mailto:%20kardel%20%28at%29%20ntp%20%28dot%29%20org + 32. mailto:kuehn@ntp.org + 33. mailto:%20jones@hermes.chpc.utexas.edu + 34. mailto:%20dkatz@cisco.com + 35. mailto:%20leres@ee.lbl.gov + 36. mailto:%20lindholm@ucs.ubc.ca + 37. mailto:%20louie@ni.umd.edu + 38. mailto:%20thorinn@diku.dk + 39. mailto:%20mayer@ntp.org + 40. mailto:%20mills@udel.edu + 41. mailto:%20moeller@gwdgv1.dnet.gwdg.de + 42. mailto:%20mogul@pa.dec.com + 43. mailto:%20tmoore@fievel.daytonoh.ncr.com + 44. mailto:%20kamal@whence.com + 45. mailto:%20derek@toybox.demon.co.uk + 46. mailto:%20d@hd.org + 47. mailto:%20neal@ntp.org + 48. mailto:%20Rainer.Pruy@informatik.uni-erlangen.de + 49. mailto:%20dirce@zk3.dec.com + 50. mailto:%20wsanchez@apple.com + 51. mailto:%20mrapple@quack.kfu.com + 52. mailto:%20jack@innovativeinternet.com + 53. mailto:%20schnitz@unipress.com + 54. mailto:%20shields@tembel.org + 55. mailto:%20pebbles.jpl.nasa.gov + 56. mailto:%20harlan@pfcs.com + 57. mailto:%20ken@sdd.hp.com + 58. mailto:%20ajit@ee.udel.edu + 59. mailto:%20tsuruoka@nc.fukuoka-u.ac.jp + 60. mailto:%20brian.utterback@oracle.com + 61. mailto:%20loganaden@gmail.com + 62. mailto:%20vixie@vix.com + 63. mailto:%20Ulrich.Windl@rz.uni-regensburg.de diff --git a/contrib/ntp/sntp/Makefile.am b/contrib/ntp/sntp/Makefile.am index 1bee65de1..5c30fc27d 100644 --- a/contrib/ntp/sntp/Makefile.am +++ b/contrib/ntp/sntp/Makefile.am @@ -1,51 +1,170 @@ -# Makefile.am, by Harlan Stenn, from: -# Makefile for sntp -# N.M. Maclaren, October 2000. +## Makefile.am for JMK's SNTP, by Harlan Stenn -AUTOMAKE_OPTIONS = foreign -ACLOCAL_AMFLAGS= -I libopts/m4 +ACLOCAL_AMFLAGS = -I m4 -I libevent/m4 -I libopts/m4 -AM_CPPFLAGS= $(LIBOPTS_CFLAGS) -LDADD= $(LIBOPTS_LDADD) +NULL = -NULL= +AM_CFLAGS = $(CFLAGS_NTP) -bindir= ${exec_prefix}/${BINSUBDIR} -bin_PROGRAMS= sntp -#run_ag= cd $(srcdir) && autogen --writable -L $(top_srcdir)/include -run_ag= cd $(srcdir) && autogen --writable +AM_CPPFLAGS = $(SNTP_INCS) +AM_CPPFLAGS += $(LIBOPTS_CFLAGS) +AM_CPPFLAGS += $(CPPFLAGS_LIBEVENT) +AM_CPPFLAGS += $(CPPFLAGS_NTP) + +AM_LDFLAGS = $(LDFLAGS_NTP) + +LDADD = version.o +LDADD += libsntp.a +LDADD += $(LIBOPTS_LDADD) +LDADD += $(LDADD_LIBEVENT) +LDADD += ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) +LDADD += $(PTHREAD_LIBS) +LDADD += $(LDADD_NTP) + +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L include -L ag-tpl --writable +std_def_list = \ + $(srcdir)/include/debug-opt.def \ + $(srcdir)/include/autogen-version.def \ + $(srcdir)/include/copyright.def \ + $(srcdir)/include/homerc.def \ + $(srcdir)/include/ntp.lic \ + $(srcdir)/include/version.def \ + $(NULL) + +EXTRA_PROGRAMS = sntp + +bin_PROGRAMS = @SNTP_DB@ +libexec_PROGRAMS = @SNTP_DL@ +sbin_PROGRAMS = @SNTP_DS@ + +SUBDIRS = include scripts unity +DIST_FAIL = + +if BUILD_LIBEVENT +SUBDIRS += libevent +else +DIST_FAIL += "--enable-local-libevent" +endif -SUBDIRS= if NEED_LIBOPTS -SUBDIRS+= libopts +SUBDIRS += libopts +endif + +if BUILD_SNTP +noinst_LIBRARIES = libsntp.a +SUBDIRS += tests endif -SUBDIRS+= . - -sntp_SOURCES = \ - header.h \ - internet.c \ - internet.h \ - kludges.h \ - main.c \ - sntp-opts.c \ - sntp-opts.h \ - socket.c \ - timing.c \ - unix.c \ + +libsntp_a_SOURCES = \ + crypto.c \ + kod_management.c \ + log.c \ + main.c \ + networking.c \ + sntp-opts.c \ + utilities.c \ + $(NULL) + +sntp_SOURCES = \ + sntp.c \ + $(NULL) + +noinst_HEADERS = \ + crypto.h \ + data_formats.h \ + kod_management.h \ + log.h \ + main.h \ + networking.h \ + sntp-opts.h \ + utilities.h \ + $(NULL) + +DISTCLEANFILES = \ + .version \ + version.c \ + config.log \ + $(man_MANS) \ + $(NULL) + +EXTRA_DIST = \ + $(srcdir)/COPYRIGHT \ + ag-tpl \ + deps-ver \ + invoke-sntp.menu \ + invoke-sntp.texi \ + @NTP_FORCE_LIBEVENT_DIST@ \ + libpkgver \ + loc \ + sntp-opts.def \ + sntp.1sntpman \ + sntp.1sntpmdoc \ + sntp.man.in \ + sntp.mdoc.in \ + sntp.html \ + sntp.texi \ + unity/auto \ + $(srcdir)/scm-rev \ + $(srcdir)/m4/version.m4 \ + $(NULL) + +BUILT_SOURCES = \ + $(srcdir)/COPYRIGHT \ + libtool \ + $(srcdir)/sntp-opts.c \ + $(srcdir)/sntp-opts.h \ + check-scm-rev \ + $(srcdir)/include/version.def \ + $(srcdir)/m4/version.m4 \ + $(srcdir)/include/version.texi \ $(NULL) -dist_man_MANS= sntp.1 +CLEANFILES = \ + built-sources-only \ + check-COPYRIGHT-submake \ + $(NULL) -EXTRA_DIST= bincheck.mf \ - COPYRIGHT \ - sntp-opts.def sntp.1 sntp-opts.texi sntp-opts.menu \ - autogen-version.def version.def -BUILT_SOURCES= check-autogen-version.def check-version.def \ - sntp-opts.c sntp-opts.h sntp.1 sntp-opts.texi sntp-opts.menu -man_MANS= sntp.1 +man1_MANS= +man8_MANS= +man_MANS= sntp.$(SNTP_MS) +## HMS: Real Soon Now... +##info_TEXINFOS= sntp.texi +##sntp_TEXINFOS= invoke-sntp.texi + +html_DATA= \ + $(srcdir)/sntp.html \ + $(NULL) + +noinst_DATA= \ + $(srcdir)/invoke-sntp.menu \ + $(srcdir)/invoke-sntp.texi \ + $(srcdir)/sntp.man.in \ + $(srcdir)/sntp.mdoc.in \ + $(NULL) + +install-data-local: install-html FRC: + @: do-nothing action to prevent default SCCS get + @: FRC "force" depends on nothing and is not a file, so is + @: always out-of-date causing targets which depend on it to + @: similarly always be outdated causing their rules to fire + @: each time they or a dependent is built. + +$(PROGRAMS): version.o + +## We probably need something about libevent, too +## That is probably not possible since LDADD_LIBEVENT may be +## non-file "-levent_core". + +version.c: $(sntp_OBJECTS) ../libntp/libntp.a Makefile $(srcdir)/scm-rev + env CSET=`cat $(srcdir)/scm-rev` $(top_builddir)/../scripts/build/mkver sntp + +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o + check-autogen-version.def: FRC @cd $(srcdir) \ && test -r ../include/autogen-version.def \ @@ -55,23 +174,116 @@ check-autogen-version.def: FRC echo "Installing new sntp/autogen-version.def file"; \ fi ) -check-version.def: FRC - @cd $(srcdir) \ - && test -r ../include/version.def \ - && ( if cmp -s ../include/version.def version.def; \ - then : ; \ - else cp ../include/version.def version.def; \ - echo "Installing new sntp/version.def file"; \ - fi ) +$(srcdir)/autogen-version.def: + $(MAKE) $(AM_MAKEFLAGS) check-autogen-version.def + +built-sources-only: $(BUILT_SOURCES) + @: do-nothing action to avoid default SCCS get + +## HMS: The next bit is still suboptimal. We'll get an error if this is +## a bk repo and srcdir or scm-rev is unwritable. + +check-scm-rev: $(srcdir)/scm-rev + @: do-nothing + +$(srcdir)/scm-rev: + -test -r $(srcdir)/../SCCS/s.ChangeSet && \ + (bk version) >/dev/null 2>&1 && \ + cd $(srcdir)/.. && \ + x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ + y=`cat sntp/scm-rev 2>/dev/null` || true && \ + case "$$x" in ''|$$y) ;; *) echo $$x > sntp/scm-rev ;; esac + +$(srcdir)/m4/version.m4: $(srcdir)/../packageinfo.sh + TEMPDIR=`pwd` && export TEMPDIR && cd $(srcdir) && \ + ../scripts/build/genver m4/version.m4 + +$(srcdir)/include/version.def: $(srcdir)/../packageinfo.sh + TEMPDIR=`pwd` && export TEMPDIR && cd $(srcdir) && \ + ../scripts/build/genver include/version.def + +$(srcdir)/include/version.texi: $(srcdir)/../packageinfo.sh + TEMPDIR=`pwd` && export TEMPDIR && cd $(srcdir) && \ + ../scripts/build/genver include/version.texi + +$(srcdir)/../COPYRIGHT: + cd .. && $(MAKE) $(AM_MAKEFLAGS) COPYRIGHT-please + +check-COPYRIGHT-submake: $(srcdir)/../COPYRIGHT + @cmp -s $(srcdir)/../COPYRIGHT $(srcdir)/COPYRIGHT \ + || { cp $(srcdir)/../COPYRIGHT $(srcdir) \ + && echo 'updated sntp/COPYRIGHT installed' ;} + @echo 'submake avoided if this file is newer than parent COPYRIGHT' > $@ + +check-COPYRIGHT: FRC + [ ! -r $(srcdir)/../COPYRIGHT ] \ + || [ check-COPYRIGHT-submake -nt $(srcdir)/../COPYRIGHT ] \ + || $(MAKE) $(AM_MAKEFLAGS) check-COPYRIGHT-submake + +$(srcdir)/COPYRIGHT: check-COPYRIGHT + @: do-nothing action to prevent any default $(srcdir)/sntp-opts.h: $(srcdir)/sntp-opts.c -$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/version.def + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(std_def_list) $(run_ag) sntp-opts.def -$(srcdir)/sntp.1: $(srcdir)/sntp-opts.def $(srcdir)/version.def - $(run_ag) -Tagman1.tpl -bsntp sntp-opts.def +### + +$(srcdir)/sntp.1sntpman: $(srcdir)/sntp-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1sntpman -Tagman-cmd.tpl sntp-opts.def + +$(srcdir)/sntp.man.in: $(srcdir)/sntp.1sntpman $(srcdir)/scripts/mansec2subst.sed + sed -f $(srcdir)/scripts/mansec2subst.sed $(srcdir)/sntp.1sntpman > $(srcdir)/sntp.man.in+ + mv $(srcdir)/sntp.man.in+ $(srcdir)/sntp.man.in + +### + +$(srcdir)/sntp.1sntpmdoc: $(srcdir)/sntp-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1sntpmdoc -Tagmdoc-cmd.tpl sntp-opts.def + +$(srcdir)/sntp.mdoc.in: $(srcdir)/sntp.1sntpmdoc $(srcdir)/scripts/mansec2subst.sed + sed -f $(srcdir)/scripts/mansec2subst.sed $(srcdir)/sntp.1sntpmdoc > $(srcdir)/sntp.mdoc.in+ + mv $(srcdir)/sntp.mdoc.in+ $(srcdir)/sntp.mdoc.in + +### + +sntp.$(SNTP_MS): $(srcdir)/sntp.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=sntp.$(SNTP_MS)+:$(srcdir)/sntp.$(MANTAGFMT).in + mv sntp.$(SNTP_MS)+ sntp.$(SNTP_MS) + +### + +$(srcdir)/invoke-sntp.menu: $(srcdir)/invoke-sntp.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-sntp.texi: $(srcdir)/sntp-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section sntp-opts.def + $(top_srcdir)/../scripts/build/check--help $@ + +$(srcdir)/sntp.html: $(srcdir)/invoke-sntp.menu $(srcdir)/invoke-sntp.texi $(srcdir)/sntp.texi $(srcdir)/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o sntp.html sntp.texi || true ) + +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + +# HMS: libevent/ is a target if it's in EXTRA_DIST via NTP_FORCE_LIBEVENT_DIST. +# Note that libevent/ is already in DIST_SUBDIRS (implicit in Makefile.am +# but explicit in Makefile.in). This check doesn't help with distclean. +libevent: distdir-pre-check -$(srcdir)/sntp-opts.texi $(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.def $(srcdir)/version.def - $(run_ag) -Taginfo.tpl -DLEVEL=section sntp-opts.def +# HMS: Stops the build for gmake or pmake +distdir-pre-check: + case "$(DIST_FAIL)" in \ + '') ;; \ + *) $(error re-run configure adding $(DIST_FAIL) if you want to make a distribution.); \ + echo "re-run configure adding $(DIST_FAIL) if you want to make a distribution."; \ + exit 1 ;; \ + esac -include bincheck.mf +include $(top_srcdir)/bincheck.mf +include $(top_srcdir)/check-libntp.mf +include $(top_srcdir)/check-libopts.mf +include $(top_srcdir)/depsver.mf +include $(top_srcdir)/includes.mf diff --git a/contrib/ntp/sntp/Makefile.in b/contrib/ntp/sntp/Makefile.in index 62acb87ad..39f7dc7dc 100644 --- a/contrib/ntp/sntp/Makefile.in +++ b/contrib/ntp/sntp/Makefile.in @@ -1,9 +1,8 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.15 from Makefile.am. # @configure_input@ -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -15,15 +14,69 @@ @SET_MAKE@ -# Makefile.am, by Harlan Stenn, from: -# Makefile for sntp -# N.M. Maclaren, October 2000. - # we traditionally installed software in bindir, while it should have gone # in sbindir. Now that we offer a choice, look in the "other" installation # subdir to warn folks if there is another version there. + + + VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -42,57 +95,127 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ -bin_PROGRAMS = sntp$(EXEEXT) -@NEED_LIBOPTS_TRUE@am__append_1 = libopts -DIST_COMMON = README $(am__configure_deps) $(dist_man_MANS) \ - $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(srcdir)/bincheck.mf $(srcdir)/config.h.in \ - $(top_srcdir)/configure compile config.guess config.sub \ - depcomp install-sh ltmain.sh missing +EXTRA_PROGRAMS = sntp$(EXEEXT) +@BUILD_LIBEVENT_TRUE@am__append_1 = libevent +@BUILD_LIBEVENT_FALSE@am__append_2 = "--enable-local-libevent" +@NEED_LIBOPTS_TRUE@am__append_3 = libopts +@BUILD_SNTP_TRUE@am__append_4 = tests subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ + $(top_srcdir)/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/m4/hms_search_lib.m4 $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_compiler.m4 \ + $(top_srcdir)/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/m4/ntp_debug.m4 $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/m4/ntp_googletest.m4 \ + $(top_srcdir)/m4/ntp_ipv6.m4 $(top_srcdir)/m4/ntp_lib_m.m4 \ + $(top_srcdir)/m4/ntp_libevent.m4 \ + $(top_srcdir)/m4/ntp_libntp.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_locinfo.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/m4/ntp_prog_cc.m4 $(top_srcdir)/m4/ntp_sntp.m4 \ + $(top_srcdir)/m4/ntp_sysexits.m4 \ + $(top_srcdir)/m4/ntp_unitytest.m4 \ + $(top_srcdir)/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/m4/openldap-thread-check.m4 \ + $(top_srcdir)/m4/openldap.m4 $(top_srcdir)/m4/os_cflags.m4 \ + $(top_srcdir)/m4/snprintf.m4 $(top_srcdir)/m4/version.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ + $(am__configure_deps) $(noinst_HEADERS) $(am__DIST_COMMON) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(install_sh) -d CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" -PROGRAMS = $(bin_PROGRAMS) +LIBRARIES = $(noinst_LIBRARIES) +ARFLAGS = cru +AM_V_AR = $(am__v_AR_@AM_V@) +am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@) +am__v_AR_0 = @echo " AR " $@; +am__v_AR_1 = +libsntp_a_AR = $(AR) $(ARFLAGS) +libsntp_a_LIBADD = am__objects_1 = -am_sntp_OBJECTS = internet.$(OBJEXT) main.$(OBJEXT) \ - sntp-opts.$(OBJEXT) socket.$(OBJEXT) timing.$(OBJEXT) \ - unix.$(OBJEXT) $(am__objects_1) +am_libsntp_a_OBJECTS = crypto.$(OBJEXT) kod_management.$(OBJEXT) \ + log.$(OBJEXT) main.$(OBJEXT) networking.$(OBJEXT) \ + sntp-opts.$(OBJEXT) utilities.$(OBJEXT) $(am__objects_1) +libsntp_a_OBJECTS = $(am_libsntp_a_OBJECTS) +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" \ + "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" \ + "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)" +PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(sbin_PROGRAMS) +am_sntp_OBJECTS = sntp.$(OBJEXT) $(am__objects_1) sntp_OBJECTS = $(am_sntp_OBJECTS) sntp_LDADD = $(LDADD) am__DEPENDENCIES_1 = -sntp_DEPENDENCIES = $(am__DEPENDENCIES_1) +sntp_DEPENDENCIES = version.o libsntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) ../libntp/libntp.a $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ -depcomp = $(SHELL) $(top_srcdir)/depcomp +depcomp = $(SHELL) $(top_srcdir)/libevent/build-aux/depcomp am__depfiles_maybe = depfiles am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = CCLD = $(CC) -LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ - --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ - $(LDFLAGS) -o $@ -SOURCES = $(sntp_SOURCES) -DIST_SOURCES = $(sntp_SOURCES) -RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ - html-recursive info-recursive install-data-recursive \ - install-dvi-recursive install-exec-recursive \ - install-html-recursive install-info-recursive \ - install-pdf-recursive install-ps-recursive install-recursive \ - installcheck-recursive installdirs-recursive pdf-recursive \ - ps-recursive uninstall-recursive +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libsntp_a_SOURCES) $(sntp_SOURCES) +DIST_SOURCES = $(libsntp_a_SOURCES) $(sntp_SOURCES) +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -114,24 +237,76 @@ am__nobase_list = $(am__nobase_strip_setup); \ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } man1dir = $(mandir)/man1 +man8dir = $(mandir)/man8 NROFF = nroff -MANS = $(dist_man_MANS) $(man_MANS) +MANS = $(man1_MANS) $(man8_MANS) $(man_MANS) +DATA = $(html_DATA) $(noinst_DATA) +HEADERS = $(noinst_HEADERS) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive -AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ - $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \ - distdir dist dist-all distcheck +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + cscope distdir dist dist-all distcheck +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ + $(LISP)config.h.in +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags -DIST_SUBDIRS = libopts . +CSCOPE = cscope +DIST_SUBDIRS = include scripts unity libevent libopts tests +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \ + $(top_srcdir)/bincheck.mf $(top_srcdir)/check-libntp.mf \ + $(top_srcdir)/check-libopts.mf $(top_srcdir)/depsver.mf \ + $(top_srcdir)/includes.mf \ + $(top_srcdir)/libevent/build-aux/ar-lib \ + $(top_srcdir)/libevent/build-aux/compile \ + $(top_srcdir)/libevent/build-aux/config.guess \ + $(top_srcdir)/libevent/build-aux/config.sub \ + $(top_srcdir)/libevent/build-aux/depcomp \ + $(top_srcdir)/libevent/build-aux/install-sh \ + $(top_srcdir)/libevent/build-aux/ltmain.sh \ + $(top_srcdir)/libevent/build-aux/missing compile config.guess \ + config.sub depcomp install-sh libevent/build-aux/ar-lib \ + libevent/build-aux/compile libevent/build-aux/config.guess \ + libevent/build-aux/config.sub libevent/build-aux/depcomp \ + libevent/build-aux/install-sh libevent/build-aux/ltmain.sh \ + libevent/build-aux/missing libevent/build-aux/ylwrap ltmain.sh \ + missing DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ - { test ! -d "$(distdir)" \ - || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -fr "$(distdir)"; }; } + if test -d "$(distdir)"; then \ + find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ + && rm -rf "$(distdir)" \ + || { sleep 5 && rm -rf "$(distdir)"; }; \ + else :; fi +am__post_remove_distdir = $(am__remove_distdir) am__relativize = \ dir0=`pwd`; \ sed_first='s,^\([^/]*\)/.*$$,\1,'; \ @@ -159,49 +334,151 @@ am__relativize = \ reldir="$$dir2" DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best +DIST_TARGETS = dist-gzip distuninstallcheck_listfiles = find . -type f -print +am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ + | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ -BINSUBDIR = @BINSUBDIR@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ -ECHO = @ECHO@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ +FGREP = @FGREP@ GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ HAVE_INLINE = @HAVE_INLINE@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NTP = @LDADD_NTP@ LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ LIBOBJS = @LIBOBJS@ LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ LIBOPTS_DIR = @LIBOPTS_DIR@ LIBOPTS_LDADD = @LIBOPTS_LDADD@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIB_SYSLOG = @LIB_SYSLOG@ +LIPO = @LIPO@ LN_S = @LN_S@ +LTHREAD_LIBS = @LTHREAD_LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_FORCE_LIBEVENT_DIST = @NTP_FORCE_LIBEVENT_DIST@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -209,23 +486,54 @@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_RUBY = @PATH_RUBY@ PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ +SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ STRIP = @STRIP@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ -bindir = ${exec_prefix}/${BINSUBDIR} +bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ @@ -260,50 +568,126 @@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ +subdirs = @subdirs@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = foreign -ACLOCAL_AMFLAGS = -I libopts/m4 -AM_CPPFLAGS = $(LIBOPTS_CFLAGS) -LDADD = $(LIBOPTS_LDADD) +ACLOCAL_AMFLAGS = -I m4 -I libevent/m4 -I libopts/m4 NULL = -#run_ag= cd $(srcdir) && autogen --writable -L $(top_srcdir)/include -run_ag = cd $(srcdir) && autogen --writable -SUBDIRS = $(am__append_1) . +AM_CFLAGS = $(CFLAGS_NTP) +AM_CPPFLAGS = $(SNTP_INCS) $(LIBOPTS_CFLAGS) $(CPPFLAGS_LIBEVENT) \ + $(CPPFLAGS_NTP) +AM_LDFLAGS = $(LDFLAGS_NTP) +LDADD = version.o libsntp.a $(LIBOPTS_LDADD) $(LDADD_LIBEVENT) \ + ../libntp/libntp.a $(LDADD_LIBNTP) $(LIBM) $(PTHREAD_LIBS) \ + $(LDADD_NTP) +run_ag = cd $(srcdir) && env PATH="$(abs_builddir):$(PATH)" AUTOGEN_DNE_DATE=-D \ + autogen -L include -L ag-tpl --writable + +std_def_list = \ + $(srcdir)/include/debug-opt.def \ + $(srcdir)/include/autogen-version.def \ + $(srcdir)/include/copyright.def \ + $(srcdir)/include/homerc.def \ + $(srcdir)/include/ntp.lic \ + $(srcdir)/include/version.def \ + $(NULL) + +bin_PROGRAMS = @SNTP_DB@ +libexec_PROGRAMS = @SNTP_DL@ +sbin_PROGRAMS = @SNTP_DS@ +SUBDIRS = include scripts unity $(am__append_1) $(am__append_3) \ + $(am__append_4) +DIST_FAIL = $(am__append_2) +@BUILD_SNTP_TRUE@noinst_LIBRARIES = libsntp.a +libsntp_a_SOURCES = \ + crypto.c \ + kod_management.c \ + log.c \ + main.c \ + networking.c \ + sntp-opts.c \ + utilities.c \ + $(NULL) + sntp_SOURCES = \ - header.h \ - internet.c \ - internet.h \ - kludges.h \ - main.c \ - sntp-opts.c \ - sntp-opts.h \ - socket.c \ - timing.c \ - unix.c \ + sntp.c \ + $(NULL) + +noinst_HEADERS = \ + crypto.h \ + data_formats.h \ + kod_management.h \ + log.h \ + main.h \ + networking.h \ + sntp-opts.h \ + utilities.h \ + $(NULL) + +DISTCLEANFILES = \ + .version \ + version.c \ + config.log \ + $(man_MANS) \ $(NULL) -dist_man_MANS = sntp.1 -EXTRA_DIST = bincheck.mf \ - COPYRIGHT \ - sntp-opts.def sntp.1 sntp-opts.texi sntp-opts.menu \ - autogen-version.def version.def +EXTRA_DIST = \ + $(srcdir)/COPYRIGHT \ + ag-tpl \ + deps-ver \ + invoke-sntp.menu \ + invoke-sntp.texi \ + @NTP_FORCE_LIBEVENT_DIST@ \ + libpkgver \ + loc \ + sntp-opts.def \ + sntp.1sntpman \ + sntp.1sntpmdoc \ + sntp.man.in \ + sntp.mdoc.in \ + sntp.html \ + sntp.texi \ + unity/auto \ + $(srcdir)/scm-rev \ + $(srcdir)/m4/version.m4 \ + $(NULL) -BUILT_SOURCES = check-autogen-version.def check-version.def \ - sntp-opts.c sntp-opts.h sntp.1 sntp-opts.texi sntp-opts.menu +BUILT_SOURCES = $(srcdir)/COPYRIGHT libtool $(srcdir)/sntp-opts.c \ + $(srcdir)/sntp-opts.h check-scm-rev \ + $(srcdir)/include/version.def $(srcdir)/m4/version.m4 \ + $(srcdir)/include/version.texi $(NULL) check-libntp \ + check-libopts .deps-ver +CLEANFILES = built-sources-only check-COPYRIGHT-submake $(NULL) \ + check-libntp check-libopts .deps-ver +man1_MANS = +man8_MANS = +man_MANS = sntp.$(SNTP_MS) +html_DATA = \ + $(srcdir)/sntp.html \ + $(NULL) -man_MANS = sntp.1 +noinst_DATA = \ + $(srcdir)/invoke-sntp.menu \ + $(srcdir)/invoke-sntp.texi \ + $(srcdir)/sntp.man.in \ + $(srcdir)/sntp.mdoc.in \ + $(NULL) + +SNTP_INCS = -I$(top_srcdir)/../include \ + -I$(top_srcdir)/../lib/isc/include \ + -I$(top_srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include \ + -I$(top_srcdir)/../lib/isc/unix/include all: $(BUILT_SOURCES) config.h $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: .SUFFIXES: .c .lo .o .obj -am--refresh: +am--refresh: Makefile @: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/bincheck.mf $(am__configure_deps) +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/bincheck.mf $(top_srcdir)/check-libntp.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -316,7 +700,6 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/bincheck.mf $(am__config echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile -.PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -326,6 +709,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; +$(top_srcdir)/bincheck.mf $(top_srcdir)/check-libntp.mf $(top_srcdir)/check-libopts.mf $(top_srcdir)/depsver.mf $(top_srcdir)/includes.mf $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck @@ -337,10 +721,8 @@ $(ACLOCAL_M4): $(am__aclocal_m4_deps) $(am__aclocal_m4_deps): config.h: stamp-h1 - @if test ! -f $@; then \ - rm -f stamp-h1; \ - $(MAKE) $(AM_MAKEFLAGS) stamp-h1; \ - else :; fi + @test -f $@ || rm -f stamp-h1 + @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 @@ -352,16 +734,29 @@ $(srcdir)/config.h.in: $(am__configure_deps) distclean-hdr: -rm -f config.h stamp-h1 + +clean-noinstLIBRARIES: + -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) + +libsntp.a: $(libsntp_a_OBJECTS) $(libsntp_a_DEPENDENCIES) $(EXTRA_libsntp_a_DEPENDENCIES) + $(AM_V_at)-rm -f libsntp.a + $(AM_V_AR)$(libsntp_a_AR) libsntp.a $(libsntp_a_OBJECTS) $(libsntp_a_LIBADD) + $(AM_V_at)$(RANLIB) libsntp.a install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p || test -f $$p1; \ - then echo "$$p"; echo "$$p"; else :; fi; \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ - sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ @@ -382,7 +777,8 @@ uninstall-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' `; \ + -e 's/$$/$(EXEEXT)/' \ + `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files @@ -395,9 +791,108 @@ clean-binPROGRAMS: list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list -sntp$(EXEEXT): $(sntp_OBJECTS) $(sntp_DEPENDENCIES) +install-libexecPROGRAMS: $(libexec_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libexecdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libexecdir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(libexecdir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(libexecdir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-libexecPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(libexec_PROGRAMS)'; test -n "$(libexecdir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(libexecdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(libexecdir)" && rm -f $$files + +clean-libexecPROGRAMS: + @list='$(libexec_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +install-sbinPROGRAMS: $(sbin_PROGRAMS) + @$(NORMAL_INSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ + fi; \ + for p in $$list; do echo "$$p $$p"; done | \ + sed 's/$(EXEEXT)$$//' | \ + while read p p1; do if test -f $$p \ + || test -f $$p1 \ + ; then echo "$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n;h' \ + -e 's|.*|.|' \ + -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ + sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) files[d] = files[d] " " $$1; \ + else { print "f", $$3 "/" $$4, $$1; } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ + $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-sbinPROGRAMS: + @$(NORMAL_UNINSTALL) + @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ + -e 's/$$/$(EXEEXT)/' \ + `; \ + test -n "$$list" || exit 0; \ + echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(sbindir)" && rm -f $$files + +clean-sbinPROGRAMS: + @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +sntp$(EXEEXT): $(sntp_OBJECTS) $(sntp_DEPENDENCIES) $(EXTRA_sntp_DEPENDENCIES) @rm -f sntp$(EXEEXT) - $(LINK) $(sntp_OBJECTS) $(sntp_LDADD) $(LIBS) + $(AM_V_CCLD)$(LINK) $(sntp_OBJECTS) $(sntp_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) @@ -405,33 +900,35 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/internet.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/crypto.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kod_management.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/networking.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sntp-opts.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/socket.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timing.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/unix.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sntp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/utilities.Po@am__quote@ .c.o: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo @@ -441,13 +938,20 @@ clean-libtool: distclean-libtool: -rm -f libtool config.lt -install-man1: $(dist_man_MANS) $(man_MANS) +install-man1: $(man1_MANS) $(man_MANS) @$(NORMAL_INSTALL) - test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)" - @list=''; test -n "$(man1dir)" || exit 0; \ - { for i in $$list; do echo "$$i"; done; \ - l2='$(dist_man_MANS) $(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ - sed -n '/\.1[a-z]*$$/p'; \ + @list1='$(man1_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man1dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.1[a-z]*$$/p'; \ + fi; \ } | while read p; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; echo "$$p"; \ @@ -470,33 +974,98 @@ install-man1: $(dist_man_MANS) $(man_MANS) uninstall-man1: @$(NORMAL_UNINSTALL) - @list=''; test -n "$(man1dir)" || exit 0; \ + @list='$(man1_MANS)'; test -n "$(man1dir)" || exit 0; \ files=`{ for i in $$list; do echo "$$i"; done; \ - l2='$(dist_man_MANS) $(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ - test -z "$$files" || { \ - echo " ( cd '$(DESTDIR)$(man1dir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(man1dir)" && rm -f $$files; } + dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) +install-man8: $(man8_MANS) $(man_MANS) + @$(NORMAL_INSTALL) + @list1='$(man8_MANS)'; \ + list2='$(man_MANS)'; \ + test -n "$(man8dir)" \ + && test -n "`echo $$list1$$list2`" \ + || exit 0; \ + echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ + { for i in $$list1; do echo "$$i"; done; \ + if test -n "$$list2"; then \ + for i in $$list2; do echo "$$i"; done \ + | sed -n '/\.8[a-z]*$$/p'; \ + fi; \ + } | while read p; do \ + if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; echo "$$p"; \ + done | \ + sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ + sed 'N;N;s,\n, ,g' | { \ + list=; while read file base inst; do \ + if test "$$base" = "$$inst"; then list="$$list $$file"; else \ + echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ + $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ + fi; \ + done; \ + for i in $$list; do echo "$$i"; done | $(am__base_list) | \ + while read files; do \ + test -z "$$files" || { \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ + done; } + +uninstall-man8: + @$(NORMAL_UNINSTALL) + @list='$(man8_MANS)'; test -n "$(man8dir)" || exit 0; \ + files=`{ for i in $$list; do echo "$$i"; done; \ + l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ + sed -n '/\.8[a-z]*$$/p'; \ + } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ + -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ + dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) +install-htmlDATA: $(html_DATA) + @$(NORMAL_INSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \ + done + +uninstall-htmlDATA: + @$(NORMAL_UNINSTALL) + @list='$(html_DATA)'; test -n "$(htmldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(htmldir)'; $(am__uninstall_files_from_dir) # This directory's subdirectories are mostly independent; you can cd -# into them and run `make' without going through this Makefile. -# To change the values of `make' variables: instead of editing Makefiles, -# (1) if the variable is set in `config.status', edit `config.status' -# (which will cause the Makefiles to be regenerated when you run `make'); -# (2) otherwise, pass the desired values on the `make' command line. -$(RECURSIVE_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ @@ -511,57 +1080,12 @@ $(RECURSIVE_TARGETS): $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" -$(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - rev=''; for subdir in $$list; do \ - if test "$$subdir" = "."; then :; else \ - rev="$$subdir $$rev"; \ - fi; \ - done; \ - rev="$$rev ."; \ - target=`echo $@ | sed s/-recursive//`; \ - for subdir in $$rev; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done && test -z "$$fail" -tags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ - done -ctags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ - done +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ @@ -577,12 +1101,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ - list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ + $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ @@ -594,15 +1113,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $$unique; \ fi; \ fi -ctags: CTAGS -CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in files) print i; }; }'`; \ +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique @@ -611,24 +1126,33 @@ GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" +cscope: cscope.files + test ! -s cscope.files \ + || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) +clean-cscope: + -rm -f cscope.files +cscope.files: clean-cscope cscopelist +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + -rm -f cscope.out cscope.in.out cscope.po.out cscope.files distdir: $(DISTFILES) - @list='$(MANS)'; if test -n "$$list"; then \ - list=`for p in $$list; do \ - if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ - if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \ - if test -n "$$list" && \ - grep 'ab help2man is required to generate this page' $$list >/dev/null; then \ - echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \ - grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \ - echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \ - echo " typically \`make maintainer-clean' will remove them" >&2; \ - exit 1; \ - else :; fi; \ - else :; fi $(am__remove_distdir) test -d "$(distdir)" || mkdir "$(distdir)" @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ @@ -662,13 +1186,10 @@ distdir: $(DISTFILES) done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ - test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ @@ -689,43 +1210,50 @@ distdir: $(DISTFILES) fi; \ done -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ + || find "$(distdir)" -type d ! -perm -755 \ + -exec chmod u+rwx,go+rx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r "$(distdir)" dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) + $(am__post_remove_distdir) dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 - $(am__remove_distdir) + tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 + $(am__post_remove_distdir) -dist-lzma: distdir - tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma - $(am__remove_distdir) +dist-lzip: distdir + tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz + $(am__post_remove_distdir) dist-xz: distdir - tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz - $(am__remove_distdir) + tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz + $(am__post_remove_distdir) dist-tarZ: distdir + @echo WARNING: "Support for distribution archives compressed with" \ + "legacy program 'compress' is deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__remove_distdir) + $(am__post_remove_distdir) dist-shar: distdir + @echo WARNING: "Support for shar distribution archives is" \ + "deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz - $(am__remove_distdir) + $(am__post_remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) - $(am__remove_distdir) + $(am__post_remove_distdir) -dist dist-all: distdir - tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz - $(am__remove_distdir) +dist dist-all: + $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' + $(am__post_remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another @@ -733,31 +1261,33 @@ dist dist-all: distdir distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ - bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lzma*) \ - unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ + bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.lz*) \ + lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ *.tar.xz*) \ xz -dc $(distdir).tar.xz | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac - chmod -R a-w $(distdir); chmod a+w $(distdir) - mkdir $(distdir)/_build - mkdir $(distdir)/_inst + chmod -R a-w $(distdir) + chmod u+w $(distdir) + mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst chmod a-w $(distdir) test -d $(distdir)/_build || exit 0; \ dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && am__cwd=`pwd` \ - && $(am__cd) $(distdir)/_build \ - && ../configure --srcdir=.. --prefix="$$dc_install_base" \ + && $(am__cd) $(distdir)/_build/sub \ + && ../../configure \ + $(AM_DISTCHECK_CONFIGURE_FLAGS) \ $(DISTCHECK_CONFIGURE_FLAGS) \ + --srcdir=../.. --prefix="$$dc_install_base" \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ @@ -780,13 +1310,21 @@ distcheck: dist && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ && cd "$$am__cwd" \ || exit 1 - $(am__remove_distdir) + $(am__post_remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' distuninstallcheck: - @$(am__cd) '$(distuninstallcheck_dir)' \ - && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ + @test -n '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: trying to run $@ with an empty' \ + '$$(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + $(am__cd) '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ @@ -805,10 +1343,11 @@ distcleancheck: distclean check-am: all-am check: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) check-recursive -all-am: Makefile $(PROGRAMS) $(MANS) config.h +all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(MANS) $(DATA) $(HEADERS) \ + config.h installdirs: installdirs-recursive installdirs-am: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)"; do \ + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libexecdir)" "$(DESTDIR)$(sbindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(htmldir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: $(BUILT_SOURCES) @@ -822,17 +1361,24 @@ install-am: all-am installcheck: installcheck-recursive install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @@ -840,7 +1386,9 @@ maintainer-clean-generic: -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-recursive -clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am +clean-am: clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ + clean-libtool clean-noinstLIBRARIES clean-sbinPROGRAMS \ + mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) @@ -861,13 +1409,14 @@ info: info-recursive info-am: -install-data-am: install-man +install-data-am: install-data-local install-htmlDATA install-man install-dvi: install-dvi-recursive install-dvi-am: -install-exec-am: install-binPROGRAMS +install-exec-am: install-binPROGRAMS install-libexecPROGRAMS \ + install-sbinPROGRAMS @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-exec-hook install-html: install-html-recursive @@ -878,7 +1427,7 @@ install-info: install-info-recursive install-info-am: -install-man: install-man1 +install-man: install-man1 install-man8 install-pdf: install-pdf-recursive @@ -910,35 +1459,57 @@ ps: ps-recursive ps-am: -uninstall-am: uninstall-binPROGRAMS uninstall-man - -uninstall-man: uninstall-man1 - -.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) all check \ - ctags-recursive install install-am install-exec-am \ - install-strip tags-recursive - -.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ - all all-am am--refresh check check-am clean clean-binPROGRAMS \ - clean-generic clean-libtool ctags ctags-recursive dist \ - dist-all dist-bzip2 dist-gzip dist-lzma dist-shar dist-tarZ \ - dist-xz dist-zip distcheck distclean distclean-compile \ - distclean-generic distclean-hdr distclean-libtool \ - distclean-tags distcleancheck distdir distuninstallcheck dvi \ - dvi-am html html-am info info-am install install-am \ - install-binPROGRAMS install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-man1 install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs installdirs-am maintainer-clean \ +uninstall-am: uninstall-binPROGRAMS uninstall-htmlDATA \ + uninstall-libexecPROGRAMS uninstall-man uninstall-sbinPROGRAMS + +uninstall-man: uninstall-man1 uninstall-man8 + +.MAKE: $(am__recursive_targets) all check install install-am \ + install-exec-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ + am--refresh check check-am clean clean-binPROGRAMS \ + clean-cscope clean-generic clean-libexecPROGRAMS clean-libtool \ + clean-noinstLIBRARIES clean-sbinPROGRAMS cscope cscopelist-am \ + ctags ctags-am dist dist-all dist-bzip2 dist-gzip dist-lzip \ + dist-shar dist-tarZ dist-xz dist-zip distcheck distclean \ + distclean-compile distclean-generic distclean-hdr \ + distclean-libtool distclean-tags distcleancheck distdir \ + distuninstallcheck dvi dvi-am html html-am info info-am \ + install install-am install-binPROGRAMS install-data \ + install-data-am install-data-local install-dvi install-dvi-am \ + install-exec install-exec-am install-exec-hook install-html \ + install-html-am install-htmlDATA install-info install-info-am \ + install-libexecPROGRAMS install-man install-man1 install-man8 \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-sbinPROGRAMS install-strip installcheck \ + installcheck-am installdirs installdirs-am maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-recursive uninstall uninstall-am \ - uninstall-binPROGRAMS uninstall-man uninstall-man1 + tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ + uninstall-htmlDATA uninstall-libexecPROGRAMS uninstall-man \ + uninstall-man1 uninstall-man8 uninstall-sbinPROGRAMS + +.PRECIOUS: Makefile + +install-data-local: install-html FRC: + @: do-nothing action to prevent default SCCS get + @: FRC "force" depends on nothing and is not a file, so is + @: always out-of-date causing targets which depend on it to + @: similarly always be outdated causing their rules to fire + @: each time they or a dependent is built. + +$(PROGRAMS): version.o + +version.c: $(sntp_OBJECTS) ../libntp/libntp.a Makefile $(srcdir)/scm-rev + env CSET=`cat $(srcdir)/scm-rev` $(top_builddir)/../scripts/build/mkver sntp + +version.o: version.c + env CCACHE_DISABLE=1 $(COMPILE) -c version.c -o version.o + check-autogen-version.def: FRC @cd $(srcdir) \ && test -r ../include/autogen-version.def \ @@ -948,35 +1519,192 @@ check-autogen-version.def: FRC echo "Installing new sntp/autogen-version.def file"; \ fi ) -check-version.def: FRC - @cd $(srcdir) \ - && test -r ../include/version.def \ - && ( if cmp -s ../include/version.def version.def; \ - then : ; \ - else cp ../include/version.def version.def; \ - echo "Installing new sntp/version.def file"; \ - fi ) +$(srcdir)/autogen-version.def: + $(MAKE) $(AM_MAKEFLAGS) check-autogen-version.def + +built-sources-only: $(BUILT_SOURCES) + @: do-nothing action to avoid default SCCS get + +check-scm-rev: $(srcdir)/scm-rev + @: do-nothing + +$(srcdir)/scm-rev: + -test -r $(srcdir)/../SCCS/s.ChangeSet && \ + (bk version) >/dev/null 2>&1 && \ + cd $(srcdir)/.. && \ + x=`bk -R prs -hr+ -nd:I: ChangeSet` && \ + y=`cat sntp/scm-rev 2>/dev/null` || true && \ + case "$$x" in ''|$$y) ;; *) echo $$x > sntp/scm-rev ;; esac + +$(srcdir)/m4/version.m4: $(srcdir)/../packageinfo.sh + TEMPDIR=`pwd` && export TEMPDIR && cd $(srcdir) && \ + ../scripts/build/genver m4/version.m4 + +$(srcdir)/include/version.def: $(srcdir)/../packageinfo.sh + TEMPDIR=`pwd` && export TEMPDIR && cd $(srcdir) && \ + ../scripts/build/genver include/version.def + +$(srcdir)/include/version.texi: $(srcdir)/../packageinfo.sh + TEMPDIR=`pwd` && export TEMPDIR && cd $(srcdir) && \ + ../scripts/build/genver include/version.texi + +$(srcdir)/../COPYRIGHT: + cd .. && $(MAKE) $(AM_MAKEFLAGS) COPYRIGHT-please + +check-COPYRIGHT-submake: $(srcdir)/../COPYRIGHT + @cmp -s $(srcdir)/../COPYRIGHT $(srcdir)/COPYRIGHT \ + || { cp $(srcdir)/../COPYRIGHT $(srcdir) \ + && echo 'updated sntp/COPYRIGHT installed' ;} + @echo 'submake avoided if this file is newer than parent COPYRIGHT' > $@ + +check-COPYRIGHT: FRC + [ ! -r $(srcdir)/../COPYRIGHT ] \ + || [ check-COPYRIGHT-submake -nt $(srcdir)/../COPYRIGHT ] \ + || $(MAKE) $(AM_MAKEFLAGS) check-COPYRIGHT-submake + +$(srcdir)/COPYRIGHT: check-COPYRIGHT + @: do-nothing action to prevent any default $(srcdir)/sntp-opts.h: $(srcdir)/sntp-opts.c -$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(srcdir)/version.def + @: do-nothing action to avoid default SCCS get, .h built with .c + +$(srcdir)/sntp-opts.c: $(srcdir)/sntp-opts.def $(std_def_list) $(run_ag) sntp-opts.def -$(srcdir)/sntp.1: $(srcdir)/sntp-opts.def $(srcdir)/version.def - $(run_ag) -Tagman1.tpl -bsntp sntp-opts.def +### + +$(srcdir)/sntp.1sntpman: $(srcdir)/sntp-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1sntpman -Tagman-cmd.tpl sntp-opts.def + +$(srcdir)/sntp.man.in: $(srcdir)/sntp.1sntpman $(srcdir)/scripts/mansec2subst.sed + sed -f $(srcdir)/scripts/mansec2subst.sed $(srcdir)/sntp.1sntpman > $(srcdir)/sntp.man.in+ + mv $(srcdir)/sntp.man.in+ $(srcdir)/sntp.man.in + +### + +$(srcdir)/sntp.1sntpmdoc: $(srcdir)/sntp-opts.def $(std_def_list) + $(run_ag) -DMAN_SECTION=1sntpmdoc -Tagmdoc-cmd.tpl sntp-opts.def + +$(srcdir)/sntp.mdoc.in: $(srcdir)/sntp.1sntpmdoc $(srcdir)/scripts/mansec2subst.sed + sed -f $(srcdir)/scripts/mansec2subst.sed $(srcdir)/sntp.1sntpmdoc > $(srcdir)/sntp.mdoc.in+ + mv $(srcdir)/sntp.mdoc.in+ $(srcdir)/sntp.mdoc.in + +### + +sntp.$(SNTP_MS): $(srcdir)/sntp.$(MANTAGFMT).in $(top_builddir)/config.status + $(top_builddir)/config.status --file=sntp.$(SNTP_MS)+:$(srcdir)/sntp.$(MANTAGFMT).in + mv sntp.$(SNTP_MS)+ sntp.$(SNTP_MS) + +### + +$(srcdir)/invoke-sntp.menu: $(srcdir)/invoke-sntp.texi + @: do-nothing action to avoid default SCCS get, .menu built with .texi + +$(srcdir)/invoke-sntp.texi: $(srcdir)/sntp-opts.def $(std_def_list) + $(run_ag) -Tagtexi-cmd.tpl -DLEVEL=section sntp-opts.def + $(top_srcdir)/../scripts/build/check--help $@ + +$(srcdir)/sntp.html: $(srcdir)/invoke-sntp.menu $(srcdir)/invoke-sntp.texi $(srcdir)/sntp.texi $(srcdir)/include/version.texi + cd $(srcdir) && ( makeinfo --force --html --no-split -o sntp.html sntp.texi || true ) -$(srcdir)/sntp-opts.texi $(srcdir)/sntp-opts.menu: $(srcdir)/sntp-opts.def $(srcdir)/version.def - $(run_ag) -Taginfo.tpl -DLEVEL=section sntp-opts.def +libtool: $(LIBTOOL_DEPS) + ./config.status --recheck + +# HMS: libevent/ is a target if it's in EXTRA_DIST via NTP_FORCE_LIBEVENT_DIST. +# Note that libevent/ is already in DIST_SUBDIRS (implicit in Makefile.am +# but explicit in Makefile.in). This check doesn't help with distclean. +libevent: distdir-pre-check + +# HMS: Stops the build for gmake or pmake +distdir-pre-check: + case "$(DIST_FAIL)" in \ + '') ;; \ + *) $(error re-run configure adding $(DIST_FAIL) if you want to make a distribution.); \ + echo "re-run configure adding $(DIST_FAIL) if you want to make a distribution."; \ + exit 1 ;; \ + esac install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ - || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ - test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ + done + +# +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a + +check-libopts: libopts/libopts.la + @echo stamp > $@ + +libopts/libopts.la: + -cd libopts && $(MAKE) $(AM_MAKEFLAGS) libopts.la +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. # # Tell versions [3.59,3.63) of GNU make to not export all variables. diff --git a/contrib/ntp/sntp/README b/contrib/ntp/sntp/README deleted file mode 100644 index d7738e93a..000000000 --- a/contrib/ntp/sntp/README +++ /dev/null @@ -1,536 +0,0 @@ -SNTP (Simple Network Time Protocol Utility) - Version 1.6 ----------------------------------------------------------- - -Please read the file Copyright first. Also note that the file RFC2030.TXT is -David Mills's copyright and not the author's - it is just a copy of the RFC -that is available from so many Internet archives. - -RFC 1305 (Network Time Protocol - NTP) is an attempt to provide globally -consistent timestamps in an extremely hostile environment; it is fiendishly -complicated and an impressive piece of virtuosity. RFC 2030 (Simple Network -Time Protocol - SNTP) which supersedes RFC 1769 describes a subset of this that -will give excellent accuracy in most environments encountered in practice; it -uses only the obvious algorithms that have been used since time immemorial. - -WARNING: the text version of RFC 1305 is incomplete, and omits the tables that -are in the Postscript version. Unfortunately, these contain the only copy of -some critical information. - -draft-mills-sntp-v4-00.txt is the next proposed revision of RFC 2030, -and the current goal is to have this code implement that specification. - -SNTP Servers - Some Little-Known Facts --------------------------------------- - -RFC 2030 states that SNTP clients should be used only at the lowest level, -which is good practice. It then states that SNTP servers should be used only -at stratum 1 (i.e. top level), which is bizarre! A far saner use of them would -be for the very lowest level of server, exporting solely to local clients that -do not themselves act as servers to ANY system (e.g. on a Netware server, -exporting only to the PCs that it manages). - -[There is missing language in the previous paragraph. SNTP is designed -to be used in 2 cases: as a client at the lowest levels of the timing -hierarchy, or as a server of last resort at stratum 1 when connected to -a modem or radio clock.] - -[This is as far as I have updated this file as part of the upgrade.] - -If the NTP network were being run as a directed acyclic graph (i.e. using SNTP -rather than full NTP), with a diameter of D links and a maximum error per link -of E, the maximum synchronisation error would be D*E. Reasonable figures for D -and E are 5 and 0.1 seconds, so this would be adequate for most uses. Note -that the fact that the graph is acyclic is critical, which is one reason why -SNTP client/servers must NEVER be embedded WITHIN an NTP network. - -The other reason is that inserting SNTP client/servers at a low stratum (but -not the root) of an NTP network could easily break NTP! See RFC 1305 for why, -but don't expect the answer to stand out at you. It would be easy to extend -SNTP to a full-function client/server application, thus making it into a true -alternative to ntp, but this incompatibility is why it MUST NOT be done. - -The above does not mean that the SNTP approach is unsatisfactory, but only that -it is incompatible with full NTP. The author would favour a complete SNTP -network using the SNTP approach, and the statistical error reduction used in -SNTP, but it actually addresses a slightly different problem from that -addressed by NTP. TANSTAAFL. - -FINAL WARNING: do NOT use this program to serve NTP requests from outside the -systems that you manage. If you do this, and manage to break the time -synchronisation on other people's systems, you will be regarded very -unfavourably. Actually, this should be possible only if their NTP client is -completely broken, because SNTP does its damnedest to declare its packets as -the lowest form of NTP timestamp. - - - -SNTP and its Assumptions -------------------------- - -SNTP is intended to be a straightforward SNTP daemon/utility that is easy to -build on any reasonable Unix platform (and most near-Unix ones), whether or not -it has ever been ported to them before. It is intended to answer the following -requirements, either by challenge and response or the less reliable broadcast -method: - - A simple command to run on Unix systems that will check the time - and optionally drift compared with a known, local and reliable NTP - time server. No privilege is required just to read the time and - estimate the drift. - - A client for Unix systems that will synchronise the time from a known, - local and reliable NTP time server. This is probably the most common - one, and the need that caused the program to be written. - - A server for Unix systems that are synchronised other than by NTP - methods and that need to synchronise other systems by NTP. This is - the classroom of PCs with a central server scenario. It is NOT - intended to work as a peer with true NTP servers, and won't. - - A simple method by which two or more Unix systems can keep themselves - synchronised using what is becoming a standard protocol. Yes, I know - that there are half-a-dozen other such methods. - - A base for building non-Unix SNTP clients. Some 3/4 of the code - (including all of the complicated algorithms and NTP packet handling) - should work, unchanged, on any system with an ANSI/ISO C compiler. - -There are full tracing facilities and a lot of paranoia in the code to check -for bad packets (more than in ntp) which may need relaxing in the light of -experience. Unfortunately, RFC 1305 does not include a precise description of -the data protocol, despite its length, and there are some internal -inconsistencies and differences between it and RFC 2030 and ntp's behaviour. - -WARNING: SNTP has not been tested in conjunction with ntp broadcasts or ntp -clients, as the ability to do so was not available to the author. It is very -unlikely that it won't work, but you should check. Much of the paranoid code -is only partially tested, too, because it is dealing with cases that are very -hard to provoke. - -It assumes that the local network is tolerably secure and that any accessible -NTP or SNTP servers are trustworthy. It also makes no attempt to check that -it has been installed and is being used correctly (e.g. at an appropriate -priority) or that the changes it makes have the desired effect. When you first -use it, you should both run it in display mode and use the date command as a -cross-check. - -Furthermore, it does not attempt to solve all of the problems addressed by the -NTP protocol and you should NOT use it if any of those problems are likely to -cause you serious trouble. If they are, bite the bullet and implement ntp, or -buy a fancy time-server. - - -Building SNTP -------------- - -The contents of the distribution are: - -README - this file -Copyright - the copyright notice and conditions of use -Makefile - the makefile, with comments for several systems -header.h - the main header (almost entirely portable) -kludges.h - dirty kludges for difficult systems -internet.h - a very small header for internet.c and socket.c -main.c - most of the source (almost entirely portable) -unix.c - just for isatty, sleep and locking -internet.c - Internet host and service name lookup -socket.c - the Berkeley socket code -sntp.1 - the man page -RFC2030.TXT - the SNTPv4 specification - -All you SHOULD need to do is to uncomment the settings in file Makefile for -your system or to add new ones. But real life is not always so simple. As -POSIX does not yet define sub-second timers, Internet addressing facilities, -sockets etc., the code has to rely on the facilities described in the -ill-defined and non-standard 'X/Open' documents and the almost totally -unspecified 'BSD' extensions. - -Most hacks should be limited to the compiler options (e.g. setting flags like -_XOPEN_SOURCE), but perverse systems may need additions to kludges.h - please -report them to the author. See Makefile and kludges.h for documentation on -the standard hacks - there only 6, and most are only for obsolete systems. -But, generally, using the generic set of C options usually works with no -further ado. - - -Sick, Bizarre or non-Unix Systems ---------------------------------- - -A very few Unix systems and almost all non-Unix systems may need changes to the -code, such as: - - If the system doesn't have Berkeley sockets, you will need to replace - socket.c and possibly modify internet.h and internet.c. All of the - systems for which the author needs this have Berkeley sockets. - - NTP is supposedly an Internet protocol, but is not Internet specific. - For other types of network, you will need to replace internet.c and - probably modify internet.h. - - If the system doesn't have gettimeofday or settimeofday, you will - need to modify timing.c. If it doesn't have adjtime (e.g. HP-UX - on PA-RISC before 10.0), you can set -DADJTIME_MISSING and the code - will compile but the -a option will always give an error. - - If the system has totally broken signal handling, the program will - hang or crash if it can't reach its name server or responses time - out. You may be able to improve matters by hacking internet.c and - socket.c, but don't bet on it. - - If the the program won't be able to create files in /etc when - updating the clock, you can use another lock file or even set - -DLOCKFILE=NULL, which will disable the locking code entirely. On - systems that have it, using /var/run would be better than /etc. - - If the the program hangs when flushing outstanding packets (which - you can tell by setting -W), it may help to set -DNONBLOCK_BROKEN. - This seems needed only for obsolete systems, like Ultrix. - - If the system isn't Unix, even vaguely, you will probably need to - modify all of the above, and unix.c as well. - - Note that adjtime is commonly sick, but you don't need to change the - code - just use the -r option whan making large corrections (see below - for more details). - -Any changes needed to header.h or main.c are bugs. They may be bugs in the -code or in the compiler or libraries, but they are bugs. Please prod the -people responsible and tell the author, who may be able to bypass them cleanly -even if they aren't bugs in his code. The code also makes the following -assumptions, which would be quite hard to remove: - - 8-bit bytes. Strictly, neither ANSI/ISO C nor POSIX require these, - and there were some very early versions of Unix on systems with other - byte sizes. But, without a defined sub-byte facility in C, .... - - At least 32-bit ints. Well, actually, this wouldn't be too hard to - remove. But most Unix programs make this assumption, and I have very - little interest in the more rudimentary versions of MS-DOS etc. - - An ANSI/ISO C compiler. It didn't seem worth writing dual-language - code in 1996. Tough luck if you haven't got one. - - Tolerably efficient floating-point arithmetic, with at least 13 digits - (decimal), preferably 15, in the mantissa of doubles. Ditto. If you - want to port this to a toaster, please accept my insincerest sympathies - and don't bother me. - - A trustworthy local network. It does not check for DNS, Ethernet, - packet or other spoofing, and assumes that any accessible NTP or SNTP - servers are properly synchronised. - - -Warnings about Installation and Use ------------------------------------ - -Anyone attempting to fiddle with the clock on their system should already know -how to write system administration scripts, install daemons and so on. There -are a few warnings: - - Don't use the broadcast modes unless you really have to, as the - client-server modes are far more reliable. The broadcast modes were - implemented more for virtuosity (a.k.a. SNTP conformance) than use. - In particular, the error estimates are mere guesses, and may be low - or even very low. And even reading broadcasts needs privilege. - - The program is not intended to be installed setuid or setgid, and - doing so is asking for trouble. Its ownerships and access modes are - not important. It need not be run by root for merely displaying the - time (even in daemon mode). - - The program does not need to run at a high priority (low in Unix - terms!) even when being used to set the clock or as a server, except - when the '-r' option is used. However, doing so may improve its - accuracy. - - Unlike NTP, the SNTP protocol contains no protection against - client-server loops. If you set one up, your systems will spin - themselves off into a disconnected vortex of unreality! - - It will get very confused if another process changes the local time - while it is running. There is some locking code in unix.c to prevent - this program doing this to itself, but it will protect only against - some errors. However, the remaining failures should be harmless. - - Don't run it as a server unless you REALLY know what you are doing. - It should be used as a server only on a system that is properly - synchronised, by fair means or foul. If it isn't, you will simply - perpetrate misinformation. And remember that broadcasts are most - unpopular with overloaded administrators of overloaded networks. - - Watch out for multi-server broadcasts and systems with multiple ports - onto the same Ethernet; there is some code to protect against this, - but it is still easy to get confused. - - Don't put the lock file onto an automounted partition or delete it by - hand, unless you really want to start two daemons at the same time. - Both will probably fail horribly if you do this. - - The daemon save file is checked fairly carefully, but should be in a - reasonably safe directory, unless you want hackers to cause trouble. - /tmp is safe enough on most systems, but not all - /etc is better. - - -Installing and Using the Program --------------------------------- - -Start by copying the executable and man page to where you want them. If you -want only to display the time and as a replacement for the rdate or date -commands, the installation is finished! - -You can use it as a simple unprivileged command to check the time, quite -independently of whether it is running as a time-updating daemon or server, or -whether you are running ntp. You can run it in daemon mode without updating -the clock, to check for drift, but it may fail if the clock is changed under -its feet. Unfortunately, you cannot listen to broadcasts without privilege. - -If it is used with the -a option to keep the time synchronised, it is best to -run it as one of root's cron jobs - for many systems, running it once a day -should be adequate, but it will depend on the reliability of the local clock. -The author runs it this way with -a and -x - see below. - -If it is used with the -r option to set the time (instead of the rdate or date -commands), it should be used interactively and either on a lightly loaded -system or at a high priority. You should then check the result by running it -in display mode. - -You are advised NOT to run it with the -r option in a cron job, though this is -not locked out. If you have to (for example under HP-UX before 10.0), be sure -to run it as the highest priority that will not cause other system problems and -set the maximum automatic change to as low a value as you can get away with. - -WARNING: adjtime is more than a bit sick on many systems, and will ignore large -corrections, usually without any form of hint that it has done so. It is often -(even usually) necessary to reset the clock to approximately the right time -using the -r option before using the -a and -x options to keep it correct. - -It can be started as a time-updating daemon with the -a and -x options (or -r -and -x if you must), and will perform some limited drift correction. In this -case, start it from any suitable system initialisation script and leave it -running. Note that it will stop if it thinks that the time difference or drift -has got out of control, and you will need to reset the time and restart it by -hand. - -In daemon mode, it will survive its time server or network disappearing for a -while, but will eventually fail, and will fail immediately if the network call -returns an unexpected error. If this is a problem, you can start it (say, -hourly or nightly) from cron, and it will fail if it is already running -(provided that you haven't disabled or deleted the lock file). - -If it is used as a server, it should be started from any suitable system -initialisation script, just like any other daemon. It must be started after -the networking, of course. To run it in both server modes, start one copy with -the -B option and one with the -S option. - - -Simple Examples of Use ----------------------- - -Many people use it solely to check the time of their system, especially as a -cross-check on ntpd. You do not need privilege and it will not cause trouble -to the local network, so you can use it on someone else's system! You can -specify one server or several. For example: - - msntp ntp.server.local ntp.server.neighbour - -You can use it to check how your system is drifting, but it isn't very good at -this if the system is drifting very badly (in which case use the previous -technique and dc) or if you are running ntp. You do not need privilege and it -will not cause trouble to the local network. For example: - - sntp -x 120 -f /tmp/msntp.state ntp.server.local - -More generally, it is used to synchronise the clock, in which case you DO need -root privilege. It can be used in many ways, but the author favours running it -in daemon mode, started from a cron job, which will restart after power cuts -with no attention, and send a mail message (if cron is configured to do that) -when it fails badly. For example, the author uses a root crontab entry on one -system of: - - 15 0 * * * /bin/nice --10 /usr/local/bin/sntp -a -x 480 ntp.server.local - -If you have a home computer, it can be set up to resynchronise each time you -dial up. For example, the author uses a /etc/ppp/ip-up.d/sntp file on his -home Linux system of: - - #!/bin/sh - sleep 60 - /bin/nice --10 /usr/local/sbin/sntp -r -P 60 ntp.server.local - --a would be better, but adjtime is broken in Linux. - - -Debugging or Hacking the Program --------------------------------- - -Almost everybody who does this is likely to need to modify only the system -interfaces. While they are messy, they are pretty simple and have a simple -specification. This is documented in comments in the source. This is -described above. - -The main program SHOULD need no attention, though it may need the odd tweak to -bypass compiler problems - please report these, if you encounter any. If -something looks odd while it is running, start by setting the -v option (lower -case), as for investigating network problems, and checking any diagnostics that -appear. Note that most of it can be checked in display mode without harming -your system. - -The client will sometimes give up, complaining about inconsistent timestamps or -similar. This can be caused by the server being rebooted and similar glitches -to the time - unfortunately, there is no reliable way to tell an ignorable -fluctuation from a server up the spout. If this happens annoyingly often, -the -V option may help tie down the problem. In actual use, it is simplest -just to restart the client in a cron job! - -If it needs more than this, then you will need to debug the source seriously. -Start by putting an icepack on your head and pouring yourself a large whisky! -While it is commented, it is not well commented, and much of the code interacts -in complex and horrible ways. This isn't so much because it lacks 'structure' -as because one part needs to make assumptions about the numerical properties of -another. - -The -W option (upper case) will print out a complete trace of everything it -does, and this should be enough to tie down the problem. It does distort the -timing a bit, but not usually too badly. However, wading through that amount -of gibberish (let alone looking at the source) is not a pleasant task. If you -are pretty sure that you have a bug, you may tell the author, and he may ask -for a copy of the output - but he will reply rudely if you send thousands of -lines of tracing to him by Email! - -Note that there are a fair number of circumstances where its error recovery -could be better, but is left as it is to keep the code simple. Most of these -should be pretty rare. - - -Changes in Version 1.2 ----------------------- - -The main change was the addition of the daemon mode for drift correction (i.e. -the -x option). The daemon code is complex and has a lot of special-casing for -strange circumstances, not all of which are testable in practice. - -A lot of the code was reordered while doing this. The output was slightly -different - considerably different with -V. - -The error estimation for broadcasts was modified, and should bear more relation -to reality. It remains a guess, as there is no way to get decent error error -estimates under such circumstances. - -The -B option is now in minutes, and has a different permissible range and -default value. - -The argument consistency checking for broadcasts was tightened up a bit, and a -few other internal checks added. These should not affect any reasonable -requirement. - -A couple of new functions were added to the portability base, but they don't -use any non-standard new facilities. However, the specification of the -functions has changed slightly. - - -Changes in Version 1.3 ----------------------- - -The main change was the addition of the restarting facility for daemon mode -(i.e. the -f option), which is pretty straightforward. - -There were also a lot of minor changes to the paranoia code in daemon mode, to -try to separate out the case of a demented server from network and other -'ignorable' problems. These are not entirely successful. - - -Changes in Version 1.4 and 1.5 ------------------------------- - -There turned out to be a couple of places where the author misunderstood the -specification of NTP, which affect only its use in server mode. The main -change is to use stratum 15 instead of stratum 0. - -And there were some more relaxations of the paranoia code, to allow for more -erratic servers, plus a kludge to improve restarting in daemon mode after a -period of down time has unsynchronised the clock. There is also an -incompatible change to the debugging options to add a new level - the old -V -option is now -W, and -V is an intermediate one for debugging daemon mode - but -they are both hacker's facilities, and not for normal use. - -Version 1.5 adds some very minor fixes. - - -Changes in Version 1.6 ----------------------- - -The first change is support for multiple server addresses - it uses these in a -round-robin fashion. This may be useful when you have access to several -servers, all of which are a bit iffy. This means that the restart file format -is incompatible with msntp 1.5. - -It has also been modified to reset itself automatically after detecting an -inconsistency in its server's timestamps, because the author got sick of the -failures. It writes a comment to syslog (uniquely) in such cases. - -The ability to query a daemon save file was added. - -Related to the above, the -E argument has been redefined to mean an error bound -on various internal times (which is what it had become, anyway) and a -P option -introduced to be what the -E argument was documented to be. - -The lock and save file handling have been changed to allow defaults to be set -at installation time, and to be overridable at run-time. To disable these -at either stage, simply set the file names to the null string. - -And there have been the usual changes for portability, as standards have been -modified and/or introduced. - - -Future Versions ---------------- - -There are unlikely to be any, except probably one to fix bugs in version 1.6. - -I attempted to put support for intermittent connexions (e.g. dial-up) into the -daemon mode, but doing so needs so much code reorganisation that it isn't worth -it. What needs doing for that is to separate the socket handling from the -timekeeping, so that they can be run asynchronously (either in separate -processes or threads), and to look up a network name and open a socket only -when prodded (and to close it immediately thereafter). So just running it -with the -r option is the current best solution. - -I also attempted to put support for the "Unix 2000" interfaces into the code. -Ha, ha. Not merely do very few systems define socklen_t (needed for IPv6 -support), but "Unix 2000" neither addresses the leap second problem nor even -provides an adjtime replacement! Some function like the latter is critical, -not so much because of the gradual change, but because of its atomicity; -without it, msntp really needs to be made non-interruptible, and that brings in -a ghastly number of system-dependencies. - -Realistically, it needs a complete rewrite before adding any more function. -And, worse, the Unix 'standards' need fixing, too. - - - -Miscellaneous -------------- - -Thanks are due to Douglas M. Wells of Connection Technologies for helping the -author with several IP-related conventions, to Sam Nelson of Stirling -University for testing it on some very strange systems, and to David Mills for -clarifying what the NTP specification really is. - -Thanks are also due to several other people with locating bugs, finding -appropriate options for the Makefile and passing on extension code and -suggestions. As I am sure to leave someone out, I shall not name anyone else. - -Version 1.0 - October 1996. -Version 1.1 - November 1996 - mainly portability improvements. -Version 1.2 - January 1997 - mainly drift handling, but much reorganisation. -Version 1.3 - February 1997 - daemon save file, and some robustness changes. -Version 1.4 - May 1997 - relatively minor fixes, more diagnostic levels etc. -Version 1.5 - December 1997 - some very minor fixes -Version 1.6 - October 2000 - quite a few miscellaneous changes - - -Nick Maclaren, -University of Cambridge Computer Laboratory, -New Museums Site, Pembroke Street, Cambridge CB2 3QG, England. -Email: nmm1@cam.ac.uk -Tel.: +44 1223 334761 Fax: +44 1223 334679 diff --git a/contrib/ntp/sntp/aclocal.m4 b/contrib/ntp/sntp/aclocal.m4 index 1994696b4..00ce90896 100644 --- a/contrib/ntp/sntp/aclocal.m4 +++ b/contrib/ntp/sntp/aclocal.m4 @@ -1,6189 +1,145 @@ -# generated automatically by aclocal 1.11 -*- Autoconf -*- +# generated automatically by aclocal 1.15 -*- Autoconf -*- -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],, -[m4_warning([this file was generated for autoconf 2.65. -You have another version of autoconf. It may work, but is not guaranteed to. -If you have problems, you may need to regenerate the build system entirely. -To do so, use the procedure documented by the package, typically `autoreconf'.])]) - -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- - -# serial 47 AC_PROG_LIBTOOL - - -# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) -# ----------------------------------------------------------- -# If this macro is not defined by Autoconf, define it here. -m4_ifdef([AC_PROVIDE_IFELSE], - [], - [m4_define([AC_PROVIDE_IFELSE], - [m4_ifdef([AC_PROVIDE_$1], - [$2], [$3])])]) - - -# AC_PROG_LIBTOOL -# --------------- -AC_DEFUN([AC_PROG_LIBTOOL], -[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl -dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX -dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. - AC_PROVIDE_IFELSE([AC_PROG_CXX], - [AC_LIBTOOL_CXX], - [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX - ])]) -dnl And a similar setup for Fortran 77 support - AC_PROVIDE_IFELSE([AC_PROG_F77], - [AC_LIBTOOL_F77], - [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 -])]) - -dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. -dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run -dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. - AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [ifdef([AC_PROG_GCJ], - [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([A][M_PROG_GCJ], - [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([LT_AC_PROG_GCJ], - [define([LT_AC_PROG_GCJ], - defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) -])])# AC_PROG_LIBTOOL - - -# _AC_PROG_LIBTOOL -# ---------------- -AC_DEFUN([_AC_PROG_LIBTOOL], -[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl -AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl -AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl -AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl - -# Prevent multiple expansion -define([AC_PROG_LIBTOOL], []) -])# _AC_PROG_LIBTOOL - - -# AC_LIBTOOL_SETUP -# ---------------- -AC_DEFUN([AC_LIBTOOL_SETUP], -[AC_PREREQ(2.50)dnl -AC_REQUIRE([AC_ENABLE_SHARED])dnl -AC_REQUIRE([AC_ENABLE_STATIC])dnl -AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_PROG_LD])dnl -AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl -AC_REQUIRE([AC_PROG_NM])dnl - -AC_REQUIRE([AC_PROG_LN_S])dnl -AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl -# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! -AC_REQUIRE([AC_OBJEXT])dnl -AC_REQUIRE([AC_EXEEXT])dnl -dnl - -AC_LIBTOOL_SYS_MAX_CMD_LEN -AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -AC_LIBTOOL_OBJDIR - -AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -_LT_AC_PROG_ECHO_BACKSLASH - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e 1s/^X//' -[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] - -# Same as above, but do not quote variable references. -[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -# Constants: -rm="rm -f" - -# Global variables: -default_ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a -ltmain="$ac_aux_dir/ltmain.sh" -ofile="$default_ofile" -with_gnu_ld="$lt_cv_prog_gnu_ld" - -AC_CHECK_TOOL(AR, ar, false) -AC_CHECK_TOOL(RANLIB, ranlib, :) -AC_CHECK_TOOL(STRIP, strip, :) - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru -test -z "$AS" && AS=as -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$LD" && LD=ld -test -z "$LN_S" && LN_S="ln -s" -test -z "$MAGIC_CMD" && MAGIC_CMD=file -test -z "$NM" && NM=nm -test -z "$SED" && SED=sed -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$RANLIB" && RANLIB=: -test -z "$STRIP" && STRIP=: -test -z "$ac_objext" && ac_objext=o - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" - ;; - *) - old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" -fi - -_LT_CC_BASENAME([$compiler]) - -# Only perform the check for file, if the check method requires it -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - AC_PATH_MAGIC - fi - ;; -esac - -AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) -AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], -enable_win32_dll=yes, enable_win32_dll=no) - -AC_ARG_ENABLE([libtool-lock], - [AC_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -AC_ARG_WITH([pic], - [AC_HELP_STRING([--with-pic], - [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], - [pic_mode="$withval"], - [pic_mode=default]) -test -z "$pic_mode" && pic_mode=default - -# Use C for the default configuration in the libtool script -tagname= -AC_LIBTOOL_LANG_C_CONFIG -_LT_AC_TAGCONFIG -])# AC_LIBTOOL_SETUP - - -# _LT_AC_SYS_COMPILER -# ------------------- -AC_DEFUN([_LT_AC_SYS_COMPILER], -[AC_REQUIRE([AC_PROG_CC])dnl - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_AC_SYS_COMPILER - - -# _LT_CC_BASENAME(CC) -# ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -AC_DEFUN([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -]) - - -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -AC_DEFUN([_LT_COMPILER_BOILERPLATE], -[ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* -])# _LT_COMPILER_BOILERPLATE - - -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -AC_DEFUN([_LT_LINKER_BOILERPLATE], -[ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* -])# _LT_LINKER_BOILERPLATE - - -# _LT_AC_SYS_LIBPATH_AIX -# ---------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], -[AC_LINK_IFELSE(AC_LANG_PROGRAM,[ -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi],[]) -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -])# _LT_AC_SYS_LIBPATH_AIX - - -# _LT_AC_SHELL_INIT(ARG) -# ---------------------- -AC_DEFUN([_LT_AC_SHELL_INIT], -[ifdef([AC_DIVERSION_NOTICE], - [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], - [AC_DIVERT_PUSH(NOTICE)]) -$1 -AC_DIVERT_POP -])# _LT_AC_SHELL_INIT - - -# _LT_AC_PROG_ECHO_BACKSLASH -# -------------------------- -# Add some code to the start of the generated configure script which -# will find an echo command which doesn't interpret backslashes. -AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], -[_LT_AC_SHELL_INIT([ -# Check that we are running under the correct shell. -SHELL=${CONFIG_SHELL-/bin/sh} - -case X$ECHO in -X*--fallback-echo) - # Remove one level of quotation (which was required for Make). - ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` - ;; -esac - -echo=${ECHO-echo} -if test "X[$]1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X[$]1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then - # Yippee, $echo works! - : -else - # Restart under the correct shell. - exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} -fi - -if test "X[$]1" = X--fallback-echo; then - # used as fallback echo - shift - cat </dev/null 2>&1 && unset CDPATH - -if test -z "$ECHO"; then -if test "X${echo_test_string+set}" != Xset; then -# find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if (echo_test_string=`eval $cmd`) 2>/dev/null && - echo_test_string=`eval $cmd` && - (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null - then - break - fi - done -fi - -if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : -else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. - - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for dir in $PATH /usr/ucb; do - IFS="$lt_save_ifs" - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$dir/echo" - break - fi - done - IFS="$lt_save_ifs" - - if test "X$echo" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - echo='print -r' - elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running configure again with it. - ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} - else - # Try using printf. - echo='printf %s\n' - if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # Cool, printf works - : - elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - echo="$CONFIG_SHELL [$]0 --fallback-echo" - elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$CONFIG_SHELL [$]0 --fallback-echo" - else - # maybe with a smaller string... - prev=: - - for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do - if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null - then - break - fi - prev="$cmd" - done - - if test "$prev" != 'sed 50q "[$]0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} - else - # Oops. We lost completely, so just stick with echo. - echo=echo - fi - fi - fi - fi -fi -fi - -# Copy echo and quote the copy suitably for passing to libtool from -# the Makefile, instead of quoting the original, which is used later. -ECHO=$echo -if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then - ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" -fi - -AC_SUBST(ECHO) -])])# _LT_AC_PROG_ECHO_BACKSLASH - - -# _LT_AC_LOCK -# ----------- -AC_DEFUN([_LT_AC_LOCK], -[AC_ARG_ENABLE([libtool-lock], - [AC_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '[#]line __oline__ "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], -[*-*-cygwin* | *-*-mingw* | *-*-pw32*) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; - ]) -esac - -need_locks="$enable_libtool_lock" - -])# _LT_AC_LOCK - - -# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], -[AC_REQUIRE([LT_AC_PROG_SED]) -AC_CACHE_CHECK([$1], [$2], - [$2=no - ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $rm conftest* -]) - -if test x"[$]$2" = xyes; then - ifelse([$5], , :, [$5]) -else - ifelse([$6], , :, [$6]) -fi -])# AC_LIBTOOL_COMPILER_OPTION - - -# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ------------------------------------------------------------ -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], -[AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $3" - printf "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $rm conftest* - LDFLAGS="$save_LDFLAGS" -]) - -if test x"[$]$2" = xyes; then - ifelse([$4], , :, [$4]) -else - ifelse([$5], , :, [$5]) -fi -])# AC_LIBTOOL_LINKER_OPTION - - -# AC_LIBTOOL_SYS_MAX_CMD_LEN -# -------------------------- -AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], -[# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - *) - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ - = "XX$teststring") >/dev/null 2>&1 && - new_result=`expr "X$teststring" : ".*" 2>&1` && - lt_cv_sys_max_cmd_len=$new_result && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - teststring= - # Add a significant safety factor because C++ compilers can tack on massive - # amounts of additional arguments before passing them to the linker. - # It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - ;; - esac -]) -if test -n $lt_cv_sys_max_cmd_len ; then - AC_MSG_RESULT($lt_cv_sys_max_cmd_len) -else - AC_MSG_RESULT(none) -fi -])# AC_LIBTOOL_SYS_MAX_CMD_LEN - - -# _LT_AC_CHECK_DLFCN -# -------------------- -AC_DEFUN([_LT_AC_CHECK_DLFCN], -[AC_CHECK_HEADERS(dlfcn.h)dnl -])# _LT_AC_CHECK_DLFCN - - -# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, -# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) -# ------------------------------------------------------------------ -AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], -[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl -if test "$cross_compiling" = yes; then : - [$4] -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -#ifdef __cplusplus -extern "C" void exit (int); -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - - exit (status); -}] -EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_unknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi -fi -rm -fr conftest* -])# _LT_AC_TRY_DLOPEN_SELF - - -# AC_LIBTOOL_DLOPEN_SELF -# ------------------- -AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], -[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ]) - ;; - - *) - AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], - [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"], - [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], - [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], - [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], - [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"]) - ]) - ]) - ]) - ]) - ]) - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - AC_CACHE_CHECK([whether a program can dlopen itself], - lt_cv_dlopen_self, [dnl - _LT_AC_TRY_DLOPEN_SELF( - lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, - lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) - ]) - - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_AC_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi -])# AC_LIBTOOL_DLOPEN_SELF - - -# AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) -# --------------------------------- -# Check to see if options -c and -o are simultaneously supported by compiler -AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], -[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . 2>&AS_MESSAGE_LOG_FD - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* -]) -])# AC_LIBTOOL_PROG_CC_C_O - - -# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) -# ----------------------------------------- -# Check to see if we can do hard links to lock some files if needed -AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], -[AC_REQUIRE([_LT_AC_LOCK])dnl - -hard_links="nottested" -if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - AC_MSG_CHECKING([if we can lock with hard links]) - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) - need_locks=warn - fi -else - need_locks=no -fi -])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS - - -# AC_LIBTOOL_OBJDIR -# ----------------- -AC_DEFUN([AC_LIBTOOL_OBJDIR], -[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], -[rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null]) -objdir=$lt_cv_objdir -])# AC_LIBTOOL_OBJDIR - - -# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) -# ---------------------------------------------- -# Check hardcoding attributes. -AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], -[AC_MSG_CHECKING([how to hardcode library paths into programs]) -_LT_AC_TAGVAR(hardcode_action, $1)= -if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ - test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \ - test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then - - # We can hardcode non-existant directories. - if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then - # Linking always hardcodes the temporary library directory. - _LT_AC_TAGVAR(hardcode_action, $1)=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - _LT_AC_TAGVAR(hardcode_action, $1)=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - _LT_AC_TAGVAR(hardcode_action, $1)=unsupported -fi -AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) - -if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi -])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH - - -# AC_LIBTOOL_SYS_LIB_STRIP -# ------------------------ -AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], -[striplib= -old_striplib= -AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) -fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac -fi -])# AC_LIBTOOL_SYS_LIB_STRIP - - -# AC_LIBTOOL_SYS_DYNAMIC_LINKER -# ----------------------------- -# PORTME Fill in your ld.so characteristics -AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], -[AC_MSG_CHECKING([dynamic linker characteristics]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[[45]]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; - - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd1*) - dynamic_linker=no - ;; - -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[[123]]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[[01]]* | freebsdelf3.[[01]]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - esac - ;; - -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; - -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no -])# AC_LIBTOOL_SYS_DYNAMIC_LINKER - - -# _LT_AC_TAGCONFIG -# ---------------- -AC_DEFUN([_LT_AC_TAGCONFIG], -[AC_ARG_WITH([tags], - [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], - [include additional configurations @<:@automatic@:>@])], - [tagnames="$withval"]) - -if test -f "$ltmain" && test -n "$tagnames"; then - if test ! -f "${ofile}"; then - AC_MSG_WARN([output file `$ofile' does not exist]) - fi - - if test -z "$LTCC"; then - eval "`$SHELL ${ofile} --config | grep '^LTCC='`" - if test -z "$LTCC"; then - AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) - else - AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) - fi - fi - - # Extract list of available tagged configurations in $ofile. - # Note that this assumes the entire list is on one line. - available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` - - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for tagname in $tagnames; do - IFS="$lt_save_ifs" - # Check whether tagname contains only valid characters - case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in - "") ;; - *) AC_MSG_ERROR([invalid tag name: $tagname]) - ;; - esac - - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null - then - AC_MSG_ERROR([tag name \"$tagname\" already exists]) - fi - - # Update the list of available tags. - if test -n "$tagname"; then - echo appending configuration tag \"$tagname\" to $ofile - - case $tagname in - CXX) - if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_LIBTOOL_LANG_CXX_CONFIG - else - tagname="" - fi - ;; - - F77) - if test -n "$F77" && test "X$F77" != "Xno"; then - AC_LIBTOOL_LANG_F77_CONFIG - else - tagname="" - fi - ;; - - GCJ) - if test -n "$GCJ" && test "X$GCJ" != "Xno"; then - AC_LIBTOOL_LANG_GCJ_CONFIG - else - tagname="" - fi - ;; - - RC) - AC_LIBTOOL_LANG_RC_CONFIG - ;; - - *) - AC_MSG_ERROR([Unsupported tag name: $tagname]) - ;; - esac - - # Append the new tag name to the list of available tags. - if test -n "$tagname" ; then - available_tags="$available_tags $tagname" - fi - fi - done - IFS="$lt_save_ifs" - - # Now substitute the updated list of available tags. - if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then - mv "${ofile}T" "$ofile" - chmod +x "$ofile" - else - rm -f "${ofile}T" - AC_MSG_ERROR([unable to update list of available tagged configurations.]) - fi -fi -])# _LT_AC_TAGCONFIG - - -# AC_LIBTOOL_DLOPEN -# ----------------- -# enable checks for dlopen support -AC_DEFUN([AC_LIBTOOL_DLOPEN], - [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) -])# AC_LIBTOOL_DLOPEN - - -# AC_LIBTOOL_WIN32_DLL -# -------------------- -# declare package support for building win32 DLLs -AC_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) -])# AC_LIBTOOL_WIN32_DLL - - -# AC_ENABLE_SHARED([DEFAULT]) -# --------------------------- -# implement the --enable-shared flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_SHARED], -[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([shared], - [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_shared=]AC_ENABLE_SHARED_DEFAULT) -])# AC_ENABLE_SHARED - - -# AC_DISABLE_SHARED -# ----------------- -#- set the default shared flag to --disable-shared -AC_DEFUN([AC_DISABLE_SHARED], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_SHARED(no) -])# AC_DISABLE_SHARED - - -# AC_ENABLE_STATIC([DEFAULT]) -# --------------------------- -# implement the --enable-static flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_STATIC], -[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([static], - [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@], - [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_static=]AC_ENABLE_STATIC_DEFAULT) -])# AC_ENABLE_STATIC - - -# AC_DISABLE_STATIC -# ----------------- -# set the default static flag to --disable-static -AC_DEFUN([AC_DISABLE_STATIC], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_STATIC(no) -])# AC_DISABLE_STATIC - - -# AC_ENABLE_FAST_INSTALL([DEFAULT]) -# --------------------------------- -# implement the --enable-fast-install flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_FAST_INSTALL], -[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([fast-install], - [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], - [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) -])# AC_ENABLE_FAST_INSTALL - - -# AC_DISABLE_FAST_INSTALL -# ----------------------- -# set the default to --disable-fast-install -AC_DEFUN([AC_DISABLE_FAST_INSTALL], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_FAST_INSTALL(no) -])# AC_DISABLE_FAST_INSTALL - - -# AC_LIBTOOL_PICMODE([MODE]) -# -------------------------- -# implement the --with-pic flag -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. -AC_DEFUN([AC_LIBTOOL_PICMODE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -pic_mode=ifelse($#,1,$1,default) -])# AC_LIBTOOL_PICMODE - - -# AC_PROG_EGREP -# ------------- -# This is predefined starting with Autoconf 2.54, so this conditional -# definition can be removed once we require Autoconf 2.54 or later. -m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], -[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], - [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 - then ac_cv_prog_egrep='grep -E' - else ac_cv_prog_egrep='egrep' - fi]) - EGREP=$ac_cv_prog_egrep - AC_SUBST([EGREP]) -])]) - - -# AC_PATH_TOOL_PREFIX -# ------------------- -# find a file program which can recognise shared library -AC_DEFUN([AC_PATH_TOOL_PREFIX], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, -[case $MAGIC_CMD in -[[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR -dnl $ac_dummy forces splitting on constant user-supplied paths. -dnl POSIX.2 word splitting is done only on the output of word expansions, -dnl not every word. This closes a longstanding sh security hole. - ac_dummy="ifelse([$2], , $PATH, [$2])" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - AC_MSG_RESULT($MAGIC_CMD) -else - AC_MSG_RESULT(no) -fi -])# AC_PATH_TOOL_PREFIX - - -# AC_PATH_MAGIC -# ------------- -# find a file program which can recognise a shared library -AC_DEFUN([AC_PATH_MAGIC], -[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi -fi -])# AC_PATH_MAGIC - - -# AC_PROG_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([AC_PROG_LD], -[AC_ARG_WITH([gnu-ld], - [AC_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], - [with_gnu_ld=no]) -AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - AC_MSG_CHECKING([for GNU ld]) -else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &1 /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be Linux ELF. -linux*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -nto-qnx*) - lt_cv_deplibs_check_method=unknown - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -sco3.2v5*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown -])# AC_DEPLIBS_CHECK_METHOD - - -# AC_PROG_NM -# ---------- -# find the pathname to a BSD-compatible name lister -AC_DEFUN([AC_PROG_NM], -[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/${ac_tool_prefix}nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - esac - fi - done - IFS="$lt_save_ifs" - test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm -fi]) -NM="$lt_cv_path_NM" -])# AC_PROG_NM - - -# AC_CHECK_LIBM -# ------------- -# check for math library -AC_DEFUN([AC_CHECK_LIBM], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -LIBM= -case $host in -*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) - # These system don't have libm, or don't need it - ;; -*-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") - AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") - ;; -*) - AC_CHECK_LIB(m, cos, LIBM="-lm") - ;; -esac -])# AC_CHECK_LIBM - - -# AC_LIBLTDL_CONVENIENCE([DIRECTORY]) -# ----------------------------------- -# sets LIBLTDL to the link flags for the libltdl convenience library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-convenience to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, -# it is assumed to be `libltdl'. LIBLTDL will be prefixed with -# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/' -# (note the single quotes!). If your package is not flat and you're not -# using automake, define top_builddir and top_srcdir appropriately in -# the Makefiles. -AC_DEFUN([AC_LIBLTDL_CONVENIENCE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - case $enable_ltdl_convenience in - no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; - "") enable_ltdl_convenience=yes - ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; - esac - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_CONVENIENCE - - -# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) -# ----------------------------------- -# sets LIBLTDL to the link flags for the libltdl installable library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-install to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, -# and an installed libltdl is not found, it is assumed to be `libltdl'. -# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with -# '${top_srcdir}/' (note the single quotes!). If your package is not -# flat and you're not using automake, define top_builddir and top_srcdir -# appropriately in the Makefiles. -# In the future, this macro may have to be called after AC_PROG_LIBTOOL. -AC_DEFUN([AC_LIBLTDL_INSTALLABLE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - AC_CHECK_LIB(ltdl, lt_dlinit, - [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], - [if test x"$enable_ltdl_install" = xno; then - AC_MSG_WARN([libltdl not installed, but installation disabled]) - else - enable_ltdl_install=yes - fi - ]) - if test x"$enable_ltdl_install" = x"yes"; then - ac_configure_args="$ac_configure_args --enable-ltdl-install" - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - else - ac_configure_args="$ac_configure_args --enable-ltdl-install=no" - LIBLTDL="-lltdl" - LTDLINCL= - fi - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_INSTALLABLE - - -# AC_LIBTOOL_CXX -# -------------- -# enable support for C++ libraries -AC_DEFUN([AC_LIBTOOL_CXX], -[AC_REQUIRE([_LT_AC_LANG_CXX]) -])# AC_LIBTOOL_CXX - - -# _LT_AC_LANG_CXX -# --------------- -AC_DEFUN([_LT_AC_LANG_CXX], -[AC_REQUIRE([AC_PROG_CXX]) -AC_REQUIRE([_LT_AC_PROG_CXXCPP]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) -])# _LT_AC_LANG_CXX - -# _LT_AC_PROG_CXXCPP -# --------------- -AC_DEFUN([_LT_AC_PROG_CXXCPP], -[ -AC_REQUIRE([AC_PROG_CXX]) -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_PROG_CXXCPP -fi -])# _LT_AC_PROG_CXXCPP - -# AC_LIBTOOL_F77 -# -------------- -# enable support for Fortran 77 libraries -AC_DEFUN([AC_LIBTOOL_F77], -[AC_REQUIRE([_LT_AC_LANG_F77]) -])# AC_LIBTOOL_F77 - - -# _LT_AC_LANG_F77 -# --------------- -AC_DEFUN([_LT_AC_LANG_F77], -[AC_REQUIRE([AC_PROG_F77]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77]) -])# _LT_AC_LANG_F77 - - -# AC_LIBTOOL_GCJ -# -------------- -# enable support for GCJ libraries -AC_DEFUN([AC_LIBTOOL_GCJ], -[AC_REQUIRE([_LT_AC_LANG_GCJ]) -])# AC_LIBTOOL_GCJ - - -# _LT_AC_LANG_GCJ -# --------------- -AC_DEFUN([_LT_AC_LANG_GCJ], -[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], - [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], - [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], - [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], - [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ]) -])# _LT_AC_LANG_GCJ - - -# AC_LIBTOOL_RC -# -------------- -# enable support for Windows resource files -AC_DEFUN([AC_LIBTOOL_RC], -[AC_REQUIRE([LT_AC_PROG_RC]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC]) -])# AC_LIBTOOL_RC - - -# AC_LIBTOOL_LANG_C_CONFIG -# ------------------------ -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) -AC_DEFUN([_LT_AC_LANG_C_CONFIG], -[lt_save_CC="$CC" -AC_LANG_PUSH(C) - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}\n' - -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# -# Check for any special shared library compilation flags. -# -_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)= -if test "$GCC" = no; then - case $host_os in - sco3.2v5*) - _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf' - ;; - esac -fi -if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then - AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries]) - if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ ]]" >/dev/null; then : - else - AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure]) - _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no - fi -fi - - -# -# Check to make sure the static flag actually works. -# -AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works], - _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1), - $_LT_AC_TAGVAR(lt_prog_compiler_static, $1), - [], - [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) - - -AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF($1) - -# Report which librarie types wil actually be built -AC_MSG_CHECKING([if libtool supports shared libraries]) -AC_MSG_RESULT([$can_build_shared]) - -AC_MSG_CHECKING([whether to build shared libraries]) -test "$can_build_shared" = "no" && enable_shared=no - -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case $host_os in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - -aix4* | aix5*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -AC_MSG_RESULT([$enable_shared]) - -AC_MSG_CHECKING([whether to build static libraries]) -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -AC_MSG_RESULT([$enable_static]) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_C_CONFIG - - -# AC_LIBTOOL_LANG_CXX_CONFIG -# -------------------------- -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) -AC_DEFUN([_LT_AC_LANG_CXX_CONFIG], -[AC_LANG_PUSH(C++) -AC_REQUIRE([AC_PROG_CXX]) -AC_REQUIRE([_LT_AC_PROG_CXXCPP]) - -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_AC_TAGVAR(allow_undefined_flag, $1)= -_LT_AC_TAGVAR(always_export_symbols, $1)=no -_LT_AC_TAGVAR(archive_expsym_cmds, $1)= -_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_direct, $1)=no -_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= -_LT_AC_TAGVAR(hardcode_minus_L, $1)=no -_LT_AC_TAGVAR(hardcode_automatic, $1)=no -_LT_AC_TAGVAR(module_cmds, $1)= -_LT_AC_TAGVAR(module_expsym_cmds, $1)= -_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_AC_TAGVAR(no_undefined_flag, $1)= -_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= -_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Dependencies to place before and after the object being linked: -_LT_AC_TAGVAR(predep_objects, $1)= -_LT_AC_TAGVAR(postdep_objects, $1)= -_LT_AC_TAGVAR(predeps, $1)= -_LT_AC_TAGVAR(postdeps, $1)= -_LT_AC_TAGVAR(compiler_lib_search_path, $1)= - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_LD=$LD -lt_save_GCC=$GCC -GCC=$GXX -lt_save_with_gnu_ld=$with_gnu_ld -lt_save_path_LD=$lt_cv_path_LD -if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx -else - unset lt_cv_prog_gnu_ld -fi -if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX -else - unset lt_cv_path_LD -fi -test -z "${LDCXX+set}" || LD=$LDCXX -CC=${CXX-"c++"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -# We don't want -fno-exception wen compiling C++ code, so set the -# no_builtin_flag separately -if test "$GXX" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' -else - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= -fi - -if test "$GXX" = yes; then - # Set up default GNU C++ configuration - - AC_PROG_LD - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='${wl}' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ - grep 'no-whole-archive' > /dev/null; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - -else - GXX=no - with_gnu_ld=no - wlarc= -fi - -# PORTME: fill in a description of your system's C++ link characteristics -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -_LT_AC_TAGVAR(ld_shlibs, $1)=yes -case $host_os in - aix3*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_AC_TAGVAR(archive_cmds, $1)='' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GXX" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GXX" = yes ; then - lt_int_apple_cc_single_mod=no - output_verbose_link_cmd='echo' - if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then - lt_int_apple_cc_single_mod=yes - fi - if test "X$lt_int_apple_cc_single_mod" = Xyes ; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - fi - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - if test "X$lt_int_apple_cc_single_mod" = Xyes ; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - freebsd[[12]]*) - # C++ shared libraries reported to be fairly broken before switch to ELF - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - freebsd-elf*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - freebsd* | kfreebsd*-gnu | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - ;; - gnu*) - ;; - hpux9*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - ;; - *) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - esac - fi - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - *) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case $host_cpu in - ia64*|hppa*64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' - fi - fi - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - linux*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc*) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC*) - # Portland Group C++ compiler - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - ;; - cxx*) - # Compaq C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' - - runpath_var=LD_RUN_PATH - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - esac - ;; - lynxos*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - m88k*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - openbsd2*) - # C++ shared libraries are fairly broken - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - openbsd*) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd='echo' - ;; - osf3*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ - $rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - psos*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - sco*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The C++ compiler is used as linker so we must use $wl - # flag to pass the commands to the underlying system - # linker. We must also pass each convience library through - # to the system linker between allextract/defaultextract. - # The C++ compiler will combine linker options so we - # cannot just pass the convience library names through - # without $wl. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' - ;; - esac - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - output_verbose_link_cmd='echo' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' - if $CC --version | grep -v '^2\.7' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" - else - # g++ 2.7 appears to require `-G' NOT `-shared' on this - # platform. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" - fi - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' - fi - ;; - esac - ;; - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - vxworks*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; -esac -AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -_LT_AC_TAGVAR(GCC, $1)="$GXX" -_LT_AC_TAGVAR(LD, $1)="$LD" - -AC_LIBTOOL_POSTDEP_PREDEP($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF($1) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC=$lt_save_CC -LDCXX=$LD -LD=$lt_save_LD -GCC=$lt_save_GCC -with_gnu_ldcxx=$with_gnu_ld -with_gnu_ld=$lt_save_with_gnu_ld -lt_cv_path_LDCXX=$lt_cv_path_LD -lt_cv_path_LD=$lt_save_path_LD -lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld -lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -])# AC_LIBTOOL_LANG_CXX_CONFIG - -# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) -# ------------------------ -# Figure out "hidden" library dependencies from verbose -# compiler output when linking a shared library. -# Parse the compiler output and extract the necessary -# objects, libraries and library flags. -AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[ -dnl we can't use the lt_simple_compile_test_code here, -dnl because it contains code intended for an executable, -dnl not a library. It's possible we should let each -dnl tag define a new lt_????_link_test_code variable, -dnl but it's only used here... -ifelse([$1],[],[cat > conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext <> "$cfgfile" -ifelse([$1], [], -[#! $SHELL - -# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -# Free Software Foundation, Inc. -# -# This file is part of GNU Libtool: -# Originally by Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="$SED -e 1s/^X//" - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# The names of the tagged configurations supported by this script. -available_tags= - -# ### BEGIN LIBTOOL CONFIG], -[# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) - -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) - -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# An echo program that does not interpret backslashes. -echo=$lt_echo - -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS - -# A C compiler. -LTCC=$lt_LTCC - -# A language-specific compiler. -CC=$lt_[]_LT_AC_TAGVAR(compiler, $1) - -# Is the compiler the GNU C compiler? -with_gcc=$_LT_AC_TAGVAR(GCC, $1) - -# An ERE matcher. -EGREP=$lt_EGREP - -# The linker used to build libraries. -LD=$lt_[]_LT_AC_TAGVAR(LD, $1) - -# Whether we need hard or soft links. -LN_S=$lt_LN_S - -# A BSD-compatible nm program. -NM=$lt_NM - -# A symbol stripping program -STRIP=$lt_STRIP - -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD - -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" - -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" - -# Used on cygwin: assembler. -AS="$AS" - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds - -# How to pass a linker flag through the compiler. -wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) - -# Object file suffix (normally "o"). -objext="$ac_objext" - -# Old archive suffix (normally "a"). -libext="$libext" - -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' - -# Executable file suffix (normally ""). -exeext="$exeext" - -# Additional compiler flags for building library objects. -pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) -pic_mode=$pic_mode - -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) - -# Must we lock files when doing compilation? -need_locks=$lt_need_locks - -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Whether dlopen is supported. -dlopen_support=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) - -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) - -# Library versioning type. -version_type=$version_type - -# Format of library name prefix. -libname_spec=$lt_libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec - -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) - -# Commands used to build and install a shared archive. -archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) -archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds - -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) -module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) - -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib - -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) - -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) - -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) - -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) - -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method - -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) - -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds - -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl - -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - -# This is the shared library runtime path variable. -runpath_var=$runpath_var - -# This is the shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# How to hardcode a shared library path into an executable. -hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) - -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) - -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) - -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) - -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) - -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) - -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) - -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) - -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)" - -# Set to yes if exported symbols are required. -always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) - -# The commands to list exported symbols. -export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) - -# Symbols that must always be exported. -include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) - -ifelse([$1],[], -[# ### END LIBTOOL CONFIG], -[# ### END LIBTOOL TAG CONFIG: $tagname]) - -__EOF__ - -ifelse([$1],[], [ - case $host_os in - aix3*) - cat <<\EOF >> "$cfgfile" - -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -EOF - ;; - esac - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || \ - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" -]) -else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi -])# AC_LIBTOOL_CONFIG - - -# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) -# ------------------------------------------- -AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], -[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl - -_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - -if test "$GCC" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' - - AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], - lt_cv_prog_compiler_rtti_exceptions, - [-fno-rtti -fno-exceptions], [], - [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) -fi -])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI - - -# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -# --------------------------------- -AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], -[AC_REQUIRE([AC_CANONICAL_HOST]) -AC_REQUIRE([AC_PROG_NM]) -AC_REQUIRE([AC_OBJEXT]) -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[[BCDEGRST]]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' - -# Transform an extracted symbol line into a proper C declaration -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[[BCDT]]' - ;; -cygwin* | mingw* | pw32*) - symcode='[[ABCDGISTW]]' - ;; -hpux*) # Its linker distinguishes data from code symbols - if test "$host_cpu" = ia64; then - symcode='[[ABCDEGRST]]' - fi - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - ;; -linux*) - if test "$host_cpu" = ia64; then - symcode='[[ABCDGIRSTW]]' - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris* | sysv5*) - symcode='[[BDRT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext < $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if grep ' nm_test_var$' "$nlist" >/dev/null; then - if grep ' nm_test_func$' "$nlist" >/dev/null; then - cat < conftest.$ac_ext -#ifdef __cplusplus -extern "C" { -#endif - -EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' - - cat <> conftest.$ac_ext -#if defined (__STDC__) && __STDC__ -# define lt_ptr_t void * -#else -# define lt_ptr_t char * -# define const -#endif - -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - lt_ptr_t address; -} -lt_preloaded_symbols[[]] = -{ -EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext - cat <<\EOF >> conftest.$ac_ext - {0, (lt_ptr_t) 0} -}; - -#ifdef __cplusplus -} -#endif -EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" - else - echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.$ac_ext >&5 - fi - rm -f conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done -]) -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - AC_MSG_RESULT(failed) -else - AC_MSG_RESULT(ok) -fi -]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE - - -# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) -# --------------------------------------- -AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], -[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= -_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= -_LT_AC_TAGVAR(lt_prog_compiler_static, $1)= - -AC_MSG_CHECKING([for $compiler option to produce PIC]) - ifelse([$1],[CXX],[ - # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | os2* | pw32*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - case $host_os in - aix4* | aix5*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" - ;; - esac - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | kfreebsd*-gnu | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - icpc* | ecpc*) - # Intel C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC*) - # Portland Group C++ compiler. - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd*) - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - sco*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - *) - ;; - esac - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - unixware*) - ;; - vxworks*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - if test "$GCC" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - enable_shared=no - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - - hpux9* | hpux10* | hpux11*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC (with -KPIC) is the default. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - newsos6) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - linux*) - case $cc_basename in - icc* | ecc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - ccc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - esac - ;; - - osf3* | osf4* | osf5*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All OSF/1 code is PIC. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - sco3.2v5*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn' - ;; - - solaris*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; - - sunos4*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - unicos*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - - uts4*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *) - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -]) -AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then - AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], - _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1), - [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" - ;; -esac -]) - - -# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) -# ------------------------------------ -# See if the linker supports building shared libraries. -AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], -[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -ifelse([$1],[CXX],[ - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - case $host_os in - aix4* | aix5*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - ;; - pw32*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" - ;; - cygwin* | mingw*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' - ;; - *) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac -],[ - runpath_var= - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)= - _LT_AC_TAGVAR(archive_expsym_cmds, $1)= - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_minus_L, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown - _LT_AC_TAGVAR(hardcode_automatic, $1)=no - _LT_AC_TAGVAR(module_cmds, $1)= - _LT_AC_TAGVAR(module_expsym_cmds, $1)= - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_AC_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - _LT_CC_BASENAME([$compiler]) - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac - - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <&2 - -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. - -EOF - fi - ;; - - amigaos*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test $supports_anon_versioning = yes; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - sunos4*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - - if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then - runpath_var= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; - - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_AC_TAGVAR(archive_cmds, $1)='' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GCC" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - amigaos*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - # see comment about different semantics on the GNU ld section - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - bsdi[[45]]*) - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic - ;; - - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' - # FIXME: Should let the user specify the lib program. - _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs' - _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - ;; - - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - dgux*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - freebsd1*) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - hpux9*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - ;; - *) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - newsos6) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - openbsd*) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac - fi - ;; - - os2*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - else - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' - - # Both c and cxx compiler support -rpath directly - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - fi - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - sco3.2v5*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; - - solaris*) - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; - *) - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4) - case $host_vendor in - sni) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' - _LT_AC_TAGVAR(hardcode_direct, $1)=no - ;; - motorola) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4.3*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' - ;; +# Copyright (C) 1996-2014 Free Software Foundation, Inc. - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - fi - ;; +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. - sysv4.2uw2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) - _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text' - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, +[m4_warning([this file was generated for autoconf 2.69. +You have another version of autoconf. It may work, but is not guaranteed to. +If you have problems, you may need to regenerate the build system entirely. +To do so, use the procedure documented by the package, typically 'autoreconf'.])]) - sysv5*) - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - ;; +# serial 9 -*- Autoconf -*- +# Enable extensions on systems that normally disable them. - uts4*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +# Copyright (C) 2003, 2006-2010 Free Software Foundation, Inc. +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac +# This definition of AC_USE_SYSTEM_EXTENSIONS is stolen from CVS +# Autoconf. Perhaps we can remove this once we can assume Autoconf +# 2.62 or later everywhere, but since CVS Autoconf mutates rapidly +# enough in this area it's likely we'll need to redefine +# AC_USE_SYSTEM_EXTENSIONS for quite some time. + +# If autoconf reports a warning +# warning: AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS +# or warning: AC_RUN_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS +# the fix is +# 1) to ensure that AC_USE_SYSTEM_EXTENSIONS is never directly invoked +# but always AC_REQUIREd, +# 2) to ensure that for each occurrence of +# AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS]) +# or +# AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) +# the corresponding gnulib module description has 'extensions' among +# its dependencies. This will ensure that the gl_USE_SYSTEM_EXTENSIONS +# invocation occurs in gl_EARLY, not in gl_INIT. + +# AC_USE_SYSTEM_EXTENSIONS +# ------------------------ +# Enable extensions on systems that normally disable them, +# typically due to standards-conformance issues. +# Remember that #undef in AH_VERBATIM gets replaced with #define by +# AC_DEFINE. The goal here is to define all known feature-enabling +# macros, then, if reports of conflicts are made, disable macros that +# cause problems on some platforms (such as __EXTENSIONS__). +AC_DEFUN_ONCE([AC_USE_SYSTEM_EXTENSIONS], +[AC_BEFORE([$0], [AC_COMPILE_IFELSE])dnl +AC_BEFORE([$0], [AC_RUN_IFELSE])dnl + + AC_REQUIRE([AC_CANONICAL_HOST]) + + AC_CHECK_HEADER([minix/config.h], [MINIX=yes], [MINIX=]) + if test "$MINIX" = yes; then + AC_DEFINE([_POSIX_SOURCE], [1], + [Define to 1 if you need to in order for `stat' and other + things to work.]) + AC_DEFINE([_POSIX_1_SOURCE], [2], + [Define to 2 if the system does not provide POSIX.1 features + except with this defined.]) + AC_DEFINE([_MINIX], [1], + [Define to 1 if on MINIX.]) fi -]) -AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -# -# Do we need to explicitly link libc? -# -case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in -x|xyes) - # Assume -lc should be added - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $_LT_AC_TAGVAR(archive_cmds, $1) in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - AC_MSG_CHECKING([whether -lc should be explicitly linked in]) - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) - then - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - else - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) + dnl HP-UX 11.11 defines mbstate_t only if _XOPEN_SOURCE is defined to 500, + dnl regardless of whether the flags -Ae or _D_HPUX_SOURCE=1 are already + dnl provided. + case "$host_os" in + hpux*) + AC_DEFINE([_XOPEN_SOURCE], [500], + [Define to 500 only on HP-UX.]) ;; - esac - fi - ;; -esac -])# AC_LIBTOOL_PROG_LD_SHLIBS - - -# _LT_AC_FILE_LTDLL_C -# ------------------- -# Be careful that the start marker always follows a newline. -AC_DEFUN([_LT_AC_FILE_LTDLL_C], [ -# /* ltdll.c starts here */ -# #define WIN32_LEAN_AND_MEAN -# #include -# #undef WIN32_LEAN_AND_MEAN -# #include -# -# #ifndef __CYGWIN__ -# # ifdef __CYGWIN32__ -# # define __CYGWIN__ __CYGWIN32__ -# # endif -# #endif -# -# #ifdef __cplusplus -# extern "C" { -# #endif -# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); -# #ifdef __cplusplus -# } -# #endif -# -# #ifdef __CYGWIN__ -# #include -# DECLARE_CYGWIN_DLL( DllMain ); -# #endif -# HINSTANCE __hDllInstance_base; -# -# BOOL APIENTRY -# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) -# { -# __hDllInstance_base = hInst; -# return TRUE; -# } -# /* ltdll.c ends here */ -])# _LT_AC_FILE_LTDLL_C - - -# _LT_AC_TAGVAR(VARNAME, [TAGNAME]) -# --------------------------------- -AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) - - -# old names -AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) -AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) -AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) -AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) -AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) -AC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) -AC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) - -# This is just to silence aclocal about the macro not being used -ifelse([AC_DISABLE_FAST_INSTALL]) - -AC_DEFUN([LT_AC_PROG_GCJ], -[AC_CHECK_TOOL(GCJ, gcj, no) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" - AC_SUBST(GCJFLAGS) -]) - -AC_DEFUN([LT_AC_PROG_RC], -[AC_CHECK_TOOL(RC, windres, no) -]) + esac -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -# LT_AC_PROG_SED -# -------------- -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -AC_DEFUN([LT_AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done + AH_VERBATIM([__EXTENSIONS__], +[/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# undef _GNU_SOURCE +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# undef _POSIX_PTHREAD_SEMANTICS +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# undef _TANDEM_SOURCE +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# undef __EXTENSIONS__ +#endif ]) -SED=$lt_cv_path_SED -AC_MSG_RESULT([$SED]) + AC_CACHE_CHECK([whether it is safe to define __EXTENSIONS__], + [ac_cv_safe_to_define___extensions__], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[ +# define __EXTENSIONS__ 1 + ]AC_INCLUDES_DEFAULT])], + [ac_cv_safe_to_define___extensions__=yes], + [ac_cv_safe_to_define___extensions__=no])]) + test $ac_cv_safe_to_define___extensions__ = yes && + AC_DEFINE([__EXTENSIONS__]) + AC_DEFINE([_ALL_SOURCE]) + AC_DEFINE([_GNU_SOURCE]) + AC_DEFINE([_POSIX_PTHREAD_SEMANTICS]) + AC_DEFINE([_TANDEM_SOURCE]) +])# AC_USE_SYSTEM_EXTENSIONS + +# gl_USE_SYSTEM_EXTENSIONS +# ------------------------ +# Enable extensions on systems that normally disable them, +# typically due to standards-conformance issues. +AC_DEFUN_ONCE([gl_USE_SYSTEM_EXTENSIONS], +[ + dnl Require this macro before AC_USE_SYSTEM_EXTENSIONS. + dnl gnulib does not need it. But if it gets required by third-party macros + dnl after AC_USE_SYSTEM_EXTENSIONS is required, autoconf 2.62..2.63 emit a + dnl warning: "AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS". + dnl Note: We can do this only for one of the macros AC_AIX, AC_GNU_SOURCE, + dnl AC_MINIX. If people still use AC_AIX or AC_MINIX, they are out of luck. + AC_REQUIRE([AC_GNU_SOURCE]) + + AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS]) ]) -# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +# Copyright (C) 2002-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -6195,10 +151,10 @@ AC_MSG_RESULT([$SED]) # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.11' +[am__api_version='1.15' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.11], [], +m4_if([$1], [1.15], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -6214,22 +170,82 @@ m4_define([_AM_AUTOCONF_VERSION], []) # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.11])dnl +[AM_AUTOMAKE_VERSION([1.15])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) +# Copyright (C) 2011-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_AR([ACT-IF-FAIL]) +# ------------------------- +# Try to determine the archiver interface, and trigger the ar-lib wrapper +# if it is needed. If the detection of archiver interface fails, run +# ACT-IF-FAIL (default is to abort configure with a proper error message). +AC_DEFUN([AM_PROG_AR], +[AC_BEFORE([$0], [LT_INIT])dnl +AC_BEFORE([$0], [AC_PROG_LIBTOOL])dnl +AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([ar-lib])dnl +AC_CHECK_TOOLS([AR], [ar lib "link -lib"], [false]) +: ${AR=ar} + +AC_CACHE_CHECK([the archiver ($AR) interface], [am_cv_ar_interface], + [AC_LANG_PUSH([C]) + am_cv_ar_interface=ar + AC_COMPILE_IFELSE([AC_LANG_SOURCE([[int some_variable = 0;]])], + [am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([am_ar_try]) + if test "$ac_status" -eq 0; then + am_cv_ar_interface=ar + else + am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([am_ar_try]) + if test "$ac_status" -eq 0; then + am_cv_ar_interface=lib + else + am_cv_ar_interface=unknown + fi + fi + rm -f conftest.lib libconftest.a + ]) + AC_LANG_POP([C])]) + +case $am_cv_ar_interface in +ar) + ;; +lib) + # Microsoft lib, so override with the ar-lib wrapper script. + # FIXME: It is wrong to rewrite AR. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__AR in this case, + # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something + # similar. + AR="$am_aux_dir/ar-lib $AR" + ;; +unknown) + m4_default([$1], + [AC_MSG_ERROR([could not determine $AR interface])]) + ;; +esac +AC_SUBST([AR])dnl +]) + # AM_AUX_DIR_EXPAND -*- Autoconf -*- -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets -# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to -# `$srcdir', `$srcdir/..', or `$srcdir/../..'. +# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to +# '$srcdir', '$srcdir/..', or '$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and @@ -6248,7 +264,7 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually -# harmless because $srcdir is `.', but things will broke when you +# harmless because $srcdir is '.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, @@ -6266,30 +282,26 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], -[dnl Rely on autoconf to set up CDPATH properly. -AC_PREREQ([2.50])dnl -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` +[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- -# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 9 - # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], -[AC_PREREQ(2.52)dnl - ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], - [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl +[AC_PREREQ([2.52])dnl + m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE])dnl AC_SUBST([$1_FALSE])dnl _AM_SUBST_NOTMAKE([$1_TRUE])dnl @@ -6308,16 +320,14 @@ AC_CONFIG_COMMANDS_PRE( Usually this means the macro was only invoked conditionally.]]) fi])]) -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 -# Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 10 -# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be +# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing @@ -6327,7 +337,7 @@ fi])]) # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. -# NAME is "CC", "CXX", "GCJ", or "OBJC". +# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was @@ -6340,12 +350,13 @@ AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl -ifelse([$1], CC, [depcc="$CC" am_compiler_list=], - [$1], CXX, [depcc="$CXX" am_compiler_list=], - [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], - [$1], UPC, [depcc="$UPC" am_compiler_list=], - [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], - [depcc="$$1" am_compiler_list=]) +m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], + [$1], [CXX], [depcc="$CXX" am_compiler_list=], + [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], + [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], + [$1], [UPC], [depcc="$UPC" am_compiler_list=], + [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], + [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], @@ -6353,8 +364,9 @@ AC_CACHE_CHECK([dependency style of $depcc], # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -6393,16 +405,16 @@ AC_CACHE_CHECK([dependency style of $depcc], : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with `-c' and `-o' for the sake of the "dashmstdout" + # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in @@ -6411,16 +423,16 @@ AC_CACHE_CHECK([dependency style of $depcc], test "$am__universal" = false || continue ;; nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} @@ -6468,7 +480,7 @@ AM_CONDITIONAL([am__fastdep$1], [ # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. -# This macro is AC_REQUIREd in _AM_DEPENDENCIES +# This macro is AC_REQUIREd in _AM_DEPENDENCIES. AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl @@ -6478,34 +490,39 @@ AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], -[AC_ARG_ENABLE(dependency-tracking, -[ --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors]) +[AC_ARG_ENABLE([dependency-tracking], [dnl +AS_HELP_STRING( + [--enable-dependency-tracking], + [do not reject slow dependency extractors]) +AS_HELP_STRING( + [--disable-dependency-tracking], + [speeds up one-time build])]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' + am__nodep='_no' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl +AC_SUBST([am__nodep])dnl +_AM_SUBST_NOTMAKE([am__nodep])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -#serial 5 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [{ - # Autoconf 2.62 quotes --file arguments for eval, but not when files + # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. case $CONFIG_FILES in @@ -6518,7 +535,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but + # We used to match only the files named 'Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. @@ -6530,21 +547,19 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], continue fi # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. + # from the Makefile without running 'make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue + test -z "$am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` @@ -6562,7 +577,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking -# is enabled. FIXME. This creates each `.P' file that we will +# is enabled. FIXME. This creates each '.P' file that we will # need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], @@ -6570,32 +585,23 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 -# Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# serial 8 - -# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. -AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) - # Do all the work for Automake. -*- Autoconf -*- -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 16 - # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. +dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. +m4_define([AC_PROG_CC], +m4_defn([AC_PROG_CC]) +[_AM_PROG_CC_C_O +]) + # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- @@ -6608,7 +614,7 @@ AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], -[AC_PREREQ([2.62])dnl +[AC_PREREQ([2.65])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl @@ -6637,33 +643,42 @@ AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], -[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl +[AC_DIAGNOSE([obsolete], + [$0: two- and three-arguments forms are deprecated.]) +m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. -m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, +m4_if( + m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), + [ok:ok],, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, -[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) - AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl +[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) + AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl -AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) -AM_MISSING_PROG(AUTOCONF, autoconf) -AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) -AM_MISSING_PROG(AUTOHEADER, autoheader) -AM_MISSING_PROG(MAKEINFO, makeinfo) +AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) +AM_MISSING_PROG([AUTOCONF], [autoconf]) +AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) +AM_MISSING_PROG([AUTOHEADER], [autoheader]) +AM_MISSING_PROG([MAKEINFO], [makeinfo]) AC_REQUIRE([AM_PROG_INSTALL_SH])dnl AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl -AC_REQUIRE([AM_PROG_MKDIR_P])dnl -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. +AC_REQUIRE([AC_PROG_MKDIR_P])dnl +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +AC_SUBST([mkdir_p], ['$(MKDIR_P)']) +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl @@ -6672,34 +687,82 @@ _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], - [_AM_DEPENDENCIES(CC)], - [define([AC_PROG_CC], - defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl + [_AM_DEPENDENCIES([CC])], + [m4_define([AC_PROG_CC], + m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], - [_AM_DEPENDENCIES(CXX)], - [define([AC_PROG_CXX], - defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl + [_AM_DEPENDENCIES([CXX])], + [m4_define([AC_PROG_CXX], + m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], - [_AM_DEPENDENCIES(OBJC)], - [define([AC_PROG_OBJC], - defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl + [_AM_DEPENDENCIES([OBJC])], + [m4_define([AC_PROG_OBJC], + m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], + [_AM_DEPENDENCIES([OBJCXX])], + [m4_define([AC_PROG_OBJCXX], + m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl ]) -_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl -dnl The `parallel-tests' driver may need to know about EXEEXT, so add the -dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro -dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. +AC_REQUIRE([AM_SILENT_RULES])dnl +dnl The testsuite driver may need to know about EXEEXT, so add the +dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This +dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. AC_CONFIG_COMMANDS_PRE(dnl [m4_provide_if([_AM_COMPILER_EXEEXT], [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) + fi +fi +dnl The trailing newline in this macro's definition is deliberate, for +dnl backward compatibility and to allow trailing 'dnl'-style comments +dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. ]) -dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not +dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further dnl mangled by Autoconf and run in a shell conditional statement. m4_define([_AC_COMPILER_EXEEXT], m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) - # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. @@ -6721,7 +784,7 @@ for _am_header in $config_headers :; do done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) -# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -6732,7 +795,7 @@ echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_co # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -if test x"${install_sh}" != xset; then +if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; @@ -6740,16 +803,14 @@ if test x"${install_sh}" != xset; then install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi -AC_SUBST(install_sh)]) +AC_SUBST([install_sh])]) -# Copyright (C) 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2003-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], @@ -6765,14 +826,12 @@ AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- -# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 4 - # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. @@ -6790,7 +849,7 @@ am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. +# Ignore all kinds of additional output from 'make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include @@ -6817,15 +876,12 @@ rm -f confinc confmf # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- -# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 6 - # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], @@ -6833,11 +889,10 @@ AC_DEFUN([AM_MISSING_PROG], $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) - # AM_MISSING_HAS_RUN # ------------------ -# Define MISSING if not defined so far and test if it supports --run. -# If it does, set am_missing_run to use it, otherwise, to nothing. +# Define MISSING if not defined so far and test if it is modern enough. +# If it is, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl @@ -6850,63 +905,35 @@ if test x"${MISSING+set}" != xset; then esac fi # Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " else am_missing_run= - AC_MSG_WARN([`missing' script is too old or missing]) + AC_MSG_WARN(['missing' script is too old or missing]) fi ]) -# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_MKDIR_P -# --------------- -# Check for `mkdir -p'. -AC_DEFUN([AM_PROG_MKDIR_P], -[AC_PREREQ([2.60])dnl -AC_REQUIRE([AC_PROG_MKDIR_P])dnl -dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, -dnl while keeping a definition of mkdir_p for backward compatibility. -dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. -dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of -dnl Makefile.ins that do not define MKDIR_P, so we do our own -dnl adjustment using top_builddir (which is defined more often than -dnl MKDIR_P). -AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl -case $mkdir_p in - [[\\/$]]* | ?:[[\\/]]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac -]) - # Helper functions for option handling. -*- Autoconf -*- -# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 4 - # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) -# ------------------------------ +# -------------------- # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], -[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) +[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) # _AM_SET_OPTIONS(OPTIONS) -# ---------------------------------- +# ------------------------ # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) @@ -6917,24 +944,82 @@ AC_DEFUN([_AM_SET_OPTIONS], AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Check to make sure that the build environment is sane. -*- Autoconf -*- +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_CC_C_O +# --------------- +# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC +# to automatically call this. +AC_DEFUN([_AM_PROG_CC_C_O], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([compile])dnl +AC_LANG_PUSH([C])dnl +AC_CACHE_CHECK( + [whether $CC understands -c and -o together], + [am_cv_prog_cc_c_o], + [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i]) +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +AC_LANG_POP([C])]) + +# For backward compatibility. +AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 5 +# AM_RUN_LOG(COMMAND) +# ------------------- +# Run COMMAND, save the exit status in ac_status, and log it. +# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) +AC_DEFUN([AM_RUN_LOG], +[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD + ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + (exit $ac_status); }]) + +# Check to make sure that the build environment is sane. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) -# Just in case -sleep 1 -echo timestamp > conftest.file # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' @@ -6945,32 +1030,40 @@ case `pwd` in esac case $srcdir in *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) - AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; + AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; esac -# Do `set' in a subshell so we don't clobber the current shell's +# Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$[*]" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$[*]" != "X $srcdir/configure conftest.file" \ - && test "$[*]" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken -alias in your environment]) - fi - + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[*]" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$[*]" != "X $srcdir/configure conftest.file" \ + && test "$[*]" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken + alias in your environment]) + fi + if test "$[2]" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done test "$[2]" = conftest.file ) then @@ -6980,9 +1073,85 @@ else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi -AC_MSG_RESULT(yes)]) +AC_MSG_RESULT([yes]) +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi +AC_CONFIG_COMMANDS_PRE( + [AC_MSG_CHECKING([that generated files are newer than configure]) + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + AC_MSG_RESULT([done])]) +rm -f conftest.file +]) + +# Copyright (C) 2009-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Enable less verbose build rules; with the default set to DEFAULT +# ("yes" being less verbose, "no" or empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_ARG_ENABLE([silent-rules], [dnl +AS_HELP_STRING( + [--enable-silent-rules], + [less verbose build output (undo: "make V=1")]) +AS_HELP_STRING( + [--disable-silent-rules], + [verbose build output (undo: "make V=0")])dnl +]) +case $enable_silent_rules in @%:@ ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; +esac +dnl +dnl A few 'make' implementations (e.g., NonStop OS and NextStep) +dnl do not support nested variable expansions. +dnl See automake bug#9928 and bug#10237. +am_make=${MAKE-make} +AC_CACHE_CHECK([whether $am_make supports nested variables], + [am_cv_make_support_nested_variables], + [if AS_ECHO([['TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi]) +if test $am_cv_make_support_nested_variables = yes; then + dnl Using '$V' instead of '$(V)' breaks IRIX make. + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AC_SUBST([AM_V])dnl +AM_SUBST_NOTMAKE([AM_V])dnl +AC_SUBST([AM_DEFAULT_V])dnl +AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl +AC_SUBST([AM_DEFAULT_VERBOSITY])dnl +AM_BACKSLASH='\' +AC_SUBST([AM_BACKSLASH])dnl +_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +]) -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -6990,34 +1159,32 @@ AC_MSG_RESULT(yes)]) # AM_PROG_INSTALL_STRIP # --------------------- -# One issue with vendor `install' (even GNU) is that you can't +# One issue with vendor 'install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we -# always use install-sh in `make install-strip', and initialize +# always use install-sh in "make install-strip", and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. -dnl Don't test for $cross_compiling = yes, because it might be `maybe'. +# will honor the 'STRIP' environment variable to overrule this program. +dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) -# Copyright (C) 2006, 2008 Free Software Foundation, Inc. +# Copyright (C) 2006-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # _AM_SUBST_NOTMAKE(VARIABLE) # --------------------------- # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. @@ -7025,24 +1192,22 @@ AC_SUBST([INSTALL_STRIP_PROGRAM])]) AC_DEFUN([_AM_SUBST_NOTMAKE]) # AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- +# -------------------------- # Public sister of _AM_SUBST_NOTMAKE. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- -# Copyright (C) 2004, 2005 Free Software Foundation, Inc. +# Copyright (C) 2004-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. -# FORMAT should be one of `v7', `ustar', or `pax'. +# FORMAT should be one of 'v7', 'ustar', or 'pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory @@ -7052,77 +1217,147 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar +# AC_DEFUN([_AM_PROG_TAR], -[# Always define AMTAR for backward compatibility. -AM_MISSING_PROG([AMTAR], [tar]) -m4_if([$1], [v7], - [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], - [m4_case([$1], [ustar],, [pax],, - [m4_fatal([Unknown tar format])]) -AC_MSG_CHECKING([how to create a $1 tar archive]) -# Loop over all known methods to create a tar archive until one works. +[# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AC_SUBST([AMTAR], ['$${TAR-tar}']) + +# We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' -_am_tools=${am_cv_prog_tar_$1-$_am_tools} -# Do not fold the above two line into one, because Tru64 sh and -# Solaris sh will not grok spaces in the rhs of `-'. -for _am_tool in $_am_tools -do - case $_am_tool in - gnutar) - for _am_tar in tar gnutar gtar; - do - AM_RUN_LOG([$_am_tar --version]) && break - done - am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' - am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' - am__untar="$_am_tar -xf -" - ;; - plaintar) - # Must skip GNU tar: if it does not support --format= it doesn't create - # ustar tarball either. - (tar --version) >/dev/null 2>&1 && continue - am__tar='tar chf - "$$tardir"' - am__tar_='tar chf - "$tardir"' - am__untar='tar xf -' - ;; - pax) - am__tar='pax -L -x $1 -w "$$tardir"' - am__tar_='pax -L -x $1 -w "$tardir"' - am__untar='pax -r' - ;; - cpio) - am__tar='find "$$tardir" -print | cpio -o -H $1 -L' - am__tar_='find "$tardir" -print | cpio -o -H $1 -L' - am__untar='cpio -i -H $1 -d' - ;; - none) - am__tar=false - am__tar_=false - am__untar=false - ;; - esac - # If the value was cached, stop now. We just wanted to have am__tar - # and am__untar set. - test -n "${am_cv_prog_tar_$1}" && break +m4_if([$1], [v7], + [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], + + [m4_case([$1], + [ustar], + [# The POSIX 1988 'ustar' format is defined with fixed-size fields. + # There is notably a 21 bits limit for the UID and the GID. In fact, + # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 + # and bug#13588). + am_max_uid=2097151 # 2^21 - 1 + am_max_gid=$am_max_uid + # The $UID and $GID variables are not portable, so we need to resort + # to the POSIX-mandated id(1) utility. Errors in the 'id' calls + # below are definitely unexpected, so allow the users to see them + # (that is, avoid stderr redirection). + am_uid=`id -u || echo unknown` + am_gid=`id -g || echo unknown` + AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) + if test $am_uid -le $am_max_uid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi + AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) + if test $am_gid -le $am_max_gid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi], + + [pax], + [], - # tar/untar a dummy directory, and stop if the command works - rm -rf conftest.dir - mkdir conftest.dir - echo GrepMe > conftest.dir/file - AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + [m4_fatal([Unknown tar format])]) + + AC_MSG_CHECKING([how to create a $1 tar archive]) + + # Go ahead even if we have the value already cached. We do so because we + # need to set the values for the 'am__tar' and 'am__untar' variables. + _am_tools=${am_cv_prog_tar_$1-$_am_tools} + + for _am_tool in $_am_tools; do + case $_am_tool in + gnutar) + for _am_tar in tar gnutar gtar; do + AM_RUN_LOG([$_am_tar --version]) && break + done + am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' + am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' + am__untar="$_am_tar -xf -" + ;; + plaintar) + # Must skip GNU tar: if it does not support --format= it doesn't create + # ustar tarball either. + (tar --version) >/dev/null 2>&1 && continue + am__tar='tar chf - "$$tardir"' + am__tar_='tar chf - "$tardir"' + am__untar='tar xf -' + ;; + pax) + am__tar='pax -L -x $1 -w "$$tardir"' + am__tar_='pax -L -x $1 -w "$tardir"' + am__untar='pax -r' + ;; + cpio) + am__tar='find "$$tardir" -print | cpio -o -H $1 -L' + am__tar_='find "$tardir" -print | cpio -o -H $1 -L' + am__untar='cpio -i -H $1 -d' + ;; + none) + am__tar=false + am__tar_=false + am__untar=false + ;; + esac + + # If the value was cached, stop now. We just wanted to have am__tar + # and am__untar set. + test -n "${am_cv_prog_tar_$1}" && break + + # tar/untar a dummy directory, and stop if the command works. + rm -rf conftest.dir + mkdir conftest.dir + echo GrepMe > conftest.dir/file + AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + rm -rf conftest.dir + if test -s conftest.tar; then + AM_RUN_LOG([$am__untar /dev/null 2>&1 && break + fi + done rm -rf conftest.dir - if test -s conftest.tar; then - AM_RUN_LOG([$am__untar /dev/null 2>&1 && break - fi -done -rm -rf conftest.dir -AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) -AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) + AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR m4_include([libopts/m4/libopts.m4]) +m4_include([libopts/m4/stdnoreturn.m4]) +m4_include([m4/hms_search_lib.m4]) +m4_include([m4/libtool.m4]) +m4_include([m4/ltoptions.m4]) +m4_include([m4/ltsugar.m4]) +m4_include([m4/ltversion.m4]) +m4_include([m4/lt~obsolete.m4]) +m4_include([m4/ntp_cacheversion.m4]) +m4_include([m4/ntp_compiler.m4]) +m4_include([m4/ntp_crosscompile.m4]) +m4_include([m4/ntp_debug.m4]) +m4_include([m4/ntp_dir_sep.m4]) +m4_include([m4/ntp_facilitynames.m4]) +m4_include([m4/ntp_googletest.m4]) +m4_include([m4/ntp_ipv6.m4]) +m4_include([m4/ntp_lib_m.m4]) +m4_include([m4/ntp_libevent.m4]) +m4_include([m4/ntp_libntp.m4]) +m4_include([m4/ntp_lineeditlibs.m4]) +m4_include([m4/ntp_locinfo.m4]) +m4_include([m4/ntp_openssl.m4]) +m4_include([m4/ntp_pkg_config.m4]) +m4_include([m4/ntp_prog_cc.m4]) +m4_include([m4/ntp_sntp.m4]) +m4_include([m4/ntp_sysexits.m4]) +m4_include([m4/ntp_unitytest.m4]) +m4_include([m4/ntp_ver_suffix.m4]) +m4_include([m4/openldap-thread-check.m4]) +m4_include([m4/openldap.m4]) +m4_include([m4/os_cflags.m4]) +m4_include([m4/snprintf.m4]) diff --git a/contrib/ntp/sntp/ag-tpl/0-old/Mdoc.pm b/contrib/ntp/sntp/ag-tpl/0-old/Mdoc.pm new file mode 100644 index 000000000..61fffd6f6 --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/Mdoc.pm @@ -0,0 +1,515 @@ +=head1 NAME + +Mdoc - perl module to parse Mdoc macros + +=head1 SYNOPSIS + + use Mdoc qw(ns pp soff son stoggle mapwords); + +See mdoc2man and mdoc2texi for code examples. + +=head1 FUNCTIONS + +=over 4 + +=item def_macro( NAME, CODE, [ raw => 1, greedy => 1, concat_until => '.Xx' ] ) + +Define new macro. The CODE reference will be called by call_macro(). You can +have two distinct definitions for and inline macro and for a standalone macro +(i. e. 'Pa' and '.Pa'). + +The CODE reference is passed a list of arguments and is expected to return list +of strings and control characters (see C). + +By default the surrouding "" from arguments to macros are removed, use C +to disable this. + +Normaly CODE reference is passed all arguments up to next nested macro. Set +C to to pass everything up to the end of the line. + +If the concat_until is present, the line is concated until the .Xx macro is +found. For example the following macro definition + + def_macro('.Oo', gen_encloser(qw([ ]), concat_until => '.Oc' } + def_macro('.Cm', sub { mapwords {'($_)'} @_ } } + +and the following input + + .Oo + .Cm foo | + .Cm bar | + .Oc + +results in [(foo) | (bar)] + +=item get_macro( NAME ) + +Returns a hash reference like: + + { run => CODE, raw => [1|0], greedy => [1|0] } + +Where C is the CODE reference used to define macro called C + +=item parse_line( INPUT, OUTPUT_CODE, PREPROCESS_CODE ) + +Parse a line from the C filehandle. If a macro was detected it returns a +list (MACRO_NAME, @MACRO_ARGS), otherwise it calls the C, giving +caller a chance to modify line before printing it. If C is +defined it calls it prior to passing argument to a macro, giving caller a +chance to alter them. if EOF was reached undef is returned. + +=item call_macro( MACRO, ARGS, ... ) + +Call macro C with C. The CODE reference for macro C is +called and for all the nested macros. Every called macro returns a list which +is appended to return value and returned when all nested macros are processed. +Use to_string() to produce a printable string from the list. + +=item to_string ( LIST ) + +Processes C returned from call_macro() and returns formatted string. + +=item mapwords BLOCK ARRAY + +This is like perl's map only it calls BLOCK only on elements which are not +punctuation or control characters. + +=item space ( ['on'|'off] ) + +Turn spacing on or off. If called without argument it returns the current state. + +=item gen_encloser ( START, END ) + +Helper function for generating macros that enclose their arguments. + gen_encloser(qw({ })); +returns + sub { '{', ns, @_, ns, pp('}')} + +=item set_Bl_callback( CODE , DEFS ) + +This module implements the Bl/El macros for you. Using set_Bl_callback you can +provide a macro definition that should be executed on a .Bl call. + +=item set_El_callback( CODE , DEFS ) + +This module implements the Bl/El macros for you. Using set_El_callback you can +provide a macro definition that should be executed on a .El call. + +=item set_Re_callback( CODE ) + +The C is called after a Rs/Re block is done. With a hash reference as a +parameter, describing the reference. + +=back + +=head1 CONSTANTS + +=over 4 + +=item ns + +Indicate 'no space' between to members of the list. + +=item pp ( STRING ) + +The string is 'punctuation point'. It means that every punctuation +preceeding that element is put behind it. + +=item soff + +Turn spacing off. + +=item son + +Turn spacing on. + +=item stoggle + +Toogle spacing. + +=item hs + +Print space no matter spacing mode. + +=back + +=head1 TODO + +* The concat_until only works with standalone macros. This means that + .Po blah Pc +will hang until .Pc in encountered. + +* Provide default macros for Bd/Ed + +* The reference implementation is uncomplete + +=cut + +package Mdoc; +use strict; +use warnings; +use List::Util qw(reduce); +use Text::ParseWords qw(quotewords); +use Carp; +use Exporter qw(import); +our @EXPORT_OK = qw(ns pp soff son stoggle hs mapwords gen_encloser nl); + +use constant { + ns => ['nospace'], + soff => ['spaceoff'], + son => ['spaceon'], + stoggle => ['spacetoggle'], + hs => ['hardspace'], +}; + +sub pp { + my $c = shift; + return ['pp', $c ]; +} +sub gen_encloser { + my ($o, $c) = @_; + return sub { ($o, ns, @_, ns, pp($c)) }; +} + +sub mapwords(&@) { + my ($f, @l) = @_; + my @res; + for my $el (@l) { + local $_ = $el; + push @res, $el =~ /^(?:[,\.\{\}\(\):;\[\]\|])$/ || ref $el eq 'ARRAY' ? + $el : $f->(); + } + return @res; +} + +my %macros; + +############################################################################### + +# Default macro definitions start + +############################################################################### + +def_macro('Xo', sub { @_ }, concat_until => '.Xc'); + +def_macro('.Ns', sub {ns, @_}); +def_macro('Ns', sub {ns, @_}); + +{ + my %reference; + def_macro('.Rs', sub { () } ); + def_macro('.%A', sub { + if ($reference{authors}) { + $reference{authors} .= " and @_" + } + else { + $reference{authors} = "@_"; + } + return (); + }); + def_macro('.%T', sub { $reference{title} = "@_"; () } ); + def_macro('.%O', sub { $reference{optional} = "@_"; () } ); + + sub set_Re_callback { + my ($sub) = @_; + croak 'Not a CODE reference' if not ref $sub eq 'CODE'; + def_macro('.Re', sub { + my @ret = $sub->(\%reference); + %reference = (); @ret + }); + return; + } +} + +def_macro('.Bl', sub { die '.Bl - no list callback set' }); +def_macro('.It', sub { die ".It called outside of list context - maybe near line $." }); +def_macro('.El', sub { die '.El requires .Bl first' }); + + +{ + my $elcb = sub { () }; + + sub set_El_callback { + my ($sub) = @_; + croak 'Not a CODE reference' if ref $sub ne 'CODE'; + $elcb = $sub; + return; + } + + sub set_Bl_callback { + my ($blcb, %defs) = @_; + croak 'Not a CODE reference' if ref $blcb ne 'CODE'; + def_macro('.Bl', sub { + + my $orig_it = get_macro('.It'); + my $orig_el = get_macro('.El'); + my $orig_bl = get_macro('.Bl'); + my $orig_elcb = $elcb; + + # Restore previous .It and .El on each .El + def_macro('.El', sub { + def_macro('.El', delete $orig_el->{run}, %$orig_el); + def_macro('.It', delete $orig_it->{run}, %$orig_it); + def_macro('.Bl', delete $orig_bl->{run}, %$orig_bl); + my @ret = $elcb->(@_); + $elcb = $orig_elcb; + @ret + }); + $blcb->(@_) + }, %defs); + return; + } +} + +def_macro('.Sm', sub { + my ($arg) = @_; + if (defined $arg) { + space($arg); + } else { + space() eq 'off' ? + space('on') : + space('off'); + } + () +} ); +def_macro('Sm', do { my $off; sub { + my ($arg) = @_; + if (defined $arg && $arg =~ /^(on|off)$/) { + shift; + if ($arg eq 'off') { soff, @_; } + elsif ($arg eq 'on') { son, @_; } + } + else { + stoggle, @_; + } +}} ); + +############################################################################### + +# Default macro definitions end + +############################################################################### + +sub def_macro { + croak 'Odd number of elements for hash argument <'.(scalar @_).'>' if @_%2; + my ($macro, $sub, %def) = @_; + croak 'Not a CODE reference' if ref $sub ne 'CODE'; + + $macros{ $macro } = { + run => $sub, + greedy => delete $def{greedy} || 0, + raw => delete $def{raw} || 0, + concat_until => delete $def{concat_until}, + }; + if ($macros{ $macro }{concat_until}) { + $macros{ $macros{ $macro }{concat_until} } = { run => sub { @_ } }; + $macros{ $macro }{greedy} = 1; + } + return; +} + +sub get_macro { + my ($macro) = @_; + croak "Macro <$macro> not defined" if not exists $macros{ $macro }; + +{ %{ $macros{ $macro } } } +} + +#TODO: document this +sub parse_opts { + my %args; + my $last; + for (@_) { + if ($_ =~ /^\\?-/) { + s/^\\?-//; + $args{$_} = 1; + $last = _unquote($_); + } + else { + $args{$last} = _unquote($_) if $last; + undef $last; + } + } + return %args; +} + +sub _is_control { + my ($el, $expected) = @_; + if (defined $expected) { + ref $el eq 'ARRAY' and $el->[0] eq $expected; + } + else { + ref $el eq 'ARRAY'; + } +} + +{ + my $sep = ' '; + + sub to_string { + if (@_ > 0) { + # Handle punctunation + my ($in_brace, @punct) = ''; + my @new = map { + if (/^([\[\(])$/) { + ($in_brace = $1) =~ tr/([/)]/; + $_, ns + } + elsif (/^([\)\]])$/ && $in_brace eq $1) { + $in_brace = ''; + ns, $_ + } + elsif ($_ =~ /^[,\.;:\?\!\)\]]$/) { + push @punct, ns, $_; + (); + } + elsif (_is_control($_, 'pp')) { + $_->[1] + } + elsif (_is_control($_)) { + $_ + } + else { + splice (@punct), $_; + } + } @_; + push @new, @punct; + + # Produce string out of an array dealing with the special control characters + # space('off') must but one character delayed + my ($no_space, $space_off) = 1; + my $res = ''; + while (defined(my $el = shift @new)) { + if (_is_control($el, 'hardspace')) { $no_space = 1; $res .= ' ' } + elsif (_is_control($el, 'nospace')) { $no_space = 1; } + elsif (_is_control($el, 'spaceoff')) { $space_off = 1; } + elsif (_is_control($el, 'spaceon')) { space('on'); } + elsif (_is_control($el, 'spacetoggle')) { space() eq 'on' ? + $space_off = 1 : + space('on') } + else { + if ($no_space) { + $no_space = 0; + $res .= "$el" + } + else { + $res .= "$sep$el" + } + + if ($space_off) { space('off'); $space_off = 0; } + } + } + $res + } + else { + ''; + } + } + + sub space { + my ($arg) = @_; + if (defined $arg && $arg =~ /^(on|off)$/) { + $sep = ' ' if $arg eq 'on'; + $sep = '' if $arg eq 'off'; + return; + } + else { + return $sep eq '' ? 'off' : 'on'; + } + } +} + +sub _unquote { + my @args = @_; + $_ =~ s/^"([^"]+)"$/$1/g for @args; + wantarray ? @args : $args[0]; +} + +sub call_macro { + my ($macro, @args) = @_; + my @ret; + + my @newargs; + my $i = 0; + + @args = _unquote(@args) if (!$macros{ $macro }{raw}); + + # Call any callable macros in the argument list + for (@args) { + if ($_ =~ /^[A-Z][a-z]+$/ && exists $macros{ $_ }) { + push @ret, call_macro($_, @args[$i+1 .. $#args]); + last; + } else { + if ($macros{ $macro }{greedy}) { + push @ret, $_; + } + else { + push @newargs, $_; + } + } + $i++; + } + + if ($macros{ $macro }{concat_until}) { + my ($n_macro, @n_args) = (''); + while (1) { + die "EOF was reached and no $macros{ $macro }{concat_until} found" + if not defined $n_macro; + ($n_macro, @n_args) = parse_line(undef, sub { push @ret, shift }); + if ($n_macro eq $macros{ $macro }{concat_until}) { + push @ret, call_macro($n_macro, @n_args); + last; + } + else { + $n_macro =~ s/^\.//; + push @ret, call_macro($n_macro, @n_args) if exists $macros{ $n_macro }; + } + } + } + + if ($macros{ $macro }{greedy}) { + #print "MACROG $macro (", (join ', ', @ret), ")\n"; + return $macros{ $macro }{run}->(@ret); + } + else { + #print "MACRO $macro (", (join ', ', @newargs), ")".(join ', ', @ret)."\n"; + return $macros{ $macro }{run}->(@newargs), @ret; + } +} + +{ + my ($in_fh, $out_sub, $preprocess_sub); + sub parse_line { + $in_fh = $_[0] if defined $_[0] || !defined $in_fh; + $out_sub = $_[1] if defined $_[1] || !defined $out_sub; + $preprocess_sub = $_[2] if defined $_[2] || !defined $preprocess_sub; + + croak 'out_sub not a CODE reference' + if not ref $out_sub eq 'CODE'; + croak 'preprocess_sub not a CODE reference' + if defined $preprocess_sub && not ref $preprocess_sub eq 'CODE'; + + while (my $line = <$in_fh>) { + chomp $line; + if ($line =~ /^\.[A-z][a-z0-9]+/ || $line =~ /^\.%[A-Z]/ || + $line =~ /^\.\\"/) + { + $line =~ s/ +/ /g; + my ($macro, @args) = quotewords(' ', 1, $line); + @args = grep { defined $_ } @args; + $preprocess_sub->(@args) if defined $preprocess_sub; + if ($macro && exists $macros{ $macro }) { + return ($macro, @args); + } else { + $out_sub->($line); + } + } + else { + $out_sub->($line); + } + } + return; + } +} + +1; +__END__ diff --git a/contrib/ntp/sntp/ag-tpl/0-old/agman-cmd.tpl b/contrib/ntp/sntp/ag-tpl/0-old/agman-cmd.tpl new file mode 100644 index 000000000..6d937e468 --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/agman-cmd.tpl @@ -0,0 +1,58 @@ +[+: -*- Mode: nroff -*- + + AutoGen5 template man + +## agman-cmd.tpl -- Template for command line man pages +## +## This file is part of AutoOpts, a companion to AutoGen. +## AutoOpts is free software. +## Copyright (C) 1992-2013 Bruce Korb - all rights reserved +## +## AutoOpts is available under any one of two licenses. The license +## in use must be one of these two and the choice is under the control +## of the user of the license. +## +## The GNU Lesser General Public License, version 3 or later +## See the files "COPYING.lgplv3" and "COPYING.gplv3" +## +## The Modified Berkeley Software Distribution License +## See the file "COPYING.mbsd" +## +## These files have the following sha256 sums: +## +## 8584710e9b04216a394078dc156b781d0b47e1729104d666658aecef8ee32e95 COPYING.gplv3 +## 4379e7444a0e2ce2b12dd6f5a52a27a4d02d39d247901d3285c88cf0d37f477b COPYING.lgplv3 +## 13aa749a5b0a454917a944ed8fffc530b784f5ead522b1aacaf4ec8aa55a6239 COPYING.mbsd + +# Produce a man page for section 1, 5 or 8 commands. +# Which is selected via: -DMAN_SECTION=n +# passed to the autogen invocation. "n" may have a suffix, if desired. +# +:+][+: + +(define head-line (lambda() + (sprintf ".TH %s %s \"%s\" \"%s\" \"%s\"\n.\\\"\n" + (get "prog-name") man-sect + (shell "date '+%d %b %Y'") package-text section-name) )) + +(define man-page #t) +(out-push-new) :+][+: + +INCLUDE "mdoc-synopsis.tlib" :+][+: +INCLUDE "cmd-doc.tlib" :+][+: + +INVOKE build-doc :+][+: + + (shell (string-append + "fn='" (find-file "mdoc2man") "'\n" + "test -f ${fn} || die mdoc2man not found from $PWD\n" + "${fn} <<\\_EndOfMdoc_ || die ${fn} failed in $PWD\n" + (out-pop #t) + "\n_EndOfMdoc_" )) + +:+][+: + +(out-move (string-append (get "prog-name") "." + man-sect)) :+][+: + +agman-cmd.tpl ends here :+] diff --git a/contrib/ntp/sntp/ag-tpl/0-old/agmdoc-cmd.tpl b/contrib/ntp/sntp/ag-tpl/0-old/agmdoc-cmd.tpl new file mode 100644 index 000000000..cc56ffe84 --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/agmdoc-cmd.tpl @@ -0,0 +1,46 @@ +[+: -*- Mode: nroff -*- + + AutoGen5 template mdoc + +## agman-cmd.tpl -- Template for command line mdoc pages +## +## This file is part of AutoOpts, a companion to AutoGen. +## AutoOpts is free software. +## AutoOpts is Copyright (C) 1992-2013 by Bruce Korb - all rights reserved +## +## AutoOpts is available under any one of two licenses. The license +## in use must be one of these two and the choice is under the control +## of the user of the license. +## +## The GNU Lesser General Public License, version 3 or later +## See the files "COPYING.lgplv3" and "COPYING.gplv3" +## +## The Modified Berkeley Software Distribution License +## See the file "COPYING.mbsd" +## +## These files have the following sha256 sums: +## +## 8584710e9b04216a394078dc156b781d0b47e1729104d666658aecef8ee32e95 COPYING.gplv3 +## 4379e7444a0e2ce2b12dd6f5a52a27a4d02d39d247901d3285c88cf0d37f477b COPYING.lgplv3 +## 13aa749a5b0a454917a944ed8fffc530b784f5ead522b1aacaf4ec8aa55a6239 COPYING.mbsd + +# Produce a man page for section 1, 5 or 8 commands. +# Which is selected via: -DMAN_SECTION=n +# passed to the autogen invocation. "n" may have a suffix, if desired. +# +:+][+: + +(define head-line (lambda() (string-append + ".Dd " (shell "date '+%B %e %Y' | sed 's/ */ /g'") + "\n.Dt " UP-PROG-NAME " " man-sect " " section-name + "\n.Os\n") )) + +(define man-page #f) :+][+: + +INCLUDE "mdoc-synopsis.tlib" :+][+: +INCLUDE "cmd-doc.tlib" :+][+: +INVOKE build-doc :+][+: + +(out-move (string-append + (get "prog-name") "." man-sect)) :+][+: +agmdoc-cmd.tpl ends here :+] diff --git a/contrib/ntp/sntp/ag-tpl/0-old/cmd-doc.tlib b/contrib/ntp/sntp/ag-tpl/0-old/cmd-doc.tlib new file mode 100644 index 000000000..0f4c50c10 --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/cmd-doc.tlib @@ -0,0 +1,1079 @@ +[+: -*- Mode: nroff -*- + + AutoGen5 template man + +# cmd-doc.tlib -- Template for command line man/mdoc pages +# +# This file is part of AutoOpts, a companion to AutoGen. +# AutoOpts is free software. +# Copyright (C) 1992-2013 Bruce Korb - all rights reserved +# +# AutoOpts is available under any one of two licenses. The license +# in use must be one of these two and the choice is under the control +# of the user of the license. +# +# The GNU Lesser General Public License, version 3 or later +# See the files "COPYING.lgplv3" and "COPYING.gplv3" +# +# The Modified Berkeley Software Distribution License +# See the file "COPYING.mbsd" +# +# These files have the following sha256 sums: +# +# 8584710e9b04216a394078dc156b781d0b47e1729104d666658aecef8ee32e95 COPYING.gplv3 +# 4379e7444a0e2ce2b12dd6f5a52a27a4d02d39d247901d3285c88cf0d37f477b COPYING.lgplv3 +# 13aa749a5b0a454917a944ed8fffc530b784f5ead522b1aacaf4ec8aa55a6239 COPYING.mbsd + +# Produce a man page for section 1, 5, 6 or 8 commands. Which is +# selected via: -DMAN_SECTION=n. "n" may have a suffix, if desired. +# These sections have default section names that may be overridden +# with -DSECTIN_NAME=XX, also passed to the autogen invocation. +# +:+][+: + + ;;# START-BUILDTREE-ISMS + ;; + (shell "CLexe=${AGexe%/agen5/*}/columns/columns + test -x \"${CLexe}\" || { + CLexe=${AGexe%/autogen}/columns + test -x \"${CLexe}\" || die 'columns program is not findable' + }") + +:+][+: # END-BUILDTREE-ISMS + +(shell "CLexe=`echo ${AGexe} | sed 's@/autogen@/columns@'` + test -x \"${CLexe}\" || CLexe=`which columns`") + +# END-INSTALL-ONLY-CODE :+][+: + +(define down-prog-name (string-downcase! (get "prog-name"))) +(define UP-PROG-NAME (get-up-name "prog-name")) + +(define command-doc #t) +(define tmp-val (getenv "MAN_SECTION")) +(define man-sect (if (exist? "cmd-section") (get "cmd-section") "1")) +(define file-name "") +(define sect-name "") +(define macro-name "") +(define tmp-str "") +(define fname-line "") +(define use-flags (exist? "flag.value")) +(define named-mode (not (or use-flags (exist? "long-opts") ))) + +(if (defined? 'tmp-val) + (if (string? tmp-val) + (set! man-sect tmp-val))) + +(define section-name + (if (=* man-sect "1") "User Commands" + (if (=* man-sect "5") "File Formats" + (if (=* man-sect "6") "Games" + (if (=* man-sect "8") "System Management" + (error + "the agman-cmd template only produces section 1, 5, 6 and 8 man pages") +))))) +(set! tmp-val (getenv "SECTION_NAME")) +(if (defined? 'tmp-val) (if (string? tmp-val) + (set! section-name tmp-val) )) + +(define package-text "") +(define package+version (and (exist? "package") (exist? "version"))) + +(if (or (exist? "package") (exist? "version")) (begin + (set! package-text (string-append + (get "package") + (if package+version " (" "") + (get "version") + (if package+version ")" "") )) +) ) + +(define name-to-fname (lambda (nm) + (string-tr (string-downcase nm) " " "-") )) + +(define sect-line-fname (lambda () (begin + (out-push-new file-name) + (emit (string-append ".Sh \"" sect-name "\"\n")) + (string-append "mk-" macro-name) ))) + +(make-tmp-dir) + +(define home-rc-files (exist? "homerc")) +(define home-rc-text + "\nSee \\fBOPTION PRESETS\\fP for configuration files.") + +(define environ-init (exist? "environrc")) +(define environ-text + "\nSee \\fBOPTION PRESETS\\fP for configuration environment variables.") + +(emit (head-line)) +(dne ".\\\" ") :+] +.Sh NAME +.Nm [+: prog-name :+] +.Nd [+: prog-title :+] +[+: INCLUDE "tpl-config.tlib" :+][+:# + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" B U I L D D O C +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE build-doc :+][+: + +(if (not command-doc) (begin + (set! home-rc-files #f) + (set! home-rc-text "") +) ) :+][+: + +INVOKE doc-sections :+][+: +INVOKE ao-sections :+][+: +INVOKE assemble-sections :+][+: + +ENDDEF build-doc + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" A S S E M B L E S E C T I O N S +.\" +.\" Emit the files for each section that was provided, and do conversions +.\" +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE assemble-sections :+][+: + +(out-push-new) + +:+][+: +#.\" Insert the sections in the prescribed order +#.\" Ensure a newline between them all. We strip blank lines, +#.\" so extra blank lines get removed. +#:+] +cvt_prog='[+: + + (define target-form (if man-page "man" "mdoc")) + (define source-form (get "option-format" "texi")) + (define converter (string-append source-form "2" target-form )) + (set! tmp-str (find-file converter)) + + (if (not (defined? 'tmp-str)) + (error (string-append "cannot locate " converter))) + tmp-str +:+]' +cvt_prog=`cd \`dirname "$cvt_prog"\` >/dev/null && pwd + `/`basename "$cvt_prog"` +cd $tmp_dir +test -x "$cvt_prog" || die "'$cvt_prog' is not executable" +{ + list='synopsis description options option-presets' + for f in $list ; do cat $f ; echo ; done + rm -f $list name + list='implementation-notes environment files examples exit-status errors + compatibility see-also conforming-to history authors copyright bugs + notes' + for f in $list ; do cat $f ; echo ; done > .end-doc + rm -f $list + list=`ls -1 *`' .end-doc' + for f in $list ; do cat $f ; echo ; done + rm -f $list +} 1>.doc 2>/dev/null +[+: +IF (exist? "doc-sub") :+][+: + (out-push-new (string-append tmp-dir "/.cmds")) :+][+: + FOR doc-sub :+][+: + + IF (define field-name (get "sub-type" target-form)) + (~~ target-form field-name) :+][+: + + (set! field-name (get "sub-name")) + (define rep-string (string-append "<<" field-name ">>")) + (emit (string-substitute (get "sub-text") rep-string (get field-name))) + "\n" + + :+][+: ENDIF :+][+: + + ENDFOR doc-sub :+][+: + + (out-pop) + (define post-proc-cmd (string-append + (get "doc-sub-cmd" "sed -f %s %s") " | " + egrep-prog " -v '^[ ]*$' | $cvt_prog")) + (sprintf post-proc-cmd ".cmds" ".doc") + :+][+: +ELSE \:+] +[+:(. egrep-prog):+] -v '^[ ]*$' .doc | $cvt_prog[+: +ENDIF doc-sub exists :+][+: + +(shell (out-pop #t)) :+][+: + +ENDDEF assemble-sections + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" D O C S E C T I O N S +.\" +.\" Emit the files for each section that was provided. +.\" If multiple sections exist, they get glued together with ".Pp" +.\" between them. +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE doc-sections :+][+: + +FOR doc-section :+][+: + IF + (define sec-type (string-upcase (get "ds-type"))) + (define sec-name (name-to-fname sec-type)) + (define cvt-fn (find-file (string-append + (get "ds-format" "man") "2mdoc"))) + (if (not (defined? 'cvt-fn)) + (error (sprintf "Cannot locate converter for %s" + (get "ds-format" "man")))) + + (define sec-file (string-append tmp-dir "/" sec-name)) + (access? sec-file R_OK) :+][+: + (out-push-add sec-file) + (emit ".Pp\n") :+][+: + + ELSE :+][+: CASE + (out-push-new sec-file) + sec-type :+][+: + + == "" :+][+: (error "unnamed doc-section") :+][+: + *==* " " :+].Sh "[+: (. sec-type) :+]"[+: + * :+].Sh [+: (. sec-type) :+][+: + ESAC :+][+: + ENDIF :+] +[+: + (shell (string-append + "fn='" cvt-fn "'\n" + "test -f ${fn} || die ${fn} not found from $PWD\n" + "${fn} <<\\_EndOfDocSection_ || die ${fn} failed in $PWD\n" + (get "ds-text") + "\n_EndOfDocSection_" + )) :+][+: + + CASE (emit "\n") sec-type :+][+: + == FILES :+][+: + (if home-rc-files (emit home-rc-text)) + (set! home-rc-files #f) :+][+: + + == ENVIRONMENT :+][+: + (if environ-init (emit environ-text)) + (set! environ-init #f) :+][+: + ESAC :+][+: + + (out-pop) + :+][+: + +ENDFOR doc-section :+][+: + +ENDDEF doc-sections + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" A O S E C T I O N S +.\" +.\" Emit the files for the sections that these templates augment, +.\" replace or conditionally replace +.\" +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE ao-sections :+][+: + IF (. command-doc) :+][+: + INVOKE cond-section sec = "OPTIONS" mode = "replace" :+][+: + INVOKE cond-section sec = "EXIT STATUS" mode = "insert" :+][+: + + IF (or home-rc-files environ-init) :+][+: + INVOKE cond-section sec = "OPTION PRESETS" mode = "replace" :+][+: + + IF (. home-rc-files) :+][+: + INVOKE cond-section sec = "FILES" mode = "append" :+][+: + ENDIF :+][+: + + IF (. environ-init) :+][+: + INVOKE cond-section sec = "ENVIRONMENT" mode = "append" :+][+: + ENDIF :+][+: + ENDIF :+][+: + + ELSE section 5, not command :+][+: + INVOKE cond-section sec = "FILES" mode = "append" :+][+: + ENDIF section 5/not :+][+: + + INVOKE cond-section sec = "SYNOPSIS" mode = "alt" :+][+: + INVOKE cond-section sec = "DESCRIPTION" mode = "append" :+][+: + INVOKE cond-section sec = "AUTHORS" mode = "alt" :+][+: + INVOKE cond-section sec = "BUGS" mode = "append" :+][+: + INVOKE cond-section sec = "NOTES" mode = "append" :+][+: + +IF (exist? "copyright") :+][+: + INVOKE cond-section sec = "COPYRIGHT" mode = "alt" :+][+: +ENDIF :+][+: + +ENDDEF ao-sections + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" C O N D I T I O N A L S E C T I O N +.\" +.\" Figure out what to do for AutoOpts required sections, depending on "mode" +.\" In all cases, if the file does not exist, invoke the "mk" macro to create +.\" a new file. If it does exist, then: +.\" +.\" alt Alternate -- emit no text +.\" replace throw away any pre-existing file. +.\" append invoke the "append" macro to emit additional text +.\" insert save the current contents, replacing the .Sh line with .Pp. +.\" invoke the "mk" macro then emit the saved text +.\" +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE cond-section :+][+: + + IF + (set! sect-name (string-upcase! (string-substitute + (get "sec") "-" " " ))) + (set! macro-name (string-downcase! (string-substitute + sect-name " " "-" ))) + (set! file-name (string-append tmp-dir "/" macro-name)) + + (not (access? file-name R_OK)) :+][+: + + INVOKE (sect-line-fname) :+][+: + + ELSE file exists :+][+: + + CASE (get "mode") :+][+: + + == replace :+][+: + INVOKE (sect-line-fname) :+][+: + + == append :+][+: + (out-push-add file-name) :+][+: + INVOKE (string-append "append-" macro-name) :+][+: + + == insert :+][+: + (set! fname-line (shellf + "sed '1s/.Sh .*/.Pp/' %1$s ; rm -f %1$s" file-name)) :+][+: + INVOKE (sect-line-fname) :+][+: + + == alt :+][+: + (out-push-new) :+][+: + + * :+][+: + (error (sprintf "invalid section type: %s" (get "mode"))) + + :+][+: + ESAC :+][+: + + ENDIF file existence/non-existence :+][+: + (out-pop) :+][+: # All paths open out :+][+: +ENDDEF cond-section + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - D E S C R I P T I O N +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-description :+][+: + + (out-push-new) + (emit + (if (exist? "prog-man-descrip") + (stack-join "\n.Pp\n" "prog-man-descrip") + (if (exist? "detail") + (stack-join "\n.Pp\n" "detail") + "There is no description for this command." + ) ) ) + (shell "sed 's/^$/.sp/' <<\\_EODesc_\n" (out-pop #t) "\n_EODesc_") + + :+][+: + INVOKE append-description :+][+: + +ENDDEF mk-description + +.\" = = = = = = = = = = = = = = = = = = +.\" A P P E N D - D E S C R I P T I O N +.\" = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE append-description :+][+: + +IF (= (get "main.main-type") "for-each"):+][+: + + CASE main.handler-type :+][+: + ~* ^(name|file)|.*text \:+] +.Pp +This program will perform its function for every file named on the command +line or every file named in a list read from stdin. The arguments or input +names must be pre\-existing files. The input list may contain comments, +which[+: + + !E \:+] +.Pp +This program will perform its function for every command line argument +or every non\-comment line in a list read from stdin. +The input list comments[+: + + * :+][+: + (error "the 'for-each' main has in invalid handler-type.") :+][+: + ESAC \:+] + are blank lines or lines beginning with a '[+: + ?% comment-char "%s" "#" :+]' character. +[+: + +ENDIF - "main" is of "for-each" type :+][+: + +ENDDEF append-description + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - O P T I O N S +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-options + +:+][+: + +(define opt-arg "") +(define dis-name "") +(define opt-name "") +(define optname-from "A-Z_^") +(define optname-to "a-z--") +(define cvt-cmd "") +(define formatted-doc (exist? "option-format")) + +(if formatted-doc (begin + (out-push-new) + (set! cvt-cmd (string-append (get "option-format") "2mdoc")) +) ) + +(if (exist? "preserve-case") + (begin + (set! optname-from "_^") + (set! optname-to "--") +) ) + +(define fix-optname (lambda (o_nm) (begin + (set! o_nm (string-tr o_nm optname-from optname-to)) + (set! o_nm (string-substitute o_nm "-" "\\-" )) + o_nm ))) + +(if (exist? "option-info") + (string-append ".Pp\n" (get "option-info") "\n") ) +\:+] +.Bl -tag[+: + +FOR flag :+][+: + IF (not (exist? "documentation")) :+][+: + IF (exist? "aliases") :+][+: + INVOKE emit-alias-opt :+][+: + ELSE :+][+: + INVOKE emit-flag-text :+][+: + ENDIF :+][+: + + ELSE :+] +.Ss "[+: (get "descrip" "") :+]"[+: +(set! tmp-str (get "documentation" "")) +(if (> (string-length tmp-str) 3) (string-append + "\n" tmp-str "\n" )) :+][+: + + ENDIF :+][+: +ENDFOR flag + +.\" = = = = = = = = = = = = = = = = = +.\" help option +.\" = = = = = = = = = = = = = = = = = + +:+] +.It [+: + (define tmp-val (get "help-value" "\\&?")) + (if (and use-flags (> (string-length tmp-val) 0)) + (string-append "Fl " tmp-val + (if (exist? "long-opts") " , Fl -help" "") ) + (string-append (if (exist? "long-opts") "Fl -" "") "help" ) + ) \:+] + +Display usage information and exit.[+:# + +.\" = = = = = = = = = = = = = = = = = +.\" more-help option +.\" = = = = = = = = = = = = = = = = = :+][+: + + IF (not (exist? "no-libopts")) :+] +.It [+: + (define tmp-val (get "more-help-value" "\\&!")) + (if (and use-flags (> (string-length tmp-val) 0)) + (string-append "Fl " tmp-val + (if (exist? "long-opts") " , Fl -more-help" "") ) + (string-append (if (exist? "long-opts") "Fl -" "") "more-help" ) + ) \:+] + +Pass the extended usage information through a pager.[+: + +ENDIF no no-libopts + +.\" = = = = = = = = = = = = = = = = = +.\" save and load configuration +.\" = = = = = = = = = = = = = = = = = :+][+: + +IF (exist? "homerc") :+] +.It [+: + + IF (not (exist? "disable-save")) :+][+: + + (define tmp-val (get "save-opts-value" ">")) + (if (and use-flags (> (string-length tmp-val) 0)) + (string-append "Fl " tmp-val " Oo Ar cfgfile Oc" + (if (exist? "long-opts") + " , Fl -save-opts Oo Ns = Ns Ar cfgfile Oc" ) "") + (string-append (if (exist? "long-opts") "Fl -" "") + "save-opts Oo Ns = Ns Ar cfgfile Oc" ) + ) \:+] + +Save the option state to \fIcfgfile\fP. The default is the \fIlast\fP +configuration file listed in the \fBOPTION PRESETS\fP section, below. +The command will exit after updating the config file. +.It [+: + ENDIF saving not disabled :+][+: + + (define tmp-val (get "load-opts-value" "<")) + (define tmp-str (if (exist? "long-opts") "Fl -" "")) + + (if (and use-flags (> (string-length tmp-val) 0)) + (string-append "Fl " tmp-val " Ar cfgfile" + (if (exist? "long-opts") + (string-append " , " tmp-str "load-opts Ns = Ns Ar cfgfile" + " , " tmp-str "no-load-opts" ) + "") ) + (string-append tmp-str "load-opts Ns = Ns Ar cfgfile , " + tmp-str "no-load-opts" ) + ) \:+] + +Load options from \fIcfgfile\fP. +The \fIno-load-opts\fP form will disable the loading +of earlier config/rc/ini files. \fI\-\-no-load-opts\fP is handled early, +out of order.[+: + +ENDIF (exist? "homerc") + +.\" = = = = = = = = = = = = = = = = = +.\" version +.\" = = = = = = = = = = = = = = = = = :+][+: + +IF (exist? "version") :+] +.It [+: + + (define tmp-val (get "version-value" "v")) + (if (and use-flags (> (string-length tmp-val) 0)) + (string-append "Fl " tmp-val " Op Brq Ar v|c|n" + (if (exist? "long-opts") + " Fl -version Op Brq Ar v|c|n" ) "") + (string-append (if (exist? "long-opts") "Fl -" "") + "version Op Brq Ar v|c|n" ) + ) \:+] + +Output version of program and exit. The default mode is `v', a simple +version. The `c' mode will print copyright information and `n' will +print the full copyright notice.[+: +ENDIF :+] +.El +[+: + +(if formatted-doc + (shell (string-append + "fn='" (find-file cvt-cmd) + "'\ntest -f ${fn} || die '" cvt-cmd " not found'\n" + "${fn} <<\\_EndOfMdoc_ || die ${fn} failed in $PWD\n" + (out-pop #t) + "\n_EndOfMdoc_" )) ) :+][+: + +ENDDEF mk-options + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - O P T I O N - P R E S E T S +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-option-presets \:+] +Any option that is not marked as \fInot presettable\fP may be preset +by loading values from [+: + IF (. home-rc-files) + :+]configuration ("RC" or ".INI") file(s)[+: + IF (. environ-init) :+] and values from +[+: + ENDIF :+][+: + ENDIF :+][+: + IF (. environ-init) :+]environment variables named: +.nf + \fB[+:(. UP-PROG-NAME):+]_\fP or \fB[+:(. UP-PROG-NAME):+]\fP +.fi +.ad[+: + IF (. home-rc-files) :+] +The environmental presets take precedence (are processed later than) +the configuration files.[+: + ENDIF :+][+: + ELSE :+].[+: + ENDIF :+][+: + + CASE + (define rc-file + (get "rcfile" (string-append "." (get "prog-name") "rc")) ) + (count "homerc") :+][+: + + == "0" :+][+: + == "1" :+][+: + + CASE homerc :+][+: + ~~ '\.|\$HOME' :+] +The file "\fI[+: (string-append (get "homerc") "/" rc-file) +:+]\fP" will be used, if present.[+: + + == "" :+][+: + + * :+] +The \fIhomerc\fP file is "\fI[+:homerc:+]\fP", unless that is a directory. +In that case, the file "\fI[+: (. rc-file) :+]\fP" +is searched for within that directory.[+: + ESAC :+][+: + + * :+] +The \fIhomerc\fP files are [+: + FOR homerc ", " :+][+: + IF (last-for?) :+]and [+: + ENDIF :+]"\fI[+: homerc :+]\fP"[+: ENDFOR :+]. +If any of these are directories, then the file \fI[+: (. rc-file) :+]\fP +is searched for within those directories.[+: + ESAC :+][+: + +ENDDEF mk-option-presets + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - E X I T - S T A T U S +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-exit-status \:+] +One of the following exit values will be returned: +.Bl -tag +[+: +(ag-fprintf 0 ".It 0 \" (EXIT_%s)\"\n%s\n" + (string->c-name! (string-upcase (get "exit-name[0]" "SUCCESS"))) + (get "exit-desc[0]" "Successful program execution.") ) + +(define need-ex-noinput (exist? "homerc")) +(define need-ex-software #t) + +(ag-fprintf 0 ".It 1 \" (EXIT_%s)\"\n%s\n" + (string->c-name! (string-upcase (get "exit-name[1]" "FAILURE"))) + (get "exit-desc[1]" + "The operation failed or the command syntax was not valid.")) :+][+: + +FOR exit-desc (for-from 2) :+][+: + (if (= (for-index) 66) + (set! need-ex-noinput #f) + (if (= (for-index) 70) + (set! need-ex-software #f) )) + + (set! tmp-str (get (sprintf "exit-name[%d]" (for-index)) "* unnamed *")) + (sprintf ".It %d \" (EXIT_%s)\"\n%s\n" + (for-index) + (string-upcase (string->c-name! tmp-str)) + (get "exit-desc" "")) :+][+: +ENDFOR exit-desc :+][+: +(if need-ex-noinput + (emit ".It 66 \" (EX_NOINPUT)\" +A specified configuration file could not be loaded.\n")) + +(if need-ex-software + (emit ".It 70 \" (EX_SOFTWARE)\" +libopts had an internal operational error. Please report +it to autogen-users@lists.sourceforge.net. Thank you.\n")) + +(if (> (string-length fname-line) 1) + (emit fname-line)) :+] +.El +[+: + +ENDDEF mk-exit-status + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - A U T H O R S +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-authors :+][+: + + (define remove-authors #t) + + (set! tmp-val + (if (exist? "copyright.author") + (stack-join ",\n" "copyright.author") + (stack-join ",\n" "copyright.owner") )) + + (if (> (string-length tmp-val) 1) + (string-append tmp-val "\n") + (delete-file file-name)) + + :+][+: + +ENDDEF mk-authors + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - B U G S +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-bugs :+][+: + + (set! tmp-val (get "copyright.eaddr" (get "eaddr"))) + (if (> (string-length tmp-val) 1) + (string-append "Please send bug reports to: " tmp-val "\n") + (delete-file file-name) ) + :+][+: + +ENDDEF mk-bugs :+][+: + +DEFINE append-bugs :+][+: + + (set! tmp-val (get "copyright.eaddr" (get "eaddr"))) + (if (> (string-length tmp-val) 1) + (string-append "\n.Pp\nPlease send bug reports to: " tmp-val "\n") ) + :+][+: + +ENDDEF append-bugs + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - C O P Y R I G H T (+ licensing) +.\" +.\" This section is guaranteed to be the last section in the man page +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-copyright \:+] +Copyright (C) [+: copyright.date :+] [+: + (get "copyright.owner" (get "copyright.author" (get "copyright.eaddr"))) + :+] all rights reserved. +[+: CASE (get "copyright.type") :+][+: + = note :+][+: (get "copyright.text") :+][+: + == '' :+]This program has an unspecified license.[+: + + * :+][+: + (string-append "This program is released under the terms of " + (license-name (get "copyright.type")) ".") :+][+: + + ESAC :+] +[+: +ENDDEF mk-copyright + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - N O T E S +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-notes \:+] +This manual page was \fIAutoGen\fP-erated from the \fB[+: prog-name :+]\fP +option definitions. +[+: + +ENDDEF mk-notes + +.\" = = = = = APPEND TO IT: :+][+: + +DEFINE append-notes :+] +.Pp +This manual page was \fIAutoGen\fP-erated from the \fB[+: prog-name :+]\fP +option definitions.[+: + +ENDDEF append-notes + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - E N V I R O N M E N T +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-environment :+][+: + INVOKE append-environment :+][+: +ENDDEF mk-environment + +.\" = = = = = APPEND TO IT: :+][+: + +DEFINE append-environment :+] +[+:(. environ-text) :+][+: +ENDDEF append-environment + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" M K - F I L E S +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE mk-files :+][+: + INVOKE append-files :+][+: +ENDDEF mk-files + +.\" = = = = = APPEND TO IT: :+][+: + +DEFINE append-files :+] +[+:(. home-rc-text) :+][+: +ENDDEF append-files + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" E M I T A L I A S O P T +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE emit-alias-opt :+] +.It [+: + IF (exist? "value") :+][+: + IF (exist? "long-opts") \:+] + Fl [+:value:+] , Fl \-[+: name :+][+: + ELSE \:+] + Fl [+:value:+][+: + ENDIF (exist? "long-opts") :+][+: + + ELSE value does not exist -- named option only :+][+: + + IF (not (exist? "long-opts")) \:+] + [+: name :+][+: + ELSE \:+] + Fl \-[+: (get "name") :+][+: + ENDIF :+][+: + ENDIF :+] +This is an alias for the \fI--[+: aliases :+]\fR option.[+: + IF (exist? "deprecated") :+] +.sp +.B +NOTE: THIS OPTION IS DEPRECATED +[+: + ENDIF :+][+: +ENDDEF emit-alias-opt + +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +.\" E M I T F L A G T E X T +.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+: + +DEFINE emit-flag-text :+][+: + + (if (exist? "enable") + (set! opt-name (string-append (get "enable") "-" (get "name"))) + (set! opt-name (get "name")) ) + (if (exist? "disable") + (set! dis-name (string-append (get "disable") "-" (get "name"))) + (set! dis-name "") ) + + (set! opt-name (fix-optname opt-name)) + (if (> (string-length dis-name) 0) + (set! dis-name (fix-optname dis-name)) ) + + (if (not (exist? "arg-type")) + (set! opt-arg "") + (set! opt-arg (string-append "Ar " + (fix-optname (if (exist? "arg-name") + (get "arg-name") + (string-downcase! (get "arg-type")) )) + )) + ) + +:+] +.It [+: + IF (exist? "value") :+][+: + IF (exist? "long-opts") :+][+: + + # * * * * * * * * * * * * * * * * * * * * + * + * The option has a flag value (character) AND + * the program uses long options + * + \:+] + Fl [+:value:+][+: + IF (not (exist? "arg-type")) :+] , Fl -[+: + ELSE :+] [+:(. opt-arg):+] , Fl -[+: + ENDIF :+][+: (. opt-name) :+] [+: + IF (exist? "arg-type") :+][+: + ? arg-optional Oo Ns = Ns + :+] [+: (. opt-arg) :+] [+: + arg-optional Oc :+][+: + ENDIF :+][+: + IF (exist? "disable") :+] , Fl -[+:(. dis-name):+][+: + ENDIF :+][+: + + ELSE :+][+: + + # * * * * * * * * * * * * * * * * * * * * + * + * The option has a flag value (character) BUT + * the program does _NOT_ use long options + * + \:+] + Fl [+:value:+] [+: + IF (exist? "arg-type") :+][+: + arg-optional Oo :+] [+:(. opt-arg):+] [+: + arg-optional Oc :+] [+: + ENDIF " :+][+: + ENDIF (exist? "long-opts") :+][+: + + + ELSE value does not exist -- named option only :+][+: + + IF (not (exist? "long-opts")) :+][+: + + # * * * * * * * * * * * * * * * * * * * * + * + * The option does not have a flag value (character). + * The program does _NOT_ use long options either. + * Special magic: All arguments are named options. + * + \:+] + [+: (. opt-name) :+] [+: + IF (exist? "arg-type") :+] [+: + ? arg-optional ' Oo = Ns' ' Ns = Ns ' + :+] [+:(. opt-arg) :+] [+: + arg-optional Oc :+] [+: + ENDIF:+][+: + IF (exist? "disable") :+] , Fl -[+:(. dis-name):+][+: + ENDIF :+][+: + + + ELSE :+][+: + # * * * * * * * * * * * * * * * * * * * * + * + * The option does not have a flag value (character). + * The program, instead, only accepts long options. + * + \:+] + Fl -[+: (. opt-name) :+] [+: + + IF (exist? "arg-type") :+][+: + arg-optional Oo :+] Ns = Ns [+:(. opt-arg):+] [+: + arg-optional Oc :+][+: + ENDIF :+][+: + + IF (exist? "disable") + :+], " Fl \-[+:(. dis-name):+]"[+: + ENDIF :+][+: + ENDIF :+][+: + ENDIF :+] +[+: (get "descrip" "") :+].[+: + + IF (exist? "min") :+] +This option is required to appear.[+: + ENDIF :+][+: + + IF (exist? "max") :+] +This option may appear [+: + IF % max (= "%s" "NOLIMIT") + :+]an unlimited number of times[+:ELSE + :+]up to [+: max :+] times[+: + ENDIF:+].[+: + ENDIF:+][+: + + IF (exist? "disable") :+] +The \fI[+:(. dis-name):+]\fP form will [+: + IF (exist? "stack-arg") + :+]clear the list of option arguments[+: + ELSE :+]disable the option[+: + ENDIF :+].[+: + ENDIF:+][+: + + IF (exist? "enabled") :+] +This option is enabled by default.[+: + ENDIF :+][+: + + IF (exist? "no-preset") :+] +This option may not be preset with environment variables +or in initialization (rc) files.[+: + ENDIF :+][+: + + IF (and (exist? "default") named-mode) :+] +This option is the default option.[+: + ENDIF :+][+: + + IF (exist? "equivalence") :+] +This option is a member of the [+:equivalence:+] class of options.[+: + ENDIF :+][+: + + IF (exist? "flags-must") :+] +This option must appear in combination with the following options: +[+: FOR flags-must ", " :+][+:flags-must:+][+:ENDFOR:+].[+: + ENDIF :+][+: + + IF (exist? "flags-cant") :+] +This option must not appear in combination with any of the following options: +[+: FOR flags-cant ", " :+][+:flags-cant:+][+:ENDFOR:+].[+: + ENDIF :+][+: + + + IF (~* (get "arg-type") "key|set") :+] +This option takes a keyword as its argument[+: + + IF (=* (get "arg-type") "set") + +:+] list. Each entry turns on or off +membership bits. The bits are set by name or numeric value and cleared +by preceding the name or number with an exclamation character ('!'). +They can all be cleared with the magic name \fInone\fR and they can all be set +with +.IR all . +A single option will process a list of these values.[+: + + ELSE + +:+]. The argument sets an enumeration value that can +be tested by comparing them against the option value macro.[+: + + ENDIF + +:+] +The available keywords are: +.in +4 +.nf +.na +[+: (shellf "${CLexe} --indent='' --spread=1 -W50 <<_EOF_\n%s\n_EOF_" + (join "\n" (stack "keyword")) ) :+] +.fi +or their numeric equivalent. +.in -4[+: (if (exist? "arg-default") "\n.sp" ) :+][+: + + ELIF (=* (get "arg-type") "num") :+] +This option takes an integer number as its argument.[+: + + IF (exist? "arg-range") :+] +The value of +.[+:(. opt-arg):+] +is constrained to being: +.in +4 +.nf +.na[+:FOR arg_range ", or" :+] +[+: (shellf " +range='%s' + +case \"X${range}\" in +X'->'?* ) + echo \"less than or equal to\" ` + echo $range | sed 's/->//' ` ;; + +X?*'->' ) + echo \"greater than or equal to\" ` + echo $range | sed 's/->.*//' ` ;; + +X?*'->'?* ) + echo \"in the range \" ` + echo $range | sed 's/->/ through /' ` ;; + +X?* ) + echo exactly $range ;; + +X* ) echo $range is indeterminate +esac" + +(get "arg-range") ) +:+][+: + ENDFOR arg-range :+] +.fi +.in -4[+: + + ENDIF arg-range exists :+][+: + + ENDIF arg-type key/set/num :+][+: + + IF (exist? "arg-default") :+] +The default +.[+: (. opt-arg) :+] +for this option is: +.ti +4 + [+: (join " + " (stack "arg-default" )) :+][+: + ENDIF :+] +.sp +[+: + (if (exist? "doc") (string-substitute (get "doc" "") "\n\n" "\n.sp\n") + "This option has not been fully documented." ) :+][+: + IF (exist? "deprecated") :+] +.sp +.B +NOTE: THIS OPTION IS DEPRECATED +[+: + ENDIF :+][+: + +ENDDEF emit-flag-text + +.\" cmd-doc.tlib ends here \:+] diff --git a/contrib/ntp/sntp/ag-tpl/0-old/mdoc-synopsis.tlib b/contrib/ntp/sntp/ag-tpl/0-old/mdoc-synopsis.tlib new file mode 100644 index 000000000..35fe05bbd --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/mdoc-synopsis.tlib @@ -0,0 +1,92 @@ +[+: autogen5 template man :+][+: +DEFINE mk-synopsis :+][+: + (out-push-new file-name) \:+] +.Sh SYNOPSIS +.Nm[+: + + IF (. use-flags) :+][+: + IF (exist? "long-opts") :+] +.\" Mixture of short (flag) options and long options +.Op Fl flags +.Op Fl flag Op Ar value +.Op Fl \-option-name Ns Oo Oo Ns "=| " Oc Ns Ar value Oc +[+: ELSE no long options: :+] +.Op Fl flags +.Op Fl flag Op Ar value +[+: ENDIF + :+][+: + ELIF (exist? "long-opts") + :+] +.Op Fl \-option-name +.Op Fl \-option-name Ar value +[+: + + ELIF (not (exist? "argument")) :+] +.Op Ar option\-name Ar value +.Pp +All arguments are named options. +[+: + ENDIF :+][+: + + IF (exist? "argument") :+][+: + argument :+][+: + + IF (exist? "reorder-args") :+] +.Pp +Operands and options may be intermixed. They will be reordered. +[+: ENDIF :+][+: + + ELIF (or (exist? "long-opts") use-flags) + +:+] +.Pp +All arguments must be options. +[+: + + ENDIF :+][+: + + IF (exist? "main") :+][+: + CASE main.main-type :+][+: + == shell-process :+] +.Pp +This program will emit text that is expected to be evaluated by +a Bourne-compatible shell, thus digesting the options for the script.[+: + + == shell-parser :+] +.Pp +This program is designed to produce output suitable for inclusion +into a shell script that will parse the options described.[+: + + == for-each :+] +.Pp +The operands that this program operates on may be specified either +on the command line or read from standard input, one per line. +In that input, leading and trailing white space is stripped, +blank lines are ignored[+: + + IF (define comment-char (get "comment-char" "#")) + (> (string-length comment-char) 1) \:+] + and lines beginning with the character +.I [+: (substring comment-char 1 0):+] +are treated as comments[+: + ENDIF :+].[+: + + IF (exist? "interleaved") :+] +Options may be interleaved with operands both on the command +line and when operands are read from standard input.[+: + ENDIF interleaved + +:+] +Standard input may not be a terminal.[+: + + ESAC main-type :+][+: + ENDIF main exists :+] +.Pp +[+: + +FOR explain "\n.Pp\n" :+][+: + (get "explain" "") :+][+: +ENDFOR :+][+: + +(out-pop) :+][+: +ENDDEF mk-synopsis :+] diff --git a/contrib/ntp/sntp/ag-tpl/0-old/mdoc2man b/contrib/ntp/sntp/ag-tpl/0-old/mdoc2man new file mode 100755 index 000000000..459505900 --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/mdoc2man @@ -0,0 +1,193 @@ +#!/usr/bin/perl + +### ToDo +# Properly implement -columns in the "my %lists" definition... +# +# .Xr requires at least 1 arg, the code here expects at least 2 +### + +package mdoc2man; +use strict; +use warnings; +use File::Basename; +use lib dirname(__FILE__); +use Mdoc qw(hs ns pp mapwords son soff stoggle gen_encloser); + +######## +## Basic +######## + +Mdoc::def_macro( '.Sh', sub { '.SH', hs, @_ }, raw => 1); +Mdoc::def_macro( '.Ss', sub { '.SS', hs, @_ }, raw => 1); +Mdoc::def_macro( '.Pp', sub { ".sp \\n(Ppu\n.ne 2\n" } ); +Mdoc::def_macro( '.Nd', sub { "\\- @_" } ); + +# Macros that enclose things +Mdoc::def_macro( '.Brq', gen_encloser(qw({ })) , greedy => 1 ); +Mdoc::def_macro( '.Op' , gen_encloser(qw([ ])) , greedy => 1 ); +Mdoc::def_macro( '.Qq' , gen_encloser(qw(" ")) , greedy => 1 ); +Mdoc::def_macro( '.Dq' , gen_encloser(qw(\*[Lq] \*[Rq])), greedy => 1 ); +Mdoc::def_macro( '.Ql' , gen_encloser(qw(\[oq] \[cq])) , greedy => 1 ); +Mdoc::def_macro( '.Sq' , gen_encloser(qw(\[oq] \[cq])) , greedy => 1 ); +Mdoc::def_macro( '.Pq' , gen_encloser(qw/( )/) , greedy => 1 ); +Mdoc::def_macro( '.D1' , sub { ".in +4\n", ns, @_ , ns , "\n.in -4" } , greedy => 1); + +Mdoc::def_macro( 'Oo', sub { '[', @_ } ); +Mdoc::def_macro( 'Oc', sub { ']', @_ } ); + +Mdoc::def_macro( 'Po', sub { '(', @_} ); +Mdoc::def_macro( 'Pc', sub { ')', @_ } ); + +Mdoc::def_macro( 'Bro', sub { '{', ns, @_ } ); +Mdoc::def_macro( 'Brc', sub { '}', @_ } ); + +Mdoc::def_macro( '.Oo', gen_encloser(qw([ ])), concat_until => '.Oc' ); +Mdoc::def_macro( '.Bro', gen_encloser(qw({ })), concat_until => '.Brc' ); +Mdoc::def_macro( '.Po', gen_encloser(qw/( )/), concat_until => '.Pc' ); + +Mdoc::def_macro( '.Ev', sub { @_ } ); +Mdoc::def_macro( '.An', sub { ".NOP ", @_, "\n.br" }, raw => 1 ); +Mdoc::def_macro( '.Li', sub { mapwords {"\\f[C]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Cm', sub { mapwords {"\\f\\*[B-Font]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Ic', sub { mapwords {"\\f\\*[B-Font]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Fl', sub { mapwords {"\\f\\*[B-Font]\\-$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Ar', sub { mapwords {"\\f\\*[I-Font]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Em', sub { mapwords {"\\fI$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Va', sub { mapwords {"\\fI$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Sx', sub { mapwords {"\\fI$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Xr', sub { "\\fC".(shift)."\\fR(".(shift).")\\f[]", @_ } ); +Mdoc::def_macro( '.Fn', sub { "\\f\\*[B-Font]".(shift)."\\fR()\\f[]" } ); +Mdoc::def_macro( '.Fn', sub { "\\fB".(shift)."\\fR()\\f[]" } ); +Mdoc::def_macro( '.Fx', sub { "FreeBSD", @_ } ); +Mdoc::def_macro( '.Ux', sub { "UNIX", @_ } ); + +Mdoc::def_macro( '.No', sub { ".NOP", map { ($_, ns) } @_ } ); +Mdoc::def_macro( '.Pa', sub { mapwords {"\\fI$_\\f[]"} @_; } ); +{ + my $name; + Mdoc::def_macro('.Nm', sub { + $name = shift if (!$name); + "\\f\\*[B-Font]$name\\fP", @_ + } ); +} + +######## +## lists +######## + +my %lists = ( + bullet => sub { + Mdoc::def_macro('.It', sub { '.IP \fB\(bu\fP 2' }); + }, + + column => sub { + Mdoc::def_macro('.It', sub { '.IP \fB\(bu\fP 2' }); + }, + + tag => sub { + my (%opts) = @_; + + my $width = ''; + + if (exists $opts{width}) { + $width = ' '.((length $opts{width})+1); + } + + if (exists $opts{compact}) { + my $dobrns = 0; + Mdoc::def_macro('.It', sub { + my @ret = (".TP$width\n.NOP", hs); + if ($dobrns) { + ".br\n.ns\n", ns, @ret, @_; + } + else { + $dobrns = 1; + @ret, @_; + } + }, raw => 1); + } + else { + Mdoc::def_macro('.It', sub { + ".TP$width\n.NOP", hs, @_ + }, raw => 1); + } + }, +); + +Mdoc::set_Bl_callback(do { my $nested = 0; sub { + my $type = shift; + my %opts = Mdoc::parse_opts(@_); + if (defined $type && $type =~ /-(\w+)/ && exists $lists{$1}) { + + # Wrap nested lists with .RS and .RE + Mdoc::set_El_callback(sub { + return '.RE' if $nested-- > 1; + return '.PP'; + }); + + $lists{$1}->(%opts); + + if ($nested++) { + return ".RS"; + } + else { + return (); + } + } + else { + die "Invalid list type <$type>"; + } +}}, raw => 1); + +# don't bother with arguments for now and do what mdoc2man'.sh' did + +Mdoc::def_macro('.Bd', sub { ".br\n.in +4\n.nf" } ); +Mdoc::def_macro('.Ed', sub { ".in -4\n.fi" } ); + +Mdoc::set_Re_callback(sub { + my ($reference) = @_; + <<"REF"; +$reference->{authors}, +\\fI$reference->{title}\\fR, +$reference->{optional}\n.PP +REF +}); + +# Define all macros which have the same sub for inline and standalone macro +for (qw(Xr Em Ar Fl Ic Cm Qq Op Nm Pa Sq Li Va Brq Pq Fx Ux)) { + my $m = Mdoc::get_macro(".$_"); + Mdoc::def_macro($_, delete $m->{run}, %$m); +} + +sub print_line { + print shift; + print "\n"; +} + +sub run { + print <<'DEFS'; +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +DEFS + + while (my ($macro, @args) = Mdoc::parse_line(\*STDIN, \&print_line)) { + my @ret = Mdoc::call_macro($macro, @args); + print_line(Mdoc::to_string(@ret)) if @ret; + } + return 0; +} + +exit run(@ARGV) unless caller; + +1; +__END__ diff --git a/contrib/ntp/sntp/ag-tpl/0-old/mdoc2texi b/contrib/ntp/sntp/ag-tpl/0-old/mdoc2texi new file mode 100755 index 000000000..e4966ad08 --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/mdoc2texi @@ -0,0 +1,162 @@ +#! /usr/bin/perl + +### To Do: + +# the Bl -column command needs work: +# - support for "-offset" +# - support for the header widths + +# + +### + +package mdoc2texi; +use strict; +use warnings; +use File::Basename qw(dirname); +use lib dirname(__FILE__); +use Mdoc qw(ns pp hs mapwords gen_encloser nl); + +# Ignore commments +Mdoc::def_macro( '.\"', sub { () } ); + +# Enclosers +Mdoc::def_macro( '.An', sub { @_, ns, '@*' } ); +Mdoc::def_macro( '.Aq', gen_encloser(qw(< >)), greedy => 1); +Mdoc::def_macro( '.Bq', gen_encloser(qw([ ])), greedy => 1); +Mdoc::def_macro( '.Brq', gen_encloser(qw(@{ @})), greedy => 1); +Mdoc::def_macro( '.Pq', gen_encloser(qw/( )/), greedy => 1); +Mdoc::def_macro( '.Qq', gen_encloser(qw(" ")), greedy => 1); +Mdoc::def_macro( '.Op', gen_encloser(qw(@code{[ ]})), greedy => 1); +Mdoc::def_macro( '.Ql', gen_encloser(qw(@quoteleft{} @quoteright{})), + greedy => 1); +Mdoc::def_macro( '.Sq', gen_encloser(qw(@quoteleft{} @quoteright{})), + greedy => 1); +Mdoc::def_macro( '.Dq', gen_encloser(qw(@quotedblleft{} @quotedblright{})), + greedy => 1); +Mdoc::def_macro( '.Eq', sub { + my ($o, $c) = (shift, pop); + gen_encloser($o, $c)->(@_) +}, greedy => 1); +Mdoc::def_macro( '.D1', sub { "\@example\n", ns, @_, ns, "\n\@end example" }, + greedy => 1); +Mdoc::def_macro( '.Dl', sub { "\@example\n", ns, @_, ns, "\n\@end example" }, + greedy => 1); + +Mdoc::def_macro( '.Oo', gen_encloser(qw(@code{[ ]})), concat_until => '.Oc'); +Mdoc::def_macro( 'Oo', sub { '@code{[', ns, @_ } ); +Mdoc::def_macro( 'Oc', sub { @_, ns, pp(']}') } ); + +Mdoc::def_macro( '.Bro', gen_encloser(qw(@code{@{ @}})), concat_until => '.Brc'); +Mdoc::def_macro( 'Bro', sub { '@code{@{', ns, @_ } ); +Mdoc::def_macro( 'Brc', sub { @_, ns, pp('@}}') } ); + +Mdoc::def_macro( '.Po', gen_encloser(qw/( )/), concat_until => '.Pc'); +Mdoc::def_macro( 'Po', sub { '(', @_ } ); +Mdoc::def_macro( 'Pc', sub { @_, ')' } ); + +Mdoc::def_macro( '.Ar', sub { mapwords {"\@kbd{$_}"} @_ } ); +Mdoc::def_macro( '.Fl', sub { mapwords {"\@code{-$_}"} @_ } ); +Mdoc::def_macro( '.Cm', sub { mapwords {"\@code{-$_}"} @_ } ); +Mdoc::def_macro( '.Ic', sub { mapwords {"\@code{$_}"} @_ } ); +Mdoc::def_macro( '.Cm', sub { mapwords {"\@code{$_}"} @_ } ); +Mdoc::def_macro( '.Li', sub { mapwords {"\@code{$_}"} @_ } ); +Mdoc::def_macro( '.Va', sub { mapwords {"\@code{$_}"} @_ } ); +Mdoc::def_macro( '.Em', sub { mapwords {"\@emph{$_}"} @_ } ); +Mdoc::def_macro( '.Fn', sub { '@code{'.(shift).'()}' } ); +Mdoc::def_macro( '.Ss', sub { "\@subsubsection", hs, @_ }); +Mdoc::def_macro( '.Sh', sub { + my $name = "@_"; + "\@node", hs, "$name\n", ns, "\@subsection", hs, $name + }); +Mdoc::def_macro( '.Ss', sub { "\@subsubsection", hs, @_ }); +Mdoc::def_macro( '.Xr', sub { '@code{'.(shift).'('.(shift).')}', @_ } ); +Mdoc::def_macro( '.Sx', gen_encloser(qw(@ref{ })) ); +Mdoc::def_macro( '.Ux', sub { '@sc{unix}', @_ } ); +Mdoc::def_macro( '.Fx', sub { '@sc{freebsd}', @_ } ); +{ + my $name; + Mdoc::def_macro('.Nm', sub { + $name = shift || $ENV{AG_DEF_PROG_NAME} || 'XXX' if (!$name); + "\@code{$name}" + } ); +} +Mdoc::def_macro( '.Pa', sub { mapwords {"\@file{$_}"} @_ } ); +Mdoc::def_macro( '.Pp', sub { '' } ); + +# Setup references + +Mdoc::def_macro( '.Rs', sub { "\@*\n", @_ } ); +Mdoc::set_Re_callback(sub { + my ($reference) = @_; + "@*\n", ns, $reference->{authors}, ',', "\@emph{$reference->{title}}", + ',', $reference->{optional} + }); + +# Set up Bd/Ed + +my %displays = ( + literal => [ '@verbatim', '@end verbatim' ], +); + +Mdoc::def_macro( '.Bd', sub { + (my $type = shift) =~ s/^-//; + die "Not supported display type <$type>" + if not exists $displays{ $type }; + + my $orig_ed = Mdoc::get_macro('.Ed'); + Mdoc::def_macro('.Ed', sub { + Mdoc::def_macro('.Ed', delete $orig_ed->{run}, %$orig_ed); + $displays{ $type }[1]; + }); + $displays{ $type }[0] + }); +Mdoc::def_macro('.Ed', sub { die '.Ed used but .Bd was not seen' }); + +# Set up Bl/El + +my %lists = ( + bullet => [ '@itemize @bullet', '@end itemize' ], + tag => [ '@table @asis', '@end table' ], + column => [ '@table @asis', '@end table' ], +); + +Mdoc::set_Bl_callback(sub { + my $type = shift; + die "Specify a list type" if not defined $type; + $type =~ s/^-//; + die "Not supported list type <$type>" if not exists $lists{ $type }; + Mdoc::set_El_callback(sub { $lists{ $type }[1] }); + $lists{ $type }[0] + }); +Mdoc::def_macro('.It', sub { '@item', hs, @_ }); + +for (qw(Aq Bq Brq Pq Qq Ql Sq Dq Eq Ar Fl Ic Pa Op Cm Li Fx Ux Va)) { + my $m = Mdoc::get_macro(".$_"); + Mdoc::def_macro($_, delete $m->{run}, %$m); +} + +sub print_line { + my $s = shift; + $s =~ s/\\&//g; + print "$s\n"; +} + +sub preprocess_args { + $_ =~ s/([{}])/\@$1/g for @_; +} + +sub run { + while (my ($macro, @args) = Mdoc::parse_line(\*STDIN, \&print_line, + \&preprocess_args) + ) { + my @ret = Mdoc::call_macro($macro, @args); + if (@ret) { + my $s = Mdoc::to_string(@ret); + print_line($s); + } + } + return 0; +} + +exit run(@ARGV) unless caller; diff --git a/contrib/ntp/sntp/ag-tpl/0-old/perlopt.tpl b/contrib/ntp/sntp/ag-tpl/0-old/perlopt.tpl new file mode 100644 index 000000000..c4fd69583 --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/0-old/perlopt.tpl @@ -0,0 +1,188 @@ +[= AutoGen5 template foo=(base-name) -*- Mode: scheme -*-=] +[= + +(emit (dne "# ")) + +(if (not (and (exist? "prog-name") (exist? "prog-title") (exist? "version"))) + (error "prog-name and prog-title are required")) +(define prog-name (get "prog-name")) + +(if (> (string-length prog-name) 16) + (error (sprintf "prog-name limited to 16 characters: %s" + prog-name)) ) +(if (not (exist? "long-opts")) + (error "long-opts is required")) + +;; perl list containing string to initialize the option hash +(define perl_opts "") +;; perl list containing option definitions for Getopt::Long +(define perl_defs " ") +;; usage string +(define perl_usage "") + +(define optname-from "A-Z_^") +(define optname-to "a-z--") +(define counter 0) + +(define q (lambda (s) (string-append "'" s "'"))) +(define qp (lambda (s) (string-append "q{" s "}"))) + +=][= + +FOR flag =][= + +(define optarg "") ;; the option argument for Getopt::Long +(define opttarget "''") ;; the value of a hash key that represents option +(define optargname "") +(define optisarray #f) +(define optname (string-tr! (get "name") optname-from optname-to)) + +=][= # +;; since autoopts doesn't support float we take the combination arg-name = +;; float and arg-type = string as float +=][= + IF arg-type =][= + CASE arg-type =][= + + =* num =][= (set! optarg "=i") =][= + + =* str =][= + (if (and (exist? "arg-name") (== (get "arg-name") "float")) + (set! optarg "=f") + (set! optarg "=s") + ) =][= + + * =][= + (error (string-append "unknown arg type '" + (get "arg-type") "' for " (get "name"))) =][= + ESAC arg-type =][= + ENDIF =][= + +(if (exist? "stack-arg") + ;; set optarget to array reference if can take more than one value + ;; FIXME: if "max" exists, then just presume it is greater than 1 + ;; + (if (and (exist? "max") (== (get "max") "NOLIMIT")) + (begin + (set! opttarget (string-append + "[" + (if (exist? "arg-default") (q (get "arg-default")) "") + "]" + ) + ) + (set! optisarray #t) + ) + (error "If stack-arg then max has to be NOLIMIT") + ) + ;; just scalar otherwise + (if (exist? "arg-default") (set! opttarget (q (get "arg-default")))) +) + +(set! perl_opts (string-append perl_opts + "'" (get "name") "' => " opttarget ",\n ")) + +(define def_add (string-append "'" optname (if (exist? "value") + (string-append "|" (get "value")) "") optarg "',")) + +(define add_len (+ (string-length def_add) counter)) +(if (> add_len 80) + (begin + (set! perl_defs (string-append perl_defs "\n " def_add)) + (set! counter 8) + ) + (begin + (set! perl_defs (string-append perl_defs " " def_add)) + (set! counter (+ counter add_len)) + ) +) + +(if (exist? "arg-type") + (if (and (exist? "arg-name") (== (get "arg-name") "float")) + (set! optargname "=float") + (set! optargname (string-append "=" (substring (get "arg-type") 0 3))) + ) + (set! optargname " ") +) + +(if (not (exist? "deprecated")) + (set! perl_usage (string-append perl_usage + (sprintf "\n %-28s %s" (string-append + (if (exist? "value") (string-append "-" (get "value") ",") " ") + " --" + (get "name") + optargname) + (get "descrip")) +) ) ) +(if optisarray + (set! perl_usage (string-append perl_usage + "\n - may appear multiple times")) +) + +=][= + +ENDFOR each "flag" =] + +use Getopt::Long qw(GetOptionsFromArray); +Getopt::Long::Configure(qw(no_auto_abbrev no_ignore_case_always)); + +my $usage; + +sub usage { + my ($ret) = @_; + print STDERR $usage; + exit $ret; +} + +sub paged_usage { + my ($ret) = @_; + my $pager = $ENV{PAGER} || '(less || more)'; + + open STDOUT, "| $pager" or die "Can't fork a pager: $!"; + print $usage; + + exit $ret; +} + +sub processOptions { + my $args = shift; + + my $opts = { + [= (. perl_opts) =]'help' => '', 'more-help' => '' + }; + my $argument = '[= argument =]'; + my $ret = GetOptionsFromArray($args, $opts, ( +[= (. perl_defs) =] + 'help|?', 'more-help')); + + $usage = <<'USAGE'; +[= prog-name =] - [= prog-title =] - Ver. [= version =] +USAGE: [= prog-name =] [ - [] | --[{=| }] ]... [= argument =] +[= (. perl_usage) =] + -?, --help Display usage information and exit + --more-help Pass the extended usage information through a pager + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. +USAGE + + usage(0) if $opts->{'help'}; + paged_usage(0) if $opts->{'more-help'};[= + +CASE argument =][= +!E =][= +==* "[" =][= +* =] + + if ($argument && $argument =~ /^[^\[]/ && !@$args) { + print STDERR "Not enough arguments supplied (See --help/-?)\n"; + exit 1; + }[= + +ESAC + +=] + $_[0] = $opts; + return $ret; +} + +END { close STDOUT }; diff --git a/contrib/ntp/sntp/ag-tpl/Mdoc.pm b/contrib/ntp/sntp/ag-tpl/Mdoc.pm new file mode 100644 index 000000000..549454f0f --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/Mdoc.pm @@ -0,0 +1,542 @@ +=begin comment + +## Mdoc.pm -- Perl functions for mdoc processing +## +## Author: Oliver Kindernay (GSoC project for NTP.org) +## +## +## This file is part of AutoOpts, a companion to AutoGen. +## AutoOpts is free software. +## AutoOpts is Copyright (C) 1992-2015 by Bruce Korb - all rights reserved +## +## AutoOpts is available under any one of two licenses. The license +## in use must be one of these two and the choice is under the control +## of the user of the license. +## +## The GNU Lesser General Public License, version 3 or later +## See the files "COPYING.lgplv3" and "COPYING.gplv3" +## +## The Modified Berkeley Software Distribution License +## See the file "COPYING.mbsd" +## +## These files have the following sha256 sums: +## +## 8584710e9b04216a394078dc156b781d0b47e1729104d666658aecef8ee32e95 COPYING.gplv3 +## 4379e7444a0e2ce2b12dd6f5a52a27a4d02d39d247901d3285c88cf0d37f477b COPYING.lgplv3 +## 13aa749a5b0a454917a944ed8fffc530b784f5ead522b1aacaf4ec8aa55a6239 COPYING.mbsd +=end comment +=head1 NAME + +Mdoc - perl module to parse Mdoc macros + +=head1 SYNOPSIS + + use Mdoc qw(ns pp soff son stoggle mapwords); + +See mdoc2man and mdoc2texi for code examples. + +=head1 FUNCTIONS + +=over 4 + +=item def_macro( NAME, CODE, [ raw => 1, greedy => 1, concat_until => '.Xx' ] ) + +Define new macro. The CODE reference will be called by call_macro(). You can +have two distinct definitions for and inline macro and for a standalone macro +(i. e. 'Pa' and '.Pa'). + +The CODE reference is passed a list of arguments and is expected to return list +of strings and control characters (see C). + +By default the surrouding "" from arguments to macros are removed, use C +to disable this. + +Normaly CODE reference is passed all arguments up to next nested macro. Set +C to to pass everything up to the end of the line. + +If the concat_until is present, the line is concated until the .Xx macro is +found. For example the following macro definition + + def_macro('.Oo', gen_encloser(qw([ ]), concat_until => '.Oc' } + def_macro('.Cm', sub { mapwords {'($_)'} @_ } } + +and the following input + + .Oo + .Cm foo | + .Cm bar | + .Oc + +results in [(foo) | (bar)] + +=item get_macro( NAME ) + +Returns a hash reference like: + + { run => CODE, raw => [1|0], greedy => [1|0] } + +Where C is the CODE reference used to define macro called C + +=item parse_line( INPUT, OUTPUT_CODE, PREPROCESS_CODE ) + +Parse a line from the C filehandle. If a macro was detected it returns a +list (MACRO_NAME, @MACRO_ARGS), otherwise it calls the C, giving +caller a chance to modify line before printing it. If C is +defined it calls it prior to passing argument to a macro, giving caller a +chance to alter them. if EOF was reached undef is returned. + +=item call_macro( MACRO, ARGS, ... ) + +Call macro C with C. The CODE reference for macro C is +called and for all the nested macros. Every called macro returns a list which +is appended to return value and returned when all nested macros are processed. +Use to_string() to produce a printable string from the list. + +=item to_string ( LIST ) + +Processes C returned from call_macro() and returns formatted string. + +=item mapwords BLOCK ARRAY + +This is like perl's map only it calls BLOCK only on elements which are not +punctuation or control characters. + +=item space ( ['on'|'off] ) + +Turn spacing on or off. If called without argument it returns the current state. + +=item gen_encloser ( START, END ) + +Helper function for generating macros that enclose their arguments. + gen_encloser(qw({ })); +returns + sub { '{', ns, @_, ns, pp('}')} + +=item set_Bl_callback( CODE , DEFS ) + +This module implements the Bl/El macros for you. Using set_Bl_callback you can +provide a macro definition that should be executed on a .Bl call. + +=item set_El_callback( CODE , DEFS ) + +This module implements the Bl/El macros for you. Using set_El_callback you can +provide a macro definition that should be executed on a .El call. + +=item set_Re_callback( CODE ) + +The C is called after a Rs/Re block is done. With a hash reference as a +parameter, describing the reference. + +=back + +=head1 CONSTANTS + +=over 4 + +=item ns + +Indicate 'no space' between to members of the list. + +=item pp ( STRING ) + +The string is 'punctuation point'. It means that every punctuation +preceeding that element is put behind it. + +=item soff + +Turn spacing off. + +=item son + +Turn spacing on. + +=item stoggle + +Toogle spacing. + +=item hs + +Print space no matter spacing mode. + +=back + +=head1 TODO + +* The concat_until only works with standalone macros. This means that + .Po blah Pc +will hang until .Pc in encountered. + +* Provide default macros for Bd/Ed + +* The reference implementation is uncomplete + +=cut + +package Mdoc; +use strict; +use warnings; +use List::Util qw(reduce); +use Text::ParseWords qw(quotewords); +use Carp; +use Exporter qw(import); +our @EXPORT_OK = qw(ns pp soff son stoggle hs mapwords gen_encloser nl); + +use constant { + ns => ['nospace'], + soff => ['spaceoff'], + son => ['spaceon'], + stoggle => ['spacetoggle'], + hs => ['hardspace'], +}; + +sub pp { + my $c = shift; + return ['pp', $c ]; +} +sub gen_encloser { + my ($o, $c) = @_; + return sub { ($o, ns, @_, ns, pp($c)) }; +} + +sub mapwords(&@) { + my ($f, @l) = @_; + my @res; + for my $el (@l) { + local $_ = $el; + push @res, $el =~ /^(?:[,\.\{\}\(\):;\[\]\|])$/ || ref $el eq 'ARRAY' ? + $el : $f->(); + } + return @res; +} + +my %macros; + +############################################################################### + +# Default macro definitions start + +############################################################################### + +def_macro('Xo', sub { @_ }, concat_until => '.Xc'); + +def_macro('.Ns', sub {ns, @_}); +def_macro('Ns', sub {ns, @_}); + +{ + my %reference; + def_macro('.Rs', sub { () } ); + def_macro('.%A', sub { + if ($reference{authors}) { + $reference{authors} .= " and @_" + } + else { + $reference{authors} = "@_"; + } + return (); + }); + def_macro('.%T', sub { $reference{title} = "@_"; () } ); + def_macro('.%O', sub { $reference{optional} = "@_"; () } ); + + sub set_Re_callback { + my ($sub) = @_; + croak 'Not a CODE reference' if not ref $sub eq 'CODE'; + def_macro('.Re', sub { + my @ret = $sub->(\%reference); + %reference = (); @ret + }); + return; + } +} + +def_macro('.Bl', sub { die '.Bl - no list callback set' }); +def_macro('.It', sub { die ".It called outside of list context - maybe near line $." }); +def_macro('.El', sub { die '.El requires .Bl first' }); + + +{ + my $elcb = sub { () }; + + sub set_El_callback { + my ($sub) = @_; + croak 'Not a CODE reference' if ref $sub ne 'CODE'; + $elcb = $sub; + return; + } + + sub set_Bl_callback { + my ($blcb, %defs) = @_; + croak 'Not a CODE reference' if ref $blcb ne 'CODE'; + def_macro('.Bl', sub { + + my $orig_it = get_macro('.It'); + my $orig_el = get_macro('.El'); + my $orig_bl = get_macro('.Bl'); + my $orig_elcb = $elcb; + + # Restore previous .It and .El on each .El + def_macro('.El', sub { + def_macro('.El', delete $orig_el->{run}, %$orig_el); + def_macro('.It', delete $orig_it->{run}, %$orig_it); + def_macro('.Bl', delete $orig_bl->{run}, %$orig_bl); + my @ret = $elcb->(@_); + $elcb = $orig_elcb; + @ret + }); + $blcb->(@_) + }, %defs); + return; + } +} + +def_macro('.Sm', sub { + my ($arg) = @_; + if (defined $arg) { + space($arg); + } else { + space() eq 'off' ? + space('on') : + space('off'); + } + () +} ); +def_macro('Sm', do { my $off; sub { + my ($arg) = @_; + if (defined $arg && $arg =~ /^(on|off)$/) { + shift; + if ($arg eq 'off') { soff, @_; } + elsif ($arg eq 'on') { son, @_; } + } + else { + stoggle, @_; + } +}} ); + +############################################################################### + +# Default macro definitions end + +############################################################################### + +sub def_macro { + croak 'Odd number of elements for hash argument <'.(scalar @_).'>' if @_%2; + my ($macro, $sub, %def) = @_; + croak 'Not a CODE reference' if ref $sub ne 'CODE'; + + $macros{ $macro } = { + run => $sub, + greedy => delete $def{greedy} || 0, + raw => delete $def{raw} || 0, + concat_until => delete $def{concat_until}, + }; + if ($macros{ $macro }{concat_until}) { + $macros{ $macros{ $macro }{concat_until} } = { run => sub { @_ } }; + $macros{ $macro }{greedy} = 1; + } + return; +} + +sub get_macro { + my ($macro) = @_; + croak "Macro <$macro> not defined" if not exists $macros{ $macro }; + +{ %{ $macros{ $macro } } } +} + +#TODO: document this +sub parse_opts { + my %args; + my $last; + for (@_) { + if ($_ =~ /^\\?-/) { + s/^\\?-//; + $args{$_} = 1; + $last = _unquote($_); + } + else { + $args{$last} = _unquote($_) if $last; + undef $last; + } + } + return %args; +} + +sub _is_control { + my ($el, $expected) = @_; + if (defined $expected) { + ref $el eq 'ARRAY' and $el->[0] eq $expected; + } + else { + ref $el eq 'ARRAY'; + } +} + +{ + my $sep = ' '; + + sub to_string { + if (@_ > 0) { + # Handle punctunation + my ($in_brace, @punct) = ''; + my @new = map { + if (/^([\[\(])$/) { + ($in_brace = $1) =~ tr/([/)]/; + $_, ns + } + elsif (/^([\)\]])$/ && $in_brace eq $1) { + $in_brace = ''; + ns, $_ + } + elsif ($_ =~ /^[,\.;:\?\!\)\]]$/) { + push @punct, ns, $_; + (); + } + elsif (_is_control($_, 'pp')) { + $_->[1] + } + elsif (_is_control($_)) { + $_ + } + else { + splice (@punct), $_; + } + } @_; + push @new, @punct; + + # Produce string out of an array dealing with the special control characters + # space('off') must but one character delayed + my ($no_space, $space_off) = 1; + my $res = ''; + while (defined(my $el = shift @new)) { + if (_is_control($el, 'hardspace')) { $no_space = 1; $res .= ' ' } + elsif (_is_control($el, 'nospace')) { $no_space = 1; } + elsif (_is_control($el, 'spaceoff')) { $space_off = 1; } + elsif (_is_control($el, 'spaceon')) { space('on'); } + elsif (_is_control($el, 'spacetoggle')) { space() eq 'on' ? + $space_off = 1 : + space('on') } + else { + if ($no_space) { + $no_space = 0; + $res .= "$el" + } + else { + $res .= "$sep$el" + } + + if ($space_off) { space('off'); $space_off = 0; } + } + } + $res + } + else { + ''; + } + } + + sub space { + my ($arg) = @_; + if (defined $arg && $arg =~ /^(on|off)$/) { + $sep = ' ' if $arg eq 'on'; + $sep = '' if $arg eq 'off'; + return; + } + else { + return $sep eq '' ? 'off' : 'on'; + } + } +} + +sub _unquote { + my @args = @_; + $_ =~ s/^"([^"]+)"$/$1/g for @args; + wantarray ? @args : $args[0]; +} + +sub call_macro { + my ($macro, @args) = @_; + my @ret; + + my @newargs; + my $i = 0; + + @args = _unquote(@args) if (!$macros{ $macro }{raw}); + + # Call any callable macros in the argument list + for (@args) { + if ($_ =~ /^[A-Z][a-z]+$/ && exists $macros{ $_ }) { + push @ret, call_macro($_, @args[$i+1 .. $#args]); + last; + } else { + if ($macros{ $macro }{greedy}) { + push @ret, $_; + } + else { + push @newargs, $_; + } + } + $i++; + } + + if ($macros{ $macro }{concat_until}) { + my ($n_macro, @n_args) = (''); + while (1) { + die "EOF was reached and no $macros{ $macro }{concat_until} found" + if not defined $n_macro; + ($n_macro, @n_args) = parse_line(undef, sub { push @ret, shift }); + if ($n_macro eq $macros{ $macro }{concat_until}) { + push @ret, call_macro($n_macro, @n_args); + last; + } + else { + $n_macro =~ s/^\.//; + push @ret, call_macro($n_macro, @n_args) if exists $macros{ $n_macro }; + } + } + } + + if ($macros{ $macro }{greedy}) { + #print "MACROG $macro (", (join ', ', @ret), ")\n"; + return $macros{ $macro }{run}->(@ret); + } + else { + #print "MACRO $macro (", (join ', ', @newargs), ")".(join ', ', @ret)."\n"; + return $macros{ $macro }{run}->(@newargs), @ret; + } +} + +{ + my ($in_fh, $out_sub, $preprocess_sub); + sub parse_line { + $in_fh = $_[0] if defined $_[0] || !defined $in_fh; + $out_sub = $_[1] if defined $_[1] || !defined $out_sub; + $preprocess_sub = $_[2] if defined $_[2] || !defined $preprocess_sub; + + croak 'out_sub not a CODE reference' + if not ref $out_sub eq 'CODE'; + croak 'preprocess_sub not a CODE reference' + if defined $preprocess_sub && not ref $preprocess_sub eq 'CODE'; + + while (my $line = <$in_fh>) { + chomp $line; + if ($line =~ /^\.[A-z][a-z0-9]+/ || $line =~ /^\.%[A-Z]/ || + $line =~ /^\.\\"/) + { + $line =~ s/ +/ /g; + my ($macro, @args) = quotewords(' ', 1, $line); + @args = grep { defined $_ } @args; + $preprocess_sub->(@args) if defined $preprocess_sub; + if ($macro && exists $macros{ $macro }) { + return ($macro, @args); + } else { + $out_sub->($line); + } + } + else { + $out_sub->($line); + } + } + return; + } +} + +1; +__END__ diff --git a/contrib/ntp/sntp/ag-tpl/mdoc2man b/contrib/ntp/sntp/ag-tpl/mdoc2man new file mode 100755 index 000000000..305fab07b --- /dev/null +++ b/contrib/ntp/sntp/ag-tpl/mdoc2man @@ -0,0 +1,219 @@ +#! /usr/local/bin/perl + +## mdoc2man.pl -- Convert mdoc tags to man tags +## +## Author: Harlan Stenn +## +## +## This file is part of AutoOpts, a companion to AutoGen. +## AutoOpts is free software. +## AutoOpts is Copyright (C) 1992-2015 by Bruce Korb - all rights reserved +## +## AutoOpts is available under any one of two licenses. The license +## in use must be one of these two and the choice is under the control +## of the user of the license. +## +## The GNU Lesser General Public License, version 3 or later +## See the files "COPYING.lgplv3" and "COPYING.gplv3" +## +## The Modified Berkeley Software Distribution License +## See the file "COPYING.mbsd" +## +## These files have the following sha256 sums: +## +## 8584710e9b04216a394078dc156b781d0b47e1729104d666658aecef8ee32e95 COPYING.gplv3 +## 4379e7444a0e2ce2b12dd6f5a52a27a4d02d39d247901d3285c88cf0d37f477b COPYING.lgplv3 +## 13aa749a5b0a454917a944ed8fffc530b784f5ead522b1aacaf4ec8aa55a6239 COPYING.mbsd + +### ToDo +# Properly implement -columns in the "my %lists" definition... +# +# .Xr requires at least 1 arg, the code here expects at least 2 +# +### + +package mdoc2man; +use strict; +use warnings; +use File::Basename; +use lib dirname(__FILE__); +use Mdoc qw(hs ns pp mapwords son soff stoggle gen_encloser); + +######## +## Basic +######## + +Mdoc::def_macro( '.Sh', sub { '.SH', hs, @_ }, raw => 1); +Mdoc::def_macro( '.Ss', sub { '.SS', hs, @_ }, raw => 1); +Mdoc::def_macro( '.Pp', sub { ".sp \\n(Ppu\n.ne 2\n" } ); +Mdoc::def_macro( '.Nd', sub { "\\- @_" } ); + +# Macros that enclose things +Mdoc::def_macro( '.Brq', gen_encloser(qw({ })) , greedy => 1 ); +Mdoc::def_macro( '.Op' , gen_encloser(qw([ ])) , greedy => 1 ); +Mdoc::def_macro( '.Qq' , gen_encloser(qw(" ")) , greedy => 1 ); +Mdoc::def_macro( '.Dq' , gen_encloser(qw(\*[Lq] \*[Rq])), greedy => 1 ); +Mdoc::def_macro( '.Ql' , gen_encloser(qw(\[oq] \[cq])) , greedy => 1 ); +Mdoc::def_macro( '.Sq' , gen_encloser(qw(\[oq] \[cq])) , greedy => 1 ); +Mdoc::def_macro( '.Pq' , gen_encloser(qw/( )/) , greedy => 1 ); +Mdoc::def_macro( '.D1' , sub { ".in +4\n", ns, @_ , ns , "\n.in -4" } , greedy => 1); + +Mdoc::def_macro( 'Oo', sub { '[', @_ } ); +Mdoc::def_macro( 'Oc', sub { ']', @_ } ); + +Mdoc::def_macro( 'Po', sub { '(', @_} ); +Mdoc::def_macro( 'Pc', sub { ')', @_ } ); + +Mdoc::def_macro( 'Bro', sub { '{', ns, @_ } ); +Mdoc::def_macro( 'Brc', sub { '}', @_ } ); + +Mdoc::def_macro( '.Oo', gen_encloser(qw([ ])), concat_until => '.Oc' ); +Mdoc::def_macro( '.Bro', gen_encloser(qw({ })), concat_until => '.Brc' ); +Mdoc::def_macro( '.Po', gen_encloser(qw/( )/), concat_until => '.Pc' ); + +Mdoc::def_macro( '.Ev', sub { @_ } ); +Mdoc::def_macro( '.An', sub { ".NOP ", @_, "\n.br" }, raw => 1 ); +Mdoc::def_macro( '.Li', sub { mapwords {"\\f[C]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Cm', sub { mapwords {"\\f\\*[B-Font]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Ic', sub { mapwords {"\\f\\*[B-Font]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Fl', sub { mapwords {"\\f\\*[B-Font]\\-$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Ar', sub { mapwords {"\\f\\*[I-Font]$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Em', sub { mapwords {"\\fI$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Va', sub { mapwords {"\\fI$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Sx', sub { mapwords {"\\fI$_\\f[]"} @_ } ); +Mdoc::def_macro( '.Xr', sub { "\\fC".(shift)."\\f[]\\fR(".(shift).")\\f[]", @_ } ); +Mdoc::def_macro( '.Fn', sub { "\\f\\*[B-Font]".(shift)."\\f[]\\fR()\\f[]" } ); +Mdoc::def_macro( '.Fn', sub { "\\fB".(shift)."\\f[]\\fR()\\f[]" } ); +Mdoc::def_macro( '.Fx', sub { "FreeBSD", @_ } ); +Mdoc::def_macro( '.Ux', sub { "UNIX", @_ } ); + +Mdoc::def_macro( '.No', sub { ".NOP", map { ($_, ns) } @_ } ); +Mdoc::def_macro( '.Pa', sub { mapwords {"\\fI$_\\f[]"} @_; } ); +{ + my $name; + Mdoc::def_macro('.Nm', sub { + $name = shift if (!$name); + "\\f\\*[B-Font]$name\\fP", @_ + } ); +} + +######## +## lists +######## + +my %lists = ( + bullet => sub { + Mdoc::def_macro('.It', sub { '.IP \fB\(bu\fP 2' }); + }, + + column => sub { + Mdoc::def_macro('.It', sub { '.IP \fB\(bu\fP 2' }); + }, + + tag => sub { + my (%opts) = @_; + + my $width = ''; + + if (exists $opts{width}) { + $width = ' '.((length $opts{width})+1); + } + + if (exists $opts{compact}) { + my $dobrns = 0; + Mdoc::def_macro('.It', sub { + my @ret = (".TP$width\n.NOP", hs); + if ($dobrns) { + ".br\n.ns\n", ns, @ret, @_; + } + else { + $dobrns = 1; + @ret, @_; + } + }, raw => 1); + } + else { + Mdoc::def_macro('.It', sub { + ".TP$width\n.NOP", hs, @_ + }, raw => 1); + } + }, +); + +Mdoc::set_Bl_callback(do { my $nested = 0; sub { + my $type = shift; + my %opts = Mdoc::parse_opts(@_); + if (defined $type && $type =~ /-(\w+)/ && exists $lists{$1}) { + + # Wrap nested lists with .RS and .RE + Mdoc::set_El_callback(sub { + return '.RE' if $nested-- > 1; + return '.PP'; + }); + + $lists{$1}->(%opts); + + if ($nested++) { + return ".RS"; + } + else { + return (); + } + } + else { + die "Invalid list type <$type>"; + } +}}, raw => 1); + +# don't bother with arguments for now and do what mdoc2man'.sh' did + +Mdoc::def_macro('.Bd', sub { ".br\n.in +4\n.nf" } ); +Mdoc::def_macro('.Ed', sub { ".in -4\n.fi" } ); + +Mdoc::set_Re_callback(sub { + my ($reference) = @_; + <<"REF"; +$reference->{authors}, +\\fI$reference->{title}\\fR, +$reference->{optional}\n.PP +REF +}); + +# Define all macros which have the same sub for inline and standalone macro +for (qw(Xr Em Ar Fl Ic Cm Qq Op Nm Pa Sq Li Va Brq Pq Fx Ux)) { + my $m = Mdoc::get_macro(".$_"); + Mdoc::def_macro($_, delete $m->{run}, %$m); +} + +sub print_line { + print shift; + print "\n"; +} + +sub run { + print <<'DEFS'; +.de1 NOP +. it 1 an-trap +. if \\n[.$] \,\\$*\/ +.. +.ie t \ +.ds B-Font [CB] +.ds I-Font [CI] +.ds R-Font [CR] +.el \ +.ds B-Font B +.ds I-Font I +.ds R-Font R +DEFS + + while (my ($macro, @args) = Mdoc::parse_line(\*STDIN, \&print_line)) { + my @ret = Mdoc::call_macro($macro, @args); + print_line(Mdoc::to_string(@ret)) if @ret; + } + return 0; +} + +exit run(@ARGV) unless caller; + +1; +__END__ diff --git a/contrib/ntp/sntp/autogen-version.def b/contrib/ntp/sntp/autogen-version.def deleted file mode 100644 index 89439830e..000000000 --- a/contrib/ntp/sntp/autogen-version.def +++ /dev/null @@ -1,2 +0,0 @@ -#assert (version-compare >= autogen-version "5.9.1") -guard-option-names; diff --git a/contrib/ntp/sntp/bincheck.mf b/contrib/ntp/sntp/bincheck.mf index c67827dde..67f461f8c 100644 --- a/contrib/ntp/sntp/bincheck.mf +++ b/contrib/ntp/sntp/bincheck.mf @@ -3,13 +3,15 @@ # subdir to warn folks if there is another version there. install-exec-hook: - @case ${BINSUBDIR} in \ - bin) ODIR=${exec_prefix}/sbin ;; \ - sbin) ODIR=${exec_prefix}/bin ;; \ - esac; \ - test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ - || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ - test ! -f $$ODIR/$$i || echo "*** $$i is also in $$ODIR!"; \ + @test -z "${bin_PROGRAMS}${bin_SCRIPTS}" \ + || for i in ${bin_PROGRAMS} ${bin_SCRIPTS} " "; do \ + test ! -f ${sbindir}/$$i \ + || echo "*** $$i is also in ${sbindir}!"; \ + done + @test -z "${sbin_PROGRAMS}${asbin_SCRIPTS}" \ + || for i in ${sbin_PROGRAMS} ${sbin_SCRIPTS} " "; do \ + test ! -f ${bindir}/$$i \ + || echo "*** $$i is also in ${bindir}!"; \ done # diff --git a/contrib/ntp/sntp/check-libntp.mf b/contrib/ntp/sntp/check-libntp.mf new file mode 100644 index 000000000..b867a3a9a --- /dev/null +++ b/contrib/ntp/sntp/check-libntp.mf @@ -0,0 +1,15 @@ +## check-libntp.mf - automake fragment +## +## tests/libntp/Makefile.am +## sntp/tests/Makefile.am +## The above files have adaptations of this for deeper nesting. + +BUILT_SOURCES += check-libntp +CLEANFILES += check-libntp + +check-libntp: ../libntp/libntp.a + @echo stamp > $@ + +../libntp/libntp.a: + cd ../libntp && $(MAKE) $(AM_MAKEFLAGS) libntp.a + diff --git a/contrib/ntp/sntp/check-libopts.mf b/contrib/ntp/sntp/check-libopts.mf new file mode 100644 index 000000000..7c79b3fcf --- /dev/null +++ b/contrib/ntp/sntp/check-libopts.mf @@ -0,0 +1,14 @@ +## check-libopts.mf - automake fragment +## +## If we are not using the tearoff libopts, we won't be +## building its libopts.la, so the submake is allowed +## to fail. + +BUILT_SOURCES += check-libopts +CLEANFILES += check-libopts + +check-libopts: libopts/libopts.la + @echo stamp > $@ + +libopts/libopts.la: + -cd libopts && $(MAKE) $(AM_MAKEFLAGS) libopts.la diff --git a/contrib/ntp/sntp/config.guess b/contrib/ntp/sntp/config.guess index 917bbc50f..b02565c7b 100755 --- a/contrib/ntp/sntp/config.guess +++ b/contrib/ntp/sntp/config.guess @@ -1,9 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011 Free Software Foundation, Inc. -timestamp='2005-07-08' +timestamp='2011-06-03' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -26,16 +27,16 @@ timestamp='2005-07-08' # the same distribution terms that you use for the rest of that program. -# Originally written by Per Bothner . -# Please send patches to . Submit a context -# diff and a properly formatted ChangeLog entry. +# Originally written by Per Bothner. Please send patches (context +# diff format) to and include a ChangeLog +# entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # -# The plan is that this can be called by configure scripts if you -# don't specify an explicit build system type. +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD me=`echo "$0" | sed -e 's,.*/,,'` @@ -55,8 +56,9 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free +Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -106,7 +108,7 @@ set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; - { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; @@ -160,6 +162,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; + sh5el) machine=sh5le-unknown ;; *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched @@ -168,7 +171,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep __ELF__ >/dev/null + | grep -q __ELF__ then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? @@ -178,7 +181,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in fi ;; *) - os=netbsd + os=netbsd ;; esac # The OS release @@ -206,8 +209,11 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; + *:SolidBSD:*:*) + echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} + exit ;; macppc:MirBSD:*:*) - echo powerppc-unknown-mirbsd${UNAME_RELEASE} + echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} @@ -218,7 +224,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on @@ -264,7 +270,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - exit ;; + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + exitcode=$? + trap '' 0 + exit $exitcode ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead @@ -290,7 +299,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in echo s390-ibm-zvmoe exit ;; *:OS400:*:*) - echo powerpc-ibm-os400 + echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} @@ -319,14 +328,33 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; + s390x:SunOS:*:*) + echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; - i86pc:SunOS:5.*:*) - echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) + echo i386-pc-auroraux${UNAME_RELEASE} + exit ;; + i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) + eval $set_cc_for_build + SUN_ARCH="i386" + # If there is a compiler, see if it is configured for 64-bit objects. + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. + # This test works for both compilers. + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + SUN_ARCH="x86_64" + fi + fi + echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize @@ -370,23 +398,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} - exit ;; + exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint${UNAME_RELEASE} + echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint${UNAME_RELEASE} - exit ;; + echo m68k-milan-mint${UNAME_RELEASE} + exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint${UNAME_RELEASE} - exit ;; + echo m68k-hades-mint${UNAME_RELEASE} + exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint${UNAME_RELEASE} - exit ;; + echo m68k-unknown-mint${UNAME_RELEASE} + exit ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit ;; @@ -456,8 +484,8 @@ EOF echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` + # DG/UX returns AViiON for all architectures + UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ @@ -470,7 +498,7 @@ EOF else echo i586-dg-dgux${UNAME_RELEASE} fi - exit ;; + exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; @@ -527,7 +555,7 @@ EOF echo rs6000-ibm-aix3.2 fi exit ;; - *:AIX:*:[45]) + *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 @@ -570,52 +598,52 @@ EOF 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "${sc_cpu_version}" in - 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 - 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case "${sc_kernel_bits}" in - 32) HP_ARCH="hppa2.0n" ;; - 64) HP_ARCH="hppa2.0w" ;; + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` + case "${sc_cpu_version}" in + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 + 532) # CPU_PA_RISC2_0 + case "${sc_kernel_bits}" in + 32) HP_ARCH="hppa2.0n" ;; + 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 - esac ;; - esac + esac ;; + esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c + sed 's/^ //' << EOF >$dummy.c - #define _HPUX_SOURCE - #include - #include + #define _HPUX_SOURCE + #include + #include - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa @@ -635,7 +663,7 @@ EOF # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | - grep __LP64__ >/dev/null + grep -q __LP64__ then HP_ARCH="hppa2.0w" else @@ -706,22 +734,22 @@ EOF exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd - exit ;; + exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi - exit ;; + exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd - exit ;; + exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd - exit ;; + exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd - exit ;; + exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; @@ -745,14 +773,14 @@ EOF exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` - FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} @@ -764,27 +792,46 @@ EOF echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) - echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + case ${UNAME_MACHINE} in + pc98) + echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + amd64) + echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + *) + echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; - i*:MINGW*:*) + *:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; i*:windows32*:*) - # uname -m includes "-pc" on this system. - echo ${UNAME_MACHINE}-mingw32 + # uname -m includes "-pc" on this system. + echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; - x86:Interix*:[34]*) - echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//' - exit ;; + *:Interix*:*) + case ${UNAME_MACHINE} in + x86) + echo i586-pc-interix${UNAME_RELEASE} + exit ;; + authenticamd | genuineintel | EM64T) + echo x86_64-unknown-interix${UNAME_RELEASE} + exit ;; + IA64) + echo ia64-unknown-interix${UNAME_RELEASE} + exit ;; + esac ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; + 8664:Windows_NT:*) + echo x86_64-pc-mks + exit ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we @@ -794,7 +841,7 @@ EOF i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit ;; - amd64:CYGWIN*:*:*) + amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; p*:CYGWIN*:*) @@ -814,7 +861,37 @@ EOF i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; + alpha:Linux:*:*) + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in + EV5) UNAME_MACHINE=alphaev5 ;; + EV56) UNAME_MACHINE=alphaev56 ;; + PCA56) UNAME_MACHINE=alphapca56 ;; + PCA57) UNAME_MACHINE=alphapca56 ;; + EV6) UNAME_MACHINE=alphaev6 ;; + EV67) UNAME_MACHINE=alphaev67 ;; + EV68*) UNAME_MACHINE=alphaev68 ;; + esac + objdump --private-headers /bin/sh | grep -q ld.so.1 + if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi + echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} + exit ;; arm*:Linux:*:*) + eval $set_cc_for_build + if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_EABI__ + then + echo ${UNAME_MACHINE}-unknown-linux-gnu + else + if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_PCS_VFP + then + echo ${UNAME_MACHINE}-unknown-linux-gnueabi + else + echo ${UNAME_MACHINE}-unknown-linux-gnueabihf + fi + fi + exit ;; + avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) @@ -824,7 +901,18 @@ EOF echo crisv32-axis-linux-gnu exit ;; frv:Linux:*:*) - echo frv-unknown-linux-gnu + echo frv-unknown-linux-gnu + exit ;; + i*86:Linux:*:*) + LIBC=gnu + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #ifdef __dietlibc__ + LIBC=dietlibc + #endif +EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` + echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -835,63 +923,33 @@ EOF m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; - mips:Linux:*:*) - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #undef CPU - #undef mips - #undef mipsel - #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=mipsel - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=mips - #else - CPU= - #endif - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` - test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } - ;; - mips64:Linux:*:*) + mips:Linux:*:* | mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU - #undef mips64 - #undef mips64el + #undef ${UNAME_MACHINE} + #undef ${UNAME_MACHINE}el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - CPU=mips64el + CPU=${UNAME_MACHINE}el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - CPU=mips64 + CPU=${UNAME_MACHINE} #else CPU= #endif #endif EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; - ppc:Linux:*:*) - echo powerpc-unknown-linux-gnu + or32:Linux:*:*) + echo or32-unknown-linux-gnu exit ;; - ppc64:Linux:*:*) - echo powerpc64-unknown-linux-gnu + padre:Linux:*:*) + echo sparc-unknown-linux-gnu exit ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; - esac - objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null - if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi - echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} + parisc64:Linux:*:* | hppa64:Linux:*:*) + echo hppa64-unknown-linux-gnu exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level @@ -901,14 +959,17 @@ EOF *) echo hppa-unknown-linux-gnu ;; esac exit ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-gnu + ppc64:Linux:*:*) + echo powerpc64-unknown-linux-gnu + exit ;; + ppc:Linux:*:*) + echo powerpc-unknown-linux-gnu exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit ;; sh64*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -916,68 +977,18 @@ EOF sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; + tile*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + vax:Linux:*:*) + echo ${UNAME_MACHINE}-dec-linux-gnu + exit ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; - i*86:Linux:*:*) - # The BFD linker knows what the default object file format is, so - # first see if it will tell us. cd to the root directory to prevent - # problems with other programs or directories called `ld' in the path. - # Set LC_ALL=C to ensure ld outputs messages in English. - ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ - | sed -ne '/supported targets:/!d - s/[ ][ ]*/ /g - s/.*supported targets: *// - s/ .*// - p'` - case "$ld_supported_targets" in - elf32-i386) - TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" - ;; - a.out-i386-linux) - echo "${UNAME_MACHINE}-pc-linux-gnuaout" - exit ;; - coff-i386) - echo "${UNAME_MACHINE}-pc-linux-gnucoff" - exit ;; - "") - # Either a pre-BFD a.out linker (linux-gnuoldld) or - # one that does not give us useful --help. - echo "${UNAME_MACHINE}-pc-linux-gnuoldld" - exit ;; - esac - # Determine whether the default compiler is a.out or elf - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - #ifdef __ELF__ - # ifdef __GLIBC__ - # if __GLIBC__ >= 2 - LIBC=gnu - # else - LIBC=gnulibc1 - # endif - # else - LIBC=gnulibc1 - # endif - #else - #ifdef __INTEL_COMPILER - LIBC=gnu - #else - LIBC=gnuaout - #endif - #endif - #ifdef __dietlibc__ - LIBC=dietlibc - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` - test x"${LIBC}" != x && { - echo "${UNAME_MACHINE}-pc-linux-${LIBC}" - exit - } - test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } - ;; + xtensa*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both @@ -985,11 +996,11 @@ EOF echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) - # Unixware is an offshoot of SVR4, but it has its own version - # number series starting with 2... - # I am not positive that other SVR4 systems won't match this, + # Unixware is an offshoot of SVR4, but it has its own version + # number series starting with 2... + # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. - # Use sysv4.2uw... so that sysv4* matches it. + # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) @@ -1006,7 +1017,7 @@ EOF i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) @@ -1021,7 +1032,7 @@ EOF fi exit ;; i*86:*:5:[678]*) - # UnixWare 7.x, OpenUNIX and OpenServer 6. + # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; @@ -1049,10 +1060,13 @@ EOF exit ;; pc:*:*:*) # Left here for compatibility: - # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i386. - echo i386-pc-msdosdjgpp - exit ;; + # uname -m prints for DJGPP always 'pc', but it prints nothing about + # the processor, so we play safe by assuming i586. + # Note: whatever this is, it MUST be the same as what config.sub + # prints for the "djgpp" host, or else GDB configury will decide that + # this is a cross-build. + echo i586-pc-msdosdjgpp + exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; @@ -1087,8 +1101,18 @@ EOF /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4; exit; } ;; + NCR*:*:4.2:* | MPRAS*:*:4.2:*) + OS_REL='.3' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; @@ -1101,7 +1125,7 @@ EOF rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) + PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) @@ -1121,10 +1145,10 @@ EOF echo ns32k-sni-sysv fi exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says - echo i586-unisys-sysv4 - exit ;; + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says + echo i586-unisys-sysv4 + exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm @@ -1150,11 +1174,11 @@ EOF exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then - echo mips-nec-sysv${UNAME_RELEASE} + echo mips-nec-sysv${UNAME_RELEASE} else - echo mips-unknown-sysv${UNAME_RELEASE} + echo mips-unknown-sysv${UNAME_RELEASE} fi - exit ;; + exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; @@ -1164,6 +1188,9 @@ EOF BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; + BePC:Haiku:*:*) # Haiku running on Intel PC compatible. + echo i586-pc-haiku + exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; @@ -1173,6 +1200,15 @@ EOF SX-6:SUPER-UX:*:*) echo sx6-nec-superux${UNAME_RELEASE} exit ;; + SX-7:SUPER-UX:*:*) + echo sx7-nec-superux${UNAME_RELEASE} + exit ;; + SX-8:SUPER-UX:*:*) + echo sx8-nec-superux${UNAME_RELEASE} + exit ;; + SX-8R:SUPER-UX:*:*) + echo sx8r-nec-superux${UNAME_RELEASE} + exit ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit ;; @@ -1182,7 +1218,16 @@ EOF *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in - *86) UNAME_PROCESSOR=i686 ;; + i386) + eval $set_cc_for_build + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + UNAME_PROCESSOR="x86_64" + fi + fi ;; unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} @@ -1198,6 +1243,9 @@ EOF *:QNX:*:4*) echo i386-pc-qnx exit ;; + NEO-?:NONSTOP_KERNEL:*:*) + echo neo-tandem-nsk${UNAME_RELEASE} + exit ;; NSE-?:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; @@ -1243,13 +1291,13 @@ EOF echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) - echo mips-sei-seiux${UNAME_RELEASE} + echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` + UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; @@ -1261,6 +1309,12 @@ EOF i*86:skyos:*:*) echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' exit ;; + i*86:rdos:*:*) + echo ${UNAME_MACHINE}-pc-rdos + exit ;; + i*86:AROS:*:*) + echo ${UNAME_MACHINE}-pc-aros + exit ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 @@ -1283,11 +1337,11 @@ main () #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 - "4" + "4" #else - "" + "" #endif - ); exit (0); + ); exit (0); #endif #endif @@ -1421,9 +1475,9 @@ This script, last modified $timestamp, has failed to recognize the operating system you are using. It is advised that you download the most up to date version of the config scripts from - http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.guess + http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD and - http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.sub + http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD If the version you run ($0) is already up to date, please send the following data and any information you think might be diff --git a/contrib/ntp/sntp/config.h.in b/contrib/ntp/sntp/config.h.in index ae394d728..2013ce398 100644 --- a/contrib/ntp/sntp/config.h.in +++ b/contrib/ntp/sntp/config.h.in @@ -1,20 +1,78 @@ /* config.h.in. Generated from configure.ac by autoheader. */ +/* Define if building universal (internal helper macro) */ +#undef AC_APPLE_UNIVERSAL_BUILD + +/* why not HAVE_P_S? */ +#undef CALL_PTHREAD_SETCONCURRENCY + +/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP + systems. This function is required for `alloca.c' support on those systems. + */ +#undef CRAY_STACKSEG_END + +/* Define to 1 if using `alloca.c'. */ +#undef C_ALLOCA + +/* Enable debugging code? */ +#undef DEBUG + +/* Directory separator character, usually / or \\ */ +#undef DIR_SEP + +/* number of args to el_init() */ +#undef EL_INIT_ARGS + +/* nls support in libopts */ +#undef ENABLE_NLS + +/* successful termination */ +#undef EX_OK + +/* internal software error */ +#undef EX_SOFTWARE + /* fopen(3) accepts a 'b' in the mode flag */ #undef FOPEN_BINARY_FLAG /* fopen(3) accepts a 't' in the mode flag */ #undef FOPEN_TEXT_FLAG -/* Define to 1 if you have the `alarm' function. */ -#undef HAVE_ALARM +/* What is getsockname()'s socklen type? */ +#undef GETSOCKNAME_SOCKLEN_TYPE -/* Define to 1 if you have the header file. */ -#undef HAVE_ARPA_INET_H +/* Define to 1 if you have `alloca', as a function or macro. */ +#undef HAVE_ALLOCA + +/* Define to 1 if you have and it should be used (not on Ultrix). + */ +#undef HAVE_ALLOCA_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_ARPA_NAMESER_H /* Define to 1 if you have the `canonicalize_file_name' function. */ #undef HAVE_CANONICALIZE_FILE_NAME +/* Define to 1 if you have the `chmod' function. */ +#undef HAVE_CHMOD + +/* Define to 1 if you have the `clock_getres' function. */ +#undef HAVE_CLOCK_GETRES + +/* Define to 1 if you have the `clock_gettime' function. */ +#undef HAVE_CLOCK_GETTIME + +/* Define to 1 if you have the `clock_settime' function. */ +#undef HAVE_CLOCK_SETTIME + +/* Define to 1 if you have the header file. */ +#undef HAVE_CTHREADS_H + +/* Define to 1 if you have the declaration of `strerror_r', and to 0 if you + don't. */ +#undef HAVE_DECL_STRERROR_R + /* Define this if /dev/zero is readable device */ #undef HAVE_DEV_ZERO @@ -28,20 +86,47 @@ /* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */ #undef HAVE_DOPRNT +/* Can we drop root privileges? */ +#undef HAVE_DROPROOT + /* Define to 1 if you have the header file. */ #undef HAVE_ERRNO_H +/* Define to 1 if you have the `EVP_MD_do_all_sorted' function. */ +#undef HAVE_EVP_MD_DO_ALL_SORTED + +/* Define to 1 if you have the `fchmod' function. */ +#undef HAVE_FCHMOD + /* Define to 1 if you have the header file. */ #undef HAVE_FCNTL_H -/* Define to 1 if you have the header file. */ -#undef HAVE_FLOAT_H +/* Define to 1 if you have the `fork' function. */ +#undef HAVE_FORK + +/* Define to 1 if you have the `fstat' function. */ +#undef HAVE_FSTAT + +/* Define to 1 if you have the `getclock' function. */ +#undef HAVE_GETCLOCK + +/* Define to 1 if you have the `getdtablesize' function. */ +#undef HAVE_GETDTABLESIZE + +/* Define to 1 if you have the `getifaddrs' function. */ +#undef HAVE_GETIFADDRS + +/* if you have GNU Pth */ +#undef HAVE_GNU_PTH + +/* Define to 1 if you have the header file. */ +#undef HAVE_HISTEDIT_H -/* Define to 1 if you have the `gettimeofday' function. */ -#undef HAVE_GETTIMEOFDAY +/* Define to 1 if you have the header file. */ +#undef HAVE_HISTORY_H -/* Define to 1 if you have the `inet_ntoa' function. */ -#undef HAVE_INET_NTOA +/* Define to 1 if you have the `if_nametoindex' function. */ +#undef HAVE_IF_NAMETOINDEX /* inline keyword or macro available */ #undef HAVE_INLINE @@ -49,12 +134,21 @@ /* Define to 1 if the system has the type `int16_t'. */ #undef HAVE_INT16_T +/* Define to 1 if the system has the type `int32'. */ +#undef HAVE_INT32 + +/* int32 type in DNS headers, not others. */ +#undef HAVE_INT32_ONLY_WITH_DNS + /* Define to 1 if the system has the type `int32_t'. */ #undef HAVE_INT32_T /* Define to 1 if the system has the type `int8_t'. */ #undef HAVE_INT8_T +/* Define to 1 if the system has the type `intmax_t'. */ +#undef HAVE_INTMAX_T + /* Define to 1 if the system has the type `intptr_t'. */ #undef HAVE_INTPTR_T @@ -67,15 +161,63 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LIBGEN_H +/* Define to 1 if you have the `intl' library (-lintl). */ +#undef HAVE_LIBINTL + +/* Define to 1 if you have the header file. */ +#undef HAVE_LIBINTL_H + /* Define to 1 if you have the header file. */ #undef HAVE_LIMITS_H +/* using Linux pthread? */ +#undef HAVE_LINUXTHREADS + +/* Do we have Linux capabilities? */ +#undef HAVE_LINUX_CAPABILITIES + +/* Define to 1 if you have the header file. */ +#undef HAVE_LINUX_IF_ADDR_H + +/* if you have LinuxThreads */ +#undef HAVE_LINUX_THREADS + +/* Define to 1 if you have the `localeconv' function. */ +#undef HAVE_LOCALECONV + +/* Define to 1 if you have the header file. */ +#undef HAVE_LOCALE_H + +/* Define to 1 if the system has the type `long double'. */ +#undef HAVE_LONG_DOUBLE + +/* Define to 1 if the system has the type `long long'. */ +#undef HAVE_LONG_LONG + +/* Define to 1 if the system has the type `long long int'. */ +#undef HAVE_LONG_LONG_INT + +/* if you have SunOS LWP package */ +#undef HAVE_LWP + +/* Define to 1 if you have the header file. */ +#undef HAVE_LWP_LWP_H + +/* define if you have Mach Cthreads */ +#undef HAVE_MACH_CTHREADS + +/* Define to 1 if you have the header file. */ +#undef HAVE_MACH_CTHREADS_H + +/* Define to 1 if you have the `MD5Init' function. */ +#undef HAVE_MD5INIT + +/* Define to 1 if you have the header file. */ +#undef HAVE_MD5_H + /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H -/* Define to 1 if you have the `memset' function. */ -#undef HAVE_MEMSET - /* Define to 1 if you have the `mmap' function. */ #undef HAVE_MMAP @@ -88,42 +230,189 @@ /* Define to 1 if you have the header file. */ #undef HAVE_NETINET_IN_H +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IN_SYSTEM_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IN_SYSTM_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IN_VAR_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IP_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NET_IF_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NET_IF_VAR_H + +/* sntp does not care about 'nice' */ +#undef HAVE_NO_NICE + +/* if you have NT Event Log */ +#undef HAVE_NT_EVENT_LOG + +/* if you have NT Service Manager */ +#undef HAVE_NT_SERVICE_MANAGER + +/* if you have NT Threads */ +#undef HAVE_NT_THREADS + /* Define this if pathfind(3) works */ #undef HAVE_PATHFIND +/* Define to 1 if the system has the type `pid_t'. */ +#undef HAVE_PID_T + +/* Define to 1 if you have the header file. */ +#undef HAVE_PRIV_H + +/* Define if you have POSIX threads libraries and header files. */ +#undef HAVE_PTHREAD + +/* define to pthreads API spec revision */ +#undef HAVE_PTHREADS + +/* Define to 1 if you have the `pthread_attr_getstacksize' function. */ +#undef HAVE_PTHREAD_ATTR_GETSTACKSIZE + +/* Define to 1 if you have the `pthread_attr_setstacksize' function. */ +#undef HAVE_PTHREAD_ATTR_SETSTACKSIZE + +/* define if you have pthread_detach function */ +#undef HAVE_PTHREAD_DETACH + +/* Define to 1 if you have the `pthread_getconcurrency' function. */ +#undef HAVE_PTHREAD_GETCONCURRENCY + +/* Define to 1 if you have the header file. */ +#undef HAVE_PTHREAD_H + +/* Define to 1 if you have the `pthread_kill' function. */ +#undef HAVE_PTHREAD_KILL + +/* Define to 1 if you have the `pthread_kill_other_threads_np' function. */ +#undef HAVE_PTHREAD_KILL_OTHER_THREADS_NP + +/* define if you have pthread_rwlock_destroy function */ +#undef HAVE_PTHREAD_RWLOCK_DESTROY + +/* Define to 1 if you have the `pthread_setconcurrency' function. */ +#undef HAVE_PTHREAD_SETCONCURRENCY + +/* Define to 1 if you have the `pthread_yield' function. */ +#undef HAVE_PTHREAD_YIELD + +/* Define to 1 if you have the header file. */ +#undef HAVE_PTH_H + +/* Define to 1 if the system has the type `ptrdiff_t'. */ +#undef HAVE_PTRDIFF_T + +/* Define to 1 if you have the header file. */ +#undef HAVE_READLINE_H + +/* Define if your readline library has \`add_history' */ +#undef HAVE_READLINE_HISTORY + +/* Define to 1 if you have the header file. */ +#undef HAVE_READLINE_HISTORY_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_READLINE_READLINE_H + /* Define this if we have a functional realpath(3C) */ #undef HAVE_REALPATH +/* Define to 1 if you have the `recvmsg' function. */ +#undef HAVE_RECVMSG + +/* Define to 1 if you have the header file. */ +#undef HAVE_RESOLV_H + +/* Define to 1 if you have the `res_init' function. */ +#undef HAVE_RES_INIT + +/* Define to 1 if you have the header file. */ +#undef HAVE_RUNETYPE_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SCHED_H + +/* Define to 1 if you have the `sched_yield' function. */ +#undef HAVE_SCHED_YIELD + +/* Define to 1 if you have the header file. */ +#undef HAVE_SEMAPHORE_H + +/* Define to 1 if you have the `sem_timedwait' function. */ +#undef HAVE_SEM_TIMEDWAIT + /* Define to 1 if you have the header file. */ #undef HAVE_SETJMP_H +/* Define to 1 if you have the `settimeofday' function. */ +#undef HAVE_SETTIMEOFDAY + +/* Define to 1 if you have the `sigaction' function. */ +#undef HAVE_SIGACTION + +/* Can we use SIGIO for tcp and udp IO? */ +#undef HAVE_SIGNALED_IO + +/* Define to 1 if you have the `sigset' function. */ +#undef HAVE_SIGSET + +/* Define to 1 if you have the `sigvec' function. */ +#undef HAVE_SIGVEC + +/* sigwait() available? */ +#undef HAVE_SIGWAIT + +/* Define to 1 if the system has the type `size_t'. */ +#undef HAVE_SIZE_T + /* Define to 1 if you have the `snprintf' function. */ #undef HAVE_SNPRINTF /* Define to 1 if you have the `socket' function. */ #undef HAVE_SOCKET -/* Define to 1 if you have the `sqrt' function. */ -#undef HAVE_SQRT +/* Define to 1 if you have the `socketpair' function. */ +#undef HAVE_SOCKETPAIR -/* Does struct sockaddr_storage have ss_family? */ -#undef HAVE_SS_FAMILY_IN_SS +/* Are Solaris privileges available? */ +#undef HAVE_SOLARIS_PRIVS /* Define to 1 if you have the header file. */ #undef HAVE_STDARG_H +/* Define to 1 if stdbool.h conforms to C99. */ +#undef HAVE_STDBOOL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDDEF_H + /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H +/* Define to 1 if you have the `stime' function. */ +#undef HAVE_STIME + /* Define to 1 if you have the `strchr' function. */ #undef HAVE_STRCHR /* Define to 1 if you have the `strdup' function. */ #undef HAVE_STRDUP +/* Define to 1 if you have the `strerror_r' function. */ +#undef HAVE_STRERROR_R + /* Define this if strftime() works */ #undef HAVE_STRFTIME @@ -133,15 +422,54 @@ /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H +/* Define to 1 if you have the `strlcat' function. */ +#undef HAVE_STRLCAT + +/* Define to 1 if you have the `strlcpy' function. */ +#undef HAVE_STRLCPY + /* Define to 1 if you have the `strrchr' function. */ #undef HAVE_STRRCHR +/* Define to 1 if you have the `strsignal' function. */ +#undef HAVE_STRSIGNAL + +/* Define to 1 if `decimal_point' is a member of `struct lconv'. */ +#undef HAVE_STRUCT_LCONV_DECIMAL_POINT + +/* Define to 1 if `thousands_sep' is a member of `struct lconv'. */ +#undef HAVE_STRUCT_LCONV_THOUSANDS_SEP + +/* Do we have struct ntptimeval? */ +#undef HAVE_STRUCT_NTPTIMEVAL + +/* Does a system header define struct sockaddr_storage? */ +#undef HAVE_STRUCT_SOCKADDR_STORAGE + +/* struct timespec declared? */ +#undef HAVE_STRUCT_TIMESPEC + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYNCH_H + +/* Define to 1 if you have the `sysconf' function. */ +#undef HAVE_SYSCONF + /* Define to 1 if you have the header file. */ #undef HAVE_SYSEXITS_H +/* */ +#undef HAVE_SYSLOG_FACILITYNAMES + /* Define to 1 if you have the header file. */ #undef HAVE_SYSLOG_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_CAPABILITY_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_CLOCKCTL_H + /* Define to 1 if you have the header file, and it defines `DIR'. */ #undef HAVE_SYS_DIR_H @@ -162,6 +490,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SYS_POLL_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_PRCTL_H + /* Define to 1 if you have the header file. */ #undef HAVE_SYS_PROCSET_H @@ -177,6 +508,15 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SYS_STROPTS_H +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_SYSCTL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TIMEPPS_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TIMERS_H + /* Define to 1 if you have the header file. */ #undef HAVE_SYS_TIME_H @@ -189,6 +529,33 @@ /* Define to 1 if you have the header file. */ #undef HAVE_SYS_WAIT_H +/* Define to 1 if the system has the type `s_char'. */ +#undef HAVE_S_CHAR + +/* sntp does not care about TTY stuff */ +#undef HAVE_TERMIOS + +/* if you have Solaris LWP (thr) package */ +#undef HAVE_THR + +/* Define to 1 if you have the header file. */ +#undef HAVE_THREAD_H + +/* Define to 1 if you have the `thr_getconcurrency' function. */ +#undef HAVE_THR_GETCONCURRENCY + +/* Define to 1 if you have the `thr_setconcurrency' function. */ +#undef HAVE_THR_SETCONCURRENCY + +/* Define to 1 if you have the `thr_yield' function. */ +#undef HAVE_THR_YIELD + +/* Define to 1 if you have the `timegm' function. */ +#undef HAVE_TIMEGM + +/* Define to 1 if you have the header file. */ +#undef HAVE_TIME_H + /* Define to 1 if the system has the type `uint16_t'. */ #undef HAVE_UINT16_T @@ -198,6 +565,9 @@ /* Define to 1 if the system has the type `uint8_t'. */ #undef HAVE_UINT8_T +/* Define to 1 if the system has the type `uintmax_t'. */ +#undef HAVE_UINTMAX_T + /* Define to 1 if the system has the type `uintptr_t'. */ #undef HAVE_UINTPTR_T @@ -207,27 +577,169 @@ /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H +/* deviant sigwait? */ +#undef HAVE_UNIXWARE_SIGWAIT + +/* Define to 1 if the system has the type `unsigned long long int'. */ +#undef HAVE_UNSIGNED_LONG_LONG_INT + /* Define to 1 if you have the header file. */ #undef HAVE_UTIME_H +/* Define to 1 if the system has the type `u_int32'. */ +#undef HAVE_U_INT32 + +/* u_int32 type in DNS headers, not others. */ +#undef HAVE_U_INT32_ONLY_WITH_DNS + /* Define to 1 if you have the header file. */ #undef HAVE_VALUES_H /* Define to 1 if you have the header file. */ #undef HAVE_VARARGS_H +/* Define to 1 if you have the `vfork' function. */ +#undef HAVE_VFORK + +/* Define to 1 if you have the header file. */ +#undef HAVE_VFORK_H + /* Define to 1 if you have the `vprintf' function. */ #undef HAVE_VPRINTF +/* Define if C99-compliant `vsnprintf' is available. */ +#undef HAVE_VSNPRINTF + +/* Define to 1 if you have the header file. */ +#undef HAVE_WCHAR_H + +/* Define to 1 if the system has the type `wchar_t'. */ +#undef HAVE_WCHAR_T + +/* Define to 1 if the system has the type `wint_t'. */ +#undef HAVE_WINT_T + +/* Define to 1 if `fork' works. */ +#undef HAVE_WORKING_FORK + +/* Define to 1 if `vfork' works. */ +#undef HAVE_WORKING_VFORK + +/* define if select implicitly yields */ +#undef HAVE_YIELDING_SELECT + +/* Define to 1 if the system has the type `_Bool'. */ +#undef HAVE__BOOL + +/* defined if C compiler supports __attribute__((...)) */ +#undef HAVE___ATTRIBUTE__ + + + /* define away __attribute__() if unsupported */ + #ifndef HAVE___ATTRIBUTE__ + # define __attribute__(x) /* empty */ + #endif + #define ISC_PLATFORM_NORETURN_PRE + #define ISC_PLATFORM_NORETURN_POST __attribute__((__noreturn__)) + + + +/* Define to 1 if you have the `__res_init' function. */ +#undef HAVE___RES_INIT + /* Does struct sockaddr_storage have __ss_family? */ #undef HAVE___SS_FAMILY_IN_SS + + /* Handle sockaddr_storage.__ss_family */ + #ifdef HAVE___SS_FAMILY_IN_SS + # define ss_family __ss_family + #endif /* HAVE___SS_FAMILY_IN_SS */ + + + +/* Define to provide `rpl_snprintf' function. */ +#undef HW_WANT_RPL_SNPRINTF + +/* Define to provide `rpl_vsnprintf' function. */ +#undef HW_WANT_RPL_VSNPRINTF + +/* Enclose PTHREAD_ONCE_INIT in extra braces? */ +#undef ISC_PLATFORM_BRACEPTHREADONCEINIT + +/* Do we need to fix in6isaddr? */ +#undef ISC_PLATFORM_FIXIN6ISADDR + +/* ISC: do we have if_nametoindex()? */ +#undef ISC_PLATFORM_HAVEIFNAMETOINDEX + +/* have struct if_laddrconf? */ +#undef ISC_PLATFORM_HAVEIF_LADDRCONF + +/* have struct if_laddrreq? */ +#undef ISC_PLATFORM_HAVEIF_LADDRREQ + +/* have struct in6_pktinfo? */ +#undef ISC_PLATFORM_HAVEIN6PKTINFO + +/* have IPv6? */ +#undef ISC_PLATFORM_HAVEIPV6 + +/* struct sockaddr has sa_len? */ +#undef ISC_PLATFORM_HAVESALEN + +/* sin6_scope_id? */ +#undef ISC_PLATFORM_HAVESCOPEID + +/* missing in6addr_any? */ +#undef ISC_PLATFORM_NEEDIN6ADDRANY + +/* Do we need netinet6/in6.h? */ +#undef ISC_PLATFORM_NEEDNETINET6IN6H + +/* ISC: provide inet_ntop() */ +#undef ISC_PLATFORM_NEEDNTOP + +/* Declare in_port_t? */ +#undef ISC_PLATFORM_NEEDPORTT + +/* ISC: provide inet_pton() */ +#undef ISC_PLATFORM_NEEDPTON + +/* enable libisc thread support? */ +#undef ISC_PLATFORM_USETHREADS + +/* define to 1 if library is thread safe */ +#undef LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE + +/* Define to the sub-directory in which libtool stores uninstalled libraries. + */ +#undef LT_OBJDIR + +/* Does the target support multicast IP? */ +#undef MCAST + +/* pthread_init() required? */ +#undef NEED_PTHREAD_INIT + +/* use PTHREAD_SCOPE_SYSTEM? */ +#undef NEED_PTHREAD_SCOPE_SYSTEM + +/* Do we need an s_char typedef? */ +#undef NEED_S_CHAR_TYPEDEF + /* Define this if optional arguments are disallowed */ #undef NO_OPTIONAL_OPT_ARGS /* Should we avoid #warning on option name collisions? */ #undef NO_OPTION_NAME_WARNINGS +/* define if you have (or want) no threads */ +#undef NO_THREADS + +/* Use OpenSSL? */ +#undef OPENSSL + /* Name of package */ #undef PACKAGE @@ -249,14 +761,20 @@ /* Define to the version of this package. */ #undef PACKAGE_VERSION +/* define to a working POSIX compliant shell */ +#undef POSIX_SHELL + +/* enable thread safety */ +#undef REENTRANT + /* name of regex header file */ #undef REGEX_HEADER -/* Define as the return type of signal handlers (`int' or `void'). */ -#undef RETSIGTYPE +/* define if sched_yield yields the entire process */ +#undef REPLACE_BROKEN_YIELD -/* The size of `char*', as computed by sizeof. */ -#undef SIZEOF_CHARP +/* The size of `char *', as computed by sizeof. */ +#undef SIZEOF_CHAR_P /* The size of `int', as computed by sizeof. */ #undef SIZEOF_INT @@ -264,41 +782,233 @@ /* The size of `long', as computed by sizeof. */ #undef SIZEOF_LONG +/* The size of `long long', as computed by sizeof. */ +#undef SIZEOF_LONG_LONG + +/* The size of `pthread_t', as computed by sizeof. */ +#undef SIZEOF_PTHREAD_T + /* The size of `short', as computed by sizeof. */ #undef SIZEOF_SHORT +/* The size of `signed char', as computed by sizeof. */ +#undef SIZEOF_SIGNED_CHAR + +/* The size of `time_t', as computed by sizeof. */ +#undef SIZEOF_TIME_T + +/* If using the C implementation of alloca, define if you know the + direction of stack growth for your system; otherwise it will be + automatically deduced at runtime. + STACK_DIRECTION > 0 => grows toward higher addresses + STACK_DIRECTION < 0 => grows toward lower addresses + STACK_DIRECTION = 0 => direction of growth unknown */ +#undef STACK_DIRECTION + /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS +/* Define to 1 if strerror_r returns char *. */ +#undef STRERROR_R_CHAR_P + +/* canonical system (cpu-vendor-os) of where we should run */ +#undef STR_SYSTEM + +/* Does Xettimeofday take 1 arg? */ +#undef SYSV_TIMEOFDAY + +/* enable thread safety */ +#undef THREADSAFE + +/* enable thread safety */ +#undef THREAD_SAFE + /* Define to 1 if you can safely include both and . */ #undef TIME_WITH_SYS_TIME -/* Define to 1 if your declares `struct tm'. */ -#undef TM_IN_SYS_TIME +/* Provide a typedef for uintptr_t? */ +#ifndef HAVE_UINTPTR_T +typedef unsigned int uintptr_t; +#define HAVE_UINTPTR_T 1 +#endif + +/* What type to use for setsockopt */ +#undef TYPEOF_IP_MULTICAST_LOOP + +/* OK to use snprintb()? */ +#undef USE_SNPRINTB + +/* Can we use SIGPOLL for tty IO? */ +#undef USE_TTY_SIGPOLL + +/* Can we use SIGPOLL for UDP? */ +#undef USE_UDP_SIGPOLL /* Version number of package */ #undef VERSION +/* vsnprintf expands "%m" to strerror(errno) */ +#undef VSNPRINTF_PERCENT_M + +/* configure --enable-ipv6 */ +#undef WANT_IPV6 + /* Define this if a working libregex can be found */ #undef WITH_LIBREGEX +/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most + significant byte first (like Motorola and SPARC, unlike Intel). */ +#if defined AC_APPLE_UNIVERSAL_BUILD +# if defined __BIG_ENDIAN__ +# define WORDS_BIGENDIAN 1 +# endif +#else +# ifndef WORDS_BIGENDIAN +# undef WORDS_BIGENDIAN +# endif +#endif + +/* Define to 1 if on MINIX. */ +#undef _MINIX + +/* Define to 2 if the system does not provide POSIX.1 features except with + this defined. */ +#undef _POSIX_1_SOURCE + +/* Define to 1 if you need to in order for `stat' and other things to work. */ +#undef _POSIX_SOURCE + +/* enable thread safety */ +#undef _REENTRANT + +/* enable thread safety */ +#undef _SGI_MP_SOURCE + +/* enable thread safety */ +#undef _THREADSAFE + +/* enable thread safety */ +#undef _THREAD_SAFE + +/* Define to 500 only on HP-UX. */ +#undef _XOPEN_SOURCE + +/* Are we _special_? */ +#undef __APPLE_USE_RFC_3542 + +/* Define to 1 if type `char' is unsigned and you are not using gcc. */ +#ifndef __CHAR_UNSIGNED__ +# undef __CHAR_UNSIGNED__ +#endif + +/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# undef _GNU_SOURCE +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# undef _POSIX_PTHREAD_SEMANTICS +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# undef _TANDEM_SOURCE +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# undef __EXTENSIONS__ +#endif + + /* Define to empty if `const' does not conform to ANSI C. */ #undef const +/* Define to `int' if doesn't define. */ +#undef gid_t + /* Define to `__inline__' or `__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif +/* Define to the widest signed integer type if and do + not define. */ +#undef intmax_t + +/* Define to `int' if does not define. */ +#undef pid_t + /* Define to `unsigned int' if does not define. */ #undef size_t -/* normalize ss_family access */ -#undef ss_family + + #if !defined(_KERNEL) && !defined(PARSESTREAM) + /* + * stdio.h must be included after _GNU_SOURCE is defined + * but before #define snprintf rpl_snprintf + */ + # include + #endif + + +/* Define to rpl_snprintf if the replacement function should be used. */ +#undef snprintf -/* normalize ss_len access */ -#undef ss_len +/* Define to `int' if doesn't define. */ +#undef uid_t -/* Alternate uintptr_t for systems without it. */ +/* Define to the widest unsigned integer type if and + do not define. */ +#undef uintmax_t + +/* Define to the type of an unsigned integer type wide enough to hold a + pointer, if such a type exists, and if the system does not define it. */ #undef uintptr_t + +/* Define as `fork' if `vfork' does not work. */ +#undef vfork + +/* Define to empty if the keyword `volatile' does not work. Warning: valid + code using `volatile' can become incorrect without. Disable with care. */ +#undef volatile + +/* Define to rpl_vsnprintf if the replacement function should be used. */ +#undef vsnprintf + + +#ifndef MPINFOU_PREDECLARED +# define MPINFOU_PREDECLARED +typedef union mpinfou { + struct pdk_mpinfo *pdkptr; + struct mpinfo *pikptr; +} mpinfou_t; +#endif + + + + #if !defined(_KERNEL) && !defined(PARSESTREAM) + # if defined(HW_WANT_RPL_VSNPRINTF) + # if defined(__cplusplus) + extern "C" { + # endif + # include + int rpl_vsnprintf(char *, size_t, const char *, va_list); + # if defined(__cplusplus) + } + # endif + # endif + # if defined(HW_WANT_RPL_SNPRINTF) + # if defined(__cplusplus) + extern "C" { + # endif + int rpl_snprintf(char *, size_t, const char *, ...); + # if defined(__cplusplus) + } + # endif + # endif + #endif /* !defined(_KERNEL) && !defined(PARSESTREAM) */ + diff --git a/contrib/ntp/sntp/config.sub b/contrib/ntp/sntp/config.sub index 1c366dfde..f9fcdc879 100755 --- a/contrib/ntp/sntp/config.sub +++ b/contrib/ntp/sntp/config.sub @@ -1,9 +1,10 @@ #! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, -# 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011 Free Software Foundation, Inc. -timestamp='2005-07-08' +timestamp='2011-06-03' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -31,13 +32,16 @@ timestamp='2005-07-08' # Please send patches to . Submit a context -# diff and a properly formatted ChangeLog entry. +# diff and a properly formatted GNU ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD + # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. @@ -71,8 +75,9 @@ Report bugs and patches to ." version="\ GNU config.sub ($timestamp) -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free +Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -119,8 +124,11 @@ esac # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in - nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \ - kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) + nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ + linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ + knetbsd*-gnu* | netbsd*-gnu* | \ + kopensolaris*-gnu* | \ + storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; @@ -146,10 +154,13 @@ case $os in -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ - -apple | -axis | -knuth | -cray) + -apple | -axis | -knuth | -cray | -microblaze) os= basic_machine=$1 ;; + -bluegene*) + os=-cnk + ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 @@ -164,13 +175,17 @@ case $os in os=-chorusos basic_machine=$1 ;; - -chorusrdb) - os=-chorusrdb + -chorusrdb) + os=-chorusrdb basic_machine=$1 - ;; + ;; -hiux*) os=-hiuxwe2 ;; + -sco6) + os=-sco5v6 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` @@ -187,6 +202,10 @@ case $os in # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; + -sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` @@ -231,20 +250,24 @@ case $basic_machine in | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ - | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \ + | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ - | fr30 | frv \ + | fido | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ - | m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \ + | lm32 \ + | m32c | m32r | m32rle | m68000 | m68k | m88k \ + | maxq | mb | microblaze | mcore | mep | metag \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ - | mips64vr | mips64vrel \ + | mips64octeon | mips64octeonel \ | mips64orion | mips64orionel \ + | mips64r5900 | mips64r5900el \ + | mips64vr | mips64vrel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ @@ -257,35 +280,63 @@ case $basic_machine in | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ - | ms1 \ + | moxie \ + | mt \ | msp430 \ + | nds32 | nds32le | nds32be \ + | nios | nios2 \ | ns16k | ns32k \ + | open8 \ | or32 \ | pdp10 | pdp11 | pj | pjl \ - | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ + | powerpc | powerpc64 | powerpc64le | powerpcle \ | pyramid \ - | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \ + | rx \ + | score \ + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc86x | sparclet | sparclite \ - | sparcv8 | sparcv9 | sparcv9b \ - | strongarm \ - | tahoe | thumb | tic4x | tic80 | tron \ - | v850 | v850e \ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ + | spu \ + | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ + | ubicom32 \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ | we32k \ - | x86 | xscale | xscalee[bl] | xstormy16 | xtensa \ - | z8k) + | x86 | xc16x | xstormy16 | xtensa \ + | z8k | z80) basic_machine=$basic_machine-unknown ;; - m32c) - basic_machine=$basic_machine-unknown + c54x) + basic_machine=tic54x-unknown ;; - m6811 | m68hc11 | m6812 | m68hc12) + c55x) + basic_machine=tic55x-unknown + ;; + c6x) + basic_machine=tic6x-unknown + ;; + m6811 | m68hc11 | m6812 | m68hc12 | picochip) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; + ms1) + basic_machine=mt-unknown + ;; + + strongarm | thumb | xscale) + basic_machine=arm-unknown + ;; + + xscaleeb) + basic_machine=armeb-unknown + ;; + + xscaleel) + basic_machine=armel-unknown + ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and @@ -305,25 +356,28 @@ case $basic_machine in | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ - | avr-* \ + | avr-* | avr32-* \ | bfin-* | bs2000-* \ - | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ + | c[123]* | c30-* | [cjt]90-* | c4x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ - | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \ + | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ - | m32r-* | m32rle-* \ + | lm32-* \ + | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ - | m88110-* | m88k-* | maxq-* | mcore-* \ + | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ - | mips64vr-* | mips64vrel-* \ + | mips64octeon-* | mips64octeonel-* \ | mips64orion-* | mips64orionel-* \ + | mips64r5900-* | mips64r5900el-* \ + | mips64vr-* | mips64vrel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ @@ -336,30 +390,38 @@ case $basic_machine in | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ - | ms1-* \ + | mt-* \ | msp430-* \ + | nds32-* | nds32le-* | nds32be-* \ + | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ + | open8-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ - | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ | pyramid-* \ - | romp-* | rs6000-* \ - | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | shbe-* \ + | romp-* | rs6000-* | rx-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ - | sparc-* | sparc64-* | sparc64b-* | sparc86x-* | sparclet-* \ + | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ - | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ - | tahoe-* | thumb-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ + | tahoe-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tile*-* \ | tron-* \ - | v850-* | v850e-* | vax-* \ + | ubicom32-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ | we32k-* \ - | x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \ - | xstormy16-* | xtensa-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* \ + | xstormy16-* | xtensa*-* \ | ymp-* \ - | z8k-*) + | z8k-* | z80-*) ;; - m32c-*) + # Recognize the basic CPU types without company name, with glob match. + xtensa*) + basic_machine=$basic_machine-unknown ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. @@ -377,7 +439,7 @@ case $basic_machine in basic_machine=a29k-amd os=-udi ;; - abacus) + abacus) basic_machine=abacus-unknown ;; adobe68k) @@ -423,6 +485,10 @@ case $basic_machine in basic_machine=m68k-apollo os=-bsd ;; + aros) + basic_machine=i386-pc + os=-aros + ;; aux) basic_machine=m68k-apple os=-aux @@ -431,10 +497,35 @@ case $basic_machine in basic_machine=ns32k-sequent os=-dynix ;; + blackfin) + basic_machine=bfin-unknown + os=-linux + ;; + blackfin-*) + basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + bluegene*) + basic_machine=powerpc-ibm + os=-cnk + ;; + c54x-*) + basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c55x-*) + basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c6x-*) + basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; c90) basic_machine=c90-cray os=-unicos ;; + cegcc) + basic_machine=arm-unknown + os=-cegcc + ;; convex-c1) basic_machine=c1-convex os=-bsd @@ -463,8 +554,8 @@ case $basic_machine in basic_machine=craynv-cray os=-unicosmp ;; - cr16c) - basic_machine=cr16c-unknown + cr16 | cr16-*) + basic_machine=cr16-unknown os=-elf ;; crds | unos) @@ -502,6 +593,10 @@ case $basic_machine in basic_machine=m88k-motorola os=-sysv3 ;; + dicos) + basic_machine=i686-pc + os=-dicos + ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp @@ -656,6 +751,14 @@ case $basic_machine in basic_machine=m68k-isi os=-sysv ;; + m68knommu) + basic_machine=m68k-unknown + os=-linux + ;; + m68knommu-*) + basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; m88k-omron*) basic_machine=m88k-omron ;; @@ -667,10 +770,17 @@ case $basic_machine in basic_machine=ns32k-utek os=-sysv ;; + microblaze) + basic_machine=microblaze-xilinx + ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; + mingw32ce) + basic_machine=arm-unknown + os=-mingw32ce + ;; miniframe) basic_machine=m68000-convergent ;; @@ -696,6 +806,9 @@ case $basic_machine in basic_machine=i386-pc os=-msdos ;; + ms1-*) + basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` + ;; mvs) basic_machine=i370-ibm os=-mvs @@ -764,6 +877,12 @@ case $basic_machine in np1) basic_machine=np1-gould ;; + neo-tandem) + basic_machine=neo-tandem + ;; + nse-tandem) + basic_machine=nse-tandem + ;; nsr-tandem) basic_machine=nsr-tandem ;; @@ -794,6 +913,14 @@ case $basic_machine in basic_machine=i860-intel os=-osf ;; + parisc) + basic_machine=hppa-unknown + os=-linux + ;; + parisc-*) + basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; pbd) basic_machine=sparc-tti ;; @@ -803,6 +930,12 @@ case $basic_machine in pc532 | pc532-*) basic_machine=ns32k-pc532 ;; + pc98) + basic_machine=i386-pc + ;; + pc98-*) + basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; @@ -832,9 +965,10 @@ case $basic_machine in ;; power) basic_machine=power-ibm ;; - ppc) basic_machine=powerpc-unknown + ppc | ppcbe) basic_machine=powerpc-unknown ;; - ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + ppc-* | ppcbe-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown @@ -859,6 +993,10 @@ case $basic_machine in basic_machine=i586-unknown os=-pw32 ;; + rdos) + basic_machine=i386-pc + os=-rdos + ;; rom68k) basic_machine=m68k-rom68k os=-coff @@ -885,6 +1023,10 @@ case $basic_machine in sb1el) basic_machine=mipsisa64sb1el-unknown ;; + sde) + basic_machine=mipsisa32-sde + os=-elf + ;; sei) basic_machine=mips-sei os=-seiux @@ -896,6 +1038,9 @@ case $basic_machine in basic_machine=sh-hitachi os=-hms ;; + sh5el) + basic_machine=sh5le-unknown + ;; sh64) basic_machine=sh64-unknown ;; @@ -917,6 +1062,9 @@ case $basic_machine in basic_machine=i860-stratus os=-sysv4 ;; + strongarm-* | thumb-*) + basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; sun2) basic_machine=m68000-sun ;; @@ -973,17 +1121,9 @@ case $basic_machine in basic_machine=t90-cray os=-unicos ;; - tic54x | c54x*) - basic_machine=tic54x-unknown - os=-coff - ;; - tic55x | c55x*) - basic_machine=tic55x-unknown - os=-coff - ;; - tic6x | c6x*) - basic_machine=tic6x-unknown - os=-coff + tile*) + basic_machine=$basic_machine-unknown + os=-linux-gnu ;; tx39) basic_machine=mipstx39-unknown @@ -1052,6 +1192,9 @@ case $basic_machine in xps | xps100) basic_machine=xps100-honeywell ;; + xscale-* | xscalee[bl]-*) + basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + ;; ymp) basic_machine=ymp-cray os=-unicos @@ -1060,6 +1203,10 @@ case $basic_machine in basic_machine=z8k-unknown os=-sim ;; + z80-*-coff) + basic_machine=z80-unknown + os=-sim + ;; none) basic_machine=none-none os=-none @@ -1098,10 +1245,10 @@ case $basic_machine in we32k) basic_machine=we32k-att ;; - sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) + sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; - sparc | sparcv8 | sparcv9 | sparcv9b) + sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) basic_machine=sparc-sun ;; cydra) @@ -1145,9 +1292,12 @@ esac if [ x"$os" != x"" ] then case $os in - # First match some system type aliases - # that might get confused with valid system types. + # First match some system type aliases + # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. + -auroraux) + os=-auroraux + ;; -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; @@ -1168,27 +1318,31 @@ case $os in # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ - | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ - | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ - | -aos* \ + | -aos* | -aros* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ - | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \ + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -chorusos* | -chorusrdb* \ + | -chorusos* | -chorusrdb* | -cegcc* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \ + | -mingw32* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-uclibc* \ + | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ - | -skyos* | -haiku*) + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) @@ -1227,7 +1381,7 @@ case $os in -opened*) os=-openedition ;; - -os400*) + -os400*) os=-os400 ;; -wince*) @@ -1276,7 +1430,7 @@ case $os in -sinix*) os=-sysv4 ;; - -tpf*) + -tpf*) os=-tpf ;; -triton*) @@ -1318,6 +1472,11 @@ case $os in -zvmoe) os=-zvmoe ;; + -dicos*) + os=-dicos + ;; + -nacl*) + ;; -none) ;; *) @@ -1340,6 +1499,12 @@ else # system, and we'll never get to this point. case $basic_machine in + score-*) + os=-elf + ;; + spu-*) + os=-elf + ;; *-acorn) os=-riscix1.2 ;; @@ -1349,9 +1514,18 @@ case $basic_machine in arm*-semi) os=-aout ;; - c4x-* | tic4x-*) - os=-coff - ;; + c4x-* | tic4x-*) + os=-coff + ;; + tic54x-*) + os=-coff + ;; + tic55x-*) + os=-coff + ;; + tic6x-*) + os=-coff + ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 @@ -1377,6 +1551,9 @@ case $basic_machine in m68*-cisco) os=-aout ;; + mep-*) + os=-elf + ;; mips*-cisco) os=-elf ;; @@ -1401,7 +1578,7 @@ case $basic_machine in *-ibm) os=-aix ;; - *-knuth) + *-knuth) os=-mmixware ;; *-wec) @@ -1506,7 +1683,7 @@ case $basic_machine in -sunos*) vendor=sun ;; - -aix*) + -cnk*|-aix*) vendor=ibm ;; -beos*) diff --git a/contrib/ntp/sntp/configure b/contrib/ntp/sntp/configure index 1bcdaf7ab..74d0587cf 100755 --- a/contrib/ntp/sntp/configure +++ b/contrib/ntp/sntp/configure @@ -1,11 +1,11 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.65. +# Generated by GNU Autoconf 2.69 for sntp 4.2.8p4. # +# Report bugs to . # -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# +# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. # # # This configure script is free software; the Free Software Foundation @@ -89,6 +89,7 @@ fi IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. +as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -133,6 +134,31 @@ export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# Use a proper internal environment variable to ensure we don't fall + # into an infinite loop, continuously re-executing ourselves. + if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then + _as_can_reexec=no; export _as_can_reexec; + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +as_fn_exit 255 + fi + # We don't want this to propagate to other subprocesses. + { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh @@ -166,12 +192,21 @@ if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi -test x\$exitcode = x0 || exit 1" +test x\$exitcode = x0 || exit 1 +test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 -test \$(( 1 + 1 )) = 2 || exit 1" +test \$(( 1 + 1 )) = 2 || exit 1 + + test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ + || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else @@ -211,14 +246,25 @@ IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : - # We cannot yet assume a decent shell, so we have to provide a - # neutralization value for shells without unset; and this also - # works around shells that cannot unset nonexistent variables. - BASH_ENV=/dev/null - ENV=/dev/null - (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV - export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} + export CONFIG_SHELL + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 fi if test x$as_have_required = xno; then : @@ -228,10 +274,11 @@ fi $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else - $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, -$0: including any error possibly output before this -$0: message. Then install a modern shell, or manually run -$0: the script under such a shell if you do have one." + $as_echo "$0: Please tell bug-autoconf@gnu.org and +$0: http://bugs.ntp.org./ about your system, including any +$0: error possibly output before this message. Then install +$0: a modern shell, or manually run the script under such a +$0: shell if you do have one." fi exit 1 fi @@ -316,10 +363,18 @@ $as_echo X"$as_dir" | test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take @@ -356,19 +411,19 @@ else fi # as_fn_arith -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. +# script with STATUS, using 1 if that was 0. as_fn_error () { - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi - $as_echo "$as_me: error: $1" >&2 + $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error @@ -441,6 +496,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + # If we had to re-execute with $CONFIG_SHELL, we're ensured to have + # already done that, so ensure we don't try to do so again and fall + # in an infinite loop. This has already happened in practice. + _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). @@ -475,16 +534,16 @@ if (echo >conf$$.file) 2>/dev/null; then # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. + # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' + as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi else - as_ln_s='cp -p' + as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null @@ -496,28 +555,8 @@ else as_mkdir_p=false fi -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x +as_test_x='test -x' +as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" @@ -525,162 +564,14 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -# Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} -case X$ECHO in -X*--fallback-echo) - # Remove one level of quotation (which was required for Make). - ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','` - ;; -esac - -echo=${ECHO-echo} -if test "X$1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X$1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then - # Yippee, $echo works! - : -else - # Restart under the correct shell. - exec $SHELL "$0" --no-reexec ${1+"$@"} -fi - -if test "X$1" = X--fallback-echo; then - # used as fallback echo - shift - cat </dev/null 2>&1 && unset CDPATH - -if test -z "$ECHO"; then -if test "X${echo_test_string+set}" != Xset; then -# find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if (echo_test_string=`eval $cmd`) 2>/dev/null && - echo_test_string=`eval $cmd` && - (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null - then - break - fi - done -fi - -if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : -else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. - - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for dir in $PATH /usr/ucb; do - IFS="$lt_save_ifs" - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$dir/echo" - break - fi - done - IFS="$lt_save_ifs" - - if test "X$echo" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - echo='print -r' - elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running configure again with it. - ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"} - else - # Try using printf. - echo='printf %s\n' - if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # Cool, printf works - : - elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - echo="$CONFIG_SHELL $0 --fallback-echo" - elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$CONFIG_SHELL $0 --fallback-echo" - else - # maybe with a smaller string... - prev=: - - for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do - if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null - then - break - fi - prev="$cmd" - done - - if test "$prev" != 'sed 50q "$0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"} - else - # Oops. We lost completely, so just stick with echo. - echo=echo - fi - fi - fi - fi -fi -fi - -# Copy echo and quote the copy suitably for passing to libtool from -# the Makefile, instead of quoting the original, which is used later. -ECHO=$echo -if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then - ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo" -fi - - - test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. -# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, +# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` @@ -697,15 +588,13 @@ MFLAGS= MAKEFLAGS= # Identity of this package. -PACKAGE_NAME= -PACKAGE_TARNAME= -PACKAGE_VERSION= -PACKAGE_STRING= -PACKAGE_BUGREPORT= -PACKAGE_URL= - -ac_unique_file="main.c" -ac_unique_file="header.h" +PACKAGE_NAME='sntp' +PACKAGE_TARNAME='sntp' +PACKAGE_VERSION='4.2.8p4' +PACKAGE_STRING='sntp 4.2.8p4' +PACKAGE_BUGREPORT='http://bugs.ntp.org./' +PACKAGE_URL='http://www.ntp.org./' + # Factoring default headers for most tests. ac_includes_default="\ #include @@ -742,30 +631,185 @@ ac_includes_default="\ # include #endif" +ac_header_list= +enable_option_checking=no ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS -LIBOBJS -BINSUBDIR -HAVE_INLINE +GTEST_AVAILABLE_FALSE +GTEST_AVAILABLE_TRUE +GTEST_CPPFLAGS +GTEST_CXXFLAGS +GTEST_LIBS +GTEST_LDFLAGS +GTEST_CONFIG +CXXCPP +am__fastdepCXX_FALSE +am__fastdepCXX_TRUE +CXXDEPMODE +ac_ct_CXX +CXXFLAGS +CXX +UNITYBUILD_AVAILABLE_FALSE +UNITYBUILD_AVAILABLE_TRUE +PATH_RUBY +VER_SUFFIX +LIB_SYSLOG +subdirs +BUILD_LIBEVENT_FALSE +BUILD_LIBEVENT_TRUE +LDADD_LIBEVENT +CPPFLAGS_LIBEVENT +CFLAGS_LIBEVENT +PKG_CONFIG +NTP_FORCE_LIBEVENT_DIST +LIBOPTS_DIR LIBOPTS_CFLAGS LIBOPTS_LDADD NEED_LIBOPTS_FALSE NEED_LIBOPTS_TRUE INSTALL_LIBOPTS_FALSE INSTALL_LIBOPTS_TRUE -LIBOPTS_DIR -LIBTOOL -CPP +POSIX_SHELL +GL_GENERATE_STDNORETURN_H_FALSE +GL_GENERATE_STDNORETURN_H_TRUE +STDNORETURN_H +BUILD_SNTP_FALSE +BUILD_SNTP_TRUE +SNTP +LIBTOOL_DEPS +OTOOL64 +OTOOL +LIPO +NMEDIT +DSYMUTIL +MANIFEST_TOOL RANLIB -AR -ECHO +DLLTOOL +OBJDUMP LN_S +NM +ac_ct_DUMPBIN +DUMPBIN +LIBTOOL +LIBOBJS +PTHREADS_FALSE +PTHREADS_TRUE +LIBISC_PTHREADS_NOTHREADS +PTHREAD_LIBS +LTHREAD_LIBS +BUILD_THREAD +HAVE_INLINE +LDADD_LIBUTIL +ALLOCA +LIBM +EDITLINE_LIBS +LD +FGREP +SED +LDADD_LIBNTP +NTP_CROSSCOMPILE_FALSE +NTP_CROSSCOMPILE_TRUE +ac_ct_AR +AR +INSTALL_UPDATE_LEAP_FALSE +INSTALL_UPDATE_LEAP_TRUE +UPDATE_LEAP_NI +UPDATE_LEAP_MS +UPDATE_LEAP_DS +UPDATE_LEAP_DL +UPDATE_LEAP_DB +TIMETRIM_NI +TIMETRIM_MS +TIMETRIM_DS +TIMETRIM_DL +TIMETRIM_DB +TICKADJ_NI +TICKADJ_MS +TICKADJ_DS +TICKADJ_DL +TICKADJ_DB +SNTP_NI +SNTP_MS +SNTP_DS +SNTP_DL +SNTP_DB +NTP_WAIT_NI +NTP_WAIT_MS +NTP_WAIT_DS +NTP_WAIT_DL +NTP_WAIT_DB +NTP_KEYGEN_NI +NTP_KEYGEN_MS +NTP_KEYGEN_DS +NTP_KEYGEN_DL +NTP_KEYGEN_DB +NTPTRACE_NI +NTPTRACE_MS +NTPTRACE_DS +NTPTRACE_DL +NTPTRACE_DB +NTPTIME_NI +NTPTIME_MS +NTPTIME_DS +NTPTIME_DL +NTPTIME_DB +INSTALL_NTPSWEEP_FALSE +INSTALL_NTPSWEEP_TRUE +NTPSWEEP_NI +NTPSWEEP_MS +NTPSWEEP_DS +NTPSWEEP_DL +NTPSWEEP_DB +NTPSNMPD_NI +NTPSNMPD_MS +NTPSNMPD_DS +NTPSNMPD_DL +NTPSNMPD_DB +NTPQ_NI +NTPQ_MS +NTPQ_DS +NTPQ_DL +NTPQ_DB +NTPD_NI +NTPD_MS +NTPD_DS +NTPD_DL +NTPD_DB +NTPDSIM_NI +NTPDSIM_MS +NTPDSIM_DS +NTPDSIM_DL +NTPDSIM_DB +NTPDC_NI +NTPDC_MS +NTPDC_DS +NTPDC_DL +NTPDC_DB +NTPDATE_NI +NTPDATE_MS +NTPDATE_DS +NTPDATE_DL +NTPDATE_DB +MANTAGFMT +CALC_TICKADJ_NI +CALC_TICKADJ_MS +CALC_TICKADJ_DS +CALC_TICKADJ_DL +CALC_TICKADJ_DB +WANT_CALC_TICKADJ_MS_FALSE +WANT_CALC_TICKADJ_MS_TRUE +LDFLAGS_NTP +LDADD_NTP +CPPFLAGS_NTP +CFLAGS_NTP EGREP GREP +CPP am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE +am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE @@ -787,6 +831,10 @@ build_os build_vendor build_cpu build +AM_BACKSLASH +AM_DEFAULT_VERBOSITY +AM_DEFAULT_V +AM_V am__untar am__tar AMTAR @@ -851,14 +899,27 @@ SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking +enable_silent_rules enable_dependency_tracking +with_locfile +with_gnu_ld +with_lineeditlibs +enable_debugging +enable_thread_support +with_threads +with_yielding_select +enable_c99_snprintf +enable_clockctl +enable_linuxcaps +enable_solarisprivs enable_shared enable_static +with_pic enable_fast_install -with_gnu_ld +with_sysroot enable_libtool_lock -with_pic -with_tags +with_sntp +enable_nls enable_local_libopts enable_libopts_install with_autoopts_config @@ -867,7 +928,15 @@ with_libregex with_libregex_cflags with_libregex_libs enable_optional_args -with_binsubdir +enable_local_libevent +with_crypto +with_openssl_libdir +with_openssl_incdir +with_rpath +enable_ipv6 +with_kame +enable_getifaddrs +with_gtest ' ac_precious_vars='build_alias host_alias @@ -877,8 +946,12 @@ CFLAGS LDFLAGS LIBS CPPFLAGS -CPP' - +CPP +CXX +CXXFLAGS +CCC +CXXCPP' +ac_subdirs_all='libevent' # Initialize some variables set by options. ac_init_help= @@ -918,7 +991,7 @@ sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE}' +docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' @@ -940,8 +1013,9 @@ do fi case $ac_option in - *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *) ac_optarg=yes ;; + *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; + *=) ac_optarg= ;; + *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. @@ -986,7 +1060,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" + as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1012,7 +1086,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid feature name: $ac_useropt" + as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1216,7 +1290,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" + as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1232,7 +1306,7 @@ do ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error "invalid package name: $ac_useropt" + as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1262,8 +1336,8 @@ do | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; - -*) as_fn_error "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information." + -*) as_fn_error $? "unrecognized option: \`$ac_option' +Try \`$0 --help' for more information" ;; *=*) @@ -1271,7 +1345,7 @@ Try \`$0 --help' for more information." # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error "invalid variable name: \`$ac_envvar'" ;; + as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; @@ -1281,7 +1355,7 @@ Try \`$0 --help' for more information." $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac @@ -1289,13 +1363,13 @@ done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error "missing argument to $ac_option" + as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; - fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; + fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi @@ -1318,7 +1392,7 @@ do [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac - as_fn_error "expected an absolute directory name for --$ac_var: $ac_val" + as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' @@ -1332,8 +1406,6 @@ target=$target_alias if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe - $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. - If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi @@ -1348,9 +1420,9 @@ test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error "working directory cannot be determined" + as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error "pwd does not report name of working directory" + as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. @@ -1389,11 +1461,11 @@ else fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" + as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg" + cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then @@ -1419,7 +1491,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures this package to adapt to many kinds of systems. +\`configure' configures sntp 4.2.8p4 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1433,7 +1505,7 @@ Configuration: --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking...' messages + -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files @@ -1467,7 +1539,7 @@ Fine tuning of the installation directories: --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] + --docdir=DIR documentation root [DATAROOTDIR/doc/sntp] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] @@ -1488,38 +1560,71 @@ _ACEOF fi if test -n "$ac_init_help"; then - + case $ac_init_help in + short | recursive ) echo "Configuration of sntp 4.2.8p4:";; + esac cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors + --enable-silent-rules less verbose build output (undo: "make V=1") + --disable-silent-rules verbose build output (undo: "make V=0") + --enable-dependency-tracking + do not reject slow dependency extractors + --disable-dependency-tracking + speeds up one-time build + defaults: + yes, - no, s system-specific + --enable-debugging + include ntpd debugging code + --enable-thread-support s use threads (+ if available) + --enable-c99-snprintf s force replacement + --enable-clockctl s Use /dev/clockctl for non-root clock control + --enable-linuxcaps + Use Linux capabilities for non-root clock control + --enable-solarisprivs + Use Solaris privileges for non-root clock control --enable-shared[=PKGS] build shared libraries [default=no] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) - --enable-local-libopts Force using the supplied libopts tearoff code - --disable-libopts-install - Do not install libopts with client installation + --disable-nls disable nls support in libopts + --enable-local-libopts Use the supplied libopts tearoff code + --enable-libopts-install + Install libopts with client installation --disable-optional-args not wanting optional option args + --enable-local-libevent Force using the supplied libevent tearoff code + --enable-ipv6 s use IPv6? + + --enable-getifaddrs + Enable the use of getifaddrs() [[yes|no]]. Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-locfile=XXX os-specific or "legacy" --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-lineeditlibs edit,editline (readline may be specified if desired) + --with-threads with threads [auto] + --with-yielding-select with yielding select [auto] --with-pic try to use only PIC/non-PIC objects [default=use both] - --with-tags[=TAGS] include additional configurations [automatic] + --with-sysroot=DIR Search for dependent libraries within DIR + (or the compiler's sysroot if not specified). + --without-sntp - disable building sntp and sntp/tests --with-autoopts-config specify the config-info script --with-regex-header a reg expr header is specified --with-libregex libregex installation prefix --with-libregex-cflags libregex compile flags --with-libregex-libs libregex link command arguments - --with-binsubdir bin ={bin,sbin} + --with-crypto + =openssl,libcrypto + + --with-openssl-libdir + =/something/reasonable + + --with-openssl-incdir + =/something/reasonable + + --without-rpath s Disable auto-added -R linker paths + + --with-kame - =/usr/local/v6 + --with-gtest Use the gtest framework (Default: if it's available) Some influential environment variables: CC C compiler command @@ -1530,11 +1635,15 @@ Some influential environment variables: CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor + CXX C++ compiler command + CXXFLAGS C++ compiler flags + CXXCPP C++ preprocessor Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. -Report bugs to the package provider. +Report bugs to . +sntp home page: . _ACEOF ac_status=$? fi @@ -1597,10 +1706,10 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -configure -generated by GNU Autoconf 2.65 +sntp configure 4.2.8p4 +generated by GNU Autoconf 2.69 -Copyright (C) 2009 Free Software Foundation, Inc. +Copyright (C) 2012 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF @@ -1644,57 +1753,11 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link - # ac_fn_c_try_cpp LINENO # ---------------------- # Try to preprocess conftest.$ac_ext, and return whether this succeeded. @@ -1716,7 +1779,7 @@ $as_echo "$ac_try_echo"; } >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } >/dev/null && { + test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : @@ -1727,7 +1790,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp @@ -1740,10 +1803,10 @@ fi ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : + if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 @@ -1779,7 +1842,7 @@ if ac_fn_c_try_cpp "$LINENO"; then : else ac_header_preproc=no fi -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } @@ -1802,11 +1865,15 @@ $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} +( $as_echo "## ------------------------------------ ## +## Report this to http://bugs.ntp.org./ ## +## ------------------------------------ ##" + ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" @@ -1815,7 +1882,7 @@ eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel @@ -1856,7 +1923,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run @@ -1870,7 +1937,7 @@ ac_fn_c_check_header_compile () as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -1888,10 +1955,110 @@ fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile +# ac_fn_c_try_link LINENO +# ----------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_link + +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type + # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly @@ -1900,7 +2067,7 @@ ac_fn_c_check_func () as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -1955,63 +2122,55 @@ fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () +# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES +# --------------------------------------------- +# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR +# accordingly. +ac_fn_c_check_decl () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : + as_decl_name=`echo $2|sed 's/ *(.*//'` + as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 +$as_echo_n "checking whether $as_decl_name is declared... " >&6; } +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else - eval "$3=no" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { -if (sizeof ($2)) - return 0; +#ifndef $as_decl_name +#ifdef __cplusplus + (void) $as_decl_use; +#else + (void) $as_decl_name; +#endif +#endif + ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main () -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno -} # ac_fn_c_check_type +} # ac_fn_c_check_decl # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES # -------------------------------------------- @@ -2030,7 +2189,8 @@ int main () { static int test_array [1 - 2 * !(($2) >= 0)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2046,7 +2206,8 @@ int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2072,7 +2233,8 @@ int main () { static int test_array [1 - 2 * !(($2) < 0)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2088,7 +2250,8 @@ int main () { static int test_array [1 - 2 * !(($2) >= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2122,7 +2285,8 @@ int main () { static int test_array [1 - 2 * !(($2) <= $ac_mid)]; -test_array [0] = 0 +test_array [0] = 0; +return test_array [0]; ; return 0; @@ -2186,16 +2350,194 @@ rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ rm -f conftest.val fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_compute_int + +# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES +# ---------------------------------------------------- +# Tries to find if the field MEMBER exists in type AGGR, after including +# INCLUDES, setting cache variable VAR accordingly. +ac_fn_c_check_member () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 +$as_echo_n "checking for $2.$3... " >&6; } +if eval \${$4+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$5 +int +main () +{ +static $2 ac_aggr; +if (ac_aggr.$3) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$4=yes" +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$5 +int +main () +{ +static $2 ac_aggr; +if (sizeof ac_aggr.$3) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$4=yes" +else + eval "$4=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$4 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_member + +# ac_fn_cxx_try_compile LINENO +# ---------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_compile + +# ac_fn_cxx_try_cpp LINENO +# ------------------------ +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_cpp + +# ac_fn_cxx_try_link LINENO +# ------------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_link cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by $as_me, which was -generated by GNU Autoconf 2.65. Invocation command line was +It was created by sntp $as_me 4.2.8p4, which was +generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -2305,11 +2647,9 @@ trap 'exit_status=$? { echo - cat <<\_ASBOX -## ---------------- ## + $as_echo "## ---------------- ## ## Cache variables. ## -## ---------------- ## -_ASBOX +## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( @@ -2343,11 +2683,9 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; ) echo - cat <<\_ASBOX -## ----------------- ## + $as_echo "## ----------------- ## ## Output variables. ## -## ----------------- ## -_ASBOX +## ----------------- ##" echo for ac_var in $ac_subst_vars do @@ -2360,11 +2698,9 @@ _ASBOX echo if test -n "$ac_subst_files"; then - cat <<\_ASBOX -## ------------------- ## + $as_echo "## ------------------- ## ## File substitutions. ## -## ------------------- ## -_ASBOX +## ------------------- ##" echo for ac_var in $ac_subst_files do @@ -2378,11 +2714,9 @@ _ASBOX fi if test -s confdefs.h; then - cat <<\_ASBOX -## ----------- ## + $as_echo "## ----------- ## ## confdefs.h. ## -## ----------- ## -_ASBOX +## ----------- ##" echo cat confdefs.h echo @@ -2437,7 +2771,12 @@ _ACEOF ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then - ac_site_file1=$CONFIG_SITE + # We do not want a PATH search for config.site. + case $CONFIG_SITE in #(( + -*) ac_site_file1=./$CONFIG_SITE;; + */*) ac_site_file1=$CONFIG_SITE;; + *) ac_site_file1=./$CONFIG_SITE;; + esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site @@ -2452,7 +2791,11 @@ do { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" + . "$ac_site_file" \ + || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "failed to load site script $ac_site_file +See \`config.log' for more details" "$LINENO" 5; } fi done @@ -2473,6 +2816,7 @@ $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi +as_fn_append ac_header_list " stdarg.h" # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false @@ -2528,7 +2872,7 @@ if $ac_cache_corrupted; then $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 + as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## @@ -2541,20 +2885,25 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $ ac_compiler_gnu=$ac_cv_c_compiler_gnu -am__api_version='1.11' ac_aux_dir= -for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do - for ac_t in install-sh install.sh shtool; do - if test -f "$ac_dir/$ac_t"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/$ac_t -c" - break 2 - fi - done +for ac_dir in libevent/build-aux "$srcdir"/libevent/build-aux; do + if test -f "$ac_dir/install-sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f "$ac_dir/install.sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + elif test -f "$ac_dir/shtool"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break + fi done if test -z "$ac_aux_dir"; then - as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 + as_fn_error $? "cannot find install-sh, install.sh, or shtool in libevent/build-aux \"$srcdir\"/libevent/build-aux" "$LINENO" 5 fi # These three variables are undocumented and unsupported, @@ -2566,6 +2915,140 @@ ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Bump sntp_configure_cache_version for each change to configure.ac or +# .m4 files which invalidates cached values from previous configure +# runs. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of each. If you are not sure, the +# safe choice is to bump all on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +sntp_configure_cache_version=20120806 + +# When the version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + + + + ntp_cache_flush=1 + + case "$ntp_cv_sntp_cache_version" in + $sntp_configure_cache_version) + # same version, good + ntp_cache_flush=0 + ;; + '') + # No cache, predates ntp_cv_sntp_cache_version, or is empty. + case "$cache_file" in + /dev/null) + ntp_cache_flush=0 + ;; + *) + case "$NTP_CACHEVERSION_PARENT" in + '') + # Do not clear the cache immediately after it is created + # empty as it is noisy. Differentiate a newly-created + # config.cache from one predating the cache version + # mechanism by looking for the first cached variable set + # by Autoconf + case "$ac_cv_path_install" in + '') + # empty config.cache file + ntp_cache_flush=0 + esac + ;; + *) + # Parent configure just created cache from empty, + # flushing would be counterproductive. + ntp_cache_flush=0; + ;; + esac + esac + ;; + *) + # configure cache version mismatches config.cache version + ;; + esac + + case "$ntp_cache_flush" in + 1) + c_version="${ntp_cv_sntp_cache_version:-(no version found)}" + + # Do we flush all variables or exclude others' version stamps? + + case "$NTP_CACHEVERSION_PARENT" in + '') + # Clear all *_cv_* variables including our child subdirs' + # ntp_cv_*_cache_version variables. This prevents subdir + # configure scripts from noticing a version mismatch just + # after the top configure in the invocation cleared and + # recreated the cache. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/_cv_/p' + ` + ;; + *) + # This is not the top configure this particular invocation. + # Clear all *_cv_* variables sparing the version stamps + # of other configure scripts, so we don't trigger + # useless repeated clearings. + + c_varname_list=`set | + sed -n -e 's/=.*$//' \ + -e '/ntp_cv_.*_cache_version/d' \ + -e '/_cv_/p' + ` + esac + + for c_varname in $c_varname_list + do + { eval $c_varname=; unset $c_varname; } + done + + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file saved by another version, ignored." >&5 +$as_echo "$as_me: $cache_file saved by another version, ignored." >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: configure script cache version: $sntp_configure_cache_version" >&5 +$as_echo "$as_me: configure script cache version: $sntp_configure_cache_version" >&6;} + { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file version: $c_version" >&5 +$as_echo "$as_me: $cache_file version: $c_version" >&6;} + { c_varname=; unset c_varname;} + { c_varname_list=; unset c_varname_list;} + { c_version=; unset c_version;} + esac + + { ntp_cache_flush=; unset ntp_cache_flush;} + + # save configure version in config.cache for next time + ntp_cv_sntp_cache_version="$sntp_configure_cache_version" + + # let any subdir configure.ac NTP_CACHEVERSION invocations + # know they are not the top level. + NTP_CACHEVERSION_PARENT='sntp' ; export NTP_CACHEVERSION_PARENT + + +am__api_version='1.15' + # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: @@ -2583,7 +3066,7 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then -if test "${ac_cv_path_install+set}" = set; then : +if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -2603,7 +3086,7 @@ case $as_dir/ in #(( # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. @@ -2661,56 +3144,71 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } -# Just in case -sleep 1 -echo timestamp > conftest.file # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[\\\"\#\$\&\'\`$am_lf]*) - as_fn_error "unsafe absolute working directory name" "$LINENO" 5;; + as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; + as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; esac -# Do `set' in a subshell so we don't clobber the current shell's +# Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error "ls -t appears to fail. Make sure there is not a broken -alias in your environment" "$LINENO" 5 - fi - + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$*" != "X $srcdir/configure conftest.file" \ + && test "$*" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken + alias in your environment" "$LINENO" 5 + fi + if test "$2" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done test "$2" = conftest.file ) then # Ok. : else - as_fn_error "newly created file is older than distributed files! + as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi + +rm -f conftest.file + test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. @@ -2721,8 +3219,8 @@ test "$program_suffix" != NONE && ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` if test x"${MISSING+set}" != xset; then case $am_aux_dir in @@ -2733,15 +3231,15 @@ if test x"${MISSING+set}" != xset; then esac fi # Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " else am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} fi -if test x"${install_sh}" != xset; then +if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; @@ -2750,17 +3248,17 @@ if test x"${install_sh}" != xset; then esac fi -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. +# will honor the 'STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then : +if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then @@ -2772,7 +3270,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -2800,7 +3298,7 @@ if test -z "$ac_cv_prog_STRIP"; then set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then @@ -2812,7 +3310,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -2853,7 +3351,7 @@ INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } if test -z "$MKDIR_P"; then - if test "${ac_cv_path_mkdir+set}" = set; then : + if ${ac_cv_path_mkdir+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -2863,7 +3361,7 @@ do test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do - { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue + as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ @@ -2892,19 +3390,13 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } -mkdir_p="$MKDIR_P" -case $mkdir_p in - [\\/$]* | ?:[\\/]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac - for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AWK+set}" = set; then : +if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then @@ -2916,7 +3408,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -2944,7 +3436,7 @@ done $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF @@ -2952,7 +3444,7 @@ SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF -# GNU make sometimes prints "make[1]: Entering...", which would confuse us. +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; @@ -2980,13 +3472,52 @@ else fi rmdir .tst 2>/dev/null +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=1;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then - as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 + as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi fi @@ -3001,8 +3532,8 @@ fi # Define the identity of the package. - PACKAGE=msntp - VERSION=1.6 + PACKAGE='sntp' + VERSION='4.2.8p4' cat >>confdefs.h <<_ACEOF @@ -3030,42 +3561,134 @@ AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -# Always define AMTAR for backward compatibility. +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +mkdir_p='$(MKDIR_P)' -AMTAR=${AMTAR-"${am_missing_run}tar"} +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AMTAR='$${TAR-tar}' -am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar pax cpio none' +am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' -# Make sure we can run config.sub. -$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 -$as_echo_n "checking build system type... " >&6; } -if test "${ac_cv_build+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_build_alias=$build_alias -test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` -test "x$ac_build_alias" = x && - as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5 -ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 + fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 -$as_echo "$ac_cv_build" >&6; } -case $ac_cv_build in + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=0;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + + +# Make sure we can run config.sub. +$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || + as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 +$as_echo_n "checking build system type... " >&6; } +if ${ac_cv_build+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_build_alias=$build_alias +test "x$ac_build_alias" = x && + ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` +test "x$ac_build_alias" = x && + as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 +ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 +$as_echo "$ac_cv_build" >&6; } +case $ac_cv_build in *-*-*) ;; -*) as_fn_error "invalid value of canonical build" "$LINENO" 5;; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' @@ -3083,14 +3706,14 @@ case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } -if test "${ac_cv_host+set}" = set; then : +if ${ac_cv_host+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 fi fi @@ -3098,7 +3721,7 @@ fi $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; -*) as_fn_error "invalid value of canonical host" "$LINENO" 5;; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' @@ -3114,10 +3737,77 @@ IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac + +cat >>confdefs.h <<_ACEOF +#define STR_SYSTEM "$host" +_ACEOF + ac_config_headers="$ac_config_headers config.h" -# Checks for programs. +DEPDIR="${am__leading_dot}deps" + +ac_config_commands="$ac_config_commands depfiles" + + +am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 +$as_echo_n "checking for style of include used by $am_make... " >&6; } +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 +$as_echo "$_am_result" >&6; } +rm -f confinc confmf + +# Check whether --enable-dependency-tracking was given. +if test "${enable_dependency_tracking+set}" = set; then : + enableval=$enable_dependency_tracking; +fi + +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi + if test "x$enable_dependency_tracking" != xno; then + AMDEP_TRUE= + AMDEP_FALSE='#' +else + AMDEP_TRUE='#' + AMDEP_FALSE= +fi + + ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -3128,7 +3818,7 @@ if test -n "$ac_tool_prefix"; then set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3140,7 +3830,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3168,7 +3858,7 @@ if test -z "$ac_cv_prog_CC"; then set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -3180,7 +3870,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3221,7 +3911,7 @@ if test -z "$CC"; then set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3233,7 +3923,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3261,7 +3951,7 @@ if test -z "$CC"; then set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3274,7 +3964,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue @@ -3320,7 +4010,7 @@ if test -z "$CC"; then set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3332,7 +4022,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3364,7 +4054,7 @@ do set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -3376,7 +4066,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 @@ -3418,8 +4108,8 @@ fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "no acceptable C compiler found in \$PATH -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 @@ -3533,9 +4223,8 @@ sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "C compiler cannot create executables -See \`config.log' for more details." "$LINENO" 5; }; } +as_fn_error 77 "C compiler cannot create executables +See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } @@ -3577,8 +4266,8 @@ done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "cannot compute suffix of executables: cannot compile and link +See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 @@ -3635,9 +4324,9 @@ $as_echo "$ac_try_echo"; } >&5 else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot run C compiled programs. +as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. -See \`config.log' for more details." "$LINENO" 5; } +See \`config.log' for more details" "$LINENO" 5; } fi fi fi @@ -3648,7 +4337,7 @@ rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } -if test "${ac_cv_objext+set}" = set; then : +if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -3688,8 +4377,8 @@ sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "cannot compute suffix of object files: cannot compile -See \`config.log' for more details." "$LINENO" 5; } +as_fn_error $? "cannot compute suffix of object files: cannot compile +See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi @@ -3699,7 +4388,7 @@ OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then : +if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -3736,7 +4425,7 @@ ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then : +if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag @@ -3814,7 +4503,7 @@ else fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : +if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no @@ -3823,8 +4512,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include -#include -#include +struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); @@ -3908,82 +4596,80 @@ ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu -DEPDIR="${am__leading_dot}deps" - -ac_config_commands="$ac_config_commands depfiles" - - -am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo this is the am__doit target -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 -$as_echo_n "checking for style of include used by $am_make... " >&6; } -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 -$as_echo "$_am_result" >&6; } -rm -f confinc confmf +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then : - enableval=$enable_dependency_tracking; -fi +int +main () +{ -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' -fi - if test "x$enable_dependency_tracking" != xno; then - AMDEP_TRUE= - AMDEP_FALSE='#' -else - AMDEP_TRUE='#' - AMDEP_FALSE= + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" fi - +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } -if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then : +if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -4017,16 +4703,16 @@ else : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with `-c' and `-o' for the sake of the "dashmstdout" + # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in @@ -4035,16 +4721,16 @@ else test "$am__universal" = false || continue ;; nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} @@ -4099,145 +4785,147 @@ fi -# So far, the only shared library we might use is libopts. -# It's a small library - we might as well use a static version of it. -# Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then : - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac -else - enable_shared=no +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + done + ac_cv_prog_CPP=$CPP - - -# Check whether --enable-static was given. -if test "${enable_static+set}" = set; then : - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac +fi + CPP=$ac_cv_prog_CPP else - enable_static=yes + ac_cv_prog_CPP=$CPP fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : - -# Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then : - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac else - enable_fast_install=yes + # Broken: fails on valid input. +continue fi +rm -f conftest.err conftest.i conftest.$ac_ext - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if test "${lt_cv_path_SED+set}" = set; then : - $as_echo_n "(cached) " >&6 + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue else - # Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } fi -SED=$lt_cv_path_SED -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 -$as_echo "$SED" >&6; } +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then : +if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then @@ -4251,7 +4939,7 @@ do for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue + as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in @@ -4286,7 +4974,7 @@ esac done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then - as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP @@ -4300,7 +4988,7 @@ $as_echo "$ac_cv_path_GREP" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then : +if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 @@ -4317,7 +5005,7 @@ do for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue + as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in @@ -4352,7 +5040,7 @@ esac done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then - as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP @@ -4365,9706 +5053,9608 @@ $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" - -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes -else - with_gnu_ld=no -fi - -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } -fi -if test "${lt_cv_path_LD+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else - if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes else - lt_cv_path_LD="$LD" # Let the user override the test with a path. -fi + ac_cv_header_stdc=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : -LD="$lt_cv_path_LD" -if test -n "$LD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 -$as_echo "$LD" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + ac_cv_header_stdc=no fi -test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if test "${lt_cv_prog_gnu_ld+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if test "${lt_cv_ld_reload_flag+set}" = set; then : - $as_echo_n "(cached) " >&6 else - lt_cv_ld_reload_flag='-r' + ac_cv_header_stdc=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - darwin*) - if test "$GCC" = yes; then - reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac +rm -f conftest* -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD-compatible nm" >&5 -$as_echo_n "checking for BSD-compatible nm... " >&6; } -if test "${lt_cv_path_NM+set}" = set; then : - $as_echo_n "(cached) " >&6 +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : else - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif + +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + else - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/${ac_tool_prefix}nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - esac - fi - done - IFS="$lt_save_ifs" - test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm + ac_cv_header_stdc=no fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -$as_echo "$lt_cv_path_NM" >&6; } -NM="$lt_cv_path_NM" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognise dependent libraries" >&5 -$as_echo_n "checking how to recognise dependent libraries... " >&6; } -if test "${lt_cv_deplibs_check_method+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. - -case $host_os in -aix4* | aix5*) - lt_cv_deplibs_check_method=pass_all - ;; +$as_echo "#define STDC_HEADERS 1" >>confdefs.h -beos*) - lt_cv_deplibs_check_method=pass_all - ;; +fi -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; +# On IRIX 5.3, sys/types and inttypes.h are conflicting. +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; +fi -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump'. - lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; +done -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; -freebsd* | kfreebsd*-gnu | dragonfly*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; + ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" +if test "x$ac_cv_header_minix_config_h" = xyes; then : + MINIX=yes +else + MINIX= +fi -# This must be Linux ELF. -linux*) - lt_cv_deplibs_check_method=pass_all - ;; -netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; + if test "$MINIX" = yes; then -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; +$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h -nto-qnx*) - lt_cv_deplibs_check_method=unknown - ;; -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - fi - ;; +$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; -sco3.2v5*) - lt_cv_deplibs_check_method=pass_all - ;; +$as_echo "#define _MINIX 1" >>confdefs.h -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; + fi -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; + case "$host_os" in + hpux*) -sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac +$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 -$as_echo "$lt_cv_deplibs_check_method" >&6; } -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 +$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } +if ${ac_cv_safe_to_define___extensions__+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +# define __EXTENSIONS__ 1 + $ac_includes_default +int +main () +{ -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_safe_to_define___extensions__=yes +else + ac_cv_safe_to_define___extensions__=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 +$as_echo "$ac_cv_safe_to_define___extensions__" >&6; } + test $ac_cv_safe_to_define___extensions__ = yes && + $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h -# Allow CC to be a program name with arguments. -compiler=$CC + $as_echo "#define _ALL_SOURCE 1" >>confdefs.h + $as_echo "#define _GNU_SOURCE 1" >>confdefs.h -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; -fi + $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '#line 4774 "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; -x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if test "${lt_cv_cc_needs_belf+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +#include +struct stat; +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; int main () { - +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_cc_needs_belf=yes -else - lt_cv_cc_needs_belf=no +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; - +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac +if test "x$ac_cv_prog_cc_c89" != xno; then : -need_locks="$enable_libtool_lock" +fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5 +$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } +if ${ac_cv_prog_cc_c99+:} false; then : $as_echo_n "(cached) " >&6 else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_cv_prog_cc_c99=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifdef __STDC__ -# include +#include +#include +#include +#include +#include + +// Check varargs macros. These examples are taken from C99 6.10.3.5. +#define debug(...) fprintf (stderr, __VA_ARGS__) +#define showlist(...) puts (#__VA_ARGS__) +#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) +static void +test_varargs_macros (void) +{ + int x = 1234; + int y = 5678; + debug ("Flag"); + debug ("X = %d\n", x); + showlist (The first, second, and third items.); + report (x>y, "x is %d but y is %d", x, y); +} + +// Check long long types. +#define BIG64 18446744073709551615ull +#define BIG32 4294967295ul +#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) +#if !BIG_OK + your preprocessor is broken; +#endif +#if BIG_OK #else -# include + your preprocessor is broken; #endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +static long long int bignum = -9223372036854775807LL; +static unsigned long long int ubignum = BIG64; -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.$ac_ext +struct incomplete_array +{ + int datasize; + double data[]; +}; - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.$ac_ext +struct named_init { + int number; + const wchar_t *name; + double average; +}; -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break -fi +typedef const char *ccp; - done - ac_cv_prog_CPP=$CPP +static inline int +test_restrict (ccp restrict text) +{ + // See if C++-style comments work. + // Iterate through items via the restricted pointer. + // Also check for declarations in for loops. + for (unsigned int i = 0; *(text+i) != '\0'; ++i) + continue; + return 0; +} -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include -#else -# include -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - -else - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu +// Check varargs and va_copy. +static void +test_varargs (const char *format, ...) +{ + va_list args; + va_start (args, format); + va_list args_copy; + va_copy (args_copy, args); + const char *str; + int number; + float fnumber; -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include + while (*format) + { + switch (*format++) + { + case 's': // string + str = va_arg (args_copy, const char *); + break; + case 'd': // int + number = va_arg (args_copy, int); + break; + case 'f': // float + fnumber = va_arg (args_copy, double); + break; + default: + break; + } + } + va_end (args_copy); + va_end (args); +} int main () { - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : + // Check bool. + _Bool success = false; -else - ac_cv_header_stdc=no -fi -rm -f conftest* + // Check restrict. + if (test_restrict ("String literal") == 0) + success = true; + char *restrict newvar = "Another string"; -fi + // Check varargs. + test_varargs ("s, d' f .", "string", 65, 34.234); + test_varargs_macros (); -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include + // Check flexible array members. + struct incomplete_array *ia = + malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); + ia->datasize = 10; + for (int i = 0; i < ia->datasize; ++i) + ia->data[i] = i * 1.234; -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : + // Check named initializers. + struct named_init ni = { + .number = 34, + .name = L"Test wide string", + .average = 543.34343, + }; -else - ac_cv_header_stdc=no -fi -rm -f conftest* + ni.number = 58; -fi + int dynamic_array[ni.number]; + dynamic_array[ni.number - 1] = 543; -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif + // work around unused variable warnings + return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' + || dynamic_array[ni.number - 1] != 543); -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; + ; return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext +for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99 +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c99=$ac_arg fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c99" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c99" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c99" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 +$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c99" != xno; then : fi -# On IRIX 5.3, sys/types and inttypes.h are conflicting. -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default -" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi -done -for ac_header in dlfcn.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default" -if test "x$ac_cv_header_dlfcn_h" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DLFCN_H 1 -_ACEOF -fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done +IFS=$as_save_IFS +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! -# find the maximum length of command line arguments -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if test "${lt_cv_sys_max_cmd_len+set}" = set; then : +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else - i=0 - teststring="ABCD" + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +else + CC="$ac_cv_prog_CC" +fi - cygwin* | mingw*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. +set dummy ${ac_tool_prefix}cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - *) - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \ - = "XX$teststring") >/dev/null 2>&1 && - new_result=`expr "X$teststring" : ".*" 2>&1` && - lt_cv_sys_max_cmd_len=$new_result && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - teststring= - # Add a significant safety factor because C++ compilers can tack on massive - # amounts of additional arguments before passing them to the linker. - # It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - ;; - esac + fi fi +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + ac_prog_rejected=no +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -if test -n $lt_cv_sys_max_cmd_len ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" + fi +fi +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 -$as_echo "none" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - - -# Check for command to grab the raw symbol name followed by C symbol from nm. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } -if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then : +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl.exe + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl.exe +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# Transform an extracted symbol line into a proper C declaration -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" -# Define system-specific variables. -case $host_os in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw* | pw32*) - symcode='[ABCDGISTW]' - ;; -hpux*) # Its linker distinguishes data from code symbols - if test "$host_cpu" = ia64; then - symcode='[ABCDEGRST]' - fi - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - ;; -linux*) - if test "$host_cpu" = ia64; then - symcode='[ABCDGIRSTW]' - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - fi - ;; -irix* | nonstopux*) - symcode='[BCDEGRST]' - ;; -osf*) - symcode='[BCDEGQRST]' - ;; -solaris* | sysv5*) - symcode='[BDRT]' - ;; -sysv4) - symcode='[DFNSTU]' - ;; -esac - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac + test -n "$ac_ct_CC" && break +done -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; esac + CC=$ac_ct_CC + fi +fi -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" +fi - # Check to see that the pipe works correctly. - pipe_works=no - rm -f conftest* - cat > conftest.$ac_ext <&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Now try to grab the symbols. - nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if grep ' nm_test_var$' "$nlist" >/dev/null; then - if grep ' nm_test_func$' "$nlist" >/dev/null; then - cat < conftest.$ac_ext -#ifdef __cplusplus -extern "C" { -#endif - -EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' + test $ac_status = 0; } +done - cat <> conftest.$ac_ext -#if defined (__STDC__) && __STDC__ -# define lt_ptr_t void * -#else -# define lt_ptr_t char * -# define const -#endif +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 +$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } +if ${ac_cv_c_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - lt_ptr_t address; -} -lt_preloaded_symbols[] = +int +main () { -EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext - cat <<\EOF >> conftest.$ac_ext - {0, (lt_ptr_t) 0} -}; - -#ifdef __cplusplus -} +#ifndef __GNUC__ + choke me #endif -EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - fi - rm -f conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 +$as_echo "$ac_cv_c_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GCC=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -$as_echo "ok" >&6; } + GCC= fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if test "${lt_cv_objdir+set}" = set; then : +ac_test_CFLAGS=${CFLAGS+set} +ac_save_CFLAGS=$CFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 +$as_echo_n "checking whether $CC accepts -g... " >&6; } +if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir - - + ac_save_c_werror_flag=$ac_c_werror_flag + ac_c_werror_flag=yes + ac_cv_prog_cc_g=no + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int +main () +{ + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +else + CFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac +int +main () +{ -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e 1s/^X//' -sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : -# Same as above, but do not quote variable references. -double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' +else + ac_c_werror_flag=$ac_save_c_werror_flag + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -# Constants: -rm="rm -f" - -# Global variables: -default_ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a -ltmain="$ac_aux_dir/ltmain.sh" -ofile="$default_ofile" -with_gnu_ld="$lt_cv_prog_gnu_ld" - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. -set dummy ${ac_tool_prefix}ar; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AR+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_AR="${ac_tool_prefix}ar" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS +int +main () +{ + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -$as_echo "$AR" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag fi -if test -z "$ac_cv_prog_AR"; then - ac_ct_AR=$AR - # Extract the first word of "ar", so it can be a program name with args. -set dummy ar; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_AR+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_AR="ar" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 +$as_echo "$ac_cv_prog_cc_g" >&6; } +if test "$ac_test_CFLAGS" = set; then + CFLAGS=$ac_save_CFLAGS +elif test $ac_cv_prog_cc_g = yes; then + if test "$GCC" = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-g" fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_AR" = x; then - AR="false" + if test "$GCC" = yes; then + CFLAGS="-O2" else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR + CFLAGS= fi -else - AR="$ac_cv_prog_AR" fi - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +struct stat; +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break done - done -IFS=$as_save_IFS +rm -f conftest.$ac_ext +CC=$ac_save_CC fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c89" != xno; then : + fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int +main () +{ + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +depcc="$CC" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CC_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi -done + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CC_dependencies_compiler_type=$depmode + break + fi + fi done -IFS=$as_save_IFS -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } + cd .. + rm -rf conftest.dir else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + am_cv_CC_dependencies_compiler_type=none fi - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } +CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then + am__fastdepCC_TRUE= + am__fastdepCC_FALSE='#' else - RANLIB="$ac_cv_prog_RANLIB" + am__fastdepCC_TRUE='#' + am__fastdepCC_FALSE= fi -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then : + +# Ralf Wildenhues: With per-target flags we need CC_C_O +# AM_PROG_CC_C_O supersets AC_PROG_CC_C_O + +if test $ac_cv_c_compiler_gnu = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 +$as_echo_n "checking whether $CC needs -traditional... " >&6; } +if ${ac_cv_prog_gcc_traditional+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. + ac_pattern="Autoconf.*'x'" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TIOCGETP +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + ac_cv_prog_gcc_traditional=no +fi +rm -f conftest* + + if test $ac_cv_prog_gcc_traditional = no; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TCGETA +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes fi +rm -f conftest* + + fi fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 +$as_echo "$ac_cv_prog_gcc_traditional" >&6; } + if test $ac_cv_prog_gcc_traditional = yes; then + CC="$CC -traditional" + fi fi -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : + + + +CFLAGS_NTP= +CPPFLAGS_NTP= +LDADD_NTP= +LDFLAGS_NTP= + + + + + +case "$ac_cv_prog_cc_c89" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP + version 4.2.5 and higher." >&5 +$as_echo "$as_me: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP + version 4.2.5 and higher." >&2;} + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5 +$as_echo_n "checking if $CC can handle #warning... " >&6; } +if ${ntp_cv_cpp_warning+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#warning foo + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_cpp_warning=yes else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + ntp_cv_cpp_warning=no fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cpp_warning" >&5 +$as_echo "$ntp_cv_cpp_warning" >&6; } +case "$ntp_cv_cpp_warning" in + no) + +$as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; esac - STRIP=$ac_ct_STRIP - fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports __attribute__((...))" >&5 +$as_echo_n "checking if $CC supports __attribute__((...))... " >&6; } +if ${ntp_cv_cc_attribute+:} false; then : + $as_echo_n "(cached) " >&6 else - STRIP="$ac_cv_prog_STRIP" -fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int +main () +{ +void foo(void) __attribute__((__noreturn__)); -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru -test -z "$AS" && AS=as -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$LD" && LD=ld -test -z "$LN_S" && LN_S="ln -s" -test -z "$MAGIC_CMD" && MAGIC_CMD=file -test -z "$NM" && NM=nm -test -z "$SED" && SED=sed -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$RANLIB" && RANLIB=: -test -z "$STRIP" && STRIP=: -test -z "$ac_objext" && ac_objext=o + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_cc_attribute=yes +else + ntp_cv_cc_attribute=no -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" - ;; - *) - old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cc_attribute" >&5 +$as_echo "$ntp_cv_cc_attribute" >&6; } +case "$ntp_cv_cc_attribute" in + yes) -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` +$as_echo "#define HAVE___ATTRIBUTE__ /**/" >>confdefs.h +esac -# Only perform the check for file, if the check method requires it -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : + +case "$GCC" in + yes) + SAVED_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Wstrict-overflow" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Wstrict-overflow" >&5 +$as_echo_n "checking if $CC can handle -Wstrict-overflow... " >&6; } +if ${ntp_cv_gcc_Wstrict_overflow+:} false; then : $as_echo_n "(cached) " >&6 else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/${ac_tool_prefix}file; then - lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi +int +main () +{ -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_gcc_Wstrict_overflow=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + ntp_cv_gcc_Wstrict_overflow=no + fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Wstrict_overflow" >&5 +$as_echo "$ntp_cv_gcc_Wstrict_overflow" >&6; } + # + # $ntp_cv_gcc_Wstrict_overflow is tested later to add the + # flag to CFLAGS. + # + CFLAGS="$SAVED_CFLAGS -Winit-self" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Winit-self" >&5 +$as_echo_n "checking if $CC can handle -Winit-self... " >&6; } +if ${ntp_cv_gcc_Winit_self+:} false; then : $as_echo_n "(cached) " >&6 else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/file; then - lt_cv_path_MAGIC_CMD="$ac_dir/file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <&2 -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac -fi +int +main () +{ -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_gcc_Winit_self=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi + ntp_cv_gcc_Winit_self=no - else - MAGIC_CMD=: - fi fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi - ;; -esac - -enable_dlopen=no -enable_win32_dll=no -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : - enableval=$enable_libtool_lock; fi - -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - - -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then : - withval=$with_pic; pic_mode="$withval" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Winit_self" >&5 +$as_echo "$ntp_cv_gcc_Winit_self" >&6; } + CFLAGS="$SAVED_CFLAGS" + { SAVED_CFLAGS=; unset SAVED_CFLAGS;} + # + # $ntp_cv_gcc_Winit_self is tested later to add the + # flag to CFLAGS_NTP. + # + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports omitting unused code and data" >&5 +$as_echo_n "checking if linker supports omitting unused code and data... " >&6; } +if ${ntp_cv_gc_sections_runs+:} false; then : + $as_echo_n "(cached) " >&6 else - pic_mode=default -fi -test -z "$pic_mode" && pic_mode=default + origCFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Wl,--gc-sections" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Use C for the default configuration in the libtool script -tagname= -lt_save_CC="$CC" -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu + #include + #include +int +main () +{ -# Source file extension for C test sources. -ac_ext=c + FILE * fpC; + char buf[32]; + size_t cch; + int read_success_once; -# Object file extension for compiled C test sources. -objext=o -objext=$objext + fpC = fopen("conftest.c", "r"); + if (NULL == fpC) + exit(1); + do { + cch = fread(buf, sizeof(buf), 1, fpC); + read_success_once |= (0 != cch); + } while (0 != cch); + if (!read_success_once) + exit(2); + if (!feof(fpC)) + exit(3); + if (0 != fclose(fpC)) + exit(4); -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" + exit(EXIT_SUCCESS); -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}\n' + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} + if test "X$cross_compiling" = "Xyes" || grep gc-sections conftest.err ; then + ntp_cv_gc_sections_runs=no + else + ntp_cv_gc_sections_runs=no + ./conftest >/dev/null 2>&1 && ntp_cv_gc_sections_runs=yes + fi -# Allow CC to be a program name with arguments. -compiler=$CC +else + ntp_cv_gc_sections_runs=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS="$origCFLAGS" + { origCFLAGS=; unset origCFLAGS;} -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gc_sections_runs" >&5 +$as_echo "$ntp_cv_gc_sections_runs" >&6; } + case "$ntp_cv_gc_sections_runs" in + yes) + LDADD_LIBNTP="-Wl,--gc-sections" + CFLAGS_NTP="$CFLAGS_NTP -ffunction-sections -fdata-sections" + ;; + no) + LDADD_LIBNTP= + ;; + esac + CFLAGS_NTP="$CFLAGS_NTP -Wall" + CFLAGS_NTP="$CFLAGS_NTP -Wcast-align" + CFLAGS_NTP="$CFLAGS_NTP -Wcast-qual" + # CFLAGS_NTP="$CFLAGS_NTP -Wconversion" + # CFLAGS_NTP="$CFLAGS_NTP -Werror" + # CFLAGS_NTP="$CFLAGS_NTP -Wextra" + # CFLAGS_NTP="$CFLAGS_NTP -Wfloat-equal" + CFLAGS_NTP="$CFLAGS_NTP -Wmissing-prototypes" + CFLAGS_NTP="$CFLAGS_NTP -Wpointer-arith" + CFLAGS_NTP="$CFLAGS_NTP -Wshadow" + # CFLAGS_NTP="$CFLAGS_NTP -Wtraditional" + # CFLAGS_NTP="$CFLAGS_NTP -Wwrite-strings" + case "$ntp_cv_gcc_Winit_self" in + yes) + CFLAGS_NTP="$CFLAGS_NTP -Winit-self" + esac + case "$ntp_cv_gcc_Wstrict_overflow" in + yes) + CFLAGS_NTP="$CFLAGS_NTP -Wstrict-overflow" + esac + # -W[no-]strict-prototypes might be added by NTP_OPENSSL +esac -# -# Check for any special shared library compilation flags. -# -lt_prog_cc_shlib= -if test "$GCC" = no; then - case $host_os in - sco3.2v5*) - lt_prog_cc_shlib='-belf' - ;; - esac -fi -if test -n "$lt_prog_cc_shlib"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5 -$as_echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;} - if echo "$old_CC $old_CFLAGS " | grep "[ ]$lt_prog_cc_shlib[ ]" >/dev/null; then : - else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5 -$as_echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;} - lt_cv_prog_cc_can_build_shared=no - fi -fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5 +$as_echo_n "checking additional compiler flags... " >&6; } + # allow ntp_os_cflags to be preset to skip this stuff + case "${ntp_os_cflags+set}" in + set) + ;; + *) + ntp_os_cflags= + case "$host_os" in + aix[1-3]*) + ;; + aix4.[0-2]*) + # turn on additional headers + ntp_os_cflags="-D_XOPEN_EXTENDED_SOURCE" + ;; + aix5.3*) + # avoid circular dependencies in yp headers, and more + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS -D_MSGQSUPPORT" + ;; + aix*) + # XXX Only verified thru AIX6. + # aix7 seems to need a different XOPEN_SOURCE_EXTENDED thing. + # avoid circular dependencies in yp headers + # _XOPEN_SOURCE=500 = X/Open 5: POSIX 1995 + # _XOPEN_SOURCE=600 = X/Open 6: POSIX 2004 + # _XOPEN_SOURCE=700 = X/Open 7: POSIX 2008 + ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_SOURCE=600" + ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS" + ;; + amigaos) + ntp_os_cflags="-DSYS_AMIGA" + ;; + darwin*|macosx*|rhapsody*) + ntp_os_cflags="-D_P1003_1B_VISIBLE" + ;; + hpux10.*) # at least for hppa2.0-hp-hpux10.20 + case "$GCC" in + yes) + ;; + *) + # use Ansi compiler on HPUX, and some -Wp magic + ntp_os_cflags="-Ae -Wp,-H18816" + ;; + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L" + ;; + hpux*) + case "$GCC" in + yes) + ;; + *) + # use Ansi compiler on HPUX + ntp_os_cflags="-Ae" + esac + ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE -D__STDC_VERSION__=199901L" + ;; + irix6*) + case "$CC" in + cc) + # do not use 64-bit compiler + ntp_os_cflags="-n32 -mips3 -Wl,-woff,84" + esac + ;; + nextstep3) + ntp_os_cflags="-posix" + ;; + solaris1*|solaris2.[0-5]|solaris2.5.*) + ;; + sunos[34]*|sunos5.[0-5]|sunos5.5.*) + ;; + solaris2*|sunos5*) + # turn on 64-bit file offset interface + ntp_os_cflags="-D_LARGEFILE64_SOURCE" + ;; + vxworks*) + case "$build" in + $host) + ;; + *) + # Quick and dirty sanity check + case "$VX_KERNEL" in + '') + as_fn_error $? "See html/build/hints/vxworks.html" "$LINENO" 5 + esac + ntp_os_cflags="-DSYS_VXWORKS" + esac + ;; + esac + esac + case "$ntp_os_cflags" in + '') + ntp_os_cflags_msg="none needed" + ;; + *) + ntp_os_cflags_msg="$ntp_os_cflags" + esac + CFLAGS_NTP="$CFLAGS_NTP $ntp_os_cflags" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_cflags_msg" >&5 +$as_echo "$ntp_os_cflags_msg" >&6; } + { ntp_os_cflags_msg=; unset ntp_os_cflags_msg;} + ### + { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional linker flags" >&5 +$as_echo_n "checking additional linker flags... " >&6; } + # HMS: The following might still need tweaking + # allow ntp_os_ldflags to be preset to skip this stuff + case "${ntp_os_ldflags+set}" in + set) + ;; + *) + ntp_os_ldflags= + case "$host_os" in + hpux*) + case "$GCC" in + yes) + ntp_os_ldflags="-Wl,+allowdups" + ;; + esac + ;; + esac + ;; + esac + case "$ntp_os_ldflags" in + '') + ntp_os_ldflags_msg="none needed" + ;; + *) + ntp_os_ldflags_msg="$ntp_os_ldflags" + esac + LDFLAGS_NTP="$LDFLAGS_NTP $ntp_os_ldflags" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_ldflags_msg" >&5 +$as_echo "$ntp_os_ldflags_msg" >&6; } + { ntp_os_ldflags_msg=; unset ntp_os_ldflags_msg;} -# -# Check to make sure the static flag actually works. -# -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_prog_compiler_static works" >&5 -$as_echo_n "checking if $compiler static flag $lt_prog_compiler_static works... " >&6; } -if test "${lt_prog_compiler_static_works+set}" = set; then : + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 +$as_echo_n "checking whether byte ordering is bigendian... " >&6; } +if ${ac_cv_c_bigendian+:} false; then : $as_echo_n "(cached) " >&6 else - lt_prog_compiler_static_works=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_prog_compiler_static" - printf "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_static_works=yes - fi - else - lt_prog_compiler_static_works=yes - fi - fi - $rm conftest* - LDFLAGS="$save_LDFLAGS" + ac_cv_c_bigendian=unknown + # See if we're dealing with a universal compiler. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __APPLE_CC__ + not a universal capable compiler + #endif + typedef int dummy; -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_static_works" >&5 -$as_echo "$lt_prog_compiler_static_works" >&6; } +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : -if test x"$lt_prog_compiler_static_works" = xyes; then - : -else - lt_prog_compiler_static= + # Check for potential -arch flags. It is not universal unless + # there are at least two -arch flags with different values. + ac_arch= + ac_prev= + for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do + if test -n "$ac_prev"; then + case $ac_word in + i?86 | x86_64 | ppc | ppc64) + if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then + ac_arch=$ac_word + else + ac_cv_c_bigendian=universal + break + fi + ;; + esac + ac_prev= + elif test "x$ac_word" = "x-arch"; then + ac_prev=arch + fi + done fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if test $ac_cv_c_bigendian = unknown; then + # See if sys/param.h defines the BYTE_ORDER macro. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include +int +main () +{ +#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ + && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ + && LITTLE_ENDIAN) + bogus endian macros + #endif + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include +int +main () +{ +#if BYTE_ORDER != BIG_ENDIAN + not big endian + #endif -lt_prog_compiler_no_builtin_flag= - -if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag=' -fno-builtin' + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes +else + ac_cv_c_bigendian=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) + bogus endian macros + #endif -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:6177: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:6181: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $rm conftest* + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to _BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } +int +main () +{ +#ifndef _BIG_ENDIAN + not big endian + #endif -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes else - : + ac_cv_c_bigendian=no fi - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # Compile a test program. + if test "$cross_compiling" = yes; then : + # Try to guess by grepping values from an object file. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +short int ascii_mm[] = + { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; + short int ascii_ii[] = + { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; + int use_ascii (int i) { + return ascii_mm[i] + ascii_ii[i]; + } + short int ebcdic_ii[] = + { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; + short int ebcdic_mm[] = + { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; + int use_ebcdic (int i) { + return ebcdic_mm[i] + ebcdic_ii[i]; + } + extern int foo; -lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= +int +main () +{ +return use_ascii (foo) == use_ebcdic (foo); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then + ac_cv_c_bigendian=yes + fi + if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then + if test "$ac_cv_c_bigendian" = unknown; then + ac_cv_c_bigendian=no + else + # finding both strings is unlikely to happen, but who knows? + ac_cv_c_bigendian=unknown + fi + fi +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } + /* Are we little or big endian? From Harbison&Steele. */ + union + { + long int l; + char c[sizeof (long int)]; + } u; + u.l = 1; + return u.c[sizeof (long int) - 1] == 1; - if test "$GCC" = yes; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_bigendian=no +else + ac_cv_c_bigendian=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - ;; + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 +$as_echo "$ac_cv_c_bigendian" >&6; } + case $ac_cv_c_bigendian in #( + yes) + $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h +;; #( + no) + ;; #( + universal) - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; +$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; + ;; #( + *) + as_fn_error $? "unknown endianness + presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; + esac - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 +$as_echo_n "checking for working volatile... " >&6; } +if ${ac_cv_c_volatile+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - ;; +int +main () +{ - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no - ;; +volatile int x; +int * volatile y = (int *) 0; +return !x && !y; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_volatile=yes +else + ac_cv_c_volatile=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 +$as_echo "$ac_cv_c_volatile" >&6; } +if test $ac_cv_c_volatile = no; then - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic - fi - ;; +$as_echo "#define volatile /**/" >>confdefs.h - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - ;; +fi - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - lt_prog_compiler_pic='-qnocommon' - lt_prog_compiler_wl='-Wl,' - ;; - esac - ;; +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - ;; +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='${wl}-a ${wl}archive' - ;; + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' - ;; +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi - newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; + done + ac_cv_prog_CPP=$CPP - linux*) - case $cc_basename in - icc* | ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - esac - ;; +fi + CPP=$ac_cv_prog_CPP +else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' - ;; +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext - sco3.2v5*) - lt_prog_compiler_pic='-Kpic' - lt_prog_compiler_static='-dn' - ;; + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext - solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - lt_prog_compiler_wl='-Qoption ld ';; - *) - lt_prog_compiler_wl='-Wl,';; - esac - ;; +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : - sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' - fi - ;; - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no - ;; - uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' - ;; - *) - lt_prog_compiler_can_build_shared=no - ;; - esac - fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5 -$as_echo "$lt_prog_compiler_pic" >&6; } -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic"; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for install dir and man conventions" >&5 +$as_echo_n "checking for install dir and man conventions... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if test "${lt_prog_compiler_pic_works+set}" = set; then : - $as_echo_n "(cached) " >&6 + +# Check whether --with-locfile was given. +if test "${with_locfile+set}" = set; then : + withval=$with_locfile; else - lt_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:6439: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:6443: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_pic_works=yes - fi - fi - $rm conftest* + with_locfile=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works" >&5 -$as_echo "$lt_prog_compiler_pic_works" >&6; } -if test x"$lt_prog_compiler_pic_works" = xyes; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac + +( \ + SENTINEL_DIR="$PWD" && \ + cd $srcdir/ && \ + case "$with_locfile" in \ + yes|no|'') \ + scripts/genLocInfo -d "$SENTINEL_DIR" \ + ;; \ + *) \ + scripts/genLocInfo -d "$SENTINEL_DIR" -f "$with_locfile" \ + ;; \ + esac \ +) > genLocInfo.i 2> genLocInfo.err +. ./genLocInfo.i + +case "$GENLOCINFO" in + OK) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: in file $GENLOCINFOFILE" >&5 +$as_echo "in file $GENLOCINFOFILE" >&6; } + rm genLocInfo.err genLocInfo.i + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed." >&5 +$as_echo "failed." >&6; } + as_fn_error $? "Problem with genLocInfo!" "$LINENO" 5 + ;; +esac + + if test "$CALC_TICKADJ_MS" ; then + WANT_CALC_TICKADJ_MS_TRUE= + WANT_CALC_TICKADJ_MS_FALSE='#' else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no + WANT_CALC_TICKADJ_MS_TRUE='#' + WANT_CALC_TICKADJ_MS_FALSE= fi -fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:6501: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:6505: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - runpath_var= - allow_undefined_flag= - enable_shared_with_static_runtimes=no - archive_cmds= - archive_expsym_cmds= - old_archive_From_new_cmds= - old_archive_from_expsyms_cmds= - export_dynamic_flag_spec= - whole_archive_flag_spec= - thread_safe_flag_spec= - hardcode_libdir_flag_spec= - hardcode_libdir_flag_spec_ld= - hardcode_libdir_separator= - hardcode_direct=no - hardcode_minus_L=no - hardcode_shlibpath_var=unsupported - link_all_deplibs=unknown - hardcode_automatic=no - module_cmds= - module_expsym_cmds= - always_export_symbols=no - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac - ld_shlibs=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs=no - cat <&2 -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. -EOF - fi - ;; - amigaos*) - archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - ld_shlibs=no - ;; - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - ld_shlibs=no - fi - ;; - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test $supports_anon_versioning = yes; then - archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - ld_shlibs=no - fi - ;; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <&2 -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - if test "$ld_shlibs" = no; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - archive_cmds='' - hardcode_direct=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - hardcode_direct=yes - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int -main () -{ - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int -main () -{ - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi + + if test -z "$NTPSWEEP_NI" ; then + INSTALL_NTPSWEEP_TRUE= + INSTALL_NTPSWEEP_FALSE='#' +else + INSTALL_NTPSWEEP_TRUE='#' + INSTALL_NTPSWEEP_FALSE= fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' ${wl}-bernotok' - allow_undefined_flag=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - always_export_symbols=yes - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec=' ' - archive_cmds_need_lc=yes - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - amigaos*) - archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - # see comment about different semantics on the GNU ld section - ld_shlibs=no - ;; - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_From_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs' - fix_srcfile_path='`cygpath -w "$srcfile"`' - enable_shared_with_static_runtimes=yes - ;; - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[012]) - allow_undefined_flag='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[012]) - allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - whole_archive_flag_spec='' - link_all_deplibs=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - ld_shlibs=no - ;; - esac - fi - ;; - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - freebsd1*) - ld_shlibs=no - ;; - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - hpux9*) - if test "$GCC" = yes; then - archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='${wl}-E' - ;; - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*|ia64*) - archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_flag_spec_ld='+b $libdir' - hardcode_libdir_separator=: - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - ia64*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=no - hardcode_shlibpath_var=no - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - *) - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - export_dynamic_flag_spec='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_ld='-rpath $libdir' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - link_all_deplibs=yes - ;; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; - openbsd*) - hardcode_direct=yes - hardcode_shlibpath_var=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-R$libdir' - ;; - *) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - ;; - esac - fi - ;; - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - hardcode_libdir_separator=: - ;; - sco3.2v5*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; - solaris*) - no_undefined_flag=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;; - *) - whole_archive_flag_spec='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - link_all_deplibs=yes - ;; - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; - sysv4.2uw2*) - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=no - hardcode_shlibpath_var=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) - no_undefined_flag='${wl}-z ${wl}text' - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; - sysv5*) - no_undefined_flag=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - hardcode_libdir_flag_spec= - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - ;; - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - *) - ld_shlibs=no - ;; - esac + + + + + + + + if test -z "$UPDATE_LEAP_NI" ; then + INSTALL_UPDATE_LEAP_TRUE= + INSTALL_UPDATE_LEAP_FALSE='#' +else + INSTALL_UPDATE_LEAP_TRUE='#' + INSTALL_UPDATE_LEAP_FALSE= +fi + + + + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar lib "link -lib" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi +done + done +IFS=$as_save_IFS -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } -test "$ld_shlibs" = no && can_build_shared=no +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" + + test -n "$AR" && break + done fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar lib "link -lib" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 + test -n "$ac_ct_AR" && break +done + + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi + +: ${AR=ar} + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5 +$as_echo_n "checking the archiver ($AR) interface... " >&6; } +if ${am_cv_ar_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + am_cv_ar_interface=ar + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int some_variable = 0; +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 + (eval $am_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + am_cv_ar_interface=ar + else + am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 + (eval $am_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } - then - archive_cmds_need_lc=no + if test "$ac_status" -eq 0; then + am_cv_ar_interface=lib else - archive_cmds_need_lc=yes + am_cv_ar_interface=unknown fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 fi - $rm conftest* - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc" >&5 -$as_echo "$archive_cmds_need_lc" >&6; } - ;; - esac - fi + rm -f conftest.lib libconftest.a + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5 +$as_echo "$am_cv_ar_interface" >&6; } + +case $am_cv_ar_interface in +ar) + ;; +lib) + # Microsoft lib, so override with the ar-lib wrapper script. + # FIXME: It is wrong to rewrite AR. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__AR in this case, + # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something + # similar. + AR="$am_aux_dir/ar-lib $AR" + ;; +unknown) + as_fn_error $? "could not determine $AR interface" "$LINENO" 5 ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + + + + +# Expose a cross-compilation indicator to makefiles + if test $build != $host; then + NTP_CROSSCOMPILE_TRUE= + NTP_CROSSCOMPILE_FALSE='#' +else + NTP_CROSSCOMPILE_TRUE='#' + NTP_CROSSCOMPILE_FALSE= +fi + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 fi else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + ac_cv_path_SED=$SED fi -need_lib_prefix=unknown -hardcode_into_libs=no -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +$as_echo_n "checking for fgrep... " >&6; } +if ${ac_cv_path_FGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 + then ac_cv_path_FGREP="$GREP -F" + else + if test -z "$FGREP"; then + ac_path_FGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in fgrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_FGREP" || continue +# Check for GNU ac_path_FGREP and select it if it is found. + # Check for GNU $ac_path_FGREP +case `"$ac_path_FGREP" --version 2>&1` in +*GNU*) + ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'FGREP' >> "conftest.nl" + "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_FGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_FGREP="$ac_path_FGREP" + ac_path_FGREP_max=$ac_count fi - shlibpath_var=LIBPATH + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi - ;; +else + ac_cv_path_FGREP=$FGREP +fi -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +$as_echo "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; -bsdi[45]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; +test -z "$GREP" && GREP=grep -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; -freebsd1*) - dynamic_linker=no - ;; -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[123]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - esac - ;; -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; +ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +$as_echo_n "checking how to print strings... " >&6; } +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "" +} -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +case "$ECHO" in + printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +$as_echo "printf" >&6; } ;; + print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +$as_echo "print -r" >&6; } ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +$as_echo "cat" >&6; } ;; +esac -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || \ - test -n "$runpath_var" || \ - test "X$hardcode_automatic" = "Xyes" ; then - # We can hardcode non-existant directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi + + +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = xyes; then : + else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported + +cat >>confdefs.h <<_ACEOF +#define pid_t int +_ACEOF + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } -if test "$hardcode_action" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + fi -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + + # Check whether --enable-c99-snprintf was given. +if test "${enable_c99_snprintf+set}" = set; then : + enableval=$enable_c99_snprintf; force_c99_snprintf=$enableval else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + force_c99_snprintf=no + fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac + + case "$force_c99_snprintf" in + yes) + hw_force_rpl_snprintf=yes + hw_force_rpl_vsnprintf=yes + esac + + + + + + + for ac_header in $ac_header_list +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + fi -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= +done - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5 +$as_echo_n "checking for unsigned long long int... " >&6; } +if ${ac_cv_type_unsigned_long_long_int+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_cv_type_unsigned_long_long_int=yes + if test "x${ac_cv_prog_cc_c99-no}" = xno; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); + /* For now, do not test the preprocessor; as of 2007 there are too many + implementations with broken preprocessors. Perhaps this can + be revisited in 2012. In the meantime, code should not expect + #if to work with literals wider than 32 bits. */ + /* Test literals. */ + long long int ll = 9223372036854775807ll; + long long int nll = -9223372036854775807LL; + unsigned long long int ull = 18446744073709551615ULL; + /* Test constant expressions. */ + typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll) + ? 1 : -1)]; + typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1 + ? 1 : -1)]; + int i = 63; int main () { -return dlopen (); +/* Test availability of runtime routines for shift and division. */ + long long int llmax = 9223372036854775807ll; + unsigned long long int ullmax = 18446744073709551615ull; + return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i) + | (llmax / ll) | (llmax % ll) + | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i) + | (ullmax / ull) | (ullmax % ull)); ; return 0; } + _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes + else - ac_cv_lib_dl_dlopen=no + ac_cv_type_unsigned_long_long_int=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5 +$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; } + if test $ac_cv_type_unsigned_long_long_int = yes; then - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes +$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h -fi + fi - ;; - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" + ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf" +if test "x$ac_cv_func_vsnprintf" = xyes; then : + hw_cv_func_vsnprintf=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then : + hw_cv_func_vsnprintf=no +fi + + if test "$hw_cv_func_vsnprintf" = yes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether vsnprintf is C99 compliant" >&5 +$as_echo_n "checking whether vsnprintf is C99 compliant... " >&6; } +if ${hw_cv_func_vsnprintf_c99+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test "$cross_compiling" = yes; then : + hw_cv_func_vsnprintf_c99=no +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); +#if HAVE_STDARG_H + #include + #endif + #include + static int testprintf(char *buf, size_t size, const char *format, ...) + { + int result; + va_list ap; + va_start(ap, format); + result = vsnprintf(buf, size, format, ap); + va_end(ap); + return result; + } int main () { -return shl_load (); +char buf[43]; + if (testprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 || + testprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 || + buf[0] != 'T' || buf[3] != '\0') + return 1; ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes +if ac_fn_c_try_run "$LINENO"; then : + hw_cv_func_vsnprintf_c99=yes else - ac_cv_lib_dld_shl_load=no + hw_cv_func_vsnprintf_c99=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_vsnprintf_c99" >&5 +$as_echo "$hw_cv_func_vsnprintf_c99" >&6; } else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" + hw_cv_func_vsnprintf_c99=no +fi + +$as_echo "#define HAVE_VSNPRINTF 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement vsnprintf will be used" >&5 +$as_echo_n "checking if C99-snprintf replacement vsnprintf will be used... " >&6; } + if test "${hw_force_rpl_vsnprintf=no}" = yes -o "$hw_cv_func_vsnprintf_c99" = no; then : + hw_use_rpl_vsnprintf=yes else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : + hw_use_rpl_vsnprintf=no +fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_vsnprintf" >&5 +$as_echo "$hw_use_rpl_vsnprintf" >&6; } + if test "$hw_use_rpl_vsnprintf" = yes; then : + +$as_echo "#define HW_WANT_RPL_VSNPRINTF 1" >>confdefs.h + + if test ${hw_nodef_vsnprintf=no} = no; then : + +$as_echo "#define vsnprintf rpl_vsnprintf" >>confdefs.h + +fi + for ac_header in inttypes.h locale.h stddef.h stdint.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include +" +if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_LCONV_DECIMAL_POINT 1 +_ACEOF + + +fi +ac_fn_c_check_member "$LINENO" "struct lconv" "thousands_sep" "ac_cv_member_struct_lconv_thousands_sep" "#include +" +if test "x$ac_cv_member_struct_lconv_thousands_sep" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_LCONV_THOUSANDS_SEP 1 +_ACEOF + + +fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double" >&5 +$as_echo_n "checking for long double... " >&6; } +if ${ac_cv_type_long_double+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test "$GCC" = yes; then + ac_cv_type_long_double=yes + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +/* The Stardent Vistra knows sizeof (long double), but does + not support it. */ + long double foo = 0.0L; +int +main () +{ +static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8. */ + sizeof (double) <= sizeof (long double))]; +test_array [0] = 0; +return test_array [0]; -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_type_long_double=yes else - ac_cv_lib_dl_dlopen=no + ac_cv_type_long_double=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if test "${ac_cv_lib_svld_dlopen+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5 +$as_echo "$ac_cv_type_long_double" >&6; } + if test $ac_cv_type_long_double = yes; then + +$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h + + fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5 +$as_echo_n "checking for long long int... " >&6; } +if ${ac_cv_type_long_long_int+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_cv_type_long_long_int=yes + if test "x${ac_cv_prog_cc_c99-no}" = xno; then + ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int + if test $ac_cv_type_long_long_int = yes; then + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); +#include + #ifndef LLONG_MAX + # define HALF \ + (1LL << (sizeof (long long int) * CHAR_BIT - 2)) + # define LLONG_MAX (HALF - 1 + HALF) + #endif int main () { -return dlopen (); +long long int n = 1; + int i; + for (i = 0; ; i++) + { + long long int m = n << i; + if (m >> i != n) + return 1; + if (LLONG_MAX / 2 < m) + break; + } + return 0; ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes +if ac_fn_c_try_run "$LINENO"; then : + else - ac_cv_lib_svld_dlopen=no + ac_cv_type_long_long_int=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if test "${ac_cv_lib_dld_dld_link+set}" = set; then : + + fi + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5 +$as_echo "$ac_cv_type_long_long_int" >&6; } + if test $ac_cv_type_long_long_int = yes; then + +$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h + + fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5 +$as_echo_n "checking for unsigned long long int... " >&6; } +if ${ac_cv_type_unsigned_long_long_int+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_cv_type_unsigned_long_long_int=yes + if test "x${ac_cv_prog_cc_c99-no}" = xno; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dld_link (); + /* For now, do not test the preprocessor; as of 2007 there are too many + implementations with broken preprocessors. Perhaps this can + be revisited in 2012. In the meantime, code should not expect + #if to work with literals wider than 32 bits. */ + /* Test literals. */ + long long int ll = 9223372036854775807ll; + long long int nll = -9223372036854775807LL; + unsigned long long int ull = 18446744073709551615ULL; + /* Test constant expressions. */ + typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll) + ? 1 : -1)]; + typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1 + ? 1 : -1)]; + int i = 63; int main () { -return dld_link (); +/* Test availability of runtime routines for shift and division. */ + long long int llmax = 9223372036854775807ll; + unsigned long long int ullmax = 18446744073709551615ull; + return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i) + | (llmax / ll) | (llmax % ll) + | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i) + | (ullmax / ull) | (ullmax % ull)); ; return 0; } + _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes + else - ac_cv_lib_dld_dld_link=no + ac_cv_type_unsigned_long_long_int=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" + fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5 +$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; } + if test $ac_cv_type_unsigned_long_long_int = yes; then +$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h -fi + fi + ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : -fi +else +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF fi -fi + ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" "$ac_includes_default" +if test "x$ac_cv_type_intmax_t" = xyes; then : + +$as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h + +else + test $ac_cv_type_long_long_int = yes \ + && ac_type='long long int' \ + || ac_type='long int' + +cat >>confdefs.h <<_ACEOF +#define intmax_t $ac_type +_ACEOF fi - ;; - esac - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" "$ac_includes_default" +if test "x$ac_cv_type_uintmax_t" = xyes; then : - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" +$as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < -#endif +cat >>confdefs.h <<_ACEOF +#define uintmax_t $ac_type +_ACEOF -#include +fi -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif -#ifdef __cplusplus -extern "C" void exit (int); -#endif + ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = xyes; then : -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +$as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } +else + for ac_type in 'unsigned int' 'unsigned long int' \ + 'unsigned long long int'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))]; +test_array [0] = 0; +return test_array [0]; - exit (status); + ; + return 0; } -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +cat >>confdefs.h <<_ACEOF +#define uintptr_t $ac_type +_ACEOF + + ac_type= +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test -z "$ac_type" && break + done fi -rm -fr conftest* + + + ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" +if test "x$ac_cv_type_ptrdiff_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PTRDIFF_T 1 +_ACEOF fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self_static+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <>confdefs.h <<_ACEOF +#define HAVE_LOCALECONV 1 +_ACEOF -#if HAVE_DLFCN_H -#include -#endif +fi +done -#include -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif + if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 +$as_echo_n "checking for an ANSI C-conforming const... " >&6; } +if ${ac_cv_c_const+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif +int +main () +{ -#ifdef __cplusplus -extern "C" void exit (int); +#ifndef __cplusplus + /* Ultrix mips cc rejects this sort of thing. */ + typedef int charset[2]; + const charset cs = { 0, 0 }; + /* SunOS 4.1.1 cc rejects this. */ + char const *const *pcpcc; + char **ppc; + /* NEC SVR4.0.2 mips cc rejects this. */ + struct point {int x, y;}; + static struct point const zero = {0,0}; + /* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in + an arm of an if-expression whose if-part is not a constant + expression */ + const char *g = "string"; + pcpcc = &g + (g ? g-g : 0); + /* HPUX 7.0 cc rejects these. */ + ++pcpcc; + ppc = (char**) pcpcc; + pcpcc = (char const *const *) ppc; + { /* SCO 3.2v4 cc rejects this sort of thing. */ + char tx; + char *t = &tx; + char const *s = 0 ? (char *) 0 : (char const *) 0; + + *t++ = 0; + if (s) return 0; + } + { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; + } + { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; + } + { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; } bx; + struct s *b = &bx; b->j = 5; + } + { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; + if (!foo) return 0; + } + return !cs[0] && !zero.x; #endif -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_const=yes +else + ac_cv_c_const=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 +$as_echo "$ac_cv_c_const" >&6; } +if test $ac_cv_c_const = no; then - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } +$as_echo "#define const /**/" >>confdefs.h - exit (status); -} -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi fi -rm -fr conftest* + + + case " $LIBOBJS " in + *" snprintf.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" + ;; +esac + + _hw_cv_func_xprintf_replace_done=yes fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac +fi - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac + ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf" +if test "x$ac_cv_func_snprintf" = xyes; then : + hw_cv_func_snprintf=yes +else + hw_cv_func_snprintf=no fi + if test "$hw_cv_func_snprintf" = yes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf is C99 compliant" >&5 +$as_echo_n "checking whether snprintf is C99 compliant... " >&6; } +if ${hw_cv_func_snprintf_c99+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + hw_cv_func_snprintf_c99=no +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +char buf[43]; + if (snprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 || + snprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 || + buf[0] != 'T' || buf[3] != '\0') + return 1; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + hw_cv_func_snprintf_c99=yes +else + hw_cv_func_snprintf_c99=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Report which librarie types wil actually be built -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_snprintf_c99" >&5 +$as_echo "$hw_cv_func_snprintf_c99" >&6; } +else + hw_cv_func_snprintf_c99=no +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } -test "$can_build_shared" = "no" && enable_shared=no +$as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case $host_os in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement snprintf will be used" >&5 +$as_echo_n "checking if C99-snprintf replacement snprintf will be used... " >&6; } + if test "${hw_force_rpl_snprintf=no}" = yes -o "$hw_cv_func_snprintf_c99" = no; then : + hw_use_rpl_snprintf=yes +else + hw_use_rpl_snprintf=no +fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_snprintf" >&5 +$as_echo "$hw_use_rpl_snprintf" >&6; } + if test "$hw_use_rpl_snprintf" = yes; then : -aix4* | aix5*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } +$as_echo "#define HW_WANT_RPL_SNPRINTF 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } + if test ${hw_nodef_snprintf=no} = no; then : -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler \ - CC \ - LD \ - lt_prog_compiler_wl \ - lt_prog_compiler_pic \ - lt_prog_compiler_static \ - lt_prog_compiler_no_builtin_flag \ - export_dynamic_flag_spec \ - thread_safe_flag_spec \ - whole_archive_flag_spec \ - enable_shared_with_static_runtimes \ - old_archive_cmds \ - old_archive_from_new_cmds \ - predep_objects \ - postdep_objects \ - predeps \ - postdeps \ - compiler_lib_search_path \ - archive_cmds \ - archive_expsym_cmds \ - postinstall_cmds \ - postuninstall_cmds \ - old_archive_from_expsyms_cmds \ - allow_undefined_flag \ - no_undefined_flag \ - export_symbols_cmds \ - hardcode_libdir_flag_spec \ - hardcode_libdir_flag_spec_ld \ - hardcode_libdir_separator \ - hardcode_automatic \ - module_cmds \ - module_expsym_cmds \ - lt_cv_prog_compiler_c_o \ - exclude_expsyms \ - include_expsyms; do - - case $var in - old_archive_cmds | \ - old_archive_from_new_cmds | \ - archive_cmds | \ - archive_expsym_cmds | \ - module_cmds | \ - module_expsym_cmds | \ - old_archive_from_expsyms_cmds | \ - export_symbols_cmds | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done +$as_echo "#define snprintf rpl_snprintf" >>confdefs.h - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac +fi -cfgfile="${ofile}T" - trap "$rm \"$cfgfile\"; exit 1" 1 2 15 - $rm -f "$cfgfile" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ofile" >&5 -$as_echo "$as_me: creating $ofile" >&6;} + if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 +$as_echo_n "checking for an ANSI C-conforming const... " >&6; } +if ${ac_cv_c_const+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - cat <<__EOF__ >> "$cfgfile" -#! $SHELL +int +main () +{ -# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -# Free Software Foundation, Inc. -# -# This file is part of GNU Libtool: -# Originally by Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. +#ifndef __cplusplus + /* Ultrix mips cc rejects this sort of thing. */ + typedef int charset[2]; + const charset cs = { 0, 0 }; + /* SunOS 4.1.1 cc rejects this. */ + char const *const *pcpcc; + char **ppc; + /* NEC SVR4.0.2 mips cc rejects this. */ + struct point {int x, y;}; + static struct point const zero = {0,0}; + /* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in + an arm of an if-expression whose if-part is not a constant + expression */ + const char *g = "string"; + pcpcc = &g + (g ? g-g : 0); + /* HPUX 7.0 cc rejects these. */ + ++pcpcc; + ppc = (char**) pcpcc; + pcpcc = (char const *const *) ppc; + { /* SCO 3.2v4 cc rejects this sort of thing. */ + char tx; + char *t = &tx; + char const *s = 0 ? (char *) 0 : (char const *) 0; -# A sed program that does not truncate output. -SED=$lt_SED + *t++ = 0; + if (s) return 0; + } + { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; + } + { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; + } + { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; } bx; + struct s *b = &bx; b->j = 5; + } + { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; + if (!foo) return 0; + } + return !cs[0] && !zero.x; +#endif -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="$SED -e 1s/^X//" + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_const=yes +else + ac_cv_c_const=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 +$as_echo "$ac_cv_c_const" >&6; } +if test $ac_cv_c_const = no; then -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +$as_echo "#define const /**/" >>confdefs.h -# The names of the tagged configurations supported by this script. -available_tags= +fi -# ### BEGIN LIBTOOL CONFIG -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static + case " $LIBOBJS " in + *" snprintf.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" + ;; +esac -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc + _hw_cv_func_xprintf_replace_done=yes +fi -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes +fi -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os -# An echo program that does not interpret backslashes. -echo=$lt_echo -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS +# HMS: Save $LIBS and empty it. +# any LIBS we add here should go in to LDADD_LIBNTP -# A C compiler. -LTCC=$lt_LTCC +__LIBS=$LIBS +LIBS= -# A language-specific compiler. -CC=$lt_compiler -# Is the compiler the GNU C compiler? -with_gcc=$GCC -# An ERE matcher. -EGREP=$lt_EGREP +# [Bug 2332] because we need to know if we are using GNU ld... -# The linker used to build libraries. -LD=$lt_LD -# Whether we need hard or soft links. -LN_S=$lt_LN_S +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi -# A BSD-compatible nm program. -NM=$lt_NM +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" -# Used on cygwin: assembler. -AS="$AS" -# The name of the directory that contains temporary libtool files. -objdir=$objdir -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl -# Object file suffix (normally "o"). -objext="$ac_objext" -# Old archive suffix (normally "a"). -libext="$libext" -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' -# Executable file suffix (normally ""). -exeext="$exeext" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for directory path separator" >&5 +$as_echo_n "checking for directory path separator... " >&6; } +if ${ntp_cv_dir_sep+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic -pic_mode=$pic_mode + case "$ntp_cv_dir_sep" in + '') + case "$host_os" in + *djgpp | *mingw32* | *emx*) + ntp_cv_dir_sep="'\\'" + ;; + *) + ntp_cv_dir_sep="'/'" + ;; + esac + esac -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_dir_sep" >&5 +$as_echo "$ntp_cv_dir_sep" >&6; } -# Must we lock files when doing compilation? -need_locks=$lt_need_locks +cat >>confdefs.h <<_ACEOF +#define DIR_SEP $ntp_cv_dir_sep +_ACEOF -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix -# Do we need a version for libraries? -need_version=$need_version -# Whether dlopen is supported. -dlopen_support=$enable_dlopen + NTP_ORIG_LIBS="$LIBS" -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self +# Check whether --with-lineeditlibs was given. +if test "${with_lineeditlibs+set}" = set; then : + withval=$with_lineeditlibs; use_lineeditlibs="$withval" +else + use_lineeditlibs="edit,editline" -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static +fi -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static + { $as_echo "$as_me:${as_lineno-$LINENO}: checking line editing libraries" >&5 +$as_echo_n "checking line editing libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_lineeditlibs" >&5 +$as_echo "$use_lineeditlibs" >&6; } + case "$use_lineeditlibs" in + no) + ntp_lib_lineedit=no + ;; + *) + for lineedit_lib in `echo $use_lineeditlibs | sed -e 's/,/ /'`; do + for term_lib in "" termcap curses ncurses; do + case "$term_lib" in + '') + TRY_LIB="-l$lineedit_lib" + ;; + *) + TRY_LIB="-l$lineedit_lib -l$term_lib" + ;; + esac + LIBS="$NTP_ORIG_LIBS $TRY_LIB" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline() with $TRY_LIB" >&5 +$as_echo_n "checking for readline() with $TRY_LIB... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char readline (); +int +main () +{ +return readline (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_lib_lineedit="$TRY_LIB" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + case "$ntp_lib_lineedit" in + '') + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) + # Use readline() + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + esac + case "$term_lib" in + '') + # do not try el_gets without a terminal library + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for el_gets() with $TRY_LIB" >&5 +$as_echo_n "checking for el_gets() with $TRY_LIB... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char el_gets (); +int +main () +{ +return el_gets (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_lib_lineedit="$TRY_LIB" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + case "$ntp_lib_lineedit" in + '') + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) # Use el_gets() + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + break + ;; + esac # $ntp_lib_lineedit + esac # $term_lib + done + case "$ntp_lib_lineedit" in + '') + ;; + *) + break + ;; + esac + done + LIBS="$NTP_ORIG_LIBS" + ;; + esac # $use_lineeditlibs -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec + case "$ntp_lib_lineedit" in + '') + ntp_lib_lineedit="no" + ;; + no) + ;; + *) + EDITLINE_LIBS="$ntp_lib_lineedit" -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec + ;; + esac # $ntp_lib_lineedit -# Library versioning type. -version_type=$version_type + case "$ntp_lib_lineedit" in + no) + ;; + *) + for ac_header in readline.h readline/readline.h histedit.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -# Format of library name prefix. -libname_spec=$lt_libname_spec +fi -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec +done -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec + for ac_header in history.h readline/history.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds +fi -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds +done -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds + case "$ac_cv_header_histedit_h" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to el_init()" >&5 +$as_echo_n "checking number of arguments to el_init()... " >&6; } +if ${ntp_cv_el_init_args+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds + #include + #include -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib +int +main () +{ -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects + el_init("conftest", stdin, stdout, stderr); -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_el_init_args=4 +else + ntp_cv_el_init_args=3 -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_el_init_args" >&5 +$as_echo "$ntp_cv_el_init_args" >&6; } -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method +cat >>confdefs.h <<_ACEOF +#define EL_INIT_ARGS $ntp_cv_el_init_args +_ACEOF -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd + esac -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5 +$as_echo_n "checking whether readline supports history... " >&6; } -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag + ntp_lib_lineedit_history="no" + ORIG_LIBS="$LIBS" + LIBS="$ORIG_LIBS $ntp_lib_lineedit" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char add_history (); +int +main () +{ +return add_history (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_lib_lineedit_history="yes" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$ORIG_LIBS" -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_lib_lineedit_history" >&5 +$as_echo "$ntp_lib_lineedit_history" >&6; } -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + case "$ntp_lib_lineedit_history" in + yes) -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +$as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + esac + esac # $ntp_lib_lineedit + { NTP_ORIG_LIBS=; unset NTP_ORIG_LIBS;} + { ORIG_LIBS=; unset ORIG_LIBS;} + { TRY_LIB=; unset TRY_LIB;} + { use_lineeditlibs=; unset use_lineeditlibs;} -# This is the shared library runtime path variable. -runpath_var=$runpath_var -# This is the shared library path variable. -shlibpath_var=$shlibpath_var +LIBM= +case "$host" in + *-*-darwin*) + ;; + *) + _libs=$LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing cos" >&5 +$as_echo_n "checking for library containing cos... " >&6; } +if ${ac_cv_search_cos+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char cos (); +int +main () +{ +return cos (); + ; + return 0; +} +_ACEOF +for ac_lib in '' m; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_cos=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_cos+:} false; then : + break +fi +done +if ${ac_cv_search_cos+:} false; then : -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action +else + ac_cv_search_cos=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_cos" >&5 +$as_echo "$ac_cv_search_cos" >&6; } +ac_res=$ac_cv_search_cos +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + LIBM="-lm" +fi -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs + LIBS=$_libs + ;; +esac -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec +{ _libs=; unset _libs;} -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator +for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct +fi -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L +done -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic +fi +done -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if ${ac_cv_func_fork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs + /* By Ruediger Kuhlmann. */ + return fork () < 0; -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path" +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if ${ac_cv_func_vfork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds + /* Did the child fail? (This shouldn't happen.) */ + || status -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms + /* Did the vfork/compiler bug occur? */ + || parent != getpid() -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# ### END LIBTOOL CONFIG +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } -__EOF__ +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi +if test "x$ac_cv_func_vfork_works" = xyes; then - case $host_os in - aix3*) - cat <<\EOF >> "$cfgfile" +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES fi -EOF - ;; - esac +if test "x$ac_cv_func_fork_works" = xyes; then - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h - mv -f "$cfgfile" "$ofile" || \ - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" +fi +# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works +# for constant arguments. Useless! +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 +$as_echo_n "checking for working alloca.h... " >&6; } +if ${ac_cv_working_alloca_h+:} false; then : + $as_echo_n "(cached) " >&6 else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +char *p = (char *) alloca (2 * sizeof (int)); + if (p) return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_working_alloca_h=yes +else + ac_cv_working_alloca_h=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 +$as_echo "$ac_cv_working_alloca_h" >&6; } +if test $ac_cv_working_alloca_h = yes; then +$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -CC="$lt_save_CC" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 +$as_echo_n "checking for alloca... " >&6; } +if ${ac_cv_func_alloca_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __GNUC__ +# define alloca __builtin_alloca +#else +# ifdef _MSC_VER +# include +# define alloca _alloca +# else +# ifdef HAVE_ALLOCA_H +# include +# else +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ +void *alloca (size_t); +# endif +# endif +# endif +# endif +#endif -# Check whether --with-tags was given. -if test "${with_tags+set}" = set; then : - withval=$with_tags; tagnames="$withval" +int +main () +{ +char *p = (char *) alloca (1); + if (p) return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_func_alloca_works=yes +else + ac_cv_func_alloca_works=no fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 +$as_echo "$ac_cv_func_alloca_works" >&6; } +if test $ac_cv_func_alloca_works = yes; then -if test -f "$ltmain" && test -n "$tagnames"; then - if test ! -f "${ofile}"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not exist" >&5 -$as_echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;} - fi +$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h - if test -z "$LTCC"; then - eval "`$SHELL ${ofile} --config | grep '^LTCC='`" - if test -z "$LTCC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not look like a libtool script" >&5 -$as_echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} - else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 -$as_echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} - fi - fi +else + # The SVR3 libPW and SVR4 libucb both contain incompatible functions +# that cause trouble. Some versions do not even contain alloca or +# contain a buggy version. If you still want to use their alloca, +# use ar to extract alloca.o from them instead of compiling alloca.c. - # Extract list of available tagged configurations in $ofile. - # Note that this assumes the entire list is on one line. - available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` +ALLOCA=\${LIBOBJDIR}alloca.$ac_objext - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for tagname in $tagnames; do - IFS="$lt_save_ifs" - # Check whether tagname contains only valid characters - case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in - "") ;; - *) as_fn_error "invalid tag name: $tagname" "$LINENO" 5 - ;; - esac +$as_echo "#define C_ALLOCA 1" >>confdefs.h - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null - then - as_fn_error "tag name \"$tagname\" already exists" "$LINENO" 5 - fi - # Update the list of available tags. - if test -n "$tagname"; then - echo appending configuration tag \"$tagname\" to $ofile +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 +$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } +if ${ac_cv_os_cray+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#if defined CRAY && ! defined CRAY2 +webecray +#else +wenotbecray +#endif - case $tagname in - CXX) - if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - : - else - tagname="" - fi - ;; +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "webecray" >/dev/null 2>&1; then : + ac_cv_os_cray=yes +else + ac_cv_os_cray=no +fi +rm -f conftest* - F77) - if test -n "$F77" && test "X$F77" != "Xno"; then - : - else - tagname="" - fi - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 +$as_echo "$ac_cv_os_cray" >&6; } +if test $ac_cv_os_cray = yes; then + for ac_func in _getb67 GETB67 getb67; do + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - GCJ) - if test -n "$GCJ" && test "X$GCJ" != "Xno"; then +cat >>confdefs.h <<_ACEOF +#define CRAY_STACKSEG_END $ac_func +_ACEOF + break +fi -# Source file extension for Java test sources. -ac_ext=java + done +fi -# Object file extension for compiled Java test sources. -objext=o -objext_GCJ=$objext +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 +$as_echo_n "checking stack direction for C alloca... " >&6; } +if ${ac_cv_c_stack_direction+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_c_stack_direction=0 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +find_stack_direction (int *addr, int depth) +{ + int dir, dummy = 0; + if (! addr) + addr = &dummy; + *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; + dir = depth ? find_stack_direction (addr, depth - 1) : 0; + return dir + dummy; +} -# Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}\n" +int +main (int argc, char **argv) +{ + return find_stack_direction (0, argc + !argv + 20) < 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_stack_direction=1 +else + ac_cv_c_stack_direction=-1 +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 +$as_echo "$ac_cv_c_stack_direction" >&6; } +cat >>confdefs.h <<_ACEOF +#define STACK_DIRECTION $ac_cv_c_stack_direction +_ACEOF -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} +fi -# Allow CC to be a program name with arguments. -compiler=$CC +ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default" +if test "x$ac_cv_have_decl_strerror_r" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_STRERROR_R $ac_have_decl +_ACEOF -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* +for ac_func in strerror_r +do : + ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r" +if test "x$ac_cv_func_strerror_r" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STRERROR_R 1 +_ACEOF -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* +fi +done +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5 +$as_echo_n "checking whether strerror_r returns char *... " >&6; } +if ${ac_cv_func_strerror_r_char_p+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${GCJ-"gcj"} -compiler=$CC -compiler_GCJ=$CC -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + ac_cv_func_strerror_r_char_p=no + if test $ac_cv_have_decl_strerror_r = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + char buf[100]; + char x = *strerror_r (0, buf, sizeof buf); + char *p = strerror_r (0, buf, sizeof buf); + return !p || x; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_func_strerror_r_char_p=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + else + # strerror_r is not declared. Choose between + # systems that have relatively inaccessible declarations for the + # function. BeOS and DEC UNIX 4.0 fall in this category, but the + # former has a strerror_r that returns char*, while the latter + # has a strerror_r that returns `int'. + # This test should segfault on the DEC system. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default + extern char *strerror_r (); +int +main () +{ +char buf[100]; + char x = *strerror_r (0, buf, sizeof buf); + return ! isalpha (x); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_strerror_r_char_p=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + fi -# GCJ did not exist at the time GCC didn't implicitly link libc in. -archive_cmds_need_lc_GCJ=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5 +$as_echo "$ac_cv_func_strerror_r_char_p" >&6; } +if test $ac_cv_func_strerror_r_char_p = yes; then -old_archive_cmds_GCJ=$old_archive_cmds +$as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h +fi -lt_prog_compiler_no_builtin_flag_GCJ= -if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' +ac_busted_vpath_in_make=no +case "$build" in + *-*-irix6.1*) # 64 bit only + # busted vpath? + ;; + *-*-irix6*) # 6.2 (and later?) + ac_busted_vpath_in_make=yes + ;; + *-*-solaris2.5.1) + ac_busted_vpath_in_make=yes + ;; + *-*-unicosmp*) + ac_busted_vpath_in_make=yes + ;; +esac +case "$ac_busted_vpath_in_make$srcdir" in + yes.|no*) + ;; + *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in + '') + as_fn_error $? "building outside of the main directory requires GNU make" "$LINENO" 5 + esac + ;; +esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : +case "$host" in + *-*-aix4*) + # Bug 2516: + # Was *-*-aix[[4-9]]* + # XXX only verified thru AIX6. But... + # Ken Link says this is fine for AIX 5.3 and 7.1, and sees no reason + # that this support would be in 5.3, removed in 6, and added back. + # + # (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub + # (returning ENOSYS). I didn't check 4.2. If, in the future, + # IBM pulls its thumbs out long enough to implement clock_settime, + # this conditional will need to change. Maybe use AC_TRY_RUN + # instead to try to set the time to itself and check errno. + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 +$as_echo_n "checking for library containing clock_gettime... " >&6; } +if ${ac_cv_search_clock_gettime+:} false; then : $as_echo_n "(cached) " >&6 else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9250: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:9254: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $rm conftest* + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char clock_gettime (); +int +main () +{ +return clock_gettime (); + ; + return 0; +} +_ACEOF +for ac_lib in '' rt; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_clock_gettime=$ac_res fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_clock_gettime+:} false; then : + break +fi +done +if ${ac_cv_search_clock_gettime+:} false; then : -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions" else - : + ac_cv_search_clock_gettime=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 +$as_echo "$ac_cv_search_clock_gettime" >&6; } +ac_res=$ac_cv_search_clock_gettime +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_clock_gettime" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_clock_gettime $LDADD_LIBNTP" ;; + esac fi -lt_prog_compiler_wl_GCJ= -lt_prog_compiler_pic_GCJ= -lt_prog_compiler_static_GCJ= + for ac_func in clock_getres clock_gettime clock_settime +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +fi +done - if test "$GCC" = yes; then - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_static_GCJ='-static' + ;; +esac - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_GCJ='-Bstatic' - fi - ;; +for ac_func in getclock stime timegm strlcpy strlcat +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4' - ;; +fi +done - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' - ;; +# Bug 2713 +LDADD_LIBUTIL= - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic_GCJ='-fno-common' - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing snprintb" >&5 +$as_echo_n "checking for library containing snprintb... " >&6; } +if ${ac_cv_search_snprintb+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared_GCJ=no - enable_shared=no - ;; +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char snprintb (); +int +main () +{ +return snprintb (); + ; + return 0; +} +_ACEOF +for ac_lib in '' util; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_snprintb=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_snprintb+:} false; then : + break +fi +done +if ${ac_cv_search_snprintb+:} false; then : - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic_GCJ=-Kconform_pic - fi - ;; +else + ac_cv_search_snprintb=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_snprintb" >&5 +$as_echo "$ac_cv_search_snprintb" >&6; } +ac_res=$ac_cv_search_snprintb +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_snprintb" in + 'none required') ;; + no) ;; + *) LDADD_LIBUTIL="$ac_cv_search_snprintb $LDADD_LIBUTIL" ;; + esac - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_GCJ='-fPIC' - ;; - esac - ;; +$as_echo "#define USE_SNPRINTB 1" >>confdefs.h - *) - lt_prog_compiler_pic_GCJ='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl_GCJ='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_GCJ='-Bstatic' - else - lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - lt_prog_compiler_pic_GCJ='-qnocommon' - lt_prog_compiler_wl_GCJ='-Wl,' - ;; - esac - ;; +fi - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_GCJ='-DDLL_EXPORT' - ;; - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl_GCJ='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_GCJ='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive' - ;; +# +for ac_header in errno.h sys/socket.h sys/types.h time.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl_GCJ='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static_GCJ='-non_shared' - ;; +fi - newsos6) - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; +done - linux*) - case $cc_basename in - icc* | ecc*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-fpic' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl_GCJ='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static_GCJ='-non_shared' - ;; - esac - ;; +for ac_header in net/if.h +do : + ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" " + #ifdef HAVE_SYS_SOCKET_H + # include + #endif - osf3* | osf4* | osf5*) - lt_prog_compiler_wl_GCJ='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static_GCJ='-non_shared' - ;; +" +if test "x$ac_cv_header_net_if_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_NET_IF_H 1 +_ACEOF - sco3.2v5*) - lt_prog_compiler_pic_GCJ='-Kpic' - lt_prog_compiler_static_GCJ='-dn' - ;; +fi - solaris*) - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - lt_prog_compiler_wl_GCJ='-Qoption ld ';; - *) - lt_prog_compiler_wl_GCJ='-Wl,';; - esac - ;; +done - sunos4*) - lt_prog_compiler_wl_GCJ='-Qoption ld ' - lt_prog_compiler_pic_GCJ='-PIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; +case "$host" in + *-hp-hpux*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if net/if.h requires mpinfou predeclaration" >&5 +$as_echo_n "checking if net/if.h requires mpinfou predeclaration... " >&6; } +if ${ntp_cv_predecl_mpinfou+:} false; then : + $as_echo_n "(cached) " >&6 +else - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_pic_GCJ='-KPIC' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; + np_cv_predecl_mpinfou=no + case "$ac_cv_header_net_if_h" in + no) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic_GCJ='-Kconform_pic' - lt_prog_compiler_static_GCJ='-Bstatic' - fi - ;; + typedef union mpinfou { + struct pdk_mpinfo *pdkptr; + struct mpinfo *pikptr; + } mpinfou_t; + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #include - unicos*) - lt_prog_compiler_wl_GCJ='-Wl,' - lt_prog_compiler_can_build_shared_GCJ=no - ;; +int +main () +{ - uts4*) - lt_prog_compiler_pic_GCJ='-pic' - lt_prog_compiler_static_GCJ='-Bstatic' - ;; - *) - lt_prog_compiler_can_build_shared_GCJ=no - ;; - esac - fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_GCJ" >&5 -$as_echo "$lt_prog_compiler_pic_GCJ" >&6; } + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic_GCJ"; then + ntp_cv_predecl_mpinfou=yes + ac_cv_header_net_if_h=yes -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... " >&6; } -if test "${lt_prog_compiler_pic_works_GCJ+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_prog_compiler_pic_works_GCJ=no - ac_outfile=conftest.$ac_objext - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic_GCJ" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9512: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:9516: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - lt_prog_compiler_pic_works_GCJ=yes - fi - fi - $rm conftest* fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_works_GCJ" >&5 -$as_echo "$lt_prog_compiler_pic_works_GCJ" >&6; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + esac -if test x"$lt_prog_compiler_pic_works_GCJ" = xyes; then - case $lt_prog_compiler_pic_GCJ in - "" | " "*) ;; - *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;; - esac -else - lt_prog_compiler_pic_GCJ= - lt_prog_compiler_can_build_shared_GCJ=no -fi fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic_GCJ= - ;; - *) - lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ" - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_predecl_mpinfou" >&5 +$as_echo "$ntp_cv_predecl_mpinfou" >&6; } + case "$ntp_cv_predecl_mpinfou" in + yes) + cat >>confdefs.h <<_ACEOF +#ifndef MPINFOU_PREDECLARED +# define MPINFOU_PREDECLARED +typedef union mpinfou { + struct pdk_mpinfo *pdkptr; + struct mpinfo *pikptr; +} mpinfou_t; +#endif +_ACEOF + + esac esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o_GCJ=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext +case "$host" in + *-linux*) + for ac_header in linux/if_addr.h +do : + ac_fn_c_check_header_compile "$LINENO" "linux/if_addr.h" "ac_cv_header_linux_if_addr_h" " + #ifdef HAVE_SYS_SOCKET_H + # include + #endif - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9574: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:9578: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o_GCJ=yes - fi - fi - chmod u+w . 2>&5 - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* +" +if test "x$ac_cv_header_linux_if_addr_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LINUX_IF_ADDR_H 1 +_ACEOF fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 -$as_echo "$lt_cv_prog_compiler_c_o_GCJ" >&6; } - -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi +done -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } +esac - runpath_var= - allow_undefined_flag_GCJ= - enable_shared_with_static_runtimes_GCJ=no - archive_cmds_GCJ= - archive_expsym_cmds_GCJ= - old_archive_From_new_cmds_GCJ= - old_archive_from_expsyms_cmds_GCJ= - export_dynamic_flag_spec_GCJ= - whole_archive_flag_spec_GCJ= - thread_safe_flag_spec_GCJ= - hardcode_libdir_flag_spec_GCJ= - hardcode_libdir_flag_spec_ld_GCJ= - hardcode_libdir_separator_GCJ= - hardcode_direct_GCJ=no - hardcode_minus_L_GCJ=no - hardcode_shlibpath_var_GCJ=unsupported - link_all_deplibs_GCJ=unknown - hardcode_automatic_GCJ=no - module_cmds_GCJ= - module_expsym_cmds_GCJ= - always_export_symbols_GCJ=no - export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms_GCJ= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms_GCJ="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` +for ac_header in arpa/nameser.h sys/param.h sys/time.h sys/timers.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac +fi - ld_shlibs_GCJ=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' +done - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir' - export_dynamic_flag_spec_GCJ='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - whole_archive_flag_spec_GCJ= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac +# sys/sysctl.h depends on sys/param.h on OpenBSD - Bug 1576 +for ac_header in sys/sysctl.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" " + #if defined HAVE_SYS_PARAM_H + # include + #endif - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs_GCJ=no - cat <&2 +" +if test "x$ac_cv_header_sys_sysctl_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_SYSCTL_H 1 +_ACEOF -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. +fi -EOF - fi - ;; +done - amigaos*) - archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - - # Samuel A. Falvo II reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - ld_shlibs_GCJ=no - ;; +for ac_header in netinet/in_system.h netinet/in_systm.h netinet/in.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag_GCJ=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs_GCJ=no - fi - ;; +fi - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec_GCJ='-L$libdir' - allow_undefined_flag_GCJ=unsupported - always_export_symbols_GCJ=no - enable_shared_with_static_runtimes_GCJ=yes - export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - ld_shlibs_GCJ=no - fi - ;; +done - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - archive_cmds_GCJ='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test $supports_anon_versioning = yes; then - archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - ld_shlibs_GCJ=no - fi - ;; +for ac_header in resolv.h +do : + ac_fn_c_check_header_compile "$LINENO" "resolv.h" "ac_cv_header_resolv_h" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; +" +if test "x$ac_cv_header_resolv_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_RESOLV_H 1 +_ACEOF - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - ld_shlibs_GCJ=no - cat <&2 +fi -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. +done -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs_GCJ=no - fi - ;; - sunos4*) - archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; +for ac_header in net/if_var.h +do : + ac_fn_c_check_header_compile "$LINENO" "net/if_var.h" "ac_cv_header_net_if_var_h" " + #if HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_NET_IF_H + # include + #endif - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs_GCJ=no - fi - ;; - esac +" +if test "x$ac_cv_header_net_if_var_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_NET_IF_VAR_H 1 +_ACEOF - if test "$ld_shlibs_GCJ" = no; then - runpath_var= - hardcode_libdir_flag_spec_GCJ= - export_dynamic_flag_spec_GCJ= - whole_archive_flag_spec_GCJ= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag_GCJ=unsupported - always_export_symbols_GCJ=yes - archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L_GCJ=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct_GCJ=unsupported - fi - ;; +fi - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no +done - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi +for ac_header in netinet/ip.h netinet/in_var.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NET_IF_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + #ifdef HAVE_NET_IF_VAR_H + # include + #endif + #ifdef HAVE_NETINET_IN_SYSTM_H + # include + #endif - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi - archive_cmds_GCJ='' - hardcode_direct_GCJ=yes - hardcode_libdir_separator_GCJ=':' - link_all_deplibs_GCJ=yes +done - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - hardcode_direct_GCJ=yes - else - # We have old collect2 - hardcode_direct_GCJ=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L_GCJ=yes - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_libdir_separator_GCJ= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols_GCJ=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag_GCJ='-berok' - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +# HMS: Do we need to check for -lsocket before or after these tests? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5 +$as_echo_n "checking for library containing inet_pton... " >&6; } +if ${ac_cv_search_inet_pton+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_pton (); int main () { - +return inet_pton (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi +for ac_lib in '' nsl; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_pton=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - - hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag_GCJ="-z nodefs" - archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ + conftest$ac_exeext + if ${ac_cv_search_inet_pton+:} false; then : + break +fi +done +if ${ac_cv_search_inet_pton+:} false; then : +else + ac_cv_search_inet_pton=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5 +$as_echo "$ac_cv_search_inet_pton" >&6; } +ac_res=$ac_cv_search_inet_pton +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_inet_pton" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_inet_pton $LDADD_LIBNTP" ;; + esac + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5 +$as_echo_n "checking for library containing inet_ntop... " >&6; } +if ${ac_cv_search_inet_ntop+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_ntop (); int main () { - +return inet_ntop (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib -lnsl $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_ntop=$ac_res fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - - hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag_GCJ=' ${wl}-bernotok' - allow_undefined_flag_GCJ=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - always_export_symbols_GCJ=yes - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec_GCJ=' ' - archive_cmds_need_lc_GCJ=yes - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - amigaos*) - archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - # see comment about different semantics on the GNU ld section - ld_shlibs_GCJ=no - ;; + conftest$ac_exeext + if ${ac_cv_search_inet_ntop+:} false; then : + break +fi +done +if ${ac_cv_search_inet_ntop+:} false; then : - bsdi[45]*) - export_dynamic_flag_spec_GCJ=-rdynamic - ;; +else + ac_cv_search_inet_ntop=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5 +$as_echo "$ac_cv_search_inet_ntop" >&6; } +ac_res=$ac_cv_search_inet_ntop +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_inet_ntop" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_inet_ntop $LDADD_LIBNTP" ;; + esac - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec_GCJ=' ' - allow_undefined_flag_GCJ=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_From_new_cmds_GCJ='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds_GCJ='lib /OUT:$oldlib$oldobjs$old_deplibs' - fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`' - enable_shared_with_static_runtimes_GCJ=yes - ;; +fi - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[012]) - allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[012]) - allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - archive_cmds_need_lc_GCJ=no - hardcode_direct_GCJ=no - hardcode_automatic_GCJ=yes - hardcode_shlibpath_var_GCJ=unsupported - whole_archive_flag_spec_GCJ='' - link_all_deplibs_GCJ=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - archive_cmds_GCJ='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - ld_shlibs_GCJ=no - ;; - esac - fi - ;; - dgux*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_shlibpath_var_GCJ=no - ;; +# [Bug 1628] On Solaris, we need -lxnet -lsocket. Generalize this to +# avoid keying on the OS name: If we find socket functions in +# libsocket, next try for them in libxnet without libsocket, if found, +# list both. If we simply tested libxnet first, we would find the +# functions there and never add libsocket. See also [Bug 660] +# http://bugs.ntp.org/show_bug.cgi?id=660#c9 +saved_LIBS=$LIBS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5 +$as_echo_n "checking for library containing setsockopt... " >&6; } +if ${ac_cv_search_setsockopt+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - freebsd1*) - ld_shlibs_GCJ=no - ;; +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char setsockopt (); +int +main () +{ +return setsockopt (); + ; + return 0; +} +_ACEOF +for ac_lib in '' socket; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_setsockopt=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_setsockopt+:} false; then : + break +fi +done +if ${ac_cv_search_setsockopt+:} false; then : - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; +else + ac_cv_search_setsockopt=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5 +$as_echo "$ac_cv_search_setsockopt" >&6; } +ac_res=$ac_cv_search_setsockopt +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_setsockopt" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_setsockopt $LDADD_LIBNTP" ;; + esac - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; +fi - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; +case "$ac_cv_search_setsockopt" in + -lsocket) + LIBS="$saved_LIBS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getsockopt" >&5 +$as_echo_n "checking for library containing getsockopt... " >&6; } +if ${ac_cv_search_getsockopt+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - hpux9*) - if test "$GCC" = yes; then - archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=yes +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char getsockopt (); +int +main () +{ +return getsockopt (); + ; + return 0; +} +_ACEOF +for ac_lib in '' xnet; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_getsockopt=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_getsockopt+:} false; then : + break +fi +done +if ${ac_cv_search_getsockopt+:} false; then : - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - export_dynamic_flag_spec_GCJ='${wl}-E' - ;; +else + ac_cv_search_getsockopt=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getsockopt" >&5 +$as_echo "$ac_cv_search_getsockopt" >&6; } +ac_res=$ac_cv_search_getsockopt +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_getsockopt" in + 'none required') ;; + no) ;; + *) LDADD_LIBNTP="$ac_cv_search_getsockopt $LDADD_LIBNTP" ;; + esac - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*|ia64*) - archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*|ia64*) - archive_cmds_GCJ='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=no - hardcode_shlibpath_var_GCJ=no - ;; - ia64*) - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_direct_GCJ=no - hardcode_shlibpath_var_GCJ=no +fi - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - ;; - *) - hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_direct_GCJ=yes - export_dynamic_flag_spec_GCJ='${wl}-E' + # XXX Possible trouble here - reading the comments above and looking at the + # code below I wonder if we'll add -lxnet when we don't need it. + # Also, do we need to add -lxnet to LDADD_LIBNTP, or perhaps see if it's + # there when it is not needed? + case "$ac_cv_search_getsockopt" in + -lxnet) + LIBS="-lxnet -lsocket $saved_LIBS" + ;; + *) LIBS="-lsocket $saved_LIBS" + ;; + esac + ;; +esac +{ saved_LIBS=; unset saved_LIBS;} - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L_GCJ=yes - ;; - esac - fi - ;; +# Bug 2427 - look for recvmsg here. +for ac_func in recvmsg +do : + ac_fn_c_check_func "$LINENO" "recvmsg" "ac_cv_func_recvmsg" +if test "x$ac_cv_func_recvmsg" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_RECVMSG 1 +_ACEOF - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir' - fi - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - link_all_deplibs_GCJ=yes - ;; +fi +done - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; - newsos6) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - hardcode_shlibpath_var_GCJ=no - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +$as_echo_n "checking for inline... " >&6; } +if ${ac_cv_c_inline+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __cplusplus +typedef int foo_t; +static $ac_kw foo_t static_foo () {return 0; } +$ac_kw foo_t foo () {return 0; } +#endif - openbsd*) - hardcode_direct_GCJ=yes - hardcode_shlibpath_var_GCJ=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' - export_dynamic_flag_spec_GCJ='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - ;; - *) - archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' - ;; - esac - fi - ;; +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_inline=$ac_kw +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test "$ac_cv_c_inline" != no && break +done - os2*) - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_minus_L_GCJ=yes - allow_undefined_flag_GCJ=unsupported - archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +$as_echo "$ac_cv_c_inline" >&6; } - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - allow_undefined_flag_GCJ=' -expect_unresolved \*' - archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator_GCJ=: - ;; +case $ac_cv_c_inline in + inline | yes) ;; + *) + case $ac_cv_c_inline in + no) ac_val=;; + *) ac_val=$ac_cv_c_inline;; + esac + cat >>confdefs.h <<_ACEOF +#ifndef __cplusplus +#define inline $ac_val +#endif +_ACEOF + ;; +esac - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag_GCJ=' -expect_unresolved \*' - archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec_GCJ='-rpath $libdir' - fi - hardcode_libdir_separator_GCJ=: - ;; +case "$ac_cv_c_inline" in + '') + ;; + *) - sco3.2v5*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - export_dynamic_flag_spec_GCJ='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; +$as_echo "#define HAVE_INLINE 1" >>confdefs.h - solaris*) - no_undefined_flag_GCJ=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_shlibpath_var_GCJ=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' ;; - *) - whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - link_all_deplibs_GCJ=yes - ;; - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=yes - hardcode_shlibpath_var_GCJ=no - ;; +esac - sysv4) - case $host_vendor in - sni) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds_GCJ='$CC -r -o $output$reload_objs' - hardcode_direct_GCJ=no - ;; - motorola) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var_GCJ=no - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 +$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } +if ${ac_cv_header_time+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include - sysv4.3*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - export_dynamic_flag_spec_GCJ='-Bexport' - ;; +int +main () +{ +if ((struct tm *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_time=yes +else + ac_cv_header_time=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 +$as_echo "$ac_cv_header_time" >&6; } +if test $ac_cv_header_time = yes; then - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var_GCJ=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs_GCJ=yes - fi - ;; +$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h - sysv4.2uw2*) - archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct_GCJ=yes - hardcode_minus_L_GCJ=no - hardcode_shlibpath_var_GCJ=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; +fi - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) - no_undefined_flag_GCJ='${wl}-z ${wl}text' - if test "$GCC" = yes; then - archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds_GCJ='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var_GCJ=no - ;; +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 +$as_echo_n "checking size of time_t... " >&6; } +if ${ac_cv_sizeof_time_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "$ac_includes_default"; then : - sysv5*) - no_undefined_flag_GCJ=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - hardcode_libdir_flag_spec_GCJ= - hardcode_shlibpath_var_GCJ=no - runpath_var='LD_RUN_PATH' - ;; +else + if test "$ac_cv_type_time_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (time_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_time_t=0 + fi +fi - uts4*) - archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec_GCJ='-L$libdir' - hardcode_shlibpath_var_GCJ=no - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 +$as_echo "$ac_cv_sizeof_time_t" >&6; } - *) - ld_shlibs_GCJ=no - ;; - esac - fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_GCJ" >&5 -$as_echo "$ld_shlibs_GCJ" >&6; } -test "$ld_shlibs_GCJ" = no && can_build_shared=no -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi +cat >>confdefs.h <<_ACEOF +#define SIZEOF_TIME_T $ac_cv_sizeof_time_t +_ACEOF -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc_GCJ" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc_GCJ=yes - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $archive_cmds_GCJ in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 +$as_echo_n "checking whether char is unsigned... " >&6; } +if ${ac_cv_c_char_unsigned+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !(((char) -1) < 0)]; +test_array [0] = 0; +return test_array [0]; - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl_GCJ - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ - allow_undefined_flag_GCJ= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - archive_cmds_need_lc_GCJ=no - else - archive_cmds_need_lc_GCJ=yes - fi - allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc_GCJ" >&5 -$as_echo "$archive_cmds_need_lc_GCJ" >&6; } - ;; - esac - fi - ;; -esac + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_char_unsigned=no +else + ac_cv_c_char_unsigned=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 +$as_echo "$ac_cv_c_char_unsigned" >&6; } +if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then + $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi +fi + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of signed char" >&5 +$as_echo_n "checking size of signed char... " >&6; } +if ${ac_cv_sizeof_signed_char+:} false; then : + $as_echo_n "(cached) " >&6 else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (signed char))" "ac_cv_sizeof_signed_char" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_signed_char" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (signed char) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_signed_char=0 + fi fi -need_lib_prefix=unknown -hardcode_into_libs=no -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_signed_char" >&5 +$as_echo "$ac_cv_sizeof_signed_char" >&6; } -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char +_ACEOF -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; +ac_fn_c_check_type "$LINENO" "s_char" "ac_cv_type_s_char" "$ac_includes_default" +if test "x$ac_cv_type_s_char" = xyes; then : -bsdi[45]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_S_CHAR 1 +_ACEOF -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes +fi +ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default" +if test "x$ac_cv_type_long_long" = xyes; then : - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; +cat >>confdefs.h <<_ACEOF +#define HAVE_LONG_LONG 1 +_ACEOF - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + +fi + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 +$as_echo_n "checking size of short... " >&6; } +if ${ac_cv_sizeof_short+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_short" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (short) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_short=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 +$as_echo "$ac_cv_sizeof_short" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if ${ac_cv_sizeof_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (int) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_int=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if ${ac_cv_sizeof_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + + +case "$ac_cv_type_long_long" in + no) ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; + *) + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 +$as_echo_n "checking size of long long... " >&6; } +if ${ac_cv_sizeof_long_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; +else + if test "$ac_cv_type_long_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long_long=0 + fi +fi -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 +$as_echo "$ac_cv_sizeof_long_long" >&6; } -freebsd1*) - dynamic_linker=no - ;; -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[123]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long +_ACEOF + + ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes +esac + +case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in + *yes) + # We have a typedef for s_char. Might as well believe it... ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes + no0no) + # We have signed chars, can't say 'signed char', no s_char typedef. + +$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h + ;; - esac - ;; + no1no) + # We have signed chars, can say 'signed char', no s_char typedef. -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; +$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + yes0no) + # We have unsigned chars, can't say 'signed char', no s_char typedef. + as_fn_error $? "No way to specify a signed character!" "$LINENO" 5 ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; + yes1no) + # We have unsigned chars, can say 'signed char', no s_char typedef. + +$as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; +esac -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 +$as_echo_n "checking for uid_t in sys/types.h... " >&6; } +if ${ac_cv_type_uid_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "uid_t" >/dev/null 2>&1; then : + ac_cv_type_uid_t=yes +else + ac_cv_type_uid_t=no +fi +rm -f conftest* - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 +$as_echo "$ac_cv_type_uid_t" >&6; } +if test $ac_cv_type_uid_t = no; then - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; +$as_echo "#define uid_t int" >>confdefs.h -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; +$as_echo "#define gid_t int" >>confdefs.h -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +fi -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including debugging code" >&5 +$as_echo_n "checking if we're including debugging code... " >&6; } +# Check whether --enable-debugging was given. +if test "${enable_debugging+set}" = set; then : + enableval=$enable_debugging; ntp_ok=$enableval +else + ntp_ok=yes -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; +fi -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; +case "$ntp_ok" in + yes) -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +$as_echo "#define DEBUG 1" >>confdefs.h -*) - dynamic_linker=no - ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5 +$as_echo "$ntp_ok" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action_GCJ= -if test -n "$hardcode_libdir_flag_spec_GCJ" || \ - test -n "$runpath_var_GCJ" || \ - test "X$hardcode_automatic_GCJ" = "Xyes" ; then - # We can hardcode non-existant directories. - if test "$hardcode_direct_GCJ" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no && - test "$hardcode_minus_L_GCJ" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action_GCJ=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action_GCJ=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action_GCJ=unsupported + +# check if we can compile with pthreads +for ac_header in semaphore.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "semaphore.h" "ac_cv_header_semaphore_h" "$ac_includes_default" +if test "x$ac_cv_header_semaphore_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SEMAPHORE_H 1 +_ACEOF + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_GCJ" >&5 -$as_echo "$hardcode_action_GCJ" >&6; } -if test "$hardcode_action_GCJ" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless +done + +for ac_func in socketpair +do : + ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair" +if test "x$ac_cv_func_socketpair" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SOCKETPAIR 1 +_ACEOF + fi +done -striplib= -old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +# Check whether --enable-thread-support was given. +if test "${enable_thread_support+set}" = set; then : + enableval=$enable_thread_support; else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac + enable_thread_support=yes + fi -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown +have_pthreads=no +case "$enable_thread_support" in + no) ;; + *) + ol_found_pthreads=no + + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +# OpenLDAP --with-threads + +# Check whether --with-threads was given. +if test "${with_threads+set}" = set; then : + withval=$with_threads; + ol_arg=invalid + for ol_val in auto nt posix mach pth lwp yes no manual ; do + if test "$withval" = "$ol_val" ; then + ol_arg="$ol_val" + fi + done + if test "$ol_arg" = "invalid" ; then + as_fn_error $? "bad value $withval for --with-threads" "$LINENO" 5 + fi + ol_with_threads="$ol_arg" + else - lt_cv_dlopen=no - lt_cv_dlopen_libs= + ol_with_threads="auto" +fi +# end --with-threads - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes + +case "$ol_with_threads$host" in + auto*-*-solaris2.[0-6]) + ol_with_threads=no ;; +esac - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; +ol_aix_threads=no +case "$host" in +*-*-aix*) if test -z "$CC" ; then + case "$ol_with_threads" in + auto | yes | posix) ol_aix_threads=yes ;; + esac + fi +;; +esac - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : +if test $ol_aix_threads = yes ; then + if test -z "${CC}" ; then + for ac_prog in cc_r xlc_r cc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. else - ac_cv_lib_dl_dlopen=no +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes + test -n "$CC" && break +done + + + if test "$CC" = cc ; then + if test $ol_with_threads != auto ; then + as_fn_error $? "--with-threads requires cc_r (or other suitable compiler) on AIX" "$LINENO" 5 + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling threads, no cc_r on AIX" >&5 +$as_echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;} + fi + ol_with_threads=no + fi + fi + + case ${CC} in cc_r | xlc_r) + ol_with_threads=posix + ol_cv_pthread_create=yes + ;; + esac fi - ;; +ol_link_threads=no +# OpenLDAP --with-yielding_select + +# Check whether --with-yielding_select was given. +if test "${with_yielding_select+set}" = set; then : + withval=$with_yielding_select; + ol_arg=invalid + for ol_val in auto yes no manual ; do + if test "$withval" = "$ol_val" ; then + ol_arg="$ol_val" + fi + done + if test "$ol_arg" = "invalid" ; then + as_fn_error $? "bad value $withval for --with-yielding_select" "$LINENO" 5 + fi + ol_with_yielding_select="$ol_arg" - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then : + ol_with_yielding_select="auto" +fi +# end --with-yielding_select + + +case $ol_with_threads in auto | yes | nt) + + + ac_fn_c_check_func "$LINENO" "_beginthread" "ac_cv_func__beginthread" +if test "x$ac_cv_func__beginthread" = xyes; then : + +fi + + + if test $ac_cv_func__beginthread = yes ; then + +$as_echo "#define HAVE_NT_THREADS 1" >>confdefs.h + + ol_cv_nt_threads=yes + fi + + + if test "$ol_cv_nt_threads" = yes ; then + ol_link_threads=nt + ol_with_threads=found + ol_with_yielding_select=yes + + +$as_echo "#define HAVE_NT_SERVICE_MANAGER 1" >>confdefs.h + + +$as_echo "#define HAVE_NT_EVENT_LOG 1" >>confdefs.h + + fi + + if test $ol_with_threads = nt ; then + as_fn_error $? "could not locate NT Threads" "$LINENO" 5 + fi + ;; +esac + +case $ol_with_threads in auto | yes | posix) + + for ac_header in pthread.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default" +if test "x$ac_cv_header_pthread_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_H 1 +_ACEOF + +fi + +done + + + if test $ac_cv_header_pthread_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking POSIX thread version" >&5 +$as_echo_n "checking POSIX thread version... " >&6; } +if ${ol_cv_pthread_version+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); +# include + int main () { -return shl_load (); + + int i = PTHREAD_CREATE_JOINABLE; + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_shl_load=yes +if ac_fn_c_try_compile "$LINENO"; then : + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_detach" >/dev/null 2>&1; then : + ol_cv_pthread_version=10 else - ac_cv_lib_dld_shl_load=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS + ol_cv_pthread_version=8 fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" +rm -f conftest* + else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then : - $as_echo_n "(cached) " >&6 + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +# include +# ifdef PTHREAD_CREATE_UNDETACHED + draft7 +# endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "draft7" >/dev/null 2>&1; then : + ol_cv_pthread_version=7 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_attr_init" >/dev/null 2>&1; then : + ol_cv_pthread_version=6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +# include +#ifdef PTHREAD_MUTEX_INITIALIZER + draft5 #endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} + _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dl_dlopen=yes +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "draft5" >/dev/null 2>&1; then : + ol_cv_pthread_version=5 else - ac_cv_lib_dl_dlopen=no + ol_cv_pthread_version=4 fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f conftest* + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if test "${ac_cv_lib_svld_dlopen+set}" = set; then : +rm -f conftest* + +fi +rm -f conftest* + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_version" >&5 +$as_echo "$ol_cv_pthread_version" >&6; } + + + if test $ol_cv_pthread_version != 0 ; then + +cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREADS $ol_cv_pthread_version +_ACEOF + + else + as_fn_error $? "unknown pthread version" "$LINENO" 5 + fi + + # consider threads found + ol_with_threads=found + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5 +$as_echo_n "checking for LinuxThreads pthread.h... " >&6; } +if ${ol_cv_header_linux_threads+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then : + ol_cv_header_linux_threads=yes +else + ol_cv_header_linux_threads=no +fi +rm -f conftest* -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5 +$as_echo "$ol_cv_header_linux_threads" >&6; } + if test $ol_cv_header_linux_threads = yes; then + +$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h + + fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU Pth pthread.h" >&5 +$as_echo_n "checking for GNU Pth pthread.h... " >&6; } +if ${ol_cv_header_gnu_pth_pthread_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#ifdef _POSIX_THREAD_IS_GNU_PTH + __gnu_pth__; #endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} + _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_svld_dlopen=yes +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "__gnu_pth__" >/dev/null 2>&1; then : + ol_cv_header_gnu_pth_pthread_h=yes else - ac_cv_lib_svld_dlopen=no + ol_cv_header_gnu_pth_pthread_h=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +rm -f conftest* + + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if test "${ac_cv_lib_dld_dld_link+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_gnu_pth_pthread_h" >&5 +$as_echo "$ol_cv_header_gnu_pth_pthread_h" >&6; } + + + if test $ol_cv_header_gnu_pth_pthread_h = no ; then + for ac_header in sched.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sched.h" "ac_cv_header_sched_h" "$ac_includes_default" +if test "x$ac_cv_header_sched_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SCHED_H 1 +_ACEOF + +fi + +done + + fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in default libraries" >&5 +$as_echo_n "checking for pthread_create in default libraries... " >&6; } +if ${ol_cv_pthread_create+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include #endif -char dld_link (); +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + int main () { -return dld_link (); + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_dld_dld_link=yes + ol_cv_pthread_create=yes else - ac_cv_lib_dld_dld_link=no + ol_cv_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" -fi +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -fi +int main(argc, argv) + int argc; + char **argv; +{ -fi + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -fi + status = pthread_attr_init(&attr); + if( status ) return status; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -fi + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - ;; - esac + status = pthread_detach( &t ); + if( status ) return errno; +#endif - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + return 0; - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" +} - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_create=yes +else + ol_cv_pthread_create=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self+set}" = set; then : +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create" >&5 +$as_echo "$ol_cv_pthread_create" >&6; } + + if test $ol_cv_pthread_create != no ; then + ol_link_threads=posix + ol_link_pthreads="" + fi + + # Pthread try link: -kthread (ol_cv_pthread_kthread) +if test "$ol_link_threads" = no ; then + # try -kthread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -kthread" >&5 +$as_echo_n "checking for pthread link with -kthread... " >&6; } +if ${ol_cv_pthread_kthread+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < + # save the flags + ol_LIBS="$LIBS" + LIBS="-kthread $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 #endif -#include +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL +int +main () +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; #else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; #endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -#ifdef __cplusplus -extern "C" void exit (int); + status = pthread_detach( &t ); + if( status ) return errno; #endif -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } + return 0; - exit (status); + ; + return 0; } -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_kthread=yes +else + ol_cv_pthread_kthread=no fi -rm -fr conftest* +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self_static+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext < + +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 #endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -#include +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; #else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif + status = pthread_attr_setdetachstate(&attr, detach); #endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; #endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -#ifdef __cplusplus -extern "C" void exit (int); + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; #endif -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } + return 0; - exit (status); } -EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi -fi -rm -fr conftest* - +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_kthread=yes +else + ol_cv_pthread_kthread=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac + # restore the LIBS + LIBS="$ol_LIBS" - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_kthread" >&5 +$as_echo "$ol_cv_pthread_kthread" >&6; } + if test $ol_cv_pthread_kthread = yes ; then + ol_link_pthreads="-kthread" + ol_link_threads=posix + fi +fi -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler_GCJ \ - CC_GCJ \ - LD_GCJ \ - lt_prog_compiler_wl_GCJ \ - lt_prog_compiler_pic_GCJ \ - lt_prog_compiler_static_GCJ \ - lt_prog_compiler_no_builtin_flag_GCJ \ - export_dynamic_flag_spec_GCJ \ - thread_safe_flag_spec_GCJ \ - whole_archive_flag_spec_GCJ \ - enable_shared_with_static_runtimes_GCJ \ - old_archive_cmds_GCJ \ - old_archive_from_new_cmds_GCJ \ - predep_objects_GCJ \ - postdep_objects_GCJ \ - predeps_GCJ \ - postdeps_GCJ \ - compiler_lib_search_path_GCJ \ - archive_cmds_GCJ \ - archive_expsym_cmds_GCJ \ - postinstall_cmds_GCJ \ - postuninstall_cmds_GCJ \ - old_archive_from_expsyms_cmds_GCJ \ - allow_undefined_flag_GCJ \ - no_undefined_flag_GCJ \ - export_symbols_cmds_GCJ \ - hardcode_libdir_flag_spec_GCJ \ - hardcode_libdir_flag_spec_ld_GCJ \ - hardcode_libdir_separator_GCJ \ - hardcode_automatic_GCJ \ - module_cmds_GCJ \ - module_expsym_cmds_GCJ \ - lt_cv_prog_compiler_c_o_GCJ \ - exclude_expsyms_GCJ \ - include_expsyms_GCJ; do - - case $var in - old_archive_cmds_GCJ | \ - old_archive_from_new_cmds_GCJ | \ - archive_cmds_GCJ | \ - archive_expsym_cmds_GCJ | \ - module_cmds_GCJ | \ - module_expsym_cmds_GCJ | \ - old_archive_from_expsyms_cmds_GCJ | \ - export_symbols_cmds_GCJ | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done + # Pthread try link: -pthread (ol_cv_pthread_pthread) +if test "$ol_link_threads" = no ; then + # try -pthread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthread" >&5 +$as_echo_n "checking for pthread link with -pthread... " >&6; } +if ${ol_cv_pthread_pthread+:} false; then : + $as_echo_n "(cached) " >&6 +else - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac + # save the flags + ol_LIBS="$LIBS" + LIBS="-pthread $LIBS" -cfgfile="$ofile" + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - cat <<__EOF__ >> "$cfgfile" -# ### BEGIN LIBTOOL TAG CONFIG: $tagname +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL +int +main () +{ -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Whether or not to build static libraries. -build_old_libs=$enable_static +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_GCJ + status = pthread_attr_init(&attr); + if( status ) return status; -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# An echo program that does not interpret backslashes. -echo=$lt_echo + return 0; -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_pthread=yes +else + ol_cv_pthread_pthread=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# A C compiler. -LTCC=$lt_LTCC -# A language-specific compiler. -CC=$lt_compiler_GCJ +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Is the compiler the GNU C compiler? -with_gcc=$GCC_GCJ +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# An ERE matcher. -EGREP=$lt_EGREP -# The linker used to build libraries. -LD=$lt_LD_GCJ +int main(argc, argv) + int argc; + char **argv; +{ -# Whether we need hard or soft links. -LN_S=$lt_LN_S + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# A BSD-compatible nm program. -NM=$lt_NM +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# A symbol stripping program -STRIP=$lt_STRIP + status = pthread_attr_init(&attr); + if( status ) return status; -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Used on cygwin: assembler. -AS="$AS" +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# The name of the directory that contains temporary libtool files. -objdir=$objdir + return 0; -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds +} -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_GCJ +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_pthread=yes +else + ol_cv_pthread_pthread=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Object file suffix (normally "o"). -objext="$ac_objext" -# Old archive suffix (normally "a"). -libext="$libext" + # restore the LIBS + LIBS="$ol_LIBS" -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthread" >&5 +$as_echo "$ol_cv_pthread_pthread" >&6; } -# Executable file suffix (normally ""). -exeext="$exeext" + if test $ol_cv_pthread_pthread = yes ; then + ol_link_pthreads="-pthread" + ol_link_threads=posix + fi +fi -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_GCJ -pic_mode=$pic_mode + # Pthread try link: -pthreads (ol_cv_pthread_pthreads) +if test "$ol_link_threads" = no ; then + # try -pthreads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthreads" >&5 +$as_echo_n "checking for pthread link with -pthreads... " >&6; } +if ${ol_cv_pthread_pthreads+:} false; then : + $as_echo_n "(cached) " >&6 +else -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len + # save the flags + ol_LIBS="$LIBS" + LIBS="-pthreads $LIBS" -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Must we lock files when doing compilation? -need_locks=$lt_need_locks +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Do we need a version for libraries? -need_version=$need_version +int +main () +{ -# Whether dlopen is supported. -dlopen_support=$enable_dlopen + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static + status = pthread_attr_init(&attr); + if( status ) return status; -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_GCJ +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ + return 0; -# Library versioning type. -version_type=$version_type + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_pthreads=yes +else + ol_cv_pthread_pthreads=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Format of library name prefix. -libname_spec=$lt_libname_spec -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds_GCJ -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ +int main(argc, argv) + int argc; + char **argv; +{ -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds_GCJ -archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds_GCJ -module_expsym_cmds=$lt_module_expsym_cmds_GCJ + status = pthread_attr_init(&attr); + if( status ) return status; -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects_GCJ + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects_GCJ + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps_GCJ +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps_GCJ + return 0; -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ +} -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_pthreads=yes +else + ol_cv_pthread_pthreads=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_GCJ + # restore the LIBS + LIBS="$ol_LIBS" -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_GCJ +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthreads" >&5 +$as_echo "$ol_cv_pthread_pthreads" >&6; } -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds + if test $ol_cv_pthread_pthreads = yes ; then + ol_link_pthreads="-pthreads" + ol_link_threads=posix + fi +fi -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval + # Pthread try link: -mthreads (ol_cv_pthread_mthreads) +if test "$ol_link_threads" = no ; then + # try -mthreads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -mthreads" >&5 +$as_echo_n "checking for pthread link with -mthreads... " >&6; } +if ${ol_cv_pthread_mthreads+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + # save the flags + ol_LIBS="$LIBS" + LIBS="-mthreads $LIBS" -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# This is the shared library runtime path variable. -runpath_var=$runpath_var +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# This is the shared library path variable. -shlibpath_var=$shlibpath_var +int +main () +{ -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_GCJ +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs + status = pthread_attr_init(&attr); + if( status ) return status; -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct_GCJ +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L_GCJ + return 0; -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_mthreads=yes +else + ol_cv_pthread_mthreads=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic_GCJ -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_GCJ +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +int main(argc, argv) + int argc; + char **argv; +{ -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path_GCJ" + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols_GCJ +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_GCJ + status = pthread_attr_init(&attr); + if( status ) return status; -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_GCJ + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_GCJ + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# ### END LIBTOOL TAG CONFIG: $tagname +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -__EOF__ + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_mthreads=yes else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi + ol_cv_pthread_mthreads=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu + # restore the LIBS + LIBS="$ol_LIBS" -CC="$lt_save_CC" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_mthreads" >&5 +$as_echo "$ol_cv_pthread_mthreads" >&6; } - else - tagname="" + if test $ol_cv_pthread_mthreads = yes ; then + ol_link_pthreads="-mthreads" + ol_link_threads=posix fi - ;; +fi - RC) + # Pthread try link: -thread (ol_cv_pthread_thread) +if test "$ol_link_threads" = no ; then + # try -thread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -thread" >&5 +$as_echo_n "checking for pthread link with -thread... " >&6; } +if ${ol_cv_pthread_thread+:} false; then : + $as_echo_n "(cached) " >&6 +else + # save the flags + ol_LIBS="$LIBS" + LIBS="-thread $LIBS" -# Source file extension for RC test sources. -ac_ext=rc + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Object file extension for compiled RC test sources. -objext=o -objext_RC=$objext +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n' +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" +int +main () +{ -# ltmain only uses $CC for tagged configurations so make sure $CC is set. + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Allow CC to be a program name with arguments. -compiler=$CC + status = pthread_attr_init(&attr); + if( status ) return status; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* + status = pthread_detach( &t ); + if( status ) return errno; +#endif +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${RC-"windres"} -compiler=$CC -compiler_RC=$CC -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` - -lt_cv_prog_compiler_c_o_RC=yes - -# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - compiler_RC \ - CC_RC \ - LD_RC \ - lt_prog_compiler_wl_RC \ - lt_prog_compiler_pic_RC \ - lt_prog_compiler_static_RC \ - lt_prog_compiler_no_builtin_flag_RC \ - export_dynamic_flag_spec_RC \ - thread_safe_flag_spec_RC \ - whole_archive_flag_spec_RC \ - enable_shared_with_static_runtimes_RC \ - old_archive_cmds_RC \ - old_archive_from_new_cmds_RC \ - predep_objects_RC \ - postdep_objects_RC \ - predeps_RC \ - postdeps_RC \ - compiler_lib_search_path_RC \ - archive_cmds_RC \ - archive_expsym_cmds_RC \ - postinstall_cmds_RC \ - postuninstall_cmds_RC \ - old_archive_from_expsyms_cmds_RC \ - allow_undefined_flag_RC \ - no_undefined_flag_RC \ - export_symbols_cmds_RC \ - hardcode_libdir_flag_spec_RC \ - hardcode_libdir_flag_spec_ld_RC \ - hardcode_libdir_separator_RC \ - hardcode_automatic_RC \ - module_cmds_RC \ - module_expsym_cmds_RC \ - lt_cv_prog_compiler_c_o_RC \ - exclude_expsyms_RC \ - include_expsyms_RC; do - - case $var in - old_archive_cmds_RC | \ - old_archive_from_new_cmds_RC | \ - archive_cmds_RC | \ - archive_expsym_cmds_RC | \ - module_cmds_RC | \ - module_expsym_cmds_RC | \ - old_archive_from_expsyms_cmds_RC | \ - export_symbols_cmds_RC | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done + return 0; - case $lt_echo in - *'\$0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` - ;; - esac + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_thread=yes +else + ol_cv_pthread_thread=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -cfgfile="$ofile" - cat <<__EOF__ >> "$cfgfile" -# ### BEGIN LIBTOOL TAG CONFIG: $tagname +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared +int main(argc, argv) + int argc; + char **argv; +{ -# Whether or not to build static libraries. -build_old_libs=$enable_static + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_RC +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC + status = pthread_attr_init(&attr); + if( status ) return status; -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# An echo program that does not interpret backslashes. -echo=$lt_echo +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS + return 0; -# A C compiler. -LTCC=$lt_LTCC +} -# A language-specific compiler. -CC=$lt_compiler_RC +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_thread=yes +else + ol_cv_pthread_thread=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Is the compiler the GNU C compiler? -with_gcc=$GCC_RC -# An ERE matcher. -EGREP=$lt_EGREP + # restore the LIBS + LIBS="$ol_LIBS" -# The linker used to build libraries. -LD=$lt_LD_RC +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_thread" >&5 +$as_echo "$ol_cv_pthread_thread" >&6; } -# Whether we need hard or soft links. -LN_S=$lt_LN_S + if test $ol_cv_pthread_thread = yes ; then + ol_link_pthreads="-thread" + ol_link_threads=posix + fi +fi -# A BSD-compatible nm program. -NM=$lt_NM -# A symbol stripping program -STRIP=$lt_STRIP + # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r) +if test "$ol_link_threads" = no ; then + # try -lpthread -lmach -lexc -lc_r + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5 +$as_echo_n "checking for pthread link with -lpthread -lmach -lexc -lc_r... " >&6; } +if ${ol_cv_pthread_lpthread_lmach_lexc_lc_r+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread -lmach -lexc -lc_r $LIBS" -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Used on cygwin: assembler. -AS="$AS" +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# The name of the directory that contains temporary libtool files. -objdir=$objdir +int +main () +{ -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_RC +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Object file suffix (normally "o"). -objext="$ac_objext" + status = pthread_attr_init(&attr); + if( status ) return status; -# Old archive suffix (normally "a"). -libext="$libext" +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds' + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Executable file suffix (normally ""). -exeext="$exeext" + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_RC -pic_mode=$pic_mode +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len + return 0; -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes +else + ol_cv_pthread_lpthread_lmach_lexc_lc_r=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Must we lock files when doing compilation? -need_locks=$lt_need_locks -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Do we need a version for libraries? -need_version=$need_version +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Whether dlopen is supported. -dlopen_support=$enable_dlopen -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self +int main(argc, argv) + int argc; + char **argv; +{ -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_RC +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC + status = pthread_attr_init(&attr); + if( status ) return status; -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Library versioning type. -version_type=$version_type +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Format of library name prefix. -libname_spec=$lt_libname_spec + return 0; -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec +} -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes +else + ol_cv_pthread_lpthread_lmach_lexc_lc_r=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_old_archive_cmds_RC -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC + # restore the LIBS + LIBS="$ol_LIBS" -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5 +$as_echo "$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6; } -# Commands used to build and install a shared archive. -archive_cmds=$lt_archive_cmds_RC -archive_expsym_cmds=$lt_archive_expsym_cmds_RC -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds + if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then + ol_link_pthreads="-lpthread -lmach -lexc -lc_r" + ol_link_threads=posix + fi +fi -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_module_cmds_RC -module_expsym_cmds=$lt_module_expsym_cmds_RC + # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc) +if test "$ol_link_threads" = no ; then + # try -lpthread -lmach -lexc + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc" >&5 +$as_echo_n "checking for pthread link with -lpthread -lmach -lexc... " >&6; } +if ${ol_cv_pthread_lpthread_lmach_lexc+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread -lmach -lexc $LIBS" -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_predep_objects_RC + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_postdep_objects_RC +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_predeps_RC +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_postdeps_RC +int +main () +{ -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_RC + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd + status = pthread_attr_init(&attr); + if( status ) return status; -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_RC +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_RC + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + return 0; -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthread_lmach_lexc=yes +else + ol_cv_pthread_lpthread_lmach_lexc=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address -# This is the shared library runtime path variable. -runpath_var=$runpath_var +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# This is the shared library path variable. -shlibpath_var=$shlibpath_var +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_RC +int main(argc, argv) + int argc; + char **argv; +{ -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC + status = pthread_attr_init(&attr); + if( status ) return status; -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$hardcode_direct_RC + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$hardcode_minus_L_RC + status = pthread_detach( &t ); + if( status ) return errno; +#endif -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_RC +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$hardcode_automatic_RC + return 0; -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" +} -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_RC +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthread_lmach_lexc=yes +else + ol_cv_pthread_lpthread_lmach_lexc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec + # restore the LIBS + LIBS="$ol_LIBS" -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$fix_srcfile_path_RC" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5 +$as_echo "$ol_cv_pthread_lpthread_lmach_lexc" >&6; } -# Set to yes if exported symbols are required. -always_export_symbols=$always_export_symbols_RC + if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then + ol_link_pthreads="-lpthread -lmach -lexc" + ol_link_threads=posix + fi +fi -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_RC -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds + # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff) +if test "$ol_link_threads" = no ; then + # try -lpthread -Wl,-woff,85 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -Wl,-woff,85" >&5 +$as_echo_n "checking for pthread link with -lpthread -Wl,-woff,85... " >&6; } +if ${ol_cv_pthread_lib_lpthread_woff+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_RC + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread -Wl,-woff,85 $LIBS" -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_RC + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# ### END LIBTOOL TAG CONFIG: $tagname +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -__EOF__ +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} +int +main () +{ -else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu + status = pthread_attr_init(&attr); + if( status ) return status; -CC="$lt_save_CC" +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - ;; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - *) - as_fn_error "Unsupported tag name: $tagname" "$LINENO" 5 - ;; - esac + status = pthread_detach( &t ); + if( status ) return errno; +#endif - # Append the new tag name to the list of available tags. - if test -n "$tagname" ; then - available_tags="$available_tags $tagname" - fi - fi - done - IFS="$lt_save_ifs" - - # Now substitute the updated list of available tags. - if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then - mv "${ofile}T" "$ofile" - chmod +x "$ofile" - else - rm -f "${ofile}T" - as_fn_error "unable to update list of available tagged configurations." "$LINENO" 5 - fi -fi - - - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -# Prevent multiple expansion + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lib_lpthread_woff=yes +else + ol_cv_pthread_lib_lpthread_woff=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} +int main(argc, argv) + int argc; + char **argv; +{ + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + status = pthread_attr_init(&attr); + if( status ) return status; -# NTP has (so far) been relying on leading-edge autogen. -# Therefore, by default: -# - use the version we ship with -# - do not install it -# - build a static copy (AC_DISABLE_SHARED - done earlier) -case "${enable_local_libopts+set}" in - set) ;; - *) enable_local_libopts=yes ;; -esac -case "${enable_libopts_install+set}" in - set) ;; - *) enable_libopts_install=no ;; -esac +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - NEED_LIBOPTS_DIR='' + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - LIBOPTS_DIR=libopts + status = pthread_detach( &t ); + if( status ) return errno; +#endif - # Check whether --enable-local-libopts was given. -if test "${enable_local_libopts+set}" = set; then : - enableval=$enable_local_libopts; - if test x$enableval = xyes ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5 -$as_echo "$as_me: Using supplied libopts tearoff" >&6;} - LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' - NEED_LIBOPTS_DIR=true - fi -fi +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; - # Check whether --enable-libopts-install was given. -if test "${enable_libopts_install+set}" = set; then : - enableval=$enable_libopts_install; -fi +} - if test "X${enable_libopts_install}" != Xno; then - INSTALL_LIBOPTS_TRUE= - INSTALL_LIBOPTS_FALSE='#' +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lib_lpthread_woff=yes else - INSTALL_LIBOPTS_TRUE='#' - INSTALL_LIBOPTS_FALSE= + ol_cv_pthread_lib_lpthread_woff=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - if test -z "${NEED_LIBOPTS_DIR}" ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5 -$as_echo_n "checking whether autoopts-config can be found... " >&6; } + # restore the LIBS + LIBS="$ol_LIBS" -# Check whether --with-autoopts-config was given. -if test "${with_autoopts_config+set}" = set; then : - withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5 -$as_echo_n "checking whether autoopts-config is specified... " >&6; } -if test "${lo_cv_with_autoopts_config+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=no ; fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5 -$as_echo "$lo_cv_with_autoopts_config" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthread_woff" >&5 +$as_echo "$ol_cv_pthread_lib_lpthread_woff" >&6; } + if test $ol_cv_pthread_lib_lpthread_woff = yes ; then + ol_link_pthreads="-lpthread -Wl,-woff,85" + ol_link_threads=posix + fi fi - # end of AC_ARG_WITH - if test "${lo_cv_test_autoopts+set}" = set; then : + + # Pthread try link: -lpthread (ol_cv_pthread_lpthread) +if test "$ol_link_threads" = no ; then + # try -lpthread + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread" >&5 +$as_echo_n "checking for pthread link with -lpthread... " >&6; } +if ${ol_cv_pthread_lpthread+:} false; then : $as_echo_n "(cached) " >&6 else - if test -z "${lo_cv_with_autoopts_config}" \ - -o X"${lo_cv_with_autoopts_config}" = Xno - then - if autoopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=autoopts-config - elif libopts-config --help 2>/dev/null 1>&2 - then lo_cv_with_autoopts_config=libopts-config - else lo_cv_with_autoopts_config=false ; fi - fi - lo_cv_test_autoopts=` - ${lo_cv_with_autoopts_config} --libs` 2> /dev/null - if test $? -ne 0 -o -z "${lo_cv_test_autoopts}" - then lo_cv_test_autoopts=no ; fi - -fi - # end of CACHE_VAL - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5 -$as_echo "${lo_cv_test_autoopts}" >&6; } + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthread $LIBS" - if test "X${lo_cv_test_autoopts}" != Xno - then - LIBOPTS_LDADD="${lo_cv_test_autoopts}" - LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`" - else - LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' - LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' - NEED_LIBOPTS_DIR=true - fi - fi # end of if test -z "${NEED_LIBOPTS_DIR}" + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - if test -n "${NEED_LIBOPTS_DIR}"; then - NEED_LIBOPTS_TRUE= - NEED_LIBOPTS_FALSE='#' -else - NEED_LIBOPTS_TRUE='#' - NEED_LIBOPTS_FALSE= -fi +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} +int +main () +{ - LIBOPTS_DIR=libopts + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - ac_config_files="$ac_config_files libopts/Makefile" +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + status = pthread_attr_init(&attr); + if( status ) return status; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; - if test -n "${NEED_LIBOPTS_DIR}" ; then + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + status = pthread_detach( &t ); + if( status ) return errno; +#endif -if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif -int -main () -{ + return 0; ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthread=yes else - ac_cv_header_stdc=no + ol_cv_pthread_lpthread=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : -else - ac_cv_header_stdc=no -fi -rm -f conftest* +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -fi +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : +int main(argc, argv) + int argc; + char **argv; +{ -else - ac_cv_header_stdc=no -fi -rm -f conftest* + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -fi +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; #else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; #endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; } + _ACEOF if ac_fn_c_try_run "$LINENO"; then : - + ol_cv_pthread_lpthread=yes else - ac_cv_header_stdc=no + ol_cv_pthread_lpthread=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then -$as_echo "#define STDC_HEADERS 1" >>confdefs.h + # restore the LIBS + LIBS="$ol_LIBS" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread" >&5 +$as_echo "$ol_cv_pthread_lpthread" >&6; } - # ================= - # AC_HEADER_DIRENT - # ================= - ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : + if test $ol_cv_pthread_lpthread = yes ; then + ol_link_pthreads="-lpthread" + ol_link_threads=posix + fi +fi + + # Pthread try link: -lc_r (ol_cv_pthread_lc_r) +if test "$ol_link_threads" = no ; then + # try -lc_r + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lc_r" >&5 +$as_echo_n "checking for pthread link with -lc_r... " >&6; } +if ${ol_cv_pthread_lc_r+:} false; then : $as_echo_n "(cached) " >&6 else + + # save the flags + ol_LIBS="$LIBS" + LIBS="-lc_r $LIBS" + + if test "$cross_compiling" = yes; then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include <$ac_hdr> + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} int main () { -if ((DIR *) 0) -return 0; + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_ac_Header=yes" +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lc_r=yes else - eval "$as_ac_Header=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$as_ac_Header - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 -_ACEOF - -ac_header_dirent=$ac_hdr; break + ol_cv_pthread_lc_r=no fi - -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : - $as_echo_n "(cached) " >&6 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include #endif -char opendir (); -int -main () +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; { -return opendir (); - ; - return 0; + return (void *) (p == NULL); +} + + +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + } + _ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lc_r=yes +else + ol_cv_pthread_lc_r=no fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -done -if test "${ac_cv_search_opendir+set}" = set; then : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS + + # restore the LIBS + LIBS="$ol_LIBS" + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lc_r" >&5 +$as_echo "$ol_cv_pthread_lc_r" >&6; } + if test $ol_cv_pthread_lc_r = yes ; then + ol_link_pthreads="-lc_r" + ol_link_threads=posix + fi fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : + + # Pthread try link: -threads (ol_cv_pthread_threads) +if test "$ol_link_threads" = no ; then + # try -threads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -threads" >&5 +$as_echo_n "checking for pthread link with -threads... " >&6; } +if ${ol_cv_pthread_threads+:} false; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + # save the flags + ol_LIBS="$LIBS" + LIBS="-threads $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include #endif -char opendir (); +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + int main () { -return opendir (); + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + ; return 0; } _ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_threads=yes +else + ol_cv_pthread_threads=no fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then : - + conftest$ac_exeext conftest.$ac_ext else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -fi +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - # ================= - # AC_CHECK_HEADERS - # ================= - for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ - setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ - sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ - utime.h sysexits.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF -fi +int main(argc, argv) + int argc; + char **argv; +{ -done + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - # -------------------------------------------- - # Verify certain entries from AC_CHECK_HEADERS - # -------------------------------------------- - for f in sys_types sys_mman sys_param sys_stat sys_wait \ - string errno stdlib memory setjmp - do eval as_ac_var=\${ac_cv_header_${f}_h+set} - test "${as_ac_var}" = set || \ - as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 - done + status = pthread_attr_init(&attr); + if( status ) return status; - # ================================================ - # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise - # if varargs.h is present define HAVE_VARARGS_H. - # ================================================ - for ac_header in stdarg.h varargs.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -done + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 - fi + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + +} - # ================================================ - # Similarly for the string.h and strings.h headers - # ================================================ - for ac_header in string.h strings.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF - break +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_threads=yes +else + ol_cv_pthread_threads=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 - fi + # restore the LIBS + LIBS="$ol_LIBS" - # ===================== - # ...and limits headers - # ===================== - for ac_header in limits.h sys/limits.h values.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_threads" >&5 +$as_echo "$ol_cv_pthread_threads" >&6; } -done + if test $ol_cv_pthread_threads = yes ; then + ol_link_pthreads="-threads" + ol_link_threads=posix + fi +fi - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 - fi - # ======================== - # ...and int types headers - # ======================== - for ac_header in stdint.h inttypes.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - break -fi + # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r) +if test "$ol_link_threads" = no ; then + # try -lpthreads -lmach -lexc -lc_r + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5 +$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc -lc_r... " >&6; } +if ${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+:} false; then : + $as_echo_n "(cached) " >&6 +else -done + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads -lmach -lexc -lc_r $LIBS" - ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" -if test "x$ac_cv_type_int8_t" = x""yes; then : + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -cat >>confdefs.h <<_ACEOF -#define HAVE_INT8_T 1 -_ACEOF +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -fi -ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" -if test "x$ac_cv_type_uint8_t" = x""yes; then : +int +main () +{ -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT8_T 1 -_ACEOF + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -fi -ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" -if test "x$ac_cv_type_int16_t" = x""yes; then : + status = pthread_attr_init(&attr); + if( status ) return status; -cat >>confdefs.h <<_ACEOF -#define HAVE_INT16_T 1 -_ACEOF +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -fi -ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" -if test "x$ac_cv_type_uint16_t" = x""yes; then : + status = pthread_detach( &t ); + if( status ) return errno; +#endif -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT16_T 1 -_ACEOF +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes +else + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no fi -ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" -if test "x$ac_cv_type_int32_t" = x""yes; then : +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -cat >>confdefs.h <<_ACEOF -#define HAVE_INT32_T 1 -_ACEOF +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -fi -ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" -if test "x$ac_cv_type_uint32_t" = x""yes; then : +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT32_T 1 -_ACEOF +int main(argc, argv) + int argc; + char **argv; +{ -fi -ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" -if test "x$ac_cv_type_intptr_t" = x""yes; then : + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -cat >>confdefs.h <<_ACEOF -#define HAVE_INTPTR_T 1 -_ACEOF +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + status = pthread_attr_init(&attr); + if( status ) return status; -fi -ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" -if test "x$ac_cv_type_uint_t" = x""yes; then : +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT_T 1 -_ACEOF + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + status = pthread_detach( &t ); + if( status ) return errno; +#endif -fi +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : +} -cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 _ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes +else + ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi -else + # restore the LIBS + LIBS="$ol_LIBS" -$as_echo "#define uintptr_t unsigned long" >>confdefs.h +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5 +$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6; } + if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then + ol_link_pthreads="-lpthreads -lmach -lexc -lc_r" + ol_link_threads=posix + fi fi - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 -$as_echo_n "checking size of char*... " >&6; } -if test "${ac_cv_sizeof_charp+set}" = set; then : + # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc) +if test "$ol_link_threads" = no ; then + # try -lpthreads -lmach -lexc + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc" >&5 +$as_echo_n "checking for pthread link with -lpthreads -lmach -lexc... " >&6; } +if ${ol_cv_pthread_lpthreads_lmach_lexc+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : -else - if test "$ac_cv_type_charp" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (char*) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_charp=0 - fi -fi + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads -lmach -lexc $LIBS" -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 -$as_echo "$ac_cv_sizeof_charp" >&6; } + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -cat >>confdefs.h <<_ACEOF -#define SIZEOF_CHARP $ac_cv_sizeof_charp -_ACEOF +int +main () +{ + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc=yes else - if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (int) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_int=0 - fi + ol_cv_pthread_lpthreads_lmach_lexc=no fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int -_ACEOF +int main(argc, argv) + int argc; + char **argv; +{ - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -else - if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (long) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_long=0 - fi -fi +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } + status = pthread_attr_init(&attr); + if( status ) return status; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF + status = pthread_detach( &t ); + if( status ) return errno; +#endif +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 -$as_echo_n "checking size of short... " >&6; } -if test "${ac_cv_sizeof_short+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + return 0; + +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthreads_lmach_lexc=yes else - if test "$ac_cv_type_short" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (short) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_short=0 - fi + ol_cv_pthread_lpthreads_lmach_lexc=no fi - +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 -$as_echo "$ac_cv_sizeof_short" >&6; } + # restore the LIBS + LIBS="$ol_LIBS" -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SHORT $ac_cv_sizeof_short -_ACEOF - +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5 +$as_echo "$ol_cv_pthread_lpthreads_lmach_lexc" >&6; } + if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then + ol_link_pthreads="-lpthreads -lmach -lexc" + ol_link_threads=posix + fi +fi - # ---------------------------------------------------------------------- - # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. - # ---------------------------------------------------------------------- - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 -$as_echo_n "checking for pathfind in -lgen... " >&6; } -if test "${ac_cv_lib_gen_pathfind+set}" = set; then : + # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc) +if test "$ol_link_threads" = no ; then + # try -lpthreads -lexc + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lexc" >&5 +$as_echo_n "checking for pthread link with -lpthreads -lexc... " >&6; } +if ${ol_cv_pthread_lpthreads_lexc+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lgen $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext + + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads -lexc $LIBS" + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include #endif -char pathfind (); +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + int main () { -return pathfind (); - ; + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + + ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_gen_pathfind=yes + ol_cv_pthread_lpthreads_lexc=yes else - ac_cv_lib_gen_pathfind=no + ol_cv_pthread_lpthreads_lexc=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 -$as_echo "$ac_cv_lib_gen_pathfind" >&6; } -if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBGEN 1 -_ACEOF +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - LIBS="-lgen $LIBS" -fi +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif - for ac_func in vprintf -do : - ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" -if test "x$ac_cv_func_vprintf" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_VPRINTF 1 -_ACEOF +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" -if test "x$ac_cv_func__doprnt" = x""yes; then : -$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h +int main(argc, argv) + int argc; + char **argv; +{ -fi + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; -fi -done +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + +} - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_lpthreads_lexc=yes +else + ol_cv_pthread_lpthreads_lexc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + + # restore the LIBS + LIBS="$ol_LIBS" fi -done +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lexc" >&5 +$as_echo "$ol_cv_pthread_lpthreads_lexc" >&6; } - INVOKE_LIBOPTS_MACROS_FIRST_done=yes + if test $ol_cv_pthread_lpthreads_lexc = yes ; then + ol_link_pthreads="-lpthreads -lexc" + ol_link_threads=posix + fi fi - # Check to see if a reg expr header is specified. -# Check whether --with-regex-header was given. -if test "${with_regex_header+set}" = set; then : - withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5 -$as_echo_n "checking whether a reg expr header is specified... " >&6; } -if test "${libopts_cv_with_regex_header+set}" = set; then : + # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads) +if test "$ol_link_threads" = no ; then + # try -lpthreads + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads" >&5 +$as_echo_n "checking for pthread link with -lpthreads... " >&6; } +if ${ol_cv_pthread_lib_lpthreads+:} false; then : $as_echo_n "(cached) " >&6 else - libopts_cv_with_regex_header=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5 -$as_echo "$libopts_cv_with_regex_header" >&6; } -fi - # end of AC_ARG_WITH + # save the flags + ol_LIBS="$LIBS" + LIBS="-lpthreads $LIBS" - if test "X${libopts_cv_with_regex_header}" != Xno - then - cat >>confdefs.h <<_ACEOF -#define REGEX_HEADER <${libopts_cv_with_regex_header}> -_ACEOF + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - else +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -$as_echo "#define REGEX_HEADER " >>confdefs.h +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} - fi +int +main () +{ + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; - # Check to see if a working libregex can be found. + status = pthread_attr_init(&attr); + if( status ) return status; +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; -# Check whether --with-libregex was given. -if test "${with_libregex+set}" = set; then : - withval=$with_libregex; libopts_cv_with_libregex_root=${with_libregex} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex was specified" >&5 -$as_echo_n "checking whether with-libregex was specified... " >&6; } -if test "${libopts_cv_with_libregex_root+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_root=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_root" >&5 -$as_echo "$libopts_cv_with_libregex_root" >&6; } + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); -fi - # end of AC_ARG_WITH libregex + status = pthread_detach( &t ); + if( status ) return errno; +#endif - if test "${with_libguile+set}" = set && \ - test "${withval}" = no - then ## disabled by request - libopts_cv_with_libregex_root=no - libopts_cv_with_libregex_cflags=no - libopts_cv_with_libregex_libs=no - else +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + return 0; -# Check whether --with-libregex-cflags was given. -if test "${with_libregex_cflags+set}" = set; then : - withval=$with_libregex_cflags; libopts_cv_with_libregex_cflags=${with_regex_cflags} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-cflags was specified" >&5 -$as_echo_n "checking whether with-libregex-cflags was specified... " >&6; } -if test "${libopts_cv_with_libregex_cflags+set}" = set; then : - $as_echo_n "(cached) " >&6 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_pthread_lib_lpthreads=yes else - libopts_cv_with_libregex_cflags=no + ol_cv_pthread_lib_lpthreads=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_cflags" >&5 -$as_echo "$libopts_cv_with_libregex_cflags" >&6; } +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi - # end of AC_ARG_WITH libregex-cflags +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif -# Check whether --with-libregex-libs was given. -if test "${with_libregex_libs+set}" = set; then : - withval=$with_libregex_libs; libopts_cv_with_libregex_libs=${with_regex_libs} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-libs was specified" >&5 -$as_echo_n "checking whether with-libregex-libs was specified... " >&6; } -if test "${libopts_cv_with_libregex_libs+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - libopts_cv_with_libregex_libs=no -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_libs" >&5 -$as_echo "$libopts_cv_with_libregex_libs" >&6; } +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} -fi - # end of AC_ARG_WITH libregex-libs - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;; - * ) libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;; - esac - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - case "X${libopts_cv_with_libregex_root}" in - Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;; - * ) libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex";; - esac - esac - libopts_save_CPPFLAGS="${CPPFLAGS}" - libopts_save_LIBS="${LIBS}" - fi ## disabled by request +int main(argc, argv) + int argc; + char **argv; +{ - case "X${libopts_cv_with_libregex_cflags}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_cflags="" ;; - * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;; - esac - case "X${libopts_cv_with_libregex_libs}" in - Xyes|Xno|X ) - libopts_cv_with_libregex_libs="" ;; - * ) - LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;; - esac - LIBREGEX_CFLAGS="" - LIBREGEX_LIBS="" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libregex functions properly" >&5 -$as_echo_n "checking whether libregex functions properly... " >&6; } - if test "${libopts_cv_with_libregex+set}" = set; then : - $as_echo_n "(cached) " >&6 -else + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + +} - if test "$cross_compiling" = yes; then : - libopts_cv_with_libregex=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include REGEX_HEADER -static regex_t re; -void comp_re( char const* pzPat ) { - int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE ); - if (res == 0) return; - exit( res ); } -int main() { - regmatch_t m[2]; - comp_re( "^.*\$" ); - comp_re( "()|no.*" ); - comp_re( "." ); - if (regexec( &re, "X", 2, m, 0 ) != 0) return 1; - if ((m[0].rm_so != 0) || (m[0].rm_eo != 1)) { - fputs( "error: regex -->.<-- did not match\n", stderr ); - return 1; - } - return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_with_libregex=yes + ol_cv_pthread_lib_lpthreads=yes else - libopts_cv_with_libregex=no + ol_cv_pthread_lib_lpthreads=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi - # end of AC_TRY_RUN + + + # restore the LIBS + LIBS="$ol_LIBS" fi - # end of AC_CACHE_VAL for libopts_cv_with_libregex - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_with_libregex}" >&5 -$as_echo "${libopts_cv_with_libregex}" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthreads" >&5 +$as_echo "$ol_cv_pthread_lib_lpthreads" >&6; } - if test "X${libopts_cv_with_libregex}" != Xno - then + if test $ol_cv_pthread_lib_lpthreads = yes ; then + ol_link_pthreads="-lpthreads" + ol_link_threads=posix + fi +fi -$as_echo "#define WITH_LIBREGEX 1" >>confdefs.h - else - CPPFLAGS="${libopts_save_CPPFLAGS}" - LIBS="${libopts_save_LIBS}" - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&5 +$as_echo "$as_me: ol_link_threads: <$ol_link_threads> ol_link_pthreads <$ol_link_pthreads>" >&6;} + if test $ol_link_threads != no ; then + LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads" + save_CPPFLAGS="$CPPFLAGS" + save_LIBS="$LIBS" + LIBS="$LTHREAD_LIBS $LIBS" - # Check to see if pathfind(3) works. + for ac_func in sched_yield pthread_yield thr_yield +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pathfind(3) works" >&5 -$as_echo_n "checking whether pathfind(3) works... " >&6; } - if test "${libopts_cv_run_pathfind+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +fi +done - if test "$cross_compiling" = yes; then : - libopts_cv_run_pathfind=no + if test $ac_cv_func_sched_yield = no && + test $ac_cv_func_pthread_yield = no && + test $ac_cv_func_thr_yield = no ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5 +$as_echo_n "checking for sched_yield in -lrt... " >&6; } +if ${ac_cv_lib_rt_sched_yield+:} false; then : + $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_check_lib_save_LIBS=$LIBS +LIBS="-lrt $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -int main (int argc, char** argv) { - char* pz = pathfind( getenv( "PATH" ), "sh", "x" ); - return (pz == 0) ? 1 : 0; + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sched_yield (); +int +main () +{ +return sched_yield (); + ; + return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_pathfind=yes +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_rt_sched_yield=yes else - libopts_cv_run_pathfind=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + ac_cv_lib_rt_sched_yield=no fi - # end of TRY_RUN - +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi - # end of AC_CACHE_VAL for libopts_cv_run_pathfind - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_pathfind}" >&5 -$as_echo "${libopts_cv_run_pathfind}" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5 +$as_echo "$ac_cv_lib_rt_sched_yield" >&6; } +if test "x$ac_cv_lib_rt_sched_yield" = xyes; then : + LTHREAD_LIBS="$LTHREAD_LIBS -lrt" - if test "X${libopts_cv_run_pathfind}" != Xno - then +$as_echo "#define HAVE_SCHED_YIELD 1" >>confdefs.h -$as_echo "#define HAVE_PATHFIND 1" >>confdefs.h + ac_cv_func_sched_yield=yes +else + ac_cv_func_sched_yield=no +fi - fi + fi + if test $ac_cv_func_sched_yield = no && + test $ac_cv_func_pthread_yield = no && + test "$ac_cv_func_thr_yield" = no ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not locate sched_yield() or pthread_yield()" >&5 +$as_echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;} + fi + for ac_func in pthread_kill +do : + ac_fn_c_check_func "$LINENO" "pthread_kill" "ac_cv_func_pthread_kill" +if test "x$ac_cv_func_pthread_kill" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_KILL 1 +_ACEOF +fi +done - # Check to see if /dev/zero is readable device. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/zero is readable device" >&5 -$as_echo_n "checking whether /dev/zero is readable device... " >&6; } - if test "${libopts_cv_test_dev_zero+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_rwlock_destroy with " >&5 +$as_echo_n "checking for pthread_rwlock_destroy with ... " >&6; } +if ${ol_cv_func_pthread_rwlock_destroy+:} false; then : $as_echo_n "(cached) " >&6 else - libopts_cv_test_dev_zero=`exec 2> /dev/null -dzero=\`ls -lL /dev/zero | egrep ^c......r\` -test -z "${dzero}" && exit 1 -echo ${dzero}` - if test $? -ne 0 - then libopts_cv_test_dev_zero=no - elif test -z "$libopts_cv_test_dev_zero" - then libopts_cv_test_dev_zero=no - fi - -fi - # end of CACHE_VAL of libopts_cv_test_dev_zero - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_test_dev_zero}" >&5 -$as_echo "${libopts_cv_test_dev_zero}" >&6; } - - if test "X${libopts_cv_test_dev_zero}" != Xno - then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -$as_echo "#define HAVE_DEV_ZERO 1" >>confdefs.h +#include +pthread_rwlock_t rwlock; - fi +int +main () +{ +pthread_rwlock_destroy(&rwlock); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_func_pthread_rwlock_destroy=yes +else + ol_cv_func_pthread_rwlock_destroy=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_rwlock_destroy" >&5 +$as_echo "$ol_cv_func_pthread_rwlock_destroy" >&6; } + if test $ol_cv_func_pthread_rwlock_destroy = yes ; then +$as_echo "#define HAVE_PTHREAD_RWLOCK_DESTROY 1" >>confdefs.h - # Check to see if we have a functional realpath(3C). + fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have a functional realpath(3C)" >&5 -$as_echo_n "checking whether we have a functional realpath(3C)... " >&6; } - if test "${libopts_cv_run_realpath+set}" = set; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_detach with " >&5 +$as_echo_n "checking for pthread_detach with ... " >&6; } +if ${ol_cv_func_pthread_detach+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then : - libopts_cv_run_realpath=no - -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -int main (int argc, char** argv) { -#ifndef PATH_MAX -choke me!! -#else - char zPath[PATH_MAX+1]; + +#include +#ifndef NULL +#define NULL (void*)0 #endif - char *pz = realpath(argv[0], zPath); - return (pz == zPath) ? 0 : 1; + +int +main () +{ +pthread_detach(NULL); + ; + return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_realpath=yes +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_func_pthread_detach=yes else - libopts_cv_run_realpath=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + ol_cv_func_pthread_detach=no fi - # end of TRY_RUN +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi - # end of AC_CACHE_VAL for libopts_cv_run_realpath - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_realpath}" >&5 -$as_echo "${libopts_cv_run_realpath}" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_detach" >&5 +$as_echo "$ol_cv_func_pthread_detach" >&6; } - if test "X${libopts_cv_run_realpath}" != Xno - then + if test $ol_cv_func_pthread_detach = no ; then + as_fn_error $? "could not locate pthread_detach()" "$LINENO" 5 + fi -$as_echo "#define HAVE_REALPATH 1" >>confdefs.h - fi +$as_echo "#define HAVE_PTHREAD_DETACH 1" >>confdefs.h + for ac_func in \ + pthread_setconcurrency \ + pthread_getconcurrency \ + thr_setconcurrency \ + thr_getconcurrency \ - # Check to see if strftime() works. +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strftime() works" >&5 -$as_echo_n "checking whether strftime() works... " >&6; } - if test "${libopts_cv_run_strftime+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +fi +done - if test "$cross_compiling" = yes; then : - libopts_cv_run_strftime=no -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -char t_buf[ 64 ]; -int main() { - static char const z[] = "Thursday Aug 28 240"; - struct tm tm; - tm.tm_sec = 36; /* seconds after the minute [0, 61] */ - tm.tm_min = 44; /* minutes after the hour [0, 59] */ - tm.tm_hour = 12; /* hour since midnight [0, 23] */ - tm.tm_mday = 28; /* day of the month [1, 31] */ - tm.tm_mon = 7; /* months since January [0, 11] */ - tm.tm_year = 86; /* years since 1900 */ - tm.tm_wday = 4; /* days since Sunday [0, 6] */ - tm.tm_yday = 239; /* days since January 1 [0, 365] */ - tm.tm_isdst = 1; /* flag for daylight savings time */ - strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm ); - return (strcmp( t_buf, z ) != 0); } + + for ac_func in pthread_kill_other_threads_np +do : + ac_fn_c_check_func "$LINENO" "pthread_kill_other_threads_np" "ac_cv_func_pthread_kill_other_threads_np" +if test "x$ac_cv_func_pthread_kill_other_threads_np" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_KILL_OTHER_THREADS_NP 1 _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_strftime=yes -else - libopts_cv_run_strftime=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + fi - # end of TRY_RUN +done + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads implementation" >&5 +$as_echo_n "checking for LinuxThreads implementation... " >&6; } +if ${ol_cv_sys_linux_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else + ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np fi - # end of AC_CACHE_VAL for libopts_cv_run_strftime - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_strftime}" >&5 -$as_echo "${libopts_cv_run_strftime}" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_sys_linux_threads" >&5 +$as_echo "$ol_cv_sys_linux_threads" >&6; } - if test "X${libopts_cv_run_strftime}" != Xno - then -$as_echo "#define HAVE_STRFTIME 1" >>confdefs.h - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads consistency" >&5 +$as_echo_n "checking for LinuxThreads consistency... " >&6; } +if ${ol_cv_linux_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test $ol_cv_header_linux_threads = yes && + test $ol_cv_sys_linux_threads = yes; then + ol_cv_linux_threads=yes + elif test $ol_cv_header_linux_threads = no && + test $ol_cv_sys_linux_threads = no; then + ol_cv_linux_threads=no + else + ol_cv_linux_threads=error + fi - # Check to see if fopen accepts "b" mode. +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_linux_threads" >&5 +$as_echo "$ol_cv_linux_threads" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"b\" mode" >&5 -$as_echo_n "checking whether fopen accepts \"b\" mode... " >&6; } - if test "${libopts_cv_run_fopen_binary+set}" = set; then : + + if test $ol_cv_linux_threads = error; then + as_fn_error $? "LinuxThreads header/library mismatch" "$LINENO" 5; + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pthread_create() works" >&5 +$as_echo_n "checking if pthread_create() works... " >&6; } +if ${ol_cv_pthread_create_works+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then : - libopts_cv_run_fopen_binary=no - + if test "$cross_compiling" = yes; then : + ol_cv_pthread_create_works=yes else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.$ac_ext", "rb"); -return (fp == NULL) ? 1 : fclose(fp); } + + +/* pthread test headers */ +#include +#if HAVE_PTHREADS < 7 +#include +#endif +#ifndef NULL +#define NULL (void*)0 +#endif + +static void *task(p) + void *p; +{ + return (void *) (p == NULL); +} + + +int main(argc, argv) + int argc; + char **argv; +{ + + /* pthread test function */ +#ifndef PTHREAD_CREATE_DETACHED +#define PTHREAD_CREATE_DETACHED 1 +#endif + pthread_t t; + int status; + int detach = PTHREAD_CREATE_DETACHED; + +#if HAVE_PTHREADS > 4 + /* Final pthreads */ + pthread_attr_t attr; + + status = pthread_attr_init(&attr); + if( status ) return status; + +#if HAVE_PTHREADS < 7 + status = pthread_attr_setdetachstate(&attr, &detach); + if( status < 0 ) status = errno; +#else + status = pthread_attr_setdetachstate(&attr, detach); +#endif + if( status ) return status; + status = pthread_create( &t, &attr, task, NULL ); +#if HAVE_PTHREADS < 7 + if( status < 0 ) status = errno; +#endif + if( status ) return status; +#else + /* Draft 4 pthreads */ + status = pthread_create( &t, pthread_attr_default, task, NULL ); + if( status ) return errno; + + /* give thread a chance to complete */ + /* it should remain joinable and hence detachable */ + sleep( 1 ); + + status = pthread_detach( &t ); + if( status ) return errno; +#endif + +#ifdef HAVE_LINUX_THREADS + pthread_kill_other_threads_np(); +#endif + + return 0; + +} + _ACEOF if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_fopen_binary=yes + ol_cv_pthread_create_works=yes else - libopts_cv_run_fopen_binary=no + ol_cv_pthread_create_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi - # end of TRY_RUN fi - # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_binary}" >&5 -$as_echo "${libopts_cv_run_fopen_binary}" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create_works" >&5 +$as_echo "$ol_cv_pthread_create_works" >&6; } - if test "X${libopts_cv_run_fopen_binary}" != Xno - then + if test $ol_cv_pthread_create_works = no ; then + as_fn_error $? "pthread_create is not usable, check environment settings" "$LINENO" 5 + fi -$as_echo "#define FOPEN_BINARY_FLAG \"b\"" >>confdefs.h + ol_replace_broken_yield=no - else + if test $ol_replace_broken_yield = yes ; then -$as_echo "#define FOPEN_BINARY_FLAG \"\"" >>confdefs.h +$as_echo "#define REPLACE_BROKEN_YIELD 1" >>confdefs.h - fi + fi + if test x$ol_with_yielding_select = xauto ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if select yields when using pthreads" >&5 +$as_echo_n "checking if select yields when using pthreads... " >&6; } +if ${ol_cv_pthread_select_yields+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ol_cv_pthread_select_yields=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - # Check to see if fopen accepts "t" mode. +#include +#include +#include +#include +#ifndef NULL +#define NULL (void*) 0 +#endif - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"t\" mode" >&5 -$as_echo_n "checking whether fopen accepts \"t\" mode... " >&6; } - if test "${libopts_cv_run_fopen_text+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +static int fildes[2]; - if test "$cross_compiling" = yes; then : - libopts_cv_run_fopen_text=no +static void *task(p) + void *p; +{ + int i; + struct timeval tv; -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int main (int argc, char** argv) { -FILE* fp = fopen("conftest.$ac_ext", "rt"); -return (fp == NULL) ? 1 : fclose(fp); } -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - libopts_cv_run_fopen_text=yes -else - libopts_cv_run_fopen_text=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - # end of TRY_RUN + fd_set rfds; -fi - # end of AC_CACHE_VAL for libopts_cv_run_fopen_text - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_text}" >&5 -$as_echo "${libopts_cv_run_fopen_text}" >&6; } + tv.tv_sec=10; + tv.tv_usec=0; - if test "X${libopts_cv_run_fopen_text}" != Xno - then + FD_ZERO(&rfds); + FD_SET(fildes[0], &rfds); -$as_echo "#define FOPEN_TEXT_FLAG \"t\"" >>confdefs.h + /* we're not interested in any fds */ + i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv); - else + if(i < 0) { + perror("select"); + exit(10); + } -$as_echo "#define FOPEN_TEXT_FLAG \"\"" >>confdefs.h + exit(0); /* if we exit here, the select blocked the whole process */ +} - fi +int main(argc, argv) + int argc; + char **argv; +{ + pthread_t t; + /* create a pipe to select */ + if(pipe(&fildes[0])) { + perror("select"); + exit(1); + } +#ifdef HAVE_PTHREAD_SETCONCURRENCY + (void) pthread_setconcurrency(2); +#else +#ifdef HAVE_THR_SETCONCURRENCY + /* Set Solaris LWP concurrency to 2 */ + thr_setconcurrency(2); +#endif +#endif - # Check to see if not wanting optional option args. +#if HAVE_PTHREADS < 6 + pthread_create(&t, pthread_attr_default, task, NULL); +#else + pthread_create(&t, NULL, task, NULL); +#endif - # Check whether --enable-optional-args was given. -if test "${enable_optional_args+set}" = set; then : - enableval=$enable_optional_args; libopts_cv_enable_optional_args=${enable_optional_args} -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether not wanting optional option args" >&5 -$as_echo_n "checking whether not wanting optional option args... " >&6; } -if test "${libopts_cv_enable_optional_args+set}" = set; then : - $as_echo_n "(cached) " >&6 + /* make sure task runs first */ +#ifdef HAVE_THR_YIELD + thr_yield(); +#elif defined( HAVE_SCHED_YIELD ) + sched_yield(); +#elif defined( HAVE_PTHREAD_YIELD ) + pthread_yield(); +#endif + + exit(2); +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ol_cv_pthread_select_yields=no else - libopts_cv_enable_optional_args=yes + ol_cv_pthread_select_yields=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_enable_optional_args" >&5 -$as_echo "$libopts_cv_enable_optional_args" >&6; } fi - # end of AC_ARG_ENABLE +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_select_yields" >&5 +$as_echo "$ol_cv_pthread_select_yields" >&6; } - if test "X${libopts_cv_enable_optional_args}" = Xno - then + if test $ol_cv_pthread_select_yields = cross ; then + as_fn_error $? "crossing compiling: use --with-yielding-select=yes|no|manual" "$LINENO" 5 + fi -$as_echo "#define NO_OPTIONAL_OPT_ARGS 1" >>confdefs.h + if test $ol_cv_pthread_select_yields = yes ; then + ol_with_yielding_select=yes + fi + fi - fi + CPPFLAGS="$save_CPPFLAGS" + LIBS="$save_LIBS" + else + as_fn_error $? "could not locate usable POSIX Threads" "$LINENO" 5 + fi + fi + if test $ol_with_threads = posix ; then + as_fn_error $? "could not locate POSIX Threads" "$LINENO" 5 + fi + ;; +esac +case $ol_with_threads in auto | yes | mach) + for ac_header in mach/cthreads.h cthreads.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF - else +fi -if test X${INVOKE_LIBOPTS_MACROS_FIRST_done} != Xyes ; then - # ================= - # AC_HEADER_STDC - # ================= - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : +done + + if test $ac_cv_header_mach_cthreads_h = yes ; then + ol_with_threads=found + + ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork" +if test "x$ac_cv_func_cthread_fork" = xyes; then : + ol_link_threads=yes +fi + + + if test $ol_link_threads = no ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cthread_fork with -all_load" >&5 +$as_echo_n "checking for cthread_fork with -all_load... " >&6; } +if ${ol_cv_cthread_all_load+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include + save_LIBS="$LIBS" + LIBS="-all_load $LIBS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include int main () { + cthread_fork((void *)0, (void *)0); + ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_cthread_all_load=yes else - ac_cv_header_stdc=no + ol_cv_cthread_all_load=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$save_LIBS" -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_cthread_all_load" >&5 +$as_echo "$ol_cv_cthread_all_load" >&6; } -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : + if test $ol_cv_cthread_all_load = yes ; then + LTHREAD_LIBS="$LTHREAD_LIBS -all_load" + ol_link_threads=mach + ol_with_threads=found + fi + fi -else - ac_cv_header_stdc=no -fi -rm -f conftest* + elif test $ac_cv_header_cthreads_h = yes ; then + + ol_with_threads=found + save_LIBS="$LIBS" + LIBS="$LIBS -lthreads" + ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork" +if test "x$ac_cv_func_cthread_fork" = xyes; then : + ol_link_threads=yes fi -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include + LIBS="$save_LIBS" -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : + if test $ol_link_threads = yes ; then + LTHREAD_LIBS="-lthreads" + ol_link_threads=mach + ol_with_threads=found + else + as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5 + fi -else - ac_cv_header_stdc=no -fi -rm -f conftest* + elif test $ol_with_threads = mach ; then + as_fn_error $? "could not locate Mach CThreads" "$LINENO" 5 + fi -fi + if test $ol_link_threads = mach ; then -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif +$as_echo "#define HAVE_MACH_CTHREADS 1" >>confdefs.h -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : + elif test $ol_with_threads = found ; then + as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5 + fi + ;; +esac -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi +case $ol_with_threads in auto | yes | pth) + + for ac_header in pth.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "pth.h" "ac_cv_header_pth_h" "$ac_includes_default" +if test "x$ac_cv_header_pth_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTH_H 1 +_ACEOF fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then -$as_echo "#define STDC_HEADERS 1" >>confdefs.h +done -fi - # ================= - # AC_HEADER_DIRENT - # ================= - ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : + if test $ac_cv_header_pth_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pth_version in -lpth" >&5 +$as_echo_n "checking for pth_version in -lpth... " >&6; } +if ${ac_cv_lib_pth_pth_version+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_check_lib_save_LIBS=$LIBS +LIBS="-lpth $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include <$ac_hdr> +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pth_version (); int main () { -if ((DIR *) 0) -return 0; +return pth_version (); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$as_ac_Header=yes" +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_pth_pth_version=yes else - eval "$as_ac_Header=no" + ac_cv_lib_pth_pth_version=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi -eval ac_res=\$$as_ac_Header - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pth_pth_version" >&5 +$as_echo "$ac_cv_lib_pth_pth_version" >&6; } +if test "x$ac_cv_lib_pth_pth_version" = xyes; then : + have_pth=yes +else + have_pth=no +fi + + + if test $have_pth = yes ; then + +$as_echo "#define HAVE_GNU_PTH 1" >>confdefs.h + + LTHREAD_LIBS="$LTHREAD_LIBS -lpth" + ol_link_threads=pth + ol_with_threads=found + + if test x$ol_with_yielding_select = xauto ; then + ol_with_yielding_select=yes + fi + fi + fi + ;; +esac + +case $ol_with_threads in auto | yes | lwp) + + for ac_header in thread.h synch.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF -ac_header_dirent=$ac_hdr; break fi done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : + + if test $ac_cv_header_thread_h = yes && + test $ac_cv_header_synch_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 +$as_echo_n "checking for thr_create in -lthread... " >&6; } +if ${ac_cv_lib_thread_thr_create+:} false; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS + ac_check_lib_save_LIBS=$LIBS +LIBS="-lthread $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -14074,54 +14664,82 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char opendir (); +char thr_create (); int main () { -return opendir (); +return thr_create (); ; return 0; } _ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_thread_thr_create=yes +else + ac_cv_lib_thread_thr_create=no fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi -done -if test "${ac_cv_search_opendir+set}" = set; then : - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 +$as_echo "$ac_cv_lib_thread_thr_create" >&6; } +if test "x$ac_cv_lib_thread_thr_create" = xyes; then : + have_thr=yes else - ac_cv_search_opendir=no + have_thr=no fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS + + + if test $have_thr = yes ; then + +$as_echo "#define HAVE_THR 1" >>confdefs.h + + LTHREAD_LIBS="$LTHREAD_LIBS -lthread" + ol_link_threads=thr + + if test x$ol_with_yielding_select = xauto ; then + ol_with_yielding_select=yes + fi + + for ac_func in \ + thr_setconcurrency \ + thr_getconcurrency \ + +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +done + + fi + fi + + for ac_header in lwp/lwp.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default" +if test "x$ac_cv_header_lwp_lwp_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LWP_LWP_H 1 +_ACEOF fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then : +done + + if test $ac_cv_header_lwp_lwp_h = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwp_create in -llwp" >&5 +$as_echo_n "checking for lwp_create in -llwp... " >&6; } +if ${ac_cv_lib_lwp_lwp_create+:} false; then : $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS + ac_check_lib_save_LIBS=$LIBS +LIBS="-llwp $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -14131,62 +14749,65 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char opendir (); +char lwp_create (); int main () { -return opendir (); +return lwp_create (); ; return 0; } _ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_opendir=$ac_res +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_lwp_lwp_create=yes +else + ac_cv_lib_lwp_lwp_create=no fi rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then : - break + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi -done -if test "${ac_cv_search_opendir+set}" = set; then : - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lwp_lwp_create" >&5 +$as_echo "$ac_cv_lib_lwp_lwp_create" >&6; } +if test "x$ac_cv_lib_lwp_lwp_create" = xyes; then : + have_lwp=yes else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS + have_lwp=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi + + if test $have_lwp = yes ; then + +$as_echo "#define HAVE_LWP 1" >>confdefs.h + + LTHREAD_LIBS="$LTHREAD_LIBS -llwp" + ol_link_threads=lwp + + if test x$ol_with_yielding_select = xauto ; then + ol_with_yielding_select=no + fi + fi + fi + ;; +esac + +if test $ol_with_yielding_select = yes ; then + +$as_echo "#define HAVE_YIELDING_SELECT 1" >>confdefs.h fi +if test $ol_with_threads = manual ; then + ol_link_threads=yes - # ================= - # AC_CHECK_HEADERS - # ================= - for ac_header in dlfcn.h errno.h fcntl.h libgen.h memory.h netinet/in.h \ - setjmp.h sys/mman.h sys/param.h sys/poll.h sys/procset.h sys/select.h \ - sys/socket.h sys/stropts.h sys/time.h sys/un.h sys/wait.h unistd.h \ - utime.h sysexits.h + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: thread defines and link options must be set manually" >&5 +$as_echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;} + + for ac_header in pthread.h sched.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -14195,336 +14816,447 @@ fi done - - # -------------------------------------------- - # Verify certain entries from AC_CHECK_HEADERS - # -------------------------------------------- - for f in sys_types sys_mman sys_param sys_stat sys_wait \ - string errno stdlib memory setjmp - do eval as_ac_var=\${ac_cv_header_${f}_h+set} - test "${as_ac_var}" = set || \ - as_fn_error "You must have ${f}.h on your system" "$LINENO" 5 - done - - # ================================================ - # AC_CHECK_HEADERS: stdarg.h is present define HAVE_STDARG_H, otherwise - # if varargs.h is present define HAVE_VARARGS_H. - # ================================================ - for ac_header in stdarg.h varargs.h + for ac_func in sched_yield pthread_yield do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF - break -fi +fi done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have stdarg.h or varargs.h on your system" "$LINENO" 5 - fi - # ================================================ - # Similarly for the string.h and strings.h headers - # ================================================ - for ac_header in string.h strings.h + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5 +$as_echo_n "checking for LinuxThreads pthread.h... " >&6; } +if ${ol_cv_header_linux_threads+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then : + ol_cv_header_linux_threads=yes +else + ol_cv_header_linux_threads=no +fi +rm -f conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5 +$as_echo "$ol_cv_header_linux_threads" >&6; } + if test $ol_cv_header_linux_threads = yes; then + +$as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h + + fi + + + for ac_header in mach/cthreads.h do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : + ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default" +if test "x$ac_cv_header_mach_cthreads_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_MACH_CTHREADS_H 1 _ACEOF - break + fi done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have string.h or strings.h on your system" "$LINENO" 5 - fi - - # ===================== - # ...and limits headers - # ===================== - for ac_header in limits.h sys/limits.h values.h + for ac_header in lwp/lwp.h do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : + ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default" +if test "x$ac_cv_header_lwp_lwp_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_LWP_LWP_H 1 _ACEOF - break + fi done - if test `eval echo '${'$as_ac_Header'}'` != yes; then - as_fn_error "You must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 - fi - - # ======================== - # ...and int types headers - # ======================== - for ac_header in stdint.h inttypes.h + for ac_header in thread.h synch.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF - break + fi done - ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" -if test "x$ac_cv_type_int8_t" = x""yes; then : - -cat >>confdefs.h <<_ACEOF -#define HAVE_INT8_T 1 -_ACEOF +fi +if test $ol_link_threads != no && test $ol_link_threads != nt ; then -fi -ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" -if test "x$ac_cv_type_uint8_t" = x""yes; then : +$as_echo "#define REENTRANT 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT8_T 1 -_ACEOF +$as_echo "#define _REENTRANT 1" >>confdefs.h -fi -ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" -if test "x$ac_cv_type_int16_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_INT16_T 1 -_ACEOF +$as_echo "#define THREAD_SAFE 1" >>confdefs.h -fi -ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" -if test "x$ac_cv_type_uint16_t" = x""yes; then : +$as_echo "#define _THREAD_SAFE 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT16_T 1 -_ACEOF +$as_echo "#define THREADSAFE 1" >>confdefs.h -fi -ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" -if test "x$ac_cv_type_int32_t" = x""yes; then : -cat >>confdefs.h <<_ACEOF -#define HAVE_INT32_T 1 -_ACEOF +$as_echo "#define _THREADSAFE 1" >>confdefs.h -fi -ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" -if test "x$ac_cv_type_uint32_t" = x""yes; then : +$as_echo "#define _SGI_MP_SOURCE 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT32_T 1 -_ACEOF + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific errno" >&5 +$as_echo_n "checking for thread specific errno... " >&6; } +if ${ol_cv_errno_thread_specific+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +errno = 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_errno_thread_specific=yes +else + ol_cv_errno_thread_specific=no fi -ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" -if test "x$ac_cv_type_intptr_t" = x""yes; then : +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext -cat >>confdefs.h <<_ACEOF -#define HAVE_INTPTR_T 1 -_ACEOF +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_errno_thread_specific" >&5 +$as_echo "$ol_cv_errno_thread_specific" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific h_errno" >&5 +$as_echo_n "checking for thread specific h_errno... " >&6; } +if ${ol_cv_h_errno_thread_specific+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +h_errno = 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ol_cv_h_errno_thread_specific=yes +else + ol_cv_h_errno_thread_specific=no fi -ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" -if test "x$ac_cv_type_uint_t" = x""yes; then : +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext -cat >>confdefs.h <<_ACEOF -#define HAVE_UINT_T 1 -_ACEOF +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_h_errno_thread_specific" >&5 +$as_echo "$ol_cv_h_errno_thread_specific" >&6; } + if test $ol_cv_errno_thread_specific != yes || + test $ol_cv_h_errno_thread_specific != yes ; then + LIBS="$LTHREAD_LIBS $LIBS" + LTHREAD_LIBS="" + fi fi +if test $ol_link_threads = no ; then + if test $ol_with_threads = yes ; then + as_fn_error $? "no suitable thread support" "$LINENO" 5 + fi - # ==================== - # uintptr type & sizes - # ==================== - ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" -if test "x$ac_cv_type_uintptr_t" = x""yes; then : + if test $ol_with_threads = auto ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no suitable thread support, disabling threads" >&5 +$as_echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;} + ol_with_threads=no + fi -cat >>confdefs.h <<_ACEOF -#define HAVE_UINTPTR_T 1 -_ACEOF +$as_echo "#define NO_THREADS 1" >>confdefs.h + LTHREAD_LIBS="" + BUILD_THREAD=no else + BUILD_THREAD=yes +fi -$as_echo "#define uintptr_t unsigned long" >>confdefs.h +if test $ol_link_threads != no ; then + +$as_echo "#define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1" >>confdefs.h fi - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5 -$as_echo_n "checking size of char*... " >&6; } -if test "${ac_cv_sizeof_charp+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp" "$ac_includes_default"; then : +# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND: +case "$ol_with_threads" in + no) + ol_pthread_ok=no -else - if test "$ac_cv_type_charp" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (char*) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_charp=0 - fi -fi + ;; + *) + ol_found_pthreads=yes + ;; +esac -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5 -$as_echo "$ac_cv_sizeof_charp" >&6; } +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu -cat >>confdefs.h <<_ACEOF -#define SIZEOF_CHARP $ac_cv_sizeof_charp + + + + case "$ol_found_pthreads" in + yes) + saved_LIBS="$LIBS" + LIBS="$LTHREAD_LIBS $LIBS" + saved_CFLAGS="$CFLAGS" + CFLAGS="$PTHREAD_CFLAGS $CFLAGS" + for ac_func in sem_timedwait +do : + ac_fn_c_check_func "$LINENO" "sem_timedwait" "ac_cv_func_sem_timedwait" +if test "x$ac_cv_func_sem_timedwait" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SEM_TIMEDWAIT 1 _ACEOF +fi +done - # The cast to long int works around a bug in the HP C Compiler + LIBS="$saved_LIBS" + { saved_LIBS=; unset saved_LIBS;} + CFLAGS="$saved_CFLAGS" + { saved_CFLAGS=; unset saved_CFLAGS;} + case "$ac_cv_func_sem_timedwait" in + yes) + PTHREAD_LIBS="$LTHREAD_LIBS" + have_pthreads=yes + esac + esac +esac + +case "$have_pthreads" in + yes) + CFLAGS_NTP="$CFLAGS_NTP $PTHREAD_CFLAGS" + saved_LIBS="$LIBS" + LIBS="$LTHREAD_LIBS $LIBS" + saved_CFLAGS="$CFLAGS" + CFLAGS="$PTHREAD_CFLAGS $CFLAGS" + # The cast to long int works around a bug in the HP C Compiler # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. # This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then : +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 +$as_echo_n "checking size of pthread_t... " >&6; } +if ${ac_cv_sizeof_pthread_t+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t" " + $ac_includes_default + #include + + +"; then : else - if test "$ac_cv_type_int" = yes; then + if test "$ac_cv_type_pthread_t" = yes; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (int) -See \`config.log' for more details." "$LINENO" 5; }; } +as_fn_error 77 "cannot compute sizeof (pthread_t) +See \`config.log' for more details" "$LINENO" 5; } else - ac_cv_sizeof_int=0 + ac_cv_sizeof_pthread_t=0 fi fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 +$as_echo "$ac_cv_sizeof_pthread_t" >&6; } cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int +#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t _ACEOF - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then : + LIBISC_PTHREADS_NOTHREADS=pthreads + +$as_echo "#define ISC_PLATFORM_USETHREADS 1" >>confdefs.h + + # + # We'd like to use sigwait() too + # + ac_fn_c_check_func "$LINENO" "sigwait" "ac_cv_func_sigwait" +if test "x$ac_cv_func_sigwait" = xyes; then : + have_sigwait=yes +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc" >&5 +$as_echo_n "checking for sigwait in -lc... " >&6; } +if ${ac_cv_lib_c_sigwait+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + ac_check_lib_save_LIBS=$LIBS +LIBS="-lc $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sigwait (); +int +main () +{ +return sigwait (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_c_sigwait=yes else - if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (long) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_long=0 - fi + ac_cv_lib_c_sigwait=no fi - +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } - - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_sigwait" >&5 +$as_echo "$ac_cv_lib_c_sigwait" >&6; } +if test "x$ac_cv_lib_c_sigwait" = xyes; then : + have_sigwait=yes +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lpthread" >&5 +$as_echo_n "checking for sigwait in -lpthread... " >&6; } +if ${ac_cv_lib_pthread_sigwait+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lpthread $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sigwait (); +int +main () +{ +return sigwait (); + ; + return 0; +} _ACEOF - - - # The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 -$as_echo_n "checking size of short... " >&6; } -if test "${ac_cv_sizeof_short+set}" = set; then : +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_pthread_sigwait=yes +else + ac_cv_lib_pthread_sigwait=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_sigwait" >&5 +$as_echo "$ac_cv_lib_pthread_sigwait" >&6; } +if test "x$ac_cv_lib_pthread_sigwait" = xyes; then : + have_sigwait=yes +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Psigwait in -lpthread" >&5 +$as_echo_n "checking for _Psigwait in -lpthread... " >&6; } +if ${ac_cv_lib_pthread__Psigwait+:} false; then : $as_echo_n "(cached) " >&6 else - if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + ac_check_lib_save_LIBS=$LIBS +LIBS="-lpthread $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char _Psigwait (); +int +main () +{ +return _Psigwait (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_pthread__Psigwait=yes else - if test "$ac_cv_type_short" = yes; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ as_fn_set_status 77 -as_fn_error "cannot compute sizeof (short) -See \`config.log' for more details." "$LINENO" 5; }; } - else - ac_cv_sizeof_short=0 - fi + ac_cv_lib_pthread__Psigwait=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread__Psigwait" >&5 +$as_echo "$ac_cv_lib_pthread__Psigwait" >&6; } +if test "x$ac_cv_lib_pthread__Psigwait" = xyes; then : + have_sigwait=yes +else + have_sigwait=no fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 -$as_echo "$ac_cv_sizeof_short" >&6; } +fi -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SHORT $ac_cv_sizeof_short -_ACEOF +fi - # ---------------------------------------------------------------------- - # AC_CHECK_LIB for SVR4 libgen, and use it if it defines pathfind. - # ---------------------------------------------------------------------- - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 -$as_echo_n "checking for pathfind in -lgen... " >&6; } -if test "${ac_cv_lib_gen_pathfind+set}" = set; then : +fi + + case "$host:$have_sigwait" in + *-freebsd*:no) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc_r" >&5 +$as_echo_n "checking for sigwait in -lc_r... " >&6; } +if ${ac_cv_lib_c_r_sigwait+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lgen $LIBS" +LIBS="-lc_r $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -14534,60 +15266,56 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #ifdef __cplusplus extern "C" #endif -char pathfind (); +char sigwait (); int main () { -return pathfind (); +return sigwait (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - ac_cv_lib_gen_pathfind=yes + ac_cv_lib_c_r_sigwait=yes else - ac_cv_lib_gen_pathfind=no + ac_cv_lib_c_r_sigwait=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 -$as_echo "$ac_cv_lib_gen_pathfind" >&6; } -if test "x$ac_cv_lib_gen_pathfind" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBGEN 1 -_ACEOF - - LIBS="-lgen $LIBS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_sigwait" >&5 +$as_echo "$ac_cv_lib_c_r_sigwait" >&6; } +if test "x$ac_cv_lib_c_r_sigwait" = xyes; then : + have_sigwait=yes fi - for ac_func in vprintf -do : - ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" -if test "x$ac_cv_func_vprintf" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_VPRINTF 1 -_ACEOF + esac + case "$have_sigwait" in + yes) + ac_cv_func_sigwait=yes -ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" -if test "x$ac_cv_func__doprnt" = x""yes; then : +$as_echo "#define HAVE_SIGWAIT 1" >>confdefs.h -$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h + esac -fi + for ac_func in pthread_attr_getstacksize +do : + ac_fn_c_check_func "$LINENO" "pthread_attr_getstacksize" "ac_cv_func_pthread_attr_getstacksize" +if test "x$ac_cv_func_pthread_attr_getstacksize" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_ATTR_GETSTACKSIZE 1 +_ACEOF fi done - - for ac_func in mmap canonicalize_file_name snprintf strdup strchr strrchr + for ac_func in pthread_attr_setstacksize sysconf do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF @@ -14595,219 +15323,246 @@ _ACEOF fi done - INVOKE_LIBOPTS_MACROS_FIRST_done=yes -fi - fi -# end of AC_DEFUN of LIBOPTS_CHECK + case "$host" in + *-freebsd5.[012]|*-freebsd5.[012].*) + ;; + *-freebsd5.[3456789]|*-freebsd5.[3456789].*|*-freebsd6.*) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5 -$as_echo_n "checking if $CC can handle #warning... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +$as_echo "#define NEED_PTHREAD_SCOPE_SYSTEM 1" >>confdefs.h -int -main () -{ -#warning foo - ; - return 0; -} + ;; + *-bsdi3.*|*-bsdi4.0*) + +$as_echo "#define NEED_PTHREAD_INIT 1" >>confdefs.h + + ;; + *-linux*) + +$as_echo "#define HAVE_LINUXTHREADS 1" >>confdefs.h + + ;; + *-solaris*) + $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h + + for ac_func in pthread_setconcurrency +do : + ac_fn_c_check_func "$LINENO" "pthread_setconcurrency" "ac_cv_func_pthread_setconcurrency" +if test "x$ac_cv_func_pthread_setconcurrency" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PTHREAD_SETCONCURRENCY 1 _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_cpp_warning=yes -else - ac_cv_cpp_warning=no + fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cpp_warning" >&5 -$as_echo "$ac_cv_cpp_warning" >&6; } +done -case "$ac_cv_cpp_warning" in - no) + case "$ac_cv_func_pthread_setconcurrency" in + yes) -$as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h +$as_echo "#define CALL_PTHREAD_SETCONCURRENCY 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: result: Enabling NO_OPTION_NAME_WARNINGS as #warning does not work" >&5 -$as_echo "Enabling NO_OPTION_NAME_WARNINGS as #warning does not work" >&6; } - ;; -esac + esac + ;; + *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 -$as_echo_n "checking for inline... " >&6; } -if test "${ac_cv_c_inline+set}" = set; then : +$as_echo "#define HAVE_UNIXWARE_SIGWAIT 1" >>confdefs.h + + ;; + esac + hack_shutup_pthreadonceinit=no + case "$host" in + *-aix5.[123].*) + hack_shutup_pthreadonceinit=yes + ;; + *-solaris2.[89]) + hack_shutup_pthreadonceinit=yes + ;; + *-solaris2.1[0-9]) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if extra braces are needed for PTHREAD_ONCE_INIT" >&5 +$as_echo_n "checking if extra braces are needed for PTHREAD_ONCE_INIT... " >&6; } +if ${ntp_cv_braces_around_pthread_once_init+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_c_inline=no -for ac_kw in inline __inline__ __inline; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifndef __cplusplus -typedef int foo_t; -static $ac_kw foo_t static_foo () {return 0; } -$ac_kw foo_t foo () {return 0; } -#endif + #include + +int +main () +{ + + static pthread_once_t once_test = + PTHREAD_ONCE_INIT; + + + ; + return 0; +} _ACEOF if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_inline=$ac_kw + ntp_cv_braces_around_pthread_once_init=no +else + ntp_cv_braces_around_pthread_once_init=yes + fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - test "$ac_cv_c_inline" != no && break -done fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 -$as_echo "$ac_cv_c_inline" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_braces_around_pthread_once_init" >&5 +$as_echo "$ntp_cv_braces_around_pthread_once_init" >&6; } + case "$ntp_cv_braces_around_pthread_once_init" in + yes) + hack_shutup_pthreadonceinit=yes + esac + ;; + esac + case "$hack_shutup_pthreadonceinit" in + yes) + +$as_echo "#define ISC_PLATFORM_BRACEPTHREADONCEINIT 1" >>confdefs.h -case $ac_cv_c_inline in - inline | yes) ;; - *) - case $ac_cv_c_inline in - no) ac_val=;; - *) ac_val=$ac_cv_c_inline;; esac - cat >>confdefs.h <<_ACEOF -#ifndef __cplusplus -#define inline $ac_val -#endif -_ACEOF + LIBS="$saved_LIBS" + { saved_LIBS=; unset saved_LIBS;} + CFLAGS="$saved_CFLAGS" + { saved_CFLAGS=; unset saved_CFLAGS;} + ;; + *) + LIBISC_PTHREADS_NOTHREADS=nothreads ;; esac + if test "$have_pthreads" != "no"; then + PTHREADS_TRUE= + PTHREADS_FALSE='#' +else + PTHREADS_TRUE='#' + PTHREADS_FALSE= +fi -case "$ac_cv_c_inline" in - '') - ;; - *) -$as_echo "#define HAVE_INLINE 1" >>confdefs.h -esac -# Checks for libraries. -# Checks for header files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : +case "$hw_use_rpl_vsnprintf:$hw_cv_func_vsnprintf" in + no:yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if vsnprintf expands \"%m\" to strerror(errno)" >&5 +$as_echo_n "checking if vsnprintf expands \"%m\" to strerror(errno)... " >&6; } +if ${ntp_cv_vsnprintf_percent_m+:} false; then : $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ntp_cv_vsnprintf_percent_m=no + else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include -#include + + #include + #include + #include + #include + + int call_vsnprintf( + char * dst, + size_t sz, + const char *fmt, + ... + ); + + int call_vsnprintf( + char * dst, + size_t sz, + const char *fmt, + ... + ) + { + va_list ap; + int rc; + + va_start(ap, fmt); + rc = vsnprintf(dst, sz, fmt, ap); + va_end(ap); + + return rc; + } int main () { + char sbuf[512]; + char pbuf[512]; + int slen; + + strcpy(sbuf, strerror(ENOENT)); + errno = ENOENT; + slen = call_vsnprintf(pbuf, sizeof(pbuf), "%m", + "wrong"); + return strcmp(sbuf, pbuf); + + ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes +if ac_fn_c_try_run "$LINENO"; then : + ntp_cv_vsnprintf_percent_m=yes else - ac_cv_header_stdc=no + ntp_cv_vsnprintf_percent_m=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : -else - ac_cv_header_stdc=no fi -rm -f conftest* +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_vsnprintf_percent_m" >&5 +$as_echo "$ntp_cv_vsnprintf_percent_m" >&6; } + case "$ntp_cv_vsnprintf_percent_m" in + yes) -fi +$as_echo "#define VSNPRINTF_PERCENT_M 1" >>confdefs.h -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include + esac +esac +for ac_header in sys/clockctl.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sys/clockctl.h" "ac_cv_header_sys_clockctl_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_clockctl_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_CLOCKCTL_H 1 _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no -fi -rm -f conftest* fi -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif +done -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : +# Check whether --enable-clockctl was given. +if test "${enable_clockctl+set}" = set; then : + enableval=$enable_clockctl; ntp_use_dev_clockctl=$enableval else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi + ntp_use_dev_clockctl=$ac_cv_header_sys_clockctl_h fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then -$as_echo "#define STDC_HEADERS 1" >>confdefs.h -fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use /dev/clockctl" >&5 +$as_echo_n "checking if we should use /dev/clockctl... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_dev_clockctl" >&5 +$as_echo "$ntp_use_dev_clockctl" >&6; } + -for ac_header in arpa/inet.h fcntl.h float.h limits.h netdb.h netinet/in.h stdlib.h string.h sys/socket.h sys/time.h syslog.h unistd.h +for ac_header in sys/capability.h sys/prctl.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -eval as_val=\$$as_ac_Header - if test "x$as_val" = x""yes; then : +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -14817,1697 +15572,17724 @@ fi done -# Checks for typedefs, structures, and compiler characteristics. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 -$as_echo_n "checking for an ANSI C-conforming const... " >&6; } -if test "${ac_cv_c_const+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have linux capabilities (libcap)" >&5 +$as_echo_n "checking if we have linux capabilities (libcap)... " >&6; } -int -main () -{ -/* FIXME: Include the comments suggested by Paul. */ -#ifndef __cplusplus - /* Ultrix mips cc rejects this. */ - typedef int charset[2]; - const charset cs; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this. */ - char *t; - char const *s = 0 ? (char *) 0 : (char const *) 0; +case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in + yesyes) + case "$host" in + mips-sgi-irix*) + ntp_have_linuxcaps=no + ;; + *) ntp_have_linuxcaps=yes + ;; + esac + ;; + *) + ntp_have_linuxcaps=no + ;; +esac - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; }; - struct s *b; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif +# Check whether --enable-linuxcaps was given. +if test "${enable_linuxcaps+set}" = set; then : + enableval=$enable_linuxcaps; ntp_have_linuxcaps=$enableval - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_const=yes -else - ac_cv_c_const=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 -$as_echo "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then -$as_echo "#define const /**/" >>confdefs.h + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5 +$as_echo "$ntp_have_linuxcaps" >&6; } + +case "$ntp_have_linuxcaps" in + yes) + +$as_echo "#define HAVE_LINUX_CAPABILITIES 1" >>confdefs.h + + LIBS="$LIBS -lcap" + ;; +esac + + +for ac_header in priv.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "priv.h" "ac_cv_header_priv_h" "$ac_includes_default" +if test "x$ac_cv_header_priv_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PRIV_H 1 +_ACEOF fi -ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" -if test "x$ac_cv_type_size_t" = x""yes; then : +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have solaris privileges" >&5 +$as_echo_n "checking if we have solaris privileges... " >&6; } +case "$ac_cv_header_priv_h" in + yes) + case "$host" in + *-solaris*) + ac_fn_c_check_func "$LINENO" "setppriv" "ac_cv_func_setppriv" +if test "x$ac_cv_func_setppriv" = xyes; then : + ntp_have_solarisprivs=yes else + ntp_have_solarisprivs=no -cat >>confdefs.h <<_ACEOF -#define size_t unsigned int -_ACEOF +fi + + ;; + esac +esac + +# Check whether --enable-solarisprivs was given. +if test "${enable_solarisprivs+set}" = set; then : + enableval=$enable_solarisprivs; ntp_have_solarisprivs=$enableval fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 -$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } -if test "${ac_cv_header_time+set}" = set; then : + + +case "$ntp_have_solarisprivs" in + yes) + +$as_echo "#define HAVE_SOLARIS_PRIVS 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_solarisprivs" >&5 +$as_echo "$ntp_have_solarisprivs" >&6; } + +case "$ntp_use_dev_clockctl$ntp_have_linuxcaps$ntp_have_solarisprivs" in + *yes*) + +$as_echo "#define HAVE_DROPROOT 1" >>confdefs.h + +esac + +case "$host" in + *-*-darwin*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_init" >&5 +$as_echo_n "checking for library containing res_9_init... " >&6; } +if ${ac_cv_search_res_9_init+:} false; then : $as_echo_n "(cached) " >&6 else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -#include +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char res_9_init (); int main () { -if ((struct tm *) 0) -return 0; +return res_9_init (); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_time=yes -else - ac_cv_header_time=no +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_res_9_init=$ac_res fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_res_9_init+:} false; then : + break fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 -$as_echo "$ac_cv_header_time" >&6; } -if test $ac_cv_header_time = yes; then +done +if ${ac_cv_search_res_9_init+:} false; then : -$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h +else + ac_cv_search_res_9_init=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_init" >&5 +$as_echo "$ac_cv_search_res_9_init" >&6; } +ac_res=$ac_cv_search_res_9_init +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 -$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } -if test "${ac_cv_struct_tm+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include + ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_init" >&5 +$as_echo_n "checking for library containing res_init... " >&6; } +if ${ac_cv_search_res_init+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char res_init (); +int +main () +{ +return res_init (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_res_init=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_res_init+:} false; then : + break +fi +done +if ${ac_cv_search_res_init+:} false; then : + +else + ac_cv_search_res_init=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_init" >&5 +$as_echo "$ac_cv_search_res_init" >&6; } +ac_res=$ac_cv_search_res_init +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + ;; +esac +for ac_header in sys/types.h netinet/in.h arpa/nameser.h netdb.h resolv.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_NETINET_IN_H +# include /* inet_ functions / structs */ +#endif +#ifdef HAVE_ARPA_NAMESER_H +# include /* DNS HEADER struct */ +#endif +#ifdef HAVE_NETDB_H +# include +#endif +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +#HMS: Why do we do this check so "early"? +for ac_func in res_init +do : + ac_fn_c_check_func "$LINENO" "res_init" "ac_cv_func_res_init" +if test "x$ac_cv_func_res_init" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_RES_INIT 1 +_ACEOF + +else + for ac_func in __res_init +do : + ac_fn_c_check_func "$LINENO" "__res_init" "ac_cv_func___res_init" +if test "x$ac_cv_func___res_init" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE___RES_INIT 1 +_ACEOF + +fi +done + +fi +done + + +# We also need -lsocket, but we have tested for that already. +ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" +if test "x$ac_cv_func_inet_ntop" = xyes; then : + +else + +$as_echo "#define ISC_PLATFORM_NEEDNTOP 1" >>confdefs.h + +fi + +ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton" +if test "x$ac_cv_func_inet_pton" = xyes; then : + +else + +$as_echo "#define ISC_PLATFORM_NEEDPTON 1" >>confdefs.h + +fi + + +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "int32" "ac_cv_type_int32" "$ac_includes_default" +if test "x$ac_cv_type_int32" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT32 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "u_int32" "ac_cv_type_u_int32" "$ac_includes_default" +if test "x$ac_cv_type_u_int32" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_U_INT32 1 +_ACEOF + + +fi + + + + +case "$ac_cv_type_int32::$ac_cv_header_resolv_h" in + no::yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int32 with DNS headers included" >&5 +$as_echo_n "checking for int32 with DNS headers included... " >&6; } +if ${ntp_cv_type_int32_with_dns+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif + #include + +int +main () +{ + + size_t cb = sizeof(int32); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_type_int32_with_dns=yes +else + ntp_cv_type_int32_with_dns=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_int32_with_dns" >&5 +$as_echo "$ntp_cv_type_int32_with_dns" >&6; } + case "$ntp_cv_type_int32_with_dns" in + yes) + +$as_echo "#define HAVE_INT32_ONLY_WITH_DNS 1" >>confdefs.h + + esac +esac + +case "$ac_cv_type_u_int32::$ac_cv_header_resolv_h" in + no::yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int32 with DNS headers included" >&5 +$as_echo_n "checking for u_int32 with DNS headers included... " >&6; } +if ${ntp_cv_type_u_int32_with_dns+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_ARPA_NAMESER_H + # include + #endif + #include + +int +main () +{ + + size_t cb = sizeof(u_int32); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_type_u_int32_with_dns=yes +else + ntp_cv_type_u_int32_with_dns=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_u_int32_with_dns" >&5 +$as_echo "$ntp_cv_type_u_int32_with_dns" >&6; } + case "$ntp_cv_type_u_int32_with_dns" in + yes) + +$as_echo "#define HAVE_U_INT32_ONLY_WITH_DNS 1" >>confdefs.h + + esac +esac + +for ac_header in sys/timepps.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/timepps.h" "ac_cv_header_sys_timepps_h" " + #ifdef HAVE_SYS_TIME_H + # include + #endif + #ifdef HAVE_ERRNO_H + # include + #endif + + +" +if test "x$ac_cv_header_sys_timepps_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_TIMEPPS_H 1 +_ACEOF + +fi + +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec" >&5 +$as_echo_n "checking for struct timespec... " >&6; } +if ${ntp_cv_struct_timespec+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + /* Under SunOS, timespec is in sys/timepps.h, + which needs errno.h and FRAC */ + #ifdef HAVE_ERRNO_H + # include + #endif + #ifdef HAVE_SYS_TIMEPPS_H + # define FRAC 4294967296 + # include + #endif + +int +main () +{ + + struct timespec n; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_struct_timespec=yes +else + ntp_cv_struct_timespec=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_timespec" >&5 +$as_echo "$ntp_cv_struct_timespec" >&6; } +case "$ntp_cv_struct_timespec" in + yes) + +$as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ntptimeval" >&5 +$as_echo_n "checking for struct ntptimeval... " >&6; } +if ${ntp_cv_struct_ntptimeval+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + struct ntptimeval n; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_struct_ntptimeval=yes +else + ntp_cv_struct_ntptimeval=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_ntptimeval" >&5 +$as_echo "$ntp_cv_struct_ntptimeval" >&6; } +case "$ntp_cv_struct_ntptimeval" in + yes) + +$as_echo "#define HAVE_STRUCT_NTPTIMEVAL 1" >>confdefs.h + +esac + +for ac_header in md5.h +do : + ac_fn_c_check_header_compile "$LINENO" "md5.h" "ac_cv_header_md5_h" " + #ifdef HAVE_SYS_TYPES_H + # include + #endif + + +" +if test "x$ac_cv_header_md5_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_MD5_H 1 +_ACEOF + +fi + +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing MD5Init" >&5 +$as_echo_n "checking for library containing MD5Init... " >&6; } +if ${ac_cv_search_MD5Init+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char MD5Init (); +int +main () +{ +return MD5Init (); + ; + return 0; +} +_ACEOF +for ac_lib in '' md5 md; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_MD5Init=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_MD5Init+:} false; then : + break +fi +done +if ${ac_cv_search_MD5Init+:} false; then : + +else + ac_cv_search_MD5Init=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_MD5Init" >&5 +$as_echo "$ac_cv_search_MD5Init" >&6; } +ac_res=$ac_cv_search_MD5Init +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +for ac_func in MD5Init sysconf getdtablesize sigaction sigset sigvec +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGIO" >&5 +$as_echo_n "checking for SIGIO... " >&6; } +if ${ntp_cv_hdr_def_sigio+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + + #ifndef SIGIO + # error + #endif + +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_cv_hdr_def_sigio=yes +else + ntp_cv_hdr_def_sigio=no + +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigio" >&5 +$as_echo "$ntp_cv_hdr_def_sigio" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use SIGIO" >&5 +$as_echo_n "checking if we want to use SIGIO... " >&6; } +ans=no +case "$ntp_cv_hdr_def_sigio" in + yes) + ans=yes + case "$host" in + alpha*-dec-osf4*|alpha*-dec-osf5*) + ans=no + ;; + *-convex-*) + ans=no + ;; + *-dec-*) + ans=no + ;; + *-pc-cygwin*) + ans=no + ;; + *-sni-sysv*) + ans=no + ;; + *-stratus-vos) + ans=no + ;; + *-univel-sysv*) + ans=no + ;; + *-*-irix6*) + ans=no + ;; + *-*-freebsd*) + ans=no + ;; + *-*-*linux*) + ans=no + ;; + *-*-unicosmp*) + ans=no + ;; + *-*-kfreebsd*) + ans=no + ;; + m68k-*-mint*) + ans=no + ;; + esac + ;; +esac +case "$ans" in + yes) + +$as_echo "#define HAVE_SIGNALED_IO 1" >>confdefs.h + +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGPOLL" >&5 +$as_echo_n "checking for SIGPOLL... " >&6; } +if ${ntp_cv_hdr_def_sigpoll+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + + #ifndef SIGPOLL + # error + #endif + +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ntp_cv_hdr_def_sigpoll=yes +else + ntp_cv_hdr_def_sigpoll=no + +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigpoll" >&5 +$as_echo "$ntp_cv_hdr_def_sigpoll" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for UDP I/O" >&5 +$as_echo_n "checking if we can use SIGPOLL for UDP I/O... " >&6; } +ans=no +case "$ntp_cv_hdr_def_sigpoll" in + yes) + case "$host" in + mips-sgi-irix*) + ans=no + ;; + vax-dec-bsd) + ans=no + ;; + *-pc-cygwin*) + ans=no + ;; + *-sni-sysv*) + ans=no + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix[4-9]*) + # XXX Only verified thru AIX6 + ans=no + ;; + *-*-hpux*) + ans=no + ;; + *-*-*linux*) + ans=no + ;; + *-*-osf*) + ans=no + ;; + *-*-qnx*) + ans=no + ;; + *-*-sunos*) + ans=no + ;; + *-*-solaris*) + ans=no + ;; + *-*-ultrix*) + ans=no + ;; + *-*-unicosmp*) + ans=no + ;; + *-*-kfreebsd*) + ans=no + ;; + *) ans=yes + ;; + esac + ;; +esac +case "$ans" in + yes) + +$as_echo "#define USE_UDP_SIGPOLL 1" >>confdefs.h + +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for TTY I/O" >&5 +$as_echo_n "checking if we can use SIGPOLL for TTY I/O... " >&6; } +ans=no +case "$ntp_cv_hdr_def_sigpoll" in + yes) + case "$host" in + mips-sgi-irix*) + ans=no + ;; + vax-dec-bsd) + ans=no + ;; + *-pc-cygwin*) + ans=no + ;; + *-sni-sysv*) + ans=no + ;; + *-stratus-vos) + ans=no + ;; + *-*-aix[4-9]*) + # XXX Only verified thru AIX6 + ans=no + ;; + *-*-hpux*) + ans=no + ;; + *-*-*linux*) + ans=no + ;; + *-*-osf*) + ans=no + ;; + *-*-sunos*) + ans=no + ;; + *-*-ultrix*) + ans=no + ;; + *-*-qnx*) + ans=no + ;; + *-*-unicosmp*) + ans=no + ;; + *-*-kfreebsd*) + ans=no + ;; + *) ans=yes + ;; + esac + ;; +esac +case "$ans" in + yes) + +$as_echo "#define USE_TTY_SIGPOLL 1" >>confdefs.h + +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to gettimeofday()" >&5 +$as_echo_n "checking number of arguments to gettimeofday()... " >&6; } +if ${ntp_cv_func_Xettimeofday_nargs+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + +int +main () +{ + + gettimeofday(0, 0); + settimeofday(0, 0); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_func_Xettimeofday_nargs=2 +else + ntp_cv_func_Xettimeofday_nargs=1 + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_Xettimeofday_nargs" >&5 +$as_echo "$ntp_cv_func_Xettimeofday_nargs" >&6; } +case "$ntp_cv_func_Xettimeofday_nargs" in + 1) + +$as_echo "#define SYSV_TIMEOFDAY 1" >>confdefs.h + +esac + +for ac_func in settimeofday +do : + ac_fn_c_check_func "$LINENO" "settimeofday" "ac_cv_func_settimeofday" +if test "x$ac_cv_func_settimeofday" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SETTIMEOFDAY 1 +_ACEOF + +else + + case "$host" in + *-*-mpeix*) ac_cv_func_settimeofday=yes + esac + +fi +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we'll use clock_settime or settimeofday or stime" >&5 +$as_echo_n "checking if we'll use clock_settime or settimeofday or stime... " >&6; } +ntp_warning='GRONK' +ans=none +case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in + yes*) + ntp_warning='' + ans='clock_settime()' + ;; + noyes*) + ntp_warning='But clock_settime() would be better (if we had it)' + ans='settimeofday()' + ;; + nonoyes) + ntp_warning='Which is the worst of the three' + ans='stime()' + ;; + *) + case "$build" in + $host) + ntp_warning='Which leaves us with nothing to use!' + esac +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5 +$as_echo "$ans" >&6; } +case "$ntp_warning" in + '') + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** $ntp_warning ***" >&5 +$as_echo "$as_me: WARNING: *** $ntp_warning ***" >&2;} + ;; +esac + + +LDADD_LIBNTP="$LDADD_LIBNTP $LIBS" +LIBS=$__LIBS +{ __LIBS=; unset __LIBS;} + + + +# Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then : + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_shared=no +fi + + + + + + + + + +case `pwd` in + *\ * | *\ *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 +$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; +esac + + + +macro_version='2.4.2' +macro_revision='1.3337' + + + + + + + + + + + + + +ltmain="$ac_aux_dir/ltmain.sh" + +# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\(["`$\\]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 +$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } +if ${lt_cv_path_NM+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS="$lt_save_ifs" + done + : ${lt_cv_path_NM=no} +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +$as_echo "$lt_cv_path_NM" >&6; } +if test "$lt_cv_path_NM" != "no"; then + NM="$lt_cv_path_NM" +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + if test -n "$ac_tool_prefix"; then + for ac_prog in dumpbin "link -dump" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DUMPBIN"; then + ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DUMPBIN=$ac_cv_prog_DUMPBIN +if test -n "$DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +$as_echo "$DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DUMPBIN" && break + done +fi +if test -z "$DUMPBIN"; then + ac_ct_DUMPBIN=$DUMPBIN + for ac_prog in dumpbin "link -dump" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DUMPBIN"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN +if test -n "$ac_ct_DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +$as_echo "$ac_ct_DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_DUMPBIN" && break +done + + if test "x$ac_ct_DUMPBIN" = x; then + DUMPBIN=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DUMPBIN=$ac_ct_DUMPBIN + fi +fi + + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi + + if test "$DUMPBIN" != ":"; then + NM="$DUMPBIN" + fi +fi +test -z "$NM" && NM=nm + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +$as_echo_n "checking the name lister ($NM) interface... " >&6; } +if ${lt_cv_nm_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: output\"" >&5) + cat conftest.out >&5 + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +$as_echo "$lt_cv_nm_interface" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi + +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if ${lt_cv_sys_max_cmd_len+:} false; then : + $as_echo_n "(cached) " >&6 +else + i=0 + teststring="ABCD" + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8 ; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac + +fi + +if test -n $lt_cv_sys_max_cmd_len ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } +fi +max_cmd_len=$lt_cv_sys_max_cmd_len + + + + + + +: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 +$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } +# Try some XSI features +xsi_shell=no +( _lt_dummy="a/b/c" + test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ + = c,a/b,b/c, \ + && eval 'test $(( 1 + 1 )) -eq 2 \ + && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ + && xsi_shell=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 +$as_echo "$xsi_shell" >&6; } + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 +$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } +lt_shell_append=no +( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ + >/dev/null 2>&1 \ + && lt_shell_append=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 +$as_echo "$lt_shell_append" >&6; } + + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi + + + + + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; } +if ${lt_cv_to_host_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac + +fi + +to_host_file_cmd=$lt_cv_to_host_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +$as_echo "$lt_cv_to_host_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } +if ${lt_cv_to_tool_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + #assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac + +fi + +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +$as_echo "$lt_cv_to_tool_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if ${lt_cv_ld_reload_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; + darwin*) + if test "$GCC" = yes; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi + +test -z "$OBJDUMP" && OBJDUMP=objdump + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if ${lt_cv_deplibs_check_method+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# `unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# which responds to the $file_magic_cmd with a given extended regex. +# If you have `file' or equivalent on your system and you're not sure +# whether `pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[4-9]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. + if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[3-9]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + + + + + + + + + + + + + + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" +fi + +test -z "$DLLTOOL" && DLLTOOL=dlltool + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; } +if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd="$ECHO" + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + + + + + + + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_AR" && break +done + + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi + +: ${AR=ar} +: ${AR_FLAGS=cru} + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +$as_echo_n "checking for archiver @FILE support... " >&6; } +if ${lt_cv_ar_at_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ar_at_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +$as_echo "$lt_cv_ar_at_file" >&6; } + +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +test -z "$STRIP" && STRIP=: + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB + fi +else + RANLIB="$ac_cv_prog_RANLIB" +fi + +test -z "$RANLIB" && RANLIB=: + + + + + + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + +# Check for command to grab the raw symbol name followed by C symbol from nm. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } +if ${lt_cv_sys_global_symbol_pipe+:} false; then : + $as_echo_n "(cached) " >&6 +else + +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[BCDEGRST]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([_A-Za-z][_A-Za-z0-9]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[BCDT]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[ABCDGISTW]' + ;; +hpux*) + if test "$host_cpu" = ia64; then + symcode='[ABCDEGRST]' + fi + ;; +irix* | nonstopux*) + symcode='[BCDEGRST]' + ;; +osf*) + symcode='[BCDEGQRST]' + ;; +solaris*) + symcode='[BDRT]' + ;; +sco3.2v5*) + symcode='[DT]' + ;; +sysv4.2uw2*) + symcode='[DT]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[ABDT]' + ;; +sysv4) + symcode='[DFNSTU]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function + # and D for any global variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK '"\ +" {last_section=section; section=\$ 3};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ +" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ +" s[1]~/^[@?]/{print s[1], s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Now try to grab the symbols. + nlist=conftest.nm + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 + (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&5 + fi + else + echo "cannot find nm_test_var in $nlist" >&5 + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "$progname: failed program was:" >&5 + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done + +fi + +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +$as_echo "failed" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; } +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +$as_echo_n "checking for sysroot... " >&6; } + +# Check whether --with-sysroot was given. +if test "${with_sysroot+set}" = set; then : + withval=$with_sysroot; +else + with_sysroot=no +fi + + +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 +$as_echo "${with_sysroot}" >&6; } + as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 + ;; +esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +$as_echo "${lt_sysroot:-no}" >&6; } + + + + + +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; +fi + +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out which ABI we are using. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_i386" + ;; + ppc64-*linux*|powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + ppc*-*linux*|powerpc*-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if ${lt_cv_cc_needs_belf+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_cc_needs_belf=yes +else + lt_cv_cc_needs_belf=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +sparc*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) LD="${LD-ld} -m elf64_sparc" ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks="$enable_libtool_lock" + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. +set dummy ${ac_tool_prefix}mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$MANIFEST_TOOL"; then + ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL +if test -n "$MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +$as_echo "$MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_MANIFEST_TOOL"; then + ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_MANIFEST_TOOL"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL +if test -n "$ac_ct_MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_MANIFEST_TOOL" = x; then + MANIFEST_TOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL + fi +else + MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" +fi + +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if ${lt_cv_path_mainfest_tool+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&5 + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 +$as_echo "$lt_cv_path_mainfest_tool" >&6; } +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi + + + + + + + case $host_os in + rhapsody* | darwin*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. +set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DSYMUTIL"; then + ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DSYMUTIL"; then + ac_ct_DSYMUTIL=$DSYMUTIL + # Extract the first word of "dsymutil", so it can be a program name with args. +set dummy dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DSYMUTIL"; then + ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL +if test -n "$ac_ct_DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DSYMUTIL" = x; then + DSYMUTIL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DSYMUTIL=$ac_ct_DSYMUTIL + fi +else + DSYMUTIL="$ac_cv_prog_DSYMUTIL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. +set dummy ${ac_tool_prefix}nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NMEDIT"; then + ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +NMEDIT=$ac_cv_prog_NMEDIT +if test -n "$NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_NMEDIT"; then + ac_ct_NMEDIT=$NMEDIT + # Extract the first word of "nmedit", so it can be a program name with args. +set dummy nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_NMEDIT"; then + ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_NMEDIT="nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT +if test -n "$ac_ct_NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 +$as_echo "$ac_ct_NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_NMEDIT" = x; then + NMEDIT=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + NMEDIT=$ac_ct_NMEDIT + fi +else + NMEDIT="$ac_cv_prog_NMEDIT" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. +set dummy ${ac_tool_prefix}lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$LIPO"; then + ac_cv_prog_LIPO="$LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_LIPO="${ac_tool_prefix}lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +LIPO=$ac_cv_prog_LIPO +if test -n "$LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 +$as_echo "$LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_LIPO"; then + ac_ct_LIPO=$LIPO + # Extract the first word of "lipo", so it can be a program name with args. +set dummy lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_LIPO"; then + ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_LIPO="lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO +if test -n "$ac_ct_LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 +$as_echo "$ac_ct_LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_LIPO" = x; then + LIPO=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + LIPO=$ac_ct_LIPO + fi +else + LIPO="$ac_cv_prog_LIPO" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL"; then + ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL="${ac_tool_prefix}otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL=$ac_cv_prog_OTOOL +if test -n "$OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 +$as_echo "$OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL"; then + ac_ct_OTOOL=$OTOOL + # Extract the first word of "otool", so it can be a program name with args. +set dummy otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL"; then + ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL="otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL +if test -n "$ac_ct_OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 +$as_echo "$ac_ct_OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL" = x; then + OTOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL=$ac_ct_OTOOL + fi +else + OTOOL="$ac_cv_prog_OTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL64"; then + ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL64=$ac_cv_prog_OTOOL64 +if test -n "$OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 +$as_echo "$OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL64"; then + ac_ct_OTOOL64=$OTOOL64 + # Extract the first word of "otool64", so it can be a program name with args. +set dummy otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL64"; then + ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL64="otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 +if test -n "$ac_ct_OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 +$as_echo "$ac_ct_OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL64" = x; then + OTOOL64=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL64=$ac_ct_OTOOL64 + fi +else + OTOOL64="$ac_cv_prog_OTOOL64" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 +$as_echo_n "checking for -single_module linker flag... " >&6; } +if ${lt_cv_apple_cc_single_mod+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_apple_cc_single_mod=no + if test -z "${LT_MULTI_MODULE}"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&5 + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 +$as_echo "$lt_cv_apple_cc_single_mod" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 +$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } +if ${lt_cv_ld_exported_symbols_list+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_ld_exported_symbols_list=yes +else + lt_cv_ld_exported_symbols_list=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 +$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +$as_echo_n "checking for -force_load linker flag... " >&6; } +if ${lt_cv_ld_force_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 + echo "$AR cru libconftest.a conftest.o" >&5 + $AR cru libconftest.a conftest.o 2>&5 + echo "$RANLIB libconftest.a" >&5 + $RANLIB libconftest.a 2>&5 + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&5 + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +$as_echo "$lt_cv_ld_force_load" >&6; } + case $host_os in + rhapsody* | darwin1.[012]) + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[91]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[012]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test "$lt_cv_apple_cc_single_mod" = "yes"; then + _lt_dar_single_mod='$single_module' + fi + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + fi + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac + +for ac_header in dlfcn.h +do : + ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +" +if test "x$ac_cv_header_dlfcn_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DLFCN_H 1 +_ACEOF + +fi + +done + + + + + +# Set options + + + + enable_dlopen=no + + + enable_win32_dll=no + + + + # Check whether --enable-static was given. +if test "${enable_static+set}" = set; then : + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_static=yes +fi + + + + + + + + + + +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then : + withval=$with_pic; pic_mode="$withval" +else + pic_mode=default +fi + + +test -z "$pic_mode" && pic_mode=default + + + + + + + + # Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then : + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_fast_install=yes +fi + + + + + + + + + + + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ltmain" + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' + + + + + + + + + + + + + + + + + + + + + + + + + + +test -z "$LN_S" && LN_S="ln -s" + + + + + + + + + + + + + + +if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if ${lt_cv_objdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir + + + + + +cat >>confdefs.h <<_ACEOF +#define LT_OBJDIR "$lt_cv_objdir/" +_ACEOF + + + + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld="$lt_cv_prog_gnu_ld" + +old_CC="$CC" +old_CFLAGS="$CFLAGS" + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` + + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/${ac_tool_prefix}file; then + lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + + +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/file; then + lt_cv_path_MAGIC_CMD="$ac_dir/file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + else + MAGIC_CMD=: + fi +fi + + fi + ;; +esac + +# Use C for the default configuration in the libtool script + +lt_save_CC="$CC" +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +objext=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + +lt_prog_compiler_no_builtin_flag= + +if test "$GCC" = yes; then + case $cc_basename in + nvcc*) + lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; + *) + lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" +else + : +fi + +fi + + + + + + + lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= + + + if test "$GCC" = yes; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + lt_prog_compiler_pic='-Xcompiler -fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='${wl}-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + # old Intel for x86_64 which still supported -KPIC. + ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='--shared' + lt_prog_compiler_static='--static' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-qpic' + lt_prog_compiler_static='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ F* | *Sun*Fortran*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + esac + ;; + esac + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi + +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +$as_echo "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if ${lt_cv_prog_compiler_pic_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } + +if test x"$lt_cv_prog_compiler_pic_works" = xyes; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi + +fi + + + + + + + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +$as_echo "$lt_cv_prog_compiler_static_works" >&6; } + +if test x"$lt_cv_prog_compiler_static_works" = xyes; then + : +else + lt_prog_compiler_static= +fi + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + runpath_var= + allow_undefined_flag= + always_export_symbols=no + archive_cmds= + archive_expsym_cmds= + compiler_needs_object=no + enable_shared_with_static_runtimes=no + export_dynamic_flag_spec= + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + hardcode_automatic=no + hardcode_direct=no + hardcode_direct_absolute=no + hardcode_libdir_flag_spec= + hardcode_libdir_flag_spec_ld= + hardcode_libdir_separator= + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + inherit_rpath=no + link_all_deplibs=unknown + module_cmds= + module_expsym_cmds= + old_archive_from_new_cmds= + old_archive_from_expsyms_cmds= + thread_safe_flag_spec= + whole_archive_flag_spec= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac + + ld_shlibs=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; + *\ \(GNU\ Binutils\)\ [3-9]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + export_dynamic_flag_spec='${wl}--export-all-symbols' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs=no + fi + ;; + + haiku*) + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs=yes + ;; + + interix[3-9]*) + hardcode_direct=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test "$host_os" = linux-dietlibc; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test "$tmp_diet" = no + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + whole_archive_flag_spec= + tmp_sharedflag='--shared' ;; + xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' + hardcode_libdir_flag_spec= + hardcode_libdir_flag_spec_ld='-rpath $libdir' + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + ld_shlibs=no + fi + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + ;; + + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + + if test "$ld_shlibs" = no; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; + + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds='' + hardcode_direct=yes + hardcode_direct_absolute=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + file_list_spec='${wl}-f,' + + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + export_dynamic_flag_spec='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' ${wl}-bernotok' + allow_undefined_flag=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + fi + archive_cmds_need_lc=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + always_export_symbols=yes + file_list_spec='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, )='true' + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + old_postinstall_cmds='chmod 644 $oldlib' + postlink_cmds='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_from_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' + enable_shared_with_static_runtimes=yes + ;; + esac + ;; + + darwin* | rhapsody*) + + + archive_cmds_need_lc=no + hardcode_direct=no + hardcode_automatic=yes + hardcode_shlibpath_var=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + whole_archive_flag_spec='' + fi + link_all_deplibs=yes + allow_undefined_flag="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + + else + ld_shlibs=no + fi + + ;; + + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + freebsd1*) + ld_shlibs=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + hpux9*) + if test "$GCC" = yes; then + archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='${wl}-E' + ;; + + hpux10*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_flag_spec_ld='+b $libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + fi + ;; + + hpux11*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +$as_echo_n "checking if $CC understands -b... " >&6; } +if ${lt_cv_prog_compiler__b+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler__b=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -b" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler__b=yes + fi + else + lt_cv_prog_compiler__b=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +$as_echo "$lt_cv_prog_compiler__b" >&6; } + +if test x"$lt_cv_prog_compiler__b" = xyes; then + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' +else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' +fi + + ;; + esac + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + *) + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if ${lt_cv_irix_exported_symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int foo (void) { return 0; } +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_irix_exported_symbol=yes +else + lt_cv_irix_exported_symbol=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +$as_echo "$lt_cv_irix_exported_symbol" >&6; } + if test "$lt_cv_irix_exported_symbol" = yes; then + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi + else + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + inherit_rpath=yes + link_all_deplibs=yes + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + newsos6) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + *nto* | *qnx*) + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct=yes + hardcode_shlibpath_var=no + hardcode_direct_absolute=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-R$libdir' + ;; + *) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + ;; + esac + fi + else + ld_shlibs=no + fi + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + archive_cmds_need_lc='no' + hardcode_libdir_separator=: + ;; + + solaris*) + no_undefined_flag=' -z defs' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='${wl}' + archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs=yes + ;; + + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag='${wl}-z,text' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag='${wl}-z,text' + allow_undefined_flag='${wl}-z,nodefs' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-R,$libdir' + hardcode_libdir_separator=':' + link_all_deplibs=yes + export_dynamic_flag_spec='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + *) + ld_shlibs=no + ;; + esac + + if test x$host_vendor = xsni; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + export_dynamic_flag_spec='${wl}-Blargedynsym' + ;; + esac + fi + fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test "$ld_shlibs" = no && can_build_shared=no + +with_gnu_ld=$with_gnu_ld + + + + + + + + + + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + pic_flag=$lt_prog_compiler_pic + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc=no + else + lt_cv_archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } + archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[lt_foo]++; } + if (lt_freq[lt_foo] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([A-Za-z]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd1*) + dynamic_linker=no + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; + +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || + test -n "$runpath_var" || + test "X$hardcode_automatic" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$hardcode_direct" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && + test "$hardcode_minus_L" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test "$hardcode_action" = relink || + test "$inherit_rpath" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if ${ac_cv_lib_dld_shl_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if ${ac_cv_lib_svld_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if ${ac_cv_lib_dld_dld_link+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = xyes; then : + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" +fi + + +fi + + +fi + + +fi + + +fi + + +fi + + ;; + esac + + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } + + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self_static+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi + + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi + + + + + + + + + + + + + + + + + +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + + + + + + + + + + + + + # Report which library types will actually be built + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[4-9]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } + + + + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +CC="$lt_save_CC" + + + + + + + + + + + + + + ac_config_commands="$ac_config_commands libtool" + + + + +# Only expand once: + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sntp will be built" >&5 +$as_echo_n "checking if sntp will be built... " >&6; } + +# Check whether --with-sntp was given. +if test "${with_sntp+set}" = set; then : + withval=$with_sntp; +else + with_sntp="${withsntp=yes}" + +fi + +case "$with_sntp" in + no) + SNTP= + ;; + *) + SNTP=sntp + ;; +esac + + if test -n "$SNTP"; then + BUILD_SNTP_TRUE= + BUILD_SNTP_FALSE='#' +else + BUILD_SNTP_TRUE='#' + BUILD_SNTP_FALSE= +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sntp" >&5 +$as_echo "$with_sntp" >&6; } + + + +case "$SNTP" in + '') + SNTP_DB= + SNTP_DL= + SNTP_DS= + ;; +esac + +### + +# NTP has (so far) been relying on leading-edge autogen. +# Therefore, by default: +# - use the version we ship with +# - do not install it +# - build a static copy (AC_DISABLE_SHARED - done earlier) +case "${enable_local_libopts+set}" in + set) ;; + *) enable_local_libopts=yes ;; +esac +case "${enable_libopts_install+set}" in + set) ;; + *) enable_libopts_install=no ;; +esac +enable_nls=no + + + ac_header_dirent=no +for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do + as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 +$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } +if eval \${$as_ac_Header+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include <$ac_hdr> + +int +main () +{ +if ((DIR *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_ac_Header=yes" +else + eval "$as_ac_Header=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$as_ac_Header + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 +_ACEOF + +ac_header_dirent=$ac_hdr; break +fi + +done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' dir; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break +fi +done +if ${ac_cv_search_opendir+:} false; then : + +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' x; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break +fi +done +if ${ac_cv_search_opendir+:} false; then : + +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +fi + + + # ================= + # AC_CHECK_HEADERS + # ================= + for ac_header in \ + sys/mman.h sys/param.h sys/poll.h sys/procset.h \ + sys/select.h sys/socket.h sys/stropts.h sys/time.h \ + sys/un.h sys/wait.h dlfcn.h errno.h \ + fcntl.h libgen.h libintl.h memory.h \ + netinet/in.h setjmp.h stdbool.h sysexits.h \ + unistd.h utime.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + for ac_header in stdarg.h varargs.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_arg_hdr=true;break +else + lo_have_arg_hdr=false +fi + +done + + + for ac_header in string.h strings.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_str_hdr=true;break +else + lo_have_str_hdr=false +fi + +done + + + for ac_header in limits.h sys/limits.h values.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_lim_hdr=true;break +else + lo_have_lim_hdr=false +fi + +done + + + for ac_header in inttypes.h stdint.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + lo_have_typ_hdr=true;break +else + lo_have_typ_hdr=false +fi + +done + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdnoreturn.h" >&5 +$as_echo_n "checking for working stdnoreturn.h... " >&6; } +if ${gl_cv_header_working_stdnoreturn_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include + /* Do not check for 'noreturn' after the return type. + C11 allows it, but it's rarely done that way + and circa-2012 bleeding-edge GCC rejects it when given + -Werror=old-style-declaration. */ + noreturn void foo1 (void) { exit (0); } + _Noreturn void foo2 (void) { exit (0); } + int testit (int argc, char **argv) { + if (argc & 1) + return 0; + (argv[0][0] ? foo1 : foo2) (); + } + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_header_working_stdnoreturn_h=yes +else + gl_cv_header_working_stdnoreturn_h=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdnoreturn_h" >&5 +$as_echo "$gl_cv_header_working_stdnoreturn_h" >&6; } + + if test $gl_cv_header_working_stdnoreturn_h = yes; then + STDNORETURN_H='' + else + STDNORETURN_H='stdnoreturn.h' + fi + + + if test -n "$STDNORETURN_H"; then + GL_GENERATE_STDNORETURN_H_TRUE= + GL_GENERATE_STDNORETURN_H_FALSE='#' +else + GL_GENERATE_STDNORETURN_H_TRUE='#' + GL_GENERATE_STDNORETURN_H_FALSE= +fi + + + + # ---------------------------------------------------------------------- + # check for various programs used during the build. + # On OS/X, "wchar.h" needs "runetype.h" to work properly. + # ---------------------------------------------------------------------- + for ac_header in runetype.h wchar.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + # Check whether --enable-nls was given. +if test "${enable_nls+set}" = set; then : + enableval=$enable_nls; +fi + + if test "x$enable_nls" != "xno" && \ + test "X${ac_cv_header_libintl_h}" = Xyes; then : + + +$as_echo "#define ENABLE_NLS 1" >>confdefs.h + +fi + + # -------------------------------------------- + # Verify certain entries from AC_CHECK_HEADERS + # -------------------------------------------- + ${lo_have_arg_hdr} || \ + as_fn_error $? "you must have stdarg.h or varargs.h on your system" "$LINENO" 5 + + ${lo_have_str_hdr} || \ + as_fn_error $? "you must have string.h or strings.h on your system" "$LINENO" 5 + + ${lo_have_lim_hdr} || \ + as_fn_error $? "you must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5 + + ${lo_have_typ_hdr} || \ + as_fn_error $? "you must have inttypes.h or stdint.h on your system" "$LINENO" 5 + + for f in sys_types sys_param sys_stat string errno stdlib memory setjmp + do eval as_ac_var=\${ac_cv_header_${f}_h} + test "X${as_ac_var}" = Xyes || { + as_fn_error $? "you must have ${f}.h on your system" "$LINENO" 5 + } + done + test "X${ac_cv_header_inttypes_h-no}" = Xyes || \ + echo '#include ' > inttypes.h + + # ---------------------------------------------------------------------- + # Checks for typedefs + # ---------------------------------------------------------------------- + ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default" +if test "x$ac_cv_type_wchar_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WCHAR_T 1 +_ACEOF + + +fi + + ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" " + $ac_includes_default + #if HAVE_RUNETYPE_H + # include + #endif + #if HAVE_WCHAR_H + # include + #endif + +" +if test "x$ac_cv_type_wint_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_WINT_T 1 +_ACEOF + + +fi + + ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default" +if test "x$ac_cv_type_int8_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT8_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default" +if test "x$ac_cv_type_uint8_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT8_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" +if test "x$ac_cv_type_int16_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT16_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default" +if test "x$ac_cv_type_uint16_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT16_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" +if test "x$ac_cv_type_int32_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INT32_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" +if test "x$ac_cv_type_uint32_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT32_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" +if test "x$ac_cv_type_intptr_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_INTPTR_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" +if test "x$ac_cv_type_uintptr_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default" +if test "x$ac_cv_type_uint_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PID_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SIZE_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" +if test "x$ac_cv_type_ptrdiff_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_PTRDIFF_T 1 +_ACEOF + + +fi + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5 +$as_echo_n "checking size of char *... " >&6; } +if ${ac_cv_sizeof_char_p+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_char_p" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (char *) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_char_p=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5 +$as_echo "$ac_cv_sizeof_char_p" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_CHAR_P $ac_cv_sizeof_char_p +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if ${ac_cv_sizeof_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (int) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_int=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if ${ac_cv_sizeof_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 +$as_echo_n "checking size of short... " >&6; } +if ${ac_cv_sizeof_short+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_short" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (short) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_short=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 +$as_echo "$ac_cv_sizeof_short" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +_ACEOF + + + + # ------------ + # AC_CHECK_LIB + # ------------ + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5 +$as_echo_n "checking for pathfind in -lgen... " >&6; } +if ${ac_cv_lib_gen_pathfind+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lgen $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pathfind (); +int +main () +{ +return pathfind (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_gen_pathfind=yes +else + ac_cv_lib_gen_pathfind=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5 +$as_echo "$ac_cv_lib_gen_pathfind" >&6; } +if test "x$ac_cv_lib_gen_pathfind" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBGEN 1 +_ACEOF + + LIBS="-lgen $LIBS" + +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettext in -lintl" >&5 +$as_echo_n "checking for gettext in -lintl... " >&6; } +if ${ac_cv_lib_intl_gettext+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lintl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char gettext (); +int +main () +{ +return gettext (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_intl_gettext=yes +else + ac_cv_lib_intl_gettext=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_gettext" >&5 +$as_echo "$ac_cv_lib_intl_gettext" >&6; } +if test "x$ac_cv_lib_intl_gettext" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBINTL 1 +_ACEOF + + LIBS="-lintl $LIBS" + +fi + + for ac_func in vprintf +do : + ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" +if test "x$ac_cv_func_vprintf" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VPRINTF 1 +_ACEOF + +ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" +if test "x$ac_cv_func__doprnt" = xyes; then : + +$as_echo "#define HAVE_DOPRNT 1" >>confdefs.h + +fi + +fi +done + + + for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if ${ac_cv_func_fork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if ${ac_cv_func_vfork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } + +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi + +if test "x$ac_cv_func_vfork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h + +fi +if test "x$ac_cv_func_fork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h + +fi + + for ac_func in mmap canonicalize_file_name snprintf strdup strchr \ + strrchr strsignal fchmod fstat chmod +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + + while : + do + POSIX_SHELL=`which bash` + test -x "$POSIX_SHELL" && break + POSIX_SHELL=`which dash` + test -x "$POSIX_SHELL" && break + POSIX_SHELL=/usr/xpg4/bin/sh + test -x "$POSIX_SHELL" && break + POSIX_SHELL=`/bin/sh -c ' + exec 2>/dev/null + if ! true ; then exit 1 ; fi + echo /bin/sh'` + test -x "$POSIX_SHELL" && break + as_fn_error $? "cannot locate a working POSIX shell" "$LINENO" 5 + done + +cat >>confdefs.h <<_ACEOF +#define POSIX_SHELL "${POSIX_SHELL}" +_ACEOF + + + + + + LIBOPTS_BUILD_BLOCKED='' + + + NEED_LIBOPTS_DIR='' + + # Check whether --enable-local-libopts was given. +if test "${enable_local_libopts+set}" = set; then : + enableval=$enable_local_libopts; + if test x$enableval = xyes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5 +$as_echo "$as_me: Using supplied libopts tearoff" >&6;} + LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' + NEED_LIBOPTS_DIR=true + LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' + fi +fi + + + # Check whether --enable-libopts-install was given. +if test "${enable_libopts_install+set}" = set; then : + enableval=$enable_libopts_install; +fi + + if test "X${enable_libopts_install}" = Xyes; then + INSTALL_LIBOPTS_TRUE= + INSTALL_LIBOPTS_FALSE='#' +else + INSTALL_LIBOPTS_TRUE='#' + INSTALL_LIBOPTS_FALSE= +fi + + + if test -z "${NEED_LIBOPTS_DIR}" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5 +$as_echo_n "checking whether autoopts-config can be found... " >&6; } + +# Check whether --with-autoopts-config was given. +if test "${with_autoopts_config+set}" = set; then : + withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5 +$as_echo_n "checking whether autoopts-config is specified... " >&6; } +if ${lo_cv_with_autoopts_config+:} false; then : + $as_echo_n "(cached) " >&6 +else + if autoopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=autoopts-config + elif libopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=libopts-config + else lo_cv_with_autoopts_config=no ; fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5 +$as_echo "$lo_cv_with_autoopts_config" >&6; } + +fi + # end of AC_ARG_WITH + + if ${lo_cv_test_autoopts+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test -z "${lo_cv_with_autoopts_config}" \ + -o X"${lo_cv_with_autoopts_config}" = Xno + then + if autoopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=autoopts-config + elif libopts-config --help 2>/dev/null 1>&2 + then lo_cv_with_autoopts_config=libopts-config + else lo_cv_with_autoopts_config=false ; fi + fi + lo_cv_test_autoopts=` + ${lo_cv_with_autoopts_config} --libs` 2> /dev/null + if test $? -ne 0 -o -z "${lo_cv_test_autoopts}" + then lo_cv_test_autoopts=no ; fi + +fi + # end of CACHE_VAL + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5 +$as_echo "${lo_cv_test_autoopts}" >&6; } + + if test "X${lo_cv_test_autoopts}" != Xno + then + LIBOPTS_LDADD="${lo_cv_test_autoopts}" + LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`" + else + LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la' + LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts' + NEED_LIBOPTS_DIR=true + fi + fi # end of if test -z "${NEED_LIBOPTS_DIR}" + if test -n "${LIBOPTS_BUILD_BLOCKED}" ; then + NEED_LIBOPTS_DIR='' + fi + if test -n "${NEED_LIBOPTS_DIR}"; then + NEED_LIBOPTS_TRUE= + NEED_LIBOPTS_FALSE='#' +else + NEED_LIBOPTS_TRUE='#' + NEED_LIBOPTS_FALSE= +fi + + + + LIBOPTS_DIR=libopts + + +# end of AC_DEFUN of LIBOPTS_CHECK_COMMON + + + if test -z "$NEED_LIBOPTS_TRUE"; then : + + + + # Check to see if a reg expr header is specified. + + +# Check whether --with-regex-header was given. +if test "${with_regex_header+set}" = set; then : + withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5 +$as_echo_n "checking whether a reg expr header is specified... " >&6; } +if ${libopts_cv_with_regex_header+:} false; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_with_regex_header=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5 +$as_echo "$libopts_cv_with_regex_header" >&6; } + +fi + # end of AC_ARG_WITH + if test "X${libopts_cv_with_regex_header}" != Xno + then + cat >>confdefs.h <<_ACEOF +#define REGEX_HEADER <${libopts_cv_with_regex_header}> +_ACEOF + + else + +$as_echo "#define REGEX_HEADER " >>confdefs.h + + fi + + + + # Check to see if a working libregex can be found. + + +# Check whether --with-libregex was given. +if test "${with_libregex+set}" = set; then : + withval=$with_libregex; libopts_cv_with_libregex_root=${with_libregex} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex was specified" >&5 +$as_echo_n "checking whether with-libregex was specified... " >&6; } +if ${libopts_cv_with_libregex_root+:} false; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_with_libregex_root=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_root" >&5 +$as_echo "$libopts_cv_with_libregex_root" >&6; } + +fi + # end of AC_ARG_WITH libregex + + if test "${with_libregex+set}" = set && \ + test "X${withval}" = Xno + then ## disabled by request + libopts_cv_with_libregex_root=no + libopts_cv_with_libregex_cflags=no + libopts_cv_with_libregex_libs=no + else + + +# Check whether --with-libregex-cflags was given. +if test "${with_libregex_cflags+set}" = set; then : + withval=$with_libregex_cflags; libopts_cv_with_libregex_cflags=${with_libregex_cflags} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-cflags was specified" >&5 +$as_echo_n "checking whether with-libregex-cflags was specified... " >&6; } +if ${libopts_cv_with_libregex_cflags+:} false; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_with_libregex_cflags=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_cflags" >&5 +$as_echo "$libopts_cv_with_libregex_cflags" >&6; } + +fi + # end of AC_ARG_WITH libregex-cflags + + +# Check whether --with-libregex-libs was given. +if test "${with_libregex_libs+set}" = set; then : + withval=$with_libregex_libs; libopts_cv_with_libregex_libs=${with_libregex_libs} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-libs was specified" >&5 +$as_echo_n "checking whether with-libregex-libs was specified... " >&6; } +if ${libopts_cv_with_libregex_libs+:} false; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_with_libregex_libs=no +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_libs" >&5 +$as_echo "$libopts_cv_with_libregex_libs" >&6; } + +fi + # end of AC_ARG_WITH libregex-libs + + case "X${libopts_cv_with_libregex_cflags}" in + Xyes|Xno|X ) + case "X${libopts_cv_with_libregex_root}" in + Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;; + * ) libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;; + esac + esac + case "X${libopts_cv_with_libregex_libs}" in + Xyes|Xno|X ) + case "X${libopts_cv_with_libregex_root}" in + Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;; + * ) libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex" ;; + esac + esac + libopts_save_CPPFLAGS="${CPPFLAGS}" + libopts_save_LIBS="${LIBS}" + case "X${libopts_cv_with_libregex_cflags}" in + Xyes|Xno|X ) + libopts_cv_with_libregex_cflags="" ;; + * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;; + esac + case "X${libopts_cv_with_libregex_libs}" in + Xyes|Xno|X ) + libopts_cv_with_libregex_libs="" ;; + * ) + LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;; + esac + LIBREGEX_CFLAGS="" + LIBREGEX_LIBS="" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libregex functions properly" >&5 +$as_echo_n "checking whether libregex functions properly... " >&6; } + if ${libopts_cv_with_libregex+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + libopts_cv_with_libregex=no +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include REGEX_HEADER +static regex_t re; +void comp_re(char const * pzPat) { + int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE ); + if (res == 0) return; + exit( res ); } +int main() { + regmatch_t m[2]; + comp_re( "^.*\$" ); + comp_re( "()|no.*" ); + comp_re( "." ); + if (regexec( &re, "X", 2, m, 0 ) != 0) return 1; + if ((m[0].rm_so != 0) || (m[0].rm_eo != 1)) { + fputs( "error: regex -->.<-- did not match\n", stderr ); + return 1; + } + return 0; } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_with_libregex=yes +else + libopts_cv_with_libregex=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of AC_RUN_IFELSE + +fi + # end of AC_CACHE_VAL for libopts_cv_with_libregex + fi ## disabled by request + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_with_libregex}" >&5 +$as_echo "${libopts_cv_with_libregex}" >&6; } + if test "X${libopts_cv_with_libregex}" != Xno + then + +$as_echo "#define WITH_LIBREGEX 1" >>confdefs.h + + else + CPPFLAGS="${libopts_save_CPPFLAGS}" + LIBS="${libopts_save_LIBS}" + libopts_cv_with_libregex_root=no +libopts_cv_with_libregex_cflags=no +libopts_cv_with_libregex_libs=no +libopts_cv_with_libregex=no + fi + + + + # Check to see if pathfind(3) works. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pathfind(3) works" >&5 +$as_echo_n "checking whether pathfind(3) works... " >&6; } + if ${libopts_cv_run_pathfind+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + libopts_cv_run_pathfind=no + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +int main (int argc, char ** argv) { + char * pz = pathfind( getenv( "PATH" ), "sh", "x" ); + return (pz == 0) ? 1 : 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_pathfind=yes +else + libopts_cv_run_pathfind=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of RUN_IFELSE + +fi + # end of AC_CACHE_VAL for libopts_cv_run_pathfind + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_pathfind}" >&5 +$as_echo "${libopts_cv_run_pathfind}" >&6; } + if test "X${libopts_cv_run_pathfind}" != Xno + then + +$as_echo "#define HAVE_PATHFIND 1" >>confdefs.h + + fi + + + + # Check to see if /dev/zero is readable device. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/zero is readable device" >&5 +$as_echo_n "checking whether /dev/zero is readable device... " >&6; } + if ${libopts_cv_test_dev_zero+:} false; then : + $as_echo_n "(cached) " >&6 +else + + libopts_cv_test_dev_zero=`exec 2> /dev/null +dzero=\`ls -lL /dev/zero | egrep ^c......r\` +test -z "${dzero}" && exit 1 +echo ${dzero}` + if test $? -ne 0 || test -z "$libopts_cv_test_dev_zero" + then libopts_cv_test_dev_zero=no + fi + +fi + # end of CACHE_VAL of libopts_cv_test_dev_zero + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_test_dev_zero}" >&5 +$as_echo "${libopts_cv_test_dev_zero}" >&6; } + if test "X${libopts_cv_test_dev_zero}" != Xno + then + +$as_echo "#define HAVE_DEV_ZERO 1" >>confdefs.h + + fi + + + + # Check to see if we have a functional realpath(3C). + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have a functional realpath(3C)" >&5 +$as_echo_n "checking whether we have a functional realpath(3C)... " >&6; } + if ${libopts_cv_run_realpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + libopts_cv_run_realpath=no + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +int main (int argc, char ** argv) { +#ifndef PATH_MAX +choke me!! +#else + char zPath[PATH_MAX+1]; +#endif + char *pz = realpath(argv[0], zPath); + return (pz == zPath) ? 0 : 1; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_realpath=yes +else + libopts_cv_run_realpath=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of RUN_IFELSE + +fi + # end of AC_CACHE_VAL for libopts_cv_run_realpath + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_realpath}" >&5 +$as_echo "${libopts_cv_run_realpath}" >&6; } + if test "X${libopts_cv_run_realpath}" != Xno + then + +$as_echo "#define HAVE_REALPATH 1" >>confdefs.h + + fi + + + + # Check to see if strftime() works. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strftime() works" >&5 +$as_echo_n "checking whether strftime() works... " >&6; } + if ${libopts_cv_run_strftime+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + libopts_cv_run_strftime=no + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +char t_buf[ 64 ]; +int main() { + static char const z[] = "Thursday Aug 28 240"; + struct tm tm; + tm.tm_sec = 36; /* seconds after the minute [0, 61] */ + tm.tm_min = 44; /* minutes after the hour [0, 59] */ + tm.tm_hour = 12; /* hour since midnight [0, 23] */ + tm.tm_mday = 28; /* day of the month [1, 31] */ + tm.tm_mon = 7; /* months since January [0, 11] */ + tm.tm_year = 86; /* years since 1900 */ + tm.tm_wday = 4; /* days since Sunday [0, 6] */ + tm.tm_yday = 239; /* days since January 1 [0, 365] */ + tm.tm_isdst = 1; /* flag for daylight savings time */ + strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm ); + return (strcmp( t_buf, z ) != 0); } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_strftime=yes +else + libopts_cv_run_strftime=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of RUN_IFELSE + +fi + # end of AC_CACHE_VAL for libopts_cv_run_strftime + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_strftime}" >&5 +$as_echo "${libopts_cv_run_strftime}" >&6; } + if test "X${libopts_cv_run_strftime}" != Xno + then + +$as_echo "#define HAVE_STRFTIME 1" >>confdefs.h + + fi + + + + # Check to see if fopen accepts "b" mode. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"b\" mode" >&5 +$as_echo_n "checking whether fopen accepts \"b\" mode... " >&6; } + if ${libopts_cv_run_fopen_binary+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + libopts_cv_run_fopen_binary=no + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int main (int argc, char ** argv) { +FILE * fp = fopen("conftest.$ac_ext", "rb"); +return (fp == NULL) ? 1 : fclose(fp); } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_fopen_binary=yes +else + libopts_cv_run_fopen_binary=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of RUN_IFELSE + +fi + # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_binary}" >&5 +$as_echo "${libopts_cv_run_fopen_binary}" >&6; } + if test "X${libopts_cv_run_fopen_binary}" != Xno + then + +$as_echo "#define FOPEN_BINARY_FLAG \"b\"" >>confdefs.h + + else + +$as_echo "#define FOPEN_BINARY_FLAG \"\"" >>confdefs.h + + fi + + + + # Check to see if fopen accepts "t" mode. + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"t\" mode" >&5 +$as_echo_n "checking whether fopen accepts \"t\" mode... " >&6; } + if ${libopts_cv_run_fopen_text+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + libopts_cv_run_fopen_text=no + +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int main (int argc, char ** argv) { +FILE * fp = fopen("conftest.$ac_ext", "rt"); +return (fp == NULL) ? 1 : fclose(fp); } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + libopts_cv_run_fopen_text=yes +else + libopts_cv_run_fopen_text=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + # end of RUN_IFELSE + +fi + # end of AC_CACHE_VAL for libopts_cv_run_fopen_text + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_text}" >&5 +$as_echo "${libopts_cv_run_fopen_text}" >&6; } + if test "X${libopts_cv_run_fopen_text}" != Xno + then + +$as_echo "#define FOPEN_TEXT_FLAG \"t\"" >>confdefs.h + + else + +$as_echo "#define FOPEN_TEXT_FLAG \"\"" >>confdefs.h + + fi + + + + # Check to see if not wanting optional option args. + + # Check whether --enable-optional-args was given. +if test "${enable_optional_args+set}" = set; then : + enableval=$enable_optional_args; libopts_cv_enable_optional_args=${enable_optional_args} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether not wanting optional option args" >&5 +$as_echo_n "checking whether not wanting optional option args... " >&6; } +if ${libopts_cv_enable_optional_args+:} false; then : + $as_echo_n "(cached) " >&6 +else + libopts_cv_enable_optional_args=yes +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_enable_optional_args" >&5 +$as_echo "$libopts_cv_enable_optional_args" >&6; } + +fi + # end of AC_ARG_ENABLE + if test "X${libopts_cv_enable_optional_args}" = Xno + then + +$as_echo "#define NO_OPTIONAL_OPT_ARGS 1" >>confdefs.h + + fi + + + + + + fi + ac_config_files="$ac_config_files libopts/Makefile" + + # end of AC_DEFUN of LIBOPTS_CHECK + + +# From when we only used libevent for sntp: +#AM_COND_IF( +# [BUILD_SNTP], +# [NTP_LIBEVENT_CHECK], +# [NTP_LIBEVENT_CHECK_NOBUILD] +#) + + + +ntp_pkgconfig_min_version='0.15.0' +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PKG_CONFIG=$ac_cv_path_PKG_CONFIG +if test -n "$PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 +$as_echo "$PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_path_PKG_CONFIG"; then + ac_pt_PKG_CONFIG=$PKG_CONFIG + # Extract the first word of "pkg-config", so it can be a program name with args. +set dummy pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG +if test -n "$ac_pt_PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 +$as_echo "$ac_pt_PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_PKG_CONFIG" = x; then + PKG_CONFIG="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + PKG_CONFIG=$ac_pt_PKG_CONFIG + fi +else + PKG_CONFIG="$ac_cv_path_PKG_CONFIG" +fi + +{ ac_cv_path_PKG_CONFIG=; unset ac_cv_path_PKG_CONFIG;} +{ ac_cv_path_ac_pt_PKG_CONFIG=; unset ac_cv_path_ac_pt_PKG_CONFIG;} + +case "$PKG_CONFIG" in + /*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pkg-config is at least version $ntp_pkgconfig_min_version" >&5 +$as_echo_n "checking if pkg-config is at least version $ntp_pkgconfig_min_version... " >&6; } + if $PKG_CONFIG --atleast-pkgconfig-version $ntp_pkgconfig_min_version; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + PKG_CONFIG="" + fi + ;; +esac + + + + +# Check whether --enable-local-libevent was given. +if test "${enable_local_libevent+set}" = set; then : + enableval=$enable_local_libevent; ntp_use_local_libevent=$enableval +else + ntp_use_local_libevent=${ntp_use_local_libevent-detect} + +fi + + + + + + + + + + +ntp_libevent_min_version=2 +ntp_libevent_tearoff=libevent + + + + + +case "$ntp_use_local_libevent" in + yes) + ;; + *) # If we have (a good enough) pkg-config, see if it can find libevent + case "$PKG_CONFIG" in + /*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libevent $ntp_libevent_min_version or later is installed" >&5 +$as_echo_n "checking if libevent $ntp_libevent_min_version or later is installed... " >&6; } + if $PKG_CONFIG --atleast-version=$ntp_libevent_min_version libevent + then + ntp_use_local_libevent=no + { $as_echo "$as_me:${as_lineno-$LINENO}: Using the installed libevent" >&5 +$as_echo "$as_me: Using the installed libevent" >&6;} + CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads` + CPPFLAGS_LIBEVENT=`$PKG_CONFIG --cflags-only-I libevent` + # HMS: I hope the following is accurate. + # We don't need -levent, we only need -levent_core. + # While we could grab only the -L stuff, there *might* be + # other flags there we want. Originally we just removed -levent + # but then somebody decided to install -levent-2.0 + # LDADD_LIBEVENT=`$PKG_CONFIG --libs libevent | sed 's:-levent::'` + # So now we dance... + LDADD_LIBEVENT= + for i in `$PKG_CONFIG --libs libevent` + do + case "$i" in + -levent*) ;; + *) case "$LDADD_LIBEVENT" in + '') LDADD_LIBEVENT="$i" ;; + *) LDADD_LIBEVENT="$LDADD_LIBEVENT $i" ;; + esac + ;; + esac + done + case "$LIBISC_PTHREADS_NOTHREADS" in + pthreads) + LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_pthreads" + esac + LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_core" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + ntp_use_local_libevent=yes + # HMS: do we only need to do this if LIBISC_PTHREADS_NOTHREADS + # is "pthreads"? + CFLAGS_LIBEVENT=`$PKG_CONFIG --cflags libevent_pthreads` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + ntp_use_local_libevent=yes + ;; + esac + ;; +esac + +case "$ntp_use_local_libevent" in + yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: Using libevent tearoff" >&5 +$as_echo "$as_me: Using libevent tearoff" >&6;} + CPPFLAGS_LIBEVENT="-I\$(top_builddir)/$ntp_libevent_tearoff/include -I\$(top_srcdir)/$ntp_libevent_tearoff/include" + case "$LIBISC_PTHREADS_NOTHREADS" in + pthreads) + LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_pthreads.la \$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la" + ;; + *) + LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la" + esac +esac + + + if test "x$ntp_use_local_libevent" = "xyes"; then + BUILD_LIBEVENT_TRUE= + BUILD_LIBEVENT_FALSE='#' +else + BUILD_LIBEVENT_TRUE='#' + BUILD_LIBEVENT_FALSE= +fi + + + + +case "$ntp_libevent_tearoff" in + libevent) + ;; + *) + as_fn_error $? "ntp_libevent.m4 dir must be libevent, not $ntp_libevent_tearoff" "$LINENO" 5 + ;; +esac + +case "$ntp_use_local_libevent" in + yes) + ac_configure_args=" --disable-openssl${ac_configure_args}" + ac_configure_args=" --disable-shared${ac_configure_args}" + ac_configure_args=" --disable-libevent-regress${ac_configure_args}" + ac_configure_args=" --disable-libevent-install${ac_configure_args}" + ac_configure_args=" --enable-silent-rules${ac_configure_args}" + ac_configure_args=" --enable-function-sections${ac_configure_args}" + subdirs="$subdirs libevent" + + ;; + *) + NTP_FORCE_LIBEVENT_DIST=libevent + ;; +esac + + + +# Checks for libraries. + + +LIB_SYSLOG='' + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5 +$as_echo_n "checking for library containing openlog... " >&6; } +if ${ac_cv_search_openlog+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char openlog (); +int +main () +{ +return openlog (); + ; + return 0; +} +_ACEOF +for ac_lib in '' gen syslog; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_openlog=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_openlog+:} false; then : + break +fi +done +if ${ac_cv_search_openlog+:} false; then : + +else + ac_cv_search_openlog=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5 +$as_echo "$ac_cv_search_openlog" >&6; } +ac_res=$ac_cv_search_openlog +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + case "$ac_cv_search_openlog" in + 'none required') ;; + no) ;; + *) LIB_SYSLOG="$ac_cv_search_openlog $LIB_SYSLOG" ;; + esac + +fi + + +# Checks for header files. +for ac_header in netdb.h string.h strings.h syslog.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + +for ac_header in sysexits.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sysexits.h" "ac_cv_header_sysexits_h" "$ac_includes_default" +if test "x$ac_cv_header_sysexits_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYSEXITS_H 1 +_ACEOF + +else + + +$as_echo "#define EX_OK 0" >>confdefs.h + + +$as_echo "#define EX_SOFTWARE 70" >>confdefs.h + + +fi + +done + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for facilitynames in syslog.h" >&5 +$as_echo_n "checking for facilitynames in syslog.h... " >&6; } +if ${ac_cv_HAVE_SYSLOG_FACILITYNAMES+:} false; then : + $as_echo_n "(cached) " >&6 +else + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#define SYSLOG_NAMES +#include +#include + +int +main () +{ + void *fnames; fnames = facilitynames; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_HAVE_SYSLOG_FACILITYNAMES=yes +else + ac_cv_HAVE_SYSLOG_FACILITYNAMES=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&5 +$as_echo "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&6; } +case "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" in + yes) + +$as_echo "#define HAVE_SYSLOG_FACILITYNAMES 1" >>confdefs.h + + ;; + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No facilitynames in " >&5 +$as_echo "$as_me: WARNING: No facilitynames in " >&2;} + ;; + cross) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: facilitynames in - cross-compiling" >&5 +$as_echo "$as_me: WARNING: facilitynames in - cross-compiling" >&2;} + ;; +esac + + +# Checks for typedefs, structures, and compiler characteristics. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 +$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; } +if ${ac_cv_header_stdbool_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #ifndef bool + "error: bool is not defined" + #endif + #ifndef false + "error: false is not defined" + #endif + #if false + "error: false is not 0" + #endif + #ifndef true + "error: true is not defined" + #endif + #if true != 1 + "error: true is not 1" + #endif + #ifndef __bool_true_false_are_defined + "error: __bool_true_false_are_defined is not defined" + #endif + + struct s { _Bool s: 1; _Bool t; } s; + + char a[true == 1 ? 1 : -1]; + char b[false == 0 ? 1 : -1]; + char c[__bool_true_false_are_defined == 1 ? 1 : -1]; + char d[(bool) 0.5 == true ? 1 : -1]; + /* See body of main program for 'e'. */ + char f[(_Bool) 0.0 == false ? 1 : -1]; + char g[true]; + char h[sizeof (_Bool)]; + char i[sizeof s.t]; + enum { j = false, k = true, l = false * true, m = true * 256 }; + /* The following fails for + HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */ + _Bool n[m]; + char o[sizeof n == m * sizeof n[0] ? 1 : -1]; + char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1]; + /* Catch a bug in an HP-UX C compiler. See + http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html + http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html + */ + _Bool q = true; + _Bool *pq = &q; + +int +main () +{ + + bool e = &s; + *pq |= q; + *pq |= ! q; + /* Refer to every declared value, to avoid compiler optimizations. */ + return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l + + !m + !n + !o + !p + !q + !pq); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdbool_h=yes +else + ac_cv_header_stdbool_h=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 +$as_echo "$ac_cv_header_stdbool_h" >&6; } + ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" +if test "x$ac_cv_type__Bool" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE__BOOL 1 +_ACEOF + + +fi + + +if test $ac_cv_header_stdbool_h = yes; then + +$as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h + +fi + + + + + +VER_SUFFIX= + + + + +# Check whether --with-crypto was given. +if test "${with_crypto+set}" = set; then : + withval=$with_crypto; +fi + + +# Check whether --with-openssl-libdir was given. +if test "${with_openssl_libdir+set}" = set; then : + withval=$with_openssl_libdir; +fi + + +# Check whether --with-openssl-incdir was given. +if test "${with_openssl_incdir+set}" = set; then : + withval=$with_openssl_incdir; +fi + + +# Check whether --with-rpath was given. +if test "${with_rpath+set}" = set; then : + withval=$with_rpath; +fi + +ntp_openssl=no +ntp_openssl_from_pkg_config=no +with_crypto=${with_crypto:-openssl,libcrypto} +case "$with_crypto" in + yes) + with_crypto=openssl,libcrypto +esac +case "$with_crypto:${PKG_CONFIG:+notempty}:${with_openssl_libdir-notgiven}:${with_openssl_incdir-notgiven}" in + no:*) ;; + *:notempty:notgiven:notgiven) + for pkg in `echo $with_crypto | sed -e 's/,/ /'`; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config for $pkg" >&5 +$as_echo_n "checking pkg-config for $pkg... " >&6; } + if $PKG_CONFIG --exists $pkg ; then + CPPFLAGS_NTP="$CPPFLAGS_NTP `$PKG_CONFIG --cflags-only-I $pkg`" + CFLAGS_NTP="$CFLAGS_NTP `$PKG_CONFIG --cflags-only-other $pkg`" + LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-L $pkg`" + LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-l $pkg`" + LDFLAGS_NTP="$LDFLAGS_NTP `$PKG_CONFIG --libs-only-other $pkg`" + VER_SUFFIX=o + ntp_openssl=yes + ntp_openssl_from_pkg_config=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + + break + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + done +esac +case "$with_crypto:$ntp_openssl" in + no:*) ;; + *:no) + need_dash_r= + need_dash_Wlrpath= + case "${with_rpath-notgiven}" in + yes) + # Lame - what to do if we need -Wl... but not -R? + need_dash_r=1 + ;; + notgiven) + case "$host" in + *-*-linux*) + # This may really only be true for gcc + need_dash_Wlrpath=1 + ;; + *-*-netbsd*) + need_dash_r=1 + ;; + *-*-solaris*) + need_dash_r=1 + ;; + esac + ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5 +$as_echo_n "checking for openssl library directory... " >&6; } + with_openssl_libdir=${with_openssl_libdir-notgiven} + case "$with_openssl_libdir" in + notgiven) + case "$build" in + $host) + with_openssl_libdir=default + ;; + *) + with_openssl_libdir=no + ;; + esac + esac + case "$with_openssl_libdir" in + default) + # Look in: + with_openssl_libdir="/usr/lib /usr/lib/openssl /usr/sfw/lib" + with_openssl_libdir="$with_openssl_libdir /usr/local/lib" + with_openssl_libdir="$with_openssl_libdir /usr/local/ssl/lib /lib" + esac + case "$with_openssl_libdir" in + no) + ;; + *) # Look for libcrypto.a and libssl.a: + for i in $with_openssl_libdir no + do + case "$host" in + *-*-darwin*) + test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break + ;; + *) + test -f $i/libcrypto.so -a -f $i/libssl.so && break + test -f $i/libcrypto.a -a -f $i/libssl.a && break + ;; + esac + done + openssl_libdir=$i + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_libdir" >&5 +$as_echo "$openssl_libdir" >&6; } + case "$openssl_libdir" in + no) + openssl_libdir= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&5 +$as_echo "$as_me: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&2;} + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl include directory" >&5 +$as_echo_n "checking for openssl include directory... " >&6; } + with_openssl_incdir=${with_openssl_incdir-notgiven} + case "$with_openssl_incdir" in + notgiven) + # Look in: + with_openssl_incdir="/usr/include /usr/sfw/include" + with_openssl_incdir="$with_openssl_incdir /usr/local/include" + with_openssl_incdir="$with_openssl_incdir /usr/local/ssl/include" + esac + case "$with_openssl_incdir" in + no) + ;; + *) # look for openssl/evp.h: + for i in $with_openssl_incdir no + do + test -f $i/openssl/evp.h && break + done + openssl_incdir=$i + ;; + esac + { i=; unset i;} + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_incdir" >&5 +$as_echo "$openssl_incdir" >&6; } + case "$openssl_incdir" in + no) + openssl_incdir= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&5 +$as_echo "$as_me: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&2;} + esac + if test -z "$openssl_libdir" -o -z "$openssl_incdir" + then + ntp_openssl=no + else + ntp_openssl=yes + VER_SUFFIX=o + fi + case "$ntp_openssl" in + yes) + # We have OpenSSL inc/lib dirs - use them. + case "$openssl_incdir" in + /usr/include) + ;; + *) + CPPFLAGS_NTP="$CPPFLAGS_NTP -I$openssl_incdir" + ;; + esac + case "$openssl_libdir" in + /usr/lib) + ;; + *) + LDADD_NTP="$LDADD_NTP -L$openssl_libdir" + case "$need_dash_r" in + 1) + LDFLAGS_NTP="$LDFLAGS_NTP -R$openssl_libdir" + esac + case "$need_dash_Wlrpath" in + 1) + LDFLAGS_NTP="$LDFLAGS_NTP -Wl,-rpath,$openssl_libdir" + esac + ;; + esac + LDADD_NTP="$LDADD_NTP -lcrypto" + esac +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will use crypto" >&5 +$as_echo_n "checking if we will use crypto... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_openssl" >&5 +$as_echo "$ntp_openssl" >&6; } + +case "$ntp_openssl" in + yes) + +$as_echo "#define OPENSSL /**/" >>confdefs.h + + case "$VER_SUFFIX" in + *o*) ;; + *) as_fn_error $? "OPENSSL set but no 'o' in VER_SUFFIX!" "$LINENO" 5 ;; + esac + ;; +esac + +NTPO_SAVED_CPPFLAGS="$CPPFLAGS" +CPPFLAGS="$CPPFLAGS $CPPFLAGS_NTP" +NTPO_SAVED_LIBS="$LIBS" + +# +# check for linking with -lcrypto failure, and try -lcrypto -lz. +# Helps m68k-atari-mint +# +case "$ntp_openssl:$ntp_openssl_from_pkg_config" in + yes:no) + LIBS="$NTPO_SAVED_LIBS $LDADD_NTP" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto alone works" >&5 +$as_echo_n "checking if linking with -lcrypto alone works... " >&6; } +if ${ntp_cv_bare_lcrypto+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include "openssl/err.h" + #include "openssl/evp.h" + +int +main () +{ + + ERR_load_crypto_strings(); + OpenSSL_add_all_algorithms(); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_cv_bare_lcrypto=yes +else + ntp_cv_bare_lcrypto=no + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_bare_lcrypto" >&5 +$as_echo "$ntp_cv_bare_lcrypto" >&6; } + case "$ntp_cv_bare_lcrypto" in + no) + LIBS="$NTPO_SAVED_LIBS $LDADD_NTP -lz" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto -lz works" >&5 +$as_echo_n "checking if linking with -lcrypto -lz works... " >&6; } +if ${ntp_cv_lcrypto_lz+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include "openssl/err.h" + #include "openssl/evp.h" + +int +main () +{ + + ERR_load_crypto_strings(); + OpenSSL_add_all_algorithms(); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ntp_cv_lcrypto_lz=yes +else + ntp_cv_lcrypto_lz=no + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_lcrypto_lz" >&5 +$as_echo "$ntp_cv_lcrypto_lz" >&6; } + case "$ntp_cv_lcrypto_lz" in + yes) + LDADD_NTP="$LDADD_NTP -lz" + esac + esac +esac + +# +# Older OpenSSL headers have a number of callback prototypes inside +# other function prototypes which trigger copious warnings with gcc's +# -Wstrict-prototypes, which is included in -Wall. +# +# An example: +# +# int i2d_RSA_NET(const RSA *a, unsigned char **pp, +# int (*cb)(), int sgckey); +# ^^^^^^^^^^^ +# +# +# +openssl_triggers_warnings=unknown +NTPO_SAVED_CFLAGS="$CFLAGS" + +case "$ntp_openssl:$GCC" in + yes:yes) + CFLAGS="$CFLAGS -Werror" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ + + /* see if -Werror breaks gcc */ + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gcc_handles_Werror=yes +else + gcc_handles_Werror=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + case "$gcc_handles_Werror" in + no) + # if this gcc doesn't do -Werror go ahead and use + # -Wstrict-prototypes. + openssl_triggers_warnings=yes + ;; + yes) + CFLAGS="$CFLAGS -Wstrict-prototypes" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include "openssl/asn1_mac.h" + #include "openssl/bn.h" + #include "openssl/err.h" + #include "openssl/evp.h" + #include "openssl/pem.h" + #include "openssl/rand.h" + #include "openssl/x509v3.h" + +int +main () +{ + + /* empty body */ + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + openssl_triggers_warnings=no +else + openssl_triggers_warnings=yes + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + esac + case "$openssl_triggers_warnings" in + yes) + CFLAGS_NTP="$CFLAGS_NTP -Wno-strict-prototypes" + ;; + *) + CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes" + esac + ;; + no:yes) + # gcc without OpenSSL + CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes" +esac + +# Because we don't want -Werror for the EVP_MD_do_all_sorted check +CFLAGS="$NTPO_SAVED_CFLAGS" + +case "$ntp_openssl" in + yes) + LIBS="$NTPO_SAVED_LIBS $LDADD_NTP" + for ac_func in EVP_MD_do_all_sorted +do : + ac_fn_c_check_func "$LINENO" "EVP_MD_do_all_sorted" "ac_cv_func_EVP_MD_do_all_sorted" +if test "x$ac_cv_func_EVP_MD_do_all_sorted" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_EVP_MD_DO_ALL_SORTED 1 +_ACEOF + +fi +done + + ;; +esac + +CPPFLAGS="$NTPO_SAVED_CPPFLAGS" +LIBS="$NTPO_SAVED_LIBS" +{ NTPO_SAVED_CFLAGS=; unset NTPO_SAVED_CFLAGS;} +{ NTPO_SAVED_CPPFLAGS=; unset NTPO_SAVED_CPPFLAGS;} +{ NTPO_SAVED_LIBS=; unset NTPO_SAVED_LIBS;} +{ openssl_triggers_warnings=; unset openssl_triggers_warnings;} +{ ntp_openssl_from_pkg_config=; unset ntp_openssl_from_pkg_config;} + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5 +$as_echo_n "checking for struct sockaddr_storage... " >&6; } +if ${ntp_cv_sockaddr_storage+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + +int +main () +{ + + struct sockaddr_storage n; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_sockaddr_storage=yes +else + ntp_cv_sockaddr_storage=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_sockaddr_storage" >&5 +$as_echo "$ntp_cv_sockaddr_storage" >&6; } +case "$ntp_cv_sockaddr_storage" in + yes) + +$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_family" >&5 +$as_echo_n "checking for sockaddr_storage.__ss_family... " >&6; } +if ${ntp_cv_have___ss_family+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + #ifdef HAVE_NETINET_IN_H + # include + #endif + +int +main () +{ + + struct sockaddr_storage s; + s.__ss_family = 1; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_have___ss_family=yes +else + ntp_cv_have___ss_family=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_family" >&5 +$as_echo "$ntp_cv_have___ss_family" >&6; } + case "$ntp_cv_have___ss_family" in + yes) + +$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h + + esac + +esac + + +# +# Look for in_port_t. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5 +$as_echo_n "checking for in_port_t... " >&6; } +if ${isc_cv_have_in_port_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + in_port_t port = 25; + return (0); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_have_in_port_t=yes +else + isc_cv_have_in_port_t=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in_port_t" >&5 +$as_echo "$isc_cv_have_in_port_t" >&6; } +case "$isc_cv_have_in_port_t" in + no) + +$as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking type of socklen arg for getsockname()" >&5 +$as_echo_n "checking type of socklen arg for getsockname()... " >&6; } +if ${ntp_cv_getsockname_socklen_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + + getsockname_socklen_type_found=no + for getsockname_arg2 in 'struct sockaddr *' 'void *'; do + for ntp_cv_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_SYS_TYPES_H + # include + #endif + #ifdef HAVE_SYS_SOCKET_H + # include + #endif + +int +main () +{ + + extern + getsockname(int, $getsockname_arg2, + $ntp_cv_getsockname_socklen_type *); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + getsockname_socklen_type_found=yes ; break 2 +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done + done + case "$getsockname_socklen_type_found" in + no) + ntp_cv_getsockname_socklen_type='socklen_t' + esac + { getsockname_arg2=; unset getsockname_arg2;} + { getsockname_socklen_type_found=; unset getsockname_socklen_type_found;} + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_getsockname_socklen_type" >&5 +$as_echo "$ntp_cv_getsockname_socklen_type" >&6; } + +cat >>confdefs.h <<_ACEOF +#define GETSOCKNAME_SOCKLEN_TYPE $ntp_cv_getsockname_socklen_type +_ACEOF + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5 +$as_echo_n "checking struct sockaddr for sa_len... " >&6; } +if ${isc_cv_platform_havesalen+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + extern struct sockaddr *ps; + return ps->sa_len; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_platform_havesalen=yes +else + isc_cv_platform_havesalen=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_platform_havesalen" >&5 +$as_echo "$isc_cv_platform_havesalen" >&6; } +case "$isc_cv_platform_havesalen" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVESALEN 1" >>confdefs.h + +esac + +# Check whether --enable-ipv6 was given. +if test "${enable_ipv6+set}" = set; then : + enableval=$enable_ipv6; +fi + + +case "$enable_ipv6" in + yes|''|autodetect) + case "$host" in + powerpc-ibm-aix4*) + ;; + *) + +$as_echo "#define WANT_IPV6 1" >>confdefs.h + + ;; + esac + ;; + no) + ;; +esac + + +case "$host" in + *-*-darwin*) + +$as_echo "#define __APPLE_USE_RFC_3542 1" >>confdefs.h + +esac + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 structures" >&5 +$as_echo_n "checking for IPv6 structures... " >&6; } +if ${isc_cv_found_ipv6+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + #include + +int +main () +{ + + struct sockaddr_in6 sin6; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_found_ipv6=yes +else + isc_cv_found_ipv6=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_found_ipv6" >&5 +$as_echo "$isc_cv_found_ipv6" >&6; } + +# +# See whether IPv6 support is provided via a Kame add-on. +# This is done before other IPv6 linking tests so LIBS is properly set. +# +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kame IPv6 support" >&5 +$as_echo_n "checking for Kame IPv6 support... " >&6; } + +# Check whether --with-kame was given. +if test "${with_kame+set}" = set; then : + withval=$with_kame; use_kame="$withval" +else + use_kame="no" + +fi + +case "$use_kame" in + no) + ;; + yes) + kame_path=/usr/local/v6 + ;; + *) + kame_path="$use_kame" + ;; +esac +case "$use_kame" in + no) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + *) + if test -f $kame_path/lib/libinet6.a; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $kame_path/lib/libinet6.a" >&5 +$as_echo "$kame_path/lib/libinet6.a" >&6; } + LIBS="-L$kame_path/lib -linet6 $LIBS" + else + as_fn_error $? "$kame_path/lib/libinet6.a not found. + +Please choose the proper path with the following command: + + configure --with-kame=PATH +" "$LINENO" 5 + fi + ;; +esac + +# +# Whether netinet6/in6.h is needed has to be defined in isc/platform.h. +# Including it on Kame-using platforms is very bad, though, because +# Kame uses #error against direct inclusion. So include it on only +# the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1. +# This is done before the in6_pktinfo check because that's what +# netinet6/in6.h is needed for. +# +case "$host" in + *-bsdi4.[01]*) + +$as_echo "#define ISC_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h + + isc_netinet6in6_hack="#include " + ;; + *) + isc_netinet6in6_hack="" + ;; +esac + +# +# This is similar to the netinet6/in6.h issue. +# +case "$host" in + *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*) + +$as_echo "#define ISC_PLATFORM_FIXIN6ISADDR 1" >>confdefs.h + + isc_netinetin6_hack="#include " + ;; + *) + isc_netinetin6_hack="" + ;; +esac + + +case "$isc_cv_found_ipv6" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVEIPV6 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6_pktinfo" >&5 +$as_echo_n "checking for in6_pktinfo... " >&6; } +if ${isc_cv_have_in6_pktinfo+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack + +int +main () +{ + + struct in6_pktinfo xyzzy; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_have_in6_pktinfo=yes +else + isc_cv_have_in6_pktinfo=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in6_pktinfo" >&5 +$as_echo "$isc_cv_have_in6_pktinfo" >&6; } + case "$isc_cv_have_in6_pktinfo" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVEIN6PKTINFO 1" >>confdefs.h + + esac + + + # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead? + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_in6.sin6_scope_id" >&5 +$as_echo_n "checking for sockaddr_in6.sin6_scope_id... " >&6; } +if ${isc_cv_have_sin6_scope_id+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack + +int +main () +{ + + struct sockaddr_in6 xyzzy; + xyzzy.sin6_scope_id = 0; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_have_sin6_scope_id=yes +else + isc_cv_have_sin6_scope_id=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_sin6_scope_id" >&5 +$as_echo "$isc_cv_have_sin6_scope_id" >&6; } + + case "$isc_cv_have_sin6_scope_id" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVESCOPEID 1" >>confdefs.h + + esac +esac + + +# We need this check run even without isc_cv_found_ipv6=yes + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5 +$as_echo_n "checking for in6addr_any... " >&6; } +if ${isc_cv_in6addr_any_links+:} false; then : + $as_echo_n "(cached) " >&6 +else + + SAVED_LIBS="$LIBS" + LIBS="$LDADD_LIBNTP $LIBS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default + #include + #include + $isc_netinetin6_hack + $isc_netinet6in6_hack + +int +main () +{ + + printf("%x", in6addr_any.s6_addr[15]); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + isc_cv_in6addr_any_links=yes +else + isc_cv_in6addr_any_links=no + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$SAVED_LIBS" + { SAVED_LIBS=; unset SAVED_LIBS;} + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_in6addr_any_links" >&5 +$as_echo "$isc_cv_in6addr_any_links" >&6; } + +case "$isc_cv_in6addr_any_links" in + no) + +$as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY 1" >>confdefs.h + +esac + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrconf" >&5 +$as_echo_n "checking for struct if_laddrconf... " >&6; } +if ${isc_cv_struct_if_laddrconf+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + struct if_laddrconf a; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_struct_if_laddrconf=yes +else + isc_cv_struct_if_laddrconf=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrconf" >&5 +$as_echo "$isc_cv_struct_if_laddrconf" >&6; } + +case "$isc_cv_struct_if_laddrconf" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRCONF 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrreq" >&5 +$as_echo_n "checking for struct if_laddrreq... " >&6; } +if ${isc_cv_struct_if_laddrreq+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + struct if_laddrreq a; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + isc_cv_struct_if_laddrreq=yes +else + isc_cv_struct_if_laddrreq=no + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrreq" >&5 +$as_echo "$isc_cv_struct_if_laddrreq" >&6; } + +case "$isc_cv_struct_if_laddrreq" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVEIF_LADDRREQ 1" >>confdefs.h + +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multicast IP support" >&5 +$as_echo_n "checking for multicast IP support... " >&6; } +if ${ntp_cv_multicast+:} false; then : + $as_echo_n "(cached) " >&6 +else + + ntp_cv_multicast=no + case "$host" in + i386-sequent-sysv4) + ;; + *) + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_NETINET_IN_H + # include + #endif + +int +main () +{ + + struct ip_mreq ipmr; + ipmr.imr_interface.s_addr = 0; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ntp_cv_multicast=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ;; + esac + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_multicast" >&5 +$as_echo "$ntp_cv_multicast" >&6; } +case "$ntp_cv_multicast" in + yes) + +$as_echo "#define MCAST 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for setsockopt() IP*_MULTICAST_LOOP" >&5 +$as_echo_n "checking arg type needed for setsockopt() IP*_MULTICAST_LOOP... " >&6; } +if ${ntp_cv_typeof_ip_multicast_loop+:} false; then : + $as_echo_n "(cached) " >&6 +else + + case "$host" in + *-*-netbsd*|*-*-*linux*) + ntp_cv_typeof_ip_multicast_loop=u_int + ;; + *) + ntp_cv_typeof_ip_multicast_loop=u_char + ;; + esac + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_typeof_ip_multicast_loop" >&5 +$as_echo "$ntp_cv_typeof_ip_multicast_loop" >&6; } + +cat >>confdefs.h <<_ACEOF +#define TYPEOF_IP_MULTICAST_LOOP $ntp_cv_typeof_ip_multicast_loop +_ACEOF + +esac + +# Check whether --enable-getifaddrs was given. +if test "${enable_getifaddrs+set}" = set; then : + enableval=$enable_getifaddrs; want_getifaddrs="$enableval" +else + want_getifaddrs="yes" + +fi + + +case $want_getifaddrs in + glibc) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-getifaddrs=glibc is no longer required" >&5 +$as_echo "$as_me: WARNING: --enable-getifaddrs=glibc is no longer required" >&2;} +esac +case $want_getifaddrs in + no) + ;; + *) + SAVED_LIBS="$LIBS" + LIBS="$LDADD_LIBNTP $LIBS" + for ac_func in getifaddrs +do : + ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs" +if test "x$ac_cv_func_getifaddrs" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_GETIFADDRS 1 +_ACEOF + +fi +done + + LIBS="$SAVED_LIBS" + { SAVED_LIBS=; unset SAVED_LIBS;} + ;; +esac + +# +# Check for if_nametoindex() for IPv6 scoped addresses support +# +case "$host" in + *-hp-hpux*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing if_nametoindex" >&5 +$as_echo_n "checking for library containing if_nametoindex... " >&6; } +if ${ac_cv_search_if_nametoindex+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char if_nametoindex (); +int +main () +{ +return if_nametoindex (); + ; + return 0; +} +_ACEOF +for ac_lib in '' ipv6; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_if_nametoindex=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_if_nametoindex+:} false; then : + break +fi +done +if ${ac_cv_search_if_nametoindex+:} false; then : + +else + ac_cv_search_if_nametoindex=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_if_nametoindex" >&5 +$as_echo "$ac_cv_search_if_nametoindex" >&6; } +ac_res=$ac_cv_search_if_nametoindex +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +esac +SAVED_LIBS="$LIBS" +LIBS="$LDADD_LIBNTP $LIBS" +for ac_func in if_nametoindex +do : + ac_fn_c_check_func "$LINENO" "if_nametoindex" "ac_cv_func_if_nametoindex" +if test "x$ac_cv_func_if_nametoindex" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_IF_NAMETOINDEX 1 +_ACEOF + +fi +done + +LIBS="$SAVED_LIBS" +{ SAVED_LIBS=; unset SAVED_LIBS;} +case "$ac_cv_func_if_nametoindex" in + yes) + +$as_echo "#define ISC_PLATFORM_HAVEIFNAMETOINDEX 1" >>confdefs.h + +esac + + + +### + +# Hacks +# these need work if we're to move libntp under sntp + +$as_echo "#define HAVE_NO_NICE 1" >>confdefs.h + + +$as_echo "#define HAVE_TERMIOS 1" >>confdefs.h + + +# Checks for library functions. +for ac_func in socket +do : + ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket" +if test "x$ac_cv_func_socket" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SOCKET 1 +_ACEOF + +fi +done + + + +# We may not need have_unity +have_unity=false +# Extract the first word of "ruby", so it can be a program name with args. +set dummy ruby; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PATH_RUBY+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PATH_RUBY in + [\\/]* | ?:[\\/]*) + ac_cv_path_PATH_RUBY="$PATH_RUBY" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PATH_RUBY="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PATH_RUBY=$ac_cv_path_PATH_RUBY +if test -n "$PATH_RUBY"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_RUBY" >&5 +$as_echo "$PATH_RUBY" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +case "$PATH_RUBY" in + /*) + have_unity=true + ;; + *) PATH_RUBY="false" + ;; +esac +# We may not need UNITYBUILD_AVAILABLE + if $have_unity; then + UNITYBUILD_AVAILABLE_TRUE= + UNITYBUILD_AVAILABLE_FALSE='#' +else + UNITYBUILD_AVAILABLE_TRUE='#' + UNITYBUILD_AVAILABLE_FALSE= +fi + + + +# HMS: if we don't find c++ we should not look for gtest. +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +if test -z "$CXX"; then + if test -n "$CCC"; then + CXX=$CCC + else + if test -n "$ac_tool_prefix"; then + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CXX"; then + ac_cv_prog_CXX="$CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CXX=$ac_cv_prog_CXX +if test -n "$CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 +$as_echo "$CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CXX" && break + done +fi +if test -z "$CXX"; then + ac_ct_CXX=$CXX + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CXX"; then + ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CXX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CXX=$ac_cv_prog_ac_ct_CXX +if test -n "$ac_ct_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 +$as_echo "$ac_ct_CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CXX" && break +done + + if test "x$ac_ct_CXX" = x; then + CXX="g++" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CXX=$ac_ct_CXX + fi +fi + + fi +fi +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 +$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } +if ${ac_cv_cxx_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_cxx_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 +$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GXX=yes +else + GXX= +fi +ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_save_CXXFLAGS=$CXXFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 +$as_echo_n "checking whether $CXX accepts -g... " >&6; } +if ${ac_cv_prog_cxx_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_cxx_werror_flag=$ac_cxx_werror_flag + ac_cxx_werror_flag=yes + ac_cv_prog_cxx_g=no + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +else + CXXFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + +else + ac_cxx_werror_flag=$ac_save_cxx_werror_flag + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 +$as_echo "$ac_cv_prog_cxx_g" >&6; } +if test "$ac_test_CXXFLAGS" = set; then + CXXFLAGS=$ac_save_CXXFLAGS +elif test $ac_cv_prog_cxx_g = yes; then + if test "$GXX" = yes; then + CXXFLAGS="-g -O2" + else + CXXFLAGS="-g" + fi +else + if test "$GXX" = yes; then + CXXFLAGS="-O2" + else + CXXFLAGS= + fi +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +depcc="$CXX" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CXX_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CXX_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CXX_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CXX_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } +CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then + am__fastdepCXX_TRUE= + am__fastdepCXX_FALSE='#' +else + am__fastdepCXX_TRUE='#' + am__fastdepCXX_FALSE= +fi + + + + +func_stripname_cnf () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname_cnf + + if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 +$as_echo_n "checking how to run the C++ preprocessor... " >&6; } +if test -z "$CXXCPP"; then + if ${ac_cv_prog_CXXCPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CXXCPP needs to be expanded + for CXXCPP in "$CXX -E" "/lib/cpp" + do + ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CXXCPP=$CXXCPP + +fi + CXXCPP=$ac_cv_prog_CXXCPP +else + ac_cv_prog_CXXCPP=$CXXCPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 +$as_echo "$CXXCPP" >&6; } +ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +else + _lt_caught_CXX_error=yes +fi + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +archive_cmds_need_lc_CXX=no +allow_undefined_flag_CXX= +always_export_symbols_CXX=no +archive_expsym_cmds_CXX= +compiler_needs_object_CXX=no +export_dynamic_flag_spec_CXX= +hardcode_direct_CXX=no +hardcode_direct_absolute_CXX=no +hardcode_libdir_flag_spec_CXX= +hardcode_libdir_flag_spec_ld_CXX= +hardcode_libdir_separator_CXX= +hardcode_minus_L_CXX=no +hardcode_shlibpath_var_CXX=unsupported +hardcode_automatic_CXX=no +inherit_rpath_CXX=no +module_cmds_CXX= +module_expsym_cmds_CXX= +link_all_deplibs_CXX=unknown +old_archive_cmds_CXX=$old_archive_cmds +reload_flag_CXX=$reload_flag +reload_cmds_CXX=$reload_cmds +no_undefined_flag_CXX= +whole_archive_flag_spec_CXX= +enable_shared_with_static_runtimes_CXX=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +objext_CXX=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_caught_CXX_error" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + + # save warnings/boilerplate of simple test code + ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + + ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + compiler_CXX=$CC + for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` + + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test "$GXX" = yes; then + lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' + else + lt_prog_compiler_no_builtin_flag_CXX= + fi + + if test "$GXX" = yes; then + # Set up default GNU C++ configuration + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test "$with_gnu_ld" = yes; then + archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='${wl}' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec_CXX= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + ld_shlibs_CXX=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds_CXX='' + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + file_list_spec_CXX='${wl}-f,' + + if test "$GXX" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_CXX=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_CXX=yes + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_libdir_separator_CXX= + fi + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + export_dynamic_flag_spec_CXX='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + always_export_symbols_CXX=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag_CXX='-berok' + # Determine the default libpath from the value encoded in an empty + # executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" + + archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag_CXX="-z nodefs" + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_CXX=' ${wl}-bernotok' + allow_undefined_flag_CXX=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_CXX='$convenience' + fi + archive_cmds_need_lc_CXX=yes + # This is similar to how AIX traditionally builds its shared + # libraries. + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_CXX=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs_CXX=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_CXX=' ' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=yes + file_list_spec_CXX='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' + enable_shared_with_static_runtimes_CXX=yes + # Don't use ranlib + old_postinstall_cmds_CXX='chmod 644 $oldlib' + postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_CXX='-L$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-all-symbols' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=no + enable_shared_with_static_runtimes_CXX=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_CXX=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + + + archive_cmds_need_lc_CXX=no + hardcode_direct_CXX=no + hardcode_automatic_CXX=yes + hardcode_shlibpath_var_CXX=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + whole_archive_flag_spec_CXX='' + fi + link_all_deplibs_CXX=yes + allow_undefined_flag_CXX="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + if test "$lt_cv_apple_cc_single_mod" != "yes"; then + archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" + fi + + else + ld_shlibs_CXX=no + fi + + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + freebsd[12]*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + ld_shlibs_CXX=no + ;; + + freebsd-elf*) + archive_cmds_need_lc_CXX=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + ld_shlibs_CXX=yes + ;; + + gnu*) + ;; + + haiku*) + archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs_CXX=yes + ;; + + hpux9*) + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: + export_dynamic_flag_spec_CXX='${wl}-E' + hardcode_direct_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test $with_gnu_ld = no; then + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + export_dynamic_flag_spec_CXX='${wl}-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + ;; + *) + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + if test $with_gnu_ld = no; then + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + interix[3-9]*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test "$GXX" = yes; then + if test "$with_gnu_ld" = no; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' + fi + fi + link_all_deplibs_CXX=yes + ;; + esac + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + inherit_rpath_CXX=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + archive_cmds_need_lc_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [1-5].* | *pgcpp\ [1-5].*) + prelink_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + old_archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + archive_expsym_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + ;; + cxx*) + # Compaq C++ + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + hardcode_libdir_flag_spec_CXX='-R$libdir' + whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object_CXX=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + ld_shlibs_CXX=yes + ;; + + openbsd2*) + # C++ shared libraries are fairly broken + ld_shlibs_CXX=no + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + hardcode_direct_absolute_CXX=yes + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' + export_dynamic_flag_spec_CXX='${wl}-E' + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + ld_shlibs_CXX=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + hardcode_libdir_separator_CXX=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + cxx*) + case $host in + osf3*) + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + ;; + *) + allow_undefined_flag_CXX=' -expect_unresolved \*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ + $RM $lib.exp' + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + ;; + esac + + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + case $host in + osf3*) + archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + *) + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + archive_cmds_need_lc_CXX=yes + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_shlibpath_var_CXX=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' + ;; + esac + link_all_deplibs_CXX=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + no_undefined_flag_CXX=' ${wl}-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require `-G' NOT `-shared' on this + # platform. + archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_CXX='${wl}-z,text' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag_CXX='${wl}-z,text' + allow_undefined_flag_CXX='${wl}-z,nodefs' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir' + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + export_dynamic_flag_spec_CXX='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ + '"$old_archive_cmds_CXX" + reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ + '"$reload_cmds_CXX" + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } + test "$ld_shlibs_CXX" = no && can_build_shared=no + + GCC_CXX="$GXX" + LD_CXX="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + # Dependencies to place before and after the object being linked: +predep_objects_CXX= +postdep_objects_CXX= +predeps_CXX= +postdeps_CXX= +compiler_lib_search_path_CXX= + +cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF + + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +esac + +if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case ${prev}${p} in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test $p = "-L" || + test $p = "-R"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test "$pre_test_object_deps_done" = no; then + case ${prev} in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$compiler_lib_search_path_CXX"; then + compiler_lib_search_path_CXX="${prev}${p}" + else + compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$postdeps_CXX"; then + postdeps_CXX="${prev}${p}" + else + postdeps_CXX="${postdeps_CXX} ${prev}${p}" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test "$pre_test_object_deps_done" = no; then + if test -z "$predep_objects_CXX"; then + predep_objects_CXX="$p" + else + predep_objects_CXX="$predep_objects_CXX $p" + fi + else + if test -z "$postdep_objects_CXX"; then + postdep_objects_CXX="$p" + else + postdep_objects_CXX="$postdep_objects_CXX $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling CXX test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +case $host_os in +interix[3-9]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + predep_objects_CXX= + postdep_objects_CXX= + postdeps_CXX= + ;; + +linux*) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; + +solaris*) + case $cc_basename in + CC* | sunCC*) + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + # Adding this requires a known-good setup of shared libraries for + # Sun compiler versions before 5.6, else PIC objects from an old + # archive will be linked into the output, leading to subtle bugs. + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; +esac + + +case " $postdeps_CXX " in +*" -lc "*) archive_cmds_need_lc_CXX=no ;; +esac + compiler_lib_search_dirs_CXX= +if test -n "${compiler_lib_search_path_CXX}"; then + compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + lt_prog_compiler_wl_CXX= +lt_prog_compiler_pic_CXX= +lt_prog_compiler_static_CXX= + + + # C++ specific cases for pic, static, wl, etc. + if test "$GXX" = yes; then + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic_CXX='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_CXX='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + lt_prog_compiler_pic_CXX= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static_CXX= + ;; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_CXX=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + else + case $host_os in + aix[4-9]*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + else + lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + dgux*) + case $cc_basename in + ec++*) + lt_prog_compiler_pic_CXX='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + if test "$host_cpu" != ia64; then + lt_prog_compiler_pic_CXX='+Z' + fi + ;; + aCC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_CXX='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + KCC*) + # KAI C++ Compiler + lt_prog_compiler_wl_CXX='--backend -Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64 which still supported -KPIC. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + lt_prog_compiler_static_CXX='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fpic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-qpic' + lt_prog_compiler_static_CXX='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + lt_prog_compiler_pic_CXX='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd*) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + lt_prog_compiler_wl_CXX='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + lt_prog_compiler_pic_CXX='-pic' + ;; + cxx*) + # Digital/Compaq C++ + lt_prog_compiler_wl_CXX='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + lt_prog_compiler_pic_CXX='-pic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + lcc*) + # Lucid + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + lt_prog_compiler_pic_CXX='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + lt_prog_compiler_can_build_shared_CXX=no + ;; + esac + fi + +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_CXX= + ;; + *) + lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } +lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } +if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works_CXX=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_CXX=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } + +if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then + case $lt_prog_compiler_pic_CXX in + "" | " "*) ;; + *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; + esac +else + lt_prog_compiler_pic_CXX= + lt_prog_compiler_can_build_shared_CXX=no +fi + +fi + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works_CXX=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_CXX=yes + fi + else + lt_cv_prog_compiler_static_works_CXX=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } + +if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then + : +else + lt_prog_compiler_static_CXX= +fi + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + case $host_os in + aix[4-9]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global defined + # symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + export_symbols_cmds_CXX="$ltdll_cmds" + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + ;; + esac + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } +test "$ld_shlibs_CXX" = no && can_build_shared=no + +with_gnu_ld_CXX=$with_gnu_ld + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_CXX" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_CXX=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds_CXX in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_CXX + pic_flag=$lt_prog_compiler_pic_CXX + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_CXX + allow_undefined_flag_CXX= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc_CXX=no + else + lt_cv_archive_cmds_need_lc_CXX=yes + fi + allow_undefined_flag_CXX=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } + archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd1*) + dynamic_linker=no + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; + +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_CXX= +if test -n "$hardcode_libdir_flag_spec_CXX" || + test -n "$runpath_var_CXX" || + test "X$hardcode_automatic_CXX" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$hardcode_direct_CXX" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no && + test "$hardcode_minus_L_CXX" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action_CXX=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_CXX=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_CXX=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 +$as_echo "$hardcode_action_CXX" >&6; } + +if test "$hardcode_action_CXX" = relink || + test "$inherit_rpath_CXX" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test "$_lt_caught_CXX_error" != yes + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + +gta=false + +# Check whether --with-gtest was given. +if test "${with_gtest+set}" = set; then : + withval=$with_gtest; try_gtest=$withval +else + try_gtest=yes + +fi + +case "$try_gtest" in + yes) + # Extract the first word of "gtest-config", so it can be a program name with args. +set dummy gtest-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GTEST_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GTEST_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_GTEST_CONFIG="$GTEST_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_GTEST_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +GTEST_CONFIG=$ac_cv_path_GTEST_CONFIG +if test -n "$GTEST_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTEST_CONFIG" >&5 +$as_echo "$GTEST_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + { ac_cv_path_GTEST_CONFIG=; unset ac_cv_path_GTEST_CONFIG;} + case x${GTEST_CONFIG} in + x) ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking gtest version" >&5 +$as_echo_n "checking gtest version... " >&6; } + gtest_version_test=`$GTEST_CONFIG --min-version=1.5 || echo toolow` + case "$gtest_version_test" in + toolow*) + ;; + *) + GTEST_LDFLAGS=`$GTEST_CONFIG --ldflags` + GTEST_LIBS=`$GTEST_CONFIG --libs` + GTEST_CXXFLAGS=`$GTEST_CONFIG --cxxflags` + GTEST_CPPFLAGS=`$GTEST_CONFIG --cppflags` + + + + + gta=true + ;; + esac + gtest_version=`$GTEST_CONFIG --version` + case "$gta" in + true) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) ok" >&5 +$as_echo "($gtest_version) ok" >&6; } + ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) not ok" >&5 +$as_echo "($gtest_version) not ok" >&6; } + ;; + esac + { gtest_version_test=; unset gtest_version_test;} + { gtest_version=; unset gtest_version;} + esac +esac + if $gta; then + GTEST_AVAILABLE_TRUE= + GTEST_AVAILABLE_FALSE='#' +else + GTEST_AVAILABLE_TRUE='#' + GTEST_AVAILABLE_FALSE= +fi + + + + +# All libraries should be in various LIB_* variables now. +#LIBS= +# Sadly not. There is a gettext() check somewhere, and on Solaris this pulls +# in -lintl -lgen, outside our "scope". + +ac_config_files="$ac_config_files Makefile" + +ac_config_files="$ac_config_files include/Makefile" + +ac_config_files="$ac_config_files scripts/Makefile" + +ac_config_files="$ac_config_files tests/Makefile" + +ac_config_files="$ac_config_files tests/fileHandlingTest.h" + +ac_config_files="$ac_config_files unity/Makefile" + + +cat >confcache <<\_ACEOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. +# +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. +# +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. + +_ACEOF + +# The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +( + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + + (set) 2>&1 | + case $as_nl`(ac_space=' '; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + # `set' does not quote correctly, so add quotes: double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \. + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; #( + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) | + sed ' + /^ac_cv_env_/b end + t clear + :clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + :end' >>confcache +if diff "$cache_file" confcache >/dev/null 2>&1; then :; else + if test -w "$cache_file"; then + if test "x$cache_file" != "x/dev/null"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 +$as_echo "$as_me: updating cache $cache_file" >&6;} + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 +$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + fi +fi +rm -f confcache + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +DEFS=-DHAVE_CONFIG_H + +ac_libobjs= +ac_ltlibobjs= +U= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' + ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR + # will be set to the directory where LIBOBJS objects are built. + as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" + as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs + +LTLIBOBJS=$ac_ltlibobjs + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +$as_echo_n "checking that generated files are newer than configure... " >&6; } + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 +$as_echo "done" >&6; } + if test -n "$EXEEXT"; then + am__EXEEXT_TRUE= + am__EXEEXT_FALSE='#' +else + am__EXEEXT_TRUE='#' + am__EXEEXT_FALSE= +fi + +if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then + as_fn_error $? "conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +if test -z "${WANT_CALC_TICKADJ_MS_TRUE}" && test -z "${WANT_CALC_TICKADJ_MS_FALSE}"; then + as_fn_error $? "conditional \"WANT_CALC_TICKADJ_MS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${INSTALL_NTPSWEEP_TRUE}" && test -z "${INSTALL_NTPSWEEP_FALSE}"; then + as_fn_error $? "conditional \"INSTALL_NTPSWEEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${INSTALL_UPDATE_LEAP_TRUE}" && test -z "${INSTALL_UPDATE_LEAP_FALSE}"; then + as_fn_error $? "conditional \"INSTALL_UPDATE_LEAP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${NTP_CROSSCOMPILE_TRUE}" && test -z "${NTP_CROSSCOMPILE_FALSE}"; then + as_fn_error $? "conditional \"NTP_CROSSCOMPILE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${PTHREADS_TRUE}" && test -z "${PTHREADS_FALSE}"; then + as_fn_error $? "conditional \"PTHREADS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_SNTP_TRUE}" && test -z "${BUILD_SNTP_FALSE}"; then + as_fn_error $? "conditional \"BUILD_SNTP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${GL_GENERATE_STDNORETURN_H_TRUE}" && test -z "${GL_GENERATE_STDNORETURN_H_FALSE}"; then + as_fn_error $? "conditional \"GL_GENERATE_STDNORETURN_H\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then + as_fn_error $? "conditional \"INSTALL_LIBOPTS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${NEED_LIBOPTS_TRUE}" && test -z "${NEED_LIBOPTS_FALSE}"; then + as_fn_error $? "conditional \"NEED_LIBOPTS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_LIBEVENT_TRUE}" && test -z "${BUILD_LIBEVENT_FALSE}"; then + as_fn_error $? "conditional \"BUILD_LIBEVENT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${UNITYBUILD_AVAILABLE_TRUE}" && test -z "${UNITYBUILD_AVAILABLE_FALSE}"; then + as_fn_error $? "conditional \"UNITYBUILD_AVAILABLE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${GTEST_AVAILABLE_TRUE}" && test -z "${GTEST_AVAILABLE_FALSE}"; then + as_fn_error $? "conditional \"GTEST_AVAILABLE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +: "${CONFIG_STATUS=./config.status}" +ac_write_fail=0 +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files $CONFIG_STATUS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 +$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +as_write_fail=0 +cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 +#! $SHELL +# Generated by $as_me. +# Run this file to recreate the current configuration. +# Compiler output produced by configure, useful for debugging +# configure, is in config.log if it exists. + +debug=false +ac_cs_recheck=false +ac_cs_silent=false + +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + + +exec 6>&1 +## ----------------------------------- ## +## Main body of $CONFIG_STATUS script. ## +## ----------------------------------- ## +_ASEOF +test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Save the log message, to keep $0 and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. +ac_log=" +This file was extended by sntp $as_me 4.2.8p4, which was +generated by GNU Autoconf 2.69. Invocation command line was + + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ + +on `(hostname || uname -n) 2>/dev/null | sed 1q` +" + +_ACEOF + +case $ac_config_files in *" +"*) set x $ac_config_files; shift; ac_config_files=$*;; +esac + +case $ac_config_headers in *" +"*) set x $ac_config_headers; shift; ac_config_headers=$*;; +esac + + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# Files that config.status was made for. +config_files="$ac_config_files" +config_headers="$ac_config_headers" +config_commands="$ac_config_commands" + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +ac_cs_usage="\ +\`$as_me' instantiates files and other configuration actions +from templates according to the current configuration. Unless the files +and actions are specified as TAGs, all are instantiated by default. + +Usage: $0 [OPTION]... [TAG]... + + -h, --help print this help, then exit + -V, --version print version number and configuration settings, then exit + --config print configuration, then exit + -q, --quiet, --silent + do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + --header=FILE[:TEMPLATE] + instantiate the configuration header FILE + +Configuration files: +$config_files + +Configuration headers: +$config_headers + +Configuration commands: +$config_commands + +Report bugs to . +sntp home page: ." + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +ac_cs_version="\\ +sntp config.status 4.2.8p4 +configured by $0, generated by GNU Autoconf 2.69, + with options \\"\$ac_cs_config\\" + +Copyright (C) 2012 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." + +ac_pwd='$ac_pwd' +srcdir='$srcdir' +INSTALL='$INSTALL' +MKDIR_P='$MKDIR_P' +AWK='$AWK' +test -n "\$AWK" || AWK=awk +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# The default lists apply if the user does not specify any file. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=?*) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` + ac_shift=: + ;; + --*=) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg= + ac_shift=: + ;; + *) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + esac + + case $ac_option in + # Handling of the options. + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) + $as_echo "$ac_cs_version"; exit ;; + --config | --confi | --conf | --con | --co | --c ) + $as_echo "$ac_cs_config"; exit ;; + --debug | --debu | --deb | --de | --d | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + '') as_fn_error $? "missing file argument" ;; + esac + as_fn_append CONFIG_FILES " '$ac_optarg'" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append CONFIG_HEADERS " '$ac_optarg'" + ac_need_defaults=false;; + --he | --h) + # Conflict between --help and --header + as_fn_error $? "ambiguous option: \`$1' +Try \`$0 --help' for more information.";; + --help | --hel | -h ) + $as_echo "$ac_cs_usage"; exit ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; + + # This is an error. + -*) as_fn_error $? "unrecognized option: \`$1' +Try \`$0 --help' for more information." ;; + + *) as_fn_append ac_config_targets " $1" + ac_need_defaults=false ;; + + esac + shift +done + +ac_configure_extra_args= + +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +if \$ac_cs_recheck; then + set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + shift + \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + CONFIG_SHELL='$SHELL' + export CONFIG_SHELL + exec "\$@" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX + $as_echo "$ac_log" +} >&5 + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# +# INIT-COMMANDS +# +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" + + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' +Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' +GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' +EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' +FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' +SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' +ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' +LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' +enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' +macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' +macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' +enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' +pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' +enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' +host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' +host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' +host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' +build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' +build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' +build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' +NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' +LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' +max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' +ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' +exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' +lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' +lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' +lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' +lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' +lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' +reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' +reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' +deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' +file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' +file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' +want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' +DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' +sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' +AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' +archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' +STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' +RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' +old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' +old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' +lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' +CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' +CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' +compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' +GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' +nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' +lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' +objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' +MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' +need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' +MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' +DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' +NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' +LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' +OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' +OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' +libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' +shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' +extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' +compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' +module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' +with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' +no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' +hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' +hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' +inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' +link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' +always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' +exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' +include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' +prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' +postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' +file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' +variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' +need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' +need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' +version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' +runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' +libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' +library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' +soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' +install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' +postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' +postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' +finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' +hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' +sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' +sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' +hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' +enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' +old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' +striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' +predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' +postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' +predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' +postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' +LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' +reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' +reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' +GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_ld_CXX='`$ECHO "$hardcode_libdir_flag_spec_ld_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' +inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' +link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' +always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' +exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' +predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' +postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' +predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' +postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' + +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in SED \ +GREP \ +EGREP \ +FGREP \ +SHELL \ +ECHO \ +LD \ +NM \ +LN_S \ +lt_SP2NL \ +lt_NL2SP \ +reload_flag \ +OBJDUMP \ +deplibs_check_method \ +file_magic_cmd \ +file_magic_glob \ +want_nocaseglob \ +DLLTOOL \ +sharedlib_from_linklib_cmd \ +AR \ +AR_FLAGS \ +archiver_list_spec \ +STRIP \ +RANLIB \ +CC \ +CFLAGS \ +compiler \ +lt_cv_sys_global_symbol_pipe \ +lt_cv_sys_global_symbol_to_cdecl \ +lt_cv_sys_global_symbol_to_c_name_address \ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ +nm_file_list_spec \ +lt_prog_compiler_no_builtin_flag \ +lt_prog_compiler_pic \ +lt_prog_compiler_wl \ +lt_prog_compiler_static \ +lt_cv_prog_compiler_c_o \ +need_locks \ +MANIFEST_TOOL \ +DSYMUTIL \ +NMEDIT \ +LIPO \ +OTOOL \ +OTOOL64 \ +shrext_cmds \ +export_dynamic_flag_spec \ +whole_archive_flag_spec \ +compiler_needs_object \ +with_gnu_ld \ +allow_undefined_flag \ +no_undefined_flag \ +hardcode_libdir_flag_spec \ +hardcode_libdir_flag_spec_ld \ +hardcode_libdir_separator \ +exclude_expsyms \ +include_expsyms \ +file_list_spec \ +variables_saved_for_relink \ +libname_spec \ +library_names_spec \ +soname_spec \ +install_override_mode \ +finish_eval \ +old_striplib \ +striplib \ +compiler_lib_search_dirs \ +predep_objects \ +postdep_objects \ +predeps \ +postdeps \ +compiler_lib_search_path \ +LD_CXX \ +reload_flag_CXX \ +compiler_CXX \ +lt_prog_compiler_no_builtin_flag_CXX \ +lt_prog_compiler_pic_CXX \ +lt_prog_compiler_wl_CXX \ +lt_prog_compiler_static_CXX \ +lt_cv_prog_compiler_c_o_CXX \ +export_dynamic_flag_spec_CXX \ +whole_archive_flag_spec_CXX \ +compiler_needs_object_CXX \ +with_gnu_ld_CXX \ +allow_undefined_flag_CXX \ +no_undefined_flag_CXX \ +hardcode_libdir_flag_spec_CXX \ +hardcode_libdir_flag_spec_ld_CXX \ +hardcode_libdir_separator_CXX \ +exclude_expsyms_CXX \ +include_expsyms_CXX \ +file_list_spec_CXX \ +compiler_lib_search_dirs_CXX \ +predep_objects_CXX \ +postdep_objects_CXX \ +predeps_CXX \ +postdeps_CXX \ +compiler_lib_search_path_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in reload_cmds \ +old_postinstall_cmds \ +old_postuninstall_cmds \ +old_archive_cmds \ +extract_expsyms_cmds \ +old_archive_from_new_cmds \ +old_archive_from_expsyms_cmds \ +archive_cmds \ +archive_expsym_cmds \ +module_cmds \ +module_expsym_cmds \ +export_symbols_cmds \ +prelink_cmds \ +postlink_cmds \ +postinstall_cmds \ +postuninstall_cmds \ +finish_cmds \ +sys_lib_search_path_spec \ +sys_lib_dlsearch_path_spec \ +reload_cmds_CXX \ +old_archive_cmds_CXX \ +old_archive_from_new_cmds_CXX \ +old_archive_from_expsyms_cmds_CXX \ +archive_cmds_CXX \ +archive_expsym_cmds_CXX \ +module_cmds_CXX \ +module_expsym_cmds_CXX \ +export_symbols_cmds_CXX \ +prelink_cmds_CXX \ +postlink_cmds_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +ac_aux_dir='$ac_aux_dir' +xsi_shell='$xsi_shell' +lt_shell_append='$lt_shell_append' + +# See if we are running on zsh, and set the options which allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + + + PACKAGE='$PACKAGE' + VERSION='$VERSION' + TIMESTAMP='$TIMESTAMP' + RM='$RM' + ofile='$ofile' + + + + + + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + +# Handling of arguments. +for ac_config_target in $ac_config_targets +do + case $ac_config_target in + "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; + "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; + "libopts/Makefile") CONFIG_FILES="$CONFIG_FILES libopts/Makefile" ;; + "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; + "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;; + "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;; + "tests/fileHandlingTest.h") CONFIG_FILES="$CONFIG_FILES tests/fileHandlingTest.h" ;; + "unity/Makefile") CONFIG_FILES="$CONFIG_FILES unity/Makefile" ;; + + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + esac +done + + +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files + test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers + test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands +fi + +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason against having it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Hook for its removal unless debugging. +# Note that there is a small window in which the directory will not be cleaned: +# after its creation but before its name has been assigned to `$tmp'. +$debug || +{ + tmp= ac_tmp= + trap 'exit_status=$? + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status +' 0 + trap 'as_fn_exit 1' 1 2 13 15 +} +# Create a (secure) tmp directory for tmp files. + +{ + tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && + test -d "$tmp" +} || +{ + tmp=./conf$$-$RANDOM + (umask 077 && mkdir "$tmp") +} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp + +# Set up the scripts for CONFIG_FILES section. +# No need to generate them if there are no CONFIG_FILES. +# This happens for instance with `./config.status config.h'. +if test -n "$CONFIG_FILES"; then + + +ac_cr=`echo X | tr X '\015'` +# On cygwin, bash can eat \r inside `` if the user requested igncr. +# But we know of no other shell where ac_cr would be empty at this +# point, so we can use a bashism as a fallback. +if test "x$ac_cr" = x; then + eval ac_cr=\$\'\\r\' +fi +ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` +if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then + ac_cs_awk_cr='\\r' +else + ac_cs_awk_cr=$ac_cr +fi + +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && +_ACEOF + + +{ + echo "cat >conf$$subs.awk <<_ACEOF" && + echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && + echo "_ACEOF" +} >conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` +ac_delim='%!_!# ' +for ac_last_try in false false false false false :; do + . ./conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + if test $ac_delim_n = $ac_delim_num; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done +rm -f conf$$subs.sh + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && +_ACEOF +sed -n ' +h +s/^/S["/; s/!.*/"]=/ +p +g +s/^[^!]*!// +:repl +t repl +s/'"$ac_delim"'$// +t delim +:nl +h +s/\(.\{148\}\)..*/\1/ +t more1 +s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ +p +n +b repl +:more1 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t nl +:delim +h +s/\(.\{148\}\)..*/\1/ +t more2 +s/["\\]/\\&/g; s/^/"/; s/$/"/ +p +b +:more2 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t delim +' >$CONFIG_STATUS || ac_write_fail=1 +rm -f conf$$subs.awk +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +_ACAWK +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && + for (key in S) S_is_set[key] = 1 + FS = "" + +} +{ + line = $ 0 + nfields = split(line, field, "@") + substed = 0 + len = length(field[1]) + for (i = 2; i < nfields; i++) { + key = field[i] + keylen = length(key) + if (S_is_set[key]) { + value = S[key] + line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) + len += length(value) + length(field[++i]) + substed = 1 + } else + len += 1 + keylen + } + + print line +} + +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then + sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" +else + cat +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ + || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 +_ACEOF + +# VPATH may cause trouble with some makes, so we remove sole $(srcdir), +# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ +h +s/// +s/^/:/ +s/[ ]*$/:/ +s/:\$(srcdir):/:/g +s/:\${srcdir}:/:/g +s/:@srcdir@:/:/g +s/^:*// +s/:*$// +x +s/\(=[ ]*\).*/\1/ +G +s/\n// +s/^[^=]*=[ ]*$// +}' +fi + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +fi # test -n "$CONFIG_FILES" + +# Set up the scripts for CONFIG_HEADERS section. +# No need to generate them if there are no CONFIG_HEADERS. +# This happens for instance with `./config.status Makefile'. +if test -n "$CONFIG_HEADERS"; then +cat >"$ac_tmp/defines.awk" <<\_ACAWK || +BEGIN { +_ACEOF + +# Transform confdefs.h into an awk script `defines.awk', embedded as +# here-document in config.status, that substitutes the proper values into +# config.h.in to produce config.h. + +# Create a delimiter string that does not exist in confdefs.h, to ease +# handling of long lines. +ac_delim='%!_!# ' +for ac_last_try in false false :; do + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done + +# For the awk script, D is an array of macro values keyed by name, +# likewise P contains macro parameters if any. Preserve backslash +# newline sequences. + +ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* +sed -n ' +s/.\{148\}/&'"$ac_delim"'/g +t rset +:rset +s/^[ ]*#[ ]*define[ ][ ]*/ / +t def +d +:def +s/\\$// +t bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3"/p +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p +d +:bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3\\\\\\n"\\/p +t cont +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p +t cont +d +:cont +n +s/.\{148\}/&'"$ac_delim"'/g +t clear +:clear +s/\\$// +t bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/"/p +d +:bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p +b cont +' >$CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + for (key in D) D_is_set[key] = 1 + FS = "" +} +/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { + line = \$ 0 + split(line, arg, " ") + if (arg[1] == "#") { + defundef = arg[2] + mac1 = arg[3] + } else { + defundef = substr(arg[1], 2) + mac1 = arg[2] + } + split(mac1, mac2, "(") #) + macro = mac2[1] + prefix = substr(line, 1, index(line, defundef) - 1) + if (D_is_set[macro]) { + # Preserve the white space surrounding the "#". + print prefix "define", macro P[macro] D[macro] + next + } else { + # Replace #undef with comments. This is necessary, for example, + # in the case of _POSIX_SOURCE, which is predefined and required + # on some systems where configure will not decide to define it. + if (defundef == "undef") { + print "/*", prefix defundef, macro, "*/" + next + } + } +} +{ print } +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 +fi # test -n "$CONFIG_HEADERS" + + +eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" +shift +for ac_tag +do + case $ac_tag in + :[FHLC]) ac_mode=$ac_tag; continue;; + esac + case $ac_mode$ac_tag in + :[FHL]*:*);; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; + :[FH]-) ac_tag=-:-;; + :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; + esac + ac_save_IFS=$IFS + IFS=: + set x $ac_tag + IFS=$ac_save_IFS + shift + ac_file=$1 + shift + + case $ac_mode in + :L) ac_source=$1;; + :[FH]) + ac_file_inputs= + for ac_f + do + case $ac_f in + -) ac_f="$ac_tmp/stdin";; + *) # Look for the file first in the build tree, then in the source tree + # (if the path is not absolute). The absolute path cannot be DOS-style, + # because $ac_f cannot contain `:'. + test -f "$ac_f" || + case $ac_f in + [\\/$]*) false;; + *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; + esac || + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; + esac + case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + as_fn_append ac_file_inputs " '$ac_f'" + done + + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + configure_input='Generated from '` + $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + `' by configure.' + if test x"$ac_file" != x-; then + configure_input="$ac_file. $configure_input" + { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 +$as_echo "$as_me: creating $ac_file" >&6;} + fi + # Neutralize special characters interpreted by sed in replacement strings. + case $configure_input in #( + *\&* | *\|* | *\\* ) + ac_sed_conf_input=`$as_echo "$configure_input" | + sed 's/[\\\\&|]/\\\\&/g'`;; #( + *) ac_sed_conf_input=$configure_input;; + esac + + case $ac_tag in + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; + esac + ;; + esac + + ac_dir=`$as_dirname -- "$ac_file" || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + + case $ac_mode in + :F) + # + # CONFIG_FILE + # + + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; + esac + ac_MKDIR_P=$MKDIR_P + case $MKDIR_P in + [\\/$]* | ?:[\\/]* ) ;; + */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; + esac +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# If the template does not know about datarootdir, expand it. +# FIXME: This hack should be removed a few years after 2.60. +ac_datarootdir_hack=; ac_datarootdir_seen= +ac_sed_dataroot=' +/datarootdir/ { + p + q +} +/@datadir@/p +/@docdir@/p +/@infodir@/p +/@localedir@/p +/@mandir@/p' +case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in +*datarootdir*) ac_datarootdir_seen=yes;; +*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + ac_datarootdir_hack=' + s&@datadir@&$datadir&g + s&@docdir@&$docdir&g + s&@infodir@&$infodir&g + s&@localedir@&$localedir&g + s&@mandir@&$mandir&g + s&\\\${datarootdir}&$datarootdir&g' ;; +esac +_ACEOF + +# Neutralize VPATH when `$srcdir' = `.'. +# Shell code in configure.ac might set extrasub. +# FIXME: do we really want to maintain this feature? +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_sed_extra="$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s|@configure_input@|$ac_sed_conf_input|;t t +s&@top_builddir@&$ac_top_builddir_sub&;t t +s&@top_build_prefix@&$ac_top_build_prefix&;t t +s&@srcdir@&$ac_srcdir&;t t +s&@abs_srcdir@&$ac_abs_srcdir&;t t +s&@top_srcdir@&$ac_top_srcdir&;t t +s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t +s&@builddir@&$ac_builddir&;t t +s&@abs_builddir@&$ac_abs_builddir&;t t +s&@abs_top_builddir@&$ac_abs_top_builddir&;t t +s&@INSTALL@&$ac_INSTALL&;t t +s&@MKDIR_P@&$ac_MKDIR_P&;t t +$ac_datarootdir_hack +" +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + +test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&5 +$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&2;} + + rm -f "$ac_tmp/stdin" + case $ac_file in + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; + esac \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + ;; + :H) + # + # CONFIG_HEADER + # + if test x"$ac_file" != x-; then + { + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 +$as_echo "$as_me: $ac_file is unchanged" >&6;} + else + rm -f "$ac_file" + mv "$ac_tmp/config.h" "$ac_file" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + fi + else + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ + || as_fn_error $? "could not create -" "$LINENO" 5 + fi +# Compute "$ac_file"'s index in $config_headers. +_am_arg="$ac_file" +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || +$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$_am_arg" : 'X\(//\)[^/]' \| \ + X"$_am_arg" : 'X\(//\)$' \| \ + X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$_am_arg" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'`/stamp-h$_am_stamp_count + ;; + + :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 +$as_echo "$as_me: executing $ac_file commands" >&6;} + ;; + esac + -int -main () -{ -struct tm tm; - int *p = &tm.tm_sec; - return !p; - ; - return 0; + case $ac_file$ac_mode in + "depfiles":C) test x"$AMDEP_TRUE" != x"" || { + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir=$dirpart/$fdir; as_fn_mkdir_p + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done } -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_struct_tm=time.h -else - ac_cv_struct_tm=sys/time.h -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 -$as_echo "$ac_cv_struct_tm" >&6; } -if test $ac_cv_struct_tm = sys/time.h; then - -$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h + ;; + "libtool":C) -fi + # See if we are running on zsh, and set the options which allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + cfgfile="${ofile}T" + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have_ss_family_in_struct_ss+set}" = set; then : - $as_echo_n "(cached) " >&6 -else + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is part of GNU Libtool. +# +# GNU Libtool is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or +# obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -#include -#include -int -main () -{ - struct sockaddr_storage s; s.ss_family = 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have_ss_family_in_struct_ss="yes" -else - ac_cv_have_ss_family_in_struct_ss="no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +# The names of the tagged configurations supported by this script. +available_tags="CXX " -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have_ss_family_in_struct_ss" >&6; } -case "$ac_cv_have_ss_family_in_struct_ss" in - yes) +# ### BEGIN LIBTOOL CONFIG -$as_echo "#define HAVE_SS_FAMILY_IN_SS 1" >>confdefs.h +# A sed program that does not truncate output. +SED=$lt_SED - ;; -esac +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="\$SED -e 1s/^X//" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __ss_family field in struct sockaddr_storage" >&5 -$as_echo_n "checking for __ss_family field in struct sockaddr_storage... " >&6; } -if test "${ac_cv_have___ss_family_in_struct_ss+set}" = set; then : - $as_echo_n "(cached) " >&6 -else +# A grep program that handles long lines. +GREP=$lt_GREP - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# An ERE matcher. +EGREP=$lt_EGREP -#include -#include +# A literal string matcher. +FGREP=$lt_FGREP -int -main () -{ - struct sockaddr_storage s; s.__ss_family = 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_have___ss_family_in_struct_ss="yes" -else - ac_cv_have___ss_family_in_struct_ss="no" +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +# An echo program that protects backslashes. +ECHO=$lt_ECHO -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_family_in_struct_ss" >&5 -$as_echo "$ac_cv_have___ss_family_in_struct_ss" >&6; } -case "$ac_cv_have___ss_family_in_struct_ss" in - yes) +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared -$as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h +# Which release of libtool.m4 was used? +macro_version=$macro_version +macro_revision=$macro_revision - ;; -esac +# Whether or not to build static libraries. +build_old_libs=$enable_static -case "$ac_cv_have_ss_family_in_struct_ss$ac_cv_have___ss_family_in_struct_ss" in - noyes) +# What type of objects to build. +pic_mode=$pic_mode -cat >>confdefs.h <<_ACEOF -#define ss_family __ss_family -_ACEOF +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os -cat >>confdefs.h <<_ACEOF -#define ss_len __ss_len -_ACEOF +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os - ;; -esac +# A BSD- or MS-compatible name lister. +NM=$lt_NM -# Checks for library functions. -#AC_FUNC_MEMCMP dnl HMS: we don't have a memcmp.c to use here, so why bother? -if test "${ac_cv_func_setvbuf_reversed+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_func_setvbuf_reversed=no -fi +# Whether we need soft or hard links. +LN_S=$lt_LN_S +# What is the maximum length of a command? +max_cmd_len=$max_cmd_len -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 -$as_echo_n "checking return type of signal handlers... " >&6; } -if test "${ac_cv_type_signal+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include +# Object file suffix (normally "o"). +objext=$ac_objext -int -main () -{ -return *(signal (0, 0)) (0) == 1; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_type_signal=int -else - ac_cv_type_signal=void -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 -$as_echo "$ac_cv_type_signal" >&6; } +# Executable file suffix (normally ""). +exeext=$exeext -cat >>confdefs.h <<_ACEOF -#define RETSIGTYPE $ac_cv_type_signal -_ACEOF +# whether the shell understands "unset". +lt_unset=$lt_unset +# turn spaces into newlines. +SP2NL=$lt_lt_SP2NL -for ac_func in alarm -do : - ac_fn_c_check_func "$LINENO" "alarm" "ac_cv_func_alarm" -if test "x$ac_cv_func_alarm" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_ALARM 1 -_ACEOF +# turn newlines into spaces. +NL2SP=$lt_lt_NL2SP -fi -done +# convert \$build file names to \$host format. +to_host_file_cmd=$lt_cv_to_host_file_cmd -ac_fn_c_check_func "$LINENO" "gethostent" "ac_cv_func_gethostent" -if test "x$ac_cv_func_gethostent" = x""yes; then : +# convert \$build files to toolchain format. +to_tool_file_cmd=$lt_cv_to_tool_file_cmd -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostent" >&5 -$as_echo_n "checking for library containing gethostent... " >&6; } -if test "${ac_cv_search_gethostent+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# An object symbol dumper. +OBJDUMP=$lt_OBJDUMP -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char gethostent (); -int -main () -{ -return gethostent (); - ; - return 0; -} -_ACEOF -for ac_lib in '' nsl; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib -lsocket $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_gethostent=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_gethostent+set}" = set; then : - break -fi -done -if test "${ac_cv_search_gethostent+set}" = set; then : +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -else - ac_cv_search_gethostent=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostent" >&5 -$as_echo "$ac_cv_search_gethostent" >&6; } -ac_res=$ac_cv_search_gethostent -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +# Command to use when deplibs_check_method = "file_magic". +file_magic_cmd=$lt_file_magic_cmd -fi +# How to find potential files when deplibs_check_method = "file_magic". +file_magic_glob=$lt_file_magic_glob -fi +# Find potential files using nocaseglob when deplibs_check_method = "file_magic". +want_nocaseglob=$lt_want_nocaseglob -for ac_func in gettimeofday inet_ntoa memset -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -eval as_val=\$$as_ac_var - if test "x$as_val" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +# DLL creation program. +DLLTOOL=$lt_DLLTOOL -fi -done +# Command to associate shared and link libraries. +sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd -for ac_func in socket -do : - ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket" -if test "x$ac_cv_func_socket" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SOCKET 1 -_ACEOF +# The archiver. +AR=$lt_AR -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5 -$as_echo_n "checking for library containing socket... " >&6; } -if test "${ac_cv_search_socket+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# Flags to create an archive. +AR_FLAGS=$lt_AR_FLAGS -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char socket (); -int -main () -{ -return socket (); - ; - return 0; -} -_ACEOF -for ac_lib in '' socket; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_socket=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_socket+set}" = set; then : - break -fi -done -if test "${ac_cv_search_socket+set}" = set; then : +# How to feed a file listing to the archiver. +archiver_list_spec=$lt_archiver_list_spec -else - ac_cv_search_socket=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5 -$as_echo "$ac_cv_search_socket" >&6; } -ac_res=$ac_cv_search_socket -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +# A symbol stripping program. +STRIP=$lt_STRIP -fi +# Commands used to install an old-style archive. +RANLIB=$lt_RANLIB +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds -fi -done +# Whether to use a lock for old archive extraction. +lock_old_archive_extraction=$lock_old_archive_extraction -for ac_func in sqrt -do : - ac_fn_c_check_func "$LINENO" "sqrt" "ac_cv_func_sqrt" -if test "x$ac_cv_func_sqrt" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_SQRT 1 -_ACEOF +# A C compiler. +LTCC=$lt_CC -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sqrt" >&5 -$as_echo_n "checking for library containing sqrt... " >&6; } -if test "${ac_cv_search_sqrt+set}" = set; then : - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ +# LTCC compiler flags. +LTCFLAGS=$lt_CFLAGS -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char sqrt (); -int -main () -{ -return sqrt (); - ; - return 0; -} -_ACEOF -for ac_lib in '' m; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO"; then : - ac_cv_search_sqrt=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext - if test "${ac_cv_search_sqrt+set}" = set; then : - break -fi -done -if test "${ac_cv_search_sqrt+set}" = set; then : +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe -else - ac_cv_search_sqrt=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sqrt" >&5 -$as_echo "$ac_cv_search_sqrt" >&6; } -ac_res=$ac_cv_search_sqrt -if test "$ac_res" != no; then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +# Transform the output of nm in a proper C declaration. +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl -fi +# Transform the output of nm in a C name address pair. +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address -fi -done +# Transform the output of nm in a C name address pair when lib prefix is needed. +global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix -for ac_func in strrchr -do : - ac_fn_c_check_func "$LINENO" "strrchr" "ac_cv_func_strrchr" -if test "x$ac_cv_func_strrchr" = x""yes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_STRRCHR 1 -_ACEOF +# Specify filename containing input files for \$NM. +nm_file_list_spec=$lt_nm_file_list_spec -fi -done +# The root where to search for dependent libraries,and in which our libraries should be installed. +lt_sysroot=$lt_sysroot +# The name of the directory that contains temporary libtool files. +objdir=$objdir -case "$host" in - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in - yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; - esac - ;; - *-*-linux*) - CFLAGS="$CFLAGS -DADJTIME_MISSING" - ;; - *-*-sunos*) - CFLAGS="$CFLAGS -DNONBLOCK_BROKEN" - ;; -esac +# Used to examine libraries when file_magic_cmd begins with "file". +MAGIC_CMD=$MAGIC_CMD -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for bin subdirectory" >&5 -$as_echo_n "checking for bin subdirectory... " >&6; } +# Must we lock files when doing compilation? +need_locks=$lt_need_locks -# Check whether --with-binsubdir was given. -if test "${with_binsubdir+set}" = set; then : - withval=$with_binsubdir; use_binsubdir="$withval" -else - use_binsubdir="bin" -fi +# Manifest tool. +MANIFEST_TOOL=$lt_MANIFEST_TOOL +# Tool to manipulate archived DWARF debug symbol files on Mac OS X. +DSYMUTIL=$lt_DSYMUTIL -case "$use_binsubdir" in - bin) - ;; - sbin) - ;; - *) - as_fn_error "<$use_binsubdir> is illegal - must be \"bin\" or \"sbin\"" "$LINENO" 5 - ;; -esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_binsubdir" >&5 -$as_echo "$use_binsubdir" >&6; } -BINSUBDIR=$use_binsubdir +# Tool to change global to local symbols on Mac OS X. +NMEDIT=$lt_NMEDIT +# Tool to manipulate fat objects and archives on Mac OS X. +LIPO=$lt_LIPO -ac_config_files="$ac_config_files Makefile" +# ldd/readelf like tool for Mach-O binaries on Mac OS X. +OTOOL=$lt_OTOOL -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. +# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. +OTOOL64=$lt_OTOOL64 -_ACEOF +# Old archive suffix (normally "a"). +libext=$libext -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done +# Shared library suffix (normally ".so"). +shrext_cmds=$lt_shrext_cmds - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - test "x$cache_file" != "x/dev/null" && - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file - else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' +# Variables whose values should be saved in libtool wrapper scripts and +# restored at link time. +variables_saved_for_relink=$lt_variables_saved_for_relink + +# Do we need the "lib" prefix for modules? +need_lib_prefix=$need_lib_prefix + +# Do we need a version for libraries? +need_version=$need_version + +# Library versioning type. +version_type=$version_type + +# Shared library runtime path variable. +runpath_var=$runpath_var + +# Shared library path variable. +shlibpath_var=$shlibpath_var + +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath + +# Format of library name prefix. +libname_spec=$lt_libname_spec + +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME +library_names_spec=$lt_library_names_spec + +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec + +# Permission mode override for installation of shared libraries. +install_override_mode=$lt_install_override_mode + +# Command to use after installation of a shared archive. +postinstall_cmds=$lt_postinstall_cmds -DEFS=-DHAVE_CONFIG_H +# Command to use after uninstallation of a shared archive. +postuninstall_cmds=$lt_postuninstall_cmds -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds -LTLIBOBJS=$ac_ltlibobjs +# As "finish_cmds", except a single script fragment to be evaled but +# not shown. +finish_eval=$lt_finish_eval +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi +# Compile-time system search path for libraries. +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - as_fn_error "conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then - as_fn_error "conditional \"INSTALL_LIBOPTS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${NEED_LIBOPTS_TRUE}" && test -z "${NEED_LIBOPTS_FALSE}"; then - as_fn_error "conditional \"NEED_LIBOPTS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi +# Run-time system search path for libraries. +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec -: ${CONFIG_STATUS=./config.status} -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. +# Whether dlopen is supported. +dlopen_support=$enable_dlopen -debug=false -ac_cs_recheck=false -ac_cs_silent=false +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi +# The linker used to build libraries. +LD=$lt_LD -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" +# A language specific compiler. +CC=$lt_compiler -# Find who we are. Look in the path if we contain no directory separator. -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break - done -IFS=$as_save_IFS +# Is the compiler the GNU compiler? +with_gcc=$GCC - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o -# as_fn_error ERROR [LINENO LOG_FD] -# --------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with status $?, using 1 if that was 0. -as_fn_error () -{ - as_status=$?; test $as_status -eq 0 && as_status=1 - if test "$3"; then - as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 - fi - $as_echo "$as_me: error: $1" >&2 - as_fn_exit $as_status -} # as_fn_error +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac +# If ld is used when linking, flag to hardcode \$libdir into a binary +# during linking. This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -p' - fi -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \${shlibpath_var} if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' -else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= - fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in #( - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' -fi -as_executable_p=$as_test_x +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by $as_me, which was -generated by GNU Autoconf 2.65. Invocation command line was +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds -_ACEOF +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action -case $ac_config_headers in *" -"*) set x $ac_config_headers; shift; ac_config_headers=$*;; -esac +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects +postdep_objects=$lt_postdep_objects +predeps=$lt_predeps +postdeps=$lt_postdeps -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_headers="$ac_config_headers" -config_commands="$ac_config_commands" +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path -_ACEOF +# ### END LIBTOOL CONFIG -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. +_LT_EOF -Usage: $0 [OPTION]... [TAG]... + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - --header=FILE[:TEMPLATE] - instantiate the configuration header FILE -Configuration files: -$config_files +ltmain="$ac_aux_dir/ltmain.sh" + + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + if test x"$xsi_shell" = xyes; then + sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ +func_dirname ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_basename ()$/,/^} # func_basename /c\ +func_basename ()\ +{\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ +func_dirname_and_basename ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ +func_stripname ()\ +{\ +\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ +\ # positional parameters, so assign one to ordinary parameter first.\ +\ func_stripname_result=${3}\ +\ func_stripname_result=${func_stripname_result#"${1}"}\ +\ func_stripname_result=${func_stripname_result%"${2}"}\ +} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ +func_split_long_opt ()\ +{\ +\ func_split_long_opt_name=${1%%=*}\ +\ func_split_long_opt_arg=${1#*=}\ +} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ +func_split_short_opt ()\ +{\ +\ func_split_short_opt_arg=${1#??}\ +\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ +} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ +func_lo2o ()\ +{\ +\ case ${1} in\ +\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ +\ *) func_lo2o_result=${1} ;;\ +\ esac\ +} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_xform ()$/,/^} # func_xform /c\ +func_xform ()\ +{\ + func_xform_result=${1%.*}.lo\ +} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_arith ()$/,/^} # func_arith /c\ +func_arith ()\ +{\ + func_arith_result=$(( $* ))\ +} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_len ()$/,/^} # func_len /c\ +func_len ()\ +{\ + func_len_result=${#1}\ +} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + +fi + +if test x"$lt_shell_append" = xyes; then + sed -e '/^func_append ()$/,/^} # func_append /c\ +func_append ()\ +{\ + eval "${1}+=\\${2}"\ +} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ +func_append_quoted ()\ +{\ +\ func_quote_for_eval "${2}"\ +\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ +} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi + +if test x"$_lt_function_replace_fail" = x":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} +fi + + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" -Configuration headers: -$config_headers -Configuration commands: -$config_commands + cat <<_LT_EOF >> "$ofile" -Report bugs to the package provider." +# ### BEGIN LIBTOOL TAG CONFIG: CXX -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" -ac_cs_version="\\ -config.status -configured by $0, generated by GNU Autoconf 2.65, - with options \\"\$ac_cs_config\\" +# The linker used to build libraries. +LD=$lt_LD_CXX -Copyright (C) 2009 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." +# How to create reloadable object files. +reload_flag=$lt_reload_flag_CXX +reload_cmds=$lt_reload_cmds_CXX -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds_CXX -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac +# A language specific compiler. +CC=$lt_compiler_CXX - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --header | --heade | --head | --hea ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_HEADERS " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h) - # Conflict between --help and --header - as_fn_error "ambiguous option: \`$1' -Try \`$0 --help' for more information.";; - --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; +# Is the compiler the GNU compiler? +with_gcc=$GCC_CXX - # This is an error. - -*) as_fn_error "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_CXX - esac - shift -done +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_CXX -ac_configure_extra_args= +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_CXX -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_CXX -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX -_ACEOF +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object_CXX -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "libopts/Makefile") CONFIG_FILES="$CONFIG_FILES libopts/Makefile" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX - *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds_CXX +archive_expsym_cmds=$lt_archive_expsym_cmds_CXX -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands -fi +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds_CXX +module_expsym_cmds=$lt_module_expsym_cmds_CXX -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= - trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld_CXX -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -n "$tmp" && test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_CXX -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_CXX +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\r' -else - ac_cs_awk_cr=$ac_cr -fi +# If ld is used when linking, flag to hardcode \$libdir into a binary +# during linking. This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX -echo 'BEGIN {' >"$tmp/subs1.awk" && -_ACEOF +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct_CXX -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \${shlibpath_var} if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute_CXX - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L_CXX -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic_CXX - print line -} +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath_CXX -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ - || as_fn_error "could not setup config files machinery" "$LINENO" 5 -_ACEOF +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_CXX -# VPATH may cause trouble with some makes, so we remove $(srcdir), -# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=/{ -s/:*\$(srcdir):*/:/ -s/:*\${srcdir}:*/:/ -s/:*@srcdir@:*/:/ -s/^\([^=]*=[ ]*\):*/\1/ -s/:*$// -s/^[^=]*=[ ]*$// -}' -fi +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols_CXX -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_CXX -# Set up the scripts for CONFIG_HEADERS section. -# No need to generate them if there are no CONFIG_HEADERS. -# This happens for instance with `./config.status Makefile'. -if test -n "$CONFIG_HEADERS"; then -cat >"$tmp/defines.awk" <<\_ACAWK || -BEGIN { -_ACEOF +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_CXX -# Transform confdefs.h into an awk script `defines.awk', embedded as -# here-document in config.status, that substitutes the proper values into -# config.h.in to produce config.h. +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_CXX -# Create a delimiter string that does not exist in confdefs.h, to ease -# handling of long lines. -ac_delim='%!_!# ' -for ac_last_try in false false :; do - ac_t=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_t"; then - break - elif $ac_last_try; then - as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds_CXX -# For the awk script, D is an array of macro values keyed by name, -# likewise P contains macro parameters if any. Preserve backslash -# newline sequences. +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds_CXX -ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* -sed -n ' -s/.\{148\}/&'"$ac_delim"'/g -t rset -:rset -s/^[ ]*#[ ]*define[ ][ ]*/ / -t def -d -:def -s/\\$// -t bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3"/p -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p -d -:bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3\\\\\\n"\\/p -t cont -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p -t cont -d -:cont -n -s/.\{148\}/&'"$ac_delim"'/g -t clear -:clear -s/\\$// -t bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/"/p -d -:bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p -b cont -' >$CONFIG_STATUS || ac_write_fail=1 +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec_CXX -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - for (key in D) D_is_set[key] = 1 - FS = "" -} -/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { - line = \$ 0 - split(line, arg, " ") - if (arg[1] == "#") { - defundef = arg[2] - mac1 = arg[3] - } else { - defundef = substr(arg[1], 2) - mac1 = arg[2] - } - split(mac1, mac2, "(") #) - macro = mac2[1] - prefix = substr(line, 1, index(line, defundef) - 1) - if (D_is_set[macro]) { - # Preserve the white space surrounding the "#". - print prefix "define", macro P[macro] D[macro] - next - } else { - # Replace #undef with comments. This is necessary, for example, - # in the case of _POSIX_SOURCE, which is predefined and required - # on some systems where configure will not decide to define it. - if (defundef == "undef") { - print "/*", prefix defundef, macro, "*/" - next - } - } -} -{ print } -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - as_fn_error "could not setup config headers machinery" "$LINENO" 5 -fi # test -n "$CONFIG_HEADERS" +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_CXX +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX + +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects_CXX +postdep_objects=$lt_postdep_objects_CXX +predeps=$lt_predeps_CXX +postdeps=$lt_postdeps_CXX + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_CXX + +# ### END LIBTOOL TAG CONFIG: CXX +_LT_EOF + + ;; -eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift +done # for ac_tag - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} +as_fn_exit 0 +_ACEOF +ac_clean_files=$ac_clean_files_save + +test $ac_write_fail = 0 || + as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 + + +# configure is writing to config.log, and then calls config.status. +# config.status does its own redirection, appending to config.log. +# Unfortunately, on DOS this fails, as config.log is still kept open +# by configure, so config.status won't be able to write to it; its +# output is simply discarded. So we exec the FD to /dev/null, +# effectively closing config.log, so it can be properly (re)opened and +# appended to by config.status. When coming back to configure, we +# need to make the FD available again. +if test "$no_create" != yes; then + ac_cs_success=: + ac_config_status_args= + test "$silent" = yes && + ac_config_status_args="$ac_config_status_args --quiet" + exec 5>/dev/null + $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false + exec 5>>config.log + # Use ||, not &&, to avoid exiting from the if with $? = 1, which + # would make configure fail if this is the last instruction. + $ac_cs_success || as_fn_exit 1 +fi + +# +# CONFIG_SUBDIRS section. +# +if test "$no_recursion" != yes; then + + # Remove --cache-file, --srcdir, and --disable-option-checking arguments + # so they do not pile up. + ac_sub_configure_args= + ac_prev= + eval "set x $ac_configure_args" + shift + for ac_arg + do + if test -n "$ac_prev"; then + ac_prev= + continue fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; + case $ac_arg in + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \ + | --c=*) + ;; + --config-cache | -C) + ;; + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + ;; + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + ;; + --disable-option-checking) + ;; + *) + case $ac_arg in + *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append ac_sub_configure_args " '$ac_arg'" ;; esac + done - case $ac_tag in - *:-:* | *:-) cat >"$tmp/stdin" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; + # Always prepend --prefix to ensure using the same prefix + # in subdir configurations. + ac_arg="--prefix=$prefix" + case $ac_arg in + *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac + ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args" - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. + # Pass --silent + if test "$silent" = yes; then + ac_sub_configure_args="--silent $ac_sub_configure_args" + fi + + # Always prepend --disable-option-checking to silence warnings, since + # different subdirs can have different --enable and --with options. + ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args" + + ac_popdir=`pwd` + for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue + + # Do not complain, so a configure script can configure whichever + # parts of a large source tree are present. + test -d "$srcdir/$ac_dir" || continue + + ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)" + $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5 + $as_echo "$ac_msg" >&6 + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; @@ -16542,289 +33324,41 @@ esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&2;} + cd "$ac_dir" - rm -f "$tmp/stdin" - case $ac_file in - -) cat "$tmp/out" && rm -f "$tmp/out";; - *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; - esac \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - ;; - :H) - # - # CONFIG_HEADER - # - if test x"$ac_file" != x-; then - { - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" - } >"$tmp/config.h" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 - if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then - { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 -$as_echo "$as_me: $ac_file is unchanged" >&6;} + # Check for guested configure; otherwise get Cygnus style configure. + if test -f "$ac_srcdir/configure.gnu"; then + ac_sub_configure=$ac_srcdir/configure.gnu + elif test -f "$ac_srcdir/configure"; then + ac_sub_configure=$ac_srcdir/configure + elif test -f "$ac_srcdir/configure.in"; then + # This should be Cygnus configure. + ac_sub_configure=$ac_aux_dir/configure else - rm -f "$ac_file" - mv "$tmp/config.h" "$ac_file" \ - || as_fn_error "could not create $ac_file" "$LINENO" 5 + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5 +$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;} + ac_sub_configure= fi - else - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ - || as_fn_error "could not create -" "$LINENO" 5 - fi -# Compute "$ac_file"'s index in $config_headers. -_am_arg="$ac_file" -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || -$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$_am_arg" : 'X\(//\)[^/]' \| \ - X"$_am_arg" : 'X\(//\)$' \| \ - X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$_am_arg" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'`/stamp-h$_am_stamp_count - ;; - - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac + # The recursion is here. + if test -n "$ac_sub_configure"; then + # Make the cache file name correct relative to the subdirectory. + case $cache_file in + [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;; + *) # Relative name. + ac_sub_cache_file=$ac_top_build_prefix$cache_file ;; + esac - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Autoconf 2.62 quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - else - continue + { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5 +$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;} + # The eval makes quoting arguments work. + eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \ + --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" || + as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5 fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir=$dirpart/$fdir; as_fn_mkdir_p - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} - ;; - - esac -done # for ac_tag - - -as_fn_exit 0 -_ACEOF -ac_clean_files=$ac_clean_files_save - -test $ac_write_fail = 0 || - as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit $? + cd "$ac_popdir" + done fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 diff --git a/contrib/ntp/sntp/configure.ac b/contrib/ntp/sntp/configure.ac index be6943ff9..a08aa1347 100644 --- a/contrib/ntp/sntp/configure.ac +++ b/contrib/ntp/sntp/configure.ac @@ -1,21 +1,86 @@ -# Process this file with autoconf to produce a configure script. -AC_INIT(main.c) -AM_INIT_AUTOMAKE([msntp],[1.6]) -AC_CONFIG_SRCDIR([header.h]) +dnl SNTP subpackage configure.ac -*- Autoconf -*- +dnl +m4_include([m4/version.m4]) +AC_PREREQ([2.61]) +AC_INIT( + [sntp], + [VERSION_NUMBER], + [http://bugs.ntp.org./], + [], + [http://www.ntp.org./]dnl +) +AC_CONFIG_MACRO_DIR([m4]) +AC_CONFIG_AUX_DIR([libevent/build-aux]) +AC_LANG([C]) + +# Bump sntp_configure_cache_version for each change to configure.ac or +# .m4 files which invalidates cached values from previous configure +# runs. +# +# If the change affects cache variables used only by the main NTP +# configure.ac, then only its version number should be bumped, while +# the subdir configure.ac version numbers should be unchanged. The +# same is true for a test/variable that is used only by one subdir +# being changed incompatibly; only that subdir's cache version needs +# bumping. +# +# If a change affects variables shared by all NTP configure scripts, +# please bump the version numbers of each. If you are not sure, the +# safe choice is to bump all on any cache-invalidating change. +# +# In order to avoid the risk of version stamp collision between -stable +# and -dev branches, do not simply increment the version, instead use +# the date YYYYMMDD optionally with -HHMM if there is more than one +# bump in a day. + +sntp_configure_cache_version=20120806 + +# When the version of config.cache and configure do not +# match, NTP_CACHEVERSION will flush the cache. + +NTP_CACHEVERSION([sntp], [$sntp_configure_cache_version]) + +AM_INIT_AUTOMAKE([1.10 foreign -Wall -Wno-gnu]) +dnl AM_SILENT_RULES req. automake 1.11. [yes] defaults V=0 +m4_ifdef( + [AM_SILENT_RULES], + [AM_SILENT_RULES([yes])] +) +AC_CANONICAL_BUILD AC_CANONICAL_HOST -AM_CONFIG_HEADER(config.h) +dnl the 'build' machine is where we run configure and compile +dnl the 'host' machine is where the resulting stuff runs. +AC_DEFINE_UNQUOTED([STR_SYSTEM], "$host", [canonical system (cpu-vendor-os) of where we should run]) +AC_CONFIG_HEADER([config.h]) +dnl AC_ARG_PROGRAM -# Checks for programs. -AC_PROG_CC +NTP_PROG_CC -# So far, the only shared library we might use is libopts. -# It's a small library - we might as well use a static version of it. -AC_DISABLE_SHARED +NTP_LOCINFO() + +dnl AM_PROG_AR req. automake 1.12 +m4_ifdef( + [AM_PROG_AR], + [AM_PROG_AR] +) -m4_defun([_LT_AC_LANG_CXX_CONFIG], [:]) -m4_defun([_LT_AC_LANG_F77_CONFIG], [:]) +NTP_LIBNTP +AC_DISABLE_SHARED AC_PROG_LIBTOOL +AC_SUBST([LIBTOOL_DEPS]) + +NTP_WITHSNTP + +case "$SNTP" in + '') + SNTP_DB= + SNTP_DL= + SNTP_DS= + ;; +esac + +### # NTP has (so far) been relying on leading-edge autogen. # Therefore, by default: @@ -30,130 +95,64 @@ case "${enable_libopts_install+set}" in set) ;; *) enable_libopts_install=no ;; esac +enable_nls=no LIBOPTS_CHECK -AC_MSG_CHECKING([[if $CC can handle #warning]]) -AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[#warning foo]])],[ac_cv_cpp_warning=yes],[ac_cv_cpp_warning=no]) -AC_MSG_RESULT([$ac_cv_cpp_warning]) +# From when we only used libevent for sntp: +#AM_COND_IF( +# [BUILD_SNTP], +# [NTP_LIBEVENT_CHECK], +# [NTP_LIBEVENT_CHECK_NOBUILD] +#) -case "$ac_cv_cpp_warning" in - no) - AC_DEFINE([NO_OPTION_NAME_WARNINGS], [1], [Should we avoid #warning on option name collisions?]) - AC_MSG_RESULT([[Enabling NO_OPTION_NAME_WARNINGS as #warning does not work]]) - ;; -esac +NTP_LIBEVENT_CHECK([2]) -AC_C_INLINE - -case "$ac_cv_c_inline" in - '') - ;; - *) - AC_DEFINE(HAVE_INLINE,1,[inline keyword or macro available]) - AC_SUBST(HAVE_INLINE) -esac +# Checks for libraries. +dnl NTP_LIBNTP checks for inet_XtoY +dnl AC_SEARCH_LIBS([inet_pton], [nsl]) -# Checks for libraries. +dnl AC_SEARCH_LIBS([openlog], [gen syslog]) +LIB_SYSLOG='' +AC_SUBST([LIB_SYSLOG]) +HMS_SEARCH_LIBS([LIB_SYSLOG], [openlog], [gen syslog]) # Checks for header files. -AC_HEADER_STDC -AC_CHECK_HEADERS([arpa/inet.h fcntl.h float.h limits.h netdb.h netinet/in.h stdlib.h string.h sys/socket.h sys/time.h syslog.h unistd.h]) +AC_CHECK_HEADERS([netdb.h string.h strings.h syslog.h]) +NTP_SYSEXITS_H +NTP_FACILITYNAMES # Checks for typedefs, structures, and compiler characteristics. -AC_C_CONST -AC_TYPE_SIZE_T -AC_HEADER_TIME -AC_STRUCT_TM - -AC_CACHE_CHECK([for ss_family field in struct sockaddr_storage], - ac_cv_have_ss_family_in_struct_ss, [ - AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.ss_family = 1; ], - [ ac_cv_have_ss_family_in_struct_ss="yes" ], - [ ac_cv_have_ss_family_in_struct_ss="no" ], - ) -]) -case "$ac_cv_have_ss_family_in_struct_ss" in - yes) - AC_DEFINE(HAVE_SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have ss_family?]) - ;; -esac +AC_HEADER_STDBOOL -AC_CACHE_CHECK([for __ss_family field in struct sockaddr_storage], - ac_cv_have___ss_family_in_struct_ss, [ - AC_TRY_COMPILE( - [ -#include -#include - ], - [ struct sockaddr_storage s; s.__ss_family = 1; ], - [ ac_cv_have___ss_family_in_struct_ss="yes" ], - [ ac_cv_have___ss_family_in_struct_ss="no" ] - ) -]) -case "$ac_cv_have___ss_family_in_struct_ss" in - yes) - AC_DEFINE(HAVE___SS_FAMILY_IN_SS, 1, [Does struct sockaddr_storage have __ss_family?]) - ;; -esac +NTP_OPENSSL +NTP_IPV6 -case "$ac_cv_have_ss_family_in_struct_ss$ac_cv_have___ss_family_in_struct_ss" in - noyes) - AC_DEFINE_UNQUOTED([ss_family], [__ss_family], [normalize ss_family access]) - AC_DEFINE_UNQUOTED([ss_len], [__ss_len], [normalize ss_len access]) - ;; -esac +### + +# Hacks +# these need work if we're to move libntp under sntp +AC_DEFINE([HAVE_NO_NICE], 1, [sntp does not care about 'nice']) +AC_DEFINE([HAVE_TERMIOS], 1, [sntp does not care about TTY stuff]) # Checks for library functions. -#AC_FUNC_MEMCMP dnl HMS: we don't have a memcmp.c to use here, so why bother? -AC_FUNC_SETVBUF_REVERSED -AC_TYPE_SIGNAL -AC_CHECK_FUNCS([alarm]) -AC_CHECK_FUNC([gethostent], , AC_SEARCH_LIBS([gethostent], [nsl], , , [-lsocket])) -AC_CHECK_FUNCS([gettimeofday inet_ntoa memset]) -AC_CHECK_FUNCS([socket], , AC_SEARCH_LIBS([socket], [socket])) -AC_CHECK_FUNCS([sqrt], , AC_SEARCH_LIBS([sqrt], [m])) -AC_CHECK_FUNCS([strrchr]) - -case "$host" in - *-*-hpux10.*) # at least for hppa2.0-hp-hpux10.20 - case "$GCC" in - yes) - ;; - *) CFLAGS="$CFLAGS -Wp,-H18816" - ;; - esac - ;; - *-*-linux*) - CFLAGS="$CFLAGS -DADJTIME_MISSING" - ;; - *-*-sunos*) - CFLAGS="$CFLAGS -DNONBLOCK_BROKEN" - ;; -esac +AC_CHECK_FUNCS([socket]) -AC_MSG_CHECKING(for bin subdirectory) -AC_ARG_WITH(binsubdir, - AC_HELP_STRING([--with-binsubdir], [bin ={bin,sbin}]), - use_binsubdir="$withval", use_binsubdir="bin") +NTP_UNITYBUILD +# HMS: if we don't find c++ we should not look for gtest. +AC_PROG_CXX +NTP_GOOGLETEST -case "$use_binsubdir" in - bin) - ;; - sbin) - ;; - *) - AC_MSG_ERROR([<$use_binsubdir> is illegal - must be "bin" or "sbin"]) - ;; -esac -AC_MSG_RESULT($use_binsubdir) -BINSUBDIR=$use_binsubdir -AC_SUBST(BINSUBDIR) +# All libraries should be in various LIB_* variables now. +#LIBS= +# Sadly not. There is a gettext() check somewhere, and on Solaris this pulls +# in -lintl -lgen, outside our "scope". AC_CONFIG_FILES([Makefile]) +AC_CONFIG_FILES([include/Makefile]) +AC_CONFIG_FILES([scripts/Makefile]) +AC_CONFIG_FILES([tests/Makefile]) +AC_CONFIG_FILES([tests/fileHandlingTest.h]) +AC_CONFIG_FILES([unity/Makefile]) + AC_OUTPUT diff --git a/contrib/ntp/sntp/crypto.c b/contrib/ntp/sntp/crypto.c new file mode 100644 index 000000000..b178f8c2e --- /dev/null +++ b/contrib/ntp/sntp/crypto.c @@ -0,0 +1,192 @@ +#include +#include "crypto.h" +#include + +struct key *key_ptr; +size_t key_cnt = 0; + +int +make_mac( + char *pkt_data, + int pkt_size, + int mac_size, + struct key *cmp_key, + char * digest + ) +{ + u_int len = mac_size; + int key_type; + EVP_MD_CTX ctx; + + if (cmp_key->key_len > 64) + return 0; + if (pkt_size % 4 != 0) + return 0; + + INIT_SSL(); + key_type = keytype_from_text(cmp_key->type, NULL); + EVP_DigestInit(&ctx, EVP_get_digestbynid(key_type)); + EVP_DigestUpdate(&ctx, (u_char *)cmp_key->key_seq, (u_int)cmp_key->key_len); + EVP_DigestUpdate(&ctx, (u_char *)pkt_data, (u_int)pkt_size); + EVP_DigestFinal(&ctx, (u_char *)digest, &len); + + return (int)len; +} + + +/* Generates a md5 digest of the key specified in keyid concatinated with the + * ntp packet (exluding the MAC) and compares this digest to the digest in + * the packet's MAC. If they're equal this function returns 1 (packet is + * authentic) or else 0 (not authentic). + */ +int +auth_md5( + char *pkt_data, + int pkt_size, + int mac_size, + struct key *cmp_key + ) +{ + int hash_len; + int authentic; + char digest[20]; + + if (mac_size > (int)sizeof(digest)) + return 0; + hash_len = make_mac(pkt_data, pkt_size, sizeof(digest), cmp_key, + digest); + if (!hash_len) + authentic = FALSE; + else + authentic = !memcmp(digest, pkt_data + pkt_size + 4, + hash_len); + return authentic; +} + +static int +hex_val( + unsigned char x + ) +{ + int val; + + if ('0' <= x && x <= '9') + val = x - '0'; + else if ('a' <= x && x <= 'f') + val = x - 'a' + 0xa; + else if ('A' <= x && x <= 'F') + val = x - 'A' + 0xA; + else + val = -1; + + return val; +} + +/* Load keys from the specified keyfile into the key structures. + * Returns -1 if the reading failed, otherwise it returns the + * number of keys it read + */ +int +auth_init( + const char *keyfile, + struct key **keys + ) +{ + FILE *keyf = fopen(keyfile, "r"); + struct key *prev = NULL; + int scan_cnt, line_cnt = 0; + char kbuf[200]; + char keystring[129]; + + if (keyf == NULL) { + if (debug) + printf("sntp auth_init: Couldn't open key file %s for reading!\n", keyfile); + return -1; + } + if (feof(keyf)) { + if (debug) + printf("sntp auth_init: Key file %s is empty!\n", keyfile); + fclose(keyf); + return -1; + } + key_cnt = 0; + while (!feof(keyf)) { + char * octothorpe; + struct key *act; + int goodline = 0; + + if (NULL == fgets(kbuf, sizeof(kbuf), keyf)) + continue; + + kbuf[sizeof(kbuf) - 1] = '\0'; + octothorpe = strchr(kbuf, '#'); + if (octothorpe) + *octothorpe = '\0'; + act = emalloc(sizeof(*act)); + scan_cnt = sscanf(kbuf, "%d %9s %128s", &act->key_id, act->type, keystring); + if (scan_cnt == 3) { + int len = strlen(keystring); + if (len <= 20) { + act->key_len = len; + memcpy(act->key_seq, keystring, len + 1); + goodline = 1; + } else if ((len & 1) != 0) { + goodline = 0; /* it's bad */ + } else { + int j; + goodline = 1; + act->key_len = len >> 1; + for (j = 0; j < len; j+=2) { + int val; + val = (hex_val(keystring[j]) << 4) | + hex_val(keystring[j+1]); + if (val < 0) { + goodline = 0; /* it's bad */ + break; + } + act->key_seq[j>>1] = (char)val; + } + } + } + if (goodline) { + act->next = NULL; + if (NULL == prev) + *keys = act; + else + prev->next = act; + prev = act; + key_cnt++; + } else { + msyslog(LOG_DEBUG, "auth_init: scanf %d items, skipping line %d.", + scan_cnt, line_cnt); + free(act); + } + line_cnt++; + } + fclose(keyf); + + key_ptr = *keys; + return key_cnt; +} + +/* Looks for the key with keyid key_id and sets the d_key pointer to the + * address of the key. If no matching key is found the pointer is not touched. + */ +void +get_key( + int key_id, + struct key **d_key + ) +{ + struct key *itr_key; + + if (key_cnt == 0) + return; + for (itr_key = key_ptr; itr_key; itr_key = itr_key->next) { + if (itr_key->key_id == key_id) { + *d_key = itr_key; + break; + } + } + return; +} diff --git a/contrib/ntp/sntp/crypto.h b/contrib/ntp/sntp/crypto.h new file mode 100644 index 000000000..39e0e6b66 --- /dev/null +++ b/contrib/ntp/sntp/crypto.h @@ -0,0 +1,32 @@ +#ifndef CRYPTO_H +#define CRYPTO_H + +#include +#include +#include + +#include +#include +#include +#include /* provides OpenSSL digest API */ +#include "utilities.h" +#include "sntp-opts.h" + +#define LEN_PKT_MAC LEN_PKT_NOMAC + sizeof(u_int32) + +/* #include "sntp-opts.h" */ + +struct key { + struct key *next; + int key_id; + int key_len; + char type[10]; + char key_seq[64]; +}; + +int auth_init(const char *keyfile, struct key **keys); +void get_key(int key_id, struct key **d_key); +int make_mac(char *pkt_data, int pkt_size, int mac_size, struct key *cmp_key, char *digest); +int auth_md5(char *pkt_data, int pkt_size, int mac_size, struct key *cmp_key); + +#endif diff --git a/contrib/ntp/sntp/data_formats.h b/contrib/ntp/sntp/data_formats.h new file mode 100644 index 000000000..28848b216 --- /dev/null +++ b/contrib/ntp/sntp/data_formats.h @@ -0,0 +1,8 @@ +#ifndef DATA_FORMATS_H +#define DATA_FORMATS_H + +#include +#include +#include + +#endif diff --git a/contrib/ntp/sntp/deps-ver b/contrib/ntp/sntp/deps-ver new file mode 100644 index 000000000..596602f02 --- /dev/null +++ b/contrib/ntp/sntp/deps-ver @@ -0,0 +1 @@ +Mon Jan 31 21:14:29 UTC 2011 diff --git a/contrib/ntp/sntp/depsver.mf b/contrib/ntp/sntp/depsver.mf new file mode 100644 index 000000000..695f7303c --- /dev/null +++ b/contrib/ntp/sntp/depsver.mf @@ -0,0 +1,60 @@ +$(DEPDIR)/deps-ver: $(top_srcdir)/deps-ver + @[ -f $@ ] || \ + cp $(top_srcdir)/deps-ver $@ + @[ -w $@ ] || \ + chmod ug+w $@ + @cmp $(top_srcdir)/deps-ver $@ > /dev/null || ( \ + $(MAKE) $(AM_MAKEFLAGS) clean && \ + echo -n "Prior $(subdir)/$(DEPDIR) version " && \ + cat $@ && \ + rm -rf $(DEPDIR) && \ + mkdir $(DEPDIR) && \ + case "$(top_builddir)" in \ + .) \ + ./config.status Makefile depfiles \ + ;; \ + *) \ + cd "$(top_builddir)" && \ + ./config.status $(subdir)/Makefile depfiles && \ + cd $(subdir) \ + ;; \ + esac && \ + echo -n "Cleaned $(subdir)/$(DEPDIR) version " && \ + cat $(top_srcdir)/deps-ver \ + ) + cp $(top_srcdir)/deps-ver $@ + +.deps-ver: $(top_srcdir)/deps-ver + @[ ! -d $(DEPDIR) ] || $(MAKE) $(AM_MAKEFLAGS) $(DEPDIR)/deps-ver + @touch $@ + +BUILT_SOURCES += .deps-ver +CLEANFILES += .deps-ver + +# +# depsver.mf included in Makefile.am for directories with .deps +# +# When building in the same directory with sources that change over +# time, such as when tracking using bk, the .deps files can become +# stale with respect to moved, deleted, or superceded headers. Most +# commonly, this would exhibit as make reporting a failure to make a +# header file which is no longer in the location given. To address +# this issue, we use a deps-ver file which is updated with each change +# that breaks old .deps files. A copy of deps-ver is made into +# $(DEPDIR) if not already present. If $(DEPDIR)/deps-ver is present +# with different contents than deps-ver, we make clean to ensure all +# .o files built before the incompatible change are rebuilt along with +# their updated .deps files, then remove $(DEPDIR) and recreate it as +# empty stubs. +# +# It is normal when configured with --disable-dependency-tracking for +# the DEPDIR to not have been created. For this reason, we use the +# intermediate target .deps-ver, which invokes make recursively if +# DEPDIR exists. +# +# If you modify depsver.mf, please make the changes to the master +# copy, the one in sntp is copied by the bootstrap script from it. +# +# This comment block follows rather than leads the related code so that +# it stays with it in the generated Makefile.in and Makefile. +# diff --git a/contrib/ntp/sntp/header.h b/contrib/ntp/sntp/header.h deleted file mode 100644 index c752d1554..000000000 --- a/contrib/ntp/sntp/header.h +++ /dev/null @@ -1,87 +0,0 @@ -/* Copyright (C) 1996 N.M. Maclaren - Copyright (C) 1996 The University of Cambridge - -This includes all of the 'safe' headers and definitions used across modules. -No changes should be needed for any system that is even remotely like Unix. */ - - - -#include -#include -#include -#include -#include -#include - - - -#define VERSION "1.6" /* Just the version string */ -#define MAX_SOCKETS 10 /* Maximum number of addresses */ - -#ifndef LOCKNAME -# define LOCKNAME "/etc/sntp.pid" /* Stores the pid */ -#endif -#ifndef SAVENAME -# define SAVENAME "/etc/sntp.state" /* Stores the recovery state */ -#endif - - - -/* Defined in main.c */ - -#define op_client 1 /* Behave as a challenge client */ -#define op_listen 2 /* Behave as a listening client */ - -extern const char *argv0; - -extern int verbose, operation; - -extern const char *lockname; - -extern void fatal (int syserr, const char *message, const char *insert); - - - -/* Defined in unix.c */ - -extern void do_nothing (int seconds); - -extern int ftty (FILE *file); - -extern void set_lock (int lock); - -extern void log_message (const char *message); - - - -/* Defined in internet.c */ - -/* extern void find_address (struct in_addr *address, int *port, char *hostname, - int timespan); */ - -#define PREF_FAM_INET 1 -#define PREF_FAM_INET6 2 -extern void preferred_family(int); - - -/* Defined in socket.c */ - -extern void open_socket (int which, char *hostnames, int timespan); - -extern void write_socket (int which, void *packet, int length); - -extern int read_socket (int which, void *packet, int length, int waiting); - -extern int flush_socket (int which); - -extern void close_socket (int which); - - - -/* Defined in timing.c */ - -extern double current_time (double offset); - -extern time_t convert_time (double value, int *millisecs); - -extern void adjust_time (double difference, int immediate, double ignore); diff --git a/contrib/ntp/sntp/include/Makefile.am b/contrib/ntp/sntp/include/Makefile.am new file mode 100644 index 000000000..12227889a --- /dev/null +++ b/contrib/ntp/sntp/include/Makefile.am @@ -0,0 +1,19 @@ +NULL = + +EXTRA_DIST = \ + autogen-version.def \ + copyright.def \ + debug-opt.def \ + homerc.def \ + ntp.lic \ + version.def \ + version.texi \ + $(NULL) + +noinst_HEADERS = + +$(srcdir)/version.def: $(srcdir)/../../packageinfo.sh + cd .. && $(MAKE) $(AM_MAKEFLAGS) $(abs_top_srcdir)/include/version.def + +$(srcdir)/version.texi: $(srcdir)/../../packageinfo.sh + cd .. && $(MAKE) $(AM_MAKEFLAGS) $(abs_top_srcdir)/include/version.texi diff --git a/contrib/ntp/sntp/include/Makefile.in b/contrib/ntp/sntp/include/Makefile.in new file mode 100644 index 000000000..1c8a179dd --- /dev/null +++ b/contrib/ntp/sntp/include/Makefile.in @@ -0,0 +1,597 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = include +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/libopts/m4/libopts.m4 \ + $(top_srcdir)/libopts/m4/stdnoreturn.m4 \ + $(top_srcdir)/m4/hms_search_lib.m4 $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/ntp_cacheversion.m4 \ + $(top_srcdir)/m4/ntp_compiler.m4 \ + $(top_srcdir)/m4/ntp_crosscompile.m4 \ + $(top_srcdir)/m4/ntp_debug.m4 $(top_srcdir)/m4/ntp_dir_sep.m4 \ + $(top_srcdir)/m4/ntp_facilitynames.m4 \ + $(top_srcdir)/m4/ntp_googletest.m4 \ + $(top_srcdir)/m4/ntp_ipv6.m4 $(top_srcdir)/m4/ntp_lib_m.m4 \ + $(top_srcdir)/m4/ntp_libevent.m4 \ + $(top_srcdir)/m4/ntp_libntp.m4 \ + $(top_srcdir)/m4/ntp_lineeditlibs.m4 \ + $(top_srcdir)/m4/ntp_locinfo.m4 \ + $(top_srcdir)/m4/ntp_openssl.m4 \ + $(top_srcdir)/m4/ntp_pkg_config.m4 \ + $(top_srcdir)/m4/ntp_prog_cc.m4 $(top_srcdir)/m4/ntp_sntp.m4 \ + $(top_srcdir)/m4/ntp_sysexits.m4 \ + $(top_srcdir)/m4/ntp_unitytest.m4 \ + $(top_srcdir)/m4/ntp_ver_suffix.m4 \ + $(top_srcdir)/m4/openldap-thread-check.m4 \ + $(top_srcdir)/m4/openldap.m4 $(top_srcdir)/m4/os_cflags.m4 \ + $(top_srcdir)/m4/snprintf.m4 $(top_srcdir)/m4/version.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BUILD_THREAD = @BUILD_THREAD@ +CALC_TICKADJ_DB = @CALC_TICKADJ_DB@ +CALC_TICKADJ_DL = @CALC_TICKADJ_DL@ +CALC_TICKADJ_DS = @CALC_TICKADJ_DS@ +CALC_TICKADJ_MS = @CALC_TICKADJ_MS@ +CALC_TICKADJ_NI = @CALC_TICKADJ_NI@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CFLAGS_LIBEVENT = @CFLAGS_LIBEVENT@ +CFLAGS_NTP = @CFLAGS_NTP@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CPPFLAGS_LIBEVENT = @CPPFLAGS_LIBEVENT@ +CPPFLAGS_NTP = @CPPFLAGS_NTP@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EDITLINE_LIBS = @EDITLINE_LIBS@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +GTEST_CONFIG = @GTEST_CONFIG@ +GTEST_CPPFLAGS = @GTEST_CPPFLAGS@ +GTEST_CXXFLAGS = @GTEST_CXXFLAGS@ +GTEST_LDFLAGS = @GTEST_LDFLAGS@ +GTEST_LIBS = @GTEST_LIBS@ +HAVE_INLINE = @HAVE_INLINE@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDADD_LIBEVENT = @LDADD_LIBEVENT@ +LDADD_LIBNTP = @LDADD_LIBNTP@ +LDADD_LIBUTIL = @LDADD_LIBUTIL@ +LDADD_NTP = @LDADD_NTP@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_NTP = @LDFLAGS_NTP@ +LIBISC_PTHREADS_NOTHREADS = @LIBISC_PTHREADS_NOTHREADS@ +LIBM = @LIBM@ +LIBOBJS = @LIBOBJS@ +LIBOPTS_CFLAGS = @LIBOPTS_CFLAGS@ +LIBOPTS_DIR = @LIBOPTS_DIR@ +LIBOPTS_LDADD = @LIBOPTS_LDADD@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIB_SYSLOG = @LIB_SYSLOG@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTHREAD_LIBS = @LTHREAD_LIBS@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MANTAGFMT = @MANTAGFMT@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NTPDATE_DB = @NTPDATE_DB@ +NTPDATE_DL = @NTPDATE_DL@ +NTPDATE_DS = @NTPDATE_DS@ +NTPDATE_MS = @NTPDATE_MS@ +NTPDATE_NI = @NTPDATE_NI@ +NTPDC_DB = @NTPDC_DB@ +NTPDC_DL = @NTPDC_DL@ +NTPDC_DS = @NTPDC_DS@ +NTPDC_MS = @NTPDC_MS@ +NTPDC_NI = @NTPDC_NI@ +NTPDSIM_DB = @NTPDSIM_DB@ +NTPDSIM_DL = @NTPDSIM_DL@ +NTPDSIM_DS = @NTPDSIM_DS@ +NTPDSIM_MS = @NTPDSIM_MS@ +NTPDSIM_NI = @NTPDSIM_NI@ +NTPD_DB = @NTPD_DB@ +NTPD_DL = @NTPD_DL@ +NTPD_DS = @NTPD_DS@ +NTPD_MS = @NTPD_MS@ +NTPD_NI = @NTPD_NI@ +NTPQ_DB = @NTPQ_DB@ +NTPQ_DL = @NTPQ_DL@ +NTPQ_DS = @NTPQ_DS@ +NTPQ_MS = @NTPQ_MS@ +NTPQ_NI = @NTPQ_NI@ +NTPSNMPD_DB = @NTPSNMPD_DB@ +NTPSNMPD_DL = @NTPSNMPD_DL@ +NTPSNMPD_DS = @NTPSNMPD_DS@ +NTPSNMPD_MS = @NTPSNMPD_MS@ +NTPSNMPD_NI = @NTPSNMPD_NI@ +NTPSWEEP_DB = @NTPSWEEP_DB@ +NTPSWEEP_DL = @NTPSWEEP_DL@ +NTPSWEEP_DS = @NTPSWEEP_DS@ +NTPSWEEP_MS = @NTPSWEEP_MS@ +NTPSWEEP_NI = @NTPSWEEP_NI@ +NTPTIME_DB = @NTPTIME_DB@ +NTPTIME_DL = @NTPTIME_DL@ +NTPTIME_DS = @NTPTIME_DS@ +NTPTIME_MS = @NTPTIME_MS@ +NTPTIME_NI = @NTPTIME_NI@ +NTPTRACE_DB = @NTPTRACE_DB@ +NTPTRACE_DL = @NTPTRACE_DL@ +NTPTRACE_DS = @NTPTRACE_DS@ +NTPTRACE_MS = @NTPTRACE_MS@ +NTPTRACE_NI = @NTPTRACE_NI@ +NTP_FORCE_LIBEVENT_DIST = @NTP_FORCE_LIBEVENT_DIST@ +NTP_KEYGEN_DB = @NTP_KEYGEN_DB@ +NTP_KEYGEN_DL = @NTP_KEYGEN_DL@ +NTP_KEYGEN_DS = @NTP_KEYGEN_DS@ +NTP_KEYGEN_MS = @NTP_KEYGEN_MS@ +NTP_KEYGEN_NI = @NTP_KEYGEN_NI@ +NTP_WAIT_DB = @NTP_WAIT_DB@ +NTP_WAIT_DL = @NTP_WAIT_DL@ +NTP_WAIT_DS = @NTP_WAIT_DS@ +NTP_WAIT_MS = @NTP_WAIT_MS@ +NTP_WAIT_NI = @NTP_WAIT_NI@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_RUBY = @PATH_RUBY@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +POSIX_SHELL = @POSIX_SHELL@ +PTHREAD_LIBS = @PTHREAD_LIBS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +SNTP = @SNTP@ +SNTP_DB = @SNTP_DB@ +SNTP_DL = @SNTP_DL@ +SNTP_DS = @SNTP_DS@ +SNTP_MS = @SNTP_MS@ +SNTP_NI = @SNTP_NI@ +STDNORETURN_H = @STDNORETURN_H@ +STRIP = @STRIP@ +TICKADJ_DB = @TICKADJ_DB@ +TICKADJ_DL = @TICKADJ_DL@ +TICKADJ_DS = @TICKADJ_DS@ +TICKADJ_MS = @TICKADJ_MS@ +TICKADJ_NI = @TICKADJ_NI@ +TIMETRIM_DB = @TIMETRIM_DB@ +TIMETRIM_DL = @TIMETRIM_DL@ +TIMETRIM_DS = @TIMETRIM_DS@ +TIMETRIM_MS = @TIMETRIM_MS@ +TIMETRIM_NI = @TIMETRIM_NI@ +UPDATE_LEAP_DB = @UPDATE_LEAP_DB@ +UPDATE_LEAP_DL = @UPDATE_LEAP_DL@ +UPDATE_LEAP_DS = @UPDATE_LEAP_DS@ +UPDATE_LEAP_MS = @UPDATE_LEAP_MS@ +UPDATE_LEAP_NI = @UPDATE_LEAP_NI@ +VERSION = @VERSION@ +VER_SUFFIX = @VER_SUFFIX@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +NULL = +EXTRA_DIST = \ + autogen-version.def \ + copyright.def \ + debug-opt.def \ + homerc.def \ + ntp.lic \ + version.def \ + version.texi \ + $(NULL) + +noinst_HEADERS = +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign include/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +tags TAGS: + +ctags CTAGS: + +cscope cscopelist: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(HEADERS) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + cscopelist-am ctags-am distclean distclean-generic \ + distclean-libtool distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +$(srcdir)/version.def: $(srcdir)/../../packageinfo.sh + cd .. && $(MAKE) $(AM_MAKEFLAGS) $(abs_top_srcdir)/include/version.def + +$(srcdir)/version.texi: $(srcdir)/../../packageinfo.sh + cd .. && $(MAKE) $(AM_MAKEFLAGS) $(abs_top_srcdir)/include/version.texi + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/sntp/include/autogen-version.def b/contrib/ntp/sntp/include/autogen-version.def new file mode 100644 index 000000000..e494f0ef4 --- /dev/null +++ b/contrib/ntp/sntp/include/autogen-version.def @@ -0,0 +1,4 @@ +#assert (version-compare >= autogen-version "5.18.5") +// >= is usually what we want. +// > is when we need a pre* version +guard-option-names; diff --git a/contrib/ntp/sntp/include/copyright.def b/contrib/ntp/sntp/include/copyright.def new file mode 100644 index 000000000..1cc7ad270 --- /dev/null +++ b/contrib/ntp/sntp/include/copyright.def @@ -0,0 +1,30 @@ +/* -*- Mode: Text -*- */ + +copyright = { + date = "1992-2015"; + owner = "The University of Delaware and Network Time Foundation"; + eaddr = "http://bugs.ntp.org, bugs@ntp.org"; + type = ntp; +}; + +long-opts; +config-header = config.h; +environrc; +no-misuse-usage; +version-proc = ntpOptionPrintVersion; + +version = ` +eval VERSION=\`sed -e 's/.*,\\[//' -e 's/\\].*//' < ../sntp/m4/version.m4\` +[ -z "${VERSION}" ] && echo "Cannot determine VERSION" && kill -TERM $AG_pid +echo $VERSION`; + +version-value = ''; /* Don't use -v as a shortcut for --version */ + +/* + * HMS: man pages already have this, and texi pages can use the + * values in sntp/include/version.texi . + */ +// doc-sub = { +// sub-name = version; +// sub-text = 's/#VERSION#/<>/g'; +// }; diff --git a/contrib/ntp/sntp/include/debug-opt.def b/contrib/ntp/sntp/include/debug-opt.def new file mode 100644 index 000000000..516163d6e --- /dev/null +++ b/contrib/ntp/sntp/include/debug-opt.def @@ -0,0 +1,29 @@ + +include = <<- _EOF_ + #ifdef __windows + extern int atoi(const char*); + #else + # include + #endif + _EOF_; + +flag = { + name = debug-level; + value = d; + max = NOLIMIT; + nopreset; + flag-code = 'OPT_VALUE_SET_DEBUG_LEVEL++;'; + descrip = "Increase debug verbosity level"; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; + +flag = { + name = set-debug-level; + value = D; + max = NOLIMIT; + descrip = "Set the debug verbosity level"; + arg-type = number; + doc = <<- _EndOfDoc_ + _EndOfDoc_; +}; diff --git a/contrib/ntp/include/homerc.def b/contrib/ntp/sntp/include/homerc.def similarity index 100% rename from contrib/ntp/include/homerc.def rename to contrib/ntp/sntp/include/homerc.def diff --git a/contrib/ntp/sntp/include/ntp.lic b/contrib/ntp/sntp/include/ntp.lic new file mode 100644 index 000000000..69af392e1 --- /dev/null +++ b/contrib/ntp/sntp/include/ntp.lic @@ -0,0 +1,18 @@ +Copyright (C) , all rights reserved. +This is free software. It is licensed for use, modification and +redistribution under the terms of the NTP License, copies of which +can be seen at: + + + +Permission to use, copy, modify, and distribute this software and its +documentation for any purpose with or without fee is hereby granted, +provided that the above copyright notice appears in all copies and that +both the copyright notice and this permission notice appear in +supporting documentation, and that the name The University of Delaware not be used in +advertising or publicity pertaining to distribution of the software +without specific, written prior permission. makes no +representations about the suitability this software for any purpose. It +is provided "as is" without express or implied warranty. + +the NTP license, diff --git a/contrib/ntp/sntp/include/version.def b/contrib/ntp/sntp/include/version.def new file mode 100644 index 000000000..9f1ca6b51 --- /dev/null +++ b/contrib/ntp/sntp/include/version.def @@ -0,0 +1 @@ +version = '4.2.8p4'; diff --git a/contrib/ntp/sntp/include/version.texi b/contrib/ntp/sntp/include/version.texi new file mode 100644 index 000000000..64f037b28 --- /dev/null +++ b/contrib/ntp/sntp/include/version.texi @@ -0,0 +1,3 @@ +@set UPDATED 21 October 2015 +@set EDITION 4.2.8p4 +@set VERSION 4.2.8p4 diff --git a/contrib/ntp/sntp/includes.mf b/contrib/ntp/sntp/includes.mf new file mode 100644 index 000000000..9ba126df4 --- /dev/null +++ b/contrib/ntp/sntp/includes.mf @@ -0,0 +1,6 @@ +## includes.mf - automake fragment + +SNTP_INCS = -I$(top_srcdir)/../include +SNTP_INCS += -I$(top_srcdir)/../lib/isc/include +SNTP_INCS += -I$(top_srcdir)/../lib/isc/$(LIBISC_PTHREADS_NOTHREADS)/include +SNTP_INCS += -I$(top_srcdir)/../lib/isc/unix/include diff --git a/contrib/ntp/sntp/internet.c b/contrib/ntp/sntp/internet.c deleted file mode 100644 index a1040f167..000000000 --- a/contrib/ntp/sntp/internet.c +++ /dev/null @@ -1,207 +0,0 @@ -/* Copyright (C) 1996 N.M. Maclaren - Copyright (C) 1996 The University of Cambridge - -This includes all of the code needed to handle Internet addressing. It is way -outside current POSIX, unfortunately. It should be easy to convert to a system -that uses another mechanism. The signal handling is not necessary for its -function, but is an attempt to avoid the program hanging when the name server -is inaccessible. */ - - - -#include "header.h" -#include "internet.h" - -#include -#include - -#define INTERNET -#include "kludges.h" -#undef INTERNET - - -/* Used to force dns resolving to ipv4 or ipv6 addresses. */ -static int pref_family; - -/* There needs to be some disgusting grobble for handling timeouts, which is -identical to the grobble in socket.c. */ - -static jmp_buf jump_buffer; - -static void jump_handler (int sig) { - longjmp(jump_buffer,1); -} - -static void clear_alarm (void) { - int k; - - k = errno; - alarm(0); - errno = 0; - if (signal(SIGALRM,SIG_DFL) == SIG_ERR) - fatal(1,"unable to reset signal handler",NULL); - errno = k; -} - -void preferred_family(int fam) { - switch(fam) { - case PREF_FAM_INET: - pref_family = AF_INET; - break; -#ifdef HAVE_IPV6 - case PREF_FAM_INET6: - pref_family = AF_INET6; - break; -#endif - default: - fatal(0,"unable to set the preferred family", NULL); - break; - } -} - -#ifdef HAVE_IPV6 - -void find_address (struct sockaddr_storage *address, - struct sockaddr_storage *anywhere, - int *port, char *hostname, int timespan) { - -/* Locate the specified NTP server and return its Internet address and port -number. */ - - int family, rval; - struct addrinfo hints; - struct addrinfo *res; - - res = NULL; - memset(address, 0, sizeof(struct sockaddr_storage)); - memset(anywhere, 0, sizeof(struct sockaddr_storage)); - - if (setjmp(jump_buffer)) - fatal(0,"unable to set up access to NTP server %s",hostname); - errno = 0; - if (signal(SIGALRM,jump_handler) == SIG_ERR) - fatal(1,"unable to set up signal handler",NULL); - alarm((unsigned int)timespan); - -/* Look up the Internet name or IP number. */ - memset(&hints, 0, sizeof(hints)); - hints.ai_socktype = SOCK_DGRAM; - hints.ai_family = pref_family; - rval = getaddrinfo(hostname, "ntp", &hints, &res); - if (rval != 0) - fatal(0, "getaddrinfo(hostname, ntp) failed with %s", - gai_strerror(rval)); - -/* Now clear the timer and check the result. */ - - clear_alarm(); - /* There can be more than one address in the list, but for now only - use the first. */ - memcpy(address, res->ai_addr, res->ai_addrlen); - family = res->ai_family; - freeaddrinfo(res); - - switch(family) { - case AF_INET: - hints.ai_family = AF_INET; - hints.ai_flags = AI_PASSIVE; - rval = getaddrinfo(NULL, "ntp", &hints, &res); - if (rval != 0) - fatal(0, "getaddrinfo(NULL, ntp) failed with %s", - gai_strerror(rval)); - memcpy(anywhere, res->ai_addr, res->ai_addrlen); - freeaddrinfo(res); - break; - case AF_INET6: - hints.ai_family = AF_INET6; - hints.ai_flags = AI_PASSIVE; - rval = getaddrinfo(NULL, "ntp", &hints, &res); - if (rval != 0) - fatal(0, "getaddrinfo(NULL, ntp, INET6, AI_PASSIVE) failed with %s", - gai_strerror(rval)); - memcpy(anywhere, res->ai_addr, res->ai_addrlen); - freeaddrinfo(res); - break; - } -} - -#else - -void find_address (struct in_addr *address, struct in_addr *anywhere, - int *port, char *hostname, int timespan) { - -/* Locate the specified NTP server and return its Internet address and port -number. */ - - unsigned long ipaddr; - struct in_addr nowhere[1]; - struct hostent *host; - struct servent *service; - -/* Set up the reserved Internet addresses, attempting not to assume that -addresses are 32 bits. */ - - local_to_address(nowhere,INADDR_LOOPBACK); - local_to_address(anywhere,INADDR_ANY); - -/* Check the address, if any. This assumes that the DNS is reliable, or is at -least checked by someone else. But it doesn't assume that it is accessible, so -it needs to set up a timeout. */ - - if (hostname == NULL) - *address = *anywhere; - else { - if (setjmp(jump_buffer)) - fatal(0,"unable to set up access to NTP server %s",hostname); - errno = 0; - if (signal(SIGALRM,jump_handler) == SIG_ERR) - fatal(1,"unable to set up signal handler",NULL); - alarm((unsigned int)timespan); - -/* Look up the Internet name or IP number. */ - - if (! isdigit(hostname[0])) { - errno = 0; - host = gethostbyname(hostname); - } else { - if ((ipaddr = inet_addr(hostname)) == (unsigned long)-1) - fatal(0,"invalid IP number %s",hostname); - network_to_address(address,ipaddr); - errno = 0; - host = gethostbyaddr((void *)address,sizeof(struct in_addr), - AF_INET); - } - -/* Now clear the timer and check the result. */ - - clear_alarm(); - if (host == NULL) fatal(1,"unable to locate IP address/number",NULL); - if (host->h_length != sizeof(struct in_addr)) - fatal(0,"the address does not seem to be an Internet one",NULL); - *address = *((struct in_addr **)host->h_addr_list)[0]; - if (memcmp(address,nowhere,sizeof(struct in_addr)) == 0 - || memcmp(address,anywhere,sizeof(struct in_addr)) == 0) - fatal(0,"reserved IP numbers cannot be used",NULL); - if (verbose) - fprintf(stderr, - "%s: using NTP server %s (%s)\n", - argv0,host->h_name,inet_ntoa(*address)); - } - -/* Find out the port number (usually from /etc/services), and leave it in -network format. This is assumed not to be obtained from a network service! -Note that a port number is not assumed to be 16 bits. */ - - if ((service = getservbyname("ntp","udp")) != NULL) { - *port = service->s_port; - if (verbose > 2) - fprintf(stderr,"Using port %d for NTP\n",port_to_integer(*port)); - } else { - *port = NTP_PORT; - if (verbose) - fprintf(stderr, - "%s: assuming port %d for NTP - check /etc/services\n", - argv0,port_to_integer(*port)); - } -} -#endif diff --git a/contrib/ntp/sntp/internet.h b/contrib/ntp/sntp/internet.h deleted file mode 100644 index 524131481..000000000 --- a/contrib/ntp/sntp/internet.h +++ /dev/null @@ -1,47 +0,0 @@ -/* Copyright (C) 1996 N.M. Maclaren - Copyright (C) 1996 The University of Cambridge - -This includes all of the 'Internet' headers and definitions used across -modules, including those for handling timeouts. No changes should be needed -for any version of Unix with Internet (IP version 5) addressing, but would be -for other addressing domains. It needs only because AF_INET is -needed by gethostbyaddr and is defined there rather than in , for some -damn-fool reason. */ - - - -#include -#include - -#include -#include -#include -#include - - - -/* It is most unclear whether these should be here or in kludges.h, as they are -kludges to keep 32-bit address dependencies out of the main body of internet.c, -to allow for the much heralded arrival of IP version 6. It will be interesting -to see whether the universal availability of 64-bit integers arrives first. */ - -#define local_to_address(x,y) ((x)->s_addr = htonl((unsigned long)y)) -#define network_to_address(x,y) ((x)->s_addr = (y)) - -#define NTP_PORT htons((unsigned short)123) /* If not in /etc/services */ -#define port_to_integer(x) (ntohs((unsigned short)(x))) - - -#if defined(_SS_MAXSIZE) || defined(_SS_SIZE) -#define HAVE_IPV6 -#endif - -/* Defined in internet.c */ -#ifdef HAVE_IPV6 -extern void find_address (struct sockaddr_storage *address, - struct sockaddr_storage *anywhere, - int *port, char *hostname, int timespan); -#else -extern void find_address (struct in_addr *address, struct in_addr *anywhere, - int *port, char *hostname, int timespan); -#endif diff --git a/contrib/ntp/sntp/sntp-opts.menu b/contrib/ntp/sntp/invoke-sntp.menu similarity index 100% rename from contrib/ntp/sntp/sntp-opts.menu rename to contrib/ntp/sntp/invoke-sntp.menu diff --git a/contrib/ntp/sntp/invoke-sntp.texi b/contrib/ntp/sntp/invoke-sntp.texi new file mode 100644 index 000000000..9a726faf7 --- /dev/null +++ b/contrib/ntp/sntp/invoke-sntp.texi @@ -0,0 +1,430 @@ +@node sntp Invocation +@section Invoking sntp +@pindex sntp +@cindex standard Simple Network Time Protocol client program +@ignore +# +# EDIT THIS FILE WITH CAUTION (invoke-sntp.texi) +# +# It has been AutoGen-ed October 21, 2015 at 12:30:56 PM by AutoGen 5.18.5 +# From the definitions sntp-opts.def +# and the template file agtexi-cmd.tpl +@end ignore + + + +@code{sntp} +can be used as an SNTP client to query a NTP or SNTP server and either display +the time or set the local system's time (given suitable privilege). It can be +run as an interactive command or from a +@code{cron} +job. + +NTP (the Network Time Protocol) and SNTP (the Simple Network Time Protocol) +are defined and described by RFC 5905. + + +The default is to write the estimated correct local date and time (i.e. not +UTC) to the standard output in a format like: + +@code{'1996-10-15 20:17:25.123 (+0800) +4.567 +/- 0.089 [host] IP sN'} + +where the +@code{'(+0800)'} +means that to get to UTC from the reported local time one must +add 8 hours and 0 minutes, +the +@code{'+4.567'} +indicates the local clock is 4.567 seconds behind the correct time +(so 4.567 seconds must be added to the local clock to get it to be correct). +Note that the number of decimals printed for this value will change +based on the reported precision of the server. +@code{'+/- 0.089'} +is the reported +@emph{synchronization} @emph{distance} +(in seconds), which represents the maximum error due to all causes. +If the server does not report valid data needed to calculate the +synchronization distance, this will be reported as +@code{'+/- ?'}. +If the +@emph{host} +is different from the +@emph{IP}, +both will be displayed. +Otherwise, only the +@emph{IP} +is displayed. +Finally, the +@emph{stratum} +of the host is reported +and the leap indicator is decoded and displayed. + +This section was generated by @strong{AutoGen}, +using the @code{agtexi-cmd} template and the option descriptions for the @code{sntp} program. +This software is released under the NTP license, . + +@menu +* sntp usage:: sntp help/usage (@option{--help}) +* sntp ipv4:: ipv4 option (-4) +* sntp ipv6:: ipv6 option (-6) +* sntp authentication:: authentication option (-a) +* sntp broadcast:: broadcast option (-b) +* sntp concurrent:: concurrent option (-c) +* sntp gap:: gap option (-g) +* sntp kod:: kod option (-K) +* sntp keyfile:: keyfile option (-k) +* sntp logfile:: logfile option (-l) +* sntp steplimit:: steplimit option (-M) +* sntp ntpversion:: ntpversion option (-o) +* sntp usereservedport:: usereservedport option (-r) +* sntp timeout:: timeout option (-t) +* sntp wait:: wait option +* sntp config:: presetting/configuring sntp +* sntp exit status:: exit status +* sntp Usage:: Usage +* sntp Authors:: Authors +@end menu + +@node sntp usage +@subsection sntp help/usage (@option{--help}) +@cindex sntp help + +This is the automatically generated usage text for sntp. + +The text printed is the same whether selected with the @code{help} option +(@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print +the usage text by passing it through a pager program. +@code{more-help} is disabled on platforms without a working +@code{fork(2)} function. The @code{PAGER} environment variable is +used to select the program, defaulting to @file{more}. Both will exit +with a status code of 0. + +@exampleindent 0 +@example +sntp - standard Simple Network Time Protocol client program - Ver. 4.2.8p4 +Usage: sntp [ - [] | --[@{=| @}] ]... \ + [ hostname-or-IP ...] + Flg Arg Option-Name Description + -4 no ipv4 Force IPv4 DNS name resolution + - prohibits the option 'ipv6' + -6 no ipv6 Force IPv6 DNS name resolution + - prohibits the option 'ipv4' + -a Num authentication Enable authentication with the key auth-keynumber + -b Str broadcast Listen to the address specified for broadcast time sync + - may appear multiple times + -c Str concurrent Concurrently query all IPs returned for host-name + - may appear multiple times + -d no debug-level Increase debug verbosity level + - may appear multiple times + -D Num set-debug-level Set the debug verbosity level + - may appear multiple times + -g Num gap The gap (in milliseconds) between time requests + -K Fil kod KoD history filename + -k Fil keyfile Look in this file for the key specified with -a + -l Fil logfile Log to specified logfile + -M Num steplimit Adjustments less than steplimit msec will be slewed + - it must be in the range: + greater than or equal to 0 + -o Num ntpversion Send int as our NTP protocol version + - it must be in the range: + 0 to 7 + -r no usereservedport Use the NTP Reserved Port (port 123) + -S no step OK to 'step' the time with settimeofday(2) + -s no slew OK to 'slew' the time with adjtime(2) + -t Num timeout The number of seconds to wait for responses + no wait Wait for pending replies (if not setting the time) + - disabled as '--no-wait' + - enabled by default + opt version output version information and exit + -? no help display extended usage information and exit + -! no more-help extended usage information passed thru pager + -> opt save-opts save the option state to a config file + -< Str load-opts load options from a config file + - disabled as '--no-load-opts' + - may appear multiple times + +Options are specified by doubled hyphens and their name or by a single +hyphen and the flag character. + + +The following option preset mechanisms are supported: + - reading file $HOME/.ntprc + - reading file ./.ntprc + - examining environment variables named SNTP_* + +Please send bug reports to: +@end example +@exampleindent 4 + +@node sntp ipv4 +@subsection ipv4 option (-4) +@cindex sntp-ipv4 + +This is the ``force ipv4 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv6. +@end itemize + +Force DNS resolution of the following host names on the command line +to the IPv4 namespace. +@node sntp ipv6 +@subsection ipv6 option (-6) +@cindex sntp-ipv6 + +This is the ``force ipv6 dns name resolution'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +must not appear in combination with any of the following options: +ipv4. +@end itemize + +Force DNS resolution of the following host names on the command line +to the IPv6 namespace. +@node sntp authentication +@subsection authentication option (-a) +@cindex sntp-authentication + +This is the ``enable authentication with the key @var{auth-keynumber}'' option. +This option takes a number argument @file{auth-keynumber}. +Enable authentication using the key specified in this option's +argument. The argument of this option is the @option{keyid}, a +number specified in the @option{keyfile} as this key's identifier. +See the @option{keyfile} option (@option{-k}) for more details. +@node sntp broadcast +@subsection broadcast option (-b) +@cindex sntp-broadcast + +This is the ``listen to the address specified for broadcast time sync'' option. +This option takes a string argument @file{broadcast-address}. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + +If specified @code{sntp} will listen to the specified address +for NTP broadcasts. The default maximum wait time +can (and probably should) be modified with @option{-t}. +@node sntp concurrent +@subsection concurrent option (-c) +@cindex sntp-concurrent + +This is the ``concurrently query all ips returned for host-name'' option. +This option takes a string argument @file{host-name}. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +may appear an unlimited number of times. +@end itemize + +Requests from an NTP "client" to a "server" should never be sent +more rapidly than one every 2 seconds. By default, any IPs returned +as part of a DNS lookup are assumed to be for a single instance of +@code{ntpd}, and therefore @code{sntp} will send queries to these IPs +one after another, with a 2-second gap in between each query. + +The @option{-c} or @option{--concurrent} flag says that any IPs +returned for the DNS lookup of the supplied host-name are on +different machines, so we can send concurrent queries. +@node sntp gap +@subsection gap option (-g) +@cindex sntp-gap + +This is the ``the gap (in milliseconds) between time requests'' option. +This option takes a number argument @file{milliseconds}. +Since we're only going to use the first valid response we get and +there is benefit to specifying a good number of servers to query, +separate the queries we send out by the specified number of +milliseconds. +@node sntp kod +@subsection kod option (-K) +@cindex sntp-kod + +This is the ``kod history filename'' option. +This option takes a file argument @file{file-name}. +Specifies the filename to be used for the persistent history of KoD +responses received from servers. If the file does not exist, a +warning message will be displayed. The file will not be created. +@node sntp keyfile +@subsection keyfile option (-k) +@cindex sntp-keyfile + +This is the ``look in this file for the key specified with @option{-a}'' option. +This option takes a file argument @file{file-name}. +This option specifies the keyfile. +@code{sntp} will search for the key specified with @option{-a} +@file{keyno} in this file. See @command{ntp.keys(5)} for more +information. +@node sntp logfile +@subsection logfile option (-l) +@cindex sntp-logfile + +This is the ``log to specified logfile'' option. +This option takes a file argument @file{file-name}. +This option causes the client to write log messages to the specified +@file{logfile}. +@node sntp steplimit +@subsection steplimit option (-M) +@cindex sntp-steplimit + +This is the ``adjustments less than @var{steplimit} msec will be slewed'' option. +This option takes a number argument. +If the time adjustment is less than @file{steplimit} milliseconds, +slew the amount using @command{adjtime(2)}. Otherwise, step the +correction using @command{settimeofday(2)}. The default value is 0, +which means all adjustments will be stepped. This is a feature, as +different situations demand different values. +@node sntp ntpversion +@subsection ntpversion option (-o) +@cindex sntp-ntpversion + +This is the ``send @var{int} as our ntp protocol version'' option. +This option takes a number argument. +When sending requests to a remote server, tell them we are running +NTP protocol version @file{ntpversion} . +@node sntp usereservedport +@subsection usereservedport option (-r) +@cindex sntp-usereservedport + +This is the ``use the ntp reserved port (port 123)'' option. +Use port 123, which is reserved for NTP, for our network +communications. +@node sntp timeout +@subsection timeout option (-t) +@cindex sntp-timeout + +This is the ``the number of seconds to wait for responses'' option. +This option takes a number argument @file{seconds}. +When waiting for a reply, @code{sntp} will wait the number +of seconds specified before giving up. The default should be +more than enough for a unicast response. If @code{sntp} is +only waiting for a broadcast response a longer timeout is +likely needed. +@node sntp wait +@subsection wait option +@cindex sntp-wait + +This is the ``wait for pending replies (if not setting the time)'' option. + +@noindent +This option has some usage constraints. It: +@itemize @bullet +@item +can be disabled with --no-wait. +@item +It is enabled by default. +@end itemize + +If we are not setting the time, wait for all pending responses. + + +@node sntp config +@subsection presetting/configuring sntp + +Any option that is not marked as @i{not presettable} may be preset by +loading values from configuration ("rc" or "ini") files, and values from environment variables named @code{SNTP} and @code{SNTP_}. @code{} must be one of +the options listed above in upper case and segmented with underscores. +The @code{SNTP} variable will be tokenized and parsed like +the command line. The remaining variables are tested for existence and their +values are treated like option arguments. + + +@noindent +@code{libopts} will search in 2 places for configuration files: +@itemize @bullet +@item +$HOME +@item +$PWD +@end itemize +The environment variables @code{HOME}, and @code{PWD} +are expanded and replaced when @file{sntp} runs. +For any of these that are plain files, they are simply processed. +For any that are directories, then a file named @file{.ntprc} is searched for +within that directory and processed. + +Configuration files may be in a wide variety of formats. +The basic format is an option name followed by a value (argument) on the +same line. Values may be separated from the option name with a colon, +equal sign or simply white space. Values may be continued across multiple +lines by escaping the newline with a backslash. + +Multiple programs may also share the same initialization file. +Common options are collected at the top, followed by program specific +segments. The segments are separated by lines like: +@example +[SNTP] +@end example +@noindent +or by +@example + +@end example +@noindent +Do not mix these styles within one configuration file. + +Compound values and carefully constructed string values may also be +specified using XML syntax: +@example + + ...<...>... + +@end example +@noindent +yielding an @code{option-name.sub-opt} string value of +@example +"...<...>..." +@end example +@code{AutoOpts} does not track suboptions. You simply note that it is a +hierarchicly valued option. @code{AutoOpts} does provide a means for searching +the associated name/value pair list (see: optionFindValue). + +The command line options relating to configuration and/or usage help are: + +@subsubheading version (-) + +Print the program version to standard out, optionally with licensing +information, then exit 0. The optional argument specifies how much licensing +detail to provide. The default is to print just the version. The licensing infomation may be selected with an option argument. +Only the first letter of the argument is examined: + +@table @samp +@item version +Only print the version. This is the default. +@item copyright +Name the copyright usage licensing terms. +@item verbose +Print the full copyright usage licensing terms. +@end table + +@node sntp exit status +@subsection sntp exit status + +One of the following exit values will be returned: +@table @samp +@item 0 (EXIT_SUCCESS) +Successful program execution. +@item 1 (EXIT_FAILURE) +The operation failed or the command syntax was not valid. +@item 66 (EX_NOINPUT) +A specified configuration file could not be loaded. +@item 70 (EX_SOFTWARE) +libopts had an internal operational error. Please report +it to autogen-users@@lists.sourceforge.net. Thank you. +@end table +@node sntp Usage +@subsection sntp Usage +@node sntp Authors +@subsection sntp Authors diff --git a/contrib/ntp/sntp/kludges.h b/contrib/ntp/sntp/kludges.h deleted file mode 100644 index dc78c8d7d..000000000 --- a/contrib/ntp/sntp/kludges.h +++ /dev/null @@ -1,62 +0,0 @@ -/* Copyright (C) 1996, 2000 N.M. Maclaren - Copyright (C) 1996, 2000 The University of Cambridge - -This includes all of the kludges necessary for certain broken systems. It is -called after all other headers. All of the modules set a flag to say which -they are, but none of the current kludges critically need that information. */ - - - -/* stdlib.h is broken under SunOS4. */ - -#ifndef EXIT_SUCCESS -#define EXIT_SUCCESS 0 -#define EXIT_FAILURE 1 -#endif - - - -/* stdio.h is also broken under SunOS4. */ - -#ifndef SEEK_SET -#define SEEK_SET 0 -#endif - - - -/* netinet/in.h sometimes omits INADDR_LOOPBACK, or makes it conditional on -peculiar preprocessor symbols. */ - -#ifndef INADDR_LOOPBACK -#define INADDR_LOOPBACK 0x7f000001ul -#endif - - - -/* HP-UX up to version 9.x does not have adjtime, so make it fail. This needs -a flag setting in Makefile. */ - -#ifdef ADJTIME_MISSING -#define adjtime(x,y) 1 -#endif - - - -/* O_NONBLOCK doesn't work under Ultrix 4.3. This needs a flag setting in -Makefile. */ - -#ifdef NONBLOCK_BROKEN -#ifdef O_NONBLOCK -#undef O_NONBLOCK -#endif -#define O_NONBLOCK O_NDELAY -#endif - - - -/* Some older systems use EWOULDBLOCK rather than EAGAIN, but don't assume that -it is defined. The differences are not relevant to this program. */ - -#ifndef EWOULDBLOCK -#define EWOULDBLOCK EAGAIN -#endif diff --git a/contrib/ntp/sntp/kod_management.c b/contrib/ntp/sntp/kod_management.c new file mode 100644 index 000000000..c8df3bdca --- /dev/null +++ b/contrib/ntp/sntp/kod_management.c @@ -0,0 +1,301 @@ +#include +#include +#include +#include + +#include "kod_management.h" +#include "log.h" +#include "sntp-opts.h" +#include "ntp_stdlib.h" +#include "ntp_worker.h" +#include "ntp_debug.h" + +int kod_init = 0, kod_db_cnt = 0; +const char *kod_db_file; +struct kod_entry **kod_db; /* array of pointers to kod_entry */ + + +/* + * Search for a KOD entry + */ +int +search_entry( + const char *hostname, + struct kod_entry **dst + ) +{ + register int a, b, resc = 0; + + for (a = 0; a < kod_db_cnt; a++) + if (!strcmp(kod_db[a]->hostname, hostname)) + resc++; + + if (!resc) { + *dst = NULL; + return 0; + } + + *dst = eallocarray(resc, sizeof(**dst)); + + b = 0; + for (a = 0; a < kod_db_cnt; a++) + if (!strcmp(kod_db[a]->hostname, hostname)) { + (*dst)[b] = *kod_db[a]; + b++; + } + + return resc; +} + + +void +add_entry( + const char * hostname, + const char * type /* 4 bytes not \0 terminated */ + ) +{ + int n; + struct kod_entry *pke; + + pke = emalloc_zero(sizeof(*pke)); + pke->timestamp = time(NULL); + memcpy(pke->type, type, 4); + pke->type[sizeof(pke->type) - 1] = '\0'; + strlcpy(pke->hostname, hostname, sizeof(pke->hostname)); + + /* + * insert in address ("hostname") order to find duplicates + */ + for (n = 0; n < kod_db_cnt; n++) + if (strcmp(kod_db[n]->hostname, pke->hostname) >= 0) + break; + + if (n < kod_db_cnt && + 0 == strcmp(kod_db[n]->hostname, pke->hostname)) { + kod_db[n]->timestamp = pke->timestamp; + free(pke); + return; + } + + kod_db_cnt++; + kod_db = erealloc(kod_db, kod_db_cnt * sizeof(kod_db[0])); + if (n != kod_db_cnt - 1) + memmove(&kod_db[n + 1], &kod_db[n], + sizeof(kod_db[0]) * ((kod_db_cnt - 1) - n)); + kod_db[n] = pke; +} + + +void +delete_entry( + const char * hostname, + const char * type + ) +{ + int a; + + for (a = 0; a < kod_db_cnt; a++) + if (!strcmp(kod_db[a]->hostname, hostname) + && !strcmp(kod_db[a]->type, type)) + break; + + if (a == kod_db_cnt) + return; + + free(kod_db[a]); + kod_db_cnt--; + + if (a < kod_db_cnt) + memmove(&kod_db[a], &kod_db[a + 1], + (kod_db_cnt - a) * sizeof(kod_db[0])); +} + + +void +atexit_write_kod_db(void) +{ +#ifdef WORK_FORK + if (worker_process) + return; +#endif + write_kod_db(); +} + + +int +write_kod_db(void) +{ + FILE *db_s; + char *pch; + int dirmode; + register int a; + + db_s = fopen(kod_db_file, "w"); + + /* + * If opening fails, blindly attempt to create each directory + * in the path first, then retry the open. + */ + if (NULL == db_s && strlen(kod_db_file)) { + dirmode = S_IRUSR | S_IWUSR | S_IXUSR + | S_IRGRP | S_IXGRP + | S_IROTH | S_IXOTH; + pch = strchr(kod_db_file + 1, DIR_SEP); + while (NULL != pch) { + *pch = '\0'; + if (-1 == mkdir(kod_db_file, dirmode) + && errno != EEXIST) { + msyslog(LOG_ERR, "mkdir(%s) failed: %m", + kod_db_file); + return FALSE; + } + *pch = DIR_SEP; + pch = strchr(pch + 1, DIR_SEP); + } + db_s = fopen(kod_db_file, "w"); + } + + if (NULL == db_s) { + msyslog(LOG_WARNING, "Can't open KOD db file %s for writing: %m", + kod_db_file); + + return FALSE; + } + + for (a = 0; a < kod_db_cnt; a++) { + fprintf(db_s, "%16.16llx %s %s\n", (unsigned long long) + kod_db[a]->timestamp, kod_db[a]->type, + kod_db[a]->hostname); + } + + fflush(db_s); + fclose(db_s); + + return TRUE; +} + + +void +kod_init_kod_db( + const char * db_file, + int readonly + ) +{ + /* + * Max. of 254 characters for hostname, 10 for timestamp, 4 for + * kisscode, 2 for spaces, 1 for \n, and 1 for \0 + */ + char fbuf[254+10+4+2+1+1]; + FILE *db_s; + int a, b, sepc, len; + unsigned long long ull; + char *str_ptr; + char error = 0; + + TRACE(2, ("Initializing KOD DB...\n")); + + kod_db_file = estrdup(db_file); + + db_s = fopen(db_file, "r"); + + if (NULL == db_s) { + msyslog(LOG_WARNING, "kod_init_kod_db(): Cannot open KoD db file %s: %m", + db_file); + + return; + } + + if (debug) + printf("Starting to read KoD file %s...\n", db_file); + /* First let's see how many entries there are and check for right syntax */ + + while (!feof(db_s) && NULL != fgets(fbuf, sizeof(fbuf), db_s)) { + + /* ignore blank lines */ + if ('\n' == fbuf[0]) + continue; + + sepc = 0; + len = strlen(fbuf); + for (a = 0; a < len; a++) { + if (' ' == fbuf[a]) + sepc++; + + if ('\n' == fbuf[a]) { + if (sepc != 2) { + if (strcmp(db_file, "/dev/null")) + msyslog(LOG_DEBUG, + "Syntax error in KoD db file %s in line %i (missing space)", + db_file, + kod_db_cnt + 1); + fclose(db_s); + return; + } + sepc = 0; + kod_db_cnt++; + } + } + } + + if (0 == kod_db_cnt) { + TRACE(2, ("KoD DB %s empty.\n", db_file)); + goto wrapup; + } + + TRACE(2, ("KoD DB %s contains %d entries, reading...\n", db_file, kod_db_cnt)); + + rewind(db_s); + + kod_db = eallocarray(kod_db_cnt, sizeof(kod_db[0])); + + /* Read contents of file */ + for (b = 0; + !feof(db_s) && !ferror(db_s) && b < kod_db_cnt; + b++) { + + str_ptr = fgets(fbuf, sizeof(fbuf), db_s); + if (NULL == str_ptr) { + error = 1; + break; + } + + /* ignore blank lines */ + if ('\n' == fbuf[0]) { + b--; + continue; + } + + kod_db[b] = emalloc(sizeof(*kod_db[b])); + + if (3 != sscanf(fbuf, "%llx %4s %254s", &ull, + kod_db[b]->type, kod_db[b]->hostname)) { + + free(kod_db[b]); + kod_db[b] = NULL; + error = 1; + break; + } + + kod_db[b]->timestamp = (time_t)ull; + } + + if (ferror(db_s) || error) { + kod_db_cnt = b; + msyslog(LOG_WARNING, "An error occured while parsing the KoD db file %s", + db_file); + fclose(db_s); + + return; + } + + wrapup: + fclose(db_s); + for (a = 0; a < kod_db_cnt; a++) + TRACE(2, ("KoD entry %d: %s at %llx type %s\n", a, + kod_db[a]->hostname, + (unsigned long long)kod_db[a]->timestamp, + kod_db[a]->type)); + + if (!readonly && write_kod_db()) + atexit(&atexit_write_kod_db); +} diff --git a/contrib/ntp/sntp/kod_management.h b/contrib/ntp/sntp/kod_management.h new file mode 100644 index 000000000..37089f209 --- /dev/null +++ b/contrib/ntp/sntp/kod_management.h @@ -0,0 +1,20 @@ +#ifndef KOD_MANAGEMENT_H +#define KOD_MANAGEMENT_H + +#include + +struct kod_entry { + char hostname[255]; + time_t timestamp; + char type[5]; +}; + +int search_entry(const char *hostname, struct kod_entry **dst); +void add_entry(const char *hostname, const char *type); +void delete_entry(const char *hostname, const char *type); +void kod_init_kod_db(const char *db_file, int readonly); +int write_kod_db(void); +void atexit_write_kod_db(void); + + +#endif diff --git a/contrib/ntp/sntp/libevent/ChangeLog b/contrib/ntp/sntp/libevent/ChangeLog new file mode 100644 index 000000000..149963750 --- /dev/null +++ b/contrib/ntp/sntp/libevent/ChangeLog @@ -0,0 +1,1402 @@ +Changes in version 2.1.5-beta (5 January 2015) + + Security Fixes (evbuffers) + o Avoid integer overflow bugs in evbuffer_add() and related functions. See CVE-2014-6272 advisory for more information. (d49bc0e88b81a5812116074dc007f1db0ca1eecd) + + New APIs (evconnlistener) + o Provide support for SO_REUSEPORT through LEV_OPT_REUSABLE_PORT (b625361 Maciej Soltysiak) + + Bugfixes (core) + o Fix use-after-free error in EV_CLOSURE_EVENT callback (3cc0eac John Ohl) + o Fix race caused by event_active (3c7d6fc vjpai) + + Bugfixes (evbuffer) + o Fix evbuffer_peek() with len==-1 and start_at non-NULL. (ba59923) + o Consistently check for failure from evbuffer_pullup() (60f8f72) + o Fix evbuffer_peek() with len==-1 and start_at non-NULL. (fb7e76a) + + Bugfixes (windows, IOCP) + o be async: avoid double close() (f133b86 Azat Khuzhin) + + Bugfixes (bufferevents) + o Fix issue #127, double free for filterevents that use BEV_OPT_CLOSE_ON_FREE (2c82aa0 John Ohl) + o make bufferevent_getwatermark api more robust (a21e510 ufo2243) + o [Bugfix] fix bufferevent setwatermark suspend_read (b34e4ac ufo2243) + o bufferevent_openssl: reset fd_is_set when setfd with -1 is called (3da84c2 Azat Khuzhin) + o Fix compilation for older OpenSSL versions. (5c7282f Joakim Soderberg) + + New APIs (evhttp) + o Add evhttp_connection_set_family() to set addrinfo->family for DNS requests (12c29b0 Azat Khuzhin) + o Implement interface that provides the ability to have an outbound evhttp_connection free itself once all requests have completed (2b9ec4c,10fe4f John Ohl) + + New APIs (core) + o Implement new/free for struct evutil_monotonic_timer and export monotonic time functions (f2645f8 Andrea Shepard) + + Bugfixes (evdns) + o Load hosts file on Windows. (a0b247c Vilmos Nebehaj) + o Don't truncate hosts file path on Windows. (d0dc861 Vilmos Nebehaj) + o Fix a crash in evdns related to shutting down evdns (9f39c88,e8fe749) + o evdns: avoid read-after-free in evdns_request_timeout_callback() (61262a0 Azat Khuzhin) + o Correctly handle allocation failures in evdns_getaddrinfo (6a53d15) + o evdns: fix EVDNS_BASE_DISABLE_WHEN_INACTIVE in case retransmit/retry (74d0eee Azat Khuzhin) + o evdns: add retry/reissue tests for EVDNS_BASE_DISABLE_WHEN_INACTIVE (3ca9d43 Azat Khuzhin) + o evdns: fail ns after we are failing/retrasmitting request (97c750d Azat Khuzhin) + + Bugfixes (evhttp) + o http: reset connection before installing retry timer (fix http retries handling) (bc79cc5 Azat Khuzhin) + + + Testing + o regress_dns: fix leaks in getaddrinfo_async{,_cancel_stress} tests (2fdc5f2 Azat Khuzhin) + o test: add family argument for http_connection_test_() (177b8a7 Azat Khuzhin) + o test: add regress for evhttp_connection_set_family() with AF_INET and AF_UNSPEC (42aefeb Azat Khuzhin) + o test/http: add regress test for set family to AF_INET6 (3fbf3cc Azat Khuzhin) + o Update to a more recent tinytest_macros. (8da5a18) + o test/regress: add simplestsignal: to track reorder bugs separately (b897bef Azat Khuzhin) + o test/evbuffer_peek: add regress in case we have first buffer greater (e2d139d Azat Khuzhin) + o More evbuffer_peek() test cases (154006a) + o use correct tt macro for pointer compare (08c88ea) + o regress_buffer: fix 'memcmp' compare size (79800df Maks Naumov) + o Fix a use-after-free in unit tests. CID 752027 (3739057) + o Fix a dead-code warning in unit tests. CID 1193548 (c119f24) + o Use evutil_weakrand() in unit tests. (a677b72, 364c110) + o Use a more precise calculation for max in time-ratelim.c (ca5b5c7) + o Make a buffer larger in the tests to avoid a scary evbuffer_copyout_from() (fb57b8b) + o Fix several memory leaks in the unit tests. (89c1a3b) + o Add test for evhttp_connection_free_on_completion (b0e9924 John Ohl) + o Fix annoying heisenbug in test-time.c (cb73704) + + Sample code + o Make http-server.c output into good html5 (6d72bdc) + o Use FindClose for handle from FindFirstFile in http-server.c (6466e88) + o https-client: add -retries argument, for connection retries (d9da844 Azat Khuzhin) + + Bugfixes (build) + o Add missing headerfile for cmake (15d90cc Trond Norbye) + o ignore one more test binary (b6593aa Michael Richardson) + o ignore config.cache/test-driver files (c83f333 Mike Frysinger) + o add a --disable-samples configure flag (0c492b3 Mike Frysinger) + o Add a few files created by "make verify" to .gitignore. (1a8295a Pierre Phaneuf) + o updates in cmake build (27bd9fa Sergey Nikulov) + o Fix cmake error when the Module path has more than one entry. (befbd13 Acer Yang) + o Fix CMake shared library build (e69d910 Nobuaki Sukegawa) + o Fix warnings when compiling with clang 3.5 (f5b4765 John Ohl) + o Fix mixed declarations and code (forbidden by ISO C90) (8afbdbc Thomas Bernard) + + Bugfixes (miscellaneous) + o tree.h: drop duplicated content of tree.h (6193187 Azat Khuzhin) + o evdns: disable probing with EVDNS_BASE_DISABLE_WHEN_INACTIVE (610410b,ad0493e,fea86a6,d83b337,5ca9e97 Azat Khuzhin) + o [Bugfix] fix grammer error (3a4d249 ufo2243) + o Change return type of evutil_load_windows_system_library_ to HMODULE (f691389) + o Fix a c90 warning (76643dd) + o Fix a typo in a doxygen comment. Reported by 亦得. (be1aeff) + o remove trailing comma from enum (b361b8a Jean-Philippe Ouellet) + + Bugfixes (FreeBSD) + o Handle ENOTCAPABLE from FreeBSD - this is returned if an event in the changelist is for an FD that has been closed. (6fd7394 Adrian Chadd) + + + +Changes in version 2.1.4-alpha (21 Mar 2014) + + Libevent 2.1.4-alpha adds a number of new miscellaneous APIs to make + Libevent more useful, including support for early close detection with + epoll via EPOLLRDHUP, triggering bufferevent callbacks, adding more + evhttp callbacks, and more. There are also numerous bugfixes, including + a number for finalize-related issues from 2.1.3-alpha; and an + alternative (non-primary!) cmake-based build mechanism. + + New APIs (core) + o Added event_base_get_num_events() (0fa107d Mobai Zhang) + o New event_base_active_by_fd API (865a142 Greg Hazel, 5c9da9a, 87fa2b0) + o Add event_base_active_by_signal by analogy (4865943) + o Add access to max event count stats (5173bef, efbd3dc, 26230a2 + Andrew Sweeney) + o Implemented EV_CLOSED event for epoll backend + (EPOLLRDHUP). (b1b69ac Diego Giagio, 53d2793, 43ffcf6, dfe1e52 + Marcin Juszkiewicz, ff26633 Joakim Soderberg, 3908a5e) + + New APIs (evutil_secure_rng) + o Add evutil_secure_rng_set_urandom_device_file (2bbb5d7) + + New APIs (bufferevents) + o Add function to fetch underlying ratelimit cfg (4b3d5af Mark Ellzey) + o Pass and return const for bufferevent_get_token_bucket_cfg (1c77fbb + Mark Ellzey) + o Add watermark introspection (4ce242b Ondřej Kuzník) + o Add an option to trigger bufferevent I/O callbacks (61ee18b Ondřej Kuzník) + o Add an option to trigger bufferevent event callbacks (a7384c7 + Ondřej Kuzník) + o Clarifications in response to merge req. comments (bd41947 Ondřej + Kuzník) + o Minor optimizations on bufferevent_trigger options (a3172a4) + + New APIs (evhttp) + o Add evhttp_connection_get_server(). (a7f82a3 Maxime Henrion) + o add a http default content type option (5a5acd9 Nicolas Martyanoff) + o http: implement new evhttp_connection_get_addr() api. (0c7f040 Azat + Khuzhin) + o Add a variant of evhttp_send_reply_chunk() with a callback on + evhttp_write_buffer() (8d8decf Julien BLACHE) + o Allow registering callback for parsing HTTP headers (b0bd7fe Balint Reczey) + o Provide on request complete callback facility (b083ca0 Andrew Sweeney) + o evhttp_request_set_on_complete_cb to be more specific about what + the function actually does and usage (da86dda Andrew Sweeney) + o Update unit test to make sure that the callback happens after the + output data is written (b85f398 Andrew Sweeney) + + Features (evdns) + o bug fix for issues #293 evdns_base_load_hosts doesn't remove + outdated addresses (954d2f9, f03d353, 45eba6f Kuldeep Gupta) + + Features: (cmake build support) + o Initial CMake commit. (e415196 Joakim Soderberg) + o Add all tests and benchmarks to CMake project. (e9fc014 Joakim Soderberg) + o More work on adding tests to CMake project (99c1dc3 Joakim Soderberg) + o Generate a dummy evconfig-private.h so things build + properly. (ce14def Joakim Soderberg) + o Link libm on unix platforms. (58fcd42 Joakim Soderberg) + o Added some GCC specific options. (19222e5 Joakim Soderberg) + o Use evutil_closesocket instead. (dbf2b51 Joakim Soderberg) + o Add copyright and licensing files for CMake modules. (c259d53 + Joakim Soderberg) + o Only include WIN32 getopt where it is used. (9bbce0b Joakim Soderberg) + o Fix bench_cascade program on Windows. (78da644 Joakim Soderberg) + o Don't segfault on no found event backend. (8f2af50 Joakim Soderberg) + o Only test the event backends available on the system. (7ea4159 + Joakim Soderberg) + o Added a "make verify" target. (e053c4f Joakim Soderberg) + o Fix the make "verify" target on Windows. (67e5d74 Joakim Soderberg) + o Get rid of deprecation warnings for OpenSSL on OSX 10.7+ (69c3516 + Joakim Söderberg) + o Fix kqueue support. (a831f2f Joakim Söderberg) + o Added a test for testing if kqueue works with pipes. (2799b35 + Joakim Söderberg) + o Change the BSD license from 4 to 3-clause. (86df3ed Joakim Soderberg) + o Minimum required python version is 2.4. (968e97b Joakim Soderberg) + o Get rid of unknown pragma warnings. (0ef1d04 Joakim Soderberg) + o Add a "make verify_coverage" target generation coverage + info. (f2483f8 Joakim Soderberg) + o Fix the "make verify" target on NetBSD (4ac086a Joakim Soderberg) + o Only look for ZLib when it is used (if tests are + included). (f780593 Joakim Soderberg) + o Added EVENT__ENABLE_GCC_WARNINGS, turns all warnings into + errors. (dd413bd Joakim Soderberg) + o Add CMake config and install targets. (f3446ed Joakim Soderberg) + o Fix typo (4b754df Joakim Soderberg) + o Some work on making it possible to simply do add_subdirectory() on + the project. (49ab363 Joakim Soderberg) + o Set USE_DEBUG=1 on EVENT__ENABLE_VERBOSE_DEBUG (fd42e70 Joakim Soderberg) + o Fix so that old nmake project still builds. (24d6466 Joakim + Soderberg) + o Rename README to README.md and use markdown to format. (d2bc39a + Joakim Soderberg) + o Update README with CMake build instructions. (604b8cc Joakim Soderberg) + o Clean up the README some. (8d4cb35 JoakimSoderberg) + o Forgotten headers for old nmake project compatability. (8697b99 + Joakim Soderberg) + o Change all uses of WIN32 to _WIN32 (4e14395 Joakim Söderberg) + o Fix include bug. (2024467 Joakim Söderberg) + o Check if we're on OSX before disabling deprecation in le-proxy + (8b40a5b Joakim Söderberg) + o Fix broken autotools build. (ae1bd82 Joakim Söderberg) + o Disclaimerize cmake a little in the README (d03b5bf) + o Fix CMake compile when OpenSSL is disabled. (e423d42 Joakim + Söderberg) + o CMake: Get rid of python not found warning when regress tests + turned off. (d38d798 Joakim Söderberg) + o Fix https-client compilation on Windows. (d7be788 Joakim Soderberg) + o Guard against EVENT_NOWIN32 being set during testing. (f1715b4 + Joakim Soderberg) + o Check for OSX when checking for clang. (e212c54 Joakim Soderberg) + o Added a Travis-CI configuration file. (8c0f0a9 Joakim Soderberg) + o Added -Qunused-arguments for clang on macosx (ed99d92 Trond Norbye) + o Rename event_extras to event_extra (a0dd5df Trond Norbye) + o Add option to build shared library (4545fa9 Trond Norbye) + o Add -Qunused-arguments for clang on macos (b56611d Trond Norbye) + o Add cmake-related files to .gitignore (e061321 Trond Norbye) + o Export event_extra not event_extras. (2b41bcf Joakim Söderberg) + + Bugfixes (core) + o If evsel->del() fails, don't leave the evmap in an inconsistent + state (9b5a527 Maxime Henrion) + o Move event_debug_note_teardown_ before mm_free. (69b5c64) + o Check CLOCK_MONOTONIC_* at runtime if needed. (911abf3) + o Fix reinit of fds with EV_WRITE but not EV_READ. (ebfd8a8 maksqwe) + o Tweaked callbacks to prevent race condition + (https://github.com/libevent/libevent/issues/104) (40830f1, 2ea15ed + John Ohl) + o Move assert(ev) to before we use ev in EV_CLOSURE_EVENT_FINALIZE + case (9805972) + + Bugfixes (evhttp) + o Fix a double close() bug in evhttp when the underlying bufferevent uses + BEV_OPT_CLOSE_ON_FREE. (31db8a0 Maxime Henrion) + o Fix an unlikely but possible error case for http connections (f22049e) + o Avoid racy bufferevent activation (5eb1788 Nate Rosenblum) + + Bugfixes on 2.0 (Windows) + o Use windows vsnprintf fixup logic on all windows environments (e826f19) + o libevent/win32_dealloc() : fix sizeof(pointer) vs sizeof(*pointer) + (b8f5980 Frank Denis) + + Bugfixes (evutil_secure_rng) + o When we seed from /proc/sys/kernel/random/uuid, count it as success + (e35b540) + o We should return after arc4random_buf() (1ea1f26 Makoto Kato) + o Avoid other RNG initialization FS reads when urandom file is + specified (9695e9c) + o Really remove RNG seeds from the stack (f5ced88) + o Fix another arc4random_buf-related warning (e64a2b0) + + Bugfixes (bufferevents) + o Initialize async bufferevent timeout CBs unconditionally (af9b2a7) + + Bugfixes (evdns) + o Checking request nameserver for NULL, before using it. (5c710c0 + Belobrov Andrey) + o Fix SEGFAULT after evdns_base_resume if no nameservers + installed. (14971a8 Azat Khuzhin) + o Actually use the log facility for reporting evdns problems. (e1766a1) + o Fix SEGFAULT after evdns_base_resume if no nameservers + installed. (f8d7df8 Azat Khuzhin) + o fix for ServFail from RIPE Atlas release (62f596b Antony Antony) + + Bugfixes (compilation) + o Fix test compilation with nmake: add the gdi.lib dependency (5ba8ab7) + o Whoops. It is gdi.lib, not gdi32.lib. (github issue #61) (8ab612e) + o Don't use return since return type is void and build error occurs + using clang (838161d Makoto Kato) + o Use void casts to suppress some "unchecked return value" warns (7080d55) + o rpcgen: Generate regress.gen.[c,h] in build rather than src dir + (243386c Ross Lagerwall) + o Fix a compiler warning when checking for arc4random_buf linker + breakage. (5cb3865) + o Fix 'make distcheck' by adding regress.gen.[ch] to DISTCLEANFILES + (239d834) + + o Fix a c90 warning (c207682) + o Fix consts in WIN32-Code/getopt*.[ch] (57abb35) + + Bugfixes (locks, synchronization) + o Missed lock acquire/release in event_base_cancel_single_callback_() + (d3d999a Azat Khuzhin) + o Fix locking in bufferevent_get_options_(). (dbc9cd4 Maxime Henrion) + + Bugfixes (leaks) + o Avoid leaking segment mappings when offset is not a page multiple (d409514) + + Testing + o Add tests for evdns_base_resume(). (1cd9ff5 Azat Khuzhin) + o Fix dns/leak_resume_send_err test. (7e876df Azat Khuzhin) + o Add checks for evhttp_connection_get_server() in unit + tests. (fbc323b Maxime Henrion) + o Fix a (failure-only) null dereference in the unit tests (1104d0b) + o Fix a logic error in test_evbuffer_freeze (7765884) + o Add missing check to test_evbuffer_file_segment_add_cleanup_cb (eba4506) + o Fix some crash-on-fail cases in DNS regression tests (87cd6f0) + o DNS tests: add a missing check (f314900) + o Finalize tests: add a missing check (82b6956) + o test_evutil_rtrim: add another missing check. (e193c95) + o regress_main: logging all if env EVENT_DEBUG_LOGGING_ALL isset + (611e28b Azat Khuzhin) + o regress_http: add tests for evhttp_connection_get_addr() (4dd500c + Azat Khuzhin) + o Update to the latest version of tinytest (7a80476) + o Heap-allocate zlib data structure in regress_zlib tests (4947c18) + + Performance tweaks (core) + o Avoid redundant syscall to make a nonblocking socket nonblocking + (42c03da Maxime Henrion) + o Avoid redundant syscall if making a socket cloexec twice (1f29b18) + o Avoid redundant invocations of init_extension_functions for IOCP (3b77d62) + + Documentation + o Document that arc4random is not a great cryptographic PRNG. (6e49696) + o Small doxygen tweaks (6e67b51) + o Try another doxygen tweak (ccf432b) + o Clarify event_base_loop exit conditions (031a803) + o Fix a typo (be7bf2c Ondřej Kuzník) + o Document deferred eventcb behaviour (13a9a02 Ondřej Kuzník) + o Typo fixes from Linus Nordberg (cec62cb, 8cd695b) + o Fix duplicate paragraph in evbuffer_ptr documentation (58408ee) + + Code Improvements (coverity) + o Fix a pile of coverity warnings in the unit tests (867f401) + o Fix coverity warnings in benchmark tools. (ff7f739) + o Whoops; fix compilation in bench.c (544cf88) + o Remove spurious checks in evrpc.c error cases (coverity) (991b362) + o Fix a couple of compilation warnings in regress_http.c (860767e) + o Fix even more coverity warnings. (d240328) + o Stop checking for inet_aton; we don't use it. (f665d5c) + o Add an include to evrpc-internal to fix openbsd compilation warning + (5e161c6) + + Cleanups + o Remove an unreachable return statement in minheap-internal.h (e639a9e) + o Refactor evmap_{io,signal}_active_() to tolerate bad inputs (974c60e) + o Fix needless bufferevent includes in evdns.c (254c04e) + o Fix a couple of "#ifdef WIN32" instances (88ecda3) + o Remove unneeded declaration in bufferevent-internal.h (4c8ebcd) + + Sample code + o le-proxy: Fail more gracefully if opening listener fails (44b2491) + o http-server: drop uri_root from base_url in http-server. (6171e1c Azat Khuzhin) + o https-client: POST supported, args supported (c5887f7 Alexey Ozeritsky) + o https-client: code cleanup (29af65e Alexey Ozeritsky) + o https-client: Small tweaks to https-client.c (90786eb) + o https-client: Set hostname for SNI extension (by f69m) (d1976f8) + o https-client: add a cast to https-client.c (462e6b6) + + + +Changes in version 2.1.3-alpha (1 May 2013) + + Libevent 2.1.3-alpha fixes various bugs, adds new unit tests, and cleans + up the code in a couple of places. It has a new callback in evhttp for + reporting errors during a request, a new feature for allowing evdns to + not keep the event_base looping when there are no requests inflight, and + example code for writing an https client. + + Libevent 2.1.3-alpha also has an important new (experimental) event + finalization feature to allow safe event teardown in multithreaded + programs. This ought to fix the longstanding bug with deadlocks in + multithreaded use of SSL-based bufferevents that some people have been + experiencing since Libevent 2.0. + + + Core (event finalization) + o Implement event_finalize() and related functions to avoid certain + deadlocks (8eedeab) + o Use finalization feature so bufferevents can avoid deadlocks (02fbf68) + o Always run pending finalizers when event_base_free() is called (e9ebef8) + o Remove bufferevent_del_generic_timeout_cbs as now unused (4ea4c6a) + o More documentation for finalization feature (a800b91) + o Make the event_finalize* functions return an error code (5d11f4f) + o Mark the finalize stuff as experiemental in case it needs to + change (23e2e29) + + Evdns + o evdns: New flag to make evdns not prevent the event loop from + exiting (6b7fa62 Azat Khuzhin) + + Bugfixes (Core) + o Make event_remove_timer behave correctly with persistent timers (5623e80) + o Unit test for event_remove_timer with EV_PERSIST. (96150dd) + o Double-check next timeout when adding events (9443868 Nate Rosenblum) + o event_base_update_cache_time should be a no-op if the loop isn't + running (5e6fa2a) + + Bugfixes (evhttp, crash fix, from 2.0) + o fix #73 and fix http_connection_fail_test to catch it (b618204 Greg Hazel) + + Bugfixes (compilation and portability, from 2.0) + o Fix compilation with WIN32_HAVE_CONDITION_VARIABLES enabled (7e45739) + o Fix missing AC_PROG_SED on older Autoconfs (9ab2b3f Tay Ray Chuan) + o Backport libevent to vanilla Autoconf 2.59 (as used in RHEL5) + (74d4c44 Kevin Bowling) + o Use AC_CONFIG_HEADERS in place of AM_CONFIG_HEADERS for autmake + 1.13 compat (817ea36) + o Rename configure.in to configure.ac to appease newer autoconfs (0c79787) + o Avoid using top_srcdir in TESTS: new automakes do not like this (a55514e) + + Bugfixes (resource leaks/lock errors on error, from 2.0) + o Avoid leaking fds on evconnlistener with no callback set (69db261) + o Avoid double-close on getsockname error in evutil_ersatz_socketpair + (0a822a6) + o Fix a locking error in bufferevent_socket_get_dns_error. (0a5eb2e) + + Documentation Fixes (from 2.0) + o Fix a mistake in evbuffer_remove() arguments in example http server code + (c322c20 Gyepi Sam) + o Fix a typo in a comment in buffer.h. Spotted by Alt_F4 (773b0a5) + + Documentation Fixes + o minor documentation typos (809586a Patrick Pelletier) + o Fix cut-and-paste err in whatsnew-2.1 (49905ac) + o Fix comment to refer to sample/include.am correctly (9e8cdf3 Sebastian + Hahn) + o Fix typo : Dispatching instead of Dispaching (0c2bacc Volker Lendecke) + o fix some hinky indentation in evhttp_make_request (80e220e Patrick + Pelletier) + o "buffer" spelling (a452811 Patrick Pelletier) + o Specify return behavior in header for evbuffer_pullup() in corner case + (cf8d1cd Dan Petro) + o Clarify an important point about event_base_foreach_event() (920a5e6) + + Compilation Fixes/Tool Support + o avoid valgrind false positive by zeroing epoll_event (1258614 Patrick + Pelletier) + o Fix harmless clang enum warning (b452a43 Sebastian Hahn) + o remove all exes on "make clean", not just regress.exe (974bfa0 Patrick + Pelletier) + o Make --disable-libevent-regress work again (787fd74) + o Do not build strlcpy.c when it will have no code. (4914620) + + Portability Fixes + o When EWOULDBLOCK is not EAGAIN, treat it as equivalent to it (bf7a0ff) + o Preliminary changes for Minix3. (0dda56a Nicholas Heath) + o Use AC_CONFIG_HEADERS in place of AM_CONFIG_HEADERS for autmake 1.13 + compat (bf278b) + o Avoid using $(top_srcdir) in TESTS. (2863c83) + o build test/test-script.sh on systems with a less-featureful $< (f935e21) + o Implement EVUTIL_ERR_IS_EAGAIN on windows. (42aaf4d) + + Evhttp changes: + o Fix ipv6 support for http. When URL contain domain, not IP + address. (71e709c Azat Khuzhin) + o uri decode: fix for warning "use of uninitialised value" (64b6ece Azat + Khuzhin) + o uri decode: changed the test for the existence of the next character + (e1903e3 Azat Khuzhin) + o Move prototype of evhttp_decode_uri_internal() to http-internal.h + (de8101a Azat Khuzhin) + o Test: decoding just part of string with evhttp_decode_uri_internal() + (1367653 Azat Khuzhin) + o Add new error_cb for actual reporting of HTTP request errors. (7b07719 + Azat Khuzhin) + o Add test for EVREQ_HTTP_REQUEST_CANCEL into http_cancel_test() (862c217 + Azat Khuzhin) + o Drop extra header http_struct.h from regress_http.c (54cc800 Azat Khuzhin) + + Testing + o Add regress test ipv6_for_domain. (9ec88bd Azat Khuzhin) + o Add an environment variable (EVENT_DEBUG_MODE) to run unit tests in debug + mode (2fad0f3) + o Add a test with an active_later event at event_base_free time. (1c3147f) + o Make all tests pass under EVENT_DEBUG_MODE=1 (b1b054f) + o Add some verbose notes to bufferevent unit tests (9d893c9) + o New test for active_later->active transition on event_active (a153874) + o New tests for event_base_foreach_event() (0b096ef) + o Unit tests for event_base_gettimeofday_cached() and + event_base_update_cache_time() (30ea291) + o A test for event_get_assignment() (f09629e) + o More unit tests for initializing common timeouts. (d596739) + o Fix a bug in the new main/event_foreach test (702c9aa) + + Windows: + o use FormatMessage for winsock errors (0c6ec5d, 2078e9b, 4ccdd53, c9ad3af + Patrick Pelletier) + o a program to print out the error strings for winsock errors (7296512 + Patrick Pelletier) + o Fix a warning introduced in 0c6ec5d8 (eeb700c) + o Fix another warning introduced in 0c6ec5d8 (ed26561) + + Examples (http) + o Add sample/https-client.c, an example of stacking evhttp as a client on + top of bufferevent_ssl. (be46c99 Catalin Patulea) + o use ${OPENSSL_LIBS} instead of -lssl -lcrypto (bf31fa5 Patrick Pelletier) + o https-client was putting newlines at 256-byte boundaries (42d7441 Patrick + Pelletier) + o better handling of OpenSSL errors (5754d96 Patrick Pelletier) + o use Debian's default root certificate location (aacd674 Patrick Pelletier) + o use iSECPartners code to validate hostname in certificate (64d9f16 + Patrick Pelletier) + o avoid sign mismatch warning in openssl_hostname_validation.c (6021cb5 + Patrick Pelletier) + o pull in wildcard matching code from cURL (4db9da6 Patrick Pelletier) + o Another tweak to https-client.c (95acdaa) + o Remove http_struct.h usage in sample/https-client.c (8a90a85) + + + +Changes in version 2.1.2-alpha (18 Nov 2012) + + Libevent 2.1.2-alpha includes more portable for monotonic timers, + refactors much of Libevent's internal and external infrastructure, + closes some longstanding gaps in the interface, makde other + improvements. Ths log below tries to organize features by rough area of + effect. It omits a few commits which were pure bugfixes on other commits + listed below. For more detail, see the git changelogs. For more + insight, see the "whatsnew-2.1.txt" document included in the Libevent + 2.1.2-alpha distribution. + + Libevent 2.1.2-alpha also includes all changes made in 2.0.19-stable + through 2.0.21-stable inclusive. + + Performance (core): + o Replace pipe-based notification with EVFILT_USER where possible. This + should make multithreaded programs on OSX and *BSD alert the main thread a + little faster. (53a07fe) + o Make th_base_lock nonrecursive. (9cd5acb) + + New/Changed API Functions: + o New event_get_priority() function to return an event's priority (f90e255) + o Add a bufferevent_get_priority() function (bd39554) + o Add an event_base_loopcontinue() to tell Libevent to rescan for more + events right away (7d6aa5e) + o Add a new callback to get called on evbuffer_file_segment free + (e9f8feb yangacer, 64051b9) + o Expose event_base_foreach_event() as a public API. (84fd6d7 Roman + Puls, 232055e, ffe1643) + o Add an event_remove_timer() to remove timer on an event without + deleting it (e3b2e08) + o Make bufferevent_set_timeouts(bev, NULL, NULL) have plausible + semantics (9dee36b) + o Rename event_enable_lock_debuging() to ..._debugging(). (The old name + should still work.) (07e132e) + o Add missing implementation for event_enable_debug_logging (3b3e21d) + + PORTABLE MONOTONIC TIMERS: + + Libevent 2.1.2 includes internal support for monotonic timers on + (nearly) all supported platforms, including Windows, and OSX. Libevent + applications should now be more resilient to jumps forwards or backwards + in the system clock. Also, on Linux systems with epoll, we now + optionally support microsecond-level timeouts (whereas epoll only + supports millisecond-precision timeouts). + + o Use mach_absolute_time() for monotonic clock support on OSX. (b8fd6f9) + o Do not track use_monotonic field when is no monotonic clock (cb653a0) + o EVENT_BASE_FLAG_PRECISE_TIMER indicates we want fine timer precision + (ddd69d3) + o On Linux, use CLOCK_MONOTONIC_COARSE by default (55780a7) + o Implement a GetTickCount-based monotonic timer for Windows (d5e1d5a) + o Refactor monotonic timer handling into a new type and set of + functions; add a gettimeofday-based ratcheting implementation (f5e4eb0) + o Add EVENT_PRECISE_TIMER environment var for selecting precise-but-slow + timer (a2598ec) + o Implement fast/precise monotonic clocks on Windows (2c47045) + o Simple unit tests for monotonic timers (630f077) + o Improve the monotonic-time unit test: make it check the step size (7428c78) + o When PRECISE_TIMERS is set with epoll, use timerfd for microsecond + precision (26c7582) + o Split out time-related evutil functions into a new evutil_time.c (c419485) + o Split out time-related prototypes into time-internal.h (71bca50) + o Add evutil_time.obj to Makefile.nmake (0ba0683) + o Avoid giving a spurious warning when timerfd support is unavailable + (1aaf9f0 Dave Hart) + o Make test_evutil_monotonic a little more tolerant (def3b83) + o Avoid unused-var warning on systems with clock_gettime but without + CLOCK_MONOTONIC_COARSE (9be5468) + +EVENT_BASE_ONCE LEAKS: + If a callback added by event_base_once() is never invoked, Libevent no + longer leaks internal memory. + + o Free dangling event_once objects on event_base_free() (c17dd59) + o Add a unit test in which an event is created with event_base_once() + but never fires (4343edf) + +TESTING SUPPORT, FIXES AND IMPROVEMENTS: + + Libevent now disables by default its unit tests that would touch the + network, or that tend to fail on heavily-loaded systems. To re-enable + them, invoke the ./test/regress program with the @all alias. + + o Simplify test.sh code significantly. (9b856fd Ross Lagerwall) + o Make all tests that hit the network disabled by default (f2cea87) + o Avoid a resource leak on error in http client benchmark (ea92fba) + o Update to latest tinytest (911b4f0349377) (ef7c4f7) + o Avoid (unlikely) overflow in bench_httpclient.c (5671033) + o Shave 700 msec off the persistent_timeout_jump test (21205b8) + o Check return value of write() in regress.c (c8009d2) + o Make load-dependent monotonic timer tests off-by-default (2b6fe8b) + o Add deferred_cb_skew to list of timing-dependent tests (34c8f31) + o Avoid test -e; older shs don't have one. (f1bd938) + o Fix renegotiation test to work around openssl 1.0.1 bug (c2f3086) + o Fix a couple of compile warnings in the unit tests (5a9a014) + +MISC: + o Change evutil_weakrand_() to avoid platform random() (e86af4b Nicholas + Marriott, 3aa4415) + +INFRASTRUCTURE (Active-later events): + As a simplification and optimization to Libevent's "deferred callback" + logic (introduced in 2.0 to avoid callback recursion), Libevent now + treats all of its deferrable callback types using the same logic it uses + for active events. Now deferred events no longer cause priority + inversion, no longer require special code to cancel them, and so on. + + o Refactor the callback part of an event into its own event_callback + type (cba59e5) + o Add "active later" event_callbacks to supersede deferred (745a63d) + o event_base_assert_ok: check value of event_active_count for + correctness (fec8bae) + o Replace deferred_cbs with event_callback-based implementation. (ae2b84b) + o Replace more deferred_cb names with event_callback (a4079aa) + o Give event_base_process_active a single exit path (581b5be) + o Restore our priority-inversion-prevention code with deferreds (c0e425a) + o Refactor event_persist_closure: raise and extract some common logic + (bec22b4) + o Remove the unused bits from EVLIST_ALL (9889a3d) +||||||| merged common ancestors +Changes in version 2.0.22-stable (?? Dec 2013) + + (As of 3b77d62829c4393bda6f9105a5d3b73b48a64b71.) + +BUGFIXES (evhttp) + o fix #73 and fix http_connection_fail_test to catch it (crash fix) (b618204 Greg Hazel) + o Avoid racy bufferevent activation (5eb1788 Nate Rosenblum) + +BUGFIXES (compilation and portability) + o Fix compilation with WIN32_HAVE_CONDITION_VARIABLES enabled (7e45739) + o Fix missing AC_PROG_SED on older Autoconfs (9ab2b3f Tay Ray Chuan) + o Backport libevent to vanilla Autoconf 2.59 (as used in RHEL5) (74d4c44 Kevin Bowling) + o Use AC_CONFIG_HEADERS in place of AM_CONFIG_HEADERS for autmake 1.13 compat (817ea36) + o Rename configure.in to configure.ac to appease newer autoconfs (0c79787) + o Avoid using top_srcdir in TESTS: new automakes do not like this (a55514e) + o Use windows vsnprintf fixup logic on all windows environments (e826f19) + o Fix a compiler warning when checking for arc4random_buf linker breakage. (5cb3865) + o Fix another arc4random_buf-related warning (e64a2b0) + +BUGFIXES (resource leaks/lock errors on error) + o Avoid leaking fds on evconnlistener with no callback set (69db261) + o Avoid double-close on getsockname error in evutil_ersatz_socketpair (0a822a6) + o Fix a locking error in bufferevent_socket_get_dns_error. (0a5eb2e) + o libevent/win32_dealloc() : fix sizeof(pointer) vs sizeof(*pointer) (b8f5980 Frank Denis) + +BUGFIXES (miscellaneous) + o Avoid other RNG initialization FS reads when urandom file is specified (9695e9c, bb52471) + o Avoid redundant invocations of init_extension_functions for IOCP (3b77d62) + +BUFGIXES (evdns) + o Checking request nameserver for NULL, before using it. (5c710c0 Belobrov Andrey) + o Fix SEGFAULT after evdns_base_resume if no nameservers installed. (f8d7df8 Azat Khuzhin) + +BUGFIXES (evutil_secure_random) + o When we seed from /proc/sys/kernel/random/uuid, count it as success (e35b540) + o Document that arc4random is not a great cryptographic PRNG. (6e49696) + o Add evutil_secure_rng_set_urandom_device_file (2bbb5d7) + o Really remove RNG seeds from the stack (f5ced88) + + +DOCUMENTATION FIXES + o Fix a mistake in evbuffer_remove() arguments in example http server code (c322c20 Gyepi Sam) + o Fix a typo in a comment in buffer.h. Spotted by Alt_F4 (773b0a5) + + + +Changes in version 2.0.21-stable (18 Nov 2012) +BUGFIXES: + o ssl: Don't discard SSL read event when timeout and read come close together (576b29f) + o ssl: Stop looping in "consider_reading" if reading is suspended. (f719b8a Joachim Bauch) + o ssl: No need to reserve space if reading is suspended. (1acf2eb Joachim Bauch) + o dns: Avoid a memory-leak on OOM in evdns. (73e85dd, f2bff75 George Danchev) + o build: Use python2 rather than python (0eb0109 Ross Lagerwall) + o build: Compile without warnings on mingw64 (94866c2) + o build: Fix compilation on mingw64 with -DUSE_DEBUG (62bd2c4) + o build: Make rpcgen_wrapper.sh work on systems without a "python2" binary (f3009e4) + o iocp: Close IOCP listener socket on free when LEV_OPT_CLOSE_ON_FREE is set (cb853ea Juan Pablo Fernandez) + o core: Avoid crash when event_pending() called with no event_base set on event (e3cccf3) + o misc: remove stray 'x' so print_err will compile when uncommented (ac35650 Patrick Pelletier) + o tests: Fix renegotiation test to work around openssl 1.0.1 bug (c2f3086) + o tests: Warn when openssl version in unit test mismatches compiled version. (ac009f9) + + +Changes in version 2.0.20-stable (23 Aug 2012) +BUGFIXES: + o core: Make event_pending() threadsafe. (be7a95c Simon Liu) + o win32: avoid crash when waiting forever on zero fds. (160e58b) + o evhttp: Fix a memory leak on error in evhttp_uriencode (11c8b31) + o evbuffer: Avoid possible needless call to writev. Found by coverity. (6a4ec5c) + o evdns: memset sockaddr_in before using it. Found by coverity. (a1a0e67) + o evhttp: Check more setsockopt return values when binding sockets. Found by coverity (a0912e3) + o evdns: Avoid segfault on weird timeout during name lookup. (dc32077 Greg Hazel) + o bufferevent_ssl: Correctly invoke callbacks when a SSL bufferevent reads some and then blocks. (606ac43) + + +PORTABILITY FIXES: + o check for arc4random_buf at runtime, on OS X (bff5f94 Greg Hazel) + o Correctly check for arc4random_buf (fcec3e8 Sebastian Hahn) + o Add explicit AC_PROG_SED to configure.in so all autoconfs will expose $(SED) (ca80ea6) + +BUILD FIXES: + o Add GCC annotations so that the vsprintf functions get checked properly (117e327) + o Fix an unused variable warning on *BSD. (c0720c1) + +UNIT TEST FIXES: + o Fix a couple of memory leaks (found with Valgrind). (3b2529a Ross Lagerwall) + o Remove deadcode in http regression tests. Found by coverity. (5553346) + o Fix possible uninitialized read in dns regression tests. Found by coverity. (2259777) + o Set umask before calling mkstemp in unit tests. Found by coverity (f1ce15d) + o Fix various check-after-dereference issues in unit tests: found by coverity (4f3732d) + o Fix resource leaks in the unit tests; found by coverity (270f279) + o Add some missing null checks to unit tests; found by coverity (f021c3d) + o Avoid more crashes/bad calls in unit tests; found by coverity (3cde5bf) + o Remove unused variable; spotted by coverity (6355b2a) + o Add checks to various return values in unit tests. Found by coverity (b9e7329) + o Move assignment outside tt_assert in ssl unit tests. Appeases coverity. (a2006c0) + + + +Changes in version 2.0.19-stable (3 May 2012) +BUGFIXES (CORE): + o Refactor event_persist_closure: raise and extract some common logic (bec22b4) + o If time has jumped so we'd reschedule a periodic event in the past, schedule it for the future instead (dfd808c) + o If a higher-priority event becomes active, don't continue running events of the current priority. (2bfda40) + +BUGFIXES (SSL): + o Fixed potential double-readcb execution with openssl bufferevents. (4e62cd1 Mark Ellzey) + +BUGFIXES (DNS): + o Cancel a probe request when the server is freed, and ignore cancelled probe callbacks (94d2336 Greg Hazel) + o Remove redundant DNS_ERR_CANCEL check, move comment (46b8060 Greg Hazel) + o When retransmitting a timed-out DNS request, pick a fresh nameserver. (3d9e52a) + +DOCUMENTATION FIXES: + o Fix a typo in the bufferevent documentation (98e9119) + o Add missing ) to changelog; spotted by rransom (4c7ee6b) + o Fix the website URL in the readme (f775521) + +COMPILATION FIXES: + o Fix a compilation error with MSVC 2005 due to use of mode_t (336dcae) + o Configure with gcc older than 2.95 (4a6fd43 Sebastian Hahn) + o Generate event-config.h with a single sed script (30b6f88 Zack Weinberg) + +FORWARD-COMPATIBILITY: + o Backport: provide EVENT_LOG_* names, and deprecate _EVENT_LOG_* (d1a03b2) + +TESTING/DEBUGGING SUPPORT: + o dns-example.c can now take a resolv.conf file on the commandline (6610fa5) + o Make some evdns.c debug logs more verbose (d873d67) + o Work-around a stupid gcov-breaking bug in OSX 10.6 (b3887cd) + + + +Changes in version 2.0.18-stable (22 Mar 2012) +BUGFIXES (core): + o Make uses of open() close-on-exec safe by introducing an internal evutil_open_closeonexec. (d2b5f72 Ross Lagerwall, 03dce42) + +BUGFIXES (kqueue): + o Properly zero the kevent in kq_setup_kevent() (c2c7b39 Sebastian Hahn) + +BUILD FIXES: + o Added OPENSSL_LDFLAGS env variable which is appended to SSL checks. (9278196 Mark Ellzey) + o Changed OPENSSL_LDFLAGS to OPENSSL_LIBADD (2d67b63 Mark Ellzey) + o Don't do clang version detection when disabling some flags (083296b Sebastian Hahn) + +BUGFIXES (dns): + o Stop crashing in evdns when nameserver probes give a weird error (bec5068) + + +Changes in version 2.0.17-stable (10 Feb 2012) + +BUGFIXES (core): + o Be absolutely sure to clear pncalls before leaving event_signal_closure (11f36a5) + o check for sysctl before we use it (358c745 Mike Frysinger) + o Remove bogus casts of socket to int before calling ev_callback (f032516) + o Make evconnlistener work around bug in older Linux when getting nmapped (ecfc720) + o Fix a list corruption bug when using event_reinit() with signals present (6e41cdc) + o Fix a fd leak in event_reinit() (3f18ad1) + o Do a memberwise comparison of threading function tables (c94a5f2 Nate R) + o Use C-style comments in C source files (for compatibility with compilers such as xlc on AIX). (d84d917 Greg Hewgill) + o Avoid crash when freeing event_iocp and using event_set_mem_functions (19715a6) + o In the kqueue backend, do not report EBADF as an EV_READ (5d7bfa1 Nicholas Marriott) + +BUGFIXES (evbuffer and bufferevents): + o Fix behavior of evbuffer_peek(buf,-1,NULL,NULL,0) (c986f23 Zack Weinberg) + o Loop on filtering SSL reads until we are blocked or exhausted. (5b4b812) + +BUGFIXES (evhttp): + o Force strict validation of HTTP version in response. (790f6b3 Catalin Patulea) + +BUGFIXES (evdns): + o evdns: fix a bug in circular-queue implementation (d6094b1) + +BUILD FIXES: + o Fix a silly compilation error with the sun compiler (1927776 Colin Watt) + o Suppress a gcc warning from ignoring fwrite return in http-sample.c (7206e8c) + +DOCUMENTATION FIXES: + o Slightly clarify evbuffer_peek documentation (7bbf6ca) + o Update copyright notices to 2012 (e49e289) + +NEW APIS: + o Backport evhttp_connection_get_bufferevent to Libevent 2.0 (da70fa7 Arno Bakker) + +TESTS AND TEST FIXES: + o Fix a race condition in the dns/bufferevent_connect_hostname test. (cba48c7) + o Add function to check referential integrity of an event_base (27737d5) + o Check event_base correctness at end of each unit test (3312b02) + o Workaround in the unit tests for an apparent epoll bug in Linux 3.2 (dab9187) + o Better workaround for Linux 3.2 edge-triggered epoll bug (9f9e259) + +Changes in version 2.0.16-stable (18 Nov 2011) +BUGFIXES (core): + o More detailed message in case of libevent self-debugging failure. (9e6a4ef Leonid Evdokimov) + o epoll: close fd on alloc fail at initialization (1aee718 Jamie Iles) + o Fix compile warning from saying event2/*.h inside a comment (447b0ba) + o Warn when unable to construct base because of failing make_base_notifiable (4e797f3) + o Don't try to make notifiable event_base when no threading fns are configured (e787413) + +BUGFIXES (evbuffer): + o unit test for remove_buffer bug (90bd620 Greg Hazel) + o Fix an evbuffer crash in evbuffer_remove_buffer() (c37069c) + +BUGFIXES (bufferevent_openssl): + o Refactor amount-to-read calculations in buffervent_ssl consider_reading() (a186e73 Mark Ellzey) + o Move SSL rate-limit enforcement into bytes_to_read() (96c562f) + o Avoid spinning on OpenSSL reads (2aa036f Mark Ellzey) + +BUGFIXES (dns) + o Empty DNS reply with OK status is another way to say NODATA. (21a08d6 Leonid Evdokimov) + +TESTING: + o Tests for 94fba5b and f72e8f6 (d58c15e Leonid Evdokimov) + o Test for commit aff6ba1 (f7841bf Leonid Evdokimov) + o Style and comment tweaks for dns/leak* tests (5e42202) + o improve test to remove at least one buffer from src (7eb52eb Greg Hazel) + +DOCUMENTATION: + o Add note about evhttp_send_reply_end to its doxygen (724bfb5) + o Update copyright dates to 2011. (3c824bd) + o Fix typo in whatsnew-2.0.txt (674bc6a Mansour Moufid) + o Improve win32 behavior of dns-sample.c code (a3f320e Gisle Vanem) + + + +Changes in version 2.0.15-stable (12 Oct 2011) +BUGFIXES (DNS): + o DNS: add ttl for negative answers using RFC 2308 idea. (f72e8f6 Leonid Evdokimov) + o Add DNS_ERR_NODATA error code to handle empty replies. (94fba5b Leonid Evdokimov) + +BUFGIXES (bufferevents and evbuffers): + o Make evbuffer callbacks get the right n_added value after evbuffer_add (1ef1f68 Alex) + o Prefer mmap to sendfile unless a DRAINS_TO_FD flag is set. Allows add_file to work with SSL. (0ba0af9) + +BUGFIXES (event loop): + o When a signal callback is activated to run multiple times, allow event_base_loopbreak to work even before they all have run. (4e8eb6a) + +DOCUMENTATION FIXES: + o Fix docstring in dns.h (2b6eae5 Leonid Evdokimov) + o refer to non-deprecated evdns functions in comments (ba5c27d Greg Hazel) + +BUILD AND TESTING FIXES: + o le-proxy and regress depend on openssl directly (9ae061a Sergey Avseyev) + o Use _SOURCES, not _sources, in sample/Makefile.am (7f82382) + o Fixed compiler warnings for unchecked read/write calls. (c3b62fd Mark Ellzey) + o Make write-checking fixes use tt_fail_perror (2b76847) + o Fix some "value never used" warnings with gcc 4.6.1 (39c0cf7) + + + +Changes in version 2.0.14-stable (31 Aug 2011) +BUGFIXES (bufferevents and evbuffers): + o Propagate errors on the underlying bufferevent to the user. (4a34394 Joachim Bauch) + o Ignore OpenSSL deprecation warnings on OS X (5d1b255 Sebastian Hahn) + o Fix handling of group rate limits under 64 bytes of burst (6d5440e) + o Solaris sendfile: correctly detect amount of data sent (643922e Michael Herf) + o Make rate limiting work with common_timeout logic (5b18f13) + o clear read watermark on underlying bufferevent when creating filtering bev to fix potentially failing fragmented ssl handshakes (54f7e61 Joachim Bauch) + +BUGFIXES (IOCP): + o IOCP: don't launch reads or writes on an unconnected socket (495c227) + o Make IOCP rate-limiting group support stricter and less surprising. (a98da7b) + o Have test-ratelim.c support IOCP (0ff2c5a) + o Make overlapped reads result in evbuffer callbacks getting invoked (6acfbdd) + o Correctly terminate IO on an async bufferevent on bufferevent_free (e6af35d) + +BUGFIXES (other): + o Fix evsig_dealloc memory leak with debugging turned on. (9b724b2 Leonid Evdokimov) + o Fix request_finished memory leak with debugging turned on. (aff6ba1 Leonid Evdokimov) + +BUILD AND TESTING FIXES: + o Allow OS-neutral builds for platforms where some versions have arc4random_buf (b442302 Mitchell Livingston) + o Try to fix 'make distcheck' errors when building out-of-tree (04656ea Dave Hart) + o Clean up some problems identified by Coverity. (7c11e51 Harlan Stenn) + + +Changes in version 2.0.13-stable (18 Jul 2011) +BUGFIXES + o Avoid race-condition when initializing global locks (b683cae) + o Fix bug in SSL bufferevents backed by a bev with a write high-watermarks (e050703 Joachim Bauch) + o Speed up invoke_callbacks on evbuffers when there are no callbacks (f87f568 Mark Ellzey) + o Avoid a segfault when all methods are disabled or broken (27ce38b) + o Fix incorrect results from evbuffer_search_eol(EOL_LF) (4461f1a) + o Add some missing checks for mm_calloc failures (89d5e09) + o Replace an assertion for event_base_free(NULL) with a check-and-warn (09fe97d) + o Report kqueue ebadf, epipe, and eperm as EV_READ events (1fd34ab) + o Check if the `evhttp_new_object' function in `http.c' returns NULL. (446cc7a Mansour Moufid) + o Use the correct printf args when formatting size_t (3203f88) + o Complain if the caller tries to change threading cbs after setting them (cb6ecee) + +DOCUMENTATION FIXES AND IMPROVEMENTS + o Revise the event/evbuffer/bufferevent doxygen for clarity and accuracy (2888fac) + o Update Doxyfile to produce more useful output (aea0555) + +TEST FIXES + o Fix up test_evutil_snprintf (caf695a) + o Fix tinytest invocation from windows shell (57def34 Ed Day) + +BUILD FIXES + o Use AM_CPPFLAGS in sample/Makefile.am, not AM_CFLAGS (4a5c82d) + o Fix select.c compilation on systems with no NFDBITS (49d1136) + o Fix a few warnings on OpenBSD (8ee9f9c Nicholas Marriott) + o Don't break when building tests from git without python installed (b031adf) + o Don't install event_rpcgen.py when --disable-libevent-install is used (e23cda3 Harlan Stenn) + o Fix AIX build issue with TAILQ_FOREACH definition (e934096) + + +Changes in version 2.0.12-stable (4 Jun 2011) +BUGFIXES + o Fix a warn-and-fail bug in kqueue by providing kevent() room to report errors (28317a0) + o Fix an assert-inducing fencepost bug in the select backend (d90149d) + o Fix failing http assertion introducd in commit 0d6622e (0848814 Kevin Ko) + o Fix a bug that prevented us from configuring IPv6 nameservers. (74760f1) + o Prevent size_t overflow in evhttp_htmlescape. (06c51cd Mansour Moufid) + o Added several checks for under/overflow conditions in evhttp_handle_chunked_read (a279272 Mark Ellzey) + o Added overflow checks in evhttp_read_body and evhttp_get_body (84560fc Mark Ellzey) + +DOCUMENTATION: + o Add missing words to EVLOOP_NONBLOCK documentation (9556a7d) + +BUILD FIXES + o libssl depends on libcrypto, not the other way around. (274dd03 Peter Rosin) + o Libtool brings in the dependencies of libevent_openssl.la automatically (7b819f2 Peter Rosin) + o Use OPENSSL_LIBS in Makefile.am (292092e Sebastian Hahn) + o Move the win32 detection in configure.in (ceb03b9 Sebastian Hahn) + o Correctly detect openssl on windows (6619385 Sebastian Hahn) + o Fix a compile warning with zlib 1.2.4 and 1.2.5 (5786b91 Sebastian Hahn) + o Fix compilation with GCC 2, which had no __builtin_expect (09d39a1 Dave Hart) + o Fix new warnings from GCC 4.6 (06a714f) + o Link with -lshell32 and -ladvapi32 on Win32. (86090ee Peter Rosin) + o Make the tests build when OpenSSL is not available. (07c41be Peter Rosin) + o Bring in the compile script from automake, if needed. (f3c7a4c Peter Rosin) + o MSVC does not provide S_ISDIR, so provide it manually. (70be7d1 Peter Rosin) + o unistd.h and sys/time.h might not exist. (fe93022 Peter Rosin) + o Make sure TINYTEST_LOCAL is defined when building tinytest.c (8fa030c Peter Rosin) + o Fix winsock2.h #include issues with MSVC (3d768dc Peter Rosin) + o Use evutil_gettimeofday instead of relying on the system gettimeofday. (0de87fe Peter Rosin) + o Always use evutil_snprintf, even if OS provides it (d1b2d11 Sebastian Hahn) + o InitializeCriticalSectionAndSpinCount requires _WIN32_WINNT >= 0x0403. (816115a Peter Rosin) + o cygwin: make it possible to build DLLs (d54d3fc) + + + +Changes in version 2.0.11-stable (27 Apr 2011) + [Autogenerated from the Git log, sorted and cleaned by hand.] +BUGFIXES: + o Fix evport handling of POLLHUP and POLLERR (b42ce4b) + o Fix compilation on Windows with NDEBUG (cb8059d) + o Check for POLLERR, POLLHUP and POLLNVAL for Solaris event ports (0144886 Trond Norbye) + o Detect and handle more allocation failures. (666b096 Jardel Weyrich) + o Use event_err() only if the failure is truly unrecoverable. (3f8d22a Jardel Weyrich) + o Handle resize failures in the select backend better. (83e805a) + o Correctly free selectop fields when select_resize fails in select_init (0c0ec0b) + o Make --enable-gcc-warnings a no-op if not using gcc (3267703) + o Fix a type error in our (unused) arc4random_stir() (f736198) + o Correctly detect and stop non-chunked http requests when the body is too long (63a715e) + o Have event_base_gettimeofday_cached() always return wall-clock time (a459ef7) + o Workaround for http crash bug 3078187 (5dc5662 Tomash Brechko) + o Fix incorrect assertions and possible use-after-free in evrpc_free() (4b8f02f Christophe Fillot) + o Reset outgoing http connection when read data in idle state. (272823f Tomash Brechko) + o Fix subtle recursion in evhttp_connection_cb_cleanup(). (218cf19 Tomash Brechko) + o Fix the case when failed evhttp_make_request() leaved request in the queue. (0d6622e Tomash Brechko) + o Fix a crash bug in evdns server circular list code (00e91b3) + o Handle calloc failure in evdns. (Found by Dave Hart) (364291e) + o Fix a memory leak on win32 socket->event map. (b4f89f0) + o Add a forgotten NULL check to evhttp_parse_headers (12311ff Sebastian Hahn) + o Fix possible NULL-deref in evdns_cancel_request (5208544 Sebastian Hahn) + +PORTABILITY: + o Fall back to sscanf if we have no other way to implement strtoll (453317b) + o Build correctly on platforms without sockaddr_storage (9184563) + o Try to build correctly on platforms with no IPv6 support (713c254) + o Build on systems without AI_PASSIVE (cb92113) + o Fix http unit test on non-windows platforms without getaddrinfo (6092f12) + o Do not check for gethostbyname_r versions if we have getaddrinfo (c1260b0) + o Include arpa/inet.h as needed on HPUX (10c834c Harlan Stenn) + o Include util-internal.h as needed to build on platforms with no sockaddr_storage (bbf5515 Harlan Stenn) + o Check for getservbyname even if not on win32. (af08a94 Harlan Stenn) + o Add -D_OSF_SOURCE to fix hpux builds (0b33479 Harlan Stenn) + o Check for allocation failures in apply_socktype_protocol_hack (637d17a) + o Fix the check for multicast or broadcast addresses in evutil_check_interfaces (1a21d7b) + o Avoid a free(NULL) if out-of-memory in evdns_getaddrinfo. Found by Dave Hart (3417f68) + +DEFENSIVE PROGRAMMING: + o Add compile-time check for AF_UNSPEC==PF_UNSPEC (3c8f4e7) + +BUGS IN TESTS: + o Fix test.sh output on solaris (b4f89b6 Dave Hart) + o Make test-eof fail with a timeout if we never get an eof. (05a2c22 Harlan Stenn) + o Use %s with printf in test.sh (039b9bd) + o Add an assert to appease clang's static analyzer (b0ff7eb Sebastian Hahn) + o Add a forgotten return value check in the unit tests (3819b62 Sebastian Hahn) + o Actually send NULL request in http_bad_request_test (b693c32 Sebastian Hahn) + o add some (void) casts for unused variables (65707d7 Sebastian Hahn) + o Refactor test_getaddrinfo_async_cancel_stress() (48c44a6 Sebastian Hahn) + o Be nice and "handle" error return values in sample code (4bac793 Sebastian Hahn) + o Check return value of evbuffer_add_cb in tests (93a1abb Sebastian Hahn) + o Remote some dead code from dns-example.c (744c745 Sebastian Hahn) + o Zero a struct sockaddr_in before using it (646f9fe Sebastian Hahn) + +BUILD FIXES: + o Fix warnings about AC_LANG_PROGRAM usage (f663112 Sebastian Hahn) + o Skip check for zlib if we have no zlib.h (a317c06 Harlan Stenn) + o Fix autoconf bracket issues; make check for getaddrinfo include netdb.h (833e5e9 Harlan Stenn) + o Correct an AM_CFLAGS to an AM_CPPFLAGS in test/Makefile.am (9c469db Dave Hart) + o Fix make distcheck & installation of libevent 1 headers (b5a1f9f Dave Hart) + o Fix compilation under LLVM/clang with --enable-gcc-warnings (ad9ff58 Sebastian Hahn) + +FEATURES: + o Make URI parser able to tolerate nonconformant URIs. (95060b5) + +DOCUMENTATION: + o Clarify event_set_mem_functions doc (926f816) + o Correct evhttp_del_accept_socket documentation on whether socket is closed (f665924) + o fix spelling mistake in whatsnew-2.0.txt (deb2f73) + o Fix sample/http-server ipv6 fixes (eb692be) + o Comment internal headers used in sample code. (4eb281c) + o Be explicit about how long event loops run in event.h documentation (f95bafb) + o Add comment to configure.in to explain gc-sections test logic (c621359) + o Fix a couple of memory leaks in samples/http-server.c. Found by Dave Hart. (2e9f665) + + + +BUILD IMPROVEMENTS: + Libevent 2.1.2-alpha modernizes Libevent's use of autotools, and makes + numerous other build system. Parallel builds should be faster, and all + builds should be quieter. + + o Split long lists in Makefile.am into one-item-per-line (2711cda) + o Remove unnecessary code in configure.in. (e65914f Ross Lagerwall) + o attempt to support OpenSSL in Makefile.nmake (eba0eb2 Patrick Pelletier) + o Use newer syntax for autoconf/automake init (7d60ba8) + o Enable silent build rules by default. Override with V=1 (7b18e5c) + o Switch to non-recursive makefiles (7092f3b) + o Rename subordinate Makefile.ams to include.am (6cdfeeb) + o Make quiet build even quieter (371a123) + o New --quiet option for event_rpcgen.py (aa59c1e) + o Be quiet when making regress.gen.[ch] (607a8ff) + o Fix handling of no-python case for nonrecursive make (1e3123d) + o We now require automake 1.9 or later. Modernize! (b7f6e89) + o Rename configure.in to configure.ac. (b3fea67 Ross Lagerwall) + o Use correct openssl libs and includes in pkgconfig file (d70af27) + o Use the same CFLAGS for openssl when building unit tests as with + libevent (1d9d511) + +DOCUMENTATION + o Note that make_base_notifiable should not be necessary (26ee5f9) + o Be more clear that LEV_OPT_DEFERRED_ACCEPT has tricky prereqs (371efeb) + o Add caveat to docs about bufferevent_free() with data in outbuf (6fab9ee) + o Make it more clear that NOLOCK means "I promise, no multithreading" + (9444524) + o Fix a comment in test-fdleak after 077c7e949. (3881d8f Ross Lagerwall) + o Make the Makefile.nmake warning slightly less dire (e7bf4c8) + o Fix typo : events instead of evets (05f1aca Azat Khuzhin) + o Additional comments about OPENSSL_DIR variable, prompted by Dave Hart + (6bde2ef Patrick Pelletier) + +EVHTTP: + o ignore LWS after field-content in headers (370a2c0 Artem Germanov) + o Clean up rtrim implementation (aa59d80) + o Remove trailing tabs in HTTP headers as well. (ac42519) + o Remove internal ws from multiline http headers correctly (c6ff381) + o Move evutil_rtrim_lws_ to evutil.c where it belongs (61b93af) + o add evhttp_request_get_response_code_line (4f4d0c9 Jay R. Wren) + o Use EVUTIL_SOCKET_ERROR() wrapper to save/restore errno in + evhttp_connection_fail_ (7afbd60) + o preserve errno in evhttp_connection_fail_ for inspection by the + callback (36d0ee5 Patrick Pelletier) + +BUGFIXES: + o Correctly handle running on a system where accept4 doesn't work. (9fbfe9b) + o Avoid double-free on error in evbuffer_add_file. Found by + coverity. (6a81b1f) + o Fix another possible uninitialized read in dns regression tests. Found + by coverity. (13525c5) + o Add checks for functions in test-ratelim.c; found by Coverity (aa501e1) + o Avoid memory leak in test_event_calloc unit test; found by coverity + (92817a1) + o Fix a shadowed variable in addfile_test_readcb; found by coverity + (225344c) + o Check return value when using LEV_OPT_DEFERRED_ACCEPT. Found by + coverity (6487f63) + o Prevent reference leak of bufferevent if getaddrinfo fails. (b757786 + Joachim Bauch) + o Make event_base_getnpriorities work with old "implicit base" code + (c46cb9c) + o Simplify and correct evutil_open_closeonexec_ (0de587f) + o Fix event_dlist definition when sys/queue not included (81b6209 + Derrick Pallas) + + + +Changes in version 2.1.1-alpha (4 Apr 2012) + + Libevent 2.1.1-alpha includes a number of new features and performance + improvements. The log below tries to organize them by rough area of + effect. It omits some commits which were pure bugfixes on other commits + listed below. For more detail, see the git changelogs. For more + insight, see the "whatsnew-2.1.txt" document included in the Libevent + 2.1.1-alpha distribution. + + Performance: Core + o Replace several TAILQ users with LIST. LIST can be a little faster than + TAILQ for cases where we don't need queue-like behavior. (f9db33d, + 6494772, d313c29, 974d004) + o Disabled code to optimize the case where we reinsert an existing + timeout (e47042f, 09cbc3d) + o Remove a needless base-notify when rescheduling the first timeout (77a96fd) + o Save a needless comparison when removing/adjusting timeouts (dd5189b) + o Possible optimization: split event_queue_insert/remove into + separate functions. needs testing (efc4dc5) + o Make event_count maintenance branchless at the expense of an + extra shift. Needs benchmarking (d1cee3b) + o In the 2.1 branch, let's try out lazy gettimeofday/clock_gettime + comparison (2a83ecc) + o Optimization in event_process_active(): ignore maxcb & endtime + for highest priority events. (a9866aa Alexander Drozdov) + o Bypass event_add when using event_base_once() for a 0-sec timeout (35c5c95) + o Remove the eventqueue list and the ev_next pointers. (604569b 066775e) + + Performance: Evbuffers + o Roughly 20% speed increase when line-draining a buffer using + EVBUFFER_EOL_CRLF (5dde0f0 Mina Naguib) + o Try to squeeze a little more speed out of EVBUFFER_EOL_CRLF (7b9d139) + o Fix a bug in the improved EOL_CRLF code (d927965) + o Remove a needless branch in evbuffer_drain() (d19a326) + + Performance: Linux + o Infrastructure for using faster/fewer syscalls when creating + sockets (a1c042b) + o Minimize syscalls during socket creation in listener.c (7e9e289) + o Use a wrapper function to create the notification + pipe/socketpair/eventfd (ca76cd9) + o Use pipes for telling signals to main thread when possible (a35f396) + o Save syscalls when constructing listener sockets for evhttp (af6c9d8) + o Save some syscalls when creating evdns sockets (713e570) + o Save some syscalls when constructing a socket for a bufferevent (33fca62) + o Prefer epoll_create1 on Linuxen that have it (bac906c) + + Performance: Epoll backend + o Use current event set rather than current pending change when + deciding whether to no-op a del (04ba27e Mike Smellie) + o Replace big chain of if/thens in epoll.c with a table lookup (8c83eb6) + o Clean up error handling in epoll_apply_one_change() a little (2d55a19) + + Performance: Evport backend + o evport: use evmap_io to track fdinfo status. Should save time and + RAM. (4687ce4) + o evport: Remove a linear search over recent events when + reactivating them (0f77efe) + o evport: Use portev_user to remember fdinfo struct (276ec0e) + o evport: don't scan more events in ed_pending than needed (849a5cf) + o evport: Remove artificial low limit on max events per getn call (c04d927) + o Reenable main/many_events_slow_add for evport in 2.1 (e903db3) + + Performance: Windows + o Use GetSystemTimeAsFileTime to implement gettimeofday on + win32. It's faster and more accurate than our old + approach. (b8b8aa5) + + New functions and features: debugging + o Add event_enable_debug_logging() to control use of debug logs (e30a82f) + + New functions and features: core + o Add event_config function to limit time/callbacks between calls + to dispatch (fd4de1e, 9fa56bd, a37a0c0, 3c63edd) + o New EVLOOP_NO_EXIT_ON_EMPTY option to keep looping even when no + events are pending (084e68f) + o Add event_base_get_npriorities() function. (ee3a4ee Alexander Drozdov) + o Make evbase_priority_init() and evbase_get_npriorities() + threadsafe (3c55b5e) + o New event_base_update_cache_time() to set cached_tv to current + time (212533e Abel Mathew) + o Add event_self_cbarg() to be used in conjunction with + event_new(). (ed36e6a Ross Lagerwall, fa931bb, 09a1906, 1338e6c, + 33e43ef) + o Add a new libevent_global_shutdown() to free all globals before + exiting. (041ca00 Mark Ellzey, f98c158, 15296d0, 55e991b) + o Use getifaddrs to detect our interfaces if possible (7085a45) + o Add event_base_get_running_event() to get the event* whose cb we + are in (c5732fd, 13dad99) + + New functions and features: building + o Implement --enable-gcc-hardening configure option (7550267 Sebastian Hahn) + + New functions and features: evbuffers + o Add evbuffer_add_file_segment() so one fd can be used efficiently + in more than one evbuffer_add_file at a time (e72afae, c2d9884, + 3f405d2, 0aad014) + o Fix windows file segment mappings (8254de7) + o Allow evbuffer_ptr_set to yield a point just after the end of the + buffer. (e6fe1da) + o Allow evbuffer_ptr to point to position 0 in an empty evbuffer + (7aeb2fd Nir Soffer) + o Set the special "not found" evbuffer_ptr consistently. (e3e97ae Nir Soffer) + o support adding buffers to other buffers non-destructively + (9d7368a Joachim Bauch) + o prevent nested multicast references, reworked locking (26041a8 + Joachim Bauch) + o New EVBUFFER_EOL_NUL to read NUL-terminated strings from an + evbuffer (d7a8b36 Andrea Montefusco, 54142c9) + o Make evbuffer_file_segment_types adaptable (c6bbbf1) + o Added evbuffer_add_iovec and unit tests. (aaec5ac Mark Ellzey, 27b5398) + o Add evbuffer_copyout_from to copy data from the middle of a + buffer (27e2225) + + New functions and features: bufferevents + o Allow users to set allow_dirty_shutdown (099d27d Catalin Patulea) + o Tweak allow_dirty_shutdown documentation (a44cd2b) + o Fix two issues in the allow_dirty_shutdown code. (f3b89de) + o Add a bufferevent_getcb() to find a bufferevent's current + callbacks (a650394) + o bufferevent: Add functions to set/get max_single_read/write + values. (998c813 Alexander Drozdov) + o bev_ssl: Be more specific in event callbacks. evhttp in particular gets + confused without at least one of BEV_EVENT_{READING|WRITING}. (f7eb69a + Catalin Patulea) + + New functions and features: evconnlisteners + o Support TCP_DEFER_ACCEPT sockopts for listeners (5880e4a Mark Ellzey, + a270728) + o Add another caveat to the TCP_DEFER_ACCEPT documentation (a270728) + o Allow evconnlistener to be created in disabled state. (9593a33 + Alexander Drozdov) + o The LEV_OPT_CLOSE_ON_EXEC flag now applies to accepted listener + sockets too (4970329) + + Evhttp: + o Add new evhttp_{connection_}set_timeout_tv() functions to set + finger-grained http timeouts (6350e6c Constantine Verutin) + o Performance tweak to evhttp_parse_request_line. (aee1a97 Mark Ellzey) + o Add missing break to evhttp_parse_request_line (0fcc536) + o Add evhttp callback for bufferevent creation; this lets evhttp + support SSL. (8d3a850) + o Remove calls to deprecated bufferevent functions from evhttp.c (4d63758) + o evhttp: Add evhttp_foreach_bound_socket. (a2c48e3 Samy Al Bahra) + + Build improvements: + o Add AC_USE_SYSTEM_EXTENSIONS to configure.in. Requires follow on + patches for correctness and robustness. (1fa7dbe Kevin Bowling) + o Filter '# define' statements from autoconf and generate + event-private.h (321b558 Kevin Bowling) + o Remove internal usage of _GNU_SOURCE (3b26541 Kevin Bowling) + o Eliminate a couple more manual internal _GNU_SOURCE defines (c51ef93 + Kevin Bowling) + o Add AC_GNU_SOURCE to the fallback case. (ea8fa4c Kevin Bowling) + o Use a Configuration Header Template for evconfig-private.h (868f888 + Kevin Bowling) + o Fix a comment warning and add evconfig-private.h to .gitignore + (f6d66bc Kevin Bowling) + o Include evconfig-private.h in internal files for great good. (0915ca0 + Kevin Bowling) + o Backport libevent to vanilla Autoconf 2.59 (as used in RHEL5) + (ad03952 Kevin Bowling) + o Prefer the ./configure evconfig-private.h in MinGW, just in + case. (f964b72 Kevin Bowling) + o Shell hack for weird mkdir -p commands (fd7b5a8 Kevin Bowling) + o Add evconfig-private to remaining files (ded0a09 Kevin Bowling) + o Allow use of --enable-silent-rules for quieter compilation with + automake 1.11 (f1f8514 Dave Hart) + o Use "_WIN32", not WIN32: it's standard and we don't need to fake it + (9f560b) + o In configure, test for _WIN32 not WIN32. (85078b1 Peter Rosin) + o Do not define WIN32 in Makefile.nmake (d41f3ea Peter Rosin) + o Provide the autoconf m4 macros for the new OpenSSL via pkg-config + stuff. (674dc3d Harlan Stenn) + o Use pkg-config (if available) to handle OpenSSL. (1c63860 Harlan Stenn) + o We need AM_CPPFLAGS when compiling bufferevent_openssl.c (6d2613b + Harlan Stenn) + o Fix OSX build: $(OPENSSL_INCS) needs to be after + $(AM_CPPFLAGS). (46f1769 Zack Weinberg) + o Make gcc warnings on by default, and --enable-gcc-warnings only add + -Werror (d46517e Sebastian Hahn) + o Split up extra-long AC_CHECK_FUNCS/HEADERS lines in configure.in (88a30ad) + o Move libevent 1.x headers to include/, to put all public headers in + one place. (bbea8d6) + o Put #ifdef around some files to support alternate build + systems. (76d4c92 Ross Lagerwall) + o Also make win32select.c conditional for IDE users (bf2c5a7) + + Debugging: + o Add a magic number to debug_locks to better catch lock-coding + errors. (b4a29c0 Dave Hart) + o munge the debug_lock signature before freeing it: it might help us + catch use-after-free (f28084d) + o Added --enable-event-debugging in configure (bc7b4e4, a9c2c9a Mark Ellzey) + o Debug addition for printing usec on TIMEOUT debugging. (ac43ce0 Mark Ellzey) + o Added usec debug in another area for debug (3baab0d Mark Ellzey) + o added timeout debug logs to include event ptr. (4b7d298 Mark Ellzey) + o more event dbg updates (6727543 Mark Ellzey) + o Clarify event_enable_debug_logging a little (6207826) + o Make --enable-verbose-debug option match its help text (10c3450) + o Add argument checks to some memory functions in `event.c'. (c8953d1 + Mansour Moufid) + + Testing: + o More abstraction in test.sh (cd74c4e) + o Add failing test for evbuffer_search_range. (8e26154 Nir Soffer) + o Tweaks to return types with end-of-buf ptrs (9ab8ab8) + o Add an (internal) usleep function for use by unit tests (f25d9d3) + o Synchronize with upstream tinytest (6c81be7) + o Make test-changelist faster (7622d26) + o Reduce the timeout in the main/fork test. (ab14f7c) + o New evhttp function to adjust initial retry timeout (350a3c4) + o Make regression tests run over 3x faster. (67a1763) + o Use test_timeval_diff_eq more consistently (b77b43f) + o Allow more slop in deferred_cb_skew test; freebsd needs it (b9f7e5f) + o When including an -internal.h header outside the main tree, do so + early (95e2455) + o Add a new test: test-fdleak which tests for fd leaks by creating many + sockets. (2ef9278 Ross Lagerwall, f7af194, 1c4288f, etc) + o Add a unit test for event_base_dump_events() (7afe48a, 8d08cce) + o Test more bufferevent_ratelim features (c24f91a) + + Documentation: + o Improve evbuffer_ptr documentation (261ba63) + o added comments to describe refcounting of multicast chains (ba24f61 + Joachim Bauch) + o Add doxygen for event_base_dump_events (cad5753) + + OSX: + o Use "unlimited select" on OSX so that we can have more than + FD_SETSIZE fds (1fb5cc6) + + KQueue: + o Use SIG_IGN instead of a do-nothing handler for signal events with + kqueue (148458e Zack Weinberg) + + evprc: + o event_rpcgen.py now prints status information to stdout and errors to + stderr. (ffb0ba0 Ross Lagerwall) + + Code improvement and refactoring: + o Make event_reinit() more robust and maintainable (272033e) + o Restore fast-path event_reinit() for slower backends (2c4b5de) + o Check changelist as part of checking representational integrity (39b3f38) + o Fix a compile warning in event_reinit (e4a56ed Sebastian Hahn) + o Refactor the functions that run over every event. (c89b4e6) + o Remove the last vestiges of _EVENT_USE_EVENTLIST (a3cec90) + o Make event-config.h depend on Makefile.am (2958a5c) + + Build fixes: + o Don't do clang version detection when disabling some flags (083296b + Sebastian Hahn) + + C standards conformance: + o Check for NULL return on win32 mm_calloc, and set ENOMEM. (af7ba69) + o Convert event-config.h macros to avoid reserved identifiers (68120d9) + o Generate event-config.h using the correct macros. (f82c57e) + o Convert include-guard macro convention to avoid reserved identifiers + (3f8c7cd) + o Make event_rpcgen.py output conform to identifier conventions (372bff1) + o Stop referring to an obsolete include guard in bench_http.h (5c0f7e0) + o Make the generated event-config.h use correct include guards (639383a) + o Fix all identifiers with names beginning with underscore. (cb9da0b) + o Make event_rpcgen.py output conform to identifier conventions, more + (bcefd24) + o Fix some problems introduced by automated identifier cleanup script + (c963534) + o Have all visible internal function names end with an underscore. (8ac3c4c) + o Apply the naming convention to our EVUTIL_IS* functions (c7848fa) + o Clean up lingering _identifiers. (946b584) + o Fix doxygen to use new macro conventions (da455e9) + + Bugfixes: + o Do not use system EAI/AI values if we are not using the system + getaddrinfo. (7bcac07) + + Sample Code: + o Fix up sample/event-test.c to use newer interfaces and make it + actually work. (19bab4f Ross Lagerwall) + o On Unix, remove event.fifo left by sample/event-test.c. (c0dacd2 Ross + Lagerwall) + o Rename event-test.c to event-read-fifo.c. (a5b370a Ross Lagerwall) + o event-read-fifo: Use EV_PERSIST appropriately (24dab0b) + + + + diff --git a/contrib/ntp/sntp/libevent/ChangeLog-1.4 b/contrib/ntp/sntp/libevent/ChangeLog-1.4 new file mode 100644 index 000000000..166d30872 --- /dev/null +++ b/contrib/ntp/sntp/libevent/ChangeLog-1.4 @@ -0,0 +1,231 @@ +Changes in 1.4.14b-stable + o Set the VERSION_INFO correctly for 1.4.14 + +Changes in 1.4.14-stable + o Add a .gitignore file for the 1.4 branch. (d014edb) + o Backport evbuffer_readln(). (b04cc60 Nicholas Marriott) + o Make the evbuffer_readln backport follow the current API (c545485) + o Valgrind fix: Clear struct kevent before checking for OSX bug. (5713d5d William Ahern) + o Fix a crash when reading badly formatted resolve.conf (5b10d00 Yasuoka Masahiko) + o Fix memory-leak of signal handler array with kqueue. [backport] (01f3775) + o Update sample/signal-test.c to use newer APIs and not leak. (891765c Evan Jones) + o Correct all versions in 1.4 branch (ac0d213) + o Make evutil_make_socket_nonblocking() leave any other flags alone. (81c26ba Jardel Weyrich) + o Adjusted fcntl() retval comparison on evutil_make_socket_nonblocking(). (5f2e250 Jardel Weyrich) + o Correct a debug message in evhttp_parse_request_line (35df59e) + o Merge branch 'readln-backport' into patches-1.4 (8771d5b) + o Do not send an HTTP error when we've already closed or responded. (4fd2dd9 Pavel Plesov) + o Re-add event_siglcb; some old code _was_ still using it. :( (bd03d06) + o Make Libevent 1.4 build on win32 with Unicode enabled. (bce58d6 Brodie Thiesfield) + o Distribute nmake makefile for 1.4 (20d706d) + o do not fail while sending on http connections the client closed. (5c8b446) + o make evhttp_send() safe against terminated connections, too (01ea0c5) + o Fix a free(NULL) in min_heap.h (2458934) + o Fix memory leak when setting up priorities; reported by Alexander Drozdov (cb1a722) + o Clean up properly when adding a signal handler fails. (ae6ece0 Gilad Benjamini) + o Do not abort HTTP requests missing a reason string. (29d7b32 Pierre Phaneuf) + o Fix compile warning in http.c (906d573) + o Define _REENTRANT as needed on Solaris, elsewhere (6cbea13) + + +Changes in 1.4.13-stable: + o If the kernel tells us that there are a negative number of bytes to read from a socket, do not believe it. Fixes bug 2841177; found by Alexander Pronchenkov. + o Do not allocate the maximum event queue and fd array for the epoll backend at startup. Instead, start out accepting 32 events at a time, and double the queue's size when it seems that the OS is generating events faster than we're requesting them. Saves up to 512K per epoll-based event_base. Resolves bug 2839240. + o Fix compilation on Android, which forgot to define fd_mask in its sys/select.h + o Do not drop data from evbuffer when out of memory; reported by Jacek Masiulaniec + o Rename our replacement compat/sys/_time.h header to avoid build a conflict on HPUX; reported by Kathryn Hogg. + o Build kqueue.c correctly on GNU/kFreeBSD platforms. Patch pulled upstream from Debian. + o Fix a problem with excessive memory allocation when using multiple event priorities. + o When running set[ug]id, don't check the environment. Based on a patch from OpenBSD. + + +Changes in 1.4.12-stable: + o Try to contain degree of failure when running on a win32 version so heavily firewalled that we can't fake a socketpair. + o Fix an obscure timing-dependent, allocator-dependent crash in the evdns code. + o Use __VA_ARGS__ syntax for varargs macros in event_rpcgen when compiler is not GCC. + o Activate fd events in a pseudorandom order with O(N) backends, so that we don't systematically favor low fds (select) or earlier-added fds (poll, win32). + o Fix another pair of fencepost bugs in epoll.c. [Patch from Adam Langley.] + o Do not break evdns connections to nameservers when our IP changes. + o Set truncated flag correctly in evdns server replies. + o Disable strict aliasing with GCC: our code is not compliant with it. + +Changes in 1.4.11-stable: + o Fix a bug when removing a timeout from the heap. [Patch from Marko Kreen] + o Remove the limit on size of HTTP headers by removing static buffers. + o Fix a nasty dangling pointer bug in epoll.c that could occur after epoll_recalc(). [Patch from Kevin Springborn] + o Distribute Win32-Code/event-config.h, not ./event-config.h + +Changes in 1.4.10-stable: + o clean up buffered http connection data on reset; reported by Brian O'Kelley + o bug fix and potential race condition in signal handling; from Alexander Drozdov + o rename the Solaris event ports backend to evport + o support compilation on Haiku + o fix signal processing when a signal callback delivers a signal; from Alexander Drozdov + o const-ify some arguments to evdns functions. + o off-by-one error in epoll_recalc; reported by Victor Goya + o include Doxyfile in tar ball; from Jeff Garzik + o correctly parse queries with encoded \r, \n or + characters + +Changes in 1.4.9-stable: + o event_add would not return error for some backends; from Dean McNamee + o Clear the timer cache on entering the event loop; reported by Victor Chang + o Only bind the socket on connect when a local address has been provided; reported by Alejo Sanchez + o Allow setting of local port for evhttp connections to support millions of connections from a single system; from Richard Jones. + o Clear the timer cache when leaving the event loop; reported by Robin Haberkorn + o Fix a typo in setting the global event base; reported by lance. + o Fix a memory leak when reading multi-line headers + o Fix a memory leak by not running explicit close detection for server connections + +Changes in 1.4.8-stable: + o Match the query in DNS replies to the query in the request; from Vsevolod Stakhov. + o Fix a merge problem in which name_from_addr returned pointers to the stack; found by Jiang Hong. + o Do not remove Accept-Encoding header + +Changes in 1.4.7-stable: + o Fix a bug where headers arriving in multiple packets were not parsed; fix from Jiang Hong; test by me. + +Changes in 1.4.6-stable: + o evutil.h now includes directly + o switch all uses of [v]snprintf over to evutil + o Correct handling of trailing headers in chunked replies; from Scott Lamb. + o Support multi-line HTTP headers; based on a patch from Moshe Litvin + o Reject negative Content-Length headers; anonymous bug report + o Detect CLOCK_MONOTONIC at runtime for evdns; anonymous bug report + o Fix a bug where deleting signals with the kqueue backend would cause subsequent adds to fail + o Support multiple events listening on the same signal; make signals regular events that go on the same event queue; problem report by Alexander Drozdov. + o Deal with evbuffer_read() returning -1 on EINTR|EAGAIN; from Adam Langley. + o Fix a bug in which the DNS server would incorrectly set the type of a cname reply to a. + o Fix a bug where setting the timeout on a bufferevent would take not effect if the event was already pending. + o Fix a memory leak when using signals for some event bases; reported by Alexander Drozdov. + o Add libevent.vcproj file to distribution to help with Windows build. + o Fix a problem with epoll() and reinit; problem report by Alexander Drozdov. + o Fix off-by-one errors in devpoll; from Ian Bell + o Make event_add not change any state if it fails; reported by Ian Bell. + o Do not warn on accept when errno is either EAGAIN or EINTR + +Changes in 1.4.5-stable: + o Fix connection keep-alive behavior for HTTP/1.0 + o Fix use of freed memory in event_reinit; pointed out by Peter Postma + o Constify struct timeval * where possible; pointed out by Forest Wilkinson + o allow min_heap_erase to be called on removed members; from liusifan. + o Rename INPUT and OUTPUT to EVRPC_INPUT and EVRPC_OUTPUT. Retain INPUT/OUTPUT aliases on on-win32 platforms for backwards compatibility. + o Do not use SO_REUSEADDR when connecting + o Fix Windows build + o Fix a bug in event_rpcgen when generated fixed-sized entries + +Changes in 1.4.4-stable: + o Correct the documentation on buffer printf functions. + o Don't warn on unimplemented epoll_create(): this isn't a problem, just a reason to fall back to poll or select. + o Correctly handle timeouts larger than 35 minutes on Linux with epoll.c. This is probably a kernel defect, but we'll have to support old kernels anyway even if it gets fixed. + o Fix a potential stack corruption bug in tagging on 64-bit CPUs. + o expose bufferevent_setwatermark via header files and fix high watermark on read + o fix a bug in bufferevent read water marks and add a test for them + o introduce bufferevent_setcb and bufferevent_setfd to allow better manipulation of bufferevents + o use libevent's internal timercmp on all platforms, to avoid bugs on old platforms where timercmp(a,b,<=) is buggy. + o reduce system calls for getting current time by caching it. + o fix evhttp_bind_socket() so that multiple sockets can be bound by the same http server. + o Build test directory correctly with CPPFLAGS set. + o Fix build under Visual C++ 2005. + o Expose evhttp_accept_socket() API. + o Merge windows gettimeofday() replacement into a new evutil_gettimeofday() function. + o Fix autoconf script behavior on IRIX. + o Make sure winsock2.h include always comes before windows.h include. + +Changes in 1.4.3-stable: + o include Content-Length in reply for HTTP/1.0 requests with keep-alive + o Patch from Tani Hosokawa: make some functions in http.c threadsafe. + o Do not free the kqop file descriptor in other processes, also allow it to be 0; from Andrei Nigmatulin + o make event_rpcgen.py generate code include event-config.h; reported by Sam Banks. + o make event methods static so that they are not exported; from Andrei Nigmatulin + o make RPC replies use application/octet-stream as mime type + o do not delete uninitialized timeout event in evdns + +Changes in 1.4.2-rc: + o remove pending timeouts on event_base_free() + o also check EAGAIN for Solaris' event ports; from W.C.A. Wijngaards + o devpoll and evport need reinit; tested by W.C.A Wijngaards + o event_base_get_method; from Springande Ulv + o Send CRLF after each chunk in HTTP output, for compliance with RFC2626. Patch from "propanbutan". Fixes bug 1894184. + o Add a int64_t parsing function, with unit tests, so we can apply Scott Lamb's fix to allow large HTTP values. + o Use a 64-bit field to hold HTTP content-lengths. Patch from Scott Lamb. + o Allow regression code to build even without Python installed + o remove NDEBUG ifdefs from evdns.c + o update documentation of event_loop and event_base_loop; from Tani Hosokawa. + o detect integer types properly on platforms without stdint.h + o Remove "AM_MAINTAINER_MODE" declaration in configure.in: now makefiles and configure should get re-generated automatically when Makefile.am or configure.in chanes. + o do not insert event into list when evsel->add fails + +Changes in 1.4.1-beta: + o free minheap on event_base_free(); from Christopher Layne + o debug cleanups in signal.c; from Christopher Layne + o provide event_base_new() that does not set the current_base global + o bufferevent_write now uses a const source argument; report from Charles Kerr + o better documentation for event_base_loopexit; from Scott Lamb. + o Make kqueue have the same behavior as other backends when a signal is caught between event_add() and event_loop(). Previously, it would catch and ignore such signals. + o Make kqueue restore signal handlers correctly when event_del() is called. + o provide event_reinit() to reintialize an event_base after fork + o small improvements to evhttp documentation + o always generate Date and Content-Length headers for HTTP/1.1 replies + o set the correct event base for HTTP close events + o New function, event_{base_}loopbreak. Like event_loopexit, it makes an event loop stop executing and return. Unlike event_loopexit, it keeps subsequent pending events from getting executed. Patch from Scott Lamb + o Removed obsoleted recalc code + o pull setters/getters out of RPC structures into a base class to which we just need to store a pointer; this reduces the memory footprint of these structures. + o fix a bug with event_rpcgen for integers + o move EV_PERSIST handling out of the event backends + o support for 32-bit tag numbers in rpc structures; this is wire compatible, but changes the API slightly. + o prefix {encode,decode}_tag functions with evtag to avoid collisions + o Correctly handle DNS replies with no answers set (Fixes bug 1846282) + o The configure script now takes an --enable-gcc-warnigns option that turns on many optional gcc warnings. (Nick has been building with these for a while, but they might be useful to other developers.) + o When building with GCC, use the "format" attribute to verify type correctness of calls to printf-like functions. + o removed linger from http server socket; reported by Ilya Martynov + o allow \r or \n individually to separate HTTP headers instead of the standard "\r\n"; from Charles Kerr. + o demote most http warnings to debug messages + o Fix Solaris compilation; from Magne Mahre + o Add a "Date" header to HTTP responses, as required by HTTP 1.1. + o Support specifying the local address of an evhttp_connection using set_local_address + o Fix a memory leak in which failed HTTP connections would not free the request object + o Make adding of array members in event_rpcgen more efficient, but doubling memory allocation + o Fix a memory leak in the DNS server + o Fix compilation when DNS_USE_OPENSSL_FOR_ID is enabled + o Fix buffer size and string generation in evdns_resolve_reverse_ipv6(). + o Respond to nonstandard DNS queries with "NOTIMPL" rather than by ignoring them. + o In DNS responses, the CD flag should be preserved, not the TC flag. + o Fix http.c to compile properly with USE_DEBUG; from Christopher Layne + o Handle NULL timeouts correctly on Solaris; from Trond Norbye + o Recalculate pending events properly when reallocating event array on Solaris; from Trond Norbye + o Add Doxygen documentation to header files; from Mark Heily + o Add a evdns_set_transaction_id_fn() function to override the default + transaction ID generation code. + o Add an evutil module (with header evutil.h) to implement our standard cross-platform hacks, on the theory that somebody else would like to use them too. + o Fix signals implementation on windows. + o Fix http module on windows to close sockets properly. + o Make autogen.sh script run correctly on systems where /bin/sh isn't bash. (Patch from Trond Norbye, rewritten by Hagne Mahre and then Hannah Schroeter.) + o Skip calling gettime() in timeout_process if we are not in fact waiting for any events. (Patch from Trond Norbye) + o Make test subdirectory compile under mingw. + o Fix win32 buffer.c behavior so that it is correct for sockets (which do not like ReadFile and WriteFile). + o Make the test.sh script run unit tests for the evpoll method. + o Make the entire evdns.h header enclosed in "extern C" as appropriate. + o Fix implementation of strsep on platforms that lack it + o Fix implementation of getaddrinfo on platforms that lack it; mainly, this will make Windows http.c work better. Original patch by Lubomir Marinov. + o Fix evport implementation: port_disassociate called on unassociated events resulting in bogus errors; more efficient memory management; from Trond Norbye and Prakash Sangappa + o support for hooks on rpc input and output; can be used to implement rpc independent processing such as compression or authentication. + o use a min heap instead of a red-black tree for timeouts; as a result finding the min is a O(1) operation now; from Maxim Yegorushkin + o associate an event base with an rpc pool + o added two additional libraries: libevent_core and libevent_extra in addition to the regular libevent. libevent_core contains only the event core whereas libevent_extra contains dns, http and rpc support + o Begin using libtool's library versioning support correctly. If we don't mess up, this will more or less guarantee binaries linked against old versions of libevent continue working when we make changes to libevent that do not break backward compatibility. + o Fix evhttp.h compilation when TAILQ_ENTRY is not defined. + o Small code cleanups in epoll_dispatch(). + o Increase the maximum number of addresses read from a packet in evdns to 32. + o Remove support for the rtsig method: it hasn't compiled for a while, and nobody seems to miss it very much. Let us know if there's a good reason to put it back in. + o Rename the "class" field in evdns_server_request to dns_question_class, so that it won't break compilation under C++. Use a macro so that old code won't break. Mark the macro as deprecated. + o Fix DNS unit tests so that having a DNS server with broken IPv6 support is no longer cause for aborting the unit tests. + o Make event_base_free() succeed even if there are pending non-internal events on a base. This may still leak memory and fds, but at least it no longer crashes. + o Post-process the config.h file into a new, installed event-config.h file that we can install, and whose macros will be safe to include in header files. + o Remove the long-deprecated acconfig.h file. + o Do not require #include before #include . + o Add new evutil_timer* functions to wrap (or replace) the regular timeval manipulation functions. + o Fix many build issues when using the Microsoft C compiler. + o Remove a bash-ism in autogen.sh + o When calling event_del on a signal, restore the signal handler's previous value rather than setting it to SIG_DFL. Patch from Christopher Layne. + o Make the logic for active events work better with internal events; patch from Christopher Layne. + o We do not need to specially remove a timeout before calling event_del; patch from Christopher Layne. diff --git a/contrib/ntp/sntp/libevent/ChangeLog-2.0 b/contrib/ntp/sntp/libevent/ChangeLog-2.0 new file mode 100644 index 000000000..a925d33b1 --- /dev/null +++ b/contrib/ntp/sntp/libevent/ChangeLog-2.0 @@ -0,0 +1,1280 @@ +Changes in version 2.0.21-stable (18 Nov 2012) +BUGFIXES: + o ssl: Don't discard SSL read event when timeout and read come close together (576b29f) + o ssl: Stop looping in "consider_reading" if reading is suspended. (f719b8a Joachim Bauch) + o ssl: No need to reserve space if reading is suspended. (1acf2eb Joachim Bauch) + o dns: Avoid a memory-leak on OOM in evdns. (73e85dd, f2bff75 George Danchev) + o build: Use python2 rather than python (0eb0109 Ross Lagerwall) + o build: Compile without warnings on mingw64 (94866c2) + o build: Fix compilation on mingw64 with -DUSE_DEBUG (62bd2c4) + o build: Make rpcgen_wrapper.sh work on systems without a "python2" binary (f3009e4) + o iocp: Close IOCP listener socket on free when LEV_OPT_CLOSE_ON_FREE is set (cb853ea Juan Pablo Fernandez) + o core: Avoid crash when event_pending() called with no event_base set on event (e3cccf3) + o misc: remove stray 'x' so print_err will compile when uncommented (ac35650 Patrick Pelletier) + o tests: Fix renegotiation test to work around openssl 1.0.1 bug (c2f3086) + o tests: Warn when openssl version in unit test mismatches compiled version. (ac009f9) + + +Changes in version 2.0.20-stable (23 Aug 2012) +BUGFIXES: + o core: Make event_pending() threadsafe. (be7a95c Simon Liu) + o win32: avoid crash when waiting forever on zero fds. (160e58b) + o evhttp: Fix a memory leak on error in evhttp_uriencode (11c8b31) + o evbuffer: Avoid possible needless call to writev. Found by coverity. (6a4ec5c) + o evdns: memset sockaddr_in before using it. Found by coverity. (a1a0e67) + o evhttp: Check more setsockopt return values when binding sockets. Found by coverity (a0912e3) + o evdns: Avoid segfault on weird timeout during name lookup. (dc32077 Greg Hazel) + o bufferevent_ssl: Correctly invoke callbacks when a SSL bufferevent reads some and then blocks. (606ac43) + + +PORTABILITY FIXES: + o check for arc4random_buf at runtime, on OS X (bff5f94 Greg Hazel) + o Correctly check for arc4random_buf (fcec3e8 Sebastian Hahn) + o Add explicit AC_PROG_SED to configure.in so all autoconfs will expose $(SED) (ca80ea6) + +BUILD FIXES: + o Add GCC annotations so that the vsprintf functions get checked properly (117e327) + o Fix an unused variable warning on *BSD. (c0720c1) + +UNIT TEST FIXES: + o Fix a couple of memory leaks (found with Valgrind). (3b2529a Ross Lagerwall) + o Remove deadcode in http regression tests. Found by coverity. (5553346) + o Fix possible uninitialized read in dns regression tests. Found by coverity. (2259777) + o Set umask before calling mkstemp in unit tests. Found by coverity (f1ce15d) + o Fix various check-after-dereference issues in unit tests: found by coverity (4f3732d) + o Fix resource leaks in the unit tests; found by coverity (270f279) + o Add some missing null checks to unit tests; found by coverity (f021c3d) + o Avoid more crashes/bad calls in unit tests; found by coverity (3cde5bf) + o Remove unused variable; spotted by coverity (6355b2a) + o Add checks to various return values in unit tests. Found by coverity (b9e7329) + o Move assignment outside tt_assert in ssl unit tests. Appeases coverity. (a2006c0) + + + +Changes in version 2.0.19-stable (3 May 2012) +BUGFIXES (CORE): + o Refactor event_persist_closure: raise and extract some common logic (bec22b4) + o If time has jumped so we'd reschedule a periodic event in the past, schedule it for the future instead (dfd808c) + o If a higher-priority event becomes active, don't continue running events of the current priority. (2bfda40) + +BUGFIXES (SSL): + o Fixed potential double-readcb execution with openssl bufferevents. (4e62cd1 Mark Ellzey) + +BUGFIXES (DNS): + o Cancel a probe request when the server is freed, and ignore cancelled probe callbacks (94d2336 Greg Hazel) + o Remove redundant DNS_ERR_CANCEL check, move comment (46b8060 Greg Hazel) + o When retransmitting a timed-out DNS request, pick a fresh nameserver. (3d9e52a) + +DOCUMENTATION FIXES: + o Fix a typo in the bufferevent documentation (98e9119) + o Add missing ) to changelog; spotted by rransom (4c7ee6b) + o Fix the website URL in the readme (f775521) + +COMPILATION FIXES: + o Fix a compilation error with MSVC 2005 due to use of mode_t (336dcae) + o Configure with gcc older than 2.95 (4a6fd43 Sebastian Hahn) + o Generate event-config.h with a single sed script (30b6f88 Zack Weinberg) + +FORWARD-COMPATIBILITY: + o Backport: provide EVENT_LOG_* names, and deprecate _EVENT_LOG_* (d1a03b2) + +TESTING/DEBUGGING SUPPORT: + o dns-example.c can now take a resolv.conf file on the commandline (6610fa5) + o Make some evdns.c debug logs more verbose (d873d67) + o Work-around a stupid gcov-breaking bug in OSX 10.6 (b3887cd) + + + +Changes in version 2.0.18-stable (22 Mar 2012) +BUGFIXES (core): + o Make uses of open() close-on-exec safe by introducing an internal evutil_open_closeonexec. (d2b5f72 Ross Lagerwall, 03dce42) + +BUGFIXES (kqueue): + o Properly zero the kevent in kq_setup_kevent() (c2c7b39 Sebastian Hahn) + +BUILD FIXES: + o Added OPENSSL_LDFLAGS env variable which is appended to SSL checks. (9278196 Mark Ellzey) + o Changed OPENSSL_LDFLAGS to OPENSSL_LIBADD (2d67b63 Mark Ellzey) + o Don't do clang version detection when disabling some flags (083296b Sebastian Hahn) + +BUGFIXES (dns): + o Stop crashing in evdns when nameserver probes give a weird error (bec5068) + + +Changes in version 2.0.17-stable (10 Feb 2012) + +BUGFIXES (core): + o Be absolutely sure to clear pncalls before leaving event_signal_closure (11f36a5) + o check for sysctl before we use it (358c745 Mike Frysinger) + o Remove bogus casts of socket to int before calling ev_callback (f032516) + o Make evconnlistener work around bug in older Linux when getting nmapped (ecfc720) + o Fix a list corruption bug when using event_reinit() with signals present (6e41cdc) + o Fix a fd leak in event_reinit() (3f18ad1) + o Do a memberwise comparison of threading function tables (c94a5f2 Nate R) + o Use C-style comments in C source files (for compatibility with compilers such as xlc on AIX). (d84d917 Greg Hewgill) + o Avoid crash when freeing event_iocp and using event_set_mem_functions (19715a6) + o In the kqueue backend, do not report EBADF as an EV_READ (5d7bfa1 Nicholas Marriott) + +BUGFIXES (evbuffer and bufferevents): + o Fix behavior of evbuffer_peek(buf,-1,NULL,NULL,0) (c986f23 Zack Weinberg) + o Loop on filtering SSL reads until we are blocked or exhausted. (5b4b812) + +BUGFIXES (evhttp): + o Force strict validation of HTTP version in response. (790f6b3 Catalin Patulea) + +BUGFIXES (evdns): + o evdns: fix a bug in circular-queue implementation (d6094b1) + +BUILD FIXES: + o Fix a silly compilation error with the sun compiler (1927776 Colin Watt) + o Suppress a gcc warning from ignoring fwrite return in http-sample.c (7206e8c) + +DOCUMENTATION FIXES: + o Slightly clarify evbuffer_peek documentation (7bbf6ca) + o Update copyright notices to 2012 (e49e289) + +NEW APIS: + o Backport evhttp_connection_get_bufferevent to Libevent 2.0 (da70fa7 Arno Bakker) + +TESTS AND TEST FIXES: + o Fix a race condition in the dns/bufferevent_connect_hostname test. (cba48c7) + o Add function to check referential integrity of an event_base (27737d5) + o Check event_base correctness at end of each unit test (3312b02) + o Workaround in the unit tests for an apparent epoll bug in Linux 3.2 (dab9187) + o Better workaround for Linux 3.2 edge-triggered epoll bug (9f9e259) + +Changes in version 2.0.16-stable (18 Nov 2011) +BUGFIXES (core): + o More detailed message in case of libevent self-debugging failure. (9e6a4ef Leonid Evdokimov) + o epoll: close fd on alloc fail at initialization (1aee718 Jamie Iles) + o Fix compile warning from saying event2/*.h inside a comment (447b0ba) + o Warn when unable to construct base because of failing make_base_notifiable (4e797f3) + o Don't try to make notifiable event_base when no threading fns are configured (e787413) + +BUGFIXES (evbuffer): + o unit test for remove_buffer bug (90bd620 Greg Hazel) + o Fix an evbuffer crash in evbuffer_remove_buffer() (c37069c) + +BUGFIXES (bufferevent_openssl): + o Refactor amount-to-read calculations in buffervent_ssl consider_reading() (a186e73 Mark Ellzey) + o Move SSL rate-limit enforcement into bytes_to_read() (96c562f) + o Avoid spinning on OpenSSL reads (2aa036f Mark Ellzey) + +BUGFIXES (dns) + o Empty DNS reply with OK status is another way to say NODATA. (21a08d6 Leonid Evdokimov) + +TESTING: + o Tests for 94fba5b and f72e8f6 (d58c15e Leonid Evdokimov) + o Test for commit aff6ba1 (f7841bf Leonid Evdokimov) + o Style and comment tweaks for dns/leak* tests (5e42202) + o improve test to remove at least one buffer from src (7eb52eb Greg Hazel) + +DOCUMENTATION: + o Add note about evhttp_send_reply_end to its doxygen (724bfb5) + o Update copyright dates to 2011. (3c824bd) + o Fix typo in whatsnew-2.0.txt (674bc6a Mansour Moufid) + o Improve win32 behavior of dns-sample.c code (a3f320e Gisle Vanem) + + + +Changes in version 2.0.15-stable (12 Oct 2011) +BUGFIXES (DNS): + o DNS: add ttl for negative answers using RFC 2308 idea. (f72e8f6 Leonid Evdokimov) + o Add DNS_ERR_NODATA error code to handle empty replies. (94fba5b Leonid Evdokimov) + +BUFGIXES (bufferevents and evbuffers): + o Make evbuffer callbacks get the right n_added value after evbuffer_add (1ef1f68 Alex) + o Prefer mmap to sendfile unless a DRAINS_TO_FD flag is set. Allows add_file to work with SSL. (0ba0af9) + +BUGFIXES (event loop): + o When a signal callback is activated to run multiple times, allow event_base_loopbreak to work even before they all have run. (4e8eb6a) + +DOCUMENTATION FIXES: + o Fix docstring in dns.h (2b6eae5 Leonid Evdokimov) + o refer to non-deprecated evdns functions in comments (ba5c27d Greg Hazel) + +BUILD AND TESTING FIXES: + o le-proxy and regress depend on openssl directly (9ae061a Sergey Avseyev) + o Use _SOURCES, not _sources, in sample/Makefile.am (7f82382) + o Fixed compiler warnings for unchecked read/write calls. (c3b62fd Mark Ellzey) + o Make write-checking fixes use tt_fail_perror (2b76847) + o Fix some "value never used" warnings with gcc 4.6.1 (39c0cf7) + + + +Changes in version 2.0.14-stable (31 Aug 2011) +BUGFIXES (bufferevents and evbuffers): + o Propagate errors on the underlying bufferevent to the user. (4a34394 Joachim Bauch) + o Ignore OpenSSL deprecation warnings on OS X (5d1b255 Sebastian Hahn) + o Fix handling of group rate limits under 64 bytes of burst (6d5440e) + o Solaris sendfile: correctly detect amount of data sent (643922e Michael Herf) + o Make rate limiting work with common_timeout logic (5b18f13) + o clear read watermark on underlying bufferevent when creating filtering bev to fix potentially failing fragmented ssl handshakes (54f7e61 Joachim Bauch) + +BUGFIXES (IOCP): + o IOCP: don't launch reads or writes on an unconnected socket (495c227) + o Make IOCP rate-limiting group support stricter and less surprising. (a98da7b) + o Have test-ratelim.c support IOCP (0ff2c5a) + o Make overlapped reads result in evbuffer callbacks getting invoked (6acfbdd) + o Correctly terminate IO on an async bufferevent on bufferevent_free (e6af35d) + +BUGFIXES (other): + o Fix evsig_dealloc memory leak with debugging turned on. (9b724b2 Leonid Evdokimov) + o Fix request_finished memory leak with debugging turned on. (aff6ba1 Leonid Evdokimov) + +BUILD AND TESTING FIXES: + o Allow OS-neutral builds for platforms where some versions have arc4random_buf (b442302 Mitchell Livingston) + o Try to fix 'make distcheck' errors when building out-of-tree (04656ea Dave Hart) + o Clean up some problems identified by Coverity. (7c11e51 Harlan Stenn) + + +Changes in version 2.0.13-stable (18 Jul 2011) +BUGFIXES + o Avoid race-condition when initializing global locks (b683cae) + o Fix bug in SSL bufferevents backed by a bev with a write high-watermarks (e050703 Joachim Bauch) + o Speed up invoke_callbacks on evbuffers when there are no callbacks (f87f568 Mark Ellzey) + o Avoid a segfault when all methods are disabled or broken (27ce38b) + o Fix incorrect results from evbuffer_search_eol(EOL_LF) (4461f1a) + o Add some missing checks for mm_calloc failures (89d5e09) + o Replace an assertion for event_base_free(NULL) with a check-and-warn (09fe97d) + o Report kqueue ebadf, epipe, and eperm as EV_READ events (1fd34ab) + o Check if the `evhttp_new_object' function in `http.c' returns NULL. (446cc7a Mansour Moufid) + o Use the correct printf args when formatting size_t (3203f88) + o Complain if the caller tries to change threading cbs after setting them (cb6ecee) + +DOCUMENTATION FIXES AND IMPROVEMENTS + o Revise the event/evbuffer/bufferevent doxygen for clarity and accuracy (2888fac) + o Update Doxyfile to produce more useful output (aea0555) + +TEST FIXES + o Fix up test_evutil_snprintf (caf695a) + o Fix tinytest invocation from windows shell (57def34 Ed Day) + +BUILD FIXES + o Use AM_CPPFLAGS in sample/Makefile.am, not AM_CFLAGS (4a5c82d) + o Fix select.c compilation on systems with no NFDBITS (49d1136) + o Fix a few warnings on OpenBSD (8ee9f9c Nicholas Marriott) + o Don't break when building tests from git without python installed (b031adf) + o Don't install event_rpcgen.py when --disable-libevent-install is used (e23cda3 Harlan Stenn) + o Fix AIX build issue with TAILQ_FOREACH definition (e934096) + + +Changes in version 2.0.12-stable (4 Jun 2011) +BUGFIXES + o Fix a warn-and-fail bug in kqueue by providing kevent() room to report errors (28317a0) + o Fix an assert-inducing fencepost bug in the select backend (d90149d) + o Fix failing http assertion introducd in commit 0d6622e (0848814 Kevin Ko) + o Fix a bug that prevented us from configuring IPv6 nameservers. (74760f1) + o Prevent size_t overflow in evhttp_htmlescape. (06c51cd Mansour Moufid) + o Added several checks for under/overflow conditions in evhttp_handle_chunked_read (a279272 Mark Ellzey) + o Added overflow checks in evhttp_read_body and evhttp_get_body (84560fc Mark Ellzey) + +DOCUMENTATION: + o Add missing words to EVLOOP_NONBLOCK documentation (9556a7d) + +BUILD FIXES + o libssl depends on libcrypto, not the other way around. (274dd03 Peter Rosin) + o Libtool brings in the dependencies of libevent_openssl.la automatically (7b819f2 Peter Rosin) + o Use OPENSSL_LIBS in Makefile.am (292092e Sebastian Hahn) + o Move the win32 detection in configure.in (ceb03b9 Sebastian Hahn) + o Correctly detect openssl on windows (6619385 Sebastian Hahn) + o Fix a compile warning with zlib 1.2.4 and 1.2.5 (5786b91 Sebastian Hahn) + o Fix compilation with GCC 2, which had no __builtin_expect (09d39a1 Dave Hart) + o Fix new warnings from GCC 4.6 (06a714f) + o Link with -lshell32 and -ladvapi32 on Win32. (86090ee Peter Rosin) + o Make the tests build when OpenSSL is not available. (07c41be Peter Rosin) + o Bring in the compile script from automake, if needed. (f3c7a4c Peter Rosin) + o MSVC does not provide S_ISDIR, so provide it manually. (70be7d1 Peter Rosin) + o unistd.h and sys/time.h might not exist. (fe93022 Peter Rosin) + o Make sure TINYTEST_LOCAL is defined when building tinytest.c (8fa030c Peter Rosin) + o Fix winsock2.h #include issues with MSVC (3d768dc Peter Rosin) + o Use evutil_gettimeofday instead of relying on the system gettimeofday. (0de87fe Peter Rosin) + o Always use evutil_snprintf, even if OS provides it (d1b2d11 Sebastian Hahn) + o InitializeCriticalSectionAndSpinCount requires _WIN32_WINNT >= 0x0403. (816115a Peter Rosin) + o cygwin: make it possible to build DLLs (d54d3fc) + + + +Changes in version 2.0.11-stable (27 Apr 2011) + [Autogenerated from the Git log, sorted and cleaned by hand.] +BUGFIXES: + o Fix evport handling of POLLHUP and POLLERR (b42ce4b) + o Fix compilation on Windows with NDEBUG (cb8059d) + o Check for POLLERR, POLLHUP and POLLNVAL for Solaris event ports (0144886 Trond Norbye) + o Detect and handle more allocation failures. (666b096 Jardel Weyrich) + o Use event_err() only if the failure is truly unrecoverable. (3f8d22a Jardel Weyrich) + o Handle resize failures in the select backend better. (83e805a) + o Correctly free selectop fields when select_resize fails in select_init (0c0ec0b) + o Make --enable-gcc-warnings a no-op if not using gcc (3267703) + o Fix a type error in our (unused) arc4random_stir() (f736198) + o Correctly detect and stop non-chunked http requests when the body is too long (63a715e) + o Have event_base_gettimeofday_cached() always return wall-clock time (a459ef7) + o Workaround for http crash bug 3078187 (5dc5662 Tomash Brechko) + o Fix incorrect assertions and possible use-after-free in evrpc_free() (4b8f02f Christophe Fillot) + o Reset outgoing http connection when read data in idle state. (272823f Tomash Brechko) + o Fix subtle recursion in evhttp_connection_cb_cleanup(). (218cf19 Tomash Brechko) + o Fix the case when failed evhttp_make_request() leaved request in the queue. (0d6622e Tomash Brechko) + o Fix a crash bug in evdns server circular list code (00e91b3) + o Handle calloc failure in evdns. (Found by Dave Hart) (364291e) + o Fix a memory leak on win32 socket->event map. (b4f89f0) + o Add a forgotten NULL check to evhttp_parse_headers (12311ff Sebastian Hahn) + o Fix possible NULL-deref in evdns_cancel_request (5208544 Sebastian Hahn) + +PORTABILITY: + o Fall back to sscanf if we have no other way to implement strtoll (453317b) + o Build correctly on platforms without sockaddr_storage (9184563) + o Try to build correctly on platforms with no IPv6 support (713c254) + o Build on systems without AI_PASSIVE (cb92113) + o Fix http unit test on non-windows platforms without getaddrinfo (6092f12) + o Do not check for gethostbyname_r versions if we have getaddrinfo (c1260b0) + o Include arpa/inet.h as needed on HPUX (10c834c Harlan Stenn) + o Include util-internal.h as needed to build on platforms with no sockaddr_storage (bbf5515 Harlan Stenn) + o Check for getservbyname even if not on win32. (af08a94 Harlan Stenn) + o Add -D_OSF_SOURCE to fix hpux builds (0b33479 Harlan Stenn) + o Check for allocation failures in apply_socktype_protocol_hack (637d17a) + o Fix the check for multicast or broadcast addresses in evutil_check_interfaces (1a21d7b) + o Avoid a free(NULL) if out-of-memory in evdns_getaddrinfo. Found by Dave Hart (3417f68) + +DEFENSIVE PROGRAMMING: + o Add compile-time check for AF_UNSPEC==PF_UNSPEC (3c8f4e7) + +BUGS IN TESTS: + o Fix test.sh output on solaris (b4f89b6 Dave Hart) + o Make test-eof fail with a timeout if we never get an eof. (05a2c22 Harlan Stenn) + o Use %s with printf in test.sh (039b9bd) + o Add an assert to appease clang's static analyzer (b0ff7eb Sebastian Hahn) + o Add a forgotten return value check in the unit tests (3819b62 Sebastian Hahn) + o Actually send NULL request in http_bad_request_test (b693c32 Sebastian Hahn) + o add some (void) casts for unused variables (65707d7 Sebastian Hahn) + o Refactor test_getaddrinfo_async_cancel_stress() (48c44a6 Sebastian Hahn) + o Be nice and "handle" error return values in sample code (4bac793 Sebastian Hahn) + o Check return value of evbuffer_add_cb in tests (93a1abb Sebastian Hahn) + o Remote some dead code from dns-example.c (744c745 Sebastian Hahn) + o Zero a struct sockaddr_in before using it (646f9fe Sebastian Hahn) + +BUILD FIXES: + o Fix warnings about AC_LANG_PROGRAM usage (f663112 Sebastian Hahn) + o Skip check for zlib if we have no zlib.h (a317c06 Harlan Stenn) + o Fix autoconf bracket issues; make check for getaddrinfo include netdb.h (833e5e9 Harlan Stenn) + o Correct an AM_CFLAGS to an AM_CPPFLAGS in test/Makefile.am (9c469db Dave Hart) + o Fix make distcheck & installation of libevent 1 headers (b5a1f9f Dave Hart) + o Fix compilation under LLVM/clang with --enable-gcc-warnings (ad9ff58 Sebastian Hahn) + +FEATURES: + o Make URI parser able to tolerate nonconformant URIs. (95060b5) + +DOCUMENTATION: + o Clarify event_set_mem_functions doc (926f816) + o Correct evhttp_del_accept_socket documentation on whether socket is closed (f665924) + o fix spelling mistake in whatsnew-2.0.txt (deb2f73) + o Fix sample/http-server ipv6 fixes (eb692be) + o Comment internal headers used in sample code. (4eb281c) + o Be explicit about how long event loops run in event.h documentation (f95bafb) + o Add comment to configure.in to explain gc-sections test logic (c621359) + o Fix a couple of memory leaks in samples/http-server.c. Found by Dave Hart. (2e9f665) + +BUILD IMPROVEMENTS: + o Use the gcc -ffunction-segments feature to allow gc when linking with static libevent (0965c56 Dave Hart) + o Add configure options to disable installation, regression tests (49e9bb7 Dave Hart) + + + +Changes in version 2.0.10-stable (16 Dec 2010) + [Autogenerated from the Git log, sorted and cleaned by hand.] +BUGFIXES + o Minor fix for IOCP shutdown handling fix (2599b2d Kelly Brock) + o Correctly notify the main thread when activating an event from a subthread (5beeec9) + o Reject overlong http requests early when Expect:100-continue is set (d23839f Constantine Verutin) + o EVUTIL_ASSERT: Use sizeof() to avoid "unused variable" warnings with -DNDEBUG. (b63ab17 Evan Jones) + +CODE CLEANUPS + o bufferevent-internal.h: Use the new event2/util.h header, not evutil.h (ef5e65a Evan Jones) + o Use relative includes instead of system includes consistently. (fbe64f2 Evan Jones) + o Make whitespace more consistent + +TESTING + o tests: Use new event2 headers instead of old compatibility headers. (4f33209 Evan Jones) + +DOCUMENTATION + o Document that the cpu_hint is only used on Windows with IOCP for now (57689c4) + o Add stuff to "whats new in 2.0" based on reading include changes since August. (18adc3f) + + +Changes in 2.0.9-rc (30 Nov 2010): + [Autogenerated from the Git log, sorted and cleaned by hand.] +NEW AND MODIFIED APIs + o Add a function to change a listener's callback. (46ee061) + o Make evbuffer_add_file take ev_off_t, not off_t (ac7e52d) + o Make rate-limits go up to SIZE_MAX/EV_SSIZE_MAX, not just INT32_MAX (2cbb1a1) + o Add a bufferevent_get_base function (aab49b6) + +MAJOR BUGFIXES + o Disable changelist for epoll by default because of Linux dup() bug; add an option and/or an envvar to reenable it for speed. (9531763) + o Fix a 100%-CPU bug where an SSL connection would sometimes never stop trying to write (1213d3d) + o Fix a nasty bug related to use of dup() with epoll on Linux (c281aba) + o Fix bugs in posix thread-id calculation when sizeof(pthread_t) != sizeof(long) (fbaf077) + o Fix some ints to evutil_socket_t; make tests pass on win64. (f817bfa Dimitre Piskyulev) + o Set _EVENT_SIZEOF_VOID_P correctly on win32 and win64 (1ae82cd Dimitre Piskyulev) + o Avoid double-invocation of user callback with EVUTIL_EAI_CANCEL (abf01ed) + o Set SO_UPDATE_ACCEPT_CONTEXT on sockets from AcceptEx so that shutdown() can work (52aa419) + o When closing a filtering bufferevent, clear callbacks on the underlying bufferevent (fc7b1b0) + +NEW AND MODIFIED HTTP APIs + o Add evhttp_parse_query_str to be used with evhttp_uri_parse. (2075fbc) + o Add evhttp_response_code to remove one more reason to include http_struct.h (22e0a9b) + o Define enumerators for all HTTP methods, including PATCH from RFC5789 (75a7341 Felix Nawothnig) + o Functions to actually use evhttp_bound_socket with/as evconnlistener. (006efa7) + o Add evhttp_request_get_command so code can tell GET from POST without peeking at the struct. (49f4bf7) + o Introduce absolute URI parsing helpers. (86dd720 Pavel Plesov) + o Revise evhttp_uri_parse implementation to handle more of RFC3986 (eaa5f1d) + o Add evhttp_connection_get_base() to get the event_base from an http connection (cd00079) + o Let evhttp_parse_query return -1 on failure (b1756d0) + o New evhttp_uri(encode|decode) functions to handle + and NUL characters right (a8148ce) + o Add evhttp_response_code to remove one more reason to include http_struct.h (22e0a9b) + o Tweak interface for allowed methods (f5b391e) + o Add evhttp server alias interface, correct flagging of proxy requests. (aab8c38 Christopher Davis) + +HTTP BUGFIXES + o Add some comments to http.c and make a few functions static. (90b3ed5) + o Fix Content-Length when trying send more than 100GB of data (!) on an evhttp. (525da3e) + o Fix a bug where we would read too much data in HTTP bodies or requests. (58a1cc6) + o Correctly count req->body_size on http usage without Content-Length (8e342e5) + o Avoid missed-request bug when entire http request arrives before data is flushed (74c0e86) + o reset "chunked" flag when sending non-chunked reply (aa5f55f Joachim Bauch) + o evhttp_encode_uri encodes all reserved characters, including !$'()*+,/:=@ (2e63a60) + o Replace exact-version checks for HTTP/1.1 with >= or < checks (647e094) + o evhttp: Return 501 when we get an unrecognized method, not 400. (536311a) + o Don't disable reading from the HTTP connection after sending the request to be notified of connection-close in time (c76640b Felix Nawothnig) + o Never call evhttp_readcb while writing. (0512487) + o Try to fix an assertion failure related to close detection (0faaa39) + o Correctly detect timeouts during http connects (04861d5) + o Preliminary support for Continue expectation in evhttp. (fa9305f Christopher Davis) + +OTHER BUGFIXES + o Correct logic for realigning a chain in evbuffer_add (e4f34e8) + o Fix a minor syntax error that most compilers didn't care about (e56ff65) + o Fix some uses of int for socket in regress (5d389dc) + o Check return value for ioctlsocket on win32 (f5ad31c Trond Norbye) + o Fix som event_warns that should have been event_warnx (19c71e7) + o Fix signal handler types for win64. (b81217f) + o Try to clear up more size_t vs int/long issues. (598d133) + o Make sure IOCP evconnlistener uses virtual events. (7b40a00 Christopher Davis) + o Don't free evdns_request handles until after the callback is invoked (9ed30de) + o Fix some more cancel-related bugs in getaddrinfo_async (c7cfbcf) + o Make evdns_getaddrinfo_cancel threadsafe (d51b2fc) + o Only clear underlying callbacks when the user hasn't reset them. (1ac5b23) + o Fix bug in bufferevent_connect on an openssl bufferevent that already had an fd (4f228a1) + o Resolve an evport bug in the thread/forking test (3a67d0b) + o Make sure the CLOEXEC flag is set on fds we open for base notification (3ab578f) + o Fix IRIX build. sa_family collides with a #define in sys/socket.h on IRIX. (e874982 Kevin Bowling) + o If not WIN32, include in event2/util.h. (1cd45e5 Kevin Bowling) + o Fix some C99-style comments to work with the xlC compiler. (c2e5e22 Kevin Bowling) + o Add some checks since lack of TAILQ_FOREACH doesn't imply lack of FIRST, END, NEXT, or INSERT_BEFORE. Quiet some warnings in XL C. (c4dc335 Kevin Bowling) + o Reworked AIX __ss_family workaround to use AC_STRUCT_MEMBER. (2e2a3d7 Kevin Bowling) + o Take select from when testing in autoconf. AIX build fix. (a3a9f6b Kevin Bowling) + o Fix snprintf related failures on IRIX. (3239073 Kevin Bowling) + o Remove _event_initialized(); make event_initialized() a function(); make it consistent on windows and non-windows (652024b) + o Do not let EVLOOP_ONCE exit the loop until all deferred callbacks have run (2d5e1bd) + o Make EVLOOP_ONCE ignore internal events (0617a81) + o Possible crash fix when freeing an underlying bufferevent of an openssl bufferevent (29f7623) + +HTTP CLEANUPS + o Stop using Libevent-1 headers in regress_http (1f507d7) + o Modernize header usage in bench_http.c (e587069) + o fix signed/unsigned warnings in http.c (74a91e5) + o Update the HTTP regression tests to use Libevent2 apis for non-http stuff (d9ffa89) + o Start porting http tests to not use legacy interfaces (8505a74) + o Convert the rest of the http tests to be non-legacy unit tests. (9bb8239) + o Rename the confusing "base" static variable in regress_http.c (353402a) + o Stop accessing http request struct directly from in the unit tests. (0b137f4) + o Refactor http version parsing into a single function (a38140b) + +TESTING + o Improvements to tinytest_macros.h (ad923a1) + o Add a huge pile of tests for the new URI functions, and make them pass. (a5a76e6) + o Unit tests for evhttp_uri_set* (bc98f5e) + o Increase the skew tolerance to 2 seconds in thread/deferred_cb_skew (f806476 Christopher Davis) + o Reorder backends in test.sh to match preference order in event.c (ece974f) + o Add a stress test for getaddrinfo_cancel (da1bf52) + o Units test for unexpected evhttp methods. (75e3320) + +DOCUMENTATION + o Document behavior of URI parsing more thoroughly. (3a33462) + o Document that two bufferevent functions only work on socket bufferevents (70e1b60) + o add a requested docstring for event_rpcgen.CommandLine.__init__ (f1250eb) + o Fix a mistake in http documentation found by Julien Blache (229714d) + o Add a basic example of how to write a static HTTP server. (4e794d5) + o Document event_get_assignment (88be27d) + o Note that reentrant calls to libevent from logging cbs may fail badly (e431bcd) + o Clarify EVLOOP_* documentation to be more precise. (057a514) + +CLEANUPS + o Simplify the logic for choosing EPOLL_CTL_ADD vs EPOLL_CTL_MOD (2c66983) + o Rename "size" variables in win32select that were really fd counts. (b6a158c) + o Fix even more win64 warnings (7484df6) + o Fix even more win64 warnings: buffer, event_tagging, http, evdns, evrpc (545a611) + o Fix more wn64 warnings. (34b84b9 Christopher Davis) + o Use the label_len local variable in evdns instead of recalculating it over and over (ba01456) + o Fix some irix compilation warnings spotted by Kevin Bowling (7bcace2) + + + +Changes in 2.0.8-rc (14 Oct 2010): + [Autogenerated from the Git log, sorted and cleaned by hand.] +NEW APIS + o Add error callback to evconnlistener (c4be8d8 Simon Perreault) + o Add a LEV_OPT_THREADSAFE option for threadsafe evconnlisteners (127d4f2) + +CHANGED BEHAVIOR + o Correct logic on disabling underlying bufferevents when disabling a filter (ac27eb8) + +BUGFIXES + o Obey enabled status when unsuspending (040a019 Simon Perreault) + o Warn when using the error-prone EV_SIGNAL interface in an error-prone way. Also, fix a couple of race conditions in signal.c (720bd93) + O Make default signal backend fully threadsafe (95a7d41) + o Put internal events at highest priority (90651b3) + o Fix warnings in the main codebase flagged by -Wsigned-compare (9c8db0, 5e4bafb, 5c214a, 6be589a, e06f514) + o Fix compile in kqueue.c (b395392 Sebastian Hahn) + o Do not search outside of the system directory for windows DLLs (d49b5e3) + o Fix a spurious-call bug on epoll.c (0faaee0) + o Send a shutdown(SHUT_WR) before closing an http connection (e0fd870 Christopher Davis) + o Fix warnings on mingw with gcc 4.5 (5b7a370) + o Fix an EINVAL on evbuffer_write_iovec on OpenSolaris. (fdc640b) + o Fix allocation error for IOCP listeners. Probably harmless, since struct event is big (481ef92) + o Make iocp/listener/error work; don't accept again if lev is disabled. (62b429a Christopher Davis) + o Handle rate-limiting for reading on OpenSSL bufferevents correctly. (819b171) + o Fix serious bugs in per-bufferevent rate-limiting code (34d64f8) + o Avoid spurious reads from just-created open openssl bufferevents (223ee40) + o Fix a case where an ssl bufferevent with CLOSE_ON_FREE didn't close its fd (93bb7d8) + o The corrected bufferevent filter semantics let us fix our openssl tests (34331e4) + +TESTING + o Make SSL tests cover enabling/disabling EV_READ. (a5ce9ad) + o Bump to the latest version of tinytest (f0bd83e) + o Unit tests for listener error callbacks (045eef4) + o New unit test for ssl bufferevents starting with connected SSLs. (02f6259) + +DEBUGGABILITY + o Make debugging output for epoll backend more comprehensive (ec2b05e) + o Make event.c debugging messages report fds (e119899) + o Make the --enable-gcc-warnings option include signed comparison warnings (d3b096c) + +DEADCODE REMOVAL + o Remove the now-useless evsig_caught and evsig_process (4858b79) + o Remove event_base.evsigbase; nothing used it. (38d0960) + + + +Changes in 2.0.7-rc (9 Sep 2010): + [Autogenerated from the Git log, sorted and cleaned by hand.] +NEW APIS + o Expose a evdns_base_nameserver_sockaddr_add() function to add a nameserver by sockaddr (1952143) + o Add event_config_set_num_cpus_hint() for tuning win32 IOCP thread pools, etc. (2447fe8 Christopher Davis) + +BUGFIXES + o Fix a nasty dangling-event bug when using rate-limiting groups (0bffe43) + o Clean up syntax on TAILQ_ENTRY() usage to build correctly with recent MSVC (60433a0 Gilad Benjamini) + o Make definition of WIN32_LEAN_AND_MEAN in event.h conditional (3920172 Gilad Benjamini) + o Correctly detect failure to delete bufferevent read-timeout event (da6e7cd) + o Set close-on-exec bit for filedescriptors created by dns subsystem (d0b8843) + o Fix kqueue correctness test on x84_64 (6123d12) + o Detect events with no ev_base; warn instead of crashing (f1074b7) + o Fix an issue with forking and signal socketpairs in select/poll backends (d61b2f3) + o Stop using global arrays to implement the EVUTIL_ctype functions (1fdec20) + o On windows, make lock/thread function tables static (5de2bcb) + o Close th_notify_fds and open a new pair on reinit (495ed66) + o Declare signal handler function as "__cdecl" on Windows (f0056d0) + o Use the _func() replacements for open, fstat, etc in evutil.c on win32 (e50c0fc) + o Only process up to MAX_DEFERRED deferred_cbs at a time (17a14f1 Christopher Davis) + +THREADING BUGFIXES + o Avoid deadlock when activating signals (970e6ad) + o Add a condition variable backend, with implementations for pthreads and win32 (d4977b5) + o Use conditions instead of current_event_lock to fix a deadlock (e0972c2) + o Fix logic error in win32 TRY_LOCK that caused problems with rate-limiting (4c32b9d) + o Avoid needlessly calling evthread_notify_base() when the loop is not running (c7a06bf) + o Minimize calls to base_notify implementation functions, thereby avoiding needless syscalls (4632b78) + +IOCP BUGFIXES + o IOCP-related evbuffer fixes (03afa20 Christopher Davis) + o Stop IOCP when freeing the event_base (d844242 Christopher Davis) + o Some IOCP bufferevent tweaks (76f7e7a Christopher Davis) + +TESTS + o Make the regress_pthread.c tests work on windows with current test APIs (d74ae38) + o Add a unit test for conditions (5fb1095) + o Allow more than one copy of regression tests to run at once (a97320a) + o Fix event_del(0) instance in bench.c (b0f284c Shuo Chen) + o Fix a few memory leaks in the tests (1115366) + o IOCP-related unit test tweaks (499452f Christopher Davis) + o Improve testing of when thread-notification occurs (ce85280) + +BUILD AND DISTRIBUTION + o Add pkgconfig files for libevent_{openssl,pthreads} (ebcb1f0) + o Change include order in Makefile.nmake (4022b28) + o Make include/event2/event-config.h not included in source dist (a4af9be) + o Honor NDEBUG; build without warnings with NDEBUG; make NDEBUG always-off in unit test code (743f866) + o Declare evkeyvalq and event_list even if event_struct.h comes before sys/queue.h (d3ceca8) + o Move evkeyvalq into a separate header for evhttp_parse_query users (ca9048f) + o Prefer autoreconf -ivf to manual autogen.sh (7ea8e89) + +CLEANUP + o Completely remove the (mostly-removed) obsolete thread functions (3808168) + o Rename regress_pthread.c to regress_thread.c (041989f) + o Make defer-internal.h use lock macros, not direct calls to lock fns (5218d2a) + +DOCUMENTATION + o Document that DNS_NO_SEARCH is an obsolete alias for DNS_QUERY_NO_SEARCH (33200e7) + o Update the whatsnew-2.0.txt document (4991669) + + + +Changes in 2.0.6-rc (6 Aug 2010): + [Autogenerated from the Git log, sorted by hand.] +DOCUMENTATION + o Document a change in the semantics of event_get_struct_event_size() (e21f5d1) + o Add a comment to describe our plan for library versioning (9659ece) + o Fix sentence fragment in docs for event_get_struct_event_size() (7b259b6) + +NEW FEATURES AND INTERFACE CHANGES + o Remove the obsolete evthread interfaces (c5bab56) + o Let evhttp_send_error infer the right error reasons (3990669) + o Add a function to retrieve the other side of a bufferevent pair (17a8e2d) + o Add bufferevent_lock()/bufferevent_unlock() (215e629) + o Stop asserting when asked for a (unsupported) TCP dns port. Just return NULL. (7e87a59) + o Replace (unused,always 0) is_tcp argument to evdns_add_server_port*() with flags (e1c1167) + o Constify a couple of arguments to evdns_server_request_add_*_reply (cc2379d) + o Add an interface to expose min_share in ratelimiting groups (6ae53d6) + +BUGFIXES + o Avoid event_del on uninitialized event in event_base_free (6d19510) + o Add some missing includes to fix Linux build again (75701e8) + o Avoid close of uninitialized socket in evbuffer unit test (bda21e7) + o Correctly recognize .255 addresses as link-local when looking for interfaces (8c3452b) + o If no evdns request can be launched, return NULL, not a handle (b14f151) + o Use generic win32 interfaces, not ASCII-only ones, where possible. (899b0a3) + o Fix the default HTTP error template (06bd056 Felix Nawothnig) + o Close the file in evutil_read_file whether there's an error or not. (0798dd1 Pierre Phaneuf) + o Fix possible nullptr dereference in evhttp_send_reply_end() (29b2e23 Felix Nawothnig) + o never let bufferevent_rlim functions return negative (0859870) + o Make sample/hello_world work on windows (d89fdba) + o Fix a deadlock related to event-base notification. Diagnosed by Zhou Li, Avi Bab, and Scott Lamb. (17522d2) + o Possible fix to 100% cpu usage with epoll and openssl (cf249e7 Mike Smellie) + o Don't race when calling event_active/event_add on a running signal event (fc5e0a2) + o Suppress a spurious EPERM warning in epoll.c (e73cbde) + o Fix wrong size calculation of iovec buffers when exact=1 (65abdc2 niks) + o Change bufferevent_openssl::do_write so it doesn't call SSL_write with a 0 length buffer (c991317 Mike Smellie) + o Fixed compilation of sample/le-proxy.c on win32 (13b912e Trond Norbye) + o Fix rate-limit calculation on openssl bufferevents. (009f300) + o Remember to initialize timeout events for bufferevent_async (de1f5d6 Christopher Davis) + +BUILD AND DISTRIBUTION CHANGES + o Test the unlocked-deferred callback case of bufferevents (dfb75ab) + o Remove the now-unusable EVTHREAD_LOCK/UNLOCK constants (fdfc3fc) + o Use -Wlogical-op on gcc 4.5 or higher (d14bb92) + o Add the libtool-generated /m4/* stuff to .gitignore (c21c663) + o Remove some automake-generated files from version control. (9b14911) + o Have autogen.sh pass --force-missing to automake (8a44062) + o Set library version for libevent_pthreads correctly (b2d7440) + o Really only add libevent_core.la to LIBADD on mingw (1425003 Sebastian Hahn) + o Build more cleanly with NetBSDs that dislike toupper(char) (42a8c71) + o Fix unit tests with -DUSE_DEBUG enabled (28f31a4) + o Fix evdns build with -DUNICODE (5fa30d2) + o Move event-config.h to include/event2 (ec347b9) + +TESTING + o Add options to test-ratelim.c to check its results (2b44dcc) + o Make test-ratelim clean up after itself better. (b5bfc44) + o Remove the now-obsolete setup_test() and cleanup_test() functions (e73f1d7) + o Remove all non-error prints from test/regress.c (8bc1e3d) + o Make test.sh exit with nonzero status if tests fail (faf2a04) + o Have the unit tests report errors from test.sh (3689bd2) + o Fix logic in correcting high values from FIONREAD (3467f2f) + o Add test for behavior on remote socket close (44d57ee) + o Unit test for event_get_struct_event_size() (7510aac) + o Make test/test.sh call test-changelist (7c92691) + o Fix badly-behaved subtest of dns/bufferevent_connect_hostname (840a72f Joachim Bauch) + o Add option to test-ratelim to test min_share (42f6b62) + o Fix an assertion bug in test-ratelim (b2c6202) + o Make tests quieter on local dns resolver failure (e996b3d) + o Increase the tolerance in our unit tests for sloppy clocks. (170ffd2) + o Use AF_INET socketpair to test sendfile on Solaris (9b60209) + o Make test-changelist count cpu usage right on win32 (ea1ea3d) + +INTERNALS, PERFORMANCE, AND CODE CLEANUPS + o Mark the event_err() functions as __attribute__((noreturn)) (33bbbed) + o Do not check that event_base is set in EVBASE_ACQUIRE_LOCK (218a3c3) + o Replace (safe) use of strcpy with memcpy to appease OpenBSD (caca2f4) + o Remove some dead assignments (47c5dfb) + o Fix a pedantic gcc 4.4 warning in event2/event.h (276e7ee) + o Drain th_notify_fd[0] more bytes at a time. (a5bc15b) + o Tidy up the code in evthread_make_base_notifiable a little (61e1eee) + o Pass flags to fcntl(F_SETFL) and fcntl(F_SETFD) as int, not long (7c2dea1) + o Remove unused variables in test/test-changelist.c (b00d4c0) + o Fix whitespace. (cb927a5) + o Improve error message for failed epoll to make debugging easier. (9e725f7) + o Turn our socketpair() replacement into its own function (57b30cd) + + + +Changes in 2.0.5-beta (10 May 2010): + [Autogenerated from the Git log, sorted by hand.] +DOCUMENTATION + o Update all our copyright notices to say "2010" (17efc1c) + o Add Christopher Clark and Maxim Yegorushkin to the LICENSE file (38b7b57) + o Clarify Christopher Clark's status as writer of original ht code. (78772c3) + o Try to comment some of the event code more (cdd4c49) + o Add a few more evmap/changelist comments (c247adc) + o Add a comment to explain why evdns_request is now separte from request (ceefbe8) + o Document evutil_secure_rng_init() and evutil_secure_rng_add_bytes() (a5bf43a) + o Stop distributing and installing manpages: they were too inaccurate (7731ec8) + +NEW FEATURES AND INTERFACE CHANGES + o Remove signal_assign() and signal_new() macros. (2fac0f7) + o Make evdns use the regular logging system by default (b2f2be6) + o Allow evbuffer_read() to split across more than 2 iovecs (e470ad3) + o Functions to manipulate existing rate limiting groups. (ee41aca) + o Functions to track the total bytes sent over a rate limit group. (fb366c1) + o Detect and refuse reentrant event_base_loop() calls (b557b17) + o Limit the maximum number of events on each socket to 65535 (819f949) + o Add evbuffer_copyout to copy data from an evbuffer without draining (eb86c8c) + o Expose the request and reply members of rpc_req_generic() (07edf78 Shuo Chen) + o Add void* arguments to request_new and reply_new evrpc hooks (755fbf1 Shuo Chen) + o Seed the RNG using sysctl() as well as /dev/urandom (71fc3eb) + o Make evutil_secure_rng_init() work even with builtin arc4random (f980716) + o Report DNS error when lookup fails during bufferevent_socket_connect_hostname. (0ef4070 Christopher Davis) + o Release locks on bufferevents while executing callbacks (a5208fe Joachim Bauch) o Make debug mode catch mixed ET and non-ET events on an fd (cb67074) + o Catch attempts to enable debug_mode too late (9ecf0d4) + o Refuse null keys in evhttp_parse_query() (953e229 Frank Denis) + +BUGFIXES + o Avoid a spurious close(-1) on Linux (70a44b6) + o Do not close(-1) when freeing an uninitialized socket bufferevent (b34abf3) + o Free evdns_base->req_heads on evdns_base_free (859af67) + o Avoid an (untriggerable so far) crash bug in bufferevent_free() (0cf1431) + o Set mem_offset for every bufferevent type (657d1b6) + o Fix infrequent memory leak in bufferevent_init_common(). (8398641 Jardel Weyrich) + o Make evutil_signal_active() match declaration. (e1e703d Patrick Galbraith) + o Fix minheap code to use replacement malloc functions (a527618) + o Fix a free(NULL) in minheap-internal.h (6f20492) + o Fix critical bug in evbuffer_write when writev is not available (cda56ab) + o Make the no_iovecs case of write_atmost compile (8e227b0) + o Fix a memory leak when appending/prepending to a buffer with unused space. (45068a3) + o Clean up a mistake in pointer manipulation in evbuffer_remove (28bfed4 Christopher Davis) + o Always round up when there's a fractional number of msecs. (8f9e60c Christopher Davis) + o Fix compiler warnings under WIN32 (d469c50 Giuseppe Scrivano) + o Clean up properly when adding a signal handler fails. (b84b598 Gilad Benjamini) o Ensure that evdns_request is a persistent handle. (15bb82d Christopher Davis) + o Free search state when finished searching to avoid an infinite loop. (a625840 Christopher Davis) + o Assert for valid requests as necessary. (67072f3 Christopher Davis) + o do not leak the request object on persistent connections (9d8edf2) + o Make evdns logging threadsafe (b1c7950) + o Fix a couple of bugs in the BSD sysctl arc4seed logic (a47a4b7) + o Remove one last bug in last_with_datap logic. Found with valgrind (d49b92a) + o fix a leak when unpausing evrpc requests (94ee125) + o Fix a memory leak when unmarshalling RPC object arrays (f6ab2a2) + o Fix compilation when openssl support is disabled (40c301b) + o Allow empty reason line in HTTP status (739e688 Pierre Phaneuf) + o Fix a compile warning introduced in 739e688 (bd1ed5f Sebastian Hahn) + o Fix nonstandard TAILQ_FOREACH_REVERSE() definition (71afc52 Frank Denis) + o Try /proc on Linux as entropy fallback; use sysctl as last resort (20fda29) + o Fix symbol conflict between mm_*() macros and libmm (99e50e9) + o Fix some crazy macro mistakes in arc4random.c (90d4225) + o Make evbuffer_add_file() work on windows (dcdae6b) + o Fix unused-variable warning when building with threads disabled (ad811cd) + o Numerous opensolaris compilation fixes (c44de06) + o Fix getaddrinfo with protocol unset on Solaris 9. Found by Dagobert Michelsen (2cf2a28) + o Fix another nasty solaris getaddrinfo() behavior (3557071) + o Define _REENTRANT as needed on Solaris, elsewhere (c1cd32a) + o Fix some autoconf issues on OpenBSD (7c519df) + +BUILD AND DISTRIBUTION CHANGES + o Distribute libevent.pc.in, not libevent.pc (22aff04) + o Avoid errors in evutil.c when building with _UNICODE defined (b677032 Brodie Thiesfield) + o Avoid errors in http.c when building with VC 2003 .NET (13e4f3b Brodie Thiesfield) + o Support the standard 'make check' target in place of 'make verify' (426c8fb) + o Remove redundant stuff from EXTRA_DIST (b660edf) + o Switch to using AM conditionals in place of AC_LIBOBJ (2e898f5) + o Remove an orphaned RELEASE flag in Makefile.am (0794b0d) + o Give a better warning for bad automake versions. (77c917d) + o Use dist_bin_SCRIPTS, not EXTRA_DIST, to distribute scripts (9eb2fd7) + o Never test for select() on windows (3eb044d Trond Norbye) + o Do not inhibit automake dependencies generation (10c4c90 Giuseppe Scrivano) + o Create shared libraries under Windows (3cbca86 Giuseppe Scrivano) + o Add ctags/etags files to .gitignore (0861d17) + o Only specify -no-undefined on mingw (25433b9) + o Only add libevent_core.la to LIBADD on mingw (fdc6297) + +TESTING + o Get bench_http to work on Windows; add a switch to enable IOCP. (4ac38a5 Christopher Davis) + o VC has no getopt(), so do without in bench_http. (1273d2f Christopher Davis) + o Fix an obnoxious typo in the bufferevent_timeout_filter test (0d047c3) + o Fix a write of uninitialized RAM in regression tests (68dc742) + o Fix some memory leaks in the unit tests (274a7bd) + o Make 'main/many_events' test 70 fds, not 64. (33874b0) + o Unit-test every evbuffer_add_file() implementation. (06a4443) + o Add more unit tests for evbuffer_expand (8c83e99) + o Test another case of evbuffer_prepend (1234b95) + o Fix a possible double-free bug in SSL bufferevents with CLOSE_ON_FREE (7501895) o Add dns/search_cancel unit test. (39b870b Christopher Davis) + o Make http_base_test stop leaking an event_base. (96730d3) + o Detect broken unsetenv at unit-test runtime (f37cd4c) + o Implement regress_make_tempfile on win32 to test evbuffer_add_file (b4f12a1) + o add more (currently skipped) add_file tests on win32 (05de45d) + o Fix bench_http build on win32. (384d124) + o Make unit test for add_file able to tell "error" from "done" (88a543f) + o Make test for bufferevent_connect_hostname system-neutral (f89168e) + o Make test.sh support mingw/msys on win32 (0ee6f6c) + o Fix test.sh on freebsd (3d9e05b) + +INTERNALS, PERFORMANCE, AND AND CODE CLEANUPS + o Improve the speed of evbuffer_readln() (cc1600a) + o more whitespace normalization (2c2618d) + o Revise evbuffer to add last_with_data (2a6d2a1) + o Use last_with_data in place of previous_to_last (c8ac57f) + o Remove previous_to_last from evbuffer (6f47bd1) + o Fix last_with_data compilation on windows (1e7b986) + o Add some glass-box tests for the last_with_data code. (17da042) + o Improve robustness for refcounting (f1bc125) + o Remove a needless min_heap_shift_up_() call (7204b91) + o Increase MIN_BUFFER_SIZE to 512 (1024 on 64-bit) (2014ae4) + o Do not use evbuffer_expand() to add the first chain to a buffer (5c0ebb3) + o Make evbuffer_prepend handle empty buffers better (c87272b) + o Replace last_with_data with a slightly smarter version (b7442f8) + o Turn the increasingly complex *_CHAIN() macros into functions (96865c4) + o Rewrite evbuffer_expand and its users (d5ebcf3) + o Add evutil_tv_to_msec for safe conversion of timevals to milliseconds. (850c3ff Christopher Davis) + o Initialize last_with_datap correctly in evbuffer_overlapped (a0983b6) + o Replace EVUTIL_CLOSESOCKET macro with a function (899c1dc Sebastian Sjöberg) + o Move domain search state to evdns_request. (beaa14a Christopher Davis) + o Remove redundant checks for lock!=NULL before calling EVLOCK_LOCK (50ec59f) + o Rename current_base symbol to event_global_current_base_ (c16e684) + o Fix whitespace in evutil.c (935e150) + o Replace users of "int fd" with "evutil_socket_t fd" in portable code (c7cf6f0) + + + +Changes in 2.0.4-alpha (28 Feb 2010): + [Autogenerated from the Git log, sorted by hand.] +DOCUMENTATION + o Add stub header for 2.0.4-alpha changelog. (94d0065) + o Improve the README with more information and links. (0b42726) + o Add more people who wrote patches to the acknowledgments (0af10d5) + o Add a warning about the use of event_initialized. (f32b575) + o Add a LICENSE file so people can find our license easily (7067006) + o Add a new "hello world" sample program (becb9f9) + o Clarify status of example programs (d60a1bd) + o Update time-test.c to use event2 (f4190bf) + o Add the arc4random.c license to the LICENSE file. (e15e1e9) + +NEW FEATURES AND INTERFACE CHANGES + o Improved optional lock debugging. (0cd3bb9) + o Rate-limiting for bufferevents; group and individual limits are supported. (737c9cd) + o Testing code for bufferevent rate-limiting. (f0c0124) + o Make the initial nameserver probe timeout configurable. (1e56a32) + o Revise the locking API: deprecate the old locking callbacks and add trylock. (347952f) + o Do not make bufferevent_setfd implicitly disable EV_READ and EV_WRITE. (8274379) + o Do not ignore bufferevent_enable(EV_READ) before bufferevent_connect(). (4a5b534) + o Introduced evutil_make_socket_closeonexec() to preserve fd flags for F_SETFD. (d0939d2 Jardel Weyrich) + o evdns_getaddrinfo() now supports the /etc/hosts file. (72dd666) + o Look at the proper /etc/hosts file on windows. (66c02c7) + o Allow http connections to use evdns for hostname looksups. (c698b77) + o Changelist code to defer event changes until just before dispatch (27308aa) + o do not use a function to assign the evdns base; instead assign it via evhttp_connection_base_new() which is a new function introduced in 2.0 (5032e52) + o Functions to access more fields of struct event. (0683950) + o Make kqueue use changelists. (45e5ae3) + o Remove kqueue->pend_changes. (3225dfb) + o Minimize epoll_ctl calls by using changelist (c8c6a89) + o Add support for a "debug mode" to try to catch common errors. (cd17c3a) + o Note a missing ratelim function (361da8f) + o Add ev_[u]intptr_t to include/event2/util.h (1fa4c81) + o const-ify a few more functions in event.h (d38a7a1) + o Deprecate EVENT_FD and EVENT_SIGNAL. (f6b2694) + o Remove EVUTIL_CHECK_FMT. (6c21c89) + o Add EV_*_MAX macros to event2/util.h to expose limits for ev_* types. (aba1fff) o Functions to view and manipulate rate-limiting buckets. (85047a6) + o Add the rest of the integer limits, and add a test for them. (60742d5) + o Remove the 'flags' argument from evdns_base_set_option() (1dd7e6d) + o Add an arc4random implementation for use by evdns (d4de062) + o Use off_t for the length parameter of evbuffer_add_file (3fe60fd) + o Construct Windows locks using InitializeCriticalSectionAndSpinCount (32c6f1b) + o Expose view of current rate limit as constrained by group limit (162ce8a) + o Provide consistent, tested semantics for bufferevent timeouts (d328829) + +BUGFIXES AND TESTS + o Tolerate code that returns from a fatal_cb. (91fe23f) + o Parenthesize macro arguments more aggressively (07e9e9b) + o Fix memory-leak of signal handler array with kqueue. (e1ffbb8) + o Stop passing EVTHREAD_READ and EVTHREAD_WRITE to non-rw locks. (76cd2b7) + o Fix two use-after-free bugs in unit tests spoted by lock debugging (d84d838) + o Fix a locking bug in event_base_loop() (da1718b) + o Fix an evdns lock violation. (2df1f82 Zhuang Yuyao) + o Valgrind fix: Clear struct kevent before checking for OSX bug. (56771a3 William Ahern) + o Fix up evthread compilation on windows (bd6f1ba Roman Puls) + o Fix regress_iocp.c usage of old lock allocation macros. (31687b4 unknown) + o Update nmake makefile to build evthread.c (b62d979 unknown) + o Fix a crash when reading badly formatted resolve.conf; from Yasuoka Masahiko (6c7c579 Yasuoka Masahiko) + o Fix a snow leopard compile warning in the unit tests. (7ae9445) + o Fix compile on Snow Leopard with gcc warnings enabled (70cdfe4 Sebastian Hahn) + o Only define _GNU_SOURCE if it is not already defined. (ea6b1df Joachim Bauch) + o Update sample/signal-test.c to use newer APIs and not leak. (f6430ac Evan Jones) + o Fix a segfault when writing a very fragmented evbuffer onto an SSL (a6adeca Joachim Bauch) + o Fix a segfault when freeing SSL bufferevents in an unusual order (a773df5 Joachim Bauch) + o Drop install-sh from our git repo: a mismatched version could break "make dist" (6799527) + o Set all instances of the version number correctly. (5a112d3) + o Fix a few locking issues on windows. (c51bb3c unknown) + o Use evutil_socket_t, not int, when logging socket errors. (292467c) + o Fix up behavior of never-defered callbacks a little (390e056) + o Replace some cases of uint32_t with ev_uint32_t. (a47d88d) + o Fix compilation of devpoll.c by adding missing thread includes. (fee2c77 Dagobert Michelsen) + o Make evutil_make_socket_nonblocking() leave any other flags alone. (4c8b7cd Jardel Weyrich) + o Fix an fd leak in evconnlistener_new_bind(). (24fb502 Jardel Weyrich) + o Fix a bogus free in evutil_new_addrinfo() (0d64051 Jardel Weyrich) + o Adjusted fcntl() retval comparison on evutil_make_socket_nonblocking(). (4df7dbc Jardel Weyrich) + o Fix the code that allowed DNS options to not end with : (ee4953f) + o Fix crash bugs when a bufferevent's eventcb is not set. (2e8eeea) + o Fix test-ratelim compilation on Linux. (885b427) + o Fix compilation of rate-limiting code on win32. (165d30e) + o Eradicated the last free() call. Let mm_free() take care of deallocation. (0546ce1 Jardel Weyrich) + o Fix byte counts when mixing deferred and non-deferred evbuffer callbacks. (29151e6) + o Fixed a memory leak on windows threads implementation. The CRITICAL_SECTION was not being free'd in evthread_win32_lock_free(). (2f33e00 Jardel Weyrich) + o Fixed a fd leak in start_accepting(), plus cosmetic changes (4367a33 Jardel Weyrich) + o Improved error handling in evconnlistener_new_async(). Also keeping the fd open because it is not opened by this function, so the caller is responsible for closing it. Additionally, since evconnlistener_new_bind() creates a socket and passes it to the function above, it required error checking to close the same socket. (fec66f9 Jardel Weyrich) + o Don't use a bind address for nameservers on loopback (8d4aaf9) + o Fix compilation of rate-limit code when threading support is disabled (97a8c79) + o Detect setenv/unsetenv; skip main/base_environ test if we can't fake them. (7296971) + o Check more internal event_add() calls for failure (ff3f6cd) + o Fix windows and msvc build (5c7a7bc) + o Call event_debug_unassign on internal events (a19b4a0) + o Try to fix a warning in hash_debug_entry (137f2c6) + o Fix a dumb typo in ev_intptr_t definitions. (27c9a40) + o do not fail while sending on http connections the client closed. (93d7369) + o make evhttp_send() safe against terminated connections, too (3978180) + o Make Libevent 1.4.12 build on win32 with Unicode enabled. (000a33e Brodie Thiesfield) + o Fix some additional -DUNICODE issues on win32. (a7a9431) + o Add a check to make soure our EVUTIL_AI flags do not conflict with the native ones (c18490e) + o Always use our own gai_strerror() replacement. (6810bdb) + o Make RNG work when we have arc4random() but not arc4random_buf() (4ec8fea) + o validate close cb on server when client connection closes (2f782af) + o Fix two unlocked reads in evbuffer. (7116bf2) + o When working without a current event base, don't try to use IOCP listeners (cb52838) + o Fix getpid() usage on Windows (ff2a134) + o Add a unit test for secure rng. (48a29b6) + o Add some headers to fix freebsd compilation (b72be50) + o When connect() succeeds immediately, don't invoke the callback immediately. (7515de9) + o Suspend read/write on bufferevents during hostname lookup (db08f64) + o Make bufferevent_free() clear all callbacks immediately. (b2fbeb3) + o Fix some race conditions in persistent events and event_reinit (e2642f0) + o Fix a bug in resetting timeouts on persistent events when IO triggers. (38ec0a7) + o Add a test for timeouts on filtering bufferevents. (c02bfe1) + o Add test for periodic timers that get activated for other reasons (8fcb7a1) + o Use new timeval diff comparison function in bufferevent test (f3dfe46) + o Delete stack-alloced event in new unit test before returning. (7ffd387) + o Fix mingw compilation (23170a6) + o Try to define a sane _EVENT_SIZEOF_SIZE_T for msvc compilation (1e14f82) + o Fix arc4random compilation on MSVC. (98edb89) + o deal with connect() failing immediately (7bc48bf) + o Small cleanups on freebsd-connect-refused patch. (57b7248) + +BUILD AND DISTRIBUTION CHANGES + o Remove the contents of WIN32-Prj as unmaintained. (c69d5a5) + o Allow the user to redirect the verbose output of test/test.sh to a file (c382de6) + o Allow test.sh to be run as ./test/test.sh (7dfbe94) + o Never believe that we have pthreads on win32, even if gcc thinks we do. (78ed097) + o Make it compile under gcc --std=c89. (e2ca403) + o Fix a number of warnings from gcc -pedantic (918e9c5) + o Add the msvc-generated .lib files to .gitignore. (e244a2e) + o Add the "compile" script to gitignore. (1ba6bed) + +INTERNALS AND CODE CLEANUPS + o Add a .gitignore file. (ba34071) + o New EVTHREAD_TRY_LOCK function to try to grab a lock. (689fc09) + o Add the abilitity to mark some buffer callbacks as never-deferred. (438f9ed) + o Refactor our 'suspend operation' logic on bufferevents. (0d744aa) + o Simplify the read high-watermark checking. (5846bf6) + o Improve readability of evutil_unparse_protoname() (5a43df8 Jardel Weyrich) + o Expose our cached gettimeofday value with a new interface (47854a8) + o Whitespace fixes in test.sh (0b151a9) + o Enable branch-prediction hints with EVUTIL_UNLIKELY. (eaaf27f) + o Refactor code from evdns into a new internal "read a file" function. (0f7144f) + o Comestic changes in evconnlistener_new(), new_accepting_socket(), accepted_socket_invoke_user_cb() and iocp_listener_enable(). (510ab6b Jardel Weyrich) + o Add unit-test for bad_request bug fixed in 1.4 recently. (6cc79c6 Pavel Plesov) o Add a comment on evthread_enable_lock_debuging. (b9f43b2) + o Fix test.sh on shells without echo -n (94131e9) + o More unit tests for getaddrinfo_async: v4timeout and cancel. (a334b31) + o Make http use evconnlistener. (ec34533) + o move dns utility functions into a separate file so that we can use them for http testing (b822639) + o add a test for evhttp_connection_base_new with a dns_base (26714ca) + o forgot to add void to test function (78a50fe) + o Add a forgotten header (changelist-internal.h) (4b9f307) + o Remove some commented-out code in evutil (26e1b6f) + o Remove a needless include of rpc_compat.h (70a4a3e) + o Use less memory for each entry in a hashtable (a66e947) + o Try to untangle the logic in server_port_flush(). (439aea0) + o Use ev_[u]intptr_t types in place of [u]intptr_t (cef61a2) + o Reduce windows header includes in our own headers. (da6135e) + o clean up terminate_chunked test (e8a9782) + o Increment the submicro version number. (63e868e) + o Update event-config.h version number to match configure.in (aae7db5) + o Clean up formatting: Disallow space-before-tab. (8fdf09c) + o Clean up formatting: use tabs, not 8-spaces, to indent. (e5bbd40) + o Clean up formatting: remove trailing spaces (e5cf987) + o Clean up formatting: function/keyword spacing consistency. (4faeaea) + + + +Changes in 2.0.3-alpha (20 Nov 2009): + o Add a new code to support SSL/TLS on bufferevents, using the OpenSSL library (where available). + o Fix a bug where we didn't allocate enough memory in event_get_supported_methods(). + o Avoid segfault during failed allocation of locked evdns_base. (Found by Rocco Carbone.) + o Export new evutil_ascii_* functions to perform locale-independent character type operations. + o Try to compile better with MSVC: patches from Brodie Thiesfield + o New evconnlistener_get_fd function to expose a listener's associated socket. + o Expose an ev_socklen_t type for consistent use across platforms. + o Make bufferevent_socket_connect() work when the original fd was -1. + o Fix a bug in bufferevent_socket_connect() when the connection succeeds too quickly. + o Export an evutil_sockaddr_cmp() to compare to sockaddr objects for equality. + o Add a bufferevent_get_enabled() to tell what a bufferevent has been configured to do. + o Add an evbuffer_search_eol() function to locate the end of a line nondestructively. + o Add an evbuffer_search_range() function to search a bounded range of a buffer. + o Fix a rare crash bug in evdns. + o Have bufferevent_socket_connect() with no arguments put a bufferevent into connecting mode. + o Support sendfile on Solaris: patch from Caitlin Mercer. + o New functions to explicitly reference a socket used by an evhttp object. Patches from David Reiss. + o When we send a BEV_EVENT_CONNECTED to indicate connected status, we no longer invoke the write callback as well unless we actually wrote data too. + o If the kernel tells us that there are a negative number of bytes to read from a socket, do not believe it. Fixes bug 2841177; found by Alexander Pronchenkov. + o Do not detect whether we have monotonic clock support every time a new event base is created: instead do it only once. Patch taken from Chromium. + o Do not allocate the maximum event queue for the epoll backend at startup. Instead, start out accepting 32 events at a time, and double the queue's size when it seems that the OS is generating events faster than we're requesting them. Saves up to 374K per epoll-based event_base. Resolves bug 2839240. + o Treat an event with a negative fd as valid but untriggerable by Libevent. This is useful for applications that want to manually activate events. + o Fix compilation on Android, which forgot to define fd_mask in its sys/select.h + o Do not drop data from evbuffer when out of memory; reported by Jacek Masiulaniec + o New event_base_got_exit() and event_base_got_break() functions to tell whether an event loop exited because of an event_base_loopexit() or an event_base_loopbreak(). Patch from Ka-Hing Cheung. + o When adding or deleting an event from a non-main thread, only wake up the main thread when its behavior actually needs to change. + o Fix some bugs when using the old evdns interfaces to initialize the evdns module. + o Detect errors during bufferevent_connect(). Patch from Christopher Davis. + o Fix compilation for listener.h for C++ - missing extern "C". Patch from Ferenc Szalai. + o Make the event_base_loop() family of functions respect thread-safety better. This should clear up a few hard-to-debug race conditions. + o Fix a bug when using a specialized memory allocator on win32. + o Have the win32 select() backend label TCP-socket-connected events as EV_WRITE, not EV_READ. This should bring it in line with the other backends, and improve portability. Patch from Christopher Davis. + o Stop using enums as arguments or return values when what we mean is a bitfield of enum values. C++ doesn't believe that you can OR two enum values together and get another enum, and C++ takes its typing seriously. Patch from Christopher Davis. + o Add an API to replace all fatal calls to exit() with a user-provided panic function. + o Replace all assert() calls with a variant that is aware of the user-provided logging and panic functions. + o Add a return value to event_assign so that it can fail rather than asserting when the user gives it bad input. event_set still dies on bad input. + o The event_base_new() and event_base_new_with_config() functions now never call exit() on failure. For backward "compatibility", event_init() still does, but more consistently. + o Remove compat/sys/_time.h. It interfered with system headers on HPUX, and its functionality has been subsumed by event2/util.h and util-internal.h. + o Add a new bufferevent_socket_connect_hostname() to encapsulate the resolve-then-connect operation. + o Build kqueue.c correctly on GNU/kFreeBSD platforms. Patch pulled upstream from Debian. + o Alternative queue-based timeout algorithm for programs that use a large number of timeouts with the same value. + o New event_base_config option to disable the timeval cache entirely. + o Make EV_PERSIST timeouts more accurate: schedule the next event based on the scheduled time of the previous event, not based on the current time. + o Allow http.c to handle cases where getaddrinfo returns an IPv6 address. Patch from Ryan Phillips. + o Fix a problem with excessive memory allocation when using multiple event priorities. + o Default to using arc4random for DNS transaction IDs on systems that have it; from OpenBSD. + o Never check the environment when we're running setuid or setgid; from OpenBSD. + o Options passed to evdns_set_option() no longer need to end with a colon. + o Add an evutil_getaddrinfo() function to clone getaddrinfo on platforms that don't have it. + o Add an evdns_getaddrinfo() function to provide a nonblocking getaddrinfo using evdns, so programs can perform useful hostname lookup. + o Finally expose the IOCP-based bufferevent backend. It passes its unit tests, but probably still has some bugs remaining. Code by Nick Mathewson and Christopher Davis. + o Numerous other bugfixes. + o On FreeBSD and other OSes, connect can return ECONREFUSED immediately; instead of failing the function call, pretend with faileld in the callback. + o Fix a race condition in the pthreads test case; found by Nick Mathewson + o Remove most calls to event_err() in http and deal with memory errors instead + + + +Changes in 2.0.2-alpha (25 Jul 2009): + o Add a new flag to bufferevents to make all callbacks automatically deferred. + o Make evdns functionality locked, and automatically defer dns callbacks. + o Fix a possible free(NULL) when freeing an event_base with no signals. + o Add a flag to disable checking environment varibles when making an event_base + o Disallow setting less than 1 priority. + o Fix a bug when removing a timeout from the heap. [Patch from Marko Kreen] + o Use signal.h, not sys/signal.h. [Patch from mmadia] + o Try harder to build with certain older c99 compilers. + o Make sure that an event_config's flags field is always initialized to 0. [Bug report from Victor Goya] + o Avoid data corruption when reading data entirely into the second-to-last chain of an evbuffer. [Bug report from Victor Goya] + o Make sendfile work on FreeBSD + o Do not use vararg macros for accessing evrpc structures; this is not backwards compatible, but we did not promise any backwards compatibility for the rpc code. + o Actually define the event_config_set_flag() function. + o Try harder to compile with Visual C++. + o Move event_set() and its allies to event2/event_compat.h where they belong. + o Remove the event_gotsig code, which has long been deprecated and unused. + o Add an event_get_base() function to return the base assigned to an event. + o New function to automate connecting on a socket-based bufferevent. + o New functions to automate listening for incoming TCP connections. + o Do case-insensitive checks with a locale-independent comparison function. + o Rename the evbuffercb and everrorcb callbacks to bufferevent_data_cb and bufferevent_event_cb respectively. The old names are available in bufferevent_compat.h. + o Rename the EVBUFFER_* codes used by bufferevent event callbacks to BEV_EVENT_*, to avoid namespace collision with evbuffer flags. The old names are available in bufferevent_compat.h. + o Move the EVBUFFER_INPUT and EVBUFFER_OUTPUT macros to bufferevent_compat.h + o Add a bufferevent_getfd() function to mirror bufferevent_setfd() + o Make bufferevent_setfd() return an error code if the operation is not successful. + o Shave 22 bytes off struct event on 32-bit platforms by shrinking and re-ordering fields. The savings on 64-bit platforms is likely higher. + o Cap the maximum number of priorities at 256. + o Change the semantics of evbuffer_cb_set_flags() to be set-flag only; add a new evbuffer_cb_clear_flags() to remove set flags. + o Change the interface of evbuffer_add_reference so that the cleanup callback gets more information + o Revise the new evbuffer_reserve_space/evbuffer_commit_space() interfaces so that you can use them without causing extraneous copies or leaving gaps in the evbuffer. + o Add a new evbuffer_peek() interface to inspect data in an evbuffer without removing it. + o Fix a deadlock when suspending reads in a bufferevent due to a full buffer. (Spotted by Joachim Bauch.) + o Fix a memory error when freeing a thread-enabled event base with registered events. (Spotted by Joachim Bauch.) + o Try to contain degree of failure when running on a win32 version so heavily firewalled that we can't fake a socketpair. + o Activate fd events in a pseudorandom order with O(N) backends, so that we don't systematically favor low fds (select) or earlier-added fds (poll, win32). + o Replace some read()/write() instances with send()/recv() to work properly on win32. + o Set truncated flag correctly in evdns server replies. + o Raise RpcGenError in event_rpcgen.py; from jmanison and Zack Weinberg + o Fix preamble of rpcgen-generated files to rely on event2 includes; based on work by jmansion; patch from Zack Weinberg. + o Allow specifying the output filename for rpcgen; based on work by jmansion; patch from Zack Weinberg. + o Allow C identifiers as struct names; allow multiple comments in .rpc files; from Zack Weinberg + o Mitigate a race condition when using socket bufferevents in multiple threads. + o Use AC_SEARCH_LIBS, not AC_CHECK_LIB to avoid needless library use. + o Do not allow event_del(ev) to return while that event's callback is executing in another thread. This fixes a nasty race condition. + o event_get_supported_methods() now lists methods that have been disabled with the EVENT_NO* environment options. + o Rename encode_int[64] to evtag_encode_int[64] to avoid polluting the global namespace. The old method names are still available as macros in event2/tag_compat.h. + + + +Changes in 2.0.1-alpha (17 Apr 2009): + o free minheap on event_base_free(); from Christopher Layne + o debug cleanups in signal.c; from Christopher Layne + o provide event_base_new() that does not set the current_base global + o bufferevent_write now uses a const source argument; report from Charles Kerr + o improve documentation on event_base_loopexit; patch from Scott Lamb + o New function, event_{base_}loopbreak. Like event_loopexit, it makes an event loop stop executing and return. Unlike event_loopexit, it keeps subsequent pending events from getting executed. Patch from Scott Lamb + o Check return value of event_add in signal.c + o provide event_reinit() to reintialize an event_base after fork + o New function event_set_mem_functinons. It allows the user to give libevent replacement functions to use for memory management in place of malloc(), free(), etc. This should be generally useful for memory instrumentation, specialized allocators, and so on. + o The kqueue implementation now catches signals that are raised after event_add() is called but before the event_loop() call. This makes it match the other implementations. + o The kqueue implementation now restores original signal handlers correctly when its signal events are removed. + o Check return value of event_add in signal.c + o Add a more powerful evbuffer_readln as a replacement for evbuffer_readline. The new function handles more newline styles, and is more useful with buffers that may contain a nul characters. + o Do not mangle socket handles on 64-bit windows. + o The configure script now takes an --enable-gcc-warnigns option that turns on many optional gcc warnings. (Nick has been building with these for a while, but they might be useful to other developers.) + o move EV_PERSIST handling out of the event backends + o small improvements to evhttp documentation + o always generate Date and Content-Length headers for HTTP/1.1 replies + o set the correct event base for HTTP close events + o When building with GCC, use the "format" attribute to verify type correctness of calls to printf-like functions. + o Rewrite win32.c backend to be O(n lg n) rather than O(n^2). + o Removed obsoleted recalc code + o support for 32-bit tag numbers in rpc structures; this is wire compatible, but changes the API slightly. + o pull setters/getters out of RPC structures into a base class to which we just need to store a pointer; this reduces the memory footprint of these structures. + o prefix {encode,decode}_tag functions with evtag to avoid collisions + o fix a bug with event_rpcgen for integers + o Correctly handle DNS replies with no answers set (Fixes bug 1846282) + o add -Wstrict-aliasing to warnings and more cleanup + o removed linger from http server socket; reported by Ilya Martynov + o event_rpcgen now allows creating integer arrays + o support string arrays in event_rpcgen + o change evrpc hooking to allow pausing of RPCs; this will make it possible for the hook to do some meaning ful work; this is not backwards compatible. + o allow an http request callback to take ownership of a request structure + o allow association of meta data with RPC requests for hook processing + o associate more context for hooks to query such as the connection object + o remove pending timeouts on event_base_free() + o also check EAGAIN for Solaris' event ports; from W.C.A. Wijngaards + o devpoll and evport need reinit; tested by W.C.A Wijngaards + o event_base_get_method; from Springande Ulv + o Send CRLF after each chunk in HTTP output, for compliance with RFC2626. Patch from "propanbutan". Fixes bug 1894184. + o Add a int64_t parsing function, with unit tests, so we can apply Scott Lamb's fix to allow large HTTP values. + o Use a 64-bit field to hold HTTP content-lengths. Patch from Scott Lamb. + o Allow regression code to build even without Python installed + o remove NDEBUG ifdefs from evdns.c + o detect integer types properly on platforms without stdint.h + o udpate documentation of event_loop and event_base_loop; from Tani Hosokawa. + o simplify evbuffer by removing orig_buffer + o do not insert event into list when evsel->add fails + o add support for PUT/DELETE requests; from Josh Rotenberg + o introduce evhttp_accept_socket() to accept from an already created socket + o include Content-Length in reply for HTTP/1.0 requests with keep-alive + o increase listen queue for http sockets to 128; if that is not enough the evhttp_accpet_socket() api can be used with a prepared socket. + o Patch from Tani Hosokawa: make some functions in http.c threadsafe. + o test support for PUT/DELETE requests; from Josh Rotenberg + o rewrite of the evbuffer code to reduce memory copies + o Some older Solaris versions demand that _REENTRANT be defined to get strtok_r(); do so. + o Do not free the kqop file descriptor in other processes, also allow it to be 0; from Andrei Nigmatulin + o Provide OpenSSL style support for multiple threads accessing the same event_base + o make event_rpcgen.py generate code include event-config.h; reported by Sam Banks. + o switch thread support so that locks get allocated as they are needed. + o make event methods static so that they are not exported; from Andrei Nigmatulin + o make RPC replies use application/octet-stream as mime type + o do not delete uninitialized timeout event in evdns + o Correct the documentation on buffer printf functions. + o Don't warn on unimplemented epoll_create(): this isn't a problem, just a reason to fall back to poll or select. + o Correctly handle timeouts larger than 35 minutes on Linux with epoll.c. This is probably a kernel defect, but we'll have to support old kernels anyway even if it gets fixed. + o Make name_from_addr() threadsafe in http.c + o Add new thread-safe interfaces to evdns functions. + o Make all event_tagging interfaces threadsafe. + o Rename internal memory management functions. + o New functions (event_assign, event_new, event_free) for use by apps that want to be safely threadsafe, or want to remain ignorant of the contents of struct event. + o introduce bufferevent_read_buffer; allows reading without memory copy. + o expose bufferevent_setwatermark via header files and fix high watermark on read + o fix a bug in buffrevent read water marks and add a test for them + o fix a bug in which bufferevent_write_buffer would not schedule a write event + o provide bufferevent_input and bufferevent_output without requiring knowledge of the structure + o introduce bufferevent_setcb and bufferevent_setfd to allow better manipulation of bufferevents + o convert evhttp_connection to use bufferevents. + o use libevent's internal timercmp on all platforms, to avoid bugs on old platforms where timercmp(a,b,<=) is buggy. + o Remove the never-exported, never-used evhttp_hostportfile function. + o Support input/output filters for bufferevents; somewhat similar to libio's model. This will allow us to implement SSL, compression, etc, transparently to users of bufferevents such as the http layer. + o allow connections to be removed from an rpc pool + o add new evtimer_assign, signal_assign, evtimer_new, and signal_new functions to manipulate timer and signal events, analagous to the now-recommended event_assign and event_new + o switch internal uses of event_set over to use event_assign. + o introduce evbuffer_contiguous_space() api that tells a user how much data is available in the first buffer chain + o introduce evbuffer_reserve_space() and evbuffer_commit_space() to make processing in filters more efficient. + o reduce system calls for getting current time by caching it. + o separate signal events from io events; making the code less complex. + o support for periodic timeouts + o support for virtual HTTP hosts. + o turn event_initialized() into a function, and add function equivalents to EVENT_SIGNAL and EVENT_FD so that people don't need to include event_struct.h + o Build test directory correctly with CPPFLAGS set. + o Provide an API for retrieving the supported event mechanisms. + o event_base_new_with_config() and corresponding config APIs. + o migrate the evhttp header to event2/ but accessors are still missing. + o deprecate timeout_* event functions by moving them to event_compat.h + o Move windows gettimeofday replacement into a new evutil_gettimeofday(). + o Make configure script work on IRIX. + o provide a method for canceling ongoing http requests. + o Make vsnprintf() returns consistent on win32. + o Fix connection keep-alive behavior for HTTP/1.0 + o Fix use of freed memory in event_reinit; pointed out by Peter Postma + o constify struct timeval * where possible + o make event_get_supported_methods obey environment variables + o support for edge-triggered events on epoll and kqueue backends: patch from Valery Kholodkov + o support for selecting event backends by their features, and for querying the features of a backend. + o change failing behavior of event_base_new_with_config: if a config is provided and no backend is selected, return NULL instead of aborting. + o deliver partial data to request callbacks when chunked callback is set even if there is no chunking on the http level; allows cancelation of requests from within the chunked callback; from Scott Lamb. + o allow min_heap_erase to be called on removed members; from liusifan. + o Rename INPUT and OUTPUT to EVRPC_INPUT and EVRPC_OUTPUT. Retain INPUT/OUTPUT aliases on on-win32 platforms for backwards compatibility. + o Do not use SO_REUSEADDR when connecting + o Support 64-bit integers in RPC structs + o Correct handling of trailing headers in chunked replies; from Scott Lamb. + o Support multi-line HTTP headers; based on a patch from Moshe Litvin + o Reject negative Content-Length headers; anonymous bug report + o Detect CLOCK_MONOTONIC at runtime for evdns; anonymous bug report + o Various HTTP correctness fixes from Scott Lamb + o Fix a bug where deleting signals with the kqueue backend would cause subsequent adds to fail + o Support multiple events listening on the same signal; make signals regular events that go on the same event queue; problem report by Alexander Drozdov. + o Fix a problem with epoll() and reinit; problem report by Alexander Drozdov. + o Fix off-by-one errors in devpoll; from Ian Bell + o Make event_add not change any state if it fails; reported by Ian Bell. + o Fix a bug where headers arriving in multiple packets were not parsed; fix from Jiang Hong; test by me. + o Match the query in DNS replies to the query in the request; from Vsevolod Stakhov. + o Add new utility functions to correctly observe and log winsock errors. + o Do not remove Accept-Encoding header + o Clear the timer cache on entering the event loop; reported by Victor Chang + o Only bind the socket on connect when a local address has been provided; reported by Alejo Sanchez + o Allow setting of local port for evhttp connections to support millions of connections from a single system; from Richard Jones. + o Clear the timer cache when leaving the event loop; reported by Robin Haberkorn + o Fix a typo in setting the global event base; reported by lance. + o Set the 0x20 bit on outgoing alphabetic characters in DNS requests randomly, and insist on a match in replies. This helps resist DNS poisoning attacks. + o Make the http connection close detection work properly with bufferevents and fix a potential memory leak associated with it. + o Restructure the event backends so that they do not need to keep track of events themselves, as a side effect multiple events can use the same fd or signal. + o Add generic implementations for parsing and emiting IPv6 addresses on platforms that do not have inet_ntop and/or inet_pton. + o Allow DNS servers that have IPv6 addresses. + o Add an evbuffer_write_atmost() function to write a limited number of bytes to an fd. + o Refactor internal notify-main-thread logic to prefer eventfd to pipe, then pipe to socketpair, and only use socketpairs as a last resort. + o Try harder to pack all evbuffer reads into as few chains as possible, using readv/WSARecv as appropriate. + o New evthread_use_windows_threads() and evthread_use_pthreads() functions to set up the evthread callbacks with reasonable defaults. + o Change the semantics of timeouts in conjunction with EV_PERSIST; timeouts in that case will now repeat until deleted. + o sendfile, mmap and memory reference support for evbuffers. + o New evutil_make_listen_socket_reuseable() to abstract SO_REUSEADDR. + o New bind-to option to allow DNS clients to bind to an arbitrary port for outgoing requests. + o evbuffers can now be "frozen" to prevent operations at one or both ends. + o Bufferevents now notice external attempts to add data to an inbuf or remove it from an outbuf, and stop them. + o Fix parsing of queries where the encoded queries contained \r, \n or + + o Do not allow internal events to starve lower-priority events. + diff --git a/contrib/ntp/sntp/libevent/Doxyfile b/contrib/ntp/sntp/libevent/Doxyfile new file mode 100644 index 000000000..d9d660345 --- /dev/null +++ b/contrib/ntp/sntp/libevent/Doxyfile @@ -0,0 +1,257 @@ +# Doxyfile 1.5.1 + +# This file describes the settings to be used by the documentation system +# doxygen (www.doxygen.org) for a project +# +# All text after a hash (#) is considered a comment and will be ignored +# The format is: +# TAG = value [value, ...] +# For lists items can also be appended using: +# TAG += value [value, ...] +# Values that contain spaces should be placed between quotes (" ") + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- + +# The PROJECT_NAME tag is a single word (or a sequence of words surrounded +# by quotes) that should identify the project. + +PROJECT_NAME = libevent + +# Place all output under 'doxygen/' + +OUTPUT_DIRECTORY = doxygen/ + +# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen +# will interpret the first line (until the first dot) of a JavaDoc-style +# comment as the brief description. If set to NO, the JavaDoc +# comments will behave just like the Qt-style comments (thus requiring an +# explicit @brief command for a brief description. + +JAVADOC_AUTOBRIEF = YES + +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C +# sources only. Doxygen will then generate output that is more tailored for C. +# For instance, some of the names that are used will be different. The list +# of all members will be omitted, etc. + +OPTIMIZE_OUTPUT_FOR_C = YES + +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the +# brief documentation of file, namespace and class members alphabetically +# by member name. If set to NO (the default) the members will appear in +# declaration order. + +SORT_BRIEF_DOCS = YES + +# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag +# can be used to strip a user-defined part of the path. Stripping is +# only done if one of the specified strings matches the left-hand part of +# the path. The tag can be used to show relative paths in the file list. +# If left blank the directory from which doxygen is run is used as the +# path to strip. + +STRIP_FROM_PATH = include/ + +#--------------------------------------------------------------------------- +# configuration options related to the input files +#--------------------------------------------------------------------------- + +# The INPUT tag can be used to specify the files and/or directories that contain +# documented source files. You may enter file names like "myfile.cpp" or +# directories like "/usr/src/myproject". Separate the files or directories +# with spaces. + +INPUT = \ + include/event2/buffer.h \ + include/event2/buffer_compat.h \ + include/event2/bufferevent.h \ + include/event2/bufferevent_compat.h \ + include/event2/bufferevent_ssl.h \ + include/event2/dns.h \ + include/event2/dns_compat.h \ + include/event2/event.h \ + include/event2/event_compat.h \ + include/event2/http.h \ + include/event2/http_compat.h \ + include/event2/listener.h \ + include/event2/rpc.h \ + include/event2/rpc_compat.h \ + include/event2/tag.h \ + include/event2/tag_compat.h \ + include/event2/thread.h \ + include/event2/util.h + +#--------------------------------------------------------------------------- +# configuration options related to the HTML output +#--------------------------------------------------------------------------- + +# If the GENERATE_HTML tag is set to YES (the default) Doxygen will +# generate HTML output. + +GENERATE_HTML = YES + +#--------------------------------------------------------------------------- +# configuration options related to the LaTeX output +#--------------------------------------------------------------------------- + +# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will +# generate Latex output. + +GENERATE_LATEX = YES + +# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `latex' will be used as the default path. + +LATEX_OUTPUT = latex + +# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be +# invoked. If left blank `latex' will be used as the default command name. + +LATEX_CMD_NAME = latex + +# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to +# generate index for LaTeX. If left blank `makeindex' will be used as the +# default command name. + +MAKEINDEX_CMD_NAME = makeindex + +# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact +# LaTeX documents. This may be useful for small projects and may help to +# save some trees in general. + +COMPACT_LATEX = NO + +# The PAPER_TYPE tag can be used to set the paper type that is used +# by the printer. Possible values are: a4, a4wide, letter, legal and +# executive. If left blank a4wide will be used. + +PAPER_TYPE = a4wide + +# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX +# packages that should be included in the LaTeX output. + +EXTRA_PACKAGES = + +# The LATEX_HEADER tag can be used to specify a personal LaTeX header for +# the generated latex document. The header should contain everything until +# the first chapter. If it is left blank doxygen will generate a +# standard header. Notice: only use this tag if you know what you are doing! + +LATEX_HEADER = + +# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated +# is prepared for conversion to pdf (using ps2pdf). The pdf file will +# contain links (just like the HTML output) instead of page references +# This makes the output suitable for online browsing using a pdf viewer. + +PDF_HYPERLINKS = NO + +# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of +# plain latex in the generated Makefile. Set this option to YES to get a +# higher quality PDF documentation. + +USE_PDFLATEX = YES + +# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. +# command to the generated LaTeX files. This will instruct LaTeX to keep +# running if errors occur, instead of asking the user for help. +# This option is also used when generating formulas in HTML. + +LATEX_BATCHMODE = NO + +# If LATEX_HIDE_INDICES is set to YES then doxygen will not +# include the index chapters (such as File Index, Compound Index, etc.) +# in the output. + +LATEX_HIDE_INDICES = NO + +#--------------------------------------------------------------------------- +# configuration options related to the man page output +#--------------------------------------------------------------------------- + +# If the GENERATE_MAN tag is set to YES (the default) Doxygen will +# generate man pages + +GENERATE_MAN = NO + +# The MAN_EXTENSION tag determines the extension that is added to +# the generated man pages (default is the subroutine's section .3) + +MAN_EXTENSION = .3 + +# If the MAN_LINKS tag is set to YES and Doxygen generates man output, +# then it will generate one additional man file for each entity +# documented in the real man page(s). These additional files +# only source the real man page, but without them the man command +# would be unable to find the correct page. The default is NO. + +MAN_LINKS = YES + +#--------------------------------------------------------------------------- +# Configuration options related to the preprocessor +#--------------------------------------------------------------------------- + +# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will +# evaluate all C-preprocessor directives found in the sources and include +# files. + +ENABLE_PREPROCESSING = YES + +# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro +# names in the source code. If set to NO (the default) only conditional +# compilation will be performed. Macro expansion can be done in a controlled +# way by setting EXPAND_ONLY_PREDEF to YES. + +MACRO_EXPANSION = NO + +# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES +# then the macro expansion is limited to the macros specified with the +# PREDEFINED and EXPAND_AS_DEFINED tags. + +EXPAND_ONLY_PREDEF = NO + +# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files +# in the INCLUDE_PATH (see below) will be search if a #include is found. + +SEARCH_INCLUDES = YES + +# The INCLUDE_PATH tag can be used to specify one or more directories that +# contain include files that are not input files but should be processed by +# the preprocessor. + +INCLUDE_PATH = + +# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard +# patterns (like *.h and *.hpp) to filter out the header-files in the +# directories. If left blank, the patterns specified with FILE_PATTERNS will +# be used. + +INCLUDE_FILE_PATTERNS = + +# The PREDEFINED tag can be used to specify one or more macro names that +# are defined before the preprocessor is started (similar to the -D option of +# gcc). The argument of the tag is a list of macros of the form: name +# or name=definition (no spaces). If the definition and the = are +# omitted =1 is assumed. To prevent a macro definition from being +# undefined via #undef or recursively expanded use the := operator +# instead of the = operator. + +PREDEFINED = TAILQ_ENTRY RB_ENTRY EVENT_DEFINED_TQENTRY_ EVENT_IN_DOXYGEN_ + +# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then +# this tag can be used to specify a list of macro names that should be expanded. +# The macro definition that is found in the sources will be used. +# Use the PREDEFINED tag if you want to use a different macro definition. + +EXPAND_AS_DEFINED = + +# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then +# doxygen's preprocessor will remove all function-like macros that are alone +# on a line, have an all uppercase name, and do not end with a semicolon. Such +# function macros are typically used for boiler-plate code, and will confuse +# the parser if not removed. + +SKIP_FUNCTION_MACROS = YES diff --git a/contrib/ntp/sntp/libevent/LICENSE b/contrib/ntp/sntp/libevent/LICENSE new file mode 100644 index 000000000..402ca5089 --- /dev/null +++ b/contrib/ntp/sntp/libevent/LICENSE @@ -0,0 +1,99 @@ +Libevent is available for use under the following license, commonly known +as the 3-clause (or "modified") BSD license: + +============================== +Copyright (c) 2000-2007 Niels Provos +Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. +3. The name of the author may not be used to endorse or promote products + derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +============================== + +Portions of Libevent are based on works by others, also made available by +them under the three-clause BSD license above. The copyright notices are +available in the corresponding source files; the license is as above. Here's +a list: + +log.c: + Copyright (c) 2000 Dug Song + Copyright (c) 1993 The Regents of the University of California. + +strlcpy.c: + Copyright (c) 1998 Todd C. Miller + +win32select.c: + Copyright (c) 2003 Michael A. Davis + +evport.c: + Copyright (c) 2007 Sun Microsystems + +ht-internal.h: + Copyright (c) 2002 Christopher Clark + +minheap-internal.h: + Copyright (c) 2006 Maxim Yegorushkin + +============================== + +The arc4module is available under the following, sometimes called the +"OpenBSD" license: + + Copyright (c) 1996, David Mazieres + Copyright (c) 2008, Damien Miller + + Permission to use, copy, modify, and distribute this software for any + purpose with or without fee is hereby granted, provided that the above + copyright notice and this permission notice appear in all copies. + + THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +============================== + +The Windows timer code is based on code from libutp, which is +distributed under this license, sometimes called the "MIT" license. + + +Copyright (c) 2010 BitTorrent, Inc. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/contrib/ntp/sntp/libevent/Makefile.am b/contrib/ntp/sntp/libevent/Makefile.am new file mode 100644 index 000000000..1300e8f9d --- /dev/null +++ b/contrib/ntp/sntp/libevent/Makefile.am @@ -0,0 +1,303 @@ +# Makefile.am for libevent +# Copyright 2000-2007 Niels Provos +# Copyright 2007-2012 Niels Provos and Nick Mathewson +# +# See LICENSE for copying information. + +# 'foreign' means that we're not enforcing GNU package rules strictly. +# '1.9' means that we need automake 1.9 or later (and we do). +AUTOMAKE_OPTIONS = foreign 1.9 subdir-objects + +ACLOCAL_AMFLAGS = -I m4 + +# This is the "Release" of the Libevent ABI. It takes precedence over +# the VERSION_INFO, so that two versions of Libevent with the same +# "Release" are never binary-compatible. +# +# This number incremented once for the 2.0 release candidate, and +# will increment for each series until we revise our interfaces enough +# that we can seriously expect ABI compatibility between series. +# +RELEASE = -release 2.1 + +# This is the version info for the libevent binary API. It has three +# numbers: +# Current -- the number of the binary API that we're implementing +# Revision -- which iteration of the implementation of the binary +# API are we supplying? +# Age -- How many previous binary API versions do we also +# support? +# +# To increment a VERSION_INFO (current:revision:age): +# If the ABI didn't change: +# Return (current:revision+1:age) +# If the ABI changed, but it's backward-compatible: +# Return (current+1:0:age+1) +# If the ABI changed and it isn't backward-compatible: +# Return (current+1:0:0) +# +# Once an RC is out, DO NOT MAKE ANY ABI-BREAKING CHANGES IN THAT SERIES +# UNLESS YOU REALLY REALLY HAVE TO. +VERSION_INFO = 5:0:0 + +# History: RELEASE VERSION_INFO +# 2.0.1-alpha -- 2.0 1:0:0 +# 2.0.2-alpha -- 2:0:0 +# 2.0.3-alpha -- 2:0:0 (should have incremented; didn't.) +# 2.0.4-alpha -- 3:0:0 +# 2.0.5-beta -- 4:0:0 +# 2.0.6-rc -- 2.0 2:0:0 +# 2.0.7-rc -- 2.0 3:0:1 +# 2.0.8-rc -- 2.0 4:0:2 +# 2.0.9-rc -- 2.0 5:0:0 (ABI changed slightly) +# 2.0.10-stable-- 2.0 5:1:0 (No ABI change) +# 2.0.11-stable-- 2.0 6:0:1 (ABI changed, backward-compatible) +# 2.0.12-stable-- 2.0 6:1:1 (No ABI change) +# 2.0.13-stable-- 2.0 6:2:1 (No ABI change) +# 2.0.14-stable-- 2.0 6:3:1 (No ABI change) +# 2.0.15-stable-- 2.0 6:3:1 (Forgot to update :( ) +# 2.0.16-stable-- 2.0 6:4:1 (No ABI change) +# 2.0.17-stable-- 2.0 6:5:1 (No ABI change) +# 2.0.18-stable-- 2.0 6:6:1 (No ABI change) +# 2.0.19-stable-- 2.0 6:7:1 (No ABI change) +# 2.0.20-stable-- 2.0 6:8:1 (No ABI change) +# 2.0.21-stable-- 2.0 6:9:1 (No ABI change) +# +# For Libevent 2.1: +# 2.1.1-alpha -- 2.1 1:0:0 +# 2.1.2-alpha -- 2.1 1:0:0 (should have been 2:0:1) +# 2.1.3-alpha -- 2.1 3:0:0 (ABI changed slightly) +# 2.1.4-alpha -- 2.1 4:0:0 (ABI changed slightly) +# 2.1.5-beta -- 2.1 5:0:0 (ABI changed slightly) + +# ABI version history for this package effectively restarts every time +# we change RELEASE. Version 1.4.x had RELEASE of 1.4. +# +# Ideally, we would not be using RELEASE at all; instead we could just +# use the VERSION_INFO field to label our backward-incompatible ABI +# changes, and those would be few and far between. Unfortunately, +# Libevent still exposes far too many volatile structures in its +# headers, so we pretty much have to assume that most development +# series will break ABI compatibility. For now, it's simplest just to +# keep incrementing the RELEASE between series and resetting VERSION_INFO. +# +# Eventually, when we get to the point where the structures in the +# headers are all non-changing (or not there at all!), we can shift to +# a more normal worldview where backward-incompatible ABI changes are +# nice and rare. For the next couple of years, though, 'struct event' +# is user-visible, and so we can pretty much guarantee that release +# series won't be binary-compatible. + +if INSTALL_LIBEVENT +dist_bin_SCRIPTS = event_rpcgen.py +endif + +pkgconfigdir=$(libdir)/pkgconfig +LIBEVENT_PKGCONFIG=libevent.pc + +# These sources are conditionally added by configure.ac or conditionally +# included from other files. +PLATFORM_DEPENDENT_SRC = \ + arc4random.c \ + epoll_sub.c + +EXTRA_DIST = \ + ChangeLog-1.4 \ + ChangeLog-2.0 \ + Doxyfile \ + LICENSE \ + Makefile.nmake test/Makefile.nmake \ + autogen.sh \ + event_rpcgen.py \ + libevent.pc.in \ + make-event-config.sed \ + whatsnew-2.0.txt \ + whatsnew-2.1.txt \ + $(PLATFORM_DEPENDENT_SRC) + +LIBEVENT_LIBS_LA = libevent.la libevent_core.la libevent_extra.la +if PTHREADS +LIBEVENT_LIBS_LA += libevent_pthreads.la +LIBEVENT_PKGCONFIG += libevent_pthreads.pc +endif +if OPENSSL +LIBEVENT_LIBS_LA += libevent_openssl.la +LIBEVENT_PKGCONFIG += libevent_openssl.pc +endif + +if INSTALL_LIBEVENT +lib_LTLIBRARIES = $(LIBEVENT_LIBS_LA) +pkgconfig_DATA = $(LIBEVENT_PKGCONFIG) +else +noinst_LTLIBRARIES = $(LIBEVENT_LIBS_LA) +endif + +EXTRA_SOURCE= +noinst_HEADERS= +noinst_PROGRAMS= +EXTRA_PROGRAMS= +CLEANFILES= +DISTCLEANFILES= +BUILT_SOURCES = +include include/include.am +#include sample/include.am +include test/include.am + +if BUILD_WIN32 + +SYS_LIBS = -lws2_32 -lshell32 -ladvapi32 +SYS_SRC = win32select.c evthread_win32.c buffer_iocp.c event_iocp.c \ + bufferevent_async.c +SYS_INCLUDES = -IWIN32-Code -IWIN32-Code/nmake + +else + +SYS_LIBS = +SYS_SRC = +SYS_INCLUDES = + +endif + +if STRLCPY_IMPL +SYS_SRC += strlcpy.c +endif +if SELECT_BACKEND +SYS_SRC += select.c +endif +if POLL_BACKEND +SYS_SRC += poll.c +endif +if DEVPOLL_BACKEND +SYS_SRC += devpoll.c +endif +if KQUEUE_BACKEND +SYS_SRC += kqueue.c +endif +if EPOLL_BACKEND +SYS_SRC += epoll.c +endif +if EVPORT_BACKEND +SYS_SRC += evport.c +endif +if SIGNAL_SUPPORT +SYS_SRC += signal.c +endif + +BUILT_SOURCES += include/event2/event-config.h + +include/event2/event-config.h: config.h make-event-config.sed + $(AM_V_GEN)test -d include/event2 || $(MKDIR_P) include/event2 + $(AM_V_at)$(SED) -f $(srcdir)/make-event-config.sed < config.h > $@T + $(AM_V_at)mv -f $@T $@ + +CORE_SRC = \ + buffer.c \ + bufferevent.c \ + bufferevent_filter.c \ + bufferevent_pair.c \ + bufferevent_ratelim.c \ + bufferevent_sock.c \ + event.c \ + evmap.c \ + evthread.c \ + evutil.c \ + evutil_rand.c \ + evutil_time.c \ + listener.c \ + log.c \ + $(SYS_SRC) + +EXTRAS_SRC = \ + evdns.c \ + event_tagging.c \ + evrpc.c \ + http.c + +if BUILD_WITH_NO_UNDEFINED +NO_UNDEFINED = -no-undefined +MAYBE_CORE = libevent_core.la +else +NO_UNDEFINED = +MAYBE_CORE = +endif + +GENERIC_LDFLAGS = -version-info $(VERSION_INFO) $(RELEASE) $(NO_UNDEFINED) + +libevent_la_SOURCES = $(CORE_SRC) $(EXTRAS_SRC) +libevent_la_LIBADD = @LTLIBOBJS@ $(SYS_LIBS) +libevent_la_LDFLAGS = $(GENERIC_LDFLAGS) + +libevent_core_la_SOURCES = $(CORE_SRC) +libevent_core_la_LIBADD = @LTLIBOBJS@ $(SYS_LIBS) +libevent_core_la_LDFLAGS = $(GENERIC_LDFLAGS) + +if PTHREADS +libevent_pthreads_la_SOURCES = evthread_pthread.c +libevent_pthreads_la_LIBADD = $(MAYBE_CORE) +libevent_pthreads_la_LDFLAGS = $(GENERIC_LDFLAGS) +endif + +libevent_extra_la_SOURCES = $(EXTRAS_SRC) +libevent_extra_la_LIBADD = $(MAYBE_CORE) $(SYS_LIBS) +libevent_extra_la_LDFLAGS = $(GENERIC_LDFLAGS) + +if OPENSSL +libevent_openssl_la_SOURCES = bufferevent_openssl.c +libevent_openssl_la_LIBADD = $(MAYBE_CORE) $(OPENSSL_LIBS) +libevent_openssl_la_LDFLAGS = $(GENERIC_LDFLAGS) +libevent_openssl_la_CPPFLAGS = $(AM_CPPFLAGS) $(OPENSSL_INCS) +endif + +noinst_HEADERS += \ + WIN32-Code/nmake/evconfig-private.h \ + WIN32-Code/nmake/event2/event-config.h \ + WIN32-Code/tree.h \ + bufferevent-internal.h \ + changelist-internal.h \ + compat/sys/queue.h \ + defer-internal.h \ + epolltable-internal.h \ + evbuffer-internal.h \ + evconfig-private.h \ + event-internal.h \ + evmap-internal.h \ + evrpc-internal.h \ + evsignal-internal.h \ + evthread-internal.h \ + ht-internal.h \ + http-internal.h \ + iocp-internal.h \ + ipv6-internal.h \ + kqueue-internal.h \ + log-internal.h \ + minheap-internal.h \ + mm-internal.h \ + ratelim-internal.h \ + ratelim-internal.h \ + strlcpy-internal.h \ + time-internal.h \ + util-internal.h + +EVENT1_HDRS = \ + include/evdns.h \ + include/event.h \ + include/evhttp.h \ + include/evrpc.h \ + include/evutil.h + +if INSTALL_LIBEVENT +include_HEADERS = $(EVENT1_HDRS) +else +noinst_HEADERS += $(EVENT1_HDRS) +endif + +AM_CPPFLAGS = -I$(srcdir)/compat -I$(srcdir)/include -I./include $(SYS_INCLUDES) + +verify: check + +doxygen: FORCE + doxygen $(srcdir)/Doxyfile +FORCE: + +DISTCLEANFILES += *~ libevent.pc ./include/event2/event-config.h + diff --git a/contrib/ntp/sntp/libevent/Makefile.in b/contrib/ntp/sntp/libevent/Makefile.in new file mode 100644 index 000000000..81e121cf7 --- /dev/null +++ b/contrib/ntp/sntp/libevent/Makefile.in @@ -0,0 +1,2473 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +# Makefile.am for libevent +# Copyright 2000-2007 Niels Provos +# Copyright 2007-2012 Niels Provos and Nick Mathewson +# +# See LICENSE for copying information. + +# include/Makefile.am for libevent +# Copyright 2000-2007 Niels Provos +# Copyright 2007-2012 Niels Provos and Nick Mathewson +# +# See LICENSE for copying information. + +# test/Makefile.am for libevent +# Copyright 2000-2007 Niels Provos +# Copyright 2007-2012 Niels Provos and Nick Mathewson +# +# See LICENSE for copying information. + + + + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +@PTHREADS_TRUE@am__append_1 = libevent_pthreads.la +@PTHREADS_TRUE@am__append_2 = libevent_pthreads.pc +@OPENSSL_TRUE@am__append_3 = libevent_openssl.la +@OPENSSL_TRUE@am__append_4 = libevent_openssl.pc +noinst_PROGRAMS = $(am__EXEEXT_3) +EXTRA_PROGRAMS = $(am__EXEEXT_1) +@INSTALL_LIBEVENT_FALSE@am__append_5 = $(EVENT2_EXPORT) +@BUILD_REGRESS_TRUE@am__append_6 = $(TESTPROGRAMS) +@BUILD_REGRESS_TRUE@am__append_7 = test/regress +@BUILD_REGRESS_TRUE@am__append_8 = test/regress.gen.c test/regress.gen.h +@PTHREADS_TRUE@am__append_9 = libevent_pthreads.la +@BUILD_WIN32_TRUE@am__append_10 = test/regress_iocp.c +@OPENSSL_TRUE@am__append_11 = test/regress_ssl.c +@OPENSSL_TRUE@am__append_12 = $(OPENSSL_INCS) +@OPENSSL_TRUE@am__append_13 = libevent_openssl.la $(OPENSSL_LIBS) ${OPENSSL_LIBADD} +@STRLCPY_IMPL_TRUE@am__append_14 = strlcpy.c +@SELECT_BACKEND_TRUE@am__append_15 = select.c +@POLL_BACKEND_TRUE@am__append_16 = poll.c +@DEVPOLL_BACKEND_TRUE@am__append_17 = devpoll.c +@KQUEUE_BACKEND_TRUE@am__append_18 = kqueue.c +@EPOLL_BACKEND_TRUE@am__append_19 = epoll.c +@EVPORT_BACKEND_TRUE@am__append_20 = evport.c +@SIGNAL_SUPPORT_TRUE@am__append_21 = signal.c +@INSTALL_LIBEVENT_FALSE@am__append_22 = $(EVENT1_HDRS) +subdir = . +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/ac_backport_259_ssizet.m4 \ + $(top_srcdir)/m4/acx_pthread.m4 \ + $(top_srcdir)/m4/libevent_openssl.m4 \ + $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ + $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ + $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/ntp_pkg_config.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ + $(am__configure_deps) $(am__dist_bin_SCRIPTS_DIST) \ + $(am__include_HEADERS_DIST) $(am__include_event2_HEADERS_DIST) \ + $(am__noinst_HEADERS_DIST) $(am__DIST_COMMON) +am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ + configure.lineno config.status.lineno +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = config.h evconfig-private.h +CONFIG_CLEAN_FILES = libevent.pc libevent_openssl.pc \ + libevent_pthreads.pc +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" \ + "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(includedir)" \ + "$(DESTDIR)$(include_event2dir)" \ + "$(DESTDIR)$(include_event2dir)" +LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES) +am__DEPENDENCIES_1 = +libevent_la_DEPENDENCIES = @LTLIBOBJS@ $(am__DEPENDENCIES_1) +am__libevent_la_SOURCES_DIST = buffer.c bufferevent.c \ + bufferevent_filter.c bufferevent_pair.c bufferevent_ratelim.c \ + bufferevent_sock.c event.c evmap.c evthread.c evutil.c \ + evutil_rand.c evutil_time.c listener.c log.c strlcpy.c \ + select.c poll.c devpoll.c kqueue.c epoll.c evport.c signal.c \ + win32select.c evthread_win32.c buffer_iocp.c event_iocp.c \ + bufferevent_async.c evdns.c event_tagging.c evrpc.c http.c +@STRLCPY_IMPL_TRUE@am__objects_1 = strlcpy.lo +@SELECT_BACKEND_TRUE@am__objects_2 = select.lo +@POLL_BACKEND_TRUE@am__objects_3 = poll.lo +@DEVPOLL_BACKEND_TRUE@am__objects_4 = devpoll.lo +@KQUEUE_BACKEND_TRUE@am__objects_5 = kqueue.lo +@EPOLL_BACKEND_TRUE@am__objects_6 = epoll.lo +@EVPORT_BACKEND_TRUE@am__objects_7 = evport.lo +@SIGNAL_SUPPORT_TRUE@am__objects_8 = signal.lo +@BUILD_WIN32_FALSE@am__objects_9 = $(am__objects_1) $(am__objects_2) \ +@BUILD_WIN32_FALSE@ $(am__objects_3) $(am__objects_4) \ +@BUILD_WIN32_FALSE@ $(am__objects_5) $(am__objects_6) \ +@BUILD_WIN32_FALSE@ $(am__objects_7) $(am__objects_8) +@BUILD_WIN32_TRUE@am__objects_9 = win32select.lo evthread_win32.lo \ +@BUILD_WIN32_TRUE@ buffer_iocp.lo event_iocp.lo \ +@BUILD_WIN32_TRUE@ bufferevent_async.lo $(am__objects_1) \ +@BUILD_WIN32_TRUE@ $(am__objects_2) $(am__objects_3) \ +@BUILD_WIN32_TRUE@ $(am__objects_4) $(am__objects_5) \ +@BUILD_WIN32_TRUE@ $(am__objects_6) $(am__objects_7) \ +@BUILD_WIN32_TRUE@ $(am__objects_8) +am__objects_10 = buffer.lo bufferevent.lo bufferevent_filter.lo \ + bufferevent_pair.lo bufferevent_ratelim.lo bufferevent_sock.lo \ + event.lo evmap.lo evthread.lo evutil.lo evutil_rand.lo \ + evutil_time.lo listener.lo log.lo $(am__objects_9) +am__objects_11 = evdns.lo event_tagging.lo evrpc.lo http.lo +am_libevent_la_OBJECTS = $(am__objects_10) $(am__objects_11) +libevent_la_OBJECTS = $(am_libevent_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +libevent_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(libevent_la_LDFLAGS) $(LDFLAGS) -o $@ +@INSTALL_LIBEVENT_FALSE@am_libevent_la_rpath = +@INSTALL_LIBEVENT_TRUE@am_libevent_la_rpath = -rpath $(libdir) +libevent_core_la_DEPENDENCIES = @LTLIBOBJS@ $(am__DEPENDENCIES_1) +am__libevent_core_la_SOURCES_DIST = buffer.c bufferevent.c \ + bufferevent_filter.c bufferevent_pair.c bufferevent_ratelim.c \ + bufferevent_sock.c event.c evmap.c evthread.c evutil.c \ + evutil_rand.c evutil_time.c listener.c log.c strlcpy.c \ + select.c poll.c devpoll.c kqueue.c epoll.c evport.c signal.c \ + win32select.c evthread_win32.c buffer_iocp.c event_iocp.c \ + bufferevent_async.c +am_libevent_core_la_OBJECTS = $(am__objects_10) +libevent_core_la_OBJECTS = $(am_libevent_core_la_OBJECTS) +libevent_core_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(AM_CFLAGS) $(CFLAGS) $(libevent_core_la_LDFLAGS) $(LDFLAGS) \ + -o $@ +@INSTALL_LIBEVENT_FALSE@am_libevent_core_la_rpath = +@INSTALL_LIBEVENT_TRUE@am_libevent_core_la_rpath = -rpath $(libdir) +@BUILD_WITH_NO_UNDEFINED_TRUE@am__DEPENDENCIES_2 = libevent_core.la +libevent_extra_la_DEPENDENCIES = $(am__DEPENDENCIES_2) \ + $(am__DEPENDENCIES_1) +am_libevent_extra_la_OBJECTS = $(am__objects_11) +libevent_extra_la_OBJECTS = $(am_libevent_extra_la_OBJECTS) +libevent_extra_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(AM_CFLAGS) $(CFLAGS) $(libevent_extra_la_LDFLAGS) $(LDFLAGS) \ + -o $@ +@INSTALL_LIBEVENT_FALSE@am_libevent_extra_la_rpath = +@INSTALL_LIBEVENT_TRUE@am_libevent_extra_la_rpath = -rpath $(libdir) +@OPENSSL_TRUE@libevent_openssl_la_DEPENDENCIES = \ +@OPENSSL_TRUE@ $(am__DEPENDENCIES_2) $(am__DEPENDENCIES_1) +am__libevent_openssl_la_SOURCES_DIST = bufferevent_openssl.c +@OPENSSL_TRUE@am_libevent_openssl_la_OBJECTS = \ +@OPENSSL_TRUE@ libevent_openssl_la-bufferevent_openssl.lo +libevent_openssl_la_OBJECTS = $(am_libevent_openssl_la_OBJECTS) +libevent_openssl_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(AM_CFLAGS) $(CFLAGS) $(libevent_openssl_la_LDFLAGS) \ + $(LDFLAGS) -o $@ +@INSTALL_LIBEVENT_FALSE@@OPENSSL_TRUE@am_libevent_openssl_la_rpath = +@INSTALL_LIBEVENT_TRUE@@OPENSSL_TRUE@am_libevent_openssl_la_rpath = \ +@INSTALL_LIBEVENT_TRUE@@OPENSSL_TRUE@ -rpath $(libdir) +@PTHREADS_TRUE@libevent_pthreads_la_DEPENDENCIES = \ +@PTHREADS_TRUE@ $(am__DEPENDENCIES_2) +am__libevent_pthreads_la_SOURCES_DIST = evthread_pthread.c +@PTHREADS_TRUE@am_libevent_pthreads_la_OBJECTS = evthread_pthread.lo +libevent_pthreads_la_OBJECTS = $(am_libevent_pthreads_la_OBJECTS) +libevent_pthreads_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(AM_CFLAGS) $(CFLAGS) $(libevent_pthreads_la_LDFLAGS) \ + $(LDFLAGS) -o $@ +@INSTALL_LIBEVENT_FALSE@@PTHREADS_TRUE@am_libevent_pthreads_la_rpath = +@INSTALL_LIBEVENT_TRUE@@PTHREADS_TRUE@am_libevent_pthreads_la_rpath = \ +@INSTALL_LIBEVENT_TRUE@@PTHREADS_TRUE@ -rpath $(libdir) +@BUILD_REGRESS_TRUE@am__EXEEXT_1 = test/regress$(EXEEXT) +am__EXEEXT_2 = test/bench$(EXEEXT) test/bench_cascade$(EXEEXT) \ + test/bench_http$(EXEEXT) test/bench_httpclient$(EXEEXT) \ + test/test-changelist$(EXEEXT) test/test-dumpevents$(EXEEXT) \ + test/test-eof$(EXEEXT) test/test-closed$(EXEEXT) \ + test/test-fdleak$(EXEEXT) test/test-init$(EXEEXT) \ + test/test-ratelim$(EXEEXT) test/test-time$(EXEEXT) \ + test/test-weof$(EXEEXT) test/regress$(EXEEXT) +@BUILD_REGRESS_TRUE@am__EXEEXT_3 = $(am__EXEEXT_2) +PROGRAMS = $(noinst_PROGRAMS) +am__dirstamp = $(am__leading_dot)dirstamp +am_test_bench_OBJECTS = test/bench.$(OBJEXT) +test_bench_OBJECTS = $(am_test_bench_OBJECTS) +test_bench_DEPENDENCIES = $(am__DEPENDENCIES_1) libevent.la +am_test_bench_cascade_OBJECTS = test/bench_cascade.$(OBJEXT) +test_bench_cascade_OBJECTS = $(am_test_bench_cascade_OBJECTS) +test_bench_cascade_DEPENDENCIES = $(am__DEPENDENCIES_1) libevent.la +am_test_bench_http_OBJECTS = test/bench_http.$(OBJEXT) +test_bench_http_OBJECTS = $(am_test_bench_http_OBJECTS) +test_bench_http_DEPENDENCIES = $(am__DEPENDENCIES_1) libevent.la +am_test_bench_httpclient_OBJECTS = test/bench_httpclient.$(OBJEXT) +test_bench_httpclient_OBJECTS = $(am_test_bench_httpclient_OBJECTS) +test_bench_httpclient_DEPENDENCIES = $(am__DEPENDENCIES_1) \ + libevent_core.la +am__test_regress_SOURCES_DIST = test/regress.c test/regress.gen.c \ + test/regress.gen.h test/regress_buffer.c \ + test/regress_bufferevent.c test/regress_dns.c \ + test/regress_et.c test/regress_finalize.c test/regress_http.c \ + test/regress_listener.c test/regress_main.c \ + test/regress_minheap.c test/regress_rpc.c \ + test/regress_testutils.c test/regress_testutils.h \ + test/regress_util.c test/tinytest.c test/regress_thread.c \ + test/regress_zlib.c test/regress_iocp.c test/regress_ssl.c +@BUILD_WIN32_FALSE@@PTHREADS_TRUE@am__objects_12 = test/test_regress-regress_thread.$(OBJEXT) +@BUILD_WIN32_TRUE@am__objects_12 = \ +@BUILD_WIN32_TRUE@ test/test_regress-regress_thread.$(OBJEXT) +@ZLIB_REGRESS_TRUE@am__objects_13 = \ +@ZLIB_REGRESS_TRUE@ test/test_regress-regress_zlib.$(OBJEXT) +@BUILD_WIN32_TRUE@am__objects_14 = \ +@BUILD_WIN32_TRUE@ test/test_regress-regress_iocp.$(OBJEXT) +@OPENSSL_TRUE@am__objects_15 = \ +@OPENSSL_TRUE@ test/test_regress-regress_ssl.$(OBJEXT) +am_test_regress_OBJECTS = test/test_regress-regress.$(OBJEXT) \ + test/test_regress-regress.gen.$(OBJEXT) \ + test/test_regress-regress_buffer.$(OBJEXT) \ + test/test_regress-regress_bufferevent.$(OBJEXT) \ + test/test_regress-regress_dns.$(OBJEXT) \ + test/test_regress-regress_et.$(OBJEXT) \ + test/test_regress-regress_finalize.$(OBJEXT) \ + test/test_regress-regress_http.$(OBJEXT) \ + test/test_regress-regress_listener.$(OBJEXT) \ + test/test_regress-regress_main.$(OBJEXT) \ + test/test_regress-regress_minheap.$(OBJEXT) \ + test/test_regress-regress_rpc.$(OBJEXT) \ + test/test_regress-regress_testutils.$(OBJEXT) \ + test/test_regress-regress_util.$(OBJEXT) \ + test/test_regress-tinytest.$(OBJEXT) $(am__objects_12) \ + $(am__objects_13) $(am__objects_14) $(am__objects_15) +test_regress_OBJECTS = $(am_test_regress_OBJECTS) +am__DEPENDENCIES_3 = $(am__append_9) +@OPENSSL_TRUE@am__DEPENDENCIES_4 = libevent_openssl.la \ +@OPENSSL_TRUE@ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +test_regress_DEPENDENCIES = $(am__DEPENDENCIES_1) libevent.la \ + $(am__DEPENDENCIES_3) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_4) +test_regress_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(test_regress_LDFLAGS) $(LDFLAGS) -o $@ +am_test_test_changelist_OBJECTS = test/test-changelist.$(OBJEXT) +test_test_changelist_OBJECTS = $(am_test_test_changelist_OBJECTS) +test_test_changelist_DEPENDENCIES = libevent_core.la +am_test_test_closed_OBJECTS = test/test-closed.$(OBJEXT) +test_test_closed_OBJECTS = $(am_test_test_closed_OBJECTS) +test_test_closed_DEPENDENCIES = libevent_core.la +am_test_test_dumpevents_OBJECTS = test/test-dumpevents.$(OBJEXT) +test_test_dumpevents_OBJECTS = $(am_test_test_dumpevents_OBJECTS) +test_test_dumpevents_DEPENDENCIES = libevent_core.la +am_test_test_eof_OBJECTS = test/test-eof.$(OBJEXT) +test_test_eof_OBJECTS = $(am_test_test_eof_OBJECTS) +test_test_eof_DEPENDENCIES = libevent_core.la +am_test_test_fdleak_OBJECTS = test/test-fdleak.$(OBJEXT) +test_test_fdleak_OBJECTS = $(am_test_test_fdleak_OBJECTS) +test_test_fdleak_DEPENDENCIES = libevent_core.la +am_test_test_init_OBJECTS = test/test-init.$(OBJEXT) +test_test_init_OBJECTS = $(am_test_test_init_OBJECTS) +test_test_init_DEPENDENCIES = libevent_core.la +am_test_test_ratelim_OBJECTS = test/test-ratelim.$(OBJEXT) +test_test_ratelim_OBJECTS = $(am_test_test_ratelim_OBJECTS) +test_test_ratelim_DEPENDENCIES = libevent_core.la +am_test_test_time_OBJECTS = test/test-time.$(OBJEXT) +test_test_time_OBJECTS = $(am_test_test_time_OBJECTS) +test_test_time_DEPENDENCIES = libevent_core.la +am_test_test_weof_OBJECTS = test/test-weof.$(OBJEXT) +test_test_weof_OBJECTS = $(am_test_test_weof_OBJECTS) +test_test_weof_DEPENDENCIES = libevent_core.la +am__dist_bin_SCRIPTS_DIST = event_rpcgen.py +SCRIPTS = $(dist_bin_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ +depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libevent_la_SOURCES) $(libevent_core_la_SOURCES) \ + $(libevent_extra_la_SOURCES) $(libevent_openssl_la_SOURCES) \ + $(libevent_pthreads_la_SOURCES) $(test_bench_SOURCES) \ + $(test_bench_cascade_SOURCES) $(test_bench_http_SOURCES) \ + $(test_bench_httpclient_SOURCES) $(test_regress_SOURCES) \ + $(test_test_changelist_SOURCES) $(test_test_closed_SOURCES) \ + $(test_test_dumpevents_SOURCES) $(test_test_eof_SOURCES) \ + $(test_test_fdleak_SOURCES) $(test_test_init_SOURCES) \ + $(test_test_ratelim_SOURCES) $(test_test_time_SOURCES) \ + $(test_test_weof_SOURCES) +DIST_SOURCES = $(am__libevent_la_SOURCES_DIST) \ + $(am__libevent_core_la_SOURCES_DIST) \ + $(libevent_extra_la_SOURCES) \ + $(am__libevent_openssl_la_SOURCES_DIST) \ + $(am__libevent_pthreads_la_SOURCES_DIST) $(test_bench_SOURCES) \ + $(test_bench_cascade_SOURCES) $(test_bench_http_SOURCES) \ + $(test_bench_httpclient_SOURCES) \ + $(am__test_regress_SOURCES_DIST) \ + $(test_test_changelist_SOURCES) $(test_test_closed_SOURCES) \ + $(test_test_dumpevents_SOURCES) $(test_test_eof_SOURCES) \ + $(test_test_fdleak_SOURCES) $(test_test_init_SOURCES) \ + $(test_test_ratelim_SOURCES) $(test_test_time_SOURCES) \ + $(test_test_weof_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +DATA = $(pkgconfig_DATA) +am__include_HEADERS_DIST = include/evdns.h include/event.h \ + include/evhttp.h include/evrpc.h include/evutil.h +am__include_event2_HEADERS_DIST = include/event2/buffer.h \ + include/event2/buffer_compat.h include/event2/bufferevent.h \ + include/event2/bufferevent_compat.h \ + include/event2/bufferevent_ssl.h \ + include/event2/bufferevent_struct.h include/event2/dns.h \ + include/event2/dns_compat.h include/event2/dns_struct.h \ + include/event2/event.h include/event2/event_compat.h \ + include/event2/event_struct.h include/event2/http.h \ + include/event2/http_compat.h include/event2/http_struct.h \ + include/event2/keyvalq_struct.h include/event2/listener.h \ + include/event2/rpc.h include/event2/rpc_compat.h \ + include/event2/rpc_struct.h include/event2/tag.h \ + include/event2/tag_compat.h include/event2/thread.h \ + include/event2/util.h include/event2/visibility.h +am__noinst_HEADERS_DIST = include/event2/buffer.h \ + include/event2/buffer_compat.h include/event2/bufferevent.h \ + include/event2/bufferevent_compat.h \ + include/event2/bufferevent_ssl.h \ + include/event2/bufferevent_struct.h include/event2/dns.h \ + include/event2/dns_compat.h include/event2/dns_struct.h \ + include/event2/event.h include/event2/event_compat.h \ + include/event2/event_struct.h include/event2/http.h \ + include/event2/http_compat.h include/event2/http_struct.h \ + include/event2/keyvalq_struct.h include/event2/listener.h \ + include/event2/rpc.h include/event2/rpc_compat.h \ + include/event2/rpc_struct.h include/event2/tag.h \ + include/event2/tag_compat.h include/event2/thread.h \ + include/event2/util.h include/event2/visibility.h \ + test/regress.h test/regress_thread.h test/tinytest.h \ + test/tinytest_local.h test/tinytest_macros.h \ + WIN32-Code/nmake/evconfig-private.h \ + WIN32-Code/nmake/event2/event-config.h WIN32-Code/tree.h \ + bufferevent-internal.h changelist-internal.h \ + compat/sys/queue.h defer-internal.h epolltable-internal.h \ + evbuffer-internal.h evconfig-private.h event-internal.h \ + evmap-internal.h evrpc-internal.h evsignal-internal.h \ + evthread-internal.h ht-internal.h http-internal.h \ + iocp-internal.h ipv6-internal.h kqueue-internal.h \ + log-internal.h minheap-internal.h mm-internal.h \ + ratelim-internal.h strlcpy-internal.h time-internal.h \ + util-internal.h include/evdns.h include/event.h \ + include/evhttp.h include/evrpc.h include/evutil.h +HEADERS = $(include_HEADERS) $(include_event2_HEADERS) \ + $(nodist_include_event2_HEADERS) $(nodist_noinst_HEADERS) \ + $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ + $(LISP)config.h.in evconfig-private.h.in +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +CSCOPE = cscope +AM_RECURSIVE_TARGETS = cscope check recheck +am__tty_colors_dummy = \ + mgn= red= grn= lgn= blu= brg= std=; \ + am__color_tests=no +am__tty_colors = { \ + $(am__tty_colors_dummy); \ + if test "X$(AM_COLOR_TESTS)" = Xno; then \ + am__color_tests=no; \ + elif test "X$(AM_COLOR_TESTS)" = Xalways; then \ + am__color_tests=yes; \ + elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \ + am__color_tests=yes; \ + fi; \ + if test $$am__color_tests = yes; then \ + red=''; \ + grn=''; \ + lgn=''; \ + blu=''; \ + mgn=''; \ + brg=''; \ + std=''; \ + fi; \ +} +am__recheck_rx = ^[ ]*:recheck:[ ]* +am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* +am__copy_in_global_log_rx = ^[ ]*:copy-in-global-log:[ ]* +# A command that, given a newline-separated list of test names on the +# standard input, print the name of the tests that are to be re-run +# upon "make recheck". +am__list_recheck_tests = $(AWK) '{ \ + recheck = 1; \ + while ((rc = (getline line < ($$0 ".trs"))) != 0) \ + { \ + if (rc < 0) \ + { \ + if ((getline line2 < ($$0 ".log")) < 0) \ + recheck = 0; \ + break; \ + } \ + else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \ + { \ + recheck = 0; \ + break; \ + } \ + else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \ + { \ + break; \ + } \ + }; \ + if (recheck) \ + print $$0; \ + close ($$0 ".trs"); \ + close ($$0 ".log"); \ +}' +# A command that, given a newline-separated list of test names on the +# standard input, create the global log from their .trs and .log files. +am__create_global_log = $(AWK) ' \ +function fatal(msg) \ +{ \ + print "fatal: making $@: " msg | "cat >&2"; \ + exit 1; \ +} \ +function rst_section(header) \ +{ \ + print header; \ + len = length(header); \ + for (i = 1; i <= len; i = i + 1) \ + printf "="; \ + printf "\n\n"; \ +} \ +{ \ + copy_in_global_log = 1; \ + global_test_result = "RUN"; \ + while ((rc = (getline line < ($$0 ".trs"))) != 0) \ + { \ + if (rc < 0) \ + fatal("failed to read from " $$0 ".trs"); \ + if (line ~ /$(am__global_test_result_rx)/) \ + { \ + sub("$(am__global_test_result_rx)", "", line); \ + sub("[ ]*$$", "", line); \ + global_test_result = line; \ + } \ + else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \ + copy_in_global_log = 0; \ + }; \ + if (copy_in_global_log) \ + { \ + rst_section(global_test_result ": " $$0); \ + while ((rc = (getline line < ($$0 ".log"))) != 0) \ + { \ + if (rc < 0) \ + fatal("failed to read from " $$0 ".log"); \ + print line; \ + }; \ + printf "\n"; \ + }; \ + close ($$0 ".trs"); \ + close ($$0 ".log"); \ +}' +# Restructured Text title. +am__rst_title = { sed 's/.*/ & /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; } +# Solaris 10 'make', and several other traditional 'make' implementations, +# pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it +# by disabling -e (using the XSI extension "set +e") if it's set. +am__sh_e_setup = case $$- in *e*) set +e;; esac +# Default flags passed to test drivers. +am__common_driver_flags = \ + --color-tests "$$am__color_tests" \ + --enable-hard-errors "$$am__enable_hard_errors" \ + --expect-failure "$$am__expect_failure" +# To be inserted before the command running the test. Creates the +# directory for the log if needed. Stores in $dir the directory +# containing $f, in $tst the test, in $log the log. Executes the +# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and +# passes TESTS_ENVIRONMENT. Set up options for the wrapper that +# will run the test scripts (or their associated LOG_COMPILER, if +# thy have one). +am__check_pre = \ +$(am__sh_e_setup); \ +$(am__vpath_adj_setup) $(am__vpath_adj) \ +$(am__tty_colors); \ +srcdir=$(srcdir); export srcdir; \ +case "$@" in \ + */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;; \ + *) am__odir=.;; \ +esac; \ +test "x$$am__odir" = x"." || test -d "$$am__odir" \ + || $(MKDIR_P) "$$am__odir" || exit $$?; \ +if test -f "./$$f"; then dir=./; \ +elif test -f "$$f"; then dir=; \ +else dir="$(srcdir)/"; fi; \ +tst=$$dir$$f; log='$@'; \ +if test -n '$(DISABLE_HARD_ERRORS)'; then \ + am__enable_hard_errors=no; \ +else \ + am__enable_hard_errors=yes; \ +fi; \ +case " $(XFAIL_TESTS) " in \ + *[\ \ ]$$f[\ \ ]* | *[\ \ ]$$dir$$f[\ \ ]*) \ + am__expect_failure=yes;; \ + *) \ + am__expect_failure=no;; \ +esac; \ +$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT) +# A shell command to get the names of the tests scripts with any registered +# extension removed (i.e., equivalently, the names of the test logs, with +# the '.log' extension removed). The result is saved in the shell variable +# '$bases'. This honors runtime overriding of TESTS and TEST_LOGS. Sadly, +# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)", +# since that might cause problem with VPATH rewrites for suffix-less tests. +# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'. +am__set_TESTS_bases = \ + bases='$(TEST_LOGS)'; \ + bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ + bases=`echo $$bases` +RECHECK_LOGS = $(TEST_LOGS) +TEST_SUITE_LOG = test-suite.log +TEST_EXTENSIONS = @EXEEXT@ .test +LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver +LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS) +am__set_b = \ + case '$@' in \ + */*) \ + case '$*' in \ + */*) b='$*';; \ + *) b=`echo '$@' | sed 's/\.log$$//'`; \ + esac;; \ + *) \ + b='$*';; \ + esac +am__test_logs1 = $(TESTS:=.log) +am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log) +TEST_LOGS = $(am__test_logs2:.test.log=.log) +TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver +TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \ + $(TEST_LOG_FLAGS) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \ + $(srcdir)/evconfig-private.h.in $(srcdir)/include/include.am \ + $(srcdir)/libevent.pc.in $(srcdir)/libevent_openssl.pc.in \ + $(srcdir)/libevent_pthreads.pc.in $(srcdir)/test/include.am \ + $(top_srcdir)/build-aux/compile \ + $(top_srcdir)/build-aux/config.guess \ + $(top_srcdir)/build-aux/config.sub \ + $(top_srcdir)/build-aux/depcomp \ + $(top_srcdir)/build-aux/install-sh \ + $(top_srcdir)/build-aux/ltmain.sh \ + $(top_srcdir)/build-aux/missing \ + $(top_srcdir)/build-aux/test-driver ChangeLog build-aux/ar-lib \ + build-aux/compile build-aux/config.guess build-aux/config.sub \ + build-aux/depcomp build-aux/install-sh build-aux/ltmain.sh \ + build-aux/missing build-aux/ylwrap epoll_sub.c +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +distdir = $(PACKAGE)-$(VERSION) +top_distdir = $(distdir) +am__remove_distdir = \ + if test -d "$(distdir)"; then \ + find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ + && rm -rf "$(distdir)" \ + || { sleep 5 && rm -rf "$(distdir)"; }; \ + else :; fi +am__post_remove_distdir = $(am__remove_distdir) +DIST_ARCHIVES = $(distdir).tar.gz +GZIP_ENV = --best +DIST_TARGETS = dist-gzip +distuninstallcheck_listfiles = find . -type f -print +am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ + | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' +distcleancheck_listfiles = find . -type f -print +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EV_LIB_GDI = @EV_LIB_GDI@ +EV_LIB_WS32 = @EV_LIB_WS32@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBEVENT_GC_SECTIONS = @LIBEVENT_GC_SECTIONS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIBTOOL_DEPS = @LIBTOOL_DEPS@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OPENSSL_INCS = @OPENSSL_INCS@ +OPENSSL_LIBADD = @OPENSSL_LIBADD@ +OPENSSL_LIBS = @OPENSSL_LIBS@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PTHREAD_CC = @PTHREAD_CC@ +PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_LIBS = @PTHREAD_LIBS@ $(am__append_9) +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +ZLIB_LIBS = @ZLIB_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +acx_pthread_config = @acx_pthread_config@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ + +# 'foreign' means that we're not enforcing GNU package rules strictly. +# '1.9' means that we need automake 1.9 or later (and we do). +AUTOMAKE_OPTIONS = foreign 1.9 subdir-objects +ACLOCAL_AMFLAGS = -I m4 + +# This is the "Release" of the Libevent ABI. It takes precedence over +# the VERSION_INFO, so that two versions of Libevent with the same +# "Release" are never binary-compatible. +# +# This number incremented once for the 2.0 release candidate, and +# will increment for each series until we revise our interfaces enough +# that we can seriously expect ABI compatibility between series. +# +RELEASE = -release 2.1 + +# This is the version info for the libevent binary API. It has three +# numbers: +# Current -- the number of the binary API that we're implementing +# Revision -- which iteration of the implementation of the binary +# API are we supplying? +# Age -- How many previous binary API versions do we also +# support? +# +# To increment a VERSION_INFO (current:revision:age): +# If the ABI didn't change: +# Return (current:revision+1:age) +# If the ABI changed, but it's backward-compatible: +# Return (current+1:0:age+1) +# If the ABI changed and it isn't backward-compatible: +# Return (current+1:0:0) +# +# Once an RC is out, DO NOT MAKE ANY ABI-BREAKING CHANGES IN THAT SERIES +# UNLESS YOU REALLY REALLY HAVE TO. +VERSION_INFO = 5:0:0 + +# History: RELEASE VERSION_INFO +# 2.0.1-alpha -- 2.0 1:0:0 +# 2.0.2-alpha -- 2:0:0 +# 2.0.3-alpha -- 2:0:0 (should have incremented; didn't.) +# 2.0.4-alpha -- 3:0:0 +# 2.0.5-beta -- 4:0:0 +# 2.0.6-rc -- 2.0 2:0:0 +# 2.0.7-rc -- 2.0 3:0:1 +# 2.0.8-rc -- 2.0 4:0:2 +# 2.0.9-rc -- 2.0 5:0:0 (ABI changed slightly) +# 2.0.10-stable-- 2.0 5:1:0 (No ABI change) +# 2.0.11-stable-- 2.0 6:0:1 (ABI changed, backward-compatible) +# 2.0.12-stable-- 2.0 6:1:1 (No ABI change) +# 2.0.13-stable-- 2.0 6:2:1 (No ABI change) +# 2.0.14-stable-- 2.0 6:3:1 (No ABI change) +# 2.0.15-stable-- 2.0 6:3:1 (Forgot to update :( ) +# 2.0.16-stable-- 2.0 6:4:1 (No ABI change) +# 2.0.17-stable-- 2.0 6:5:1 (No ABI change) +# 2.0.18-stable-- 2.0 6:6:1 (No ABI change) +# 2.0.19-stable-- 2.0 6:7:1 (No ABI change) +# 2.0.20-stable-- 2.0 6:8:1 (No ABI change) +# 2.0.21-stable-- 2.0 6:9:1 (No ABI change) +# +# For Libevent 2.1: +# 2.1.1-alpha -- 2.1 1:0:0 +# 2.1.2-alpha -- 2.1 1:0:0 (should have been 2:0:1) +# 2.1.3-alpha -- 2.1 3:0:0 (ABI changed slightly) +# 2.1.4-alpha -- 2.1 4:0:0 (ABI changed slightly) +# 2.1.5-beta -- 2.1 5:0:0 (ABI changed slightly) + +# ABI version history for this package effectively restarts every time +# we change RELEASE. Version 1.4.x had RELEASE of 1.4. +# +# Ideally, we would not be using RELEASE at all; instead we could just +# use the VERSION_INFO field to label our backward-incompatible ABI +# changes, and those would be few and far between. Unfortunately, +# Libevent still exposes far too many volatile structures in its +# headers, so we pretty much have to assume that most development +# series will break ABI compatibility. For now, it's simplest just to +# keep incrementing the RELEASE between series and resetting VERSION_INFO. +# +# Eventually, when we get to the point where the structures in the +# headers are all non-changing (or not there at all!), we can shift to +# a more normal worldview where backward-incompatible ABI changes are +# nice and rare. For the next couple of years, though, 'struct event' +# is user-visible, and so we can pretty much guarantee that release +# series won't be binary-compatible. +@INSTALL_LIBEVENT_TRUE@dist_bin_SCRIPTS = event_rpcgen.py +pkgconfigdir = $(libdir)/pkgconfig +LIBEVENT_PKGCONFIG = libevent.pc $(am__append_2) $(am__append_4) + +# These sources are conditionally added by configure.ac or conditionally +# included from other files. +PLATFORM_DEPENDENT_SRC = \ + arc4random.c \ + epoll_sub.c + +EXTRA_DIST = ChangeLog-1.4 ChangeLog-2.0 Doxyfile LICENSE \ + Makefile.nmake test/Makefile.nmake autogen.sh event_rpcgen.py \ + libevent.pc.in make-event-config.sed whatsnew-2.0.txt \ + whatsnew-2.1.txt $(PLATFORM_DEPENDENT_SRC) \ + test/check-dumpevents.py test/regress.gen.c test/regress.gen.h \ + test/regress.rpc test/rpcgen_wrapper.sh test/test.sh +LIBEVENT_LIBS_LA = libevent.la libevent_core.la libevent_extra.la \ + $(am__append_1) $(am__append_3) +@INSTALL_LIBEVENT_TRUE@lib_LTLIBRARIES = $(LIBEVENT_LIBS_LA) +@INSTALL_LIBEVENT_TRUE@pkgconfig_DATA = $(LIBEVENT_PKGCONFIG) +@INSTALL_LIBEVENT_FALSE@noinst_LTLIBRARIES = $(LIBEVENT_LIBS_LA) +EXTRA_SOURCE = +noinst_HEADERS = $(am__append_5) test/regress.h test/regress_thread.h \ + test/tinytest.h test/tinytest_local.h test/tinytest_macros.h \ + WIN32-Code/nmake/evconfig-private.h \ + WIN32-Code/nmake/event2/event-config.h WIN32-Code/tree.h \ + bufferevent-internal.h changelist-internal.h \ + compat/sys/queue.h defer-internal.h epolltable-internal.h \ + evbuffer-internal.h evconfig-private.h event-internal.h \ + evmap-internal.h evrpc-internal.h evsignal-internal.h \ + evthread-internal.h ht-internal.h http-internal.h \ + iocp-internal.h ipv6-internal.h kqueue-internal.h \ + log-internal.h minheap-internal.h mm-internal.h \ + ratelim-internal.h ratelim-internal.h strlcpy-internal.h \ + time-internal.h util-internal.h $(am__append_22) +CLEANFILES = test/rpcgen-attempted +DISTCLEANFILES = test/test-script.sh test/regress.gen.c \ + test/regress.gen.h *~ libevent.pc \ + ./include/event2/event-config.h +BUILT_SOURCES = $(am__append_8) include/event2/event-config.h +include_event2dir = $(includedir)/event2 +EVENT2_EXPORT = \ + include/event2/buffer.h \ + include/event2/buffer_compat.h \ + include/event2/bufferevent.h \ + include/event2/bufferevent_compat.h \ + include/event2/bufferevent_ssl.h \ + include/event2/bufferevent_struct.h \ + include/event2/dns.h \ + include/event2/dns_compat.h \ + include/event2/dns_struct.h \ + include/event2/event.h \ + include/event2/event_compat.h \ + include/event2/event_struct.h \ + include/event2/http.h \ + include/event2/http_compat.h \ + include/event2/http_struct.h \ + include/event2/keyvalq_struct.h \ + include/event2/listener.h \ + include/event2/rpc.h \ + include/event2/rpc_compat.h \ + include/event2/rpc_struct.h \ + include/event2/tag.h \ + include/event2/tag_compat.h \ + include/event2/thread.h \ + include/event2/util.h \ + include/event2/visibility.h + +@INSTALL_LIBEVENT_TRUE@include_event2_HEADERS = $(EVENT2_EXPORT) +@INSTALL_LIBEVENT_TRUE@nodist_include_event2_HEADERS = include/event2/event-config.h +@INSTALL_LIBEVENT_FALSE@nodist_noinst_HEADERS = include/event2/event-config.h +regress_CPPFLAGS = -DTINYTEST_LOCAL +TESTPROGRAMS = \ + test/bench \ + test/bench_cascade \ + test/bench_http \ + test/bench_httpclient \ + test/test-changelist \ + test/test-dumpevents \ + test/test-eof \ + test/test-closed \ + test/test-fdleak \ + test/test-init \ + test/test-ratelim \ + test/test-time \ + test/test-weof \ + test/regress + + +# We need to copy this file, since automake doesn't want us to use top_srcdir +# in TESTS. +TESTS = test/test-script.sh +test_test_init_SOURCES = test/test-init.c +test_test_init_LDADD = libevent_core.la +test_test_dumpevents_SOURCES = test/test-dumpevents.c +test_test_dumpevents_LDADD = libevent_core.la +test_test_eof_SOURCES = test/test-eof.c +test_test_eof_LDADD = libevent_core.la +test_test_closed_SOURCES = test/test-closed.c +test_test_closed_LDADD = libevent_core.la +test_test_changelist_SOURCES = test/test-changelist.c +test_test_changelist_LDADD = libevent_core.la +test_test_weof_SOURCES = test/test-weof.c +test_test_weof_LDADD = libevent_core.la +test_test_time_SOURCES = test/test-time.c +test_test_time_LDADD = libevent_core.la +test_test_ratelim_SOURCES = test/test-ratelim.c +test_test_ratelim_LDADD = libevent_core.la -lm +test_test_fdleak_SOURCES = test/test-fdleak.c +test_test_fdleak_LDADD = libevent_core.la +test_regress_SOURCES = test/regress.c test/regress.gen.c \ + test/regress.gen.h test/regress_buffer.c \ + test/regress_bufferevent.c test/regress_dns.c \ + test/regress_et.c test/regress_finalize.c test/regress_http.c \ + test/regress_listener.c test/regress_main.c \ + test/regress_minheap.c test/regress_rpc.c \ + test/regress_testutils.c test/regress_testutils.h \ + test/regress_util.c test/tinytest.c $(regress_thread_SOURCES) \ + $(regress_zlib_SOURCES) $(am__append_10) $(am__append_11) +@BUILD_WIN32_TRUE@regress_thread_SOURCES = test/regress_thread.c +@PTHREADS_TRUE@regress_thread_SOURCES = test/regress_thread.c +@ZLIB_REGRESS_TRUE@regress_zlib_SOURCES = test/regress_zlib.c +test_regress_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la \ + $(PTHREAD_LIBS) $(ZLIB_LIBS) $(am__append_13) +test_regress_CPPFLAGS = $(AM_CPPFLAGS) $(PTHREAD_CFLAGS) \ + $(ZLIB_CFLAGS) -Itest $(am__append_12) +test_regress_LDFLAGS = $(PTHREAD_CFLAGS) +test_bench_SOURCES = test/bench.c +test_bench_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la +test_bench_cascade_SOURCES = test/bench_cascade.c +test_bench_cascade_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la +test_bench_http_SOURCES = test/bench_http.c +test_bench_http_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la +test_bench_httpclient_SOURCES = test/bench_httpclient.c +test_bench_httpclient_LDADD = $(LIBEVENT_GC_SECTIONS) libevent_core.la +@BUILD_WIN32_FALSE@SYS_LIBS = +#include sample/include.am +@BUILD_WIN32_TRUE@SYS_LIBS = -lws2_32 -lshell32 -ladvapi32 +@BUILD_WIN32_FALSE@SYS_SRC = $(am__append_14) $(am__append_15) \ +@BUILD_WIN32_FALSE@ $(am__append_16) $(am__append_17) \ +@BUILD_WIN32_FALSE@ $(am__append_18) $(am__append_19) \ +@BUILD_WIN32_FALSE@ $(am__append_20) $(am__append_21) +@BUILD_WIN32_TRUE@SYS_SRC = win32select.c evthread_win32.c \ +@BUILD_WIN32_TRUE@ buffer_iocp.c event_iocp.c \ +@BUILD_WIN32_TRUE@ bufferevent_async.c $(am__append_14) \ +@BUILD_WIN32_TRUE@ $(am__append_15) $(am__append_16) \ +@BUILD_WIN32_TRUE@ $(am__append_17) $(am__append_18) \ +@BUILD_WIN32_TRUE@ $(am__append_19) $(am__append_20) \ +@BUILD_WIN32_TRUE@ $(am__append_21) +@BUILD_WIN32_FALSE@SYS_INCLUDES = +@BUILD_WIN32_TRUE@SYS_INCLUDES = -IWIN32-Code -IWIN32-Code/nmake +CORE_SRC = \ + buffer.c \ + bufferevent.c \ + bufferevent_filter.c \ + bufferevent_pair.c \ + bufferevent_ratelim.c \ + bufferevent_sock.c \ + event.c \ + evmap.c \ + evthread.c \ + evutil.c \ + evutil_rand.c \ + evutil_time.c \ + listener.c \ + log.c \ + $(SYS_SRC) + +EXTRAS_SRC = \ + evdns.c \ + event_tagging.c \ + evrpc.c \ + http.c + +@BUILD_WITH_NO_UNDEFINED_FALSE@NO_UNDEFINED = +@BUILD_WITH_NO_UNDEFINED_TRUE@NO_UNDEFINED = -no-undefined +@BUILD_WITH_NO_UNDEFINED_FALSE@MAYBE_CORE = +@BUILD_WITH_NO_UNDEFINED_TRUE@MAYBE_CORE = libevent_core.la +GENERIC_LDFLAGS = -version-info $(VERSION_INFO) $(RELEASE) $(NO_UNDEFINED) +libevent_la_SOURCES = $(CORE_SRC) $(EXTRAS_SRC) +libevent_la_LIBADD = @LTLIBOBJS@ $(SYS_LIBS) +libevent_la_LDFLAGS = $(GENERIC_LDFLAGS) +libevent_core_la_SOURCES = $(CORE_SRC) +libevent_core_la_LIBADD = @LTLIBOBJS@ $(SYS_LIBS) +libevent_core_la_LDFLAGS = $(GENERIC_LDFLAGS) +@PTHREADS_TRUE@libevent_pthreads_la_SOURCES = evthread_pthread.c +@PTHREADS_TRUE@libevent_pthreads_la_LIBADD = $(MAYBE_CORE) +@PTHREADS_TRUE@libevent_pthreads_la_LDFLAGS = $(GENERIC_LDFLAGS) +libevent_extra_la_SOURCES = $(EXTRAS_SRC) +libevent_extra_la_LIBADD = $(MAYBE_CORE) $(SYS_LIBS) +libevent_extra_la_LDFLAGS = $(GENERIC_LDFLAGS) +@OPENSSL_TRUE@libevent_openssl_la_SOURCES = bufferevent_openssl.c +@OPENSSL_TRUE@libevent_openssl_la_LIBADD = $(MAYBE_CORE) $(OPENSSL_LIBS) +@OPENSSL_TRUE@libevent_openssl_la_LDFLAGS = $(GENERIC_LDFLAGS) +@OPENSSL_TRUE@libevent_openssl_la_CPPFLAGS = $(AM_CPPFLAGS) $(OPENSSL_INCS) +EVENT1_HDRS = \ + include/evdns.h \ + include/event.h \ + include/evhttp.h \ + include/evrpc.h \ + include/evutil.h + +@INSTALL_LIBEVENT_TRUE@include_HEADERS = $(EVENT1_HDRS) +AM_CPPFLAGS = -I$(srcdir)/compat -I$(srcdir)/include -I./include $(SYS_INCLUDES) +all: $(BUILT_SOURCES) config.h evconfig-private.h + $(MAKE) $(AM_MAKEFLAGS) all-am + +.SUFFIXES: +.SUFFIXES: .c .lo .log .o .obj .test .test$(EXEEXT) .trs +am--refresh: Makefile + @: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/include/include.am $(srcdir)/test/include.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ + $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ + && exit 0; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + echo ' $(SHELL) ./config.status'; \ + $(SHELL) ./config.status;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ + esac; +$(srcdir)/include/include.am $(srcdir)/test/include.am $(am__empty): + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + $(SHELL) ./config.status --recheck + +$(top_srcdir)/configure: $(am__configure_deps) + $(am__cd) $(srcdir) && $(AUTOCONF) +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) +$(am__aclocal_m4_deps): + +config.h: stamp-h1 + @test -f $@ || rm -f stamp-h1 + @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 + +stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status + @rm -f stamp-h1 + cd $(top_builddir) && $(SHELL) ./config.status config.h +$(srcdir)/config.h.in: $(am__configure_deps) + ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) + rm -f stamp-h1 + touch $@ + +evconfig-private.h: stamp-h2 + @test -f $@ || rm -f stamp-h2 + @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h2 + +stamp-h2: $(srcdir)/evconfig-private.h.in $(top_builddir)/config.status + @rm -f stamp-h2 + cd $(top_builddir) && $(SHELL) ./config.status evconfig-private.h + +distclean-hdr: + -rm -f config.h stamp-h1 evconfig-private.h stamp-h2 +libevent.pc: $(top_builddir)/config.status $(srcdir)/libevent.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +libevent_openssl.pc: $(top_builddir)/config.status $(srcdir)/libevent_openssl.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +libevent_pthreads.pc: $(top_builddir)/config.status $(srcdir)/libevent_pthreads.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $@ + +install-libLTLIBRARIES: $(lib_LTLIBRARIES) + @$(NORMAL_INSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + list2=; for p in $$list; do \ + if test -f $$p; then \ + list2="$$list2 $$p"; \ + else :; fi; \ + done; \ + test -z "$$list2" || { \ + echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ + } + +uninstall-libLTLIBRARIES: + @$(NORMAL_UNINSTALL) + @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ + for p in $$list; do \ + $(am__strip_dir) \ + echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ + $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ + done + +clean-libLTLIBRARIES: + -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) + @list='$(lib_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libevent.la: $(libevent_la_OBJECTS) $(libevent_la_DEPENDENCIES) $(EXTRA_libevent_la_DEPENDENCIES) + $(AM_V_CCLD)$(libevent_la_LINK) $(am_libevent_la_rpath) $(libevent_la_OBJECTS) $(libevent_la_LIBADD) $(LIBS) + +libevent_core.la: $(libevent_core_la_OBJECTS) $(libevent_core_la_DEPENDENCIES) $(EXTRA_libevent_core_la_DEPENDENCIES) + $(AM_V_CCLD)$(libevent_core_la_LINK) $(am_libevent_core_la_rpath) $(libevent_core_la_OBJECTS) $(libevent_core_la_LIBADD) $(LIBS) + +libevent_extra.la: $(libevent_extra_la_OBJECTS) $(libevent_extra_la_DEPENDENCIES) $(EXTRA_libevent_extra_la_DEPENDENCIES) + $(AM_V_CCLD)$(libevent_extra_la_LINK) $(am_libevent_extra_la_rpath) $(libevent_extra_la_OBJECTS) $(libevent_extra_la_LIBADD) $(LIBS) + +libevent_openssl.la: $(libevent_openssl_la_OBJECTS) $(libevent_openssl_la_DEPENDENCIES) $(EXTRA_libevent_openssl_la_DEPENDENCIES) + $(AM_V_CCLD)$(libevent_openssl_la_LINK) $(am_libevent_openssl_la_rpath) $(libevent_openssl_la_OBJECTS) $(libevent_openssl_la_LIBADD) $(LIBS) + +libevent_pthreads.la: $(libevent_pthreads_la_OBJECTS) $(libevent_pthreads_la_DEPENDENCIES) $(EXTRA_libevent_pthreads_la_DEPENDENCIES) + $(AM_V_CCLD)$(libevent_pthreads_la_LINK) $(am_libevent_pthreads_la_rpath) $(libevent_pthreads_la_OBJECTS) $(libevent_pthreads_la_LIBADD) $(LIBS) + +clean-noinstPROGRAMS: + @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list +test/$(am__dirstamp): + @$(MKDIR_P) test + @: > test/$(am__dirstamp) +test/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) test/$(DEPDIR) + @: > test/$(DEPDIR)/$(am__dirstamp) +test/bench.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/bench$(EXEEXT): $(test_bench_OBJECTS) $(test_bench_DEPENDENCIES) $(EXTRA_test_bench_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/bench$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_bench_OBJECTS) $(test_bench_LDADD) $(LIBS) +test/bench_cascade.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/bench_cascade$(EXEEXT): $(test_bench_cascade_OBJECTS) $(test_bench_cascade_DEPENDENCIES) $(EXTRA_test_bench_cascade_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/bench_cascade$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_bench_cascade_OBJECTS) $(test_bench_cascade_LDADD) $(LIBS) +test/bench_http.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/bench_http$(EXEEXT): $(test_bench_http_OBJECTS) $(test_bench_http_DEPENDENCIES) $(EXTRA_test_bench_http_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/bench_http$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_bench_http_OBJECTS) $(test_bench_http_LDADD) $(LIBS) +test/bench_httpclient.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/bench_httpclient$(EXEEXT): $(test_bench_httpclient_OBJECTS) $(test_bench_httpclient_DEPENDENCIES) $(EXTRA_test_bench_httpclient_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/bench_httpclient$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_bench_httpclient_OBJECTS) $(test_bench_httpclient_LDADD) $(LIBS) +test/test_regress-regress.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress.gen.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_buffer.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_bufferevent.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_dns.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_et.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_finalize.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_http.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_listener.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_main.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_minheap.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_rpc.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_testutils.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_util.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-tinytest.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_thread.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_zlib.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_iocp.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) +test/test_regress-regress_ssl.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/regress$(EXEEXT): $(test_regress_OBJECTS) $(test_regress_DEPENDENCIES) $(EXTRA_test_regress_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/regress$(EXEEXT) + $(AM_V_CCLD)$(test_regress_LINK) $(test_regress_OBJECTS) $(test_regress_LDADD) $(LIBS) +test/test-changelist.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-changelist$(EXEEXT): $(test_test_changelist_OBJECTS) $(test_test_changelist_DEPENDENCIES) $(EXTRA_test_test_changelist_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-changelist$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_changelist_OBJECTS) $(test_test_changelist_LDADD) $(LIBS) +test/test-closed.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-closed$(EXEEXT): $(test_test_closed_OBJECTS) $(test_test_closed_DEPENDENCIES) $(EXTRA_test_test_closed_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-closed$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_closed_OBJECTS) $(test_test_closed_LDADD) $(LIBS) +test/test-dumpevents.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-dumpevents$(EXEEXT): $(test_test_dumpevents_OBJECTS) $(test_test_dumpevents_DEPENDENCIES) $(EXTRA_test_test_dumpevents_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-dumpevents$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_dumpevents_OBJECTS) $(test_test_dumpevents_LDADD) $(LIBS) +test/test-eof.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-eof$(EXEEXT): $(test_test_eof_OBJECTS) $(test_test_eof_DEPENDENCIES) $(EXTRA_test_test_eof_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-eof$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_eof_OBJECTS) $(test_test_eof_LDADD) $(LIBS) +test/test-fdleak.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-fdleak$(EXEEXT): $(test_test_fdleak_OBJECTS) $(test_test_fdleak_DEPENDENCIES) $(EXTRA_test_test_fdleak_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-fdleak$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_fdleak_OBJECTS) $(test_test_fdleak_LDADD) $(LIBS) +test/test-init.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-init$(EXEEXT): $(test_test_init_OBJECTS) $(test_test_init_DEPENDENCIES) $(EXTRA_test_test_init_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-init$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_init_OBJECTS) $(test_test_init_LDADD) $(LIBS) +test/test-ratelim.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-ratelim$(EXEEXT): $(test_test_ratelim_OBJECTS) $(test_test_ratelim_DEPENDENCIES) $(EXTRA_test_test_ratelim_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-ratelim$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_ratelim_OBJECTS) $(test_test_ratelim_LDADD) $(LIBS) +test/test-time.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-time$(EXEEXT): $(test_test_time_OBJECTS) $(test_test_time_DEPENDENCIES) $(EXTRA_test_test_time_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-time$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_time_OBJECTS) $(test_test_time_LDADD) $(LIBS) +test/test-weof.$(OBJEXT): test/$(am__dirstamp) \ + test/$(DEPDIR)/$(am__dirstamp) + +test/test-weof$(EXEEXT): $(test_test_weof_OBJECTS) $(test_test_weof_DEPENDENCIES) $(EXTRA_test_test_weof_DEPENDENCIES) test/$(am__dirstamp) + @rm -f test/test-weof$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_test_weof_OBJECTS) $(test_test_weof_LDADD) $(LIBS) +install-dist_binSCRIPTS: $(dist_bin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(dist_bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-dist_binSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(dist_bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + -rm -f test/*.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@$(DEPDIR)/epoll_sub.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buffer.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/buffer_iocp.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bufferevent.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bufferevent_async.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bufferevent_filter.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bufferevent_pair.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bufferevent_ratelim.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bufferevent_sock.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/devpoll.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/epoll.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evdns.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/event.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/event_iocp.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/event_tagging.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evmap.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evport.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evrpc.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evthread.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evthread_pthread.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evthread_win32.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evutil.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evutil_rand.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/evutil_time.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/http.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kqueue.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libevent_openssl_la-bufferevent_openssl.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/listener.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/log.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/poll.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/select.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/signal.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strlcpy.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/win32select.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/bench.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/bench_cascade.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/bench_http.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/bench_httpclient.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-changelist.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-closed.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-dumpevents.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-eof.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-fdleak.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-init.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-ratelim.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-time.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test-weof.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress.gen.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_buffer.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_bufferevent.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_dns.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_et.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_finalize.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_http.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_iocp.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_listener.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_main.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_minheap.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_rpc.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_ssl.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_testutils.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_thread.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_util.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-regress_zlib.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@test/$(DEPDIR)/test_regress-tinytest.Po@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ +@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< + +.c.obj: +@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ +@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ +@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ +@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ +@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +libevent_openssl_la-bufferevent_openssl.lo: bufferevent_openssl.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libevent_openssl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libevent_openssl_la-bufferevent_openssl.lo -MD -MP -MF $(DEPDIR)/libevent_openssl_la-bufferevent_openssl.Tpo -c -o libevent_openssl_la-bufferevent_openssl.lo `test -f 'bufferevent_openssl.c' || echo '$(srcdir)/'`bufferevent_openssl.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libevent_openssl_la-bufferevent_openssl.Tpo $(DEPDIR)/libevent_openssl_la-bufferevent_openssl.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='bufferevent_openssl.c' object='libevent_openssl_la-bufferevent_openssl.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libevent_openssl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libevent_openssl_la-bufferevent_openssl.lo `test -f 'bufferevent_openssl.c' || echo '$(srcdir)/'`bufferevent_openssl.c + +test/test_regress-regress.o: test/regress.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress.Tpo -c -o test/test_regress-regress.o `test -f 'test/regress.c' || echo '$(srcdir)/'`test/regress.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress.Tpo test/$(DEPDIR)/test_regress-regress.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress.c' object='test/test_regress-regress.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress.o `test -f 'test/regress.c' || echo '$(srcdir)/'`test/regress.c + +test/test_regress-regress.obj: test/regress.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress.Tpo -c -o test/test_regress-regress.obj `if test -f 'test/regress.c'; then $(CYGPATH_W) 'test/regress.c'; else $(CYGPATH_W) '$(srcdir)/test/regress.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress.Tpo test/$(DEPDIR)/test_regress-regress.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress.c' object='test/test_regress-regress.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress.obj `if test -f 'test/regress.c'; then $(CYGPATH_W) 'test/regress.c'; else $(CYGPATH_W) '$(srcdir)/test/regress.c'; fi` + +test/test_regress-regress.gen.o: test/regress.gen.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress.gen.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress.gen.Tpo -c -o test/test_regress-regress.gen.o `test -f 'test/regress.gen.c' || echo '$(srcdir)/'`test/regress.gen.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress.gen.Tpo test/$(DEPDIR)/test_regress-regress.gen.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress.gen.c' object='test/test_regress-regress.gen.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress.gen.o `test -f 'test/regress.gen.c' || echo '$(srcdir)/'`test/regress.gen.c + +test/test_regress-regress.gen.obj: test/regress.gen.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress.gen.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress.gen.Tpo -c -o test/test_regress-regress.gen.obj `if test -f 'test/regress.gen.c'; then $(CYGPATH_W) 'test/regress.gen.c'; else $(CYGPATH_W) '$(srcdir)/test/regress.gen.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress.gen.Tpo test/$(DEPDIR)/test_regress-regress.gen.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress.gen.c' object='test/test_regress-regress.gen.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress.gen.obj `if test -f 'test/regress.gen.c'; then $(CYGPATH_W) 'test/regress.gen.c'; else $(CYGPATH_W) '$(srcdir)/test/regress.gen.c'; fi` + +test/test_regress-regress_buffer.o: test/regress_buffer.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_buffer.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_buffer.Tpo -c -o test/test_regress-regress_buffer.o `test -f 'test/regress_buffer.c' || echo '$(srcdir)/'`test/regress_buffer.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_buffer.Tpo test/$(DEPDIR)/test_regress-regress_buffer.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_buffer.c' object='test/test_regress-regress_buffer.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_buffer.o `test -f 'test/regress_buffer.c' || echo '$(srcdir)/'`test/regress_buffer.c + +test/test_regress-regress_buffer.obj: test/regress_buffer.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_buffer.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_buffer.Tpo -c -o test/test_regress-regress_buffer.obj `if test -f 'test/regress_buffer.c'; then $(CYGPATH_W) 'test/regress_buffer.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_buffer.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_buffer.Tpo test/$(DEPDIR)/test_regress-regress_buffer.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_buffer.c' object='test/test_regress-regress_buffer.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_buffer.obj `if test -f 'test/regress_buffer.c'; then $(CYGPATH_W) 'test/regress_buffer.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_buffer.c'; fi` + +test/test_regress-regress_bufferevent.o: test/regress_bufferevent.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_bufferevent.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_bufferevent.Tpo -c -o test/test_regress-regress_bufferevent.o `test -f 'test/regress_bufferevent.c' || echo '$(srcdir)/'`test/regress_bufferevent.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_bufferevent.Tpo test/$(DEPDIR)/test_regress-regress_bufferevent.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_bufferevent.c' object='test/test_regress-regress_bufferevent.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_bufferevent.o `test -f 'test/regress_bufferevent.c' || echo '$(srcdir)/'`test/regress_bufferevent.c + +test/test_regress-regress_bufferevent.obj: test/regress_bufferevent.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_bufferevent.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_bufferevent.Tpo -c -o test/test_regress-regress_bufferevent.obj `if test -f 'test/regress_bufferevent.c'; then $(CYGPATH_W) 'test/regress_bufferevent.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_bufferevent.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_bufferevent.Tpo test/$(DEPDIR)/test_regress-regress_bufferevent.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_bufferevent.c' object='test/test_regress-regress_bufferevent.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_bufferevent.obj `if test -f 'test/regress_bufferevent.c'; then $(CYGPATH_W) 'test/regress_bufferevent.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_bufferevent.c'; fi` + +test/test_regress-regress_dns.o: test/regress_dns.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_dns.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_dns.Tpo -c -o test/test_regress-regress_dns.o `test -f 'test/regress_dns.c' || echo '$(srcdir)/'`test/regress_dns.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_dns.Tpo test/$(DEPDIR)/test_regress-regress_dns.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_dns.c' object='test/test_regress-regress_dns.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_dns.o `test -f 'test/regress_dns.c' || echo '$(srcdir)/'`test/regress_dns.c + +test/test_regress-regress_dns.obj: test/regress_dns.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_dns.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_dns.Tpo -c -o test/test_regress-regress_dns.obj `if test -f 'test/regress_dns.c'; then $(CYGPATH_W) 'test/regress_dns.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_dns.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_dns.Tpo test/$(DEPDIR)/test_regress-regress_dns.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_dns.c' object='test/test_regress-regress_dns.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_dns.obj `if test -f 'test/regress_dns.c'; then $(CYGPATH_W) 'test/regress_dns.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_dns.c'; fi` + +test/test_regress-regress_et.o: test/regress_et.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_et.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_et.Tpo -c -o test/test_regress-regress_et.o `test -f 'test/regress_et.c' || echo '$(srcdir)/'`test/regress_et.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_et.Tpo test/$(DEPDIR)/test_regress-regress_et.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_et.c' object='test/test_regress-regress_et.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_et.o `test -f 'test/regress_et.c' || echo '$(srcdir)/'`test/regress_et.c + +test/test_regress-regress_et.obj: test/regress_et.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_et.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_et.Tpo -c -o test/test_regress-regress_et.obj `if test -f 'test/regress_et.c'; then $(CYGPATH_W) 'test/regress_et.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_et.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_et.Tpo test/$(DEPDIR)/test_regress-regress_et.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_et.c' object='test/test_regress-regress_et.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_et.obj `if test -f 'test/regress_et.c'; then $(CYGPATH_W) 'test/regress_et.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_et.c'; fi` + +test/test_regress-regress_finalize.o: test/regress_finalize.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_finalize.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_finalize.Tpo -c -o test/test_regress-regress_finalize.o `test -f 'test/regress_finalize.c' || echo '$(srcdir)/'`test/regress_finalize.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_finalize.Tpo test/$(DEPDIR)/test_regress-regress_finalize.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_finalize.c' object='test/test_regress-regress_finalize.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_finalize.o `test -f 'test/regress_finalize.c' || echo '$(srcdir)/'`test/regress_finalize.c + +test/test_regress-regress_finalize.obj: test/regress_finalize.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_finalize.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_finalize.Tpo -c -o test/test_regress-regress_finalize.obj `if test -f 'test/regress_finalize.c'; then $(CYGPATH_W) 'test/regress_finalize.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_finalize.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_finalize.Tpo test/$(DEPDIR)/test_regress-regress_finalize.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_finalize.c' object='test/test_regress-regress_finalize.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_finalize.obj `if test -f 'test/regress_finalize.c'; then $(CYGPATH_W) 'test/regress_finalize.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_finalize.c'; fi` + +test/test_regress-regress_http.o: test/regress_http.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_http.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_http.Tpo -c -o test/test_regress-regress_http.o `test -f 'test/regress_http.c' || echo '$(srcdir)/'`test/regress_http.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_http.Tpo test/$(DEPDIR)/test_regress-regress_http.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_http.c' object='test/test_regress-regress_http.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_http.o `test -f 'test/regress_http.c' || echo '$(srcdir)/'`test/regress_http.c + +test/test_regress-regress_http.obj: test/regress_http.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_http.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_http.Tpo -c -o test/test_regress-regress_http.obj `if test -f 'test/regress_http.c'; then $(CYGPATH_W) 'test/regress_http.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_http.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_http.Tpo test/$(DEPDIR)/test_regress-regress_http.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_http.c' object='test/test_regress-regress_http.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_http.obj `if test -f 'test/regress_http.c'; then $(CYGPATH_W) 'test/regress_http.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_http.c'; fi` + +test/test_regress-regress_listener.o: test/regress_listener.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_listener.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_listener.Tpo -c -o test/test_regress-regress_listener.o `test -f 'test/regress_listener.c' || echo '$(srcdir)/'`test/regress_listener.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_listener.Tpo test/$(DEPDIR)/test_regress-regress_listener.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_listener.c' object='test/test_regress-regress_listener.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_listener.o `test -f 'test/regress_listener.c' || echo '$(srcdir)/'`test/regress_listener.c + +test/test_regress-regress_listener.obj: test/regress_listener.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_listener.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_listener.Tpo -c -o test/test_regress-regress_listener.obj `if test -f 'test/regress_listener.c'; then $(CYGPATH_W) 'test/regress_listener.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_listener.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_listener.Tpo test/$(DEPDIR)/test_regress-regress_listener.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_listener.c' object='test/test_regress-regress_listener.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_listener.obj `if test -f 'test/regress_listener.c'; then $(CYGPATH_W) 'test/regress_listener.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_listener.c'; fi` + +test/test_regress-regress_main.o: test/regress_main.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_main.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_main.Tpo -c -o test/test_regress-regress_main.o `test -f 'test/regress_main.c' || echo '$(srcdir)/'`test/regress_main.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_main.Tpo test/$(DEPDIR)/test_regress-regress_main.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_main.c' object='test/test_regress-regress_main.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_main.o `test -f 'test/regress_main.c' || echo '$(srcdir)/'`test/regress_main.c + +test/test_regress-regress_main.obj: test/regress_main.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_main.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_main.Tpo -c -o test/test_regress-regress_main.obj `if test -f 'test/regress_main.c'; then $(CYGPATH_W) 'test/regress_main.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_main.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_main.Tpo test/$(DEPDIR)/test_regress-regress_main.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_main.c' object='test/test_regress-regress_main.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_main.obj `if test -f 'test/regress_main.c'; then $(CYGPATH_W) 'test/regress_main.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_main.c'; fi` + +test/test_regress-regress_minheap.o: test/regress_minheap.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_minheap.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_minheap.Tpo -c -o test/test_regress-regress_minheap.o `test -f 'test/regress_minheap.c' || echo '$(srcdir)/'`test/regress_minheap.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_minheap.Tpo test/$(DEPDIR)/test_regress-regress_minheap.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_minheap.c' object='test/test_regress-regress_minheap.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_minheap.o `test -f 'test/regress_minheap.c' || echo '$(srcdir)/'`test/regress_minheap.c + +test/test_regress-regress_minheap.obj: test/regress_minheap.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_minheap.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_minheap.Tpo -c -o test/test_regress-regress_minheap.obj `if test -f 'test/regress_minheap.c'; then $(CYGPATH_W) 'test/regress_minheap.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_minheap.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_minheap.Tpo test/$(DEPDIR)/test_regress-regress_minheap.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_minheap.c' object='test/test_regress-regress_minheap.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_minheap.obj `if test -f 'test/regress_minheap.c'; then $(CYGPATH_W) 'test/regress_minheap.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_minheap.c'; fi` + +test/test_regress-regress_rpc.o: test/regress_rpc.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_rpc.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_rpc.Tpo -c -o test/test_regress-regress_rpc.o `test -f 'test/regress_rpc.c' || echo '$(srcdir)/'`test/regress_rpc.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_rpc.Tpo test/$(DEPDIR)/test_regress-regress_rpc.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_rpc.c' object='test/test_regress-regress_rpc.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_rpc.o `test -f 'test/regress_rpc.c' || echo '$(srcdir)/'`test/regress_rpc.c + +test/test_regress-regress_rpc.obj: test/regress_rpc.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_rpc.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_rpc.Tpo -c -o test/test_regress-regress_rpc.obj `if test -f 'test/regress_rpc.c'; then $(CYGPATH_W) 'test/regress_rpc.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_rpc.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_rpc.Tpo test/$(DEPDIR)/test_regress-regress_rpc.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_rpc.c' object='test/test_regress-regress_rpc.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_rpc.obj `if test -f 'test/regress_rpc.c'; then $(CYGPATH_W) 'test/regress_rpc.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_rpc.c'; fi` + +test/test_regress-regress_testutils.o: test/regress_testutils.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_testutils.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_testutils.Tpo -c -o test/test_regress-regress_testutils.o `test -f 'test/regress_testutils.c' || echo '$(srcdir)/'`test/regress_testutils.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_testutils.Tpo test/$(DEPDIR)/test_regress-regress_testutils.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_testutils.c' object='test/test_regress-regress_testutils.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_testutils.o `test -f 'test/regress_testutils.c' || echo '$(srcdir)/'`test/regress_testutils.c + +test/test_regress-regress_testutils.obj: test/regress_testutils.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_testutils.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_testutils.Tpo -c -o test/test_regress-regress_testutils.obj `if test -f 'test/regress_testutils.c'; then $(CYGPATH_W) 'test/regress_testutils.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_testutils.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_testutils.Tpo test/$(DEPDIR)/test_regress-regress_testutils.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_testutils.c' object='test/test_regress-regress_testutils.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_testutils.obj `if test -f 'test/regress_testutils.c'; then $(CYGPATH_W) 'test/regress_testutils.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_testutils.c'; fi` + +test/test_regress-regress_util.o: test/regress_util.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_util.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_util.Tpo -c -o test/test_regress-regress_util.o `test -f 'test/regress_util.c' || echo '$(srcdir)/'`test/regress_util.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_util.Tpo test/$(DEPDIR)/test_regress-regress_util.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_util.c' object='test/test_regress-regress_util.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_util.o `test -f 'test/regress_util.c' || echo '$(srcdir)/'`test/regress_util.c + +test/test_regress-regress_util.obj: test/regress_util.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_util.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_util.Tpo -c -o test/test_regress-regress_util.obj `if test -f 'test/regress_util.c'; then $(CYGPATH_W) 'test/regress_util.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_util.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_util.Tpo test/$(DEPDIR)/test_regress-regress_util.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_util.c' object='test/test_regress-regress_util.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_util.obj `if test -f 'test/regress_util.c'; then $(CYGPATH_W) 'test/regress_util.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_util.c'; fi` + +test/test_regress-tinytest.o: test/tinytest.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-tinytest.o -MD -MP -MF test/$(DEPDIR)/test_regress-tinytest.Tpo -c -o test/test_regress-tinytest.o `test -f 'test/tinytest.c' || echo '$(srcdir)/'`test/tinytest.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-tinytest.Tpo test/$(DEPDIR)/test_regress-tinytest.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/tinytest.c' object='test/test_regress-tinytest.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-tinytest.o `test -f 'test/tinytest.c' || echo '$(srcdir)/'`test/tinytest.c + +test/test_regress-tinytest.obj: test/tinytest.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-tinytest.obj -MD -MP -MF test/$(DEPDIR)/test_regress-tinytest.Tpo -c -o test/test_regress-tinytest.obj `if test -f 'test/tinytest.c'; then $(CYGPATH_W) 'test/tinytest.c'; else $(CYGPATH_W) '$(srcdir)/test/tinytest.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-tinytest.Tpo test/$(DEPDIR)/test_regress-tinytest.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/tinytest.c' object='test/test_regress-tinytest.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-tinytest.obj `if test -f 'test/tinytest.c'; then $(CYGPATH_W) 'test/tinytest.c'; else $(CYGPATH_W) '$(srcdir)/test/tinytest.c'; fi` + +test/test_regress-regress_thread.o: test/regress_thread.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_thread.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_thread.Tpo -c -o test/test_regress-regress_thread.o `test -f 'test/regress_thread.c' || echo '$(srcdir)/'`test/regress_thread.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_thread.Tpo test/$(DEPDIR)/test_regress-regress_thread.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_thread.c' object='test/test_regress-regress_thread.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_thread.o `test -f 'test/regress_thread.c' || echo '$(srcdir)/'`test/regress_thread.c + +test/test_regress-regress_thread.obj: test/regress_thread.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_thread.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_thread.Tpo -c -o test/test_regress-regress_thread.obj `if test -f 'test/regress_thread.c'; then $(CYGPATH_W) 'test/regress_thread.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_thread.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_thread.Tpo test/$(DEPDIR)/test_regress-regress_thread.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_thread.c' object='test/test_regress-regress_thread.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_thread.obj `if test -f 'test/regress_thread.c'; then $(CYGPATH_W) 'test/regress_thread.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_thread.c'; fi` + +test/test_regress-regress_zlib.o: test/regress_zlib.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_zlib.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_zlib.Tpo -c -o test/test_regress-regress_zlib.o `test -f 'test/regress_zlib.c' || echo '$(srcdir)/'`test/regress_zlib.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_zlib.Tpo test/$(DEPDIR)/test_regress-regress_zlib.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_zlib.c' object='test/test_regress-regress_zlib.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_zlib.o `test -f 'test/regress_zlib.c' || echo '$(srcdir)/'`test/regress_zlib.c + +test/test_regress-regress_zlib.obj: test/regress_zlib.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_zlib.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_zlib.Tpo -c -o test/test_regress-regress_zlib.obj `if test -f 'test/regress_zlib.c'; then $(CYGPATH_W) 'test/regress_zlib.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_zlib.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_zlib.Tpo test/$(DEPDIR)/test_regress-regress_zlib.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_zlib.c' object='test/test_regress-regress_zlib.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_zlib.obj `if test -f 'test/regress_zlib.c'; then $(CYGPATH_W) 'test/regress_zlib.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_zlib.c'; fi` + +test/test_regress-regress_iocp.o: test/regress_iocp.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_iocp.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_iocp.Tpo -c -o test/test_regress-regress_iocp.o `test -f 'test/regress_iocp.c' || echo '$(srcdir)/'`test/regress_iocp.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_iocp.Tpo test/$(DEPDIR)/test_regress-regress_iocp.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_iocp.c' object='test/test_regress-regress_iocp.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_iocp.o `test -f 'test/regress_iocp.c' || echo '$(srcdir)/'`test/regress_iocp.c + +test/test_regress-regress_iocp.obj: test/regress_iocp.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_iocp.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_iocp.Tpo -c -o test/test_regress-regress_iocp.obj `if test -f 'test/regress_iocp.c'; then $(CYGPATH_W) 'test/regress_iocp.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_iocp.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_iocp.Tpo test/$(DEPDIR)/test_regress-regress_iocp.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_iocp.c' object='test/test_regress-regress_iocp.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_iocp.obj `if test -f 'test/regress_iocp.c'; then $(CYGPATH_W) 'test/regress_iocp.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_iocp.c'; fi` + +test/test_regress-regress_ssl.o: test/regress_ssl.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_ssl.o -MD -MP -MF test/$(DEPDIR)/test_regress-regress_ssl.Tpo -c -o test/test_regress-regress_ssl.o `test -f 'test/regress_ssl.c' || echo '$(srcdir)/'`test/regress_ssl.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_ssl.Tpo test/$(DEPDIR)/test_regress-regress_ssl.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_ssl.c' object='test/test_regress-regress_ssl.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_ssl.o `test -f 'test/regress_ssl.c' || echo '$(srcdir)/'`test/regress_ssl.c + +test/test_regress-regress_ssl.obj: test/regress_ssl.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT test/test_regress-regress_ssl.obj -MD -MP -MF test/$(DEPDIR)/test_regress-regress_ssl.Tpo -c -o test/test_regress-regress_ssl.obj `if test -f 'test/regress_ssl.c'; then $(CYGPATH_W) 'test/regress_ssl.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_ssl.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) test/$(DEPDIR)/test_regress-regress_ssl.Tpo test/$(DEPDIR)/test_regress-regress_ssl.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test/regress_ssl.c' object='test/test_regress-regress_ssl.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_regress_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o test/test_regress-regress_ssl.obj `if test -f 'test/regress_ssl.c'; then $(CYGPATH_W) 'test/regress_ssl.c'; else $(CYGPATH_W) '$(srcdir)/test/regress_ssl.c'; fi` + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + -rm -rf test/.libs test/_libs + +distclean-libtool: + -rm -f libtool config.lt +install-pkgconfigDATA: $(pkgconfig_DATA) + @$(NORMAL_INSTALL) + @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(pkgconfigdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pkgconfigdir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(pkgconfigdir)" || exit $$?; \ + done + +uninstall-pkgconfigDATA: + @$(NORMAL_UNINSTALL) + @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir) +install-includeHEADERS: $(include_HEADERS) + @$(NORMAL_INSTALL) + @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \ + done + +uninstall-includeHEADERS: + @$(NORMAL_UNINSTALL) + @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir) +install-include_event2HEADERS: $(include_event2_HEADERS) + @$(NORMAL_INSTALL) + @list='$(include_event2_HEADERS)'; test -n "$(include_event2dir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(include_event2dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(include_event2dir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(include_event2dir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(include_event2dir)" || exit $$?; \ + done + +uninstall-include_event2HEADERS: + @$(NORMAL_UNINSTALL) + @list='$(include_event2_HEADERS)'; test -n "$(include_event2dir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(include_event2dir)'; $(am__uninstall_files_from_dir) +install-nodist_include_event2HEADERS: $(nodist_include_event2_HEADERS) + @$(NORMAL_INSTALL) + @list='$(nodist_include_event2_HEADERS)'; test -n "$(include_event2dir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(include_event2dir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(include_event2dir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(include_event2dir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(include_event2dir)" || exit $$?; \ + done + +uninstall-nodist_include_event2HEADERS: + @$(NORMAL_UNINSTALL) + @list='$(nodist_include_event2_HEADERS)'; test -n "$(include_event2dir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(include_event2dir)'; $(am__uninstall_files_from_dir) + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscope: cscope.files + test ! -s cscope.files \ + || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) +clean-cscope: + -rm -f cscope.files +cscope.files: clean-cscope cscopelist +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + -rm -f cscope.out cscope.in.out cscope.po.out cscope.files + +# Recover from deleted '.trs' file; this should ensure that +# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create +# both 'foo.log' and 'foo.trs'. Break the recipe in two subshells +# to avoid problems with "make -n". +.log.trs: + rm -f $< $@ + $(MAKE) $(AM_MAKEFLAGS) $< + +# Leading 'am--fnord' is there to ensure the list of targets does not +# expand to empty, as could happen e.g. with make check TESTS=''. +am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) +am--force-recheck: + @: + +$(TEST_SUITE_LOG): $(TEST_LOGS) + @$(am__set_TESTS_bases); \ + am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ + redo_bases=`for i in $$bases; do \ + am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \ + done`; \ + if test -n "$$redo_bases"; then \ + redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \ + redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \ + if $(am__make_dryrun); then :; else \ + rm -f $$redo_logs && rm -f $$redo_results || exit 1; \ + fi; \ + fi; \ + if test -n "$$am__remaking_logs"; then \ + echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \ + "recursion detected" >&2; \ + elif test -n "$$redo_logs"; then \ + am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \ + fi; \ + if $(am__make_dryrun); then :; else \ + st=0; \ + errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \ + for i in $$redo_bases; do \ + test -f $$i.trs && test -r $$i.trs \ + || { echo "$$errmsg $$i.trs" >&2; st=1; }; \ + test -f $$i.log && test -r $$i.log \ + || { echo "$$errmsg $$i.log" >&2; st=1; }; \ + done; \ + test $$st -eq 0 || exit 1; \ + fi + @$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \ + ws='[ ]'; \ + results=`for b in $$bases; do echo $$b.trs; done`; \ + test -n "$$results" || results=/dev/null; \ + all=` grep "^$$ws*:test-result:" $$results | wc -l`; \ + pass=` grep "^$$ws*:test-result:$$ws*PASS" $$results | wc -l`; \ + fail=` grep "^$$ws*:test-result:$$ws*FAIL" $$results | wc -l`; \ + skip=` grep "^$$ws*:test-result:$$ws*SKIP" $$results | wc -l`; \ + xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \ + xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \ + error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \ + if test `expr $$fail + $$xpass + $$error` -eq 0; then \ + success=true; \ + else \ + success=false; \ + fi; \ + br='==================='; br=$$br$$br$$br$$br; \ + result_count () \ + { \ + if test x"$$1" = x"--maybe-color"; then \ + maybe_colorize=yes; \ + elif test x"$$1" = x"--no-color"; then \ + maybe_colorize=no; \ + else \ + echo "$@: invalid 'result_count' usage" >&2; exit 4; \ + fi; \ + shift; \ + desc=$$1 count=$$2; \ + if test $$maybe_colorize = yes && test $$count -gt 0; then \ + color_start=$$3 color_end=$$std; \ + else \ + color_start= color_end=; \ + fi; \ + echo "$${color_start}# $$desc $$count$${color_end}"; \ + }; \ + create_testsuite_report () \ + { \ + result_count $$1 "TOTAL:" $$all "$$brg"; \ + result_count $$1 "PASS: " $$pass "$$grn"; \ + result_count $$1 "SKIP: " $$skip "$$blu"; \ + result_count $$1 "XFAIL:" $$xfail "$$lgn"; \ + result_count $$1 "FAIL: " $$fail "$$red"; \ + result_count $$1 "XPASS:" $$xpass "$$red"; \ + result_count $$1 "ERROR:" $$error "$$mgn"; \ + }; \ + { \ + echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ + $(am__rst_title); \ + create_testsuite_report --no-color; \ + echo; \ + echo ".. contents:: :depth: 2"; \ + echo; \ + for b in $$bases; do echo $$b; done \ + | $(am__create_global_log); \ + } >$(TEST_SUITE_LOG).tmp || exit 1; \ + mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG); \ + if $$success; then \ + col="$$grn"; \ + else \ + col="$$red"; \ + test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ + fi; \ + echo "$${col}$$br$${std}"; \ + echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}"; \ + echo "$${col}$$br$${std}"; \ + create_testsuite_report --maybe-color; \ + echo "$$col$$br$$std"; \ + if $$success; then :; else \ + echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ + if test -n "$(PACKAGE_BUGREPORT)"; then \ + echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ + fi; \ + echo "$$col$$br$$std"; \ + fi; \ + $$success || exit 1 + +check-TESTS: + @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list + @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list + @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + @set +e; $(am__set_TESTS_bases); \ + log_list=`for i in $$bases; do echo $$i.log; done`; \ + trs_list=`for i in $$bases; do echo $$i.trs; done`; \ + log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ + $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ + exit $$?; +recheck: all + @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + @set +e; $(am__set_TESTS_bases); \ + bases=`for i in $$bases; do echo $$i; done \ + | $(am__list_recheck_tests)` || exit 1; \ + log_list=`for i in $$bases; do echo $$i.log; done`; \ + log_list=`echo $$log_list`; \ + $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \ + am__force_recheck=am--force-recheck \ + TEST_LOGS="$$log_list"; \ + exit $$? +test/test-script.sh.log: test/test-script.sh + @p='test/test-script.sh'; \ + b='test/test-script.sh'; \ + $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) +.test.log: + @p='$<'; \ + $(am__set_b); \ + $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) +@am__EXEEXT_TRUE@.test$(EXEEXT).log: +@am__EXEEXT_TRUE@ @p='$<'; \ +@am__EXEEXT_TRUE@ $(am__set_b); \ +@am__EXEEXT_TRUE@ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ +@am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \ +@am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ +@am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT) + +distdir: $(DISTFILES) + $(am__remove_distdir) + test -d "$(distdir)" || mkdir "$(distdir)" + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + -test -n "$(am__skip_mode_fix)" \ + || find "$(distdir)" -type d ! -perm -755 \ + -exec chmod u+rwx,go+rx {} \; -o \ + ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ + || chmod -R a+r "$(distdir)" +dist-gzip: distdir + tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz + $(am__post_remove_distdir) + +dist-bzip2: distdir + tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 + $(am__post_remove_distdir) + +dist-lzip: distdir + tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz + $(am__post_remove_distdir) + +dist-xz: distdir + tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz + $(am__post_remove_distdir) + +dist-tarZ: distdir + @echo WARNING: "Support for distribution archives compressed with" \ + "legacy program 'compress' is deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z + $(am__post_remove_distdir) + +dist-shar: distdir + @echo WARNING: "Support for shar distribution archives is" \ + "deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz + $(am__post_remove_distdir) + +dist-zip: distdir + -rm -f $(distdir).zip + zip -rq $(distdir).zip $(distdir) + $(am__post_remove_distdir) + +dist dist-all: + $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' + $(am__post_remove_distdir) + +# This target untars the dist file and tries a VPATH configuration. Then +# it guarantees that the distribution is self-contained by making another +# tarfile. +distcheck: dist + case '$(DIST_ARCHIVES)' in \ + *.tar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ + *.tar.bz2*) \ + bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.lz*) \ + lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ + *.tar.xz*) \ + xz -dc $(distdir).tar.xz | $(am__untar) ;;\ + *.tar.Z*) \ + uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ + *.shar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ + *.zip*) \ + unzip $(distdir).zip ;;\ + esac + chmod -R a-w $(distdir) + chmod u+w $(distdir) + mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst + chmod a-w $(distdir) + test -d $(distdir)/_build || exit 0; \ + dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ + && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ + && am__cwd=`pwd` \ + && $(am__cd) $(distdir)/_build/sub \ + && ../../configure \ + $(AM_DISTCHECK_CONFIGURE_FLAGS) \ + $(DISTCHECK_CONFIGURE_FLAGS) \ + --srcdir=../.. --prefix="$$dc_install_base" \ + && $(MAKE) $(AM_MAKEFLAGS) \ + && $(MAKE) $(AM_MAKEFLAGS) dvi \ + && $(MAKE) $(AM_MAKEFLAGS) check \ + && $(MAKE) $(AM_MAKEFLAGS) install \ + && $(MAKE) $(AM_MAKEFLAGS) installcheck \ + && $(MAKE) $(AM_MAKEFLAGS) uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ + distuninstallcheck \ + && chmod -R a-w "$$dc_install_base" \ + && ({ \ + (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ + distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ + } || { rm -rf "$$dc_destdir"; exit 1; }) \ + && rm -rf "$$dc_destdir" \ + && $(MAKE) $(AM_MAKEFLAGS) dist \ + && rm -rf $(DIST_ARCHIVES) \ + && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ + && cd "$$am__cwd" \ + || exit 1 + $(am__post_remove_distdir) + @(echo "$(distdir) archives ready for distribution: "; \ + list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ + sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' +distuninstallcheck: + @test -n '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: trying to run $@ with an empty' \ + '$$(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + $(am__cd) '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left after uninstall:" ; \ + if test -n "$(DESTDIR)"; then \ + echo " (check DESTDIR support)"; \ + fi ; \ + $(distuninstallcheck_listfiles) ; \ + exit 1; } >&2 +distcleancheck: distclean + @if test '$(srcdir)' = . ; then \ + echo "ERROR: distcleancheck can only run from a VPATH build" ; \ + exit 1 ; \ + fi + @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left in build directory after distclean:" ; \ + $(distcleancheck_listfiles) ; \ + exit 1; } >&2 +check-am: all-am + $(MAKE) $(AM_MAKEFLAGS) check-TESTS +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am +all-am: Makefile $(LTLIBRARIES) $(PROGRAMS) $(SCRIPTS) $(DATA) \ + $(HEADERS) config.h evconfig-private.h +installdirs: + for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(includedir)" "$(DESTDIR)$(include_event2dir)" "$(DESTDIR)$(include_event2dir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) + -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) + -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -rm -f test/$(DEPDIR)/$(am__dirstamp) + -rm -f test/$(am__dirstamp) + -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) +clean: clean-am + +clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ + clean-noinstLTLIBRARIES clean-noinstPROGRAMS mostlyclean-am + +distclean: distclean-am + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -rf $(DEPDIR) ./$(DEPDIR) test/$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-hdr distclean-libtool distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-includeHEADERS install-include_event2HEADERS \ + install-nodist_include_event2HEADERS install-pkgconfigDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: install-dist_binSCRIPTS install-libLTLIBRARIES + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -rf $(top_srcdir)/autom4te.cache + -rm -rf $(DEPDIR) ./$(DEPDIR) test/$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-dist_binSCRIPTS uninstall-includeHEADERS \ + uninstall-include_event2HEADERS uninstall-libLTLIBRARIES \ + uninstall-nodist_include_event2HEADERS uninstall-pkgconfigDATA + +.MAKE: all check check-am install install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am am--refresh check check-TESTS \ + check-am clean clean-cscope clean-generic clean-libLTLIBRARIES \ + clean-libtool clean-noinstLTLIBRARIES clean-noinstPROGRAMS \ + cscope cscopelist-am ctags ctags-am dist dist-all dist-bzip2 \ + dist-gzip dist-lzip dist-shar dist-tarZ dist-xz dist-zip \ + distcheck distclean distclean-compile distclean-generic \ + distclean-hdr distclean-libtool distclean-tags distcleancheck \ + distdir distuninstallcheck dvi dvi-am html html-am info \ + info-am install install-am install-data install-data-am \ + install-dist_binSCRIPTS install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-includeHEADERS install-include_event2HEADERS \ + install-info install-info-am install-libLTLIBRARIES \ + install-man install-nodist_include_event2HEADERS install-pdf \ + install-pdf-am install-pkgconfigDATA install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ + pdf pdf-am ps ps-am recheck tags tags-am uninstall \ + uninstall-am uninstall-dist_binSCRIPTS \ + uninstall-includeHEADERS uninstall-include_event2HEADERS \ + uninstall-libLTLIBRARIES \ + uninstall-nodist_include_event2HEADERS uninstall-pkgconfigDATA + +.PRECIOUS: Makefile + + +test/test-script.sh: test/test.sh + cp $(top_srcdir)/test/test.sh $@ + +test/regress.gen.c test/regress.gen.h: test/rpcgen-attempted + +test/rpcgen-attempted: test/regress.rpc event_rpcgen.py test/rpcgen_wrapper.sh + $(AM_V_GEN)date -u > $@ + $(AM_V_at)if $(srcdir)/test/rpcgen_wrapper.sh $(srcdir)/test; then \ + true; \ + else \ + echo "No Python installed; stubbing out RPC test." >&2; \ + echo " "> test/regress.gen.c; \ + echo "#define NO_PYTHON_EXISTS" > test/regress.gen.h; \ + fi + +$(TESTPROGRAMS) : libevent.la + +include/event2/event-config.h: config.h make-event-config.sed + $(AM_V_GEN)test -d include/event2 || $(MKDIR_P) include/event2 + $(AM_V_at)$(SED) -f $(srcdir)/make-event-config.sed < config.h > $@T + $(AM_V_at)mv -f $@T $@ + +verify: check + +doxygen: FORCE + doxygen $(srcdir)/Doxyfile +FORCE: + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/contrib/ntp/sntp/libevent/Makefile.nmake b/contrib/ntp/sntp/libevent/Makefile.nmake new file mode 100644 index 000000000..f27cd6194 --- /dev/null +++ b/contrib/ntp/sntp/libevent/Makefile.nmake @@ -0,0 +1,82 @@ +# WATCH OUT! This makefile is a work in progress. -*- makefile -*- +# +# I'm not very knowledgeable about MSVC and nmake beyond their most basic +# aspects. If anything here looks wrong to you, please let me know. + +# If OPENSSL_DIR is not set, builds without OpenSSL support. If you want +# OpenSSL support, you can set the OPENSSL_DIR variable to where you +# installed OpenSSL. This can be done in the environment: +# set OPENSSL_DIR=c:\openssl +# Or on the nmake command line: +# nmake OPENSSL_DIR=C:\openssl -f Makefile.nmake +# Or by uncommenting the following line here in the makefile... + +# OPENSSL_DIR=c:\openssl + +!IFDEF OPENSSL_DIR +SSL_CFLAGS=/I$(OPENSSL_DIR)\include /DEVENT__HAVE_OPENSSL +!ELSE +SSL_CFLAGS= +!ENDIF + +# Needed for correctness +CFLAGS=/IWIN32-Code /IWIN32-Code/nmake /Iinclude /Icompat /DHAVE_CONFIG_H /I. $(SSL_CFLAGS) + +# For optimization and warnings +CFLAGS=$(CFLAGS) /Ox /W3 /wd4996 /nologo + +# XXXX have a debug mode + +LIBFLAGS=/nologo + +CORE_OBJS=event.obj buffer.obj bufferevent.obj bufferevent_sock.obj \ + bufferevent_pair.obj listener.obj evmap.obj log.obj evutil.obj \ + strlcpy.obj signal.obj bufferevent_filter.obj evthread.obj \ + bufferevent_ratelim.obj evutil_rand.obj evutil_time.obj +WIN_OBJS=win32select.obj evthread_win32.obj buffer_iocp.obj \ + event_iocp.obj bufferevent_async.obj +EXTRA_OBJS=event_tagging.obj http.obj evdns.obj evrpc.obj + +!IFDEF OPENSSL_DIR +SSL_OBJS=bufferevent_openssl.obj +SSL_LIBS=libevent_openssl.lib +!ELSE +SSL_OBJS= +SSL_LIBS= +!ENDIF + +ALL_OBJS=$(CORE_OBJS) $(WIN_OBJS) $(EXTRA_OBJS) $(SSL_OBJS) +STATIC_LIBS=libevent_core.lib libevent_extras.lib libevent.lib $(SSL_LIBS) + + +all: static_libs tests + +static_libs: $(STATIC_LIBS) + +libevent_core.lib: $(CORE_OBJS) $(WIN_OBJS) + lib $(LIBFLAGS) $(CORE_OBJS) $(WIN_OBJS) /out:libevent_core.lib + +libevent_extras.lib: $(EXTRA_OBJS) + lib $(LIBFLAGS) $(EXTRA_OBJS) /out:libevent_extras.lib + +libevent.lib: $(CORE_OBJS) $(WIN_OBJS) $(EXTRA_OBJS) + lib $(LIBFLAGS) $(CORE_OBJS) $(EXTRA_OBJS) $(WIN_OBJS) /out:libevent.lib + +libevent_openssl.lib: $(SSL_OBJS) + lib $(LIBFLAGS) $(SSL_OBJS) /out:libevent_openssl.lib + +clean: + del $(ALL_OBJS) + del $(STATIC_LIBS) + cd test + $(MAKE) /F Makefile.nmake clean + cd .. + +tests: + cd test +!IFDEF OPENSSL_DIR + $(MAKE) OPENSSL_DIR=$(OPENSSL_DIR) /F Makefile.nmake +!ELSE + $(MAKE) /F Makefile.nmake +!ENDIF + cd .. diff --git a/contrib/ntp/sntp/libevent/WIN32-Code/nmake/evconfig-private.h b/contrib/ntp/sntp/libevent/WIN32-Code/nmake/evconfig-private.h new file mode 100644 index 000000000..88e206272 --- /dev/null +++ b/contrib/ntp/sntp/libevent/WIN32-Code/nmake/evconfig-private.h @@ -0,0 +1,6 @@ +#if !defined(EVENT_EVCONFIG__PRIVATE_H_) && !defined(__MINGW32__) +#define EVENT_EVCONFIG__PRIVATE_H_ + +/* Nothing to see here. Move along. */ + +#endif diff --git a/contrib/ntp/sntp/libevent/WIN32-Code/nmake/event2/event-config.h b/contrib/ntp/sntp/libevent/WIN32-Code/nmake/event2/event-config.h new file mode 100644 index 000000000..8cbf19028 --- /dev/null +++ b/contrib/ntp/sntp/libevent/WIN32-Code/nmake/event2/event-config.h @@ -0,0 +1,360 @@ +/* event2/event-config.h + * + * This file was generated by autoconf when libevent was built, and post- + * processed by Libevent so that its macros would have a uniform prefix. + * + * DO NOT EDIT THIS FILE. + * + * Do not rely on macros in this file existing in later versions. + */ +#ifndef EVENT_CONFIG_H__ +#define EVENT_CONFIG_H__ +/* config.h. Generated by configure. */ +/* config.h.in. Generated from configure.in by autoheader. */ + +/* Define if libevent should not allow replacing the mm functions */ +/* #undef EVENT__DISABLE_MM_REPLACEMENT */ + +/* Define if libevent should not be compiled with thread support */ +/* #undef EVENT__DISABLE_THREAD_SUPPORT */ + +/* Define if clock_gettime is available in libc */ +/* #undef _EVENT_DNS_USE_CPU_CLOCK_FOR_ID */ + +/* Define is no secure id variant is available */ +/* #define _EVENT_DNS_USE_GETTIMEOFDAY_FOR_ID 1 */ +#define EVENT_DNS_USE_FTIME_FOR_ID_ 1 + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_ARPA_INET_H */ + +/* Define to 1 if you have the `clock_gettime' function. */ +/* #undef EVENT__HAVE_CLOCK_GETTIME */ + +/* Define if /dev/poll is available */ +/* #undef EVENT__HAVE_DEVPOLL */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_DLFCN_H */ + +/* Define if your system supports the epoll system calls */ +/* #undef EVENT__HAVE_EPOLL */ + +/* Define to 1 if you have the `epoll_ctl' function. */ +/* #undef EVENT__HAVE_EPOLL_CTL */ + +/* Define to 1 if you have the `eventfd' function. */ +/* #undef EVENT__HAVE_EVENTFD */ + +/* Define if your system supports event ports */ +/* #undef EVENT__HAVE_EVENT_PORTS */ + +/* Define to 1 if you have the `fcntl' function. */ +/* #undef EVENT__HAVE_FCNTL */ + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_FCNTL_H 1 + +/* Define to 1 if you have the `getaddrinfo' function. */ +#define EVENT__HAVE_GETADDRINFO 1 + +/* Define to 1 if you have the `getnameinfo' function. */ +#define EVENT__HAVE_GETNAMEINFO 1 + +/* Define to 1 if you have the `getprotobynumber' function. */ +#define EVENT__HAVE_GETPROTOBYNUMBER 1 + +/* Define to 1 if you have the `getservbyname' function. */ +#define EVENT__HAVE_GETSERVBYNAME 1 + +/* Define to 1 if you have the `gettimeofday' function. */ +/* #define EVENT__HAVE_GETTIMEOFDAY 1 */ + +/* Define to 1 if you have the `inet_ntop' function. */ +/* #undef EVENT__HAVE_INET_NTOP */ + +/* Define to 1 if you have the `inet_pton' function. */ +/* #undef EVENT__HAVE_INET_PTON */ + +/* Define to 1 if you have the header file. */ +/* #define EVENT__HAVE_INTTYPES_H 1 */ + +/* Define to 1 if you have the `kqueue' function. */ +/* #undef EVENT__HAVE_KQUEUE */ + +/* Define if the system has zlib */ +/* #undef EVENT__HAVE_LIBZ */ + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_MEMORY_H 1 + +/* Define to 1 if you have the `mmap' function. */ +/* #undef EVENT__HAVE_MMAP */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_NETINET_IN6_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_NETINET_IN_H */ + +/* Define to 1 if you have the `pipe' function. */ +/* #undef EVENT__HAVE_PIPE */ + +/* Define to 1 if you have the `poll' function. */ +/* #undef EVENT__HAVE_POLL */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_POLL_H */ + +/* Define to 1 if you have the `port_create' function. */ +/* #undef EVENT__HAVE_PORT_CREATE */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_PORT_H */ + +/* Define if you have POSIX threads libraries and header files. */ +/* #undef EVENT__HAVE_PTHREAD */ + +/* Define if we have pthreads on this system */ +/* #undef EVENT__HAVE_PTHREADS */ + +/* Define to 1 if the system has the type `sa_family_t'. */ +/* #undef EVENT__HAVE_SA_FAMILY_T */ + +/* Define to 1 if you have the `select' function. */ +/* #undef EVENT__HAVE_SELECT */ + +/* Define to 1 if you have the `sendfile' function. */ +/* #undef EVENT__HAVE_SENDFILE */ + +/* Define if F_SETFD is defined in */ +/* #undef EVENT__HAVE_SETFD */ + +/* Define to 1 if you have the `sigaction' function. */ +/* #undef EVENT__HAVE_SIGACTION */ + +/* Define to 1 if you have the `signal' function. */ +#define EVENT__HAVE_SIGNAL 1 + +/* Define to 1 if you have the `splice' function. */ +/* #undef EVENT__HAVE_SPLICE */ + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_STDARG_H 1 + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_STDDEF_H 1 + +/* Define to 1 if you have the header file. */ +/* #define EVENT__HAVE_STDINT_H 1 */ + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_STDLIB_H 1 + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_STRINGS_H 1 + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_STRING_H 1 + +/* Define to 1 if you have the `strlcpy' function. */ +/* #undef EVENT__HAVE_STRLCPY */ + +/* Define to 1 if you have the `strsep' function. */ +/* #undef EVENT__HAVE_STRSEP */ + +/* Define to 1 if you have the `strtok_r' function. */ +/* #undef EVENT__HAVE_STRTOK_R */ + +/* Define to 1 if you have the `strtoll' function. */ +/* #define EVENT__HAVE_STRTOLL 1 */ + +#define EVENT__HAVE_STRUCT_ADDRINFO 1 + +/* Define to 1 if the system has the type `struct in6_addr'. */ +#define EVENT__HAVE_STRUCT_IN6_ADDR 1 + +/* Define to 1 if `s6_addr16' is member of `struct in6_addr'. */ +#define EVENT__HAVE_STRUCT_IN6_ADDR_S6_ADDR16 1 + +/* Define to 1 if `s6_addr32' is member of `struct in6_addr'. */ +#define EVENT__HAVE_STRUCT_IN6_ADDR_S6_ADDR32 1 + +/* Define to 1 if the system has the type `struct sockaddr_in6'. */ +#define EVENT__HAVE_STRUCT_SOCKADDR_IN6 1 + +/* Define to 1 if `sin6_len' is member of `struct sockaddr_in6'. */ +/* #undef EVENT__HAVE_STRUCT_SOCKADDR_IN6_SIN6_LEN */ + +/* Define to 1 if `sin_len' is member of `struct sockaddr_in'. */ +/* #undef EVENT__HAVE_STRUCT_SOCKADDR_IN_SIN_LEN */ + +/* Define to 1 if the system has the type `struct sockaddr_storage'. */ +#define EVENT__HAVE_STRUCT_SOCKADDR_STORAGE 1 + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_DEVPOLL_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_EPOLL_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_EVENTFD_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_EVENT_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_IOCTL_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_MMAN_H */ + +/* Define to 1 if you have the header file. */ +/* #define EVENT__HAVE_SYS_PARAM_H 1 */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_QUEUE_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_SELECT_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_SENDFILE_H */ + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_SOCKET_H */ + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the header file. */ +/* #define EVENT__HAVE_SYS_TIME_H 1 */ + +/* Define to 1 if you have the header file. */ +#define EVENT__HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the header file. */ +/* #undef EVENT__HAVE_SYS_UIO_H */ + +/* Define if TAILQ_FOREACH is defined in */ +/* #undef EVENT__HAVE_TAILQFOREACH */ + +/* Define if timeradd is defined in */ +/* #undef EVENT__HAVE_TIMERADD */ + +/* Define if timerclear is defined in */ +#define EVENT__HAVE_TIMERCLEAR 1 + +/* Define if timercmp is defined in */ +#define EVENT__HAVE_TIMERCMP 1 + +/* Define if timerisset is defined in */ +#define EVENT__HAVE_TIMERISSET 1 + +/* Define to 1 if the system has the type `uint16_t'. */ +/* #define EVENT__HAVE_UINT16_T 1 */ + +/* Define to 1 if the system has the type `uint32_t'. */ +/* #define EVENT__HAVE_UINT32_T 1 */ + +/* Define to 1 if the system has the type `uint64_t'. */ +/* #define EVENT__HAVE_UINT64_T 1 */ + +/* Define to 1 if the system has the type `uint8_t'. */ +/* #define EVENT__HAVE_UINT8_T 1 */ + +/* Define to 1 if you have the header file. */ +/* #define EVENT__HAVE_UNISTD_H 1 */ + +/* Define to 1 if you have the `vasprintf' function. */ +/* #undef EVENT__HAVE_VASPRINTF */ + +/* Define if kqueue works correctly with pipes */ +/* #undef EVENT__HAVE_WORKING_KQUEUE */ + +/* Numeric representation of the version */ +#define EVENT__NUMERIC_VERSION 0x02010500 + +/* Name of package */ +#define EVENT__PACKAGE "libevent" + +/* Define to the address where bug reports for this package should be sent. */ +#define EVENT__PACKAGE_BUGREPORT "" + +/* Define to the full name of this package. */ +#define EVENT__PACKAGE_NAME "" + +/* Define to the full name and version of this package. */ +#define EVENT__PACKAGE_STRING "" + +/* Define to the one symbol short name of this package. */ +#define EVENT__PACKAGE_TARNAME "" + +/* Define to the version of this package. */ +#define EVENT__PACKAGE_VERSION "" + +/* Define to necessary symbol if this constant uses a non-standard name on + your system. */ +/* #undef EVENT__PTHREAD_CREATE_JOINABLE */ + +/* The size of a `int', as computed by sizeof. */ +#define EVENT__SIZEOF_INT 4 + +/* The size of a `long', as computed by sizeof. */ +#define EVENT__SIZEOF_LONG 4 + +/* The size of a `long long', as computed by sizeof. */ +#define EVENT__SIZEOF_LONG_LONG 8 + +/* The size of a `short', as computed by sizeof. */ +#define EVENT__SIZEOF_SHORT 2 + +/* The size of `size_t', as computed by sizeof. */ +#ifdef _WIN64 +#define EVENT__SIZEOF_SIZE_T 8 +#else +#define EVENT__SIZEOF_SIZE_T 4 +#endif + +/* The size of `void *', as computed by sizeof. */ +#ifdef _WIN64 +#define EVENT__SIZEOF_VOID_P 8 +#else +#define EVENT__SIZEOF_VOID_P 4 +#endif + +/* Define to 1 if you have the ANSI C header files. */ +#define EVENT__STDC_HEADERS 1 + +/* Define to 1 if you can safely include both and . */ +#define EVENT__TIME_WITH_SYS_TIME 1 + +/* Version number of package */ +#define EVENT__VERSION "2.1.5-beta" + +/* Define to appropriate substitue if compiler doesnt have __func__ */ +#define EVENT____func__ __FUNCTION__ + +/* Define to empty if `const' does not conform to ANSI C. */ +/* #undef EVENT__const */ + +/* Define to `__inline__' or `__inline' if that's what the C compiler + calls it, or to nothing if 'inline' is not supported under any name. */ +#ifndef _EVENT___cplusplus +#define EVENT__inline __inline +#endif + +/* Define to `int' if does not define. */ +/* #undef EVENT__pid_t */ + +/* Define to `unsigned' if does not define. */ +/* #undef EVENT__size_t */ + +/* Define to unsigned int if you dont have it */ +#define EVENT__socklen_t unsigned int + +/* Define to `int' if does not define. */ +#define EVENT__ssize_t SSIZE_T + +#endif diff --git a/contrib/ntp/sntp/libevent/WIN32-Code/tree.h b/contrib/ntp/sntp/libevent/WIN32-Code/tree.h new file mode 100644 index 000000000..2ccfbf20a --- /dev/null +++ b/contrib/ntp/sntp/libevent/WIN32-Code/tree.h @@ -0,0 +1,677 @@ +/* $OpenBSD: tree.h,v 1.7 2002/10/17 21:51:54 art Exp $ */ +/* + * Copyright 2002 Niels Provos + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef _SYS_TREE_H_ +#define _SYS_TREE_H_ + +/* + * This file defines data structures for different types of trees: + * splay trees and red-black trees. + * + * A splay tree is a self-organizing data structure. Every operation + * on the tree causes a splay to happen. The splay moves the requested + * node to the root of the tree and partly rebalances it. + * + * This has the benefit that request locality causes faster lookups as + * the requested nodes move to the top of the tree. On the other hand, + * every lookup causes memory writes. + * + * The Balance Theorem bounds the total access time for m operations + * and n inserts on an initially empty tree as O((m + n)lg n). The + * amortized cost for a sequence of m accesses to a splay tree is O(lg n); + * + * A red-black tree is a binary search tree with the node color as an + * extra attribute. It fulfills a set of conditions: + * - every search path from the root to a leaf consists of the + * same number of black nodes, + * - each red node (except for the root) has a black parent, + * - each leaf node is black. + * + * Every operation on a red-black tree is bounded as O(lg n). + * The maximum height of a red-black tree is 2lg (n+1). + */ + +#define SPLAY_HEAD(name, type) \ +struct name { \ + struct type *sph_root; /* root of the tree */ \ +} + +#define SPLAY_INITIALIZER(root) \ + { NULL } + +#define SPLAY_INIT(root) do { \ + (root)->sph_root = NULL; \ +} while (0) + +#define SPLAY_ENTRY(type) \ +struct { \ + struct type *spe_left; /* left element */ \ + struct type *spe_right; /* right element */ \ +} + +#define SPLAY_LEFT(elm, field) (elm)->field.spe_left +#define SPLAY_RIGHT(elm, field) (elm)->field.spe_right +#define SPLAY_ROOT(head) (head)->sph_root +#define SPLAY_EMPTY(head) (SPLAY_ROOT(head) == NULL) + +/* SPLAY_ROTATE_{LEFT,RIGHT} expect that tmp hold SPLAY_{RIGHT,LEFT} */ +#define SPLAY_ROTATE_RIGHT(head, tmp, field) do { \ + SPLAY_LEFT((head)->sph_root, field) = SPLAY_RIGHT(tmp, field); \ + SPLAY_RIGHT(tmp, field) = (head)->sph_root; \ + (head)->sph_root = tmp; \ +} while (0) + +#define SPLAY_ROTATE_LEFT(head, tmp, field) do { \ + SPLAY_RIGHT((head)->sph_root, field) = SPLAY_LEFT(tmp, field); \ + SPLAY_LEFT(tmp, field) = (head)->sph_root; \ + (head)->sph_root = tmp; \ +} while (0) + +#define SPLAY_LINKLEFT(head, tmp, field) do { \ + SPLAY_LEFT(tmp, field) = (head)->sph_root; \ + tmp = (head)->sph_root; \ + (head)->sph_root = SPLAY_LEFT((head)->sph_root, field); \ +} while (0) + +#define SPLAY_LINKRIGHT(head, tmp, field) do { \ + SPLAY_RIGHT(tmp, field) = (head)->sph_root; \ + tmp = (head)->sph_root; \ + (head)->sph_root = SPLAY_RIGHT((head)->sph_root, field); \ +} while (0) + +#define SPLAY_ASSEMBLE(head, node, left, right, field) do { \ + SPLAY_RIGHT(left, field) = SPLAY_LEFT((head)->sph_root, field); \ + SPLAY_LEFT(right, field) = SPLAY_RIGHT((head)->sph_root, field);\ + SPLAY_LEFT((head)->sph_root, field) = SPLAY_RIGHT(node, field); \ + SPLAY_RIGHT((head)->sph_root, field) = SPLAY_LEFT(node, field); \ +} while (0) + +/* Generates prototypes and inline functions */ + +#define SPLAY_PROTOTYPE(name, type, field, cmp) \ +void name##_SPLAY(struct name *, struct type *); \ +void name##_SPLAY_MINMAX(struct name *, int); \ +struct type *name##_SPLAY_INSERT(struct name *, struct type *); \ +struct type *name##_SPLAY_REMOVE(struct name *, struct type *); \ + \ +/* Finds the node with the same key as elm */ \ +static __inline struct type * \ +name##_SPLAY_FIND(struct name *head, struct type *elm) \ +{ \ + if (SPLAY_EMPTY(head)) \ + return(NULL); \ + name##_SPLAY(head, elm); \ + if ((cmp)(elm, (head)->sph_root) == 0) \ + return (head->sph_root); \ + return (NULL); \ +} \ + \ +static __inline struct type * \ +name##_SPLAY_NEXT(struct name *head, struct type *elm) \ +{ \ + name##_SPLAY(head, elm); \ + if (SPLAY_RIGHT(elm, field) != NULL) { \ + elm = SPLAY_RIGHT(elm, field); \ + while (SPLAY_LEFT(elm, field) != NULL) { \ + elm = SPLAY_LEFT(elm, field); \ + } \ + } else \ + elm = NULL; \ + return (elm); \ +} \ + \ +static __inline struct type * \ +name##_SPLAY_MIN_MAX(struct name *head, int val) \ +{ \ + name##_SPLAY_MINMAX(head, val); \ + return (SPLAY_ROOT(head)); \ +} + +/* Main splay operation. + * Moves node close to the key of elm to top + */ +#define SPLAY_GENERATE(name, type, field, cmp) \ +struct type * \ +name##_SPLAY_INSERT(struct name *head, struct type *elm) \ +{ \ + if (SPLAY_EMPTY(head)) { \ + SPLAY_LEFT(elm, field) = SPLAY_RIGHT(elm, field) = NULL; \ + } else { \ + int __comp; \ + name##_SPLAY(head, elm); \ + __comp = (cmp)(elm, (head)->sph_root); \ + if(__comp < 0) { \ + SPLAY_LEFT(elm, field) = SPLAY_LEFT((head)->sph_root, field);\ + SPLAY_RIGHT(elm, field) = (head)->sph_root; \ + SPLAY_LEFT((head)->sph_root, field) = NULL; \ + } else if (__comp > 0) { \ + SPLAY_RIGHT(elm, field) = SPLAY_RIGHT((head)->sph_root, field);\ + SPLAY_LEFT(elm, field) = (head)->sph_root; \ + SPLAY_RIGHT((head)->sph_root, field) = NULL; \ + } else \ + return ((head)->sph_root); \ + } \ + (head)->sph_root = (elm); \ + return (NULL); \ +} \ + \ +struct type * \ +name##_SPLAY_REMOVE(struct name *head, struct type *elm) \ +{ \ + struct type *__tmp; \ + if (SPLAY_EMPTY(head)) \ + return (NULL); \ + name##_SPLAY(head, elm); \ + if ((cmp)(elm, (head)->sph_root) == 0) { \ + if (SPLAY_LEFT((head)->sph_root, field) == NULL) { \ + (head)->sph_root = SPLAY_RIGHT((head)->sph_root, field);\ + } else { \ + __tmp = SPLAY_RIGHT((head)->sph_root, field); \ + (head)->sph_root = SPLAY_LEFT((head)->sph_root, field);\ + name##_SPLAY(head, elm); \ + SPLAY_RIGHT((head)->sph_root, field) = __tmp; \ + } \ + return (elm); \ + } \ + return (NULL); \ +} \ + \ +void \ +name##_SPLAY(struct name *head, struct type *elm) \ +{ \ + struct type __node, *__left, *__right, *__tmp; \ + int __comp; \ +\ + SPLAY_LEFT(&__node, field) = SPLAY_RIGHT(&__node, field) = NULL;\ + __left = __right = &__node; \ +\ + while ((__comp = (cmp)(elm, (head)->sph_root))) { \ + if (__comp < 0) { \ + __tmp = SPLAY_LEFT((head)->sph_root, field); \ + if (__tmp == NULL) \ + break; \ + if ((cmp)(elm, __tmp) < 0){ \ + SPLAY_ROTATE_RIGHT(head, __tmp, field); \ + if (SPLAY_LEFT((head)->sph_root, field) == NULL)\ + break; \ + } \ + SPLAY_LINKLEFT(head, __right, field); \ + } else if (__comp > 0) { \ + __tmp = SPLAY_RIGHT((head)->sph_root, field); \ + if (__tmp == NULL) \ + break; \ + if ((cmp)(elm, __tmp) > 0){ \ + SPLAY_ROTATE_LEFT(head, __tmp, field); \ + if (SPLAY_RIGHT((head)->sph_root, field) == NULL)\ + break; \ + } \ + SPLAY_LINKRIGHT(head, __left, field); \ + } \ + } \ + SPLAY_ASSEMBLE(head, &__node, __left, __right, field); \ +} \ + \ +/* Splay with either the minimum or the maximum element \ + * Used to find minimum or maximum element in tree. \ + */ \ +void name##_SPLAY_MINMAX(struct name *head, int __comp) \ +{ \ + struct type __node, *__left, *__right, *__tmp; \ +\ + SPLAY_LEFT(&__node, field) = SPLAY_RIGHT(&__node, field) = NULL;\ + __left = __right = &__node; \ +\ + while (1) { \ + if (__comp < 0) { \ + __tmp = SPLAY_LEFT((head)->sph_root, field); \ + if (__tmp == NULL) \ + break; \ + if (__comp < 0){ \ + SPLAY_ROTATE_RIGHT(head, __tmp, field); \ + if (SPLAY_LEFT((head)->sph_root, field) == NULL)\ + break; \ + } \ + SPLAY_LINKLEFT(head, __right, field); \ + } else if (__comp > 0) { \ + __tmp = SPLAY_RIGHT((head)->sph_root, field); \ + if (__tmp == NULL) \ + break; \ + if (__comp > 0) { \ + SPLAY_ROTATE_LEFT(head, __tmp, field); \ + if (SPLAY_RIGHT((head)->sph_root, field) == NULL)\ + break; \ + } \ + SPLAY_LINKRIGHT(head, __left, field); \ + } \ + } \ + SPLAY_ASSEMBLE(head, &__node, __left, __right, field); \ +} + +#define SPLAY_NEGINF -1 +#define SPLAY_INF 1 + +#define SPLAY_INSERT(name, x, y) name##_SPLAY_INSERT(x, y) +#define SPLAY_REMOVE(name, x, y) name##_SPLAY_REMOVE(x, y) +#define SPLAY_FIND(name, x, y) name##_SPLAY_FIND(x, y) +#define SPLAY_NEXT(name, x, y) name##_SPLAY_NEXT(x, y) +#define SPLAY_MIN(name, x) (SPLAY_EMPTY(x) ? NULL \ + : name##_SPLAY_MIN_MAX(x, SPLAY_NEGINF)) +#define SPLAY_MAX(name, x) (SPLAY_EMPTY(x) ? NULL \ + : name##_SPLAY_MIN_MAX(x, SPLAY_INF)) + +#define SPLAY_FOREACH(x, name, head) \ + for ((x) = SPLAY_MIN(name, head); \ + (x) != NULL; \ + (x) = SPLAY_NEXT(name, head, x)) + +/* Macros that define a red-back tree */ +#define RB_HEAD(name, type) \ +struct name { \ + struct type *rbh_root; /* root of the tree */ \ +} + +#define RB_INITIALIZER(root) \ + { NULL } + +#define RB_INIT(root) do { \ + (root)->rbh_root = NULL; \ +} while (0) + +#define RB_BLACK 0 +#define RB_RED 1 +#define RB_ENTRY(type) \ +struct { \ + struct type *rbe_left; /* left element */ \ + struct type *rbe_right; /* right element */ \ + struct type *rbe_parent; /* parent element */ \ + int rbe_color; /* node color */ \ +} + +#define RB_LEFT(elm, field) (elm)->field.rbe_left +#define RB_RIGHT(elm, field) (elm)->field.rbe_right +#define RB_PARENT(elm, field) (elm)->field.rbe_parent +#define RB_COLOR(elm, field) (elm)->field.rbe_color +#define RB_ROOT(head) (head)->rbh_root +#define RB_EMPTY(head) (RB_ROOT(head) == NULL) + +#define RB_SET(elm, parent, field) do { \ + RB_PARENT(elm, field) = parent; \ + RB_LEFT(elm, field) = RB_RIGHT(elm, field) = NULL; \ + RB_COLOR(elm, field) = RB_RED; \ +} while (0) + +#define RB_SET_BLACKRED(black, red, field) do { \ + RB_COLOR(black, field) = RB_BLACK; \ + RB_COLOR(red, field) = RB_RED; \ +} while (0) + +#ifndef RB_AUGMENT +#define RB_AUGMENT(x) +#endif + +#define RB_ROTATE_LEFT(head, elm, tmp, field) do { \ + (tmp) = RB_RIGHT(elm, field); \ + if ((RB_RIGHT(elm, field) = RB_LEFT(tmp, field))) { \ + RB_PARENT(RB_LEFT(tmp, field), field) = (elm); \ + } \ + RB_AUGMENT(elm); \ + if ((RB_PARENT(tmp, field) = RB_PARENT(elm, field))) { \ + if ((elm) == RB_LEFT(RB_PARENT(elm, field), field)) \ + RB_LEFT(RB_PARENT(elm, field), field) = (tmp); \ + else \ + RB_RIGHT(RB_PARENT(elm, field), field) = (tmp); \ + } else \ + (head)->rbh_root = (tmp); \ + RB_LEFT(tmp, field) = (elm); \ + RB_PARENT(elm, field) = (tmp); \ + RB_AUGMENT(tmp); \ + if ((RB_PARENT(tmp, field))) \ + RB_AUGMENT(RB_PARENT(tmp, field)); \ +} while (0) + +#define RB_ROTATE_RIGHT(head, elm, tmp, field) do { \ + (tmp) = RB_LEFT(elm, field); \ + if ((RB_LEFT(elm, field) = RB_RIGHT(tmp, field))) { \ + RB_PARENT(RB_RIGHT(tmp, field), field) = (elm); \ + } \ + RB_AUGMENT(elm); \ + if ((RB_PARENT(tmp, field) = RB_PARENT(elm, field))) { \ + if ((elm) == RB_LEFT(RB_PARENT(elm, field), field)) \ + RB_LEFT(RB_PARENT(elm, field), field) = (tmp); \ + else \ + RB_RIGHT(RB_PARENT(elm, field), field) = (tmp); \ + } else \ + (head)->rbh_root = (tmp); \ + RB_RIGHT(tmp, field) = (elm); \ + RB_PARENT(elm, field) = (tmp); \ + RB_AUGMENT(tmp); \ + if ((RB_PARENT(tmp, field))) \ + RB_AUGMENT(RB_PARENT(tmp, field)); \ +} while (0) + +/* Generates prototypes and inline functions */ +#define RB_PROTOTYPE(name, type, field, cmp) \ +void name##_RB_INSERT_COLOR(struct name *, struct type *); \ +void name##_RB_REMOVE_COLOR(struct name *, struct type *, struct type *);\ +struct type *name##_RB_REMOVE(struct name *, struct type *); \ +struct type *name##_RB_INSERT(struct name *, struct type *); \ +struct type *name##_RB_FIND(struct name *, struct type *); \ +struct type *name##_RB_NEXT(struct type *); \ +struct type *name##_RB_MINMAX(struct name *, int); \ + \ + +/* Main rb operation. + * Moves node close to the key of elm to top + */ +#define RB_GENERATE(name, type, field, cmp) \ +void \ +name##_RB_INSERT_COLOR(struct name *head, struct type *elm) \ +{ \ + struct type *parent, *gparent, *tmp; \ + while ((parent = RB_PARENT(elm, field)) && \ + RB_COLOR(parent, field) == RB_RED) { \ + gparent = RB_PARENT(parent, field); \ + if (parent == RB_LEFT(gparent, field)) { \ + tmp = RB_RIGHT(gparent, field); \ + if (tmp && RB_COLOR(tmp, field) == RB_RED) { \ + RB_COLOR(tmp, field) = RB_BLACK; \ + RB_SET_BLACKRED(parent, gparent, field);\ + elm = gparent; \ + continue; \ + } \ + if (RB_RIGHT(parent, field) == elm) { \ + RB_ROTATE_LEFT(head, parent, tmp, field);\ + tmp = parent; \ + parent = elm; \ + elm = tmp; \ + } \ + RB_SET_BLACKRED(parent, gparent, field); \ + RB_ROTATE_RIGHT(head, gparent, tmp, field); \ + } else { \ + tmp = RB_LEFT(gparent, field); \ + if (tmp && RB_COLOR(tmp, field) == RB_RED) { \ + RB_COLOR(tmp, field) = RB_BLACK; \ + RB_SET_BLACKRED(parent, gparent, field);\ + elm = gparent; \ + continue; \ + } \ + if (RB_LEFT(parent, field) == elm) { \ + RB_ROTATE_RIGHT(head, parent, tmp, field);\ + tmp = parent; \ + parent = elm; \ + elm = tmp; \ + } \ + RB_SET_BLACKRED(parent, gparent, field); \ + RB_ROTATE_LEFT(head, gparent, tmp, field); \ + } \ + } \ + RB_COLOR(head->rbh_root, field) = RB_BLACK; \ +} \ + \ +void \ +name##_RB_REMOVE_COLOR(struct name *head, struct type *parent, struct type *elm) \ +{ \ + struct type *tmp; \ + while ((elm == NULL || RB_COLOR(elm, field) == RB_BLACK) && \ + elm != RB_ROOT(head)) { \ + if (RB_LEFT(parent, field) == elm) { \ + tmp = RB_RIGHT(parent, field); \ + if (RB_COLOR(tmp, field) == RB_RED) { \ + RB_SET_BLACKRED(tmp, parent, field); \ + RB_ROTATE_LEFT(head, parent, tmp, field);\ + tmp = RB_RIGHT(parent, field); \ + } \ + if ((RB_LEFT(tmp, field) == NULL || \ + RB_COLOR(RB_LEFT(tmp, field), field) == RB_BLACK) &&\ + (RB_RIGHT(tmp, field) == NULL || \ + RB_COLOR(RB_RIGHT(tmp, field), field) == RB_BLACK)) {\ + RB_COLOR(tmp, field) = RB_RED; \ + elm = parent; \ + parent = RB_PARENT(elm, field); \ + } else { \ + if (RB_RIGHT(tmp, field) == NULL || \ + RB_COLOR(RB_RIGHT(tmp, field), field) == RB_BLACK) {\ + struct type *oleft; \ + if ((oleft = RB_LEFT(tmp, field)))\ + RB_COLOR(oleft, field) = RB_BLACK;\ + RB_COLOR(tmp, field) = RB_RED; \ + RB_ROTATE_RIGHT(head, tmp, oleft, field);\ + tmp = RB_RIGHT(parent, field); \ + } \ + RB_COLOR(tmp, field) = RB_COLOR(parent, field);\ + RB_COLOR(parent, field) = RB_BLACK; \ + if (RB_RIGHT(tmp, field)) \ + RB_COLOR(RB_RIGHT(tmp, field), field) = RB_BLACK;\ + RB_ROTATE_LEFT(head, parent, tmp, field);\ + elm = RB_ROOT(head); \ + break; \ + } \ + } else { \ + tmp = RB_LEFT(parent, field); \ + if (RB_COLOR(tmp, field) == RB_RED) { \ + RB_SET_BLACKRED(tmp, parent, field); \ + RB_ROTATE_RIGHT(head, parent, tmp, field);\ + tmp = RB_LEFT(parent, field); \ + } \ + if ((RB_LEFT(tmp, field) == NULL || \ + RB_COLOR(RB_LEFT(tmp, field), field) == RB_BLACK) &&\ + (RB_RIGHT(tmp, field) == NULL || \ + RB_COLOR(RB_RIGHT(tmp, field), field) == RB_BLACK)) {\ + RB_COLOR(tmp, field) = RB_RED; \ + elm = parent; \ + parent = RB_PARENT(elm, field); \ + } else { \ + if (RB_LEFT(tmp, field) == NULL || \ + RB_COLOR(RB_LEFT(tmp, field), field) == RB_BLACK) {\ + struct type *oright; \ + if ((oright = RB_RIGHT(tmp, field)))\ + RB_COLOR(oright, field) = RB_BLACK;\ + RB_COLOR(tmp, field) = RB_RED; \ + RB_ROTATE_LEFT(head, tmp, oright, field);\ + tmp = RB_LEFT(parent, field); \ + } \ + RB_COLOR(tmp, field) = RB_COLOR(parent, field);\ + RB_COLOR(parent, field) = RB_BLACK; \ + if (RB_LEFT(tmp, field)) \ + RB_COLOR(RB_LEFT(tmp, field), field) = RB_BLACK;\ + RB_ROTATE_RIGHT(head, parent, tmp, field);\ + elm = RB_ROOT(head); \ + break; \ + } \ + } \ + } \ + if (elm) \ + RB_COLOR(elm, field) = RB_BLACK; \ +} \ + \ +struct type * \ +name##_RB_REMOVE(struct name *head, struct type *elm) \ +{ \ + struct type *child, *parent, *old = elm; \ + int color; \ + if (RB_LEFT(elm, field) == NULL) \ + child = RB_RIGHT(elm, field); \ + else if (RB_RIGHT(elm, field) == NULL) \ + child = RB_LEFT(elm, field); \ + else { \ + struct type *left; \ + elm = RB_RIGHT(elm, field); \ + while ((left = RB_LEFT(elm, field))) \ + elm = left; \ + child = RB_RIGHT(elm, field); \ + parent = RB_PARENT(elm, field); \ + color = RB_COLOR(elm, field); \ + if (child) \ + RB_PARENT(child, field) = parent; \ + if (parent) { \ + if (RB_LEFT(parent, field) == elm) \ + RB_LEFT(parent, field) = child; \ + else \ + RB_RIGHT(parent, field) = child; \ + RB_AUGMENT(parent); \ + } else \ + RB_ROOT(head) = child; \ + if (RB_PARENT(elm, field) == old) \ + parent = elm; \ + (elm)->field = (old)->field; \ + if (RB_PARENT(old, field)) { \ + if (RB_LEFT(RB_PARENT(old, field), field) == old)\ + RB_LEFT(RB_PARENT(old, field), field) = elm;\ + else \ + RB_RIGHT(RB_PARENT(old, field), field) = elm;\ + RB_AUGMENT(RB_PARENT(old, field)); \ + } else \ + RB_ROOT(head) = elm; \ + RB_PARENT(RB_LEFT(old, field), field) = elm; \ + if (RB_RIGHT(old, field)) \ + RB_PARENT(RB_RIGHT(old, field), field) = elm; \ + if (parent) { \ + left = parent; \ + do { \ + RB_AUGMENT(left); \ + } while ((left = RB_PARENT(left, field))); \ + } \ + goto color; \ + } \ + parent = RB_PARENT(elm, field); \ + color = RB_COLOR(elm, field); \ + if (child) \ + RB_PARENT(child, field) = parent; \ + if (parent) { \ + if (RB_LEFT(parent, field) == elm) \ + RB_LEFT(parent, field) = child; \ + else \ + RB_RIGHT(parent, field) = child; \ + RB_AUGMENT(parent); \ + } else \ + RB_ROOT(head) = child; \ +color: \ + if (color == RB_BLACK) \ + name##_RB_REMOVE_COLOR(head, parent, child); \ + return (old); \ +} \ + \ +/* Inserts a node into the RB tree */ \ +struct type * \ +name##_RB_INSERT(struct name *head, struct type *elm) \ +{ \ + struct type *tmp; \ + struct type *parent = NULL; \ + int comp = 0; \ + tmp = RB_ROOT(head); \ + while (tmp) { \ + parent = tmp; \ + comp = (cmp)(elm, parent); \ + if (comp < 0) \ + tmp = RB_LEFT(tmp, field); \ + else if (comp > 0) \ + tmp = RB_RIGHT(tmp, field); \ + else \ + return (tmp); \ + } \ + RB_SET(elm, parent, field); \ + if (parent != NULL) { \ + if (comp < 0) \ + RB_LEFT(parent, field) = elm; \ + else \ + RB_RIGHT(parent, field) = elm; \ + RB_AUGMENT(parent); \ + } else \ + RB_ROOT(head) = elm; \ + name##_RB_INSERT_COLOR(head, elm); \ + return (NULL); \ +} \ + \ +/* Finds the node with the same key as elm */ \ +struct type * \ +name##_RB_FIND(struct name *head, struct type *elm) \ +{ \ + struct type *tmp = RB_ROOT(head); \ + int comp; \ + while (tmp) { \ + comp = cmp(elm, tmp); \ + if (comp < 0) \ + tmp = RB_LEFT(tmp, field); \ + else if (comp > 0) \ + tmp = RB_RIGHT(tmp, field); \ + else \ + return (tmp); \ + } \ + return (NULL); \ +} \ + \ +struct type * \ +name##_RB_NEXT(struct type *elm) \ +{ \ + if (RB_RIGHT(elm, field)) { \ + elm = RB_RIGHT(elm, field); \ + while (RB_LEFT(elm, field)) \ + elm = RB_LEFT(elm, field); \ + } else { \ + if (RB_PARENT(elm, field) && \ + (elm == RB_LEFT(RB_PARENT(elm, field), field))) \ + elm = RB_PARENT(elm, field); \ + else { \ + while (RB_PARENT(elm, field) && \ + (elm == RB_RIGHT(RB_PARENT(elm, field), field)))\ + elm = RB_PARENT(elm, field); \ + elm = RB_PARENT(elm, field); \ + } \ + } \ + return (elm); \ +} \ + \ +struct type * \ +name##_RB_MINMAX(struct name *head, int val) \ +{ \ + struct type *tmp = RB_ROOT(head); \ + struct type *parent = NULL; \ + while (tmp) { \ + parent = tmp; \ + if (val < 0) \ + tmp = RB_LEFT(tmp, field); \ + else \ + tmp = RB_RIGHT(tmp, field); \ + } \ + return (parent); \ +} + +#define RB_NEGINF -1 +#define RB_INF 1 + +#define RB_INSERT(name, x, y) name##_RB_INSERT(x, y) +#define RB_REMOVE(name, x, y) name##_RB_REMOVE(x, y) +#define RB_FIND(name, x, y) name##_RB_FIND(x, y) +#define RB_NEXT(name, x, y) name##_RB_NEXT(y) +#define RB_MIN(name, x) name##_RB_MINMAX(x, RB_NEGINF) +#define RB_MAX(name, x) name##_RB_MINMAX(x, RB_INF) + +#define RB_FOREACH(x, name, head) \ + for ((x) = RB_MIN(name, head); \ + (x) != NULL; \ + (x) = name##_RB_NEXT(x)) + +#endif /* _SYS_TREE_H_ */ diff --git a/contrib/ntp/arlib/aclocal.m4 b/contrib/ntp/sntp/libevent/aclocal.m4 similarity index 52% rename from contrib/ntp/arlib/aclocal.m4 rename to contrib/ntp/sntp/libevent/aclocal.m4 index fb69e8e2c..3d294974f 100644 --- a/contrib/ntp/arlib/aclocal.m4 +++ b/contrib/ntp/sntp/libevent/aclocal.m4 @@ -1,7 +1,7 @@ -# generated automatically by aclocal 1.11 -*- Autoconf -*- +# generated automatically by aclocal 1.15 -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. @@ -11,15 +11,135 @@ # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. +m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],, -[m4_warning([this file was generated for autoconf 2.65. +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, +[m4_warning([this file was generated for autoconf 2.69. You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. -To do so, use the procedure documented by the package, typically `autoreconf'.])]) +To do so, use the procedure documented by the package, typically 'autoreconf'.])]) + +# serial 9 -*- Autoconf -*- +# Enable extensions on systems that normally disable them. + +# Copyright (C) 2003, 2006-2010 Free Software Foundation, Inc. +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This definition of AC_USE_SYSTEM_EXTENSIONS is stolen from CVS +# Autoconf. Perhaps we can remove this once we can assume Autoconf +# 2.62 or later everywhere, but since CVS Autoconf mutates rapidly +# enough in this area it's likely we'll need to redefine +# AC_USE_SYSTEM_EXTENSIONS for quite some time. + +# If autoconf reports a warning +# warning: AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS +# or warning: AC_RUN_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS +# the fix is +# 1) to ensure that AC_USE_SYSTEM_EXTENSIONS is never directly invoked +# but always AC_REQUIREd, +# 2) to ensure that for each occurrence of +# AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS]) +# or +# AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) +# the corresponding gnulib module description has 'extensions' among +# its dependencies. This will ensure that the gl_USE_SYSTEM_EXTENSIONS +# invocation occurs in gl_EARLY, not in gl_INIT. + +# AC_USE_SYSTEM_EXTENSIONS +# ------------------------ +# Enable extensions on systems that normally disable them, +# typically due to standards-conformance issues. +# Remember that #undef in AH_VERBATIM gets replaced with #define by +# AC_DEFINE. The goal here is to define all known feature-enabling +# macros, then, if reports of conflicts are made, disable macros that +# cause problems on some platforms (such as __EXTENSIONS__). +AC_DEFUN_ONCE([AC_USE_SYSTEM_EXTENSIONS], +[AC_BEFORE([$0], [AC_COMPILE_IFELSE])dnl +AC_BEFORE([$0], [AC_RUN_IFELSE])dnl + + AC_REQUIRE([AC_CANONICAL_HOST]) + + AC_CHECK_HEADER([minix/config.h], [MINIX=yes], [MINIX=]) + if test "$MINIX" = yes; then + AC_DEFINE([_POSIX_SOURCE], [1], + [Define to 1 if you need to in order for `stat' and other + things to work.]) + AC_DEFINE([_POSIX_1_SOURCE], [2], + [Define to 2 if the system does not provide POSIX.1 features + except with this defined.]) + AC_DEFINE([_MINIX], [1], + [Define to 1 if on MINIX.]) + fi -# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. + dnl HP-UX 11.11 defines mbstate_t only if _XOPEN_SOURCE is defined to 500, + dnl regardless of whether the flags -Ae or _D_HPUX_SOURCE=1 are already + dnl provided. + case "$host_os" in + hpux*) + AC_DEFINE([_XOPEN_SOURCE], [500], + [Define to 500 only on HP-UX.]) + ;; + esac + + AH_VERBATIM([__EXTENSIONS__], +[/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# undef _GNU_SOURCE +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# undef _POSIX_PTHREAD_SEMANTICS +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# undef _TANDEM_SOURCE +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# undef __EXTENSIONS__ +#endif +]) + AC_CACHE_CHECK([whether it is safe to define __EXTENSIONS__], + [ac_cv_safe_to_define___extensions__], + [AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[ +# define __EXTENSIONS__ 1 + ]AC_INCLUDES_DEFAULT])], + [ac_cv_safe_to_define___extensions__=yes], + [ac_cv_safe_to_define___extensions__=no])]) + test $ac_cv_safe_to_define___extensions__ = yes && + AC_DEFINE([__EXTENSIONS__]) + AC_DEFINE([_ALL_SOURCE]) + AC_DEFINE([_GNU_SOURCE]) + AC_DEFINE([_POSIX_PTHREAD_SEMANTICS]) + AC_DEFINE([_TANDEM_SOURCE]) +])# AC_USE_SYSTEM_EXTENSIONS + +# gl_USE_SYSTEM_EXTENSIONS +# ------------------------ +# Enable extensions on systems that normally disable them, +# typically due to standards-conformance issues. +AC_DEFUN_ONCE([gl_USE_SYSTEM_EXTENSIONS], +[ + dnl Require this macro before AC_USE_SYSTEM_EXTENSIONS. + dnl gnulib does not need it. But if it gets required by third-party macros + dnl after AC_USE_SYSTEM_EXTENSIONS is required, autoconf 2.62..2.63 emit a + dnl warning: "AC_COMPILE_IFELSE was called before AC_USE_SYSTEM_EXTENSIONS". + dnl Note: We can do this only for one of the macros AC_AIX, AC_GNU_SOURCE, + dnl AC_MINIX. If people still use AC_AIX or AC_MINIX, they are out of luck. + AC_REQUIRE([AC_GNU_SOURCE]) + + AC_REQUIRE([AC_USE_SYSTEM_EXTENSIONS]) +]) + +# Copyright (C) 2002-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -31,10 +151,10 @@ To do so, use the procedure documented by the package, typically `autoreconf'.]) # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.11' +[am__api_version='1.15' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.11], [], +m4_if([$1], [1.15], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -50,22 +170,22 @@ m4_define([_AM_AUTOCONF_VERSION], []) # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.11])dnl +[AM_AUTOMAKE_VERSION([1.15])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets -# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to -# `$srcdir', `$srcdir/..', or `$srcdir/../..'. +# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to +# '$srcdir', '$srcdir/..', or '$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and @@ -84,7 +204,7 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually -# harmless because $srcdir is `.', but things will broke when you +# harmless because $srcdir is '.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, @@ -102,30 +222,26 @@ _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], -[dnl Rely on autoconf to set up CDPATH properly. -AC_PREREQ([2.50])dnl -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` +[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- -# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 9 - # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], -[AC_PREREQ(2.52)dnl - ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], - [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl +[AC_PREREQ([2.52])dnl + m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE])dnl AC_SUBST([$1_FALSE])dnl _AM_SUBST_NOTMAKE([$1_TRUE])dnl @@ -144,16 +260,14 @@ AC_CONFIG_COMMANDS_PRE( Usually this means the macro was only invoked conditionally.]]) fi])]) -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 -# Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 10 -# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be +# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing @@ -163,7 +277,7 @@ fi])]) # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. -# NAME is "CC", "CXX", "GCJ", or "OBJC". +# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was @@ -176,12 +290,13 @@ AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl -ifelse([$1], CC, [depcc="$CC" am_compiler_list=], - [$1], CXX, [depcc="$CXX" am_compiler_list=], - [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], - [$1], UPC, [depcc="$UPC" am_compiler_list=], - [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], - [depcc="$$1" am_compiler_list=]) +m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], + [$1], [CXX], [depcc="$CXX" am_compiler_list=], + [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], + [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], + [$1], [UPC], [depcc="$UPC" am_compiler_list=], + [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], + [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], @@ -189,8 +304,9 @@ AC_CACHE_CHECK([dependency style of $depcc], # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -229,16 +345,16 @@ AC_CACHE_CHECK([dependency style of $depcc], : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with `-c' and `-o' for the sake of the "dashmstdout" + # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in @@ -247,16 +363,16 @@ AC_CACHE_CHECK([dependency style of $depcc], test "$am__universal" = false || continue ;; nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} @@ -304,7 +420,7 @@ AM_CONDITIONAL([am__fastdep$1], [ # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. -# This macro is AC_REQUIREd in _AM_DEPENDENCIES +# This macro is AC_REQUIREd in _AM_DEPENDENCIES. AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl @@ -314,34 +430,39 @@ AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], -[AC_ARG_ENABLE(dependency-tracking, -[ --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors]) +[AC_ARG_ENABLE([dependency-tracking], [dnl +AS_HELP_STRING( + [--enable-dependency-tracking], + [do not reject slow dependency extractors]) +AS_HELP_STRING( + [--disable-dependency-tracking], + [speeds up one-time build])]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' + am__nodep='_no' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl +AC_SUBST([am__nodep])dnl +_AM_SUBST_NOTMAKE([am__nodep])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1999-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -#serial 5 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [{ - # Autoconf 2.62 quotes --file arguments for eval, but not when files + # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. case $CONFIG_FILES in @@ -354,7 +475,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but + # We used to match only the files named 'Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. @@ -366,21 +487,19 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], continue fi # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. + # from the Makefile without running 'make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue + test -z "$am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` @@ -398,7 +517,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking -# is enabled. FIXME. This creates each `.P' file that we will +# is enabled. FIXME. This creates each '.P' file that we will # need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], @@ -408,18 +527,21 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], # Do all the work for Automake. -*- Autoconf -*- -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. +# Copyright (C) 1996-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 16 - # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. +dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. +m4_define([AC_PROG_CC], +m4_defn([AC_PROG_CC]) +[_AM_PROG_CC_C_O +]) + # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- @@ -432,7 +554,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], -[AC_PREREQ([2.62])dnl +[AC_PREREQ([2.65])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl @@ -461,33 +583,42 @@ AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], -[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl +[AC_DIAGNOSE([obsolete], + [$0: two- and three-arguments forms are deprecated.]) +m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. -m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, +m4_if( + m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), + [ok:ok],, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, -[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) - AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl +[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) + AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl -AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) -AM_MISSING_PROG(AUTOCONF, autoconf) -AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) -AM_MISSING_PROG(AUTOHEADER, autoheader) -AM_MISSING_PROG(MAKEINFO, makeinfo) +AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) +AM_MISSING_PROG([AUTOCONF], [autoconf]) +AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) +AM_MISSING_PROG([AUTOHEADER], [autoheader]) +AM_MISSING_PROG([MAKEINFO], [makeinfo]) AC_REQUIRE([AM_PROG_INSTALL_SH])dnl AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl -AC_REQUIRE([AM_PROG_MKDIR_P])dnl -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. +AC_REQUIRE([AC_PROG_MKDIR_P])dnl +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +AC_SUBST([mkdir_p], ['$(MKDIR_P)']) +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl @@ -496,34 +627,82 @@ _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], - [_AM_DEPENDENCIES(CC)], - [define([AC_PROG_CC], - defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl + [_AM_DEPENDENCIES([CC])], + [m4_define([AC_PROG_CC], + m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], - [_AM_DEPENDENCIES(CXX)], - [define([AC_PROG_CXX], - defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl + [_AM_DEPENDENCIES([CXX])], + [m4_define([AC_PROG_CXX], + m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], - [_AM_DEPENDENCIES(OBJC)], - [define([AC_PROG_OBJC], - defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl + [_AM_DEPENDENCIES([OBJC])], + [m4_define([AC_PROG_OBJC], + m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], + [_AM_DEPENDENCIES([OBJCXX])], + [m4_define([AC_PROG_OBJCXX], + m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl ]) -_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl -dnl The `parallel-tests' driver may need to know about EXEEXT, so add the -dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro -dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. +AC_REQUIRE([AM_SILENT_RULES])dnl +dnl The testsuite driver may need to know about EXEEXT, so add the +dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This +dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. AC_CONFIG_COMMANDS_PRE(dnl [m4_provide_if([_AM_COMPILER_EXEEXT], [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) + fi +fi +dnl The trailing newline in this macro's definition is deliberate, for +dnl backward compatibility and to allow trailing 'dnl'-style comments +dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. ]) -dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not +dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further dnl mangled by Autoconf and run in a shell conditional statement. m4_define([_AC_COMPILER_EXEEXT], m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) - # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. @@ -545,7 +724,7 @@ for _am_header in $config_headers :; do done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) -# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -556,7 +735,7 @@ echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_co # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -if test x"${install_sh}" != xset; then +if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; @@ -564,16 +743,14 @@ if test x"${install_sh}" != xset; then install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi -AC_SUBST(install_sh)]) +AC_SUBST([install_sh])]) -# Copyright (C) 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2003-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], @@ -589,14 +766,12 @@ AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- -# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 4 - # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. @@ -614,7 +789,7 @@ am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. +# Ignore all kinds of additional output from 'make'. case `$am_make -s -f confmf 2> /dev/null` in #( *the\ am__doit\ target*) am__include=include @@ -641,15 +816,12 @@ rm -f confinc confmf # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- -# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. +# Copyright (C) 1997-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 6 - # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], @@ -657,11 +829,10 @@ AC_DEFUN([AM_MISSING_PROG], $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) - # AM_MISSING_HAS_RUN # ------------------ -# Define MISSING if not defined so far and test if it supports --run. -# If it does, set am_missing_run to use it, otherwise, to nothing. +# Define MISSING if not defined so far and test if it is modern enough. +# If it is, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl @@ -674,63 +845,35 @@ if test x"${MISSING+set}" != xset; then esac fi # Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " else am_missing_run= - AC_MSG_WARN([`missing' script is too old or missing]) + AC_MSG_WARN(['missing' script is too old or missing]) fi ]) -# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_MKDIR_P -# --------------- -# Check for `mkdir -p'. -AC_DEFUN([AM_PROG_MKDIR_P], -[AC_PREREQ([2.60])dnl -AC_REQUIRE([AC_PROG_MKDIR_P])dnl -dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, -dnl while keeping a definition of mkdir_p for backward compatibility. -dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. -dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of -dnl Makefile.ins that do not define MKDIR_P, so we do our own -dnl adjustment using top_builddir (which is defined more often than -dnl MKDIR_P). -AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl -case $mkdir_p in - [[\\/$]]* | ?:[[\\/]]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; -esac -]) - # Helper functions for option handling. -*- Autoconf -*- -# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 4 - # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) -# ------------------------------ +# -------------------- # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], -[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) +[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) # _AM_SET_OPTIONS(OPTIONS) -# ---------------------------------- +# ------------------------ # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) @@ -741,24 +884,82 @@ AC_DEFUN([_AM_SET_OPTIONS], AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Check to make sure that the build environment is sane. -*- Autoconf -*- +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 -# Free Software Foundation, Inc. +# _AM_PROG_CC_C_O +# --------------- +# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC +# to automatically call this. +AC_DEFUN([_AM_PROG_CC_C_O], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([compile])dnl +AC_LANG_PUSH([C])dnl +AC_CACHE_CHECK( + [whether $CC understands -c and -o together], + [am_cv_prog_cc_c_o], + [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i]) +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +AC_LANG_POP([C])]) + +# For backward compatibility. +AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 5 +# AM_RUN_LOG(COMMAND) +# ------------------- +# Run COMMAND, save the exit status in ac_status, and log it. +# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) +AC_DEFUN([AM_RUN_LOG], +[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD + ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + (exit $ac_status); }]) + +# Check to make sure that the build environment is sane. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) -# Just in case -sleep 1 -echo timestamp > conftest.file # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' @@ -769,32 +970,40 @@ case `pwd` in esac case $srcdir in *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) - AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; + AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; esac -# Do `set' in a subshell so we don't clobber the current shell's +# Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$[*]" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$[*]" != "X $srcdir/configure conftest.file" \ - && test "$[*]" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken -alias in your environment]) - fi - + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[*]" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$[*]" != "X $srcdir/configure conftest.file" \ + && test "$[*]" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken + alias in your environment]) + fi + if test "$[2]" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done test "$[2]" = conftest.file ) then @@ -804,9 +1013,85 @@ else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi -AC_MSG_RESULT(yes)]) +AC_MSG_RESULT([yes]) +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi +AC_CONFIG_COMMANDS_PRE( + [AC_MSG_CHECKING([that generated files are newer than configure]) + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + AC_MSG_RESULT([done])]) +rm -f conftest.file +]) + +# Copyright (C) 2009-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Enable less verbose build rules; with the default set to DEFAULT +# ("yes" being less verbose, "no" or empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_ARG_ENABLE([silent-rules], [dnl +AS_HELP_STRING( + [--enable-silent-rules], + [less verbose build output (undo: "make V=1")]) +AS_HELP_STRING( + [--disable-silent-rules], + [verbose build output (undo: "make V=0")])dnl +]) +case $enable_silent_rules in @%:@ ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; +esac +dnl +dnl A few 'make' implementations (e.g., NonStop OS and NextStep) +dnl do not support nested variable expansions. +dnl See automake bug#9928 and bug#10237. +am_make=${MAKE-make} +AC_CACHE_CHECK([whether $am_make supports nested variables], + [am_cv_make_support_nested_variables], + [if AS_ECHO([['TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi]) +if test $am_cv_make_support_nested_variables = yes; then + dnl Using '$V' instead of '$(V)' breaks IRIX make. + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AC_SUBST([AM_V])dnl +AM_SUBST_NOTMAKE([AM_V])dnl +AC_SUBST([AM_DEFAULT_V])dnl +AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl +AC_SUBST([AM_DEFAULT_VERBOSITY])dnl +AM_BACKSLASH='\' +AC_SUBST([AM_BACKSLASH])dnl +_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +]) -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. +# Copyright (C) 2001-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -814,34 +1099,32 @@ AC_MSG_RESULT(yes)]) # AM_PROG_INSTALL_STRIP # --------------------- -# One issue with vendor `install' (even GNU) is that you can't +# One issue with vendor 'install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we -# always use install-sh in `make install-strip', and initialize +# always use install-sh in "make install-strip", and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. -dnl Don't test for $cross_compiling = yes, because it might be `maybe'. +# will honor the 'STRIP' environment variable to overrule this program. +dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) -# Copyright (C) 2006, 2008 Free Software Foundation, Inc. +# Copyright (C) 2006-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # _AM_SUBST_NOTMAKE(VARIABLE) # --------------------------- # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. @@ -849,24 +1132,22 @@ AC_SUBST([INSTALL_STRIP_PROGRAM])]) AC_DEFUN([_AM_SUBST_NOTMAKE]) # AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- +# -------------------------- # Public sister of _AM_SUBST_NOTMAKE. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- -# Copyright (C) 2004, 2005 Free Software Foundation, Inc. +# Copyright (C) 2004-2014 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# serial 2 - # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. -# FORMAT should be one of `v7', `ustar', or `pax'. +# FORMAT should be one of 'v7', 'ustar', or 'pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory @@ -876,76 +1157,124 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar +# AC_DEFUN([_AM_PROG_TAR], -[# Always define AMTAR for backward compatibility. -AM_MISSING_PROG([AMTAR], [tar]) -m4_if([$1], [v7], - [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], - [m4_case([$1], [ustar],, [pax],, - [m4_fatal([Unknown tar format])]) -AC_MSG_CHECKING([how to create a $1 tar archive]) -# Loop over all known methods to create a tar archive until one works. +[# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AC_SUBST([AMTAR], ['$${TAR-tar}']) + +# We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' -_am_tools=${am_cv_prog_tar_$1-$_am_tools} -# Do not fold the above two line into one, because Tru64 sh and -# Solaris sh will not grok spaces in the rhs of `-'. -for _am_tool in $_am_tools -do - case $_am_tool in - gnutar) - for _am_tar in tar gnutar gtar; - do - AM_RUN_LOG([$_am_tar --version]) && break - done - am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' - am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' - am__untar="$_am_tar -xf -" - ;; - plaintar) - # Must skip GNU tar: if it does not support --format= it doesn't create - # ustar tarball either. - (tar --version) >/dev/null 2>&1 && continue - am__tar='tar chf - "$$tardir"' - am__tar_='tar chf - "$tardir"' - am__untar='tar xf -' - ;; - pax) - am__tar='pax -L -x $1 -w "$$tardir"' - am__tar_='pax -L -x $1 -w "$tardir"' - am__untar='pax -r' - ;; - cpio) - am__tar='find "$$tardir" -print | cpio -o -H $1 -L' - am__tar_='find "$tardir" -print | cpio -o -H $1 -L' - am__untar='cpio -i -H $1 -d' - ;; - none) - am__tar=false - am__tar_=false - am__untar=false - ;; - esac - # If the value was cached, stop now. We just wanted to have am__tar - # and am__untar set. - test -n "${am_cv_prog_tar_$1}" && break +m4_if([$1], [v7], + [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], + + [m4_case([$1], + [ustar], + [# The POSIX 1988 'ustar' format is defined with fixed-size fields. + # There is notably a 21 bits limit for the UID and the GID. In fact, + # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 + # and bug#13588). + am_max_uid=2097151 # 2^21 - 1 + am_max_gid=$am_max_uid + # The $UID and $GID variables are not portable, so we need to resort + # to the POSIX-mandated id(1) utility. Errors in the 'id' calls + # below are definitely unexpected, so allow the users to see them + # (that is, avoid stderr redirection). + am_uid=`id -u || echo unknown` + am_gid=`id -g || echo unknown` + AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) + if test $am_uid -le $am_max_uid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi + AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) + if test $am_gid -le $am_max_gid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi], + + [pax], + [], + + [m4_fatal([Unknown tar format])]) + + AC_MSG_CHECKING([how to create a $1 tar archive]) + + # Go ahead even if we have the value already cached. We do so because we + # need to set the values for the 'am__tar' and 'am__untar' variables. + _am_tools=${am_cv_prog_tar_$1-$_am_tools} + + for _am_tool in $_am_tools; do + case $_am_tool in + gnutar) + for _am_tar in tar gnutar gtar; do + AM_RUN_LOG([$_am_tar --version]) && break + done + am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' + am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' + am__untar="$_am_tar -xf -" + ;; + plaintar) + # Must skip GNU tar: if it does not support --format= it doesn't create + # ustar tarball either. + (tar --version) >/dev/null 2>&1 && continue + am__tar='tar chf - "$$tardir"' + am__tar_='tar chf - "$tardir"' + am__untar='tar xf -' + ;; + pax) + am__tar='pax -L -x $1 -w "$$tardir"' + am__tar_='pax -L -x $1 -w "$tardir"' + am__untar='pax -r' + ;; + cpio) + am__tar='find "$$tardir" -print | cpio -o -H $1 -L' + am__tar_='find "$tardir" -print | cpio -o -H $1 -L' + am__untar='cpio -i -H $1 -d' + ;; + none) + am__tar=false + am__tar_=false + am__untar=false + ;; + esac - # tar/untar a dummy directory, and stop if the command works - rm -rf conftest.dir - mkdir conftest.dir - echo GrepMe > conftest.dir/file - AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + # If the value was cached, stop now. We just wanted to have am__tar + # and am__untar set. + test -n "${am_cv_prog_tar_$1}" && break + + # tar/untar a dummy directory, and stop if the command works. + rm -rf conftest.dir + mkdir conftest.dir + echo GrepMe > conftest.dir/file + AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + rm -rf conftest.dir + if test -s conftest.tar; then + AM_RUN_LOG([$am__untar /dev/null 2>&1 && break + fi + done rm -rf conftest.dir - if test -s conftest.tar; then - AM_RUN_LOG([$am__untar /dev/null 2>&1 && break - fi -done -rm -rf conftest.dir -AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) -AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) + AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR +m4_include([m4/ac_backport_259_ssizet.m4]) +m4_include([m4/acx_pthread.m4]) +m4_include([m4/libevent_openssl.m4]) +m4_include([m4/libtool.m4]) +m4_include([m4/ltoptions.m4]) +m4_include([m4/ltsugar.m4]) +m4_include([m4/ltversion.m4]) +m4_include([m4/lt~obsolete.m4]) +m4_include([m4/ntp_pkg_config.m4]) diff --git a/contrib/ntp/sntp/libevent/arc4random.c b/contrib/ntp/sntp/libevent/arc4random.c new file mode 100644 index 000000000..a2338e692 --- /dev/null +++ b/contrib/ntp/sntp/libevent/arc4random.c @@ -0,0 +1,556 @@ +/* Portable arc4random.c based on arc4random.c from OpenBSD. + * Portable version by Chris Davis, adapted for Libevent by Nick Mathewson + * Copyright (c) 2010 Chris Davis, Niels Provos, and Nick Mathewson + * Copyright (c) 2010-2012 Niels Provos and Nick Mathewson + * + * Note that in Libevent, this file isn't compiled directly. Instead, + * it's included from evutil_rand.c + */ + +/* + * Copyright (c) 1996, David Mazieres + * Copyright (c) 2008, Damien Miller + * + * Permission to use, copy, modify, and distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +/* + * Arc4 random number generator for OpenBSD. + * + * This code is derived from section 17.1 of Applied Cryptography, + * second edition, which describes a stream cipher allegedly + * compatible with RSA Labs "RC4" cipher (the actual description of + * which is a trade secret). The same algorithm is used as a stream + * cipher called "arcfour" in Tatu Ylonen's ssh package. + * + * Here the stream cipher has been modified always to include the time + * when initializing the state. That makes it impossible to + * regenerate the same random sequence twice, so this can't be used + * for encryption, but will generate good random numbers. + * + * RC4 is a registered trademark of RSA Laboratories. + */ + +#ifndef ARC4RANDOM_EXPORT +#define ARC4RANDOM_EXPORT +#endif + +#ifndef ARC4RANDOM_UINT32 +#define ARC4RANDOM_UINT32 uint32_t +#endif + +#ifndef ARC4RANDOM_NO_INCLUDES +#include "evconfig-private.h" +#ifdef _WIN32 +#include +#include +#else +#include +#include +#include +#include +#ifdef EVENT__HAVE_SYS_SYSCTL_H +#include +#endif +#endif +#include +#include +#include +#endif + +/* Add platform entropy 32 bytes (256 bits) at a time. */ +#define ADD_ENTROPY 32 + +/* Re-seed from the platform RNG after generating this many bytes. */ +#define BYTES_BEFORE_RESEED 1600000 + +struct arc4_stream { + unsigned char i; + unsigned char j; + unsigned char s[256]; +}; + +#ifdef _WIN32 +#define getpid _getpid +#define pid_t int +#endif + +static int rs_initialized; +static struct arc4_stream rs; +static pid_t arc4_stir_pid; +static int arc4_count; +static int arc4_seeded_ok; + +static inline unsigned char arc4_getbyte(void); + +static inline void +arc4_init(void) +{ + int n; + + for (n = 0; n < 256; n++) + rs.s[n] = n; + rs.i = 0; + rs.j = 0; +} + +static inline void +arc4_addrandom(const unsigned char *dat, int datlen) +{ + int n; + unsigned char si; + + rs.i--; + for (n = 0; n < 256; n++) { + rs.i = (rs.i + 1); + si = rs.s[rs.i]; + rs.j = (rs.j + si + dat[n % datlen]); + rs.s[rs.i] = rs.s[rs.j]; + rs.s[rs.j] = si; + } + rs.j = rs.i; +} + +#ifndef _WIN32 +static ssize_t +read_all(int fd, unsigned char *buf, size_t count) +{ + size_t numread = 0; + ssize_t result; + + while (numread < count) { + result = read(fd, buf+numread, count-numread); + if (result<0) + return -1; + else if (result == 0) + break; + numread += result; + } + + return (ssize_t)numread; +} +#endif + +#ifdef _WIN32 +#define TRY_SEED_WIN32 +static int +arc4_seed_win32(void) +{ + /* This is adapted from Tor's crypto_seed_rng() */ + static int provider_set = 0; + static HCRYPTPROV provider; + unsigned char buf[ADD_ENTROPY]; + + if (!provider_set) { + if (!CryptAcquireContext(&provider, NULL, NULL, PROV_RSA_FULL, + CRYPT_VERIFYCONTEXT)) { + if (GetLastError() != (DWORD)NTE_BAD_KEYSET) + return -1; + } + provider_set = 1; + } + if (!CryptGenRandom(provider, sizeof(buf), buf)) + return -1; + arc4_addrandom(buf, sizeof(buf)); + evutil_memclear_(buf, sizeof(buf)); + arc4_seeded_ok = 1; + return 0; +} +#endif + +#if defined(EVENT__HAVE_SYS_SYSCTL_H) && defined(EVENT__HAVE_SYSCTL) +#if EVENT__HAVE_DECL_CTL_KERN && EVENT__HAVE_DECL_KERN_RANDOM && EVENT__HAVE_DECL_RANDOM_UUID +#define TRY_SEED_SYSCTL_LINUX +static int +arc4_seed_sysctl_linux(void) +{ + /* Based on code by William Ahern, this function tries to use the + * RANDOM_UUID sysctl to get entropy from the kernel. This can work + * even if /dev/urandom is inaccessible for some reason (e.g., we're + * running in a chroot). */ + int mib[] = { CTL_KERN, KERN_RANDOM, RANDOM_UUID }; + unsigned char buf[ADD_ENTROPY]; + size_t len, n; + unsigned i; + int any_set; + + memset(buf, 0, sizeof(buf)); + + for (len = 0; len < sizeof(buf); len += n) { + n = sizeof(buf) - len; + + if (0 != sysctl(mib, 3, &buf[len], &n, NULL, 0)) + return -1; + } + /* make sure that the buffer actually got set. */ + for (i=0,any_set=0; i sizeof(buf)) + n = len - sizeof(buf); + if (sysctl(mib, 2, &buf[len], &n, NULL, 0) == -1) + return -1; + } + } + /* make sure that the buffer actually got set. */ + for (i=any_set=0; i 0xffffffffUL) + min = 0x100000000UL % upper_bound; +#else + /* Calculate (2**32 % upper_bound) avoiding 64-bit math */ + if (upper_bound > 0x80000000) + min = 1 + ~upper_bound; /* 2**32 - upper_bound */ + else { + /* (2**32 - (x * 2)) % x == 2**32 % x when x <= 2**31 */ + min = ((0xffffffff - (upper_bound * 2)) + 1) % upper_bound; + } +#endif + + /* + * This could theoretically loop forever but each retry has + * p > 0.5 (worst case, usually far better) of selecting a + * number inside the range we need, so it should rarely need + * to re-roll. + */ + for (;;) { + r = arc4random(); + if (r >= min) + break; + } + + return r % upper_bound; +} +#endif diff --git a/contrib/ntp/sntp/libevent/autogen.sh b/contrib/ntp/sntp/libevent/autogen.sh new file mode 100755 index 000000000..57eeb940b --- /dev/null +++ b/contrib/ntp/sntp/libevent/autogen.sh @@ -0,0 +1,15 @@ +#!/bin/sh +if [ -x "`which autoreconf 2>/dev/null`" ] ; then + exec autoreconf -ivf +fi + +LIBTOOLIZE=libtoolize +SYSNAME=`uname` +if [ "x$SYSNAME" = "xDarwin" ] ; then + LIBTOOLIZE=glibtoolize +fi +aclocal -I m4 && \ + autoheader && \ + $LIBTOOLIZE && \ + autoconf && \ + automake --add-missing --force-missing --copy diff --git a/contrib/ntp/sntp/libevent/buffer.c b/contrib/ntp/sntp/libevent/buffer.c new file mode 100644 index 000000000..a1a2b988c --- /dev/null +++ b/contrib/ntp/sntp/libevent/buffer.c @@ -0,0 +1,3439 @@ +/* + * Copyright (c) 2002-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#include +#include +#include +#endif + +#ifdef EVENT__HAVE_VASPRINTF +/* If we have vasprintf, we need to define _GNU_SOURCE before we include + * stdio.h. This comes from evconfig-private.h. + */ +#endif + +#include + +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif + +#ifdef EVENT__HAVE_SYS_UIO_H +#include +#endif + +#ifdef EVENT__HAVE_SYS_IOCTL_H +#include +#endif + +#ifdef EVENT__HAVE_SYS_MMAN_H +#include +#endif + +#ifdef EVENT__HAVE_SYS_SENDFILE_H +#include +#endif +#ifdef EVENT__HAVE_SYS_STAT_H +#include +#endif + + +#include +#include +#include +#include +#ifdef EVENT__HAVE_STDARG_H +#include +#endif +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#include + +#include "event2/event.h" +#include "event2/buffer.h" +#include "event2/buffer_compat.h" +#include "event2/bufferevent.h" +#include "event2/bufferevent_compat.h" +#include "event2/bufferevent_struct.h" +#include "event2/thread.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "util-internal.h" +#include "evthread-internal.h" +#include "evbuffer-internal.h" +#include "bufferevent-internal.h" + +/* some systems do not have MAP_FAILED */ +#ifndef MAP_FAILED +#define MAP_FAILED ((void *)-1) +#endif + +/* send file support */ +#if defined(EVENT__HAVE_SYS_SENDFILE_H) && defined(EVENT__HAVE_SENDFILE) && defined(__linux__) +#define USE_SENDFILE 1 +#define SENDFILE_IS_LINUX 1 +#elif defined(EVENT__HAVE_SENDFILE) && defined(__FreeBSD__) +#define USE_SENDFILE 1 +#define SENDFILE_IS_FREEBSD 1 +#elif defined(EVENT__HAVE_SENDFILE) && defined(__APPLE__) +#define USE_SENDFILE 1 +#define SENDFILE_IS_MACOSX 1 +#elif defined(EVENT__HAVE_SENDFILE) && defined(__sun__) && defined(__svr4__) +#define USE_SENDFILE 1 +#define SENDFILE_IS_SOLARIS 1 +#endif + +/* Mask of user-selectable callback flags. */ +#define EVBUFFER_CB_USER_FLAGS 0xffff +/* Mask of all internal-use-only flags. */ +#define EVBUFFER_CB_INTERNAL_FLAGS 0xffff0000 + +/* Flag set if the callback is using the cb_obsolete function pointer */ +#define EVBUFFER_CB_OBSOLETE 0x00040000 + +/* evbuffer_chain support */ +#define CHAIN_SPACE_PTR(ch) ((ch)->buffer + (ch)->misalign + (ch)->off) +#define CHAIN_SPACE_LEN(ch) ((ch)->flags & EVBUFFER_IMMUTABLE ? \ + 0 : (ch)->buffer_len - ((ch)->misalign + (ch)->off)) + +#define CHAIN_PINNED(ch) (((ch)->flags & EVBUFFER_MEM_PINNED_ANY) != 0) +#define CHAIN_PINNED_R(ch) (((ch)->flags & EVBUFFER_MEM_PINNED_R) != 0) + +/* evbuffer_ptr support */ +#define PTR_NOT_FOUND(ptr) do { \ + (ptr)->pos = -1; \ + (ptr)->internal_.chain = NULL; \ + (ptr)->internal_.pos_in_chain = 0; \ +} while (0) + +static void evbuffer_chain_align(struct evbuffer_chain *chain); +static int evbuffer_chain_should_realign(struct evbuffer_chain *chain, + size_t datalen); +static void evbuffer_deferred_callback(struct event_callback *cb, void *arg); +static int evbuffer_ptr_memcmp(const struct evbuffer *buf, + const struct evbuffer_ptr *pos, const char *mem, size_t len); +static struct evbuffer_chain *evbuffer_expand_singlechain(struct evbuffer *buf, + size_t datlen); +static int evbuffer_ptr_subtract(struct evbuffer *buf, struct evbuffer_ptr *pos, + size_t howfar); +static int evbuffer_file_segment_materialize(struct evbuffer_file_segment *seg); +static inline void evbuffer_chain_incref(struct evbuffer_chain *chain); + +static struct evbuffer_chain * +evbuffer_chain_new(size_t size) +{ + struct evbuffer_chain *chain; + size_t to_alloc; + + if (size > EVBUFFER_CHAIN_MAX - EVBUFFER_CHAIN_SIZE) + return (NULL); + + size += EVBUFFER_CHAIN_SIZE; + + /* get the next largest memory that can hold the buffer */ + if (size < EVBUFFER_CHAIN_MAX / 2) { + to_alloc = MIN_BUFFER_SIZE; + while (to_alloc < size) { + to_alloc <<= 1; + } + } else { + to_alloc = size; + } + + /* we get everything in one chunk */ + if ((chain = mm_malloc(to_alloc)) == NULL) + return (NULL); + + memset(chain, 0, EVBUFFER_CHAIN_SIZE); + + chain->buffer_len = to_alloc - EVBUFFER_CHAIN_SIZE; + + /* this way we can manipulate the buffer to different addresses, + * which is required for mmap for example. + */ + chain->buffer = EVBUFFER_CHAIN_EXTRA(u_char, chain); + + chain->refcnt = 1; + + return (chain); +} + +static inline void +evbuffer_chain_free(struct evbuffer_chain *chain) +{ + EVUTIL_ASSERT(chain->refcnt > 0); + if (--chain->refcnt > 0) { + /* chain is still referenced by other chains */ + return; + } + + if (CHAIN_PINNED(chain)) { + /* will get freed once no longer dangling */ + chain->refcnt++; + chain->flags |= EVBUFFER_DANGLING; + return; + } + + /* safe to release chain, it's either a referencing + * chain or all references to it have been freed */ + if (chain->flags & EVBUFFER_REFERENCE) { + struct evbuffer_chain_reference *info = + EVBUFFER_CHAIN_EXTRA( + struct evbuffer_chain_reference, + chain); + if (info->cleanupfn) + (*info->cleanupfn)(chain->buffer, + chain->buffer_len, + info->extra); + } + if (chain->flags & EVBUFFER_FILESEGMENT) { + struct evbuffer_chain_file_segment *info = + EVBUFFER_CHAIN_EXTRA( + struct evbuffer_chain_file_segment, + chain); + if (info->segment) { +#ifdef _WIN32 + if (info->segment->is_mapping) + UnmapViewOfFile(chain->buffer); +#endif + evbuffer_file_segment_free(info->segment); + } + } + if (chain->flags & EVBUFFER_MULTICAST) { + struct evbuffer_multicast_parent *info = + EVBUFFER_CHAIN_EXTRA( + struct evbuffer_multicast_parent, + chain); + /* referencing chain is being freed, decrease + * refcounts of source chain and associated + * evbuffer (which get freed once both reach + * zero) */ + EVUTIL_ASSERT(info->source != NULL); + EVUTIL_ASSERT(info->parent != NULL); + EVBUFFER_LOCK(info->source); + evbuffer_chain_free(info->parent); + evbuffer_decref_and_unlock_(info->source); + } + + mm_free(chain); +} + +static void +evbuffer_free_all_chains(struct evbuffer_chain *chain) +{ + struct evbuffer_chain *next; + for (; chain; chain = next) { + next = chain->next; + evbuffer_chain_free(chain); + } +} + +#ifndef NDEBUG +static int +evbuffer_chains_all_empty(struct evbuffer_chain *chain) +{ + for (; chain; chain = chain->next) { + if (chain->off) + return 0; + } + return 1; +} +#else +/* The definition is needed for EVUTIL_ASSERT, which uses sizeof to avoid +"unused variable" warnings. */ +static inline int evbuffer_chains_all_empty(struct evbuffer_chain *chain) { + return 1; +} +#endif + +/* Free all trailing chains in 'buf' that are neither pinned nor empty, prior + * to replacing them all with a new chain. Return a pointer to the place + * where the new chain will go. + * + * Internal; requires lock. The caller must fix up buf->last and buf->first + * as needed; they might have been freed. + */ +static struct evbuffer_chain ** +evbuffer_free_trailing_empty_chains(struct evbuffer *buf) +{ + struct evbuffer_chain **ch = buf->last_with_datap; + /* Find the first victim chain. It might be *last_with_datap */ + while ((*ch) && ((*ch)->off != 0 || CHAIN_PINNED(*ch))) + ch = &(*ch)->next; + if (*ch) { + EVUTIL_ASSERT(evbuffer_chains_all_empty(*ch)); + evbuffer_free_all_chains(*ch); + *ch = NULL; + } + return ch; +} + +/* Add a single chain 'chain' to the end of 'buf', freeing trailing empty + * chains as necessary. Requires lock. Does not schedule callbacks. + */ +static void +evbuffer_chain_insert(struct evbuffer *buf, + struct evbuffer_chain *chain) +{ + ASSERT_EVBUFFER_LOCKED(buf); + if (*buf->last_with_datap == NULL) { + /* There are no chains data on the buffer at all. */ + EVUTIL_ASSERT(buf->last_with_datap == &buf->first); + EVUTIL_ASSERT(buf->first == NULL); + buf->first = buf->last = chain; + } else { + struct evbuffer_chain **chp; + chp = evbuffer_free_trailing_empty_chains(buf); + *chp = chain; + if (chain->off) + buf->last_with_datap = chp; + buf->last = chain; + } + buf->total_len += chain->off; +} + +static inline struct evbuffer_chain * +evbuffer_chain_insert_new(struct evbuffer *buf, size_t datlen) +{ + struct evbuffer_chain *chain; + if ((chain = evbuffer_chain_new(datlen)) == NULL) + return NULL; + evbuffer_chain_insert(buf, chain); + return chain; +} + +void +evbuffer_chain_pin_(struct evbuffer_chain *chain, unsigned flag) +{ + EVUTIL_ASSERT((chain->flags & flag) == 0); + chain->flags |= flag; +} + +void +evbuffer_chain_unpin_(struct evbuffer_chain *chain, unsigned flag) +{ + EVUTIL_ASSERT((chain->flags & flag) != 0); + chain->flags &= ~flag; + if (chain->flags & EVBUFFER_DANGLING) + evbuffer_chain_free(chain); +} + +static inline void +evbuffer_chain_incref(struct evbuffer_chain *chain) +{ + ++chain->refcnt; +} + +struct evbuffer * +evbuffer_new(void) +{ + struct evbuffer *buffer; + + buffer = mm_calloc(1, sizeof(struct evbuffer)); + if (buffer == NULL) + return (NULL); + + LIST_INIT(&buffer->callbacks); + buffer->refcnt = 1; + buffer->last_with_datap = &buffer->first; + + return (buffer); +} + +int +evbuffer_set_flags(struct evbuffer *buf, ev_uint64_t flags) +{ + EVBUFFER_LOCK(buf); + buf->flags |= (ev_uint32_t)flags; + EVBUFFER_UNLOCK(buf); + return 0; +} + +int +evbuffer_clear_flags(struct evbuffer *buf, ev_uint64_t flags) +{ + EVBUFFER_LOCK(buf); + buf->flags &= ~(ev_uint32_t)flags; + EVBUFFER_UNLOCK(buf); + return 0; +} + +void +evbuffer_incref_(struct evbuffer *buf) +{ + EVBUFFER_LOCK(buf); + ++buf->refcnt; + EVBUFFER_UNLOCK(buf); +} + +void +evbuffer_incref_and_lock_(struct evbuffer *buf) +{ + EVBUFFER_LOCK(buf); + ++buf->refcnt; +} + +int +evbuffer_defer_callbacks(struct evbuffer *buffer, struct event_base *base) +{ + EVBUFFER_LOCK(buffer); + buffer->cb_queue = base; + buffer->deferred_cbs = 1; + event_deferred_cb_init_(&buffer->deferred, + event_base_get_npriorities(base) / 2, + evbuffer_deferred_callback, buffer); + EVBUFFER_UNLOCK(buffer); + return 0; +} + +int +evbuffer_enable_locking(struct evbuffer *buf, void *lock) +{ +#ifdef EVENT__DISABLE_THREAD_SUPPORT + return -1; +#else + if (buf->lock) + return -1; + + if (!lock) { + EVTHREAD_ALLOC_LOCK(lock, EVTHREAD_LOCKTYPE_RECURSIVE); + if (!lock) + return -1; + buf->lock = lock; + buf->own_lock = 1; + } else { + buf->lock = lock; + buf->own_lock = 0; + } + + return 0; +#endif +} + +void +evbuffer_set_parent_(struct evbuffer *buf, struct bufferevent *bev) +{ + EVBUFFER_LOCK(buf); + buf->parent = bev; + EVBUFFER_UNLOCK(buf); +} + +static void +evbuffer_run_callbacks(struct evbuffer *buffer, int running_deferred) +{ + struct evbuffer_cb_entry *cbent, *next; + struct evbuffer_cb_info info; + size_t new_size; + ev_uint32_t mask, masked_val; + int clear = 1; + + if (running_deferred) { + mask = EVBUFFER_CB_NODEFER|EVBUFFER_CB_ENABLED; + masked_val = EVBUFFER_CB_ENABLED; + } else if (buffer->deferred_cbs) { + mask = EVBUFFER_CB_NODEFER|EVBUFFER_CB_ENABLED; + masked_val = EVBUFFER_CB_NODEFER|EVBUFFER_CB_ENABLED; + /* Don't zero-out n_add/n_del, since the deferred callbacks + will want to see them. */ + clear = 0; + } else { + mask = EVBUFFER_CB_ENABLED; + masked_val = EVBUFFER_CB_ENABLED; + } + + ASSERT_EVBUFFER_LOCKED(buffer); + + if (LIST_EMPTY(&buffer->callbacks)) { + buffer->n_add_for_cb = buffer->n_del_for_cb = 0; + return; + } + if (buffer->n_add_for_cb == 0 && buffer->n_del_for_cb == 0) + return; + + new_size = buffer->total_len; + info.orig_size = new_size + buffer->n_del_for_cb - buffer->n_add_for_cb; + info.n_added = buffer->n_add_for_cb; + info.n_deleted = buffer->n_del_for_cb; + if (clear) { + buffer->n_add_for_cb = 0; + buffer->n_del_for_cb = 0; + } + for (cbent = LIST_FIRST(&buffer->callbacks); + cbent != LIST_END(&buffer->callbacks); + cbent = next) { + /* Get the 'next' pointer now in case this callback decides + * to remove itself or something. */ + next = LIST_NEXT(cbent, next); + + if ((cbent->flags & mask) != masked_val) + continue; + + if ((cbent->flags & EVBUFFER_CB_OBSOLETE)) + cbent->cb.cb_obsolete(buffer, + info.orig_size, new_size, cbent->cbarg); + else + cbent->cb.cb_func(buffer, &info, cbent->cbarg); + } +} + +void +evbuffer_invoke_callbacks_(struct evbuffer *buffer) +{ + if (LIST_EMPTY(&buffer->callbacks)) { + buffer->n_add_for_cb = buffer->n_del_for_cb = 0; + return; + } + + if (buffer->deferred_cbs) { + if (event_deferred_cb_schedule_(buffer->cb_queue, &buffer->deferred)) { + evbuffer_incref_and_lock_(buffer); + if (buffer->parent) + bufferevent_incref_(buffer->parent); + } + EVBUFFER_UNLOCK(buffer); + } + + evbuffer_run_callbacks(buffer, 0); +} + +static void +evbuffer_deferred_callback(struct event_callback *cb, void *arg) +{ + struct bufferevent *parent = NULL; + struct evbuffer *buffer = arg; + + /* XXXX It would be better to run these callbacks without holding the + * lock */ + EVBUFFER_LOCK(buffer); + parent = buffer->parent; + evbuffer_run_callbacks(buffer, 1); + evbuffer_decref_and_unlock_(buffer); + if (parent) + bufferevent_decref_(parent); +} + +static void +evbuffer_remove_all_callbacks(struct evbuffer *buffer) +{ + struct evbuffer_cb_entry *cbent; + + while ((cbent = LIST_FIRST(&buffer->callbacks))) { + LIST_REMOVE(cbent, next); + mm_free(cbent); + } +} + +void +evbuffer_decref_and_unlock_(struct evbuffer *buffer) +{ + struct evbuffer_chain *chain, *next; + ASSERT_EVBUFFER_LOCKED(buffer); + + EVUTIL_ASSERT(buffer->refcnt > 0); + + if (--buffer->refcnt > 0) { + EVBUFFER_UNLOCK(buffer); + return; + } + + for (chain = buffer->first; chain != NULL; chain = next) { + next = chain->next; + evbuffer_chain_free(chain); + } + evbuffer_remove_all_callbacks(buffer); + if (buffer->deferred_cbs) + event_deferred_cb_cancel_(buffer->cb_queue, &buffer->deferred); + + EVBUFFER_UNLOCK(buffer); + if (buffer->own_lock) + EVTHREAD_FREE_LOCK(buffer->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + mm_free(buffer); +} + +void +evbuffer_free(struct evbuffer *buffer) +{ + EVBUFFER_LOCK(buffer); + evbuffer_decref_and_unlock_(buffer); +} + +void +evbuffer_lock(struct evbuffer *buf) +{ + EVBUFFER_LOCK(buf); +} + +void +evbuffer_unlock(struct evbuffer *buf) +{ + EVBUFFER_UNLOCK(buf); +} + +size_t +evbuffer_get_length(const struct evbuffer *buffer) +{ + size_t result; + + EVBUFFER_LOCK(buffer); + + result = (buffer->total_len); + + EVBUFFER_UNLOCK(buffer); + + return result; +} + +size_t +evbuffer_get_contiguous_space(const struct evbuffer *buf) +{ + struct evbuffer_chain *chain; + size_t result; + + EVBUFFER_LOCK(buf); + chain = buf->first; + result = (chain != NULL ? chain->off : 0); + EVBUFFER_UNLOCK(buf); + + return result; +} + +size_t +evbuffer_add_iovec(struct evbuffer * buf, struct evbuffer_iovec * vec, int n_vec) { + int n; + size_t res; + size_t to_alloc; + + EVBUFFER_LOCK(buf); + + res = to_alloc = 0; + + for (n = 0; n < n_vec; n++) { + to_alloc += vec[n].iov_len; + } + + if (evbuffer_expand_fast_(buf, to_alloc, 2) < 0) { + goto done; + } + + for (n = 0; n < n_vec; n++) { + /* XXX each 'add' call here does a bunch of setup that's + * obviated by evbuffer_expand_fast_, and some cleanup that we + * would like to do only once. Instead we should just extract + * the part of the code that's needed. */ + + if (evbuffer_add(buf, vec[n].iov_base, vec[n].iov_len) < 0) { + goto done; + } + + res += vec[n].iov_len; + } + +done: + EVBUFFER_UNLOCK(buf); + return res; +} + +int +evbuffer_reserve_space(struct evbuffer *buf, ev_ssize_t size, + struct evbuffer_iovec *vec, int n_vecs) +{ + struct evbuffer_chain *chain, **chainp; + int n = -1; + + EVBUFFER_LOCK(buf); + if (buf->freeze_end) + goto done; + if (n_vecs < 1) + goto done; + if (n_vecs == 1) { + if ((chain = evbuffer_expand_singlechain(buf, size)) == NULL) + goto done; + + vec[0].iov_base = CHAIN_SPACE_PTR(chain); + vec[0].iov_len = (size_t) CHAIN_SPACE_LEN(chain); + EVUTIL_ASSERT(size<0 || (size_t)vec[0].iov_len >= (size_t)size); + n = 1; + } else { + if (evbuffer_expand_fast_(buf, size, n_vecs)<0) + goto done; + n = evbuffer_read_setup_vecs_(buf, size, vec, n_vecs, + &chainp, 0); + } + +done: + EVBUFFER_UNLOCK(buf); + return n; + +} + +static int +advance_last_with_data(struct evbuffer *buf) +{ + int n = 0; + ASSERT_EVBUFFER_LOCKED(buf); + + if (!*buf->last_with_datap) + return 0; + + while ((*buf->last_with_datap)->next && (*buf->last_with_datap)->next->off) { + buf->last_with_datap = &(*buf->last_with_datap)->next; + ++n; + } + return n; +} + +int +evbuffer_commit_space(struct evbuffer *buf, + struct evbuffer_iovec *vec, int n_vecs) +{ + struct evbuffer_chain *chain, **firstchainp, **chainp; + int result = -1; + size_t added = 0; + int i; + + EVBUFFER_LOCK(buf); + + if (buf->freeze_end) + goto done; + if (n_vecs == 0) { + result = 0; + goto done; + } else if (n_vecs == 1 && + (buf->last && vec[0].iov_base == (void*)CHAIN_SPACE_PTR(buf->last))) { + /* The user only got or used one chain; it might not + * be the first one with space in it. */ + if ((size_t)vec[0].iov_len > (size_t)CHAIN_SPACE_LEN(buf->last)) + goto done; + buf->last->off += vec[0].iov_len; + added = vec[0].iov_len; + if (added) + advance_last_with_data(buf); + goto okay; + } + + /* Advance 'firstchain' to the first chain with space in it. */ + firstchainp = buf->last_with_datap; + if (!*firstchainp) + goto done; + if (CHAIN_SPACE_LEN(*firstchainp) == 0) { + firstchainp = &(*firstchainp)->next; + } + + chain = *firstchainp; + /* pass 1: make sure that the pointers and lengths of vecs[] are in + * bounds before we try to commit anything. */ + for (i=0; i CHAIN_SPACE_LEN(chain)) + goto done; + chain = chain->next; + } + /* pass 2: actually adjust all the chains. */ + chainp = firstchainp; + for (i=0; ioff += vec[i].iov_len; + added += vec[i].iov_len; + if (vec[i].iov_len) { + buf->last_with_datap = chainp; + } + chainp = &(*chainp)->next; + } + +okay: + buf->total_len += added; + buf->n_add_for_cb += added; + result = 0; + evbuffer_invoke_callbacks_(buf); + +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +static inline int +HAS_PINNED_R(struct evbuffer *buf) +{ + return (buf->last && CHAIN_PINNED_R(buf->last)); +} + +static inline void +ZERO_CHAIN(struct evbuffer *dst) +{ + ASSERT_EVBUFFER_LOCKED(dst); + dst->first = NULL; + dst->last = NULL; + dst->last_with_datap = &(dst)->first; + dst->total_len = 0; +} + +/* Prepares the contents of src to be moved to another buffer by removing + * read-pinned chains. The first pinned chain is saved in first, and the + * last in last. If src has no read-pinned chains, first and last are set + * to NULL. */ +static int +PRESERVE_PINNED(struct evbuffer *src, struct evbuffer_chain **first, + struct evbuffer_chain **last) +{ + struct evbuffer_chain *chain, **pinned; + + ASSERT_EVBUFFER_LOCKED(src); + + if (!HAS_PINNED_R(src)) { + *first = *last = NULL; + return 0; + } + + pinned = src->last_with_datap; + if (!CHAIN_PINNED_R(*pinned)) + pinned = &(*pinned)->next; + EVUTIL_ASSERT(CHAIN_PINNED_R(*pinned)); + chain = *first = *pinned; + *last = src->last; + + /* If there's data in the first pinned chain, we need to allocate + * a new chain and copy the data over. */ + if (chain->off) { + struct evbuffer_chain *tmp; + + EVUTIL_ASSERT(pinned == src->last_with_datap); + tmp = evbuffer_chain_new(chain->off); + if (!tmp) + return -1; + memcpy(tmp->buffer, chain->buffer + chain->misalign, + chain->off); + tmp->off = chain->off; + *src->last_with_datap = tmp; + src->last = tmp; + chain->misalign += chain->off; + chain->off = 0; + } else { + src->last = *src->last_with_datap; + *pinned = NULL; + } + + return 0; +} + +static inline void +RESTORE_PINNED(struct evbuffer *src, struct evbuffer_chain *pinned, + struct evbuffer_chain *last) +{ + ASSERT_EVBUFFER_LOCKED(src); + + if (!pinned) { + ZERO_CHAIN(src); + return; + } + + src->first = pinned; + src->last = last; + src->last_with_datap = &src->first; + src->total_len = 0; +} + +static inline void +COPY_CHAIN(struct evbuffer *dst, struct evbuffer *src) +{ + ASSERT_EVBUFFER_LOCKED(dst); + ASSERT_EVBUFFER_LOCKED(src); + dst->first = src->first; + if (src->last_with_datap == &src->first) + dst->last_with_datap = &dst->first; + else + dst->last_with_datap = src->last_with_datap; + dst->last = src->last; + dst->total_len = src->total_len; +} + +static void +APPEND_CHAIN(struct evbuffer *dst, struct evbuffer *src) +{ + ASSERT_EVBUFFER_LOCKED(dst); + ASSERT_EVBUFFER_LOCKED(src); + dst->last->next = src->first; + if (src->last_with_datap == &src->first) + dst->last_with_datap = &dst->last->next; + else + dst->last_with_datap = src->last_with_datap; + dst->last = src->last; + dst->total_len += src->total_len; +} + +static inline void +APPEND_CHAIN_MULTICAST(struct evbuffer *dst, struct evbuffer *src) +{ + struct evbuffer_chain *tmp; + struct evbuffer_chain *chain = src->first; + struct evbuffer_multicast_parent *extra; + + ASSERT_EVBUFFER_LOCKED(dst); + ASSERT_EVBUFFER_LOCKED(src); + + for (; chain; chain = chain->next) { + if (!chain->off || chain->flags & EVBUFFER_DANGLING) { + /* skip empty chains */ + continue; + } + + tmp = evbuffer_chain_new(sizeof(struct evbuffer_multicast_parent)); + if (!tmp) { + event_warn("%s: out of memory", __func__); + return; + } + extra = EVBUFFER_CHAIN_EXTRA(struct evbuffer_multicast_parent, tmp); + /* reference evbuffer containing source chain so it + * doesn't get released while the chain is still + * being referenced to */ + evbuffer_incref_(src); + extra->source = src; + /* reference source chain which now becomes immutable */ + evbuffer_chain_incref(chain); + extra->parent = chain; + chain->flags |= EVBUFFER_IMMUTABLE; + tmp->buffer_len = chain->buffer_len; + tmp->misalign = chain->misalign; + tmp->off = chain->off; + tmp->flags |= EVBUFFER_MULTICAST|EVBUFFER_IMMUTABLE; + tmp->buffer = chain->buffer; + evbuffer_chain_insert(dst, tmp); + } +} + +static void +PREPEND_CHAIN(struct evbuffer *dst, struct evbuffer *src) +{ + ASSERT_EVBUFFER_LOCKED(dst); + ASSERT_EVBUFFER_LOCKED(src); + src->last->next = dst->first; + dst->first = src->first; + dst->total_len += src->total_len; + if (*dst->last_with_datap == NULL) { + if (src->last_with_datap == &(src)->first) + dst->last_with_datap = &dst->first; + else + dst->last_with_datap = src->last_with_datap; + } else if (dst->last_with_datap == &dst->first) { + dst->last_with_datap = &src->last->next; + } +} + +int +evbuffer_add_buffer(struct evbuffer *outbuf, struct evbuffer *inbuf) +{ + struct evbuffer_chain *pinned, *last; + size_t in_total_len, out_total_len; + int result = 0; + + EVBUFFER_LOCK2(inbuf, outbuf); + in_total_len = inbuf->total_len; + out_total_len = outbuf->total_len; + + if (in_total_len == 0 || outbuf == inbuf) + goto done; + + if (outbuf->freeze_end || inbuf->freeze_start) { + result = -1; + goto done; + } + + if (PRESERVE_PINNED(inbuf, &pinned, &last) < 0) { + result = -1; + goto done; + } + + if (out_total_len == 0) { + /* There might be an empty chain at the start of outbuf; free + * it. */ + evbuffer_free_all_chains(outbuf->first); + COPY_CHAIN(outbuf, inbuf); + } else { + APPEND_CHAIN(outbuf, inbuf); + } + + RESTORE_PINNED(inbuf, pinned, last); + + inbuf->n_del_for_cb += in_total_len; + outbuf->n_add_for_cb += in_total_len; + + evbuffer_invoke_callbacks_(inbuf); + evbuffer_invoke_callbacks_(outbuf); + +done: + EVBUFFER_UNLOCK2(inbuf, outbuf); + return result; +} + +int +evbuffer_add_buffer_reference(struct evbuffer *outbuf, struct evbuffer *inbuf) +{ + size_t in_total_len, out_total_len; + struct evbuffer_chain *chain; + int result = 0; + + EVBUFFER_LOCK2(inbuf, outbuf); + in_total_len = inbuf->total_len; + out_total_len = outbuf->total_len; + chain = inbuf->first; + + if (in_total_len == 0) + goto done; + + if (outbuf->freeze_end || outbuf == inbuf) { + result = -1; + goto done; + } + + for (; chain; chain = chain->next) { + if ((chain->flags & (EVBUFFER_FILESEGMENT|EVBUFFER_SENDFILE|EVBUFFER_MULTICAST)) != 0) { + /* chain type can not be referenced */ + result = -1; + goto done; + } + } + + if (out_total_len == 0) { + /* There might be an empty chain at the start of outbuf; free + * it. */ + evbuffer_free_all_chains(outbuf->first); + } + APPEND_CHAIN_MULTICAST(outbuf, inbuf); + + outbuf->n_add_for_cb += in_total_len; + evbuffer_invoke_callbacks_(outbuf); + +done: + EVBUFFER_UNLOCK2(inbuf, outbuf); + return result; +} + +int +evbuffer_prepend_buffer(struct evbuffer *outbuf, struct evbuffer *inbuf) +{ + struct evbuffer_chain *pinned, *last; + size_t in_total_len, out_total_len; + int result = 0; + + EVBUFFER_LOCK2(inbuf, outbuf); + + in_total_len = inbuf->total_len; + out_total_len = outbuf->total_len; + + if (!in_total_len || inbuf == outbuf) + goto done; + + if (outbuf->freeze_start || inbuf->freeze_start) { + result = -1; + goto done; + } + + if (PRESERVE_PINNED(inbuf, &pinned, &last) < 0) { + result = -1; + goto done; + } + + if (out_total_len == 0) { + /* There might be an empty chain at the start of outbuf; free + * it. */ + evbuffer_free_all_chains(outbuf->first); + COPY_CHAIN(outbuf, inbuf); + } else { + PREPEND_CHAIN(outbuf, inbuf); + } + + RESTORE_PINNED(inbuf, pinned, last); + + inbuf->n_del_for_cb += in_total_len; + outbuf->n_add_for_cb += in_total_len; + + evbuffer_invoke_callbacks_(inbuf); + evbuffer_invoke_callbacks_(outbuf); +done: + EVBUFFER_UNLOCK2(inbuf, outbuf); + return result; +} + +int +evbuffer_drain(struct evbuffer *buf, size_t len) +{ + struct evbuffer_chain *chain, *next; + size_t remaining, old_len; + int result = 0; + + EVBUFFER_LOCK(buf); + old_len = buf->total_len; + + if (old_len == 0) + goto done; + + if (buf->freeze_start) { + result = -1; + goto done; + } + + if (len >= old_len && !HAS_PINNED_R(buf)) { + len = old_len; + for (chain = buf->first; chain != NULL; chain = next) { + next = chain->next; + evbuffer_chain_free(chain); + } + + ZERO_CHAIN(buf); + } else { + if (len >= old_len) + len = old_len; + + buf->total_len -= len; + remaining = len; + for (chain = buf->first; + remaining >= chain->off; + chain = next) { + next = chain->next; + remaining -= chain->off; + + if (chain == *buf->last_with_datap) { + buf->last_with_datap = &buf->first; + } + if (&chain->next == buf->last_with_datap) + buf->last_with_datap = &buf->first; + + if (CHAIN_PINNED_R(chain)) { + EVUTIL_ASSERT(remaining == 0); + chain->misalign += chain->off; + chain->off = 0; + break; + } else + evbuffer_chain_free(chain); + } + + buf->first = chain; + EVUTIL_ASSERT(chain && remaining <= chain->off); + chain->misalign += remaining; + chain->off -= remaining; + } + + buf->n_del_for_cb += len; + /* Tell someone about changes in this buffer */ + evbuffer_invoke_callbacks_(buf); + +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +/* Reads data from an event buffer and drains the bytes read */ +int +evbuffer_remove(struct evbuffer *buf, void *data_out, size_t datlen) +{ + ev_ssize_t n; + EVBUFFER_LOCK(buf); + n = evbuffer_copyout_from(buf, NULL, data_out, datlen); + if (n > 0) { + if (evbuffer_drain(buf, n)<0) + n = -1; + } + EVBUFFER_UNLOCK(buf); + return (int)n; +} + +ev_ssize_t +evbuffer_copyout(struct evbuffer *buf, void *data_out, size_t datlen) +{ + return evbuffer_copyout_from(buf, NULL, data_out, datlen); +} + +ev_ssize_t +evbuffer_copyout_from(struct evbuffer *buf, const struct evbuffer_ptr *pos, + void *data_out, size_t datlen) +{ + /*XXX fails badly on sendfile case. */ + struct evbuffer_chain *chain; + char *data = data_out; + size_t nread; + ev_ssize_t result = 0; + size_t pos_in_chain; + + EVBUFFER_LOCK(buf); + + if (pos) { + if (datlen > (size_t)(EV_SSIZE_MAX - pos->pos)) { + result = -1; + goto done; + } + chain = pos->internal_.chain; + pos_in_chain = pos->internal_.pos_in_chain; + if (datlen + pos->pos > buf->total_len) + datlen = buf->total_len - pos->pos; + } else { + chain = buf->first; + pos_in_chain = 0; + if (datlen > buf->total_len) + datlen = buf->total_len; + } + + + if (datlen == 0) + goto done; + + if (buf->freeze_start) { + result = -1; + goto done; + } + + nread = datlen; + + while (datlen && datlen >= chain->off - pos_in_chain) { + size_t copylen = chain->off - pos_in_chain; + memcpy(data, + chain->buffer + chain->misalign + pos_in_chain, + copylen); + data += copylen; + datlen -= copylen; + + chain = chain->next; + pos_in_chain = 0; + EVUTIL_ASSERT(chain || datlen==0); + } + + if (datlen) { + EVUTIL_ASSERT(chain); + EVUTIL_ASSERT(datlen+pos_in_chain <= chain->off); + + memcpy(data, chain->buffer + chain->misalign + pos_in_chain, + datlen); + } + + result = nread; +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +/* reads data from the src buffer to the dst buffer, avoids memcpy as + * possible. */ +/* XXXX should return ev_ssize_t */ +int +evbuffer_remove_buffer(struct evbuffer *src, struct evbuffer *dst, + size_t datlen) +{ + /*XXX We should have an option to force this to be zero-copy.*/ + + /*XXX can fail badly on sendfile case. */ + struct evbuffer_chain *chain, *previous; + size_t nread = 0; + int result; + + EVBUFFER_LOCK2(src, dst); + + chain = previous = src->first; + + if (datlen == 0 || dst == src) { + result = 0; + goto done; + } + + if (dst->freeze_end || src->freeze_start) { + result = -1; + goto done; + } + + /* short-cut if there is no more data buffered */ + if (datlen >= src->total_len) { + datlen = src->total_len; + evbuffer_add_buffer(dst, src); + result = (int)datlen; /*XXXX should return ev_ssize_t*/ + goto done; + } + + /* removes chains if possible */ + while (chain->off <= datlen) { + /* We can't remove the last with data from src unless we + * remove all chains, in which case we would have done the if + * block above */ + EVUTIL_ASSERT(chain != *src->last_with_datap); + nread += chain->off; + datlen -= chain->off; + previous = chain; + if (src->last_with_datap == &chain->next) + src->last_with_datap = &src->first; + chain = chain->next; + } + + if (nread) { + /* we can remove the chain */ + struct evbuffer_chain **chp; + chp = evbuffer_free_trailing_empty_chains(dst); + + if (dst->first == NULL) { + dst->first = src->first; + } else { + *chp = src->first; + } + dst->last = previous; + previous->next = NULL; + src->first = chain; + advance_last_with_data(dst); + + dst->total_len += nread; + dst->n_add_for_cb += nread; + } + + /* we know that there is more data in the src buffer than + * we want to read, so we manually drain the chain */ + evbuffer_add(dst, chain->buffer + chain->misalign, datlen); + chain->misalign += datlen; + chain->off -= datlen; + nread += datlen; + + /* You might think we would want to increment dst->n_add_for_cb + * here too. But evbuffer_add above already took care of that. + */ + src->total_len -= nread; + src->n_del_for_cb += nread; + + if (nread) { + evbuffer_invoke_callbacks_(dst); + evbuffer_invoke_callbacks_(src); + } + result = (int)nread;/*XXXX should change return type */ + +done: + EVBUFFER_UNLOCK2(src, dst); + return result; +} + +unsigned char * +evbuffer_pullup(struct evbuffer *buf, ev_ssize_t size) +{ + struct evbuffer_chain *chain, *next, *tmp, *last_with_data; + unsigned char *buffer, *result = NULL; + ev_ssize_t remaining; + int removed_last_with_data = 0; + int removed_last_with_datap = 0; + + EVBUFFER_LOCK(buf); + + chain = buf->first; + + if (size < 0) + size = buf->total_len; + /* if size > buf->total_len, we cannot guarantee to the user that she + * is going to have a long enough buffer afterwards; so we return + * NULL */ + if (size == 0 || (size_t)size > buf->total_len) + goto done; + + /* No need to pull up anything; the first size bytes are + * already here. */ + if (chain->off >= (size_t)size) { + result = chain->buffer + chain->misalign; + goto done; + } + + /* Make sure that none of the chains we need to copy from is pinned. */ + remaining = size - chain->off; + EVUTIL_ASSERT(remaining >= 0); + for (tmp=chain->next; tmp; tmp=tmp->next) { + if (CHAIN_PINNED(tmp)) + goto done; + if (tmp->off >= (size_t)remaining) + break; + remaining -= tmp->off; + } + + if (CHAIN_PINNED(chain)) { + size_t old_off = chain->off; + if (CHAIN_SPACE_LEN(chain) < size - chain->off) { + /* not enough room at end of chunk. */ + goto done; + } + buffer = CHAIN_SPACE_PTR(chain); + tmp = chain; + tmp->off = size; + size -= old_off; + chain = chain->next; + } else if (chain->buffer_len - chain->misalign >= (size_t)size) { + /* already have enough space in the first chain */ + size_t old_off = chain->off; + buffer = chain->buffer + chain->misalign + chain->off; + tmp = chain; + tmp->off = size; + size -= old_off; + chain = chain->next; + } else { + if ((tmp = evbuffer_chain_new(size)) == NULL) { + event_warn("%s: out of memory", __func__); + goto done; + } + buffer = tmp->buffer; + tmp->off = size; + buf->first = tmp; + } + + /* TODO(niels): deal with buffers that point to NULL like sendfile */ + + /* Copy and free every chunk that will be entirely pulled into tmp */ + last_with_data = *buf->last_with_datap; + for (; chain != NULL && (size_t)size >= chain->off; chain = next) { + next = chain->next; + + memcpy(buffer, chain->buffer + chain->misalign, chain->off); + size -= chain->off; + buffer += chain->off; + if (chain == last_with_data) + removed_last_with_data = 1; + if (&chain->next == buf->last_with_datap) + removed_last_with_datap = 1; + + evbuffer_chain_free(chain); + } + + if (chain != NULL) { + memcpy(buffer, chain->buffer + chain->misalign, size); + chain->misalign += size; + chain->off -= size; + } else { + buf->last = tmp; + } + + tmp->next = chain; + + if (removed_last_with_data) { + buf->last_with_datap = &buf->first; + } else if (removed_last_with_datap) { + if (buf->first->next && buf->first->next->off) + buf->last_with_datap = &buf->first->next; + else + buf->last_with_datap = &buf->first; + } + + result = (tmp->buffer + tmp->misalign); + +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +/* + * Reads a line terminated by either '\r\n', '\n\r' or '\r' or '\n'. + * The returned buffer needs to be freed by the called. + */ +char * +evbuffer_readline(struct evbuffer *buffer) +{ + return evbuffer_readln(buffer, NULL, EVBUFFER_EOL_ANY); +} + +static inline ev_ssize_t +evbuffer_strchr(struct evbuffer_ptr *it, const char chr) +{ + struct evbuffer_chain *chain = it->internal_.chain; + size_t i = it->internal_.pos_in_chain; + while (chain != NULL) { + char *buffer = (char *)chain->buffer + chain->misalign; + char *cp = memchr(buffer+i, chr, chain->off-i); + if (cp) { + it->internal_.chain = chain; + it->internal_.pos_in_chain = cp - buffer; + it->pos += (cp - buffer - i); + return it->pos; + } + it->pos += chain->off - i; + i = 0; + chain = chain->next; + } + + return (-1); +} + +static inline char * +find_eol_char(char *s, size_t len) +{ +#define CHUNK_SZ 128 + /* Lots of benchmarking found this approach to be faster in practice + * than doing two memchrs over the whole buffer, doin a memchr on each + * char of the buffer, or trying to emulate memchr by hand. */ + char *s_end, *cr, *lf; + s_end = s+len; + while (s < s_end) { + size_t chunk = (s + CHUNK_SZ < s_end) ? CHUNK_SZ : (s_end - s); + cr = memchr(s, '\r', chunk); + lf = memchr(s, '\n', chunk); + if (cr) { + if (lf && lf < cr) + return lf; + return cr; + } else if (lf) { + return lf; + } + s += CHUNK_SZ; + } + + return NULL; +#undef CHUNK_SZ +} + +static ev_ssize_t +evbuffer_find_eol_char(struct evbuffer_ptr *it) +{ + struct evbuffer_chain *chain = it->internal_.chain; + size_t i = it->internal_.pos_in_chain; + while (chain != NULL) { + char *buffer = (char *)chain->buffer + chain->misalign; + char *cp = find_eol_char(buffer+i, chain->off-i); + if (cp) { + it->internal_.chain = chain; + it->internal_.pos_in_chain = cp - buffer; + it->pos += (cp - buffer) - i; + return it->pos; + } + it->pos += chain->off - i; + i = 0; + chain = chain->next; + } + + return (-1); +} + +static inline int +evbuffer_strspn( + struct evbuffer_ptr *ptr, const char *chrset) +{ + int count = 0; + struct evbuffer_chain *chain = ptr->internal_.chain; + size_t i = ptr->internal_.pos_in_chain; + + if (!chain) + return 0; + + while (1) { + char *buffer = (char *)chain->buffer + chain->misalign; + for (; i < chain->off; ++i) { + const char *p = chrset; + while (*p) { + if (buffer[i] == *p++) + goto next; + } + ptr->internal_.chain = chain; + ptr->internal_.pos_in_chain = i; + ptr->pos += count; + return count; + next: + ++count; + } + i = 0; + + if (! chain->next) { + ptr->internal_.chain = chain; + ptr->internal_.pos_in_chain = i; + ptr->pos += count; + return count; + } + + chain = chain->next; + } +} + + +static inline int +evbuffer_getchr(struct evbuffer_ptr *it) +{ + struct evbuffer_chain *chain = it->internal_.chain; + size_t off = it->internal_.pos_in_chain; + + if (chain == NULL) + return -1; + + return (unsigned char)chain->buffer[chain->misalign + off]; +} + +struct evbuffer_ptr +evbuffer_search_eol(struct evbuffer *buffer, + struct evbuffer_ptr *start, size_t *eol_len_out, + enum evbuffer_eol_style eol_style) +{ + struct evbuffer_ptr it, it2; + size_t extra_drain = 0; + int ok = 0; + + /* Avoid locking in trivial edge cases */ + if (start && start->internal_.chain == NULL) { + PTR_NOT_FOUND(&it); + if (eol_len_out) + *eol_len_out = extra_drain; + return it; + } + + EVBUFFER_LOCK(buffer); + + if (start) { + memcpy(&it, start, sizeof(it)); + } else { + it.pos = 0; + it.internal_.chain = buffer->first; + it.internal_.pos_in_chain = 0; + } + + /* the eol_style determines our first stop character and how many + * characters we are going to drain afterwards. */ + switch (eol_style) { + case EVBUFFER_EOL_ANY: + if (evbuffer_find_eol_char(&it) < 0) + goto done; + memcpy(&it2, &it, sizeof(it)); + extra_drain = evbuffer_strspn(&it2, "\r\n"); + break; + case EVBUFFER_EOL_CRLF_STRICT: { + it = evbuffer_search(buffer, "\r\n", 2, &it); + if (it.pos < 0) + goto done; + extra_drain = 2; + break; + } + case EVBUFFER_EOL_CRLF: { + ev_ssize_t start_pos = it.pos; + /* Look for a LF ... */ + if (evbuffer_strchr(&it, '\n') < 0) + goto done; + extra_drain = 1; + /* ... optionally preceeded by a CR. */ + if (it.pos == start_pos) + break; /* If the first character is \n, don't back up */ + /* This potentially does an extra linear walk over the first + * few chains. Probably, that's not too expensive unless you + * have a really pathological setup. */ + memcpy(&it2, &it, sizeof(it)); + if (evbuffer_ptr_subtract(buffer, &it2, 1)<0) + break; + if (evbuffer_getchr(&it2) == '\r') { + memcpy(&it, &it2, sizeof(it)); + extra_drain = 2; + } + break; + } + case EVBUFFER_EOL_LF: + if (evbuffer_strchr(&it, '\n') < 0) + goto done; + extra_drain = 1; + break; + case EVBUFFER_EOL_NUL: + if (evbuffer_strchr(&it, '\0') < 0) + goto done; + extra_drain = 1; + break; + default: + goto done; + } + + ok = 1; +done: + EVBUFFER_UNLOCK(buffer); + + if (!ok) + PTR_NOT_FOUND(&it); + if (eol_len_out) + *eol_len_out = extra_drain; + + return it; +} + +char * +evbuffer_readln(struct evbuffer *buffer, size_t *n_read_out, + enum evbuffer_eol_style eol_style) +{ + struct evbuffer_ptr it; + char *line; + size_t n_to_copy=0, extra_drain=0; + char *result = NULL; + + EVBUFFER_LOCK(buffer); + + if (buffer->freeze_start) { + goto done; + } + + it = evbuffer_search_eol(buffer, NULL, &extra_drain, eol_style); + if (it.pos < 0) + goto done; + n_to_copy = it.pos; + + if ((line = mm_malloc(n_to_copy+1)) == NULL) { + event_warn("%s: out of memory", __func__); + goto done; + } + + evbuffer_remove(buffer, line, n_to_copy); + line[n_to_copy] = '\0'; + + evbuffer_drain(buffer, extra_drain); + result = line; +done: + EVBUFFER_UNLOCK(buffer); + + if (n_read_out) + *n_read_out = result ? n_to_copy : 0; + + return result; +} + +#define EVBUFFER_CHAIN_MAX_AUTO_SIZE 4096 + +/* Adds data to an event buffer */ + +int +evbuffer_add(struct evbuffer *buf, const void *data_in, size_t datlen) +{ + struct evbuffer_chain *chain, *tmp; + const unsigned char *data = data_in; + size_t remain, to_alloc; + int result = -1; + + EVBUFFER_LOCK(buf); + + if (buf->freeze_end) { + goto done; + } + /* Prevent buf->total_len overflow */ + if (datlen > EV_SIZE_MAX - buf->total_len) { + goto done; + } + + chain = buf->last; + + /* If there are no chains allocated for this buffer, allocate one + * big enough to hold all the data. */ + if (chain == NULL) { + chain = evbuffer_chain_new(datlen); + if (!chain) + goto done; + evbuffer_chain_insert(buf, chain); + } + + if ((chain->flags & EVBUFFER_IMMUTABLE) == 0) { + /* Always true for mutable buffers */ + EVUTIL_ASSERT(chain->misalign >= 0 && + (ev_uint64_t)chain->misalign <= EVBUFFER_CHAIN_MAX); + remain = chain->buffer_len - (size_t)chain->misalign - chain->off; + if (remain >= datlen) { + /* there's enough space to hold all the data in the + * current last chain */ + memcpy(chain->buffer + chain->misalign + chain->off, + data, datlen); + chain->off += datlen; + buf->total_len += datlen; + buf->n_add_for_cb += datlen; + goto out; + } else if (!CHAIN_PINNED(chain) && + evbuffer_chain_should_realign(chain, datlen)) { + /* we can fit the data into the misalignment */ + evbuffer_chain_align(chain); + + memcpy(chain->buffer + chain->off, data, datlen); + chain->off += datlen; + buf->total_len += datlen; + buf->n_add_for_cb += datlen; + goto out; + } + } else { + /* we cannot write any data to the last chain */ + remain = 0; + } + + /* we need to add another chain */ + to_alloc = chain->buffer_len; + if (to_alloc <= EVBUFFER_CHAIN_MAX_AUTO_SIZE/2) + to_alloc <<= 1; + if (datlen > to_alloc) + to_alloc = datlen; + tmp = evbuffer_chain_new(to_alloc); + if (tmp == NULL) + goto done; + + if (remain) { + memcpy(chain->buffer + chain->misalign + chain->off, + data, remain); + chain->off += remain; + buf->total_len += remain; + buf->n_add_for_cb += remain; + } + + data += remain; + datlen -= remain; + + memcpy(tmp->buffer, data, datlen); + tmp->off = datlen; + evbuffer_chain_insert(buf, tmp); + buf->n_add_for_cb += datlen; + +out: + evbuffer_invoke_callbacks_(buf); + result = 0; +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +int +evbuffer_prepend(struct evbuffer *buf, const void *data, size_t datlen) +{ + struct evbuffer_chain *chain, *tmp; + int result = -1; + + EVBUFFER_LOCK(buf); + + if (buf->freeze_start) { + goto done; + } + if (datlen > EV_SIZE_MAX - buf->total_len) { + goto done; + } + + chain = buf->first; + + if (chain == NULL) { + chain = evbuffer_chain_new(datlen); + if (!chain) + goto done; + evbuffer_chain_insert(buf, chain); + } + + /* we cannot touch immutable buffers */ + if ((chain->flags & EVBUFFER_IMMUTABLE) == 0) { + /* Always true for mutable buffers */ + EVUTIL_ASSERT(chain->misalign >= 0 && + (ev_uint64_t)chain->misalign <= EVBUFFER_CHAIN_MAX); + + /* If this chain is empty, we can treat it as + * 'empty at the beginning' rather than 'empty at the end' */ + if (chain->off == 0) + chain->misalign = chain->buffer_len; + + if ((size_t)chain->misalign >= datlen) { + /* we have enough space to fit everything */ + memcpy(chain->buffer + chain->misalign - datlen, + data, datlen); + chain->off += datlen; + chain->misalign -= datlen; + buf->total_len += datlen; + buf->n_add_for_cb += datlen; + goto out; + } else if (chain->misalign) { + /* we can only fit some of the data. */ + memcpy(chain->buffer, + (char*)data + datlen - chain->misalign, + (size_t)chain->misalign); + chain->off += (size_t)chain->misalign; + buf->total_len += (size_t)chain->misalign; + buf->n_add_for_cb += (size_t)chain->misalign; + datlen -= (size_t)chain->misalign; + chain->misalign = 0; + } + } + + /* we need to add another chain */ + if ((tmp = evbuffer_chain_new(datlen)) == NULL) + goto done; + buf->first = tmp; + if (buf->last_with_datap == &buf->first) + buf->last_with_datap = &tmp->next; + + tmp->next = chain; + + tmp->off = datlen; + EVUTIL_ASSERT(datlen <= tmp->buffer_len); + tmp->misalign = tmp->buffer_len - datlen; + + memcpy(tmp->buffer + tmp->misalign, data, datlen); + buf->total_len += datlen; + buf->n_add_for_cb += (size_t)chain->misalign; + +out: + evbuffer_invoke_callbacks_(buf); + result = 0; +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +/** Helper: realigns the memory in chain->buffer so that misalign is 0. */ +static void +evbuffer_chain_align(struct evbuffer_chain *chain) +{ + EVUTIL_ASSERT(!(chain->flags & EVBUFFER_IMMUTABLE)); + EVUTIL_ASSERT(!(chain->flags & EVBUFFER_MEM_PINNED_ANY)); + memmove(chain->buffer, chain->buffer + chain->misalign, chain->off); + chain->misalign = 0; +} + +#define MAX_TO_COPY_IN_EXPAND 4096 +#define MAX_TO_REALIGN_IN_EXPAND 2048 + +/** Helper: return true iff we should realign chain to fit datalen bytes of + data in it. */ +static int +evbuffer_chain_should_realign(struct evbuffer_chain *chain, + size_t datlen) +{ + return chain->buffer_len - chain->off >= datlen && + (chain->off < chain->buffer_len / 2) && + (chain->off <= MAX_TO_REALIGN_IN_EXPAND); +} + +/* Expands the available space in the event buffer to at least datlen, all in + * a single chunk. Return that chunk. */ +static struct evbuffer_chain * +evbuffer_expand_singlechain(struct evbuffer *buf, size_t datlen) +{ + struct evbuffer_chain *chain, **chainp; + struct evbuffer_chain *result = NULL; + ASSERT_EVBUFFER_LOCKED(buf); + + chainp = buf->last_with_datap; + + /* XXX If *chainp is no longer writeable, but has enough space in its + * misalign, this might be a bad idea: we could still use *chainp, not + * (*chainp)->next. */ + if (*chainp && CHAIN_SPACE_LEN(*chainp) == 0) + chainp = &(*chainp)->next; + + /* 'chain' now points to the first chain with writable space (if any) + * We will either use it, realign it, replace it, or resize it. */ + chain = *chainp; + + if (chain == NULL || + (chain->flags & (EVBUFFER_IMMUTABLE|EVBUFFER_MEM_PINNED_ANY))) { + /* We can't use the last_with_data chain at all. Just add a + * new one that's big enough. */ + goto insert_new; + } + + /* If we can fit all the data, then we don't have to do anything */ + if (CHAIN_SPACE_LEN(chain) >= datlen) { + result = chain; + goto ok; + } + + /* If the chain is completely empty, just replace it by adding a new + * empty chain. */ + if (chain->off == 0) { + goto insert_new; + } + + /* If the misalignment plus the remaining space fulfills our data + * needs, we could just force an alignment to happen. Afterwards, we + * have enough space. But only do this if we're saving a lot of space + * and not moving too much data. Otherwise the space savings are + * probably offset by the time lost in copying. + */ + if (evbuffer_chain_should_realign(chain, datlen)) { + evbuffer_chain_align(chain); + result = chain; + goto ok; + } + + /* At this point, we can either resize the last chunk with space in + * it, use the next chunk after it, or If we add a new chunk, we waste + * CHAIN_SPACE_LEN(chain) bytes in the former last chunk. If we + * resize, we have to copy chain->off bytes. + */ + + /* Would expanding this chunk be affordable and worthwhile? */ + if (CHAIN_SPACE_LEN(chain) < chain->buffer_len / 8 || + chain->off > MAX_TO_COPY_IN_EXPAND || + (datlen < EVBUFFER_CHAIN_MAX && + EVBUFFER_CHAIN_MAX - datlen >= chain->off)) { + /* It's not worth resizing this chain. Can the next one be + * used? */ + if (chain->next && CHAIN_SPACE_LEN(chain->next) >= datlen) { + /* Yes, we can just use the next chain (which should + * be empty. */ + result = chain->next; + goto ok; + } else { + /* No; append a new chain (which will free all + * terminal empty chains.) */ + goto insert_new; + } + } else { + /* Okay, we're going to try to resize this chain: Not doing so + * would waste at least 1/8 of its current allocation, and we + * can do so without having to copy more than + * MAX_TO_COPY_IN_EXPAND bytes. */ + /* figure out how much space we need */ + size_t length = chain->off + datlen; + struct evbuffer_chain *tmp = evbuffer_chain_new(length); + if (tmp == NULL) + goto err; + + /* copy the data over that we had so far */ + tmp->off = chain->off; + memcpy(tmp->buffer, chain->buffer + chain->misalign, + chain->off); + /* fix up the list */ + EVUTIL_ASSERT(*chainp == chain); + result = *chainp = tmp; + + if (buf->last == chain) + buf->last = tmp; + + tmp->next = chain->next; + evbuffer_chain_free(chain); + goto ok; + } + +insert_new: + result = evbuffer_chain_insert_new(buf, datlen); + if (!result) + goto err; +ok: + EVUTIL_ASSERT(result); + EVUTIL_ASSERT(CHAIN_SPACE_LEN(result) >= datlen); +err: + return result; +} + +/* Make sure that datlen bytes are available for writing in the last n + * chains. Never copies or moves data. */ +int +evbuffer_expand_fast_(struct evbuffer *buf, size_t datlen, int n) +{ + struct evbuffer_chain *chain = buf->last, *tmp, *next; + size_t avail; + int used; + + ASSERT_EVBUFFER_LOCKED(buf); + EVUTIL_ASSERT(n >= 2); + + if (chain == NULL || (chain->flags & EVBUFFER_IMMUTABLE)) { + /* There is no last chunk, or we can't touch the last chunk. + * Just add a new chunk. */ + chain = evbuffer_chain_new(datlen); + if (chain == NULL) + return (-1); + + evbuffer_chain_insert(buf, chain); + return (0); + } + + used = 0; /* number of chains we're using space in. */ + avail = 0; /* how much space they have. */ + /* How many bytes can we stick at the end of buffer as it is? Iterate + * over the chains at the end of the buffer, tring to see how much + * space we have in the first n. */ + for (chain = *buf->last_with_datap; chain; chain = chain->next) { + if (chain->off) { + size_t space = (size_t) CHAIN_SPACE_LEN(chain); + EVUTIL_ASSERT(chain == *buf->last_with_datap); + if (space) { + avail += space; + ++used; + } + } else { + /* No data in chain; realign it. */ + chain->misalign = 0; + avail += chain->buffer_len; + ++used; + } + if (avail >= datlen) { + /* There is already enough space. Just return */ + return (0); + } + if (used == n) + break; + } + + /* There wasn't enough space in the first n chains with space in + * them. Either add a new chain with enough space, or replace all + * empty chains with one that has enough space, depending on n. */ + if (used < n) { + /* The loop ran off the end of the chains before it hit n + * chains; we can add another. */ + EVUTIL_ASSERT(chain == NULL); + + tmp = evbuffer_chain_new(datlen - avail); + if (tmp == NULL) + return (-1); + + buf->last->next = tmp; + buf->last = tmp; + /* (we would only set last_with_data if we added the first + * chain. But if the buffer had no chains, we would have + * just allocated a new chain earlier) */ + return (0); + } else { + /* Nuke _all_ the empty chains. */ + int rmv_all = 0; /* True iff we removed last_with_data. */ + chain = *buf->last_with_datap; + if (!chain->off) { + EVUTIL_ASSERT(chain == buf->first); + rmv_all = 1; + avail = 0; + } else { + /* can't overflow, since only mutable chains have + * huge misaligns. */ + avail = (size_t) CHAIN_SPACE_LEN(chain); + chain = chain->next; + } + + + for (; chain; chain = next) { + next = chain->next; + EVUTIL_ASSERT(chain->off == 0); + evbuffer_chain_free(chain); + } + EVUTIL_ASSERT(datlen >= avail); + tmp = evbuffer_chain_new(datlen - avail); + if (tmp == NULL) { + if (rmv_all) { + ZERO_CHAIN(buf); + } else { + buf->last = *buf->last_with_datap; + (*buf->last_with_datap)->next = NULL; + } + return (-1); + } + + if (rmv_all) { + buf->first = buf->last = tmp; + buf->last_with_datap = &buf->first; + } else { + (*buf->last_with_datap)->next = tmp; + buf->last = tmp; + } + return (0); + } +} + +int +evbuffer_expand(struct evbuffer *buf, size_t datlen) +{ + struct evbuffer_chain *chain; + + EVBUFFER_LOCK(buf); + chain = evbuffer_expand_singlechain(buf, datlen); + EVBUFFER_UNLOCK(buf); + return chain ? 0 : -1; +} + +/* + * Reads data from a file descriptor into a buffer. + */ + +#if defined(EVENT__HAVE_SYS_UIO_H) || defined(_WIN32) +#define USE_IOVEC_IMPL +#endif + +#ifdef USE_IOVEC_IMPL + +#ifdef EVENT__HAVE_SYS_UIO_H +/* number of iovec we use for writev, fragmentation is going to determine + * how much we end up writing */ + +#define DEFAULT_WRITE_IOVEC 128 + +#if defined(UIO_MAXIOV) && UIO_MAXIOV < DEFAULT_WRITE_IOVEC +#define NUM_WRITE_IOVEC UIO_MAXIOV +#elif defined(IOV_MAX) && IOV_MAX < DEFAULT_WRITE_IOVEC +#define NUM_WRITE_IOVEC IOV_MAX +#else +#define NUM_WRITE_IOVEC DEFAULT_WRITE_IOVEC +#endif + +#define IOV_TYPE struct iovec +#define IOV_PTR_FIELD iov_base +#define IOV_LEN_FIELD iov_len +#define IOV_LEN_TYPE size_t +#else +#define NUM_WRITE_IOVEC 16 +#define IOV_TYPE WSABUF +#define IOV_PTR_FIELD buf +#define IOV_LEN_FIELD len +#define IOV_LEN_TYPE unsigned long +#endif +#endif +#define NUM_READ_IOVEC 4 + +#define EVBUFFER_MAX_READ 4096 + +/** Helper function to figure out which space to use for reading data into + an evbuffer. Internal use only. + + @param buf The buffer to read into + @param howmuch How much we want to read. + @param vecs An array of two or more iovecs or WSABUFs. + @param n_vecs_avail The length of vecs + @param chainp A pointer to a variable to hold the first chain we're + reading into. + @param exact Boolean: if true, we do not provide more than 'howmuch' + space in the vectors, even if more space is available. + @return The number of buffers we're using. + */ +int +evbuffer_read_setup_vecs_(struct evbuffer *buf, ev_ssize_t howmuch, + struct evbuffer_iovec *vecs, int n_vecs_avail, + struct evbuffer_chain ***chainp, int exact) +{ + struct evbuffer_chain *chain; + struct evbuffer_chain **firstchainp; + size_t so_far; + int i; + ASSERT_EVBUFFER_LOCKED(buf); + + if (howmuch < 0) + return -1; + + so_far = 0; + /* Let firstchain be the first chain with any space on it */ + firstchainp = buf->last_with_datap; + if (CHAIN_SPACE_LEN(*firstchainp) == 0) { + firstchainp = &(*firstchainp)->next; + } + + chain = *firstchainp; + for (i = 0; i < n_vecs_avail && so_far < (size_t)howmuch; ++i) { + size_t avail = (size_t) CHAIN_SPACE_LEN(chain); + if (avail > (howmuch - so_far) && exact) + avail = howmuch - so_far; + vecs[i].iov_base = CHAIN_SPACE_PTR(chain); + vecs[i].iov_len = avail; + so_far += avail; + chain = chain->next; + } + + *chainp = firstchainp; + return i; +} + +static int +get_n_bytes_readable_on_socket(evutil_socket_t fd) +{ +#if defined(FIONREAD) && defined(_WIN32) + unsigned long lng = EVBUFFER_MAX_READ; + if (ioctlsocket(fd, FIONREAD, &lng) < 0) + return -1; + /* Can overflow, but mostly harmlessly. XXXX */ + return (int)lng; +#elif defined(FIONREAD) + int n = EVBUFFER_MAX_READ; + if (ioctl(fd, FIONREAD, &n) < 0) + return -1; + return n; +#else + return EVBUFFER_MAX_READ; +#endif +} + +/* TODO(niels): should this function return ev_ssize_t and take ev_ssize_t + * as howmuch? */ +int +evbuffer_read(struct evbuffer *buf, evutil_socket_t fd, int howmuch) +{ + struct evbuffer_chain **chainp; + int n; + int result; + +#ifdef USE_IOVEC_IMPL + int nvecs, i, remaining; +#else + struct evbuffer_chain *chain; + unsigned char *p; +#endif + + EVBUFFER_LOCK(buf); + + if (buf->freeze_end) { + result = -1; + goto done; + } + + n = get_n_bytes_readable_on_socket(fd); + if (n <= 0 || n > EVBUFFER_MAX_READ) + n = EVBUFFER_MAX_READ; + if (howmuch < 0 || howmuch > n) + howmuch = n; + +#ifdef USE_IOVEC_IMPL + /* Since we can use iovecs, we're willing to use the last + * NUM_READ_IOVEC chains. */ + if (evbuffer_expand_fast_(buf, howmuch, NUM_READ_IOVEC) == -1) { + result = -1; + goto done; + } else { + IOV_TYPE vecs[NUM_READ_IOVEC]; +#ifdef EVBUFFER_IOVEC_IS_NATIVE_ + nvecs = evbuffer_read_setup_vecs_(buf, howmuch, vecs, + NUM_READ_IOVEC, &chainp, 1); +#else + /* We aren't using the native struct iovec. Therefore, + we are on win32. */ + struct evbuffer_iovec ev_vecs[NUM_READ_IOVEC]; + nvecs = evbuffer_read_setup_vecs_(buf, howmuch, ev_vecs, 2, + &chainp, 1); + + for (i=0; i < nvecs; ++i) + WSABUF_FROM_EVBUFFER_IOV(&vecs[i], &ev_vecs[i]); +#endif + +#ifdef _WIN32 + { + DWORD bytesRead; + DWORD flags=0; + if (WSARecv(fd, vecs, nvecs, &bytesRead, &flags, NULL, NULL)) { + /* The read failed. It might be a close, + * or it might be an error. */ + if (WSAGetLastError() == WSAECONNABORTED) + n = 0; + else + n = -1; + } else + n = bytesRead; + } +#else + n = readv(fd, vecs, nvecs); +#endif + } + +#else /*!USE_IOVEC_IMPL*/ + /* If we don't have FIONREAD, we might waste some space here */ + /* XXX we _will_ waste some space here if there is any space left + * over on buf->last. */ + if ((chain = evbuffer_expand_singlechain(buf, howmuch)) == NULL) { + result = -1; + goto done; + } + + /* We can append new data at this point */ + p = chain->buffer + chain->misalign + chain->off; + +#ifndef _WIN32 + n = read(fd, p, howmuch); +#else + n = recv(fd, p, howmuch, 0); +#endif +#endif /* USE_IOVEC_IMPL */ + + if (n == -1) { + result = -1; + goto done; + } + if (n == 0) { + result = 0; + goto done; + } + +#ifdef USE_IOVEC_IMPL + remaining = n; + for (i=0; i < nvecs; ++i) { + /* can't overflow, since only mutable chains have + * huge misaligns. */ + size_t space = (size_t) CHAIN_SPACE_LEN(*chainp); + /* XXXX This is a kludge that can waste space in perverse + * situations. */ + if (space > EVBUFFER_CHAIN_MAX) + space = EVBUFFER_CHAIN_MAX; + if ((ev_ssize_t)space < remaining) { + (*chainp)->off += space; + remaining -= (int)space; + } else { + (*chainp)->off += remaining; + buf->last_with_datap = chainp; + break; + } + chainp = &(*chainp)->next; + } +#else + chain->off += n; + advance_last_with_data(buf); +#endif + buf->total_len += n; + buf->n_add_for_cb += n; + + /* Tell someone about changes in this buffer */ + evbuffer_invoke_callbacks_(buf); + result = n; +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +#ifdef USE_IOVEC_IMPL +static inline int +evbuffer_write_iovec(struct evbuffer *buffer, evutil_socket_t fd, + ev_ssize_t howmuch) +{ + IOV_TYPE iov[NUM_WRITE_IOVEC]; + struct evbuffer_chain *chain = buffer->first; + int n, i = 0; + + if (howmuch < 0) + return -1; + + ASSERT_EVBUFFER_LOCKED(buffer); + /* XXX make this top out at some maximal data length? if the + * buffer has (say) 1MB in it, split over 128 chains, there's + * no way it all gets written in one go. */ + while (chain != NULL && i < NUM_WRITE_IOVEC && howmuch) { +#ifdef USE_SENDFILE + /* we cannot write the file info via writev */ + if (chain->flags & EVBUFFER_SENDFILE) + break; +#endif + iov[i].IOV_PTR_FIELD = (void *) (chain->buffer + chain->misalign); + if ((size_t)howmuch >= chain->off) { + /* XXXcould be problematic when windows supports mmap*/ + iov[i++].IOV_LEN_FIELD = (IOV_LEN_TYPE)chain->off; + howmuch -= chain->off; + } else { + /* XXXcould be problematic when windows supports mmap*/ + iov[i++].IOV_LEN_FIELD = (IOV_LEN_TYPE)howmuch; + break; + } + chain = chain->next; + } + if (! i) + return 0; + +#ifdef _WIN32 + { + DWORD bytesSent; + if (WSASend(fd, iov, i, &bytesSent, 0, NULL, NULL)) + n = -1; + else + n = bytesSent; + } +#else + n = writev(fd, iov, i); +#endif + return (n); +} +#endif + +#ifdef USE_SENDFILE +static inline int +evbuffer_write_sendfile(struct evbuffer *buffer, evutil_socket_t dest_fd, + ev_ssize_t howmuch) +{ + struct evbuffer_chain *chain = buffer->first; + struct evbuffer_chain_file_segment *info = + EVBUFFER_CHAIN_EXTRA(struct evbuffer_chain_file_segment, + chain); + const int source_fd = info->segment->fd; +#if defined(SENDFILE_IS_MACOSX) || defined(SENDFILE_IS_FREEBSD) + int res; + ev_off_t len = chain->off; +#elif defined(SENDFILE_IS_LINUX) || defined(SENDFILE_IS_SOLARIS) + ev_ssize_t res; + ev_off_t offset = chain->misalign; +#endif + + ASSERT_EVBUFFER_LOCKED(buffer); + +#if defined(SENDFILE_IS_MACOSX) + res = sendfile(source_fd, dest_fd, chain->misalign, &len, NULL, 0); + if (res == -1 && !EVUTIL_ERR_RW_RETRIABLE(errno)) + return (-1); + + return (len); +#elif defined(SENDFILE_IS_FREEBSD) + res = sendfile(source_fd, dest_fd, chain->misalign, chain->off, NULL, &len, 0); + if (res == -1 && !EVUTIL_ERR_RW_RETRIABLE(errno)) + return (-1); + + return (len); +#elif defined(SENDFILE_IS_LINUX) + /* TODO(niels): implement splice */ + res = sendfile(dest_fd, source_fd, &offset, chain->off); + if (res == -1 && EVUTIL_ERR_RW_RETRIABLE(errno)) { + /* if this is EAGAIN or EINTR return 0; otherwise, -1 */ + return (0); + } + return (res); +#elif defined(SENDFILE_IS_SOLARIS) + { + const off_t offset_orig = offset; + res = sendfile(dest_fd, source_fd, &offset, chain->off); + if (res == -1 && EVUTIL_ERR_RW_RETRIABLE(errno)) { + if (offset - offset_orig) + return offset - offset_orig; + /* if this is EAGAIN or EINTR and no bytes were + * written, return 0 */ + return (0); + } + return (res); + } +#endif +} +#endif + +int +evbuffer_write_atmost(struct evbuffer *buffer, evutil_socket_t fd, + ev_ssize_t howmuch) +{ + int n = -1; + + EVBUFFER_LOCK(buffer); + + if (buffer->freeze_start) { + goto done; + } + + if (howmuch < 0 || (size_t)howmuch > buffer->total_len) + howmuch = buffer->total_len; + + if (howmuch > 0) { +#ifdef USE_SENDFILE + struct evbuffer_chain *chain = buffer->first; + if (chain != NULL && (chain->flags & EVBUFFER_SENDFILE)) + n = evbuffer_write_sendfile(buffer, fd, howmuch); + else { +#endif +#ifdef USE_IOVEC_IMPL + n = evbuffer_write_iovec(buffer, fd, howmuch); +#elif defined(_WIN32) + /* XXX(nickm) Don't disable this code until we know if + * the WSARecv code above works. */ + void *p = evbuffer_pullup(buffer, howmuch); + EVUTIL_ASSERT(p || !howmuch); + n = send(fd, p, howmuch, 0); +#else + void *p = evbuffer_pullup(buffer, howmuch); + EVUTIL_ASSERT(p || !howmuch); + n = write(fd, p, howmuch); +#endif +#ifdef USE_SENDFILE + } +#endif + } + + if (n > 0) + evbuffer_drain(buffer, n); + +done: + EVBUFFER_UNLOCK(buffer); + return (n); +} + +int +evbuffer_write(struct evbuffer *buffer, evutil_socket_t fd) +{ + return evbuffer_write_atmost(buffer, fd, -1); +} + +unsigned char * +evbuffer_find(struct evbuffer *buffer, const unsigned char *what, size_t len) +{ + unsigned char *search; + struct evbuffer_ptr ptr; + + EVBUFFER_LOCK(buffer); + + ptr = evbuffer_search(buffer, (const char *)what, len, NULL); + if (ptr.pos < 0) { + search = NULL; + } else { + search = evbuffer_pullup(buffer, ptr.pos + len); + if (search) + search += ptr.pos; + } + EVBUFFER_UNLOCK(buffer); + return search; +} + +/* Subract howfar from the position of pos within + * buf. Returns 0 on success, -1 on failure. + * + * This isn't exposed yet, because of potential inefficiency issues. + * Maybe it should be. */ +static int +evbuffer_ptr_subtract(struct evbuffer *buf, struct evbuffer_ptr *pos, + size_t howfar) +{ + if (pos->pos < 0) + return -1; + if (howfar > (size_t)pos->pos) + return -1; + if (pos->internal_.chain && howfar <= pos->internal_.pos_in_chain) { + pos->internal_.pos_in_chain -= howfar; + pos->pos -= howfar; + return 0; + } else { + const size_t newpos = pos->pos - howfar; + /* Here's the inefficient part: it walks over the + * chains until we hit newpos. */ + return evbuffer_ptr_set(buf, pos, newpos, EVBUFFER_PTR_SET); + } +} + +int +evbuffer_ptr_set(struct evbuffer *buf, struct evbuffer_ptr *pos, + size_t position, enum evbuffer_ptr_how how) +{ + size_t left = position; + struct evbuffer_chain *chain = NULL; + int result = 0; + + EVBUFFER_LOCK(buf); + + switch (how) { + case EVBUFFER_PTR_SET: + chain = buf->first; + pos->pos = position; + position = 0; + break; + case EVBUFFER_PTR_ADD: + /* this avoids iterating over all previous chains if + we just want to advance the position */ + if (pos->pos < 0 || EV_SIZE_MAX - position < (size_t)pos->pos) { + EVBUFFER_UNLOCK(buf); + return -1; + } + chain = pos->internal_.chain; + pos->pos += position; + position = pos->internal_.pos_in_chain; + break; + } + + EVUTIL_ASSERT(EV_SIZE_MAX - left >= position); + while (chain && position + left >= chain->off) { + left -= chain->off - position; + chain = chain->next; + position = 0; + } + if (chain) { + pos->internal_.chain = chain; + pos->internal_.pos_in_chain = position + left; + } else if (left == 0) { + /* The first byte in the (nonexistent) chain after the last chain */ + pos->internal_.chain = NULL; + pos->internal_.pos_in_chain = 0; + } else { + PTR_NOT_FOUND(pos); + result = -1; + } + + EVBUFFER_UNLOCK(buf); + + return result; +} + +/** + Compare the bytes in buf at position pos to the len bytes in mem. Return + less than 0, 0, or greater than 0 as memcmp. + */ +static int +evbuffer_ptr_memcmp(const struct evbuffer *buf, const struct evbuffer_ptr *pos, + const char *mem, size_t len) +{ + struct evbuffer_chain *chain; + size_t position; + int r; + + ASSERT_EVBUFFER_LOCKED(buf); + + if (pos->pos < 0 || + EV_SIZE_MAX - len < (size_t)pos->pos || + pos->pos + len > buf->total_len) + return -1; + + chain = pos->internal_.chain; + position = pos->internal_.pos_in_chain; + while (len && chain) { + size_t n_comparable; + if (len + position > chain->off) + n_comparable = chain->off - position; + else + n_comparable = len; + r = memcmp(chain->buffer + chain->misalign + position, mem, + n_comparable); + if (r) + return r; + mem += n_comparable; + len -= n_comparable; + position = 0; + chain = chain->next; + } + + return 0; +} + +struct evbuffer_ptr +evbuffer_search(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start) +{ + return evbuffer_search_range(buffer, what, len, start, NULL); +} + +struct evbuffer_ptr +evbuffer_search_range(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start, const struct evbuffer_ptr *end) +{ + struct evbuffer_ptr pos; + struct evbuffer_chain *chain, *last_chain = NULL; + const unsigned char *p; + char first; + + EVBUFFER_LOCK(buffer); + + if (start) { + memcpy(&pos, start, sizeof(pos)); + chain = pos.internal_.chain; + } else { + pos.pos = 0; + chain = pos.internal_.chain = buffer->first; + pos.internal_.pos_in_chain = 0; + } + + if (end) + last_chain = end->internal_.chain; + + if (!len || len > EV_SSIZE_MAX) + goto done; + + first = what[0]; + + while (chain) { + const unsigned char *start_at = + chain->buffer + chain->misalign + + pos.internal_.pos_in_chain; + p = memchr(start_at, first, + chain->off - pos.internal_.pos_in_chain); + if (p) { + pos.pos += p - start_at; + pos.internal_.pos_in_chain += p - start_at; + if (!evbuffer_ptr_memcmp(buffer, &pos, what, len)) { + if (end && pos.pos + (ev_ssize_t)len > end->pos) + goto not_found; + else + goto done; + } + ++pos.pos; + ++pos.internal_.pos_in_chain; + if (pos.internal_.pos_in_chain == chain->off) { + chain = pos.internal_.chain = chain->next; + pos.internal_.pos_in_chain = 0; + } + } else { + if (chain == last_chain) + goto not_found; + pos.pos += chain->off - pos.internal_.pos_in_chain; + chain = pos.internal_.chain = chain->next; + pos.internal_.pos_in_chain = 0; + } + } + +not_found: + PTR_NOT_FOUND(&pos); +done: + EVBUFFER_UNLOCK(buffer); + return pos; +} + +int +evbuffer_peek(struct evbuffer *buffer, ev_ssize_t len, + struct evbuffer_ptr *start_at, + struct evbuffer_iovec *vec, int n_vec) +{ + struct evbuffer_chain *chain; + int idx = 0; + ev_ssize_t len_so_far = 0; + + /* Avoid locking in trivial edge cases */ + if (start_at && start_at->internal_.chain == NULL) + return 0; + + EVBUFFER_LOCK(buffer); + + if (start_at) { + chain = start_at->internal_.chain; + len_so_far = chain->off + - start_at->internal_.pos_in_chain; + idx = 1; + if (n_vec > 0) { + vec[0].iov_base = chain->buffer + chain->misalign + + start_at->internal_.pos_in_chain; + vec[0].iov_len = len_so_far; + } + chain = chain->next; + } else { + chain = buffer->first; + } + + if (n_vec == 0 && len < 0) { + /* If no vectors are provided and they asked for "everything", + * pretend they asked for the actual available amount. */ + len = buffer->total_len; + if (start_at) { + len -= start_at->pos; + } + } + + while (chain) { + if (len >= 0 && len_so_far >= len) + break; + if (idxbuffer + chain->misalign; + vec[idx].iov_len = chain->off; + } else if (len<0) { + break; + } + ++idx; + len_so_far += chain->off; + chain = chain->next; + } + + EVBUFFER_UNLOCK(buffer); + + return idx; +} + + +int +evbuffer_add_vprintf(struct evbuffer *buf, const char *fmt, va_list ap) +{ + char *buffer; + size_t space; + int sz, result = -1; + va_list aq; + struct evbuffer_chain *chain; + + + EVBUFFER_LOCK(buf); + + if (buf->freeze_end) { + goto done; + } + + /* make sure that at least some space is available */ + if ((chain = evbuffer_expand_singlechain(buf, 64)) == NULL) + goto done; + + for (;;) { +#if 0 + size_t used = chain->misalign + chain->off; + buffer = (char *)chain->buffer + chain->misalign + chain->off; + EVUTIL_ASSERT(chain->buffer_len >= used); + space = chain->buffer_len - used; +#endif + buffer = (char*) CHAIN_SPACE_PTR(chain); + space = (size_t) CHAIN_SPACE_LEN(chain); + +#ifndef va_copy +#define va_copy(dst, src) memcpy(&(dst), &(src), sizeof(va_list)) +#endif + va_copy(aq, ap); + + sz = evutil_vsnprintf(buffer, space, fmt, aq); + + va_end(aq); + + if (sz < 0) + goto done; + if (INT_MAX >= EVBUFFER_CHAIN_MAX && + (size_t)sz >= EVBUFFER_CHAIN_MAX) + goto done; + if ((size_t)sz < space) { + chain->off += sz; + buf->total_len += sz; + buf->n_add_for_cb += sz; + + advance_last_with_data(buf); + evbuffer_invoke_callbacks_(buf); + result = sz; + goto done; + } + if ((chain = evbuffer_expand_singlechain(buf, sz + 1)) == NULL) + goto done; + } + /* NOTREACHED */ + +done: + EVBUFFER_UNLOCK(buf); + return result; +} + +int +evbuffer_add_printf(struct evbuffer *buf, const char *fmt, ...) +{ + int res = -1; + va_list ap; + + va_start(ap, fmt); + res = evbuffer_add_vprintf(buf, fmt, ap); + va_end(ap); + + return (res); +} + +int +evbuffer_add_reference(struct evbuffer *outbuf, + const void *data, size_t datlen, + evbuffer_ref_cleanup_cb cleanupfn, void *extra) +{ + struct evbuffer_chain *chain; + struct evbuffer_chain_reference *info; + int result = -1; + + chain = evbuffer_chain_new(sizeof(struct evbuffer_chain_reference)); + if (!chain) + return (-1); + chain->flags |= EVBUFFER_REFERENCE | EVBUFFER_IMMUTABLE; + chain->buffer = (u_char *)data; + chain->buffer_len = datlen; + chain->off = datlen; + + info = EVBUFFER_CHAIN_EXTRA(struct evbuffer_chain_reference, chain); + info->cleanupfn = cleanupfn; + info->extra = extra; + + EVBUFFER_LOCK(outbuf); + if (outbuf->freeze_end) { + /* don't call chain_free; we do not want to actually invoke + * the cleanup function */ + mm_free(chain); + goto done; + } + evbuffer_chain_insert(outbuf, chain); + outbuf->n_add_for_cb += datlen; + + evbuffer_invoke_callbacks_(outbuf); + + result = 0; +done: + EVBUFFER_UNLOCK(outbuf); + + return result; +} + +/* TODO(niels): we may want to add to automagically convert to mmap, in + * case evbuffer_remove() or evbuffer_pullup() are being used. + */ +struct evbuffer_file_segment * +evbuffer_file_segment_new( + int fd, ev_off_t offset, ev_off_t length, unsigned flags) +{ + struct evbuffer_file_segment *seg = + mm_calloc(sizeof(struct evbuffer_file_segment), 1); + if (!seg) + return NULL; + seg->refcnt = 1; + seg->fd = fd; + seg->flags = flags; + seg->file_offset = offset; + seg->cleanup_cb = NULL; + seg->cleanup_cb_arg = NULL; +#ifdef _WIN32 +#ifndef lseek +#define lseek _lseeki64 +#endif +#ifndef fstat +#define fstat _fstat +#endif +#ifndef stat +#define stat _stat +#endif +#endif + if (length == -1) { + struct stat st; + if (fstat(fd, &st) < 0) + goto err; + length = st.st_size; + } + seg->length = length; + + if (offset < 0 || length < 0 || + ((ev_uint64_t)length > EVBUFFER_CHAIN_MAX) || + (ev_uint64_t)offset > (ev_uint64_t)(EVBUFFER_CHAIN_MAX - length)) + goto err; + +#if defined(USE_SENDFILE) + if (!(flags & EVBUF_FS_DISABLE_SENDFILE)) { + seg->can_sendfile = 1; + goto done; + } +#endif + + if (evbuffer_file_segment_materialize(seg)<0) + goto err; + +#if defined(USE_SENDFILE) +done: +#endif + if (!(flags & EVBUF_FS_DISABLE_LOCKING)) { + EVTHREAD_ALLOC_LOCK(seg->lock, 0); + } + return seg; +err: + mm_free(seg); + return NULL; +} + +#ifdef EVENT__HAVE_MMAP +static long +get_page_size(void) +{ +#ifdef SC_PAGE_SIZE + return sysconf(SC_PAGE_SIZE); +#elif defined(_SC_PAGE_SIZE) + return sysconf(_SC_PAGE_SIZE); +#else + return 1; +#endif +} +#endif + +/* DOCDOC */ +/* Requires lock */ +static int +evbuffer_file_segment_materialize(struct evbuffer_file_segment *seg) +{ + const unsigned flags = seg->flags; + const int fd = seg->fd; + const ev_off_t length = seg->length; + const ev_off_t offset = seg->file_offset; + + if (seg->contents) + return 0; /* already materialized */ + +#if defined(EVENT__HAVE_MMAP) + if (!(flags & EVBUF_FS_DISABLE_MMAP)) { + off_t offset_rounded = 0, offset_leftover = 0; + void *mapped; + if (offset) { + /* mmap implementations don't generally like us + * to have an offset that isn't a round */ + long page_size = get_page_size(); + if (page_size == -1) + goto err; + offset_leftover = offset % page_size; + offset_rounded = offset - offset_leftover; + } + mapped = mmap(NULL, length + offset_leftover, + PROT_READ, +#ifdef MAP_NOCACHE + MAP_NOCACHE | /* ??? */ +#endif +#ifdef MAP_FILE + MAP_FILE | +#endif + MAP_PRIVATE, + fd, offset_rounded); + if (mapped == MAP_FAILED) { + event_warn("%s: mmap(%d, %d, %zu) failed", + __func__, fd, 0, (size_t)(offset + length)); + } else { + seg->mapping = mapped; + seg->contents = (char*)mapped+offset_leftover; + seg->mmap_offset = 0; + seg->is_mapping = 1; + goto done; + } + } +#endif +#ifdef _WIN32 + if (!(flags & EVBUF_FS_DISABLE_MMAP)) { + intptr_t h = _get_osfhandle(fd); + HANDLE m; + ev_uint64_t total_size = length+offset; + if ((HANDLE)h == INVALID_HANDLE_VALUE) + goto err; + m = CreateFileMapping((HANDLE)h, NULL, PAGE_READONLY, + (total_size >> 32), total_size & 0xfffffffful, + NULL); + if (m != INVALID_HANDLE_VALUE) { /* Does h leak? */ + seg->mapping_handle = m; + seg->mmap_offset = offset; + seg->is_mapping = 1; + goto done; + } + } +#endif + { + ev_off_t start_pos = lseek(fd, 0, SEEK_CUR), pos; + ev_off_t read_so_far = 0; + char *mem; + int e; + ev_ssize_t n = 0; + if (!(mem = mm_malloc(length))) + goto err; + if (start_pos < 0) { + mm_free(mem); + goto err; + } + if (lseek(fd, offset, SEEK_SET) < 0) { + mm_free(mem); + goto err; + } + while (read_so_far < length) { + n = read(fd, mem+read_so_far, length-read_so_far); + if (n <= 0) + break; + read_so_far += n; + } + + e = errno; + pos = lseek(fd, start_pos, SEEK_SET); + if (n < 0 || (n == 0 && length > read_so_far)) { + mm_free(mem); + errno = e; + goto err; + } else if (pos < 0) { + mm_free(mem); + goto err; + } + + seg->contents = mem; + } + +done: + return 0; +err: + return -1; +} + +void evbuffer_file_segment_add_cleanup_cb(struct evbuffer_file_segment *seg, + evbuffer_file_segment_cleanup_cb cb, void* arg) +{ + EVUTIL_ASSERT(seg->refcnt > 0); + seg->cleanup_cb = cb; + seg->cleanup_cb_arg = arg; +} + +void +evbuffer_file_segment_free(struct evbuffer_file_segment *seg) +{ + int refcnt; + EVLOCK_LOCK(seg->lock, 0); + refcnt = --seg->refcnt; + EVLOCK_UNLOCK(seg->lock, 0); + if (refcnt > 0) + return; + EVUTIL_ASSERT(refcnt == 0); + + if (seg->is_mapping) { +#ifdef _WIN32 + CloseHandle(seg->mapping_handle); +#elif defined (EVENT__HAVE_MMAP) + off_t offset_leftover; + offset_leftover = seg->file_offset % get_page_size(); + if (munmap(seg->mapping, seg->length + offset_leftover) == -1) + event_warn("%s: munmap failed", __func__); +#endif + } else if (seg->contents) { + mm_free(seg->contents); + } + + if ((seg->flags & EVBUF_FS_CLOSE_ON_FREE) && seg->fd >= 0) { + close(seg->fd); + } + + if (seg->cleanup_cb) { + (*seg->cleanup_cb)((struct evbuffer_file_segment const*)seg, + seg->flags, seg->cleanup_cb_arg); + seg->cleanup_cb = NULL; + seg->cleanup_cb_arg = NULL; + } + + EVTHREAD_FREE_LOCK(seg->lock, 0); + mm_free(seg); +} + +int +evbuffer_add_file_segment(struct evbuffer *buf, + struct evbuffer_file_segment *seg, ev_off_t offset, ev_off_t length) +{ + struct evbuffer_chain *chain; + struct evbuffer_chain_file_segment *extra; + int can_use_sendfile = 0; + + EVBUFFER_LOCK(buf); + EVLOCK_LOCK(seg->lock, 0); + if (buf->flags & EVBUFFER_FLAG_DRAINS_TO_FD) { + can_use_sendfile = 1; + } else { + if (!seg->contents) { + if (evbuffer_file_segment_materialize(seg)<0) { + EVLOCK_UNLOCK(seg->lock, 0); + EVBUFFER_UNLOCK(buf); + return -1; + } + } + } + ++seg->refcnt; + EVLOCK_UNLOCK(seg->lock, 0); + + if (buf->freeze_end) + goto err; + + if (length < 0) { + if (offset > seg->length) + goto err; + length = seg->length - offset; + } + + /* Can we actually add this? */ + if (offset+length > seg->length) + goto err; + + chain = evbuffer_chain_new(sizeof(struct evbuffer_chain_file_segment)); + if (!chain) + goto err; + extra = EVBUFFER_CHAIN_EXTRA(struct evbuffer_chain_file_segment, chain); + + chain->flags |= EVBUFFER_IMMUTABLE|EVBUFFER_FILESEGMENT; + if (can_use_sendfile && seg->can_sendfile) { + chain->flags |= EVBUFFER_SENDFILE; + chain->misalign = seg->file_offset + offset; + chain->off = length; + chain->buffer_len = chain->misalign + length; + } else if (seg->is_mapping) { +#ifdef _WIN32 + ev_uint64_t total_offset = seg->mmap_offset+offset; + ev_uint64_t offset_rounded=0, offset_remaining=0; + LPVOID data; + if (total_offset) { + SYSTEM_INFO si; + memset(&si, 0, sizeof(si)); /* cargo cult */ + GetSystemInfo(&si); + offset_remaining = total_offset % si.dwAllocationGranularity; + offset_rounded = total_offset - offset_remaining; + } + data = MapViewOfFile( + seg->mapping_handle, + FILE_MAP_READ, + offset_rounded >> 32, + offset_rounded & 0xfffffffful, + length + offset_remaining); + if (data == NULL) { + mm_free(chain); + goto err; + } + chain->buffer = (unsigned char*) data; + chain->buffer_len = length+offset_remaining; + chain->misalign = offset_remaining; + chain->off = length; +#else + chain->buffer = (unsigned char*)(seg->contents + offset); + chain->buffer_len = length; + chain->off = length; +#endif + } else { + chain->buffer = (unsigned char*)(seg->contents + offset); + chain->buffer_len = length; + chain->off = length; + } + + extra->segment = seg; + buf->n_add_for_cb += length; + evbuffer_chain_insert(buf, chain); + + evbuffer_invoke_callbacks_(buf); + + EVBUFFER_UNLOCK(buf); + + return 0; +err: + EVBUFFER_UNLOCK(buf); + evbuffer_file_segment_free(seg); /* Lowers the refcount */ + return -1; +} + +int +evbuffer_add_file(struct evbuffer *buf, int fd, ev_off_t offset, ev_off_t length) +{ + struct evbuffer_file_segment *seg; + unsigned flags = EVBUF_FS_CLOSE_ON_FREE; + int r; + + seg = evbuffer_file_segment_new(fd, offset, length, flags); + if (!seg) + return -1; + r = evbuffer_add_file_segment(buf, seg, 0, length); + if (r == 0) + evbuffer_file_segment_free(seg); + return r; +} + +void +evbuffer_setcb(struct evbuffer *buffer, evbuffer_cb cb, void *cbarg) +{ + EVBUFFER_LOCK(buffer); + + if (!LIST_EMPTY(&buffer->callbacks)) + evbuffer_remove_all_callbacks(buffer); + + if (cb) { + struct evbuffer_cb_entry *ent = + evbuffer_add_cb(buffer, NULL, cbarg); + ent->cb.cb_obsolete = cb; + ent->flags |= EVBUFFER_CB_OBSOLETE; + } + EVBUFFER_UNLOCK(buffer); +} + +struct evbuffer_cb_entry * +evbuffer_add_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg) +{ + struct evbuffer_cb_entry *e; + if (! (e = mm_calloc(1, sizeof(struct evbuffer_cb_entry)))) + return NULL; + EVBUFFER_LOCK(buffer); + e->cb.cb_func = cb; + e->cbarg = cbarg; + e->flags = EVBUFFER_CB_ENABLED; + LIST_INSERT_HEAD(&buffer->callbacks, e, next); + EVBUFFER_UNLOCK(buffer); + return e; +} + +int +evbuffer_remove_cb_entry(struct evbuffer *buffer, + struct evbuffer_cb_entry *ent) +{ + EVBUFFER_LOCK(buffer); + LIST_REMOVE(ent, next); + EVBUFFER_UNLOCK(buffer); + mm_free(ent); + return 0; +} + +int +evbuffer_remove_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg) +{ + struct evbuffer_cb_entry *cbent; + int result = -1; + EVBUFFER_LOCK(buffer); + LIST_FOREACH(cbent, &buffer->callbacks, next) { + if (cb == cbent->cb.cb_func && cbarg == cbent->cbarg) { + result = evbuffer_remove_cb_entry(buffer, cbent); + goto done; + } + } +done: + EVBUFFER_UNLOCK(buffer); + return result; +} + +int +evbuffer_cb_set_flags(struct evbuffer *buffer, + struct evbuffer_cb_entry *cb, ev_uint32_t flags) +{ + /* the user isn't allowed to mess with these. */ + flags &= ~EVBUFFER_CB_INTERNAL_FLAGS; + EVBUFFER_LOCK(buffer); + cb->flags |= flags; + EVBUFFER_UNLOCK(buffer); + return 0; +} + +int +evbuffer_cb_clear_flags(struct evbuffer *buffer, + struct evbuffer_cb_entry *cb, ev_uint32_t flags) +{ + /* the user isn't allowed to mess with these. */ + flags &= ~EVBUFFER_CB_INTERNAL_FLAGS; + EVBUFFER_LOCK(buffer); + cb->flags &= ~flags; + EVBUFFER_UNLOCK(buffer); + return 0; +} + +int +evbuffer_freeze(struct evbuffer *buffer, int start) +{ + EVBUFFER_LOCK(buffer); + if (start) + buffer->freeze_start = 1; + else + buffer->freeze_end = 1; + EVBUFFER_UNLOCK(buffer); + return 0; +} + +int +evbuffer_unfreeze(struct evbuffer *buffer, int start) +{ + EVBUFFER_LOCK(buffer); + if (start) + buffer->freeze_start = 0; + else + buffer->freeze_end = 0; + EVBUFFER_UNLOCK(buffer); + return 0; +} + +#if 0 +void +evbuffer_cb_suspend(struct evbuffer *buffer, struct evbuffer_cb_entry *cb) +{ + if (!(cb->flags & EVBUFFER_CB_SUSPENDED)) { + cb->size_before_suspend = evbuffer_get_length(buffer); + cb->flags |= EVBUFFER_CB_SUSPENDED; + } +} + +void +evbuffer_cb_unsuspend(struct evbuffer *buffer, struct evbuffer_cb_entry *cb) +{ + if ((cb->flags & EVBUFFER_CB_SUSPENDED)) { + unsigned call = (cb->flags & EVBUFFER_CB_CALL_ON_UNSUSPEND); + size_t sz = cb->size_before_suspend; + cb->flags &= ~(EVBUFFER_CB_SUSPENDED| + EVBUFFER_CB_CALL_ON_UNSUSPEND); + cb->size_before_suspend = 0; + if (call && (cb->flags & EVBUFFER_CB_ENABLED)) { + cb->cb(buffer, sz, evbuffer_get_length(buffer), cb->cbarg); + } + } +} +#endif + +int +evbuffer_get_callbacks_(struct evbuffer *buffer, struct event_callback **cbs, + int max_cbs) +{ + int r = 0; + EVBUFFER_LOCK(buffer); + if (buffer->deferred_cbs) { + if (max_cbs < 1) { + r = -1; + goto done; + } + cbs[0] = &buffer->deferred; + r = 1; + } +done: + EVBUFFER_UNLOCK(buffer); + return r; +} diff --git a/contrib/ntp/sntp/libevent/buffer_iocp.c b/contrib/ntp/sntp/libevent/buffer_iocp.c new file mode 100644 index 000000000..2d76a90e7 --- /dev/null +++ b/contrib/ntp/sntp/libevent/buffer_iocp.c @@ -0,0 +1,326 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/** + @file buffer_iocp.c + + This module implements overlapped read and write functions for evbuffer + objects on Windows. +*/ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include "event2/buffer.h" +#include "event2/buffer_compat.h" +#include "event2/util.h" +#include "event2/thread.h" +#include "util-internal.h" +#include "evthread-internal.h" +#include "evbuffer-internal.h" +#include "iocp-internal.h" +#include "mm-internal.h" + +#include +#include +#include + +#define MAX_WSABUFS 16 + +/** An evbuffer that can handle overlapped IO. */ +struct evbuffer_overlapped { + struct evbuffer buffer; + /** The socket that we're doing overlapped IO on. */ + evutil_socket_t fd; + + /** pending I/O type */ + unsigned read_in_progress : 1; + unsigned write_in_progress : 1; + + /** The first pinned chain in the buffer. */ + struct evbuffer_chain *first_pinned; + + /** How many chains are pinned; how many of the fields in buffers + * are we using. */ + int n_buffers; + WSABUF buffers[MAX_WSABUFS]; +}; + +/** Given an evbuffer, return the correponding evbuffer structure, or NULL if + * the evbuffer isn't overlapped. */ +static inline struct evbuffer_overlapped * +upcast_evbuffer(struct evbuffer *buf) +{ + if (!buf || !buf->is_overlapped) + return NULL; + return EVUTIL_UPCAST(buf, struct evbuffer_overlapped, buffer); +} + +/** Unpin all the chains noted as pinned in 'eo'. */ +static void +pin_release(struct evbuffer_overlapped *eo, unsigned flag) +{ + int i; + struct evbuffer_chain *next, *chain = eo->first_pinned; + + for (i = 0; i < eo->n_buffers; ++i) { + EVUTIL_ASSERT(chain); + next = chain->next; + evbuffer_chain_unpin_(chain, flag); + chain = next; + } +} + +void +evbuffer_commit_read_(struct evbuffer *evbuf, ev_ssize_t nBytes) +{ + struct evbuffer_overlapped *buf = upcast_evbuffer(evbuf); + struct evbuffer_chain **chainp; + size_t remaining, len; + unsigned i; + + EVBUFFER_LOCK(evbuf); + EVUTIL_ASSERT(buf->read_in_progress && !buf->write_in_progress); + EVUTIL_ASSERT(nBytes >= 0); /* XXXX Can this be false? */ + + evbuffer_unfreeze(evbuf, 0); + + chainp = evbuf->last_with_datap; + if (!((*chainp)->flags & EVBUFFER_MEM_PINNED_R)) + chainp = &(*chainp)->next; + remaining = nBytes; + for (i = 0; remaining > 0 && i < (unsigned)buf->n_buffers; ++i) { + EVUTIL_ASSERT(*chainp); + len = buf->buffers[i].len; + if (remaining < len) + len = remaining; + (*chainp)->off += len; + evbuf->last_with_datap = chainp; + remaining -= len; + chainp = &(*chainp)->next; + } + + pin_release(buf, EVBUFFER_MEM_PINNED_R); + + buf->read_in_progress = 0; + + evbuf->total_len += nBytes; + evbuf->n_add_for_cb += nBytes; + + evbuffer_invoke_callbacks_(evbuf); + + evbuffer_decref_and_unlock_(evbuf); +} + +void +evbuffer_commit_write_(struct evbuffer *evbuf, ev_ssize_t nBytes) +{ + struct evbuffer_overlapped *buf = upcast_evbuffer(evbuf); + + EVBUFFER_LOCK(evbuf); + EVUTIL_ASSERT(buf->write_in_progress && !buf->read_in_progress); + evbuffer_unfreeze(evbuf, 1); + evbuffer_drain(evbuf, nBytes); + pin_release(buf,EVBUFFER_MEM_PINNED_W); + buf->write_in_progress = 0; + evbuffer_decref_and_unlock_(evbuf); +} + +struct evbuffer * +evbuffer_overlapped_new_(evutil_socket_t fd) +{ + struct evbuffer_overlapped *evo; + + evo = mm_calloc(1, sizeof(struct evbuffer_overlapped)); + if (!evo) + return NULL; + + LIST_INIT(&evo->buffer.callbacks); + evo->buffer.refcnt = 1; + evo->buffer.last_with_datap = &evo->buffer.first; + + evo->buffer.is_overlapped = 1; + evo->fd = fd; + + return &evo->buffer; +} + +int +evbuffer_launch_write_(struct evbuffer *buf, ev_ssize_t at_most, + struct event_overlapped *ol) +{ + struct evbuffer_overlapped *buf_o = upcast_evbuffer(buf); + int r = -1; + int i; + struct evbuffer_chain *chain; + DWORD bytesSent; + + if (!buf) { + /* No buffer, or it isn't overlapped */ + return -1; + } + + EVBUFFER_LOCK(buf); + EVUTIL_ASSERT(!buf_o->read_in_progress); + if (buf->freeze_start || buf_o->write_in_progress) + goto done; + if (!buf->total_len) { + /* Nothing to write */ + r = 0; + goto done; + } else if (at_most < 0 || (size_t)at_most > buf->total_len) { + at_most = buf->total_len; + } + evbuffer_freeze(buf, 1); + + buf_o->first_pinned = NULL; + buf_o->n_buffers = 0; + memset(buf_o->buffers, 0, sizeof(buf_o->buffers)); + + chain = buf_o->first_pinned = buf->first; + + for (i=0; i < MAX_WSABUFS && chain; ++i, chain=chain->next) { + WSABUF *b = &buf_o->buffers[i]; + b->buf = (char*)( chain->buffer + chain->misalign ); + evbuffer_chain_pin_(chain, EVBUFFER_MEM_PINNED_W); + + if ((size_t)at_most > chain->off) { + /* XXXX Cast is safe for now, since win32 has no + mmaped chains. But later, we need to have this + add more WSAbufs if chain->off is greater than + ULONG_MAX */ + b->len = (unsigned long)chain->off; + at_most -= chain->off; + } else { + b->len = (unsigned long)at_most; + ++i; + break; + } + } + + buf_o->n_buffers = i; + evbuffer_incref_(buf); + if (WSASend(buf_o->fd, buf_o->buffers, i, &bytesSent, 0, + &ol->overlapped, NULL)) { + int error = WSAGetLastError(); + if (error != WSA_IO_PENDING) { + /* An actual error. */ + pin_release(buf_o, EVBUFFER_MEM_PINNED_W); + evbuffer_unfreeze(buf, 1); + evbuffer_free(buf); /* decref */ + goto done; + } + } + + buf_o->write_in_progress = 1; + r = 0; +done: + EVBUFFER_UNLOCK(buf); + return r; +} + +int +evbuffer_launch_read_(struct evbuffer *buf, size_t at_most, + struct event_overlapped *ol) +{ + struct evbuffer_overlapped *buf_o = upcast_evbuffer(buf); + int r = -1, i; + int nvecs; + int npin=0; + struct evbuffer_chain *chain=NULL, **chainp; + DWORD bytesRead; + DWORD flags = 0; + struct evbuffer_iovec vecs[MAX_WSABUFS]; + + if (!buf_o) + return -1; + EVBUFFER_LOCK(buf); + EVUTIL_ASSERT(!buf_o->write_in_progress); + if (buf->freeze_end || buf_o->read_in_progress) + goto done; + + buf_o->first_pinned = NULL; + buf_o->n_buffers = 0; + memset(buf_o->buffers, 0, sizeof(buf_o->buffers)); + + if (evbuffer_expand_fast_(buf, at_most, MAX_WSABUFS) == -1) + goto done; + evbuffer_freeze(buf, 0); + + nvecs = evbuffer_read_setup_vecs_(buf, at_most, + vecs, MAX_WSABUFS, &chainp, 1); + for (i=0;ibuffers[i], + &vecs[i]); + } + + buf_o->n_buffers = nvecs; + buf_o->first_pinned = chain = *chainp; + + npin=0; + for ( ; chain; chain = chain->next) { + evbuffer_chain_pin_(chain, EVBUFFER_MEM_PINNED_R); + ++npin; + } + EVUTIL_ASSERT(npin == nvecs); + + evbuffer_incref_(buf); + if (WSARecv(buf_o->fd, buf_o->buffers, nvecs, &bytesRead, &flags, + &ol->overlapped, NULL)) { + int error = WSAGetLastError(); + if (error != WSA_IO_PENDING) { + /* An actual error. */ + pin_release(buf_o, EVBUFFER_MEM_PINNED_R); + evbuffer_unfreeze(buf, 0); + evbuffer_free(buf); /* decref */ + goto done; + } + } + + buf_o->read_in_progress = 1; + r = 0; +done: + EVBUFFER_UNLOCK(buf); + return r; +} + +evutil_socket_t +evbuffer_overlapped_get_fd_(struct evbuffer *buf) +{ + struct evbuffer_overlapped *buf_o = upcast_evbuffer(buf); + return buf_o ? buf_o->fd : -1; +} + +void +evbuffer_overlapped_set_fd_(struct evbuffer *buf, evutil_socket_t fd) +{ + struct evbuffer_overlapped *buf_o = upcast_evbuffer(buf); + EVBUFFER_LOCK(buf); + /* XXX is this right?, should it cancel current I/O operations? */ + if (buf_o) + buf_o->fd = fd; + EVBUFFER_UNLOCK(buf); +} diff --git a/contrib/ntp/sntp/libevent/bufferevent-internal.h b/contrib/ntp/sntp/libevent/bufferevent-internal.h new file mode 100644 index 000000000..134bb3375 --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent-internal.h @@ -0,0 +1,450 @@ +/* + * Copyright (c) 2008-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef BUFFEREVENT_INTERNAL_H_INCLUDED_ +#define BUFFEREVENT_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "event2/event-config.h" +#include "event2/event_struct.h" +#include "evconfig-private.h" +#include "event2/util.h" +#include "defer-internal.h" +#include "evthread-internal.h" +#include "event2/thread.h" +#include "ratelim-internal.h" +#include "event2/bufferevent_struct.h" + +/* These flags are reasons that we might be declining to actually enable + reading or writing on a bufferevent. + */ + +/* On a all bufferevents, for reading: used when we have read up to the + watermark value. + + On a filtering bufferevent, for writing: used when the underlying + bufferevent's write buffer has been filled up to its watermark + value. +*/ +#define BEV_SUSPEND_WM 0x01 +/* On a base bufferevent: when we have emptied a bandwidth buckets */ +#define BEV_SUSPEND_BW 0x02 +/* On a base bufferevent: when we have emptied the group's bandwidth bucket. */ +#define BEV_SUSPEND_BW_GROUP 0x04 +/* On a socket bufferevent: can't do any operations while we're waiting for + * name lookup to finish. */ +#define BEV_SUSPEND_LOOKUP 0x08 +/* On a base bufferevent, for reading: used when a filter has choked this + * (underlying) bufferevent because it has stopped reading from it. */ +#define BEV_SUSPEND_FILT_READ 0x10 + +typedef ev_uint16_t bufferevent_suspend_flags; + +struct bufferevent_rate_limit_group { + /** List of all members in the group */ + LIST_HEAD(rlim_group_member_list, bufferevent_private) members; + /** Current limits for the group. */ + struct ev_token_bucket rate_limit; + struct ev_token_bucket_cfg rate_limit_cfg; + + /** True iff we don't want to read from any member of the group.until + * the token bucket refills. */ + unsigned read_suspended : 1; + /** True iff we don't want to write from any member of the group.until + * the token bucket refills. */ + unsigned write_suspended : 1; + /** True iff we were unable to suspend one of the bufferevents in the + * group for reading the last time we tried, and we should try + * again. */ + unsigned pending_unsuspend_read : 1; + /** True iff we were unable to suspend one of the bufferevents in the + * group for writing the last time we tried, and we should try + * again. */ + unsigned pending_unsuspend_write : 1; + + /*@{*/ + /** Total number of bytes read or written in this group since last + * reset. */ + ev_uint64_t total_read; + ev_uint64_t total_written; + /*@}*/ + + /** The number of bufferevents in the group. */ + int n_members; + + /** The smallest number of bytes that any member of the group should + * be limited to read or write at a time. */ + ev_ssize_t min_share; + ev_ssize_t configured_min_share; + + /** Timeout event that goes off once a tick, when the bucket is ready + * to refill. */ + struct event master_refill_event; + + /** Seed for weak random number generator. Protected by 'lock' */ + struct evutil_weakrand_state weakrand_seed; + + /** Lock to protect the members of this group. This lock should nest + * within every bufferevent lock: if you are holding this lock, do + * not assume you can lock another bufferevent. */ + void *lock; +}; + +/** Fields for rate-limiting a single bufferevent. */ +struct bufferevent_rate_limit { + /* Linked-list elements for storing this bufferevent_private in a + * group. + * + * Note that this field is supposed to be protected by the group + * lock */ + LIST_ENTRY(bufferevent_private) next_in_group; + /** The rate-limiting group for this bufferevent, or NULL if it is + * only rate-limited on its own. */ + struct bufferevent_rate_limit_group *group; + + /* This bufferevent's current limits. */ + struct ev_token_bucket limit; + /* Pointer to the rate-limit configuration for this bufferevent. + * Can be shared. XXX reference-count this? */ + struct ev_token_bucket_cfg *cfg; + + /* Timeout event used when one this bufferevent's buckets are + * empty. */ + struct event refill_bucket_event; +}; + +/** Parts of the bufferevent structure that are shared among all bufferevent + * types, but not exposed in bufferevent_struct.h. */ +struct bufferevent_private { + /** The underlying bufferevent structure. */ + struct bufferevent bev; + + /** Evbuffer callback to enforce watermarks on input. */ + struct evbuffer_cb_entry *read_watermarks_cb; + + /** If set, we should free the lock when we free the bufferevent. */ + unsigned own_lock : 1; + + /** Flag: set if we have deferred callbacks and a read callback is + * pending. */ + unsigned readcb_pending : 1; + /** Flag: set if we have deferred callbacks and a write callback is + * pending. */ + unsigned writecb_pending : 1; + /** Flag: set if we are currently busy connecting. */ + unsigned connecting : 1; + /** Flag: set if a connect failed prematurely; this is a hack for + * getting around the bufferevent abstraction. */ + unsigned connection_refused : 1; + /** Set to the events pending if we have deferred callbacks and + * an events callback is pending. */ + short eventcb_pending; + + /** If set, read is suspended until one or more conditions are over. + * The actual value here is a bitfield of those conditions; see the + * BEV_SUSPEND_* flags above. */ + bufferevent_suspend_flags read_suspended; + + /** If set, writing is suspended until one or more conditions are over. + * The actual value here is a bitfield of those conditions; see the + * BEV_SUSPEND_* flags above. */ + bufferevent_suspend_flags write_suspended; + + /** Set to the current socket errno if we have deferred callbacks and + * an events callback is pending. */ + int errno_pending; + + /** The DNS error code for bufferevent_socket_connect_hostname */ + int dns_error; + + /** Used to implement deferred callbacks */ + struct event_callback deferred; + + /** The options this bufferevent was constructed with */ + enum bufferevent_options options; + + /** Current reference count for this bufferevent. */ + int refcnt; + + /** Lock for this bufferevent. Shared by the inbuf and the outbuf. + * If NULL, locking is disabled. */ + void *lock; + + /** No matter how big our bucket gets, don't try to read more than this + * much in a single read operation. */ + ev_ssize_t max_single_read; + + /** No matter how big our bucket gets, don't try to write more than this + * much in a single write operation. */ + ev_ssize_t max_single_write; + + /** Rate-limiting information for this bufferevent */ + struct bufferevent_rate_limit *rate_limiting; +}; + +/** Possible operations for a control callback. */ +enum bufferevent_ctrl_op { + BEV_CTRL_SET_FD, + BEV_CTRL_GET_FD, + BEV_CTRL_GET_UNDERLYING, + BEV_CTRL_CANCEL_ALL +}; + +/** Possible data types for a control callback */ +union bufferevent_ctrl_data { + void *ptr; + evutil_socket_t fd; +}; + +/** + Implementation table for a bufferevent: holds function pointers and other + information to make the various bufferevent types work. +*/ +struct bufferevent_ops { + /** The name of the bufferevent's type. */ + const char *type; + /** At what offset into the implementation type will we find a + bufferevent structure? + + Example: if the type is implemented as + struct bufferevent_x { + int extra_data; + struct bufferevent bev; + } + then mem_offset should be offsetof(struct bufferevent_x, bev) + */ + off_t mem_offset; + + /** Enables one or more of EV_READ|EV_WRITE on a bufferevent. Does + not need to adjust the 'enabled' field. Returns 0 on success, -1 + on failure. + */ + int (*enable)(struct bufferevent *, short); + + /** Disables one or more of EV_READ|EV_WRITE on a bufferevent. Does + not need to adjust the 'enabled' field. Returns 0 on success, -1 + on failure. + */ + int (*disable)(struct bufferevent *, short); + + /** Detatches the bufferevent from related data structures. Called as + * soon as its reference count reaches 0. */ + void (*unlink)(struct bufferevent *); + + /** Free any storage and deallocate any extra data or structures used + in this implementation. Called when the bufferevent is + finalized. + */ + void (*destruct)(struct bufferevent *); + + /** Called when the timeouts on the bufferevent have changed.*/ + int (*adj_timeouts)(struct bufferevent *); + + /** Called to flush data. */ + int (*flush)(struct bufferevent *, short, enum bufferevent_flush_mode); + + /** Called to access miscellaneous fields. */ + int (*ctrl)(struct bufferevent *, enum bufferevent_ctrl_op, union bufferevent_ctrl_data *); + +}; + +extern const struct bufferevent_ops bufferevent_ops_socket; +extern const struct bufferevent_ops bufferevent_ops_filter; +extern const struct bufferevent_ops bufferevent_ops_pair; + +#define BEV_IS_SOCKET(bevp) ((bevp)->be_ops == &bufferevent_ops_socket) +#define BEV_IS_FILTER(bevp) ((bevp)->be_ops == &bufferevent_ops_filter) +#define BEV_IS_PAIR(bevp) ((bevp)->be_ops == &bufferevent_ops_pair) + +#ifdef _WIN32 +extern const struct bufferevent_ops bufferevent_ops_async; +#define BEV_IS_ASYNC(bevp) ((bevp)->be_ops == &bufferevent_ops_async) +#else +#define BEV_IS_ASYNC(bevp) 0 +#endif + +/** Initialize the shared parts of a bufferevent. */ +int bufferevent_init_common_(struct bufferevent_private *, struct event_base *, const struct bufferevent_ops *, enum bufferevent_options options); + +/** For internal use: temporarily stop all reads on bufev, until the conditions + * in 'what' are over. */ +void bufferevent_suspend_read_(struct bufferevent *bufev, bufferevent_suspend_flags what); +/** For internal use: clear the conditions 'what' on bufev, and re-enable + * reading if there are no conditions left. */ +void bufferevent_unsuspend_read_(struct bufferevent *bufev, bufferevent_suspend_flags what); + +/** For internal use: temporarily stop all writes on bufev, until the conditions + * in 'what' are over. */ +void bufferevent_suspend_write_(struct bufferevent *bufev, bufferevent_suspend_flags what); +/** For internal use: clear the conditions 'what' on bufev, and re-enable + * writing if there are no conditions left. */ +void bufferevent_unsuspend_write_(struct bufferevent *bufev, bufferevent_suspend_flags what); + +#define bufferevent_wm_suspend_read(b) \ + bufferevent_suspend_read_((b), BEV_SUSPEND_WM) +#define bufferevent_wm_unsuspend_read(b) \ + bufferevent_unsuspend_read_((b), BEV_SUSPEND_WM) + +/* + Disable a bufferevent. Equivalent to bufferevent_disable(), but + first resets 'connecting' flag to force EV_WRITE down for sure. + + XXXX this method will go away in the future; try not to add new users. + See comment in evhttp_connection_reset_() for discussion. + + @param bufev the bufferevent to be disabled + @param event any combination of EV_READ | EV_WRITE. + @return 0 if successful, or -1 if an error occurred + @see bufferevent_disable() + */ +int bufferevent_disable_hard_(struct bufferevent *bufev, short event); + +/** Internal: Set up locking on a bufferevent. If lock is set, use it. + * Otherwise, use a new lock. */ +int bufferevent_enable_locking_(struct bufferevent *bufev, void *lock); +/** Internal: Increment the reference count on bufev. */ +void bufferevent_incref_(struct bufferevent *bufev); +/** Internal: Lock bufev and increase its reference count. + * unlocking it otherwise. */ +void bufferevent_incref_and_lock_(struct bufferevent *bufev); +/** Internal: Decrement the reference count on bufev. Returns 1 if it freed + * the bufferevent.*/ +int bufferevent_decref_(struct bufferevent *bufev); +/** Internal: Drop the reference count on bufev, freeing as necessary, and + * unlocking it otherwise. Returns 1 if it freed the bufferevent. */ +int bufferevent_decref_and_unlock_(struct bufferevent *bufev); + +/** Internal: If callbacks are deferred and we have a read callback, schedule + * a readcb. Otherwise just run the readcb. Ignores watermarks. */ +void bufferevent_run_readcb_(struct bufferevent *bufev, int options); +/** Internal: If callbacks are deferred and we have a write callback, schedule + * a writecb. Otherwise just run the writecb. Ignores watermarks. */ +void bufferevent_run_writecb_(struct bufferevent *bufev, int options); +/** Internal: If callbacks are deferred and we have an eventcb, schedule + * it to run with events "what". Otherwise just run the eventcb. + * See bufferevent_trigger_event for meaning of "options". */ +void bufferevent_run_eventcb_(struct bufferevent *bufev, short what, int options); + +/** Internal: Run or schedule (if deferred or options contain + * BEV_TRIG_DEFER_CALLBACKS) I/O callbacks specified in iotype. + * Must already hold the bufev lock. Honors watermarks unless + * BEV_TRIG_IGNORE_WATERMARKS is in options. */ +static inline void bufferevent_trigger_nolock_(struct bufferevent *bufev, short iotype, int options); + +/* Making this inline since all of the common-case calls to this function in + * libevent use constant arguments. */ +static inline void +bufferevent_trigger_nolock_(struct bufferevent *bufev, short iotype, int options) +{ + if ((iotype & EV_READ) && ((options & BEV_TRIG_IGNORE_WATERMARKS) || + evbuffer_get_length(bufev->input) >= bufev->wm_read.low)) + bufferevent_run_readcb_(bufev, options); + if ((iotype & EV_WRITE) && ((options & BEV_TRIG_IGNORE_WATERMARKS) || + evbuffer_get_length(bufev->output) <= bufev->wm_write.low)) + bufferevent_run_writecb_(bufev, options); +} + +/** Internal: Add the event 'ev' with timeout tv, unless tv is set to 0, in + * which case add ev with no timeout. */ +int bufferevent_add_event_(struct event *ev, const struct timeval *tv); + +/* ========= + * These next functions implement timeouts for bufferevents that aren't doing + * anything else with ev_read and ev_write, to handle timeouts. + * ========= */ +/** Internal use: Set up the ev_read and ev_write callbacks so that + * the other "generic_timeout" functions will work on it. Call this from + * the constructor function. */ +void bufferevent_init_generic_timeout_cbs_(struct bufferevent *bev); +/** Internal use: Add or delete the generic timeout events as appropriate. + * (If an event is enabled and a timeout is set, we add the event. Otherwise + * we delete it.) Call this from anything that changes the timeout values, + * that enabled EV_READ or EV_WRITE, or that disables EV_READ or EV_WRITE. */ +int bufferevent_generic_adj_timeouts_(struct bufferevent *bev); + +enum bufferevent_options bufferevent_get_options_(struct bufferevent *bev); + +/** Internal use: We have just successfully read data into an inbuf, so + * reset the read timeout (if any). */ +#define BEV_RESET_GENERIC_READ_TIMEOUT(bev) \ + do { \ + if (evutil_timerisset(&(bev)->timeout_read)) \ + event_add(&(bev)->ev_read, &(bev)->timeout_read); \ + } while (0) +/** Internal use: We have just successfully written data from an inbuf, so + * reset the read timeout (if any). */ +#define BEV_RESET_GENERIC_WRITE_TIMEOUT(bev) \ + do { \ + if (evutil_timerisset(&(bev)->timeout_write)) \ + event_add(&(bev)->ev_write, &(bev)->timeout_write); \ + } while (0) +#define BEV_DEL_GENERIC_READ_TIMEOUT(bev) \ + event_del(&(bev)->ev_read) +#define BEV_DEL_GENERIC_WRITE_TIMEOUT(bev) \ + event_del(&(bev)->ev_write) + + +/** Internal: Given a bufferevent, return its corresponding + * bufferevent_private. */ +#define BEV_UPCAST(b) EVUTIL_UPCAST((b), struct bufferevent_private, bev) + +#ifdef EVENT__DISABLE_THREAD_SUPPORT +#define BEV_LOCK(b) EVUTIL_NIL_STMT_ +#define BEV_UNLOCK(b) EVUTIL_NIL_STMT_ +#else +/** Internal: Grab the lock (if any) on a bufferevent */ +#define BEV_LOCK(b) do { \ + struct bufferevent_private *locking = BEV_UPCAST(b); \ + EVLOCK_LOCK(locking->lock, 0); \ + } while (0) + +/** Internal: Release the lock (if any) on a bufferevent */ +#define BEV_UNLOCK(b) do { \ + struct bufferevent_private *locking = BEV_UPCAST(b); \ + EVLOCK_UNLOCK(locking->lock, 0); \ + } while (0) +#endif + + +/* ==== For rate-limiting. */ + +int bufferevent_decrement_write_buckets_(struct bufferevent_private *bev, + ev_ssize_t bytes); +int bufferevent_decrement_read_buckets_(struct bufferevent_private *bev, + ev_ssize_t bytes); +ev_ssize_t bufferevent_get_read_max_(struct bufferevent_private *bev); +ev_ssize_t bufferevent_get_write_max_(struct bufferevent_private *bev); + +int bufferevent_ratelim_init_(struct bufferevent_private *bev); + +#ifdef __cplusplus +} +#endif + + +#endif /* BUFFEREVENT_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/bufferevent.c b/contrib/ntp/sntp/libevent/bufferevent.c new file mode 100644 index 000000000..d298d0b3f --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent.c @@ -0,0 +1,989 @@ +/* + * Copyright (c) 2002-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos, Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#include +#include +#include +#include +#ifdef EVENT__HAVE_STDARG_H +#include +#endif + +#ifdef _WIN32 +#include +#endif +#include + +#include "event2/util.h" +#include "event2/buffer.h" +#include "event2/buffer_compat.h" +#include "event2/bufferevent.h" +#include "event2/bufferevent_struct.h" +#include "event2/bufferevent_compat.h" +#include "event2/event.h" +#include "event-internal.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "bufferevent-internal.h" +#include "evbuffer-internal.h" +#include "util-internal.h" + +static void bufferevent_cancel_all_(struct bufferevent *bev); +static void bufferevent_finalize_cb_(struct event_callback *evcb, void *arg_); + +void +bufferevent_suspend_read_(struct bufferevent *bufev, bufferevent_suspend_flags what) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + BEV_LOCK(bufev); + if (!bufev_private->read_suspended) + bufev->be_ops->disable(bufev, EV_READ); + bufev_private->read_suspended |= what; + BEV_UNLOCK(bufev); +} + +void +bufferevent_unsuspend_read_(struct bufferevent *bufev, bufferevent_suspend_flags what) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + BEV_LOCK(bufev); + bufev_private->read_suspended &= ~what; + if (!bufev_private->read_suspended && (bufev->enabled & EV_READ)) + bufev->be_ops->enable(bufev, EV_READ); + BEV_UNLOCK(bufev); +} + +void +bufferevent_suspend_write_(struct bufferevent *bufev, bufferevent_suspend_flags what) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + BEV_LOCK(bufev); + if (!bufev_private->write_suspended) + bufev->be_ops->disable(bufev, EV_WRITE); + bufev_private->write_suspended |= what; + BEV_UNLOCK(bufev); +} + +void +bufferevent_unsuspend_write_(struct bufferevent *bufev, bufferevent_suspend_flags what) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + BEV_LOCK(bufev); + bufev_private->write_suspended &= ~what; + if (!bufev_private->write_suspended && (bufev->enabled & EV_WRITE)) + bufev->be_ops->enable(bufev, EV_WRITE); + BEV_UNLOCK(bufev); +} + + +/* Callback to implement watermarks on the input buffer. Only enabled + * if the watermark is set. */ +static void +bufferevent_inbuf_wm_cb(struct evbuffer *buf, + const struct evbuffer_cb_info *cbinfo, + void *arg) +{ + struct bufferevent *bufev = arg; + size_t size; + + size = evbuffer_get_length(buf); + + if (size >= bufev->wm_read.high) + bufferevent_wm_suspend_read(bufev); + else + bufferevent_wm_unsuspend_read(bufev); +} + +static void +bufferevent_run_deferred_callbacks_locked(struct event_callback *cb, void *arg) +{ + struct bufferevent_private *bufev_private = arg; + struct bufferevent *bufev = &bufev_private->bev; + + BEV_LOCK(bufev); + if ((bufev_private->eventcb_pending & BEV_EVENT_CONNECTED) && + bufev->errorcb) { + /* The "connected" happened before any reads or writes, so + send it first. */ + bufev_private->eventcb_pending &= ~BEV_EVENT_CONNECTED; + bufev->errorcb(bufev, BEV_EVENT_CONNECTED, bufev->cbarg); + } + if (bufev_private->readcb_pending && bufev->readcb) { + bufev_private->readcb_pending = 0; + bufev->readcb(bufev, bufev->cbarg); + } + if (bufev_private->writecb_pending && bufev->writecb) { + bufev_private->writecb_pending = 0; + bufev->writecb(bufev, bufev->cbarg); + } + if (bufev_private->eventcb_pending && bufev->errorcb) { + short what = bufev_private->eventcb_pending; + int err = bufev_private->errno_pending; + bufev_private->eventcb_pending = 0; + bufev_private->errno_pending = 0; + EVUTIL_SET_SOCKET_ERROR(err); + bufev->errorcb(bufev, what, bufev->cbarg); + } + bufferevent_decref_and_unlock_(bufev); +} + +static void +bufferevent_run_deferred_callbacks_unlocked(struct event_callback *cb, void *arg) +{ + struct bufferevent_private *bufev_private = arg; + struct bufferevent *bufev = &bufev_private->bev; + + BEV_LOCK(bufev); +#define UNLOCKED(stmt) \ + do { BEV_UNLOCK(bufev); stmt; BEV_LOCK(bufev); } while(0) + + if ((bufev_private->eventcb_pending & BEV_EVENT_CONNECTED) && + bufev->errorcb) { + /* The "connected" happened before any reads or writes, so + send it first. */ + bufferevent_event_cb errorcb = bufev->errorcb; + void *cbarg = bufev->cbarg; + bufev_private->eventcb_pending &= ~BEV_EVENT_CONNECTED; + UNLOCKED(errorcb(bufev, BEV_EVENT_CONNECTED, cbarg)); + } + if (bufev_private->readcb_pending && bufev->readcb) { + bufferevent_data_cb readcb = bufev->readcb; + void *cbarg = bufev->cbarg; + bufev_private->readcb_pending = 0; + UNLOCKED(readcb(bufev, cbarg)); + } + if (bufev_private->writecb_pending && bufev->writecb) { + bufferevent_data_cb writecb = bufev->writecb; + void *cbarg = bufev->cbarg; + bufev_private->writecb_pending = 0; + UNLOCKED(writecb(bufev, cbarg)); + } + if (bufev_private->eventcb_pending && bufev->errorcb) { + bufferevent_event_cb errorcb = bufev->errorcb; + void *cbarg = bufev->cbarg; + short what = bufev_private->eventcb_pending; + int err = bufev_private->errno_pending; + bufev_private->eventcb_pending = 0; + bufev_private->errno_pending = 0; + EVUTIL_SET_SOCKET_ERROR(err); + UNLOCKED(errorcb(bufev,what,cbarg)); + } + bufferevent_decref_and_unlock_(bufev); +#undef UNLOCKED +} + +#define SCHEDULE_DEFERRED(bevp) \ + do { \ + if (event_deferred_cb_schedule_( \ + (bevp)->bev.ev_base, \ + &(bevp)->deferred)) \ + bufferevent_incref_(&(bevp)->bev); \ + } while (0) + + +void +bufferevent_run_readcb_(struct bufferevent *bufev, int options) +{ + /* Requires that we hold the lock and a reference */ + struct bufferevent_private *p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + if (bufev->readcb == NULL) + return; + if ((p->options|options) & BEV_OPT_DEFER_CALLBACKS) { + p->readcb_pending = 1; + SCHEDULE_DEFERRED(p); + } else { + bufev->readcb(bufev, bufev->cbarg); + } +} + +void +bufferevent_run_writecb_(struct bufferevent *bufev, int options) +{ + /* Requires that we hold the lock and a reference */ + struct bufferevent_private *p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + if (bufev->writecb == NULL) + return; + if ((p->options|options) & BEV_OPT_DEFER_CALLBACKS) { + p->writecb_pending = 1; + SCHEDULE_DEFERRED(p); + } else { + bufev->writecb(bufev, bufev->cbarg); + } +} + +#define BEV_TRIG_ALL_OPTS ( \ + BEV_TRIG_IGNORE_WATERMARKS| \ + BEV_TRIG_DEFER_CALLBACKS \ + ) + +void +bufferevent_trigger(struct bufferevent *bufev, short iotype, int options) +{ + bufferevent_incref_and_lock_(bufev); + bufferevent_trigger_nolock_(bufev, iotype, options&BEV_TRIG_ALL_OPTS); + bufferevent_decref_and_unlock_(bufev); +} + +void +bufferevent_run_eventcb_(struct bufferevent *bufev, short what, int options) +{ + /* Requires that we hold the lock and a reference */ + struct bufferevent_private *p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + if (bufev->errorcb == NULL) + return; + if ((p->options|options) & BEV_OPT_DEFER_CALLBACKS) { + p->eventcb_pending |= what; + p->errno_pending = EVUTIL_SOCKET_ERROR(); + SCHEDULE_DEFERRED(p); + } else { + bufev->errorcb(bufev, what, bufev->cbarg); + } +} + +void +bufferevent_trigger_event(struct bufferevent *bufev, short what, int options) +{ + bufferevent_incref_and_lock_(bufev); + bufferevent_run_eventcb_(bufev, what, options&BEV_TRIG_ALL_OPTS); + bufferevent_decref_and_unlock_(bufev); +} + +int +bufferevent_init_common_(struct bufferevent_private *bufev_private, + struct event_base *base, + const struct bufferevent_ops *ops, + enum bufferevent_options options) +{ + struct bufferevent *bufev = &bufev_private->bev; + + if (!bufev->input) { + if ((bufev->input = evbuffer_new()) == NULL) + return -1; + } + + if (!bufev->output) { + if ((bufev->output = evbuffer_new()) == NULL) { + evbuffer_free(bufev->input); + return -1; + } + } + + bufev_private->refcnt = 1; + bufev->ev_base = base; + + /* Disable timeouts. */ + evutil_timerclear(&bufev->timeout_read); + evutil_timerclear(&bufev->timeout_write); + + bufev->be_ops = ops; + + bufferevent_ratelim_init_(bufev_private); + + /* + * Set to EV_WRITE so that using bufferevent_write is going to + * trigger a callback. Reading needs to be explicitly enabled + * because otherwise no data will be available. + */ + bufev->enabled = EV_WRITE; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (options & BEV_OPT_THREADSAFE) { + if (bufferevent_enable_locking_(bufev, NULL) < 0) { + /* cleanup */ + evbuffer_free(bufev->input); + evbuffer_free(bufev->output); + bufev->input = NULL; + bufev->output = NULL; + return -1; + } + } +#endif + if ((options & (BEV_OPT_DEFER_CALLBACKS|BEV_OPT_UNLOCK_CALLBACKS)) + == BEV_OPT_UNLOCK_CALLBACKS) { + event_warnx("UNLOCK_CALLBACKS requires DEFER_CALLBACKS"); + return -1; + } + if (options & BEV_OPT_UNLOCK_CALLBACKS) + event_deferred_cb_init_( + &bufev_private->deferred, + event_base_get_npriorities(base) / 2, + bufferevent_run_deferred_callbacks_unlocked, + bufev_private); + else + event_deferred_cb_init_( + &bufev_private->deferred, + event_base_get_npriorities(base) / 2, + bufferevent_run_deferred_callbacks_locked, + bufev_private); + + bufev_private->options = options; + + evbuffer_set_parent_(bufev->input, bufev); + evbuffer_set_parent_(bufev->output, bufev); + + return 0; +} + +void +bufferevent_setcb(struct bufferevent *bufev, + bufferevent_data_cb readcb, bufferevent_data_cb writecb, + bufferevent_event_cb eventcb, void *cbarg) +{ + BEV_LOCK(bufev); + + bufev->readcb = readcb; + bufev->writecb = writecb; + bufev->errorcb = eventcb; + + bufev->cbarg = cbarg; + BEV_UNLOCK(bufev); +} + +void +bufferevent_getcb(struct bufferevent *bufev, + bufferevent_data_cb *readcb_ptr, + bufferevent_data_cb *writecb_ptr, + bufferevent_event_cb *eventcb_ptr, + void **cbarg_ptr) +{ + BEV_LOCK(bufev); + if (readcb_ptr) + *readcb_ptr = bufev->readcb; + if (writecb_ptr) + *writecb_ptr = bufev->writecb; + if (eventcb_ptr) + *eventcb_ptr = bufev->errorcb; + if (cbarg_ptr) + *cbarg_ptr = bufev->cbarg; + + BEV_UNLOCK(bufev); +} + +struct evbuffer * +bufferevent_get_input(struct bufferevent *bufev) +{ + return bufev->input; +} + +struct evbuffer * +bufferevent_get_output(struct bufferevent *bufev) +{ + return bufev->output; +} + +struct event_base * +bufferevent_get_base(struct bufferevent *bufev) +{ + return bufev->ev_base; +} + +int +bufferevent_get_priority(const struct bufferevent *bufev) +{ + if (event_initialized(&bufev->ev_read)) { + return event_get_priority(&bufev->ev_read); + } else { + return event_base_get_npriorities(bufev->ev_base) / 2; + } +} + +int +bufferevent_write(struct bufferevent *bufev, const void *data, size_t size) +{ + if (evbuffer_add(bufev->output, data, size) == -1) + return (-1); + + return 0; +} + +int +bufferevent_write_buffer(struct bufferevent *bufev, struct evbuffer *buf) +{ + if (evbuffer_add_buffer(bufev->output, buf) == -1) + return (-1); + + return 0; +} + +size_t +bufferevent_read(struct bufferevent *bufev, void *data, size_t size) +{ + return (evbuffer_remove(bufev->input, data, size)); +} + +int +bufferevent_read_buffer(struct bufferevent *bufev, struct evbuffer *buf) +{ + return (evbuffer_add_buffer(buf, bufev->input)); +} + +int +bufferevent_enable(struct bufferevent *bufev, short event) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + short impl_events = event; + int r = 0; + + bufferevent_incref_and_lock_(bufev); + if (bufev_private->read_suspended) + impl_events &= ~EV_READ; + if (bufev_private->write_suspended) + impl_events &= ~EV_WRITE; + + bufev->enabled |= event; + + if (impl_events && bufev->be_ops->enable(bufev, impl_events) < 0) + r = -1; + + bufferevent_decref_and_unlock_(bufev); + return r; +} + +int +bufferevent_set_timeouts(struct bufferevent *bufev, + const struct timeval *tv_read, + const struct timeval *tv_write) +{ + int r = 0; + BEV_LOCK(bufev); + if (tv_read) { + bufev->timeout_read = *tv_read; + } else { + evutil_timerclear(&bufev->timeout_read); + } + if (tv_write) { + bufev->timeout_write = *tv_write; + } else { + evutil_timerclear(&bufev->timeout_write); + } + + if (bufev->be_ops->adj_timeouts) + r = bufev->be_ops->adj_timeouts(bufev); + BEV_UNLOCK(bufev); + + return r; +} + + +/* Obsolete; use bufferevent_set_timeouts */ +void +bufferevent_settimeout(struct bufferevent *bufev, + int timeout_read, int timeout_write) +{ + struct timeval tv_read, tv_write; + struct timeval *ptv_read = NULL, *ptv_write = NULL; + + memset(&tv_read, 0, sizeof(tv_read)); + memset(&tv_write, 0, sizeof(tv_write)); + + if (timeout_read) { + tv_read.tv_sec = timeout_read; + ptv_read = &tv_read; + } + if (timeout_write) { + tv_write.tv_sec = timeout_write; + ptv_write = &tv_write; + } + + bufferevent_set_timeouts(bufev, ptv_read, ptv_write); +} + + +int +bufferevent_disable_hard_(struct bufferevent *bufev, short event) +{ + int r = 0; + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + + BEV_LOCK(bufev); + bufev->enabled &= ~event; + + bufev_private->connecting = 0; + if (bufev->be_ops->disable(bufev, event) < 0) + r = -1; + + BEV_UNLOCK(bufev); + return r; +} + +int +bufferevent_disable(struct bufferevent *bufev, short event) +{ + int r = 0; + + BEV_LOCK(bufev); + bufev->enabled &= ~event; + + if (bufev->be_ops->disable(bufev, event) < 0) + r = -1; + + BEV_UNLOCK(bufev); + return r; +} + +/* + * Sets the water marks + */ + +void +bufferevent_setwatermark(struct bufferevent *bufev, short events, + size_t lowmark, size_t highmark) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + + BEV_LOCK(bufev); + if (events & EV_WRITE) { + bufev->wm_write.low = lowmark; + bufev->wm_write.high = highmark; + } + + if (events & EV_READ) { + bufev->wm_read.low = lowmark; + bufev->wm_read.high = highmark; + + if (highmark) { + /* There is now a new high-water mark for read. + enable the callback if needed, and see if we should + suspend/bufferevent_wm_unsuspend. */ + + if (bufev_private->read_watermarks_cb == NULL) { + bufev_private->read_watermarks_cb = + evbuffer_add_cb(bufev->input, + bufferevent_inbuf_wm_cb, + bufev); + } + evbuffer_cb_set_flags(bufev->input, + bufev_private->read_watermarks_cb, + EVBUFFER_CB_ENABLED|EVBUFFER_CB_NODEFER); + + if (evbuffer_get_length(bufev->input) >= highmark) + bufferevent_wm_suspend_read(bufev); + else if (evbuffer_get_length(bufev->input) < highmark) + bufferevent_wm_unsuspend_read(bufev); + } else { + /* There is now no high-water mark for read. */ + if (bufev_private->read_watermarks_cb) + evbuffer_cb_clear_flags(bufev->input, + bufev_private->read_watermarks_cb, + EVBUFFER_CB_ENABLED); + bufferevent_wm_unsuspend_read(bufev); + } + } + BEV_UNLOCK(bufev); +} + +int +bufferevent_getwatermark(struct bufferevent *bufev, short events, + size_t *lowmark, size_t *highmark) +{ + if (events == EV_WRITE) { + BEV_LOCK(bufev); + if (lowmark) + *lowmark = bufev->wm_write.low; + if (highmark) + *highmark = bufev->wm_write.high; + BEV_UNLOCK(bufev); + return 0; + } + + if (events == EV_READ) { + BEV_LOCK(bufev); + if (lowmark) + *lowmark = bufev->wm_read.low; + if (highmark) + *highmark = bufev->wm_read.high; + BEV_UNLOCK(bufev); + return 0; + } + return -1; +} + +int +bufferevent_flush(struct bufferevent *bufev, + short iotype, + enum bufferevent_flush_mode mode) +{ + int r = -1; + BEV_LOCK(bufev); + if (bufev->be_ops->flush) + r = bufev->be_ops->flush(bufev, iotype, mode); + BEV_UNLOCK(bufev); + return r; +} + +void +bufferevent_incref_and_lock_(struct bufferevent *bufev) +{ + struct bufferevent_private *bufev_private = + BEV_UPCAST(bufev); + BEV_LOCK(bufev); + ++bufev_private->refcnt; +} + +#if 0 +static void +bufferevent_transfer_lock_ownership_(struct bufferevent *donor, + struct bufferevent *recipient) +{ + struct bufferevent_private *d = BEV_UPCAST(donor); + struct bufferevent_private *r = BEV_UPCAST(recipient); + if (d->lock != r->lock) + return; + if (r->own_lock) + return; + if (d->own_lock) { + d->own_lock = 0; + r->own_lock = 1; + } +} +#endif + +int +bufferevent_decref_and_unlock_(struct bufferevent *bufev) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + int n_cbs = 0; +#define MAX_CBS 16 + struct event_callback *cbs[MAX_CBS]; + + EVUTIL_ASSERT(bufev_private->refcnt > 0); + + if (--bufev_private->refcnt) { + BEV_UNLOCK(bufev); + return 0; + } + + if (bufev->be_ops->unlink) + bufev->be_ops->unlink(bufev); + + /* Okay, we're out of references. Let's finalize this once all the + * callbacks are done running. */ + cbs[0] = &bufev->ev_read.ev_evcallback; + cbs[1] = &bufev->ev_write.ev_evcallback; + cbs[2] = &bufev_private->deferred; + n_cbs = 3; + if (bufev_private->rate_limiting) { + struct event *e = &bufev_private->rate_limiting->refill_bucket_event; + if (event_initialized(e)) + cbs[n_cbs++] = &e->ev_evcallback; + } + n_cbs += evbuffer_get_callbacks_(bufev->input, cbs+n_cbs, MAX_CBS-n_cbs); + n_cbs += evbuffer_get_callbacks_(bufev->output, cbs+n_cbs, MAX_CBS-n_cbs); + + event_callback_finalize_many_(bufev->ev_base, n_cbs, cbs, + bufferevent_finalize_cb_); + +#undef MAX_CBS + BEV_UNLOCK(bufev); + + return 1; +} + +static void +bufferevent_finalize_cb_(struct event_callback *evcb, void *arg_) +{ + struct bufferevent *bufev = arg_; + struct bufferevent *underlying; + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + + BEV_LOCK(bufev); + underlying = bufferevent_get_underlying(bufev); + + /* Clean up the shared info */ + if (bufev->be_ops->destruct) + bufev->be_ops->destruct(bufev); + + /* XXX what happens if refcnt for these buffers is > 1? + * The buffers can share a lock with this bufferevent object, + * but the lock might be destroyed below. */ + /* evbuffer will free the callbacks */ + evbuffer_free(bufev->input); + evbuffer_free(bufev->output); + + if (bufev_private->rate_limiting) { + if (bufev_private->rate_limiting->group) + bufferevent_remove_from_rate_limit_group_internal_(bufev,0); + mm_free(bufev_private->rate_limiting); + bufev_private->rate_limiting = NULL; + } + + + BEV_UNLOCK(bufev); + + if (bufev_private->own_lock) + EVTHREAD_FREE_LOCK(bufev_private->lock, + EVTHREAD_LOCKTYPE_RECURSIVE); + + /* Free the actual allocated memory. */ + mm_free(((char*)bufev) - bufev->be_ops->mem_offset); + + /* Release the reference to underlying now that we no longer need the + * reference to it. We wait this long mainly in case our lock is + * shared with underlying. + * + * The 'destruct' function will also drop a reference to underlying + * if BEV_OPT_CLOSE_ON_FREE is set. + * + * XXX Should we/can we just refcount evbuffer/bufferevent locks? + * It would probably save us some headaches. + */ + if (underlying) + bufferevent_decref_(underlying); +} + +int +bufferevent_decref_(struct bufferevent *bufev) +{ + BEV_LOCK(bufev); + return bufferevent_decref_and_unlock_(bufev); +} + +void +bufferevent_free(struct bufferevent *bufev) +{ + BEV_LOCK(bufev); + bufferevent_setcb(bufev, NULL, NULL, NULL, NULL); + bufferevent_cancel_all_(bufev); + bufferevent_decref_and_unlock_(bufev); +} + +void +bufferevent_incref_(struct bufferevent *bufev) +{ + struct bufferevent_private *bufev_private = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + + BEV_LOCK(bufev); + ++bufev_private->refcnt; + BEV_UNLOCK(bufev); +} + +int +bufferevent_enable_locking_(struct bufferevent *bufev, void *lock) +{ +#ifdef EVENT__DISABLE_THREAD_SUPPORT + return -1; +#else + struct bufferevent *underlying; + + if (BEV_UPCAST(bufev)->lock) + return -1; + underlying = bufferevent_get_underlying(bufev); + + if (!lock && underlying && BEV_UPCAST(underlying)->lock) { + lock = BEV_UPCAST(underlying)->lock; + BEV_UPCAST(bufev)->lock = lock; + BEV_UPCAST(bufev)->own_lock = 0; + } else if (!lock) { + EVTHREAD_ALLOC_LOCK(lock, EVTHREAD_LOCKTYPE_RECURSIVE); + if (!lock) + return -1; + BEV_UPCAST(bufev)->lock = lock; + BEV_UPCAST(bufev)->own_lock = 1; + } else { + BEV_UPCAST(bufev)->lock = lock; + BEV_UPCAST(bufev)->own_lock = 0; + } + evbuffer_enable_locking(bufev->input, lock); + evbuffer_enable_locking(bufev->output, lock); + + if (underlying && !BEV_UPCAST(underlying)->lock) + bufferevent_enable_locking_(underlying, lock); + + return 0; +#endif +} + +int +bufferevent_setfd(struct bufferevent *bev, evutil_socket_t fd) +{ + union bufferevent_ctrl_data d; + int res = -1; + d.fd = fd; + BEV_LOCK(bev); + if (bev->be_ops->ctrl) + res = bev->be_ops->ctrl(bev, BEV_CTRL_SET_FD, &d); + BEV_UNLOCK(bev); + return res; +} + +evutil_socket_t +bufferevent_getfd(struct bufferevent *bev) +{ + union bufferevent_ctrl_data d; + int res = -1; + d.fd = -1; + BEV_LOCK(bev); + if (bev->be_ops->ctrl) + res = bev->be_ops->ctrl(bev, BEV_CTRL_GET_FD, &d); + BEV_UNLOCK(bev); + return (res<0) ? -1 : d.fd; +} + +enum bufferevent_options +bufferevent_get_options_(struct bufferevent *bev) +{ + struct bufferevent_private *bev_p = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + enum bufferevent_options options; + + BEV_LOCK(bev); + options = bev_p->options; + BEV_UNLOCK(bev); + return options; +} + + +static void +bufferevent_cancel_all_(struct bufferevent *bev) +{ + union bufferevent_ctrl_data d; + memset(&d, 0, sizeof(d)); + BEV_LOCK(bev); + if (bev->be_ops->ctrl) + bev->be_ops->ctrl(bev, BEV_CTRL_CANCEL_ALL, &d); + BEV_UNLOCK(bev); +} + +short +bufferevent_get_enabled(struct bufferevent *bufev) +{ + short r; + BEV_LOCK(bufev); + r = bufev->enabled; + BEV_UNLOCK(bufev); + return r; +} + +struct bufferevent * +bufferevent_get_underlying(struct bufferevent *bev) +{ + union bufferevent_ctrl_data d; + int res = -1; + d.ptr = NULL; + BEV_LOCK(bev); + if (bev->be_ops->ctrl) + res = bev->be_ops->ctrl(bev, BEV_CTRL_GET_UNDERLYING, &d); + BEV_UNLOCK(bev); + return (res<0) ? NULL : d.ptr; +} + +static void +bufferevent_generic_read_timeout_cb(evutil_socket_t fd, short event, void *ctx) +{ + struct bufferevent *bev = ctx; + bufferevent_incref_and_lock_(bev); + bufferevent_disable(bev, EV_READ); + bufferevent_run_eventcb_(bev, BEV_EVENT_TIMEOUT|BEV_EVENT_READING, 0); + bufferevent_decref_and_unlock_(bev); +} +static void +bufferevent_generic_write_timeout_cb(evutil_socket_t fd, short event, void *ctx) +{ + struct bufferevent *bev = ctx; + bufferevent_incref_and_lock_(bev); + bufferevent_disable(bev, EV_WRITE); + bufferevent_run_eventcb_(bev, BEV_EVENT_TIMEOUT|BEV_EVENT_WRITING, 0); + bufferevent_decref_and_unlock_(bev); +} + +void +bufferevent_init_generic_timeout_cbs_(struct bufferevent *bev) +{ + event_assign(&bev->ev_read, bev->ev_base, -1, EV_FINALIZE, + bufferevent_generic_read_timeout_cb, bev); + event_assign(&bev->ev_write, bev->ev_base, -1, EV_FINALIZE, + bufferevent_generic_write_timeout_cb, bev); +} + +int +bufferevent_generic_adj_timeouts_(struct bufferevent *bev) +{ + const short enabled = bev->enabled; + struct bufferevent_private *bev_p = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + int r1=0, r2=0; + if ((enabled & EV_READ) && !bev_p->read_suspended && + evutil_timerisset(&bev->timeout_read)) + r1 = event_add(&bev->ev_read, &bev->timeout_read); + else + r1 = event_del(&bev->ev_read); + + if ((enabled & EV_WRITE) && !bev_p->write_suspended && + evutil_timerisset(&bev->timeout_write) && + evbuffer_get_length(bev->output)) + r2 = event_add(&bev->ev_write, &bev->timeout_write); + else + r2 = event_del(&bev->ev_write); + if (r1 < 0 || r2 < 0) + return -1; + return 0; +} + +int +bufferevent_add_event_(struct event *ev, const struct timeval *tv) +{ + if (tv->tv_sec == 0 && tv->tv_usec == 0) + return event_add(ev, NULL); + else + return event_add(ev, tv); +} + +/* For use by user programs only; internally, we should be calling + either bufferevent_incref_and_lock_(), or BEV_LOCK. */ +void +bufferevent_lock(struct bufferevent *bev) +{ + bufferevent_incref_and_lock_(bev); +} + +void +bufferevent_unlock(struct bufferevent *bev) +{ + bufferevent_decref_and_unlock_(bev); +} diff --git a/contrib/ntp/sntp/libevent/bufferevent_async.c b/contrib/ntp/sntp/libevent/bufferevent_async.c new file mode 100644 index 000000000..6395e57a9 --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent_async.c @@ -0,0 +1,686 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#include +#include +#include +#include +#ifdef EVENT__HAVE_STDARG_H +#include +#endif +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif + +#ifdef _WIN32 +#include +#include +#endif + +#include + +#include "event2/util.h" +#include "event2/bufferevent.h" +#include "event2/buffer.h" +#include "event2/bufferevent_struct.h" +#include "event2/event.h" +#include "event2/util.h" +#include "event-internal.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "bufferevent-internal.h" +#include "util-internal.h" +#include "iocp-internal.h" + +#ifndef SO_UPDATE_CONNECT_CONTEXT +/* Mingw is sometimes missing this */ +#define SO_UPDATE_CONNECT_CONTEXT 0x7010 +#endif + +/* prototypes */ +static int be_async_enable(struct bufferevent *, short); +static int be_async_disable(struct bufferevent *, short); +static void be_async_destruct(struct bufferevent *); +static int be_async_flush(struct bufferevent *, short, enum bufferevent_flush_mode); +static int be_async_ctrl(struct bufferevent *, enum bufferevent_ctrl_op, union bufferevent_ctrl_data *); + +struct bufferevent_async { + struct bufferevent_private bev; + struct event_overlapped connect_overlapped; + struct event_overlapped read_overlapped; + struct event_overlapped write_overlapped; + size_t read_in_progress; + size_t write_in_progress; + unsigned ok : 1; + unsigned read_added : 1; + unsigned write_added : 1; +}; + +const struct bufferevent_ops bufferevent_ops_async = { + "socket_async", + evutil_offsetof(struct bufferevent_async, bev.bev), + be_async_enable, + be_async_disable, + NULL, /* Unlink */ + be_async_destruct, + bufferevent_generic_adj_timeouts_, + be_async_flush, + be_async_ctrl, +}; + +static inline struct bufferevent_async * +upcast(struct bufferevent *bev) +{ + struct bufferevent_async *bev_a; + if (bev->be_ops != &bufferevent_ops_async) + return NULL; + bev_a = EVUTIL_UPCAST(bev, struct bufferevent_async, bev.bev); + return bev_a; +} + +static inline struct bufferevent_async * +upcast_connect(struct event_overlapped *eo) +{ + struct bufferevent_async *bev_a; + bev_a = EVUTIL_UPCAST(eo, struct bufferevent_async, connect_overlapped); + EVUTIL_ASSERT(BEV_IS_ASYNC(&bev_a->bev.bev)); + return bev_a; +} + +static inline struct bufferevent_async * +upcast_read(struct event_overlapped *eo) +{ + struct bufferevent_async *bev_a; + bev_a = EVUTIL_UPCAST(eo, struct bufferevent_async, read_overlapped); + EVUTIL_ASSERT(BEV_IS_ASYNC(&bev_a->bev.bev)); + return bev_a; +} + +static inline struct bufferevent_async * +upcast_write(struct event_overlapped *eo) +{ + struct bufferevent_async *bev_a; + bev_a = EVUTIL_UPCAST(eo, struct bufferevent_async, write_overlapped); + EVUTIL_ASSERT(BEV_IS_ASYNC(&bev_a->bev.bev)); + return bev_a; +} + +static void +bev_async_del_write(struct bufferevent_async *beva) +{ + struct bufferevent *bev = &beva->bev.bev; + + if (beva->write_added) { + beva->write_added = 0; + event_base_del_virtual_(bev->ev_base); + } +} + +static void +bev_async_del_read(struct bufferevent_async *beva) +{ + struct bufferevent *bev = &beva->bev.bev; + + if (beva->read_added) { + beva->read_added = 0; + event_base_del_virtual_(bev->ev_base); + } +} + +static void +bev_async_add_write(struct bufferevent_async *beva) +{ + struct bufferevent *bev = &beva->bev.bev; + + if (!beva->write_added) { + beva->write_added = 1; + event_base_add_virtual_(bev->ev_base); + } +} + +static void +bev_async_add_read(struct bufferevent_async *beva) +{ + struct bufferevent *bev = &beva->bev.bev; + + if (!beva->read_added) { + beva->read_added = 1; + event_base_add_virtual_(bev->ev_base); + } +} + +static void +bev_async_consider_writing(struct bufferevent_async *beva) +{ + size_t at_most; + int limit; + struct bufferevent *bev = &beva->bev.bev; + + /* Don't write if there's a write in progress, or we do not + * want to write, or when there's nothing left to write. */ + if (beva->write_in_progress || beva->bev.connecting) + return; + if (!beva->ok || !(bev->enabled&EV_WRITE) || + !evbuffer_get_length(bev->output)) { + bev_async_del_write(beva); + return; + } + + at_most = evbuffer_get_length(bev->output); + + /* This is safe so long as bufferevent_get_write_max never returns + * more than INT_MAX. That's true for now. XXXX */ + limit = (int)bufferevent_get_write_max_(&beva->bev); + if (at_most >= (size_t)limit && limit >= 0) + at_most = limit; + + if (beva->bev.write_suspended) { + bev_async_del_write(beva); + return; + } + + /* XXXX doesn't respect low-water mark very well. */ + bufferevent_incref_(bev); + if (evbuffer_launch_write_(bev->output, at_most, + &beva->write_overlapped)) { + bufferevent_decref_(bev); + beva->ok = 0; + bufferevent_run_eventcb_(bev, BEV_EVENT_ERROR, 0); + } else { + beva->write_in_progress = at_most; + bufferevent_decrement_write_buckets_(&beva->bev, at_most); + bev_async_add_write(beva); + } +} + +static void +bev_async_consider_reading(struct bufferevent_async *beva) +{ + size_t cur_size; + size_t read_high; + size_t at_most; + int limit; + struct bufferevent *bev = &beva->bev.bev; + + /* Don't read if there is a read in progress, or we do not + * want to read. */ + if (beva->read_in_progress || beva->bev.connecting) + return; + if (!beva->ok || !(bev->enabled&EV_READ)) { + bev_async_del_read(beva); + return; + } + + /* Don't read if we're full */ + cur_size = evbuffer_get_length(bev->input); + read_high = bev->wm_read.high; + if (read_high) { + if (cur_size >= read_high) { + bev_async_del_read(beva); + return; + } + at_most = read_high - cur_size; + } else { + at_most = 16384; /* FIXME totally magic. */ + } + + /* XXXX This over-commits. */ + /* XXXX see also not above on cast on bufferevent_get_write_max_() */ + limit = (int)bufferevent_get_read_max_(&beva->bev); + if (at_most >= (size_t)limit && limit >= 0) + at_most = limit; + + if (beva->bev.read_suspended) { + bev_async_del_read(beva); + return; + } + + bufferevent_incref_(bev); + if (evbuffer_launch_read_(bev->input, at_most, &beva->read_overlapped)) { + beva->ok = 0; + bufferevent_run_eventcb_(bev, BEV_EVENT_ERROR, 0); + bufferevent_decref_(bev); + } else { + beva->read_in_progress = at_most; + bufferevent_decrement_read_buckets_(&beva->bev, at_most); + bev_async_add_read(beva); + } + + return; +} + +static void +be_async_outbuf_callback(struct evbuffer *buf, + const struct evbuffer_cb_info *cbinfo, + void *arg) +{ + struct bufferevent *bev = arg; + struct bufferevent_async *bev_async = upcast(bev); + + /* If we added data to the outbuf and were not writing before, + * we may want to write now. */ + + bufferevent_incref_and_lock_(bev); + + if (cbinfo->n_added) + bev_async_consider_writing(bev_async); + + bufferevent_decref_and_unlock_(bev); +} + +static void +be_async_inbuf_callback(struct evbuffer *buf, + const struct evbuffer_cb_info *cbinfo, + void *arg) +{ + struct bufferevent *bev = arg; + struct bufferevent_async *bev_async = upcast(bev); + + /* If we drained data from the inbuf and were not reading before, + * we may want to read now */ + + bufferevent_incref_and_lock_(bev); + + if (cbinfo->n_deleted) + bev_async_consider_reading(bev_async); + + bufferevent_decref_and_unlock_(bev); +} + +static int +be_async_enable(struct bufferevent *buf, short what) +{ + struct bufferevent_async *bev_async = upcast(buf); + + if (!bev_async->ok) + return -1; + + if (bev_async->bev.connecting) { + /* Don't launch anything during connection attempts. */ + return 0; + } + + if (what & EV_READ) + BEV_RESET_GENERIC_READ_TIMEOUT(buf); + if (what & EV_WRITE) + BEV_RESET_GENERIC_WRITE_TIMEOUT(buf); + + /* If we newly enable reading or writing, and we aren't reading or + writing already, consider launching a new read or write. */ + + if (what & EV_READ) + bev_async_consider_reading(bev_async); + if (what & EV_WRITE) + bev_async_consider_writing(bev_async); + return 0; +} + +static int +be_async_disable(struct bufferevent *bev, short what) +{ + struct bufferevent_async *bev_async = upcast(bev); + /* XXXX If we disable reading or writing, we may want to consider + * canceling any in-progress read or write operation, though it might + * not work. */ + + if (what & EV_READ) { + BEV_DEL_GENERIC_READ_TIMEOUT(bev); + bev_async_del_read(bev_async); + } + if (what & EV_WRITE) { + BEV_DEL_GENERIC_WRITE_TIMEOUT(bev); + bev_async_del_write(bev_async); + } + + return 0; +} + +static void +be_async_destruct(struct bufferevent *bev) +{ + struct bufferevent_async *bev_async = upcast(bev); + struct bufferevent_private *bev_p = BEV_UPCAST(bev); + evutil_socket_t fd; + + EVUTIL_ASSERT(!upcast(bev)->write_in_progress && + !upcast(bev)->read_in_progress); + + bev_async_del_read(bev_async); + bev_async_del_write(bev_async); + + fd = evbuffer_overlapped_get_fd_(bev->input); + if (fd != (evutil_socket_t)INVALID_SOCKET && + (bev_p->options & BEV_OPT_CLOSE_ON_FREE)) { + evutil_closesocket(fd); + evbuffer_overlapped_set_fd_(bev->input, INVALID_SOCKET); + } +} + +/* GetQueuedCompletionStatus doesn't reliably yield WSA error codes, so + * we use WSAGetOverlappedResult to translate. */ +static void +bev_async_set_wsa_error(struct bufferevent *bev, struct event_overlapped *eo) +{ + DWORD bytes, flags; + evutil_socket_t fd; + + fd = evbuffer_overlapped_get_fd_(bev->input); + WSAGetOverlappedResult(fd, &eo->overlapped, &bytes, FALSE, &flags); +} + +static int +be_async_flush(struct bufferevent *bev, short what, + enum bufferevent_flush_mode mode) +{ + return 0; +} + +static void +connect_complete(struct event_overlapped *eo, ev_uintptr_t key, + ev_ssize_t nbytes, int ok) +{ + struct bufferevent_async *bev_a = upcast_connect(eo); + struct bufferevent *bev = &bev_a->bev.bev; + evutil_socket_t sock; + + BEV_LOCK(bev); + + EVUTIL_ASSERT(bev_a->bev.connecting); + bev_a->bev.connecting = 0; + sock = evbuffer_overlapped_get_fd_(bev_a->bev.bev.input); + /* XXXX Handle error? */ + setsockopt(sock, SOL_SOCKET, SO_UPDATE_CONNECT_CONTEXT, NULL, 0); + + if (ok) + bufferevent_async_set_connected_(bev); + else + bev_async_set_wsa_error(bev, eo); + + bufferevent_run_eventcb_(bev, + ok? BEV_EVENT_CONNECTED : BEV_EVENT_ERROR, 0); + + event_base_del_virtual_(bev->ev_base); + + bufferevent_decref_and_unlock_(bev); +} + +static void +read_complete(struct event_overlapped *eo, ev_uintptr_t key, + ev_ssize_t nbytes, int ok) +{ + struct bufferevent_async *bev_a = upcast_read(eo); + struct bufferevent *bev = &bev_a->bev.bev; + short what = BEV_EVENT_READING; + ev_ssize_t amount_unread; + BEV_LOCK(bev); + EVUTIL_ASSERT(bev_a->read_in_progress); + + amount_unread = bev_a->read_in_progress - nbytes; + evbuffer_commit_read_(bev->input, nbytes); + bev_a->read_in_progress = 0; + if (amount_unread) + bufferevent_decrement_read_buckets_(&bev_a->bev, -amount_unread); + + if (!ok) + bev_async_set_wsa_error(bev, eo); + + if (bev_a->ok) { + if (ok && nbytes) { + BEV_RESET_GENERIC_READ_TIMEOUT(bev); + bufferevent_trigger_nolock_(bev, EV_READ, 0); + bev_async_consider_reading(bev_a); + } else if (!ok) { + what |= BEV_EVENT_ERROR; + bev_a->ok = 0; + bufferevent_run_eventcb_(bev, what, 0); + } else if (!nbytes) { + what |= BEV_EVENT_EOF; + bev_a->ok = 0; + bufferevent_run_eventcb_(bev, what, 0); + } + } + + bufferevent_decref_and_unlock_(bev); +} + +static void +write_complete(struct event_overlapped *eo, ev_uintptr_t key, + ev_ssize_t nbytes, int ok) +{ + struct bufferevent_async *bev_a = upcast_write(eo); + struct bufferevent *bev = &bev_a->bev.bev; + short what = BEV_EVENT_WRITING; + ev_ssize_t amount_unwritten; + + BEV_LOCK(bev); + EVUTIL_ASSERT(bev_a->write_in_progress); + + amount_unwritten = bev_a->write_in_progress - nbytes; + evbuffer_commit_write_(bev->output, nbytes); + bev_a->write_in_progress = 0; + + if (amount_unwritten) + bufferevent_decrement_write_buckets_(&bev_a->bev, + -amount_unwritten); + + + if (!ok) + bev_async_set_wsa_error(bev, eo); + + if (bev_a->ok) { + if (ok && nbytes) { + BEV_RESET_GENERIC_WRITE_TIMEOUT(bev); + bufferevent_trigger_nolock_(bev, EV_WRITE, 0); + bev_async_consider_writing(bev_a); + } else if (!ok) { + what |= BEV_EVENT_ERROR; + bev_a->ok = 0; + bufferevent_run_eventcb_(bev, what, 0); + } else if (!nbytes) { + what |= BEV_EVENT_EOF; + bev_a->ok = 0; + bufferevent_run_eventcb_(bev, what, 0); + } + } + + bufferevent_decref_and_unlock_(bev); +} + +struct bufferevent * +bufferevent_async_new_(struct event_base *base, + evutil_socket_t fd, int options) +{ + struct bufferevent_async *bev_a; + struct bufferevent *bev; + struct event_iocp_port *iocp; + + options |= BEV_OPT_THREADSAFE; + + if (!(iocp = event_base_get_iocp_(base))) + return NULL; + + if (fd >= 0 && event_iocp_port_associate_(iocp, fd, 1)<0) { + int err = GetLastError(); + /* We may have alrady associated this fd with a port. + * Let's hope it's this port, and that the error code + * for doing this neer changes. */ + if (err != ERROR_INVALID_PARAMETER) + return NULL; + } + + if (!(bev_a = mm_calloc(1, sizeof(struct bufferevent_async)))) + return NULL; + + bev = &bev_a->bev.bev; + if (!(bev->input = evbuffer_overlapped_new_(fd))) { + mm_free(bev_a); + return NULL; + } + if (!(bev->output = evbuffer_overlapped_new_(fd))) { + evbuffer_free(bev->input); + mm_free(bev_a); + return NULL; + } + + if (bufferevent_init_common_(&bev_a->bev, base, &bufferevent_ops_async, + options)<0) + goto err; + + evbuffer_add_cb(bev->input, be_async_inbuf_callback, bev); + evbuffer_add_cb(bev->output, be_async_outbuf_callback, bev); + + event_overlapped_init_(&bev_a->connect_overlapped, connect_complete); + event_overlapped_init_(&bev_a->read_overlapped, read_complete); + event_overlapped_init_(&bev_a->write_overlapped, write_complete); + + bufferevent_init_generic_timeout_cbs_(bev); + + bev_a->ok = fd >= 0; + + return bev; +err: + bufferevent_free(&bev_a->bev.bev); + return NULL; +} + +void +bufferevent_async_set_connected_(struct bufferevent *bev) +{ + struct bufferevent_async *bev_async = upcast(bev); + bev_async->ok = 1; + bufferevent_init_generic_timeout_cbs_(bev); + /* Now's a good time to consider reading/writing */ + be_async_enable(bev, bev->enabled); +} + +int +bufferevent_async_can_connect_(struct bufferevent *bev) +{ + const struct win32_extension_fns *ext = + event_get_win32_extension_fns_(); + + if (BEV_IS_ASYNC(bev) && + event_base_get_iocp_(bev->ev_base) && + ext && ext->ConnectEx) + return 1; + + return 0; +} + +int +bufferevent_async_connect_(struct bufferevent *bev, evutil_socket_t fd, + const struct sockaddr *sa, int socklen) +{ + BOOL rc; + struct bufferevent_async *bev_async = upcast(bev); + struct sockaddr_storage ss; + const struct win32_extension_fns *ext = + event_get_win32_extension_fns_(); + + EVUTIL_ASSERT(ext && ext->ConnectEx && fd >= 0 && sa != NULL); + + /* ConnectEx() requires that the socket be bound to an address + * with bind() before using, otherwise it will fail. We attempt + * to issue a bind() here, taking into account that the error + * code is set to WSAEINVAL when the socket is already bound. */ + memset(&ss, 0, sizeof(ss)); + if (sa->sa_family == AF_INET) { + struct sockaddr_in *sin = (struct sockaddr_in *)&ss; + sin->sin_family = AF_INET; + sin->sin_addr.s_addr = INADDR_ANY; + } else if (sa->sa_family == AF_INET6) { + struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)&ss; + sin6->sin6_family = AF_INET6; + sin6->sin6_addr = in6addr_any; + } else { + /* Well, the user will have to bind() */ + return -1; + } + if (bind(fd, (struct sockaddr *)&ss, sizeof(ss)) < 0 && + WSAGetLastError() != WSAEINVAL) + return -1; + + event_base_add_virtual_(bev->ev_base); + bufferevent_incref_(bev); + rc = ext->ConnectEx(fd, sa, socklen, NULL, 0, NULL, + &bev_async->connect_overlapped.overlapped); + if (rc || WSAGetLastError() == ERROR_IO_PENDING) + return 0; + + event_base_del_virtual_(bev->ev_base); + bufferevent_decref_(bev); + + return -1; +} + +static int +be_async_ctrl(struct bufferevent *bev, enum bufferevent_ctrl_op op, + union bufferevent_ctrl_data *data) +{ + switch (op) { + case BEV_CTRL_GET_FD: + data->fd = evbuffer_overlapped_get_fd_(bev->input); + return 0; + case BEV_CTRL_SET_FD: { + struct event_iocp_port *iocp; + + if (data->fd == evbuffer_overlapped_get_fd_(bev->input)) + return 0; + if (!(iocp = event_base_get_iocp_(bev->ev_base))) + return -1; + if (event_iocp_port_associate_(iocp, data->fd, 1) < 0) + return -1; + evbuffer_overlapped_set_fd_(bev->input, data->fd); + evbuffer_overlapped_set_fd_(bev->output, data->fd); + return 0; + } + case BEV_CTRL_CANCEL_ALL: { + struct bufferevent_async *bev_a = upcast(bev); + evutil_socket_t fd = evbuffer_overlapped_get_fd_(bev->input); + if (fd != (evutil_socket_t)INVALID_SOCKET && + (bev_a->bev.options & BEV_OPT_CLOSE_ON_FREE)) { + closesocket(fd); + evbuffer_overlapped_set_fd_(bev->input, INVALID_SOCKET); + } + bev_a->ok = 0; + return 0; + } + case BEV_CTRL_GET_UNDERLYING: + default: + return -1; + } +} + + diff --git a/contrib/ntp/sntp/libevent/bufferevent_filter.c b/contrib/ntp/sntp/libevent/bufferevent_filter.c new file mode 100644 index 000000000..4d9be43e2 --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent_filter.c @@ -0,0 +1,545 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * Copyright (c) 2002-2006 Niels Provos + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "evconfig-private.h" + +#include + +#include "event2/event-config.h" + +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#include +#include +#include +#include +#ifdef EVENT__HAVE_STDARG_H +#include +#endif + +#ifdef _WIN32 +#include +#endif + +#include "event2/util.h" +#include "event2/bufferevent.h" +#include "event2/buffer.h" +#include "event2/bufferevent_struct.h" +#include "event2/event.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "bufferevent-internal.h" +#include "util-internal.h" + +/* prototypes */ +static int be_filter_enable(struct bufferevent *, short); +static int be_filter_disable(struct bufferevent *, short); +static void be_filter_unlink(struct bufferevent *); +static void be_filter_destruct(struct bufferevent *); + +static void be_filter_readcb(struct bufferevent *, void *); +static void be_filter_writecb(struct bufferevent *, void *); +static void be_filter_eventcb(struct bufferevent *, short, void *); +static int be_filter_flush(struct bufferevent *bufev, + short iotype, enum bufferevent_flush_mode mode); +static int be_filter_ctrl(struct bufferevent *, enum bufferevent_ctrl_op, union bufferevent_ctrl_data *); + +static void bufferevent_filtered_outbuf_cb(struct evbuffer *buf, + const struct evbuffer_cb_info *info, void *arg); + +struct bufferevent_filtered { + struct bufferevent_private bev; + + /** The bufferevent that we read/write filtered data from/to. */ + struct bufferevent *underlying; + /** A callback on our outbuf to notice when somebody adds data */ + struct evbuffer_cb_entry *outbuf_cb; + /** True iff we have received an EOF callback from the underlying + * bufferevent. */ + unsigned got_eof; + + /** Function to free context when we're done. */ + void (*free_context)(void *); + /** Input filter */ + bufferevent_filter_cb process_in; + /** Output filter */ + bufferevent_filter_cb process_out; + /** User-supplied argument to the filters. */ + void *context; +}; + +const struct bufferevent_ops bufferevent_ops_filter = { + "filter", + evutil_offsetof(struct bufferevent_filtered, bev.bev), + be_filter_enable, + be_filter_disable, + be_filter_unlink, + be_filter_destruct, + bufferevent_generic_adj_timeouts_, + be_filter_flush, + be_filter_ctrl, +}; + +/* Given a bufferevent that's really the bev filter of a bufferevent_filtered, + * return that bufferevent_filtered. Returns NULL otherwise.*/ +static inline struct bufferevent_filtered * +upcast(struct bufferevent *bev) +{ + struct bufferevent_filtered *bev_f; + if (bev->be_ops != &bufferevent_ops_filter) + return NULL; + bev_f = (void*)( ((char*)bev) - + evutil_offsetof(struct bufferevent_filtered, bev.bev)); + EVUTIL_ASSERT(bev_f->bev.bev.be_ops == &bufferevent_ops_filter); + return bev_f; +} + +#define downcast(bev_f) (&(bev_f)->bev.bev) + +/** Return 1 iff bevf's underlying bufferevent's output buffer is at or + * over its high watermark such that we should not write to it in a given + * flush mode. */ +static int +be_underlying_writebuf_full(struct bufferevent_filtered *bevf, + enum bufferevent_flush_mode state) +{ + struct bufferevent *u = bevf->underlying; + return state == BEV_NORMAL && + u->wm_write.high && + evbuffer_get_length(u->output) >= u->wm_write.high; +} + +/** Return 1 if our input buffer is at or over its high watermark such that we + * should not write to it in a given flush mode. */ +static int +be_readbuf_full(struct bufferevent_filtered *bevf, + enum bufferevent_flush_mode state) +{ + struct bufferevent *bufev = downcast(bevf); + return state == BEV_NORMAL && + bufev->wm_read.high && + evbuffer_get_length(bufev->input) >= bufev->wm_read.high; +} + + +/* Filter to use when we're created with a NULL filter. */ +static enum bufferevent_filter_result +be_null_filter(struct evbuffer *src, struct evbuffer *dst, ev_ssize_t lim, + enum bufferevent_flush_mode state, void *ctx) +{ + (void)state; + if (evbuffer_remove_buffer(src, dst, lim) == 0) + return BEV_OK; + else + return BEV_ERROR; +} + +struct bufferevent * +bufferevent_filter_new(struct bufferevent *underlying, + bufferevent_filter_cb input_filter, + bufferevent_filter_cb output_filter, + int options, + void (*free_context)(void *), + void *ctx) +{ + struct bufferevent_filtered *bufev_f; + int tmp_options = options & ~BEV_OPT_THREADSAFE; + + if (!underlying) + return NULL; + + if (!input_filter) + input_filter = be_null_filter; + if (!output_filter) + output_filter = be_null_filter; + + bufev_f = mm_calloc(1, sizeof(struct bufferevent_filtered)); + if (!bufev_f) + return NULL; + + if (bufferevent_init_common_(&bufev_f->bev, underlying->ev_base, + &bufferevent_ops_filter, tmp_options) < 0) { + mm_free(bufev_f); + return NULL; + } + if (options & BEV_OPT_THREADSAFE) { + bufferevent_enable_locking_(downcast(bufev_f), NULL); + } + + bufev_f->underlying = underlying; + + bufev_f->process_in = input_filter; + bufev_f->process_out = output_filter; + bufev_f->free_context = free_context; + bufev_f->context = ctx; + + bufferevent_setcb(bufev_f->underlying, + be_filter_readcb, be_filter_writecb, be_filter_eventcb, bufev_f); + + bufev_f->outbuf_cb = evbuffer_add_cb(downcast(bufev_f)->output, + bufferevent_filtered_outbuf_cb, bufev_f); + + bufferevent_init_generic_timeout_cbs_(downcast(bufev_f)); + bufferevent_incref_(underlying); + + bufferevent_enable(underlying, EV_READ|EV_WRITE); + bufferevent_suspend_read_(underlying, BEV_SUSPEND_FILT_READ); + + return downcast(bufev_f); +} + +static void +be_filter_unlink(struct bufferevent *bev) +{ + struct bufferevent_filtered *bevf = upcast(bev); + EVUTIL_ASSERT(bevf); + + if (bevf->bev.options & BEV_OPT_CLOSE_ON_FREE) { + /* Yes, there is also a decref in bufferevent_decref_. + * That decref corresponds to the incref when we set + * underlying for the first time. This decref is an + * extra one to remove the last reference. + */ + if (BEV_UPCAST(bevf->underlying)->refcnt < 2) { + event_warnx("BEV_OPT_CLOSE_ON_FREE set on an " + "bufferevent with too few references"); + } else { + bufferevent_free(bevf->underlying); + } + } else { + if (bevf->underlying) { + if (bevf->underlying->errorcb == be_filter_eventcb) + bufferevent_setcb(bevf->underlying, + NULL, NULL, NULL, NULL); + bufferevent_unsuspend_read_(bevf->underlying, + BEV_SUSPEND_FILT_READ); + } + } +} + +static void +be_filter_destruct(struct bufferevent *bev) +{ + struct bufferevent_filtered *bevf = upcast(bev); + EVUTIL_ASSERT(bevf); + if (bevf->free_context) + bevf->free_context(bevf->context); +} + +static int +be_filter_enable(struct bufferevent *bev, short event) +{ + struct bufferevent_filtered *bevf = upcast(bev); + if (event & EV_WRITE) + BEV_RESET_GENERIC_WRITE_TIMEOUT(bev); + + if (event & EV_READ) { + BEV_RESET_GENERIC_READ_TIMEOUT(bev); + bufferevent_unsuspend_read_(bevf->underlying, + BEV_SUSPEND_FILT_READ); + } + return 0; +} + +static int +be_filter_disable(struct bufferevent *bev, short event) +{ + struct bufferevent_filtered *bevf = upcast(bev); + if (event & EV_WRITE) + BEV_DEL_GENERIC_WRITE_TIMEOUT(bev); + if (event & EV_READ) { + BEV_DEL_GENERIC_READ_TIMEOUT(bev); + bufferevent_suspend_read_(bevf->underlying, + BEV_SUSPEND_FILT_READ); + } + return 0; +} + +static enum bufferevent_filter_result +be_filter_process_input(struct bufferevent_filtered *bevf, + enum bufferevent_flush_mode state, + int *processed_out) +{ + enum bufferevent_filter_result res; + struct bufferevent *bev = downcast(bevf); + + if (state == BEV_NORMAL) { + /* If we're in 'normal' mode, don't urge data on the filter + * unless we're reading data and under our high-water mark.*/ + if (!(bev->enabled & EV_READ) || + be_readbuf_full(bevf, state)) + return BEV_OK; + } + + do { + ev_ssize_t limit = -1; + if (state == BEV_NORMAL && bev->wm_read.high) + limit = bev->wm_read.high - + evbuffer_get_length(bev->input); + + res = bevf->process_in(bevf->underlying->input, + bev->input, limit, state, bevf->context); + + if (res == BEV_OK) + *processed_out = 1; + } while (res == BEV_OK && + (bev->enabled & EV_READ) && + evbuffer_get_length(bevf->underlying->input) && + !be_readbuf_full(bevf, state)); + + if (*processed_out) + BEV_RESET_GENERIC_READ_TIMEOUT(bev); + + return res; +} + + +static enum bufferevent_filter_result +be_filter_process_output(struct bufferevent_filtered *bevf, + enum bufferevent_flush_mode state, + int *processed_out) +{ + /* Requires references and lock: might call writecb */ + enum bufferevent_filter_result res = BEV_OK; + struct bufferevent *bufev = downcast(bevf); + int again = 0; + + if (state == BEV_NORMAL) { + /* If we're in 'normal' mode, don't urge data on the + * filter unless we're writing data, and the underlying + * bufferevent is accepting data, and we have data to + * give the filter. If we're in 'flush' or 'finish', + * call the filter no matter what. */ + if (!(bufev->enabled & EV_WRITE) || + be_underlying_writebuf_full(bevf, state) || + !evbuffer_get_length(bufev->output)) + return BEV_OK; + } + + /* disable the callback that calls this function + when the user adds to the output buffer. */ + evbuffer_cb_set_flags(bufev->output, bevf->outbuf_cb, 0); + + do { + int processed = 0; + again = 0; + + do { + ev_ssize_t limit = -1; + if (state == BEV_NORMAL && + bevf->underlying->wm_write.high) + limit = bevf->underlying->wm_write.high - + evbuffer_get_length(bevf->underlying->output); + + res = bevf->process_out(downcast(bevf)->output, + bevf->underlying->output, + limit, + state, + bevf->context); + + if (res == BEV_OK) + processed = *processed_out = 1; + } while (/* Stop if the filter wasn't successful...*/ + res == BEV_OK && + /* Or if we aren't writing any more. */ + (bufev->enabled & EV_WRITE) && + /* Of if we have nothing more to write and we are + * not flushing. */ + evbuffer_get_length(bufev->output) && + /* Or if we have filled the underlying output buffer. */ + !be_underlying_writebuf_full(bevf,state)); + + if (processed) { + /* call the write callback.*/ + bufferevent_trigger_nolock_(bufev, EV_WRITE, 0); + + if (res == BEV_OK && + (bufev->enabled & EV_WRITE) && + evbuffer_get_length(bufev->output) && + !be_underlying_writebuf_full(bevf, state)) { + again = 1; + } + } + } while (again); + + /* reenable the outbuf_cb */ + evbuffer_cb_set_flags(bufev->output,bevf->outbuf_cb, + EVBUFFER_CB_ENABLED); + + if (*processed_out) + BEV_RESET_GENERIC_WRITE_TIMEOUT(bufev); + + return res; +} + +/* Called when the size of our outbuf changes. */ +static void +bufferevent_filtered_outbuf_cb(struct evbuffer *buf, + const struct evbuffer_cb_info *cbinfo, void *arg) +{ + struct bufferevent_filtered *bevf = arg; + struct bufferevent *bev = downcast(bevf); + + if (cbinfo->n_added) { + int processed_any = 0; + /* Somebody added more data to the output buffer. Try to + * process it, if we should. */ + bufferevent_incref_and_lock_(bev); + be_filter_process_output(bevf, BEV_NORMAL, &processed_any); + bufferevent_decref_and_unlock_(bev); + } +} + +/* Called when the underlying socket has read. */ +static void +be_filter_readcb(struct bufferevent *underlying, void *me_) +{ + struct bufferevent_filtered *bevf = me_; + enum bufferevent_filter_result res; + enum bufferevent_flush_mode state; + struct bufferevent *bufev = downcast(bevf); + struct bufferevent_private *bufev_private = BEV_UPCAST(bufev); + int processed_any = 0; + + BEV_LOCK(bufev); + + // It's possible our refcount is 0 at this point if another thread free'd our filterevent + EVUTIL_ASSERT(bufev_private->refcnt >= 0); + + // If our refcount is > 0 + if (bufev_private->refcnt > 0) { + + if (bevf->got_eof) + state = BEV_FINISHED; + else + state = BEV_NORMAL; + + /* XXXX use return value */ + res = be_filter_process_input(bevf, state, &processed_any); + (void)res; + + /* XXX This should be in process_input, not here. There are + * other places that can call process-input, and they should + * force readcb calls as needed. */ + if (processed_any) + bufferevent_trigger_nolock_(bufev, EV_READ, 0); + } + + BEV_UNLOCK(bufev); +} + +/* Called when the underlying socket has drained enough that we can write to + it. */ +static void +be_filter_writecb(struct bufferevent *underlying, void *me_) +{ + struct bufferevent_filtered *bevf = me_; + struct bufferevent *bev = downcast(bevf); + struct bufferevent_private *bufev_private = BEV_UPCAST(bev); + int processed_any = 0; + + BEV_LOCK(bev); + + // It's possible our refcount is 0 at this point if another thread free'd our filterevent + EVUTIL_ASSERT(bufev_private->refcnt >= 0); + + // If our refcount is > 0 + if (bufev_private->refcnt > 0) { + be_filter_process_output(bevf, BEV_NORMAL, &processed_any); + } + + BEV_UNLOCK(bev); +} + +/* Called when the underlying socket has given us an error */ +static void +be_filter_eventcb(struct bufferevent *underlying, short what, void *me_) +{ + struct bufferevent_filtered *bevf = me_; + struct bufferevent *bev = downcast(bevf); + struct bufferevent_private *bufev_private = BEV_UPCAST(bev); + + BEV_LOCK(bev); + + // It's possible our refcount is 0 at this point if another thread free'd our filterevent + EVUTIL_ASSERT(bufev_private->refcnt >= 0); + + // If our refcount is > 0 + if (bufev_private->refcnt > 0) { + + /* All we can really to is tell our own eventcb. */ + bufferevent_run_eventcb_(bev, what, 0); + } + + BEV_UNLOCK(bev); +} + +static int +be_filter_flush(struct bufferevent *bufev, + short iotype, enum bufferevent_flush_mode mode) +{ + struct bufferevent_filtered *bevf = upcast(bufev); + int processed_any = 0; + EVUTIL_ASSERT(bevf); + + bufferevent_incref_and_lock_(bufev); + + if (iotype & EV_READ) { + be_filter_process_input(bevf, mode, &processed_any); + } + if (iotype & EV_WRITE) { + be_filter_process_output(bevf, mode, &processed_any); + } + /* XXX check the return value? */ + /* XXX does this want to recursively call lower-level flushes? */ + bufferevent_flush(bevf->underlying, iotype, mode); + + bufferevent_decref_and_unlock_(bufev); + + return processed_any; +} + +static int +be_filter_ctrl(struct bufferevent *bev, enum bufferevent_ctrl_op op, + union bufferevent_ctrl_data *data) +{ + struct bufferevent_filtered *bevf; + switch (op) { + case BEV_CTRL_GET_UNDERLYING: + bevf = upcast(bev); + data->ptr = bevf->underlying; + return 0; + case BEV_CTRL_GET_FD: + case BEV_CTRL_SET_FD: + case BEV_CTRL_CANCEL_ALL: + default: + return -1; + } +} diff --git a/contrib/ntp/sntp/libevent/bufferevent_openssl.c b/contrib/ntp/sntp/libevent/bufferevent_openssl.c new file mode 100644 index 000000000..b30f90ff2 --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent_openssl.c @@ -0,0 +1,1504 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// Get rid of OSX 10.7 and greater deprecation warnings. +#if defined(__APPLE__) && defined(__clang__) +#pragma clang diagnostic ignored "-Wdeprecated-declarations" +#endif + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#include +#include +#include +#include +#ifdef EVENT__HAVE_STDARG_H +#include +#endif +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif + +#ifdef _WIN32 +#include +#endif + +#include "event2/bufferevent.h" +#include "event2/bufferevent_struct.h" +#include "event2/bufferevent_ssl.h" +#include "event2/buffer.h" +#include "event2/event.h" + +#include "mm-internal.h" +#include "bufferevent-internal.h" +#include "log-internal.h" + +#include +#include +#include + +/* + * Define an OpenSSL bio that targets a bufferevent. + */ + +/* -------------------- + A BIO is an OpenSSL abstraction that handles reading and writing data. The + library will happily speak SSL over anything that implements a BIO + interface. + + Here we define a BIO implementation that directs its output to a + bufferevent. We'll want to use this only when none of OpenSSL's built-in + IO mechanisms work for us. + -------------------- */ + +/* every BIO type needs its own integer type value. */ +#define BIO_TYPE_LIBEVENT 57 +/* ???? Arguably, we should set BIO_TYPE_FILTER or BIO_TYPE_SOURCE_SINK on + * this. */ + +#if 0 +static void +print_err(int val) +{ + int err; + printf("Error was %d\n", val); + + while ((err = ERR_get_error())) { + const char *msg = (const char*)ERR_reason_error_string(err); + const char *lib = (const char*)ERR_lib_error_string(err); + const char *func = (const char*)ERR_func_error_string(err); + + printf("%s in %s %s\n", msg, lib, func); + } +} +#else +#define print_err(v) ((void)0) +#endif + +/* Called to initialize a new BIO */ +static int +bio_bufferevent_new(BIO *b) +{ + b->init = 0; + b->num = -1; + b->ptr = NULL; /* We'll be putting the bufferevent in this field.*/ + b->flags = 0; + return 1; +} + +/* Called to uninitialize the BIO. */ +static int +bio_bufferevent_free(BIO *b) +{ + if (!b) + return 0; + if (b->shutdown) { + if (b->init && b->ptr) + bufferevent_free(b->ptr); + b->init = 0; + b->flags = 0; + b->ptr = NULL; + } + return 1; +} + +/* Called to extract data from the BIO. */ +static int +bio_bufferevent_read(BIO *b, char *out, int outlen) +{ + int r = 0; + struct evbuffer *input; + + BIO_clear_retry_flags(b); + + if (!out) + return 0; + if (!b->ptr) + return -1; + + input = bufferevent_get_input(b->ptr); + if (evbuffer_get_length(input) == 0) { + /* If there's no data to read, say so. */ + BIO_set_retry_read(b); + return -1; + } else { + r = evbuffer_remove(input, out, outlen); + } + + return r; +} + +/* Called to write data info the BIO */ +static int +bio_bufferevent_write(BIO *b, const char *in, int inlen) +{ + struct bufferevent *bufev = b->ptr; + struct evbuffer *output; + size_t outlen; + + BIO_clear_retry_flags(b); + + if (!b->ptr) + return -1; + + output = bufferevent_get_output(bufev); + outlen = evbuffer_get_length(output); + + /* Copy only as much data onto the output buffer as can fit under the + * high-water mark. */ + if (bufev->wm_write.high && bufev->wm_write.high <= (outlen+inlen)) { + if (bufev->wm_write.high <= outlen) { + /* If no data can fit, we'll need to retry later. */ + BIO_set_retry_write(b); + return -1; + } + inlen = bufev->wm_write.high - outlen; + } + + EVUTIL_ASSERT(inlen > 0); + evbuffer_add(output, in, inlen); + return inlen; +} + +/* Called to handle various requests */ +static long +bio_bufferevent_ctrl(BIO *b, int cmd, long num, void *ptr) +{ + struct bufferevent *bufev = b->ptr; + long ret = 1; + + switch (cmd) { + case BIO_CTRL_GET_CLOSE: + ret = b->shutdown; + break; + case BIO_CTRL_SET_CLOSE: + b->shutdown = (int)num; + break; + case BIO_CTRL_PENDING: + ret = evbuffer_get_length(bufferevent_get_input(bufev)) != 0; + break; + case BIO_CTRL_WPENDING: + ret = evbuffer_get_length(bufferevent_get_output(bufev)) != 0; + break; + /* XXXX These two are given a special-case treatment because + * of cargo-cultism. I should come up with a better reason. */ + case BIO_CTRL_DUP: + case BIO_CTRL_FLUSH: + ret = 1; + break; + default: + ret = 0; + break; + } + return ret; +} + +/* Called to write a string to the BIO */ +static int +bio_bufferevent_puts(BIO *b, const char *s) +{ + return bio_bufferevent_write(b, s, strlen(s)); +} + +/* Method table for the bufferevent BIO */ +static BIO_METHOD methods_bufferevent = { + BIO_TYPE_LIBEVENT, "bufferevent", + bio_bufferevent_write, + bio_bufferevent_read, + bio_bufferevent_puts, + NULL /* bio_bufferevent_gets */, + bio_bufferevent_ctrl, + bio_bufferevent_new, + bio_bufferevent_free, + NULL /* callback_ctrl */, +}; + +/* Return the method table for the bufferevents BIO */ +static BIO_METHOD * +BIO_s_bufferevent(void) +{ + return &methods_bufferevent; +} + +/* Create a new BIO to wrap communication around a bufferevent. If close_flag + * is true, the bufferevent will be freed when the BIO is closed. */ +static BIO * +BIO_new_bufferevent(struct bufferevent *bufferevent, int close_flag) +{ + BIO *result; + if (!bufferevent) + return NULL; + if (!(result = BIO_new(BIO_s_bufferevent()))) + return NULL; + result->init = 1; + result->ptr = bufferevent; + result->shutdown = close_flag ? 1 : 0; + return result; +} + +/* -------------------- + Now, here's the OpenSSL-based implementation of bufferevent. + + The implementation comes in two flavors: one that connects its SSL object + to an underlying bufferevent using a BIO_bufferevent, and one that has the + SSL object connect to a socket directly. The latter should generally be + faster, except on Windows, where your best bet is using a + bufferevent_async. + + (OpenSSL supports many other BIO types, too. But we can't use any unless + we have a good way to get notified when they become readable/writable.) + -------------------- */ + +struct bio_data_counts { + unsigned long n_written; + unsigned long n_read; +}; + +struct bufferevent_openssl { + /* Shared fields with common bufferevent implementation code. + If we were set up with an underlying bufferevent, we use the + events here as timers only. If we have an SSL, then we use + the events as socket events. + */ + struct bufferevent_private bev; + /* An underlying bufferevent that we're directing our output to. + If it's NULL, then we're connected to an fd, not an evbuffer. */ + struct bufferevent *underlying; + /* The SSL object doing our encryption. */ + SSL *ssl; + + /* A callback that's invoked when data arrives on our outbuf so we + know to write data to the SSL. */ + struct evbuffer_cb_entry *outbuf_cb; + + /* A count of how much data the bios have read/written total. Used + for rate-limiting. */ + struct bio_data_counts counts; + + /* If this value is greater than 0, then the last SSL_write blocked, + * and we need to try it again with this many bytes. */ + ev_ssize_t last_write; + +#define NUM_ERRORS 3 + ev_uint32_t errors[NUM_ERRORS]; + + /* When we next get available space, we should say "read" instead of + "write". This can happen if there's a renegotiation during a read + operation. */ + unsigned read_blocked_on_write : 1; + /* When we next get data, we should say "write" instead of "read". */ + unsigned write_blocked_on_read : 1; + /* Treat TCP close before SSL close on SSL >= v3 as clean EOF. */ + unsigned allow_dirty_shutdown : 1; + /* XXXX */ + unsigned fd_is_set : 1; + /* XXX */ + unsigned n_errors : 2; + + /* Are we currently connecting, accepting, or doing IO? */ + unsigned state : 2; +}; + +static int be_openssl_enable(struct bufferevent *, short); +static int be_openssl_disable(struct bufferevent *, short); +static void be_openssl_unlink(struct bufferevent *); +static void be_openssl_destruct(struct bufferevent *); +static int be_openssl_adj_timeouts(struct bufferevent *); +static int be_openssl_flush(struct bufferevent *bufev, + short iotype, enum bufferevent_flush_mode mode); +static int be_openssl_ctrl(struct bufferevent *, enum bufferevent_ctrl_op, union bufferevent_ctrl_data *); + +const struct bufferevent_ops bufferevent_ops_openssl = { + "ssl", + evutil_offsetof(struct bufferevent_openssl, bev.bev), + be_openssl_enable, + be_openssl_disable, + be_openssl_unlink, + be_openssl_destruct, + be_openssl_adj_timeouts, + be_openssl_flush, + be_openssl_ctrl, +}; + +/* Given a bufferevent, return a pointer to the bufferevent_openssl that + * contains it, if any. */ +static inline struct bufferevent_openssl * +upcast(struct bufferevent *bev) +{ + struct bufferevent_openssl *bev_o; + if (bev->be_ops != &bufferevent_ops_openssl) + return NULL; + bev_o = (void*)( ((char*)bev) - + evutil_offsetof(struct bufferevent_openssl, bev.bev)); + EVUTIL_ASSERT(bev_o->bev.bev.be_ops == &bufferevent_ops_openssl); + return bev_o; +} + +static inline void +put_error(struct bufferevent_openssl *bev_ssl, unsigned long err) +{ + if (bev_ssl->n_errors == NUM_ERRORS) + return; + /* The error type according to openssl is "unsigned long", but + openssl never uses more than 32 bits of it. It _can't_ use more + than 32 bits of it, since it needs to report errors on systems + where long is only 32 bits. + */ + bev_ssl->errors[bev_ssl->n_errors++] = (ev_uint32_t) err; +} + +/* Have the base communications channel (either the underlying bufferevent or + * ev_read and ev_write) start reading. Take the read-blocked-on-write flag + * into account. */ +static int +start_reading(struct bufferevent_openssl *bev_ssl) +{ + if (bev_ssl->underlying) { + bufferevent_unsuspend_read_(bev_ssl->underlying, + BEV_SUSPEND_FILT_READ); + return 0; + } else { + struct bufferevent *bev = &bev_ssl->bev.bev; + int r; + r = bufferevent_add_event_(&bev->ev_read, &bev->timeout_read); + if (r == 0 && bev_ssl->read_blocked_on_write) + r = bufferevent_add_event_(&bev->ev_write, + &bev->timeout_write); + return r; + } +} + +/* Have the base communications channel (either the underlying bufferevent or + * ev_read and ev_write) start writing. Take the write-blocked-on-read flag + * into account. */ +static int +start_writing(struct bufferevent_openssl *bev_ssl) +{ + int r = 0; + if (bev_ssl->underlying) { + ; + } else { + struct bufferevent *bev = &bev_ssl->bev.bev; + r = bufferevent_add_event_(&bev->ev_write, &bev->timeout_write); + if (!r && bev_ssl->write_blocked_on_read) + r = bufferevent_add_event_(&bev->ev_read, + &bev->timeout_read); + } + return r; +} + +static void +stop_reading(struct bufferevent_openssl *bev_ssl) +{ + if (bev_ssl->write_blocked_on_read) + return; + if (bev_ssl->underlying) { + bufferevent_suspend_read_(bev_ssl->underlying, + BEV_SUSPEND_FILT_READ); + } else { + struct bufferevent *bev = &bev_ssl->bev.bev; + event_del(&bev->ev_read); + } +} + +static void +stop_writing(struct bufferevent_openssl *bev_ssl) +{ + if (bev_ssl->read_blocked_on_write) + return; + if (bev_ssl->underlying) { + ; + } else { + struct bufferevent *bev = &bev_ssl->bev.bev; + event_del(&bev->ev_write); + } +} + +static int +set_rbow(struct bufferevent_openssl *bev_ssl) +{ + if (!bev_ssl->underlying) + stop_reading(bev_ssl); + bev_ssl->read_blocked_on_write = 1; + return start_writing(bev_ssl); +} + +static int +set_wbor(struct bufferevent_openssl *bev_ssl) +{ + if (!bev_ssl->underlying) + stop_writing(bev_ssl); + bev_ssl->write_blocked_on_read = 1; + return start_reading(bev_ssl); +} + +static int +clear_rbow(struct bufferevent_openssl *bev_ssl) +{ + struct bufferevent *bev = &bev_ssl->bev.bev; + int r = 0; + bev_ssl->read_blocked_on_write = 0; + if (!(bev->enabled & EV_WRITE)) + stop_writing(bev_ssl); + if (bev->enabled & EV_READ) + r = start_reading(bev_ssl); + return r; +} + + +static int +clear_wbor(struct bufferevent_openssl *bev_ssl) +{ + struct bufferevent *bev = &bev_ssl->bev.bev; + int r = 0; + bev_ssl->write_blocked_on_read = 0; + if (!(bev->enabled & EV_READ)) + stop_reading(bev_ssl); + if (bev->enabled & EV_WRITE) + r = start_writing(bev_ssl); + return r; +} + +static void +conn_closed(struct bufferevent_openssl *bev_ssl, int when, int errcode, int ret) +{ + int event = BEV_EVENT_ERROR; + int dirty_shutdown = 0; + unsigned long err; + + switch (errcode) { + case SSL_ERROR_ZERO_RETURN: + /* Possibly a clean shutdown. */ + if (SSL_get_shutdown(bev_ssl->ssl) & SSL_RECEIVED_SHUTDOWN) + event = BEV_EVENT_EOF; + else + dirty_shutdown = 1; + break; + case SSL_ERROR_SYSCALL: + /* IO error; possibly a dirty shutdown. */ + if (ret == 0 && ERR_peek_error() == 0) + dirty_shutdown = 1; + break; + case SSL_ERROR_SSL: + /* Protocol error. */ + break; + case SSL_ERROR_WANT_X509_LOOKUP: + /* XXXX handle this. */ + break; + case SSL_ERROR_NONE: + case SSL_ERROR_WANT_READ: + case SSL_ERROR_WANT_WRITE: + case SSL_ERROR_WANT_CONNECT: + case SSL_ERROR_WANT_ACCEPT: + default: + /* should be impossible; treat as normal error. */ + event_warnx("BUG: Unexpected OpenSSL error code %d", errcode); + break; + } + + while ((err = ERR_get_error())) { + put_error(bev_ssl, err); + } + + if (dirty_shutdown && bev_ssl->allow_dirty_shutdown) + event = BEV_EVENT_EOF; + + stop_reading(bev_ssl); + stop_writing(bev_ssl); + + /* when is BEV_EVENT_{READING|WRITING} */ + event = when | event; + bufferevent_run_eventcb_(&bev_ssl->bev.bev, event, 0); +} + +static void +init_bio_counts(struct bufferevent_openssl *bev_ssl) +{ + bev_ssl->counts.n_written = + BIO_number_written(SSL_get_wbio(bev_ssl->ssl)); + bev_ssl->counts.n_read = + BIO_number_read(SSL_get_rbio(bev_ssl->ssl)); +} + +static inline void +decrement_buckets(struct bufferevent_openssl *bev_ssl) +{ + unsigned long num_w = BIO_number_written(SSL_get_wbio(bev_ssl->ssl)); + unsigned long num_r = BIO_number_read(SSL_get_rbio(bev_ssl->ssl)); + /* These next two subtractions can wrap around. That's okay. */ + unsigned long w = num_w - bev_ssl->counts.n_written; + unsigned long r = num_r - bev_ssl->counts.n_read; + if (w) + bufferevent_decrement_write_buckets_(&bev_ssl->bev, w); + if (r) + bufferevent_decrement_read_buckets_(&bev_ssl->bev, r); + bev_ssl->counts.n_written = num_w; + bev_ssl->counts.n_read = num_r; +} + +#define OP_MADE_PROGRESS 1 +#define OP_BLOCKED 2 +#define OP_ERR 4 + +/* Return a bitmask of OP_MADE_PROGRESS (if we read anything); OP_BLOCKED (if + we're now blocked); and OP_ERR (if an error occurred). */ +static int +do_read(struct bufferevent_openssl *bev_ssl, int n_to_read) { + /* Requires lock */ + struct bufferevent *bev = &bev_ssl->bev.bev; + struct evbuffer *input = bev->input; + int r, n, i, n_used = 0, atmost; + struct evbuffer_iovec space[2]; + int result = 0; + + if (bev_ssl->bev.read_suspended) + return 0; + + atmost = bufferevent_get_read_max_(&bev_ssl->bev); + if (n_to_read > atmost) + n_to_read = atmost; + + n = evbuffer_reserve_space(input, n_to_read, space, 2); + if (n < 0) + return OP_ERR; + + for (i=0; ibev.read_suspended) + break; + r = SSL_read(bev_ssl->ssl, space[i].iov_base, space[i].iov_len); + if (r>0) { + result |= OP_MADE_PROGRESS; + if (bev_ssl->read_blocked_on_write) + if (clear_rbow(bev_ssl) < 0) + return OP_ERR | result; + ++n_used; + space[i].iov_len = r; + decrement_buckets(bev_ssl); + } else { + int err = SSL_get_error(bev_ssl->ssl, r); + print_err(err); + switch (err) { + case SSL_ERROR_WANT_READ: + /* Can't read until underlying has more data. */ + if (bev_ssl->read_blocked_on_write) + if (clear_rbow(bev_ssl) < 0) + return OP_ERR | result; + break; + case SSL_ERROR_WANT_WRITE: + /* This read operation requires a write, and the + * underlying is full */ + if (!bev_ssl->read_blocked_on_write) + if (set_rbow(bev_ssl) < 0) + return OP_ERR | result; + break; + default: + conn_closed(bev_ssl, BEV_EVENT_READING, err, r); + break; + } + result |= OP_BLOCKED; + break; /* out of the loop */ + } + } + + if (n_used) { + evbuffer_commit_space(input, space, n_used); + if (bev_ssl->underlying) + BEV_RESET_GENERIC_READ_TIMEOUT(bev); + } + + return result; +} + +/* Return a bitmask of OP_MADE_PROGRESS (if we wrote anything); OP_BLOCKED (if + we're now blocked); and OP_ERR (if an error occurred). */ +static int +do_write(struct bufferevent_openssl *bev_ssl, int atmost) +{ + int i, r, n, n_written = 0; + struct bufferevent *bev = &bev_ssl->bev.bev; + struct evbuffer *output = bev->output; + struct evbuffer_iovec space[8]; + int result = 0; + + if (bev_ssl->last_write > 0) + atmost = bev_ssl->last_write; + else + atmost = bufferevent_get_write_max_(&bev_ssl->bev); + + n = evbuffer_peek(output, atmost, NULL, space, 8); + if (n < 0) + return OP_ERR | result; + + if (n > 8) + n = 8; + for (i=0; i < n; ++i) { + if (bev_ssl->bev.write_suspended) + break; + + /* SSL_write will (reasonably) return 0 if we tell it to + send 0 data. Skip this case so we don't interpret the + result as an error */ + if (space[i].iov_len == 0) + continue; + + r = SSL_write(bev_ssl->ssl, space[i].iov_base, + space[i].iov_len); + if (r > 0) { + result |= OP_MADE_PROGRESS; + if (bev_ssl->write_blocked_on_read) + if (clear_wbor(bev_ssl) < 0) + return OP_ERR | result; + n_written += r; + bev_ssl->last_write = -1; + decrement_buckets(bev_ssl); + } else { + int err = SSL_get_error(bev_ssl->ssl, r); + print_err(err); + switch (err) { + case SSL_ERROR_WANT_WRITE: + /* Can't read until underlying has more data. */ + if (bev_ssl->write_blocked_on_read) + if (clear_wbor(bev_ssl) < 0) + return OP_ERR | result; + bev_ssl->last_write = space[i].iov_len; + break; + case SSL_ERROR_WANT_READ: + /* This read operation requires a write, and the + * underlying is full */ + if (!bev_ssl->write_blocked_on_read) + if (set_wbor(bev_ssl) < 0) + return OP_ERR | result; + bev_ssl->last_write = space[i].iov_len; + break; + default: + conn_closed(bev_ssl, BEV_EVENT_WRITING, err, r); + bev_ssl->last_write = -1; + break; + } + result |= OP_BLOCKED; + break; + } + } + if (n_written) { + evbuffer_drain(output, n_written); + if (bev_ssl->underlying) + BEV_RESET_GENERIC_WRITE_TIMEOUT(bev); + + bufferevent_trigger_nolock_(bev, EV_WRITE, 0); + } + return result; +} + +#define WRITE_FRAME 15000 + +#define READ_DEFAULT 4096 + +/* Try to figure out how many bytes to read; return 0 if we shouldn't be + * reading. */ +static int +bytes_to_read(struct bufferevent_openssl *bev) +{ + struct evbuffer *input = bev->bev.bev.input; + struct event_watermark *wm = &bev->bev.bev.wm_read; + int result = READ_DEFAULT; + ev_ssize_t limit; + /* XXX 99% of this is generic code that nearly all bufferevents will + * want. */ + + if (bev->write_blocked_on_read) { + return 0; + } + + if (! (bev->bev.bev.enabled & EV_READ)) { + return 0; + } + + if (bev->bev.read_suspended) { + return 0; + } + + if (wm->high) { + if (evbuffer_get_length(input) >= wm->high) { + return 0; + } + + result = wm->high - evbuffer_get_length(input); + } else { + result = READ_DEFAULT; + } + + /* Respect the rate limit */ + limit = bufferevent_get_read_max_(&bev->bev); + if (result > limit) { + result = limit; + } + + return result; +} + + +/* Things look readable. If write is blocked on read, write till it isn't. + * Read from the underlying buffer until we block or we hit our high-water + * mark. + */ +static void +consider_reading(struct bufferevent_openssl *bev_ssl) +{ + int r; + int n_to_read; + int all_result_flags = 0; + + while (bev_ssl->write_blocked_on_read) { + r = do_write(bev_ssl, WRITE_FRAME); + if (r & (OP_BLOCKED|OP_ERR)) + break; + } + if (bev_ssl->write_blocked_on_read) + return; + + n_to_read = bytes_to_read(bev_ssl); + + while (n_to_read) { + r = do_read(bev_ssl, n_to_read); + all_result_flags |= r; + + if (r & (OP_BLOCKED|OP_ERR)) + break; + + if (bev_ssl->bev.read_suspended) + break; + + /* Read all pending data. This won't hit the network + * again, and will (most importantly) put us in a state + * where we don't need to read anything else until the + * socket is readable again. It'll potentially make us + * overrun our read high-watermark (somewhat + * regrettable). The damage to the rate-limit has + * already been done, since OpenSSL went and read a + * whole SSL record anyway. */ + n_to_read = SSL_pending(bev_ssl->ssl); + + /* XXX This if statement is actually a bad bug, added to avoid + * XXX a worse bug. + * + * The bad bug: It can potentially cause resource unfairness + * by reading too much data from the underlying bufferevent; + * it can potentially cause read looping if the underlying + * bufferevent is a bufferevent_pair and deferred callbacks + * aren't used. + * + * The worse bug: If we didn't do this, then we would + * potentially not read any more from bev_ssl->underlying + * until more data arrived there, which could lead to us + * waiting forever. + */ + if (!n_to_read && bev_ssl->underlying) + n_to_read = bytes_to_read(bev_ssl); + } + + if (all_result_flags & OP_MADE_PROGRESS) { + struct bufferevent *bev = &bev_ssl->bev.bev; + + bufferevent_trigger_nolock_(bev, EV_READ, 0); + } + + if (!bev_ssl->underlying) { + /* Should be redundant, but let's avoid busy-looping */ + if (bev_ssl->bev.read_suspended || + !(bev_ssl->bev.bev.enabled & EV_READ)) { + event_del(&bev_ssl->bev.bev.ev_read); + } + } +} + +static void +consider_writing(struct bufferevent_openssl *bev_ssl) +{ + int r; + struct evbuffer *output = bev_ssl->bev.bev.output; + struct evbuffer *target = NULL; + struct event_watermark *wm = NULL; + + while (bev_ssl->read_blocked_on_write) { + r = do_read(bev_ssl, 1024); /* XXXX 1024 is a hack */ + if (r & OP_MADE_PROGRESS) { + struct bufferevent *bev = &bev_ssl->bev.bev; + + bufferevent_trigger_nolock_(bev, EV_READ, 0); + } + if (r & (OP_ERR|OP_BLOCKED)) + break; + } + if (bev_ssl->read_blocked_on_write) + return; + if (bev_ssl->underlying) { + target = bev_ssl->underlying->output; + wm = &bev_ssl->underlying->wm_write; + } + while ((bev_ssl->bev.bev.enabled & EV_WRITE) && + (! bev_ssl->bev.write_suspended) && + evbuffer_get_length(output) && + (!target || (! wm->high || evbuffer_get_length(target) < wm->high))) { + int n_to_write; + if (wm && wm->high) + n_to_write = wm->high - evbuffer_get_length(target); + else + n_to_write = WRITE_FRAME; + r = do_write(bev_ssl, n_to_write); + if (r & (OP_BLOCKED|OP_ERR)) + break; + } + + if (!bev_ssl->underlying) { + if (evbuffer_get_length(output) == 0) { + event_del(&bev_ssl->bev.bev.ev_write); + } else if (bev_ssl->bev.write_suspended || + !(bev_ssl->bev.bev.enabled & EV_WRITE)) { + /* Should be redundant, but let's avoid busy-looping */ + event_del(&bev_ssl->bev.bev.ev_write); + } + } +} + +static void +be_openssl_readcb(struct bufferevent *bev_base, void *ctx) +{ + struct bufferevent_openssl *bev_ssl = ctx; + consider_reading(bev_ssl); +} + +static void +be_openssl_writecb(struct bufferevent *bev_base, void *ctx) +{ + struct bufferevent_openssl *bev_ssl = ctx; + consider_writing(bev_ssl); +} + +static void +be_openssl_eventcb(struct bufferevent *bev_base, short what, void *ctx) +{ + struct bufferevent_openssl *bev_ssl = ctx; + int event = 0; + + if (what & BEV_EVENT_EOF) { + if (bev_ssl->allow_dirty_shutdown) + event = BEV_EVENT_EOF; + else + event = BEV_EVENT_ERROR; + } else if (what & BEV_EVENT_TIMEOUT) { + /* We sure didn't set this. Propagate it to the user. */ + event = what; + } else if (what & BEV_EVENT_ERROR) { + /* An error occurred on the connection. Propagate it to the user. */ + event = what; + } else if (what & BEV_EVENT_CONNECTED) { + /* Ignore it. We're saying SSL_connect() already, which will + eat it. */ + } + if (event) + bufferevent_run_eventcb_(&bev_ssl->bev.bev, event, 0); +} + +static void +be_openssl_readeventcb(evutil_socket_t fd, short what, void *ptr) +{ + struct bufferevent_openssl *bev_ssl = ptr; + bufferevent_incref_and_lock_(&bev_ssl->bev.bev); + if (what == EV_TIMEOUT) { + bufferevent_run_eventcb_(&bev_ssl->bev.bev, + BEV_EVENT_TIMEOUT|BEV_EVENT_READING, 0); + } else { + consider_reading(bev_ssl); + } + bufferevent_decref_and_unlock_(&bev_ssl->bev.bev); +} + +static void +be_openssl_writeeventcb(evutil_socket_t fd, short what, void *ptr) +{ + struct bufferevent_openssl *bev_ssl = ptr; + bufferevent_incref_and_lock_(&bev_ssl->bev.bev); + if (what == EV_TIMEOUT) { + bufferevent_run_eventcb_(&bev_ssl->bev.bev, + BEV_EVENT_TIMEOUT|BEV_EVENT_WRITING, 0); + } else { + consider_writing(bev_ssl); + } + bufferevent_decref_and_unlock_(&bev_ssl->bev.bev); +} + +static int +set_open_callbacks(struct bufferevent_openssl *bev_ssl, evutil_socket_t fd) +{ + if (bev_ssl->underlying) { + bufferevent_setcb(bev_ssl->underlying, + be_openssl_readcb, be_openssl_writecb, be_openssl_eventcb, + bev_ssl); + return 0; + } else { + struct bufferevent *bev = &bev_ssl->bev.bev; + int rpending=0, wpending=0, r1=0, r2=0; + if (fd < 0 && bev_ssl->fd_is_set) + fd = event_get_fd(&bev->ev_read); + if (bev_ssl->fd_is_set) { + rpending = event_pending(&bev->ev_read, EV_READ, NULL); + wpending = event_pending(&bev->ev_write, EV_WRITE, NULL); + event_del(&bev->ev_read); + event_del(&bev->ev_write); + } + event_assign(&bev->ev_read, bev->ev_base, fd, + EV_READ|EV_PERSIST|EV_FINALIZE, + be_openssl_readeventcb, bev_ssl); + event_assign(&bev->ev_write, bev->ev_base, fd, + EV_WRITE|EV_PERSIST|EV_FINALIZE, + be_openssl_writeeventcb, bev_ssl); + if (rpending) + r1 = bufferevent_add_event_(&bev->ev_read, &bev->timeout_read); + if (wpending) + r2 = bufferevent_add_event_(&bev->ev_write, &bev->timeout_write); + if (fd >= 0) { + bev_ssl->fd_is_set = 1; + } + return (r1<0 || r2<0) ? -1 : 0; + } +} + +static int +do_handshake(struct bufferevent_openssl *bev_ssl) +{ + int r; + + switch (bev_ssl->state) { + default: + case BUFFEREVENT_SSL_OPEN: + EVUTIL_ASSERT(0); + return -1; + case BUFFEREVENT_SSL_CONNECTING: + case BUFFEREVENT_SSL_ACCEPTING: + r = SSL_do_handshake(bev_ssl->ssl); + break; + } + decrement_buckets(bev_ssl); + + if (r==1) { + /* We're done! */ + bev_ssl->state = BUFFEREVENT_SSL_OPEN; + set_open_callbacks(bev_ssl, -1); /* XXXX handle failure */ + /* Call do_read and do_write as needed */ + bufferevent_enable(&bev_ssl->bev.bev, bev_ssl->bev.bev.enabled); + bufferevent_run_eventcb_(&bev_ssl->bev.bev, + BEV_EVENT_CONNECTED, 0); + return 1; + } else { + int err = SSL_get_error(bev_ssl->ssl, r); + print_err(err); + switch (err) { + case SSL_ERROR_WANT_WRITE: + if (!bev_ssl->underlying) { + stop_reading(bev_ssl); + return start_writing(bev_ssl); + } + return 0; + case SSL_ERROR_WANT_READ: + if (!bev_ssl->underlying) { + stop_writing(bev_ssl); + return start_reading(bev_ssl); + } + return 0; + default: + conn_closed(bev_ssl, BEV_EVENT_READING, err, r); + return -1; + } + } +} + +static void +be_openssl_handshakecb(struct bufferevent *bev_base, void *ctx) +{ + struct bufferevent_openssl *bev_ssl = ctx; + do_handshake(bev_ssl);/* XXX handle failure */ +} + +static void +be_openssl_handshakeeventcb(evutil_socket_t fd, short what, void *ptr) +{ + struct bufferevent_openssl *bev_ssl = ptr; + + bufferevent_incref_and_lock_(&bev_ssl->bev.bev); + if (what & EV_TIMEOUT) { + bufferevent_run_eventcb_(&bev_ssl->bev.bev, BEV_EVENT_TIMEOUT, 0); + } else + do_handshake(bev_ssl);/* XXX handle failure */ + bufferevent_decref_and_unlock_(&bev_ssl->bev.bev); +} + +static int +set_handshake_callbacks(struct bufferevent_openssl *bev_ssl, evutil_socket_t fd) +{ + if (bev_ssl->underlying) { + bufferevent_setcb(bev_ssl->underlying, + be_openssl_handshakecb, be_openssl_handshakecb, + be_openssl_eventcb, + bev_ssl); + return do_handshake(bev_ssl); + } else { + struct bufferevent *bev = &bev_ssl->bev.bev; + int r1=0, r2=0; + if (fd < 0 && bev_ssl->fd_is_set) + fd = event_get_fd(&bev->ev_read); + if (bev_ssl->fd_is_set) { + event_del(&bev->ev_read); + event_del(&bev->ev_write); + } + event_assign(&bev->ev_read, bev->ev_base, fd, + EV_READ|EV_PERSIST|EV_FINALIZE, + be_openssl_handshakeeventcb, bev_ssl); + event_assign(&bev->ev_write, bev->ev_base, fd, + EV_WRITE|EV_PERSIST|EV_FINALIZE, + be_openssl_handshakeeventcb, bev_ssl); + if (fd >= 0) { + r1 = bufferevent_add_event_(&bev->ev_read, &bev->timeout_read); + r2 = bufferevent_add_event_(&bev->ev_write, &bev->timeout_write); + bev_ssl->fd_is_set = 1; + } + return (r1<0 || r2<0) ? -1 : 0; + } +} + +int +bufferevent_ssl_renegotiate(struct bufferevent *bev) +{ + struct bufferevent_openssl *bev_ssl = upcast(bev); + if (!bev_ssl) + return -1; + if (SSL_renegotiate(bev_ssl->ssl) < 0) + return -1; + bev_ssl->state = BUFFEREVENT_SSL_CONNECTING; + if (set_handshake_callbacks(bev_ssl, -1) < 0) + return -1; + if (!bev_ssl->underlying) + return do_handshake(bev_ssl); + return 0; +} + +static void +be_openssl_outbuf_cb(struct evbuffer *buf, + const struct evbuffer_cb_info *cbinfo, void *arg) +{ + struct bufferevent_openssl *bev_ssl = arg; + int r = 0; + /* XXX need to hold a reference here. */ + + if (cbinfo->n_added && bev_ssl->state == BUFFEREVENT_SSL_OPEN) { + if (cbinfo->orig_size == 0) + r = bufferevent_add_event_(&bev_ssl->bev.bev.ev_write, + &bev_ssl->bev.bev.timeout_write); + consider_writing(bev_ssl); + } + /* XXX Handle r < 0 */ + (void)r; +} + + +static int +be_openssl_enable(struct bufferevent *bev, short events) +{ + struct bufferevent_openssl *bev_ssl = upcast(bev); + int r1 = 0, r2 = 0; + + if (bev_ssl->state != BUFFEREVENT_SSL_OPEN) + return 0; + + if (events & EV_READ) + r1 = start_reading(bev_ssl); + if (events & EV_WRITE) + r2 = start_writing(bev_ssl); + + if (bev_ssl->underlying) { + if (events & EV_READ) + BEV_RESET_GENERIC_READ_TIMEOUT(bev); + if (events & EV_WRITE) + BEV_RESET_GENERIC_WRITE_TIMEOUT(bev); + + if (events & EV_READ) + consider_reading(bev_ssl); + if (events & EV_WRITE) + consider_writing(bev_ssl); + } + return (r1 < 0 || r2 < 0) ? -1 : 0; +} + +static int +be_openssl_disable(struct bufferevent *bev, short events) +{ + struct bufferevent_openssl *bev_ssl = upcast(bev); + if (bev_ssl->state != BUFFEREVENT_SSL_OPEN) + return 0; + + if (events & EV_READ) + stop_reading(bev_ssl); + if (events & EV_WRITE) + stop_writing(bev_ssl); + + if (bev_ssl->underlying) { + if (events & EV_READ) + BEV_DEL_GENERIC_READ_TIMEOUT(bev); + if (events & EV_WRITE) + BEV_DEL_GENERIC_WRITE_TIMEOUT(bev); + } + return 0; +} + +static void +be_openssl_unlink(struct bufferevent *bev) +{ + struct bufferevent_openssl *bev_ssl = upcast(bev); + + if (bev_ssl->bev.options & BEV_OPT_CLOSE_ON_FREE) { + if (bev_ssl->underlying) { + if (BEV_UPCAST(bev_ssl->underlying)->refcnt < 2) { + event_warnx("BEV_OPT_CLOSE_ON_FREE set on an " + "bufferevent with too few references"); + } else { + bufferevent_free(bev_ssl->underlying); + /* We still have a reference to it, via our + * BIO. So we don't drop this. */ + // bev_ssl->underlying = NULL; + } + } + } else { + if (bev_ssl->underlying) { + if (bev_ssl->underlying->errorcb == be_openssl_eventcb) + bufferevent_setcb(bev_ssl->underlying, + NULL,NULL,NULL,NULL); + bufferevent_unsuspend_read_(bev_ssl->underlying, + BEV_SUSPEND_FILT_READ); + } + } +} + +static void +be_openssl_destruct(struct bufferevent *bev) +{ + struct bufferevent_openssl *bev_ssl = upcast(bev); + + if (bev_ssl->bev.options & BEV_OPT_CLOSE_ON_FREE) { + if (! bev_ssl->underlying) { + evutil_socket_t fd = -1; + BIO *bio = SSL_get_wbio(bev_ssl->ssl); + if (bio) + fd = BIO_get_fd(bio, NULL); + if (fd >= 0) + evutil_closesocket(fd); + } + SSL_free(bev_ssl->ssl); + } +} + +static int +be_openssl_adj_timeouts(struct bufferevent *bev) +{ + struct bufferevent_openssl *bev_ssl = upcast(bev); + + if (bev_ssl->underlying) { + return bufferevent_generic_adj_timeouts_(bev); + } else { + int r1=0, r2=0; + if (event_pending(&bev->ev_read, EV_READ, NULL)) { + if (evutil_timerisset(&bev->timeout_read)) { + r1 = bufferevent_add_event_(&bev->ev_read, &bev->timeout_read); + } else { + event_remove_timer(&bev->ev_read); + } + } + if (event_pending(&bev->ev_write, EV_WRITE, NULL)) { + if (evutil_timerisset(&bev->timeout_write)) { + r2 = bufferevent_add_event_(&bev->ev_write, &bev->timeout_write); + } else { + event_remove_timer(&bev->ev_write); + } + } + + return (r1<0 || r2<0) ? -1 : 0; + } +} + +static int +be_openssl_flush(struct bufferevent *bufev, + short iotype, enum bufferevent_flush_mode mode) +{ + /* XXXX Implement this. */ + return 0; +} + +static int +be_openssl_ctrl(struct bufferevent *bev, + enum bufferevent_ctrl_op op, union bufferevent_ctrl_data *data) +{ + struct bufferevent_openssl *bev_ssl = upcast(bev); + switch (op) { + case BEV_CTRL_SET_FD: + if (bev_ssl->underlying) + return -1; + { + BIO *bio; + bio = BIO_new_socket(data->fd, 0); + SSL_set_bio(bev_ssl->ssl, bio, bio); + bev_ssl->fd_is_set = 1; + } + if (data->fd == -1) + bev_ssl->fd_is_set = 0; + if (bev_ssl->state == BUFFEREVENT_SSL_OPEN) + return set_open_callbacks(bev_ssl, data->fd); + else { + return set_handshake_callbacks(bev_ssl, data->fd); + } + case BEV_CTRL_GET_FD: + if (bev_ssl->underlying) + return -1; + if (!bev_ssl->fd_is_set) + return -1; + data->fd = event_get_fd(&bev->ev_read); + return 0; + case BEV_CTRL_GET_UNDERLYING: + if (!bev_ssl->underlying) + return -1; + data->ptr = bev_ssl->underlying; + return 0; + case BEV_CTRL_CANCEL_ALL: + default: + return -1; + } +} + +SSL * +bufferevent_openssl_get_ssl(struct bufferevent *bufev) +{ + struct bufferevent_openssl *bev_ssl = upcast(bufev); + if (!bev_ssl) + return NULL; + return bev_ssl->ssl; +} + +static struct bufferevent * +bufferevent_openssl_new_impl(struct event_base *base, + struct bufferevent *underlying, + evutil_socket_t fd, + SSL *ssl, + enum bufferevent_ssl_state state, + int options) +{ + struct bufferevent_openssl *bev_ssl = NULL; + struct bufferevent_private *bev_p = NULL; + int tmp_options = options & ~BEV_OPT_THREADSAFE; + + if (underlying != NULL && fd >= 0) + return NULL; /* Only one can be set. */ + + if (!(bev_ssl = mm_calloc(1, sizeof(struct bufferevent_openssl)))) + goto err; + + bev_p = &bev_ssl->bev; + + if (bufferevent_init_common_(bev_p, base, + &bufferevent_ops_openssl, tmp_options) < 0) + goto err; + + /* Don't explode if we decide to realloc a chunk we're writing from in + * the output buffer. */ + SSL_set_mode(ssl, SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER); + + bev_ssl->underlying = underlying; + bev_ssl->ssl = ssl; + + bev_ssl->outbuf_cb = evbuffer_add_cb(bev_p->bev.output, + be_openssl_outbuf_cb, bev_ssl); + + if (options & BEV_OPT_THREADSAFE) + bufferevent_enable_locking_(&bev_ssl->bev.bev, NULL); + + if (underlying) { + bufferevent_init_generic_timeout_cbs_(&bev_ssl->bev.bev); + bufferevent_incref_(underlying); + } + + bev_ssl->state = state; + bev_ssl->last_write = -1; + + init_bio_counts(bev_ssl); + + switch (state) { + case BUFFEREVENT_SSL_ACCEPTING: + SSL_set_accept_state(bev_ssl->ssl); + if (set_handshake_callbacks(bev_ssl, fd) < 0) + goto err; + break; + case BUFFEREVENT_SSL_CONNECTING: + SSL_set_connect_state(bev_ssl->ssl); + if (set_handshake_callbacks(bev_ssl, fd) < 0) + goto err; + break; + case BUFFEREVENT_SSL_OPEN: + if (set_open_callbacks(bev_ssl, fd) < 0) + goto err; + break; + default: + goto err; + } + + if (underlying) { + bufferevent_setwatermark(underlying, EV_READ, 0, 0); + bufferevent_enable(underlying, EV_READ|EV_WRITE); + if (state == BUFFEREVENT_SSL_OPEN) + bufferevent_suspend_read_(underlying, + BEV_SUSPEND_FILT_READ); + } else { + bev_ssl->bev.bev.enabled = EV_READ|EV_WRITE; + if (bev_ssl->fd_is_set) { + if (state != BUFFEREVENT_SSL_OPEN) + if (event_add(&bev_ssl->bev.bev.ev_read, NULL) < 0) + goto err; + if (event_add(&bev_ssl->bev.bev.ev_write, NULL) < 0) + goto err; + } + } + + return &bev_ssl->bev.bev; +err: + if (bev_ssl) + bufferevent_free(&bev_ssl->bev.bev); + return NULL; +} + +struct bufferevent * +bufferevent_openssl_filter_new(struct event_base *base, + struct bufferevent *underlying, + SSL *ssl, + enum bufferevent_ssl_state state, + int options) +{ + /* We don't tell the BIO to close the bufferevent; we do it ourselves + * on be_openssl_destruct */ + int close_flag = 0; /* options & BEV_OPT_CLOSE_ON_FREE; */ + BIO *bio; + if (!underlying) + return NULL; + if (!(bio = BIO_new_bufferevent(underlying, close_flag))) + return NULL; + + SSL_set_bio(ssl, bio, bio); + + return bufferevent_openssl_new_impl( + base, underlying, -1, ssl, state, options); +} + +struct bufferevent * +bufferevent_openssl_socket_new(struct event_base *base, + evutil_socket_t fd, + SSL *ssl, + enum bufferevent_ssl_state state, + int options) +{ + /* Does the SSL already have an fd? */ + BIO *bio = SSL_get_wbio(ssl); + long have_fd = -1; + + if (bio) + have_fd = BIO_get_fd(bio, NULL); + + if (have_fd >= 0) { + /* The SSL is already configured with an fd. */ + if (fd < 0) { + /* We should learn the fd from the SSL. */ + fd = (evutil_socket_t) have_fd; + } else if (have_fd == (long)fd) { + /* We already know the fd from the SSL; do nothing */ + } else { + /* We specified an fd different from that of the SSL. + This is probably an error on our part. Fail. */ + return NULL; + } + (void) BIO_set_close(bio, 0); + } else { + /* The SSL isn't configured with a BIO with an fd. */ + if (fd >= 0) { + /* ... and we have an fd we want to use. */ + bio = BIO_new_socket(fd, 0); + SSL_set_bio(ssl, bio, bio); + } else { + /* Leave the fd unset. */ + } + } + + return bufferevent_openssl_new_impl( + base, NULL, fd, ssl, state, options); +} + +int +bufferevent_openssl_get_allow_dirty_shutdown(struct bufferevent *bev) +{ + int allow_dirty_shutdown = -1; + struct bufferevent_openssl *bev_ssl; + BEV_LOCK(bev); + bev_ssl = upcast(bev); + if (bev_ssl) + allow_dirty_shutdown = bev_ssl->allow_dirty_shutdown; + BEV_UNLOCK(bev); + return allow_dirty_shutdown; +} + +void +bufferevent_openssl_set_allow_dirty_shutdown(struct bufferevent *bev, + int allow_dirty_shutdown) +{ + struct bufferevent_openssl *bev_ssl; + BEV_LOCK(bev); + bev_ssl = upcast(bev); + if (bev_ssl) + bev_ssl->allow_dirty_shutdown = !!allow_dirty_shutdown; + BEV_UNLOCK(bev); +} + +unsigned long +bufferevent_get_openssl_error(struct bufferevent *bev) +{ + unsigned long err = 0; + struct bufferevent_openssl *bev_ssl; + BEV_LOCK(bev); + bev_ssl = upcast(bev); + if (bev_ssl && bev_ssl->n_errors) { + err = bev_ssl->errors[--bev_ssl->n_errors]; + } + BEV_UNLOCK(bev); + return err; +} diff --git a/contrib/ntp/sntp/libevent/bufferevent_pair.c b/contrib/ntp/sntp/libevent/bufferevent_pair.c new file mode 100644 index 000000000..8154e17be --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent_pair.c @@ -0,0 +1,358 @@ +/* + * Copyright (c) 2009-2012 Niels Provos, Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#ifdef _WIN32 +#include +#endif + +#include "event2/util.h" +#include "event2/buffer.h" +#include "event2/bufferevent.h" +#include "event2/bufferevent_struct.h" +#include "event2/event.h" +#include "defer-internal.h" +#include "bufferevent-internal.h" +#include "mm-internal.h" +#include "util-internal.h" + +struct bufferevent_pair { + struct bufferevent_private bev; + struct bufferevent_pair *partner; + /* For ->destruct() lock checking */ + struct bufferevent_pair *unlinked_partner; +}; + + +/* Given a bufferevent that's really a bev part of a bufferevent_pair, + * return that bufferevent_filtered. Returns NULL otherwise.*/ +static inline struct bufferevent_pair * +upcast(struct bufferevent *bev) +{ + struct bufferevent_pair *bev_p; + if (bev->be_ops != &bufferevent_ops_pair) + return NULL; + bev_p = EVUTIL_UPCAST(bev, struct bufferevent_pair, bev.bev); + EVUTIL_ASSERT(bev_p->bev.bev.be_ops == &bufferevent_ops_pair); + return bev_p; +} + +#define downcast(bev_pair) (&(bev_pair)->bev.bev) + +static inline void +incref_and_lock(struct bufferevent *b) +{ + struct bufferevent_pair *bevp; + bufferevent_incref_and_lock_(b); + bevp = upcast(b); + if (bevp->partner) + bufferevent_incref_and_lock_(downcast(bevp->partner)); +} + +static inline void +decref_and_unlock(struct bufferevent *b) +{ + struct bufferevent_pair *bevp = upcast(b); + if (bevp->partner) + bufferevent_decref_and_unlock_(downcast(bevp->partner)); + bufferevent_decref_and_unlock_(b); +} + +/* XXX Handle close */ + +static void be_pair_outbuf_cb(struct evbuffer *, + const struct evbuffer_cb_info *, void *); + +static struct bufferevent_pair * +bufferevent_pair_elt_new(struct event_base *base, + int options) +{ + struct bufferevent_pair *bufev; + if (! (bufev = mm_calloc(1, sizeof(struct bufferevent_pair)))) + return NULL; + if (bufferevent_init_common_(&bufev->bev, base, &bufferevent_ops_pair, + options)) { + mm_free(bufev); + return NULL; + } + if (!evbuffer_add_cb(bufev->bev.bev.output, be_pair_outbuf_cb, bufev)) { + bufferevent_free(downcast(bufev)); + return NULL; + } + + bufferevent_init_generic_timeout_cbs_(&bufev->bev.bev); + + return bufev; +} + +int +bufferevent_pair_new(struct event_base *base, int options, + struct bufferevent *pair[2]) +{ + struct bufferevent_pair *bufev1 = NULL, *bufev2 = NULL; + int tmp_options; + + options |= BEV_OPT_DEFER_CALLBACKS; + tmp_options = options & ~BEV_OPT_THREADSAFE; + + bufev1 = bufferevent_pair_elt_new(base, options); + if (!bufev1) + return -1; + bufev2 = bufferevent_pair_elt_new(base, tmp_options); + if (!bufev2) { + bufferevent_free(downcast(bufev1)); + return -1; + } + + if (options & BEV_OPT_THREADSAFE) { + /*XXXX check return */ + bufferevent_enable_locking_(downcast(bufev2), bufev1->bev.lock); + } + + bufev1->partner = bufev2; + bufev2->partner = bufev1; + + evbuffer_freeze(downcast(bufev1)->input, 0); + evbuffer_freeze(downcast(bufev1)->output, 1); + evbuffer_freeze(downcast(bufev2)->input, 0); + evbuffer_freeze(downcast(bufev2)->output, 1); + + pair[0] = downcast(bufev1); + pair[1] = downcast(bufev2); + + return 0; +} + +static void +be_pair_transfer(struct bufferevent *src, struct bufferevent *dst, + int ignore_wm) +{ + size_t dst_size; + size_t n; + + evbuffer_unfreeze(src->output, 1); + evbuffer_unfreeze(dst->input, 0); + + if (dst->wm_read.high) { + dst_size = evbuffer_get_length(dst->input); + if (dst_size < dst->wm_read.high) { + n = dst->wm_read.high - dst_size; + evbuffer_remove_buffer(src->output, dst->input, n); + } else { + if (!ignore_wm) + goto done; + n = evbuffer_get_length(src->output); + evbuffer_add_buffer(dst->input, src->output); + } + } else { + n = evbuffer_get_length(src->output); + evbuffer_add_buffer(dst->input, src->output); + } + + if (n) { + BEV_RESET_GENERIC_READ_TIMEOUT(dst); + + if (evbuffer_get_length(dst->output)) + BEV_RESET_GENERIC_WRITE_TIMEOUT(dst); + else + BEV_DEL_GENERIC_WRITE_TIMEOUT(dst); + } + + bufferevent_trigger_nolock_(dst, EV_READ, 0); + bufferevent_trigger_nolock_(src, EV_WRITE, 0); +done: + evbuffer_freeze(src->output, 1); + evbuffer_freeze(dst->input, 0); +} + +static inline int +be_pair_wants_to_talk(struct bufferevent_pair *src, + struct bufferevent_pair *dst) +{ + return (downcast(src)->enabled & EV_WRITE) && + (downcast(dst)->enabled & EV_READ) && + !dst->bev.read_suspended && + evbuffer_get_length(downcast(src)->output); +} + +static void +be_pair_outbuf_cb(struct evbuffer *outbuf, + const struct evbuffer_cb_info *info, void *arg) +{ + struct bufferevent_pair *bev_pair = arg; + struct bufferevent_pair *partner = bev_pair->partner; + + incref_and_lock(downcast(bev_pair)); + + if (info->n_added > info->n_deleted && partner) { + /* We got more data. If the other side's reading, then + hand it over. */ + if (be_pair_wants_to_talk(bev_pair, partner)) { + be_pair_transfer(downcast(bev_pair), downcast(partner), 0); + } + } + + decref_and_unlock(downcast(bev_pair)); +} + +static int +be_pair_enable(struct bufferevent *bufev, short events) +{ + struct bufferevent_pair *bev_p = upcast(bufev); + struct bufferevent_pair *partner = bev_p->partner; + + incref_and_lock(bufev); + + if (events & EV_READ) { + BEV_RESET_GENERIC_READ_TIMEOUT(bufev); + } + if ((events & EV_WRITE) && evbuffer_get_length(bufev->output)) + BEV_RESET_GENERIC_WRITE_TIMEOUT(bufev); + + /* We're starting to read! Does the other side have anything to write?*/ + if ((events & EV_READ) && partner && + be_pair_wants_to_talk(partner, bev_p)) { + be_pair_transfer(downcast(partner), bufev, 0); + } + /* We're starting to write! Does the other side want to read? */ + if ((events & EV_WRITE) && partner && + be_pair_wants_to_talk(bev_p, partner)) { + be_pair_transfer(bufev, downcast(partner), 0); + } + decref_and_unlock(bufev); + return 0; +} + +static int +be_pair_disable(struct bufferevent *bev, short events) +{ + if (events & EV_READ) { + BEV_DEL_GENERIC_READ_TIMEOUT(bev); + } + if (events & EV_WRITE) { + BEV_DEL_GENERIC_WRITE_TIMEOUT(bev); + } + return 0; +} + +static void +be_pair_unlink(struct bufferevent *bev) +{ + struct bufferevent_pair *bev_p = upcast(bev); + + if (bev_p->partner) { + bev_p->unlinked_partner = bev_p->partner; + bev_p->partner->partner = NULL; + bev_p->partner = NULL; + } +} + +/* Free *shared* lock in the latest be (since we share it between two of them). */ +static void +be_pair_destruct(struct bufferevent *bev) +{ + struct bufferevent_pair *bev_p = upcast(bev); + + /* Transfer ownership of the lock into partner, otherwise we will use + * already free'd lock during freeing second bev, see next example: + * + * bev1->own_lock = 1 + * bev2->own_lock = 0 + * bev2->lock = bev1->lock + * + * bufferevent_free(bev1) # refcnt == 0 -> unlink + * bufferevent_free(bev2) # refcnt == 0 -> unlink + * + * event_base_free() -> finilizers -> EVTHREAD_FREE_LOCK(bev1->lock) + * -> BEV_LOCK(bev2->lock) <-- already freed + * + * Where bev1 == pair[0], bev2 == pair[1]. + */ + if (bev_p->unlinked_partner && bev_p->bev.own_lock) { + bev_p->unlinked_partner->bev.own_lock = 1; + bev_p->bev.own_lock = 0; + } + bev_p->unlinked_partner = NULL; +} + +static int +be_pair_flush(struct bufferevent *bev, short iotype, + enum bufferevent_flush_mode mode) +{ + struct bufferevent_pair *bev_p = upcast(bev); + struct bufferevent *partner; + incref_and_lock(bev); + if (!bev_p->partner) + return -1; + + partner = downcast(bev_p->partner); + + if (mode == BEV_NORMAL) + return 0; + + if ((iotype & EV_READ) != 0) + be_pair_transfer(partner, bev, 1); + + if ((iotype & EV_WRITE) != 0) + be_pair_transfer(bev, partner, 1); + + if (mode == BEV_FINISHED) { + bufferevent_run_eventcb_(partner, iotype|BEV_EVENT_EOF, 0); + } + decref_and_unlock(bev); + return 0; +} + +struct bufferevent * +bufferevent_pair_get_partner(struct bufferevent *bev) +{ + struct bufferevent_pair *bev_p; + struct bufferevent *partner = NULL; + bev_p = upcast(bev); + if (! bev_p) + return NULL; + + incref_and_lock(bev); + if (bev_p->partner) + partner = downcast(bev_p->partner); + decref_and_unlock(bev); + return partner; +} + +const struct bufferevent_ops bufferevent_ops_pair = { + "pair_elt", + evutil_offsetof(struct bufferevent_pair, bev.bev), + be_pair_enable, + be_pair_disable, + be_pair_unlink, + be_pair_destruct, + bufferevent_generic_adj_timeouts_, + be_pair_flush, + NULL, /* ctrl */ +}; diff --git a/contrib/ntp/sntp/libevent/bufferevent_ratelim.c b/contrib/ntp/sntp/libevent/bufferevent_ratelim.c new file mode 100644 index 000000000..bde192021 --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent_ratelim.c @@ -0,0 +1,1092 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * Copyright (c) 2002-2006 Niels Provos + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "evconfig-private.h" + +#include +#include +#include +#include + +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/util.h" +#include "event2/bufferevent.h" +#include "event2/bufferevent_struct.h" +#include "event2/buffer.h" + +#include "ratelim-internal.h" + +#include "bufferevent-internal.h" +#include "mm-internal.h" +#include "util-internal.h" +#include "event-internal.h" + +int +ev_token_bucket_init_(struct ev_token_bucket *bucket, + const struct ev_token_bucket_cfg *cfg, + ev_uint32_t current_tick, + int reinitialize) +{ + if (reinitialize) { + /* on reinitialization, we only clip downwards, since we've + already used who-knows-how-much bandwidth this tick. We + leave "last_updated" as it is; the next update will add the + appropriate amount of bandwidth to the bucket. + */ + if (bucket->read_limit > (ev_int64_t) cfg->read_maximum) + bucket->read_limit = cfg->read_maximum; + if (bucket->write_limit > (ev_int64_t) cfg->write_maximum) + bucket->write_limit = cfg->write_maximum; + } else { + bucket->read_limit = cfg->read_rate; + bucket->write_limit = cfg->write_rate; + bucket->last_updated = current_tick; + } + return 0; +} + +int +ev_token_bucket_update_(struct ev_token_bucket *bucket, + const struct ev_token_bucket_cfg *cfg, + ev_uint32_t current_tick) +{ + /* It's okay if the tick number overflows, since we'll just + * wrap around when we do the unsigned substraction. */ + unsigned n_ticks = current_tick - bucket->last_updated; + + /* Make sure some ticks actually happened, and that time didn't + * roll back. */ + if (n_ticks == 0 || n_ticks > INT_MAX) + return 0; + + /* Naively, we would say + bucket->limit += n_ticks * cfg->rate; + + if (bucket->limit > cfg->maximum) + bucket->limit = cfg->maximum; + + But we're worried about overflow, so we do it like this: + */ + + if ((cfg->read_maximum - bucket->read_limit) / n_ticks < cfg->read_rate) + bucket->read_limit = cfg->read_maximum; + else + bucket->read_limit += n_ticks * cfg->read_rate; + + + if ((cfg->write_maximum - bucket->write_limit) / n_ticks < cfg->write_rate) + bucket->write_limit = cfg->write_maximum; + else + bucket->write_limit += n_ticks * cfg->write_rate; + + + bucket->last_updated = current_tick; + + return 1; +} + +static inline void +bufferevent_update_buckets(struct bufferevent_private *bev) +{ + /* Must hold lock on bev. */ + struct timeval now; + unsigned tick; + event_base_gettimeofday_cached(bev->bev.ev_base, &now); + tick = ev_token_bucket_get_tick_(&now, bev->rate_limiting->cfg); + if (tick != bev->rate_limiting->limit.last_updated) + ev_token_bucket_update_(&bev->rate_limiting->limit, + bev->rate_limiting->cfg, tick); +} + +ev_uint32_t +ev_token_bucket_get_tick_(const struct timeval *tv, + const struct ev_token_bucket_cfg *cfg) +{ + /* This computation uses two multiplies and a divide. We could do + * fewer if we knew that the tick length was an integer number of + * seconds, or if we knew it divided evenly into a second. We should + * investigate that more. + */ + + /* We cast to an ev_uint64_t first, since we don't want to overflow + * before we do the final divide. */ + ev_uint64_t msec = (ev_uint64_t)tv->tv_sec * 1000 + tv->tv_usec / 1000; + return (unsigned)(msec / cfg->msec_per_tick); +} + +struct ev_token_bucket_cfg * +ev_token_bucket_cfg_new(size_t read_rate, size_t read_burst, + size_t write_rate, size_t write_burst, + const struct timeval *tick_len) +{ + struct ev_token_bucket_cfg *r; + struct timeval g; + if (! tick_len) { + g.tv_sec = 1; + g.tv_usec = 0; + tick_len = &g; + } + if (read_rate > read_burst || write_rate > write_burst || + read_rate < 1 || write_rate < 1) + return NULL; + if (read_rate > EV_RATE_LIMIT_MAX || + write_rate > EV_RATE_LIMIT_MAX || + read_burst > EV_RATE_LIMIT_MAX || + write_burst > EV_RATE_LIMIT_MAX) + return NULL; + r = mm_calloc(1, sizeof(struct ev_token_bucket_cfg)); + if (!r) + return NULL; + r->read_rate = read_rate; + r->write_rate = write_rate; + r->read_maximum = read_burst; + r->write_maximum = write_burst; + memcpy(&r->tick_timeout, tick_len, sizeof(struct timeval)); + r->msec_per_tick = (tick_len->tv_sec * 1000) + + (tick_len->tv_usec & COMMON_TIMEOUT_MICROSECONDS_MASK)/1000; + return r; +} + +void +ev_token_bucket_cfg_free(struct ev_token_bucket_cfg *cfg) +{ + mm_free(cfg); +} + +/* Default values for max_single_read & max_single_write variables. */ +#define MAX_SINGLE_READ_DEFAULT 16384 +#define MAX_SINGLE_WRITE_DEFAULT 16384 + +#define LOCK_GROUP(g) EVLOCK_LOCK((g)->lock, 0) +#define UNLOCK_GROUP(g) EVLOCK_UNLOCK((g)->lock, 0) + +static int bev_group_suspend_reading_(struct bufferevent_rate_limit_group *g); +static int bev_group_suspend_writing_(struct bufferevent_rate_limit_group *g); +static void bev_group_unsuspend_reading_(struct bufferevent_rate_limit_group *g); +static void bev_group_unsuspend_writing_(struct bufferevent_rate_limit_group *g); + +/** Helper: figure out the maximum amount we should write if is_write, or + the maximum amount we should read if is_read. Return that maximum, or + 0 if our bucket is wholly exhausted. + */ +static inline ev_ssize_t +bufferevent_get_rlim_max_(struct bufferevent_private *bev, int is_write) +{ + /* needs lock on bev. */ + ev_ssize_t max_so_far = is_write?bev->max_single_write:bev->max_single_read; + +#define LIM(x) \ + (is_write ? (x).write_limit : (x).read_limit) + +#define GROUP_SUSPENDED(g) \ + (is_write ? (g)->write_suspended : (g)->read_suspended) + + /* Sets max_so_far to MIN(x, max_so_far) */ +#define CLAMPTO(x) \ + do { \ + if (max_so_far > (x)) \ + max_so_far = (x); \ + } while (0); + + if (!bev->rate_limiting) + return max_so_far; + + /* If rate-limiting is enabled at all, update the appropriate + bucket, and take the smaller of our rate limit and the group + rate limit. + */ + + if (bev->rate_limiting->cfg) { + bufferevent_update_buckets(bev); + max_so_far = LIM(bev->rate_limiting->limit); + } + if (bev->rate_limiting->group) { + struct bufferevent_rate_limit_group *g = + bev->rate_limiting->group; + ev_ssize_t share; + LOCK_GROUP(g); + if (GROUP_SUSPENDED(g)) { + /* We can get here if we failed to lock this + * particular bufferevent while suspending the whole + * group. */ + if (is_write) + bufferevent_suspend_write_(&bev->bev, + BEV_SUSPEND_BW_GROUP); + else + bufferevent_suspend_read_(&bev->bev, + BEV_SUSPEND_BW_GROUP); + share = 0; + } else { + /* XXXX probably we should divide among the active + * members, not the total members. */ + share = LIM(g->rate_limit) / g->n_members; + if (share < g->min_share) + share = g->min_share; + } + UNLOCK_GROUP(g); + CLAMPTO(share); + } + + if (max_so_far < 0) + max_so_far = 0; + return max_so_far; +} + +ev_ssize_t +bufferevent_get_read_max_(struct bufferevent_private *bev) +{ + return bufferevent_get_rlim_max_(bev, 0); +} + +ev_ssize_t +bufferevent_get_write_max_(struct bufferevent_private *bev) +{ + return bufferevent_get_rlim_max_(bev, 1); +} + +int +bufferevent_decrement_read_buckets_(struct bufferevent_private *bev, ev_ssize_t bytes) +{ + /* XXXXX Make sure all users of this function check its return value */ + int r = 0; + /* need to hold lock on bev */ + if (!bev->rate_limiting) + return 0; + + if (bev->rate_limiting->cfg) { + bev->rate_limiting->limit.read_limit -= bytes; + if (bev->rate_limiting->limit.read_limit <= 0) { + bufferevent_suspend_read_(&bev->bev, BEV_SUSPEND_BW); + if (event_add(&bev->rate_limiting->refill_bucket_event, + &bev->rate_limiting->cfg->tick_timeout) < 0) + r = -1; + } else if (bev->read_suspended & BEV_SUSPEND_BW) { + if (!(bev->write_suspended & BEV_SUSPEND_BW)) + event_del(&bev->rate_limiting->refill_bucket_event); + bufferevent_unsuspend_read_(&bev->bev, BEV_SUSPEND_BW); + } + } + + if (bev->rate_limiting->group) { + LOCK_GROUP(bev->rate_limiting->group); + bev->rate_limiting->group->rate_limit.read_limit -= bytes; + bev->rate_limiting->group->total_read += bytes; + if (bev->rate_limiting->group->rate_limit.read_limit <= 0) { + bev_group_suspend_reading_(bev->rate_limiting->group); + } else if (bev->rate_limiting->group->read_suspended) { + bev_group_unsuspend_reading_(bev->rate_limiting->group); + } + UNLOCK_GROUP(bev->rate_limiting->group); + } + + return r; +} + +int +bufferevent_decrement_write_buckets_(struct bufferevent_private *bev, ev_ssize_t bytes) +{ + /* XXXXX Make sure all users of this function check its return value */ + int r = 0; + /* need to hold lock */ + if (!bev->rate_limiting) + return 0; + + if (bev->rate_limiting->cfg) { + bev->rate_limiting->limit.write_limit -= bytes; + if (bev->rate_limiting->limit.write_limit <= 0) { + bufferevent_suspend_write_(&bev->bev, BEV_SUSPEND_BW); + if (event_add(&bev->rate_limiting->refill_bucket_event, + &bev->rate_limiting->cfg->tick_timeout) < 0) + r = -1; + } else if (bev->write_suspended & BEV_SUSPEND_BW) { + if (!(bev->read_suspended & BEV_SUSPEND_BW)) + event_del(&bev->rate_limiting->refill_bucket_event); + bufferevent_unsuspend_write_(&bev->bev, BEV_SUSPEND_BW); + } + } + + if (bev->rate_limiting->group) { + LOCK_GROUP(bev->rate_limiting->group); + bev->rate_limiting->group->rate_limit.write_limit -= bytes; + bev->rate_limiting->group->total_written += bytes; + if (bev->rate_limiting->group->rate_limit.write_limit <= 0) { + bev_group_suspend_writing_(bev->rate_limiting->group); + } else if (bev->rate_limiting->group->write_suspended) { + bev_group_unsuspend_writing_(bev->rate_limiting->group); + } + UNLOCK_GROUP(bev->rate_limiting->group); + } + + return r; +} + +/** Stop reading on every bufferevent in g */ +static int +bev_group_suspend_reading_(struct bufferevent_rate_limit_group *g) +{ + /* Needs group lock */ + struct bufferevent_private *bev; + g->read_suspended = 1; + g->pending_unsuspend_read = 0; + + /* Note that in this loop we call EVLOCK_TRY_LOCK_ instead of BEV_LOCK, + to prevent a deadlock. (Ordinarily, the group lock nests inside + the bufferevent locks. If we are unable to lock any individual + bufferevent, it will find out later when it looks at its limit + and sees that its group is suspended.) + */ + LIST_FOREACH(bev, &g->members, rate_limiting->next_in_group) { + if (EVLOCK_TRY_LOCK_(bev->lock)) { + bufferevent_suspend_read_(&bev->bev, + BEV_SUSPEND_BW_GROUP); + EVLOCK_UNLOCK(bev->lock, 0); + } + } + return 0; +} + +/** Stop writing on every bufferevent in g */ +static int +bev_group_suspend_writing_(struct bufferevent_rate_limit_group *g) +{ + /* Needs group lock */ + struct bufferevent_private *bev; + g->write_suspended = 1; + g->pending_unsuspend_write = 0; + LIST_FOREACH(bev, &g->members, rate_limiting->next_in_group) { + if (EVLOCK_TRY_LOCK_(bev->lock)) { + bufferevent_suspend_write_(&bev->bev, + BEV_SUSPEND_BW_GROUP); + EVLOCK_UNLOCK(bev->lock, 0); + } + } + return 0; +} + +/** Timer callback invoked on a single bufferevent with one or more exhausted + buckets when they are ready to refill. */ +static void +bev_refill_callback_(evutil_socket_t fd, short what, void *arg) +{ + unsigned tick; + struct timeval now; + struct bufferevent_private *bev = arg; + int again = 0; + BEV_LOCK(&bev->bev); + if (!bev->rate_limiting || !bev->rate_limiting->cfg) { + BEV_UNLOCK(&bev->bev); + return; + } + + /* First, update the bucket */ + event_base_gettimeofday_cached(bev->bev.ev_base, &now); + tick = ev_token_bucket_get_tick_(&now, + bev->rate_limiting->cfg); + ev_token_bucket_update_(&bev->rate_limiting->limit, + bev->rate_limiting->cfg, + tick); + + /* Now unsuspend any read/write operations as appropriate. */ + if ((bev->read_suspended & BEV_SUSPEND_BW)) { + if (bev->rate_limiting->limit.read_limit > 0) + bufferevent_unsuspend_read_(&bev->bev, BEV_SUSPEND_BW); + else + again = 1; + } + if ((bev->write_suspended & BEV_SUSPEND_BW)) { + if (bev->rate_limiting->limit.write_limit > 0) + bufferevent_unsuspend_write_(&bev->bev, BEV_SUSPEND_BW); + else + again = 1; + } + if (again) { + /* One or more of the buckets may need another refill if they + started negative. + + XXXX if we need to be quiet for more ticks, we should + maybe figure out what timeout we really want. + */ + /* XXXX Handle event_add failure somehow */ + event_add(&bev->rate_limiting->refill_bucket_event, + &bev->rate_limiting->cfg->tick_timeout); + } + BEV_UNLOCK(&bev->bev); +} + +/** Helper: grab a random element from a bufferevent group. + * + * Requires that we hold the lock on the group. + */ +static struct bufferevent_private * +bev_group_random_element_(struct bufferevent_rate_limit_group *group) +{ + int which; + struct bufferevent_private *bev; + + /* requires group lock */ + + if (!group->n_members) + return NULL; + + EVUTIL_ASSERT(! LIST_EMPTY(&group->members)); + + which = evutil_weakrand_range_(&group->weakrand_seed, group->n_members); + + bev = LIST_FIRST(&group->members); + while (which--) + bev = LIST_NEXT(bev, rate_limiting->next_in_group); + + return bev; +} + +/** Iterate over the elements of a rate-limiting group 'g' with a random + starting point, assigning each to the variable 'bev', and executing the + block 'block'. + + We do this in a half-baked effort to get fairness among group members. + XXX Round-robin or some kind of priority queue would be even more fair. + */ +#define FOREACH_RANDOM_ORDER(block) \ + do { \ + first = bev_group_random_element_(g); \ + for (bev = first; bev != LIST_END(&g->members); \ + bev = LIST_NEXT(bev, rate_limiting->next_in_group)) { \ + block ; \ + } \ + for (bev = LIST_FIRST(&g->members); bev && bev != first; \ + bev = LIST_NEXT(bev, rate_limiting->next_in_group)) { \ + block ; \ + } \ + } while (0) + +static void +bev_group_unsuspend_reading_(struct bufferevent_rate_limit_group *g) +{ + int again = 0; + struct bufferevent_private *bev, *first; + + g->read_suspended = 0; + FOREACH_RANDOM_ORDER({ + if (EVLOCK_TRY_LOCK_(bev->lock)) { + bufferevent_unsuspend_read_(&bev->bev, + BEV_SUSPEND_BW_GROUP); + EVLOCK_UNLOCK(bev->lock, 0); + } else { + again = 1; + } + }); + g->pending_unsuspend_read = again; +} + +static void +bev_group_unsuspend_writing_(struct bufferevent_rate_limit_group *g) +{ + int again = 0; + struct bufferevent_private *bev, *first; + g->write_suspended = 0; + + FOREACH_RANDOM_ORDER({ + if (EVLOCK_TRY_LOCK_(bev->lock)) { + bufferevent_unsuspend_write_(&bev->bev, + BEV_SUSPEND_BW_GROUP); + EVLOCK_UNLOCK(bev->lock, 0); + } else { + again = 1; + } + }); + g->pending_unsuspend_write = again; +} + +/** Callback invoked every tick to add more elements to the group bucket + and unsuspend group members as needed. + */ +static void +bev_group_refill_callback_(evutil_socket_t fd, short what, void *arg) +{ + struct bufferevent_rate_limit_group *g = arg; + unsigned tick; + struct timeval now; + + event_base_gettimeofday_cached(event_get_base(&g->master_refill_event), &now); + + LOCK_GROUP(g); + + tick = ev_token_bucket_get_tick_(&now, &g->rate_limit_cfg); + ev_token_bucket_update_(&g->rate_limit, &g->rate_limit_cfg, tick); + + if (g->pending_unsuspend_read || + (g->read_suspended && (g->rate_limit.read_limit >= g->min_share))) { + bev_group_unsuspend_reading_(g); + } + if (g->pending_unsuspend_write || + (g->write_suspended && (g->rate_limit.write_limit >= g->min_share))){ + bev_group_unsuspend_writing_(g); + } + + /* XXXX Rather than waiting to the next tick to unsuspend stuff + * with pending_unsuspend_write/read, we should do it on the + * next iteration of the mainloop. + */ + + UNLOCK_GROUP(g); +} + +int +bufferevent_set_rate_limit(struct bufferevent *bev, + struct ev_token_bucket_cfg *cfg) +{ + struct bufferevent_private *bevp = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + int r = -1; + struct bufferevent_rate_limit *rlim; + struct timeval now; + ev_uint32_t tick; + int reinit = 0, suspended = 0; + /* XXX reference-count cfg */ + + BEV_LOCK(bev); + + if (cfg == NULL) { + if (bevp->rate_limiting) { + rlim = bevp->rate_limiting; + rlim->cfg = NULL; + bufferevent_unsuspend_read_(bev, BEV_SUSPEND_BW); + bufferevent_unsuspend_write_(bev, BEV_SUSPEND_BW); + if (event_initialized(&rlim->refill_bucket_event)) + event_del(&rlim->refill_bucket_event); + } + r = 0; + goto done; + } + + event_base_gettimeofday_cached(bev->ev_base, &now); + tick = ev_token_bucket_get_tick_(&now, cfg); + + if (bevp->rate_limiting && bevp->rate_limiting->cfg == cfg) { + /* no-op */ + r = 0; + goto done; + } + if (bevp->rate_limiting == NULL) { + rlim = mm_calloc(1, sizeof(struct bufferevent_rate_limit)); + if (!rlim) + goto done; + bevp->rate_limiting = rlim; + } else { + rlim = bevp->rate_limiting; + } + reinit = rlim->cfg != NULL; + + rlim->cfg = cfg; + ev_token_bucket_init_(&rlim->limit, cfg, tick, reinit); + + if (reinit) { + EVUTIL_ASSERT(event_initialized(&rlim->refill_bucket_event)); + event_del(&rlim->refill_bucket_event); + } + event_assign(&rlim->refill_bucket_event, bev->ev_base, + -1, EV_FINALIZE, bev_refill_callback_, bevp); + + if (rlim->limit.read_limit > 0) { + bufferevent_unsuspend_read_(bev, BEV_SUSPEND_BW); + } else { + bufferevent_suspend_read_(bev, BEV_SUSPEND_BW); + suspended=1; + } + if (rlim->limit.write_limit > 0) { + bufferevent_unsuspend_write_(bev, BEV_SUSPEND_BW); + } else { + bufferevent_suspend_write_(bev, BEV_SUSPEND_BW); + suspended = 1; + } + + if (suspended) + event_add(&rlim->refill_bucket_event, &cfg->tick_timeout); + + r = 0; + +done: + BEV_UNLOCK(bev); + return r; +} + +struct bufferevent_rate_limit_group * +bufferevent_rate_limit_group_new(struct event_base *base, + const struct ev_token_bucket_cfg *cfg) +{ + struct bufferevent_rate_limit_group *g; + struct timeval now; + ev_uint32_t tick; + + event_base_gettimeofday_cached(base, &now); + tick = ev_token_bucket_get_tick_(&now, cfg); + + g = mm_calloc(1, sizeof(struct bufferevent_rate_limit_group)); + if (!g) + return NULL; + memcpy(&g->rate_limit_cfg, cfg, sizeof(g->rate_limit_cfg)); + LIST_INIT(&g->members); + + ev_token_bucket_init_(&g->rate_limit, cfg, tick, 0); + + event_assign(&g->master_refill_event, base, -1, EV_PERSIST|EV_FINALIZE, + bev_group_refill_callback_, g); + /*XXXX handle event_add failure */ + event_add(&g->master_refill_event, &cfg->tick_timeout); + + EVTHREAD_ALLOC_LOCK(g->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + + bufferevent_rate_limit_group_set_min_share(g, 64); + + evutil_weakrand_seed_(&g->weakrand_seed, + (ev_uint32_t) ((now.tv_sec + now.tv_usec) + (ev_intptr_t)g)); + + return g; +} + +int +bufferevent_rate_limit_group_set_cfg( + struct bufferevent_rate_limit_group *g, + const struct ev_token_bucket_cfg *cfg) +{ + int same_tick; + if (!g || !cfg) + return -1; + + LOCK_GROUP(g); + same_tick = evutil_timercmp( + &g->rate_limit_cfg.tick_timeout, &cfg->tick_timeout, ==); + memcpy(&g->rate_limit_cfg, cfg, sizeof(g->rate_limit_cfg)); + + if (g->rate_limit.read_limit > (ev_ssize_t)cfg->read_maximum) + g->rate_limit.read_limit = cfg->read_maximum; + if (g->rate_limit.write_limit > (ev_ssize_t)cfg->write_maximum) + g->rate_limit.write_limit = cfg->write_maximum; + + if (!same_tick) { + /* This can cause a hiccup in the schedule */ + event_add(&g->master_refill_event, &cfg->tick_timeout); + } + + /* The new limits might force us to adjust min_share differently. */ + bufferevent_rate_limit_group_set_min_share(g, g->configured_min_share); + + UNLOCK_GROUP(g); + return 0; +} + +int +bufferevent_rate_limit_group_set_min_share( + struct bufferevent_rate_limit_group *g, + size_t share) +{ + if (share > EV_SSIZE_MAX) + return -1; + + g->configured_min_share = share; + + /* Can't set share to less than the one-tick maximum. IOW, at steady + * state, at least one connection can go per tick. */ + if (share > g->rate_limit_cfg.read_rate) + share = g->rate_limit_cfg.read_rate; + if (share > g->rate_limit_cfg.write_rate) + share = g->rate_limit_cfg.write_rate; + + g->min_share = share; + return 0; +} + +void +bufferevent_rate_limit_group_free(struct bufferevent_rate_limit_group *g) +{ + LOCK_GROUP(g); + EVUTIL_ASSERT(0 == g->n_members); + event_del(&g->master_refill_event); + UNLOCK_GROUP(g); + EVTHREAD_FREE_LOCK(g->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + mm_free(g); +} + +int +bufferevent_add_to_rate_limit_group(struct bufferevent *bev, + struct bufferevent_rate_limit_group *g) +{ + int wsuspend, rsuspend; + struct bufferevent_private *bevp = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + BEV_LOCK(bev); + + if (!bevp->rate_limiting) { + struct bufferevent_rate_limit *rlim; + rlim = mm_calloc(1, sizeof(struct bufferevent_rate_limit)); + if (!rlim) { + BEV_UNLOCK(bev); + return -1; + } + event_assign(&rlim->refill_bucket_event, bev->ev_base, + -1, EV_FINALIZE, bev_refill_callback_, bevp); + bevp->rate_limiting = rlim; + } + + if (bevp->rate_limiting->group == g) { + BEV_UNLOCK(bev); + return 0; + } + if (bevp->rate_limiting->group) + bufferevent_remove_from_rate_limit_group(bev); + + LOCK_GROUP(g); + bevp->rate_limiting->group = g; + ++g->n_members; + LIST_INSERT_HEAD(&g->members, bevp, rate_limiting->next_in_group); + + rsuspend = g->read_suspended; + wsuspend = g->write_suspended; + + UNLOCK_GROUP(g); + + if (rsuspend) + bufferevent_suspend_read_(bev, BEV_SUSPEND_BW_GROUP); + if (wsuspend) + bufferevent_suspend_write_(bev, BEV_SUSPEND_BW_GROUP); + + BEV_UNLOCK(bev); + return 0; +} + +int +bufferevent_remove_from_rate_limit_group(struct bufferevent *bev) +{ + return bufferevent_remove_from_rate_limit_group_internal_(bev, 1); +} + +int +bufferevent_remove_from_rate_limit_group_internal_(struct bufferevent *bev, + int unsuspend) +{ + struct bufferevent_private *bevp = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + BEV_LOCK(bev); + if (bevp->rate_limiting && bevp->rate_limiting->group) { + struct bufferevent_rate_limit_group *g = + bevp->rate_limiting->group; + LOCK_GROUP(g); + bevp->rate_limiting->group = NULL; + --g->n_members; + LIST_REMOVE(bevp, rate_limiting->next_in_group); + UNLOCK_GROUP(g); + } + if (unsuspend) { + bufferevent_unsuspend_read_(bev, BEV_SUSPEND_BW_GROUP); + bufferevent_unsuspend_write_(bev, BEV_SUSPEND_BW_GROUP); + } + BEV_UNLOCK(bev); + return 0; +} + +/* === + * API functions to expose rate limits. + * + * Don't use these from inside Libevent; they're meant to be for use by + * the program. + * === */ + +/* Mostly you don't want to use this function from inside libevent; + * bufferevent_get_read_max_() is more likely what you want*/ +ev_ssize_t +bufferevent_get_read_limit(struct bufferevent *bev) +{ + ev_ssize_t r; + struct bufferevent_private *bevp; + BEV_LOCK(bev); + bevp = BEV_UPCAST(bev); + if (bevp->rate_limiting && bevp->rate_limiting->cfg) { + bufferevent_update_buckets(bevp); + r = bevp->rate_limiting->limit.read_limit; + } else { + r = EV_SSIZE_MAX; + } + BEV_UNLOCK(bev); + return r; +} + +/* Mostly you don't want to use this function from inside libevent; + * bufferevent_get_write_max_() is more likely what you want*/ +ev_ssize_t +bufferevent_get_write_limit(struct bufferevent *bev) +{ + ev_ssize_t r; + struct bufferevent_private *bevp; + BEV_LOCK(bev); + bevp = BEV_UPCAST(bev); + if (bevp->rate_limiting && bevp->rate_limiting->cfg) { + bufferevent_update_buckets(bevp); + r = bevp->rate_limiting->limit.write_limit; + } else { + r = EV_SSIZE_MAX; + } + BEV_UNLOCK(bev); + return r; +} + +int +bufferevent_set_max_single_read(struct bufferevent *bev, size_t size) +{ + struct bufferevent_private *bevp; + BEV_LOCK(bev); + bevp = BEV_UPCAST(bev); + if (size == 0 || size > EV_SSIZE_MAX) + bevp->max_single_read = MAX_SINGLE_READ_DEFAULT; + else + bevp->max_single_read = size; + BEV_UNLOCK(bev); + return 0; +} + +int +bufferevent_set_max_single_write(struct bufferevent *bev, size_t size) +{ + struct bufferevent_private *bevp; + BEV_LOCK(bev); + bevp = BEV_UPCAST(bev); + if (size == 0 || size > EV_SSIZE_MAX) + bevp->max_single_write = MAX_SINGLE_WRITE_DEFAULT; + else + bevp->max_single_write = size; + BEV_UNLOCK(bev); + return 0; +} + +ev_ssize_t +bufferevent_get_max_single_read(struct bufferevent *bev) +{ + ev_ssize_t r; + + BEV_LOCK(bev); + r = BEV_UPCAST(bev)->max_single_read; + BEV_UNLOCK(bev); + return r; +} + +ev_ssize_t +bufferevent_get_max_single_write(struct bufferevent *bev) +{ + ev_ssize_t r; + + BEV_LOCK(bev); + r = BEV_UPCAST(bev)->max_single_write; + BEV_UNLOCK(bev); + return r; +} + +ev_ssize_t +bufferevent_get_max_to_read(struct bufferevent *bev) +{ + ev_ssize_t r; + BEV_LOCK(bev); + r = bufferevent_get_read_max_(BEV_UPCAST(bev)); + BEV_UNLOCK(bev); + return r; +} + +ev_ssize_t +bufferevent_get_max_to_write(struct bufferevent *bev) +{ + ev_ssize_t r; + BEV_LOCK(bev); + r = bufferevent_get_write_max_(BEV_UPCAST(bev)); + BEV_UNLOCK(bev); + return r; +} + +const struct ev_token_bucket_cfg * +bufferevent_get_token_bucket_cfg(const struct bufferevent *bev) { + struct bufferevent_private *bufev_private = BEV_UPCAST(bev); + struct ev_token_bucket_cfg *cfg; + + BEV_LOCK(bev); + + if (bufev_private->rate_limiting) { + cfg = bufev_private->rate_limiting->cfg; + } else { + cfg = NULL; + } + + BEV_UNLOCK(bev); + + return cfg; +} + +/* Mostly you don't want to use this function from inside libevent; + * bufferevent_get_read_max_() is more likely what you want*/ +ev_ssize_t +bufferevent_rate_limit_group_get_read_limit( + struct bufferevent_rate_limit_group *grp) +{ + ev_ssize_t r; + LOCK_GROUP(grp); + r = grp->rate_limit.read_limit; + UNLOCK_GROUP(grp); + return r; +} + +/* Mostly you don't want to use this function from inside libevent; + * bufferevent_get_write_max_() is more likely what you want. */ +ev_ssize_t +bufferevent_rate_limit_group_get_write_limit( + struct bufferevent_rate_limit_group *grp) +{ + ev_ssize_t r; + LOCK_GROUP(grp); + r = grp->rate_limit.write_limit; + UNLOCK_GROUP(grp); + return r; +} + +int +bufferevent_decrement_read_limit(struct bufferevent *bev, ev_ssize_t decr) +{ + int r = 0; + ev_ssize_t old_limit, new_limit; + struct bufferevent_private *bevp; + BEV_LOCK(bev); + bevp = BEV_UPCAST(bev); + EVUTIL_ASSERT(bevp->rate_limiting && bevp->rate_limiting->cfg); + old_limit = bevp->rate_limiting->limit.read_limit; + + new_limit = (bevp->rate_limiting->limit.read_limit -= decr); + if (old_limit > 0 && new_limit <= 0) { + bufferevent_suspend_read_(bev, BEV_SUSPEND_BW); + if (event_add(&bevp->rate_limiting->refill_bucket_event, + &bevp->rate_limiting->cfg->tick_timeout) < 0) + r = -1; + } else if (old_limit <= 0 && new_limit > 0) { + if (!(bevp->write_suspended & BEV_SUSPEND_BW)) + event_del(&bevp->rate_limiting->refill_bucket_event); + bufferevent_unsuspend_read_(bev, BEV_SUSPEND_BW); + } + + BEV_UNLOCK(bev); + return r; +} + +int +bufferevent_decrement_write_limit(struct bufferevent *bev, ev_ssize_t decr) +{ + /* XXXX this is mostly copy-and-paste from + * bufferevent_decrement_read_limit */ + int r = 0; + ev_ssize_t old_limit, new_limit; + struct bufferevent_private *bevp; + BEV_LOCK(bev); + bevp = BEV_UPCAST(bev); + EVUTIL_ASSERT(bevp->rate_limiting && bevp->rate_limiting->cfg); + old_limit = bevp->rate_limiting->limit.write_limit; + + new_limit = (bevp->rate_limiting->limit.write_limit -= decr); + if (old_limit > 0 && new_limit <= 0) { + bufferevent_suspend_write_(bev, BEV_SUSPEND_BW); + if (event_add(&bevp->rate_limiting->refill_bucket_event, + &bevp->rate_limiting->cfg->tick_timeout) < 0) + r = -1; + } else if (old_limit <= 0 && new_limit > 0) { + if (!(bevp->read_suspended & BEV_SUSPEND_BW)) + event_del(&bevp->rate_limiting->refill_bucket_event); + bufferevent_unsuspend_write_(bev, BEV_SUSPEND_BW); + } + + BEV_UNLOCK(bev); + return r; +} + +int +bufferevent_rate_limit_group_decrement_read( + struct bufferevent_rate_limit_group *grp, ev_ssize_t decr) +{ + int r = 0; + ev_ssize_t old_limit, new_limit; + LOCK_GROUP(grp); + old_limit = grp->rate_limit.read_limit; + new_limit = (grp->rate_limit.read_limit -= decr); + + if (old_limit > 0 && new_limit <= 0) { + bev_group_suspend_reading_(grp); + } else if (old_limit <= 0 && new_limit > 0) { + bev_group_unsuspend_reading_(grp); + } + + UNLOCK_GROUP(grp); + return r; +} + +int +bufferevent_rate_limit_group_decrement_write( + struct bufferevent_rate_limit_group *grp, ev_ssize_t decr) +{ + int r = 0; + ev_ssize_t old_limit, new_limit; + LOCK_GROUP(grp); + old_limit = grp->rate_limit.write_limit; + new_limit = (grp->rate_limit.write_limit -= decr); + + if (old_limit > 0 && new_limit <= 0) { + bev_group_suspend_writing_(grp); + } else if (old_limit <= 0 && new_limit > 0) { + bev_group_unsuspend_writing_(grp); + } + + UNLOCK_GROUP(grp); + return r; +} + +void +bufferevent_rate_limit_group_get_totals(struct bufferevent_rate_limit_group *grp, + ev_uint64_t *total_read_out, ev_uint64_t *total_written_out) +{ + EVUTIL_ASSERT(grp != NULL); + if (total_read_out) + *total_read_out = grp->total_read; + if (total_written_out) + *total_written_out = grp->total_written; +} + +void +bufferevent_rate_limit_group_reset_totals(struct bufferevent_rate_limit_group *grp) +{ + grp->total_read = grp->total_written = 0; +} + +int +bufferevent_ratelim_init_(struct bufferevent_private *bev) +{ + bev->rate_limiting = NULL; + bev->max_single_read = MAX_SINGLE_READ_DEFAULT; + bev->max_single_write = MAX_SINGLE_WRITE_DEFAULT; + + return 0; +} diff --git a/contrib/ntp/sntp/libevent/bufferevent_sock.c b/contrib/ntp/sntp/libevent/bufferevent_sock.c new file mode 100644 index 000000000..49ebc0bef --- /dev/null +++ b/contrib/ntp/sntp/libevent/bufferevent_sock.c @@ -0,0 +1,709 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * Copyright (c) 2002-2006 Niels Provos + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#include +#include +#include +#include +#ifdef EVENT__HAVE_STDARG_H +#include +#endif +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif + +#ifdef _WIN32 +#include +#include +#endif + +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif +#ifdef EVENT__HAVE_NETINET_IN_H +#include +#endif +#ifdef EVENT__HAVE_NETINET_IN6_H +#include +#endif + +#include "event2/util.h" +#include "event2/bufferevent.h" +#include "event2/buffer.h" +#include "event2/bufferevent_struct.h" +#include "event2/bufferevent_compat.h" +#include "event2/event.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "bufferevent-internal.h" +#include "util-internal.h" +#ifdef _WIN32 +#include "iocp-internal.h" +#endif + +/* prototypes */ +static int be_socket_enable(struct bufferevent *, short); +static int be_socket_disable(struct bufferevent *, short); +static void be_socket_destruct(struct bufferevent *); +static int be_socket_adj_timeouts(struct bufferevent *); +static int be_socket_flush(struct bufferevent *, short, enum bufferevent_flush_mode); +static int be_socket_ctrl(struct bufferevent *, enum bufferevent_ctrl_op, union bufferevent_ctrl_data *); + +static void be_socket_setfd(struct bufferevent *, evutil_socket_t); + +const struct bufferevent_ops bufferevent_ops_socket = { + "socket", + evutil_offsetof(struct bufferevent_private, bev), + be_socket_enable, + be_socket_disable, + NULL, /* unlink */ + be_socket_destruct, + be_socket_adj_timeouts, + be_socket_flush, + be_socket_ctrl, +}; + +#define be_socket_add(ev, t) \ + bufferevent_add_event_((ev), (t)) + +static void +bufferevent_socket_outbuf_cb(struct evbuffer *buf, + const struct evbuffer_cb_info *cbinfo, + void *arg) +{ + struct bufferevent *bufev = arg; + struct bufferevent_private *bufev_p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + + if (cbinfo->n_added && + (bufev->enabled & EV_WRITE) && + !event_pending(&bufev->ev_write, EV_WRITE, NULL) && + !bufev_p->write_suspended) { + /* Somebody added data to the buffer, and we would like to + * write, and we were not writing. So, start writing. */ + if (be_socket_add(&bufev->ev_write, &bufev->timeout_write) == -1) { + /* Should we log this? */ + } + } +} + +static void +bufferevent_readcb(evutil_socket_t fd, short event, void *arg) +{ + struct bufferevent *bufev = arg; + struct bufferevent_private *bufev_p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + struct evbuffer *input; + int res = 0; + short what = BEV_EVENT_READING; + ev_ssize_t howmuch = -1, readmax=-1; + + bufferevent_incref_and_lock_(bufev); + + if (event == EV_TIMEOUT) { + /* Note that we only check for event==EV_TIMEOUT. If + * event==EV_TIMEOUT|EV_READ, we can safely ignore the + * timeout, since a read has occurred */ + what |= BEV_EVENT_TIMEOUT; + goto error; + } + + input = bufev->input; + + /* + * If we have a high watermark configured then we don't want to + * read more data than would make us reach the watermark. + */ + if (bufev->wm_read.high != 0) { + howmuch = bufev->wm_read.high - evbuffer_get_length(input); + /* we somehow lowered the watermark, stop reading */ + if (howmuch <= 0) { + bufferevent_wm_suspend_read(bufev); + goto done; + } + } + readmax = bufferevent_get_read_max_(bufev_p); + if (howmuch < 0 || howmuch > readmax) /* The use of -1 for "unlimited" + * uglifies this code. XXXX */ + howmuch = readmax; + if (bufev_p->read_suspended) + goto done; + + evbuffer_unfreeze(input, 0); + res = evbuffer_read(input, fd, (int)howmuch); /* XXXX evbuffer_read would do better to take and return ev_ssize_t */ + evbuffer_freeze(input, 0); + + if (res == -1) { + int err = evutil_socket_geterror(fd); + if (EVUTIL_ERR_RW_RETRIABLE(err)) + goto reschedule; + /* error case */ + what |= BEV_EVENT_ERROR; + } else if (res == 0) { + /* eof case */ + what |= BEV_EVENT_EOF; + } + + if (res <= 0) + goto error; + + bufferevent_decrement_read_buckets_(bufev_p, res); + + /* Invoke the user callback - must always be called last */ + bufferevent_trigger_nolock_(bufev, EV_READ, 0); + + goto done; + + reschedule: + goto done; + + error: + bufferevent_disable(bufev, EV_READ); + bufferevent_run_eventcb_(bufev, what, 0); + + done: + bufferevent_decref_and_unlock_(bufev); +} + +static void +bufferevent_writecb(evutil_socket_t fd, short event, void *arg) +{ + struct bufferevent *bufev = arg; + struct bufferevent_private *bufev_p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + int res = 0; + short what = BEV_EVENT_WRITING; + int connected = 0; + ev_ssize_t atmost = -1; + + bufferevent_incref_and_lock_(bufev); + + if (event == EV_TIMEOUT) { + /* Note that we only check for event==EV_TIMEOUT. If + * event==EV_TIMEOUT|EV_WRITE, we can safely ignore the + * timeout, since a read has occurred */ + what |= BEV_EVENT_TIMEOUT; + goto error; + } + if (bufev_p->connecting) { + int c = evutil_socket_finished_connecting_(fd); + /* we need to fake the error if the connection was refused + * immediately - usually connection to localhost on BSD */ + if (bufev_p->connection_refused) { + bufev_p->connection_refused = 0; + c = -1; + } + + if (c == 0) + goto done; + + bufev_p->connecting = 0; + if (c < 0) { + event_del(&bufev->ev_write); + event_del(&bufev->ev_read); + bufferevent_run_eventcb_(bufev, BEV_EVENT_ERROR, 0); + goto done; + } else { + connected = 1; +#ifdef _WIN32 + if (BEV_IS_ASYNC(bufev)) { + event_del(&bufev->ev_write); + bufferevent_async_set_connected_(bufev); + bufferevent_run_eventcb_(bufev, + BEV_EVENT_CONNECTED, 0); + goto done; + } +#endif + bufferevent_run_eventcb_(bufev, + BEV_EVENT_CONNECTED, 0); + if (!(bufev->enabled & EV_WRITE) || + bufev_p->write_suspended) { + event_del(&bufev->ev_write); + goto done; + } + } + } + + atmost = bufferevent_get_write_max_(bufev_p); + + if (bufev_p->write_suspended) + goto done; + + if (evbuffer_get_length(bufev->output)) { + evbuffer_unfreeze(bufev->output, 1); + res = evbuffer_write_atmost(bufev->output, fd, atmost); + evbuffer_freeze(bufev->output, 1); + if (res == -1) { + int err = evutil_socket_geterror(fd); + if (EVUTIL_ERR_RW_RETRIABLE(err)) + goto reschedule; + what |= BEV_EVENT_ERROR; + } else if (res == 0) { + /* eof case + XXXX Actually, a 0 on write doesn't indicate + an EOF. An ECONNRESET might be more typical. + */ + what |= BEV_EVENT_EOF; + } + if (res <= 0) + goto error; + + bufferevent_decrement_write_buckets_(bufev_p, res); + } + + if (evbuffer_get_length(bufev->output) == 0) { + event_del(&bufev->ev_write); + } + + /* + * Invoke the user callback if our buffer is drained or below the + * low watermark. + */ + if (res || !connected) { + bufferevent_trigger_nolock_(bufev, EV_WRITE, 0); + } + + goto done; + + reschedule: + if (evbuffer_get_length(bufev->output) == 0) { + event_del(&bufev->ev_write); + } + goto done; + + error: + bufferevent_disable(bufev, EV_WRITE); + bufferevent_run_eventcb_(bufev, what, 0); + + done: + bufferevent_decref_and_unlock_(bufev); +} + +struct bufferevent * +bufferevent_socket_new(struct event_base *base, evutil_socket_t fd, + int options) +{ + struct bufferevent_private *bufev_p; + struct bufferevent *bufev; + +#ifdef _WIN32 + if (base && event_base_get_iocp_(base)) + return bufferevent_async_new_(base, fd, options); +#endif + + if ((bufev_p = mm_calloc(1, sizeof(struct bufferevent_private)))== NULL) + return NULL; + + if (bufferevent_init_common_(bufev_p, base, &bufferevent_ops_socket, + options) < 0) { + mm_free(bufev_p); + return NULL; + } + bufev = &bufev_p->bev; + evbuffer_set_flags(bufev->output, EVBUFFER_FLAG_DRAINS_TO_FD); + + event_assign(&bufev->ev_read, bufev->ev_base, fd, + EV_READ|EV_PERSIST|EV_FINALIZE, bufferevent_readcb, bufev); + event_assign(&bufev->ev_write, bufev->ev_base, fd, + EV_WRITE|EV_PERSIST|EV_FINALIZE, bufferevent_writecb, bufev); + + evbuffer_add_cb(bufev->output, bufferevent_socket_outbuf_cb, bufev); + + evbuffer_freeze(bufev->input, 0); + evbuffer_freeze(bufev->output, 1); + + return bufev; +} + +int +bufferevent_socket_connect(struct bufferevent *bev, + struct sockaddr *sa, int socklen) +{ + struct bufferevent_private *bufev_p = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + + evutil_socket_t fd; + int r = 0; + int result=-1; + int ownfd = 0; + + bufferevent_incref_and_lock_(bev); + + if (!bufev_p) + goto done; + + fd = bufferevent_getfd(bev); + if (fd < 0) { + if (!sa) + goto done; + fd = evutil_socket_(sa->sa_family, + SOCK_STREAM|EVUTIL_SOCK_NONBLOCK, 0); + if (fd < 0) + goto done; + ownfd = 1; + } + if (sa) { +#ifdef _WIN32 + if (bufferevent_async_can_connect_(bev)) { + bufferevent_setfd(bev, fd); + r = bufferevent_async_connect_(bev, fd, sa, socklen); + if (r < 0) + goto freesock; + bufev_p->connecting = 1; + result = 0; + goto done; + } else +#endif + r = evutil_socket_connect_(&fd, sa, socklen); + if (r < 0) + goto freesock; + } +#ifdef _WIN32 + /* ConnectEx() isn't always around, even when IOCP is enabled. + * Here, we borrow the socket object's write handler to fall back + * on a non-blocking connect() when ConnectEx() is unavailable. */ + if (BEV_IS_ASYNC(bev)) { + event_assign(&bev->ev_write, bev->ev_base, fd, + EV_WRITE|EV_PERSIST|EV_FINALIZE, bufferevent_writecb, bev); + } +#endif + bufferevent_setfd(bev, fd); + if (r == 0) { + if (! be_socket_enable(bev, EV_WRITE)) { + bufev_p->connecting = 1; + result = 0; + goto done; + } + } else if (r == 1) { + /* The connect succeeded already. How very BSD of it. */ + result = 0; + bufev_p->connecting = 1; + event_active(&bev->ev_write, EV_WRITE, 1); + } else { + /* The connect failed already. How very BSD of it. */ + bufev_p->connection_refused = 1; + bufev_p->connecting = 1; + result = 0; + event_active(&bev->ev_write, EV_WRITE, 1); + } + + goto done; + +freesock: + bufferevent_run_eventcb_(bev, BEV_EVENT_ERROR, 0); + if (ownfd) + evutil_closesocket(fd); + /* do something about the error? */ +done: + bufferevent_decref_and_unlock_(bev); + return result; +} + +static void +bufferevent_connect_getaddrinfo_cb(int result, struct evutil_addrinfo *ai, + void *arg) +{ + struct bufferevent *bev = arg; + struct bufferevent_private *bev_p = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + int r; + BEV_LOCK(bev); + + bufferevent_unsuspend_write_(bev, BEV_SUSPEND_LOOKUP); + bufferevent_unsuspend_read_(bev, BEV_SUSPEND_LOOKUP); + + if (result != 0) { + bev_p->dns_error = result; + bufferevent_run_eventcb_(bev, BEV_EVENT_ERROR, 0); + bufferevent_decref_and_unlock_(bev); + if (ai) + evutil_freeaddrinfo(ai); + return; + } + + /* XXX use the other addrinfos? */ + /* XXX use this return value */ + r = bufferevent_socket_connect(bev, ai->ai_addr, (int)ai->ai_addrlen); + (void)r; + bufferevent_decref_and_unlock_(bev); + evutil_freeaddrinfo(ai); +} + +int +bufferevent_socket_connect_hostname(struct bufferevent *bev, + struct evdns_base *evdns_base, int family, const char *hostname, int port) +{ + char portbuf[10]; + struct evutil_addrinfo hint; + int err; + struct bufferevent_private *bev_p = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + + if (family != AF_INET && family != AF_INET6 && family != AF_UNSPEC) + return -1; + if (port < 1 || port > 65535) + return -1; + + BEV_LOCK(bev); + bev_p->dns_error = 0; + BEV_UNLOCK(bev); + + evutil_snprintf(portbuf, sizeof(portbuf), "%d", port); + + memset(&hint, 0, sizeof(hint)); + hint.ai_family = family; + hint.ai_protocol = IPPROTO_TCP; + hint.ai_socktype = SOCK_STREAM; + + bufferevent_suspend_write_(bev, BEV_SUSPEND_LOOKUP); + bufferevent_suspend_read_(bev, BEV_SUSPEND_LOOKUP); + + bufferevent_incref_(bev); + err = evutil_getaddrinfo_async_(evdns_base, hostname, portbuf, + &hint, bufferevent_connect_getaddrinfo_cb, bev); + + if (err == 0) { + return 0; + } else { + bufferevent_unsuspend_write_(bev, BEV_SUSPEND_LOOKUP); + bufferevent_unsuspend_read_(bev, BEV_SUSPEND_LOOKUP); + bufferevent_decref_(bev); + return -1; + } +} + +int +bufferevent_socket_get_dns_error(struct bufferevent *bev) +{ + int rv; + struct bufferevent_private *bev_p = + EVUTIL_UPCAST(bev, struct bufferevent_private, bev); + + BEV_LOCK(bev); + rv = bev_p->dns_error; + BEV_UNLOCK(bev); + + return rv; +} + +/* + * Create a new buffered event object. + * + * The read callback is invoked whenever we read new data. + * The write callback is invoked whenever the output buffer is drained. + * The error callback is invoked on a write/read error or on EOF. + * + * Both read and write callbacks maybe NULL. The error callback is not + * allowed to be NULL and have to be provided always. + */ + +struct bufferevent * +bufferevent_new(evutil_socket_t fd, + bufferevent_data_cb readcb, bufferevent_data_cb writecb, + bufferevent_event_cb eventcb, void *cbarg) +{ + struct bufferevent *bufev; + + if (!(bufev = bufferevent_socket_new(NULL, fd, 0))) + return NULL; + + bufferevent_setcb(bufev, readcb, writecb, eventcb, cbarg); + + return bufev; +} + + +static int +be_socket_enable(struct bufferevent *bufev, short event) +{ + if (event & EV_READ) { + if (be_socket_add(&bufev->ev_read,&bufev->timeout_read) == -1) + return -1; + } + if (event & EV_WRITE) { + if (be_socket_add(&bufev->ev_write,&bufev->timeout_write) == -1) + return -1; + } + return 0; +} + +static int +be_socket_disable(struct bufferevent *bufev, short event) +{ + struct bufferevent_private *bufev_p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + if (event & EV_READ) { + if (event_del(&bufev->ev_read) == -1) + return -1; + } + /* Don't actually disable the write if we are trying to connect. */ + if ((event & EV_WRITE) && ! bufev_p->connecting) { + if (event_del(&bufev->ev_write) == -1) + return -1; + } + return 0; +} + +static void +be_socket_destruct(struct bufferevent *bufev) +{ + struct bufferevent_private *bufev_p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + evutil_socket_t fd; + EVUTIL_ASSERT(bufev->be_ops == &bufferevent_ops_socket); + + fd = event_get_fd(&bufev->ev_read); + + if ((bufev_p->options & BEV_OPT_CLOSE_ON_FREE) && fd >= 0) + EVUTIL_CLOSESOCKET(fd); +} + +static int +be_socket_adj_timeouts(struct bufferevent *bufev) +{ + int r = 0; + if (event_pending(&bufev->ev_read, EV_READ, NULL)) { + if (evutil_timerisset(&bufev->timeout_read)) { + if (be_socket_add(&bufev->ev_read, &bufev->timeout_read) < 0) + r = -1; + } else { + event_remove_timer(&bufev->ev_read); + } + } + if (event_pending(&bufev->ev_write, EV_WRITE, NULL)) { + if (evutil_timerisset(&bufev->timeout_write)) { + if (be_socket_add(&bufev->ev_write, &bufev->timeout_write) < 0) + r = -1; + } else { + event_remove_timer(&bufev->ev_write); + } + } + return r; +} + +static int +be_socket_flush(struct bufferevent *bev, short iotype, + enum bufferevent_flush_mode mode) +{ + return 0; +} + + +static void +be_socket_setfd(struct bufferevent *bufev, evutil_socket_t fd) +{ + BEV_LOCK(bufev); + EVUTIL_ASSERT(bufev->be_ops == &bufferevent_ops_socket); + + event_del(&bufev->ev_read); + event_del(&bufev->ev_write); + + event_assign(&bufev->ev_read, bufev->ev_base, fd, + EV_READ|EV_PERSIST|EV_FINALIZE, bufferevent_readcb, bufev); + event_assign(&bufev->ev_write, bufev->ev_base, fd, + EV_WRITE|EV_PERSIST|EV_FINALIZE, bufferevent_writecb, bufev); + + if (fd >= 0) + bufferevent_enable(bufev, bufev->enabled); + + BEV_UNLOCK(bufev); +} + +/* XXXX Should non-socket bufferevents support this? */ +int +bufferevent_priority_set(struct bufferevent *bufev, int priority) +{ + int r = -1; + struct bufferevent_private *bufev_p = + EVUTIL_UPCAST(bufev, struct bufferevent_private, bev); + + BEV_LOCK(bufev); + if (bufev->be_ops != &bufferevent_ops_socket) + goto done; + + if (event_priority_set(&bufev->ev_read, priority) == -1) + goto done; + if (event_priority_set(&bufev->ev_write, priority) == -1) + goto done; + + event_deferred_cb_set_priority_(&bufev_p->deferred, priority); + + r = 0; +done: + BEV_UNLOCK(bufev); + return r; +} + +/* XXXX Should non-socket bufferevents support this? */ +int +bufferevent_base_set(struct event_base *base, struct bufferevent *bufev) +{ + int res = -1; + + BEV_LOCK(bufev); + if (bufev->be_ops != &bufferevent_ops_socket) + goto done; + + bufev->ev_base = base; + + res = event_base_set(base, &bufev->ev_read); + if (res == -1) + goto done; + + res = event_base_set(base, &bufev->ev_write); +done: + BEV_UNLOCK(bufev); + return res; +} + +static int +be_socket_ctrl(struct bufferevent *bev, enum bufferevent_ctrl_op op, + union bufferevent_ctrl_data *data) +{ + switch (op) { + case BEV_CTRL_SET_FD: + be_socket_setfd(bev, data->fd); + return 0; + case BEV_CTRL_GET_FD: + data->fd = event_get_fd(&bev->ev_read); + return 0; + case BEV_CTRL_GET_UNDERLYING: + case BEV_CTRL_CANCEL_ALL: + default: + return -1; + } +} diff --git a/contrib/ntp/sntp/libevent/build-aux/ar-lib b/contrib/ntp/sntp/libevent/build-aux/ar-lib new file mode 100755 index 000000000..463b9ec02 --- /dev/null +++ b/contrib/ntp/sntp/libevent/build-aux/ar-lib @@ -0,0 +1,270 @@ +#! /bin/sh +# Wrapper for Microsoft lib.exe + +me=ar-lib +scriptversion=2012-03-01.08; # UTC + +# Copyright (C) 2010-2014 Free Software Foundation, Inc. +# Written by Peter Rosin . +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to or send patches to +# . + + +# func_error message +func_error () +{ + echo "$me: $1" 1>&2 + exit 1 +} + +file_conv= + +# func_file_conv build_file +# Convert a $build file to $host form and store it in $file +# Currently only supports Windows hosts. +func_file_conv () +{ + file=$1 + case $file in + / | /[!/]*) # absolute file, and not a UNC file + if test -z "$file_conv"; then + # lazily determine how to convert abs files + case `uname -s` in + MINGW*) + file_conv=mingw + ;; + CYGWIN*) + file_conv=cygwin + ;; + *) + file_conv=wine + ;; + esac + fi + case $file_conv in + mingw) + file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` + ;; + cygwin) + file=`cygpath -m "$file" || echo "$file"` + ;; + wine) + file=`winepath -w "$file" || echo "$file"` + ;; + esac + ;; + esac +} + +# func_at_file at_file operation archive +# Iterate over all members in AT_FILE performing OPERATION on ARCHIVE +# for each of them. +# When interpreting the content of the @FILE, do NOT use func_file_conv, +# since the user would need to supply preconverted file names to +# binutils ar, at least for MinGW. +func_at_file () +{ + operation=$2 + archive=$3 + at_file_contents=`cat "$1"` + eval set x "$at_file_contents" + shift + + for member + do + $AR -NOLOGO $operation:"$member" "$archive" || exit $? + done +} + +case $1 in + '') + func_error "no command. Try '$0 --help' for more information." + ;; + -h | --h*) + cat <. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to or send patches to +# . + +case $1 in + '') + echo "$0: No command. Try \`$0 --help' for more information." 1>&2 + exit 1; + ;; + -h | --h*) + cat <<\EOF +Usage: compile [--help] [--version] PROGRAM [ARGS] + +Wrapper for compilers which do not understand `-c -o'. +Remove `-o dest.o' from ARGS, run PROGRAM with the remaining +arguments, and rename the output as expected. + +If you are trying to build a whole package this is not the +right script to run: please start by reading the file `INSTALL'. + +Report bugs to . +EOF + exit $? + ;; + -v | --v*) + echo "compile $scriptversion" + exit $? + ;; +esac + +ofile= +cfile= +eat= + +for arg +do + if test -n "$eat"; then + eat= + else + case $1 in + -o) + # configure might choose to run compile as `compile cc -o foo foo.c'. + # So we strip `-o arg' only if arg is an object. + eat=1 + case $2 in + *.o | *.obj) + ofile=$2 + ;; + *) + set x "$@" -o "$2" + shift + ;; + esac + ;; + *.c) + cfile=$1 + set x "$@" "$1" + shift + ;; + *) + set x "$@" "$1" + shift + ;; + esac + fi + shift +done + +if test -z "$ofile" || test -z "$cfile"; then + # If no `-o' option was seen then we might have been invoked from a + # pattern rule where we don't need one. That is ok -- this is a + # normal compilation that the losing compiler can handle. If no + # `.c' file was seen then we are probably linking. That is also + # ok. + exec "$@" +fi + +# Name of file we expect compiler to create. +cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` + +# Create the lock directory. +# Note: use `[/\\:.-]' here to ensure that we don't use the same name +# that we are using for the .o file. Also, base the name on the expected +# object file name, since that is what matters with a parallel build. +lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d +while true; do + if mkdir "$lockdir" >/dev/null 2>&1; then + break + fi + sleep 1 +done +# FIXME: race condition here if user kills between mkdir and trap. +trap "rmdir '$lockdir'; exit 1" 1 2 15 + +# Run the compile. +"$@" +ret=$? + +if test -f "$cofile"; then + test "$cofile" = "$ofile" || mv "$cofile" "$ofile" +elif test -f "${cofile}bj"; then + test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" +fi + +rmdir "$lockdir" +exit $ret + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/contrib/ntp/sntp/libevent/build-aux/config.guess b/contrib/ntp/sntp/libevent/build-aux/config.guess new file mode 100755 index 000000000..b02565c7b --- /dev/null +++ b/contrib/ntp/sntp/libevent/build-aux/config.guess @@ -0,0 +1,1517 @@ +#! /bin/sh +# Attempt to guess a canonical system name. +# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011 Free Software Foundation, Inc. + +timestamp='2011-06-03' + +# This file is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA +# 02110-1301, USA. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + + +# Originally written by Per Bothner. Please send patches (context +# diff format) to and include a ChangeLog +# entry. +# +# This script attempts to guess a canonical system name similar to +# config.sub. If it succeeds, it prints the system name on stdout, and +# exits with 0. Otherwise, it exits with 1. +# +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD + +me=`echo "$0" | sed -e 's,.*/,,'` + +usage="\ +Usage: $0 [OPTION] + +Output the configuration name of the system \`$me' is run on. + +Operation modes: + -h, --help print this help, then exit + -t, --time-stamp print date of last modification, then exit + -v, --version print version number, then exit + +Report bugs and patches to ." + +version="\ +GNU config.guess ($timestamp) + +Originally written by Per Bothner. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free +Software Foundation, Inc. + +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + +help=" +Try \`$me --help' for more information." + +# Parse command line +while test $# -gt 0 ; do + case $1 in + --time-stamp | --time* | -t ) + echo "$timestamp" ; exit ;; + --version | -v ) + echo "$version" ; exit ;; + --help | --h* | -h ) + echo "$usage"; exit ;; + -- ) # Stop option processing + shift; break ;; + - ) # Use stdin as input. + break ;; + -* ) + echo "$me: invalid option $1$help" >&2 + exit 1 ;; + * ) + break ;; + esac +done + +if test $# != 0; then + echo "$me: too many arguments$help" >&2 + exit 1 +fi + +trap 'exit 1' 1 2 15 + +# CC_FOR_BUILD -- compiler used by this script. Note that the use of a +# compiler to aid in system detection is discouraged as it requires +# temporary files to be created and, as you can see below, it is a +# headache to deal with in a portable fashion. + +# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still +# use `HOST_CC' if defined, but it is deprecated. + +# Portable tmp directory creation inspired by the Autoconf team. + +set_cc_for_build=' +trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; +trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; +: ${TMPDIR=/tmp} ; + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || + { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || + { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || + { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; +dummy=$tmp/dummy ; +tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; +case $CC_FOR_BUILD,$HOST_CC,$CC in + ,,) echo "int x;" > $dummy.c ; + for c in cc gcc c89 c99 ; do + if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then + CC_FOR_BUILD="$c"; break ; + fi ; + done ; + if test x"$CC_FOR_BUILD" = x ; then + CC_FOR_BUILD=no_compiler_found ; + fi + ;; + ,,*) CC_FOR_BUILD=$CC ;; + ,*,*) CC_FOR_BUILD=$HOST_CC ;; +esac ; set_cc_for_build= ;' + +# This is needed to find uname on a Pyramid OSx when run in the BSD universe. +# (ghazi@noc.rutgers.edu 1994-08-24) +if (test -f /.attbin/uname) >/dev/null 2>&1 ; then + PATH=$PATH:/.attbin ; export PATH +fi + +UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown +UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown +UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown +UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown + +# Note: order is significant - the case branches are not exclusive. + +case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in + *:NetBSD:*:*) + # NetBSD (nbsd) targets should (where applicable) match one or + # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, + # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently + # switched to ELF, *-*-netbsd* would select the old + # object file format. This provides both forward + # compatibility and a consistent mechanism for selecting the + # object file format. + # + # Note: NetBSD doesn't particularly care about the vendor + # portion of the name. We always set it to "unknown". + sysctl="sysctl -n hw.machine_arch" + UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ + /usr/sbin/$sysctl 2>/dev/null || echo unknown)` + case "${UNAME_MACHINE_ARCH}" in + armeb) machine=armeb-unknown ;; + arm*) machine=arm-unknown ;; + sh3el) machine=shl-unknown ;; + sh3eb) machine=sh-unknown ;; + sh5el) machine=sh5le-unknown ;; + *) machine=${UNAME_MACHINE_ARCH}-unknown ;; + esac + # The Operating System including object format, if it has switched + # to ELF recently, or will in the future. + case "${UNAME_MACHINE_ARCH}" in + arm*|i386|m68k|ns32k|sh3*|sparc|vax) + eval $set_cc_for_build + if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ELF__ + then + # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). + # Return netbsd for either. FIX? + os=netbsd + else + os=netbsdelf + fi + ;; + *) + os=netbsd + ;; + esac + # The OS release + # Debian GNU/NetBSD machines have a different userland, and + # thus, need a distinct triplet. However, they do not need + # kernel version information, so it can be replaced with a + # suitable tag, in the style of linux-gnu. + case "${UNAME_VERSION}" in + Debian*) + release='-gnu' + ;; + *) + release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` + ;; + esac + # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: + # contains redundant information, the shorter form: + # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. + echo "${machine}-${os}${release}" + exit ;; + *:OpenBSD:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` + echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} + exit ;; + *:ekkoBSD:*:*) + echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} + exit ;; + *:SolidBSD:*:*) + echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} + exit ;; + macppc:MirBSD:*:*) + echo powerpc-unknown-mirbsd${UNAME_RELEASE} + exit ;; + *:MirBSD:*:*) + echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} + exit ;; + alpha:OSF1:*:*) + case $UNAME_RELEASE in + *4.0) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` + ;; + *5.*) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` + ;; + esac + # According to Compaq, /usr/sbin/psrinfo has been available on + # OSF/1 and Tru64 systems produced since 1995. I hope that + # covers most systems running today. This code pipes the CPU + # types through head -n 1, so we only detect the type of CPU 0. + ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` + case "$ALPHA_CPU_TYPE" in + "EV4 (21064)") + UNAME_MACHINE="alpha" ;; + "EV4.5 (21064)") + UNAME_MACHINE="alpha" ;; + "LCA4 (21066/21068)") + UNAME_MACHINE="alpha" ;; + "EV5 (21164)") + UNAME_MACHINE="alphaev5" ;; + "EV5.6 (21164A)") + UNAME_MACHINE="alphaev56" ;; + "EV5.6 (21164PC)") + UNAME_MACHINE="alphapca56" ;; + "EV5.7 (21164PC)") + UNAME_MACHINE="alphapca57" ;; + "EV6 (21264)") + UNAME_MACHINE="alphaev6" ;; + "EV6.7 (21264A)") + UNAME_MACHINE="alphaev67" ;; + "EV6.8CB (21264C)") + UNAME_MACHINE="alphaev68" ;; + "EV6.8AL (21264B)") + UNAME_MACHINE="alphaev68" ;; + "EV6.8CX (21264D)") + UNAME_MACHINE="alphaev68" ;; + "EV6.9A (21264/EV69A)") + UNAME_MACHINE="alphaev69" ;; + "EV7 (21364)") + UNAME_MACHINE="alphaev7" ;; + "EV7.9 (21364A)") + UNAME_MACHINE="alphaev79" ;; + esac + # A Pn.n version is a patched version. + # A Vn.n version is a released version. + # A Tn.n version is a released field test version. + # A Xn.n version is an unreleased experimental baselevel. + # 1.2 uses "1.2" for uname -r. + echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + exitcode=$? + trap '' 0 + exit $exitcode ;; + Alpha\ *:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # Should we change UNAME_MACHINE based on the output of uname instead + # of the specific Alpha model? + echo alpha-pc-interix + exit ;; + 21064:Windows_NT:50:3) + echo alpha-dec-winnt3.5 + exit ;; + Amiga*:UNIX_System_V:4.0:*) + echo m68k-unknown-sysv4 + exit ;; + *:[Aa]miga[Oo][Ss]:*:*) + echo ${UNAME_MACHINE}-unknown-amigaos + exit ;; + *:[Mm]orph[Oo][Ss]:*:*) + echo ${UNAME_MACHINE}-unknown-morphos + exit ;; + *:OS/390:*:*) + echo i370-ibm-openedition + exit ;; + *:z/VM:*:*) + echo s390-ibm-zvmoe + exit ;; + *:OS400:*:*) + echo powerpc-ibm-os400 + exit ;; + arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) + echo arm-acorn-riscix${UNAME_RELEASE} + exit ;; + arm:riscos:*:*|arm:RISCOS:*:*) + echo arm-unknown-riscos + exit ;; + SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) + echo hppa1.1-hitachi-hiuxmpp + exit ;; + Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) + # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. + if test "`(/bin/universe) 2>/dev/null`" = att ; then + echo pyramid-pyramid-sysv3 + else + echo pyramid-pyramid-bsd + fi + exit ;; + NILE*:*:*:dcosx) + echo pyramid-pyramid-svr4 + exit ;; + DRS?6000:unix:4.0:6*) + echo sparc-icl-nx6 + exit ;; + DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) + case `/usr/bin/uname -p` in + sparc) echo sparc-icl-nx7; exit ;; + esac ;; + s390x:SunOS:*:*) + echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4H:SunOS:5.*:*) + echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) + echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) + echo i386-pc-auroraux${UNAME_RELEASE} + exit ;; + i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) + eval $set_cc_for_build + SUN_ARCH="i386" + # If there is a compiler, see if it is configured for 64-bit objects. + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. + # This test works for both compilers. + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + SUN_ARCH="x86_64" + fi + fi + echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:6*:*) + # According to config.sub, this is the proper way to canonicalize + # SunOS6. Hard to guess exactly what SunOS6 will be like, but + # it's likely to be more like Solaris than SunOS4. + echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:*:*) + case "`/usr/bin/arch -k`" in + Series*|S4*) + UNAME_RELEASE=`uname -v` + ;; + esac + # Japanese Language versions have a version number like `4.1.3-JL'. + echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` + exit ;; + sun3*:SunOS:*:*) + echo m68k-sun-sunos${UNAME_RELEASE} + exit ;; + sun*:*:4.2BSD:*) + UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` + test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 + case "`/bin/arch`" in + sun3) + echo m68k-sun-sunos${UNAME_RELEASE} + ;; + sun4) + echo sparc-sun-sunos${UNAME_RELEASE} + ;; + esac + exit ;; + aushp:SunOS:*:*) + echo sparc-auspex-sunos${UNAME_RELEASE} + exit ;; + # The situation for MiNT is a little confusing. The machine name + # can be virtually everything (everything which is not + # "atarist" or "atariste" at least should have a processor + # > m68000). The system name ranges from "MiNT" over "FreeMiNT" + # to the lowercase version "mint" (or "freemint"). Finally + # the system name "TOS" denotes a system which is actually not + # MiNT. But MiNT is downward compatible to TOS, so this should + # be no problem. + atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) + echo m68k-milan-mint${UNAME_RELEASE} + exit ;; + hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) + echo m68k-hades-mint${UNAME_RELEASE} + exit ;; + *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) + echo m68k-unknown-mint${UNAME_RELEASE} + exit ;; + m68k:machten:*:*) + echo m68k-apple-machten${UNAME_RELEASE} + exit ;; + powerpc:machten:*:*) + echo powerpc-apple-machten${UNAME_RELEASE} + exit ;; + RISC*:Mach:*:*) + echo mips-dec-mach_bsd4.3 + exit ;; + RISC*:ULTRIX:*:*) + echo mips-dec-ultrix${UNAME_RELEASE} + exit ;; + VAX*:ULTRIX*:*:*) + echo vax-dec-ultrix${UNAME_RELEASE} + exit ;; + 2020:CLIX:*:* | 2430:CLIX:*:*) + echo clipper-intergraph-clix${UNAME_RELEASE} + exit ;; + mips:*:*:UMIPS | mips:*:*:RISCos) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c +#ifdef __cplusplus +#include /* for printf() prototype */ + int main (int argc, char *argv[]) { +#else + int main (argc, argv) int argc; char *argv[]; { +#endif + #if defined (host_mips) && defined (MIPSEB) + #if defined (SYSTYPE_SYSV) + printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_SVR4) + printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) + printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); + #endif + #endif + exit (-1); + } +EOF + $CC_FOR_BUILD -o $dummy $dummy.c && + dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && + SYSTEM_NAME=`$dummy $dummyarg` && + { echo "$SYSTEM_NAME"; exit; } + echo mips-mips-riscos${UNAME_RELEASE} + exit ;; + Motorola:PowerMAX_OS:*:*) + echo powerpc-motorola-powermax + exit ;; + Motorola:*:4.3:PL8-*) + echo powerpc-harris-powermax + exit ;; + Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) + echo powerpc-harris-powermax + exit ;; + Night_Hawk:Power_UNIX:*:*) + echo powerpc-harris-powerunix + exit ;; + m88k:CX/UX:7*:*) + echo m88k-harris-cxux7 + exit ;; + m88k:*:4*:R4*) + echo m88k-motorola-sysv4 + exit ;; + m88k:*:3*:R3*) + echo m88k-motorola-sysv3 + exit ;; + AViiON:dgux:*:*) + # DG/UX returns AViiON for all architectures + UNAME_PROCESSOR=`/usr/bin/uname -p` + if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] + then + if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ + [ ${TARGET_BINARY_INTERFACE}x = x ] + then + echo m88k-dg-dgux${UNAME_RELEASE} + else + echo m88k-dg-dguxbcs${UNAME_RELEASE} + fi + else + echo i586-dg-dgux${UNAME_RELEASE} + fi + exit ;; + M88*:DolphinOS:*:*) # DolphinOS (SVR3) + echo m88k-dolphin-sysv3 + exit ;; + M88*:*:R3*:*) + # Delta 88k system running SVR3 + echo m88k-motorola-sysv3 + exit ;; + XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) + echo m88k-tektronix-sysv3 + exit ;; + Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) + echo m68k-tektronix-bsd + exit ;; + *:IRIX*:*:*) + echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` + exit ;; + ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. + echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id + exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' + i*86:AIX:*:*) + echo i386-ibm-aix + exit ;; + ia64:AIX:*:*) + if [ -x /usr/bin/oslevel ] ; then + IBM_REV=`/usr/bin/oslevel` + else + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + fi + echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} + exit ;; + *:AIX:2:3) + if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #include + + main() + { + if (!__power_pc()) + exit(1); + puts("powerpc-ibm-aix3.2.5"); + exit(0); + } +EOF + if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` + then + echo "$SYSTEM_NAME" + else + echo rs6000-ibm-aix3.2.5 + fi + elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then + echo rs6000-ibm-aix3.2.4 + else + echo rs6000-ibm-aix3.2 + fi + exit ;; + *:AIX:*:[4567]) + IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` + if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then + IBM_ARCH=rs6000 + else + IBM_ARCH=powerpc + fi + if [ -x /usr/bin/oslevel ] ; then + IBM_REV=`/usr/bin/oslevel` + else + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + fi + echo ${IBM_ARCH}-ibm-aix${IBM_REV} + exit ;; + *:AIX:*:*) + echo rs6000-ibm-aix + exit ;; + ibmrt:4.4BSD:*|romp-ibm:BSD:*) + echo romp-ibm-bsd4.4 + exit ;; + ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and + echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to + exit ;; # report: romp-ibm BSD 4.3 + *:BOSX:*:*) + echo rs6000-bull-bosx + exit ;; + DPX/2?00:B.O.S.:*:*) + echo m68k-bull-sysv3 + exit ;; + 9000/[34]??:4.3bsd:1.*:*) + echo m68k-hp-bsd + exit ;; + hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) + echo m68k-hp-bsd4.4 + exit ;; + 9000/[34678]??:HP-UX:*:*) + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + case "${UNAME_MACHINE}" in + 9000/31? ) HP_ARCH=m68000 ;; + 9000/[34]?? ) HP_ARCH=m68k ;; + 9000/[678][0-9][0-9]) + if [ -x /usr/bin/getconf ]; then + sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` + case "${sc_cpu_version}" in + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 + 532) # CPU_PA_RISC2_0 + case "${sc_kernel_bits}" in + 32) HP_ARCH="hppa2.0n" ;; + 64) HP_ARCH="hppa2.0w" ;; + '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 + esac ;; + esac + fi + if [ "${HP_ARCH}" = "" ]; then + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + + #define _HPUX_SOURCE + #include + #include + + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); + + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } +EOF + (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` + test -z "$HP_ARCH" && HP_ARCH=hppa + fi ;; + esac + if [ ${HP_ARCH} = "hppa2.0w" ] + then + eval $set_cc_for_build + + # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating + # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler + # generating 64-bit code. GNU and HP use different nomenclature: + # + # $ CC_FOR_BUILD=cc ./config.guess + # => hppa2.0w-hp-hpux11.23 + # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess + # => hppa64-hp-hpux11.23 + + if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | + grep -q __LP64__ + then + HP_ARCH="hppa2.0w" + else + HP_ARCH="hppa64" + fi + fi + echo ${HP_ARCH}-hp-hpux${HPUX_REV} + exit ;; + ia64:HP-UX:*:*) + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + echo ia64-hp-hpux${HPUX_REV} + exit ;; + 3050*:HI-UX:*:*) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #include + int + main () + { + long cpu = sysconf (_SC_CPU_VERSION); + /* The order matters, because CPU_IS_HP_MC68K erroneously returns + true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct + results, however. */ + if (CPU_IS_PA_RISC (cpu)) + { + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; + case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; + default: puts ("hppa-hitachi-hiuxwe2"); break; + } + } + else if (CPU_IS_HP_MC68K (cpu)) + puts ("m68k-hitachi-hiuxwe2"); + else puts ("unknown-hitachi-hiuxwe2"); + exit (0); + } +EOF + $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && + { echo "$SYSTEM_NAME"; exit; } + echo unknown-hitachi-hiuxwe2 + exit ;; + 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) + echo hppa1.1-hp-bsd + exit ;; + 9000/8??:4.3bsd:*:*) + echo hppa1.0-hp-bsd + exit ;; + *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) + echo hppa1.0-hp-mpeix + exit ;; + hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) + echo hppa1.1-hp-osf + exit ;; + hp8??:OSF1:*:*) + echo hppa1.0-hp-osf + exit ;; + i*86:OSF1:*:*) + if [ -x /usr/sbin/sysversion ] ; then + echo ${UNAME_MACHINE}-unknown-osf1mk + else + echo ${UNAME_MACHINE}-unknown-osf1 + fi + exit ;; + parisc*:Lites*:*:*) + echo hppa1.1-hp-lites + exit ;; + C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) + echo c1-convex-bsd + exit ;; + C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) + if getsysinfo -f scalar_acc + then echo c32-convex-bsd + else echo c2-convex-bsd + fi + exit ;; + C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) + echo c34-convex-bsd + exit ;; + C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) + echo c38-convex-bsd + exit ;; + C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) + echo c4-convex-bsd + exit ;; + CRAY*Y-MP:*:*:*) + echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*[A-Z]90:*:*:*) + echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ + | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ + -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ + -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*TS:*:*:*) + echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*T3E:*:*:*) + echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*SV1:*:*:*) + echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + *:UNICOS/mp:*:*) + echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) + FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; + 5000:UNIX_System_V:4.*:*) + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; + i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) + echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} + exit ;; + sparc*:BSD/OS:*:*) + echo sparc-unknown-bsdi${UNAME_RELEASE} + exit ;; + *:BSD/OS:*:*) + echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} + exit ;; + *:FreeBSD:*:*) + case ${UNAME_MACHINE} in + pc98) + echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + amd64) + echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + *) + echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + esac + exit ;; + i*:CYGWIN*:*) + echo ${UNAME_MACHINE}-pc-cygwin + exit ;; + *:MINGW*:*) + echo ${UNAME_MACHINE}-pc-mingw32 + exit ;; + i*:windows32*:*) + # uname -m includes "-pc" on this system. + echo ${UNAME_MACHINE}-mingw32 + exit ;; + i*:PW*:*) + echo ${UNAME_MACHINE}-pc-pw32 + exit ;; + *:Interix*:*) + case ${UNAME_MACHINE} in + x86) + echo i586-pc-interix${UNAME_RELEASE} + exit ;; + authenticamd | genuineintel | EM64T) + echo x86_64-unknown-interix${UNAME_RELEASE} + exit ;; + IA64) + echo ia64-unknown-interix${UNAME_RELEASE} + exit ;; + esac ;; + [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) + echo i${UNAME_MACHINE}-pc-mks + exit ;; + 8664:Windows_NT:*) + echo x86_64-pc-mks + exit ;; + i*:Windows_NT*:* | Pentium*:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we + # UNAME_MACHINE based on the output of uname instead of i386? + echo i586-pc-interix + exit ;; + i*:UWIN*:*) + echo ${UNAME_MACHINE}-pc-uwin + exit ;; + amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) + echo x86_64-unknown-cygwin + exit ;; + p*:CYGWIN*:*) + echo powerpcle-unknown-cygwin + exit ;; + prep*:SunOS:5.*:*) + echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + *:GNU:*:*) + # the GNU system + echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` + exit ;; + *:GNU/*:*:*) + # other systems with GNU libc and userland + echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu + exit ;; + i*86:Minix:*:*) + echo ${UNAME_MACHINE}-pc-minix + exit ;; + alpha:Linux:*:*) + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in + EV5) UNAME_MACHINE=alphaev5 ;; + EV56) UNAME_MACHINE=alphaev56 ;; + PCA56) UNAME_MACHINE=alphapca56 ;; + PCA57) UNAME_MACHINE=alphapca56 ;; + EV6) UNAME_MACHINE=alphaev6 ;; + EV67) UNAME_MACHINE=alphaev67 ;; + EV68*) UNAME_MACHINE=alphaev68 ;; + esac + objdump --private-headers /bin/sh | grep -q ld.so.1 + if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi + echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} + exit ;; + arm*:Linux:*:*) + eval $set_cc_for_build + if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_EABI__ + then + echo ${UNAME_MACHINE}-unknown-linux-gnu + else + if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_PCS_VFP + then + echo ${UNAME_MACHINE}-unknown-linux-gnueabi + else + echo ${UNAME_MACHINE}-unknown-linux-gnueabihf + fi + fi + exit ;; + avr32*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + cris:Linux:*:*) + echo cris-axis-linux-gnu + exit ;; + crisv32:Linux:*:*) + echo crisv32-axis-linux-gnu + exit ;; + frv:Linux:*:*) + echo frv-unknown-linux-gnu + exit ;; + i*86:Linux:*:*) + LIBC=gnu + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #ifdef __dietlibc__ + LIBC=dietlibc + #endif +EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` + echo "${UNAME_MACHINE}-pc-linux-${LIBC}" + exit ;; + ia64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + m32r*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + m68*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + mips:Linux:*:* | mips64:Linux:*:*) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #undef CPU + #undef ${UNAME_MACHINE} + #undef ${UNAME_MACHINE}el + #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) + CPU=${UNAME_MACHINE}el + #else + #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) + CPU=${UNAME_MACHINE} + #else + CPU= + #endif + #endif +EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` + test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } + ;; + or32:Linux:*:*) + echo or32-unknown-linux-gnu + exit ;; + padre:Linux:*:*) + echo sparc-unknown-linux-gnu + exit ;; + parisc64:Linux:*:* | hppa64:Linux:*:*) + echo hppa64-unknown-linux-gnu + exit ;; + parisc:Linux:*:* | hppa:Linux:*:*) + # Look for CPU level + case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in + PA7*) echo hppa1.1-unknown-linux-gnu ;; + PA8*) echo hppa2.0-unknown-linux-gnu ;; + *) echo hppa-unknown-linux-gnu ;; + esac + exit ;; + ppc64:Linux:*:*) + echo powerpc64-unknown-linux-gnu + exit ;; + ppc:Linux:*:*) + echo powerpc-unknown-linux-gnu + exit ;; + s390:Linux:*:* | s390x:Linux:*:*) + echo ${UNAME_MACHINE}-ibm-linux + exit ;; + sh64*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + sh*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + sparc:Linux:*:* | sparc64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + tile*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + vax:Linux:*:*) + echo ${UNAME_MACHINE}-dec-linux-gnu + exit ;; + x86_64:Linux:*:*) + echo x86_64-unknown-linux-gnu + exit ;; + xtensa*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu + exit ;; + i*86:DYNIX/ptx:4*:*) + # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. + # earlier versions are messed up and put the nodename in both + # sysname and nodename. + echo i386-sequent-sysv4 + exit ;; + i*86:UNIX_SV:4.2MP:2.*) + # Unixware is an offshoot of SVR4, but it has its own version + # number series starting with 2... + # I am not positive that other SVR4 systems won't match this, + # I just have to hope. -- rms. + # Use sysv4.2uw... so that sysv4* matches it. + echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} + exit ;; + i*86:OS/2:*:*) + # If we were able to find `uname', then EMX Unix compatibility + # is probably installed. + echo ${UNAME_MACHINE}-pc-os2-emx + exit ;; + i*86:XTS-300:*:STOP) + echo ${UNAME_MACHINE}-unknown-stop + exit ;; + i*86:atheos:*:*) + echo ${UNAME_MACHINE}-unknown-atheos + exit ;; + i*86:syllable:*:*) + echo ${UNAME_MACHINE}-pc-syllable + exit ;; + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) + echo i386-unknown-lynxos${UNAME_RELEASE} + exit ;; + i*86:*DOS:*:*) + echo ${UNAME_MACHINE}-pc-msdosdjgpp + exit ;; + i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) + UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` + if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then + echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} + else + echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} + fi + exit ;; + i*86:*:5:[678]*) + # UnixWare 7.x, OpenUNIX and OpenServer 6. + case `/bin/uname -X | grep "^Machine"` in + *486*) UNAME_MACHINE=i486 ;; + *Pentium) UNAME_MACHINE=i586 ;; + *Pent*|*Celeron) UNAME_MACHINE=i686 ;; + esac + echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} + exit ;; + i*86:*:3.2:*) + if test -f /usr/options/cb.name; then + UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then + UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` + (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 + (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ + && UNAME_MACHINE=i586 + (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ + && UNAME_MACHINE=i686 + (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ + && UNAME_MACHINE=i686 + echo ${UNAME_MACHINE}-pc-sco$UNAME_REL + else + echo ${UNAME_MACHINE}-pc-sysv32 + fi + exit ;; + pc:*:*:*) + # Left here for compatibility: + # uname -m prints for DJGPP always 'pc', but it prints nothing about + # the processor, so we play safe by assuming i586. + # Note: whatever this is, it MUST be the same as what config.sub + # prints for the "djgpp" host, or else GDB configury will decide that + # this is a cross-build. + echo i586-pc-msdosdjgpp + exit ;; + Intel:Mach:3*:*) + echo i386-pc-mach3 + exit ;; + paragon:*:*:*) + echo i860-intel-osf1 + exit ;; + i860:*:4.*:*) # i860-SVR4 + if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then + echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 + else # Add other i860-SVR4 vendors below as they are discovered. + echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 + fi + exit ;; + mini*:CTIX:SYS*5:*) + # "miniframe" + echo m68010-convergent-sysv + exit ;; + mc68k:UNIX:SYSTEM5:3.51m) + echo m68k-convergent-sysv + exit ;; + M680?0:D-NIX:5.3:*) + echo m68k-diab-dnix + exit ;; + M68*:*:R3V[5678]*:*) + test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; + 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) + OS_REL='' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4; exit; } ;; + NCR*:*:4.2:* | MPRAS*:*:4.2:*) + OS_REL='.3' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) + echo m68k-unknown-lynxos${UNAME_RELEASE} + exit ;; + mc68030:UNIX_System_V:4.*:*) + echo m68k-atari-sysv4 + exit ;; + TSUNAMI:LynxOS:2.*:*) + echo sparc-unknown-lynxos${UNAME_RELEASE} + exit ;; + rs6000:LynxOS:2.*:*) + echo rs6000-unknown-lynxos${UNAME_RELEASE} + exit ;; + PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) + echo powerpc-unknown-lynxos${UNAME_RELEASE} + exit ;; + SM[BE]S:UNIX_SV:*:*) + echo mips-dde-sysv${UNAME_RELEASE} + exit ;; + RM*:ReliantUNIX-*:*:*) + echo mips-sni-sysv4 + exit ;; + RM*:SINIX-*:*:*) + echo mips-sni-sysv4 + exit ;; + *:SINIX-*:*:*) + if uname -p 2>/dev/null >/dev/null ; then + UNAME_MACHINE=`(uname -p) 2>/dev/null` + echo ${UNAME_MACHINE}-sni-sysv4 + else + echo ns32k-sni-sysv + fi + exit ;; + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says + echo i586-unisys-sysv4 + exit ;; + *:UNIX_System_V:4*:FTX*) + # From Gerald Hewes . + # How about differentiating between stratus architectures? -djm + echo hppa1.1-stratus-sysv4 + exit ;; + *:*:*:FTX*) + # From seanf@swdc.stratus.com. + echo i860-stratus-sysv4 + exit ;; + i*86:VOS:*:*) + # From Paul.Green@stratus.com. + echo ${UNAME_MACHINE}-stratus-vos + exit ;; + *:VOS:*:*) + # From Paul.Green@stratus.com. + echo hppa1.1-stratus-vos + exit ;; + mc68*:A/UX:*:*) + echo m68k-apple-aux${UNAME_RELEASE} + exit ;; + news*:NEWS-OS:6*:*) + echo mips-sony-newsos6 + exit ;; + R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) + if [ -d /usr/nec ]; then + echo mips-nec-sysv${UNAME_RELEASE} + else + echo mips-unknown-sysv${UNAME_RELEASE} + fi + exit ;; + BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. + echo powerpc-be-beos + exit ;; + BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. + echo powerpc-apple-beos + exit ;; + BePC:BeOS:*:*) # BeOS running on Intel PC compatible. + echo i586-pc-beos + exit ;; + BePC:Haiku:*:*) # Haiku running on Intel PC compatible. + echo i586-pc-haiku + exit ;; + SX-4:SUPER-UX:*:*) + echo sx4-nec-superux${UNAME_RELEASE} + exit ;; + SX-5:SUPER-UX:*:*) + echo sx5-nec-superux${UNAME_RELEASE} + exit ;; + SX-6:SUPER-UX:*:*) + echo sx6-nec-superux${UNAME_RELEASE} + exit ;; + SX-7:SUPER-UX:*:*) + echo sx7-nec-superux${UNAME_RELEASE} + exit ;; + SX-8:SUPER-UX:*:*) + echo sx8-nec-superux${UNAME_RELEASE} + exit ;; + SX-8R:SUPER-UX:*:*) + echo sx8r-nec-superux${UNAME_RELEASE} + exit ;; + Power*:Rhapsody:*:*) + echo powerpc-apple-rhapsody${UNAME_RELEASE} + exit ;; + *:Rhapsody:*:*) + echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} + exit ;; + *:Darwin:*:*) + UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown + case $UNAME_PROCESSOR in + i386) + eval $set_cc_for_build + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + UNAME_PROCESSOR="x86_64" + fi + fi ;; + unknown) UNAME_PROCESSOR=powerpc ;; + esac + echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} + exit ;; + *:procnto*:*:* | *:QNX:[0123456789]*:*) + UNAME_PROCESSOR=`uname -p` + if test "$UNAME_PROCESSOR" = "x86"; then + UNAME_PROCESSOR=i386 + UNAME_MACHINE=pc + fi + echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} + exit ;; + *:QNX:*:4*) + echo i386-pc-qnx + exit ;; + NEO-?:NONSTOP_KERNEL:*:*) + echo neo-tandem-nsk${UNAME_RELEASE} + exit ;; + NSE-?:NONSTOP_KERNEL:*:*) + echo nse-tandem-nsk${UNAME_RELEASE} + exit ;; + NSR-?:NONSTOP_KERNEL:*:*) + echo nsr-tandem-nsk${UNAME_RELEASE} + exit ;; + *:NonStop-UX:*:*) + echo mips-compaq-nonstopux + exit ;; + BS2000:POSIX*:*:*) + echo bs2000-siemens-sysv + exit ;; + DS/*:UNIX_System_V:*:*) + echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} + exit ;; + *:Plan9:*:*) + # "uname -m" is not consistent, so use $cputype instead. 386 + # is converted to i386 for consistency with other x86 + # operating systems. + if test "$cputype" = "386"; then + UNAME_MACHINE=i386 + else + UNAME_MACHINE="$cputype" + fi + echo ${UNAME_MACHINE}-unknown-plan9 + exit ;; + *:TOPS-10:*:*) + echo pdp10-unknown-tops10 + exit ;; + *:TENEX:*:*) + echo pdp10-unknown-tenex + exit ;; + KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) + echo pdp10-dec-tops20 + exit ;; + XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) + echo pdp10-xkl-tops20 + exit ;; + *:TOPS-20:*:*) + echo pdp10-unknown-tops20 + exit ;; + *:ITS:*:*) + echo pdp10-unknown-its + exit ;; + SEI:*:*:SEIUX) + echo mips-sei-seiux${UNAME_RELEASE} + exit ;; + *:DragonFly:*:*) + echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + exit ;; + *:*VMS:*:*) + UNAME_MACHINE=`(uname -p) 2>/dev/null` + case "${UNAME_MACHINE}" in + A*) echo alpha-dec-vms ; exit ;; + I*) echo ia64-dec-vms ; exit ;; + V*) echo vax-dec-vms ; exit ;; + esac ;; + *:XENIX:*:SysV) + echo i386-pc-xenix + exit ;; + i*86:skyos:*:*) + echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' + exit ;; + i*86:rdos:*:*) + echo ${UNAME_MACHINE}-pc-rdos + exit ;; + i*86:AROS:*:*) + echo ${UNAME_MACHINE}-pc-aros + exit ;; +esac + +#echo '(No uname command or uname output not recognized.)' 1>&2 +#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 + +eval $set_cc_for_build +cat >$dummy.c < +# include +#endif +main () +{ +#if defined (sony) +#if defined (MIPSEB) + /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, + I don't know.... */ + printf ("mips-sony-bsd\n"); exit (0); +#else +#include + printf ("m68k-sony-newsos%s\n", +#ifdef NEWSOS4 + "4" +#else + "" +#endif + ); exit (0); +#endif +#endif + +#if defined (__arm) && defined (__acorn) && defined (__unix) + printf ("arm-acorn-riscix\n"); exit (0); +#endif + +#if defined (hp300) && !defined (hpux) + printf ("m68k-hp-bsd\n"); exit (0); +#endif + +#if defined (NeXT) +#if !defined (__ARCHITECTURE__) +#define __ARCHITECTURE__ "m68k" +#endif + int version; + version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; + if (version < 4) + printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); + else + printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); + exit (0); +#endif + +#if defined (MULTIMAX) || defined (n16) +#if defined (UMAXV) + printf ("ns32k-encore-sysv\n"); exit (0); +#else +#if defined (CMU) + printf ("ns32k-encore-mach\n"); exit (0); +#else + printf ("ns32k-encore-bsd\n"); exit (0); +#endif +#endif +#endif + +#if defined (__386BSD__) + printf ("i386-pc-bsd\n"); exit (0); +#endif + +#if defined (sequent) +#if defined (i386) + printf ("i386-sequent-dynix\n"); exit (0); +#endif +#if defined (ns32000) + printf ("ns32k-sequent-dynix\n"); exit (0); +#endif +#endif + +#if defined (_SEQUENT_) + struct utsname un; + + uname(&un); + + if (strncmp(un.version, "V2", 2) == 0) { + printf ("i386-sequent-ptx2\n"); exit (0); + } + if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ + printf ("i386-sequent-ptx1\n"); exit (0); + } + printf ("i386-sequent-ptx\n"); exit (0); + +#endif + +#if defined (vax) +# if !defined (ultrix) +# include +# if defined (BSD) +# if BSD == 43 + printf ("vax-dec-bsd4.3\n"); exit (0); +# else +# if BSD == 199006 + printf ("vax-dec-bsd4.3reno\n"); exit (0); +# else + printf ("vax-dec-bsd\n"); exit (0); +# endif +# endif +# else + printf ("vax-dec-bsd\n"); exit (0); +# endif +# else + printf ("vax-dec-ultrix\n"); exit (0); +# endif +#endif + +#if defined (alliant) && defined (i860) + printf ("i860-alliant-bsd\n"); exit (0); +#endif + + exit (1); +} +EOF + +$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && + { echo "$SYSTEM_NAME"; exit; } + +# Apollos put the system type in the environment. + +test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } + +# Convex versions that predate uname can use getsysinfo(1) + +if [ -x /usr/convex/getsysinfo ] +then + case `getsysinfo -f cpu_type` in + c1*) + echo c1-convex-bsd + exit ;; + c2*) + if getsysinfo -f scalar_acc + then echo c32-convex-bsd + else echo c2-convex-bsd + fi + exit ;; + c34*) + echo c34-convex-bsd + exit ;; + c38*) + echo c38-convex-bsd + exit ;; + c4*) + echo c4-convex-bsd + exit ;; + esac +fi + +cat >&2 < in order to provide the needed +information to handle your system. + +config.guess timestamp = $timestamp + +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null` + +hostinfo = `(hostinfo) 2>/dev/null` +/bin/universe = `(/bin/universe) 2>/dev/null` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` +/bin/arch = `(/bin/arch) 2>/dev/null` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` + +UNAME_MACHINE = ${UNAME_MACHINE} +UNAME_RELEASE = ${UNAME_RELEASE} +UNAME_SYSTEM = ${UNAME_SYSTEM} +UNAME_VERSION = ${UNAME_VERSION} +EOF + +exit 1 + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "timestamp='" +# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-end: "'" +# End: diff --git a/contrib/ntp/sntp/libevent/build-aux/config.sub b/contrib/ntp/sntp/libevent/build-aux/config.sub new file mode 100755 index 000000000..f9fcdc879 --- /dev/null +++ b/contrib/ntp/sntp/libevent/build-aux/config.sub @@ -0,0 +1,1756 @@ +#! /bin/sh +# Configuration validation subroutine script. +# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +# 2011 Free Software Foundation, Inc. + +timestamp='2011-06-03' + +# This file is (in principle) common to ALL GNU software. +# The presence of a machine in this file suggests that SOME GNU software +# can handle that machine. It does not imply ALL GNU software can. +# +# This file is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA +# 02110-1301, USA. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + + +# Please send patches to . Submit a context +# diff and a properly formatted GNU ChangeLog entry. +# +# Configuration subroutine to validate and canonicalize a configuration type. +# Supply the specified configuration type as an argument. +# If it is invalid, we print an error message on stderr and exit with code 1. +# Otherwise, we print the canonical config type on stdout and succeed. + +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD + +# This file is supposed to be the same for all GNU packages +# and recognize all the CPU types, system types and aliases +# that are meaningful with *any* GNU software. +# Each package is responsible for reporting which valid configurations +# it does not support. The user should be able to distinguish +# a failure to support a valid configuration from a meaningless +# configuration. + +# The goal of this file is to map all the various variations of a given +# machine specification into a single specification in the form: +# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM +# or in some cases, the newer four-part form: +# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM +# It is wrong to echo any other type of specification. + +me=`echo "$0" | sed -e 's,.*/,,'` + +usage="\ +Usage: $0 [OPTION] CPU-MFR-OPSYS + $0 [OPTION] ALIAS + +Canonicalize a configuration name. + +Operation modes: + -h, --help print this help, then exit + -t, --time-stamp print date of last modification, then exit + -v, --version print version number, then exit + +Report bugs and patches to ." + +version="\ +GNU config.sub ($timestamp) + +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, +2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free +Software Foundation, Inc. + +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + +help=" +Try \`$me --help' for more information." + +# Parse command line +while test $# -gt 0 ; do + case $1 in + --time-stamp | --time* | -t ) + echo "$timestamp" ; exit ;; + --version | -v ) + echo "$version" ; exit ;; + --help | --h* | -h ) + echo "$usage"; exit ;; + -- ) # Stop option processing + shift; break ;; + - ) # Use stdin as input. + break ;; + -* ) + echo "$me: invalid option $1$help" + exit 1 ;; + + *local*) + # First pass through any local machine types. + echo $1 + exit ;; + + * ) + break ;; + esac +done + +case $# in + 0) echo "$me: missing argument$help" >&2 + exit 1;; + 1) ;; + *) echo "$me: too many arguments$help" >&2 + exit 1;; +esac + +# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). +# Here we must recognize all the valid KERNEL-OS combinations. +maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` +case $maybe_os in + nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ + linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ + knetbsd*-gnu* | netbsd*-gnu* | \ + kopensolaris*-gnu* | \ + storm-chaos* | os2-emx* | rtmk-nova*) + os=-$maybe_os + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` + ;; + *) + basic_machine=`echo $1 | sed 's/-[^-]*$//'` + if [ $basic_machine != $1 ] + then os=`echo $1 | sed 's/.*-/-/'` + else os=; fi + ;; +esac + +### Let's recognize common machines as not being operating systems so +### that things like config.sub decstation-3100 work. We also +### recognize some manufacturers as not being operating systems, so we +### can provide default operating systems below. +case $os in + -sun*os*) + # Prevent following clause from handling this invalid input. + ;; + -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ + -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ + -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ + -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ + -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ + -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ + -apple | -axis | -knuth | -cray | -microblaze) + os= + basic_machine=$1 + ;; + -bluegene*) + os=-cnk + ;; + -sim | -cisco | -oki | -wec | -winbond) + os= + basic_machine=$1 + ;; + -scout) + ;; + -wrs) + os=-vxworks + basic_machine=$1 + ;; + -chorusos*) + os=-chorusos + basic_machine=$1 + ;; + -chorusrdb) + os=-chorusrdb + basic_machine=$1 + ;; + -hiux*) + os=-hiuxwe2 + ;; + -sco6) + os=-sco5v6 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5) + os=-sco3.2v5 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco4) + os=-sco3.2v4 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2.[4-9]*) + os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2v[4-9]*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco*) + os=-sco3.2v2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -udk*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -isc) + os=-isc2.2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -clix*) + basic_machine=clipper-intergraph + ;; + -isc*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -lynx*) + os=-lynxos + ;; + -ptx*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` + ;; + -windowsnt*) + os=`echo $os | sed -e 's/windowsnt/winnt/'` + ;; + -psos*) + os=-psos + ;; + -mint | -mint[0-9]*) + basic_machine=m68k-atari + os=-mint + ;; +esac + +# Decode aliases for certain CPU-COMPANY combinations. +case $basic_machine in + # Recognize the basic CPU types without company name. + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ + | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ + | bfin \ + | c4x | clipper \ + | d10v | d30v | dlx | dsp16xx \ + | fido | fr30 | frv \ + | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | i370 | i860 | i960 | ia64 \ + | ip2k | iq2000 \ + | lm32 \ + | m32c | m32r | m32rle | m68000 | m68k | m88k \ + | maxq | mb | microblaze | mcore | mep | metag \ + | mips | mipsbe | mipseb | mipsel | mipsle \ + | mips16 \ + | mips64 | mips64el \ + | mips64octeon | mips64octeonel \ + | mips64orion | mips64orionel \ + | mips64r5900 | mips64r5900el \ + | mips64vr | mips64vrel \ + | mips64vr4100 | mips64vr4100el \ + | mips64vr4300 | mips64vr4300el \ + | mips64vr5000 | mips64vr5000el \ + | mips64vr5900 | mips64vr5900el \ + | mipsisa32 | mipsisa32el \ + | mipsisa32r2 | mipsisa32r2el \ + | mipsisa64 | mipsisa64el \ + | mipsisa64r2 | mipsisa64r2el \ + | mipsisa64sb1 | mipsisa64sb1el \ + | mipsisa64sr71k | mipsisa64sr71kel \ + | mipstx39 | mipstx39el \ + | mn10200 | mn10300 \ + | moxie \ + | mt \ + | msp430 \ + | nds32 | nds32le | nds32be \ + | nios | nios2 \ + | ns16k | ns32k \ + | open8 \ + | or32 \ + | pdp10 | pdp11 | pj | pjl \ + | powerpc | powerpc64 | powerpc64le | powerpcle \ + | pyramid \ + | rx \ + | score \ + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ + | sh64 | sh64le \ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ + | spu \ + | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ + | ubicom32 \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ + | we32k \ + | x86 | xc16x | xstormy16 | xtensa \ + | z8k | z80) + basic_machine=$basic_machine-unknown + ;; + c54x) + basic_machine=tic54x-unknown + ;; + c55x) + basic_machine=tic55x-unknown + ;; + c6x) + basic_machine=tic6x-unknown + ;; + m6811 | m68hc11 | m6812 | m68hc12 | picochip) + # Motorola 68HC11/12. + basic_machine=$basic_machine-unknown + os=-none + ;; + m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) + ;; + ms1) + basic_machine=mt-unknown + ;; + + strongarm | thumb | xscale) + basic_machine=arm-unknown + ;; + + xscaleeb) + basic_machine=armeb-unknown + ;; + + xscaleel) + basic_machine=armel-unknown + ;; + + # We use `pc' rather than `unknown' + # because (1) that's what they normally are, and + # (2) the word "unknown" tends to confuse beginning users. + i*86 | x86_64) + basic_machine=$basic_machine-pc + ;; + # Object if more than one company name word. + *-*-*) + echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + exit 1 + ;; + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ + | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ + | avr-* | avr32-* \ + | bfin-* | bs2000-* \ + | c[123]* | c30-* | [cjt]90-* | c4x-* \ + | clipper-* | craynv-* | cydra-* \ + | d10v-* | d30v-* | dlx-* \ + | elxsi-* \ + | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ + | h8300-* | h8500-* \ + | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | i*86-* | i860-* | i960-* | ia64-* \ + | ip2k-* | iq2000-* \ + | lm32-* \ + | m32c-* | m32r-* | m32rle-* \ + | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ + | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \ + | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ + | mips16-* \ + | mips64-* | mips64el-* \ + | mips64octeon-* | mips64octeonel-* \ + | mips64orion-* | mips64orionel-* \ + | mips64r5900-* | mips64r5900el-* \ + | mips64vr-* | mips64vrel-* \ + | mips64vr4100-* | mips64vr4100el-* \ + | mips64vr4300-* | mips64vr4300el-* \ + | mips64vr5000-* | mips64vr5000el-* \ + | mips64vr5900-* | mips64vr5900el-* \ + | mipsisa32-* | mipsisa32el-* \ + | mipsisa32r2-* | mipsisa32r2el-* \ + | mipsisa64-* | mipsisa64el-* \ + | mipsisa64r2-* | mipsisa64r2el-* \ + | mipsisa64sb1-* | mipsisa64sb1el-* \ + | mipsisa64sr71k-* | mipsisa64sr71kel-* \ + | mipstx39-* | mipstx39el-* \ + | mmix-* \ + | mt-* \ + | msp430-* \ + | nds32-* | nds32le-* | nds32be-* \ + | nios-* | nios2-* \ + | none-* | np1-* | ns16k-* | ns32k-* \ + | open8-* \ + | orion-* \ + | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ + | pyramid-* \ + | romp-* | rs6000-* | rx-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ + | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ + | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ + | sparclite-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \ + | tahoe-* \ + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tile*-* \ + | tron-* \ + | ubicom32-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ + | we32k-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* \ + | xstormy16-* | xtensa*-* \ + | ymp-* \ + | z8k-* | z80-*) + ;; + # Recognize the basic CPU types without company name, with glob match. + xtensa*) + basic_machine=$basic_machine-unknown + ;; + # Recognize the various machine names and aliases which stand + # for a CPU type and a company and sometimes even an OS. + 386bsd) + basic_machine=i386-unknown + os=-bsd + ;; + 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) + basic_machine=m68000-att + ;; + 3b*) + basic_machine=we32k-att + ;; + a29khif) + basic_machine=a29k-amd + os=-udi + ;; + abacus) + basic_machine=abacus-unknown + ;; + adobe68k) + basic_machine=m68010-adobe + os=-scout + ;; + alliant | fx80) + basic_machine=fx80-alliant + ;; + altos | altos3068) + basic_machine=m68k-altos + ;; + am29k) + basic_machine=a29k-none + os=-bsd + ;; + amd64) + basic_machine=x86_64-pc + ;; + amd64-*) + basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + amdahl) + basic_machine=580-amdahl + os=-sysv + ;; + amiga | amiga-*) + basic_machine=m68k-unknown + ;; + amigaos | amigados) + basic_machine=m68k-unknown + os=-amigaos + ;; + amigaunix | amix) + basic_machine=m68k-unknown + os=-sysv4 + ;; + apollo68) + basic_machine=m68k-apollo + os=-sysv + ;; + apollo68bsd) + basic_machine=m68k-apollo + os=-bsd + ;; + aros) + basic_machine=i386-pc + os=-aros + ;; + aux) + basic_machine=m68k-apple + os=-aux + ;; + balance) + basic_machine=ns32k-sequent + os=-dynix + ;; + blackfin) + basic_machine=bfin-unknown + os=-linux + ;; + blackfin-*) + basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + bluegene*) + basic_machine=powerpc-ibm + os=-cnk + ;; + c54x-*) + basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c55x-*) + basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c6x-*) + basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c90) + basic_machine=c90-cray + os=-unicos + ;; + cegcc) + basic_machine=arm-unknown + os=-cegcc + ;; + convex-c1) + basic_machine=c1-convex + os=-bsd + ;; + convex-c2) + basic_machine=c2-convex + os=-bsd + ;; + convex-c32) + basic_machine=c32-convex + os=-bsd + ;; + convex-c34) + basic_machine=c34-convex + os=-bsd + ;; + convex-c38) + basic_machine=c38-convex + os=-bsd + ;; + cray | j90) + basic_machine=j90-cray + os=-unicos + ;; + craynv) + basic_machine=craynv-cray + os=-unicosmp + ;; + cr16 | cr16-*) + basic_machine=cr16-unknown + os=-elf + ;; + crds | unos) + basic_machine=m68k-crds + ;; + crisv32 | crisv32-* | etraxfs*) + basic_machine=crisv32-axis + ;; + cris | cris-* | etrax*) + basic_machine=cris-axis + ;; + crx) + basic_machine=crx-unknown + os=-elf + ;; + da30 | da30-*) + basic_machine=m68k-da30 + ;; + decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) + basic_machine=mips-dec + ;; + decsystem10* | dec10*) + basic_machine=pdp10-dec + os=-tops10 + ;; + decsystem20* | dec20*) + basic_machine=pdp10-dec + os=-tops20 + ;; + delta | 3300 | motorola-3300 | motorola-delta \ + | 3300-motorola | delta-motorola) + basic_machine=m68k-motorola + ;; + delta88) + basic_machine=m88k-motorola + os=-sysv3 + ;; + dicos) + basic_machine=i686-pc + os=-dicos + ;; + djgpp) + basic_machine=i586-pc + os=-msdosdjgpp + ;; + dpx20 | dpx20-*) + basic_machine=rs6000-bull + os=-bosx + ;; + dpx2* | dpx2*-bull) + basic_machine=m68k-bull + os=-sysv3 + ;; + ebmon29k) + basic_machine=a29k-amd + os=-ebmon + ;; + elxsi) + basic_machine=elxsi-elxsi + os=-bsd + ;; + encore | umax | mmax) + basic_machine=ns32k-encore + ;; + es1800 | OSE68k | ose68k | ose | OSE) + basic_machine=m68k-ericsson + os=-ose + ;; + fx2800) + basic_machine=i860-alliant + ;; + genix) + basic_machine=ns32k-ns + ;; + gmicro) + basic_machine=tron-gmicro + os=-sysv + ;; + go32) + basic_machine=i386-pc + os=-go32 + ;; + h3050r* | hiux*) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + h8300hms) + basic_machine=h8300-hitachi + os=-hms + ;; + h8300xray) + basic_machine=h8300-hitachi + os=-xray + ;; + h8500hms) + basic_machine=h8500-hitachi + os=-hms + ;; + harris) + basic_machine=m88k-harris + os=-sysv3 + ;; + hp300-*) + basic_machine=m68k-hp + ;; + hp300bsd) + basic_machine=m68k-hp + os=-bsd + ;; + hp300hpux) + basic_machine=m68k-hp + os=-hpux + ;; + hp3k9[0-9][0-9] | hp9[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k2[0-9][0-9] | hp9k31[0-9]) + basic_machine=m68000-hp + ;; + hp9k3[2-9][0-9]) + basic_machine=m68k-hp + ;; + hp9k6[0-9][0-9] | hp6[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k7[0-79][0-9] | hp7[0-79][0-9]) + basic_machine=hppa1.1-hp + ;; + hp9k78[0-9] | hp78[0-9]) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][13679] | hp8[0-9][13679]) + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][0-9] | hp8[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hppa-next) + os=-nextstep3 + ;; + hppaosf) + basic_machine=hppa1.1-hp + os=-osf + ;; + hppro) + basic_machine=hppa1.1-hp + os=-proelf + ;; + i370-ibm* | ibm*) + basic_machine=i370-ibm + ;; +# I'm not sure what "Sysv32" means. Should this be sysv3.2? + i*86v32) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv32 + ;; + i*86v4*) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv4 + ;; + i*86v) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv + ;; + i*86sol2) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-solaris2 + ;; + i386mach) + basic_machine=i386-mach + os=-mach + ;; + i386-vsta | vsta) + basic_machine=i386-unknown + os=-vsta + ;; + iris | iris4d) + basic_machine=mips-sgi + case $os in + -irix*) + ;; + *) + os=-irix4 + ;; + esac + ;; + isi68 | isi) + basic_machine=m68k-isi + os=-sysv + ;; + m68knommu) + basic_machine=m68k-unknown + os=-linux + ;; + m68knommu-*) + basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + m88k-omron*) + basic_machine=m88k-omron + ;; + magnum | m3230) + basic_machine=mips-mips + os=-sysv + ;; + merlin) + basic_machine=ns32k-utek + os=-sysv + ;; + microblaze) + basic_machine=microblaze-xilinx + ;; + mingw32) + basic_machine=i386-pc + os=-mingw32 + ;; + mingw32ce) + basic_machine=arm-unknown + os=-mingw32ce + ;; + miniframe) + basic_machine=m68000-convergent + ;; + *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) + basic_machine=m68k-atari + os=-mint + ;; + mips3*-*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` + ;; + mips3*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown + ;; + monitor) + basic_machine=m68k-rom68k + os=-coff + ;; + morphos) + basic_machine=powerpc-unknown + os=-morphos + ;; + msdos) + basic_machine=i386-pc + os=-msdos + ;; + ms1-*) + basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` + ;; + mvs) + basic_machine=i370-ibm + os=-mvs + ;; + ncr3000) + basic_machine=i486-ncr + os=-sysv4 + ;; + netbsd386) + basic_machine=i386-unknown + os=-netbsd + ;; + netwinder) + basic_machine=armv4l-rebel + os=-linux + ;; + news | news700 | news800 | news900) + basic_machine=m68k-sony + os=-newsos + ;; + news1000) + basic_machine=m68030-sony + os=-newsos + ;; + news-3600 | risc-news) + basic_machine=mips-sony + os=-newsos + ;; + necv70) + basic_machine=v70-nec + os=-sysv + ;; + next | m*-next ) + basic_machine=m68k-next + case $os in + -nextstep* ) + ;; + -ns2*) + os=-nextstep2 + ;; + *) + os=-nextstep3 + ;; + esac + ;; + nh3000) + basic_machine=m68k-harris + os=-cxux + ;; + nh[45]000) + basic_machine=m88k-harris + os=-cxux + ;; + nindy960) + basic_machine=i960-intel + os=-nindy + ;; + mon960) + basic_machine=i960-intel + os=-mon960 + ;; + nonstopux) + basic_machine=mips-compaq + os=-nonstopux + ;; + np1) + basic_machine=np1-gould + ;; + neo-tandem) + basic_machine=neo-tandem + ;; + nse-tandem) + basic_machine=nse-tandem + ;; + nsr-tandem) + basic_machine=nsr-tandem + ;; + op50n-* | op60c-*) + basic_machine=hppa1.1-oki + os=-proelf + ;; + openrisc | openrisc-*) + basic_machine=or32-unknown + ;; + os400) + basic_machine=powerpc-ibm + os=-os400 + ;; + OSE68000 | ose68000) + basic_machine=m68000-ericsson + os=-ose + ;; + os68k) + basic_machine=m68k-none + os=-os68k + ;; + pa-hitachi) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + paragon) + basic_machine=i860-intel + os=-osf + ;; + parisc) + basic_machine=hppa-unknown + os=-linux + ;; + parisc-*) + basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + pbd) + basic_machine=sparc-tti + ;; + pbb) + basic_machine=m68k-tti + ;; + pc532 | pc532-*) + basic_machine=ns32k-pc532 + ;; + pc98) + basic_machine=i386-pc + ;; + pc98-*) + basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium | p5 | k5 | k6 | nexgen | viac3) + basic_machine=i586-pc + ;; + pentiumpro | p6 | 6x86 | athlon | athlon_*) + basic_machine=i686-pc + ;; + pentiumii | pentium2 | pentiumiii | pentium3) + basic_machine=i686-pc + ;; + pentium4) + basic_machine=i786-pc + ;; + pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) + basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumpro-* | p6-* | 6x86-* | athlon-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium4-*) + basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pn) + basic_machine=pn-gould + ;; + power) basic_machine=power-ibm + ;; + ppc | ppcbe) basic_machine=powerpc-unknown + ;; + ppc-* | ppcbe-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppcle | powerpclittle | ppc-le | powerpc-little) + basic_machine=powerpcle-unknown + ;; + ppcle-* | powerpclittle-*) + basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64) basic_machine=powerpc64-unknown + ;; + ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64le | powerpc64little | ppc64-le | powerpc64-little) + basic_machine=powerpc64le-unknown + ;; + ppc64le-* | powerpc64little-*) + basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ps2) + basic_machine=i386-ibm + ;; + pw32) + basic_machine=i586-unknown + os=-pw32 + ;; + rdos) + basic_machine=i386-pc + os=-rdos + ;; + rom68k) + basic_machine=m68k-rom68k + os=-coff + ;; + rm[46]00) + basic_machine=mips-siemens + ;; + rtpc | rtpc-*) + basic_machine=romp-ibm + ;; + s390 | s390-*) + basic_machine=s390-ibm + ;; + s390x | s390x-*) + basic_machine=s390x-ibm + ;; + sa29200) + basic_machine=a29k-amd + os=-udi + ;; + sb1) + basic_machine=mipsisa64sb1-unknown + ;; + sb1el) + basic_machine=mipsisa64sb1el-unknown + ;; + sde) + basic_machine=mipsisa32-sde + os=-elf + ;; + sei) + basic_machine=mips-sei + os=-seiux + ;; + sequent) + basic_machine=i386-sequent + ;; + sh) + basic_machine=sh-hitachi + os=-hms + ;; + sh5el) + basic_machine=sh5le-unknown + ;; + sh64) + basic_machine=sh64-unknown + ;; + sparclite-wrs | simso-wrs) + basic_machine=sparclite-wrs + os=-vxworks + ;; + sps7) + basic_machine=m68k-bull + os=-sysv2 + ;; + spur) + basic_machine=spur-unknown + ;; + st2000) + basic_machine=m68k-tandem + ;; + stratus) + basic_machine=i860-stratus + os=-sysv4 + ;; + strongarm-* | thumb-*) + basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + sun2) + basic_machine=m68000-sun + ;; + sun2os3) + basic_machine=m68000-sun + os=-sunos3 + ;; + sun2os4) + basic_machine=m68000-sun + os=-sunos4 + ;; + sun3os3) + basic_machine=m68k-sun + os=-sunos3 + ;; + sun3os4) + basic_machine=m68k-sun + os=-sunos4 + ;; + sun4os3) + basic_machine=sparc-sun + os=-sunos3 + ;; + sun4os4) + basic_machine=sparc-sun + os=-sunos4 + ;; + sun4sol2) + basic_machine=sparc-sun + os=-solaris2 + ;; + sun3 | sun3-*) + basic_machine=m68k-sun + ;; + sun4) + basic_machine=sparc-sun + ;; + sun386 | sun386i | roadrunner) + basic_machine=i386-sun + ;; + sv1) + basic_machine=sv1-cray + os=-unicos + ;; + symmetry) + basic_machine=i386-sequent + os=-dynix + ;; + t3e) + basic_machine=alphaev5-cray + os=-unicos + ;; + t90) + basic_machine=t90-cray + os=-unicos + ;; + tile*) + basic_machine=$basic_machine-unknown + os=-linux-gnu + ;; + tx39) + basic_machine=mipstx39-unknown + ;; + tx39el) + basic_machine=mipstx39el-unknown + ;; + toad1) + basic_machine=pdp10-xkl + os=-tops20 + ;; + tower | tower-32) + basic_machine=m68k-ncr + ;; + tpf) + basic_machine=s390x-ibm + os=-tpf + ;; + udi29k) + basic_machine=a29k-amd + os=-udi + ;; + ultra3) + basic_machine=a29k-nyu + os=-sym1 + ;; + v810 | necv810) + basic_machine=v810-nec + os=-none + ;; + vaxv) + basic_machine=vax-dec + os=-sysv + ;; + vms) + basic_machine=vax-dec + os=-vms + ;; + vpp*|vx|vx-*) + basic_machine=f301-fujitsu + ;; + vxworks960) + basic_machine=i960-wrs + os=-vxworks + ;; + vxworks68) + basic_machine=m68k-wrs + os=-vxworks + ;; + vxworks29k) + basic_machine=a29k-wrs + os=-vxworks + ;; + w65*) + basic_machine=w65-wdc + os=-none + ;; + w89k-*) + basic_machine=hppa1.1-winbond + os=-proelf + ;; + xbox) + basic_machine=i686-pc + os=-mingw32 + ;; + xps | xps100) + basic_machine=xps100-honeywell + ;; + xscale-* | xscalee[bl]-*) + basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + ;; + ymp) + basic_machine=ymp-cray + os=-unicos + ;; + z8k-*-coff) + basic_machine=z8k-unknown + os=-sim + ;; + z80-*-coff) + basic_machine=z80-unknown + os=-sim + ;; + none) + basic_machine=none-none + os=-none + ;; + +# Here we handle the default manufacturer of certain CPU types. It is in +# some cases the only manufacturer, in others, it is the most popular. + w89k) + basic_machine=hppa1.1-winbond + ;; + op50n) + basic_machine=hppa1.1-oki + ;; + op60c) + basic_machine=hppa1.1-oki + ;; + romp) + basic_machine=romp-ibm + ;; + mmix) + basic_machine=mmix-knuth + ;; + rs6000) + basic_machine=rs6000-ibm + ;; + vax) + basic_machine=vax-dec + ;; + pdp10) + # there are many clones, so DEC is not a safe bet + basic_machine=pdp10-unknown + ;; + pdp11) + basic_machine=pdp11-dec + ;; + we32k) + basic_machine=we32k-att + ;; + sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) + basic_machine=sh-unknown + ;; + sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) + basic_machine=sparc-sun + ;; + cydra) + basic_machine=cydra-cydrome + ;; + orion) + basic_machine=orion-highlevel + ;; + orion105) + basic_machine=clipper-highlevel + ;; + mac | mpw | mac-mpw) + basic_machine=m68k-apple + ;; + pmac | pmac-mpw) + basic_machine=powerpc-apple + ;; + *-unknown) + # Make sure to match an already-canonicalized machine name. + ;; + *) + echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + exit 1 + ;; +esac + +# Here we canonicalize certain aliases for manufacturers. +case $basic_machine in + *-digital*) + basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` + ;; + *-commodore*) + basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` + ;; + *) + ;; +esac + +# Decode manufacturer-specific aliases for certain operating systems. + +if [ x"$os" != x"" ] +then +case $os in + # First match some system type aliases + # that might get confused with valid system types. + # -solaris* is a basic system type, with this one exception. + -auroraux) + os=-auroraux + ;; + -solaris1 | -solaris1.*) + os=`echo $os | sed -e 's|solaris1|sunos4|'` + ;; + -solaris) + os=-solaris2 + ;; + -svr4*) + os=-sysv4 + ;; + -unixware*) + os=-sysv4.2uw + ;; + -gnu/linux*) + os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` + ;; + # First accept the basic system types. + # The portable systems comes first. + # Each alternative MUST END IN A *, to match a version number. + # -sysv* is not here because it comes later, after sysvr4. + -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* \ + | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ + | -aos* | -aros* \ + | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ + | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -openbsd* | -solidbsd* \ + | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ + | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ + | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* | -cegcc* \ + | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ + | -mingw32* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-uclibc* \ + | -uxpv* | -beos* | -mpeix* | -udk* \ + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ + | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ + | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ + | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) + # Remember, each alternative MUST END IN *, to match a version number. + ;; + -qnx*) + case $basic_machine in + x86-* | i*86-*) + ;; + *) + os=-nto$os + ;; + esac + ;; + -nto-qnx*) + ;; + -nto*) + os=`echo $os | sed -e 's|nto|nto-qnx|'` + ;; + -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ + | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ + | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) + ;; + -mac*) + os=`echo $os | sed -e 's|mac|macos|'` + ;; + -linux-dietlibc) + os=-linux-dietlibc + ;; + -linux*) + os=`echo $os | sed -e 's|linux|linux-gnu|'` + ;; + -sunos5*) + os=`echo $os | sed -e 's|sunos5|solaris2|'` + ;; + -sunos6*) + os=`echo $os | sed -e 's|sunos6|solaris3|'` + ;; + -opened*) + os=-openedition + ;; + -os400*) + os=-os400 + ;; + -wince*) + os=-wince + ;; + -osfrose*) + os=-osfrose + ;; + -osf*) + os=-osf + ;; + -utek*) + os=-bsd + ;; + -dynix*) + os=-bsd + ;; + -acis*) + os=-aos + ;; + -atheos*) + os=-atheos + ;; + -syllable*) + os=-syllable + ;; + -386bsd) + os=-bsd + ;; + -ctix* | -uts*) + os=-sysv + ;; + -nova*) + os=-rtmk-nova + ;; + -ns2 ) + os=-nextstep2 + ;; + -nsk*) + os=-nsk + ;; + # Preserve the version number of sinix5. + -sinix5.*) + os=`echo $os | sed -e 's|sinix|sysv|'` + ;; + -sinix*) + os=-sysv4 + ;; + -tpf*) + os=-tpf + ;; + -triton*) + os=-sysv3 + ;; + -oss*) + os=-sysv3 + ;; + -svr4) + os=-sysv4 + ;; + -svr3) + os=-sysv3 + ;; + -sysvr4) + os=-sysv4 + ;; + # This must come after -sysvr4. + -sysv*) + ;; + -ose*) + os=-ose + ;; + -es1800*) + os=-ose + ;; + -xenix) + os=-xenix + ;; + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) + os=-mint + ;; + -aros*) + os=-aros + ;; + -kaos*) + os=-kaos + ;; + -zvmoe) + os=-zvmoe + ;; + -dicos*) + os=-dicos + ;; + -nacl*) + ;; + -none) + ;; + *) + # Get rid of the `-' at the beginning of $os. + os=`echo $os | sed 's/[^-]*-//'` + echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 + exit 1 + ;; +esac +else + +# Here we handle the default operating systems that come with various machines. +# The value should be what the vendor currently ships out the door with their +# machine or put another way, the most popular os provided with the machine. + +# Note that if you're going to try to match "-MANUFACTURER" here (say, +# "-sun"), then you have to tell the case statement up towards the top +# that MANUFACTURER isn't an operating system. Otherwise, code above +# will signal an error saying that MANUFACTURER isn't an operating +# system, and we'll never get to this point. + +case $basic_machine in + score-*) + os=-elf + ;; + spu-*) + os=-elf + ;; + *-acorn) + os=-riscix1.2 + ;; + arm*-rebel) + os=-linux + ;; + arm*-semi) + os=-aout + ;; + c4x-* | tic4x-*) + os=-coff + ;; + tic54x-*) + os=-coff + ;; + tic55x-*) + os=-coff + ;; + tic6x-*) + os=-coff + ;; + # This must come before the *-dec entry. + pdp10-*) + os=-tops20 + ;; + pdp11-*) + os=-none + ;; + *-dec | vax-*) + os=-ultrix4.2 + ;; + m68*-apollo) + os=-domain + ;; + i386-sun) + os=-sunos4.0.2 + ;; + m68000-sun) + os=-sunos3 + # This also exists in the configure program, but was not the + # default. + # os=-sunos4 + ;; + m68*-cisco) + os=-aout + ;; + mep-*) + os=-elf + ;; + mips*-cisco) + os=-elf + ;; + mips*-*) + os=-elf + ;; + or32-*) + os=-coff + ;; + *-tti) # must be before sparc entry or we get the wrong os. + os=-sysv3 + ;; + sparc-* | *-sun) + os=-sunos4.1.1 + ;; + *-be) + os=-beos + ;; + *-haiku) + os=-haiku + ;; + *-ibm) + os=-aix + ;; + *-knuth) + os=-mmixware + ;; + *-wec) + os=-proelf + ;; + *-winbond) + os=-proelf + ;; + *-oki) + os=-proelf + ;; + *-hp) + os=-hpux + ;; + *-hitachi) + os=-hiux + ;; + i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) + os=-sysv + ;; + *-cbm) + os=-amigaos + ;; + *-dg) + os=-dgux + ;; + *-dolphin) + os=-sysv3 + ;; + m68k-ccur) + os=-rtu + ;; + m88k-omron*) + os=-luna + ;; + *-next ) + os=-nextstep + ;; + *-sequent) + os=-ptx + ;; + *-crds) + os=-unos + ;; + *-ns) + os=-genix + ;; + i370-*) + os=-mvs + ;; + *-next) + os=-nextstep3 + ;; + *-gould) + os=-sysv + ;; + *-highlevel) + os=-bsd + ;; + *-encore) + os=-bsd + ;; + *-sgi) + os=-irix + ;; + *-siemens) + os=-sysv4 + ;; + *-masscomp) + os=-rtu + ;; + f30[01]-fujitsu | f700-fujitsu) + os=-uxpv + ;; + *-rom68k) + os=-coff + ;; + *-*bug) + os=-coff + ;; + *-apple) + os=-macos + ;; + *-atari*) + os=-mint + ;; + *) + os=-none + ;; +esac +fi + +# Here we handle the case where we know the os, and the CPU type, but not the +# manufacturer. We pick the logical manufacturer. +vendor=unknown +case $basic_machine in + *-unknown) + case $os in + -riscix*) + vendor=acorn + ;; + -sunos*) + vendor=sun + ;; + -cnk*|-aix*) + vendor=ibm + ;; + -beos*) + vendor=be + ;; + -hpux*) + vendor=hp + ;; + -mpeix*) + vendor=hp + ;; + -hiux*) + vendor=hitachi + ;; + -unos*) + vendor=crds + ;; + -dgux*) + vendor=dg + ;; + -luna*) + vendor=omron + ;; + -genix*) + vendor=ns + ;; + -mvs* | -opened*) + vendor=ibm + ;; + -os400*) + vendor=ibm + ;; + -ptx*) + vendor=sequent + ;; + -tpf*) + vendor=ibm + ;; + -vxsim* | -vxworks* | -windiss*) + vendor=wrs + ;; + -aux*) + vendor=apple + ;; + -hms*) + vendor=hitachi + ;; + -mpw* | -macos*) + vendor=apple + ;; + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) + vendor=atari + ;; + -vos*) + vendor=stratus + ;; + esac + basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` + ;; +esac + +echo $basic_machine$os +exit + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "timestamp='" +# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-end: "'" +# End: diff --git a/contrib/ntp/arlib/depcomp b/contrib/ntp/sntp/libevent/build-aux/depcomp similarity index 77% rename from contrib/ntp/arlib/depcomp rename to contrib/ntp/sntp/libevent/build-aux/depcomp index 04701da53..df8eea7e4 100755 --- a/contrib/ntp/arlib/depcomp +++ b/contrib/ntp/sntp/libevent/build-aux/depcomp @@ -1,9 +1,10 @@ #! /bin/sh # depcomp - compile a program generating dependencies as side-effects -scriptversion=2005-07-09.11 +scriptversion=2009-04-28.21; # UTC -# Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc. +# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009 Free +# Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -16,9 +17,7 @@ scriptversion=2005-07-09.11 # GNU General Public License for more details. # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -# 02110-1301, USA. +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -86,12 +85,34 @@ if test "$depmode" = dashXmstdout; then depmode=dashmstdout fi +cygpath_u="cygpath -u -f -" +if test "$depmode" = msvcmsys; then + # This is just like msvisualcpp but w/o cygpath translation. + # Just convert the backslash-escaped backslashes to single forward + # slashes to satisfy depend.m4 + cygpath_u="sed s,\\\\\\\\,/,g" + depmode=msvisualcpp +fi + case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. - "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" +## Unfortunately, FreeBSD c89 acceptance of flags depends upon +## the command line argument order; so add the flags where they +## appear in depend2.am. Note that the slowdown incurred here +## affects only configure: in makefiles, %FASTDEP% shortcuts this. + for arg + do + case $arg in + -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; + *) set fnord "$@" "$arg" ;; + esac + shift # fnord + shift # $arg + done + "$@" stat=$? if test $stat -eq 0; then : else @@ -178,14 +199,14 @@ sgi) ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ tr ' -' ' ' >> $depfile - echo >> $depfile +' ' ' >> "$depfile" + echo >> "$depfile" # The second pass generates a dummy entry for each header file. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ - >> $depfile + >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile @@ -201,34 +222,39 @@ aix) # current directory. Also, the AIX compiler puts `$object:' at the # start of each line; $object doesn't have directory information. # Version 6 uses the directory in both cases. - stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'` - tmpdepfile="$stripped.u" + dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` + test "x$dir" = "x$object" && dir= + base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` if test "$libtool" = yes; then + tmpdepfile1=$dir$base.u + tmpdepfile2=$base.u + tmpdepfile3=$dir.libs/$base.u "$@" -Wc,-M else + tmpdepfile1=$dir$base.u + tmpdepfile2=$dir$base.u + tmpdepfile3=$dir$base.u "$@" -M fi stat=$? - if test -f "$tmpdepfile"; then : - else - stripped=`echo "$stripped" | sed 's,^.*/,,'` - tmpdepfile="$stripped.u" - fi - if test $stat -eq 0; then : else - rm -f "$tmpdepfile" + rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" exit $stat fi + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + do + test -f "$tmpdepfile" && break + done if test -f "$tmpdepfile"; then - outname="$stripped.o" # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. - sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" - sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" + sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" + # That's a tab and a space in the []. + sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile @@ -276,6 +302,51 @@ icc) rm -f "$tmpdepfile" ;; +hp2) + # The "hp" stanza above does not work with aCC (C++) and HP's ia64 + # compilers, which have integrated preprocessors. The correct option + # to use with these is +Maked; it writes dependencies to a file named + # 'foo.d', which lands next to the object file, wherever that + # happens to be. + # Much of this is similar to the tru64 case; see comments there. + dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` + test "x$dir" = "x$object" && dir= + base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` + if test "$libtool" = yes; then + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir.libs/$base.d + "$@" -Wc,+Maked + else + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir$base.d + "$@" +Maked + fi + stat=$? + if test $stat -eq 0; then : + else + rm -f "$tmpdepfile1" "$tmpdepfile2" + exit $stat + fi + + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" + do + test -f "$tmpdepfile" && break + done + if test -f "$tmpdepfile"; then + sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile" + # Add `dependent.h:' lines. + sed -ne '2,${ + s/^ *// + s/ \\*$// + s/$/:/ + p + }' "$tmpdepfile" >> "$depfile" + else + echo "#dummy" > "$depfile" + fi + rm -f "$tmpdepfile" "$tmpdepfile2" + ;; + tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. @@ -288,13 +359,13 @@ tru64) if test "$libtool" = yes; then # With Tru64 cc, shared objects can also be used to make a - # static library. This mecanism is used in libtool 1.4 series to + # static library. This mechanism is used in libtool 1.4 series to # handle both shared and static libraries in a single compilation. # With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d. # # With libtool 1.5 this exception was removed, and libtool now # generates 2 separate objects for the 2 libraries. These two - # compilations output dependencies in in $dir.libs/$base.o.d and + # compilations output dependencies in $dir.libs/$base.o.d and # in $dir$base.o.d. We have to check for both files, because # one of the two compilations can be disabled. We should prefer # $dir$base.o.d over $dir.libs/$base.o.d because the latter is @@ -345,7 +416,7 @@ dashmstdout) # Remove the call to Libtool. if test "$libtool" = yes; then - while test $1 != '--mode=compile'; do + while test "X$1" != 'X--mode=compile'; do shift done shift @@ -396,32 +467,39 @@ makedepend) "$@" || exit $? # Remove any Libtool call if test "$libtool" = yes; then - while test $1 != '--mode=compile'; do + while test "X$1" != 'X--mode=compile'; do shift done shift fi # X makedepend shift - cleared=no - for arg in "$@"; do + cleared=no eat=no + for arg + do case $cleared in no) set ""; shift cleared=yes ;; esac + if test $eat = yes; then + eat=no + continue + fi case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; # Strip any option that makedepend may not understand. Remove # the object too, otherwise makedepend will parse it as a source file. + -arch) + eat=yes ;; -*|$object) ;; *) set fnord "$@" "$arg"; shift ;; esac done - obj_suffix="`echo $object | sed 's/^.*\././'`" + obj_suffix=`echo "$object" | sed 's/^.*\././'` touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" @@ -441,7 +519,7 @@ cpp) # Remove the call to Libtool. if test "$libtool" = yes; then - while test $1 != '--mode=compile'; do + while test "X$1" != 'X--mode=compile'; do shift done shift @@ -479,13 +557,27 @@ cpp) msvisualcpp) # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout, regardless of -o, - # because we must use -o when running libtool. + # always write the preprocessed file to stdout. "$@" || exit $? + + # Remove the call to Libtool. + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + IFS=" " for arg do case "$arg" in + -o) + shift + ;; + $object) + shift + ;; "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift @@ -498,16 +590,23 @@ msvisualcpp) ;; esac done - "$@" -E | - sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" + "$@" -E 2>/dev/null | + sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" - . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" + sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" echo " " >> "$depfile" - . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" + sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; +msvcmsys) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + none) exec "$@" ;; @@ -526,5 +625,6 @@ exit 0 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-end: "$" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" # End: diff --git a/contrib/ntp/sntp/libevent/build-aux/install-sh b/contrib/ntp/sntp/libevent/build-aux/install-sh new file mode 100755 index 000000000..6781b987b --- /dev/null +++ b/contrib/ntp/sntp/libevent/build-aux/install-sh @@ -0,0 +1,520 @@ +#!/bin/sh +# install - install a program, script, or datafile + +scriptversion=2009-04-28.21; # UTC + +# This originates from X11R5 (mit/util/scripts/install.sh), which was +# later released in X11R6 (xc/config/util/install.sh) with the +# following copyright and license. +# +# Copyright (C) 1994 X Consortium +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to +# deal in the Software without restriction, including without limitation the +# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +# sell copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- +# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +# +# Except as contained in this notice, the name of the X Consortium shall not +# be used in advertising or otherwise to promote the sale, use or other deal- +# ings in this Software without prior written authorization from the X Consor- +# tium. +# +# +# FSF changes to this file are in the public domain. +# +# Calling this script install-sh is preferred over install.sh, to prevent +# `make' implicit rules from creating a file called install from it +# when there is no Makefile. +# +# This script is compatible with the BSD install script, but was written +# from scratch. + +nl=' +' +IFS=" "" $nl" + +# set DOITPROG to echo to test this script + +# Don't use :- since 4.3BSD and earlier shells don't like it. +doit=${DOITPROG-} +if test -z "$doit"; then + doit_exec=exec +else + doit_exec=$doit +fi + +# Put in absolute file names if you don't have them in your path; +# or use environment vars. + +chgrpprog=${CHGRPPROG-chgrp} +chmodprog=${CHMODPROG-chmod} +chownprog=${CHOWNPROG-chown} +cmpprog=${CMPPROG-cmp} +cpprog=${CPPROG-cp} +mkdirprog=${MKDIRPROG-mkdir} +mvprog=${MVPROG-mv} +rmprog=${RMPROG-rm} +stripprog=${STRIPPROG-strip} + +posix_glob='?' +initialize_posix_glob=' + test "$posix_glob" != "?" || { + if (set -f) 2>/dev/null; then + posix_glob= + else + posix_glob=: + fi + } +' + +posix_mkdir= + +# Desired mode of installed file. +mode=0755 + +chgrpcmd= +chmodcmd=$chmodprog +chowncmd= +mvcmd=$mvprog +rmcmd="$rmprog -f" +stripcmd= + +src= +dst= +dir_arg= +dst_arg= + +copy_on_change=false +no_target_directory= + +usage="\ +Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE + or: $0 [OPTION]... SRCFILES... DIRECTORY + or: $0 [OPTION]... -t DIRECTORY SRCFILES... + or: $0 [OPTION]... -d DIRECTORIES... + +In the 1st form, copy SRCFILE to DSTFILE. +In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. +In the 4th, create DIRECTORIES. + +Options: + --help display this help and exit. + --version display version info and exit. + + -c (ignored) + -C install only if different (preserve the last data modification time) + -d create directories instead of installing files. + -g GROUP $chgrpprog installed files to GROUP. + -m MODE $chmodprog installed files to MODE. + -o USER $chownprog installed files to USER. + -s $stripprog installed files. + -t DIRECTORY install into DIRECTORY. + -T report an error if DSTFILE is a directory. + +Environment variables override the default commands: + CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG + RMPROG STRIPPROG +" + +while test $# -ne 0; do + case $1 in + -c) ;; + + -C) copy_on_change=true;; + + -d) dir_arg=true;; + + -g) chgrpcmd="$chgrpprog $2" + shift;; + + --help) echo "$usage"; exit $?;; + + -m) mode=$2 + case $mode in + *' '* | *' '* | *' +'* | *'*'* | *'?'* | *'['*) + echo "$0: invalid mode: $mode" >&2 + exit 1;; + esac + shift;; + + -o) chowncmd="$chownprog $2" + shift;; + + -s) stripcmd=$stripprog;; + + -t) dst_arg=$2 + shift;; + + -T) no_target_directory=true;; + + --version) echo "$0 $scriptversion"; exit $?;; + + --) shift + break;; + + -*) echo "$0: invalid option: $1" >&2 + exit 1;; + + *) break;; + esac + shift +done + +if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then + # When -d is used, all remaining arguments are directories to create. + # When -t is used, the destination is already specified. + # Otherwise, the last argument is the destination. Remove it from $@. + for arg + do + if test -n "$dst_arg"; then + # $@ is not empty: it contains at least $arg. + set fnord "$@" "$dst_arg" + shift # fnord + fi + shift # arg + dst_arg=$arg + done +fi + +if test $# -eq 0; then + if test -z "$dir_arg"; then + echo "$0: no input file specified." >&2 + exit 1 + fi + # It's OK to call `install-sh -d' without argument. + # This can happen when creating conditional directories. + exit 0 +fi + +if test -z "$dir_arg"; then + trap '(exit $?); exit' 1 2 13 15 + + # Set umask so as not to create temps with too-generous modes. + # However, 'strip' requires both read and write access to temps. + case $mode in + # Optimize common cases. + *644) cp_umask=133;; + *755) cp_umask=22;; + + *[0-7]) + if test -z "$stripcmd"; then + u_plus_rw= + else + u_plus_rw='% 200' + fi + cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; + *) + if test -z "$stripcmd"; then + u_plus_rw= + else + u_plus_rw=,u+rw + fi + cp_umask=$mode$u_plus_rw;; + esac +fi + +for src +do + # Protect names starting with `-'. + case $src in + -*) src=./$src;; + esac + + if test -n "$dir_arg"; then + dst=$src + dstdir=$dst + test -d "$dstdir" + dstdir_status=$? + else + + # Waiting for this to be detected by the "$cpprog $src $dsttmp" command + # might cause directories to be created, which would be especially bad + # if $src (and thus $dsttmp) contains '*'. + if test ! -f "$src" && test ! -d "$src"; then + echo "$0: $src does not exist." >&2 + exit 1 + fi + + if test -z "$dst_arg"; then + echo "$0: no destination specified." >&2 + exit 1 + fi + + dst=$dst_arg + # Protect names starting with `-'. + case $dst in + -*) dst=./$dst;; + esac + + # If destination is a directory, append the input filename; won't work + # if double slashes aren't ignored. + if test -d "$dst"; then + if test -n "$no_target_directory"; then + echo "$0: $dst_arg: Is a directory" >&2 + exit 1 + fi + dstdir=$dst + dst=$dstdir/`basename "$src"` + dstdir_status=0 + else + # Prefer dirname, but fall back on a substitute if dirname fails. + dstdir=` + (dirname "$dst") 2>/dev/null || + expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$dst" : 'X\(//\)[^/]' \| \ + X"$dst" : 'X\(//\)$' \| \ + X"$dst" : 'X\(/\)' \| . 2>/dev/null || + echo X"$dst" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q' + ` + + test -d "$dstdir" + dstdir_status=$? + fi + fi + + obsolete_mkdir_used=false + + if test $dstdir_status != 0; then + case $posix_mkdir in + '') + # Create intermediate dirs using mode 755 as modified by the umask. + # This is like FreeBSD 'install' as of 1997-10-28. + umask=`umask` + case $stripcmd.$umask in + # Optimize common cases. + *[2367][2367]) mkdir_umask=$umask;; + .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; + + *[0-7]) + mkdir_umask=`expr $umask + 22 \ + - $umask % 100 % 40 + $umask % 20 \ + - $umask % 10 % 4 + $umask % 2 + `;; + *) mkdir_umask=$umask,go-w;; + esac + + # With -d, create the new directory with the user-specified mode. + # Otherwise, rely on $mkdir_umask. + if test -n "$dir_arg"; then + mkdir_mode=-m$mode + else + mkdir_mode= + fi + + posix_mkdir=false + case $umask in + *[123567][0-7][0-7]) + # POSIX mkdir -p sets u+wx bits regardless of umask, which + # is incompatible with FreeBSD 'install' when (umask & 300) != 0. + ;; + *) + tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ + trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 + + if (umask $mkdir_umask && + exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 + then + if test -z "$dir_arg" || { + # Check for POSIX incompatibilities with -m. + # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or + # other-writeable bit of parent directory when it shouldn't. + # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. + ls_ld_tmpdir=`ls -ld "$tmpdir"` + case $ls_ld_tmpdir in + d????-?r-*) different_mode=700;; + d????-?--*) different_mode=755;; + *) false;; + esac && + $mkdirprog -m$different_mode -p -- "$tmpdir" && { + ls_ld_tmpdir_1=`ls -ld "$tmpdir"` + test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" + } + } + then posix_mkdir=: + fi + rmdir "$tmpdir/d" "$tmpdir" + else + # Remove any dirs left behind by ancient mkdir implementations. + rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null + fi + trap '' 0;; + esac;; + esac + + if + $posix_mkdir && ( + umask $mkdir_umask && + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" + ) + then : + else + + # The umask is ridiculous, or mkdir does not conform to POSIX, + # or it failed possibly due to a race condition. Create the + # directory the slow way, step by step, checking for races as we go. + + case $dstdir in + /*) prefix='/';; + -*) prefix='./';; + *) prefix='';; + esac + + eval "$initialize_posix_glob" + + oIFS=$IFS + IFS=/ + $posix_glob set -f + set fnord $dstdir + shift + $posix_glob set +f + IFS=$oIFS + + prefixes= + + for d + do + test -z "$d" && continue + + prefix=$prefix$d + if test -d "$prefix"; then + prefixes= + else + if $posix_mkdir; then + (umask=$mkdir_umask && + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break + # Don't fail if two instances are running concurrently. + test -d "$prefix" || exit 1 + else + case $prefix in + *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; + *) qprefix=$prefix;; + esac + prefixes="$prefixes '$qprefix'" + fi + fi + prefix=$prefix/ + done + + if test -n "$prefixes"; then + # Don't fail if two instances are running concurrently. + (umask $mkdir_umask && + eval "\$doit_exec \$mkdirprog $prefixes") || + test -d "$dstdir" || exit 1 + obsolete_mkdir_used=true + fi + fi + fi + + if test -n "$dir_arg"; then + { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && + { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && + { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || + test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 + else + + # Make a couple of temp file names in the proper directory. + dsttmp=$dstdir/_inst.$$_ + rmtmp=$dstdir/_rm.$$_ + + # Trap to clean up those temp files at exit. + trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 + + # Copy the file name to the temp name. + (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && + + # and set any options; do chmod last to preserve setuid bits. + # + # If any of these fail, we abort the whole thing. If we want to + # ignore errors from any of these, just make sure not to ignore + # errors from the above "$doit $cpprog $src $dsttmp" command. + # + { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && + { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && + { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && + { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && + + # If -C, don't bother to copy if it wouldn't change the file. + if $copy_on_change && + old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && + new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && + + eval "$initialize_posix_glob" && + $posix_glob set -f && + set X $old && old=:$2:$4:$5:$6 && + set X $new && new=:$2:$4:$5:$6 && + $posix_glob set +f && + + test "$old" = "$new" && + $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 + then + rm -f "$dsttmp" + else + # Rename the file to the real destination. + $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || + + # The rename failed, perhaps because mv can't rename something else + # to itself, or perhaps because mv is so ancient that it does not + # support -f. + { + # Now remove or move aside any old file at destination location. + # We try this two ways since rm can't unlink itself on some + # systems and the destination file might be busy for other + # reasons. In this case, the final cleanup might fail but the new + # file should still install successfully. + { + test ! -f "$dst" || + $doit $rmcmd -f "$dst" 2>/dev/null || + { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && + { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } + } || + { echo "$0: cannot unlink or rename $dst" >&2 + (exit 1); exit 1 + } + } && + + # Now rename the file to the real destination. + $doit $mvcmd "$dsttmp" "$dst" + } + fi || exit 1 + + trap '' 0 + fi +done + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/contrib/ntp/sntp/libevent/build-aux/ltmain.sh b/contrib/ntp/sntp/libevent/build-aux/ltmain.sh new file mode 100755 index 000000000..63ae69dc6 --- /dev/null +++ b/contrib/ntp/sntp/libevent/build-aux/ltmain.sh @@ -0,0 +1,9655 @@ + +# libtool (GNU libtool) 2.4.2 +# Written by Gordon Matzigkeit , 1996 + +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, +# 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, +# or obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + +# Usage: $progname [OPTION]... [MODE-ARG]... +# +# Provide generalized library-building support services. +# +# --config show all configuration variables +# --debug enable verbose shell tracing +# -n, --dry-run display commands without modifying any files +# --features display basic configuration information and exit +# --mode=MODE use operation mode MODE +# --preserve-dup-deps don't remove duplicate dependency libraries +# --quiet, --silent don't print informational messages +# --no-quiet, --no-silent +# print informational messages (default) +# --no-warn don't display warning messages +# --tag=TAG use configuration variables from tag TAG +# -v, --verbose print more informational messages than default +# --no-verbose don't print the extra informational messages +# --version print version information +# -h, --help, --help-all print short, long, or detailed help message +# +# MODE must be one of the following: +# +# clean remove files from the build directory +# compile compile a source file into a libtool object +# execute automatically set library path, then run a program +# finish complete the installation of libtool libraries +# install install libraries or executables +# link create a library or an executable +# uninstall remove libraries from an installed directory +# +# MODE-ARGS vary depending on the MODE. When passed as first option, +# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that. +# Try `$progname --help --mode=MODE' for a more detailed description of MODE. +# +# When reporting a bug, please describe a test case to reproduce it and +# include the following information: +# +# host-triplet: $host +# shell: $SHELL +# compiler: $LTCC +# compiler flags: $LTCFLAGS +# linker: $LD (gnu? $with_gnu_ld) +# $progname: (GNU libtool) 2.4.2 +# automake: $automake_version +# autoconf: $autoconf_version +# +# Report bugs to . +# GNU libtool home page: . +# General help using GNU software: . + +PROGRAM=libtool +PACKAGE=libtool +VERSION=2.4.2 +TIMESTAMP="" +package_revision=1.3337 + +# Be Bourne compatible +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' +} + +# NLS nuisances: We save the old values to restore during execute mode. +lt_user_locale= +lt_safe_locale= +for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES +do + eval "if test \"\${$lt_var+set}\" = set; then + save_$lt_var=\$$lt_var + $lt_var=C + export $lt_var + lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\" + lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" + fi" +done +LC_ALL=C +LANGUAGE=C +export LANGUAGE LC_ALL + +$lt_unset CDPATH + + +# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh +# is ksh but when the shell is invoked as "sh" and the current value of +# the _XPG environment variable is not equal to 1 (one), the special +# positional parameter $0, within a function call, is the name of the +# function. +progpath="$0" + + + +: ${CP="cp -f"} +test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'} +: ${MAKE="make"} +: ${MKDIR="mkdir"} +: ${MV="mv -f"} +: ${RM="rm -f"} +: ${SHELL="${CONFIG_SHELL-/bin/sh}"} +: ${Xsed="$SED -e 1s/^X//"} + +# Global variables: +EXIT_SUCCESS=0 +EXIT_FAILURE=1 +EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. +EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. + +exit_status=$EXIT_SUCCESS + +# Make sure IFS has a sensible default +lt_nl=' +' +IFS=" $lt_nl" + +dirname="s,/[^/]*$,," +basename="s,^.*/,," + +# func_dirname file append nondir_replacement +# Compute the dirname of FILE. If nonempty, add APPEND to the result, +# otherwise set result to NONDIR_REPLACEMENT. +func_dirname () +{ + func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` + if test "X$func_dirname_result" = "X${1}"; then + func_dirname_result="${3}" + else + func_dirname_result="$func_dirname_result${2}" + fi +} # func_dirname may be replaced by extended shell implementation + + +# func_basename file +func_basename () +{ + func_basename_result=`$ECHO "${1}" | $SED "$basename"` +} # func_basename may be replaced by extended shell implementation + + +# func_dirname_and_basename file append nondir_replacement +# perform func_basename and func_dirname in a single function +# call: +# dirname: Compute the dirname of FILE. If nonempty, +# add APPEND to the result, otherwise set result +# to NONDIR_REPLACEMENT. +# value returned in "$func_dirname_result" +# basename: Compute filename of FILE. +# value retuned in "$func_basename_result" +# Implementation must be kept synchronized with func_dirname +# and func_basename. For efficiency, we do not delegate to +# those functions but instead duplicate the functionality here. +func_dirname_and_basename () +{ + # Extract subdirectory from the argument. + func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"` + if test "X$func_dirname_result" = "X${1}"; then + func_dirname_result="${3}" + else + func_dirname_result="$func_dirname_result${2}" + fi + func_basename_result=`$ECHO "${1}" | $SED -e "$basename"` +} # func_dirname_and_basename may be replaced by extended shell implementation + + +# func_stripname prefix suffix name +# strip PREFIX and SUFFIX off of NAME. +# PREFIX and SUFFIX must not contain globbing or regex special +# characters, hashes, percent signs, but SUFFIX may contain a leading +# dot (in which case that matches only a dot). +# func_strip_suffix prefix name +func_stripname () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname may be replaced by extended shell implementation + + +# These SED scripts presuppose an absolute path with a trailing slash. +pathcar='s,^/\([^/]*\).*$,\1,' +pathcdr='s,^/[^/]*,,' +removedotparts=':dotsl + s@/\./@/@g + t dotsl + s,/\.$,/,' +collapseslashes='s@/\{1,\}@/@g' +finalslash='s,/*$,/,' + +# func_normal_abspath PATH +# Remove doubled-up and trailing slashes, "." path components, +# and cancel out any ".." path components in PATH after making +# it an absolute path. +# value returned in "$func_normal_abspath_result" +func_normal_abspath () +{ + # Start from root dir and reassemble the path. + func_normal_abspath_result= + func_normal_abspath_tpath=$1 + func_normal_abspath_altnamespace= + case $func_normal_abspath_tpath in + "") + # Empty path, that just means $cwd. + func_stripname '' '/' "`pwd`" + func_normal_abspath_result=$func_stripname_result + return + ;; + # The next three entries are used to spot a run of precisely + # two leading slashes without using negated character classes; + # we take advantage of case's first-match behaviour. + ///*) + # Unusual form of absolute path, do nothing. + ;; + //*) + # Not necessarily an ordinary path; POSIX reserves leading '//' + # and for example Cygwin uses it to access remote file shares + # over CIFS/SMB, so we conserve a leading double slash if found. + func_normal_abspath_altnamespace=/ + ;; + /*) + # Absolute path, do nothing. + ;; + *) + # Relative path, prepend $cwd. + func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath + ;; + esac + # Cancel out all the simple stuff to save iterations. We also want + # the path to end with a slash for ease of parsing, so make sure + # there is one (and only one) here. + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"` + while :; do + # Processed it all yet? + if test "$func_normal_abspath_tpath" = / ; then + # If we ascended to the root using ".." the result may be empty now. + if test -z "$func_normal_abspath_result" ; then + func_normal_abspath_result=/ + fi + break + fi + func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$pathcar"` + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$pathcdr"` + # Figure out what to do with it + case $func_normal_abspath_tcomponent in + "") + # Trailing empty path component, ignore it. + ;; + ..) + # Parent dir; strip last assembled component from result. + func_dirname "$func_normal_abspath_result" + func_normal_abspath_result=$func_dirname_result + ;; + *) + # Actual path component, append it. + func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent + ;; + esac + done + # Restore leading double-slash if one was found on entry. + func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result +} + +# func_relative_path SRCDIR DSTDIR +# generates a relative path from SRCDIR to DSTDIR, with a trailing +# slash if non-empty, suitable for immediately appending a filename +# without needing to append a separator. +# value returned in "$func_relative_path_result" +func_relative_path () +{ + func_relative_path_result= + func_normal_abspath "$1" + func_relative_path_tlibdir=$func_normal_abspath_result + func_normal_abspath "$2" + func_relative_path_tbindir=$func_normal_abspath_result + + # Ascend the tree starting from libdir + while :; do + # check if we have found a prefix of bindir + case $func_relative_path_tbindir in + $func_relative_path_tlibdir) + # found an exact match + func_relative_path_tcancelled= + break + ;; + $func_relative_path_tlibdir*) + # found a matching prefix + func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" + func_relative_path_tcancelled=$func_stripname_result + if test -z "$func_relative_path_result"; then + func_relative_path_result=. + fi + break + ;; + *) + func_dirname $func_relative_path_tlibdir + func_relative_path_tlibdir=${func_dirname_result} + if test "x$func_relative_path_tlibdir" = x ; then + # Have to descend all the way to the root! + func_relative_path_result=../$func_relative_path_result + func_relative_path_tcancelled=$func_relative_path_tbindir + break + fi + func_relative_path_result=../$func_relative_path_result + ;; + esac + done + + # Now calculate path; take care to avoid doubling-up slashes. + func_stripname '' '/' "$func_relative_path_result" + func_relative_path_result=$func_stripname_result + func_stripname '/' '/' "$func_relative_path_tcancelled" + if test "x$func_stripname_result" != x ; then + func_relative_path_result=${func_relative_path_result}/${func_stripname_result} + fi + + # Normalisation. If bindir is libdir, return empty string, + # else relative path ending with a slash; either way, target + # file name can be directly appended. + if test ! -z "$func_relative_path_result"; then + func_stripname './' '' "$func_relative_path_result/" + func_relative_path_result=$func_stripname_result + fi +} + +# The name of this program: +func_dirname_and_basename "$progpath" +progname=$func_basename_result + +# Make sure we have an absolute path for reexecution: +case $progpath in + [\\/]*|[A-Za-z]:\\*) ;; + *[\\/]*) + progdir=$func_dirname_result + progdir=`cd "$progdir" && pwd` + progpath="$progdir/$progname" + ;; + *) + save_IFS="$IFS" + IFS=${PATH_SEPARATOR-:} + for progdir in $PATH; do + IFS="$save_IFS" + test -x "$progdir/$progname" && break + done + IFS="$save_IFS" + test -n "$progdir" || progdir=`pwd` + progpath="$progdir/$progname" + ;; +esac + +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +Xsed="${SED}"' -e 1s/^X//' +sed_quote_subst='s/\([`"$\\]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution that turns a string into a regex matching for the +# string literally. +sed_make_literal_regex='s,[].[^$\\*\/],\\&,g' + +# Sed substitution that converts a w32 file name or path +# which contains forward slashes, into one that contains +# (escaped) backslashes. A very naive implementation. +lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' + +# Re-`\' parameter expansions in output of double_quote_subst that were +# `\'-ed in input to the same. If an odd number of `\' preceded a '$' +# in input to double_quote_subst, that '$' was protected from expansion. +# Since each input `\' is now two `\'s, look for any number of runs of +# four `\'s followed by two `\'s and then a '$'. `\' that '$'. +bs='\\' +bs2='\\\\' +bs4='\\\\\\\\' +dollar='\$' +sed_double_backslash="\ + s/$bs4/&\\ +/g + s/^$bs2$dollar/$bs&/ + s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g + s/\n//g" + +# Standard options: +opt_dry_run=false +opt_help=false +opt_quiet=false +opt_verbose=false +opt_warning=: + +# func_echo arg... +# Echo program name prefixed message, along with the current mode +# name if it has been set yet. +func_echo () +{ + $ECHO "$progname: ${opt_mode+$opt_mode: }$*" +} + +# func_verbose arg... +# Echo program name prefixed message in verbose mode only. +func_verbose () +{ + $opt_verbose && func_echo ${1+"$@"} + + # A bug in bash halts the script if the last line of a function + # fails when set -e is in force, so we need another command to + # work around that: + : +} + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + +# func_error arg... +# Echo program name prefixed message to standard error. +func_error () +{ + $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2 +} + +# func_warning arg... +# Echo program name prefixed warning message to standard error. +func_warning () +{ + $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 + + # bash bug again: + : +} + +# func_fatal_error arg... +# Echo program name prefixed message to standard error, and exit. +func_fatal_error () +{ + func_error ${1+"$@"} + exit $EXIT_FAILURE +} + +# func_fatal_help arg... +# Echo program name prefixed message to standard error, followed by +# a help hint, and exit. +func_fatal_help () +{ + func_error ${1+"$@"} + func_fatal_error "$help" +} +help="Try \`$progname --help' for more information." ## default + + +# func_grep expression filename +# Check whether EXPRESSION matches any line of FILENAME, without output. +func_grep () +{ + $GREP "$1" "$2" >/dev/null 2>&1 +} + + +# func_mkdir_p directory-path +# Make sure the entire path to DIRECTORY-PATH is available. +func_mkdir_p () +{ + my_directory_path="$1" + my_dir_list= + + if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then + + # Protect directory names starting with `-' + case $my_directory_path in + -*) my_directory_path="./$my_directory_path" ;; + esac + + # While some portion of DIR does not yet exist... + while test ! -d "$my_directory_path"; do + # ...make a list in topmost first order. Use a colon delimited + # list incase some portion of path contains whitespace. + my_dir_list="$my_directory_path:$my_dir_list" + + # If the last portion added has no slash in it, the list is done + case $my_directory_path in */*) ;; *) break ;; esac + + # ...otherwise throw away the child directory and loop + my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"` + done + my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'` + + save_mkdir_p_IFS="$IFS"; IFS=':' + for my_dir in $my_dir_list; do + IFS="$save_mkdir_p_IFS" + # mkdir can fail with a `File exist' error if two processes + # try to create one of the directories concurrently. Don't + # stop in that case! + $MKDIR "$my_dir" 2>/dev/null || : + done + IFS="$save_mkdir_p_IFS" + + # Bail out if we (or some other process) failed to create a directory. + test -d "$my_directory_path" || \ + func_fatal_error "Failed to create \`$1'" + fi +} + + +# func_mktempdir [string] +# Make a temporary directory that won't clash with other running +# libtool processes, and avoids race conditions if possible. If +# given, STRING is the basename for that directory. +func_mktempdir () +{ + my_template="${TMPDIR-/tmp}/${1-$progname}" + + if test "$opt_dry_run" = ":"; then + # Return a directory name, but don't create it in dry-run mode + my_tmpdir="${my_template}-$$" + else + + # If mktemp works, use that first and foremost + my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` + + if test ! -d "$my_tmpdir"; then + # Failing that, at least try and use $RANDOM to avoid a race + my_tmpdir="${my_template}-${RANDOM-0}$$" + + save_mktempdir_umask=`umask` + umask 0077 + $MKDIR "$my_tmpdir" + umask $save_mktempdir_umask + fi + + # If we're not in dry-run mode, bomb out on failure + test -d "$my_tmpdir" || \ + func_fatal_error "cannot create temporary directory \`$my_tmpdir'" + fi + + $ECHO "$my_tmpdir" +} + + +# func_quote_for_eval arg +# Aesthetically quote ARG to be evaled later. +# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT +# is double-quoted, suitable for a subsequent eval, whereas +# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters +# which are still active within double quotes backslashified. +func_quote_for_eval () +{ + case $1 in + *[\\\`\"\$]*) + func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;; + *) + func_quote_for_eval_unquoted_result="$1" ;; + esac + + case $func_quote_for_eval_unquoted_result in + # Double-quote args containing shell metacharacters to delay + # word splitting, command substitution and and variable + # expansion for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\"" + ;; + *) + func_quote_for_eval_result="$func_quote_for_eval_unquoted_result" + esac +} + + +# func_quote_for_expand arg +# Aesthetically quote ARG to be evaled later; same as above, +# but do not quote variable references. +func_quote_for_expand () +{ + case $1 in + *[\\\`\"]*) + my_arg=`$ECHO "$1" | $SED \ + -e "$double_quote_subst" -e "$sed_double_backslash"` ;; + *) + my_arg="$1" ;; + esac + + case $my_arg in + # Double-quote args containing shell metacharacters to delay + # word splitting and command substitution for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + my_arg="\"$my_arg\"" + ;; + esac + + func_quote_for_expand_result="$my_arg" +} + + +# func_show_eval cmd [fail_exp] +# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. +func_show_eval () +{ + my_cmd="$1" + my_fail_exp="${2-:}" + + ${opt_silent-false} || { + func_quote_for_expand "$my_cmd" + eval "func_echo $func_quote_for_expand_result" + } + + if ${opt_dry_run-false}; then :; else + eval "$my_cmd" + my_status=$? + if test "$my_status" -eq 0; then :; else + eval "(exit $my_status); $my_fail_exp" + fi + fi +} + + +# func_show_eval_locale cmd [fail_exp] +# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. Use the saved locale for evaluation. +func_show_eval_locale () +{ + my_cmd="$1" + my_fail_exp="${2-:}" + + ${opt_silent-false} || { + func_quote_for_expand "$my_cmd" + eval "func_echo $func_quote_for_expand_result" + } + + if ${opt_dry_run-false}; then :; else + eval "$lt_user_locale + $my_cmd" + my_status=$? + eval "$lt_safe_locale" + if test "$my_status" -eq 0; then :; else + eval "(exit $my_status); $my_fail_exp" + fi + fi +} + +# func_tr_sh +# Turn $1 into a string suitable for a shell variable name. +# Result is stored in $func_tr_sh_result. All characters +# not in the set a-zA-Z0-9_ are replaced with '_'. Further, +# if $1 begins with a digit, a '_' is prepended as well. +func_tr_sh () +{ + case $1 in + [0-9]* | *[!a-zA-Z0-9_]*) + func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` + ;; + * ) + func_tr_sh_result=$1 + ;; + esac +} + + +# func_version +# Echo version message to standard output and exit. +func_version () +{ + $opt_debug + + $SED -n '/(C)/!b go + :more + /\./!{ + N + s/\n# / / + b more + } + :go + /^# '$PROGRAM' (GNU /,/# warranty; / { + s/^# // + s/^# *$// + s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ + p + }' < "$progpath" + exit $? +} + +# func_usage +# Echo short help message to standard output and exit. +func_usage () +{ + $opt_debug + + $SED -n '/^# Usage:/,/^# *.*--help/ { + s/^# // + s/^# *$// + s/\$progname/'$progname'/ + p + }' < "$progpath" + echo + $ECHO "run \`$progname --help | more' for full usage" + exit $? +} + +# func_help [NOEXIT] +# Echo long help message to standard output and exit, +# unless 'noexit' is passed as argument. +func_help () +{ + $opt_debug + + $SED -n '/^# Usage:/,/# Report bugs to/ { + :print + s/^# // + s/^# *$// + s*\$progname*'$progname'* + s*\$host*'"$host"'* + s*\$SHELL*'"$SHELL"'* + s*\$LTCC*'"$LTCC"'* + s*\$LTCFLAGS*'"$LTCFLAGS"'* + s*\$LD*'"$LD"'* + s/\$with_gnu_ld/'"$with_gnu_ld"'/ + s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/ + s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/ + p + d + } + /^# .* home page:/b print + /^# General help using/b print + ' < "$progpath" + ret=$? + if test -z "$1"; then + exit $ret + fi +} + +# func_missing_arg argname +# Echo program name prefixed message to standard error and set global +# exit_cmd. +func_missing_arg () +{ + $opt_debug + + func_error "missing argument for $1." + exit_cmd=exit +} + + +# func_split_short_opt shortopt +# Set func_split_short_opt_name and func_split_short_opt_arg shell +# variables after splitting SHORTOPT after the 2nd character. +func_split_short_opt () +{ + my_sed_short_opt='1s/^\(..\).*$/\1/;q' + my_sed_short_rest='1s/^..\(.*\)$/\1/;q' + + func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` + func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` +} # func_split_short_opt may be replaced by extended shell implementation + + +# func_split_long_opt longopt +# Set func_split_long_opt_name and func_split_long_opt_arg shell +# variables after splitting LONGOPT at the `=' sign. +func_split_long_opt () +{ + my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' + my_sed_long_arg='1s/^--[^=]*=//' + + func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` + func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` +} # func_split_long_opt may be replaced by extended shell implementation + +exit_cmd=: + + + + + +magic="%%%MAGIC variable%%%" +magic_exe="%%%MAGIC EXE variable%%%" + +# Global variables. +nonopt= +preserve_args= +lo2o="s/\\.lo\$/.${objext}/" +o2lo="s/\\.${objext}\$/.lo/" +extracted_archives= +extracted_serial=0 + +# If this variable is set in any of the actions, the command in it +# will be execed at the end. This prevents here-documents from being +# left over by shells. +exec_cmd= + +# func_append var value +# Append VALUE to the end of shell variable VAR. +func_append () +{ + eval "${1}=\$${1}\${2}" +} # func_append may be replaced by extended shell implementation + +# func_append_quoted var value +# Quote VALUE and append to the end of shell variable VAR, separated +# by a space. +func_append_quoted () +{ + func_quote_for_eval "${2}" + eval "${1}=\$${1}\\ \$func_quote_for_eval_result" +} # func_append_quoted may be replaced by extended shell implementation + + +# func_arith arithmetic-term... +func_arith () +{ + func_arith_result=`expr "${@}"` +} # func_arith may be replaced by extended shell implementation + + +# func_len string +# STRING may not start with a hyphen. +func_len () +{ + func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len` +} # func_len may be replaced by extended shell implementation + + +# func_lo2o object +func_lo2o () +{ + func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` +} # func_lo2o may be replaced by extended shell implementation + + +# func_xform libobj-or-source +func_xform () +{ + func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` +} # func_xform may be replaced by extended shell implementation + + +# func_fatal_configuration arg... +# Echo program name prefixed message to standard error, followed by +# a configuration failure hint, and exit. +func_fatal_configuration () +{ + func_error ${1+"$@"} + func_error "See the $PACKAGE documentation for more information." + func_fatal_error "Fatal configuration error." +} + + +# func_config +# Display the configuration for all the tags in this script. +func_config () +{ + re_begincf='^# ### BEGIN LIBTOOL' + re_endcf='^# ### END LIBTOOL' + + # Default configuration. + $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" + + # Now print the configurations for the tags. + for tagname in $taglist; do + $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" + done + + exit $? +} + +# func_features +# Display the features supported by this script. +func_features () +{ + echo "host: $host" + if test "$build_libtool_libs" = yes; then + echo "enable shared libraries" + else + echo "disable shared libraries" + fi + if test "$build_old_libs" = yes; then + echo "enable static libraries" + else + echo "disable static libraries" + fi + + exit $? +} + +# func_enable_tag tagname +# Verify that TAGNAME is valid, and either flag an error and exit, or +# enable the TAGNAME tag. We also add TAGNAME to the global $taglist +# variable here. +func_enable_tag () +{ + # Global variable: + tagname="$1" + + re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" + re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" + sed_extractcf="/$re_begincf/,/$re_endcf/p" + + # Validate tagname. + case $tagname in + *[!-_A-Za-z0-9,/]*) + func_fatal_error "invalid tag name: $tagname" + ;; + esac + + # Don't test for the "default" C tag, as we know it's + # there but not specially marked. + case $tagname in + CC) ;; + *) + if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then + taglist="$taglist $tagname" + + # Evaluate the configuration. Be careful to quote the path + # and the sed script, to avoid splitting on whitespace, but + # also don't use non-portable quotes within backquotes within + # quotes we have to do it in 2 steps: + extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` + eval "$extractedcf" + else + func_error "ignoring unknown tag $tagname" + fi + ;; + esac +} + +# func_check_version_match +# Ensure that we are using m4 macros, and libtool script from the same +# release of libtool. +func_check_version_match () +{ + if test "$package_revision" != "$macro_revision"; then + if test "$VERSION" != "$macro_version"; then + if test -z "$macro_version"; then + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from an older release. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + else + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + fi + else + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, +$progname: but the definition of this LT_INIT comes from revision $macro_revision. +$progname: You should recreate aclocal.m4 with macros from revision $package_revision +$progname: of $PACKAGE $VERSION and run autoconf again. +_LT_EOF + fi + + exit $EXIT_MISMATCH + fi +} + + +# Shorthand for --mode=foo, only valid as the first argument +case $1 in +clean|clea|cle|cl) + shift; set dummy --mode clean ${1+"$@"}; shift + ;; +compile|compil|compi|comp|com|co|c) + shift; set dummy --mode compile ${1+"$@"}; shift + ;; +execute|execut|execu|exec|exe|ex|e) + shift; set dummy --mode execute ${1+"$@"}; shift + ;; +finish|finis|fini|fin|fi|f) + shift; set dummy --mode finish ${1+"$@"}; shift + ;; +install|instal|insta|inst|ins|in|i) + shift; set dummy --mode install ${1+"$@"}; shift + ;; +link|lin|li|l) + shift; set dummy --mode link ${1+"$@"}; shift + ;; +uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) + shift; set dummy --mode uninstall ${1+"$@"}; shift + ;; +esac + + + +# Option defaults: +opt_debug=: +opt_dry_run=false +opt_config=false +opt_preserve_dup_deps=false +opt_features=false +opt_finish=false +opt_help=false +opt_help_all=false +opt_silent=: +opt_warning=: +opt_verbose=: +opt_silent=false +opt_verbose=false + + +# Parse options once, thoroughly. This comes as soon as possible in the +# script to make things like `--version' happen as quickly as we can. +{ + # this just eases exit handling + while test $# -gt 0; do + opt="$1" + shift + case $opt in + --debug|-x) opt_debug='set -x' + func_echo "enabling shell trace mode" + $opt_debug + ;; + --dry-run|--dryrun|-n) + opt_dry_run=: + ;; + --config) + opt_config=: +func_config + ;; + --dlopen|-dlopen) + optarg="$1" + opt_dlopen="${opt_dlopen+$opt_dlopen +}$optarg" + shift + ;; + --preserve-dup-deps) + opt_preserve_dup_deps=: + ;; + --features) + opt_features=: +func_features + ;; + --finish) + opt_finish=: +set dummy --mode finish ${1+"$@"}; shift + ;; + --help) + opt_help=: + ;; + --help-all) + opt_help_all=: +opt_help=': help-all' + ;; + --mode) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_mode="$optarg" +case $optarg in + # Valid mode arguments: + clean|compile|execute|finish|install|link|relink|uninstall) ;; + + # Catch anything else as an error + *) func_error "invalid argument for $opt" + exit_cmd=exit + break + ;; +esac + shift + ;; + --no-silent|--no-quiet) + opt_silent=false +func_append preserve_args " $opt" + ;; + --no-warning|--no-warn) + opt_warning=false +func_append preserve_args " $opt" + ;; + --no-verbose) + opt_verbose=false +func_append preserve_args " $opt" + ;; + --silent|--quiet) + opt_silent=: +func_append preserve_args " $opt" + opt_verbose=false + ;; + --verbose|-v) + opt_verbose=: +func_append preserve_args " $opt" +opt_silent=false + ;; + --tag) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_tag="$optarg" +func_append preserve_args " $opt $optarg" +func_enable_tag "$optarg" + shift + ;; + + -\?|-h) func_usage ;; + --help) func_help ;; + --version) func_version ;; + + # Separate optargs to long options: + --*=*) + func_split_long_opt "$opt" + set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"} + shift + ;; + + # Separate non-argument short options: + -\?*|-h*|-n*|-v*) + func_split_short_opt "$opt" + set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"} + shift + ;; + + --) break ;; + -*) func_fatal_help "unrecognized option \`$opt'" ;; + *) set dummy "$opt" ${1+"$@"}; shift; break ;; + esac + done + + # Validate options: + + # save first non-option argument + if test "$#" -gt 0; then + nonopt="$opt" + shift + fi + + # preserve --debug + test "$opt_debug" = : || func_append preserve_args " --debug" + + case $host in + *cygwin* | *mingw* | *pw32* | *cegcc*) + # don't eliminate duplications in $postdeps and $predeps + opt_duplicate_compiler_generated_deps=: + ;; + *) + opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps + ;; + esac + + $opt_help || { + # Sanity checks first: + func_check_version_match + + if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then + func_fatal_configuration "not configured to build any kind of library" + fi + + # Darwin sucks + eval std_shrext=\"$shrext_cmds\" + + # Only execute mode is allowed to have -dlopen flags. + if test -n "$opt_dlopen" && test "$opt_mode" != execute; then + func_error "unrecognized option \`-dlopen'" + $ECHO "$help" 1>&2 + exit $EXIT_FAILURE + fi + + # Change the help message to a mode-specific one. + generic_help="$help" + help="Try \`$progname --help --mode=$opt_mode' for more information." + } + + + # Bail if the options were screwed + $exit_cmd $EXIT_FAILURE +} + + + + +## ----------- ## +## Main. ## +## ----------- ## + +# func_lalib_p file +# True iff FILE is a libtool `.la' library or `.lo' object file. +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_lalib_p () +{ + test -f "$1" && + $SED -e 4q "$1" 2>/dev/null \ + | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 +} + +# func_lalib_unsafe_p file +# True iff FILE is a libtool `.la' library or `.lo' object file. +# This function implements the same check as func_lalib_p without +# resorting to external programs. To this end, it redirects stdin and +# closes it afterwards, without saving the original file descriptor. +# As a safety measure, use it only where a negative result would be +# fatal anyway. Works if `file' does not exist. +func_lalib_unsafe_p () +{ + lalib_p=no + if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then + for lalib_p_l in 1 2 3 4 + do + read lalib_p_line + case "$lalib_p_line" in + \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; + esac + done + exec 0<&5 5<&- + fi + test "$lalib_p" = yes +} + +# func_ltwrapper_script_p file +# True iff FILE is a libtool wrapper script +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_script_p () +{ + func_lalib_p "$1" +} + +# func_ltwrapper_executable_p file +# True iff FILE is a libtool wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_executable_p () +{ + func_ltwrapper_exec_suffix= + case $1 in + *.exe) ;; + *) func_ltwrapper_exec_suffix=.exe ;; + esac + $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 +} + +# func_ltwrapper_scriptname file +# Assumes file is an ltwrapper_executable +# uses $file to determine the appropriate filename for a +# temporary ltwrapper_script. +func_ltwrapper_scriptname () +{ + func_dirname_and_basename "$1" "" "." + func_stripname '' '.exe' "$func_basename_result" + func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" +} + +# func_ltwrapper_p file +# True iff FILE is a libtool wrapper script or wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_p () +{ + func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" +} + + +# func_execute_cmds commands fail_cmd +# Execute tilde-delimited COMMANDS. +# If FAIL_CMD is given, eval that upon failure. +# FAIL_CMD may read-access the current command in variable CMD! +func_execute_cmds () +{ + $opt_debug + save_ifs=$IFS; IFS='~' + for cmd in $1; do + IFS=$save_ifs + eval cmd=\"$cmd\" + func_show_eval "$cmd" "${2-:}" + done + IFS=$save_ifs +} + + +# func_source file +# Source FILE, adding directory component if necessary. +# Note that it is not necessary on cygwin/mingw to append a dot to +# FILE even if both FILE and FILE.exe exist: automatic-append-.exe +# behavior happens only for exec(3), not for open(2)! Also, sourcing +# `FILE.' does not work on cygwin managed mounts. +func_source () +{ + $opt_debug + case $1 in + */* | *\\*) . "$1" ;; + *) . "./$1" ;; + esac +} + + +# func_resolve_sysroot PATH +# Replace a leading = in PATH with a sysroot. Store the result into +# func_resolve_sysroot_result +func_resolve_sysroot () +{ + func_resolve_sysroot_result=$1 + case $func_resolve_sysroot_result in + =*) + func_stripname '=' '' "$func_resolve_sysroot_result" + func_resolve_sysroot_result=$lt_sysroot$func_stripname_result + ;; + esac +} + +# func_replace_sysroot PATH +# If PATH begins with the sysroot, replace it with = and +# store the result into func_replace_sysroot_result. +func_replace_sysroot () +{ + case "$lt_sysroot:$1" in + ?*:"$lt_sysroot"*) + func_stripname "$lt_sysroot" '' "$1" + func_replace_sysroot_result="=$func_stripname_result" + ;; + *) + # Including no sysroot. + func_replace_sysroot_result=$1 + ;; + esac +} + +# func_infer_tag arg +# Infer tagged configuration to use if any are available and +# if one wasn't chosen via the "--tag" command line option. +# Only attempt this if the compiler in the base compile +# command doesn't match the default compiler. +# arg is usually of the form 'gcc ...' +func_infer_tag () +{ + $opt_debug + if test -n "$available_tags" && test -z "$tagname"; then + CC_quoted= + for arg in $CC; do + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case $@ in + # Blanks in the command may have been stripped by the calling shell, + # but not from the CC environment variable when configure was run. + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; + # Blanks at the start of $base_compile will cause this to fail + # if we don't check for them as well. + *) + for z in $available_tags; do + if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then + # Evaluate the configuration. + eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" + CC_quoted= + for arg in $CC; do + # Double-quote args containing other shell metacharacters. + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case "$@ " in + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) + # The compiler in the base compile command matches + # the one in the tagged configuration. + # Assume this is the tagged configuration we want. + tagname=$z + break + ;; + esac + fi + done + # If $tagname still isn't set, then no tagged configuration + # was found and let the user know that the "--tag" command + # line option must be used. + if test -z "$tagname"; then + func_echo "unable to infer tagged configuration" + func_fatal_error "specify a tag with \`--tag'" +# else +# func_verbose "using $tagname tagged configuration" + fi + ;; + esac + fi +} + + + +# func_write_libtool_object output_name pic_name nonpic_name +# Create a libtool object file (analogous to a ".la" file), +# but don't create it if we're doing a dry run. +func_write_libtool_object () +{ + write_libobj=${1} + if test "$build_libtool_libs" = yes; then + write_lobj=\'${2}\' + else + write_lobj=none + fi + + if test "$build_old_libs" = yes; then + write_oldobj=\'${3}\' + else + write_oldobj=none + fi + + $opt_dry_run || { + cat >${write_libobj}T </dev/null` + if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then + func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | + $SED -e "$lt_sed_naive_backslashify"` + else + func_convert_core_file_wine_to_w32_result= + fi + fi +} +# end: func_convert_core_file_wine_to_w32 + + +# func_convert_core_path_wine_to_w32 ARG +# Helper function used by path conversion functions when $build is *nix, and +# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly +# configured wine environment available, with the winepath program in $build's +# $PATH. Assumes ARG has no leading or trailing path separator characters. +# +# ARG is path to be converted from $build format to win32. +# Result is available in $func_convert_core_path_wine_to_w32_result. +# Unconvertible file (directory) names in ARG are skipped; if no directory names +# are convertible, then the result may be empty. +func_convert_core_path_wine_to_w32 () +{ + $opt_debug + # unfortunately, winepath doesn't convert paths, only file names + func_convert_core_path_wine_to_w32_result="" + if test -n "$1"; then + oldIFS=$IFS + IFS=: + for func_convert_core_path_wine_to_w32_f in $1; do + IFS=$oldIFS + func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" + if test -n "$func_convert_core_file_wine_to_w32_result" ; then + if test -z "$func_convert_core_path_wine_to_w32_result"; then + func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" + else + func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" + fi + fi + done + IFS=$oldIFS + fi +} +# end: func_convert_core_path_wine_to_w32 + + +# func_cygpath ARGS... +# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when +# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) +# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or +# (2), returns the Cygwin file name or path in func_cygpath_result (input +# file name or path is assumed to be in w32 format, as previously converted +# from $build's *nix or MSYS format). In case (3), returns the w32 file name +# or path in func_cygpath_result (input file name or path is assumed to be in +# Cygwin format). Returns an empty string on error. +# +# ARGS are passed to cygpath, with the last one being the file name or path to +# be converted. +# +# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH +# environment variable; do not put it in $PATH. +func_cygpath () +{ + $opt_debug + if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then + func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` + if test "$?" -ne 0; then + # on failure, ensure result is empty + func_cygpath_result= + fi + else + func_cygpath_result= + func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" + fi +} +#end: func_cygpath + + +# func_convert_core_msys_to_w32 ARG +# Convert file name or path ARG from MSYS format to w32 format. Return +# result in func_convert_core_msys_to_w32_result. +func_convert_core_msys_to_w32 () +{ + $opt_debug + # awkward: cmd appends spaces to result + func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | + $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` +} +#end: func_convert_core_msys_to_w32 + + +# func_convert_file_check ARG1 ARG2 +# Verify that ARG1 (a file name in $build format) was converted to $host +# format in ARG2. Otherwise, emit an error message, but continue (resetting +# func_to_host_file_result to ARG1). +func_convert_file_check () +{ + $opt_debug + if test -z "$2" && test -n "$1" ; then + func_error "Could not determine host file name corresponding to" + func_error " \`$1'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback: + func_to_host_file_result="$1" + fi +} +# end func_convert_file_check + + +# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH +# Verify that FROM_PATH (a path in $build format) was converted to $host +# format in TO_PATH. Otherwise, emit an error message, but continue, resetting +# func_to_host_file_result to a simplistic fallback value (see below). +func_convert_path_check () +{ + $opt_debug + if test -z "$4" && test -n "$3"; then + func_error "Could not determine the host path corresponding to" + func_error " \`$3'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback. This is a deliberately simplistic "conversion" and + # should not be "improved". See libtool.info. + if test "x$1" != "x$2"; then + lt_replace_pathsep_chars="s|$1|$2|g" + func_to_host_path_result=`echo "$3" | + $SED -e "$lt_replace_pathsep_chars"` + else + func_to_host_path_result="$3" + fi + fi +} +# end func_convert_path_check + + +# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG +# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT +# and appending REPL if ORIG matches BACKPAT. +func_convert_path_front_back_pathsep () +{ + $opt_debug + case $4 in + $1 ) func_to_host_path_result="$3$func_to_host_path_result" + ;; + esac + case $4 in + $2 ) func_append func_to_host_path_result "$3" + ;; + esac +} +# end func_convert_path_front_back_pathsep + + +################################################## +# $build to $host FILE NAME CONVERSION FUNCTIONS # +################################################## +# invoked via `$to_host_file_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# Result will be available in $func_to_host_file_result. + + +# func_to_host_file ARG +# Converts the file name ARG from $build format to $host format. Return result +# in func_to_host_file_result. +func_to_host_file () +{ + $opt_debug + $to_host_file_cmd "$1" +} +# end func_to_host_file + + +# func_to_tool_file ARG LAZY +# converts the file name ARG from $build format to toolchain format. Return +# result in func_to_tool_file_result. If the conversion in use is listed +# in (the comma separated) LAZY, no conversion takes place. +func_to_tool_file () +{ + $opt_debug + case ,$2, in + *,"$to_tool_file_cmd",*) + func_to_tool_file_result=$1 + ;; + *) + $to_tool_file_cmd "$1" + func_to_tool_file_result=$func_to_host_file_result + ;; + esac +} +# end func_to_tool_file + + +# func_convert_file_noop ARG +# Copy ARG to func_to_host_file_result. +func_convert_file_noop () +{ + func_to_host_file_result="$1" +} +# end func_convert_file_noop + + +# func_convert_file_msys_to_w32 ARG +# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_file_result. +func_convert_file_msys_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_to_host_file_result="$func_convert_core_msys_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_w32 + + +# func_convert_file_cygwin_to_w32 ARG +# Convert file name ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_file_cygwin_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # because $build is cygwin, we call "the" cygpath in $PATH; no need to use + # LT_CYGPATH in this case. + func_to_host_file_result=`cygpath -m "$1"` + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_cygwin_to_w32 + + +# func_convert_file_nix_to_w32 ARG +# Convert file name ARG from *nix to w32 format. Requires a wine environment +# and a working winepath. Returns result in func_to_host_file_result. +func_convert_file_nix_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_file_wine_to_w32 "$1" + func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_w32 + + +# func_convert_file_msys_to_cygwin ARG +# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_file_msys_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_cygpath -u "$func_convert_core_msys_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_cygwin + + +# func_convert_file_nix_to_cygwin ARG +# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed +# in a wine environment, working winepath, and LT_CYGPATH set. Returns result +# in func_to_host_file_result. +func_convert_file_nix_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. + func_convert_core_file_wine_to_w32 "$1" + func_cygpath -u "$func_convert_core_file_wine_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_cygwin + + +############################################# +# $build to $host PATH CONVERSION FUNCTIONS # +############################################# +# invoked via `$to_host_path_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# The result will be available in $func_to_host_path_result. +# +# Path separators are also converted from $build format to $host format. If +# ARG begins or ends with a path separator character, it is preserved (but +# converted to $host format) on output. +# +# All path conversion functions are named using the following convention: +# file name conversion function : func_convert_file_X_to_Y () +# path conversion function : func_convert_path_X_to_Y () +# where, for any given $build/$host combination the 'X_to_Y' value is the +# same. If conversion functions are added for new $build/$host combinations, +# the two new functions must follow this pattern, or func_init_to_host_path_cmd +# will break. + + +# func_init_to_host_path_cmd +# Ensures that function "pointer" variable $to_host_path_cmd is set to the +# appropriate value, based on the value of $to_host_file_cmd. +to_host_path_cmd= +func_init_to_host_path_cmd () +{ + $opt_debug + if test -z "$to_host_path_cmd"; then + func_stripname 'func_convert_file_' '' "$to_host_file_cmd" + to_host_path_cmd="func_convert_path_${func_stripname_result}" + fi +} + + +# func_to_host_path ARG +# Converts the path ARG from $build format to $host format. Return result +# in func_to_host_path_result. +func_to_host_path () +{ + $opt_debug + func_init_to_host_path_cmd + $to_host_path_cmd "$1" +} +# end func_to_host_path + + +# func_convert_path_noop ARG +# Copy ARG to func_to_host_path_result. +func_convert_path_noop () +{ + func_to_host_path_result="$1" +} +# end func_convert_path_noop + + +# func_convert_path_msys_to_w32 ARG +# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_path_result. +func_convert_path_msys_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # Remove leading and trailing path separator characters from ARG. MSYS + # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; + # and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result="$func_convert_core_msys_to_w32_result" + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_msys_to_w32 + + +# func_convert_path_cygwin_to_w32 ARG +# Convert path ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_path_cygwin_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_cygwin_to_w32 + + +# func_convert_path_nix_to_w32 ARG +# Convert path ARG from *nix to w32 format. Requires a wine environment and +# a working winepath. Returns result in func_to_host_file_result. +func_convert_path_nix_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result="$func_convert_core_path_wine_to_w32_result" + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_nix_to_w32 + + +# func_convert_path_msys_to_cygwin ARG +# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_path_msys_to_cygwin () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_msys_to_w32_result" + func_to_host_path_result="$func_cygpath_result" + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_msys_to_cygwin + + +# func_convert_path_nix_to_cygwin ARG +# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a +# a wine environment, working winepath, and LT_CYGPATH set. Returns result in +# func_to_host_file_result. +func_convert_path_nix_to_cygwin () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # Remove leading and trailing path separator characters from + # ARG. msys behavior is inconsistent here, cygpath turns them + # into '.;' and ';.', and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" + func_to_host_path_result="$func_cygpath_result" + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_nix_to_cygwin + + +# func_mode_compile arg... +func_mode_compile () +{ + $opt_debug + # Get the compilation command and the source file. + base_compile= + srcfile="$nonopt" # always keep a non-empty value in "srcfile" + suppress_opt=yes + suppress_output= + arg_mode=normal + libobj= + later= + pie_flag= + + for arg + do + case $arg_mode in + arg ) + # do not "continue". Instead, add this to base_compile + lastarg="$arg" + arg_mode=normal + ;; + + target ) + libobj="$arg" + arg_mode=normal + continue + ;; + + normal ) + # Accept any command-line options. + case $arg in + -o) + test -n "$libobj" && \ + func_fatal_error "you cannot specify \`-o' more than once" + arg_mode=target + continue + ;; + + -pie | -fpie | -fPIE) + func_append pie_flag " $arg" + continue + ;; + + -shared | -static | -prefer-pic | -prefer-non-pic) + func_append later " $arg" + continue + ;; + + -no-suppress) + suppress_opt=no + continue + ;; + + -Xcompiler) + arg_mode=arg # the next one goes into the "base_compile" arg list + continue # The current "srcfile" will either be retained or + ;; # replaced later. I would guess that would be a bug. + + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + lastarg= + save_ifs="$IFS"; IFS=',' + for arg in $args; do + IFS="$save_ifs" + func_append_quoted lastarg "$arg" + done + IFS="$save_ifs" + func_stripname ' ' '' "$lastarg" + lastarg=$func_stripname_result + + # Add the arguments to base_compile. + func_append base_compile " $lastarg" + continue + ;; + + *) + # Accept the current argument as the source file. + # The previous "srcfile" becomes the current argument. + # + lastarg="$srcfile" + srcfile="$arg" + ;; + esac # case $arg + ;; + esac # case $arg_mode + + # Aesthetically quote the previous argument. + func_append_quoted base_compile "$lastarg" + done # for arg + + case $arg_mode in + arg) + func_fatal_error "you must specify an argument for -Xcompile" + ;; + target) + func_fatal_error "you must specify a target with \`-o'" + ;; + *) + # Get the name of the library object. + test -z "$libobj" && { + func_basename "$srcfile" + libobj="$func_basename_result" + } + ;; + esac + + # Recognize several different file suffixes. + # If the user specifies -o file.o, it is replaced with file.lo + case $libobj in + *.[cCFSifmso] | \ + *.ada | *.adb | *.ads | *.asm | \ + *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ + *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) + func_xform "$libobj" + libobj=$func_xform_result + ;; + esac + + case $libobj in + *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; + *) + func_fatal_error "cannot determine name of library object from \`$libobj'" + ;; + esac + + func_infer_tag $base_compile + + for arg in $later; do + case $arg in + -shared) + test "$build_libtool_libs" != yes && \ + func_fatal_configuration "can not build a shared library" + build_old_libs=no + continue + ;; + + -static) + build_libtool_libs=no + build_old_libs=yes + continue + ;; + + -prefer-pic) + pic_mode=yes + continue + ;; + + -prefer-non-pic) + pic_mode=no + continue + ;; + esac + done + + func_quote_for_eval "$libobj" + test "X$libobj" != "X$func_quote_for_eval_result" \ + && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ + && func_warning "libobj name \`$libobj' may not contain shell special characters." + func_dirname_and_basename "$obj" "/" "" + objname="$func_basename_result" + xdir="$func_dirname_result" + lobj=${xdir}$objdir/$objname + + test -z "$base_compile" && \ + func_fatal_help "you must specify a compilation command" + + # Delete any leftover library objects. + if test "$build_old_libs" = yes; then + removelist="$obj $lobj $libobj ${libobj}T" + else + removelist="$lobj $libobj ${libobj}T" + fi + + # On Cygwin there's no "real" PIC flag so we must build both object types + case $host_os in + cygwin* | mingw* | pw32* | os2* | cegcc*) + pic_mode=default + ;; + esac + if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then + # non-PIC code in shared libraries is not supported + pic_mode=default + fi + + # Calculate the filename of the output object if compiler does + # not support -o with -c + if test "$compiler_c_o" = no; then + output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext} + lockfile="$output_obj.lock" + else + output_obj= + need_locks=no + lockfile= + fi + + # Lock this critical section if it is needed + # We use this script file to make the link, it avoids creating a new file + if test "$need_locks" = yes; then + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + elif test "$need_locks" = warn; then + if test -f "$lockfile"; then + $ECHO "\ +*** ERROR, $lockfile exists and contains: +`cat $lockfile 2>/dev/null` + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + func_append removelist " $output_obj" + $ECHO "$srcfile" > "$lockfile" + fi + + $opt_dry_run || $RM $removelist + func_append removelist " $lockfile" + trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 + + func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 + srcfile=$func_to_tool_file_result + func_quote_for_eval "$srcfile" + qsrcfile=$func_quote_for_eval_result + + # Only build a PIC object if we are building libtool libraries. + if test "$build_libtool_libs" = yes; then + # Without this assignment, base_compile gets emptied. + fbsd_hideous_sh_bug=$base_compile + + if test "$pic_mode" != no; then + command="$base_compile $qsrcfile $pic_flag" + else + # Don't build PIC code + command="$base_compile $qsrcfile" + fi + + func_mkdir_p "$xdir$objdir" + + if test -z "$output_obj"; then + # Place PIC objects in $objdir + func_append command " -o $lobj" + fi + + func_show_eval_locale "$command" \ + 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' + + if test "$need_locks" = warn && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` + +but it should contain: +$srcfile + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + + # Just move the object if needed, then go on to compile the next one + if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then + func_show_eval '$MV "$output_obj" "$lobj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + fi + + # Allow error messages only from the first compilation. + if test "$suppress_opt" = yes; then + suppress_output=' >/dev/null 2>&1' + fi + fi + + # Only build a position-dependent object if we build old libraries. + if test "$build_old_libs" = yes; then + if test "$pic_mode" != yes; then + # Don't build PIC code + command="$base_compile $qsrcfile$pie_flag" + else + command="$base_compile $qsrcfile $pic_flag" + fi + if test "$compiler_c_o" = yes; then + func_append command " -o $obj" + fi + + # Suppress compiler output if we already did a PIC compilation. + func_append command "$suppress_output" + func_show_eval_locale "$command" \ + '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' + + if test "$need_locks" = warn && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` + +but it should contain: +$srcfile + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support \`-c' and \`-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + + # Just move the object if needed + if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then + func_show_eval '$MV "$output_obj" "$obj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + fi + fi + + $opt_dry_run || { + func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" + + # Unlock the critical section if it was locked + if test "$need_locks" != no; then + removelist=$lockfile + $RM "$lockfile" + fi + } + + exit $EXIT_SUCCESS +} + +$opt_help || { + test "$opt_mode" = compile && func_mode_compile ${1+"$@"} +} + +func_mode_help () +{ + # We need to display help for each of the modes. + case $opt_mode in + "") + # Generic help is extracted from the usage comments + # at the start of this file. + func_help + ;; + + clean) + $ECHO \ +"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... + +Remove files from the build directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. + +If FILE is a libtool library, object or program, all the files associated +with it are deleted. Otherwise, only FILE itself is deleted using RM." + ;; + + compile) + $ECHO \ +"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE + +Compile a source file into a libtool library object. + +This mode accepts the following additional options: + + -o OUTPUT-FILE set the output file name to OUTPUT-FILE + -no-suppress do not suppress compiler output for multiple passes + -prefer-pic try to build PIC objects only + -prefer-non-pic try to build non-PIC objects only + -shared do not build a \`.o' file suitable for static linking + -static only build a \`.o' file suitable for static linking + -Wc,FLAG pass FLAG directly to the compiler + +COMPILE-COMMAND is a command to be used in creating a \`standard' object file +from the given SOURCEFILE. + +The output file name is determined by removing the directory component from +SOURCEFILE, then substituting the C source code suffix \`.c' with the +library object suffix, \`.lo'." + ;; + + execute) + $ECHO \ +"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... + +Automatically set library path, then run a program. + +This mode accepts the following additional options: + + -dlopen FILE add the directory containing FILE to the library path + +This mode sets the library path environment variable according to \`-dlopen' +flags. + +If any of the ARGS are libtool executable wrappers, then they are translated +into their corresponding uninstalled binary, and any of their required library +directories are added to the library path. + +Then, COMMAND is executed, with ARGS as arguments." + ;; + + finish) + $ECHO \ +"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... + +Complete the installation of libtool libraries. + +Each LIBDIR is a directory that contains libtool libraries. + +The commands that this mode executes may require superuser privileges. Use +the \`--dry-run' option if you just want to see what would be executed." + ;; + + install) + $ECHO \ +"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... + +Install executables or libraries. + +INSTALL-COMMAND is the installation command. The first component should be +either the \`install' or \`cp' program. + +The following components of INSTALL-COMMAND are treated specially: + + -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation + +The rest of the components are interpreted as arguments to that command (only +BSD-compatible install options are recognized)." + ;; + + link) + $ECHO \ +"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... + +Link object files or libraries together to form another library, or to +create an executable program. + +LINK-COMMAND is a command using the C compiler that you would use to create +a program from several object files. + +The following components of LINK-COMMAND are treated specially: + + -all-static do not do any dynamic linking at all + -avoid-version do not add a version suffix if possible + -bindir BINDIR specify path to binaries directory (for systems where + libraries must be found in the PATH setting at runtime) + -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime + -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols + -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) + -export-symbols SYMFILE + try to export only the symbols listed in SYMFILE + -export-symbols-regex REGEX + try to export only the symbols matching REGEX + -LLIBDIR search LIBDIR for required installed libraries + -lNAME OUTPUT-FILE requires the installed library libNAME + -module build a library that can dlopened + -no-fast-install disable the fast-install mode + -no-install link a not-installable executable + -no-undefined declare that a library does not refer to external symbols + -o OUTPUT-FILE create OUTPUT-FILE from the specified objects + -objectlist FILE Use a list of object files found in FILE to specify objects + -precious-files-regex REGEX + don't remove output files matching REGEX + -release RELEASE specify package release information + -rpath LIBDIR the created library will eventually be installed in LIBDIR + -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries + -shared only do dynamic linking of libtool libraries + -shrext SUFFIX override the standard shared library file extension + -static do not do any dynamic linking of uninstalled libtool libraries + -static-libtool-libs + do not do any dynamic linking of libtool libraries + -version-info CURRENT[:REVISION[:AGE]] + specify library version info [each variable defaults to 0] + -weak LIBNAME declare that the target provides the LIBNAME interface + -Wc,FLAG + -Xcompiler FLAG pass linker-specific FLAG directly to the compiler + -Wl,FLAG + -Xlinker FLAG pass linker-specific FLAG directly to the linker + -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) + +All other options (arguments beginning with \`-') are ignored. + +Every other argument is treated as a filename. Files ending in \`.la' are +treated as uninstalled libtool libraries, other files are standard or library +object files. + +If the OUTPUT-FILE ends in \`.la', then a libtool library is created, +only library objects (\`.lo' files) may be specified, and \`-rpath' is +required, except when creating a convenience library. + +If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created +using \`ar' and \`ranlib', or on Windows using \`lib'. + +If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file +is created, otherwise an executable program is created." + ;; + + uninstall) + $ECHO \ +"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... + +Remove libraries from an installation directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. + +If FILE is a libtool library, all the files associated with it are deleted. +Otherwise, only FILE itself is deleted using RM." + ;; + + *) + func_fatal_help "invalid operation mode \`$opt_mode'" + ;; + esac + + echo + $ECHO "Try \`$progname --help' for more information about other modes." +} + +# Now that we've collected a possible --mode arg, show help if necessary +if $opt_help; then + if test "$opt_help" = :; then + func_mode_help + else + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + func_mode_help + done + } | sed -n '1p; 2,$s/^Usage:/ or: /p' + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + echo + func_mode_help + done + } | + sed '1d + /^When reporting/,/^Report/{ + H + d + } + $x + /information about other modes/d + /more detailed .*MODE/d + s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' + fi + exit $? +fi + + +# func_mode_execute arg... +func_mode_execute () +{ + $opt_debug + # The first argument is the command name. + cmd="$nonopt" + test -z "$cmd" && \ + func_fatal_help "you must specify a COMMAND" + + # Handle -dlopen flags immediately. + for file in $opt_dlopen; do + test -f "$file" \ + || func_fatal_help "\`$file' is not a file" + + dir= + case $file in + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "\`$lib' is not a valid libtool archive" + + # Read the libtool library. + dlname= + library_names= + func_source "$file" + + # Skip this library if it cannot be dlopened. + if test -z "$dlname"; then + # Warn if it was a shared library. + test -n "$library_names" && \ + func_warning "\`$file' was not linked with \`-export-dynamic'" + continue + fi + + func_dirname "$file" "" "." + dir="$func_dirname_result" + + if test -f "$dir/$objdir/$dlname"; then + func_append dir "/$objdir" + else + if test ! -f "$dir/$dlname"; then + func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" + fi + fi + ;; + + *.lo) + # Just add the directory containing the .lo file. + func_dirname "$file" "" "." + dir="$func_dirname_result" + ;; + + *) + func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" + continue + ;; + esac + + # Get the absolute pathname. + absdir=`cd "$dir" && pwd` + test -n "$absdir" && dir="$absdir" + + # Now add the directory to shlibpath_var. + if eval "test -z \"\$$shlibpath_var\""; then + eval "$shlibpath_var=\"\$dir\"" + else + eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" + fi + done + + # This variable tells wrapper scripts just to set shlibpath_var + # rather than running their programs. + libtool_execute_magic="$magic" + + # Check if any of the arguments is a wrapper script. + args= + for file + do + case $file in + -* | *.la | *.lo ) ;; + *) + # Do a test to see if this is really a libtool program. + if func_ltwrapper_script_p "$file"; then + func_source "$file" + # Transform arg to wrapped name. + file="$progdir/$program" + elif func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + func_source "$func_ltwrapper_scriptname_result" + # Transform arg to wrapped name. + file="$progdir/$program" + fi + ;; + esac + # Quote arguments (to preserve shell metacharacters). + func_append_quoted args "$file" + done + + if test "X$opt_dry_run" = Xfalse; then + if test -n "$shlibpath_var"; then + # Export the shlibpath_var. + eval "export $shlibpath_var" + fi + + # Restore saved environment variables + for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES + do + eval "if test \"\${save_$lt_var+set}\" = set; then + $lt_var=\$save_$lt_var; export $lt_var + else + $lt_unset $lt_var + fi" + done + + # Now prepare to actually exec the command. + exec_cmd="\$cmd$args" + else + # Display what would be done. + if test -n "$shlibpath_var"; then + eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" + echo "export $shlibpath_var" + fi + $ECHO "$cmd$args" + exit $EXIT_SUCCESS + fi +} + +test "$opt_mode" = execute && func_mode_execute ${1+"$@"} + + +# func_mode_finish arg... +func_mode_finish () +{ + $opt_debug + libs= + libdirs= + admincmds= + + for opt in "$nonopt" ${1+"$@"} + do + if test -d "$opt"; then + func_append libdirs " $opt" + + elif test -f "$opt"; then + if func_lalib_unsafe_p "$opt"; then + func_append libs " $opt" + else + func_warning "\`$opt' is not a valid libtool archive" + fi + + else + func_fatal_error "invalid argument \`$opt'" + fi + done + + if test -n "$libs"; then + if test -n "$lt_sysroot"; then + sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` + sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" + else + sysroot_cmd= + fi + + # Remove sysroot references + if $opt_dry_run; then + for lib in $libs; do + echo "removing references to $lt_sysroot and \`=' prefixes from $lib" + done + else + tmpdir=`func_mktempdir` + for lib in $libs; do + sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ + > $tmpdir/tmp-la + mv -f $tmpdir/tmp-la $lib + done + ${RM}r "$tmpdir" + fi + fi + + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + for libdir in $libdirs; do + if test -n "$finish_cmds"; then + # Do each command in the finish commands. + func_execute_cmds "$finish_cmds" 'admincmds="$admincmds +'"$cmd"'"' + fi + if test -n "$finish_eval"; then + # Do the single finish_eval. + eval cmds=\"$finish_eval\" + $opt_dry_run || eval "$cmds" || func_append admincmds " + $cmds" + fi + done + fi + + # Exit here if they wanted silent mode. + $opt_silent && exit $EXIT_SUCCESS + + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + echo "----------------------------------------------------------------------" + echo "Libraries have been installed in:" + for libdir in $libdirs; do + $ECHO " $libdir" + done + echo + echo "If you ever happen to want to link against installed libraries" + echo "in a given directory, LIBDIR, you must either use libtool, and" + echo "specify the full pathname of the library, or use the \`-LLIBDIR'" + echo "flag during linking and do at least one of the following:" + if test -n "$shlibpath_var"; then + echo " - add LIBDIR to the \`$shlibpath_var' environment variable" + echo " during execution" + fi + if test -n "$runpath_var"; then + echo " - add LIBDIR to the \`$runpath_var' environment variable" + echo " during linking" + fi + if test -n "$hardcode_libdir_flag_spec"; then + libdir=LIBDIR + eval flag=\"$hardcode_libdir_flag_spec\" + + $ECHO " - use the \`$flag' linker flag" + fi + if test -n "$admincmds"; then + $ECHO " - have your system administrator run these commands:$admincmds" + fi + if test -f /etc/ld.so.conf; then + echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" + fi + echo + + echo "See any operating system documentation about shared libraries for" + case $host in + solaris2.[6789]|solaris2.1[0-9]) + echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" + echo "pages." + ;; + *) + echo "more information, such as the ld(1) and ld.so(8) manual pages." + ;; + esac + echo "----------------------------------------------------------------------" + fi + exit $EXIT_SUCCESS +} + +test "$opt_mode" = finish && func_mode_finish ${1+"$@"} + + +# func_mode_install arg... +func_mode_install () +{ + $opt_debug + # There may be an optional sh(1) argument at the beginning of + # install_prog (especially on Windows NT). + if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || + # Allow the use of GNU shtool's install command. + case $nonopt in *shtool*) :;; *) false;; esac; then + # Aesthetically quote it. + func_quote_for_eval "$nonopt" + install_prog="$func_quote_for_eval_result " + arg=$1 + shift + else + install_prog= + arg=$nonopt + fi + + # The real first argument should be the name of the installation program. + # Aesthetically quote it. + func_quote_for_eval "$arg" + func_append install_prog "$func_quote_for_eval_result" + install_shared_prog=$install_prog + case " $install_prog " in + *[\\\ /]cp\ *) install_cp=: ;; + *) install_cp=false ;; + esac + + # We need to accept at least all the BSD install flags. + dest= + files= + opts= + prev= + install_type= + isdir=no + stripme= + no_mode=: + for arg + do + arg2= + if test -n "$dest"; then + func_append files " $dest" + dest=$arg + continue + fi + + case $arg in + -d) isdir=yes ;; + -f) + if $install_cp; then :; else + prev=$arg + fi + ;; + -g | -m | -o) + prev=$arg + ;; + -s) + stripme=" -s" + continue + ;; + -*) + ;; + *) + # If the previous option needed an argument, then skip it. + if test -n "$prev"; then + if test "x$prev" = x-m && test -n "$install_override_mode"; then + arg2=$install_override_mode + no_mode=false + fi + prev= + else + dest=$arg + continue + fi + ;; + esac + + # Aesthetically quote the argument. + func_quote_for_eval "$arg" + func_append install_prog " $func_quote_for_eval_result" + if test -n "$arg2"; then + func_quote_for_eval "$arg2" + fi + func_append install_shared_prog " $func_quote_for_eval_result" + done + + test -z "$install_prog" && \ + func_fatal_help "you must specify an install program" + + test -n "$prev" && \ + func_fatal_help "the \`$prev' option requires an argument" + + if test -n "$install_override_mode" && $no_mode; then + if $install_cp; then :; else + func_quote_for_eval "$install_override_mode" + func_append install_shared_prog " -m $func_quote_for_eval_result" + fi + fi + + if test -z "$files"; then + if test -z "$dest"; then + func_fatal_help "no file or destination specified" + else + func_fatal_help "you must specify a destination" + fi + fi + + # Strip any trailing slash from the destination. + func_stripname '' '/' "$dest" + dest=$func_stripname_result + + # Check to see that the destination is a directory. + test -d "$dest" && isdir=yes + if test "$isdir" = yes; then + destdir="$dest" + destname= + else + func_dirname_and_basename "$dest" "" "." + destdir="$func_dirname_result" + destname="$func_basename_result" + + # Not a directory, so check to see that there is only one file specified. + set dummy $files; shift + test "$#" -gt 1 && \ + func_fatal_help "\`$dest' is not a directory" + fi + case $destdir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + for file in $files; do + case $file in + *.lo) ;; + *) + func_fatal_help "\`$destdir' must be an absolute directory name" + ;; + esac + done + ;; + esac + + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic="$magic" + + staticlibs= + future_libdirs= + current_libdirs= + for file in $files; do + + # Do each installation. + case $file in + *.$libext) + # Do the static libraries later. + func_append staticlibs " $file" + ;; + + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "\`$file' is not a valid libtool archive" + + library_names= + old_library= + relink_command= + func_source "$file" + + # Add the libdir to current_libdirs if it is the destination. + if test "X$destdir" = "X$libdir"; then + case "$current_libdirs " in + *" $libdir "*) ;; + *) func_append current_libdirs " $libdir" ;; + esac + else + # Note the libdir as a future libdir. + case "$future_libdirs " in + *" $libdir "*) ;; + *) func_append future_libdirs " $libdir" ;; + esac + fi + + func_dirname "$file" "/" "" + dir="$func_dirname_result" + func_append dir "$objdir" + + if test -n "$relink_command"; then + # Determine the prefix the user has applied to our future dir. + inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` + + # Don't allow the user to place us outside of our expected + # location b/c this prevents finding dependent libraries that + # are installed to the same prefix. + # At present, this check doesn't affect windows .dll's that + # are installed into $libdir/../bin (currently, that works fine) + # but it's something to keep an eye on. + test "$inst_prefix_dir" = "$destdir" && \ + func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir" + + if test -n "$inst_prefix_dir"; then + # Stick the inst_prefix_dir data into the link command. + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` + else + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` + fi + + func_warning "relinking \`$file'" + func_show_eval "$relink_command" \ + 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' + fi + + # See the names of the shared library. + set dummy $library_names; shift + if test -n "$1"; then + realname="$1" + shift + + srcname="$realname" + test -n "$relink_command" && srcname="$realname"T + + # Install the shared library and build the symlinks. + func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ + 'exit $?' + tstripme="$stripme" + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + case $realname in + *.dll.a) + tstripme="" + ;; + esac + ;; + esac + if test -n "$tstripme" && test -n "$striplib"; then + func_show_eval "$striplib $destdir/$realname" 'exit $?' + fi + + if test "$#" -gt 0; then + # Delete the old symlinks, and create new ones. + # Try `ln -sf' first, because the `ln' binary might depend on + # the symlink we replace! Solaris /bin/ln does not understand -f, + # so we also need to try rm && ln -s. + for linkname + do + test "$linkname" != "$realname" \ + && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" + done + fi + + # Do each command in the postinstall commands. + lib="$destdir/$realname" + func_execute_cmds "$postinstall_cmds" 'exit $?' + fi + + # Install the pseudo-library for information purposes. + func_basename "$file" + name="$func_basename_result" + instname="$dir/$name"i + func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' + + # Maybe install the static library, too. + test -n "$old_library" && func_append staticlibs " $dir/$old_library" + ;; + + *.lo) + # Install (i.e. copy) a libtool object. + + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" + else + func_basename "$file" + destfile="$func_basename_result" + destfile="$destdir/$destfile" + fi + + # Deduce the name of the destination old-style object file. + case $destfile in + *.lo) + func_lo2o "$destfile" + staticdest=$func_lo2o_result + ;; + *.$objext) + staticdest="$destfile" + destfile= + ;; + *) + func_fatal_help "cannot copy a libtool object to \`$destfile'" + ;; + esac + + # Install the libtool object if requested. + test -n "$destfile" && \ + func_show_eval "$install_prog $file $destfile" 'exit $?' + + # Install the old object if enabled. + if test "$build_old_libs" = yes; then + # Deduce the name of the old-style object file. + func_lo2o "$file" + staticobj=$func_lo2o_result + func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' + fi + exit $EXIT_SUCCESS + ;; + + *) + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" + else + func_basename "$file" + destfile="$func_basename_result" + destfile="$destdir/$destfile" + fi + + # If the file is missing, and there is a .exe on the end, strip it + # because it is most likely a libtool script we actually want to + # install + stripped_ext="" + case $file in + *.exe) + if test ! -f "$file"; then + func_stripname '' '.exe' "$file" + file=$func_stripname_result + stripped_ext=".exe" + fi + ;; + esac + + # Do a test to see if this is really a libtool program. + case $host in + *cygwin* | *mingw*) + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + wrapper=$func_ltwrapper_scriptname_result + else + func_stripname '' '.exe' "$file" + wrapper=$func_stripname_result + fi + ;; + *) + wrapper=$file + ;; + esac + if func_ltwrapper_script_p "$wrapper"; then + notinst_deplibs= + relink_command= + + func_source "$wrapper" + + # Check the variables that should have been set. + test -z "$generated_by_libtool_version" && \ + func_fatal_error "invalid libtool wrapper script \`$wrapper'" + + finalize=yes + for lib in $notinst_deplibs; do + # Check to see that each library is installed. + libdir= + if test -f "$lib"; then + func_source "$lib" + fi + libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test + if test -n "$libdir" && test ! -f "$libfile"; then + func_warning "\`$lib' has not been installed in \`$libdir'" + finalize=no + fi + done + + relink_command= + func_source "$wrapper" + + outputname= + if test "$fast_install" = no && test -n "$relink_command"; then + $opt_dry_run || { + if test "$finalize" = yes; then + tmpdir=`func_mktempdir` + func_basename "$file$stripped_ext" + file="$func_basename_result" + outputname="$tmpdir/$file" + # Replace the output file specification. + relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` + + $opt_silent || { + func_quote_for_expand "$relink_command" + eval "func_echo $func_quote_for_expand_result" + } + if eval "$relink_command"; then : + else + func_error "error: relink \`$file' with the above command before installing it" + $opt_dry_run || ${RM}r "$tmpdir" + continue + fi + file="$outputname" + else + func_warning "cannot relink \`$file'" + fi + } + else + # Install the binary that we compiled earlier. + file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` + fi + fi + + # remove .exe since cygwin /usr/bin/install will append another + # one anyway + case $install_prog,$host in + */usr/bin/install*,*cygwin*) + case $file:$destfile in + *.exe:*.exe) + # this is ok + ;; + *.exe:*) + destfile=$destfile.exe + ;; + *:*.exe) + func_stripname '' '.exe' "$destfile" + destfile=$func_stripname_result + ;; + esac + ;; + esac + func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' + $opt_dry_run || if test -n "$outputname"; then + ${RM}r "$tmpdir" + fi + ;; + esac + done + + for file in $staticlibs; do + func_basename "$file" + name="$func_basename_result" + + # Set up the ranlib parameters. + oldlib="$destdir/$name" + func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 + tool_oldlib=$func_to_tool_file_result + + func_show_eval "$install_prog \$file \$oldlib" 'exit $?' + + if test -n "$stripme" && test -n "$old_striplib"; then + func_show_eval "$old_striplib $tool_oldlib" 'exit $?' + fi + + # Do each command in the postinstall commands. + func_execute_cmds "$old_postinstall_cmds" 'exit $?' + done + + test -n "$future_libdirs" && \ + func_warning "remember to run \`$progname --finish$future_libdirs'" + + if test -n "$current_libdirs"; then + # Maybe just do a dry run. + $opt_dry_run && current_libdirs=" -n$current_libdirs" + exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' + else + exit $EXIT_SUCCESS + fi +} + +test "$opt_mode" = install && func_mode_install ${1+"$@"} + + +# func_generate_dlsyms outputname originator pic_p +# Extract symbols from dlprefiles and create ${outputname}S.o with +# a dlpreopen symbol table. +func_generate_dlsyms () +{ + $opt_debug + my_outputname="$1" + my_originator="$2" + my_pic_p="${3-no}" + my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'` + my_dlsyms= + + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + if test -n "$NM" && test -n "$global_symbol_pipe"; then + my_dlsyms="${my_outputname}S.c" + else + func_error "not configured to extract global symbols from dlpreopened files" + fi + fi + + if test -n "$my_dlsyms"; then + case $my_dlsyms in + "") ;; + *.c) + # Discover the nlist of each of the dlfiles. + nlist="$output_objdir/${my_outputname}.nm" + + func_show_eval "$RM $nlist ${nlist}S ${nlist}T" + + # Parse the name list into a source file. + func_verbose "creating $output_objdir/$my_dlsyms" + + $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ +/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */ +/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */ + +#ifdef __cplusplus +extern \"C\" { +#endif + +#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) +#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" +#endif + +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +/* External symbol declarations for the compiler. */\ +" + + if test "$dlself" = yes; then + func_verbose "generating symbol list for \`$output'" + + $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" + + # Add our own program objects to the symbol list. + progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` + for progfile in $progfiles; do + func_to_tool_file "$progfile" func_convert_file_msys_to_w32 + func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" + $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" + done + + if test -n "$exclude_expsyms"; then + $opt_dry_run || { + eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } + fi + + if test -n "$export_symbols_regex"; then + $opt_dry_run || { + eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } + fi + + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + export_symbols="$output_objdir/$outputname.exp" + $opt_dry_run || { + $RM $export_symbols + eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' + ;; + esac + } + else + $opt_dry_run || { + eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' + eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' + ;; + esac + } + fi + fi + + for dlprefile in $dlprefiles; do + func_verbose "extracting global C symbols from \`$dlprefile'" + func_basename "$dlprefile" + name="$func_basename_result" + case $host in + *cygwin* | *mingw* | *cegcc* ) + # if an import library, we need to obtain dlname + if func_win32_import_lib_p "$dlprefile"; then + func_tr_sh "$dlprefile" + eval "curr_lafile=\$libfile_$func_tr_sh_result" + dlprefile_dlbasename="" + if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then + # Use subshell, to avoid clobbering current variable values + dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` + if test -n "$dlprefile_dlname" ; then + func_basename "$dlprefile_dlname" + dlprefile_dlbasename="$func_basename_result" + else + # no lafile. user explicitly requested -dlpreopen . + $sharedlib_from_linklib_cmd "$dlprefile" + dlprefile_dlbasename=$sharedlib_from_linklib_result + fi + fi + $opt_dry_run || { + if test -n "$dlprefile_dlbasename" ; then + eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' + else + func_warning "Could not compute DLL name from $name" + eval '$ECHO ": $name " >> "$nlist"' + fi + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | + $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" + } + else # not an import lib + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + fi + ;; + *) + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + ;; + esac + done + + $opt_dry_run || { + # Make sure we have at least an empty file. + test -f "$nlist" || : > "$nlist" + + if test -n "$exclude_expsyms"; then + $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T + $MV "$nlist"T "$nlist" + fi + + # Try sorting and uniquifying the output. + if $GREP -v "^: " < "$nlist" | + if sort -k 3 /dev/null 2>&1; then + sort -k 3 + else + sort +2 + fi | + uniq > "$nlist"S; then + : + else + $GREP -v "^: " < "$nlist" > "$nlist"S + fi + + if test -f "$nlist"S; then + eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' + else + echo '/* NONE */' >> "$output_objdir/$my_dlsyms" + fi + + echo >> "$output_objdir/$my_dlsyms" "\ + +/* The mapping between symbol names and symbols. */ +typedef struct { + const char *name; + void *address; +} lt_dlsymlist; +extern LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[]; +LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[] = +{\ + { \"$my_originator\", (void *) 0 }," + + case $need_lib_prefix in + no) + eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + *) + eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + esac + echo >> "$output_objdir/$my_dlsyms" "\ + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt_${my_prefix}_LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif\ +" + } # !$opt_dry_run + + pic_flag_for_symtable= + case "$compile_command " in + *" -static "*) ;; + *) + case $host in + # compiling the symbol table file with pic_flag works around + # a FreeBSD bug that causes programs to crash when -lm is + # linked before any other PIC object. But we must not use + # pic_flag when linking with -static. The problem exists in + # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. + *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) + pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; + *-*-hpux*) + pic_flag_for_symtable=" $pic_flag" ;; + *) + if test "X$my_pic_p" != Xno; then + pic_flag_for_symtable=" $pic_flag" + fi + ;; + esac + ;; + esac + symtab_cflags= + for arg in $LTCFLAGS; do + case $arg in + -pie | -fpie | -fPIE) ;; + *) func_append symtab_cflags " $arg" ;; + esac + done + + # Now compile the dynamic symbol file. + func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' + + # Clean up the generated files. + func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"' + + # Transform the symbol file into the correct name. + symfileobj="$output_objdir/${my_outputname}S.$objext" + case $host in + *cygwin* | *mingw* | *cegcc* ) + if test -f "$output_objdir/$my_outputname.def"; then + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + else + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + fi + ;; + *) + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + ;; + esac + ;; + *) + func_fatal_error "unknown suffix for \`$my_dlsyms'" + ;; + esac + else + # We keep going just in case the user didn't refer to + # lt_preloaded_symbols. The linker will fail if global_symbol_pipe + # really was required. + + # Nullify the symbol file. + compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` + fi +} + +# func_win32_libid arg +# return the library type of file 'arg' +# +# Need a lot of goo to handle *both* DLLs and import libs +# Has to be a shell function in order to 'eat' the argument +# that is supplied when $file_magic_command is called. +# Despite the name, also deal with 64 bit binaries. +func_win32_libid () +{ + $opt_debug + win32_libid_type="unknown" + win32_fileres=`file -L $1 2>/dev/null` + case $win32_fileres in + *ar\ archive\ import\ library*) # definitely import + win32_libid_type="x86 archive import" + ;; + *ar\ archive*) # could be an import, or static + # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. + if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | + $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then + func_to_tool_file "$1" func_convert_file_msys_to_w32 + win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | + $SED -n -e ' + 1,100{ + / I /{ + s,.*,import, + p + q + } + }'` + case $win32_nmres in + import*) win32_libid_type="x86 archive import";; + *) win32_libid_type="x86 archive static";; + esac + fi + ;; + *DLL*) + win32_libid_type="x86 DLL" + ;; + *executable*) # but shell scripts are "executable" too... + case $win32_fileres in + *MS\ Windows\ PE\ Intel*) + win32_libid_type="x86 DLL" + ;; + esac + ;; + esac + $ECHO "$win32_libid_type" +} + +# func_cygming_dll_for_implib ARG +# +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib () +{ + $opt_debug + sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` +} + +# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs +# +# The is the core of a fallback implementation of a +# platform-specific function to extract the name of the +# DLL associated with the specified import library LIBNAME. +# +# SECTION_NAME is either .idata$6 or .idata$7, depending +# on the platform and compiler that created the implib. +# +# Echos the name of the DLL associated with the +# specified import library. +func_cygming_dll_for_implib_fallback_core () +{ + $opt_debug + match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` + $OBJDUMP -s --section "$1" "$2" 2>/dev/null | + $SED '/^Contents of section '"$match_literal"':/{ + # Place marker at beginning of archive member dllname section + s/.*/====MARK====/ + p + d + } + # These lines can sometimes be longer than 43 characters, but + # are always uninteresting + /:[ ]*file format pe[i]\{,1\}-/d + /^In archive [^:]*:/d + # Ensure marker is printed + /^====MARK====/p + # Remove all lines with less than 43 characters + /^.\{43\}/!d + # From remaining lines, remove first 43 characters + s/^.\{43\}//' | + $SED -n ' + # Join marker and all lines until next marker into a single line + /^====MARK====/ b para + H + $ b para + b + :para + x + s/\n//g + # Remove the marker + s/^====MARK====// + # Remove trailing dots and whitespace + s/[\. \t]*$// + # Print + /./p' | + # we now have a list, one entry per line, of the stringified + # contents of the appropriate section of all members of the + # archive which possess that section. Heuristic: eliminate + # all those which have a first or second character that is + # a '.' (that is, objdump's representation of an unprintable + # character.) This should work for all archives with less than + # 0x302f exports -- but will fail for DLLs whose name actually + # begins with a literal '.' or a single character followed by + # a '.'. + # + # Of those that remain, print the first one. + $SED -e '/^\./d;/^.\./d;q' +} + +# func_cygming_gnu_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is a GNU/binutils-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_gnu_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` + test -n "$func_cygming_gnu_implib_tmp" +} + +# func_cygming_ms_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is an MS-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_ms_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` + test -n "$func_cygming_ms_implib_tmp" +} + +# func_cygming_dll_for_implib_fallback ARG +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# +# This fallback implementation is for use when $DLLTOOL +# does not support the --identify-strict option. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib_fallback () +{ + $opt_debug + if func_cygming_gnu_implib_p "$1" ; then + # binutils import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` + elif func_cygming_ms_implib_p "$1" ; then + # ms-generated import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` + else + # unknown + sharedlib_from_linklib_result="" + fi +} + + +# func_extract_an_archive dir oldlib +func_extract_an_archive () +{ + $opt_debug + f_ex_an_ar_dir="$1"; shift + f_ex_an_ar_oldlib="$1" + if test "$lock_old_archive_extraction" = yes; then + lockfile=$f_ex_an_ar_oldlib.lock + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + fi + func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ + 'stat=$?; rm -f "$lockfile"; exit $stat' + if test "$lock_old_archive_extraction" = yes; then + $opt_dry_run || rm -f "$lockfile" + fi + if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then + : + else + func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" + fi +} + + +# func_extract_archives gentop oldlib ... +func_extract_archives () +{ + $opt_debug + my_gentop="$1"; shift + my_oldlibs=${1+"$@"} + my_oldobjs="" + my_xlib="" + my_xabs="" + my_xdir="" + + for my_xlib in $my_oldlibs; do + # Extract the objects. + case $my_xlib in + [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; + *) my_xabs=`pwd`"/$my_xlib" ;; + esac + func_basename "$my_xlib" + my_xlib="$func_basename_result" + my_xlib_u=$my_xlib + while :; do + case " $extracted_archives " in + *" $my_xlib_u "*) + func_arith $extracted_serial + 1 + extracted_serial=$func_arith_result + my_xlib_u=lt$extracted_serial-$my_xlib ;; + *) break ;; + esac + done + extracted_archives="$extracted_archives $my_xlib_u" + my_xdir="$my_gentop/$my_xlib_u" + + func_mkdir_p "$my_xdir" + + case $host in + *-darwin*) + func_verbose "Extracting $my_xabs" + # Do not bother doing anything if just a dry run + $opt_dry_run || { + darwin_orig_dir=`pwd` + cd $my_xdir || exit $? + darwin_archive=$my_xabs + darwin_curdir=`pwd` + darwin_base_archive=`basename "$darwin_archive"` + darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` + if test -n "$darwin_arches"; then + darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` + darwin_arch= + func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" + for darwin_arch in $darwin_arches ; do + func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}" + $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" + cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" + func_extract_an_archive "`pwd`" "${darwin_base_archive}" + cd "$darwin_curdir" + $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" + done # $darwin_arches + ## Okay now we've a bunch of thin objects, gotta fatten them up :) + darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u` + darwin_file= + darwin_files= + for darwin_file in $darwin_filelist; do + darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` + $LIPO -create -output "$darwin_file" $darwin_files + done # $darwin_filelist + $RM -rf unfat-$$ + cd "$darwin_orig_dir" + else + cd $darwin_orig_dir + func_extract_an_archive "$my_xdir" "$my_xabs" + fi # $darwin_arches + } # !$opt_dry_run + ;; + *) + func_extract_an_archive "$my_xdir" "$my_xabs" + ;; + esac + my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` + done + + func_extract_archives_result="$my_oldobjs" +} + + +# func_emit_wrapper [arg=no] +# +# Emit a libtool wrapper script on stdout. +# Don't directly open a file because we may want to +# incorporate the script contents within a cygwin/mingw +# wrapper executable. Must ONLY be called from within +# func_mode_link because it depends on a number of variables +# set therein. +# +# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR +# variable will take. If 'yes', then the emitted script +# will assume that the directory in which it is stored is +# the $objdir directory. This is a cygwin/mingw-specific +# behavior. +func_emit_wrapper () +{ + func_emit_wrapper_arg1=${1-no} + + $ECHO "\ +#! $SHELL + +# $output - temporary wrapper script for $objdir/$outputname +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION +# +# The $output program cannot be directly executed until all the libtool +# libraries that it depends on are installed. +# +# This wrapper script should never be moved out of the build directory. +# If it is, it will not operate correctly. + +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +sed_quote_subst='$sed_quote_subst' + +# Be Bourne compatible +if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +relink_command=\"$relink_command\" + +# This environment variable determines our operation mode. +if test \"\$libtool_install_magic\" = \"$magic\"; then + # install mode needs the following variables: + generated_by_libtool_version='$macro_version' + notinst_deplibs='$notinst_deplibs' +else + # When we are sourced in execute mode, \$file and \$ECHO are already set. + if test \"\$libtool_execute_magic\" != \"$magic\"; then + file=\"\$0\"" + + qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` + $ECHO "\ + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + ECHO=\"$qECHO\" + fi + +# Very basic option parsing. These options are (a) specific to +# the libtool wrapper, (b) are identical between the wrapper +# /script/ and the wrapper /executable/ which is used only on +# windows platforms, and (c) all begin with the string "--lt-" +# (application programs are unlikely to have options which match +# this pattern). +# +# There are only two supported options: --lt-debug and +# --lt-dump-script. There is, deliberately, no --lt-help. +# +# The first argument to this parsing function should be the +# script's $0 value, followed by "$@". +lt_option_debug= +func_parse_lt_options () +{ + lt_script_arg0=\$0 + shift + for lt_opt + do + case \"\$lt_opt\" in + --lt-debug) lt_option_debug=1 ;; + --lt-dump-script) + lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` + test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. + lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` + cat \"\$lt_dump_D/\$lt_dump_F\" + exit 0 + ;; + --lt-*) + \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 + exit 1 + ;; + esac + done + + # Print the debug banner immediately: + if test -n \"\$lt_option_debug\"; then + echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2 + fi +} + +# Used when --lt-debug. Prints its arguments to stdout +# (redirection is the responsibility of the caller) +func_lt_dump_args () +{ + lt_dump_args_N=1; + for lt_arg + do + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\" + lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` + done +} + +# Core function for launching the target application +func_exec_program_core () +{ +" + case $host in + # Backslashes separate directories on plain windows + *-*-mingw | *-*-os2* | *-cegcc*) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} +" + ;; + + *) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir/\$program\" \${1+\"\$@\"} +" + ;; + esac + $ECHO "\ + \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 + exit 1 +} + +# A function to encapsulate launching the target application +# Strips options in the --lt-* namespace from \$@ and +# launches target application with the remaining arguments. +func_exec_program () +{ + case \" \$* \" in + *\\ --lt-*) + for lt_wr_arg + do + case \$lt_wr_arg in + --lt-*) ;; + *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; + esac + shift + done ;; + esac + func_exec_program_core \${1+\"\$@\"} +} + + # Parse options + func_parse_lt_options \"\$0\" \${1+\"\$@\"} + + # Find the directory that this script lives in. + thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` + test \"x\$thisdir\" = \"x\$file\" && thisdir=. + + # Follow symbolic links until we get to the real thisdir. + file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` + while test -n \"\$file\"; do + destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` + + # If there was a directory component, then change thisdir. + if test \"x\$destdir\" != \"x\$file\"; then + case \"\$destdir\" in + [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; + *) thisdir=\"\$thisdir/\$destdir\" ;; + esac + fi + + file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` + file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` + done + + # Usually 'no', except on cygwin/mingw when embedded into + # the cwrapper. + WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 + if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then + # special case for '.' + if test \"\$thisdir\" = \".\"; then + thisdir=\`pwd\` + fi + # remove .libs from thisdir + case \"\$thisdir\" in + *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; + $objdir ) thisdir=. ;; + esac + fi + + # Try to get the absolute directory name. + absdir=\`cd \"\$thisdir\" && pwd\` + test -n \"\$absdir\" && thisdir=\"\$absdir\" +" + + if test "$fast_install" = yes; then + $ECHO "\ + program=lt-'$outputname'$exeext + progdir=\"\$thisdir/$objdir\" + + if test ! -f \"\$progdir/\$program\" || + { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ + test \"X\$file\" != \"X\$progdir/\$program\"; }; then + + file=\"\$\$-\$program\" + + if test ! -d \"\$progdir\"; then + $MKDIR \"\$progdir\" + else + $RM \"\$progdir/\$file\" + fi" + + $ECHO "\ + + # relink executable if necessary + if test -n \"\$relink_command\"; then + if relink_command_output=\`eval \$relink_command 2>&1\`; then : + else + $ECHO \"\$relink_command_output\" >&2 + $RM \"\$progdir/\$file\" + exit 1 + fi + fi + + $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || + { $RM \"\$progdir/\$program\"; + $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } + $RM \"\$progdir/\$file\" + fi" + else + $ECHO "\ + program='$outputname' + progdir=\"\$thisdir/$objdir\" +" + fi + + $ECHO "\ + + if test -f \"\$progdir/\$program\"; then" + + # fixup the dll searchpath if we need to. + # + # Fix the DLL searchpath if we need to. Do this before prepending + # to shlibpath, because on Windows, both are PATH and uninstalled + # libraries must come first. + if test -n "$dllsearchpath"; then + $ECHO "\ + # Add the dll search path components to the executable PATH + PATH=$dllsearchpath:\$PATH +" + fi + + # Export our shlibpath_var if we have one. + if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then + $ECHO "\ + # Add our own library path to $shlibpath_var + $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" + + # Some systems cannot cope with colon-terminated $shlibpath_var + # The second colon is a workaround for a bug in BeOS R4 sed + $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` + + export $shlibpath_var +" + fi + + $ECHO "\ + if test \"\$libtool_execute_magic\" != \"$magic\"; then + # Run the actual program with our arguments. + func_exec_program \${1+\"\$@\"} + fi + else + # The program doesn't exist. + \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 + \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 + \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 + exit 1 + fi +fi\ +" +} + + +# func_emit_cwrapperexe_src +# emit the source code for a wrapper executable on stdout +# Must ONLY be called from within func_mode_link because +# it depends on a number of variable set therein. +func_emit_cwrapperexe_src () +{ + cat < +#include +#ifdef _MSC_VER +# include +# include +# include +#else +# include +# include +# ifdef __CYGWIN__ +# include +# endif +#endif +#include +#include +#include +#include +#include +#include +#include +#include + +/* declarations of non-ANSI functions */ +#if defined(__MINGW32__) +# ifdef __STRICT_ANSI__ +int _putenv (const char *); +# endif +#elif defined(__CYGWIN__) +# ifdef __STRICT_ANSI__ +char *realpath (const char *, char *); +int putenv (char *); +int setenv (const char *, const char *, int); +# endif +/* #elif defined (other platforms) ... */ +#endif + +/* portability defines, excluding path handling macros */ +#if defined(_MSC_VER) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +# define S_IXUSR _S_IEXEC +# ifndef _INTPTR_T_DEFINED +# define _INTPTR_T_DEFINED +# define intptr_t int +# endif +#elif defined(__MINGW32__) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +#elif defined(__CYGWIN__) +# define HAVE_SETENV +# define FOPEN_WB "wb" +/* #elif defined (other platforms) ... */ +#endif + +#if defined(PATH_MAX) +# define LT_PATHMAX PATH_MAX +#elif defined(MAXPATHLEN) +# define LT_PATHMAX MAXPATHLEN +#else +# define LT_PATHMAX 1024 +#endif + +#ifndef S_IXOTH +# define S_IXOTH 0 +#endif +#ifndef S_IXGRP +# define S_IXGRP 0 +#endif + +/* path handling portability macros */ +#ifndef DIR_SEPARATOR +# define DIR_SEPARATOR '/' +# define PATH_SEPARATOR ':' +#endif + +#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ + defined (__OS2__) +# define HAVE_DOS_BASED_FILE_SYSTEM +# define FOPEN_WB "wb" +# ifndef DIR_SEPARATOR_2 +# define DIR_SEPARATOR_2 '\\' +# endif +# ifndef PATH_SEPARATOR_2 +# define PATH_SEPARATOR_2 ';' +# endif +#endif + +#ifndef DIR_SEPARATOR_2 +# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) +#else /* DIR_SEPARATOR_2 */ +# define IS_DIR_SEPARATOR(ch) \ + (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) +#endif /* DIR_SEPARATOR_2 */ + +#ifndef PATH_SEPARATOR_2 +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) +#else /* PATH_SEPARATOR_2 */ +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) +#endif /* PATH_SEPARATOR_2 */ + +#ifndef FOPEN_WB +# define FOPEN_WB "w" +#endif +#ifndef _O_BINARY +# define _O_BINARY 0 +#endif + +#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) +#define XFREE(stale) do { \ + if (stale) { free ((void *) stale); stale = 0; } \ +} while (0) + +#if defined(LT_DEBUGWRAPPER) +static int lt_debug = 1; +#else +static int lt_debug = 0; +#endif + +const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ + +void *xmalloc (size_t num); +char *xstrdup (const char *string); +const char *base_name (const char *name); +char *find_executable (const char *wrapper); +char *chase_symlinks (const char *pathspec); +int make_executable (const char *path); +int check_executable (const char *path); +char *strendzap (char *str, const char *pat); +void lt_debugprintf (const char *file, int line, const char *fmt, ...); +void lt_fatal (const char *file, int line, const char *message, ...); +static const char *nonnull (const char *s); +static const char *nonempty (const char *s); +void lt_setenv (const char *name, const char *value); +char *lt_extend_str (const char *orig_value, const char *add, int to_end); +void lt_update_exe_path (const char *name, const char *value); +void lt_update_lib_path (const char *name, const char *value); +char **prepare_spawn (char **argv); +void lt_dump_script (FILE *f); +EOF + + cat <= 0) + && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) + return 1; + else + return 0; +} + +int +make_executable (const char *path) +{ + int rval = 0; + struct stat st; + + lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", + nonempty (path)); + if ((!path) || (!*path)) + return 0; + + if (stat (path, &st) >= 0) + { + rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); + } + return rval; +} + +/* Searches for the full path of the wrapper. Returns + newly allocated full path name if found, NULL otherwise + Does not chase symlinks, even on platforms that support them. +*/ +char * +find_executable (const char *wrapper) +{ + int has_slash = 0; + const char *p; + const char *p_next; + /* static buffer for getcwd */ + char tmp[LT_PATHMAX + 1]; + int tmp_len; + char *concat_name; + + lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", + nonempty (wrapper)); + + if ((wrapper == NULL) || (*wrapper == '\0')) + return NULL; + + /* Absolute path? */ +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') + { + concat_name = xstrdup (wrapper); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } + else + { +#endif + if (IS_DIR_SEPARATOR (wrapper[0])) + { + concat_name = xstrdup (wrapper); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + } +#endif + + for (p = wrapper; *p; p++) + if (*p == '/') + { + has_slash = 1; + break; + } + if (!has_slash) + { + /* no slashes; search PATH */ + const char *path = getenv ("PATH"); + if (path != NULL) + { + for (p = path; *p; p = p_next) + { + const char *q; + size_t p_len; + for (q = p; *q; q++) + if (IS_PATH_SEPARATOR (*q)) + break; + p_len = q - p; + p_next = (*q == '\0' ? q : q + 1); + if (p_len == 0) + { + /* empty path: current directory */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = + XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + } + else + { + concat_name = + XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, p, p_len); + concat_name[p_len] = '/'; + strcpy (concat_name + p_len + 1, wrapper); + } + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } + } + /* not found in PATH; assume curdir */ + } + /* Relative path | not found in path: prepend cwd */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + return NULL; +} + +char * +chase_symlinks (const char *pathspec) +{ +#ifndef S_ISLNK + return xstrdup (pathspec); +#else + char buf[LT_PATHMAX]; + struct stat s; + char *tmp_pathspec = xstrdup (pathspec); + char *p; + int has_symlinks = 0; + while (strlen (tmp_pathspec) && !has_symlinks) + { + lt_debugprintf (__FILE__, __LINE__, + "checking path component for symlinks: %s\n", + tmp_pathspec); + if (lstat (tmp_pathspec, &s) == 0) + { + if (S_ISLNK (s.st_mode) != 0) + { + has_symlinks = 1; + break; + } + + /* search backwards for last DIR_SEPARATOR */ + p = tmp_pathspec + strlen (tmp_pathspec) - 1; + while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + p--; + if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + { + /* no more DIR_SEPARATORS left */ + break; + } + *p = '\0'; + } + else + { + lt_fatal (__FILE__, __LINE__, + "error accessing file \"%s\": %s", + tmp_pathspec, nonnull (strerror (errno))); + } + } + XFREE (tmp_pathspec); + + if (!has_symlinks) + { + return xstrdup (pathspec); + } + + tmp_pathspec = realpath (pathspec, buf); + if (tmp_pathspec == 0) + { + lt_fatal (__FILE__, __LINE__, + "could not follow symlinks for %s", pathspec); + } + return xstrdup (tmp_pathspec); +#endif +} + +char * +strendzap (char *str, const char *pat) +{ + size_t len, patlen; + + assert (str != NULL); + assert (pat != NULL); + + len = strlen (str); + patlen = strlen (pat); + + if (patlen <= len) + { + str += len - patlen; + if (strcmp (str, pat) == 0) + *str = '\0'; + } + return str; +} + +void +lt_debugprintf (const char *file, int line, const char *fmt, ...) +{ + va_list args; + if (lt_debug) + { + (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); + va_start (args, fmt); + (void) vfprintf (stderr, fmt, args); + va_end (args); + } +} + +static void +lt_error_core (int exit_status, const char *file, + int line, const char *mode, + const char *message, va_list ap) +{ + fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); + vfprintf (stderr, message, ap); + fprintf (stderr, ".\n"); + + if (exit_status >= 0) + exit (exit_status); +} + +void +lt_fatal (const char *file, int line, const char *message, ...) +{ + va_list ap; + va_start (ap, message); + lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); + va_end (ap); +} + +static const char * +nonnull (const char *s) +{ + return s ? s : "(null)"; +} + +static const char * +nonempty (const char *s) +{ + return (s && !*s) ? "(empty)" : nonnull (s); +} + +void +lt_setenv (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_setenv) setting '%s' to '%s'\n", + nonnull (name), nonnull (value)); + { +#ifdef HAVE_SETENV + /* always make a copy, for consistency with !HAVE_SETENV */ + char *str = xstrdup (value); + setenv (name, str, 1); +#else + int len = strlen (name) + 1 + strlen (value) + 1; + char *str = XMALLOC (char, len); + sprintf (str, "%s=%s", name, value); + if (putenv (str) != EXIT_SUCCESS) + { + XFREE (str); + } +#endif + } +} + +char * +lt_extend_str (const char *orig_value, const char *add, int to_end) +{ + char *new_value; + if (orig_value && *orig_value) + { + int orig_value_len = strlen (orig_value); + int add_len = strlen (add); + new_value = XMALLOC (char, add_len + orig_value_len + 1); + if (to_end) + { + strcpy (new_value, orig_value); + strcpy (new_value + orig_value_len, add); + } + else + { + strcpy (new_value, add); + strcpy (new_value + add_len, orig_value); + } + } + else + { + new_value = xstrdup (add); + } + return new_value; +} + +void +lt_update_exe_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + /* some systems can't cope with a ':'-terminated path #' */ + int len = strlen (new_value); + while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1])) + { + new_value[len-1] = '\0'; + } + lt_setenv (name, new_value); + XFREE (new_value); + } +} + +void +lt_update_lib_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + lt_setenv (name, new_value); + XFREE (new_value); + } +} + +EOF + case $host_os in + mingw*) + cat <<"EOF" + +/* Prepares an argument vector before calling spawn(). + Note that spawn() does not by itself call the command interpreter + (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : + ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + GetVersionEx(&v); + v.dwPlatformId == VER_PLATFORM_WIN32_NT; + }) ? "cmd.exe" : "command.com"). + Instead it simply concatenates the arguments, separated by ' ', and calls + CreateProcess(). We must quote the arguments since Win32 CreateProcess() + interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a + special way: + - Space and tab are interpreted as delimiters. They are not treated as + delimiters if they are surrounded by double quotes: "...". + - Unescaped double quotes are removed from the input. Their only effect is + that within double quotes, space and tab are treated like normal + characters. + - Backslashes not followed by double quotes are not special. + - But 2*n+1 backslashes followed by a double quote become + n backslashes followed by a double quote (n >= 0): + \" -> " + \\\" -> \" + \\\\\" -> \\" + */ +#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +char ** +prepare_spawn (char **argv) +{ + size_t argc; + char **new_argv; + size_t i; + + /* Count number of arguments. */ + for (argc = 0; argv[argc] != NULL; argc++) + ; + + /* Allocate new argument vector. */ + new_argv = XMALLOC (char *, argc + 1); + + /* Put quoted arguments into the new argument vector. */ + for (i = 0; i < argc; i++) + { + const char *string = argv[i]; + + if (string[0] == '\0') + new_argv[i] = xstrdup ("\"\""); + else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) + { + int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); + size_t length; + unsigned int backslashes; + const char *s; + char *quoted_string; + char *p; + + length = 0; + backslashes = 0; + if (quote_around) + length++; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + length += backslashes + 1; + length++; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + length += backslashes + 1; + + quoted_string = XMALLOC (char, length + 1); + + p = quoted_string; + backslashes = 0; + if (quote_around) + *p++ = '"'; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + { + unsigned int j; + for (j = backslashes + 1; j > 0; j--) + *p++ = '\\'; + } + *p++ = c; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + { + unsigned int j; + for (j = backslashes; j > 0; j--) + *p++ = '\\'; + *p++ = '"'; + } + *p = '\0'; + + new_argv[i] = quoted_string; + } + else + new_argv[i] = (char *) string; + } + new_argv[argc] = NULL; + + return new_argv; +} +EOF + ;; + esac + + cat <<"EOF" +void lt_dump_script (FILE* f) +{ +EOF + func_emit_wrapper yes | + $SED -n -e ' +s/^\(.\{79\}\)\(..*\)/\1\ +\2/ +h +s/\([\\"]\)/\\\1/g +s/$/\\n/ +s/\([^\n]*\).*/ fputs ("\1", f);/p +g +D' + cat <<"EOF" +} +EOF +} +# end: func_emit_cwrapperexe_src + +# func_win32_import_lib_p ARG +# True if ARG is an import lib, as indicated by $file_magic_cmd +func_win32_import_lib_p () +{ + $opt_debug + case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in + *import*) : ;; + *) false ;; + esac +} + +# func_mode_link arg... +func_mode_link () +{ + $opt_debug + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + # It is impossible to link a dll without this setting, and + # we shouldn't force the makefile maintainer to figure out + # which system we are compiling for in order to pass an extra + # flag for every libtool invocation. + # allow_undefined=no + + # FIXME: Unfortunately, there are problems with the above when trying + # to make a dll which has undefined symbols, in which case not + # even a static library is built. For now, we need to specify + # -no-undefined on the libtool link line when we can be certain + # that all symbols are satisfied, otherwise we get a static library. + allow_undefined=yes + ;; + *) + allow_undefined=yes + ;; + esac + libtool_args=$nonopt + base_compile="$nonopt $@" + compile_command=$nonopt + finalize_command=$nonopt + + compile_rpath= + finalize_rpath= + compile_shlibpath= + finalize_shlibpath= + convenience= + old_convenience= + deplibs= + old_deplibs= + compiler_flags= + linker_flags= + dllsearchpath= + lib_search_path=`pwd` + inst_prefix_dir= + new_inherited_linker_flags= + + avoid_version=no + bindir= + dlfiles= + dlprefiles= + dlself=no + export_dynamic=no + export_symbols= + export_symbols_regex= + generated= + libobjs= + ltlibs= + module=no + no_install=no + objs= + non_pic_objects= + precious_files_regex= + prefer_static_libs=no + preload=no + prev= + prevarg= + release= + rpath= + xrpath= + perm_rpath= + temp_rpath= + thread_safe=no + vinfo= + vinfo_number=no + weak_libs= + single_module="${wl}-single_module" + func_infer_tag $base_compile + + # We need to know -static, to get the right output filenames. + for arg + do + case $arg in + -shared) + test "$build_libtool_libs" != yes && \ + func_fatal_configuration "can not build a shared library" + build_old_libs=no + break + ;; + -all-static | -static | -static-libtool-libs) + case $arg in + -all-static) + if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then + func_warning "complete static linking is impossible in this configuration" + fi + if test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + -static) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=built + ;; + -static-libtool-libs) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + esac + build_libtool_libs=no + build_old_libs=yes + break + ;; + esac + done + + # See if our shared archives depend on static archives. + test -n "$old_archive_from_new_cmds" && build_old_libs=yes + + # Go through the arguments, transforming them on the way. + while test "$#" -gt 0; do + arg="$1" + shift + func_quote_for_eval "$arg" + qarg=$func_quote_for_eval_unquoted_result + func_append libtool_args " $func_quote_for_eval_result" + + # If the previous option needs an argument, assign it. + if test -n "$prev"; then + case $prev in + output) + func_append compile_command " @OUTPUT@" + func_append finalize_command " @OUTPUT@" + ;; + esac + + case $prev in + bindir) + bindir="$arg" + prev= + continue + ;; + dlfiles|dlprefiles) + if test "$preload" = no; then + # Add the symbol object into the linking commands. + func_append compile_command " @SYMFILE@" + func_append finalize_command " @SYMFILE@" + preload=yes + fi + case $arg in + *.la | *.lo) ;; # We handle these cases below. + force) + if test "$dlself" = no; then + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + self) + if test "$prev" = dlprefiles; then + dlself=yes + elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then + dlself=yes + else + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + *) + if test "$prev" = dlfiles; then + func_append dlfiles " $arg" + else + func_append dlprefiles " $arg" + fi + prev= + continue + ;; + esac + ;; + expsyms) + export_symbols="$arg" + test -f "$arg" \ + || func_fatal_error "symbol file \`$arg' does not exist" + prev= + continue + ;; + expsyms_regex) + export_symbols_regex="$arg" + prev= + continue + ;; + framework) + case $host in + *-*-darwin*) + case "$deplibs " in + *" $qarg.ltframework "*) ;; + *) func_append deplibs " $qarg.ltframework" # this is fixed later + ;; + esac + ;; + esac + prev= + continue + ;; + inst_prefix) + inst_prefix_dir="$arg" + prev= + continue + ;; + objectlist) + if test -f "$arg"; then + save_arg=$arg + moreargs= + for fil in `cat "$save_arg"` + do +# func_append moreargs " $fil" + arg=$fil + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test "$pic_object" = none && + test "$non_pic_object" = none; then + func_fatal_error "cannot find name of object for \`$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" + + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg="$pic_object" + fi + + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "\`$arg' is not a valid libtool object" + fi + fi + done + else + func_fatal_error "link input file \`$arg' does not exist" + fi + arg=$save_arg + prev= + continue + ;; + precious_regex) + precious_files_regex="$arg" + prev= + continue + ;; + release) + release="-$arg" + prev= + continue + ;; + rpath | xrpath) + # We need an absolute path. + case $arg in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + if test "$prev" = rpath; then + case "$rpath " in + *" $arg "*) ;; + *) func_append rpath " $arg" ;; + esac + else + case "$xrpath " in + *" $arg "*) ;; + *) func_append xrpath " $arg" ;; + esac + fi + prev= + continue + ;; + shrext) + shrext_cmds="$arg" + prev= + continue + ;; + weak) + func_append weak_libs " $arg" + prev= + continue + ;; + xcclinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xcompiler) + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xlinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $wl$qarg" + prev= + func_append compile_command " $wl$qarg" + func_append finalize_command " $wl$qarg" + continue + ;; + *) + eval "$prev=\"\$arg\"" + prev= + continue + ;; + esac + fi # test -n "$prev" + + prevarg="$arg" + + case $arg in + -all-static) + if test -n "$link_static_flag"; then + # See comment for -static flag below, for more details. + func_append compile_command " $link_static_flag" + func_append finalize_command " $link_static_flag" + fi + continue + ;; + + -allow-undefined) + # FIXME: remove this flag sometime in the future. + func_fatal_error "\`-allow-undefined' must not be used because it is the default" + ;; + + -avoid-version) + avoid_version=yes + continue + ;; + + -bindir) + prev=bindir + continue + ;; + + -dlopen) + prev=dlfiles + continue + ;; + + -dlpreopen) + prev=dlprefiles + continue + ;; + + -export-dynamic) + export_dynamic=yes + continue + ;; + + -export-symbols | -export-symbols-regex) + if test -n "$export_symbols" || test -n "$export_symbols_regex"; then + func_fatal_error "more than one -exported-symbols argument is not allowed" + fi + if test "X$arg" = "X-export-symbols"; then + prev=expsyms + else + prev=expsyms_regex + fi + continue + ;; + + -framework) + prev=framework + continue + ;; + + -inst-prefix-dir) + prev=inst_prefix + continue + ;; + + # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* + # so, if we see these flags be careful not to treat them like -L + -L[A-Z][A-Z]*:*) + case $with_gcc/$host in + no/*-*-irix* | /*-*-irix*) + func_append compile_command " $arg" + func_append finalize_command " $arg" + ;; + esac + continue + ;; + + -L*) + func_stripname "-L" '' "$arg" + if test -z "$func_stripname_result"; then + if test "$#" -gt 0; then + func_fatal_error "require no space between \`-L' and \`$1'" + else + func_fatal_error "need path for \`-L' option" + fi + fi + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + absdir=`cd "$dir" && pwd` + test -z "$absdir" && \ + func_fatal_error "cannot determine absolute directory name of \`$dir'" + dir="$absdir" + ;; + esac + case "$deplibs " in + *" -L$dir "* | *" $arg "*) + # Will only happen for absolute or sysroot arguments + ;; + *) + # Preserve sysroot, but never include relative directories + case $dir in + [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; + *) func_append deplibs " -L$dir" ;; + esac + func_append lib_search_path " $dir" + ;; + esac + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$dir:"*) ;; + ::) dllsearchpath=$dir;; + *) func_append dllsearchpath ":$dir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + continue + ;; + + -l*) + if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) + # These systems don't actually have a C or math library (as such) + continue + ;; + *-*-os2*) + # These systems don't actually have a C library (as such) + test "X$arg" = "X-lc" && continue + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + test "X$arg" = "X-lc" && continue + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C and math libraries are in the System framework + func_append deplibs " System.ltframework" + continue + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + test "X$arg" = "X-lc" && continue + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + test "X$arg" = "X-lc" && continue + ;; + esac + elif test "X$arg" = "X-lc_r"; then + case $host in + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc_r directly, use -pthread flag. + continue + ;; + esac + fi + func_append deplibs " $arg" + continue + ;; + + -module) + module=yes + continue + ;; + + # Tru64 UNIX uses -model [arg] to determine the layout of C++ + # classes, name mangling, and exception handling. + # Darwin uses the -arch flag to determine output architecture. + -model|-arch|-isysroot|--sysroot) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + prev=xcompiler + continue + ;; + + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ + |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + case "$new_inherited_linker_flags " in + *" $arg "*) ;; + * ) func_append new_inherited_linker_flags " $arg" ;; + esac + continue + ;; + + -multi_module) + single_module="${wl}-multi_module" + continue + ;; + + -no-fast-install) + fast_install=no + continue + ;; + + -no-install) + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) + # The PATH hackery in wrapper scripts is required on Windows + # and Darwin in order for the loader to find any dlls it needs. + func_warning "\`-no-install' is ignored for $host" + func_warning "assuming \`-no-fast-install' instead" + fast_install=no + ;; + *) no_install=yes ;; + esac + continue + ;; + + -no-undefined) + allow_undefined=no + continue + ;; + + -objectlist) + prev=objectlist + continue + ;; + + -o) prev=output ;; + + -precious-files-regex) + prev=precious_regex + continue + ;; + + -release) + prev=release + continue + ;; + + -rpath) + prev=rpath + continue + ;; + + -R) + prev=xrpath + continue + ;; + + -R*) + func_stripname '-R' '' "$arg" + dir=$func_stripname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + =*) + func_stripname '=' '' "$dir" + dir=$lt_sysroot$func_stripname_result + ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + continue + ;; + + -shared) + # The effects of -shared are defined in a previous loop. + continue + ;; + + -shrext) + prev=shrext + continue + ;; + + -static | -static-libtool-libs) + # The effects of -static are defined in a previous loop. + # We used to do the same as -all-static on platforms that + # didn't have a PIC flag, but the assumption that the effects + # would be equivalent was wrong. It would break on at least + # Digital Unix and AIX. + continue + ;; + + -thread-safe) + thread_safe=yes + continue + ;; + + -version-info) + prev=vinfo + continue + ;; + + -version-number) + prev=vinfo + vinfo_number=yes + continue + ;; + + -weak) + prev=weak + continue + ;; + + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + func_quote_for_eval "$flag" + func_append arg " $func_quote_for_eval_result" + func_append compiler_flags " $func_quote_for_eval_result" + done + IFS="$save_ifs" + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Wl,*) + func_stripname '-Wl,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + func_quote_for_eval "$flag" + func_append arg " $wl$func_quote_for_eval_result" + func_append compiler_flags " $wl$func_quote_for_eval_result" + func_append linker_flags " $func_quote_for_eval_result" + done + IFS="$save_ifs" + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Xcompiler) + prev=xcompiler + continue + ;; + + -Xlinker) + prev=xlinker + continue + ;; + + -XCClinker) + prev=xcclinker + continue + ;; + + # -msg_* for osf cc + -msg_*) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + + # Flags to be passed through unchanged, with rationale: + # -64, -mips[0-9] enable 64-bit mode for the SGI compiler + # -r[0-9][0-9]* specify processor for the SGI compiler + # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler + # +DA*, +DD* enable 64-bit mode for the HP compiler + # -q* compiler args for the IBM compiler + # -m*, -t[45]*, -txscale* architecture-specific flags for GCC + # -F/path path to uninstalled frameworks, gcc on darwin + # -p, -pg, --coverage, -fprofile-* profiling flags for GCC + # @file GCC response files + # -tp=* Portland pgcc target processor selection + # --sysroot=* for sysroot support + # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ + -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ + -O*|-flto*|-fwhopr*|-fuse-linker-plugin) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + func_append compile_command " $arg" + func_append finalize_command " $arg" + func_append compiler_flags " $arg" + continue + ;; + + # Some other compiler flag. + -* | +*) + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + + *.$objext) + # A standard object. + func_append objs " $arg" + ;; + + *.lo) + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test "$pic_object" = none && + test "$non_pic_object" = none; then + func_fatal_error "cannot find name of object for \`$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" + + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg="$pic_object" + fi + + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir="$func_dirname_result" + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "\`$arg' is not a valid libtool object" + fi + fi + ;; + + *.$libext) + # An archive. + func_append deplibs " $arg" + func_append old_deplibs " $arg" + continue + ;; + + *.la) + # A libtool-controlled library. + + func_resolve_sysroot "$arg" + if test "$prev" = dlfiles; then + # This library was specified with -dlopen. + func_append dlfiles " $func_resolve_sysroot_result" + prev= + elif test "$prev" = dlprefiles; then + # The library was specified with -dlpreopen. + func_append dlprefiles " $func_resolve_sysroot_result" + prev= + else + func_append deplibs " $func_resolve_sysroot_result" + fi + continue + ;; + + # Some other compiler argument. + *) + # Unknown arguments in both finalize_command and compile_command need + # to be aesthetically quoted because they are evaled later. + func_quote_for_eval "$arg" + arg="$func_quote_for_eval_result" + ;; + esac # arg + + # Now actually substitute the argument into the commands. + if test -n "$arg"; then + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + done # argument parsing loop + + test -n "$prev" && \ + func_fatal_help "the \`$prevarg' option requires an argument" + + if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then + eval arg=\"$export_dynamic_flag_spec\" + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + + oldlibs= + # calculate the name of the file, without its directory + func_basename "$output" + outputname="$func_basename_result" + libobjs_save="$libobjs" + + if test -n "$shlibpath_var"; then + # get the directories listed in $shlibpath_var + eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\` + else + shlib_search_path= + fi + eval sys_lib_search_path=\"$sys_lib_search_path_spec\" + eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" + + func_dirname "$output" "/" "" + output_objdir="$func_dirname_result$objdir" + func_to_tool_file "$output_objdir/" + tool_output_objdir=$func_to_tool_file_result + # Create the object directory. + func_mkdir_p "$output_objdir" + + # Determine the type of output + case $output in + "") + func_fatal_help "you must specify an output file" + ;; + *.$libext) linkmode=oldlib ;; + *.lo | *.$objext) linkmode=obj ;; + *.la) linkmode=lib ;; + *) linkmode=prog ;; # Anything else should be a program. + esac + + specialdeplibs= + + libs= + # Find all interdependent deplibs by searching for libraries + # that are linked more than once (e.g. -la -lb -la) + for deplib in $deplibs; do + if $opt_preserve_dup_deps ; then + case "$libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append libs " $deplib" + done + + if test "$linkmode" = lib; then + libs="$predeps $libs $compiler_lib_search_path $postdeps" + + # Compute libraries that are listed more than once in $predeps + # $postdeps and mark them as special (i.e., whose duplicates are + # not to be eliminated). + pre_post_deps= + if $opt_duplicate_compiler_generated_deps; then + for pre_post_dep in $predeps $postdeps; do + case "$pre_post_deps " in + *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; + esac + func_append pre_post_deps " $pre_post_dep" + done + fi + pre_post_deps= + fi + + deplibs= + newdependency_libs= + newlib_search_path= + need_relink=no # whether we're linking any uninstalled libtool libraries + notinst_deplibs= # not-installed libtool libraries + notinst_path= # paths that contain not-installed libtool libraries + + case $linkmode in + lib) + passes="conv dlpreopen link" + for file in $dlfiles $dlprefiles; do + case $file in + *.la) ;; + *) + func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file" + ;; + esac + done + ;; + prog) + compile_deplibs= + finalize_deplibs= + alldeplibs=no + newdlfiles= + newdlprefiles= + passes="conv scan dlopen dlpreopen link" + ;; + *) passes="conv" + ;; + esac + + for pass in $passes; do + # The preopen pass in lib mode reverses $deplibs; put it back here + # so that -L comes before libs that need it for instance... + if test "$linkmode,$pass" = "lib,link"; then + ## FIXME: Find the place where the list is rebuilt in the wrong + ## order, and fix it there properly + tmp_deplibs= + for deplib in $deplibs; do + tmp_deplibs="$deplib $tmp_deplibs" + done + deplibs="$tmp_deplibs" + fi + + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan"; then + libs="$deplibs" + deplibs= + fi + if test "$linkmode" = prog; then + case $pass in + dlopen) libs="$dlfiles" ;; + dlpreopen) libs="$dlprefiles" ;; + link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; + esac + fi + if test "$linkmode,$pass" = "lib,dlpreopen"; then + # Collect and forward deplibs of preopened libtool libs + for lib in $dlprefiles; do + # Ignore non-libtool-libs + dependency_libs= + func_resolve_sysroot "$lib" + case $lib in + *.la) func_source "$func_resolve_sysroot_result" ;; + esac + + # Collect preopened libtool deplibs, except any this library + # has declared as weak libs + for deplib in $dependency_libs; do + func_basename "$deplib" + deplib_base=$func_basename_result + case " $weak_libs " in + *" $deplib_base "*) ;; + *) func_append deplibs " $deplib" ;; + esac + done + done + libs="$dlprefiles" + fi + if test "$pass" = dlopen; then + # Collect dlpreopened libraries + save_deplibs="$deplibs" + deplibs= + fi + + for deplib in $libs; do + lib= + found=no + case $deplib in + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ + |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append compiler_flags " $deplib" + if test "$linkmode" = lib ; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -l*) + if test "$linkmode" != lib && test "$linkmode" != prog; then + func_warning "\`-l' is ignored for archives/objects" + continue + fi + func_stripname '-l' '' "$deplib" + name=$func_stripname_result + if test "$linkmode" = lib; then + searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" + else + searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" + fi + for searchdir in $searchdirs; do + for search_ext in .la $std_shrext .so .a; do + # Search the libtool library + lib="$searchdir/lib${name}${search_ext}" + if test -f "$lib"; then + if test "$search_ext" = ".la"; then + found=yes + else + found=no + fi + break 2 + fi + done + done + if test "$found" != yes; then + # deplib doesn't seem to be a libtool library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + else # deplib is a libtool library + # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, + # We need to do some special things here, and not later. + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $deplib "*) + if func_lalib_p "$lib"; then + library_names= + old_library= + func_source "$lib" + for l in $old_library $library_names; do + ll="$l" + done + if test "X$ll" = "X$old_library" ; then # only static version available + found=no + func_dirname "$lib" "" "." + ladir="$func_dirname_result" + lib=$ladir/$old_library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + fi + fi + ;; + *) ;; + esac + fi + fi + ;; # -l + *.ltframework) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + if test "$linkmode" = lib ; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -L*) + case $linkmode in + lib) + deplibs="$deplib $deplibs" + test "$pass" = conv && continue + newdependency_libs="$deplib $newdependency_libs" + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + prog) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + if test "$pass" = scan; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + *) + func_warning "\`-L' is ignored for archives/objects" + ;; + esac # linkmode + continue + ;; # -L + -R*) + if test "$pass" = link; then + func_stripname '-R' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # Make sure the xrpath contains only unique directories. + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + fi + deplibs="$deplib $deplibs" + continue + ;; + *.la) + func_resolve_sysroot "$deplib" + lib=$func_resolve_sysroot_result + ;; + *.$libext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + case $linkmode in + lib) + # Linking convenience modules into shared libraries is allowed, + # but linking other static libraries is non-portable. + case " $dlpreconveniencelibs " in + *" $deplib "*) ;; + *) + valid_a_lib=no + case $deplibs_check_method in + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ + | $EGREP "$match_pattern_regex" > /dev/null; then + valid_a_lib=yes + fi + ;; + pass_all) + valid_a_lib=yes + ;; + esac + if test "$valid_a_lib" != yes; then + echo + $ECHO "*** Warning: Trying to link with static lib archive $deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because the file extensions .$libext of this argument makes me believe" + echo "*** that it is just a static archive that I should not use here." + else + echo + $ECHO "*** Warning: Linking the shared library $output against the" + $ECHO "*** static library $deplib is not portable!" + deplibs="$deplib $deplibs" + fi + ;; + esac + continue + ;; + prog) + if test "$pass" != link; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + continue + ;; + esac # linkmode + ;; # *.$libext + *.lo | *.$objext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + elif test "$linkmode" = prog; then + if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then + # If there is no dlopen support or we're linking statically, + # we need to preload. + func_append newdlprefiles " $deplib" + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append newdlfiles " $deplib" + fi + fi + continue + ;; + %DEPLIBS%) + alldeplibs=yes + continue + ;; + esac # case $deplib + + if test "$found" = yes || test -f "$lib"; then : + else + func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'" + fi + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$lib" \ + || func_fatal_error "\`$lib' is not a valid libtool archive" + + func_dirname "$lib" "" "." + ladir="$func_dirname_result" + + dlname= + dlopen= + dlpreopen= + libdir= + library_names= + old_library= + inherited_linker_flags= + # If the library was installed with an old release of libtool, + # it will not redefine variables installed, or shouldnotlink + installed=yes + shouldnotlink=no + avoidtemprpath= + + + # Read the .la file + func_source "$lib" + + # Convert "-framework foo" to "foo.ltframework" + if test -n "$inherited_linker_flags"; then + tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` + for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do + case " $new_inherited_linker_flags " in + *" $tmp_inherited_linker_flag "*) ;; + *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; + esac + done + fi + dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan" || + { test "$linkmode" != prog && test "$linkmode" != lib; }; then + test -n "$dlopen" && func_append dlfiles " $dlopen" + test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" + fi + + if test "$pass" = conv; then + # Only check for convenience libraries + deplibs="$lib $deplibs" + if test -z "$libdir"; then + if test -z "$old_library"; then + func_fatal_error "cannot find name of link library for \`$lib'" + fi + # It is a libtool convenience library, so add in its objects. + func_append convenience " $ladir/$objdir/$old_library" + func_append old_convenience " $ladir/$objdir/$old_library" + elif test "$linkmode" != prog && test "$linkmode" != lib; then + func_fatal_error "\`$lib' is not a convenience library" + fi + tmp_libs= + for deplib in $dependency_libs; do + deplibs="$deplib $deplibs" + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done + continue + fi # $pass = conv + + + # Get the name of the library we link against. + linklib= + if test -n "$old_library" && + { test "$prefer_static_libs" = yes || + test "$prefer_static_libs,$installed" = "built,no"; }; then + linklib=$old_library + else + for l in $old_library $library_names; do + linklib="$l" + done + fi + if test -z "$linklib"; then + func_fatal_error "cannot find name of link library for \`$lib'" + fi + + # This library was specified with -dlopen. + if test "$pass" = dlopen; then + if test -z "$libdir"; then + func_fatal_error "cannot -dlopen a convenience library: \`$lib'" + fi + if test -z "$dlname" || + test "$dlopen_support" != yes || + test "$build_libtool_libs" = no; then + # If there is no dlname, no dlopen support or we're linking + # statically, we need to preload. We also need to preload any + # dependent libraries so libltdl's deplib preloader doesn't + # bomb out in the load deplibs phase. + func_append dlprefiles " $lib $dependency_libs" + else + func_append newdlfiles " $lib" + fi + continue + fi # $pass = dlopen + + # We need an absolute path. + case $ladir in + [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; + *) + abs_ladir=`cd "$ladir" && pwd` + if test -z "$abs_ladir"; then + func_warning "cannot determine absolute directory name of \`$ladir'" + func_warning "passing it literally to the linker, although it might fail" + abs_ladir="$ladir" + fi + ;; + esac + func_basename "$lib" + laname="$func_basename_result" + + # Find the relevant object directory and library name. + if test "X$installed" = Xyes; then + if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then + func_warning "library \`$lib' was moved." + dir="$ladir" + absdir="$abs_ladir" + libdir="$abs_ladir" + else + dir="$lt_sysroot$libdir" + absdir="$lt_sysroot$libdir" + fi + test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes + else + if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then + dir="$ladir" + absdir="$abs_ladir" + # Remove this search path later + func_append notinst_path " $abs_ladir" + else + dir="$ladir/$objdir" + absdir="$abs_ladir/$objdir" + # Remove this search path later + func_append notinst_path " $abs_ladir" + fi + fi # $installed = yes + func_stripname 'lib' '.la' "$laname" + name=$func_stripname_result + + # This library was specified with -dlpreopen. + if test "$pass" = dlpreopen; then + if test -z "$libdir" && test "$linkmode" = prog; then + func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" + fi + case "$host" in + # special handling for platforms with PE-DLLs. + *cygwin* | *mingw* | *cegcc* ) + # Linker will automatically link against shared library if both + # static and shared are present. Therefore, ensure we extract + # symbols from the import library if a shared library is present + # (otherwise, the dlopen module name will be incorrect). We do + # this by putting the import library name into $newdlprefiles. + # We recover the dlopen module name by 'saving' the la file + # name in a special purpose variable, and (later) extracting the + # dlname from the la file. + if test -n "$dlname"; then + func_tr_sh "$dir/$linklib" + eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" + func_append newdlprefiles " $dir/$linklib" + else + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + fi + ;; + * ) + # Prefer using a static library (so that no silly _DYNAMIC symbols + # are required to link). + if test -n "$old_library"; then + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + # Otherwise, use the dlname, so that lt_dlopen finds it. + elif test -n "$dlname"; then + func_append newdlprefiles " $dir/$dlname" + else + func_append newdlprefiles " $dir/$linklib" + fi + ;; + esac + fi # $pass = dlpreopen + + if test -z "$libdir"; then + # Link the convenience library + if test "$linkmode" = lib; then + deplibs="$dir/$old_library $deplibs" + elif test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$dir/$old_library $compile_deplibs" + finalize_deplibs="$dir/$old_library $finalize_deplibs" + else + deplibs="$lib $deplibs" # used for prog,scan pass + fi + continue + fi + + + if test "$linkmode" = prog && test "$pass" != link; then + func_append newlib_search_path " $ladir" + deplibs="$lib $deplibs" + + linkalldeplibs=no + if test "$link_all_deplibs" != no || test -z "$library_names" || + test "$build_libtool_libs" = no; then + linkalldeplibs=yes + fi + + tmp_libs= + for deplib in $dependency_libs; do + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + esac + # Need to link against all dependency_libs? + if test "$linkalldeplibs" = yes; then + deplibs="$deplib $deplibs" + else + # Need to hardcode shared library paths + # or/and link against static libraries + newdependency_libs="$deplib $newdependency_libs" + fi + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done # for deplib + continue + fi # $linkmode = prog... + + if test "$linkmode,$pass" = "prog,link"; then + if test -n "$library_names" && + { { test "$prefer_static_libs" = no || + test "$prefer_static_libs,$installed" = "built,yes"; } || + test -z "$old_library"; }; then + # We need to hardcode the library path + if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then + # Make sure the rpath contains only unique directories. + case "$temp_rpath:" in + *"$absdir:"*) ;; + *) func_append temp_rpath "$absdir:" ;; + esac + fi + + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi # $linkmode,$pass = prog,link... + + if test "$alldeplibs" = yes && + { test "$deplibs_check_method" = pass_all || + { test "$build_libtool_libs" = yes && + test -n "$library_names"; }; }; then + # We only need to search for static libraries + continue + fi + fi + + link_static=no # Whether the deplib will be linked statically + use_static_libs=$prefer_static_libs + if test "$use_static_libs" = built && test "$installed" = yes; then + use_static_libs=no + fi + if test -n "$library_names" && + { test "$use_static_libs" = no || test -z "$old_library"; }; then + case $host in + *cygwin* | *mingw* | *cegcc*) + # No point in relinking DLLs because paths are not encoded + func_append notinst_deplibs " $lib" + need_relink=no + ;; + *) + if test "$installed" = no; then + func_append notinst_deplibs " $lib" + need_relink=yes + fi + ;; + esac + # This is a shared library + + # Warn about portability, can't link against -module's on some + # systems (darwin). Don't bleat about dlopened modules though! + dlopenmodule="" + for dlpremoduletest in $dlprefiles; do + if test "X$dlpremoduletest" = "X$lib"; then + dlopenmodule="$dlpremoduletest" + break + fi + done + if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then + echo + if test "$linkmode" = prog; then + $ECHO "*** Warning: Linking the executable $output against the loadable module" + else + $ECHO "*** Warning: Linking the shared library $output against the loadable module" + fi + $ECHO "*** $linklib is not portable!" + fi + if test "$linkmode" = lib && + test "$hardcode_into_libs" = yes; then + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi + + if test -n "$old_archive_from_expsyms_cmds"; then + # figure out the soname + set dummy $library_names + shift + realname="$1" + shift + libname=`eval "\\$ECHO \"$libname_spec\""` + # use dlname if we got it. it's perfectly good, no? + if test -n "$dlname"; then + soname="$dlname" + elif test -n "$soname_spec"; then + # bleh windows + case $host in + *cygwin* | mingw* | *cegcc*) + func_arith $current - $age + major=$func_arith_result + versuffix="-$major" + ;; + esac + eval soname=\"$soname_spec\" + else + soname="$realname" + fi + + # Make a new name for the extract_expsyms_cmds to use + soroot="$soname" + func_basename "$soroot" + soname="$func_basename_result" + func_stripname 'lib' '.dll' "$soname" + newlib=libimp-$func_stripname_result.a + + # If the library has no export list, then create one now + if test -f "$output_objdir/$soname-def"; then : + else + func_verbose "extracting exported symbol list from \`$soname'" + func_execute_cmds "$extract_expsyms_cmds" 'exit $?' + fi + + # Create $newlib + if test -f "$output_objdir/$newlib"; then :; else + func_verbose "generating import library for \`$soname'" + func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' + fi + # make sure the library variables are pointing to the new library + dir=$output_objdir + linklib=$newlib + fi # test -n "$old_archive_from_expsyms_cmds" + + if test "$linkmode" = prog || test "$opt_mode" != relink; then + add_shlibpath= + add_dir= + add= + lib_linked=yes + case $hardcode_action in + immediate | unsupported) + if test "$hardcode_direct" = no; then + add="$dir/$linklib" + case $host in + *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; + *-*-sysv4*uw2*) add_dir="-L$dir" ;; + *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ + *-*-unixware7*) add_dir="-L$dir" ;; + *-*-darwin* ) + # if the lib is a (non-dlopened) module then we can not + # link against it, someone is ignoring the earlier warnings + if /usr/bin/file -L $add 2> /dev/null | + $GREP ": [^:]* bundle" >/dev/null ; then + if test "X$dlopenmodule" != "X$lib"; then + $ECHO "*** Warning: lib $linklib is a module, not a shared library" + if test -z "$old_library" ; then + echo + echo "*** And there doesn't seem to be a static archive available" + echo "*** The link will probably fail, sorry" + else + add="$dir/$old_library" + fi + elif test -n "$old_library"; then + add="$dir/$old_library" + fi + fi + esac + elif test "$hardcode_minus_L" = no; then + case $host in + *-*-sunos*) add_shlibpath="$dir" ;; + esac + add_dir="-L$dir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = no; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + relink) + if test "$hardcode_direct" = yes && + test "$hardcode_direct_absolute" = no; then + add="$dir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$absdir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + *) lib_linked=no ;; + esac + + if test "$lib_linked" != yes; then + func_fatal_configuration "unsupported hardcode properties" + fi + + if test -n "$add_shlibpath"; then + case :$compile_shlibpath: in + *":$add_shlibpath:"*) ;; + *) func_append compile_shlibpath "$add_shlibpath:" ;; + esac + fi + if test "$linkmode" = prog; then + test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" + test -n "$add" && compile_deplibs="$add $compile_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + if test "$hardcode_direct" != yes && + test "$hardcode_minus_L" != yes && + test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + fi + fi + fi + + if test "$linkmode" = prog || test "$opt_mode" = relink; then + add_shlibpath= + add_dir= + add= + # Finalize command for both is simple: just hardcode it. + if test "$hardcode_direct" = yes && + test "$hardcode_direct_absolute" = no; then + add="$libdir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$libdir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + add="-l$name" + elif test "$hardcode_automatic" = yes; then + if test -n "$inst_prefix_dir" && + test -f "$inst_prefix_dir$libdir/$linklib" ; then + add="$inst_prefix_dir$libdir/$linklib" + else + add="$libdir/$linklib" + fi + else + # We cannot seem to hardcode it, guess we'll fake it. + add_dir="-L$libdir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + fi + + if test "$linkmode" = prog; then + test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" + test -n "$add" && finalize_deplibs="$add $finalize_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + fi + fi + elif test "$linkmode" = prog; then + # Here we assume that one of hardcode_direct or hardcode_minus_L + # is not unsupported. This is valid on all known static and + # shared platforms. + if test "$hardcode_direct" != unsupported; then + test -n "$old_library" && linklib="$old_library" + compile_deplibs="$dir/$linklib $compile_deplibs" + finalize_deplibs="$dir/$linklib $finalize_deplibs" + else + compile_deplibs="-l$name -L$dir $compile_deplibs" + finalize_deplibs="-l$name -L$dir $finalize_deplibs" + fi + elif test "$build_libtool_libs" = yes; then + # Not a shared library + if test "$deplibs_check_method" != pass_all; then + # We're trying link a shared library against a static one + # but the system doesn't support it. + + # Just print a warning and add the library to dependency_libs so + # that the program can be linked against the static library. + echo + $ECHO "*** Warning: This system can not link to static lib archive $lib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have." + if test "$module" = yes; then + echo "*** But as you try to build a module library, libtool will still create " + echo "*** a static module, that should work as long as the dlopening application" + echo "*** is linked with the -dlopen flag to resolve symbols at runtime." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + else + deplibs="$dir/$old_library $deplibs" + link_static=yes + fi + fi # link shared/static library? + + if test "$linkmode" = lib; then + if test -n "$dependency_libs" && + { test "$hardcode_into_libs" != yes || + test "$build_old_libs" = yes || + test "$link_static" = yes; }; then + # Extract -R from dependency_libs + temp_deplibs= + for libdir in $dependency_libs; do + case $libdir in + -R*) func_stripname '-R' '' "$libdir" + temp_xrpath=$func_stripname_result + case " $xrpath " in + *" $temp_xrpath "*) ;; + *) func_append xrpath " $temp_xrpath";; + esac;; + *) func_append temp_deplibs " $libdir";; + esac + done + dependency_libs="$temp_deplibs" + fi + + func_append newlib_search_path " $absdir" + # Link against this library + test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" + # ... and its dependency_libs + tmp_libs= + for deplib in $dependency_libs; do + newdependency_libs="$deplib $newdependency_libs" + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result";; + *) func_resolve_sysroot "$deplib" ;; + esac + if $opt_preserve_dup_deps ; then + case "$tmp_libs " in + *" $func_resolve_sysroot_result "*) + func_append specialdeplibs " $func_resolve_sysroot_result" ;; + esac + fi + func_append tmp_libs " $func_resolve_sysroot_result" + done + + if test "$link_all_deplibs" != no; then + # Add the search paths of all dependency libraries + for deplib in $dependency_libs; do + path= + case $deplib in + -L*) path="$deplib" ;; + *.la) + func_resolve_sysroot "$deplib" + deplib=$func_resolve_sysroot_result + func_dirname "$deplib" "" "." + dir=$func_dirname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; + *) + absdir=`cd "$dir" && pwd` + if test -z "$absdir"; then + func_warning "cannot determine absolute directory name of \`$dir'" + absdir="$dir" + fi + ;; + esac + if $GREP "^installed=no" $deplib > /dev/null; then + case $host in + *-*-darwin*) + depdepl= + eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` + if test -n "$deplibrary_names" ; then + for tmp in $deplibrary_names ; do + depdepl=$tmp + done + if test -f "$absdir/$objdir/$depdepl" ; then + depdepl="$absdir/$objdir/$depdepl" + darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + if test -z "$darwin_install_name"; then + darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + fi + func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" + func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" + path= + fi + fi + ;; + *) + path="-L$absdir/$objdir" + ;; + esac + else + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + test -z "$libdir" && \ + func_fatal_error "\`$deplib' is not a valid libtool archive" + test "$absdir" != "$libdir" && \ + func_warning "\`$deplib' seems to be moved" + + path="-L$absdir" + fi + ;; + esac + case " $deplibs " in + *" $path "*) ;; + *) deplibs="$path $deplibs" ;; + esac + done + fi # link_all_deplibs != no + fi # linkmode = lib + done # for deplib in $libs + if test "$pass" = link; then + if test "$linkmode" = "prog"; then + compile_deplibs="$new_inherited_linker_flags $compile_deplibs" + finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" + else + compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + fi + fi + dependency_libs="$newdependency_libs" + if test "$pass" = dlpreopen; then + # Link the dlpreopened libraries before other libraries + for deplib in $save_deplibs; do + deplibs="$deplib $deplibs" + done + fi + if test "$pass" != dlopen; then + if test "$pass" != conv; then + # Make sure lib_search_path contains only unique directories. + lib_search_path= + for dir in $newlib_search_path; do + case "$lib_search_path " in + *" $dir "*) ;; + *) func_append lib_search_path " $dir" ;; + esac + done + newlib_search_path= + fi + + if test "$linkmode,$pass" != "prog,link"; then + vars="deplibs" + else + vars="compile_deplibs finalize_deplibs" + fi + for var in $vars dependency_libs; do + # Add libraries to $var in reverse order + eval tmp_libs=\"\$$var\" + new_libs= + for deplib in $tmp_libs; do + # FIXME: Pedantically, this is the right thing to do, so + # that some nasty dependency loop isn't accidentally + # broken: + #new_libs="$deplib $new_libs" + # Pragmatically, this seems to cause very few problems in + # practice: + case $deplib in + -L*) new_libs="$deplib $new_libs" ;; + -R*) ;; + *) + # And here is the reason: when a library appears more + # than once as an explicit dependence of a library, or + # is implicitly linked in more than once by the + # compiler, it is considered special, and multiple + # occurrences thereof are not removed. Compare this + # with having the same library being listed as a + # dependency of multiple other libraries: in this case, + # we know (pedantically, we assume) the library does not + # need to be listed more than once, so we keep only the + # last copy. This is not always right, but it is rare + # enough that we require users that really mean to play + # such unportable linking tricks to link the library + # using -Wl,-lname, so that libtool does not consider it + # for duplicate removal. + case " $specialdeplibs " in + *" $deplib "*) new_libs="$deplib $new_libs" ;; + *) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$deplib $new_libs" ;; + esac + ;; + esac + ;; + esac + done + tmp_libs= + for deplib in $new_libs; do + case $deplib in + -L*) + case " $tmp_libs " in + *" $deplib "*) ;; + *) func_append tmp_libs " $deplib" ;; + esac + ;; + *) func_append tmp_libs " $deplib" ;; + esac + done + eval $var=\"$tmp_libs\" + done # for var + fi + # Last step: remove runtime libs from dependency_libs + # (they stay in deplibs) + tmp_libs= + for i in $dependency_libs ; do + case " $predeps $postdeps $compiler_lib_search_path " in + *" $i "*) + i="" + ;; + esac + if test -n "$i" ; then + func_append tmp_libs " $i" + fi + done + dependency_libs=$tmp_libs + done # for pass + if test "$linkmode" = prog; then + dlfiles="$newdlfiles" + fi + if test "$linkmode" = prog || test "$linkmode" = lib; then + dlprefiles="$newdlprefiles" + fi + + case $linkmode in + oldlib) + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + func_warning "\`-dlopen' is ignored for archives" + fi + + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "\`-l' and \`-L' are ignored for archives" ;; + esac + + test -n "$rpath" && \ + func_warning "\`-rpath' is ignored for archives" + + test -n "$xrpath" && \ + func_warning "\`-R' is ignored for archives" + + test -n "$vinfo" && \ + func_warning "\`-version-info/-version-number' is ignored for archives" + + test -n "$release" && \ + func_warning "\`-release' is ignored for archives" + + test -n "$export_symbols$export_symbols_regex" && \ + func_warning "\`-export-symbols' is ignored for archives" + + # Now set the variables for building old libraries. + build_libtool_libs=no + oldlibs="$output" + func_append objs "$old_deplibs" + ;; + + lib) + # Make sure we only generate libraries of the form `libNAME.la'. + case $outputname in + lib*) + func_stripname 'lib' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + ;; + *) + test "$module" = no && \ + func_fatal_help "libtool library \`$output' must begin with \`lib'" + + if test "$need_lib_prefix" != no; then + # Add the "lib" prefix for modules if required + func_stripname '' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + else + func_stripname '' '.la' "$outputname" + libname=$func_stripname_result + fi + ;; + esac + + if test -n "$objs"; then + if test "$deplibs_check_method" != pass_all; then + func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs" + else + echo + $ECHO "*** Warning: Linking the shared library $output against the non-libtool" + $ECHO "*** objects $objs is not portable!" + func_append libobjs " $objs" + fi + fi + + test "$dlself" != no && \ + func_warning "\`-dlopen self' is ignored for libtool libraries" + + set dummy $rpath + shift + test "$#" -gt 1 && \ + func_warning "ignoring multiple \`-rpath's for a libtool library" + + install_libdir="$1" + + oldlibs= + if test -z "$rpath"; then + if test "$build_libtool_libs" = yes; then + # Building a libtool convenience library. + # Some compilers have problems with a `.al' extension so + # convenience libraries should have the same extension an + # archive normally would. + oldlibs="$output_objdir/$libname.$libext $oldlibs" + build_libtool_libs=convenience + build_old_libs=yes + fi + + test -n "$vinfo" && \ + func_warning "\`-version-info/-version-number' is ignored for convenience libraries" + + test -n "$release" && \ + func_warning "\`-release' is ignored for convenience libraries" + else + + # Parse the version information argument. + save_ifs="$IFS"; IFS=':' + set dummy $vinfo 0 0 0 + shift + IFS="$save_ifs" + + test -n "$7" && \ + func_fatal_help "too many parameters to \`-version-info'" + + # convert absolute version numbers to libtool ages + # this retains compatibility with .la files and attempts + # to make the code below a bit more comprehensible + + case $vinfo_number in + yes) + number_major="$1" + number_minor="$2" + number_revision="$3" + # + # There are really only two kinds -- those that + # use the current revision as the major version + # and those that subtract age and use age as + # a minor version. But, then there is irix + # which has an extra 1 added just for fun + # + case $version_type in + # correct linux to gnu/linux during the next big refactor + darwin|linux|osf|windows|none) + func_arith $number_major + $number_minor + current=$func_arith_result + age="$number_minor" + revision="$number_revision" + ;; + freebsd-aout|freebsd-elf|qnx|sunos) + current="$number_major" + revision="$number_minor" + age="0" + ;; + irix|nonstopux) + func_arith $number_major + $number_minor + current=$func_arith_result + age="$number_minor" + revision="$number_minor" + lt_irix_increment=no + ;; + esac + ;; + no) + current="$1" + revision="$2" + age="$3" + ;; + esac + + # Check that each of the things are valid numbers. + case $current in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "CURRENT \`$current' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + case $revision in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "REVISION \`$revision' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + case $age in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "AGE \`$age' must be a nonnegative integer" + func_fatal_error "\`$vinfo' is not valid version information" + ;; + esac + + if test "$age" -gt "$current"; then + func_error "AGE \`$age' is greater than the current interface number \`$current'" + func_fatal_error "\`$vinfo' is not valid version information" + fi + + # Calculate the version variables. + major= + versuffix= + verstring= + case $version_type in + none) ;; + + darwin) + # Like Linux, but with the current version available in + # verstring for coding it into the library header + func_arith $current - $age + major=.$func_arith_result + versuffix="$major.$age.$revision" + # Darwin ld doesn't like 0 for these options... + func_arith $current + 1 + minor_current=$func_arith_result + xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" + verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" + ;; + + freebsd-aout) + major=".$current" + versuffix=".$current.$revision"; + ;; + + freebsd-elf) + major=".$current" + versuffix=".$current" + ;; + + irix | nonstopux) + if test "X$lt_irix_increment" = "Xno"; then + func_arith $current - $age + else + func_arith $current - $age + 1 + fi + major=$func_arith_result + + case $version_type in + nonstopux) verstring_prefix=nonstopux ;; + *) verstring_prefix=sgi ;; + esac + verstring="$verstring_prefix$major.$revision" + + # Add in all the interfaces that we are compatible with. + loop=$revision + while test "$loop" -ne 0; do + func_arith $revision - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring="$verstring_prefix$major.$iface:$verstring" + done + + # Before this point, $major must not contain `.'. + major=.$major + versuffix="$major.$revision" + ;; + + linux) # correct to gnu/linux during the next big refactor + func_arith $current - $age + major=.$func_arith_result + versuffix="$major.$age.$revision" + ;; + + osf) + func_arith $current - $age + major=.$func_arith_result + versuffix=".$current.$age.$revision" + verstring="$current.$age.$revision" + + # Add in all the interfaces that we are compatible with. + loop=$age + while test "$loop" -ne 0; do + func_arith $current - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring="$verstring:${iface}.0" + done + + # Make executables depend on our current version. + func_append verstring ":${current}.0" + ;; + + qnx) + major=".$current" + versuffix=".$current" + ;; + + sunos) + major=".$current" + versuffix=".$current.$revision" + ;; + + windows) + # Use '-' rather than '.', since we only want one + # extension on DOS 8.3 filesystems. + func_arith $current - $age + major=$func_arith_result + versuffix="-$major" + ;; + + *) + func_fatal_configuration "unknown library version type \`$version_type'" + ;; + esac + + # Clear the version info if we defaulted, and they specified a release. + if test -z "$vinfo" && test -n "$release"; then + major= + case $version_type in + darwin) + # we can't check for "0.0" in archive_cmds due to quoting + # problems, so we reset it completely + verstring= + ;; + *) + verstring="0.0" + ;; + esac + if test "$need_version" = no; then + versuffix= + else + versuffix=".0.0" + fi + fi + + # Remove version info from name if versioning should be avoided + if test "$avoid_version" = yes && test "$need_version" = no; then + major= + versuffix= + verstring="" + fi + + # Check to see if the archive will have undefined symbols. + if test "$allow_undefined" = yes; then + if test "$allow_undefined_flag" = unsupported; then + func_warning "undefined symbols not allowed in $host shared libraries" + build_libtool_libs=no + build_old_libs=yes + fi + else + # Don't allow undefined symbols. + allow_undefined_flag="$no_undefined_flag" + fi + + fi + + func_generate_dlsyms "$libname" "$libname" "yes" + func_append libobjs " $symfileobj" + test "X$libobjs" = "X " && libobjs= + + if test "$opt_mode" != relink; then + # Remove our outputs, but don't remove object files since they + # may have been created when compiling PIC objects. + removelist= + tempremovelist=`$ECHO "$output_objdir/*"` + for p in $tempremovelist; do + case $p in + *.$objext | *.gcno) + ;; + $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) + if test "X$precious_files_regex" != "X"; then + if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 + then + continue + fi + fi + func_append removelist " $p" + ;; + *) ;; + esac + done + test -n "$removelist" && \ + func_show_eval "${RM}r \$removelist" + fi + + # Now set the variables for building old libraries. + if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then + func_append oldlibs " $output_objdir/$libname.$libext" + + # Transform .lo files to .o files. + oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP` + fi + + # Eliminate all temporary directories. + #for path in $notinst_path; do + # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` + # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` + # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` + #done + + if test -n "$xrpath"; then + # If the user specified any rpath flags, then add them. + temp_xrpath= + for libdir in $xrpath; do + func_replace_sysroot "$libdir" + func_append temp_xrpath " -R$func_replace_sysroot_result" + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + done + if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then + dependency_libs="$temp_xrpath $dependency_libs" + fi + fi + + # Make sure dlfiles contains only unique files that won't be dlpreopened + old_dlfiles="$dlfiles" + dlfiles= + for lib in $old_dlfiles; do + case " $dlprefiles $dlfiles " in + *" $lib "*) ;; + *) func_append dlfiles " $lib" ;; + esac + done + + # Make sure dlprefiles contains only unique files + old_dlprefiles="$dlprefiles" + dlprefiles= + for lib in $old_dlprefiles; do + case "$dlprefiles " in + *" $lib "*) ;; + *) func_append dlprefiles " $lib" ;; + esac + done + + if test "$build_libtool_libs" = yes; then + if test -n "$rpath"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) + # these systems don't actually have a c library (as such)! + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C library is in the System framework + func_append deplibs " System.ltframework" + ;; + *-*-netbsd*) + # Don't link with libc until the a.out ld.so is fixed. + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + ;; + *) + # Add libc to deplibs on all other systems if necessary. + if test "$build_libtool_need_lc" = "yes"; then + func_append deplibs " -lc" + fi + ;; + esac + fi + + # Transform deplibs into only deplibs that can be linked in shared. + name_save=$name + libname_save=$libname + release_save=$release + versuffix_save=$versuffix + major_save=$major + # I'm not sure if I'm treating the release correctly. I think + # release should show up in the -l (ie -lgmp5) so we don't want to + # add it in twice. Is that correct? + release="" + versuffix="" + major="" + newdeplibs= + droppeddeps=no + case $deplibs_check_method in + pass_all) + # Don't check for shared/static. Everything works. + # This might be a little naive. We might want to check + # whether the library exists or not. But this is on + # osf3 & osf4 and I'm not really sure... Just + # implementing what was already the behavior. + newdeplibs=$deplibs + ;; + test_compile) + # This code stresses the "libraries are programs" paradigm to its + # limits. Maybe even breaks it. We compile a program, linking it + # against the deplibs as a proxy for the library. Then we can check + # whether they linked in statically or dynamically with ldd. + $opt_dry_run || $RM conftest.c + cat > conftest.c </dev/null` + $nocaseglob + else + potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` + fi + for potent_lib in $potential_libs; do + # Follow soft links. + if ls -lLd "$potent_lib" 2>/dev/null | + $GREP " -> " >/dev/null; then + continue + fi + # The statement above tries to avoid entering an + # endless loop below, in case of cyclic links. + # We might still enter an endless loop, since a link + # loop can be closed while we follow links, + # but so what? + potlib="$potent_lib" + while test -h "$potlib" 2>/dev/null; do + potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` + case $potliblink in + [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; + *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";; + esac + done + if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | + $SED -e 10q | + $EGREP "$file_magic_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $ECHO "*** with $libname but no candidates were found. (...for file magic test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a file magic. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + for a_deplib in $deplibs; do + case $a_deplib in + -l*) + func_stripname -l '' "$a_deplib" + name=$func_stripname_result + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $a_deplib "*) + func_append newdeplibs " $a_deplib" + a_deplib="" + ;; + esac + fi + if test -n "$a_deplib" ; then + libname=`eval "\\$ECHO \"$libname_spec\""` + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do + potential_libs=`ls $i/$libname[.-]* 2>/dev/null` + for potent_lib in $potential_libs; do + potlib="$potent_lib" # see symlink-check above in file_magic test + if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ + $EGREP "$match_pattern_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a regex pattern. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + none | unknown | *) + newdeplibs="" + tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + for i in $predeps $postdeps ; do + # can't use Xsed below, because $i might contain '/' + tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"` + done + fi + case $tmp_deplibs in + *[!\ \ ]*) + echo + if test "X$deplibs_check_method" = "Xnone"; then + echo "*** Warning: inter-library dependencies are not supported in this platform." + else + echo "*** Warning: inter-library dependencies are not known to be supported." + fi + echo "*** All declared inter-library dependencies are being dropped." + droppeddeps=yes + ;; + esac + ;; + esac + versuffix=$versuffix_save + major=$major_save + release=$release_save + libname=$libname_save + name=$name_save + + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library with the System framework + newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` + ;; + esac + + if test "$droppeddeps" = yes; then + if test "$module" = yes; then + echo + echo "*** Warning: libtool could not satisfy all declared inter-library" + $ECHO "*** dependencies of module $libname. Therefore, libtool will create" + echo "*** a static module, that should work as long as the dlopening" + echo "*** application is linked with the -dlopen flag." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + else + echo "*** The inter-library dependencies that have been dropped here will be" + echo "*** automatically added whenever a program is linked with this library" + echo "*** or is declared to -dlopen it." + + if test "$allow_undefined" = no; then + echo + echo "*** Since this library must not contain undefined symbols," + echo "*** because either the platform does not support them or" + echo "*** it was explicitly requested with -no-undefined," + echo "*** libtool will only create a static version of it." + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + fi + fi + # Done checking deplibs! + deplibs=$newdeplibs + fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + case $host in + *-*-darwin*) + newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac + + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; + esac + done + deplibs="$new_libs" + + # All the library-specific variables (install_libdir is set above). + library_names= + old_library= + dlname= + + # Test again, we may have decided not to build it any more + if test "$build_libtool_libs" = yes; then + # Remove ${wl} instances when linking with ld. + # FIXME: should test the right _cmds variable. + case $archive_cmds in + *\$LD\ *) wl= ;; + esac + if test "$hardcode_into_libs" = yes; then + # Hardcode the library paths + hardcode_libdirs= + dep_rpath= + rpath="$finalize_rpath" + test "$opt_mode" != relink && rpath="$compile_rpath$rpath" + for libdir in $rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + func_replace_sysroot "$libdir" + libdir=$func_replace_sysroot_result + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append dep_rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) func_append perm_rpath " $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" + fi + if test -n "$runpath_var" && test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" + fi + test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" + fi + + shlibpath="$finalize_shlibpath" + test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" + if test -n "$shlibpath"; then + eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" + fi + + # Get the real and link names of the library. + eval shared_ext=\"$shrext_cmds\" + eval library_names=\"$library_names_spec\" + set dummy $library_names + shift + realname="$1" + shift + + if test -n "$soname_spec"; then + eval soname=\"$soname_spec\" + else + soname="$realname" + fi + if test -z "$dlname"; then + dlname=$soname + fi + + lib="$output_objdir/$realname" + linknames= + for link + do + func_append linknames " $link" + done + + # Use standard objects if they are pic + test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` + test "X$libobjs" = "X " && libobjs= + + delfiles= + if test -n "$export_symbols" && test -n "$include_expsyms"; then + $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" + export_symbols="$output_objdir/$libname.uexp" + func_append delfiles " $export_symbols" + fi + + orig_export_symbols= + case $host_os in + cygwin* | mingw* | cegcc*) + if test -n "$export_symbols" && test -z "$export_symbols_regex"; then + # exporting using user supplied symfile + if test "x`$SED 1q $export_symbols`" != xEXPORTS; then + # and it's NOT already a .def file. Must figure out + # which of the given symbols are data symbols and tag + # them as such. So, trigger use of export_symbols_cmds. + # export_symbols gets reassigned inside the "prepare + # the list of exported symbols" if statement, so the + # include_expsyms logic still works. + orig_export_symbols="$export_symbols" + export_symbols= + always_export_symbols=yes + fi + fi + ;; + esac + + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then + func_verbose "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $opt_dry_run || $RM $export_symbols + cmds=$export_symbols_cmds + save_ifs="$IFS"; IFS='~' + for cmd1 in $cmds; do + IFS="$save_ifs" + # Take the normal branch if the nm_file_list_spec branch + # doesn't work or if tool conversion is not needed. + case $nm_file_list_spec~$to_tool_file_cmd in + *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) + try_normal_branch=yes + eval cmd=\"$cmd1\" + func_len " $cmd" + len=$func_len_result + ;; + *) + try_normal_branch=no + ;; + esac + if test "$try_normal_branch" = yes \ + && { test "$len" -lt "$max_cmd_len" \ + || test "$max_cmd_len" -le -1; } + then + func_show_eval "$cmd" 'exit $?' + skipped_export=false + elif test -n "$nm_file_list_spec"; then + func_basename "$output" + output_la=$func_basename_result + save_libobjs=$libobjs + save_output=$output + output=${output_objdir}/${output_la}.nm + func_to_tool_file "$output" + libobjs=$nm_file_list_spec$func_to_tool_file_result + func_append delfiles " $output" + func_verbose "creating $NM input file list: $output" + for obj in $save_libobjs; do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > "$output" + eval cmd=\"$cmd1\" + func_show_eval "$cmd" 'exit $?' + output=$save_output + libobjs=$save_libobjs + skipped_export=false + else + # The command line is too long to execute in one step. + func_verbose "using reloadable object file for export list..." + skipped_export=: + # Break out early, otherwise skipped_export may be + # set to false by a later but shorter cmd. + break + fi + done + IFS="$save_ifs" + if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi + fi + + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols="$export_symbols" + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi + + if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi + + tmp_deplibs= + for test_deplib in $deplibs; do + case " $convenience " in + *" $test_deplib "*) ;; + *) + func_append tmp_deplibs " $test_deplib" + ;; + esac + done + deplibs="$tmp_deplibs" + + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec" && + test "$compiler_needs_object" = yes && + test -z "$libobjs"; then + # extract the archives, so we have objects to list. + # TODO: could optimize this to just extract one archive. + whole_archive_flag_spec= + fi + if test -n "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + else + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $convenience + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= + fi + fi + + if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then + eval flag=\"$thread_safe_flag_spec\" + func_append linker_flags " $flag" + fi + + # Make a backup of the uninstalled library when relinking + if test "$opt_mode" = relink; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? + fi + + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + eval test_cmds=\"$module_expsym_cmds\" + cmds=$module_expsym_cmds + else + eval test_cmds=\"$module_cmds\" + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + eval test_cmds=\"$archive_expsym_cmds\" + cmds=$archive_expsym_cmds + else + eval test_cmds=\"$archive_cmds\" + cmds=$archive_cmds + fi + fi + + if test "X$skipped_export" != "X:" && + func_len " $test_cmds" && + len=$func_len_result && + test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + : + else + # The command line is too long to link in one step, link piecewise + # or, if using GNU ld and skipped_export is not :, use a linker + # script. + + # Save the value of $output and $libobjs because we want to + # use them later. If we have whole_archive_flag_spec, we + # want to use save_libobjs as it was before + # whole_archive_flag_spec was expanded, because we can't + # assume the linker understands whole_archive_flag_spec. + # This may have to be revisited, in case too many + # convenience libraries get linked in and end up exceeding + # the spec. + if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + fi + save_output=$output + func_basename "$output" + output_la=$func_basename_result + + # Clear the reloadable object creation command queue and + # initialize k to one. + test_cmds= + concat_cmds= + objlist= + last_robj= + k=1 + + if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then + output=${output_objdir}/${output_la}.lnkscript + func_verbose "creating GNU ld script: $output" + echo 'INPUT (' > $output + for obj in $save_libobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + echo ')' >> $output + func_append delfiles " $output" + func_to_tool_file "$output" + output=$func_to_tool_file_result + elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then + output=${output_objdir}/${output_la}.lnk + func_verbose "creating linker input file list: $output" + : > $output + set x $save_libobjs + shift + firstobj= + if test "$compiler_needs_object" = yes; then + firstobj="$1 " + shift + fi + for obj + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + func_append delfiles " $output" + func_to_tool_file "$output" + output=$firstobj\"$file_list_spec$func_to_tool_file_result\" + else + if test -n "$save_libobjs"; then + func_verbose "creating reloadable object files..." + output=$output_objdir/$output_la-${k}.$objext + eval test_cmds=\"$reload_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + + # Loop over the list of objects to be linked. + for obj in $save_libobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + if test "X$objlist" = X || + test "$len" -lt "$max_cmd_len"; then + func_append objlist " $obj" + else + # The command $test_cmds is almost too long, add a + # command to the queue. + if test "$k" -eq 1 ; then + # The first file doesn't have a previous command to add. + reload_objs=$objlist + eval concat_cmds=\"$reload_cmds\" + else + # All subsequent reloadable object files will link in + # the last one created. + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" + fi + last_robj=$output_objdir/$output_la-${k}.$objext + func_arith $k + 1 + k=$func_arith_result + output=$output_objdir/$output_la-${k}.$objext + objlist=" $obj" + func_len " $last_robj" + func_arith $len0 + $func_len_result + len=$func_arith_result + fi + done + # Handle the remaining objects by creating one last + # reloadable object file. All subsequent reloadable object + # files will link in the last one created. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\${concat_cmds}$reload_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" + fi + func_append delfiles " $output" + + else + output= + fi + + if ${skipped_export-false}; then + func_verbose "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $opt_dry_run || $RM $export_symbols + libobjs=$output + # Append the command to create the export file. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" + fi + fi + + test -n "$save_libobjs" && + func_verbose "creating a temporary reloadable object file: $output" + + # Loop through the commands generated above and execute them. + save_ifs="$IFS"; IFS='~' + for cmd in $concat_cmds; do + IFS="$save_ifs" + $opt_silent || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi + + exit $lt_exit + } + done + IFS="$save_ifs" + + if test -n "$export_symbols_regex" && ${skipped_export-false}; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi + + if ${skipped_export-false}; then + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols="$export_symbols" + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi + + if test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi + fi + + libobjs=$output + # Restore the value of output. + output=$save_output + + if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + fi + # Expand the library linking commands again to reset the + # value of $libobjs for piecewise linking. + + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + cmds=$module_expsym_cmds + else + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + cmds=$archive_expsym_cmds + else + cmds=$archive_cmds + fi + fi + fi + + if test -n "$delfiles"; then + # Append the command to remove temporary files to $cmds. + eval cmds=\"\$cmds~\$RM $delfiles\" + fi + + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $dlprefiles + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= + fi + + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $opt_silent || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi + + exit $lt_exit + } + done + IFS="$save_ifs" + + # Restore the uninstalled library and exit + if test "$opt_mode" = relink; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? + + if test -n "$convenience"; then + if test -z "$whole_archive_flag_spec"; then + func_show_eval '${RM}r "$gentop"' + fi + fi + + exit $EXIT_SUCCESS + fi + + # Create links to the real library. + for linkname in $linknames; do + if test "$realname" != "$linkname"; then + func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' + fi + done + + # If -module or -export-dynamic was specified, set the dlname. + if test "$module" = yes || test "$export_dynamic" = yes; then + # On all known operating systems, these are identical. + dlname="$soname" + fi + fi + ;; + + obj) + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + func_warning "\`-dlopen' is ignored for objects" + fi + + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "\`-l' and \`-L' are ignored for objects" ;; + esac + + test -n "$rpath" && \ + func_warning "\`-rpath' is ignored for objects" + + test -n "$xrpath" && \ + func_warning "\`-R' is ignored for objects" + + test -n "$vinfo" && \ + func_warning "\`-version-info' is ignored for objects" + + test -n "$release" && \ + func_warning "\`-release' is ignored for objects" + + case $output in + *.lo) + test -n "$objs$old_deplibs" && \ + func_fatal_error "cannot build library object \`$output' from non-libtool objects" + + libobj=$output + func_lo2o "$libobj" + obj=$func_lo2o_result + ;; + *) + libobj= + obj="$output" + ;; + esac + + # Delete the old objects. + $opt_dry_run || $RM $obj $libobj + + # Objects from convenience libraries. This assumes + # single-version convenience libraries. Whenever we create + # different ones for PIC/non-PIC, this we'll have to duplicate + # the extraction. + reload_conv_objs= + gentop= + # reload_cmds runs $LD directly, so let us get rid of + # -Wl from whole_archive_flag_spec and hope we can get by with + # turning comma into space.. + wl= + + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec"; then + eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" + reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` + else + gentop="$output_objdir/${obj}x" + func_append generated " $gentop" + + func_extract_archives $gentop $convenience + reload_conv_objs="$reload_objs $func_extract_archives_result" + fi + fi + + # If we're not building shared, we need to use non_pic_objs + test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" + + # Create the old-style object. + reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test + + output="$obj" + func_execute_cmds "$reload_cmds" 'exit $?' + + # Exit if we aren't doing a library object file. + if test -z "$libobj"; then + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS + fi + + if test "$build_libtool_libs" != yes; then + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + # Create an invalid libtool object if no PIC, so that we don't + # accidentally link it into a program. + # $show "echo timestamp > $libobj" + # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? + exit $EXIT_SUCCESS + fi + + if test -n "$pic_flag" || test "$pic_mode" != default; then + # Only do commands if we really have different PIC objects. + reload_objs="$libobjs $reload_conv_objs" + output="$libobj" + func_execute_cmds "$reload_cmds" 'exit $?' + fi + + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS + ;; + + prog) + case $host in + *cygwin*) func_stripname '' '.exe' "$output" + output=$func_stripname_result.exe;; + esac + test -n "$vinfo" && \ + func_warning "\`-version-info' is ignored for programs" + + test -n "$release" && \ + func_warning "\`-release' is ignored for programs" + + test "$preload" = yes \ + && test "$dlopen_support" = unknown \ + && test "$dlopen_self" = unknown \ + && test "$dlopen_self_static" = unknown && \ + func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support." + + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library is the System framework + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` + ;; + esac + + case $host in + *-*-darwin*) + # Don't allow lazy linking, it breaks C++ global constructors + # But is supposedly fixed on 10.4 or later (yay!). + if test "$tagname" = CXX ; then + case ${MACOSX_DEPLOYMENT_TARGET-10.0} in + 10.[0123]) + func_append compile_command " ${wl}-bind_at_load" + func_append finalize_command " ${wl}-bind_at_load" + ;; + esac + fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac + + + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $compile_deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $compile_deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; + esac + done + compile_deplibs="$new_libs" + + + func_append compile_command " $compile_deplibs" + func_append finalize_command " $finalize_deplibs" + + if test -n "$rpath$xrpath"; then + # If the user specified any rpath flags, then add them. + for libdir in $rpath $xrpath; do + # This is the magic to use -rpath. + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + done + fi + + # Now hardcode the library paths + rpath= + hardcode_libdirs= + for libdir in $compile_rpath $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) func_append perm_rpath " $libdir" ;; + esac + fi + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$libdir:"*) ;; + ::) dllsearchpath=$libdir;; + *) func_append dllsearchpath ":$libdir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + compile_rpath="$rpath" + + rpath= + hardcode_libdirs= + for libdir in $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$finalize_perm_rpath " in + *" $libdir "*) ;; + *) func_append finalize_perm_rpath " $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + finalize_rpath="$rpath" + + if test -n "$libobjs" && test "$build_old_libs" = yes; then + # Transform all the library objects into standard objects. + compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + fi + + func_generate_dlsyms "$outputname" "@PROGRAM@" "no" + + # template prelinking step + if test -n "$prelink_cmds"; then + func_execute_cmds "$prelink_cmds" 'exit $?' + fi + + wrappers_required=yes + case $host in + *cegcc* | *mingw32ce*) + # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. + wrappers_required=no + ;; + *cygwin* | *mingw* ) + if test "$build_libtool_libs" != yes; then + wrappers_required=no + fi + ;; + *) + if test "$need_relink" = no || test "$build_libtool_libs" != yes; then + wrappers_required=no + fi + ;; + esac + if test "$wrappers_required" = no; then + # Replace the output file specification. + compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + link_command="$compile_command$compile_rpath" + + # We have no uninstalled library dependencies, so finalize right now. + exit_status=0 + func_show_eval "$link_command" 'exit_status=$?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + # Delete the generated files. + if test -f "$output_objdir/${outputname}S.${objext}"; then + func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' + fi + + exit $exit_status + fi + + if test -n "$compile_shlibpath$finalize_shlibpath"; then + compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" + fi + if test -n "$finalize_shlibpath"; then + finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" + fi + + compile_var= + finalize_var= + if test -n "$runpath_var"; then + if test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + compile_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + if test -n "$finalize_perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $finalize_perm_rpath; do + func_append rpath "$dir:" + done + finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + fi + + if test "$no_install" = yes; then + # We don't need to create a wrapper script. + link_command="$compile_var$compile_command$compile_rpath" + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + # Delete the old output file. + $opt_dry_run || $RM $output + # Link the executable and exit + func_show_eval "$link_command" 'exit $?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + exit $EXIT_SUCCESS + fi + + if test "$hardcode_action" = relink; then + # Fast installation is not supported + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" + + func_warning "this platform does not like uninstalled shared libraries" + func_warning "\`$output' will be relinked during installation" + else + if test "$fast_install" != no; then + link_command="$finalize_var$compile_command$finalize_rpath" + if test "$fast_install" = yes; then + relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` + else + # fast_install is set to needless + relink_command= + fi + else + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" + fi + fi + + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` + + # Delete the old output files. + $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname + + func_show_eval "$link_command" 'exit $?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output_objdir/$outputname" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + # Now create the wrapper script. + func_verbose "creating $output" + + # Quote the relink command for shipping. + if test -n "$relink_command"; then + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + fi + done + relink_command="(cd `pwd`; $relink_command)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + fi + + # Only actually do things if not in dry run mode. + $opt_dry_run || { + # win32 will think the script is a binary if it has + # a .exe suffix, so we strip it off here. + case $output in + *.exe) func_stripname '' '.exe' "$output" + output=$func_stripname_result ;; + esac + # test for cygwin because mv fails w/o .exe extensions + case $host in + *cygwin*) + exeext=.exe + func_stripname '' '.exe' "$outputname" + outputname=$func_stripname_result ;; + *) exeext= ;; + esac + case $host in + *cygwin* | *mingw* ) + func_dirname_and_basename "$output" "" "." + output_name=$func_basename_result + output_path=$func_dirname_result + cwrappersource="$output_path/$objdir/lt-$output_name.c" + cwrapper="$output_path/$output_name.exe" + $RM $cwrappersource $cwrapper + trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 + + func_emit_cwrapperexe_src > $cwrappersource + + # The wrapper executable is built using the $host compiler, + # because it contains $host paths and files. If cross- + # compiling, it, like the target executable, must be + # executed on the $host or under an emulation environment. + $opt_dry_run || { + $LTCC $LTCFLAGS -o $cwrapper $cwrappersource + $STRIP $cwrapper + } + + # Now, create the wrapper script for func_source use: + func_ltwrapper_scriptname $cwrapper + $RM $func_ltwrapper_scriptname_result + trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 + $opt_dry_run || { + # note: this script will not be executed, so do not chmod. + if test "x$build" = "x$host" ; then + $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result + else + func_emit_wrapper no > $func_ltwrapper_scriptname_result + fi + } + ;; + * ) + $RM $output + trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 + + func_emit_wrapper no > $output + chmod +x $output + ;; + esac + } + exit $EXIT_SUCCESS + ;; + esac + + # See if we need to build an old-fashioned archive. + for oldlib in $oldlibs; do + + if test "$build_libtool_libs" = convenience; then + oldobjs="$libobjs_save $symfileobj" + addlibs="$convenience" + build_libtool_libs=no + else + if test "$build_libtool_libs" = module; then + oldobjs="$libobjs_save" + build_libtool_libs=no + else + oldobjs="$old_deplibs $non_pic_objects" + if test "$preload" = yes && test -f "$symfileobj"; then + func_append oldobjs " $symfileobj" + fi + fi + addlibs="$old_convenience" + fi + + if test -n "$addlibs"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $addlibs + func_append oldobjs " $func_extract_archives_result" + fi + + # Do each command in the archive commands. + if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then + cmds=$old_archive_from_new_cmds + else + + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + + func_extract_archives $gentop $dlprefiles + func_append oldobjs " $func_extract_archives_result" + fi + + # POSIX demands no paths to be encoded in archives. We have + # to avoid creating archives with duplicate basenames if we + # might have to extract them afterwards, e.g., when creating a + # static archive out of a convenience library, or when linking + # the entirety of a libtool archive into another (currently + # not supported by libtool). + if (for obj in $oldobjs + do + func_basename "$obj" + $ECHO "$func_basename_result" + done | sort | sort -uc >/dev/null 2>&1); then + : + else + echo "copying selected object files to avoid basename conflicts..." + gentop="$output_objdir/${outputname}x" + func_append generated " $gentop" + func_mkdir_p "$gentop" + save_oldobjs=$oldobjs + oldobjs= + counter=1 + for obj in $save_oldobjs + do + func_basename "$obj" + objbase="$func_basename_result" + case " $oldobjs " in + " ") oldobjs=$obj ;; + *[\ /]"$objbase "*) + while :; do + # Make sure we don't pick an alternate name that also + # overlaps. + newobj=lt$counter-$objbase + func_arith $counter + 1 + counter=$func_arith_result + case " $oldobjs " in + *[\ /]"$newobj "*) ;; + *) if test ! -f "$gentop/$newobj"; then break; fi ;; + esac + done + func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" + func_append oldobjs " $gentop/$newobj" + ;; + *) func_append oldobjs " $obj" ;; + esac + done + fi + func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 + tool_oldlib=$func_to_tool_file_result + eval cmds=\"$old_archive_cmds\" + + func_len " $cmds" + len=$func_len_result + if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + cmds=$old_archive_cmds + elif test -n "$archiver_list_spec"; then + func_verbose "using command file archive linking..." + for obj in $oldobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > $output_objdir/$libname.libcmd + func_to_tool_file "$output_objdir/$libname.libcmd" + oldobjs=" $archiver_list_spec$func_to_tool_file_result" + cmds=$old_archive_cmds + else + # the command line is too long to link in one step, link in parts + func_verbose "using piecewise archive linking..." + save_RANLIB=$RANLIB + RANLIB=: + objlist= + concat_cmds= + save_oldobjs=$oldobjs + oldobjs= + # Is there a better way of finding the last object in the list? + for obj in $save_oldobjs + do + last_oldobj=$obj + done + eval test_cmds=\"$old_archive_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + for obj in $save_oldobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + func_append objlist " $obj" + if test "$len" -lt "$max_cmd_len"; then + : + else + # the above command should be used before it gets too long + oldobjs=$objlist + if test "$obj" = "$last_oldobj" ; then + RANLIB=$save_RANLIB + fi + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" + objlist= + len=$len0 + fi + done + RANLIB=$save_RANLIB + oldobjs=$objlist + if test "X$oldobjs" = "X" ; then + eval cmds=\"\$concat_cmds\" + else + eval cmds=\"\$concat_cmds~\$old_archive_cmds\" + fi + fi + fi + func_execute_cmds "$cmds" 'exit $?' + done + + test -n "$generated" && \ + func_show_eval "${RM}r$generated" + + # Now create the libtool archive. + case $output in + *.la) + old_library= + test "$build_old_libs" = yes && old_library="$libname.$libext" + func_verbose "creating $output" + + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + fi + done + # Quote the link command for shipping. + relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + if test "$hardcode_automatic" = yes ; then + relink_command= + fi + + # Only create the output if not a dry run. + $opt_dry_run || { + for installed in no yes; do + if test "$installed" = yes; then + if test -z "$install_libdir"; then + break + fi + output="$output_objdir/$outputname"i + # Replace all uninstalled libtool libraries with the installed ones + newdependency_libs= + for deplib in $dependency_libs; do + case $deplib in + *.la) + func_basename "$deplib" + name="$func_basename_result" + func_resolve_sysroot "$deplib" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` + test -z "$libdir" && \ + func_fatal_error "\`$deplib' is not a valid libtool archive" + func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" + ;; + -L*) + func_stripname -L '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -L$func_replace_sysroot_result" + ;; + -R*) + func_stripname -R '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -R$func_replace_sysroot_result" + ;; + *) func_append newdependency_libs " $deplib" ;; + esac + done + dependency_libs="$newdependency_libs" + newdlfiles= + + for lib in $dlfiles; do + case $lib in + *.la) + func_basename "$lib" + name="$func_basename_result" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "\`$lib' is not a valid libtool archive" + func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" + ;; + *) func_append newdlfiles " $lib" ;; + esac + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + *.la) + # Only pass preopened files to the pseudo-archive (for + # eventual linking with the app. that links it) if we + # didn't already link the preopened objects directly into + # the library: + func_basename "$lib" + name="$func_basename_result" + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "\`$lib' is not a valid libtool archive" + func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" + ;; + esac + done + dlprefiles="$newdlprefiles" + else + newdlfiles= + for lib in $dlfiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlfiles " $abs" + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlprefiles " $abs" + done + dlprefiles="$newdlprefiles" + fi + $RM $output + # place dlname in correct position for cygwin + # In fact, it would be nice if we could use this code for all target + # systems that can't hard-code library paths into their executables + # and that have no shared library path variable independent of PATH, + # but it turns out we can't easily determine that from inspecting + # libtool variables, so we have to hard-code the OSs to which it + # applies here; at the moment, that means platforms that use the PE + # object format with DLL files. See the long comment at the top of + # tests/bindir.at for full details. + tdlname=$dlname + case $host,$output,$installed,$module,$dlname in + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) + # If a -bindir argument was supplied, place the dll there. + if test "x$bindir" != x ; + then + func_relative_path "$install_libdir" "$bindir" + tdlname=$func_relative_path_result$dlname + else + # Otherwise fall back on heuristic. + tdlname=../bin/$dlname + fi + ;; + esac + $ECHO > $output "\ +# $outputname - a libtool library file +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION +# +# Please DO NOT delete this file! +# It is necessary for linking the library. + +# The name that we can dlopen(3). +dlname='$tdlname' + +# Names of this library. +library_names='$library_names' + +# The name of the static archive. +old_library='$old_library' + +# Linker flags that can not go in dependency_libs. +inherited_linker_flags='$new_inherited_linker_flags' + +# Libraries that this one depends upon. +dependency_libs='$dependency_libs' + +# Names of additional weak libraries provided by this library +weak_library_names='$weak_libs' + +# Version information for $libname. +current=$current +age=$age +revision=$revision + +# Is this an already installed library? +installed=$installed + +# Should we warn about portability when linking against -modules? +shouldnotlink=$module + +# Files to dlopen/dlpreopen +dlopen='$dlfiles' +dlpreopen='$dlprefiles' + +# Directory that this library needs to be installed in: +libdir='$install_libdir'" + if test "$installed" = no && test "$need_relink" = yes; then + $ECHO >> $output "\ +relink_command=\"$relink_command\"" + fi + done + } + + # Do a symbolic link so that the libtool archive can be found in + # LD_LIBRARY_PATH before the program is installed. + func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' + ;; + esac + exit $EXIT_SUCCESS +} + +{ test "$opt_mode" = link || test "$opt_mode" = relink; } && + func_mode_link ${1+"$@"} + + +# func_mode_uninstall arg... +func_mode_uninstall () +{ + $opt_debug + RM="$nonopt" + files= + rmforce= + exit_status=0 + + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic="$magic" + + for arg + do + case $arg in + -f) func_append RM " $arg"; rmforce=yes ;; + -*) func_append RM " $arg" ;; + *) func_append files " $arg" ;; + esac + done + + test -z "$RM" && \ + func_fatal_help "you must specify an RM program" + + rmdirs= + + for file in $files; do + func_dirname "$file" "" "." + dir="$func_dirname_result" + if test "X$dir" = X.; then + odir="$objdir" + else + odir="$dir/$objdir" + fi + func_basename "$file" + name="$func_basename_result" + test "$opt_mode" = uninstall && odir="$dir" + + # Remember odir for removal later, being careful to avoid duplicates + if test "$opt_mode" = clean; then + case " $rmdirs " in + *" $odir "*) ;; + *) func_append rmdirs " $odir" ;; + esac + fi + + # Don't error if the file doesn't exist and rm -f was used. + if { test -L "$file"; } >/dev/null 2>&1 || + { test -h "$file"; } >/dev/null 2>&1 || + test -f "$file"; then + : + elif test -d "$file"; then + exit_status=1 + continue + elif test "$rmforce" = yes; then + continue + fi + + rmfiles="$file" + + case $name in + *.la) + # Possibly a libtool archive, so verify it. + if func_lalib_p "$file"; then + func_source $dir/$name + + # Delete the libtool libraries and symlinks. + for n in $library_names; do + func_append rmfiles " $odir/$n" + done + test -n "$old_library" && func_append rmfiles " $odir/$old_library" + + case "$opt_mode" in + clean) + case " $library_names " in + *" $dlname "*) ;; + *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; + esac + test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" + ;; + uninstall) + if test -n "$library_names"; then + # Do each command in the postuninstall commands. + func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' + fi + + if test -n "$old_library"; then + # Do each command in the old_postuninstall commands. + func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' + fi + # FIXME: should reinstall the best remaining shared library. + ;; + esac + fi + ;; + + *.lo) + # Possibly a libtool object, so verify it. + if func_lalib_p "$file"; then + + # Read the .lo file + func_source $dir/$name + + # Add PIC object to the list of files to remove. + if test -n "$pic_object" && + test "$pic_object" != none; then + func_append rmfiles " $dir/$pic_object" + fi + + # Add non-PIC object to the list of files to remove. + if test -n "$non_pic_object" && + test "$non_pic_object" != none; then + func_append rmfiles " $dir/$non_pic_object" + fi + fi + ;; + + *) + if test "$opt_mode" = clean ; then + noexename=$name + case $file in + *.exe) + func_stripname '' '.exe' "$file" + file=$func_stripname_result + func_stripname '' '.exe' "$name" + noexename=$func_stripname_result + # $file with .exe has already been added to rmfiles, + # add $file without .exe + func_append rmfiles " $file" + ;; + esac + # Do a test to see if this is a libtool program. + if func_ltwrapper_p "$file"; then + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + relink_command= + func_source $func_ltwrapper_scriptname_result + func_append rmfiles " $func_ltwrapper_scriptname_result" + else + relink_command= + func_source $dir/$noexename + fi + + # note $name still contains .exe if it was in $file originally + # as does the version of $file that was added into $rmfiles + func_append rmfiles " $odir/$name $odir/${name}S.${objext}" + if test "$fast_install" = yes && test -n "$relink_command"; then + func_append rmfiles " $odir/lt-$name" + fi + if test "X$noexename" != "X$name" ; then + func_append rmfiles " $odir/lt-${noexename}.c" + fi + fi + fi + ;; + esac + func_show_eval "$RM $rmfiles" 'exit_status=1' + done + + # Try to remove the ${objdir}s in the directories where we deleted files + for dir in $rmdirs; do + if test -d "$dir"; then + func_show_eval "rmdir $dir >/dev/null 2>&1" + fi + done + + exit $exit_status +} + +{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && + func_mode_uninstall ${1+"$@"} + +test -z "$opt_mode" && { + help="$generic_help" + func_fatal_help "you must specify a MODE" +} + +test -z "$exec_cmd" && \ + func_fatal_help "invalid operation mode \`$opt_mode'" + +if test -n "$exec_cmd"; then + eval exec "$exec_cmd" + exit $EXIT_FAILURE +fi + +exit $exit_status + + +# The TAGs below are defined such that we never get into a situation +# in which we disable both kinds of libraries. Given conflicting +# choices, we go for a static library, that is the most portable, +# since we can't tell whether shared libraries were disabled because +# the user asked for that or because the platform doesn't support +# them. This is particularly important on AIX, because we don't +# support having both static and shared libraries enabled at the same +# time on that platform, so we default to a shared-only configuration. +# If a disable-shared tag is given, we'll fallback to a static-only +# configuration. But we'll never go from static-only to shared-only. + +# ### BEGIN LIBTOOL TAG CONFIG: disable-shared +build_libtool_libs=no +build_old_libs=yes +# ### END LIBTOOL TAG CONFIG: disable-shared + +# ### BEGIN LIBTOOL TAG CONFIG: disable-static +build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` +# ### END LIBTOOL TAG CONFIG: disable-static + +# Local Variables: +# mode:shell-script +# sh-indentation:2 +# End: +# vi:sw=2 + diff --git a/contrib/ntp/arlib/missing b/contrib/ntp/sntp/libevent/build-aux/missing similarity index 85% rename from contrib/ntp/arlib/missing rename to contrib/ntp/sntp/libevent/build-aux/missing index 894e786e1..28055d2ae 100755 --- a/contrib/ntp/arlib/missing +++ b/contrib/ntp/sntp/libevent/build-aux/missing @@ -1,10 +1,10 @@ #! /bin/sh # Common stub for a few missing GNU programs while installing. -scriptversion=2005-06-08.21 +scriptversion=2009-04-28.21; # UTC -# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005 -# Free Software Foundation, Inc. +# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006, +# 2008, 2009 Free Software Foundation, Inc. # Originally by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify @@ -18,9 +18,7 @@ scriptversion=2005-06-08.21 # GNU General Public License for more details. # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -# 02110-1301, USA. +# along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a @@ -33,6 +31,8 @@ if test $# -eq 0; then fi run=: +sed_output='s/.* --output[ =]\([^ ]*\).*/\1/p' +sed_minuso='s/.* -o \([^ ]*\).*/\1/p' # In the cases where this matters, `missing' is being run in the # srcdir already. @@ -44,7 +44,7 @@ fi msg="missing on your system" -case "$1" in +case $1 in --run) # Try to run requested program, and just exit if it succeeds. run= @@ -77,6 +77,7 @@ Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' + autom4te touch the output file, or create a stub one automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c @@ -86,6 +87,9 @@ Supported PROGRAM values: tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch] +Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and +\`g' are ignored when checking the name. + Send bug reports to ." exit $? ;; @@ -103,15 +107,22 @@ Send bug reports to ." esac +# normalize program name to check for. +program=`echo "$1" | sed ' + s/^gnu-//; t + s/^gnu//; t + s/^g//; t'` + # Now exit if we have it, but it failed. Also exit now if we # don't have it and --version was passed (most likely to detect -# the program). -case "$1" in - lex|yacc) +# the program). This is about non-GNU programs, so use $1 not +# $program. +case $1 in + lex*|yacc*) # Not GNU programs, they don't have --version. ;; - tar) + tar*) if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 @@ -135,7 +146,7 @@ esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. -case "$1" in +case $program in aclocal*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if @@ -145,7 +156,7 @@ WARNING: \`$1' is $msg. You should only need it if touch aclocal.m4 ;; - autoconf) + autoconf*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`${configure_ac}'. You might want to install the @@ -154,7 +165,7 @@ WARNING: \`$1' is $msg. You should only need it if touch configure ;; - autoheader) + autoheader*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want @@ -164,7 +175,7 @@ WARNING: \`$1' is $msg. You should only need it if test -z "$files" && files="config.h" touch_files= for f in $files; do - case "$f" in + case $f in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; @@ -184,7 +195,7 @@ WARNING: \`$1' is $msg. You should only need it if while read f; do touch "$f"; done ;; - autom4te) + autom4te*) echo 1>&2 "\ WARNING: \`$1' is needed, but is $msg. You might have modified some files without having the @@ -192,8 +203,8 @@ WARNING: \`$1' is needed, but is $msg. You can get \`$1' as part of \`Autoconf' from any GNU archive site." - file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'` - test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'` + file=`echo "$*" | sed -n "$sed_output"` + test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -f "$file"; then touch $file else @@ -207,80 +218,78 @@ WARNING: \`$1' is needed, but is $msg. fi ;; - bison|yacc) + bison*|yacc*) echo 1>&2 "\ WARNING: \`$1' $msg. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h - if [ $# -ne 1 ]; then + if test $# -ne 1; then eval LASTARG="\${$#}" - case "$LASTARG" in + case $LASTARG in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` - if [ -f "$SRCFILE" ]; then + if test -f "$SRCFILE"; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` - if [ -f "$SRCFILE" ]; then + if test -f "$SRCFILE"; then cp "$SRCFILE" y.tab.h fi ;; esac fi - if [ ! -f y.tab.h ]; then + if test ! -f y.tab.h; then echo >y.tab.h fi - if [ ! -f y.tab.c ]; then + if test ! -f y.tab.c; then echo 'main() { return 0; }' >y.tab.c fi ;; - lex|flex) + lex*|flex*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c - if [ $# -ne 1 ]; then + if test $# -ne 1; then eval LASTARG="\${$#}" - case "$LASTARG" in + case $LASTARG in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` - if [ -f "$SRCFILE" ]; then + if test -f "$SRCFILE"; then cp "$SRCFILE" lex.yy.c fi ;; esac fi - if [ ! -f lex.yy.c ]; then + if test ! -f lex.yy.c; then echo 'main() { return 0; }' >lex.yy.c fi ;; - help2man) + help2man*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." - file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` - if test -z "$file"; then - file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` - fi - if [ -f "$file" ]; then + file=`echo "$*" | sed -n "$sed_output"` + test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` + if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" - exit 1 + exit $? fi ;; - makeinfo) + makeinfo*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file @@ -289,11 +298,17 @@ WARNING: \`$1' is $msg. You should only need it if DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." # The file to touch is that specified with -o ... - file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` + file=`echo "$*" | sed -n "$sed_output"` + test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -z "$file"; then # ... or it is the one specified with @setfilename ... infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` - file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $infile` + file=`sed -n ' + /^@setfilename/{ + s/.* \([^ ]*\) *$/\1/ + p + q + }' $infile` # ... or it is derived from the source name (dir/f.texi becomes f.info) test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info fi @@ -303,7 +318,7 @@ WARNING: \`$1' is $msg. You should only need it if touch $file ;; - tar) + tar*) shift # We have already tried tar in the generic part. @@ -317,13 +332,13 @@ WARNING: \`$1' is $msg. You should only need it if fi firstarg="$1" if shift; then - case "$firstarg" in + case $firstarg in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" "$@" && exit 0 ;; esac - case "$firstarg" in + case $firstarg in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" "$@" && exit 0 @@ -356,5 +371,6 @@ exit 0 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-end: "$" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" # End: diff --git a/contrib/ntp/sntp/libevent/build-aux/test-driver b/contrib/ntp/sntp/libevent/build-aux/test-driver new file mode 100755 index 000000000..8e575b017 --- /dev/null +++ b/contrib/ntp/sntp/libevent/build-aux/test-driver @@ -0,0 +1,148 @@ +#! /bin/sh +# test-driver - basic testsuite driver script. + +scriptversion=2013-07-13.22; # UTC + +# Copyright (C) 2011-2014 Free Software Foundation, Inc. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to or send patches to +# . + +# Make unconditional expansion of undefined variables an error. This +# helps a lot in preventing typo-related bugs. +set -u + +usage_error () +{ + echo "$0: $*" >&2 + print_usage >&2 + exit 2 +} + +print_usage () +{ + cat <$log_file 2>&1 +estatus=$? + +if test $enable_hard_errors = no && test $estatus -eq 99; then + tweaked_estatus=1 +else + tweaked_estatus=$estatus +fi + +case $tweaked_estatus:$expect_failure in + 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;; + 0:*) col=$grn res=PASS recheck=no gcopy=no;; + 77:*) col=$blu res=SKIP recheck=no gcopy=yes;; + 99:*) col=$mgn res=ERROR recheck=yes gcopy=yes;; + *:yes) col=$lgn res=XFAIL recheck=no gcopy=yes;; + *:*) col=$red res=FAIL recheck=yes gcopy=yes;; +esac + +# Report the test outcome and exit status in the logs, so that one can +# know whether the test passed or failed simply by looking at the '.log' +# file, without the need of also peaking into the corresponding '.trs' +# file (automake bug#11814). +echo "$res $test_name (exit status: $estatus)" >>$log_file + +# Report outcome to console. +echo "${col}${res}${std}: $test_name" + +# Register the test result, and other relevant metadata. +echo ":test-result: $res" > $trs_file +echo ":global-test-result: $res" >> $trs_file +echo ":recheck: $recheck" >> $trs_file +echo ":copy-in-global-log: $gcopy" >> $trs_file + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/contrib/ntp/sntp/libevent/build-aux/ylwrap b/contrib/ntp/sntp/libevent/build-aux/ylwrap new file mode 100755 index 000000000..84d563405 --- /dev/null +++ b/contrib/ntp/sntp/libevent/build-aux/ylwrap @@ -0,0 +1,222 @@ +#! /bin/sh +# ylwrap - wrapper for lex/yacc invocations. + +scriptversion=2009-04-28.21; # UTC + +# Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004, 2005, +# 2007, 2009 Free Software Foundation, Inc. +# +# Written by Tom Tromey . +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to or send patches to +# . + +case "$1" in + '') + echo "$0: No files given. Try \`$0 --help' for more information." 1>&2 + exit 1 + ;; + --basedir) + basedir=$2 + shift 2 + ;; + -h|--h*) + cat <<\EOF +Usage: ylwrap [--help|--version] INPUT [OUTPUT DESIRED]... -- PROGRAM [ARGS]... + +Wrapper for lex/yacc invocations, renaming files as desired. + + INPUT is the input file + OUTPUT is one file PROG generates + DESIRED is the file we actually want instead of OUTPUT + PROGRAM is program to run + ARGS are passed to PROG + +Any number of OUTPUT,DESIRED pairs may be used. + +Report bugs to . +EOF + exit $? + ;; + -v|--v*) + echo "ylwrap $scriptversion" + exit $? + ;; +esac + + +# The input. +input="$1" +shift +case "$input" in + [\\/]* | ?:[\\/]*) + # Absolute path; do nothing. + ;; + *) + # Relative path. Make it absolute. + input="`pwd`/$input" + ;; +esac + +pairlist= +while test "$#" -ne 0; do + if test "$1" = "--"; then + shift + break + fi + pairlist="$pairlist $1" + shift +done + +# The program to run. +prog="$1" +shift +# Make any relative path in $prog absolute. +case "$prog" in + [\\/]* | ?:[\\/]*) ;; + *[\\/]*) prog="`pwd`/$prog" ;; +esac + +# FIXME: add hostname here for parallel makes that run commands on +# other machines. But that might take us over the 14-char limit. +dirname=ylwrap$$ +trap "cd '`pwd`'; rm -rf $dirname > /dev/null 2>&1" 1 2 3 15 +mkdir $dirname || exit 1 + +cd $dirname + +case $# in + 0) "$prog" "$input" ;; + *) "$prog" "$@" "$input" ;; +esac +ret=$? + +if test $ret -eq 0; then + set X $pairlist + shift + first=yes + # Since DOS filename conventions don't allow two dots, + # the DOS version of Bison writes out y_tab.c instead of y.tab.c + # and y_tab.h instead of y.tab.h. Test to see if this is the case. + y_tab_nodot="no" + if test -f y_tab.c || test -f y_tab.h; then + y_tab_nodot="yes" + fi + + # The directory holding the input. + input_dir=`echo "$input" | sed -e 's,\([\\/]\)[^\\/]*$,\1,'` + # Quote $INPUT_DIR so we can use it in a regexp. + # FIXME: really we should care about more than `.' and `\'. + input_rx=`echo "$input_dir" | sed 's,\\\\,\\\\\\\\,g;s,\\.,\\\\.,g'` + + while test "$#" -ne 0; do + from="$1" + # Handle y_tab.c and y_tab.h output by DOS + if test $y_tab_nodot = "yes"; then + if test $from = "y.tab.c"; then + from="y_tab.c" + else + if test $from = "y.tab.h"; then + from="y_tab.h" + fi + fi + fi + if test -f "$from"; then + # If $2 is an absolute path name, then just use that, + # otherwise prepend `../'. + case "$2" in + [\\/]* | ?:[\\/]*) target="$2";; + *) target="../$2";; + esac + + # We do not want to overwrite a header file if it hasn't + # changed. This avoid useless recompilations. However the + # parser itself (the first file) should always be updated, + # because it is the destination of the .y.c rule in the + # Makefile. Divert the output of all other files to a temporary + # file so we can compare them to existing versions. + if test $first = no; then + realtarget="$target" + target="tmp-`echo $target | sed s/.*[\\/]//g`" + fi + # Edit out `#line' or `#' directives. + # + # We don't want the resulting debug information to point at + # an absolute srcdir; it is better for it to just mention the + # .y file with no path. + # + # We want to use the real output file name, not yy.lex.c for + # instance. + # + # We want the include guards to be adjusted too. + FROM=`echo "$from" | sed \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'\ + -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g'` + TARGET=`echo "$2" | sed \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'\ + -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g'` + + sed -e "/^#/!b" -e "s,$input_rx,," -e "s,$from,$2," \ + -e "s,$FROM,$TARGET," "$from" >"$target" || ret=$? + + # Check whether header files must be updated. + if test $first = no; then + if test -f "$realtarget" && cmp -s "$realtarget" "$target"; then + echo "$2" is unchanged + rm -f "$target" + else + echo updating "$2" + mv -f "$target" "$realtarget" + fi + fi + else + # A missing file is only an error for the first file. This + # is a blatant hack to let us support using "yacc -d". If -d + # is not specified, we don't want an error when the header + # file is "missing". + if test $first = yes; then + ret=1 + fi + fi + shift + shift + first=no + done +else + ret=$? +fi + +# Remove the directory. +cd .. +rm -rf $dirname + +exit $ret + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/contrib/ntp/sntp/libevent/changelist-internal.h b/contrib/ntp/sntp/libevent/changelist-internal.h new file mode 100644 index 000000000..98fc52aeb --- /dev/null +++ b/contrib/ntp/sntp/libevent/changelist-internal.h @@ -0,0 +1,102 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef CHANGELIST_INTERNAL_H_INCLUDED_ +#define CHANGELIST_INTERNAL_H_INCLUDED_ + +/* + A "changelist" is a list of all the fd status changes that should be made + between calls to the backend's dispatch function. There are a few reasons + that a backend would want to queue changes like this rather than processing + them immediately. + + 1) Sometimes applications will add and delete the same event more than + once between calls to dispatch. Processing these changes immediately + is needless, and potentially expensive (especially if we're on a system + that makes one syscall per changed event). + + 2) Sometimes we can coalesce multiple changes on the same fd into a single + syscall if we know about them in advance. For example, epoll can do an + add and a delete at the same time, but only if we have found out about + both of them before we tell epoll. + + 3) Sometimes adding an event that we immediately delete can cause + unintended consequences: in kqueue, this makes pending events get + reported spuriously. + */ + +#include "event2/util.h" + +/** Represents a */ +struct event_change { + /** The fd or signal whose events are to be changed */ + evutil_socket_t fd; + /* The events that were enabled on the fd before any of these changes + were made. May include EV_READ or EV_WRITE. */ + short old_events; + + /* The changes that we want to make in reading and writing on this fd. + * If this is a signal, then read_change has EV_CHANGE_SIGNAL set, + * and write_change is unused. */ + ev_uint8_t read_change; + ev_uint8_t write_change; + ev_uint8_t close_change; +}; + +/* Flags for read_change and write_change. */ + +/* If set, add the event. */ +#define EV_CHANGE_ADD 0x01 +/* If set, delete the event. Exclusive with EV_CHANGE_ADD */ +#define EV_CHANGE_DEL 0x02 +/* If set, this event refers a signal, not an fd. */ +#define EV_CHANGE_SIGNAL EV_SIGNAL +/* Set for persistent events. Currently not used. */ +#define EV_CHANGE_PERSIST EV_PERSIST +/* Set for adding edge-triggered events. */ +#define EV_CHANGE_ET EV_ET + +/* The value of fdinfo_size that a backend should use if it is letting + * changelist handle its add and delete functions. */ +#define EVENT_CHANGELIST_FDINFO_SIZE sizeof(int) + +/** Set up the data fields in a changelist. */ +void event_changelist_init_(struct event_changelist *changelist); +/** Remove every change in the changelist, and make corresponding changes + * in the event maps in the base. This function is generally used right + * after making all the changes in the changelist. */ +void event_changelist_remove_all_(struct event_changelist *changelist, + struct event_base *base); +/** Free all memory held in a changelist. */ +void event_changelist_freemem_(struct event_changelist *changelist); + +/** Implementation of eventop_add that queues the event in a changelist. */ +int event_changelist_add_(struct event_base *base, evutil_socket_t fd, short old, short events, + void *p); +/** Implementation of eventop_del that queues the event in a changelist. */ +int event_changelist_del_(struct event_base *base, evutil_socket_t fd, short old, short events, + void *p); + +#endif diff --git a/contrib/ntp/sntp/libevent/compat/sys/queue.h b/contrib/ntp/sntp/libevent/compat/sys/queue.h new file mode 100644 index 000000000..c387bdcf5 --- /dev/null +++ b/contrib/ntp/sntp/libevent/compat/sys/queue.h @@ -0,0 +1,488 @@ +/* $OpenBSD: queue.h,v 1.16 2000/09/07 19:47:59 art Exp $ */ +/* $NetBSD: queue.h,v 1.11 1996/05/16 05:17:14 mycroft Exp $ */ + +/* + * Copyright (c) 1991, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * @(#)queue.h 8.5 (Berkeley) 8/20/94 + */ + +#ifndef SYS_QUEUE_H__ +#define SYS_QUEUE_H__ + +/* + * This file defines five types of data structures: singly-linked lists, + * lists, simple queues, tail queues, and circular queues. + * + * + * A singly-linked list is headed by a single forward pointer. The elements + * are singly linked for minimum space and pointer manipulation overhead at + * the expense of O(n) removal for arbitrary elements. New elements can be + * added to the list after an existing element or at the head of the list. + * Elements being removed from the head of the list should use the explicit + * macro for this purpose for optimum efficiency. A singly-linked list may + * only be traversed in the forward direction. Singly-linked lists are ideal + * for applications with large datasets and few or no removals or for + * implementing a LIFO queue. + * + * A list is headed by a single forward pointer (or an array of forward + * pointers for a hash table header). The elements are doubly linked + * so that an arbitrary element can be removed without a need to + * traverse the list. New elements can be added to the list before + * or after an existing element or at the head of the list. A list + * may only be traversed in the forward direction. + * + * A simple queue is headed by a pair of pointers, one the head of the + * list and the other to the tail of the list. The elements are singly + * linked to save space, so elements can only be removed from the + * head of the list. New elements can be added to the list before or after + * an existing element, at the head of the list, or at the end of the + * list. A simple queue may only be traversed in the forward direction. + * + * A tail queue is headed by a pair of pointers, one to the head of the + * list and the other to the tail of the list. The elements are doubly + * linked so that an arbitrary element can be removed without a need to + * traverse the list. New elements can be added to the list before or + * after an existing element, at the head of the list, or at the end of + * the list. A tail queue may be traversed in either direction. + * + * A circle queue is headed by a pair of pointers, one to the head of the + * list and the other to the tail of the list. The elements are doubly + * linked so that an arbitrary element can be removed without a need to + * traverse the list. New elements can be added to the list before or after + * an existing element, at the head of the list, or at the end of the list. + * A circle queue may be traversed in either direction, but has a more + * complex end of list detection. + * + * For details on the use of these macros, see the queue(3) manual page. + */ + +/* + * Singly-linked List definitions. + */ +#define SLIST_HEAD(name, type) \ +struct name { \ + struct type *slh_first; /* first element */ \ +} + +#define SLIST_HEAD_INITIALIZER(head) \ + { NULL } + +#ifndef _WIN32 +#define SLIST_ENTRY(type) \ +struct { \ + struct type *sle_next; /* next element */ \ +} +#endif + +/* + * Singly-linked List access methods. + */ +#define SLIST_FIRST(head) ((head)->slh_first) +#define SLIST_END(head) NULL +#define SLIST_EMPTY(head) (SLIST_FIRST(head) == SLIST_END(head)) +#define SLIST_NEXT(elm, field) ((elm)->field.sle_next) + +#define SLIST_FOREACH(var, head, field) \ + for((var) = SLIST_FIRST(head); \ + (var) != SLIST_END(head); \ + (var) = SLIST_NEXT(var, field)) + +/* + * Singly-linked List functions. + */ +#define SLIST_INIT(head) { \ + SLIST_FIRST(head) = SLIST_END(head); \ +} + +#define SLIST_INSERT_AFTER(slistelm, elm, field) do { \ + (elm)->field.sle_next = (slistelm)->field.sle_next; \ + (slistelm)->field.sle_next = (elm); \ +} while (0) + +#define SLIST_INSERT_HEAD(head, elm, field) do { \ + (elm)->field.sle_next = (head)->slh_first; \ + (head)->slh_first = (elm); \ +} while (0) + +#define SLIST_REMOVE_HEAD(head, field) do { \ + (head)->slh_first = (head)->slh_first->field.sle_next; \ +} while (0) + +/* + * List definitions. + */ +#define LIST_HEAD(name, type) \ +struct name { \ + struct type *lh_first; /* first element */ \ +} + +#define LIST_HEAD_INITIALIZER(head) \ + { NULL } + +#define LIST_ENTRY(type) \ +struct { \ + struct type *le_next; /* next element */ \ + struct type **le_prev; /* address of previous next element */ \ +} + +/* + * List access methods + */ +#define LIST_FIRST(head) ((head)->lh_first) +#define LIST_END(head) NULL +#define LIST_EMPTY(head) (LIST_FIRST(head) == LIST_END(head)) +#define LIST_NEXT(elm, field) ((elm)->field.le_next) + +#define LIST_FOREACH(var, head, field) \ + for((var) = LIST_FIRST(head); \ + (var)!= LIST_END(head); \ + (var) = LIST_NEXT(var, field)) + +/* + * List functions. + */ +#define LIST_INIT(head) do { \ + LIST_FIRST(head) = LIST_END(head); \ +} while (0) + +#define LIST_INSERT_AFTER(listelm, elm, field) do { \ + if (((elm)->field.le_next = (listelm)->field.le_next) != NULL) \ + (listelm)->field.le_next->field.le_prev = \ + &(elm)->field.le_next; \ + (listelm)->field.le_next = (elm); \ + (elm)->field.le_prev = &(listelm)->field.le_next; \ +} while (0) + +#define LIST_INSERT_BEFORE(listelm, elm, field) do { \ + (elm)->field.le_prev = (listelm)->field.le_prev; \ + (elm)->field.le_next = (listelm); \ + *(listelm)->field.le_prev = (elm); \ + (listelm)->field.le_prev = &(elm)->field.le_next; \ +} while (0) + +#define LIST_INSERT_HEAD(head, elm, field) do { \ + if (((elm)->field.le_next = (head)->lh_first) != NULL) \ + (head)->lh_first->field.le_prev = &(elm)->field.le_next;\ + (head)->lh_first = (elm); \ + (elm)->field.le_prev = &(head)->lh_first; \ +} while (0) + +#define LIST_REMOVE(elm, field) do { \ + if ((elm)->field.le_next != NULL) \ + (elm)->field.le_next->field.le_prev = \ + (elm)->field.le_prev; \ + *(elm)->field.le_prev = (elm)->field.le_next; \ +} while (0) + +#define LIST_REPLACE(elm, elm2, field) do { \ + if (((elm2)->field.le_next = (elm)->field.le_next) != NULL) \ + (elm2)->field.le_next->field.le_prev = \ + &(elm2)->field.le_next; \ + (elm2)->field.le_prev = (elm)->field.le_prev; \ + *(elm2)->field.le_prev = (elm2); \ +} while (0) + +/* + * Simple queue definitions. + */ +#define SIMPLEQ_HEAD(name, type) \ +struct name { \ + struct type *sqh_first; /* first element */ \ + struct type **sqh_last; /* addr of last next element */ \ +} + +#define SIMPLEQ_HEAD_INITIALIZER(head) \ + { NULL, &(head).sqh_first } + +#define SIMPLEQ_ENTRY(type) \ +struct { \ + struct type *sqe_next; /* next element */ \ +} + +/* + * Simple queue access methods. + */ +#define SIMPLEQ_FIRST(head) ((head)->sqh_first) +#define SIMPLEQ_END(head) NULL +#define SIMPLEQ_EMPTY(head) (SIMPLEQ_FIRST(head) == SIMPLEQ_END(head)) +#define SIMPLEQ_NEXT(elm, field) ((elm)->field.sqe_next) + +#define SIMPLEQ_FOREACH(var, head, field) \ + for((var) = SIMPLEQ_FIRST(head); \ + (var) != SIMPLEQ_END(head); \ + (var) = SIMPLEQ_NEXT(var, field)) + +/* + * Simple queue functions. + */ +#define SIMPLEQ_INIT(head) do { \ + (head)->sqh_first = NULL; \ + (head)->sqh_last = &(head)->sqh_first; \ +} while (0) + +#define SIMPLEQ_INSERT_HEAD(head, elm, field) do { \ + if (((elm)->field.sqe_next = (head)->sqh_first) == NULL) \ + (head)->sqh_last = &(elm)->field.sqe_next; \ + (head)->sqh_first = (elm); \ +} while (0) + +#define SIMPLEQ_INSERT_TAIL(head, elm, field) do { \ + (elm)->field.sqe_next = NULL; \ + *(head)->sqh_last = (elm); \ + (head)->sqh_last = &(elm)->field.sqe_next; \ +} while (0) + +#define SIMPLEQ_INSERT_AFTER(head, listelm, elm, field) do { \ + if (((elm)->field.sqe_next = (listelm)->field.sqe_next) == NULL)\ + (head)->sqh_last = &(elm)->field.sqe_next; \ + (listelm)->field.sqe_next = (elm); \ +} while (0) + +#define SIMPLEQ_REMOVE_HEAD(head, elm, field) do { \ + if (((head)->sqh_first = (elm)->field.sqe_next) == NULL) \ + (head)->sqh_last = &(head)->sqh_first; \ +} while (0) + +/* + * Tail queue definitions. + */ +#define TAILQ_HEAD(name, type) \ +struct name { \ + struct type *tqh_first; /* first element */ \ + struct type **tqh_last; /* addr of last next element */ \ +} + +#define TAILQ_HEAD_INITIALIZER(head) \ + { NULL, &(head).tqh_first } + +#define TAILQ_ENTRY(type) \ +struct { \ + struct type *tqe_next; /* next element */ \ + struct type **tqe_prev; /* address of previous next element */ \ +} + +/* + * tail queue access methods + */ +#define TAILQ_FIRST(head) ((head)->tqh_first) +#define TAILQ_END(head) NULL +#define TAILQ_NEXT(elm, field) ((elm)->field.tqe_next) +#define TAILQ_LAST(head, headname) \ + (*(((struct headname *)((head)->tqh_last))->tqh_last)) +/* XXX */ +#define TAILQ_PREV(elm, headname, field) \ + (*(((struct headname *)((elm)->field.tqe_prev))->tqh_last)) +#define TAILQ_EMPTY(head) \ + (TAILQ_FIRST(head) == TAILQ_END(head)) + +#define TAILQ_FOREACH(var, head, field) \ + for((var) = TAILQ_FIRST(head); \ + (var) != TAILQ_END(head); \ + (var) = TAILQ_NEXT(var, field)) + +#define TAILQ_FOREACH_REVERSE(var, head, headname, field) \ + for((var) = TAILQ_LAST(head, headname); \ + (var) != TAILQ_END(head); \ + (var) = TAILQ_PREV(var, headname, field)) + +/* + * Tail queue functions. + */ +#define TAILQ_INIT(head) do { \ + (head)->tqh_first = NULL; \ + (head)->tqh_last = &(head)->tqh_first; \ +} while (0) + +#define TAILQ_INSERT_HEAD(head, elm, field) do { \ + if (((elm)->field.tqe_next = (head)->tqh_first) != NULL) \ + (head)->tqh_first->field.tqe_prev = \ + &(elm)->field.tqe_next; \ + else \ + (head)->tqh_last = &(elm)->field.tqe_next; \ + (head)->tqh_first = (elm); \ + (elm)->field.tqe_prev = &(head)->tqh_first; \ +} while (0) + +#define TAILQ_INSERT_TAIL(head, elm, field) do { \ + (elm)->field.tqe_next = NULL; \ + (elm)->field.tqe_prev = (head)->tqh_last; \ + *(head)->tqh_last = (elm); \ + (head)->tqh_last = &(elm)->field.tqe_next; \ +} while (0) + +#define TAILQ_INSERT_AFTER(head, listelm, elm, field) do { \ + if (((elm)->field.tqe_next = (listelm)->field.tqe_next) != NULL)\ + (elm)->field.tqe_next->field.tqe_prev = \ + &(elm)->field.tqe_next; \ + else \ + (head)->tqh_last = &(elm)->field.tqe_next; \ + (listelm)->field.tqe_next = (elm); \ + (elm)->field.tqe_prev = &(listelm)->field.tqe_next; \ +} while (0) + +#define TAILQ_INSERT_BEFORE(listelm, elm, field) do { \ + (elm)->field.tqe_prev = (listelm)->field.tqe_prev; \ + (elm)->field.tqe_next = (listelm); \ + *(listelm)->field.tqe_prev = (elm); \ + (listelm)->field.tqe_prev = &(elm)->field.tqe_next; \ +} while (0) + +#define TAILQ_REMOVE(head, elm, field) do { \ + if (((elm)->field.tqe_next) != NULL) \ + (elm)->field.tqe_next->field.tqe_prev = \ + (elm)->field.tqe_prev; \ + else \ + (head)->tqh_last = (elm)->field.tqe_prev; \ + *(elm)->field.tqe_prev = (elm)->field.tqe_next; \ +} while (0) + +#define TAILQ_REPLACE(head, elm, elm2, field) do { \ + if (((elm2)->field.tqe_next = (elm)->field.tqe_next) != NULL) \ + (elm2)->field.tqe_next->field.tqe_prev = \ + &(elm2)->field.tqe_next; \ + else \ + (head)->tqh_last = &(elm2)->field.tqe_next; \ + (elm2)->field.tqe_prev = (elm)->field.tqe_prev; \ + *(elm2)->field.tqe_prev = (elm2); \ +} while (0) + +/* + * Circular queue definitions. + */ +#define CIRCLEQ_HEAD(name, type) \ +struct name { \ + struct type *cqh_first; /* first element */ \ + struct type *cqh_last; /* last element */ \ +} + +#define CIRCLEQ_HEAD_INITIALIZER(head) \ + { CIRCLEQ_END(&head), CIRCLEQ_END(&head) } + +#define CIRCLEQ_ENTRY(type) \ +struct { \ + struct type *cqe_next; /* next element */ \ + struct type *cqe_prev; /* previous element */ \ +} + +/* + * Circular queue access methods + */ +#define CIRCLEQ_FIRST(head) ((head)->cqh_first) +#define CIRCLEQ_LAST(head) ((head)->cqh_last) +#define CIRCLEQ_END(head) ((void *)(head)) +#define CIRCLEQ_NEXT(elm, field) ((elm)->field.cqe_next) +#define CIRCLEQ_PREV(elm, field) ((elm)->field.cqe_prev) +#define CIRCLEQ_EMPTY(head) \ + (CIRCLEQ_FIRST(head) == CIRCLEQ_END(head)) + +#define CIRCLEQ_FOREACH(var, head, field) \ + for((var) = CIRCLEQ_FIRST(head); \ + (var) != CIRCLEQ_END(head); \ + (var) = CIRCLEQ_NEXT(var, field)) + +#define CIRCLEQ_FOREACH_REVERSE(var, head, field) \ + for((var) = CIRCLEQ_LAST(head); \ + (var) != CIRCLEQ_END(head); \ + (var) = CIRCLEQ_PREV(var, field)) + +/* + * Circular queue functions. + */ +#define CIRCLEQ_INIT(head) do { \ + (head)->cqh_first = CIRCLEQ_END(head); \ + (head)->cqh_last = CIRCLEQ_END(head); \ +} while (0) + +#define CIRCLEQ_INSERT_AFTER(head, listelm, elm, field) do { \ + (elm)->field.cqe_next = (listelm)->field.cqe_next; \ + (elm)->field.cqe_prev = (listelm); \ + if ((listelm)->field.cqe_next == CIRCLEQ_END(head)) \ + (head)->cqh_last = (elm); \ + else \ + (listelm)->field.cqe_next->field.cqe_prev = (elm); \ + (listelm)->field.cqe_next = (elm); \ +} while (0) + +#define CIRCLEQ_INSERT_BEFORE(head, listelm, elm, field) do { \ + (elm)->field.cqe_next = (listelm); \ + (elm)->field.cqe_prev = (listelm)->field.cqe_prev; \ + if ((listelm)->field.cqe_prev == CIRCLEQ_END(head)) \ + (head)->cqh_first = (elm); \ + else \ + (listelm)->field.cqe_prev->field.cqe_next = (elm); \ + (listelm)->field.cqe_prev = (elm); \ +} while (0) + +#define CIRCLEQ_INSERT_HEAD(head, elm, field) do { \ + (elm)->field.cqe_next = (head)->cqh_first; \ + (elm)->field.cqe_prev = CIRCLEQ_END(head); \ + if ((head)->cqh_last == CIRCLEQ_END(head)) \ + (head)->cqh_last = (elm); \ + else \ + (head)->cqh_first->field.cqe_prev = (elm); \ + (head)->cqh_first = (elm); \ +} while (0) + +#define CIRCLEQ_INSERT_TAIL(head, elm, field) do { \ + (elm)->field.cqe_next = CIRCLEQ_END(head); \ + (elm)->field.cqe_prev = (head)->cqh_last; \ + if ((head)->cqh_first == CIRCLEQ_END(head)) \ + (head)->cqh_first = (elm); \ + else \ + (head)->cqh_last->field.cqe_next = (elm); \ + (head)->cqh_last = (elm); \ +} while (0) + +#define CIRCLEQ_REMOVE(head, elm, field) do { \ + if ((elm)->field.cqe_next == CIRCLEQ_END(head)) \ + (head)->cqh_last = (elm)->field.cqe_prev; \ + else \ + (elm)->field.cqe_next->field.cqe_prev = \ + (elm)->field.cqe_prev; \ + if ((elm)->field.cqe_prev == CIRCLEQ_END(head)) \ + (head)->cqh_first = (elm)->field.cqe_next; \ + else \ + (elm)->field.cqe_prev->field.cqe_next = \ + (elm)->field.cqe_next; \ +} while (0) + +#define CIRCLEQ_REPLACE(head, elm, elm2, field) do { \ + if (((elm2)->field.cqe_next = (elm)->field.cqe_next) == \ + CIRCLEQ_END(head)) \ + (head).cqh_last = (elm2); \ + else \ + (elm2)->field.cqe_next->field.cqe_prev = (elm2); \ + if (((elm2)->field.cqe_prev = (elm)->field.cqe_prev) == \ + CIRCLEQ_END(head)) \ + (head).cqh_first = (elm2); \ + else \ + (elm2)->field.cqe_prev->field.cqe_next = (elm2); \ +} while (0) + +#endif /* !SYS_QUEUE_H__ */ diff --git a/contrib/ntp/sntp/libevent/config.h.in b/contrib/ntp/sntp/libevent/config.h.in new file mode 100644 index 000000000..8a0764188 --- /dev/null +++ b/contrib/ntp/sntp/libevent/config.h.in @@ -0,0 +1,524 @@ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Define if libevent should build without support for a debug mode */ +#undef DISABLE_DEBUG_MODE + +/* Define if libevent should not allow replacing the mm functions */ +#undef DISABLE_MM_REPLACEMENT + +/* Define if libevent should not be compiled with thread support */ +#undef DISABLE_THREAD_SUPPORT + +/* Define to 1 if you have the `accept4' function. */ +#undef HAVE_ACCEPT4 + +/* Define to 1 if you have the `arc4random' function. */ +#undef HAVE_ARC4RANDOM + +/* Define to 1 if you have the `arc4random_buf' function. */ +#undef HAVE_ARC4RANDOM_BUF + +/* Define to 1 if you have the header file. */ +#undef HAVE_ARPA_INET_H + +/* Define to 1 if you have the `clock_gettime' function. */ +#undef HAVE_CLOCK_GETTIME + +/* Define to 1 if you have the declaration of `CTL_KERN', and to 0 if you + don't. */ +#undef HAVE_DECL_CTL_KERN + +/* Define to 1 if you have the declaration of `KERN_ARND', and to 0 if you + don't. */ +#undef HAVE_DECL_KERN_ARND + +/* Define to 1 if you have the declaration of `KERN_RANDOM', and to 0 if you + don't. */ +#undef HAVE_DECL_KERN_RANDOM + +/* Define to 1 if you have the declaration of `RANDOM_UUID', and to 0 if you + don't. */ +#undef HAVE_DECL_RANDOM_UUID + +/* Define if /dev/poll is available */ +#undef HAVE_DEVPOLL + +/* Define to 1 if you have the header file. */ +#undef HAVE_DLFCN_H + +/* Define if your system supports the epoll system calls */ +#undef HAVE_EPOLL + +/* Define to 1 if you have the `epoll_create1' function. */ +#undef HAVE_EPOLL_CREATE1 + +/* Define to 1 if you have the `epoll_ctl' function. */ +#undef HAVE_EPOLL_CTL + +/* Define to 1 if you have the `eventfd' function. */ +#undef HAVE_EVENTFD + +/* Define if your system supports event ports */ +#undef HAVE_EVENT_PORTS + +/* Define to 1 if you have the `fcntl' function. */ +#undef HAVE_FCNTL + +/* Define to 1 if you have the header file. */ +#undef HAVE_FCNTL_H + +/* Define to 1 if the system has the type `fd_mask'. */ +#undef HAVE_FD_MASK + +/* Do we have getaddrinfo()? */ +#undef HAVE_GETADDRINFO + +/* Define to 1 if you have the `getegid' function. */ +#undef HAVE_GETEGID + +/* Define to 1 if you have the `geteuid' function. */ +#undef HAVE_GETEUID + +/* Define this if you have any gethostbyname_r() */ +#undef HAVE_GETHOSTBYNAME_R + +/* Define this if gethostbyname_r takes 3 arguments */ +#undef HAVE_GETHOSTBYNAME_R_3_ARG + +/* Define this if gethostbyname_r takes 5 arguments */ +#undef HAVE_GETHOSTBYNAME_R_5_ARG + +/* Define this if gethostbyname_r takes 6 arguments */ +#undef HAVE_GETHOSTBYNAME_R_6_ARG + +/* Define to 1 if you have the `getifaddrs' function. */ +#undef HAVE_GETIFADDRS + +/* Define to 1 if you have the `getnameinfo' function. */ +#undef HAVE_GETNAMEINFO + +/* Define to 1 if you have the `getprotobynumber' function. */ +#undef HAVE_GETPROTOBYNUMBER + +/* Define to 1 if you have the `getservbyname' function. */ +#undef HAVE_GETSERVBYNAME + +/* Define to 1 if you have the `gettimeofday' function. */ +#undef HAVE_GETTIMEOFDAY + +/* Define to 1 if you have the header file. */ +#undef HAVE_IFADDRS_H + +/* Define to 1 if you have the `inet_ntop' function. */ +#undef HAVE_INET_NTOP + +/* Define to 1 if you have the `inet_pton' function. */ +#undef HAVE_INET_PTON + +/* Define to 1 if you have the header file. */ +#undef HAVE_INTTYPES_H + +/* Define to 1 if you have the `issetugid' function. */ +#undef HAVE_ISSETUGID + +/* Define to 1 if you have the `kqueue' function. */ +#undef HAVE_KQUEUE + +/* Define if the system has zlib */ +#undef HAVE_LIBZ + +/* Define to 1 if you have the `mach_absolute_time' function. */ +#undef HAVE_MACH_ABSOLUTE_TIME + +/* Define to 1 if you have the header file. */ +#undef HAVE_MACH_MACH_TIME_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_MEMORY_H + +/* Define to 1 if you have the `mmap' function. */ +#undef HAVE_MMAP + +/* Define to 1 if you have the `nanosleep' function. */ +#undef HAVE_NANOSLEEP + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETDB_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IN6_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_IN_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_NETINET_TCP_H + +/* Define if the system has openssl */ +#undef HAVE_OPENSSL + +/* Define to 1 if you have the `pipe' function. */ +#undef HAVE_PIPE + +/* Define to 1 if you have the `pipe2' function. */ +#undef HAVE_PIPE2 + +/* Define to 1 if you have the `poll' function. */ +#undef HAVE_POLL + +/* Define to 1 if you have the header file. */ +#undef HAVE_POLL_H + +/* Define to 1 if you have the `port_create' function. */ +#undef HAVE_PORT_CREATE + +/* Define to 1 if you have the header file. */ +#undef HAVE_PORT_H + +/* Define if you have POSIX threads libraries and header files. */ +#undef HAVE_PTHREAD + +/* Define if we have pthreads on this system */ +#undef HAVE_PTHREADS + +/* Define to 1 if you have the `putenv' function. */ +#undef HAVE_PUTENV + +/* Define to 1 if the system has the type `sa_family_t'. */ +#undef HAVE_SA_FAMILY_T + +/* Define to 1 if you have the `select' function. */ +#undef HAVE_SELECT + +/* Define to 1 if you have the `sendfile' function. */ +#undef HAVE_SENDFILE + +/* Define to 1 if you have the `setenv' function. */ +#undef HAVE_SETENV + +/* Define if F_SETFD is defined in */ +#undef HAVE_SETFD + +/* Define to 1 if you have the `setrlimit' function. */ +#undef HAVE_SETRLIMIT + +/* Define to 1 if you have the `sigaction' function. */ +#undef HAVE_SIGACTION + +/* Define to 1 if you have the `signal' function. */ +#undef HAVE_SIGNAL + +/* Define to 1 if you have the `splice' function. */ +#undef HAVE_SPLICE + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDARG_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDDEF_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDINT_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDLIB_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STRINGS_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STRING_H + +/* Define to 1 if you have the `strlcpy' function. */ +#undef HAVE_STRLCPY + +/* Define to 1 if you have the `strsep' function. */ +#undef HAVE_STRSEP + +/* Define to 1 if you have the `strtok_r' function. */ +#undef HAVE_STRTOK_R + +/* Define to 1 if you have the `strtoll' function. */ +#undef HAVE_STRTOLL + +/* Define to 1 if the system has the type `struct addrinfo'. */ +#undef HAVE_STRUCT_ADDRINFO + +/* Define to 1 if the system has the type `struct in6_addr'. */ +#undef HAVE_STRUCT_IN6_ADDR + +/* Define to 1 if `s6_addr16' is a member of `struct in6_addr'. */ +#undef HAVE_STRUCT_IN6_ADDR_S6_ADDR16 + +/* Define to 1 if `s6_addr32' is a member of `struct in6_addr'. */ +#undef HAVE_STRUCT_IN6_ADDR_S6_ADDR32 + +/* Define to 1 if the system has the type `struct sockaddr_in6'. */ +#undef HAVE_STRUCT_SOCKADDR_IN6 + +/* Define to 1 if `sin6_len' is a member of `struct sockaddr_in6'. */ +#undef HAVE_STRUCT_SOCKADDR_IN6_SIN6_LEN + +/* Define to 1 if `sin_len' is a member of `struct sockaddr_in'. */ +#undef HAVE_STRUCT_SOCKADDR_IN_SIN_LEN + +/* Define to 1 if the system has the type `struct sockaddr_storage'. */ +#undef HAVE_STRUCT_SOCKADDR_STORAGE + +/* Define to 1 if `ss_family' is a member of `struct sockaddr_storage'. */ +#undef HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY + +/* Define to 1 if `__ss_family' is a member of `struct sockaddr_storage'. */ +#undef HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY + +/* Define to 1 if the system has the type `struct so_linger'. */ +#undef HAVE_STRUCT_SO_LINGER + +/* Define to 1 if you have the `sysctl' function. */ +#undef HAVE_SYSCTL + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_DEVPOLL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_EPOLL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_EVENTFD_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_EVENT_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_IOCTL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_MMAN_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_PARAM_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_QUEUE_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_RESOURCE_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_SELECT_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_SENDFILE_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_SOCKET_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_STAT_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_SYSCTL_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TIMERFD_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TIME_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TYPES_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_UIO_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_WAIT_H + +/* Define if TAILQ_FOREACH is defined in */ +#undef HAVE_TAILQFOREACH + +/* Define if timeradd is defined in */ +#undef HAVE_TIMERADD + +/* Define if timerclear is defined in */ +#undef HAVE_TIMERCLEAR + +/* Define if timercmp is defined in */ +#undef HAVE_TIMERCMP + +/* Define to 1 if you have the `timerfd_create' function. */ +#undef HAVE_TIMERFD_CREATE + +/* Define if timerisset is defined in */ +#undef HAVE_TIMERISSET + +/* Define to 1 if the system has the type `uint16_t'. */ +#undef HAVE_UINT16_T + +/* Define to 1 if the system has the type `uint32_t'. */ +#undef HAVE_UINT32_T + +/* Define to 1 if the system has the type `uint64_t'. */ +#undef HAVE_UINT64_T + +/* Define to 1 if the system has the type `uint8_t'. */ +#undef HAVE_UINT8_T + +/* Define to 1 if the system has the type `uintptr_t'. */ +#undef HAVE_UINTPTR_T + +/* Define to 1 if you have the `umask' function. */ +#undef HAVE_UMASK + +/* Define to 1 if you have the header file. */ +#undef HAVE_UNISTD_H + +/* Define to 1 if you have the `unsetenv' function. */ +#undef HAVE_UNSETENV + +/* Define to 1 if you have the `usleep' function. */ +#undef HAVE_USLEEP + +/* Define to 1 if you have the `vasprintf' function. */ +#undef HAVE_VASPRINTF + +/* Define if kqueue works correctly with pipes */ +#undef HAVE_WORKING_KQUEUE + +/* Define to 1 if you have the header file. */ +#undef HAVE_ZLIB_H + +/* Define to the sub-directory in which libtool stores uninstalled libraries. + */ +#undef LT_OBJDIR + +/* Numeric representation of the version */ +#undef NUMERIC_VERSION + +/* Name of package */ +#undef PACKAGE + +/* Define to the address where bug reports for this package should be sent. */ +#undef PACKAGE_BUGREPORT + +/* Define to the full name of this package. */ +#undef PACKAGE_NAME + +/* Define to the full name and version of this package. */ +#undef PACKAGE_STRING + +/* Define to the one symbol short name of this package. */ +#undef PACKAGE_TARNAME + +/* Define to the home page for this package. */ +#undef PACKAGE_URL + +/* Define to the version of this package. */ +#undef PACKAGE_VERSION + +/* Define to necessary symbol if this constant uses a non-standard name on + your system. */ +#undef PTHREAD_CREATE_JOINABLE + +/* The size of `int', as computed by sizeof. */ +#undef SIZEOF_INT + +/* The size of `long', as computed by sizeof. */ +#undef SIZEOF_LONG + +/* The size of `long long', as computed by sizeof. */ +#undef SIZEOF_LONG_LONG + +/* The size of `off_t', as computed by sizeof. */ +#undef SIZEOF_OFF_T + +/* The size of `pthread_t', as computed by sizeof. */ +#undef SIZEOF_PTHREAD_T + +/* The size of `short', as computed by sizeof. */ +#undef SIZEOF_SHORT + +/* The size of `size_t', as computed by sizeof. */ +#undef SIZEOF_SIZE_T + +/* The size of `void *', as computed by sizeof. */ +#undef SIZEOF_VOID_P + +/* Define to 1 if you have the ANSI C header files. */ +#undef STDC_HEADERS + +/* Define to 1 if you can safely include both and . */ +#undef TIME_WITH_SYS_TIME + +/* Version number of package */ +#undef VERSION + +/* Enable large inode numbers on Mac OS X 10.5. */ +#ifndef _DARWIN_USE_64_BIT_INODE +# define _DARWIN_USE_64_BIT_INODE 1 +#endif + +/* Number of bits in a file offset, on hosts where this is settable. */ +#undef _FILE_OFFSET_BITS + +/* Define for large files, on AIX-style hosts. */ +#undef _LARGE_FILES + +/* Define to 1 if on MINIX. */ +#undef _MINIX + +/* Define to 2 if the system does not provide POSIX.1 features except with + this defined. */ +#undef _POSIX_1_SOURCE + +/* Define to 1 if you need to in order for `stat' and other things to work. */ +#undef _POSIX_SOURCE + +/* Define to 500 only on HP-UX. */ +#undef _XOPEN_SOURCE + +/* Enable extensions on AIX 3, Interix. */ +#ifndef _ALL_SOURCE +# undef _ALL_SOURCE +#endif +/* Enable GNU extensions on systems that have them. */ +#ifndef _GNU_SOURCE +# undef _GNU_SOURCE +#endif +/* Enable threading extensions on Solaris. */ +#ifndef _POSIX_PTHREAD_SEMANTICS +# undef _POSIX_PTHREAD_SEMANTICS +#endif +/* Enable extensions on HP NonStop. */ +#ifndef _TANDEM_SOURCE +# undef _TANDEM_SOURCE +#endif +/* Enable general extensions on Solaris. */ +#ifndef __EXTENSIONS__ +# undef __EXTENSIONS__ +#endif + + +/* Define to appropriate substitue if compiler doesnt have __func__ */ +#undef __func__ + +/* Define to empty if `const' does not conform to ANSI C. */ +#undef const + +/* Define to `__inline__' or `__inline' if that's what the C compiler + calls it, or to nothing if 'inline' is not supported under any name. */ +#ifndef __cplusplus +#undef inline +#endif + +/* Define to `int' if does not define. */ +#undef pid_t + +/* Define to `unsigned int' if does not define. */ +#undef size_t + +/* Define to unsigned int if you dont have it */ +#undef socklen_t + +/* Define to `int' if does not define. */ +#undef ssize_t diff --git a/contrib/ntp/sntp/libevent/configure b/contrib/ntp/sntp/libevent/configure new file mode 100755 index 000000000..e759b4f8e --- /dev/null +++ b/contrib/ntp/sntp/libevent/configure @@ -0,0 +1,18025 @@ +#! /bin/sh +# Guess values for system-dependent variables and create Makefiles. +# Generated by GNU Autoconf 2.69 for libevent 2.1.5-beta. +# +# +# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. +# +# +# This configure script is free software; the Free Software Foundation +# gives unlimited permission to copy, distribute and modify it. +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +# Use a proper internal environment variable to ensure we don't fall + # into an infinite loop, continuously re-executing ourselves. + if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then + _as_can_reexec=no; export _as_can_reexec; + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +as_fn_exit 255 + fi + # We don't want this to propagate to other subprocesses. + { _as_can_reexec=; unset _as_can_reexec;} +if test "x$CONFIG_SHELL" = x; then + as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi +" + as_required="as_fn_return () { (exit \$1); } +as_fn_success () { as_fn_return 0; } +as_fn_failure () { as_fn_return 1; } +as_fn_ret_success () { return 0; } +as_fn_ret_failure () { return 1; } + +exitcode=0 +as_fn_success || { exitcode=1; echo as_fn_success failed.; } +as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } +as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } +as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } +if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : + +else + exitcode=1; echo positional parameters were not saved. +fi +test x\$exitcode = x0 || exit 1 +test -x / || exit 1" + as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO + as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO + eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && + test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 +test \$(( 1 + 1 )) = 2 || exit 1 + + test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ + || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" + if (eval "$as_required") 2>/dev/null; then : + as_have_required=yes +else + as_have_required=no +fi + if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : + +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_found=false +for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + as_found=: + case $as_dir in #( + /*) + for as_base in sh bash ksh sh5; do + # Try only shells that exist, to save several forks. + as_shell=$as_dir/$as_base + if { test -f "$as_shell" || test -f "$as_shell.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : + CONFIG_SHELL=$as_shell as_have_required=yes + if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : + break 2 +fi +fi + done;; + esac + as_found=false +done +$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : + CONFIG_SHELL=$SHELL as_have_required=yes +fi; } +IFS=$as_save_IFS + + + if test "x$CONFIG_SHELL" != x; then : + export CONFIG_SHELL + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 +fi + + if test x$as_have_required = xno; then : + $as_echo "$0: This script requires a shell more modern than all" + $as_echo "$0: the shells that I found on your system." + if test x${ZSH_VERSION+set} = xset ; then + $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" + $as_echo "$0: be upgraded to zsh 4.3.4 or later." + else + $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, +$0: including any error possibly output before this +$0: message. Then install a modern shell, or manually run +$0: the script under such a shell if you do have one." + fi + exit 1 +fi +fi +fi +SHELL=${CONFIG_SHELL-/bin/sh} +export SHELL +# Unset more variables known to interfere with behavior of common tools. +CLICOLOR_FORCE= GREP_OPTIONS= +unset CLICOLOR_FORCE GREP_OPTIONS + +## --------------------- ## +## M4sh Shell Functions. ## +## --------------------- ## +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + + + as_lineno_1=$LINENO as_lineno_1a=$LINENO + as_lineno_2=$LINENO as_lineno_2a=$LINENO + eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && + test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { + # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) + sed -n ' + p + /[$]LINENO/= + ' <$as_myself | + sed ' + s/[$]LINENO.*/&-/ + t lineno + b + :lineno + N + :loop + s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ + t loop + s/-\n.*// + ' >$as_me.lineno && + chmod +x "$as_me.lineno" || + { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + + # If we had to re-execute with $CONFIG_SHELL, we're ensured to have + # already done that, so ensure we don't try to do so again and fall + # in an infinite loop. This has already happened in practice. + _as_can_reexec=no; export _as_can_reexec + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensitive to this). + . "./$as_me.lineno" + # Exit status is that of the last command. + exit +} + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + +SHELL=${CONFIG_SHELL-/bin/sh} + + +test -n "$DJDIR" || exec 7<&0 &1 + +# Name of the host. +# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, +# so uname gets run too. +ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` + +# +# Initializations. +# +ac_default_prefix=/usr/local +ac_clean_files= +ac_config_libobj_dir=. +LIBOBJS= +cross_compiling=no +subdirs= +MFLAGS= +MAKEFLAGS= + +# Identity of this package. +PACKAGE_NAME='libevent' +PACKAGE_TARNAME='libevent' +PACKAGE_VERSION='2.1.5-beta' +PACKAGE_STRING='libevent 2.1.5-beta' +PACKAGE_BUGREPORT='' +PACKAGE_URL='' + +ac_unique_file="event.c" +# Factoring default headers for most tests. +ac_includes_default="\ +#include +#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_SYS_STAT_H +# include +#endif +#ifdef STDC_HEADERS +# include +# include +#else +# ifdef HAVE_STDLIB_H +# include +# endif +#endif +#ifdef HAVE_STRING_H +# if !defined STDC_HEADERS && defined HAVE_MEMORY_H +# include +# endif +# include +#endif +#ifdef HAVE_STRINGS_H +# include +#endif +#ifdef HAVE_INTTYPES_H +# include +#endif +#ifdef HAVE_STDINT_H +# include +#endif +#ifdef HAVE_UNISTD_H +# include +#endif" + +ac_subst_vars='am__EXEEXT_FALSE +am__EXEEXT_TRUE +LTLIBOBJS +INSTALL_LIBEVENT_FALSE +INSTALL_LIBEVENT_TRUE +LIBEVENT_GC_SECTIONS +PTHREADS_FALSE +PTHREADS_TRUE +PTHREAD_CFLAGS +PTHREAD_LIBS +PTHREAD_CC +acx_pthread_config +SIGNAL_SUPPORT_FALSE +SIGNAL_SUPPORT_TRUE +EVPORT_BACKEND_FALSE +EVPORT_BACKEND_TRUE +EPOLL_BACKEND_FALSE +EPOLL_BACKEND_TRUE +LIBOBJS +KQUEUE_BACKEND_FALSE +KQUEUE_BACKEND_TRUE +DEVPOLL_BACKEND_FALSE +DEVPOLL_BACKEND_TRUE +POLL_BACKEND_FALSE +POLL_BACKEND_TRUE +SELECT_BACKEND_FALSE +SELECT_BACKEND_TRUE +STRLCPY_IMPL_FALSE +STRLCPY_IMPL_TRUE +BUILD_WITH_NO_UNDEFINED_FALSE +BUILD_WITH_NO_UNDEFINED_TRUE +BUILD_CYGWIN_FALSE +BUILD_CYGWIN_TRUE +BUILD_WIN32_FALSE +BUILD_WIN32_TRUE +OPENSSL_FALSE +OPENSSL_TRUE +OPENSSL_LIBS +OPENSSL_INCS +PKG_CONFIG +OPENSSL_LIBADD +EV_LIB_GDI +EV_LIB_WS32 +ZLIB_REGRESS_FALSE +ZLIB_REGRESS_TRUE +ZLIB_LIBS +BUILD_REGRESS_FALSE +BUILD_REGRESS_TRUE +BUILD_SAMPLES_FALSE +BUILD_SAMPLES_TRUE +LIBTOOL_DEPS +OTOOL64 +OTOOL +LIPO +NMEDIT +DSYMUTIL +MANIFEST_TOOL +RANLIB +ac_ct_AR +AR +DLLTOOL +OBJDUMP +NM +ac_ct_DUMPBIN +DUMPBIN +LD +FGREP +LIBTOOL +SED +LN_S +EGREP +GREP +CPP +am__fastdepCC_FALSE +am__fastdepCC_TRUE +CCDEPMODE +am__nodep +AMDEPBACKSLASH +AMDEP_FALSE +AMDEP_TRUE +am__quote +am__include +DEPDIR +OBJEXT +EXEEXT +ac_ct_CC +CPPFLAGS +LDFLAGS +CFLAGS +CC +host_os +host_vendor +host_cpu +host +build_os +build_vendor +build_cpu +build +AM_BACKSLASH +AM_DEFAULT_VERBOSITY +AM_DEFAULT_V +AM_V +am__untar +am__tar +AMTAR +am__leading_dot +SET_MAKE +AWK +mkdir_p +MKDIR_P +INSTALL_STRIP_PROGRAM +STRIP +install_sh +MAKEINFO +AUTOHEADER +AUTOMAKE +AUTOCONF +ACLOCAL +VERSION +PACKAGE +CYGPATH_W +am__isrc +INSTALL_DATA +INSTALL_SCRIPT +INSTALL_PROGRAM +target_alias +host_alias +build_alias +LIBS +ECHO_T +ECHO_N +ECHO_C +DEFS +mandir +localedir +libdir +psdir +pdfdir +dvidir +htmldir +infodir +docdir +oldincludedir +includedir +localstatedir +sharedstatedir +sysconfdir +datadir +datarootdir +libexecdir +sbindir +bindir +program_transform_name +prefix +exec_prefix +PACKAGE_URL +PACKAGE_BUGREPORT +PACKAGE_STRING +PACKAGE_VERSION +PACKAGE_TARNAME +PACKAGE_NAME +PATH_SEPARATOR +SHELL' +ac_subst_files='' +ac_user_opts=' +enable_option_checking +enable_silent_rules +enable_dependency_tracking +enable_gcc_warnings +enable_gcc_hardening +enable_thread_support +enable_malloc_replacement +enable_openssl +enable_debug_mode +enable_libevent_install +enable_libevent_regress +enable_samples +enable_function_sections +enable_verbose_debug +enable_shared +enable_static +with_pic +enable_fast_install +with_gnu_ld +with_sysroot +enable_libtool_lock +enable_largefile +' + ac_precious_vars='build_alias +host_alias +target_alias +CC +CFLAGS +LDFLAGS +LIBS +CPPFLAGS +CPP' + + +# Initialize some variables set by options. +ac_init_help= +ac_init_version=false +ac_unrecognized_opts= +ac_unrecognized_sep= +# The variables have the same names as the options, with +# dashes changed to underlines. +cache_file=/dev/null +exec_prefix=NONE +no_create= +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +verbose= +x_includes=NONE +x_libraries=NONE + +# Installation directory options. +# These are left unexpanded so users can "make install exec_prefix=/foo" +# and all the variables that are supposed to be based on exec_prefix +# by default will actually change. +# Use braces instead of parens because sh, perl, etc. also accept them. +# (The list follows the same order as the GNU Coding Standards.) +bindir='${exec_prefix}/bin' +sbindir='${exec_prefix}/sbin' +libexecdir='${exec_prefix}/libexec' +datarootdir='${prefix}/share' +datadir='${datarootdir}' +sysconfdir='${prefix}/etc' +sharedstatedir='${prefix}/com' +localstatedir='${prefix}/var' +includedir='${prefix}/include' +oldincludedir='/usr/include' +docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' +infodir='${datarootdir}/info' +htmldir='${docdir}' +dvidir='${docdir}' +pdfdir='${docdir}' +psdir='${docdir}' +libdir='${exec_prefix}/lib' +localedir='${datarootdir}/locale' +mandir='${datarootdir}/man' + +ac_prev= +ac_dashdash= +for ac_option +do + # If the previous option needs an argument, assign it. + if test -n "$ac_prev"; then + eval $ac_prev=\$ac_option + ac_prev= + continue + fi + + case $ac_option in + *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; + *=) ac_optarg= ;; + *) ac_optarg=yes ;; + esac + + # Accept the important Cygnus configure options, so we can diagnose typos. + + case $ac_dashdash$ac_option in + --) + ac_dashdash=yes ;; + + -bindir | --bindir | --bindi | --bind | --bin | --bi) + ac_prev=bindir ;; + -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) + bindir=$ac_optarg ;; + + -build | --build | --buil | --bui | --bu) + ac_prev=build_alias ;; + -build=* | --build=* | --buil=* | --bui=* | --bu=*) + build_alias=$ac_optarg ;; + + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + cache_file=$ac_optarg ;; + + --config-cache | -C) + cache_file=config.cache ;; + + -datadir | --datadir | --datadi | --datad) + ac_prev=datadir ;; + -datadir=* | --datadir=* | --datadi=* | --datad=*) + datadir=$ac_optarg ;; + + -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ + | --dataroo | --dataro | --datar) + ac_prev=datarootdir ;; + -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ + | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) + datarootdir=$ac_optarg ;; + + -disable-* | --disable-*) + ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=no ;; + + -docdir | --docdir | --docdi | --doc | --do) + ac_prev=docdir ;; + -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) + docdir=$ac_optarg ;; + + -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) + ac_prev=dvidir ;; + -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) + dvidir=$ac_optarg ;; + + -enable-* | --enable-*) + ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=\$ac_optarg ;; + + -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ + | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ + | --exec | --exe | --ex) + ac_prev=exec_prefix ;; + -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ + | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ + | --exec=* | --exe=* | --ex=*) + exec_prefix=$ac_optarg ;; + + -gas | --gas | --ga | --g) + # Obsolete; use --with-gas. + with_gas=yes ;; + + -help | --help | --hel | --he | -h) + ac_init_help=long ;; + -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) + ac_init_help=recursive ;; + -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) + ac_init_help=short ;; + + -host | --host | --hos | --ho) + ac_prev=host_alias ;; + -host=* | --host=* | --hos=* | --ho=*) + host_alias=$ac_optarg ;; + + -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) + ac_prev=htmldir ;; + -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ + | --ht=*) + htmldir=$ac_optarg ;; + + -includedir | --includedir | --includedi | --included | --include \ + | --includ | --inclu | --incl | --inc) + ac_prev=includedir ;; + -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ + | --includ=* | --inclu=* | --incl=* | --inc=*) + includedir=$ac_optarg ;; + + -infodir | --infodir | --infodi | --infod | --info | --inf) + ac_prev=infodir ;; + -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) + infodir=$ac_optarg ;; + + -libdir | --libdir | --libdi | --libd) + ac_prev=libdir ;; + -libdir=* | --libdir=* | --libdi=* | --libd=*) + libdir=$ac_optarg ;; + + -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ + | --libexe | --libex | --libe) + ac_prev=libexecdir ;; + -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ + | --libexe=* | --libex=* | --libe=*) + libexecdir=$ac_optarg ;; + + -localedir | --localedir | --localedi | --localed | --locale) + ac_prev=localedir ;; + -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) + localedir=$ac_optarg ;; + + -localstatedir | --localstatedir | --localstatedi | --localstated \ + | --localstate | --localstat | --localsta | --localst | --locals) + ac_prev=localstatedir ;; + -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ + | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) + localstatedir=$ac_optarg ;; + + -mandir | --mandir | --mandi | --mand | --man | --ma | --m) + ac_prev=mandir ;; + -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) + mandir=$ac_optarg ;; + + -nfp | --nfp | --nf) + # Obsolete; use --without-fp. + with_fp=no ;; + + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c | -n) + no_create=yes ;; + + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + no_recursion=yes ;; + + -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ + | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ + | --oldin | --oldi | --old | --ol | --o) + ac_prev=oldincludedir ;; + -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ + | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ + | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) + oldincludedir=$ac_optarg ;; + + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + prefix=$ac_optarg ;; + + -program-prefix | --program-prefix | --program-prefi | --program-pref \ + | --program-pre | --program-pr | --program-p) + ac_prev=program_prefix ;; + -program-prefix=* | --program-prefix=* | --program-prefi=* \ + | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) + program_prefix=$ac_optarg ;; + + -program-suffix | --program-suffix | --program-suffi | --program-suff \ + | --program-suf | --program-su | --program-s) + ac_prev=program_suffix ;; + -program-suffix=* | --program-suffix=* | --program-suffi=* \ + | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) + program_suffix=$ac_optarg ;; + + -program-transform-name | --program-transform-name \ + | --program-transform-nam | --program-transform-na \ + | --program-transform-n | --program-transform- \ + | --program-transform | --program-transfor \ + | --program-transfo | --program-transf \ + | --program-trans | --program-tran \ + | --progr-tra | --program-tr | --program-t) + ac_prev=program_transform_name ;; + -program-transform-name=* | --program-transform-name=* \ + | --program-transform-nam=* | --program-transform-na=* \ + | --program-transform-n=* | --program-transform-=* \ + | --program-transform=* | --program-transfor=* \ + | --program-transfo=* | --program-transf=* \ + | --program-trans=* | --program-tran=* \ + | --progr-tra=* | --program-tr=* | --program-t=*) + program_transform_name=$ac_optarg ;; + + -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) + ac_prev=pdfdir ;; + -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) + pdfdir=$ac_optarg ;; + + -psdir | --psdir | --psdi | --psd | --ps) + ac_prev=psdir ;; + -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) + psdir=$ac_optarg ;; + + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + silent=yes ;; + + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) + ac_prev=sbindir ;; + -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ + | --sbi=* | --sb=*) + sbindir=$ac_optarg ;; + + -sharedstatedir | --sharedstatedir | --sharedstatedi \ + | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ + | --sharedst | --shareds | --shared | --share | --shar \ + | --sha | --sh) + ac_prev=sharedstatedir ;; + -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ + | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ + | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ + | --sha=* | --sh=*) + sharedstatedir=$ac_optarg ;; + + -site | --site | --sit) + ac_prev=site ;; + -site=* | --site=* | --sit=*) + site=$ac_optarg ;; + + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + srcdir=$ac_optarg ;; + + -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ + | --syscon | --sysco | --sysc | --sys | --sy) + ac_prev=sysconfdir ;; + -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ + | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) + sysconfdir=$ac_optarg ;; + + -target | --target | --targe | --targ | --tar | --ta | --t) + ac_prev=target_alias ;; + -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) + target_alias=$ac_optarg ;; + + -v | -verbose | --verbose | --verbos | --verbo | --verb) + verbose=yes ;; + + -version | --version | --versio | --versi | --vers | -V) + ac_init_version=: ;; + + -with-* | --with-*) + ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=\$ac_optarg ;; + + -without-* | --without-*) + ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=no ;; + + --x) + # Obsolete; use --with-x. + with_x=yes ;; + + -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ + | --x-incl | --x-inc | --x-in | --x-i) + ac_prev=x_includes ;; + -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ + | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) + x_includes=$ac_optarg ;; + + -x-libraries | --x-libraries | --x-librarie | --x-librari \ + | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) + ac_prev=x_libraries ;; + -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ + | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) + x_libraries=$ac_optarg ;; + + -*) as_fn_error $? "unrecognized option: \`$ac_option' +Try \`$0 --help' for more information" + ;; + + *=*) + ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` + # Reject names that are not valid shell variable names. + case $ac_envvar in #( + '' | [0-9]* | *[!_$as_cr_alnum]* ) + as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; + esac + eval $ac_envvar=\$ac_optarg + export $ac_envvar ;; + + *) + # FIXME: should be removed in autoconf 3.0. + $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && + $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" + ;; + + esac +done + +if test -n "$ac_prev"; then + ac_option=--`echo $ac_prev | sed 's/_/-/g'` + as_fn_error $? "missing argument to $ac_option" +fi + +if test -n "$ac_unrecognized_opts"; then + case $enable_option_checking in + no) ;; + fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; + *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; + esac +fi + +# Check all directory arguments for consistency. +for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ + datadir sysconfdir sharedstatedir localstatedir includedir \ + oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ + libdir localedir mandir +do + eval ac_val=\$$ac_var + # Remove trailing slashes. + case $ac_val in + */ ) + ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` + eval $ac_var=\$ac_val;; + esac + # Be sure to have absolute directory names. + case $ac_val in + [\\/$]* | ?:[\\/]* ) continue;; + NONE | '' ) case $ac_var in *prefix ) continue;; esac;; + esac + as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" +done + +# There might be people who depend on the old broken behavior: `$host' +# used to hold the argument of --host etc. +# FIXME: To remove some day. +build=$build_alias +host=$host_alias +target=$target_alias + +# FIXME: To remove some day. +if test "x$host_alias" != x; then + if test "x$build_alias" = x; then + cross_compiling=maybe + elif test "x$build_alias" != "x$host_alias"; then + cross_compiling=yes + fi +fi + +ac_tool_prefix= +test -n "$host_alias" && ac_tool_prefix=$host_alias- + +test "$silent" = yes && exec 6>/dev/null + + +ac_pwd=`pwd` && test -n "$ac_pwd" && +ac_ls_di=`ls -di .` && +ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || + as_fn_error $? "working directory cannot be determined" +test "X$ac_ls_di" = "X$ac_pwd_ls_di" || + as_fn_error $? "pwd does not report name of working directory" + + +# Find the source files, if location was not specified. +if test -z "$srcdir"; then + ac_srcdir_defaulted=yes + # Try the directory containing this script, then the parent directory. + ac_confdir=`$as_dirname -- "$as_myself" || +$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_myself" : 'X\(//\)[^/]' \| \ + X"$as_myself" : 'X\(//\)$' \| \ + X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_myself" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + srcdir=$ac_confdir + if test ! -r "$srcdir/$ac_unique_file"; then + srcdir=.. + fi +else + ac_srcdir_defaulted=no +fi +if test ! -r "$srcdir/$ac_unique_file"; then + test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." + as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" +fi +ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" +ac_abs_confdir=`( + cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" + pwd)` +# When building in place, set srcdir=. +if test "$ac_abs_confdir" = "$ac_pwd"; then + srcdir=. +fi +# Remove unnecessary trailing slashes from srcdir. +# Double slashes in file names in object file debugging info +# mess up M-x gdb in Emacs. +case $srcdir in +*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; +esac +for ac_var in $ac_precious_vars; do + eval ac_env_${ac_var}_set=\${${ac_var}+set} + eval ac_env_${ac_var}_value=\$${ac_var} + eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} + eval ac_cv_env_${ac_var}_value=\$${ac_var} +done + +# +# Report the --help message. +# +if test "$ac_init_help" = "long"; then + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat <<_ACEOF +\`configure' configures libevent 2.1.5-beta to adapt to many kinds of systems. + +Usage: $0 [OPTION]... [VAR=VALUE]... + +To assign environment variables (e.g., CC, CFLAGS...), specify them as +VAR=VALUE. See below for descriptions of some of the useful variables. + +Defaults for the options are specified in brackets. + +Configuration: + -h, --help display this help and exit + --help=short display options specific to this package + --help=recursive display the short help of all the included packages + -V, --version display version information and exit + -q, --quiet, --silent do not print \`checking ...' messages + --cache-file=FILE cache test results in FILE [disabled] + -C, --config-cache alias for \`--cache-file=config.cache' + -n, --no-create do not create output files + --srcdir=DIR find the sources in DIR [configure dir or \`..'] + +Installation directories: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX + [PREFIX] + +By default, \`make install' will install all the files in +\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify +an installation prefix other than \`$ac_default_prefix' using \`--prefix', +for instance \`--prefix=\$HOME'. + +For better control, use the options below. + +Fine tuning of the installation directories: + --bindir=DIR user executables [EPREFIX/bin] + --sbindir=DIR system admin executables [EPREFIX/sbin] + --libexecdir=DIR program executables [EPREFIX/libexec] + --sysconfdir=DIR read-only single-machine data [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] + --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --libdir=DIR object code libraries [EPREFIX/lib] + --includedir=DIR C header files [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc [/usr/include] + --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] + --datadir=DIR read-only architecture-independent data [DATAROOTDIR] + --infodir=DIR info documentation [DATAROOTDIR/info] + --localedir=DIR locale-dependent data [DATAROOTDIR/locale] + --mandir=DIR man documentation [DATAROOTDIR/man] + --docdir=DIR documentation root [DATAROOTDIR/doc/libevent] + --htmldir=DIR html documentation [DOCDIR] + --dvidir=DIR dvi documentation [DOCDIR] + --pdfdir=DIR pdf documentation [DOCDIR] + --psdir=DIR ps documentation [DOCDIR] +_ACEOF + + cat <<\_ACEOF + +Program names: + --program-prefix=PREFIX prepend PREFIX to installed program names + --program-suffix=SUFFIX append SUFFIX to installed program names + --program-transform-name=PROGRAM run sed PROGRAM on installed program names + +System types: + --build=BUILD configure for building on BUILD [guessed] + --host=HOST cross-compile to build programs to run on HOST [BUILD] +_ACEOF +fi + +if test -n "$ac_init_help"; then + case $ac_init_help in + short | recursive ) echo "Configuration of libevent 2.1.5-beta:";; + esac + cat <<\_ACEOF + +Optional Features: + --disable-option-checking ignore unrecognized --enable/--with options + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --enable-silent-rules less verbose build output (undo: "make V=1") + --disable-silent-rules verbose build output (undo: "make V=0") + --enable-dependency-tracking + do not reject slow dependency extractors + --disable-dependency-tracking + speeds up one-time build + --disable-gcc-warnings disable verbose warnings with GCC + --enable-gcc-hardening enable compiler security checks + --disable-thread-support + disable support for threading + --disable-malloc-replacement + disable support for replacing the memory mgt + functions + --disable-openssl disable support for openssl encryption + --disable-debug-mode disable support for running in debug mode + --disable-libevent-install, disable installation of libevent + + --disable-libevent-regress, skip regress in make check + + --disable-samples, skip building of sample programs + + --enable-function-sections, make static library allow smaller binaries with --gc-sections + + --enable-verbose-debug, verbose debug logging + + --enable-shared[=PKGS] build shared libraries [default=yes] + --enable-static[=PKGS] build static libraries [default=yes] + --enable-fast-install[=PKGS] + optimize for fast installation [default=yes] + --disable-libtool-lock avoid locking (might break parallel builds) + --disable-largefile omit support for large files + +Optional Packages: + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-pic try to use only PIC/non-PIC objects [default=use + both] + --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-sysroot=DIR Search for dependent libraries within DIR + (or the compiler's sysroot if not specified). + +Some influential environment variables: + CC C compiler command + CFLAGS C compiler flags + LDFLAGS linker flags, e.g. -L if you have libraries in a + nonstandard directory + LIBS libraries to pass to the linker, e.g. -l + CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if + you have headers in a nonstandard directory + CPP C preprocessor + +Use these variables to override the choices made by `configure' or to help +it to find libraries and programs with nonstandard names/locations. + +Report bugs to the package provider. +_ACEOF +ac_status=$? +fi + +if test "$ac_init_help" = "recursive"; then + # If there are subdirs, report their specific --help. + for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue + test -d "$ac_dir" || + { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || + continue + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + cd "$ac_dir" || { ac_status=$?; continue; } + # Check for guested configure. + if test -f "$ac_srcdir/configure.gnu"; then + echo && + $SHELL "$ac_srcdir/configure.gnu" --help=recursive + elif test -f "$ac_srcdir/configure"; then + echo && + $SHELL "$ac_srcdir/configure" --help=recursive + else + $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + fi || ac_status=$? + cd "$ac_pwd" || { ac_status=$?; break; } + done +fi + +test -n "$ac_init_help" && exit $ac_status +if $ac_init_version; then + cat <<\_ACEOF +libevent configure 2.1.5-beta +generated by GNU Autoconf 2.69 + +Copyright (C) 2012 Free Software Foundation, Inc. +This configure script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it. +_ACEOF + exit +fi + +## ------------------------ ## +## Autoconf initialization. ## +## ------------------------ ## + +# ac_fn_c_try_compile LINENO +# -------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_compile + +# ac_fn_c_try_cpp LINENO +# ---------------------- +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_cpp + +# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists, giving a warning if it cannot be compiled using +# the include files in INCLUDES and setting the cache variable VAR +# accordingly. +ac_fn_c_check_header_mongrel () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if eval \${$3+:} false; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +else + # Is the header compilable? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 +$as_echo_n "checking $2 usability... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_header_compiler=yes +else + ac_header_compiler=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 +$as_echo_n "checking $2 presence... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <$2> +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ac_header_preproc=yes +else + ac_header_preproc=no +fi +rm -f conftest.err conftest.i conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( + yes:no: ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} + ;; + no:yes:* ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} + ;; +esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=\$ac_header_compiler" +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_mongrel + +# ac_fn_c_try_run LINENO +# ---------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes +# that executables *can* be run. +ac_fn_c_try_run () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then : + ac_retval=0 +else + $as_echo "$as_me: program exited with status $ac_status" >&5 + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=$ac_status +fi + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_run + +# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists and can be compiled using the include files in +# INCLUDES, setting the cache variable VAR accordingly. +ac_fn_c_check_header_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_compile + +# ac_fn_c_try_link LINENO +# ----------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_link + +# ac_fn_c_check_func LINENO FUNC VAR +# ---------------------------------- +# Tests whether FUNC exists, setting the cache variable VAR accordingly +ac_fn_c_check_func () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Define $2 to an innocuous variant, in case declares $2. + For example, HP-UX 11i declares gettimeofday. */ +#define $2 innocuous_$2 + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $2 (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $2 + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $2 (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$2 || defined __stub___$2 +choke me +#endif + +int +main () +{ +return $2 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_func + +# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES +# --------------------------------------------- +# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR +# accordingly. +ac_fn_c_check_decl () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + as_decl_name=`echo $2|sed 's/ *(.*//'` + as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 +$as_echo_n "checking whether $as_decl_name is declared... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +#ifndef $as_decl_name +#ifdef __cplusplus + (void) $as_decl_use; +#else + (void) $as_decl_name; +#endif +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_decl + +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type + +# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES +# -------------------------------------------- +# Tries to find the compile-time value of EXPR in a program that includes +# INCLUDES, setting VAR accordingly. Returns whether the value could be +# computed +ac_fn_c_compute_int () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if test "$cross_compiling" = yes; then + # Depending upon the size, compute the lo and hi bounds. +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) >= 0)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_lo=0 ac_mid=0 + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) <= $ac_mid)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=$ac_mid; break +else + as_fn_arith $ac_mid + 1 && ac_lo=$as_val + if test $ac_lo -le $ac_mid; then + ac_lo= ac_hi= + break + fi + as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) < 0)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=-1 ac_mid=-1 + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) >= $ac_mid)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_lo=$ac_mid; break +else + as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val + if test $ac_mid -le $ac_hi; then + ac_lo= ac_hi= + break + fi + as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + ac_lo= ac_hi= +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +# Binary search between lo and hi bounds. +while test "x$ac_lo" != "x$ac_hi"; do + as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) <= $ac_mid)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=$ac_mid +else + as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +done +case $ac_lo in #(( +?*) eval "$3=\$ac_lo"; ac_retval=0 ;; +'') ac_retval=1 ;; +esac + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +static long int longval () { return $2; } +static unsigned long int ulongval () { return $2; } +#include +#include +int +main () +{ + + FILE *f = fopen ("conftest.val", "w"); + if (! f) + return 1; + if (($2) < 0) + { + long int i = longval (); + if (i != ($2)) + return 1; + fprintf (f, "%ld", i); + } + else + { + unsigned long int i = ulongval (); + if (i != ($2)) + return 1; + fprintf (f, "%lu", i); + } + /* Do not output a trailing newline, as this causes \r\n confusion + on some platforms. */ + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + echo >>conftest.val; read $3 &5 +$as_echo_n "checking for $2.$3... " >&6; } +if eval \${$4+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$5 +int +main () +{ +static $2 ac_aggr; +if (ac_aggr.$3) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$4=yes" +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$5 +int +main () +{ +static $2 ac_aggr; +if (sizeof ac_aggr.$3) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$4=yes" +else + eval "$4=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$4 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_member +cat >config.log <<_ACEOF +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by libevent $as_me 2.1.5-beta, which was +generated by GNU Autoconf 2.69. Invocation command line was + + $ $0 $@ + +_ACEOF +exec 5>>config.log +{ +cat <<_ASUNAME +## --------- ## +## Platform. ## +## --------- ## + +hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` + +/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` +/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` +/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` +/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` + +_ASUNAME + +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + $as_echo "PATH: $as_dir" + done +IFS=$as_save_IFS + +} >&5 + +cat >&5 <<_ACEOF + + +## ----------- ## +## Core tests. ## +## ----------- ## + +_ACEOF + + +# Keep a trace of the command line. +# Strip out --no-create and --no-recursion so they do not pile up. +# Strip out --silent because we don't want to record it for future runs. +# Also quote any args containing shell meta-characters. +# Make two passes to allow for proper duplicate-argument suppression. +ac_configure_args= +ac_configure_args0= +ac_configure_args1= +ac_must_keep_next=false +for ac_pass in 1 2 +do + for ac_arg + do + case $ac_arg in + -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + continue ;; + *\'*) + ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + case $ac_pass in + 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; + 2) + as_fn_append ac_configure_args1 " '$ac_arg'" + if test $ac_must_keep_next = true; then + ac_must_keep_next=false # Got value, back to normal. + else + case $ac_arg in + *=* | --config-cache | -C | -disable-* | --disable-* \ + | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ + | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ + | -with-* | --with-* | -without-* | --without-* | --x) + case "$ac_configure_args0 " in + "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; + esac + ;; + -* ) ac_must_keep_next=true ;; + esac + fi + as_fn_append ac_configure_args " '$ac_arg'" + ;; + esac + done +done +{ ac_configure_args0=; unset ac_configure_args0;} +{ ac_configure_args1=; unset ac_configure_args1;} + +# When interrupted or exit'd, cleanup temporary files, and complete +# config.log. We remove comments because anyway the quotes in there +# would cause problems or look ugly. +# WARNING: Use '\'' to represent an apostrophe within the trap. +# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. +trap 'exit_status=$? + # Save into config.log some information that might help in debugging. + { + echo + + $as_echo "## ---------------- ## +## Cache variables. ## +## ---------------- ##" + echo + # The following way of writing the cache mishandles newlines in values, +( + for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + (set) 2>&1 | + case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + sed -n \ + "s/'\''/'\''\\\\'\'''\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" + ;; #( + *) + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) + echo + + $as_echo "## ----------------- ## +## Output variables. ## +## ----------------- ##" + echo + for ac_var in $ac_subst_vars + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + + if test -n "$ac_subst_files"; then + $as_echo "## ------------------- ## +## File substitutions. ## +## ------------------- ##" + echo + for ac_var in $ac_subst_files + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + fi + + if test -s confdefs.h; then + $as_echo "## ----------- ## +## confdefs.h. ## +## ----------- ##" + echo + cat confdefs.h + echo + fi + test "$ac_signal" != 0 && + $as_echo "$as_me: caught signal $ac_signal" + $as_echo "$as_me: exit $exit_status" + } >&5 + rm -f core *.core core.conftest.* && + rm -f -r conftest* confdefs* conf$$* $ac_clean_files && + exit $exit_status +' 0 +for ac_signal in 1 2 13 15; do + trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal +done +ac_signal=0 + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -f -r conftest* confdefs.h + +$as_echo "/* confdefs.h */" > confdefs.h + +# Predefined preprocessor variables. + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_NAME "$PACKAGE_NAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_TARNAME "$PACKAGE_TARNAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION "$PACKAGE_VERSION" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_STRING "$PACKAGE_STRING" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_URL "$PACKAGE_URL" +_ACEOF + + +# Let the site file select an alternate cache file if it wants to. +# Prefer an explicitly selected file to automatically selected ones. +ac_site_file1=NONE +ac_site_file2=NONE +if test -n "$CONFIG_SITE"; then + # We do not want a PATH search for config.site. + case $CONFIG_SITE in #(( + -*) ac_site_file1=./$CONFIG_SITE;; + */*) ac_site_file1=$CONFIG_SITE;; + *) ac_site_file1=./$CONFIG_SITE;; + esac +elif test "x$prefix" != xNONE; then + ac_site_file1=$prefix/share/config.site + ac_site_file2=$prefix/etc/config.site +else + ac_site_file1=$ac_default_prefix/share/config.site + ac_site_file2=$ac_default_prefix/etc/config.site +fi +for ac_site_file in "$ac_site_file1" "$ac_site_file2" +do + test "x$ac_site_file" = xNONE && continue + if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 +$as_echo "$as_me: loading site script $ac_site_file" >&6;} + sed 's/^/| /' "$ac_site_file" >&5 + . "$ac_site_file" \ + || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "failed to load site script $ac_site_file +See \`config.log' for more details" "$LINENO" 5; } + fi +done + +if test -r "$cache_file"; then + # Some versions of bash will fail to source /dev/null (special files + # actually), so we avoid doing that. DJGPP emulates it as a regular file. + if test /dev/null != "$cache_file" && test -f "$cache_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 +$as_echo "$as_me: loading cache $cache_file" >&6;} + case $cache_file in + [\\/]* | ?:[\\/]* ) . "$cache_file";; + *) . "./$cache_file";; + esac + fi +else + { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 +$as_echo "$as_me: creating cache $cache_file" >&6;} + >$cache_file +fi + +# Check that the precious variables saved in the cache have kept the same +# value. +ac_cache_corrupted=false +for ac_var in $ac_precious_vars; do + eval ac_old_set=\$ac_cv_env_${ac_var}_set + eval ac_new_set=\$ac_env_${ac_var}_set + eval ac_old_val=\$ac_cv_env_${ac_var}_value + eval ac_new_val=\$ac_env_${ac_var}_value + case $ac_old_set,$ac_new_set in + set,) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,set) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,);; + *) + if test "x$ac_old_val" != "x$ac_new_val"; then + # differences in whitespace do not lead to failure. + ac_old_val_w=`echo x $ac_old_val` + ac_new_val_w=`echo x $ac_new_val` + if test "$ac_old_val_w" != "$ac_new_val_w"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 +$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} + ac_cache_corrupted=: + else + { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 +$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} + eval $ac_var=\$ac_old_val + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 +$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 +$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} + fi;; + esac + # Pass precious variables to config.status. + if test "$ac_new_set" = set; then + case $ac_new_val in + *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *) ac_arg=$ac_var=$ac_new_val ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) as_fn_append ac_configure_args " '$ac_arg'" ;; + esac + fi +done +if $ac_cache_corrupted; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 +$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} + as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 +fi +## -------------------- ## +## Main body of script. ## +## -------------------- ## + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + +ac_aux_dir= +for ac_dir in build-aux "$srcdir"/build-aux; do + if test -f "$ac_dir/install-sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f "$ac_dir/install.sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + elif test -f "$ac_dir/shtool"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break + fi +done +if test -z "$ac_aux_dir"; then + as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5 +fi + +# These three variables are undocumented and unsupported, +# and are intended to be withdrawn in a future Autoconf release. +# They can cause serious problems if a builder's source tree is in a directory +# whose full name contains unusual characters. +ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. +ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. +ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. + + +am__api_version='1.15' + +# Find a good install program. We prefer a C program (faster), +# so one script is as good as another. But avoid the broken or +# incompatible versions: +# SysV /etc/install, /usr/sbin/install +# SunOS /usr/etc/install +# IRIX /sbin/install +# AIX /bin/install +# AmigaOS /C/install, which installs bootblocks on floppy discs +# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag +# AFS /usr/afsws/bin/install, which mishandles nonexistent args +# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# OS/2's system install, which has a completely different semantic +# ./install, which can be erroneously created by make from ./install.sh. +# Reject install programs that cannot install multiple files. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 +$as_echo_n "checking for a BSD-compatible install... " >&6; } +if test -z "$INSTALL"; then +if ${ac_cv_path_install+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + # Account for people who put trailing slashes in PATH elements. +case $as_dir/ in #(( + ./ | .// | /[cC]/* | \ + /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ + ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ + /usr/ucb/* ) ;; + *) + # OSF1 and SCO ODT 3.0 have their own names for install. + # Don't use installbsd from OSF since it installs stuff as root + # by default. + for ac_prog in ginstall scoinst install; do + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then + if test $ac_prog = install && + grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # AIX install. It has an incompatible calling convention. + : + elif test $ac_prog = install && + grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # program-specific install script used by HP pwplus--don't use. + : + else + rm -rf conftest.one conftest.two conftest.dir + echo one > conftest.one + echo two > conftest.two + mkdir conftest.dir + if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && + test -s conftest.one && test -s conftest.two && + test -s conftest.dir/conftest.one && + test -s conftest.dir/conftest.two + then + ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" + break 3 + fi + fi + fi + done + done + ;; +esac + + done +IFS=$as_save_IFS + +rm -rf conftest.one conftest.two conftest.dir + +fi + if test "${ac_cv_path_install+set}" = set; then + INSTALL=$ac_cv_path_install + else + # As a last resort, use the slow shell script. Don't cache a + # value for INSTALL within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + INSTALL=$ac_install_sh + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 +$as_echo "$INSTALL" >&6; } + +# Use test -z because SunOS4 sh mishandles braces in ${var-val}. +# It thinks the first close brace ends the variable substitution. +test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' + +test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' + +test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 +$as_echo_n "checking whether build environment is sane... " >&6; } +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[\\\"\#\$\&\'\`$am_lf]*) + as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; +esac +case $srcdir in + *[\\\"\#\$\&\'\`$am_lf\ \ ]*) + as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; +esac + +# Do 'set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$*" != "X $srcdir/configure conftest.file" \ + && test "$*" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken + alias in your environment" "$LINENO" 5 + fi + if test "$2" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done + test "$2" = conftest.file + ) +then + # Ok. + : +else + as_fn_error $? "newly created file is older than distributed files! +Check your system clock" "$LINENO" 5 +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi + +rm -f conftest.file + +test "$program_prefix" != NONE && + program_transform_name="s&^&$program_prefix&;$program_transform_name" +# Use a double $ so make ignores it. +test "$program_suffix" != NONE && + program_transform_name="s&\$&$program_suffix&;$program_transform_name" +# Double any \ or $. +# By default was `s,x,x', remove it if useless. +ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' +program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` + +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` + +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; + esac +fi +# Use eval to expand $SHELL +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " +else + am_missing_run= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} +fi + +if test x"${install_sh+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" + esac +fi + +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the 'STRIP' environment variable to overrule this program. +if test "$cross_compiling" != no; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 +$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } +if test -z "$MKDIR_P"; then + if ${ac_cv_path_mkdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in mkdir gmkdir; do + for ac_exec_ext in '' $ac_executable_extensions; do + as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue + case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( + 'mkdir (GNU coreutils) '* | \ + 'mkdir (coreutils) '* | \ + 'mkdir (fileutils) '4.1*) + ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext + break 3;; + esac + done + done + done +IFS=$as_save_IFS + +fi + + test -d ./--version && rmdir ./--version + if test "${ac_cv_path_mkdir+set}" = set; then + MKDIR_P="$ac_cv_path_mkdir -p" + else + # As a last resort, use the slow shell script. Don't cache a + # value for MKDIR_P within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + MKDIR_P="$ac_install_sh -d" + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 +$as_echo "$MKDIR_P" >&6; } + +for ac_prog in gawk mawk nawk awk +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AWK+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AWK"; then + ac_cv_prog_AWK="$AWK" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AWK="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AWK=$ac_cv_prog_AWK +if test -n "$AWK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +$as_echo "$AWK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AWK" && break +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +set x ${MAKE-make} +ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat >conftest.make <<\_ACEOF +SHELL = /bin/sh +all: + @echo '@@@%%%=$(MAKE)=@@@%%%' +_ACEOF +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. +case `${MAKE-make} -f conftest.make 2>/dev/null` in + *@@@%%%=?*=@@@%%%*) + eval ac_cv_prog_make_${ac_make}_set=yes;; + *) + eval ac_cv_prog_make_${ac_make}_set=no;; +esac +rm -f conftest.make +fi +if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + SET_MAKE= +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + SET_MAKE="MAKE=${MAKE-make}" +fi + +rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=1;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + am__isrc=' -I$(srcdir)' + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 + fi +fi + +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi + + +# Define the identity of the package. + PACKAGE='libevent' + VERSION='2.1.5-beta' + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE "$PACKAGE" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define VERSION "$VERSION" +_ACEOF + +# Some tools Automake needs. + +ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} + + +AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} + + +AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} + + +AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} + + +MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} + +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +mkdir_p='$(MKDIR_P)' + +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AMTAR='$${TAR-tar}' + + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar pax cpio none' + +am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' + + + + + + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 + fi +fi + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=0;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + +ac_config_headers="$ac_config_headers config.h evconfig-private.h:evconfig-private.h.in" + + +$as_echo "#define NUMERIC_VERSION 0x02010500" >>confdefs.h + + +if test "$prefix" = "NONE"; then + prefix="/usr/local" +fi + + +# Make sure we can run config.sub. +$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || + as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 +$as_echo_n "checking build system type... " >&6; } +if ${ac_cv_build+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_build_alias=$build_alias +test "x$ac_build_alias" = x && + ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` +test "x$ac_build_alias" = x && + as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 +ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 +$as_echo "$ac_cv_build" >&6; } +case $ac_cv_build in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; +esac +build=$ac_cv_build +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_build +shift +build_cpu=$1 +build_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +build_os=$* +IFS=$ac_save_IFS +case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 +$as_echo_n "checking host system type... " >&6; } +if ${ac_cv_host+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "x$host_alias" = x; then + ac_cv_host=$ac_cv_build +else + ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 +$as_echo "$ac_cv_host" >&6; } +case $ac_cv_host in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; +esac +host=$ac_cv_host +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_host +shift +host_cpu=$1 +host_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +host_os=$* +IFS=$ac_save_IFS +case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac + + +DEPDIR="${am__leading_dot}deps" + +ac_config_commands="$ac_config_commands depfiles" + + +am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 +$as_echo_n "checking for style of include used by $am_make... " >&6; } +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 +$as_echo "$_am_result" >&6; } +rm -f confinc confmf + +# Check whether --enable-dependency-tracking was given. +if test "${enable_dependency_tracking+set}" = set; then : + enableval=$enable_dependency_tracking; +fi + +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi + if test "x$enable_dependency_tracking" != xno; then + AMDEP_TRUE= + AMDEP_FALSE='#' +else + AMDEP_TRUE='#' + AMDEP_FALSE= +fi + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +else + CC="$ac_cv_prog_CC" +fi + +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. +set dummy ${ac_tool_prefix}cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + fi +fi +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + ac_prog_rejected=no +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" + fi +fi +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl.exe + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl.exe +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CC" && break +done + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +fi + +fi + + +test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } + +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" +# Try to create an executable without -o first, disregard a.out. +# It will help us diagnose broken compilers, and finding out an intuition +# of exeext. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 +$as_echo_n "checking whether the C compiler works... " >&6; } +ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` + +# The possible output files: +ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" + +ac_rmfiles= +for ac_file in $ac_files +do + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + * ) ac_rmfiles="$ac_rmfiles $ac_file";; + esac +done +rm -f $ac_rmfiles + +if { { ac_try="$ac_link_default" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link_default") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. +# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' +# in a Makefile. We should not override ac_cv_exeext if it was cached, +# so that the user can short-circuit this test for compilers unknown to +# Autoconf. +for ac_file in $ac_files '' +do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) + ;; + [ab].out ) + # We found the default executable, but exeext='' is most + # certainly right. + break;; + *.* ) + if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; + then :; else + ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + fi + # We set ac_cv_exeext here because the later test for it is not + # safe: cross compilers may not add the suffix if given an `-o' + # argument, so we may need to know it at that point already. + # Even if this section looks crufty: it has the advantage of + # actually working. + break;; + * ) + break;; + esac +done +test "$ac_cv_exeext" = no && ac_cv_exeext= + +else + ac_file='' +fi +if test -z "$ac_file"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +$as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "C compiler cannot create executables +See \`config.log' for more details" "$LINENO" 5; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 +$as_echo_n "checking for C compiler default output file name... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 +$as_echo "$ac_file" >&6; } +ac_exeext=$ac_cv_exeext + +rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 +$as_echo_n "checking for suffix of executables... " >&6; } +if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # If both `conftest.exe' and `conftest' are `present' (well, observable) +# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will +# work properly (i.e., refer to `conftest.exe'), while it won't with +# `rm'. +for ac_file in conftest.exe conftest conftest.*; do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + break;; + * ) break;; + esac +done +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of executables: cannot compile and link +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest conftest$ac_cv_exeext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 +$as_echo "$ac_cv_exeext" >&6; } + +rm -f conftest.$ac_ext +EXEEXT=$ac_cv_exeext +ac_exeext=$EXEEXT +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +FILE *f = fopen ("conftest.out", "w"); + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +ac_clean_files="$ac_clean_files conftest.out" +# Check that the compiler produces executables we can run. If not, either +# the compiler is broken, or we cross compile. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 +$as_echo_n "checking whether we are cross compiling... " >&6; } +if test "$cross_compiling" != yes; then + { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if { ac_try='./conftest$ac_cv_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + cross_compiling=no + else + if test "$cross_compiling" = maybe; then + cross_compiling=yes + else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot run C compiled programs. +If you meant to cross compile, use \`--host'. +See \`config.log' for more details" "$LINENO" 5; } + fi + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 +$as_echo "$cross_compiling" >&6; } + +rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 +$as_echo_n "checking for suffix of object files... " >&6; } +if ${ac_cv_objext+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.o conftest.obj +if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + for ac_file in conftest.o conftest.obj conftest.*; do + test -f "$ac_file" || continue; + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; + *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` + break;; + esac +done +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of object files: cannot compile +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest.$ac_cv_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 +$as_echo "$ac_cv_objext" >&6; } +OBJEXT=$ac_cv_objext +ac_objext=$OBJEXT +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 +$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } +if ${ac_cv_c_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 +$as_echo "$ac_cv_c_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GCC=yes +else + GCC= +fi +ac_test_CFLAGS=${CFLAGS+set} +ac_save_CFLAGS=$CFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 +$as_echo_n "checking whether $CC accepts -g... " >&6; } +if ${ac_cv_prog_cc_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_c_werror_flag=$ac_c_werror_flag + ac_c_werror_flag=yes + ac_cv_prog_cc_g=no + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +else + CFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + ac_c_werror_flag=$ac_save_c_werror_flag + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 +$as_echo "$ac_cv_prog_cc_g" >&6; } +if test "$ac_test_CFLAGS" = set; then + CFLAGS=$ac_save_CFLAGS +elif test $ac_cv_prog_cc_g = yes; then + if test "$GCC" = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-g" + fi +else + if test "$GCC" = yes; then + CFLAGS="-O2" + else + CFLAGS= + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if ${ac_cv_prog_cc_c89+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +struct stat; +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC + +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c89" != xno; then : + +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +depcc="$CC" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CC_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CC_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CC_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CC_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } +CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then + am__fastdepCC_TRUE= + am__fastdepCC_FALSE='#' +else + am__fastdepCC_TRUE='#' + am__fastdepCC_FALSE= +fi + + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP +else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 +$as_echo_n "checking for grep that handles long lines and -e... " >&6; } +if ${ac_cv_path_GREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$GREP"; then + ac_path_GREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in grep ggrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_GREP" || continue +# Check for GNU ac_path_GREP and select it if it is found. + # Check for GNU $ac_path_GREP +case `"$ac_path_GREP" --version 2>&1` in +*GNU*) + ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'GREP' >> "conftest.nl" + "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_GREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_GREP="$ac_path_GREP" + ac_path_GREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_GREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_GREP"; then + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_GREP=$GREP +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 +$as_echo "$ac_cv_path_GREP" >&6; } + GREP="$ac_cv_path_GREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 +$as_echo_n "checking for egrep... " >&6; } +if ${ac_cv_path_EGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 + then ac_cv_path_EGREP="$GREP -E" + else + if test -z "$EGREP"; then + ac_path_EGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in egrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_EGREP" || continue +# Check for GNU ac_path_EGREP and select it if it is found. + # Check for GNU $ac_path_EGREP +case `"$ac_path_EGREP" --version 2>&1` in +*GNU*) + ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'EGREP' >> "conftest.nl" + "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_EGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP="$ac_path_EGREP" + ac_path_EGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_EGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_EGREP=$EGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 +$as_echo "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if ${ac_cv_header_stdc+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + ac_cv_header_stdc=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif + +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + +else + ac_cv_header_stdc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then + +$as_echo "#define STDC_HEADERS 1" >>confdefs.h + +fi + +# On IRIX 5.3, sys/types and inttypes.h are conflicting. +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + + + + ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" +if test "x$ac_cv_header_minix_config_h" = xyes; then : + MINIX=yes +else + MINIX= +fi + + + if test "$MINIX" = yes; then + +$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h + + +$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h + + +$as_echo "#define _MINIX 1" >>confdefs.h + + fi + + case "$host_os" in + hpux*) + +$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h + + ;; + esac + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 +$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } +if ${ac_cv_safe_to_define___extensions__+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +# define __EXTENSIONS__ 1 + $ac_includes_default +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_safe_to_define___extensions__=yes +else + ac_cv_safe_to_define___extensions__=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 +$as_echo "$ac_cv_safe_to_define___extensions__" >&6; } + test $ac_cv_safe_to_define___extensions__ = yes && + $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h + + $as_echo "#define _ALL_SOURCE 1" >>confdefs.h + + $as_echo "#define _GNU_SOURCE 1" >>confdefs.h + + $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h + + $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h + + + + + + + +#case "$host_os" in +# +# osf5*) +# CFLAGS="$CFLAGS -D_OSF_SOURCE" +# ;; +#esac + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi + +# AC_PROG_MKDIR_P - $(MKDIR_P) should be defined by AM_INIT_AUTOMAKE + +# AC_PROG_SED is only available in Autoconf >= 2.59b; workaround for older +# versions +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + + +if test $ac_cv_c_compiler_gnu = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 +$as_echo_n "checking whether $CC needs -traditional... " >&6; } +if ${ac_cv_prog_gcc_traditional+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_pattern="Autoconf.*'x'" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TIOCGETP +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes +else + ac_cv_prog_gcc_traditional=no +fi +rm -f conftest* + + + if test $ac_cv_prog_gcc_traditional = no; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TCGETA +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes +fi +rm -f conftest* + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 +$as_echo "$ac_cv_prog_gcc_traditional" >&6; } + if test $ac_cv_prog_gcc_traditional = yes; then + CC="$CC -traditional" + fi +fi + + +# We need to test for at least gcc 2.95 here, because older versions don't +# have -fno-strict-aliasing +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#if !defined(__GNUC__) || (__GNUC__ < 2) || (__GNUC__ == 2 && __GNUC_MINOR__ < 95) +#error +#endif + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + have_gcc295=yes +else + have_gcc295=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test "$GCC" = "yes" ; then + # Enable many gcc warnings by default... + CFLAGS="$CFLAGS -Wall" + # And disable the strict-aliasing optimization, since it breaks + # our sockaddr-handling code in strange ways. + if test x$have_gcc295 = xyes; then + CFLAGS="$CFLAGS -fno-strict-aliasing" + fi +fi + +# OS X Lion started deprecating the system openssl. Let's just disable +# all deprecation warnings on OS X. +case "$host_os" in + + darwin*) + CFLAGS="$CFLAGS -Wno-deprecated-declarations" + ;; +esac + +# Check whether --enable-gcc-warnings was given. +if test "${enable_gcc_warnings+set}" = set; then : + enableval=$enable_gcc_warnings; +fi + + +# Check whether --enable-gcc-hardening was given. +if test "${enable_gcc_hardening+set}" = set; then : + enableval=$enable_gcc_hardening; if test x$enableval = xyes; then + CFLAGS="$CFLAGS -D_FORTIFY_SOURCE=2 -fstack-protector-all" + CFLAGS="$CFLAGS -fwrapv -fPIE -Wstack-protector" + CFLAGS="$CFLAGS --param ssp-buffer-size=1" +fi +fi + + +# Check whether --enable-thread-support was given. +if test "${enable_thread_support+set}" = set; then : + enableval=$enable_thread_support; +else + enable_thread_support=yes +fi + +# Check whether --enable-malloc-replacement was given. +if test "${enable_malloc_replacement+set}" = set; then : + enableval=$enable_malloc_replacement; +else + enable_malloc_replacement=yes +fi + +# Check whether --enable-openssl was given. +if test "${enable_openssl+set}" = set; then : + enableval=$enable_openssl; +else + enable_openssl=yes +fi + +# Check whether --enable-debug-mode was given. +if test "${enable_debug_mode+set}" = set; then : + enableval=$enable_debug_mode; +else + enable_debug_mode=yes +fi + +# Check whether --enable-libevent-install was given. +if test "${enable_libevent_install+set}" = set; then : + enableval=$enable_libevent_install; +else + enable_libevent_install=yes +fi + +# Check whether --enable-libevent-regress was given. +if test "${enable_libevent_regress+set}" = set; then : + enableval=$enable_libevent_regress; +else + enable_libevent_regress=yes +fi + +# Check whether --enable-samples was given. +if test "${enable_samples+set}" = set; then : + enableval=$enable_samples; +else + enable_samples=yes +fi + +# Check whether --enable-function-sections was given. +if test "${enable_function_sections+set}" = set; then : + enableval=$enable_function_sections; +else + enable_function_sections=no +fi + +# Check whether --enable-verbose-debug was given. +if test "${enable_verbose_debug+set}" = set; then : + enableval=$enable_verbose_debug; +else + enable_verbose_debug=no +fi + + + +case `pwd` in + *\ * | *\ *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 +$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; +esac + + + +macro_version='2.4.2' +macro_revision='1.3337' + + + + + + + + + + + + + +ltmain="$ac_aux_dir/ltmain.sh" + +# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\(["`$\\]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' + +ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +$as_echo_n "checking how to print strings... " >&6; } +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "" +} + +case "$ECHO" in + printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +$as_echo "printf" >&6; } ;; + print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +$as_echo "print -r" >&6; } ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +$as_echo "cat" >&6; } ;; +esac + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +$as_echo_n "checking for fgrep... " >&6; } +if ${ac_cv_path_FGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 + then ac_cv_path_FGREP="$GREP -F" + else + if test -z "$FGREP"; then + ac_path_FGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in fgrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_FGREP" || continue +# Check for GNU ac_path_FGREP and select it if it is found. + # Check for GNU $ac_path_FGREP +case `"$ac_path_FGREP" --version 2>&1` in +*GNU*) + ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'FGREP' >> "conftest.nl" + "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_FGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_FGREP="$ac_path_FGREP" + ac_path_FGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_FGREP=$FGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +$as_echo "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" + + +test -z "$GREP" && GREP=grep + + + + + + + + + + + + + + + + + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 +$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } +if ${lt_cv_path_NM+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS="$lt_save_ifs" + done + : ${lt_cv_path_NM=no} +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +$as_echo "$lt_cv_path_NM" >&6; } +if test "$lt_cv_path_NM" != "no"; then + NM="$lt_cv_path_NM" +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + if test -n "$ac_tool_prefix"; then + for ac_prog in dumpbin "link -dump" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DUMPBIN"; then + ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DUMPBIN=$ac_cv_prog_DUMPBIN +if test -n "$DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +$as_echo "$DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DUMPBIN" && break + done +fi +if test -z "$DUMPBIN"; then + ac_ct_DUMPBIN=$DUMPBIN + for ac_prog in dumpbin "link -dump" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DUMPBIN"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN +if test -n "$ac_ct_DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +$as_echo "$ac_ct_DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_DUMPBIN" && break +done + + if test "x$ac_ct_DUMPBIN" = x; then + DUMPBIN=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DUMPBIN=$ac_ct_DUMPBIN + fi +fi + + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi + + if test "$DUMPBIN" != ":"; then + NM="$DUMPBIN" + fi +fi +test -z "$NM" && NM=nm + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +$as_echo_n "checking the name lister ($NM) interface... " >&6; } +if ${lt_cv_nm_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: output\"" >&5) + cat conftest.out >&5 + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +$as_echo "$lt_cv_nm_interface" >&6; } + +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if ${lt_cv_sys_max_cmd_len+:} false; then : + $as_echo_n "(cached) " >&6 +else + i=0 + teststring="ABCD" + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8 ; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac + +fi + +if test -n $lt_cv_sys_max_cmd_len ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } +fi +max_cmd_len=$lt_cv_sys_max_cmd_len + + + + + + +: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 +$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } +# Try some XSI features +xsi_shell=no +( _lt_dummy="a/b/c" + test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ + = c,a/b,b/c, \ + && eval 'test $(( 1 + 1 )) -eq 2 \ + && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ + && xsi_shell=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 +$as_echo "$xsi_shell" >&6; } + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 +$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } +lt_shell_append=no +( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ + >/dev/null 2>&1 \ + && lt_shell_append=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 +$as_echo "$lt_shell_append" >&6; } + + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi + + + + + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; } +if ${lt_cv_to_host_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac + +fi + +to_host_file_cmd=$lt_cv_to_host_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +$as_echo "$lt_cv_to_host_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } +if ${lt_cv_to_tool_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + #assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac + +fi + +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +$as_echo "$lt_cv_to_tool_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if ${lt_cv_ld_reload_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; + darwin*) + if test "$GCC" = yes; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi + +test -z "$OBJDUMP" && OBJDUMP=objdump + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if ${lt_cv_deplibs_check_method+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# `unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# which responds to the $file_magic_cmd with a given extended regex. +# If you have `file' or equivalent on your system and you're not sure +# whether `pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[4-9]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. + if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[3-9]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + + + + + + + + + + + + + + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" +fi + +test -z "$DLLTOOL" && DLLTOOL=dlltool + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; } +if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd="$ECHO" + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + + + + + + + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_AR" && break +done + + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi + +: ${AR=ar} +: ${AR_FLAGS=cru} + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +$as_echo_n "checking for archiver @FILE support... " >&6; } +if ${lt_cv_ar_at_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ar_at_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +$as_echo "$lt_cv_ar_at_file" >&6; } + +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +test -z "$STRIP" && STRIP=: + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB + fi +else + RANLIB="$ac_cv_prog_RANLIB" +fi + +test -z "$RANLIB" && RANLIB=: + + + + + + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + +# Check for command to grab the raw symbol name followed by C symbol from nm. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } +if ${lt_cv_sys_global_symbol_pipe+:} false; then : + $as_echo_n "(cached) " >&6 +else + +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[BCDEGRST]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([_A-Za-z][_A-Za-z0-9]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[BCDT]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[ABCDGISTW]' + ;; +hpux*) + if test "$host_cpu" = ia64; then + symcode='[ABCDEGRST]' + fi + ;; +irix* | nonstopux*) + symcode='[BCDEGRST]' + ;; +osf*) + symcode='[BCDEGQRST]' + ;; +solaris*) + symcode='[BDRT]' + ;; +sco3.2v5*) + symcode='[DT]' + ;; +sysv4.2uw2*) + symcode='[DT]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[ABDT]' + ;; +sysv4) + symcode='[DFNSTU]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function + # and D for any global variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK '"\ +" {last_section=section; section=\$ 3};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ +" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ +" s[1]~/^[@?]/{print s[1], s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Now try to grab the symbols. + nlist=conftest.nm + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 + (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&5 + fi + else + echo "cannot find nm_test_var in $nlist" >&5 + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "$progname: failed program was:" >&5 + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done + +fi + +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +$as_echo "failed" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; } +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +$as_echo_n "checking for sysroot... " >&6; } + +# Check whether --with-sysroot was given. +if test "${with_sysroot+set}" = set; then : + withval=$with_sysroot; +else + with_sysroot=no +fi + + +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 +$as_echo "${with_sysroot}" >&6; } + as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 + ;; +esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +$as_echo "${lt_sysroot:-no}" >&6; } + + + + + +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; +fi + +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out which ABI we are using. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_i386" + ;; + ppc64-*linux*|powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + ppc*-*linux*|powerpc*-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if ${lt_cv_cc_needs_belf+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_cc_needs_belf=yes +else + lt_cv_cc_needs_belf=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +sparc*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) LD="${LD-ld} -m elf64_sparc" ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks="$enable_libtool_lock" + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. +set dummy ${ac_tool_prefix}mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$MANIFEST_TOOL"; then + ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL +if test -n "$MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +$as_echo "$MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_MANIFEST_TOOL"; then + ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_MANIFEST_TOOL"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL +if test -n "$ac_ct_MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_MANIFEST_TOOL" = x; then + MANIFEST_TOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL + fi +else + MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" +fi + +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if ${lt_cv_path_mainfest_tool+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&5 + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 +$as_echo "$lt_cv_path_mainfest_tool" >&6; } +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi + + + + + + + case $host_os in + rhapsody* | darwin*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. +set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DSYMUTIL"; then + ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DSYMUTIL"; then + ac_ct_DSYMUTIL=$DSYMUTIL + # Extract the first word of "dsymutil", so it can be a program name with args. +set dummy dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DSYMUTIL"; then + ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL +if test -n "$ac_ct_DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DSYMUTIL" = x; then + DSYMUTIL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DSYMUTIL=$ac_ct_DSYMUTIL + fi +else + DSYMUTIL="$ac_cv_prog_DSYMUTIL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. +set dummy ${ac_tool_prefix}nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NMEDIT"; then + ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +NMEDIT=$ac_cv_prog_NMEDIT +if test -n "$NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_NMEDIT"; then + ac_ct_NMEDIT=$NMEDIT + # Extract the first word of "nmedit", so it can be a program name with args. +set dummy nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_NMEDIT"; then + ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_NMEDIT="nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT +if test -n "$ac_ct_NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 +$as_echo "$ac_ct_NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_NMEDIT" = x; then + NMEDIT=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + NMEDIT=$ac_ct_NMEDIT + fi +else + NMEDIT="$ac_cv_prog_NMEDIT" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. +set dummy ${ac_tool_prefix}lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$LIPO"; then + ac_cv_prog_LIPO="$LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_LIPO="${ac_tool_prefix}lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +LIPO=$ac_cv_prog_LIPO +if test -n "$LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 +$as_echo "$LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_LIPO"; then + ac_ct_LIPO=$LIPO + # Extract the first word of "lipo", so it can be a program name with args. +set dummy lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_LIPO"; then + ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_LIPO="lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO +if test -n "$ac_ct_LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 +$as_echo "$ac_ct_LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_LIPO" = x; then + LIPO=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + LIPO=$ac_ct_LIPO + fi +else + LIPO="$ac_cv_prog_LIPO" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL"; then + ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL="${ac_tool_prefix}otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL=$ac_cv_prog_OTOOL +if test -n "$OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 +$as_echo "$OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL"; then + ac_ct_OTOOL=$OTOOL + # Extract the first word of "otool", so it can be a program name with args. +set dummy otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL"; then + ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL="otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL +if test -n "$ac_ct_OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 +$as_echo "$ac_ct_OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL" = x; then + OTOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL=$ac_ct_OTOOL + fi +else + OTOOL="$ac_cv_prog_OTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL64"; then + ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL64=$ac_cv_prog_OTOOL64 +if test -n "$OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 +$as_echo "$OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL64"; then + ac_ct_OTOOL64=$OTOOL64 + # Extract the first word of "otool64", so it can be a program name with args. +set dummy otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL64"; then + ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL64="otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 +if test -n "$ac_ct_OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 +$as_echo "$ac_ct_OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL64" = x; then + OTOOL64=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL64=$ac_ct_OTOOL64 + fi +else + OTOOL64="$ac_cv_prog_OTOOL64" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 +$as_echo_n "checking for -single_module linker flag... " >&6; } +if ${lt_cv_apple_cc_single_mod+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_apple_cc_single_mod=no + if test -z "${LT_MULTI_MODULE}"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&5 + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 +$as_echo "$lt_cv_apple_cc_single_mod" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 +$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } +if ${lt_cv_ld_exported_symbols_list+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_ld_exported_symbols_list=yes +else + lt_cv_ld_exported_symbols_list=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 +$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +$as_echo_n "checking for -force_load linker flag... " >&6; } +if ${lt_cv_ld_force_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 + echo "$AR cru libconftest.a conftest.o" >&5 + $AR cru libconftest.a conftest.o 2>&5 + echo "$RANLIB libconftest.a" >&5 + $RANLIB libconftest.a 2>&5 + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&5 + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +$as_echo "$lt_cv_ld_force_load" >&6; } + case $host_os in + rhapsody* | darwin1.[012]) + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[91]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[012]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test "$lt_cv_apple_cc_single_mod" = "yes"; then + _lt_dar_single_mod='$single_module' + fi + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + fi + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac + +for ac_header in dlfcn.h +do : + ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +" +if test "x$ac_cv_header_dlfcn_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DLFCN_H 1 +_ACEOF + +fi + +done + + + + + +# Set options + + + + enable_dlopen=no + + + enable_win32_dll=no + + + # Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then : + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_shared=yes +fi + + + + + + + + + + # Check whether --enable-static was given. +if test "${enable_static+set}" = set; then : + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_static=yes +fi + + + + + + + + + + +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then : + withval=$with_pic; pic_mode="$withval" +else + pic_mode=default +fi + + +test -z "$pic_mode" && pic_mode=default + + + + + + + + # Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then : + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_fast_install=yes +fi + + + + + + + + + + + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ltmain" + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' + + + + + + + + + + + + + + + + + + + + + + + + + + +test -z "$LN_S" && LN_S="ln -s" + + + + + + + + + + + + + + +if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if ${lt_cv_objdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir + + + + + +cat >>confdefs.h <<_ACEOF +#define LT_OBJDIR "$lt_cv_objdir/" +_ACEOF + + + + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld="$lt_cv_prog_gnu_ld" + +old_CC="$CC" +old_CFLAGS="$CFLAGS" + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` + + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/${ac_tool_prefix}file; then + lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + + +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/file; then + lt_cv_path_MAGIC_CMD="$ac_dir/file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + else + MAGIC_CMD=: + fi +fi + + fi + ;; +esac + +# Use C for the default configuration in the libtool script + +lt_save_CC="$CC" +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +objext=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + +lt_prog_compiler_no_builtin_flag= + +if test "$GCC" = yes; then + case $cc_basename in + nvcc*) + lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; + *) + lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" +else + : +fi + +fi + + + + + + + lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= + + + if test "$GCC" = yes; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + lt_prog_compiler_pic='-Xcompiler -fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='${wl}-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + # old Intel for x86_64 which still supported -KPIC. + ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='--shared' + lt_prog_compiler_static='--static' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-qpic' + lt_prog_compiler_static='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ F* | *Sun*Fortran*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + esac + ;; + esac + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi + +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +$as_echo "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if ${lt_cv_prog_compiler_pic_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } + +if test x"$lt_cv_prog_compiler_pic_works" = xyes; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi + +fi + + + + + + + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +$as_echo "$lt_cv_prog_compiler_static_works" >&6; } + +if test x"$lt_cv_prog_compiler_static_works" = xyes; then + : +else + lt_prog_compiler_static= +fi + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + runpath_var= + allow_undefined_flag= + always_export_symbols=no + archive_cmds= + archive_expsym_cmds= + compiler_needs_object=no + enable_shared_with_static_runtimes=no + export_dynamic_flag_spec= + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + hardcode_automatic=no + hardcode_direct=no + hardcode_direct_absolute=no + hardcode_libdir_flag_spec= + hardcode_libdir_flag_spec_ld= + hardcode_libdir_separator= + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + inherit_rpath=no + link_all_deplibs=unknown + module_cmds= + module_expsym_cmds= + old_archive_from_new_cmds= + old_archive_from_expsyms_cmds= + thread_safe_flag_spec= + whole_archive_flag_spec= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac + + ld_shlibs=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; + *\ \(GNU\ Binutils\)\ [3-9]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + export_dynamic_flag_spec='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + export_dynamic_flag_spec='${wl}--export-all-symbols' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs=no + fi + ;; + + haiku*) + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs=yes + ;; + + interix[3-9]*) + hardcode_direct=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test "$host_os" = linux-dietlibc; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test "$tmp_diet" = no + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + whole_archive_flag_spec= + tmp_sharedflag='--shared' ;; + xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' + hardcode_libdir_flag_spec= + hardcode_libdir_flag_spec_ld='-rpath $libdir' + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + ld_shlibs=no + fi + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + ;; + + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + + if test "$ld_shlibs" = no; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; + + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds='' + hardcode_direct=yes + hardcode_direct_absolute=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + file_list_spec='${wl}-f,' + + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + export_dynamic_flag_spec='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' ${wl}-bernotok' + allow_undefined_flag=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + fi + archive_cmds_need_lc=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + always_export_symbols=yes + file_list_spec='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, )='true' + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + old_postinstall_cmds='chmod 644 $oldlib' + postlink_cmds='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_from_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' + enable_shared_with_static_runtimes=yes + ;; + esac + ;; + + darwin* | rhapsody*) + + + archive_cmds_need_lc=no + hardcode_direct=no + hardcode_automatic=yes + hardcode_shlibpath_var=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + whole_archive_flag_spec='' + fi + link_all_deplibs=yes + allow_undefined_flag="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + + else + ld_shlibs=no + fi + + ;; + + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + freebsd1*) + ld_shlibs=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + hpux9*) + if test "$GCC" = yes; then + archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='${wl}-E' + ;; + + hpux10*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_flag_spec_ld='+b $libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + fi + ;; + + hpux11*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +$as_echo_n "checking if $CC understands -b... " >&6; } +if ${lt_cv_prog_compiler__b+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler__b=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -b" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler__b=yes + fi + else + lt_cv_prog_compiler__b=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +$as_echo "$lt_cv_prog_compiler__b" >&6; } + +if test x"$lt_cv_prog_compiler__b" = xyes; then + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' +else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' +fi + + ;; + esac + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + *) + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if ${lt_cv_irix_exported_symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int foo (void) { return 0; } +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_irix_exported_symbol=yes +else + lt_cv_irix_exported_symbol=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +$as_echo "$lt_cv_irix_exported_symbol" >&6; } + if test "$lt_cv_irix_exported_symbol" = yes; then + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi + else + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + inherit_rpath=yes + link_all_deplibs=yes + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + newsos6) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + *nto* | *qnx*) + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct=yes + hardcode_shlibpath_var=no + hardcode_direct_absolute=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-R$libdir' + ;; + *) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + ;; + esac + fi + else + ld_shlibs=no + fi + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + archive_cmds_need_lc='no' + hardcode_libdir_separator=: + ;; + + solaris*) + no_undefined_flag=' -z defs' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='${wl}' + archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs=yes + ;; + + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag='${wl}-z,text' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag='${wl}-z,text' + allow_undefined_flag='${wl}-z,nodefs' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-R,$libdir' + hardcode_libdir_separator=':' + link_all_deplibs=yes + export_dynamic_flag_spec='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + *) + ld_shlibs=no + ;; + esac + + if test x$host_vendor = xsni; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + export_dynamic_flag_spec='${wl}-Blargedynsym' + ;; + esac + fi + fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test "$ld_shlibs" = no && can_build_shared=no + +with_gnu_ld=$with_gnu_ld + + + + + + + + + + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + pic_flag=$lt_prog_compiler_pic + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc=no + else + lt_cv_archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } + archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[lt_foo]++; } + if (lt_freq[lt_foo] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([A-Za-z]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd1*) + dynamic_linker=no + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; + +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || + test -n "$runpath_var" || + test "X$hardcode_automatic" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$hardcode_direct" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && + test "$hardcode_minus_L" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test "$hardcode_action" = relink || + test "$inherit_rpath" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if ${ac_cv_lib_dld_shl_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if ${ac_cv_lib_svld_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if ${ac_cv_lib_dld_dld_link+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = xyes; then : + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" +fi + + +fi + + +fi + + +fi + + +fi + + +fi + + ;; + esac + + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } + + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self_static+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi + + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi + + + + + + + + + + + + + + + + + +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + + + + + + + + + + + + + # Report which library types will actually be built + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[4-9]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } + + + + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +CC="$lt_save_CC" + + + + + + + + + + + + + + ac_config_commands="$ac_config_commands libtool" + + + + +# Only expand once: + + + + + + if test "$enable_samples" = "yes"; then + BUILD_SAMPLES_TRUE= + BUILD_SAMPLES_FALSE='#' +else + BUILD_SAMPLES_TRUE='#' + BUILD_SAMPLES_FALSE= +fi + + if test "$enable_libevent_regress" = "yes"; then + BUILD_REGRESS_TRUE= + BUILD_REGRESS_FALSE='#' +else + BUILD_REGRESS_TRUE='#' + BUILD_REGRESS_FALSE= +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntoa" >&5 +$as_echo_n "checking for library containing inet_ntoa... " >&6; } +if ${ac_cv_search_inet_ntoa+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_ntoa (); +int +main () +{ +return inet_ntoa (); + ; + return 0; +} +_ACEOF +for ac_lib in '' nsl; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_ntoa=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inet_ntoa+:} false; then : + break +fi +done +if ${ac_cv_search_inet_ntoa+:} false; then : + +else + ac_cv_search_inet_ntoa=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntoa" >&5 +$as_echo "$ac_cv_search_inet_ntoa" >&6; } +ac_res=$ac_cv_search_inet_ntoa +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5 +$as_echo_n "checking for library containing socket... " >&6; } +if ${ac_cv_search_socket+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char socket (); +int +main () +{ +return socket (); + ; + return 0; +} +_ACEOF +for ac_lib in '' socket; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_socket=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_socket+:} false; then : + break +fi +done +if ${ac_cv_search_socket+:} false; then : + +else + ac_cv_search_socket=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5 +$as_echo "$ac_cv_search_socket" >&6; } +ac_res=$ac_cv_search_socket +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_aton" >&5 +$as_echo_n "checking for library containing inet_aton... " >&6; } +if ${ac_cv_search_inet_aton+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inet_aton (); +int +main () +{ +return inet_aton (); + ; + return 0; +} +_ACEOF +for ac_lib in '' resolv; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inet_aton=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inet_aton+:} false; then : + break +fi +done +if ${ac_cv_search_inet_aton+:} false; then : + +else + ac_cv_search_inet_aton=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_aton" >&5 +$as_echo "$ac_cv_search_inet_aton" >&6; } +ac_res=$ac_cv_search_inet_aton +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 +$as_echo_n "checking for library containing clock_gettime... " >&6; } +if ${ac_cv_search_clock_gettime+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char clock_gettime (); +int +main () +{ +return clock_gettime (); + ; + return 0; +} +_ACEOF +for ac_lib in '' rt; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_clock_gettime=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_clock_gettime+:} false; then : + break +fi +done +if ${ac_cv_search_clock_gettime+:} false; then : + +else + ac_cv_search_clock_gettime=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 +$as_echo "$ac_cv_search_clock_gettime" >&6; } +ac_res=$ac_cv_search_clock_gettime +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sendfile" >&5 +$as_echo_n "checking for library containing sendfile... " >&6; } +if ${ac_cv_search_sendfile+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char sendfile (); +int +main () +{ +return sendfile (); + ; + return 0; +} +_ACEOF +for ac_lib in '' sendfile; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_sendfile=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_sendfile+:} false; then : + break +fi +done +if ${ac_cv_search_sendfile+:} false; then : + +else + ac_cv_search_sendfile=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sendfile" >&5 +$as_echo "$ac_cv_search_sendfile" >&6; } +ac_res=$ac_cv_search_sendfile +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for WIN32" >&5 +$as_echo_n "checking for WIN32... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#ifndef _WIN32 +die horribly +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + bwin32=true; { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + bwin32=false; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGWIN" >&5 +$as_echo_n "checking for CYGWIN... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#ifndef __CYGWIN__ +die horribly +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cygwin=true; { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + cygwin=false; { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +for ac_header in zlib.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default" +if test "x$ac_cv_header_zlib_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ZLIB_H 1 +_ACEOF + +fi + +done + + +if test "x$ac_cv_header_zlib_h" = "xyes"; then +save_LIBS="$LIBS" +LIBS="" +ZLIB_LIBS="" +have_zlib=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inflateEnd" >&5 +$as_echo_n "checking for library containing inflateEnd... " >&6; } +if ${ac_cv_search_inflateEnd+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char inflateEnd (); +int +main () +{ +return inflateEnd (); + ; + return 0; +} +_ACEOF +for ac_lib in '' z; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_inflateEnd=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inflateEnd+:} false; then : + break +fi +done +if ${ac_cv_search_inflateEnd+:} false; then : + +else + ac_cv_search_inflateEnd=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inflateEnd" >&5 +$as_echo "$ac_cv_search_inflateEnd" >&6; } +ac_res=$ac_cv_search_inflateEnd +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + have_zlib=yes + ZLIB_LIBS="$LIBS" + +$as_echo "#define HAVE_LIBZ 1" >>confdefs.h + +fi + +LIBS="$save_LIBS" + +fi + if test "$have_zlib" = "yes"; then + ZLIB_REGRESS_TRUE= + ZLIB_REGRESS_FALSE='#' +else + ZLIB_REGRESS_TRUE='#' + ZLIB_REGRESS_FALSE= +fi + + +if test "$bwin32" = true; then + EV_LIB_WS32=-lws2_32 + EV_LIB_GDI=-lgdi32 +else + EV_LIB_WS32= + EV_LIB_GDI= +fi + + + + +# Check whether --enable-largefile was given. +if test "${enable_largefile+set}" = set; then : + enableval=$enable_largefile; +fi + +if test "$enable_largefile" != no; then + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 +$as_echo_n "checking for special C compiler options needed for large files... " >&6; } +if ${ac_cv_sys_largefile_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_sys_largefile_CC=no + if test "$GCC" != yes; then + ac_save_CC=$CC + while :; do + # IRIX 6.2 and later do not support large files by default, + # so use the C compiler's -n32 option if that helps. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + /* Check that off_t can represent 2**63 - 1 correctly. + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +int +main () +{ + + ; + return 0; +} +_ACEOF + if ac_fn_c_try_compile "$LINENO"; then : + break +fi +rm -f core conftest.err conftest.$ac_objext + CC="$CC -n32" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_sys_largefile_CC=' -n32'; break +fi +rm -f core conftest.err conftest.$ac_objext + break + done + CC=$ac_save_CC + rm -f conftest.$ac_ext + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 +$as_echo "$ac_cv_sys_largefile_CC" >&6; } + if test "$ac_cv_sys_largefile_CC" != no; then + CC=$CC$ac_cv_sys_largefile_CC + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 +$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } +if ${ac_cv_sys_file_offset_bits+:} false; then : + $as_echo_n "(cached) " >&6 +else + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + /* Check that off_t can represent 2**63 - 1 correctly. + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_sys_file_offset_bits=no; break +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#define _FILE_OFFSET_BITS 64 +#include + /* Check that off_t can represent 2**63 - 1 correctly. + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_sys_file_offset_bits=64; break +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cv_sys_file_offset_bits=unknown + break +done +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 +$as_echo "$ac_cv_sys_file_offset_bits" >&6; } +case $ac_cv_sys_file_offset_bits in #( + no | unknown) ;; + *) +cat >>confdefs.h <<_ACEOF +#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits +_ACEOF +;; +esac +rm -rf conftest* + if test $ac_cv_sys_file_offset_bits = unknown; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 +$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } +if ${ac_cv_sys_large_files+:} false; then : + $as_echo_n "(cached) " >&6 +else + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + /* Check that off_t can represent 2**63 - 1 correctly. + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_sys_large_files=no; break +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#define _LARGE_FILES 1 +#include + /* Check that off_t can represent 2**63 - 1 correctly. + We can't simply define LARGE_OFF_T to be 9223372036854775807, + since some C++ compilers masquerading as C compilers + incorrectly reject 9223372036854775807. */ +#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) + int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 + && LARGE_OFF_T % 2147483647 == 1) + ? 1 : -1]; +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_sys_large_files=1; break +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cv_sys_large_files=unknown + break +done +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 +$as_echo "$ac_cv_sys_large_files" >&6; } +case $ac_cv_sys_large_files in #( + no | unknown) ;; + *) +cat >>confdefs.h <<_ACEOF +#define _LARGE_FILES $ac_cv_sys_large_files +_ACEOF +;; +esac +rm -rf conftest* + fi + + +fi + + + + +ntp_pkgconfig_min_version='0.15.0' +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PKG_CONFIG=$ac_cv_path_PKG_CONFIG +if test -n "$PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 +$as_echo "$PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_path_PKG_CONFIG"; then + ac_pt_PKG_CONFIG=$PKG_CONFIG + # Extract the first word of "pkg-config", so it can be a program name with args. +set dummy pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG +if test -n "$ac_pt_PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 +$as_echo "$ac_pt_PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_PKG_CONFIG" = x; then + PKG_CONFIG="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + PKG_CONFIG=$ac_pt_PKG_CONFIG + fi +else + PKG_CONFIG="$ac_cv_path_PKG_CONFIG" +fi + +{ ac_cv_path_PKG_CONFIG=; unset ac_cv_path_PKG_CONFIG;} +{ ac_cv_path_ac_pt_PKG_CONFIG=; unset ac_cv_path_ac_pt_PKG_CONFIG;} + +case "$PKG_CONFIG" in + /*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pkg-config is at least version $ntp_pkgconfig_min_version" >&5 +$as_echo_n "checking if pkg-config is at least version $ntp_pkgconfig_min_version... " >&6; } + if $PKG_CONFIG --atleast-pkgconfig-version $ntp_pkgconfig_min_version; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + PKG_CONFIG="" + fi + ;; +esac + + + + +case "$enable_openssl" in + yes) + have_openssl=no + case "$PKG_CONFIG" in + '') + ;; + *) + OPENSSL_LIBS=`$PKG_CONFIG --libs openssl 2>/dev/null` + case "$OPENSSL_LIBS" in + '') ;; + *) OPENSSL_LIBS="$OPENSSL_LIBS $EV_LIB_GDI $EV_LIB_WS32 $OPENSSL_LIBADD" + have_openssl=yes + ;; + esac + OPENSSL_INCS=`$PKG_CONFIG --cflags openssl 2>/dev/null` + ;; + esac + case "$have_openssl" in + yes) ;; + *) + save_LIBS="$LIBS" + LIBS="" + OPENSSL_LIBS="" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing SSL_new" >&5 +$as_echo_n "checking for library containing SSL_new... " >&6; } +if ${ac_cv_search_SSL_new+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char SSL_new (); +int +main () +{ +return SSL_new (); + ; + return 0; +} +_ACEOF +for ac_lib in '' ssl; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib -lcrypto $EV_LIB_GDI $EV_LIB_WS32 $OPENSSL_LIBADD $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_SSL_new=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_SSL_new+:} false; then : + break +fi +done +if ${ac_cv_search_SSL_new+:} false; then : + +else + ac_cv_search_SSL_new=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_SSL_new" >&5 +$as_echo "$ac_cv_search_SSL_new" >&6; } +ac_res=$ac_cv_search_SSL_new +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + have_openssl=yes + OPENSSL_LIBS="$LIBS -lcrypto $EV_LIB_GDI $EV_LIB_WS32 $OPENSSL_LIBADD" +else + have_openssl=no +fi + + LIBS="$save_LIBS" + ;; + esac + + + case "$have_openssl" in + yes) +$as_echo "#define HAVE_OPENSSL 1" >>confdefs.h + ;; + esac + ;; +esac + +# check if we have and should use openssl + if test "$enable_openssl" != "no" && test "$have_openssl" = "yes"; then + OPENSSL_TRUE= + OPENSSL_FALSE='#' +else + OPENSSL_TRUE='#' + OPENSSL_FALSE= +fi + + + +for ac_header in \ + arpa/inet.h \ + fcntl.h \ + ifaddrs.h \ + mach/mach_time.h \ + netdb.h \ + netinet/in.h \ + netinet/in6.h \ + netinet/tcp.h \ + poll.h \ + port.h \ + stdarg.h \ + stddef.h \ + sys/devpoll.h \ + sys/epoll.h \ + sys/event.h \ + sys/eventfd.h \ + sys/ioctl.h \ + sys/mman.h \ + sys/param.h \ + sys/queue.h \ + sys/resource.h \ + sys/select.h \ + sys/sendfile.h \ + sys/socket.h \ + sys/stat.h \ + sys/time.h \ + sys/timerfd.h \ + sys/uio.h \ + sys/wait.h \ + +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +for ac_header in sys/sysctl.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" " +#ifdef HAVE_SYS_PARAM_H +#include +#endif + +" +if test "x$ac_cv_header_sys_sysctl_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_SYSCTL_H 1 +_ACEOF + +fi + +done + +if test "x$ac_cv_header_sys_queue_h" = "xyes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAILQ_FOREACH in sys/queue.h" >&5 +$as_echo_n "checking for TAILQ_FOREACH in sys/queue.h... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include +#ifdef TAILQ_FOREACH + yes +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "yes" >/dev/null 2>&1; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +$as_echo "#define HAVE_TAILQFOREACH 1" >>confdefs.h + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +fi +rm -f conftest* + +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timeradd in sys/time.h" >&5 +$as_echo_n "checking for timeradd in sys/time.h... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include +#ifdef timeradd + yes +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "yes" >/dev/null 2>&1; then : + +$as_echo "#define HAVE_TIMERADD 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +fi +rm -f conftest* + +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timercmp in sys/time.h" >&5 +$as_echo_n "checking for timercmp in sys/time.h... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include +#ifdef timercmp + yes +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "yes" >/dev/null 2>&1; then : + +$as_echo "#define HAVE_TIMERCMP 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +fi +rm -f conftest* + +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timerclear in sys/time.h" >&5 +$as_echo_n "checking for timerclear in sys/time.h... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include +#ifdef timerclear + yes +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "yes" >/dev/null 2>&1; then : + +$as_echo "#define HAVE_TIMERCLEAR 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +fi +rm -f conftest* + +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timerisset in sys/time.h" >&5 +$as_echo_n "checking for timerisset in sys/time.h... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include +#ifdef timerisset + yes +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "yes" >/dev/null 2>&1; then : + +$as_echo "#define HAVE_TIMERISSET 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +fi +rm -f conftest* + +fi + +if test "x$ac_cv_header_sys_sysctl_h" = "xyes"; then + ac_fn_c_check_decl "$LINENO" "CTL_KERN" "ac_cv_have_decl_CTL_KERN" "#include + #include + +" +if test "x$ac_cv_have_decl_CTL_KERN" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi + +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_CTL_KERN $ac_have_decl +_ACEOF +ac_fn_c_check_decl "$LINENO" "KERN_RANDOM" "ac_cv_have_decl_KERN_RANDOM" "#include + #include + +" +if test "x$ac_cv_have_decl_KERN_RANDOM" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi + +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_KERN_RANDOM $ac_have_decl +_ACEOF +ac_fn_c_check_decl "$LINENO" "RANDOM_UUID" "ac_cv_have_decl_RANDOM_UUID" "#include + #include + +" +if test "x$ac_cv_have_decl_RANDOM_UUID" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi + +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_RANDOM_UUID $ac_have_decl +_ACEOF +ac_fn_c_check_decl "$LINENO" "KERN_ARND" "ac_cv_have_decl_KERN_ARND" "#include + #include + +" +if test "x$ac_cv_have_decl_KERN_ARND" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi + +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_KERN_ARND $ac_have_decl +_ACEOF + +fi + + if test x$bwin32 = xtrue; then + BUILD_WIN32_TRUE= + BUILD_WIN32_FALSE='#' +else + BUILD_WIN32_TRUE='#' + BUILD_WIN32_FALSE= +fi + + if test x$cygwin = xtrue; then + BUILD_CYGWIN_TRUE= + BUILD_CYGWIN_FALSE='#' +else + BUILD_CYGWIN_TRUE='#' + BUILD_CYGWIN_FALSE= +fi + + if test x$bwin32 = xtrue || test x$cygwin = xtrue; then + BUILD_WITH_NO_UNDEFINED_TRUE= + BUILD_WITH_NO_UNDEFINED_FALSE='#' +else + BUILD_WITH_NO_UNDEFINED_TRUE='#' + BUILD_WITH_NO_UNDEFINED_FALSE= +fi + + +if test x$bwin32 = xtrue; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getservbyname" >&5 +$as_echo_n "checking for library containing getservbyname... " >&6; } +if ${ac_cv_search_getservbyname+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char getservbyname (); +int +main () +{ +return getservbyname (); + ; + return 0; +} +_ACEOF +for ac_lib in '' ws2_32; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_getservbyname=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_getservbyname+:} false; then : + break +fi +done +if ${ac_cv_search_getservbyname+:} false; then : + +else + ac_cv_search_getservbyname=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getservbyname" >&5 +$as_echo "$ac_cv_search_getservbyname" >&6; } +ac_res=$ac_cv_search_getservbyname +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 +$as_echo_n "checking for an ANSI C-conforming const... " >&6; } +if ${ac_cv_c_const+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#ifndef __cplusplus + /* Ultrix mips cc rejects this sort of thing. */ + typedef int charset[2]; + const charset cs = { 0, 0 }; + /* SunOS 4.1.1 cc rejects this. */ + char const *const *pcpcc; + char **ppc; + /* NEC SVR4.0.2 mips cc rejects this. */ + struct point {int x, y;}; + static struct point const zero = {0,0}; + /* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in + an arm of an if-expression whose if-part is not a constant + expression */ + const char *g = "string"; + pcpcc = &g + (g ? g-g : 0); + /* HPUX 7.0 cc rejects these. */ + ++pcpcc; + ppc = (char**) pcpcc; + pcpcc = (char const *const *) ppc; + { /* SCO 3.2v4 cc rejects this sort of thing. */ + char tx; + char *t = &tx; + char const *s = 0 ? (char *) 0 : (char const *) 0; + + *t++ = 0; + if (s) return 0; + } + { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; + } + { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; + } + { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; } bx; + struct s *b = &bx; b->j = 5; + } + { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; + if (!foo) return 0; + } + return !cs[0] && !zero.x; +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_const=yes +else + ac_cv_c_const=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 +$as_echo "$ac_cv_c_const" >&6; } +if test $ac_cv_c_const = no; then + +$as_echo "#define const /**/" >>confdefs.h + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +$as_echo_n "checking for inline... " >&6; } +if ${ac_cv_c_inline+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __cplusplus +typedef int foo_t; +static $ac_kw foo_t static_foo () {return 0; } +$ac_kw foo_t foo () {return 0; } +#endif + +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_inline=$ac_kw +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test "$ac_cv_c_inline" != no && break +done + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +$as_echo "$ac_cv_c_inline" >&6; } + +case $ac_cv_c_inline in + inline | yes) ;; + *) + case $ac_cv_c_inline in + no) ac_val=;; + *) ac_val=$ac_cv_c_inline;; + esac + cat >>confdefs.h <<_ACEOF +#ifndef __cplusplus +#define inline $ac_val +#endif +_ACEOF + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 +$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } +if ${ac_cv_header_time+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include + +int +main () +{ +if ((struct tm *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_time=yes +else + ac_cv_header_time=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 +$as_echo "$ac_cv_header_time" >&6; } +if test $ac_cv_header_time = yes; then + +$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h + +fi + + +for ac_func in \ + accept4 \ + arc4random \ + arc4random_buf \ + clock_gettime \ + eventfd \ + epoll_create1 \ + fcntl \ + getegid \ + geteuid \ + getifaddrs \ + getnameinfo \ + getprotobynumber \ + gettimeofday \ + inet_ntop \ + inet_pton \ + issetugid \ + mach_absolute_time \ + mmap \ + nanosleep \ + pipe \ + pipe2 \ + putenv \ + sendfile \ + setenv \ + setrlimit \ + sigaction \ + signal \ + splice \ + strlcpy \ + strsep \ + strtok_r \ + strtoll \ + sysctl \ + timerfd_create \ + umask \ + unsetenv \ + usleep \ + vasprintf \ + +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + + if test x"$ac_cv_func_strlcpy" = xno; then + STRLCPY_IMPL_TRUE= + STRLCPY_IMPL_FALSE='#' +else + STRLCPY_IMPL_TRUE='#' + STRLCPY_IMPL_FALSE= +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 +$as_echo_n "checking for getaddrinfo... " >&6; } +if ${libevent_cv_getaddrinfo+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef HAVE_NETDB_H + #include + #endif + +int +main () +{ + + getaddrinfo; + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + libevent_cv_getaddrinfo=yes +else + libevent_cv_getaddrinfo=no + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libevent_cv_getaddrinfo" >&5 +$as_echo "$libevent_cv_getaddrinfo" >&6; } +if test "$libevent_cv_getaddrinfo" = "yes" ; then + +$as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h + +else + +for ac_func in getservbyname +do : + ac_fn_c_check_func "$LINENO" "getservbyname" "ac_cv_func_getservbyname" +if test "x$ac_cv_func_getservbyname" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_GETSERVBYNAME 1 +_ACEOF + +fi +done + +# Check for gethostbyname_r in all its glorious incompatible versions. +# (This is cut-and-pasted from Tor, which based its logic on +# Python's configure.in.) + + +ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r" +if test "x$ac_cv_func_gethostbyname_r" = xyes; then : + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how many arguments gethostbyname_r() wants" >&5 +$as_echo_n "checking how many arguments gethostbyname_r() wants... " >&6; } + OLD_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include + +int +main () +{ + + char *cp1, *cp2; + struct hostent *h1, *h2; + int i1, i2; + (void)gethostbyname_r(cp1,h1,cp2,i1,&h2,&i2); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + + $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h + + +$as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6" >&5 +$as_echo "6" >&6; } + +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include + +int +main () +{ + + char *cp1, *cp2; + struct hostent *h1; + int i1, i2; + (void)gethostbyname_r(cp1,h1,cp2,i1,&i2); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + + $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h + + +$as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: 5" >&5 +$as_echo "5" >&6; } + +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#include + +int +main () +{ + + char *cp1; + struct hostent *h1; + struct hostent_data hd; + (void) gethostbyname_r(cp1,h1,&hd); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + + $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h + + +$as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: 3" >&5 +$as_echo "3" >&6; } + +else + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: 0" >&5 +$as_echo "0" >&6; } + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + CFLAGS=$OLD_CFLAGS + +fi + + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for F_SETFD in fcntl.h" >&5 +$as_echo_n "checking for F_SETFD in fcntl.h... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#define _GNU_SOURCE +#include +#ifdef F_SETFD +yes +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "yes" >/dev/null 2>&1; then : + +$as_echo "#define HAVE_SETFD 1" >>confdefs.h + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +rm -f conftest* + + +needsignal=no +haveselect=no +if test x$bwin32 != xtrue; then + for ac_func in select +do : + ac_fn_c_check_func "$LINENO" "select" "ac_cv_func_select" +if test "x$ac_cv_func_select" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SELECT 1 +_ACEOF + haveselect=yes +fi +done + + if test "x$haveselect" = "xyes" ; then + needsignal=yes + fi +fi + if test "x$haveselect" = "xyes"; then + SELECT_BACKEND_TRUE= + SELECT_BACKEND_FALSE='#' +else + SELECT_BACKEND_TRUE='#' + SELECT_BACKEND_FALSE= +fi + + +havepoll=no +for ac_func in poll +do : + ac_fn_c_check_func "$LINENO" "poll" "ac_cv_func_poll" +if test "x$ac_cv_func_poll" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_POLL 1 +_ACEOF + havepoll=yes +fi +done + +if test "x$havepoll" = "xyes" ; then + needsignal=yes +fi + if test "x$havepoll" = "xyes"; then + POLL_BACKEND_TRUE= + POLL_BACKEND_FALSE='#' +else + POLL_BACKEND_TRUE='#' + POLL_BACKEND_FALSE= +fi + + +havedevpoll=no +if test "x$ac_cv_header_sys_devpoll_h" = "xyes"; then + +$as_echo "#define HAVE_DEVPOLL 1" >>confdefs.h + +fi + if test "x$ac_cv_header_sys_devpoll_h" = "xyes"; then + DEVPOLL_BACKEND_TRUE= + DEVPOLL_BACKEND_FALSE='#' +else + DEVPOLL_BACKEND_TRUE='#' + DEVPOLL_BACKEND_FALSE= +fi + + +havekqueue=no +if test "x$ac_cv_header_sys_event_h" = "xyes"; then + for ac_func in kqueue +do : + ac_fn_c_check_func "$LINENO" "kqueue" "ac_cv_func_kqueue" +if test "x$ac_cv_func_kqueue" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_KQUEUE 1 +_ACEOF + havekqueue=yes +fi +done + + if test "x$havekqueue" = "xyes" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working kqueue" >&5 +$as_echo_n "checking for working kqueue... " >&6; } + if test "$cross_compiling" = yes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include +#include +#include + +int +main(int argc, char **argv) +{ + int kq; + int n; + int fd[2]; + struct kevent ev; + struct timespec ts; + char buf[8000]; + + if (pipe(fd) == -1) + exit(1); + if (fcntl(fd[1], F_SETFL, O_NONBLOCK) == -1) + exit(1); + + while ((n = write(fd[1], buf, sizeof(buf))) == sizeof(buf)) + ; + + if ((kq = kqueue()) == -1) + exit(1); + + memset(&ev, 0, sizeof(ev)); + ev.ident = fd[1]; + ev.filter = EVFILT_WRITE; + ev.flags = EV_ADD | EV_ENABLE; + n = kevent(kq, &ev, 1, NULL, 0, NULL); + if (n == -1) + exit(1); + + read(fd[0], buf, sizeof(buf)); + + ts.tv_sec = 0; + ts.tv_nsec = 0; + n = kevent(kq, NULL, 0, &ev, 1, &ts); + if (n == -1 || n == 0) + exit(1); + + exit(0); +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +$as_echo "#define HAVE_WORKING_KQUEUE 1" >>confdefs.h + + havekqueue=yes + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + fi +fi + if test "x$havekqueue" = "xyes"; then + KQUEUE_BACKEND_TRUE= + KQUEUE_BACKEND_FALSE='#' +else + KQUEUE_BACKEND_TRUE='#' + KQUEUE_BACKEND_FALSE= +fi + + +haveepollsyscall=no +haveepoll=no +for ac_func in epoll_ctl +do : + ac_fn_c_check_func "$LINENO" "epoll_ctl" "ac_cv_func_epoll_ctl" +if test "x$ac_cv_func_epoll_ctl" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_EPOLL_CTL 1 +_ACEOF + haveepoll=yes +fi +done + +if test "x$haveepoll" = "xyes" ; then + +$as_echo "#define HAVE_EPOLL 1" >>confdefs.h + + needsignal=yes +fi +if test "x$ac_cv_header_sys_epoll_h" = "xyes"; then + if test "x$haveepoll" = "xno" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll system call" >&5 +$as_echo_n "checking for epoll system call... " >&6; } + if test "$cross_compiling" = yes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include +#include +#include + +int +epoll_create(int size) +{ + return (syscall(__NR_epoll_create, size)); +} + +int +main(int argc, char **argv) +{ + int epfd; + + epfd = epoll_create(256); + exit (epfd == -1 ? 1 : 0); +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +$as_echo "#define HAVE_EPOLL 1" >>confdefs.h + + needsignal=yes + have_epoll=yes + case " $LIBOBJS " in + *" epoll_sub.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS epoll_sub.$ac_objext" + ;; +esac + + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + fi +fi + if test "x$haveepoll" = "xyes"; then + EPOLL_BACKEND_TRUE= + EPOLL_BACKEND_FALSE='#' +else + EPOLL_BACKEND_TRUE='#' + EPOLL_BACKEND_FALSE= +fi + + +haveeventports=no +for ac_func in port_create +do : + ac_fn_c_check_func "$LINENO" "port_create" "ac_cv_func_port_create" +if test "x$ac_cv_func_port_create" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_PORT_CREATE 1 +_ACEOF + haveeventports=yes +fi +done + +if test "x$haveeventports" = "xyes" ; then + +$as_echo "#define HAVE_EVENT_PORTS 1" >>confdefs.h + + needsignal=yes +fi + if test "x$haveeventports" = "xyes"; then + EVPORT_BACKEND_TRUE= + EVPORT_BACKEND_FALSE='#' +else + EVPORT_BACKEND_TRUE='#' + EVPORT_BACKEND_FALSE= +fi + + +if test "x$bwin32" = "xtrue"; then + needsignal=yes +fi + + if test "x$needsignal" = "xyes"; then + SIGNAL_SUPPORT_TRUE= + SIGNAL_SUPPORT_FALSE='#' +else + SIGNAL_SUPPORT_TRUE='#' + SIGNAL_SUPPORT_FALSE= +fi + + +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define pid_t int +_ACEOF + +fi + +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + +fi + +ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" +if test "x$ac_cv_type_ssize_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define ssize_t int +_ACEOF + +fi + + +ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "#ifdef HAVE_STDINT_H +#include +#elif defined(HAVE_INTTYPES_H) +#include +#endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif +" +if test "x$ac_cv_type_uint64_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT64_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "#ifdef HAVE_STDINT_H +#include +#elif defined(HAVE_INTTYPES_H) +#include +#endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif +" +if test "x$ac_cv_type_uint32_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT32_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "#ifdef HAVE_STDINT_H +#include +#elif defined(HAVE_INTTYPES_H) +#include +#endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif +" +if test "x$ac_cv_type_uint16_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT16_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "#ifdef HAVE_STDINT_H +#include +#elif defined(HAVE_INTTYPES_H) +#include +#endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif +" +if test "x$ac_cv_type_uint8_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINT8_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "#ifdef HAVE_STDINT_H +#include +#elif defined(HAVE_INTTYPES_H) +#include +#endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif +" +if test "x$ac_cv_type_uintptr_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_UINTPTR_T 1 +_ACEOF + + +fi + + +ac_fn_c_check_type "$LINENO" "fd_mask" "ac_cv_type_fd_mask" "#ifdef HAVE_SYS_TYPES_H +#include +#endif +#ifdef HAVE_SYS_SELECT_H +#include +#endif +" +if test "x$ac_cv_type_fd_mask" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_FD_MASK 1 +_ACEOF + + +fi + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 +$as_echo_n "checking size of long long... " >&6; } +if ${ac_cv_sizeof_long_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 +$as_echo "$ac_cv_sizeof_long_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if ${ac_cv_sizeof_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if ${ac_cv_sizeof_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (int) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_int=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 +$as_echo_n "checking size of short... " >&6; } +if ${ac_cv_sizeof_short+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_short" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (short) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_short=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 +$as_echo "$ac_cv_sizeof_short" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 +$as_echo_n "checking size of size_t... " >&6; } +if ${ac_cv_sizeof_size_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_size_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (size_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_size_t=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 +$as_echo "$ac_cv_sizeof_size_t" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 +$as_echo_n "checking size of void *... " >&6; } +if ${ac_cv_sizeof_void_p+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_void_p" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (void *) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_void_p=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 +$as_echo "$ac_cv_sizeof_void_p" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_VOID_P $ac_cv_sizeof_void_p +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 +$as_echo_n "checking size of off_t... " >&6; } +if ${ac_cv_sizeof_off_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_off_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (off_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_off_t=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 +$as_echo "$ac_cv_sizeof_off_t" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_OFF_T $ac_cv_sizeof_off_t +_ACEOF + + + +ac_fn_c_check_type "$LINENO" "struct in6_addr" "ac_cv_type_struct_in6_addr" "#define _GNU_SOURCE +#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETDB_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_type_struct_in6_addr" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_IN6_ADDR 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "struct sockaddr_in6" "ac_cv_type_struct_sockaddr_in6" "#define _GNU_SOURCE +#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETDB_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_type_struct_sockaddr_in6" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_IN6 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" "#define _GNU_SOURCE +#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETDB_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_type_sa_family_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SA_FAMILY_T 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "struct addrinfo" "ac_cv_type_struct_addrinfo" "#define _GNU_SOURCE +#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETDB_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_type_struct_addrinfo" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_ADDRINFO 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "#define _GNU_SOURCE +#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETDB_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_STORAGE 1 +_ACEOF + + +fi + +ac_fn_c_check_member "$LINENO" "struct in6_addr" "s6_addr32" "ac_cv_member_struct_in6_addr_s6_addr32" "#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_member_struct_in6_addr_s6_addr32" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_IN6_ADDR_S6_ADDR32 1 +_ACEOF + + +fi +ac_fn_c_check_member "$LINENO" "struct in6_addr" "s6_addr16" "ac_cv_member_struct_in6_addr_s6_addr16" "#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_member_struct_in6_addr_s6_addr16" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_IN6_ADDR_S6_ADDR16 1 +_ACEOF + + +fi +ac_fn_c_check_member "$LINENO" "struct sockaddr_in" "sin_len" "ac_cv_member_struct_sockaddr_in_sin_len" "#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_member_struct_sockaddr_in_sin_len" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_IN_SIN_LEN 1 +_ACEOF + + +fi +ac_fn_c_check_member "$LINENO" "struct sockaddr_in6" "sin6_len" "ac_cv_member_struct_sockaddr_in6_sin6_len" "#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_member_struct_sockaddr_in6_sin6_len" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_IN6_SIN6_LEN 1 +_ACEOF + + +fi +ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_family" "ac_cv_member_struct_sockaddr_storage_ss_family" "#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1 +_ACEOF + + +fi +ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "__ss_family" "ac_cv_member_struct_sockaddr_storage___ss_family" "#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif + +" +if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1 +_ACEOF + + +fi + + +ac_fn_c_check_type "$LINENO" "struct so_linger" "ac_cv_type_struct_so_linger" " +#ifdef HAVE_SYS_SOCKET_H +#include +#endif + +" +if test "x$ac_cv_type_struct_so_linger" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SO_LINGER 1 +_ACEOF + +#define HAVE_SO_LINGER +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5 +$as_echo_n "checking for socklen_t... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include +int +main () +{ +socklen_t x; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +$as_echo "#define socklen_t unsigned int" >>confdefs.h + + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether our compiler supports __func__" >&5 +$as_echo_n "checking whether our compiler supports __func__... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + const char *cp = __func__; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether our compiler supports __FUNCTION__" >&5 +$as_echo_n "checking whether our compiler supports __FUNCTION__... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + const char *cp = __FUNCTION__; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +$as_echo "#define __func__ __FUNCTION__" >>confdefs.h + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +$as_echo "#define __func__ __FILE__" >>confdefs.h + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + +# check if we can compile with pthreads +have_pthreads=no +if test x$bwin32 != xtrue && test "$enable_thread_support" != "no"; then + + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +acx_pthread_ok=no + +# We used to check for pthread.h first, but this fails if pthread.h +# requires special compiler flags (e.g. on True64 or Sequent). +# It gets checked for in the link test anyway. + +# First of all, check if the user has set any of the PTHREAD_LIBS, +# etcetera environment variables, and if threads linking works using +# them: +if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then + save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + save_LIBS="$LIBS" + LIBS="$PTHREAD_LIBS $LIBS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5 +$as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pthread_join (); +int +main () +{ +return pthread_join (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + acx_pthread_ok=yes +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5 +$as_echo "$acx_pthread_ok" >&6; } + if test x"$acx_pthread_ok" = xno; then + PTHREAD_LIBS="" + PTHREAD_CFLAGS="" + fi + LIBS="$save_LIBS" + CFLAGS="$save_CFLAGS" +fi + +# We must check for the threads library under a number of different +# names; the ordering is very important because some systems +# (e.g. DEC) have both -lpthread and -lpthreads, where one of the +# libraries is broken (non-POSIX). + +# Create a list of thread flags to try. Items starting with a "-" are +# C compiler flags, and other items are library names, except for "none" +# which indicates that we try without any flags at all, and "pthread-config" +# which is a program returning the flags for the Pth emulation library. + +acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config" + +# The ordering *is* (sometimes) important. Some notes on the +# individual items follow: + +# pthreads: AIX (must check this before -lpthread) +# none: in case threads are in libc; should be tried before -Kthread and +# other compiler flags to prevent continual compiler warnings +# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h) +# -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able) +# lthread: LinuxThreads port on FreeBSD (also preferred to -pthread) +# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads) +# -pthreads: Solaris/gcc +# -mthreads: Mingw32/gcc, Lynx/gcc +# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it +# doesn't hurt to check since this sometimes defines pthreads too; +# also defines -D_REENTRANT) +# ... -mt is also the pthreads flag for HP/aCC +# pthread: Linux, etcetera +# --thread-safe: KAI C++ +# pthread-config: use pthread-config program (for GNU Pth library) + +case "${host_cpu}-${host_os}" in + *solaris*) + + # On Solaris (at least, for some versions), libc contains stubbed + # (non-functional) versions of the pthreads routines, so link-based + # tests will erroneously succeed. (We need to link with -pthreads/-mt/ + # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather + # a function called by this macro, so we could check for that, but + # who knows whether they'll stub that too in a future libc.) So, + # we'll just look for -pthreads and -lpthread first: + + acx_pthread_flags="-pthreads pthread -mt -pthread $acx_pthread_flags" + ;; +esac + +if test x"$acx_pthread_ok" = xno; then +for flag in $acx_pthread_flags; do + + case $flag in + none) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5 +$as_echo_n "checking whether pthreads work without any flags... " >&6; } + ;; + + -*) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5 +$as_echo_n "checking whether pthreads work with $flag... " >&6; } + PTHREAD_CFLAGS="$flag" + ;; + + pthread-config) + # Extract the first word of "pthread-config", so it can be a program name with args. +set dummy pthread-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_acx_pthread_config+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$acx_pthread_config"; then + ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_acx_pthread_config="yes" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no" +fi +fi +acx_pthread_config=$ac_cv_prog_acx_pthread_config +if test -n "$acx_pthread_config"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_config" >&5 +$as_echo "$acx_pthread_config" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + if test x"$acx_pthread_config" = xno; then continue; fi + PTHREAD_CFLAGS="`pthread-config --cflags`" + PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`" + ;; + + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5 +$as_echo_n "checking for the pthreads library -l$flag... " >&6; } + PTHREAD_LIBS="-l$flag" + ;; + esac + + save_LIBS="$LIBS" + save_CFLAGS="$CFLAGS" + LIBS="$PTHREAD_LIBS $LIBS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + + # Check for various functions. We must include pthread.h, + # since some functions may be macros. (On the Sequent, we + # need a special flag -Kthread to make this header compile.) + # We check for pthread_join because it is in -lpthread on IRIX + # while pthread_create is in libc. We check for pthread_attr_init + # due to DEC craziness with -lpthreads. We check for + # pthread_cleanup_push because it is one of the few pthread + # functions on Solaris that doesn't have a non-functional libc stub. + # We try pthread_create on general principles. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +pthread_t th; pthread_join(th, 0); + pthread_attr_init(0); pthread_cleanup_push(0, 0); + pthread_create(0,0,0,0); pthread_cleanup_pop(0); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + acx_pthread_ok=yes +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + + LIBS="$save_LIBS" + CFLAGS="$save_CFLAGS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5 +$as_echo "$acx_pthread_ok" >&6; } + if test "x$acx_pthread_ok" = xyes; then + break; + fi + + PTHREAD_LIBS="" + PTHREAD_CFLAGS="" +done +fi + +# Various other checks: +if test "x$acx_pthread_ok" = xyes; then + save_LIBS="$LIBS" + LIBS="$PTHREAD_LIBS $LIBS" + save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + + # Detect AIX lossage: JOINABLE attribute is called UNDETACHED. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5 +$as_echo_n "checking for joinable pthread attribute... " >&6; } + attr_name=unknown + for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +int attr=$attr; return attr; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + attr_name=$attr; break +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + done + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $attr_name" >&5 +$as_echo "$attr_name" >&6; } + if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then + +cat >>confdefs.h <<_ACEOF +#define PTHREAD_CREATE_JOINABLE $attr_name +_ACEOF + + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5 +$as_echo_n "checking if more special flags are required for pthreads... " >&6; } + flag=no + case "${host_cpu}-${host_os}" in + *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";; + *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${flag}" >&5 +$as_echo "${flag}" >&6; } + if test "x$flag" != xno; then + PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS" + fi + + LIBS="$save_LIBS" + CFLAGS="$save_CFLAGS" + + # More AIX lossage: must compile with xlc_r or cc_r + if test x"$GCC" != xyes; then + for ac_prog in xlc_r cc_r +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_PTHREAD_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$PTHREAD_CC"; then + ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_PTHREAD_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +PTHREAD_CC=$ac_cv_prog_PTHREAD_CC +if test -n "$PTHREAD_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5 +$as_echo "$PTHREAD_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$PTHREAD_CC" && break +done +test -n "$PTHREAD_CC" || PTHREAD_CC="${CC}" + + else + PTHREAD_CC=$CC + fi +else + PTHREAD_CC="$CC" +fi + + + + + +# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND: +if test x"$acx_pthread_ok" = xyes; then + + +$as_echo "#define HAVE_PTHREADS 1" >>confdefs.h + + have_pthreads=yes + : +else + acx_pthread_ok=no + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + # The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 +$as_echo_n "checking size of pthread_t... " >&6; } +if ${ac_cv_sizeof_pthread_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t" "$ac_includes_default + #include + +"; then : + +else + if test "$ac_cv_type_pthread_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (pthread_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_pthread_t=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 +$as_echo "$ac_cv_sizeof_pthread_t" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t +_ACEOF + + +fi + if test "$have_pthreads" != "no" && test "$enable_thread_support" != "no"; then + PTHREADS_TRUE= + PTHREADS_FALSE='#' +else + PTHREADS_TRUE='#' + PTHREADS_FALSE= +fi + + +# check if we should compile locking into the library +if test x$enable_thread_support = xno; then + +$as_echo "#define DISABLE_THREAD_SUPPORT 1" >>confdefs.h + +fi + +# check if we should hard-code the mm functions. +if test x$enable_malloc_replacement = xno; then + +$as_echo "#define DISABLE_MM_REPLACEMENT 1" >>confdefs.h + +fi + +# check if we should hard-code debugging out +if test x$enable_debug_mode = xno; then + +$as_echo "#define DISABLE_DEBUG_MODE 1" >>confdefs.h + +fi + +# check if we should enable verbose debugging +if test x$enable_verbose_debug = xyes; then + CFLAGS="$CFLAGS -DUSE_DEBUG" +fi + +# check if we have and should use openssl + if test "$enable_openssl" != "no" && test "$have_openssl" = "yes"; then + OPENSSL_TRUE= + OPENSSL_FALSE='#' +else + OPENSSL_TRUE='#' + OPENSSL_FALSE= +fi + + +# Add some more warnings which we use in development but not in the +# released versions. (Some relevant gcc versions can't handle these.) +if test x$enable_gcc_warnings != xno && test "$GCC" = "yes"; then + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#if !defined(__GNUC__) || (__GNUC__ < 4) +#error +#endif + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + have_gcc4=yes +else + have_gcc4=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#if !defined(__GNUC__) || (__GNUC__ < 4) || (__GNUC__ == 4 && __GNUC_MINOR__ < 2) +#error +#endif + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + have_gcc42=yes +else + have_gcc42=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#if !defined(__GNUC__) || (__GNUC__ < 4) || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) +#error +#endif + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + have_gcc45=yes +else + have_gcc45=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +#if !defined(__clang__) +#error +#endif + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + have_clang=yes +else + have_clang=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + CFLAGS="$CFLAGS -W -Wfloat-equal -Wundef -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wwrite-strings -Wredundant-decls -Wchar-subscripts -Wcomment -Wformat -Wwrite-strings -Wmissing-declarations -Wredundant-decls -Wnested-externs -Wbad-function-cast -Wswitch-enum" + if test x$enable_gcc_warnings = xyes; then + CFLAGS="$CFLAGS -Werror" + fi + + CFLAGS="$CFLAGS -Wno-unused-parameter -Wstrict-aliasing" + + if test x$have_gcc4 = xyes ; then + # These warnings break gcc 3.3.5 and work on gcc 4.0.2 + CFLAGS="$CFLAGS -Winit-self -Wmissing-field-initializers -Wdeclaration-after-statement" + #CFLAGS="$CFLAGS -Wold-style-definition" + fi + + if test x$have_gcc42 = xyes ; then + # These warnings break gcc 4.0.2 and work on gcc 4.2 + CFLAGS="$CFLAGS -Waddress" + fi + + if test x$have_gcc42 = xyes && test x$have_clang = xno; then + # These warnings break gcc 4.0.2 and clang, but work on gcc 4.2 + CFLAGS="$CFLAGS -Wnormalized=id -Woverride-init" + fi + + if test x$have_gcc45 = xyes ; then + # These warnings work on gcc 4.5 + CFLAGS="$CFLAGS -Wlogical-op" + fi + + if test x$have_clang = xyes; then + # Disable the unused-function warnings, because these trigger + # for minheap-internal.h related code. + CFLAGS="$CFLAGS -Wno-unused-function" + + # clang on macosx emits warnigns for each directory specified which + # isn't "used" generating a lot of build noise (typically 3 warnings + # per file + case "$host_os" in + darwin*) + CFLAGS="$CFLAGS -Qunused-arguments" + ;; + esac + fi + +##This will break the world on some 64-bit architectures +# CFLAGS="$CFLAGS -Winline" + +fi + +LIBEVENT_GC_SECTIONS= +if test "$GCC" = yes && test "$enable_function_sections" = yes ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports omitting unused code and data" >&5 +$as_echo_n "checking if linker supports omitting unused code and data... " >&6; } +if ${libevent_cv_gc_sections_runs+:} false; then : + $as_echo_n "(cached) " >&6 +else + + origCFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Wl,--gc-sections" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #include + +int +main () +{ + + FILE * fpC; + char buf[32]; + size_t cch; + int read_success_once; + + fpC = fopen("conftest.c", "r"); + if (NULL == fpC) + exit(1); + do { + cch = fread(buf, sizeof(buf), 1, fpC); + read_success_once |= (0 != cch); + } while (0 != cch); + if (!read_success_once) + exit(2); + if (!feof(fpC)) + exit(3); + if (0 != fclose(fpC)) + exit(4); + + exit(EXIT_SUCCESS); + + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + if test "X$cross_compiling" = "Xyes" || grep gc-sections conftest.err ; then + libevent_cv_gc_sections_runs=no + else + libevent_cv_gc_sections_runs=no + ./conftest >/dev/null 2>&1 && libevent_cv_gc_sections_runs=yes + fi + +else + libevent_cv_gc_sections_runs=no + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS="$origCFLAGS" + { origCFLAGS=; unset origCFLAGS;} + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libevent_cv_gc_sections_runs" >&5 +$as_echo "$libevent_cv_gc_sections_runs" >&6; } + case "$libevent_cv_gc_sections_runs" in + yes) + CFLAGS="-ffunction-sections -fdata-sections $CFLAGS" + LIBEVENT_GC_SECTIONS="-Wl,--gc-sections" + ;; + esac +fi + + + if test "$enable_libevent_install" = "yes"; then + INSTALL_LIBEVENT_TRUE= + INSTALL_LIBEVENT_FALSE='#' +else + INSTALL_LIBEVENT_TRUE='#' + INSTALL_LIBEVENT_FALSE= +fi + + +ac_config_files="$ac_config_files libevent.pc libevent_openssl.pc libevent_pthreads.pc" + +ac_config_files="$ac_config_files Makefile" + +cat >confcache <<\_ACEOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. +# +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. +# +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. + +_ACEOF + +# The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +( + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + + (set) 2>&1 | + case $as_nl`(ac_space=' '; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + # `set' does not quote correctly, so add quotes: double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \. + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; #( + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) | + sed ' + /^ac_cv_env_/b end + t clear + :clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + :end' >>confcache +if diff "$cache_file" confcache >/dev/null 2>&1; then :; else + if test -w "$cache_file"; then + if test "x$cache_file" != "x/dev/null"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 +$as_echo "$as_me: updating cache $cache_file" >&6;} + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 +$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + fi +fi +rm -f confcache + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +DEFS=-DHAVE_CONFIG_H + +ac_libobjs= +ac_ltlibobjs= +U= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' + ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR + # will be set to the directory where LIBOBJS objects are built. + as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" + as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs + +LTLIBOBJS=$ac_ltlibobjs + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +$as_echo_n "checking that generated files are newer than configure... " >&6; } + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 +$as_echo "done" >&6; } + if test -n "$EXEEXT"; then + am__EXEEXT_TRUE= + am__EXEEXT_FALSE='#' +else + am__EXEEXT_TRUE='#' + am__EXEEXT_FALSE= +fi + +if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then + as_fn_error $? "conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_SAMPLES_TRUE}" && test -z "${BUILD_SAMPLES_FALSE}"; then + as_fn_error $? "conditional \"BUILD_SAMPLES\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_REGRESS_TRUE}" && test -z "${BUILD_REGRESS_FALSE}"; then + as_fn_error $? "conditional \"BUILD_REGRESS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${ZLIB_REGRESS_TRUE}" && test -z "${ZLIB_REGRESS_FALSE}"; then + as_fn_error $? "conditional \"ZLIB_REGRESS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${OPENSSL_TRUE}" && test -z "${OPENSSL_FALSE}"; then + as_fn_error $? "conditional \"OPENSSL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_WIN32_TRUE}" && test -z "${BUILD_WIN32_FALSE}"; then + as_fn_error $? "conditional \"BUILD_WIN32\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_CYGWIN_TRUE}" && test -z "${BUILD_CYGWIN_FALSE}"; then + as_fn_error $? "conditional \"BUILD_CYGWIN\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${BUILD_WITH_NO_UNDEFINED_TRUE}" && test -z "${BUILD_WITH_NO_UNDEFINED_FALSE}"; then + as_fn_error $? "conditional \"BUILD_WITH_NO_UNDEFINED\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${STRLCPY_IMPL_TRUE}" && test -z "${STRLCPY_IMPL_FALSE}"; then + as_fn_error $? "conditional \"STRLCPY_IMPL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${SELECT_BACKEND_TRUE}" && test -z "${SELECT_BACKEND_FALSE}"; then + as_fn_error $? "conditional \"SELECT_BACKEND\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${POLL_BACKEND_TRUE}" && test -z "${POLL_BACKEND_FALSE}"; then + as_fn_error $? "conditional \"POLL_BACKEND\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${DEVPOLL_BACKEND_TRUE}" && test -z "${DEVPOLL_BACKEND_FALSE}"; then + as_fn_error $? "conditional \"DEVPOLL_BACKEND\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${KQUEUE_BACKEND_TRUE}" && test -z "${KQUEUE_BACKEND_FALSE}"; then + as_fn_error $? "conditional \"KQUEUE_BACKEND\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${EPOLL_BACKEND_TRUE}" && test -z "${EPOLL_BACKEND_FALSE}"; then + as_fn_error $? "conditional \"EPOLL_BACKEND\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${EVPORT_BACKEND_TRUE}" && test -z "${EVPORT_BACKEND_FALSE}"; then + as_fn_error $? "conditional \"EVPORT_BACKEND\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${SIGNAL_SUPPORT_TRUE}" && test -z "${SIGNAL_SUPPORT_FALSE}"; then + as_fn_error $? "conditional \"SIGNAL_SUPPORT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${PTHREADS_TRUE}" && test -z "${PTHREADS_FALSE}"; then + as_fn_error $? "conditional \"PTHREADS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${OPENSSL_TRUE}" && test -z "${OPENSSL_FALSE}"; then + as_fn_error $? "conditional \"OPENSSL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${INSTALL_LIBEVENT_TRUE}" && test -z "${INSTALL_LIBEVENT_FALSE}"; then + as_fn_error $? "conditional \"INSTALL_LIBEVENT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +: "${CONFIG_STATUS=./config.status}" +ac_write_fail=0 +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files $CONFIG_STATUS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 +$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +as_write_fail=0 +cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 +#! $SHELL +# Generated by $as_me. +# Run this file to recreate the current configuration. +# Compiler output produced by configure, useful for debugging +# configure, is in config.log if it exists. + +debug=false +ac_cs_recheck=false +ac_cs_silent=false + +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + + +exec 6>&1 +## ----------------------------------- ## +## Main body of $CONFIG_STATUS script. ## +## ----------------------------------- ## +_ASEOF +test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Save the log message, to keep $0 and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. +ac_log=" +This file was extended by libevent $as_me 2.1.5-beta, which was +generated by GNU Autoconf 2.69. Invocation command line was + + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ + +on `(hostname || uname -n) 2>/dev/null | sed 1q` +" + +_ACEOF + +case $ac_config_files in *" +"*) set x $ac_config_files; shift; ac_config_files=$*;; +esac + +case $ac_config_headers in *" +"*) set x $ac_config_headers; shift; ac_config_headers=$*;; +esac + + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# Files that config.status was made for. +config_files="$ac_config_files" +config_headers="$ac_config_headers" +config_commands="$ac_config_commands" + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +ac_cs_usage="\ +\`$as_me' instantiates files and other configuration actions +from templates according to the current configuration. Unless the files +and actions are specified as TAGs, all are instantiated by default. + +Usage: $0 [OPTION]... [TAG]... + + -h, --help print this help, then exit + -V, --version print version number and configuration settings, then exit + --config print configuration, then exit + -q, --quiet, --silent + do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + --header=FILE[:TEMPLATE] + instantiate the configuration header FILE + +Configuration files: +$config_files + +Configuration headers: +$config_headers + +Configuration commands: +$config_commands + +Report bugs to the package provider." + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +ac_cs_version="\\ +libevent config.status 2.1.5-beta +configured by $0, generated by GNU Autoconf 2.69, + with options \\"\$ac_cs_config\\" + +Copyright (C) 2012 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." + +ac_pwd='$ac_pwd' +srcdir='$srcdir' +INSTALL='$INSTALL' +MKDIR_P='$MKDIR_P' +AWK='$AWK' +test -n "\$AWK" || AWK=awk +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# The default lists apply if the user does not specify any file. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=?*) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` + ac_shift=: + ;; + --*=) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg= + ac_shift=: + ;; + *) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + esac + + case $ac_option in + # Handling of the options. + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) + $as_echo "$ac_cs_version"; exit ;; + --config | --confi | --conf | --con | --co | --c ) + $as_echo "$ac_cs_config"; exit ;; + --debug | --debu | --deb | --de | --d | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + '') as_fn_error $? "missing file argument" ;; + esac + as_fn_append CONFIG_FILES " '$ac_optarg'" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append CONFIG_HEADERS " '$ac_optarg'" + ac_need_defaults=false;; + --he | --h) + # Conflict between --help and --header + as_fn_error $? "ambiguous option: \`$1' +Try \`$0 --help' for more information.";; + --help | --hel | -h ) + $as_echo "$ac_cs_usage"; exit ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; + + # This is an error. + -*) as_fn_error $? "unrecognized option: \`$1' +Try \`$0 --help' for more information." ;; + + *) as_fn_append ac_config_targets " $1" + ac_need_defaults=false ;; + + esac + shift +done + +ac_configure_extra_args= + +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +if \$ac_cs_recheck; then + set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + shift + \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + CONFIG_SHELL='$SHELL' + export CONFIG_SHELL + exec "\$@" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX + $as_echo "$ac_log" +} >&5 + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# +# INIT-COMMANDS +# +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" + + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' +macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' +enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' +enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' +pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' +enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' +SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' +ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' +host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' +host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' +host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' +build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' +build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' +build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' +SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' +Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' +GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' +EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' +FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' +LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' +NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' +LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' +max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' +ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' +exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' +lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' +lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' +lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' +lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' +lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' +reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' +reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' +deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' +file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' +file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' +want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' +DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' +sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' +AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' +archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' +STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' +RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' +old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' +old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' +lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' +CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' +CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' +compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' +GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' +nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' +lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' +objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' +MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' +need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' +MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' +DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' +NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' +LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' +OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' +OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' +libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' +shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' +extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' +compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' +module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' +with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' +no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' +hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' +hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' +inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' +link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' +always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' +exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' +include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' +prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' +postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' +file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' +variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' +need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' +need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' +version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' +runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' +libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' +library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' +soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' +install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' +postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' +postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' +finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' +hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' +sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' +sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' +hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' +enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' +old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' +striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' + +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in SHELL \ +ECHO \ +SED \ +GREP \ +EGREP \ +FGREP \ +LD \ +NM \ +LN_S \ +lt_SP2NL \ +lt_NL2SP \ +reload_flag \ +OBJDUMP \ +deplibs_check_method \ +file_magic_cmd \ +file_magic_glob \ +want_nocaseglob \ +DLLTOOL \ +sharedlib_from_linklib_cmd \ +AR \ +AR_FLAGS \ +archiver_list_spec \ +STRIP \ +RANLIB \ +CC \ +CFLAGS \ +compiler \ +lt_cv_sys_global_symbol_pipe \ +lt_cv_sys_global_symbol_to_cdecl \ +lt_cv_sys_global_symbol_to_c_name_address \ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ +nm_file_list_spec \ +lt_prog_compiler_no_builtin_flag \ +lt_prog_compiler_pic \ +lt_prog_compiler_wl \ +lt_prog_compiler_static \ +lt_cv_prog_compiler_c_o \ +need_locks \ +MANIFEST_TOOL \ +DSYMUTIL \ +NMEDIT \ +LIPO \ +OTOOL \ +OTOOL64 \ +shrext_cmds \ +export_dynamic_flag_spec \ +whole_archive_flag_spec \ +compiler_needs_object \ +with_gnu_ld \ +allow_undefined_flag \ +no_undefined_flag \ +hardcode_libdir_flag_spec \ +hardcode_libdir_flag_spec_ld \ +hardcode_libdir_separator \ +exclude_expsyms \ +include_expsyms \ +file_list_spec \ +variables_saved_for_relink \ +libname_spec \ +library_names_spec \ +soname_spec \ +install_override_mode \ +finish_eval \ +old_striplib \ +striplib; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in reload_cmds \ +old_postinstall_cmds \ +old_postuninstall_cmds \ +old_archive_cmds \ +extract_expsyms_cmds \ +old_archive_from_new_cmds \ +old_archive_from_expsyms_cmds \ +archive_cmds \ +archive_expsym_cmds \ +module_cmds \ +module_expsym_cmds \ +export_symbols_cmds \ +prelink_cmds \ +postlink_cmds \ +postinstall_cmds \ +postuninstall_cmds \ +finish_cmds \ +sys_lib_search_path_spec \ +sys_lib_dlsearch_path_spec; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +ac_aux_dir='$ac_aux_dir' +xsi_shell='$xsi_shell' +lt_shell_append='$lt_shell_append' + +# See if we are running on zsh, and set the options which allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + + + PACKAGE='$PACKAGE' + VERSION='$VERSION' + TIMESTAMP='$TIMESTAMP' + RM='$RM' + ofile='$ofile' + + + + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + +# Handling of arguments. +for ac_config_target in $ac_config_targets +do + case $ac_config_target in + "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; + "evconfig-private.h") CONFIG_HEADERS="$CONFIG_HEADERS evconfig-private.h:evconfig-private.h.in" ;; + "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; + "libevent.pc") CONFIG_FILES="$CONFIG_FILES libevent.pc" ;; + "libevent_openssl.pc") CONFIG_FILES="$CONFIG_FILES libevent_openssl.pc" ;; + "libevent_pthreads.pc") CONFIG_FILES="$CONFIG_FILES libevent_pthreads.pc" ;; + "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + esac +done + + +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files + test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers + test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands +fi + +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason against having it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Hook for its removal unless debugging. +# Note that there is a small window in which the directory will not be cleaned: +# after its creation but before its name has been assigned to `$tmp'. +$debug || +{ + tmp= ac_tmp= + trap 'exit_status=$? + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status +' 0 + trap 'as_fn_exit 1' 1 2 13 15 +} +# Create a (secure) tmp directory for tmp files. + +{ + tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && + test -d "$tmp" +} || +{ + tmp=./conf$$-$RANDOM + (umask 077 && mkdir "$tmp") +} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp + +# Set up the scripts for CONFIG_FILES section. +# No need to generate them if there are no CONFIG_FILES. +# This happens for instance with `./config.status config.h'. +if test -n "$CONFIG_FILES"; then + + +ac_cr=`echo X | tr X '\015'` +# On cygwin, bash can eat \r inside `` if the user requested igncr. +# But we know of no other shell where ac_cr would be empty at this +# point, so we can use a bashism as a fallback. +if test "x$ac_cr" = x; then + eval ac_cr=\$\'\\r\' +fi +ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` +if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then + ac_cs_awk_cr='\\r' +else + ac_cs_awk_cr=$ac_cr +fi + +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && +_ACEOF + + +{ + echo "cat >conf$$subs.awk <<_ACEOF" && + echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && + echo "_ACEOF" +} >conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` +ac_delim='%!_!# ' +for ac_last_try in false false false false false :; do + . ./conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + if test $ac_delim_n = $ac_delim_num; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done +rm -f conf$$subs.sh + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && +_ACEOF +sed -n ' +h +s/^/S["/; s/!.*/"]=/ +p +g +s/^[^!]*!// +:repl +t repl +s/'"$ac_delim"'$// +t delim +:nl +h +s/\(.\{148\}\)..*/\1/ +t more1 +s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ +p +n +b repl +:more1 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t nl +:delim +h +s/\(.\{148\}\)..*/\1/ +t more2 +s/["\\]/\\&/g; s/^/"/; s/$/"/ +p +b +:more2 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t delim +' >$CONFIG_STATUS || ac_write_fail=1 +rm -f conf$$subs.awk +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +_ACAWK +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && + for (key in S) S_is_set[key] = 1 + FS = "" + +} +{ + line = $ 0 + nfields = split(line, field, "@") + substed = 0 + len = length(field[1]) + for (i = 2; i < nfields; i++) { + key = field[i] + keylen = length(key) + if (S_is_set[key]) { + value = S[key] + line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) + len += length(value) + length(field[++i]) + substed = 1 + } else + len += 1 + keylen + } + + print line +} + +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then + sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" +else + cat +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ + || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 +_ACEOF + +# VPATH may cause trouble with some makes, so we remove sole $(srcdir), +# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ +h +s/// +s/^/:/ +s/[ ]*$/:/ +s/:\$(srcdir):/:/g +s/:\${srcdir}:/:/g +s/:@srcdir@:/:/g +s/^:*// +s/:*$// +x +s/\(=[ ]*\).*/\1/ +G +s/\n// +s/^[^=]*=[ ]*$// +}' +fi + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +fi # test -n "$CONFIG_FILES" + +# Set up the scripts for CONFIG_HEADERS section. +# No need to generate them if there are no CONFIG_HEADERS. +# This happens for instance with `./config.status Makefile'. +if test -n "$CONFIG_HEADERS"; then +cat >"$ac_tmp/defines.awk" <<\_ACAWK || +BEGIN { +_ACEOF + +# Transform confdefs.h into an awk script `defines.awk', embedded as +# here-document in config.status, that substitutes the proper values into +# config.h.in to produce config.h. + +# Create a delimiter string that does not exist in confdefs.h, to ease +# handling of long lines. +ac_delim='%!_!# ' +for ac_last_try in false false :; do + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done + +# For the awk script, D is an array of macro values keyed by name, +# likewise P contains macro parameters if any. Preserve backslash +# newline sequences. + +ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* +sed -n ' +s/.\{148\}/&'"$ac_delim"'/g +t rset +:rset +s/^[ ]*#[ ]*define[ ][ ]*/ / +t def +d +:def +s/\\$// +t bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3"/p +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p +d +:bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3\\\\\\n"\\/p +t cont +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p +t cont +d +:cont +n +s/.\{148\}/&'"$ac_delim"'/g +t clear +:clear +s/\\$// +t bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/"/p +d +:bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p +b cont +' >$CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + for (key in D) D_is_set[key] = 1 + FS = "" +} +/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { + line = \$ 0 + split(line, arg, " ") + if (arg[1] == "#") { + defundef = arg[2] + mac1 = arg[3] + } else { + defundef = substr(arg[1], 2) + mac1 = arg[2] + } + split(mac1, mac2, "(") #) + macro = mac2[1] + prefix = substr(line, 1, index(line, defundef) - 1) + if (D_is_set[macro]) { + # Preserve the white space surrounding the "#". + print prefix "define", macro P[macro] D[macro] + next + } else { + # Replace #undef with comments. This is necessary, for example, + # in the case of _POSIX_SOURCE, which is predefined and required + # on some systems where configure will not decide to define it. + if (defundef == "undef") { + print "/*", prefix defundef, macro, "*/" + next + } + } +} +{ print } +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 +fi # test -n "$CONFIG_HEADERS" + + +eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" +shift +for ac_tag +do + case $ac_tag in + :[FHLC]) ac_mode=$ac_tag; continue;; + esac + case $ac_mode$ac_tag in + :[FHL]*:*);; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; + :[FH]-) ac_tag=-:-;; + :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; + esac + ac_save_IFS=$IFS + IFS=: + set x $ac_tag + IFS=$ac_save_IFS + shift + ac_file=$1 + shift + + case $ac_mode in + :L) ac_source=$1;; + :[FH]) + ac_file_inputs= + for ac_f + do + case $ac_f in + -) ac_f="$ac_tmp/stdin";; + *) # Look for the file first in the build tree, then in the source tree + # (if the path is not absolute). The absolute path cannot be DOS-style, + # because $ac_f cannot contain `:'. + test -f "$ac_f" || + case $ac_f in + [\\/$]*) false;; + *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; + esac || + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; + esac + case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + as_fn_append ac_file_inputs " '$ac_f'" + done + + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + configure_input='Generated from '` + $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + `' by configure.' + if test x"$ac_file" != x-; then + configure_input="$ac_file. $configure_input" + { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 +$as_echo "$as_me: creating $ac_file" >&6;} + fi + # Neutralize special characters interpreted by sed in replacement strings. + case $configure_input in #( + *\&* | *\|* | *\\* ) + ac_sed_conf_input=`$as_echo "$configure_input" | + sed 's/[\\\\&|]/\\\\&/g'`;; #( + *) ac_sed_conf_input=$configure_input;; + esac + + case $ac_tag in + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; + esac + ;; + esac + + ac_dir=`$as_dirname -- "$ac_file" || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + + case $ac_mode in + :F) + # + # CONFIG_FILE + # + + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; + esac + ac_MKDIR_P=$MKDIR_P + case $MKDIR_P in + [\\/$]* | ?:[\\/]* ) ;; + */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; + esac +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# If the template does not know about datarootdir, expand it. +# FIXME: This hack should be removed a few years after 2.60. +ac_datarootdir_hack=; ac_datarootdir_seen= +ac_sed_dataroot=' +/datarootdir/ { + p + q +} +/@datadir@/p +/@docdir@/p +/@infodir@/p +/@localedir@/p +/@mandir@/p' +case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in +*datarootdir*) ac_datarootdir_seen=yes;; +*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + ac_datarootdir_hack=' + s&@datadir@&$datadir&g + s&@docdir@&$docdir&g + s&@infodir@&$infodir&g + s&@localedir@&$localedir&g + s&@mandir@&$mandir&g + s&\\\${datarootdir}&$datarootdir&g' ;; +esac +_ACEOF + +# Neutralize VPATH when `$srcdir' = `.'. +# Shell code in configure.ac might set extrasub. +# FIXME: do we really want to maintain this feature? +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_sed_extra="$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s|@configure_input@|$ac_sed_conf_input|;t t +s&@top_builddir@&$ac_top_builddir_sub&;t t +s&@top_build_prefix@&$ac_top_build_prefix&;t t +s&@srcdir@&$ac_srcdir&;t t +s&@abs_srcdir@&$ac_abs_srcdir&;t t +s&@top_srcdir@&$ac_top_srcdir&;t t +s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t +s&@builddir@&$ac_builddir&;t t +s&@abs_builddir@&$ac_abs_builddir&;t t +s&@abs_top_builddir@&$ac_abs_top_builddir&;t t +s&@INSTALL@&$ac_INSTALL&;t t +s&@MKDIR_P@&$ac_MKDIR_P&;t t +$ac_datarootdir_hack +" +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + +test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&5 +$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&2;} + + rm -f "$ac_tmp/stdin" + case $ac_file in + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; + esac \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + ;; + :H) + # + # CONFIG_HEADER + # + if test x"$ac_file" != x-; then + { + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 +$as_echo "$as_me: $ac_file is unchanged" >&6;} + else + rm -f "$ac_file" + mv "$ac_tmp/config.h" "$ac_file" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + fi + else + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ + || as_fn_error $? "could not create -" "$LINENO" 5 + fi +# Compute "$ac_file"'s index in $config_headers. +_am_arg="$ac_file" +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || +$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$_am_arg" : 'X\(//\)[^/]' \| \ + X"$_am_arg" : 'X\(//\)$' \| \ + X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$_am_arg" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'`/stamp-h$_am_stamp_count + ;; + + :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 +$as_echo "$as_me: executing $ac_file commands" >&6;} + ;; + esac + + + case $ac_file$ac_mode in + "depfiles":C) test x"$AMDEP_TRUE" != x"" || { + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir=$dirpart/$fdir; as_fn_mkdir_p + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} + ;; + "libtool":C) + + # See if we are running on zsh, and set the options which allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + + cfgfile="${ofile}T" + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL + +# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is part of GNU Libtool. +# +# GNU Libtool is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or +# obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + +# The names of the tagged configurations supported by this script. +available_tags="" + +# ### BEGIN LIBTOOL CONFIG + +# Which release of libtool.m4 was used? +macro_version=$macro_version +macro_revision=$macro_revision + +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared + +# Whether or not to build static libraries. +build_old_libs=$enable_static + +# What type of objects to build. +pic_mode=$pic_mode + +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install + +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL + +# An echo program that protects backslashes. +ECHO=$lt_ECHO + +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os + +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os + +# A sed program that does not truncate output. +SED=$lt_SED + +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="\$SED -e 1s/^X//" + +# A grep program that handles long lines. +GREP=$lt_GREP + +# An ERE matcher. +EGREP=$lt_EGREP + +# A literal string matcher. +FGREP=$lt_FGREP + +# A BSD- or MS-compatible name lister. +NM=$lt_NM + +# Whether we need soft or hard links. +LN_S=$lt_LN_S + +# What is the maximum length of a command? +max_cmd_len=$max_cmd_len + +# Object file suffix (normally "o"). +objext=$ac_objext + +# Executable file suffix (normally ""). +exeext=$exeext + +# whether the shell understands "unset". +lt_unset=$lt_unset + +# turn spaces into newlines. +SP2NL=$lt_lt_SP2NL + +# turn newlines into spaces. +NL2SP=$lt_lt_NL2SP + +# convert \$build file names to \$host format. +to_host_file_cmd=$lt_cv_to_host_file_cmd + +# convert \$build files to toolchain format. +to_tool_file_cmd=$lt_cv_to_tool_file_cmd + +# An object symbol dumper. +OBJDUMP=$lt_OBJDUMP + +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method + +# Command to use when deplibs_check_method = "file_magic". +file_magic_cmd=$lt_file_magic_cmd + +# How to find potential files when deplibs_check_method = "file_magic". +file_magic_glob=$lt_file_magic_glob + +# Find potential files using nocaseglob when deplibs_check_method = "file_magic". +want_nocaseglob=$lt_want_nocaseglob + +# DLL creation program. +DLLTOOL=$lt_DLLTOOL + +# Command to associate shared and link libraries. +sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd + +# The archiver. +AR=$lt_AR + +# Flags to create an archive. +AR_FLAGS=$lt_AR_FLAGS + +# How to feed a file listing to the archiver. +archiver_list_spec=$lt_archiver_list_spec + +# A symbol stripping program. +STRIP=$lt_STRIP + +# Commands used to install an old-style archive. +RANLIB=$lt_RANLIB +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds + +# Whether to use a lock for old archive extraction. +lock_old_archive_extraction=$lock_old_archive_extraction + +# A C compiler. +LTCC=$lt_CC + +# LTCC compiler flags. +LTCFLAGS=$lt_CFLAGS + +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + +# Transform the output of nm in a proper C declaration. +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + +# Transform the output of nm in a C name address pair. +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + +# Transform the output of nm in a C name address pair when lib prefix is needed. +global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix + +# Specify filename containing input files for \$NM. +nm_file_list_spec=$lt_nm_file_list_spec + +# The root where to search for dependent libraries,and in which our libraries should be installed. +lt_sysroot=$lt_sysroot + +# The name of the directory that contains temporary libtool files. +objdir=$objdir + +# Used to examine libraries when file_magic_cmd begins with "file". +MAGIC_CMD=$MAGIC_CMD + +# Must we lock files when doing compilation? +need_locks=$lt_need_locks + +# Manifest tool. +MANIFEST_TOOL=$lt_MANIFEST_TOOL + +# Tool to manipulate archived DWARF debug symbol files on Mac OS X. +DSYMUTIL=$lt_DSYMUTIL + +# Tool to change global to local symbols on Mac OS X. +NMEDIT=$lt_NMEDIT + +# Tool to manipulate fat objects and archives on Mac OS X. +LIPO=$lt_LIPO + +# ldd/readelf like tool for Mach-O binaries on Mac OS X. +OTOOL=$lt_OTOOL + +# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. +OTOOL64=$lt_OTOOL64 + +# Old archive suffix (normally "a"). +libext=$libext + +# Shared library suffix (normally ".so"). +shrext_cmds=$lt_shrext_cmds + +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds + +# Variables whose values should be saved in libtool wrapper scripts and +# restored at link time. +variables_saved_for_relink=$lt_variables_saved_for_relink + +# Do we need the "lib" prefix for modules? +need_lib_prefix=$need_lib_prefix + +# Do we need a version for libraries? +need_version=$need_version + +# Library versioning type. +version_type=$version_type + +# Shared library runtime path variable. +runpath_var=$runpath_var + +# Shared library path variable. +shlibpath_var=$shlibpath_var + +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath + +# Format of library name prefix. +libname_spec=$lt_libname_spec + +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME +library_names_spec=$lt_library_names_spec + +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec + +# Permission mode override for installation of shared libraries. +install_override_mode=$lt_install_override_mode + +# Command to use after installation of a shared archive. +postinstall_cmds=$lt_postinstall_cmds + +# Command to use after uninstallation of a shared archive. +postuninstall_cmds=$lt_postuninstall_cmds + +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds + +# As "finish_cmds", except a single script fragment to be evaled but +# not shown. +finish_eval=$lt_finish_eval + +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs + +# Compile-time system search path for libraries. +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec + +# Run-time system search path for libraries. +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec + +# Whether dlopen is supported. +dlopen_support=$enable_dlopen + +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self + +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static + +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib + + +# The linker used to build libraries. +LD=$lt_LD + +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds + +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds + +# A language specific compiler. +CC=$lt_compiler + +# Is the compiler the GNU compiler? +with_gcc=$GCC + +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic + +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl + +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static + +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc + +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes + +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec + +# If ld is used when linking, flag to hardcode \$libdir into a binary +# during linking. This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct + +# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \${shlibpath_var} if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath + +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs + +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols + +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms + +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds + +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds + +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec + +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action + +# ### END LIBTOOL CONFIG + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + +ltmain="$ac_aux_dir/ltmain.sh" + + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + if test x"$xsi_shell" = xyes; then + sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ +func_dirname ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_basename ()$/,/^} # func_basename /c\ +func_basename ()\ +{\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ +func_dirname_and_basename ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ +func_stripname ()\ +{\ +\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\ +\ # positional parameters, so assign one to ordinary parameter first.\ +\ func_stripname_result=${3}\ +\ func_stripname_result=${func_stripname_result#"${1}"}\ +\ func_stripname_result=${func_stripname_result%"${2}"}\ +} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ +func_split_long_opt ()\ +{\ +\ func_split_long_opt_name=${1%%=*}\ +\ func_split_long_opt_arg=${1#*=}\ +} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ +func_split_short_opt ()\ +{\ +\ func_split_short_opt_arg=${1#??}\ +\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ +} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ +func_lo2o ()\ +{\ +\ case ${1} in\ +\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ +\ *) func_lo2o_result=${1} ;;\ +\ esac\ +} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_xform ()$/,/^} # func_xform /c\ +func_xform ()\ +{\ + func_xform_result=${1%.*}.lo\ +} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_arith ()$/,/^} # func_arith /c\ +func_arith ()\ +{\ + func_arith_result=$(( $* ))\ +} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_len ()$/,/^} # func_len /c\ +func_len ()\ +{\ + func_len_result=${#1}\ +} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + +fi + +if test x"$lt_shell_append" = xyes; then + sed -e '/^func_append ()$/,/^} # func_append /c\ +func_append ()\ +{\ + eval "${1}+=\\${2}"\ +} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ +func_append_quoted ()\ +{\ +\ func_quote_for_eval "${2}"\ +\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ +} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi + +if test x"$_lt_function_replace_fail" = x":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} +fi + + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" + + ;; + + esac +done # for ac_tag + + +as_fn_exit 0 +_ACEOF +ac_clean_files=$ac_clean_files_save + +test $ac_write_fail = 0 || + as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 + + +# configure is writing to config.log, and then calls config.status. +# config.status does its own redirection, appending to config.log. +# Unfortunately, on DOS this fails, as config.log is still kept open +# by configure, so config.status won't be able to write to it; its +# output is simply discarded. So we exec the FD to /dev/null, +# effectively closing config.log, so it can be properly (re)opened and +# appended to by config.status. When coming back to configure, we +# need to make the FD available again. +if test "$no_create" != yes; then + ac_cs_success=: + ac_config_status_args= + test "$silent" = yes && + ac_config_status_args="$ac_config_status_args --quiet" + exec 5>/dev/null + $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false + exec 5>>config.log + # Use ||, not &&, to avoid exiting from the if with $? = 1, which + # would make configure fail if this is the last instruction. + $ac_cs_success || as_fn_exit 1 +fi +if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 +$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} +fi + diff --git a/contrib/ntp/sntp/libevent/configure.ac b/contrib/ntp/sntp/libevent/configure.ac new file mode 100644 index 000000000..2cdc74f16 --- /dev/null +++ b/contrib/ntp/sntp/libevent/configure.ac @@ -0,0 +1,916 @@ +dnl Copyright 2000-2007 Niels Provos +dnl Copyright 2007-2012 Niels Provos and Nick Mathewson +dnl +dnl See LICENSE for copying information. +dnl +dnl Original version Dug Song + +AC_INIT(libevent,2.1.5-beta) +AC_PREREQ(2.59) +AC_CONFIG_SRCDIR(event.c) + +AC_CONFIG_MACRO_DIR([m4]) +AC_CONFIG_AUX_DIR([build-aux]) +AM_INIT_AUTOMAKE +dnl AM_SILENT_RULES req. automake 1.11. [no] defaults V=1 +m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) +AC_CONFIG_HEADERS(config.h evconfig-private.h:evconfig-private.h.in) +AC_DEFINE(NUMERIC_VERSION, 0x02010500, [Numeric representation of the version]) + +dnl Initialize prefix. +if test "$prefix" = "NONE"; then + prefix="/usr/local" +fi + +dnl Try and get a full POSIX environment on obscure systems +ifdef([AC_USE_SYSTEM_EXTENSIONS], [ +AC_USE_SYSTEM_EXTENSIONS +], [ +AC_AIX +AC_GNU_SOURCE +AC_MINIX +]) + +AC_CANONICAL_BUILD +AC_CANONICAL_HOST +dnl the 'build' machine is where we run configure and compile +dnl the 'host' machine is where the resulting stuff runs. + +#case "$host_os" in +# +# osf5*) +# CFLAGS="$CFLAGS -D_OSF_SOURCE" +# ;; +#esac + +dnl Checks for programs. +AM_PROG_CC_C_O +AC_PROG_INSTALL +AC_PROG_LN_S +# AC_PROG_MKDIR_P - $(MKDIR_P) should be defined by AM_INIT_AUTOMAKE + +# AC_PROG_SED is only available in Autoconf >= 2.59b; workaround for older +# versions +ifdef([AC_PROG_SED], [AC_PROG_SED], [ +AC_CHECK_PROGS(SED, [gsed sed]) +]) + +AC_PROG_GCC_TRADITIONAL + +# We need to test for at least gcc 2.95 here, because older versions don't +# have -fno-strict-aliasing +AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [ +#if !defined(__GNUC__) || (__GNUC__ < 2) || (__GNUC__ == 2 && __GNUC_MINOR__ < 95) +#error +#endif])], have_gcc295=yes, have_gcc295=no) + +if test "$GCC" = "yes" ; then + # Enable many gcc warnings by default... + CFLAGS="$CFLAGS -Wall" + # And disable the strict-aliasing optimization, since it breaks + # our sockaddr-handling code in strange ways. + if test x$have_gcc295 = xyes; then + CFLAGS="$CFLAGS -fno-strict-aliasing" + fi +fi + +# OS X Lion started deprecating the system openssl. Let's just disable +# all deprecation warnings on OS X. +case "$host_os" in + + darwin*) + CFLAGS="$CFLAGS -Wno-deprecated-declarations" + ;; +esac + +AC_ARG_ENABLE(gcc-warnings, + AS_HELP_STRING(--disable-gcc-warnings, disable verbose warnings with GCC)) + +AC_ARG_ENABLE(gcc-hardening, + AS_HELP_STRING(--enable-gcc-hardening, enable compiler security checks), +[if test x$enableval = xyes; then + CFLAGS="$CFLAGS -D_FORTIFY_SOURCE=2 -fstack-protector-all" + CFLAGS="$CFLAGS -fwrapv -fPIE -Wstack-protector" + CFLAGS="$CFLAGS --param ssp-buffer-size=1" +fi]) + +AC_ARG_ENABLE(thread-support, + AS_HELP_STRING(--disable-thread-support, disable support for threading), + [], [enable_thread_support=yes]) +AC_ARG_ENABLE(malloc-replacement, + AS_HELP_STRING(--disable-malloc-replacement, disable support for replacing the memory mgt functions), + [], [enable_malloc_replacement=yes]) +AC_ARG_ENABLE(openssl, + AS_HELP_STRING(--disable-openssl, disable support for openssl encryption), + [], [enable_openssl=yes]) +AC_ARG_ENABLE(debug-mode, + AS_HELP_STRING(--disable-debug-mode, disable support for running in debug mode), + [], [enable_debug_mode=yes]) +AC_ARG_ENABLE([libevent-install], + AS_HELP_STRING([--disable-libevent-install, disable installation of libevent]), + [], [enable_libevent_install=yes]) +AC_ARG_ENABLE([libevent-regress], + AS_HELP_STRING([--disable-libevent-regress, skip regress in make check]), + [], [enable_libevent_regress=yes]) +AC_ARG_ENABLE([samples], + AS_HELP_STRING([--disable-samples, skip building of sample programs]), + [], [enable_samples=yes]) +AC_ARG_ENABLE([function-sections], + AS_HELP_STRING([--enable-function-sections, make static library allow smaller binaries with --gc-sections]), + [], [enable_function_sections=no]) +AC_ARG_ENABLE([verbose-debug], + AS_HELP_STRING([--enable-verbose-debug, verbose debug logging]), + [], [enable_verbose_debug=no]) + + +AC_PROG_LIBTOOL + +dnl Uncomment "AC_DISABLE_SHARED" to make shared libraries not get +dnl built by default. You can also turn shared libs on and off from +dnl the command line with --enable-shared and --disable-shared. +dnl AC_DISABLE_SHARED +AC_SUBST(LIBTOOL_DEPS) + +AM_CONDITIONAL([BUILD_SAMPLES], [test "$enable_samples" = "yes"]) +AM_CONDITIONAL([BUILD_REGRESS], [test "$enable_libevent_regress" = "yes"]) + +dnl Checks for libraries. +AC_SEARCH_LIBS([inet_ntoa], [nsl]) +AC_SEARCH_LIBS([socket], [socket]) +AC_SEARCH_LIBS([inet_aton], [resolv]) +AC_SEARCH_LIBS([clock_gettime], [rt]) +AC_SEARCH_LIBS([sendfile], [sendfile]) + +dnl - check if the macro _WIN32 is defined on this compiler. +dnl - (this is how we check for a windows compiler) +AC_MSG_CHECKING(for WIN32) +AC_TRY_COMPILE(, + [ +#ifndef _WIN32 +die horribly +#endif + ], + bwin32=true; AC_MSG_RESULT(yes), + bwin32=false; AC_MSG_RESULT(no), +) + +dnl - check if the macro __CYGWIN__ is defined on this compiler. +dnl - (this is how we check for a cygwin version of GCC) +AC_MSG_CHECKING(for CYGWIN) +AC_TRY_COMPILE(, + [ +#ifndef __CYGWIN__ +die horribly +#endif + ], + cygwin=true; AC_MSG_RESULT(yes), + cygwin=false; AC_MSG_RESULT(no), +) + +AC_CHECK_HEADERS([zlib.h]) + +if test "x$ac_cv_header_zlib_h" = "xyes"; then +dnl Determine if we have zlib for regression tests +dnl Don't put this one in LIBS +save_LIBS="$LIBS" +LIBS="" +ZLIB_LIBS="" +have_zlib=no +AC_SEARCH_LIBS([inflateEnd], [z], + [have_zlib=yes + ZLIB_LIBS="$LIBS" + AC_DEFINE(HAVE_LIBZ, 1, [Define if the system has zlib])]) +LIBS="$save_LIBS" +AC_SUBST(ZLIB_LIBS) +fi +AM_CONDITIONAL(ZLIB_REGRESS, [test "$have_zlib" = "yes"]) + +dnl See if we have openssl. This doesn't go in LIBS either. +if test "$bwin32" = true; then + EV_LIB_WS32=-lws2_32 + EV_LIB_GDI=-lgdi32 +else + EV_LIB_WS32= + EV_LIB_GDI= +fi +AC_SUBST(EV_LIB_WS32) +AC_SUBST(EV_LIB_GDI) +AC_SUBST(OPENSSL_LIBADD) + +AC_SYS_LARGEFILE + +LIBEVENT_OPENSSL + +dnl Checks for header files. +AC_CHECK_HEADERS([ \ + arpa/inet.h \ + fcntl.h \ + ifaddrs.h \ + mach/mach_time.h \ + netdb.h \ + netinet/in.h \ + netinet/in6.h \ + netinet/tcp.h \ + poll.h \ + port.h \ + stdarg.h \ + stddef.h \ + sys/devpoll.h \ + sys/epoll.h \ + sys/event.h \ + sys/eventfd.h \ + sys/ioctl.h \ + sys/mman.h \ + sys/param.h \ + sys/queue.h \ + sys/resource.h \ + sys/select.h \ + sys/sendfile.h \ + sys/socket.h \ + sys/stat.h \ + sys/time.h \ + sys/timerfd.h \ + sys/uio.h \ + sys/wait.h \ +]) + +AC_CHECK_HEADERS(sys/sysctl.h, [], [], [ +#ifdef HAVE_SYS_PARAM_H +#include +#endif +]) +if test "x$ac_cv_header_sys_queue_h" = "xyes"; then + AC_MSG_CHECKING(for TAILQ_FOREACH in sys/queue.h) + AC_EGREP_CPP(yes, +[ +#include +#ifdef TAILQ_FOREACH + yes +#endif +], [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_TAILQFOREACH, 1, + [Define if TAILQ_FOREACH is defined in ])], + AC_MSG_RESULT(no) + ) +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + AC_MSG_CHECKING(for timeradd in sys/time.h) + AC_EGREP_CPP(yes, +[ +#include +#ifdef timeradd + yes +#endif +], [ AC_DEFINE(HAVE_TIMERADD, 1, + [Define if timeradd is defined in ]) + AC_MSG_RESULT(yes)] ,AC_MSG_RESULT(no) +) +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + AC_MSG_CHECKING(for timercmp in sys/time.h) + AC_EGREP_CPP(yes, +[ +#include +#ifdef timercmp + yes +#endif +], [ AC_DEFINE(HAVE_TIMERCMP, 1, + [Define if timercmp is defined in ]) + AC_MSG_RESULT(yes)] ,AC_MSG_RESULT(no) +) +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + AC_MSG_CHECKING(for timerclear in sys/time.h) + AC_EGREP_CPP(yes, +[ +#include +#ifdef timerclear + yes +#endif +], [ AC_DEFINE(HAVE_TIMERCLEAR, 1, + [Define if timerclear is defined in ]) + AC_MSG_RESULT(yes)] ,AC_MSG_RESULT(no) +) +fi + +if test "x$ac_cv_header_sys_time_h" = "xyes"; then + AC_MSG_CHECKING(for timerisset in sys/time.h) + AC_EGREP_CPP(yes, +[ +#include +#ifdef timerisset + yes +#endif +], [ AC_DEFINE(HAVE_TIMERISSET, 1, + [Define if timerisset is defined in ]) + AC_MSG_RESULT(yes)] ,AC_MSG_RESULT(no) +) +fi + +if test "x$ac_cv_header_sys_sysctl_h" = "xyes"; then + AC_CHECK_DECLS([CTL_KERN, KERN_RANDOM, RANDOM_UUID, KERN_ARND], [], [], + [[#include + #include ]] + ) +fi + +AM_CONDITIONAL(BUILD_WIN32, test x$bwin32 = xtrue) +AM_CONDITIONAL(BUILD_CYGWIN, test x$cygwin = xtrue) +AM_CONDITIONAL(BUILD_WITH_NO_UNDEFINED, test x$bwin32 = xtrue || test x$cygwin = xtrue) + +if test x$bwin32 = xtrue; then + AC_SEARCH_LIBS([getservbyname],[ws2_32]) +fi + +dnl Checks for typedefs, structures, and compiler characteristics. +AC_C_CONST +AC_C_INLINE +AC_HEADER_TIME + +dnl Checks for library functions. +AC_CHECK_FUNCS([ \ + accept4 \ + arc4random \ + arc4random_buf \ + clock_gettime \ + eventfd \ + epoll_create1 \ + fcntl \ + getegid \ + geteuid \ + getifaddrs \ + getnameinfo \ + getprotobynumber \ + gettimeofday \ + inet_ntop \ + inet_pton \ + issetugid \ + mach_absolute_time \ + mmap \ + nanosleep \ + pipe \ + pipe2 \ + putenv \ + sendfile \ + setenv \ + setrlimit \ + sigaction \ + signal \ + splice \ + strlcpy \ + strsep \ + strtok_r \ + strtoll \ + sysctl \ + timerfd_create \ + umask \ + unsetenv \ + usleep \ + vasprintf \ +]) +AM_CONDITIONAL(STRLCPY_IMPL, [test x"$ac_cv_func_strlcpy" = xno]) + +AC_CACHE_CHECK( + [for getaddrinfo], + [libevent_cv_getaddrinfo], + [AC_LINK_IFELSE( + [AC_LANG_PROGRAM( + [[ + #ifdef HAVE_NETDB_H + #include + #endif + ]], + [[ + getaddrinfo; + ]] + )], + [libevent_cv_getaddrinfo=yes], + [libevent_cv_getaddrinfo=no] + )] +) +if test "$libevent_cv_getaddrinfo" = "yes" ; then + AC_DEFINE([HAVE_GETADDRINFO], [1], [Do we have getaddrinfo()?]) +else + +AC_CHECK_FUNCS([getservbyname]) +# Check for gethostbyname_r in all its glorious incompatible versions. +# (This is cut-and-pasted from Tor, which based its logic on +# Python's configure.in.) +AH_TEMPLATE(HAVE_GETHOSTBYNAME_R, + [Define this if you have any gethostbyname_r()]) + +AC_CHECK_FUNC(gethostbyname_r, [ + AC_MSG_CHECKING([how many arguments gethostbyname_r() wants]) + OLD_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([ +#include + ], [[ + char *cp1, *cp2; + struct hostent *h1, *h2; + int i1, i2; + (void)gethostbyname_r(cp1,h1,cp2,i1,&h2,&i2); + ]])],[ + AC_DEFINE(HAVE_GETHOSTBYNAME_R) + AC_DEFINE(HAVE_GETHOSTBYNAME_R_6_ARG, 1, + [Define this if gethostbyname_r takes 6 arguments]) + AC_MSG_RESULT(6) + ], [ + AC_TRY_COMPILE([ +#include + ], [ + char *cp1, *cp2; + struct hostent *h1; + int i1, i2; + (void)gethostbyname_r(cp1,h1,cp2,i1,&i2); + ], [ + AC_DEFINE(HAVE_GETHOSTBYNAME_R) + AC_DEFINE(HAVE_GETHOSTBYNAME_R_5_ARG, 1, + [Define this if gethostbyname_r takes 5 arguments]) + AC_MSG_RESULT(5) + ], [ + AC_TRY_COMPILE([ +#include + ], [ + char *cp1; + struct hostent *h1; + struct hostent_data hd; + (void) gethostbyname_r(cp1,h1,&hd); + ], [ + AC_DEFINE(HAVE_GETHOSTBYNAME_R) + AC_DEFINE(HAVE_GETHOSTBYNAME_R_3_ARG, 1, + [Define this if gethostbyname_r takes 3 arguments]) + AC_MSG_RESULT(3) + ], [ + AC_MSG_RESULT(0) + ]) + ]) + ]) + CFLAGS=$OLD_CFLAGS +]) + +fi + +AC_MSG_CHECKING(for F_SETFD in fcntl.h) +AC_EGREP_CPP(yes, +[ +#define _GNU_SOURCE +#include +#ifdef F_SETFD +yes +#endif +], [ AC_DEFINE(HAVE_SETFD, 1, + [Define if F_SETFD is defined in ]) + AC_MSG_RESULT(yes) ], AC_MSG_RESULT(no)) + +needsignal=no +haveselect=no +if test x$bwin32 != xtrue; then + AC_CHECK_FUNCS(select, [haveselect=yes], ) + if test "x$haveselect" = "xyes" ; then + needsignal=yes + fi +fi +AM_CONDITIONAL(SELECT_BACKEND, [test "x$haveselect" = "xyes"]) + +havepoll=no +AC_CHECK_FUNCS(poll, [havepoll=yes], ) +if test "x$havepoll" = "xyes" ; then + needsignal=yes +fi +AM_CONDITIONAL(POLL_BACKEND, [test "x$havepoll" = "xyes"]) + +havedevpoll=no +if test "x$ac_cv_header_sys_devpoll_h" = "xyes"; then + AC_DEFINE(HAVE_DEVPOLL, 1, + [Define if /dev/poll is available]) +fi +AM_CONDITIONAL(DEVPOLL_BACKEND, [test "x$ac_cv_header_sys_devpoll_h" = "xyes"]) + +havekqueue=no +if test "x$ac_cv_header_sys_event_h" = "xyes"; then + AC_CHECK_FUNCS(kqueue, [havekqueue=yes], ) + if test "x$havekqueue" = "xyes" ; then + AC_MSG_CHECKING(for working kqueue) + AC_TRY_RUN( +#include +#include +#include +#include +#include +#include + +int +main(int argc, char **argv) +{ + int kq; + int n; + int fd[[2]]; + struct kevent ev; + struct timespec ts; + char buf[[8000]]; + + if (pipe(fd) == -1) + exit(1); + if (fcntl(fd[[1]], F_SETFL, O_NONBLOCK) == -1) + exit(1); + + while ((n = write(fd[[1]], buf, sizeof(buf))) == sizeof(buf)) + ; + + if ((kq = kqueue()) == -1) + exit(1); + + memset(&ev, 0, sizeof(ev)); + ev.ident = fd[[1]]; + ev.filter = EVFILT_WRITE; + ev.flags = EV_ADD | EV_ENABLE; + n = kevent(kq, &ev, 1, NULL, 0, NULL); + if (n == -1) + exit(1); + + read(fd[[0]], buf, sizeof(buf)); + + ts.tv_sec = 0; + ts.tv_nsec = 0; + n = kevent(kq, NULL, 0, &ev, 1, &ts); + if (n == -1 || n == 0) + exit(1); + + exit(0); +}, [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_WORKING_KQUEUE, 1, + [Define if kqueue works correctly with pipes]) + havekqueue=yes + ], AC_MSG_RESULT(no), AC_MSG_RESULT(no)) + fi +fi +AM_CONDITIONAL(KQUEUE_BACKEND, [test "x$havekqueue" = "xyes"]) + +haveepollsyscall=no +haveepoll=no +AC_CHECK_FUNCS(epoll_ctl, [haveepoll=yes], ) +if test "x$haveepoll" = "xyes" ; then + AC_DEFINE(HAVE_EPOLL, 1, + [Define if your system supports the epoll system calls]) + needsignal=yes +fi +if test "x$ac_cv_header_sys_epoll_h" = "xyes"; then + if test "x$haveepoll" = "xno" ; then + AC_MSG_CHECKING(for epoll system call) + AC_TRY_RUN( +#include +#include +#include +#include +#include +#include + +int +epoll_create(int size) +{ + return (syscall(__NR_epoll_create, size)); +} + +int +main(int argc, char **argv) +{ + int epfd; + + epfd = epoll_create(256); + exit (epfd == -1 ? 1 : 0); +}, [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_EPOLL, 1, + [Define if your system supports the epoll system calls]) + needsignal=yes + have_epoll=yes + AC_LIBOBJ(epoll_sub) + ], AC_MSG_RESULT(no), AC_MSG_RESULT(no)) + fi +fi +AM_CONDITIONAL(EPOLL_BACKEND, [test "x$haveepoll" = "xyes"]) + +haveeventports=no +AC_CHECK_FUNCS(port_create, [haveeventports=yes], ) +if test "x$haveeventports" = "xyes" ; then + AC_DEFINE(HAVE_EVENT_PORTS, 1, + [Define if your system supports event ports]) + needsignal=yes +fi +AM_CONDITIONAL(EVPORT_BACKEND, [test "x$haveeventports" = "xyes"]) + +if test "x$bwin32" = "xtrue"; then + needsignal=yes +fi + +AM_CONDITIONAL(SIGNAL_SUPPORT, [test "x$needsignal" = "xyes"]) + +AC_TYPE_PID_T +AC_TYPE_SIZE_T +AC_TYPE_SSIZE_T + +AC_CHECK_TYPES([uint64_t, uint32_t, uint16_t, uint8_t, uintptr_t], , , +[#ifdef HAVE_STDINT_H +#include +#elif defined(HAVE_INTTYPES_H) +#include +#endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif]) + +AC_CHECK_TYPES([fd_mask], , , +[#ifdef HAVE_SYS_TYPES_H +#include +#endif +#ifdef HAVE_SYS_SELECT_H +#include +#endif]) + +AC_CHECK_SIZEOF(long long) +AC_CHECK_SIZEOF(long) +AC_CHECK_SIZEOF(int) +AC_CHECK_SIZEOF(short) +AC_CHECK_SIZEOF(size_t) +AC_CHECK_SIZEOF(void *) +AC_CHECK_SIZEOF(off_t) + +AC_CHECK_TYPES([struct in6_addr, struct sockaddr_in6, sa_family_t, struct addrinfo, struct sockaddr_storage], , , +[#define _GNU_SOURCE +#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETDB_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif +]) +AC_CHECK_MEMBERS([struct in6_addr.s6_addr32, struct in6_addr.s6_addr16, struct sockaddr_in.sin_len, struct sockaddr_in6.sin6_len, struct sockaddr_storage.ss_family, struct sockaddr_storage.__ss_family], , , +[#include +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef _WIN32 +#define WIN32_WINNT 0x400 +#define _WIN32_WINNT 0x400 +#define WIN32_LEAN_AND_MEAN +#if defined(_MSC_VER) && (_MSC_VER < 1300) +#include +#else +#include +#include +#endif +#endif +]) + +AC_CHECK_TYPES([struct so_linger], +[#define HAVE_SO_LINGER], , +[ +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +]) + +AC_MSG_CHECKING([for socklen_t]) +AC_TRY_COMPILE([ + #include + #include ], + [socklen_t x;], + AC_MSG_RESULT([yes]), + [AC_MSG_RESULT([no]) + AC_DEFINE(socklen_t, unsigned int, + [Define to unsigned int if you dont have it])] +) + +AC_MSG_CHECKING([whether our compiler supports __func__]) +AC_TRY_COMPILE([], + [ const char *cp = __func__; ], + AC_MSG_RESULT([yes]), + AC_MSG_RESULT([no]) + AC_MSG_CHECKING([whether our compiler supports __FUNCTION__]) + AC_TRY_COMPILE([], + [ const char *cp = __FUNCTION__; ], + AC_MSG_RESULT([yes]) + AC_DEFINE(__func__, __FUNCTION__, + [Define to appropriate substitue if compiler doesnt have __func__]), + AC_MSG_RESULT([no]) + AC_DEFINE(__func__, __FILE__, + [Define to appropriate substitue if compiler doesnt have __func__]))) + + +# check if we can compile with pthreads +have_pthreads=no +if test x$bwin32 != xtrue && test "$enable_thread_support" != "no"; then + ACX_PTHREAD([ + AC_DEFINE(HAVE_PTHREADS, 1, + [Define if we have pthreads on this system]) + have_pthreads=yes]) + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + AC_CHECK_SIZEOF(pthread_t, , + [AC_INCLUDES_DEFAULT() + #include ] + ) +fi +AM_CONDITIONAL([PTHREADS], [test "$have_pthreads" != "no" && test "$enable_thread_support" != "no"]) + +# check if we should compile locking into the library +if test x$enable_thread_support = xno; then + AC_DEFINE(DISABLE_THREAD_SUPPORT, 1, + [Define if libevent should not be compiled with thread support]) +fi + +# check if we should hard-code the mm functions. +if test x$enable_malloc_replacement = xno; then + AC_DEFINE(DISABLE_MM_REPLACEMENT, 1, + [Define if libevent should not allow replacing the mm functions]) +fi + +# check if we should hard-code debugging out +if test x$enable_debug_mode = xno; then + AC_DEFINE(DISABLE_DEBUG_MODE, 1, + [Define if libevent should build without support for a debug mode]) +fi + +# check if we should enable verbose debugging +if test x$enable_verbose_debug = xyes; then + CFLAGS="$CFLAGS -DUSE_DEBUG" +fi + +# check if we have and should use openssl +AM_CONDITIONAL(OPENSSL, [test "$enable_openssl" != "no" && test "$have_openssl" = "yes"]) + +# Add some more warnings which we use in development but not in the +# released versions. (Some relevant gcc versions can't handle these.) +if test x$enable_gcc_warnings != xno && test "$GCC" = "yes"; then + + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [ +#if !defined(__GNUC__) || (__GNUC__ < 4) +#error +#endif])], have_gcc4=yes, have_gcc4=no) + + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [ +#if !defined(__GNUC__) || (__GNUC__ < 4) || (__GNUC__ == 4 && __GNUC_MINOR__ < 2) +#error +#endif])], have_gcc42=yes, have_gcc42=no) + + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [ +#if !defined(__GNUC__) || (__GNUC__ < 4) || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) +#error +#endif])], have_gcc45=yes, have_gcc45=no) + + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [ +#if !defined(__clang__) +#error +#endif])], have_clang=yes, have_clang=no) + + CFLAGS="$CFLAGS -W -Wfloat-equal -Wundef -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wwrite-strings -Wredundant-decls -Wchar-subscripts -Wcomment -Wformat -Wwrite-strings -Wmissing-declarations -Wredundant-decls -Wnested-externs -Wbad-function-cast -Wswitch-enum" + if test x$enable_gcc_warnings = xyes; then + CFLAGS="$CFLAGS -Werror" + fi + + CFLAGS="$CFLAGS -Wno-unused-parameter -Wstrict-aliasing" + + if test x$have_gcc4 = xyes ; then + # These warnings break gcc 3.3.5 and work on gcc 4.0.2 + CFLAGS="$CFLAGS -Winit-self -Wmissing-field-initializers -Wdeclaration-after-statement" + #CFLAGS="$CFLAGS -Wold-style-definition" + fi + + if test x$have_gcc42 = xyes ; then + # These warnings break gcc 4.0.2 and work on gcc 4.2 + CFLAGS="$CFLAGS -Waddress" + fi + + if test x$have_gcc42 = xyes && test x$have_clang = xno; then + # These warnings break gcc 4.0.2 and clang, but work on gcc 4.2 + CFLAGS="$CFLAGS -Wnormalized=id -Woverride-init" + fi + + if test x$have_gcc45 = xyes ; then + # These warnings work on gcc 4.5 + CFLAGS="$CFLAGS -Wlogical-op" + fi + + if test x$have_clang = xyes; then + # Disable the unused-function warnings, because these trigger + # for minheap-internal.h related code. + CFLAGS="$CFLAGS -Wno-unused-function" + + # clang on macosx emits warnigns for each directory specified which + # isn't "used" generating a lot of build noise (typically 3 warnings + # per file + case "$host_os" in + darwin*) + CFLAGS="$CFLAGS -Qunused-arguments" + ;; + esac + fi + +##This will break the world on some 64-bit architectures +# CFLAGS="$CFLAGS -Winline" + +fi + +LIBEVENT_GC_SECTIONS= +if test "$GCC" = yes && test "$enable_function_sections" = yes ; then + AC_CACHE_CHECK( + [if linker supports omitting unused code and data], + [libevent_cv_gc_sections_runs], + [ + dnl NetBSD will link but likely not run with --gc-sections + dnl http://bugs.ntp.org/1844 + dnl http://gnats.netbsd.org/40401 + dnl --gc-sections causes attempt to load as linux elf, with + dnl wrong syscalls in place. Test a little gauntlet of + dnl simple stdio read code checking for errors, expecting + dnl enough syscall differences that the NetBSD code will + dnl fail even with Linux emulation working as designed. + dnl A shorter test could be refined by someone with access + dnl to a NetBSD host with Linux emulation working. + origCFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -Wl,--gc-sections" + AC_LINK_IFELSE( + [AC_LANG_PROGRAM( + [[ + #include + #include + ]], + [[ + FILE * fpC; + char buf[32]; + size_t cch; + int read_success_once; + + fpC = fopen("conftest.c", "r"); + if (NULL == fpC) + exit(1); + do { + cch = fread(buf, sizeof(buf), 1, fpC); + read_success_once |= (0 != cch); + } while (0 != cch); + if (!read_success_once) + exit(2); + if (!feof(fpC)) + exit(3); + if (0 != fclose(fpC)) + exit(4); + + exit(EXIT_SUCCESS); + ]] + )], + [ + dnl We have to do this invocation manually so that we can + dnl get the output of conftest.err to make sure it doesn't + dnl mention gc-sections. + if test "X$cross_compiling" = "Xyes" || grep gc-sections conftest.err ; then + libevent_cv_gc_sections_runs=no + else + libevent_cv_gc_sections_runs=no + ./conftest >/dev/null 2>&1 && libevent_cv_gc_sections_runs=yes + fi + ], + [libevent_cv_gc_sections_runs=no] + ) + CFLAGS="$origCFLAGS" + AS_UNSET([origCFLAGS]) + ] + ) + case "$libevent_cv_gc_sections_runs" in + yes) + CFLAGS="-ffunction-sections -fdata-sections $CFLAGS" + LIBEVENT_GC_SECTIONS="-Wl,--gc-sections" + ;; + esac +fi +AC_SUBST([LIBEVENT_GC_SECTIONS]) + +AM_CONDITIONAL([INSTALL_LIBEVENT], [test "$enable_libevent_install" = "yes"]) + +AC_CONFIG_FILES( [libevent.pc libevent_openssl.pc libevent_pthreads.pc] ) +AC_OUTPUT(Makefile) diff --git a/contrib/ntp/sntp/libevent/defer-internal.h b/contrib/ntp/sntp/libevent/defer-internal.h new file mode 100644 index 000000000..d8cf32f44 --- /dev/null +++ b/contrib/ntp/sntp/libevent/defer-internal.h @@ -0,0 +1,70 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef DEFER_INTERNAL_H_INCLUDED_ +#define DEFER_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +struct event_callback; +typedef void (*deferred_cb_fn)(struct event_callback *, void *); + +/** + Initialize an empty, non-pending event_callback. + + @param deferred The struct event_callback structure to initialize. + @param priority The priority that the callback should run at. + @param cb The function to run when the struct event_callback executes. + @param arg The function's second argument. + */ +void event_deferred_cb_init_(struct event_callback *, ev_uint8_t, deferred_cb_fn, void *); +/** + Change the priority of a non-pending event_callback. + */ +void event_deferred_cb_set_priority_(struct event_callback *, ev_uint8_t); +/** + Cancel a struct event_callback if it is currently scheduled in an event_base. + */ +void event_deferred_cb_cancel_(struct event_base *, struct event_callback *); +/** + Activate a struct event_callback if it is not currently scheduled in an event_base. + + Return true iff it was not previously scheduled. + */ +int event_deferred_cb_schedule_(struct event_base *, struct event_callback *); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT_INTERNAL_H_INCLUDED_ */ + diff --git a/contrib/ntp/sntp/libevent/devpoll.c b/contrib/ntp/sntp/libevent/devpoll.c new file mode 100644 index 000000000..3a2f86d6f --- /dev/null +++ b/contrib/ntp/sntp/libevent/devpoll.c @@ -0,0 +1,311 @@ +/* + * Copyright 2000-2009 Niels Provos + * Copyright 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_DEVPOLL + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/thread.h" +#include "event-internal.h" +#include "evsignal-internal.h" +#include "log-internal.h" +#include "evmap-internal.h" +#include "evthread-internal.h" + +struct devpollop { + struct pollfd *events; + int nevents; + int dpfd; + struct pollfd *changes; + int nchanges; +}; + +static void *devpoll_init(struct event_base *); +static int devpoll_add(struct event_base *, int fd, short old, short events, void *); +static int devpoll_del(struct event_base *, int fd, short old, short events, void *); +static int devpoll_dispatch(struct event_base *, struct timeval *); +static void devpoll_dealloc(struct event_base *); + +const struct eventop devpollops = { + "devpoll", + devpoll_init, + devpoll_add, + devpoll_del, + devpoll_dispatch, + devpoll_dealloc, + 1, /* need reinit */ + EV_FEATURE_FDS|EV_FEATURE_O1, + 0 +}; + +#define NEVENT 32000 + +static int +devpoll_commit(struct devpollop *devpollop) +{ + /* + * Due to a bug in Solaris, we have to use pwrite with an offset of 0. + * Write is limited to 2GB of data, until it will fail. + */ + if (pwrite(devpollop->dpfd, devpollop->changes, + sizeof(struct pollfd) * devpollop->nchanges, 0) == -1) + return (-1); + + devpollop->nchanges = 0; + return (0); +} + +static int +devpoll_queue(struct devpollop *devpollop, int fd, int events) { + struct pollfd *pfd; + + if (devpollop->nchanges >= devpollop->nevents) { + /* + * Change buffer is full, must commit it to /dev/poll before + * adding more + */ + if (devpoll_commit(devpollop) != 0) + return (-1); + } + + pfd = &devpollop->changes[devpollop->nchanges++]; + pfd->fd = fd; + pfd->events = events; + pfd->revents = 0; + + return (0); +} + +static void * +devpoll_init(struct event_base *base) +{ + int dpfd, nfiles = NEVENT; + struct rlimit rl; + struct devpollop *devpollop; + + if (!(devpollop = mm_calloc(1, sizeof(struct devpollop)))) + return (NULL); + + if (getrlimit(RLIMIT_NOFILE, &rl) == 0 && + rl.rlim_cur != RLIM_INFINITY) + nfiles = rl.rlim_cur; + + /* Initialize the kernel queue */ + if ((dpfd = evutil_open_closeonexec_("/dev/poll", O_RDWR, 0)) == -1) { + event_warn("open: /dev/poll"); + mm_free(devpollop); + return (NULL); + } + + devpollop->dpfd = dpfd; + + /* Initialize fields */ + /* FIXME: allocating 'nfiles' worth of space here can be + * expensive and unnecessary. See how epoll.c does it instead. */ + devpollop->events = mm_calloc(nfiles, sizeof(struct pollfd)); + if (devpollop->events == NULL) { + mm_free(devpollop); + close(dpfd); + return (NULL); + } + devpollop->nevents = nfiles; + + devpollop->changes = mm_calloc(nfiles, sizeof(struct pollfd)); + if (devpollop->changes == NULL) { + mm_free(devpollop->events); + mm_free(devpollop); + close(dpfd); + return (NULL); + } + + evsig_init_(base); + + return (devpollop); +} + +static int +devpoll_dispatch(struct event_base *base, struct timeval *tv) +{ + struct devpollop *devpollop = base->evbase; + struct pollfd *events = devpollop->events; + struct dvpoll dvp; + int i, res, timeout = -1; + + if (devpollop->nchanges) + devpoll_commit(devpollop); + + if (tv != NULL) + timeout = tv->tv_sec * 1000 + (tv->tv_usec + 999) / 1000; + + dvp.dp_fds = devpollop->events; + dvp.dp_nfds = devpollop->nevents; + dvp.dp_timeout = timeout; + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + res = ioctl(devpollop->dpfd, DP_POLL, &dvp); + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (res == -1) { + if (errno != EINTR) { + event_warn("ioctl: DP_POLL"); + return (-1); + } + + return (0); + } + + event_debug(("%s: devpoll_wait reports %d", __func__, res)); + + for (i = 0; i < res; i++) { + int which = 0; + int what = events[i].revents; + + if (what & POLLHUP) + what |= POLLIN | POLLOUT; + else if (what & POLLERR) + what |= POLLIN | POLLOUT; + + if (what & POLLIN) + which |= EV_READ; + if (what & POLLOUT) + which |= EV_WRITE; + + if (!which) + continue; + + /* XXX(niels): not sure if this works for devpoll */ + evmap_io_active_(base, events[i].fd, which); + } + + return (0); +} + + +static int +devpoll_add(struct event_base *base, int fd, short old, short events, void *p) +{ + struct devpollop *devpollop = base->evbase; + int res; + (void)p; + + /* + * It's not necessary to OR the existing read/write events that we + * are currently interested in with the new event we are adding. + * The /dev/poll driver ORs any new events with the existing events + * that it has cached for the fd. + */ + + res = 0; + if (events & EV_READ) + res |= POLLIN; + if (events & EV_WRITE) + res |= POLLOUT; + + if (devpoll_queue(devpollop, fd, res) != 0) + return (-1); + + return (0); +} + +static int +devpoll_del(struct event_base *base, int fd, short old, short events, void *p) +{ + struct devpollop *devpollop = base->evbase; + int res; + (void)p; + + res = 0; + if (events & EV_READ) + res |= POLLIN; + if (events & EV_WRITE) + res |= POLLOUT; + + /* + * The only way to remove an fd from the /dev/poll monitored set is + * to use POLLREMOVE by itself. This removes ALL events for the fd + * provided so if we care about two events and are only removing one + * we must re-add the other event after POLLREMOVE. + */ + + if (devpoll_queue(devpollop, fd, POLLREMOVE) != 0) + return (-1); + + if ((res & (POLLIN|POLLOUT)) != (POLLIN|POLLOUT)) { + /* + * We're not deleting all events, so we must resubmit the + * event that we are still interested in if one exists. + */ + + if ((res & POLLIN) && (old & EV_WRITE)) { + /* Deleting read, still care about write */ + devpoll_queue(devpollop, fd, POLLOUT); + } else if ((res & POLLOUT) && (old & EV_READ)) { + /* Deleting write, still care about read */ + devpoll_queue(devpollop, fd, POLLIN); + } + } + + return (0); +} + +static void +devpoll_dealloc(struct event_base *base) +{ + struct devpollop *devpollop = base->evbase; + + evsig_dealloc_(base); + if (devpollop->events) + mm_free(devpollop->events); + if (devpollop->changes) + mm_free(devpollop->changes); + if (devpollop->dpfd >= 0) + close(devpollop->dpfd); + + memset(devpollop, 0, sizeof(struct devpollop)); + mm_free(devpollop); +} + +#endif /* EVENT__HAVE_DEVPOLL */ diff --git a/contrib/ntp/sntp/libevent/epoll.c b/contrib/ntp/sntp/libevent/epoll.c new file mode 100644 index 000000000..aa41f84e0 --- /dev/null +++ b/contrib/ntp/sntp/libevent/epoll.c @@ -0,0 +1,541 @@ +/* + * Copyright 2000-2007 Niels Provos + * Copyright 2007-2012 Niels Provos, Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_EPOLL + +#include +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#include +#include +#include +#include +#include +#include +#include +#include +#ifdef EVENT__HAVE_FCNTL_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIMERFD_H +#include +#endif + +#include "event-internal.h" +#include "evsignal-internal.h" +#include "event2/thread.h" +#include "evthread-internal.h" +#include "log-internal.h" +#include "evmap-internal.h" +#include "changelist-internal.h" +#include "time-internal.h" + +/* Since Linux 2.6.17, epoll is able to report about peer half-closed connection + using special EPOLLRDHUP flag on a read event. +*/ +#if !defined(EPOLLRDHUP) +#define EPOLLRDHUP 0 +#define EARLY_CLOSE_IF_HAVE_RDHUP 0 +#else +#define EARLY_CLOSE_IF_HAVE_RDHUP EV_FEATURE_EARLY_CLOSE +#endif + +#include "epolltable-internal.h" + +#if defined(EVENT__HAVE_SYS_TIMERFD_H) && \ + defined(EVENT__HAVE_TIMERFD_CREATE) && \ + defined(HAVE_POSIX_MONOTONIC) && defined(TFD_NONBLOCK) && \ + defined(TFD_CLOEXEC) +/* Note that we only use timerfd if TFD_NONBLOCK and TFD_CLOEXEC are available + and working. This means that we can't support it on 2.6.25 (where timerfd + was introduced) or 2.6.26, since 2.6.27 introduced those flags. + */ +#define USING_TIMERFD +#endif + +struct epollop { + struct epoll_event *events; + int nevents; + int epfd; +#ifdef USING_TIMERFD + int timerfd; +#endif +}; + +static void *epoll_init(struct event_base *); +static int epoll_dispatch(struct event_base *, struct timeval *); +static void epoll_dealloc(struct event_base *); + +static const struct eventop epollops_changelist = { + "epoll (with changelist)", + epoll_init, + event_changelist_add_, + event_changelist_del_, + epoll_dispatch, + epoll_dealloc, + 1, /* need reinit */ + EV_FEATURE_ET|EV_FEATURE_O1| EARLY_CLOSE_IF_HAVE_RDHUP, + EVENT_CHANGELIST_FDINFO_SIZE +}; + + +static int epoll_nochangelist_add(struct event_base *base, evutil_socket_t fd, + short old, short events, void *p); +static int epoll_nochangelist_del(struct event_base *base, evutil_socket_t fd, + short old, short events, void *p); + +const struct eventop epollops = { + "epoll", + epoll_init, + epoll_nochangelist_add, + epoll_nochangelist_del, + epoll_dispatch, + epoll_dealloc, + 1, /* need reinit */ + EV_FEATURE_ET|EV_FEATURE_O1|EV_FEATURE_EARLY_CLOSE, + 0 +}; + +#define INITIAL_NEVENT 32 +#define MAX_NEVENT 4096 + +/* On Linux kernels at least up to 2.6.24.4, epoll can't handle timeout + * values bigger than (LONG_MAX - 999ULL)/HZ. HZ in the wild can be + * as big as 1000, and LONG_MAX can be as small as (1<<31)-1, so the + * largest number of msec we can support here is 2147482. Let's + * round that down by 47 seconds. + */ +#define MAX_EPOLL_TIMEOUT_MSEC (35*60*1000) + +static void * +epoll_init(struct event_base *base) +{ + int epfd = -1; + struct epollop *epollop; + +#ifdef EVENT__HAVE_EPOLL_CREATE1 + /* First, try the shiny new epoll_create1 interface, if we have it. */ + epfd = epoll_create1(EPOLL_CLOEXEC); +#endif + if (epfd == -1) { + /* Initialize the kernel queue using the old interface. (The + size field is ignored since 2.6.8.) */ + if ((epfd = epoll_create(32000)) == -1) { + if (errno != ENOSYS) + event_warn("epoll_create"); + return (NULL); + } + evutil_make_socket_closeonexec(epfd); + } + + if (!(epollop = mm_calloc(1, sizeof(struct epollop)))) { + close(epfd); + return (NULL); + } + + epollop->epfd = epfd; + + /* Initialize fields */ + epollop->events = mm_calloc(INITIAL_NEVENT, sizeof(struct epoll_event)); + if (epollop->events == NULL) { + mm_free(epollop); + close(epfd); + return (NULL); + } + epollop->nevents = INITIAL_NEVENT; + + if ((base->flags & EVENT_BASE_FLAG_EPOLL_USE_CHANGELIST) != 0 || + ((base->flags & EVENT_BASE_FLAG_IGNORE_ENV) == 0 && + evutil_getenv_("EVENT_EPOLL_USE_CHANGELIST") != NULL)) { + + base->evsel = &epollops_changelist; + } + +#ifdef USING_TIMERFD + /* + The epoll interface ordinarily gives us one-millisecond precision, + so on Linux it makes perfect sense to use the CLOCK_MONOTONIC_COARSE + timer. But when the user has set the new PRECISE_TIMER flag for an + event_base, we can try to use timerfd to give them finer granularity. + */ + if ((base->flags & EVENT_BASE_FLAG_PRECISE_TIMER) && + base->monotonic_timer.monotonic_clock == CLOCK_MONOTONIC) { + int fd; + fd = epollop->timerfd = timerfd_create(CLOCK_MONOTONIC, TFD_NONBLOCK|TFD_CLOEXEC); + if (epollop->timerfd >= 0) { + struct epoll_event epev; + memset(&epev, 0, sizeof(epev)); + epev.data.fd = epollop->timerfd; + epev.events = EPOLLIN; + if (epoll_ctl(epollop->epfd, EPOLL_CTL_ADD, fd, &epev) < 0) { + event_warn("epoll_ctl(timerfd)"); + close(fd); + epollop->timerfd = -1; + } + } else { + if (errno != EINVAL && errno != ENOSYS) { + /* These errors probably mean that we were + * compiled with timerfd/TFD_* support, but + * we're running on a kernel that lacks those. + */ + event_warn("timerfd_create"); + } + epollop->timerfd = -1; + } + } else { + epollop->timerfd = -1; + } +#endif + + evsig_init_(base); + + return (epollop); +} + +static const char * +change_to_string(int change) +{ + change &= (EV_CHANGE_ADD|EV_CHANGE_DEL); + if (change == EV_CHANGE_ADD) { + return "add"; + } else if (change == EV_CHANGE_DEL) { + return "del"; + } else if (change == 0) { + return "none"; + } else { + return "???"; + } +} + +static const char * +epoll_op_to_string(int op) +{ + return op == EPOLL_CTL_ADD?"ADD": + op == EPOLL_CTL_DEL?"DEL": + op == EPOLL_CTL_MOD?"MOD": + "???"; +} + +static int +epoll_apply_one_change(struct event_base *base, + struct epollop *epollop, + const struct event_change *ch) +{ + struct epoll_event epev; + int op, events = 0; + int idx; + + idx = EPOLL_OP_TABLE_INDEX(ch); + op = epoll_op_table[idx].op; + events = epoll_op_table[idx].events; + + if (!events) { + EVUTIL_ASSERT(op == 0); + return 0; + } + + if ((ch->read_change|ch->write_change) & EV_CHANGE_ET) + events |= EPOLLET; + + memset(&epev, 0, sizeof(epev)); + epev.data.fd = ch->fd; + epev.events = events; + if (epoll_ctl(epollop->epfd, op, ch->fd, &epev) == 0) { + event_debug(("Epoll %s(%d) on fd %d okay. [old events were %d; read change was %d; write change was %d; close change was %d]", + epoll_op_to_string(op), + (int)epev.events, + (int)ch->fd, + ch->old_events, + ch->read_change, + ch->write_change, + ch->close_change)); + return 0; + } + + switch (op) { + case EPOLL_CTL_MOD: + if (errno == ENOENT) { + /* If a MOD operation fails with ENOENT, the + * fd was probably closed and re-opened. We + * should retry the operation as an ADD. + */ + if (epoll_ctl(epollop->epfd, EPOLL_CTL_ADD, ch->fd, &epev) == -1) { + event_warn("Epoll MOD(%d) on %d retried as ADD; that failed too", + (int)epev.events, ch->fd); + return -1; + } else { + event_debug(("Epoll MOD(%d) on %d retried as ADD; succeeded.", + (int)epev.events, + ch->fd)); + return 0; + } + } + break; + case EPOLL_CTL_ADD: + if (errno == EEXIST) { + /* If an ADD operation fails with EEXIST, + * either the operation was redundant (as with a + * precautionary add), or we ran into a fun + * kernel bug where using dup*() to duplicate the + * same file into the same fd gives you the same epitem + * rather than a fresh one. For the second case, + * we must retry with MOD. */ + if (epoll_ctl(epollop->epfd, EPOLL_CTL_MOD, ch->fd, &epev) == -1) { + event_warn("Epoll ADD(%d) on %d retried as MOD; that failed too", + (int)epev.events, ch->fd); + return -1; + } else { + event_debug(("Epoll ADD(%d) on %d retried as MOD; succeeded.", + (int)epev.events, + ch->fd)); + return 0; + } + } + break; + case EPOLL_CTL_DEL: + if (errno == ENOENT || errno == EBADF || errno == EPERM) { + /* If a delete fails with one of these errors, + * that's fine too: we closed the fd before we + * got around to calling epoll_dispatch. */ + event_debug(("Epoll DEL(%d) on fd %d gave %s: DEL was unnecessary.", + (int)epev.events, + ch->fd, + strerror(errno))); + return 0; + } + break; + default: + break; + } + + event_warn("Epoll %s(%d) on fd %d failed. Old events were %d; read change was %d (%s); write change was %d (%s); close change was %d (%s)", + epoll_op_to_string(op), + (int)epev.events, + ch->fd, + ch->old_events, + ch->read_change, + change_to_string(ch->read_change), + ch->write_change, + change_to_string(ch->write_change), + ch->close_change, + change_to_string(ch->close_change)); + + return -1; +} + +static int +epoll_apply_changes(struct event_base *base) +{ + struct event_changelist *changelist = &base->changelist; + struct epollop *epollop = base->evbase; + struct event_change *ch; + + int r = 0; + int i; + + for (i = 0; i < changelist->n_changes; ++i) { + ch = &changelist->changes[i]; + if (epoll_apply_one_change(base, epollop, ch) < 0) + r = -1; + } + + return (r); +} + +static int +epoll_nochangelist_add(struct event_base *base, evutil_socket_t fd, + short old, short events, void *p) +{ + struct event_change ch; + ch.fd = fd; + ch.old_events = old; + ch.read_change = ch.write_change = ch.close_change = 0; + if (events & EV_WRITE) + ch.write_change = EV_CHANGE_ADD | + (events & EV_ET); + if (events & EV_READ) + ch.read_change = EV_CHANGE_ADD | + (events & EV_ET); + if (events & EV_CLOSED) + ch.close_change = EV_CHANGE_ADD | + (events & EV_ET); + + return epoll_apply_one_change(base, base->evbase, &ch); +} + +static int +epoll_nochangelist_del(struct event_base *base, evutil_socket_t fd, + short old, short events, void *p) +{ + struct event_change ch; + ch.fd = fd; + ch.old_events = old; + ch.read_change = ch.write_change = ch.close_change = 0; + if (events & EV_WRITE) + ch.write_change = EV_CHANGE_DEL; + if (events & EV_READ) + ch.read_change = EV_CHANGE_DEL; + if (events & EV_CLOSED) + ch.close_change = EV_CHANGE_DEL; + + return epoll_apply_one_change(base, base->evbase, &ch); +} + +static int +epoll_dispatch(struct event_base *base, struct timeval *tv) +{ + struct epollop *epollop = base->evbase; + struct epoll_event *events = epollop->events; + int i, res; + long timeout = -1; + +#ifdef USING_TIMERFD + if (epollop->timerfd >= 0) { + struct itimerspec is; + is.it_interval.tv_sec = 0; + is.it_interval.tv_nsec = 0; + if (tv == NULL) { + /* No timeout; disarm the timer. */ + is.it_value.tv_sec = 0; + is.it_value.tv_nsec = 0; + } else { + if (tv->tv_sec == 0 && tv->tv_usec == 0) { + /* we need to exit immediately; timerfd can't + * do that. */ + timeout = 0; + } + is.it_value.tv_sec = tv->tv_sec; + is.it_value.tv_nsec = tv->tv_usec * 1000; + } + /* TODO: we could avoid unnecessary syscalls here by only + calling timerfd_settime when the top timeout changes, or + when we're called with a different timeval. + */ + if (timerfd_settime(epollop->timerfd, 0, &is, NULL) < 0) { + event_warn("timerfd_settime"); + } + } else +#endif + if (tv != NULL) { + timeout = evutil_tv_to_msec_(tv); + if (timeout < 0 || timeout > MAX_EPOLL_TIMEOUT_MSEC) { + /* Linux kernels can wait forever if the timeout is + * too big; see comment on MAX_EPOLL_TIMEOUT_MSEC. */ + timeout = MAX_EPOLL_TIMEOUT_MSEC; + } + } + + epoll_apply_changes(base); + event_changelist_remove_all_(&base->changelist, base); + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + res = epoll_wait(epollop->epfd, events, epollop->nevents, timeout); + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (res == -1) { + if (errno != EINTR) { + event_warn("epoll_wait"); + return (-1); + } + + return (0); + } + + event_debug(("%s: epoll_wait reports %d", __func__, res)); + EVUTIL_ASSERT(res <= epollop->nevents); + + for (i = 0; i < res; i++) { + int what = events[i].events; + short ev = 0; +#ifdef USING_TIMERFD + if (events[i].data.fd == epollop->timerfd) + continue; +#endif + + if (what & (EPOLLHUP|EPOLLERR)) { + ev = EV_READ | EV_WRITE; + } else { + if (what & EPOLLIN) + ev |= EV_READ; + if (what & EPOLLOUT) + ev |= EV_WRITE; + if (what & EPOLLRDHUP) + ev |= EV_CLOSED; + } + + if (!ev) + continue; + + evmap_io_active_(base, events[i].data.fd, ev | EV_ET); + } + + if (res == epollop->nevents && epollop->nevents < MAX_NEVENT) { + /* We used all of the event space this time. We should + be ready for more events next time. */ + int new_nevents = epollop->nevents * 2; + struct epoll_event *new_events; + + new_events = mm_realloc(epollop->events, + new_nevents * sizeof(struct epoll_event)); + if (new_events) { + epollop->events = new_events; + epollop->nevents = new_nevents; + } + } + + return (0); +} + + +static void +epoll_dealloc(struct event_base *base) +{ + struct epollop *epollop = base->evbase; + + evsig_dealloc_(base); + if (epollop->events) + mm_free(epollop->events); + if (epollop->epfd >= 0) + close(epollop->epfd); +#ifdef USING_TIMERFD + if (epollop->timerfd >= 0) + close(epollop->timerfd); +#endif + + memset(epollop, 0, sizeof(struct epollop)); + mm_free(epollop); +} + +#endif /* EVENT__HAVE_EPOLL */ diff --git a/contrib/ntp/sntp/libevent/epoll_sub.c b/contrib/ntp/sntp/libevent/epoll_sub.c new file mode 100644 index 000000000..3f01f6a69 --- /dev/null +++ b/contrib/ntp/sntp/libevent/epoll_sub.c @@ -0,0 +1,66 @@ +/* + * Copyright 2003-2009 Niels Provos + * Copyright 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "evconfig-private.h" +#include + +#include +#include +#include +#include +#include +#include + +int +epoll_create(int size) +{ +#if !defined(__NR_epoll_create) && defined(__NR_epoll_create1) + if (size <= 0) { + errno = EINVAL; + return -1; + } + return (syscall(__NR_epoll_create1, 0)); +#else + return (syscall(__NR_epoll_create, size)); +#endif +} + +int +epoll_ctl(int epfd, int op, int fd, struct epoll_event *event) +{ + + return (syscall(__NR_epoll_ctl, epfd, op, fd, event)); +} + +int +epoll_wait(int epfd, struct epoll_event *events, int maxevents, int timeout) +{ +#if !defined(__NR_epoll_wait) && defined(__NR_epoll_pwait) + return (syscall(__NR_epoll_pwait, epfd, events, maxevents, timeout, NULL, 0)); +#else + return (syscall(__NR_epoll_wait, epfd, events, maxevents, timeout)); +#endif +} diff --git a/contrib/ntp/sntp/libevent/epolltable-internal.h b/contrib/ntp/sntp/libevent/epolltable-internal.h new file mode 100644 index 000000000..da30e0973 --- /dev/null +++ b/contrib/ntp/sntp/libevent/epolltable-internal.h @@ -0,0 +1,1166 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EPOLLTABLE_INTERNAL_H_INCLUDED_ +#define EPOLLTABLE_INTERNAL_H_INCLUDED_ + +/* + Here are the values we're masking off to decide what operations to do. + Note that since EV_READ|EV_WRITE. + + Note also that this table is a little sparse, since ADD+DEL is + nonsensical ("xxx" in the list below.) + + Note also also that we are shifting old_events by only 5 bits, since + EV_READ is 2 and EV_WRITE is 4. + + The table was auto-generated with a python script, according to this + pseudocode:[*0] + + If either the read or the write change is add+del: + This is impossible; Set op==-1, events=0. + Else, if either the read or the write change is add: + Set events to 0. + If the read change is add, or + (the read change is not del, and ev_read is in old_events): + Add EPOLLIN to events. + If the write change is add, or + (the write change is not del, and ev_write is in old_events): + Add EPOLLOUT to events. + + If old_events is set: + Set op to EPOLL_CTL_MOD [*1,*2] + Else: + Set op to EPOLL_CTL_ADD [*3] + + Else, if the read or the write change is del: + Set op to EPOLL_CTL_DEL. + If the read change is del: + If the write change is del: + Set events to EPOLLIN|EPOLLOUT + Else if ev_write is in old_events: + Set events to EPOLLOUT + Set op to EPOLL_CTL_MOD + Else + Set events to EPOLLIN + Else: + {The write change is del.} + If ev_read is in old_events: + Set events to EPOLLIN + Set op to EPOLL_CTL_MOD + Else: + Set the events to EPOLLOUT + + Else: + There is no read or write change; set op to 0 and events to 0. + + The logic is a little tricky, since we had no events set on the fd before, + we need to set op="ADD" and set events=the events we want to add. If we + had any events set on the fd before, and we want any events to remain on + the fd, we need to say op="MOD" and set events=the events we want to + remain. But if we want to delete the last event, we say op="DEL" and + set events=(any non-null pointer). + + [*0] Actually, the Python script has gotten a bit more complicated, to + support EPOLLRDHUP. + + [*1] This MOD is only a guess. MOD might fail with ENOENT if the file was + closed and a new file was opened with the same fd. If so, we'll retry + with ADD. + + [*2] We can't replace this with a no-op even if old_events is the same as + the new events: if the file was closed and reopened, we need to retry + with an ADD. (We do a MOD in this case since "no change" is more + common than "close and reopen", so we'll usually wind up doing 1 + syscalls instead of 2.) + + [*3] This ADD is only a guess. There is a fun Linux kernel issue where if + you have two fds for the same file (via dup) and you ADD one to an + epfd, then close it, then re-create it with the same fd (via dup2 or an + unlucky dup), then try to ADD it again, you'll get an EEXIST, since the + struct epitem is not actually removed from the struct eventpoll until + the file itself is closed. + + EV_CHANGE_ADD==1 + EV_CHANGE_DEL==2 + EV_READ ==2 + EV_WRITE ==4 + EV_CLOSED ==0x80 + + Bit 0: close change is add + Bit 1: close change is del + Bit 2: read change is add + Bit 3: read change is del + Bit 4: write change is add + Bit 5: write change is del + Bit 6: old events had EV_READ + Bit 7: old events had EV_WRITE + Bit 8: old events had EV_CLOSED +*/ + +#define EPOLL_OP_TABLE_INDEX(c) \ + ( (((c)->close_change&(EV_CHANGE_ADD|EV_CHANGE_DEL))) | \ + (((c)->read_change&(EV_CHANGE_ADD|EV_CHANGE_DEL)) << 2) | \ + (((c)->write_change&(EV_CHANGE_ADD|EV_CHANGE_DEL)) << 4) | \ + (((c)->old_events&(EV_READ|EV_WRITE)) << 5) | \ + (((c)->old_events&(EV_CLOSED)) << 1) \ + ) + +#if EV_READ != 2 || EV_WRITE != 4 || EV_CLOSED != 0x80 || EV_CHANGE_ADD != 1 || EV_CHANGE_DEL != 2 +#error "Libevent's internals changed! Regenerate the op_table in epolltable-internal.h" +#endif + +static const struct operation { + int events; + int op; +} epoll_op_table[] = { + /* old= 0, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old= 0, write: 0, read: 0, close:add */ + { EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write: 0, read: 0, close:del */ + { EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= 0, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old= 0, write: 0, read:add, close: 0 */ + { EPOLLIN, EPOLL_CTL_ADD }, + /* old= 0, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write: 0, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_ADD }, + /* old= 0, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old= 0, write: 0, read:del, close: 0 */ + { EPOLLIN, EPOLL_CTL_DEL }, + /* old= 0, write: 0, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write: 0, read:del, close:del */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= 0, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old= 0, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old= 0, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old= 0, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old= 0, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old= 0, write:add, read: 0, close: 0 */ + { EPOLLOUT, EPOLL_CTL_ADD }, + /* old= 0, write:add, read: 0, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write:add, read: 0, close:del */ + { EPOLLOUT, EPOLL_CTL_ADD }, + /* old= 0, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old= 0, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_ADD }, + /* old= 0, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_ADD }, + /* old= 0, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old= 0, write:add, read:del, close: 0 */ + { EPOLLOUT, EPOLL_CTL_ADD }, + /* old= 0, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_ADD }, + /* old= 0, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old= 0, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old= 0, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old= 0, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old= 0, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old= 0, write:del, read: 0, close: 0 */ + { EPOLLOUT, EPOLL_CTL_DEL }, + /* old= 0, write:del, read: 0, close:add */ + { EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write:del, read: 0, close:del */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= 0, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old= 0, write:del, read:add, close: 0 */ + { EPOLLIN, EPOLL_CTL_ADD }, + /* old= 0, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_ADD }, + /* old= 0, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old= 0, write:del, read:del, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL }, + /* old= 0, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_ADD }, + /* old= 0, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= 0, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old= 0, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old= 0, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old= 0, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old= 0, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old= 0, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old= 0, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old= 0, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old= 0, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old= 0, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old= 0, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old= 0, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old= 0, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old= 0, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old= 0, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old= 0, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old= 0, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old= 0, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old= 0, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old= 0, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old= 0, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, + /* old= r, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old= r, write: 0, read: 0, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write: 0, read: 0, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= r, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old= r, write: 0, read:add, close: 0 */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= r, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write: 0, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= r, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old= r, write: 0, read:del, close: 0 */ + { EPOLLIN, EPOLL_CTL_DEL }, + /* old= r, write: 0, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write: 0, read:del, close:del */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= r, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old= r, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old= r, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old= r, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old= r, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old= r, write:add, read: 0, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= r, write:add, read: 0, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write:add, read: 0, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= r, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old= r, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= r, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= r, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old= r, write:add, read:del, close: 0 */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= r, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= r, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old= r, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old= r, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old= r, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old= r, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old= r, write:del, read: 0, close: 0 */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= r, write:del, read: 0, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write:del, read: 0, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= r, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old= r, write:del, read:add, close: 0 */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= r, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= r, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old= r, write:del, read:del, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL }, + /* old= r, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= r, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= r, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old= r, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old= r, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old= r, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old= r, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old= r, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old= r, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old= r, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old= r, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old= r, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old= r, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old= r, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old= r, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old= r, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old= r, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old= r, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old= r, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old= r, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old= r, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old= r, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old= r, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, + /* old= w, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old= w, write: 0, read: 0, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write: 0, read: 0, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old= w, write: 0, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write: 0, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old= w, write: 0, read:del, close: 0 */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write: 0, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write: 0, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old= w, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old= w, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old= w, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old= w, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old= w, write:add, read: 0, close: 0 */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write:add, read: 0, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write:add, read: 0, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old= w, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old= w, write:add, read:del, close: 0 */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= w, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old= w, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old= w, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old= w, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old= w, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old= w, write:del, read: 0, close: 0 */ + { EPOLLOUT, EPOLL_CTL_DEL }, + /* old= w, write:del, read: 0, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write:del, read: 0, close:del */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= w, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old= w, write:del, read:add, close: 0 */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= w, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= w, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old= w, write:del, read:del, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL }, + /* old= w, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= w, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= w, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old= w, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old= w, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old= w, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old= w, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old= w, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old= w, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old= w, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old= w, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old= w, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old= w, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old= w, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old= w, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old= w, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old= w, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old= w, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old= w, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old= w, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old= w, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old= w, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old= w, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, + /* old= rw, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old= rw, write: 0, read: 0, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read: 0, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old= rw, write: 0, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old= rw, write: 0, read:del, close: 0 */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old= rw, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old= rw, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old= rw, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old= rw, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old= rw, write:add, read: 0, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write:add, read: 0, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write:add, read: 0, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old= rw, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old= rw, write:add, read:del, close: 0 */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= rw, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old= rw, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old= rw, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old= rw, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old= rw, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old= rw, write:del, read: 0, close: 0 */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= rw, write:del, read: 0, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write:del, read: 0, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= rw, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old= rw, write:del, read:add, close: 0 */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= rw, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= rw, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old= rw, write:del, read:del, close: 0 */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_DEL }, + /* old= rw, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= rw, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= rw, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old= rw, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old= rw, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old= rw, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old= rw, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old= rw, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old= rw, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old= rw, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old= rw, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old= rw, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old= rw, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old= rw, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old= rw, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old= rw, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old= rw, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old= rw, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old= rw, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old= rw, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old= rw, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old= rw, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old= rw, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, + /* old= c, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old= c, write: 0, read: 0, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write: 0, read: 0, close:del */ + { EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= c, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old= c, write: 0, read:add, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write: 0, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= c, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old= c, write: 0, read:del, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write: 0, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write: 0, read:del, close:del */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= c, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old= c, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old= c, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old= c, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old= c, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old= c, write:add, read: 0, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:add, read: 0, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:add, read: 0, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= c, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old= c, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= c, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old= c, write:add, read:del, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= c, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old= c, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old= c, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old= c, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old= c, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old= c, write:del, read: 0, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:del, read: 0, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:del, read: 0, close:del */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= c, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old= c, write:del, read:add, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= c, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old= c, write:del, read:del, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= c, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= c, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old= c, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old= c, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old= c, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old= c, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old= c, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old= c, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old= c, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old= c, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old= c, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old= c, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old= c, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old= c, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old= c, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old= c, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old= c, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old= c, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old= c, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old= c, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old= c, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old= c, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cr, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old= cr, write: 0, read: 0, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write: 0, read: 0, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= cr, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old= cr, write: 0, read:add, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write: 0, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= cr, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old= cr, write: 0, read:del, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write: 0, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write: 0, read:del, close:del */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= cr, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old= cr, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cr, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old= cr, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old= cr, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cr, write:add, read: 0, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:add, read: 0, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:add, read: 0, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cr, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old= cr, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cr, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old= cr, write:add, read:del, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cr, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old= cr, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cr, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old= cr, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old= cr, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cr, write:del, read: 0, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:del, read: 0, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:del, read: 0, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= cr, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old= cr, write:del, read:add, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= cr, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old= cr, write:del, read:del, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cr, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= cr, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old= cr, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cr, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old= cr, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old= cr, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cr, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old= cr, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old= cr, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old= cr, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old= cr, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old= cr, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old= cr, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old= cr, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old= cr, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old= cr, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old= cr, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old= cr, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old= cr, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cr, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old= cr, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old= cr, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cw, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old= cw, write: 0, read: 0, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read: 0, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old= cw, write: 0, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old= cw, write: 0, read:del, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cw, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old= cw, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cw, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old= cw, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old= cw, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cw, write:add, read: 0, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:add, read: 0, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:add, read: 0, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cw, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old= cw, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cw, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old= cw, write:add, read:del, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old= cw, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old= cw, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cw, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old= cw, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old= cw, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cw, write:del, read: 0, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:del, read: 0, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:del, read: 0, close:del */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= cw, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old= cw, write:del, read:add, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old= cw, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old= cw, write:del, read:del, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old= cw, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old= cw, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old= cw, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cw, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old= cw, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old= cw, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old= cw, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old= cw, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old= cw, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old= cw, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old= cw, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old= cw, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old= cw, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old= cw, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old= cw, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old= cw, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old= cw, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old= cw, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old= cw, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old= cw, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old= cw, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old= cw, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, + /* old=crw, write: 0, read: 0, close: 0 */ + { 0, 0 }, + /* old=crw, write: 0, read: 0, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read: 0, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read: 0, close:xxx */ + { 0, 255 }, + /* old=crw, write: 0, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read:add, close:xxx */ + { 0, 255 }, + /* old=crw, write: 0, read:del, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old=crw, write: 0, read:del, close:xxx */ + { 0, 255 }, + /* old=crw, write: 0, read:xxx, close: 0 */ + { 0, 255 }, + /* old=crw, write: 0, read:xxx, close:add */ + { 0, 255 }, + /* old=crw, write: 0, read:xxx, close:del */ + { 0, 255 }, + /* old=crw, write: 0, read:xxx, close:xxx */ + { 0, 255 }, + /* old=crw, write:add, read: 0, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:add, read: 0, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:add, read: 0, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old=crw, write:add, read: 0, close:xxx */ + { 0, 255 }, + /* old=crw, write:add, read:add, close: 0 */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:add, read:add, close:add */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:add, read:add, close:del */ + { EPOLLIN|EPOLLOUT, EPOLL_CTL_MOD }, + /* old=crw, write:add, read:add, close:xxx */ + { 0, 255 }, + /* old=crw, write:add, read:del, close: 0 */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:add, read:del, close:add */ + { EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:add, read:del, close:del */ + { EPOLLOUT, EPOLL_CTL_MOD }, + /* old=crw, write:add, read:del, close:xxx */ + { 0, 255 }, + /* old=crw, write:add, read:xxx, close: 0 */ + { 0, 255 }, + /* old=crw, write:add, read:xxx, close:add */ + { 0, 255 }, + /* old=crw, write:add, read:xxx, close:del */ + { 0, 255 }, + /* old=crw, write:add, read:xxx, close:xxx */ + { 0, 255 }, + /* old=crw, write:del, read: 0, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:del, read: 0, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:del, read: 0, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old=crw, write:del, read: 0, close:xxx */ + { 0, 255 }, + /* old=crw, write:del, read:add, close: 0 */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:del, read:add, close:add */ + { EPOLLIN|EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:del, read:add, close:del */ + { EPOLLIN, EPOLL_CTL_MOD }, + /* old=crw, write:del, read:add, close:xxx */ + { 0, 255 }, + /* old=crw, write:del, read:del, close: 0 */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:del, read:del, close:add */ + { EPOLLRDHUP, EPOLL_CTL_MOD }, + /* old=crw, write:del, read:del, close:del */ + { EPOLLIN|EPOLLOUT|EPOLLRDHUP, EPOLL_CTL_DEL }, + /* old=crw, write:del, read:del, close:xxx */ + { 0, 255 }, + /* old=crw, write:del, read:xxx, close: 0 */ + { 0, 255 }, + /* old=crw, write:del, read:xxx, close:add */ + { 0, 255 }, + /* old=crw, write:del, read:xxx, close:del */ + { 0, 255 }, + /* old=crw, write:del, read:xxx, close:xxx */ + { 0, 255 }, + /* old=crw, write:xxx, read: 0, close: 0 */ + { 0, 255 }, + /* old=crw, write:xxx, read: 0, close:add */ + { 0, 255 }, + /* old=crw, write:xxx, read: 0, close:del */ + { 0, 255 }, + /* old=crw, write:xxx, read: 0, close:xxx */ + { 0, 255 }, + /* old=crw, write:xxx, read:add, close: 0 */ + { 0, 255 }, + /* old=crw, write:xxx, read:add, close:add */ + { 0, 255 }, + /* old=crw, write:xxx, read:add, close:del */ + { 0, 255 }, + /* old=crw, write:xxx, read:add, close:xxx */ + { 0, 255 }, + /* old=crw, write:xxx, read:del, close: 0 */ + { 0, 255 }, + /* old=crw, write:xxx, read:del, close:add */ + { 0, 255 }, + /* old=crw, write:xxx, read:del, close:del */ + { 0, 255 }, + /* old=crw, write:xxx, read:del, close:xxx */ + { 0, 255 }, + /* old=crw, write:xxx, read:xxx, close: 0 */ + { 0, 255 }, + /* old=crw, write:xxx, read:xxx, close:add */ + { 0, 255 }, + /* old=crw, write:xxx, read:xxx, close:del */ + { 0, 255 }, + /* old=crw, write:xxx, read:xxx, close:xxx */ + { 0, 255 }, +}; + +#endif diff --git a/contrib/ntp/sntp/libevent/evbuffer-internal.h b/contrib/ntp/sntp/libevent/evbuffer-internal.h new file mode 100644 index 000000000..cf4bddc80 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evbuffer-internal.h @@ -0,0 +1,351 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVBUFFER_INTERNAL_H_INCLUDED_ +#define EVBUFFER_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "event2/event-config.h" +#include "evconfig-private.h" +#include "event2/util.h" +#include "event2/event_struct.h" +#include "util-internal.h" +#include "defer-internal.h" + +/* Experimental cb flag: "never deferred." Implementation note: + * these callbacks may get an inaccurate view of n_del/n_added in their + * arguments. */ +#define EVBUFFER_CB_NODEFER 2 + +#ifdef _WIN32 +#include +#endif +#include + +/* Minimum allocation for a chain. We define this so that we're burning no + * more than 5% of each allocation on overhead. It would be nice to lose even + * less space, though. */ +#if EVENT__SIZEOF_VOID_P < 8 +#define MIN_BUFFER_SIZE 512 +#else +#define MIN_BUFFER_SIZE 1024 +#endif + +/** A single evbuffer callback for an evbuffer. This function will be invoked + * when bytes are added to or removed from the evbuffer. */ +struct evbuffer_cb_entry { + /** Structures to implement a doubly-linked queue of callbacks */ + LIST_ENTRY(evbuffer_cb_entry) next; + /** The callback function to invoke when this callback is called. + If EVBUFFER_CB_OBSOLETE is set in flags, the cb_obsolete field is + valid; otherwise, cb_func is valid. */ + union { + evbuffer_cb_func cb_func; + evbuffer_cb cb_obsolete; + } cb; + /** Argument to pass to cb. */ + void *cbarg; + /** Currently set flags on this callback. */ + ev_uint32_t flags; +}; + +struct bufferevent; +struct evbuffer_chain; +struct evbuffer { + /** The first chain in this buffer's linked list of chains. */ + struct evbuffer_chain *first; + /** The last chain in this buffer's linked list of chains. */ + struct evbuffer_chain *last; + + /** Pointer to the next pointer pointing at the 'last_with_data' chain. + * + * To unpack: + * + * The last_with_data chain is the last chain that has any data in it. + * If all chains in the buffer are empty, it is the first chain. + * If the buffer has no chains, it is NULL. + * + * The last_with_datap pointer points at _whatever 'next' pointer_ + * points at the last_with_datap chain. If the last_with_data chain + * is the first chain, or it is NULL, then the last_with_datap pointer + * is &buf->first. + */ + struct evbuffer_chain **last_with_datap; + + /** Total amount of bytes stored in all chains.*/ + size_t total_len; + + /** Number of bytes we have added to the buffer since we last tried to + * invoke callbacks. */ + size_t n_add_for_cb; + /** Number of bytes we have removed from the buffer since we last + * tried to invoke callbacks. */ + size_t n_del_for_cb; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + /** A lock used to mediate access to this buffer. */ + void *lock; +#endif + /** True iff we should free the lock field when we free this + * evbuffer. */ + unsigned own_lock : 1; + /** True iff we should not allow changes to the front of the buffer + * (drains or prepends). */ + unsigned freeze_start : 1; + /** True iff we should not allow changes to the end of the buffer + * (appends) */ + unsigned freeze_end : 1; + /** True iff this evbuffer's callbacks are not invoked immediately + * upon a change in the buffer, but instead are deferred to be invoked + * from the event_base's loop. Useful for preventing enormous stack + * overflows when we have mutually recursive callbacks, and for + * serializing callbacks in a single thread. */ + unsigned deferred_cbs : 1; +#ifdef _WIN32 + /** True iff this buffer is set up for overlapped IO. */ + unsigned is_overlapped : 1; +#endif + /** Zero or more EVBUFFER_FLAG_* bits */ + ev_uint32_t flags; + + /** Used to implement deferred callbacks. */ + struct event_base *cb_queue; + + /** A reference count on this evbuffer. When the reference count + * reaches 0, the buffer is destroyed. Manipulated with + * evbuffer_incref and evbuffer_decref_and_unlock and + * evbuffer_free. */ + int refcnt; + + /** A struct event_callback handle to make all of this buffer's callbacks + * invoked from the event loop. */ + struct event_callback deferred; + + /** A doubly-linked-list of callback functions */ + LIST_HEAD(evbuffer_cb_queue, evbuffer_cb_entry) callbacks; + + /** The parent bufferevent object this evbuffer belongs to. + * NULL if the evbuffer stands alone. */ + struct bufferevent *parent; +}; + +#if EVENT__SIZEOF_OFF_T < EVENT__SIZEOF_SIZE_T +typedef ev_ssize_t ev_misalign_t; +#define EVBUFFER_CHAIN_MAX ((size_t)EV_SSIZE_MAX) +#else +typedef ev_off_t ev_misalign_t; +#if EVENT__SIZEOF_OFF_T > EVENT__SIZEOF_SIZE_T +#define EVBUFFER_CHAIN_MAX EV_SIZE_MAX +#else +#define EVBUFFER_CHAIN_MAX ((size_t)EV_SSIZE_MAX) +#endif +#endif + +/** A single item in an evbuffer. */ +struct evbuffer_chain { + /** points to next buffer in the chain */ + struct evbuffer_chain *next; + + /** total allocation available in the buffer field. */ + size_t buffer_len; + + /** unused space at the beginning of buffer or an offset into a + * file for sendfile buffers. */ + ev_misalign_t misalign; + + /** Offset into buffer + misalign at which to start writing. + * In other words, the total number of bytes actually stored + * in buffer. */ + size_t off; + + /** Set if special handling is required for this chain */ + unsigned flags; +#define EVBUFFER_FILESEGMENT 0x0001 /**< A chain used for a file segment */ +#define EVBUFFER_SENDFILE 0x0002 /**< a chain used with sendfile */ +#define EVBUFFER_REFERENCE 0x0004 /**< a chain with a mem reference */ +#define EVBUFFER_IMMUTABLE 0x0008 /**< read-only chain */ + /** a chain that mustn't be reallocated or freed, or have its contents + * memmoved, until the chain is un-pinned. */ +#define EVBUFFER_MEM_PINNED_R 0x0010 +#define EVBUFFER_MEM_PINNED_W 0x0020 +#define EVBUFFER_MEM_PINNED_ANY (EVBUFFER_MEM_PINNED_R|EVBUFFER_MEM_PINNED_W) + /** a chain that should be freed, but can't be freed until it is + * un-pinned. */ +#define EVBUFFER_DANGLING 0x0040 + /** a chain that is a referenced copy of another chain */ +#define EVBUFFER_MULTICAST 0x0080 + + /** number of references to this chain */ + int refcnt; + + /** Usually points to the read-write memory belonging to this + * buffer allocated as part of the evbuffer_chain allocation. + * For mmap, this can be a read-only buffer and + * EVBUFFER_IMMUTABLE will be set in flags. For sendfile, it + * may point to NULL. + */ + unsigned char *buffer; +}; + +/** callback for a reference chain; lets us know what to do with it when + * we're done with it. Lives at the end of an evbuffer_chain with the + * EVBUFFER_REFERENCE flag set */ +struct evbuffer_chain_reference { + evbuffer_ref_cleanup_cb cleanupfn; + void *extra; +}; + +/** File segment for a file-segment chain. Lives at the end of an + * evbuffer_chain with the EVBUFFER_FILESEGMENT flag set. */ +struct evbuffer_chain_file_segment { + struct evbuffer_file_segment *segment; +#ifdef _WIN32 + /** If we're using CreateFileMapping, this is the handle to the view. */ + HANDLE view_handle; +#endif +}; + +/* Declared in event2/buffer.h; defined here. */ +struct evbuffer_file_segment { + void *lock; /**< lock prevent concurrent access to refcnt */ + int refcnt; /**< Reference count for this file segment */ + unsigned flags; /**< combination of EVBUF_FS_* flags */ + + /** What kind of file segment is this? */ + unsigned can_sendfile : 1; + unsigned is_mapping : 1; + + /** The fd that we read the data from. */ + int fd; + /** If we're using mmap, this is the raw mapped memory. */ + void *mapping; +#ifdef _WIN32 + /** If we're using CreateFileMapping, this is the mapping */ + HANDLE mapping_handle; +#endif + /** If we're using mmap or IO, this is the content of the file + * segment. */ + char *contents; + /** Position of this segment within the file. */ + ev_off_t file_offset; + /** If we're using mmap, this is the offset within 'mapping' where + * this data segment begins. */ + ev_off_t mmap_offset; + /** The length of this segment. */ + ev_off_t length; + /** Cleanup callback function */ + evbuffer_file_segment_cleanup_cb cleanup_cb; + /** Argument to be pass to cleanup callback function */ + void *cleanup_cb_arg; +}; + +/** Information about the multicast parent of a chain. Lives at the + * end of an evbuffer_chain with the EVBUFFER_MULTICAST flag set. */ +struct evbuffer_multicast_parent { + /** source buffer the multicast parent belongs to */ + struct evbuffer *source; + /** multicast parent for this chain */ + struct evbuffer_chain *parent; +}; + +#define EVBUFFER_CHAIN_SIZE sizeof(struct evbuffer_chain) +/** Return a pointer to extra data allocated along with an evbuffer. */ +#define EVBUFFER_CHAIN_EXTRA(t, c) (t *)((struct evbuffer_chain *)(c) + 1) + +/** Assert that we are holding the lock on an evbuffer */ +#define ASSERT_EVBUFFER_LOCKED(buffer) \ + EVLOCK_ASSERT_LOCKED((buffer)->lock) + +#define EVBUFFER_LOCK(buffer) \ + do { \ + EVLOCK_LOCK((buffer)->lock, 0); \ + } while (0) +#define EVBUFFER_UNLOCK(buffer) \ + do { \ + EVLOCK_UNLOCK((buffer)->lock, 0); \ + } while (0) +#define EVBUFFER_LOCK2(buffer1, buffer2) \ + do { \ + EVLOCK_LOCK2((buffer1)->lock, (buffer2)->lock, 0, 0); \ + } while (0) +#define EVBUFFER_UNLOCK2(buffer1, buffer2) \ + do { \ + EVLOCK_UNLOCK2((buffer1)->lock, (buffer2)->lock, 0, 0); \ + } while (0) + +/** Increase the reference count of buf by one. */ +void evbuffer_incref_(struct evbuffer *buf); +/** Increase the reference count of buf by one and acquire the lock. */ +void evbuffer_incref_and_lock_(struct evbuffer *buf); +/** Pin a single buffer chain using a given flag. A pinned chunk may not be + * moved or freed until it is unpinned. */ +void evbuffer_chain_pin_(struct evbuffer_chain *chain, unsigned flag); +/** Unpin a single buffer chain using a given flag. */ +void evbuffer_chain_unpin_(struct evbuffer_chain *chain, unsigned flag); +/** As evbuffer_free, but requires that we hold a lock on the buffer, and + * releases the lock before freeing it and the buffer. */ +void evbuffer_decref_and_unlock_(struct evbuffer *buffer); + +/** As evbuffer_expand, but does not guarantee that the newly allocated memory + * is contiguous. Instead, it may be split across two or more chunks. */ +int evbuffer_expand_fast_(struct evbuffer *, size_t, int); + +/** Helper: prepares for a readv/WSARecv call by expanding the buffer to + * hold enough memory to read 'howmuch' bytes in possibly noncontiguous memory. + * Sets up the one or two iovecs in 'vecs' to point to the free memory and its + * extent, and *chainp to point to the first chain that we'll try to read into. + * Returns the number of vecs used. + */ +int evbuffer_read_setup_vecs_(struct evbuffer *buf, ev_ssize_t howmuch, + struct evbuffer_iovec *vecs, int n_vecs, struct evbuffer_chain ***chainp, + int exact); + +/* Helper macro: copies an evbuffer_iovec in ei to a win32 WSABUF in i. */ +#define WSABUF_FROM_EVBUFFER_IOV(i,ei) do { \ + (i)->buf = (ei)->iov_base; \ + (i)->len = (unsigned long)(ei)->iov_len; \ + } while (0) +/* XXXX the cast above is safe for now, but not if we allow mmaps on win64. + * See note in buffer_iocp's launch_write function */ + +/** Set the parent bufferevent object for buf to bev */ +void evbuffer_set_parent_(struct evbuffer *buf, struct bufferevent *bev); + +void evbuffer_invoke_callbacks_(struct evbuffer *buf); + + +int evbuffer_get_callbacks_(struct evbuffer *buffer, + struct event_callback **cbs, + int max_cbs); + +#ifdef __cplusplus +} +#endif + +#endif /* EVBUFFER_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/evconfig-private.h b/contrib/ntp/sntp/libevent/evconfig-private.h new file mode 100644 index 000000000..ea4940d5e --- /dev/null +++ b/contrib/ntp/sntp/libevent/evconfig-private.h @@ -0,0 +1,49 @@ +/* evconfig-private.h. Generated from evconfig-private.h.in by configure. */ +/* evconfig-private.h template - see "Configuration Header Templates" */ +/* in AC manual. Kevin Bowling + * http://www.imperialviolet.org/eventdns.html + * Public Domain code + * + * This software is Public Domain. To view a copy of the public domain dedication, + * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to + * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. + * + * I ask and expect, but do not require, that all derivative works contain an + * attribution similar to: + * Parts developed by Adam Langley + * + * You may wish to replace the word "Parts" with something else depending on + * the amount of original code. + * + * (Derivative works does not include programs which link against, run or include + * the source verbatim in their source distributions) + * + * Version: 0.1b + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#ifndef _FORTIFY_SOURCE +#define _FORTIFY_SOURCE 3 +#endif + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#ifdef EVENT__HAVE_STDINT_H +#include +#endif +#include +#include +#include +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#include +#include +#include +#include +#ifdef _WIN32 +#include +#include +#ifndef _WIN32_IE +#define _WIN32_IE 0x400 +#endif +#include +#endif + +#include "event2/dns.h" +#include "event2/dns_struct.h" +#include "event2/dns_compat.h" +#include "event2/util.h" +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/thread.h" + +#include "defer-internal.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "strlcpy-internal.h" +#include "ipv6-internal.h" +#include "util-internal.h" +#include "evthread-internal.h" +#ifdef _WIN32 +#include +#include +#include +#include +#include +#else +#include +#include +#include +#endif + +#ifdef EVENT__HAVE_NETINET_IN6_H +#include +#endif + +#define EVDNS_LOG_DEBUG EVENT_LOG_DEBUG +#define EVDNS_LOG_WARN EVENT_LOG_WARN +#define EVDNS_LOG_MSG EVENT_LOG_MSG + +#ifndef HOST_NAME_MAX +#define HOST_NAME_MAX 255 +#endif + +#include + +#undef MIN +#define MIN(a,b) ((a)<(b)?(a):(b)) + +#define ASSERT_VALID_REQUEST(req) \ + EVUTIL_ASSERT((req)->handle && (req)->handle->current_req == (req)) + +#define u64 ev_uint64_t +#define u32 ev_uint32_t +#define u16 ev_uint16_t +#define u8 ev_uint8_t + +/* maximum number of addresses from a single packet */ +/* that we bother recording */ +#define MAX_V4_ADDRS 32 +#define MAX_V6_ADDRS 32 + + +#define TYPE_A EVDNS_TYPE_A +#define TYPE_CNAME 5 +#define TYPE_PTR EVDNS_TYPE_PTR +#define TYPE_SOA EVDNS_TYPE_SOA +#define TYPE_AAAA EVDNS_TYPE_AAAA + +#define CLASS_INET EVDNS_CLASS_INET + +/* Persistent handle. We keep this separate from 'struct request' since we + * need some object to last for as long as an evdns_request is outstanding so + * that it can be canceled, whereas a search request can lead to multiple + * 'struct request' instances being created over its lifetime. */ +struct evdns_request { + struct request *current_req; + struct evdns_base *base; + + int pending_cb; /* Waiting for its callback to be invoked; not + * owned by event base any more. */ + + /* elements used by the searching code */ + int search_index; + struct search_state *search_state; + char *search_origname; /* needs to be free()ed */ + int search_flags; +}; + +struct request { + u8 *request; /* the dns packet data */ + u8 request_type; /* TYPE_PTR or TYPE_A or TYPE_AAAA */ + unsigned int request_len; + int reissue_count; + int tx_count; /* the number of times that this packet has been sent */ + void *user_pointer; /* the pointer given to us for this request */ + evdns_callback_type user_callback; + struct nameserver *ns; /* the server which we last sent it */ + + /* these objects are kept in a circular list */ + /* XXX We could turn this into a CIRCLEQ. */ + struct request *next, *prev; + + struct event timeout_event; + + u16 trans_id; /* the transaction id */ + unsigned request_appended :1; /* true if the request pointer is data which follows this struct */ + unsigned transmit_me :1; /* needs to be transmitted */ + + /* XXXX This is a horrible hack. */ + char **put_cname_in_ptr; /* store the cname here if we get one. */ + + struct evdns_base *base; + + struct evdns_request *handle; +}; + +struct reply { + unsigned int type; + unsigned int have_answer : 1; + union { + struct { + u32 addrcount; + u32 addresses[MAX_V4_ADDRS]; + } a; + struct { + u32 addrcount; + struct in6_addr addresses[MAX_V6_ADDRS]; + } aaaa; + struct { + char name[HOST_NAME_MAX]; + } ptr; + } data; +}; + +struct nameserver { + evutil_socket_t socket; /* a connected UDP socket */ + struct sockaddr_storage address; + ev_socklen_t addrlen; + int failed_times; /* number of times which we have given this server a chance */ + int timedout; /* number of times in a row a request has timed out */ + struct event event; + /* these objects are kept in a circular list */ + struct nameserver *next, *prev; + struct event timeout_event; /* used to keep the timeout for */ + /* when we next probe this server. */ + /* Valid if state == 0 */ + /* Outstanding probe request for this nameserver, if any */ + struct evdns_request *probe_request; + char state; /* zero if we think that this server is down */ + char choked; /* true if we have an EAGAIN from this server's socket */ + char write_waiting; /* true if we are waiting for EV_WRITE events */ + struct evdns_base *base; + + /* Number of currently inflight requests: used + * to track when we should add/del the event. */ + int requests_inflight; +}; + + +/* Represents a local port where we're listening for DNS requests. Right now, */ +/* only UDP is supported. */ +struct evdns_server_port { + evutil_socket_t socket; /* socket we use to read queries and write replies. */ + int refcnt; /* reference count. */ + char choked; /* Are we currently blocked from writing? */ + char closing; /* Are we trying to close this port, pending writes? */ + evdns_request_callback_fn_type user_callback; /* Fn to handle requests */ + void *user_data; /* Opaque pointer passed to user_callback */ + struct event event; /* Read/write event */ + /* circular list of replies that we want to write. */ + struct server_request *pending_replies; + struct event_base *event_base; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + void *lock; +#endif +}; + +/* Represents part of a reply being built. (That is, a single RR.) */ +struct server_reply_item { + struct server_reply_item *next; /* next item in sequence. */ + char *name; /* name part of the RR */ + u16 type; /* The RR type */ + u16 class; /* The RR class (usually CLASS_INET) */ + u32 ttl; /* The RR TTL */ + char is_name; /* True iff data is a label */ + u16 datalen; /* Length of data; -1 if data is a label */ + void *data; /* The contents of the RR */ +}; + +/* Represents a request that we've received as a DNS server, and holds */ +/* the components of the reply as we're constructing it. */ +struct server_request { + /* Pointers to the next and previous entries on the list of replies */ + /* that we're waiting to write. Only set if we have tried to respond */ + /* and gotten EAGAIN. */ + struct server_request *next_pending; + struct server_request *prev_pending; + + u16 trans_id; /* Transaction id. */ + struct evdns_server_port *port; /* Which port received this request on? */ + struct sockaddr_storage addr; /* Where to send the response */ + ev_socklen_t addrlen; /* length of addr */ + + int n_answer; /* how many answer RRs have been set? */ + int n_authority; /* how many authority RRs have been set? */ + int n_additional; /* how many additional RRs have been set? */ + + struct server_reply_item *answer; /* linked list of answer RRs */ + struct server_reply_item *authority; /* linked list of authority RRs */ + struct server_reply_item *additional; /* linked list of additional RRs */ + + /* Constructed response. Only set once we're ready to send a reply. */ + /* Once this is set, the RR fields are cleared, and no more should be set. */ + char *response; + size_t response_len; + + /* Caller-visible fields: flags, questions. */ + struct evdns_server_request base; +}; + +struct evdns_base { + /* An array of n_req_heads circular lists for inflight requests. + * Each inflight request req is in req_heads[req->trans_id % n_req_heads]. + */ + struct request **req_heads; + /* A circular list of requests that we're waiting to send, but haven't + * sent yet because there are too many requests inflight */ + struct request *req_waiting_head; + /* A circular list of nameservers. */ + struct nameserver *server_head; + int n_req_heads; + + struct event_base *event_base; + + /* The number of good nameservers that we have */ + int global_good_nameservers; + + /* inflight requests are contained in the req_head list */ + /* and are actually going out across the network */ + int global_requests_inflight; + /* requests which aren't inflight are in the waiting list */ + /* and are counted here */ + int global_requests_waiting; + + int global_max_requests_inflight; + + struct timeval global_timeout; /* 5 seconds by default */ + int global_max_reissues; /* a reissue occurs when we get some errors from the server */ + int global_max_retransmits; /* number of times we'll retransmit a request which timed out */ + /* number of timeouts in a row before we consider this server to be down */ + int global_max_nameserver_timeout; + /* true iff we will use the 0x20 hack to prevent poisoning attacks. */ + int global_randomize_case; + + /* The first time that a nameserver fails, how long do we wait before + * probing to see if it has returned? */ + struct timeval global_nameserver_probe_initial_timeout; + + /** Port to bind to for outgoing DNS packets. */ + struct sockaddr_storage global_outgoing_address; + /** ev_socklen_t for global_outgoing_address. 0 if it isn't set. */ + ev_socklen_t global_outgoing_addrlen; + + struct timeval global_getaddrinfo_allow_skew; + + int getaddrinfo_ipv4_timeouts; + int getaddrinfo_ipv6_timeouts; + int getaddrinfo_ipv4_answered; + int getaddrinfo_ipv6_answered; + + struct search_state *global_search_state; + + TAILQ_HEAD(hosts_list, hosts_entry) hostsdb; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + void *lock; +#endif + + int disable_when_inactive; +}; + +struct hosts_entry { + TAILQ_ENTRY(hosts_entry) next; + union { + struct sockaddr sa; + struct sockaddr_in sin; + struct sockaddr_in6 sin6; + } addr; + int addrlen; + char hostname[1]; +}; + +static struct evdns_base *current_base = NULL; + +struct evdns_base * +evdns_get_global_base(void) +{ + return current_base; +} + +/* Given a pointer to an evdns_server_request, get the corresponding */ +/* server_request. */ +#define TO_SERVER_REQUEST(base_ptr) \ + ((struct server_request*) \ + (((char*)(base_ptr) - evutil_offsetof(struct server_request, base)))) + +#define REQ_HEAD(base, id) ((base)->req_heads[id % (base)->n_req_heads]) + +static struct nameserver *nameserver_pick(struct evdns_base *base); +static void evdns_request_insert(struct request *req, struct request **head); +static void evdns_request_remove(struct request *req, struct request **head); +static void nameserver_ready_callback(evutil_socket_t fd, short events, void *arg); +static int evdns_transmit(struct evdns_base *base); +static int evdns_request_transmit(struct request *req); +static void nameserver_send_probe(struct nameserver *const ns); +static void search_request_finished(struct evdns_request *const); +static int search_try_next(struct evdns_request *const req); +static struct request *search_request_new(struct evdns_base *base, struct evdns_request *handle, int type, const char *const name, int flags, evdns_callback_type user_callback, void *user_arg); +static void evdns_requests_pump_waiting_queue(struct evdns_base *base); +static u16 transaction_id_pick(struct evdns_base *base); +static struct request *request_new(struct evdns_base *base, struct evdns_request *handle, int type, const char *name, int flags, evdns_callback_type callback, void *ptr); +static void request_submit(struct request *const req); + +static int server_request_free(struct server_request *req); +static void server_request_free_answers(struct server_request *req); +static void server_port_free(struct evdns_server_port *port); +static void server_port_ready_callback(evutil_socket_t fd, short events, void *arg); +static int evdns_base_resolv_conf_parse_impl(struct evdns_base *base, int flags, const char *const filename); +static int evdns_base_set_option_impl(struct evdns_base *base, + const char *option, const char *val, int flags); +static void evdns_base_free_and_unlock(struct evdns_base *base, int fail_requests); +static void evdns_request_timeout_callback(evutil_socket_t fd, short events, void *arg); + +static int strtoint(const char *const str); + +#ifdef EVENT__DISABLE_THREAD_SUPPORT +#define EVDNS_LOCK(base) EVUTIL_NIL_STMT_ +#define EVDNS_UNLOCK(base) EVUTIL_NIL_STMT_ +#define ASSERT_LOCKED(base) EVUTIL_NIL_STMT_ +#else +#define EVDNS_LOCK(base) \ + EVLOCK_LOCK((base)->lock, 0) +#define EVDNS_UNLOCK(base) \ + EVLOCK_UNLOCK((base)->lock, 0) +#define ASSERT_LOCKED(base) \ + EVLOCK_ASSERT_LOCKED((base)->lock) +#endif + +static evdns_debug_log_fn_type evdns_log_fn = NULL; + +void +evdns_set_log_fn(evdns_debug_log_fn_type fn) +{ + evdns_log_fn = fn; +} + +#ifdef __GNUC__ +#define EVDNS_LOG_CHECK __attribute__ ((format(printf, 2, 3))) +#else +#define EVDNS_LOG_CHECK +#endif + +static void evdns_log_(int severity, const char *fmt, ...) EVDNS_LOG_CHECK; +static void +evdns_log_(int severity, const char *fmt, ...) +{ + va_list args; + va_start(args,fmt); + if (evdns_log_fn) { + char buf[512]; + int is_warn = (severity == EVDNS_LOG_WARN); + evutil_vsnprintf(buf, sizeof(buf), fmt, args); + evdns_log_fn(is_warn, buf); + } else { + event_logv_(severity, NULL, fmt, args); + } + va_end(args); +} + +#define log evdns_log_ + +/* This walks the list of inflight requests to find the */ +/* one with a matching transaction id. Returns NULL on */ +/* failure */ +static struct request * +request_find_from_trans_id(struct evdns_base *base, u16 trans_id) { + struct request *req = REQ_HEAD(base, trans_id); + struct request *const started_at = req; + + ASSERT_LOCKED(base); + + if (req) { + do { + if (req->trans_id == trans_id) return req; + req = req->next; + } while (req != started_at); + } + + return NULL; +} + +/* a libevent callback function which is called when a nameserver */ +/* has gone down and we want to test if it has came back to life yet */ +static void +nameserver_prod_callback(evutil_socket_t fd, short events, void *arg) { + struct nameserver *const ns = (struct nameserver *) arg; + (void)fd; + (void)events; + + EVDNS_LOCK(ns->base); + nameserver_send_probe(ns); + EVDNS_UNLOCK(ns->base); +} + +/* a libevent callback which is called when a nameserver probe (to see if */ +/* it has come back to life) times out. We increment the count of failed_times */ +/* and wait longer to send the next probe packet. */ +static void +nameserver_probe_failed(struct nameserver *const ns) { + struct timeval timeout; + int i; + + ASSERT_LOCKED(ns->base); + (void) evtimer_del(&ns->timeout_event); + if (ns->state == 1) { + /* This can happen if the nameserver acts in a way which makes us mark */ + /* it as bad and then starts sending good replies. */ + return; + } + +#define MAX_PROBE_TIMEOUT 3600 +#define TIMEOUT_BACKOFF_FACTOR 3 + + memcpy(&timeout, &ns->base->global_nameserver_probe_initial_timeout, + sizeof(struct timeval)); + for (i=ns->failed_times; i > 0 && timeout.tv_sec < MAX_PROBE_TIMEOUT; --i) { + timeout.tv_sec *= TIMEOUT_BACKOFF_FACTOR; + timeout.tv_usec *= TIMEOUT_BACKOFF_FACTOR; + if (timeout.tv_usec > 1000000) { + timeout.tv_sec += timeout.tv_usec / 1000000; + timeout.tv_usec %= 1000000; + } + } + if (timeout.tv_sec > MAX_PROBE_TIMEOUT) { + timeout.tv_sec = MAX_PROBE_TIMEOUT; + timeout.tv_usec = 0; + } + + ns->failed_times++; + + if (evtimer_add(&ns->timeout_event, &timeout) < 0) { + char addrbuf[128]; + log(EVDNS_LOG_WARN, + "Error from libevent when adding timer event for %s", + evutil_format_sockaddr_port_( + (struct sockaddr *)&ns->address, + addrbuf, sizeof(addrbuf))); + } +} + +static void +request_swap_ns(struct request *req, struct nameserver *ns) { + if (ns && req->ns != ns) { + EVUTIL_ASSERT(req->ns->requests_inflight > 0); + req->ns->requests_inflight--; + ns->requests_inflight++; + + req->ns = ns; + } +} + +/* called when a nameserver has been deemed to have failed. For example, too */ +/* many packets have timed out etc */ +static void +nameserver_failed(struct nameserver *const ns, const char *msg) { + struct request *req, *started_at; + struct evdns_base *base = ns->base; + int i; + char addrbuf[128]; + + ASSERT_LOCKED(base); + /* if this nameserver has already been marked as failed */ + /* then don't do anything */ + if (!ns->state) return; + + log(EVDNS_LOG_MSG, "Nameserver %s has failed: %s", + evutil_format_sockaddr_port_( + (struct sockaddr *)&ns->address, + addrbuf, sizeof(addrbuf)), + msg); + + base->global_good_nameservers--; + EVUTIL_ASSERT(base->global_good_nameservers >= 0); + if (base->global_good_nameservers == 0) { + log(EVDNS_LOG_MSG, "All nameservers have failed"); + } + + ns->state = 0; + ns->failed_times = 1; + + if (evtimer_add(&ns->timeout_event, + &base->global_nameserver_probe_initial_timeout) < 0) { + log(EVDNS_LOG_WARN, + "Error from libevent when adding timer event for %s", + evutil_format_sockaddr_port_( + (struct sockaddr *)&ns->address, + addrbuf, sizeof(addrbuf))); + /* ???? Do more? */ + } + + /* walk the list of inflight requests to see if any can be reassigned to */ + /* a different server. Requests in the waiting queue don't have a */ + /* nameserver assigned yet */ + + /* if we don't have *any* good nameservers then there's no point */ + /* trying to reassign requests to one */ + if (!base->global_good_nameservers) return; + + for (i = 0; i < base->n_req_heads; ++i) { + req = started_at = base->req_heads[i]; + if (req) { + do { + if (req->tx_count == 0 && req->ns == ns) { + /* still waiting to go out, can be moved */ + /* to another server */ + request_swap_ns(req, nameserver_pick(base)); + } + req = req->next; + } while (req != started_at); + } + } +} + +static void +nameserver_up(struct nameserver *const ns) +{ + char addrbuf[128]; + ASSERT_LOCKED(ns->base); + if (ns->state) return; + log(EVDNS_LOG_MSG, "Nameserver %s is back up", + evutil_format_sockaddr_port_( + (struct sockaddr *)&ns->address, + addrbuf, sizeof(addrbuf))); + evtimer_del(&ns->timeout_event); + if (ns->probe_request) { + evdns_cancel_request(ns->base, ns->probe_request); + ns->probe_request = NULL; + } + ns->state = 1; + ns->failed_times = 0; + ns->timedout = 0; + ns->base->global_good_nameservers++; +} + +static void +request_trans_id_set(struct request *const req, const u16 trans_id) { + req->trans_id = trans_id; + *((u16 *) req->request) = htons(trans_id); +} + +/* Called to remove a request from a list and dealloc it. */ +/* head is a pointer to the head of the list it should be */ +/* removed from or NULL if the request isn't in a list. */ +/* when free_handle is one, free the handle as well. */ +static void +request_finished(struct request *const req, struct request **head, int free_handle) { + struct evdns_base *base = req->base; + int was_inflight = (head != &base->req_waiting_head); + EVDNS_LOCK(base); + ASSERT_VALID_REQUEST(req); + + if (head) + evdns_request_remove(req, head); + + log(EVDNS_LOG_DEBUG, "Removing timeout for request %p", req); + if (was_inflight) { + evtimer_del(&req->timeout_event); + base->global_requests_inflight--; + req->ns->requests_inflight--; + } else { + base->global_requests_waiting--; + } + /* it was initialized during request_new / evtimer_assign */ + event_debug_unassign(&req->timeout_event); + + if (req->ns && + req->ns->requests_inflight == 0 && + req->base->disable_when_inactive) { + event_del(&req->ns->event); + evtimer_del(&req->ns->timeout_event); + } + + if (!req->request_appended) { + /* need to free the request data on it's own */ + mm_free(req->request); + } else { + /* the request data is appended onto the header */ + /* so everything gets free()ed when we: */ + } + + if (req->handle) { + EVUTIL_ASSERT(req->handle->current_req == req); + + if (free_handle) { + search_request_finished(req->handle); + req->handle->current_req = NULL; + if (! req->handle->pending_cb) { + /* If we're planning to run the callback, + * don't free the handle until later. */ + mm_free(req->handle); + } + req->handle = NULL; /* If we have a bug, let's crash + * early */ + } else { + req->handle->current_req = NULL; + } + } + + mm_free(req); + + evdns_requests_pump_waiting_queue(base); + EVDNS_UNLOCK(base); +} + +/* This is called when a server returns a funny error code. */ +/* We try the request again with another server. */ +/* */ +/* return: */ +/* 0 ok */ +/* 1 failed/reissue is pointless */ +static int +request_reissue(struct request *req) { + const struct nameserver *const last_ns = req->ns; + ASSERT_LOCKED(req->base); + ASSERT_VALID_REQUEST(req); + /* the last nameserver should have been marked as failing */ + /* by the caller of this function, therefore pick will try */ + /* not to return it */ + request_swap_ns(req, nameserver_pick(req->base)); + if (req->ns == last_ns) { + /* ... but pick did return it */ + /* not a lot of point in trying again with the */ + /* same server */ + return 1; + } + + req->reissue_count++; + req->tx_count = 0; + req->transmit_me = 1; + + return 0; +} + +/* this function looks for space on the inflight queue and promotes */ +/* requests from the waiting queue if it can. */ +/* */ +/* TODO: */ +/* add return code, see at nameserver_pick() and other functions. */ +static void +evdns_requests_pump_waiting_queue(struct evdns_base *base) { + ASSERT_LOCKED(base); + while (base->global_requests_inflight < base->global_max_requests_inflight && + base->global_requests_waiting) { + struct request *req; + + EVUTIL_ASSERT(base->req_waiting_head); + req = base->req_waiting_head; + + req->ns = nameserver_pick(base); + if (!req->ns) + return; + + /* move a request from the waiting queue to the inflight queue */ + req->ns->requests_inflight++; + + evdns_request_remove(req, &base->req_waiting_head); + + base->global_requests_waiting--; + base->global_requests_inflight++; + + request_trans_id_set(req, transaction_id_pick(base)); + + evdns_request_insert(req, &REQ_HEAD(base, req->trans_id)); + evdns_request_transmit(req); + evdns_transmit(base); + } +} + +/* TODO(nickm) document */ +struct deferred_reply_callback { + struct event_callback deferred; + struct evdns_request *handle; + u8 request_type; + u8 have_reply; + u32 ttl; + u32 err; + evdns_callback_type user_callback; + struct reply reply; +}; + +static void +reply_run_callback(struct event_callback *d, void *user_pointer) +{ + struct deferred_reply_callback *cb = + EVUTIL_UPCAST(d, struct deferred_reply_callback, deferred); + + switch (cb->request_type) { + case TYPE_A: + if (cb->have_reply) + cb->user_callback(DNS_ERR_NONE, DNS_IPv4_A, + cb->reply.data.a.addrcount, cb->ttl, + cb->reply.data.a.addresses, + user_pointer); + else + cb->user_callback(cb->err, 0, 0, cb->ttl, NULL, user_pointer); + break; + case TYPE_PTR: + if (cb->have_reply) { + char *name = cb->reply.data.ptr.name; + cb->user_callback(DNS_ERR_NONE, DNS_PTR, 1, cb->ttl, + &name, user_pointer); + } else { + cb->user_callback(cb->err, 0, 0, cb->ttl, NULL, user_pointer); + } + break; + case TYPE_AAAA: + if (cb->have_reply) + cb->user_callback(DNS_ERR_NONE, DNS_IPv6_AAAA, + cb->reply.data.aaaa.addrcount, cb->ttl, + cb->reply.data.aaaa.addresses, + user_pointer); + else + cb->user_callback(cb->err, 0, 0, cb->ttl, NULL, user_pointer); + break; + default: + EVUTIL_ASSERT(0); + } + + if (cb->handle && cb->handle->pending_cb) { + mm_free(cb->handle); + } + + mm_free(cb); +} + +static void +reply_schedule_callback(struct request *const req, u32 ttl, u32 err, struct reply *reply) +{ + struct deferred_reply_callback *d = mm_calloc(1, sizeof(*d)); + + if (!d) { + event_warn("%s: Couldn't allocate space for deferred callback.", + __func__); + return; + } + + ASSERT_LOCKED(req->base); + + d->request_type = req->request_type; + d->user_callback = req->user_callback; + d->ttl = ttl; + d->err = err; + if (reply) { + d->have_reply = 1; + memcpy(&d->reply, reply, sizeof(struct reply)); + } + + if (req->handle) { + req->handle->pending_cb = 1; + d->handle = req->handle; + } + + event_deferred_cb_init_( + &d->deferred, + event_get_priority(&req->timeout_event), + reply_run_callback, + req->user_pointer); + event_deferred_cb_schedule_( + req->base->event_base, + &d->deferred); +} + +/* this processes a parsed reply packet */ +static void +reply_handle(struct request *const req, u16 flags, u32 ttl, struct reply *reply) { + int error; + char addrbuf[128]; + static const int error_codes[] = { + DNS_ERR_FORMAT, DNS_ERR_SERVERFAILED, DNS_ERR_NOTEXIST, + DNS_ERR_NOTIMPL, DNS_ERR_REFUSED + }; + + ASSERT_LOCKED(req->base); + ASSERT_VALID_REQUEST(req); + + if (flags & 0x020f || !reply || !reply->have_answer) { + /* there was an error */ + if (flags & 0x0200) { + error = DNS_ERR_TRUNCATED; + } else if (flags & 0x000f) { + u16 error_code = (flags & 0x000f) - 1; + if (error_code > 4) { + error = DNS_ERR_UNKNOWN; + } else { + error = error_codes[error_code]; + } + } else if (reply && !reply->have_answer) { + error = DNS_ERR_NODATA; + } else { + error = DNS_ERR_UNKNOWN; + } + + switch (error) { + case DNS_ERR_NOTIMPL: + case DNS_ERR_REFUSED: + /* we regard these errors as marking a bad nameserver */ + if (req->reissue_count < req->base->global_max_reissues) { + char msg[64]; + evutil_snprintf(msg, sizeof(msg), "Bad response %d (%s)", + error, evdns_err_to_string(error)); + nameserver_failed(req->ns, msg); + if (!request_reissue(req)) return; + } + break; + case DNS_ERR_SERVERFAILED: + /* rcode 2 (servfailed) sometimes means "we + * are broken" and sometimes (with some binds) + * means "that request was very confusing." + * Treat this as a timeout, not a failure. + */ + log(EVDNS_LOG_DEBUG, "Got a SERVERFAILED from nameserver" + "at %s; will allow the request to time out.", + evutil_format_sockaddr_port_( + (struct sockaddr *)&req->ns->address, + addrbuf, sizeof(addrbuf))); + /* Call the timeout function */ + evdns_request_timeout_callback(0, 0, req); + return; + default: + /* we got a good reply from the nameserver: it is up. */ + if (req->handle == req->ns->probe_request) { + /* Avoid double-free */ + req->ns->probe_request = NULL; + } + + nameserver_up(req->ns); + } + + if (req->handle->search_state && + req->request_type != TYPE_PTR) { + /* if we have a list of domains to search in, + * try the next one */ + if (!search_try_next(req->handle)) { + /* a new request was issued so this + * request is finished and */ + /* the user callback will be made when + * that request (or a */ + /* child of it) finishes. */ + return; + } + } + + /* all else failed. Pass the failure up */ + reply_schedule_callback(req, ttl, error, NULL); + request_finished(req, &REQ_HEAD(req->base, req->trans_id), 1); + } else { + /* all ok, tell the user */ + reply_schedule_callback(req, ttl, 0, reply); + if (req->handle == req->ns->probe_request) + req->ns->probe_request = NULL; /* Avoid double-free */ + nameserver_up(req->ns); + request_finished(req, &REQ_HEAD(req->base, req->trans_id), 1); + } +} + +static int +name_parse(u8 *packet, int length, int *idx, char *name_out, int name_out_len) { + int name_end = -1; + int j = *idx; + int ptr_count = 0; +#define GET32(x) do { if (j + 4 > length) goto err; memcpy(&t32_, packet + j, 4); j += 4; x = ntohl(t32_); } while (0) +#define GET16(x) do { if (j + 2 > length) goto err; memcpy(&t_, packet + j, 2); j += 2; x = ntohs(t_); } while (0) +#define GET8(x) do { if (j >= length) goto err; x = packet[j++]; } while (0) + + char *cp = name_out; + const char *const end = name_out + name_out_len; + + /* Normally, names are a series of length prefixed strings terminated */ + /* with a length of 0 (the lengths are u8's < 63). */ + /* However, the length can start with a pair of 1 bits and that */ + /* means that the next 14 bits are a pointer within the current */ + /* packet. */ + + for (;;) { + u8 label_len; + if (j >= length) return -1; + GET8(label_len); + if (!label_len) break; + if (label_len & 0xc0) { + u8 ptr_low; + GET8(ptr_low); + if (name_end < 0) name_end = j; + j = (((int)label_len & 0x3f) << 8) + ptr_low; + /* Make sure that the target offset is in-bounds. */ + if (j < 0 || j >= length) return -1; + /* If we've jumped more times than there are characters in the + * message, we must have a loop. */ + if (++ptr_count > length) return -1; + continue; + } + if (label_len > 63) return -1; + if (cp != name_out) { + if (cp + 1 >= end) return -1; + *cp++ = '.'; + } + if (cp + label_len >= end) return -1; + memcpy(cp, packet + j, label_len); + cp += label_len; + j += label_len; + } + if (cp >= end) return -1; + *cp = '\0'; + if (name_end < 0) + *idx = j; + else + *idx = name_end; + return 0; + err: + return -1; +} + +/* parses a raw request from a nameserver */ +static int +reply_parse(struct evdns_base *base, u8 *packet, int length) { + int j = 0, k = 0; /* index into packet */ + u16 t_; /* used by the macros */ + u32 t32_; /* used by the macros */ + char tmp_name[256], cmp_name[256]; /* used by the macros */ + int name_matches = 0; + + u16 trans_id, questions, answers, authority, additional, datalength; + u16 flags = 0; + u32 ttl, ttl_r = 0xffffffff; + struct reply reply; + struct request *req = NULL; + unsigned int i; + + ASSERT_LOCKED(base); + + GET16(trans_id); + GET16(flags); + GET16(questions); + GET16(answers); + GET16(authority); + GET16(additional); + (void) authority; /* suppress "unused variable" warnings. */ + (void) additional; /* suppress "unused variable" warnings. */ + + req = request_find_from_trans_id(base, trans_id); + if (!req) return -1; + EVUTIL_ASSERT(req->base == base); + + memset(&reply, 0, sizeof(reply)); + + /* If it's not an answer, it doesn't correspond to any request. */ + if (!(flags & 0x8000)) return -1; /* must be an answer */ + if ((flags & 0x020f) && (flags & 0x020f) != DNS_ERR_NOTEXIST) { + /* there was an error and it's not NXDOMAIN */ + goto err; + } + /* if (!answers) return; */ /* must have an answer of some form */ + + /* This macro skips a name in the DNS reply. */ +#define SKIP_NAME \ + do { tmp_name[0] = '\0'; \ + if (name_parse(packet, length, &j, tmp_name, \ + sizeof(tmp_name))<0) \ + goto err; \ + } while (0) +#define TEST_NAME \ + do { tmp_name[0] = '\0'; \ + cmp_name[0] = '\0'; \ + k = j; \ + if (name_parse(packet, length, &j, tmp_name, \ + sizeof(tmp_name))<0) \ + goto err; \ + if (name_parse(req->request, req->request_len, &k, \ + cmp_name, sizeof(cmp_name))<0) \ + goto err; \ + if (base->global_randomize_case) { \ + if (strcmp(tmp_name, cmp_name) == 0) \ + name_matches = 1; \ + } else { \ + if (evutil_ascii_strcasecmp(tmp_name, cmp_name) == 0) \ + name_matches = 1; \ + } \ + } while (0) + + reply.type = req->request_type; + + /* skip over each question in the reply */ + for (i = 0; i < questions; ++i) { + /* the question looks like + * + */ + TEST_NAME; + j += 4; + if (j > length) goto err; + } + + if (!name_matches) + goto err; + + /* now we have the answer section which looks like + * + */ + + for (i = 0; i < answers; ++i) { + u16 type, class; + + SKIP_NAME; + GET16(type); + GET16(class); + GET32(ttl); + GET16(datalength); + + if (type == TYPE_A && class == CLASS_INET) { + int addrcount, addrtocopy; + if (req->request_type != TYPE_A) { + j += datalength; continue; + } + if ((datalength & 3) != 0) /* not an even number of As. */ + goto err; + addrcount = datalength >> 2; + addrtocopy = MIN(MAX_V4_ADDRS - reply.data.a.addrcount, (unsigned)addrcount); + + ttl_r = MIN(ttl_r, ttl); + /* we only bother with the first four addresses. */ + if (j + 4*addrtocopy > length) goto err; + memcpy(&reply.data.a.addresses[reply.data.a.addrcount], + packet + j, 4*addrtocopy); + j += 4*addrtocopy; + reply.data.a.addrcount += addrtocopy; + reply.have_answer = 1; + if (reply.data.a.addrcount == MAX_V4_ADDRS) break; + } else if (type == TYPE_PTR && class == CLASS_INET) { + if (req->request_type != TYPE_PTR) { + j += datalength; continue; + } + if (name_parse(packet, length, &j, reply.data.ptr.name, + sizeof(reply.data.ptr.name))<0) + goto err; + ttl_r = MIN(ttl_r, ttl); + reply.have_answer = 1; + break; + } else if (type == TYPE_CNAME) { + char cname[HOST_NAME_MAX]; + if (!req->put_cname_in_ptr || *req->put_cname_in_ptr) { + j += datalength; continue; + } + if (name_parse(packet, length, &j, cname, + sizeof(cname))<0) + goto err; + *req->put_cname_in_ptr = mm_strdup(cname); + } else if (type == TYPE_AAAA && class == CLASS_INET) { + int addrcount, addrtocopy; + if (req->request_type != TYPE_AAAA) { + j += datalength; continue; + } + if ((datalength & 15) != 0) /* not an even number of AAAAs. */ + goto err; + addrcount = datalength >> 4; /* each address is 16 bytes long */ + addrtocopy = MIN(MAX_V6_ADDRS - reply.data.aaaa.addrcount, (unsigned)addrcount); + ttl_r = MIN(ttl_r, ttl); + + /* we only bother with the first four addresses. */ + if (j + 16*addrtocopy > length) goto err; + memcpy(&reply.data.aaaa.addresses[reply.data.aaaa.addrcount], + packet + j, 16*addrtocopy); + reply.data.aaaa.addrcount += addrtocopy; + j += 16*addrtocopy; + reply.have_answer = 1; + if (reply.data.aaaa.addrcount == MAX_V6_ADDRS) break; + } else { + /* skip over any other type of resource */ + j += datalength; + } + } + + if (!reply.have_answer) { + for (i = 0; i < authority; ++i) { + u16 type, class; + SKIP_NAME; + GET16(type); + GET16(class); + GET32(ttl); + GET16(datalength); + if (type == TYPE_SOA && class == CLASS_INET) { + u32 serial, refresh, retry, expire, minimum; + SKIP_NAME; + SKIP_NAME; + GET32(serial); + GET32(refresh); + GET32(retry); + GET32(expire); + GET32(minimum); + (void)expire; + (void)retry; + (void)refresh; + (void)serial; + ttl_r = MIN(ttl_r, ttl); + ttl_r = MIN(ttl_r, minimum); + } else { + /* skip over any other type of resource */ + j += datalength; + } + } + } + + if (ttl_r == 0xffffffff) + ttl_r = 0; + + reply_handle(req, flags, ttl_r, &reply); + return 0; + err: + if (req) + reply_handle(req, flags, 0, NULL); + return -1; +} + +/* Parse a raw request (packet,length) sent to a nameserver port (port) from */ +/* a DNS client (addr,addrlen), and if it's well-formed, call the corresponding */ +/* callback. */ +static int +request_parse(u8 *packet, int length, struct evdns_server_port *port, struct sockaddr *addr, ev_socklen_t addrlen) +{ + int j = 0; /* index into packet */ + u16 t_; /* used by the macros */ + char tmp_name[256]; /* used by the macros */ + + int i; + u16 trans_id, flags, questions, answers, authority, additional; + struct server_request *server_req = NULL; + + ASSERT_LOCKED(port); + + /* Get the header fields */ + GET16(trans_id); + GET16(flags); + GET16(questions); + GET16(answers); + GET16(authority); + GET16(additional); + (void)answers; + (void)additional; + (void)authority; + + if (flags & 0x8000) return -1; /* Must not be an answer. */ + flags &= 0x0110; /* Only RD and CD get preserved. */ + + server_req = mm_malloc(sizeof(struct server_request)); + if (server_req == NULL) return -1; + memset(server_req, 0, sizeof(struct server_request)); + + server_req->trans_id = trans_id; + memcpy(&server_req->addr, addr, addrlen); + server_req->addrlen = addrlen; + + server_req->base.flags = flags; + server_req->base.nquestions = 0; + server_req->base.questions = mm_calloc(sizeof(struct evdns_server_question *), questions); + if (server_req->base.questions == NULL) + goto err; + + for (i = 0; i < questions; ++i) { + u16 type, class; + struct evdns_server_question *q; + int namelen; + if (name_parse(packet, length, &j, tmp_name, sizeof(tmp_name))<0) + goto err; + GET16(type); + GET16(class); + namelen = (int)strlen(tmp_name); + q = mm_malloc(sizeof(struct evdns_server_question) + namelen); + if (!q) + goto err; + q->type = type; + q->dns_question_class = class; + memcpy(q->name, tmp_name, namelen+1); + server_req->base.questions[server_req->base.nquestions++] = q; + } + + /* Ignore answers, authority, and additional. */ + + server_req->port = port; + port->refcnt++; + + /* Only standard queries are supported. */ + if (flags & 0x7800) { + evdns_server_request_respond(&(server_req->base), DNS_ERR_NOTIMPL); + return -1; + } + + port->user_callback(&(server_req->base), port->user_data); + + return 0; +err: + if (server_req) { + if (server_req->base.questions) { + for (i = 0; i < server_req->base.nquestions; ++i) + mm_free(server_req->base.questions[i]); + mm_free(server_req->base.questions); + } + mm_free(server_req); + } + return -1; + +#undef SKIP_NAME +#undef GET32 +#undef GET16 +#undef GET8 +} + + +void +evdns_set_transaction_id_fn(ev_uint16_t (*fn)(void)) +{ +} + +void +evdns_set_random_bytes_fn(void (*fn)(char *, size_t)) +{ +} + +/* Try to choose a strong transaction id which isn't already in flight */ +static u16 +transaction_id_pick(struct evdns_base *base) { + ASSERT_LOCKED(base); + for (;;) { + u16 trans_id; + evutil_secure_rng_get_bytes(&trans_id, sizeof(trans_id)); + + if (trans_id == 0xffff) continue; + /* now check to see if that id is already inflight */ + if (request_find_from_trans_id(base, trans_id) == NULL) + return trans_id; + } +} + +/* choose a namesever to use. This function will try to ignore */ +/* nameservers which we think are down and load balance across the rest */ +/* by updating the server_head global each time. */ +static struct nameserver * +nameserver_pick(struct evdns_base *base) { + struct nameserver *started_at = base->server_head, *picked; + ASSERT_LOCKED(base); + if (!base->server_head) return NULL; + + /* if we don't have any good nameservers then there's no */ + /* point in trying to find one. */ + if (!base->global_good_nameservers) { + base->server_head = base->server_head->next; + return base->server_head; + } + + /* remember that nameservers are in a circular list */ + for (;;) { + if (base->server_head->state) { + /* we think this server is currently good */ + picked = base->server_head; + base->server_head = base->server_head->next; + return picked; + } + + base->server_head = base->server_head->next; + if (base->server_head == started_at) { + /* all the nameservers seem to be down */ + /* so we just return this one and hope for the */ + /* best */ + EVUTIL_ASSERT(base->global_good_nameservers == 0); + picked = base->server_head; + base->server_head = base->server_head->next; + return picked; + } + } +} + +/* this is called when a namesever socket is ready for reading */ +static void +nameserver_read(struct nameserver *ns) { + struct sockaddr_storage ss; + ev_socklen_t addrlen = sizeof(ss); + u8 packet[1500]; + char addrbuf[128]; + ASSERT_LOCKED(ns->base); + + for (;;) { + const int r = recvfrom(ns->socket, (void*)packet, + sizeof(packet), 0, + (struct sockaddr*)&ss, &addrlen); + if (r < 0) { + int err = evutil_socket_geterror(ns->socket); + if (EVUTIL_ERR_RW_RETRIABLE(err)) + return; + nameserver_failed(ns, + evutil_socket_error_to_string(err)); + return; + } + if (evutil_sockaddr_cmp((struct sockaddr*)&ss, + (struct sockaddr*)&ns->address, 0)) { + log(EVDNS_LOG_WARN, "Address mismatch on received " + "DNS packet. Apparent source was %s", + evutil_format_sockaddr_port_( + (struct sockaddr *)&ss, + addrbuf, sizeof(addrbuf))); + return; + } + + ns->timedout = 0; + reply_parse(ns->base, packet, r); + } +} + +/* Read a packet from a DNS client on a server port s, parse it, and */ +/* act accordingly. */ +static void +server_port_read(struct evdns_server_port *s) { + u8 packet[1500]; + struct sockaddr_storage addr; + ev_socklen_t addrlen; + int r; + ASSERT_LOCKED(s); + + for (;;) { + addrlen = sizeof(struct sockaddr_storage); + r = recvfrom(s->socket, (void*)packet, sizeof(packet), 0, + (struct sockaddr*) &addr, &addrlen); + if (r < 0) { + int err = evutil_socket_geterror(s->socket); + if (EVUTIL_ERR_RW_RETRIABLE(err)) + return; + log(EVDNS_LOG_WARN, + "Error %s (%d) while reading request.", + evutil_socket_error_to_string(err), err); + return; + } + request_parse(packet, r, s, (struct sockaddr*) &addr, addrlen); + } +} + +/* Try to write all pending replies on a given DNS server port. */ +static void +server_port_flush(struct evdns_server_port *port) +{ + struct server_request *req = port->pending_replies; + ASSERT_LOCKED(port); + while (req) { + int r = sendto(port->socket, req->response, (int)req->response_len, 0, + (struct sockaddr*) &req->addr, (ev_socklen_t)req->addrlen); + if (r < 0) { + int err = evutil_socket_geterror(port->socket); + if (EVUTIL_ERR_RW_RETRIABLE(err)) + return; + log(EVDNS_LOG_WARN, "Error %s (%d) while writing response to port; dropping", evutil_socket_error_to_string(err), err); + } + if (server_request_free(req)) { + /* we released the last reference to req->port. */ + return; + } else { + EVUTIL_ASSERT(req != port->pending_replies); + req = port->pending_replies; + } + } + + /* We have no more pending requests; stop listening for 'writeable' events. */ + (void) event_del(&port->event); + event_assign(&port->event, port->event_base, + port->socket, EV_READ | EV_PERSIST, + server_port_ready_callback, port); + + if (event_add(&port->event, NULL) < 0) { + log(EVDNS_LOG_WARN, "Error from libevent when adding event for DNS server."); + /* ???? Do more? */ + } +} + +/* set if we are waiting for the ability to write to this server. */ +/* if waiting is true then we ask libevent for EV_WRITE events, otherwise */ +/* we stop these events. */ +static void +nameserver_write_waiting(struct nameserver *ns, char waiting) { + ASSERT_LOCKED(ns->base); + if (ns->write_waiting == waiting) return; + + ns->write_waiting = waiting; + (void) event_del(&ns->event); + event_assign(&ns->event, ns->base->event_base, + ns->socket, EV_READ | (waiting ? EV_WRITE : 0) | EV_PERSIST, + nameserver_ready_callback, ns); + if (event_add(&ns->event, NULL) < 0) { + char addrbuf[128]; + log(EVDNS_LOG_WARN, "Error from libevent when adding event for %s", + evutil_format_sockaddr_port_( + (struct sockaddr *)&ns->address, + addrbuf, sizeof(addrbuf))); + /* ???? Do more? */ + } +} + +/* a callback function. Called by libevent when the kernel says that */ +/* a nameserver socket is ready for writing or reading */ +static void +nameserver_ready_callback(evutil_socket_t fd, short events, void *arg) { + struct nameserver *ns = (struct nameserver *) arg; + (void)fd; + + EVDNS_LOCK(ns->base); + if (events & EV_WRITE) { + ns->choked = 0; + if (!evdns_transmit(ns->base)) { + nameserver_write_waiting(ns, 0); + } + } + if (events & EV_READ) { + nameserver_read(ns); + } + EVDNS_UNLOCK(ns->base); +} + +/* a callback function. Called by libevent when the kernel says that */ +/* a server socket is ready for writing or reading. */ +static void +server_port_ready_callback(evutil_socket_t fd, short events, void *arg) { + struct evdns_server_port *port = (struct evdns_server_port *) arg; + (void) fd; + + EVDNS_LOCK(port); + if (events & EV_WRITE) { + port->choked = 0; + server_port_flush(port); + } + if (events & EV_READ) { + server_port_read(port); + } + EVDNS_UNLOCK(port); +} + +/* This is an inefficient representation; only use it via the dnslabel_table_* + * functions, so that is can be safely replaced with something smarter later. */ +#define MAX_LABELS 128 +/* Structures used to implement name compression */ +struct dnslabel_entry { char *v; off_t pos; }; +struct dnslabel_table { + int n_labels; /* number of current entries */ + /* map from name to position in message */ + struct dnslabel_entry labels[MAX_LABELS]; +}; + +/* Initialize dnslabel_table. */ +static void +dnslabel_table_init(struct dnslabel_table *table) +{ + table->n_labels = 0; +} + +/* Free all storage held by table, but not the table itself. */ +static void +dnslabel_clear(struct dnslabel_table *table) +{ + int i; + for (i = 0; i < table->n_labels; ++i) + mm_free(table->labels[i].v); + table->n_labels = 0; +} + +/* return the position of the label in the current message, or -1 if the label */ +/* hasn't been used yet. */ +static int +dnslabel_table_get_pos(const struct dnslabel_table *table, const char *label) +{ + int i; + for (i = 0; i < table->n_labels; ++i) { + if (!strcmp(label, table->labels[i].v)) + return table->labels[i].pos; + } + return -1; +} + +/* remember that we've used the label at position pos */ +static int +dnslabel_table_add(struct dnslabel_table *table, const char *label, off_t pos) +{ + char *v; + int p; + if (table->n_labels == MAX_LABELS) + return (-1); + v = mm_strdup(label); + if (v == NULL) + return (-1); + p = table->n_labels++; + table->labels[p].v = v; + table->labels[p].pos = pos; + + return (0); +} + +/* Converts a string to a length-prefixed set of DNS labels, starting */ +/* at buf[j]. name and buf must not overlap. name_len should be the length */ +/* of name. table is optional, and is used for compression. */ +/* */ +/* Input: abc.def */ +/* Output: <3>abc<3>def<0> */ +/* */ +/* Returns the first index after the encoded name, or negative on error. */ +/* -1 label was > 63 bytes */ +/* -2 name too long to fit in buffer. */ +/* */ +static off_t +dnsname_to_labels(u8 *const buf, size_t buf_len, off_t j, + const char *name, const size_t name_len, + struct dnslabel_table *table) { + const char *end = name + name_len; + int ref = 0; + u16 t_; + +#define APPEND16(x) do { \ + if (j + 2 > (off_t)buf_len) \ + goto overflow; \ + t_ = htons(x); \ + memcpy(buf + j, &t_, 2); \ + j += 2; \ + } while (0) +#define APPEND32(x) do { \ + if (j + 4 > (off_t)buf_len) \ + goto overflow; \ + t32_ = htonl(x); \ + memcpy(buf + j, &t32_, 4); \ + j += 4; \ + } while (0) + + if (name_len > 255) return -2; + + for (;;) { + const char *const start = name; + if (table && (ref = dnslabel_table_get_pos(table, name)) >= 0) { + APPEND16(ref | 0xc000); + return j; + } + name = strchr(name, '.'); + if (!name) { + const size_t label_len = end - start; + if (label_len > 63) return -1; + if ((size_t)(j+label_len+1) > buf_len) return -2; + if (table) dnslabel_table_add(table, start, j); + buf[j++] = (ev_uint8_t)label_len; + + memcpy(buf + j, start, label_len); + j += (int) label_len; + break; + } else { + /* append length of the label. */ + const size_t label_len = name - start; + if (label_len > 63) return -1; + if ((size_t)(j+label_len+1) > buf_len) return -2; + if (table) dnslabel_table_add(table, start, j); + buf[j++] = (ev_uint8_t)label_len; + + memcpy(buf + j, start, label_len); + j += (int) label_len; + /* hop over the '.' */ + name++; + } + } + + /* the labels must be terminated by a 0. */ + /* It's possible that the name ended in a . */ + /* in which case the zero is already there */ + if (!j || buf[j-1]) buf[j++] = 0; + return j; + overflow: + return (-2); +} + +/* Finds the length of a dns request for a DNS name of the given */ +/* length. The actual request may be smaller than the value returned */ +/* here */ +static size_t +evdns_request_len(const size_t name_len) { + return 96 + /* length of the DNS standard header */ + name_len + 2 + + 4; /* space for the resource type */ +} + +/* build a dns request packet into buf. buf should be at least as long */ +/* as evdns_request_len told you it should be. */ +/* */ +/* Returns the amount of space used. Negative on error. */ +static int +evdns_request_data_build(const char *const name, const size_t name_len, + const u16 trans_id, const u16 type, const u16 class, + u8 *const buf, size_t buf_len) { + off_t j = 0; /* current offset into buf */ + u16 t_; /* used by the macros */ + + APPEND16(trans_id); + APPEND16(0x0100); /* standard query, recusion needed */ + APPEND16(1); /* one question */ + APPEND16(0); /* no answers */ + APPEND16(0); /* no authority */ + APPEND16(0); /* no additional */ + + j = dnsname_to_labels(buf, buf_len, j, name, name_len, NULL); + if (j < 0) { + return (int)j; + } + + APPEND16(type); + APPEND16(class); + + return (int)j; + overflow: + return (-1); +} + +/* exported function */ +struct evdns_server_port * +evdns_add_server_port_with_base(struct event_base *base, evutil_socket_t socket, int flags, evdns_request_callback_fn_type cb, void *user_data) +{ + struct evdns_server_port *port; + if (flags) + return NULL; /* flags not yet implemented */ + if (!(port = mm_malloc(sizeof(struct evdns_server_port)))) + return NULL; + memset(port, 0, sizeof(struct evdns_server_port)); + + + port->socket = socket; + port->refcnt = 1; + port->choked = 0; + port->closing = 0; + port->user_callback = cb; + port->user_data = user_data; + port->pending_replies = NULL; + port->event_base = base; + + event_assign(&port->event, port->event_base, + port->socket, EV_READ | EV_PERSIST, + server_port_ready_callback, port); + if (event_add(&port->event, NULL) < 0) { + mm_free(port); + return NULL; + } + EVTHREAD_ALLOC_LOCK(port->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + return port; +} + +struct evdns_server_port * +evdns_add_server_port(evutil_socket_t socket, int flags, evdns_request_callback_fn_type cb, void *user_data) +{ + return evdns_add_server_port_with_base(NULL, socket, flags, cb, user_data); +} + +/* exported function */ +void +evdns_close_server_port(struct evdns_server_port *port) +{ + EVDNS_LOCK(port); + if (--port->refcnt == 0) { + EVDNS_UNLOCK(port); + server_port_free(port); + } else { + port->closing = 1; + } +} + +/* exported function */ +int +evdns_server_request_add_reply(struct evdns_server_request *req_, int section, const char *name, int type, int class, int ttl, int datalen, int is_name, const char *data) +{ + struct server_request *req = TO_SERVER_REQUEST(req_); + struct server_reply_item **itemp, *item; + int *countp; + int result = -1; + + EVDNS_LOCK(req->port); + if (req->response) /* have we already answered? */ + goto done; + + switch (section) { + case EVDNS_ANSWER_SECTION: + itemp = &req->answer; + countp = &req->n_answer; + break; + case EVDNS_AUTHORITY_SECTION: + itemp = &req->authority; + countp = &req->n_authority; + break; + case EVDNS_ADDITIONAL_SECTION: + itemp = &req->additional; + countp = &req->n_additional; + break; + default: + goto done; + } + while (*itemp) { + itemp = &((*itemp)->next); + } + item = mm_malloc(sizeof(struct server_reply_item)); + if (!item) + goto done; + item->next = NULL; + if (!(item->name = mm_strdup(name))) { + mm_free(item); + goto done; + } + item->type = type; + item->dns_question_class = class; + item->ttl = ttl; + item->is_name = is_name != 0; + item->datalen = 0; + item->data = NULL; + if (data) { + if (item->is_name) { + if (!(item->data = mm_strdup(data))) { + mm_free(item->name); + mm_free(item); + goto done; + } + item->datalen = (u16)-1; + } else { + if (!(item->data = mm_malloc(datalen))) { + mm_free(item->name); + mm_free(item); + goto done; + } + item->datalen = datalen; + memcpy(item->data, data, datalen); + } + } + + *itemp = item; + ++(*countp); + result = 0; +done: + EVDNS_UNLOCK(req->port); + return result; +} + +/* exported function */ +int +evdns_server_request_add_a_reply(struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl) +{ + return evdns_server_request_add_reply( + req, EVDNS_ANSWER_SECTION, name, TYPE_A, CLASS_INET, + ttl, n*4, 0, addrs); +} + +/* exported function */ +int +evdns_server_request_add_aaaa_reply(struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl) +{ + return evdns_server_request_add_reply( + req, EVDNS_ANSWER_SECTION, name, TYPE_AAAA, CLASS_INET, + ttl, n*16, 0, addrs); +} + +/* exported function */ +int +evdns_server_request_add_ptr_reply(struct evdns_server_request *req, struct in_addr *in, const char *inaddr_name, const char *hostname, int ttl) +{ + u32 a; + char buf[32]; + if (in && inaddr_name) + return -1; + else if (!in && !inaddr_name) + return -1; + if (in) { + a = ntohl(in->s_addr); + evutil_snprintf(buf, sizeof(buf), "%d.%d.%d.%d.in-addr.arpa", + (int)(u8)((a )&0xff), + (int)(u8)((a>>8 )&0xff), + (int)(u8)((a>>16)&0xff), + (int)(u8)((a>>24)&0xff)); + inaddr_name = buf; + } + return evdns_server_request_add_reply( + req, EVDNS_ANSWER_SECTION, inaddr_name, TYPE_PTR, CLASS_INET, + ttl, -1, 1, hostname); +} + +/* exported function */ +int +evdns_server_request_add_cname_reply(struct evdns_server_request *req, const char *name, const char *cname, int ttl) +{ + return evdns_server_request_add_reply( + req, EVDNS_ANSWER_SECTION, name, TYPE_CNAME, CLASS_INET, + ttl, -1, 1, cname); +} + +/* exported function */ +void +evdns_server_request_set_flags(struct evdns_server_request *exreq, int flags) +{ + struct server_request *req = TO_SERVER_REQUEST(exreq); + req->base.flags &= ~(EVDNS_FLAGS_AA|EVDNS_FLAGS_RD); + req->base.flags |= flags; +} + +static int +evdns_server_request_format_response(struct server_request *req, int err) +{ + unsigned char buf[1500]; + size_t buf_len = sizeof(buf); + off_t j = 0, r; + u16 t_; + u32 t32_; + int i; + u16 flags; + struct dnslabel_table table; + + if (err < 0 || err > 15) return -1; + + /* Set response bit and error code; copy OPCODE and RD fields from + * question; copy RA and AA if set by caller. */ + flags = req->base.flags; + flags |= (0x8000 | err); + + dnslabel_table_init(&table); + APPEND16(req->trans_id); + APPEND16(flags); + APPEND16(req->base.nquestions); + APPEND16(req->n_answer); + APPEND16(req->n_authority); + APPEND16(req->n_additional); + + /* Add questions. */ + for (i=0; i < req->base.nquestions; ++i) { + const char *s = req->base.questions[i]->name; + j = dnsname_to_labels(buf, buf_len, j, s, strlen(s), &table); + if (j < 0) { + dnslabel_clear(&table); + return (int) j; + } + APPEND16(req->base.questions[i]->type); + APPEND16(req->base.questions[i]->dns_question_class); + } + + /* Add answer, authority, and additional sections. */ + for (i=0; i<3; ++i) { + struct server_reply_item *item; + if (i==0) + item = req->answer; + else if (i==1) + item = req->authority; + else + item = req->additional; + while (item) { + r = dnsname_to_labels(buf, buf_len, j, item->name, strlen(item->name), &table); + if (r < 0) + goto overflow; + j = r; + + APPEND16(item->type); + APPEND16(item->dns_question_class); + APPEND32(item->ttl); + if (item->is_name) { + off_t len_idx = j, name_start; + j += 2; + name_start = j; + r = dnsname_to_labels(buf, buf_len, j, item->data, strlen(item->data), &table); + if (r < 0) + goto overflow; + j = r; + t_ = htons( (short) (j-name_start) ); + memcpy(buf+len_idx, &t_, 2); + } else { + APPEND16(item->datalen); + if (j+item->datalen > (off_t)buf_len) + goto overflow; + memcpy(buf+j, item->data, item->datalen); + j += item->datalen; + } + item = item->next; + } + } + + if (j > 512) { +overflow: + j = 512; + buf[2] |= 0x02; /* set the truncated bit. */ + } + + req->response_len = j; + + if (!(req->response = mm_malloc(req->response_len))) { + server_request_free_answers(req); + dnslabel_clear(&table); + return (-1); + } + memcpy(req->response, buf, req->response_len); + server_request_free_answers(req); + dnslabel_clear(&table); + return (0); +} + +/* exported function */ +int +evdns_server_request_respond(struct evdns_server_request *req_, int err) +{ + struct server_request *req = TO_SERVER_REQUEST(req_); + struct evdns_server_port *port = req->port; + int r = -1; + + EVDNS_LOCK(port); + if (!req->response) { + if ((r = evdns_server_request_format_response(req, err))<0) + goto done; + } + + r = sendto(port->socket, req->response, (int)req->response_len, 0, + (struct sockaddr*) &req->addr, (ev_socklen_t)req->addrlen); + if (r<0) { + int sock_err = evutil_socket_geterror(port->socket); + if (EVUTIL_ERR_RW_RETRIABLE(sock_err)) + goto done; + + if (port->pending_replies) { + req->prev_pending = port->pending_replies->prev_pending; + req->next_pending = port->pending_replies; + req->prev_pending->next_pending = + req->next_pending->prev_pending = req; + } else { + req->prev_pending = req->next_pending = req; + port->pending_replies = req; + port->choked = 1; + + (void) event_del(&port->event); + event_assign(&port->event, port->event_base, port->socket, (port->closing?0:EV_READ) | EV_WRITE | EV_PERSIST, server_port_ready_callback, port); + + if (event_add(&port->event, NULL) < 0) { + log(EVDNS_LOG_WARN, "Error from libevent when adding event for DNS server"); + } + + } + + r = 1; + goto done; + } + if (server_request_free(req)) { + r = 0; + goto done; + } + + if (port->pending_replies) + server_port_flush(port); + + r = 0; +done: + EVDNS_UNLOCK(port); + return r; +} + +/* Free all storage held by RRs in req. */ +static void +server_request_free_answers(struct server_request *req) +{ + struct server_reply_item *victim, *next, **list; + int i; + for (i = 0; i < 3; ++i) { + if (i==0) + list = &req->answer; + else if (i==1) + list = &req->authority; + else + list = &req->additional; + + victim = *list; + while (victim) { + next = victim->next; + mm_free(victim->name); + if (victim->data) + mm_free(victim->data); + mm_free(victim); + victim = next; + } + *list = NULL; + } +} + +/* Free all storage held by req, and remove links to it. */ +/* return true iff we just wound up freeing the server_port. */ +static int +server_request_free(struct server_request *req) +{ + int i, rc=1, lock=0; + if (req->base.questions) { + for (i = 0; i < req->base.nquestions; ++i) + mm_free(req->base.questions[i]); + mm_free(req->base.questions); + } + + if (req->port) { + EVDNS_LOCK(req->port); + lock=1; + if (req->port->pending_replies == req) { + if (req->next_pending && req->next_pending != req) + req->port->pending_replies = req->next_pending; + else + req->port->pending_replies = NULL; + } + rc = --req->port->refcnt; + } + + if (req->response) { + mm_free(req->response); + } + + server_request_free_answers(req); + + if (req->next_pending && req->next_pending != req) { + req->next_pending->prev_pending = req->prev_pending; + req->prev_pending->next_pending = req->next_pending; + } + + if (rc == 0) { + EVDNS_UNLOCK(req->port); /* ????? nickm */ + server_port_free(req->port); + mm_free(req); + return (1); + } + if (lock) + EVDNS_UNLOCK(req->port); + mm_free(req); + return (0); +} + +/* Free all storage held by an evdns_server_port. Only called when */ +static void +server_port_free(struct evdns_server_port *port) +{ + EVUTIL_ASSERT(port); + EVUTIL_ASSERT(!port->refcnt); + EVUTIL_ASSERT(!port->pending_replies); + if (port->socket > 0) { + evutil_closesocket(port->socket); + port->socket = -1; + } + (void) event_del(&port->event); + event_debug_unassign(&port->event); + EVTHREAD_FREE_LOCK(port->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + mm_free(port); +} + +/* exported function */ +int +evdns_server_request_drop(struct evdns_server_request *req_) +{ + struct server_request *req = TO_SERVER_REQUEST(req_); + server_request_free(req); + return 0; +} + +/* exported function */ +int +evdns_server_request_get_requesting_addr(struct evdns_server_request *req_, struct sockaddr *sa, int addr_len) +{ + struct server_request *req = TO_SERVER_REQUEST(req_); + if (addr_len < (int)req->addrlen) + return -1; + memcpy(sa, &(req->addr), req->addrlen); + return req->addrlen; +} + +#undef APPEND16 +#undef APPEND32 + +/* this is a libevent callback function which is called when a request */ +/* has timed out. */ +static void +evdns_request_timeout_callback(evutil_socket_t fd, short events, void *arg) { + struct request *const req = (struct request *) arg; + struct evdns_base *base = req->base; + + (void) fd; + (void) events; + + log(EVDNS_LOG_DEBUG, "Request %p timed out", arg); + EVDNS_LOCK(base); + + if (req->tx_count >= req->base->global_max_retransmits) { + struct nameserver *ns = req->ns; + /* this request has failed */ + log(EVDNS_LOG_DEBUG, "Giving up on request %p; tx_count==%d", + arg, req->tx_count); + reply_schedule_callback(req, 0, DNS_ERR_TIMEOUT, NULL); + + request_finished(req, &REQ_HEAD(req->base, req->trans_id), 1); + nameserver_failed(ns, "request timed out."); + } else { + /* retransmit it */ + log(EVDNS_LOG_DEBUG, "Retransmitting request %p; tx_count==%d", + arg, req->tx_count); + (void) evtimer_del(&req->timeout_event); + request_swap_ns(req, nameserver_pick(base)); + evdns_request_transmit(req); + + req->ns->timedout++; + if (req->ns->timedout > req->base->global_max_nameserver_timeout) { + req->ns->timedout = 0; + nameserver_failed(req->ns, "request timed out."); + } + } + + EVDNS_UNLOCK(base); +} + +/* try to send a request to a given server. */ +/* */ +/* return: */ +/* 0 ok */ +/* 1 temporary failure */ +/* 2 other failure */ +static int +evdns_request_transmit_to(struct request *req, struct nameserver *server) { + int r; + ASSERT_LOCKED(req->base); + ASSERT_VALID_REQUEST(req); + + if (server->requests_inflight == 1 && + req->base->disable_when_inactive && + event_add(&server->event, NULL) < 0) { + return 1; + } + + r = sendto(server->socket, (void*)req->request, req->request_len, 0, + (struct sockaddr *)&server->address, server->addrlen); + if (r < 0) { + int err = evutil_socket_geterror(server->socket); + if (EVUTIL_ERR_RW_RETRIABLE(err)) + return 1; + nameserver_failed(req->ns, evutil_socket_error_to_string(err)); + return 2; + } else if (r != (int)req->request_len) { + return 1; /* short write */ + } else { + return 0; + } +} + +/* try to send a request, updating the fields of the request */ +/* as needed */ +/* */ +/* return: */ +/* 0 ok */ +/* 1 failed */ +static int +evdns_request_transmit(struct request *req) { + int retcode = 0, r; + + ASSERT_LOCKED(req->base); + ASSERT_VALID_REQUEST(req); + /* if we fail to send this packet then this flag marks it */ + /* for evdns_transmit */ + req->transmit_me = 1; + EVUTIL_ASSERT(req->trans_id != 0xffff); + + if (!req->ns) + { + /* unable to transmit request if no nameservers */ + return 1; + } + + if (req->ns->choked) { + /* don't bother trying to write to a socket */ + /* which we have had EAGAIN from */ + return 1; + } + + r = evdns_request_transmit_to(req, req->ns); + switch (r) { + case 1: + /* temp failure */ + req->ns->choked = 1; + nameserver_write_waiting(req->ns, 1); + return 1; + case 2: + /* failed to transmit the request entirely. */ + retcode = 1; + /* fall through: we'll set a timeout, which will time out, + * and make us retransmit the request anyway. */ + default: + /* all ok */ + log(EVDNS_LOG_DEBUG, + "Setting timeout for request %p, sent to nameserver %p", req, req->ns); + if (evtimer_add(&req->timeout_event, &req->base->global_timeout) < 0) { + log(EVDNS_LOG_WARN, + "Error from libevent when adding timer for request %p", + req); + /* ???? Do more? */ + } + req->tx_count++; + req->transmit_me = 0; + return retcode; + } +} + +static void +nameserver_probe_callback(int result, char type, int count, int ttl, void *addresses, void *arg) { + struct nameserver *const ns = (struct nameserver *) arg; + (void) type; + (void) count; + (void) ttl; + (void) addresses; + + if (result == DNS_ERR_CANCEL) { + /* We canceled this request because the nameserver came up + * for some other reason. Do not change our opinion about + * the nameserver. */ + return; + } + + EVDNS_LOCK(ns->base); + ns->probe_request = NULL; + if (result == DNS_ERR_NONE || result == DNS_ERR_NOTEXIST) { + /* this is a good reply */ + nameserver_up(ns); + } else { + nameserver_probe_failed(ns); + } + EVDNS_UNLOCK(ns->base); +} + +static void +nameserver_send_probe(struct nameserver *const ns) { + struct evdns_request *handle; + struct request *req; + char addrbuf[128]; + /* here we need to send a probe to a given nameserver */ + /* in the hope that it is up now. */ + + ASSERT_LOCKED(ns->base); + log(EVDNS_LOG_DEBUG, "Sending probe to %s", + evutil_format_sockaddr_port_( + (struct sockaddr *)&ns->address, + addrbuf, sizeof(addrbuf))); + handle = mm_calloc(1, sizeof(*handle)); + if (!handle) return; + req = request_new(ns->base, handle, TYPE_A, "google.com", DNS_QUERY_NO_SEARCH, nameserver_probe_callback, ns); + if (!req) { + mm_free(handle); + return; + } + ns->probe_request = handle; + /* we force this into the inflight queue no matter what */ + request_trans_id_set(req, transaction_id_pick(ns->base)); + req->ns = ns; + request_submit(req); +} + +/* returns: */ +/* 0 didn't try to transmit anything */ +/* 1 tried to transmit something */ +static int +evdns_transmit(struct evdns_base *base) { + char did_try_to_transmit = 0; + int i; + + ASSERT_LOCKED(base); + for (i = 0; i < base->n_req_heads; ++i) { + if (base->req_heads[i]) { + struct request *const started_at = base->req_heads[i], *req = started_at; + /* first transmit all the requests which are currently waiting */ + do { + if (req->transmit_me) { + did_try_to_transmit = 1; + evdns_request_transmit(req); + } + + req = req->next; + } while (req != started_at); + } + } + + return did_try_to_transmit; +} + +/* exported function */ +int +evdns_base_count_nameservers(struct evdns_base *base) +{ + const struct nameserver *server; + int n = 0; + + EVDNS_LOCK(base); + server = base->server_head; + if (!server) + goto done; + do { + ++n; + server = server->next; + } while (server != base->server_head); +done: + EVDNS_UNLOCK(base); + return n; +} + +int +evdns_count_nameservers(void) +{ + return evdns_base_count_nameservers(current_base); +} + +/* exported function */ +int +evdns_base_clear_nameservers_and_suspend(struct evdns_base *base) +{ + struct nameserver *server, *started_at; + int i; + + EVDNS_LOCK(base); + server = base->server_head; + started_at = base->server_head; + if (!server) { + EVDNS_UNLOCK(base); + return 0; + } + while (1) { + struct nameserver *next = server->next; + (void) event_del(&server->event); + if (evtimer_initialized(&server->timeout_event)) + (void) evtimer_del(&server->timeout_event); + if (server->probe_request) { + evdns_cancel_request(server->base, server->probe_request); + server->probe_request = NULL; + } + if (server->socket >= 0) + evutil_closesocket(server->socket); + mm_free(server); + if (next == started_at) + break; + server = next; + } + base->server_head = NULL; + base->global_good_nameservers = 0; + + for (i = 0; i < base->n_req_heads; ++i) { + struct request *req, *req_started_at; + req = req_started_at = base->req_heads[i]; + while (req) { + struct request *next = req->next; + req->tx_count = req->reissue_count = 0; + req->ns = NULL; + /* ???? What to do about searches? */ + (void) evtimer_del(&req->timeout_event); + req->trans_id = 0; + req->transmit_me = 0; + + base->global_requests_waiting++; + evdns_request_insert(req, &base->req_waiting_head); + /* We want to insert these suspended elements at the front of + * the waiting queue, since they were pending before any of + * the waiting entries were added. This is a circular list, + * so we can just shift the start back by one.*/ + base->req_waiting_head = base->req_waiting_head->prev; + + if (next == req_started_at) + break; + req = next; + } + base->req_heads[i] = NULL; + } + + base->global_requests_inflight = 0; + + EVDNS_UNLOCK(base); + return 0; +} + +int +evdns_clear_nameservers_and_suspend(void) +{ + return evdns_base_clear_nameservers_and_suspend(current_base); +} + + +/* exported function */ +int +evdns_base_resume(struct evdns_base *base) +{ + EVDNS_LOCK(base); + evdns_requests_pump_waiting_queue(base); + EVDNS_UNLOCK(base); + + return 0; +} + +int +evdns_resume(void) +{ + return evdns_base_resume(current_base); +} + +static int +evdns_nameserver_add_impl_(struct evdns_base *base, const struct sockaddr *address, int addrlen) { + /* first check to see if we already have this nameserver */ + + const struct nameserver *server = base->server_head, *const started_at = base->server_head; + struct nameserver *ns; + int err = 0; + char addrbuf[128]; + + ASSERT_LOCKED(base); + if (server) { + do { + if (!evutil_sockaddr_cmp((struct sockaddr*)&server->address, address, 1)) return 3; + server = server->next; + } while (server != started_at); + } + if (addrlen > (int)sizeof(ns->address)) { + log(EVDNS_LOG_DEBUG, "Addrlen %d too long.", (int)addrlen); + return 2; + } + + ns = (struct nameserver *) mm_malloc(sizeof(struct nameserver)); + if (!ns) return -1; + + memset(ns, 0, sizeof(struct nameserver)); + ns->base = base; + + evtimer_assign(&ns->timeout_event, ns->base->event_base, nameserver_prod_callback, ns); + + ns->socket = evutil_socket_(address->sa_family, + SOCK_DGRAM|EVUTIL_SOCK_NONBLOCK|EVUTIL_SOCK_CLOEXEC, 0); + if (ns->socket < 0) { err = 1; goto out1; } + + if (base->global_outgoing_addrlen && + !evutil_sockaddr_is_loopback_(address)) { + if (bind(ns->socket, + (struct sockaddr*)&base->global_outgoing_address, + base->global_outgoing_addrlen) < 0) { + log(EVDNS_LOG_WARN,"Couldn't bind to outgoing address"); + err = 2; + goto out2; + } + } + + memcpy(&ns->address, address, addrlen); + ns->addrlen = addrlen; + ns->state = 1; + event_assign(&ns->event, ns->base->event_base, ns->socket, + EV_READ | EV_PERSIST, nameserver_ready_callback, ns); + if (!base->disable_when_inactive && event_add(&ns->event, NULL) < 0) { + err = 2; + goto out2; + } + + log(EVDNS_LOG_DEBUG, "Added nameserver %s as %p", + evutil_format_sockaddr_port_(address, addrbuf, sizeof(addrbuf)), ns); + + /* insert this nameserver into the list of them */ + if (!base->server_head) { + ns->next = ns->prev = ns; + base->server_head = ns; + } else { + ns->next = base->server_head->next; + ns->prev = base->server_head; + base->server_head->next = ns; + ns->next->prev = ns; + } + + base->global_good_nameservers++; + + return 0; + +out2: + evutil_closesocket(ns->socket); +out1: + event_debug_unassign(&ns->event); + mm_free(ns); + log(EVDNS_LOG_WARN, "Unable to add nameserver %s: error %d", + evutil_format_sockaddr_port_(address, addrbuf, sizeof(addrbuf)), err); + return err; +} + +/* exported function */ +int +evdns_base_nameserver_add(struct evdns_base *base, unsigned long int address) +{ + struct sockaddr_in sin; + int res; + memset(&sin, 0, sizeof(sin)); + sin.sin_addr.s_addr = address; + sin.sin_port = htons(53); + sin.sin_family = AF_INET; + EVDNS_LOCK(base); + res = evdns_nameserver_add_impl_(base, (struct sockaddr*)&sin, sizeof(sin)); + EVDNS_UNLOCK(base); + return res; +} + +int +evdns_nameserver_add(unsigned long int address) { + if (!current_base) + current_base = evdns_base_new(NULL, 0); + return evdns_base_nameserver_add(current_base, address); +} + +static void +sockaddr_setport(struct sockaddr *sa, ev_uint16_t port) +{ + if (sa->sa_family == AF_INET) { + ((struct sockaddr_in *)sa)->sin_port = htons(port); + } else if (sa->sa_family == AF_INET6) { + ((struct sockaddr_in6 *)sa)->sin6_port = htons(port); + } +} + +static ev_uint16_t +sockaddr_getport(struct sockaddr *sa) +{ + if (sa->sa_family == AF_INET) { + return ntohs(((struct sockaddr_in *)sa)->sin_port); + } else if (sa->sa_family == AF_INET6) { + return ntohs(((struct sockaddr_in6 *)sa)->sin6_port); + } else { + return 0; + } +} + +/* exported function */ +int +evdns_base_nameserver_ip_add(struct evdns_base *base, const char *ip_as_string) { + struct sockaddr_storage ss; + struct sockaddr *sa; + int len = sizeof(ss); + int res; + if (evutil_parse_sockaddr_port(ip_as_string, (struct sockaddr *)&ss, + &len)) { + log(EVDNS_LOG_WARN, "Unable to parse nameserver address %s", + ip_as_string); + return 4; + } + sa = (struct sockaddr *) &ss; + if (sockaddr_getport(sa) == 0) + sockaddr_setport(sa, 53); + + EVDNS_LOCK(base); + res = evdns_nameserver_add_impl_(base, sa, len); + EVDNS_UNLOCK(base); + return res; +} + +int +evdns_nameserver_ip_add(const char *ip_as_string) { + if (!current_base) + current_base = evdns_base_new(NULL, 0); + return evdns_base_nameserver_ip_add(current_base, ip_as_string); +} + +int +evdns_base_nameserver_sockaddr_add(struct evdns_base *base, + const struct sockaddr *sa, ev_socklen_t len, unsigned flags) +{ + int res; + EVUTIL_ASSERT(base); + EVDNS_LOCK(base); + res = evdns_nameserver_add_impl_(base, sa, len); + EVDNS_UNLOCK(base); + return res; +} + +int +evdns_base_get_nameserver_addr(struct evdns_base *base, int idx, + struct sockaddr *sa, ev_socklen_t len) +{ + int result = -1; + int i; + struct nameserver *server; + EVDNS_LOCK(base); + server = base->server_head; + for (i = 0; i < idx && server; ++i, server = server->next) { + if (server->next == base->server_head) + goto done; + } + if (! server) + goto done; + + if (server->addrlen > len) { + result = (int) server->addrlen; + goto done; + } + + memcpy(sa, &server->address, server->addrlen); + result = (int) server->addrlen; +done: + EVDNS_UNLOCK(base); + return result; +} + +/* remove from the queue */ +static void +evdns_request_remove(struct request *req, struct request **head) +{ + ASSERT_LOCKED(req->base); + ASSERT_VALID_REQUEST(req); + +#if 0 + { + struct request *ptr; + int found = 0; + EVUTIL_ASSERT(*head != NULL); + + ptr = *head; + do { + if (ptr == req) { + found = 1; + break; + } + ptr = ptr->next; + } while (ptr != *head); + EVUTIL_ASSERT(found); + + EVUTIL_ASSERT(req->next); + } +#endif + + if (req->next == req) { + /* only item in the list */ + *head = NULL; + } else { + req->next->prev = req->prev; + req->prev->next = req->next; + if (*head == req) *head = req->next; + } + req->next = req->prev = NULL; +} + +/* insert into the tail of the queue */ +static void +evdns_request_insert(struct request *req, struct request **head) { + ASSERT_LOCKED(req->base); + ASSERT_VALID_REQUEST(req); + if (!*head) { + *head = req; + req->next = req->prev = req; + return; + } + + req->prev = (*head)->prev; + req->prev->next = req; + req->next = *head; + (*head)->prev = req; +} + +static int +string_num_dots(const char *s) { + int count = 0; + while ((s = strchr(s, '.'))) { + s++; + count++; + } + return count; +} + +static struct request * +request_new(struct evdns_base *base, struct evdns_request *handle, int type, + const char *name, int flags, evdns_callback_type callback, + void *user_ptr) { + + const char issuing_now = + (base->global_requests_inflight < base->global_max_requests_inflight) ? 1 : 0; + + const size_t name_len = strlen(name); + const size_t request_max_len = evdns_request_len(name_len); + const u16 trans_id = issuing_now ? transaction_id_pick(base) : 0xffff; + /* the request data is alloced in a single block with the header */ + struct request *const req = + mm_malloc(sizeof(struct request) + request_max_len); + int rlen; + char namebuf[256]; + (void) flags; + + ASSERT_LOCKED(base); + + if (!req) return NULL; + + if (name_len >= sizeof(namebuf)) { + mm_free(req); + return NULL; + } + + memset(req, 0, sizeof(struct request)); + req->base = base; + + evtimer_assign(&req->timeout_event, req->base->event_base, evdns_request_timeout_callback, req); + + if (base->global_randomize_case) { + unsigned i; + char randbits[(sizeof(namebuf)+7)/8]; + strlcpy(namebuf, name, sizeof(namebuf)); + evutil_secure_rng_get_bytes(randbits, (name_len+7)/8); + for (i = 0; i < name_len; ++i) { + if (EVUTIL_ISALPHA_(namebuf[i])) { + if ((randbits[i >> 3] & (1<<(i & 7)))) + namebuf[i] |= 0x20; + else + namebuf[i] &= ~0x20; + } + } + name = namebuf; + } + + /* request data lives just after the header */ + req->request = ((u8 *) req) + sizeof(struct request); + /* denotes that the request data shouldn't be free()ed */ + req->request_appended = 1; + rlen = evdns_request_data_build(name, name_len, trans_id, + type, CLASS_INET, req->request, request_max_len); + if (rlen < 0) + goto err1; + + req->request_len = rlen; + req->trans_id = trans_id; + req->tx_count = 0; + req->request_type = type; + req->user_pointer = user_ptr; + req->user_callback = callback; + req->ns = issuing_now ? nameserver_pick(base) : NULL; + req->next = req->prev = NULL; + req->handle = handle; + if (handle) { + handle->current_req = req; + handle->base = base; + } + + return req; +err1: + mm_free(req); + return NULL; +} + +static void +request_submit(struct request *const req) { + struct evdns_base *base = req->base; + ASSERT_LOCKED(base); + ASSERT_VALID_REQUEST(req); + if (req->ns) { + /* if it has a nameserver assigned then this is going */ + /* straight into the inflight queue */ + evdns_request_insert(req, &REQ_HEAD(base, req->trans_id)); + + base->global_requests_inflight++; + req->ns->requests_inflight++; + + evdns_request_transmit(req); + } else { + evdns_request_insert(req, &base->req_waiting_head); + base->global_requests_waiting++; + } +} + +/* exported function */ +void +evdns_cancel_request(struct evdns_base *base, struct evdns_request *handle) +{ + struct request *req; + + if (!handle->current_req) + return; + + if (!base) { + /* This redundancy is silly; can we fix it? (Not for 2.0) XXXX */ + base = handle->base; + if (!base) + base = handle->current_req->base; + } + + EVDNS_LOCK(base); + if (handle->pending_cb) { + EVDNS_UNLOCK(base); + return; + } + + req = handle->current_req; + ASSERT_VALID_REQUEST(req); + + reply_schedule_callback(req, 0, DNS_ERR_CANCEL, NULL); + if (req->ns) { + /* remove from inflight queue */ + request_finished(req, &REQ_HEAD(base, req->trans_id), 1); + } else { + /* remove from global_waiting head */ + request_finished(req, &base->req_waiting_head, 1); + } + EVDNS_UNLOCK(base); +} + +/* exported function */ +struct evdns_request * +evdns_base_resolve_ipv4(struct evdns_base *base, const char *name, int flags, + evdns_callback_type callback, void *ptr) { + struct evdns_request *handle; + struct request *req; + log(EVDNS_LOG_DEBUG, "Resolve requested for %s", name); + handle = mm_calloc(1, sizeof(*handle)); + if (handle == NULL) + return NULL; + EVDNS_LOCK(base); + if (flags & DNS_QUERY_NO_SEARCH) { + req = + request_new(base, handle, TYPE_A, name, flags, + callback, ptr); + if (req) + request_submit(req); + } else { + search_request_new(base, handle, TYPE_A, name, flags, + callback, ptr); + } + if (handle->current_req == NULL) { + mm_free(handle); + handle = NULL; + } + EVDNS_UNLOCK(base); + return handle; +} + +int evdns_resolve_ipv4(const char *name, int flags, + evdns_callback_type callback, void *ptr) +{ + return evdns_base_resolve_ipv4(current_base, name, flags, callback, ptr) + ? 0 : -1; +} + + +/* exported function */ +struct evdns_request * +evdns_base_resolve_ipv6(struct evdns_base *base, + const char *name, int flags, + evdns_callback_type callback, void *ptr) +{ + struct evdns_request *handle; + struct request *req; + log(EVDNS_LOG_DEBUG, "Resolve requested for %s", name); + handle = mm_calloc(1, sizeof(*handle)); + if (handle == NULL) + return NULL; + EVDNS_LOCK(base); + if (flags & DNS_QUERY_NO_SEARCH) { + req = request_new(base, handle, TYPE_AAAA, name, flags, + callback, ptr); + if (req) + request_submit(req); + } else { + search_request_new(base, handle, TYPE_AAAA, name, flags, + callback, ptr); + } + if (handle->current_req == NULL) { + mm_free(handle); + handle = NULL; + } + EVDNS_UNLOCK(base); + return handle; +} + +int evdns_resolve_ipv6(const char *name, int flags, + evdns_callback_type callback, void *ptr) { + return evdns_base_resolve_ipv6(current_base, name, flags, callback, ptr) + ? 0 : -1; +} + +struct evdns_request * +evdns_base_resolve_reverse(struct evdns_base *base, const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr) { + char buf[32]; + struct evdns_request *handle; + struct request *req; + u32 a; + EVUTIL_ASSERT(in); + a = ntohl(in->s_addr); + evutil_snprintf(buf, sizeof(buf), "%d.%d.%d.%d.in-addr.arpa", + (int)(u8)((a )&0xff), + (int)(u8)((a>>8 )&0xff), + (int)(u8)((a>>16)&0xff), + (int)(u8)((a>>24)&0xff)); + handle = mm_calloc(1, sizeof(*handle)); + if (handle == NULL) + return NULL; + log(EVDNS_LOG_DEBUG, "Resolve requested for %s (reverse)", buf); + EVDNS_LOCK(base); + req = request_new(base, handle, TYPE_PTR, buf, flags, callback, ptr); + if (req) + request_submit(req); + if (handle->current_req == NULL) { + mm_free(handle); + handle = NULL; + } + EVDNS_UNLOCK(base); + return (handle); +} + +int evdns_resolve_reverse(const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr) { + return evdns_base_resolve_reverse(current_base, in, flags, callback, ptr) + ? 0 : -1; +} + +struct evdns_request * +evdns_base_resolve_reverse_ipv6(struct evdns_base *base, const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr) { + /* 32 nybbles, 32 periods, "ip6.arpa", NUL. */ + char buf[73]; + char *cp; + struct evdns_request *handle; + struct request *req; + int i; + EVUTIL_ASSERT(in); + cp = buf; + for (i=15; i >= 0; --i) { + u8 byte = in->s6_addr[i]; + *cp++ = "0123456789abcdef"[byte & 0x0f]; + *cp++ = '.'; + *cp++ = "0123456789abcdef"[byte >> 4]; + *cp++ = '.'; + } + EVUTIL_ASSERT(cp + strlen("ip6.arpa") < buf+sizeof(buf)); + memcpy(cp, "ip6.arpa", strlen("ip6.arpa")+1); + handle = mm_calloc(1, sizeof(*handle)); + if (handle == NULL) + return NULL; + log(EVDNS_LOG_DEBUG, "Resolve requested for %s (reverse)", buf); + EVDNS_LOCK(base); + req = request_new(base, handle, TYPE_PTR, buf, flags, callback, ptr); + if (req) + request_submit(req); + if (handle->current_req == NULL) { + mm_free(handle); + handle = NULL; + } + EVDNS_UNLOCK(base); + return (handle); +} + +int evdns_resolve_reverse_ipv6(const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr) { + return evdns_base_resolve_reverse_ipv6(current_base, in, flags, callback, ptr) + ? 0 : -1; +} + +/* ================================================================= */ +/* Search support */ +/* */ +/* the libc resolver has support for searching a number of domains */ +/* to find a name. If nothing else then it takes the single domain */ +/* from the gethostname() call. */ +/* */ +/* It can also be configured via the domain and search options in a */ +/* resolv.conf. */ +/* */ +/* The ndots option controls how many dots it takes for the resolver */ +/* to decide that a name is non-local and so try a raw lookup first. */ + +struct search_domain { + int len; + struct search_domain *next; + /* the text string is appended to this structure */ +}; + +struct search_state { + int refcount; + int ndots; + int num_domains; + struct search_domain *head; +}; + +static void +search_state_decref(struct search_state *const state) { + if (!state) return; + state->refcount--; + if (!state->refcount) { + struct search_domain *next, *dom; + for (dom = state->head; dom; dom = next) { + next = dom->next; + mm_free(dom); + } + mm_free(state); + } +} + +static struct search_state * +search_state_new(void) { + struct search_state *state = (struct search_state *) mm_malloc(sizeof(struct search_state)); + if (!state) return NULL; + memset(state, 0, sizeof(struct search_state)); + state->refcount = 1; + state->ndots = 1; + + return state; +} + +static void +search_postfix_clear(struct evdns_base *base) { + search_state_decref(base->global_search_state); + + base->global_search_state = search_state_new(); +} + +/* exported function */ +void +evdns_base_search_clear(struct evdns_base *base) +{ + EVDNS_LOCK(base); + search_postfix_clear(base); + EVDNS_UNLOCK(base); +} + +void +evdns_search_clear(void) { + evdns_base_search_clear(current_base); +} + +static void +search_postfix_add(struct evdns_base *base, const char *domain) { + size_t domain_len; + struct search_domain *sdomain; + while (domain[0] == '.') domain++; + domain_len = strlen(domain); + + ASSERT_LOCKED(base); + if (!base->global_search_state) base->global_search_state = search_state_new(); + if (!base->global_search_state) return; + base->global_search_state->num_domains++; + + sdomain = (struct search_domain *) mm_malloc(sizeof(struct search_domain) + domain_len); + if (!sdomain) return; + memcpy( ((u8 *) sdomain) + sizeof(struct search_domain), domain, domain_len); + sdomain->next = base->global_search_state->head; + sdomain->len = (int) domain_len; + + base->global_search_state->head = sdomain; +} + +/* reverse the order of members in the postfix list. This is needed because, */ +/* when parsing resolv.conf we push elements in the wrong order */ +static void +search_reverse(struct evdns_base *base) { + struct search_domain *cur, *prev = NULL, *next; + ASSERT_LOCKED(base); + cur = base->global_search_state->head; + while (cur) { + next = cur->next; + cur->next = prev; + prev = cur; + cur = next; + } + + base->global_search_state->head = prev; +} + +/* exported function */ +void +evdns_base_search_add(struct evdns_base *base, const char *domain) { + EVDNS_LOCK(base); + search_postfix_add(base, domain); + EVDNS_UNLOCK(base); +} +void +evdns_search_add(const char *domain) { + evdns_base_search_add(current_base, domain); +} + +/* exported function */ +void +evdns_base_search_ndots_set(struct evdns_base *base, const int ndots) { + EVDNS_LOCK(base); + if (!base->global_search_state) base->global_search_state = search_state_new(); + if (base->global_search_state) + base->global_search_state->ndots = ndots; + EVDNS_UNLOCK(base); +} +void +evdns_search_ndots_set(const int ndots) { + evdns_base_search_ndots_set(current_base, ndots); +} + +static void +search_set_from_hostname(struct evdns_base *base) { + char hostname[HOST_NAME_MAX + 1], *domainname; + + ASSERT_LOCKED(base); + search_postfix_clear(base); + if (gethostname(hostname, sizeof(hostname))) return; + domainname = strchr(hostname, '.'); + if (!domainname) return; + search_postfix_add(base, domainname); +} + +/* warning: returns malloced string */ +static char * +search_make_new(const struct search_state *const state, int n, const char *const base_name) { + const size_t base_len = strlen(base_name); + const char need_to_append_dot = base_name[base_len - 1] == '.' ? 0 : 1; + struct search_domain *dom; + + for (dom = state->head; dom; dom = dom->next) { + if (!n--) { + /* this is the postfix we want */ + /* the actual postfix string is kept at the end of the structure */ + const u8 *const postfix = ((u8 *) dom) + sizeof(struct search_domain); + const int postfix_len = dom->len; + char *const newname = (char *) mm_malloc(base_len + need_to_append_dot + postfix_len + 1); + if (!newname) return NULL; + memcpy(newname, base_name, base_len); + if (need_to_append_dot) newname[base_len] = '.'; + memcpy(newname + base_len + need_to_append_dot, postfix, postfix_len); + newname[base_len + need_to_append_dot + postfix_len] = 0; + return newname; + } + } + + /* we ran off the end of the list and still didn't find the requested string */ + EVUTIL_ASSERT(0); + return NULL; /* unreachable; stops warnings in some compilers. */ +} + +static struct request * +search_request_new(struct evdns_base *base, struct evdns_request *handle, + int type, const char *const name, int flags, + evdns_callback_type user_callback, void *user_arg) { + ASSERT_LOCKED(base); + EVUTIL_ASSERT(type == TYPE_A || type == TYPE_AAAA); + EVUTIL_ASSERT(handle->current_req == NULL); + if ( ((flags & DNS_QUERY_NO_SEARCH) == 0) && + base->global_search_state && + base->global_search_state->num_domains) { + /* we have some domains to search */ + struct request *req; + if (string_num_dots(name) >= base->global_search_state->ndots) { + req = request_new(base, handle, type, name, flags, user_callback, user_arg); + if (!req) return NULL; + handle->search_index = -1; + } else { + char *const new_name = search_make_new(base->global_search_state, 0, name); + if (!new_name) return NULL; + req = request_new(base, handle, type, new_name, flags, user_callback, user_arg); + mm_free(new_name); + if (!req) return NULL; + handle->search_index = 0; + } + EVUTIL_ASSERT(handle->search_origname == NULL); + handle->search_origname = mm_strdup(name); + if (handle->search_origname == NULL) { + /* XXX Should we dealloc req? If yes, how? */ + if (req) + mm_free(req); + return NULL; + } + handle->search_state = base->global_search_state; + handle->search_flags = flags; + base->global_search_state->refcount++; + request_submit(req); + return req; + } else { + struct request *const req = request_new(base, handle, type, name, flags, user_callback, user_arg); + if (!req) return NULL; + request_submit(req); + return req; + } +} + +/* this is called when a request has failed to find a name. We need to check */ +/* if it is part of a search and, if so, try the next name in the list */ +/* returns: */ +/* 0 another request has been submitted */ +/* 1 no more requests needed */ +static int +search_try_next(struct evdns_request *const handle) { + struct request *req = handle->current_req; + struct evdns_base *base = req->base; + struct request *newreq; + ASSERT_LOCKED(base); + if (handle->search_state) { + /* it is part of a search */ + char *new_name; + handle->search_index++; + if (handle->search_index >= handle->search_state->num_domains) { + /* no more postfixes to try, however we may need to try */ + /* this name without a postfix */ + if (string_num_dots(handle->search_origname) < handle->search_state->ndots) { + /* yep, we need to try it raw */ + newreq = request_new(base, NULL, req->request_type, handle->search_origname, handle->search_flags, req->user_callback, req->user_pointer); + log(EVDNS_LOG_DEBUG, "Search: trying raw query %s", handle->search_origname); + if (newreq) { + search_request_finished(handle); + goto submit_next; + } + } + return 1; + } + + new_name = search_make_new(handle->search_state, handle->search_index, handle->search_origname); + if (!new_name) return 1; + log(EVDNS_LOG_DEBUG, "Search: now trying %s (%d)", new_name, handle->search_index); + newreq = request_new(base, NULL, req->request_type, new_name, handle->search_flags, req->user_callback, req->user_pointer); + mm_free(new_name); + if (!newreq) return 1; + goto submit_next; + } + return 1; + +submit_next: + request_finished(req, &REQ_HEAD(req->base, req->trans_id), 0); + handle->current_req = newreq; + newreq->handle = handle; + request_submit(newreq); + return 0; +} + +static void +search_request_finished(struct evdns_request *const handle) { + ASSERT_LOCKED(handle->current_req->base); + if (handle->search_state) { + search_state_decref(handle->search_state); + handle->search_state = NULL; + } + if (handle->search_origname) { + mm_free(handle->search_origname); + handle->search_origname = NULL; + } +} + +/* ================================================================= */ +/* Parsing resolv.conf files */ + +static void +evdns_resolv_set_defaults(struct evdns_base *base, int flags) { + /* if the file isn't found then we assume a local resolver */ + ASSERT_LOCKED(base); + if (flags & DNS_OPTION_SEARCH) search_set_from_hostname(base); + if (flags & DNS_OPTION_NAMESERVERS) evdns_base_nameserver_ip_add(base,"127.0.0.1"); +} + +#ifndef EVENT__HAVE_STRTOK_R +static char * +strtok_r(char *s, const char *delim, char **state) { + char *cp, *start; + start = cp = s ? s : *state; + if (!cp) + return NULL; + while (*cp && !strchr(delim, *cp)) + ++cp; + if (!*cp) { + if (cp == start) + return NULL; + *state = NULL; + return start; + } else { + *cp++ = '\0'; + *state = cp; + return start; + } +} +#endif + +/* helper version of atoi which returns -1 on error */ +static int +strtoint(const char *const str) +{ + char *endptr; + const int r = strtol(str, &endptr, 10); + if (*endptr) return -1; + return r; +} + +/* Parse a number of seconds into a timeval; return -1 on error. */ +static int +evdns_strtotimeval(const char *const str, struct timeval *out) +{ + double d; + char *endptr; + d = strtod(str, &endptr); + if (*endptr) return -1; + if (d < 0) return -1; + out->tv_sec = (int) d; + out->tv_usec = (int) ((d - (int) d)*1000000); + if (out->tv_sec == 0 && out->tv_usec < 1000) /* less than 1 msec */ + return -1; + return 0; +} + +/* helper version of atoi that returns -1 on error and clips to bounds. */ +static int +strtoint_clipped(const char *const str, int min, int max) +{ + int r = strtoint(str); + if (r == -1) + return r; + else if (rmax) + return max; + else + return r; +} + +static int +evdns_base_set_max_requests_inflight(struct evdns_base *base, int maxinflight) +{ + int old_n_heads = base->n_req_heads, n_heads; + struct request **old_heads = base->req_heads, **new_heads, *req; + int i; + + ASSERT_LOCKED(base); + if (maxinflight < 1) + maxinflight = 1; + n_heads = (maxinflight+4) / 5; + EVUTIL_ASSERT(n_heads > 0); + new_heads = mm_calloc(n_heads, sizeof(struct request*)); + if (!new_heads) + return (-1); + if (old_heads) { + for (i = 0; i < old_n_heads; ++i) { + while (old_heads[i]) { + req = old_heads[i]; + evdns_request_remove(req, &old_heads[i]); + evdns_request_insert(req, &new_heads[req->trans_id % n_heads]); + } + } + mm_free(old_heads); + } + base->req_heads = new_heads; + base->n_req_heads = n_heads; + base->global_max_requests_inflight = maxinflight; + return (0); +} + +/* exported function */ +int +evdns_base_set_option(struct evdns_base *base, + const char *option, const char *val) +{ + int res; + EVDNS_LOCK(base); + res = evdns_base_set_option_impl(base, option, val, DNS_OPTIONS_ALL); + EVDNS_UNLOCK(base); + return res; +} + +static inline int +str_matches_option(const char *s1, const char *optionname) +{ + /* Option names are given as "option:" We accept either 'option' in + * s1, or 'option:randomjunk'. The latter form is to implement the + * resolv.conf parser. */ + size_t optlen = strlen(optionname); + size_t slen = strlen(s1); + if (slen == optlen || slen == optlen - 1) + return !strncmp(s1, optionname, slen); + else if (slen > optlen) + return !strncmp(s1, optionname, optlen); + else + return 0; +} + +static int +evdns_base_set_option_impl(struct evdns_base *base, + const char *option, const char *val, int flags) +{ + ASSERT_LOCKED(base); + if (str_matches_option(option, "ndots:")) { + const int ndots = strtoint(val); + if (ndots == -1) return -1; + if (!(flags & DNS_OPTION_SEARCH)) return 0; + log(EVDNS_LOG_DEBUG, "Setting ndots to %d", ndots); + if (!base->global_search_state) base->global_search_state = search_state_new(); + if (!base->global_search_state) return -1; + base->global_search_state->ndots = ndots; + } else if (str_matches_option(option, "timeout:")) { + struct timeval tv; + if (evdns_strtotimeval(val, &tv) == -1) return -1; + if (!(flags & DNS_OPTION_MISC)) return 0; + log(EVDNS_LOG_DEBUG, "Setting timeout to %s", val); + memcpy(&base->global_timeout, &tv, sizeof(struct timeval)); + } else if (str_matches_option(option, "getaddrinfo-allow-skew:")) { + struct timeval tv; + if (evdns_strtotimeval(val, &tv) == -1) return -1; + if (!(flags & DNS_OPTION_MISC)) return 0; + log(EVDNS_LOG_DEBUG, "Setting getaddrinfo-allow-skew to %s", + val); + memcpy(&base->global_getaddrinfo_allow_skew, &tv, + sizeof(struct timeval)); + } else if (str_matches_option(option, "max-timeouts:")) { + const int maxtimeout = strtoint_clipped(val, 1, 255); + if (maxtimeout == -1) return -1; + if (!(flags & DNS_OPTION_MISC)) return 0; + log(EVDNS_LOG_DEBUG, "Setting maximum allowed timeouts to %d", + maxtimeout); + base->global_max_nameserver_timeout = maxtimeout; + } else if (str_matches_option(option, "max-inflight:")) { + const int maxinflight = strtoint_clipped(val, 1, 65000); + if (maxinflight == -1) return -1; + if (!(flags & DNS_OPTION_MISC)) return 0; + log(EVDNS_LOG_DEBUG, "Setting maximum inflight requests to %d", + maxinflight); + evdns_base_set_max_requests_inflight(base, maxinflight); + } else if (str_matches_option(option, "attempts:")) { + int retries = strtoint(val); + if (retries == -1) return -1; + if (retries > 255) retries = 255; + if (!(flags & DNS_OPTION_MISC)) return 0; + log(EVDNS_LOG_DEBUG, "Setting retries to %d", retries); + base->global_max_retransmits = retries; + } else if (str_matches_option(option, "randomize-case:")) { + int randcase = strtoint(val); + if (!(flags & DNS_OPTION_MISC)) return 0; + base->global_randomize_case = randcase; + } else if (str_matches_option(option, "bind-to:")) { + /* XXX This only applies to successive nameservers, not + * to already-configured ones. We might want to fix that. */ + int len = sizeof(base->global_outgoing_address); + if (!(flags & DNS_OPTION_NAMESERVERS)) return 0; + if (evutil_parse_sockaddr_port(val, + (struct sockaddr*)&base->global_outgoing_address, &len)) + return -1; + base->global_outgoing_addrlen = len; + } else if (str_matches_option(option, "initial-probe-timeout:")) { + struct timeval tv; + if (evdns_strtotimeval(val, &tv) == -1) return -1; + if (tv.tv_sec > 3600) + tv.tv_sec = 3600; + if (!(flags & DNS_OPTION_MISC)) return 0; + log(EVDNS_LOG_DEBUG, "Setting initial probe timeout to %s", + val); + memcpy(&base->global_nameserver_probe_initial_timeout, &tv, + sizeof(tv)); + } + return 0; +} + +int +evdns_set_option(const char *option, const char *val, int flags) +{ + if (!current_base) + current_base = evdns_base_new(NULL, 0); + return evdns_base_set_option(current_base, option, val); +} + +static void +resolv_conf_parse_line(struct evdns_base *base, char *const start, int flags) { + char *strtok_state; + static const char *const delims = " \t"; +#define NEXT_TOKEN strtok_r(NULL, delims, &strtok_state) + + + char *const first_token = strtok_r(start, delims, &strtok_state); + ASSERT_LOCKED(base); + if (!first_token) return; + + if (!strcmp(first_token, "nameserver") && (flags & DNS_OPTION_NAMESERVERS)) { + const char *const nameserver = NEXT_TOKEN; + + if (nameserver) + evdns_base_nameserver_ip_add(base, nameserver); + } else if (!strcmp(first_token, "domain") && (flags & DNS_OPTION_SEARCH)) { + const char *const domain = NEXT_TOKEN; + if (domain) { + search_postfix_clear(base); + search_postfix_add(base, domain); + } + } else if (!strcmp(first_token, "search") && (flags & DNS_OPTION_SEARCH)) { + const char *domain; + search_postfix_clear(base); + + while ((domain = NEXT_TOKEN)) { + search_postfix_add(base, domain); + } + search_reverse(base); + } else if (!strcmp(first_token, "options")) { + const char *option; + while ((option = NEXT_TOKEN)) { + const char *val = strchr(option, ':'); + evdns_base_set_option_impl(base, option, val ? val+1 : "", flags); + } + } +#undef NEXT_TOKEN +} + +/* exported function */ +/* returns: */ +/* 0 no errors */ +/* 1 failed to open file */ +/* 2 failed to stat file */ +/* 3 file too large */ +/* 4 out of memory */ +/* 5 short read from file */ +int +evdns_base_resolv_conf_parse(struct evdns_base *base, int flags, const char *const filename) { + int res; + EVDNS_LOCK(base); + res = evdns_base_resolv_conf_parse_impl(base, flags, filename); + EVDNS_UNLOCK(base); + return res; +} + +static char * +evdns_get_default_hosts_filename(void) +{ +#ifdef _WIN32 + /* Windows is a little coy about where it puts its configuration + * files. Sure, they're _usually_ in C:\windows\system32, but + * there's no reason in principle they couldn't be in + * W:\hoboken chicken emergency\ + */ + char path[MAX_PATH+1]; + static const char hostfile[] = "\\drivers\\etc\\hosts"; + char *path_out; + size_t len_out; + + if (! SHGetSpecialFolderPathA(NULL, path, CSIDL_SYSTEM, 0)) + return NULL; + len_out = strlen(path)+strlen(hostfile)+1; + path_out = mm_malloc(len_out); + evutil_snprintf(path_out, len_out, "%s%s", path, hostfile); + return path_out; +#else + return mm_strdup("/etc/hosts"); +#endif +} + +static int +evdns_base_resolv_conf_parse_impl(struct evdns_base *base, int flags, const char *const filename) { + size_t n; + char *resolv; + char *start; + int err = 0; + + log(EVDNS_LOG_DEBUG, "Parsing resolv.conf file %s", filename); + + if (flags & DNS_OPTION_HOSTSFILE) { + char *fname = evdns_get_default_hosts_filename(); + evdns_base_load_hosts(base, fname); + if (fname) + mm_free(fname); + } + + if ((err = evutil_read_file_(filename, &resolv, &n, 0)) < 0) { + if (err == -1) { + /* No file. */ + evdns_resolv_set_defaults(base, flags); + return 1; + } else { + return 2; + } + } + + start = resolv; + for (;;) { + char *const newline = strchr(start, '\n'); + if (!newline) { + resolv_conf_parse_line(base, start, flags); + break; + } else { + *newline = 0; + resolv_conf_parse_line(base, start, flags); + start = newline + 1; + } + } + + if (!base->server_head && (flags & DNS_OPTION_NAMESERVERS)) { + /* no nameservers were configured. */ + evdns_base_nameserver_ip_add(base, "127.0.0.1"); + err = 6; + } + if (flags & DNS_OPTION_SEARCH && (!base->global_search_state || base->global_search_state->num_domains == 0)) { + search_set_from_hostname(base); + } + + mm_free(resolv); + return err; +} + +int +evdns_resolv_conf_parse(int flags, const char *const filename) { + if (!current_base) + current_base = evdns_base_new(NULL, 0); + return evdns_base_resolv_conf_parse(current_base, flags, filename); +} + + +#ifdef _WIN32 +/* Add multiple nameservers from a space-or-comma-separated list. */ +static int +evdns_nameserver_ip_add_line(struct evdns_base *base, const char *ips) { + const char *addr; + char *buf; + int r; + ASSERT_LOCKED(base); + while (*ips) { + while (isspace(*ips) || *ips == ',' || *ips == '\t') + ++ips; + addr = ips; + while (isdigit(*ips) || *ips == '.' || *ips == ':' || + *ips=='[' || *ips==']') + ++ips; + buf = mm_malloc(ips-addr+1); + if (!buf) return 4; + memcpy(buf, addr, ips-addr); + buf[ips-addr] = '\0'; + r = evdns_base_nameserver_ip_add(base, buf); + mm_free(buf); + if (r) return r; + } + return 0; +} + +typedef DWORD(WINAPI *GetNetworkParams_fn_t)(FIXED_INFO *, DWORD*); + +/* Use the windows GetNetworkParams interface in iphlpapi.dll to */ +/* figure out what our nameservers are. */ +static int +load_nameservers_with_getnetworkparams(struct evdns_base *base) +{ + /* Based on MSDN examples and inspection of c-ares code. */ + FIXED_INFO *fixed; + HMODULE handle = 0; + ULONG size = sizeof(FIXED_INFO); + void *buf = NULL; + int status = 0, r, added_any; + IP_ADDR_STRING *ns; + GetNetworkParams_fn_t fn; + + ASSERT_LOCKED(base); + if (!(handle = evutil_load_windows_system_library_( + TEXT("iphlpapi.dll")))) { + log(EVDNS_LOG_WARN, "Could not open iphlpapi.dll"); + status = -1; + goto done; + } + if (!(fn = (GetNetworkParams_fn_t) GetProcAddress(handle, "GetNetworkParams"))) { + log(EVDNS_LOG_WARN, "Could not get address of function."); + status = -1; + goto done; + } + + buf = mm_malloc(size); + if (!buf) { status = 4; goto done; } + fixed = buf; + r = fn(fixed, &size); + if (r != ERROR_SUCCESS && r != ERROR_BUFFER_OVERFLOW) { + status = -1; + goto done; + } + if (r != ERROR_SUCCESS) { + mm_free(buf); + buf = mm_malloc(size); + if (!buf) { status = 4; goto done; } + fixed = buf; + r = fn(fixed, &size); + if (r != ERROR_SUCCESS) { + log(EVDNS_LOG_DEBUG, "fn() failed."); + status = -1; + goto done; + } + } + + EVUTIL_ASSERT(fixed); + added_any = 0; + ns = &(fixed->DnsServerList); + while (ns) { + r = evdns_nameserver_ip_add_line(base, ns->IpAddress.String); + if (r) { + log(EVDNS_LOG_DEBUG,"Could not add nameserver %s to list,error: %d", + (ns->IpAddress.String),(int)GetLastError()); + status = r; + } else { + ++added_any; + log(EVDNS_LOG_DEBUG,"Successfully added %s as nameserver",ns->IpAddress.String); + } + + ns = ns->Next; + } + + if (!added_any) { + log(EVDNS_LOG_DEBUG, "No nameservers added."); + if (status == 0) + status = -1; + } else { + status = 0; + } + + done: + if (buf) + mm_free(buf); + if (handle) + FreeLibrary(handle); + return status; +} + +static int +config_nameserver_from_reg_key(struct evdns_base *base, HKEY key, const TCHAR *subkey) +{ + char *buf; + DWORD bufsz = 0, type = 0; + int status = 0; + + ASSERT_LOCKED(base); + if (RegQueryValueEx(key, subkey, 0, &type, NULL, &bufsz) + != ERROR_MORE_DATA) + return -1; + if (!(buf = mm_malloc(bufsz))) + return -1; + + if (RegQueryValueEx(key, subkey, 0, &type, (LPBYTE)buf, &bufsz) + == ERROR_SUCCESS && bufsz > 1) { + status = evdns_nameserver_ip_add_line(base,buf); + } + + mm_free(buf); + return status; +} + +#define SERVICES_KEY TEXT("System\\CurrentControlSet\\Services\\") +#define WIN_NS_9X_KEY SERVICES_KEY TEXT("VxD\\MSTCP") +#define WIN_NS_NT_KEY SERVICES_KEY TEXT("Tcpip\\Parameters") + +static int +load_nameservers_from_registry(struct evdns_base *base) +{ + int found = 0; + int r; +#define TRY(k, name) \ + if (!found && config_nameserver_from_reg_key(base,k,TEXT(name)) == 0) { \ + log(EVDNS_LOG_DEBUG,"Found nameservers in %s/%s",#k,name); \ + found = 1; \ + } else if (!found) { \ + log(EVDNS_LOG_DEBUG,"Didn't find nameservers in %s/%s", \ + #k,#name); \ + } + + ASSERT_LOCKED(base); + + if (((int)GetVersion()) > 0) { /* NT */ + HKEY nt_key = 0, interfaces_key = 0; + + if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, WIN_NS_NT_KEY, 0, + KEY_READ, &nt_key) != ERROR_SUCCESS) { + log(EVDNS_LOG_DEBUG,"Couldn't open nt key, %d",(int)GetLastError()); + return -1; + } + r = RegOpenKeyEx(nt_key, TEXT("Interfaces"), 0, + KEY_QUERY_VALUE|KEY_ENUMERATE_SUB_KEYS, + &interfaces_key); + if (r != ERROR_SUCCESS) { + log(EVDNS_LOG_DEBUG,"Couldn't open interfaces key, %d",(int)GetLastError()); + return -1; + } + TRY(nt_key, "NameServer"); + TRY(nt_key, "DhcpNameServer"); + TRY(interfaces_key, "NameServer"); + TRY(interfaces_key, "DhcpNameServer"); + RegCloseKey(interfaces_key); + RegCloseKey(nt_key); + } else { + HKEY win_key = 0; + if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, WIN_NS_9X_KEY, 0, + KEY_READ, &win_key) != ERROR_SUCCESS) { + log(EVDNS_LOG_DEBUG, "Couldn't open registry key, %d", (int)GetLastError()); + return -1; + } + TRY(win_key, "NameServer"); + RegCloseKey(win_key); + } + + if (found == 0) { + log(EVDNS_LOG_WARN,"Didn't find any nameservers."); + } + + return found ? 0 : -1; +#undef TRY +} + +int +evdns_base_config_windows_nameservers(struct evdns_base *base) +{ + int r; + char *fname; + if (base == NULL) + base = current_base; + if (base == NULL) + return -1; + EVDNS_LOCK(base); + fname = evdns_get_default_hosts_filename(); + log(EVDNS_LOG_DEBUG, "Loading hosts entries from %s", fname); + evdns_base_load_hosts(base, fname); + if (fname) + mm_free(fname); + + if (load_nameservers_with_getnetworkparams(base) == 0) { + EVDNS_UNLOCK(base); + return 0; + } + r = load_nameservers_from_registry(base); + + EVDNS_UNLOCK(base); + return r; +} + +int +evdns_config_windows_nameservers(void) +{ + if (!current_base) { + current_base = evdns_base_new(NULL, 1); + return current_base == NULL ? -1 : 0; + } else { + return evdns_base_config_windows_nameservers(current_base); + } +} +#endif + +struct evdns_base * +evdns_base_new(struct event_base *event_base, int flags) +{ + struct evdns_base *base; + + if (evutil_secure_rng_init() < 0) { + log(EVDNS_LOG_WARN, "Unable to seed random number generator; " + "DNS can't run."); + return NULL; + } + + /* Give the evutil library a hook into its evdns-enabled + * functionality. We can't just call evdns_getaddrinfo directly or + * else libevent-core will depend on libevent-extras. */ + evutil_set_evdns_getaddrinfo_fn_(evdns_getaddrinfo); + + base = mm_malloc(sizeof(struct evdns_base)); + if (base == NULL) + return (NULL); + memset(base, 0, sizeof(struct evdns_base)); + base->req_waiting_head = NULL; + + EVTHREAD_ALLOC_LOCK(base->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + EVDNS_LOCK(base); + + /* Set max requests inflight and allocate req_heads. */ + base->req_heads = NULL; + + evdns_base_set_max_requests_inflight(base, 64); + + base->server_head = NULL; + base->event_base = event_base; + base->global_good_nameservers = base->global_requests_inflight = + base->global_requests_waiting = 0; + + base->global_timeout.tv_sec = 5; + base->global_timeout.tv_usec = 0; + base->global_max_reissues = 1; + base->global_max_retransmits = 3; + base->global_max_nameserver_timeout = 3; + base->global_search_state = NULL; + base->global_randomize_case = 1; + base->global_getaddrinfo_allow_skew.tv_sec = 3; + base->global_getaddrinfo_allow_skew.tv_usec = 0; + base->global_nameserver_probe_initial_timeout.tv_sec = 10; + base->global_nameserver_probe_initial_timeout.tv_usec = 0; + + TAILQ_INIT(&base->hostsdb); + +#define EVDNS_BASE_ALL_FLAGS (0x8001) + if (flags & ~EVDNS_BASE_ALL_FLAGS) { + flags = EVDNS_BASE_INITIALIZE_NAMESERVERS; + log(EVDNS_LOG_WARN, + "Unrecognized flag passed to evdns_base_new(). Assuming " + "you meant EVDNS_BASE_INITIALIZE_NAMESERVERS."); + } +#undef EVDNS_BASE_ALL_FLAGS + + if (flags & EVDNS_BASE_INITIALIZE_NAMESERVERS) { + int r; +#ifdef _WIN32 + r = evdns_base_config_windows_nameservers(base); +#else + r = evdns_base_resolv_conf_parse(base, DNS_OPTIONS_ALL, "/etc/resolv.conf"); +#endif + if (r == -1) { + evdns_base_free_and_unlock(base, 0); + return NULL; + } + } + if (flags & EVDNS_BASE_DISABLE_WHEN_INACTIVE) { + base->disable_when_inactive = 1; + } + + EVDNS_UNLOCK(base); + return base; +} + +int +evdns_init(void) +{ + struct evdns_base *base = evdns_base_new(NULL, 1); + if (base) { + current_base = base; + return 0; + } else { + return -1; + } +} + +const char * +evdns_err_to_string(int err) +{ + switch (err) { + case DNS_ERR_NONE: return "no error"; + case DNS_ERR_FORMAT: return "misformatted query"; + case DNS_ERR_SERVERFAILED: return "server failed"; + case DNS_ERR_NOTEXIST: return "name does not exist"; + case DNS_ERR_NOTIMPL: return "query not implemented"; + case DNS_ERR_REFUSED: return "refused"; + + case DNS_ERR_TRUNCATED: return "reply truncated or ill-formed"; + case DNS_ERR_UNKNOWN: return "unknown"; + case DNS_ERR_TIMEOUT: return "request timed out"; + case DNS_ERR_SHUTDOWN: return "dns subsystem shut down"; + case DNS_ERR_CANCEL: return "dns request canceled"; + case DNS_ERR_NODATA: return "no records in the reply"; + default: return "[Unknown error code]"; + } +} + +static void +evdns_nameserver_free(struct nameserver *server) +{ + if (server->socket >= 0) + evutil_closesocket(server->socket); + (void) event_del(&server->event); + event_debug_unassign(&server->event); + if (server->state == 0) + (void) event_del(&server->timeout_event); + if (server->probe_request) { + evdns_cancel_request(server->base, server->probe_request); + server->probe_request = NULL; + } + event_debug_unassign(&server->timeout_event); + mm_free(server); +} + +static void +evdns_base_free_and_unlock(struct evdns_base *base, int fail_requests) +{ + struct nameserver *server, *server_next; + struct search_domain *dom, *dom_next; + int i; + + /* Requires that we hold the lock. */ + + /* TODO(nickm) we might need to refcount here. */ + + for (server = base->server_head; server; server = server_next) { + server_next = server->next; + evdns_nameserver_free(server); + if (server_next == base->server_head) + break; + } + base->server_head = NULL; + base->global_good_nameservers = 0; + + for (i = 0; i < base->n_req_heads; ++i) { + while (base->req_heads[i]) { + if (fail_requests) + reply_schedule_callback(base->req_heads[i], 0, DNS_ERR_SHUTDOWN, NULL); + request_finished(base->req_heads[i], &REQ_HEAD(base, base->req_heads[i]->trans_id), 1); + } + } + while (base->req_waiting_head) { + if (fail_requests) + reply_schedule_callback(base->req_waiting_head, 0, DNS_ERR_SHUTDOWN, NULL); + request_finished(base->req_waiting_head, &base->req_waiting_head, 1); + } + base->global_requests_inflight = base->global_requests_waiting = 0; + + + if (base->global_search_state) { + for (dom = base->global_search_state->head; dom; dom = dom_next) { + dom_next = dom->next; + mm_free(dom); + } + mm_free(base->global_search_state); + base->global_search_state = NULL; + } + + { + struct hosts_entry *victim; + while ((victim = TAILQ_FIRST(&base->hostsdb))) { + TAILQ_REMOVE(&base->hostsdb, victim, next); + mm_free(victim); + } + } + + mm_free(base->req_heads); + + EVDNS_UNLOCK(base); + EVTHREAD_FREE_LOCK(base->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + + mm_free(base); +} + +void +evdns_base_free(struct evdns_base *base, int fail_requests) +{ + EVDNS_LOCK(base); + evdns_base_free_and_unlock(base, fail_requests); +} + +void +evdns_base_clear_host_addresses(struct evdns_base *base) +{ + struct hosts_entry *victim; + EVDNS_LOCK(base); + while ((victim = TAILQ_FIRST(&base->hostsdb))) { + TAILQ_REMOVE(&base->hostsdb, victim, next); + mm_free(victim); + } + EVDNS_UNLOCK(base); +} + +void +evdns_shutdown(int fail_requests) +{ + if (current_base) { + struct evdns_base *b = current_base; + current_base = NULL; + evdns_base_free(b, fail_requests); + } + evdns_log_fn = NULL; +} + +static int +evdns_base_parse_hosts_line(struct evdns_base *base, char *line) +{ + char *strtok_state; + static const char *const delims = " \t"; + char *const addr = strtok_r(line, delims, &strtok_state); + char *hostname, *hash; + struct sockaddr_storage ss; + int socklen = sizeof(ss); + ASSERT_LOCKED(base); + +#define NEXT_TOKEN strtok_r(NULL, delims, &strtok_state) + + if (!addr || *addr == '#') + return 0; + + memset(&ss, 0, sizeof(ss)); + if (evutil_parse_sockaddr_port(addr, (struct sockaddr*)&ss, &socklen)<0) + return -1; + if (socklen > (int)sizeof(struct sockaddr_in6)) + return -1; + + if (sockaddr_getport((struct sockaddr*)&ss)) + return -1; + + while ((hostname = NEXT_TOKEN)) { + struct hosts_entry *he; + size_t namelen; + if ((hash = strchr(hostname, '#'))) { + if (hash == hostname) + return 0; + *hash = '\0'; + } + + namelen = strlen(hostname); + + he = mm_calloc(1, sizeof(struct hosts_entry)+namelen); + if (!he) + return -1; + EVUTIL_ASSERT(socklen <= (int)sizeof(he->addr)); + memcpy(&he->addr, &ss, socklen); + memcpy(he->hostname, hostname, namelen+1); + he->addrlen = socklen; + + TAILQ_INSERT_TAIL(&base->hostsdb, he, next); + + if (hash) + return 0; + } + + return 0; +#undef NEXT_TOKEN +} + +static int +evdns_base_load_hosts_impl(struct evdns_base *base, const char *hosts_fname) +{ + char *str=NULL, *cp, *eol; + size_t len; + int err=0; + + ASSERT_LOCKED(base); + + if (hosts_fname == NULL || + (err = evutil_read_file_(hosts_fname, &str, &len, 0)) < 0) { + char tmp[64]; + strlcpy(tmp, "127.0.0.1 localhost", sizeof(tmp)); + evdns_base_parse_hosts_line(base, tmp); + strlcpy(tmp, "::1 localhost", sizeof(tmp)); + evdns_base_parse_hosts_line(base, tmp); + return err ? -1 : 0; + } + + /* This will break early if there is a NUL in the hosts file. + * Probably not a problem.*/ + cp = str; + for (;;) { + eol = strchr(cp, '\n'); + + if (eol) { + *eol = '\0'; + evdns_base_parse_hosts_line(base, cp); + cp = eol+1; + } else { + evdns_base_parse_hosts_line(base, cp); + break; + } + } + + mm_free(str); + return 0; +} + +int +evdns_base_load_hosts(struct evdns_base *base, const char *hosts_fname) +{ + int res; + if (!base) + base = current_base; + EVDNS_LOCK(base); + res = evdns_base_load_hosts_impl(base, hosts_fname); + EVDNS_UNLOCK(base); + return res; +} + +/* A single request for a getaddrinfo, either v4 or v6. */ +struct getaddrinfo_subrequest { + struct evdns_request *r; + ev_uint32_t type; +}; + +/* State data used to implement an in-progress getaddrinfo. */ +struct evdns_getaddrinfo_request { + struct evdns_base *evdns_base; + /* Copy of the modified 'hints' data that we'll use to build + * answers. */ + struct evutil_addrinfo hints; + /* The callback to invoke when we're done */ + evdns_getaddrinfo_cb user_cb; + /* User-supplied data to give to the callback. */ + void *user_data; + /* The port to use when building sockaddrs. */ + ev_uint16_t port; + /* The sub_request for an A record (if any) */ + struct getaddrinfo_subrequest ipv4_request; + /* The sub_request for an AAAA record (if any) */ + struct getaddrinfo_subrequest ipv6_request; + + /* The cname result that we were told (if any) */ + char *cname_result; + + /* If we have one request answered and one request still inflight, + * then this field holds the answer from the first request... */ + struct evutil_addrinfo *pending_result; + /* And this event is a timeout that will tell us to cancel the second + * request if it's taking a long time. */ + struct event timeout; + + /* And this field holds the error code from the first request... */ + int pending_error; + /* If this is set, the user canceled this request. */ + unsigned user_canceled : 1; + /* If this is set, the user can no longer cancel this request; we're + * just waiting for the free. */ + unsigned request_done : 1; +}; + +/* Convert an evdns errors to the equivalent getaddrinfo error. */ +static int +evdns_err_to_getaddrinfo_err(int e1) +{ + /* XXX Do this better! */ + if (e1 == DNS_ERR_NONE) + return 0; + else if (e1 == DNS_ERR_NOTEXIST) + return EVUTIL_EAI_NONAME; + else + return EVUTIL_EAI_FAIL; +} + +/* Return the more informative of two getaddrinfo errors. */ +static int +getaddrinfo_merge_err(int e1, int e2) +{ + /* XXXX be cleverer here. */ + if (e1 == 0) + return e2; + else + return e1; +} + +static void +free_getaddrinfo_request(struct evdns_getaddrinfo_request *data) +{ + /* DO NOT CALL this if either of the requests is pending. Only once + * both callbacks have been invoked is it safe to free the request */ + if (data->pending_result) + evutil_freeaddrinfo(data->pending_result); + if (data->cname_result) + mm_free(data->cname_result); + event_del(&data->timeout); + mm_free(data); + return; +} + +static void +add_cname_to_reply(struct evdns_getaddrinfo_request *data, + struct evutil_addrinfo *ai) +{ + if (data->cname_result && ai) { + ai->ai_canonname = data->cname_result; + data->cname_result = NULL; + } +} + +/* Callback: invoked when one request in a mixed-format A/AAAA getaddrinfo + * request has finished, but the other one took too long to answer. Pass + * along the answer we got, and cancel the other request. + */ +static void +evdns_getaddrinfo_timeout_cb(evutil_socket_t fd, short what, void *ptr) +{ + int v4_timedout = 0, v6_timedout = 0; + struct evdns_getaddrinfo_request *data = ptr; + + /* Cancel any pending requests, and note which one */ + if (data->ipv4_request.r) { + /* XXXX This does nothing if the request's callback is already + * running (pending_cb is set). */ + evdns_cancel_request(NULL, data->ipv4_request.r); + v4_timedout = 1; + EVDNS_LOCK(data->evdns_base); + ++data->evdns_base->getaddrinfo_ipv4_timeouts; + EVDNS_UNLOCK(data->evdns_base); + } + if (data->ipv6_request.r) { + /* XXXX This does nothing if the request's callback is already + * running (pending_cb is set). */ + evdns_cancel_request(NULL, data->ipv6_request.r); + v6_timedout = 1; + EVDNS_LOCK(data->evdns_base); + ++data->evdns_base->getaddrinfo_ipv6_timeouts; + EVDNS_UNLOCK(data->evdns_base); + } + + /* We only use this timeout callback when we have an answer for + * one address. */ + EVUTIL_ASSERT(!v4_timedout || !v6_timedout); + + /* Report the outcome of the other request that didn't time out. */ + if (data->pending_result) { + add_cname_to_reply(data, data->pending_result); + data->user_cb(0, data->pending_result, data->user_data); + data->pending_result = NULL; + } else { + int e = data->pending_error; + if (!e) + e = EVUTIL_EAI_AGAIN; + data->user_cb(e, NULL, data->user_data); + } + + data->user_cb = NULL; /* prevent double-call if evdns callbacks are + * in-progress. XXXX It would be better if this + * weren't necessary. */ + + if (!v4_timedout && !v6_timedout) { + /* should be impossible? XXXX */ + free_getaddrinfo_request(data); + } +} + +static int +evdns_getaddrinfo_set_timeout(struct evdns_base *evdns_base, + struct evdns_getaddrinfo_request *data) +{ + return event_add(&data->timeout, &evdns_base->global_getaddrinfo_allow_skew); +} + +static inline int +evdns_result_is_answer(int result) +{ + return (result != DNS_ERR_NOTIMPL && result != DNS_ERR_REFUSED && + result != DNS_ERR_SERVERFAILED && result != DNS_ERR_CANCEL); +} + +static void +evdns_getaddrinfo_gotresolve(int result, char type, int count, + int ttl, void *addresses, void *arg) +{ + int i; + struct getaddrinfo_subrequest *req = arg; + struct getaddrinfo_subrequest *other_req; + struct evdns_getaddrinfo_request *data; + + struct evutil_addrinfo *res; + + struct sockaddr_in sin; + struct sockaddr_in6 sin6; + struct sockaddr *sa; + int socklen, addrlen; + void *addrp; + int err; + int user_canceled; + + EVUTIL_ASSERT(req->type == DNS_IPv4_A || req->type == DNS_IPv6_AAAA); + if (req->type == DNS_IPv4_A) { + data = EVUTIL_UPCAST(req, struct evdns_getaddrinfo_request, ipv4_request); + other_req = &data->ipv6_request; + } else { + data = EVUTIL_UPCAST(req, struct evdns_getaddrinfo_request, ipv6_request); + other_req = &data->ipv4_request; + } + + EVDNS_LOCK(data->evdns_base); + if (evdns_result_is_answer(result)) { + if (req->type == DNS_IPv4_A) + ++data->evdns_base->getaddrinfo_ipv4_answered; + else + ++data->evdns_base->getaddrinfo_ipv6_answered; + } + user_canceled = data->user_canceled; + if (other_req->r == NULL) + data->request_done = 1; + EVDNS_UNLOCK(data->evdns_base); + + req->r = NULL; + + if (result == DNS_ERR_CANCEL && ! user_canceled) { + /* Internal cancel request from timeout or internal error. + * we already answered the user. */ + if (other_req->r == NULL) + free_getaddrinfo_request(data); + return; + } + + if (data->user_cb == NULL) { + /* We already answered. XXXX This shouldn't be needed; see + * comments in evdns_getaddrinfo_timeout_cb */ + free_getaddrinfo_request(data); + return; + } + + if (result == DNS_ERR_NONE) { + if (count == 0) + err = EVUTIL_EAI_NODATA; + else + err = 0; + } else { + err = evdns_err_to_getaddrinfo_err(result); + } + + if (err) { + /* Looks like we got an error. */ + if (other_req->r) { + /* The other request is still working; maybe it will + * succeed. */ + /* XXXX handle failure from set_timeout */ + evdns_getaddrinfo_set_timeout(data->evdns_base, data); + data->pending_error = err; + return; + } + + if (user_canceled) { + data->user_cb(EVUTIL_EAI_CANCEL, NULL, data->user_data); + } else if (data->pending_result) { + /* If we have an answer waiting, and we weren't + * canceled, ignore this error. */ + add_cname_to_reply(data, data->pending_result); + data->user_cb(0, data->pending_result, data->user_data); + data->pending_result = NULL; + } else { + if (data->pending_error) + err = getaddrinfo_merge_err(err, + data->pending_error); + data->user_cb(err, NULL, data->user_data); + } + free_getaddrinfo_request(data); + return; + } else if (user_canceled) { + if (other_req->r) { + /* The other request is still working; let it hit this + * callback with EVUTIL_EAI_CANCEL callback and report + * the failure. */ + return; + } + data->user_cb(EVUTIL_EAI_CANCEL, NULL, data->user_data); + free_getaddrinfo_request(data); + return; + } + + /* Looks like we got some answers. We should turn them into addrinfos + * and then either queue those or return them all. */ + EVUTIL_ASSERT(type == DNS_IPv4_A || type == DNS_IPv6_AAAA); + + if (type == DNS_IPv4_A) { + memset(&sin, 0, sizeof(sin)); + sin.sin_family = AF_INET; + sin.sin_port = htons(data->port); + + sa = (struct sockaddr *)&sin; + socklen = sizeof(sin); + addrlen = 4; + addrp = &sin.sin_addr.s_addr; + } else { + memset(&sin6, 0, sizeof(sin6)); + sin6.sin6_family = AF_INET6; + sin6.sin6_port = htons(data->port); + + sa = (struct sockaddr *)&sin6; + socklen = sizeof(sin6); + addrlen = 16; + addrp = &sin6.sin6_addr.s6_addr; + } + + res = NULL; + for (i=0; i < count; ++i) { + struct evutil_addrinfo *ai; + memcpy(addrp, ((char*)addresses)+i*addrlen, addrlen); + ai = evutil_new_addrinfo_(sa, socklen, &data->hints); + if (!ai) { + if (other_req->r) { + evdns_cancel_request(NULL, other_req->r); + } + data->user_cb(EVUTIL_EAI_MEMORY, NULL, data->user_data); + if (res) + evutil_freeaddrinfo(res); + + if (other_req->r == NULL) + free_getaddrinfo_request(data); + return; + } + res = evutil_addrinfo_append_(res, ai); + } + + if (other_req->r) { + /* The other request is still in progress; wait for it */ + /* XXXX handle failure from set_timeout */ + evdns_getaddrinfo_set_timeout(data->evdns_base, data); + data->pending_result = res; + return; + } else { + /* The other request is done or never started; append its + * results (if any) and return them. */ + if (data->pending_result) { + if (req->type == DNS_IPv4_A) + res = evutil_addrinfo_append_(res, + data->pending_result); + else + res = evutil_addrinfo_append_( + data->pending_result, res); + data->pending_result = NULL; + } + + /* Call the user callback. */ + add_cname_to_reply(data, res); + data->user_cb(0, res, data->user_data); + + /* Free data. */ + free_getaddrinfo_request(data); + } +} + +static struct hosts_entry * +find_hosts_entry(struct evdns_base *base, const char *hostname, + struct hosts_entry *find_after) +{ + struct hosts_entry *e; + + if (find_after) + e = TAILQ_NEXT(find_after, next); + else + e = TAILQ_FIRST(&base->hostsdb); + + for (; e; e = TAILQ_NEXT(e, next)) { + if (!evutil_ascii_strcasecmp(e->hostname, hostname)) + return e; + } + return NULL; +} + +static int +evdns_getaddrinfo_fromhosts(struct evdns_base *base, + const char *nodename, struct evutil_addrinfo *hints, ev_uint16_t port, + struct evutil_addrinfo **res) +{ + int n_found = 0; + struct hosts_entry *e; + struct evutil_addrinfo *ai=NULL; + int f = hints->ai_family; + + EVDNS_LOCK(base); + for (e = find_hosts_entry(base, nodename, NULL); e; + e = find_hosts_entry(base, nodename, e)) { + struct evutil_addrinfo *ai_new; + ++n_found; + if ((e->addr.sa.sa_family == AF_INET && f == PF_INET6) || + (e->addr.sa.sa_family == AF_INET6 && f == PF_INET)) + continue; + ai_new = evutil_new_addrinfo_(&e->addr.sa, e->addrlen, hints); + if (!ai_new) { + n_found = 0; + goto out; + } + sockaddr_setport(ai_new->ai_addr, port); + ai = evutil_addrinfo_append_(ai, ai_new); + } + EVDNS_UNLOCK(base); +out: + if (n_found) { + /* Note that we return an empty answer if we found entries for + * this hostname but none were of the right address type. */ + *res = ai; + return 0; + } else { + if (ai) + evutil_freeaddrinfo(ai); + return -1; + } +} + +struct evdns_getaddrinfo_request * +evdns_getaddrinfo(struct evdns_base *dns_base, + const char *nodename, const char *servname, + const struct evutil_addrinfo *hints_in, + evdns_getaddrinfo_cb cb, void *arg) +{ + struct evdns_getaddrinfo_request *data; + struct evutil_addrinfo hints; + struct evutil_addrinfo *res = NULL; + int err; + int port = 0; + int want_cname = 0; + + if (!dns_base) { + dns_base = current_base; + if (!dns_base) { + log(EVDNS_LOG_WARN, + "Call to getaddrinfo_async with no " + "evdns_base configured."); + cb(EVUTIL_EAI_FAIL, NULL, arg); /* ??? better error? */ + return NULL; + } + } + + /* If we _must_ answer this immediately, do so. */ + if ((hints_in && (hints_in->ai_flags & EVUTIL_AI_NUMERICHOST))) { + res = NULL; + err = evutil_getaddrinfo(nodename, servname, hints_in, &res); + cb(err, res, arg); + return NULL; + } + + if (hints_in) { + memcpy(&hints, hints_in, sizeof(hints)); + } else { + memset(&hints, 0, sizeof(hints)); + hints.ai_family = PF_UNSPEC; + } + + evutil_adjust_hints_for_addrconfig_(&hints); + + /* Now try to see if we _can_ answer immediately. */ + /* (It would be nice to do this by calling getaddrinfo directly, with + * AI_NUMERICHOST, on plaforms that have it, but we can't: there isn't + * a reliable way to distinguish the "that wasn't a numeric host!" case + * from any other EAI_NONAME cases.) */ + err = evutil_getaddrinfo_common_(nodename, servname, &hints, &res, &port); + if (err != EVUTIL_EAI_NEED_RESOLVE) { + cb(err, res, arg); + return NULL; + } + + /* If there is an entry in the hosts file, we should give it now. */ + if (!evdns_getaddrinfo_fromhosts(dns_base, nodename, &hints, port, &res)) { + cb(0, res, arg); + return NULL; + } + + /* Okay, things are serious now. We're going to need to actually + * launch a request. + */ + data = mm_calloc(1,sizeof(struct evdns_getaddrinfo_request)); + if (!data) { + cb(EVUTIL_EAI_MEMORY, NULL, arg); + return NULL; + } + + memcpy(&data->hints, &hints, sizeof(data->hints)); + data->port = (ev_uint16_t)port; + data->ipv4_request.type = DNS_IPv4_A; + data->ipv6_request.type = DNS_IPv6_AAAA; + data->user_cb = cb; + data->user_data = arg; + data->evdns_base = dns_base; + + want_cname = (hints.ai_flags & EVUTIL_AI_CANONNAME); + + /* If we are asked for a PF_UNSPEC address, we launch two requests in + * parallel: one for an A address and one for an AAAA address. We + * can't send just one request, since many servers only answer one + * question per DNS request. + * + * Once we have the answer to one request, we allow for a short + * timeout before we report it, to see if the other one arrives. If + * they both show up in time, then we report both the answers. + * + * If too many addresses of one type time out or fail, we should stop + * launching those requests. (XXX we don't do that yet.) + */ + + if (hints.ai_family != PF_INET6) { + log(EVDNS_LOG_DEBUG, "Sending request for %s on ipv4 as %p", + nodename, &data->ipv4_request); + + data->ipv4_request.r = evdns_base_resolve_ipv4(dns_base, + nodename, 0, evdns_getaddrinfo_gotresolve, + &data->ipv4_request); + if (want_cname && data->ipv4_request.r) + data->ipv4_request.r->current_req->put_cname_in_ptr = + &data->cname_result; + } + if (hints.ai_family != PF_INET) { + log(EVDNS_LOG_DEBUG, "Sending request for %s on ipv6 as %p", + nodename, &data->ipv6_request); + + data->ipv6_request.r = evdns_base_resolve_ipv6(dns_base, + nodename, 0, evdns_getaddrinfo_gotresolve, + &data->ipv6_request); + if (want_cname && data->ipv6_request.r) + data->ipv6_request.r->current_req->put_cname_in_ptr = + &data->cname_result; + } + + evtimer_assign(&data->timeout, dns_base->event_base, + evdns_getaddrinfo_timeout_cb, data); + + if (data->ipv4_request.r || data->ipv6_request.r) { + return data; + } else { + mm_free(data); + cb(EVUTIL_EAI_FAIL, NULL, arg); + return NULL; + } +} + +void +evdns_getaddrinfo_cancel(struct evdns_getaddrinfo_request *data) +{ + EVDNS_LOCK(data->evdns_base); + if (data->request_done) { + EVDNS_UNLOCK(data->evdns_base); + return; + } + event_del(&data->timeout); + data->user_canceled = 1; + if (data->ipv4_request.r) + evdns_cancel_request(data->evdns_base, data->ipv4_request.r); + if (data->ipv6_request.r) + evdns_cancel_request(data->evdns_base, data->ipv6_request.r); + EVDNS_UNLOCK(data->evdns_base); +} diff --git a/contrib/ntp/sntp/libevent/event-internal.h b/contrib/ntp/sntp/libevent/event-internal.h new file mode 100644 index 000000000..5208fbe08 --- /dev/null +++ b/contrib/ntp/sntp/libevent/event-internal.h @@ -0,0 +1,474 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT_INTERNAL_H_INCLUDED_ +#define EVENT_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include +#include +#include "event2/event_struct.h" +#include "minheap-internal.h" +#include "evsignal-internal.h" +#include "mm-internal.h" +#include "defer-internal.h" + +/* map union members back */ + +/* mutually exclusive */ +#define ev_signal_next ev_.ev_signal.ev_signal_next +#define ev_io_next ev_.ev_io.ev_io_next +#define ev_io_timeout ev_.ev_io.ev_timeout + +/* used only by signals */ +#define ev_ncalls ev_.ev_signal.ev_ncalls +#define ev_pncalls ev_.ev_signal.ev_pncalls + +#define ev_pri ev_evcallback.evcb_pri +#define ev_flags ev_evcallback.evcb_flags +#define ev_closure ev_evcallback.evcb_closure +#define ev_callback ev_evcallback.evcb_cb_union.evcb_callback +#define ev_arg ev_evcallback.evcb_arg + +/** @name Event closure codes + + Possible values for evcb_closure in struct event_callback + + @{ + */ +/** A regular event. Uses the evcb_callback callback */ +#define EV_CLOSURE_EVENT 0 +/** A signal event. Uses the evcb_callback callback */ +#define EV_CLOSURE_EVENT_SIGNAL 1 +/** A persistent non-signal event. Uses the evcb_callback callback */ +#define EV_CLOSURE_EVENT_PERSIST 2 +/** A simple callback. Uses the evcb_selfcb callback. */ +#define EV_CLOSURE_CB_SELF 3 +/** A finalizing callback. Uses the evcb_cbfinalize callback. */ +#define EV_CLOSURE_CB_FINALIZE 4 +/** A finalizing event. Uses the evcb_evfinalize callback. */ +#define EV_CLOSURE_EVENT_FINALIZE 5 +/** A finalizing event that should get freed after. Uses the evcb_evfinalize + * callback. */ +#define EV_CLOSURE_EVENT_FINALIZE_FREE 6 +/** @} */ + +/** Structure to define the backend of a given event_base. */ +struct eventop { + /** The name of this backend. */ + const char *name; + /** Function to set up an event_base to use this backend. It should + * create a new structure holding whatever information is needed to + * run the backend, and return it. The returned pointer will get + * stored by event_init into the event_base.evbase field. On failure, + * this function should return NULL. */ + void *(*init)(struct event_base *); + /** Enable reading/writing on a given fd or signal. 'events' will be + * the events that we're trying to enable: one or more of EV_READ, + * EV_WRITE, EV_SIGNAL, and EV_ET. 'old' will be those events that + * were enabled on this fd previously. 'fdinfo' will be a structure + * associated with the fd by the evmap; its size is defined by the + * fdinfo field below. It will be set to 0 the first time the fd is + * added. The function should return 0 on success and -1 on error. + */ + int (*add)(struct event_base *, evutil_socket_t fd, short old, short events, void *fdinfo); + /** As "add", except 'events' contains the events we mean to disable. */ + int (*del)(struct event_base *, evutil_socket_t fd, short old, short events, void *fdinfo); + /** Function to implement the core of an event loop. It must see which + added events are ready, and cause event_active to be called for each + active event (usually via event_io_active or such). It should + return 0 on success and -1 on error. + */ + int (*dispatch)(struct event_base *, struct timeval *); + /** Function to clean up and free our data from the event_base. */ + void (*dealloc)(struct event_base *); + /** Flag: set if we need to reinitialize the event base after we fork. + */ + int need_reinit; + /** Bit-array of supported event_method_features that this backend can + * provide. */ + enum event_method_feature features; + /** Length of the extra information we should record for each fd that + has one or more active events. This information is recorded + as part of the evmap entry for each fd, and passed as an argument + to the add and del functions above. + */ + size_t fdinfo_len; +}; + +#ifdef _WIN32 +/* If we're on win32, then file descriptors are not nice low densely packed + integers. Instead, they are pointer-like windows handles, and we want to + use a hashtable instead of an array to map fds to events. +*/ +#define EVMAP_USE_HT +#endif + +/* #define HT_CACHE_HASH_VALS */ + +#ifdef EVMAP_USE_HT +#define HT_NO_CACHE_HASH_VALUES +#include "ht-internal.h" +struct event_map_entry; +HT_HEAD(event_io_map, event_map_entry); +#else +#define event_io_map event_signal_map +#endif + +/* Used to map signal numbers to a list of events. If EVMAP_USE_HT is not + defined, this structure is also used as event_io_map, which maps fds to a + list of events. +*/ +struct event_signal_map { + /* An array of evmap_io * or of evmap_signal *; empty entries are + * set to NULL. */ + void **entries; + /* The number of entries available in entries */ + int nentries; +}; + +/* A list of events waiting on a given 'common' timeout value. Ordinarily, + * events waiting for a timeout wait on a minheap. Sometimes, however, a + * queue can be faster. + **/ +struct common_timeout_list { + /* List of events currently waiting in the queue. */ + struct event_list events; + /* 'magic' timeval used to indicate the duration of events in this + * queue. */ + struct timeval duration; + /* Event that triggers whenever one of the events in the queue is + * ready to activate */ + struct event timeout_event; + /* The event_base that this timeout list is part of */ + struct event_base *base; +}; + +/** Mask used to get the real tv_usec value from a common timeout. */ +#define COMMON_TIMEOUT_MICROSECONDS_MASK 0x000fffff + +struct event_change; + +/* List of 'changes' since the last call to eventop.dispatch. Only maintained + * if the backend is using changesets. */ +struct event_changelist { + struct event_change *changes; + int n_changes; + int changes_size; +}; + +#ifndef EVENT__DISABLE_DEBUG_MODE +/* Global internal flag: set to one if debug mode is on. */ +extern int event_debug_mode_on_; +#define EVENT_DEBUG_MODE_IS_ON() (event_debug_mode_on_) +#else +#define EVENT_DEBUG_MODE_IS_ON() (0) +#endif + +TAILQ_HEAD(evcallback_list, event_callback); + +/* Sets up an event for processing once */ +struct event_once { + LIST_ENTRY(event_once) next_once; + struct event ev; + + void (*cb)(evutil_socket_t, short, void *); + void *arg; +}; + +struct event_base { + /** Function pointers and other data to describe this event_base's + * backend. */ + const struct eventop *evsel; + /** Pointer to backend-specific data. */ + void *evbase; + + /** List of changes to tell backend about at next dispatch. Only used + * by the O(1) backends. */ + struct event_changelist changelist; + + /** Function pointers used to describe the backend that this event_base + * uses for signals */ + const struct eventop *evsigsel; + /** Data to implement the common signal handelr code. */ + struct evsig_info sig; + + /** Number of virtual events */ + int virtual_event_count; + /** Maximum number of virtual events active */ + int virtual_event_count_max; + /** Number of total events added to this event_base */ + int event_count; + /** Maximum number of total events added to this event_base */ + int event_count_max; + /** Number of total events active in this event_base */ + int event_count_active; + /** Maximum number of total events active in this event_base */ + int event_count_active_max; + + /** Set if we should terminate the loop once we're done processing + * events. */ + int event_gotterm; + /** Set if we should terminate the loop immediately */ + int event_break; + /** Set if we should start a new instance of the loop immediately. */ + int event_continue; + + /** The currently running priority of events */ + int event_running_priority; + + /** Set if we're running the event_base_loop function, to prevent + * reentrant invocation. */ + int running_loop; + + /** Set to the number of deferred_cbs we've made 'active' in the + * loop. This is a hack to prevent starvation; it would be smarter + * to just use event_config_set_max_dispatch_interval's max_callbacks + * feature */ + int n_deferreds_queued; + + /* Active event management. */ + /** An array of nactivequeues queues for active event_callbacks (ones + * that have triggered, and whose callbacks need to be called). Low + * priority numbers are more important, and stall higher ones. + */ + struct evcallback_list *activequeues; + /** The length of the activequeues array */ + int nactivequeues; + /** A list of event_callbacks that should become active the next time + * we process events, but not this time. */ + struct evcallback_list active_later_queue; + + /* common timeout logic */ + + /** An array of common_timeout_list* for all of the common timeout + * values we know. */ + struct common_timeout_list **common_timeout_queues; + /** The number of entries used in common_timeout_queues */ + int n_common_timeouts; + /** The total size of common_timeout_queues. */ + int n_common_timeouts_allocated; + + /** Mapping from file descriptors to enabled (added) events */ + struct event_io_map io; + + /** Mapping from signal numbers to enabled (added) events. */ + struct event_signal_map sigmap; + + /** Priority queue of events with timeouts. */ + struct min_heap timeheap; + + /** Stored timeval: used to avoid calling gettimeofday/clock_gettime + * too often. */ + struct timeval tv_cache; + + struct evutil_monotonic_timer monotonic_timer; + + /** Difference between internal time (maybe from clock_gettime) and + * gettimeofday. */ + struct timeval tv_clock_diff; + /** Second in which we last updated tv_clock_diff, in monotonic time. */ + time_t last_updated_clock_diff; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + /* threading support */ + /** The thread currently running the event_loop for this base */ + unsigned long th_owner_id; + /** A lock to prevent conflicting accesses to this event_base */ + void *th_base_lock; + /** A condition that gets signalled when we're done processing an + * event with waiters on it. */ + void *current_event_cond; + /** Number of threads blocking on current_event_cond. */ + int current_event_waiters; +#endif + /** The event whose callback is executing right now */ + struct event_callback *current_event; + +#ifdef _WIN32 + /** IOCP support structure, if IOCP is enabled. */ + struct event_iocp_port *iocp; +#endif + + /** Flags that this base was configured with */ + enum event_base_config_flag flags; + + struct timeval max_dispatch_time; + int max_dispatch_callbacks; + int limit_callbacks_after_prio; + + /* Notify main thread to wake up break, etc. */ + /** True if the base already has a pending notify, and we don't need + * to add any more. */ + int is_notify_pending; + /** A socketpair used by some th_notify functions to wake up the main + * thread. */ + evutil_socket_t th_notify_fd[2]; + /** An event used by some th_notify functions to wake up the main + * thread. */ + struct event th_notify; + /** A function used to wake up the main thread from another thread. */ + int (*th_notify_fn)(struct event_base *base); + + /** Saved seed for weak random number generator. Some backends use + * this to produce fairness among sockets. Protected by th_base_lock. */ + struct evutil_weakrand_state weakrand_seed; + + /** List of event_onces that have not yet fired. */ + LIST_HEAD(once_event_list, event_once) once_events; + +}; + +struct event_config_entry { + TAILQ_ENTRY(event_config_entry) next; + + const char *avoid_method; +}; + +/** Internal structure: describes the configuration we want for an event_base + * that we're about to allocate. */ +struct event_config { + TAILQ_HEAD(event_configq, event_config_entry) entries; + + int n_cpus_hint; + struct timeval max_dispatch_interval; + int max_dispatch_callbacks; + int limit_callbacks_after_prio; + enum event_method_feature require_features; + enum event_base_config_flag flags; +}; + +/* Internal use only: Functions that might be missing from */ +#if defined(EVENT__HAVE_SYS_QUEUE_H) && !defined(EVENT__HAVE_TAILQFOREACH) +#ifndef TAILQ_FIRST +#define TAILQ_FIRST(head) ((head)->tqh_first) +#endif +#ifndef TAILQ_END +#define TAILQ_END(head) NULL +#endif +#ifndef TAILQ_NEXT +#define TAILQ_NEXT(elm, field) ((elm)->field.tqe_next) +#endif + +#ifndef TAILQ_FOREACH +#define TAILQ_FOREACH(var, head, field) \ + for ((var) = TAILQ_FIRST(head); \ + (var) != TAILQ_END(head); \ + (var) = TAILQ_NEXT(var, field)) +#endif + +#ifndef TAILQ_INSERT_BEFORE +#define TAILQ_INSERT_BEFORE(listelm, elm, field) do { \ + (elm)->field.tqe_prev = (listelm)->field.tqe_prev; \ + (elm)->field.tqe_next = (listelm); \ + *(listelm)->field.tqe_prev = (elm); \ + (listelm)->field.tqe_prev = &(elm)->field.tqe_next; \ +} while (0) +#endif +#endif /* TAILQ_FOREACH */ + +#define N_ACTIVE_CALLBACKS(base) \ + ((base)->event_count_active) + +int evsig_set_handler_(struct event_base *base, int evsignal, + void (*fn)(int)); +int evsig_restore_handler_(struct event_base *base, int evsignal); + +int event_add_nolock_(struct event *ev, + const struct timeval *tv, int tv_is_absolute); +/** Argument for event_del_nolock_. Tells event_del not to block on the event + * if it's running in another thread. */ +#define EVENT_DEL_NOBLOCK 0 +/** Argument for event_del_nolock_. Tells event_del to block on the event + * if it's running in another thread, regardless of its value for EV_FINALIZE + */ +#define EVENT_DEL_BLOCK 1 +/** Argument for event_del_nolock_. Tells event_del to block on the event + * if it is running in another thread and it doesn't have EV_FINALIZE set. + */ +#define EVENT_DEL_AUTOBLOCK 2 +/** Argument for event_del_nolock_. Tells event_del to procede even if the + * event is set up for finalization rather for regular use.*/ +#define EVENT_DEL_EVEN_IF_FINALIZING 3 +int event_del_nolock_(struct event *ev, int blocking); +int event_remove_timer_nolock_(struct event *ev); + +void event_active_nolock_(struct event *ev, int res, short count); +int event_callback_activate_(struct event_base *, struct event_callback *); +int event_callback_activate_nolock_(struct event_base *, struct event_callback *); +int event_callback_cancel_(struct event_base *base, + struct event_callback *evcb); + +void event_callback_finalize_nolock_(struct event_base *base, unsigned flags, struct event_callback *evcb, void (*cb)(struct event_callback *, void *)); +void event_callback_finalize_(struct event_base *base, unsigned flags, struct event_callback *evcb, void (*cb)(struct event_callback *, void *)); +int event_callback_finalize_many_(struct event_base *base, int n_cbs, struct event_callback **evcb, void (*cb)(struct event_callback *, void *)); + + +void event_active_later_(struct event *ev, int res); +void event_active_later_nolock_(struct event *ev, int res); +void event_callback_activate_later_nolock_(struct event_base *base, + struct event_callback *evcb); +int event_callback_cancel_nolock_(struct event_base *base, + struct event_callback *evcb, int even_if_finalizing); +void event_callback_init_(struct event_base *base, + struct event_callback *cb); + +/* FIXME document. */ +void event_base_add_virtual_(struct event_base *base); +void event_base_del_virtual_(struct event_base *base); + +/** For debugging: unless assertions are disabled, verify the referential + integrity of the internal data structures of 'base'. This operation can + be expensive. + + Returns on success; aborts on failure. +*/ +void event_base_assert_ok_(struct event_base *base); +void event_base_assert_ok_nolock_(struct event_base *base); + + +/* Helper function: Call 'fn' exactly once every inserted or active event in + * the event_base 'base'. + * + * If fn returns 0, continue on to the next event. Otherwise, return the same + * value that fn returned. + * + * Requires that 'base' be locked. + */ +int event_base_foreach_event_nolock_(struct event_base *base, + event_base_foreach_event_cb cb, void *arg); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/event.c b/contrib/ntp/sntp/libevent/event.c new file mode 100644 index 000000000..af4a6e05e --- /dev/null +++ b/contrib/ntp/sntp/libevent/event.c @@ -0,0 +1,3890 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#include +#define WIN32_LEAN_AND_MEAN +#include +#undef WIN32_LEAN_AND_MEAN +#endif +#include +#if !defined(_WIN32) && defined(EVENT__HAVE_SYS_TIME_H) +#include +#endif +#include +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif +#include +#include +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#include +#include +#include +#include +#include +#include + +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/event_compat.h" +#include "event-internal.h" +#include "defer-internal.h" +#include "evthread-internal.h" +#include "event2/thread.h" +#include "event2/util.h" +#include "log-internal.h" +#include "evmap-internal.h" +#include "iocp-internal.h" +#include "changelist-internal.h" +#define HT_NO_CACHE_HASH_VALUES +#include "ht-internal.h" +#include "util-internal.h" + + +#ifdef EVENT__HAVE_WORKING_KQUEUE +#include "kqueue-internal.h" +#endif + +#ifdef EVENT__HAVE_EVENT_PORTS +extern const struct eventop evportops; +#endif +#ifdef EVENT__HAVE_SELECT +extern const struct eventop selectops; +#endif +#ifdef EVENT__HAVE_POLL +extern const struct eventop pollops; +#endif +#ifdef EVENT__HAVE_EPOLL +extern const struct eventop epollops; +#endif +#ifdef EVENT__HAVE_WORKING_KQUEUE +extern const struct eventop kqops; +#endif +#ifdef EVENT__HAVE_DEVPOLL +extern const struct eventop devpollops; +#endif +#ifdef _WIN32 +extern const struct eventop win32ops; +#endif + +/* Array of backends in order of preference. */ +static const struct eventop *eventops[] = { +#ifdef EVENT__HAVE_EVENT_PORTS + &evportops, +#endif +#ifdef EVENT__HAVE_WORKING_KQUEUE + &kqops, +#endif +#ifdef EVENT__HAVE_EPOLL + &epollops, +#endif +#ifdef EVENT__HAVE_DEVPOLL + &devpollops, +#endif +#ifdef EVENT__HAVE_POLL + &pollops, +#endif +#ifdef EVENT__HAVE_SELECT + &selectops, +#endif +#ifdef _WIN32 + &win32ops, +#endif + NULL +}; + +/* Global state; deprecated */ +struct event_base *event_global_current_base_ = NULL; +#define current_base event_global_current_base_ + +/* Global state */ + +static void *event_self_cbarg_ptr_ = NULL; + +/* Prototypes */ +static void event_queue_insert_active(struct event_base *, struct event_callback *); +static void event_queue_insert_active_later(struct event_base *, struct event_callback *); +static void event_queue_insert_timeout(struct event_base *, struct event *); +static void event_queue_insert_inserted(struct event_base *, struct event *); +static void event_queue_remove_active(struct event_base *, struct event_callback *); +static void event_queue_remove_active_later(struct event_base *, struct event_callback *); +static void event_queue_remove_timeout(struct event_base *, struct event *); +static void event_queue_remove_inserted(struct event_base *, struct event *); +static void event_queue_make_later_events_active(struct event_base *base); + +static int evthread_make_base_notifiable_nolock_(struct event_base *base); +static int event_del_(struct event *ev, int blocking); + +#ifdef USE_REINSERT_TIMEOUT +/* This code seems buggy; only turn it on if we find out what the trouble is. */ +static void event_queue_reinsert_timeout(struct event_base *,struct event *, int was_common, int is_common, int old_timeout_idx); +#endif + +static int event_haveevents(struct event_base *); + +static int event_process_active(struct event_base *); + +static int timeout_next(struct event_base *, struct timeval **); +static void timeout_process(struct event_base *); + +static inline void event_signal_closure(struct event_base *, struct event *ev); +static inline void event_persist_closure(struct event_base *, struct event *ev); + +static int evthread_notify_base(struct event_base *base); + +static void insert_common_timeout_inorder(struct common_timeout_list *ctl, + struct event *ev); + +#ifndef EVENT__DISABLE_DEBUG_MODE +/* These functions implement a hashtable of which 'struct event *' structures + * have been setup or added. We don't want to trust the content of the struct + * event itself, since we're trying to work through cases where an event gets + * clobbered or freed. Instead, we keep a hashtable indexed by the pointer. + */ + +struct event_debug_entry { + HT_ENTRY(event_debug_entry) node; + const struct event *ptr; + unsigned added : 1; +}; + +static inline unsigned +hash_debug_entry(const struct event_debug_entry *e) +{ + /* We need to do this silliness to convince compilers that we + * honestly mean to cast e->ptr to an integer, and discard any + * part of it that doesn't fit in an unsigned. + */ + unsigned u = (unsigned) ((ev_uintptr_t) e->ptr); + /* Our hashtable implementation is pretty sensitive to low bits, + * and every struct event is over 64 bytes in size, so we can + * just say >>6. */ + return (u >> 6); +} + +static inline int +eq_debug_entry(const struct event_debug_entry *a, + const struct event_debug_entry *b) +{ + return a->ptr == b->ptr; +} + +int event_debug_mode_on_ = 0; +/* Set if it's too late to enable event_debug_mode. */ +static int event_debug_mode_too_late = 0; +#ifndef EVENT__DISABLE_THREAD_SUPPORT +static void *event_debug_map_lock_ = NULL; +#endif +static HT_HEAD(event_debug_map, event_debug_entry) global_debug_map = + HT_INITIALIZER(); + +HT_PROTOTYPE(event_debug_map, event_debug_entry, node, hash_debug_entry, + eq_debug_entry) +HT_GENERATE(event_debug_map, event_debug_entry, node, hash_debug_entry, + eq_debug_entry, 0.5, mm_malloc, mm_realloc, mm_free) + +/* Macro: record that ev is now setup (that is, ready for an add) */ +#define event_debug_note_setup_(ev) do { \ + if (event_debug_mode_on_) { \ + struct event_debug_entry *dent,find; \ + find.ptr = (ev); \ + EVLOCK_LOCK(event_debug_map_lock_, 0); \ + dent = HT_FIND(event_debug_map, &global_debug_map, &find); \ + if (dent) { \ + dent->added = 0; \ + } else { \ + dent = mm_malloc(sizeof(*dent)); \ + if (!dent) \ + event_err(1, \ + "Out of memory in debugging code"); \ + dent->ptr = (ev); \ + dent->added = 0; \ + HT_INSERT(event_debug_map, &global_debug_map, dent); \ + } \ + EVLOCK_UNLOCK(event_debug_map_lock_, 0); \ + } \ + event_debug_mode_too_late = 1; \ + } while (0) +/* Macro: record that ev is no longer setup */ +#define event_debug_note_teardown_(ev) do { \ + if (event_debug_mode_on_) { \ + struct event_debug_entry *dent,find; \ + find.ptr = (ev); \ + EVLOCK_LOCK(event_debug_map_lock_, 0); \ + dent = HT_REMOVE(event_debug_map, &global_debug_map, &find); \ + if (dent) \ + mm_free(dent); \ + EVLOCK_UNLOCK(event_debug_map_lock_, 0); \ + } \ + event_debug_mode_too_late = 1; \ + } while (0) +/* Macro: record that ev is now added */ +#define event_debug_note_add_(ev) do { \ + if (event_debug_mode_on_) { \ + struct event_debug_entry *dent,find; \ + find.ptr = (ev); \ + EVLOCK_LOCK(event_debug_map_lock_, 0); \ + dent = HT_FIND(event_debug_map, &global_debug_map, &find); \ + if (dent) { \ + dent->added = 1; \ + } else { \ + event_errx(EVENT_ERR_ABORT_, \ + "%s: noting an add on a non-setup event %p" \ + " (events: 0x%x, fd: "EV_SOCK_FMT \ + ", flags: 0x%x)", \ + __func__, (ev), (ev)->ev_events, \ + EV_SOCK_ARG((ev)->ev_fd), (ev)->ev_flags); \ + } \ + EVLOCK_UNLOCK(event_debug_map_lock_, 0); \ + } \ + event_debug_mode_too_late = 1; \ + } while (0) +/* Macro: record that ev is no longer added */ +#define event_debug_note_del_(ev) do { \ + if (event_debug_mode_on_) { \ + struct event_debug_entry *dent,find; \ + find.ptr = (ev); \ + EVLOCK_LOCK(event_debug_map_lock_, 0); \ + dent = HT_FIND(event_debug_map, &global_debug_map, &find); \ + if (dent) { \ + dent->added = 0; \ + } else { \ + event_errx(EVENT_ERR_ABORT_, \ + "%s: noting a del on a non-setup event %p" \ + " (events: 0x%x, fd: "EV_SOCK_FMT \ + ", flags: 0x%x)", \ + __func__, (ev), (ev)->ev_events, \ + EV_SOCK_ARG((ev)->ev_fd), (ev)->ev_flags); \ + } \ + EVLOCK_UNLOCK(event_debug_map_lock_, 0); \ + } \ + event_debug_mode_too_late = 1; \ + } while (0) +/* Macro: assert that ev is setup (i.e., okay to add or inspect) */ +#define event_debug_assert_is_setup_(ev) do { \ + if (event_debug_mode_on_) { \ + struct event_debug_entry *dent,find; \ + find.ptr = (ev); \ + EVLOCK_LOCK(event_debug_map_lock_, 0); \ + dent = HT_FIND(event_debug_map, &global_debug_map, &find); \ + if (!dent) { \ + event_errx(EVENT_ERR_ABORT_, \ + "%s called on a non-initialized event %p" \ + " (events: 0x%x, fd: "EV_SOCK_FMT\ + ", flags: 0x%x)", \ + __func__, (ev), (ev)->ev_events, \ + EV_SOCK_ARG((ev)->ev_fd), (ev)->ev_flags); \ + } \ + EVLOCK_UNLOCK(event_debug_map_lock_, 0); \ + } \ + } while (0) +/* Macro: assert that ev is not added (i.e., okay to tear down or set + * up again) */ +#define event_debug_assert_not_added_(ev) do { \ + if (event_debug_mode_on_) { \ + struct event_debug_entry *dent,find; \ + find.ptr = (ev); \ + EVLOCK_LOCK(event_debug_map_lock_, 0); \ + dent = HT_FIND(event_debug_map, &global_debug_map, &find); \ + if (dent && dent->added) { \ + event_errx(EVENT_ERR_ABORT_, \ + "%s called on an already added event %p" \ + " (events: 0x%x, fd: "EV_SOCK_FMT", " \ + "flags: 0x%x)", \ + __func__, (ev), (ev)->ev_events, \ + EV_SOCK_ARG((ev)->ev_fd), (ev)->ev_flags); \ + } \ + EVLOCK_UNLOCK(event_debug_map_lock_, 0); \ + } \ + } while (0) +#else +#define event_debug_note_setup_(ev) \ + ((void)0) +#define event_debug_note_teardown_(ev) \ + ((void)0) +#define event_debug_note_add_(ev) \ + ((void)0) +#define event_debug_note_del_(ev) \ + ((void)0) +#define event_debug_assert_is_setup_(ev) \ + ((void)0) +#define event_debug_assert_not_added_(ev) \ + ((void)0) +#endif + +#define EVENT_BASE_ASSERT_LOCKED(base) \ + EVLOCK_ASSERT_LOCKED((base)->th_base_lock) + +/* How often (in seconds) do we check for changes in wall clock time relative + * to monotonic time? Set this to -1 for 'never.' */ +#define CLOCK_SYNC_INTERVAL 5 + +/** Set 'tp' to the current time according to 'base'. We must hold the lock + * on 'base'. If there is a cached time, return it. Otherwise, use + * clock_gettime or gettimeofday as appropriate to find out the right time. + * Return 0 on success, -1 on failure. + */ +static int +gettime(struct event_base *base, struct timeval *tp) +{ + EVENT_BASE_ASSERT_LOCKED(base); + + if (base->tv_cache.tv_sec) { + *tp = base->tv_cache; + return (0); + } + + if (evutil_gettime_monotonic_(&base->monotonic_timer, tp) == -1) { + return -1; + } + + if (base->last_updated_clock_diff + CLOCK_SYNC_INTERVAL + < tp->tv_sec) { + struct timeval tv; + evutil_gettimeofday(&tv,NULL); + evutil_timersub(&tv, tp, &base->tv_clock_diff); + base->last_updated_clock_diff = tp->tv_sec; + } + + return 0; +} + +int +event_base_gettimeofday_cached(struct event_base *base, struct timeval *tv) +{ + int r; + if (!base) { + base = current_base; + if (!current_base) + return evutil_gettimeofday(tv, NULL); + } + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + if (base->tv_cache.tv_sec == 0) { + r = evutil_gettimeofday(tv, NULL); + } else { + evutil_timeradd(&base->tv_cache, &base->tv_clock_diff, tv); + r = 0; + } + EVBASE_RELEASE_LOCK(base, th_base_lock); + return r; +} + +/** Make 'base' have no current cached time. */ +static inline void +clear_time_cache(struct event_base *base) +{ + base->tv_cache.tv_sec = 0; +} + +/** Replace the cached time in 'base' with the current time. */ +static inline void +update_time_cache(struct event_base *base) +{ + base->tv_cache.tv_sec = 0; + if (!(base->flags & EVENT_BASE_FLAG_NO_CACHE_TIME)) + gettime(base, &base->tv_cache); +} + +int +event_base_update_cache_time(struct event_base *base) +{ + + if (!base) { + base = current_base; + if (!current_base) + return -1; + } + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + if (base->running_loop) + update_time_cache(base); + EVBASE_RELEASE_LOCK(base, th_base_lock); + return 0; +} + +static inline struct event * +event_callback_to_event(struct event_callback *evcb) +{ + EVUTIL_ASSERT((evcb->evcb_flags & EVLIST_INIT)); + return EVUTIL_UPCAST(evcb, struct event, ev_evcallback); +} + +static inline struct event_callback * +event_to_event_callback(struct event *ev) +{ + return &ev->ev_evcallback; +} + +struct event_base * +event_init(void) +{ + struct event_base *base = event_base_new_with_config(NULL); + + if (base == NULL) { + event_errx(1, "%s: Unable to construct event_base", __func__); + return NULL; + } + + current_base = base; + + return (base); +} + +struct event_base * +event_base_new(void) +{ + struct event_base *base = NULL; + struct event_config *cfg = event_config_new(); + if (cfg) { + base = event_base_new_with_config(cfg); + event_config_free(cfg); + } + return base; +} + +/** Return true iff 'method' is the name of a method that 'cfg' tells us to + * avoid. */ +static int +event_config_is_avoided_method(const struct event_config *cfg, + const char *method) +{ + struct event_config_entry *entry; + + TAILQ_FOREACH(entry, &cfg->entries, next) { + if (entry->avoid_method != NULL && + strcmp(entry->avoid_method, method) == 0) + return (1); + } + + return (0); +} + +/** Return true iff 'method' is disabled according to the environment. */ +static int +event_is_method_disabled(const char *name) +{ + char environment[64]; + int i; + + evutil_snprintf(environment, sizeof(environment), "EVENT_NO%s", name); + for (i = 8; environment[i] != '\0'; ++i) + environment[i] = EVUTIL_TOUPPER_(environment[i]); + /* Note that evutil_getenv_() ignores the environment entirely if + * we're setuid */ + return (evutil_getenv_(environment) != NULL); +} + +int +event_base_get_features(const struct event_base *base) +{ + return base->evsel->features; +} + +void +event_enable_debug_mode(void) +{ +#ifndef EVENT__DISABLE_DEBUG_MODE + if (event_debug_mode_on_) + event_errx(1, "%s was called twice!", __func__); + if (event_debug_mode_too_late) + event_errx(1, "%s must be called *before* creating any events " + "or event_bases",__func__); + + event_debug_mode_on_ = 1; + + HT_INIT(event_debug_map, &global_debug_map); +#endif +} + +void +event_disable_debug_mode(void) +{ +#ifndef EVENT__DISABLE_DEBUG_MODE + struct event_debug_entry **ent, *victim; + + EVLOCK_LOCK(event_debug_map_lock_, 0); + for (ent = HT_START(event_debug_map, &global_debug_map); ent; ) { + victim = *ent; + ent = HT_NEXT_RMV(event_debug_map, &global_debug_map, ent); + mm_free(victim); + } + HT_CLEAR(event_debug_map, &global_debug_map); + EVLOCK_UNLOCK(event_debug_map_lock_ , 0); + + event_debug_mode_on_ = 0; +#endif +} + +struct event_base * +event_base_new_with_config(const struct event_config *cfg) +{ + int i; + struct event_base *base; + int should_check_environment; + +#ifndef EVENT__DISABLE_DEBUG_MODE + event_debug_mode_too_late = 1; +#endif + + if ((base = mm_calloc(1, sizeof(struct event_base))) == NULL) { + event_warn("%s: calloc", __func__); + return NULL; + } + + if (cfg) + base->flags = cfg->flags; + + should_check_environment = + !(cfg && (cfg->flags & EVENT_BASE_FLAG_IGNORE_ENV)); + + { + struct timeval tmp; + int precise_time = + cfg && (cfg->flags & EVENT_BASE_FLAG_PRECISE_TIMER); + int flags; + if (should_check_environment && !precise_time) { + precise_time = evutil_getenv_("EVENT_PRECISE_TIMER") != NULL; + base->flags |= EVENT_BASE_FLAG_PRECISE_TIMER; + } + flags = precise_time ? EV_MONOT_PRECISE : 0; + evutil_configure_monotonic_time_(&base->monotonic_timer, flags); + + gettime(base, &tmp); + } + + min_heap_ctor_(&base->timeheap); + + base->sig.ev_signal_pair[0] = -1; + base->sig.ev_signal_pair[1] = -1; + base->th_notify_fd[0] = -1; + base->th_notify_fd[1] = -1; + + TAILQ_INIT(&base->active_later_queue); + + evmap_io_initmap_(&base->io); + evmap_signal_initmap_(&base->sigmap); + event_changelist_init_(&base->changelist); + + base->evbase = NULL; + + if (cfg) { + memcpy(&base->max_dispatch_time, + &cfg->max_dispatch_interval, sizeof(struct timeval)); + base->limit_callbacks_after_prio = + cfg->limit_callbacks_after_prio; + } else { + base->max_dispatch_time.tv_sec = -1; + base->limit_callbacks_after_prio = 1; + } + if (cfg && cfg->max_dispatch_callbacks >= 0) { + base->max_dispatch_callbacks = cfg->max_dispatch_callbacks; + } else { + base->max_dispatch_callbacks = INT_MAX; + } + if (base->max_dispatch_callbacks == INT_MAX && + base->max_dispatch_time.tv_sec == -1) + base->limit_callbacks_after_prio = INT_MAX; + + for (i = 0; eventops[i] && !base->evbase; i++) { + if (cfg != NULL) { + /* determine if this backend should be avoided */ + if (event_config_is_avoided_method(cfg, + eventops[i]->name)) + continue; + if ((eventops[i]->features & cfg->require_features) + != cfg->require_features) + continue; + } + + /* also obey the environment variables */ + if (should_check_environment && + event_is_method_disabled(eventops[i]->name)) + continue; + + base->evsel = eventops[i]; + + base->evbase = base->evsel->init(base); + } + + if (base->evbase == NULL) { + event_warnx("%s: no event mechanism available", + __func__); + base->evsel = NULL; + event_base_free(base); + return NULL; + } + + if (evutil_getenv_("EVENT_SHOW_METHOD")) + event_msgx("libevent using: %s", base->evsel->name); + + /* allocate a single active event queue */ + if (event_base_priority_init(base, 1) < 0) { + event_base_free(base); + return NULL; + } + + /* prepare for threading */ + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (EVTHREAD_LOCKING_ENABLED() && + (!cfg || !(cfg->flags & EVENT_BASE_FLAG_NOLOCK))) { + int r; + EVTHREAD_ALLOC_LOCK(base->th_base_lock, 0); + EVTHREAD_ALLOC_COND(base->current_event_cond); + r = evthread_make_base_notifiable(base); + if (r<0) { + event_warnx("%s: Unable to make base notifiable.", __func__); + event_base_free(base); + return NULL; + } + } +#endif + +#ifdef _WIN32 + if (cfg && (cfg->flags & EVENT_BASE_FLAG_STARTUP_IOCP)) + event_base_start_iocp_(base, cfg->n_cpus_hint); +#endif + + return (base); +} + +int +event_base_start_iocp_(struct event_base *base, int n_cpus) +{ +#ifdef _WIN32 + if (base->iocp) + return 0; + base->iocp = event_iocp_port_launch_(n_cpus); + if (!base->iocp) { + event_warnx("%s: Couldn't launch IOCP", __func__); + return -1; + } + return 0; +#else + return -1; +#endif +} + +void +event_base_stop_iocp_(struct event_base *base) +{ +#ifdef _WIN32 + int rv; + + if (!base->iocp) + return; + rv = event_iocp_shutdown_(base->iocp, -1); + EVUTIL_ASSERT(rv >= 0); + base->iocp = NULL; +#endif +} + +static int +event_base_cancel_single_callback_(struct event_base *base, + struct event_callback *evcb, + int run_finalizers) +{ + int result = 0; + + if (evcb->evcb_flags & EVLIST_INIT) { + struct event *ev = event_callback_to_event(evcb); + if (!(ev->ev_flags & EVLIST_INTERNAL)) { + event_del_(ev, EVENT_DEL_EVEN_IF_FINALIZING); + result = 1; + } + } else { + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + event_callback_cancel_nolock_(base, evcb, 1); + EVBASE_RELEASE_LOCK(base, th_base_lock); + result = 1; + } + + if (run_finalizers && (evcb->evcb_flags & EVLIST_FINALIZING)) { + switch (evcb->evcb_closure) { + case EV_CLOSURE_EVENT_FINALIZE: + case EV_CLOSURE_EVENT_FINALIZE_FREE: { + struct event *ev = event_callback_to_event(evcb); + ev->ev_evcallback.evcb_cb_union.evcb_evfinalize(ev, ev->ev_arg); + if (evcb->evcb_closure == EV_CLOSURE_EVENT_FINALIZE_FREE) + mm_free(ev); + break; + } + case EV_CLOSURE_CB_FINALIZE: + evcb->evcb_cb_union.evcb_cbfinalize(evcb, evcb->evcb_arg); + break; + default: + break; + } + } + return result; +} + +static void +event_base_free_(struct event_base *base, int run_finalizers) +{ + int i, n_deleted=0; + struct event *ev; + /* XXXX grab the lock? If there is contention when one thread frees + * the base, then the contending thread will be very sad soon. */ + + /* event_base_free(NULL) is how to free the current_base if we + * made it with event_init and forgot to hold a reference to it. */ + if (base == NULL && current_base) + base = current_base; + /* Don't actually free NULL. */ + if (base == NULL) { + event_warnx("%s: no base to free", __func__); + return; + } + /* XXX(niels) - check for internal events first */ + +#ifdef _WIN32 + event_base_stop_iocp_(base); +#endif + + /* threading fds if we have them */ + if (base->th_notify_fd[0] != -1) { + event_del(&base->th_notify); + EVUTIL_CLOSESOCKET(base->th_notify_fd[0]); + if (base->th_notify_fd[1] != -1) + EVUTIL_CLOSESOCKET(base->th_notify_fd[1]); + base->th_notify_fd[0] = -1; + base->th_notify_fd[1] = -1; + event_debug_unassign(&base->th_notify); + } + + /* Delete all non-internal events. */ + evmap_delete_all_(base); + + while ((ev = min_heap_top_(&base->timeheap)) != NULL) { + event_del(ev); + ++n_deleted; + } + for (i = 0; i < base->n_common_timeouts; ++i) { + struct common_timeout_list *ctl = + base->common_timeout_queues[i]; + event_del(&ctl->timeout_event); /* Internal; doesn't count */ + event_debug_unassign(&ctl->timeout_event); + for (ev = TAILQ_FIRST(&ctl->events); ev; ) { + struct event *next = TAILQ_NEXT(ev, + ev_timeout_pos.ev_next_with_common_timeout); + if (!(ev->ev_flags & EVLIST_INTERNAL)) { + event_del(ev); + ++n_deleted; + } + ev = next; + } + mm_free(ctl); + } + if (base->common_timeout_queues) + mm_free(base->common_timeout_queues); + + for (i = 0; i < base->nactivequeues; ++i) { + struct event_callback *evcb, *next; + for (evcb = TAILQ_FIRST(&base->activequeues[i]); evcb; ) { + next = TAILQ_NEXT(evcb, evcb_active_next); + n_deleted += event_base_cancel_single_callback_(base, evcb, run_finalizers); + evcb = next; + } + } + { + struct event_callback *evcb; + while ((evcb = TAILQ_FIRST(&base->active_later_queue))) { + n_deleted += event_base_cancel_single_callback_(base, evcb, run_finalizers); + } + } + + + if (n_deleted) + event_debug(("%s: %d events were still set in base", + __func__, n_deleted)); + + while (LIST_FIRST(&base->once_events)) { + struct event_once *eonce = LIST_FIRST(&base->once_events); + LIST_REMOVE(eonce, next_once); + mm_free(eonce); + } + + if (base->evsel != NULL && base->evsel->dealloc != NULL) + base->evsel->dealloc(base); + + for (i = 0; i < base->nactivequeues; ++i) + EVUTIL_ASSERT(TAILQ_EMPTY(&base->activequeues[i])); + + EVUTIL_ASSERT(min_heap_empty_(&base->timeheap)); + min_heap_dtor_(&base->timeheap); + + mm_free(base->activequeues); + + evmap_io_clear_(&base->io); + evmap_signal_clear_(&base->sigmap); + event_changelist_freemem_(&base->changelist); + + EVTHREAD_FREE_LOCK(base->th_base_lock, 0); + EVTHREAD_FREE_COND(base->current_event_cond); + + /* If we're freeing current_base, there won't be a current_base. */ + if (base == current_base) + current_base = NULL; + mm_free(base); +} + +void +event_base_free_nofinalize(struct event_base *base) +{ + event_base_free_(base, 0); +} + +void +event_base_free(struct event_base *base) +{ + event_base_free_(base, 1); +} + +/* Fake eventop; used to disable the backend temporarily inside event_reinit + * so that we can call event_del() on an event without telling the backend. + */ +static int +nil_backend_del(struct event_base *b, evutil_socket_t fd, short old, + short events, void *fdinfo) +{ + return 0; +} +const struct eventop nil_eventop = { + "nil", + NULL, /* init: unused. */ + NULL, /* add: unused. */ + nil_backend_del, /* del: used, so needs to be killed. */ + NULL, /* dispatch: unused. */ + NULL, /* dealloc: unused. */ + 0, 0, 0 +}; + +/* reinitialize the event base after a fork */ +int +event_reinit(struct event_base *base) +{ + const struct eventop *evsel; + int res = 0; + int was_notifiable = 0; + int had_signal_added = 0; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + evsel = base->evsel; + + /* check if this event mechanism requires reinit on the backend */ + if (evsel->need_reinit) { + /* We're going to call event_del() on our notify events (the + * ones that tell about signals and wakeup events). But we + * don't actually want to tell the backend to change its + * state, since it might still share some resource (a kqueue, + * an epoll fd) with the parent process, and we don't want to + * delete the fds from _that_ backend, we temporarily stub out + * the evsel with a replacement. + */ + base->evsel = &nil_eventop; + } + + /* We need to re-create a new signal-notification fd and a new + * thread-notification fd. Otherwise, we'll still share those with + * the parent process, which would make any notification sent to them + * get received by one or both of the event loops, more or less at + * random. + */ + if (base->sig.ev_signal_added) { + event_del_nolock_(&base->sig.ev_signal, EVENT_DEL_AUTOBLOCK); + event_debug_unassign(&base->sig.ev_signal); + memset(&base->sig.ev_signal, 0, sizeof(base->sig.ev_signal)); + if (base->sig.ev_signal_pair[0] != -1) + EVUTIL_CLOSESOCKET(base->sig.ev_signal_pair[0]); + if (base->sig.ev_signal_pair[1] != -1) + EVUTIL_CLOSESOCKET(base->sig.ev_signal_pair[1]); + had_signal_added = 1; + base->sig.ev_signal_added = 0; + } + if (base->th_notify_fn != NULL) { + was_notifiable = 1; + base->th_notify_fn = NULL; + } + if (base->th_notify_fd[0] != -1) { + event_del_nolock_(&base->th_notify, EVENT_DEL_AUTOBLOCK); + EVUTIL_CLOSESOCKET(base->th_notify_fd[0]); + if (base->th_notify_fd[1] != -1) + EVUTIL_CLOSESOCKET(base->th_notify_fd[1]); + base->th_notify_fd[0] = -1; + base->th_notify_fd[1] = -1; + event_debug_unassign(&base->th_notify); + } + + /* Replace the original evsel. */ + base->evsel = evsel; + + if (evsel->need_reinit) { + /* Reconstruct the backend through brute-force, so that we do + * not share any structures with the parent process. For some + * backends, this is necessary: epoll and kqueue, for + * instance, have events associated with a kernel + * structure. If didn't reinitialize, we'd share that + * structure with the parent process, and any changes made by + * the parent would affect our backend's behavior (and vice + * versa). + */ + if (base->evsel->dealloc != NULL) + base->evsel->dealloc(base); + base->evbase = evsel->init(base); + if (base->evbase == NULL) { + event_errx(1, + "%s: could not reinitialize event mechanism", + __func__); + res = -1; + goto done; + } + + /* Empty out the changelist (if any): we are starting from a + * blank slate. */ + event_changelist_freemem_(&base->changelist); + + /* Tell the event maps to re-inform the backend about all + * pending events. This will make the signal notification + * event get re-created if necessary. */ + if (evmap_reinit_(base) < 0) + res = -1; + } else { + if (had_signal_added) + res = evsig_init_(base); + } + + /* If we were notifiable before, and nothing just exploded, become + * notifiable again. */ + if (was_notifiable && res == 0) + res = evthread_make_base_notifiable_nolock_(base); + +done: + EVBASE_RELEASE_LOCK(base, th_base_lock); + return (res); +} + +/* Get the monotonic time for this event_base' timer */ +int +event_gettime_monotonic(struct event_base *base, struct timeval *tv) +{ + int rv = -1; + + if (base && tv) { + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + rv = evutil_gettime_monotonic_(&(base->monotonic_timer), tv); + EVBASE_RELEASE_LOCK(base, th_base_lock); + } + + return rv; +} + +const char ** +event_get_supported_methods(void) +{ + static const char **methods = NULL; + const struct eventop **method; + const char **tmp; + int i = 0, k; + + /* count all methods */ + for (method = &eventops[0]; *method != NULL; ++method) { + ++i; + } + + /* allocate one more than we need for the NULL pointer */ + tmp = mm_calloc((i + 1), sizeof(char *)); + if (tmp == NULL) + return (NULL); + + /* populate the array with the supported methods */ + for (k = 0, i = 0; eventops[k] != NULL; ++k) { + tmp[i++] = eventops[k]->name; + } + tmp[i] = NULL; + + if (methods != NULL) + mm_free((char**)methods); + + methods = tmp; + + return (methods); +} + +struct event_config * +event_config_new(void) +{ + struct event_config *cfg = mm_calloc(1, sizeof(*cfg)); + + if (cfg == NULL) + return (NULL); + + TAILQ_INIT(&cfg->entries); + cfg->max_dispatch_interval.tv_sec = -1; + cfg->max_dispatch_callbacks = INT_MAX; + cfg->limit_callbacks_after_prio = 1; + + return (cfg); +} + +static void +event_config_entry_free(struct event_config_entry *entry) +{ + if (entry->avoid_method != NULL) + mm_free((char *)entry->avoid_method); + mm_free(entry); +} + +void +event_config_free(struct event_config *cfg) +{ + struct event_config_entry *entry; + + while ((entry = TAILQ_FIRST(&cfg->entries)) != NULL) { + TAILQ_REMOVE(&cfg->entries, entry, next); + event_config_entry_free(entry); + } + mm_free(cfg); +} + +int +event_config_set_flag(struct event_config *cfg, int flag) +{ + if (!cfg) + return -1; + cfg->flags |= flag; + return 0; +} + +int +event_config_avoid_method(struct event_config *cfg, const char *method) +{ + struct event_config_entry *entry = mm_malloc(sizeof(*entry)); + if (entry == NULL) + return (-1); + + if ((entry->avoid_method = mm_strdup(method)) == NULL) { + mm_free(entry); + return (-1); + } + + TAILQ_INSERT_TAIL(&cfg->entries, entry, next); + + return (0); +} + +int +event_config_require_features(struct event_config *cfg, + int features) +{ + if (!cfg) + return (-1); + cfg->require_features = features; + return (0); +} + +int +event_config_set_num_cpus_hint(struct event_config *cfg, int cpus) +{ + if (!cfg) + return (-1); + cfg->n_cpus_hint = cpus; + return (0); +} + +int +event_config_set_max_dispatch_interval(struct event_config *cfg, + const struct timeval *max_interval, int max_callbacks, int min_priority) +{ + if (max_interval) + memcpy(&cfg->max_dispatch_interval, max_interval, + sizeof(struct timeval)); + else + cfg->max_dispatch_interval.tv_sec = -1; + cfg->max_dispatch_callbacks = + max_callbacks >= 0 ? max_callbacks : INT_MAX; + if (min_priority < 0) + min_priority = 0; + cfg->limit_callbacks_after_prio = min_priority; + return (0); +} + +int +event_priority_init(int npriorities) +{ + return event_base_priority_init(current_base, npriorities); +} + +int +event_base_priority_init(struct event_base *base, int npriorities) +{ + int i, r; + r = -1; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (N_ACTIVE_CALLBACKS(base) || npriorities < 1 + || npriorities >= EVENT_MAX_PRIORITIES) + goto err; + + if (npriorities == base->nactivequeues) + goto ok; + + if (base->nactivequeues) { + mm_free(base->activequeues); + base->nactivequeues = 0; + } + + /* Allocate our priority queues */ + base->activequeues = (struct evcallback_list *) + mm_calloc(npriorities, sizeof(struct evcallback_list)); + if (base->activequeues == NULL) { + event_warn("%s: calloc", __func__); + goto err; + } + base->nactivequeues = npriorities; + + for (i = 0; i < base->nactivequeues; ++i) { + TAILQ_INIT(&base->activequeues[i]); + } + +ok: + r = 0; +err: + EVBASE_RELEASE_LOCK(base, th_base_lock); + return (r); +} + +int +event_base_get_npriorities(struct event_base *base) +{ + + int n; + if (base == NULL) + base = current_base; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + n = base->nactivequeues; + EVBASE_RELEASE_LOCK(base, th_base_lock); + return (n); +} + +int +event_base_get_num_events(struct event_base *base, unsigned int type) +{ + int r = 0; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (type & EVENT_BASE_COUNT_ACTIVE) + r += base->event_count_active; + + if (type & EVENT_BASE_COUNT_VIRTUAL) + r += base->virtual_event_count; + + if (type & EVENT_BASE_COUNT_ADDED) + r += base->event_count; + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + return r; +} + +int +event_base_get_max_events(struct event_base *base, unsigned int type, int clear) +{ + int r = 0; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (type & EVENT_BASE_COUNT_ACTIVE) { + r += base->event_count_active_max; + if (clear) + base->event_count_active_max = 0; + } + + if (type & EVENT_BASE_COUNT_VIRTUAL) { + r += base->virtual_event_count_max; + if (clear) + base->virtual_event_count_max = 0; + } + + if (type & EVENT_BASE_COUNT_ADDED) { + r += base->event_count_max; + if (clear) + base->event_count_max = 0; + } + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + return r; +} + +/* Returns true iff we're currently watching any events. */ +static int +event_haveevents(struct event_base *base) +{ + /* Caller must hold th_base_lock */ + return (base->virtual_event_count > 0 || base->event_count > 0); +} + +/* "closure" function called when processing active signal events */ +static inline void +event_signal_closure(struct event_base *base, struct event *ev) +{ + short ncalls; + int should_break; + + /* Allows deletes to work */ + ncalls = ev->ev_ncalls; + if (ncalls != 0) + ev->ev_pncalls = &ncalls; + EVBASE_RELEASE_LOCK(base, th_base_lock); + while (ncalls) { + ncalls--; + ev->ev_ncalls = ncalls; + if (ncalls == 0) + ev->ev_pncalls = NULL; + (*ev->ev_callback)(ev->ev_fd, ev->ev_res, ev->ev_arg); + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + should_break = base->event_break; + EVBASE_RELEASE_LOCK(base, th_base_lock); + + if (should_break) { + if (ncalls != 0) + ev->ev_pncalls = NULL; + return; + } + } +} + +/* Common timeouts are special timeouts that are handled as queues rather than + * in the minheap. This is more efficient than the minheap if we happen to + * know that we're going to get several thousands of timeout events all with + * the same timeout value. + * + * Since all our timeout handling code assumes timevals can be copied, + * assigned, etc, we can't use "magic pointer" to encode these common + * timeouts. Searching through a list to see if every timeout is common could + * also get inefficient. Instead, we take advantage of the fact that tv_usec + * is 32 bits long, but only uses 20 of those bits (since it can never be over + * 999999.) We use the top bits to encode 4 bites of magic number, and 8 bits + * of index into the event_base's aray of common timeouts. + */ + +#define MICROSECONDS_MASK COMMON_TIMEOUT_MICROSECONDS_MASK +#define COMMON_TIMEOUT_IDX_MASK 0x0ff00000 +#define COMMON_TIMEOUT_IDX_SHIFT 20 +#define COMMON_TIMEOUT_MASK 0xf0000000 +#define COMMON_TIMEOUT_MAGIC 0x50000000 + +#define COMMON_TIMEOUT_IDX(tv) \ + (((tv)->tv_usec & COMMON_TIMEOUT_IDX_MASK)>>COMMON_TIMEOUT_IDX_SHIFT) + +/** Return true iff if 'tv' is a common timeout in 'base' */ +static inline int +is_common_timeout(const struct timeval *tv, + const struct event_base *base) +{ + int idx; + if ((tv->tv_usec & COMMON_TIMEOUT_MASK) != COMMON_TIMEOUT_MAGIC) + return 0; + idx = COMMON_TIMEOUT_IDX(tv); + return idx < base->n_common_timeouts; +} + +/* True iff tv1 and tv2 have the same common-timeout index, or if neither + * one is a common timeout. */ +static inline int +is_same_common_timeout(const struct timeval *tv1, const struct timeval *tv2) +{ + return (tv1->tv_usec & ~MICROSECONDS_MASK) == + (tv2->tv_usec & ~MICROSECONDS_MASK); +} + +/** Requires that 'tv' is a common timeout. Return the corresponding + * common_timeout_list. */ +static inline struct common_timeout_list * +get_common_timeout_list(struct event_base *base, const struct timeval *tv) +{ + return base->common_timeout_queues[COMMON_TIMEOUT_IDX(tv)]; +} + +#if 0 +static inline int +common_timeout_ok(const struct timeval *tv, + struct event_base *base) +{ + const struct timeval *expect = + &get_common_timeout_list(base, tv)->duration; + return tv->tv_sec == expect->tv_sec && + tv->tv_usec == expect->tv_usec; +} +#endif + +/* Add the timeout for the first event in given common timeout list to the + * event_base's minheap. */ +static void +common_timeout_schedule(struct common_timeout_list *ctl, + const struct timeval *now, struct event *head) +{ + struct timeval timeout = head->ev_timeout; + timeout.tv_usec &= MICROSECONDS_MASK; + event_add_nolock_(&ctl->timeout_event, &timeout, 1); +} + +/* Callback: invoked when the timeout for a common timeout queue triggers. + * This means that (at least) the first event in that queue should be run, + * and the timeout should be rescheduled if there are more events. */ +static void +common_timeout_callback(evutil_socket_t fd, short what, void *arg) +{ + struct timeval now; + struct common_timeout_list *ctl = arg; + struct event_base *base = ctl->base; + struct event *ev = NULL; + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + gettime(base, &now); + while (1) { + ev = TAILQ_FIRST(&ctl->events); + if (!ev || ev->ev_timeout.tv_sec > now.tv_sec || + (ev->ev_timeout.tv_sec == now.tv_sec && + (ev->ev_timeout.tv_usec&MICROSECONDS_MASK) > now.tv_usec)) + break; + event_del_nolock_(ev, EVENT_DEL_NOBLOCK); + event_active_nolock_(ev, EV_TIMEOUT, 1); + } + if (ev) + common_timeout_schedule(ctl, &now, ev); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +#define MAX_COMMON_TIMEOUTS 256 + +const struct timeval * +event_base_init_common_timeout(struct event_base *base, + const struct timeval *duration) +{ + int i; + struct timeval tv; + const struct timeval *result=NULL; + struct common_timeout_list *new_ctl; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + if (duration->tv_usec > 1000000) { + memcpy(&tv, duration, sizeof(struct timeval)); + if (is_common_timeout(duration, base)) + tv.tv_usec &= MICROSECONDS_MASK; + tv.tv_sec += tv.tv_usec / 1000000; + tv.tv_usec %= 1000000; + duration = &tv; + } + for (i = 0; i < base->n_common_timeouts; ++i) { + const struct common_timeout_list *ctl = + base->common_timeout_queues[i]; + if (duration->tv_sec == ctl->duration.tv_sec && + duration->tv_usec == + (ctl->duration.tv_usec & MICROSECONDS_MASK)) { + EVUTIL_ASSERT(is_common_timeout(&ctl->duration, base)); + result = &ctl->duration; + goto done; + } + } + if (base->n_common_timeouts == MAX_COMMON_TIMEOUTS) { + event_warnx("%s: Too many common timeouts already in use; " + "we only support %d per event_base", __func__, + MAX_COMMON_TIMEOUTS); + goto done; + } + if (base->n_common_timeouts_allocated == base->n_common_timeouts) { + int n = base->n_common_timeouts < 16 ? 16 : + base->n_common_timeouts*2; + struct common_timeout_list **newqueues = + mm_realloc(base->common_timeout_queues, + n*sizeof(struct common_timeout_queue *)); + if (!newqueues) { + event_warn("%s: realloc",__func__); + goto done; + } + base->n_common_timeouts_allocated = n; + base->common_timeout_queues = newqueues; + } + new_ctl = mm_calloc(1, sizeof(struct common_timeout_list)); + if (!new_ctl) { + event_warn("%s: calloc",__func__); + goto done; + } + TAILQ_INIT(&new_ctl->events); + new_ctl->duration.tv_sec = duration->tv_sec; + new_ctl->duration.tv_usec = + duration->tv_usec | COMMON_TIMEOUT_MAGIC | + (base->n_common_timeouts << COMMON_TIMEOUT_IDX_SHIFT); + evtimer_assign(&new_ctl->timeout_event, base, + common_timeout_callback, new_ctl); + new_ctl->timeout_event.ev_flags |= EVLIST_INTERNAL; + event_priority_set(&new_ctl->timeout_event, 0); + new_ctl->base = base; + base->common_timeout_queues[base->n_common_timeouts++] = new_ctl; + result = &new_ctl->duration; + +done: + if (result) + EVUTIL_ASSERT(is_common_timeout(result, base)); + + EVBASE_RELEASE_LOCK(base, th_base_lock); + return result; +} + +/* Closure function invoked when we're activating a persistent event. */ +static inline void +event_persist_closure(struct event_base *base, struct event *ev) +{ + void (*evcb_callback)(evutil_socket_t, short, void *); + + // Other fields of *ev that must be stored before executing + evutil_socket_t evcb_fd; + short evcb_res; + void *evcb_arg; + + /* reschedule the persistent event if we have a timeout. */ + if (ev->ev_io_timeout.tv_sec || ev->ev_io_timeout.tv_usec) { + /* If there was a timeout, we want it to run at an interval of + * ev_io_timeout after the last time it was _scheduled_ for, + * not ev_io_timeout after _now_. If it fired for another + * reason, though, the timeout ought to start ticking _now_. */ + struct timeval run_at, relative_to, delay, now; + ev_uint32_t usec_mask = 0; + EVUTIL_ASSERT(is_same_common_timeout(&ev->ev_timeout, + &ev->ev_io_timeout)); + gettime(base, &now); + if (is_common_timeout(&ev->ev_timeout, base)) { + delay = ev->ev_io_timeout; + usec_mask = delay.tv_usec & ~MICROSECONDS_MASK; + delay.tv_usec &= MICROSECONDS_MASK; + if (ev->ev_res & EV_TIMEOUT) { + relative_to = ev->ev_timeout; + relative_to.tv_usec &= MICROSECONDS_MASK; + } else { + relative_to = now; + } + } else { + delay = ev->ev_io_timeout; + if (ev->ev_res & EV_TIMEOUT) { + relative_to = ev->ev_timeout; + } else { + relative_to = now; + } + } + evutil_timeradd(&relative_to, &delay, &run_at); + if (evutil_timercmp(&run_at, &now, <)) { + /* Looks like we missed at least one invocation due to + * a clock jump, not running the event loop for a + * while, really slow callbacks, or + * something. Reschedule relative to now. + */ + evutil_timeradd(&now, &delay, &run_at); + } + run_at.tv_usec |= usec_mask; + event_add_nolock_(ev, &run_at, 1); + } + + // Save our callback before we release the lock + evcb_callback = ev->ev_callback; + evcb_fd = ev->ev_fd; + evcb_res = ev->ev_res; + evcb_arg = ev->ev_arg; + + // Release the lock + EVBASE_RELEASE_LOCK(base, th_base_lock); + + // Execute the callback + (evcb_callback)(evcb_fd, evcb_res, evcb_arg); +} + +/* + Helper for event_process_active to process all the events in a single queue, + releasing the lock as we go. This function requires that the lock be held + when it's invoked. Returns -1 if we get a signal or an event_break that + means we should stop processing any active events now. Otherwise returns + the number of non-internal event_callbacks that we processed. +*/ +static int +event_process_active_single_queue(struct event_base *base, + struct evcallback_list *activeq, + int max_to_process, const struct timeval *endtime) +{ + struct event_callback *evcb; + int count = 0; + + EVUTIL_ASSERT(activeq != NULL); + + for (evcb = TAILQ_FIRST(activeq); evcb; evcb = TAILQ_FIRST(activeq)) { + struct event *ev=NULL; + if (evcb->evcb_flags & EVLIST_INIT) { + ev = event_callback_to_event(evcb); + + if (ev->ev_events & EV_PERSIST || ev->ev_flags & EVLIST_FINALIZING) + event_queue_remove_active(base, evcb); + else + event_del_nolock_(ev, EVENT_DEL_NOBLOCK); + event_debug(( + "event_process_active: event: %p, %s%s%scall %p", + ev, + ev->ev_res & EV_READ ? "EV_READ " : " ", + ev->ev_res & EV_WRITE ? "EV_WRITE " : " ", + ev->ev_res & EV_CLOSED ? "EV_CLOSED " : " ", + ev->ev_callback)); + } else { + event_queue_remove_active(base, evcb); + event_debug(("event_process_active: event_callback %p, " + "closure %d, call %p", + evcb, evcb->evcb_closure, evcb->evcb_cb_union.evcb_callback)); + } + + if (!(evcb->evcb_flags & EVLIST_INTERNAL)) + ++count; + + + base->current_event = evcb; +#ifndef EVENT__DISABLE_THREAD_SUPPORT + base->current_event_waiters = 0; +#endif + + switch (evcb->evcb_closure) { + case EV_CLOSURE_EVENT_SIGNAL: + EVUTIL_ASSERT(ev != NULL); + event_signal_closure(base, ev); + break; + case EV_CLOSURE_EVENT_PERSIST: + EVUTIL_ASSERT(ev != NULL); + event_persist_closure(base, ev); + break; + case EV_CLOSURE_EVENT: { + void (*evcb_callback)(evutil_socket_t, short, void *); + EVUTIL_ASSERT(ev != NULL); + evcb_callback = *ev->ev_callback; + EVBASE_RELEASE_LOCK(base, th_base_lock); + evcb_callback(ev->ev_fd, ev->ev_res, ev->ev_arg); + } + break; + case EV_CLOSURE_CB_SELF: { + void (*evcb_selfcb)(struct event_callback *, void *) = evcb->evcb_cb_union.evcb_selfcb; + EVBASE_RELEASE_LOCK(base, th_base_lock); + evcb_selfcb(evcb, evcb->evcb_arg); + } + break; + case EV_CLOSURE_EVENT_FINALIZE: + case EV_CLOSURE_EVENT_FINALIZE_FREE: { + void (*evcb_evfinalize)(struct event *, void *); + int evcb_closure = evcb->evcb_closure; + EVUTIL_ASSERT(ev != NULL); + base->current_event = NULL; + evcb_evfinalize = ev->ev_evcallback.evcb_cb_union.evcb_evfinalize; + EVUTIL_ASSERT((evcb->evcb_flags & EVLIST_FINALIZING)); + EVBASE_RELEASE_LOCK(base, th_base_lock); + evcb_evfinalize(ev, ev->ev_arg); + event_debug_note_teardown_(ev); + if (evcb_closure == EV_CLOSURE_EVENT_FINALIZE_FREE) + mm_free(ev); + } + break; + case EV_CLOSURE_CB_FINALIZE: { + void (*evcb_cbfinalize)(struct event_callback *, void *) = evcb->evcb_cb_union.evcb_cbfinalize; + base->current_event = NULL; + EVUTIL_ASSERT((evcb->evcb_flags & EVLIST_FINALIZING)); + EVBASE_RELEASE_LOCK(base, th_base_lock); + evcb_cbfinalize(evcb, evcb->evcb_arg); + } + break; + default: + EVUTIL_ASSERT(0); + } + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + base->current_event = NULL; +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (base->current_event_waiters) { + base->current_event_waiters = 0; + EVTHREAD_COND_BROADCAST(base->current_event_cond); + } +#endif + + if (base->event_break) + return -1; + if (count >= max_to_process) + return count; + if (count && endtime) { + struct timeval now; + update_time_cache(base); + gettime(base, &now); + if (evutil_timercmp(&now, endtime, >=)) + return count; + } + if (base->event_continue) + break; + } + return count; +} + +/* + * Active events are stored in priority queues. Lower priorities are always + * process before higher priorities. Low priority events can starve high + * priority ones. + */ + +static int +event_process_active(struct event_base *base) +{ + /* Caller must hold th_base_lock */ + struct evcallback_list *activeq = NULL; + int i, c = 0; + const struct timeval *endtime; + struct timeval tv; + const int maxcb = base->max_dispatch_callbacks; + const int limit_after_prio = base->limit_callbacks_after_prio; + if (base->max_dispatch_time.tv_sec >= 0) { + update_time_cache(base); + gettime(base, &tv); + evutil_timeradd(&base->max_dispatch_time, &tv, &tv); + endtime = &tv; + } else { + endtime = NULL; + } + + for (i = 0; i < base->nactivequeues; ++i) { + if (TAILQ_FIRST(&base->activequeues[i]) != NULL) { + base->event_running_priority = i; + activeq = &base->activequeues[i]; + if (i < limit_after_prio) + c = event_process_active_single_queue(base, activeq, + INT_MAX, NULL); + else + c = event_process_active_single_queue(base, activeq, + maxcb, endtime); + if (c < 0) { + goto done; + } else if (c > 0) + break; /* Processed a real event; do not + * consider lower-priority events */ + /* If we get here, all of the events we processed + * were internal. Continue. */ + } + } + +done: + base->event_running_priority = -1; + + return c; +} + +/* + * Wait continuously for events. We exit only if no events are left. + */ + +int +event_dispatch(void) +{ + return (event_loop(0)); +} + +int +event_base_dispatch(struct event_base *event_base) +{ + return (event_base_loop(event_base, 0)); +} + +const char * +event_base_get_method(const struct event_base *base) +{ + EVUTIL_ASSERT(base); + return (base->evsel->name); +} + +/** Callback: used to implement event_base_loopexit by telling the event_base + * that it's time to exit its loop. */ +static void +event_loopexit_cb(evutil_socket_t fd, short what, void *arg) +{ + struct event_base *base = arg; + base->event_gotterm = 1; +} + +int +event_loopexit(const struct timeval *tv) +{ + return (event_once(-1, EV_TIMEOUT, event_loopexit_cb, + current_base, tv)); +} + +int +event_base_loopexit(struct event_base *event_base, const struct timeval *tv) +{ + return (event_base_once(event_base, -1, EV_TIMEOUT, event_loopexit_cb, + event_base, tv)); +} + +int +event_loopbreak(void) +{ + return (event_base_loopbreak(current_base)); +} + +int +event_base_loopbreak(struct event_base *event_base) +{ + int r = 0; + if (event_base == NULL) + return (-1); + + EVBASE_ACQUIRE_LOCK(event_base, th_base_lock); + event_base->event_break = 1; + + if (EVBASE_NEED_NOTIFY(event_base)) { + r = evthread_notify_base(event_base); + } else { + r = (0); + } + EVBASE_RELEASE_LOCK(event_base, th_base_lock); + return r; +} + +int +event_base_loopcontinue(struct event_base *event_base) +{ + int r = 0; + if (event_base == NULL) + return (-1); + + EVBASE_ACQUIRE_LOCK(event_base, th_base_lock); + event_base->event_continue = 1; + + if (EVBASE_NEED_NOTIFY(event_base)) { + r = evthread_notify_base(event_base); + } else { + r = (0); + } + EVBASE_RELEASE_LOCK(event_base, th_base_lock); + return r; +} + +int +event_base_got_break(struct event_base *event_base) +{ + int res; + EVBASE_ACQUIRE_LOCK(event_base, th_base_lock); + res = event_base->event_break; + EVBASE_RELEASE_LOCK(event_base, th_base_lock); + return res; +} + +int +event_base_got_exit(struct event_base *event_base) +{ + int res; + EVBASE_ACQUIRE_LOCK(event_base, th_base_lock); + res = event_base->event_gotterm; + EVBASE_RELEASE_LOCK(event_base, th_base_lock); + return res; +} + +/* not thread safe */ + +int +event_loop(int flags) +{ + return event_base_loop(current_base, flags); +} + +int +event_base_loop(struct event_base *base, int flags) +{ + const struct eventop *evsel = base->evsel; + struct timeval tv; + struct timeval *tv_p; + int res, done, retval = 0; + + /* Grab the lock. We will release it inside evsel.dispatch, and again + * as we invoke user callbacks. */ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (base->running_loop) { + event_warnx("%s: reentrant invocation. Only one event_base_loop" + " can run on each event_base at once.", __func__); + EVBASE_RELEASE_LOCK(base, th_base_lock); + return -1; + } + + base->running_loop = 1; + + clear_time_cache(base); + + if (base->sig.ev_signal_added && base->sig.ev_n_signals_added) + evsig_set_base_(base); + + done = 0; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + base->th_owner_id = EVTHREAD_GET_ID(); +#endif + + base->event_gotterm = base->event_break = 0; + + while (!done) { + base->event_continue = 0; + base->n_deferreds_queued = 0; + + /* Terminate the loop if we have been asked to */ + if (base->event_gotterm) { + break; + } + + if (base->event_break) { + break; + } + + tv_p = &tv; + if (!N_ACTIVE_CALLBACKS(base) && !(flags & EVLOOP_NONBLOCK)) { + timeout_next(base, &tv_p); + } else { + /* + * if we have active events, we just poll new events + * without waiting. + */ + evutil_timerclear(&tv); + } + + /* If we have no events, we just exit */ + if (0==(flags&EVLOOP_NO_EXIT_ON_EMPTY) && + !event_haveevents(base) && !N_ACTIVE_CALLBACKS(base)) { + event_debug(("%s: no events registered.", __func__)); + retval = 1; + goto done; + } + + event_queue_make_later_events_active(base); + + clear_time_cache(base); + + res = evsel->dispatch(base, tv_p); + + if (res == -1) { + event_debug(("%s: dispatch returned unsuccessfully.", + __func__)); + retval = -1; + goto done; + } + + update_time_cache(base); + + timeout_process(base); + + if (N_ACTIVE_CALLBACKS(base)) { + int n = event_process_active(base); + if ((flags & EVLOOP_ONCE) + && N_ACTIVE_CALLBACKS(base) == 0 + && n != 0) + done = 1; + } else if (flags & EVLOOP_NONBLOCK) + done = 1; + } + event_debug(("%s: asked to terminate loop.", __func__)); + +done: + clear_time_cache(base); + base->running_loop = 0; + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + return (retval); +} + +/* One-time callback to implement event_base_once: invokes the user callback, + * then deletes the allocated storage */ +static void +event_once_cb(evutil_socket_t fd, short events, void *arg) +{ + struct event_once *eonce = arg; + + (*eonce->cb)(fd, events, eonce->arg); + EVBASE_ACQUIRE_LOCK(eonce->ev.ev_base, th_base_lock); + LIST_REMOVE(eonce, next_once); + EVBASE_RELEASE_LOCK(eonce->ev.ev_base, th_base_lock); + event_debug_unassign(&eonce->ev); + mm_free(eonce); +} + +/* not threadsafe, event scheduled once. */ +int +event_once(evutil_socket_t fd, short events, + void (*callback)(evutil_socket_t, short, void *), + void *arg, const struct timeval *tv) +{ + return event_base_once(current_base, fd, events, callback, arg, tv); +} + +/* Schedules an event once */ +int +event_base_once(struct event_base *base, evutil_socket_t fd, short events, + void (*callback)(evutil_socket_t, short, void *), + void *arg, const struct timeval *tv) +{ + struct event_once *eonce; + int res = 0; + int activate = 0; + + /* We cannot support signals that just fire once, or persistent + * events. */ + if (events & (EV_SIGNAL|EV_PERSIST)) + return (-1); + + if ((eonce = mm_calloc(1, sizeof(struct event_once))) == NULL) + return (-1); + + eonce->cb = callback; + eonce->arg = arg; + + if ((events & (EV_TIMEOUT|EV_SIGNAL|EV_READ|EV_WRITE|EV_CLOSED)) == EV_TIMEOUT) { + evtimer_assign(&eonce->ev, base, event_once_cb, eonce); + + if (tv == NULL || ! evutil_timerisset(tv)) { + /* If the event is going to become active immediately, + * don't put it on the timeout queue. This is one + * idiom for scheduling a callback, so let's make + * it fast (and order-preserving). */ + activate = 1; + } + } else if (events & (EV_READ|EV_WRITE|EV_CLOSED)) { + events &= EV_READ|EV_WRITE|EV_CLOSED; + + event_assign(&eonce->ev, base, fd, events, event_once_cb, eonce); + } else { + /* Bad event combination */ + mm_free(eonce); + return (-1); + } + + if (res == 0) { + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + if (activate) + event_active_nolock_(&eonce->ev, EV_TIMEOUT, 1); + else + res = event_add_nolock_(&eonce->ev, tv, 0); + + if (res != 0) { + mm_free(eonce); + return (res); + } else { + LIST_INSERT_HEAD(&base->once_events, eonce, next_once); + } + EVBASE_RELEASE_LOCK(base, th_base_lock); + } + + return (0); +} + +int +event_assign(struct event *ev, struct event_base *base, evutil_socket_t fd, short events, void (*callback)(evutil_socket_t, short, void *), void *arg) +{ + if (!base) + base = current_base; + if (arg == &event_self_cbarg_ptr_) + arg = ev; + + event_debug_assert_not_added_(ev); + + ev->ev_base = base; + + ev->ev_callback = callback; + ev->ev_arg = arg; + ev->ev_fd = fd; + ev->ev_events = events; + ev->ev_res = 0; + ev->ev_flags = EVLIST_INIT; + ev->ev_ncalls = 0; + ev->ev_pncalls = NULL; + + if (events & EV_SIGNAL) { + if ((events & (EV_READ|EV_WRITE|EV_CLOSED)) != 0) { + event_warnx("%s: EV_SIGNAL is not compatible with " + "EV_READ, EV_WRITE or EV_CLOSED", __func__); + return -1; + } + ev->ev_closure = EV_CLOSURE_EVENT_SIGNAL; + } else { + if (events & EV_PERSIST) { + evutil_timerclear(&ev->ev_io_timeout); + ev->ev_closure = EV_CLOSURE_EVENT_PERSIST; + } else { + ev->ev_closure = EV_CLOSURE_EVENT; + } + } + + min_heap_elem_init_(ev); + + if (base != NULL) { + /* by default, we put new events into the middle priority */ + ev->ev_pri = base->nactivequeues / 2; + } + + event_debug_note_setup_(ev); + + return 0; +} + +int +event_base_set(struct event_base *base, struct event *ev) +{ + /* Only innocent events may be assigned to a different base */ + if (ev->ev_flags != EVLIST_INIT) + return (-1); + + event_debug_assert_is_setup_(ev); + + ev->ev_base = base; + ev->ev_pri = base->nactivequeues/2; + + return (0); +} + +void +event_set(struct event *ev, evutil_socket_t fd, short events, + void (*callback)(evutil_socket_t, short, void *), void *arg) +{ + int r; + r = event_assign(ev, current_base, fd, events, callback, arg); + EVUTIL_ASSERT(r == 0); +} + +void * +event_self_cbarg(void) +{ + return &event_self_cbarg_ptr_; +} + +struct event * +event_base_get_running_event(struct event_base *base) +{ + struct event *ev = NULL; + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + if (EVBASE_IN_THREAD(base)) { + struct event_callback *evcb = base->current_event; + if (evcb->evcb_flags & EVLIST_INIT) + ev = event_callback_to_event(evcb); + } + EVBASE_RELEASE_LOCK(base, th_base_lock); + return ev; +} + +struct event * +event_new(struct event_base *base, evutil_socket_t fd, short events, void (*cb)(evutil_socket_t, short, void *), void *arg) +{ + struct event *ev; + ev = mm_malloc(sizeof(struct event)); + if (ev == NULL) + return (NULL); + if (event_assign(ev, base, fd, events, cb, arg) < 0) { + mm_free(ev); + return (NULL); + } + + return (ev); +} + +void +event_free(struct event *ev) +{ + /* This is disabled, so that events which have been finalized be a + * valid target for event_free(). That's */ + // event_debug_assert_is_setup_(ev); + + /* make sure that this event won't be coming back to haunt us. */ + event_del(ev); + event_debug_note_teardown_(ev); + mm_free(ev); + +} + +void +event_debug_unassign(struct event *ev) +{ + event_debug_assert_not_added_(ev); + event_debug_note_teardown_(ev); + + ev->ev_flags &= ~EVLIST_INIT; +} + +#define EVENT_FINALIZE_FREE_ 0x10000 +static int +event_finalize_nolock_(struct event_base *base, unsigned flags, struct event *ev, event_finalize_callback_fn cb) +{ + ev_uint8_t closure = (flags & EVENT_FINALIZE_FREE_) ? + EV_CLOSURE_EVENT_FINALIZE_FREE : EV_CLOSURE_EVENT_FINALIZE; + + event_del_nolock_(ev, EVENT_DEL_NOBLOCK); + ev->ev_closure = closure; + ev->ev_evcallback.evcb_cb_union.evcb_evfinalize = cb; + event_active_nolock_(ev, EV_FINALIZE, 1); + ev->ev_flags |= EVLIST_FINALIZING; + return 0; +} + +static int +event_finalize_impl_(unsigned flags, struct event *ev, event_finalize_callback_fn cb) +{ + int r; + struct event_base *base = ev->ev_base; + if (EVUTIL_FAILURE_CHECK(!base)) { + event_warnx("%s: event has no event_base set.", __func__); + return -1; + } + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + r = event_finalize_nolock_(base, flags, ev, cb); + EVBASE_RELEASE_LOCK(base, th_base_lock); + return r; +} + +int +event_finalize(unsigned flags, struct event *ev, event_finalize_callback_fn cb) +{ + return event_finalize_impl_(flags, ev, cb); +} + +int +event_free_finalize(unsigned flags, struct event *ev, event_finalize_callback_fn cb) +{ + return event_finalize_impl_(flags|EVENT_FINALIZE_FREE_, ev, cb); +} + +void +event_callback_finalize_nolock_(struct event_base *base, unsigned flags, struct event_callback *evcb, void (*cb)(struct event_callback *, void *)) +{ + struct event *ev = NULL; + if (evcb->evcb_flags & EVLIST_INIT) { + ev = event_callback_to_event(evcb); + event_del_nolock_(ev, EVENT_DEL_NOBLOCK); + } else { + event_callback_cancel_nolock_(base, evcb, 0); /*XXX can this fail?*/ + } + + evcb->evcb_closure = EV_CLOSURE_CB_FINALIZE; + evcb->evcb_cb_union.evcb_cbfinalize = cb; + event_callback_activate_nolock_(base, evcb); /* XXX can this really fail?*/ + evcb->evcb_flags |= EVLIST_FINALIZING; +} + +void +event_callback_finalize_(struct event_base *base, unsigned flags, struct event_callback *evcb, void (*cb)(struct event_callback *, void *)) +{ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + event_callback_finalize_nolock_(base, flags, evcb, cb); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +/** Internal: Finalize all of the n_cbs callbacks in evcbs. The provided + * callback will be invoked on *one of them*, after they have *all* been + * finalized. */ +int +event_callback_finalize_many_(struct event_base *base, int n_cbs, struct event_callback **evcbs, void (*cb)(struct event_callback *, void *)) +{ + int n_pending = 0, i; + + if (base == NULL) + base = current_base; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + event_debug(("%s: %d events finalizing", __func__, n_cbs)); + + /* At most one can be currently executing; the rest we just + * cancel... But we always make sure that the finalize callback + * runs. */ + for (i = 0; i < n_cbs; ++i) { + struct event_callback *evcb = evcbs[i]; + if (evcb == base->current_event) { + event_callback_finalize_nolock_(base, 0, evcb, cb); + ++n_pending; + } else { + event_callback_cancel_nolock_(base, evcb, 0); + } + } + + if (n_pending == 0) { + /* Just do the first one. */ + event_callback_finalize_nolock_(base, 0, evcbs[0], cb); + } + + EVBASE_RELEASE_LOCK(base, th_base_lock); + return 0; +} + +/* + * Set's the priority of an event - if an event is already scheduled + * changing the priority is going to fail. + */ + +int +event_priority_set(struct event *ev, int pri) +{ + event_debug_assert_is_setup_(ev); + + if (ev->ev_flags & EVLIST_ACTIVE) + return (-1); + if (pri < 0 || pri >= ev->ev_base->nactivequeues) + return (-1); + + ev->ev_pri = pri; + + return (0); +} + +/* + * Checks if a specific event is pending or scheduled. + */ + +int +event_pending(const struct event *ev, short event, struct timeval *tv) +{ + int flags = 0; + + if (EVUTIL_FAILURE_CHECK(ev->ev_base == NULL)) { + event_warnx("%s: event has no event_base set.", __func__); + return 0; + } + + EVBASE_ACQUIRE_LOCK(ev->ev_base, th_base_lock); + event_debug_assert_is_setup_(ev); + + if (ev->ev_flags & EVLIST_INSERTED) + flags |= (ev->ev_events & (EV_READ|EV_WRITE|EV_CLOSED|EV_SIGNAL)); + if (ev->ev_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER)) + flags |= ev->ev_res; + if (ev->ev_flags & EVLIST_TIMEOUT) + flags |= EV_TIMEOUT; + + event &= (EV_TIMEOUT|EV_READ|EV_WRITE|EV_CLOSED|EV_SIGNAL); + + /* See if there is a timeout that we should report */ + if (tv != NULL && (flags & event & EV_TIMEOUT)) { + struct timeval tmp = ev->ev_timeout; + tmp.tv_usec &= MICROSECONDS_MASK; + /* correctly remamp to real time */ + evutil_timeradd(&ev->ev_base->tv_clock_diff, &tmp, tv); + } + + EVBASE_RELEASE_LOCK(ev->ev_base, th_base_lock); + + return (flags & event); +} + +int +event_initialized(const struct event *ev) +{ + if (!(ev->ev_flags & EVLIST_INIT)) + return 0; + + return 1; +} + +void +event_get_assignment(const struct event *event, struct event_base **base_out, evutil_socket_t *fd_out, short *events_out, event_callback_fn *callback_out, void **arg_out) +{ + event_debug_assert_is_setup_(event); + + if (base_out) + *base_out = event->ev_base; + if (fd_out) + *fd_out = event->ev_fd; + if (events_out) + *events_out = event->ev_events; + if (callback_out) + *callback_out = event->ev_callback; + if (arg_out) + *arg_out = event->ev_arg; +} + +size_t +event_get_struct_event_size(void) +{ + return sizeof(struct event); +} + +evutil_socket_t +event_get_fd(const struct event *ev) +{ + event_debug_assert_is_setup_(ev); + return ev->ev_fd; +} + +struct event_base * +event_get_base(const struct event *ev) +{ + event_debug_assert_is_setup_(ev); + return ev->ev_base; +} + +short +event_get_events(const struct event *ev) +{ + event_debug_assert_is_setup_(ev); + return ev->ev_events; +} + +event_callback_fn +event_get_callback(const struct event *ev) +{ + event_debug_assert_is_setup_(ev); + return ev->ev_callback; +} + +void * +event_get_callback_arg(const struct event *ev) +{ + event_debug_assert_is_setup_(ev); + return ev->ev_arg; +} + +int +event_get_priority(const struct event *ev) +{ + event_debug_assert_is_setup_(ev); + return ev->ev_pri; +} + +int +event_add(struct event *ev, const struct timeval *tv) +{ + int res; + + if (EVUTIL_FAILURE_CHECK(!ev->ev_base)) { + event_warnx("%s: event has no event_base set.", __func__); + return -1; + } + + EVBASE_ACQUIRE_LOCK(ev->ev_base, th_base_lock); + + res = event_add_nolock_(ev, tv, 0); + + EVBASE_RELEASE_LOCK(ev->ev_base, th_base_lock); + + return (res); +} + +/* Helper callback: wake an event_base from another thread. This version + * works by writing a byte to one end of a socketpair, so that the event_base + * listening on the other end will wake up as the corresponding event + * triggers */ +static int +evthread_notify_base_default(struct event_base *base) +{ + char buf[1]; + int r; + buf[0] = (char) 0; +#ifdef _WIN32 + r = send(base->th_notify_fd[1], buf, 1, 0); +#else + r = write(base->th_notify_fd[1], buf, 1); +#endif + return (r < 0 && ! EVUTIL_ERR_IS_EAGAIN(errno)) ? -1 : 0; +} + +#ifdef EVENT__HAVE_EVENTFD +/* Helper callback: wake an event_base from another thread. This version + * assumes that you have a working eventfd() implementation. */ +static int +evthread_notify_base_eventfd(struct event_base *base) +{ + ev_uint64_t msg = 1; + int r; + do { + r = write(base->th_notify_fd[0], (void*) &msg, sizeof(msg)); + } while (r < 0 && errno == EAGAIN); + + return (r < 0) ? -1 : 0; +} +#endif + + +/** Tell the thread currently running the event_loop for base (if any) that it + * needs to stop waiting in its dispatch function (if it is) and process all + * active callbacks. */ +static int +evthread_notify_base(struct event_base *base) +{ + EVENT_BASE_ASSERT_LOCKED(base); + if (!base->th_notify_fn) + return -1; + if (base->is_notify_pending) + return 0; + base->is_notify_pending = 1; + return base->th_notify_fn(base); +} + +/* Implementation function to remove a timeout on a currently pending event. + */ +int +event_remove_timer_nolock_(struct event *ev) +{ + struct event_base *base = ev->ev_base; + + EVENT_BASE_ASSERT_LOCKED(base); + event_debug_assert_is_setup_(ev); + + event_debug(("event_remove_timer_nolock: event: %p", ev)); + + /* If it's not pending on a timeout, we don't need to do anything. */ + if (ev->ev_flags & EVLIST_TIMEOUT) { + event_queue_remove_timeout(base, ev); + evutil_timerclear(&ev->ev_.ev_io.ev_timeout); + } + + return (0); +} + +int +event_remove_timer(struct event *ev) +{ + int res; + + if (EVUTIL_FAILURE_CHECK(!ev->ev_base)) { + event_warnx("%s: event has no event_base set.", __func__); + return -1; + } + + EVBASE_ACQUIRE_LOCK(ev->ev_base, th_base_lock); + + res = event_remove_timer_nolock_(ev); + + EVBASE_RELEASE_LOCK(ev->ev_base, th_base_lock); + + return (res); +} + +/* Implementation function to add an event. Works just like event_add, + * except: 1) it requires that we have the lock. 2) if tv_is_absolute is set, + * we treat tv as an absolute time, not as an interval to add to the current + * time */ +int +event_add_nolock_(struct event *ev, const struct timeval *tv, + int tv_is_absolute) +{ + struct event_base *base = ev->ev_base; + int res = 0; + int notify = 0; + + EVENT_BASE_ASSERT_LOCKED(base); + event_debug_assert_is_setup_(ev); + + event_debug(( + "event_add: event: %p (fd "EV_SOCK_FMT"), %s%s%s%scall %p", + ev, + EV_SOCK_ARG(ev->ev_fd), + ev->ev_events & EV_READ ? "EV_READ " : " ", + ev->ev_events & EV_WRITE ? "EV_WRITE " : " ", + ev->ev_events & EV_CLOSED ? "EV_CLOSED " : " ", + tv ? "EV_TIMEOUT " : " ", + ev->ev_callback)); + + EVUTIL_ASSERT(!(ev->ev_flags & ~EVLIST_ALL)); + + if (ev->ev_flags & EVLIST_FINALIZING) { + /* XXXX debug */ + return (-1); + } + + /* + * prepare for timeout insertion further below, if we get a + * failure on any step, we should not change any state. + */ + if (tv != NULL && !(ev->ev_flags & EVLIST_TIMEOUT)) { + if (min_heap_reserve_(&base->timeheap, + 1 + min_heap_size_(&base->timeheap)) == -1) + return (-1); /* ENOMEM == errno */ + } + + /* If the main thread is currently executing a signal event's + * callback, and we are not the main thread, then we want to wait + * until the callback is done before we mess with the event, or else + * we can race on ev_ncalls and ev_pncalls below. */ +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (base->current_event == event_to_event_callback(ev) && + (ev->ev_events & EV_SIGNAL) + && !EVBASE_IN_THREAD(base)) { + ++base->current_event_waiters; + EVTHREAD_COND_WAIT(base->current_event_cond, base->th_base_lock); + } +#endif + + if ((ev->ev_events & (EV_READ|EV_WRITE|EV_CLOSED|EV_SIGNAL)) && + !(ev->ev_flags & (EVLIST_INSERTED|EVLIST_ACTIVE|EVLIST_ACTIVE_LATER))) { + if (ev->ev_events & (EV_READ|EV_WRITE|EV_CLOSED)) + res = evmap_io_add_(base, ev->ev_fd, ev); + else if (ev->ev_events & EV_SIGNAL) + res = evmap_signal_add_(base, (int)ev->ev_fd, ev); + if (res != -1) + event_queue_insert_inserted(base, ev); + if (res == 1) { + /* evmap says we need to notify the main thread. */ + notify = 1; + res = 0; + } + } + + /* + * we should change the timeout state only if the previous event + * addition succeeded. + */ + if (res != -1 && tv != NULL) { + struct timeval now; + int common_timeout; +#ifdef USE_REINSERT_TIMEOUT + int was_common; + int old_timeout_idx; +#endif + + /* + * for persistent timeout events, we remember the + * timeout value and re-add the event. + * + * If tv_is_absolute, this was already set. + */ + if (ev->ev_closure == EV_CLOSURE_EVENT_PERSIST && !tv_is_absolute) + ev->ev_io_timeout = *tv; + +#ifndef USE_REINSERT_TIMEOUT + if (ev->ev_flags & EVLIST_TIMEOUT) { + event_queue_remove_timeout(base, ev); + } +#endif + + /* Check if it is active due to a timeout. Rescheduling + * this timeout before the callback can be executed + * removes it from the active list. */ + if ((ev->ev_flags & EVLIST_ACTIVE) && + (ev->ev_res & EV_TIMEOUT)) { + if (ev->ev_events & EV_SIGNAL) { + /* See if we are just active executing + * this event in a loop + */ + if (ev->ev_ncalls && ev->ev_pncalls) { + /* Abort loop */ + *ev->ev_pncalls = 0; + } + } + + event_queue_remove_active(base, event_to_event_callback(ev)); + } + + gettime(base, &now); + + common_timeout = is_common_timeout(tv, base); +#ifdef USE_REINSERT_TIMEOUT + was_common = is_common_timeout(&ev->ev_timeout, base); + old_timeout_idx = COMMON_TIMEOUT_IDX(&ev->ev_timeout); +#endif + + if (tv_is_absolute) { + ev->ev_timeout = *tv; + } else if (common_timeout) { + struct timeval tmp = *tv; + tmp.tv_usec &= MICROSECONDS_MASK; + evutil_timeradd(&now, &tmp, &ev->ev_timeout); + ev->ev_timeout.tv_usec |= + (tv->tv_usec & ~MICROSECONDS_MASK); + } else { + evutil_timeradd(&now, tv, &ev->ev_timeout); + } + + event_debug(( + "event_add: event %p, timeout in %d seconds %d useconds, call %p", + ev, (int)tv->tv_sec, (int)tv->tv_usec, ev->ev_callback)); + +#ifdef USE_REINSERT_TIMEOUT + event_queue_reinsert_timeout(base, ev, was_common, common_timeout, old_timeout_idx); +#else + event_queue_insert_timeout(base, ev); +#endif + + if (common_timeout) { + struct common_timeout_list *ctl = + get_common_timeout_list(base, &ev->ev_timeout); + if (ev == TAILQ_FIRST(&ctl->events)) { + common_timeout_schedule(ctl, &now, ev); + } + } else { + struct event* top = NULL; + /* See if the earliest timeout is now earlier than it + * was before: if so, we will need to tell the main + * thread to wake up earlier than it would otherwise. + * We double check the timeout of the top element to + * handle time distortions due to system suspension. + */ + if (min_heap_elt_is_top_(ev)) + notify = 1; + else if ((top = min_heap_top_(&base->timeheap)) != NULL && + evutil_timercmp(&top->ev_timeout, &now, <)) + notify = 1; + } + } + + /* if we are not in the right thread, we need to wake up the loop */ + if (res != -1 && notify && EVBASE_NEED_NOTIFY(base)) + evthread_notify_base(base); + + event_debug_note_add_(ev); + + return (res); +} + +static int +event_del_(struct event *ev, int blocking) +{ + int res; + + if (EVUTIL_FAILURE_CHECK(!ev->ev_base)) { + event_warnx("%s: event has no event_base set.", __func__); + return -1; + } + + EVBASE_ACQUIRE_LOCK(ev->ev_base, th_base_lock); + + res = event_del_nolock_(ev, blocking); + + EVBASE_RELEASE_LOCK(ev->ev_base, th_base_lock); + + return (res); +} + +int +event_del(struct event *ev) +{ + return event_del_(ev, EVENT_DEL_AUTOBLOCK); +} + +int +event_del_block(struct event *ev) +{ + return event_del_(ev, EVENT_DEL_BLOCK); +} + +int +event_del_noblock(struct event *ev) +{ + return event_del_(ev, EVENT_DEL_NOBLOCK); +} + +/** Helper for event_del: always called with th_base_lock held. + * + * "blocking" must be one of the EVENT_DEL_{BLOCK, NOBLOCK, AUTOBLOCK, + * EVEN_IF_FINALIZING} values. See those for more information. + */ +int +event_del_nolock_(struct event *ev, int blocking) +{ + struct event_base *base; + int res = 0, notify = 0; + + event_debug(("event_del: %p (fd "EV_SOCK_FMT"), callback %p", + ev, EV_SOCK_ARG(ev->ev_fd), ev->ev_callback)); + + /* An event without a base has not been added */ + if (ev->ev_base == NULL) + return (-1); + + EVENT_BASE_ASSERT_LOCKED(ev->ev_base); + + if (blocking != EVENT_DEL_EVEN_IF_FINALIZING) { + if (ev->ev_flags & EVLIST_FINALIZING) { + /* XXXX Debug */ + return 0; + } + } + + /* If the main thread is currently executing this event's callback, + * and we are not the main thread, then we want to wait until the + * callback is done before we start removing the event. That way, + * when this function returns, it will be safe to free the + * user-supplied argument. */ + base = ev->ev_base; +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (blocking != EVENT_DEL_NOBLOCK && + base->current_event == event_to_event_callback(ev) && + !EVBASE_IN_THREAD(base) && + (blocking == EVENT_DEL_BLOCK || !(ev->ev_events & EV_FINALIZE))) { + ++base->current_event_waiters; + EVTHREAD_COND_WAIT(base->current_event_cond, base->th_base_lock); + } +#endif + + EVUTIL_ASSERT(!(ev->ev_flags & ~EVLIST_ALL)); + + /* See if we are just active executing this event in a loop */ + if (ev->ev_events & EV_SIGNAL) { + if (ev->ev_ncalls && ev->ev_pncalls) { + /* Abort loop */ + *ev->ev_pncalls = 0; + } + } + + if (ev->ev_flags & EVLIST_TIMEOUT) { + /* NOTE: We never need to notify the main thread because of a + * deleted timeout event: all that could happen if we don't is + * that the dispatch loop might wake up too early. But the + * point of notifying the main thread _is_ to wake up the + * dispatch loop early anyway, so we wouldn't gain anything by + * doing it. + */ + event_queue_remove_timeout(base, ev); + } + + if (ev->ev_flags & EVLIST_ACTIVE) + event_queue_remove_active(base, event_to_event_callback(ev)); + else if (ev->ev_flags & EVLIST_ACTIVE_LATER) + event_queue_remove_active_later(base, event_to_event_callback(ev)); + + if (ev->ev_flags & EVLIST_INSERTED) { + event_queue_remove_inserted(base, ev); + if (ev->ev_events & (EV_READ|EV_WRITE|EV_CLOSED)) + res = evmap_io_del_(base, ev->ev_fd, ev); + else + res = evmap_signal_del_(base, (int)ev->ev_fd, ev); + if (res == 1) { + /* evmap says we need to notify the main thread. */ + notify = 1; + res = 0; + } + } + + /* if we are not in the right thread, we need to wake up the loop */ + if (res != -1 && notify && EVBASE_NEED_NOTIFY(base)) + evthread_notify_base(base); + + event_debug_note_del_(ev); + + return (res); +} + +void +event_active(struct event *ev, int res, short ncalls) +{ + if (EVUTIL_FAILURE_CHECK(!ev->ev_base)) { + event_warnx("%s: event has no event_base set.", __func__); + return; + } + + EVBASE_ACQUIRE_LOCK(ev->ev_base, th_base_lock); + + event_debug_assert_is_setup_(ev); + + event_active_nolock_(ev, res, ncalls); + + EVBASE_RELEASE_LOCK(ev->ev_base, th_base_lock); +} + + +void +event_active_nolock_(struct event *ev, int res, short ncalls) +{ + struct event_base *base; + + event_debug(("event_active: %p (fd "EV_SOCK_FMT"), res %d, callback %p", + ev, EV_SOCK_ARG(ev->ev_fd), (int)res, ev->ev_callback)); + + base = ev->ev_base; + EVENT_BASE_ASSERT_LOCKED(base); + + if (ev->ev_flags & EVLIST_FINALIZING) { + /* XXXX debug */ + return; + } + + switch ((ev->ev_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER))) { + default: + case EVLIST_ACTIVE|EVLIST_ACTIVE_LATER: + EVUTIL_ASSERT(0); + break; + case EVLIST_ACTIVE: + /* We get different kinds of events, add them together */ + ev->ev_res |= res; + return; + case EVLIST_ACTIVE_LATER: + ev->ev_res |= res; + break; + case 0: + ev->ev_res = res; + break; + } + + if (ev->ev_pri < base->event_running_priority) + base->event_continue = 1; + + if (ev->ev_events & EV_SIGNAL) { +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (base->current_event == event_to_event_callback(ev) && + !EVBASE_IN_THREAD(base)) { + ++base->current_event_waiters; + EVTHREAD_COND_WAIT(base->current_event_cond, base->th_base_lock); + } +#endif + ev->ev_ncalls = ncalls; + ev->ev_pncalls = NULL; + } + + event_callback_activate_nolock_(base, event_to_event_callback(ev)); +} + +void +event_active_later_(struct event *ev, int res) +{ + EVBASE_ACQUIRE_LOCK(ev->ev_base, th_base_lock); + event_active_later_nolock_(ev, res); + EVBASE_RELEASE_LOCK(ev->ev_base, th_base_lock); +} + +void +event_active_later_nolock_(struct event *ev, int res) +{ + struct event_base *base = ev->ev_base; + EVENT_BASE_ASSERT_LOCKED(base); + + if (ev->ev_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER)) { + /* We get different kinds of events, add them together */ + ev->ev_res |= res; + return; + } + + ev->ev_res = res; + + event_callback_activate_later_nolock_(base, event_to_event_callback(ev)); +} + +int +event_callback_activate_(struct event_base *base, + struct event_callback *evcb) +{ + int r; + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + r = event_callback_activate_nolock_(base, evcb); + EVBASE_RELEASE_LOCK(base, th_base_lock); + return r; +} + +int +event_callback_activate_nolock_(struct event_base *base, + struct event_callback *evcb) +{ + int r = 1; + + if (evcb->evcb_flags & EVLIST_FINALIZING) + return 0; + + switch (evcb->evcb_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER)) { + default: + EVUTIL_ASSERT(0); + case EVLIST_ACTIVE_LATER: + event_queue_remove_active_later(base, evcb); + r = 0; + break; + case EVLIST_ACTIVE: + return 0; + case 0: + break; + } + + event_queue_insert_active(base, evcb); + + if (EVBASE_NEED_NOTIFY(base)) + evthread_notify_base(base); + + return r; +} + +void +event_callback_activate_later_nolock_(struct event_base *base, + struct event_callback *evcb) +{ + if (evcb->evcb_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER)) + return; + + event_queue_insert_active_later(base, evcb); + if (EVBASE_NEED_NOTIFY(base)) + evthread_notify_base(base); +} + +void +event_callback_init_(struct event_base *base, + struct event_callback *cb) +{ + memset(cb, 0, sizeof(*cb)); + cb->evcb_pri = base->nactivequeues - 1; +} + +int +event_callback_cancel_(struct event_base *base, + struct event_callback *evcb) +{ + int r; + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + r = event_callback_cancel_nolock_(base, evcb, 0); + EVBASE_RELEASE_LOCK(base, th_base_lock); + return r; +} + +int +event_callback_cancel_nolock_(struct event_base *base, + struct event_callback *evcb, int even_if_finalizing) +{ + if ((evcb->evcb_flags & EVLIST_FINALIZING) && !even_if_finalizing) + return 0; + + if (evcb->evcb_flags & EVLIST_INIT) + return event_del_nolock_(event_callback_to_event(evcb), + even_if_finalizing ? EVENT_DEL_EVEN_IF_FINALIZING : EVENT_DEL_AUTOBLOCK); + + switch ((evcb->evcb_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER))) { + default: + case EVLIST_ACTIVE|EVLIST_ACTIVE_LATER: + EVUTIL_ASSERT(0); + break; + case EVLIST_ACTIVE: + /* We get different kinds of events, add them together */ + event_queue_remove_active(base, evcb); + return 0; + case EVLIST_ACTIVE_LATER: + event_queue_remove_active_later(base, evcb); + break; + case 0: + break; + } + + return 0; +} + +void +event_deferred_cb_init_(struct event_callback *cb, ev_uint8_t priority, deferred_cb_fn fn, void *arg) +{ + memset(cb, 0, sizeof(*cb)); + cb->evcb_cb_union.evcb_selfcb = fn; + cb->evcb_arg = arg; + cb->evcb_pri = priority; + cb->evcb_closure = EV_CLOSURE_CB_SELF; +} + +void +event_deferred_cb_set_priority_(struct event_callback *cb, ev_uint8_t priority) +{ + cb->evcb_pri = priority; +} + +void +event_deferred_cb_cancel_(struct event_base *base, struct event_callback *cb) +{ + if (!base) + base = current_base; + event_callback_cancel_(base, cb); +} + +#define MAX_DEFERREDS_QUEUED 32 +int +event_deferred_cb_schedule_(struct event_base *base, struct event_callback *cb) +{ + int r = 1; + if (!base) + base = current_base; + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + if (base->n_deferreds_queued > MAX_DEFERREDS_QUEUED) { + event_callback_activate_later_nolock_(base, cb); + } else { + ++base->n_deferreds_queued; + r = event_callback_activate_nolock_(base, cb); + } + EVBASE_RELEASE_LOCK(base, th_base_lock); + return r; +} + +static int +timeout_next(struct event_base *base, struct timeval **tv_p) +{ + /* Caller must hold th_base_lock */ + struct timeval now; + struct event *ev; + struct timeval *tv = *tv_p; + int res = 0; + + ev = min_heap_top_(&base->timeheap); + + if (ev == NULL) { + /* if no time-based events are active wait for I/O */ + *tv_p = NULL; + goto out; + } + + if (gettime(base, &now) == -1) { + res = -1; + goto out; + } + + if (evutil_timercmp(&ev->ev_timeout, &now, <=)) { + evutil_timerclear(tv); + goto out; + } + + evutil_timersub(&ev->ev_timeout, &now, tv); + + EVUTIL_ASSERT(tv->tv_sec >= 0); + EVUTIL_ASSERT(tv->tv_usec >= 0); + event_debug(("timeout_next: event: %p, in %d seconds, %d useconds", ev, (int)tv->tv_sec, (int)tv->tv_usec)); + +out: + return (res); +} + +/* Activate every event whose timeout has elapsed. */ +static void +timeout_process(struct event_base *base) +{ + /* Caller must hold lock. */ + struct timeval now; + struct event *ev; + + if (min_heap_empty_(&base->timeheap)) { + return; + } + + gettime(base, &now); + + while ((ev = min_heap_top_(&base->timeheap))) { + if (evutil_timercmp(&ev->ev_timeout, &now, >)) + break; + + /* delete this event from the I/O queues */ + event_del_nolock_(ev, EVENT_DEL_NOBLOCK); + + event_debug(("timeout_process: event: %p, call %p", + ev, ev->ev_callback)); + event_active_nolock_(ev, EV_TIMEOUT, 1); + } +} + +#if (EVLIST_INTERNAL >> 4) != 1 +#error "Mismatch for value of EVLIST_INTERNAL" +#endif + +#ifndef MAX +#define MAX(a,b) (((a)>(b))?(a):(b)) +#endif + +#define MAX_EVENT_COUNT(var, v) var = MAX(var, v) + +/* These are a fancy way to spell + if (flags & EVLIST_INTERNAL) + base->event_count--/++; +*/ +#define DECR_EVENT_COUNT(base,flags) \ + ((base)->event_count -= (~((flags) >> 4) & 1)) +#define INCR_EVENT_COUNT(base,flags) do { \ + ((base)->event_count += (~((flags) >> 4) & 1)); \ + MAX_EVENT_COUNT((base)->event_count_max, (base)->event_count); \ +} while (0) + +static void +event_queue_remove_inserted(struct event_base *base, struct event *ev) +{ + EVENT_BASE_ASSERT_LOCKED(base); + if (EVUTIL_FAILURE_CHECK(!(ev->ev_flags & EVLIST_INSERTED))) { + event_errx(1, "%s: %p(fd "EV_SOCK_FMT") not on queue %x", __func__, + ev, EV_SOCK_ARG(ev->ev_fd), EVLIST_INSERTED); + return; + } + DECR_EVENT_COUNT(base, ev->ev_flags); + ev->ev_flags &= ~EVLIST_INSERTED; +} +static void +event_queue_remove_active(struct event_base *base, struct event_callback *evcb) +{ + EVENT_BASE_ASSERT_LOCKED(base); + if (EVUTIL_FAILURE_CHECK(!(evcb->evcb_flags & EVLIST_ACTIVE))) { + event_errx(1, "%s: %p not on queue %x", __func__, + evcb, EVLIST_ACTIVE); + return; + } + DECR_EVENT_COUNT(base, evcb->evcb_flags); + evcb->evcb_flags &= ~EVLIST_ACTIVE; + base->event_count_active--; + + TAILQ_REMOVE(&base->activequeues[evcb->evcb_pri], + evcb, evcb_active_next); +} +static void +event_queue_remove_active_later(struct event_base *base, struct event_callback *evcb) +{ + EVENT_BASE_ASSERT_LOCKED(base); + if (EVUTIL_FAILURE_CHECK(!(evcb->evcb_flags & EVLIST_ACTIVE_LATER))) { + event_errx(1, "%s: %p not on queue %x", __func__, + evcb, EVLIST_ACTIVE_LATER); + return; + } + DECR_EVENT_COUNT(base, evcb->evcb_flags); + evcb->evcb_flags &= ~EVLIST_ACTIVE_LATER; + base->event_count_active--; + + TAILQ_REMOVE(&base->active_later_queue, evcb, evcb_active_next); +} +static void +event_queue_remove_timeout(struct event_base *base, struct event *ev) +{ + EVENT_BASE_ASSERT_LOCKED(base); + if (EVUTIL_FAILURE_CHECK(!(ev->ev_flags & EVLIST_TIMEOUT))) { + event_errx(1, "%s: %p(fd "EV_SOCK_FMT") not on queue %x", __func__, + ev, EV_SOCK_ARG(ev->ev_fd), EVLIST_TIMEOUT); + return; + } + DECR_EVENT_COUNT(base, ev->ev_flags); + ev->ev_flags &= ~EVLIST_TIMEOUT; + + if (is_common_timeout(&ev->ev_timeout, base)) { + struct common_timeout_list *ctl = + get_common_timeout_list(base, &ev->ev_timeout); + TAILQ_REMOVE(&ctl->events, ev, + ev_timeout_pos.ev_next_with_common_timeout); + } else { + min_heap_erase_(&base->timeheap, ev); + } +} + +#ifdef USE_REINSERT_TIMEOUT +/* Remove and reinsert 'ev' into the timeout queue. */ +static void +event_queue_reinsert_timeout(struct event_base *base, struct event *ev, + int was_common, int is_common, int old_timeout_idx) +{ + struct common_timeout_list *ctl; + if (!(ev->ev_flags & EVLIST_TIMEOUT)) { + event_queue_insert_timeout(base, ev); + return; + } + + switch ((was_common<<1) | is_common) { + case 3: /* Changing from one common timeout to another */ + ctl = base->common_timeout_queues[old_timeout_idx]; + TAILQ_REMOVE(&ctl->events, ev, + ev_timeout_pos.ev_next_with_common_timeout); + ctl = get_common_timeout_list(base, &ev->ev_timeout); + insert_common_timeout_inorder(ctl, ev); + break; + case 2: /* Was common; is no longer common */ + ctl = base->common_timeout_queues[old_timeout_idx]; + TAILQ_REMOVE(&ctl->events, ev, + ev_timeout_pos.ev_next_with_common_timeout); + min_heap_push_(&base->timeheap, ev); + break; + case 1: /* Wasn't common; has become common. */ + min_heap_erase_(&base->timeheap, ev); + ctl = get_common_timeout_list(base, &ev->ev_timeout); + insert_common_timeout_inorder(ctl, ev); + break; + case 0: /* was in heap; is still on heap. */ + min_heap_adjust_(&base->timeheap, ev); + break; + default: + EVUTIL_ASSERT(0); /* unreachable */ + break; + } +} +#endif + +/* Add 'ev' to the common timeout list in 'ev'. */ +static void +insert_common_timeout_inorder(struct common_timeout_list *ctl, + struct event *ev) +{ + struct event *e; + /* By all logic, we should just be able to append 'ev' to the end of + * ctl->events, since the timeout on each 'ev' is set to {the common + * timeout} + {the time when we add the event}, and so the events + * should arrive in order of their timeeouts. But just in case + * there's some wacky threading issue going on, we do a search from + * the end of 'ev' to find the right insertion point. + */ + TAILQ_FOREACH_REVERSE(e, &ctl->events, + event_list, ev_timeout_pos.ev_next_with_common_timeout) { + /* This timercmp is a little sneaky, since both ev and e have + * magic values in tv_usec. Fortunately, they ought to have + * the _same_ magic values in tv_usec. Let's assert for that. + */ + EVUTIL_ASSERT( + is_same_common_timeout(&e->ev_timeout, &ev->ev_timeout)); + if (evutil_timercmp(&ev->ev_timeout, &e->ev_timeout, >=)) { + TAILQ_INSERT_AFTER(&ctl->events, e, ev, + ev_timeout_pos.ev_next_with_common_timeout); + return; + } + } + TAILQ_INSERT_HEAD(&ctl->events, ev, + ev_timeout_pos.ev_next_with_common_timeout); +} + +static void +event_queue_insert_inserted(struct event_base *base, struct event *ev) +{ + EVENT_BASE_ASSERT_LOCKED(base); + + if (EVUTIL_FAILURE_CHECK(ev->ev_flags & EVLIST_INSERTED)) { + event_errx(1, "%s: %p(fd "EV_SOCK_FMT") already inserted", __func__, + ev, EV_SOCK_ARG(ev->ev_fd)); + return; + } + + INCR_EVENT_COUNT(base, ev->ev_flags); + + ev->ev_flags |= EVLIST_INSERTED; +} + +static void +event_queue_insert_active(struct event_base *base, struct event_callback *evcb) +{ + EVENT_BASE_ASSERT_LOCKED(base); + + if (evcb->evcb_flags & EVLIST_ACTIVE) { + /* Double insertion is possible for active events */ + return; + } + + INCR_EVENT_COUNT(base, evcb->evcb_flags); + + evcb->evcb_flags |= EVLIST_ACTIVE; + + base->event_count_active++; + MAX_EVENT_COUNT(base->event_count_active_max, base->event_count_active); + EVUTIL_ASSERT(evcb->evcb_pri < base->nactivequeues); + TAILQ_INSERT_TAIL(&base->activequeues[evcb->evcb_pri], + evcb, evcb_active_next); +} + +static void +event_queue_insert_active_later(struct event_base *base, struct event_callback *evcb) +{ + EVENT_BASE_ASSERT_LOCKED(base); + if (evcb->evcb_flags & (EVLIST_ACTIVE_LATER|EVLIST_ACTIVE)) { + /* Double insertion is possible */ + return; + } + + INCR_EVENT_COUNT(base, evcb->evcb_flags); + evcb->evcb_flags |= EVLIST_ACTIVE_LATER; + base->event_count_active++; + MAX_EVENT_COUNT(base->event_count_active_max, base->event_count_active); + EVUTIL_ASSERT(evcb->evcb_pri < base->nactivequeues); + TAILQ_INSERT_TAIL(&base->active_later_queue, evcb, evcb_active_next); +} + +static void +event_queue_insert_timeout(struct event_base *base, struct event *ev) +{ + EVENT_BASE_ASSERT_LOCKED(base); + + if (EVUTIL_FAILURE_CHECK(ev->ev_flags & EVLIST_TIMEOUT)) { + event_errx(1, "%s: %p(fd "EV_SOCK_FMT") already on timeout", __func__, + ev, EV_SOCK_ARG(ev->ev_fd)); + return; + } + + INCR_EVENT_COUNT(base, ev->ev_flags); + + ev->ev_flags |= EVLIST_TIMEOUT; + + if (is_common_timeout(&ev->ev_timeout, base)) { + struct common_timeout_list *ctl = + get_common_timeout_list(base, &ev->ev_timeout); + insert_common_timeout_inorder(ctl, ev); + } else { + min_heap_push_(&base->timeheap, ev); + } +} + +static void +event_queue_make_later_events_active(struct event_base *base) +{ + struct event_callback *evcb; + EVENT_BASE_ASSERT_LOCKED(base); + + while ((evcb = TAILQ_FIRST(&base->active_later_queue))) { + TAILQ_REMOVE(&base->active_later_queue, evcb, evcb_active_next); + evcb->evcb_flags = (evcb->evcb_flags & ~EVLIST_ACTIVE_LATER) | EVLIST_ACTIVE; + EVUTIL_ASSERT(evcb->evcb_pri < base->nactivequeues); + TAILQ_INSERT_TAIL(&base->activequeues[evcb->evcb_pri], evcb, evcb_active_next); + base->n_deferreds_queued += (evcb->evcb_closure == EV_CLOSURE_CB_SELF); + } +} + +/* Functions for debugging */ + +const char * +event_get_version(void) +{ + return (EVENT__VERSION); +} + +ev_uint32_t +event_get_version_number(void) +{ + return (EVENT__NUMERIC_VERSION); +} + +/* + * No thread-safe interface needed - the information should be the same + * for all threads. + */ + +const char * +event_get_method(void) +{ + return (current_base->evsel->name); +} + +#ifndef EVENT__DISABLE_MM_REPLACEMENT +static void *(*mm_malloc_fn_)(size_t sz) = NULL; +static void *(*mm_realloc_fn_)(void *p, size_t sz) = NULL; +static void (*mm_free_fn_)(void *p) = NULL; + +void * +event_mm_malloc_(size_t sz) +{ + if (sz == 0) + return NULL; + + if (mm_malloc_fn_) + return mm_malloc_fn_(sz); + else + return malloc(sz); +} + +void * +event_mm_calloc_(size_t count, size_t size) +{ + if (count == 0 || size == 0) + return NULL; + + if (mm_malloc_fn_) { + size_t sz = count * size; + void *p = NULL; + if (count > EV_SIZE_MAX / size) + goto error; + p = mm_malloc_fn_(sz); + if (p) + return memset(p, 0, sz); + } else { + void *p = calloc(count, size); +#ifdef _WIN32 + /* Windows calloc doesn't reliably set ENOMEM */ + if (p == NULL) + goto error; +#endif + return p; + } + +error: + errno = ENOMEM; + return NULL; +} + +char * +event_mm_strdup_(const char *str) +{ + if (!str) { + errno = EINVAL; + return NULL; + } + + if (mm_malloc_fn_) { + size_t ln = strlen(str); + void *p = NULL; + if (ln == EV_SIZE_MAX) + goto error; + p = mm_malloc_fn_(ln+1); + if (p) + return memcpy(p, str, ln+1); + } else +#ifdef _WIN32 + return _strdup(str); +#else + return strdup(str); +#endif + +error: + errno = ENOMEM; + return NULL; +} + +void * +event_mm_realloc_(void *ptr, size_t sz) +{ + if (mm_realloc_fn_) + return mm_realloc_fn_(ptr, sz); + else + return realloc(ptr, sz); +} + +void +event_mm_free_(void *ptr) +{ + if (mm_free_fn_) + mm_free_fn_(ptr); + else + free(ptr); +} + +void +event_set_mem_functions(void *(*malloc_fn)(size_t sz), + void *(*realloc_fn)(void *ptr, size_t sz), + void (*free_fn)(void *ptr)) +{ + mm_malloc_fn_ = malloc_fn; + mm_realloc_fn_ = realloc_fn; + mm_free_fn_ = free_fn; +} +#endif + +#ifdef EVENT__HAVE_EVENTFD +static void +evthread_notify_drain_eventfd(evutil_socket_t fd, short what, void *arg) +{ + ev_uint64_t msg; + ev_ssize_t r; + struct event_base *base = arg; + + r = read(fd, (void*) &msg, sizeof(msg)); + if (r<0 && errno != EAGAIN) { + event_sock_warn(fd, "Error reading from eventfd"); + } + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + base->is_notify_pending = 0; + EVBASE_RELEASE_LOCK(base, th_base_lock); +} +#endif + +static void +evthread_notify_drain_default(evutil_socket_t fd, short what, void *arg) +{ + unsigned char buf[1024]; + struct event_base *base = arg; +#ifdef _WIN32 + while (recv(fd, (char*)buf, sizeof(buf), 0) > 0) + ; +#else + while (read(fd, (char*)buf, sizeof(buf)) > 0) + ; +#endif + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + base->is_notify_pending = 0; + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +int +evthread_make_base_notifiable(struct event_base *base) +{ + int r; + if (!base) + return -1; + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + r = evthread_make_base_notifiable_nolock_(base); + EVBASE_RELEASE_LOCK(base, th_base_lock); + return r; +} + +static int +evthread_make_base_notifiable_nolock_(struct event_base *base) +{ + void (*cb)(evutil_socket_t, short, void *); + int (*notify)(struct event_base *); + + if (base->th_notify_fn != NULL) { + /* The base is already notifiable: we're doing fine. */ + return 0; + } + +#if defined(EVENT__HAVE_WORKING_KQUEUE) + if (base->evsel == &kqops && event_kq_add_notify_event_(base) == 0) { + base->th_notify_fn = event_kq_notify_base_; + /* No need to add an event here; the backend can wake + * itself up just fine. */ + return 0; + } +#endif + +#ifdef EVENT__HAVE_EVENTFD + base->th_notify_fd[0] = evutil_eventfd_(0, + EVUTIL_EFD_CLOEXEC|EVUTIL_EFD_NONBLOCK); + if (base->th_notify_fd[0] >= 0) { + base->th_notify_fd[1] = -1; + notify = evthread_notify_base_eventfd; + cb = evthread_notify_drain_eventfd; + } else +#endif + if (evutil_make_internal_pipe_(base->th_notify_fd) == 0) { + notify = evthread_notify_base_default; + cb = evthread_notify_drain_default; + } else { + return -1; + } + + base->th_notify_fn = notify; + + /* prepare an event that we can use for wakeup */ + event_assign(&base->th_notify, base, base->th_notify_fd[0], + EV_READ|EV_PERSIST, cb, base); + + /* we need to mark this as internal event */ + base->th_notify.ev_flags |= EVLIST_INTERNAL; + event_priority_set(&base->th_notify, 0); + + return event_add_nolock_(&base->th_notify, NULL, 0); +} + +int +event_base_foreach_event_nolock_(struct event_base *base, + event_base_foreach_event_cb fn, void *arg) +{ + int r, i; + unsigned u; + struct event *ev; + + /* Start out with all the EVLIST_INSERTED events. */ + if ((r = evmap_foreach_event_(base, fn, arg))) + return r; + + /* Okay, now we deal with those events that have timeouts and are in + * the min-heap. */ + for (u = 0; u < base->timeheap.n; ++u) { + ev = base->timeheap.p[u]; + if (ev->ev_flags & EVLIST_INSERTED) { + /* we already processed this one */ + continue; + } + if ((r = fn(base, ev, arg))) + return r; + } + + /* Now for the events in one of the timeout queues. + * the min-heap. */ + for (i = 0; i < base->n_common_timeouts; ++i) { + struct common_timeout_list *ctl = + base->common_timeout_queues[i]; + TAILQ_FOREACH(ev, &ctl->events, + ev_timeout_pos.ev_next_with_common_timeout) { + if (ev->ev_flags & EVLIST_INSERTED) { + /* we already processed this one */ + continue; + } + if ((r = fn(base, ev, arg))) + return r; + } + } + + /* Finally, we deal wit all the active events that we haven't touched + * yet. */ + for (i = 0; i < base->nactivequeues; ++i) { + struct event_callback *evcb; + TAILQ_FOREACH(evcb, &base->activequeues[i], evcb_active_next) { + if ((evcb->evcb_flags & (EVLIST_INIT|EVLIST_INSERTED|EVLIST_TIMEOUT)) != EVLIST_INIT) { + /* This isn't an event (evlist_init clear), or + * we already processed it. (inserted or + * timeout set */ + continue; + } + ev = event_callback_to_event(evcb); + if ((r = fn(base, ev, arg))) + return r; + } + } + + return 0; +} + +/* Helper for event_base_dump_events: called on each event in the event base; + * dumps only the inserted events. */ +static int +dump_inserted_event_fn(const struct event_base *base, const struct event *e, void *arg) +{ + FILE *output = arg; + const char *gloss = (e->ev_events & EV_SIGNAL) ? + "sig" : "fd "; + + if (! (e->ev_flags & (EVLIST_INSERTED|EVLIST_TIMEOUT))) + return 0; + + fprintf(output, " %p [%s "EV_SOCK_FMT"]%s%s%s%s%s%s", + (void*)e, gloss, EV_SOCK_ARG(e->ev_fd), + (e->ev_events&EV_READ)?" Read":"", + (e->ev_events&EV_WRITE)?" Write":"", + (e->ev_events&EV_CLOSED)?" EOF":"", + (e->ev_events&EV_SIGNAL)?" Signal":"", + (e->ev_events&EV_PERSIST)?" Persist":"", + (e->ev_flags&EVLIST_INTERNAL)?" Internal":""); + if (e->ev_flags & EVLIST_TIMEOUT) { + struct timeval tv; + tv.tv_sec = e->ev_timeout.tv_sec; + tv.tv_usec = e->ev_timeout.tv_usec & MICROSECONDS_MASK; + evutil_timeradd(&tv, &base->tv_clock_diff, &tv); + fprintf(output, " Timeout=%ld.%06d", + (long)tv.tv_sec, (int)(tv.tv_usec & MICROSECONDS_MASK)); + } + fputc('\n', output); + + return 0; +} + +/* Helper for event_base_dump_events: called on each event in the event base; + * dumps only the active events. */ +static int +dump_active_event_fn(const struct event_base *base, const struct event *e, void *arg) +{ + FILE *output = arg; + const char *gloss = (e->ev_events & EV_SIGNAL) ? + "sig" : "fd "; + + if (! (e->ev_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER))) + return 0; + + fprintf(output, " %p [%s "EV_SOCK_FMT", priority=%d]%s%s%s%s%s active%s%s\n", + (void*)e, gloss, EV_SOCK_ARG(e->ev_fd), e->ev_pri, + (e->ev_res&EV_READ)?" Read":"", + (e->ev_res&EV_WRITE)?" Write":"", + (e->ev_res&EV_CLOSED)?" EOF":"", + (e->ev_res&EV_SIGNAL)?" Signal":"", + (e->ev_res&EV_TIMEOUT)?" Timeout":"", + (e->ev_flags&EVLIST_INTERNAL)?" [Internal]":"", + (e->ev_flags&EVLIST_ACTIVE_LATER)?" [NextTime]":""); + + return 0; +} + +int +event_base_foreach_event(struct event_base *base, + event_base_foreach_event_cb fn, void *arg) +{ + int r; + if ((!fn) || (!base)) { + return -1; + } + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + r = event_base_foreach_event_nolock_(base, fn, arg); + EVBASE_RELEASE_LOCK(base, th_base_lock); + return r; +} + + +void +event_base_dump_events(struct event_base *base, FILE *output) +{ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + fprintf(output, "Inserted events:\n"); + event_base_foreach_event_nolock_(base, dump_inserted_event_fn, output); + + fprintf(output, "Active events:\n"); + event_base_foreach_event_nolock_(base, dump_active_event_fn, output); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +void +event_base_active_by_fd(struct event_base *base, evutil_socket_t fd, short events) +{ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + evmap_io_active_(base, fd, events & (EV_READ|EV_WRITE|EV_CLOSED)); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +void +event_base_active_by_signal(struct event_base *base, int sig) +{ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + evmap_signal_active_(base, sig, 1); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + + +void +event_base_add_virtual_(struct event_base *base) +{ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + base->virtual_event_count++; + MAX_EVENT_COUNT(base->virtual_event_count_max, base->virtual_event_count); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +void +event_base_del_virtual_(struct event_base *base) +{ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + EVUTIL_ASSERT(base->virtual_event_count > 0); + base->virtual_event_count--; + if (base->virtual_event_count == 0 && EVBASE_NEED_NOTIFY(base)) + evthread_notify_base(base); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +static void +event_free_debug_globals_locks(void) +{ +#ifndef EVENT__DISABLE_THREAD_SUPPORT +#ifndef EVENT__DISABLE_DEBUG_MODE + if (event_debug_map_lock_ != NULL) { + EVTHREAD_FREE_LOCK(event_debug_map_lock_, 0); + event_debug_map_lock_ = NULL; + evthreadimpl_disable_lock_debugging_(); + } +#endif /* EVENT__DISABLE_DEBUG_MODE */ +#endif /* EVENT__DISABLE_THREAD_SUPPORT */ + return; +} + +static void +event_free_debug_globals(void) +{ + event_free_debug_globals_locks(); +} + +static void +event_free_evsig_globals(void) +{ + evsig_free_globals_(); +} + +static void +event_free_evutil_globals(void) +{ + evutil_free_globals_(); +} + +static void +event_free_globals(void) +{ + event_free_debug_globals(); + event_free_evsig_globals(); + event_free_evutil_globals(); +} + +void +libevent_global_shutdown(void) +{ + event_disable_debug_mode(); + event_free_globals(); +} + +#ifndef EVENT__DISABLE_THREAD_SUPPORT +int +event_global_setup_locks_(const int enable_locks) +{ +#ifndef EVENT__DISABLE_DEBUG_MODE + EVTHREAD_SETUP_GLOBAL_LOCK(event_debug_map_lock_, 0); +#endif + if (evsig_global_setup_locks_(enable_locks) < 0) + return -1; + if (evutil_global_setup_locks_(enable_locks) < 0) + return -1; + if (evutil_secure_rng_global_setup_locks_(enable_locks) < 0) + return -1; + return 0; +} +#endif + +void +event_base_assert_ok_(struct event_base *base) +{ + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + event_base_assert_ok_nolock_(base); + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +void +event_base_assert_ok_nolock_(struct event_base *base) +{ + int i; + int count; + + /* First do checks on the per-fd and per-signal lists */ + evmap_check_integrity_(base); + + /* Check the heap property */ + for (i = 1; i < (int)base->timeheap.n; ++i) { + int parent = (i - 1) / 2; + struct event *ev, *p_ev; + ev = base->timeheap.p[i]; + p_ev = base->timeheap.p[parent]; + EVUTIL_ASSERT(ev->ev_flags & EVLIST_TIMEOUT); + EVUTIL_ASSERT(evutil_timercmp(&p_ev->ev_timeout, &ev->ev_timeout, <=)); + EVUTIL_ASSERT(ev->ev_timeout_pos.min_heap_idx == i); + } + + /* Check that the common timeouts are fine */ + for (i = 0; i < base->n_common_timeouts; ++i) { + struct common_timeout_list *ctl = base->common_timeout_queues[i]; + struct event *last=NULL, *ev; + + EVUTIL_ASSERT_TAILQ_OK(&ctl->events, event, ev_timeout_pos.ev_next_with_common_timeout); + + TAILQ_FOREACH(ev, &ctl->events, ev_timeout_pos.ev_next_with_common_timeout) { + if (last) + EVUTIL_ASSERT(evutil_timercmp(&last->ev_timeout, &ev->ev_timeout, <=)); + EVUTIL_ASSERT(ev->ev_flags & EVLIST_TIMEOUT); + EVUTIL_ASSERT(is_common_timeout(&ev->ev_timeout,base)); + EVUTIL_ASSERT(COMMON_TIMEOUT_IDX(&ev->ev_timeout) == i); + last = ev; + } + } + + /* Check the active queues. */ + count = 0; + for (i = 0; i < base->nactivequeues; ++i) { + struct event_callback *evcb; + EVUTIL_ASSERT_TAILQ_OK(&base->activequeues[i], event_callback, evcb_active_next); + TAILQ_FOREACH(evcb, &base->activequeues[i], evcb_active_next) { + EVUTIL_ASSERT((evcb->evcb_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER)) == EVLIST_ACTIVE); + EVUTIL_ASSERT(evcb->evcb_pri == i); + ++count; + } + } + + { + struct event_callback *evcb; + TAILQ_FOREACH(evcb, &base->active_later_queue, evcb_active_next) { + EVUTIL_ASSERT((evcb->evcb_flags & (EVLIST_ACTIVE|EVLIST_ACTIVE_LATER)) == EVLIST_ACTIVE_LATER); + ++count; + } + } + EVUTIL_ASSERT(count == base->event_count_active); +} diff --git a/contrib/ntp/sntp/libevent/event_iocp.c b/contrib/ntp/sntp/libevent/event_iocp.c new file mode 100644 index 000000000..a9902fbc4 --- /dev/null +++ b/contrib/ntp/sntp/libevent/event_iocp.c @@ -0,0 +1,294 @@ +/* + * Copyright (c) 2009-2012 Niels Provos, Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "evconfig-private.h" + +#ifndef _WIN32_WINNT +/* Minimum required for InitializeCriticalSectionAndSpinCount */ +#define _WIN32_WINNT 0x0403 +#endif +#include +#include +#include +#include +#include + +#include "event2/util.h" +#include "util-internal.h" +#include "iocp-internal.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "event-internal.h" +#include "evthread-internal.h" + +#define NOTIFICATION_KEY ((ULONG_PTR)-1) + +void +event_overlapped_init_(struct event_overlapped *o, iocp_callback cb) +{ + memset(o, 0, sizeof(struct event_overlapped)); + o->cb = cb; +} + +static void +handle_entry(OVERLAPPED *o, ULONG_PTR completion_key, DWORD nBytes, int ok) +{ + struct event_overlapped *eo = + EVUTIL_UPCAST(o, struct event_overlapped, overlapped); + eo->cb(eo, completion_key, nBytes, ok); +} + +static void +loop(void *port_) +{ + struct event_iocp_port *port = port_; + long ms = port->ms; + HANDLE p = port->port; + + if (ms <= 0) + ms = INFINITE; + + while (1) { + OVERLAPPED *overlapped=NULL; + ULONG_PTR key=0; + DWORD bytes=0; + int ok = GetQueuedCompletionStatus(p, &bytes, &key, + &overlapped, ms); + EnterCriticalSection(&port->lock); + if (port->shutdown) { + if (--port->n_live_threads == 0) + ReleaseSemaphore(port->shutdownSemaphore, 1, + NULL); + LeaveCriticalSection(&port->lock); + return; + } + LeaveCriticalSection(&port->lock); + + if (key != NOTIFICATION_KEY && overlapped) + handle_entry(overlapped, key, bytes, ok); + else if (!overlapped) + break; + } + event_warnx("GetQueuedCompletionStatus exited with no event."); + EnterCriticalSection(&port->lock); + if (--port->n_live_threads == 0) + ReleaseSemaphore(port->shutdownSemaphore, 1, NULL); + LeaveCriticalSection(&port->lock); +} + +int +event_iocp_port_associate_(struct event_iocp_port *port, evutil_socket_t fd, + ev_uintptr_t key) +{ + HANDLE h; + h = CreateIoCompletionPort((HANDLE)fd, port->port, key, port->n_threads); + if (!h) + return -1; + return 0; +} + +static void * +get_extension_function(SOCKET s, const GUID *which_fn) +{ + void *ptr = NULL; + DWORD bytes=0; + WSAIoctl(s, SIO_GET_EXTENSION_FUNCTION_POINTER, + (GUID*)which_fn, sizeof(*which_fn), + &ptr, sizeof(ptr), + &bytes, NULL, NULL); + + /* No need to detect errors here: if ptr is set, then we have a good + function pointer. Otherwise, we should behave as if we had no + function pointer. + */ + return ptr; +} + +/* Mingw doesn't have these in its mswsock.h. The values are copied from + wine.h. Perhaps if we copy them exactly, the cargo will come again. +*/ +#ifndef WSAID_ACCEPTEX +#define WSAID_ACCEPTEX \ + {0xb5367df1,0xcbac,0x11cf,{0x95,0xca,0x00,0x80,0x5f,0x48,0xa1,0x92}} +#endif +#ifndef WSAID_CONNECTEX +#define WSAID_CONNECTEX \ + {0x25a207b9,0xddf3,0x4660,{0x8e,0xe9,0x76,0xe5,0x8c,0x74,0x06,0x3e}} +#endif +#ifndef WSAID_GETACCEPTEXSOCKADDRS +#define WSAID_GETACCEPTEXSOCKADDRS \ + {0xb5367df2,0xcbac,0x11cf,{0x95,0xca,0x00,0x80,0x5f,0x48,0xa1,0x92}} +#endif + +static int extension_fns_initialized = 0; + +static void +init_extension_functions(struct win32_extension_fns *ext) +{ + const GUID acceptex = WSAID_ACCEPTEX; + const GUID connectex = WSAID_CONNECTEX; + const GUID getacceptexsockaddrs = WSAID_GETACCEPTEXSOCKADDRS; + SOCKET s = socket(AF_INET, SOCK_STREAM, 0); + if (s == INVALID_SOCKET) + return; + ext->AcceptEx = get_extension_function(s, &acceptex); + ext->ConnectEx = get_extension_function(s, &connectex); + ext->GetAcceptExSockaddrs = get_extension_function(s, + &getacceptexsockaddrs); + closesocket(s); + + extension_fns_initialized = 1; +} + +static struct win32_extension_fns the_extension_fns; + +const struct win32_extension_fns * +event_get_win32_extension_fns_(void) +{ + return &the_extension_fns; +} + +#define N_CPUS_DEFAULT 2 + +struct event_iocp_port * +event_iocp_port_launch_(int n_cpus) +{ + struct event_iocp_port *port; + int i; + + if (!extension_fns_initialized) + init_extension_functions(&the_extension_fns); + + if (!(port = mm_calloc(1, sizeof(struct event_iocp_port)))) + return NULL; + + if (n_cpus <= 0) + n_cpus = N_CPUS_DEFAULT; + port->n_threads = n_cpus * 2; + port->threads = mm_calloc(port->n_threads, sizeof(HANDLE)); + if (!port->threads) + goto err; + + port->port = CreateIoCompletionPort(INVALID_HANDLE_VALUE, NULL, 0, + n_cpus); + port->ms = -1; + if (!port->port) + goto err; + + port->shutdownSemaphore = CreateSemaphore(NULL, 0, 1, NULL); + if (!port->shutdownSemaphore) + goto err; + + for (i=0; in_threads; ++i) { + ev_uintptr_t th = _beginthread(loop, 0, port); + if (th == (ev_uintptr_t)-1) + goto err; + port->threads[i] = (HANDLE)th; + ++port->n_live_threads; + } + + InitializeCriticalSectionAndSpinCount(&port->lock, 1000); + + return port; +err: + if (port->port) + CloseHandle(port->port); + if (port->threads) + mm_free(port->threads); + if (port->shutdownSemaphore) + CloseHandle(port->shutdownSemaphore); + mm_free(port); + return NULL; +} + +static void +event_iocp_port_unlock_and_free_(struct event_iocp_port *port) +{ + DeleteCriticalSection(&port->lock); + CloseHandle(port->port); + CloseHandle(port->shutdownSemaphore); + mm_free(port->threads); + mm_free(port); +} + +static int +event_iocp_notify_all(struct event_iocp_port *port) +{ + int i, r, ok=1; + for (i=0; in_threads; ++i) { + r = PostQueuedCompletionStatus(port->port, 0, NOTIFICATION_KEY, + NULL); + if (!r) + ok = 0; + } + return ok ? 0 : -1; +} + +int +event_iocp_shutdown_(struct event_iocp_port *port, long waitMsec) +{ + DWORD ms = INFINITE; + int n; + + EnterCriticalSection(&port->lock); + port->shutdown = 1; + LeaveCriticalSection(&port->lock); + event_iocp_notify_all(port); + + if (waitMsec >= 0) + ms = waitMsec; + + WaitForSingleObject(port->shutdownSemaphore, ms); + EnterCriticalSection(&port->lock); + n = port->n_live_threads; + LeaveCriticalSection(&port->lock); + if (n == 0) { + event_iocp_port_unlock_and_free_(port); + return 0; + } else { + return -1; + } +} + +int +event_iocp_activate_overlapped_( + struct event_iocp_port *port, struct event_overlapped *o, + ev_uintptr_t key, ev_uint32_t n) +{ + BOOL r; + + r = PostQueuedCompletionStatus(port->port, n, key, &o->overlapped); + return (r==0) ? -1 : 0; +} + +struct event_iocp_port * +event_base_get_iocp_(struct event_base *base) +{ +#ifdef _WIN32 + return base->iocp; +#else + return NULL; +#endif +} diff --git a/contrib/ntp/sntp/libevent/event_rpcgen.py b/contrib/ntp/sntp/libevent/event_rpcgen.py new file mode 100755 index 000000000..c53756569 --- /dev/null +++ b/contrib/ntp/sntp/libevent/event_rpcgen.py @@ -0,0 +1,1728 @@ +#!/usr/bin/env python2 +# +# Copyright (c) 2005-2007 Niels Provos +# Copyright (c) 2007-2012 Niels Provos and Nick Mathewson +# All rights reserved. +# +# Generates marshaling code based on libevent. + +# TODO: +# 1) use optparse to allow the strategy shell to parse options, and +# to allow the instantiated factory (for the specific output language) +# to parse remaining options +# 2) move the globals into a class that manages execution (including the +# progress outputs that space stderr at the moment) +# 3) emit other languages + +import sys +import re + +_NAME = "event_rpcgen.py" +_VERSION = "0.1" + +# Globals +line_count = 0 + +white = re.compile(r'\s+') +cppcomment = re.compile(r'\/\/.*$') +nonident = re.compile(r'[^a-zA-Z0-9_]') +structref = re.compile(r'^struct\[([a-zA-Z_][a-zA-Z0-9_]*)\]$') +structdef = re.compile(r'^struct +[a-zA-Z_][a-zA-Z0-9_]* *{$') + +headerdirect = [] +cppdirect = [] + +QUIETLY = 0 + +def declare(s): + if not QUIETLY: + print s + +def TranslateList(mylist, mydict): + return map(lambda x: x % mydict, mylist) + +# Exception class for parse errors +class RpcGenError(Exception): + def __init__(self, why): + self.why = why + def __str__(self): + return str(self.why) + +# Holds everything that makes a struct +class Struct: + def __init__(self, name): + self._name = name + self._entries = [] + self._tags = {} + declare(' Created struct: %s' % name) + + def AddEntry(self, entry): + if self._tags.has_key(entry.Tag()): + raise RpcGenError( + 'Entry "%s" duplicates tag number %d from "%s" ' + 'around line %d' % (entry.Name(), entry.Tag(), + self._tags[entry.Tag()], line_count)) + self._entries.append(entry) + self._tags[entry.Tag()] = entry.Name() + declare(' Added entry: %s' % entry.Name()) + + def Name(self): + return self._name + + def EntryTagName(self, entry): + """Creates the name inside an enumeration for distinguishing data + types.""" + name = "%s_%s" % (self._name, entry.Name()) + return name.upper() + + def PrintIndented(self, file, ident, code): + """Takes an array, add indentation to each entry and prints it.""" + for entry in code: + print >>file, '%s%s' % (ident, entry) + +class StructCCode(Struct): + """ Knows how to generate C code for a struct """ + + def __init__(self, name): + Struct.__init__(self, name) + + def PrintTags(self, file): + """Prints the tag definitions for a structure.""" + print >>file, '/* Tag definition for %s */' % self._name + print >>file, 'enum %s_ {' % self._name.lower() + for entry in self._entries: + print >>file, ' %s=%d,' % (self.EntryTagName(entry), + entry.Tag()) + print >>file, ' %s_MAX_TAGS' % (self._name.upper()) + print >>file, '};\n' + + def PrintForwardDeclaration(self, file): + print >>file, 'struct %s;' % self._name + + def PrintDeclaration(self, file): + print >>file, '/* Structure declaration for %s */' % self._name + print >>file, 'struct %s_access_ {' % self._name + for entry in self._entries: + dcl = entry.AssignDeclaration('(*%s_assign)' % entry.Name()) + dcl.extend( + entry.GetDeclaration('(*%s_get)' % entry.Name())) + if entry.Array(): + dcl.extend( + entry.AddDeclaration('(*%s_add)' % entry.Name())) + self.PrintIndented(file, ' ', dcl) + print >>file, '};\n' + + print >>file, 'struct %s {' % self._name + print >>file, ' struct %s_access_ *base;\n' % self._name + for entry in self._entries: + dcl = entry.Declaration() + self.PrintIndented(file, ' ', dcl) + print >>file, '' + for entry in self._entries: + print >>file, ' ev_uint8_t %s_set;' % entry.Name() + print >>file, '};\n' + + print >>file, \ +"""struct %(name)s *%(name)s_new(void); +struct %(name)s *%(name)s_new_with_arg(void *); +void %(name)s_free(struct %(name)s *); +void %(name)s_clear(struct %(name)s *); +void %(name)s_marshal(struct evbuffer *, const struct %(name)s *); +int %(name)s_unmarshal(struct %(name)s *, struct evbuffer *); +int %(name)s_complete(struct %(name)s *); +void evtag_marshal_%(name)s(struct evbuffer *, ev_uint32_t, + const struct %(name)s *); +int evtag_unmarshal_%(name)s(struct evbuffer *, ev_uint32_t, + struct %(name)s *);""" % { 'name' : self._name } + + + # Write a setting function of every variable + for entry in self._entries: + self.PrintIndented(file, '', entry.AssignDeclaration( + entry.AssignFuncName())) + self.PrintIndented(file, '', entry.GetDeclaration( + entry.GetFuncName())) + if entry.Array(): + self.PrintIndented(file, '', entry.AddDeclaration( + entry.AddFuncName())) + + print >>file, '/* --- %s done --- */\n' % self._name + + def PrintCode(self, file): + print >>file, ('/*\n' + ' * Implementation of %s\n' + ' */\n') % self._name + + print >>file, \ + 'static struct %(name)s_access_ %(name)s_base__ = {' % \ + { 'name' : self._name } + for entry in self._entries: + self.PrintIndented(file, ' ', entry.CodeBase()) + print >>file, '};\n' + + # Creation + print >>file, ( + 'struct %(name)s *\n' + '%(name)s_new(void)\n' + '{\n' + ' return %(name)s_new_with_arg(NULL);\n' + '}\n' + '\n' + 'struct %(name)s *\n' + '%(name)s_new_with_arg(void *unused)\n' + '{\n' + ' struct %(name)s *tmp;\n' + ' if ((tmp = malloc(sizeof(struct %(name)s))) == NULL) {\n' + ' event_warn("%%s: malloc", __func__);\n' + ' return (NULL);\n' + ' }\n' + ' tmp->base = &%(name)s_base__;\n') % { 'name' : self._name } + + for entry in self._entries: + self.PrintIndented(file, ' ', entry.CodeInitialize('tmp')) + print >>file, ' tmp->%s_set = 0;\n' % entry.Name() + + print >>file, ( + ' return (tmp);\n' + '}\n') + + # Adding + for entry in self._entries: + if entry.Array(): + self.PrintIndented(file, '', entry.CodeAdd()) + print >>file, '' + + # Assigning + for entry in self._entries: + self.PrintIndented(file, '', entry.CodeAssign()) + print >>file, '' + + # Getting + for entry in self._entries: + self.PrintIndented(file, '', entry.CodeGet()) + print >>file, '' + + # Clearing + print >>file, ( 'void\n' + '%(name)s_clear(struct %(name)s *tmp)\n' + '{' + ) % { 'name' : self._name } + for entry in self._entries: + self.PrintIndented(file, ' ', entry.CodeClear('tmp')) + + print >>file, '}\n' + + # Freeing + print >>file, ( 'void\n' + '%(name)s_free(struct %(name)s *tmp)\n' + '{' + ) % { 'name' : self._name } + + for entry in self._entries: + self.PrintIndented(file, ' ', entry.CodeFree('tmp')) + + print >>file, (' free(tmp);\n' + '}\n') + + # Marshaling + print >>file, ('void\n' + '%(name)s_marshal(struct evbuffer *evbuf, ' + 'const struct %(name)s *tmp)' + '{') % { 'name' : self._name } + for entry in self._entries: + indent = ' ' + # Optional entries do not have to be set + if entry.Optional(): + indent += ' ' + print >>file, ' if (tmp->%s_set) {' % entry.Name() + self.PrintIndented( + file, indent, + entry.CodeMarshal('evbuf', self.EntryTagName(entry), + entry.GetVarName('tmp'), + entry.GetVarLen('tmp'))) + if entry.Optional(): + print >>file, ' }' + + print >>file, '}\n' + + # Unmarshaling + print >>file, ('int\n' + '%(name)s_unmarshal(struct %(name)s *tmp, ' + ' struct evbuffer *evbuf)\n' + '{\n' + ' ev_uint32_t tag;\n' + ' while (evbuffer_get_length(evbuf) > 0) {\n' + ' if (evtag_peek(evbuf, &tag) == -1)\n' + ' return (-1);\n' + ' switch (tag) {\n' + ) % { 'name' : self._name } + for entry in self._entries: + print >>file, ' case %s:\n' % self.EntryTagName(entry) + if not entry.Array(): + print >>file, ( + ' if (tmp->%s_set)\n' + ' return (-1);' + ) % (entry.Name()) + + self.PrintIndented( + file, ' ', + entry.CodeUnmarshal('evbuf', + self.EntryTagName(entry), + entry.GetVarName('tmp'), + entry.GetVarLen('tmp'))) + + print >>file, ( ' tmp->%s_set = 1;\n' % entry.Name() + + ' break;\n' ) + print >>file, ( ' default:\n' + ' return -1;\n' + ' }\n' + ' }\n' ) + # Check if it was decoded completely + print >>file, ( ' if (%(name)s_complete(tmp) == -1)\n' + ' return (-1);' + ) % { 'name' : self._name } + + # Successfully decoded + print >>file, ( ' return (0);\n' + '}\n') + + # Checking if a structure has all the required data + print >>file, ( + 'int\n' + '%(name)s_complete(struct %(name)s *msg)\n' + '{' ) % { 'name' : self._name } + for entry in self._entries: + if not entry.Optional(): + code = [ + 'if (!msg->%(name)s_set)', + ' return (-1);' ] + code = TranslateList(code, entry.GetTranslation()) + self.PrintIndented( + file, ' ', code) + + self.PrintIndented( + file, ' ', + entry.CodeComplete('msg', entry.GetVarName('msg'))) + print >>file, ( + ' return (0);\n' + '}\n' ) + + # Complete message unmarshaling + print >>file, ( + 'int\n' + 'evtag_unmarshal_%(name)s(struct evbuffer *evbuf, ' + 'ev_uint32_t need_tag, struct %(name)s *msg)\n' + '{\n' + ' ev_uint32_t tag;\n' + ' int res = -1;\n' + '\n' + ' struct evbuffer *tmp = evbuffer_new();\n' + '\n' + ' if (evtag_unmarshal(evbuf, &tag, tmp) == -1' + ' || tag != need_tag)\n' + ' goto error;\n' + '\n' + ' if (%(name)s_unmarshal(msg, tmp) == -1)\n' + ' goto error;\n' + '\n' + ' res = 0;\n' + '\n' + ' error:\n' + ' evbuffer_free(tmp);\n' + ' return (res);\n' + '}\n' ) % { 'name' : self._name } + + # Complete message marshaling + print >>file, ( + 'void\n' + 'evtag_marshal_%(name)s(struct evbuffer *evbuf, ev_uint32_t tag, ' + 'const struct %(name)s *msg)\n' + '{\n' + ' struct evbuffer *buf_ = evbuffer_new();\n' + ' assert(buf_ != NULL);\n' + ' %(name)s_marshal(buf_, msg);\n' + ' evtag_marshal_buffer(evbuf, tag, buf_);\n ' + ' evbuffer_free(buf_);\n' + '}\n' ) % { 'name' : self._name } + +class Entry: + def __init__(self, type, name, tag): + self._type = type + self._name = name + self._tag = int(tag) + self._ctype = type + self._optional = 0 + self._can_be_array = 0 + self._array = 0 + self._line_count = -1 + self._struct = None + self._refname = None + + self._optpointer = True + self._optaddarg = True + + def GetInitializer(self): + assert 0, "Entry does not provide initializer" + + def SetStruct(self, struct): + self._struct = struct + + def LineCount(self): + assert self._line_count != -1 + return self._line_count + + def SetLineCount(self, number): + self._line_count = number + + def Array(self): + return self._array + + def Optional(self): + return self._optional + + def Tag(self): + return self._tag + + def Name(self): + return self._name + + def Type(self): + return self._type + + def MakeArray(self, yes=1): + self._array = yes + + def MakeOptional(self): + self._optional = 1 + + def Verify(self): + if self.Array() and not self._can_be_array: + raise RpcGenError( + 'Entry "%s" cannot be created as an array ' + 'around line %d' % (self._name, self.LineCount())) + if not self._struct: + raise RpcGenError( + 'Entry "%s" does not know which struct it belongs to ' + 'around line %d' % (self._name, self.LineCount())) + if self._optional and self._array: + raise RpcGenError( + 'Entry "%s" has illegal combination of optional and array ' + 'around line %d' % (self._name, self.LineCount())) + + def GetTranslation(self, extradict = {}): + mapping = { + "parent_name" : self._struct.Name(), + "name" : self._name, + "ctype" : self._ctype, + "refname" : self._refname, + "optpointer" : self._optpointer and "*" or "", + "optreference" : self._optpointer and "&" or "", + "optaddarg" : + self._optaddarg and ", const %s value" % self._ctype or "" + } + for (k, v) in extradict.items(): + mapping[k] = v + + return mapping + + def GetVarName(self, var): + return '%(var)s->%(name)s_data' % self.GetTranslation({ 'var' : var }) + + def GetVarLen(self, var): + return 'sizeof(%s)' % self._ctype + + def GetFuncName(self): + return '%s_%s_get' % (self._struct.Name(), self._name) + + def GetDeclaration(self, funcname): + code = [ 'int %s(struct %s *, %s *);' % ( + funcname, self._struct.Name(), self._ctype ) ] + return code + + def CodeGet(self): + code = ( + 'int', + '%(parent_name)s_%(name)s_get(struct %(parent_name)s *msg, ' + '%(ctype)s *value)', + '{', + ' if (msg->%(name)s_set != 1)', + ' return (-1);', + ' *value = msg->%(name)s_data;', + ' return (0);', + '}' ) + code = '\n'.join(code) + code = code % self.GetTranslation() + return code.split('\n') + + def AssignFuncName(self): + return '%s_%s_assign' % (self._struct.Name(), self._name) + + def AddFuncName(self): + return '%s_%s_add' % (self._struct.Name(), self._name) + + def AssignDeclaration(self, funcname): + code = [ 'int %s(struct %s *, const %s);' % ( + funcname, self._struct.Name(), self._ctype ) ] + return code + + def CodeAssign(self): + code = [ 'int', + '%(parent_name)s_%(name)s_assign(struct %(parent_name)s *msg,' + ' const %(ctype)s value)', + '{', + ' msg->%(name)s_set = 1;', + ' msg->%(name)s_data = value;', + ' return (0);', + '}' ] + code = '\n'.join(code) + code = code % self.GetTranslation() + return code.split('\n') + + def CodeClear(self, structname): + code = [ '%s->%s_set = 0;' % (structname, self.Name()) ] + + return code + + def CodeComplete(self, structname, var_name): + return [] + + def CodeFree(self, name): + return [] + + def CodeBase(self): + code = [ + '%(parent_name)s_%(name)s_assign,', + '%(parent_name)s_%(name)s_get,' + ] + if self.Array(): + code.append('%(parent_name)s_%(name)s_add,') + + code = '\n'.join(code) + code = code % self.GetTranslation() + return code.split('\n') + +class EntryBytes(Entry): + def __init__(self, type, name, tag, length): + # Init base class + Entry.__init__(self, type, name, tag) + + self._length = length + self._ctype = 'ev_uint8_t' + + def GetInitializer(self): + return "NULL" + + def GetVarLen(self, var): + return '(%s)' % self._length + + def CodeArrayAdd(self, varname, value): + # XXX: copy here + return [ '%(varname)s = NULL;' % { 'varname' : varname } ] + + def GetDeclaration(self, funcname): + code = [ 'int %s(struct %s *, %s **);' % ( + funcname, self._struct.Name(), self._ctype ) ] + return code + + def AssignDeclaration(self, funcname): + code = [ 'int %s(struct %s *, const %s *);' % ( + funcname, self._struct.Name(), self._ctype ) ] + return code + + def Declaration(self): + dcl = ['ev_uint8_t %s_data[%s];' % (self._name, self._length)] + + return dcl + + def CodeGet(self): + name = self._name + code = [ 'int', + '%s_%s_get(struct %s *msg, %s **value)' % ( + self._struct.Name(), name, + self._struct.Name(), self._ctype), + '{', + ' if (msg->%s_set != 1)' % name, + ' return (-1);', + ' *value = msg->%s_data;' % name, + ' return (0);', + '}' ] + return code + + def CodeAssign(self): + name = self._name + code = [ 'int', + '%s_%s_assign(struct %s *msg, const %s *value)' % ( + self._struct.Name(), name, + self._struct.Name(), self._ctype), + '{', + ' msg->%s_set = 1;' % name, + ' memcpy(msg->%s_data, value, %s);' % ( + name, self._length), + ' return (0);', + '}' ] + return code + + def CodeUnmarshal(self, buf, tag_name, var_name, var_len): + code = [ 'if (evtag_unmarshal_fixed(%(buf)s, %(tag)s, ' + '%(var)s, %(varlen)s) == -1) {', + ' event_warnx("%%s: failed to unmarshal %(name)s", __func__);', + ' return (-1);', + '}' + ] + return TranslateList(code, + self.GetTranslation({ + 'var' : var_name, + 'varlen' : var_len, + 'buf' : buf, + 'tag' : tag_name })) + + def CodeMarshal(self, buf, tag_name, var_name, var_len): + code = ['evtag_marshal(%s, %s, %s, %s);' % ( + buf, tag_name, var_name, var_len)] + return code + + def CodeClear(self, structname): + code = [ '%s->%s_set = 0;' % (structname, self.Name()), + 'memset(%s->%s_data, 0, sizeof(%s->%s_data));' % ( + structname, self._name, structname, self._name)] + + return code + + def CodeInitialize(self, name): + code = ['memset(%s->%s_data, 0, sizeof(%s->%s_data));' % ( + name, self._name, name, self._name)] + return code + + def Verify(self): + if not self._length: + raise RpcGenError( + 'Entry "%s" needs a length ' + 'around line %d' % (self._name, self.LineCount())) + + Entry.Verify(self) + +class EntryInt(Entry): + def __init__(self, type, name, tag, bits=32): + # Init base class + Entry.__init__(self, type, name, tag) + + self._can_be_array = 1 + if bits == 32: + self._ctype = 'ev_uint32_t' + self._marshal_type = 'int' + if bits == 64: + self._ctype = 'ev_uint64_t' + self._marshal_type = 'int64' + + def GetInitializer(self): + return "0" + + def CodeArrayFree(self, var): + return [] + + def CodeArrayAssign(self, varname, srcvar): + return [ '%(varname)s = %(srcvar)s;' % { 'varname' : varname, + 'srcvar' : srcvar } ] + + def CodeArrayAdd(self, varname, value): + """Returns a new entry of this type.""" + return [ '%(varname)s = %(value)s;' % { 'varname' : varname, + 'value' : value } ] + + def CodeUnmarshal(self, buf, tag_name, var_name, var_len): + code = [ + 'if (evtag_unmarshal_%(ma)s(%(buf)s, %(tag)s, &%(var)s) == -1) {', + ' event_warnx("%%s: failed to unmarshal %(name)s", __func__);', + ' return (-1);', + '}' ] + code = '\n'.join(code) % self.GetTranslation({ + 'ma' : self._marshal_type, + 'buf' : buf, + 'tag' : tag_name, + 'var' : var_name }) + return code.split('\n') + + def CodeMarshal(self, buf, tag_name, var_name, var_len): + code = [ + 'evtag_marshal_%s(%s, %s, %s);' % ( + self._marshal_type, buf, tag_name, var_name)] + return code + + def Declaration(self): + dcl = ['%s %s_data;' % (self._ctype, self._name)] + + return dcl + + def CodeInitialize(self, name): + code = ['%s->%s_data = 0;' % (name, self._name)] + return code + +class EntryString(Entry): + def __init__(self, type, name, tag): + # Init base class + Entry.__init__(self, type, name, tag) + + self._can_be_array = 1 + self._ctype = 'char *' + + def GetInitializer(self): + return "NULL" + + def CodeArrayFree(self, varname): + code = [ + 'if (%(var)s != NULL) free(%(var)s);' ] + + return TranslateList(code, { 'var' : varname }) + + def CodeArrayAssign(self, varname, srcvar): + code = [ + 'if (%(var)s != NULL)', + ' free(%(var)s);', + '%(var)s = strdup(%(srcvar)s);', + 'if (%(var)s == NULL) {', + ' event_warnx("%%s: strdup", __func__);', + ' return (-1);', + '}' ] + + return TranslateList(code, { 'var' : varname, + 'srcvar' : srcvar }) + + def CodeArrayAdd(self, varname, value): + code = [ + 'if (%(value)s != NULL) {', + ' %(var)s = strdup(%(value)s);', + ' if (%(var)s == NULL) {', + ' goto error;', + ' }', + '} else {', + ' %(var)s = NULL;', + '}' ] + + return TranslateList(code, { 'var' : varname, + 'value' : value }) + + def GetVarLen(self, var): + return 'strlen(%s)' % self.GetVarName(var) + + def CodeMakeInitalize(self, varname): + return '%(varname)s = NULL;' % { 'varname' : varname } + + def CodeAssign(self): + name = self._name + code = """int +%(parent_name)s_%(name)s_assign(struct %(parent_name)s *msg, + const %(ctype)s value) +{ + if (msg->%(name)s_data != NULL) + free(msg->%(name)s_data); + if ((msg->%(name)s_data = strdup(value)) == NULL) + return (-1); + msg->%(name)s_set = 1; + return (0); +}""" % self.GetTranslation() + + return code.split('\n') + + def CodeUnmarshal(self, buf, tag_name, var_name, var_len): + code = ['if (evtag_unmarshal_string(%(buf)s, %(tag)s, &%(var)s) == -1) {', + ' event_warnx("%%s: failed to unmarshal %(name)s", __func__);', + ' return (-1);', + '}' + ] + code = '\n'.join(code) % self.GetTranslation({ + 'buf' : buf, + 'tag' : tag_name, + 'var' : var_name }) + return code.split('\n') + + def CodeMarshal(self, buf, tag_name, var_name, var_len): + code = ['evtag_marshal_string(%s, %s, %s);' % ( + buf, tag_name, var_name)] + return code + + def CodeClear(self, structname): + code = [ 'if (%s->%s_set == 1) {' % (structname, self.Name()), + ' free(%s->%s_data);' % (structname, self.Name()), + ' %s->%s_data = NULL;' % (structname, self.Name()), + ' %s->%s_set = 0;' % (structname, self.Name()), + '}' + ] + + return code + + def CodeInitialize(self, name): + code = ['%s->%s_data = NULL;' % (name, self._name)] + return code + + def CodeFree(self, name): + code = ['if (%s->%s_data != NULL)' % (name, self._name), + ' free (%s->%s_data);' % (name, self._name)] + + return code + + def Declaration(self): + dcl = ['char *%s_data;' % self._name] + + return dcl + +class EntryStruct(Entry): + def __init__(self, type, name, tag, refname): + # Init base class + Entry.__init__(self, type, name, tag) + + self._optpointer = False + self._can_be_array = 1 + self._refname = refname + self._ctype = 'struct %s*' % refname + self._optaddarg = False + + def GetInitializer(self): + return "NULL" + + def GetVarLen(self, var): + return '-1' + + def CodeArrayAdd(self, varname, value): + code = [ + '%(varname)s = %(refname)s_new();', + 'if (%(varname)s == NULL)', + ' goto error;' ] + + return TranslateList(code, self.GetTranslation({ 'varname' : varname })) + + def CodeArrayFree(self, var): + code = [ '%(refname)s_free(%(var)s);' % self.GetTranslation( + { 'var' : var }) ] + return code + + def CodeArrayAssign(self, var, srcvar): + code = [ + 'int had_error = 0;', + 'struct evbuffer *tmp = NULL;', + '%(refname)s_clear(%(var)s);', + 'if ((tmp = evbuffer_new()) == NULL) {', + ' event_warn("%%s: evbuffer_new()", __func__);', + ' had_error = 1;', + ' goto done;', + '}', + '%(refname)s_marshal(tmp, %(srcvar)s);', + 'if (%(refname)s_unmarshal(%(var)s, tmp) == -1) {', + ' event_warnx("%%s: %(refname)s_unmarshal", __func__);', + ' had_error = 1;', + ' goto done;', + '}', + 'done:' + 'if (tmp != NULL)', + ' evbuffer_free(tmp);', + 'if (had_error) {', + ' %(refname)s_clear(%(var)s);', + ' return (-1);', + '}' ] + + return TranslateList(code, self.GetTranslation({ + 'var' : var, + 'srcvar' : srcvar})) + + def CodeGet(self): + name = self._name + code = [ 'int', + '%s_%s_get(struct %s *msg, %s *value)' % ( + self._struct.Name(), name, + self._struct.Name(), self._ctype), + '{', + ' if (msg->%s_set != 1) {' % name, + ' msg->%s_data = %s_new();' % (name, self._refname), + ' if (msg->%s_data == NULL)' % name, + ' return (-1);', + ' msg->%s_set = 1;' % name, + ' }', + ' *value = msg->%s_data;' % name, + ' return (0);', + '}' ] + return code + + def CodeAssign(self): + name = self._name + code = """int +%(parent_name)s_%(name)s_assign(struct %(parent_name)s *msg, + const %(ctype)s value) +{ + struct evbuffer *tmp = NULL; + if (msg->%(name)s_set) { + %(refname)s_clear(msg->%(name)s_data); + msg->%(name)s_set = 0; + } else { + msg->%(name)s_data = %(refname)s_new(); + if (msg->%(name)s_data == NULL) { + event_warn("%%s: %(refname)s_new()", __func__); + goto error; + } + } + if ((tmp = evbuffer_new()) == NULL) { + event_warn("%%s: evbuffer_new()", __func__); + goto error; + } + %(refname)s_marshal(tmp, value); + if (%(refname)s_unmarshal(msg->%(name)s_data, tmp) == -1) { + event_warnx("%%s: %(refname)s_unmarshal", __func__); + goto error; + } + msg->%(name)s_set = 1; + evbuffer_free(tmp); + return (0); + error: + if (tmp != NULL) + evbuffer_free(tmp); + if (msg->%(name)s_data != NULL) { + %(refname)s_free(msg->%(name)s_data); + msg->%(name)s_data = NULL; + } + return (-1); +}""" % self.GetTranslation() + return code.split('\n') + + def CodeComplete(self, structname, var_name): + code = [ 'if (%(structname)s->%(name)s_set && ' + '%(refname)s_complete(%(var)s) == -1)', + ' return (-1);' ] + + return TranslateList(code, self.GetTranslation({ + 'structname' : structname, + 'var' : var_name })) + + def CodeUnmarshal(self, buf, tag_name, var_name, var_len): + code = ['%(var)s = %(refname)s_new();', + 'if (%(var)s == NULL)', + ' return (-1);', + 'if (evtag_unmarshal_%(refname)s(%(buf)s, %(tag)s, ' + '%(var)s) == -1) {', + ' event_warnx("%%s: failed to unmarshal %(name)s", __func__);', + ' return (-1);', + '}' + ] + code = '\n'.join(code) % self.GetTranslation({ + 'buf' : buf, + 'tag' : tag_name, + 'var' : var_name }) + return code.split('\n') + + def CodeMarshal(self, buf, tag_name, var_name, var_len): + code = ['evtag_marshal_%s(%s, %s, %s);' % ( + self._refname, buf, tag_name, var_name)] + return code + + def CodeClear(self, structname): + code = [ 'if (%s->%s_set == 1) {' % (structname, self.Name()), + ' %s_free(%s->%s_data);' % ( + self._refname, structname, self.Name()), + ' %s->%s_data = NULL;' % (structname, self.Name()), + ' %s->%s_set = 0;' % (structname, self.Name()), + '}' + ] + + return code + + def CodeInitialize(self, name): + code = ['%s->%s_data = NULL;' % (name, self._name)] + return code + + def CodeFree(self, name): + code = ['if (%s->%s_data != NULL)' % (name, self._name), + ' %s_free(%s->%s_data);' % ( + self._refname, name, self._name)] + + return code + + def Declaration(self): + dcl = ['%s %s_data;' % (self._ctype, self._name)] + + return dcl + +class EntryVarBytes(Entry): + def __init__(self, type, name, tag): + # Init base class + Entry.__init__(self, type, name, tag) + + self._ctype = 'ev_uint8_t *' + + def GetInitializer(self): + return "NULL" + + def GetVarLen(self, var): + return '%(var)s->%(name)s_length' % self.GetTranslation({ 'var' : var }) + + def CodeArrayAdd(self, varname, value): + # xxx: copy + return [ '%(varname)s = NULL;' % { 'varname' : varname } ] + + def GetDeclaration(self, funcname): + code = [ 'int %s(struct %s *, %s *, ev_uint32_t *);' % ( + funcname, self._struct.Name(), self._ctype ) ] + return code + + def AssignDeclaration(self, funcname): + code = [ 'int %s(struct %s *, const %s, ev_uint32_t);' % ( + funcname, self._struct.Name(), self._ctype ) ] + return code + + def CodeAssign(self): + name = self._name + code = [ 'int', + '%s_%s_assign(struct %s *msg, ' + 'const %s value, ev_uint32_t len)' % ( + self._struct.Name(), name, + self._struct.Name(), self._ctype), + '{', + ' if (msg->%s_data != NULL)' % name, + ' free (msg->%s_data);' % name, + ' msg->%s_data = malloc(len);' % name, + ' if (msg->%s_data == NULL)' % name, + ' return (-1);', + ' msg->%s_set = 1;' % name, + ' msg->%s_length = len;' % name, + ' memcpy(msg->%s_data, value, len);' % name, + ' return (0);', + '}' ] + return code + + def CodeGet(self): + name = self._name + code = [ 'int', + '%s_%s_get(struct %s *msg, %s *value, ev_uint32_t *plen)' % ( + self._struct.Name(), name, + self._struct.Name(), self._ctype), + '{', + ' if (msg->%s_set != 1)' % name, + ' return (-1);', + ' *value = msg->%s_data;' % name, + ' *plen = msg->%s_length;' % name, + ' return (0);', + '}' ] + return code + + def CodeUnmarshal(self, buf, tag_name, var_name, var_len): + code = ['if (evtag_payload_length(%(buf)s, &%(varlen)s) == -1)', + ' return (-1);', + # We do not want DoS opportunities + 'if (%(varlen)s > evbuffer_get_length(%(buf)s))', + ' return (-1);', + 'if ((%(var)s = malloc(%(varlen)s)) == NULL)', + ' return (-1);', + 'if (evtag_unmarshal_fixed(%(buf)s, %(tag)s, %(var)s, ' + '%(varlen)s) == -1) {', + ' event_warnx("%%s: failed to unmarshal %(name)s", __func__);', + ' return (-1);', + '}' + ] + code = '\n'.join(code) % self.GetTranslation({ + 'buf' : buf, + 'tag' : tag_name, + 'var' : var_name, + 'varlen' : var_len }) + return code.split('\n') + + def CodeMarshal(self, buf, tag_name, var_name, var_len): + code = ['evtag_marshal(%s, %s, %s, %s);' % ( + buf, tag_name, var_name, var_len)] + return code + + def CodeClear(self, structname): + code = [ 'if (%s->%s_set == 1) {' % (structname, self.Name()), + ' free (%s->%s_data);' % (structname, self.Name()), + ' %s->%s_data = NULL;' % (structname, self.Name()), + ' %s->%s_length = 0;' % (structname, self.Name()), + ' %s->%s_set = 0;' % (structname, self.Name()), + '}' + ] + + return code + + def CodeInitialize(self, name): + code = ['%s->%s_data = NULL;' % (name, self._name), + '%s->%s_length = 0;' % (name, self._name) ] + return code + + def CodeFree(self, name): + code = ['if (%s->%s_data != NULL)' % (name, self._name), + ' free(%s->%s_data);' % (name, self._name)] + + return code + + def Declaration(self): + dcl = ['ev_uint8_t *%s_data;' % self._name, + 'ev_uint32_t %s_length;' % self._name] + + return dcl + +class EntryArray(Entry): + def __init__(self, entry): + # Init base class + Entry.__init__(self, entry._type, entry._name, entry._tag) + + self._entry = entry + self._refname = entry._refname + self._ctype = self._entry._ctype + self._optional = True + self._optpointer = self._entry._optpointer + self._optaddarg = self._entry._optaddarg + + # provide a new function for accessing the variable name + def GetVarName(var_name): + return '%(var)s->%(name)s_data[%(index)s]' % \ + self._entry.GetTranslation({'var' : var_name, + 'index' : self._index}) + self._entry.GetVarName = GetVarName + + def GetInitializer(self): + return "NULL" + + def GetVarName(self, var_name): + return var_name + + def GetVarLen(self, var_name): + return '-1' + + def GetDeclaration(self, funcname): + """Allows direct access to elements of the array.""" + code = [ + 'int %(funcname)s(struct %(parent_name)s *, int, %(ctype)s *);' % + self.GetTranslation({ 'funcname' : funcname }) ] + return code + + def AssignDeclaration(self, funcname): + code = [ 'int %s(struct %s *, int, const %s);' % ( + funcname, self._struct.Name(), self._ctype ) ] + return code + + def AddDeclaration(self, funcname): + code = [ + '%(ctype)s %(optpointer)s ' + '%(funcname)s(struct %(parent_name)s *msg%(optaddarg)s);' % \ + self.GetTranslation({ 'funcname' : funcname }) ] + return code + + def CodeGet(self): + code = """int +%(parent_name)s_%(name)s_get(struct %(parent_name)s *msg, int offset, + %(ctype)s *value) +{ + if (!msg->%(name)s_set || offset < 0 || offset >= msg->%(name)s_length) + return (-1); + *value = msg->%(name)s_data[offset]; + return (0); +}""" % self.GetTranslation() + + return code.split('\n') + + def CodeAssign(self): + code = [ + 'int', + '%(parent_name)s_%(name)s_assign(struct %(parent_name)s *msg, int off,', + ' const %(ctype)s value)', + '{', + ' if (!msg->%(name)s_set || off < 0 || off >= msg->%(name)s_length)', + ' return (-1);\n', + ' {' ] + code = TranslateList(code, self.GetTranslation()) + + codearrayassign = self._entry.CodeArrayAssign( + 'msg->%(name)s_data[off]' % self.GetTranslation(), 'value') + code += map(lambda x: ' ' + x, codearrayassign) + + code += TranslateList([ + ' }', + ' return (0);', + '}' ], self.GetTranslation()) + + return code + + def CodeAdd(self): + codearrayadd = self._entry.CodeArrayAdd( + 'msg->%(name)s_data[msg->%(name)s_length - 1]' % self.GetTranslation(), + 'value') + code = [ + 'static int', + '%(parent_name)s_%(name)s_expand_to_hold_more(' + 'struct %(parent_name)s *msg)', + '{', + ' int tobe_allocated = msg->%(name)s_num_allocated;', + ' %(ctype)s* new_data = NULL;', + ' tobe_allocated = !tobe_allocated ? 1 : tobe_allocated << 1;', + ' new_data = (%(ctype)s*) realloc(msg->%(name)s_data,', + ' tobe_allocated * sizeof(%(ctype)s));', + ' if (new_data == NULL)', + ' return -1;', + ' msg->%(name)s_data = new_data;', + ' msg->%(name)s_num_allocated = tobe_allocated;', + ' return 0;' + '}', + '', + '%(ctype)s %(optpointer)s', + '%(parent_name)s_%(name)s_add(' + 'struct %(parent_name)s *msg%(optaddarg)s)', + '{', + ' if (++msg->%(name)s_length >= msg->%(name)s_num_allocated) {', + ' if (%(parent_name)s_%(name)s_expand_to_hold_more(msg)<0)', + ' goto error;', + ' }' ] + + code = TranslateList(code, self.GetTranslation()) + + code += map(lambda x: ' ' + x, codearrayadd) + + code += TranslateList([ + ' msg->%(name)s_set = 1;', + ' return %(optreference)s(msg->%(name)s_data[' + 'msg->%(name)s_length - 1]);', + 'error:', + ' --msg->%(name)s_length;', + ' return (NULL);', + '}' ], self.GetTranslation()) + + return code + + def CodeComplete(self, structname, var_name): + self._index = 'i' + tmp = self._entry.CodeComplete(structname, self._entry.GetVarName(var_name)) + # skip the whole loop if there is nothing to check + if not tmp: + return [] + + translate = self.GetTranslation({ 'structname' : structname }) + code = [ + '{', + ' int i;', + ' for (i = 0; i < %(structname)s->%(name)s_length; ++i) {' ] + + code = TranslateList(code, translate) + + code += map(lambda x: ' ' + x, tmp) + + code += [ + ' }', + '}' ] + + return code + + def CodeUnmarshal(self, buf, tag_name, var_name, var_len): + translate = self.GetTranslation({ 'var' : var_name, + 'buf' : buf, + 'tag' : tag_name, + 'init' : self._entry.GetInitializer()}) + code = [ + 'if (%(var)s->%(name)s_length >= %(var)s->%(name)s_num_allocated &&', + ' %(parent_name)s_%(name)s_expand_to_hold_more(%(var)s) < 0) {', + ' puts("HEY NOW");', + ' return (-1);', + '}'] + + # the unmarshal code directly returns + code = TranslateList(code, translate) + + self._index = '%(var)s->%(name)s_length' % translate + code += self._entry.CodeUnmarshal(buf, tag_name, + self._entry.GetVarName(var_name), + self._entry.GetVarLen(var_name)) + + code += [ '++%(var)s->%(name)s_length;' % translate ] + + return code + + def CodeMarshal(self, buf, tag_name, var_name, var_len): + code = ['{', + ' int i;', + ' for (i = 0; i < %(var)s->%(name)s_length; ++i) {' ] + + self._index = 'i' + code += self._entry.CodeMarshal(buf, tag_name, + self._entry.GetVarName(var_name), + self._entry.GetVarLen(var_name)) + code += [' }', + '}' + ] + + code = "\n".join(code) % self.GetTranslation({ 'var' : var_name }) + + return code.split('\n') + + def CodeClear(self, structname): + translate = self.GetTranslation({ 'structname' : structname }) + codearrayfree = self._entry.CodeArrayFree( + '%(structname)s->%(name)s_data[i]' % self.GetTranslation( + { 'structname' : structname } )) + + code = [ 'if (%(structname)s->%(name)s_set == 1) {' ] + + if codearrayfree: + code += [ + ' int i;', + ' for (i = 0; i < %(structname)s->%(name)s_length; ++i) {' ] + + code = TranslateList(code, translate) + + if codearrayfree: + code += map(lambda x: ' ' + x, codearrayfree) + code += [ + ' }' ] + + code += TranslateList([ + ' free(%(structname)s->%(name)s_data);', + ' %(structname)s->%(name)s_data = NULL;', + ' %(structname)s->%(name)s_set = 0;', + ' %(structname)s->%(name)s_length = 0;', + ' %(structname)s->%(name)s_num_allocated = 0;', + '}' + ], translate) + + return code + + def CodeInitialize(self, name): + code = ['%s->%s_data = NULL;' % (name, self._name), + '%s->%s_length = 0;' % (name, self._name), + '%s->%s_num_allocated = 0;' % (name, self._name)] + return code + + def CodeFree(self, structname): + code = self.CodeClear(structname); + + code += TranslateList([ + 'free(%(structname)s->%(name)s_data);' ], + self.GetTranslation({'structname' : structname })) + + return code + + def Declaration(self): + dcl = ['%s *%s_data;' % (self._ctype, self._name), + 'int %s_length;' % self._name, + 'int %s_num_allocated;' % self._name ] + + return dcl + +def NormalizeLine(line): + global white + global cppcomment + + line = cppcomment.sub('', line) + line = line.strip() + line = white.sub(' ', line) + + return line + +def ProcessOneEntry(factory, newstruct, entry): + optional = 0 + array = 0 + entry_type = '' + name = '' + tag = '' + tag_set = None + separator = '' + fixed_length = '' + + tokens = entry.split(' ') + while tokens: + token = tokens[0] + tokens = tokens[1:] + + if not entry_type: + if not optional and token == 'optional': + optional = 1 + continue + + if not array and token == 'array': + array = 1 + continue + + if not entry_type: + entry_type = token + continue + + if not name: + res = re.match(r'^([^\[\]]+)(\[.*\])?$', token) + if not res: + raise RpcGenError( + 'Cannot parse name: \"%s\" ' + 'around line %d' % (entry, line_count)) + name = res.group(1) + fixed_length = res.group(2) + if fixed_length: + fixed_length = fixed_length[1:-1] + continue + + if not separator: + separator = token + if separator != '=': + raise RpcGenError('Expected "=" after name \"%s\" got %s' + % (name, token)) + continue + + if not tag_set: + tag_set = 1 + if not re.match(r'^(0x)?[0-9]+$', token): + raise RpcGenError('Expected tag number: \"%s\"' % entry) + tag = int(token, 0) + continue + + raise RpcGenError('Cannot parse \"%s\"' % entry) + + if not tag_set: + raise RpcGenError('Need tag number: \"%s\"' % entry) + + # Create the right entry + if entry_type == 'bytes': + if fixed_length: + newentry = factory.EntryBytes(entry_type, name, tag, fixed_length) + else: + newentry = factory.EntryVarBytes(entry_type, name, tag) + elif entry_type == 'int' and not fixed_length: + newentry = factory.EntryInt(entry_type, name, tag) + elif entry_type == 'int64' and not fixed_length: + newentry = factory.EntryInt(entry_type, name, tag, bits=64) + elif entry_type == 'string' and not fixed_length: + newentry = factory.EntryString(entry_type, name, tag) + else: + res = structref.match(entry_type) + if res: + # References another struct defined in our file + newentry = factory.EntryStruct(entry_type, name, tag, res.group(1)) + else: + raise RpcGenError('Bad type: "%s" in "%s"' % (entry_type, entry)) + + structs = [] + + if optional: + newentry.MakeOptional() + if array: + newentry.MakeArray() + + newentry.SetStruct(newstruct) + newentry.SetLineCount(line_count) + newentry.Verify() + + if array: + # We need to encapsulate this entry into a struct + newname = newentry.Name()+ '_array' + + # Now borgify the new entry. + newentry = factory.EntryArray(newentry) + newentry.SetStruct(newstruct) + newentry.SetLineCount(line_count) + newentry.MakeArray() + + newstruct.AddEntry(newentry) + + return structs + +def ProcessStruct(factory, data): + tokens = data.split(' ') + + # First three tokens are: 'struct' 'name' '{' + newstruct = factory.Struct(tokens[1]) + + inside = ' '.join(tokens[3:-1]) + + tokens = inside.split(';') + + structs = [] + + for entry in tokens: + entry = NormalizeLine(entry) + if not entry: + continue + + # It's possible that new structs get defined in here + structs.extend(ProcessOneEntry(factory, newstruct, entry)) + + structs.append(newstruct) + return structs + +def GetNextStruct(file): + global line_count + global cppdirect + + got_struct = 0 + + processed_lines = [] + + have_c_comment = 0 + data = '' + while 1: + line = file.readline() + if not line: + break + + line_count += 1 + line = line[:-1] + + if not have_c_comment and re.search(r'/\*', line): + if re.search(r'/\*.*?\*/', line): + line = re.sub(r'/\*.*?\*/', '', line) + else: + line = re.sub(r'/\*.*$', '', line) + have_c_comment = 1 + + if have_c_comment: + if not re.search(r'\*/', line): + continue + have_c_comment = 0 + line = re.sub(r'^.*\*/', '', line) + + line = NormalizeLine(line) + + if not line: + continue + + if not got_struct: + if re.match(r'#include ["<].*[>"]', line): + cppdirect.append(line) + continue + + if re.match(r'^#(if( |def)|endif)', line): + cppdirect.append(line) + continue + + if re.match(r'^#define', line): + headerdirect.append(line) + continue + + if not structdef.match(line): + raise RpcGenError('Missing struct on line %d: %s' + % (line_count, line)) + else: + got_struct = 1 + data += line + continue + + # We are inside the struct + tokens = line.split('}') + if len(tokens) == 1: + data += ' ' + line + continue + + if len(tokens[1]): + raise RpcGenError('Trailing garbage after struct on line %d' + % line_count) + + # We found the end of the struct + data += ' %s}' % tokens[0] + break + + # Remove any comments, that might be in there + data = re.sub(r'/\*.*\*/', '', data) + + return data + + +def Parse(factory, file): + """ + Parses the input file and returns C code and corresponding header file. + """ + + entities = [] + + while 1: + # Just gets the whole struct nicely formatted + data = GetNextStruct(file) + + if not data: + break + + entities.extend(ProcessStruct(factory, data)) + + return entities + +class CCodeGenerator: + def __init__(self): + pass + + def GuardName(self, name): + # Use the complete provided path to the input file, with all + # non-identifier characters replaced with underscores, to + # reduce the chance of a collision between guard macros. + return 'EVENT_RPCOUT_' + nonident.sub('_', name).upper() + '_' + + def HeaderPreamble(self, name): + guard = self.GuardName(name) + pre = ( + '/*\n' + ' * Automatically generated from %s\n' + ' */\n\n' + '#ifndef %s\n' + '#define %s\n\n' ) % ( + name, guard, guard) + + for statement in headerdirect: + pre += '%s\n' % statement + if headerdirect: + pre += '\n' + + pre += ( + '#include /* for ev_uint*_t */\n' + '#include \n' + ) + + return pre + + def HeaderPostamble(self, name): + guard = self.GuardName(name) + return '#endif /* %s */' % guard + + def BodyPreamble(self, name, header_file): + global _NAME + global _VERSION + + slash = header_file.rfind('/') + if slash != -1: + header_file = header_file[slash+1:] + + pre = ( '/*\n' + ' * Automatically generated from %s\n' + ' * by %s/%s. DO NOT EDIT THIS FILE.\n' + ' */\n\n' ) % (name, _NAME, _VERSION) + pre += ( '#include \n' + '#include \n' + '#include \n' + '#include \n' + '#include \n' + '#include \n' + '#include \n\n' + '#ifdef EVENT____func__\n' + '#define __func__ EVENT____func__\n' + '#endif\n\n' + ) + + for statement in cppdirect: + pre += '%s\n' % statement + + pre += '\n#include "%s"\n\n' % header_file + + pre += 'void event_warn(const char *fmt, ...);\n' + pre += 'void event_warnx(const char *fmt, ...);\n\n' + + return pre + + def HeaderFilename(self, filename): + return '.'.join(filename.split('.')[:-1]) + '.h' + + def CodeFilename(self, filename): + return '.'.join(filename.split('.')[:-1]) + '.gen.c' + + def Struct(self, name): + return StructCCode(name) + + def EntryBytes(self, entry_type, name, tag, fixed_length): + return EntryBytes(entry_type, name, tag, fixed_length) + + def EntryVarBytes(self, entry_type, name, tag): + return EntryVarBytes(entry_type, name, tag) + + def EntryInt(self, entry_type, name, tag, bits=32): + return EntryInt(entry_type, name, tag, bits) + + def EntryString(self, entry_type, name, tag): + return EntryString(entry_type, name, tag) + + def EntryStruct(self, entry_type, name, tag, struct_name): + return EntryStruct(entry_type, name, tag, struct_name) + + def EntryArray(self, entry): + return EntryArray(entry) + +class Usage(RpcGenError): + def __init__(self, argv0): + RpcGenError.__init__("usage: %s input.rpc [[output.h] output.c]" + % argv0) + +class CommandLine: + def __init__(self, argv): + """Initialize a command-line to launch event_rpcgen, as if + from a command-line with CommandLine(sys.argv). If you're + calling this directly, remember to provide a dummy value + for sys.argv[0] + """ + self.filename = None + self.header_file = None + self.impl_file = None + self.factory = CCodeGenerator() + + if len(argv) >= 2 and argv[1] == '--quiet': + global QUIETLY + QUIETLY = 1 + del argv[1] + + if len(argv) < 2 or len(argv) > 4: + raise Usage(argv[0]) + + self.filename = argv[1].replace('\\', '/') + if len(argv) == 3: + self.impl_file = argv[2].replace('\\', '/') + if len(argv) == 4: + self.header_file = argv[2].replace('\\', '/') + self.impl_file = argv[3].replace('\\', '/') + + if not self.filename: + raise Usage(argv[0]) + + if not self.impl_file: + self.impl_file = self.factory.CodeFilename(self.filename) + + if not self.header_file: + self.header_file = self.factory.HeaderFilename(self.impl_file) + + if not self.impl_file.endswith('.c'): + raise RpcGenError("can only generate C implementation files") + if not self.header_file.endswith('.h'): + raise RpcGenError("can only generate C header files") + + def run(self): + filename = self.filename + header_file = self.header_file + impl_file = self.impl_file + factory = self.factory + + declare('Reading \"%s\"' % filename) + + fp = open(filename, 'r') + entities = Parse(factory, fp) + fp.close() + + declare('... creating "%s"' % header_file) + header_fp = open(header_file, 'w') + print >>header_fp, factory.HeaderPreamble(filename) + + # Create forward declarations: allows other structs to reference + # each other + for entry in entities: + entry.PrintForwardDeclaration(header_fp) + print >>header_fp, '' + + for entry in entities: + entry.PrintTags(header_fp) + entry.PrintDeclaration(header_fp) + print >>header_fp, factory.HeaderPostamble(filename) + header_fp.close() + + declare('... creating "%s"' % impl_file) + impl_fp = open(impl_file, 'w') + print >>impl_fp, factory.BodyPreamble(filename, header_file) + for entry in entities: + entry.PrintCode(impl_fp) + impl_fp.close() + +if __name__ == '__main__': + try: + CommandLine(sys.argv).run() + sys.exit(0) + + except RpcGenError, e: + print >>sys.stderr, e + sys.exit(1) + + except EnvironmentError, e: + if e.filename and e.strerror: + print >>sys.stderr, "%s: %s" % (e.filename, e.strerror) + sys.exit(1) + elif e.strerror: + print >> sys.stderr, e.strerror + sys.exit(1) + else: + raise diff --git a/contrib/ntp/sntp/libevent/event_tagging.c b/contrib/ntp/sntp/libevent/event_tagging.c new file mode 100644 index 000000000..64b100b82 --- /dev/null +++ b/contrib/ntp/sntp/libevent/event_tagging.c @@ -0,0 +1,604 @@ +/* + * Copyright (c) 2003-2009 Niels Provos + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_PARAM_H +#include +#endif + +#ifdef _WIN32 +#define WIN32_LEAN_AND_MEAN +#include +#include +#undef WIN32_LEAN_AND_MEAN +#else +#include +#endif + +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#include +#include +#include +#include +#ifndef _WIN32 +#include +#endif +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#include + +#include "event2/event.h" +#include "event2/tag.h" +#include "event2/buffer.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "util-internal.h" + +/* + Here's our wire format: + + Stream = TaggedData* + + TaggedData = Tag Length Data + where the integer value of 'Length' is the length of 'data'. + + Tag = HByte* LByte + where HByte is a byte with the high bit set, and LByte is a byte + with the high bit clear. The integer value of the tag is taken + by concatenating the lower 7 bits from all the tags. So for example, + the tag 0x66 is encoded as [66], whereas the tag 0x166 is encoded as + [82 66] + + Length = Integer + + Integer = NNibbles Nibble* Padding? + where NNibbles is a 4-bit value encoding the number of nibbles-1, + and each Nibble is 4 bits worth of encoded integer, in big-endian + order. If the total encoded integer size is an odd number of nibbles, + a final padding nibble with value 0 is appended. +*/ + +int evtag_decode_int(ev_uint32_t *pnumber, struct evbuffer *evbuf); +int evtag_decode_int64(ev_uint64_t *pnumber, struct evbuffer *evbuf); +int evtag_encode_tag(struct evbuffer *evbuf, ev_uint32_t tag); +int evtag_decode_tag(ev_uint32_t *ptag, struct evbuffer *evbuf); + +void +evtag_init(void) +{ +} + +/* + * We encode integers by nibbles; the first nibble contains the number + * of significant nibbles - 1; this allows us to encode up to 64-bit + * integers. This function is byte-order independent. + * + * @param number a 32-bit unsigned integer to encode + * @param data a pointer to where the data should be written. Must + * have at least 5 bytes free. + * @return the number of bytes written into data. + */ + +#define ENCODE_INT_INTERNAL(data, number) do { \ + int off = 1, nibbles = 0; \ + \ + memset(data, 0, sizeof(number)+1); \ + while (number) { \ + if (off & 0x1) \ + data[off/2] = (data[off/2] & 0xf0) | (number & 0x0f); \ + else \ + data[off/2] = (data[off/2] & 0x0f) | \ + ((number & 0x0f) << 4); \ + number >>= 4; \ + off++; \ + } \ + \ + if (off > 2) \ + nibbles = off - 2; \ + \ + /* Off - 1 is the number of encoded nibbles */ \ + data[0] = (data[0] & 0x0f) | ((nibbles & 0x0f) << 4); \ + \ + return ((off + 1) / 2); \ +} while (0) + +static inline int +encode_int_internal(ev_uint8_t *data, ev_uint32_t number) +{ + ENCODE_INT_INTERNAL(data, number); +} + +static inline int +encode_int64_internal(ev_uint8_t *data, ev_uint64_t number) +{ + ENCODE_INT_INTERNAL(data, number); +} + +void +evtag_encode_int(struct evbuffer *evbuf, ev_uint32_t number) +{ + ev_uint8_t data[5]; + int len = encode_int_internal(data, number); + evbuffer_add(evbuf, data, len); +} + +void +evtag_encode_int64(struct evbuffer *evbuf, ev_uint64_t number) +{ + ev_uint8_t data[9]; + int len = encode_int64_internal(data, number); + evbuffer_add(evbuf, data, len); +} + +/* + * Support variable length encoding of tags; we use the high bit in each + * octet as a continuation signal. + */ + +int +evtag_encode_tag(struct evbuffer *evbuf, ev_uint32_t tag) +{ + int bytes = 0; + ev_uint8_t data[5]; + + memset(data, 0, sizeof(data)); + do { + ev_uint8_t lower = tag & 0x7f; + tag >>= 7; + + if (tag) + lower |= 0x80; + + data[bytes++] = lower; + } while (tag); + + if (evbuf != NULL) + evbuffer_add(evbuf, data, bytes); + + return (bytes); +} + +static int +decode_tag_internal(ev_uint32_t *ptag, struct evbuffer *evbuf, int dodrain) +{ + ev_uint32_t number = 0; + size_t len = evbuffer_get_length(evbuf); + ev_uint8_t *data; + size_t count = 0; + int shift = 0, done = 0; + + /* + * the encoding of a number is at most one byte more than its + * storage size. however, it may also be much smaller. + */ + data = evbuffer_pullup( + evbuf, len < sizeof(number) + 1 ? len : sizeof(number) + 1); + if (!data) + return (-1); + + while (count++ < len) { + ev_uint8_t lower = *data++; + if (shift >= 28) { + /* Make sure it fits into 32 bits */ + if (shift > 28) + return (-1); + if ((lower & 0x7f) > 15) + return (-1); + } + number |= (lower & (unsigned)0x7f) << shift; + shift += 7; + + if (!(lower & 0x80)) { + done = 1; + break; + } + } + + if (!done) + return (-1); + + if (dodrain) + evbuffer_drain(evbuf, count); + + if (ptag != NULL) + *ptag = number; + + return count > INT_MAX ? INT_MAX : (int)(count); +} + +int +evtag_decode_tag(ev_uint32_t *ptag, struct evbuffer *evbuf) +{ + return (decode_tag_internal(ptag, evbuf, 1 /* dodrain */)); +} + +/* + * Marshal a data type, the general format is as follows: + * + * tag number: one byte; length: var bytes; payload: var bytes + */ + +void +evtag_marshal(struct evbuffer *evbuf, ev_uint32_t tag, + const void *data, ev_uint32_t len) +{ + evtag_encode_tag(evbuf, tag); + evtag_encode_int(evbuf, len); + evbuffer_add(evbuf, (void *)data, len); +} + +void +evtag_marshal_buffer(struct evbuffer *evbuf, ev_uint32_t tag, + struct evbuffer *data) +{ + evtag_encode_tag(evbuf, tag); + /* XXX support more than UINT32_MAX data */ + evtag_encode_int(evbuf, (ev_uint32_t)evbuffer_get_length(data)); + evbuffer_add_buffer(evbuf, data); +} + +/* Marshaling for integers */ +void +evtag_marshal_int(struct evbuffer *evbuf, ev_uint32_t tag, ev_uint32_t integer) +{ + ev_uint8_t data[5]; + int len = encode_int_internal(data, integer); + + evtag_encode_tag(evbuf, tag); + evtag_encode_int(evbuf, len); + evbuffer_add(evbuf, data, len); +} + +void +evtag_marshal_int64(struct evbuffer *evbuf, ev_uint32_t tag, + ev_uint64_t integer) +{ + ev_uint8_t data[9]; + int len = encode_int64_internal(data, integer); + + evtag_encode_tag(evbuf, tag); + evtag_encode_int(evbuf, len); + evbuffer_add(evbuf, data, len); +} + +void +evtag_marshal_string(struct evbuffer *buf, ev_uint32_t tag, const char *string) +{ + /* TODO support strings longer than UINT32_MAX ? */ + evtag_marshal(buf, tag, string, (ev_uint32_t)strlen(string)); +} + +void +evtag_marshal_timeval(struct evbuffer *evbuf, ev_uint32_t tag, struct timeval *tv) +{ + ev_uint8_t data[10]; + int len = encode_int_internal(data, tv->tv_sec); + len += encode_int_internal(data + len, tv->tv_usec); + evtag_marshal(evbuf, tag, data, len); +} + +#define DECODE_INT_INTERNAL(number, maxnibbles, pnumber, evbuf, offset) \ +do { \ + ev_uint8_t *data; \ + ev_ssize_t len = evbuffer_get_length(evbuf) - offset; \ + int nibbles = 0; \ + \ + if (len <= 0) \ + return (-1); \ + \ + /* XXX(niels): faster? */ \ + data = evbuffer_pullup(evbuf, offset + 1) + offset; \ + if (!data) \ + return (-1); \ + \ + nibbles = ((data[0] & 0xf0) >> 4) + 1; \ + if (nibbles > maxnibbles || (nibbles >> 1) + 1 > len) \ + return (-1); \ + len = (nibbles >> 1) + 1; \ + \ + data = evbuffer_pullup(evbuf, offset + len) + offset; \ + if (!data) \ + return (-1); \ + \ + while (nibbles > 0) { \ + number <<= 4; \ + if (nibbles & 0x1) \ + number |= data[nibbles >> 1] & 0x0f; \ + else \ + number |= (data[nibbles >> 1] & 0xf0) >> 4; \ + nibbles--; \ + } \ + \ + *pnumber = number; \ + \ + return (int)(len); \ +} while (0) + +/* Internal: decode an integer from an evbuffer, without draining it. + * Only integers up to 32-bits are supported. + * + * @param evbuf the buffer to read from + * @param offset an index into the buffer at which we should start reading. + * @param pnumber a pointer to receive the integer. + * @return The length of the number as encoded, or -1 on error. + */ + +static int +decode_int_internal(ev_uint32_t *pnumber, struct evbuffer *evbuf, int offset) +{ + ev_uint32_t number = 0; + DECODE_INT_INTERNAL(number, 8, pnumber, evbuf, offset); +} + +static int +decode_int64_internal(ev_uint64_t *pnumber, struct evbuffer *evbuf, int offset) +{ + ev_uint64_t number = 0; + DECODE_INT_INTERNAL(number, 16, pnumber, evbuf, offset); +} + +int +evtag_decode_int(ev_uint32_t *pnumber, struct evbuffer *evbuf) +{ + int res = decode_int_internal(pnumber, evbuf, 0); + if (res != -1) + evbuffer_drain(evbuf, res); + + return (res == -1 ? -1 : 0); +} + +int +evtag_decode_int64(ev_uint64_t *pnumber, struct evbuffer *evbuf) +{ + int res = decode_int64_internal(pnumber, evbuf, 0); + if (res != -1) + evbuffer_drain(evbuf, res); + + return (res == -1 ? -1 : 0); +} + +int +evtag_peek(struct evbuffer *evbuf, ev_uint32_t *ptag) +{ + return (decode_tag_internal(ptag, evbuf, 0 /* dodrain */)); +} + +int +evtag_peek_length(struct evbuffer *evbuf, ev_uint32_t *plength) +{ + int res, len; + + len = decode_tag_internal(NULL, evbuf, 0 /* dodrain */); + if (len == -1) + return (-1); + + res = decode_int_internal(plength, evbuf, len); + if (res == -1) + return (-1); + + *plength += res + len; + + return (0); +} + +int +evtag_payload_length(struct evbuffer *evbuf, ev_uint32_t *plength) +{ + int res, len; + + len = decode_tag_internal(NULL, evbuf, 0 /* dodrain */); + if (len == -1) + return (-1); + + res = decode_int_internal(plength, evbuf, len); + if (res == -1) + return (-1); + + return (0); +} + +/* just unmarshals the header and returns the length of the remaining data */ + +int +evtag_unmarshal_header(struct evbuffer *evbuf, ev_uint32_t *ptag) +{ + ev_uint32_t len; + + if (decode_tag_internal(ptag, evbuf, 1 /* dodrain */) == -1) + return (-1); + if (evtag_decode_int(&len, evbuf) == -1) + return (-1); + + if (evbuffer_get_length(evbuf) < len) + return (-1); + + return (len); +} + +int +evtag_consume(struct evbuffer *evbuf) +{ + int len; + if ((len = evtag_unmarshal_header(evbuf, NULL)) == -1) + return (-1); + evbuffer_drain(evbuf, len); + + return (0); +} + +/* Reads the data type from an event buffer */ + +int +evtag_unmarshal(struct evbuffer *src, ev_uint32_t *ptag, struct evbuffer *dst) +{ + int len; + + if ((len = evtag_unmarshal_header(src, ptag)) == -1) + return (-1); + + if (evbuffer_add(dst, evbuffer_pullup(src, len), len) == -1) + return (-1); + + evbuffer_drain(src, len); + + return (len); +} + +/* Marshaling for integers */ + +int +evtag_unmarshal_int(struct evbuffer *evbuf, ev_uint32_t need_tag, + ev_uint32_t *pinteger) +{ + ev_uint32_t tag; + ev_uint32_t len; + int result; + + if (decode_tag_internal(&tag, evbuf, 1 /* dodrain */) == -1) + return (-1); + if (need_tag != tag) + return (-1); + if (evtag_decode_int(&len, evbuf) == -1) + return (-1); + + if (evbuffer_get_length(evbuf) < len) + return (-1); + + result = decode_int_internal(pinteger, evbuf, 0); + evbuffer_drain(evbuf, len); + if (result < 0 || (size_t)result > len) /* XXX Should this be != rather than > ?*/ + return (-1); + else + return result; +} + +int +evtag_unmarshal_int64(struct evbuffer *evbuf, ev_uint32_t need_tag, + ev_uint64_t *pinteger) +{ + ev_uint32_t tag; + ev_uint32_t len; + int result; + + if (decode_tag_internal(&tag, evbuf, 1 /* dodrain */) == -1) + return (-1); + if (need_tag != tag) + return (-1); + if (evtag_decode_int(&len, evbuf) == -1) + return (-1); + + if (evbuffer_get_length(evbuf) < len) + return (-1); + + result = decode_int64_internal(pinteger, evbuf, 0); + evbuffer_drain(evbuf, len); + if (result < 0 || (size_t)result > len) /* XXX Should this be != rather than > ?*/ + return (-1); + else + return result; +} + +/* Unmarshal a fixed length tag */ + +int +evtag_unmarshal_fixed(struct evbuffer *src, ev_uint32_t need_tag, void *data, + size_t len) +{ + ev_uint32_t tag; + int tag_len; + + /* Now unmarshal a tag and check that it matches the tag we want */ + if ((tag_len = evtag_unmarshal_header(src, &tag)) < 0 || + tag != need_tag) + return (-1); + + if ((size_t)tag_len != len) + return (-1); + + evbuffer_remove(src, data, len); + return (0); +} + +int +evtag_unmarshal_string(struct evbuffer *evbuf, ev_uint32_t need_tag, + char **pstring) +{ + ev_uint32_t tag; + int tag_len; + + if ((tag_len = evtag_unmarshal_header(evbuf, &tag)) == -1 || + tag != need_tag) + return (-1); + + *pstring = mm_malloc(tag_len + 1); + if (*pstring == NULL) { + event_warn("%s: malloc", __func__); + return -1; + } + evbuffer_remove(evbuf, *pstring, tag_len); + (*pstring)[tag_len] = '\0'; + + return (0); +} + +int +evtag_unmarshal_timeval(struct evbuffer *evbuf, ev_uint32_t need_tag, + struct timeval *ptv) +{ + ev_uint32_t tag; + ev_uint32_t integer; + int len, offset, offset2; + int result = -1; + + if ((len = evtag_unmarshal_header(evbuf, &tag)) == -1) + return (-1); + if (tag != need_tag) + goto done; + if ((offset = decode_int_internal(&integer, evbuf, 0)) == -1) + goto done; + ptv->tv_sec = integer; + if ((offset2 = decode_int_internal(&integer, evbuf, offset)) == -1) + goto done; + ptv->tv_usec = integer; + if (offset + offset2 > len) /* XXX Should this be != instead of > ? */ + goto done; + + result = 0; + done: + evbuffer_drain(evbuf, len); + return result; +} diff --git a/contrib/ntp/sntp/libevent/evmap-internal.h b/contrib/ntp/sntp/libevent/evmap-internal.h new file mode 100644 index 000000000..dfc81d508 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evmap-internal.h @@ -0,0 +1,117 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVMAP_INTERNAL_H_INCLUDED_ +#define EVMAP_INTERNAL_H_INCLUDED_ + +/** @file evmap-internal.h + * + * An event_map is a utility structure to map each fd or signal to zero or + * more events. Functions to manipulate event_maps should only be used from + * inside libevent. They generally need to hold the lock on the corresponding + * event_base. + **/ + +struct event_base; +struct event; + +/** Initialize an event_map for use. + */ +void evmap_io_initmap_(struct event_io_map* ctx); +void evmap_signal_initmap_(struct event_signal_map* ctx); + +/** Remove all entries from an event_map. + + @param ctx the map to clear. + */ +void evmap_io_clear_(struct event_io_map* ctx); +void evmap_signal_clear_(struct event_signal_map* ctx); + +/** Add an IO event (some combination of EV_READ or EV_WRITE) to an + event_base's list of events on a given file descriptor, and tell the + underlying eventops about the fd if its state has changed. + + Requires that ev is not already added. + + @param base the event_base to operate on. + @param fd the file descriptor corresponding to ev. + @param ev the event to add. +*/ +int evmap_io_add_(struct event_base *base, evutil_socket_t fd, struct event *ev); +/** Remove an IO event (some combination of EV_READ or EV_WRITE) to an + event_base's list of events on a given file descriptor, and tell the + underlying eventops about the fd if its state has changed. + + @param base the event_base to operate on. + @param fd the file descriptor corresponding to ev. + @param ev the event to remove. + */ +int evmap_io_del_(struct event_base *base, evutil_socket_t fd, struct event *ev); +/** Active the set of events waiting on an event_base for a given fd. + + @param base the event_base to operate on. + @param fd the file descriptor that has become active. + @param events a bitmask of EV_READ|EV_WRITE|EV_ET. +*/ +void evmap_io_active_(struct event_base *base, evutil_socket_t fd, short events); + + +/* These functions behave in the same way as evmap_io_*, except they work on + * signals rather than fds. signals use a linear map everywhere; fds use + * either a linear map or a hashtable. */ +int evmap_signal_add_(struct event_base *base, int signum, struct event *ev); +int evmap_signal_del_(struct event_base *base, int signum, struct event *ev); +void evmap_signal_active_(struct event_base *base, evutil_socket_t signum, int ncalls); + +/* Return the fdinfo object associated with a given fd. If the fd has no + * events associated with it, the result may be NULL. + */ +void *evmap_io_get_fdinfo_(struct event_io_map *ctx, evutil_socket_t fd); + +/* Helper for event_reinit(): Tell the backend to re-add every fd and signal + * for which we have a pending event. + */ +int evmap_reinit_(struct event_base *base); + +/* Helper for event_base_free(): Call event_del() on every pending fd and + * signal event. + */ +void evmap_delete_all_(struct event_base *base); + +/* Helper for event_base_assert_ok_(): Check referential integrity of the + * evmaps. + */ +void evmap_check_integrity_(struct event_base *base); + +/* Helper: Call fn on every fd or signal event, passing as its arguments the + * provided event_base, the event, and arg. If fn returns 0, process the next + * event. If it returns any other value, return that value and process no + * more events. + */ +int evmap_foreach_event_(struct event_base *base, + event_base_foreach_event_cb fn, + void *arg); + +#endif /* EVMAP_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/evmap.c b/contrib/ntp/sntp/libevent/evmap.c new file mode 100644 index 000000000..3f76dd0ae --- /dev/null +++ b/contrib/ntp/sntp/libevent/evmap.c @@ -0,0 +1,1055 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#include +#define WIN32_LEAN_AND_MEAN +#include +#undef WIN32_LEAN_AND_MEAN +#endif +#include +#if !defined(_WIN32) && defined(EVENT__HAVE_SYS_TIME_H) +#include +#endif +#include +#include +#include +#ifndef _WIN32 +#include +#endif +#include +#include +#include +#include + +#include "event-internal.h" +#include "evmap-internal.h" +#include "mm-internal.h" +#include "changelist-internal.h" + +/** An entry for an evmap_io list: notes all the events that want to read or + write on a given fd, and the number of each. + */ +struct evmap_io { + struct event_dlist events; + ev_uint16_t nread; + ev_uint16_t nwrite; + ev_uint16_t nclose; +}; + +/* An entry for an evmap_signal list: notes all the events that want to know + when a signal triggers. */ +struct evmap_signal { + struct event_dlist events; +}; + +/* On some platforms, fds start at 0 and increment by 1 as they are + allocated, and old numbers get used. For these platforms, we + implement io maps just like signal maps: as an array of pointers to + struct evmap_io. But on other platforms (windows), sockets are not + 0-indexed, not necessarily consecutive, and not necessarily reused. + There, we use a hashtable to implement evmap_io. +*/ +#ifdef EVMAP_USE_HT +struct event_map_entry { + HT_ENTRY(event_map_entry) map_node; + evutil_socket_t fd; + union { /* This is a union in case we need to make more things that can + be in the hashtable. */ + struct evmap_io evmap_io; + } ent; +}; + +/* Helper used by the event_io_map hashtable code; tries to return a good hash + * of the fd in e->fd. */ +static inline unsigned +hashsocket(struct event_map_entry *e) +{ + /* On win32, in practice, the low 2-3 bits of a SOCKET seem not to + * matter. Our hashtable implementation really likes low-order bits, + * though, so let's do the rotate-and-add trick. */ + unsigned h = (unsigned) e->fd; + h += (h >> 2) | (h << 30); + return h; +} + +/* Helper used by the event_io_map hashtable code; returns true iff e1 and e2 + * have the same e->fd. */ +static inline int +eqsocket(struct event_map_entry *e1, struct event_map_entry *e2) +{ + return e1->fd == e2->fd; +} + +HT_PROTOTYPE(event_io_map, event_map_entry, map_node, hashsocket, eqsocket) +HT_GENERATE(event_io_map, event_map_entry, map_node, hashsocket, eqsocket, + 0.5, mm_malloc, mm_realloc, mm_free) + +#define GET_IO_SLOT(x, map, slot, type) \ + do { \ + struct event_map_entry key_, *ent_; \ + key_.fd = slot; \ + ent_ = HT_FIND(event_io_map, map, &key_); \ + (x) = ent_ ? &ent_->ent.type : NULL; \ + } while (0); + +#define GET_IO_SLOT_AND_CTOR(x, map, slot, type, ctor, fdinfo_len) \ + do { \ + struct event_map_entry key_, *ent_; \ + key_.fd = slot; \ + HT_FIND_OR_INSERT_(event_io_map, map_node, hashsocket, map, \ + event_map_entry, &key_, ptr, \ + { \ + ent_ = *ptr; \ + }, \ + { \ + ent_ = mm_calloc(1,sizeof(struct event_map_entry)+fdinfo_len); \ + if (EVUTIL_UNLIKELY(ent_ == NULL)) \ + return (-1); \ + ent_->fd = slot; \ + (ctor)(&ent_->ent.type); \ + HT_FOI_INSERT_(map_node, map, &key_, ent_, ptr) \ + }); \ + (x) = &ent_->ent.type; \ + } while (0) + +void evmap_io_initmap_(struct event_io_map *ctx) +{ + HT_INIT(event_io_map, ctx); +} + +void evmap_io_clear_(struct event_io_map *ctx) +{ + struct event_map_entry **ent, **next, *this; + for (ent = HT_START(event_io_map, ctx); ent; ent = next) { + this = *ent; + next = HT_NEXT_RMV(event_io_map, ctx, ent); + mm_free(this); + } + HT_CLEAR(event_io_map, ctx); /* remove all storage held by the ctx. */ +} +#endif + +/* Set the variable 'x' to the field in event_map 'map' with fields of type + 'struct type *' corresponding to the fd or signal 'slot'. Set 'x' to NULL + if there are no entries for 'slot'. Does no bounds-checking. */ +#define GET_SIGNAL_SLOT(x, map, slot, type) \ + (x) = (struct type *)((map)->entries[slot]) +/* As GET_SLOT, but construct the entry for 'slot' if it is not present, + by allocating enough memory for a 'struct type', and initializing the new + value by calling the function 'ctor' on it. Makes the function + return -1 on allocation failure. + */ +#define GET_SIGNAL_SLOT_AND_CTOR(x, map, slot, type, ctor, fdinfo_len) \ + do { \ + if ((map)->entries[slot] == NULL) { \ + (map)->entries[slot] = \ + mm_calloc(1,sizeof(struct type)+fdinfo_len); \ + if (EVUTIL_UNLIKELY((map)->entries[slot] == NULL)) \ + return (-1); \ + (ctor)((struct type *)(map)->entries[slot]); \ + } \ + (x) = (struct type *)((map)->entries[slot]); \ + } while (0) + +/* If we aren't using hashtables, then define the IO_SLOT macros and functions + as thin aliases over the SIGNAL_SLOT versions. */ +#ifndef EVMAP_USE_HT +#define GET_IO_SLOT(x,map,slot,type) GET_SIGNAL_SLOT(x,map,slot,type) +#define GET_IO_SLOT_AND_CTOR(x,map,slot,type,ctor,fdinfo_len) \ + GET_SIGNAL_SLOT_AND_CTOR(x,map,slot,type,ctor,fdinfo_len) +#define FDINFO_OFFSET sizeof(struct evmap_io) +void +evmap_io_initmap_(struct event_io_map* ctx) +{ + evmap_signal_initmap_(ctx); +} +void +evmap_io_clear_(struct event_io_map* ctx) +{ + evmap_signal_clear_(ctx); +} +#endif + + +/** Expand 'map' with new entries of width 'msize' until it is big enough + to store a value in 'slot'. + */ +static int +evmap_make_space(struct event_signal_map *map, int slot, int msize) +{ + if (map->nentries <= slot) { + int nentries = map->nentries ? map->nentries : 32; + void **tmp; + + while (nentries <= slot) + nentries <<= 1; + + tmp = (void **)mm_realloc(map->entries, nentries * msize); + if (tmp == NULL) + return (-1); + + memset(&tmp[map->nentries], 0, + (nentries - map->nentries) * msize); + + map->nentries = nentries; + map->entries = tmp; + } + + return (0); +} + +void +evmap_signal_initmap_(struct event_signal_map *ctx) +{ + ctx->nentries = 0; + ctx->entries = NULL; +} + +void +evmap_signal_clear_(struct event_signal_map *ctx) +{ + if (ctx->entries != NULL) { + int i; + for (i = 0; i < ctx->nentries; ++i) { + if (ctx->entries[i] != NULL) + mm_free(ctx->entries[i]); + } + mm_free(ctx->entries); + ctx->entries = NULL; + } + ctx->nentries = 0; +} + + +/* code specific to file descriptors */ + +/** Constructor for struct evmap_io */ +static void +evmap_io_init(struct evmap_io *entry) +{ + LIST_INIT(&entry->events); + entry->nread = 0; + entry->nwrite = 0; + entry->nclose = 0; +} + + +/* return -1 on error, 0 on success if nothing changed in the event backend, + * and 1 on success if something did. */ +int +evmap_io_add_(struct event_base *base, evutil_socket_t fd, struct event *ev) +{ + const struct eventop *evsel = base->evsel; + struct event_io_map *io = &base->io; + struct evmap_io *ctx = NULL; + int nread, nwrite, nclose, retval = 0; + short res = 0, old = 0; + struct event *old_ev; + + EVUTIL_ASSERT(fd == ev->ev_fd); + + if (fd < 0) + return 0; + +#ifndef EVMAP_USE_HT + if (fd >= io->nentries) { + if (evmap_make_space(io, fd, sizeof(struct evmap_io *)) == -1) + return (-1); + } +#endif + GET_IO_SLOT_AND_CTOR(ctx, io, fd, evmap_io, evmap_io_init, + evsel->fdinfo_len); + + nread = ctx->nread; + nwrite = ctx->nwrite; + nclose = ctx->nclose; + + if (nread) + old |= EV_READ; + if (nwrite) + old |= EV_WRITE; + if (nclose) + old |= EV_CLOSED; + + if (ev->ev_events & EV_READ) { + if (++nread == 1) + res |= EV_READ; + } + if (ev->ev_events & EV_WRITE) { + if (++nwrite == 1) + res |= EV_WRITE; + } + if (ev->ev_events & EV_CLOSED) { + if (++nclose == 1) + res |= EV_CLOSED; + } + if (EVUTIL_UNLIKELY(nread > 0xffff || nwrite > 0xffff || nclose > 0xffff)) { + event_warnx("Too many events reading or writing on fd %d", + (int)fd); + return -1; + } + if (EVENT_DEBUG_MODE_IS_ON() && + (old_ev = LIST_FIRST(&ctx->events)) && + (old_ev->ev_events&EV_ET) != (ev->ev_events&EV_ET)) { + event_warnx("Tried to mix edge-triggered and non-edge-triggered" + " events on fd %d", (int)fd); + return -1; + } + + if (res) { + void *extra = ((char*)ctx) + sizeof(struct evmap_io); + /* XXX(niels): we cannot mix edge-triggered and + * level-triggered, we should probably assert on + * this. */ + if (evsel->add(base, ev->ev_fd, + old, (ev->ev_events & EV_ET) | res, extra) == -1) + return (-1); + retval = 1; + } + + ctx->nread = (ev_uint16_t) nread; + ctx->nwrite = (ev_uint16_t) nwrite; + ctx->nclose = (ev_uint16_t) nclose; + LIST_INSERT_HEAD(&ctx->events, ev, ev_io_next); + + return (retval); +} + +/* return -1 on error, 0 on success if nothing changed in the event backend, + * and 1 on success if something did. */ +int +evmap_io_del_(struct event_base *base, evutil_socket_t fd, struct event *ev) +{ + const struct eventop *evsel = base->evsel; + struct event_io_map *io = &base->io; + struct evmap_io *ctx; + int nread, nwrite, nclose, retval = 0; + short res = 0, old = 0; + + if (fd < 0) + return 0; + + EVUTIL_ASSERT(fd == ev->ev_fd); + +#ifndef EVMAP_USE_HT + if (fd >= io->nentries) + return (-1); +#endif + + GET_IO_SLOT(ctx, io, fd, evmap_io); + + nread = ctx->nread; + nwrite = ctx->nwrite; + nclose = ctx->nclose; + + if (nread) + old |= EV_READ; + if (nwrite) + old |= EV_WRITE; + if (nclose) + old |= EV_CLOSED; + + if (ev->ev_events & EV_READ) { + if (--nread == 0) + res |= EV_READ; + EVUTIL_ASSERT(nread >= 0); + } + if (ev->ev_events & EV_WRITE) { + if (--nwrite == 0) + res |= EV_WRITE; + EVUTIL_ASSERT(nwrite >= 0); + } + if (ev->ev_events & EV_CLOSED) { + if (--nclose == 0) + res |= EV_CLOSED; + EVUTIL_ASSERT(nclose >= 0); + } + + if (res) { + void *extra = ((char*)ctx) + sizeof(struct evmap_io); + if (evsel->del(base, ev->ev_fd, old, res, extra) == -1) { + retval = -1; + } else { + retval = 1; + } + } + + ctx->nread = nread; + ctx->nwrite = nwrite; + ctx->nclose = nclose; + LIST_REMOVE(ev, ev_io_next); + + return (retval); +} + +void +evmap_io_active_(struct event_base *base, evutil_socket_t fd, short events) +{ + struct event_io_map *io = &base->io; + struct evmap_io *ctx; + struct event *ev; + +#ifndef EVMAP_USE_HT + if (fd < 0 || fd >= io->nentries) + return; +#endif + GET_IO_SLOT(ctx, io, fd, evmap_io); + + if (NULL == ctx) + return; + LIST_FOREACH(ev, &ctx->events, ev_io_next) { + if (ev->ev_events & events) + event_active_nolock_(ev, ev->ev_events & events, 1); + } +} + +/* code specific to signals */ + +static void +evmap_signal_init(struct evmap_signal *entry) +{ + LIST_INIT(&entry->events); +} + + +int +evmap_signal_add_(struct event_base *base, int sig, struct event *ev) +{ + const struct eventop *evsel = base->evsigsel; + struct event_signal_map *map = &base->sigmap; + struct evmap_signal *ctx = NULL; + + if (sig >= map->nentries) { + if (evmap_make_space( + map, sig, sizeof(struct evmap_signal *)) == -1) + return (-1); + } + GET_SIGNAL_SLOT_AND_CTOR(ctx, map, sig, evmap_signal, evmap_signal_init, + base->evsigsel->fdinfo_len); + + if (LIST_EMPTY(&ctx->events)) { + if (evsel->add(base, ev->ev_fd, 0, EV_SIGNAL, NULL) + == -1) + return (-1); + } + + LIST_INSERT_HEAD(&ctx->events, ev, ev_signal_next); + + return (1); +} + +int +evmap_signal_del_(struct event_base *base, int sig, struct event *ev) +{ + const struct eventop *evsel = base->evsigsel; + struct event_signal_map *map = &base->sigmap; + struct evmap_signal *ctx; + + if (sig >= map->nentries) + return (-1); + + GET_SIGNAL_SLOT(ctx, map, sig, evmap_signal); + + LIST_REMOVE(ev, ev_signal_next); + + if (LIST_FIRST(&ctx->events) == NULL) { + if (evsel->del(base, ev->ev_fd, 0, EV_SIGNAL, NULL) == -1) + return (-1); + } + + return (1); +} + +void +evmap_signal_active_(struct event_base *base, evutil_socket_t sig, int ncalls) +{ + struct event_signal_map *map = &base->sigmap; + struct evmap_signal *ctx; + struct event *ev; + + if (sig < 0 || sig >= map->nentries) + return; + GET_SIGNAL_SLOT(ctx, map, sig, evmap_signal); + + if (!ctx) + return; + LIST_FOREACH(ev, &ctx->events, ev_signal_next) + event_active_nolock_(ev, EV_SIGNAL, ncalls); +} + +void * +evmap_io_get_fdinfo_(struct event_io_map *map, evutil_socket_t fd) +{ + struct evmap_io *ctx; + GET_IO_SLOT(ctx, map, fd, evmap_io); + if (ctx) + return ((char*)ctx) + sizeof(struct evmap_io); + else + return NULL; +} + +/* Callback type for evmap_io_foreach_fd */ +typedef int (*evmap_io_foreach_fd_cb)( + struct event_base *, evutil_socket_t, struct evmap_io *, void *); + +/* Multipurpose helper function: Iterate over every file descriptor event_base + * for which we could have EV_READ or EV_WRITE events. For each such fd, call + * fn(base, signum, evmap_io, arg), where fn is the user-provided + * function, base is the event_base, signum is the signal number, evmap_io + * is an evmap_io structure containing a list of events pending on the + * file descriptor, and arg is the user-supplied argument. + * + * If fn returns 0, continue on to the next signal. Otherwise, return the same + * value that fn returned. + * + * Note that there is no guarantee that the file descriptors will be processed + * in any particular order. + */ +static int +evmap_io_foreach_fd(struct event_base *base, + evmap_io_foreach_fd_cb fn, + void *arg) +{ + evutil_socket_t fd; + struct event_io_map *iomap = &base->io; + int r = 0; +#ifdef EVMAP_USE_HT + struct event_map_entry **mapent; + HT_FOREACH(mapent, event_io_map, iomap) { + struct evmap_io *ctx = &(*mapent)->ent.evmap_io; + fd = (*mapent)->fd; +#else + for (fd = 0; fd < iomap->nentries; ++fd) { + struct evmap_io *ctx = iomap->entries[fd]; + if (!ctx) + continue; +#endif + if ((r = fn(base, fd, ctx, arg))) + break; + } + return r; +} + +/* Callback type for evmap_signal_foreach_signal */ +typedef int (*evmap_signal_foreach_signal_cb)( + struct event_base *, int, struct evmap_signal *, void *); + +/* Multipurpose helper function: Iterate over every signal number in the + * event_base for which we could have signal events. For each such signal, + * call fn(base, signum, evmap_signal, arg), where fn is the user-provided + * function, base is the event_base, signum is the signal number, evmap_signal + * is an evmap_signal structure containing a list of events pending on the + * signal, and arg is the user-supplied argument. + * + * If fn returns 0, continue on to the next signal. Otherwise, return the same + * value that fn returned. + */ +static int +evmap_signal_foreach_signal(struct event_base *base, + evmap_signal_foreach_signal_cb fn, + void *arg) +{ + struct event_signal_map *sigmap = &base->sigmap; + int r = 0; + int signum; + + for (signum = 0; signum < sigmap->nentries; ++signum) { + struct evmap_signal *ctx = sigmap->entries[signum]; + if (!ctx) + continue; + if ((r = fn(base, signum, ctx, arg))) + break; + } + return r; +} + +/* Helper for evmap_reinit_: tell the backend to add every fd for which we have + * pending events, with the appropriate combination of EV_READ, EV_WRITE, and + * EV_ET. */ +static int +evmap_io_reinit_iter_fn(struct event_base *base, evutil_socket_t fd, + struct evmap_io *ctx, void *arg) +{ + const struct eventop *evsel = base->evsel; + void *extra; + int *result = arg; + short events = 0; + struct event *ev; + EVUTIL_ASSERT(ctx); + + extra = ((char*)ctx) + sizeof(struct evmap_io); + if (ctx->nread) + events |= EV_READ; + if (ctx->nwrite) + events |= EV_WRITE; + if (ctx->nclose) + events |= EV_CLOSED; + if (evsel->fdinfo_len) + memset(extra, 0, evsel->fdinfo_len); + if (events && + (ev = LIST_FIRST(&ctx->events)) && + (ev->ev_events & EV_ET)) + events |= EV_ET; + if (evsel->add(base, fd, 0, events, extra) == -1) + *result = -1; + + return 0; +} + +/* Helper for evmap_reinit_: tell the backend to add every signal for which we + * have pending events. */ +static int +evmap_signal_reinit_iter_fn(struct event_base *base, + int signum, struct evmap_signal *ctx, void *arg) +{ + const struct eventop *evsel = base->evsigsel; + int *result = arg; + + if (!LIST_EMPTY(&ctx->events)) { + if (evsel->add(base, signum, 0, EV_SIGNAL, NULL) == -1) + *result = -1; + } + return 0; +} + +int +evmap_reinit_(struct event_base *base) +{ + int result = 0; + + evmap_io_foreach_fd(base, evmap_io_reinit_iter_fn, &result); + if (result < 0) + return -1; + evmap_signal_foreach_signal(base, evmap_signal_reinit_iter_fn, &result); + if (result < 0) + return -1; + return 0; +} + +/* Helper for evmap_delete_all_: delete every event in an event_dlist. */ +static int +delete_all_in_dlist(struct event_dlist *dlist) +{ + struct event *ev; + while ((ev = LIST_FIRST(dlist))) + event_del(ev); + return 0; +} + +/* Helper for evmap_delete_all_: delete every event pending on an fd. */ +static int +evmap_io_delete_all_iter_fn(struct event_base *base, evutil_socket_t fd, + struct evmap_io *io_info, void *arg) +{ + return delete_all_in_dlist(&io_info->events); +} + +/* Helper for evmap_delete_all_: delete every event pending on a signal. */ +static int +evmap_signal_delete_all_iter_fn(struct event_base *base, int signum, + struct evmap_signal *sig_info, void *arg) +{ + return delete_all_in_dlist(&sig_info->events); +} + +void +evmap_delete_all_(struct event_base *base) +{ + evmap_signal_foreach_signal(base, evmap_signal_delete_all_iter_fn, NULL); + evmap_io_foreach_fd(base, evmap_io_delete_all_iter_fn, NULL); +} + +/** Per-fd structure for use with changelists. It keeps track, for each fd or + * signal using the changelist, of where its entry in the changelist is. + */ +struct event_changelist_fdinfo { + int idxplus1; /* this is the index +1, so that memset(0) will make it + * a no-such-element */ +}; + +void +event_changelist_init_(struct event_changelist *changelist) +{ + changelist->changes = NULL; + changelist->changes_size = 0; + changelist->n_changes = 0; +} + +/** Helper: return the changelist_fdinfo corresponding to a given change. */ +static inline struct event_changelist_fdinfo * +event_change_get_fdinfo(struct event_base *base, + const struct event_change *change) +{ + char *ptr; + if (change->read_change & EV_CHANGE_SIGNAL) { + struct evmap_signal *ctx; + GET_SIGNAL_SLOT(ctx, &base->sigmap, change->fd, evmap_signal); + ptr = ((char*)ctx) + sizeof(struct evmap_signal); + } else { + struct evmap_io *ctx; + GET_IO_SLOT(ctx, &base->io, change->fd, evmap_io); + ptr = ((char*)ctx) + sizeof(struct evmap_io); + } + return (void*)ptr; +} + +/** Callback helper for event_changelist_assert_ok */ +static int +event_changelist_assert_ok_foreach_iter_fn( + struct event_base *base, + evutil_socket_t fd, struct evmap_io *io, void *arg) +{ + struct event_changelist *changelist = &base->changelist; + struct event_changelist_fdinfo *f; + f = (void*) + ( ((char*)io) + sizeof(struct evmap_io) ); + if (f->idxplus1) { + struct event_change *c = &changelist->changes[f->idxplus1 - 1]; + EVUTIL_ASSERT(c->fd == fd); + } + return 0; +} + +/** Make sure that the changelist is consistent with the evmap structures. */ +static void +event_changelist_assert_ok(struct event_base *base) +{ + int i; + struct event_changelist *changelist = &base->changelist; + + EVUTIL_ASSERT(changelist->changes_size >= changelist->n_changes); + for (i = 0; i < changelist->n_changes; ++i) { + struct event_change *c = &changelist->changes[i]; + struct event_changelist_fdinfo *f; + EVUTIL_ASSERT(c->fd >= 0); + f = event_change_get_fdinfo(base, c); + EVUTIL_ASSERT(f); + EVUTIL_ASSERT(f->idxplus1 == i + 1); + } + + evmap_io_foreach_fd(base, + event_changelist_assert_ok_foreach_iter_fn, + NULL); +} + +#ifdef DEBUG_CHANGELIST +#define event_changelist_check(base) event_changelist_assert_ok((base)) +#else +#define event_changelist_check(base) ((void)0) +#endif + +void +event_changelist_remove_all_(struct event_changelist *changelist, + struct event_base *base) +{ + int i; + + event_changelist_check(base); + + for (i = 0; i < changelist->n_changes; ++i) { + struct event_change *ch = &changelist->changes[i]; + struct event_changelist_fdinfo *fdinfo = + event_change_get_fdinfo(base, ch); + EVUTIL_ASSERT(fdinfo->idxplus1 == i + 1); + fdinfo->idxplus1 = 0; + } + + changelist->n_changes = 0; + + event_changelist_check(base); +} + +void +event_changelist_freemem_(struct event_changelist *changelist) +{ + if (changelist->changes) + mm_free(changelist->changes); + event_changelist_init_(changelist); /* zero it all out. */ +} + +/** Increase the size of 'changelist' to hold more changes. */ +static int +event_changelist_grow(struct event_changelist *changelist) +{ + int new_size; + struct event_change *new_changes; + if (changelist->changes_size < 64) + new_size = 64; + else + new_size = changelist->changes_size * 2; + + new_changes = mm_realloc(changelist->changes, + new_size * sizeof(struct event_change)); + + if (EVUTIL_UNLIKELY(new_changes == NULL)) + return (-1); + + changelist->changes = new_changes; + changelist->changes_size = new_size; + + return (0); +} + +/** Return a pointer to the changelist entry for the file descriptor or signal + * 'fd', whose fdinfo is 'fdinfo'. If none exists, construct it, setting its + * old_events field to old_events. + */ +static struct event_change * +event_changelist_get_or_construct(struct event_changelist *changelist, + evutil_socket_t fd, + short old_events, + struct event_changelist_fdinfo *fdinfo) +{ + struct event_change *change; + + if (fdinfo->idxplus1 == 0) { + int idx; + EVUTIL_ASSERT(changelist->n_changes <= changelist->changes_size); + + if (changelist->n_changes == changelist->changes_size) { + if (event_changelist_grow(changelist) < 0) + return NULL; + } + + idx = changelist->n_changes++; + change = &changelist->changes[idx]; + fdinfo->idxplus1 = idx + 1; + + memset(change, 0, sizeof(struct event_change)); + change->fd = fd; + change->old_events = old_events; + } else { + change = &changelist->changes[fdinfo->idxplus1 - 1]; + EVUTIL_ASSERT(change->fd == fd); + } + return change; +} + +int +event_changelist_add_(struct event_base *base, evutil_socket_t fd, short old, short events, + void *p) +{ + struct event_changelist *changelist = &base->changelist; + struct event_changelist_fdinfo *fdinfo = p; + struct event_change *change; + + event_changelist_check(base); + + change = event_changelist_get_or_construct(changelist, fd, old, fdinfo); + if (!change) + return -1; + + /* An add replaces any previous delete, but doesn't result in a no-op, + * since the delete might fail (because the fd had been closed since + * the last add, for instance. */ + + if (events & (EV_READ|EV_SIGNAL)) { + change->read_change = EV_CHANGE_ADD | + (events & (EV_ET|EV_PERSIST|EV_SIGNAL)); + } + if (events & EV_WRITE) { + change->write_change = EV_CHANGE_ADD | + (events & (EV_ET|EV_PERSIST|EV_SIGNAL)); + } + if (events & EV_CLOSED) { + change->close_change = EV_CHANGE_ADD | + (events & (EV_ET|EV_PERSIST|EV_SIGNAL)); + } + + event_changelist_check(base); + return (0); +} + +int +event_changelist_del_(struct event_base *base, evutil_socket_t fd, short old, short events, + void *p) +{ + struct event_changelist *changelist = &base->changelist; + struct event_changelist_fdinfo *fdinfo = p; + struct event_change *change; + + event_changelist_check(base); + change = event_changelist_get_or_construct(changelist, fd, old, fdinfo); + event_changelist_check(base); + if (!change) + return -1; + + /* A delete on an event set that doesn't contain the event to be + deleted produces a no-op. This effectively emoves any previous + uncommitted add, rather than replacing it: on those platforms where + "add, delete, dispatch" is not the same as "no-op, dispatch", we + want the no-op behavior. + + If we have a no-op item, we could remove it it from the list + entirely, but really there's not much point: skipping the no-op + change when we do the dispatch later is far cheaper than rejuggling + the array now. + + As this stands, it also lets through deletions of events that are + not currently set. + */ + + if (events & (EV_READ|EV_SIGNAL)) { + if (!(change->old_events & (EV_READ | EV_SIGNAL))) + change->read_change = 0; + else + change->read_change = EV_CHANGE_DEL; + } + if (events & EV_WRITE) { + if (!(change->old_events & EV_WRITE)) + change->write_change = 0; + else + change->write_change = EV_CHANGE_DEL; + } + if (events & EV_CLOSED) { + if (!(change->old_events & EV_CLOSED)) + change->close_change = 0; + else + change->close_change = EV_CHANGE_DEL; + } + + event_changelist_check(base); + return (0); +} + +/* Helper for evmap_check_integrity_: verify that all of the events pending on + * given fd are set up correctly, and that the nread and nwrite counts on that + * fd are correct. */ +static int +evmap_io_check_integrity_fn(struct event_base *base, evutil_socket_t fd, + struct evmap_io *io_info, void *arg) +{ + struct event *ev; + int n_read = 0, n_write = 0, n_close = 0; + + /* First, make sure the list itself isn't corrupt. Otherwise, + * running LIST_FOREACH could be an exciting adventure. */ + EVUTIL_ASSERT_LIST_OK(&io_info->events, event, ev_io_next); + + LIST_FOREACH(ev, &io_info->events, ev_io_next) { + EVUTIL_ASSERT(ev->ev_flags & EVLIST_INSERTED); + EVUTIL_ASSERT(ev->ev_fd == fd); + EVUTIL_ASSERT(!(ev->ev_events & EV_SIGNAL)); + EVUTIL_ASSERT((ev->ev_events & (EV_READ|EV_WRITE|EV_CLOSED))); + if (ev->ev_events & EV_READ) + ++n_read; + if (ev->ev_events & EV_WRITE) + ++n_write; + if (ev->ev_events & EV_CLOSED) + ++n_close; + } + + EVUTIL_ASSERT(n_read == io_info->nread); + EVUTIL_ASSERT(n_write == io_info->nwrite); + EVUTIL_ASSERT(n_close == io_info->nclose); + + return 0; +} + +/* Helper for evmap_check_integrity_: verify that all of the events pending + * on given signal are set up correctly. */ +static int +evmap_signal_check_integrity_fn(struct event_base *base, + int signum, struct evmap_signal *sig_info, void *arg) +{ + struct event *ev; + /* First, make sure the list itself isn't corrupt. */ + EVUTIL_ASSERT_LIST_OK(&sig_info->events, event, ev_signal_next); + + LIST_FOREACH(ev, &sig_info->events, ev_io_next) { + EVUTIL_ASSERT(ev->ev_flags & EVLIST_INSERTED); + EVUTIL_ASSERT(ev->ev_fd == signum); + EVUTIL_ASSERT((ev->ev_events & EV_SIGNAL)); + EVUTIL_ASSERT(!(ev->ev_events & (EV_READ|EV_WRITE|EV_CLOSED))); + } + return 0; +} + +void +evmap_check_integrity_(struct event_base *base) +{ + evmap_io_foreach_fd(base, evmap_io_check_integrity_fn, NULL); + evmap_signal_foreach_signal(base, evmap_signal_check_integrity_fn, NULL); + + if (base->evsel->add == event_changelist_add_) + event_changelist_assert_ok(base); +} + +/* Helper type for evmap_foreach_event_: Bundles a function to call on every + * event, and the user-provided void* to use as its third argument. */ +struct evmap_foreach_event_helper { + event_base_foreach_event_cb fn; + void *arg; +}; + +/* Helper for evmap_foreach_event_: calls a provided function on every event + * pending on a given fd. */ +static int +evmap_io_foreach_event_fn(struct event_base *base, evutil_socket_t fd, + struct evmap_io *io_info, void *arg) +{ + struct evmap_foreach_event_helper *h = arg; + struct event *ev; + int r; + LIST_FOREACH(ev, &io_info->events, ev_io_next) { + if ((r = h->fn(base, ev, h->arg))) + return r; + } + return 0; +} + +/* Helper for evmap_foreach_event_: calls a provided function on every event + * pending on a given signal. */ +static int +evmap_signal_foreach_event_fn(struct event_base *base, int signum, + struct evmap_signal *sig_info, void *arg) +{ + struct event *ev; + struct evmap_foreach_event_helper *h = arg; + int r; + LIST_FOREACH(ev, &sig_info->events, ev_signal_next) { + if ((r = h->fn(base, ev, h->arg))) + return r; + } + return 0; +} + +int +evmap_foreach_event_(struct event_base *base, + event_base_foreach_event_cb fn, void *arg) +{ + struct evmap_foreach_event_helper h; + int r; + h.fn = fn; + h.arg = arg; + if ((r = evmap_io_foreach_fd(base, evmap_io_foreach_event_fn, &h))) + return r; + return evmap_signal_foreach_signal(base, evmap_signal_foreach_event_fn, &h); +} + diff --git a/contrib/ntp/sntp/libevent/evport.c b/contrib/ntp/sntp/libevent/evport.c new file mode 100644 index 000000000..a014386bf --- /dev/null +++ b/contrib/ntp/sntp/libevent/evport.c @@ -0,0 +1,451 @@ +/* + * Submitted by David Pacheco (dp.spambait@gmail.com) + * + * Copyright 2006-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY SUN MICROSYSTEMS, INC. ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL SUN MICROSYSTEMS, INC. BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* + * Copyright (c) 2007 Sun Microsystems. All rights reserved. + * Use is subject to license terms. + */ + +/* + * evport.c: event backend using Solaris 10 event ports. See port_create(3C). + * This implementation is loosely modeled after the one used for select(2) (in + * select.c). + * + * The outstanding events are tracked in a data structure called evport_data. + * Each entry in the ed_fds array corresponds to a file descriptor, and contains + * pointers to the read and write events that correspond to that fd. (That is, + * when the file is readable, the "read" event should handle it, etc.) + * + * evport_add and evport_del update this data structure. evport_dispatch uses it + * to determine where to callback when an event occurs (which it gets from + * port_getn). + * + * Helper functions are used: grow() grows the file descriptor array as + * necessary when large fd's come in. reassociate() takes care of maintaining + * the proper file-descriptor/event-port associations. + * + * As in the select(2) implementation, signals are handled by evsignal. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_EVENT_PORTS + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "event2/thread.h" + +#include "evthread-internal.h" +#include "event-internal.h" +#include "log-internal.h" +#include "evsignal-internal.h" +#include "evmap-internal.h" + +#define INITIAL_EVENTS_PER_GETN 8 +#define MAX_EVENTS_PER_GETN 4096 + +/* + * Per-file-descriptor information about what events we're subscribed to. These + * fields are NULL if no event is subscribed to either of them. + */ + +struct fd_info { + /* combinations of EV_READ and EV_WRITE */ + short fdi_what; + /* Index of this fd within ed_pending, plus 1. Zero if this fd is + * not in ed_pending. (The +1 is a hack so that memset(0) will set + * it to a nil index. */ + int pending_idx_plus_1; +}; + +#define FDI_HAS_READ(fdi) ((fdi)->fdi_what & EV_READ) +#define FDI_HAS_WRITE(fdi) ((fdi)->fdi_what & EV_WRITE) +#define FDI_HAS_EVENTS(fdi) (FDI_HAS_READ(fdi) || FDI_HAS_WRITE(fdi)) +#define FDI_TO_SYSEVENTS(fdi) (FDI_HAS_READ(fdi) ? POLLIN : 0) | \ + (FDI_HAS_WRITE(fdi) ? POLLOUT : 0) + +struct evport_data { + int ed_port; /* event port for system events */ + /* How many elements of ed_pending should we look at? */ + int ed_npending; + /* How many elements are allocated in ed_pending and pevtlist? */ + int ed_maxevents; + /* fdi's that we need to reassoc */ + int *ed_pending; + /* storage space for incoming events. */ + port_event_t *ed_pevtlist; + +}; + +static void* evport_init(struct event_base *); +static int evport_add(struct event_base *, int fd, short old, short events, void *); +static int evport_del(struct event_base *, int fd, short old, short events, void *); +static int evport_dispatch(struct event_base *, struct timeval *); +static void evport_dealloc(struct event_base *); +static int grow(struct evport_data *, int min_events); + +const struct eventop evportops = { + "evport", + evport_init, + evport_add, + evport_del, + evport_dispatch, + evport_dealloc, + 1, /* need reinit */ + 0, /* features */ + sizeof(struct fd_info), /* fdinfo length */ +}; + +/* + * Initialize the event port implementation. + */ + +static void* +evport_init(struct event_base *base) +{ + struct evport_data *evpd; + + if (!(evpd = mm_calloc(1, sizeof(struct evport_data)))) + return (NULL); + + if ((evpd->ed_port = port_create()) == -1) { + mm_free(evpd); + return (NULL); + } + + if (grow(evpd, INITIAL_EVENTS_PER_GETN) < 0) { + close(evpd->ed_port); + mm_free(evpd); + return NULL; + } + + evpd->ed_npending = 0; + + evsig_init_(base); + + return (evpd); +} + +static int +grow(struct evport_data *data, int min_events) +{ + int newsize; + int *new_pending; + port_event_t *new_pevtlist; + if (data->ed_maxevents) { + newsize = data->ed_maxevents; + do { + newsize *= 2; + } while (newsize < min_events); + } else { + newsize = min_events; + } + + new_pending = mm_realloc(data->ed_pending, sizeof(int)*newsize); + if (new_pending == NULL) + return -1; + data->ed_pending = new_pending; + new_pevtlist = mm_realloc(data->ed_pevtlist, sizeof(port_event_t)*newsize); + if (new_pevtlist == NULL) + return -1; + data->ed_pevtlist = new_pevtlist; + + data->ed_maxevents = newsize; + return 0; +} + +#ifdef CHECK_INVARIANTS +/* + * Checks some basic properties about the evport_data structure. Because it + * checks all file descriptors, this function can be expensive when the maximum + * file descriptor ever used is rather large. + */ + +static void +check_evportop(struct evport_data *evpd) +{ + EVUTIL_ASSERT(evpd); + EVUTIL_ASSERT(evpd->ed_port > 0); +} + +/* + * Verifies very basic integrity of a given port_event. + */ +static void +check_event(port_event_t* pevt) +{ + /* + * We've only registered for PORT_SOURCE_FD events. The only + * other thing we can legitimately receive is PORT_SOURCE_ALERT, + * but since we're not using port_alert either, we can assume + * PORT_SOURCE_FD. + */ + EVUTIL_ASSERT(pevt->portev_source == PORT_SOURCE_FD); +} + +#else +#define check_evportop(epop) +#define check_event(pevt) +#endif /* CHECK_INVARIANTS */ + +/* + * (Re)associates the given file descriptor with the event port. The OS events + * are specified (implicitly) from the fd_info struct. + */ +static int +reassociate(struct evport_data *epdp, struct fd_info *fdip, int fd) +{ + int sysevents = FDI_TO_SYSEVENTS(fdip); + + if (sysevents != 0) { + if (port_associate(epdp->ed_port, PORT_SOURCE_FD, + fd, sysevents, fdip) == -1) { + event_warn("port_associate"); + return (-1); + } + } + + check_evportop(epdp); + + return (0); +} + +/* + * Main event loop - polls port_getn for some number of events, and processes + * them. + */ + +static int +evport_dispatch(struct event_base *base, struct timeval *tv) +{ + int i, res; + struct evport_data *epdp = base->evbase; + port_event_t *pevtlist = epdp->ed_pevtlist; + + /* + * port_getn will block until it has at least nevents events. It will + * also return how many it's given us (which may be more than we asked + * for, as long as it's less than our maximum (ed_maxevents)) in + * nevents. + */ + int nevents = 1; + + /* + * We have to convert a struct timeval to a struct timespec + * (only difference is nanoseconds vs. microseconds). If no time-based + * events are active, we should wait for I/O (and tv == NULL). + */ + struct timespec ts; + struct timespec *ts_p = NULL; + if (tv != NULL) { + ts.tv_sec = tv->tv_sec; + ts.tv_nsec = tv->tv_usec * 1000; + ts_p = &ts; + } + + /* + * Before doing anything else, we need to reassociate the events we hit + * last time which need reassociation. See comment at the end of the + * loop below. + */ + for (i = 0; i < epdp->ed_npending; ++i) { + struct fd_info *fdi = NULL; + const int fd = epdp->ed_pending[i]; + if (fd != -1) { + /* We might have cleared out this event; we need + * to be sure that it's still set. */ + fdi = evmap_io_get_fdinfo_(&base->io, fd); + } + + if (fdi != NULL && FDI_HAS_EVENTS(fdi)) { + reassociate(epdp, fdi, fd); + /* epdp->ed_pending[i] = -1; */ + fdi->pending_idx_plus_1 = 0; + } + } + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + res = port_getn(epdp->ed_port, pevtlist, epdp->ed_maxevents, + (unsigned int *) &nevents, ts_p); + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (res == -1) { + if (errno == EINTR || errno == EAGAIN) { + return (0); + } else if (errno == ETIME) { + if (nevents == 0) + return (0); + } else { + event_warn("port_getn"); + return (-1); + } + } + + event_debug(("%s: port_getn reports %d events", __func__, nevents)); + + for (i = 0; i < nevents; ++i) { + port_event_t *pevt = &pevtlist[i]; + int fd = (int) pevt->portev_object; + struct fd_info *fdi = pevt->portev_user; + /*EVUTIL_ASSERT(evmap_io_get_fdinfo_(&base->io, fd) == fdi);*/ + + check_evportop(epdp); + check_event(pevt); + epdp->ed_pending[i] = fd; + fdi->pending_idx_plus_1 = i + 1; + + /* + * Figure out what kind of event it was + * (because we have to pass this to the callback) + */ + res = 0; + if (pevt->portev_events & (POLLERR|POLLHUP)) { + res = EV_READ | EV_WRITE; + } else { + if (pevt->portev_events & POLLIN) + res |= EV_READ; + if (pevt->portev_events & POLLOUT) + res |= EV_WRITE; + } + + /* + * Check for the error situations or a hangup situation + */ + if (pevt->portev_events & (POLLERR|POLLHUP|POLLNVAL)) + res |= EV_READ|EV_WRITE; + + evmap_io_active_(base, fd, res); + } /* end of all events gotten */ + epdp->ed_npending = nevents; + + if (nevents == epdp->ed_maxevents && + epdp->ed_maxevents < MAX_EVENTS_PER_GETN) { + /* we used all the space this time. We should be ready + * for more events next time around. */ + grow(epdp, epdp->ed_maxevents * 2); + } + + check_evportop(epdp); + + return (0); +} + + +/* + * Adds the given event (so that you will be notified when it happens via + * the callback function). + */ + +static int +evport_add(struct event_base *base, int fd, short old, short events, void *p) +{ + struct evport_data *evpd = base->evbase; + struct fd_info *fdi = p; + + check_evportop(evpd); + + fdi->fdi_what |= events; + + return reassociate(evpd, fdi, fd); +} + +/* + * Removes the given event from the list of events to wait for. + */ + +static int +evport_del(struct event_base *base, int fd, short old, short events, void *p) +{ + struct evport_data *evpd = base->evbase; + struct fd_info *fdi = p; + int associated = ! fdi->pending_idx_plus_1; + + check_evportop(evpd); + + fdi->fdi_what &= ~(events &(EV_READ|EV_WRITE)); + + if (associated) { + if (!FDI_HAS_EVENTS(fdi) && + port_dissociate(evpd->ed_port, PORT_SOURCE_FD, fd) == -1) { + /* + * Ignore EBADFD error the fd could have been closed + * before event_del() was called. + */ + if (errno != EBADFD) { + event_warn("port_dissociate"); + return (-1); + } + } else { + if (FDI_HAS_EVENTS(fdi)) { + return (reassociate(evpd, fdi, fd)); + } + } + } else { + if ((fdi->fdi_what & (EV_READ|EV_WRITE)) == 0) { + const int i = fdi->pending_idx_plus_1 - 1; + EVUTIL_ASSERT(evpd->ed_pending[i] == fd); + evpd->ed_pending[i] = -1; + fdi->pending_idx_plus_1 = 0; + } + } + return 0; +} + + +static void +evport_dealloc(struct event_base *base) +{ + struct evport_data *evpd = base->evbase; + + evsig_dealloc_(base); + + close(evpd->ed_port); + + if (evpd->ed_pending) + mm_free(evpd->ed_pending); + if (evpd->ed_pevtlist) + mm_free(evpd->ed_pevtlist); + + mm_free(evpd); +} + +#endif /* EVENT__HAVE_EVENT_PORTS */ diff --git a/contrib/ntp/sntp/libevent/evrpc-internal.h b/contrib/ntp/sntp/libevent/evrpc-internal.h new file mode 100644 index 000000000..9eb376386 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evrpc-internal.h @@ -0,0 +1,205 @@ +/* + * Copyright (c) 2006-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVRPC_INTERNAL_H_INCLUDED_ +#define EVRPC_INTERNAL_H_INCLUDED_ + +#include "event2/http.h" +#include "http-internal.h" + +struct evrpc; +struct evrpc_request_wrapper; + +#define EVRPC_URI_PREFIX "/.rpc." + +struct evrpc_hook { + TAILQ_ENTRY(evrpc_hook) next; + + /* returns EVRPC_TERMINATE; if the rpc should be aborted. + * a hook is is allowed to rewrite the evbuffer + */ + int (*process)(void *, struct evhttp_request *, + struct evbuffer *, void *); + void *process_arg; +}; + +TAILQ_HEAD(evrpc_hook_list, evrpc_hook); + +/* + * this is shared between the base and the pool, so that we can reuse + * the hook adding functions; we alias both evrpc_pool and evrpc_base + * to this common structure. + */ + +struct evrpc_hook_ctx; +TAILQ_HEAD(evrpc_pause_list, evrpc_hook_ctx); + +struct evrpc_hooks_ { + /* hooks for processing outbound and inbound rpcs */ + struct evrpc_hook_list in_hooks; + struct evrpc_hook_list out_hooks; + + struct evrpc_pause_list pause_requests; +}; + +#define input_hooks common.in_hooks +#define output_hooks common.out_hooks +#define paused_requests common.pause_requests + +struct evrpc_base { + struct evrpc_hooks_ common; + + /* the HTTP server under which we register our RPC calls */ + struct evhttp* http_server; + + /* a list of all RPCs registered with us */ + TAILQ_HEAD(evrpc_list, evrpc) registered_rpcs; +}; + +struct evrpc_req_generic; +void evrpc_reqstate_free_(struct evrpc_req_generic* rpc_state); + +/* A pool for holding evhttp_connection objects */ +struct evrpc_pool { + struct evrpc_hooks_ common; + + struct event_base *base; + + struct evconq connections; + + int timeout; + + TAILQ_HEAD(evrpc_requestq, evrpc_request_wrapper) (requests); +}; + +struct evrpc_hook_ctx { + TAILQ_ENTRY(evrpc_hook_ctx) next; + + void *ctx; + void (*cb)(void *, enum EVRPC_HOOK_RESULT); +}; + +struct evrpc_meta { + TAILQ_ENTRY(evrpc_meta) next; + char *key; + + void *data; + size_t data_size; +}; + +TAILQ_HEAD(evrpc_meta_list, evrpc_meta); + +struct evrpc_hook_meta { + struct evrpc_meta_list meta_data; + struct evhttp_connection *evcon; +}; + +/* allows association of meta data with a request */ +static void evrpc_hook_associate_meta_(struct evrpc_hook_meta **pctx, + struct evhttp_connection *evcon); + +/* creates a new meta data store */ +static struct evrpc_hook_meta *evrpc_hook_meta_new_(void); + +/* frees the meta data associated with a request */ +static void evrpc_hook_context_free_(struct evrpc_hook_meta *ctx); + +/* the server side of an rpc */ + +/* We alias the RPC specific structs to this voided one */ +struct evrpc_req_generic { + /* + * allows association of meta data via hooks - needs to be + * synchronized with evrpc_request_wrapper + */ + struct evrpc_hook_meta *hook_meta; + + /* the unmarshaled request object */ + void *request; + + /* the empty reply object that needs to be filled in */ + void *reply; + + /* + * the static structure for this rpc; that can be used to + * automatically unmarshal and marshal the http buffers. + */ + struct evrpc *rpc; + + /* + * the http request structure on which we need to answer. + */ + struct evhttp_request* http_req; + + /* + * Temporary data store for marshaled data + */ + struct evbuffer* rpc_data; +}; + +/* the client side of an rpc request */ +struct evrpc_request_wrapper { + /* + * allows association of meta data via hooks - needs to be + * synchronized with evrpc_req_generic. + */ + struct evrpc_hook_meta *hook_meta; + + TAILQ_ENTRY(evrpc_request_wrapper) next; + + /* pool on which this rpc request is being made */ + struct evrpc_pool *pool; + + /* connection on which the request is being sent */ + struct evhttp_connection *evcon; + + /* the actual request */ + struct evhttp_request *req; + + /* event for implementing request timeouts */ + struct event ev_timeout; + + /* the name of the rpc */ + char *name; + + /* callback */ + void (*cb)(struct evrpc_status*, void *request, void *reply, void *arg); + void *cb_arg; + + void *request; + void *reply; + + /* unmarshals the buffer into the proper request structure */ + void (*request_marshal)(struct evbuffer *, void *); + + /* removes all stored state in the reply */ + void (*reply_clear)(void *); + + /* marshals the reply into a buffer */ + int (*reply_unmarshal)(void *, struct evbuffer*); +}; + +#endif /* EVRPC_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/evrpc.c b/contrib/ntp/sntp/libevent/evrpc.c new file mode 100644 index 000000000..2443ab279 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evrpc.c @@ -0,0 +1,1171 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#define WIN32_LEAN_AND_MEAN +#include +#include +#undef WIN32_LEAN_AND_MEAN +#endif + +#include +#ifndef _WIN32 +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#include +#include +#ifndef _WIN32 +#include +#endif +#include +#include +#include + +#include + +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/rpc.h" +#include "event2/rpc_struct.h" +#include "evrpc-internal.h" +#include "event2/http.h" +#include "event2/buffer.h" +#include "event2/tag.h" +#include "event2/http_struct.h" +#include "event2/http_compat.h" +#include "event2/util.h" +#include "util-internal.h" +#include "log-internal.h" +#include "mm-internal.h" + +struct evrpc_base * +evrpc_init(struct evhttp *http_server) +{ + struct evrpc_base* base = mm_calloc(1, sizeof(struct evrpc_base)); + if (base == NULL) + return (NULL); + + /* we rely on the tagging sub system */ + evtag_init(); + + TAILQ_INIT(&base->registered_rpcs); + TAILQ_INIT(&base->input_hooks); + TAILQ_INIT(&base->output_hooks); + + TAILQ_INIT(&base->paused_requests); + + base->http_server = http_server; + + return (base); +} + +void +evrpc_free(struct evrpc_base *base) +{ + struct evrpc *rpc; + struct evrpc_hook *hook; + struct evrpc_hook_ctx *pause; + int r; + + while ((rpc = TAILQ_FIRST(&base->registered_rpcs)) != NULL) { + r = evrpc_unregister_rpc(base, rpc->uri); + EVUTIL_ASSERT(r == 0); + } + while ((pause = TAILQ_FIRST(&base->paused_requests)) != NULL) { + TAILQ_REMOVE(&base->paused_requests, pause, next); + mm_free(pause); + } + while ((hook = TAILQ_FIRST(&base->input_hooks)) != NULL) { + r = evrpc_remove_hook(base, EVRPC_INPUT, hook); + EVUTIL_ASSERT(r); + } + while ((hook = TAILQ_FIRST(&base->output_hooks)) != NULL) { + r = evrpc_remove_hook(base, EVRPC_OUTPUT, hook); + EVUTIL_ASSERT(r); + } + mm_free(base); +} + +void * +evrpc_add_hook(void *vbase, + enum EVRPC_HOOK_TYPE hook_type, + int (*cb)(void *, struct evhttp_request *, struct evbuffer *, void *), + void *cb_arg) +{ + struct evrpc_hooks_ *base = vbase; + struct evrpc_hook_list *head = NULL; + struct evrpc_hook *hook = NULL; + switch (hook_type) { + case EVRPC_INPUT: + head = &base->in_hooks; + break; + case EVRPC_OUTPUT: + head = &base->out_hooks; + break; + default: + EVUTIL_ASSERT(hook_type == EVRPC_INPUT || hook_type == EVRPC_OUTPUT); + } + + hook = mm_calloc(1, sizeof(struct evrpc_hook)); + EVUTIL_ASSERT(hook != NULL); + + hook->process = cb; + hook->process_arg = cb_arg; + TAILQ_INSERT_TAIL(head, hook, next); + + return (hook); +} + +static int +evrpc_remove_hook_internal(struct evrpc_hook_list *head, void *handle) +{ + struct evrpc_hook *hook = NULL; + TAILQ_FOREACH(hook, head, next) { + if (hook == handle) { + TAILQ_REMOVE(head, hook, next); + mm_free(hook); + return (1); + } + } + + return (0); +} + +/* + * remove the hook specified by the handle + */ + +int +evrpc_remove_hook(void *vbase, enum EVRPC_HOOK_TYPE hook_type, void *handle) +{ + struct evrpc_hooks_ *base = vbase; + struct evrpc_hook_list *head = NULL; + switch (hook_type) { + case EVRPC_INPUT: + head = &base->in_hooks; + break; + case EVRPC_OUTPUT: + head = &base->out_hooks; + break; + default: + EVUTIL_ASSERT(hook_type == EVRPC_INPUT || hook_type == EVRPC_OUTPUT); + } + + return (evrpc_remove_hook_internal(head, handle)); +} + +static int +evrpc_process_hooks(struct evrpc_hook_list *head, void *ctx, + struct evhttp_request *req, struct evbuffer *evbuf) +{ + struct evrpc_hook *hook; + TAILQ_FOREACH(hook, head, next) { + int res = hook->process(ctx, req, evbuf, hook->process_arg); + if (res != EVRPC_CONTINUE) + return (res); + } + + return (EVRPC_CONTINUE); +} + +static void evrpc_pool_schedule(struct evrpc_pool *pool); +static void evrpc_request_cb(struct evhttp_request *, void *); + +/* + * Registers a new RPC with the HTTP server. The evrpc object is expected + * to have been filled in via the EVRPC_REGISTER_OBJECT macro which in turn + * calls this function. + */ + +static char * +evrpc_construct_uri(const char *uri) +{ + char *constructed_uri; + size_t constructed_uri_len; + + constructed_uri_len = strlen(EVRPC_URI_PREFIX) + strlen(uri) + 1; + if ((constructed_uri = mm_malloc(constructed_uri_len)) == NULL) + event_err(1, "%s: failed to register rpc at %s", + __func__, uri); + memcpy(constructed_uri, EVRPC_URI_PREFIX, strlen(EVRPC_URI_PREFIX)); + memcpy(constructed_uri + strlen(EVRPC_URI_PREFIX), uri, strlen(uri)); + constructed_uri[constructed_uri_len - 1] = '\0'; + + return (constructed_uri); +} + +int +evrpc_register_rpc(struct evrpc_base *base, struct evrpc *rpc, + void (*cb)(struct evrpc_req_generic *, void *), void *cb_arg) +{ + char *constructed_uri = evrpc_construct_uri(rpc->uri); + + rpc->base = base; + rpc->cb = cb; + rpc->cb_arg = cb_arg; + + TAILQ_INSERT_TAIL(&base->registered_rpcs, rpc, next); + + evhttp_set_cb(base->http_server, + constructed_uri, + evrpc_request_cb, + rpc); + + mm_free(constructed_uri); + + return (0); +} + +int +evrpc_unregister_rpc(struct evrpc_base *base, const char *name) +{ + char *registered_uri = NULL; + struct evrpc *rpc; + int r; + + /* find the right rpc; linear search might be slow */ + TAILQ_FOREACH(rpc, &base->registered_rpcs, next) { + if (strcmp(rpc->uri, name) == 0) + break; + } + if (rpc == NULL) { + /* We did not find an RPC with this name */ + return (-1); + } + TAILQ_REMOVE(&base->registered_rpcs, rpc, next); + + registered_uri = evrpc_construct_uri(name); + + /* remove the http server callback */ + r = evhttp_del_cb(base->http_server, registered_uri); + EVUTIL_ASSERT(r == 0); + + mm_free(registered_uri); + + mm_free((char *)rpc->uri); + mm_free(rpc); + return (0); +} + +static int evrpc_pause_request(void *vbase, void *ctx, + void (*cb)(void *, enum EVRPC_HOOK_RESULT)); +static void evrpc_request_cb_closure(void *, enum EVRPC_HOOK_RESULT); + +static void +evrpc_request_cb(struct evhttp_request *req, void *arg) +{ + struct evrpc *rpc = arg; + struct evrpc_req_generic *rpc_state = NULL; + + /* let's verify the outside parameters */ + if (req->type != EVHTTP_REQ_POST || + evbuffer_get_length(req->input_buffer) <= 0) + goto error; + + rpc_state = mm_calloc(1, sizeof(struct evrpc_req_generic)); + if (rpc_state == NULL) + goto error; + rpc_state->rpc = rpc; + rpc_state->http_req = req; + rpc_state->rpc_data = NULL; + + if (TAILQ_FIRST(&rpc->base->input_hooks) != NULL) { + int hook_res; + + evrpc_hook_associate_meta_(&rpc_state->hook_meta, req->evcon); + + /* + * allow hooks to modify the outgoing request + */ + hook_res = evrpc_process_hooks(&rpc->base->input_hooks, + rpc_state, req, req->input_buffer); + switch (hook_res) { + case EVRPC_TERMINATE: + goto error; + case EVRPC_PAUSE: + evrpc_pause_request(rpc->base, rpc_state, + evrpc_request_cb_closure); + return; + case EVRPC_CONTINUE: + break; + default: + EVUTIL_ASSERT(hook_res == EVRPC_TERMINATE || + hook_res == EVRPC_CONTINUE || + hook_res == EVRPC_PAUSE); + } + } + + evrpc_request_cb_closure(rpc_state, EVRPC_CONTINUE); + return; + +error: + evrpc_reqstate_free_(rpc_state); + evhttp_send_error(req, HTTP_SERVUNAVAIL, NULL); + return; +} + +static void +evrpc_request_cb_closure(void *arg, enum EVRPC_HOOK_RESULT hook_res) +{ + struct evrpc_req_generic *rpc_state = arg; + struct evrpc *rpc; + struct evhttp_request *req; + + EVUTIL_ASSERT(rpc_state); + rpc = rpc_state->rpc; + req = rpc_state->http_req; + + if (hook_res == EVRPC_TERMINATE) + goto error; + + /* let's check that we can parse the request */ + rpc_state->request = rpc->request_new(rpc->request_new_arg); + if (rpc_state->request == NULL) + goto error; + + if (rpc->request_unmarshal( + rpc_state->request, req->input_buffer) == -1) { + /* we failed to parse the request; that's a bummer */ + goto error; + } + + /* at this point, we have a well formed request, prepare the reply */ + + rpc_state->reply = rpc->reply_new(rpc->reply_new_arg); + if (rpc_state->reply == NULL) + goto error; + + /* give the rpc to the user; they can deal with it */ + rpc->cb(rpc_state, rpc->cb_arg); + + return; + +error: + evrpc_reqstate_free_(rpc_state); + evhttp_send_error(req, HTTP_SERVUNAVAIL, NULL); + return; +} + + +void +evrpc_reqstate_free_(struct evrpc_req_generic* rpc_state) +{ + struct evrpc *rpc; + EVUTIL_ASSERT(rpc_state != NULL); + rpc = rpc_state->rpc; + + /* clean up all memory */ + if (rpc_state->hook_meta != NULL) + evrpc_hook_context_free_(rpc_state->hook_meta); + if (rpc_state->request != NULL) + rpc->request_free(rpc_state->request); + if (rpc_state->reply != NULL) + rpc->reply_free(rpc_state->reply); + if (rpc_state->rpc_data != NULL) + evbuffer_free(rpc_state->rpc_data); + mm_free(rpc_state); +} + +static void +evrpc_request_done_closure(void *, enum EVRPC_HOOK_RESULT); + +void +evrpc_request_done(struct evrpc_req_generic *rpc_state) +{ + struct evhttp_request *req; + struct evrpc *rpc; + + EVUTIL_ASSERT(rpc_state); + + req = rpc_state->http_req; + rpc = rpc_state->rpc; + + if (rpc->reply_complete(rpc_state->reply) == -1) { + /* the reply was not completely filled in. error out */ + goto error; + } + + if ((rpc_state->rpc_data = evbuffer_new()) == NULL) { + /* out of memory */ + goto error; + } + + /* serialize the reply */ + rpc->reply_marshal(rpc_state->rpc_data, rpc_state->reply); + + if (TAILQ_FIRST(&rpc->base->output_hooks) != NULL) { + int hook_res; + + evrpc_hook_associate_meta_(&rpc_state->hook_meta, req->evcon); + + /* do hook based tweaks to the request */ + hook_res = evrpc_process_hooks(&rpc->base->output_hooks, + rpc_state, req, rpc_state->rpc_data); + switch (hook_res) { + case EVRPC_TERMINATE: + goto error; + case EVRPC_PAUSE: + if (evrpc_pause_request(rpc->base, rpc_state, + evrpc_request_done_closure) == -1) + goto error; + return; + case EVRPC_CONTINUE: + break; + default: + EVUTIL_ASSERT(hook_res == EVRPC_TERMINATE || + hook_res == EVRPC_CONTINUE || + hook_res == EVRPC_PAUSE); + } + } + + evrpc_request_done_closure(rpc_state, EVRPC_CONTINUE); + return; + +error: + evrpc_reqstate_free_(rpc_state); + evhttp_send_error(req, HTTP_SERVUNAVAIL, NULL); + return; +} + +void * +evrpc_get_request(struct evrpc_req_generic *req) +{ + return req->request; +} + +void * +evrpc_get_reply(struct evrpc_req_generic *req) +{ + return req->reply; +} + +static void +evrpc_request_done_closure(void *arg, enum EVRPC_HOOK_RESULT hook_res) +{ + struct evrpc_req_generic *rpc_state = arg; + struct evhttp_request *req; + EVUTIL_ASSERT(rpc_state); + req = rpc_state->http_req; + + if (hook_res == EVRPC_TERMINATE) + goto error; + + /* on success, we are going to transmit marshaled binary data */ + if (evhttp_find_header(req->output_headers, "Content-Type") == NULL) { + evhttp_add_header(req->output_headers, + "Content-Type", "application/octet-stream"); + } + evhttp_send_reply(req, HTTP_OK, "OK", rpc_state->rpc_data); + + evrpc_reqstate_free_(rpc_state); + + return; + +error: + evrpc_reqstate_free_(rpc_state); + evhttp_send_error(req, HTTP_SERVUNAVAIL, NULL); + return; +} + + +/* Client implementation of RPC site */ + +static int evrpc_schedule_request(struct evhttp_connection *connection, + struct evrpc_request_wrapper *ctx); + +struct evrpc_pool * +evrpc_pool_new(struct event_base *base) +{ + struct evrpc_pool *pool = mm_calloc(1, sizeof(struct evrpc_pool)); + if (pool == NULL) + return (NULL); + + TAILQ_INIT(&pool->connections); + TAILQ_INIT(&pool->requests); + + TAILQ_INIT(&pool->paused_requests); + + TAILQ_INIT(&pool->input_hooks); + TAILQ_INIT(&pool->output_hooks); + + pool->base = base; + pool->timeout = -1; + + return (pool); +} + +static void +evrpc_request_wrapper_free(struct evrpc_request_wrapper *request) +{ + if (request->hook_meta != NULL) + evrpc_hook_context_free_(request->hook_meta); + mm_free(request->name); + mm_free(request); +} + +void +evrpc_pool_free(struct evrpc_pool *pool) +{ + struct evhttp_connection *connection; + struct evrpc_request_wrapper *request; + struct evrpc_hook_ctx *pause; + struct evrpc_hook *hook; + int r; + + while ((request = TAILQ_FIRST(&pool->requests)) != NULL) { + TAILQ_REMOVE(&pool->requests, request, next); + evrpc_request_wrapper_free(request); + } + + while ((pause = TAILQ_FIRST(&pool->paused_requests)) != NULL) { + TAILQ_REMOVE(&pool->paused_requests, pause, next); + mm_free(pause); + } + + while ((connection = TAILQ_FIRST(&pool->connections)) != NULL) { + TAILQ_REMOVE(&pool->connections, connection, next); + evhttp_connection_free(connection); + } + + while ((hook = TAILQ_FIRST(&pool->input_hooks)) != NULL) { + r = evrpc_remove_hook(pool, EVRPC_INPUT, hook); + EVUTIL_ASSERT(r); + } + + while ((hook = TAILQ_FIRST(&pool->output_hooks)) != NULL) { + r = evrpc_remove_hook(pool, EVRPC_OUTPUT, hook); + EVUTIL_ASSERT(r); + } + + mm_free(pool); +} + +/* + * Add a connection to the RPC pool. A request scheduled on the pool + * may use any available connection. + */ + +void +evrpc_pool_add_connection(struct evrpc_pool *pool, + struct evhttp_connection *connection) +{ + EVUTIL_ASSERT(connection->http_server == NULL); + TAILQ_INSERT_TAIL(&pool->connections, connection, next); + + /* + * associate an event base with this connection + */ + if (pool->base != NULL) + evhttp_connection_set_base(connection, pool->base); + + /* + * unless a timeout was specifically set for a connection, + * the connection inherits the timeout from the pool. + */ + if (!evutil_timerisset(&connection->timeout)) + evhttp_connection_set_timeout(connection, pool->timeout); + + /* + * if we have any requests pending, schedule them with the new + * connections. + */ + + if (TAILQ_FIRST(&pool->requests) != NULL) { + struct evrpc_request_wrapper *request = + TAILQ_FIRST(&pool->requests); + TAILQ_REMOVE(&pool->requests, request, next); + evrpc_schedule_request(connection, request); + } +} + +void +evrpc_pool_remove_connection(struct evrpc_pool *pool, + struct evhttp_connection *connection) +{ + TAILQ_REMOVE(&pool->connections, connection, next); +} + +void +evrpc_pool_set_timeout(struct evrpc_pool *pool, int timeout_in_secs) +{ + struct evhttp_connection *evcon; + TAILQ_FOREACH(evcon, &pool->connections, next) { + evhttp_connection_set_timeout(evcon, timeout_in_secs); + } + pool->timeout = timeout_in_secs; +} + + +static void evrpc_reply_done(struct evhttp_request *, void *); +static void evrpc_request_timeout(evutil_socket_t, short, void *); + +/* + * Finds a connection object associated with the pool that is currently + * idle and can be used to make a request. + */ +static struct evhttp_connection * +evrpc_pool_find_connection(struct evrpc_pool *pool) +{ + struct evhttp_connection *connection; + TAILQ_FOREACH(connection, &pool->connections, next) { + if (TAILQ_FIRST(&connection->requests) == NULL) + return (connection); + } + + return (NULL); +} + +/* + * Prototypes responsible for evrpc scheduling and hooking + */ + +static void evrpc_schedule_request_closure(void *ctx, enum EVRPC_HOOK_RESULT); + +/* + * We assume that the ctx is no longer queued on the pool. + */ +static int +evrpc_schedule_request(struct evhttp_connection *connection, + struct evrpc_request_wrapper *ctx) +{ + struct evhttp_request *req = NULL; + struct evrpc_pool *pool = ctx->pool; + struct evrpc_status status; + + if ((req = evhttp_request_new(evrpc_reply_done, ctx)) == NULL) + goto error; + + /* serialize the request data into the output buffer */ + ctx->request_marshal(req->output_buffer, ctx->request); + + /* we need to know the connection that we might have to abort */ + ctx->evcon = connection; + + /* if we get paused we also need to know the request */ + ctx->req = req; + + if (TAILQ_FIRST(&pool->output_hooks) != NULL) { + int hook_res; + + evrpc_hook_associate_meta_(&ctx->hook_meta, connection); + + /* apply hooks to the outgoing request */ + hook_res = evrpc_process_hooks(&pool->output_hooks, + ctx, req, req->output_buffer); + + switch (hook_res) { + case EVRPC_TERMINATE: + goto error; + case EVRPC_PAUSE: + /* we need to be explicitly resumed */ + if (evrpc_pause_request(pool, ctx, + evrpc_schedule_request_closure) == -1) + goto error; + return (0); + case EVRPC_CONTINUE: + /* we can just continue */ + break; + default: + EVUTIL_ASSERT(hook_res == EVRPC_TERMINATE || + hook_res == EVRPC_CONTINUE || + hook_res == EVRPC_PAUSE); + } + } + + evrpc_schedule_request_closure(ctx, EVRPC_CONTINUE); + return (0); + +error: + memset(&status, 0, sizeof(status)); + status.error = EVRPC_STATUS_ERR_UNSTARTED; + (*ctx->cb)(&status, ctx->request, ctx->reply, ctx->cb_arg); + evrpc_request_wrapper_free(ctx); + return (-1); +} + +static void +evrpc_schedule_request_closure(void *arg, enum EVRPC_HOOK_RESULT hook_res) +{ + struct evrpc_request_wrapper *ctx = arg; + struct evhttp_connection *connection = ctx->evcon; + struct evhttp_request *req = ctx->req; + struct evrpc_pool *pool = ctx->pool; + struct evrpc_status status; + char *uri = NULL; + int res = 0; + + if (hook_res == EVRPC_TERMINATE) + goto error; + + uri = evrpc_construct_uri(ctx->name); + if (uri == NULL) + goto error; + + if (pool->timeout > 0) { + /* + * a timeout after which the whole rpc is going to be aborted. + */ + struct timeval tv; + evutil_timerclear(&tv); + tv.tv_sec = pool->timeout; + evtimer_add(&ctx->ev_timeout, &tv); + } + + /* start the request over the connection */ + res = evhttp_make_request(connection, req, EVHTTP_REQ_POST, uri); + mm_free(uri); + + if (res == -1) + goto error; + + return; + +error: + memset(&status, 0, sizeof(status)); + status.error = EVRPC_STATUS_ERR_UNSTARTED; + (*ctx->cb)(&status, ctx->request, ctx->reply, ctx->cb_arg); + evrpc_request_wrapper_free(ctx); +} + +/* we just queue the paused request on the pool under the req object */ +static int +evrpc_pause_request(void *vbase, void *ctx, + void (*cb)(void *, enum EVRPC_HOOK_RESULT)) +{ + struct evrpc_hooks_ *base = vbase; + struct evrpc_hook_ctx *pause = mm_malloc(sizeof(*pause)); + if (pause == NULL) + return (-1); + + pause->ctx = ctx; + pause->cb = cb; + + TAILQ_INSERT_TAIL(&base->pause_requests, pause, next); + return (0); +} + +int +evrpc_resume_request(void *vbase, void *ctx, enum EVRPC_HOOK_RESULT res) +{ + struct evrpc_hooks_ *base = vbase; + struct evrpc_pause_list *head = &base->pause_requests; + struct evrpc_hook_ctx *pause; + + TAILQ_FOREACH(pause, head, next) { + if (pause->ctx == ctx) + break; + } + + if (pause == NULL) + return (-1); + + (*pause->cb)(pause->ctx, res); + TAILQ_REMOVE(head, pause, next); + mm_free(pause); + return (0); +} + +int +evrpc_make_request(struct evrpc_request_wrapper *ctx) +{ + struct evrpc_pool *pool = ctx->pool; + + /* initialize the event structure for this rpc */ + evtimer_assign(&ctx->ev_timeout, pool->base, evrpc_request_timeout, ctx); + + /* we better have some available connections on the pool */ + EVUTIL_ASSERT(TAILQ_FIRST(&pool->connections) != NULL); + + /* + * if no connection is available, we queue the request on the pool, + * the next time a connection is empty, the rpc will be send on that. + */ + TAILQ_INSERT_TAIL(&pool->requests, ctx, next); + + evrpc_pool_schedule(pool); + + return (0); +} + + +struct evrpc_request_wrapper * +evrpc_make_request_ctx( + struct evrpc_pool *pool, void *request, void *reply, + const char *rpcname, + void (*req_marshal)(struct evbuffer*, void *), + void (*rpl_clear)(void *), + int (*rpl_unmarshal)(void *, struct evbuffer *), + void (*cb)(struct evrpc_status *, void *, void *, void *), + void *cbarg) +{ + struct evrpc_request_wrapper *ctx = (struct evrpc_request_wrapper *) + mm_malloc(sizeof(struct evrpc_request_wrapper)); + if (ctx == NULL) + return (NULL); + + ctx->pool = pool; + ctx->hook_meta = NULL; + ctx->evcon = NULL; + ctx->name = mm_strdup(rpcname); + if (ctx->name == NULL) { + mm_free(ctx); + return (NULL); + } + ctx->cb = cb; + ctx->cb_arg = cbarg; + ctx->request = request; + ctx->reply = reply; + ctx->request_marshal = req_marshal; + ctx->reply_clear = rpl_clear; + ctx->reply_unmarshal = rpl_unmarshal; + + return (ctx); +} + +static void +evrpc_reply_done_closure(void *, enum EVRPC_HOOK_RESULT); + +static void +evrpc_reply_done(struct evhttp_request *req, void *arg) +{ + struct evrpc_request_wrapper *ctx = arg; + struct evrpc_pool *pool = ctx->pool; + int hook_res = EVRPC_CONTINUE; + + /* cancel any timeout we might have scheduled */ + event_del(&ctx->ev_timeout); + + ctx->req = req; + + /* we need to get the reply now */ + if (req == NULL) { + evrpc_reply_done_closure(ctx, EVRPC_CONTINUE); + return; + } + + if (TAILQ_FIRST(&pool->input_hooks) != NULL) { + evrpc_hook_associate_meta_(&ctx->hook_meta, ctx->evcon); + + /* apply hooks to the incoming request */ + hook_res = evrpc_process_hooks(&pool->input_hooks, + ctx, req, req->input_buffer); + + switch (hook_res) { + case EVRPC_TERMINATE: + case EVRPC_CONTINUE: + break; + case EVRPC_PAUSE: + /* + * if we get paused we also need to know the + * request. unfortunately, the underlying + * layer is going to free it. we need to + * request ownership explicitly + */ + if (req != NULL) + evhttp_request_own(req); + + evrpc_pause_request(pool, ctx, + evrpc_reply_done_closure); + return; + default: + EVUTIL_ASSERT(hook_res == EVRPC_TERMINATE || + hook_res == EVRPC_CONTINUE || + hook_res == EVRPC_PAUSE); + } + } + + evrpc_reply_done_closure(ctx, hook_res); + + /* http request is being freed by underlying layer */ +} + +static void +evrpc_reply_done_closure(void *arg, enum EVRPC_HOOK_RESULT hook_res) +{ + struct evrpc_request_wrapper *ctx = arg; + struct evhttp_request *req = ctx->req; + struct evrpc_pool *pool = ctx->pool; + struct evrpc_status status; + int res = -1; + + memset(&status, 0, sizeof(status)); + status.http_req = req; + + /* we need to get the reply now */ + if (req == NULL) { + status.error = EVRPC_STATUS_ERR_TIMEOUT; + } else if (hook_res == EVRPC_TERMINATE) { + status.error = EVRPC_STATUS_ERR_HOOKABORTED; + } else { + res = ctx->reply_unmarshal(ctx->reply, req->input_buffer); + if (res == -1) + status.error = EVRPC_STATUS_ERR_BADPAYLOAD; + } + + if (res == -1) { + /* clear everything that we might have written previously */ + ctx->reply_clear(ctx->reply); + } + + (*ctx->cb)(&status, ctx->request, ctx->reply, ctx->cb_arg); + + evrpc_request_wrapper_free(ctx); + + /* the http layer owned the original request structure, but if we + * got paused, we asked for ownership and need to free it here. */ + if (req != NULL && evhttp_request_is_owned(req)) + evhttp_request_free(req); + + /* see if we can schedule another request */ + evrpc_pool_schedule(pool); +} + +static void +evrpc_pool_schedule(struct evrpc_pool *pool) +{ + struct evrpc_request_wrapper *ctx = TAILQ_FIRST(&pool->requests); + struct evhttp_connection *evcon; + + /* if no requests are pending, we have no work */ + if (ctx == NULL) + return; + + if ((evcon = evrpc_pool_find_connection(pool)) != NULL) { + TAILQ_REMOVE(&pool->requests, ctx, next); + evrpc_schedule_request(evcon, ctx); + } +} + +static void +evrpc_request_timeout(evutil_socket_t fd, short what, void *arg) +{ + struct evrpc_request_wrapper *ctx = arg; + struct evhttp_connection *evcon = ctx->evcon; + EVUTIL_ASSERT(evcon != NULL); + + evhttp_connection_fail_(evcon, EVREQ_HTTP_TIMEOUT); +} + +/* + * frees potential meta data associated with a request. + */ + +static void +evrpc_meta_data_free(struct evrpc_meta_list *meta_data) +{ + struct evrpc_meta *entry; + EVUTIL_ASSERT(meta_data != NULL); + + while ((entry = TAILQ_FIRST(meta_data)) != NULL) { + TAILQ_REMOVE(meta_data, entry, next); + mm_free(entry->key); + mm_free(entry->data); + mm_free(entry); + } +} + +static struct evrpc_hook_meta * +evrpc_hook_meta_new_(void) +{ + struct evrpc_hook_meta *ctx; + ctx = mm_malloc(sizeof(struct evrpc_hook_meta)); + EVUTIL_ASSERT(ctx != NULL); + + TAILQ_INIT(&ctx->meta_data); + ctx->evcon = NULL; + + return (ctx); +} + +static void +evrpc_hook_associate_meta_(struct evrpc_hook_meta **pctx, + struct evhttp_connection *evcon) +{ + struct evrpc_hook_meta *ctx = *pctx; + if (ctx == NULL) + *pctx = ctx = evrpc_hook_meta_new_(); + ctx->evcon = evcon; +} + +static void +evrpc_hook_context_free_(struct evrpc_hook_meta *ctx) +{ + evrpc_meta_data_free(&ctx->meta_data); + mm_free(ctx); +} + +/* Adds meta data */ +void +evrpc_hook_add_meta(void *ctx, const char *key, + const void *data, size_t data_size) +{ + struct evrpc_request_wrapper *req = ctx; + struct evrpc_hook_meta *store = NULL; + struct evrpc_meta *meta = NULL; + + if ((store = req->hook_meta) == NULL) + store = req->hook_meta = evrpc_hook_meta_new_(); + + meta = mm_malloc(sizeof(struct evrpc_meta)); + EVUTIL_ASSERT(meta != NULL); + meta->key = mm_strdup(key); + EVUTIL_ASSERT(meta->key != NULL); + meta->data_size = data_size; + meta->data = mm_malloc(data_size); + EVUTIL_ASSERT(meta->data != NULL); + memcpy(meta->data, data, data_size); + + TAILQ_INSERT_TAIL(&store->meta_data, meta, next); +} + +int +evrpc_hook_find_meta(void *ctx, const char *key, void **data, size_t *data_size) +{ + struct evrpc_request_wrapper *req = ctx; + struct evrpc_meta *meta = NULL; + + if (req->hook_meta == NULL) + return (-1); + + TAILQ_FOREACH(meta, &req->hook_meta->meta_data, next) { + if (strcmp(meta->key, key) == 0) { + *data = meta->data; + *data_size = meta->data_size; + return (0); + } + } + + return (-1); +} + +struct evhttp_connection * +evrpc_hook_get_connection(void *ctx) +{ + struct evrpc_request_wrapper *req = ctx; + return (req->hook_meta != NULL ? req->hook_meta->evcon : NULL); +} + +int +evrpc_send_request_generic(struct evrpc_pool *pool, + void *request, void *reply, + void (*cb)(struct evrpc_status *, void *, void *, void *), + void *cb_arg, + const char *rpcname, + void (*req_marshal)(struct evbuffer *, void *), + void (*rpl_clear)(void *), + int (*rpl_unmarshal)(void *, struct evbuffer *)) +{ + struct evrpc_status status; + struct evrpc_request_wrapper *ctx; + ctx = evrpc_make_request_ctx(pool, request, reply, + rpcname, req_marshal, rpl_clear, rpl_unmarshal, cb, cb_arg); + if (ctx == NULL) + goto error; + return (evrpc_make_request(ctx)); +error: + memset(&status, 0, sizeof(status)); + status.error = EVRPC_STATUS_ERR_UNSTARTED; + (*(cb))(&status, request, reply, cb_arg); + return (-1); +} + +/** Takes a request object and fills it in with the right magic */ +static struct evrpc * +evrpc_register_object(const char *name, + void *(*req_new)(void*), void *req_new_arg, void (*req_free)(void *), + int (*req_unmarshal)(void *, struct evbuffer *), + void *(*rpl_new)(void*), void *rpl_new_arg, void (*rpl_free)(void *), + int (*rpl_complete)(void *), + void (*rpl_marshal)(struct evbuffer *, void *)) +{ + struct evrpc* rpc = (struct evrpc *)mm_calloc(1, sizeof(struct evrpc)); + if (rpc == NULL) + return (NULL); + rpc->uri = mm_strdup(name); + if (rpc->uri == NULL) { + mm_free(rpc); + return (NULL); + } + rpc->request_new = req_new; + rpc->request_new_arg = req_new_arg; + rpc->request_free = req_free; + rpc->request_unmarshal = req_unmarshal; + rpc->reply_new = rpl_new; + rpc->reply_new_arg = rpl_new_arg; + rpc->reply_free = rpl_free; + rpc->reply_complete = rpl_complete; + rpc->reply_marshal = rpl_marshal; + return (rpc); +} + +int +evrpc_register_generic(struct evrpc_base *base, const char *name, + void (*callback)(struct evrpc_req_generic *, void *), void *cbarg, + void *(*req_new)(void *), void *req_new_arg, void (*req_free)(void *), + int (*req_unmarshal)(void *, struct evbuffer *), + void *(*rpl_new)(void *), void *rpl_new_arg, void (*rpl_free)(void *), + int (*rpl_complete)(void *), + void (*rpl_marshal)(struct evbuffer *, void *)) +{ + struct evrpc* rpc = + evrpc_register_object(name, req_new, req_new_arg, req_free, req_unmarshal, + rpl_new, rpl_new_arg, rpl_free, rpl_complete, rpl_marshal); + if (rpc == NULL) + return (-1); + evrpc_register_rpc(base, rpc, + (void (*)(struct evrpc_req_generic*, void *))callback, cbarg); + return (0); +} + +/** accessors for obscure and undocumented functionality */ +struct evrpc_pool * +evrpc_request_get_pool(struct evrpc_request_wrapper *ctx) +{ + return (ctx->pool); +} + +void +evrpc_request_set_pool(struct evrpc_request_wrapper *ctx, + struct evrpc_pool *pool) +{ + ctx->pool = pool; +} + +void +evrpc_request_set_cb(struct evrpc_request_wrapper *ctx, + void (*cb)(struct evrpc_status*, void *request, void *reply, void *arg), + void *cb_arg) +{ + ctx->cb = cb; + ctx->cb_arg = cb_arg; +} diff --git a/contrib/ntp/sntp/libevent/evsignal-internal.h b/contrib/ntp/sntp/libevent/evsignal-internal.h new file mode 100644 index 000000000..5cff03b52 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evsignal-internal.h @@ -0,0 +1,65 @@ +/* + * Copyright 2000-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVSIGNAL_INTERNAL_H_INCLUDED_ +#define EVSIGNAL_INTERNAL_H_INCLUDED_ + +#ifndef evutil_socket_t +#include "event2/util.h" +#endif +#include + +typedef void (*ev_sighandler_t)(int); + +/* Data structure for the default signal-handling implementation in signal.c + */ +struct evsig_info { + /* Event watching ev_signal_pair[1] */ + struct event ev_signal; + /* Socketpair used to send notifications from the signal handler */ + evutil_socket_t ev_signal_pair[2]; + /* True iff we've added the ev_signal event yet. */ + int ev_signal_added; + /* Count of the number of signals we're currently watching. */ + int ev_n_signals_added; + + /* Array of previous signal handler objects before Libevent started + * messing with them. Used to restore old signal handlers. */ +#ifdef EVENT__HAVE_SIGACTION + struct sigaction **sh_old; +#else + ev_sighandler_t **sh_old; +#endif + /* Size of sh_old. */ + int sh_old_max; +}; +int evsig_init_(struct event_base *); +void evsig_dealloc_(struct event_base *); + +void evsig_set_base_(struct event_base *base); +void evsig_free_globals_(void); + +#endif /* EVSIGNAL_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/evthread-internal.h b/contrib/ntp/sntp/libevent/evthread-internal.h new file mode 100644 index 000000000..efdecf81e --- /dev/null +++ b/contrib/ntp/sntp/libevent/evthread-internal.h @@ -0,0 +1,392 @@ +/* + * Copyright (c) 2008-2012 Niels Provos, Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVTHREAD_INTERNAL_H_INCLUDED_ +#define EVTHREAD_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include "event2/thread.h" +#include "util-internal.h" + +struct event_base; + +#ifndef _WIN32 +/* On Windows, the way we currently make DLLs, it's not allowed for us to + * have shared global structures. Thus, we only do the direct-call-to-function + * code path if we know that the local shared library system supports it. + */ +#define EVTHREAD_EXPOSE_STRUCTS +#endif + +#if ! defined(EVENT__DISABLE_THREAD_SUPPORT) && defined(EVTHREAD_EXPOSE_STRUCTS) +/* Global function pointers to lock-related functions. NULL if locking isn't + enabled. */ +extern struct evthread_lock_callbacks evthread_lock_fns_; +extern struct evthread_condition_callbacks evthread_cond_fns_; +extern unsigned long (*evthread_id_fn_)(void); +extern int evthread_lock_debugging_enabled_; + +/** Return the ID of the current thread, or 1 if threading isn't enabled. */ +#define EVTHREAD_GET_ID() \ + (evthread_id_fn_ ? evthread_id_fn_() : 1) + +/** Return true iff we're in the thread that is currently (or most recently) + * running a given event_base's loop. Requires lock. */ +#define EVBASE_IN_THREAD(base) \ + (evthread_id_fn_ == NULL || \ + (base)->th_owner_id == evthread_id_fn_()) + +/** Return true iff we need to notify the base's main thread about changes to + * its state, because it's currently running the main loop in another + * thread. Requires lock. */ +#define EVBASE_NEED_NOTIFY(base) \ + (evthread_id_fn_ != NULL && \ + (base)->running_loop && \ + (base)->th_owner_id != evthread_id_fn_()) + +/** Allocate a new lock, and store it in lockvar, a void*. Sets lockvar to + NULL if locking is not enabled. */ +#define EVTHREAD_ALLOC_LOCK(lockvar, locktype) \ + ((lockvar) = evthread_lock_fns_.alloc ? \ + evthread_lock_fns_.alloc(locktype) : NULL) + +/** Free a given lock, if it is present and locking is enabled. */ +#define EVTHREAD_FREE_LOCK(lockvar, locktype) \ + do { \ + void *lock_tmp_ = (lockvar); \ + if (lock_tmp_ && evthread_lock_fns_.free) \ + evthread_lock_fns_.free(lock_tmp_, (locktype)); \ + } while (0) + +/** Acquire a lock. */ +#define EVLOCK_LOCK(lockvar,mode) \ + do { \ + if (lockvar) \ + evthread_lock_fns_.lock(mode, lockvar); \ + } while (0) + +/** Release a lock */ +#define EVLOCK_UNLOCK(lockvar,mode) \ + do { \ + if (lockvar) \ + evthread_lock_fns_.unlock(mode, lockvar); \ + } while (0) + +/** Helper: put lockvar1 and lockvar2 into pointerwise ascending order. */ +#define EVLOCK_SORTLOCKS_(lockvar1, lockvar2) \ + do { \ + if (lockvar1 && lockvar2 && lockvar1 > lockvar2) { \ + void *tmp = lockvar1; \ + lockvar1 = lockvar2; \ + lockvar2 = tmp; \ + } \ + } while (0) + +/** Lock an event_base, if it is set up for locking. Acquires the lock + in the base structure whose field is named 'lockvar'. */ +#define EVBASE_ACQUIRE_LOCK(base, lockvar) do { \ + EVLOCK_LOCK((base)->lockvar, 0); \ + } while (0) + +/** Unlock an event_base, if it is set up for locking. */ +#define EVBASE_RELEASE_LOCK(base, lockvar) do { \ + EVLOCK_UNLOCK((base)->lockvar, 0); \ + } while (0) + +/** If lock debugging is enabled, and lock is non-null, assert that 'lock' is + * locked and held by us. */ +#define EVLOCK_ASSERT_LOCKED(lock) \ + do { \ + if ((lock) && evthread_lock_debugging_enabled_) { \ + EVUTIL_ASSERT(evthread_is_debug_lock_held_(lock)); \ + } \ + } while (0) + +/** Try to grab the lock for 'lockvar' without blocking, and return 1 if we + * manage to get it. */ +static inline int EVLOCK_TRY_LOCK_(void *lock); +static inline int +EVLOCK_TRY_LOCK_(void *lock) +{ + if (lock && evthread_lock_fns_.lock) { + int r = evthread_lock_fns_.lock(EVTHREAD_TRY, lock); + return !r; + } else { + /* Locking is disabled either globally or for this thing; + * of course we count as having the lock. */ + return 1; + } +} + +/** Allocate a new condition variable and store it in the void *, condvar */ +#define EVTHREAD_ALLOC_COND(condvar) \ + do { \ + (condvar) = evthread_cond_fns_.alloc_condition ? \ + evthread_cond_fns_.alloc_condition(0) : NULL; \ + } while (0) +/** Deallocate and free a condition variable in condvar */ +#define EVTHREAD_FREE_COND(cond) \ + do { \ + if (cond) \ + evthread_cond_fns_.free_condition((cond)); \ + } while (0) +/** Signal one thread waiting on cond */ +#define EVTHREAD_COND_SIGNAL(cond) \ + ( (cond) ? evthread_cond_fns_.signal_condition((cond), 0) : 0 ) +/** Signal all threads waiting on cond */ +#define EVTHREAD_COND_BROADCAST(cond) \ + ( (cond) ? evthread_cond_fns_.signal_condition((cond), 1) : 0 ) +/** Wait until the condition 'cond' is signalled. Must be called while + * holding 'lock'. The lock will be released until the condition is + * signalled, at which point it will be acquired again. Returns 0 for + * success, -1 for failure. */ +#define EVTHREAD_COND_WAIT(cond, lock) \ + ( (cond) ? evthread_cond_fns_.wait_condition((cond), (lock), NULL) : 0 ) +/** As EVTHREAD_COND_WAIT, but gives up after 'tv' has elapsed. Returns 1 + * on timeout. */ +#define EVTHREAD_COND_WAIT_TIMED(cond, lock, tv) \ + ( (cond) ? evthread_cond_fns_.wait_condition((cond), (lock), (tv)) : 0 ) + +/** True iff locking functions have been configured. */ +#define EVTHREAD_LOCKING_ENABLED() \ + (evthread_lock_fns_.lock != NULL) + +#elif ! defined(EVENT__DISABLE_THREAD_SUPPORT) + +unsigned long evthreadimpl_get_id_(void); +int evthreadimpl_is_lock_debugging_enabled_(void); +void *evthreadimpl_lock_alloc_(unsigned locktype); +void evthreadimpl_lock_free_(void *lock, unsigned locktype); +int evthreadimpl_lock_lock_(unsigned mode, void *lock); +int evthreadimpl_lock_unlock_(unsigned mode, void *lock); +void *evthreadimpl_cond_alloc_(unsigned condtype); +void evthreadimpl_cond_free_(void *cond); +int evthreadimpl_cond_signal_(void *cond, int broadcast); +int evthreadimpl_cond_wait_(void *cond, void *lock, const struct timeval *tv); +int evthreadimpl_locking_enabled_(void); + +#define EVTHREAD_GET_ID() evthreadimpl_get_id_() +#define EVBASE_IN_THREAD(base) \ + ((base)->th_owner_id == evthreadimpl_get_id_()) +#define EVBASE_NEED_NOTIFY(base) \ + ((base)->running_loop && \ + ((base)->th_owner_id != evthreadimpl_get_id_())) + +#define EVTHREAD_ALLOC_LOCK(lockvar, locktype) \ + ((lockvar) = evthreadimpl_lock_alloc_(locktype)) + +#define EVTHREAD_FREE_LOCK(lockvar, locktype) \ + do { \ + void *lock_tmp_ = (lockvar); \ + if (lock_tmp_) \ + evthreadimpl_lock_free_(lock_tmp_, (locktype)); \ + } while (0) + +/** Acquire a lock. */ +#define EVLOCK_LOCK(lockvar,mode) \ + do { \ + if (lockvar) \ + evthreadimpl_lock_lock_(mode, lockvar); \ + } while (0) + +/** Release a lock */ +#define EVLOCK_UNLOCK(lockvar,mode) \ + do { \ + if (lockvar) \ + evthreadimpl_lock_unlock_(mode, lockvar); \ + } while (0) + +/** Lock an event_base, if it is set up for locking. Acquires the lock + in the base structure whose field is named 'lockvar'. */ +#define EVBASE_ACQUIRE_LOCK(base, lockvar) do { \ + EVLOCK_LOCK((base)->lockvar, 0); \ + } while (0) + +/** Unlock an event_base, if it is set up for locking. */ +#define EVBASE_RELEASE_LOCK(base, lockvar) do { \ + EVLOCK_UNLOCK((base)->lockvar, 0); \ + } while (0) + +/** If lock debugging is enabled, and lock is non-null, assert that 'lock' is + * locked and held by us. */ +#define EVLOCK_ASSERT_LOCKED(lock) \ + do { \ + if ((lock) && evthreadimpl_is_lock_debugging_enabled_()) { \ + EVUTIL_ASSERT(evthread_is_debug_lock_held_(lock)); \ + } \ + } while (0) + +/** Try to grab the lock for 'lockvar' without blocking, and return 1 if we + * manage to get it. */ +static inline int EVLOCK_TRY_LOCK_(void *lock); +static inline int +EVLOCK_TRY_LOCK_(void *lock) +{ + if (lock) { + int r = evthreadimpl_lock_lock_(EVTHREAD_TRY, lock); + return !r; + } else { + /* Locking is disabled either globally or for this thing; + * of course we count as having the lock. */ + return 1; + } +} + +/** Allocate a new condition variable and store it in the void *, condvar */ +#define EVTHREAD_ALLOC_COND(condvar) \ + do { \ + (condvar) = evthreadimpl_cond_alloc_(0); \ + } while (0) +/** Deallocate and free a condition variable in condvar */ +#define EVTHREAD_FREE_COND(cond) \ + do { \ + if (cond) \ + evthreadimpl_cond_free_((cond)); \ + } while (0) +/** Signal one thread waiting on cond */ +#define EVTHREAD_COND_SIGNAL(cond) \ + ( (cond) ? evthreadimpl_cond_signal_((cond), 0) : 0 ) +/** Signal all threads waiting on cond */ +#define EVTHREAD_COND_BROADCAST(cond) \ + ( (cond) ? evthreadimpl_cond_signal_((cond), 1) : 0 ) +/** Wait until the condition 'cond' is signalled. Must be called while + * holding 'lock'. The lock will be released until the condition is + * signalled, at which point it will be acquired again. Returns 0 for + * success, -1 for failure. */ +#define EVTHREAD_COND_WAIT(cond, lock) \ + ( (cond) ? evthreadimpl_cond_wait_((cond), (lock), NULL) : 0 ) +/** As EVTHREAD_COND_WAIT, but gives up after 'tv' has elapsed. Returns 1 + * on timeout. */ +#define EVTHREAD_COND_WAIT_TIMED(cond, lock, tv) \ + ( (cond) ? evthreadimpl_cond_wait_((cond), (lock), (tv)) : 0 ) + +#define EVTHREAD_LOCKING_ENABLED() \ + (evthreadimpl_locking_enabled_()) + +#else /* EVENT__DISABLE_THREAD_SUPPORT */ + +#define EVTHREAD_GET_ID() 1 +#define EVTHREAD_ALLOC_LOCK(lockvar, locktype) EVUTIL_NIL_STMT_ +#define EVTHREAD_FREE_LOCK(lockvar, locktype) EVUTIL_NIL_STMT_ + +#define EVLOCK_LOCK(lockvar, mode) EVUTIL_NIL_STMT_ +#define EVLOCK_UNLOCK(lockvar, mode) EVUTIL_NIL_STMT_ +#define EVLOCK_LOCK2(lock1,lock2,mode1,mode2) EVUTIL_NIL_STMT_ +#define EVLOCK_UNLOCK2(lock1,lock2,mode1,mode2) EVUTIL_NIL_STMT_ + +#define EVBASE_IN_THREAD(base) 1 +#define EVBASE_NEED_NOTIFY(base) 0 +#define EVBASE_ACQUIRE_LOCK(base, lock) EVUTIL_NIL_STMT_ +#define EVBASE_RELEASE_LOCK(base, lock) EVUTIL_NIL_STMT_ +#define EVLOCK_ASSERT_LOCKED(lock) EVUTIL_NIL_STMT_ + +#define EVLOCK_TRY_LOCK_(lock) 1 + +#define EVTHREAD_ALLOC_COND(condvar) EVUTIL_NIL_STMT_ +#define EVTHREAD_FREE_COND(cond) EVUTIL_NIL_STMT_ +#define EVTHREAD_COND_SIGNAL(cond) EVUTIL_NIL_STMT_ +#define EVTHREAD_COND_BROADCAST(cond) EVUTIL_NIL_STMT_ +#define EVTHREAD_COND_WAIT(cond, lock) EVUTIL_NIL_STMT_ +#define EVTHREAD_COND_WAIT_TIMED(cond, lock, howlong) EVUTIL_NIL_STMT_ + +#define EVTHREAD_LOCKING_ENABLED() 0 + +#endif + +/* This code is shared between both lock impls */ +#if ! defined(EVENT__DISABLE_THREAD_SUPPORT) +/** Helper: put lockvar1 and lockvar2 into pointerwise ascending order. */ +#define EVLOCK_SORTLOCKS_(lockvar1, lockvar2) \ + do { \ + if (lockvar1 && lockvar2 && lockvar1 > lockvar2) { \ + void *tmp = lockvar1; \ + lockvar1 = lockvar2; \ + lockvar2 = tmp; \ + } \ + } while (0) + +/** Acquire both lock1 and lock2. Always allocates locks in the same order, + * so that two threads locking two locks with LOCK2 will not deadlock. */ +#define EVLOCK_LOCK2(lock1,lock2,mode1,mode2) \ + do { \ + void *lock1_tmplock_ = (lock1); \ + void *lock2_tmplock_ = (lock2); \ + EVLOCK_SORTLOCKS_(lock1_tmplock_,lock2_tmplock_); \ + EVLOCK_LOCK(lock1_tmplock_,mode1); \ + if (lock2_tmplock_ != lock1_tmplock_) \ + EVLOCK_LOCK(lock2_tmplock_,mode2); \ + } while (0) +/** Release both lock1 and lock2. */ +#define EVLOCK_UNLOCK2(lock1,lock2,mode1,mode2) \ + do { \ + void *lock1_tmplock_ = (lock1); \ + void *lock2_tmplock_ = (lock2); \ + EVLOCK_SORTLOCKS_(lock1_tmplock_,lock2_tmplock_); \ + if (lock2_tmplock_ != lock1_tmplock_) \ + EVLOCK_UNLOCK(lock2_tmplock_,mode2); \ + EVLOCK_UNLOCK(lock1_tmplock_,mode1); \ + } while (0) + +int evthread_is_debug_lock_held_(void *lock); +void *evthread_debug_get_real_lock_(void *lock); + +void *evthread_setup_global_lock_(void *lock_, unsigned locktype, + int enable_locks); + +#define EVTHREAD_SETUP_GLOBAL_LOCK(lockvar, locktype) \ + do { \ + lockvar = evthread_setup_global_lock_(lockvar, \ + (locktype), enable_locks); \ + if (!lockvar) { \ + event_warn("Couldn't allocate %s", #lockvar); \ + return -1; \ + } \ + } while (0); + +int event_global_setup_locks_(const int enable_locks); +int evsig_global_setup_locks_(const int enable_locks); +int evutil_global_setup_locks_(const int enable_locks); +int evutil_secure_rng_global_setup_locks_(const int enable_locks); + +/** Return current evthread_lock_callbacks */ +struct evthread_lock_callbacks *evthread_get_lock_callbacks(void); +/** Return current evthread_condition_callbacks */ +struct evthread_condition_callbacks *evthread_get_condition_callbacks(void); +/** Disable locking for internal usage (like global shutdown) */ +void evthreadimpl_disable_lock_debugging_(void); + +#endif + +#ifdef __cplusplus +} +#endif + +#endif /* EVTHREAD_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/evthread.c b/contrib/ntp/sntp/libevent/evthread.c new file mode 100644 index 000000000..02dab7a80 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evthread.c @@ -0,0 +1,475 @@ +/* + * Copyright (c) 2008-2012 Niels Provos, Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + +#include "event2/thread.h" + +#include +#include + +#include "log-internal.h" +#include "mm-internal.h" +#include "util-internal.h" +#include "evthread-internal.h" + +#ifdef EVTHREAD_EXPOSE_STRUCTS +#define GLOBAL +#else +#define GLOBAL static +#endif + +/* globals */ +GLOBAL int evthread_lock_debugging_enabled_ = 0; +GLOBAL struct evthread_lock_callbacks evthread_lock_fns_ = { + 0, 0, NULL, NULL, NULL, NULL +}; +GLOBAL unsigned long (*evthread_id_fn_)(void) = NULL; +GLOBAL struct evthread_condition_callbacks evthread_cond_fns_ = { + 0, NULL, NULL, NULL, NULL +}; + +/* Used for debugging */ +static struct evthread_lock_callbacks original_lock_fns_ = { + 0, 0, NULL, NULL, NULL, NULL +}; +static struct evthread_condition_callbacks original_cond_fns_ = { + 0, NULL, NULL, NULL, NULL +}; + +void +evthread_set_id_callback(unsigned long (*id_fn)(void)) +{ + evthread_id_fn_ = id_fn; +} + +struct evthread_lock_callbacks *evthread_get_lock_callbacks() +{ + return evthread_lock_debugging_enabled_ + ? &original_lock_fns_ : &evthread_lock_fns_; +} +struct evthread_condition_callbacks *evthread_get_condition_callbacks() +{ + return evthread_lock_debugging_enabled_ + ? &original_cond_fns_ : &evthread_cond_fns_; +} +void evthreadimpl_disable_lock_debugging_(void) +{ + evthread_lock_debugging_enabled_ = 0; +} + +int +evthread_set_lock_callbacks(const struct evthread_lock_callbacks *cbs) +{ + struct evthread_lock_callbacks *target = evthread_get_lock_callbacks(); + + if (!cbs) { + if (target->alloc) + event_warnx("Trying to disable lock functions after " + "they have been set up will probaby not work."); + memset(target, 0, sizeof(evthread_lock_fns_)); + return 0; + } + if (target->alloc) { + /* Uh oh; we already had locking callbacks set up.*/ + if (target->lock_api_version == cbs->lock_api_version && + target->supported_locktypes == cbs->supported_locktypes && + target->alloc == cbs->alloc && + target->free == cbs->free && + target->lock == cbs->lock && + target->unlock == cbs->unlock) { + /* no change -- allow this. */ + return 0; + } + event_warnx("Can't change lock callbacks once they have been " + "initialized."); + return -1; + } + if (cbs->alloc && cbs->free && cbs->lock && cbs->unlock) { + memcpy(target, cbs, sizeof(evthread_lock_fns_)); + return event_global_setup_locks_(1); + } else { + return -1; + } +} + +int +evthread_set_condition_callbacks(const struct evthread_condition_callbacks *cbs) +{ + struct evthread_condition_callbacks *target = evthread_get_condition_callbacks(); + + if (!cbs) { + if (target->alloc_condition) + event_warnx("Trying to disable condition functions " + "after they have been set up will probaby not " + "work."); + memset(target, 0, sizeof(evthread_cond_fns_)); + return 0; + } + if (target->alloc_condition) { + /* Uh oh; we already had condition callbacks set up.*/ + if (target->condition_api_version == cbs->condition_api_version && + target->alloc_condition == cbs->alloc_condition && + target->free_condition == cbs->free_condition && + target->signal_condition == cbs->signal_condition && + target->wait_condition == cbs->wait_condition) { + /* no change -- allow this. */ + return 0; + } + event_warnx("Can't change condition callbacks once they " + "have been initialized."); + return -1; + } + if (cbs->alloc_condition && cbs->free_condition && + cbs->signal_condition && cbs->wait_condition) { + memcpy(target, cbs, sizeof(evthread_cond_fns_)); + } + if (evthread_lock_debugging_enabled_) { + evthread_cond_fns_.alloc_condition = cbs->alloc_condition; + evthread_cond_fns_.free_condition = cbs->free_condition; + evthread_cond_fns_.signal_condition = cbs->signal_condition; + } + return 0; +} + +#define DEBUG_LOCK_SIG 0xdeb0b10c + +struct debug_lock { + unsigned signature; + unsigned locktype; + unsigned long held_by; + /* XXXX if we ever use read-write locks, we will need a separate + * lock to protect count. */ + int count; + void *lock; +}; + +static void * +debug_lock_alloc(unsigned locktype) +{ + struct debug_lock *result = mm_malloc(sizeof(struct debug_lock)); + if (!result) + return NULL; + if (original_lock_fns_.alloc) { + if (!(result->lock = original_lock_fns_.alloc( + locktype|EVTHREAD_LOCKTYPE_RECURSIVE))) { + mm_free(result); + return NULL; + } + } else { + result->lock = NULL; + } + result->signature = DEBUG_LOCK_SIG; + result->locktype = locktype; + result->count = 0; + result->held_by = 0; + return result; +} + +static void +debug_lock_free(void *lock_, unsigned locktype) +{ + struct debug_lock *lock = lock_; + EVUTIL_ASSERT(lock->count == 0); + EVUTIL_ASSERT(locktype == lock->locktype); + EVUTIL_ASSERT(DEBUG_LOCK_SIG == lock->signature); + if (original_lock_fns_.free) { + original_lock_fns_.free(lock->lock, + lock->locktype|EVTHREAD_LOCKTYPE_RECURSIVE); + } + lock->lock = NULL; + lock->count = -100; + lock->signature = 0x12300fda; + mm_free(lock); +} + +static void +evthread_debug_lock_mark_locked(unsigned mode, struct debug_lock *lock) +{ + EVUTIL_ASSERT(DEBUG_LOCK_SIG == lock->signature); + ++lock->count; + if (!(lock->locktype & EVTHREAD_LOCKTYPE_RECURSIVE)) + EVUTIL_ASSERT(lock->count == 1); + if (evthread_id_fn_) { + unsigned long me; + me = evthread_id_fn_(); + if (lock->count > 1) + EVUTIL_ASSERT(lock->held_by == me); + lock->held_by = me; + } +} + +static int +debug_lock_lock(unsigned mode, void *lock_) +{ + struct debug_lock *lock = lock_; + int res = 0; + if (lock->locktype & EVTHREAD_LOCKTYPE_READWRITE) + EVUTIL_ASSERT(mode & (EVTHREAD_READ|EVTHREAD_WRITE)); + else + EVUTIL_ASSERT((mode & (EVTHREAD_READ|EVTHREAD_WRITE)) == 0); + if (original_lock_fns_.lock) + res = original_lock_fns_.lock(mode, lock->lock); + if (!res) { + evthread_debug_lock_mark_locked(mode, lock); + } + return res; +} + +static void +evthread_debug_lock_mark_unlocked(unsigned mode, struct debug_lock *lock) +{ + EVUTIL_ASSERT(DEBUG_LOCK_SIG == lock->signature); + if (lock->locktype & EVTHREAD_LOCKTYPE_READWRITE) + EVUTIL_ASSERT(mode & (EVTHREAD_READ|EVTHREAD_WRITE)); + else + EVUTIL_ASSERT((mode & (EVTHREAD_READ|EVTHREAD_WRITE)) == 0); + if (evthread_id_fn_) { + unsigned long me; + me = evthread_id_fn_(); + EVUTIL_ASSERT(lock->held_by == me); + if (lock->count == 1) + lock->held_by = 0; + } + --lock->count; + EVUTIL_ASSERT(lock->count >= 0); +} + +static int +debug_lock_unlock(unsigned mode, void *lock_) +{ + struct debug_lock *lock = lock_; + int res = 0; + evthread_debug_lock_mark_unlocked(mode, lock); + if (original_lock_fns_.unlock) + res = original_lock_fns_.unlock(mode, lock->lock); + return res; +} + +static int +debug_cond_wait(void *cond_, void *lock_, const struct timeval *tv) +{ + int r; + struct debug_lock *lock = lock_; + EVUTIL_ASSERT(lock); + EVUTIL_ASSERT(DEBUG_LOCK_SIG == lock->signature); + EVLOCK_ASSERT_LOCKED(lock_); + evthread_debug_lock_mark_unlocked(0, lock); + r = original_cond_fns_.wait_condition(cond_, lock->lock, tv); + evthread_debug_lock_mark_locked(0, lock); + return r; +} + +/* misspelled version for backward compatibility */ +void +evthread_enable_lock_debuging(void) +{ + evthread_enable_lock_debugging(); +} + +void +evthread_enable_lock_debugging(void) +{ + struct evthread_lock_callbacks cbs = { + EVTHREAD_LOCK_API_VERSION, + EVTHREAD_LOCKTYPE_RECURSIVE, + debug_lock_alloc, + debug_lock_free, + debug_lock_lock, + debug_lock_unlock + }; + if (evthread_lock_debugging_enabled_) + return; + memcpy(&original_lock_fns_, &evthread_lock_fns_, + sizeof(struct evthread_lock_callbacks)); + memcpy(&evthread_lock_fns_, &cbs, + sizeof(struct evthread_lock_callbacks)); + + memcpy(&original_cond_fns_, &evthread_cond_fns_, + sizeof(struct evthread_condition_callbacks)); + evthread_cond_fns_.wait_condition = debug_cond_wait; + evthread_lock_debugging_enabled_ = 1; + + /* XXX return value should get checked. */ + event_global_setup_locks_(0); +} + +int +evthread_is_debug_lock_held_(void *lock_) +{ + struct debug_lock *lock = lock_; + if (! lock->count) + return 0; + if (evthread_id_fn_) { + unsigned long me = evthread_id_fn_(); + if (lock->held_by != me) + return 0; + } + return 1; +} + +void * +evthread_debug_get_real_lock_(void *lock_) +{ + struct debug_lock *lock = lock_; + return lock->lock; +} + +void * +evthread_setup_global_lock_(void *lock_, unsigned locktype, int enable_locks) +{ + /* there are four cases here: + 1) we're turning on debugging; locking is not on. + 2) we're turning on debugging; locking is on. + 3) we're turning on locking; debugging is not on. + 4) we're turning on locking; debugging is on. */ + + if (!enable_locks && original_lock_fns_.alloc == NULL) { + /* Case 1: allocate a debug lock. */ + EVUTIL_ASSERT(lock_ == NULL); + return debug_lock_alloc(locktype); + } else if (!enable_locks && original_lock_fns_.alloc != NULL) { + /* Case 2: wrap the lock in a debug lock. */ + struct debug_lock *lock; + EVUTIL_ASSERT(lock_ != NULL); + + if (!(locktype & EVTHREAD_LOCKTYPE_RECURSIVE)) { + /* We can't wrap it: We need a recursive lock */ + original_lock_fns_.free(lock_, locktype); + return debug_lock_alloc(locktype); + } + lock = mm_malloc(sizeof(struct debug_lock)); + if (!lock) { + original_lock_fns_.free(lock_, locktype); + return NULL; + } + lock->lock = lock_; + lock->locktype = locktype; + lock->count = 0; + lock->held_by = 0; + return lock; + } else if (enable_locks && ! evthread_lock_debugging_enabled_) { + /* Case 3: allocate a regular lock */ + EVUTIL_ASSERT(lock_ == NULL); + return evthread_lock_fns_.alloc(locktype); + } else { + /* Case 4: Fill in a debug lock with a real lock */ + struct debug_lock *lock = lock_; + EVUTIL_ASSERT(enable_locks && + evthread_lock_debugging_enabled_); + EVUTIL_ASSERT(lock->locktype == locktype); + EVUTIL_ASSERT(lock->lock == NULL); + lock->lock = original_lock_fns_.alloc( + locktype|EVTHREAD_LOCKTYPE_RECURSIVE); + if (!lock->lock) { + lock->count = -200; + mm_free(lock); + return NULL; + } + return lock; + } +} + + +#ifndef EVTHREAD_EXPOSE_STRUCTS +unsigned long +evthreadimpl_get_id_() +{ + return evthread_id_fn_ ? evthread_id_fn_() : 1; +} +void * +evthreadimpl_lock_alloc_(unsigned locktype) +{ + return evthread_lock_fns_.alloc ? + evthread_lock_fns_.alloc(locktype) : NULL; +} +void +evthreadimpl_lock_free_(void *lock, unsigned locktype) +{ + if (evthread_lock_fns_.free) + evthread_lock_fns_.free(lock, locktype); +} +int +evthreadimpl_lock_lock_(unsigned mode, void *lock) +{ + if (evthread_lock_fns_.lock) + return evthread_lock_fns_.lock(mode, lock); + else + return 0; +} +int +evthreadimpl_lock_unlock_(unsigned mode, void *lock) +{ + if (evthread_lock_fns_.unlock) + return evthread_lock_fns_.unlock(mode, lock); + else + return 0; +} +void * +evthreadimpl_cond_alloc_(unsigned condtype) +{ + return evthread_cond_fns_.alloc_condition ? + evthread_cond_fns_.alloc_condition(condtype) : NULL; +} +void +evthreadimpl_cond_free_(void *cond) +{ + if (evthread_cond_fns_.free_condition) + evthread_cond_fns_.free_condition(cond); +} +int +evthreadimpl_cond_signal_(void *cond, int broadcast) +{ + if (evthread_cond_fns_.signal_condition) + return evthread_cond_fns_.signal_condition(cond, broadcast); + else + return 0; +} +int +evthreadimpl_cond_wait_(void *cond, void *lock, const struct timeval *tv) +{ + if (evthread_cond_fns_.wait_condition) + return evthread_cond_fns_.wait_condition(cond, lock, tv); + else + return 0; +} +int +evthreadimpl_is_lock_debugging_enabled_(void) +{ + return evthread_lock_debugging_enabled_; +} + +int +evthreadimpl_locking_enabled_(void) +{ + return evthread_lock_fns_.lock != NULL; +} +#endif + +#endif diff --git a/contrib/ntp/sntp/libevent/evthread_pthread.c b/contrib/ntp/sntp/libevent/evthread_pthread.c new file mode 100644 index 000000000..4e11f7497 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evthread_pthread.c @@ -0,0 +1,191 @@ +/* + * Copyright 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +/* With glibc we need to define _GNU_SOURCE to get PTHREAD_MUTEX_RECURSIVE. + * This comes from evconfig-private.h + */ +#include + +struct event_base; +#include "event2/thread.h" + +#include +#include +#include "mm-internal.h" +#include "evthread-internal.h" + +static pthread_mutexattr_t attr_recursive; + +static void * +evthread_posix_lock_alloc(unsigned locktype) +{ + pthread_mutexattr_t *attr = NULL; + pthread_mutex_t *lock = mm_malloc(sizeof(pthread_mutex_t)); + if (!lock) + return NULL; + if (locktype & EVTHREAD_LOCKTYPE_RECURSIVE) + attr = &attr_recursive; + if (pthread_mutex_init(lock, attr)) { + mm_free(lock); + return NULL; + } + return lock; +} + +static void +evthread_posix_lock_free(void *lock_, unsigned locktype) +{ + pthread_mutex_t *lock = lock_; + pthread_mutex_destroy(lock); + mm_free(lock); +} + +static int +evthread_posix_lock(unsigned mode, void *lock_) +{ + pthread_mutex_t *lock = lock_; + if (mode & EVTHREAD_TRY) + return pthread_mutex_trylock(lock); + else + return pthread_mutex_lock(lock); +} + +static int +evthread_posix_unlock(unsigned mode, void *lock_) +{ + pthread_mutex_t *lock = lock_; + return pthread_mutex_unlock(lock); +} + +static unsigned long +evthread_posix_get_id(void) +{ + union { + pthread_t thr; +#if EVENT__SIZEOF_PTHREAD_T > EVENT__SIZEOF_LONG + ev_uint64_t id; +#else + unsigned long id; +#endif + } r; +#if EVENT__SIZEOF_PTHREAD_T < EVENT__SIZEOF_LONG + memset(&r, 0, sizeof(r)); +#endif + r.thr = pthread_self(); + return (unsigned long)r.id; +} + +static void * +evthread_posix_cond_alloc(unsigned condflags) +{ + pthread_cond_t *cond = mm_malloc(sizeof(pthread_cond_t)); + if (!cond) + return NULL; + if (pthread_cond_init(cond, NULL)) { + mm_free(cond); + return NULL; + } + return cond; +} + +static void +evthread_posix_cond_free(void *cond_) +{ + pthread_cond_t *cond = cond_; + pthread_cond_destroy(cond); + mm_free(cond); +} + +static int +evthread_posix_cond_signal(void *cond_, int broadcast) +{ + pthread_cond_t *cond = cond_; + int r; + if (broadcast) + r = pthread_cond_broadcast(cond); + else + r = pthread_cond_signal(cond); + return r ? -1 : 0; +} + +static int +evthread_posix_cond_wait(void *cond_, void *lock_, const struct timeval *tv) +{ + int r; + pthread_cond_t *cond = cond_; + pthread_mutex_t *lock = lock_; + + if (tv) { + struct timeval now, abstime; + struct timespec ts; + evutil_gettimeofday(&now, NULL); + evutil_timeradd(&now, tv, &abstime); + ts.tv_sec = abstime.tv_sec; + ts.tv_nsec = abstime.tv_usec*1000; + r = pthread_cond_timedwait(cond, lock, &ts); + if (r == ETIMEDOUT) + return 1; + else if (r) + return -1; + else + return 0; + } else { + r = pthread_cond_wait(cond, lock); + return r ? -1 : 0; + } +} + +int +evthread_use_pthreads(void) +{ + struct evthread_lock_callbacks cbs = { + EVTHREAD_LOCK_API_VERSION, + EVTHREAD_LOCKTYPE_RECURSIVE, + evthread_posix_lock_alloc, + evthread_posix_lock_free, + evthread_posix_lock, + evthread_posix_unlock + }; + struct evthread_condition_callbacks cond_cbs = { + EVTHREAD_CONDITION_API_VERSION, + evthread_posix_cond_alloc, + evthread_posix_cond_free, + evthread_posix_cond_signal, + evthread_posix_cond_wait + }; + /* Set ourselves up to get recursive locks. */ + if (pthread_mutexattr_init(&attr_recursive)) + return -1; + if (pthread_mutexattr_settype(&attr_recursive, PTHREAD_MUTEX_RECURSIVE)) + return -1; + + evthread_set_lock_callbacks(&cbs); + evthread_set_condition_callbacks(&cond_cbs); + evthread_set_id_callback(evthread_posix_get_id); + return 0; +} diff --git a/contrib/ntp/sntp/libevent/evthread_win32.c b/contrib/ntp/sntp/libevent/evthread_win32.c new file mode 100644 index 000000000..2ec80560a --- /dev/null +++ b/contrib/ntp/sntp/libevent/evthread_win32.c @@ -0,0 +1,341 @@ +/* + * Copyright 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#ifndef _WIN32_WINNT +/* Minimum required for InitializeCriticalSectionAndSpinCount */ +#define _WIN32_WINNT 0x0403 +#endif +#include +#define WIN32_LEAN_AND_MEAN +#include +#undef WIN32_LEAN_AND_MEAN +#include +#endif + +struct event_base; +#include "event2/thread.h" + +#include "mm-internal.h" +#include "evthread-internal.h" +#include "time-internal.h" + +#define SPIN_COUNT 2000 + +static void * +evthread_win32_lock_create(unsigned locktype) +{ + CRITICAL_SECTION *lock = mm_malloc(sizeof(CRITICAL_SECTION)); + if (!lock) + return NULL; + if (InitializeCriticalSectionAndSpinCount(lock, SPIN_COUNT) == 0) { + mm_free(lock); + return NULL; + } + return lock; +} + +static void +evthread_win32_lock_free(void *lock_, unsigned locktype) +{ + CRITICAL_SECTION *lock = lock_; + DeleteCriticalSection(lock); + mm_free(lock); +} + +static int +evthread_win32_lock(unsigned mode, void *lock_) +{ + CRITICAL_SECTION *lock = lock_; + if ((mode & EVTHREAD_TRY)) { + return ! TryEnterCriticalSection(lock); + } else { + EnterCriticalSection(lock); + return 0; + } +} + +static int +evthread_win32_unlock(unsigned mode, void *lock_) +{ + CRITICAL_SECTION *lock = lock_; + LeaveCriticalSection(lock); + return 0; +} + +static unsigned long +evthread_win32_get_id(void) +{ + return (unsigned long) GetCurrentThreadId(); +} + +#ifdef WIN32_HAVE_CONDITION_VARIABLES +static void WINAPI (*InitializeConditionVariable_fn)(PCONDITION_VARIABLE) + = NULL; +static BOOL WINAPI (*SleepConditionVariableCS_fn)( + PCONDITION_VARIABLE, PCRITICAL_SECTION, DWORD) = NULL; +static void WINAPI (*WakeAllConditionVariable_fn)(PCONDITION_VARIABLE) = NULL; +static void WINAPI (*WakeConditionVariable_fn)(PCONDITION_VARIABLE) = NULL; + +static int +evthread_win32_condvar_init(void) +{ + HANDLE lib; + + lib = GetModuleHandle(TEXT("kernel32.dll")); + if (lib == NULL) + return 0; + +#define LOAD(name) \ + name##_fn = GetProcAddress(lib, #name) + LOAD(InitializeConditionVariable); + LOAD(SleepConditionVariableCS); + LOAD(WakeAllConditionVariable); + LOAD(WakeConditionVariable); + + return InitializeConditionVariable_fn && SleepConditionVariableCS_fn && + WakeAllConditionVariable_fn && WakeConditionVariable_fn; +} + +/* XXXX Even if we can build this, we don't necessarily want to: the functions + * in question didn't exist before Vista, so we'd better LoadProc them. */ +static void * +evthread_win32_condvar_alloc(unsigned condflags) +{ + CONDITION_VARIABLE *cond = mm_malloc(sizeof(CONDITION_VARIABLE)); + if (!cond) + return NULL; + InitializeConditionVariable_fn(cond); + return cond; +} + +static void +evthread_win32_condvar_free(void *cond_) +{ + CONDITION_VARIABLE *cond = cond_; + /* There doesn't _seem_ to be a cleaup fn here... */ + mm_free(cond); +} + +static int +evthread_win32_condvar_signal(void *cond, int broadcast) +{ + CONDITION_VARIABLE *cond = cond_; + if (broadcast) + WakeAllConditionVariable_fn(cond); + else + WakeConditionVariable_fn(cond); + return 0; +} + +static int +evthread_win32_condvar_wait(void *cond_, void *lock_, const struct timeval *tv) +{ + CONDITION_VARIABLE *cond = cond_; + CRITICAL_SECTION *lock = lock_; + DWORD ms, err; + BOOL result; + + if (tv) + ms = evutil_tv_to_msec_(tv); + else + ms = INFINITE; + result = SleepConditionVariableCS_fn(cond, lock, ms); + if (result) { + if (GetLastError() == WAIT_TIMEOUT) + return 1; + else + return -1; + } else { + return 0; + } +} +#endif + +struct evthread_win32_cond { + HANDLE event; + + CRITICAL_SECTION lock; + int n_waiting; + int n_to_wake; + int generation; +}; + +static void * +evthread_win32_cond_alloc(unsigned flags) +{ + struct evthread_win32_cond *cond; + if (!(cond = mm_malloc(sizeof(struct evthread_win32_cond)))) + return NULL; + if (InitializeCriticalSectionAndSpinCount(&cond->lock, SPIN_COUNT)==0) { + mm_free(cond); + return NULL; + } + if ((cond->event = CreateEvent(NULL,TRUE,FALSE,NULL)) == NULL) { + DeleteCriticalSection(&cond->lock); + mm_free(cond); + return NULL; + } + cond->n_waiting = cond->n_to_wake = cond->generation = 0; + return cond; +} + +static void +evthread_win32_cond_free(void *cond_) +{ + struct evthread_win32_cond *cond = cond_; + DeleteCriticalSection(&cond->lock); + CloseHandle(cond->event); + mm_free(cond); +} + +static int +evthread_win32_cond_signal(void *cond_, int broadcast) +{ + struct evthread_win32_cond *cond = cond_; + EnterCriticalSection(&cond->lock); + if (broadcast) + cond->n_to_wake = cond->n_waiting; + else + ++cond->n_to_wake; + cond->generation++; + SetEvent(cond->event); + LeaveCriticalSection(&cond->lock); + return 0; +} + +static int +evthread_win32_cond_wait(void *cond_, void *lock_, const struct timeval *tv) +{ + struct evthread_win32_cond *cond = cond_; + CRITICAL_SECTION *lock = lock_; + int generation_at_start; + int waiting = 1; + int result = -1; + DWORD ms = INFINITE, ms_orig = INFINITE, startTime, endTime; + if (tv) + ms_orig = ms = evutil_tv_to_msec_(tv); + + EnterCriticalSection(&cond->lock); + ++cond->n_waiting; + generation_at_start = cond->generation; + LeaveCriticalSection(&cond->lock); + + LeaveCriticalSection(lock); + + startTime = GetTickCount(); + do { + DWORD res; + res = WaitForSingleObject(cond->event, ms); + EnterCriticalSection(&cond->lock); + if (cond->n_to_wake && + cond->generation != generation_at_start) { + --cond->n_to_wake; + --cond->n_waiting; + result = 0; + waiting = 0; + goto out; + } else if (res != WAIT_OBJECT_0) { + result = (res==WAIT_TIMEOUT) ? 1 : -1; + --cond->n_waiting; + waiting = 0; + goto out; + } else if (ms != INFINITE) { + endTime = GetTickCount(); + if (startTime + ms_orig <= endTime) { + result = 1; /* Timeout */ + --cond->n_waiting; + waiting = 0; + goto out; + } else { + ms = startTime + ms_orig - endTime; + } + } + /* If we make it here, we are still waiting. */ + if (cond->n_to_wake == 0) { + /* There is nobody else who should wake up; reset + * the event. */ + ResetEvent(cond->event); + } + out: + LeaveCriticalSection(&cond->lock); + } while (waiting); + + EnterCriticalSection(lock); + + EnterCriticalSection(&cond->lock); + if (!cond->n_waiting) + ResetEvent(cond->event); + LeaveCriticalSection(&cond->lock); + + return result; +} + +int +evthread_use_windows_threads(void) +{ + struct evthread_lock_callbacks cbs = { + EVTHREAD_LOCK_API_VERSION, + EVTHREAD_LOCKTYPE_RECURSIVE, + evthread_win32_lock_create, + evthread_win32_lock_free, + evthread_win32_lock, + evthread_win32_unlock + }; + + + struct evthread_condition_callbacks cond_cbs = { + EVTHREAD_CONDITION_API_VERSION, + evthread_win32_cond_alloc, + evthread_win32_cond_free, + evthread_win32_cond_signal, + evthread_win32_cond_wait + }; +#ifdef WIN32_HAVE_CONDITION_VARIABLES + struct evthread_condition_callbacks condvar_cbs = { + EVTHREAD_CONDITION_API_VERSION, + evthread_win32_condvar_alloc, + evthread_win32_condvar_free, + evthread_win32_condvar_signal, + evthread_win32_condvar_wait + }; +#endif + + evthread_set_lock_callbacks(&cbs); + evthread_set_id_callback(evthread_win32_get_id); +#ifdef WIN32_HAVE_CONDITION_VARIABLES + if (evthread_win32_condvar_init()) { + evthread_set_condition_callbacks(&condvar_cbs); + return 0; + } +#endif + evthread_set_condition_callbacks(&cond_cbs); + + return 0; +} + diff --git a/contrib/ntp/sntp/libevent/evutil.c b/contrib/ntp/sntp/libevent/evutil.c new file mode 100644 index 000000000..3d72e4032 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evutil.c @@ -0,0 +1,2663 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#include +#include +#define WIN32_LEAN_AND_MEAN +#include +#undef WIN32_LEAN_AND_MEAN +#include +#include +#include +#undef _WIN32_WINNT +/* For structs needed by GetAdaptersAddresses */ +#define _WIN32_WINNT 0x0501 +#include +#endif + +#include +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#ifdef EVENT__HAVE_FCNTL_H +#include +#endif +#ifdef EVENT__HAVE_STDLIB_H +#include +#endif +#include +#include +#include +#include +#ifdef EVENT__HAVE_NETINET_IN_H +#include +#endif +#ifdef EVENT__HAVE_NETINET_IN6_H +#include +#endif +#ifdef EVENT__HAVE_NETINET_TCP_H +#include +#endif +#ifdef EVENT__HAVE_ARPA_INET_H +#include +#endif +#include +#include +#ifdef EVENT__HAVE_IFADDRS_H +#include +#endif + +#include "event2/util.h" +#include "util-internal.h" +#include "log-internal.h" +#include "mm-internal.h" +#include "evthread-internal.h" + +#include "strlcpy-internal.h" +#include "ipv6-internal.h" + +#ifdef _WIN32 +#define HT_NO_CACHE_HASH_VALUES +#include "ht-internal.h" +#define open _open +#define read _read +#define close _close +#ifndef fstat +#define fstat _fstati64 +#endif +#ifndef stat +#define stat _stati64 +#endif +#define mode_t int +#endif + +int +evutil_open_closeonexec_(const char *pathname, int flags, unsigned mode) +{ + int fd; + +#ifdef O_CLOEXEC + fd = open(pathname, flags|O_CLOEXEC, (mode_t)mode); + if (fd >= 0 || errno == EINVAL) + return fd; + /* If we got an EINVAL, fall through and try without O_CLOEXEC */ +#endif + fd = open(pathname, flags, (mode_t)mode); + if (fd < 0) + return -1; + +#if defined(FD_CLOEXEC) + if (fcntl(fd, F_SETFD, FD_CLOEXEC) < 0) { + close(fd); + return -1; + } +#endif + + return fd; +} + +/** + Read the contents of 'filename' into a newly allocated NUL-terminated + string. Set *content_out to hold this string, and *len_out to hold its + length (not including the appended NUL). If 'is_binary', open the file in + binary mode. + + Returns 0 on success, -1 if the open fails, and -2 for all other failures. + + Used internally only; may go away in a future version. + */ +int +evutil_read_file_(const char *filename, char **content_out, size_t *len_out, + int is_binary) +{ + int fd, r; + struct stat st; + char *mem; + size_t read_so_far=0; + int mode = O_RDONLY; + + EVUTIL_ASSERT(content_out); + EVUTIL_ASSERT(len_out); + *content_out = NULL; + *len_out = 0; + +#ifdef O_BINARY + if (is_binary) + mode |= O_BINARY; +#endif + + fd = evutil_open_closeonexec_(filename, mode, 0); + if (fd < 0) + return -1; + if (fstat(fd, &st) || st.st_size < 0 || + st.st_size > EV_SSIZE_MAX-1 ) { + close(fd); + return -2; + } + mem = mm_malloc((size_t)st.st_size + 1); + if (!mem) { + close(fd); + return -2; + } + read_so_far = 0; +#ifdef _WIN32 +#define N_TO_READ(x) ((x) > INT_MAX) ? INT_MAX : ((int)(x)) +#else +#define N_TO_READ(x) (x) +#endif + while ((r = read(fd, mem+read_so_far, N_TO_READ(st.st_size - read_so_far))) > 0) { + read_so_far += r; + if (read_so_far >= (size_t)st.st_size) + break; + EVUTIL_ASSERT(read_so_far < (size_t)st.st_size); + } + close(fd); + if (r < 0) { + mm_free(mem); + return -2; + } + mem[read_so_far] = 0; + + *len_out = read_so_far; + *content_out = mem; + return 0; +} + +int +evutil_socketpair(int family, int type, int protocol, evutil_socket_t fd[2]) +{ +#ifndef _WIN32 + return socketpair(family, type, protocol, fd); +#else + return evutil_ersatz_socketpair_(family, type, protocol, fd); +#endif +} + +int +evutil_ersatz_socketpair_(int family, int type, int protocol, + evutil_socket_t fd[2]) +{ + /* This code is originally from Tor. Used with permission. */ + + /* This socketpair does not work when localhost is down. So + * it's really not the same thing at all. But it's close enough + * for now, and really, when localhost is down sometimes, we + * have other problems too. + */ +#ifdef _WIN32 +#define ERR(e) WSA##e +#else +#define ERR(e) e +#endif + evutil_socket_t listener = -1; + evutil_socket_t connector = -1; + evutil_socket_t acceptor = -1; + struct sockaddr_in listen_addr; + struct sockaddr_in connect_addr; + ev_socklen_t size; + int saved_errno = -1; + + if (protocol + || (family != AF_INET +#ifdef AF_UNIX + && family != AF_UNIX +#endif + )) { + EVUTIL_SET_SOCKET_ERROR(ERR(EAFNOSUPPORT)); + return -1; + } + if (!fd) { + EVUTIL_SET_SOCKET_ERROR(ERR(EINVAL)); + return -1; + } + + listener = socket(AF_INET, type, 0); + if (listener < 0) + return -1; + memset(&listen_addr, 0, sizeof(listen_addr)); + listen_addr.sin_family = AF_INET; + listen_addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); + listen_addr.sin_port = 0; /* kernel chooses port. */ + if (bind(listener, (struct sockaddr *) &listen_addr, sizeof (listen_addr)) + == -1) + goto tidy_up_and_fail; + if (listen(listener, 1) == -1) + goto tidy_up_and_fail; + + connector = socket(AF_INET, type, 0); + if (connector < 0) + goto tidy_up_and_fail; + /* We want to find out the port number to connect to. */ + size = sizeof(connect_addr); + if (getsockname(listener, (struct sockaddr *) &connect_addr, &size) == -1) + goto tidy_up_and_fail; + if (size != sizeof (connect_addr)) + goto abort_tidy_up_and_fail; + if (connect(connector, (struct sockaddr *) &connect_addr, + sizeof(connect_addr)) == -1) + goto tidy_up_and_fail; + + size = sizeof(listen_addr); + acceptor = accept(listener, (struct sockaddr *) &listen_addr, &size); + if (acceptor < 0) + goto tidy_up_and_fail; + if (size != sizeof(listen_addr)) + goto abort_tidy_up_and_fail; + /* Now check we are talking to ourself by matching port and host on the + two sockets. */ + if (getsockname(connector, (struct sockaddr *) &connect_addr, &size) == -1) + goto tidy_up_and_fail; + if (size != sizeof (connect_addr) + || listen_addr.sin_family != connect_addr.sin_family + || listen_addr.sin_addr.s_addr != connect_addr.sin_addr.s_addr + || listen_addr.sin_port != connect_addr.sin_port) + goto abort_tidy_up_and_fail; + evutil_closesocket(listener); + fd[0] = connector; + fd[1] = acceptor; + + return 0; + + abort_tidy_up_and_fail: + saved_errno = ERR(ECONNABORTED); + tidy_up_and_fail: + if (saved_errno < 0) + saved_errno = EVUTIL_SOCKET_ERROR(); + if (listener != -1) + evutil_closesocket(listener); + if (connector != -1) + evutil_closesocket(connector); + if (acceptor != -1) + evutil_closesocket(acceptor); + + EVUTIL_SET_SOCKET_ERROR(saved_errno); + return -1; +#undef ERR +} + +int +evutil_make_socket_nonblocking(evutil_socket_t fd) +{ +#ifdef _WIN32 + { + u_long nonblocking = 1; + if (ioctlsocket(fd, FIONBIO, &nonblocking) == SOCKET_ERROR) { + event_sock_warn(fd, "fcntl(%d, F_GETFL)", (int)fd); + return -1; + } + } +#else + { + int flags; + if ((flags = fcntl(fd, F_GETFL, NULL)) < 0) { + event_warn("fcntl(%d, F_GETFL)", fd); + return -1; + } + if (!(flags & O_NONBLOCK)) { + if (fcntl(fd, F_SETFL, flags | O_NONBLOCK) == -1) { + event_warn("fcntl(%d, F_SETFL)", fd); + return -1; + } + } + } +#endif + return 0; +} + +/* Faster version of evutil_make_socket_nonblocking for internal use. + * + * Requires that no F_SETFL flags were previously set on the fd. + */ +static int +evutil_fast_socket_nonblocking(evutil_socket_t fd) +{ +#ifdef _WIN32 + return evutil_make_socket_nonblocking(fd); +#else + if (fcntl(fd, F_SETFL, O_NONBLOCK) == -1) { + event_warn("fcntl(%d, F_SETFL)", fd); + return -1; + } + return 0; +#endif +} + +int +evutil_make_listen_socket_reuseable(evutil_socket_t sock) +{ +#ifndef _WIN32 + int one = 1; + /* REUSEADDR on Unix means, "don't hang on to this address after the + * listener is closed." On Windows, though, it means "don't keep other + * processes from binding to this address while we're using it. */ + return setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, (void*) &one, + (ev_socklen_t)sizeof(one)); +#else + return 0; +#endif +} + +int +evutil_make_listen_socket_reuseable_port(evutil_socket_t sock) +{ +#if defined __linux__ && defined(SO_REUSEPORT) + int one = 1; + /* REUSEPORT on Linux 3.9+ means, "Multiple servers (processes or + * threads) can bind to the same port if they each set the option. */ + return setsockopt(sock, SOL_SOCKET, SO_REUSEPORT, (void*) &one, + (ev_socklen_t)sizeof(one)); +#else + return 0; +#endif +} + +int +evutil_make_tcp_listen_socket_deferred(evutil_socket_t sock) +{ +#if defined(EVENT__HAVE_NETINET_TCP_H) && defined(TCP_DEFER_ACCEPT) + int one = 1; + + /* TCP_DEFER_ACCEPT tells the kernel to call defer accept() only after data + * has arrived and ready to read */ + return setsockopt(sock, IPPROTO_TCP, TCP_DEFER_ACCEPT, &one, + (ev_socklen_t)sizeof(one)); +#endif + return 0; +} + +int +evutil_make_socket_closeonexec(evutil_socket_t fd) +{ +#if !defined(_WIN32) && defined(EVENT__HAVE_SETFD) + int flags; + if ((flags = fcntl(fd, F_GETFD, NULL)) < 0) { + event_warn("fcntl(%d, F_GETFD)", fd); + return -1; + } + if (!(flags & FD_CLOEXEC)) { + if (fcntl(fd, F_SETFD, flags | FD_CLOEXEC) == -1) { + event_warn("fcntl(%d, F_SETFD)", fd); + return -1; + } + } +#endif + return 0; +} + +/* Faster version of evutil_make_socket_closeonexec for internal use. + * + * Requires that no F_SETFD flags were previously set on the fd. + */ +static int +evutil_fast_socket_closeonexec(evutil_socket_t fd) +{ +#if !defined(_WIN32) && defined(EVENT__HAVE_SETFD) + if (fcntl(fd, F_SETFD, FD_CLOEXEC) == -1) { + event_warn("fcntl(%d, F_SETFD)", fd); + return -1; + } +#endif + return 0; +} + +int +evutil_closesocket(evutil_socket_t sock) +{ +#ifndef _WIN32 + return close(sock); +#else + return closesocket(sock); +#endif +} + +ev_int64_t +evutil_strtoll(const char *s, char **endptr, int base) +{ +#ifdef EVENT__HAVE_STRTOLL + return (ev_int64_t)strtoll(s, endptr, base); +#elif EVENT__SIZEOF_LONG == 8 + return (ev_int64_t)strtol(s, endptr, base); +#elif defined(_WIN32) && defined(_MSC_VER) && _MSC_VER < 1300 + /* XXXX on old versions of MS APIs, we only support base + * 10. */ + ev_int64_t r; + if (base != 10) + return 0; + r = (ev_int64_t) _atoi64(s); + while (isspace(*s)) + ++s; + if (*s == '-') + ++s; + while (isdigit(*s)) + ++s; + if (endptr) + *endptr = (char*) s; + return r; +#elif defined(_WIN32) + return (ev_int64_t) _strtoi64(s, endptr, base); +#elif defined(EVENT__SIZEOF_LONG_LONG) && EVENT__SIZEOF_LONG_LONG == 8 + long long r; + int n; + if (base != 10 && base != 16) + return 0; + if (base == 10) { + n = sscanf(s, "%lld", &r); + } else { + unsigned long long ru=0; + n = sscanf(s, "%llx", &ru); + if (ru > EV_INT64_MAX) + return 0; + r = (long long) ru; + } + if (n != 1) + return 0; + while (EVUTIL_ISSPACE_(*s)) + ++s; + if (*s == '-') + ++s; + if (base == 10) { + while (EVUTIL_ISDIGIT_(*s)) + ++s; + } else { + while (EVUTIL_ISXDIGIT_(*s)) + ++s; + } + if (endptr) + *endptr = (char*) s; + return r; +#else +#error "I don't know how to parse 64-bit integers." +#endif +} + +#ifdef _WIN32 +int +evutil_socket_geterror(evutil_socket_t sock) +{ + int optval, optvallen=sizeof(optval); + int err = WSAGetLastError(); + if (err == WSAEWOULDBLOCK && sock >= 0) { + if (getsockopt(sock, SOL_SOCKET, SO_ERROR, (void*)&optval, + &optvallen)) + return err; + if (optval) + return optval; + } + return err; +} +#endif + +/* XXX we should use an enum here. */ +/* 2 for connection refused, 1 for connected, 0 for not yet, -1 for error. */ +int +evutil_socket_connect_(evutil_socket_t *fd_ptr, struct sockaddr *sa, int socklen) +{ + int made_fd = 0; + + if (*fd_ptr < 0) { + if ((*fd_ptr = socket(sa->sa_family, SOCK_STREAM, 0)) < 0) + goto err; + made_fd = 1; + if (evutil_make_socket_nonblocking(*fd_ptr) < 0) { + goto err; + } + } + + if (connect(*fd_ptr, sa, socklen) < 0) { + int e = evutil_socket_geterror(*fd_ptr); + if (EVUTIL_ERR_CONNECT_RETRIABLE(e)) + return 0; + if (EVUTIL_ERR_CONNECT_REFUSED(e)) + return 2; + goto err; + } else { + return 1; + } + +err: + if (made_fd) { + evutil_closesocket(*fd_ptr); + *fd_ptr = -1; + } + return -1; +} + +/* Check whether a socket on which we called connect() is done + connecting. Return 1 for connected, 0 for not yet, -1 for error. In the + error case, set the current socket errno to the error that happened during + the connect operation. */ +int +evutil_socket_finished_connecting_(evutil_socket_t fd) +{ + int e; + ev_socklen_t elen = sizeof(e); + + if (getsockopt(fd, SOL_SOCKET, SO_ERROR, (void*)&e, &elen) < 0) + return -1; + + if (e) { + if (EVUTIL_ERR_CONNECT_RETRIABLE(e)) + return 0; + EVUTIL_SET_SOCKET_ERROR(e); + return -1; + } + + return 1; +} + +#if (EVUTIL_AI_PASSIVE|EVUTIL_AI_CANONNAME|EVUTIL_AI_NUMERICHOST| \ + EVUTIL_AI_NUMERICSERV|EVUTIL_AI_V4MAPPED|EVUTIL_AI_ALL| \ + EVUTIL_AI_ADDRCONFIG) != \ + (EVUTIL_AI_PASSIVE^EVUTIL_AI_CANONNAME^EVUTIL_AI_NUMERICHOST^ \ + EVUTIL_AI_NUMERICSERV^EVUTIL_AI_V4MAPPED^EVUTIL_AI_ALL^ \ + EVUTIL_AI_ADDRCONFIG) +#error "Some of our EVUTIL_AI_* flags seem to overlap with system AI_* flags" +#endif + +/* We sometimes need to know whether we have an ipv4 address and whether we + have an ipv6 address. If 'have_checked_interfaces', then we've already done + the test. If 'had_ipv4_address', then it turns out we had an ipv4 address. + If 'had_ipv6_address', then it turns out we had an ipv6 address. These are + set by evutil_check_interfaces. */ +static int have_checked_interfaces, had_ipv4_address, had_ipv6_address; + +/* Macro: True iff the IPv4 address 'addr', in host order, is in 127.0.0.0/8 + */ +#define EVUTIL_V4ADDR_IS_LOCALHOST(addr) (((addr)>>24) == 127) + +/* Macro: True iff the IPv4 address 'addr', in host order, is a class D + * (multiclass) address. + */ +#define EVUTIL_V4ADDR_IS_CLASSD(addr) ((((addr)>>24) & 0xf0) == 0xe0) + +static void +evutil_found_ifaddr(const struct sockaddr *sa) +{ + const char ZEROES[] = "\x00\x00\x00\x00\x00\x00\x00\x00" + "\x00\x00\x00\x00\x00\x00\x00\x00"; + + if (sa->sa_family == AF_INET) { + const struct sockaddr_in *sin = (struct sockaddr_in *)sa; + ev_uint32_t addr = ntohl(sin->sin_addr.s_addr); + if (addr == 0 || + EVUTIL_V4ADDR_IS_LOCALHOST(addr) || + EVUTIL_V4ADDR_IS_CLASSD(addr)) { + /* Not actually a usable external address. */ + } else { + event_debug(("Detected an IPv4 interface")); + had_ipv4_address = 1; + } + } else if (sa->sa_family == AF_INET6) { + const struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)sa; + const unsigned char *addr = + (unsigned char*)sin6->sin6_addr.s6_addr; + if (!memcmp(addr, ZEROES, 8) || + ((addr[0] & 0xfe) == 0xfc) || + (addr[0] == 0xfe && (addr[1] & 0xc0) == 0x80) || + (addr[0] == 0xfe && (addr[1] & 0xc0) == 0xc0) || + (addr[0] == 0xff)) { + /* This is a reserved, ipv4compat, ipv4map, loopback, + * link-local, multicast, or unspecified address. */ + } else { + event_debug(("Detected an IPv6 interface")); + had_ipv6_address = 1; + } + } +} + +#ifdef _WIN32 +typedef ULONG (WINAPI *GetAdaptersAddresses_fn_t)( + ULONG, ULONG, PVOID, PIP_ADAPTER_ADDRESSES, PULONG); +#endif + +static int +evutil_check_ifaddrs(void) +{ +#if defined(EVENT__HAVE_GETIFADDRS) + /* Most free Unixy systems provide getifaddrs, which gives us a linked list + * of struct ifaddrs. */ + struct ifaddrs *ifa = NULL; + const struct ifaddrs *i; + if (getifaddrs(&ifa) < 0) { + event_warn("Unable to call getifaddrs()"); + return -1; + } + + for (i = ifa; i; i = i->ifa_next) { + if (!i->ifa_addr) + continue; + evutil_found_ifaddr(i->ifa_addr); + } + + freeifaddrs(ifa); + return 0; +#elif defined(_WIN32) + /* Windows XP began to provide GetAdaptersAddresses. Windows 2000 had a + "GetAdaptersInfo", but that's deprecated; let's just try + GetAdaptersAddresses and fall back to connect+getsockname. + */ + HMODULE lib = evutil_load_windows_system_library_(TEXT("ihplapi.dll")); + GetAdaptersAddresses_fn_t fn; + ULONG size, res; + IP_ADAPTER_ADDRESSES *addresses = NULL, *address; + int result = -1; + +#define FLAGS (GAA_FLAG_SKIP_ANYCAST | \ + GAA_FLAG_SKIP_MULTICAST | \ + GAA_FLAG_SKIP_DNS_SERVER) + + if (!lib) + goto done; + + if (!(fn = (GetAdaptersAddresses_fn_t) GetProcAddress(lib, "GetAdaptersAddresses"))) + goto done; + + /* Guess how much space we need. */ + size = 15*1024; + addresses = mm_malloc(size); + if (!addresses) + goto done; + res = fn(AF_UNSPEC, FLAGS, NULL, addresses, &size); + if (res == ERROR_BUFFER_OVERFLOW) { + /* we didn't guess that we needed enough space; try again */ + mm_free(addresses); + addresses = mm_malloc(size); + if (!addresses) + goto done; + res = fn(AF_UNSPEC, FLAGS, NULL, addresses, &size); + } + if (res != NO_ERROR) + goto done; + + for (address = addresses; address; address = address->Next) { + IP_ADAPTER_UNICAST_ADDRESS *a; + for (a = address->FirstUnicastAddress; a; a = a->Next) { + /* Yes, it's a linked list inside a linked list */ + struct sockaddr *sa = a->Address.lpSockaddr; + evutil_found_ifaddr(sa); + } + } + + result = 0; +done: + if (lib) + FreeLibrary(lib); + if (addresses) + mm_free(addresses); + return result; +#else + return -1; +#endif +} + +/* Test whether we have an ipv4 interface and an ipv6 interface. Return 0 if + * the test seemed successful. */ +static int +evutil_check_interfaces(int force_recheck) +{ + evutil_socket_t fd = -1; + struct sockaddr_in sin, sin_out; + struct sockaddr_in6 sin6, sin6_out; + ev_socklen_t sin_out_len = sizeof(sin_out); + ev_socklen_t sin6_out_len = sizeof(sin6_out); + int r; + if (have_checked_interfaces && !force_recheck) + return 0; + + if (evutil_check_ifaddrs() == 0) { + /* Use a nice sane interface, if this system has one. */ + return 0; + } + + /* Ugh. There was no nice sane interface. So to check whether we have + * an interface open for a given protocol, will try to make a UDP + * 'connection' to a remote host on the internet. We don't actually + * use it, so the address doesn't matter, but we want to pick one that + * keep us from using a host- or link-local interface. */ + memset(&sin, 0, sizeof(sin)); + sin.sin_family = AF_INET; + sin.sin_port = htons(53); + r = evutil_inet_pton(AF_INET, "18.244.0.188", &sin.sin_addr); + EVUTIL_ASSERT(r); + + memset(&sin6, 0, sizeof(sin6)); + sin6.sin6_family = AF_INET6; + sin6.sin6_port = htons(53); + r = evutil_inet_pton(AF_INET6, "2001:4860:b002::68", &sin6.sin6_addr); + EVUTIL_ASSERT(r); + + memset(&sin_out, 0, sizeof(sin_out)); + memset(&sin6_out, 0, sizeof(sin6_out)); + + /* XXX some errnos mean 'no address'; some mean 'not enough sockets'. */ + if ((fd = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP)) >= 0 && + connect(fd, (struct sockaddr*)&sin, sizeof(sin)) == 0 && + getsockname(fd, (struct sockaddr*)&sin_out, &sin_out_len) == 0) { + /* We might have an IPv4 interface. */ + evutil_found_ifaddr((struct sockaddr*) &sin_out); + } + if (fd >= 0) + evutil_closesocket(fd); + + if ((fd = socket(AF_INET6, SOCK_DGRAM, IPPROTO_UDP)) >= 0 && + connect(fd, (struct sockaddr*)&sin6, sizeof(sin6)) == 0 && + getsockname(fd, (struct sockaddr*)&sin6_out, &sin6_out_len) == 0) { + /* We might have an IPv6 interface. */ + evutil_found_ifaddr((struct sockaddr*) &sin6_out); + } + + if (fd >= 0) + evutil_closesocket(fd); + + return 0; +} + +/* Internal addrinfo flag. This one is set when we allocate the addrinfo from + * inside libevent. Otherwise, the built-in getaddrinfo() function allocated + * it, and we should trust what they said. + **/ +#define EVUTIL_AI_LIBEVENT_ALLOCATED 0x80000000 + +/* Helper: construct a new addrinfo containing the socket address in + * 'sa', which must be a sockaddr_in or a sockaddr_in6. Take the + * socktype and protocol info from hints. If they weren't set, then + * allocate both a TCP and a UDP addrinfo. + */ +struct evutil_addrinfo * +evutil_new_addrinfo_(struct sockaddr *sa, ev_socklen_t socklen, + const struct evutil_addrinfo *hints) +{ + struct evutil_addrinfo *res; + EVUTIL_ASSERT(hints); + + if (hints->ai_socktype == 0 && hints->ai_protocol == 0) { + /* Indecisive user! Give them a UDP and a TCP. */ + struct evutil_addrinfo *r1, *r2; + struct evutil_addrinfo tmp; + memcpy(&tmp, hints, sizeof(tmp)); + tmp.ai_socktype = SOCK_STREAM; tmp.ai_protocol = IPPROTO_TCP; + r1 = evutil_new_addrinfo_(sa, socklen, &tmp); + if (!r1) + return NULL; + tmp.ai_socktype = SOCK_DGRAM; tmp.ai_protocol = IPPROTO_UDP; + r2 = evutil_new_addrinfo_(sa, socklen, &tmp); + if (!r2) { + evutil_freeaddrinfo(r1); + return NULL; + } + r1->ai_next = r2; + return r1; + } + + /* We're going to allocate extra space to hold the sockaddr. */ + res = mm_calloc(1,sizeof(struct evutil_addrinfo)+socklen); + if (!res) + return NULL; + res->ai_addr = (struct sockaddr*) + (((char*)res) + sizeof(struct evutil_addrinfo)); + memcpy(res->ai_addr, sa, socklen); + res->ai_addrlen = socklen; + res->ai_family = sa->sa_family; /* Same or not? XXX */ + res->ai_flags = EVUTIL_AI_LIBEVENT_ALLOCATED; + res->ai_socktype = hints->ai_socktype; + res->ai_protocol = hints->ai_protocol; + + return res; +} + +/* Append the addrinfo 'append' to the end of 'first', and return the start of + * the list. Either element can be NULL, in which case we return the element + * that is not NULL. */ +struct evutil_addrinfo * +evutil_addrinfo_append_(struct evutil_addrinfo *first, + struct evutil_addrinfo *append) +{ + struct evutil_addrinfo *ai = first; + if (!ai) + return append; + while (ai->ai_next) + ai = ai->ai_next; + ai->ai_next = append; + + return first; +} + +static int +parse_numeric_servname(const char *servname) +{ + int n; + char *endptr=NULL; + n = (int) strtol(servname, &endptr, 10); + if (n>=0 && n <= 65535 && servname[0] && endptr && !endptr[0]) + return n; + else + return -1; +} + +/** Parse a service name in 'servname', which can be a decimal port. + * Return the port number, or -1 on error. + */ +static int +evutil_parse_servname(const char *servname, const char *protocol, + const struct evutil_addrinfo *hints) +{ + int n = parse_numeric_servname(servname); + if (n>=0) + return n; +#if defined(EVENT__HAVE_GETSERVBYNAME) || defined(_WIN32) + if (!(hints->ai_flags & EVUTIL_AI_NUMERICSERV)) { + struct servent *ent = getservbyname(servname, protocol); + if (ent) { + return ntohs(ent->s_port); + } + } +#endif + return -1; +} + +/* Return a string corresponding to a protocol number that we can pass to + * getservyname. */ +static const char * +evutil_unparse_protoname(int proto) +{ + switch (proto) { + case 0: + return NULL; + case IPPROTO_TCP: + return "tcp"; + case IPPROTO_UDP: + return "udp"; +#ifdef IPPROTO_SCTP + case IPPROTO_SCTP: + return "sctp"; +#endif + default: +#ifdef EVENT__HAVE_GETPROTOBYNUMBER + { + struct protoent *ent = getprotobynumber(proto); + if (ent) + return ent->p_name; + } +#endif + return NULL; + } +} + +static void +evutil_getaddrinfo_infer_protocols(struct evutil_addrinfo *hints) +{ + /* If we can guess the protocol from the socktype, do so. */ + if (!hints->ai_protocol && hints->ai_socktype) { + if (hints->ai_socktype == SOCK_DGRAM) + hints->ai_protocol = IPPROTO_UDP; + else if (hints->ai_socktype == SOCK_STREAM) + hints->ai_protocol = IPPROTO_TCP; + } + + /* Set the socktype if it isn't set. */ + if (!hints->ai_socktype && hints->ai_protocol) { + if (hints->ai_protocol == IPPROTO_UDP) + hints->ai_socktype = SOCK_DGRAM; + else if (hints->ai_protocol == IPPROTO_TCP) + hints->ai_socktype = SOCK_STREAM; +#ifdef IPPROTO_SCTP + else if (hints->ai_protocol == IPPROTO_SCTP) + hints->ai_socktype = SOCK_STREAM; +#endif + } +} + +#if AF_UNSPEC != PF_UNSPEC +#error "I cannot build on a system where AF_UNSPEC != PF_UNSPEC" +#endif + +/** Implements the part of looking up hosts by name that's common to both + * the blocking and nonblocking resolver: + * - Adjust 'hints' to have a reasonable socktype and protocol. + * - Look up the port based on 'servname', and store it in *portnum, + * - Handle the nodename==NULL case + * - Handle some invalid arguments cases. + * - Handle the cases where nodename is an IPv4 or IPv6 address. + * + * If we need the resolver to look up the hostname, we return + * EVUTIL_EAI_NEED_RESOLVE. Otherwise, we can completely implement + * getaddrinfo: we return 0 or an appropriate EVUTIL_EAI_* error, and + * set *res as getaddrinfo would. + */ +int +evutil_getaddrinfo_common_(const char *nodename, const char *servname, + struct evutil_addrinfo *hints, struct evutil_addrinfo **res, int *portnum) +{ + int port = 0; + const char *pname; + + if (nodename == NULL && servname == NULL) + return EVUTIL_EAI_NONAME; + + /* We only understand 3 families */ + if (hints->ai_family != PF_UNSPEC && hints->ai_family != PF_INET && + hints->ai_family != PF_INET6) + return EVUTIL_EAI_FAMILY; + + evutil_getaddrinfo_infer_protocols(hints); + + /* Look up the port number and protocol, if possible. */ + pname = evutil_unparse_protoname(hints->ai_protocol); + if (servname) { + /* XXXX We could look at the protocol we got back from + * getservbyname, but it doesn't seem too useful. */ + port = evutil_parse_servname(servname, pname, hints); + if (port < 0) { + return EVUTIL_EAI_NONAME; + } + } + + /* If we have no node name, then we're supposed to bind to 'any' and + * connect to localhost. */ + if (nodename == NULL) { + struct evutil_addrinfo *res4=NULL, *res6=NULL; + if (hints->ai_family != PF_INET) { /* INET6 or UNSPEC. */ + struct sockaddr_in6 sin6; + memset(&sin6, 0, sizeof(sin6)); + sin6.sin6_family = AF_INET6; + sin6.sin6_port = htons(port); + if (hints->ai_flags & EVUTIL_AI_PASSIVE) { + /* Bind to :: */ + } else { + /* connect to ::1 */ + sin6.sin6_addr.s6_addr[15] = 1; + } + res6 = evutil_new_addrinfo_((struct sockaddr*)&sin6, + sizeof(sin6), hints); + if (!res6) + return EVUTIL_EAI_MEMORY; + } + + if (hints->ai_family != PF_INET6) { /* INET or UNSPEC */ + struct sockaddr_in sin; + memset(&sin, 0, sizeof(sin)); + sin.sin_family = AF_INET; + sin.sin_port = htons(port); + if (hints->ai_flags & EVUTIL_AI_PASSIVE) { + /* Bind to 0.0.0.0 */ + } else { + /* connect to 127.0.0.1 */ + sin.sin_addr.s_addr = htonl(0x7f000001); + } + res4 = evutil_new_addrinfo_((struct sockaddr*)&sin, + sizeof(sin), hints); + if (!res4) { + if (res6) + evutil_freeaddrinfo(res6); + return EVUTIL_EAI_MEMORY; + } + } + *res = evutil_addrinfo_append_(res4, res6); + return 0; + } + + /* If we can, we should try to parse the hostname without resolving + * it. */ + /* Try ipv6. */ + if (hints->ai_family == PF_INET6 || hints->ai_family == PF_UNSPEC) { + struct sockaddr_in6 sin6; + memset(&sin6, 0, sizeof(sin6)); + if (1==evutil_inet_pton(AF_INET6, nodename, &sin6.sin6_addr)) { + /* Got an ipv6 address. */ + sin6.sin6_family = AF_INET6; + sin6.sin6_port = htons(port); + *res = evutil_new_addrinfo_((struct sockaddr*)&sin6, + sizeof(sin6), hints); + if (!*res) + return EVUTIL_EAI_MEMORY; + return 0; + } + } + + /* Try ipv4. */ + if (hints->ai_family == PF_INET || hints->ai_family == PF_UNSPEC) { + struct sockaddr_in sin; + memset(&sin, 0, sizeof(sin)); + if (1==evutil_inet_pton(AF_INET, nodename, &sin.sin_addr)) { + /* Got an ipv6 address. */ + sin.sin_family = AF_INET; + sin.sin_port = htons(port); + *res = evutil_new_addrinfo_((struct sockaddr*)&sin, + sizeof(sin), hints); + if (!*res) + return EVUTIL_EAI_MEMORY; + return 0; + } + } + + + /* If we have reached this point, we definitely need to do a DNS + * lookup. */ + if ((hints->ai_flags & EVUTIL_AI_NUMERICHOST)) { + /* If we're not allowed to do one, then say so. */ + return EVUTIL_EAI_NONAME; + } + *portnum = port; + return EVUTIL_EAI_NEED_RESOLVE; +} + +#ifdef EVENT__HAVE_GETADDRINFO +#define USE_NATIVE_GETADDRINFO +#endif + +#ifdef USE_NATIVE_GETADDRINFO +/* A mask of all the flags that we declare, so we can clear them before calling + * the native getaddrinfo */ +static const unsigned int ALL_NONNATIVE_AI_FLAGS = +#ifndef AI_PASSIVE + EVUTIL_AI_PASSIVE | +#endif +#ifndef AI_CANONNAME + EVUTIL_AI_CANONNAME | +#endif +#ifndef AI_NUMERICHOST + EVUTIL_AI_NUMERICHOST | +#endif +#ifndef AI_NUMERICSERV + EVUTIL_AI_NUMERICSERV | +#endif +#ifndef AI_ADDRCONFIG + EVUTIL_AI_ADDRCONFIG | +#endif +#ifndef AI_ALL + EVUTIL_AI_ALL | +#endif +#ifndef AI_V4MAPPED + EVUTIL_AI_V4MAPPED | +#endif + EVUTIL_AI_LIBEVENT_ALLOCATED; + +static const unsigned int ALL_NATIVE_AI_FLAGS = +#ifdef AI_PASSIVE + AI_PASSIVE | +#endif +#ifdef AI_CANONNAME + AI_CANONNAME | +#endif +#ifdef AI_NUMERICHOST + AI_NUMERICHOST | +#endif +#ifdef AI_NUMERICSERV + AI_NUMERICSERV | +#endif +#ifdef AI_ADDRCONFIG + AI_ADDRCONFIG | +#endif +#ifdef AI_ALL + AI_ALL | +#endif +#ifdef AI_V4MAPPED + AI_V4MAPPED | +#endif + 0; +#endif + +#ifndef USE_NATIVE_GETADDRINFO +/* Helper for systems with no getaddrinfo(): make one or more addrinfos out of + * a struct hostent. + */ +static struct evutil_addrinfo * +addrinfo_from_hostent(const struct hostent *ent, + int port, const struct evutil_addrinfo *hints) +{ + int i; + struct sockaddr_in sin; + struct sockaddr_in6 sin6; + struct sockaddr *sa; + int socklen; + struct evutil_addrinfo *res=NULL, *ai; + void *addrp; + + if (ent->h_addrtype == PF_INET) { + memset(&sin, 0, sizeof(sin)); + sin.sin_family = AF_INET; + sin.sin_port = htons(port); + sa = (struct sockaddr *)&sin; + socklen = sizeof(struct sockaddr_in); + addrp = &sin.sin_addr; + if (ent->h_length != sizeof(sin.sin_addr)) { + event_warnx("Weird h_length from gethostbyname"); + return NULL; + } + } else if (ent->h_addrtype == PF_INET6) { + memset(&sin6, 0, sizeof(sin6)); + sin6.sin6_family = AF_INET6; + sin6.sin6_port = htons(port); + sa = (struct sockaddr *)&sin6; + socklen = sizeof(struct sockaddr_in); + addrp = &sin6.sin6_addr; + if (ent->h_length != sizeof(sin6.sin6_addr)) { + event_warnx("Weird h_length from gethostbyname"); + return NULL; + } + } else + return NULL; + + for (i = 0; ent->h_addr_list[i]; ++i) { + memcpy(addrp, ent->h_addr_list[i], ent->h_length); + ai = evutil_new_addrinfo_(sa, socklen, hints); + if (!ai) { + evutil_freeaddrinfo(res); + return NULL; + } + res = evutil_addrinfo_append_(res, ai); + } + + if (res && ((hints->ai_flags & EVUTIL_AI_CANONNAME) && ent->h_name)) { + res->ai_canonname = mm_strdup(ent->h_name); + if (res->ai_canonname == NULL) { + evutil_freeaddrinfo(res); + return NULL; + } + } + + return res; +} +#endif + +/* If the EVUTIL_AI_ADDRCONFIG flag is set on hints->ai_flags, and + * hints->ai_family is PF_UNSPEC, then revise the value of hints->ai_family so + * that we'll only get addresses we could maybe connect to. + */ +void +evutil_adjust_hints_for_addrconfig_(struct evutil_addrinfo *hints) +{ + if (!(hints->ai_flags & EVUTIL_AI_ADDRCONFIG)) + return; + if (hints->ai_family != PF_UNSPEC) + return; + if (!have_checked_interfaces) + evutil_check_interfaces(0); + if (had_ipv4_address && !had_ipv6_address) { + hints->ai_family = PF_INET; + } else if (!had_ipv4_address && had_ipv6_address) { + hints->ai_family = PF_INET6; + } +} + +#ifdef USE_NATIVE_GETADDRINFO +static int need_numeric_port_hack_=0; +static int need_socktype_protocol_hack_=0; +static int tested_for_getaddrinfo_hacks=0; + +/* Some older BSDs (like OpenBSD up to 4.6) used to believe that + giving a numeric port without giving an ai_socktype was verboten. + We test for this so we can apply an appropriate workaround. If it + turns out that the bug is present, then: + + - If nodename==NULL and servname is numeric, we build an answer + ourselves using evutil_getaddrinfo_common_(). + + - If nodename!=NULL and servname is numeric, then we set + servname=NULL when calling getaddrinfo, and post-process the + result to set the ports on it. + + We test for this bug at runtime, since otherwise we can't have the + same binary run on multiple BSD versions. + + - Some versions of Solaris believe that it's nice to leave to protocol + field set to 0. We test for this so we can apply an appropriate + workaround. +*/ +static void +test_for_getaddrinfo_hacks(void) +{ + int r, r2; + struct evutil_addrinfo *ai=NULL, *ai2=NULL; + struct evutil_addrinfo hints; + + memset(&hints,0,sizeof(hints)); + hints.ai_family = PF_UNSPEC; + hints.ai_flags = +#ifdef AI_NUMERICHOST + AI_NUMERICHOST | +#endif +#ifdef AI_NUMERICSERV + AI_NUMERICSERV | +#endif + 0; + r = getaddrinfo("1.2.3.4", "80", &hints, &ai); + hints.ai_socktype = SOCK_STREAM; + r2 = getaddrinfo("1.2.3.4", "80", &hints, &ai2); + if (r2 == 0 && r != 0) { + need_numeric_port_hack_=1; + } + if (ai2 && ai2->ai_protocol == 0) { + need_socktype_protocol_hack_=1; + } + + if (ai) + freeaddrinfo(ai); + if (ai2) + freeaddrinfo(ai2); + tested_for_getaddrinfo_hacks=1; +} + +static inline int +need_numeric_port_hack(void) +{ + if (!tested_for_getaddrinfo_hacks) + test_for_getaddrinfo_hacks(); + return need_numeric_port_hack_; +} + +static inline int +need_socktype_protocol_hack(void) +{ + if (!tested_for_getaddrinfo_hacks) + test_for_getaddrinfo_hacks(); + return need_socktype_protocol_hack_; +} + +static void +apply_numeric_port_hack(int port, struct evutil_addrinfo **ai) +{ + /* Now we run through the list and set the ports on all of the + * results where ports would make sense. */ + for ( ; *ai; ai = &(*ai)->ai_next) { + struct sockaddr *sa = (*ai)->ai_addr; + if (sa && sa->sa_family == AF_INET) { + struct sockaddr_in *sin = (struct sockaddr_in*)sa; + sin->sin_port = htons(port); + } else if (sa && sa->sa_family == AF_INET6) { + struct sockaddr_in6 *sin6 = (struct sockaddr_in6*)sa; + sin6->sin6_port = htons(port); + } else { + /* A numeric port makes no sense here; remove this one + * from the list. */ + struct evutil_addrinfo *victim = *ai; + *ai = victim->ai_next; + victim->ai_next = NULL; + freeaddrinfo(victim); + } + } +} + +static int +apply_socktype_protocol_hack(struct evutil_addrinfo *ai) +{ + struct evutil_addrinfo *ai_new; + for (; ai; ai = ai->ai_next) { + evutil_getaddrinfo_infer_protocols(ai); + if (ai->ai_socktype || ai->ai_protocol) + continue; + ai_new = mm_malloc(sizeof(*ai_new)); + if (!ai_new) + return -1; + memcpy(ai_new, ai, sizeof(*ai_new)); + ai->ai_socktype = SOCK_STREAM; + ai->ai_protocol = IPPROTO_TCP; + ai_new->ai_socktype = SOCK_DGRAM; + ai_new->ai_protocol = IPPROTO_UDP; + + ai_new->ai_next = ai->ai_next; + ai->ai_next = ai_new; + } + return 0; +} +#endif + +int +evutil_getaddrinfo(const char *nodename, const char *servname, + const struct evutil_addrinfo *hints_in, struct evutil_addrinfo **res) +{ +#ifdef USE_NATIVE_GETADDRINFO + struct evutil_addrinfo hints; + int portnum=-1, need_np_hack, err; + + if (hints_in) { + memcpy(&hints, hints_in, sizeof(hints)); + } else { + memset(&hints, 0, sizeof(hints)); + hints.ai_family = PF_UNSPEC; + } + +#ifndef AI_ADDRCONFIG + /* Not every system has AI_ADDRCONFIG, so fake it. */ + if (hints.ai_family == PF_UNSPEC && + (hints.ai_flags & EVUTIL_AI_ADDRCONFIG)) { + evutil_adjust_hints_for_addrconfig_(&hints); + } +#endif + +#ifndef AI_NUMERICSERV + /* Not every system has AI_NUMERICSERV, so fake it. */ + if (hints.ai_flags & EVUTIL_AI_NUMERICSERV) { + if (servname && parse_numeric_servname(servname)<0) + return EVUTIL_EAI_NONAME; + } +#endif + + /* Enough operating systems handle enough common non-resolve + * cases here weirdly enough that we are better off just + * overriding them. For example: + * + * - Windows doesn't like to infer the protocol from the + * socket type, or fill in socket or protocol types much at + * all. It also seems to do its own broken implicit + * always-on version of AI_ADDRCONFIG that keeps it from + * ever resolving even a literal IPv6 address when + * ai_addrtype is PF_UNSPEC. + */ +#ifdef _WIN32 + { + int tmp_port; + err = evutil_getaddrinfo_common_(nodename,servname,&hints, + res, &tmp_port); + if (err == 0 || + err == EVUTIL_EAI_MEMORY || + err == EVUTIL_EAI_NONAME) + return err; + /* If we make it here, the system getaddrinfo can + * have a crack at it. */ + } +#endif + + /* See documentation for need_numeric_port_hack above.*/ + need_np_hack = need_numeric_port_hack() && servname && !hints.ai_socktype + && ((portnum=parse_numeric_servname(servname)) >= 0); + if (need_np_hack) { + if (!nodename) + return evutil_getaddrinfo_common_( + NULL,servname,&hints, res, &portnum); + servname = NULL; + } + + if (need_socktype_protocol_hack()) { + evutil_getaddrinfo_infer_protocols(&hints); + } + + /* Make sure that we didn't actually steal any AI_FLAGS values that + * the system is using. (This is a constant expression, and should ge + * optimized out.) + * + * XXXX Turn this into a compile-time failure rather than a run-time + * failure. + */ + EVUTIL_ASSERT((ALL_NONNATIVE_AI_FLAGS & ALL_NATIVE_AI_FLAGS) == 0); + + /* Clear any flags that only libevent understands. */ + hints.ai_flags &= ~ALL_NONNATIVE_AI_FLAGS; + + err = getaddrinfo(nodename, servname, &hints, res); + if (need_np_hack) + apply_numeric_port_hack(portnum, res); + + if (need_socktype_protocol_hack()) { + if (apply_socktype_protocol_hack(*res) < 0) { + evutil_freeaddrinfo(*res); + *res = NULL; + return EVUTIL_EAI_MEMORY; + } + } + return err; +#else + int port=0, err; + struct hostent *ent = NULL; + struct evutil_addrinfo hints; + + if (hints_in) { + memcpy(&hints, hints_in, sizeof(hints)); + } else { + memset(&hints, 0, sizeof(hints)); + hints.ai_family = PF_UNSPEC; + } + + evutil_adjust_hints_for_addrconfig_(&hints); + + err = evutil_getaddrinfo_common_(nodename, servname, &hints, res, &port); + if (err != EVUTIL_EAI_NEED_RESOLVE) { + /* We either succeeded or failed. No need to continue */ + return err; + } + + err = 0; + /* Use any of the various gethostbyname_r variants as available. */ + { +#ifdef EVENT__HAVE_GETHOSTBYNAME_R_6_ARG + /* This one is what glibc provides. */ + char buf[2048]; + struct hostent hostent; + int r; + r = gethostbyname_r(nodename, &hostent, buf, sizeof(buf), &ent, + &err); +#elif defined(EVENT__HAVE_GETHOSTBYNAME_R_5_ARG) + char buf[2048]; + struct hostent hostent; + ent = gethostbyname_r(nodename, &hostent, buf, sizeof(buf), + &err); +#elif defined(EVENT__HAVE_GETHOSTBYNAME_R_3_ARG) + struct hostent_data data; + struct hostent hostent; + memset(&data, 0, sizeof(data)); + err = gethostbyname_r(nodename, &hostent, &data); + ent = err ? NULL : &hostent; +#else + /* fall back to gethostbyname. */ + /* XXXX This needs a lock everywhere but Windows. */ + ent = gethostbyname(nodename); +#ifdef _WIN32 + err = WSAGetLastError(); +#else + err = h_errno; +#endif +#endif + + /* Now we have either ent or err set. */ + if (!ent) { + /* XXX is this right for windows ? */ + switch (err) { + case TRY_AGAIN: + return EVUTIL_EAI_AGAIN; + case NO_RECOVERY: + default: + return EVUTIL_EAI_FAIL; + case HOST_NOT_FOUND: + return EVUTIL_EAI_NONAME; + case NO_ADDRESS: +#if NO_DATA != NO_ADDRESS + case NO_DATA: +#endif + return EVUTIL_EAI_NODATA; + } + } + + if (ent->h_addrtype != hints.ai_family && + hints.ai_family != PF_UNSPEC) { + /* This wasn't the type we were hoping for. Too bad + * we never had a chance to ask gethostbyname for what + * we wanted. */ + return EVUTIL_EAI_NONAME; + } + + /* Make sure we got _some_ answers. */ + if (ent->h_length == 0) + return EVUTIL_EAI_NODATA; + + /* If we got an address type we don't know how to make a + sockaddr for, give up. */ + if (ent->h_addrtype != PF_INET && ent->h_addrtype != PF_INET6) + return EVUTIL_EAI_FAMILY; + + *res = addrinfo_from_hostent(ent, port, &hints); + if (! *res) + return EVUTIL_EAI_MEMORY; + } + + return 0; +#endif +} + +void +evutil_freeaddrinfo(struct evutil_addrinfo *ai) +{ +#ifdef EVENT__HAVE_GETADDRINFO + if (!(ai->ai_flags & EVUTIL_AI_LIBEVENT_ALLOCATED)) { + freeaddrinfo(ai); + return; + } +#endif + while (ai) { + struct evutil_addrinfo *next = ai->ai_next; + if (ai->ai_canonname) + mm_free(ai->ai_canonname); + mm_free(ai); + ai = next; + } +} + +static evdns_getaddrinfo_fn evdns_getaddrinfo_impl = NULL; + +void +evutil_set_evdns_getaddrinfo_fn_(evdns_getaddrinfo_fn fn) +{ + if (!evdns_getaddrinfo_impl) + evdns_getaddrinfo_impl = fn; +} + +/* Internal helper function: act like evdns_getaddrinfo if dns_base is set; + * otherwise do a blocking resolve and pass the result to the callback in the + * way that evdns_getaddrinfo would. + */ +int +evutil_getaddrinfo_async_(struct evdns_base *dns_base, + const char *nodename, const char *servname, + const struct evutil_addrinfo *hints_in, + void (*cb)(int, struct evutil_addrinfo *, void *), void *arg) +{ + if (dns_base && evdns_getaddrinfo_impl) { + evdns_getaddrinfo_impl( + dns_base, nodename, servname, hints_in, cb, arg); + } else { + struct evutil_addrinfo *ai=NULL; + int err; + err = evutil_getaddrinfo(nodename, servname, hints_in, &ai); + cb(err, ai, arg); + } + return 0; +} + +const char * +evutil_gai_strerror(int err) +{ + /* As a sneaky side-benefit, this case statement will get most + * compilers to tell us if any of the error codes we defined + * conflict with the platform's native error codes. */ + switch (err) { + case EVUTIL_EAI_CANCEL: + return "Request canceled"; + case 0: + return "No error"; + + case EVUTIL_EAI_ADDRFAMILY: + return "address family for nodename not supported"; + case EVUTIL_EAI_AGAIN: + return "temporary failure in name resolution"; + case EVUTIL_EAI_BADFLAGS: + return "invalid value for ai_flags"; + case EVUTIL_EAI_FAIL: + return "non-recoverable failure in name resolution"; + case EVUTIL_EAI_FAMILY: + return "ai_family not supported"; + case EVUTIL_EAI_MEMORY: + return "memory allocation failure"; + case EVUTIL_EAI_NODATA: + return "no address associated with nodename"; + case EVUTIL_EAI_NONAME: + return "nodename nor servname provided, or not known"; + case EVUTIL_EAI_SERVICE: + return "servname not supported for ai_socktype"; + case EVUTIL_EAI_SOCKTYPE: + return "ai_socktype not supported"; + case EVUTIL_EAI_SYSTEM: + return "system error"; + default: +#if defined(USE_NATIVE_GETADDRINFO) && defined(_WIN32) + return gai_strerrorA(err); +#elif defined(USE_NATIVE_GETADDRINFO) + return gai_strerror(err); +#else + return "Unknown error code"; +#endif + } +} + +#ifdef _WIN32 +/* destructively remove a trailing line terminator from s */ +static void +chomp (char *s) +{ + size_t len; + if (s && (len = strlen (s)) > 0 && s[len - 1] == '\n') { + s[--len] = 0; + if (len > 0 && s[len - 1] == '\r') + s[--len] = 0; + } +} + +/* FormatMessage returns allocated strings, but evutil_socket_error_to_string + * is supposed to return a string which is good indefinitely without having + * to be freed. To make this work without leaking memory, we cache the + * string the first time FormatMessage is called on a particular error + * code, and then return the cached string on subsequent calls with the + * same code. The strings aren't freed until libevent_global_shutdown + * (or never). We use a linked list to cache the errors, because we + * only expect there to be a few dozen, and that should be fast enough. + */ + +struct cached_sock_errs_entry { + HT_ENTRY(cached_sock_errs_entry) node; + DWORD code; + char *msg; /* allocated with LocalAlloc; free with LocalFree */ +}; + +static inline unsigned +hash_cached_sock_errs(const struct cached_sock_errs_entry *e) +{ + /* Use Murmur3's 32-bit finalizer as an integer hash function */ + DWORD h = e->code; + h ^= h >> 16; + h *= 0x85ebca6b; + h ^= h >> 13; + h *= 0xc2b2ae35; + h ^= h >> 16; + return h; +} + +static inline int +eq_cached_sock_errs(const struct cached_sock_errs_entry *a, + const struct cached_sock_errs_entry *b) +{ + return a->code == b->code; +} + +#ifndef EVENT__DISABLE_THREAD_SUPPORT +static void *windows_socket_errors_lock_ = NULL; +#endif + +static HT_HEAD(cached_sock_errs_map, cached_sock_errs_entry) + windows_socket_errors = HT_INITIALIZER(); + +HT_PROTOTYPE(cached_sock_errs_map, + cached_sock_errs_entry, + node, + hash_cached_sock_errs, + eq_cached_sock_errs); + +HT_GENERATE(cached_sock_errs_map, + cached_sock_errs_entry, + node, + hash_cached_sock_errs, + eq_cached_sock_errs, + 0.5, + mm_malloc, + mm_realloc, + mm_free); + +/** Equivalent to strerror, but for windows socket errors. */ +const char * +evutil_socket_error_to_string(int errcode) +{ + struct cached_sock_errs_entry *errs, *newerr, find; + char *msg = NULL; + + EVLOCK_LOCK(windows_socket_errors_lock_, 0); + + find.code = errcode; + errs = HT_FIND(cached_sock_errs_map, &windows_socket_errors, &find); + if (errs) { + msg = errs->msg; + goto done; + } + + if (0 != FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM | + FORMAT_MESSAGE_IGNORE_INSERTS | + FORMAT_MESSAGE_ALLOCATE_BUFFER, + NULL, errcode, 0, (LPTSTR)&msg, 0, NULL)) + chomp (msg); /* because message has trailing newline */ + else { + size_t len = 50; + /* use LocalAlloc because FormatMessage does */ + msg = LocalAlloc(LMEM_FIXED, len); + if (!msg) { + msg = (char *)"LocalAlloc failed during Winsock error"; + goto done; + } + evutil_snprintf(msg, len, "winsock error 0x%08x", errcode); + } + + newerr = (struct cached_sock_errs_entry *) + mm_malloc(sizeof (struct cached_sock_errs_entry)); + + if (!newerr) { + LocalFree(msg); + msg = (char *)"malloc failed during Winsock error"; + goto done; + } + + newerr->code = errcode; + newerr->msg = msg; + HT_INSERT(cached_sock_errs_map, &windows_socket_errors, newerr); + + done: + EVLOCK_UNLOCK(windows_socket_errors_lock_, 0); + + return msg; +} + +#ifndef EVENT__DISABLE_THREAD_SUPPORT +int +evutil_global_setup_locks_(const int enable_locks) +{ + EVTHREAD_SETUP_GLOBAL_LOCK(windows_socket_errors_lock_, 0); + return 0; +} +#endif + +static void +evutil_free_sock_err_globals(void) +{ + struct cached_sock_errs_entry **errs, *tofree; + + for (errs = HT_START(cached_sock_errs_map, &windows_socket_errors) + ; errs; ) { + tofree = *errs; + errs = HT_NEXT_RMV(cached_sock_errs_map, + &windows_socket_errors, + errs); + LocalFree(tofree->msg); + mm_free(tofree); + } + + HT_CLEAR(cached_sock_errs_map, &windows_socket_errors); + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (windows_socket_errors_lock_ != NULL) { + EVTHREAD_FREE_LOCK(windows_socket_errors_lock_, 0); + windows_socket_errors_lock_ = NULL; + } +#endif +} + +#else + +#ifndef EVENT__DISABLE_THREAD_SUPPORT +int +evutil_global_setup_locks_(const int enable_locks) +{ + return 0; +} +#endif + +static void +evutil_free_sock_err_globals(void) +{ +} + +#endif + +int +evutil_snprintf(char *buf, size_t buflen, const char *format, ...) +{ + int r; + va_list ap; + va_start(ap, format); + r = evutil_vsnprintf(buf, buflen, format, ap); + va_end(ap); + return r; +} + +int +evutil_vsnprintf(char *buf, size_t buflen, const char *format, va_list ap) +{ + int r; + if (!buflen) + return 0; +#if defined(_MSC_VER) || defined(_WIN32) + r = _vsnprintf(buf, buflen, format, ap); + if (r < 0) + r = _vscprintf(format, ap); +#elif defined(sgi) + /* Make sure we always use the correct vsnprintf on IRIX */ + extern int _xpg5_vsnprintf(char * __restrict, + __SGI_LIBC_NAMESPACE_QUALIFIER size_t, + const char * __restrict, /* va_list */ char *); + + r = _xpg5_vsnprintf(buf, buflen, format, ap); +#else + r = vsnprintf(buf, buflen, format, ap); +#endif + buf[buflen-1] = '\0'; + return r; +} + +#define USE_INTERNAL_NTOP +#define USE_INTERNAL_PTON + +const char * +evutil_inet_ntop(int af, const void *src, char *dst, size_t len) +{ +#if defined(EVENT__HAVE_INET_NTOP) && !defined(USE_INTERNAL_NTOP) + return inet_ntop(af, src, dst, len); +#else + if (af == AF_INET) { + const struct in_addr *in = src; + const ev_uint32_t a = ntohl(in->s_addr); + int r; + r = evutil_snprintf(dst, len, "%d.%d.%d.%d", + (int)(ev_uint8_t)((a>>24)&0xff), + (int)(ev_uint8_t)((a>>16)&0xff), + (int)(ev_uint8_t)((a>>8 )&0xff), + (int)(ev_uint8_t)((a )&0xff)); + if (r<0||(size_t)r>=len) + return NULL; + else + return dst; +#ifdef AF_INET6 + } else if (af == AF_INET6) { + const struct in6_addr *addr = src; + char buf[64], *cp; + int longestGapLen = 0, longestGapPos = -1, i, + curGapPos = -1, curGapLen = 0; + ev_uint16_t words[8]; + for (i = 0; i < 8; ++i) { + words[i] = + (((ev_uint16_t)addr->s6_addr[2*i])<<8) + addr->s6_addr[2*i+1]; + } + if (words[0] == 0 && words[1] == 0 && words[2] == 0 && words[3] == 0 && + words[4] == 0 && ((words[5] == 0 && words[6] && words[7]) || + (words[5] == 0xffff))) { + /* This is an IPv4 address. */ + if (words[5] == 0) { + evutil_snprintf(buf, sizeof(buf), "::%d.%d.%d.%d", + addr->s6_addr[12], addr->s6_addr[13], + addr->s6_addr[14], addr->s6_addr[15]); + } else { + evutil_snprintf(buf, sizeof(buf), "::%x:%d.%d.%d.%d", words[5], + addr->s6_addr[12], addr->s6_addr[13], + addr->s6_addr[14], addr->s6_addr[15]); + } + if (strlen(buf) > len) + return NULL; + strlcpy(dst, buf, len); + return dst; + } + i = 0; + while (i < 8) { + if (words[i] == 0) { + curGapPos = i++; + curGapLen = 1; + while (i<8 && words[i] == 0) { + ++i; ++curGapLen; + } + if (curGapLen > longestGapLen) { + longestGapPos = curGapPos; + longestGapLen = curGapLen; + } + } else { + ++i; + } + } + if (longestGapLen<=1) + longestGapPos = -1; + + cp = buf; + for (i = 0; i < 8; ++i) { + if (words[i] == 0 && longestGapPos == i) { + if (i == 0) + *cp++ = ':'; + *cp++ = ':'; + while (i < 8 && words[i] == 0) + ++i; + --i; /* to compensate for loop increment. */ + } else { + evutil_snprintf(cp, + sizeof(buf)-(cp-buf), "%x", (unsigned)words[i]); + cp += strlen(cp); + if (i != 7) + *cp++ = ':'; + } + } + *cp = '\0'; + if (strlen(buf) > len) + return NULL; + strlcpy(dst, buf, len); + return dst; +#endif + } else { + return NULL; + } +#endif +} + +int +evutil_inet_pton(int af, const char *src, void *dst) +{ +#if defined(EVENT__HAVE_INET_PTON) && !defined(USE_INTERNAL_PTON) + return inet_pton(af, src, dst); +#else + if (af == AF_INET) { + unsigned a,b,c,d; + char more; + struct in_addr *addr = dst; + if (sscanf(src, "%u.%u.%u.%u%c", &a,&b,&c,&d,&more) != 4) + return 0; + if (a > 255) return 0; + if (b > 255) return 0; + if (c > 255) return 0; + if (d > 255) return 0; + addr->s_addr = htonl((a<<24) | (b<<16) | (c<<8) | d); + return 1; +#ifdef AF_INET6 + } else if (af == AF_INET6) { + struct in6_addr *out = dst; + ev_uint16_t words[8]; + int gapPos = -1, i, setWords=0; + const char *dot = strchr(src, '.'); + const char *eow; /* end of words. */ + if (dot == src) + return 0; + else if (!dot) + eow = src+strlen(src); + else { + unsigned byte1,byte2,byte3,byte4; + char more; + for (eow = dot-1; eow >= src && EVUTIL_ISDIGIT_(*eow); --eow) + ; + ++eow; + + /* We use "scanf" because some platform inet_aton()s are too lax + * about IPv4 addresses of the form "1.2.3" */ + if (sscanf(eow, "%u.%u.%u.%u%c", + &byte1,&byte2,&byte3,&byte4,&more) != 4) + return 0; + + if (byte1 > 255 || + byte2 > 255 || + byte3 > 255 || + byte4 > 255) + return 0; + + words[6] = (byte1<<8) | byte2; + words[7] = (byte3<<8) | byte4; + setWords += 2; + } + + i = 0; + while (src < eow) { + if (i > 7) + return 0; + if (EVUTIL_ISXDIGIT_(*src)) { + char *next; + long r = strtol(src, &next, 16); + if (next > 4+src) + return 0; + if (next == src) + return 0; + if (r<0 || r>65536) + return 0; + + words[i++] = (ev_uint16_t)r; + setWords++; + src = next; + if (*src != ':' && src != eow) + return 0; + ++src; + } else if (*src == ':' && i > 0 && gapPos==-1) { + gapPos = i; + ++src; + } else if (*src == ':' && i == 0 && src[1] == ':' && gapPos==-1) { + gapPos = i; + src += 2; + } else { + return 0; + } + } + + if (setWords > 8 || + (setWords == 8 && gapPos != -1) || + (setWords < 8 && gapPos == -1)) + return 0; + + if (gapPos >= 0) { + int nToMove = setWords - (dot ? 2 : 0) - gapPos; + int gapLen = 8 - setWords; + /* assert(nToMove >= 0); */ + if (nToMove < 0) + return -1; /* should be impossible */ + memmove(&words[gapPos+gapLen], &words[gapPos], + sizeof(ev_uint16_t)*nToMove); + memset(&words[gapPos], 0, sizeof(ev_uint16_t)*gapLen); + } + for (i = 0; i < 8; ++i) { + out->s6_addr[2*i ] = words[i] >> 8; + out->s6_addr[2*i+1] = words[i] & 0xff; + } + + return 1; +#endif + } else { + return -1; + } +#endif +} + +int +evutil_parse_sockaddr_port(const char *ip_as_string, struct sockaddr *out, int *outlen) +{ + int port; + char buf[128]; + const char *cp, *addr_part, *port_part; + int is_ipv6; + /* recognized formats are: + * [ipv6]:port + * ipv6 + * [ipv6] + * ipv4:port + * ipv4 + */ + + cp = strchr(ip_as_string, ':'); + if (*ip_as_string == '[') { + int len; + if (!(cp = strchr(ip_as_string, ']'))) { + return -1; + } + len = (int) ( cp-(ip_as_string + 1) ); + if (len > (int)sizeof(buf)-1) { + return -1; + } + memcpy(buf, ip_as_string+1, len); + buf[len] = '\0'; + addr_part = buf; + if (cp[1] == ':') + port_part = cp+2; + else + port_part = NULL; + is_ipv6 = 1; + } else if (cp && strchr(cp+1, ':')) { + is_ipv6 = 1; + addr_part = ip_as_string; + port_part = NULL; + } else if (cp) { + is_ipv6 = 0; + if (cp - ip_as_string > (int)sizeof(buf)-1) { + return -1; + } + memcpy(buf, ip_as_string, cp-ip_as_string); + buf[cp-ip_as_string] = '\0'; + addr_part = buf; + port_part = cp+1; + } else { + addr_part = ip_as_string; + port_part = NULL; + is_ipv6 = 0; + } + + if (port_part == NULL) { + port = 0; + } else { + port = atoi(port_part); + if (port <= 0 || port > 65535) { + return -1; + } + } + + if (!addr_part) + return -1; /* Should be impossible. */ +#ifdef AF_INET6 + if (is_ipv6) + { + struct sockaddr_in6 sin6; + memset(&sin6, 0, sizeof(sin6)); +#ifdef EVENT__HAVE_STRUCT_SOCKADDR_IN6_SIN6_LEN + sin6.sin6_len = sizeof(sin6); +#endif + sin6.sin6_family = AF_INET6; + sin6.sin6_port = htons(port); + if (1 != evutil_inet_pton(AF_INET6, addr_part, &sin6.sin6_addr)) + return -1; + if ((int)sizeof(sin6) > *outlen) + return -1; + memset(out, 0, *outlen); + memcpy(out, &sin6, sizeof(sin6)); + *outlen = sizeof(sin6); + return 0; + } + else +#endif + { + struct sockaddr_in sin; + memset(&sin, 0, sizeof(sin)); +#ifdef EVENT__HAVE_STRUCT_SOCKADDR_IN_SIN_LEN + sin.sin_len = sizeof(sin); +#endif + sin.sin_family = AF_INET; + sin.sin_port = htons(port); + if (1 != evutil_inet_pton(AF_INET, addr_part, &sin.sin_addr)) + return -1; + if ((int)sizeof(sin) > *outlen) + return -1; + memset(out, 0, *outlen); + memcpy(out, &sin, sizeof(sin)); + *outlen = sizeof(sin); + return 0; + } +} + +const char * +evutil_format_sockaddr_port_(const struct sockaddr *sa, char *out, size_t outlen) +{ + char b[128]; + const char *res=NULL; + int port; + if (sa->sa_family == AF_INET) { + const struct sockaddr_in *sin = (const struct sockaddr_in*)sa; + res = evutil_inet_ntop(AF_INET, &sin->sin_addr,b,sizeof(b)); + port = ntohs(sin->sin_port); + if (res) { + evutil_snprintf(out, outlen, "%s:%d", b, port); + return out; + } + } else if (sa->sa_family == AF_INET6) { + const struct sockaddr_in6 *sin6 = (const struct sockaddr_in6*)sa; + res = evutil_inet_ntop(AF_INET6, &sin6->sin6_addr,b,sizeof(b)); + port = ntohs(sin6->sin6_port); + if (res) { + evutil_snprintf(out, outlen, "[%s]:%d", b, port); + return out; + } + } + + evutil_snprintf(out, outlen, "", + (int)sa->sa_family); + return out; +} + +int +evutil_sockaddr_cmp(const struct sockaddr *sa1, const struct sockaddr *sa2, + int include_port) +{ + int r; + if (0 != (r = (sa1->sa_family - sa2->sa_family))) + return r; + + if (sa1->sa_family == AF_INET) { + const struct sockaddr_in *sin1, *sin2; + sin1 = (const struct sockaddr_in *)sa1; + sin2 = (const struct sockaddr_in *)sa2; + if (sin1->sin_addr.s_addr < sin2->sin_addr.s_addr) + return -1; + else if (sin1->sin_addr.s_addr > sin2->sin_addr.s_addr) + return 1; + else if (include_port && + (r = ((int)sin1->sin_port - (int)sin2->sin_port))) + return r; + else + return 0; + } +#ifdef AF_INET6 + else if (sa1->sa_family == AF_INET6) { + const struct sockaddr_in6 *sin1, *sin2; + sin1 = (const struct sockaddr_in6 *)sa1; + sin2 = (const struct sockaddr_in6 *)sa2; + if ((r = memcmp(sin1->sin6_addr.s6_addr, sin2->sin6_addr.s6_addr, 16))) + return r; + else if (include_port && + (r = ((int)sin1->sin6_port - (int)sin2->sin6_port))) + return r; + else + return 0; + } +#endif + return 1; +} + +/* Tables to implement ctypes-replacement EVUTIL_IS*() functions. Each table + * has 256 bits to look up whether a character is in some set or not. This + * fails on non-ASCII platforms, but so does every other place where we + * take a char and write it onto the network. + **/ +static const ev_uint32_t EVUTIL_ISALPHA_TABLE[8] = + { 0, 0, 0x7fffffe, 0x7fffffe, 0, 0, 0, 0 }; +static const ev_uint32_t EVUTIL_ISALNUM_TABLE[8] = + { 0, 0x3ff0000, 0x7fffffe, 0x7fffffe, 0, 0, 0, 0 }; +static const ev_uint32_t EVUTIL_ISSPACE_TABLE[8] = { 0x3e00, 0x1, 0, 0, 0, 0, 0, 0 }; +static const ev_uint32_t EVUTIL_ISXDIGIT_TABLE[8] = + { 0, 0x3ff0000, 0x7e, 0x7e, 0, 0, 0, 0 }; +static const ev_uint32_t EVUTIL_ISDIGIT_TABLE[8] = { 0, 0x3ff0000, 0, 0, 0, 0, 0, 0 }; +static const ev_uint32_t EVUTIL_ISPRINT_TABLE[8] = + { 0, 0xffffffff, 0xffffffff, 0x7fffffff, 0, 0, 0, 0x0 }; +static const ev_uint32_t EVUTIL_ISUPPER_TABLE[8] = { 0, 0, 0x7fffffe, 0, 0, 0, 0, 0 }; +static const ev_uint32_t EVUTIL_ISLOWER_TABLE[8] = { 0, 0, 0, 0x7fffffe, 0, 0, 0, 0 }; +/* Upper-casing and lowercasing tables to map characters to upper/lowercase + * equivalents. */ +static const unsigned char EVUTIL_TOUPPER_TABLE[256] = { + 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15, + 16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31, + 32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47, + 48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63, + 64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79, + 80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95, + 96,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79, + 80,81,82,83,84,85,86,87,88,89,90,123,124,125,126,127, + 128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143, + 144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159, + 160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175, + 176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191, + 192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207, + 208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223, + 224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239, + 240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255, +}; +static const unsigned char EVUTIL_TOLOWER_TABLE[256] = { + 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15, + 16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31, + 32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47, + 48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63, + 64,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111, + 112,113,114,115,116,117,118,119,120,121,122,91,92,93,94,95, + 96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111, + 112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127, + 128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143, + 144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159, + 160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175, + 176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191, + 192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207, + 208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223, + 224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239, + 240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255, +}; + +#define IMPL_CTYPE_FN(name) \ + int EVUTIL_##name##_(char c) { \ + ev_uint8_t u = c; \ + return !!(EVUTIL_##name##_TABLE[(u >> 5) & 7] & (1 << (u & 31))); \ + } +IMPL_CTYPE_FN(ISALPHA) +IMPL_CTYPE_FN(ISALNUM) +IMPL_CTYPE_FN(ISSPACE) +IMPL_CTYPE_FN(ISDIGIT) +IMPL_CTYPE_FN(ISXDIGIT) +IMPL_CTYPE_FN(ISPRINT) +IMPL_CTYPE_FN(ISLOWER) +IMPL_CTYPE_FN(ISUPPER) + +char EVUTIL_TOLOWER_(char c) +{ + return ((char)EVUTIL_TOLOWER_TABLE[(ev_uint8_t)c]); +} +char EVUTIL_TOUPPER_(char c) +{ + return ((char)EVUTIL_TOUPPER_TABLE[(ev_uint8_t)c]); +} +int +evutil_ascii_strcasecmp(const char *s1, const char *s2) +{ + char c1, c2; + while (1) { + c1 = EVUTIL_TOLOWER_(*s1++); + c2 = EVUTIL_TOLOWER_(*s2++); + if (c1 < c2) + return -1; + else if (c1 > c2) + return 1; + else if (c1 == 0) + return 0; + } +} +int evutil_ascii_strncasecmp(const char *s1, const char *s2, size_t n) +{ + char c1, c2; + while (n--) { + c1 = EVUTIL_TOLOWER_(*s1++); + c2 = EVUTIL_TOLOWER_(*s2++); + if (c1 < c2) + return -1; + else if (c1 > c2) + return 1; + else if (c1 == 0) + return 0; + } + return 0; +} + +void +evutil_rtrim_lws_(char *str) +{ + char *cp; + + if (str == NULL) + return; + + if ((cp = strchr(str, '\0')) == NULL || (cp == str)) + return; + + --cp; + + while (*cp == ' ' || *cp == '\t') { + *cp = '\0'; + if (cp == str) + break; + --cp; + } +} + +static int +evutil_issetugid(void) +{ +#ifdef EVENT__HAVE_ISSETUGID + return issetugid(); +#else + +#ifdef EVENT__HAVE_GETEUID + if (getuid() != geteuid()) + return 1; +#endif +#ifdef EVENT__HAVE_GETEGID + if (getgid() != getegid()) + return 1; +#endif + return 0; +#endif +} + +const char * +evutil_getenv_(const char *varname) +{ + if (evutil_issetugid()) + return NULL; + + return getenv(varname); +} + +ev_uint32_t +evutil_weakrand_seed_(struct evutil_weakrand_state *state, ev_uint32_t seed) +{ + if (seed == 0) { + struct timeval tv; + evutil_gettimeofday(&tv, NULL); + seed = (ev_uint32_t)tv.tv_sec + (ev_uint32_t)tv.tv_usec; +#ifdef _WIN32 + seed += (ev_uint32_t) _getpid(); +#else + seed += (ev_uint32_t) getpid(); +#endif + } + state->seed = seed; + return seed; +} + +ev_int32_t +evutil_weakrand_(struct evutil_weakrand_state *state) +{ + /* This RNG implementation is a linear congruential generator, with + * modulus 2^31, multiplier 1103515245, and addend 12345. It's also + * used by OpenBSD, and by Glibc's TYPE_0 RNG. + * + * The linear congruential generator is not an industrial-strength + * RNG! It's fast, but it can have higher-order patterns. Notably, + * the low bits tend to have periodicity. + */ + state->seed = ((state->seed) * 1103515245 + 12345) & 0x7fffffff; + return (ev_int32_t)(state->seed); +} + +ev_int32_t +evutil_weakrand_range_(struct evutil_weakrand_state *state, ev_int32_t top) +{ + ev_int32_t divisor, result; + + /* We can't just do weakrand() % top, since the low bits of the LCG + * are less random than the high ones. (Specifically, since the LCG + * modulus is 2^N, every 2^m for m= top); + return result; +} + +/** + * Volatile pointer to memset: we use this to keep the compiler from + * eliminating our call to memset. + */ +void * (*volatile evutil_memset_volatile_)(void *, int, size_t) = memset; + +void +evutil_memclear_(void *mem, size_t len) +{ + evutil_memset_volatile_(mem, 0, len); +} + +int +evutil_sockaddr_is_loopback_(const struct sockaddr *addr) +{ + static const char LOOPBACK_S6[16] = + "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\1"; + if (addr->sa_family == AF_INET) { + struct sockaddr_in *sin = (struct sockaddr_in *)addr; + return (ntohl(sin->sin_addr.s_addr) & 0xff000000) == 0x7f000000; + } else if (addr->sa_family == AF_INET6) { + struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)addr; + return !memcmp(sin6->sin6_addr.s6_addr, LOOPBACK_S6, 16); + } + return 0; +} + +int +evutil_hex_char_to_int_(char c) +{ + switch(c) + { + case '0': return 0; + case '1': return 1; + case '2': return 2; + case '3': return 3; + case '4': return 4; + case '5': return 5; + case '6': return 6; + case '7': return 7; + case '8': return 8; + case '9': return 9; + case 'A': case 'a': return 10; + case 'B': case 'b': return 11; + case 'C': case 'c': return 12; + case 'D': case 'd': return 13; + case 'E': case 'e': return 14; + case 'F': case 'f': return 15; + } + return -1; +} + +#ifdef _WIN32 +HMODULE +evutil_load_windows_system_library_(const TCHAR *library_name) +{ + TCHAR path[MAX_PATH]; + unsigned n; + n = GetSystemDirectory(path, MAX_PATH); + if (n == 0 || n + _tcslen(library_name) + 2 >= MAX_PATH) + return 0; + _tcscat(path, TEXT("\\")); + _tcscat(path, library_name); + return LoadLibrary(path); +} +#endif + +/* Internal wrapper around 'socket' to provide Linux-style support for + * syscall-saving methods where available. + * + * In addition to regular socket behavior, you can use a bitwise or to set the + * flags EVUTIL_SOCK_NONBLOCK and EVUTIL_SOCK_CLOEXEC in the 'type' argument, + * to make the socket nonblocking or close-on-exec with as few syscalls as + * possible. + */ +evutil_socket_t +evutil_socket_(int domain, int type, int protocol) +{ + evutil_socket_t r; +#if defined(SOCK_NONBLOCK) && defined(SOCK_CLOEXEC) + r = socket(domain, type, protocol); + if (r >= 0) + return r; + else if ((type & (SOCK_NONBLOCK|SOCK_CLOEXEC)) == 0) + return -1; +#endif +#define SOCKET_TYPE_MASK (~(EVUTIL_SOCK_NONBLOCK|EVUTIL_SOCK_CLOEXEC)) + r = socket(domain, type & SOCKET_TYPE_MASK, protocol); + if (r < 0) + return -1; + if (type & EVUTIL_SOCK_NONBLOCK) { + if (evutil_fast_socket_nonblocking(r) < 0) { + evutil_closesocket(r); + return -1; + } + } + if (type & EVUTIL_SOCK_CLOEXEC) { + if (evutil_fast_socket_closeonexec(r) < 0) { + evutil_closesocket(r); + return -1; + } + } + return r; +} + +/* Internal wrapper around 'accept' or 'accept4' to provide Linux-style + * support for syscall-saving methods where available. + * + * In addition to regular accept behavior, you can set one or more of flags + * EVUTIL_SOCK_NONBLOCK and EVUTIL_SOCK_CLOEXEC in the 'flags' argument, to + * make the socket nonblocking or close-on-exec with as few syscalls as + * possible. + */ +evutil_socket_t +evutil_accept4_(evutil_socket_t sockfd, struct sockaddr *addr, + ev_socklen_t *addrlen, int flags) +{ + evutil_socket_t result; +#if defined(EVENT__HAVE_ACCEPT4) && defined(SOCK_CLOEXEC) && defined(SOCK_NONBLOCK) + result = accept4(sockfd, addr, addrlen, flags); + if (result >= 0 || (errno != EINVAL && errno != ENOSYS)) { + /* A nonnegative result means that we succeeded, so return. + * Failing with EINVAL means that an option wasn't supported, + * and failing with ENOSYS means that the syscall wasn't + * there: in those cases we want to fall back. Otherwise, we + * got a real error, and we should return. */ + return result; + } +#endif + result = accept(sockfd, addr, addrlen); + if (result < 0) + return result; + + if (flags & EVUTIL_SOCK_CLOEXEC) { + if (evutil_fast_socket_closeonexec(result) < 0) { + evutil_closesocket(result); + return -1; + } + } + if (flags & EVUTIL_SOCK_NONBLOCK) { + if (evutil_fast_socket_nonblocking(result) < 0) { + evutil_closesocket(result); + return -1; + } + } + return result; +} + +/* Internal function: Set fd[0] and fd[1] to a pair of fds such that writes on + * fd[0] get read from fd[1]. Make both fds nonblocking and close-on-exec. + * Return 0 on success, -1 on failure. + */ +int +evutil_make_internal_pipe_(evutil_socket_t fd[2]) +{ + /* + Making the second socket nonblocking is a bit subtle, given that we + ignore any EAGAIN returns when writing to it, and you don't usally + do that for a nonblocking socket. But if the kernel gives us EAGAIN, + then there's no need to add any more data to the buffer, since + the main thread is already either about to wake up and drain it, + or woken up and in the process of draining it. + */ + +#if defined(EVENT__HAVE_PIPE2) + if (pipe2(fd, O_NONBLOCK|O_CLOEXEC) == 0) + return 0; +#endif +#if defined(EVENT__HAVE_PIPE) + if (pipe(fd) == 0) { + if (evutil_fast_socket_nonblocking(fd[0]) < 0 || + evutil_fast_socket_nonblocking(fd[1]) < 0 || + evutil_fast_socket_closeonexec(fd[0]) < 0 || + evutil_fast_socket_closeonexec(fd[1]) < 0) { + close(fd[0]); + close(fd[1]); + fd[0] = fd[1] = -1; + return -1; + } + return 0; + } else { + event_warn("%s: pipe", __func__); + } +#endif + +#ifdef _WIN32 +#define LOCAL_SOCKETPAIR_AF AF_INET +#else +#define LOCAL_SOCKETPAIR_AF AF_UNIX +#endif + if (evutil_socketpair(LOCAL_SOCKETPAIR_AF, SOCK_STREAM, 0, fd) == 0) { + if (evutil_fast_socket_nonblocking(fd[0]) < 0 || + evutil_fast_socket_nonblocking(fd[1]) < 0 || + evutil_fast_socket_closeonexec(fd[0]) < 0 || + evutil_fast_socket_closeonexec(fd[1]) < 0) { + evutil_closesocket(fd[0]); + evutil_closesocket(fd[1]); + fd[0] = fd[1] = -1; + return -1; + } + return 0; + } + fd[0] = fd[1] = -1; + return -1; +} + +/* Wrapper around eventfd on systems that provide it. Unlike the system + * eventfd, it always supports EVUTIL_EFD_CLOEXEC and EVUTIL_EFD_NONBLOCK as + * flags. Returns -1 on error or if eventfd is not supported. + */ +evutil_socket_t +evutil_eventfd_(unsigned initval, int flags) +{ +#if defined(EVENT__HAVE_EVENTFD) && defined(EVENT__HAVE_SYS_EVENTFD_H) + int r; +#if defined(EFD_CLOEXEC) && defined(EFD_NONBLOCK) + r = eventfd(initval, flags); + if (r >= 0 || flags == 0) + return r; +#endif + r = eventfd(initval, 0); + if (r < 0) + return r; + if (flags & EVUTIL_EFD_CLOEXEC) { + if (evutil_fast_socket_closeonexec(r) < 0) { + evutil_closesocket(r); + return -1; + } + } + if (flags & EVUTIL_EFD_NONBLOCK) { + if (evutil_fast_socket_nonblocking(r) < 0) { + evutil_closesocket(r); + return -1; + } + } + return r; +#else + return -1; +#endif +} + +void +evutil_free_globals_(void) +{ + evutil_free_secure_rng_globals_(); + evutil_free_sock_err_globals(); +} diff --git a/contrib/ntp/sntp/libevent/evutil_rand.c b/contrib/ntp/sntp/libevent/evutil_rand.c new file mode 100644 index 000000000..046a14b07 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evutil_rand.c @@ -0,0 +1,206 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* This file has our secure PRNG code. On platforms that have arc4random(), + * we just use that. Otherwise, we include arc4random.c as a bunch of static + * functions, and wrap it lightly. We don't expose the arc4random*() APIs + * because A) they aren't in our namespace, and B) it's not nice to name your + * APIs after their implementations. We keep them in a separate file + * so that other people can rip it out and use it for whatever. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#include "util-internal.h" +#include "evthread-internal.h" + +#ifdef EVENT__HAVE_ARC4RANDOM +#include +#include +int +evutil_secure_rng_set_urandom_device_file(char *fname) +{ + (void) fname; + return -1; +} +int +evutil_secure_rng_init(void) +{ + /* call arc4random() now to force it to self-initialize */ + (void) arc4random(); + return 0; +} +#ifndef EVENT__DISABLE_THREAD_SUPPORT +int +evutil_secure_rng_global_setup_locks_(const int enable_locks) +{ + return 0; +} +#endif +static void +evutil_free_secure_rng_globals_locks(void) +{ +} + +static void +ev_arc4random_buf(void *buf, size_t n) +{ +#if defined(EVENT__HAVE_ARC4RANDOM_BUF) && !defined(__APPLE__) + arc4random_buf(buf, n); + return; +#else + unsigned char *b = buf; + +#if defined(EVENT__HAVE_ARC4RANDOM_BUF) + /* OSX 10.7 introducd arc4random_buf, so if you build your program + * there, you'll get surprised when older versions of OSX fail to run. + * To solve this, we can check whether the function pointer is set, + * and fall back otherwise. (OSX does this using some linker + * trickery.) + */ + { + void (*tptr)(void *,size_t) = + (void (*)(void*,size_t))arc4random_buf; + if (tptr != NULL) { + arc4random_buf(buf, n); + return; + } + } +#endif + /* Make sure that we start out with b at a 4-byte alignment; plenty + * of CPUs care about this for 32-bit access. */ + if (n >= 4 && ((ev_uintptr_t)b) & 3) { + ev_uint32_t u = arc4random(); + int n_bytes = 4 - (((ev_uintptr_t)b) & 3); + memcpy(b, &u, n_bytes); + b += n_bytes; + n -= n_bytes; + } + while (n >= 4) { + *(ev_uint32_t*)b = arc4random(); + b += 4; + n -= 4; + } + if (n) { + ev_uint32_t u = arc4random(); + memcpy(b, &u, n); + } +#endif +} + +#else /* !EVENT__HAVE_ARC4RANDOM { */ + +#ifdef EVENT__ssize_t +#define ssize_t EVENT__ssize_t +#endif +#define ARC4RANDOM_EXPORT static +#define ARC4_LOCK_() EVLOCK_LOCK(arc4rand_lock, 0) +#define ARC4_UNLOCK_() EVLOCK_UNLOCK(arc4rand_lock, 0) +#ifndef EVENT__DISABLE_THREAD_SUPPORT +static void *arc4rand_lock; +#endif + +#define ARC4RANDOM_UINT32 ev_uint32_t +#define ARC4RANDOM_NOSTIR +#define ARC4RANDOM_NORANDOM +#define ARC4RANDOM_NOUNIFORM + +#include "./arc4random.c" + +#ifndef EVENT__DISABLE_THREAD_SUPPORT +int +evutil_secure_rng_global_setup_locks_(const int enable_locks) +{ + EVTHREAD_SETUP_GLOBAL_LOCK(arc4rand_lock, 0); + return 0; +} +#endif + +static void +evutil_free_secure_rng_globals_locks(void) +{ +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (arc4rand_lock != NULL) { + EVTHREAD_FREE_LOCK(arc4rand_lock, 0); + arc4rand_lock = NULL; + } +#endif + return; +} + +int +evutil_secure_rng_set_urandom_device_file(char *fname) +{ +#ifdef TRY_SEED_URANDOM + ARC4_LOCK_(); + arc4random_urandom_filename = fname; + ARC4_UNLOCK_(); +#endif + return 0; +} + +int +evutil_secure_rng_init(void) +{ + int val; + + ARC4_LOCK_(); + if (!arc4_seeded_ok) + arc4_stir(); + val = arc4_seeded_ok ? 0 : -1; + ARC4_UNLOCK_(); + return val; +} + +static void +ev_arc4random_buf(void *buf, size_t n) +{ + arc4random_buf(buf, n); +} + +#endif /* } !EVENT__HAVE_ARC4RANDOM */ + +void +evutil_secure_rng_get_bytes(void *buf, size_t n) +{ + ev_arc4random_buf(buf, n); +} + +void +evutil_secure_rng_add_bytes(const char *buf, size_t n) +{ + arc4random_addrandom((unsigned char*)buf, + n>(size_t)INT_MAX ? INT_MAX : (int)n); +} + +void +evutil_free_secure_rng_globals_(void) +{ + evutil_free_secure_rng_globals_locks(); +} diff --git a/contrib/ntp/sntp/libevent/evutil_time.c b/contrib/ntp/sntp/libevent/evutil_time.c new file mode 100644 index 000000000..8f53c66b6 --- /dev/null +++ b/contrib/ntp/sntp/libevent/evutil_time.c @@ -0,0 +1,538 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#include +#define WIN32_LEAN_AND_MEAN +#include +#undef WIN32_LEAN_AND_MEAN +#endif + +#include +#ifdef EVENT__HAVE_STDLIB_H +#include +#endif +#include +#include +#ifndef EVENT__HAVE_GETTIMEOFDAY +#include +#endif +#if !defined(EVENT__HAVE_NANOSLEEP) && !defined(EVENT_HAVE_USLEEP) && \ + !defined(_WIN32) +#include +#endif +#include +#include +#include + +#include "event2/util.h" +#include "util-internal.h" +#include "log-internal.h" +#include "mm-internal.h" + +#ifndef EVENT__HAVE_GETTIMEOFDAY +/* No gettimeofday; this must be windows. */ +int +evutil_gettimeofday(struct timeval *tv, struct timezone *tz) +{ +#ifdef _MSC_VER +#define U64_LITERAL(n) n##ui64 +#else +#define U64_LITERAL(n) n##llu +#endif + + /* Conversion logic taken from Tor, which in turn took it + * from Perl. GetSystemTimeAsFileTime returns its value as + * an unaligned (!) 64-bit value containing the number of + * 100-nanosecond intervals since 1 January 1601 UTC. */ +#define EPOCH_BIAS U64_LITERAL(116444736000000000) +#define UNITS_PER_SEC U64_LITERAL(10000000) +#define USEC_PER_SEC U64_LITERAL(1000000) +#define UNITS_PER_USEC U64_LITERAL(10) + union { + FILETIME ft_ft; + ev_uint64_t ft_64; + } ft; + + if (tv == NULL) + return -1; + + GetSystemTimeAsFileTime(&ft.ft_ft); + + if (EVUTIL_UNLIKELY(ft.ft_64 < EPOCH_BIAS)) { + /* Time before the unix epoch. */ + return -1; + } + ft.ft_64 -= EPOCH_BIAS; + tv->tv_sec = (long) (ft.ft_64 / UNITS_PER_SEC); + tv->tv_usec = (long) ((ft.ft_64 / UNITS_PER_USEC) % USEC_PER_SEC); + return 0; +} +#endif + +#define MAX_SECONDS_IN_MSEC_LONG \ + (((LONG_MAX) - 999) / 1000) + +long +evutil_tv_to_msec_(const struct timeval *tv) +{ + if (tv->tv_usec > 1000000 || tv->tv_sec > MAX_SECONDS_IN_MSEC_LONG) + return -1; + + return (tv->tv_sec * 1000) + ((tv->tv_usec + 999) / 1000); +} + +/* + Replacement for usleep on platforms that don't have one. Not guaranteed to + be any more finegrained than 1 msec. + */ +void +evutil_usleep_(const struct timeval *tv) +{ + if (!tv) + return; +#if defined(_WIN32) + { + long msec = evutil_tv_to_msec_(tv); + Sleep((DWORD)msec); + } +#elif defined(EVENT__HAVE_NANOSLEEP) + { + struct timespec ts; + ts.tv_sec = tv->tv_sec; + ts.tv_nsec = tv->tv_usec*1000; + nanosleep(&ts, NULL); + } +#elif defined(EVENT__HAVE_USLEEP) + /* Some systems don't like to usleep more than 999999 usec */ + sleep(tv->tv_sec); + usleep(tv->tv_usec); +#else + select(0, NULL, NULL, NULL, tv); +#endif +} + +/* + This function assumes it's called repeatedly with a + not-actually-so-monotonic time source whose outputs are in 'tv'. It + implements a trivial ratcheting mechanism so that the values never go + backwards. + */ +static void +adjust_monotonic_time(struct evutil_monotonic_timer *base, + struct timeval *tv) +{ + evutil_timeradd(tv, &base->adjust_monotonic_clock, tv); + + if (evutil_timercmp(tv, &base->last_time, <)) { + /* Guess it wasn't monotonic after all. */ + struct timeval adjust; + evutil_timersub(&base->last_time, tv, &adjust); + evutil_timeradd(&adjust, &base->adjust_monotonic_clock, + &base->adjust_monotonic_clock); + *tv = base->last_time; + } + base->last_time = *tv; +} + +/* + Allocate a new struct evutil_monotonic_timer + */ +struct evutil_monotonic_timer * +evutil_monotonic_timer_new(void) +{ + struct evutil_monotonic_timer *p = NULL; + + p = mm_malloc(sizeof(*p)); + if (!p) goto done; + + memset(p, 0, sizeof(*p)); + + done: + return p; +} + +/* + Free a struct evutil_monotonic_timer + */ +void +evutil_monotonic_timer_free(struct evutil_monotonic_timer *timer) +{ + if (timer) { + mm_free(timer); + } +} + +/* + Set up a struct evutil_monotonic_timer for initial use + */ +int +evutil_configure_monotonic_time(struct evutil_monotonic_timer *timer, + int flags) +{ + return evutil_configure_monotonic_time_(timer, flags); +} + +/* + Query the current monotonic time + */ +int +evutil_gettime_monotonic(struct evutil_monotonic_timer *timer, + struct timeval *tp) +{ + return evutil_gettime_monotonic_(timer, tp); +} + + +#if defined(HAVE_POSIX_MONOTONIC) +/* ===== + The POSIX clock_gettime() interface provides a few ways to get at a + monotonic clock. CLOCK_MONOTONIC is most widely supported. Linux also + provides a CLOCK_MONOTONIC_COARSE with accuracy of about 1-4 msec. + + On all platforms I'm aware of, CLOCK_MONOTONIC really is monotonic. + Platforms don't agree about whether it should jump on a sleep/resume. + */ + +int +evutil_configure_monotonic_time_(struct evutil_monotonic_timer *base, + int flags) +{ + /* CLOCK_MONOTONIC exists on FreeBSD, Linux, and Solaris. You need to + * check for it at runtime, because some older kernel versions won't + * have it working. */ +#ifdef CLOCK_MONOTONIC_COARSE + const int precise = flags & EV_MONOT_PRECISE; +#endif + const int fallback = flags & EV_MONOT_FALLBACK; + struct timespec ts; + +#ifdef CLOCK_MONOTONIC_COARSE + if (CLOCK_MONOTONIC_COARSE < 0) { + /* Technically speaking, nothing keeps CLOCK_* from being + * negative (as far as I know). This check and the one below + * make sure that it's safe for us to use -1 as an "unset" + * value. */ + event_errx(1,"I didn't expect CLOCK_MONOTONIC_COARSE to be < 0"); + } + if (! precise && ! fallback) { + if (clock_gettime(CLOCK_MONOTONIC_COARSE, &ts) == 0) { + base->monotonic_clock = CLOCK_MONOTONIC_COARSE; + return 0; + } + } +#endif + if (!fallback && clock_gettime(CLOCK_MONOTONIC, &ts) == 0) { + base->monotonic_clock = CLOCK_MONOTONIC; + return 0; + } + + if (CLOCK_MONOTONIC < 0) { + event_errx(1,"I didn't expect CLOCK_MONOTONIC to be < 0"); + } + + base->monotonic_clock = -1; + return 0; +} + +int +evutil_gettime_monotonic_(struct evutil_monotonic_timer *base, + struct timeval *tp) +{ + struct timespec ts; + + if (base->monotonic_clock < 0) { + if (evutil_gettimeofday(tp, NULL) < 0) + return -1; + adjust_monotonic_time(base, tp); + return 0; + } + + if (clock_gettime(base->monotonic_clock, &ts) == -1) + return -1; + tp->tv_sec = ts.tv_sec; + tp->tv_usec = ts.tv_nsec / 1000; + + return 0; +} +#endif + +#if defined(HAVE_MACH_MONOTONIC) +/* ====== + Apple is a little late to the POSIX party. And why not? Instead of + clock_gettime(), they provide mach_absolute_time(). Its units are not + fixed; we need to use mach_timebase_info() to get the right functions to + convert its units into nanoseconds. + + To all appearances, mach_absolute_time() seems to be honest-to-goodness + monotonic. Whether it stops during sleep or not is unspecified in + principle, and dependent on CPU architecture in practice. + */ + +int +evutil_configure_monotonic_time_(struct evutil_monotonic_timer *base, + int flags) +{ + const int fallback = flags & EV_MONOT_FALLBACK; + struct mach_timebase_info mi; + memset(base, 0, sizeof(*base)); + /* OSX has mach_absolute_time() */ + if (!fallback && + mach_timebase_info(&mi) == 0 && + mach_absolute_time() != 0) { + /* mach_timebase_info tells us how to convert + * mach_absolute_time() into nanoseconds, but we + * want to use microseconds instead. */ + mi.denom *= 1000; + memcpy(&base->mach_timebase_units, &mi, sizeof(mi)); + } else { + base->mach_timebase_units.numer = 0; + } + return 0; +} + +int +evutil_gettime_monotonic_(struct evutil_monotonic_timer *base, + struct timeval *tp) +{ + ev_uint64_t abstime, usec; + if (base->mach_timebase_units.numer == 0) { + if (evutil_gettimeofday(tp, NULL) < 0) + return -1; + adjust_monotonic_time(base, tp); + return 0; + } + + abstime = mach_absolute_time(); + usec = (abstime * base->mach_timebase_units.numer) + / (base->mach_timebase_units.denom); + tp->tv_sec = usec / 1000000; + tp->tv_usec = usec % 1000000; + + return 0; +} +#endif + +#if defined(HAVE_WIN32_MONOTONIC) +/* ===== + Turn we now to Windows. Want monontonic time on Windows? + + Windows has QueryPerformanceCounter(), which gives time most high- + resolution time. It's a pity it's not so monotonic in practice; it's + also got some fun bugs, especially: with older Windowses, under + virtualizations, with funny hardware, on multiprocessor systems, and so + on. PEP418 [1] has a nice roundup of the issues here. + + There's GetTickCount64() on Vista and later, which gives a number of 1-msec + ticks since startup. The accuracy here might be as bad as 10-20 msec, I + hear. There's an undocumented function (NtSetTimerResolution) that + allegedly increases the accuracy. Good luck! + + There's also GetTickCount(), which is only 32 bits, but seems to be + supported on pre-Vista versions of Windows. Apparently, you can coax + another 14 bits out of it, giving you 2231 years before rollover. + + The less said about timeGetTime() the better. + + "We don't care. We don't have to. We're the Phone Company." + -- Lily Tomlin, SNL + + Our strategy, if precise timers are turned off, is to just use the best + GetTickCount equivalent available. If we've been asked for precise timing, + then we mostly[2] assume that GetTickCount is monotonic, and correct + GetPerformanceCounter to approximate it. + + [1] http://www.python.org/dev/peps/pep-0418 + [2] Of course, we feed the Windows stuff into adjust_monotonic_time() + anyway, just in case it isn't. + + */ +/* + Parts of our logic in the win32 timer code here are closely based on + BitTorrent's libUTP library. That code is subject to the following + license: + + Copyright (c) 2010 BitTorrent, Inc. + + Permission is hereby granted, free of charge, to any person obtaining a + copy of this software and associated documentation files (the + "Software"), to deal in the Software without restriction, including + without limitation the rights to use, copy, modify, merge, publish, + distribute, sublicense, and/or sell copies of the Software, and to + permit persons to whom the Software is furnished to do so, subject to + the following conditions: + + The above copyright notice and this permission notice shall be included + in all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE + LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION + OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION + WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +*/ + +static ev_uint64_t +evutil_GetTickCount_(struct evutil_monotonic_timer *base) +{ + if (base->GetTickCount64_fn) { + /* Let's just use GetTickCount64 if we can. */ + return base->GetTickCount64_fn(); + } else if (base->GetTickCount_fn) { + /* Greg Hazel assures me that this works, that BitTorrent has + * done it for years, and this it won't turn around and + * bite us. He says they found it on some game programmers' + * forum some time around 2007. + */ + ev_uint64_t v = base->GetTickCount_fn(); + return (DWORD)v | ((v >> 18) & 0xFFFFFFFF00000000); + } else { + /* Here's the fallback implementation. We have to use + * GetTickCount() with its given signature, so we only get + * 32 bits worth of milliseconds, which will roll ove every + * 49 days or so. */ + DWORD ticks = GetTickCount(); + if (ticks < base->last_tick_count) { + base->adjust_tick_count += ((ev_uint64_t)1) << 32; + } + base->last_tick_count = ticks; + return ticks + base->adjust_tick_count; + } +} + +int +evutil_configure_monotonic_time_(struct evutil_monotonic_timer *base, + int flags) +{ + const int precise = flags & EV_MONOT_PRECISE; + const int fallback = flags & EV_MONOT_FALLBACK; + HANDLE h; + memset(base, 0, sizeof(*base)); + + h = evutil_load_windows_system_library_(TEXT("kernel32.dll")); + if (h != NULL && !fallback) { + base->GetTickCount64_fn = (ev_GetTickCount_func)GetProcAddress(h, "GetTickCount64"); + base->GetTickCount_fn = (ev_GetTickCount_func)GetProcAddress(h, "GetTickCount"); + } + + base->first_tick = base->last_tick_count = evutil_GetTickCount_(base); + if (precise && !fallback) { + LARGE_INTEGER freq; + if (QueryPerformanceFrequency(&freq)) { + LARGE_INTEGER counter; + QueryPerformanceCounter(&counter); + base->first_counter = counter.QuadPart; + base->usec_per_count = 1.0e6 / freq.QuadPart; + base->use_performance_counter = 1; + } + } + + return 0; +} + +static inline ev_int64_t +abs64(ev_int64_t i) +{ + return i < 0 ? -i : i; +} + + +int +evutil_gettime_monotonic_(struct evutil_monotonic_timer *base, + struct timeval *tp) +{ + ev_uint64_t ticks = evutil_GetTickCount_(base); + if (base->use_performance_counter) { + /* Here's a trick we took from BitTorrent's libutp, at Greg + * Hazel's recommendation. We use QueryPerformanceCounter for + * our high-resolution timer, but use GetTickCount*() to keep + * it sane, and adjust_monotonic_time() to keep it monotonic. + */ + LARGE_INTEGER counter; + ev_int64_t counter_elapsed, counter_usec_elapsed, ticks_elapsed; + QueryPerformanceCounter(&counter); + counter_elapsed = (ev_int64_t) + (counter.QuadPart - base->first_counter); + ticks_elapsed = ticks - base->first_tick; + /* TODO: This may upset VC6. If you need this to work with + * VC6, please supply an appropriate patch. */ + counter_usec_elapsed = (ev_int64_t) + (counter_elapsed * base->usec_per_count); + + if (abs64(ticks_elapsed*1000 - counter_usec_elapsed) > 1000000) { + /* It appears that the QueryPerformanceCounter() + * result is more than 1 second away from + * GetTickCount() result. Let's adjust it to be as + * accurate as we can; adjust_monotnonic_time() below + * will keep it monotonic. */ + counter_usec_elapsed = ticks_elapsed * 1000; + base->first_counter = (ev_uint64_t) (counter.QuadPart - counter_usec_elapsed / base->usec_per_count); + } + tp->tv_sec = (time_t) (counter_usec_elapsed / 1000000); + tp->tv_usec = counter_usec_elapsed % 1000000; + + } else { + /* We're just using GetTickCount(). */ + tp->tv_sec = (time_t) (ticks / 1000); + tp->tv_usec = (ticks % 1000) * 1000; + } + adjust_monotonic_time(base, tp); + + return 0; +} +#endif + +#if defined(HAVE_FALLBACK_MONOTONIC) +/* ===== + And if none of the other options work, let's just use gettimeofday(), and + ratchet it forward so that it acts like a monotonic timer, whether it + wants to or not. + */ + +int +evutil_configure_monotonic_time_(struct evutil_monotonic_timer *base, + int precise) +{ + memset(base, 0, sizeof(*base)); + return 0; +} + +int +evutil_gettime_monotonic_(struct evutil_monotonic_timer *base, + struct timeval *tp) +{ + if (evutil_gettimeofday(tp, NULL) < 0) + return -1; + adjust_monotonic_time(base, tp); + return 0; + +} +#endif diff --git a/contrib/ntp/sntp/libevent/ht-internal.h b/contrib/ntp/sntp/libevent/ht-internal.h new file mode 100644 index 000000000..50375bbaa --- /dev/null +++ b/contrib/ntp/sntp/libevent/ht-internal.h @@ -0,0 +1,487 @@ +/* Copyright 2002 Christopher Clark */ +/* Copyright 2005-2012 Nick Mathewson */ +/* Copyright 2009-2012 Niels Provos and Nick Mathewson */ +/* See license at end. */ + +/* Based on ideas by Christopher Clark and interfaces from Niels Provos. */ + +#ifndef HT_INTERNAL_H_INCLUDED_ +#define HT_INTERNAL_H_INCLUDED_ + +#define HT_HEAD(name, type) \ + struct name { \ + /* The hash table itself. */ \ + struct type **hth_table; \ + /* How long is the hash table? */ \ + unsigned hth_table_length; \ + /* How many elements does the table contain? */ \ + unsigned hth_n_entries; \ + /* How many elements will we allow in the table before resizing it? */ \ + unsigned hth_load_limit; \ + /* Position of hth_table_length in the primes table. */ \ + int hth_prime_idx; \ + } + +#define HT_INITIALIZER() \ + { NULL, 0, 0, 0, -1 } + +#ifdef HT_NO_CACHE_HASH_VALUES +#define HT_ENTRY(type) \ + struct { \ + struct type *hte_next; \ + } +#else +#define HT_ENTRY(type) \ + struct { \ + struct type *hte_next; \ + unsigned hte_hash; \ + } +#endif + +#define HT_EMPTY(head) \ + ((head)->hth_n_entries == 0) + +/* How many elements in 'head'? */ +#define HT_SIZE(head) \ + ((head)->hth_n_entries) + +/* Return memory usage for a hashtable (not counting the entries themselves) */ +#define HT_MEM_USAGE(head) \ + (sizeof(*head) + (head)->hth_table_length * sizeof(void*)) + +#define HT_FIND(name, head, elm) name##_HT_FIND((head), (elm)) +#define HT_INSERT(name, head, elm) name##_HT_INSERT((head), (elm)) +#define HT_REPLACE(name, head, elm) name##_HT_REPLACE((head), (elm)) +#define HT_REMOVE(name, head, elm) name##_HT_REMOVE((head), (elm)) +#define HT_START(name, head) name##_HT_START(head) +#define HT_NEXT(name, head, elm) name##_HT_NEXT((head), (elm)) +#define HT_NEXT_RMV(name, head, elm) name##_HT_NEXT_RMV((head), (elm)) +#define HT_CLEAR(name, head) name##_HT_CLEAR(head) +#define HT_INIT(name, head) name##_HT_INIT(head) +/* Helper: */ +static inline unsigned +ht_improve_hash_(unsigned h) +{ + /* Aim to protect against poor hash functions by adding logic here + * - logic taken from java 1.4 hashtable source */ + h += ~(h << 9); + h ^= ((h >> 14) | (h << 18)); /* >>> */ + h += (h << 4); + h ^= ((h >> 10) | (h << 22)); /* >>> */ + return h; +} + +#if 0 +/** Basic string hash function, from Java standard String.hashCode(). */ +static inline unsigned +ht_string_hash_(const char *s) +{ + unsigned h = 0; + int m = 1; + while (*s) { + h += ((signed char)*s++)*m; + m = (m<<5)-1; /* m *= 31 */ + } + return h; +} +#endif + +/** Basic string hash function, from Python's str.__hash__() */ +static inline unsigned +ht_string_hash_(const char *s) +{ + unsigned h; + const unsigned char *cp = (const unsigned char *)s; + h = *cp << 7; + while (*cp) { + h = (1000003*h) ^ *cp++; + } + /* This conversion truncates the length of the string, but that's ok. */ + h ^= (unsigned)(cp-(const unsigned char*)s); + return h; +} + +#ifndef HT_NO_CACHE_HASH_VALUES +#define HT_SET_HASH_(elm, field, hashfn) \ + do { (elm)->field.hte_hash = hashfn(elm); } while (0) +#define HT_SET_HASHVAL_(elm, field, val) \ + do { (elm)->field.hte_hash = (val); } while (0) +#define HT_ELT_HASH_(elm, field, hashfn) \ + ((elm)->field.hte_hash) +#else +#define HT_SET_HASH_(elm, field, hashfn) \ + ((void)0) +#define HT_ELT_HASH_(elm, field, hashfn) \ + (hashfn(elm)) +#define HT_SET_HASHVAL_(elm, field, val) \ + ((void)0) +#endif + +/* Helper: alias for the bucket containing 'elm'. */ +#define HT_BUCKET_(head, field, elm, hashfn) \ + ((head)->hth_table[HT_ELT_HASH_(elm,field,hashfn) % head->hth_table_length]) + +#define HT_FOREACH(x, name, head) \ + for ((x) = HT_START(name, head); \ + (x) != NULL; \ + (x) = HT_NEXT(name, head, x)) + +#define HT_PROTOTYPE(name, type, field, hashfn, eqfn) \ + int name##_HT_GROW(struct name *ht, unsigned min_capacity); \ + void name##_HT_CLEAR(struct name *ht); \ + int name##_HT_REP_IS_BAD_(const struct name *ht); \ + static inline void \ + name##_HT_INIT(struct name *head) { \ + head->hth_table_length = 0; \ + head->hth_table = NULL; \ + head->hth_n_entries = 0; \ + head->hth_load_limit = 0; \ + head->hth_prime_idx = -1; \ + } \ + /* Helper: returns a pointer to the right location in the table \ + * 'head' to find or insert the element 'elm'. */ \ + static inline struct type ** \ + name##_HT_FIND_P_(struct name *head, struct type *elm) \ + { \ + struct type **p; \ + if (!head->hth_table) \ + return NULL; \ + p = &HT_BUCKET_(head, field, elm, hashfn); \ + while (*p) { \ + if (eqfn(*p, elm)) \ + return p; \ + p = &(*p)->field.hte_next; \ + } \ + return p; \ + } \ + /* Return a pointer to the element in the table 'head' matching 'elm', \ + * or NULL if no such element exists */ \ + static inline struct type * \ + name##_HT_FIND(const struct name *head, struct type *elm) \ + { \ + struct type **p; \ + struct name *h = (struct name *) head; \ + HT_SET_HASH_(elm, field, hashfn); \ + p = name##_HT_FIND_P_(h, elm); \ + return p ? *p : NULL; \ + } \ + /* Insert the element 'elm' into the table 'head'. Do not call this \ + * function if the table might already contain a matching element. */ \ + static inline void \ + name##_HT_INSERT(struct name *head, struct type *elm) \ + { \ + struct type **p; \ + if (!head->hth_table || head->hth_n_entries >= head->hth_load_limit) \ + name##_HT_GROW(head, head->hth_n_entries+1); \ + ++head->hth_n_entries; \ + HT_SET_HASH_(elm, field, hashfn); \ + p = &HT_BUCKET_(head, field, elm, hashfn); \ + elm->field.hte_next = *p; \ + *p = elm; \ + } \ + /* Insert the element 'elm' into the table 'head'. If there already \ + * a matching element in the table, replace that element and return \ + * it. */ \ + static inline struct type * \ + name##_HT_REPLACE(struct name *head, struct type *elm) \ + { \ + struct type **p, *r; \ + if (!head->hth_table || head->hth_n_entries >= head->hth_load_limit) \ + name##_HT_GROW(head, head->hth_n_entries+1); \ + HT_SET_HASH_(elm, field, hashfn); \ + p = name##_HT_FIND_P_(head, elm); \ + r = *p; \ + *p = elm; \ + if (r && (r!=elm)) { \ + elm->field.hte_next = r->field.hte_next; \ + r->field.hte_next = NULL; \ + return r; \ + } else { \ + ++head->hth_n_entries; \ + return NULL; \ + } \ + } \ + /* Remove any element matching 'elm' from the table 'head'. If such \ + * an element is found, return it; otherwise return NULL. */ \ + static inline struct type * \ + name##_HT_REMOVE(struct name *head, struct type *elm) \ + { \ + struct type **p, *r; \ + HT_SET_HASH_(elm, field, hashfn); \ + p = name##_HT_FIND_P_(head,elm); \ + if (!p || !*p) \ + return NULL; \ + r = *p; \ + *p = r->field.hte_next; \ + r->field.hte_next = NULL; \ + --head->hth_n_entries; \ + return r; \ + } \ + /* Invoke the function 'fn' on every element of the table 'head', \ + * using 'data' as its second argument. If the function returns \ + * nonzero, remove the most recently examined element before invoking \ + * the function again. */ \ + static inline void \ + name##_HT_FOREACH_FN(struct name *head, \ + int (*fn)(struct type *, void *), \ + void *data) \ + { \ + unsigned idx; \ + struct type **p, **nextp, *next; \ + if (!head->hth_table) \ + return; \ + for (idx=0; idx < head->hth_table_length; ++idx) { \ + p = &head->hth_table[idx]; \ + while (*p) { \ + nextp = &(*p)->field.hte_next; \ + next = *nextp; \ + if (fn(*p, data)) { \ + --head->hth_n_entries; \ + *p = next; \ + } else { \ + p = nextp; \ + } \ + } \ + } \ + } \ + /* Return a pointer to the first element in the table 'head', under \ + * an arbitrary order. This order is stable under remove operations, \ + * but not under others. If the table is empty, return NULL. */ \ + static inline struct type ** \ + name##_HT_START(struct name *head) \ + { \ + unsigned b = 0; \ + while (b < head->hth_table_length) { \ + if (head->hth_table[b]) \ + return &head->hth_table[b]; \ + ++b; \ + } \ + return NULL; \ + } \ + /* Return the next element in 'head' after 'elm', under the arbitrary \ + * order used by HT_START. If there are no more elements, return \ + * NULL. If 'elm' is to be removed from the table, you must call \ + * this function for the next value before you remove it. \ + */ \ + static inline struct type ** \ + name##_HT_NEXT(struct name *head, struct type **elm) \ + { \ + if ((*elm)->field.hte_next) { \ + return &(*elm)->field.hte_next; \ + } else { \ + unsigned b = (HT_ELT_HASH_(*elm, field, hashfn) % head->hth_table_length)+1; \ + while (b < head->hth_table_length) { \ + if (head->hth_table[b]) \ + return &head->hth_table[b]; \ + ++b; \ + } \ + return NULL; \ + } \ + } \ + static inline struct type ** \ + name##_HT_NEXT_RMV(struct name *head, struct type **elm) \ + { \ + unsigned h = HT_ELT_HASH_(*elm, field, hashfn); \ + *elm = (*elm)->field.hte_next; \ + --head->hth_n_entries; \ + if (*elm) { \ + return elm; \ + } else { \ + unsigned b = (h % head->hth_table_length)+1; \ + while (b < head->hth_table_length) { \ + if (head->hth_table[b]) \ + return &head->hth_table[b]; \ + ++b; \ + } \ + return NULL; \ + } \ + } + +#define HT_GENERATE(name, type, field, hashfn, eqfn, load, mallocfn, \ + reallocfn, freefn) \ + static unsigned name##_PRIMES[] = { \ + 53, 97, 193, 389, \ + 769, 1543, 3079, 6151, \ + 12289, 24593, 49157, 98317, \ + 196613, 393241, 786433, 1572869, \ + 3145739, 6291469, 12582917, 25165843, \ + 50331653, 100663319, 201326611, 402653189, \ + 805306457, 1610612741 \ + }; \ + static unsigned name##_N_PRIMES = \ + (unsigned)(sizeof(name##_PRIMES)/sizeof(name##_PRIMES[0])); \ + /* Expand the internal table of 'head' until it is large enough to \ + * hold 'size' elements. Return 0 on success, -1 on allocation \ + * failure. */ \ + int \ + name##_HT_GROW(struct name *head, unsigned size) \ + { \ + unsigned new_len, new_load_limit; \ + int prime_idx; \ + struct type **new_table; \ + if (head->hth_prime_idx == (int)name##_N_PRIMES - 1) \ + return 0; \ + if (head->hth_load_limit > size) \ + return 0; \ + prime_idx = head->hth_prime_idx; \ + do { \ + new_len = name##_PRIMES[++prime_idx]; \ + new_load_limit = (unsigned)(load*new_len); \ + } while (new_load_limit <= size && \ + prime_idx < (int)name##_N_PRIMES); \ + if ((new_table = mallocfn(new_len*sizeof(struct type*)))) { \ + unsigned b; \ + memset(new_table, 0, new_len*sizeof(struct type*)); \ + for (b = 0; b < head->hth_table_length; ++b) { \ + struct type *elm, *next; \ + unsigned b2; \ + elm = head->hth_table[b]; \ + while (elm) { \ + next = elm->field.hte_next; \ + b2 = HT_ELT_HASH_(elm, field, hashfn) % new_len; \ + elm->field.hte_next = new_table[b2]; \ + new_table[b2] = elm; \ + elm = next; \ + } \ + } \ + if (head->hth_table) \ + freefn(head->hth_table); \ + head->hth_table = new_table; \ + } else { \ + unsigned b, b2; \ + new_table = reallocfn(head->hth_table, new_len*sizeof(struct type*)); \ + if (!new_table) return -1; \ + memset(new_table + head->hth_table_length, 0, \ + (new_len - head->hth_table_length)*sizeof(struct type*)); \ + for (b=0; b < head->hth_table_length; ++b) { \ + struct type *e, **pE; \ + for (pE = &new_table[b], e = *pE; e != NULL; e = *pE) { \ + b2 = HT_ELT_HASH_(e, field, hashfn) % new_len; \ + if (b2 == b) { \ + pE = &e->field.hte_next; \ + } else { \ + *pE = e->field.hte_next; \ + e->field.hte_next = new_table[b2]; \ + new_table[b2] = e; \ + } \ + } \ + } \ + head->hth_table = new_table; \ + } \ + head->hth_table_length = new_len; \ + head->hth_prime_idx = prime_idx; \ + head->hth_load_limit = new_load_limit; \ + return 0; \ + } \ + /* Free all storage held by 'head'. Does not free 'head' itself, or \ + * individual elements. */ \ + void \ + name##_HT_CLEAR(struct name *head) \ + { \ + if (head->hth_table) \ + freefn(head->hth_table); \ + name##_HT_INIT(head); \ + } \ + /* Debugging helper: return false iff the representation of 'head' is \ + * internally consistent. */ \ + int \ + name##_HT_REP_IS_BAD_(const struct name *head) \ + { \ + unsigned n, i; \ + struct type *elm; \ + if (!head->hth_table_length) { \ + if (!head->hth_table && !head->hth_n_entries && \ + !head->hth_load_limit && head->hth_prime_idx == -1) \ + return 0; \ + else \ + return 1; \ + } \ + if (!head->hth_table || head->hth_prime_idx < 0 || \ + !head->hth_load_limit) \ + return 2; \ + if (head->hth_n_entries > head->hth_load_limit) \ + return 3; \ + if (head->hth_table_length != name##_PRIMES[head->hth_prime_idx]) \ + return 4; \ + if (head->hth_load_limit != (unsigned)(load*head->hth_table_length)) \ + return 5; \ + for (n = i = 0; i < head->hth_table_length; ++i) { \ + for (elm = head->hth_table[i]; elm; elm = elm->field.hte_next) { \ + if (HT_ELT_HASH_(elm, field, hashfn) != hashfn(elm)) \ + return 1000 + i; \ + if ((HT_ELT_HASH_(elm, field, hashfn) % head->hth_table_length) != i) \ + return 10000 + i; \ + ++n; \ + } \ + } \ + if (n != head->hth_n_entries) \ + return 6; \ + return 0; \ + } + +/** Implements an over-optimized "find and insert if absent" block; + * not meant for direct usage by typical code, or usage outside the critical + * path.*/ +#define HT_FIND_OR_INSERT_(name, field, hashfn, head, eltype, elm, var, y, n) \ + { \ + struct name *var##_head_ = head; \ + struct eltype **var; \ + if (!var##_head_->hth_table || \ + var##_head_->hth_n_entries >= var##_head_->hth_load_limit) \ + name##_HT_GROW(var##_head_, var##_head_->hth_n_entries+1); \ + HT_SET_HASH_((elm), field, hashfn); \ + var = name##_HT_FIND_P_(var##_head_, (elm)); \ + if (*var) { \ + y; \ + } else { \ + n; \ + } \ + } +#define HT_FOI_INSERT_(field, head, elm, newent, var) \ + { \ + HT_SET_HASHVAL_(newent, field, (elm)->field.hte_hash); \ + newent->field.hte_next = NULL; \ + *var = newent; \ + ++((head)->hth_n_entries); \ + } + +/* + * Copyright 2005, Nick Mathewson. Implementation logic is adapted from code + * by Christopher Clark, retrofit to allow drop-in memory management, and to + * use the same interface as Niels Provos's tree.h. This is probably still + * a derived work, so the original license below still applies. + * + * Copyright (c) 2002, Christopher Clark + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * * Neither the name of the original author; nor the names of any contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER + * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +*/ + +#endif + diff --git a/contrib/ntp/sntp/libevent/http-internal.h b/contrib/ntp/sntp/libevent/http-internal.h new file mode 100644 index 000000000..a83160c83 --- /dev/null +++ b/contrib/ntp/sntp/libevent/http-internal.h @@ -0,0 +1,206 @@ +/* + * Copyright 2001-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * This header file contains definitions for dealing with HTTP requests + * that are internal to libevent. As user of the library, you should not + * need to know about these. + */ + +#ifndef HTTP_INTERNAL_H_INCLUDED_ +#define HTTP_INTERNAL_H_INCLUDED_ + +#include "event2/event_struct.h" +#include "util-internal.h" +#include "defer-internal.h" + +#define HTTP_CONNECT_TIMEOUT 45 +#define HTTP_WRITE_TIMEOUT 50 +#define HTTP_READ_TIMEOUT 50 + +#define HTTP_PREFIX "http://" +#define HTTP_DEFAULTPORT 80 + +enum message_read_status { + ALL_DATA_READ = 1, + MORE_DATA_EXPECTED = 0, + DATA_CORRUPTED = -1, + REQUEST_CANCELED = -2, + DATA_TOO_LONG = -3 +}; + +struct evbuffer; +struct addrinfo; +struct evhttp_request; + +/* Indicates an unknown request method. */ +#define EVHTTP_REQ_UNKNOWN_ (1<<15) + +enum evhttp_connection_state { + EVCON_DISCONNECTED, /**< not currently connected not trying either*/ + EVCON_CONNECTING, /**< tries to currently connect */ + EVCON_IDLE, /**< connection is established */ + EVCON_READING_FIRSTLINE,/**< reading Request-Line (incoming conn) or + **< Status-Line (outgoing conn) */ + EVCON_READING_HEADERS, /**< reading request/response headers */ + EVCON_READING_BODY, /**< reading request/response body */ + EVCON_READING_TRAILER, /**< reading request/response chunked trailer */ + EVCON_WRITING /**< writing request/response headers/body */ +}; + +struct event_base; + +/* A client or server connection. */ +struct evhttp_connection { + /* we use this tailq only if this connection was created for an http + * server */ + TAILQ_ENTRY(evhttp_connection) next; + + evutil_socket_t fd; + struct bufferevent *bufev; + + struct event retry_ev; /* for retrying connects */ + + char *bind_address; /* address to use for binding the src */ + u_short bind_port; /* local port for binding the src */ + + char *address; /* address to connect to */ + u_short port; + + size_t max_headers_size; + ev_uint64_t max_body_size; + + int flags; +#define EVHTTP_CON_INCOMING 0x0001 /* only one request on it ever */ +#define EVHTTP_CON_OUTGOING 0x0002 /* multiple requests possible */ +#define EVHTTP_CON_CLOSEDETECT 0x0004 /* detecting if persistent close */ +#define EVHTTP_CON_AUTOFREE 0x0008 /* set when we want to auto free the connection */ + + struct timeval timeout; /* timeout for events */ + int retry_cnt; /* retry count */ + int retry_max; /* maximum number of retries */ + struct timeval initial_retry_timeout; /* Timeout for low long to wait + * after first failing attempt + * before retry */ + + enum evhttp_connection_state state; + + /* for server connections, the http server they are connected with */ + struct evhttp *http_server; + + TAILQ_HEAD(evcon_requestq, evhttp_request) requests; + + void (*cb)(struct evhttp_connection *, void *); + void *cb_arg; + + void (*closecb)(struct evhttp_connection *, void *); + void *closecb_arg; + + struct event_callback read_more_deferred_cb; + + struct event_base *base; + struct evdns_base *dns_base; + int ai_family; + + /* Saved conn_addr, to extract IP address from it. + * + * Because some servers may reset/close connection without waiting clients, + * in that case we can't extract IP address even in close_cb. + * So we need to save it, just after we connected to remote server. */ + struct sockaddr_storage *conn_address; +}; + +/* A callback for an http server */ +struct evhttp_cb { + TAILQ_ENTRY(evhttp_cb) next; + + char *what; + + void (*cb)(struct evhttp_request *req, void *); + void *cbarg; +}; + +/* both the http server as well as the rpc system need to queue connections */ +TAILQ_HEAD(evconq, evhttp_connection); + +/* each bound socket is stored in one of these */ +struct evhttp_bound_socket { + TAILQ_ENTRY(evhttp_bound_socket) next; + + struct evconnlistener *listener; +}; + +/* server alias list item. */ +struct evhttp_server_alias { + TAILQ_ENTRY(evhttp_server_alias) next; + + char *alias; /* the server alias. */ +}; + +struct evhttp { + /* Next vhost, if this is a vhost. */ + TAILQ_ENTRY(evhttp) next_vhost; + + /* All listeners for this host */ + TAILQ_HEAD(boundq, evhttp_bound_socket) sockets; + + TAILQ_HEAD(httpcbq, evhttp_cb) callbacks; + + /* All live connections on this host. */ + struct evconq connections; + + TAILQ_HEAD(vhostsq, evhttp) virtualhosts; + + TAILQ_HEAD(aliasq, evhttp_server_alias) aliases; + + /* NULL if this server is not a vhost */ + char *vhost_pattern; + + struct timeval timeout; + + size_t default_max_headers_size; + ev_uint64_t default_max_body_size; + const char *default_content_type; + + /* Bitmask of all HTTP methods that we accept and pass to user + * callbacks. */ + ev_uint16_t allowed_methods; + + /* Fallback callback if all the other callbacks for this connection + don't match. */ + void (*gencb)(struct evhttp_request *req, void *); + void *gencbarg; + struct bufferevent* (*bevcb)(struct event_base *, void *); + void *bevcbarg; + + struct event_base *base; +}; + +/* XXX most of these functions could be static. */ + +/* resets the connection; can be reused for more requests */ +void evhttp_connection_reset_(struct evhttp_connection *); + +/* connects if necessary */ +int evhttp_connection_connect_(struct evhttp_connection *); + +enum evhttp_request_error; +/* notifies the current request that it failed; resets connection */ +void evhttp_connection_fail_(struct evhttp_connection *, + enum evhttp_request_error error); + +enum message_read_status; + +enum message_read_status evhttp_parse_firstline_(struct evhttp_request *, struct evbuffer*); +enum message_read_status evhttp_parse_headers_(struct evhttp_request *, struct evbuffer*); + +void evhttp_start_read_(struct evhttp_connection *); + +/* response sending HTML the data in the buffer */ +void evhttp_response_code_(struct evhttp_request *, int, const char *); +void evhttp_send_page_(struct evhttp_request *, struct evbuffer *); + +int evhttp_decode_uri_internal(const char *uri, size_t length, + char *ret, int decode_plus); + +#endif /* _HTTP_H */ diff --git a/contrib/ntp/sntp/libevent/http.c b/contrib/ntp/sntp/libevent/http.c new file mode 100644 index 000000000..dd8c9cffd --- /dev/null +++ b/contrib/ntp/sntp/libevent/http.c @@ -0,0 +1,4857 @@ +/* + * Copyright (c) 2002-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_SYS_PARAM_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif + +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#ifdef HAVE_SYS_IOCCOM_H +#include +#endif + +#ifndef _WIN32 +#include +#include +#include +#include +#else +#include +#include +#endif + +#include + +#ifdef EVENT__HAVE_NETINET_IN_H +#include +#endif +#ifdef EVENT__HAVE_ARPA_INET_H +#include +#endif +#ifdef EVENT__HAVE_NETDB_H +#include +#endif + +#ifdef _WIN32 +#include +#endif + +#include +#include +#include +#include +#ifndef _WIN32 +#include +#endif +#include +#include +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#ifdef EVENT__HAVE_FCNTL_H +#include +#endif + +#undef timeout_pending +#undef timeout_initialized + +#include "strlcpy-internal.h" +#include "event2/http.h" +#include "event2/event.h" +#include "event2/buffer.h" +#include "event2/bufferevent.h" +#include "event2/http_struct.h" +#include "event2/http_compat.h" +#include "event2/util.h" +#include "event2/listener.h" +#include "log-internal.h" +#include "util-internal.h" +#include "http-internal.h" +#include "mm-internal.h" +#include "bufferevent-internal.h" + +#ifndef EVENT__HAVE_GETNAMEINFO +#define NI_MAXSERV 32 +#define NI_MAXHOST 1025 + +#ifndef NI_NUMERICHOST +#define NI_NUMERICHOST 1 +#endif + +#ifndef NI_NUMERICSERV +#define NI_NUMERICSERV 2 +#endif + +static int +fake_getnameinfo(const struct sockaddr *sa, size_t salen, char *host, + size_t hostlen, char *serv, size_t servlen, int flags) +{ + struct sockaddr_in *sin = (struct sockaddr_in *)sa; + + if (serv != NULL) { + char tmpserv[16]; + evutil_snprintf(tmpserv, sizeof(tmpserv), + "%d", ntohs(sin->sin_port)); + if (strlcpy(serv, tmpserv, servlen) >= servlen) + return (-1); + } + + if (host != NULL) { + if (flags & NI_NUMERICHOST) { + if (strlcpy(host, inet_ntoa(sin->sin_addr), + hostlen) >= hostlen) + return (-1); + else + return (0); + } else { + struct hostent *hp; + hp = gethostbyaddr((char *)&sin->sin_addr, + sizeof(struct in_addr), AF_INET); + if (hp == NULL) + return (-2); + + if (strlcpy(host, hp->h_name, hostlen) >= hostlen) + return (-1); + else + return (0); + } + } + return (0); +} + +#endif + +#define REQ_VERSION_BEFORE(req, major_v, minor_v) \ + ((req)->major < (major_v) || \ + ((req)->major == (major_v) && (req)->minor < (minor_v))) + +#define REQ_VERSION_ATLEAST(req, major_v, minor_v) \ + ((req)->major > (major_v) || \ + ((req)->major == (major_v) && (req)->minor >= (minor_v))) + +#ifndef MIN +#define MIN(a,b) (((a)<(b))?(a):(b)) +#endif + +extern int debug; + +static evutil_socket_t bind_socket_ai(struct evutil_addrinfo *, int reuse); +static evutil_socket_t bind_socket(const char *, ev_uint16_t, int reuse); +static void name_from_addr(struct sockaddr *, ev_socklen_t, char **, char **); +static int evhttp_associate_new_request_with_connection( + struct evhttp_connection *evcon); +static void evhttp_connection_start_detectclose( + struct evhttp_connection *evcon); +static void evhttp_connection_stop_detectclose( + struct evhttp_connection *evcon); +static void evhttp_request_dispatch(struct evhttp_connection* evcon); +static void evhttp_read_firstline(struct evhttp_connection *evcon, + struct evhttp_request *req); +static void evhttp_read_header(struct evhttp_connection *evcon, + struct evhttp_request *req); +static int evhttp_add_header_internal(struct evkeyvalq *headers, + const char *key, const char *value); +static const char *evhttp_response_phrase_internal(int code); +static void evhttp_get_request(struct evhttp *, evutil_socket_t, struct sockaddr *, ev_socklen_t); +static void evhttp_write_buffer(struct evhttp_connection *, + void (*)(struct evhttp_connection *, void *), void *); +static void evhttp_make_header(struct evhttp_connection *, struct evhttp_request *); + +/* callbacks for bufferevent */ +static void evhttp_read_cb(struct bufferevent *, void *); +static void evhttp_write_cb(struct bufferevent *, void *); +static void evhttp_error_cb(struct bufferevent *bufev, short what, void *arg); +static int evhttp_find_vhost(struct evhttp *http, struct evhttp **outhttp, + const char *hostname); + +#ifndef EVENT__HAVE_STRSEP +/* strsep replacement for platforms that lack it. Only works if + * del is one character long. */ +static char * +strsep(char **s, const char *del) +{ + char *d, *tok; + EVUTIL_ASSERT(strlen(del) == 1); + if (!s || !*s) + return NULL; + tok = *s; + d = strstr(tok, del); + if (d) { + *d = '\0'; + *s = d + 1; + } else + *s = NULL; + return tok; +} +#endif + +static size_t +html_replace(const char ch, const char **escaped) +{ + switch (ch) { + case '<': + *escaped = "<"; + return 4; + case '>': + *escaped = ">"; + return 4; + case '"': + *escaped = """; + return 6; + case '\'': + *escaped = "'"; + return 6; + case '&': + *escaped = "&"; + return 5; + default: + break; + } + + return 1; +} + +/* + * Replaces <, >, ", ' and & with <, >, ", + * ' and & correspondingly. + * + * The returned string needs to be freed by the caller. + */ + +char * +evhttp_htmlescape(const char *html) +{ + size_t i; + size_t new_size = 0, old_size = 0; + char *escaped_html, *p; + + if (html == NULL) + return (NULL); + + old_size = strlen(html); + for (i = 0; i < old_size; ++i) { + const char *replaced = NULL; + const size_t replace_size = html_replace(html[i], &replaced); + if (replace_size > EV_SIZE_MAX - new_size) { + event_warn("%s: html_replace overflow", __func__); + return (NULL); + } + new_size += replace_size; + } + + if (new_size == EV_SIZE_MAX) + return (NULL); + p = escaped_html = mm_malloc(new_size + 1); + if (escaped_html == NULL) { + event_warn("%s: malloc(%lu)", __func__, + (unsigned long)(new_size + 1)); + return (NULL); + } + for (i = 0; i < old_size; ++i) { + const char *replaced = &html[i]; + const size_t len = html_replace(html[i], &replaced); + memcpy(p, replaced, len); + p += len; + } + + *p = '\0'; + + return (escaped_html); +} + +/** Given an evhttp_cmd_type, returns a constant string containing the + * equivalent HTTP command, or NULL if the evhttp_command_type is + * unrecognized. */ +static const char * +evhttp_method(enum evhttp_cmd_type type) +{ + const char *method; + + switch (type) { + case EVHTTP_REQ_GET: + method = "GET"; + break; + case EVHTTP_REQ_POST: + method = "POST"; + break; + case EVHTTP_REQ_HEAD: + method = "HEAD"; + break; + case EVHTTP_REQ_PUT: + method = "PUT"; + break; + case EVHTTP_REQ_DELETE: + method = "DELETE"; + break; + case EVHTTP_REQ_OPTIONS: + method = "OPTIONS"; + break; + case EVHTTP_REQ_TRACE: + method = "TRACE"; + break; + case EVHTTP_REQ_CONNECT: + method = "CONNECT"; + break; + case EVHTTP_REQ_PATCH: + method = "PATCH"; + break; + default: + method = NULL; + break; + } + + return (method); +} + +/** + * Determines if a response should have a body. + * Follows the rules in RFC 2616 section 4.3. + * @return 1 if the response MUST have a body; 0 if the response MUST NOT have + * a body. + */ +static int +evhttp_response_needs_body(struct evhttp_request *req) +{ + return (req->response_code != HTTP_NOCONTENT && + req->response_code != HTTP_NOTMODIFIED && + (req->response_code < 100 || req->response_code >= 200) && + req->type != EVHTTP_REQ_HEAD); +} + +/** Helper: called after we've added some data to an evcon's bufferevent's + * output buffer. Sets the evconn's writing-is-done callback, and puts + * the bufferevent into writing mode. + */ +static void +evhttp_write_buffer(struct evhttp_connection *evcon, + void (*cb)(struct evhttp_connection *, void *), void *arg) +{ + event_debug(("%s: preparing to write buffer\n", __func__)); + + /* Set call back */ + evcon->cb = cb; + evcon->cb_arg = arg; + + /* Disable the read callback: we don't actually care about data; + * we only care about close detection. (We don't disable reading, + * since we *do* want to learn about any close events.) */ + bufferevent_setcb(evcon->bufev, + NULL, /*read*/ + evhttp_write_cb, + evhttp_error_cb, + evcon); + + bufferevent_enable(evcon->bufev, EV_WRITE); +} + +static void +evhttp_send_continue_done(struct evhttp_connection *evcon, void *arg) +{ + bufferevent_disable(evcon->bufev, EV_WRITE); +} + +static void +evhttp_send_continue(struct evhttp_connection *evcon, + struct evhttp_request *req) +{ + bufferevent_enable(evcon->bufev, EV_WRITE); + evbuffer_add_printf(bufferevent_get_output(evcon->bufev), + "HTTP/%d.%d 100 Continue\r\n\r\n", + req->major, req->minor); + evcon->cb = evhttp_send_continue_done; + evcon->cb_arg = NULL; + bufferevent_setcb(evcon->bufev, + evhttp_read_cb, + evhttp_write_cb, + evhttp_error_cb, + evcon); +} + +/** Helper: returns true iff evconn is in any connected state. */ +static int +evhttp_connected(struct evhttp_connection *evcon) +{ + switch (evcon->state) { + case EVCON_DISCONNECTED: + case EVCON_CONNECTING: + return (0); + case EVCON_IDLE: + case EVCON_READING_FIRSTLINE: + case EVCON_READING_HEADERS: + case EVCON_READING_BODY: + case EVCON_READING_TRAILER: + case EVCON_WRITING: + default: + return (1); + } +} + +/* Create the headers needed for an outgoing HTTP request, adds them to + * the request's header list, and writes the request line to the + * connection's output buffer. + */ +static void +evhttp_make_header_request(struct evhttp_connection *evcon, + struct evhttp_request *req) +{ + const char *method; + + evhttp_remove_header(req->output_headers, "Proxy-Connection"); + + /* Generate request line */ + method = evhttp_method(req->type); + evbuffer_add_printf(bufferevent_get_output(evcon->bufev), + "%s %s HTTP/%d.%d\r\n", + method, req->uri, req->major, req->minor); + + /* Add the content length on a post or put request if missing */ + if ((req->type == EVHTTP_REQ_POST || req->type == EVHTTP_REQ_PUT) && + evhttp_find_header(req->output_headers, "Content-Length") == NULL){ + char size[22]; + evutil_snprintf(size, sizeof(size), EV_SIZE_FMT, + EV_SIZE_ARG(evbuffer_get_length(req->output_buffer))); + evhttp_add_header(req->output_headers, "Content-Length", size); + } +} + +/** Return true if the list of headers in 'headers', intepreted with respect + * to flags, means that we should send a "connection: close" when the request + * is done. */ +static int +evhttp_is_connection_close(int flags, struct evkeyvalq* headers) +{ + if (flags & EVHTTP_PROXY_REQUEST) { + /* proxy connection */ + const char *connection = evhttp_find_header(headers, "Proxy-Connection"); + return (connection == NULL || evutil_ascii_strcasecmp(connection, "keep-alive") != 0); + } else { + const char *connection = evhttp_find_header(headers, "Connection"); + return (connection != NULL && evutil_ascii_strcasecmp(connection, "close") == 0); + } +} + +/* Return true iff 'headers' contains 'Connection: keep-alive' */ +static int +evhttp_is_connection_keepalive(struct evkeyvalq* headers) +{ + const char *connection = evhttp_find_header(headers, "Connection"); + return (connection != NULL + && evutil_ascii_strncasecmp(connection, "keep-alive", 10) == 0); +} + +/* Add a correct "Date" header to headers, unless it already has one. */ +static void +evhttp_maybe_add_date_header(struct evkeyvalq *headers) +{ + if (evhttp_find_header(headers, "Date") == NULL) { + char date[50]; +#ifndef _WIN32 + struct tm cur; +#endif + struct tm *cur_p; + time_t t = time(NULL); +#ifdef _WIN32 + cur_p = gmtime(&t); +#else + gmtime_r(&t, &cur); + cur_p = &cur; +#endif + if (strftime(date, sizeof(date), + "%a, %d %b %Y %H:%M:%S GMT", cur_p) != 0) { + evhttp_add_header(headers, "Date", date); + } + } +} + +/* Add a "Content-Length" header with value 'content_length' to headers, + * unless it already has a content-length or transfer-encoding header. */ +static void +evhttp_maybe_add_content_length_header(struct evkeyvalq *headers, + size_t content_length) +{ + if (evhttp_find_header(headers, "Transfer-Encoding") == NULL && + evhttp_find_header(headers, "Content-Length") == NULL) { + char len[22]; + evutil_snprintf(len, sizeof(len), EV_SIZE_FMT, + EV_SIZE_ARG(content_length)); + evhttp_add_header(headers, "Content-Length", len); + } +} + +/* + * Create the headers needed for an HTTP reply in req->output_headers, + * and write the first HTTP response for req line to evcon. + */ +static void +evhttp_make_header_response(struct evhttp_connection *evcon, + struct evhttp_request *req) +{ + int is_keepalive = evhttp_is_connection_keepalive(req->input_headers); + evbuffer_add_printf(bufferevent_get_output(evcon->bufev), + "HTTP/%d.%d %d %s\r\n", + req->major, req->minor, req->response_code, + req->response_code_line); + + if (req->major == 1) { + if (req->minor >= 1) + evhttp_maybe_add_date_header(req->output_headers); + + /* + * if the protocol is 1.0; and the connection was keep-alive + * we need to add a keep-alive header, too. + */ + if (req->minor == 0 && is_keepalive) + evhttp_add_header(req->output_headers, + "Connection", "keep-alive"); + + if ((req->minor >= 1 || is_keepalive) && + evhttp_response_needs_body(req)) { + /* + * we need to add the content length if the + * user did not give it, this is required for + * persistent connections to work. + */ + evhttp_maybe_add_content_length_header( + req->output_headers, + evbuffer_get_length(req->output_buffer)); + } + } + + /* Potentially add headers for unidentified content. */ + if (evhttp_response_needs_body(req)) { + if (evhttp_find_header(req->output_headers, + "Content-Type") == NULL + && evcon->http_server->default_content_type) { + evhttp_add_header(req->output_headers, + "Content-Type", + evcon->http_server->default_content_type); + } + } + + /* if the request asked for a close, we send a close, too */ + if (evhttp_is_connection_close(req->flags, req->input_headers)) { + evhttp_remove_header(req->output_headers, "Connection"); + if (!(req->flags & EVHTTP_PROXY_REQUEST)) + evhttp_add_header(req->output_headers, "Connection", "close"); + evhttp_remove_header(req->output_headers, "Proxy-Connection"); + } +} + +/** Generate all headers appropriate for sending the http request in req (or + * the response, if we're sending a response), and write them to evcon's + * bufferevent. Also writes all data from req->output_buffer */ +static void +evhttp_make_header(struct evhttp_connection *evcon, struct evhttp_request *req) +{ + struct evkeyval *header; + struct evbuffer *output = bufferevent_get_output(evcon->bufev); + + /* + * Depending if this is a HTTP request or response, we might need to + * add some new headers or remove existing headers. + */ + if (req->kind == EVHTTP_REQUEST) { + evhttp_make_header_request(evcon, req); + } else { + evhttp_make_header_response(evcon, req); + } + + TAILQ_FOREACH(header, req->output_headers, next) { + evbuffer_add_printf(output, "%s: %s\r\n", + header->key, header->value); + } + evbuffer_add(output, "\r\n", 2); + + if (evbuffer_get_length(req->output_buffer) > 0) { + /* + * For a request, we add the POST data, for a reply, this + * is the regular data. + */ + /* XXX We might want to support waiting (a limited amount of + time) for a continue status line from the server before + sending POST/PUT message bodies. */ + evbuffer_add_buffer(output, req->output_buffer); + } +} + +void +evhttp_connection_set_max_headers_size(struct evhttp_connection *evcon, + ev_ssize_t new_max_headers_size) +{ + if (new_max_headers_size<0) + evcon->max_headers_size = EV_SIZE_MAX; + else + evcon->max_headers_size = new_max_headers_size; +} +void +evhttp_connection_set_max_body_size(struct evhttp_connection* evcon, + ev_ssize_t new_max_body_size) +{ + if (new_max_body_size<0) + evcon->max_body_size = EV_UINT64_MAX; + else + evcon->max_body_size = new_max_body_size; +} + +static int +evhttp_connection_incoming_fail(struct evhttp_request *req, + enum evhttp_request_error error) +{ + switch (error) { + case EVREQ_HTTP_TIMEOUT: + case EVREQ_HTTP_EOF: + /* + * these are cases in which we probably should just + * close the connection and not send a reply. this + * case may happen when a browser keeps a persistent + * connection open and we timeout on the read. when + * the request is still being used for sending, we + * need to disassociated it from the connection here. + */ + if (!req->userdone) { + /* remove it so that it will not be freed */ + TAILQ_REMOVE(&req->evcon->requests, req, next); + /* indicate that this request no longer has a + * connection object + */ + req->evcon = NULL; + } + return (-1); + case EVREQ_HTTP_INVALID_HEADER: + case EVREQ_HTTP_BUFFER_ERROR: + case EVREQ_HTTP_REQUEST_CANCEL: + case EVREQ_HTTP_DATA_TOO_LONG: + default: /* xxx: probably should just error on default */ + /* the callback looks at the uri to determine errors */ + if (req->uri) { + mm_free(req->uri); + req->uri = NULL; + } + if (req->uri_elems) { + evhttp_uri_free(req->uri_elems); + req->uri_elems = NULL; + } + + /* + * the callback needs to send a reply, once the reply has + * been send, the connection should get freed. + */ + (*req->cb)(req, req->cb_arg); + } + + return (0); +} + +/* Called when evcon has experienced a (non-recoverable? -NM) error, as + * given in error. If it's an outgoing connection, reset the connection, + * retry any pending requests, and inform the user. If it's incoming, + * delegates to evhttp_connection_incoming_fail(). */ +void +evhttp_connection_fail_(struct evhttp_connection *evcon, + enum evhttp_request_error error) +{ + const int errsave = EVUTIL_SOCKET_ERROR(); + struct evhttp_request* req = TAILQ_FIRST(&evcon->requests); + void (*cb)(struct evhttp_request *, void *); + void *cb_arg; + void (*error_cb)(enum evhttp_request_error, void *); + void *error_cb_arg; + EVUTIL_ASSERT(req != NULL); + + bufferevent_disable(evcon->bufev, EV_READ|EV_WRITE); + + if (evcon->flags & EVHTTP_CON_INCOMING) { + /* + * for incoming requests, there are two different + * failure cases. it's either a network level error + * or an http layer error. for problems on the network + * layer like timeouts we just drop the connections. + * For HTTP problems, we might have to send back a + * reply before the connection can be freed. + */ + if (evhttp_connection_incoming_fail(req, error) == -1) + evhttp_connection_free(evcon); + return; + } + + error_cb = req->error_cb; + error_cb_arg = req->cb_arg; + /* when the request was canceled, the callback is not executed */ + if (error != EVREQ_HTTP_REQUEST_CANCEL) { + /* save the callback for later; the cb might free our object */ + cb = req->cb; + cb_arg = req->cb_arg; + } else { + cb = NULL; + cb_arg = NULL; + } + + /* do not fail all requests; the next request is going to get + * send over a new connection. when a user cancels a request, + * all other pending requests should be processed as normal + */ + TAILQ_REMOVE(&evcon->requests, req, next); + evhttp_request_free(req); + + /* reset the connection */ + evhttp_connection_reset_(evcon); + + /* We are trying the next request that was queued on us */ + if (TAILQ_FIRST(&evcon->requests) != NULL) + evhttp_connection_connect_(evcon); + + /* The call to evhttp_connection_reset_ overwrote errno. + * Let's restore the original errno, so that the user's + * callback can have a better idea of what the error was. + */ + EVUTIL_SET_SOCKET_ERROR(errsave); + + /* inform the user */ + if (error_cb != NULL) + error_cb(error, error_cb_arg); + if (cb != NULL) + (*cb)(NULL, cb_arg); +} + +/* Bufferevent callback: invoked when any data has been written from an + * http connection's bufferevent */ +static void +evhttp_write_cb(struct bufferevent *bufev, void *arg) +{ + struct evhttp_connection *evcon = arg; + + /* Activate our call back */ + if (evcon->cb != NULL) + (*evcon->cb)(evcon, evcon->cb_arg); +} + +/** + * Advance the connection state. + * - If this is an outgoing connection, we've just processed the response; + * idle or close the connection. + * - If this is an incoming connection, we've just processed the request; + * respond. + */ +static void +evhttp_connection_done(struct evhttp_connection *evcon) +{ + struct evhttp_request *req = TAILQ_FIRST(&evcon->requests); + int con_outgoing = evcon->flags & EVHTTP_CON_OUTGOING; + int free_evcon = 0; + + if (con_outgoing) { + /* idle or close the connection */ + int need_close; + TAILQ_REMOVE(&evcon->requests, req, next); + req->evcon = NULL; + + evcon->state = EVCON_IDLE; + + need_close = + evhttp_is_connection_close(req->flags, req->input_headers)|| + evhttp_is_connection_close(req->flags, req->output_headers); + + /* check if we got asked to close the connection */ + if (need_close) + evhttp_connection_reset_(evcon); + + if (TAILQ_FIRST(&evcon->requests) != NULL) { + /* + * We have more requests; reset the connection + * and deal with the next request. + */ + if (!evhttp_connected(evcon)) + evhttp_connection_connect_(evcon); + else + evhttp_request_dispatch(evcon); + } else if (!need_close) { + /* + * The connection is going to be persistent, but we + * need to detect if the other side closes it. + */ + evhttp_connection_start_detectclose(evcon); + } else if ((evcon->flags & EVHTTP_CON_AUTOFREE)) { + /* + * If we have no more requests that need completion + * and we're not waiting for the connection to close + */ + free_evcon = 1; + } + } else { + /* + * incoming connection - we need to leave the request on the + * connection so that we can reply to it. + */ + evcon->state = EVCON_WRITING; + } + + /* notify the user of the request */ + (*req->cb)(req, req->cb_arg); + + /* if this was an outgoing request, we own and it's done. so free it. + * unless the callback specifically requested to own the request. + */ + if (con_outgoing && ((req->flags & EVHTTP_USER_OWNED) == 0)) { + evhttp_request_free(req); + } + + /* If this was the last request of an outgoing connection and we're + * not waiting to receive a connection close event and we want to + * automatically free the connection. We check to ensure our request + * list is empty one last time just in case our callback added a + * new request. + */ + if (free_evcon && TAILQ_FIRST(&evcon->requests) == NULL) { + evhttp_connection_free(evcon); + } +} + +/* + * Handles reading from a chunked request. + * return ALL_DATA_READ: + * all data has been read + * return MORE_DATA_EXPECTED: + * more data is expected + * return DATA_CORRUPTED: + * data is corrupted + * return REQUEST_CANCELED: + * request was canceled by the user calling evhttp_cancel_request + * return DATA_TOO_LONG: + * ran over the maximum limit + */ + +static enum message_read_status +evhttp_handle_chunked_read(struct evhttp_request *req, struct evbuffer *buf) +{ + if (req == NULL || buf == NULL) { + return DATA_CORRUPTED; + } + + while (1) { + size_t buflen; + + if ((buflen = evbuffer_get_length(buf)) == 0) { + break; + } + + /* evbuffer_get_length returns size_t, but len variable is ssize_t, + * check for overflow conditions */ + if (buflen > EV_SSIZE_MAX) { + return DATA_CORRUPTED; + } + + if (req->ntoread < 0) { + /* Read chunk size */ + ev_int64_t ntoread; + char *p = evbuffer_readln(buf, NULL, EVBUFFER_EOL_CRLF); + char *endp; + int error; + if (p == NULL) + break; + /* the last chunk is on a new line? */ + if (strlen(p) == 0) { + mm_free(p); + continue; + } + ntoread = evutil_strtoll(p, &endp, 16); + error = (*p == '\0' || + (*endp != '\0' && *endp != ' ') || + ntoread < 0); + mm_free(p); + if (error) { + /* could not get chunk size */ + return (DATA_CORRUPTED); + } + + /* ntoread is signed int64, body_size is unsigned size_t, check for under/overflow conditions */ + if ((ev_uint64_t)ntoread > EV_SIZE_MAX - req->body_size) { + return DATA_CORRUPTED; + } + + if (req->body_size + (size_t)ntoread > req->evcon->max_body_size) { + /* failed body length test */ + event_debug(("Request body is too long")); + return (DATA_TOO_LONG); + } + + req->body_size += (size_t)ntoread; + req->ntoread = ntoread; + if (req->ntoread == 0) { + /* Last chunk */ + return (ALL_DATA_READ); + } + continue; + } + + /* req->ntoread is signed int64, len is ssize_t, based on arch, + * ssize_t could only be 32b, check for these conditions */ + if (req->ntoread > EV_SSIZE_MAX) { + return DATA_CORRUPTED; + } + + /* don't have enough to complete a chunk; wait for more */ + if (req->ntoread > 0 && buflen < (ev_uint64_t)req->ntoread) + return (MORE_DATA_EXPECTED); + + /* Completed chunk */ + evbuffer_remove_buffer(buf, req->input_buffer, (size_t)req->ntoread); + req->ntoread = -1; + if (req->chunk_cb != NULL) { + req->flags |= EVHTTP_REQ_DEFER_FREE; + (*req->chunk_cb)(req, req->cb_arg); + evbuffer_drain(req->input_buffer, + evbuffer_get_length(req->input_buffer)); + req->flags &= ~EVHTTP_REQ_DEFER_FREE; + if ((req->flags & EVHTTP_REQ_NEEDS_FREE) != 0) { + return (REQUEST_CANCELED); + } + } + } + + return (MORE_DATA_EXPECTED); +} + +static void +evhttp_read_trailer(struct evhttp_connection *evcon, struct evhttp_request *req) +{ + struct evbuffer *buf = bufferevent_get_input(evcon->bufev); + + switch (evhttp_parse_headers_(req, buf)) { + case DATA_CORRUPTED: + case DATA_TOO_LONG: + evhttp_connection_fail_(evcon, EVREQ_HTTP_DATA_TOO_LONG); + break; + case ALL_DATA_READ: + bufferevent_disable(evcon->bufev, EV_READ); + evhttp_connection_done(evcon); + break; + case MORE_DATA_EXPECTED: + case REQUEST_CANCELED: /* ??? */ + default: + bufferevent_enable(evcon->bufev, EV_READ); + break; + } +} + +static void +evhttp_read_body(struct evhttp_connection *evcon, struct evhttp_request *req) +{ + struct evbuffer *buf = bufferevent_get_input(evcon->bufev); + + if (req->chunked) { + switch (evhttp_handle_chunked_read(req, buf)) { + case ALL_DATA_READ: + /* finished last chunk */ + evcon->state = EVCON_READING_TRAILER; + evhttp_read_trailer(evcon, req); + return; + case DATA_CORRUPTED: + case DATA_TOO_LONG: + /* corrupted data */ + evhttp_connection_fail_(evcon, + EVREQ_HTTP_DATA_TOO_LONG); + return; + case REQUEST_CANCELED: + /* request canceled */ + evhttp_request_free(req); + return; + case MORE_DATA_EXPECTED: + default: + break; + } + } else if (req->ntoread < 0) { + /* Read until connection close. */ + if ((size_t)(req->body_size + evbuffer_get_length(buf)) < req->body_size) { + evhttp_connection_fail_(evcon, EVREQ_HTTP_INVALID_HEADER); + return; + } + + req->body_size += evbuffer_get_length(buf); + evbuffer_add_buffer(req->input_buffer, buf); + } else if (req->chunk_cb != NULL || evbuffer_get_length(buf) >= (size_t)req->ntoread) { + /* XXX: the above get_length comparison has to be fixed for overflow conditions! */ + /* We've postponed moving the data until now, but we're + * about to use it. */ + size_t n = evbuffer_get_length(buf); + + if (n > (size_t) req->ntoread) + n = (size_t) req->ntoread; + req->ntoread -= n; + req->body_size += n; + evbuffer_remove_buffer(buf, req->input_buffer, n); + } + + if (req->body_size > req->evcon->max_body_size || + (!req->chunked && req->ntoread >= 0 && + (size_t)req->ntoread > req->evcon->max_body_size)) { + /* XXX: The above casted comparison must checked for overflow */ + /* failed body length test */ + event_debug(("Request body is too long")); + evhttp_connection_fail_(evcon, + EVREQ_HTTP_DATA_TOO_LONG); + return; + } + + if (evbuffer_get_length(req->input_buffer) > 0 && req->chunk_cb != NULL) { + req->flags |= EVHTTP_REQ_DEFER_FREE; + (*req->chunk_cb)(req, req->cb_arg); + req->flags &= ~EVHTTP_REQ_DEFER_FREE; + evbuffer_drain(req->input_buffer, + evbuffer_get_length(req->input_buffer)); + if ((req->flags & EVHTTP_REQ_NEEDS_FREE) != 0) { + evhttp_request_free(req); + return; + } + } + + if (req->ntoread == 0) { + bufferevent_disable(evcon->bufev, EV_READ); + /* Completed content length */ + evhttp_connection_done(evcon); + return; + } + + /* Read more! */ + bufferevent_enable(evcon->bufev, EV_READ); +} + +#define get_deferred_queue(evcon) \ + ((evcon)->base) + +/* + * Gets called when more data becomes available + */ + +static void +evhttp_read_cb(struct bufferevent *bufev, void *arg) +{ + struct evhttp_connection *evcon = arg; + struct evhttp_request *req = TAILQ_FIRST(&evcon->requests); + + /* Cancel if it's pending. */ + event_deferred_cb_cancel_(get_deferred_queue(evcon), + &evcon->read_more_deferred_cb); + + switch (evcon->state) { + case EVCON_READING_FIRSTLINE: + evhttp_read_firstline(evcon, req); + /* note the request may have been freed in + * evhttp_read_body */ + break; + case EVCON_READING_HEADERS: + evhttp_read_header(evcon, req); + /* note the request may have been freed in + * evhttp_read_body */ + break; + case EVCON_READING_BODY: + evhttp_read_body(evcon, req); + /* note the request may have been freed in + * evhttp_read_body */ + break; + case EVCON_READING_TRAILER: + evhttp_read_trailer(evcon, req); + break; + case EVCON_IDLE: + { +#ifdef USE_DEBUG + struct evbuffer *input; + size_t total_len; + + input = bufferevent_get_input(evcon->bufev); + total_len = evbuffer_get_length(input); + event_debug(("%s: read "EV_SIZE_FMT + " bytes in EVCON_IDLE state," + " resetting connection", + __func__, EV_SIZE_ARG(total_len))); +#endif + + evhttp_connection_reset_(evcon); + } + break; + case EVCON_DISCONNECTED: + case EVCON_CONNECTING: + case EVCON_WRITING: + default: + event_errx(1, "%s: illegal connection state %d", + __func__, evcon->state); + } +} + +static void +evhttp_deferred_read_cb(struct event_callback *cb, void *data) +{ + struct evhttp_connection *evcon = data; + evhttp_read_cb(evcon->bufev, evcon); +} + +static void +evhttp_write_connectioncb(struct evhttp_connection *evcon, void *arg) +{ + /* This is after writing the request to the server */ + struct evhttp_request *req = TAILQ_FIRST(&evcon->requests); + EVUTIL_ASSERT(req != NULL); + + EVUTIL_ASSERT(evcon->state == EVCON_WRITING); + + /* We are done writing our header and are now expecting the response */ + req->kind = EVHTTP_RESPONSE; + + evhttp_start_read_(evcon); +} + +/* + * Clean up a connection object + */ + +void +evhttp_connection_free(struct evhttp_connection *evcon) +{ + struct evhttp_request *req; + + /* notify interested parties that this connection is going down */ + if (evcon->fd != -1) { + if (evhttp_connected(evcon) && evcon->closecb != NULL) + (*evcon->closecb)(evcon, evcon->closecb_arg); + } + + /* remove all requests that might be queued on this + * connection. for server connections, this should be empty. + * because it gets dequeued either in evhttp_connection_done or + * evhttp_connection_fail_. + */ + while ((req = TAILQ_FIRST(&evcon->requests)) != NULL) { + TAILQ_REMOVE(&evcon->requests, req, next); + evhttp_request_free(req); + } + + if (evcon->http_server != NULL) { + struct evhttp *http = evcon->http_server; + TAILQ_REMOVE(&http->connections, evcon, next); + } + + if (event_initialized(&evcon->retry_ev)) { + event_del(&evcon->retry_ev); + event_debug_unassign(&evcon->retry_ev); + } + + if (evcon->bufev != NULL) + bufferevent_free(evcon->bufev); + + event_deferred_cb_cancel_(get_deferred_queue(evcon), + &evcon->read_more_deferred_cb); + + if (evcon->fd != -1) { + shutdown(evcon->fd, EVUTIL_SHUT_WR); + if (!(bufferevent_get_options_(evcon->bufev) & BEV_OPT_CLOSE_ON_FREE)) { + evutil_closesocket(evcon->fd); + } + } + + if (evcon->bind_address != NULL) + mm_free(evcon->bind_address); + + if (evcon->address != NULL) + mm_free(evcon->address); + + if (evcon->conn_address != NULL) + mm_free(evcon->conn_address); + + mm_free(evcon); +} + +void +evhttp_connection_free_on_completion(struct evhttp_connection *evcon) { + evcon->flags |= EVHTTP_CON_AUTOFREE; +} + +void +evhttp_connection_set_local_address(struct evhttp_connection *evcon, + const char *address) +{ + EVUTIL_ASSERT(evcon->state == EVCON_DISCONNECTED); + if (evcon->bind_address) + mm_free(evcon->bind_address); + if ((evcon->bind_address = mm_strdup(address)) == NULL) + event_warn("%s: strdup", __func__); +} + +void +evhttp_connection_set_local_port(struct evhttp_connection *evcon, + ev_uint16_t port) +{ + EVUTIL_ASSERT(evcon->state == EVCON_DISCONNECTED); + evcon->bind_port = port; +} + +static void +evhttp_request_dispatch(struct evhttp_connection* evcon) +{ + struct evhttp_request *req = TAILQ_FIRST(&evcon->requests); + + /* this should not usually happy but it's possible */ + if (req == NULL) + return; + + /* delete possible close detection events */ + evhttp_connection_stop_detectclose(evcon); + + /* we assume that the connection is connected already */ + EVUTIL_ASSERT(evcon->state == EVCON_IDLE); + + evcon->state = EVCON_WRITING; + + /* Create the header from the store arguments */ + evhttp_make_header(evcon, req); + + evhttp_write_buffer(evcon, evhttp_write_connectioncb, NULL); +} + +/* Reset our connection state: disables reading/writing, closes our fd (if +* any), clears out buffers, and puts us in state DISCONNECTED. */ +void +evhttp_connection_reset_(struct evhttp_connection *evcon) +{ + struct evbuffer *tmp; + + /* XXXX This is not actually an optimal fix. Instead we ought to have + an API for "stop connecting", or use bufferevent_setfd to turn off + connecting. But for Libevent 2.0, this seems like a minimal change + least likely to disrupt the rest of the bufferevent and http code. + + Why is this here? If the fd is set in the bufferevent, and the + bufferevent is connecting, then you can't actually stop the + bufferevent from trying to connect with bufferevent_disable(). The + connect will never trigger, since we close the fd, but the timeout + might. That caused an assertion failure in evhttp_connection_fail_. + */ + bufferevent_disable_hard_(evcon->bufev, EV_READ|EV_WRITE); + + if (evcon->fd != -1) { + /* inform interested parties about connection close */ + if (evhttp_connected(evcon) && evcon->closecb != NULL) + (*evcon->closecb)(evcon, evcon->closecb_arg); + + shutdown(evcon->fd, EVUTIL_SHUT_WR); + evutil_closesocket(evcon->fd); + bufferevent_setfd(evcon->bufev, -1); + evcon->fd = -1; + } + + /* we need to clean up any buffered data */ + tmp = bufferevent_get_output(evcon->bufev); + evbuffer_drain(tmp, evbuffer_get_length(tmp)); + tmp = bufferevent_get_input(evcon->bufev); + evbuffer_drain(tmp, evbuffer_get_length(tmp)); + + evcon->state = EVCON_DISCONNECTED; +} + +static void +evhttp_connection_start_detectclose(struct evhttp_connection *evcon) +{ + evcon->flags |= EVHTTP_CON_CLOSEDETECT; + + bufferevent_enable(evcon->bufev, EV_READ); +} + +static void +evhttp_connection_stop_detectclose(struct evhttp_connection *evcon) +{ + evcon->flags &= ~EVHTTP_CON_CLOSEDETECT; + + bufferevent_disable(evcon->bufev, EV_READ); +} + +static void +evhttp_connection_retry(evutil_socket_t fd, short what, void *arg) +{ + struct evhttp_connection *evcon = arg; + + evcon->state = EVCON_DISCONNECTED; + evhttp_connection_connect_(evcon); +} + +static void +evhttp_connection_cb_cleanup(struct evhttp_connection *evcon) +{ + struct evcon_requestq requests; + + evhttp_connection_reset_(evcon); + if (evcon->retry_max < 0 || evcon->retry_cnt < evcon->retry_max) { + struct timeval tv_retry = evcon->initial_retry_timeout; + int i; + evtimer_assign(&evcon->retry_ev, evcon->base, evhttp_connection_retry, evcon); + /* XXXX handle failure from evhttp_add_event */ + for (i=0; i < evcon->retry_cnt; ++i) { + tv_retry.tv_usec *= 2; + if (tv_retry.tv_usec > 1000000) { + tv_retry.tv_usec -= 1000000; + tv_retry.tv_sec += 1; + } + tv_retry.tv_sec *= 2; + if (tv_retry.tv_sec > 3600) { + tv_retry.tv_sec = 3600; + tv_retry.tv_usec = 0; + } + } + event_add(&evcon->retry_ev, &tv_retry); + evcon->retry_cnt++; + return; + } + + /* + * User callback can do evhttp_make_request() on the same + * evcon so new request will be added to evcon->requests. To + * avoid freeing it prematurely we iterate over the copy of + * the queue. + */ + TAILQ_INIT(&requests); + while (TAILQ_FIRST(&evcon->requests) != NULL) { + struct evhttp_request *request = TAILQ_FIRST(&evcon->requests); + TAILQ_REMOVE(&evcon->requests, request, next); + TAILQ_INSERT_TAIL(&requests, request, next); + } + + /* for now, we just signal all requests by executing their callbacks */ + while (TAILQ_FIRST(&requests) != NULL) { + struct evhttp_request *request = TAILQ_FIRST(&requests); + TAILQ_REMOVE(&requests, request, next); + request->evcon = NULL; + + /* we might want to set an error here */ + request->cb(request, request->cb_arg); + evhttp_request_free(request); + } +} + +static void +evhttp_error_cb(struct bufferevent *bufev, short what, void *arg) +{ + struct evhttp_connection *evcon = arg; + struct evhttp_request *req = TAILQ_FIRST(&evcon->requests); + + if (evcon->fd == -1) + evcon->fd = bufferevent_getfd(bufev); + + switch (evcon->state) { + case EVCON_CONNECTING: + if (what & BEV_EVENT_TIMEOUT) { + event_debug(("%s: connection timeout for \"%s:%d\" on " + EV_SOCK_FMT, + __func__, evcon->address, evcon->port, + EV_SOCK_ARG(evcon->fd))); + evhttp_connection_cb_cleanup(evcon); + return; + } + break; + + case EVCON_READING_BODY: + if (!req->chunked && req->ntoread < 0 + && what == (BEV_EVENT_READING|BEV_EVENT_EOF)) { + /* EOF on read can be benign */ + evhttp_connection_done(evcon); + return; + } + break; + + case EVCON_DISCONNECTED: + case EVCON_IDLE: + case EVCON_READING_FIRSTLINE: + case EVCON_READING_HEADERS: + case EVCON_READING_TRAILER: + case EVCON_WRITING: + default: + break; + } + + /* when we are in close detect mode, a read error means that + * the other side closed their connection. + */ + if (evcon->flags & EVHTTP_CON_CLOSEDETECT) { + evcon->flags &= ~EVHTTP_CON_CLOSEDETECT; + EVUTIL_ASSERT(evcon->http_server == NULL); + /* For connections from the client, we just + * reset the connection so that it becomes + * disconnected. + */ + EVUTIL_ASSERT(evcon->state == EVCON_IDLE); + evhttp_connection_reset_(evcon); + + /* + * If we have no more requests that need completion + * and we want to auto-free the connection when all + * requests have been completed. + */ + if (TAILQ_FIRST(&evcon->requests) == NULL + && (evcon->flags & EVHTTP_CON_OUTGOING) + && (evcon->flags & EVHTTP_CON_AUTOFREE)) { + evhttp_connection_free(evcon); + } + return; + } + + if (what & BEV_EVENT_TIMEOUT) { + evhttp_connection_fail_(evcon, EVREQ_HTTP_TIMEOUT); + } else if (what & (BEV_EVENT_EOF|BEV_EVENT_ERROR)) { + evhttp_connection_fail_(evcon, EVREQ_HTTP_EOF); + } else if (what == BEV_EVENT_CONNECTED) { + } else { + evhttp_connection_fail_(evcon, EVREQ_HTTP_BUFFER_ERROR); + } +} + +/* + * Event callback for asynchronous connection attempt. + */ +static void +evhttp_connection_cb(struct bufferevent *bufev, short what, void *arg) +{ + struct evhttp_connection *evcon = arg; + int error; + ev_socklen_t errsz = sizeof(error); + socklen_t conn_address_len = sizeof(*evcon->conn_address); + + if (evcon->fd == -1) + evcon->fd = bufferevent_getfd(bufev); + + if (!(what & BEV_EVENT_CONNECTED)) { + /* some operating systems return ECONNREFUSED immediately + * when connecting to a local address. the cleanup is going + * to reschedule this function call. + */ +#ifndef _WIN32 + if (errno == ECONNREFUSED) + goto cleanup; +#endif + evhttp_error_cb(bufev, what, arg); + return; + } + + if (evcon->fd == -1) { + event_debug(("%s: bufferevent_getfd returned -1", + __func__)); + goto cleanup; + } + + /* Check if the connection completed */ + if (getsockopt(evcon->fd, SOL_SOCKET, SO_ERROR, (void*)&error, + &errsz) == -1) { + event_debug(("%s: getsockopt for \"%s:%d\" on "EV_SOCK_FMT, + __func__, evcon->address, evcon->port, + EV_SOCK_ARG(evcon->fd))); + goto cleanup; + } + + if (error) { + event_debug(("%s: connect failed for \"%s:%d\" on " + EV_SOCK_FMT": %s", + __func__, evcon->address, evcon->port, + EV_SOCK_ARG(evcon->fd), + evutil_socket_error_to_string(error))); + goto cleanup; + } + + /* We are connected to the server now */ + event_debug(("%s: connected to \"%s:%d\" on "EV_SOCK_FMT"\n", + __func__, evcon->address, evcon->port, + EV_SOCK_ARG(evcon->fd))); + + /* Reset the retry count as we were successful in connecting */ + evcon->retry_cnt = 0; + evcon->state = EVCON_IDLE; + + if (!evcon->conn_address) { + evcon->conn_address = mm_malloc(sizeof(*evcon->conn_address)); + } + if (getpeername(evcon->fd, (struct sockaddr *)evcon->conn_address, &conn_address_len)) { + mm_free(evcon->conn_address); + evcon->conn_address = NULL; + } + + /* reset the bufferevent cbs */ + bufferevent_setcb(evcon->bufev, + evhttp_read_cb, + evhttp_write_cb, + evhttp_error_cb, + evcon); + + if (!evutil_timerisset(&evcon->timeout)) { + const struct timeval read_tv = { HTTP_READ_TIMEOUT, 0 }; + const struct timeval write_tv = { HTTP_WRITE_TIMEOUT, 0 }; + bufferevent_set_timeouts(evcon->bufev, &read_tv, &write_tv); + } else { + bufferevent_set_timeouts(evcon->bufev, &evcon->timeout, &evcon->timeout); + } + + /* try to start requests that have queued up on this connection */ + evhttp_request_dispatch(evcon); + return; + + cleanup: + evhttp_connection_cb_cleanup(evcon); +} + +/* + * Check if we got a valid response code. + */ + +static int +evhttp_valid_response_code(int code) +{ + if (code == 0) + return (0); + + return (1); +} + +static int +evhttp_parse_http_version(const char *version, struct evhttp_request *req) +{ + int major, minor; + char ch; + int n = sscanf(version, "HTTP/%d.%d%c", &major, &minor, &ch); + if (n != 2 || major > 1) { + event_debug(("%s: bad version %s on message %p from %s", + __func__, version, req, req->remote_host)); + return (-1); + } + req->major = major; + req->minor = minor; + return (0); +} + +/* Parses the status line of a web server */ + +static int +evhttp_parse_response_line(struct evhttp_request *req, char *line) +{ + char *protocol; + char *number; + const char *readable = ""; + + protocol = strsep(&line, " "); + if (line == NULL) + return (-1); + number = strsep(&line, " "); + if (line != NULL) + readable = line; + + if (evhttp_parse_http_version(protocol, req) < 0) + return (-1); + + req->response_code = atoi(number); + if (!evhttp_valid_response_code(req->response_code)) { + event_debug(("%s: bad response code \"%s\"", + __func__, number)); + return (-1); + } + + if ((req->response_code_line = mm_strdup(readable)) == NULL) { + event_warn("%s: strdup", __func__); + return (-1); + } + + return (0); +} + +/* Parse the first line of a HTTP request */ + +static int +evhttp_parse_request_line(struct evhttp_request *req, char *line) +{ + char *method; + char *uri; + char *version; + const char *hostname; + const char *scheme; + size_t method_len; + enum evhttp_cmd_type type; + + /* Parse the request line */ + method = strsep(&line, " "); + if (line == NULL) + return (-1); + uri = strsep(&line, " "); + if (line == NULL) + return (-1); + version = strsep(&line, " "); + if (line != NULL) + return (-1); + + method_len = (uri - method) - 1; + type = EVHTTP_REQ_UNKNOWN_; + + /* First line */ + switch (method_len) { + case 3: + /* The length of the method string is 3, meaning it can only be one of two methods: GET or PUT */ + + /* Since both GET and PUT share the same character 'T' at the end, + * if the string doesn't have 'T', we can immediately determine this + * is an invalid HTTP method */ + + if (method[2] != 'T') { + break; + } + + switch (*method) { + case 'G': + /* This first byte is 'G', so make sure the next byte is + * 'E', if it isn't then this isn't a valid method */ + + if (method[1] == 'E') { + type = EVHTTP_REQ_GET; + } + + break; + case 'P': + /* First byte is P, check second byte for 'U', if not, + * we know it's an invalid method */ + if (method[1] == 'U') { + type = EVHTTP_REQ_PUT; + } + break; + default: + break; + } + break; + case 4: + /* The method length is 4 bytes, leaving only the methods "POST" and "HEAD" */ + switch (*method) { + case 'P': + if (method[3] == 'T' && method[2] == 'S' && method[1] == 'O') { + type = EVHTTP_REQ_POST; + } + break; + case 'H': + if (method[3] == 'D' && method[2] == 'A' && method[1] == 'E') { + type = EVHTTP_REQ_HEAD; + } + break; + default: + break; + } + break; + case 5: + /* Method length is 5 bytes, which can only encompass PATCH and TRACE */ + switch (*method) { + case 'P': + if (method[4] == 'H' && method[3] == 'C' && method[2] == 'T' && method[1] == 'A') { + type = EVHTTP_REQ_PATCH; + } + break; + case 'T': + if (method[4] == 'E' && method[3] == 'C' && method[2] == 'A' && method[1] == 'R') { + type = EVHTTP_REQ_TRACE; + } + + break; + default: + break; + } + break; + case 6: + /* Method length is 6, only valid method 6 bytes in length is DELEte */ + + /* If the first byte isn't 'D' then it's invalid */ + if (*method != 'D') { + break; + } + + if (method[5] == 'E' && method[4] == 'T' && method[3] == 'E' && method[2] == 'L' && method[1] == 'E') { + type = EVHTTP_REQ_DELETE; + } + + break; + case 7: + /* Method length is 7, only valid methods are "OPTIONS" and "CONNECT" */ + switch (*method) { + case 'O': + if (method[6] == 'S' && method[5] == 'N' && method[4] == 'O' && + method[3] == 'I' && method[2] == 'T' && method[1] == 'P') { + type = EVHTTP_REQ_OPTIONS; + } + + break; + case 'C': + if (method[6] == 'T' && method[5] == 'C' && method[4] == 'E' && + method[3] == 'N' && method[2] == 'N' && method[1] == 'O') { + type = EVHTTP_REQ_CONNECT; + } + + break; + default: + break; + } + break; + } /* switch */ + + if ((int)type == EVHTTP_REQ_UNKNOWN_) { + event_debug(("%s: bad method %s on request %p from %s", + __func__, method, req, req->remote_host)); + /* No error yet; we'll give a better error later when + * we see that req->type is unsupported. */ + } + + req->type = type; + + if (evhttp_parse_http_version(version, req) < 0) + return (-1); + + if ((req->uri = mm_strdup(uri)) == NULL) { + event_debug(("%s: mm_strdup", __func__)); + return (-1); + } + + if ((req->uri_elems = evhttp_uri_parse_with_flags(req->uri, + EVHTTP_URI_NONCONFORMANT)) == NULL) { + return -1; + } + + /* If we have an absolute-URI, check to see if it is an http request + for a known vhost or server alias. If we don't know about this + host, we consider it a proxy request. */ + scheme = evhttp_uri_get_scheme(req->uri_elems); + hostname = evhttp_uri_get_host(req->uri_elems); + if (scheme && (!evutil_ascii_strcasecmp(scheme, "http") || + !evutil_ascii_strcasecmp(scheme, "https")) && + hostname && + !evhttp_find_vhost(req->evcon->http_server, NULL, hostname)) + req->flags |= EVHTTP_PROXY_REQUEST; + + return (0); +} + +const char * +evhttp_find_header(const struct evkeyvalq *headers, const char *key) +{ + struct evkeyval *header; + + TAILQ_FOREACH(header, headers, next) { + if (evutil_ascii_strcasecmp(header->key, key) == 0) + return (header->value); + } + + return (NULL); +} + +void +evhttp_clear_headers(struct evkeyvalq *headers) +{ + struct evkeyval *header; + + for (header = TAILQ_FIRST(headers); + header != NULL; + header = TAILQ_FIRST(headers)) { + TAILQ_REMOVE(headers, header, next); + mm_free(header->key); + mm_free(header->value); + mm_free(header); + } +} + +/* + * Returns 0, if the header was successfully removed. + * Returns -1, if the header could not be found. + */ + +int +evhttp_remove_header(struct evkeyvalq *headers, const char *key) +{ + struct evkeyval *header; + + TAILQ_FOREACH(header, headers, next) { + if (evutil_ascii_strcasecmp(header->key, key) == 0) + break; + } + + if (header == NULL) + return (-1); + + /* Free and remove the header that we found */ + TAILQ_REMOVE(headers, header, next); + mm_free(header->key); + mm_free(header->value); + mm_free(header); + + return (0); +} + +static int +evhttp_header_is_valid_value(const char *value) +{ + const char *p = value; + + while ((p = strpbrk(p, "\r\n")) != NULL) { + /* we really expect only one new line */ + p += strspn(p, "\r\n"); + /* we expect a space or tab for continuation */ + if (*p != ' ' && *p != '\t') + return (0); + } + return (1); +} + +int +evhttp_add_header(struct evkeyvalq *headers, + const char *key, const char *value) +{ + event_debug(("%s: key: %s val: %s\n", __func__, key, value)); + + if (strchr(key, '\r') != NULL || strchr(key, '\n') != NULL) { + /* drop illegal headers */ + event_debug(("%s: dropping illegal header key\n", __func__)); + return (-1); + } + + if (!evhttp_header_is_valid_value(value)) { + event_debug(("%s: dropping illegal header value\n", __func__)); + return (-1); + } + + return (evhttp_add_header_internal(headers, key, value)); +} + +static int +evhttp_add_header_internal(struct evkeyvalq *headers, + const char *key, const char *value) +{ + struct evkeyval *header = mm_calloc(1, sizeof(struct evkeyval)); + if (header == NULL) { + event_warn("%s: calloc", __func__); + return (-1); + } + if ((header->key = mm_strdup(key)) == NULL) { + mm_free(header); + event_warn("%s: strdup", __func__); + return (-1); + } + if ((header->value = mm_strdup(value)) == NULL) { + mm_free(header->key); + mm_free(header); + event_warn("%s: strdup", __func__); + return (-1); + } + + TAILQ_INSERT_TAIL(headers, header, next); + + return (0); +} + +/* + * Parses header lines from a request or a response into the specified + * request object given an event buffer. + * + * Returns + * DATA_CORRUPTED on error + * MORE_DATA_EXPECTED when we need to read more headers + * ALL_DATA_READ when all headers have been read. + */ + +enum message_read_status +evhttp_parse_firstline_(struct evhttp_request *req, struct evbuffer *buffer) +{ + char *line; + enum message_read_status status = ALL_DATA_READ; + + size_t line_length; + /* XXX try */ + line = evbuffer_readln(buffer, &line_length, EVBUFFER_EOL_CRLF); + if (line == NULL) { + if (req->evcon != NULL && + evbuffer_get_length(buffer) > req->evcon->max_headers_size) + return (DATA_TOO_LONG); + else + return (MORE_DATA_EXPECTED); + } + + if (req->evcon != NULL && + line_length > req->evcon->max_headers_size) { + mm_free(line); + return (DATA_TOO_LONG); + } + + req->headers_size = line_length; + + switch (req->kind) { + case EVHTTP_REQUEST: + if (evhttp_parse_request_line(req, line) == -1) + status = DATA_CORRUPTED; + break; + case EVHTTP_RESPONSE: + if (evhttp_parse_response_line(req, line) == -1) + status = DATA_CORRUPTED; + break; + default: + status = DATA_CORRUPTED; + } + + mm_free(line); + return (status); +} + +static int +evhttp_append_to_last_header(struct evkeyvalq *headers, char *line) +{ + struct evkeyval *header = TAILQ_LAST(headers, evkeyvalq); + char *newval; + size_t old_len, line_len; + + if (header == NULL) + return (-1); + + old_len = strlen(header->value); + + /* Strip space from start and end of line. */ + while (*line == ' ' || *line == '\t') + ++line; + evutil_rtrim_lws_(line); + + line_len = strlen(line); + + newval = mm_realloc(header->value, old_len + line_len + 2); + if (newval == NULL) + return (-1); + + newval[old_len] = ' '; + memcpy(newval + old_len + 1, line, line_len + 1); + header->value = newval; + + return (0); +} + +enum message_read_status +evhttp_parse_headers_(struct evhttp_request *req, struct evbuffer* buffer) +{ + enum message_read_status errcode = DATA_CORRUPTED; + char *line; + enum message_read_status status = MORE_DATA_EXPECTED; + + struct evkeyvalq* headers = req->input_headers; + size_t line_length; + while ((line = evbuffer_readln(buffer, &line_length, EVBUFFER_EOL_CRLF)) + != NULL) { + char *skey, *svalue; + + req->headers_size += line_length; + + if (req->evcon != NULL && + req->headers_size > req->evcon->max_headers_size) { + errcode = DATA_TOO_LONG; + goto error; + } + + if (*line == '\0') { /* Last header - Done */ + status = ALL_DATA_READ; + mm_free(line); + break; + } + + /* Check if this is a continuation line */ + if (*line == ' ' || *line == '\t') { + if (evhttp_append_to_last_header(headers, line) == -1) + goto error; + mm_free(line); + continue; + } + + /* Processing of header lines */ + svalue = line; + skey = strsep(&svalue, ":"); + if (svalue == NULL) + goto error; + + svalue += strspn(svalue, " "); + evutil_rtrim_lws_(svalue); + + if (evhttp_add_header(headers, skey, svalue) == -1) + goto error; + + mm_free(line); + } + + if (status == MORE_DATA_EXPECTED) { + if (req->evcon != NULL && + req->headers_size + evbuffer_get_length(buffer) > req->evcon->max_headers_size) + return (DATA_TOO_LONG); + } + + return (status); + + error: + mm_free(line); + return (errcode); +} + +static int +evhttp_get_body_length(struct evhttp_request *req) +{ + struct evkeyvalq *headers = req->input_headers; + const char *content_length; + const char *connection; + + content_length = evhttp_find_header(headers, "Content-Length"); + connection = evhttp_find_header(headers, "Connection"); + + if (content_length == NULL && connection == NULL) + req->ntoread = -1; + else if (content_length == NULL && + evutil_ascii_strcasecmp(connection, "Close") != 0) { + /* Bad combination, we don't know when it will end */ + event_warnx("%s: we got no content length, but the " + "server wants to keep the connection open: %s.", + __func__, connection); + return (-1); + } else if (content_length == NULL) { + req->ntoread = -1; + } else { + char *endp; + ev_int64_t ntoread = evutil_strtoll(content_length, &endp, 10); + if (*content_length == '\0' || *endp != '\0' || ntoread < 0) { + event_debug(("%s: illegal content length: %s", + __func__, content_length)); + return (-1); + } + req->ntoread = ntoread; + } + + event_debug(("%s: bytes to read: "EV_I64_FMT" (in buffer "EV_SIZE_FMT")\n", + __func__, EV_I64_ARG(req->ntoread), + EV_SIZE_ARG(evbuffer_get_length(bufferevent_get_input(req->evcon->bufev))))); + + return (0); +} + +static int +evhttp_method_may_have_body(enum evhttp_cmd_type type) +{ + switch (type) { + case EVHTTP_REQ_POST: + case EVHTTP_REQ_PUT: + case EVHTTP_REQ_PATCH: + return 1; + case EVHTTP_REQ_TRACE: + return 0; + /* XXX May any of the below methods have a body? */ + case EVHTTP_REQ_GET: + case EVHTTP_REQ_HEAD: + case EVHTTP_REQ_DELETE: + case EVHTTP_REQ_OPTIONS: + case EVHTTP_REQ_CONNECT: + return 0; + default: + return 0; + } +} + +static void +evhttp_get_body(struct evhttp_connection *evcon, struct evhttp_request *req) +{ + const char *xfer_enc; + + /* If this is a request without a body, then we are done */ + if (req->kind == EVHTTP_REQUEST && + !evhttp_method_may_have_body(req->type)) { + evhttp_connection_done(evcon); + return; + } + evcon->state = EVCON_READING_BODY; + xfer_enc = evhttp_find_header(req->input_headers, "Transfer-Encoding"); + if (xfer_enc != NULL && evutil_ascii_strcasecmp(xfer_enc, "chunked") == 0) { + req->chunked = 1; + req->ntoread = -1; + } else { + if (evhttp_get_body_length(req) == -1) { + evhttp_connection_fail_(evcon, + EVREQ_HTTP_INVALID_HEADER); + return; + } + if (req->kind == EVHTTP_REQUEST && req->ntoread < 1) { + /* An incoming request with no content-length and no + * transfer-encoding has no body. */ + evhttp_connection_done(evcon); + return; + } + } + + /* Should we send a 100 Continue status line? */ + if (req->kind == EVHTTP_REQUEST && REQ_VERSION_ATLEAST(req, 1, 1)) { + const char *expect; + + expect = evhttp_find_header(req->input_headers, "Expect"); + if (expect) { + if (!evutil_ascii_strcasecmp(expect, "100-continue")) { + /* XXX It would be nice to do some sanity + checking here. Does the resource exist? + Should the resource accept post requests? If + no, we should respond with an error. For + now, just optimistically tell the client to + send their message body. */ + if (req->ntoread > 0) { + /* ntoread is ev_int64_t, max_body_size is ev_uint64_t */ + if ((req->evcon->max_body_size <= EV_INT64_MAX) && (ev_uint64_t)req->ntoread > req->evcon->max_body_size) { + evhttp_send_error(req, HTTP_ENTITYTOOLARGE, NULL); + return; + } + } + if (!evbuffer_get_length(bufferevent_get_input(evcon->bufev))) + evhttp_send_continue(evcon, req); + } else { + evhttp_send_error(req, HTTP_EXPECTATIONFAILED, + NULL); + return; + } + } + } + + evhttp_read_body(evcon, req); + /* note the request may have been freed in evhttp_read_body */ +} + +static void +evhttp_read_firstline(struct evhttp_connection *evcon, + struct evhttp_request *req) +{ + enum message_read_status res; + + res = evhttp_parse_firstline_(req, bufferevent_get_input(evcon->bufev)); + if (res == DATA_CORRUPTED || res == DATA_TOO_LONG) { + /* Error while reading, terminate */ + event_debug(("%s: bad header lines on "EV_SOCK_FMT"\n", + __func__, EV_SOCK_ARG(evcon->fd))); + evhttp_connection_fail_(evcon, EVREQ_HTTP_INVALID_HEADER); + return; + } else if (res == MORE_DATA_EXPECTED) { + /* Need more header lines */ + return; + } + + evcon->state = EVCON_READING_HEADERS; + evhttp_read_header(evcon, req); +} + +static void +evhttp_read_header(struct evhttp_connection *evcon, + struct evhttp_request *req) +{ + enum message_read_status res; + evutil_socket_t fd = evcon->fd; + + res = evhttp_parse_headers_(req, bufferevent_get_input(evcon->bufev)); + if (res == DATA_CORRUPTED || res == DATA_TOO_LONG) { + /* Error while reading, terminate */ + event_debug(("%s: bad header lines on "EV_SOCK_FMT"\n", + __func__, EV_SOCK_ARG(fd))); + evhttp_connection_fail_(evcon, EVREQ_HTTP_INVALID_HEADER); + return; + } else if (res == MORE_DATA_EXPECTED) { + /* Need more header lines */ + return; + } + + /* Disable reading for now */ + bufferevent_disable(evcon->bufev, EV_READ); + + /* Callback can shut down connection with negative return value */ + if (req->header_cb != NULL) { + if ((*req->header_cb)(req, req->cb_arg) < 0) { + evhttp_connection_fail_(evcon, EVREQ_HTTP_EOF); + return; + } + } + + /* Done reading headers, do the real work */ + switch (req->kind) { + case EVHTTP_REQUEST: + event_debug(("%s: checking for post data on "EV_SOCK_FMT"\n", + __func__, EV_SOCK_ARG(fd))); + evhttp_get_body(evcon, req); + /* note the request may have been freed in evhttp_get_body */ + break; + + case EVHTTP_RESPONSE: + /* Start over if we got a 100 Continue response. */ + if (req->response_code == 100) { + evhttp_start_read_(evcon); + return; + } + if (!evhttp_response_needs_body(req)) { + event_debug(("%s: skipping body for code %d\n", + __func__, req->response_code)); + evhttp_connection_done(evcon); + } else { + event_debug(("%s: start of read body for %s on " + EV_SOCK_FMT"\n", + __func__, req->remote_host, EV_SOCK_ARG(fd))); + evhttp_get_body(evcon, req); + /* note the request may have been freed in + * evhttp_get_body */ + } + break; + + default: + event_warnx("%s: bad header on "EV_SOCK_FMT, __func__, + EV_SOCK_ARG(fd)); + evhttp_connection_fail_(evcon, EVREQ_HTTP_INVALID_HEADER); + break; + } + /* request may have been freed above */ +} + +/* + * Creates a TCP connection to the specified port and executes a callback + * when finished. Failure or success is indicate by the passed connection + * object. + * + * Although this interface accepts a hostname, it is intended to take + * only numeric hostnames so that non-blocking DNS resolution can + * happen elsewhere. + */ + +struct evhttp_connection * +evhttp_connection_new(const char *address, unsigned short port) +{ + return (evhttp_connection_base_new(NULL, NULL, address, port)); +} + +struct evhttp_connection * +evhttp_connection_base_bufferevent_new(struct event_base *base, struct evdns_base *dnsbase, struct bufferevent* bev, + const char *address, unsigned short port) +{ + struct evhttp_connection *evcon = NULL; + + event_debug(("Attempting connection to %s:%d\n", address, port)); + + if ((evcon = mm_calloc(1, sizeof(struct evhttp_connection))) == NULL) { + event_warn("%s: calloc failed", __func__); + goto error; + } + + evcon->fd = -1; + evcon->port = port; + + evcon->max_headers_size = EV_SIZE_MAX; + evcon->max_body_size = EV_SIZE_MAX; + + evutil_timerclear(&evcon->timeout); + evcon->retry_cnt = evcon->retry_max = 0; + + if ((evcon->address = mm_strdup(address)) == NULL) { + event_warn("%s: strdup failed", __func__); + goto error; + } + + if (bev == NULL) { + if (!(bev = bufferevent_socket_new(base, -1, 0))) { + event_warn("%s: bufferevent_socket_new failed", __func__); + goto error; + } + } + + bufferevent_setcb(bev, evhttp_read_cb, evhttp_write_cb, evhttp_error_cb, evcon); + evcon->bufev = bev; + + evcon->state = EVCON_DISCONNECTED; + TAILQ_INIT(&evcon->requests); + + evcon->initial_retry_timeout.tv_sec = 2; + evcon->initial_retry_timeout.tv_usec = 0; + + if (base != NULL) { + evcon->base = base; + if (bufferevent_get_base(bev) != base) + bufferevent_base_set(base, evcon->bufev); + } + + event_deferred_cb_init_( + &evcon->read_more_deferred_cb, + bufferevent_get_priority(bev), + evhttp_deferred_read_cb, evcon); + + evcon->dns_base = dnsbase; + evcon->ai_family = AF_UNSPEC; + + return (evcon); + + error: + if (evcon != NULL) + evhttp_connection_free(evcon); + return (NULL); +} + +struct bufferevent* evhttp_connection_get_bufferevent(struct evhttp_connection *evcon) +{ + return evcon->bufev; +} + +struct evhttp * +evhttp_connection_get_server(struct evhttp_connection *evcon) +{ + return evcon->http_server; +} + +struct evhttp_connection * +evhttp_connection_base_new(struct event_base *base, struct evdns_base *dnsbase, + const char *address, unsigned short port) +{ + return evhttp_connection_base_bufferevent_new(base, dnsbase, NULL, address, port); +} + +void evhttp_connection_set_family(struct evhttp_connection *evcon, + int family) +{ + evcon->ai_family = family; +} + +void +evhttp_connection_set_base(struct evhttp_connection *evcon, + struct event_base *base) +{ + EVUTIL_ASSERT(evcon->base == NULL); + EVUTIL_ASSERT(evcon->state == EVCON_DISCONNECTED); + evcon->base = base; + bufferevent_base_set(base, evcon->bufev); +} + +void +evhttp_connection_set_timeout(struct evhttp_connection *evcon, + int timeout_in_secs) +{ + if (timeout_in_secs == -1) + evhttp_connection_set_timeout_tv(evcon, NULL); + else { + struct timeval tv; + tv.tv_sec = timeout_in_secs; + tv.tv_usec = 0; + evhttp_connection_set_timeout_tv(evcon, &tv); + } +} + +void +evhttp_connection_set_timeout_tv(struct evhttp_connection *evcon, + const struct timeval* tv) +{ + if (tv) { + evcon->timeout = *tv; + bufferevent_set_timeouts(evcon->bufev, &evcon->timeout, &evcon->timeout); + } else { + const struct timeval read_tv = { HTTP_READ_TIMEOUT, 0 }; + const struct timeval write_tv = { HTTP_WRITE_TIMEOUT, 0 }; + evutil_timerclear(&evcon->timeout); + bufferevent_set_timeouts(evcon->bufev, &read_tv, &write_tv); + } +} + +void +evhttp_connection_set_initial_retry_tv(struct evhttp_connection *evcon, + const struct timeval *tv) +{ + if (tv) { + evcon->initial_retry_timeout = *tv; + } else { + evutil_timerclear(&evcon->initial_retry_timeout); + evcon->initial_retry_timeout.tv_sec = 2; + } +} + +void +evhttp_connection_set_retries(struct evhttp_connection *evcon, + int retry_max) +{ + evcon->retry_max = retry_max; +} + +void +evhttp_connection_set_closecb(struct evhttp_connection *evcon, + void (*cb)(struct evhttp_connection *, void *), void *cbarg) +{ + evcon->closecb = cb; + evcon->closecb_arg = cbarg; +} + +void +evhttp_connection_get_peer(struct evhttp_connection *evcon, + char **address, ev_uint16_t *port) +{ + *address = evcon->address; + *port = evcon->port; +} + +const struct sockaddr* +evhttp_connection_get_addr(struct evhttp_connection *evcon) +{ + return (struct sockaddr *)evcon->conn_address; +} + +int +evhttp_connection_connect_(struct evhttp_connection *evcon) +{ + int old_state = evcon->state; + + if (evcon->state == EVCON_CONNECTING) + return (0); + + evhttp_connection_reset_(evcon); + + EVUTIL_ASSERT(!(evcon->flags & EVHTTP_CON_INCOMING)); + evcon->flags |= EVHTTP_CON_OUTGOING; + + if (evcon->bind_address || evcon->bind_port) { + evcon->fd = bind_socket( + evcon->bind_address, evcon->bind_port, 0 /*reuse*/); + if (evcon->fd == -1) { + event_debug(("%s: failed to bind to \"%s\"", + __func__, evcon->bind_address)); + return (-1); + } + + bufferevent_setfd(evcon->bufev, evcon->fd); + } else { + bufferevent_setfd(evcon->bufev, -1); + } + + /* Set up a callback for successful connection setup */ + bufferevent_setcb(evcon->bufev, + NULL /* evhttp_read_cb */, + NULL /* evhttp_write_cb */, + evhttp_connection_cb, + evcon); + if (!evutil_timerisset(&evcon->timeout)) { + const struct timeval conn_tv = { HTTP_CONNECT_TIMEOUT, 0 }; + bufferevent_set_timeouts(evcon->bufev, NULL, &conn_tv); + } else { + bufferevent_set_timeouts(evcon->bufev, NULL, &evcon->timeout); + } + /* make sure that we get a write callback */ + bufferevent_enable(evcon->bufev, EV_WRITE); + + evcon->state = EVCON_CONNECTING; + + if (bufferevent_socket_connect_hostname(evcon->bufev, evcon->dns_base, + evcon->ai_family, evcon->address, evcon->port) < 0) { + evcon->state = old_state; + event_sock_warn(evcon->fd, "%s: connection to \"%s\" failed", + __func__, evcon->address); + /* some operating systems return ECONNREFUSED immediately + * when connecting to a local address. the cleanup is going + * to reschedule this function call. + */ + evhttp_connection_cb_cleanup(evcon); + return (0); + } + + return (0); +} + +/* + * Starts an HTTP request on the provided evhttp_connection object. + * If the connection object is not connected to the web server already, + * this will start the connection. + */ + +int +evhttp_make_request(struct evhttp_connection *evcon, + struct evhttp_request *req, + enum evhttp_cmd_type type, const char *uri) +{ + /* We are making a request */ + req->kind = EVHTTP_REQUEST; + req->type = type; + if (req->uri != NULL) + mm_free(req->uri); + if ((req->uri = mm_strdup(uri)) == NULL) { + event_warn("%s: strdup", __func__); + evhttp_request_free(req); + return (-1); + } + + /* Set the protocol version if it is not supplied */ + if (!req->major && !req->minor) { + req->major = 1; + req->minor = 1; + } + + EVUTIL_ASSERT(req->evcon == NULL); + req->evcon = evcon; + EVUTIL_ASSERT(!(req->flags & EVHTTP_REQ_OWN_CONNECTION)); + + TAILQ_INSERT_TAIL(&evcon->requests, req, next); + + /* If the connection object is not connected; make it so */ + if (!evhttp_connected(evcon)) { + int res = evhttp_connection_connect_(evcon); + /* evhttp_connection_fail_(), which is called through + * evhttp_connection_connect_(), assumes that req lies in + * evcon->requests. Thus, enqueue the request in advance and + * remove it in the error case. */ + if (res != 0) + TAILQ_REMOVE(&evcon->requests, req, next); + + return res; + } + + /* + * If it's connected already and we are the first in the queue, + * then we can dispatch this request immediately. Otherwise, it + * will be dispatched once the pending requests are completed. + */ + if (TAILQ_FIRST(&evcon->requests) == req) + evhttp_request_dispatch(evcon); + + return (0); +} + +void +evhttp_cancel_request(struct evhttp_request *req) +{ + struct evhttp_connection *evcon = req->evcon; + if (evcon != NULL) { + /* We need to remove it from the connection */ + if (TAILQ_FIRST(&evcon->requests) == req) { + /* it's currently being worked on, so reset + * the connection. + */ + evhttp_connection_fail_(evcon, + EVREQ_HTTP_REQUEST_CANCEL); + + /* connection fail freed the request */ + return; + } else { + /* otherwise, we can just remove it from the + * queue + */ + TAILQ_REMOVE(&evcon->requests, req, next); + } + } + + evhttp_request_free(req); +} + +/* + * Reads data from file descriptor into request structure + * Request structure needs to be set up correctly. + */ + +void +evhttp_start_read_(struct evhttp_connection *evcon) +{ + /* Set up an event to read the headers */ + bufferevent_disable(evcon->bufev, EV_WRITE); + bufferevent_enable(evcon->bufev, EV_READ); + evcon->state = EVCON_READING_FIRSTLINE; + /* Reset the bufferevent callbacks */ + bufferevent_setcb(evcon->bufev, + evhttp_read_cb, + evhttp_write_cb, + evhttp_error_cb, + evcon); + + /* If there's still data pending, process it next time through the + * loop. Don't do it now; that could get recusive. */ + if (evbuffer_get_length(bufferevent_get_input(evcon->bufev))) { + event_deferred_cb_schedule_(get_deferred_queue(evcon), + &evcon->read_more_deferred_cb); + } +} + +static void +evhttp_send_done(struct evhttp_connection *evcon, void *arg) +{ + int need_close; + struct evhttp_request *req = TAILQ_FIRST(&evcon->requests); + TAILQ_REMOVE(&evcon->requests, req, next); + + if (req->on_complete_cb != NULL) { + req->on_complete_cb(req, req->on_complete_cb_arg); + } + + need_close = + (REQ_VERSION_BEFORE(req, 1, 1) && + !evhttp_is_connection_keepalive(req->input_headers))|| + evhttp_is_connection_close(req->flags, req->input_headers) || + evhttp_is_connection_close(req->flags, req->output_headers); + + EVUTIL_ASSERT(req->flags & EVHTTP_REQ_OWN_CONNECTION); + evhttp_request_free(req); + + if (need_close) { + evhttp_connection_free(evcon); + return; + } + + /* we have a persistent connection; try to accept another request. */ + if (evhttp_associate_new_request_with_connection(evcon) == -1) { + evhttp_connection_free(evcon); + } +} + +/* + * Returns an error page. + */ + +void +evhttp_send_error(struct evhttp_request *req, int error, const char *reason) +{ + +#define ERR_FORMAT "\n" \ + "%d %s\n" \ + "\n" \ + "

      %s

      \n" \ + "\n" + + struct evbuffer *buf = evbuffer_new(); + if (buf == NULL) { + /* if we cannot allocate memory; we just drop the connection */ + evhttp_connection_free(req->evcon); + return; + } + if (reason == NULL) { + reason = evhttp_response_phrase_internal(error); + } + + evhttp_response_code_(req, error, reason); + + evbuffer_add_printf(buf, ERR_FORMAT, error, reason, reason); + + evhttp_send_page_(req, buf); + + evbuffer_free(buf); +#undef ERR_FORMAT +} + +/* Requires that headers and response code are already set up */ + +static inline void +evhttp_send(struct evhttp_request *req, struct evbuffer *databuf) +{ + struct evhttp_connection *evcon = req->evcon; + + if (evcon == NULL) { + evhttp_request_free(req); + return; + } + + EVUTIL_ASSERT(TAILQ_FIRST(&evcon->requests) == req); + + /* we expect no more calls form the user on this request */ + req->userdone = 1; + + /* xxx: not sure if we really should expose the data buffer this way */ + if (databuf != NULL) + evbuffer_add_buffer(req->output_buffer, databuf); + + /* Adds headers to the response */ + evhttp_make_header(evcon, req); + + evhttp_write_buffer(evcon, evhttp_send_done, NULL); +} + +void +evhttp_send_reply(struct evhttp_request *req, int code, const char *reason, + struct evbuffer *databuf) +{ + evhttp_response_code_(req, code, reason); + + evhttp_send(req, databuf); +} + +void +evhttp_send_reply_start(struct evhttp_request *req, int code, + const char *reason) +{ + evhttp_response_code_(req, code, reason); + if (evhttp_find_header(req->output_headers, "Content-Length") == NULL && + REQ_VERSION_ATLEAST(req, 1, 1) && + evhttp_response_needs_body(req)) { + /* + * prefer HTTP/1.1 chunked encoding to closing the connection; + * note RFC 2616 section 4.4 forbids it with Content-Length: + * and it's not necessary then anyway. + */ + evhttp_add_header(req->output_headers, "Transfer-Encoding", + "chunked"); + req->chunked = 1; + } else { + req->chunked = 0; + } + evhttp_make_header(req->evcon, req); + evhttp_write_buffer(req->evcon, NULL, NULL); +} + +void +evhttp_send_reply_chunk_with_cb(struct evhttp_request *req, struct evbuffer *databuf, + void (*cb)(struct evhttp_connection *, void *), void *arg) +{ + struct evhttp_connection *evcon = req->evcon; + struct evbuffer *output; + + if (evcon == NULL) + return; + + output = bufferevent_get_output(evcon->bufev); + + if (evbuffer_get_length(databuf) == 0) + return; + if (!evhttp_response_needs_body(req)) + return; + if (req->chunked) { + evbuffer_add_printf(output, "%x\r\n", + (unsigned)evbuffer_get_length(databuf)); + } + evbuffer_add_buffer(output, databuf); + if (req->chunked) { + evbuffer_add(output, "\r\n", 2); + } + evhttp_write_buffer(evcon, cb, arg); +} + +void +evhttp_send_reply_chunk(struct evhttp_request *req, struct evbuffer *databuf) +{ + evhttp_send_reply_chunk_with_cb(req, databuf, NULL, NULL); +} +void +evhttp_send_reply_end(struct evhttp_request *req) +{ + struct evhttp_connection *evcon = req->evcon; + struct evbuffer *output; + + if (evcon == NULL) { + evhttp_request_free(req); + return; + } + + output = bufferevent_get_output(evcon->bufev); + + /* we expect no more calls form the user on this request */ + req->userdone = 1; + + if (req->chunked) { + evbuffer_add(output, "0\r\n\r\n", 5); + evhttp_write_buffer(req->evcon, evhttp_send_done, NULL); + req->chunked = 0; + } else if (evbuffer_get_length(output) == 0) { + /* let the connection know that we are done with the request */ + evhttp_send_done(evcon, NULL); + } else { + /* make the callback execute after all data has been written */ + evcon->cb = evhttp_send_done; + evcon->cb_arg = NULL; + } +} + +static const char *informational_phrases[] = { + /* 100 */ "Continue", + /* 101 */ "Switching Protocols" +}; + +static const char *success_phrases[] = { + /* 200 */ "OK", + /* 201 */ "Created", + /* 202 */ "Accepted", + /* 203 */ "Non-Authoritative Information", + /* 204 */ "No Content", + /* 205 */ "Reset Content", + /* 206 */ "Partial Content" +}; + +static const char *redirection_phrases[] = { + /* 300 */ "Multiple Choices", + /* 301 */ "Moved Permanently", + /* 302 */ "Found", + /* 303 */ "See Other", + /* 304 */ "Not Modified", + /* 305 */ "Use Proxy", + /* 307 */ "Temporary Redirect" +}; + +static const char *client_error_phrases[] = { + /* 400 */ "Bad Request", + /* 401 */ "Unauthorized", + /* 402 */ "Payment Required", + /* 403 */ "Forbidden", + /* 404 */ "Not Found", + /* 405 */ "Method Not Allowed", + /* 406 */ "Not Acceptable", + /* 407 */ "Proxy Authentication Required", + /* 408 */ "Request Time-out", + /* 409 */ "Conflict", + /* 410 */ "Gone", + /* 411 */ "Length Required", + /* 412 */ "Precondition Failed", + /* 413 */ "Request Entity Too Large", + /* 414 */ "Request-URI Too Large", + /* 415 */ "Unsupported Media Type", + /* 416 */ "Requested range not satisfiable", + /* 417 */ "Expectation Failed" +}; + +static const char *server_error_phrases[] = { + /* 500 */ "Internal Server Error", + /* 501 */ "Not Implemented", + /* 502 */ "Bad Gateway", + /* 503 */ "Service Unavailable", + /* 504 */ "Gateway Time-out", + /* 505 */ "HTTP Version not supported" +}; + +struct response_class { + const char *name; + size_t num_responses; + const char **responses; +}; + +#ifndef MEMBERSOF +#define MEMBERSOF(x) (sizeof(x)/sizeof(x[0])) +#endif + +static const struct response_class response_classes[] = { + /* 1xx */ { "Informational", MEMBERSOF(informational_phrases), informational_phrases }, + /* 2xx */ { "Success", MEMBERSOF(success_phrases), success_phrases }, + /* 3xx */ { "Redirection", MEMBERSOF(redirection_phrases), redirection_phrases }, + /* 4xx */ { "Client Error", MEMBERSOF(client_error_phrases), client_error_phrases }, + /* 5xx */ { "Server Error", MEMBERSOF(server_error_phrases), server_error_phrases } +}; + +static const char * +evhttp_response_phrase_internal(int code) +{ + int klass = code / 100 - 1; + int subcode = code % 100; + + /* Unknown class - can't do any better here */ + if (klass < 0 || klass >= (int) MEMBERSOF(response_classes)) + return "Unknown Status Class"; + + /* Unknown sub-code, return class name at least */ + if (subcode >= (int) response_classes[klass].num_responses) + return response_classes[klass].name; + + return response_classes[klass].responses[subcode]; +} + +void +evhttp_response_code_(struct evhttp_request *req, int code, const char *reason) +{ + req->kind = EVHTTP_RESPONSE; + req->response_code = code; + if (req->response_code_line != NULL) + mm_free(req->response_code_line); + if (reason == NULL) + reason = evhttp_response_phrase_internal(code); + req->response_code_line = mm_strdup(reason); + if (req->response_code_line == NULL) { + event_warn("%s: strdup", __func__); + /* XXX what else can we do? */ + } +} + +void +evhttp_send_page_(struct evhttp_request *req, struct evbuffer *databuf) +{ + if (!req->major || !req->minor) { + req->major = 1; + req->minor = 1; + } + + if (req->kind != EVHTTP_RESPONSE) + evhttp_response_code_(req, 200, "OK"); + + evhttp_clear_headers(req->output_headers); + evhttp_add_header(req->output_headers, "Content-Type", "text/html"); + evhttp_add_header(req->output_headers, "Connection", "close"); + + evhttp_send(req, databuf); +} + +static const char uri_chars[256] = { + /* 0 */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, + /* 64 */ + 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, + 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 0, + /* 128 */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + /* 192 */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +}; + +#define CHAR_IS_UNRESERVED(c) \ + (uri_chars[(unsigned char)(c)]) + +/* + * Helper functions to encode/decode a string for inclusion in a URI. + * The returned string must be freed by the caller. + */ +char * +evhttp_uriencode(const char *uri, ev_ssize_t len, int space_as_plus) +{ + struct evbuffer *buf = evbuffer_new(); + const char *p, *end; + char *result; + + if (buf == NULL) + return (NULL); + + if (len >= 0) + end = uri+len; + else + end = uri+strlen(uri); + + for (p = uri; p < end; p++) { + if (CHAR_IS_UNRESERVED(*p)) { + evbuffer_add(buf, p, 1); + } else if (*p == ' ' && space_as_plus) { + evbuffer_add(buf, "+", 1); + } else { + evbuffer_add_printf(buf, "%%%02X", (unsigned char)(*p)); + } + } + evbuffer_add(buf, "", 1); /* NUL-terminator. */ + result = mm_malloc(evbuffer_get_length(buf)); + if (result) + evbuffer_remove(buf, result, evbuffer_get_length(buf)); + evbuffer_free(buf); + + return (result); +} + +char * +evhttp_encode_uri(const char *str) +{ + return evhttp_uriencode(str, -1, 0); +} + +/* + * @param decode_plus_ctl: if 1, we decode plus into space. If 0, we don't. + * If -1, when true we transform plus to space only after we've seen + * a ?. -1 is deprecated. + * @return the number of bytes written to 'ret'. + */ +int +evhttp_decode_uri_internal( + const char *uri, size_t length, char *ret, int decode_plus_ctl) +{ + char c; + int j; + int decode_plus = (decode_plus_ctl == 1) ? 1: 0; + unsigned i; + + for (i = j = 0; i < length; i++) { + c = uri[i]; + if (c == '?') { + if (decode_plus_ctl < 0) + decode_plus = 1; + } else if (c == '+' && decode_plus) { + c = ' '; + } else if ((i + 2) < length && c == '%' && + EVUTIL_ISXDIGIT_(uri[i+1]) && EVUTIL_ISXDIGIT_(uri[i+2])) { + char tmp[3]; + tmp[0] = uri[i+1]; + tmp[1] = uri[i+2]; + tmp[2] = '\0'; + c = (char)strtol(tmp, NULL, 16); + i += 2; + } + ret[j++] = c; + } + ret[j] = '\0'; + + return (j); +} + +/* deprecated */ +char * +evhttp_decode_uri(const char *uri) +{ + char *ret; + + if ((ret = mm_malloc(strlen(uri) + 1)) == NULL) { + event_warn("%s: malloc(%lu)", __func__, + (unsigned long)(strlen(uri) + 1)); + return (NULL); + } + + evhttp_decode_uri_internal(uri, strlen(uri), + ret, -1 /*always_decode_plus*/); + + return (ret); +} + +char * +evhttp_uridecode(const char *uri, int decode_plus, size_t *size_out) +{ + char *ret; + int n; + + if ((ret = mm_malloc(strlen(uri) + 1)) == NULL) { + event_warn("%s: malloc(%lu)", __func__, + (unsigned long)(strlen(uri) + 1)); + return (NULL); + } + + n = evhttp_decode_uri_internal(uri, strlen(uri), + ret, !!decode_plus/*always_decode_plus*/); + + if (size_out) { + EVUTIL_ASSERT(n >= 0); + *size_out = (size_t)n; + } + + return (ret); +} + +/* + * Helper function to parse out arguments in a query. + * The arguments are separated by key and value. + */ + +static int +evhttp_parse_query_impl(const char *str, struct evkeyvalq *headers, + int is_whole_uri) +{ + char *line=NULL; + char *argument; + char *p; + const char *query_part; + int result = -1; + struct evhttp_uri *uri=NULL; + + TAILQ_INIT(headers); + + if (is_whole_uri) { + uri = evhttp_uri_parse(str); + if (!uri) + goto error; + query_part = evhttp_uri_get_query(uri); + } else { + query_part = str; + } + + /* No arguments - we are done */ + if (!query_part || !strlen(query_part)) { + result = 0; + goto done; + } + + if ((line = mm_strdup(query_part)) == NULL) { + event_warn("%s: strdup", __func__); + goto error; + } + + p = argument = line; + while (p != NULL && *p != '\0') { + char *key, *value, *decoded_value; + argument = strsep(&p, "&"); + + value = argument; + key = strsep(&value, "="); + if (value == NULL || *key == '\0') { + goto error; + } + + if ((decoded_value = mm_malloc(strlen(value) + 1)) == NULL) { + event_warn("%s: mm_malloc", __func__); + goto error; + } + evhttp_decode_uri_internal(value, strlen(value), + decoded_value, 1 /*always_decode_plus*/); + event_debug(("Query Param: %s -> %s\n", key, decoded_value)); + evhttp_add_header_internal(headers, key, decoded_value); + mm_free(decoded_value); + } + + result = 0; + goto done; +error: + evhttp_clear_headers(headers); +done: + if (line) + mm_free(line); + if (uri) + evhttp_uri_free(uri); + return result; +} + +int +evhttp_parse_query(const char *uri, struct evkeyvalq *headers) +{ + return evhttp_parse_query_impl(uri, headers, 1); +} +int +evhttp_parse_query_str(const char *uri, struct evkeyvalq *headers) +{ + return evhttp_parse_query_impl(uri, headers, 0); +} + +static struct evhttp_cb * +evhttp_dispatch_callback(struct httpcbq *callbacks, struct evhttp_request *req) +{ + struct evhttp_cb *cb; + size_t offset = 0; + char *translated; + const char *path; + + /* Test for different URLs */ + path = evhttp_uri_get_path(req->uri_elems); + offset = strlen(path); + if ((translated = mm_malloc(offset + 1)) == NULL) + return (NULL); + evhttp_decode_uri_internal(path, offset, translated, + 0 /* decode_plus */); + + TAILQ_FOREACH(cb, callbacks, next) { + if (!strcmp(cb->what, translated)) { + mm_free(translated); + return (cb); + } + } + + mm_free(translated); + return (NULL); +} + + +static int +prefix_suffix_match(const char *pattern, const char *name, int ignorecase) +{ + char c; + + while (1) { + switch (c = *pattern++) { + case '\0': + return *name == '\0'; + + case '*': + while (*name != '\0') { + if (prefix_suffix_match(pattern, name, + ignorecase)) + return (1); + ++name; + } + return (0); + default: + if (c != *name) { + if (!ignorecase || + EVUTIL_TOLOWER_(c) != EVUTIL_TOLOWER_(*name)) + return (0); + } + ++name; + } + } + /* NOTREACHED */ +} + +/* + Search the vhost hierarchy beginning with http for a server alias + matching hostname. If a match is found, and outhttp is non-null, + outhttp is set to the matching http object and 1 is returned. +*/ + +static int +evhttp_find_alias(struct evhttp *http, struct evhttp **outhttp, + const char *hostname) +{ + struct evhttp_server_alias *alias; + struct evhttp *vhost; + + TAILQ_FOREACH(alias, &http->aliases, next) { + /* XXX Do we need to handle IP addresses? */ + if (!evutil_ascii_strcasecmp(alias->alias, hostname)) { + if (outhttp) + *outhttp = http; + return 1; + } + } + + /* XXX It might be good to avoid recursion here, but I don't + see a way to do that w/o a list. */ + TAILQ_FOREACH(vhost, &http->virtualhosts, next_vhost) { + if (evhttp_find_alias(vhost, outhttp, hostname)) + return 1; + } + + return 0; +} + +/* + Attempts to find the best http object to handle a request for a hostname. + All aliases for the root http object and vhosts are searched for an exact + match. Then, the vhost hierarchy is traversed again for a matching + pattern. + + If an alias or vhost is matched, 1 is returned, and outhttp, if non-null, + is set with the best matching http object. If there are no matches, the + root http object is stored in outhttp and 0 is returned. +*/ + +static int +evhttp_find_vhost(struct evhttp *http, struct evhttp **outhttp, + const char *hostname) +{ + struct evhttp *vhost; + struct evhttp *oldhttp; + int match_found = 0; + + if (evhttp_find_alias(http, outhttp, hostname)) + return 1; + + do { + oldhttp = http; + TAILQ_FOREACH(vhost, &http->virtualhosts, next_vhost) { + if (prefix_suffix_match(vhost->vhost_pattern, + hostname, 1 /* ignorecase */)) { + http = vhost; + match_found = 1; + break; + } + } + } while (oldhttp != http); + + if (outhttp) + *outhttp = http; + + return match_found; +} + +static void +evhttp_handle_request(struct evhttp_request *req, void *arg) +{ + struct evhttp *http = arg; + struct evhttp_cb *cb = NULL; + const char *hostname; + + /* we have a new request on which the user needs to take action */ + req->userdone = 0; + + if (req->type == 0 || req->uri == NULL) { + evhttp_send_error(req, HTTP_BADREQUEST, NULL); + return; + } + + if ((http->allowed_methods & req->type) == 0) { + event_debug(("Rejecting disallowed method %x (allowed: %x)\n", + (unsigned)req->type, (unsigned)http->allowed_methods)); + evhttp_send_error(req, HTTP_NOTIMPLEMENTED, NULL); + return; + } + + /* handle potential virtual hosts */ + hostname = evhttp_request_get_host(req); + if (hostname != NULL) { + evhttp_find_vhost(http, &http, hostname); + } + + if ((cb = evhttp_dispatch_callback(&http->callbacks, req)) != NULL) { + (*cb->cb)(req, cb->cbarg); + return; + } + + /* Generic call back */ + if (http->gencb) { + (*http->gencb)(req, http->gencbarg); + return; + } else { + /* We need to send a 404 here */ +#define ERR_FORMAT "" \ + "404 Not Found" \ + "" \ + "

      Not Found

      " \ + "

      The requested URL %s was not found on this server.

      "\ + "\n" + + char *escaped_html; + struct evbuffer *buf; + + if ((escaped_html = evhttp_htmlescape(req->uri)) == NULL) { + evhttp_connection_free(req->evcon); + return; + } + + if ((buf = evbuffer_new()) == NULL) { + mm_free(escaped_html); + evhttp_connection_free(req->evcon); + return; + } + + evhttp_response_code_(req, HTTP_NOTFOUND, "Not Found"); + + evbuffer_add_printf(buf, ERR_FORMAT, escaped_html); + + mm_free(escaped_html); + + evhttp_send_page_(req, buf); + + evbuffer_free(buf); +#undef ERR_FORMAT + } +} + +/* Listener callback when a connection arrives at a server. */ +static void +accept_socket_cb(struct evconnlistener *listener, evutil_socket_t nfd, struct sockaddr *peer_sa, int peer_socklen, void *arg) +{ + struct evhttp *http = arg; + + evhttp_get_request(http, nfd, peer_sa, peer_socklen); +} + +int +evhttp_bind_socket(struct evhttp *http, const char *address, ev_uint16_t port) +{ + struct evhttp_bound_socket *bound = + evhttp_bind_socket_with_handle(http, address, port); + if (bound == NULL) + return (-1); + return (0); +} + +struct evhttp_bound_socket * +evhttp_bind_socket_with_handle(struct evhttp *http, const char *address, ev_uint16_t port) +{ + evutil_socket_t fd; + struct evhttp_bound_socket *bound; + + if ((fd = bind_socket(address, port, 1 /*reuse*/)) == -1) + return (NULL); + + if (listen(fd, 128) == -1) { + event_sock_warn(fd, "%s: listen", __func__); + evutil_closesocket(fd); + return (NULL); + } + + bound = evhttp_accept_socket_with_handle(http, fd); + + if (bound != NULL) { + event_debug(("Bound to port %d - Awaiting connections ... ", + port)); + return (bound); + } + + return (NULL); +} + +int +evhttp_accept_socket(struct evhttp *http, evutil_socket_t fd) +{ + struct evhttp_bound_socket *bound = + evhttp_accept_socket_with_handle(http, fd); + if (bound == NULL) + return (-1); + return (0); +} + +void +evhttp_foreach_bound_socket(struct evhttp *http, + evhttp_bound_socket_foreach_fn *function, + void *argument) +{ + struct evhttp_bound_socket *bound; + + TAILQ_FOREACH(bound, &http->sockets, next) + function(bound, argument); +} + +struct evhttp_bound_socket * +evhttp_accept_socket_with_handle(struct evhttp *http, evutil_socket_t fd) +{ + struct evhttp_bound_socket *bound; + struct evconnlistener *listener; + const int flags = + LEV_OPT_REUSEABLE|LEV_OPT_CLOSE_ON_EXEC|LEV_OPT_CLOSE_ON_FREE; + + listener = evconnlistener_new(http->base, NULL, NULL, + flags, + 0, /* Backlog is '0' because we already said 'listen' */ + fd); + if (!listener) + return (NULL); + + bound = evhttp_bind_listener(http, listener); + if (!bound) { + evconnlistener_free(listener); + return (NULL); + } + return (bound); +} + +struct evhttp_bound_socket * +evhttp_bind_listener(struct evhttp *http, struct evconnlistener *listener) +{ + struct evhttp_bound_socket *bound; + + bound = mm_malloc(sizeof(struct evhttp_bound_socket)); + if (bound == NULL) + return (NULL); + + bound->listener = listener; + TAILQ_INSERT_TAIL(&http->sockets, bound, next); + + evconnlistener_set_cb(listener, accept_socket_cb, http); + return bound; +} + +evutil_socket_t +evhttp_bound_socket_get_fd(struct evhttp_bound_socket *bound) +{ + return evconnlistener_get_fd(bound->listener); +} + +struct evconnlistener * +evhttp_bound_socket_get_listener(struct evhttp_bound_socket *bound) +{ + return bound->listener; +} + +void +evhttp_del_accept_socket(struct evhttp *http, struct evhttp_bound_socket *bound) +{ + TAILQ_REMOVE(&http->sockets, bound, next); + evconnlistener_free(bound->listener); + mm_free(bound); +} + +static struct evhttp* +evhttp_new_object(void) +{ + struct evhttp *http = NULL; + + if ((http = mm_calloc(1, sizeof(struct evhttp))) == NULL) { + event_warn("%s: calloc", __func__); + return (NULL); + } + + evutil_timerclear(&http->timeout); + evhttp_set_max_headers_size(http, EV_SIZE_MAX); + evhttp_set_max_body_size(http, EV_SIZE_MAX); + evhttp_set_default_content_type(http, "text/html; charset=ISO-8859-1"); + evhttp_set_allowed_methods(http, + EVHTTP_REQ_GET | + EVHTTP_REQ_POST | + EVHTTP_REQ_HEAD | + EVHTTP_REQ_PUT | + EVHTTP_REQ_DELETE); + + TAILQ_INIT(&http->sockets); + TAILQ_INIT(&http->callbacks); + TAILQ_INIT(&http->connections); + TAILQ_INIT(&http->virtualhosts); + TAILQ_INIT(&http->aliases); + + return (http); +} + +struct evhttp * +evhttp_new(struct event_base *base) +{ + struct evhttp *http = NULL; + + http = evhttp_new_object(); + if (http == NULL) + return (NULL); + http->base = base; + + return (http); +} + +/* + * Start a web server on the specified address and port. + */ + +struct evhttp * +evhttp_start(const char *address, unsigned short port) +{ + struct evhttp *http = NULL; + + http = evhttp_new_object(); + if (http == NULL) + return (NULL); + if (evhttp_bind_socket(http, address, port) == -1) { + mm_free(http); + return (NULL); + } + + return (http); +} + +void +evhttp_free(struct evhttp* http) +{ + struct evhttp_cb *http_cb; + struct evhttp_connection *evcon; + struct evhttp_bound_socket *bound; + struct evhttp* vhost; + struct evhttp_server_alias *alias; + + /* Remove the accepting part */ + while ((bound = TAILQ_FIRST(&http->sockets)) != NULL) { + TAILQ_REMOVE(&http->sockets, bound, next); + + evconnlistener_free(bound->listener); + + mm_free(bound); + } + + while ((evcon = TAILQ_FIRST(&http->connections)) != NULL) { + /* evhttp_connection_free removes the connection */ + evhttp_connection_free(evcon); + } + + while ((http_cb = TAILQ_FIRST(&http->callbacks)) != NULL) { + TAILQ_REMOVE(&http->callbacks, http_cb, next); + mm_free(http_cb->what); + mm_free(http_cb); + } + + while ((vhost = TAILQ_FIRST(&http->virtualhosts)) != NULL) { + TAILQ_REMOVE(&http->virtualhosts, vhost, next_vhost); + + evhttp_free(vhost); + } + + if (http->vhost_pattern != NULL) + mm_free(http->vhost_pattern); + + while ((alias = TAILQ_FIRST(&http->aliases)) != NULL) { + TAILQ_REMOVE(&http->aliases, alias, next); + mm_free(alias->alias); + mm_free(alias); + } + + mm_free(http); +} + +int +evhttp_add_virtual_host(struct evhttp* http, const char *pattern, + struct evhttp* vhost) +{ + /* a vhost can only be a vhost once and should not have bound sockets */ + if (vhost->vhost_pattern != NULL || + TAILQ_FIRST(&vhost->sockets) != NULL) + return (-1); + + vhost->vhost_pattern = mm_strdup(pattern); + if (vhost->vhost_pattern == NULL) + return (-1); + + TAILQ_INSERT_TAIL(&http->virtualhosts, vhost, next_vhost); + + return (0); +} + +int +evhttp_remove_virtual_host(struct evhttp* http, struct evhttp* vhost) +{ + if (vhost->vhost_pattern == NULL) + return (-1); + + TAILQ_REMOVE(&http->virtualhosts, vhost, next_vhost); + + mm_free(vhost->vhost_pattern); + vhost->vhost_pattern = NULL; + + return (0); +} + +int +evhttp_add_server_alias(struct evhttp *http, const char *alias) +{ + struct evhttp_server_alias *evalias; + + evalias = mm_calloc(1, sizeof(*evalias)); + if (!evalias) + return -1; + + evalias->alias = mm_strdup(alias); + if (!evalias->alias) { + mm_free(evalias); + return -1; + } + + TAILQ_INSERT_TAIL(&http->aliases, evalias, next); + + return 0; +} + +int +evhttp_remove_server_alias(struct evhttp *http, const char *alias) +{ + struct evhttp_server_alias *evalias; + + TAILQ_FOREACH(evalias, &http->aliases, next) { + if (evutil_ascii_strcasecmp(evalias->alias, alias) == 0) { + TAILQ_REMOVE(&http->aliases, evalias, next); + mm_free(evalias->alias); + mm_free(evalias); + return 0; + } + } + + return -1; +} + +void +evhttp_set_timeout(struct evhttp* http, int timeout_in_secs) +{ + if (timeout_in_secs == -1) { + evhttp_set_timeout_tv(http, NULL); + } else { + struct timeval tv; + tv.tv_sec = timeout_in_secs; + tv.tv_usec = 0; + evhttp_set_timeout_tv(http, &tv); + } +} + +void +evhttp_set_timeout_tv(struct evhttp* http, const struct timeval* tv) +{ + if (tv) { + http->timeout = *tv; + } else { + evutil_timerclear(&http->timeout); + } +} + +void +evhttp_set_max_headers_size(struct evhttp* http, ev_ssize_t max_headers_size) +{ + if (max_headers_size < 0) + http->default_max_headers_size = EV_SIZE_MAX; + else + http->default_max_headers_size = max_headers_size; +} + +void +evhttp_set_max_body_size(struct evhttp* http, ev_ssize_t max_body_size) +{ + if (max_body_size < 0) + http->default_max_body_size = EV_UINT64_MAX; + else + http->default_max_body_size = max_body_size; +} + +void +evhttp_set_default_content_type(struct evhttp *http, + const char *content_type) { + http->default_content_type = content_type; +} + +void +evhttp_set_allowed_methods(struct evhttp* http, ev_uint16_t methods) +{ + http->allowed_methods = methods; +} + +int +evhttp_set_cb(struct evhttp *http, const char *uri, + void (*cb)(struct evhttp_request *, void *), void *cbarg) +{ + struct evhttp_cb *http_cb; + + TAILQ_FOREACH(http_cb, &http->callbacks, next) { + if (strcmp(http_cb->what, uri) == 0) + return (-1); + } + + if ((http_cb = mm_calloc(1, sizeof(struct evhttp_cb))) == NULL) { + event_warn("%s: calloc", __func__); + return (-2); + } + + http_cb->what = mm_strdup(uri); + if (http_cb->what == NULL) { + event_warn("%s: strdup", __func__); + mm_free(http_cb); + return (-3); + } + http_cb->cb = cb; + http_cb->cbarg = cbarg; + + TAILQ_INSERT_TAIL(&http->callbacks, http_cb, next); + + return (0); +} + +int +evhttp_del_cb(struct evhttp *http, const char *uri) +{ + struct evhttp_cb *http_cb; + + TAILQ_FOREACH(http_cb, &http->callbacks, next) { + if (strcmp(http_cb->what, uri) == 0) + break; + } + if (http_cb == NULL) + return (-1); + + TAILQ_REMOVE(&http->callbacks, http_cb, next); + mm_free(http_cb->what); + mm_free(http_cb); + + return (0); +} + +void +evhttp_set_gencb(struct evhttp *http, + void (*cb)(struct evhttp_request *, void *), void *cbarg) +{ + http->gencb = cb; + http->gencbarg = cbarg; +} + +void +evhttp_set_bevcb(struct evhttp *http, + struct bufferevent* (*cb)(struct event_base *, void *), void *cbarg) +{ + http->bevcb = cb; + http->bevcbarg = cbarg; +} + +/* + * Request related functions + */ + +struct evhttp_request * +evhttp_request_new(void (*cb)(struct evhttp_request *, void *), void *arg) +{ + struct evhttp_request *req = NULL; + + /* Allocate request structure */ + if ((req = mm_calloc(1, sizeof(struct evhttp_request))) == NULL) { + event_warn("%s: calloc", __func__); + goto error; + } + + req->headers_size = 0; + req->body_size = 0; + + req->kind = EVHTTP_RESPONSE; + req->input_headers = mm_calloc(1, sizeof(struct evkeyvalq)); + if (req->input_headers == NULL) { + event_warn("%s: calloc", __func__); + goto error; + } + TAILQ_INIT(req->input_headers); + + req->output_headers = mm_calloc(1, sizeof(struct evkeyvalq)); + if (req->output_headers == NULL) { + event_warn("%s: calloc", __func__); + goto error; + } + TAILQ_INIT(req->output_headers); + + if ((req->input_buffer = evbuffer_new()) == NULL) { + event_warn("%s: evbuffer_new", __func__); + goto error; + } + + if ((req->output_buffer = evbuffer_new()) == NULL) { + event_warn("%s: evbuffer_new", __func__); + goto error; + } + + req->cb = cb; + req->cb_arg = arg; + + return (req); + + error: + if (req != NULL) + evhttp_request_free(req); + return (NULL); +} + +void +evhttp_request_free(struct evhttp_request *req) +{ + if ((req->flags & EVHTTP_REQ_DEFER_FREE) != 0) { + req->flags |= EVHTTP_REQ_NEEDS_FREE; + return; + } + + if (req->remote_host != NULL) + mm_free(req->remote_host); + if (req->uri != NULL) + mm_free(req->uri); + if (req->uri_elems != NULL) + evhttp_uri_free(req->uri_elems); + if (req->response_code_line != NULL) + mm_free(req->response_code_line); + if (req->host_cache != NULL) + mm_free(req->host_cache); + + evhttp_clear_headers(req->input_headers); + mm_free(req->input_headers); + + evhttp_clear_headers(req->output_headers); + mm_free(req->output_headers); + + if (req->input_buffer != NULL) + evbuffer_free(req->input_buffer); + + if (req->output_buffer != NULL) + evbuffer_free(req->output_buffer); + + mm_free(req); +} + +void +evhttp_request_own(struct evhttp_request *req) +{ + req->flags |= EVHTTP_USER_OWNED; +} + +int +evhttp_request_is_owned(struct evhttp_request *req) +{ + return (req->flags & EVHTTP_USER_OWNED) != 0; +} + +struct evhttp_connection * +evhttp_request_get_connection(struct evhttp_request *req) +{ + return req->evcon; +} + +struct event_base * +evhttp_connection_get_base(struct evhttp_connection *conn) +{ + return conn->base; +} + +void +evhttp_request_set_chunked_cb(struct evhttp_request *req, + void (*cb)(struct evhttp_request *, void *)) +{ + req->chunk_cb = cb; +} + +void +evhttp_request_set_header_cb(struct evhttp_request *req, + int (*cb)(struct evhttp_request *, void *)) +{ + req->header_cb = cb; +} + +void +evhttp_request_set_error_cb(struct evhttp_request *req, + void (*cb)(enum evhttp_request_error, void *)) +{ + req->error_cb = cb; +} + +void +evhttp_request_set_on_complete_cb(struct evhttp_request *req, + void (*cb)(struct evhttp_request *, void *), void *cb_arg) +{ + req->on_complete_cb = cb; + req->on_complete_cb_arg = cb_arg; +} + +/* + * Allows for inspection of the request URI + */ + +const char * +evhttp_request_get_uri(const struct evhttp_request *req) { + if (req->uri == NULL) + event_debug(("%s: request %p has no uri\n", __func__, req)); + return (req->uri); +} + +const struct evhttp_uri * +evhttp_request_get_evhttp_uri(const struct evhttp_request *req) { + if (req->uri_elems == NULL) + event_debug(("%s: request %p has no uri elems\n", + __func__, req)); + return (req->uri_elems); +} + +const char * +evhttp_request_get_host(struct evhttp_request *req) +{ + const char *host = NULL; + + if (req->host_cache) + return req->host_cache; + + if (req->uri_elems) + host = evhttp_uri_get_host(req->uri_elems); + if (!host && req->input_headers) { + const char *p; + size_t len; + + host = evhttp_find_header(req->input_headers, "Host"); + /* The Host: header may include a port. Remove it here + to be consistent with uri_elems case above. */ + if (host) { + p = host + strlen(host) - 1; + while (p > host && EVUTIL_ISDIGIT_(*p)) + --p; + if (p > host && *p == ':') { + len = p - host; + req->host_cache = mm_malloc(len + 1); + if (!req->host_cache) { + event_warn("%s: malloc", __func__); + return NULL; + } + memcpy(req->host_cache, host, len); + req->host_cache[len] = '\0'; + host = req->host_cache; + } + } + } + + return host; +} + +enum evhttp_cmd_type +evhttp_request_get_command(const struct evhttp_request *req) { + return (req->type); +} + +int +evhttp_request_get_response_code(const struct evhttp_request *req) +{ + return req->response_code; +} + +const char * +evhttp_request_get_response_code_line(const struct evhttp_request *req) +{ + return req->response_code_line; +} + +/** Returns the input headers */ +struct evkeyvalq *evhttp_request_get_input_headers(struct evhttp_request *req) +{ + return (req->input_headers); +} + +/** Returns the output headers */ +struct evkeyvalq *evhttp_request_get_output_headers(struct evhttp_request *req) +{ + return (req->output_headers); +} + +/** Returns the input buffer */ +struct evbuffer *evhttp_request_get_input_buffer(struct evhttp_request *req) +{ + return (req->input_buffer); +} + +/** Returns the output buffer */ +struct evbuffer *evhttp_request_get_output_buffer(struct evhttp_request *req) +{ + return (req->output_buffer); +} + + +/* + * Takes a file descriptor to read a request from. + * The callback is executed once the whole request has been read. + */ + +static struct evhttp_connection* +evhttp_get_request_connection( + struct evhttp* http, + evutil_socket_t fd, struct sockaddr *sa, ev_socklen_t salen) +{ + struct evhttp_connection *evcon; + char *hostname = NULL, *portname = NULL; + struct bufferevent* bev = NULL; + + name_from_addr(sa, salen, &hostname, &portname); + if (hostname == NULL || portname == NULL) { + if (hostname) mm_free(hostname); + if (portname) mm_free(portname); + return (NULL); + } + + event_debug(("%s: new request from %s:%s on "EV_SOCK_FMT"\n", + __func__, hostname, portname, EV_SOCK_ARG(fd))); + + /* we need a connection object to put the http request on */ + if (http->bevcb != NULL) { + bev = (*http->bevcb)(http->base, http->bevcbarg); + } + evcon = evhttp_connection_base_bufferevent_new( + http->base, NULL, bev, hostname, atoi(portname)); + mm_free(hostname); + mm_free(portname); + if (evcon == NULL) + return (NULL); + + evcon->max_headers_size = http->default_max_headers_size; + evcon->max_body_size = http->default_max_body_size; + + evcon->flags |= EVHTTP_CON_INCOMING; + evcon->state = EVCON_READING_FIRSTLINE; + + evcon->fd = fd; + + bufferevent_setfd(evcon->bufev, fd); + + return (evcon); +} + +static int +evhttp_associate_new_request_with_connection(struct evhttp_connection *evcon) +{ + struct evhttp *http = evcon->http_server; + struct evhttp_request *req; + if ((req = evhttp_request_new(evhttp_handle_request, http)) == NULL) + return (-1); + + if ((req->remote_host = mm_strdup(evcon->address)) == NULL) { + event_warn("%s: strdup", __func__); + evhttp_request_free(req); + return (-1); + } + req->remote_port = evcon->port; + + req->evcon = evcon; /* the request ends up owning the connection */ + req->flags |= EVHTTP_REQ_OWN_CONNECTION; + + /* We did not present the request to the user user yet, so treat it as + * if the user was done with the request. This allows us to free the + * request on a persistent connection if the client drops it without + * sending a request. + */ + req->userdone = 1; + + TAILQ_INSERT_TAIL(&evcon->requests, req, next); + + req->kind = EVHTTP_REQUEST; + + + evhttp_start_read_(evcon); + + return (0); +} + +static void +evhttp_get_request(struct evhttp *http, evutil_socket_t fd, + struct sockaddr *sa, ev_socklen_t salen) +{ + struct evhttp_connection *evcon; + + evcon = evhttp_get_request_connection(http, fd, sa, salen); + if (evcon == NULL) { + event_sock_warn(fd, "%s: cannot get connection on "EV_SOCK_FMT, + __func__, EV_SOCK_ARG(fd)); + evutil_closesocket(fd); + return; + } + + /* the timeout can be used by the server to close idle connections */ + if (evutil_timerisset(&http->timeout)) + evhttp_connection_set_timeout_tv(evcon, &http->timeout); + + /* + * if we want to accept more than one request on a connection, + * we need to know which http server it belongs to. + */ + evcon->http_server = http; + TAILQ_INSERT_TAIL(&http->connections, evcon, next); + + if (evhttp_associate_new_request_with_connection(evcon) == -1) + evhttp_connection_free(evcon); +} + + +/* + * Network helper functions that we do not want to export to the rest of + * the world. + */ + +static void +name_from_addr(struct sockaddr *sa, ev_socklen_t salen, + char **phost, char **pport) +{ + char ntop[NI_MAXHOST]; + char strport[NI_MAXSERV]; + int ni_result; + +#ifdef EVENT__HAVE_GETNAMEINFO + ni_result = getnameinfo(sa, salen, + ntop, sizeof(ntop), strport, sizeof(strport), + NI_NUMERICHOST|NI_NUMERICSERV); + + if (ni_result != 0) { +#ifdef EAI_SYSTEM + /* Windows doesn't have an EAI_SYSTEM. */ + if (ni_result == EAI_SYSTEM) + event_err(1, "getnameinfo failed"); + else +#endif + event_errx(1, "getnameinfo failed: %s", gai_strerror(ni_result)); + return; + } +#else + ni_result = fake_getnameinfo(sa, salen, + ntop, sizeof(ntop), strport, sizeof(strport), + NI_NUMERICHOST|NI_NUMERICSERV); + if (ni_result != 0) + return; +#endif + + *phost = mm_strdup(ntop); + *pport = mm_strdup(strport); +} + +/* Create a non-blocking socket and bind it */ +/* todo: rename this function */ +static evutil_socket_t +bind_socket_ai(struct evutil_addrinfo *ai, int reuse) +{ + evutil_socket_t fd; + + int on = 1, r; + int serrno; + + /* Create listen socket */ + fd = evutil_socket_(ai ? ai->ai_family : AF_INET, + SOCK_STREAM|EVUTIL_SOCK_NONBLOCK|EVUTIL_SOCK_CLOEXEC, 0); + if (fd == -1) { + event_sock_warn(-1, "socket"); + return (-1); + } + + if (setsockopt(fd, SOL_SOCKET, SO_KEEPALIVE, (void *)&on, sizeof(on))<0) + goto out; + if (reuse) { + if (evutil_make_listen_socket_reuseable(fd) < 0) + goto out; + } + + if (ai != NULL) { + r = bind(fd, ai->ai_addr, (ev_socklen_t)ai->ai_addrlen); + if (r == -1) + goto out; + } + + return (fd); + + out: + serrno = EVUTIL_SOCKET_ERROR(); + evutil_closesocket(fd); + EVUTIL_SET_SOCKET_ERROR(serrno); + return (-1); +} + +static struct evutil_addrinfo * +make_addrinfo(const char *address, ev_uint16_t port) +{ + struct evutil_addrinfo *ai = NULL; + + struct evutil_addrinfo hints; + char strport[NI_MAXSERV]; + int ai_result; + + memset(&hints, 0, sizeof(hints)); + hints.ai_family = AF_UNSPEC; + hints.ai_socktype = SOCK_STREAM; + /* turn NULL hostname into INADDR_ANY, and skip looking up any address + * types we don't have an interface to connect to. */ + hints.ai_flags = EVUTIL_AI_PASSIVE|EVUTIL_AI_ADDRCONFIG; + evutil_snprintf(strport, sizeof(strport), "%d", port); + if ((ai_result = evutil_getaddrinfo(address, strport, &hints, &ai)) + != 0) { + if (ai_result == EVUTIL_EAI_SYSTEM) + event_warn("getaddrinfo"); + else + event_warnx("getaddrinfo: %s", + evutil_gai_strerror(ai_result)); + return (NULL); + } + + return (ai); +} + +static evutil_socket_t +bind_socket(const char *address, ev_uint16_t port, int reuse) +{ + evutil_socket_t fd; + struct evutil_addrinfo *aitop = NULL; + + /* just create an unbound socket */ + if (address == NULL && port == 0) + return bind_socket_ai(NULL, 0); + + aitop = make_addrinfo(address, port); + + if (aitop == NULL) + return (-1); + + fd = bind_socket_ai(aitop, reuse); + + evutil_freeaddrinfo(aitop); + + return (fd); +} + +struct evhttp_uri { + unsigned flags; + char *scheme; /* scheme; e.g http, ftp etc */ + char *userinfo; /* userinfo (typically username:pass), or NULL */ + char *host; /* hostname, IP address, or NULL */ + int port; /* port, or zero */ + char *path; /* path, or "". */ + char *query; /* query, or NULL */ + char *fragment; /* fragment or NULL */ +}; + +struct evhttp_uri * +evhttp_uri_new(void) +{ + struct evhttp_uri *uri = mm_calloc(sizeof(struct evhttp_uri), 1); + if (uri) + uri->port = -1; + return uri; +} + +void +evhttp_uri_set_flags(struct evhttp_uri *uri, unsigned flags) +{ + uri->flags = flags; +} + +/* Return true if the string starting at s and ending immediately before eos + * is a valid URI scheme according to RFC3986 + */ +static int +scheme_ok(const char *s, const char *eos) +{ + /* scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." ) */ + EVUTIL_ASSERT(eos >= s); + if (s == eos) + return 0; + if (!EVUTIL_ISALPHA_(*s)) + return 0; + while (++s < eos) { + if (! EVUTIL_ISALNUM_(*s) && + *s != '+' && *s != '-' && *s != '.') + return 0; + } + return 1; +} + +#define SUBDELIMS "!$&'()*+,;=" + +/* Return true iff [s..eos) is a valid userinfo */ +static int +userinfo_ok(const char *s, const char *eos) +{ + while (s < eos) { + if (CHAR_IS_UNRESERVED(*s) || + strchr(SUBDELIMS, *s) || + *s == ':') + ++s; + else if (*s == '%' && s+2 < eos && + EVUTIL_ISXDIGIT_(s[1]) && + EVUTIL_ISXDIGIT_(s[2])) + s += 3; + else + return 0; + } + return 1; +} + +static int +regname_ok(const char *s, const char *eos) +{ + while (s && s 65535) + return -1; + ++s; + } + return portnum; +} + +/* returns 0 for bad, 1 for ipv6, 2 for IPvFuture */ +static int +bracket_addr_ok(const char *s, const char *eos) +{ + if (s + 3 > eos || *s != '[' || *(eos-1) != ']') + return 0; + if (s[1] == 'v') { + /* IPvFuture, or junk. + "v" 1*HEXDIG "." 1*( unreserved / sub-delims / ":" ) + */ + s += 2; /* skip [v */ + --eos; + if (!EVUTIL_ISXDIGIT_(*s)) /*require at least one*/ + return 0; + while (s < eos && *s != '.') { + if (EVUTIL_ISXDIGIT_(*s)) + ++s; + else + return 0; + } + if (*s != '.') + return 0; + ++s; + while (s < eos) { + if (CHAR_IS_UNRESERVED(*s) || + strchr(SUBDELIMS, *s) || + *s == ':') + ++s; + else + return 0; + } + return 2; + } else { + /* IPv6, or junk */ + char buf[64]; + ev_ssize_t n_chars = eos-s-2; + struct in6_addr in6; + if (n_chars >= 64) /* way too long */ + return 0; + memcpy(buf, s+1, n_chars); + buf[n_chars]='\0'; + return (evutil_inet_pton(AF_INET6,buf,&in6)==1) ? 1 : 0; + } +} + +static int +parse_authority(struct evhttp_uri *uri, char *s, char *eos) +{ + char *cp, *port; + EVUTIL_ASSERT(eos); + if (eos == s) { + uri->host = mm_strdup(""); + if (uri->host == NULL) { + event_warn("%s: strdup", __func__); + return -1; + } + return 0; + } + + /* Optionally, we start with "userinfo@" */ + + cp = strchr(s, '@'); + if (cp && cp < eos) { + if (! userinfo_ok(s,cp)) + return -1; + *cp++ = '\0'; + uri->userinfo = mm_strdup(s); + if (uri->userinfo == NULL) { + event_warn("%s: strdup", __func__); + return -1; + } + } else { + cp = s; + } + /* Optionally, we end with ":port" */ + for (port=eos-1; port >= cp && EVUTIL_ISDIGIT_(*port); --port) + ; + if (port >= cp && *port == ':') { + if (port+1 == eos) /* Leave port unspecified; the RFC allows a + * nil port */ + uri->port = -1; + else if ((uri->port = parse_port(port+1, eos))<0) + return -1; + eos = port; + } + /* Now, cp..eos holds the "host" port, which can be an IPv4Address, + * an IP-Literal, or a reg-name */ + EVUTIL_ASSERT(eos >= cp); + if (*cp == '[' && eos >= cp+2 && *(eos-1) == ']') { + /* IPv6address, IP-Literal, or junk. */ + if (! bracket_addr_ok(cp, eos)) + return -1; + } else { + /* Make sure the host part is ok. */ + if (! regname_ok(cp,eos)) /* Match IPv4Address or reg-name */ + return -1; + } + uri->host = mm_malloc(eos-cp+1); + if (uri->host == NULL) { + event_warn("%s: malloc", __func__); + return -1; + } + memcpy(uri->host, cp, eos-cp); + uri->host[eos-cp] = '\0'; + return 0; + +} + +static char * +end_of_authority(char *cp) +{ + while (*cp) { + if (*cp == '?' || *cp == '#' || *cp == '/') + return cp; + ++cp; + } + return cp; +} + +enum uri_part { + PART_PATH, + PART_QUERY, + PART_FRAGMENT +}; + +/* Return the character after the longest prefix of 'cp' that matches... + * *pchar / "/" if allow_qchars is false, or + * *(pchar / "/" / "?") if allow_qchars is true. + */ +static char * +end_of_path(char *cp, enum uri_part part, unsigned flags) +{ + if (flags & EVHTTP_URI_NONCONFORMANT) { + /* If NONCONFORMANT: + * Path is everything up to a # or ? or nul. + * Query is everything up a # or nul + * Fragment is everything up to a nul. + */ + switch (part) { + case PART_PATH: + while (*cp && *cp != '#' && *cp != '?') + ++cp; + break; + case PART_QUERY: + while (*cp && *cp != '#') + ++cp; + break; + case PART_FRAGMENT: + cp += strlen(cp); + break; + }; + return cp; + } + + while (*cp) { + if (CHAR_IS_UNRESERVED(*cp) || + strchr(SUBDELIMS, *cp) || + *cp == ':' || *cp == '@' || *cp == '/') + ++cp; + else if (*cp == '%' && EVUTIL_ISXDIGIT_(cp[1]) && + EVUTIL_ISXDIGIT_(cp[2])) + cp += 3; + else if (*cp == '?' && part != PART_PATH) + ++cp; + else + return cp; + } + return cp; +} + +static int +path_matches_noscheme(const char *cp) +{ + while (*cp) { + if (*cp == ':') + return 0; + else if (*cp == '/') + return 1; + ++cp; + } + return 1; +} + +struct evhttp_uri * +evhttp_uri_parse(const char *source_uri) +{ + return evhttp_uri_parse_with_flags(source_uri, 0); +} + +struct evhttp_uri * +evhttp_uri_parse_with_flags(const char *source_uri, unsigned flags) +{ + char *readbuf = NULL, *readp = NULL, *token = NULL, *query = NULL; + char *path = NULL, *fragment = NULL; + int got_authority = 0; + + struct evhttp_uri *uri = mm_calloc(1, sizeof(struct evhttp_uri)); + if (uri == NULL) { + event_warn("%s: calloc", __func__); + goto err; + } + uri->port = -1; + uri->flags = flags; + + readbuf = mm_strdup(source_uri); + if (readbuf == NULL) { + event_warn("%s: strdup", __func__); + goto err; + } + + readp = readbuf; + token = NULL; + + /* We try to follow RFC3986 here as much as we can, and match + the productions + + URI = scheme ":" hier-part [ "?" query ] [ "#" fragment ] + + relative-ref = relative-part [ "?" query ] [ "#" fragment ] + */ + + /* 1. scheme: */ + token = strchr(readp, ':'); + if (token && scheme_ok(readp,token)) { + *token = '\0'; + uri->scheme = mm_strdup(readp); + if (uri->scheme == NULL) { + event_warn("%s: strdup", __func__); + goto err; + } + readp = token+1; /* eat : */ + } + + /* 2. Optionally, "//" then an 'authority' part. */ + if (readp[0]=='/' && readp[1] == '/') { + char *authority; + readp += 2; + authority = readp; + path = end_of_authority(readp); + if (parse_authority(uri, authority, path) < 0) + goto err; + readp = path; + got_authority = 1; + } + + /* 3. Query: path-abempty, path-absolute, path-rootless, or path-empty + */ + path = readp; + readp = end_of_path(path, PART_PATH, flags); + + /* Query */ + if (*readp == '?') { + *readp = '\0'; + ++readp; + query = readp; + readp = end_of_path(readp, PART_QUERY, flags); + } + /* fragment */ + if (*readp == '#') { + *readp = '\0'; + ++readp; + fragment = readp; + readp = end_of_path(readp, PART_FRAGMENT, flags); + } + if (*readp != '\0') { + goto err; + } + + /* These next two cases may be unreachable; I'm leaving them + * in to be defensive. */ + /* If you didn't get an authority, the path can't begin with "//" */ + if (!got_authority && path[0]=='/' && path[1]=='/') + goto err; + /* If you did get an authority, the path must begin with "/" or be + * empty. */ + if (got_authority && path[0] != '/' && path[0] != '\0') + goto err; + /* (End of maybe-unreachable cases) */ + + /* If there was no scheme, the first part of the path (if any) must + * have no colon in it. */ + if (! uri->scheme && !path_matches_noscheme(path)) + goto err; + + EVUTIL_ASSERT(path); + uri->path = mm_strdup(path); + if (uri->path == NULL) { + event_warn("%s: strdup", __func__); + goto err; + } + + if (query) { + uri->query = mm_strdup(query); + if (uri->query == NULL) { + event_warn("%s: strdup", __func__); + goto err; + } + } + if (fragment) { + uri->fragment = mm_strdup(fragment); + if (uri->fragment == NULL) { + event_warn("%s: strdup", __func__); + goto err; + } + } + + mm_free(readbuf); + + return uri; +err: + if (uri) + evhttp_uri_free(uri); + if (readbuf) + mm_free(readbuf); + return NULL; +} + +void +evhttp_uri_free(struct evhttp_uri *uri) +{ +#define URI_FREE_STR_(f) \ + if (uri->f) { \ + mm_free(uri->f); \ + } + + URI_FREE_STR_(scheme); + URI_FREE_STR_(userinfo); + URI_FREE_STR_(host); + URI_FREE_STR_(path); + URI_FREE_STR_(query); + URI_FREE_STR_(fragment); + + mm_free(uri); +#undef URI_FREE_STR_ +} + +char * +evhttp_uri_join(struct evhttp_uri *uri, char *buf, size_t limit) +{ + struct evbuffer *tmp = 0; + size_t joined_size = 0; + char *output = NULL; + +#define URI_ADD_(f) evbuffer_add(tmp, uri->f, strlen(uri->f)) + + if (!uri || !buf || !limit) + return NULL; + + tmp = evbuffer_new(); + if (!tmp) + return NULL; + + if (uri->scheme) { + URI_ADD_(scheme); + evbuffer_add(tmp, ":", 1); + } + if (uri->host) { + evbuffer_add(tmp, "//", 2); + if (uri->userinfo) + evbuffer_add_printf(tmp,"%s@", uri->userinfo); + URI_ADD_(host); + if (uri->port >= 0) + evbuffer_add_printf(tmp,":%d", uri->port); + + if (uri->path && uri->path[0] != '/' && uri->path[0] != '\0') + goto err; + } + + if (uri->path) + URI_ADD_(path); + + if (uri->query) { + evbuffer_add(tmp, "?", 1); + URI_ADD_(query); + } + + if (uri->fragment) { + evbuffer_add(tmp, "#", 1); + URI_ADD_(fragment); + } + + evbuffer_add(tmp, "\0", 1); /* NUL */ + + joined_size = evbuffer_get_length(tmp); + + if (joined_size > limit) { + /* It doesn't fit. */ + evbuffer_free(tmp); + return NULL; + } + evbuffer_remove(tmp, buf, joined_size); + + output = buf; +err: + evbuffer_free(tmp); + + return output; +#undef URI_ADD_ +} + +const char * +evhttp_uri_get_scheme(const struct evhttp_uri *uri) +{ + return uri->scheme; +} +const char * +evhttp_uri_get_userinfo(const struct evhttp_uri *uri) +{ + return uri->userinfo; +} +const char * +evhttp_uri_get_host(const struct evhttp_uri *uri) +{ + return uri->host; +} +int +evhttp_uri_get_port(const struct evhttp_uri *uri) +{ + return uri->port; +} +const char * +evhttp_uri_get_path(const struct evhttp_uri *uri) +{ + return uri->path; +} +const char * +evhttp_uri_get_query(const struct evhttp_uri *uri) +{ + return uri->query; +} +const char * +evhttp_uri_get_fragment(const struct evhttp_uri *uri) +{ + return uri->fragment; +} + +#define URI_SET_STR_(f) do { \ + if (uri->f) \ + mm_free(uri->f); \ + if (f) { \ + if ((uri->f = mm_strdup(f)) == NULL) { \ + event_warn("%s: strdup()", __func__); \ + return -1; \ + } \ + } else { \ + uri->f = NULL; \ + } \ + } while(0) + +int +evhttp_uri_set_scheme(struct evhttp_uri *uri, const char *scheme) +{ + if (scheme && !scheme_ok(scheme, scheme+strlen(scheme))) + return -1; + + URI_SET_STR_(scheme); + return 0; +} +int +evhttp_uri_set_userinfo(struct evhttp_uri *uri, const char *userinfo) +{ + if (userinfo && !userinfo_ok(userinfo, userinfo+strlen(userinfo))) + return -1; + URI_SET_STR_(userinfo); + return 0; +} +int +evhttp_uri_set_host(struct evhttp_uri *uri, const char *host) +{ + if (host) { + if (host[0] == '[') { + if (! bracket_addr_ok(host, host+strlen(host))) + return -1; + } else { + if (! regname_ok(host, host+strlen(host))) + return -1; + } + } + + URI_SET_STR_(host); + return 0; +} +int +evhttp_uri_set_port(struct evhttp_uri *uri, int port) +{ + if (port < -1) + return -1; + uri->port = port; + return 0; +} +#define end_of_cpath(cp,p,f) \ + ((const char*)(end_of_path(((char*)(cp)), (p), (f)))) + +int +evhttp_uri_set_path(struct evhttp_uri *uri, const char *path) +{ + if (path && end_of_cpath(path, PART_PATH, uri->flags) != path+strlen(path)) + return -1; + + URI_SET_STR_(path); + return 0; +} +int +evhttp_uri_set_query(struct evhttp_uri *uri, const char *query) +{ + if (query && end_of_cpath(query, PART_QUERY, uri->flags) != query+strlen(query)) + return -1; + URI_SET_STR_(query); + return 0; +} +int +evhttp_uri_set_fragment(struct evhttp_uri *uri, const char *fragment) +{ + if (fragment && end_of_cpath(fragment, PART_FRAGMENT, uri->flags) != fragment+strlen(fragment)) + return -1; + URI_SET_STR_(fragment); + return 0; +} diff --git a/contrib/ntp/sntp/libevent/include/evdns.h b/contrib/ntp/sntp/libevent/include/evdns.h new file mode 100644 index 000000000..8672db036 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/evdns.h @@ -0,0 +1,45 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT1_EVDNS_H_INCLUDED_ +#define EVENT1_EVDNS_H_INCLUDED_ + +/** @file evdns.h + + A dns subsystem for Libevent. + + The header is deprecated in Libevent 2.0 and later; please + use instead. Depending on what functionality you + need, you may also want to include more of the other + headers. + */ + +#include +#include +#include +#include + +#endif /* EVENT1_EVDNS_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event.h b/contrib/ntp/sntp/libevent/include/event.h new file mode 100644 index 000000000..3a1b0c2c0 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event.h @@ -0,0 +1,85 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT1_EVENT_H_INCLUDED_ +#define EVENT1_EVENT_H_INCLUDED_ + +/** @file event.h + + A library for writing event-driven network servers. + + The header is deprecated in Libevent 2.0 and later; please + use instead. Depending on what functionality you + need, you may also want to include more of the other event2/ + headers. + */ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#ifdef EVENT__HAVE_STDINT_H +#include +#endif +#include + +/* For int types. */ +#include + +#ifdef _WIN32 +#ifndef WIN32_LEAN_AND_MEAN +#define WIN32_LEAN_AND_MEAN +#endif +#include +#include +#undef WIN32_LEAN_AND_MEAN +typedef unsigned char u_char; +typedef unsigned short u_short; +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT1_EVENT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/buffer.h b/contrib/ntp/sntp/libevent/include/event2/buffer.h new file mode 100644 index 000000000..468588b9f --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/buffer.h @@ -0,0 +1,1076 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_BUFFER_H_INCLUDED_ +#define EVENT2_BUFFER_H_INCLUDED_ + +/** @file event2/buffer.h + + Functions for buffering data for network sending or receiving. + + An evbuffer can be used for preparing data before sending it to + the network or conversely for reading data from the network. + Evbuffers try to avoid memory copies as much as possible. As a + result, evbuffers can be used to pass data around without actually + incurring the overhead of copying the data. + + A new evbuffer can be allocated with evbuffer_new(), and can be + freed with evbuffer_free(). Most users will be using evbuffers via + the bufferevent interface. To access a bufferevent's evbuffers, use + bufferevent_get_input() and bufferevent_get_output(). + + There are several guidelines for using evbuffers. + + - if you already know how much data you are going to add as a result + of calling evbuffer_add() multiple times, it makes sense to use + evbuffer_expand() first to make sure that enough memory is allocated + before hand. + + - evbuffer_add_buffer() adds the contents of one buffer to the other + without incurring any unnecessary memory copies. + + - evbuffer_add() and evbuffer_add_buffer() do not mix very well: + if you use them, you will wind up with fragmented memory in your + buffer. + + - For high-performance code, you may want to avoid copying data into and out + of buffers. You can skip the copy step by using + evbuffer_reserve_space()/evbuffer_commit_space() when writing into a + buffer, and evbuffer_peek() when reading. + + In Libevent 2.0 and later, evbuffers are represented using a linked + list of memory chunks, with pointers to the first and last chunk in + the chain. + + As the contents of an evbuffer can be stored in multiple different + memory blocks, it cannot be accessed directly. Instead, evbuffer_pullup() + can be used to force a specified number of bytes to be contiguous. This + will cause memory reallocation and memory copies if the data is split + across multiple blocks. It is more efficient, however, to use + evbuffer_peek() if you don't require that the memory to be contiguous. + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_UIO_H +#include +#endif +#include + +/** + An evbuffer is an opaque data type for efficiently buffering data to be + sent or received on the network. + + @see event2/event.h for more information +*/ +struct evbuffer +#ifdef EVENT_IN_DOXYGEN_ +{} +#endif +; + +/** + Pointer to a position within an evbuffer. + + Used when repeatedly searching through a buffer. Calling any function + that modifies or re-packs the buffer contents may invalidate all + evbuffer_ptrs for that buffer. Do not modify or contruct these values + except with evbuffer_ptr_set. + + An evbuffer_ptr can represent any position from the start of a buffer up + to a position immediately after the end of a buffer. + + @see evbuffer_ptr_set() + */ +struct evbuffer_ptr { + ev_ssize_t pos; + + /* Do not alter or rely on the values of fields: they are for internal + * use */ + struct { + void *chain; + size_t pos_in_chain; + } internal_; +}; + +/** Describes a single extent of memory inside an evbuffer. Used for + direct-access functions. + + @see evbuffer_reserve_space, evbuffer_commit_space, evbuffer_peek + */ +#ifdef EVENT__HAVE_SYS_UIO_H +#define evbuffer_iovec iovec +/* Internal use -- defined only if we are using the native struct iovec */ +#define EVBUFFER_IOVEC_IS_NATIVE_ +#else +struct evbuffer_iovec { + /** The start of the extent of memory. */ + void *iov_base; + /** The length of the extent of memory. */ + size_t iov_len; +}; +#endif + +/** + Allocate storage for a new evbuffer. + + @return a pointer to a newly allocated evbuffer struct, or NULL if an error + occurred + */ +EVENT2_EXPORT_SYMBOL +struct evbuffer *evbuffer_new(void); +/** + Deallocate storage for an evbuffer. + + @param buf pointer to the evbuffer to be freed + */ +EVENT2_EXPORT_SYMBOL +void evbuffer_free(struct evbuffer *buf); + +/** + Enable locking on an evbuffer so that it can safely be used by multiple + threads at the same time. + + NOTE: when locking is enabled, the lock will be held when callbacks are + invoked. This could result in deadlock if you aren't careful. Plan + accordingly! + + @param buf An evbuffer to make lockable. + @param lock A lock object, or NULL if we should allocate our own. + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_enable_locking(struct evbuffer *buf, void *lock); + +/** + Acquire the lock on an evbuffer. Has no effect if locking was not enabled + with evbuffer_enable_locking. +*/ +EVENT2_EXPORT_SYMBOL +void evbuffer_lock(struct evbuffer *buf); + +/** + Release the lock on an evbuffer. Has no effect if locking was not enabled + with evbuffer_enable_locking. +*/ +EVENT2_EXPORT_SYMBOL +void evbuffer_unlock(struct evbuffer *buf); + + +/** If this flag is set, then we will not use evbuffer_peek(), + * evbuffer_remove(), evbuffer_remove_buffer(), and so on to read bytes + * from this buffer: we'll only take bytes out of this buffer by + * writing them to the network (as with evbuffer_write_atmost), by + * removing them without observing them (as with evbuffer_drain), + * or by copying them all out at once (as with evbuffer_add_buffer). + * + * Using this option allows the implementation to use sendfile-based + * operations for evbuffer_add_file(); see that function for more + * information. + * + * This flag is on by default for bufferevents that can take advantage + * of it; you should never actually need to set it on a bufferevent's + * output buffer. + */ +#define EVBUFFER_FLAG_DRAINS_TO_FD 1 + +/** Change the flags that are set for an evbuffer by adding more. + * + * @param buffer the evbuffer that the callback is watching. + * @param cb the callback whose status we want to change. + * @param flags One or more EVBUFFER_FLAG_* options + * @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_set_flags(struct evbuffer *buf, ev_uint64_t flags); +/** Change the flags that are set for an evbuffer by removing some. + * + * @param buffer the evbuffer that the callback is watching. + * @param cb the callback whose status we want to change. + * @param flags One or more EVBUFFER_FLAG_* options + * @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_clear_flags(struct evbuffer *buf, ev_uint64_t flags); + +/** + Returns the total number of bytes stored in the evbuffer + + @param buf pointer to the evbuffer + @return the number of bytes stored in the evbuffer +*/ +EVENT2_EXPORT_SYMBOL +size_t evbuffer_get_length(const struct evbuffer *buf); + +/** + Returns the number of contiguous available bytes in the first buffer chain. + + This is useful when processing data that might be split into multiple + chains, or that might all be in the first chain. Calls to + evbuffer_pullup() that cause reallocation and copying of data can thus be + avoided. + + @param buf pointer to the evbuffer + @return 0 if no data is available, otherwise the number of available bytes + in the first buffer chain. +*/ +EVENT2_EXPORT_SYMBOL +size_t evbuffer_get_contiguous_space(const struct evbuffer *buf); + +/** + Expands the available space in an evbuffer. + + Expands the available space in the evbuffer to at least datlen, so that + appending datlen additional bytes will not require any new allocations. + + @param buf the evbuffer to be expanded + @param datlen the new minimum length requirement + @return 0 if successful, or -1 if an error occurred +*/ +EVENT2_EXPORT_SYMBOL +int evbuffer_expand(struct evbuffer *buf, size_t datlen); + +/** + Reserves space in the last chain or chains of an evbuffer. + + Makes space available in the last chain or chains of an evbuffer that can + be arbitrarily written to by a user. The space does not become + available for reading until it has been committed with + evbuffer_commit_space(). + + The space is made available as one or more extents, represented by + an initial pointer and a length. You can force the memory to be + available as only one extent. Allowing more extents, however, makes the + function more efficient. + + Multiple subsequent calls to this function will make the same space + available until evbuffer_commit_space() has been called. + + It is an error to do anything that moves around the buffer's internal + memory structures before committing the space. + + NOTE: The code currently does not ever use more than two extents. + This may change in future versions. + + @param buf the evbuffer in which to reserve space. + @param size how much space to make available, at minimum. The + total length of the extents may be greater than the requested + length. + @param vec an array of one or more evbuffer_iovec structures to + hold pointers to the reserved extents of memory. + @param n_vec The length of the vec array. Must be at least 1; + 2 is more efficient. + @return the number of provided extents, or -1 on error. + @see evbuffer_commit_space() +*/ +EVENT2_EXPORT_SYMBOL +int +evbuffer_reserve_space(struct evbuffer *buf, ev_ssize_t size, + struct evbuffer_iovec *vec, int n_vec); + +/** + Commits previously reserved space. + + Commits some of the space previously reserved with + evbuffer_reserve_space(). It then becomes available for reading. + + This function may return an error if the pointer in the extents do + not match those returned from evbuffer_reserve_space, or if data + has been added to the buffer since the space was reserved. + + If you want to commit less data than you got reserved space for, + modify the iov_len pointer of the appropriate extent to a smaller + value. Note that you may have received more space than you + requested if it was available! + + @param buf the evbuffer in which to reserve space. + @param vec one or two extents returned by evbuffer_reserve_space. + @param n_vecs the number of extents. + @return 0 on success, -1 on error + @see evbuffer_reserve_space() +*/ +EVENT2_EXPORT_SYMBOL +int evbuffer_commit_space(struct evbuffer *buf, + struct evbuffer_iovec *vec, int n_vecs); + +/** + Append data to the end of an evbuffer. + + @param buf the evbuffer to be appended to + @param data pointer to the beginning of the data buffer + @param datlen the number of bytes to be copied from the data buffer + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_add(struct evbuffer *buf, const void *data, size_t datlen); + + +/** + Read data from an evbuffer and drain the bytes read. + + If more bytes are requested than are available in the evbuffer, we + only extract as many bytes as were available. + + @param buf the evbuffer to be read from + @param data the destination buffer to store the result + @param datlen the maximum size of the destination buffer + @return the number of bytes read, or -1 if we can't drain the buffer. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_remove(struct evbuffer *buf, void *data, size_t datlen); + +/** + Read data from an evbuffer, and leave the buffer unchanged. + + If more bytes are requested than are available in the evbuffer, we + only extract as many bytes as were available. + + @param buf the evbuffer to be read from + @param data_out the destination buffer to store the result + @param datlen the maximum size of the destination buffer + @return the number of bytes read, or -1 if we can't drain the buffer. + */ +EVENT2_EXPORT_SYMBOL +ev_ssize_t evbuffer_copyout(struct evbuffer *buf, void *data_out, size_t datlen); + +/** + Read data from the middle of an evbuffer, and leave the buffer unchanged. + + If more bytes are requested than are available in the evbuffer, we + only extract as many bytes as were available. + + @param buf the evbuffer to be read from + @param pos the position to start reading from + @param data_out the destination buffer to store the result + @param datlen the maximum size of the destination buffer + @return the number of bytes read, or -1 if we can't drain the buffer. + */ +EVENT2_EXPORT_SYMBOL +ev_ssize_t evbuffer_copyout_from(struct evbuffer *buf, const struct evbuffer_ptr *pos, void *data_out, size_t datlen); + +/** + Read data from an evbuffer into another evbuffer, draining + the bytes from the source buffer. This function avoids copy + operations to the extent possible. + + If more bytes are requested than are available in src, the src + buffer is drained completely. + + @param src the evbuffer to be read from + @param dst the destination evbuffer to store the result into + @param datlen the maximum numbers of bytes to transfer + @return the number of bytes read + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_remove_buffer(struct evbuffer *src, struct evbuffer *dst, + size_t datlen); + +/** Used to tell evbuffer_readln what kind of line-ending to look for. + */ +enum evbuffer_eol_style { + /** Any sequence of CR and LF characters is acceptable as an + * EOL. + * + * Note that this style can produce ambiguous results: the + * sequence "CRLF" will be treated as a single EOL if it is + * all in the buffer at once, but if you first read a CR from + * the network and later read an LF from the network, it will + * be treated as two EOLs. + */ + EVBUFFER_EOL_ANY, + /** An EOL is an LF, optionally preceded by a CR. This style is + * most useful for implementing text-based internet protocols. */ + EVBUFFER_EOL_CRLF, + /** An EOL is a CR followed by an LF. */ + EVBUFFER_EOL_CRLF_STRICT, + /** An EOL is a LF. */ + EVBUFFER_EOL_LF, + /** An EOL is a NUL character (that is, a single byte with value 0) */ + EVBUFFER_EOL_NUL +}; + +/** + * Read a single line from an evbuffer. + * + * Reads a line terminated by an EOL as determined by the evbuffer_eol_style + * argument. Returns a newly allocated nul-terminated string; the caller must + * free the returned value. The EOL is not included in the returned string. + * + * @param buffer the evbuffer to read from + * @param n_read_out if non-NULL, points to a size_t that is set to the + * number of characters in the returned string. This is useful for + * strings that can contain NUL characters. + * @param eol_style the style of line-ending to use. + * @return pointer to a single line, or NULL if an error occurred + */ +EVENT2_EXPORT_SYMBOL +char *evbuffer_readln(struct evbuffer *buffer, size_t *n_read_out, + enum evbuffer_eol_style eol_style); + +/** + Move all data from one evbuffer into another evbuffer. + + This is a destructive add. The data from one buffer moves into + the other buffer. However, no unnecessary memory copies occur. + + @param outbuf the output buffer + @param inbuf the input buffer + @return 0 if successful, or -1 if an error occurred + + @see evbuffer_remove_buffer() + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_add_buffer(struct evbuffer *outbuf, struct evbuffer *inbuf); + +/** + Copy data from one evbuffer into another evbuffer. + + This is a non-destructive add. The data from one buffer is copied + into the other buffer. However, no unnecessary memory copies occur. + + Note that buffers already containing buffer references can't be added + to other buffers. + + @param outbuf the output buffer + @param inbuf the input buffer + @return 0 if successful, or -1 if an error occurred + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_add_buffer_reference(struct evbuffer *outbuf, + struct evbuffer *inbuf); + +/** + A cleanup function for a piece of memory added to an evbuffer by + reference. + + @see evbuffer_add_reference() + */ +typedef void (*evbuffer_ref_cleanup_cb)(const void *data, + size_t datalen, void *extra); + +/** + Reference memory into an evbuffer without copying. + + The memory needs to remain valid until all the added data has been + read. This function keeps just a reference to the memory without + actually incurring the overhead of a copy. + + @param outbuf the output buffer + @param data the memory to reference + @param datlen how memory to reference + @param cleanupfn callback to be invoked when the memory is no longer + referenced by this evbuffer. + @param cleanupfn_arg optional argument to the cleanup callback + @return 0 if successful, or -1 if an error occurred + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_add_reference(struct evbuffer *outbuf, + const void *data, size_t datlen, + evbuffer_ref_cleanup_cb cleanupfn, void *cleanupfn_arg); + +/** + Copy data from a file into the evbuffer for writing to a socket. + + This function avoids unnecessary data copies between userland and + kernel. If sendfile is available and the EVBUFFER_FLAG_DRAINS_TO_FD + flag is set, it uses those functions. Otherwise, it tries to use + mmap (or CreateFileMapping on Windows). + + The function owns the resulting file descriptor and will close it + when finished transferring data. + + The results of using evbuffer_remove() or evbuffer_pullup() on + evbuffers whose data was added using this function are undefined. + + For more fine-grained control, use evbuffer_add_file_segment. + + @param outbuf the output buffer + @param fd the file descriptor + @param offset the offset from which to read data + @param length how much data to read, or -1 to read as much as possible. + (-1 requires that 'fd' support fstat.) + @return 0 if successful, or -1 if an error occurred +*/ + +EVENT2_EXPORT_SYMBOL +int evbuffer_add_file(struct evbuffer *outbuf, int fd, ev_off_t offset, + ev_off_t length); + +/** + An evbuffer_file_segment holds a reference to a range of a file -- + possibly the whole file! -- for use in writing from an evbuffer to a + socket. It could be implemented with mmap, sendfile, splice, or (if all + else fails) by just pulling all the data into RAM. A single + evbuffer_file_segment can be added more than once, and to more than one + evbuffer. + */ +struct evbuffer_file_segment; + +/** + Flag for creating evbuffer_file_segment: If this flag is set, then when + the evbuffer_file_segment is freed and no longer in use by any + evbuffer, the underlying fd is closed. + */ +#define EVBUF_FS_CLOSE_ON_FREE 0x01 +/** + Flag for creating evbuffer_file_segment: Disable memory-map based + implementations. + */ +#define EVBUF_FS_DISABLE_MMAP 0x02 +/** + Flag for creating evbuffer_file_segment: Disable direct fd-to-fd + implementations (including sendfile and splice). + + You might want to use this option if data needs to be taken from the + evbuffer by any means other than writing it to the network: the sendfile + backend is fast, but it only works for sending files directly to the + network. + */ +#define EVBUF_FS_DISABLE_SENDFILE 0x04 +/** + Flag for creating evbuffer_file_segment: Do not allocate a lock for this + segment. If this option is set, then neither the segment nor any + evbuffer it is added to may ever be accessed from more than one thread + at a time. + */ +#define EVBUF_FS_DISABLE_LOCKING 0x08 + +/** + A cleanup function for a evbuffer_file_segment added to an evbuffer + for reference. + */ +typedef void (*evbuffer_file_segment_cleanup_cb)( + struct evbuffer_file_segment const* seg, int flags, void* arg); + +/** + Create and return a new evbuffer_file_segment for reading data from a + file and sending it out via an evbuffer. + + This function avoids unnecessary data copies between userland and + kernel. Where available, it uses sendfile or splice. + + The file descriptor must not be closed so long as any evbuffer is using + this segment. + + The results of using evbuffer_remove() or evbuffer_pullup() or any other + function that reads bytes from an evbuffer on any evbuffer containing + the newly returned segment are undefined, unless you pass the + EVBUF_FS_DISABLE_SENDFILE flag to this function. + + @param fd an open file to read from. + @param offset an index within the file at which to start reading + @param length how much data to read, or -1 to read as much as possible. + (-1 requires that 'fd' support fstat.) + @param flags any number of the EVBUF_FS_* flags + @return a new evbuffer_file_segment, or NULL on failure. + **/ +EVENT2_EXPORT_SYMBOL +struct evbuffer_file_segment *evbuffer_file_segment_new( + int fd, ev_off_t offset, ev_off_t length, unsigned flags); + +/** + Free an evbuffer_file_segment + + It is safe to call this function even if the segment has been added to + one or more evbuffers. The evbuffer_file_segment will not be freed + until no more references to it exist. + */ +EVENT2_EXPORT_SYMBOL +void evbuffer_file_segment_free(struct evbuffer_file_segment *seg); + +/** + Add cleanup callback and argument for the callback to an + evbuffer_file_segment. + + The cleanup callback will be invoked when no more references to the + evbuffer_file_segment exist. + **/ +EVENT2_EXPORT_SYMBOL +void evbuffer_file_segment_add_cleanup_cb(struct evbuffer_file_segment *seg, + evbuffer_file_segment_cleanup_cb cb, void* arg); + +/** + Insert some or all of an evbuffer_file_segment at the end of an evbuffer + + Note that the offset and length parameters of this function have a + different meaning from those provided to evbuffer_file_segment_new: When + you create the segment, the offset is the offset _within the file_, and + the length is the length _of the segment_, whereas when you add a + segment to an evbuffer, the offset is _within the segment_ and the + length is the length of the _part of the segment you want to use. + + In other words, if you have a 10 KiB file, and you create an + evbuffer_file_segment for it with offset 20 and length 1000, it will + refer to bytes 20..1019 inclusive. If you then pass this segment to + evbuffer_add_file_segment and specify an offset of 20 and a length of + 50, you will be adding bytes 40..99 inclusive. + + @param buf the evbuffer to append to + @param seg the segment to add + @param offset the offset within the segment to start from + @param length the amount of data to add, or -1 to add it all. + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_add_file_segment(struct evbuffer *buf, + struct evbuffer_file_segment *seg, ev_off_t offset, ev_off_t length); + +/** + Append a formatted string to the end of an evbuffer. + + The string is formated as printf. + + @param buf the evbuffer that will be appended to + @param fmt a format string + @param ... arguments that will be passed to printf(3) + @return The number of bytes added if successful, or -1 if an error occurred. + + @see evutil_printf(), evbuffer_add_vprintf() + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_add_printf(struct evbuffer *buf, const char *fmt, ...) +#ifdef __GNUC__ + __attribute__((format(printf, 2, 3))) +#endif +; + +/** + Append a va_list formatted string to the end of an evbuffer. + + @param buf the evbuffer that will be appended to + @param fmt a format string + @param ap a varargs va_list argument array that will be passed to vprintf(3) + @return The number of bytes added if successful, or -1 if an error occurred. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_add_vprintf(struct evbuffer *buf, const char *fmt, va_list ap) +#ifdef __GNUC__ + __attribute__((format(printf, 2, 0))) +#endif +; + + +/** + Remove a specified number of bytes data from the beginning of an evbuffer. + + @param buf the evbuffer to be drained + @param len the number of bytes to drain from the beginning of the buffer + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_drain(struct evbuffer *buf, size_t len); + + +/** + Write the contents of an evbuffer to a file descriptor. + + The evbuffer will be drained after the bytes have been successfully written. + + @param buffer the evbuffer to be written and drained + @param fd the file descriptor to be written to + @return the number of bytes written, or -1 if an error occurred + @see evbuffer_read() + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_write(struct evbuffer *buffer, evutil_socket_t fd); + +/** + Write some of the contents of an evbuffer to a file descriptor. + + The evbuffer will be drained after the bytes have been successfully written. + + @param buffer the evbuffer to be written and drained + @param fd the file descriptor to be written to + @param howmuch the largest allowable number of bytes to write, or -1 + to write as many bytes as we can. + @return the number of bytes written, or -1 if an error occurred + @see evbuffer_read() + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_write_atmost(struct evbuffer *buffer, evutil_socket_t fd, + ev_ssize_t howmuch); + +/** + Read from a file descriptor and store the result in an evbuffer. + + @param buffer the evbuffer to store the result + @param fd the file descriptor to read from + @param howmuch the number of bytes to be read + @return the number of bytes read, or -1 if an error occurred + @see evbuffer_write() + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_read(struct evbuffer *buffer, evutil_socket_t fd, int howmuch); + +/** + Search for a string within an evbuffer. + + @param buffer the evbuffer to be searched + @param what the string to be searched for + @param len the length of the search string + @param start NULL or a pointer to a valid struct evbuffer_ptr. + @return a struct evbuffer_ptr whose 'pos' field has the offset of the + first occurrence of the string in the buffer after 'start'. The 'pos' + field of the result is -1 if the string was not found. + */ +EVENT2_EXPORT_SYMBOL +struct evbuffer_ptr evbuffer_search(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start); + +/** + Search for a string within part of an evbuffer. + + @param buffer the evbuffer to be searched + @param what the string to be searched for + @param len the length of the search string + @param start NULL or a pointer to a valid struct evbuffer_ptr that + indicates where we should start searching. + @param end NULL or a pointer to a valid struct evbuffer_ptr that + indicates where we should stop searching. + @return a struct evbuffer_ptr whose 'pos' field has the offset of the + first occurrence of the string in the buffer after 'start'. The 'pos' + field of the result is -1 if the string was not found. + */ +EVENT2_EXPORT_SYMBOL +struct evbuffer_ptr evbuffer_search_range(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start, const struct evbuffer_ptr *end); + +/** + Defines how to adjust an evbuffer_ptr by evbuffer_ptr_set() + + @see evbuffer_ptr_set() */ +enum evbuffer_ptr_how { + /** Sets the pointer to the position; can be called on with an + uninitialized evbuffer_ptr. */ + EVBUFFER_PTR_SET, + /** Advances the pointer by adding to the current position. */ + EVBUFFER_PTR_ADD +}; + +/** + Sets the search pointer in the buffer to position. + + There are two ways to use this function: you can call + evbuffer_ptr_set(buf, &pos, N, EVBUFFER_PTR_SET) + to move 'pos' to a position 'N' bytes after the start of the buffer, or + evbuffer_ptr_set(buf, &pos, N, EVBUFFER_PTR_ADD) + to move 'pos' forward by 'N' bytes. + + If evbuffer_ptr is not initialized, this function can only be called + with EVBUFFER_PTR_SET. + + An evbuffer_ptr can represent any position from the start of the buffer to + a position immediately after the end of the buffer. + + @param buffer the evbuffer to be search + @param ptr a pointer to a struct evbuffer_ptr + @param position the position at which to start the next search + @param how determines how the pointer should be manipulated. + @returns 0 on success or -1 otherwise +*/ +EVENT2_EXPORT_SYMBOL +int +evbuffer_ptr_set(struct evbuffer *buffer, struct evbuffer_ptr *ptr, + size_t position, enum evbuffer_ptr_how how); + +/** + Search for an end-of-line string within an evbuffer. + + @param buffer the evbuffer to be searched + @param start NULL or a pointer to a valid struct evbuffer_ptr to start + searching at. + @param eol_len_out If non-NULL, the pointed-to value will be set to + the length of the end-of-line string. + @param eol_style The kind of EOL to look for; see evbuffer_readln() for + more information + @return a struct evbuffer_ptr whose 'pos' field has the offset of the + first occurrence EOL in the buffer after 'start'. The 'pos' + field of the result is -1 if the string was not found. + */ +EVENT2_EXPORT_SYMBOL +struct evbuffer_ptr evbuffer_search_eol(struct evbuffer *buffer, + struct evbuffer_ptr *start, size_t *eol_len_out, + enum evbuffer_eol_style eol_style); + +/** Function to peek at data inside an evbuffer without removing it or + copying it out. + + Pointers to the data are returned by filling the 'vec_out' array + with pointers to one or more extents of data inside the buffer. + + The total data in the extents that you get back may be more than + you requested (if there is more data last extent than you asked + for), or less (if you do not provide enough evbuffer_iovecs, or if + the buffer does not have as much data as you asked to see). + + @param buffer the evbuffer to peek into, + @param len the number of bytes to try to peek. If len is negative, we + will try to fill as much of vec_out as we can. If len is negative + and vec_out is not provided, we return the number of evbuffer_iovecs + that would be needed to get all the data in the buffer. + @param start_at an evbuffer_ptr indicating the point at which we + should start looking for data. NULL means, "At the start of the + buffer." + @param vec_out an array of evbuffer_iovec + @param n_vec the length of vec_out. If 0, we only count how many + extents would be necessary to point to the requested amount of + data. + @return The number of extents needed. This may be less than n_vec + if we didn't need all the evbuffer_iovecs we were given, or more + than n_vec if we would need more to return all the data that was + requested. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_peek(struct evbuffer *buffer, ev_ssize_t len, + struct evbuffer_ptr *start_at, + struct evbuffer_iovec *vec_out, int n_vec); + + +/** Structure passed to an evbuffer_cb_func evbuffer callback + + @see evbuffer_cb_func, evbuffer_add_cb() + */ +struct evbuffer_cb_info { + /** The number of bytes in this evbuffer when callbacks were last + * invoked. */ + size_t orig_size; + /** The number of bytes added since callbacks were last invoked. */ + size_t n_added; + /** The number of bytes removed since callbacks were last invoked. */ + size_t n_deleted; +}; + +/** Type definition for a callback that is invoked whenever data is added or + removed from an evbuffer. + + An evbuffer may have one or more callbacks set at a time. The order + in which they are executed is undefined. + + A callback function may add more callbacks, or remove itself from the + list of callbacks, or add or remove data from the buffer. It may not + remove another callback from the list. + + If a callback adds or removes data from the buffer or from another + buffer, this can cause a recursive invocation of your callback or + other callbacks. If you ask for an infinite loop, you might just get + one: watch out! + + @param buffer the buffer whose size has changed + @param info a structure describing how the buffer changed. + @param arg a pointer to user data +*/ +typedef void (*evbuffer_cb_func)(struct evbuffer *buffer, const struct evbuffer_cb_info *info, void *arg); + +struct evbuffer_cb_entry; +/** Add a new callback to an evbuffer. + + Subsequent calls to evbuffer_add_cb() add new callbacks. To remove this + callback, call evbuffer_remove_cb or evbuffer_remove_cb_entry. + + @param buffer the evbuffer to be monitored + @param cb the callback function to invoke when the evbuffer is modified, + or NULL to remove all callbacks. + @param cbarg an argument to be provided to the callback function + @return a handle to the callback on success, or NULL on failure. + */ +EVENT2_EXPORT_SYMBOL +struct evbuffer_cb_entry *evbuffer_add_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg); + +/** Remove a callback from an evbuffer, given a handle returned from + evbuffer_add_cb. + + Calling this function invalidates the handle. + + @return 0 if a callback was removed, or -1 if no matching callback was + found. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_remove_cb_entry(struct evbuffer *buffer, + struct evbuffer_cb_entry *ent); + +/** Remove a callback from an evbuffer, given the function and argument + used to add it. + + @return 0 if a callback was removed, or -1 if no matching callback was + found. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_remove_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg); + +/** If this flag is not set, then a callback is temporarily disabled, and + * should not be invoked. + * + * @see evbuffer_cb_set_flags(), evbuffer_cb_clear_flags() + */ +#define EVBUFFER_CB_ENABLED 1 + +/** Change the flags that are set for a callback on a buffer by adding more. + + @param buffer the evbuffer that the callback is watching. + @param cb the callback whose status we want to change. + @param flags EVBUFFER_CB_ENABLED to re-enable the callback. + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_cb_set_flags(struct evbuffer *buffer, + struct evbuffer_cb_entry *cb, ev_uint32_t flags); + +/** Change the flags that are set for a callback on a buffer by removing some + + @param buffer the evbuffer that the callback is watching. + @param cb the callback whose status we want to change. + @param flags EVBUFFER_CB_ENABLED to disable the callback. + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_cb_clear_flags(struct evbuffer *buffer, + struct evbuffer_cb_entry *cb, ev_uint32_t flags); + +#if 0 +/** Postpone calling a given callback until unsuspend is called later. + + This is different from disabling the callback, since the callback will get + invoked later if the buffer size changes between now and when we unsuspend + it. + + @param the buffer that the callback is watching. + @param cb the callback we want to suspend. + */ +EVENT2_EXPORT_SYMBOL +void evbuffer_cb_suspend(struct evbuffer *buffer, struct evbuffer_cb_entry *cb); +/** Stop postponing a callback that we postponed with evbuffer_cb_suspend. + + If data was added to or removed from the buffer while the callback was + suspended, the callback will get called once now. + + @param the buffer that the callback is watching. + @param cb the callback we want to stop suspending. + */ +EVENT2_EXPORT_SYMBOL +void evbuffer_cb_unsuspend(struct evbuffer *buffer, struct evbuffer_cb_entry *cb); +#endif + +/** + Makes the data at the beginning of an evbuffer contiguous. + + @param buf the evbuffer to make contiguous + @param size the number of bytes to make contiguous, or -1 to make the + entire buffer contiguous. + @return a pointer to the contiguous memory array, or NULL if param size + requested more data than is present in the buffer. +*/ + +EVENT2_EXPORT_SYMBOL +unsigned char *evbuffer_pullup(struct evbuffer *buf, ev_ssize_t size); + +/** + Prepends data to the beginning of the evbuffer + + @param buf the evbuffer to which to prepend data + @param data a pointer to the memory to prepend + @param size the number of bytes to prepend + @return 0 if successful, or -1 otherwise +*/ + +EVENT2_EXPORT_SYMBOL +int evbuffer_prepend(struct evbuffer *buf, const void *data, size_t size); + +/** + Prepends all data from the src evbuffer to the beginning of the dst + evbuffer. + + @param dst the evbuffer to which to prepend data + @param src the evbuffer to prepend; it will be emptied as a result + @return 0 if successful, or -1 otherwise +*/ +EVENT2_EXPORT_SYMBOL +int evbuffer_prepend_buffer(struct evbuffer *dst, struct evbuffer* src); + +/** + Prevent calls that modify an evbuffer from succeeding. A buffer may + frozen at the front, at the back, or at both the front and the back. + + If the front of a buffer is frozen, operations that drain data from + the front of the buffer, or that prepend data to the buffer, will + fail until it is unfrozen. If the back a buffer is frozen, operations + that append data from the buffer will fail until it is unfrozen. + + @param buf The buffer to freeze + @param at_front If true, we freeze the front of the buffer. If false, + we freeze the back. + @return 0 on success, -1 on failure. +*/ +EVENT2_EXPORT_SYMBOL +int evbuffer_freeze(struct evbuffer *buf, int at_front); +/** + Re-enable calls that modify an evbuffer. + + @param buf The buffer to un-freeze + @param at_front If true, we unfreeze the front of the buffer. If false, + we unfreeze the back. + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_unfreeze(struct evbuffer *buf, int at_front); + +struct event_base; +/** + Force all the callbacks on an evbuffer to be run, not immediately after + the evbuffer is altered, but instead from inside the event loop. + + This can be used to serialize all the callbacks to a single thread + of execution. + */ +EVENT2_EXPORT_SYMBOL +int evbuffer_defer_callbacks(struct evbuffer *buffer, struct event_base *base); + +/** + Append data from 1 or more iovec's to an evbuffer + + Calculates the number of bytes needed for an iovec structure and guarantees + all data will fit into a single chain. Can be used in lieu of functionality + which calls evbuffer_add() constantly before being used to increase + performance. + + @param buffer the destination buffer + @param vec the source iovec + @param n_vec the number of iovec structures. + @return the number of bytes successfully written to the output buffer. +*/ +EVENT2_EXPORT_SYMBOL +size_t evbuffer_add_iovec(struct evbuffer * buffer, struct evbuffer_iovec * vec, int n_vec); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_BUFFER_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/buffer_compat.h b/contrib/ntp/sntp/libevent/include/event2/buffer_compat.h new file mode 100644 index 000000000..c0bdd9d21 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/buffer_compat.h @@ -0,0 +1,115 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef EVENT2_BUFFER_COMPAT_H_INCLUDED_ +#define EVENT2_BUFFER_COMPAT_H_INCLUDED_ + +#include + +/** @file event2/buffer_compat.h + + Obsolete and deprecated versions of the functions in buffer.h: provided + only for backward compatibility. + */ + + +/** + Obsolete alias for evbuffer_readln(buffer, NULL, EOL_STYLE_ANY). + + @deprecated This function is deprecated because its behavior is not correct + for almost any protocol, and also because it's wholly subsumed by + evbuffer_readln(). + + @param buffer the evbuffer to read from + @return pointer to a single line, or NULL if an error occurred + +*/ +EVENT2_EXPORT_SYMBOL +char *evbuffer_readline(struct evbuffer *buffer); + +/** Type definition for a callback that is invoked whenever data is added or + removed from an evbuffer. + + An evbuffer may have one or more callbacks set at a time. The order + in which they are executed is undefined. + + A callback function may add more callbacks, or remove itself from the + list of callbacks, or add or remove data from the buffer. It may not + remove another callback from the list. + + If a callback adds or removes data from the buffer or from another + buffer, this can cause a recursive invocation of your callback or + other callbacks. If you ask for an infinite loop, you might just get + one: watch out! + + @param buffer the buffer whose size has changed + @param old_len the previous length of the buffer + @param new_len the current length of the buffer + @param arg a pointer to user data +*/ +typedef void (*evbuffer_cb)(struct evbuffer *buffer, size_t old_len, size_t new_len, void *arg); + +/** + Replace all callbacks on an evbuffer with a single new callback, or + remove them. + + Subsequent calls to evbuffer_setcb() replace callbacks set by previous + calls. Setting the callback to NULL removes any previously set callback. + + @deprecated This function is deprecated because it clears all previous + callbacks set on the evbuffer, which can cause confusing behavior if + multiple parts of the code all want to add their own callbacks on a + buffer. Instead, use evbuffer_add(), evbuffer_del(), and + evbuffer_setflags() to manage your own evbuffer callbacks without + interfering with callbacks set by others. + + @param buffer the evbuffer to be monitored + @param cb the callback function to invoke when the evbuffer is modified, + or NULL to remove all callbacks. + @param cbarg an argument to be provided to the callback function + */ +EVENT2_EXPORT_SYMBOL +void evbuffer_setcb(struct evbuffer *buffer, evbuffer_cb cb, void *cbarg); + + +/** + Find a string within an evbuffer. + + @param buffer the evbuffer to be searched + @param what the string to be searched for + @param len the length of the search string + @return a pointer to the beginning of the search string, or NULL if the search failed. + */ +EVENT2_EXPORT_SYMBOL +unsigned char *evbuffer_find(struct evbuffer *buffer, const unsigned char *what, size_t len); + +/** deprecated in favor of calling the functions directly */ +#define EVBUFFER_LENGTH(x) evbuffer_get_length(x) +/** deprecated in favor of calling the functions directly */ +#define EVBUFFER_DATA(x) evbuffer_pullup((x), -1) + +#endif + diff --git a/contrib/ntp/sntp/libevent/include/event2/bufferevent.h b/contrib/ntp/sntp/libevent/include/event2/bufferevent.h new file mode 100644 index 000000000..fe8a74d34 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/bufferevent.h @@ -0,0 +1,995 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_BUFFEREVENT_H_INCLUDED_ +#define EVENT2_BUFFEREVENT_H_INCLUDED_ + +/** + @file event2/bufferevent.h + + Functions for buffering data for network sending or receiving. Bufferevents + are higher level than evbuffers: each has an underlying evbuffer for reading + and one for writing, and callbacks that are invoked under certain + circumstances. + + A bufferevent provides input and output buffers that get filled and + drained automatically. The user of a bufferevent no longer deals + directly with the I/O, but instead is reading from input and writing + to output buffers. + + Once initialized, the bufferevent structure can be used repeatedly + with bufferevent_enable() and bufferevent_disable(). + + When reading is enabled, the bufferevent will try to read from the + file descriptor onto its input buffer, and call the read callback. + When writing is enabled, the bufferevent will try to write data onto its + file descriptor when the output buffer has enough data, and call the write + callback when the output buffer is sufficiently drained. + + Bufferevents come in several flavors, including: + +
      +
      Socket-based bufferevents
      +
      A bufferevent that reads and writes data onto a network + socket. Created with bufferevent_socket_new().
      + +
      Paired bufferevents
      +
      A pair of bufferevents that send and receive data to one + another without touching the network. Created with + bufferevent_pair_new().
      + +
      Filtering bufferevents
      +
      A bufferevent that transforms data, and sends or receives it + over another underlying bufferevent. Created with + bufferevent_filter_new().
      + +
      SSL-backed bufferevents
      +
      A bufferevent that uses the openssl library to send and + receive data over an encrypted connection. Created with + bufferevent_openssl_socket_new() or + bufferevent_openssl_filter_new().
      +
      + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +/** @name Bufferevent event codes + + These flags are passed as arguments to a bufferevent's event callback. + + @{ +*/ +#define BEV_EVENT_READING 0x01 /**< error encountered while reading */ +#define BEV_EVENT_WRITING 0x02 /**< error encountered while writing */ +#define BEV_EVENT_EOF 0x10 /**< eof file reached */ +#define BEV_EVENT_ERROR 0x20 /**< unrecoverable error encountered */ +#define BEV_EVENT_TIMEOUT 0x40 /**< user-specified timeout reached */ +#define BEV_EVENT_CONNECTED 0x80 /**< connect operation finished. */ +/**@}*/ + +/** + An opaque type for handling buffered IO + + @see event2/bufferevent.h + */ +struct bufferevent +#ifdef EVENT_IN_DOXYGEN_ +{} +#endif +; +struct event_base; +struct evbuffer; +struct sockaddr; + +/** + A read or write callback for a bufferevent. + + The read callback is triggered when new data arrives in the input + buffer and the amount of readable data exceed the low watermark + which is 0 by default. + + The write callback is triggered if the write buffer has been + exhausted or fell below its low watermark. + + @param bev the bufferevent that triggered the callback + @param ctx the user-specified context for this bufferevent + */ +typedef void (*bufferevent_data_cb)(struct bufferevent *bev, void *ctx); + +/** + An event/error callback for a bufferevent. + + The event callback is triggered if either an EOF condition or another + unrecoverable error was encountered. + + For bufferevents with deferred callbacks, this is a bitwise OR of all errors + that have happened on the bufferevent since the last callback invocation. + + @param bev the bufferevent for which the error condition was reached + @param what a conjunction of flags: BEV_EVENT_READING or BEV_EVENT_WRITING + to indicate if the error was encountered on the read or write path, + and one of the following flags: BEV_EVENT_EOF, BEV_EVENT_ERROR, + BEV_EVENT_TIMEOUT, BEV_EVENT_CONNECTED. + + @param ctx the user-specified context for this bufferevent +*/ +typedef void (*bufferevent_event_cb)(struct bufferevent *bev, short what, void *ctx); + +/** Options that can be specified when creating a bufferevent */ +enum bufferevent_options { + /** If set, we close the underlying file + * descriptor/bufferevent/whatever when this bufferevent is freed. */ + BEV_OPT_CLOSE_ON_FREE = (1<<0), + + /** If set, and threading is enabled, operations on this bufferevent + * are protected by a lock */ + BEV_OPT_THREADSAFE = (1<<1), + + /** If set, callbacks are run deferred in the event loop. */ + BEV_OPT_DEFER_CALLBACKS = (1<<2), + + /** If set, callbacks are executed without locks being held on the + * bufferevent. This option currently requires that + * BEV_OPT_DEFER_CALLBACKS also be set; a future version of Libevent + * might remove the requirement.*/ + BEV_OPT_UNLOCK_CALLBACKS = (1<<3) +}; + +/** + Create a new socket bufferevent over an existing socket. + + @param base the event base to associate with the new bufferevent. + @param fd the file descriptor from which data is read and written to. + This file descriptor is not allowed to be a pipe(2). + It is safe to set the fd to -1, so long as you later + set it with bufferevent_setfd or bufferevent_socket_connect(). + @param options Zero or more BEV_OPT_* flags + @return a pointer to a newly allocated bufferevent struct, or NULL if an + error occurred + @see bufferevent_free() + */ +EVENT2_EXPORT_SYMBOL +struct bufferevent *bufferevent_socket_new(struct event_base *base, evutil_socket_t fd, int options); + +/** + Launch a connect() attempt with a socket-based bufferevent. + + When the connect succeeds, the eventcb will be invoked with + BEV_EVENT_CONNECTED set. + + If the bufferevent does not already have a socket set, we allocate a new + socket here and make it nonblocking before we begin. + + If no address is provided, we assume that the socket is already connecting, + and configure the bufferevent so that a BEV_EVENT_CONNECTED event will be + yielded when it is done connecting. + + @param bufev an existing bufferevent allocated with + bufferevent_socket_new(). + @param addr the address we should connect to + @param socklen The length of the address + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_socket_connect(struct bufferevent *, struct sockaddr *, int); + +struct evdns_base; +/** + Resolve the hostname 'hostname' and connect to it as with + bufferevent_socket_connect(). + + @param bufev An existing bufferevent allocated with bufferevent_socket_new() + @param evdns_base Optionally, an evdns_base to use for resolving hostnames + asynchronously. May be set to NULL for a blocking resolve. + @param family A preferred address family to resolve addresses to, or + AF_UNSPEC for no preference. Only AF_INET, AF_INET6, and AF_UNSPEC are + supported. + @param hostname The hostname to resolve; see below for notes on recognized + formats + @param port The port to connect to on the resolved address. + @return 0 if successful, -1 on failure. + + Recognized hostname formats are: + + www.example.com (hostname) + 1.2.3.4 (ipv4address) + ::1 (ipv6address) + [::1] ([ipv6address]) + + Performance note: If you do not provide an evdns_base, this function + may block while it waits for a DNS response. This is probably not + what you want. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_socket_connect_hostname(struct bufferevent *, + struct evdns_base *, int, const char *, int); + +/** + Return the error code for the last failed DNS lookup attempt made by + bufferevent_socket_connect_hostname(). + + @param bev The bufferevent object. + @return DNS error code. + @see evutil_gai_strerror() +*/ +EVENT2_EXPORT_SYMBOL +int bufferevent_socket_get_dns_error(struct bufferevent *bev); + +/** + Assign a bufferevent to a specific event_base. + + NOTE that only socket bufferevents support this function. + + @param base an event_base returned by event_init() + @param bufev a bufferevent struct returned by bufferevent_new() + or bufferevent_socket_new() + @return 0 if successful, or -1 if an error occurred + @see bufferevent_new() + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_base_set(struct event_base *base, struct bufferevent *bufev); + +/** + Return the event_base used by a bufferevent +*/ +EVENT2_EXPORT_SYMBOL +struct event_base *bufferevent_get_base(struct bufferevent *bev); + +/** + Assign a priority to a bufferevent. + + Only supported for socket bufferevents. + + @param bufev a bufferevent struct + @param pri the priority to be assigned + @return 0 if successful, or -1 if an error occurred + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_priority_set(struct bufferevent *bufev, int pri); + +/** + Return the priority of a bufferevent. + + Only supported for socket bufferevents + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_get_priority(const struct bufferevent *bufev); + +/** + Deallocate the storage associated with a bufferevent structure. + + If there is pending data to write on the bufferevent, it probably won't be + flushed before the bufferevent is freed. + + @param bufev the bufferevent structure to be freed. + */ +EVENT2_EXPORT_SYMBOL +void bufferevent_free(struct bufferevent *bufev); + + +/** + Changes the callbacks for a bufferevent. + + @param bufev the bufferevent object for which to change callbacks + @param readcb callback to invoke when there is data to be read, or NULL if + no callback is desired + @param writecb callback to invoke when the file descriptor is ready for + writing, or NULL if no callback is desired + @param eventcb callback to invoke when there is an event on the file + descriptor + @param cbarg an argument that will be supplied to each of the callbacks + (readcb, writecb, and errorcb) + @see bufferevent_new() + */ +EVENT2_EXPORT_SYMBOL +void bufferevent_setcb(struct bufferevent *bufev, + bufferevent_data_cb readcb, bufferevent_data_cb writecb, + bufferevent_event_cb eventcb, void *cbarg); + +/** + Retrieves the callbacks for a bufferevent. + + @param bufev the bufferevent to examine. + @param readcb_ptr if readcb_ptr is nonnull, *readcb_ptr is set to the current + read callback for the bufferevent. + @param writecb_ptr if writecb_ptr is nonnull, *writecb_ptr is set to the + current write callback for the bufferevent. + @param eventcb_ptr if eventcb_ptr is nonnull, *eventcb_ptr is set to the + current event callback for the bufferevent. + @param cbarg_ptr if cbarg_ptr is nonnull, *cbarg_ptr is set to the current + callback argument for the bufferevent. + @see buffervent_setcb() +*/ +EVENT2_EXPORT_SYMBOL +void bufferevent_getcb(struct bufferevent *bufev, + bufferevent_data_cb *readcb_ptr, + bufferevent_data_cb *writecb_ptr, + bufferevent_event_cb *eventcb_ptr, + void **cbarg_ptr); + +/** + Changes the file descriptor on which the bufferevent operates. + Not supported for all bufferevent types. + + @param bufev the bufferevent object for which to change the file descriptor + @param fd the file descriptor to operate on +*/ +EVENT2_EXPORT_SYMBOL +int bufferevent_setfd(struct bufferevent *bufev, evutil_socket_t fd); + +/** + Returns the file descriptor associated with a bufferevent, or -1 if + no file descriptor is associated with the bufferevent. + */ +EVENT2_EXPORT_SYMBOL +evutil_socket_t bufferevent_getfd(struct bufferevent *bufev); + +/** + Returns the underlying bufferevent associated with a bufferevent (if + the bufferevent is a wrapper), or NULL if there is no underlying bufferevent. + */ +EVENT2_EXPORT_SYMBOL +struct bufferevent *bufferevent_get_underlying(struct bufferevent *bufev); + +/** + Write data to a bufferevent buffer. + + The bufferevent_write() function can be used to write data to the file + descriptor. The data is appended to the output buffer and written to the + descriptor automatically as it becomes available for writing. + + @param bufev the bufferevent to be written to + @param data a pointer to the data to be written + @param size the length of the data, in bytes + @return 0 if successful, or -1 if an error occurred + @see bufferevent_write_buffer() + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_write(struct bufferevent *bufev, + const void *data, size_t size); + + +/** + Write data from an evbuffer to a bufferevent buffer. The evbuffer is + being drained as a result. + + @param bufev the bufferevent to be written to + @param buf the evbuffer to be written + @return 0 if successful, or -1 if an error occurred + @see bufferevent_write() + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_write_buffer(struct bufferevent *bufev, struct evbuffer *buf); + + +/** + Read data from a bufferevent buffer. + + The bufferevent_read() function is used to read data from the input buffer. + + @param bufev the bufferevent to be read from + @param data pointer to a buffer that will store the data + @param size the size of the data buffer, in bytes + @return the amount of data read, in bytes. + */ +EVENT2_EXPORT_SYMBOL +size_t bufferevent_read(struct bufferevent *bufev, void *data, size_t size); + +/** + Read data from a bufferevent buffer into an evbuffer. This avoids + memory copies. + + @param bufev the bufferevent to be read from + @param buf the evbuffer to which to add data + @return 0 if successful, or -1 if an error occurred. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_read_buffer(struct bufferevent *bufev, struct evbuffer *buf); + +/** + Returns the input buffer. + + The user MUST NOT set the callback on this buffer. + + @param bufev the bufferevent from which to get the evbuffer + @return the evbuffer object for the input buffer + */ + +EVENT2_EXPORT_SYMBOL +struct evbuffer *bufferevent_get_input(struct bufferevent *bufev); + +/** + Returns the output buffer. + + The user MUST NOT set the callback on this buffer. + + When filters are being used, the filters need to be manually + triggered if the output buffer was manipulated. + + @param bufev the bufferevent from which to get the evbuffer + @return the evbuffer object for the output buffer + */ + +EVENT2_EXPORT_SYMBOL +struct evbuffer *bufferevent_get_output(struct bufferevent *bufev); + +/** + Enable a bufferevent. + + @param bufev the bufferevent to be enabled + @param event any combination of EV_READ | EV_WRITE. + @return 0 if successful, or -1 if an error occurred + @see bufferevent_disable() + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_enable(struct bufferevent *bufev, short event); + +/** + Disable a bufferevent. + + @param bufev the bufferevent to be disabled + @param event any combination of EV_READ | EV_WRITE. + @return 0 if successful, or -1 if an error occurred + @see bufferevent_enable() + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_disable(struct bufferevent *bufev, short event); + +/** + Return the events that are enabled on a given bufferevent. + + @param bufev the bufferevent to inspect + @return A combination of EV_READ | EV_WRITE + */ +EVENT2_EXPORT_SYMBOL +short bufferevent_get_enabled(struct bufferevent *bufev); + +/** + Set the read and write timeout for a bufferevent. + + A bufferevent's timeout will fire the first time that the indicated + amount of time has elapsed since a successful read or write operation, + during which the bufferevent was trying to read or write. + + (In other words, if reading or writing is disabled, or if the + bufferevent's read or write operation has been suspended because + there's no data to write, or not enough banwidth, or so on, the + timeout isn't active. The timeout only becomes active when we we're + willing to actually read or write.) + + Calling bufferevent_enable or setting a timeout for a bufferevent + whose timeout is already pending resets its timeout. + + If the timeout elapses, the corresponding operation (EV_READ or + EV_WRITE) becomes disabled until you re-enable it again. The + bufferevent's event callback is called with the + BEV_EVENT_TIMEOUT|BEV_EVENT_READING or + BEV_EVENT_TIMEOUT|BEV_EVENT_WRITING. + + @param bufev the bufferevent to be modified + @param timeout_read the read timeout, or NULL + @param timeout_write the write timeout, or NULL + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_set_timeouts(struct bufferevent *bufev, + const struct timeval *timeout_read, const struct timeval *timeout_write); + +/** + Sets the watermarks for read and write events. + + On input, a bufferevent does not invoke the user read callback unless + there is at least low watermark data in the buffer. If the read buffer + is beyond the high watermark, the bufferevent stops reading from the network. + + On output, the user write callback is invoked whenever the buffered data + falls below the low watermark. Filters that write to this bufev will try + not to write more bytes to this buffer than the high watermark would allow, + except when flushing. + + @param bufev the bufferevent to be modified + @param events EV_READ, EV_WRITE or both + @param lowmark the lower watermark to set + @param highmark the high watermark to set +*/ + +EVENT2_EXPORT_SYMBOL +void bufferevent_setwatermark(struct bufferevent *bufev, short events, + size_t lowmark, size_t highmark); + +/** + Retrieves the watermarks for read or write events. + Returns non-zero if events contains not only EV_READ or EV_WRITE. + Returns zero if events equal EV_READ or EV_WRITE + + @param bufev the bufferevent to be examined + @param events EV_READ or EV_WRITE + @param lowmark receives the lower watermark if not NULL + @param highmark receives the high watermark if not NULL +*/ +EVENT2_EXPORT_SYMBOL +int bufferevent_getwatermark(struct bufferevent *bufev, short events, + size_t *lowmark, size_t *highmark); + +/** + Acquire the lock on a bufferevent. Has no effect if locking was not + enabled with BEV_OPT_THREADSAFE. + */ +EVENT2_EXPORT_SYMBOL +void bufferevent_lock(struct bufferevent *bufev); + +/** + Release the lock on a bufferevent. Has no effect if locking was not + enabled with BEV_OPT_THREADSAFE. + */ +EVENT2_EXPORT_SYMBOL +void bufferevent_unlock(struct bufferevent *bufev); + +/** + Flags that can be passed into filters to let them know how to + deal with the incoming data. +*/ +enum bufferevent_flush_mode { + /** usually set when processing data */ + BEV_NORMAL = 0, + + /** want to checkpoint all data sent. */ + BEV_FLUSH = 1, + + /** encountered EOF on read or done sending data */ + BEV_FINISHED = 2 +}; + +/** + Triggers the bufferevent to produce more data if possible. + + @param bufev the bufferevent object + @param iotype either EV_READ or EV_WRITE or both. + @param mode either BEV_NORMAL or BEV_FLUSH or BEV_FINISHED + @return -1 on failure, 0 if no data was produces, 1 if data was produced + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_flush(struct bufferevent *bufev, + short iotype, + enum bufferevent_flush_mode mode); + +/** + Flags for bufferevent_trigger(_event) that modify when and how to trigger + the callback. +*/ +enum bufferevent_trigger_options { + /** trigger the callback regardless of the watermarks */ + BEV_TRIG_IGNORE_WATERMARKS = (1<<16), + + /** defer even if the callbacks are not */ + BEV_TRIG_DEFER_CALLBACKS = BEV_OPT_DEFER_CALLBACKS + + /* (Note: for internal reasons, these need to be disjoint from + * bufferevent_options, except when they mean the same thing. */ +}; + +/** + Triggers bufferevent data callbacks. + + The function will honor watermarks unless options contain + BEV_TRIG_IGNORE_WATERMARKS. If the options contain BEV_OPT_DEFER_CALLBACKS, + the callbacks are deferred. + + @param bufev the bufferevent object + @param iotype either EV_READ or EV_WRITE or both. + @param options + */ +EVENT2_EXPORT_SYMBOL +void bufferevent_trigger(struct bufferevent *bufev, short iotype, + int options); + +/** + Triggers the bufferevent event callback. + + If the options contain BEV_OPT_DEFER_CALLBACKS, the callbacks are deferred. + + @param bufev the bufferevent object + @param what the flags to pass onto the event callback + @param options + */ +EVENT2_EXPORT_SYMBOL +void bufferevent_trigger_event(struct bufferevent *bufev, short what, + int options); + +/** + @name Filtering support + + @{ +*/ +/** + Values that filters can return. + */ +enum bufferevent_filter_result { + /** everything is okay */ + BEV_OK = 0, + + /** the filter needs to read more data before output */ + BEV_NEED_MORE = 1, + + /** the filter encountered a critical error, no further data + can be processed. */ + BEV_ERROR = 2 +}; + +/** A callback function to implement a filter for a bufferevent. + + @param src An evbuffer to drain data from. + @param dst An evbuffer to add data to. + @param limit A suggested upper bound of bytes to write to dst. + The filter may ignore this value, but doing so means that + it will overflow the high-water mark associated with dst. + -1 means "no limit". + @param mode Whether we should write data as may be convenient + (BEV_NORMAL), or flush as much data as we can (BEV_FLUSH), + or flush as much as we can, possibly including an end-of-stream + marker (BEV_FINISH). + @param ctx A user-supplied pointer. + + @return BEV_OK if we wrote some data; BEV_NEED_MORE if we can't + produce any more output until we get some input; and BEV_ERROR + on an error. + */ +typedef enum bufferevent_filter_result (*bufferevent_filter_cb)( + struct evbuffer *src, struct evbuffer *dst, ev_ssize_t dst_limit, + enum bufferevent_flush_mode mode, void *ctx); + +/** + Allocate a new filtering bufferevent on top of an existing bufferevent. + + @param underlying the underlying bufferevent. + @param input_filter The filter to apply to data we read from the underlying + bufferevent + @param output_filter The filer to apply to data we write to the underlying + bufferevent + @param options A bitfield of bufferevent options. + @param free_context A function to use to free the filter context when + this bufferevent is freed. + @param ctx A context pointer to pass to the filter functions. + */ +EVENT2_EXPORT_SYMBOL +struct bufferevent * +bufferevent_filter_new(struct bufferevent *underlying, + bufferevent_filter_cb input_filter, + bufferevent_filter_cb output_filter, + int options, + void (*free_context)(void *), + void *ctx); +/**@}*/ + +/** + Allocate a pair of linked bufferevents. The bufferevents behave as would + two bufferevent_sock instances connected to opposite ends of a + socketpair(), except that no internal socketpair is allocated. + + @param base The event base to associate with the socketpair. + @param options A set of options for this bufferevent + @param pair A pointer to an array to hold the two new bufferevent objects. + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_pair_new(struct event_base *base, int options, + struct bufferevent *pair[2]); + +/** + Given one bufferevent returned by bufferevent_pair_new(), returns the + other one if it still exists. Otherwise returns NULL. + */ +EVENT2_EXPORT_SYMBOL +struct bufferevent *bufferevent_pair_get_partner(struct bufferevent *bev); + +/** + Abstract type used to configure rate-limiting on a bufferevent or a group + of bufferevents. + */ +struct ev_token_bucket_cfg; + +/** + A group of bufferevents which are configured to respect the same rate + limit. +*/ +struct bufferevent_rate_limit_group; + +/** Maximum configurable rate- or burst-limit. */ +#define EV_RATE_LIMIT_MAX EV_SSIZE_MAX + +/** + Initialize and return a new object to configure the rate-limiting behavior + of bufferevents. + + @param read_rate The maximum number of bytes to read per tick on + average. + @param read_burst The maximum number of bytes to read in any single tick. + @param write_rate The maximum number of bytes to write per tick on + average. + @param write_burst The maximum number of bytes to write in any single tick. + @param tick_len The length of a single tick. Defaults to one second. + Any fractions of a millisecond are ignored. + + Note that all rate-limits hare are currently best-effort: future versions + of Libevent may implement them more tightly. + */ +EVENT2_EXPORT_SYMBOL +struct ev_token_bucket_cfg *ev_token_bucket_cfg_new( + size_t read_rate, size_t read_burst, + size_t write_rate, size_t write_burst, + const struct timeval *tick_len); + +/** Free all storage held in 'cfg'. + + Note: 'cfg' is not currently reference-counted; it is not safe to free it + until no bufferevent is using it. + */ +EVENT2_EXPORT_SYMBOL +void ev_token_bucket_cfg_free(struct ev_token_bucket_cfg *cfg); + +/** + Set the rate-limit of a the bufferevent 'bev' to the one specified in + 'cfg'. If 'cfg' is NULL, disable any per-bufferevent rate-limiting on + 'bev'. + + Note that only some bufferevent types currently respect rate-limiting. + They are: socket-based bufferevents (normal and IOCP-based), and SSL-based + bufferevents. + + Return 0 on sucess, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_set_rate_limit(struct bufferevent *bev, + struct ev_token_bucket_cfg *cfg); + +/** + Create a new rate-limit group for bufferevents. A rate-limit group + constrains the maximum number of bytes sent and received, in toto, + by all of its bufferevents. + + @param base An event_base to run any necessary timeouts for the group. + Note that all bufferevents in the group do not necessarily need to share + this event_base. + @param cfg The rate-limit for this group. + + Note that all rate-limits hare are currently best-effort: future versions + of Libevent may implement them more tightly. + + Note also that only some bufferevent types currently respect rate-limiting. + They are: socket-based bufferevents (normal and IOCP-based), and SSL-based + bufferevents. + */ +EVENT2_EXPORT_SYMBOL +struct bufferevent_rate_limit_group *bufferevent_rate_limit_group_new( + struct event_base *base, + const struct ev_token_bucket_cfg *cfg); +/** + Change the rate-limiting settings for a given rate-limiting group. + + Return 0 on success, -1 on failure. +*/ +EVENT2_EXPORT_SYMBOL +int bufferevent_rate_limit_group_set_cfg( + struct bufferevent_rate_limit_group *, + const struct ev_token_bucket_cfg *); + +/** + Change the smallest quantum we're willing to allocate to any single + bufferevent in a group for reading or writing at a time. + + The rationale is that, because of TCP/IP protocol overheads and kernel + behavior, if a rate-limiting group is so tight on bandwidth that you're + only willing to send 1 byte per tick per bufferevent, you might instead + want to batch up the reads and writes so that you send N bytes per + 1/N of the bufferevents (chosen at random) each tick, so you still wind + up send 1 byte per tick per bufferevent on average, but you don't send + so many tiny packets. + + The default min-share is currently 64 bytes. + + Returns 0 on success, -1 on faulre. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_rate_limit_group_set_min_share( + struct bufferevent_rate_limit_group *, size_t); + +/** + Free a rate-limiting group. The group must have no members when + this function is called. +*/ +EVENT2_EXPORT_SYMBOL +void bufferevent_rate_limit_group_free(struct bufferevent_rate_limit_group *); + +/** + Add 'bev' to the list of bufferevents whose aggregate reading and writing + is restricted by 'g'. If 'g' is NULL, remove 'bev' from its current group. + + A bufferevent may belong to no more than one rate-limit group at a time. + If 'bev' is already a member of a group, it will be removed from its old + group before being added to 'g'. + + Return 0 on success and -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_add_to_rate_limit_group(struct bufferevent *bev, + struct bufferevent_rate_limit_group *g); + +/** Remove 'bev' from its current rate-limit group (if any). */ +EVENT2_EXPORT_SYMBOL +int bufferevent_remove_from_rate_limit_group(struct bufferevent *bev); + +/** + Set the size limit for single read operation. + + Set to 0 for a reasonable default. + + Return 0 on success and -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_set_max_single_read(struct bufferevent *bev, size_t size); + +/** + Set the size limit for single write operation. + + Set to 0 for a reasonable default. + + Return 0 on success and -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_set_max_single_write(struct bufferevent *bev, size_t size); + +/** Get the current size limit for single read operation. */ +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_get_max_single_read(struct bufferevent *bev); + +/** Get the current size limit for single write operation. */ +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_get_max_single_write(struct bufferevent *bev); + +/** + @name Rate limit inspection + + Return the current read or write bucket size for a bufferevent. + If it is not configured with a per-bufferevent ratelimit, return + EV_SSIZE_MAX. This function does not inspect the group limit, if any. + Note that it can return a negative value if the bufferevent has been + made to read or write more than its limit. + + @{ + */ +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_get_read_limit(struct bufferevent *bev); +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_get_write_limit(struct bufferevent *bev); +/*@}*/ + +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_get_max_to_read(struct bufferevent *bev); +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_get_max_to_write(struct bufferevent *bev); + +EVENT2_EXPORT_SYMBOL +const struct ev_token_bucket_cfg *bufferevent_get_token_bucket_cfg(const struct bufferevent * bev); + +/** + @name Group Rate limit inspection + + Return the read or write bucket size for a bufferevent rate limit + group. Note that it can return a negative value if bufferevents in + the group have been made to read or write more than their limits. + + @{ + */ +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_rate_limit_group_get_read_limit( + struct bufferevent_rate_limit_group *); +EVENT2_EXPORT_SYMBOL +ev_ssize_t bufferevent_rate_limit_group_get_write_limit( + struct bufferevent_rate_limit_group *); +/*@}*/ + +/** + @name Rate limit manipulation + + Subtract a number of bytes from a bufferevent's read or write bucket. + The decrement value can be negative, if you want to manually refill + the bucket. If the change puts the bucket above or below zero, the + bufferevent will resume or suspend reading writing as appropriate. + These functions make no change in the buckets for the bufferevent's + group, if any. + + Returns 0 on success, -1 on internal error. + + @{ + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_decrement_read_limit(struct bufferevent *bev, ev_ssize_t decr); +EVENT2_EXPORT_SYMBOL +int bufferevent_decrement_write_limit(struct bufferevent *bev, ev_ssize_t decr); +/*@}*/ + +/** + @name Group rate limit manipulation + + Subtract a number of bytes from a bufferevent rate-limiting group's + read or write bucket. The decrement value can be negative, if you + want to manually refill the bucket. If the change puts the bucket + above or below zero, the bufferevents in the group will resume or + suspend reading writing as appropriate. + + Returns 0 on success, -1 on internal error. + + @{ + */ +EVENT2_EXPORT_SYMBOL +int bufferevent_rate_limit_group_decrement_read( + struct bufferevent_rate_limit_group *, ev_ssize_t); +EVENT2_EXPORT_SYMBOL +int bufferevent_rate_limit_group_decrement_write( + struct bufferevent_rate_limit_group *, ev_ssize_t); +/*@}*/ + + +/** + * Inspect the total bytes read/written on a group. + * + * Set the variable pointed to by total_read_out to the total number of bytes + * ever read on grp, and the variable pointed to by total_written_out to the + * total number of bytes ever written on grp. */ +EVENT2_EXPORT_SYMBOL +void bufferevent_rate_limit_group_get_totals( + struct bufferevent_rate_limit_group *grp, + ev_uint64_t *total_read_out, ev_uint64_t *total_written_out); + +/** + * Reset the total bytes read/written on a group. + * + * Reset the number of bytes read or written on grp as given by + * bufferevent_rate_limit_group_reset_totals(). */ +EVENT2_EXPORT_SYMBOL +void +bufferevent_rate_limit_group_reset_totals( + struct bufferevent_rate_limit_group *grp); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_BUFFEREVENT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/bufferevent_compat.h b/contrib/ntp/sntp/libevent/include/event2/bufferevent_compat.h new file mode 100644 index 000000000..65482042f --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/bufferevent_compat.h @@ -0,0 +1,100 @@ +/* + * Copyright (c) 2007-2012 Niels Provos, Nick Mathewson + * Copyright (c) 2000-2007 Niels Provos + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_BUFFEREVENT_COMPAT_H_INCLUDED_ +#define EVENT2_BUFFEREVENT_COMPAT_H_INCLUDED_ + +#define evbuffercb bufferevent_data_cb +#define everrorcb bufferevent_event_cb + +/** + Create a new bufferevent for an fd. + + This function is deprecated. Use bufferevent_socket_new and + bufferevent_set_callbacks instead. + + Libevent provides an abstraction on top of the regular event callbacks. + This abstraction is called a buffered event. A buffered event provides + input and output buffers that get filled and drained automatically. The + user of a buffered event no longer deals directly with the I/O, but + instead is reading from input and writing to output buffers. + + Once initialized, the bufferevent structure can be used repeatedly with + bufferevent_enable() and bufferevent_disable(). + + When read enabled the bufferevent will try to read from the file descriptor + and call the read callback. The write callback is executed whenever the + output buffer is drained below the write low watermark, which is 0 by + default. + + If multiple bases are in use, bufferevent_base_set() must be called before + enabling the bufferevent for the first time. + + @deprecated This function is deprecated because it uses the current + event base, and as such can be error prone for multithreaded programs. + Use bufferevent_socket_new() instead. + + @param fd the file descriptor from which data is read and written to. + This file descriptor is not allowed to be a pipe(2). + @param readcb callback to invoke when there is data to be read, or NULL if + no callback is desired + @param writecb callback to invoke when the file descriptor is ready for + writing, or NULL if no callback is desired + @param errorcb callback to invoke when there is an error on the file + descriptor + @param cbarg an argument that will be supplied to each of the callbacks + (readcb, writecb, and errorcb) + @return a pointer to a newly allocated bufferevent struct, or NULL if an + error occurred + @see bufferevent_base_set(), bufferevent_free() + */ +struct bufferevent *bufferevent_new(evutil_socket_t fd, + evbuffercb readcb, evbuffercb writecb, everrorcb errorcb, void *cbarg); + + +/** + Set the read and write timeout for a buffered event. + + @param bufev the bufferevent to be modified + @param timeout_read the read timeout + @param timeout_write the write timeout + */ +void bufferevent_settimeout(struct bufferevent *bufev, + int timeout_read, int timeout_write); + +#define EVBUFFER_READ BEV_EVENT_READING +#define EVBUFFER_WRITE BEV_EVENT_WRITING +#define EVBUFFER_EOF BEV_EVENT_EOF +#define EVBUFFER_ERROR BEV_EVENT_ERROR +#define EVBUFFER_TIMEOUT BEV_EVENT_TIMEOUT + +/** macro for getting access to the input buffer of a bufferevent */ +#define EVBUFFER_INPUT(x) bufferevent_get_input(x) +/** macro for getting access to the output buffer of a bufferevent */ +#define EVBUFFER_OUTPUT(x) bufferevent_get_output(x) + +#endif diff --git a/contrib/ntp/sntp/libevent/include/event2/bufferevent_ssl.h b/contrib/ntp/sntp/libevent/include/event2/bufferevent_ssl.h new file mode 100644 index 000000000..bf39b844a --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/bufferevent_ssl.h @@ -0,0 +1,134 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_BUFFEREVENT_SSL_H_INCLUDED_ +#define EVENT2_BUFFEREVENT_SSL_H_INCLUDED_ + +/** @file event2/bufferevent_ssl.h + + OpenSSL support for bufferevents. + */ +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* This is what openssl's SSL objects are underneath. */ +struct ssl_st; + +/** + The state of an SSL object to be used when creating a new + SSL bufferevent. + */ +enum bufferevent_ssl_state { + BUFFEREVENT_SSL_OPEN = 0, + BUFFEREVENT_SSL_CONNECTING = 1, + BUFFEREVENT_SSL_ACCEPTING = 2 +}; + +#if defined(EVENT__HAVE_OPENSSL) || defined(EVENT_IN_DOXYGEN_) +/** + Create a new SSL bufferevent to send its data over another bufferevent. + + @param base An event_base to use to detect reading and writing. It + must also be the base for the underlying bufferevent. + @param underlying A socket to use for this SSL + @param ssl A SSL* object from openssl. + @param state The current state of the SSL connection + @param options One or more bufferevent_options + @return A new bufferevent on success, or NULL on failure +*/ +EVENT2_EXPORT_SYMBOL +struct bufferevent * +bufferevent_openssl_filter_new(struct event_base *base, + struct bufferevent *underlying, + struct ssl_st *ssl, + enum bufferevent_ssl_state state, + int options); + +/** + Create a new SSL bufferevent to send its data over an SSL * on a socket. + + @param base An event_base to use to detect reading and writing + @param fd A socket to use for this SSL + @param ssl A SSL* object from openssl. + @param state The current state of the SSL connection + @param options One or more bufferevent_options + @return A new bufferevent on success, or NULL on failure. +*/ +EVENT2_EXPORT_SYMBOL +struct bufferevent * +bufferevent_openssl_socket_new(struct event_base *base, + evutil_socket_t fd, + struct ssl_st *ssl, + enum bufferevent_ssl_state state, + int options); + +/** Control how to report dirty SSL shutdowns. + + If the peer (or the network, or an attacker) closes the TCP + connection before closing the SSL channel, and the protocol is SSL >= v3, + this is a "dirty" shutdown. If allow_dirty_shutdown is 0 (default), + this is reported as BEV_EVENT_ERROR. + + If instead allow_dirty_shutdown=1, a dirty shutdown is reported as + BEV_EVENT_EOF. + + (Note that if the protocol is < SSLv3, you will always receive + BEV_EVENT_EOF, since SSL 2 and earlier cannot distinguish a secure + connection close from a dirty one. This is one reason (among many) + not to use SSL 2.) +*/ + +EVENT2_EXPORT_SYMBOL +int bufferevent_openssl_get_allow_dirty_shutdown(struct bufferevent *bev); +EVENT2_EXPORT_SYMBOL +void bufferevent_openssl_set_allow_dirty_shutdown(struct bufferevent *bev, + int allow_dirty_shutdown); + +/** Return the underlying openssl SSL * object for an SSL bufferevent. */ +EVENT2_EXPORT_SYMBOL +struct ssl_st * +bufferevent_openssl_get_ssl(struct bufferevent *bufev); + +/** Tells a bufferevent to begin SSL renegotiation. */ +EVENT2_EXPORT_SYMBOL +int bufferevent_ssl_renegotiate(struct bufferevent *bev); + +/** Return the most recent OpenSSL error reported on an SSL bufferevent. */ +EVENT2_EXPORT_SYMBOL +unsigned long bufferevent_get_openssl_error(struct bufferevent *bev); + +#endif + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_BUFFEREVENT_SSL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/bufferevent_struct.h b/contrib/ntp/sntp/libevent/include/event2/bufferevent_struct.h new file mode 100644 index 000000000..e84c082c3 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/bufferevent_struct.h @@ -0,0 +1,116 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_BUFFEREVENT_STRUCT_H_INCLUDED_ +#define EVENT2_BUFFEREVENT_STRUCT_H_INCLUDED_ + +/** @file event2/bufferevent_struct.h + + Data structures for bufferevents. Using these structures may hurt forward + compatibility with later versions of Libevent: be careful! + + @deprecated Use of bufferevent_struct.h is completely deprecated; these + structures are only exposed for backward compatibility with programs + written before Libevent 2.0 that used them. + */ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include +/* For struct event */ +#include + +struct event_watermark { + size_t low; + size_t high; +}; + +/** + Shared implementation of a bufferevent. + + This type is exposed only because it was exposed in previous versions, + and some people's code may rely on manipulating it. Otherwise, you + should really not rely on the layout, size, or contents of this structure: + it is fairly volatile, and WILL change in future versions of the code. +**/ +struct bufferevent { + /** Event base for which this bufferevent was created. */ + struct event_base *ev_base; + /** Pointer to a table of function pointers to set up how this + bufferevent behaves. */ + const struct bufferevent_ops *be_ops; + + /** A read event that triggers when a timeout has happened or a socket + is ready to read data. Only used by some subtypes of + bufferevent. */ + struct event ev_read; + /** A write event that triggers when a timeout has happened or a socket + is ready to write data. Only used by some subtypes of + bufferevent. */ + struct event ev_write; + + /** An input buffer. Only the bufferevent is allowed to add data to + this buffer, though the user is allowed to drain it. */ + struct evbuffer *input; + + /** An input buffer. Only the bufferevent is allowed to drain data + from this buffer, though the user is allowed to add it. */ + struct evbuffer *output; + + struct event_watermark wm_read; + struct event_watermark wm_write; + + bufferevent_data_cb readcb; + bufferevent_data_cb writecb; + /* This should be called 'eventcb', but renaming it would break + * backward compatibility */ + bufferevent_event_cb errorcb; + void *cbarg; + + struct timeval timeout_read; + struct timeval timeout_write; + + /** Events that are currently enabled: currently EV_READ and EV_WRITE + are supported. */ + short enabled; +}; + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_BUFFEREVENT_STRUCT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/dns.h b/contrib/ntp/sntp/libevent/include/event2/dns.h new file mode 100644 index 000000000..17cd86a2e --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/dns.h @@ -0,0 +1,717 @@ +/* + * Copyright (c) 2006-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* + * The original DNS code is due to Adam Langley with heavy + * modifications by Nick Mathewson. Adam put his DNS software in the + * public domain. You can find his original copyright below. Please, + * aware that the code as part of Libevent is governed by the 3-clause + * BSD license above. + * + * This software is Public Domain. To view a copy of the public domain dedication, + * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to + * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. + * + * I ask and expect, but do not require, that all derivative works contain an + * attribution similar to: + * Parts developed by Adam Langley + * + * You may wish to replace the word "Parts" with something else depending on + * the amount of original code. + * + * (Derivative works does not include programs which link against, run or include + * the source verbatim in their source distributions) + */ + +/** @file event2/dns.h + * + * Welcome, gentle reader + * + * Async DNS lookups are really a whole lot harder than they should be, + * mostly stemming from the fact that the libc resolver has never been + * very good at them. Before you use this library you should see if libc + * can do the job for you with the modern async call getaddrinfo_a + * (see http://www.imperialviolet.org/page25.html#e498). Otherwise, + * please continue. + * + * The library keeps track of the state of nameservers and will avoid + * them when they go down. Otherwise it will round robin between them. + * + * Quick start guide: + * #include "evdns.h" + * void callback(int result, char type, int count, int ttl, + * void *addresses, void *arg); + * evdns_resolv_conf_parse(DNS_OPTIONS_ALL, "/etc/resolv.conf"); + * evdns_resolve("www.hostname.com", 0, callback, NULL); + * + * When the lookup is complete the callback function is called. The + * first argument will be one of the DNS_ERR_* defines in evdns.h. + * Hopefully it will be DNS_ERR_NONE, in which case type will be + * DNS_IPv4_A, count will be the number of IP addresses, ttl is the time + * which the data can be cached for (in seconds), addresses will point + * to an array of uint32_t's and arg will be whatever you passed to + * evdns_resolve. + * + * Searching: + * + * In order for this library to be a good replacement for glibc's resolver it + * supports searching. This involves setting a list of default domains, in + * which names will be queried for. The number of dots in the query name + * determines the order in which this list is used. + * + * Searching appears to be a single lookup from the point of view of the API, + * although many DNS queries may be generated from a single call to + * evdns_resolve. Searching can also drastically slow down the resolution + * of names. + * + * To disable searching: + * 1. Never set it up. If you never call evdns_resolv_conf_parse or + * evdns_search_add then no searching will occur. + * + * 2. If you do call evdns_resolv_conf_parse then don't pass + * DNS_OPTION_SEARCH (or DNS_OPTIONS_ALL, which implies it). + * + * 3. When calling evdns_resolve, pass the DNS_QUERY_NO_SEARCH flag. + * + * The order of searches depends on the number of dots in the name. If the + * number is greater than the ndots setting then the names is first tried + * globally. Otherwise each search domain is appended in turn. + * + * The ndots setting can either be set from a resolv.conf, or by calling + * evdns_search_ndots_set. + * + * For example, with ndots set to 1 (the default) and a search domain list of + * ["myhome.net"]: + * Query: www + * Order: www.myhome.net, www. + * + * Query: www.abc + * Order: www.abc., www.abc.myhome.net + * + * Internals: + * + * Requests are kept in two queues. The first is the inflight queue. In + * this queue requests have an allocated transaction id and nameserver. + * They will soon be transmitted if they haven't already been. + * + * The second is the waiting queue. The size of the inflight ring is + * limited and all other requests wait in waiting queue for space. This + * bounds the number of concurrent requests so that we don't flood the + * nameserver. Several algorithms require a full walk of the inflight + * queue and so bounding its size keeps thing going nicely under huge + * (many thousands of requests) loads. + * + * If a nameserver loses too many requests it is considered down and we + * try not to use it. After a while we send a probe to that nameserver + * (a lookup for google.com) and, if it replies, we consider it working + * again. If the nameserver fails a probe we wait longer to try again + * with the next probe. + */ + +#ifndef EVENT2_DNS_H_INCLUDED_ +#define EVENT2_DNS_H_INCLUDED_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* For integer types. */ +#include + +/** Error codes 0-5 are as described in RFC 1035. */ +#define DNS_ERR_NONE 0 +/** The name server was unable to interpret the query */ +#define DNS_ERR_FORMAT 1 +/** The name server was unable to process this query due to a problem with the + * name server */ +#define DNS_ERR_SERVERFAILED 2 +/** The domain name does not exist */ +#define DNS_ERR_NOTEXIST 3 +/** The name server does not support the requested kind of query */ +#define DNS_ERR_NOTIMPL 4 +/** The name server refuses to reform the specified operation for policy + * reasons */ +#define DNS_ERR_REFUSED 5 +/** The reply was truncated or ill-formatted */ +#define DNS_ERR_TRUNCATED 65 +/** An unknown error occurred */ +#define DNS_ERR_UNKNOWN 66 +/** Communication with the server timed out */ +#define DNS_ERR_TIMEOUT 67 +/** The request was canceled because the DNS subsystem was shut down. */ +#define DNS_ERR_SHUTDOWN 68 +/** The request was canceled via a call to evdns_cancel_request */ +#define DNS_ERR_CANCEL 69 +/** There were no answers and no error condition in the DNS packet. + * This can happen when you ask for an address that exists, but a record + * type that doesn't. */ +#define DNS_ERR_NODATA 70 + +#define DNS_IPv4_A 1 +#define DNS_PTR 2 +#define DNS_IPv6_AAAA 3 + +#define DNS_QUERY_NO_SEARCH 1 + +#define DNS_OPTION_SEARCH 1 +#define DNS_OPTION_NAMESERVERS 2 +#define DNS_OPTION_MISC 4 +#define DNS_OPTION_HOSTSFILE 8 +#define DNS_OPTIONS_ALL 15 + +/* Obsolete name for DNS_QUERY_NO_SEARCH */ +#define DNS_NO_SEARCH DNS_QUERY_NO_SEARCH + +/** + * The callback that contains the results from a lookup. + * - result is one of the DNS_ERR_* values (DNS_ERR_NONE for success) + * - type is either DNS_IPv4_A or DNS_PTR or DNS_IPv6_AAAA + * - count contains the number of addresses of form type + * - ttl is the number of seconds the resolution may be cached for. + * - addresses needs to be cast according to type. It will be an array of + * 4-byte sequences for ipv4, or an array of 16-byte sequences for ipv6, + * or a nul-terminated string for PTR. + */ +typedef void (*evdns_callback_type) (int result, char type, int count, int ttl, void *addresses, void *arg); + +struct evdns_base; +struct event_base; + +/** Flag for evdns_base_new: process resolv.conf. */ +#define EVDNS_BASE_INITIALIZE_NAMESERVERS 1 +/** Flag for evdns_base_new: Do not prevent the libevent event loop from + * exiting when we have no active dns requests. */ +#define EVDNS_BASE_DISABLE_WHEN_INACTIVE 0x8000 + +/** + Initialize the asynchronous DNS library. + + This function initializes support for non-blocking name resolution by + calling evdns_resolv_conf_parse() on UNIX and + evdns_config_windows_nameservers() on Windows. + + @param event_base the event base to associate the dns client with + @param flags any of EVDNS_BASE_INITIALIZE_NAMESERVERS| + EVDNS_BASE_DISABLE_WHEN_INACTIVE + @return evdns_base object if successful, or NULL if an error occurred. + @see evdns_base_free() + */ +EVENT2_EXPORT_SYMBOL +struct evdns_base * evdns_base_new(struct event_base *event_base, int initialize_nameservers); + + +/** + Shut down the asynchronous DNS resolver and terminate all active requests. + + If the 'fail_requests' option is enabled, all active requests will return + an empty result with the error flag set to DNS_ERR_SHUTDOWN. Otherwise, + the requests will be silently discarded. + + @param evdns_base the evdns base to free + @param fail_requests if zero, active requests will be aborted; if non-zero, + active requests will return DNS_ERR_SHUTDOWN. + @see evdns_base_new() + */ +EVENT2_EXPORT_SYMBOL +void evdns_base_free(struct evdns_base *base, int fail_requests); + +/** + Remove all hosts entries that have been loaded into the event_base via + evdns_base_load_hosts or via event_base_resolv_conf_parse. + + @param evdns_base the evdns base to remove outdated host addresses from + */ +EVENT2_EXPORT_SYMBOL +void evdns_base_clear_host_addresses(struct evdns_base *base); + +/** + Convert a DNS error code to a string. + + @param err the DNS error code + @return a string containing an explanation of the error code +*/ +EVENT2_EXPORT_SYMBOL +const char *evdns_err_to_string(int err); + + +/** + Add a nameserver. + + The address should be an IPv4 address in network byte order. + The type of address is chosen so that it matches in_addr.s_addr. + + @param base the evdns_base to which to add the name server + @param address an IP address in network byte order + @return 0 if successful, or -1 if an error occurred + @see evdns_base_nameserver_ip_add() + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_nameserver_add(struct evdns_base *base, + unsigned long int address); + +/** + Get the number of configured nameservers. + + This returns the number of configured nameservers (not necessarily the + number of running nameservers). This is useful for double-checking + whether our calls to the various nameserver configuration functions + have been successful. + + @param base the evdns_base to which to apply this operation + @return the number of configured nameservers + @see evdns_base_nameserver_add() + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_count_nameservers(struct evdns_base *base); + +/** + Remove all configured nameservers, and suspend all pending resolves. + + Resolves will not necessarily be re-attempted until evdns_base_resume() is called. + + @param base the evdns_base to which to apply this operation + @return 0 if successful, or -1 if an error occurred + @see evdns_base_resume() + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_clear_nameservers_and_suspend(struct evdns_base *base); + + +/** + Resume normal operation and continue any suspended resolve requests. + + Re-attempt resolves left in limbo after an earlier call to + evdns_base_clear_nameservers_and_suspend(). + + @param base the evdns_base to which to apply this operation + @return 0 if successful, or -1 if an error occurred + @see evdns_base_clear_nameservers_and_suspend() + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_resume(struct evdns_base *base); + +/** + Add a nameserver by string address. + + This function parses a n IPv4 or IPv6 address from a string and adds it as a + nameserver. It supports the following formats: + - [IPv6Address]:port + - [IPv6Address] + - IPv6Address + - IPv4Address:port + - IPv4Address + + If no port is specified, it defaults to 53. + + @param base the evdns_base to which to apply this operation + @return 0 if successful, or -1 if an error occurred + @see evdns_base_nameserver_add() + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_nameserver_ip_add(struct evdns_base *base, + const char *ip_as_string); + +/** + Add a nameserver by sockaddr. + **/ +EVENT2_EXPORT_SYMBOL +int +evdns_base_nameserver_sockaddr_add(struct evdns_base *base, + const struct sockaddr *sa, ev_socklen_t len, unsigned flags); + +struct evdns_request; + +/** + Lookup an A record for a given name. + + @param base the evdns_base to which to apply this operation + @param name a DNS hostname + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return an evdns_request object if successful, or NULL if an error occurred. + @see evdns_resolve_ipv6(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6(), evdns_cancel_request() + */ +EVENT2_EXPORT_SYMBOL +struct evdns_request *evdns_base_resolve_ipv4(struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr); + +/** + Lookup an AAAA record for a given name. + + @param base the evdns_base to which to apply this operation + @param name a DNS hostname + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return an evdns_request object if successful, or NULL if an error occurred. + @see evdns_resolve_ipv4(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6(), evdns_cancel_request() + */ +EVENT2_EXPORT_SYMBOL +struct evdns_request *evdns_base_resolve_ipv6(struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr); + +struct in_addr; +struct in6_addr; + +/** + Lookup a PTR record for a given IP address. + + @param base the evdns_base to which to apply this operation + @param in an IPv4 address + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return an evdns_request object if successful, or NULL if an error occurred. + @see evdns_resolve_reverse_ipv6(), evdns_cancel_request() + */ +EVENT2_EXPORT_SYMBOL +struct evdns_request *evdns_base_resolve_reverse(struct evdns_base *base, const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr); + + +/** + Lookup a PTR record for a given IPv6 address. + + @param base the evdns_base to which to apply this operation + @param in an IPv6 address + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return an evdns_request object if successful, or NULL if an error occurred. + @see evdns_resolve_reverse_ipv6(), evdns_cancel_request() + */ +EVENT2_EXPORT_SYMBOL +struct evdns_request *evdns_base_resolve_reverse_ipv6(struct evdns_base *base, const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr); + +/** + Cancels a pending DNS resolution request. + + @param base the evdns_base that was used to make the request + @param req the evdns_request that was returned by calling a resolve function + @see evdns_base_resolve_ipv4(), evdns_base_resolve_ipv6, evdns_base_resolve_reverse +*/ +EVENT2_EXPORT_SYMBOL +void evdns_cancel_request(struct evdns_base *base, struct evdns_request *req); + +/** + Set the value of a configuration option. + + The currently available configuration options are: + + ndots, timeout, max-timeouts, max-inflight, attempts, randomize-case, + bind-to, initial-probe-timeout, getaddrinfo-allow-skew. + + In versions before Libevent 2.0.3-alpha, the option name needed to end with + a colon. + + @param base the evdns_base to which to apply this operation + @param option the name of the configuration option to be modified + @param val the value to be set + @return 0 if successful, or -1 if an error occurred + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_set_option(struct evdns_base *base, const char *option, const char *val); + + +/** + Parse a resolv.conf file. + + The 'flags' parameter determines what information is parsed from the + resolv.conf file. See the man page for resolv.conf for the format of this + file. + + The following directives are not parsed from the file: sortlist, rotate, + no-check-names, inet6, debug. + + If this function encounters an error, the possible return values are: 1 = + failed to open file, 2 = failed to stat file, 3 = file too large, 4 = out of + memory, 5 = short read from file, 6 = no nameservers listed in the file + + @param base the evdns_base to which to apply this operation + @param flags any of DNS_OPTION_NAMESERVERS|DNS_OPTION_SEARCH|DNS_OPTION_MISC| + DNS_OPTION_HOSTSFILE|DNS_OPTIONS_ALL + @param filename the path to the resolv.conf file + @return 0 if successful, or various positive error codes if an error + occurred (see above) + @see resolv.conf(3), evdns_config_windows_nameservers() + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_resolv_conf_parse(struct evdns_base *base, int flags, const char *const filename); + +/** + Load an /etc/hosts-style file from 'hosts_fname' into 'base'. + + If hosts_fname is NULL, add minimal entries for localhost, and nothing + else. + + Note that only evdns_getaddrinfo uses the /etc/hosts entries. + + This function does not replace previously loaded hosts entries; to do that, + call evdns_base_clear_host_addresses first. + + Return 0 on success, negative on failure. +*/ +EVENT2_EXPORT_SYMBOL +int evdns_base_load_hosts(struct evdns_base *base, const char *hosts_fname); + +/** + Obtain nameserver information using the Windows API. + + Attempt to configure a set of nameservers based on platform settings on + a win32 host. Preferentially tries to use GetNetworkParams; if that fails, + looks in the registry. + + @return 0 if successful, or -1 if an error occurred + @see evdns_resolv_conf_parse() + */ +#ifdef _WIN32 +EVENT2_EXPORT_SYMBOL +int evdns_base_config_windows_nameservers(struct evdns_base *); +#define EVDNS_BASE_CONFIG_WINDOWS_NAMESERVERS_IMPLEMENTED +#endif + + +/** + Clear the list of search domains. + */ +EVENT2_EXPORT_SYMBOL +void evdns_base_search_clear(struct evdns_base *base); + + +/** + Add a domain to the list of search domains + + @param domain the domain to be added to the search list + */ +EVENT2_EXPORT_SYMBOL +void evdns_base_search_add(struct evdns_base *base, const char *domain); + + +/** + Set the 'ndots' parameter for searches. + + Sets the number of dots which, when found in a name, causes + the first query to be without any search domain. + + @param ndots the new ndots parameter + */ +EVENT2_EXPORT_SYMBOL +void evdns_base_search_ndots_set(struct evdns_base *base, const int ndots); + +/** + A callback that is invoked when a log message is generated + + @param is_warning indicates if the log message is a 'warning' + @param msg the content of the log message + */ +typedef void (*evdns_debug_log_fn_type)(int is_warning, const char *msg); + + +/** + Set the callback function to handle DNS log messages. If this + callback is not set, evdns log messages are handled with the regular + Libevent logging system. + + @param fn the callback to be invoked when a log message is generated + */ +EVENT2_EXPORT_SYMBOL +void evdns_set_log_fn(evdns_debug_log_fn_type fn); + +/** + Set a callback that will be invoked to generate transaction IDs. By + default, we pick transaction IDs based on the current clock time, which + is bad for security. + + @param fn the new callback, or NULL to use the default. + + NOTE: This function has no effect in Libevent 2.0.4-alpha and later, + since Libevent now provides its own secure RNG. + */ +EVENT2_EXPORT_SYMBOL +void evdns_set_transaction_id_fn(ev_uint16_t (*fn)(void)); + +/** + Set a callback used to generate random bytes. By default, we use + the same function as passed to evdns_set_transaction_id_fn to generate + bytes two at a time. If a function is provided here, it's also used + to generate transaction IDs. + + NOTE: This function has no effect in Libevent 2.0.4-alpha and later, + since Libevent now provides its own secure RNG. +*/ +EVENT2_EXPORT_SYMBOL +void evdns_set_random_bytes_fn(void (*fn)(char *, size_t)); + +/* + * Functions used to implement a DNS server. + */ + +struct evdns_server_request; +struct evdns_server_question; + +/** + A callback to implement a DNS server. The callback function receives a DNS + request. It should then optionally add a number of answers to the reply + using the evdns_server_request_add_*_reply functions, before calling either + evdns_server_request_respond to send the reply back, or + evdns_server_request_drop to decline to answer the request. + + @param req A newly received request + @param user_data A pointer that was passed to + evdns_add_server_port_with_base(). + */ +typedef void (*evdns_request_callback_fn_type)(struct evdns_server_request *, void *); +#define EVDNS_ANSWER_SECTION 0 +#define EVDNS_AUTHORITY_SECTION 1 +#define EVDNS_ADDITIONAL_SECTION 2 + +#define EVDNS_TYPE_A 1 +#define EVDNS_TYPE_NS 2 +#define EVDNS_TYPE_CNAME 5 +#define EVDNS_TYPE_SOA 6 +#define EVDNS_TYPE_PTR 12 +#define EVDNS_TYPE_MX 15 +#define EVDNS_TYPE_TXT 16 +#define EVDNS_TYPE_AAAA 28 + +#define EVDNS_QTYPE_AXFR 252 +#define EVDNS_QTYPE_ALL 255 + +#define EVDNS_CLASS_INET 1 + +/* flags that can be set in answers; as part of the err parameter */ +#define EVDNS_FLAGS_AA 0x400 +#define EVDNS_FLAGS_RD 0x080 + +/** Create a new DNS server port. + + @param base The event base to handle events for the server port. + @param socket A UDP socket to accept DNS requests. + @param flags Always 0 for now. + @param callback A function to invoke whenever we get a DNS request + on the socket. + @param user_data Data to pass to the callback. + @return an evdns_server_port structure for this server port. + */ +EVENT2_EXPORT_SYMBOL +struct evdns_server_port *evdns_add_server_port_with_base(struct event_base *base, evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data); +/** Close down a DNS server port, and free associated structures. */ +EVENT2_EXPORT_SYMBOL +void evdns_close_server_port(struct evdns_server_port *port); + +/** Sets some flags in a reply we're building. + Allows setting of the AA or RD flags + */ +EVENT2_EXPORT_SYMBOL +void evdns_server_request_set_flags(struct evdns_server_request *req, int flags); + +/* Functions to add an answer to an in-progress DNS reply. + */ +EVENT2_EXPORT_SYMBOL +int evdns_server_request_add_reply(struct evdns_server_request *req, int section, const char *name, int type, int dns_class, int ttl, int datalen, int is_name, const char *data); +EVENT2_EXPORT_SYMBOL +int evdns_server_request_add_a_reply(struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl); +EVENT2_EXPORT_SYMBOL +int evdns_server_request_add_aaaa_reply(struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl); +EVENT2_EXPORT_SYMBOL +int evdns_server_request_add_ptr_reply(struct evdns_server_request *req, struct in_addr *in, const char *inaddr_name, const char *hostname, int ttl); +EVENT2_EXPORT_SYMBOL +int evdns_server_request_add_cname_reply(struct evdns_server_request *req, const char *name, const char *cname, int ttl); + +/** + Send back a response to a DNS request, and free the request structure. +*/ +EVENT2_EXPORT_SYMBOL +int evdns_server_request_respond(struct evdns_server_request *req, int err); +/** + Free a DNS request without sending back a reply. +*/ +EVENT2_EXPORT_SYMBOL +int evdns_server_request_drop(struct evdns_server_request *req); +struct sockaddr; +/** + Get the address that made a DNS request. + */ +EVENT2_EXPORT_SYMBOL +int evdns_server_request_get_requesting_addr(struct evdns_server_request *req, struct sockaddr *sa, int addr_len); + +/** Callback for evdns_getaddrinfo. */ +typedef void (*evdns_getaddrinfo_cb)(int result, struct evutil_addrinfo *res, void *arg); + +struct evdns_base; +struct evdns_getaddrinfo_request; +/** Make a non-blocking getaddrinfo request using the dns_base in 'dns_base'. + * + * If we can answer the request immediately (with an error or not!), then we + * invoke cb immediately and return NULL. Otherwise we return + * an evdns_getaddrinfo_request and invoke cb later. + * + * When the callback is invoked, we pass as its first argument the error code + * that getaddrinfo would return (or 0 for no error). As its second argument, + * we pass the evutil_addrinfo structures we found (or NULL on error). We + * pass 'arg' as the third argument. + * + * Limitations: + * + * - The AI_V4MAPPED and AI_ALL flags are not currently implemented. + * - For ai_socktype, we only handle SOCKTYPE_STREAM, SOCKTYPE_UDP, and 0. + * - For ai_protocol, we only handle IPPROTO_TCP, IPPROTO_UDP, and 0. + */ +EVENT2_EXPORT_SYMBOL +struct evdns_getaddrinfo_request *evdns_getaddrinfo( + struct evdns_base *dns_base, + const char *nodename, const char *servname, + const struct evutil_addrinfo *hints_in, + evdns_getaddrinfo_cb cb, void *arg); + +/* Cancel an in-progress evdns_getaddrinfo. This MUST NOT be called after the + * getaddrinfo's callback has been invoked. The resolves will be canceled, + * and the callback will be invoked with the error EVUTIL_EAI_CANCEL. */ +EVENT2_EXPORT_SYMBOL +void evdns_getaddrinfo_cancel(struct evdns_getaddrinfo_request *req); + +/** + Retrieve the address of the 'idx'th configured nameserver. + + @param base The evdns_base to examine. + @param idx The index of the nameserver to get the address of. + @param sa A location to receive the server's address. + @param len The number of bytes available at sa. + + @return the number of bytes written into sa on success. On failure, returns + -1 if idx is greater than the number of configured nameservers, or a + value greater than 'len' if len was not high enough. + */ +EVENT2_EXPORT_SYMBOL +int evdns_base_get_nameserver_addr(struct evdns_base *base, int idx, + struct sockaddr *sa, ev_socklen_t len); + +#ifdef __cplusplus +} +#endif + +#endif /* !EVENT2_DNS_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/dns_compat.h b/contrib/ntp/sntp/libevent/include/event2/dns_compat.h new file mode 100644 index 000000000..965fd6544 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/dns_compat.h @@ -0,0 +1,336 @@ +/* + * Copyright (c) 2006-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_DNS_COMPAT_H_INCLUDED_ +#define EVENT2_DNS_COMPAT_H_INCLUDED_ + +/** @file event2/dns_compat.h + + Potentially non-threadsafe versions of the functions in dns.h: provided + only for backwards compatibility. + + + */ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +/** + Initialize the asynchronous DNS library. + + This function initializes support for non-blocking name resolution by + calling evdns_resolv_conf_parse() on UNIX and + evdns_config_windows_nameservers() on Windows. + + @deprecated This function is deprecated because it always uses the current + event base, and is easily confused by multiple calls to event_init(), and + so is not safe for multithreaded use. Additionally, it allocates a global + structure that only one thread can use. The replacement is + evdns_base_new(). + + @return 0 if successful, or -1 if an error occurred + @see evdns_shutdown() + */ +int evdns_init(void); + +struct evdns_base; +/** + Return the global evdns_base created by event_init() and used by the other + deprecated functions. + + @deprecated This function is deprecated because use of the global + evdns_base is error-prone. + */ +struct evdns_base *evdns_get_global_base(void); + +/** + Shut down the asynchronous DNS resolver and terminate all active requests. + + If the 'fail_requests' option is enabled, all active requests will return + an empty result with the error flag set to DNS_ERR_SHUTDOWN. Otherwise, + the requests will be silently discarded. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_shutdown(). + + @param fail_requests if zero, active requests will be aborted; if non-zero, + active requests will return DNS_ERR_SHUTDOWN. + @see evdns_init() + */ +void evdns_shutdown(int fail_requests); + +/** + Add a nameserver. + + The address should be an IPv4 address in network byte order. + The type of address is chosen so that it matches in_addr.s_addr. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_nameserver_add(). + + @param address an IP address in network byte order + @return 0 if successful, or -1 if an error occurred + @see evdns_nameserver_ip_add() + */ +int evdns_nameserver_add(unsigned long int address); + +/** + Get the number of configured nameservers. + + This returns the number of configured nameservers (not necessarily the + number of running nameservers). This is useful for double-checking + whether our calls to the various nameserver configuration functions + have been successful. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_count_nameservers(). + + @return the number of configured nameservers + @see evdns_nameserver_add() + */ +int evdns_count_nameservers(void); + +/** + Remove all configured nameservers, and suspend all pending resolves. + + Resolves will not necessarily be re-attempted until evdns_resume() is called. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_clear_nameservers_and_suspend(). + + @return 0 if successful, or -1 if an error occurred + @see evdns_resume() + */ +int evdns_clear_nameservers_and_suspend(void); + +/** + Resume normal operation and continue any suspended resolve requests. + + Re-attempt resolves left in limbo after an earlier call to + evdns_clear_nameservers_and_suspend(). + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_resume(). + + @return 0 if successful, or -1 if an error occurred + @see evdns_clear_nameservers_and_suspend() + */ +int evdns_resume(void); + +/** + Add a nameserver. + + This wraps the evdns_nameserver_add() function by parsing a string as an IP + address and adds it as a nameserver. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_nameserver_ip_add(). + + @return 0 if successful, or -1 if an error occurred + @see evdns_nameserver_add() + */ +int evdns_nameserver_ip_add(const char *ip_as_string); + +/** + Lookup an A record for a given name. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_resolve_ipv4(). + + @param name a DNS hostname + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return 0 if successful, or -1 if an error occurred + @see evdns_resolve_ipv6(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6() + */ +int evdns_resolve_ipv4(const char *name, int flags, evdns_callback_type callback, void *ptr); + +/** + Lookup an AAAA record for a given name. + + @param name a DNS hostname + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return 0 if successful, or -1 if an error occurred + @see evdns_resolve_ipv4(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6() + */ +int evdns_resolve_ipv6(const char *name, int flags, evdns_callback_type callback, void *ptr); + +struct in_addr; +struct in6_addr; + +/** + Lookup a PTR record for a given IP address. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_resolve_reverse(). + + @param in an IPv4 address + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return 0 if successful, or -1 if an error occurred + @see evdns_resolve_reverse_ipv6() + */ +int evdns_resolve_reverse(const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr); + +/** + Lookup a PTR record for a given IPv6 address. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_resolve_reverse_ipv6(). + + @param in an IPv6 address + @param flags either 0, or DNS_QUERY_NO_SEARCH to disable searching for this query. + @param callback a callback function to invoke when the request is completed + @param ptr an argument to pass to the callback function + @return 0 if successful, or -1 if an error occurred + @see evdns_resolve_reverse_ipv6() + */ +int evdns_resolve_reverse_ipv6(const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr); + +/** + Set the value of a configuration option. + + The currently available configuration options are: + + ndots, timeout, max-timeouts, max-inflight, and attempts + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_set_option(). + + @param option the name of the configuration option to be modified + @param val the value to be set + @param flags Ignored. + @return 0 if successful, or -1 if an error occurred + */ +int evdns_set_option(const char *option, const char *val, int flags); + +/** + Parse a resolv.conf file. + + The 'flags' parameter determines what information is parsed from the + resolv.conf file. See the man page for resolv.conf for the format of this + file. + + The following directives are not parsed from the file: sortlist, rotate, + no-check-names, inet6, debug. + + If this function encounters an error, the possible return values are: 1 = + failed to open file, 2 = failed to stat file, 3 = file too large, 4 = out of + memory, 5 = short read from file, 6 = no nameservers listed in the file + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_resolv_conf_parse(). + + @param flags any of DNS_OPTION_NAMESERVERS|DNS_OPTION_SEARCH|DNS_OPTION_MISC| + DNS_OPTIONS_ALL + @param filename the path to the resolv.conf file + @return 0 if successful, or various positive error codes if an error + occurred (see above) + @see resolv.conf(3), evdns_config_windows_nameservers() + */ +int evdns_resolv_conf_parse(int flags, const char *const filename); + +/** + Clear the list of search domains. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_search_clear(). + */ +void evdns_search_clear(void); + +/** + Add a domain to the list of search domains + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_search_add(). + + @param domain the domain to be added to the search list + */ +void evdns_search_add(const char *domain); + +/** + Set the 'ndots' parameter for searches. + + Sets the number of dots which, when found in a name, causes + the first query to be without any search domain. + + @deprecated This function is deprecated because it does not allow the + caller to specify which evdns_base it applies to. The recommended + function is evdns_base_search_ndots_set(). + + @param ndots the new ndots parameter + */ +void evdns_search_ndots_set(const int ndots); + +/** + As evdns_server_new_with_base. + + @deprecated This function is deprecated because it does not allow the + caller to specify which even_base it uses. The recommended + function is evdns_add_server_port_with_base(). + +*/ +struct evdns_server_port *evdns_add_server_port(evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data); + +#ifdef _WIN32 +int evdns_config_windows_nameservers(void); +#define EVDNS_CONFIG_WINDOWS_NAMESERVERS_IMPLEMENTED +#endif + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/dns_struct.h b/contrib/ntp/sntp/libevent/include/event2/dns_struct.h new file mode 100644 index 000000000..593a8a70b --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/dns_struct.h @@ -0,0 +1,80 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_DNS_STRUCT_H_INCLUDED_ +#define EVENT2_DNS_STRUCT_H_INCLUDED_ + +/** @file event2/dns_struct.h + + Data structures for dns. Using these structures may hurt forward + compatibility with later versions of Libevent: be careful! + + */ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +/* + * Structures used to implement a DNS server. + */ + +struct evdns_server_request { + int flags; + int nquestions; + struct evdns_server_question **questions; +}; +struct evdns_server_question { + int type; +#ifdef __cplusplus + int dns_question_class; +#else + /* You should refer to this field as "dns_question_class". The + * name "class" works in C for backward compatibility, and will be + * removed in a future version. (1.5 or later). */ + int class; +#define dns_question_class class +#endif + char name[1]; +}; + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_DNS_STRUCT_H_INCLUDED_ */ + diff --git a/contrib/ntp/sntp/libevent/include/event2/event.h b/contrib/ntp/sntp/libevent/include/event2/event.h new file mode 100644 index 000000000..570031f26 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/event.h @@ -0,0 +1,1679 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_EVENT_H_INCLUDED_ +#define EVENT2_EVENT_H_INCLUDED_ + +/** + @mainpage + + @section intro Introduction + + Libevent is an event notification library for developing scalable network + servers. The Libevent API provides a mechanism to execute a callback + function when a specific event occurs on a file descriptor or after a + timeout has been reached. Furthermore, Libevent also support callbacks due + to signals or regular timeouts. + + Libevent is meant to replace the event loop found in event driven network + servers. An application just needs to call event_base_dispatch() and then add or + remove events dynamically without having to change the event loop. + + + Currently, Libevent supports /dev/poll, kqueue(2), select(2), poll(2), + epoll(4), and evports. The internal event mechanism is completely + independent of the exposed event API, and a simple update of Libevent can + provide new functionality without having to redesign the applications. As a + result, Libevent allows for portable application development and provides + the most scalable event notification mechanism available on an operating + system. Libevent can also be used for multithreaded programs. Libevent + should compile on Linux, *BSD, Mac OS X, Solaris and, Windows. + + @section usage Standard usage + + Every program that uses Libevent must include the + header, and pass the -levent flag to the linker. (You can instead link + -levent_core if you only want the main event and buffered IO-based code, + and don't want to link any protocol code.) + + @section setup Library setup + + Before you call any other Libevent functions, you need to set up the + library. If you're going to use Libevent from multiple threads in a + multithreaded application, you need to initialize thread support -- + typically by using evthread_use_pthreads() or + evthread_use_windows_threads(). See for more + information. + + This is also the point where you can replace Libevent's memory + management functions with event_set_mem_functions, and enable debug mode + with event_enable_debug_mode(). + + @section base Creating an event base + + Next, you need to create an event_base structure, using event_base_new() + or event_base_new_with_config(). The event_base is responsible for + keeping track of which events are "pending" (that is to say, being + watched to see if they become active) and which events are "active". + Every event is associated with a single event_base. + + @section event Event notification + + For each file descriptor that you wish to monitor, you must create an + event structure with event_new(). (You may also declare an event + structure and call event_assign() to initialize the members of the + structure.) To enable notification, you add the structure to the list + of monitored events by calling event_add(). The event structure must + remain allocated as long as it is active, so it should generally be + allocated on the heap. + + @section loop Dispatching events. + + Finally, you call event_base_dispatch() to loop and dispatch events. + You can also use event_base_loop() for more fine-grained control. + + Currently, only one thread can be dispatching a given event_base at a + time. If you want to run events in multiple threads at once, you can + either have a single event_base whose events add work to a work queue, + or you can create multiple event_base objects. + + @section bufferevent I/O Buffers + + Libevent provides a buffered I/O abstraction on top of the regular event + callbacks. This abstraction is called a bufferevent. A bufferevent + provides input and output buffers that get filled and drained + automatically. The user of a buffered event no longer deals directly + with the I/O, but instead is reading from input and writing to output + buffers. + + Once initialized via bufferevent_socket_new(), the bufferevent structure + can be used repeatedly with bufferevent_enable() and + bufferevent_disable(). Instead of reading and writing directly to a + socket, you would call bufferevent_read() and bufferevent_write(). + + When read enabled the bufferevent will try to read from the file descriptor + and call the read callback. The write callback is executed whenever the + output buffer is drained below the write low watermark, which is 0 by + default. + + See for more information. + + @section timers Timers + + Libevent can also be used to create timers that invoke a callback after a + certain amount of time has expired. The evtimer_new() macro returns + an event struct to use as a timer. To activate the timer, call + evtimer_add(). Timers can be deactivated by calling evtimer_del(). + (These macros are thin wrappers around event_new(), event_add(), + and event_del(); you can also use those instead.) + + @section evdns Asynchronous DNS resolution + + Libevent provides an asynchronous DNS resolver that should be used instead + of the standard DNS resolver functions. See the + functions for more detail. + + @section evhttp Event-driven HTTP servers + + Libevent provides a very simple event-driven HTTP server that can be + embedded in your program and used to service HTTP requests. + + To use this capability, you need to include the header in your + program. See that header for more information. + + @section evrpc A framework for RPC servers and clients + + Libevent provides a framework for creating RPC servers and clients. It + takes care of marshaling and unmarshaling all data structures. + + @section api API Reference + + To browse the complete documentation of the libevent API, click on any of + the following links. + + event2/event.h + The primary libevent header + + event2/thread.h + Functions for use by multithreaded programs + + event2/buffer.h and event2/bufferevent.h + Buffer management for network reading and writing + + event2/util.h + Utility functions for portable nonblocking network code + + event2/dns.h + Asynchronous DNS resolution + + event2/http.h + An embedded libevent-based HTTP server + + event2/rpc.h + A framework for creating RPC servers and clients + + */ + +/** @file event2/event.h + + Core functions for waiting for and receiving events, and using event bases. +*/ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +#include + +/* For int types. */ +#include + +/** + * Structure to hold information and state for a Libevent dispatch loop. + * + * The event_base lies at the center of Libevent; every application will + * have one. It keeps track of all pending and active events, and + * notifies your application of the active ones. + * + * This is an opaque structure; you can allocate one using + * event_base_new() or event_base_new_with_config(). + * + * @see event_base_new(), event_base_free(), event_base_loop(), + * event_base_new_with_config() + */ +struct event_base +#ifdef EVENT_IN_DOXYGEN_ +{/*Empty body so that doxygen will generate documentation here.*/} +#endif +; + +/** + * @struct event + * + * Structure to represent a single event. + * + * An event can have some underlying condition it represents: a socket + * becoming readable or writeable (or both), or a signal becoming raised. + * (An event that represents no underlying condition is still useful: you + * can use one to implement a timer, or to communicate between threads.) + * + * Generally, you can create events with event_new(), then make them + * pending with event_add(). As your event_base runs, it will run the + * callbacks of an events whose conditions are triggered. When you + * longer want the event, free it with event_free(). + * + * In more depth: + * + * An event may be "pending" (one whose condition we are watching), + * "active" (one whose condition has triggered and whose callback is about + * to run), neither, or both. Events come into existence via + * event_assign() or event_new(), and are then neither active nor pending. + * + * To make an event pending, pass it to event_add(). When doing so, you + * can also set a timeout for the event. + * + * Events become active during an event_base_loop() call when either their + * condition has triggered, or when their timeout has elapsed. You can + * also activate an event manually using event_active(). The even_base + * loop will run the callbacks of active events; after it has done so, it + * marks them as no longer active. + * + * You can make an event non-pending by passing it to event_del(). This + * also makes the event non-active. + * + * Events can be "persistent" or "non-persistent". A non-persistent event + * becomes non-pending as soon as it is triggered: thus, it only runs at + * most once per call to event_add(). A persistent event remains pending + * even when it becomes active: you'll need to event_del() it manually in + * order to make it non-pending. When a persistent event with a timeout + * becomes active, its timeout is reset: this means you can use persistent + * events to implement periodic timeouts. + * + * This should be treated as an opaque structure; you should never read or + * write any of its fields directly. For backward compatibility with old + * code, it is defined in the event2/event_struct.h header; including this + * header may make your code incompatible with other versions of Libevent. + * + * @see event_new(), event_free(), event_assign(), event_get_assignment(), + * event_add(), event_del(), event_active(), event_pending(), + * event_get_fd(), event_get_base(), event_get_events(), + * event_get_callback(), event_get_callback_arg(), + * event_priority_set() + */ +struct event +#ifdef EVENT_IN_DOXYGEN_ +{/*Empty body so that doxygen will generate documentation here.*/} +#endif +; + +/** + * Configuration for an event_base. + * + * There are many options that can be used to alter the behavior and + * implementation of an event_base. To avoid having to pass them all in a + * complex many-argument constructor, we provide an abstract data type + * wrhere you set up configation information before passing it to + * event_base_new_with_config(). + * + * @see event_config_new(), event_config_free(), event_base_new_with_config(), + * event_config_avoid_method(), event_config_require_features(), + * event_config_set_flag(), event_config_set_num_cpus_hint() + */ +struct event_config +#ifdef EVENT_IN_DOXYGEN_ +{/*Empty body so that doxygen will generate documentation here.*/} +#endif +; + +/** + * Enable some relatively expensive debugging checks in Libevent that + * would normally be turned off. Generally, these checks cause code that + * would otherwise crash mysteriously to fail earlier with an assertion + * failure. Note that this method MUST be called before any events or + * event_bases have been created. + * + * Debug mode can currently catch the following errors: + * An event is re-assigned while it is added + * Any function is called on a non-assigned event + * + * Note that debugging mode uses memory to track every event that has been + * initialized (via event_assign, event_set, or event_new) but not yet + * released (via event_free or event_debug_unassign). If you want to use + * debug mode, and you find yourself running out of memory, you will need + * to use event_debug_unassign to explicitly stop tracking events that + * are no longer considered set-up. + * + * @see event_debug_unassign() + */ +EVENT2_EXPORT_SYMBOL +void event_enable_debug_mode(void); + +/** + * When debugging mode is enabled, informs Libevent that an event should no + * longer be considered as assigned. When debugging mode is not enabled, does + * nothing. + * + * This function must only be called on a non-added event. + * + * @see event_enable_debug_mode() + */ +EVENT2_EXPORT_SYMBOL +void event_debug_unassign(struct event *); + +/** + * Create and return a new event_base to use with the rest of Libevent. + * + * @return a new event_base on success, or NULL on failure. + * + * @see event_base_free(), event_base_new_with_config() + */ +EVENT2_EXPORT_SYMBOL +struct event_base *event_base_new(void); + +/** + Reinitialize the event base after a fork + + Some event mechanisms do not survive across fork. The event base needs + to be reinitialized with the event_reinit() function. + + @param base the event base that needs to be re-initialized + @return 0 if successful, or -1 if some events could not be re-added. + @see event_base_new() +*/ +EVENT2_EXPORT_SYMBOL +int event_reinit(struct event_base *base); + +/** + Event dispatching loop + + This loop will run the event base until either there are no more pending or + active, or until something calls event_base_loopbreak() or + event_base_loopexit(). + + @param base the event_base structure returned by event_base_new() or + event_base_new_with_config() + @return 0 if successful, -1 if an error occurred, or 1 if we exited because + no events were pending or active. + @see event_base_loop() + */ +EVENT2_EXPORT_SYMBOL +int event_base_dispatch(struct event_base *); + +/** + Get the kernel event notification mechanism used by Libevent. + + @param eb the event_base structure returned by event_base_new() + @return a string identifying the kernel event mechanism (kqueue, epoll, etc.) + */ +EVENT2_EXPORT_SYMBOL +const char *event_base_get_method(const struct event_base *); + +/** + Gets all event notification mechanisms supported by Libevent. + + This functions returns the event mechanism in order preferred by + Libevent. Note that this list will include all backends that + Libevent has compiled-in support for, and will not necessarily check + your OS to see whether it has the required resources. + + @return an array with pointers to the names of support methods. + The end of the array is indicated by a NULL pointer. If an + error is encountered NULL is returned. +*/ +EVENT2_EXPORT_SYMBOL +const char **event_get_supported_methods(void); + +/** Query the current monotonic time from a the timer for a struct + * event_base. + */ +EVENT2_EXPORT_SYMBOL +int event_gettime_monotonic(struct event_base *base, struct timeval *tp); + +/** + @name event type flag + + Flags to pass to event_base_get_num_events() to specify the kinds of events + we want to aggregate counts for +*/ +/**@{*/ +/** count the number of active events, which have been triggered.*/ +#define EVENT_BASE_COUNT_ACTIVE 1U +/** count the number of virtual events, which is used to represent an internal + * condition, other than a pending event, that keeps the loop from exiting. */ +#define EVENT_BASE_COUNT_VIRTUAL 2U +/** count the number of events which have been added to event base, including + * internal events. */ +#define EVENT_BASE_COUNT_ADDED 4U +/**@}*/ + +/** + Gets the number of events in event_base, as specified in the flags. + + Since event base has some internal events added to make some of its + functionalities work, EVENT_BASE_COUNT_ADDED may return more than the + number of events you added using event_add(). + + If you pass EVENT_BASE_COUNT_ACTIVE and EVENT_BASE_COUNT_ADDED together, an + active event will be counted twice. However, this might not be the case in + future libevent versions. The return value is an indication of the work + load, but the user shouldn't rely on the exact value as this may change in + the future. + + @param eb the event_base structure returned by event_base_new() + @param flags a bitwise combination of the kinds of events to aggregate + counts for + @return the number of events specified in the flags +*/ +EVENT2_EXPORT_SYMBOL +int event_base_get_num_events(struct event_base *, unsigned int); + +/** + Get the maximum number of events in a given event_base as specified in the + flags. + + @param eb the event_base structure returned by event_base_new() + @param flags a bitwise combination of the kinds of events to aggregate + counts for + @param clear option used to reset the maximum count. + @return the number of events specified in the flags + */ +EVENT2_EXPORT_SYMBOL +int event_base_get_max_events(struct event_base *, unsigned int, int); + +/** + Allocates a new event configuration object. + + The event configuration object can be used to change the behavior of + an event base. + + @return an event_config object that can be used to store configuration, or + NULL if an error is encountered. + @see event_base_new_with_config(), event_config_free(), event_config +*/ +EVENT2_EXPORT_SYMBOL +struct event_config *event_config_new(void); + +/** + Deallocates all memory associated with an event configuration object + + @param cfg the event configuration object to be freed. +*/ +EVENT2_EXPORT_SYMBOL +void event_config_free(struct event_config *cfg); + +/** + Enters an event method that should be avoided into the configuration. + + This can be used to avoid event mechanisms that do not support certain + file descriptor types, or for debugging to avoid certain event + mechanisms. An application can make use of multiple event bases to + accommodate incompatible file descriptor types. + + @param cfg the event configuration object + @param method the name of the event method to avoid + @return 0 on success, -1 on failure. +*/ +EVENT2_EXPORT_SYMBOL +int event_config_avoid_method(struct event_config *cfg, const char *method); + +/** + A flag used to describe which features an event_base (must) provide. + + Because of OS limitations, not every Libevent backend supports every + possible feature. You can use this type with + event_config_require_features() to tell Libevent to only proceed if your + event_base implements a given feature, and you can receive this type from + event_base_get_features() to see which features are available. +*/ +enum event_method_feature { + /** Require an event method that allows edge-triggered events with EV_ET. */ + EV_FEATURE_ET = 0x01, + /** Require an event method where having one event triggered among + * many is [approximately] an O(1) operation. This excludes (for + * example) select and poll, which are approximately O(N) for N + * equal to the total number of possible events. */ + EV_FEATURE_O1 = 0x02, + /** Require an event method that allows file descriptors as well as + * sockets. */ + EV_FEATURE_FDS = 0x04, + /** Require an event method that allows you to use EV_CLOSED to detect + * connection close without the necessity of reading all the pending data. + * + * Methods that do support EV_CLOSED may not be able to provide support on + * all kernel versions. + **/ + EV_FEATURE_EARLY_CLOSE = 0x08 +}; + +/** + A flag passed to event_config_set_flag(). + + These flags change the behavior of an allocated event_base. + + @see event_config_set_flag(), event_base_new_with_config(), + event_method_feature + */ +enum event_base_config_flag { + /** Do not allocate a lock for the event base, even if we have + locking set up. + + Setting this option will make it unsafe and nonfunctional to call + functions on the base concurrently from multiple threads. + */ + EVENT_BASE_FLAG_NOLOCK = 0x01, + /** Do not check the EVENT_* environment variables when configuring + an event_base */ + EVENT_BASE_FLAG_IGNORE_ENV = 0x02, + /** Windows only: enable the IOCP dispatcher at startup + + If this flag is set then bufferevent_socket_new() and + evconn_listener_new() will use IOCP-backed implementations + instead of the usual select-based one on Windows. + */ + EVENT_BASE_FLAG_STARTUP_IOCP = 0x04, + /** Instead of checking the current time every time the event loop is + ready to run timeout callbacks, check after each timeout callback. + */ + EVENT_BASE_FLAG_NO_CACHE_TIME = 0x08, + + /** If we are using the epoll backend, this flag says that it is + safe to use Libevent's internal change-list code to batch up + adds and deletes in order to try to do as few syscalls as + possible. Setting this flag can make your code run faster, but + it may trigger a Linux bug: it is not safe to use this flag + if you have any fds cloned by dup() or its variants. Doing so + will produce strange and hard-to-diagnose bugs. + + This flag can also be activated by setting the + EVENT_EPOLL_USE_CHANGELIST environment variable. + + This flag has no effect if you wind up using a backend other than + epoll. + */ + EVENT_BASE_FLAG_EPOLL_USE_CHANGELIST = 0x10, + + /** Ordinarily, Libevent implements its time and timeout code using + the fastest monotonic timer that we have. If this flag is set, + however, we use less efficient more precise timer, assuming one is + present. + */ + EVENT_BASE_FLAG_PRECISE_TIMER = 0x20 +}; + +/** + Return a bitmask of the features implemented by an event base. This + will be a bitwise OR of one or more of the values of + event_method_feature + + @see event_method_feature + */ +EVENT2_EXPORT_SYMBOL +int event_base_get_features(const struct event_base *base); + +/** + Enters a required event method feature that the application demands. + + Note that not every feature or combination of features is supported + on every platform. Code that requests features should be prepared + to handle the case where event_base_new_with_config() returns NULL, as in: +
      +     event_config_require_features(cfg, EV_FEATURE_ET);
      +     base = event_base_new_with_config(cfg);
      +     if (base == NULL) {
      +       // We can't get edge-triggered behavior here.
      +       event_config_require_features(cfg, 0);
      +       base = event_base_new_with_config(cfg);
      +     }
      +   
      + + @param cfg the event configuration object + @param feature a bitfield of one or more event_method_feature values. + Replaces values from previous calls to this function. + @return 0 on success, -1 on failure. + @see event_method_feature, event_base_new_with_config() +*/ +EVENT2_EXPORT_SYMBOL +int event_config_require_features(struct event_config *cfg, int feature); + +/** + * Sets one or more flags to configure what parts of the eventual event_base + * will be initialized, and how they'll work. + * + * @see event_base_config_flags, event_base_new_with_config() + **/ +EVENT2_EXPORT_SYMBOL +int event_config_set_flag(struct event_config *cfg, int flag); + +/** + * Records a hint for the number of CPUs in the system. This is used for + * tuning thread pools, etc, for optimal performance. In Libevent 2.0, + * it is only on Windows, and only when IOCP is in use. + * + * @param cfg the event configuration object + * @param cpus the number of cpus + * @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int event_config_set_num_cpus_hint(struct event_config *cfg, int cpus); + +/** + * Record an interval and/or a number of callbacks after which the event base + * should check for new events. By default, the event base will run as many + * events are as activated at the higest activated priority before checking + * for new events. If you configure it by setting max_interval, it will check + * the time after each callback, and not allow more than max_interval to + * elapse before checking for new events. If you configure it by setting + * max_callbacks to a value >= 0, it will run no more than max_callbacks + * callbacks before checking for new events. + * + * This option can decrease the latency of high-priority events, and + * avoid priority inversions where multiple low-priority events keep us from + * polling for high-priority events, but at the expense of slightly decreasing + * the throughput. Use it with caution! + * + * @param cfg The event_base configuration object. + * @param max_interval An interval after which Libevent should stop running + * callbacks and check for more events, or NULL if there should be + * no such interval. + * @param max_callbacks A number of callbacks after which Libevent should + * stop running callbacks and check for more events, or -1 if there + * should be no such limit. + * @param min_priority A priority below which max_interval and max_callbacks + * should not be enforced. If this is set to 0, they are enforced + * for events of every priority; if it's set to 1, they're enforced + * for events of priority 1 and above, and so on. + * @return 0 on success, -1 on failure. + **/ +EVENT2_EXPORT_SYMBOL +int event_config_set_max_dispatch_interval(struct event_config *cfg, + const struct timeval *max_interval, int max_callbacks, + int min_priority); + +/** + Initialize the event API. + + Use event_base_new_with_config() to initialize a new event base, taking + the specified configuration under consideration. The configuration object + can currently be used to avoid certain event notification mechanisms. + + @param cfg the event configuration object + @return an initialized event_base that can be used to registering events, + or NULL if no event base can be created with the requested event_config. + @see event_base_new(), event_base_free(), event_init(), event_assign() +*/ +EVENT2_EXPORT_SYMBOL +struct event_base *event_base_new_with_config(const struct event_config *); + +/** + Deallocate all memory associated with an event_base, and free the base. + + Note that this function will not close any fds or free any memory passed + to event_new as the argument to callback. + + If there are any pending finalizer callbacks, this function will invoke + them. + + @param eb an event_base to be freed + */ +EVENT2_EXPORT_SYMBOL +void event_base_free(struct event_base *); + +/** + As event_free, but do not run finalizers. + + THIS IS AN EXPERIMENTAL API. IT MIGHT CHANGE BEFORE THE LIBEVENT 2.1 SERIES + BECOMES STABLE. + */ +EVENT2_EXPORT_SYMBOL +void event_base_free_nofinalize(struct event_base *); + +/** @name Log severities + */ +/**@{*/ +#define EVENT_LOG_DEBUG 0 +#define EVENT_LOG_MSG 1 +#define EVENT_LOG_WARN 2 +#define EVENT_LOG_ERR 3 +/**@}*/ + +/* Obsolete names: these are deprecated, but older programs might use them. + * They violate the reserved-identifier namespace. */ +#define _EVENT_LOG_DEBUG EVENT_LOG_DEBUG +#define _EVENT_LOG_MSG EVENT_LOG_MSG +#define _EVENT_LOG_WARN EVENT_LOG_WARN +#define _EVENT_LOG_ERR EVENT_LOG_ERR + +/** + A callback function used to intercept Libevent's log messages. + + @see event_set_log_callback + */ +typedef void (*event_log_cb)(int severity, const char *msg); +/** + Redirect Libevent's log messages. + + @param cb a function taking two arguments: an integer severity between + EVENT_LOG_DEBUG and EVENT_LOG_ERR, and a string. If cb is NULL, + then the default log is used. + + NOTE: The function you provide *must not* call any other libevent + functionality. Doing so can produce undefined behavior. + */ +EVENT2_EXPORT_SYMBOL +void event_set_log_callback(event_log_cb cb); + +/** + A function to be called if Libevent encounters a fatal internal error. + + @see event_set_fatal_callback + */ +typedef void (*event_fatal_cb)(int err); + +/** + Override Libevent's behavior in the event of a fatal internal error. + + By default, Libevent will call exit(1) if a programming error makes it + impossible to continue correct operation. This function allows you to supply + another callback instead. Note that if the function is ever invoked, + something is wrong with your program, or with Libevent: any subsequent calls + to Libevent may result in undefined behavior. + + Libevent will (almost) always log an EVENT_LOG_ERR message before calling + this function; look at the last log message to see why Libevent has died. + */ +EVENT2_EXPORT_SYMBOL +void event_set_fatal_callback(event_fatal_cb cb); + +#define EVENT_DBG_ALL 0xffffffffu +#define EVENT_DBG_NONE 0 + +/** + Turn on debugging logs and have them sent to the default log handler. + + This is a global setting; if you are going to call it, you must call this + before any calls that create an event-base. You must call it before any + multithreaded use of Libevent. + + Debug logs are verbose. + + @param which Controls which debug messages are turned on. This option is + unused for now; for forward compatibility, you must pass in the constant + "EVENT_DBG_ALL" to turn debugging logs on, or "EVENT_DBG_NONE" to turn + debugging logs off. + */ +EVENT2_EXPORT_SYMBOL +void event_enable_debug_logging(ev_uint32_t which); + +EVENT2_EXPORT_SYMBOL +void +event_disable_debug_mode(void); + +/** + Associate a different event base with an event. + + The event to be associated must not be currently active or pending. + + @param eb the event base + @param ev the event + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int event_base_set(struct event_base *, struct event *); + +/** @name Loop flags + + These flags control the behavior of event_base_loop(). + */ +/**@{*/ +/** Block until we have an active event, then exit once all active events + * have had their callbacks run. */ +#define EVLOOP_ONCE 0x01 +/** Do not block: see which events are ready now, run the callbacks + * of the highest-priority ones, then exit. */ +#define EVLOOP_NONBLOCK 0x02 +/** Do not exit the loop because we have no pending events. Instead, keep + * running until event_base_loopexit() or event_base_loopbreak() makes us + * stop. + */ +#define EVLOOP_NO_EXIT_ON_EMPTY 0x04 +/**@}*/ + +/** + Wait for events to become active, and run their callbacks. + + This is a more flexible version of event_base_dispatch(). + + By default, this loop will run the event base until either there are no more + pending or active events, or until something calls event_base_loopbreak() or + event_base_loopexit(). You can override this behavior with the 'flags' + argument. + + @param eb the event_base structure returned by event_base_new() or + event_base_new_with_config() + @param flags any combination of EVLOOP_ONCE | EVLOOP_NONBLOCK + @return 0 if successful, -1 if an error occurred, or 1 if we exited because + no events were pending or active. + @see event_base_loopexit(), event_base_dispatch(), EVLOOP_ONCE, + EVLOOP_NONBLOCK + */ +EVENT2_EXPORT_SYMBOL +int event_base_loop(struct event_base *, int); + +/** + Exit the event loop after the specified time + + The next event_base_loop() iteration after the given timer expires will + complete normally (handling all queued events) then exit without + blocking for events again. + + Subsequent invocations of event_base_loop() will proceed normally. + + @param eb the event_base structure returned by event_init() + @param tv the amount of time after which the loop should terminate, + or NULL to exit after running all currently active events. + @return 0 if successful, or -1 if an error occurred + @see event_base_loopbreak() + */ +EVENT2_EXPORT_SYMBOL +int event_base_loopexit(struct event_base *, const struct timeval *); + +/** + Abort the active event_base_loop() immediately. + + event_base_loop() will abort the loop after the next event is completed; + event_base_loopbreak() is typically invoked from this event's callback. + This behavior is analogous to the "break;" statement. + + Subsequent invocations of event_base_loop() will proceed normally. + + @param eb the event_base structure returned by event_init() + @return 0 if successful, or -1 if an error occurred + @see event_base_loopexit() + */ +EVENT2_EXPORT_SYMBOL +int event_base_loopbreak(struct event_base *); + +/** + Tell the active event_base_loop() to scan for new events immediately. + + Calling this function makes the currently active event_base_loop() + start the loop over again (scanning for new events) after the current + event callback finishes. If the event loop is not running, this + function has no effect. + + event_base_loopbreak() is typically invoked from this event's callback. + This behavior is analogous to the "continue;" statement. + + Subsequent invocations of event loop will proceed normally. + + @param eb the event_base structure returned by event_init() + @return 0 if successful, or -1 if an error occurred + @see event_base_loopbreak() + */ +EVENT2_EXPORT_SYMBOL +int event_base_loopcontinue(struct event_base *); + +/** + Checks if the event loop was told to exit by event_base_loopexit(). + + This function will return true for an event_base at every point after + event_loopexit() is called, until the event loop is next entered. + + @param eb the event_base structure returned by event_init() + @return true if event_base_loopexit() was called on this event base, + or 0 otherwise + @see event_base_loopexit() + @see event_base_got_break() + */ +EVENT2_EXPORT_SYMBOL +int event_base_got_exit(struct event_base *); + +/** + Checks if the event loop was told to abort immediately by event_base_loopbreak(). + + This function will return true for an event_base at every point after + event_base_loopbreak() is called, until the event loop is next entered. + + @param eb the event_base structure returned by event_init() + @return true if event_base_loopbreak() was called on this event base, + or 0 otherwise + @see event_base_loopbreak() + @see event_base_got_exit() + */ +EVENT2_EXPORT_SYMBOL +int event_base_got_break(struct event_base *); + +/** + * @name event flags + * + * Flags to pass to event_new(), event_assign(), event_pending(), and + * anything else with an argument of the form "short events" + */ +/**@{*/ +/** Indicates that a timeout has occurred. It's not necessary to pass + * this flag to event_for new()/event_assign() to get a timeout. */ +#define EV_TIMEOUT 0x01 +/** Wait for a socket or FD to become readable */ +#define EV_READ 0x02 +/** Wait for a socket or FD to become writeable */ +#define EV_WRITE 0x04 +/** Wait for a POSIX signal to be raised*/ +#define EV_SIGNAL 0x08 +/** + * Persistent event: won't get removed automatically when activated. + * + * When a persistent event with a timeout becomes activated, its timeout + * is reset to 0. + */ +#define EV_PERSIST 0x10 +/** Select edge-triggered behavior, if supported by the backend. */ +#define EV_ET 0x20 +/** + * If this option is provided, then event_del() will not block in one thread + * while waiting for the event callback to complete in another thread. + * + * To use this option safely, you may need to use event_finalize() or + * event_free_finalize() in order to safely tear down an event in a + * multithreaded application. See those functions for more information. + * + * THIS IS AN EXPERIMENTAL API. IT MIGHT CHANGE BEFORE THE LIBEVENT 2.1 SERIES + * BECOMES STABLE. + **/ +#define EV_FINALIZE 0x40 +/** + * Detects connection close events. You can use this to detect when a + * connection has been closed, without having to read all the pending data + * from a connection. + * + * Not all backends support EV_CLOSED. To detect or require it, use the + * feature flag EV_FEATURE_EARLY_CLOSE. + **/ +#define EV_CLOSED 0x80 +/**@}*/ + +/** + @name evtimer_* macros + + Aliases for working with one-shot timer events */ +/**@{*/ +#define evtimer_assign(ev, b, cb, arg) \ + event_assign((ev), (b), -1, 0, (cb), (arg)) +#define evtimer_new(b, cb, arg) event_new((b), -1, 0, (cb), (arg)) +#define evtimer_add(ev, tv) event_add((ev), (tv)) +#define evtimer_del(ev) event_del(ev) +#define evtimer_pending(ev, tv) event_pending((ev), EV_TIMEOUT, (tv)) +#define evtimer_initialized(ev) event_initialized(ev) +/**@}*/ + +/** + @name evsignal_* macros + + Aliases for working with signal events + */ +/**@{*/ +#define evsignal_add(ev, tv) event_add((ev), (tv)) +#define evsignal_assign(ev, b, x, cb, arg) \ + event_assign((ev), (b), (x), EV_SIGNAL|EV_PERSIST, cb, (arg)) +#define evsignal_new(b, x, cb, arg) \ + event_new((b), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg)) +#define evsignal_del(ev) event_del(ev) +#define evsignal_pending(ev, tv) event_pending((ev), EV_SIGNAL, (tv)) +#define evsignal_initialized(ev) event_initialized(ev) +/**@}*/ + +/** + A callback function for an event. + + It receives three arguments: + + @param fd An fd or signal + @param events One or more EV_* flags + @param arg A user-supplied argument. + + @see event_new() + */ +typedef void (*event_callback_fn)(evutil_socket_t, short, void *); + +/** + Return a value used to specify that the event itself must be used as the callback argument. + + The function event_new() takes a callback argument which is passed + to the event's callback function. To specify that the argument to be + passed to the callback function is the event that event_new() returns, + pass in the return value of event_self_cbarg() as the callback argument + for event_new(). + + For example: +
      +      struct event *ev = event_new(base, sock, events, callback, %event_self_cbarg());
      +  
      + + For consistency with event_new(), it is possible to pass the return value + of this function as the callback argument for event_assign() – this + achieves the same result as passing the event in directly. + + @return a value to be passed as the callback argument to event_new() or + event_assign(). + @see event_new(), event_assign() + */ +EVENT2_EXPORT_SYMBOL +void *event_self_cbarg(void); + +/** + Allocate and asssign a new event structure, ready to be added. + + The function event_new() returns a new event that can be used in + future calls to event_add() and event_del(). The fd and events + arguments determine which conditions will trigger the event; the + callback and callback_arg arguments tell Libevent what to do when the + event becomes active. + + If events contains one of EV_READ, EV_WRITE, or EV_READ|EV_WRITE, then + fd is a file descriptor or socket that should get monitored for + readiness to read, readiness to write, or readiness for either operation + (respectively). If events contains EV_SIGNAL, then fd is a signal + number to wait for. If events contains none of those flags, then the + event can be triggered only by a timeout or by manual activation with + event_active(): In this case, fd must be -1. + + The EV_PERSIST flag can also be passed in the events argument: it makes + event_add() persistent until event_del() is called. + + The EV_ET flag is compatible with EV_READ and EV_WRITE, and supported + only by certain backends. It tells Libevent to use edge-triggered + events. + + The EV_TIMEOUT flag has no effect here. + + It is okay to have multiple events all listening on the same fds; but + they must either all be edge-triggered, or all not be edge triggerd. + + When the event becomes active, the event loop will run the provided + callbuck function, with three arguments. The first will be the provided + fd value. The second will be a bitfield of the events that triggered: + EV_READ, EV_WRITE, or EV_SIGNAL. Here the EV_TIMEOUT flag indicates + that a timeout occurred, and EV_ET indicates that an edge-triggered + event occurred. The third event will be the callback_arg pointer that + you provide. + + @param base the event base to which the event should be attached. + @param fd the file descriptor or signal to be monitored, or -1. + @param events desired events to monitor: bitfield of EV_READ, EV_WRITE, + EV_SIGNAL, EV_PERSIST, EV_ET. + @param callback callback function to be invoked when the event occurs + @param callback_arg an argument to be passed to the callback function + + @return a newly allocated struct event that must later be freed with + event_free(). + @see event_free(), event_add(), event_del(), event_assign() + */ +EVENT2_EXPORT_SYMBOL +struct event *event_new(struct event_base *, evutil_socket_t, short, event_callback_fn, void *); + + +/** + Prepare a new, already-allocated event structure to be added. + + The function event_assign() prepares the event structure ev to be used + in future calls to event_add() and event_del(). Unlike event_new(), it + doesn't allocate memory itself: it requires that you have already + allocated a struct event, probably on the heap. Doing this will + typically make your code depend on the size of the event structure, and + thereby create incompatibility with future versions of Libevent. + + The easiest way to avoid this problem is just to use event_new() and + event_free() instead. + + A slightly harder way to future-proof your code is to use + event_get_struct_event_size() to determine the required size of an event + at runtime. + + Note that it is NOT safe to call this function on an event that is + active or pending. Doing so WILL corrupt internal data structures in + Libevent, and lead to strange, hard-to-diagnose bugs. You _can_ use + event_assign to change an existing event, but only if it is not active + or pending! + + The arguments for this function, and the behavior of the events that it + makes, are as for event_new(). + + @param ev an event struct to be modified + @param base the event base to which ev should be attached. + @param fd the file descriptor to be monitored + @param events desired events to monitor; can be EV_READ and/or EV_WRITE + @param callback callback function to be invoked when the event occurs + @param callback_arg an argument to be passed to the callback function + + @return 0 if success, or -1 on invalid arguments. + + @see event_new(), event_add(), event_del(), event_base_once(), + event_get_struct_event_size() + */ +EVENT2_EXPORT_SYMBOL +int event_assign(struct event *, struct event_base *, evutil_socket_t, short, event_callback_fn, void *); + +/** + Deallocate a struct event * returned by event_new(). + + If the event is pending or active, first make it non-pending and + non-active. + */ +EVENT2_EXPORT_SYMBOL +void event_free(struct event *); + +/** + * Callback type for event_finalize and event_free_finalize(). + * + * THIS IS AN EXPERIMENTAL API. IT MIGHT CHANGE BEFORE THE LIBEVENT 2.1 SERIES + * BECOMES STABLE. + * + **/ +typedef void (*event_finalize_callback_fn)(struct event *, void *); +/** + @name Finalization functions + + These functions are used to safely tear down an event in a multithreaded + application. If you construct your events with EV_FINALIZE to avoid + deadlocks, you will need a way to remove an event in the certainty that + it will definitely not be running its callback when you deallocate it + and its callback argument. + + To do this, call one of event_finalize() or event_free_finalize with + 0 for its first argument, the event to tear down as its second argument, + and a callback function as its third argument. The callback will be + invoked as part of the event loop, with the event's priority. + + After you call a finalizer function, event_add() and event_active() will + no longer work on the event, and event_del() will produce a no-op. You + must not try to change the event's fields with event_assign() or + event_set() while the finalize callback is in progress. Once the + callback has been invoked, you should treat the event structure as + containing uninitialized memory. + + The event_free_finalize() function frees the event after it's finalized; + event_finalize() does not. + + A finalizer callback must not make events pending or active. It must not + add events, activate events, or attempt to "resucitate" the event being + finalized in any way. + + THIS IS AN EXPERIMENTAL API. IT MIGHT CHANGE BEFORE THE LIBEVENT 2.1 SERIES + BECOMES STABLE. + + @return 0 on succes, -1 on failure. + */ +/**@{*/ +EVENT2_EXPORT_SYMBOL +int event_finalize(unsigned, struct event *, event_finalize_callback_fn); +EVENT2_EXPORT_SYMBOL +int event_free_finalize(unsigned, struct event *, event_finalize_callback_fn); +/**@}*/ + +/** + Schedule a one-time event + + The function event_base_once() is similar to event_new(). However, it + schedules a callback to be called exactly once, and does not require the + caller to prepare an event structure. + + Note that in Libevent 2.0 and earlier, if the event is never triggered, the + internal memory used to hold it will never be freed. In Libevent 2.1, + the internal memory will get freed by event_base_free() if the event + is never triggered. The 'arg' value, however, will not get freed in either + case--you'll need to free that on your own if you want it to go away. + + @param base an event_base + @param fd a file descriptor to monitor, or -1 for no fd. + @param events event(s) to monitor; can be any of EV_READ | + EV_WRITE, or EV_TIMEOUT + @param callback callback function to be invoked when the event occurs + @param arg an argument to be passed to the callback function + @param timeout the maximum amount of time to wait for the event. NULL + makes an EV_READ/EV_WRITE event make forever; NULL makes an + EV_TIMEOUT event succees immediately. + @return 0 if successful, or -1 if an error occurred + */ +EVENT2_EXPORT_SYMBOL +int event_base_once(struct event_base *, evutil_socket_t, short, event_callback_fn, void *, const struct timeval *); + +/** + Add an event to the set of pending events. + + The function event_add() schedules the execution of the event 'ev' when the + condition specified by event_assign() or event_new() occurs, or when the time + specified in timeout has elapesed. If atimeout is NULL, no timeout + occurs and the function will only be + called if a matching event occurs. The event in the + ev argument must be already initialized by event_assign() or event_new() + and may not be used + in calls to event_assign() until it is no longer pending. + + If the event in the ev argument already has a scheduled timeout, calling + event_add() replaces the old timeout with the new one if tv is non-NULL. + + @param ev an event struct initialized via event_assign() or event_new() + @param timeout the maximum amount of time to wait for the event, or NULL + to wait forever + @return 0 if successful, or -1 if an error occurred + @see event_del(), event_assign(), event_new() + */ +EVENT2_EXPORT_SYMBOL +int event_add(struct event *ev, const struct timeval *timeout); + +/** + Remove a timer from a pending event without removing the event itself. + + If the event has a scheduled timeout, this function unschedules it but + leaves the event otherwise pending. + + @param ev an event struct initialized via event_assign() or event_new() + @return 0 on success, or -1 if an error occurrect. +*/ +EVENT2_EXPORT_SYMBOL +int event_remove_timer(struct event *ev); + +/** + Remove an event from the set of monitored events. + + The function event_del() will cancel the event in the argument ev. If the + event has already executed or has never been added the call will have no + effect. + + @param ev an event struct to be removed from the working set + @return 0 if successful, or -1 if an error occurred + @see event_add() + */ +EVENT2_EXPORT_SYMBOL +int event_del(struct event *); + +/** + As event_del(), but never blocks while the event's callback is running + in another thread, even if the event was constructed without the + EV_FINALIZE flag. + + THIS IS AN EXPERIMENTAL API. IT MIGHT CHANGE BEFORE THE LIBEVENT 2.1 SERIES + BECOMES STABLE. + */ +EVENT2_EXPORT_SYMBOL +int event_del_noblock(struct event *ev); +/** + As event_del(), but always blocks while the event's callback is running + in another thread, even if the event was constructed with the + EV_FINALIZE flag. + + THIS IS AN EXPERIMENTAL API. IT MIGHT CHANGE BEFORE THE LIBEVENT 2.1 SERIES + BECOMES STABLE. + */ +EVENT2_EXPORT_SYMBOL +int event_del_block(struct event *ev); + +/** + Make an event active. + + You can use this function on a pending or a non-pending event to make it + active, so that its callback will be run by event_base_dispatch() or + event_base_loop(). + + One common use in multithreaded programs is to wake the thread running + event_base_loop() from another thread. + + @param ev an event to make active. + @param res a set of flags to pass to the event's callback. + @param ncalls an obsolete argument: this is ignored. + **/ +EVENT2_EXPORT_SYMBOL +void event_active(struct event *ev, int res, short ncalls); + +/** + Checks if a specific event is pending or scheduled. + + @param ev an event struct previously passed to event_add() + @param events the requested event type; any of EV_TIMEOUT|EV_READ| + EV_WRITE|EV_SIGNAL + @param tv if this field is not NULL, and the event has a timeout, + this field is set to hold the time at which the timeout will + expire. + + @return true if the event is pending on any of the events in 'what', (that + is to say, it has been added), or 0 if the event is not added. + */ +EVENT2_EXPORT_SYMBOL +int event_pending(const struct event *ev, short events, struct timeval *tv); + +/** + If called from within the callback for an event, returns that event. + + The behavior of this function is not defined when called from outside the + callback function for an event. + */ +EVENT2_EXPORT_SYMBOL +struct event *event_base_get_running_event(struct event_base *base); + +/** + Test if an event structure might be initialized. + + The event_initialized() function can be used to check if an event has been + initialized. + + Warning: This function is only useful for distinguishing a a zeroed-out + piece of memory from an initialized event, it can easily be confused by + uninitialized memory. Thus, it should ONLY be used to distinguish an + initialized event from zero. + + @param ev an event structure to be tested + @return 1 if the structure might be initialized, or 0 if it has not been + initialized + */ +EVENT2_EXPORT_SYMBOL +int event_initialized(const struct event *ev); + +/** + Get the signal number assigned to a signal event +*/ +#define event_get_signal(ev) ((int)event_get_fd(ev)) + +/** + Get the socket or signal assigned to an event, or -1 if the event has + no socket. +*/ +EVENT2_EXPORT_SYMBOL +evutil_socket_t event_get_fd(const struct event *ev); + +/** + Get the event_base associated with an event. +*/ +EVENT2_EXPORT_SYMBOL +struct event_base *event_get_base(const struct event *ev); + +/** + Return the events (EV_READ, EV_WRITE, etc) assigned to an event. +*/ +EVENT2_EXPORT_SYMBOL +short event_get_events(const struct event *ev); + +/** + Return the callback assigned to an event. +*/ +EVENT2_EXPORT_SYMBOL +event_callback_fn event_get_callback(const struct event *ev); + +/** + Return the callback argument assigned to an event. +*/ +EVENT2_EXPORT_SYMBOL +void *event_get_callback_arg(const struct event *ev); + +/** + Return the priority of an event. + @see event_priority_init(), event_get_priority() +*/ +EVENT2_EXPORT_SYMBOL +int event_get_priority(const struct event *ev); + +/** + Extract _all_ of arguments given to construct a given event. The + event_base is copied into *base_out, the fd is copied into *fd_out, and so + on. + + If any of the "_out" arguments is NULL, it will be ignored. + */ +EVENT2_EXPORT_SYMBOL +void event_get_assignment(const struct event *event, + struct event_base **base_out, evutil_socket_t *fd_out, short *events_out, + event_callback_fn *callback_out, void **arg_out); + +/** + Return the size of struct event that the Libevent library was compiled + with. + + This will be NO GREATER than sizeof(struct event) if you're running with + the same version of Libevent that your application was built with, but + otherwise might not. + + Note that it might be SMALLER than sizeof(struct event) if some future + version of Libevent adds extra padding to the end of struct event. + We might do this to help ensure ABI-compatibility between different + versions of Libevent. + */ +EVENT2_EXPORT_SYMBOL +size_t event_get_struct_event_size(void); + +/** + Get the Libevent version. + + Note that this will give you the version of the library that you're + currently linked against, not the version of the headers that you've + compiled against. + + @return a string containing the version number of Libevent +*/ +EVENT2_EXPORT_SYMBOL +const char *event_get_version(void); + +/** + Return a numeric representation of Libevent's version. + + Note that this will give you the version of the library that you're + currently linked against, not the version of the headers you've used to + compile. + + The format uses one byte each for the major, minor, and patchlevel parts of + the version number. The low-order byte is unused. For example, version + 2.0.1-alpha has a numeric representation of 0x02000100 +*/ +EVENT2_EXPORT_SYMBOL +ev_uint32_t event_get_version_number(void); + +/** As event_get_version, but gives the version of Libevent's headers. */ +#define LIBEVENT_VERSION EVENT__VERSION +/** As event_get_version_number, but gives the version number of Libevent's + * headers. */ +#define LIBEVENT_VERSION_NUMBER EVENT__NUMERIC_VERSION + +/** Largest number of priorities that Libevent can support. */ +#define EVENT_MAX_PRIORITIES 256 +/** + Set the number of different event priorities + + By default Libevent schedules all active events with the same priority. + However, some time it is desirable to process some events with a higher + priority than others. For that reason, Libevent supports strict priority + queues. Active events with a lower priority are always processed before + events with a higher priority. + + The number of different priorities can be set initially with the + event_base_priority_init() function. This function should be called + before the first call to event_base_dispatch(). The + event_priority_set() function can be used to assign a priority to an + event. By default, Libevent assigns the middle priority to all events + unless their priority is explicitly set. + + Note that urgent-priority events can starve less-urgent events: after + running all urgent-priority callbacks, Libevent checks for more urgent + events again, before running less-urgent events. Less-urgent events + will not have their callbacks run until there are no events more urgent + than them that want to be active. + + @param eb the event_base structure returned by event_base_new() + @param npriorities the maximum number of priorities + @return 0 if successful, or -1 if an error occurred + @see event_priority_set() + */ +EVENT2_EXPORT_SYMBOL +int event_base_priority_init(struct event_base *, int); + +/** + Get the number of different event priorities. + + @param eb the event_base structure returned by event_base_new() + @return Number of different event priorities + @see event_base_priority_init() +*/ +EVENT2_EXPORT_SYMBOL +int event_base_get_npriorities(struct event_base *eb); + +/** + Assign a priority to an event. + + @param ev an event struct + @param priority the new priority to be assigned + @return 0 if successful, or -1 if an error occurred + @see event_priority_init(), event_get_priority() + */ +EVENT2_EXPORT_SYMBOL +int event_priority_set(struct event *, int); + +/** + Prepare an event_base to use a large number of timeouts with the same + duration. + + Libevent's default scheduling algorithm is optimized for having a large + number of timeouts with their durations more or less randomly + distributed. But if you have a large number of timeouts that all have + the same duration (for example, if you have a large number of + connections that all have a 10-second timeout), then you can improve + Libevent's performance by telling Libevent about it. + + To do this, call this function with the common duration. It will return a + pointer to a different, opaque timeout value. (Don't depend on its actual + contents!) When you use this timeout value in event_add(), Libevent will + schedule the event more efficiently. + + (This optimization probably will not be worthwhile until you have thousands + or tens of thousands of events with the same timeout.) + */ +EVENT2_EXPORT_SYMBOL +const struct timeval *event_base_init_common_timeout(struct event_base *base, + const struct timeval *duration); + +#if !defined(EVENT__DISABLE_MM_REPLACEMENT) || defined(EVENT_IN_DOXYGEN_) +/** + Override the functions that Libevent uses for memory management. + + Usually, Libevent uses the standard libc functions malloc, realloc, and + free to allocate memory. Passing replacements for those functions to + event_set_mem_functions() overrides this behavior. + + Note that all memory returned from Libevent will be allocated by the + replacement functions rather than by malloc() and realloc(). Thus, if you + have replaced those functions, it will not be appropriate to free() memory + that you get from Libevent. Instead, you must use the free_fn replacement + that you provided. + + Note also that if you are going to call this function, you should do so + before any call to any Libevent function that does allocation. + Otherwise, those funtions will allocate their memory using malloc(), but + then later free it using your provided free_fn. + + @param malloc_fn A replacement for malloc. + @param realloc_fn A replacement for realloc + @param free_fn A replacement for free. + **/ +EVENT2_EXPORT_SYMBOL +void event_set_mem_functions( + void *(*malloc_fn)(size_t sz), + void *(*realloc_fn)(void *ptr, size_t sz), + void (*free_fn)(void *ptr)); +/** This definition is present if Libevent was built with support for + event_set_mem_functions() */ +#define EVENT_SET_MEM_FUNCTIONS_IMPLEMENTED +#endif + +/** + Writes a human-readable description of all inserted and/or active + events to a provided stdio stream. + + This is intended for debugging; its format is not guaranteed to be the same + between libevent versions. + + @param base An event_base on which to scan the events. + @param output A stdio file to write on. + */ +EVENT2_EXPORT_SYMBOL +void event_base_dump_events(struct event_base *, FILE *); + + +/** + Activates all pending events for the given fd and event mask. + + This function activates pending events only. Events which have not been + added will not become active. + + @param base the event_base on which to activate the events. + @param fd An fd to active events on. + @param events One or more of EV_{READ,WRITE}. + */ +EVENT2_EXPORT_SYMBOL +void event_base_active_by_fd(struct event_base *base, evutil_socket_t fd, short events); + +/** + Activates all pending signals with a given signal number + + This function activates pending events only. Events which have not been + added will not become active. + + @param base the event_base on which to activate the events. + @param fd The signal to active events on. + */ +EVENT2_EXPORT_SYMBOL +void event_base_active_by_signal(struct event_base *base, int sig); + +/** + * Callback for iterating events in an event base via event_base_foreach_event + */ +typedef int (*event_base_foreach_event_cb)(const struct event_base *, const struct event *, void *); + +/** + Iterate over all added or active events events in an event loop, and invoke + a given callback on each one. + + The callback must not call any function that modifies the event base, that + modifies any event in the event base, or that adds or removes any event to + the event base. Doing so is unsupported and will lead to undefined + behavior -- likely, to crashes. + + event_base_foreach_event() holds a lock on the event_base() for the whole + time it's running: slow callbacks are not advisable. + + Note that Libevent adds some events of its own to make pieces of its + functionality work. You must not assume that the only events you'll + encounter will be the ones you added yourself. + + The callback function must return 0 to continue iteration, or some other + integer to stop iterating. + + @param base An event_base on which to scan the events. + @param fn A callback function to receive the events. + @param arg An argument passed to the callback function. + @return 0 if we iterated over every event, or the value returned by the + callback function if the loop exited early. +*/ +EVENT2_EXPORT_SYMBOL +int event_base_foreach_event(struct event_base *base, event_base_foreach_event_cb fn, void *arg); + + +/** Sets 'tv' to the current time (as returned by gettimeofday()), + looking at the cached value in 'base' if possible, and calling + gettimeofday() or clock_gettime() as appropriate if there is no + cached time. + + Generally, this value will only be cached while actually + processing event callbacks, and may be very inaccuate if your + callbacks take a long time to execute. + + Returns 0 on success, negative on failure. + */ +EVENT2_EXPORT_SYMBOL +int event_base_gettimeofday_cached(struct event_base *base, + struct timeval *tv); + +/** Update cached_tv in the 'base' to the current time + * + * You can use this function is useful for selectively increasing + * the accuracy of the cached time value in 'base' during callbacks + * that take a long time to execute. + * + * This function has no effect if the base is currently not in its + * event loop, or if timeval caching is disabled via + * EVENT_BASE_FLAG_NO_CACHE_TIME. + * + * @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int event_base_update_cache_time(struct event_base *base); + +/** Release up all globally-allocated resources allocated by Libevent. + + This function does not free developer-controlled resources like + event_bases, events, bufferevents, listeners, and so on. It only releases + resources like global locks that there is no other way to free. + + It is not actually necessary to call this function before exit: every + resource that it frees would be released anyway on exit. It mainly exists + so that resource-leak debugging tools don't see Libevent as holding + resources at exit. + + You should only call this function when no other Libevent functions will + be invoked -- e.g., when cleanly exiting a program. + */ +EVENT2_EXPORT_SYMBOL +void libevent_global_shutdown(void); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_EVENT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/event_compat.h b/contrib/ntp/sntp/libevent/include/event2/event_compat.h new file mode 100644 index 000000000..5110175a1 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/event_compat.h @@ -0,0 +1,230 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_EVENT_COMPAT_H_INCLUDED_ +#define EVENT2_EVENT_COMPAT_H_INCLUDED_ + +/** @file event2/event_compat.h + + Potentially non-threadsafe versions of the functions in event.h: provided + only for backwards compatibility. + + In the oldest versions of Libevent, event_base was not a first-class + structure. Instead, there was a single event base that every function + manipulated. Later, when separate event bases were added, the old functions + that didn't take an event_base argument needed to work by manipulating the + "current" event base. This could lead to thread-safety issues, and obscure, + hard-to-diagnose bugs. + + @deprecated All functions in this file are by definition deprecated. + */ +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +/** + Initialize the event API. + + The event API needs to be initialized with event_init() before it can be + used. Sets the global current base that gets used for events that have no + base associated with them. + + @deprecated This function is deprecated because it replaces the "current" + event_base, and is totally unsafe for multithreaded use. The replacement + is event_base_new(). + + @see event_base_set(), event_base_new() + */ +EVENT2_EXPORT_SYMBOL +struct event_base *event_init(void); + +/** + Loop to process events. + + Like event_base_dispatch(), but uses the "current" base. + + @deprecated This function is deprecated because it is easily confused by + multiple calls to event_init(), and because it is not safe for + multithreaded use. The replacement is event_base_dispatch(). + + @see event_base_dispatch(), event_init() + */ +EVENT2_EXPORT_SYMBOL +int event_dispatch(void); + +/** + Handle events. + + This function behaves like event_base_loop(), but uses the "current" base + + @deprecated This function is deprecated because it uses the event base from + the last call to event_init, and is therefore not safe for multithreaded + use. The replacement is event_base_loop(). + + @see event_base_loop(), event_init() +*/ +EVENT2_EXPORT_SYMBOL +int event_loop(int); + + +/** + Exit the event loop after the specified time. + + This function behaves like event_base_loopexit(), except that it uses the + "current" base. + + @deprecated This function is deprecated because it uses the event base from + the last call to event_init, and is therefore not safe for multithreaded + use. The replacement is event_base_loopexit(). + + @see event_init, event_base_loopexit() + */ +EVENT2_EXPORT_SYMBOL +int event_loopexit(const struct timeval *); + + +/** + Abort the active event_loop() immediately. + + This function behaves like event_base_loopbreakt(), except that it uses the + "current" base. + + @deprecated This function is deprecated because it uses the event base from + the last call to event_init, and is therefore not safe for multithreaded + use. The replacement is event_base_loopbreak(). + + @see event_base_loopbreak(), event_init() + */ +EVENT2_EXPORT_SYMBOL +int event_loopbreak(void); + +/** + Schedule a one-time event to occur. + + @deprecated This function is obsolete, and has been replaced by + event_base_once(). Its use is deprecated because it relies on the + "current" base configured by event_init(). + + @see event_base_once() + */ +EVENT2_EXPORT_SYMBOL +int event_once(evutil_socket_t , short, + void (*)(evutil_socket_t, short, void *), void *, const struct timeval *); + + +/** + Get the kernel event notification mechanism used by Libevent. + + @deprecated This function is obsolete, and has been replaced by + event_base_get_method(). Its use is deprecated because it relies on the + "current" base configured by event_init(). + + @see event_base_get_method() + */ +EVENT2_EXPORT_SYMBOL +const char *event_get_method(void); + + +/** + Set the number of different event priorities. + + @deprecated This function is deprecated because it is easily confused by + multiple calls to event_init(), and because it is not safe for + multithreaded use. The replacement is event_base_priority_init(). + + @see event_base_priority_init() + */ +EVENT2_EXPORT_SYMBOL +int event_priority_init(int); + +/** + Prepare an event structure to be added. + + @deprecated event_set() is not recommended for new code, because it requires + a subsequent call to event_base_set() to be safe under most circumstances. + Use event_assign() or event_new() instead. + */ +EVENT2_EXPORT_SYMBOL +void event_set(struct event *, evutil_socket_t, short, void (*)(evutil_socket_t, short, void *), void *); + +#define evtimer_set(ev, cb, arg) event_set((ev), -1, 0, (cb), (arg)) +#define evsignal_set(ev, x, cb, arg) \ + event_set((ev), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg)) + + +/** + @name timeout_* macros + + @deprecated These macros are deprecated because their naming is inconsistent + with the rest of Libevent. Use the evtimer_* macros instead. + @{ + */ +#define timeout_add(ev, tv) event_add((ev), (tv)) +#define timeout_set(ev, cb, arg) event_set((ev), -1, 0, (cb), (arg)) +#define timeout_del(ev) event_del(ev) +#define timeout_pending(ev, tv) event_pending((ev), EV_TIMEOUT, (tv)) +#define timeout_initialized(ev) event_initialized(ev) +/**@}*/ + +/** + @name signal_* macros + + @deprecated These macros are deprecated because their naming is inconsistent + with the rest of Libevent. Use the evsignal_* macros instead. + @{ + */ +#define signal_add(ev, tv) event_add((ev), (tv)) +#define signal_set(ev, x, cb, arg) \ + event_set((ev), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg)) +#define signal_del(ev) event_del(ev) +#define signal_pending(ev, tv) event_pending((ev), EV_SIGNAL, (tv)) +#define signal_initialized(ev) event_initialized(ev) +/**@}*/ + +#ifndef EVENT_FD +/* These macros are obsolete; use event_get_fd and event_get_signal instead. */ +#define EVENT_FD(ev) ((int)event_get_fd(ev)) +#define EVENT_SIGNAL(ev) event_get_signal(ev) +#endif + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/event_struct.h b/contrib/ntp/sntp/libevent/include/event2/event_struct.h new file mode 100644 index 000000000..1c8b71b6b --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/event_struct.h @@ -0,0 +1,180 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_EVENT_STRUCT_H_INCLUDED_ +#define EVENT2_EVENT_STRUCT_H_INCLUDED_ + +/** @file event2/event_struct.h + + Structures used by event.h. Using these structures directly WILL harm + forward compatibility: be careful. + + No field declared in this file should be used directly in user code. Except + for historical reasons, these fields would not be exposed at all. + */ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +/* For evkeyvalq */ +#include + +#define EVLIST_TIMEOUT 0x01 +#define EVLIST_INSERTED 0x02 +#define EVLIST_SIGNAL 0x04 +#define EVLIST_ACTIVE 0x08 +#define EVLIST_INTERNAL 0x10 +#define EVLIST_ACTIVE_LATER 0x20 +#define EVLIST_FINALIZING 0x40 +#define EVLIST_INIT 0x80 + +#define EVLIST_ALL 0xff + +/* Fix so that people don't have to run with */ +#ifndef TAILQ_ENTRY +#define EVENT_DEFINED_TQENTRY_ +#define TAILQ_ENTRY(type) \ +struct { \ + struct type *tqe_next; /* next element */ \ + struct type **tqe_prev; /* address of previous next element */ \ +} +#endif /* !TAILQ_ENTRY */ + +#ifndef TAILQ_HEAD +#define EVENT_DEFINED_TQHEAD_ +#define TAILQ_HEAD(name, type) \ +struct name { \ + struct type *tqh_first; \ + struct type **tqh_last; \ +} +#endif + +/* Fix so that people don't have to run with */ +#ifndef LIST_ENTRY +#define EVENT_DEFINED_LISTENTRY_ +#define LIST_ENTRY(type) \ +struct { \ + struct type *le_next; /* next element */ \ + struct type **le_prev; /* address of previous next element */ \ +} +#endif /* !LIST_ENTRY */ + +#ifndef LIST_HEAD +#define EVENT_DEFINED_LISTHEAD_ +#define LIST_HEAD(name, type) \ +struct name { \ + struct type *lh_first; /* first element */ \ + } +#endif /* !LIST_HEAD */ + +struct event; + +struct event_callback { + TAILQ_ENTRY(event_callback) evcb_active_next; + short evcb_flags; + ev_uint8_t evcb_pri; /* smaller numbers are higher priority */ + ev_uint8_t evcb_closure; + /* allows us to adopt for different types of events */ + union { + void (*evcb_callback)(evutil_socket_t, short, void *); + void (*evcb_selfcb)(struct event_callback *, void *); + void (*evcb_evfinalize)(struct event *, void *); + void (*evcb_cbfinalize)(struct event_callback *, void *); + } evcb_cb_union; + void *evcb_arg; +}; + +struct event_base; +struct event { + struct event_callback ev_evcallback; + + /* for managing timeouts */ + union { + TAILQ_ENTRY(event) ev_next_with_common_timeout; + int min_heap_idx; + } ev_timeout_pos; + evutil_socket_t ev_fd; + + struct event_base *ev_base; + + union { + /* used for io events */ + struct { + LIST_ENTRY (event) ev_io_next; + struct timeval ev_timeout; + } ev_io; + + /* used by signal events */ + struct { + LIST_ENTRY (event) ev_signal_next; + short ev_ncalls; + /* Allows deletes in callback */ + short *ev_pncalls; + } ev_signal; + } ev_; + + short ev_events; + short ev_res; /* result passed to event callback */ + struct timeval ev_timeout; +}; + +TAILQ_HEAD (event_list, event); + +#ifdef EVENT_DEFINED_TQENTRY_ +#undef TAILQ_ENTRY +#endif + +#ifdef EVENT_DEFINED_TQHEAD_ +#undef TAILQ_HEAD +#endif + +LIST_HEAD (event_dlist, event); + +#ifdef EVENT_DEFINED_LISTENTRY_ +#undef LIST_ENTRY +#endif + +#ifdef EVENT_DEFINED_LISTHEAD_ +#undef LIST_HEAD +#endif + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_EVENT_STRUCT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/http.h b/contrib/ntp/sntp/libevent/include/event2/http.h new file mode 100644 index 000000000..4284d5fc3 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/http.h @@ -0,0 +1,1154 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_HTTP_H_INCLUDED_ +#define EVENT2_HTTP_H_INCLUDED_ + +/* For int types. */ +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* In case we haven't included the right headers yet. */ +struct evbuffer; +struct event_base; +struct bufferevent; +struct evhttp_connection; + +/** @file event2/http.h + * + * Basic support for HTTP serving. + * + * As Libevent is a library for dealing with event notification and most + * interesting applications are networked today, I have often found the + * need to write HTTP code. The following prototypes and definitions provide + * an application with a minimal interface for making HTTP requests and for + * creating a very simple HTTP server. + */ + +/* Response codes */ +#define HTTP_OK 200 /**< request completed ok */ +#define HTTP_NOCONTENT 204 /**< request does not have content */ +#define HTTP_MOVEPERM 301 /**< the uri moved permanently */ +#define HTTP_MOVETEMP 302 /**< the uri moved temporarily */ +#define HTTP_NOTMODIFIED 304 /**< page was not modified from last */ +#define HTTP_BADREQUEST 400 /**< invalid http request was made */ +#define HTTP_NOTFOUND 404 /**< could not find content for uri */ +#define HTTP_BADMETHOD 405 /**< method not allowed for this uri */ +#define HTTP_ENTITYTOOLARGE 413 /**< */ +#define HTTP_EXPECTATIONFAILED 417 /**< we can't handle this expectation */ +#define HTTP_INTERNAL 500 /**< internal error */ +#define HTTP_NOTIMPLEMENTED 501 /**< not implemented */ +#define HTTP_SERVUNAVAIL 503 /**< the server is not available */ + +struct evhttp; +struct evhttp_request; +struct evkeyvalq; +struct evhttp_bound_socket; +struct evconnlistener; +struct evdns_base; + +/** + * Create a new HTTP server. + * + * @param base (optional) the event base to receive the HTTP events + * @return a pointer to a newly initialized evhttp server structure + * @see evhttp_free() + */ +EVENT2_EXPORT_SYMBOL +struct evhttp *evhttp_new(struct event_base *base); + +/** + * Binds an HTTP server on the specified address and port. + * + * Can be called multiple times to bind the same http server + * to multiple different ports. + * + * @param http a pointer to an evhttp object + * @param address a string containing the IP address to listen(2) on + * @param port the port number to listen on + * @return 0 on success, -1 on failure. + * @see evhttp_accept_socket() + */ +EVENT2_EXPORT_SYMBOL +int evhttp_bind_socket(struct evhttp *http, const char *address, ev_uint16_t port); + +/** + * Like evhttp_bind_socket(), but returns a handle for referencing the socket. + * + * The returned pointer is not valid after \a http is freed. + * + * @param http a pointer to an evhttp object + * @param address a string containing the IP address to listen(2) on + * @param port the port number to listen on + * @return Handle for the socket on success, NULL on failure. + * @see evhttp_bind_socket(), evhttp_del_accept_socket() + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_bound_socket *evhttp_bind_socket_with_handle(struct evhttp *http, const char *address, ev_uint16_t port); + +/** + * Makes an HTTP server accept connections on the specified socket. + * + * This may be useful to create a socket and then fork multiple instances + * of an http server, or when a socket has been communicated via file + * descriptor passing in situations where an http servers does not have + * permissions to bind to a low-numbered port. + * + * Can be called multiple times to have the http server listen to + * multiple different sockets. + * + * @param http a pointer to an evhttp object + * @param fd a socket fd that is ready for accepting connections + * @return 0 on success, -1 on failure. + * @see evhttp_bind_socket() + */ +EVENT2_EXPORT_SYMBOL +int evhttp_accept_socket(struct evhttp *http, evutil_socket_t fd); + +/** + * Like evhttp_accept_socket(), but returns a handle for referencing the socket. + * + * The returned pointer is not valid after \a http is freed. + * + * @param http a pointer to an evhttp object + * @param fd a socket fd that is ready for accepting connections + * @return Handle for the socket on success, NULL on failure. + * @see evhttp_accept_socket(), evhttp_del_accept_socket() + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_bound_socket *evhttp_accept_socket_with_handle(struct evhttp *http, evutil_socket_t fd); + +/** + * The most low-level evhttp_bind/accept method: takes an evconnlistener, and + * returns an evhttp_bound_socket. The listener will be freed when the bound + * socket is freed. + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_bound_socket *evhttp_bind_listener(struct evhttp *http, struct evconnlistener *listener); + +/** + * Return the listener used to implement a bound socket. + */ +EVENT2_EXPORT_SYMBOL +struct evconnlistener *evhttp_bound_socket_get_listener(struct evhttp_bound_socket *bound); + +typedef void evhttp_bound_socket_foreach_fn(struct evhttp_bound_socket *, void *); +/** + * Applies the function specified in the first argument to all + * evhttp_bound_sockets associated with "http". The user must not + * attempt to free or remove any connections, sockets or listeners + * in the callback "function". + * + * @param http pointer to an evhttp object + * @param function function to apply to every bound socket + * @param argument pointer value passed to function for every socket iterated + */ +EVENT2_EXPORT_SYMBOL +void evhttp_foreach_bound_socket(struct evhttp *http, evhttp_bound_socket_foreach_fn *function, void *argument); + +/** + * Makes an HTTP server stop accepting connections on the specified socket + * + * This may be useful when a socket has been sent via file descriptor passing + * and is no longer needed by the current process. + * + * If you created this bound socket with evhttp_bind_socket_with_handle or + * evhttp_accept_socket_with_handle, this function closes the fd you provided. + * If you created this bound socket with evhttp_bind_listener, this function + * frees the listener you provided. + * + * \a bound_socket is an invalid pointer after this call returns. + * + * @param http a pointer to an evhttp object + * @param bound_socket a handle returned by evhttp_{bind,accept}_socket_with_handle + * @see evhttp_bind_socket_with_handle(), evhttp_accept_socket_with_handle() + */ +EVENT2_EXPORT_SYMBOL +void evhttp_del_accept_socket(struct evhttp *http, struct evhttp_bound_socket *bound_socket); + +/** + * Get the raw file descriptor referenced by an evhttp_bound_socket. + * + * @param bound_socket a handle returned by evhttp_{bind,accept}_socket_with_handle + * @return the file descriptor used by the bound socket + * @see evhttp_bind_socket_with_handle(), evhttp_accept_socket_with_handle() + */ +EVENT2_EXPORT_SYMBOL +evutil_socket_t evhttp_bound_socket_get_fd(struct evhttp_bound_socket *bound_socket); + +/** + * Free the previously created HTTP server. + * + * Works only if no requests are currently being served. + * + * @param http the evhttp server object to be freed + * @see evhttp_start() + */ +EVENT2_EXPORT_SYMBOL +void evhttp_free(struct evhttp* http); + +/** XXX Document. */ +EVENT2_EXPORT_SYMBOL +void evhttp_set_max_headers_size(struct evhttp* http, ev_ssize_t max_headers_size); +/** XXX Document. */ +EVENT2_EXPORT_SYMBOL +void evhttp_set_max_body_size(struct evhttp* http, ev_ssize_t max_body_size); + +/** + Set the value to use for the Content-Type header when none was provided. If + the content type string is NULL, the Content-Type header will not be + automatically added. + + @param http the http server on which to set the default content type + @param content_type the value for the Content-Type header +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_set_default_content_type(struct evhttp *http, + const char *content_type); + +/** + Sets the what HTTP methods are supported in requests accepted by this + server, and passed to user callbacks. + + If not supported they will generate a "405 Method not allowed" response. + + By default this includes the following methods: GET, POST, HEAD, PUT, DELETE + + @param http the http server on which to set the methods + @param methods bit mask constructed from evhttp_cmd_type values +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_set_allowed_methods(struct evhttp* http, ev_uint16_t methods); + +/** + Set a callback for a specified URI + + @param http the http sever on which to set the callback + @param path the path for which to invoke the callback + @param cb the callback function that gets invoked on requesting path + @param cb_arg an additional context argument for the callback + @return 0 on success, -1 if the callback existed already, -2 on failure +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_set_cb(struct evhttp *http, const char *path, + void (*cb)(struct evhttp_request *, void *), void *cb_arg); + +/** Removes the callback for a specified URI */ +EVENT2_EXPORT_SYMBOL +int evhttp_del_cb(struct evhttp *, const char *); + +/** + Set a callback for all requests that are not caught by specific callbacks + + Invokes the specified callback for all requests that do not match any of + the previously specified request paths. This is catchall for requests not + specifically configured with evhttp_set_cb(). + + @param http the evhttp server object for which to set the callback + @param cb the callback to invoke for any unmatched requests + @param arg an context argument for the callback +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_set_gencb(struct evhttp *http, + void (*cb)(struct evhttp_request *, void *), void *arg); + +/** + Set a callback used to create new bufferevents for connections + to a given evhttp object. + + You can use this to override the default bufferevent type -- for example, + to make this evhttp object use SSL bufferevents rather than unencrypted + ones. + + New bufferevents must be allocated with no fd set on them. + + @param http the evhttp server object for which to set the callback + @param cb the callback to invoke for incoming connections + @param arg an context argument for the callback + */ +EVENT2_EXPORT_SYMBOL +void evhttp_set_bevcb(struct evhttp *http, + struct bufferevent *(*cb)(struct event_base *, void *), void *arg); + +/** + Adds a virtual host to the http server. + + A virtual host is a newly initialized evhttp object that has request + callbacks set on it via evhttp_set_cb() or evhttp_set_gencb(). It + most not have any listing sockets associated with it. + + If the virtual host has not been removed by the time that evhttp_free() + is called on the main http server, it will be automatically freed, too. + + It is possible to have hierarchical vhosts. For example: A vhost + with the pattern *.example.com may have other vhosts with patterns + foo.example.com and bar.example.com associated with it. + + @param http the evhttp object to which to add a virtual host + @param pattern the glob pattern against which the hostname is matched. + The match is case insensitive and follows otherwise regular shell + matching. + @param vhost the virtual host to add the regular http server. + @return 0 on success, -1 on failure + @see evhttp_remove_virtual_host() +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_add_virtual_host(struct evhttp* http, const char *pattern, + struct evhttp* vhost); + +/** + Removes a virtual host from the http server. + + @param http the evhttp object from which to remove the virtual host + @param vhost the virtual host to remove from the regular http server. + @return 0 on success, -1 on failure + @see evhttp_add_virtual_host() +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_remove_virtual_host(struct evhttp* http, struct evhttp* vhost); + +/** + Add a server alias to an http object. The http object can be a virtual + host or the main server. + + @param http the evhttp object + @param alias the alias to add + @see evhttp_add_remove_alias() +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_add_server_alias(struct evhttp *http, const char *alias); + +/** + Remove a server alias from an http object. + + @param http the evhttp object + @param alias the alias to remove + @see evhttp_add_server_alias() +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_remove_server_alias(struct evhttp *http, const char *alias); + +/** + * Set the timeout for an HTTP request. + * + * @param http an evhttp object + * @param timeout_in_secs the timeout, in seconds + */ +EVENT2_EXPORT_SYMBOL +void evhttp_set_timeout(struct evhttp *http, int timeout_in_secs); + +/** + * Set the timeout for an HTTP request. + * + * @param http an evhttp object + * @param tv the timeout, or NULL + */ +EVENT2_EXPORT_SYMBOL +void evhttp_set_timeout_tv(struct evhttp *http, const struct timeval* tv); + +/* Request/Response functionality */ + +/** + * Send an HTML error message to the client. + * + * @param req a request object + * @param error the HTTP error code + * @param reason a brief explanation of the error. If this is NULL, we'll + * just use the standard meaning of the error code. + */ +EVENT2_EXPORT_SYMBOL +void evhttp_send_error(struct evhttp_request *req, int error, + const char *reason); + +/** + * Send an HTML reply to the client. + * + * The body of the reply consists of the data in databuf. After calling + * evhttp_send_reply() databuf will be empty, but the buffer is still + * owned by the caller and needs to be deallocated by the caller if + * necessary. + * + * @param req a request object + * @param code the HTTP response code to send + * @param reason a brief message to send with the response code + * @param databuf the body of the response + */ +EVENT2_EXPORT_SYMBOL +void evhttp_send_reply(struct evhttp_request *req, int code, + const char *reason, struct evbuffer *databuf); + +/* Low-level response interface, for streaming/chunked replies */ + +/** + Initiate a reply that uses Transfer-Encoding chunked. + + This allows the caller to stream the reply back to the client and is + useful when either not all of the reply data is immediately available + or when sending very large replies. + + The caller needs to supply data chunks with evhttp_send_reply_chunk() + and complete the reply by calling evhttp_send_reply_end(). + + @param req a request object + @param code the HTTP response code to send + @param reason a brief message to send with the response code +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_send_reply_start(struct evhttp_request *req, int code, + const char *reason); + +/** + Send another data chunk as part of an ongoing chunked reply. + + The reply chunk consists of the data in databuf. After calling + evhttp_send_reply_chunk() databuf will be empty, but the buffer is + still owned by the caller and needs to be deallocated by the caller + if necessary. + + @param req a request object + @param databuf the data chunk to send as part of the reply. +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_send_reply_chunk(struct evhttp_request *req, + struct evbuffer *databuf); + +/** + Send another data chunk as part of an ongoing chunked reply. + + The reply chunk consists of the data in databuf. After calling + evhttp_send_reply_chunk() databuf will be empty, but the buffer is + still owned by the caller and needs to be deallocated by the caller + if necessary. + + @param req a request object + @param databuf the data chunk to send as part of the reply. + @param cb callback funcion + @param call back's argument. +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_send_reply_chunk_with_cb(struct evhttp_request *, struct evbuffer *, + void (*cb)(struct evhttp_connection *, void *), void *arg); + +/** + Complete a chunked reply, freeing the request as appropriate. + + @param req a request object +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_send_reply_end(struct evhttp_request *req); + +/* + * Interfaces for making requests + */ + +/** The different request types supported by evhttp. These are as specified + * in RFC2616, except for PATCH which is specified by RFC5789. + * + * By default, only some of these methods are accepted and passed to user + * callbacks; use evhttp_set_allowed_methods() to change which methods + * are allowed. + */ +enum evhttp_cmd_type { + EVHTTP_REQ_GET = 1 << 0, + EVHTTP_REQ_POST = 1 << 1, + EVHTTP_REQ_HEAD = 1 << 2, + EVHTTP_REQ_PUT = 1 << 3, + EVHTTP_REQ_DELETE = 1 << 4, + EVHTTP_REQ_OPTIONS = 1 << 5, + EVHTTP_REQ_TRACE = 1 << 6, + EVHTTP_REQ_CONNECT = 1 << 7, + EVHTTP_REQ_PATCH = 1 << 8 +}; + +/** a request object can represent either a request or a reply */ +enum evhttp_request_kind { EVHTTP_REQUEST, EVHTTP_RESPONSE }; + +/** + * Create and return a connection object that can be used to for making HTTP + * requests. The connection object tries to resolve address and establish the + * connection when it is given an http request object. + * + * @param base the event_base to use for handling the connection + * @param dnsbase the dns_base to use for resolving host names; if not + * specified host name resolution will block. + * @param bev a bufferevent to use for connecting to the server; if NULL, a + * socket-based bufferevent will be created. This buffrevent will be freed + * when the connection closes. It must have no fd set on it. + * @param address the address to which to connect + * @param port the port to connect to + * @return an evhttp_connection object that can be used for making requests + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_connection *evhttp_connection_base_bufferevent_new( + struct event_base *base, struct evdns_base *dnsbase, struct bufferevent* bev, const char *address, unsigned short port); + +/** + * Return the bufferevent that an evhttp_connection is using. + */ +EVENT2_EXPORT_SYMBOL +struct bufferevent* evhttp_connection_get_bufferevent(struct evhttp_connection *evcon); + +/** + * Return the HTTP server associated with this connection, or NULL. + */ +EVENT2_EXPORT_SYMBOL +struct evhttp *evhttp_connection_get_server(struct evhttp_connection *evcon); + +/** + * Creates a new request object that needs to be filled in with the request + * parameters. The callback is executed when the request completed or an + * error occurred. + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_request *evhttp_request_new( + void (*cb)(struct evhttp_request *, void *), void *arg); + +/** + * Enable delivery of chunks to requestor. + * @param cb will be called after every read of data with the same argument + * as the completion callback. Will never be called on an empty + * response. May drain the input buffer; it will be drained + * automatically on return. + */ +EVENT2_EXPORT_SYMBOL +void evhttp_request_set_chunked_cb(struct evhttp_request *, + void (*cb)(struct evhttp_request *, void *)); + +/** + * Register callback for additional parsing of request headers. + * @param cb will be called after receiving and parsing the full header. + * It allows analyzing the header and possibly closing the connection + * by returning a value < 0. + */ +EVENT2_EXPORT_SYMBOL +void evhttp_request_set_header_cb(struct evhttp_request *, + int (*cb)(struct evhttp_request *, void *)); + +/** + * The different error types supported by evhttp + * + * @see evhttp_request_set_error_cb() + */ +enum evhttp_request_error { + /** + * Timeout reached, also @see evhttp_connection_set_timeout() + */ + EVREQ_HTTP_TIMEOUT, + /** + * EOF reached + */ + EVREQ_HTTP_EOF, + /** + * Error while reading header, or invalid header + */ + EVREQ_HTTP_INVALID_HEADER, + /** + * Error encountered while reading or writing + */ + EVREQ_HTTP_BUFFER_ERROR, + /** + * The evhttp_cancel_request() called on this request. + */ + EVREQ_HTTP_REQUEST_CANCEL, + /** + * Body is greater then evhttp_connection_set_max_body_size() + */ + EVREQ_HTTP_DATA_TOO_LONG +}; +/** + * Set a callback for errors + * @see evhttp_request_error for error types. + * + * On error, both the error callback and the regular callback will be called, + * error callback is called before the regular callback. + **/ +EVENT2_EXPORT_SYMBOL +void evhttp_request_set_error_cb(struct evhttp_request *, + void (*)(enum evhttp_request_error, void *)); + +/** + * Set a callback to be called on request completion of evhttp_send_* function. + * + * The callback function will be called on the completion of the request after + * the output data has been written and before the evhttp_request object + * is destroyed. This can be useful for tracking resources associated with a + * request (ex: timing metrics). + * + * @param req a request object + * @param cb callback function that will be called on request completion + * @param cb_arg an additional context argument for the callback + */ +EVENT2_EXPORT_SYMBOL +void evhttp_request_set_on_complete_cb(struct evhttp_request *req, + void (*cb)(struct evhttp_request *, void *), void *cb_arg); + +/** Frees the request object and removes associated events. */ +EVENT2_EXPORT_SYMBOL +void evhttp_request_free(struct evhttp_request *req); + +/** + * Create and return a connection object that can be used to for making HTTP + * requests. The connection object tries to resolve address and establish the + * connection when it is given an http request object. + * + * @param base the event_base to use for handling the connection + * @param dnsbase the dns_base to use for resolving host names; if not + * specified host name resolution will block. + * @param address the address to which to connect + * @param port the port to connect to + * @return an evhttp_connection object that can be used for making requests + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_connection *evhttp_connection_base_new( + struct event_base *base, struct evdns_base *dnsbase, + const char *address, unsigned short port); + +/** + * Set family hint for DNS requests. + */ +void evhttp_connection_set_family(struct evhttp_connection *evcon, + int family); + +/** Takes ownership of the request object + * + * Can be used in a request callback to keep onto the request until + * evhttp_request_free() is explicitly called by the user. + */ +EVENT2_EXPORT_SYMBOL +void evhttp_request_own(struct evhttp_request *req); + +/** Returns 1 if the request is owned by the user */ +EVENT2_EXPORT_SYMBOL +int evhttp_request_is_owned(struct evhttp_request *req); + +/** + * Returns the connection object associated with the request or NULL + * + * The user needs to either free the request explicitly or call + * evhttp_send_reply_end(). + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_connection *evhttp_request_get_connection(struct evhttp_request *req); + +/** + * Returns the underlying event_base for this connection + */ +EVENT2_EXPORT_SYMBOL +struct event_base *evhttp_connection_get_base(struct evhttp_connection *req); + +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_max_headers_size(struct evhttp_connection *evcon, + ev_ssize_t new_max_headers_size); + +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_max_body_size(struct evhttp_connection* evcon, + ev_ssize_t new_max_body_size); + +/** Frees an http connection */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_free(struct evhttp_connection *evcon); + +/** Disowns a given connection object + * + * Can be used to tell libevent to free the connection object after + * the last request has completed or failed. + */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_free_on_completion(struct evhttp_connection *evcon); + +/** sets the ip address from which http connections are made */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_local_address(struct evhttp_connection *evcon, + const char *address); + +/** sets the local port from which http connections are made */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_local_port(struct evhttp_connection *evcon, + ev_uint16_t port); + +/** Sets the timeout in seconds for events related to this connection */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_timeout(struct evhttp_connection *evcon, + int timeout_in_secs); + +/** Sets the timeout for events related to this connection. Takes a struct + * timeval. */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_timeout_tv(struct evhttp_connection *evcon, + const struct timeval *tv); + +/** Sets the delay before retrying requests on this connection. This is only + * used if evhttp_connection_set_retries is used to make the number of retries + * at least one. Each retry after the first is twice as long as the one before + * it. */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_initial_retry_tv(struct evhttp_connection *evcon, + const struct timeval *tv); + +/** Sets the retry limit for this connection - -1 repeats indefinitely */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_retries(struct evhttp_connection *evcon, + int retry_max); + +/** Set a callback for connection close. */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_set_closecb(struct evhttp_connection *evcon, + void (*)(struct evhttp_connection *, void *), void *); + +/** Get the remote address and port associated with this connection. */ +EVENT2_EXPORT_SYMBOL +void evhttp_connection_get_peer(struct evhttp_connection *evcon, + char **address, ev_uint16_t *port); + +/** Get the remote address associated with this connection. + * extracted from getpeername(). + * + * @return NULL if getpeername() return non success, + * or connection is not connected, + * otherwise it return pointer to struct sockaddr_storage */ +EVENT2_EXPORT_SYMBOL +const struct sockaddr* +evhttp_connection_get_addr(struct evhttp_connection *evcon); + +/** + Make an HTTP request over the specified connection. + + The connection gets ownership of the request. On failure, the + request object is no longer valid as it has been freed. + + @param evcon the evhttp_connection object over which to send the request + @param req the previously created and configured request object + @param type the request type EVHTTP_REQ_GET, EVHTTP_REQ_POST, etc. + @param uri the URI associated with the request + @return 0 on success, -1 on failure + @see evhttp_cancel_request() +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_make_request(struct evhttp_connection *evcon, + struct evhttp_request *req, + enum evhttp_cmd_type type, const char *uri); + +/** + Cancels a pending HTTP request. + + Cancels an ongoing HTTP request. The callback associated with this request + is not executed and the request object is freed. If the request is + currently being processed, e.g. it is ongoing, the corresponding + evhttp_connection object is going to get reset. + + A request cannot be canceled if its callback has executed already. A request + may be canceled reentrantly from its chunked callback. + + @param req the evhttp_request to cancel; req becomes invalid after this call. +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_cancel_request(struct evhttp_request *req); + +/** + * A structure to hold a parsed URI or Relative-Ref conforming to RFC3986. + */ +struct evhttp_uri; + +/** Returns the request URI */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_request_get_uri(const struct evhttp_request *req); +/** Returns the request URI (parsed) */ +EVENT2_EXPORT_SYMBOL +const struct evhttp_uri *evhttp_request_get_evhttp_uri(const struct evhttp_request *req); +/** Returns the request command */ +EVENT2_EXPORT_SYMBOL +enum evhttp_cmd_type evhttp_request_get_command(const struct evhttp_request *req); + +EVENT2_EXPORT_SYMBOL +int evhttp_request_get_response_code(const struct evhttp_request *req); +EVENT2_EXPORT_SYMBOL +const char * evhttp_request_get_response_code_line(const struct evhttp_request *req); + +/** Returns the input headers */ +EVENT2_EXPORT_SYMBOL +struct evkeyvalq *evhttp_request_get_input_headers(struct evhttp_request *req); +/** Returns the output headers */ +EVENT2_EXPORT_SYMBOL +struct evkeyvalq *evhttp_request_get_output_headers(struct evhttp_request *req); +/** Returns the input buffer */ +EVENT2_EXPORT_SYMBOL +struct evbuffer *evhttp_request_get_input_buffer(struct evhttp_request *req); +/** Returns the output buffer */ +EVENT2_EXPORT_SYMBOL +struct evbuffer *evhttp_request_get_output_buffer(struct evhttp_request *req); +/** Returns the host associated with the request. If a client sends an absolute + URI, the host part of that is preferred. Otherwise, the input headers are + searched for a Host: header. NULL is returned if no absolute URI or Host: + header is provided. */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_request_get_host(struct evhttp_request *req); + +/* Interfaces for dealing with HTTP headers */ + +/** + Finds the value belonging to a header. + + @param headers the evkeyvalq object in which to find the header + @param key the name of the header to find + @returns a pointer to the value for the header or NULL if the header + could not be found. + @see evhttp_add_header(), evhttp_remove_header() +*/ +EVENT2_EXPORT_SYMBOL +const char *evhttp_find_header(const struct evkeyvalq *headers, + const char *key); + +/** + Removes a header from a list of existing headers. + + @param headers the evkeyvalq object from which to remove a header + @param key the name of the header to remove + @returns 0 if the header was removed, -1 otherwise. + @see evhttp_find_header(), evhttp_add_header() +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_remove_header(struct evkeyvalq *headers, const char *key); + +/** + Adds a header to a list of existing headers. + + @param headers the evkeyvalq object to which to add a header + @param key the name of the header + @param value the value belonging to the header + @returns 0 on success, -1 otherwise. + @see evhttp_find_header(), evhttp_clear_headers() +*/ +EVENT2_EXPORT_SYMBOL +int evhttp_add_header(struct evkeyvalq *headers, const char *key, const char *value); + +/** + Removes all headers from the header list. + + @param headers the evkeyvalq object from which to remove all headers +*/ +EVENT2_EXPORT_SYMBOL +void evhttp_clear_headers(struct evkeyvalq *headers); + +/* Miscellaneous utility functions */ + + +/** + Helper function to encode a string for inclusion in a URI. All + characters are replaced by their hex-escaped (%22) equivalents, + except for characters explicitly unreserved by RFC3986 -- that is, + ASCII alphanumeric characters, hyphen, dot, underscore, and tilde. + + The returned string must be freed by the caller. + + @param str an unencoded string + @return a newly allocated URI-encoded string or NULL on failure + */ +EVENT2_EXPORT_SYMBOL +char *evhttp_encode_uri(const char *str); + +/** + As evhttp_encode_uri, but if 'size' is nonnegative, treat the string + as being 'size' bytes long. This allows you to encode strings that + may contain 0-valued bytes. + + The returned string must be freed by the caller. + + @param str an unencoded string + @param size the length of the string to encode, or -1 if the string + is NUL-terminated + @param space_to_plus if true, space characters in 'str' are encoded + as +, not %20. + @return a newly allocate URI-encoded string, or NULL on failure. + */ +EVENT2_EXPORT_SYMBOL +char *evhttp_uriencode(const char *str, ev_ssize_t size, int space_to_plus); + +/** + Helper function to sort of decode a URI-encoded string. Unlike + evhttp_get_decoded_uri, it decodes all plus characters that appear + _after_ the first question mark character, but no plusses that occur + before. This is not a good way to decode URIs in whole or in part. + + The returned string must be freed by the caller + + @deprecated This function is deprecated; you probably want to use + evhttp_get_decoded_uri instead. + + @param uri an encoded URI + @return a newly allocated unencoded URI or NULL on failure + */ +EVENT2_EXPORT_SYMBOL +char *evhttp_decode_uri(const char *uri); + +/** + Helper function to decode a URI-escaped string or HTTP parameter. + + If 'decode_plus' is 1, then we decode the string as an HTTP parameter + value, and convert all plus ('+') characters to spaces. If + 'decode_plus' is 0, we leave all plus characters unchanged. + + The returned string must be freed by the caller. + + @param uri a URI-encode encoded URI + @param decode_plus determines whether we convert '+' to space. + @param size_out if size_out is not NULL, *size_out is set to the size of the + returned string + @return a newly allocated unencoded URI or NULL on failure + */ +EVENT2_EXPORT_SYMBOL +char *evhttp_uridecode(const char *uri, int decode_plus, + size_t *size_out); + +/** + Helper function to parse out arguments in a query. + + Parsing a URI like + + http://foo.com/?q=test&s=some+thing + + will result in two entries in the key value queue. + + The first entry is: key="q", value="test" + The second entry is: key="s", value="some thing" + + @deprecated This function is deprecated as of Libevent 2.0.9. Use + evhttp_uri_parse and evhttp_parse_query_str instead. + + @param uri the request URI + @param headers the head of the evkeyval queue + @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int evhttp_parse_query(const char *uri, struct evkeyvalq *headers); + +/** + Helper function to parse out arguments from the query portion of an + HTTP URI. + + Parsing a query string like + + q=test&s=some+thing + + will result in two entries in the key value queue. + + The first entry is: key="q", value="test" + The second entry is: key="s", value="some thing" + + @param query_parse the query portion of the URI + @param headers the head of the evkeyval queue + @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int evhttp_parse_query_str(const char *uri, struct evkeyvalq *headers); + +/** + * Escape HTML character entities in a string. + * + * Replaces <, >, ", ' and & with <, >, ", + * ' and & correspondingly. + * + * The returned string needs to be freed by the caller. + * + * @param html an unescaped HTML string + * @return an escaped HTML string or NULL on error + */ +EVENT2_EXPORT_SYMBOL +char *evhttp_htmlescape(const char *html); + +/** + * Return a new empty evhttp_uri with no fields set. + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_uri *evhttp_uri_new(void); + +/** + * Changes the flags set on a given URI. See EVHTTP_URI_* for + * a list of flags. + **/ +EVENT2_EXPORT_SYMBOL +void evhttp_uri_set_flags(struct evhttp_uri *uri, unsigned flags); + +/** Return the scheme of an evhttp_uri, or NULL if there is no scheme has + * been set and the evhttp_uri contains a Relative-Ref. */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_uri_get_scheme(const struct evhttp_uri *uri); +/** + * Return the userinfo part of an evhttp_uri, or NULL if it has no userinfo + * set. + */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_uri_get_userinfo(const struct evhttp_uri *uri); +/** + * Return the host part of an evhttp_uri, or NULL if it has no host set. + * The host may either be a regular hostname (conforming to the RFC 3986 + * "regname" production), or an IPv4 address, or the empty string, or a + * bracketed IPv6 address, or a bracketed 'IP-Future' address. + * + * Note that having a NULL host means that the URI has no authority + * section, but having an empty-string host means that the URI has an + * authority section with no host part. For example, + * "mailto:user@example.com" has a host of NULL, but "file:///etc/motd" + * has a host of "". + */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_uri_get_host(const struct evhttp_uri *uri); +/** Return the port part of an evhttp_uri, or -1 if there is no port set. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_get_port(const struct evhttp_uri *uri); +/** Return the path part of an evhttp_uri, or NULL if it has no path set */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_uri_get_path(const struct evhttp_uri *uri); +/** Return the query part of an evhttp_uri (excluding the leading "?"), or + * NULL if it has no query set */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_uri_get_query(const struct evhttp_uri *uri); +/** Return the fragment part of an evhttp_uri (excluding the leading "#"), + * or NULL if it has no fragment set */ +EVENT2_EXPORT_SYMBOL +const char *evhttp_uri_get_fragment(const struct evhttp_uri *uri); + +/** Set the scheme of an evhttp_uri, or clear the scheme if scheme==NULL. + * Returns 0 on success, -1 if scheme is not well-formed. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_set_scheme(struct evhttp_uri *uri, const char *scheme); +/** Set the userinfo of an evhttp_uri, or clear the userinfo if userinfo==NULL. + * Returns 0 on success, -1 if userinfo is not well-formed. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_set_userinfo(struct evhttp_uri *uri, const char *userinfo); +/** Set the host of an evhttp_uri, or clear the host if host==NULL. + * Returns 0 on success, -1 if host is not well-formed. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_set_host(struct evhttp_uri *uri, const char *host); +/** Set the port of an evhttp_uri, or clear the port if port==-1. + * Returns 0 on success, -1 if port is not well-formed. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_set_port(struct evhttp_uri *uri, int port); +/** Set the path of an evhttp_uri, or clear the path if path==NULL. + * Returns 0 on success, -1 if path is not well-formed. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_set_path(struct evhttp_uri *uri, const char *path); +/** Set the query of an evhttp_uri, or clear the query if query==NULL. + * The query should not include a leading "?". + * Returns 0 on success, -1 if query is not well-formed. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_set_query(struct evhttp_uri *uri, const char *query); +/** Set the fragment of an evhttp_uri, or clear the fragment if fragment==NULL. + * The fragment should not include a leading "#". + * Returns 0 on success, -1 if fragment is not well-formed. */ +EVENT2_EXPORT_SYMBOL +int evhttp_uri_set_fragment(struct evhttp_uri *uri, const char *fragment); + +/** + * Helper function to parse a URI-Reference as specified by RFC3986. + * + * This function matches the URI-Reference production from RFC3986, + * which includes both URIs like + * + * scheme://[[userinfo]@]foo.com[:port]]/[path][?query][#fragment] + * + * and relative-refs like + * + * [path][?query][#fragment] + * + * Any optional elements portions not present in the original URI are + * left set to NULL in the resulting evhttp_uri. If no port is + * specified, the port is set to -1. + * + * Note that no decoding is performed on percent-escaped characters in + * the string; if you want to parse them, use evhttp_uridecode or + * evhttp_parse_query_str as appropriate. + * + * Note also that most URI schemes will have additional constraints that + * this function does not know about, and cannot check. For example, + * mailto://www.example.com/cgi-bin/fortune.pl is not a reasonable + * mailto url, http://www.example.com:99999/ is not a reasonable HTTP + * URL, and ftp:username@example.com is not a reasonable FTP URL. + * Nevertheless, all of these URLs conform to RFC3986, and this function + * accepts all of them as valid. + * + * @param source_uri the request URI + * @param flags Zero or more EVHTTP_URI_* flags to affect the behavior + * of the parser. + * @return uri container to hold parsed data, or NULL if there is error + * @see evhttp_uri_free() + */ +EVENT2_EXPORT_SYMBOL +struct evhttp_uri *evhttp_uri_parse_with_flags(const char *source_uri, + unsigned flags); + +/** Tolerate URIs that do not conform to RFC3986. + * + * Unfortunately, some HTTP clients generate URIs that, according to RFC3986, + * are not conformant URIs. If you need to support these URIs, you can + * do so by passing this flag to evhttp_uri_parse_with_flags. + * + * Currently, these changes are: + *
        + *
      • Nonconformant URIs are allowed to contain otherwise unreasonable + * characters in their path, query, and fragment components. + *
      + */ +#define EVHTTP_URI_NONCONFORMANT 0x01 + +/** Alias for evhttp_uri_parse_with_flags(source_uri, 0) */ +EVENT2_EXPORT_SYMBOL +struct evhttp_uri *evhttp_uri_parse(const char *source_uri); + +/** + * Free all memory allocated for a parsed uri. Only use this for URIs + * generated by evhttp_uri_parse. + * + * @param uri container with parsed data + * @see evhttp_uri_parse() + */ +EVENT2_EXPORT_SYMBOL +void evhttp_uri_free(struct evhttp_uri *uri); + +/** + * Join together the uri parts from parsed data to form a URI-Reference. + * + * Note that no escaping of reserved characters is done on the members + * of the evhttp_uri, so the generated string might not be a valid URI + * unless the members of evhttp_uri are themselves valid. + * + * @param uri container with parsed data + * @param buf destination buffer + * @param limit destination buffer size + * @return an joined uri as string or NULL on error + * @see evhttp_uri_parse() + */ +EVENT2_EXPORT_SYMBOL +char *evhttp_uri_join(struct evhttp_uri *uri, char *buf, size_t limit); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_HTTP_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/http_compat.h b/contrib/ntp/sntp/libevent/include/event2/http_compat.h new file mode 100644 index 000000000..0d9af17f3 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/http_compat.h @@ -0,0 +1,90 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_HTTP_COMPAT_H_INCLUDED_ +#define EVENT2_HTTP_COMPAT_H_INCLUDED_ + +/** @file event2/http_compat.h + + Potentially non-threadsafe versions of the functions in http.h: provided + only for backwards compatibility. + + */ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +/** + * Start an HTTP server on the specified address and port + * + * @deprecated It does not allow an event base to be specified + * + * @param address the address to which the HTTP server should be bound + * @param port the port number on which the HTTP server should listen + * @return an struct evhttp object + */ +struct evhttp *evhttp_start(const char *address, unsigned short port); + +/** + * A connection object that can be used to for making HTTP requests. The + * connection object tries to establish the connection when it is given an + * http request object. + * + * @deprecated It does not allow an event base to be specified + */ +struct evhttp_connection *evhttp_connection_new( + const char *address, unsigned short port); + +/** + * Associates an event base with the connection - can only be called + * on a freshly created connection object that has not been used yet. + * + * @deprecated XXXX Why? + */ +void evhttp_connection_set_base(struct evhttp_connection *evcon, + struct event_base *base); + + +/** Returns the request URI */ +#define evhttp_request_uri evhttp_request_get_uri + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/http_struct.h b/contrib/ntp/sntp/libevent/include/event2/http_struct.h new file mode 100644 index 000000000..4bf5b1ff6 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/http_struct.h @@ -0,0 +1,152 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_HTTP_STRUCT_H_INCLUDED_ +#define EVENT2_HTTP_STRUCT_H_INCLUDED_ + +/** @file event2/http_struct.h + + Data structures for http. Using these structures may hurt forward + compatibility with later versions of Libevent: be careful! + + */ + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +/** + * the request structure that a server receives. + * WARNING: expect this structure to change. I will try to provide + * reasonable accessors. + */ +struct evhttp_request { +#if defined(TAILQ_ENTRY) + TAILQ_ENTRY(evhttp_request) next; +#else +struct { + struct evhttp_request *tqe_next; + struct evhttp_request **tqe_prev; +} next; +#endif + + /* the connection object that this request belongs to */ + struct evhttp_connection *evcon; + int flags; +/** The request obj owns the evhttp connection and needs to free it */ +#define EVHTTP_REQ_OWN_CONNECTION 0x0001 +/** Request was made via a proxy */ +#define EVHTTP_PROXY_REQUEST 0x0002 +/** The request object is owned by the user; the user must free it */ +#define EVHTTP_USER_OWNED 0x0004 +/** The request will be used again upstack; freeing must be deferred */ +#define EVHTTP_REQ_DEFER_FREE 0x0008 +/** The request should be freed upstack */ +#define EVHTTP_REQ_NEEDS_FREE 0x0010 + + struct evkeyvalq *input_headers; + struct evkeyvalq *output_headers; + + /* address of the remote host and the port connection came from */ + char *remote_host; + ev_uint16_t remote_port; + + /* cache of the hostname for evhttp_request_get_host */ + char *host_cache; + + enum evhttp_request_kind kind; + enum evhttp_cmd_type type; + + size_t headers_size; + size_t body_size; + + char *uri; /* uri after HTTP request was parsed */ + struct evhttp_uri *uri_elems; /* uri elements */ + + char major; /* HTTP Major number */ + char minor; /* HTTP Minor number */ + + int response_code; /* HTTP Response code */ + char *response_code_line; /* Readable response */ + + struct evbuffer *input_buffer; /* read data */ + ev_int64_t ntoread; + unsigned chunked:1, /* a chunked request */ + userdone:1; /* the user has sent all data */ + + struct evbuffer *output_buffer; /* outgoing post or data */ + + /* Callback */ + void (*cb)(struct evhttp_request *, void *); + void *cb_arg; + + /* + * Chunked data callback - call for each completed chunk if + * specified. If not specified, all the data is delivered via + * the regular callback. + */ + void (*chunk_cb)(struct evhttp_request *, void *); + + /* + * Callback added for forked-daapd so they can collect ICY + * (shoutcast) metadata from the http header. If return + * int is negative the connection will be closed. + */ + int (*header_cb)(struct evhttp_request *, void *); + + /* + * Error callback - called when error is occured. + * @see evhttp_request_error for error types. + * + * @see evhttp_request_set_error_cb() + */ + void (*error_cb)(enum evhttp_request_error, void *); + + /* + * Send complete callback - called when the request is actually + * sent and completed. + */ + void (*on_complete_cb)(struct evhttp_request *, void *); + void *on_complete_cb_arg; +}; + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_HTTP_STRUCT_H_INCLUDED_ */ + diff --git a/contrib/ntp/sntp/libevent/include/event2/keyvalq_struct.h b/contrib/ntp/sntp/libevent/include/event2/keyvalq_struct.h new file mode 100644 index 000000000..bffa54b3a --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/keyvalq_struct.h @@ -0,0 +1,80 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_KEYVALQ_STRUCT_H_INCLUDED_ +#define EVENT2_KEYVALQ_STRUCT_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +/* Fix so that people don't have to run with */ +/* XXXX This code is duplicated with event_struct.h */ +#ifndef TAILQ_ENTRY +#define EVENT_DEFINED_TQENTRY_ +#define TAILQ_ENTRY(type) \ +struct { \ + struct type *tqe_next; /* next element */ \ + struct type **tqe_prev; /* address of previous next element */ \ +} +#endif /* !TAILQ_ENTRY */ + +#ifndef TAILQ_HEAD +#define EVENT_DEFINED_TQHEAD_ +#define TAILQ_HEAD(name, type) \ +struct name { \ + struct type *tqh_first; \ + struct type **tqh_last; \ +} +#endif + +/* + * Key-Value pairs. Can be used for HTTP headers but also for + * query argument parsing. + */ +struct evkeyval { + TAILQ_ENTRY(evkeyval) next; + + char *key; + char *value; +}; + +TAILQ_HEAD (evkeyvalq, evkeyval); + +/* XXXX This code is duplicated with event_struct.h */ +#ifdef EVENT_DEFINED_TQENTRY_ +#undef TAILQ_ENTRY +#endif + +#ifdef EVENT_DEFINED_TQHEAD_ +#undef TAILQ_HEAD +#endif + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/contrib/ntp/sntp/libevent/include/event2/listener.h b/contrib/ntp/sntp/libevent/include/event2/listener.h new file mode 100644 index 000000000..84b4da055 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/listener.h @@ -0,0 +1,180 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_LISTENER_H_INCLUDED_ +#define EVENT2_LISTENER_H_INCLUDED_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +struct sockaddr; +struct evconnlistener; + +/** + A callback that we invoke when a listener has a new connection. + + @param listener The evconnlistener + @param fd The new file descriptor + @param addr The source address of the connection + @param socklen The length of addr + @param user_arg the pointer passed to evconnlistener_new() + */ +typedef void (*evconnlistener_cb)(struct evconnlistener *, evutil_socket_t, struct sockaddr *, int socklen, void *); + +/** + A callback that we invoke when a listener encounters a non-retriable error. + + @param listener The evconnlistener + @param user_arg the pointer passed to evconnlistener_new() + */ +typedef void (*evconnlistener_errorcb)(struct evconnlistener *, void *); + +/** Flag: Indicates that we should not make incoming sockets nonblocking + * before passing them to the callback. */ +#define LEV_OPT_LEAVE_SOCKETS_BLOCKING (1u<<0) +/** Flag: Indicates that freeing the listener should close the underlying + * socket. */ +#define LEV_OPT_CLOSE_ON_FREE (1u<<1) +/** Flag: Indicates that we should set the close-on-exec flag, if possible */ +#define LEV_OPT_CLOSE_ON_EXEC (1u<<2) +/** Flag: Indicates that we should disable the timeout (if any) between when + * this socket is closed and when we can listen again on the same port. */ +#define LEV_OPT_REUSEABLE (1u<<3) +/** Flag: Indicates that the listener should be locked so it's safe to use + * from multiple threadcs at once. */ +#define LEV_OPT_THREADSAFE (1u<<4) +/** Flag: Indicates that the listener should be created in disabled + * state. Use evconnlistener_enable() to enable it later. */ +#define LEV_OPT_DISABLED (1u<<5) +/** Flag: Indicates that the listener should defer accept() until data is + * available, if possible. Ignored on platforms that do not support this. + * + * This option can help performance for protocols where the client transmits + * immediately after connecting. Do not use this option if your protocol + * _doesn't_ start out with the client transmitting data, since in that case + * this option will sometimes cause the kernel to never tell you about the + * connection. + * + * This option is only supported by evconnlistener_new_bind(): it can't + * work with evconnlistener_new_fd(), since the listener needs to be told + * to use the option before it is actually bound. + */ +#define LEV_OPT_DEFERRED_ACCEPT (1u<<6) +/** Flag: Indicates that we ask to allow multiple servers (processes or + * threads) to bind to the same port if they each set the option. + * + * SO_REUSEPORT is what most people would expect SO_REUSEADDR to be, however + * SO_REUSEPORT does not imply SO_REUSEADDR. + * + * This is only available on Linux and kernel 3.9+ + */ +#define LEV_OPT_REUSEABLE_PORT (1u<<7) + +/** + Allocate a new evconnlistener object to listen for incoming TCP connections + on a given file descriptor. + + @param base The event base to associate the listener with. + @param cb A callback to be invoked when a new connection arrives. If the + callback is NULL, the listener will be treated as disabled until the + callback is set. + @param ptr A user-supplied pointer to give to the callback. + @param flags Any number of LEV_OPT_* flags + @param backlog Passed to the listen() call to determine the length of the + acceptable connection backlog. Set to -1 for a reasonable default. + Set to 0 if the socket is already listening. + @param fd The file descriptor to listen on. It must be a nonblocking + file descriptor, and it should already be bound to an appropriate + port and address. +*/ +EVENT2_EXPORT_SYMBOL +struct evconnlistener *evconnlistener_new(struct event_base *base, + evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, + evutil_socket_t fd); +/** + Allocate a new evconnlistener object to listen for incoming TCP connections + on a given address. + + @param base The event base to associate the listener with. + @param cb A callback to be invoked when a new connection arrives. If the + callback is NULL, the listener will be treated as disabled until the + callback is set. + @param ptr A user-supplied pointer to give to the callback. + @param flags Any number of LEV_OPT_* flags + @param backlog Passed to the listen() call to determine the length of the + acceptable connection backlog. Set to -1 for a reasonable default. + @param addr The address to listen for connections on. + @param socklen The length of the address. + */ +EVENT2_EXPORT_SYMBOL +struct evconnlistener *evconnlistener_new_bind(struct event_base *base, + evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, + const struct sockaddr *sa, int socklen); +/** + Disable and deallocate an evconnlistener. + */ +EVENT2_EXPORT_SYMBOL +void evconnlistener_free(struct evconnlistener *lev); +/** + Re-enable an evconnlistener that has been disabled. + */ +EVENT2_EXPORT_SYMBOL +int evconnlistener_enable(struct evconnlistener *lev); +/** + Stop listening for connections on an evconnlistener. + */ +EVENT2_EXPORT_SYMBOL +int evconnlistener_disable(struct evconnlistener *lev); + +/** Return an evconnlistener's associated event_base. */ +EVENT2_EXPORT_SYMBOL +struct event_base *evconnlistener_get_base(struct evconnlistener *lev); + +/** Return the socket that an evconnlistner is listening on. */ +EVENT2_EXPORT_SYMBOL +evutil_socket_t evconnlistener_get_fd(struct evconnlistener *lev); + +/** Change the callback on the listener to cb and its user_data to arg. + */ +EVENT2_EXPORT_SYMBOL +void evconnlistener_set_cb(struct evconnlistener *lev, + evconnlistener_cb cb, void *arg); + +/** Set an evconnlistener's error callback. */ +EVENT2_EXPORT_SYMBOL +void evconnlistener_set_error_cb(struct evconnlistener *lev, + evconnlistener_errorcb errorcb); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/contrib/ntp/sntp/libevent/include/event2/rpc.h b/contrib/ntp/sntp/libevent/include/event2/rpc.h new file mode 100644 index 000000000..dd43df266 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/rpc.h @@ -0,0 +1,596 @@ +/* + * Copyright (c) 2006-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_RPC_H_INCLUDED_ +#define EVENT2_RPC_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +/** @file rpc.h + * + * This header files provides basic support for an RPC server and client. + * + * To support RPCs in a server, every supported RPC command needs to be + * defined and registered. + * + * EVRPC_HEADER(SendCommand, Request, Reply); + * + * SendCommand is the name of the RPC command. + * Request is the name of a structure generated by event_rpcgen.py. + * It contains all parameters relating to the SendCommand RPC. The + * server needs to fill in the Reply structure. + * Reply is the name of a structure generated by event_rpcgen.py. It + * contains the answer to the RPC. + * + * To register an RPC with an HTTP server, you need to first create an RPC + * base with: + * + * struct evrpc_base *base = evrpc_init(http); + * + * A specific RPC can then be registered with + * + * EVRPC_REGISTER(base, SendCommand, Request, Reply, FunctionCB, arg); + * + * when the server receives an appropriately formatted RPC, the user callback + * is invoked. The callback needs to fill in the reply structure. + * + * void FunctionCB(EVRPC_STRUCT(SendCommand)* rpc, void *arg); + * + * To send the reply, call EVRPC_REQUEST_DONE(rpc); + * + * See the regression test for an example. + */ + +/** + Determines if the member has been set in the message + + @param msg the message to inspect + @param member the member variable to test for presences + @return 1 if it's present or 0 otherwise. +*/ +#define EVTAG_HAS(msg, member) \ + ((msg)->member##_set == 1) + +#ifndef EVENT2_RPC_COMPAT_H_INCLUDED_ + +/** + Assigns a value to the member in the message. + + @param msg the message to which to assign a value + @param member the name of the member variable + @param value the value to assign +*/ +#define EVTAG_ASSIGN(msg, member, value) \ + (*(msg)->base->member##_assign)((msg), (value)) +/** + Assigns a value to the member in the message. + + @param msg the message to which to assign a value + @param member the name of the member variable + @param value the value to assign + @param len the length of the value +*/ +#define EVTAG_ASSIGN_WITH_LEN(msg, member, value, len) \ + (*(msg)->base->member##_assign)((msg), (value), (len)) +/** + Returns the value for a member. + + @param msg the message from which to get the value + @param member the name of the member variable + @param pvalue a pointer to the variable to hold the value + @return 0 on success, -1 otherwise. +*/ +#define EVTAG_GET(msg, member, pvalue) \ + (*(msg)->base->member##_get)((msg), (pvalue)) +/** + Returns the value for a member. + + @param msg the message from which to get the value + @param member the name of the member variable + @param pvalue a pointer to the variable to hold the value + @param plen a pointer to the length of the value + @return 0 on success, -1 otherwise. +*/ +#define EVTAG_GET_WITH_LEN(msg, member, pvalue, plen) \ + (*(msg)->base->member##_get)((msg), (pvalue), (plen)) + +#endif /* EVENT2_RPC_COMPAT_H_INCLUDED_ */ + +/** + Adds a value to an array. +*/ +#define EVTAG_ARRAY_ADD_VALUE(msg, member, value) \ + (*(msg)->base->member##_add)((msg), (value)) +/** + Allocates a new entry in the array and returns it. +*/ +#define EVTAG_ARRAY_ADD(msg, member) \ + (*(msg)->base->member##_add)(msg) +/** + Gets a variable at the specified offset from the array. +*/ +#define EVTAG_ARRAY_GET(msg, member, offset, pvalue) \ + (*(msg)->base->member##_get)((msg), (offset), (pvalue)) +/** + Returns the number of entries in the array. +*/ +#define EVTAG_ARRAY_LEN(msg, member) ((msg)->member##_length) + + +struct evbuffer; +struct event_base; +struct evrpc_req_generic; +struct evrpc_request_wrapper; +struct evrpc; + +/** The type of a specific RPC Message + * + * @param rpcname the name of the RPC message + */ +#define EVRPC_STRUCT(rpcname) struct evrpc_req__##rpcname + +struct evhttp_request; +struct evrpc_status; +struct evrpc_hook_meta; + +/** Creates the definitions and prototypes for an RPC + * + * You need to use EVRPC_HEADER to create structures and function prototypes + * needed by the server and client implementation. The structures have to be + * defined in an .rpc file and converted to source code via event_rpcgen.py + * + * @param rpcname the name of the RPC + * @param reqstruct the name of the RPC request structure + * @param replystruct the name of the RPC reply structure + * @see EVRPC_GENERATE() + */ +#define EVRPC_HEADER(rpcname, reqstruct, rplystruct) \ +EVRPC_STRUCT(rpcname) { \ + struct evrpc_hook_meta *hook_meta; \ + struct reqstruct* request; \ + struct rplystruct* reply; \ + struct evrpc* rpc; \ + struct evhttp_request* http_req; \ + struct evbuffer* rpc_data; \ +}; \ +int evrpc_send_request_##rpcname(struct evrpc_pool *, \ + struct reqstruct *, struct rplystruct *, \ + void (*)(struct evrpc_status *, \ + struct reqstruct *, struct rplystruct *, void *cbarg), \ + void *); + +struct evrpc_pool; + +/** use EVRPC_GENERATE instead */ +struct evrpc_request_wrapper *evrpc_make_request_ctx( + struct evrpc_pool *pool, void *request, void *reply, + const char *rpcname, + void (*req_marshal)(struct evbuffer*, void *), + void (*rpl_clear)(void *), + int (*rpl_unmarshal)(void *, struct evbuffer *), + void (*cb)(struct evrpc_status *, void *, void *, void *), + void *cbarg); + +/** Creates a context structure that contains rpc specific information. + * + * EVRPC_MAKE_CTX is used to populate a RPC specific context that + * contains information about marshaling the RPC data types. + * + * @param rpcname the name of the RPC + * @param reqstruct the name of the RPC request structure + * @param replystruct the name of the RPC reply structure + * @param pool the evrpc_pool over which to make the request + * @param request a pointer to the RPC request structure object + * @param reply a pointer to the RPC reply structure object + * @param cb the callback function to call when the RPC has completed + * @param cbarg the argument to supply to the callback + */ +#define EVRPC_MAKE_CTX(rpcname, reqstruct, rplystruct, \ + pool, request, reply, cb, cbarg) \ + evrpc_make_request_ctx(pool, request, reply, \ + #rpcname, \ + (void (*)(struct evbuffer *, void *))reqstruct##_marshal, \ + (void (*)(void *))rplystruct##_clear, \ + (int (*)(void *, struct evbuffer *))rplystruct##_unmarshal, \ + (void (*)(struct evrpc_status *, void *, void *, void *))cb, \ + cbarg) + +/** Generates the code for receiving and sending an RPC message + * + * EVRPC_GENERATE is used to create the code corresponding to sending + * and receiving a particular RPC message + * + * @param rpcname the name of the RPC + * @param reqstruct the name of the RPC request structure + * @param replystruct the name of the RPC reply structure + * @see EVRPC_HEADER() + */ +#define EVRPC_GENERATE(rpcname, reqstruct, rplystruct) \ + int evrpc_send_request_##rpcname(struct evrpc_pool *pool, \ + struct reqstruct *request, struct rplystruct *reply, \ + void (*cb)(struct evrpc_status *, \ + struct reqstruct *, struct rplystruct *, void *cbarg), \ + void *cbarg) { \ + return evrpc_send_request_generic(pool, request, reply, \ + (void (*)(struct evrpc_status *, void *, void *, void *))cb, \ + cbarg, \ + #rpcname, \ + (void (*)(struct evbuffer *, void *))reqstruct##_marshal, \ + (void (*)(void *))rplystruct##_clear, \ + (int (*)(void *, struct evbuffer *))rplystruct##_unmarshal); \ +} + +/** Provides access to the HTTP request object underlying an RPC + * + * Access to the underlying http object; can be used to look at headers or + * for getting the remote ip address + * + * @param rpc_req the rpc request structure provided to the server callback + * @return an struct evhttp_request object that can be inspected for + * HTTP headers or sender information. + */ +#define EVRPC_REQUEST_HTTP(rpc_req) (rpc_req)->http_req + +/** completes the server response to an rpc request */ +void evrpc_request_done(struct evrpc_req_generic *req); + +/** accessors for request and reply */ +void *evrpc_get_request(struct evrpc_req_generic *req); +void *evrpc_get_reply(struct evrpc_req_generic *req); + +/** Creates the reply to an RPC request + * + * EVRPC_REQUEST_DONE is used to answer a request; the reply is expected + * to have been filled in. The request and reply pointers become invalid + * after this call has finished. + * + * @param rpc_req the rpc request structure provided to the server callback + */ +#define EVRPC_REQUEST_DONE(rpc_req) do { \ + struct evrpc_req_generic *req_ = (struct evrpc_req_generic *)(rpc_req); \ + evrpc_request_done(req_); \ +} while (0) + + +struct evrpc_base; +struct evhttp; + +/* functions to start up the rpc system */ + +/** Creates a new rpc base from which RPC requests can be received + * + * @param server a pointer to an existing HTTP server + * @return a newly allocated evrpc_base struct + * @see evrpc_free() + */ +struct evrpc_base *evrpc_init(struct evhttp *server); + +/** + * Frees the evrpc base + * + * For now, you are responsible for making sure that no rpcs are ongoing. + * + * @param base the evrpc_base object to be freed + * @see evrpc_init + */ +void evrpc_free(struct evrpc_base *base); + +/** register RPCs with the HTTP Server + * + * registers a new RPC with the HTTP server, each RPC needs to have + * a unique name under which it can be identified. + * + * @param base the evrpc_base structure in which the RPC should be + * registered. + * @param name the name of the RPC + * @param request the name of the RPC request structure + * @param reply the name of the RPC reply structure + * @param callback the callback that should be invoked when the RPC + * is received. The callback has the following prototype + * void (*callback)(EVRPC_STRUCT(Message)* rpc, void *arg) + * @param cbarg an additional parameter that can be passed to the callback. + * The parameter can be used to carry around state. + */ +#define EVRPC_REGISTER(base, name, request, reply, callback, cbarg) \ + evrpc_register_generic(base, #name, \ + (void (*)(struct evrpc_req_generic *, void *))callback, cbarg, \ + (void *(*)(void *))request##_new, NULL, \ + (void (*)(void *))request##_free, \ + (int (*)(void *, struct evbuffer *))request##_unmarshal, \ + (void *(*)(void *))reply##_new, NULL, \ + (void (*)(void *))reply##_free, \ + (int (*)(void *))reply##_complete, \ + (void (*)(struct evbuffer *, void *))reply##_marshal) + +/** + Low level function for registering an RPC with a server. + + Use EVRPC_REGISTER() instead. + + @see EVRPC_REGISTER() +*/ +int evrpc_register_rpc(struct evrpc_base *, struct evrpc *, + void (*)(struct evrpc_req_generic*, void *), void *); + +/** + * Unregisters an already registered RPC + * + * @param base the evrpc_base object from which to unregister an RPC + * @param name the name of the rpc to unregister + * @return -1 on error or 0 when successful. + * @see EVRPC_REGISTER() + */ +#define EVRPC_UNREGISTER(base, name) evrpc_unregister_rpc((base), #name) + +int evrpc_unregister_rpc(struct evrpc_base *base, const char *name); + +/* + * Client-side RPC support + */ + +struct evhttp_connection; +struct evrpc_status; + +/** launches an RPC and sends it to the server + * + * EVRPC_MAKE_REQUEST() is used by the client to send an RPC to the server. + * + * @param name the name of the RPC + * @param pool the evrpc_pool that contains the connection objects over which + * the request should be sent. + * @param request a pointer to the RPC request structure - it contains the + * data to be sent to the server. + * @param reply a pointer to the RPC reply structure. It is going to be filled + * if the request was answered successfully + * @param cb the callback to invoke when the RPC request has been answered + * @param cbarg an additional argument to be passed to the client + * @return 0 on success, -1 on failure + */ +#define EVRPC_MAKE_REQUEST(name, pool, request, reply, cb, cbarg) \ + evrpc_send_request_##name((pool), (request), (reply), (cb), (cbarg)) + +/** + Makes an RPC request based on the provided context. + + This is a low-level function and should not be used directly + unless a custom context object is provided. Use EVRPC_MAKE_REQUEST() + instead. + + @param ctx a context from EVRPC_MAKE_CTX() + @returns 0 on success, -1 otherwise. + @see EVRPC_MAKE_REQUEST(), EVRPC_MAKE_CTX() +*/ +int evrpc_make_request(struct evrpc_request_wrapper *ctx); + +/** creates an rpc connection pool + * + * a pool has a number of connections associated with it. + * rpc requests are always made via a pool. + * + * @param base a pointer to an struct event_based object; can be left NULL + * in singled-threaded applications + * @return a newly allocated struct evrpc_pool object + * @see evrpc_pool_free() + */ +struct evrpc_pool *evrpc_pool_new(struct event_base *base); +/** frees an rpc connection pool + * + * @param pool a pointer to an evrpc_pool allocated via evrpc_pool_new() + * @see evrpc_pool_new() + */ +void evrpc_pool_free(struct evrpc_pool *pool); + +/** + * Adds a connection over which rpc can be dispatched to the pool. + * + * The connection object must have been newly created. + * + * @param pool the pool to which to add the connection + * @param evcon the connection to add to the pool. + */ +void evrpc_pool_add_connection(struct evrpc_pool *pool, + struct evhttp_connection *evcon); + +/** + * Removes a connection from the pool. + * + * The connection object must have been newly created. + * + * @param pool the pool from which to remove the connection + * @param evcon the connection to remove from the pool. + */ +void evrpc_pool_remove_connection(struct evrpc_pool *pool, + struct evhttp_connection *evcon); + +/** + * Sets the timeout in secs after which a request has to complete. The + * RPC is completely aborted if it does not complete by then. Setting + * the timeout to 0 means that it never timeouts and can be used to + * implement callback type RPCs. + * + * Any connection already in the pool will be updated with the new + * timeout. Connections added to the pool after set_timeout has be + * called receive the pool timeout only if no timeout has been set + * for the connection itself. + * + * @param pool a pointer to a struct evrpc_pool object + * @param timeout_in_secs the number of seconds after which a request should + * timeout and a failure be returned to the callback. + */ +void evrpc_pool_set_timeout(struct evrpc_pool *pool, int timeout_in_secs); + +/** + * Hooks for changing the input and output of RPCs; this can be used to + * implement compression, authentication, encryption, ... + */ + +enum EVRPC_HOOK_TYPE { + EVRPC_INPUT, /**< apply the function to an input hook */ + EVRPC_OUTPUT /**< apply the function to an output hook */ +}; + +#ifndef _WIN32 +/** Deprecated alias for EVRPC_INPUT. Not available on windows, where it + * conflicts with platform headers. */ +#define INPUT EVRPC_INPUT +/** Deprecated alias for EVRPC_OUTPUT. Not available on windows, where it + * conflicts with platform headers. */ +#define OUTPUT EVRPC_OUTPUT +#endif + +/** + * Return value from hook processing functions + */ + +enum EVRPC_HOOK_RESULT { + EVRPC_TERMINATE = -1, /**< indicates the rpc should be terminated */ + EVRPC_CONTINUE = 0, /**< continue processing the rpc */ + EVRPC_PAUSE = 1 /**< pause processing request until resumed */ +}; + +/** adds a processing hook to either an rpc base or rpc pool + * + * If a hook returns TERMINATE, the processing is aborted. On CONTINUE, + * the request is immediately processed after the hook returns. If the + * hook returns PAUSE, request processing stops until evrpc_resume_request() + * has been called. + * + * The add functions return handles that can be used for removing hooks. + * + * @param vbase a pointer to either struct evrpc_base or struct evrpc_pool + * @param hook_type either INPUT or OUTPUT + * @param cb the callback to call when the hook is activated + * @param cb_arg an additional argument for the callback + * @return a handle to the hook so it can be removed later + * @see evrpc_remove_hook() + */ +void *evrpc_add_hook(void *vbase, + enum EVRPC_HOOK_TYPE hook_type, + int (*cb)(void *, struct evhttp_request *, struct evbuffer *, void *), + void *cb_arg); + +/** removes a previously added hook + * + * @param vbase a pointer to either struct evrpc_base or struct evrpc_pool + * @param hook_type either INPUT or OUTPUT + * @param handle a handle returned by evrpc_add_hook() + * @return 1 on success or 0 on failure + * @see evrpc_add_hook() + */ +int evrpc_remove_hook(void *vbase, + enum EVRPC_HOOK_TYPE hook_type, + void *handle); + +/** resume a paused request + * + * @param vbase a pointer to either struct evrpc_base or struct evrpc_pool + * @param ctx the context pointer provided to the original hook call + */ +int +evrpc_resume_request(void *vbase, void *ctx, enum EVRPC_HOOK_RESULT res); + +/** adds meta data to request + * + * evrpc_hook_add_meta() allows hooks to add meta data to a request. for + * a client request, the meta data can be inserted by an outgoing request hook + * and retrieved by the incoming request hook. + * + * @param ctx the context provided to the hook call + * @param key a NUL-terminated c-string + * @param data the data to be associated with the key + * @param data_size the size of the data + */ +void evrpc_hook_add_meta(void *ctx, const char *key, + const void *data, size_t data_size); + +/** retrieves meta data previously associated + * + * evrpc_hook_find_meta() can be used to retrieve meta data associated to a + * request by a previous hook. + * @param ctx the context provided to the hook call + * @param key a NUL-terminated c-string + * @param data pointer to a data pointer that will contain the retrieved data + * @param data_size pointer to the size of the data + * @return 0 on success or -1 on failure + */ +int evrpc_hook_find_meta(void *ctx, const char *key, + void **data, size_t *data_size); + +/** + * returns the connection object associated with the request + * + * @param ctx the context provided to the hook call + * @return a pointer to the evhttp_connection object + */ +struct evhttp_connection *evrpc_hook_get_connection(void *ctx); + +/** + Function for sending a generic RPC request. + + Do not call this function directly, use EVRPC_MAKE_REQUEST() instead. + + @see EVRPC_MAKE_REQUEST() + */ +int evrpc_send_request_generic(struct evrpc_pool *pool, + void *request, void *reply, + void (*cb)(struct evrpc_status *, void *, void *, void *), + void *cb_arg, + const char *rpcname, + void (*req_marshal)(struct evbuffer *, void *), + void (*rpl_clear)(void *), + int (*rpl_unmarshal)(void *, struct evbuffer *)); + +/** + Function for registering a generic RPC with the RPC base. + + Do not call this function directly, use EVRPC_REGISTER() instead. + + @see EVRPC_REGISTER() + */ +int +evrpc_register_generic(struct evrpc_base *base, const char *name, + void (*callback)(struct evrpc_req_generic *, void *), void *cbarg, + void *(*req_new)(void *), void *req_new_arg, void (*req_free)(void *), + int (*req_unmarshal)(void *, struct evbuffer *), + void *(*rpl_new)(void *), void *rpl_new_arg, void (*rpl_free)(void *), + int (*rpl_complete)(void *), + void (*rpl_marshal)(struct evbuffer *, void *)); + +/** accessors for obscure and undocumented functionality */ +struct evrpc_pool* evrpc_request_get_pool(struct evrpc_request_wrapper *ctx); +void evrpc_request_set_pool(struct evrpc_request_wrapper *ctx, + struct evrpc_pool *pool); +void evrpc_request_set_cb(struct evrpc_request_wrapper *ctx, + void (*cb)(struct evrpc_status*, void *request, void *reply, void *arg), + void *cb_arg); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_RPC_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/rpc_compat.h b/contrib/ntp/sntp/libevent/include/event2/rpc_compat.h new file mode 100644 index 000000000..8d8334d25 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/rpc_compat.h @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2006-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_RPC_COMPAT_H_INCLUDED_ +#define EVENT2_RPC_COMPAT_H_INCLUDED_ + +/** @file event2/rpc_compat.h + + Deprecated versions of the functions in rpc.h: provided only for + backwards compatibility. + + */ + +#ifdef __cplusplus +extern "C" { +#endif + +/** backwards compatible accessors that work only with gcc */ +#if defined(__GNUC__) && !defined(__STRICT_ANSI__) + +#undef EVTAG_ASSIGN +#undef EVTAG_GET +#undef EVTAG_ADD + +#define EVTAG_ASSIGN(msg, member, args...) \ + (*(msg)->base->member##_assign)(msg, ## args) +#define EVTAG_GET(msg, member, args...) \ + (*(msg)->base->member##_get)(msg, ## args) +#define EVTAG_ADD(msg, member, args...) \ + (*(msg)->base->member##_add)(msg, ## args) +#endif +#define EVTAG_LEN(msg, member) ((msg)->member##_length) + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/rpc_struct.h b/contrib/ntp/sntp/libevent/include/event2/rpc_struct.h new file mode 100644 index 000000000..8f691f49f --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/rpc_struct.h @@ -0,0 +1,100 @@ +/* + * Copyright (c) 2006-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_RPC_STRUCT_H_INCLUDED_ +#define EVENT2_RPC_STRUCT_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +/** @file event2/rpc_struct.h + + Structures used by rpc.h. Using these structures directly may harm + forward compatibility: be careful! + + */ + +/** + * provides information about the completed RPC request. + */ +struct evrpc_status { +#define EVRPC_STATUS_ERR_NONE 0 +#define EVRPC_STATUS_ERR_TIMEOUT 1 +#define EVRPC_STATUS_ERR_BADPAYLOAD 2 +#define EVRPC_STATUS_ERR_UNSTARTED 3 +#define EVRPC_STATUS_ERR_HOOKABORTED 4 + int error; + + /* for looking at headers or other information */ + struct evhttp_request *http_req; +}; + +/* the structure below needs to be synchronized with evrpc_req_generic */ + +/* Encapsulates a request */ +struct evrpc { + TAILQ_ENTRY(evrpc) next; + + /* the URI at which the request handler lives */ + const char* uri; + + /* creates a new request structure */ + void *(*request_new)(void *); + void *request_new_arg; + + /* frees the request structure */ + void (*request_free)(void *); + + /* unmarshals the buffer into the proper request structure */ + int (*request_unmarshal)(void *, struct evbuffer *); + + /* creates a new reply structure */ + void *(*reply_new)(void *); + void *reply_new_arg; + + /* frees the reply structure */ + void (*reply_free)(void *); + + /* verifies that the reply is valid */ + int (*reply_complete)(void *); + + /* marshals the reply into a buffer */ + void (*reply_marshal)(struct evbuffer*, void *); + + /* the callback invoked for each received rpc */ + void (*cb)(struct evrpc_req_generic *, void *); + void *cb_arg; + + /* reference for further configuration */ + struct evrpc_base *base; +}; + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_RPC_STRUCT_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/tag.h b/contrib/ntp/sntp/libevent/include/event2/tag.h new file mode 100644 index 000000000..2f73bfc00 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/tag.h @@ -0,0 +1,146 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_TAG_H_INCLUDED_ +#define EVENT2_TAG_H_INCLUDED_ + +/** @file event2/tag.h + + Helper functions for reading and writing tagged data onto buffers. + + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif + +/* For int types. */ +#include + +struct evbuffer; + +/* + * Marshaling tagged data - We assume that all tags are inserted in their + * numeric order - so that unknown tags will always be higher than the + * known ones - and we can just ignore the end of an event buffer. + */ + +EVENT2_EXPORT_SYMBOL +void evtag_init(void); + +/** + Unmarshals the header and returns the length of the payload + + @param evbuf the buffer from which to unmarshal data + @param ptag a pointer in which the tag id is being stored + @returns -1 on failure or the number of bytes in the remaining payload. +*/ +EVENT2_EXPORT_SYMBOL +int evtag_unmarshal_header(struct evbuffer *evbuf, ev_uint32_t *ptag); + +EVENT2_EXPORT_SYMBOL +void evtag_marshal(struct evbuffer *evbuf, ev_uint32_t tag, const void *data, + ev_uint32_t len); +EVENT2_EXPORT_SYMBOL +void evtag_marshal_buffer(struct evbuffer *evbuf, ev_uint32_t tag, + struct evbuffer *data); + +/** + Encode an integer and store it in an evbuffer. + + We encode integers by nybbles; the first nibble contains the number + of significant nibbles - 1; this allows us to encode up to 64-bit + integers. This function is byte-order independent. + + @param evbuf evbuffer to store the encoded number + @param number a 32-bit integer + */ +EVENT2_EXPORT_SYMBOL +void evtag_encode_int(struct evbuffer *evbuf, ev_uint32_t number); +EVENT2_EXPORT_SYMBOL +void evtag_encode_int64(struct evbuffer *evbuf, ev_uint64_t number); + +EVENT2_EXPORT_SYMBOL +void evtag_marshal_int(struct evbuffer *evbuf, ev_uint32_t tag, + ev_uint32_t integer); +EVENT2_EXPORT_SYMBOL +void evtag_marshal_int64(struct evbuffer *evbuf, ev_uint32_t tag, + ev_uint64_t integer); + +EVENT2_EXPORT_SYMBOL +void evtag_marshal_string(struct evbuffer *buf, ev_uint32_t tag, + const char *string); + +EVENT2_EXPORT_SYMBOL +void evtag_marshal_timeval(struct evbuffer *evbuf, ev_uint32_t tag, + struct timeval *tv); + +EVENT2_EXPORT_SYMBOL +int evtag_unmarshal(struct evbuffer *src, ev_uint32_t *ptag, + struct evbuffer *dst); +EVENT2_EXPORT_SYMBOL +int evtag_peek(struct evbuffer *evbuf, ev_uint32_t *ptag); +EVENT2_EXPORT_SYMBOL +int evtag_peek_length(struct evbuffer *evbuf, ev_uint32_t *plength); +EVENT2_EXPORT_SYMBOL +int evtag_payload_length(struct evbuffer *evbuf, ev_uint32_t *plength); +EVENT2_EXPORT_SYMBOL +int evtag_consume(struct evbuffer *evbuf); + +EVENT2_EXPORT_SYMBOL +int evtag_unmarshal_int(struct evbuffer *evbuf, ev_uint32_t need_tag, + ev_uint32_t *pinteger); +EVENT2_EXPORT_SYMBOL +int evtag_unmarshal_int64(struct evbuffer *evbuf, ev_uint32_t need_tag, + ev_uint64_t *pinteger); + +EVENT2_EXPORT_SYMBOL +int evtag_unmarshal_fixed(struct evbuffer *src, ev_uint32_t need_tag, + void *data, size_t len); + +EVENT2_EXPORT_SYMBOL +int evtag_unmarshal_string(struct evbuffer *evbuf, ev_uint32_t need_tag, + char **pstring); + +EVENT2_EXPORT_SYMBOL +int evtag_unmarshal_timeval(struct evbuffer *evbuf, ev_uint32_t need_tag, + struct timeval *ptv); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_TAG_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/tag_compat.h b/contrib/ntp/sntp/libevent/include/event2/tag_compat.h new file mode 100644 index 000000000..a276c0d35 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/tag_compat.h @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_TAG_COMPAT_H_INCLUDED_ +#define EVENT2_TAG_COMPAT_H_INCLUDED_ + +/** @file event2/tag_compat.h + + Obsolete/deprecated functions from tag.h; provided only for backwards + compatibility. + */ + +/** + @name Misnamed functions + + @deprecated These macros are deprecated because their names don't follow + Libevent's naming conventions. Use evtag_encode_int and + evtag_encode_int64 instead. + + @{ +*/ +#define encode_int(evbuf, number) evtag_encode_int((evbuf), (number)) +#define encode_int64(evbuf, number) evtag_encode_int64((evbuf), (number)) +/**@}*/ + +#endif /* EVENT2_TAG_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/thread.h b/contrib/ntp/sntp/libevent/include/event2/thread.h new file mode 100644 index 000000000..b51998631 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/thread.h @@ -0,0 +1,253 @@ +/* + * Copyright (c) 2008-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_THREAD_H_INCLUDED_ +#define EVENT2_THREAD_H_INCLUDED_ + +/** @file event2/thread.h + + Functions for multi-threaded applications using Libevent. + + When using a multi-threaded application in which multiple threads + add and delete events from a single event base, Libevent needs to + lock its data structures. + + Like the memory-management function hooks, all of the threading functions + _must_ be set up before an event_base is created if you want the base to + use them. + + Most programs will either be using Windows threads or Posix threads. You + can configure Libevent to use one of these event_use_windows_threads() or + event_use_pthreads() respectively. If you're using another threading + library, you'll need to configure threading functions manually using + evthread_set_lock_callbacks() and evthread_set_condition_callbacks(). + + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +/** + @name Flags passed to lock functions + + @{ +*/ +/** A flag passed to a locking callback when the lock was allocated as a + * read-write lock, and we want to acquire or release the lock for writing. */ +#define EVTHREAD_WRITE 0x04 +/** A flag passed to a locking callback when the lock was allocated as a + * read-write lock, and we want to acquire or release the lock for reading. */ +#define EVTHREAD_READ 0x08 +/** A flag passed to a locking callback when we don't want to block waiting + * for the lock; if we can't get the lock immediately, we will instead + * return nonzero from the locking callback. */ +#define EVTHREAD_TRY 0x10 +/**@}*/ + +#if !defined(EVENT__DISABLE_THREAD_SUPPORT) || defined(EVENT_IN_DOXYGEN_) + +#define EVTHREAD_LOCK_API_VERSION 1 + +/** + @name Types of locks + + @{*/ +/** A recursive lock is one that can be acquired multiple times at once by the + * same thread. No other process can allocate the lock until the thread that + * has been holding it has unlocked it as many times as it locked it. */ +#define EVTHREAD_LOCKTYPE_RECURSIVE 1 +/* A read-write lock is one that allows multiple simultaneous readers, but + * where any one writer excludes all other writers and readers. */ +#define EVTHREAD_LOCKTYPE_READWRITE 2 +/**@}*/ + +/** This structure describes the interface a threading library uses for + * locking. It's used to tell evthread_set_lock_callbacks() how to use + * locking on this platform. + */ +struct evthread_lock_callbacks { + /** The current version of the locking API. Set this to + * EVTHREAD_LOCK_API_VERSION */ + int lock_api_version; + /** Which kinds of locks does this version of the locking API + * support? A bitfield of EVTHREAD_LOCKTYPE_RECURSIVE and + * EVTHREAD_LOCKTYPE_READWRITE. + * + * (Note that RECURSIVE locks are currently mandatory, and + * READWRITE locks are not currently used.) + **/ + unsigned supported_locktypes; + /** Function to allocate and initialize new lock of type 'locktype'. + * Returns NULL on failure. */ + void *(*alloc)(unsigned locktype); + /** Funtion to release all storage held in 'lock', which was created + * with type 'locktype'. */ + void (*free)(void *lock, unsigned locktype); + /** Acquire an already-allocated lock at 'lock' with mode 'mode'. + * Returns 0 on success, and nonzero on failure. */ + int (*lock)(unsigned mode, void *lock); + /** Release a lock at 'lock' using mode 'mode'. Returns 0 on success, + * and nonzero on failure. */ + int (*unlock)(unsigned mode, void *lock); +}; + +/** Sets a group of functions that Libevent should use for locking. + * For full information on the required callback API, see the + * documentation for the individual members of evthread_lock_callbacks. + * + * Note that if you're using Windows or the Pthreads threading library, you + * probably shouldn't call this function; instead, use + * evthread_use_windows_threads() or evthread_use_posix_threads() if you can. + */ +EVENT2_EXPORT_SYMBOL +int evthread_set_lock_callbacks(const struct evthread_lock_callbacks *); + +#define EVTHREAD_CONDITION_API_VERSION 1 + +struct timeval; + +/** This structure describes the interface a threading library uses for + * condition variables. It's used to tell evthread_set_condition_callbacks + * how to use locking on this platform. + */ +struct evthread_condition_callbacks { + /** The current version of the conditions API. Set this to + * EVTHREAD_CONDITION_API_VERSION */ + int condition_api_version; + /** Function to allocate and initialize a new condition variable. + * Returns the condition variable on success, and NULL on failure. + * The 'condtype' argument will be 0 with this API version. + */ + void *(*alloc_condition)(unsigned condtype); + /** Function to free a condition variable. */ + void (*free_condition)(void *cond); + /** Function to signal a condition variable. If 'broadcast' is 1, all + * threads waiting on 'cond' should be woken; otherwise, only on one + * thread is worken. Should return 0 on success, -1 on failure. + * This function will only be called while holding the associated + * lock for the condition. + */ + int (*signal_condition)(void *cond, int broadcast); + /** Function to wait for a condition variable. The lock 'lock' + * will be held when this function is called; should be released + * while waiting for the condition to be come signalled, and + * should be held again when this function returns. + * If timeout is provided, it is interval of seconds to wait for + * the event to become signalled; if it is NULL, the function + * should wait indefinitely. + * + * The function should return -1 on error; 0 if the condition + * was signalled, or 1 on a timeout. */ + int (*wait_condition)(void *cond, void *lock, + const struct timeval *timeout); +}; + +/** Sets a group of functions that Libevent should use for condition variables. + * For full information on the required callback API, see the + * documentation for the individual members of evthread_condition_callbacks. + * + * Note that if you're using Windows or the Pthreads threading library, you + * probably shouldn't call this function; instead, use + * evthread_use_windows_threads() or evthread_use_pthreads() if you can. + */ +EVENT2_EXPORT_SYMBOL +int evthread_set_condition_callbacks( + const struct evthread_condition_callbacks *); + +/** + Sets the function for determining the thread id. + + @param base the event base for which to set the id function + @param id_fn the identify function Libevent should invoke to + determine the identity of a thread. +*/ +EVENT2_EXPORT_SYMBOL +void evthread_set_id_callback( + unsigned long (*id_fn)(void)); + +#if (defined(_WIN32) && !defined(EVENT__DISABLE_THREAD_SUPPORT)) || defined(EVENT_IN_DOXYGEN_) +/** Sets up Libevent for use with Windows builtin locking and thread ID + functions. Unavailable if Libevent is not built for Windows. + + @return 0 on success, -1 on failure. */ +EVENT2_EXPORT_SYMBOL +int evthread_use_windows_threads(void); +/** + Defined if Libevent was built with support for evthread_use_windows_threads() +*/ +#define EVTHREAD_USE_WINDOWS_THREADS_IMPLEMENTED 1 +#endif + +#if defined(EVENT__HAVE_PTHREADS) || defined(EVENT_IN_DOXYGEN_) +/** Sets up Libevent for use with Pthreads locking and thread ID functions. + Unavailable if Libevent is not build for use with pthreads. Requires + libraries to link against Libevent_pthreads as well as Libevent. + + @return 0 on success, -1 on failure. */ +EVENT2_EXPORT_SYMBOL +int evthread_use_pthreads(void); +/** Defined if Libevent was built with support for evthread_use_pthreads() */ +#define EVTHREAD_USE_PTHREADS_IMPLEMENTED 1 + +#endif + +/** Enable debugging wrappers around the current lock callbacks. If Libevent + * makes one of several common locking errors, exit with an assertion failure. + * + * If you're going to call this function, you must do so before any locks are + * allocated. + **/ +EVENT2_EXPORT_SYMBOL +void evthread_enable_lock_debugging(void); + +/* Old (misspelled) version: This is deprecated; use + * evthread_enable_log_debugging instead. */ +EVENT2_EXPORT_SYMBOL +void evthread_enable_lock_debuging(void); + +#endif /* EVENT__DISABLE_THREAD_SUPPORT */ + +struct event_base; +/** Make sure it's safe to tell an event base to wake up from another thread + or a signal handler. + + You shouldn't need to call this by hand; configuring the base with thread + support should be necessary and sufficient. + + @return 0 on success, -1 on failure. + */ +EVENT2_EXPORT_SYMBOL +int evthread_make_base_notifiable(struct event_base *base); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT2_THREAD_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/util.h b/contrib/ntp/sntp/libevent/include/event2/util.h new file mode 100644 index 000000000..b152a4b40 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/util.h @@ -0,0 +1,837 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_UTIL_H_INCLUDED_ +#define EVENT2_UTIL_H_INCLUDED_ + +/** @file event2/util.h + + Common convenience functions for cross-platform portability and + related socket manipulations. + + */ +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#ifdef EVENT__HAVE_STDINT_H +#include +#elif defined(EVENT__HAVE_INTTYPES_H) +#include +#endif +#ifdef EVENT__HAVE_SYS_TYPES_H +#include +#endif +#ifdef EVENT__HAVE_STDDEF_H +#include +#endif +#ifdef _MSC_VER +#include +#endif +#include +#ifdef EVENT__HAVE_NETDB_H +#if !defined(_GNU_SOURCE) +#define _GNU_SOURCE +#endif +#include +#endif + +#ifdef _WIN32 +#include +#ifdef EVENT__HAVE_GETADDRINFO +/* for EAI_* definitions. */ +#include +#endif +#else +#include +#endif + +/* Some openbsd autoconf versions get the name of this macro wrong. */ +#if defined(EVENT__SIZEOF_VOID__) && !defined(EVENT__SIZEOF_VOID_P) +#define EVENT__SIZEOF_VOID_P EVENT__SIZEOF_VOID__ +#endif + +/** + * @name Standard integer types. + * + * Integer type definitions for types that are supposed to be defined in the + * C99-specified stdint.h. Shamefully, some platforms do not include + * stdint.h, so we need to replace it. (If you are on a platform like this, + * your C headers are now over 10 years out of date. You should bug them to + * do something about this.) + * + * We define: + * + *
      + *
      ev_uint64_t, ev_uint32_t, ev_uint16_t, ev_uint8_t
      + *
      unsigned integer types of exactly 64, 32, 16, and 8 bits + * respectively.
      + *
      ev_int64_t, ev_int32_t, ev_int16_t, ev_int8_t
      + *
      signed integer types of exactly 64, 32, 16, and 8 bits + * respectively.
      + *
      ev_uintptr_t, ev_intptr_t
      + *
      unsigned/signed integers large enough + * to hold a pointer without loss of bits.
      + *
      ev_ssize_t
      + *
      A signed type of the same size as size_t
      + *
      ev_off_t
      + *
      A signed type typically used to represent offsets within a + * (potentially large) file
      + * + * @{ + */ +#ifdef EVENT__HAVE_UINT64_T +#define ev_uint64_t uint64_t +#define ev_int64_t int64_t +#elif defined(_WIN32) +#define ev_uint64_t unsigned __int64 +#define ev_int64_t signed __int64 +#elif EVENT__SIZEOF_LONG_LONG == 8 +#define ev_uint64_t unsigned long long +#define ev_int64_t long long +#elif EVENT__SIZEOF_LONG == 8 +#define ev_uint64_t unsigned long +#define ev_int64_t long +#elif defined(EVENT_IN_DOXYGEN_) +#define ev_uint64_t ... +#define ev_int64_t ... +#else +#error "No way to define ev_uint64_t" +#endif + +#ifdef EVENT__HAVE_UINT32_T +#define ev_uint32_t uint32_t +#define ev_int32_t int32_t +#elif defined(_WIN32) +#define ev_uint32_t unsigned int +#define ev_int32_t signed int +#elif EVENT__SIZEOF_LONG == 4 +#define ev_uint32_t unsigned long +#define ev_int32_t signed long +#elif EVENT__SIZEOF_INT == 4 +#define ev_uint32_t unsigned int +#define ev_int32_t signed int +#elif defined(EVENT_IN_DOXYGEN_) +#define ev_uint32_t ... +#define ev_int32_t ... +#else +#error "No way to define ev_uint32_t" +#endif + +#ifdef EVENT__HAVE_UINT16_T +#define ev_uint16_t uint16_t +#define ev_int16_t int16_t +#elif defined(_WIN32) +#define ev_uint16_t unsigned short +#define ev_int16_t signed short +#elif EVENT__SIZEOF_INT == 2 +#define ev_uint16_t unsigned int +#define ev_int16_t signed int +#elif EVENT__SIZEOF_SHORT == 2 +#define ev_uint16_t unsigned short +#define ev_int16_t signed short +#elif defined(EVENT_IN_DOXYGEN_) +#define ev_uint16_t ... +#define ev_int16_t ... +#else +#error "No way to define ev_uint16_t" +#endif + +#ifdef EVENT__HAVE_UINT8_T +#define ev_uint8_t uint8_t +#define ev_int8_t int8_t +#elif defined(EVENT_IN_DOXYGEN_) +#define ev_uint8_t ... +#define ev_int8_t ... +#else +#define ev_uint8_t unsigned char +#define ev_int8_t signed char +#endif + +#ifdef EVENT__HAVE_UINTPTR_T +#define ev_uintptr_t uintptr_t +#define ev_intptr_t intptr_t +#elif EVENT__SIZEOF_VOID_P <= 4 +#define ev_uintptr_t ev_uint32_t +#define ev_intptr_t ev_int32_t +#elif EVENT__SIZEOF_VOID_P <= 8 +#define ev_uintptr_t ev_uint64_t +#define ev_intptr_t ev_int64_t +#elif defined(EVENT_IN_DOXYGEN_) +#define ev_uintptr_t ... +#define ev_intptr_t ... +#else +#error "No way to define ev_uintptr_t" +#endif + +#ifdef EVENT__ssize_t +#define ev_ssize_t EVENT__ssize_t +#else +#define ev_ssize_t ssize_t +#endif + +/* Note that we define ev_off_t based on the compile-time size of off_t that + * we used to build Libevent, and not based on the current size of off_t. + * (For example, we don't define ev_off_t to off_t.). We do this because + * some systems let you build your software with different off_t sizes + * at runtime, and so putting in any dependency on off_t would risk API + * mismatch. + */ +#ifdef _WIN32 +#define ev_off_t ev_int64_t +#elif EVENT__SIZEOF_OFF_T == 8 +#define ev_off_t ev_int64_t +#elif EVENT__SIZEOF_OFF_T == 4 +#define ev_off_t ev_int32_t +#elif defined(EVENT_IN_DOXYGEN_) +#define ev_off_t ... +#else +#define ev_off_t off_t +#endif +/**@}*/ + +/* Limits for integer types. + + We're making two assumptions here: + - The compiler does constant folding properly. + - The platform does signed arithmetic in two's complement. +*/ + +/** + @name Limits for integer types + + These macros hold the largest or smallest values possible for the + ev_[u]int*_t types. + + @{ +*/ +#define EV_UINT64_MAX ((((ev_uint64_t)0xffffffffUL) << 32) | 0xffffffffUL) +#define EV_INT64_MAX ((((ev_int64_t) 0x7fffffffL) << 32) | 0xffffffffL) +#define EV_INT64_MIN ((-EV_INT64_MAX) - 1) +#define EV_UINT32_MAX ((ev_uint32_t)0xffffffffUL) +#define EV_INT32_MAX ((ev_int32_t) 0x7fffffffL) +#define EV_INT32_MIN ((-EV_INT32_MAX) - 1) +#define EV_UINT16_MAX ((ev_uint16_t)0xffffUL) +#define EV_INT16_MAX ((ev_int16_t) 0x7fffL) +#define EV_INT16_MIN ((-EV_INT16_MAX) - 1) +#define EV_UINT8_MAX 255 +#define EV_INT8_MAX 127 +#define EV_INT8_MIN ((-EV_INT8_MAX) - 1) +/** @} */ + +/** + @name Limits for SIZE_T and SSIZE_T + + @{ +*/ +#if EVENT__SIZEOF_SIZE_T == 8 +#define EV_SIZE_MAX EV_UINT64_MAX +#define EV_SSIZE_MAX EV_INT64_MAX +#elif EVENT__SIZEOF_SIZE_T == 4 +#define EV_SIZE_MAX EV_UINT32_MAX +#define EV_SSIZE_MAX EV_INT32_MAX +#elif defined(EVENT_IN_DOXYGEN_) +#define EV_SIZE_MAX ... +#define EV_SSIZE_MAX ... +#else +#error "No way to define SIZE_MAX" +#endif + +#define EV_SSIZE_MIN ((-EV_SSIZE_MAX) - 1) +/**@}*/ + +#ifdef _WIN32 +#define ev_socklen_t int +#elif defined(EVENT__socklen_t) +#define ev_socklen_t EVENT__socklen_t +#else +#define ev_socklen_t socklen_t +#endif + +#ifdef EVENT__HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY +#if !defined(EVENT__HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY) \ + && !defined(ss_family) +#define ss_family __ss_family +#endif +#endif + +/** + * A type wide enough to hold the output of "socket()" or "accept()". On + * Windows, this is an intptr_t; elsewhere, it is an int. */ +#ifdef _WIN32 +#define evutil_socket_t intptr_t +#else +#define evutil_socket_t int +#endif + +/** + * Structure to hold information about a monotonic timer + * + * Use this with evutil_configure_monotonic_time() and + * evutil_gettime_monotonic(). + * + * This is an opaque structure; you can allocate one using + * evutil_monotonic_timer_new(). + * + * @see evutil_monotonic_timer_new(), evutil_monotonic_timer_free(), + * evutil_configure_monotonic_time(), evutil_gettime_monotonic() + */ +struct evutil_monotonic_timer +#ifdef EVENT_IN_DOXYGEN_ +{/*Empty body so that doxygen will generate documentation here.*/} +#endif +; + +#define EV_MONOT_PRECISE 1 +#define EV_MONOT_FALLBACK 2 + +/** Allocate a new struct evutil_monotonic_timer for use with the + * evutil_configure_monotonic_time() and evutil_gettime_monotonic() + * functions. You must configure the timer with + * evutil_configure_monotonic_time() before using it. + */ +EVENT2_EXPORT_SYMBOL +struct evutil_monotonic_timer * evutil_monotonic_timer_new(void); + +/** Free a struct evutil_monotonic_timer that was allocated using + * evutil_monotonic_timer_new(). + */ +EVENT2_EXPORT_SYMBOL +void evutil_monotonic_timer_free(struct evutil_monotonic_timer *timer); + +/** Set up a struct evutil_monotonic_timer; flags can include + * EV_MONOT_PRECISE and EV_MONOT_FALLBACK. + */ +EVENT2_EXPORT_SYMBOL +int evutil_configure_monotonic_time(struct evutil_monotonic_timer *timer, + int flags); + +/** Query the current monotonic time from a struct evutil_monotonic_timer + * previously configured with evutil_configure_monotonic_time(). Monotonic + * time is guaranteed never to run in reverse, but is not necessarily epoch- + * based, or relative to any other definite point. Use it to make reliable + * measurements of elapsed time between events even when the system time + * may be changed. + * + * It is not safe to use this funtion on the same timer from multiple + * threads. + */ +EVENT2_EXPORT_SYMBOL +int evutil_gettime_monotonic(struct evutil_monotonic_timer *timer, + struct timeval *tp); + +/** Create two new sockets that are connected to each other. + + On Unix, this simply calls socketpair(). On Windows, it uses the + loopback network interface on 127.0.0.1, and only + AF_INET,SOCK_STREAM are supported. + + (This may fail on some Windows hosts where firewall software has cleverly + decided to keep 127.0.0.1 from talking to itself.) + + Parameters and return values are as for socketpair() +*/ +EVENT2_EXPORT_SYMBOL +int evutil_socketpair(int d, int type, int protocol, evutil_socket_t sv[2]); +/** Do platform-specific operations as needed to make a socket nonblocking. + + @param sock The socket to make nonblocking + @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int evutil_make_socket_nonblocking(evutil_socket_t sock); + +/** Do platform-specific operations to make a listener socket reusable. + + Specifically, we want to make sure that another program will be able + to bind this address right after we've closed the listener. + + This differs from Windows's interpretation of "reusable", which + allows multiple listeners to bind the same address at the same time. + + @param sock The socket to make reusable + @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int evutil_make_listen_socket_reuseable(evutil_socket_t sock); + +/** Do platform-specific operations to make a listener port reusable. + + Specifically, we want to make sure that multiple programs which also + set the same socket option will be able to bind, listen at the same time. + + This is a feature available only to Linux 3.9+ + + @param sock The socket to make reusable + @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int evutil_make_listen_socket_reuseable_port(evutil_socket_t sock); + +/** Do platform-specific operations as needed to close a socket upon a + successful execution of one of the exec*() functions. + + @param sock The socket to be closed + @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int evutil_make_socket_closeonexec(evutil_socket_t sock); + +/** Do the platform-specific call needed to close a socket returned from + socket() or accept(). + + @param sock The socket to be closed + @return 0 on success, -1 on failure + */ +EVENT2_EXPORT_SYMBOL +int evutil_closesocket(evutil_socket_t sock); +#define EVUTIL_CLOSESOCKET(s) evutil_closesocket(s) + +/** Do platform-specific operations, if possible, to make a tcp listener + * socket defer accept()s until there is data to read. + * + * Not all platforms support this. You don't want to do this for every + * listener socket: only the ones that implement a protocol where the + * client transmits before the server needs to respond. + * + * @param sock The listening socket to to make deferred + * @return 0 on success (whether the operation is supported or not), + * -1 on failure +*/ +EVENT2_EXPORT_SYMBOL +int evutil_make_tcp_listen_socket_deferred(evutil_socket_t sock); + +#ifdef _WIN32 +/** Return the most recent socket error. Not idempotent on all platforms. */ +#define EVUTIL_SOCKET_ERROR() WSAGetLastError() +/** Replace the most recent socket error with errcode */ +#define EVUTIL_SET_SOCKET_ERROR(errcode) \ + do { WSASetLastError(errcode); } while (0) +/** Return the most recent socket error to occur on sock. */ +EVENT2_EXPORT_SYMBOL +int evutil_socket_geterror(evutil_socket_t sock); +/** Convert a socket error to a string. */ +EVENT2_EXPORT_SYMBOL +const char *evutil_socket_error_to_string(int errcode); +#elif defined(EVENT_IN_DOXYGEN_) +/** + @name Socket error functions + + These functions are needed for making programs compatible between + Windows and Unix-like platforms. + + You see, Winsock handles socket errors differently from the rest of + the world. Elsewhere, a socket error is like any other error and is + stored in errno. But winsock functions require you to retrieve the + error with a special function, and don't let you use strerror for + the error codes. And handling EWOULDBLOCK is ... different. + + @{ +*/ +/** Return the most recent socket error. Not idempotent on all platforms. */ +#define EVUTIL_SOCKET_ERROR() ... +/** Replace the most recent socket error with errcode */ +#define EVUTIL_SET_SOCKET_ERROR(errcode) ... +/** Return the most recent socket error to occur on sock. */ +#define evutil_socket_geterror(sock) ... +/** Convert a socket error to a string. */ +#define evutil_socket_error_to_string(errcode) ... +/**@}*/ +#else +#define EVUTIL_SOCKET_ERROR() (errno) +#define EVUTIL_SET_SOCKET_ERROR(errcode) \ + do { errno = (errcode); } while (0) +#define evutil_socket_geterror(sock) (errno) +#define evutil_socket_error_to_string(errcode) (strerror(errcode)) +#endif + + +/** + * @name Manipulation macros for struct timeval. + * + * We define replacements + * for timeradd, timersub, timerclear, timercmp, and timerisset. + * + * @{ + */ +#ifdef EVENT__HAVE_TIMERADD +#define evutil_timeradd(tvp, uvp, vvp) timeradd((tvp), (uvp), (vvp)) +#define evutil_timersub(tvp, uvp, vvp) timersub((tvp), (uvp), (vvp)) +#else +#define evutil_timeradd(tvp, uvp, vvp) \ + do { \ + (vvp)->tv_sec = (tvp)->tv_sec + (uvp)->tv_sec; \ + (vvp)->tv_usec = (tvp)->tv_usec + (uvp)->tv_usec; \ + if ((vvp)->tv_usec >= 1000000) { \ + (vvp)->tv_sec++; \ + (vvp)->tv_usec -= 1000000; \ + } \ + } while (0) +#define evutil_timersub(tvp, uvp, vvp) \ + do { \ + (vvp)->tv_sec = (tvp)->tv_sec - (uvp)->tv_sec; \ + (vvp)->tv_usec = (tvp)->tv_usec - (uvp)->tv_usec; \ + if ((vvp)->tv_usec < 0) { \ + (vvp)->tv_sec--; \ + (vvp)->tv_usec += 1000000; \ + } \ + } while (0) +#endif /* !EVENT__HAVE_TIMERADD */ + +#ifdef EVENT__HAVE_TIMERCLEAR +#define evutil_timerclear(tvp) timerclear(tvp) +#else +#define evutil_timerclear(tvp) (tvp)->tv_sec = (tvp)->tv_usec = 0 +#endif +/**@}*/ + +/** Return true iff the tvp is related to uvp according to the relational + * operator cmp. Recognized values for cmp are ==, <=, <, >=, and >. */ +#define evutil_timercmp(tvp, uvp, cmp) \ + (((tvp)->tv_sec == (uvp)->tv_sec) ? \ + ((tvp)->tv_usec cmp (uvp)->tv_usec) : \ + ((tvp)->tv_sec cmp (uvp)->tv_sec)) + +#ifdef EVENT__HAVE_TIMERISSET +#define evutil_timerisset(tvp) timerisset(tvp) +#else +#define evutil_timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_usec) +#endif + +/** Replacement for offsetof on platforms that don't define it. */ +#ifdef offsetof +#define evutil_offsetof(type, field) offsetof(type, field) +#else +#define evutil_offsetof(type, field) ((off_t)(&((type *)0)->field)) +#endif + +/* big-int related functions */ +/** Parse a 64-bit value from a string. Arguments are as for strtol. */ +EVENT2_EXPORT_SYMBOL +ev_int64_t evutil_strtoll(const char *s, char **endptr, int base); + +/** Replacement for gettimeofday on platforms that lack it. */ +#ifdef EVENT__HAVE_GETTIMEOFDAY +#define evutil_gettimeofday(tv, tz) gettimeofday((tv), (tz)) +#else +struct timezone; +EVENT2_EXPORT_SYMBOL +int evutil_gettimeofday(struct timeval *tv, struct timezone *tz); +#endif + +/** Replacement for snprintf to get consistent behavior on platforms for + which the return value of snprintf does not conform to C99. + */ +EVENT2_EXPORT_SYMBOL +int evutil_snprintf(char *buf, size_t buflen, const char *format, ...) +#ifdef __GNUC__ + __attribute__((format(printf, 3, 4))) +#endif +; +/** Replacement for vsnprintf to get consistent behavior on platforms for + which the return value of snprintf does not conform to C99. + */ +EVENT2_EXPORT_SYMBOL +int evutil_vsnprintf(char *buf, size_t buflen, const char *format, va_list ap) +#ifdef __GNUC__ + __attribute__((format(printf, 3, 0))) +#endif +; + +/** Replacement for inet_ntop for platforms which lack it. */ +EVENT2_EXPORT_SYMBOL +const char *evutil_inet_ntop(int af, const void *src, char *dst, size_t len); +/** Replacement for inet_pton for platforms which lack it. */ +EVENT2_EXPORT_SYMBOL +int evutil_inet_pton(int af, const char *src, void *dst); +struct sockaddr; + +/** Parse an IPv4 or IPv6 address, with optional port, from a string. + + Recognized formats are: + - [IPv6Address]:port + - [IPv6Address] + - IPv6Address + - IPv4Address:port + - IPv4Address + + If no port is specified, the port in the output is set to 0. + + @param str The string to parse. + @param out A struct sockaddr to hold the result. This should probably be + a struct sockaddr_storage. + @param outlen A pointer to the number of bytes that that 'out' can safely + hold. Set to the number of bytes used in 'out' on success. + @return -1 if the address is not well-formed, if the port is out of range, + or if out is not large enough to hold the result. Otherwise returns + 0 on success. +*/ +EVENT2_EXPORT_SYMBOL +int evutil_parse_sockaddr_port(const char *str, struct sockaddr *out, int *outlen); + +/** Compare two sockaddrs; return 0 if they are equal, or less than 0 if sa1 + * preceeds sa2, or greater than 0 if sa1 follows sa2. If include_port is + * true, consider the port as well as the address. Only implemented for + * AF_INET and AF_INET6 addresses. The ordering is not guaranteed to remain + * the same between Libevent versions. */ +EVENT2_EXPORT_SYMBOL +int evutil_sockaddr_cmp(const struct sockaddr *sa1, const struct sockaddr *sa2, + int include_port); + +/** As strcasecmp, but always compares the characters in locale-independent + ASCII. That's useful if you're handling data in ASCII-based protocols. + */ +EVENT2_EXPORT_SYMBOL +int evutil_ascii_strcasecmp(const char *str1, const char *str2); +/** As strncasecmp, but always compares the characters in locale-independent + ASCII. That's useful if you're handling data in ASCII-based protocols. + */ +EVENT2_EXPORT_SYMBOL +int evutil_ascii_strncasecmp(const char *str1, const char *str2, size_t n); + +/* Here we define evutil_addrinfo to the native addrinfo type, or redefine it + * if this system has no getaddrinfo(). */ +#ifdef EVENT__HAVE_STRUCT_ADDRINFO +#define evutil_addrinfo addrinfo +#else +/** A definition of struct addrinfo for systems that lack it. + + (This is just an alias for struct addrinfo if the system defines + struct addrinfo.) +*/ +struct evutil_addrinfo { + int ai_flags; /* AI_PASSIVE, AI_CANONNAME, AI_NUMERICHOST */ + int ai_family; /* PF_xxx */ + int ai_socktype; /* SOCK_xxx */ + int ai_protocol; /* 0 or IPPROTO_xxx for IPv4 and IPv6 */ + size_t ai_addrlen; /* length of ai_addr */ + char *ai_canonname; /* canonical name for nodename */ + struct sockaddr *ai_addr; /* binary address */ + struct evutil_addrinfo *ai_next; /* next structure in linked list */ +}; +#endif +/** @name evutil_getaddrinfo() error codes + + These values are possible error codes for evutil_getaddrinfo() and + related functions. + + @{ +*/ +#if defined(EAI_ADDRFAMILY) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_ADDRFAMILY EAI_ADDRFAMILY +#else +#define EVUTIL_EAI_ADDRFAMILY -901 +#endif +#if defined(EAI_AGAIN) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_AGAIN EAI_AGAIN +#else +#define EVUTIL_EAI_AGAIN -902 +#endif +#if defined(EAI_BADFLAGS) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_BADFLAGS EAI_BADFLAGS +#else +#define EVUTIL_EAI_BADFLAGS -903 +#endif +#if defined(EAI_FAIL) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_FAIL EAI_FAIL +#else +#define EVUTIL_EAI_FAIL -904 +#endif +#if defined(EAI_FAMILY) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_FAMILY EAI_FAMILY +#else +#define EVUTIL_EAI_FAMILY -905 +#endif +#if defined(EAI_MEMORY) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_MEMORY EAI_MEMORY +#else +#define EVUTIL_EAI_MEMORY -906 +#endif +/* This test is a bit complicated, since some MS SDKs decide to + * remove NODATA or redefine it to be the same as NONAME, in a + * fun interpretation of RFC 2553 and RFC 3493. */ +#if defined(EAI_NODATA) && defined(EVENT__HAVE_GETADDRINFO) && (!defined(EAI_NONAME) || EAI_NODATA != EAI_NONAME) +#define EVUTIL_EAI_NODATA EAI_NODATA +#else +#define EVUTIL_EAI_NODATA -907 +#endif +#if defined(EAI_NONAME) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_NONAME EAI_NONAME +#else +#define EVUTIL_EAI_NONAME -908 +#endif +#if defined(EAI_SERVICE) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_SERVICE EAI_SERVICE +#else +#define EVUTIL_EAI_SERVICE -909 +#endif +#if defined(EAI_SOCKTYPE) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_SOCKTYPE EAI_SOCKTYPE +#else +#define EVUTIL_EAI_SOCKTYPE -910 +#endif +#if defined(EAI_SYSTEM) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_EAI_SYSTEM EAI_SYSTEM +#else +#define EVUTIL_EAI_SYSTEM -911 +#endif + +#define EVUTIL_EAI_CANCEL -90001 + +#if defined(AI_PASSIVE) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_AI_PASSIVE AI_PASSIVE +#else +#define EVUTIL_AI_PASSIVE 0x1000 +#endif +#if defined(AI_CANONNAME) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_AI_CANONNAME AI_CANONNAME +#else +#define EVUTIL_AI_CANONNAME 0x2000 +#endif +#if defined(AI_NUMERICHOST) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_AI_NUMERICHOST AI_NUMERICHOST +#else +#define EVUTIL_AI_NUMERICHOST 0x4000 +#endif +#if defined(AI_NUMERICSERV) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_AI_NUMERICSERV AI_NUMERICSERV +#else +#define EVUTIL_AI_NUMERICSERV 0x8000 +#endif +#if defined(AI_V4MAPPED) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_AI_V4MAPPED AI_V4MAPPED +#else +#define EVUTIL_AI_V4MAPPED 0x10000 +#endif +#if defined(AI_ALL) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_AI_ALL AI_ALL +#else +#define EVUTIL_AI_ALL 0x20000 +#endif +#if defined(AI_ADDRCONFIG) && defined(EVENT__HAVE_GETADDRINFO) +#define EVUTIL_AI_ADDRCONFIG AI_ADDRCONFIG +#else +#define EVUTIL_AI_ADDRCONFIG 0x40000 +#endif +/**@}*/ + +struct evutil_addrinfo; +/** + * This function clones getaddrinfo for systems that don't have it. For full + * details, see RFC 3493, section 6.1. + * + * Limitations: + * - When the system has no getaddrinfo, we fall back to gethostbyname_r or + * gethostbyname, with their attendant issues. + * - The AI_V4MAPPED and AI_ALL flags are not currently implemented. + * + * For a nonblocking variant, see evdns_getaddrinfo. + */ +EVENT2_EXPORT_SYMBOL +int evutil_getaddrinfo(const char *nodename, const char *servname, + const struct evutil_addrinfo *hints_in, struct evutil_addrinfo **res); + +/** Release storage allocated by evutil_getaddrinfo or evdns_getaddrinfo. */ +EVENT2_EXPORT_SYMBOL +void evutil_freeaddrinfo(struct evutil_addrinfo *ai); + +EVENT2_EXPORT_SYMBOL +const char *evutil_gai_strerror(int err); + +/** Generate n bytes of secure pseudorandom data, and store them in buf. + * + * Current versions of Libevent use an ARC4-based random number generator, + * seeded using the platform's entropy source (/dev/urandom on Unix-like + * systems; CryptGenRandom on Windows). This is not actually as secure as it + * should be: ARC4 is a pretty lousy cipher, and the current implementation + * provides only rudimentary prediction- and backtracking-resistance. Don't + * use this for serious cryptographic applications. + */ +EVENT2_EXPORT_SYMBOL +void evutil_secure_rng_get_bytes(void *buf, size_t n); + +/** + * Seed the secure random number generator if needed, and return 0 on + * success or -1 on failure. + * + * It is okay to call this function more than once; it will still return + * 0 if the RNG has been successfully seeded and -1 if it can't be + * seeded. + * + * Ordinarily you don't need to call this function from your own code; + * Libevent will seed the RNG itself the first time it needs good random + * numbers. You only need to call it if (a) you want to double-check + * that one of the seeding methods did succeed, or (b) you plan to drop + * the capability to seed (by chrooting, or dropping capabilities, or + * whatever), and you want to make sure that seeding happens before your + * program loses the ability to do it. + */ +EVENT2_EXPORT_SYMBOL +int evutil_secure_rng_init(void); + +/** + * Set a filename to use in place of /dev/urandom for seeding the secure + * PRNG. Return 0 on success, -1 on failure. + * + * Call this function BEFORE calling any other initialization or RNG + * functions. + * + * (This string will _NOT_ be copied internally. Do not free it while any + * user of the secure RNG might be running. Don't pass anything other than a + * real /dev/...random device file here, or you might lose security.) + * + * This API is unstable, and might change in a future libevent version. + */ +EVENT2_EXPORT_SYMBOL +int evutil_secure_rng_set_urandom_device_file(char *fname); + +/** Seed the random number generator with extra random bytes. + + You should almost never need to call this function; it should be + sufficient to invoke evutil_secure_rng_init(), or let Libevent take + care of calling evutil_secure_rng_init() on its own. + + If you call this function as a _replacement_ for the regular + entropy sources, then you need to be sure that your input + contains a fairly large amount of strong entropy. Doing so is + notoriously hard: most people who try get it wrong. Watch out! + + @param dat a buffer full of a strong source of random numbers + @param datlen the number of bytes to read from datlen + */ +EVENT2_EXPORT_SYMBOL +void evutil_secure_rng_add_bytes(const char *dat, size_t datlen); + +#ifdef __cplusplus +} +#endif + +#endif /* EVENT1_EVUTIL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/event2/visibility.h b/contrib/ntp/sntp/libevent/include/event2/visibility.h new file mode 100644 index 000000000..5e7163a1e --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/event2/visibility.h @@ -0,0 +1,55 @@ +/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT2_VISIBILITY_H_INCLUDED_ +#define EVENT2_VISIBILITY_H_INCLUDED_ + +#include + +#if defined(event_EXPORTS) || defined(event_extra_EXPORTS) || defined(event_core_EXPORTS) + +#if defined (__SUNPRO_C) && (__SUNPRO_C >= 0x550) +#define EVENT2_EXPORT_SYMBOL __global +#elif defined __GNUC__ +#define EVENT2_EXPORT_SYMBOL __attribute__ ((visibility("default"))) +#elif defined(_MSC_VER) +#define EVENT2_EXPORT_SYMBOL extern __declspec(dllexport) +#else +/* unknown compiler */ +#define EVENT2_EXPORT_SYMBOL +#endif + +#else + +#if defined(EVENT__NEED_DLLIMPORT) && defined(_MSC_VER) && !defined(EVENT_BUILDING_REGRESS_TEST) +#define EVENT2_EXPORT_SYMBOL extern __declspec(dllimport) +#else +#define EVENT2_EXPORT_SYMBOL +#endif + +#endif + +#endif /* EVENT2_VISIBILITY_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/evhttp.h b/contrib/ntp/sntp/libevent/include/evhttp.h new file mode 100644 index 000000000..549bc9b14 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/evhttp.h @@ -0,0 +1,45 @@ +/* + * Copyright 2000-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT1_EVHTTP_H_INCLUDED_ +#define EVENT1_EVHTTP_H_INCLUDED_ + +/** @file evhttp.h + + An http implementation subsystem for Libevent. + + The header is deprecated in Libevent 2.0 and later; please + use instead. Depending on what functionality you + need, you may also want to include more of the other + headers. + */ + +#include +#include +#include +#include + +#endif /* EVENT1_EVHTTP_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/evrpc.h b/contrib/ntp/sntp/libevent/include/evrpc.h new file mode 100644 index 000000000..7e986f7da --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/evrpc.h @@ -0,0 +1,45 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT1_EVRPC_H_INCLUDED_ +#define EVENT1_EVRPC_H_INCLUDED_ + +/** @file evrpc.h + + An RPC system for Libevent. + + The header is deprecated in Libevent 2.0 and later; please + use instead. Depending on what functionality you + need, you may also want to include more of the other + headers. + */ + +#include +#include +#include +#include + +#endif /* EVENT1_EVRPC_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/evutil.h b/contrib/ntp/sntp/libevent/include/evutil.h new file mode 100644 index 000000000..12c137d74 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/evutil.h @@ -0,0 +1,39 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef EVENT1_EVUTIL_H_INCLUDED_ +#define EVENT1_EVUTIL_H_INCLUDED_ + +/** @file evutil.h + + Utility and compatibility functions for Libevent. + + The header is deprecated in Libevent 2.0 and later; please + use instead. +*/ + +#include + +#endif /* EVENT1_EVUTIL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/include/include.am b/contrib/ntp/sntp/libevent/include/include.am new file mode 100644 index 000000000..9aad2dba4 --- /dev/null +++ b/contrib/ntp/sntp/libevent/include/include.am @@ -0,0 +1,46 @@ +# include/Makefile.am for libevent +# Copyright 2000-2007 Niels Provos +# Copyright 2007-2012 Niels Provos and Nick Mathewson +# +# See LICENSE for copying information. + +include_event2dir = $(includedir)/event2 + +EVENT2_EXPORT = \ + include/event2/buffer.h \ + include/event2/buffer_compat.h \ + include/event2/bufferevent.h \ + include/event2/bufferevent_compat.h \ + include/event2/bufferevent_ssl.h \ + include/event2/bufferevent_struct.h \ + include/event2/dns.h \ + include/event2/dns_compat.h \ + include/event2/dns_struct.h \ + include/event2/event.h \ + include/event2/event_compat.h \ + include/event2/event_struct.h \ + include/event2/http.h \ + include/event2/http_compat.h \ + include/event2/http_struct.h \ + include/event2/keyvalq_struct.h \ + include/event2/listener.h \ + include/event2/rpc.h \ + include/event2/rpc_compat.h \ + include/event2/rpc_struct.h \ + include/event2/tag.h \ + include/event2/tag_compat.h \ + include/event2/thread.h \ + include/event2/util.h \ + include/event2/visibility.h + +## Without the nobase_ prefixing, Automake would strip "include/event2/" from +## the source header filename to derive the installed header filename. +## With nobase_ the installed path is $(includedir)/include/event2/ev*.h. + +if INSTALL_LIBEVENT +include_event2_HEADERS = $(EVENT2_EXPORT) +nodist_include_event2_HEADERS = include/event2/event-config.h +else +noinst_HEADERS += $(EVENT2_EXPORT) +nodist_noinst_HEADERS = include/event2/event-config.h +endif diff --git a/contrib/ntp/sntp/libevent/iocp-internal.h b/contrib/ntp/sntp/libevent/iocp-internal.h new file mode 100644 index 000000000..93dbe2b1a --- /dev/null +++ b/contrib/ntp/sntp/libevent/iocp-internal.h @@ -0,0 +1,201 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef IOCP_INTERNAL_H_INCLUDED_ +#define IOCP_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +struct event_overlapped; +struct event_iocp_port; +struct evbuffer; +typedef void (*iocp_callback)(struct event_overlapped *, ev_uintptr_t, ev_ssize_t, int success); + +/* This whole file is actually win32 only. We wrap the structures in a win32 + * ifdef so that we can test-compile code that uses these interfaces on + * non-win32 platforms. */ +#ifdef _WIN32 + +/** + Internal use only. Wraps an OVERLAPPED that we're using for libevent + functionality. Whenever an event_iocp_port gets an event for a given + OVERLAPPED*, it upcasts the pointer to an event_overlapped, and calls the + iocp_callback function with the event_overlapped, the iocp key, and the + number of bytes transferred as arguments. + */ +struct event_overlapped { + OVERLAPPED overlapped; + iocp_callback cb; +}; + +/* Mingw's headers don't define LPFN_ACCEPTEX. */ + +typedef BOOL (WINAPI *AcceptExPtr)(SOCKET, SOCKET, PVOID, DWORD, DWORD, DWORD, LPDWORD, LPOVERLAPPED); +typedef BOOL (WINAPI *ConnectExPtr)(SOCKET, const struct sockaddr *, int, PVOID, DWORD, LPDWORD, LPOVERLAPPED); +typedef void (WINAPI *GetAcceptExSockaddrsPtr)(PVOID, DWORD, DWORD, DWORD, LPSOCKADDR *, LPINT, LPSOCKADDR *, LPINT); + +/** Internal use only. Holds pointers to functions that only some versions of + Windows provide. + */ +struct win32_extension_fns { + AcceptExPtr AcceptEx; + ConnectExPtr ConnectEx; + GetAcceptExSockaddrsPtr GetAcceptExSockaddrs; +}; + +/** + Internal use only. Stores a Windows IO Completion port, along with + related data. + */ +struct event_iocp_port { + /** The port itself */ + HANDLE port; + /* A lock to cover internal structures. */ + CRITICAL_SECTION lock; + /** Number of threads ever open on the port. */ + short n_threads; + /** True iff we're shutting down all the threads on this port */ + short shutdown; + /** How often the threads on this port check for shutdown and other + * conditions */ + long ms; + /* The threads that are waiting for events. */ + HANDLE *threads; + /** Number of threads currently open on this port. */ + short n_live_threads; + /** A semaphore to signal when we are done shutting down. */ + HANDLE *shutdownSemaphore; +}; + +const struct win32_extension_fns *event_get_win32_extension_fns_(void); +#else +/* Dummy definition so we can test-compile more things on unix. */ +struct event_overlapped { + iocp_callback cb; +}; +#endif + +/** Initialize the fields in an event_overlapped. + + @param overlapped The struct event_overlapped to initialize + @param cb The callback that should be invoked once the IO operation has + finished. + */ +void event_overlapped_init_(struct event_overlapped *, iocp_callback cb); + +/** Allocate and return a new evbuffer that supports overlapped IO on a given + socket. The socket must be associated with an IO completion port using + event_iocp_port_associate_. +*/ +struct evbuffer *evbuffer_overlapped_new_(evutil_socket_t fd); + +/** XXXX Document (nickm) */ +evutil_socket_t evbuffer_overlapped_get_fd_(struct evbuffer *buf); + +void evbuffer_overlapped_set_fd_(struct evbuffer *buf, evutil_socket_t fd); + +/** Start reading data onto the end of an overlapped evbuffer. + + An evbuffer can only have one read pending at a time. While the read + is in progress, no other data may be added to the end of the buffer. + The buffer must be created with event_overlapped_init_(). + evbuffer_commit_read_() must be called in the completion callback. + + @param buf The buffer to read onto + @param n The number of bytes to try to read. + @param ol Overlapped object with associated completion callback. + @return 0 on success, -1 on error. + */ +int evbuffer_launch_read_(struct evbuffer *buf, size_t n, struct event_overlapped *ol); + +/** Start writing data from the start of an evbuffer. + + An evbuffer can only have one write pending at a time. While the write is + in progress, no other data may be removed from the front of the buffer. + The buffer must be created with event_overlapped_init_(). + evbuffer_commit_write_() must be called in the completion callback. + + @param buf The buffer to read onto + @param n The number of bytes to try to read. + @param ol Overlapped object with associated completion callback. + @return 0 on success, -1 on error. + */ +int evbuffer_launch_write_(struct evbuffer *buf, ev_ssize_t n, struct event_overlapped *ol); + +/** XXX document */ +void evbuffer_commit_read_(struct evbuffer *, ev_ssize_t); +void evbuffer_commit_write_(struct evbuffer *, ev_ssize_t); + +/** Create an IOCP, and launch its worker threads. Internal use only. + + This interface is unstable, and will change. + */ +struct event_iocp_port *event_iocp_port_launch_(int n_cpus); + +/** Associate a file descriptor with an iocp, such that overlapped IO on the + fd will happen on one of the iocp's worker threads. +*/ +int event_iocp_port_associate_(struct event_iocp_port *port, evutil_socket_t fd, + ev_uintptr_t key); + +/** Tell all threads serving an iocp to stop. Wait for up to waitMsec for all + the threads to finish whatever they're doing. If waitMsec is -1, wait + as long as required. If all the threads are done, free the port and return + 0. Otherwise, return -1. If you get a -1 return value, it is safe to call + this function again. +*/ +int event_iocp_shutdown_(struct event_iocp_port *port, long waitMsec); + +/* FIXME document. */ +int event_iocp_activate_overlapped_(struct event_iocp_port *port, + struct event_overlapped *o, + ev_uintptr_t key, ev_uint32_t n_bytes); + +struct event_base; +/* FIXME document. */ +struct event_iocp_port *event_base_get_iocp_(struct event_base *base); + +/* FIXME document. */ +int event_base_start_iocp_(struct event_base *base, int n_cpus); +void event_base_stop_iocp_(struct event_base *base); + +/* FIXME document. */ +struct bufferevent *bufferevent_async_new_(struct event_base *base, + evutil_socket_t fd, int options); + +/* FIXME document. */ +void bufferevent_async_set_connected_(struct bufferevent *bev); +int bufferevent_async_can_connect_(struct bufferevent *bev); +int bufferevent_async_connect_(struct bufferevent *bev, evutil_socket_t fd, + const struct sockaddr *sa, int socklen); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/contrib/ntp/sntp/libevent/ipv6-internal.h b/contrib/ntp/sntp/libevent/ipv6-internal.h new file mode 100644 index 000000000..0c207377b --- /dev/null +++ b/contrib/ntp/sntp/libevent/ipv6-internal.h @@ -0,0 +1,83 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* Internal use only: Fake IPv6 structures and values on platforms that + * do not have them */ + +#ifndef IPV6_INTERNAL_H_INCLUDED_ +#define IPV6_INTERNAL_H_INCLUDED_ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif +#include "event2/util.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** @file ipv6-internal.h + * + * Replacement types and functions for platforms that don't support ipv6 + * properly. + */ + +#ifndef EVENT__HAVE_STRUCT_IN6_ADDR +struct in6_addr { + ev_uint8_t s6_addr[16]; +}; +#endif + +#ifndef EVENT__HAVE_SA_FAMILY_T +typedef int sa_family_t; +#endif + +#ifndef EVENT__HAVE_STRUCT_SOCKADDR_IN6 +struct sockaddr_in6 { + /* This will fail if we find a struct sockaddr that doesn't have + * sa_family as the first element. */ + sa_family_t sin6_family; + ev_uint16_t sin6_port; + struct in6_addr sin6_addr; +}; +#endif + +#ifndef AF_INET6 +#define AF_INET6 3333 +#endif +#ifndef PF_INET6 +#define PF_INET6 AF_INET6 +#endif + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/contrib/ntp/sntp/libevent/kqueue-internal.h b/contrib/ntp/sntp/libevent/kqueue-internal.h new file mode 100644 index 000000000..02c5a3606 --- /dev/null +++ b/contrib/ntp/sntp/libevent/kqueue-internal.h @@ -0,0 +1,39 @@ +/* + * Copyright (c) 2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef KQUEUE_INTERNAL_H_INCLUDED_ +#define KQUEUE_INTERNAL_H_INCLUDED_ + +/** Notification function, used to tell an event base to wake up from another + * thread. Only works when event_kq_add_notify_event_() has previously been + * called successfully on that base. */ +int event_kq_notify_base_(struct event_base *base); + +/** Prepare a kqueue-using event base to receive notifications via an internal + * EVFILT_USER event. Return 0 on sucess, -1 on failure. + */ +int event_kq_add_notify_event_(struct event_base *base); + +#endif diff --git a/contrib/ntp/sntp/libevent/kqueue.c b/contrib/ntp/sntp/libevent/kqueue.c new file mode 100644 index 000000000..a6578dfe1 --- /dev/null +++ b/contrib/ntp/sntp/libevent/kqueue.c @@ -0,0 +1,566 @@ +/* $OpenBSD: kqueue.c,v 1.5 2002/07/10 14:41:31 art Exp $ */ + +/* + * Copyright 2000-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_KQUEUE + +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#include +#include +#include +#include +#include +#include +#include +#ifdef EVENT__HAVE_INTTYPES_H +#include +#endif + +/* Some platforms apparently define the udata field of struct kevent as + * intptr_t, whereas others define it as void*. There doesn't seem to be an + * easy way to tell them apart via autoconf, so we need to use OS macros. */ +#if defined(EVENT__HAVE_INTTYPES_H) && !defined(__OpenBSD__) && !defined(__FreeBSD__) && !defined(__darwin__) && !defined(__APPLE__) +#define PTR_TO_UDATA(x) ((intptr_t)(x)) +#define INT_TO_UDATA(x) ((intptr_t)(x)) +#else +#define PTR_TO_UDATA(x) (x) +#define INT_TO_UDATA(x) ((void*)(x)) +#endif + +#include "event-internal.h" +#include "log-internal.h" +#include "evmap-internal.h" +#include "event2/thread.h" +#include "evthread-internal.h" +#include "changelist-internal.h" + +#include "kqueue-internal.h" + +#define NEVENT 64 + +struct kqop { + struct kevent *changes; + int changes_size; + + struct kevent *events; + int events_size; + int kq; + int notify_event_added; + pid_t pid; +}; + +static void kqop_free(struct kqop *kqop); + +static void *kq_init(struct event_base *); +static int kq_sig_add(struct event_base *, int, short, short, void *); +static int kq_sig_del(struct event_base *, int, short, short, void *); +static int kq_dispatch(struct event_base *, struct timeval *); +static void kq_dealloc(struct event_base *); + +const struct eventop kqops = { + "kqueue", + kq_init, + event_changelist_add_, + event_changelist_del_, + kq_dispatch, + kq_dealloc, + 1 /* need reinit */, + EV_FEATURE_ET|EV_FEATURE_O1|EV_FEATURE_FDS, + EVENT_CHANGELIST_FDINFO_SIZE +}; + +static const struct eventop kqsigops = { + "kqueue_signal", + NULL, + kq_sig_add, + kq_sig_del, + NULL, + NULL, + 1 /* need reinit */, + 0, + 0 +}; + +static void * +kq_init(struct event_base *base) +{ + int kq = -1; + struct kqop *kqueueop = NULL; + + if (!(kqueueop = mm_calloc(1, sizeof(struct kqop)))) + return (NULL); + +/* Initialize the kernel queue */ + + if ((kq = kqueue()) == -1) { + event_warn("kqueue"); + goto err; + } + + kqueueop->kq = kq; + + kqueueop->pid = getpid(); + + /* Initialize fields */ + kqueueop->changes = mm_calloc(NEVENT, sizeof(struct kevent)); + if (kqueueop->changes == NULL) + goto err; + kqueueop->events = mm_calloc(NEVENT, sizeof(struct kevent)); + if (kqueueop->events == NULL) + goto err; + kqueueop->events_size = kqueueop->changes_size = NEVENT; + + /* Check for Mac OS X kqueue bug. */ + memset(&kqueueop->changes[0], 0, sizeof kqueueop->changes[0]); + kqueueop->changes[0].ident = -1; + kqueueop->changes[0].filter = EVFILT_READ; + kqueueop->changes[0].flags = EV_ADD; + /* + * If kqueue works, then kevent will succeed, and it will + * stick an error in events[0]. If kqueue is broken, then + * kevent will fail. + */ + if (kevent(kq, + kqueueop->changes, 1, kqueueop->events, NEVENT, NULL) != 1 || + (int)kqueueop->events[0].ident != -1 || + kqueueop->events[0].flags != EV_ERROR) { + event_warn("%s: detected broken kqueue; not using.", __func__); + goto err; + } + + base->evsigsel = &kqsigops; + + return (kqueueop); +err: + if (kqueueop) + kqop_free(kqueueop); + + return (NULL); +} + +#define ADD_UDATA 0x30303 + +static void +kq_setup_kevent(struct kevent *out, evutil_socket_t fd, int filter, short change) +{ + memset(out, 0, sizeof(struct kevent)); + out->ident = fd; + out->filter = filter; + + if (change & EV_CHANGE_ADD) { + out->flags = EV_ADD; + /* We set a magic number here so that we can tell 'add' + * errors from 'del' errors. */ + out->udata = INT_TO_UDATA(ADD_UDATA); + if (change & EV_ET) + out->flags |= EV_CLEAR; +#ifdef NOTE_EOF + /* Make it behave like select() and poll() */ + if (filter == EVFILT_READ) + out->fflags = NOTE_EOF; +#endif + } else { + EVUTIL_ASSERT(change & EV_CHANGE_DEL); + out->flags = EV_DELETE; + } +} + +static int +kq_build_changes_list(const struct event_changelist *changelist, + struct kqop *kqop) +{ + int i; + int n_changes = 0; + + for (i = 0; i < changelist->n_changes; ++i) { + struct event_change *in_ch = &changelist->changes[i]; + struct kevent *out_ch; + if (n_changes >= kqop->changes_size - 1) { + int newsize = kqop->changes_size * 2; + struct kevent *newchanges; + + newchanges = mm_realloc(kqop->changes, + newsize * sizeof(struct kevent)); + if (newchanges == NULL) { + event_warn("%s: realloc", __func__); + return (-1); + } + kqop->changes = newchanges; + kqop->changes_size = newsize; + } + if (in_ch->read_change) { + out_ch = &kqop->changes[n_changes++]; + kq_setup_kevent(out_ch, in_ch->fd, EVFILT_READ, + in_ch->read_change); + } + if (in_ch->write_change) { + out_ch = &kqop->changes[n_changes++]; + kq_setup_kevent(out_ch, in_ch->fd, EVFILT_WRITE, + in_ch->write_change); + } + } + return n_changes; +} + +static int +kq_grow_events(struct kqop *kqop, size_t new_size) +{ + struct kevent *newresult; + + newresult = mm_realloc(kqop->events, + new_size * sizeof(struct kevent)); + + if (newresult) { + kqop->events = newresult; + kqop->events_size = new_size; + return 0; + } else { + return -1; + } +} + +static int +kq_dispatch(struct event_base *base, struct timeval *tv) +{ + struct kqop *kqop = base->evbase; + struct kevent *events = kqop->events; + struct kevent *changes; + struct timespec ts, *ts_p = NULL; + int i, n_changes, res; + + if (tv != NULL) { + TIMEVAL_TO_TIMESPEC(tv, &ts); + ts_p = &ts; + } + + /* Build "changes" from "base->changes" */ + EVUTIL_ASSERT(kqop->changes); + n_changes = kq_build_changes_list(&base->changelist, kqop); + if (n_changes < 0) + return -1; + + event_changelist_remove_all_(&base->changelist, base); + + /* steal the changes array in case some broken code tries to call + * dispatch twice at once. */ + changes = kqop->changes; + kqop->changes = NULL; + + /* Make sure that 'events' is at least as long as the list of changes: + * otherwise errors in the changes can get reported as a -1 return + * value from kevent() rather than as EV_ERROR events in the events + * array. + * + * (We could instead handle -1 return values from kevent() by + * retrying with a smaller changes array or a larger events array, + * but this approach seems less risky for now.) + */ + if (kqop->events_size < n_changes) { + int new_size = kqop->events_size; + do { + new_size *= 2; + } while (new_size < n_changes); + + kq_grow_events(kqop, new_size); + events = kqop->events; + } + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + res = kevent(kqop->kq, changes, n_changes, + events, kqop->events_size, ts_p); + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + EVUTIL_ASSERT(kqop->changes == NULL); + kqop->changes = changes; + + if (res == -1) { + if (errno != EINTR) { + event_warn("kevent"); + return (-1); + } + + return (0); + } + + event_debug(("%s: kevent reports %d", __func__, res)); + + for (i = 0; i < res; i++) { + int which = 0; + + if (events[i].flags & EV_ERROR) { + switch (events[i].data) { + + /* Can occur on delete if we are not currently + * watching any events on this fd. That can + * happen when the fd was closed and another + * file was opened with that fd. */ + case ENOENT: + /* Can occur for reasons not fully understood + * on FreeBSD. */ + case EINVAL: + continue; +#if defined(__FreeBSD__) && defined(ENOTCAPABLE) + /* + * This currently occurs if an FD is closed + * before the EV_DELETE makes it out via kevent(). + * The FreeBSD capabilities code sees the blank + * capability set and rejects the request to + * modify an event. + * + * To be strictly correct - when an FD is closed, + * all the registered events are also removed. + * Queuing EV_DELETE to a closed FD is wrong. + * The event(s) should just be deleted from + * the pending changelist. + */ + case ENOTCAPABLE: + continue; +#endif + + /* Can occur on a delete if the fd is closed. */ + case EBADF: + /* XXXX On NetBSD, we can also get EBADF if we + * try to add the write side of a pipe, but + * the read side has already been closed. + * Other BSDs call this situation 'EPIPE'. It + * would be good if we had a way to report + * this situation. */ + continue; + /* These two can occur on an add if the fd was one side + * of a pipe, and the other side was closed. */ + case EPERM: + case EPIPE: + /* Report read events, if we're listening for + * them, so that the user can learn about any + * add errors. (If the operation was a + * delete, then udata should be cleared.) */ + if (events[i].udata) { + /* The operation was an add: + * report the error as a read. */ + which |= EV_READ; + break; + } else { + /* The operation was a del: + * report nothing. */ + continue; + } + + /* Other errors shouldn't occur. */ + default: + errno = events[i].data; + return (-1); + } + } else if (events[i].filter == EVFILT_READ) { + which |= EV_READ; + } else if (events[i].filter == EVFILT_WRITE) { + which |= EV_WRITE; + } else if (events[i].filter == EVFILT_SIGNAL) { + which |= EV_SIGNAL; +#ifdef EVFILT_USER + } else if (events[i].filter == EVFILT_USER) { + base->is_notify_pending = 0; +#endif + } + + if (!which) + continue; + + if (events[i].filter == EVFILT_SIGNAL) { + evmap_signal_active_(base, events[i].ident, 1); + } else { + evmap_io_active_(base, events[i].ident, which | EV_ET); + } + } + + if (res == kqop->events_size) { + /* We used all the events space that we have. Maybe we should + make it bigger. */ + kq_grow_events(kqop, kqop->events_size * 2); + } + + return (0); +} + +static void +kqop_free(struct kqop *kqop) +{ + if (kqop->changes) + mm_free(kqop->changes); + if (kqop->events) + mm_free(kqop->events); + if (kqop->kq >= 0 && kqop->pid == getpid()) + close(kqop->kq); + memset(kqop, 0, sizeof(struct kqop)); + mm_free(kqop); +} + +static void +kq_dealloc(struct event_base *base) +{ + struct kqop *kqop = base->evbase; + evsig_dealloc_(base); + kqop_free(kqop); +} + +/* signal handling */ +static int +kq_sig_add(struct event_base *base, int nsignal, short old, short events, void *p) +{ + struct kqop *kqop = base->evbase; + struct kevent kev; + struct timespec timeout = { 0, 0 }; + (void)p; + + EVUTIL_ASSERT(nsignal >= 0 && nsignal < NSIG); + + memset(&kev, 0, sizeof(kev)); + kev.ident = nsignal; + kev.filter = EVFILT_SIGNAL; + kev.flags = EV_ADD; + + /* Be ready for the signal if it is sent any + * time between now and the next call to + * kq_dispatch. */ + if (kevent(kqop->kq, &kev, 1, NULL, 0, &timeout) == -1) + return (-1); + + /* We can set the handler for most signals to SIG_IGN and + * still have them reported to us in the queue. However, + * if the handler for SIGCHLD is SIG_IGN, the system reaps + * zombie processes for us, and we don't get any notification. + * This appears to be the only signal with this quirk. */ + if (evsig_set_handler_(base, nsignal, + nsignal == SIGCHLD ? SIG_DFL : SIG_IGN) == -1) + return (-1); + + return (0); +} + +static int +kq_sig_del(struct event_base *base, int nsignal, short old, short events, void *p) +{ + struct kqop *kqop = base->evbase; + struct kevent kev; + + struct timespec timeout = { 0, 0 }; + (void)p; + + EVUTIL_ASSERT(nsignal >= 0 && nsignal < NSIG); + + memset(&kev, 0, sizeof(kev)); + kev.ident = nsignal; + kev.filter = EVFILT_SIGNAL; + kev.flags = EV_DELETE; + + /* Because we insert signal events + * immediately, we need to delete them + * immediately, too */ + if (kevent(kqop->kq, &kev, 1, NULL, 0, &timeout) == -1) + return (-1); + + if (evsig_restore_handler_(base, nsignal) == -1) + return (-1); + + return (0); +} + + +/* OSX 10.6 and FreeBSD 8.1 add support for EVFILT_USER, which we can use + * to wake up the event loop from another thread. */ + +/* Magic number we use for our filter ID. */ +#define NOTIFY_IDENT 42 + +int +event_kq_add_notify_event_(struct event_base *base) +{ + struct kqop *kqop = base->evbase; +#if defined(EVFILT_USER) && defined(NOTE_TRIGGER) + struct kevent kev; + struct timespec timeout = { 0, 0 }; +#endif + + if (kqop->notify_event_added) + return 0; + +#if defined(EVFILT_USER) && defined(NOTE_TRIGGER) + memset(&kev, 0, sizeof(kev)); + kev.ident = NOTIFY_IDENT; + kev.filter = EVFILT_USER; + kev.flags = EV_ADD | EV_CLEAR; + + if (kevent(kqop->kq, &kev, 1, NULL, 0, &timeout) == -1) { + event_warn("kevent: adding EVFILT_USER event"); + return -1; + } + + kqop->notify_event_added = 1; + + return 0; +#else + return -1; +#endif +} + +int +event_kq_notify_base_(struct event_base *base) +{ + struct kqop *kqop = base->evbase; +#if defined(EVFILT_USER) && defined(NOTE_TRIGGER) + struct kevent kev; + struct timespec timeout = { 0, 0 }; +#endif + if (! kqop->notify_event_added) + return -1; + +#if defined(EVFILT_USER) && defined(NOTE_TRIGGER) + memset(&kev, 0, sizeof(kev)); + kev.ident = NOTIFY_IDENT; + kev.filter = EVFILT_USER; + kev.fflags = NOTE_TRIGGER; + + if (kevent(kqop->kq, &kev, 1, NULL, 0, &timeout) == -1) { + event_warn("kevent: triggering EVFILT_USER event"); + return -1; + } + + return 0; +#else + return -1; +#endif +} + +#endif /* EVENT__HAVE_KQUEUE */ diff --git a/contrib/ntp/sntp/libevent/libevent.pc.in b/contrib/ntp/sntp/libevent/libevent.pc.in new file mode 100644 index 000000000..7030884ee --- /dev/null +++ b/contrib/ntp/sntp/libevent/libevent.pc.in @@ -0,0 +1,16 @@ +#libevent pkg-config source file + +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ + +Name: libevent +Description: libevent is an asynchronous notification event loop library +Version: @VERSION@ +Requires: +Conflicts: +Libs: -L${libdir} -levent +Libs.private: @LIBS@ +Cflags: -I${includedir} + diff --git a/contrib/ntp/sntp/libevent/libevent_openssl.pc.in b/contrib/ntp/sntp/libevent/libevent_openssl.pc.in new file mode 100644 index 000000000..a65d1e066 --- /dev/null +++ b/contrib/ntp/sntp/libevent/libevent_openssl.pc.in @@ -0,0 +1,16 @@ +#libevent pkg-config source file + +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ + +Name: libevent_openssl +Description: libevent_openssl adds openssl-based TLS support to libevent +Version: @VERSION@ +Requires: libevent +Conflicts: +Libs: -L${libdir} -levent_openssl +Libs.private: @LIBS@ @OPENSSL_LIBS@ +Cflags: -I${includedir} @OPENSSL_INCS@ + diff --git a/contrib/ntp/sntp/libevent/libevent_pthreads.pc.in b/contrib/ntp/sntp/libevent/libevent_pthreads.pc.in new file mode 100644 index 000000000..9bc2392b3 --- /dev/null +++ b/contrib/ntp/sntp/libevent/libevent_pthreads.pc.in @@ -0,0 +1,16 @@ +#libevent pkg-config source file + +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ + +Name: libevent_pthreads +Description: libevent_pthreads adds pthreads-based threading support to libevent +Version: @VERSION@ +Requires: libevent +Conflicts: +Libs: -L${libdir} -levent_pthreads +Libs.private: @LIBS@ @PTHREAD_LIBS@ +Cflags: -I${includedir} @PTHREAD_CFLAGS@ + diff --git a/contrib/ntp/sntp/libevent/listener.c b/contrib/ntp/sntp/libevent/listener.c new file mode 100644 index 000000000..2af14e3a7 --- /dev/null +++ b/contrib/ntp/sntp/libevent/listener.c @@ -0,0 +1,889 @@ +/* + * Copyright (c) 2009-2012 Niels Provos, Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#ifdef _WIN32 +#ifndef _WIN32_WINNT +/* Minimum required for InitializeCriticalSectionAndSpinCount */ +#define _WIN32_WINNT 0x0403 +#endif +#include +#include +#include +#endif +#include +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif +#ifdef EVENT__HAVE_FCNTL_H +#include +#endif +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif + +#include "event2/listener.h" +#include "event2/util.h" +#include "event2/event.h" +#include "event2/event_struct.h" +#include "mm-internal.h" +#include "util-internal.h" +#include "log-internal.h" +#include "evthread-internal.h" +#ifdef _WIN32 +#include "iocp-internal.h" +#include "defer-internal.h" +#include "event-internal.h" +#endif + +struct evconnlistener_ops { + int (*enable)(struct evconnlistener *); + int (*disable)(struct evconnlistener *); + void (*destroy)(struct evconnlistener *); + void (*shutdown)(struct evconnlistener *); + evutil_socket_t (*getfd)(struct evconnlistener *); + struct event_base *(*getbase)(struct evconnlistener *); +}; + +struct evconnlistener { + const struct evconnlistener_ops *ops; + void *lock; + evconnlistener_cb cb; + evconnlistener_errorcb errorcb; + void *user_data; + unsigned flags; + short refcnt; + int accept4_flags; + unsigned enabled : 1; +}; + +struct evconnlistener_event { + struct evconnlistener base; + struct event listener; +}; + +#ifdef _WIN32 +struct evconnlistener_iocp { + struct evconnlistener base; + evutil_socket_t fd; + struct event_base *event_base; + struct event_iocp_port *port; + short n_accepting; + unsigned shutting_down : 1; + unsigned event_added : 1; + struct accepting_socket **accepting; +}; +#endif + +#define LOCK(listener) EVLOCK_LOCK((listener)->lock, 0) +#define UNLOCK(listener) EVLOCK_UNLOCK((listener)->lock, 0) + +struct evconnlistener * +evconnlistener_new_async(struct event_base *base, + evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, + evutil_socket_t fd); /* XXXX export this? */ + +static int event_listener_enable(struct evconnlistener *); +static int event_listener_disable(struct evconnlistener *); +static void event_listener_destroy(struct evconnlistener *); +static evutil_socket_t event_listener_getfd(struct evconnlistener *); +static struct event_base *event_listener_getbase(struct evconnlistener *); + +#if 0 +static void +listener_incref_and_lock(struct evconnlistener *listener) +{ + LOCK(listener); + ++listener->refcnt; +} +#endif + +static int +listener_decref_and_unlock(struct evconnlistener *listener) +{ + int refcnt = --listener->refcnt; + if (refcnt == 0) { + listener->ops->destroy(listener); + UNLOCK(listener); + EVTHREAD_FREE_LOCK(listener->lock, EVTHREAD_LOCKTYPE_RECURSIVE); + mm_free(listener); + return 1; + } else { + UNLOCK(listener); + return 0; + } +} + +static const struct evconnlistener_ops evconnlistener_event_ops = { + event_listener_enable, + event_listener_disable, + event_listener_destroy, + NULL, /* shutdown */ + event_listener_getfd, + event_listener_getbase +}; + +static void listener_read_cb(evutil_socket_t, short, void *); + +struct evconnlistener * +evconnlistener_new(struct event_base *base, + evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, + evutil_socket_t fd) +{ + struct evconnlistener_event *lev; + +#ifdef _WIN32 + if (base && event_base_get_iocp_(base)) { + const struct win32_extension_fns *ext = + event_get_win32_extension_fns_(); + if (ext->AcceptEx && ext->GetAcceptExSockaddrs) + return evconnlistener_new_async(base, cb, ptr, flags, + backlog, fd); + } +#endif + + if (backlog > 0) { + if (listen(fd, backlog) < 0) + return NULL; + } else if (backlog < 0) { + if (listen(fd, 128) < 0) + return NULL; + } + + lev = mm_calloc(1, sizeof(struct evconnlistener_event)); + if (!lev) + return NULL; + + lev->base.ops = &evconnlistener_event_ops; + lev->base.cb = cb; + lev->base.user_data = ptr; + lev->base.flags = flags; + lev->base.refcnt = 1; + + lev->base.accept4_flags = 0; + if (!(flags & LEV_OPT_LEAVE_SOCKETS_BLOCKING)) + lev->base.accept4_flags |= EVUTIL_SOCK_NONBLOCK; + if (flags & LEV_OPT_CLOSE_ON_EXEC) + lev->base.accept4_flags |= EVUTIL_SOCK_CLOEXEC; + + if (flags & LEV_OPT_THREADSAFE) { + EVTHREAD_ALLOC_LOCK(lev->base.lock, EVTHREAD_LOCKTYPE_RECURSIVE); + } + + event_assign(&lev->listener, base, fd, EV_READ|EV_PERSIST, + listener_read_cb, lev); + + if (!(flags & LEV_OPT_DISABLED)) + evconnlistener_enable(&lev->base); + + return &lev->base; +} + +struct evconnlistener * +evconnlistener_new_bind(struct event_base *base, evconnlistener_cb cb, + void *ptr, unsigned flags, int backlog, const struct sockaddr *sa, + int socklen) +{ + struct evconnlistener *listener; + evutil_socket_t fd; + int on = 1; + int family = sa ? sa->sa_family : AF_UNSPEC; + int socktype = SOCK_STREAM | EVUTIL_SOCK_NONBLOCK; + + if (backlog == 0) + return NULL; + + if (flags & LEV_OPT_CLOSE_ON_EXEC) + socktype |= EVUTIL_SOCK_CLOEXEC; + + fd = evutil_socket_(family, socktype, 0); + if (fd == -1) + return NULL; + + if (setsockopt(fd, SOL_SOCKET, SO_KEEPALIVE, (void*)&on, sizeof(on))<0) + goto err; + + if (flags & LEV_OPT_REUSEABLE) { + if (evutil_make_listen_socket_reuseable(fd) < 0) + goto err; + } + + if (flags & LEV_OPT_REUSEABLE_PORT) { + if (evutil_make_listen_socket_reuseable_port(fd) < 0) + goto err; + } + + if (flags & LEV_OPT_DEFERRED_ACCEPT) { + if (evutil_make_tcp_listen_socket_deferred(fd) < 0) + goto err; + } + + if (sa) { + if (bind(fd, sa, socklen)<0) + goto err; + } + + listener = evconnlistener_new(base, cb, ptr, flags, backlog, fd); + if (!listener) + goto err; + + return listener; +err: + evutil_closesocket(fd); + return NULL; +} + +void +evconnlistener_free(struct evconnlistener *lev) +{ + LOCK(lev); + lev->cb = NULL; + lev->errorcb = NULL; + if (lev->ops->shutdown) + lev->ops->shutdown(lev); + listener_decref_and_unlock(lev); +} + +static void +event_listener_destroy(struct evconnlistener *lev) +{ + struct evconnlistener_event *lev_e = + EVUTIL_UPCAST(lev, struct evconnlistener_event, base); + + event_del(&lev_e->listener); + if (lev->flags & LEV_OPT_CLOSE_ON_FREE) + evutil_closesocket(event_get_fd(&lev_e->listener)); + event_debug_unassign(&lev_e->listener); +} + +int +evconnlistener_enable(struct evconnlistener *lev) +{ + int r; + LOCK(lev); + lev->enabled = 1; + if (lev->cb) + r = lev->ops->enable(lev); + else + r = 0; + UNLOCK(lev); + return r; +} + +int +evconnlistener_disable(struct evconnlistener *lev) +{ + int r; + LOCK(lev); + lev->enabled = 0; + r = lev->ops->disable(lev); + UNLOCK(lev); + return r; +} + +static int +event_listener_enable(struct evconnlistener *lev) +{ + struct evconnlistener_event *lev_e = + EVUTIL_UPCAST(lev, struct evconnlistener_event, base); + return event_add(&lev_e->listener, NULL); +} + +static int +event_listener_disable(struct evconnlistener *lev) +{ + struct evconnlistener_event *lev_e = + EVUTIL_UPCAST(lev, struct evconnlistener_event, base); + return event_del(&lev_e->listener); +} + +evutil_socket_t +evconnlistener_get_fd(struct evconnlistener *lev) +{ + evutil_socket_t fd; + LOCK(lev); + fd = lev->ops->getfd(lev); + UNLOCK(lev); + return fd; +} + +static evutil_socket_t +event_listener_getfd(struct evconnlistener *lev) +{ + struct evconnlistener_event *lev_e = + EVUTIL_UPCAST(lev, struct evconnlistener_event, base); + return event_get_fd(&lev_e->listener); +} + +struct event_base * +evconnlistener_get_base(struct evconnlistener *lev) +{ + struct event_base *base; + LOCK(lev); + base = lev->ops->getbase(lev); + UNLOCK(lev); + return base; +} + +static struct event_base * +event_listener_getbase(struct evconnlistener *lev) +{ + struct evconnlistener_event *lev_e = + EVUTIL_UPCAST(lev, struct evconnlistener_event, base); + return event_get_base(&lev_e->listener); +} + +void +evconnlistener_set_cb(struct evconnlistener *lev, + evconnlistener_cb cb, void *arg) +{ + int enable = 0; + LOCK(lev); + if (lev->enabled && !lev->cb) + enable = 1; + lev->cb = cb; + lev->user_data = arg; + if (enable) + evconnlistener_enable(lev); + UNLOCK(lev); +} + +void +evconnlistener_set_error_cb(struct evconnlistener *lev, + evconnlistener_errorcb errorcb) +{ + LOCK(lev); + lev->errorcb = errorcb; + UNLOCK(lev); +} + +static void +listener_read_cb(evutil_socket_t fd, short what, void *p) +{ + struct evconnlistener *lev = p; + int err; + evconnlistener_cb cb; + evconnlistener_errorcb errorcb; + void *user_data; + LOCK(lev); + while (1) { + struct sockaddr_storage ss; + ev_socklen_t socklen = sizeof(ss); + evutil_socket_t new_fd = evutil_accept4_(fd, (struct sockaddr*)&ss, &socklen, lev->accept4_flags); + if (new_fd < 0) + break; + if (socklen == 0) { + /* This can happen with some older linux kernels in + * response to nmap. */ + evutil_closesocket(new_fd); + continue; + } + + if (lev->cb == NULL) { + evutil_closesocket(new_fd); + UNLOCK(lev); + return; + } + ++lev->refcnt; + cb = lev->cb; + user_data = lev->user_data; + UNLOCK(lev); + cb(lev, new_fd, (struct sockaddr*)&ss, (int)socklen, + user_data); + LOCK(lev); + if (lev->refcnt == 1) { + int freed = listener_decref_and_unlock(lev); + EVUTIL_ASSERT(freed); + + evutil_closesocket(new_fd); + return; + } + --lev->refcnt; + } + err = evutil_socket_geterror(fd); + if (EVUTIL_ERR_ACCEPT_RETRIABLE(err)) { + UNLOCK(lev); + return; + } + if (lev->errorcb != NULL) { + ++lev->refcnt; + errorcb = lev->errorcb; + user_data = lev->user_data; + UNLOCK(lev); + errorcb(lev, user_data); + LOCK(lev); + listener_decref_and_unlock(lev); + } else { + event_sock_warn(fd, "Error from accept() call"); + } +} + +#ifdef _WIN32 +struct accepting_socket { + CRITICAL_SECTION lock; + struct event_overlapped overlapped; + SOCKET s; + int error; + struct event_callback deferred; + struct evconnlistener_iocp *lev; + ev_uint8_t buflen; + ev_uint8_t family; + unsigned free_on_cb:1; + char addrbuf[1]; +}; + +static void accepted_socket_cb(struct event_overlapped *o, ev_uintptr_t key, + ev_ssize_t n, int ok); +static void accepted_socket_invoke_user_cb(struct event_callback *cb, void *arg); + +static void +iocp_listener_event_add(struct evconnlistener_iocp *lev) +{ + if (lev->event_added) + return; + + lev->event_added = 1; + event_base_add_virtual_(lev->event_base); +} + +static void +iocp_listener_event_del(struct evconnlistener_iocp *lev) +{ + if (!lev->event_added) + return; + + lev->event_added = 0; + event_base_del_virtual_(lev->event_base); +} + +static struct accepting_socket * +new_accepting_socket(struct evconnlistener_iocp *lev, int family) +{ + struct accepting_socket *res; + int addrlen; + int buflen; + + if (family == AF_INET) + addrlen = sizeof(struct sockaddr_in); + else if (family == AF_INET6) + addrlen = sizeof(struct sockaddr_in6); + else + return NULL; + buflen = (addrlen+16)*2; + + res = mm_calloc(1,sizeof(struct accepting_socket)-1+buflen); + if (!res) + return NULL; + + event_overlapped_init_(&res->overlapped, accepted_socket_cb); + res->s = INVALID_SOCKET; + res->lev = lev; + res->buflen = buflen; + res->family = family; + + event_deferred_cb_init_(&res->deferred, + event_base_get_npriorities(lev->event_base) / 2, + accepted_socket_invoke_user_cb, res); + + InitializeCriticalSectionAndSpinCount(&res->lock, 1000); + + return res; +} + +static void +free_and_unlock_accepting_socket(struct accepting_socket *as) +{ + /* requires lock. */ + if (as->s != INVALID_SOCKET) + closesocket(as->s); + + LeaveCriticalSection(&as->lock); + DeleteCriticalSection(&as->lock); + mm_free(as); +} + +static int +start_accepting(struct accepting_socket *as) +{ + /* requires lock */ + const struct win32_extension_fns *ext = event_get_win32_extension_fns_(); + DWORD pending = 0; + SOCKET s = socket(as->family, SOCK_STREAM, 0); + int error = 0; + + if (!as->lev->base.enabled) + return 0; + + if (s == INVALID_SOCKET) { + error = WSAGetLastError(); + goto report_err; + } + + /* XXXX It turns out we need to do this again later. Does this call + * have any effect? */ + setsockopt(s, SOL_SOCKET, SO_UPDATE_ACCEPT_CONTEXT, + (char *)&as->lev->fd, sizeof(&as->lev->fd)); + + if (!(as->lev->base.flags & LEV_OPT_LEAVE_SOCKETS_BLOCKING)) + evutil_make_socket_nonblocking(s); + + if (event_iocp_port_associate_(as->lev->port, s, 1) < 0) { + closesocket(s); + return -1; + } + + as->s = s; + + if (ext->AcceptEx(as->lev->fd, s, as->addrbuf, 0, + as->buflen/2, as->buflen/2, &pending, &as->overlapped.overlapped)) + { + /* Immediate success! */ + accepted_socket_cb(&as->overlapped, 1, 0, 1); + } else { + error = WSAGetLastError(); + if (error != ERROR_IO_PENDING) { + goto report_err; + } + } + + return 0; + +report_err: + as->error = error; + event_deferred_cb_schedule_( + as->lev->event_base, + &as->deferred); + return 0; +} + +static void +stop_accepting(struct accepting_socket *as) +{ + /* requires lock. */ + SOCKET s = as->s; + as->s = INVALID_SOCKET; + closesocket(s); +} + +static void +accepted_socket_invoke_user_cb(struct event_callback *dcb, void *arg) +{ + struct accepting_socket *as = arg; + + struct sockaddr *sa_local=NULL, *sa_remote=NULL; + int socklen_local=0, socklen_remote=0; + const struct win32_extension_fns *ext = event_get_win32_extension_fns_(); + struct evconnlistener *lev = &as->lev->base; + evutil_socket_t sock=-1; + void *data; + evconnlistener_cb cb=NULL; + evconnlistener_errorcb errorcb=NULL; + int error; + + EVUTIL_ASSERT(ext->GetAcceptExSockaddrs); + + LOCK(lev); + EnterCriticalSection(&as->lock); + if (as->free_on_cb) { + free_and_unlock_accepting_socket(as); + listener_decref_and_unlock(lev); + return; + } + + ++lev->refcnt; + + error = as->error; + if (error) { + as->error = 0; + errorcb = lev->errorcb; + } else { + ext->GetAcceptExSockaddrs( + as->addrbuf, 0, as->buflen/2, as->buflen/2, + &sa_local, &socklen_local, &sa_remote, + &socklen_remote); + sock = as->s; + cb = lev->cb; + as->s = INVALID_SOCKET; + + /* We need to call this so getsockname, getpeername, and + * shutdown work correctly on the accepted socket. */ + /* XXXX handle error? */ + setsockopt(sock, SOL_SOCKET, SO_UPDATE_ACCEPT_CONTEXT, + (char *)&as->lev->fd, sizeof(&as->lev->fd)); + } + data = lev->user_data; + + LeaveCriticalSection(&as->lock); + UNLOCK(lev); + + if (errorcb) { + WSASetLastError(error); + errorcb(lev, data); + } else if (cb) { + cb(lev, sock, sa_remote, socklen_remote, data); + } + + LOCK(lev); + if (listener_decref_and_unlock(lev)) + return; + + EnterCriticalSection(&as->lock); + start_accepting(as); + LeaveCriticalSection(&as->lock); +} + +static void +accepted_socket_cb(struct event_overlapped *o, ev_uintptr_t key, ev_ssize_t n, int ok) +{ + struct accepting_socket *as = + EVUTIL_UPCAST(o, struct accepting_socket, overlapped); + + LOCK(&as->lev->base); + EnterCriticalSection(&as->lock); + if (ok) { + /* XXXX Don't do this if some EV_MT flag is set. */ + event_deferred_cb_schedule_( + as->lev->event_base, + &as->deferred); + LeaveCriticalSection(&as->lock); + } else if (as->free_on_cb) { + struct evconnlistener *lev = &as->lev->base; + free_and_unlock_accepting_socket(as); + listener_decref_and_unlock(lev); + return; + } else if (as->s == INVALID_SOCKET) { + /* This is okay; we were disabled by iocp_listener_disable. */ + LeaveCriticalSection(&as->lock); + } else { + /* Some error on accept that we couldn't actually handle. */ + BOOL ok; + DWORD transfer = 0, flags=0; + event_sock_warn(as->s, "Unexpected error on AcceptEx"); + ok = WSAGetOverlappedResult(as->s, &o->overlapped, + &transfer, FALSE, &flags); + if (ok) { + /* well, that was confusing! */ + as->error = 1; + } else { + as->error = WSAGetLastError(); + } + event_deferred_cb_schedule_( + as->lev->event_base, + &as->deferred); + LeaveCriticalSection(&as->lock); + } + UNLOCK(&as->lev->base); +} + +static int +iocp_listener_enable(struct evconnlistener *lev) +{ + int i; + struct evconnlistener_iocp *lev_iocp = + EVUTIL_UPCAST(lev, struct evconnlistener_iocp, base); + + LOCK(lev); + iocp_listener_event_add(lev_iocp); + for (i = 0; i < lev_iocp->n_accepting; ++i) { + struct accepting_socket *as = lev_iocp->accepting[i]; + if (!as) + continue; + EnterCriticalSection(&as->lock); + if (!as->free_on_cb && as->s == INVALID_SOCKET) + start_accepting(as); + LeaveCriticalSection(&as->lock); + } + UNLOCK(lev); + return 0; +} + +static int +iocp_listener_disable_impl(struct evconnlistener *lev, int shutdown) +{ + int i; + struct evconnlistener_iocp *lev_iocp = + EVUTIL_UPCAST(lev, struct evconnlistener_iocp, base); + + LOCK(lev); + iocp_listener_event_del(lev_iocp); + for (i = 0; i < lev_iocp->n_accepting; ++i) { + struct accepting_socket *as = lev_iocp->accepting[i]; + if (!as) + continue; + EnterCriticalSection(&as->lock); + if (!as->free_on_cb && as->s != INVALID_SOCKET) { + if (shutdown) + as->free_on_cb = 1; + stop_accepting(as); + } + LeaveCriticalSection(&as->lock); + } + + if (shutdown && lev->flags & LEV_OPT_CLOSE_ON_FREE) + evutil_closesocket(lev_iocp->fd); + + UNLOCK(lev); + return 0; +} + +static int +iocp_listener_disable(struct evconnlistener *lev) +{ + return iocp_listener_disable_impl(lev,0); +} + +static void +iocp_listener_destroy(struct evconnlistener *lev) +{ + struct evconnlistener_iocp *lev_iocp = + EVUTIL_UPCAST(lev, struct evconnlistener_iocp, base); + + if (! lev_iocp->shutting_down) { + lev_iocp->shutting_down = 1; + iocp_listener_disable_impl(lev,1); + } + +} + +static evutil_socket_t +iocp_listener_getfd(struct evconnlistener *lev) +{ + struct evconnlistener_iocp *lev_iocp = + EVUTIL_UPCAST(lev, struct evconnlistener_iocp, base); + return lev_iocp->fd; +} +static struct event_base * +iocp_listener_getbase(struct evconnlistener *lev) +{ + struct evconnlistener_iocp *lev_iocp = + EVUTIL_UPCAST(lev, struct evconnlistener_iocp, base); + return lev_iocp->event_base; +} + +static const struct evconnlistener_ops evconnlistener_iocp_ops = { + iocp_listener_enable, + iocp_listener_disable, + iocp_listener_destroy, + iocp_listener_destroy, /* shutdown */ + iocp_listener_getfd, + iocp_listener_getbase +}; + +/* XXX define some way to override this. */ +#define N_SOCKETS_PER_LISTENER 4 + +struct evconnlistener * +evconnlistener_new_async(struct event_base *base, + evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, + evutil_socket_t fd) +{ + struct sockaddr_storage ss; + int socklen = sizeof(ss); + struct evconnlistener_iocp *lev; + int i; + + flags |= LEV_OPT_THREADSAFE; + + if (!base || !event_base_get_iocp_(base)) + goto err; + + /* XXXX duplicate code */ + if (backlog > 0) { + if (listen(fd, backlog) < 0) + goto err; + } else if (backlog < 0) { + if (listen(fd, 128) < 0) + goto err; + } + if (getsockname(fd, (struct sockaddr*)&ss, &socklen)) { + event_sock_warn(fd, "getsockname"); + goto err; + } + lev = mm_calloc(1, sizeof(struct evconnlistener_iocp)); + if (!lev) { + event_warn("calloc"); + goto err; + } + lev->base.ops = &evconnlistener_iocp_ops; + lev->base.cb = cb; + lev->base.user_data = ptr; + lev->base.flags = flags; + lev->base.refcnt = 1; + lev->base.enabled = 1; + + lev->port = event_base_get_iocp_(base); + lev->fd = fd; + lev->event_base = base; + + + if (event_iocp_port_associate_(lev->port, fd, 1) < 0) + goto err_free_lev; + + EVTHREAD_ALLOC_LOCK(lev->base.lock, EVTHREAD_LOCKTYPE_RECURSIVE); + + lev->n_accepting = N_SOCKETS_PER_LISTENER; + lev->accepting = mm_calloc(lev->n_accepting, + sizeof(struct accepting_socket *)); + if (!lev->accepting) { + event_warn("calloc"); + goto err_delete_lock; + } + for (i = 0; i < lev->n_accepting; ++i) { + lev->accepting[i] = new_accepting_socket(lev, ss.ss_family); + if (!lev->accepting[i]) { + event_warnx("Couldn't create accepting socket"); + goto err_free_accepting; + } + if (cb && start_accepting(lev->accepting[i]) < 0) { + event_warnx("Couldn't start accepting on socket"); + EnterCriticalSection(&lev->accepting[i]->lock); + free_and_unlock_accepting_socket(lev->accepting[i]); + goto err_free_accepting; + } + ++lev->base.refcnt; + } + + iocp_listener_event_add(lev); + + return &lev->base; + +err_free_accepting: + mm_free(lev->accepting); + /* XXXX free the other elements. */ +err_delete_lock: + EVTHREAD_FREE_LOCK(lev->base.lock, EVTHREAD_LOCKTYPE_RECURSIVE); +err_free_lev: + mm_free(lev); +err: + /* Don't close the fd, it is caller's responsibility. */ + return NULL; +} + +#endif diff --git a/contrib/ntp/sntp/libevent/log-internal.h b/contrib/ntp/sntp/libevent/log-internal.h new file mode 100644 index 000000000..330478a9e --- /dev/null +++ b/contrib/ntp/sntp/libevent/log-internal.h @@ -0,0 +1,83 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef LOG_INTERNAL_H_INCLUDED_ +#define LOG_INTERNAL_H_INCLUDED_ + +#include "event2/util.h" + +#ifdef __GNUC__ +#define EV_CHECK_FMT(a,b) __attribute__((format(printf, a, b))) +#define EV_NORETURN __attribute__((noreturn)) +#else +#define EV_CHECK_FMT(a,b) +#define EV_NORETURN +#endif + +#define EVENT_ERR_ABORT_ ((int)0xdeaddead) + +#define USE_GLOBAL_FOR_DEBUG_LOGGING + +#if !defined(EVENT__DISABLE_DEBUG_MODE) || defined(USE_DEBUG) +#define EVENT_DEBUG_LOGGING_ENABLED +#endif + +#ifdef EVENT_DEBUG_LOGGING_ENABLED +#ifdef USE_GLOBAL_FOR_DEBUG_LOGGING +extern ev_uint32_t event_debug_logging_mask_; +#define event_debug_get_logging_mask_() (event_debug_logging_mask_) +#else +ev_uint32_t event_debug_get_logging_mask_(void); +#endif +#else +#define event_debug_get_logging_mask_() (0) +#endif + +void event_err(int eval, const char *fmt, ...) EV_CHECK_FMT(2,3) EV_NORETURN; +void event_warn(const char *fmt, ...) EV_CHECK_FMT(1,2); +void event_sock_err(int eval, evutil_socket_t sock, const char *fmt, ...) EV_CHECK_FMT(3,4) EV_NORETURN; +void event_sock_warn(evutil_socket_t sock, const char *fmt, ...) EV_CHECK_FMT(2,3); +void event_errx(int eval, const char *fmt, ...) EV_CHECK_FMT(2,3) EV_NORETURN; +void event_warnx(const char *fmt, ...) EV_CHECK_FMT(1,2); +void event_msgx(const char *fmt, ...) EV_CHECK_FMT(1,2); +void event_debugx_(const char *fmt, ...) EV_CHECK_FMT(1,2); + +void event_logv_(int severity, const char *errstr, const char *fmt, va_list ap) + EV_CHECK_FMT(3,0); + +#ifdef EVENT_DEBUG_LOGGING_ENABLED +#define event_debug(x) do { \ + if (event_debug_get_logging_mask_()) { \ + event_debugx_ x; \ + } \ + } while (0) +#else +#define event_debug(x) ((void)0) +#endif + +#undef EV_CHECK_FMT + +#endif diff --git a/contrib/ntp/sntp/libevent/log.c b/contrib/ntp/sntp/libevent/log.c new file mode 100644 index 000000000..e8ae9fdc3 --- /dev/null +++ b/contrib/ntp/sntp/libevent/log.c @@ -0,0 +1,253 @@ +/* $OpenBSD: err.c,v 1.2 2002/06/25 15:50:15 mickey Exp $ */ + +/* + * log.c + * + * Based on err.c, which was adapted from OpenBSD libc *err* *warn* code. + * + * Copyright (c) 2005-2012 Niels Provos and Nick Mathewson + * + * Copyright (c) 2000 Dug Song + * + * Copyright (c) 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#include +#define WIN32_LEAN_AND_MEAN +#include +#undef WIN32_LEAN_AND_MEAN +#endif +#include +#include +#include +#include +#include +#include +#include "event2/event.h" +#include "event2/util.h" + +#include "log-internal.h" + +static void event_log(int severity, const char *msg); +static void event_exit(int errcode) EV_NORETURN; + +static event_fatal_cb fatal_fn = NULL; + +#ifdef EVENT_DEBUG_LOGGING_ENABLED +#ifdef USE_DEBUG +#define DEFAULT_MASK EVENT_DBG_ALL +#else +#define DEFAULT_MASK 0 +#endif + +#ifdef USE_GLOBAL_FOR_DEBUG_LOGGING +ev_uint32_t event_debug_logging_mask_ = DEFAULT_MASK; +#else +static ev_uint32_t event_debug_logging_mask_ = DEFAULT_MASK; +ev_uint32_t +event_debug_get_logging_mask_(void) +{ + return event_debug_logging_mask_; +} +#endif +#endif /* EVENT_DEBUG_LOGGING_ENABLED */ + +void +event_enable_debug_logging(ev_uint32_t which) +{ +#ifdef EVENT_DEBUG_LOGGING_ENABLED + event_debug_logging_mask_ = which; +#endif +} + +void +event_set_fatal_callback(event_fatal_cb cb) +{ + fatal_fn = cb; +} + +static void +event_exit(int errcode) +{ + if (fatal_fn) { + fatal_fn(errcode); + exit(errcode); /* should never be reached */ + } else if (errcode == EVENT_ERR_ABORT_) + abort(); + else + exit(errcode); +} + +void +event_err(int eval, const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + event_logv_(EVENT_LOG_ERR, strerror(errno), fmt, ap); + va_end(ap); + event_exit(eval); +} + +void +event_warn(const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + event_logv_(EVENT_LOG_WARN, strerror(errno), fmt, ap); + va_end(ap); +} + +void +event_sock_err(int eval, evutil_socket_t sock, const char *fmt, ...) +{ + va_list ap; + int err = evutil_socket_geterror(sock); + + va_start(ap, fmt); + event_logv_(EVENT_LOG_ERR, evutil_socket_error_to_string(err), fmt, ap); + va_end(ap); + event_exit(eval); +} + +void +event_sock_warn(evutil_socket_t sock, const char *fmt, ...) +{ + va_list ap; + int err = evutil_socket_geterror(sock); + + va_start(ap, fmt); + event_logv_(EVENT_LOG_WARN, evutil_socket_error_to_string(err), fmt, ap); + va_end(ap); +} + +void +event_errx(int eval, const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + event_logv_(EVENT_LOG_ERR, NULL, fmt, ap); + va_end(ap); + event_exit(eval); +} + +void +event_warnx(const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + event_logv_(EVENT_LOG_WARN, NULL, fmt, ap); + va_end(ap); +} + +void +event_msgx(const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + event_logv_(EVENT_LOG_MSG, NULL, fmt, ap); + va_end(ap); +} + +void +event_debugx_(const char *fmt, ...) +{ + va_list ap; + + va_start(ap, fmt); + event_logv_(EVENT_LOG_DEBUG, NULL, fmt, ap); + va_end(ap); +} + +void +event_logv_(int severity, const char *errstr, const char *fmt, va_list ap) +{ + char buf[1024]; + size_t len; + + if (severity == EVENT_LOG_DEBUG && !event_debug_get_logging_mask_()) + return; + + if (fmt != NULL) + evutil_vsnprintf(buf, sizeof(buf), fmt, ap); + else + buf[0] = '\0'; + + if (errstr) { + len = strlen(buf); + if (len < sizeof(buf) - 3) { + evutil_snprintf(buf + len, sizeof(buf) - len, ": %s", errstr); + } + } + + event_log(severity, buf); +} + +static event_log_cb log_fn = NULL; + +void +event_set_log_callback(event_log_cb cb) +{ + log_fn = cb; +} + +static void +event_log(int severity, const char *msg) +{ + if (log_fn) + log_fn(severity, msg); + else { + const char *severity_str; + switch (severity) { + case EVENT_LOG_DEBUG: + severity_str = "debug"; + break; + case EVENT_LOG_MSG: + severity_str = "msg"; + break; + case EVENT_LOG_WARN: + severity_str = "warn"; + break; + case EVENT_LOG_ERR: + severity_str = "err"; + break; + default: + severity_str = "???"; + break; + } + (void)fprintf(stderr, "[%s] %s\n", severity_str, msg); + } +} diff --git a/contrib/ntp/sntp/libevent/m4/ac_backport_259_ssizet.m4 b/contrib/ntp/sntp/libevent/m4/ac_backport_259_ssizet.m4 new file mode 100644 index 000000000..75fde386c --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/ac_backport_259_ssizet.m4 @@ -0,0 +1,3 @@ +AN_IDENTIFIER([ssize_t], [AC_TYPE_SSIZE_T]) +AC_DEFUN([AC_TYPE_SSIZE_T], [AC_CHECK_TYPE(ssize_t, int)]) + diff --git a/contrib/ntp/sntp/libevent/m4/acx_pthread.m4 b/contrib/ntp/sntp/libevent/m4/acx_pthread.m4 new file mode 100644 index 000000000..d2b116945 --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/acx_pthread.m4 @@ -0,0 +1,279 @@ +##### http://autoconf-archive.cryp.to/acx_pthread.html +# +# SYNOPSIS +# +# ACX_PTHREAD([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]) +# +# DESCRIPTION +# +# This macro figures out how to build C programs using POSIX threads. +# It sets the PTHREAD_LIBS output variable to the threads library and +# linker flags, and the PTHREAD_CFLAGS output variable to any special +# C compiler flags that are needed. (The user can also force certain +# compiler flags/libs to be tested by setting these environment +# variables.) +# +# Also sets PTHREAD_CC to any special C compiler that is needed for +# multi-threaded programs (defaults to the value of CC otherwise). +# (This is necessary on AIX to use the special cc_r compiler alias.) +# +# NOTE: You are assumed to not only compile your program with these +# flags, but also link it with them as well. e.g. you should link +# with $PTHREAD_CC $CFLAGS $PTHREAD_CFLAGS $LDFLAGS ... $PTHREAD_LIBS +# $LIBS +# +# If you are only building threads programs, you may wish to use +# these variables in your default LIBS, CFLAGS, and CC: +# +# LIBS="$PTHREAD_LIBS $LIBS" +# CFLAGS="$CFLAGS $PTHREAD_CFLAGS" +# CC="$PTHREAD_CC" +# +# In addition, if the PTHREAD_CREATE_JOINABLE thread-attribute +# constant has a nonstandard name, defines PTHREAD_CREATE_JOINABLE to +# that name (e.g. PTHREAD_CREATE_UNDETACHED on AIX). +# +# ACTION-IF-FOUND is a list of shell commands to run if a threads +# library is found, and ACTION-IF-NOT-FOUND is a list of commands to +# run it if it is not found. If ACTION-IF-FOUND is not specified, the +# default action will define HAVE_PTHREAD. +# +# Please let the authors know if this macro fails on any platform, or +# if you have any other suggestions or comments. This macro was based +# on work by SGJ on autoconf scripts for FFTW (http://www.fftw.org/) +# (with help from M. Frigo), as well as ac_pthread and hb_pthread +# macros posted by Alejandro Forero Cuervo to the autoconf macro +# repository. We are also grateful for the helpful feedback of +# numerous users. +# +# LAST MODIFICATION +# +# 2007-07-29 +# +# COPYLEFT +# +# Copyright (c) 2007 Steven G. Johnson +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see +# . +# +# As a special exception, the respective Autoconf Macro's copyright +# owner gives unlimited permission to copy, distribute and modify the +# configure scripts that are the output of Autoconf when processing +# the Macro. You need not follow the terms of the GNU General Public +# License when using or distributing such scripts, even though +# portions of the text of the Macro appear in them. The GNU General +# Public License (GPL) does govern all other use of the material that +# constitutes the Autoconf Macro. +# +# This special exception to the GPL applies to versions of the +# Autoconf Macro released by the Autoconf Macro Archive. When you +# make and distribute a modified version of the Autoconf Macro, you +# may extend this special exception to the GPL to apply to your +# modified version as well. + +AC_DEFUN([ACX_PTHREAD], [ +AC_REQUIRE([AC_CANONICAL_HOST]) +AC_LANG_SAVE +AC_LANG_C +acx_pthread_ok=no + +# We used to check for pthread.h first, but this fails if pthread.h +# requires special compiler flags (e.g. on True64 or Sequent). +# It gets checked for in the link test anyway. + +# First of all, check if the user has set any of the PTHREAD_LIBS, +# etcetera environment variables, and if threads linking works using +# them: +if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then + save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + save_LIBS="$LIBS" + LIBS="$PTHREAD_LIBS $LIBS" + AC_MSG_CHECKING([for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS]) + AC_TRY_LINK_FUNC(pthread_join, acx_pthread_ok=yes) + AC_MSG_RESULT($acx_pthread_ok) + if test x"$acx_pthread_ok" = xno; then + PTHREAD_LIBS="" + PTHREAD_CFLAGS="" + fi + LIBS="$save_LIBS" + CFLAGS="$save_CFLAGS" +fi + +# We must check for the threads library under a number of different +# names; the ordering is very important because some systems +# (e.g. DEC) have both -lpthread and -lpthreads, where one of the +# libraries is broken (non-POSIX). + +# Create a list of thread flags to try. Items starting with a "-" are +# C compiler flags, and other items are library names, except for "none" +# which indicates that we try without any flags at all, and "pthread-config" +# which is a program returning the flags for the Pth emulation library. + +acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config" + +# The ordering *is* (sometimes) important. Some notes on the +# individual items follow: + +# pthreads: AIX (must check this before -lpthread) +# none: in case threads are in libc; should be tried before -Kthread and +# other compiler flags to prevent continual compiler warnings +# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h) +# -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able) +# lthread: LinuxThreads port on FreeBSD (also preferred to -pthread) +# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads) +# -pthreads: Solaris/gcc +# -mthreads: Mingw32/gcc, Lynx/gcc +# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it +# doesn't hurt to check since this sometimes defines pthreads too; +# also defines -D_REENTRANT) +# ... -mt is also the pthreads flag for HP/aCC +# pthread: Linux, etcetera +# --thread-safe: KAI C++ +# pthread-config: use pthread-config program (for GNU Pth library) + +case "${host_cpu}-${host_os}" in + *solaris*) + + # On Solaris (at least, for some versions), libc contains stubbed + # (non-functional) versions of the pthreads routines, so link-based + # tests will erroneously succeed. (We need to link with -pthreads/-mt/ + # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather + # a function called by this macro, so we could check for that, but + # who knows whether they'll stub that too in a future libc.) So, + # we'll just look for -pthreads and -lpthread first: + + acx_pthread_flags="-pthreads pthread -mt -pthread $acx_pthread_flags" + ;; +esac + +if test x"$acx_pthread_ok" = xno; then +for flag in $acx_pthread_flags; do + + case $flag in + none) + AC_MSG_CHECKING([whether pthreads work without any flags]) + ;; + + -*) + AC_MSG_CHECKING([whether pthreads work with $flag]) + PTHREAD_CFLAGS="$flag" + ;; + + pthread-config) + AC_CHECK_PROG(acx_pthread_config, pthread-config, yes, no) + if test x"$acx_pthread_config" = xno; then continue; fi + PTHREAD_CFLAGS="`pthread-config --cflags`" + PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`" + ;; + + *) + AC_MSG_CHECKING([for the pthreads library -l$flag]) + PTHREAD_LIBS="-l$flag" + ;; + esac + + save_LIBS="$LIBS" + save_CFLAGS="$CFLAGS" + LIBS="$PTHREAD_LIBS $LIBS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + + # Check for various functions. We must include pthread.h, + # since some functions may be macros. (On the Sequent, we + # need a special flag -Kthread to make this header compile.) + # We check for pthread_join because it is in -lpthread on IRIX + # while pthread_create is in libc. We check for pthread_attr_init + # due to DEC craziness with -lpthreads. We check for + # pthread_cleanup_push because it is one of the few pthread + # functions on Solaris that doesn't have a non-functional libc stub. + # We try pthread_create on general principles. + AC_TRY_LINK([#include ], + [pthread_t th; pthread_join(th, 0); + pthread_attr_init(0); pthread_cleanup_push(0, 0); + pthread_create(0,0,0,0); pthread_cleanup_pop(0); ], + [acx_pthread_ok=yes]) + + LIBS="$save_LIBS" + CFLAGS="$save_CFLAGS" + + AC_MSG_RESULT($acx_pthread_ok) + if test "x$acx_pthread_ok" = xyes; then + break; + fi + + PTHREAD_LIBS="" + PTHREAD_CFLAGS="" +done +fi + +# Various other checks: +if test "x$acx_pthread_ok" = xyes; then + save_LIBS="$LIBS" + LIBS="$PTHREAD_LIBS $LIBS" + save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + + # Detect AIX lossage: JOINABLE attribute is called UNDETACHED. + AC_MSG_CHECKING([for joinable pthread attribute]) + attr_name=unknown + for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do + AC_TRY_LINK([#include ], [int attr=$attr; return attr;], + [attr_name=$attr; break]) + done + AC_MSG_RESULT($attr_name) + if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then + AC_DEFINE_UNQUOTED(PTHREAD_CREATE_JOINABLE, $attr_name, + [Define to necessary symbol if this constant + uses a non-standard name on your system.]) + fi + + AC_MSG_CHECKING([if more special flags are required for pthreads]) + flag=no + case "${host_cpu}-${host_os}" in + *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";; + *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";; + esac + AC_MSG_RESULT(${flag}) + if test "x$flag" != xno; then + PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS" + fi + + LIBS="$save_LIBS" + CFLAGS="$save_CFLAGS" + + # More AIX lossage: must compile with xlc_r or cc_r + if test x"$GCC" != xyes; then + AC_CHECK_PROGS(PTHREAD_CC, xlc_r cc_r, ${CC}) + else + PTHREAD_CC=$CC + fi +else + PTHREAD_CC="$CC" +fi + +AC_SUBST(PTHREAD_LIBS) +AC_SUBST(PTHREAD_CFLAGS) +AC_SUBST(PTHREAD_CC) + +# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND: +if test x"$acx_pthread_ok" = xyes; then + ifelse([$1],,AC_DEFINE(HAVE_PTHREAD,1,[Define if you have POSIX threads libraries and header files.]),[$1]) + : +else + acx_pthread_ok=no + $2 +fi +AC_LANG_RESTORE +])dnl ACX_PTHREAD diff --git a/contrib/ntp/sntp/libevent/m4/libevent_openssl.m4 b/contrib/ntp/sntp/libevent/m4/libevent_openssl.m4 new file mode 100644 index 000000000..3cb064a0b --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/libevent_openssl.m4 @@ -0,0 +1,47 @@ +dnl ###################################################################### +dnl OpenSSL support +AC_DEFUN([LIBEVENT_OPENSSL], [ +AC_REQUIRE([NTP_PKG_CONFIG])dnl + +case "$enable_openssl" in + yes) + have_openssl=no + case "$PKG_CONFIG" in + '') + ;; + *) + OPENSSL_LIBS=`$PKG_CONFIG --libs openssl 2>/dev/null` + case "$OPENSSL_LIBS" in + '') ;; + *) OPENSSL_LIBS="$OPENSSL_LIBS $EV_LIB_GDI $EV_LIB_WS32 $OPENSSL_LIBADD" + have_openssl=yes + ;; + esac + OPENSSL_INCS=`$PKG_CONFIG --cflags openssl 2>/dev/null` + ;; + esac + case "$have_openssl" in + yes) ;; + *) + save_LIBS="$LIBS" + LIBS="" + OPENSSL_LIBS="" + AC_SEARCH_LIBS([SSL_new], [ssl], + [have_openssl=yes + OPENSSL_LIBS="$LIBS -lcrypto $EV_LIB_GDI $EV_LIB_WS32 $OPENSSL_LIBADD"], + [have_openssl=no], + [-lcrypto $EV_LIB_GDI $EV_LIB_WS32 $OPENSSL_LIBADD]) + LIBS="$save_LIBS" + ;; + esac + AC_SUBST(OPENSSL_INCS) + AC_SUBST(OPENSSL_LIBS) + case "$have_openssl" in + yes) AC_DEFINE(HAVE_OPENSSL, 1, [Define if the system has openssl]) ;; + esac + ;; +esac + +# check if we have and should use openssl +AM_CONDITIONAL(OPENSSL, [test "$enable_openssl" != "no" && test "$have_openssl" = "yes"]) +]) diff --git a/contrib/ntp/sntp/libevent/m4/libtool.m4 b/contrib/ntp/sntp/libevent/m4/libtool.m4 new file mode 100644 index 000000000..d8125842f --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/libtool.m4 @@ -0,0 +1,7831 @@ +# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +m4_define([_LT_COPYING], [dnl +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is part of GNU Libtool. +# +# GNU Libtool is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Libtool; see the file COPYING. If not, a copy +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or +# obtained by writing to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +]) + +# serial 57 LT_INIT + + +# LT_PREREQ(VERSION) +# ------------------ +# Complain and exit if this libtool version is less that VERSION. +m4_defun([LT_PREREQ], +[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, + [m4_default([$3], + [m4_fatal([Libtool version $1 or higher is required], + 63)])], + [$2])]) + + +# _LT_CHECK_BUILDDIR +# ------------------ +# Complain if the absolute build directory name contains unusual characters +m4_defun([_LT_CHECK_BUILDDIR], +[case `pwd` in + *\ * | *\ *) + AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; +esac +]) + + +# LT_INIT([OPTIONS]) +# ------------------ +AC_DEFUN([LT_INIT], +[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT +AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +AC_BEFORE([$0], [LT_LANG])dnl +AC_BEFORE([$0], [LT_OUTPUT])dnl +AC_BEFORE([$0], [LTDL_INIT])dnl +m4_require([_LT_CHECK_BUILDDIR])dnl + +dnl Autoconf doesn't catch unexpanded LT_ macros by default: +m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl +m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl +dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 +dnl unless we require an AC_DEFUNed macro: +AC_REQUIRE([LTOPTIONS_VERSION])dnl +AC_REQUIRE([LTSUGAR_VERSION])dnl +AC_REQUIRE([LTVERSION_VERSION])dnl +AC_REQUIRE([LTOBSOLETE_VERSION])dnl +m4_require([_LT_PROG_LTMAIN])dnl + +_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) + +dnl Parse OPTIONS +_LT_SET_OPTIONS([$0], [$1]) + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ltmain" + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' +AC_SUBST(LIBTOOL)dnl + +_LT_SETUP + +# Only expand once: +m4_define([LT_INIT]) +])# LT_INIT + +# Old names: +AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) +AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PROG_LIBTOOL], []) +dnl AC_DEFUN([AM_PROG_LIBTOOL], []) + + +# _LT_CC_BASENAME(CC) +# ------------------- +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +m4_defun([_LT_CC_BASENAME], +[for cc_temp in $1""; do + case $cc_temp in + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +]) + + +# _LT_FILEUTILS_DEFAULTS +# ---------------------- +# It is okay to use these file commands and assume they have been set +# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. +m4_defun([_LT_FILEUTILS_DEFAULTS], +[: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} +])# _LT_FILEUTILS_DEFAULTS + + +# _LT_SETUP +# --------- +m4_defun([_LT_SETUP], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl + +_LT_DECL([], [host_alias], [0], [The host system])dnl +_LT_DECL([], [host], [0])dnl +_LT_DECL([], [host_os], [0])dnl +dnl +_LT_DECL([], [build_alias], [0], [The build system])dnl +_LT_DECL([], [build], [0])dnl +_LT_DECL([], [build_os], [0])dnl +dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +dnl +AC_REQUIRE([AC_PROG_LN_S])dnl +test -z "$LN_S" && LN_S="ln -s" +_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl +dnl +AC_REQUIRE([LT_CMD_MAX_LEN])dnl +_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl +_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl +dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl +m4_require([_LT_CMD_RELOAD])dnl +m4_require([_LT_CHECK_MAGIC_METHOD])dnl +m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl +m4_require([_LT_CMD_OLD_ARCHIVE])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_WITH_SYSROOT])dnl + +_LT_CONFIG_LIBTOOL_INIT([ +# See if we are running on zsh, and set the options which allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi +]) +if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST +fi + +_LT_CHECK_OBJDIR + +m4_require([_LT_TAG_COMPILER])dnl + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld="$lt_cv_prog_gnu_ld" + +old_CC="$CC" +old_CFLAGS="$CFLAGS" + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +_LT_CC_BASENAME([$compiler]) + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + _LT_PATH_MAGIC + fi + ;; +esac + +# Use C for the default configuration in the libtool script +LT_SUPPORTED_TAG([CC]) +_LT_LANG_C_CONFIG +_LT_LANG_DEFAULT_CONFIG +_LT_CONFIG_COMMANDS +])# _LT_SETUP + + +# _LT_PREPARE_SED_QUOTE_VARS +# -------------------------- +# Define a few sed substitution that help us do robust quoting. +m4_defun([_LT_PREPARE_SED_QUOTE_VARS], +[# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\([["`\\]]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' +]) + +# _LT_PROG_LTMAIN +# --------------- +# Note that this code is called both from `configure', and `config.status' +# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, +# `config.status' has no value for ac_aux_dir unless we are using Automake, +# so we pass a copy along to make sure it has a sensible value anyway. +m4_defun([_LT_PROG_LTMAIN], +[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl +_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) +ltmain="$ac_aux_dir/ltmain.sh" +])# _LT_PROG_LTMAIN + + +## ------------------------------------- ## +## Accumulate code for creating libtool. ## +## ------------------------------------- ## + +# So that we can recreate a full libtool script including additional +# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS +# in macros and then make a single call at the end using the `libtool' +# label. + + +# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) +# ---------------------------------------- +# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL_INIT], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_INIT], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_INIT]) + + +# _LT_CONFIG_LIBTOOL([COMMANDS]) +# ------------------------------ +# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) + + +# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) +# ----------------------------------------------------- +m4_defun([_LT_CONFIG_SAVE_COMMANDS], +[_LT_CONFIG_LIBTOOL([$1]) +_LT_CONFIG_LIBTOOL_INIT([$2]) +]) + + +# _LT_FORMAT_COMMENT([COMMENT]) +# ----------------------------- +# Add leading comment marks to the start of each line, and a trailing +# full-stop to the whole comment if one is not present already. +m4_define([_LT_FORMAT_COMMENT], +[m4_ifval([$1], [ +m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], + [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) +)]) + + + +## ------------------------ ## +## FIXME: Eliminate VARNAME ## +## ------------------------ ## + + +# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) +# ------------------------------------------------------------------- +# CONFIGNAME is the name given to the value in the libtool script. +# VARNAME is the (base) name used in the configure script. +# VALUE may be 0, 1 or 2 for a computed quote escaped value based on +# VARNAME. Any other value will be used directly. +m4_define([_LT_DECL], +[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], + [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], + [m4_ifval([$1], [$1], [$2])]) + lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) + m4_ifval([$4], + [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) + lt_dict_add_subkey([lt_decl_dict], [$2], + [tagged?], [m4_ifval([$5], [yes], [no])])]) +]) + + +# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) +# -------------------------------------------------------- +m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) + + +# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_tag_varnames], +[_lt_decl_filter([tagged?], [yes], $@)]) + + +# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) +# --------------------------------------------------------- +m4_define([_lt_decl_filter], +[m4_case([$#], + [0], [m4_fatal([$0: too few arguments: $#])], + [1], [m4_fatal([$0: too few arguments: $#: $1])], + [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], + [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], + [lt_dict_filter([lt_decl_dict], $@)])[]dnl +]) + + +# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) +# -------------------------------------------------- +m4_define([lt_decl_quote_varnames], +[_lt_decl_filter([value], [1], $@)]) + + +# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_dquote_varnames], +[_lt_decl_filter([value], [2], $@)]) + + +# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_varnames_tagged], +[m4_assert([$# <= 2])dnl +_$0(m4_quote(m4_default([$1], [[, ]])), + m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), + m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) +m4_define([_lt_decl_varnames_tagged], +[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) + + +# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_all_varnames], +[_$0(m4_quote(m4_default([$1], [[, ]])), + m4_if([$2], [], + m4_quote(lt_decl_varnames), + m4_quote(m4_shift($@))))[]dnl +]) +m4_define([_lt_decl_all_varnames], +[lt_join($@, lt_decl_varnames_tagged([$1], + lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl +]) + + +# _LT_CONFIG_STATUS_DECLARE([VARNAME]) +# ------------------------------------ +# Quote a variable value, and forward it to `config.status' so that its +# declaration there will have the same value as in `configure'. VARNAME +# must have a single quote delimited value for this to work. +m4_define([_LT_CONFIG_STATUS_DECLARE], +[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) + + +# _LT_CONFIG_STATUS_DECLARATIONS +# ------------------------------ +# We delimit libtool config variables with single quotes, so when +# we write them to config.status, we have to be sure to quote all +# embedded single quotes properly. In configure, this macro expands +# each variable declared with _LT_DECL (and _LT_TAGDECL) into: +# +# ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' +m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], +[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), + [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAGS +# ---------------- +# Output comment and list of tags supported by the script +m4_defun([_LT_LIBTOOL_TAGS], +[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl +available_tags="_LT_TAGS"dnl +]) + + +# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) +# ----------------------------------- +# Extract the dictionary values for VARNAME (optionally with TAG) and +# expand to a commented shell variable setting: +# +# # Some comment about what VAR is for. +# visible_name=$lt_internal_name +m4_define([_LT_LIBTOOL_DECLARE], +[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], + [description])))[]dnl +m4_pushdef([_libtool_name], + m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl +m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), + [0], [_libtool_name=[$]$1], + [1], [_libtool_name=$lt_[]$1], + [2], [_libtool_name=$lt_[]$1], + [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl +m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl +]) + + +# _LT_LIBTOOL_CONFIG_VARS +# ----------------------- +# Produce commented declarations of non-tagged libtool config variables +# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' +# script. Tagged libtool config variables (even for the LIBTOOL CONFIG +# section) are produced by _LT_LIBTOOL_TAG_VARS. +m4_defun([_LT_LIBTOOL_CONFIG_VARS], +[m4_foreach([_lt_var], + m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAG_VARS(TAG) +# ------------------------- +m4_define([_LT_LIBTOOL_TAG_VARS], +[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) + + +# _LT_TAGVAR(VARNAME, [TAGNAME]) +# ------------------------------ +m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) + + +# _LT_CONFIG_COMMANDS +# ------------------- +# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of +# variables for single and double quote escaping we saved from calls +# to _LT_DECL, we can put quote escaped variables declarations +# into `config.status', and then the shell code to quote escape them in +# for loops in `config.status'. Finally, any additional code accumulated +# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. +m4_defun([_LT_CONFIG_COMMANDS], +[AC_PROVIDE_IFELSE([LT_OUTPUT], + dnl If the libtool generation code has been placed in $CONFIG_LT, + dnl instead of duplicating it all over again into config.status, + dnl then we will have config.status run $CONFIG_LT later, so it + dnl needs to know what name is stored there: + [AC_CONFIG_COMMANDS([libtool], + [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], + dnl If the libtool generation code is destined for config.status, + dnl expand the accumulated commands and init code now: + [AC_CONFIG_COMMANDS([libtool], + [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) +])#_LT_CONFIG_COMMANDS + + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], +[ + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +_LT_CONFIG_STATUS_DECLARATIONS +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$[]1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_quote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_dquote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +_LT_OUTPUT_LIBTOOL_INIT +]) + +# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) +# ------------------------------------ +# Generate a child script FILE with all initialization necessary to +# reuse the environment learned by the parent script, and make the +# file executable. If COMMENT is supplied, it is inserted after the +# `#!' sequence but before initialization text begins. After this +# macro, additional text can be appended to FILE to form the body of +# the child script. The macro ends with non-zero status if the +# file could not be fully written (such as if the disk is full). +m4_ifdef([AS_INIT_GENERATED], +[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], +[m4_defun([_LT_GENERATED_FILE_INIT], +[m4_require([AS_PREPARE])]dnl +[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl +[lt_write_fail=0 +cat >$1 <<_ASEOF || lt_write_fail=1 +#! $SHELL +# Generated by $as_me. +$2 +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$1 <<\_ASEOF || lt_write_fail=1 +AS_SHELL_SANITIZE +_AS_PREPARE +exec AS_MESSAGE_FD>&1 +_ASEOF +test $lt_write_fail = 0 && chmod +x $1[]dnl +m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT + +# LT_OUTPUT +# --------- +# This macro allows early generation of the libtool script (before +# AC_OUTPUT is called), incase it is used in configure for compilation +# tests. +AC_DEFUN([LT_OUTPUT], +[: ${CONFIG_LT=./config.lt} +AC_MSG_NOTICE([creating $CONFIG_LT]) +_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], +[# Run this file to recreate a libtool stub with the current configuration.]) + +cat >>"$CONFIG_LT" <<\_LTEOF +lt_cl_silent=false +exec AS_MESSAGE_LOG_FD>>config.log +{ + echo + AS_BOX([Running $as_me.]) +} >&AS_MESSAGE_LOG_FD + +lt_cl_help="\ +\`$as_me' creates a local libtool stub from the current configuration, +for use in further configure time tests before the real libtool is +generated. + +Usage: $[0] [[OPTIONS]] + + -h, --help print this help, then exit + -V, --version print version number, then exit + -q, --quiet do not print progress messages + -d, --debug don't remove temporary files + +Report bugs to ." + +lt_cl_version="\ +m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl +m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) +configured by $[0], generated by m4_PACKAGE_STRING. + +Copyright (C) 2010 Free Software Foundation, Inc. +This config.lt script is free software; the Free Software Foundation +gives unlimited permision to copy, distribute and modify it." + +while test $[#] != 0 +do + case $[1] in + --version | --v* | -V ) + echo "$lt_cl_version"; exit 0 ;; + --help | --h* | -h ) + echo "$lt_cl_help"; exit 0 ;; + --debug | --d* | -d ) + debug=: ;; + --quiet | --q* | --silent | --s* | -q ) + lt_cl_silent=: ;; + + -*) AC_MSG_ERROR([unrecognized option: $[1] +Try \`$[0] --help' for more information.]) ;; + + *) AC_MSG_ERROR([unrecognized argument: $[1] +Try \`$[0] --help' for more information.]) ;; + esac + shift +done + +if $lt_cl_silent; then + exec AS_MESSAGE_FD>/dev/null +fi +_LTEOF + +cat >>"$CONFIG_LT" <<_LTEOF +_LT_OUTPUT_LIBTOOL_COMMANDS_INIT +_LTEOF + +cat >>"$CONFIG_LT" <<\_LTEOF +AC_MSG_NOTICE([creating $ofile]) +_LT_OUTPUT_LIBTOOL_COMMANDS +AS_EXIT(0) +_LTEOF +chmod +x "$CONFIG_LT" + +# configure is writing to config.log, but config.lt does its own redirection, +# appending to config.log, which fails on DOS, as config.log is still kept +# open by configure. Here we exec the FD to /dev/null, effectively closing +# config.log, so it can be properly (re)opened and appended to by config.lt. +lt_cl_success=: +test "$silent" = yes && + lt_config_lt_args="$lt_config_lt_args --quiet" +exec AS_MESSAGE_LOG_FD>/dev/null +$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false +exec AS_MESSAGE_LOG_FD>>config.log +$lt_cl_success || AS_EXIT(1) +])# LT_OUTPUT + + +# _LT_CONFIG(TAG) +# --------------- +# If TAG is the built-in tag, create an initial libtool script with a +# default configuration from the untagged config vars. Otherwise add code +# to config.status for appending the configuration named by TAG from the +# matching tagged config vars. +m4_defun([_LT_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_CONFIG_SAVE_COMMANDS([ + m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl + m4_if(_LT_TAG, [C], [ + # See if we are running on zsh, and set the options which allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + + cfgfile="${ofile}T" + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL + +# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +_LT_COPYING +_LT_LIBTOOL_TAGS + +# ### BEGIN LIBTOOL CONFIG +_LT_LIBTOOL_CONFIG_VARS +_LT_LIBTOOL_TAG_VARS +# ### END LIBTOOL CONFIG + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + _LT_PROG_LTMAIN + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + _LT_PROG_REPLACE_SHELLFNS + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" +], +[cat <<_LT_EOF >> "$ofile" + +dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded +dnl in a comment (ie after a #). +# ### BEGIN LIBTOOL TAG CONFIG: $1 +_LT_LIBTOOL_TAG_VARS(_LT_TAG) +# ### END LIBTOOL TAG CONFIG: $1 +_LT_EOF +])dnl /m4_if +], +[m4_if([$1], [], [ + PACKAGE='$PACKAGE' + VERSION='$VERSION' + TIMESTAMP='$TIMESTAMP' + RM='$RM' + ofile='$ofile'], []) +])dnl /_LT_CONFIG_SAVE_COMMANDS +])# _LT_CONFIG + + +# LT_SUPPORTED_TAG(TAG) +# --------------------- +# Trace this macro to discover what tags are supported by the libtool +# --tag option, using: +# autoconf --trace 'LT_SUPPORTED_TAG:$1' +AC_DEFUN([LT_SUPPORTED_TAG], []) + + +# C support is built-in for now +m4_define([_LT_LANG_C_enabled], []) +m4_define([_LT_TAGS], []) + + +# LT_LANG(LANG) +# ------------- +# Enable libtool support for the given language if not already enabled. +AC_DEFUN([LT_LANG], +[AC_BEFORE([$0], [LT_OUTPUT])dnl +m4_case([$1], + [C], [_LT_LANG(C)], + [C++], [_LT_LANG(CXX)], + [Java], [_LT_LANG(GCJ)], + [Fortran 77], [_LT_LANG(F77)], + [Fortran], [_LT_LANG(FC)], + [Windows Resource], [_LT_LANG(RC)], + [m4_ifdef([_LT_LANG_]$1[_CONFIG], + [_LT_LANG($1)], + [m4_fatal([$0: unsupported language: "$1"])])])dnl +])# LT_LANG + + +# _LT_LANG(LANGNAME) +# ------------------ +m4_defun([_LT_LANG], +[m4_ifdef([_LT_LANG_]$1[_enabled], [], + [LT_SUPPORTED_TAG([$1])dnl + m4_append([_LT_TAGS], [$1 ])dnl + m4_define([_LT_LANG_]$1[_enabled], [])dnl + _LT_LANG_$1_CONFIG($1)])dnl +])# _LT_LANG + + +# _LT_LANG_DEFAULT_CONFIG +# ----------------------- +m4_defun([_LT_LANG_DEFAULT_CONFIG], +[AC_PROVIDE_IFELSE([AC_PROG_CXX], + [LT_LANG(CXX)], + [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) + +AC_PROVIDE_IFELSE([AC_PROG_F77], + [LT_LANG(F77)], + [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) + +AC_PROVIDE_IFELSE([AC_PROG_FC], + [LT_LANG(FC)], + [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) + +dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal +dnl pulling things in needlessly. +AC_PROVIDE_IFELSE([AC_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([LT_PROG_GCJ], + [LT_LANG(GCJ)], + [m4_ifdef([AC_PROG_GCJ], + [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([A][M_PROG_GCJ], + [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([LT_PROG_GCJ], + [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) + +AC_PROVIDE_IFELSE([LT_PROG_RC], + [LT_LANG(RC)], + [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) +])# _LT_LANG_DEFAULT_CONFIG + +# Obsolete macros: +AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) +AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) +AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) +AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) +AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_CXX], []) +dnl AC_DEFUN([AC_LIBTOOL_F77], []) +dnl AC_DEFUN([AC_LIBTOOL_FC], []) +dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) +dnl AC_DEFUN([AC_LIBTOOL_RC], []) + + +# _LT_TAG_COMPILER +# ---------------- +m4_defun([_LT_TAG_COMPILER], +[AC_REQUIRE([AC_PROG_CC])dnl + +_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl +_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl +_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl +_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC +])# _LT_TAG_COMPILER + + +# _LT_COMPILER_BOILERPLATE +# ------------------------ +# Check for compiler boilerplate output or warnings with +# the simple compiler test code. +m4_defun([_LT_COMPILER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* +])# _LT_COMPILER_BOILERPLATE + + +# _LT_LINKER_BOILERPLATE +# ---------------------- +# Check for linker boilerplate output or warnings with +# the simple link test code. +m4_defun([_LT_LINKER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* +])# _LT_LINKER_BOILERPLATE + +# _LT_REQUIRED_DARWIN_CHECKS +# ------------------------- +m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ + case $host_os in + rhapsody* | darwin*) + AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) + AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) + AC_CHECK_TOOL([LIPO], [lipo], [:]) + AC_CHECK_TOOL([OTOOL], [otool], [:]) + AC_CHECK_TOOL([OTOOL64], [otool64], [:]) + _LT_DECL([], [DSYMUTIL], [1], + [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) + _LT_DECL([], [NMEDIT], [1], + [Tool to change global to local symbols on Mac OS X]) + _LT_DECL([], [LIPO], [1], + [Tool to manipulate fat objects and archives on Mac OS X]) + _LT_DECL([], [OTOOL], [1], + [ldd/readelf like tool for Mach-O binaries on Mac OS X]) + _LT_DECL([], [OTOOL64], [1], + [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) + + AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], + [lt_cv_apple_cc_single_mod=no + if test -z "${LT_MULTI_MODULE}"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi]) + AC_CACHE_CHECK([for -exported_symbols_list linker flag], + [lt_cv_ld_exported_symbols_list], + [lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [lt_cv_ld_exported_symbols_list=yes], + [lt_cv_ld_exported_symbols_list=no]) + LDFLAGS="$save_LDFLAGS" + ]) + AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], + [lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD + echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD + $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + ]) + case $host_os in + rhapsody* | darwin1.[[012]]) + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[[012]]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test "$lt_cv_apple_cc_single_mod" = "yes"; then + _lt_dar_single_mod='$single_module' + fi + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + fi + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac +]) + + +# _LT_DARWIN_LINKER_FEATURES +# -------------------------- +# Checks for linker and compiler features on darwin +m4_defun([_LT_DARWIN_LINKER_FEATURES], +[ + m4_require([_LT_REQUIRED_DARWIN_CHECKS]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_automatic, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + if test "$lt_cv_ld_force_load" = "yes"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='' + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" + case $cc_basename in + ifort*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test "$_lt_dar_can_shared" = "yes"; then + output_verbose_link_cmd=func_echo_all + _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + m4_if([$1], [CXX], +[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then + _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" + fi +],[]) + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi +]) + +# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) +# ---------------------------------- +# Links a minimal program and checks the executable +# for the system default hardcoded library path. In most cases, +# this is /usr/lib:/lib, but when the MPI compilers are used +# the location of the communication and MPI libs are included too. +# If we don't find anything, use the default library path according +# to the aix ld manual. +# Store the results from the different compilers for each TAGNAME. +# Allow to override them for all tags through lt_cv_aix_libpath. +m4_defun([_LT_SYS_MODULE_PATH_AIX], +[m4_require([_LT_DECL_SED])dnl +if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], + [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ + lt_aix_libpath_sed='[ + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }]' + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi],[]) + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" + fi + ]) + aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) +fi +])# _LT_SYS_MODULE_PATH_AIX + + +# _LT_SHELL_INIT(ARG) +# ------------------- +m4_define([_LT_SHELL_INIT], +[m4_divert_text([M4SH-INIT], [$1 +])])# _LT_SHELL_INIT + + + +# _LT_PROG_ECHO_BACKSLASH +# ----------------------- +# Find how we can fake an echo command that does not interpret backslash. +# In particular, with Autoconf 2.60 or later we add some code to the start +# of the generated configure script which will find a shell with a builtin +# printf (which we can use as an echo command). +m4_defun([_LT_PROG_ECHO_BACKSLASH], +[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +AC_MSG_CHECKING([how to print strings]) +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$[]1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + +case "$ECHO" in + printf*) AC_MSG_RESULT([printf]) ;; + print*) AC_MSG_RESULT([print -r]) ;; + *) AC_MSG_RESULT([cat]) ;; +esac + +m4_ifdef([_AS_DETECT_SUGGESTED], +[_AS_DETECT_SUGGESTED([ + test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test "X`printf %s $ECHO`" = "X$ECHO" \ + || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) + +_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) +_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) +])# _LT_PROG_ECHO_BACKSLASH + + +# _LT_WITH_SYSROOT +# ---------------- +AC_DEFUN([_LT_WITH_SYSROOT], +[AC_MSG_CHECKING([for sysroot]) +AC_ARG_WITH([sysroot], +[ --with-sysroot[=DIR] Search for dependent libraries within DIR + (or the compiler's sysroot if not specified).], +[], [with_sysroot=no]) + +dnl lt_sysroot will always be passed unquoted. We quote it here +dnl in case the user passed a directory name. +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + AC_MSG_RESULT([${with_sysroot}]) + AC_MSG_ERROR([The sysroot must be an absolute path.]) + ;; +esac + + AC_MSG_RESULT([${lt_sysroot:-no}]) +_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl +[dependent libraries, and in which our libraries should be installed.])]) + +# _LT_ENABLE_LOCK +# --------------- +m4_defun([_LT_ENABLE_LOCK], +[AC_ARG_ENABLE([libtool-lock], + [AS_HELP_STRING([--disable-libtool-lock], + [avoid locking (might break parallel builds)])]) +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out which ABI we are using. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_i386" + ;; + ppc64-*linux*|powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + ppc*-*linux*|powerpc*-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, + [AC_LANG_PUSH(C) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) + AC_LANG_POP]) + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +sparc*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) LD="${LD-ld} -m elf64_sparc" ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks="$enable_libtool_lock" +])# _LT_ENABLE_LOCK + + +# _LT_PROG_AR +# ----------- +m4_defun([_LT_PROG_AR], +[AC_CHECK_TOOLS(AR, [ar], false) +: ${AR=ar} +: ${AR_FLAGS=cru} +_LT_DECL([], [AR], [1], [The archiver]) +_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) + +AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], + [lt_cv_ar_at_file=no + AC_COMPILE_IFELSE([AC_LANG_PROGRAM], + [echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([lt_ar_try]) + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + AC_TRY_EVAL([lt_ar_try]) + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + ]) + ]) + +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi +_LT_DECL([], [archiver_list_spec], [1], + [How to feed a file listing to the archiver]) +])# _LT_PROG_AR + + +# _LT_CMD_OLD_ARCHIVE +# ------------------- +m4_defun([_LT_CMD_OLD_ARCHIVE], +[_LT_PROG_AR + +AC_CHECK_TOOL(STRIP, strip, :) +test -z "$STRIP" && STRIP=: +_LT_DECL([], [STRIP], [1], [A symbol stripping program]) + +AC_CHECK_TOOL(RANLIB, ranlib, :) +test -z "$RANLIB" && RANLIB=: +_LT_DECL([], [RANLIB], [1], + [Commands used to install an old-style archive]) + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac +_LT_DECL([], [old_postinstall_cmds], [2]) +_LT_DECL([], [old_postuninstall_cmds], [2]) +_LT_TAGDECL([], [old_archive_cmds], [2], + [Commands used to build an old-style archive]) +_LT_DECL([], [lock_old_archive_extraction], [0], + [Whether to use a lock for old archive extraction]) +])# _LT_CMD_OLD_ARCHIVE + + +# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------------------- +# Check whether the given compiler option works +AC_DEFUN([_LT_COMPILER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$3" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + fi + $RM conftest* +]) + +if test x"[$]$2" = xyes; then + m4_if([$5], , :, [$5]) +else + m4_if([$6], , :, [$6]) +fi +])# _LT_COMPILER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) + + +# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------- +# Check whether the given linker option works +AC_DEFUN([_LT_LINKER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $3" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&AS_MESSAGE_LOG_FD + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + else + $2=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" +]) + +if test x"[$]$2" = xyes; then + m4_if([$4], , :, [$4]) +else + m4_if([$5], , :, [$5]) +fi +])# _LT_LINKER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) + + +# LT_CMD_MAX_LEN +#--------------- +AC_DEFUN([LT_CMD_MAX_LEN], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +# find the maximum length of command line arguments +AC_MSG_CHECKING([the maximum length of command line arguments]) +AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl + i=0 + teststring="ABCD" + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8 ; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac +]) +if test -n $lt_cv_sys_max_cmd_len ; then + AC_MSG_RESULT($lt_cv_sys_max_cmd_len) +else + AC_MSG_RESULT(none) +fi +max_cmd_len=$lt_cv_sys_max_cmd_len +_LT_DECL([], [max_cmd_len], [0], + [What is the maximum length of a command?]) +])# LT_CMD_MAX_LEN + +# Old name: +AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) + + +# _LT_HEADER_DLFCN +# ---------------- +m4_defun([_LT_HEADER_DLFCN], +[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl +])# _LT_HEADER_DLFCN + + +# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, +# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) +# ---------------------------------------------------------------- +m4_defun([_LT_TRY_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test "$cross_compiling" = yes; then : + [$4] +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +[#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +}] +_LT_EOF + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) $1 ;; + x$lt_dlneed_uscore) $2 ;; + x$lt_dlunknown|x*) $3 ;; + esac + else : + # compilation failed + $3 + fi +fi +rm -fr conftest* +])# _LT_TRY_DLOPEN_SELF + + +# LT_SYS_DLOPEN_SELF +# ------------------ +AC_DEFUN([LT_SYS_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ]) + ;; + + *) + AC_CHECK_FUNC([shl_load], + [lt_cv_dlopen="shl_load"], + [AC_CHECK_LIB([dld], [shl_load], + [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], + [AC_CHECK_FUNC([dlopen], + [lt_cv_dlopen="dlopen"], + [AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], + [AC_CHECK_LIB([svld], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], + [AC_CHECK_LIB([dld], [dld_link], + [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) + ]) + ]) + ]) + ]) + ]) + ;; + esac + + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + + AC_CACHE_CHECK([whether a program can dlopen itself], + lt_cv_dlopen_self, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, + lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) + ]) + + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + AC_CACHE_CHECK([whether a statically linked program can dlopen itself], + lt_cv_dlopen_self_static, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, + lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) + ]) + fi + + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi +_LT_DECL([dlopen_support], [enable_dlopen], [0], + [Whether dlopen is supported]) +_LT_DECL([dlopen_self], [enable_dlopen_self], [0], + [Whether dlopen of programs is supported]) +_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], + [Whether dlopen of statically linked programs is supported]) +])# LT_SYS_DLOPEN_SELF + +# Old name: +AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) + + +# _LT_COMPILER_C_O([TAGNAME]) +# --------------------------- +# Check to see if options -c and -o are simultaneously supported by compiler. +# This macro does not hard code the compiler like AC_PROG_CC_C_O. +m4_defun([_LT_COMPILER_C_O], +[m4_require([_LT_DECL_SED])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + fi + fi + chmod u+w . 2>&AS_MESSAGE_LOG_FD + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* +]) +_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], + [Does compiler simultaneously support -c and -o options?]) +])# _LT_COMPILER_C_O + + +# _LT_COMPILER_FILE_LOCKS([TAGNAME]) +# ---------------------------------- +# Check to see if we can do hard links to lock some files if needed +m4_defun([_LT_COMPILER_FILE_LOCKS], +[m4_require([_LT_ENABLE_LOCK])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_COMPILER_C_O([$1]) + +hard_links="nottested" +if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + AC_MSG_CHECKING([if we can lock with hard links]) + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + AC_MSG_RESULT([$hard_links]) + if test "$hard_links" = no; then + AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) + need_locks=warn + fi +else + need_locks=no +fi +_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) +])# _LT_COMPILER_FILE_LOCKS + + +# _LT_CHECK_OBJDIR +# ---------------- +m4_defun([_LT_CHECK_OBJDIR], +[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], +[rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null]) +objdir=$lt_cv_objdir +_LT_DECL([], [objdir], [0], + [The name of the directory that contains temporary libtool files])dnl +m4_pattern_allow([LT_OBJDIR])dnl +AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", + [Define to the sub-directory in which libtool stores uninstalled libraries.]) +])# _LT_CHECK_OBJDIR + + +# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) +# -------------------------------------- +# Check hardcoding attributes. +m4_defun([_LT_LINKER_HARDCODE_LIBPATH], +[AC_MSG_CHECKING([how to hardcode library paths into programs]) +_LT_TAGVAR(hardcode_action, $1)= +if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || + test -n "$_LT_TAGVAR(runpath_var, $1)" || + test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then + + # We can hardcode non-existent directories. + if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && + test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then + # Linking always hardcodes the temporary library directory. + _LT_TAGVAR(hardcode_action, $1)=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + _LT_TAGVAR(hardcode_action, $1)=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + _LT_TAGVAR(hardcode_action, $1)=unsupported +fi +AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) + +if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || + test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi +_LT_TAGDECL([], [hardcode_action], [0], + [How to hardcode a shared library path into an executable]) +])# _LT_LINKER_HARDCODE_LIBPATH + + +# _LT_CMD_STRIPLIB +# ---------------- +m4_defun([_LT_CMD_STRIPLIB], +[m4_require([_LT_DECL_EGREP]) +striplib= +old_striplib= +AC_MSG_CHECKING([whether stripping libraries is possible]) +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + fi + ;; + *) + AC_MSG_RESULT([no]) + ;; + esac +fi +_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) +_LT_DECL([], [striplib], [1]) +])# _LT_CMD_STRIPLIB + + +# _LT_SYS_DYNAMIC_LINKER([TAG]) +# ----------------------------- +# PORTME Fill in your ld.so characteristics +m4_defun([_LT_SYS_DYNAMIC_LINKER], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_OBJDUMP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +AC_MSG_CHECKING([dynamic linker characteristics]) +m4_if([$1], + [], [ +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[[lt_foo]]++; } + if (lt_freq[[lt_foo]] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi]) +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; + +aix[[4-9]]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[[01]] | aix4.[[01]].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; + esac + ;; + +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[[45]]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd1*) + dynamic_linker=no + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[[123]]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[[01]]* | freebsdelf3.[[01]]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ + freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; + +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[[3-9]]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], + [lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ + LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], + [lt_cv_shlibpath_overrides_runpath=yes])]) + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + ]) + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[[89]] | openbsd2.[[89]].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; + +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +AC_MSG_RESULT([$dynamic_linker]) +test "$dynamic_linker" = no && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +fi +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +fi + +_LT_DECL([], [variables_saved_for_relink], [1], + [Variables whose values should be saved in libtool wrapper scripts and + restored at link time]) +_LT_DECL([], [need_lib_prefix], [0], + [Do we need the "lib" prefix for modules?]) +_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) +_LT_DECL([], [version_type], [0], [Library versioning type]) +_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) +_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) +_LT_DECL([], [shlibpath_overrides_runpath], [0], + [Is shlibpath searched before the hard-coded library search path?]) +_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) +_LT_DECL([], [library_names_spec], [1], + [[List of archive names. First name is the real one, the rest are links. + The last name is the one that the linker finds with -lNAME]]) +_LT_DECL([], [soname_spec], [1], + [[The coded name of the library, if different from the real name]]) +_LT_DECL([], [install_override_mode], [1], + [Permission mode override for installation of shared libraries]) +_LT_DECL([], [postinstall_cmds], [2], + [Command to use after installation of a shared archive]) +_LT_DECL([], [postuninstall_cmds], [2], + [Command to use after uninstallation of a shared archive]) +_LT_DECL([], [finish_cmds], [2], + [Commands used to finish a libtool library installation in a directory]) +_LT_DECL([], [finish_eval], [1], + [[As "finish_cmds", except a single script fragment to be evaled but + not shown]]) +_LT_DECL([], [hardcode_into_libs], [0], + [Whether we should hardcode library paths into libraries]) +_LT_DECL([], [sys_lib_search_path_spec], [2], + [Compile-time system search path for libraries]) +_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], + [Run-time system search path for libraries]) +])# _LT_SYS_DYNAMIC_LINKER + + +# _LT_PATH_TOOL_PREFIX(TOOL) +# -------------------------- +# find a file program which can recognize shared library +AC_DEFUN([_LT_PATH_TOOL_PREFIX], +[m4_require([_LT_DECL_EGREP])dnl +AC_MSG_CHECKING([for $1]) +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, +[case $MAGIC_CMD in +[[\\/*] | ?:[\\/]*]) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR +dnl $ac_dummy forces splitting on constant user-supplied paths. +dnl POSIX.2 word splitting is done only on the output of word expansions, +dnl not every word. This closes a longstanding sh security hole. + ac_dummy="m4_if([$2], , $PATH, [$2])" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$1; then + lt_cv_path_MAGIC_CMD="$ac_dir/$1" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac]) +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + AC_MSG_RESULT($MAGIC_CMD) +else + AC_MSG_RESULT(no) +fi +_LT_DECL([], [MAGIC_CMD], [0], + [Used to examine libraries when file_magic_cmd begins with "file"])dnl +])# _LT_PATH_TOOL_PREFIX + +# Old name: +AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) + + +# _LT_PATH_MAGIC +# -------------- +# find a file program which can recognize a shared library +m4_defun([_LT_PATH_MAGIC], +[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) + else + MAGIC_CMD=: + fi +fi +])# _LT_PATH_MAGIC + + +# LT_PATH_LD +# ---------- +# find the pathname to the GNU or non-GNU linker +AC_DEFUN([LT_PATH_LD], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PROG_ECHO_BACKSLASH])dnl + +AC_ARG_WITH([gnu-ld], + [AS_HELP_STRING([--with-gnu-ld], + [assume the C compiler uses GNU ld @<:@default=no@:>@])], + [test "$withval" = no || with_gnu_ld=yes], + [with_gnu_ld=no])dnl + +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + AC_MSG_CHECKING([for ld used by $CC]) + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [[\\/]]* | ?:[[\\/]]*) + re_direlt='/[[^/]][[^/]]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + AC_MSG_CHECKING([for GNU ld]) +else + AC_MSG_CHECKING([for non-GNU ld]) +fi +AC_CACHE_VAL(lt_cv_path_LD, +[if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &1 /dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[[3-9]]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +esac +]) + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + +_LT_DECL([], [deplibs_check_method], [1], + [Method to check whether dependent libraries are shared objects]) +_LT_DECL([], [file_magic_cmd], [1], + [Command to use when deplibs_check_method = "file_magic"]) +_LT_DECL([], [file_magic_glob], [1], + [How to find potential files when deplibs_check_method = "file_magic"]) +_LT_DECL([], [want_nocaseglob], [1], + [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) +])# _LT_CHECK_MAGIC_METHOD + + +# LT_PATH_NM +# ---------- +# find the pathname to a BSD- or MS-compatible name lister +AC_DEFUN([LT_PATH_NM], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, +[if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS="$lt_save_ifs" + done + : ${lt_cv_path_NM=no} +fi]) +if test "$lt_cv_path_NM" != "no"; then + NM="$lt_cv_path_NM" +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi + AC_SUBST([DUMPBIN]) + if test "$DUMPBIN" != ":"; then + NM="$DUMPBIN" + fi +fi +test -z "$NM" && NM=nm +AC_SUBST([NM]) +_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl + +AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], + [lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) + cat conftest.out >&AS_MESSAGE_LOG_FD + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest*]) +])# LT_PATH_NM + +# Old names: +AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) +AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_PROG_NM], []) +dnl AC_DEFUN([AC_PROG_NM], []) + +# _LT_CHECK_SHAREDLIB_FROM_LINKLIB +# -------------------------------- +# how to determine the name of the shared library +# associated with a specific link library. +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +m4_require([_LT_DECL_DLLTOOL]) +AC_CACHE_CHECK([how to associate runtime and link libraries], +lt_cv_sharedlib_from_linklib_cmd, +[lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd="$ECHO" + ;; +esac +]) +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + +_LT_DECL([], [sharedlib_from_linklib_cmd], [1], + [Command to associate shared and link libraries]) +])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB + + +# _LT_PATH_MANIFEST_TOOL +# ---------------------- +# locate the manifest tool +m4_defun([_LT_PATH_MANIFEST_TOOL], +[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], + [lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&AS_MESSAGE_LOG_FD + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest*]) +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi +_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl +])# _LT_PATH_MANIFEST_TOOL + + +# LT_LIB_M +# -------- +# check for math library +AC_DEFUN([LT_LIB_M], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +LIBM= +case $host in +*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) + # These system don't have libm, or don't need it + ;; +*-ncr-sysv4.3*) + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") + AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") + ;; +*) + AC_CHECK_LIB(m, cos, LIBM="-lm") + ;; +esac +AC_SUBST([LIBM]) +])# LT_LIB_M + +# Old name: +AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_CHECK_LIBM], []) + + +# _LT_COMPILER_NO_RTTI([TAGNAME]) +# ------------------------------- +m4_defun([_LT_COMPILER_NO_RTTI], +[m4_require([_LT_TAG_COMPILER])dnl + +_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + +if test "$GCC" = yes; then + case $cc_basename in + nvcc*) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; + *) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; + esac + + _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], + lt_cv_prog_compiler_rtti_exceptions, + [-fno-rtti -fno-exceptions], [], + [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) +fi +_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], + [Compiler flag to turn off builtin functions]) +])# _LT_COMPILER_NO_RTTI + + +# _LT_CMD_GLOBAL_SYMBOLS +# ---------------------- +m4_defun([_LT_CMD_GLOBAL_SYMBOLS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([LT_PATH_NM])dnl +AC_REQUIRE([LT_PATH_LD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_TAG_COMPILER])dnl + +# Check for command to grab the raw symbol name followed by C symbol from nm. +AC_MSG_CHECKING([command to parse $NM output from $compiler object]) +AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], +[ +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[[BCDEGRST]]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[[BCDT]]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[[ABCDGISTW]]' + ;; +hpux*) + if test "$host_cpu" = ia64; then + symcode='[[ABCDEGRST]]' + fi + ;; +irix* | nonstopux*) + symcode='[[BCDEGRST]]' + ;; +osf*) + symcode='[[BCDEGQRST]]' + ;; +solaris*) + symcode='[[BDRT]]' + ;; +sco3.2v5*) + symcode='[[DT]]' + ;; +sysv4.2uw2*) + symcode='[[DT]]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[[ABDT]]' + ;; +sysv4) + symcode='[[DFNSTU]]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[[ABCDGIRSTW]]' ;; +esac + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function + # and D for any global variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK ['"\ +" {last_section=section; section=\$ 3};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ +" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ +" s[1]~/^[@?]/{print s[1], s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx]" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if AC_TRY_EVAL(ac_compile); then + # Now try to grab the symbols. + nlist=conftest.nm + if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT@&t@_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT@&t@_DLSYM_CONST +#else +# define LT@&t@_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT@&t@_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[[]] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD + fi + else + echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done +]) +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + AC_MSG_RESULT(failed) +else + AC_MSG_RESULT(ok) +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + +_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], + [Take the output of nm and produce a listing of raw symbols and C names]) +_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], + [Transform the output of nm in a proper C declaration]) +_LT_DECL([global_symbol_to_c_name_address], + [lt_cv_sys_global_symbol_to_c_name_address], [1], + [Transform the output of nm in a C name address pair]) +_LT_DECL([global_symbol_to_c_name_address_lib_prefix], + [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], + [Transform the output of nm in a C name address pair when lib prefix is needed]) +_LT_DECL([], [nm_file_list_spec], [1], + [Specify filename containing input files for $NM]) +]) # _LT_CMD_GLOBAL_SYMBOLS + + +# _LT_COMPILER_PIC([TAGNAME]) +# --------------------------- +m4_defun([_LT_COMPILER_PIC], +[m4_require([_LT_TAG_COMPILER])dnl +_LT_TAGVAR(lt_prog_compiler_wl, $1)= +_LT_TAGVAR(lt_prog_compiler_pic, $1)= +_LT_TAGVAR(lt_prog_compiler_static, $1)= + +m4_if([$1], [CXX], [ + # C++ specific cases for pic, static, wl, etc. + if test "$GXX" = yes; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + else + case $host_os in + aix[[4-9]]*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + dgux*) + case $cc_basename in + ec++*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + if test "$host_cpu" != ia64; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + fi + ;; + aCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + KCC*) + # KAI C++ Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64 which still supported -KPIC. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd*) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + cxx*) + # Digital/Compaq C++ + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + lcc*) + # Lucid + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +], +[ + if test "$GCC" = yes; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + + hpux9* | hpux10* | hpux11*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC (with -KPIC) is the default. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + # old Intel for x86_64 which still supported -KPIC. + ecc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' + _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' + ;; + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + ccc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All Alpha code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ F* | *Sun*Fortran*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='' + ;; + *Sun\ C*) + # Sun C 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + ;; + esac + ;; + esac + ;; + + newsos6) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All OSF/1 code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + rdos*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + solaris*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; + *) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; + esac + ;; + + sunos4*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec ;then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + unicos*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + + uts4*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +]) +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" + ;; +esac + +AC_CACHE_CHECK([for $compiler option to produce PIC], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) +_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then + _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], + [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], + [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], + [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in + "" | " "*) ;; + *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; + esac], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) +fi +_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], + [Additional compiler flags for building library objects]) + +_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], + [How to pass a linker flag through the compiler]) +# +# Check to make sure the static flag actually works. +# +wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" +_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], + _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), + $lt_tmp_static_flag, + [], + [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) +_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], + [Compiler flag to prevent dynamic linking]) +])# _LT_COMPILER_PIC + + +# _LT_LINKER_SHLIBS([TAGNAME]) +# ---------------------------- +# See if the linker supports building shared libraries. +m4_defun([_LT_LINKER_SHLIBS], +[AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) +m4_if([$1], [CXX], [ + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + case $host_os in + aix[[4-9]]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global defined + # symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + ;; + esac + ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac +], [ + runpath_var= + _LT_TAGVAR(allow_undefined_flag, $1)= + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(archive_cmds, $1)= + _LT_TAGVAR(archive_expsym_cmds, $1)= + _LT_TAGVAR(compiler_needs_object, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(hardcode_automatic, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= + _LT_TAGVAR(hardcode_libdir_separator, $1)= + _LT_TAGVAR(hardcode_minus_L, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + _LT_TAGVAR(inherit_rpath, $1)=no + _LT_TAGVAR(link_all_deplibs, $1)=unknown + _LT_TAGVAR(module_cmds, $1)= + _LT_TAGVAR(module_expsym_cmds, $1)= + _LT_TAGVAR(old_archive_from_new_cmds, $1)= + _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= + _LT_TAGVAR(thread_safe_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + _LT_TAGVAR(include_expsyms, $1)= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. +dnl Note also adjust exclude_expsyms for C++ above. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac + + _LT_TAGVAR(ld_shlibs, $1)=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; + *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + supports_anon_versioning=no + case `$LD -v 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[[3-9]]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test "$host_os" = linux-dietlibc; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test "$tmp_diet" = no + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + _LT_TAGVAR(whole_archive_flag_spec, $1)= + tmp_sharedflag='--shared' ;; + xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' + _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + sunos4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + + if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then + runpath_var= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + _LT_TAGVAR(hardcode_direct, $1)=unsupported + fi + ;; + + aix[[4-9]]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + + if test "$GCC" = yes; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + # This is similar to how AIX traditionally builds its shared libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + bsdi[[45]]*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + # FIXME: Should let the user specify the lib program. + _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + esac + ;; + + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + dgux*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + freebsd1*) + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + hpux9*) + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + ;; + + hpux10*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + fi + ;; + + hpux11*) + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + m4_if($1, [], [ + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + _LT_LINKER_OPTION([if $CC understands -b], + _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], + [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) + ;; + esac + fi + if test "$with_gnu_ld" = no; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], + [lt_cv_irix_exported_symbol], + [save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + AC_LINK_IFELSE( + [AC_LANG_SOURCE( + [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], + [C++], [[int foo (void) { return 0; }]], + [Fortran 77], [[ + subroutine foo + end]], + [Fortran], [[ + subroutine foo + end]])])], + [lt_cv_irix_exported_symbol=yes], + [lt_cv_irix_exported_symbol=no]) + LDFLAGS="$save_LDFLAGS"]) + if test "$lt_cv_irix_exported_symbol" = yes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + newsos6) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *nto* | *qnx*) + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + else + case $host_os in + openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + ;; + esac + fi + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + + osf3*) + if test "$GCC" = yes; then + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + solaris*) + _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' + if test "$GCC" = yes; then + wlarc='${wl}' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='${wl}' + _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + fi + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4) + case $host_vendor in + sni) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' + _LT_TAGVAR(hardcode_direct, $1)=no + ;; + motorola) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4.3*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + _LT_TAGVAR(ld_shlibs, $1)=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + if test x$host_vendor = xsni; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' + ;; + esac + fi + fi +]) +AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) +test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no + +_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld + +_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl +_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl +_LT_DECL([], [extract_expsyms_cmds], [2], + [The commands to extract the exported symbol list from a shared archive]) + +# +# Do we need to explicitly link libc? +# +case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in +x|xyes) + # Assume -lc should be added + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $_LT_TAGVAR(archive_cmds, $1) in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + AC_CACHE_CHECK([whether -lc should be explicitly linked in], + [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), + [$RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if AC_TRY_EVAL(ac_compile) 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) + pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) + _LT_TAGVAR(allow_undefined_flag, $1)= + if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) + then + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no + else + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes + fi + _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + ]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) + ;; + esac + fi + ;; +esac + +_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], + [Whether or not to add -lc for building shared libraries]) +_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], + [enable_shared_with_static_runtimes], [0], + [Whether or not to disallow shared libs when runtime libs are static]) +_LT_TAGDECL([], [export_dynamic_flag_spec], [1], + [Compiler flag to allow reflexive dlopens]) +_LT_TAGDECL([], [whole_archive_flag_spec], [1], + [Compiler flag to generate shared objects directly from archives]) +_LT_TAGDECL([], [compiler_needs_object], [1], + [Whether the compiler copes with passing no objects directly]) +_LT_TAGDECL([], [old_archive_from_new_cmds], [2], + [Create an old-style archive from a shared archive]) +_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], + [Create a temporary old-style archive to link instead of a shared archive]) +_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) +_LT_TAGDECL([], [archive_expsym_cmds], [2]) +_LT_TAGDECL([], [module_cmds], [2], + [Commands used to build a loadable module if different from building + a shared archive.]) +_LT_TAGDECL([], [module_expsym_cmds], [2]) +_LT_TAGDECL([], [with_gnu_ld], [1], + [Whether we are building with GNU ld or not]) +_LT_TAGDECL([], [allow_undefined_flag], [1], + [Flag that allows shared libraries with undefined symbols to be built]) +_LT_TAGDECL([], [no_undefined_flag], [1], + [Flag that enforces no undefined symbols]) +_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], + [Flag to hardcode $libdir into a binary during linking. + This must work even if $libdir does not exist]) +_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1], + [[If ld is used when linking, flag to hardcode $libdir into a binary + during linking. This must work even if $libdir does not exist]]) +_LT_TAGDECL([], [hardcode_libdir_separator], [1], + [Whether we need a single "-rpath" flag with a separated argument]) +_LT_TAGDECL([], [hardcode_direct], [0], + [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + DIR into the resulting binary]) +_LT_TAGDECL([], [hardcode_direct_absolute], [0], + [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + DIR into the resulting binary and the resulting library dependency is + "absolute", i.e impossible to change by setting ${shlibpath_var} if the + library is relocated]) +_LT_TAGDECL([], [hardcode_minus_L], [0], + [Set to "yes" if using the -LDIR flag during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_shlibpath_var], [0], + [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_automatic], [0], + [Set to "yes" if building a shared library automatically hardcodes DIR + into the library and all subsequent libraries and executables linked + against it]) +_LT_TAGDECL([], [inherit_rpath], [0], + [Set to yes if linker adds runtime paths of dependent libraries + to runtime path list]) +_LT_TAGDECL([], [link_all_deplibs], [0], + [Whether libtool must link a program against all its dependency libraries]) +_LT_TAGDECL([], [always_export_symbols], [0], + [Set to "yes" if exported symbols are required]) +_LT_TAGDECL([], [export_symbols_cmds], [2], + [The commands to list exported symbols]) +_LT_TAGDECL([], [exclude_expsyms], [1], + [Symbols that should not be listed in the preloaded symbols]) +_LT_TAGDECL([], [include_expsyms], [1], + [Symbols that must always be exported]) +_LT_TAGDECL([], [prelink_cmds], [2], + [Commands necessary for linking programs (against libraries) with templates]) +_LT_TAGDECL([], [postlink_cmds], [2], + [Commands necessary for finishing linking programs]) +_LT_TAGDECL([], [file_list_spec], [1], + [Specify filename containing input files]) +dnl FIXME: Not yet implemented +dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], +dnl [Compiler flag to generate thread safe objects]) +])# _LT_LINKER_SHLIBS + + +# _LT_LANG_C_CONFIG([TAG]) +# ------------------------ +# Ensure that the configuration variables for a C compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to `libtool'. +m4_defun([_LT_LANG_C_CONFIG], +[m4_require([_LT_DECL_EGREP])dnl +lt_save_CC="$CC" +AC_LANG_PUSH(C) + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + +_LT_TAG_COMPILER +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + LT_SYS_DLOPEN_SELF + _LT_CMD_STRIPLIB + + # Report which library types will actually be built + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_CONFIG($1) +fi +AC_LANG_POP +CC="$lt_save_CC" +])# _LT_LANG_C_CONFIG + + +# _LT_LANG_CXX_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a C++ compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to `libtool'. +m4_defun([_LT_LANG_CXX_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + AC_PROG_CXXCPP +else + _lt_caught_CXX_error=yes +fi + +AC_LANG_PUSH(C++) +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(compiler_needs_object, $1)=no +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_caught_CXX_error" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test "$GXX" = yes; then + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' + else + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + fi + + if test "$GXX" = yes; then + # Set up default GNU C++ configuration + + LT_PATH_LD + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test "$with_gnu_ld" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='${wl}' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) + _LT_TAGVAR(ld_shlibs, $1)=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aix[[4-9]]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + + if test "$GXX" = yes; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an empty + # executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + # This is similar to how AIX traditionally builds its shared + # libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + freebsd[[12]]*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + freebsd-elf*) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + gnu*) + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + hpux9*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test $with_gnu_ld = no; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes; then + if test $with_gnu_ld = no; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test "$GXX" = yes; then + if test "$with_gnu_ld" = no; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' + fi + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + esac + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) + _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + ;; + cxx*) + # Compaq C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + openbsd2*) + # C++ shared libraries are fairly broken + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + cxx*) + case $host in + osf3*) + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + ;; + *) + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ + $RM $lib.exp' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + case $host in + osf3*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(archive_cmds_need_lc,$1)=yes + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require `-G' NOT `-shared' on this + # platform. + _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ + '"$_LT_TAGVAR(old_archive_cmds, $1)" + _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ + '"$_LT_TAGVAR(reload_cmds, $1)" + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) + test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no + + _LT_TAGVAR(GCC, $1)="$GXX" + _LT_TAGVAR(LD, $1)="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test "$_lt_caught_CXX_error" != yes + +AC_LANG_POP +])# _LT_LANG_CXX_CONFIG + + +# _LT_FUNC_STRIPNAME_CNF +# ---------------------- +# func_stripname_cnf prefix suffix name +# strip PREFIX and SUFFIX off of NAME. +# PREFIX and SUFFIX must not contain globbing or regex special +# characters, hashes, percent signs, but SUFFIX may contain a leading +# dot (in which case that matches only a dot). +# +# This function is identical to the (non-XSI) version of func_stripname, +# except this one can be used by m4 code that may be executed by configure, +# rather than the libtool script. +m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl +AC_REQUIRE([_LT_DECL_SED]) +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) +func_stripname_cnf () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname_cnf +])# _LT_FUNC_STRIPNAME_CNF + +# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) +# --------------------------------- +# Figure out "hidden" library dependencies from verbose +# compiler output when linking a shared library. +# Parse the compiler output and extract the necessary +# objects, libraries and library flags. +m4_defun([_LT_SYS_HIDDEN_LIBDEPS], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl +# Dependencies to place before and after the object being linked: +_LT_TAGVAR(predep_objects, $1)= +_LT_TAGVAR(postdep_objects, $1)= +_LT_TAGVAR(predeps, $1)= +_LT_TAGVAR(postdeps, $1)= +_LT_TAGVAR(compiler_lib_search_path, $1)= + +dnl we can't use the lt_simple_compile_test_code here, +dnl because it contains code intended for an executable, +dnl not a library. It's possible we should let each +dnl tag define a new lt_????_link_test_code variable, +dnl but it's only used here... +m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF +int a; +void foo (void) { a = 0; } +_LT_EOF +], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF +], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer*4 a + a=0 + return + end +_LT_EOF +], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer a + a=0 + return + end +_LT_EOF +], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF +public class foo { + private int a; + public void bar (void) { + a = 0; + } +}; +_LT_EOF +]) + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +esac + +dnl Parse the compiler output and extract the necessary +dnl objects, libraries and library flags. +if AC_TRY_EVAL(ac_compile); then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case ${prev}${p} in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test $p = "-L" || + test $p = "-R"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test "$pre_test_object_deps_done" = no; then + case ${prev} in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then + _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" + else + _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$_LT_TAGVAR(postdeps, $1)"; then + _LT_TAGVAR(postdeps, $1)="${prev}${p}" + else + _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test "$pre_test_object_deps_done" = no; then + if test -z "$_LT_TAGVAR(predep_objects, $1)"; then + _LT_TAGVAR(predep_objects, $1)="$p" + else + _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" + fi + else + if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then + _LT_TAGVAR(postdep_objects, $1)="$p" + else + _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling $1 test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +m4_if([$1], [CXX], +[case $host_os in +interix[[3-9]]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + _LT_TAGVAR(predep_objects,$1)= + _LT_TAGVAR(postdep_objects,$1)= + _LT_TAGVAR(postdeps,$1)= + ;; + +linux*) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + if test "$solaris_use_stlport4" != yes; then + _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' + fi + ;; + esac + ;; + +solaris*) + case $cc_basename in + CC* | sunCC*) + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + + # Adding this requires a known-good setup of shared libraries for + # Sun compiler versions before 5.6, else PIC objects from an old + # archive will be linked into the output, leading to subtle bugs. + if test "$solaris_use_stlport4" != yes; then + _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' + fi + ;; + esac + ;; +esac +]) + +case " $_LT_TAGVAR(postdeps, $1) " in +*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; +esac + _LT_TAGVAR(compiler_lib_search_dirs, $1)= +if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then + _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` +fi +_LT_TAGDECL([], [compiler_lib_search_dirs], [1], + [The directories searched by this compiler when creating a shared library]) +_LT_TAGDECL([], [predep_objects], [1], + [Dependencies to place before and after the objects being linked to + create a shared library]) +_LT_TAGDECL([], [postdep_objects], [1]) +_LT_TAGDECL([], [predeps], [1]) +_LT_TAGDECL([], [postdeps], [1]) +_LT_TAGDECL([], [compiler_lib_search_path], [1], + [The library search path used internally by the compiler when linking + a shared library]) +])# _LT_SYS_HIDDEN_LIBDEPS + + +# _LT_LANG_F77_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a Fortran 77 compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_F77_CONFIG], +[AC_LANG_PUSH(Fortran 77) +if test -z "$F77" || test "X$F77" = "Xno"; then + _lt_disable_F77=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for f77 test sources. +ac_ext=f + +# Object file extension for compiled f77 test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the F77 compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_disable_F77" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC="$CC" + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${F77-"f77"} + CFLAGS=$FFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + GCC=$G77 + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)="$G77" + _LT_TAGVAR(LD, $1)="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC="$lt_save_CC" + CFLAGS="$lt_save_CFLAGS" +fi # test "$_lt_disable_F77" != yes + +AC_LANG_POP +])# _LT_LANG_F77_CONFIG + + +# _LT_LANG_FC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for a Fortran compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_FC_CONFIG], +[AC_LANG_PUSH(Fortran) + +if test -z "$FC" || test "X$FC" = "Xno"; then + _lt_disable_FC=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for fc test sources. +ac_ext=${ac_fc_srcext-f} + +# Object file extension for compiled fc test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the FC compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test "$_lt_disable_FC" != yes; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC="$CC" + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${FC-"f95"} + CFLAGS=$FCFLAGS + compiler=$CC + GCC=$ac_cv_fc_compiler_gnu + + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test "$can_build_shared" = "no" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test "$enable_shared" = yes || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" + _LT_TAGVAR(LD, $1)="$LD" + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test "$_lt_disable_FC" != yes + +AC_LANG_POP +])# _LT_LANG_FC_CONFIG + + +# _LT_LANG_GCJ_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Java Compiler compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_GCJ_CONFIG], +[AC_REQUIRE([LT_PROG_GCJ])dnl +AC_LANG_SAVE + +# Source file extension for Java test sources. +ac_ext=java + +# Object file extension for compiled Java test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="class foo {}" + +# Code to be used in simple link tests +lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC=yes +CC=${GCJ-"gcj"} +CFLAGS=$GCJFLAGS +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_TAGVAR(LD, $1)="$LD" +_LT_CC_BASENAME([$compiler]) + +# GCJ did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +AC_LANG_RESTORE + +GCC=$lt_save_GCC +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_GCJ_CONFIG + + +# _LT_LANG_RC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for the Windows resource compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. +m4_defun([_LT_LANG_RC_CONFIG], +[AC_REQUIRE([LT_PROG_RC])dnl +AC_LANG_SAVE + +# Source file extension for RC test sources. +ac_ext=rc + +# Object file extension for compiled RC test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' + +# Code to be used in simple link tests +lt_simple_link_test_code="$lt_simple_compile_test_code" + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC= +CC=${RC-"windres"} +CFLAGS= +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_CC_BASENAME([$compiler]) +_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + +if test -n "$compiler"; then + : + _LT_CONFIG($1) +fi + +GCC=$lt_save_GCC +AC_LANG_RESTORE +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_RC_CONFIG + + +# LT_PROG_GCJ +# ----------- +AC_DEFUN([LT_PROG_GCJ], +[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], + [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], + [AC_CHECK_TOOL(GCJ, gcj,) + test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" + AC_SUBST(GCJFLAGS)])])[]dnl +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_GCJ], []) + + +# LT_PROG_RC +# ---------- +AC_DEFUN([LT_PROG_RC], +[AC_CHECK_TOOL(RC, windres,) +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_RC], []) + + +# _LT_DECL_EGREP +# -------------- +# If we don't have a new enough Autoconf to choose the best grep +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_EGREP], +[AC_REQUIRE([AC_PROG_EGREP])dnl +AC_REQUIRE([AC_PROG_FGREP])dnl +test -z "$GREP" && GREP=grep +_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) +_LT_DECL([], [EGREP], [1], [An ERE matcher]) +_LT_DECL([], [FGREP], [1], [A literal string matcher]) +dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too +AC_SUBST([GREP]) +]) + + +# _LT_DECL_OBJDUMP +# -------------- +# If we don't have a new enough Autoconf to choose the best objdump +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_OBJDUMP], +[AC_CHECK_TOOL(OBJDUMP, objdump, false) +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) +AC_SUBST([OBJDUMP]) +]) + +# _LT_DECL_DLLTOOL +# ---------------- +# Ensure DLLTOOL variable is set. +m4_defun([_LT_DECL_DLLTOOL], +[AC_CHECK_TOOL(DLLTOOL, dlltool, false) +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) +AC_SUBST([DLLTOOL]) +]) + +# _LT_DECL_SED +# ------------ +# Check for a fully-functional sed program, that truncates +# as few characters as possible. Prefer GNU sed if found. +m4_defun([_LT_DECL_SED], +[AC_PROG_SED +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" +_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) +_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], + [Sed that helps us avoid accidentally triggering echo(1) options like -n]) +])# _LT_DECL_SED + +m4_ifndef([AC_PROG_SED], [ +############################################################ +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_SED. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # +############################################################ + +m4_defun([AC_PROG_SED], +[AC_MSG_CHECKING([for a sed that does not truncate output]) +AC_CACHE_VAL(lt_cv_path_SED, +[# Loop through the user's path and test for sed and gsed. +# Then use that list of sed's as ones to test for truncation. +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for lt_ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then + lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" + fi + done + done +done +IFS=$as_save_IFS +lt_ac_max=0 +lt_ac_count=0 +# Add /usr/xpg4/bin/sed as it is typically found on Solaris +# along with /bin/sed that truncates output. +for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do + test ! -f $lt_ac_sed && continue + cat /dev/null > conftest.in + lt_ac_count=0 + echo $ECHO_N "0123456789$ECHO_C" >conftest.in + # Check for GNU sed and select it if it is found. + if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then + lt_cv_path_SED=$lt_ac_sed + break + fi + while true; do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo >>conftest.nl + $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break + cmp -s conftest.out conftest.nl || break + # 10000 chars as input seems more than enough + test $lt_ac_count -gt 10 && break + lt_ac_count=`expr $lt_ac_count + 1` + if test $lt_ac_count -gt $lt_ac_max; then + lt_ac_max=$lt_ac_count + lt_cv_path_SED=$lt_ac_sed + fi + done +done +]) +SED=$lt_cv_path_SED +AC_SUBST([SED]) +AC_MSG_RESULT([$SED]) +])#AC_PROG_SED +])#m4_ifndef + +# Old name: +AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_SED], []) + + +# _LT_CHECK_SHELL_FEATURES +# ------------------------ +# Find out whether the shell is Bourne or XSI compatible, +# or has some other useful features. +m4_defun([_LT_CHECK_SHELL_FEATURES], +[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) +# Try some XSI features +xsi_shell=no +( _lt_dummy="a/b/c" + test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ + = c,a/b,b/c, \ + && eval 'test $(( 1 + 1 )) -eq 2 \ + && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ + && xsi_shell=yes +AC_MSG_RESULT([$xsi_shell]) +_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) + +AC_MSG_CHECKING([whether the shell understands "+="]) +lt_shell_append=no +( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ + >/dev/null 2>&1 \ + && lt_shell_append=yes +AC_MSG_RESULT([$lt_shell_append]) +_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi +_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac +_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl +_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl +])# _LT_CHECK_SHELL_FEATURES + + +# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) +# ------------------------------------------------------ +# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and +# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. +m4_defun([_LT_PROG_FUNCTION_REPLACE], +[dnl { +sed -e '/^$1 ()$/,/^} # $1 /c\ +$1 ()\ +{\ +m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) +} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: +]) + + +# _LT_PROG_REPLACE_SHELLFNS +# ------------------------- +# Replace existing portable implementations of several shell functions with +# equivalent extended shell implementations where those features are available.. +m4_defun([_LT_PROG_REPLACE_SHELLFNS], +[if test x"$xsi_shell" = xyes; then + _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl + case ${1} in + */*) func_dirname_result="${1%/*}${2}" ;; + * ) func_dirname_result="${3}" ;; + esac]) + + _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl + func_basename_result="${1##*/}"]) + + _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl + case ${1} in + */*) func_dirname_result="${1%/*}${2}" ;; + * ) func_dirname_result="${3}" ;; + esac + func_basename_result="${1##*/}"]) + + _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl + # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are + # positional parameters, so assign one to ordinary parameter first. + func_stripname_result=${3} + func_stripname_result=${func_stripname_result#"${1}"} + func_stripname_result=${func_stripname_result%"${2}"}]) + + _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl + func_split_long_opt_name=${1%%=*} + func_split_long_opt_arg=${1#*=}]) + + _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl + func_split_short_opt_arg=${1#??} + func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) + + _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl + case ${1} in + *.lo) func_lo2o_result=${1%.lo}.${objext} ;; + *) func_lo2o_result=${1} ;; + esac]) + + _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) + + _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) + + _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) +fi + +if test x"$lt_shell_append" = xyes; then + _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) + + _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl + func_quote_for_eval "${2}" +dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ + eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) + + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi + +if test x"$_lt_function_replace_fail" = x":"; then + AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) +fi +]) + +# _LT_PATH_CONVERSION_FUNCTIONS +# ----------------------------- +# Determine which file name conversion functions should be used by +# func_to_host_file (and, implicitly, by func_to_host_path). These are needed +# for certain cross-compile configurations and native mingw. +m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_MSG_CHECKING([how to convert $build file names to $host format]) +AC_CACHE_VAL(lt_cv_to_host_file_cmd, +[case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac +]) +to_host_file_cmd=$lt_cv_to_host_file_cmd +AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) +_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], + [0], [convert $build file names to $host format])dnl + +AC_MSG_CHECKING([how to convert $build file names to toolchain format]) +AC_CACHE_VAL(lt_cv_to_tool_file_cmd, +[#assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac +]) +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) +_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], + [0], [convert $build files to toolchain format])dnl +])# _LT_PATH_CONVERSION_FUNCTIONS diff --git a/contrib/ntp/sntp/libevent/m4/ltoptions.m4 b/contrib/ntp/sntp/libevent/m4/ltoptions.m4 new file mode 100644 index 000000000..17cfd51c0 --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/ltoptions.m4 @@ -0,0 +1,369 @@ +# Helper functions for option handling. -*- Autoconf -*- +# +# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, +# Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 7 ltoptions.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) + + +# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) +# ------------------------------------------ +m4_define([_LT_MANGLE_OPTION], +[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) + + +# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) +# --------------------------------------- +# Set option OPTION-NAME for macro MACRO-NAME, and if there is a +# matching handler defined, dispatch to it. Other OPTION-NAMEs are +# saved as a flag. +m4_define([_LT_SET_OPTION], +[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl +m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), + _LT_MANGLE_DEFUN([$1], [$2]), + [m4_warning([Unknown $1 option `$2'])])[]dnl +]) + + +# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) +# ------------------------------------------------------------ +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +m4_define([_LT_IF_OPTION], +[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) + + +# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) +# ------------------------------------------------------- +# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME +# are set. +m4_define([_LT_UNLESS_OPTIONS], +[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), + [m4_define([$0_found])])])[]dnl +m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 +])[]dnl +]) + + +# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) +# ---------------------------------------- +# OPTION-LIST is a space-separated list of Libtool options associated +# with MACRO-NAME. If any OPTION has a matching handler declared with +# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about +# the unknown option and exit. +m4_defun([_LT_SET_OPTIONS], +[# Set options +m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [_LT_SET_OPTION([$1], _LT_Option)]) + +m4_if([$1],[LT_INIT],[ + dnl + dnl Simply set some default values (i.e off) if boolean options were not + dnl specified: + _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no + ]) + _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no + ]) + dnl + dnl If no reference was made to various pairs of opposing options, then + dnl we run the default mode handler for the pair. For example, if neither + dnl `shared' nor `disable-shared' was passed, we enable building of shared + dnl archives by default: + _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) + _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], + [_LT_ENABLE_FAST_INSTALL]) + ]) +])# _LT_SET_OPTIONS + + +## --------------------------------- ## +## Macros to handle LT_INIT options. ## +## --------------------------------- ## + +# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) +# ----------------------------------------- +m4_define([_LT_MANGLE_DEFUN], +[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) + + +# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) +# ----------------------------------------------- +m4_define([LT_OPTION_DEFINE], +[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl +])# LT_OPTION_DEFINE + + +# dlopen +# ------ +LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes +]) + +AU_DEFUN([AC_LIBTOOL_DLOPEN], +[_LT_SET_OPTION([LT_INIT], [dlopen]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the `dlopen' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) + + +# win32-dll +# --------- +# Declare package support for building win32 dll's. +LT_OPTION_DEFINE([LT_INIT], [win32-dll], +[enable_win32_dll=yes + +case $host in +*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) + AC_CHECK_TOOL(AS, as, false) + AC_CHECK_TOOL(DLLTOOL, dlltool, false) + AC_CHECK_TOOL(OBJDUMP, objdump, false) + ;; +esac + +test -z "$AS" && AS=as +_LT_DECL([], [AS], [1], [Assembler program])dnl + +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl + +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl +])# win32-dll + +AU_DEFUN([AC_LIBTOOL_WIN32_DLL], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +_LT_SET_OPTION([LT_INIT], [win32-dll]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the `win32-dll' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) + + +# _LT_ENABLE_SHARED([DEFAULT]) +# ---------------------------- +# implement the --enable-shared flag, and supports the `shared' and +# `disable-shared' LT_INIT options. +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +m4_define([_LT_ENABLE_SHARED], +[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([shared], + [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], + [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac], + [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) + + _LT_DECL([build_libtool_libs], [enable_shared], [0], + [Whether or not to build shared libraries]) +])# _LT_ENABLE_SHARED + +LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) +]) + +AC_DEFUN([AC_DISABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], [disable-shared]) +]) + +AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) +AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_SHARED], []) +dnl AC_DEFUN([AM_DISABLE_SHARED], []) + + + +# _LT_ENABLE_STATIC([DEFAULT]) +# ---------------------------- +# implement the --enable-static flag, and support the `static' and +# `disable-static' LT_INIT options. +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +m4_define([_LT_ENABLE_STATIC], +[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([static], + [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], + [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac], + [enable_static=]_LT_ENABLE_STATIC_DEFAULT) + + _LT_DECL([build_old_libs], [enable_static], [0], + [Whether or not to build static libraries]) +])# _LT_ENABLE_STATIC + +LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) +]) + +AC_DEFUN([AC_DISABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], [disable-static]) +]) + +AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) +AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_STATIC], []) +dnl AC_DEFUN([AM_DISABLE_STATIC], []) + + + +# _LT_ENABLE_FAST_INSTALL([DEFAULT]) +# ---------------------------------- +# implement the --enable-fast-install flag, and support the `fast-install' +# and `disable-fast-install' LT_INIT options. +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +m4_define([_LT_ENABLE_FAST_INSTALL], +[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([fast-install], + [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], + [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac], + [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) + +_LT_DECL([fast_install], [enable_fast_install], [0], + [Whether or not to optimize for fast installation])dnl +])# _LT_ENABLE_FAST_INSTALL + +LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) + +# Old names: +AU_DEFUN([AC_ENABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the `fast-install' option into LT_INIT's first parameter.]) +]) + +AU_DEFUN([AC_DISABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the `disable-fast-install' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) +dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) + + +# _LT_WITH_PIC([MODE]) +# -------------------- +# implement the --with-pic flag, and support the `pic-only' and `no-pic' +# LT_INIT options. +# MODE is either `yes' or `no'. If omitted, it defaults to `both'. +m4_define([_LT_WITH_PIC], +[AC_ARG_WITH([pic], + [AS_HELP_STRING([--with-pic], + [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], + [pic_mode="$withval"], + [pic_mode=default]) + +test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) + +_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl +])# _LT_WITH_PIC + +LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) + +# Old name: +AU_DEFUN([AC_LIBTOOL_PICMODE], +[_LT_SET_OPTION([LT_INIT], [pic-only]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the `pic-only' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) + +## ----------------- ## +## LTDL_INIT Options ## +## ----------------- ## + +m4_define([_LTDL_MODE], []) +LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], + [m4_define([_LTDL_MODE], [nonrecursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [recursive], + [m4_define([_LTDL_MODE], [recursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [subproject], + [m4_define([_LTDL_MODE], [subproject])]) + +m4_define([_LTDL_TYPE], []) +LT_OPTION_DEFINE([LTDL_INIT], [installable], + [m4_define([_LTDL_TYPE], [installable])]) +LT_OPTION_DEFINE([LTDL_INIT], [convenience], + [m4_define([_LTDL_TYPE], [convenience])]) diff --git a/contrib/ntp/sntp/libevent/m4/ltsugar.m4 b/contrib/ntp/sntp/libevent/m4/ltsugar.m4 new file mode 100644 index 000000000..9000a057d --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/ltsugar.m4 @@ -0,0 +1,123 @@ +# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- +# +# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 6 ltsugar.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) + + +# lt_join(SEP, ARG1, [ARG2...]) +# ----------------------------- +# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their +# associated separator. +# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier +# versions in m4sugar had bugs. +m4_define([lt_join], +[m4_if([$#], [1], [], + [$#], [2], [[$2]], + [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) +m4_define([_lt_join], +[m4_if([$#$2], [2], [], + [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) + + +# lt_car(LIST) +# lt_cdr(LIST) +# ------------ +# Manipulate m4 lists. +# These macros are necessary as long as will still need to support +# Autoconf-2.59 which quotes differently. +m4_define([lt_car], [[$1]]) +m4_define([lt_cdr], +[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], + [$#], 1, [], + [m4_dquote(m4_shift($@))])]) +m4_define([lt_unquote], $1) + + +# lt_append(MACRO-NAME, STRING, [SEPARATOR]) +# ------------------------------------------ +# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. +# Note that neither SEPARATOR nor STRING are expanded; they are appended +# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). +# No SEPARATOR is output if MACRO-NAME was previously undefined (different +# than defined and empty). +# +# This macro is needed until we can rely on Autoconf 2.62, since earlier +# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. +m4_define([lt_append], +[m4_define([$1], + m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) + + + +# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) +# ---------------------------------------------------------- +# Produce a SEP delimited list of all paired combinations of elements of +# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list +# has the form PREFIXmINFIXSUFFIXn. +# Needed until we can rely on m4_combine added in Autoconf 2.62. +m4_define([lt_combine], +[m4_if(m4_eval([$# > 3]), [1], + [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl +[[m4_foreach([_Lt_prefix], [$2], + [m4_foreach([_Lt_suffix], + ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, + [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) + + +# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) +# ----------------------------------------------------------------------- +# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited +# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. +m4_define([lt_if_append_uniq], +[m4_ifdef([$1], + [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], + [lt_append([$1], [$2], [$3])$4], + [$5])], + [lt_append([$1], [$2], [$3])$4])]) + + +# lt_dict_add(DICT, KEY, VALUE) +# ----------------------------- +m4_define([lt_dict_add], +[m4_define([$1($2)], [$3])]) + + +# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) +# -------------------------------------------- +m4_define([lt_dict_add_subkey], +[m4_define([$1($2:$3)], [$4])]) + + +# lt_dict_fetch(DICT, KEY, [SUBKEY]) +# ---------------------------------- +m4_define([lt_dict_fetch], +[m4_ifval([$3], + m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), + m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) + + +# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) +# ----------------------------------------------------------------- +m4_define([lt_if_dict_fetch], +[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], + [$5], + [$6])]) + + +# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) +# -------------------------------------------------------------- +m4_define([lt_dict_filter], +[m4_if([$5], [], [], + [lt_join(m4_quote(m4_default([$4], [[, ]])), + lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), + [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl +]) diff --git a/contrib/ntp/sntp/libevent/m4/ltversion.m4 b/contrib/ntp/sntp/libevent/m4/ltversion.m4 new file mode 100644 index 000000000..07a8602d4 --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/ltversion.m4 @@ -0,0 +1,23 @@ +# ltversion.m4 -- version numbers -*- Autoconf -*- +# +# Copyright (C) 2004 Free Software Foundation, Inc. +# Written by Scott James Remnant, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# @configure_input@ + +# serial 3337 ltversion.m4 +# This file is part of GNU Libtool + +m4_define([LT_PACKAGE_VERSION], [2.4.2]) +m4_define([LT_PACKAGE_REVISION], [1.3337]) + +AC_DEFUN([LTVERSION_VERSION], +[macro_version='2.4.2' +macro_revision='1.3337' +_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) +_LT_DECL(, macro_revision, 0) +]) diff --git a/contrib/ntp/sntp/libevent/m4/lt~obsolete.m4 b/contrib/ntp/sntp/libevent/m4/lt~obsolete.m4 new file mode 100644 index 000000000..c573da90c --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/lt~obsolete.m4 @@ -0,0 +1,98 @@ +# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- +# +# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. +# Written by Scott James Remnant, 2004. +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 5 lt~obsolete.m4 + +# These exist entirely to fool aclocal when bootstrapping libtool. +# +# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) +# which have later been changed to m4_define as they aren't part of the +# exported API, or moved to Autoconf or Automake where they belong. +# +# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN +# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us +# using a macro with the same name in our local m4/libtool.m4 it'll +# pull the old libtool.m4 in (it doesn't see our shiny new m4_define +# and doesn't know about Autoconf macros at all.) +# +# So we provide this file, which has a silly filename so it's always +# included after everything else. This provides aclocal with the +# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything +# because those macros already exist, or will be overwritten later. +# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. +# +# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. +# Yes, that means every name once taken will need to remain here until +# we give up compatibility with versions before 1.7, at which point +# we need to keep only those names which we still refer to. + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) + +m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) +m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) +m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) +m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) +m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) +m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) +m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) +m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) +m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) +m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) +m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) +m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) +m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) +m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) +m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) +m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) +m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) +m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) +m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) +m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) +m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) +m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) +m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) +m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) +m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) +m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) +m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) +m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) +m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) +m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) +m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) +m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) +m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) +m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) +m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) +m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) +m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) +m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) +m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) +m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) +m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) +m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) +m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) +m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) +m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) +m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) +m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) +m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) +m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) +m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) +m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) diff --git a/contrib/ntp/sntp/libevent/m4/ntp_pkg_config.m4 b/contrib/ntp/sntp/libevent/m4/ntp_pkg_config.m4 new file mode 100644 index 000000000..1bce8a6e4 --- /dev/null +++ b/contrib/ntp/sntp/libevent/m4/ntp_pkg_config.m4 @@ -0,0 +1,27 @@ +dnl NTP_PKG_CONFIG -*- Autoconf -*- +dnl +dnl Look for pkg-config, which must be at least +dnl $ntp_pkgconfig_min_version. +dnl +AC_DEFUN([NTP_PKG_CONFIG], [ + +dnl lower the minimum version if you find an earlier one works +ntp_pkgconfig_min_version='0.15.0' +AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) +AS_UNSET([ac_cv_path_PKG_CONFIG]) +AS_UNSET([ac_cv_path_ac_pt_PKG_CONFIG]) + +case "$PKG_CONFIG" in + /*) + AC_MSG_CHECKING([if pkg-config is at least version $ntp_pkgconfig_min_version]) + if $PKG_CONFIG --atleast-pkgconfig-version $ntp_pkgconfig_min_version; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + PKG_CONFIG="" + fi + ;; +esac + +]) dnl NTP_PKG_CONFIG + diff --git a/contrib/ntp/sntp/libevent/make-event-config.sed b/contrib/ntp/sntp/libevent/make-event-config.sed new file mode 100644 index 000000000..e31018a2d --- /dev/null +++ b/contrib/ntp/sntp/libevent/make-event-config.sed @@ -0,0 +1,23 @@ +# Sed script to postprocess config.h into event-config.h. + +1i\ +/* event2/event-config.h\ + *\ + * This file was generated by autoconf when libevent was built, and post-\ + * processed by Libevent so that its macros would have a uniform prefix.\ + *\ + * DO NOT EDIT THIS FILE.\ + *\ + * Do not rely on macros in this file existing in later versions.\ + */\ +\ +#ifndef EVENT2_EVENT_CONFIG_H_INCLUDED_\ +#define EVENT2_EVENT_CONFIG_H_INCLUDED_\ + +$a\ +\ +#endif /* event2/event-config.h */ + +s/#\( *\)define /#\1define EVENT__/ +s/#\( *\)undef /#\1undef EVENT__/ +s/#\( *\)if\(n*\)def /#\1if\2def EVENT__/ diff --git a/contrib/ntp/sntp/libevent/minheap-internal.h b/contrib/ntp/sntp/libevent/minheap-internal.h new file mode 100644 index 000000000..b3b6f1fd4 --- /dev/null +++ b/contrib/ntp/sntp/libevent/minheap-internal.h @@ -0,0 +1,188 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Copyright (c) 2006 Maxim Yegorushkin + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef MINHEAP_INTERNAL_H_INCLUDED_ +#define MINHEAP_INTERNAL_H_INCLUDED_ + +#include "event2/event-config.h" +#include "evconfig-private.h" +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/util.h" +#include "util-internal.h" +#include "mm-internal.h" + +typedef struct min_heap +{ + struct event** p; + unsigned n, a; +} min_heap_t; + +static inline void min_heap_ctor_(min_heap_t* s); +static inline void min_heap_dtor_(min_heap_t* s); +static inline void min_heap_elem_init_(struct event* e); +static inline int min_heap_elt_is_top_(const struct event *e); +static inline int min_heap_empty_(min_heap_t* s); +static inline unsigned min_heap_size_(min_heap_t* s); +static inline struct event* min_heap_top_(min_heap_t* s); +static inline int min_heap_reserve_(min_heap_t* s, unsigned n); +static inline int min_heap_push_(min_heap_t* s, struct event* e); +static inline struct event* min_heap_pop_(min_heap_t* s); +static inline int min_heap_adjust_(min_heap_t *s, struct event* e); +static inline int min_heap_erase_(min_heap_t* s, struct event* e); +static inline void min_heap_shift_up_(min_heap_t* s, unsigned hole_index, struct event* e); +static inline void min_heap_shift_up_unconditional_(min_heap_t* s, unsigned hole_index, struct event* e); +static inline void min_heap_shift_down_(min_heap_t* s, unsigned hole_index, struct event* e); + +#define min_heap_elem_greater(a, b) \ + (evutil_timercmp(&(a)->ev_timeout, &(b)->ev_timeout, >)) + +void min_heap_ctor_(min_heap_t* s) { s->p = 0; s->n = 0; s->a = 0; } +void min_heap_dtor_(min_heap_t* s) { if (s->p) mm_free(s->p); } +void min_heap_elem_init_(struct event* e) { e->ev_timeout_pos.min_heap_idx = -1; } +int min_heap_empty_(min_heap_t* s) { return 0u == s->n; } +unsigned min_heap_size_(min_heap_t* s) { return s->n; } +struct event* min_heap_top_(min_heap_t* s) { return s->n ? *s->p : 0; } + +int min_heap_push_(min_heap_t* s, struct event* e) +{ + if (min_heap_reserve_(s, s->n + 1)) + return -1; + min_heap_shift_up_(s, s->n++, e); + return 0; +} + +struct event* min_heap_pop_(min_heap_t* s) +{ + if (s->n) + { + struct event* e = *s->p; + min_heap_shift_down_(s, 0u, s->p[--s->n]); + e->ev_timeout_pos.min_heap_idx = -1; + return e; + } + return 0; +} + +int min_heap_elt_is_top_(const struct event *e) +{ + return e->ev_timeout_pos.min_heap_idx == 0; +} + +int min_heap_erase_(min_heap_t* s, struct event* e) +{ + if (-1 != e->ev_timeout_pos.min_heap_idx) + { + struct event *last = s->p[--s->n]; + unsigned parent = (e->ev_timeout_pos.min_heap_idx - 1) / 2; + /* we replace e with the last element in the heap. We might need to + shift it upward if it is less than its parent, or downward if it is + greater than one or both its children. Since the children are known + to be less than the parent, it can't need to shift both up and + down. */ + if (e->ev_timeout_pos.min_heap_idx > 0 && min_heap_elem_greater(s->p[parent], last)) + min_heap_shift_up_unconditional_(s, e->ev_timeout_pos.min_heap_idx, last); + else + min_heap_shift_down_(s, e->ev_timeout_pos.min_heap_idx, last); + e->ev_timeout_pos.min_heap_idx = -1; + return 0; + } + return -1; +} + +int min_heap_adjust_(min_heap_t *s, struct event *e) +{ + if (-1 == e->ev_timeout_pos.min_heap_idx) { + return min_heap_push_(s, e); + } else { + unsigned parent = (e->ev_timeout_pos.min_heap_idx - 1) / 2; + /* The position of e has changed; we shift it up or down + * as needed. We can't need to do both. */ + if (e->ev_timeout_pos.min_heap_idx > 0 && min_heap_elem_greater(s->p[parent], e)) + min_heap_shift_up_unconditional_(s, e->ev_timeout_pos.min_heap_idx, e); + else + min_heap_shift_down_(s, e->ev_timeout_pos.min_heap_idx, e); + return 0; + } +} + +int min_heap_reserve_(min_heap_t* s, unsigned n) +{ + if (s->a < n) + { + struct event** p; + unsigned a = s->a ? s->a * 2 : 8; + if (a < n) + a = n; + if (!(p = (struct event**)mm_realloc(s->p, a * sizeof *p))) + return -1; + s->p = p; + s->a = a; + } + return 0; +} + +void min_heap_shift_up_unconditional_(min_heap_t* s, unsigned hole_index, struct event* e) +{ + unsigned parent = (hole_index - 1) / 2; + do + { + (s->p[hole_index] = s->p[parent])->ev_timeout_pos.min_heap_idx = hole_index; + hole_index = parent; + parent = (hole_index - 1) / 2; + } while (hole_index && min_heap_elem_greater(s->p[parent], e)); + (s->p[hole_index] = e)->ev_timeout_pos.min_heap_idx = hole_index; +} + +void min_heap_shift_up_(min_heap_t* s, unsigned hole_index, struct event* e) +{ + unsigned parent = (hole_index - 1) / 2; + while (hole_index && min_heap_elem_greater(s->p[parent], e)) + { + (s->p[hole_index] = s->p[parent])->ev_timeout_pos.min_heap_idx = hole_index; + hole_index = parent; + parent = (hole_index - 1) / 2; + } + (s->p[hole_index] = e)->ev_timeout_pos.min_heap_idx = hole_index; +} + +void min_heap_shift_down_(min_heap_t* s, unsigned hole_index, struct event* e) +{ + unsigned min_child = 2 * (hole_index + 1); + while (min_child <= s->n) + { + min_child -= min_child == s->n || min_heap_elem_greater(s->p[min_child], s->p[min_child - 1]); + if (!(min_heap_elem_greater(e, s->p[min_child]))) + break; + (s->p[hole_index] = s->p[min_child])->ev_timeout_pos.min_heap_idx = hole_index; + hole_index = min_child; + min_child = 2 * (hole_index + 1); + } + (s->p[hole_index] = e)->ev_timeout_pos.min_heap_idx = hole_index; +} + +#endif /* MINHEAP_INTERNAL_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/mm-internal.h b/contrib/ntp/sntp/libevent/mm-internal.h new file mode 100644 index 000000000..4ba6fce4a --- /dev/null +++ b/contrib/ntp/sntp/libevent/mm-internal.h @@ -0,0 +1,87 @@ +/* + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef MM_INTERNAL_H_INCLUDED_ +#define MM_INTERNAL_H_INCLUDED_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#ifndef EVENT__DISABLE_MM_REPLACEMENT +/* Internal use only: Memory allocation functions. We give them nice short + * mm_names for our own use, but make sure that the symbols have longer names + * so they don't conflict with other libraries (like, say, libmm). */ + +/** Allocate uninitialized memory. + * + * @return On success, return a pointer to sz newly allocated bytes. + * On failure, set errno to ENOMEM and return NULL. + * If the argument sz is 0, simply return NULL. + */ +void *event_mm_malloc_(size_t sz); + +/** Allocate memory initialized to zero. + * + * @return On success, return a pointer to (count * size) newly allocated + * bytes, initialized to zero. + * On failure, or if the product would result in an integer overflow, + * set errno to ENOMEM and return NULL. + * If either arguments are 0, simply return NULL. + */ +void *event_mm_calloc_(size_t count, size_t size); + +/** Duplicate a string. + * + * @return On success, return a pointer to a newly allocated duplicate + * of a string. + * Set errno to ENOMEM and return NULL if a memory allocation error + * occurs (or would occur) in the process. + * If the argument str is NULL, set errno to EINVAL and return NULL. + */ +char *event_mm_strdup_(const char *str); + +void *event_mm_realloc_(void *p, size_t sz); +void event_mm_free_(void *p); +#define mm_malloc(sz) event_mm_malloc_(sz) +#define mm_calloc(count, size) event_mm_calloc_((count), (size)) +#define mm_strdup(s) event_mm_strdup_(s) +#define mm_realloc(p, sz) event_mm_realloc_((p), (sz)) +#define mm_free(p) event_mm_free_(p) +#else +#define mm_malloc(sz) malloc(sz) +#define mm_calloc(n, sz) calloc((n), (sz)) +#define mm_strdup(s) strdup(s) +#define mm_realloc(p, sz) realloc((p), (sz)) +#define mm_free(p) free(p) +#endif + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/contrib/ntp/sntp/libevent/poll.c b/contrib/ntp/sntp/libevent/poll.c new file mode 100644 index 000000000..51475934b --- /dev/null +++ b/contrib/ntp/sntp/libevent/poll.c @@ -0,0 +1,341 @@ +/* $OpenBSD: poll.c,v 1.2 2002/06/25 15:50:15 mickey Exp $ */ + +/* + * Copyright 2000-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_POLL + +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "event-internal.h" +#include "evsignal-internal.h" +#include "log-internal.h" +#include "evmap-internal.h" +#include "event2/thread.h" +#include "evthread-internal.h" +#include "time-internal.h" + +struct pollidx { + int idxplus1; +}; + +struct pollop { + int event_count; /* Highest number alloc */ + int nfds; /* Highest number used */ + int realloc_copy; /* True iff we must realloc + * event_set_copy */ + struct pollfd *event_set; + struct pollfd *event_set_copy; +}; + +static void *poll_init(struct event_base *); +static int poll_add(struct event_base *, int, short old, short events, void *idx); +static int poll_del(struct event_base *, int, short old, short events, void *idx); +static int poll_dispatch(struct event_base *, struct timeval *); +static void poll_dealloc(struct event_base *); + +const struct eventop pollops = { + "poll", + poll_init, + poll_add, + poll_del, + poll_dispatch, + poll_dealloc, + 0, /* doesn't need_reinit */ + EV_FEATURE_FDS, + sizeof(struct pollidx), +}; + +static void * +poll_init(struct event_base *base) +{ + struct pollop *pollop; + + if (!(pollop = mm_calloc(1, sizeof(struct pollop)))) + return (NULL); + + evsig_init_(base); + + evutil_weakrand_seed_(&base->weakrand_seed, 0); + + return (pollop); +} + +#ifdef CHECK_INVARIANTS +static void +poll_check_ok(struct pollop *pop) +{ + int i, idx; + struct event *ev; + + for (i = 0; i < pop->fd_count; ++i) { + idx = pop->idxplus1_by_fd[i]-1; + if (idx < 0) + continue; + EVUTIL_ASSERT(pop->event_set[idx].fd == i); + } + for (i = 0; i < pop->nfds; ++i) { + struct pollfd *pfd = &pop->event_set[i]; + EVUTIL_ASSERT(pop->idxplus1_by_fd[pfd->fd] == i+1); + } +} +#else +#define poll_check_ok(pop) +#endif + +static int +poll_dispatch(struct event_base *base, struct timeval *tv) +{ + int res, i, j, nfds; + long msec = -1; + struct pollop *pop = base->evbase; + struct pollfd *event_set; + + poll_check_ok(pop); + + nfds = pop->nfds; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (base->th_base_lock) { + /* If we're using this backend in a multithreaded setting, + * then we need to work on a copy of event_set, so that we can + * let other threads modify the main event_set while we're + * polling. If we're not multithreaded, then we'll skip the + * copy step here to save memory and time. */ + if (pop->realloc_copy) { + struct pollfd *tmp = mm_realloc(pop->event_set_copy, + pop->event_count * sizeof(struct pollfd)); + if (tmp == NULL) { + event_warn("realloc"); + return -1; + } + pop->event_set_copy = tmp; + pop->realloc_copy = 0; + } + memcpy(pop->event_set_copy, pop->event_set, + sizeof(struct pollfd)*nfds); + event_set = pop->event_set_copy; + } else { + event_set = pop->event_set; + } +#else + event_set = pop->event_set; +#endif + + if (tv != NULL) { + msec = evutil_tv_to_msec_(tv); + if (msec < 0 || msec > INT_MAX) + msec = INT_MAX; + } + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + res = poll(event_set, nfds, msec); + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + if (res == -1) { + if (errno != EINTR) { + event_warn("poll"); + return (-1); + } + + return (0); + } + + event_debug(("%s: poll reports %d", __func__, res)); + + if (res == 0 || nfds == 0) + return (0); + + i = evutil_weakrand_range_(&base->weakrand_seed, nfds); + for (j = 0; j < nfds; j++) { + int what; + if (++i == nfds) + i = 0; + what = event_set[i].revents; + if (!what) + continue; + + res = 0; + + /* If the file gets closed notify */ + if (what & (POLLHUP|POLLERR)) + what |= POLLIN|POLLOUT; + if (what & POLLIN) + res |= EV_READ; + if (what & POLLOUT) + res |= EV_WRITE; + if (res == 0) + continue; + + evmap_io_active_(base, event_set[i].fd, res); + } + + return (0); +} + +static int +poll_add(struct event_base *base, int fd, short old, short events, void *idx_) +{ + struct pollop *pop = base->evbase; + struct pollfd *pfd = NULL; + struct pollidx *idx = idx_; + int i; + + EVUTIL_ASSERT((events & EV_SIGNAL) == 0); + if (!(events & (EV_READ|EV_WRITE))) + return (0); + + poll_check_ok(pop); + if (pop->nfds + 1 >= pop->event_count) { + struct pollfd *tmp_event_set; + int tmp_event_count; + + if (pop->event_count < 32) + tmp_event_count = 32; + else + tmp_event_count = pop->event_count * 2; + + /* We need more file descriptors */ + tmp_event_set = mm_realloc(pop->event_set, + tmp_event_count * sizeof(struct pollfd)); + if (tmp_event_set == NULL) { + event_warn("realloc"); + return (-1); + } + pop->event_set = tmp_event_set; + + pop->event_count = tmp_event_count; + pop->realloc_copy = 1; + } + + i = idx->idxplus1 - 1; + + if (i >= 0) { + pfd = &pop->event_set[i]; + } else { + i = pop->nfds++; + pfd = &pop->event_set[i]; + pfd->events = 0; + pfd->fd = fd; + idx->idxplus1 = i + 1; + } + + pfd->revents = 0; + if (events & EV_WRITE) + pfd->events |= POLLOUT; + if (events & EV_READ) + pfd->events |= POLLIN; + poll_check_ok(pop); + + return (0); +} + +/* + * Nothing to be done here. + */ + +static int +poll_del(struct event_base *base, int fd, short old, short events, void *idx_) +{ + struct pollop *pop = base->evbase; + struct pollfd *pfd = NULL; + struct pollidx *idx = idx_; + int i; + + EVUTIL_ASSERT((events & EV_SIGNAL) == 0); + if (!(events & (EV_READ|EV_WRITE))) + return (0); + + poll_check_ok(pop); + i = idx->idxplus1 - 1; + if (i < 0) + return (-1); + + /* Do we still want to read or write? */ + pfd = &pop->event_set[i]; + if (events & EV_READ) + pfd->events &= ~POLLIN; + if (events & EV_WRITE) + pfd->events &= ~POLLOUT; + poll_check_ok(pop); + if (pfd->events) + /* Another event cares about that fd. */ + return (0); + + /* Okay, so we aren't interested in that fd anymore. */ + idx->idxplus1 = 0; + + --pop->nfds; + if (i != pop->nfds) { + /* + * Shift the last pollfd down into the now-unoccupied + * position. + */ + memcpy(&pop->event_set[i], &pop->event_set[pop->nfds], + sizeof(struct pollfd)); + idx = evmap_io_get_fdinfo_(&base->io, pop->event_set[i].fd); + EVUTIL_ASSERT(idx); + EVUTIL_ASSERT(idx->idxplus1 == pop->nfds + 1); + idx->idxplus1 = i + 1; + } + + poll_check_ok(pop); + return (0); +} + +static void +poll_dealloc(struct event_base *base) +{ + struct pollop *pop = base->evbase; + + evsig_dealloc_(base); + if (pop->event_set) + mm_free(pop->event_set); + if (pop->event_set_copy) + mm_free(pop->event_set_copy); + + memset(pop, 0, sizeof(struct pollop)); + mm_free(pop); +} + +#endif /* EVENT__HAVE_POLL */ diff --git a/contrib/ntp/sntp/libevent/ratelim-internal.h b/contrib/ntp/sntp/libevent/ratelim-internal.h new file mode 100644 index 000000000..6cc1cdde2 --- /dev/null +++ b/contrib/ntp/sntp/libevent/ratelim-internal.h @@ -0,0 +1,105 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef RATELIM_INTERNAL_H_INCLUDED_ +#define RATELIM_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "event2/util.h" + +/** A token bucket is an internal structure that tracks how many bytes we are + * currently willing to read or write on a given bufferevent or group of + * bufferevents */ +struct ev_token_bucket { + /** How many bytes are we willing to read or write right now? These + * values are signed so that we can do "defecit spending" */ + ev_ssize_t read_limit, write_limit; + /** When was this bucket last updated? Measured in abstract 'ticks' + * relative to the token bucket configuration. */ + ev_uint32_t last_updated; +}; + +/** Configuration info for a token bucket or set of token buckets. */ +struct ev_token_bucket_cfg { + /** How many bytes are we willing to read on average per tick? */ + size_t read_rate; + /** How many bytes are we willing to read at most in any one tick? */ + size_t read_maximum; + /** How many bytes are we willing to write on average per tick? */ + size_t write_rate; + /** How many bytes are we willing to write at most in any one tick? */ + size_t write_maximum; + + /* How long is a tick? Note that fractions of a millisecond are + * ignored. */ + struct timeval tick_timeout; + + /* How long is a tick, in milliseconds? Derived from tick_timeout. */ + unsigned msec_per_tick; +}; + +/** The current tick is 'current_tick': add bytes to 'bucket' as specified in + * 'cfg'. */ +int ev_token_bucket_update_(struct ev_token_bucket *bucket, + const struct ev_token_bucket_cfg *cfg, + ev_uint32_t current_tick); + +/** In which tick does 'tv' fall according to 'cfg'? Note that ticks can + * overflow easily; your code needs to handle this. */ +ev_uint32_t ev_token_bucket_get_tick_(const struct timeval *tv, + const struct ev_token_bucket_cfg *cfg); + +/** Adjust 'bucket' to respect 'cfg', and note that it was last updated in + * 'current_tick'. If 'reinitialize' is true, we are changing the + * configuration of 'bucket'; otherwise, we are setting it up for the first + * time. + */ +int ev_token_bucket_init_(struct ev_token_bucket *bucket, + const struct ev_token_bucket_cfg *cfg, + ev_uint32_t current_tick, + int reinitialize); + +int bufferevent_remove_from_rate_limit_group_internal_(struct bufferevent *bev, + int unsuspend); + +/** Decrease the read limit of 'b' by 'n' bytes */ +#define ev_token_bucket_decrement_read(b,n) \ + do { \ + (b)->read_limit -= (n); \ + } while (0) +/** Decrease the write limit of 'b' by 'n' bytes */ +#define ev_token_bucket_decrement_write(b,n) \ + do { \ + (b)->write_limit -= (n); \ + } while (0) + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/contrib/ntp/sntp/libevent/select.c b/contrib/ntp/sntp/libevent/select.c new file mode 100644 index 000000000..8ae53cc11 --- /dev/null +++ b/contrib/ntp/sntp/libevent/select.c @@ -0,0 +1,346 @@ +/* $OpenBSD: select.c,v 1.2 2002/06/25 15:50:15 mickey Exp $ */ + +/* + * Copyright 2000-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef EVENT__HAVE_SELECT + +#ifdef __APPLE__ +/* Apple wants us to define this if we might ever pass more than + * FD_SETSIZE bits to select(). */ +#define _DARWIN_UNLIMITED_SELECT +#endif + +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#ifdef EVENT__HAVE_SYS_SELECT_H +#include +#endif +#include +#include +#include +#include +#include +#include +#include + +#include "event-internal.h" +#include "evsignal-internal.h" +#include "event2/thread.h" +#include "evthread-internal.h" +#include "log-internal.h" +#include "evmap-internal.h" + +#ifndef EVENT__HAVE_FD_MASK +/* This type is mandatory, but Android doesn't define it. */ +typedef unsigned long fd_mask; +#endif + +#ifndef NFDBITS +#define NFDBITS (sizeof(fd_mask)*8) +#endif + +/* Divide positive x by y, rounding up. */ +#define DIV_ROUNDUP(x, y) (((x)+((y)-1))/(y)) + +/* How many bytes to allocate for N fds? */ +#define SELECT_ALLOC_SIZE(n) \ + (DIV_ROUNDUP(n, NFDBITS) * sizeof(fd_mask)) + +struct selectop { + int event_fds; /* Highest fd in fd set */ + int event_fdsz; + int resize_out_sets; + fd_set *event_readset_in; + fd_set *event_writeset_in; + fd_set *event_readset_out; + fd_set *event_writeset_out; +}; + +static void *select_init(struct event_base *); +static int select_add(struct event_base *, int, short old, short events, void*); +static int select_del(struct event_base *, int, short old, short events, void*); +static int select_dispatch(struct event_base *, struct timeval *); +static void select_dealloc(struct event_base *); + +const struct eventop selectops = { + "select", + select_init, + select_add, + select_del, + select_dispatch, + select_dealloc, + 0, /* doesn't need reinit. */ + EV_FEATURE_FDS, + 0, +}; + +static int select_resize(struct selectop *sop, int fdsz); +static void select_free_selectop(struct selectop *sop); + +static void * +select_init(struct event_base *base) +{ + struct selectop *sop; + + if (!(sop = mm_calloc(1, sizeof(struct selectop)))) + return (NULL); + + if (select_resize(sop, SELECT_ALLOC_SIZE(32 + 1))) { + select_free_selectop(sop); + return (NULL); + } + + evsig_init_(base); + + evutil_weakrand_seed_(&base->weakrand_seed, 0); + + return (sop); +} + +#ifdef CHECK_INVARIANTS +static void +check_selectop(struct selectop *sop) +{ + /* nothing to be done here */ +} +#else +#define check_selectop(sop) do { (void) sop; } while (0) +#endif + +static int +select_dispatch(struct event_base *base, struct timeval *tv) +{ + int res=0, i, j, nfds; + struct selectop *sop = base->evbase; + + check_selectop(sop); + if (sop->resize_out_sets) { + fd_set *readset_out=NULL, *writeset_out=NULL; + size_t sz = sop->event_fdsz; + if (!(readset_out = mm_realloc(sop->event_readset_out, sz))) + return (-1); + sop->event_readset_out = readset_out; + if (!(writeset_out = mm_realloc(sop->event_writeset_out, sz))) { + /* We don't free readset_out here, since it was + * already successfully reallocated. The next time + * we call select_dispatch, the realloc will be a + * no-op. */ + return (-1); + } + sop->event_writeset_out = writeset_out; + sop->resize_out_sets = 0; + } + + memcpy(sop->event_readset_out, sop->event_readset_in, + sop->event_fdsz); + memcpy(sop->event_writeset_out, sop->event_writeset_in, + sop->event_fdsz); + + nfds = sop->event_fds+1; + + EVBASE_RELEASE_LOCK(base, th_base_lock); + + res = select(nfds, sop->event_readset_out, + sop->event_writeset_out, NULL, tv); + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + + check_selectop(sop); + + if (res == -1) { + if (errno != EINTR) { + event_warn("select"); + return (-1); + } + + return (0); + } + + event_debug(("%s: select reports %d", __func__, res)); + + check_selectop(sop); + i = evutil_weakrand_range_(&base->weakrand_seed, nfds); + for (j = 0; j < nfds; ++j) { + if (++i >= nfds) + i = 0; + res = 0; + if (FD_ISSET(i, sop->event_readset_out)) + res |= EV_READ; + if (FD_ISSET(i, sop->event_writeset_out)) + res |= EV_WRITE; + + if (res == 0) + continue; + + evmap_io_active_(base, i, res); + } + check_selectop(sop); + + return (0); +} + +static int +select_resize(struct selectop *sop, int fdsz) +{ + fd_set *readset_in = NULL; + fd_set *writeset_in = NULL; + + if (sop->event_readset_in) + check_selectop(sop); + + if ((readset_in = mm_realloc(sop->event_readset_in, fdsz)) == NULL) + goto error; + sop->event_readset_in = readset_in; + if ((writeset_in = mm_realloc(sop->event_writeset_in, fdsz)) == NULL) { + /* Note that this will leave event_readset_in expanded. + * That's okay; we wouldn't want to free it, since that would + * change the semantics of select_resize from "expand the + * readset_in and writeset_in, or return -1" to "expand the + * *set_in members, or trash them and return -1." + */ + goto error; + } + sop->event_writeset_in = writeset_in; + sop->resize_out_sets = 1; + + memset((char *)sop->event_readset_in + sop->event_fdsz, 0, + fdsz - sop->event_fdsz); + memset((char *)sop->event_writeset_in + sop->event_fdsz, 0, + fdsz - sop->event_fdsz); + + sop->event_fdsz = fdsz; + check_selectop(sop); + + return (0); + + error: + event_warn("malloc"); + return (-1); +} + + +static int +select_add(struct event_base *base, int fd, short old, short events, void *p) +{ + struct selectop *sop = base->evbase; + (void) p; + + EVUTIL_ASSERT((events & EV_SIGNAL) == 0); + check_selectop(sop); + /* + * Keep track of the highest fd, so that we can calculate the size + * of the fd_sets for select(2) + */ + if (sop->event_fds < fd) { + int fdsz = sop->event_fdsz; + + if (fdsz < (int)sizeof(fd_mask)) + fdsz = (int)sizeof(fd_mask); + + /* In theory we should worry about overflow here. In + * reality, though, the highest fd on a unixy system will + * not overflow here. XXXX */ + while (fdsz < (int) SELECT_ALLOC_SIZE(fd + 1)) + fdsz *= 2; + + if (fdsz != sop->event_fdsz) { + if (select_resize(sop, fdsz)) { + check_selectop(sop); + return (-1); + } + } + + sop->event_fds = fd; + } + + if (events & EV_READ) + FD_SET(fd, sop->event_readset_in); + if (events & EV_WRITE) + FD_SET(fd, sop->event_writeset_in); + check_selectop(sop); + + return (0); +} + +/* + * Nothing to be done here. + */ + +static int +select_del(struct event_base *base, int fd, short old, short events, void *p) +{ + struct selectop *sop = base->evbase; + (void)p; + + EVUTIL_ASSERT((events & EV_SIGNAL) == 0); + check_selectop(sop); + + if (sop->event_fds < fd) { + check_selectop(sop); + return (0); + } + + if (events & EV_READ) + FD_CLR(fd, sop->event_readset_in); + + if (events & EV_WRITE) + FD_CLR(fd, sop->event_writeset_in); + + check_selectop(sop); + return (0); +} + +static void +select_free_selectop(struct selectop *sop) +{ + if (sop->event_readset_in) + mm_free(sop->event_readset_in); + if (sop->event_writeset_in) + mm_free(sop->event_writeset_in); + if (sop->event_readset_out) + mm_free(sop->event_readset_out); + if (sop->event_writeset_out) + mm_free(sop->event_writeset_out); + + memset(sop, 0, sizeof(struct selectop)); + mm_free(sop); +} + +static void +select_dealloc(struct event_base *base) +{ + evsig_dealloc_(base); + + select_free_selectop(base->evbase); +} + +#endif /* EVENT__HAVE_SELECT */ diff --git a/contrib/ntp/sntp/libevent/signal.c b/contrib/ntp/sntp/libevent/signal.c new file mode 100644 index 000000000..3f4629502 --- /dev/null +++ b/contrib/ntp/sntp/libevent/signal.c @@ -0,0 +1,479 @@ +/* $OpenBSD: select.c,v 1.2 2002/06/25 15:50:15 mickey Exp $ */ + +/* + * Copyright 2000-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifdef _WIN32 +#define WIN32_LEAN_AND_MEAN +#include +#include +#undef WIN32_LEAN_AND_MEAN +#endif +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif +#include +#include +#include +#include +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#include +#ifdef EVENT__HAVE_FCNTL_H +#include +#endif + +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event-internal.h" +#include "event2/util.h" +#include "evsignal-internal.h" +#include "log-internal.h" +#include "evmap-internal.h" +#include "evthread-internal.h" + +/* + signal.c + + This is the signal-handling implementation we use for backends that don't + have a better way to do signal handling. It uses sigaction() or signal() + to set a signal handler, and a socket pair to tell the event base when + + Note that I said "the event base" : only one event base can be set up to use + this at a time. For historical reasons and backward compatibility, if you + add an event for a signal to event_base A, then add an event for a signal + (any signal!) to event_base B, event_base B will get informed about the + signal, but event_base A won't. + + It would be neat to change this behavior in some future version of Libevent. + kqueue already does something far more sensible. We can make all backends + on Linux do a reasonable thing using signalfd. +*/ + +#ifndef _WIN32 +/* Windows wants us to call our signal handlers as __cdecl. Nobody else + * expects you to do anything crazy like this. */ +#define __cdecl +#endif + +static int evsig_add(struct event_base *, evutil_socket_t, short, short, void *); +static int evsig_del(struct event_base *, evutil_socket_t, short, short, void *); + +static const struct eventop evsigops = { + "signal", + NULL, + evsig_add, + evsig_del, + NULL, + NULL, + 0, 0, 0 +}; + +#ifndef EVENT__DISABLE_THREAD_SUPPORT +/* Lock for evsig_base and evsig_base_n_signals_added fields. */ +static void *evsig_base_lock = NULL; +#endif +/* The event base that's currently getting informed about signals. */ +static struct event_base *evsig_base = NULL; +/* A copy of evsig_base->sigev_n_signals_added. */ +static int evsig_base_n_signals_added = 0; +static evutil_socket_t evsig_base_fd = -1; + +static void __cdecl evsig_handler(int sig); + +#define EVSIGBASE_LOCK() EVLOCK_LOCK(evsig_base_lock, 0) +#define EVSIGBASE_UNLOCK() EVLOCK_UNLOCK(evsig_base_lock, 0) + +void +evsig_set_base_(struct event_base *base) +{ + EVSIGBASE_LOCK(); + evsig_base = base; + evsig_base_n_signals_added = base->sig.ev_n_signals_added; + evsig_base_fd = base->sig.ev_signal_pair[1]; + EVSIGBASE_UNLOCK(); +} + +/* Callback for when the signal handler write a byte to our signaling socket */ +static void +evsig_cb(evutil_socket_t fd, short what, void *arg) +{ + static char signals[1024]; + ev_ssize_t n; + int i; + int ncaught[NSIG]; + struct event_base *base; + + base = arg; + + memset(&ncaught, 0, sizeof(ncaught)); + + while (1) { +#ifdef _WIN32 + n = recv(fd, signals, sizeof(signals), 0); +#else + n = read(fd, signals, sizeof(signals)); +#endif + if (n == -1) { + int err = evutil_socket_geterror(fd); + if (! EVUTIL_ERR_RW_RETRIABLE(err)) + event_sock_err(1, fd, "%s: recv", __func__); + break; + } else if (n == 0) { + /* XXX warn? */ + break; + } + for (i = 0; i < n; ++i) { + ev_uint8_t sig = signals[i]; + if (sig < NSIG) + ncaught[sig]++; + } + } + + EVBASE_ACQUIRE_LOCK(base, th_base_lock); + for (i = 0; i < NSIG; ++i) { + if (ncaught[i]) + evmap_signal_active_(base, i, ncaught[i]); + } + EVBASE_RELEASE_LOCK(base, th_base_lock); +} + +int +evsig_init_(struct event_base *base) +{ + /* + * Our signal handler is going to write to one end of the socket + * pair to wake up our event loop. The event loop then scans for + * signals that got delivered. + */ + if (evutil_make_internal_pipe_(base->sig.ev_signal_pair) == -1) { +#ifdef _WIN32 + /* Make this nonfatal on win32, where sometimes people + have localhost firewalled. */ + event_sock_warn(-1, "%s: socketpair", __func__); +#else + event_sock_err(1, -1, "%s: socketpair", __func__); +#endif + return -1; + } + + if (base->sig.sh_old) { + mm_free(base->sig.sh_old); + } + base->sig.sh_old = NULL; + base->sig.sh_old_max = 0; + + event_assign(&base->sig.ev_signal, base, base->sig.ev_signal_pair[0], + EV_READ | EV_PERSIST, evsig_cb, base); + + base->sig.ev_signal.ev_flags |= EVLIST_INTERNAL; + event_priority_set(&base->sig.ev_signal, 0); + + base->evsigsel = &evsigops; + + return 0; +} + +/* Helper: set the signal handler for evsignal to handler in base, so that + * we can restore the original handler when we clear the current one. */ +int +evsig_set_handler_(struct event_base *base, + int evsignal, void (__cdecl *handler)(int)) +{ +#ifdef EVENT__HAVE_SIGACTION + struct sigaction sa; +#else + ev_sighandler_t sh; +#endif + struct evsig_info *sig = &base->sig; + void *p; + + /* + * resize saved signal handler array up to the highest signal number. + * a dynamic array is used to keep footprint on the low side. + */ + if (evsignal >= sig->sh_old_max) { + int new_max = evsignal + 1; + event_debug(("%s: evsignal (%d) >= sh_old_max (%d), resizing", + __func__, evsignal, sig->sh_old_max)); + p = mm_realloc(sig->sh_old, new_max * sizeof(*sig->sh_old)); + if (p == NULL) { + event_warn("realloc"); + return (-1); + } + + memset((char *)p + sig->sh_old_max * sizeof(*sig->sh_old), + 0, (new_max - sig->sh_old_max) * sizeof(*sig->sh_old)); + + sig->sh_old_max = new_max; + sig->sh_old = p; + } + + /* allocate space for previous handler out of dynamic array */ + sig->sh_old[evsignal] = mm_malloc(sizeof *sig->sh_old[evsignal]); + if (sig->sh_old[evsignal] == NULL) { + event_warn("malloc"); + return (-1); + } + + /* save previous handler and setup new handler */ +#ifdef EVENT__HAVE_SIGACTION + memset(&sa, 0, sizeof(sa)); + sa.sa_handler = handler; + sa.sa_flags |= SA_RESTART; + sigfillset(&sa.sa_mask); + + if (sigaction(evsignal, &sa, sig->sh_old[evsignal]) == -1) { + event_warn("sigaction"); + mm_free(sig->sh_old[evsignal]); + sig->sh_old[evsignal] = NULL; + return (-1); + } +#else + if ((sh = signal(evsignal, handler)) == SIG_ERR) { + event_warn("signal"); + mm_free(sig->sh_old[evsignal]); + sig->sh_old[evsignal] = NULL; + return (-1); + } + *sig->sh_old[evsignal] = sh; +#endif + + return (0); +} + +static int +evsig_add(struct event_base *base, evutil_socket_t evsignal, short old, short events, void *p) +{ + struct evsig_info *sig = &base->sig; + (void)p; + + EVUTIL_ASSERT(evsignal >= 0 && evsignal < NSIG); + + /* catch signals if they happen quickly */ + EVSIGBASE_LOCK(); + if (evsig_base != base && evsig_base_n_signals_added) { + event_warnx("Added a signal to event base %p with signals " + "already added to event_base %p. Only one can have " + "signals at a time with the %s backend. The base with " + "the most recently added signal or the most recent " + "event_base_loop() call gets preference; do " + "not rely on this behavior in future Libevent versions.", + base, evsig_base, base->evsel->name); + } + evsig_base = base; + evsig_base_n_signals_added = ++sig->ev_n_signals_added; + evsig_base_fd = base->sig.ev_signal_pair[1]; + EVSIGBASE_UNLOCK(); + + event_debug(("%s: %d: changing signal handler", __func__, (int)evsignal)); + if (evsig_set_handler_(base, (int)evsignal, evsig_handler) == -1) { + goto err; + } + + + if (!sig->ev_signal_added) { + if (event_add_nolock_(&sig->ev_signal, NULL, 0)) + goto err; + sig->ev_signal_added = 1; + } + + return (0); + +err: + EVSIGBASE_LOCK(); + --evsig_base_n_signals_added; + --sig->ev_n_signals_added; + EVSIGBASE_UNLOCK(); + return (-1); +} + +int +evsig_restore_handler_(struct event_base *base, int evsignal) +{ + int ret = 0; + struct evsig_info *sig = &base->sig; +#ifdef EVENT__HAVE_SIGACTION + struct sigaction *sh; +#else + ev_sighandler_t *sh; +#endif + + if (evsignal >= sig->sh_old_max) { + /* Can't actually restore. */ + /* XXXX.*/ + return 0; + } + + /* restore previous handler */ + sh = sig->sh_old[evsignal]; + sig->sh_old[evsignal] = NULL; +#ifdef EVENT__HAVE_SIGACTION + if (sigaction(evsignal, sh, NULL) == -1) { + event_warn("sigaction"); + ret = -1; + } +#else + if (signal(evsignal, *sh) == SIG_ERR) { + event_warn("signal"); + ret = -1; + } +#endif + + mm_free(sh); + + return ret; +} + +static int +evsig_del(struct event_base *base, evutil_socket_t evsignal, short old, short events, void *p) +{ + EVUTIL_ASSERT(evsignal >= 0 && evsignal < NSIG); + + event_debug(("%s: "EV_SOCK_FMT": restoring signal handler", + __func__, EV_SOCK_ARG(evsignal))); + + EVSIGBASE_LOCK(); + --evsig_base_n_signals_added; + --base->sig.ev_n_signals_added; + EVSIGBASE_UNLOCK(); + + return (evsig_restore_handler_(base, (int)evsignal)); +} + +static void __cdecl +evsig_handler(int sig) +{ + int save_errno = errno; +#ifdef _WIN32 + int socket_errno = EVUTIL_SOCKET_ERROR(); +#endif + ev_uint8_t msg; + + if (evsig_base == NULL) { + event_warnx( + "%s: received signal %d, but have no base configured", + __func__, sig); + return; + } + +#ifndef EVENT__HAVE_SIGACTION + signal(sig, evsig_handler); +#endif + + /* Wake up our notification mechanism */ + msg = sig; +#ifdef _WIN32 + send(evsig_base_fd, (char*)&msg, 1, 0); +#else + { + int r = write(evsig_base_fd, (char*)&msg, 1); + (void)r; /* Suppress 'unused return value' and 'unused var' */ + } +#endif + errno = save_errno; +#ifdef _WIN32 + EVUTIL_SET_SOCKET_ERROR(socket_errno); +#endif +} + +void +evsig_dealloc_(struct event_base *base) +{ + int i = 0; + if (base->sig.ev_signal_added) { + event_del(&base->sig.ev_signal); + base->sig.ev_signal_added = 0; + } + /* debug event is created in evsig_init_/event_assign even when + * ev_signal_added == 0, so unassign is required */ + event_debug_unassign(&base->sig.ev_signal); + + for (i = 0; i < NSIG; ++i) { + if (i < base->sig.sh_old_max && base->sig.sh_old[i] != NULL) + evsig_restore_handler_(base, i); + } + EVSIGBASE_LOCK(); + if (base == evsig_base) { + evsig_base = NULL; + evsig_base_n_signals_added = 0; + evsig_base_fd = -1; + } + EVSIGBASE_UNLOCK(); + + if (base->sig.ev_signal_pair[0] != -1) { + evutil_closesocket(base->sig.ev_signal_pair[0]); + base->sig.ev_signal_pair[0] = -1; + } + if (base->sig.ev_signal_pair[1] != -1) { + evutil_closesocket(base->sig.ev_signal_pair[1]); + base->sig.ev_signal_pair[1] = -1; + } + base->sig.sh_old_max = 0; + + /* per index frees are handled in evsig_del() */ + if (base->sig.sh_old) { + mm_free(base->sig.sh_old); + base->sig.sh_old = NULL; + } +} + +static void +evsig_free_globals_locks(void) +{ +#ifndef EVENT__DISABLE_THREAD_SUPPORT + if (evsig_base_lock != NULL) { + EVTHREAD_FREE_LOCK(evsig_base_lock, 0); + evsig_base_lock = NULL; + } +#endif + return; +} + +void +evsig_free_globals_(void) +{ + evsig_free_globals_locks(); +} + +#ifndef EVENT__DISABLE_THREAD_SUPPORT +int +evsig_global_setup_locks_(const int enable_locks) +{ + EVTHREAD_SETUP_GLOBAL_LOCK(evsig_base_lock, 0); + return 0; +} + +#endif diff --git a/contrib/ntp/sntp/libevent/strlcpy-internal.h b/contrib/ntp/sntp/libevent/strlcpy-internal.h new file mode 100644 index 000000000..cfc27ec66 --- /dev/null +++ b/contrib/ntp/sntp/libevent/strlcpy-internal.h @@ -0,0 +1,22 @@ +#ifndef STRLCPY_INTERNAL_H_INCLUDED_ +#define STRLCPY_INTERNAL_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#ifndef EVENT__HAVE_STRLCPY +#include +size_t event_strlcpy_(char *dst, const char *src, size_t siz); +#define strlcpy event_strlcpy_ +#endif + +#ifdef __cplusplus +} +#endif + +#endif + diff --git a/contrib/ntp/sntp/libevent/strlcpy.c b/contrib/ntp/sntp/libevent/strlcpy.c new file mode 100644 index 000000000..3876475f5 --- /dev/null +++ b/contrib/ntp/sntp/libevent/strlcpy.c @@ -0,0 +1,75 @@ +/* $OpenBSD: strlcpy.c,v 1.5 2001/05/13 15:40:16 deraadt Exp $ */ + +/* + * Copyright (c) 1998 Todd C. Miller + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL + * THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; + * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR + * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#if defined(LIBC_SCCS) && !defined(lint) +static char *rcsid = "$OpenBSD: strlcpy.c,v 1.5 2001/05/13 15:40:16 deraadt Exp $"; +#endif /* LIBC_SCCS and not lint */ + +#include "event2/event-config.h" +#include "evconfig-private.h" + +#include + +#ifndef EVENT__HAVE_STRLCPY +#include "strlcpy-internal.h" + +/* + * Copy src to string dst of size siz. At most siz-1 characters + * will be copied. Always NUL terminates (unless siz == 0). + * Returns strlen(src); if retval >= siz, truncation occurred. + */ +size_t +event_strlcpy_(dst, src, siz) + char *dst; + const char *src; + size_t siz; +{ + register char *d = dst; + register const char *s = src; + register size_t n = siz; + + /* Copy as many bytes as will fit */ + if (n != 0 && --n != 0) { + do { + if ((*d++ = *s++) == 0) + break; + } while (--n != 0); + } + + /* Not enough room in dst, add NUL and traverse rest of src */ + if (n == 0) { + if (siz != 0) + *d = '\0'; /* NUL-terminate dst */ + while (*s++) + ; + } + + return (s - src - 1); /* count does not include NUL */ +} +#endif diff --git a/contrib/ntp/sntp/libevent/test/Makefile.nmake b/contrib/ntp/sntp/libevent/test/Makefile.nmake new file mode 100644 index 000000000..30c3eb792 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/Makefile.nmake @@ -0,0 +1,79 @@ +# WATCH OUT! This makefile is a work in progress. -*- makefile -*- + +!IFDEF OPENSSL_DIR +SSL_CFLAGS=/I$(OPENSSL_DIR)\include /DEVENT__HAVE_OPENSSL +SSL_OBJS=regress_ssl.obj +SSL_LIBS=..\libevent_openssl.lib $(OPENSSL_DIR)\lib\libeay32.lib $(OPENSSL_DIR)\lib\ssleay32.lib gdi32.lib User32.lib +!ELSE +SSL_CFLAGS= +SSL_OBJS= +SSL_LIBS= +!ENDIF + +CFLAGS=/I.. /I../WIN32-Code /I../WIN32-Code/nmake /I../include /I../compat /DHAVE_CONFIG_H /DTINYTEST_LOCAL $(SSL_CFLAGS) + +CFLAGS=$(CFLAGS) /Ox /W3 /wd4996 /nologo + +REGRESS_OBJS=regress.obj regress_buffer.obj regress_http.obj regress_dns.obj \ + regress_testutils.obj \ + regress_rpc.obj regress.gen.obj \ + regress_et.obj regress_bufferevent.obj \ + regress_listener.obj regress_util.obj tinytest.obj \ + regress_main.obj regress_minheap.obj regress_iocp.obj \ + regress_thread.obj regress_finalize.obj $(SSL_OBJS) + +OTHER_OBJS=test-init.obj test-eof.obj test-closed.obj test-weof.obj test-time.obj \ + bench.obj bench_cascade.obj bench_http.obj bench_httpclient.obj \ + test-changelist.obj \ + print-winsock-errors.obj + +PROGRAMS=regress.exe \ + test-init.exe test-eof.exe test-closed.exe test-weof.exe test-time.exe \ + test-changelist.exe \ + print-winsock-errors.exe + +# Disabled for now: +# bench.exe bench_cascade.exe bench_http.exe bench_httpclient.exe + + +LIBS=..\libevent.lib ws2_32.lib shell32.lib advapi32.lib + +all: $(PROGRAMS) + +regress.exe: $(REGRESS_OBJS) + $(CC) $(CFLAGS) $(LIBS) $(SSL_LIBS) $(REGRESS_OBJS) + +test-init.exe: test-init.obj + $(CC) $(CFLAGS) $(LIBS) test-init.obj +test-eof.exe: test-eof.obj + $(CC) $(CFLAGS) $(LIBS) test-eof.obj +test-closed.exe: test-closed.obj + $(CC) $(CFLAGS) $(LIBS) test-closed.obj +test-changelist.exe: test-changelist.obj + $(CC) $(CFLAGS) $(LIBS) test-changelist.obj +test-weof.exe: test-weof.obj + $(CC) $(CFLAGS) $(LIBS) test-weof.obj +test-time.exe: test-time.obj + $(CC) $(CFLAGS) $(LIBS) test-time.obj + +print-winsock-errors.exe: print-winsock-errors.obj + $(CC) $(CFLAGS) $(LIBS) print-winsock-errors.obj + +bench.exe: bench.obj + $(CC) $(CFLAGS) $(LIBS) bench.obj +bench_cascade.exe: bench_cascade.obj + $(CC) $(CFLAGS) $(LIBS) bench_cascade.obj +bench_http.exe: bench_http.obj + $(CC) $(CFLAGS) $(LIBS) bench_http.obj +bench_httpclient.exe: bench_httpclient.obj + $(CC) $(CFLAGS) $(LIBS) bench_httpclient.obj + +regress.gen.c regress.gen.h: regress.rpc ../event_rpcgen.py + echo // > regress.gen.c + echo #define NO_PYTHON_EXISTS > regress.gen.h + -python ..\event_rpcgen.py regress.rpc + +clean: + -del $(REGRESS_OBJS) + -del $(OTHER_OBJS) + -del $(PROGRAMS) diff --git a/contrib/ntp/sntp/libevent/test/bench.c b/contrib/ntp/sntp/libevent/test/bench.c new file mode 100644 index 000000000..922a743ad --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/bench.c @@ -0,0 +1,207 @@ +/* + * Copyright 2003-2007 Niels Provos + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 4. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * + * Mon 03/10/2003 - Modified by Davide Libenzi + * + * Added chain event propagation to improve the sensitivity of + * the measure respect to the event loop efficency. + * + * + */ + +#include "event2/event-config.h" + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#ifdef _WIN32 +#define WIN32_LEAN_AND_MEAN +#include +#else +#include +#include +#include +#endif +#include +#include +#include +#include +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#include + +#ifdef _WIN32 +#include +#endif + +#include +#include + +static int count, writes, fired, failures; +static evutil_socket_t *pipes; +static int num_pipes, num_active, num_writes; +static struct event *events; + + +static void +read_cb(evutil_socket_t fd, short which, void *arg) +{ + ev_intptr_t idx = (ev_intptr_t) arg, widx = idx + 1; + u_char ch; + ev_ssize_t n; + + n = recv(fd, (char*)&ch, sizeof(ch), 0); + if (n >= 0) + count += n; + else + failures++; + if (writes) { + if (widx >= num_pipes) + widx -= num_pipes; + n = send(pipes[2 * widx + 1], "e", 1, 0); + if (n != 1) + failures++; + writes--; + fired++; + } +} + +static struct timeval * +run_once(void) +{ + evutil_socket_t *cp, space; + long i; + static struct timeval ts, te; + + for (cp = pipes, i = 0; i < num_pipes; i++, cp += 2) { + if (event_initialized(&events[i])) + event_del(&events[i]); + event_set(&events[i], cp[0], EV_READ | EV_PERSIST, read_cb, (void *)(ev_intptr_t) i); + event_add(&events[i], NULL); + } + + event_loop(EVLOOP_ONCE | EVLOOP_NONBLOCK); + + fired = 0; + space = num_pipes / num_active; + space = space * 2; + for (i = 0; i < num_active; i++, fired++) + (void) send(pipes[i * space + 1], "e", 1, 0); + + count = 0; + writes = num_writes; + { int xcount = 0; + evutil_gettimeofday(&ts, NULL); + do { + event_loop(EVLOOP_ONCE | EVLOOP_NONBLOCK); + xcount++; + } while (count != fired); + evutil_gettimeofday(&te, NULL); + + if (xcount != count) fprintf(stderr, "Xcount: %d, Rcount: %d\n", xcount, count); + } + + evutil_timersub(&te, &ts, &te); + + return (&te); +} + +int +main(int argc, char **argv) +{ +#ifdef HAVE_SETRLIMIT + struct rlimit rl; +#endif + int i, c; + struct timeval *tv; + evutil_socket_t *cp; + +#ifdef _WIN32 + WSADATA WSAData; + WSAStartup(0x101, &WSAData); +#endif + num_pipes = 100; + num_active = 1; + num_writes = num_pipes; + while ((c = getopt(argc, argv, "n:a:w:")) != -1) { + switch (c) { + case 'n': + num_pipes = atoi(optarg); + break; + case 'a': + num_active = atoi(optarg); + break; + case 'w': + num_writes = atoi(optarg); + break; + default: + fprintf(stderr, "Illegal argument \"%c\"\n", c); + exit(1); + } + } + +#ifdef HAVE_SETRLIMIT + rl.rlim_cur = rl.rlim_max = num_pipes * 2 + 50; + if (setrlimit(RLIMIT_NOFILE, &rl) == -1) { + perror("setrlimit"); + exit(1); + } +#endif + + events = calloc(num_pipes, sizeof(struct event)); + pipes = calloc(num_pipes * 2, sizeof(evutil_socket_t)); + if (events == NULL || pipes == NULL) { + perror("malloc"); + exit(1); + } + + event_init(); + + for (cp = pipes, i = 0; i < num_pipes; i++, cp += 2) { +#ifdef USE_PIPES + if (pipe(cp) == -1) { +#else + if (evutil_socketpair(AF_UNIX, SOCK_STREAM, 0, cp) == -1) { +#endif + perror("pipe"); + exit(1); + } + } + + for (i = 0; i < 25; i++) { + tv = run_once(); + if (tv == NULL) + exit(1); + fprintf(stdout, "%ld\n", + tv->tv_sec * 1000000L + tv->tv_usec); + } + + exit(0); +} diff --git a/contrib/ntp/sntp/libevent/test/bench_cascade.c b/contrib/ntp/sntp/libevent/test/bench_cascade.c new file mode 100644 index 000000000..2d85cc1f1 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/bench_cascade.c @@ -0,0 +1,188 @@ +/* + * Copyright 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 4. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#include "event2/event-config.h" + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#ifdef _WIN32 +#define WIN32_LEAN_AND_MEAN +#include +#else +#include +#include +#endif +#include +#include +#include +#include +#include +#ifdef EVENT__HAVE_UNISTD_H +#include +#endif +#include +#include +#include +#include + +/* + * This benchmark tests how quickly we can propagate a write down a chain + * of socket pairs. We start by writing to the first socket pair and all + * events will fire subsequently until the last socket pair has been reached + * and the benchmark terminates. + */ + +static int fired; +static evutil_socket_t *pipes; +static struct event *events; + +static void +read_cb(evutil_socket_t fd, short which, void *arg) +{ + char ch; + evutil_socket_t sock = (evutil_socket_t)(ev_intptr_t)arg; + + (void) recv(fd, &ch, sizeof(ch), 0); + if (sock >= 0) { + if (send(sock, "e", 1, 0) < 0) + perror("send"); + } + fired++; +} + +static struct timeval * +run_once(int num_pipes) +{ + int i; + evutil_socket_t *cp; + static struct timeval ts, te, tv_timeout; + + events = (struct event *)calloc(num_pipes, sizeof(struct event)); + pipes = (evutil_socket_t *)calloc(num_pipes * 2, sizeof(evutil_socket_t)); + + if (events == NULL || pipes == NULL) { + perror("malloc"); + exit(1); + } + + for (cp = pipes, i = 0; i < num_pipes; i++, cp += 2) { + if (evutil_socketpair(AF_UNIX, SOCK_STREAM, 0, cp) == -1) { + perror("socketpair"); + exit(1); + } + } + + /* measurements includes event setup */ + evutil_gettimeofday(&ts, NULL); + + /* provide a default timeout for events */ + evutil_timerclear(&tv_timeout); + tv_timeout.tv_sec = 60; + + for (cp = pipes, i = 0; i < num_pipes; i++, cp += 2) { + evutil_socket_t fd = i < num_pipes - 1 ? cp[3] : -1; + event_set(&events[i], cp[0], EV_READ, read_cb, + (void *)(ev_intptr_t)fd); + event_add(&events[i], &tv_timeout); + } + + fired = 0; + + /* kick everything off with a single write */ + if (send(pipes[1], "e", 1, 0) < 0) + perror("send"); + + event_dispatch(); + + evutil_gettimeofday(&te, NULL); + evutil_timersub(&te, &ts, &te); + + for (cp = pipes, i = 0; i < num_pipes; i++, cp += 2) { + event_del(&events[i]); + evutil_closesocket(cp[0]); + evutil_closesocket(cp[1]); + } + + free(pipes); + free(events); + + return (&te); +} + +int +main(int argc, char **argv) +{ +#ifdef HAVE_SETRLIMIT + struct rlimit rl; +#endif + int i, c; + struct timeval *tv; + + int num_pipes = 100; +#ifdef _WIN32 + WSADATA WSAData; + WSAStartup(0x101, &WSAData); +#endif + + while ((c = getopt(argc, argv, "n:")) != -1) { + switch (c) { + case 'n': + num_pipes = atoi(optarg); + break; + default: + fprintf(stderr, "Illegal argument \"%c\"\n", c); + exit(1); + } + } + +#ifdef HAVE_SETRLIMIT + rl.rlim_cur = rl.rlim_max = num_pipes * 2 + 50; + if (setrlimit(RLIMIT_NOFILE, &rl) == -1) { + perror("setrlimit"); + exit(1); + } +#endif + + event_init(); + + for (i = 0; i < 25; i++) { + tv = run_once(num_pipes); + if (tv == NULL) + exit(1); + fprintf(stdout, "%ld\n", + tv->tv_sec * 1000000L + tv->tv_usec); + } + +#ifdef _WIN32 + WSACleanup(); +#endif + + exit(0); +} diff --git a/contrib/ntp/sntp/libevent/test/bench_http.c b/contrib/ntp/sntp/libevent/test/bench_http.c new file mode 100644 index 000000000..6d0d97179 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/bench_http.c @@ -0,0 +1,195 @@ +/* + * Copyright 2008-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 4. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +#include +#include +#ifdef _WIN32 +#include +#else +#include +#include +#include +#include +#endif +#include +#include +#include +#include +#include +#include + +#include "event2/event.h" +#include "event2/buffer.h" +#include "event2/util.h" +#include "event2/http.h" +#include "event2/thread.h" + +static void http_basic_cb(struct evhttp_request *req, void *arg); + +static char *content; +static size_t content_len = 0; + +static void +http_basic_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *evb = evbuffer_new(); + + evbuffer_add(evb, content, content_len); + + /* allow sending of an empty reply */ + evhttp_send_reply(req, HTTP_OK, "Everything is fine", evb); + + evbuffer_free(evb); +} + +#if LIBEVENT_VERSION_NUMBER >= 0x02000200 +static void +http_ref_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *evb = evbuffer_new(); + + evbuffer_add_reference(evb, content, content_len, NULL, NULL); + + /* allow sending of an empty reply */ + evhttp_send_reply(req, HTTP_OK, "Everything is fine", evb); + + evbuffer_free(evb); +} +#endif + +int +main(int argc, char **argv) +{ + struct event_config *cfg = event_config_new(); + struct event_base *base; + struct evhttp *http; + int i; + int c; + int use_iocp = 0; + unsigned short port = 8080; + char *endptr = NULL; + +#ifdef _WIN32 + WSADATA WSAData; + WSAStartup(0x101, &WSAData); +#else + if (signal(SIGPIPE, SIG_IGN) == SIG_ERR) + return (1); +#endif + + for (i = 1; i < argc; ++i) { + if (*argv[i] != '-') + continue; + + c = argv[i][1]; + + if ((c == 'p' || c == 'l') && i + 1 >= argc) { + fprintf(stderr, "-%c requires argument.\n", c); + exit(1); + } + + switch (c) { + case 'p': + if (i+1 >= argc || !argv[i+1]) { + fprintf(stderr, "Missing port\n"); + exit(1); + } + port = (int)strtol(argv[i+1], &endptr, 10); + if (*endptr != '\0') { + fprintf(stderr, "Bad port\n"); + exit(1); + } + break; + case 'l': + if (i+1 >= argc || !argv[i+1]) { + fprintf(stderr, "Missing content length\n"); + exit(1); + } + content_len = (size_t)strtol(argv[i+1], &endptr, 10); + if (*endptr != '\0' || content_len == 0) { + fprintf(stderr, "Bad content length\n"); + exit(1); + } + break; +#ifdef _WIN32 + case 'i': + use_iocp = 1; + evthread_use_windows_threads(); + event_config_set_flag(cfg,EVENT_BASE_FLAG_STARTUP_IOCP); + break; +#endif + default: + fprintf(stderr, "Illegal argument \"%c\"\n", c); + exit(1); + } + } + + base = event_base_new_with_config(cfg); + if (!base) { + fprintf(stderr, "creating event_base failed. Exiting.\n"); + return 1; + } + + http = evhttp_new(base); + + content = malloc(content_len); + if (content == NULL) { + fprintf(stderr, "Cannot allocate content\n"); + exit(1); + } else { + int i = 0; + for (i = 0; i < (int)content_len; ++i) + content[i] = (i & 255); + } + + evhttp_set_cb(http, "/ind", http_basic_cb, NULL); + fprintf(stderr, "/ind - basic content (memory copy)\n"); + + evhttp_set_cb(http, "/ref", http_ref_cb, NULL); + fprintf(stderr, "/ref - basic content (reference)\n"); + + fprintf(stderr, "Serving %d bytes on port %d using %s\n", + (int)content_len, port, + use_iocp? "IOCP" : event_base_get_method(base)); + + evhttp_bind_socket(http, "0.0.0.0", port); + +#ifdef _WIN32 + if (use_iocp) { + struct timeval tv={99999999,0}; + event_base_loopexit(base, &tv); + } +#endif + event_base_dispatch(base); + +#ifdef _WIN32 + WSACleanup(); +#endif + + /* NOTREACHED */ + return (0); +} diff --git a/contrib/ntp/sntp/libevent/test/bench_httpclient.c b/contrib/ntp/sntp/libevent/test/bench_httpclient.c new file mode 100644 index 000000000..1573e365b --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/bench_httpclient.c @@ -0,0 +1,234 @@ +/* + * Copyright 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 4. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ + +/* for EVUTIL_ERR_CONNECT_RETRIABLE macro */ +#include "util-internal.h" + +#include +#ifdef _WIN32 +#include +#else +#include +#include +# ifdef _XOPEN_SOURCE_EXTENDED +# include +# endif +#endif +#include +#include +#include + +#include "event2/event.h" +#include "event2/bufferevent.h" +#include "event2/buffer.h" +#include "event2/util.h" + +const char *resource = NULL; +struct event_base *base = NULL; + +int total_n_handled = 0; +int total_n_errors = 0; +int total_n_launched = 0; +size_t total_n_bytes = 0; +struct timeval total_time = {0,0}; +int n_errors = 0; + +const int PARALLELISM = 200; +const int N_REQUESTS = 20000; + +struct request_info { + size_t n_read; + struct timeval started; +}; + +static int launch_request(void); +static void readcb(struct bufferevent *b, void *arg); +static void errorcb(struct bufferevent *b, short what, void *arg); + +static void +readcb(struct bufferevent *b, void *arg) +{ + struct request_info *ri = arg; + struct evbuffer *input = bufferevent_get_input(b); + size_t n = evbuffer_get_length(input); + + ri->n_read += n; + evbuffer_drain(input, n); +} + +static void +errorcb(struct bufferevent *b, short what, void *arg) +{ + struct request_info *ri = arg; + struct timeval now, diff; + if (what & BEV_EVENT_EOF) { + ++total_n_handled; + total_n_bytes += ri->n_read; + evutil_gettimeofday(&now, NULL); + evutil_timersub(&now, &ri->started, &diff); + evutil_timeradd(&diff, &total_time, &total_time); + + if (total_n_handled && (total_n_handled%1000)==0) + printf("%d requests done\n",total_n_handled); + + if (total_n_launched < N_REQUESTS) { + if (launch_request() < 0) + perror("Can't launch"); + } + } else { + ++total_n_errors; + perror("Unexpected error"); + } + + bufferevent_setcb(b, NULL, NULL, NULL, NULL); + free(ri); + bufferevent_disable(b, EV_READ|EV_WRITE); + bufferevent_free(b); +} + +static void +frob_socket(evutil_socket_t sock) +{ +#ifdef HAVE_SO_LINGER + struct linger l; +#endif + int one = 1; + if (setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, (void*)&one, sizeof(one))<0) + perror("setsockopt(SO_REUSEADDR)"); +#ifdef HAVE_SO_LINGER + l.l_onoff = 1; + l.l_linger = 0; + if (setsockopt(sock, SOL_SOCKET, SO_LINGER, (void*)&l, sizeof(l))<0) + perror("setsockopt(SO_LINGER)"); +#endif +} + +static int +launch_request(void) +{ + evutil_socket_t sock; + struct sockaddr_in sin; + struct bufferevent *b; + + struct request_info *ri; + + memset(&sin, 0, sizeof(sin)); + + ++total_n_launched; + + sin.sin_family = AF_INET; + sin.sin_addr.s_addr = htonl(0x7f000001); + sin.sin_port = htons(8080); + if ((sock = socket(AF_INET, SOCK_STREAM, 0)) < 0) + return -1; + if (evutil_make_socket_nonblocking(sock) < 0) { + evutil_closesocket(sock); + return -1; + } + frob_socket(sock); + if (connect(sock, (struct sockaddr*)&sin, sizeof(sin)) < 0) { + int e = errno; + if (! EVUTIL_ERR_CONNECT_RETRIABLE(e)) { + evutil_closesocket(sock); + return -1; + } + } + + ri = malloc(sizeof(*ri)); + if (ri == NULL) { + printf("Unable to allocate memory in launch_request()\n"); + return -1; + } + ri->n_read = 0; + evutil_gettimeofday(&ri->started, NULL); + + b = bufferevent_socket_new(base, sock, BEV_OPT_CLOSE_ON_FREE); + + bufferevent_setcb(b, readcb, NULL, errorcb, ri); + bufferevent_enable(b, EV_READ|EV_WRITE); + + evbuffer_add_printf(bufferevent_get_output(b), + "GET %s HTTP/1.0\r\n\r\n", resource); + + return 0; +} + + +int +main(int argc, char **argv) +{ + int i; + struct timeval start, end, total; + long long usec; + double throughput; + resource = "/ref"; + + setvbuf(stdout, NULL, _IONBF, 0); + + base = event_base_new(); + + for (i=0; i < PARALLELISM; ++i) { + if (launch_request() < 0) + perror("launch"); + } + + evutil_gettimeofday(&start, NULL); + + event_base_dispatch(base); + + evutil_gettimeofday(&end, NULL); + evutil_timersub(&end, &start, &total); + usec = total_time.tv_sec * (long long)1000000 + total_time.tv_usec; + + if (!total_n_handled) { + puts("Nothing worked. You probably did something dumb."); + return 0; + } + + + throughput = total_n_handled / + (total.tv_sec+ ((double)total.tv_usec)/1000000.0); + +#ifdef _WIN32 +#define I64_FMT "%I64d" +#define I64_TYP __int64 +#else +#define I64_FMT "%lld" +#define I64_TYP long long int +#endif + + printf("\n%d requests in %d.%06d sec. (%.2f throughput)\n" + "Each took about %.02f msec latency\n" + I64_FMT "bytes read. %d errors.\n", + total_n_handled, + (int)total.tv_sec, (int)total.tv_usec, + throughput, + (double)(usec/1000) / total_n_handled, + (I64_TYP)total_n_bytes, n_errors); + + return 0; +} diff --git a/contrib/ntp/sntp/libevent/test/check-dumpevents.py b/contrib/ntp/sntp/libevent/test/check-dumpevents.py new file mode 100755 index 000000000..16fe9bc92 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/check-dumpevents.py @@ -0,0 +1,54 @@ +#!/usr/bin/python2 +# +# Post-process the output of test-dumpevents and check it for correctness. +# + +import math +import re +import sys + +text = sys.stdin.readlines() + +try: + expect_inserted_pos = text.index("Inserted:\n") + expect_active_pos = text.index("Active:\n") + got_inserted_pos = text.index("Inserted events:\n") + got_active_pos = text.index("Active events:\n") +except ValueError: + print >>sys.stderr, "Missing expected dividing line in dumpevents output" + sys.exit(1) + +if not (expect_inserted_pos < expect_active_pos < + got_inserted_pos < got_active_pos): + print >>sys.stderr, "Sections out of order in dumpevents output" + sys.exit(1) + +now,T= text[1].split() +T = float(T) + +want_inserted = set(text[expect_inserted_pos+1:expect_active_pos]) +want_active = set(text[expect_active_pos+1:got_inserted_pos-1]) +got_inserted = set(text[got_inserted_pos+1:got_active_pos]) +got_active = set(text[got_active_pos+1:]) + +pat = re.compile(r'Timeout=([0-9\.]+)') +def replace_time(m): + t = float(m.group(1)) + if .9 < abs(t-T) < 1.1: + return "Timeout=T+1" + elif 2.4 < abs(t-T) < 2.6: + return "Timeout=T+2.5" + else: + return m.group(0) + +cleaned_inserted = set( pat.sub(replace_time, s) for s in got_inserted + if "Internal" not in s) + +if cleaned_inserted != want_inserted: + print >>sys.stderr, "Inserted event lists were not as expected!" + sys.exit(1) + +if set(got_active) != set(want_active): + print >>sys.stderr, "Active event lists were not as expected!" + sys.exit(1) + diff --git a/contrib/ntp/sntp/libevent/test/include.am b/contrib/ntp/sntp/libevent/test/include.am new file mode 100644 index 000000000..4cd49ef63 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/include.am @@ -0,0 +1,146 @@ +# test/Makefile.am for libevent +# Copyright 2000-2007 Niels Provos +# Copyright 2007-2012 Niels Provos and Nick Mathewson +# +# See LICENSE for copying information. + +regress_CPPFLAGS = -DTINYTEST_LOCAL + +EXTRA_DIST+= \ + test/check-dumpevents.py \ + test/regress.gen.c \ + test/regress.gen.h \ + test/regress.rpc \ + test/rpcgen_wrapper.sh \ + test/test.sh + +TESTPROGRAMS = \ + test/bench \ + test/bench_cascade \ + test/bench_http \ + test/bench_httpclient \ + test/test-changelist \ + test/test-dumpevents \ + test/test-eof \ + test/test-closed \ + test/test-fdleak \ + test/test-init \ + test/test-ratelim \ + test/test-time \ + test/test-weof \ + test/regress + +if BUILD_REGRESS +noinst_PROGRAMS += $(TESTPROGRAMS) +EXTRA_PROGRAMS+= test/regress +endif + +noinst_HEADERS+= \ + test/regress.h \ + test/regress_thread.h \ + test/tinytest.h \ + test/tinytest_local.h \ + test/tinytest_macros.h + +# We need to copy this file, since automake doesn't want us to use top_srcdir +# in TESTS. +TESTS = test/test-script.sh + +test/test-script.sh: test/test.sh + cp $(top_srcdir)/test/test.sh $@ + +DISTCLEANFILES += test/test-script.sh +DISTCLEANFILES += test/regress.gen.c test/regress.gen.h + +if BUILD_REGRESS +BUILT_SOURCES += test/regress.gen.c test/regress.gen.h +endif + +test_test_init_SOURCES = test/test-init.c +test_test_init_LDADD = libevent_core.la +test_test_dumpevents_SOURCES = test/test-dumpevents.c +test_test_dumpevents_LDADD = libevent_core.la +test_test_eof_SOURCES = test/test-eof.c +test_test_eof_LDADD = libevent_core.la +test_test_closed_SOURCES = test/test-closed.c +test_test_closed_LDADD = libevent_core.la +test_test_changelist_SOURCES = test/test-changelist.c +test_test_changelist_LDADD = libevent_core.la +test_test_weof_SOURCES = test/test-weof.c +test_test_weof_LDADD = libevent_core.la +test_test_time_SOURCES = test/test-time.c +test_test_time_LDADD = libevent_core.la +test_test_ratelim_SOURCES = test/test-ratelim.c +test_test_ratelim_LDADD = libevent_core.la -lm +test_test_fdleak_SOURCES = test/test-fdleak.c +test_test_fdleak_LDADD = libevent_core.la + +test_regress_SOURCES = \ + test/regress.c \ + test/regress.gen.c \ + test/regress.gen.h \ + test/regress_buffer.c \ + test/regress_bufferevent.c \ + test/regress_dns.c \ + test/regress_et.c \ + test/regress_finalize.c \ + test/regress_http.c \ + test/regress_listener.c \ + test/regress_main.c \ + test/regress_minheap.c \ + test/regress_rpc.c \ + test/regress_testutils.c \ + test/regress_testutils.h \ + test/regress_util.c \ + test/tinytest.c \ + $(regress_thread_SOURCES) \ + $(regress_zlib_SOURCES) + +if PTHREADS +regress_thread_SOURCES = test/regress_thread.c +PTHREAD_LIBS += libevent_pthreads.la +endif +if BUILD_WIN32 +regress_thread_SOURCES = test/regress_thread.c +endif +if ZLIB_REGRESS +regress_zlib_SOURCES = test/regress_zlib.c +endif +if BUILD_WIN32 +test_regress_SOURCES += test/regress_iocp.c +endif + +test_regress_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la $(PTHREAD_LIBS) $(ZLIB_LIBS) +test_regress_CPPFLAGS = $(AM_CPPFLAGS) $(PTHREAD_CFLAGS) $(ZLIB_CFLAGS) -Itest +test_regress_LDFLAGS = $(PTHREAD_CFLAGS) + +if OPENSSL +test_regress_SOURCES += test/regress_ssl.c +test_regress_CPPFLAGS += $(OPENSSL_INCS) +test_regress_LDADD += libevent_openssl.la $(OPENSSL_LIBS) ${OPENSSL_LIBADD} +endif + +test_bench_SOURCES = test/bench.c +test_bench_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la +test_bench_cascade_SOURCES = test/bench_cascade.c +test_bench_cascade_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la +test_bench_http_SOURCES = test/bench_http.c +test_bench_http_LDADD = $(LIBEVENT_GC_SECTIONS) libevent.la +test_bench_httpclient_SOURCES = test/bench_httpclient.c +test_bench_httpclient_LDADD = $(LIBEVENT_GC_SECTIONS) libevent_core.la + +test/regress.gen.c test/regress.gen.h: test/rpcgen-attempted + +test/rpcgen-attempted: test/regress.rpc event_rpcgen.py test/rpcgen_wrapper.sh + $(AM_V_GEN)date -u > $@ + $(AM_V_at)if $(srcdir)/test/rpcgen_wrapper.sh $(srcdir)/test; then \ + true; \ + else \ + echo "No Python installed; stubbing out RPC test." >&2; \ + echo " "> test/regress.gen.c; \ + echo "#define NO_PYTHON_EXISTS" > test/regress.gen.h; \ + fi + +CLEANFILES += test/rpcgen-attempted + +$(TESTPROGRAMS) : libevent.la diff --git a/contrib/ntp/sntp/libevent/test/regress.c b/contrib/ntp/sntp/libevent/test/regress.c new file mode 100644 index 000000000..2d887f02f --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress.c @@ -0,0 +1,3334 @@ +/* + * Copyright (c) 2003-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "util-internal.h" + +#ifdef _WIN32 +#include +#include +#endif + +#include "event2/event-config.h" + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#ifndef _WIN32 +#include +#include +#include +#include +#include +#endif +#include +#include +#include +#include +#include +#include +#include +#include + +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/event_compat.h" +#include "event2/tag.h" +#include "event2/buffer.h" +#include "event2/buffer_compat.h" +#include "event2/util.h" +#include "event-internal.h" +#include "evthread-internal.h" +#include "log-internal.h" +#include "time-internal.h" + +#include "regress.h" + +#ifndef _WIN32 +#include "regress.gen.h" +#endif + +evutil_socket_t pair[2]; +int test_ok; +int called; +struct event_base *global_base; + +static char wbuf[4096]; +static char rbuf[4096]; +static int woff; +static int roff; +static int usepersist; +static struct timeval tset; +static struct timeval tcalled; + + +#define TEST1 "this is a test" + +#ifndef SHUT_WR +#define SHUT_WR 1 +#endif + +#ifdef _WIN32 +#define write(fd,buf,len) send((fd),(buf),(int)(len),0) +#define read(fd,buf,len) recv((fd),(buf),(int)(len),0) +#endif + +struct basic_cb_args +{ + struct event_base *eb; + struct event *ev; + unsigned int callcount; +}; + +static void +simple_read_cb(evutil_socket_t fd, short event, void *arg) +{ + char buf[256]; + int len; + + len = read(fd, buf, sizeof(buf)); + + if (len) { + if (!called) { + if (event_add(arg, NULL) == -1) + exit(1); + } + } else if (called == 1) + test_ok = 1; + + called++; +} + +static void +basic_read_cb(evutil_socket_t fd, short event, void *data) +{ + char buf[256]; + int len; + struct basic_cb_args *arg = data; + + len = read(fd, buf, sizeof(buf)); + + if (len < 0) { + tt_fail_perror("read (callback)"); + } else { + switch (arg->callcount++) { + case 0: /* first call: expect to read data; cycle */ + if (len > 0) + return; + + tt_fail_msg("EOF before data read"); + break; + + case 1: /* second call: expect EOF; stop */ + if (len > 0) + tt_fail_msg("not all data read on first cycle"); + break; + + default: /* third call: should not happen */ + tt_fail_msg("too many cycles"); + } + } + + event_del(arg->ev); + event_base_loopexit(arg->eb, NULL); +} + +static void +dummy_read_cb(evutil_socket_t fd, short event, void *arg) +{ +} + +static void +simple_write_cb(evutil_socket_t fd, short event, void *arg) +{ + int len; + + len = write(fd, TEST1, strlen(TEST1) + 1); + if (len == -1) + test_ok = 0; + else + test_ok = 1; +} + +static void +multiple_write_cb(evutil_socket_t fd, short event, void *arg) +{ + struct event *ev = arg; + int len; + + len = 128; + if (woff + len >= (int)sizeof(wbuf)) + len = sizeof(wbuf) - woff; + + len = write(fd, wbuf + woff, len); + if (len == -1) { + fprintf(stderr, "%s: write\n", __func__); + if (usepersist) + event_del(ev); + return; + } + + woff += len; + + if (woff >= (int)sizeof(wbuf)) { + shutdown(fd, SHUT_WR); + if (usepersist) + event_del(ev); + return; + } + + if (!usepersist) { + if (event_add(ev, NULL) == -1) + exit(1); + } +} + +static void +multiple_read_cb(evutil_socket_t fd, short event, void *arg) +{ + struct event *ev = arg; + int len; + + len = read(fd, rbuf + roff, sizeof(rbuf) - roff); + if (len == -1) + fprintf(stderr, "%s: read\n", __func__); + if (len <= 0) { + if (usepersist) + event_del(ev); + return; + } + + roff += len; + if (!usepersist) { + if (event_add(ev, NULL) == -1) + exit(1); + } +} + +static void +timeout_cb(evutil_socket_t fd, short event, void *arg) +{ + evutil_gettimeofday(&tcalled, NULL); +} + +struct both { + struct event ev; + int nread; +}; + +static void +combined_read_cb(evutil_socket_t fd, short event, void *arg) +{ + struct both *both = arg; + char buf[128]; + int len; + + len = read(fd, buf, sizeof(buf)); + if (len == -1) + fprintf(stderr, "%s: read\n", __func__); + if (len <= 0) + return; + + both->nread += len; + if (event_add(&both->ev, NULL) == -1) + exit(1); +} + +static void +combined_write_cb(evutil_socket_t fd, short event, void *arg) +{ + struct both *both = arg; + char buf[128]; + int len; + + len = sizeof(buf); + if (len > both->nread) + len = both->nread; + + memset(buf, 'q', len); + + len = write(fd, buf, len); + if (len == -1) + fprintf(stderr, "%s: write\n", __func__); + if (len <= 0) { + shutdown(fd, SHUT_WR); + return; + } + + both->nread -= len; + if (event_add(&both->ev, NULL) == -1) + exit(1); +} + +/* These macros used to replicate the work of the legacy test wrapper code */ +#define setup_test(x) do { \ + if (!in_legacy_test_wrapper) { \ + TT_FAIL(("Legacy test %s not wrapped properly", x)); \ + return; \ + } \ + } while (0) +#define cleanup_test() setup_test("cleanup") + +static void +test_simpleread(void) +{ + struct event ev; + + /* Very simple read test */ + setup_test("Simple read: "); + + if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + } + + shutdown(pair[0], SHUT_WR); + + event_set(&ev, pair[1], EV_READ, simple_read_cb, &ev); + if (event_add(&ev, NULL) == -1) + exit(1); + event_dispatch(); + + cleanup_test(); +} + +static void +test_simplewrite(void) +{ + struct event ev; + + /* Very simple write test */ + setup_test("Simple write: "); + + event_set(&ev, pair[0], EV_WRITE, simple_write_cb, &ev); + if (event_add(&ev, NULL) == -1) + exit(1); + event_dispatch(); + + cleanup_test(); +} + +static void +simpleread_multiple_cb(evutil_socket_t fd, short event, void *arg) +{ + if (++called == 2) + test_ok = 1; +} + +static void +test_simpleread_multiple(void) +{ + struct event one, two; + + /* Very simple read test */ + setup_test("Simple read to multiple evens: "); + + if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + } + + shutdown(pair[0], SHUT_WR); + + event_set(&one, pair[1], EV_READ, simpleread_multiple_cb, NULL); + if (event_add(&one, NULL) == -1) + exit(1); + event_set(&two, pair[1], EV_READ, simpleread_multiple_cb, NULL); + if (event_add(&two, NULL) == -1) + exit(1); + event_dispatch(); + + cleanup_test(); +} + +static int have_closed = 0; +static int premature_event = 0; +static void +simpleclose_close_fd_cb(evutil_socket_t s, short what, void *ptr) +{ + evutil_socket_t **fds = ptr; + TT_BLATHER(("Closing")); + evutil_closesocket(*fds[0]); + evutil_closesocket(*fds[1]); + *fds[0] = -1; + *fds[1] = -1; + have_closed = 1; +} + +static void +record_event_cb(evutil_socket_t s, short what, void *ptr) +{ + short *whatp = ptr; + if (!have_closed) + premature_event = 1; + *whatp = what; + TT_BLATHER(("Recorded %d on socket %d", (int)what, (int)s)); +} + +static void +test_simpleclose(void *ptr) +{ + /* Test that a close of FD is detected as a read and as a write. */ + struct event_base *base = event_base_new(); + evutil_socket_t pair1[2]={-1,-1}, pair2[2] = {-1, -1}; + evutil_socket_t *to_close[2]; + struct event *rev=NULL, *wev=NULL, *closeev=NULL; + struct timeval tv; + short got_read_on_close = 0, got_write_on_close = 0; + char buf[1024]; + memset(buf, 99, sizeof(buf)); +#ifdef _WIN32 +#define LOCAL_SOCKETPAIR_AF AF_INET +#else +#define LOCAL_SOCKETPAIR_AF AF_UNIX +#endif + if (evutil_socketpair(LOCAL_SOCKETPAIR_AF, SOCK_STREAM, 0, pair1)<0) + TT_DIE(("socketpair: %s", strerror(errno))); + if (evutil_socketpair(LOCAL_SOCKETPAIR_AF, SOCK_STREAM, 0, pair2)<0) + TT_DIE(("socketpair: %s", strerror(errno))); + if (evutil_make_socket_nonblocking(pair1[1]) < 0) + TT_DIE(("make_socket_nonblocking")); + if (evutil_make_socket_nonblocking(pair2[1]) < 0) + TT_DIE(("make_socket_nonblocking")); + + /** Stuff pair2[1] full of data, until write fails */ + while (1) { + int r = write(pair2[1], buf, sizeof(buf)); + if (r<0) { + int err = evutil_socket_geterror(pair2[1]); + if (! EVUTIL_ERR_RW_RETRIABLE(err)) + TT_DIE(("write failed strangely: %s", + evutil_socket_error_to_string(err))); + break; + } + } + to_close[0] = &pair1[0]; + to_close[1] = &pair2[0]; + + closeev = event_new(base, -1, EV_TIMEOUT, simpleclose_close_fd_cb, + to_close); + rev = event_new(base, pair1[1], EV_READ, record_event_cb, + &got_read_on_close); + TT_BLATHER(("Waiting for read on %d", (int)pair1[1])); + wev = event_new(base, pair2[1], EV_WRITE, record_event_cb, + &got_write_on_close); + TT_BLATHER(("Waiting for write on %d", (int)pair2[1])); + tv.tv_sec = 0; + tv.tv_usec = 100*1000; /* Close pair1[0] after a little while, and make + * sure we get a read event. */ + event_add(closeev, &tv); + event_add(rev, NULL); + event_add(wev, NULL); + /* Don't let the test go on too long. */ + tv.tv_sec = 0; + tv.tv_usec = 200*1000; + event_base_loopexit(base, &tv); + event_base_loop(base, 0); + + tt_int_op(got_read_on_close, ==, EV_READ); + tt_int_op(got_write_on_close, ==, EV_WRITE); + tt_int_op(premature_event, ==, 0); + +end: + if (pair1[0] >= 0) + evutil_closesocket(pair1[0]); + if (pair1[1] >= 0) + evutil_closesocket(pair1[1]); + if (pair2[0] >= 0) + evutil_closesocket(pair2[0]); + if (pair2[1] >= 0) + evutil_closesocket(pair2[1]); + if (rev) + event_free(rev); + if (wev) + event_free(wev); + if (closeev) + event_free(closeev); + if (base) + event_base_free(base); +} + + +static void +test_multiple(void) +{ + struct event ev, ev2; + int i; + + /* Multiple read and write test */ + setup_test("Multiple read/write: "); + memset(rbuf, 0, sizeof(rbuf)); + for (i = 0; i < (int)sizeof(wbuf); i++) + wbuf[i] = i; + + roff = woff = 0; + usepersist = 0; + + event_set(&ev, pair[0], EV_WRITE, multiple_write_cb, &ev); + if (event_add(&ev, NULL) == -1) + exit(1); + event_set(&ev2, pair[1], EV_READ, multiple_read_cb, &ev2); + if (event_add(&ev2, NULL) == -1) + exit(1); + event_dispatch(); + + if (roff == woff) + test_ok = memcmp(rbuf, wbuf, sizeof(wbuf)) == 0; + + cleanup_test(); +} + +static void +test_persistent(void) +{ + struct event ev, ev2; + int i; + + /* Multiple read and write test with persist */ + setup_test("Persist read/write: "); + memset(rbuf, 0, sizeof(rbuf)); + for (i = 0; i < (int)sizeof(wbuf); i++) + wbuf[i] = i; + + roff = woff = 0; + usepersist = 1; + + event_set(&ev, pair[0], EV_WRITE|EV_PERSIST, multiple_write_cb, &ev); + if (event_add(&ev, NULL) == -1) + exit(1); + event_set(&ev2, pair[1], EV_READ|EV_PERSIST, multiple_read_cb, &ev2); + if (event_add(&ev2, NULL) == -1) + exit(1); + event_dispatch(); + + if (roff == woff) + test_ok = memcmp(rbuf, wbuf, sizeof(wbuf)) == 0; + + cleanup_test(); +} + +static void +test_combined(void) +{ + struct both r1, r2, w1, w2; + + setup_test("Combined read/write: "); + memset(&r1, 0, sizeof(r1)); + memset(&r2, 0, sizeof(r2)); + memset(&w1, 0, sizeof(w1)); + memset(&w2, 0, sizeof(w2)); + + w1.nread = 4096; + w2.nread = 8192; + + event_set(&r1.ev, pair[0], EV_READ, combined_read_cb, &r1); + event_set(&w1.ev, pair[0], EV_WRITE, combined_write_cb, &w1); + event_set(&r2.ev, pair[1], EV_READ, combined_read_cb, &r2); + event_set(&w2.ev, pair[1], EV_WRITE, combined_write_cb, &w2); + tt_assert(event_add(&r1.ev, NULL) != -1); + tt_assert(!event_add(&w1.ev, NULL)); + tt_assert(!event_add(&r2.ev, NULL)); + tt_assert(!event_add(&w2.ev, NULL)); + event_dispatch(); + + if (r1.nread == 8192 && r2.nread == 4096) + test_ok = 1; + +end: + cleanup_test(); +} + +static void +test_simpletimeout(void) +{ + struct timeval tv; + struct event ev; + + setup_test("Simple timeout: "); + + tv.tv_usec = 200*1000; + tv.tv_sec = 0; + evutil_timerclear(&tcalled); + evtimer_set(&ev, timeout_cb, NULL); + evtimer_add(&ev, &tv); + + evutil_gettimeofday(&tset, NULL); + event_dispatch(); + test_timeval_diff_eq(&tset, &tcalled, 200); + + test_ok = 1; +end: + cleanup_test(); +} + +static void +periodic_timeout_cb(evutil_socket_t fd, short event, void *arg) +{ + int *count = arg; + + (*count)++; + if (*count == 6) { + /* call loopexit only once - on slow machines(?), it is + * apparently possible for this to get called twice. */ + test_ok = 1; + event_base_loopexit(global_base, NULL); + } +} + +static void +test_persistent_timeout(void) +{ + struct timeval tv; + struct event ev; + int count = 0; + + evutil_timerclear(&tv); + tv.tv_usec = 10000; + + event_assign(&ev, global_base, -1, EV_TIMEOUT|EV_PERSIST, + periodic_timeout_cb, &count); + event_add(&ev, &tv); + + event_dispatch(); + + event_del(&ev); +} + +static void +test_persistent_timeout_jump(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event ev; + int count = 0; + struct timeval msec100 = { 0, 100 * 1000 }; + struct timeval msec50 = { 0, 50 * 1000 }; + struct timeval msec300 = { 0, 300 * 1000 }; + + event_assign(&ev, data->base, -1, EV_PERSIST, periodic_timeout_cb, &count); + event_add(&ev, &msec100); + /* Wait for a bit */ + evutil_usleep_(&msec300); + event_base_loopexit(data->base, &msec50); + event_base_dispatch(data->base); + tt_int_op(count, ==, 1); + +end: + event_del(&ev); +} + +struct persist_active_timeout_called { + int n; + short events[16]; + struct timeval tvs[16]; +}; + +static void +activate_cb(evutil_socket_t fd, short event, void *arg) +{ + struct event *ev = arg; + event_active(ev, EV_READ, 1); +} + +static void +persist_active_timeout_cb(evutil_socket_t fd, short event, void *arg) +{ + struct persist_active_timeout_called *c = arg; + if (c->n < 15) { + c->events[c->n] = event; + evutil_gettimeofday(&c->tvs[c->n], NULL); + ++c->n; + } +} + +static void +test_persistent_active_timeout(void *ptr) +{ + struct timeval tv, tv2, tv_exit, start; + struct event ev; + struct persist_active_timeout_called res; + + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + + memset(&res, 0, sizeof(res)); + + tv.tv_sec = 0; + tv.tv_usec = 200 * 1000; + event_assign(&ev, base, -1, EV_TIMEOUT|EV_PERSIST, + persist_active_timeout_cb, &res); + event_add(&ev, &tv); + + tv2.tv_sec = 0; + tv2.tv_usec = 100 * 1000; + event_base_once(base, -1, EV_TIMEOUT, activate_cb, &ev, &tv2); + + tv_exit.tv_sec = 0; + tv_exit.tv_usec = 600 * 1000; + event_base_loopexit(base, &tv_exit); + + event_base_assert_ok_(base); + evutil_gettimeofday(&start, NULL); + + event_base_dispatch(base); + event_base_assert_ok_(base); + + tt_int_op(res.n, ==, 3); + tt_int_op(res.events[0], ==, EV_READ); + tt_int_op(res.events[1], ==, EV_TIMEOUT); + tt_int_op(res.events[2], ==, EV_TIMEOUT); + test_timeval_diff_eq(&start, &res.tvs[0], 100); + test_timeval_diff_eq(&start, &res.tvs[1], 300); + test_timeval_diff_eq(&start, &res.tvs[2], 500); +end: + event_del(&ev); +} + +struct common_timeout_info { + struct event ev; + struct timeval called_at; + int which; + int count; +}; + +static void +common_timeout_cb(evutil_socket_t fd, short event, void *arg) +{ + struct common_timeout_info *ti = arg; + ++ti->count; + evutil_gettimeofday(&ti->called_at, NULL); + if (ti->count >= 4) + event_del(&ti->ev); +} + +static void +test_common_timeout(void *ptr) +{ + struct basic_test_data *data = ptr; + + struct event_base *base = data->base; + int i; + struct common_timeout_info info[100]; + + struct timeval start; + struct timeval tmp_100_ms = { 0, 100*1000 }; + struct timeval tmp_200_ms = { 0, 200*1000 }; + struct timeval tmp_5_sec = { 5, 0 }; + struct timeval tmp_5M_usec = { 0, 5*1000*1000 }; + + const struct timeval *ms_100, *ms_200, *sec_5; + + ms_100 = event_base_init_common_timeout(base, &tmp_100_ms); + ms_200 = event_base_init_common_timeout(base, &tmp_200_ms); + sec_5 = event_base_init_common_timeout(base, &tmp_5_sec); + tt_assert(ms_100); + tt_assert(ms_200); + tt_assert(sec_5); + tt_ptr_op(event_base_init_common_timeout(base, &tmp_200_ms), + ==, ms_200); + tt_ptr_op(event_base_init_common_timeout(base, ms_200), ==, ms_200); + tt_ptr_op(event_base_init_common_timeout(base, &tmp_5M_usec), ==, sec_5); + tt_int_op(ms_100->tv_sec, ==, 0); + tt_int_op(ms_200->tv_sec, ==, 0); + tt_int_op(sec_5->tv_sec, ==, 5); + tt_int_op(ms_100->tv_usec, ==, 100000|0x50000000); + tt_int_op(ms_200->tv_usec, ==, 200000|0x50100000); + tt_int_op(sec_5->tv_usec, ==, 0|0x50200000); + + memset(info, 0, sizeof(info)); + + for (i=0; i<100; ++i) { + info[i].which = i; + event_assign(&info[i].ev, base, -1, EV_TIMEOUT|EV_PERSIST, + common_timeout_cb, &info[i]); + if (i % 2) { + if ((i%20)==1) { + /* Glass-box test: Make sure we survive the + * transition to non-common timeouts. It's + * a little tricky. */ + event_add(&info[i].ev, ms_200); + event_add(&info[i].ev, &tmp_100_ms); + } else if ((i%20)==3) { + /* Check heap-to-common too. */ + event_add(&info[i].ev, &tmp_200_ms); + event_add(&info[i].ev, ms_100); + } else if ((i%20)==5) { + /* Also check common-to-common. */ + event_add(&info[i].ev, ms_200); + event_add(&info[i].ev, ms_100); + } else { + event_add(&info[i].ev, ms_100); + } + } else { + event_add(&info[i].ev, ms_200); + } + } + + event_base_assert_ok_(base); + evutil_gettimeofday(&start, NULL); + event_base_dispatch(base); + + event_base_assert_ok_(base); + + for (i=0; i<10; ++i) { + tt_int_op(info[i].count, ==, 4); + if (i % 2) { + test_timeval_diff_eq(&start, &info[i].called_at, 400); + } else { + test_timeval_diff_eq(&start, &info[i].called_at, 800); + } + } + + /* Make sure we can free the base with some events in. */ + for (i=0; i<100; ++i) { + if (i % 2) { + event_add(&info[i].ev, ms_100); + } else { + event_add(&info[i].ev, ms_200); + } + } + +end: + event_base_free(data->base); /* need to do this here before info is + * out-of-scope */ + data->base = NULL; +} + +#ifndef _WIN32 +static void signal_cb(evutil_socket_t fd, short event, void *arg); + +#define current_base event_global_current_base_ +extern struct event_base *current_base; + +static void +child_signal_cb(evutil_socket_t fd, short event, void *arg) +{ + struct timeval tv; + int *pint = arg; + + *pint = 1; + + tv.tv_usec = 500000; + tv.tv_sec = 0; + event_loopexit(&tv); +} + +static void +test_fork(void) +{ + int status, got_sigchld = 0; + struct event ev, sig_ev; + pid_t pid; + + setup_test("After fork: "); + + tt_assert(current_base); + evthread_make_base_notifiable(current_base); + + if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + } + + event_set(&ev, pair[1], EV_READ, simple_read_cb, &ev); + if (event_add(&ev, NULL) == -1) + exit(1); + + evsignal_set(&sig_ev, SIGCHLD, child_signal_cb, &got_sigchld); + evsignal_add(&sig_ev, NULL); + + event_base_assert_ok_(current_base); + TT_BLATHER(("Before fork")); + if ((pid = regress_fork()) == 0) { + /* in the child */ + TT_BLATHER(("In child, before reinit")); + event_base_assert_ok_(current_base); + if (event_reinit(current_base) == -1) { + fprintf(stdout, "FAILED (reinit)\n"); + exit(1); + } + TT_BLATHER(("After reinit")); + event_base_assert_ok_(current_base); + TT_BLATHER(("After assert-ok")); + + evsignal_del(&sig_ev); + + called = 0; + + event_dispatch(); + + event_base_free(current_base); + + /* we do not send an EOF; simple_read_cb requires an EOF + * to set test_ok. we just verify that the callback was + * called. */ + exit(test_ok != 0 || called != 2 ? -2 : 76); + } + + /* wait for the child to read the data */ + { + const struct timeval tv = { 0, 100000 }; + evutil_usleep_(&tv); + } + + if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + } + + TT_BLATHER(("Before waitpid")); + if (waitpid(pid, &status, 0) == -1) { + fprintf(stdout, "FAILED (fork)\n"); + exit(1); + } + TT_BLATHER(("After waitpid")); + + if (WEXITSTATUS(status) != 76) { + fprintf(stdout, "FAILED (exit): %d\n", WEXITSTATUS(status)); + exit(1); + } + + /* test that the current event loop still works */ + if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) { + fprintf(stderr, "%s: write\n", __func__); + } + + shutdown(pair[0], SHUT_WR); + + event_dispatch(); + + if (!got_sigchld) { + fprintf(stdout, "FAILED (sigchld)\n"); + exit(1); + } + + evsignal_del(&sig_ev); + + end: + cleanup_test(); +} + +static void +signal_cb_sa(int sig) +{ + test_ok = 2; +} + +static void +signal_cb(evutil_socket_t fd, short event, void *arg) +{ + struct event *ev = arg; + + evsignal_del(ev); + test_ok = 1; +} + +static void +test_simplesignal_impl(int find_reorder) +{ + struct event ev; + struct itimerval itv; + + evsignal_set(&ev, SIGALRM, signal_cb, &ev); + evsignal_add(&ev, NULL); + /* find bugs in which operations are re-ordered */ + if (find_reorder) { + evsignal_del(&ev); + evsignal_add(&ev, NULL); + } + + memset(&itv, 0, sizeof(itv)); + itv.it_value.tv_sec = 0; + itv.it_value.tv_usec = 100000; + if (setitimer(ITIMER_REAL, &itv, NULL) == -1) + goto skip_simplesignal; + + event_dispatch(); + skip_simplesignal: + if (evsignal_del(&ev) == -1) + test_ok = 0; + + cleanup_test(); +} + +static void +test_simplestsignal(void) +{ + setup_test("Simplest one signal: "); + test_simplesignal_impl(0); +} + +static void +test_simplesignal(void) +{ + setup_test("Simple signal: "); + test_simplesignal_impl(1); +} + +static void +test_multiplesignal(void) +{ + struct event ev_one, ev_two; + struct itimerval itv; + + setup_test("Multiple signal: "); + + evsignal_set(&ev_one, SIGALRM, signal_cb, &ev_one); + evsignal_add(&ev_one, NULL); + + evsignal_set(&ev_two, SIGALRM, signal_cb, &ev_two); + evsignal_add(&ev_two, NULL); + + memset(&itv, 0, sizeof(itv)); + itv.it_value.tv_sec = 0; + itv.it_value.tv_usec = 100000; + if (setitimer(ITIMER_REAL, &itv, NULL) == -1) + goto skip_simplesignal; + + event_dispatch(); + + skip_simplesignal: + if (evsignal_del(&ev_one) == -1) + test_ok = 0; + if (evsignal_del(&ev_two) == -1) + test_ok = 0; + + cleanup_test(); +} + +static void +test_immediatesignal(void) +{ + struct event ev; + + test_ok = 0; + evsignal_set(&ev, SIGUSR1, signal_cb, &ev); + evsignal_add(&ev, NULL); + raise(SIGUSR1); + event_loop(EVLOOP_NONBLOCK); + evsignal_del(&ev); + cleanup_test(); +} + +static void +test_signal_dealloc(void) +{ + /* make sure that evsignal_event is event_del'ed and pipe closed */ + struct event ev; + struct event_base *base = event_init(); + evsignal_set(&ev, SIGUSR1, signal_cb, &ev); + evsignal_add(&ev, NULL); + evsignal_del(&ev); + event_base_free(base); + /* If we got here without asserting, we're fine. */ + test_ok = 1; + cleanup_test(); +} + +static void +test_signal_pipeloss(void) +{ + /* make sure that the base1 pipe is closed correctly. */ + struct event_base *base1, *base2; + int pipe1; + test_ok = 0; + base1 = event_init(); + pipe1 = base1->sig.ev_signal_pair[0]; + base2 = event_init(); + event_base_free(base2); + event_base_free(base1); + if (close(pipe1) != -1 || errno!=EBADF) { + /* fd must be closed, so second close gives -1, EBADF */ + printf("signal pipe not closed. "); + test_ok = 0; + } else { + test_ok = 1; + } + cleanup_test(); +} + +/* + * make two bases to catch signals, use both of them. this only works + * for event mechanisms that use our signal pipe trick. kqueue handles + * signals internally, and all interested kqueues get all the signals. + */ +static void +test_signal_switchbase(void) +{ + struct event ev1, ev2; + struct event_base *base1, *base2; + int is_kqueue; + test_ok = 0; + base1 = event_init(); + base2 = event_init(); + is_kqueue = !strcmp(event_get_method(),"kqueue"); + evsignal_set(&ev1, SIGUSR1, signal_cb, &ev1); + evsignal_set(&ev2, SIGUSR1, signal_cb, &ev2); + if (event_base_set(base1, &ev1) || + event_base_set(base2, &ev2) || + event_add(&ev1, NULL) || + event_add(&ev2, NULL)) { + fprintf(stderr, "%s: cannot set base, add\n", __func__); + exit(1); + } + + tt_ptr_op(event_get_base(&ev1), ==, base1); + tt_ptr_op(event_get_base(&ev2), ==, base2); + + test_ok = 0; + /* can handle signal before loop is called */ + raise(SIGUSR1); + event_base_loop(base2, EVLOOP_NONBLOCK); + if (is_kqueue) { + if (!test_ok) + goto end; + test_ok = 0; + } + event_base_loop(base1, EVLOOP_NONBLOCK); + if (test_ok && !is_kqueue) { + test_ok = 0; + + /* set base1 to handle signals */ + event_base_loop(base1, EVLOOP_NONBLOCK); + raise(SIGUSR1); + event_base_loop(base1, EVLOOP_NONBLOCK); + event_base_loop(base2, EVLOOP_NONBLOCK); + } +end: + event_base_free(base1); + event_base_free(base2); + cleanup_test(); +} + +/* + * assert that a signal event removed from the event queue really is + * removed - with no possibility of it's parent handler being fired. + */ +static void +test_signal_assert(void) +{ + struct event ev; + struct event_base *base = event_init(); + test_ok = 0; + /* use SIGCONT so we don't kill ourselves when we signal to nowhere */ + evsignal_set(&ev, SIGCONT, signal_cb, &ev); + evsignal_add(&ev, NULL); + /* + * if evsignal_del() fails to reset the handler, it's current handler + * will still point to evsig_handler(). + */ + evsignal_del(&ev); + + raise(SIGCONT); +#if 0 + /* only way to verify we were in evsig_handler() */ + /* XXXX Now there's no longer a good way. */ + if (base->sig.evsig_caught) + test_ok = 0; + else + test_ok = 1; +#else + test_ok = 1; +#endif + + event_base_free(base); + cleanup_test(); + return; +} + +/* + * assert that we restore our previous signal handler properly. + */ +static void +test_signal_restore(void) +{ + struct event ev; + struct event_base *base = event_init(); +#ifdef EVENT__HAVE_SIGACTION + struct sigaction sa; +#endif + + test_ok = 0; +#ifdef EVENT__HAVE_SIGACTION + sa.sa_handler = signal_cb_sa; + sa.sa_flags = 0x0; + sigemptyset(&sa.sa_mask); + if (sigaction(SIGUSR1, &sa, NULL) == -1) + goto out; +#else + if (signal(SIGUSR1, signal_cb_sa) == SIG_ERR) + goto out; +#endif + evsignal_set(&ev, SIGUSR1, signal_cb, &ev); + evsignal_add(&ev, NULL); + evsignal_del(&ev); + + raise(SIGUSR1); + /* 1 == signal_cb, 2 == signal_cb_sa, we want our previous handler */ + if (test_ok != 2) + test_ok = 0; +out: + event_base_free(base); + cleanup_test(); + return; +} + +static void +signal_cb_swp(int sig, short event, void *arg) +{ + called++; + if (called < 5) + raise(sig); + else + event_loopexit(NULL); +} +static void +timeout_cb_swp(evutil_socket_t fd, short event, void *arg) +{ + if (called == -1) { + struct timeval tv = {5, 0}; + + called = 0; + evtimer_add((struct event *)arg, &tv); + raise(SIGUSR1); + return; + } + test_ok = 0; + event_loopexit(NULL); +} + +static void +test_signal_while_processing(void) +{ + struct event_base *base = event_init(); + struct event ev, ev_timer; + struct timeval tv = {0, 0}; + + setup_test("Receiving a signal while processing other signal: "); + + called = -1; + test_ok = 1; + signal_set(&ev, SIGUSR1, signal_cb_swp, NULL); + signal_add(&ev, NULL); + evtimer_set(&ev_timer, timeout_cb_swp, &ev_timer); + evtimer_add(&ev_timer, &tv); + event_dispatch(); + + event_base_free(base); + cleanup_test(); + return; +} +#endif + +static void +test_free_active_base(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base1; + struct event ev1; + + base1 = event_init(); + if (base1) { + event_assign(&ev1, base1, data->pair[1], EV_READ, + dummy_read_cb, NULL); + event_add(&ev1, NULL); + event_base_free(base1); /* should not crash */ + } else { + tt_fail_msg("failed to create event_base for test"); + } + + base1 = event_init(); + tt_assert(base1); + event_assign(&ev1, base1, 0, 0, dummy_read_cb, NULL); + event_active(&ev1, EV_READ, 1); + event_base_free(base1); +end: + ; +} + +static void +test_manipulate_active_events(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + struct event ev1; + + event_assign(&ev1, base, -1, EV_TIMEOUT, dummy_read_cb, NULL); + + /* Make sure an active event is pending. */ + event_active(&ev1, EV_READ, 1); + tt_int_op(event_pending(&ev1, EV_READ|EV_TIMEOUT|EV_WRITE, NULL), + ==, EV_READ); + + /* Make sure that activating an event twice works. */ + event_active(&ev1, EV_WRITE, 1); + tt_int_op(event_pending(&ev1, EV_READ|EV_TIMEOUT|EV_WRITE, NULL), + ==, EV_READ|EV_WRITE); + +end: + event_del(&ev1); +} + +static void +event_selfarg_cb(evutil_socket_t fd, short event, void *arg) +{ + struct event *ev = arg; + struct event_base *base = event_get_base(ev); + event_base_assert_ok_(base); + event_base_loopexit(base, NULL); + tt_want(ev == event_base_get_running_event(base)); +} + +static void +test_event_new_selfarg(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + struct event *ev = event_new(base, -1, EV_READ, event_selfarg_cb, + event_self_cbarg()); + + event_active(ev, EV_READ, 1); + event_base_dispatch(base); + + event_free(ev); +} + +static void +test_event_assign_selfarg(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + struct event ev; + + event_assign(&ev, base, -1, EV_READ, event_selfarg_cb, + event_self_cbarg()); + event_active(&ev, EV_READ, 1); + event_base_dispatch(base); +} + +static void +test_event_base_get_num_events(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + struct event ev; + int event_count_active; + int event_count_virtual; + int event_count_added; + int event_count_active_virtual; + int event_count_active_added; + int event_count_virtual_added; + int event_count_active_added_virtual; + + struct timeval qsec = {0, 100000}; + + event_assign(&ev, base, -1, EV_READ, event_selfarg_cb, + event_self_cbarg()); + + event_add(&ev, &qsec); + event_count_active = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE); + event_count_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL); + event_count_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ADDED); + event_count_active_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_VIRTUAL); + event_count_active_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_ADDED); + event_count_virtual_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL|EVENT_BASE_COUNT_ADDED); + event_count_active_added_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE| + EVENT_BASE_COUNT_ADDED| + EVENT_BASE_COUNT_VIRTUAL); + tt_int_op(event_count_active, ==, 0); + tt_int_op(event_count_virtual, ==, 0); + /* libevent itself adds a timeout event, so the event_count is 2 here */ + tt_int_op(event_count_added, ==, 2); + tt_int_op(event_count_active_virtual, ==, 0); + tt_int_op(event_count_active_added, ==, 2); + tt_int_op(event_count_virtual_added, ==, 2); + tt_int_op(event_count_active_added_virtual, ==, 2); + + event_active(&ev, EV_READ, 1); + event_count_active = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE); + event_count_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL); + event_count_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ADDED); + event_count_active_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_VIRTUAL); + event_count_active_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_ADDED); + event_count_virtual_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL|EVENT_BASE_COUNT_ADDED); + event_count_active_added_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE| + EVENT_BASE_COUNT_ADDED| + EVENT_BASE_COUNT_VIRTUAL); + tt_int_op(event_count_active, ==, 1); + tt_int_op(event_count_virtual, ==, 0); + tt_int_op(event_count_added, ==, 3); + tt_int_op(event_count_active_virtual, ==, 1); + tt_int_op(event_count_active_added, ==, 4); + tt_int_op(event_count_virtual_added, ==, 3); + tt_int_op(event_count_active_added_virtual, ==, 4); + + event_base_loop(base, 0); + event_count_active = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE); + event_count_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL); + event_count_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ADDED); + event_count_active_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_VIRTUAL); + event_count_active_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_ADDED); + event_count_virtual_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL|EVENT_BASE_COUNT_ADDED); + event_count_active_added_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE| + EVENT_BASE_COUNT_ADDED| + EVENT_BASE_COUNT_VIRTUAL); + tt_int_op(event_count_active, ==, 0); + tt_int_op(event_count_virtual, ==, 0); + tt_int_op(event_count_added, ==, 0); + tt_int_op(event_count_active_virtual, ==, 0); + tt_int_op(event_count_active_added, ==, 0); + tt_int_op(event_count_virtual_added, ==, 0); + tt_int_op(event_count_active_added_virtual, ==, 0); + + event_base_add_virtual_(base); + event_count_active = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE); + event_count_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL); + event_count_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ADDED); + event_count_active_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_VIRTUAL); + event_count_active_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE|EVENT_BASE_COUNT_ADDED); + event_count_virtual_added = event_base_get_num_events(base, + EVENT_BASE_COUNT_VIRTUAL|EVENT_BASE_COUNT_ADDED); + event_count_active_added_virtual = event_base_get_num_events(base, + EVENT_BASE_COUNT_ACTIVE| + EVENT_BASE_COUNT_ADDED| + EVENT_BASE_COUNT_VIRTUAL); + tt_int_op(event_count_active, ==, 0); + tt_int_op(event_count_virtual, ==, 1); + tt_int_op(event_count_added, ==, 0); + tt_int_op(event_count_active_virtual, ==, 1); + tt_int_op(event_count_active_added, ==, 0); + tt_int_op(event_count_virtual_added, ==, 1); + tt_int_op(event_count_active_added_virtual, ==, 1); + +end: + ; +} + +static void +test_event_base_get_max_events(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + struct event ev; + struct event ev2; + int event_count_active; + int event_count_virtual; + int event_count_added; + int event_count_active_virtual; + int event_count_active_added; + int event_count_virtual_added; + int event_count_active_added_virtual; + + struct timeval qsec = {0, 100000}; + + event_assign(&ev, base, -1, EV_READ, event_selfarg_cb, + event_self_cbarg()); + event_assign(&ev2, base, -1, EV_READ, event_selfarg_cb, + event_self_cbarg()); + + event_add(&ev, &qsec); + event_add(&ev2, &qsec); + event_del(&ev2); + + event_count_active = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE, 0); + event_count_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ADDED, 0); + event_count_active_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_active_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_ADDED, 0); + event_count_virtual_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL | EVENT_BASE_COUNT_ADDED, 0); + event_count_active_added_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | + EVENT_BASE_COUNT_ADDED | + EVENT_BASE_COUNT_VIRTUAL, 0); + + tt_int_op(event_count_active, ==, 0); + tt_int_op(event_count_virtual, ==, 0); + /* libevent itself adds a timeout event, so the event_count is 4 here */ + tt_int_op(event_count_added, ==, 4); + tt_int_op(event_count_active_virtual, ==, 0); + tt_int_op(event_count_active_added, ==, 4); + tt_int_op(event_count_virtual_added, ==, 4); + tt_int_op(event_count_active_added_virtual, ==, 4); + + event_active(&ev, EV_READ, 1); + event_count_active = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE, 0); + event_count_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ADDED, 0); + event_count_active_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_active_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_ADDED, 0); + event_count_virtual_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL | EVENT_BASE_COUNT_ADDED, 0); + event_count_active_added_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | + EVENT_BASE_COUNT_ADDED | + EVENT_BASE_COUNT_VIRTUAL, 0); + + tt_int_op(event_count_active, ==, 1); + tt_int_op(event_count_virtual, ==, 0); + tt_int_op(event_count_added, ==, 4); + tt_int_op(event_count_active_virtual, ==, 1); + tt_int_op(event_count_active_added, ==, 5); + tt_int_op(event_count_virtual_added, ==, 4); + tt_int_op(event_count_active_added_virtual, ==, 5); + + event_base_loop(base, 0); + event_count_active = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE, 1); + event_count_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL, 1); + event_count_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ADDED, 1); + event_count_active_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_active_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_ADDED, 0); + event_count_virtual_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL | EVENT_BASE_COUNT_ADDED, 0); + event_count_active_added_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | + EVENT_BASE_COUNT_ADDED | + EVENT_BASE_COUNT_VIRTUAL, 1); + + tt_int_op(event_count_active, ==, 1); + tt_int_op(event_count_virtual, ==, 0); + tt_int_op(event_count_added, ==, 4); + tt_int_op(event_count_active_virtual, ==, 0); + tt_int_op(event_count_active_added, ==, 0); + tt_int_op(event_count_virtual_added, ==, 0); + tt_int_op(event_count_active_added_virtual, ==, 0); + + event_count_active = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE, 0); + event_count_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ADDED, 0); + tt_int_op(event_count_active, ==, 0); + tt_int_op(event_count_virtual, ==, 0); + tt_int_op(event_count_added, ==, 0); + + event_base_add_virtual_(base); + event_count_active = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE, 0); + event_count_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ADDED, 0); + event_count_active_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_VIRTUAL, 0); + event_count_active_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | EVENT_BASE_COUNT_ADDED, 0); + event_count_virtual_added = event_base_get_max_events(base, + EVENT_BASE_COUNT_VIRTUAL | EVENT_BASE_COUNT_ADDED, 0); + event_count_active_added_virtual = event_base_get_max_events(base, + EVENT_BASE_COUNT_ACTIVE | + EVENT_BASE_COUNT_ADDED | + EVENT_BASE_COUNT_VIRTUAL, 0); + + tt_int_op(event_count_active, ==, 0); + tt_int_op(event_count_virtual, ==, 1); + tt_int_op(event_count_added, ==, 0); + tt_int_op(event_count_active_virtual, ==, 1); + tt_int_op(event_count_active_added, ==, 0); + tt_int_op(event_count_virtual_added, ==, 1); + tt_int_op(event_count_active_added_virtual, ==, 1); + +end: + ; +} + +static void +test_bad_assign(void *ptr) +{ + struct event ev; + int r; + /* READ|SIGNAL is not allowed */ + r = event_assign(&ev, NULL, -1, EV_SIGNAL|EV_READ, dummy_read_cb, NULL); + tt_int_op(r,==,-1); + +end: + ; +} + +static int reentrant_cb_run = 0; + +static void +bad_reentrant_run_loop_cb(evutil_socket_t fd, short what, void *ptr) +{ + struct event_base *base = ptr; + int r; + reentrant_cb_run = 1; + /* This reentrant call to event_base_loop should be detected and + * should fail */ + r = event_base_loop(base, 0); + tt_int_op(r, ==, -1); +end: + ; +} + +static void +test_bad_reentrant(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + struct event ev; + int r; + event_assign(&ev, base, -1, + 0, bad_reentrant_run_loop_cb, base); + + event_active(&ev, EV_WRITE, 1); + r = event_base_loop(base, 0); + tt_int_op(r, ==, 1); + tt_int_op(reentrant_cb_run, ==, 1); +end: + ; +} + +static int n_write_a_byte_cb=0; +static int n_read_and_drain_cb=0; +static int n_activate_other_event_cb=0; +static void +write_a_byte_cb(evutil_socket_t fd, short what, void *arg) +{ + char buf[] = "x"; + if (write(fd, buf, 1) == 1) + ++n_write_a_byte_cb; +} +static void +read_and_drain_cb(evutil_socket_t fd, short what, void *arg) +{ + char buf[128]; + int n; + ++n_read_and_drain_cb; + while ((n = read(fd, buf, sizeof(buf))) > 0) + ; +} + +static void +activate_other_event_cb(evutil_socket_t fd, short what, void *other_) +{ + struct event *ev_activate = other_; + ++n_activate_other_event_cb; + event_active_later_(ev_activate, EV_READ); +} + +static void +test_active_later(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event *ev1 = NULL, *ev2 = NULL; + struct event ev3, ev4; + struct timeval qsec = {0, 100000}; + ev1 = event_new(data->base, data->pair[0], EV_READ|EV_PERSIST, read_and_drain_cb, NULL); + ev2 = event_new(data->base, data->pair[1], EV_WRITE|EV_PERSIST, write_a_byte_cb, NULL); + event_assign(&ev3, data->base, -1, 0, activate_other_event_cb, &ev4); + event_assign(&ev4, data->base, -1, 0, activate_other_event_cb, &ev3); + event_add(ev1, NULL); + event_add(ev2, NULL); + event_active_later_(&ev3, EV_READ); + + event_base_loopexit(data->base, &qsec); + + event_base_loop(data->base, 0); + + TT_BLATHER(("%d write calls, %d read calls, %d activate-other calls.", + n_write_a_byte_cb, n_read_and_drain_cb, n_activate_other_event_cb)); + event_del(&ev3); + event_del(&ev4); + + tt_int_op(n_write_a_byte_cb, ==, n_activate_other_event_cb); + tt_int_op(n_write_a_byte_cb, >, 100); + tt_int_op(n_read_and_drain_cb, >, 100); + tt_int_op(n_activate_other_event_cb, >, 100); + + event_active_later_(&ev4, EV_READ); + event_active(&ev4, EV_READ, 1); /* This should make the event + active immediately. */ + tt_assert((ev4.ev_flags & EVLIST_ACTIVE) != 0); + tt_assert((ev4.ev_flags & EVLIST_ACTIVE_LATER) == 0); + + /* Now leave this one around, so that event_free sees it and removes + * it. */ + event_active_later_(&ev3, EV_READ); + event_base_assert_ok_(data->base); + +end: + if (ev1) + event_free(ev1); + if (ev2) + event_free(ev2); + + event_base_free(data->base); + data->base = NULL; +} + + +static void incr_arg_cb(evutil_socket_t fd, short what, void *arg) +{ + int *intptr = arg; + (void) fd; (void) what; + ++*intptr; +} +static void remove_timers_cb(evutil_socket_t fd, short what, void *arg) +{ + struct event **ep = arg; + (void) fd; (void) what; + event_remove_timer(ep[0]); + event_remove_timer(ep[1]); +} +static void send_a_byte_cb(evutil_socket_t fd, short what, void *arg) +{ + evutil_socket_t *sockp = arg; + (void) fd; (void) what; + (void) write(*sockp, "A", 1); +} +struct read_not_timeout_param +{ + struct event **ev; + int events; + int count; +}; +static void read_not_timeout_cb(evutil_socket_t fd, short what, void *arg) +{ + struct read_not_timeout_param *rntp = arg; + char c; + ev_ssize_t n; + (void) fd; (void) what; + n = read(fd, &c, 1); + tt_int_op(n, ==, 1); + rntp->events |= what; + ++rntp->count; + if(2 == rntp->count) event_del(rntp->ev[0]); +end: + ; +} + +static void +test_event_remove_timeout(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = data->base; + struct event *ev[5]; + int ev1_fired=0; + struct timeval ms25 = { 0, 25*1000 }, + ms40 = { 0, 40*1000 }, + ms75 = { 0, 75*1000 }, + ms125 = { 0, 125*1000 }; + struct read_not_timeout_param rntp = { ev, 0, 0 }; + + event_base_assert_ok_(base); + + ev[0] = event_new(base, data->pair[0], EV_READ|EV_PERSIST, + read_not_timeout_cb, &rntp); + ev[1] = evtimer_new(base, incr_arg_cb, &ev1_fired); + ev[2] = evtimer_new(base, remove_timers_cb, ev); + ev[3] = evtimer_new(base, send_a_byte_cb, &data->pair[1]); + ev[4] = evtimer_new(base, send_a_byte_cb, &data->pair[1]); + tt_assert(base); + event_add(ev[2], &ms25); /* remove timers */ + event_add(ev[4], &ms40); /* write to test if timer re-activates */ + event_add(ev[0], &ms75); /* read */ + event_add(ev[1], &ms75); /* timer */ + event_add(ev[3], &ms125); /* timeout. */ + event_base_assert_ok_(base); + + event_base_dispatch(base); + + tt_int_op(ev1_fired, ==, 0); + tt_int_op(rntp.events, ==, EV_READ); + + event_base_assert_ok_(base); +end: + event_free(ev[0]); + event_free(ev[1]); + event_free(ev[2]); + event_free(ev[3]); + event_free(ev[4]); +} + +static void +test_event_base_new(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event_base *base = 0; + struct event ev1; + struct basic_cb_args args; + + int towrite = (int)strlen(TEST1)+1; + int len = write(data->pair[0], TEST1, towrite); + + if (len < 0) + tt_abort_perror("initial write"); + else if (len != towrite) + tt_abort_printf(("initial write fell short (%d of %d bytes)", + len, towrite)); + + if (shutdown(data->pair[0], SHUT_WR)) + tt_abort_perror("initial write shutdown"); + + base = event_base_new(); + if (!base) + tt_abort_msg("failed to create event base"); + + args.eb = base; + args.ev = &ev1; + args.callcount = 0; + event_assign(&ev1, base, data->pair[1], + EV_READ|EV_PERSIST, basic_read_cb, &args); + + if (event_add(&ev1, NULL)) + tt_abort_perror("initial event_add"); + + if (event_base_loop(base, 0)) + tt_abort_msg("unsuccessful exit from event loop"); + +end: + if (base) + event_base_free(base); +} + +static void +test_loopexit(void) +{ + struct timeval tv, tv_start, tv_end; + struct event ev; + + setup_test("Loop exit: "); + + tv.tv_usec = 0; + tv.tv_sec = 60*60*24; + evtimer_set(&ev, timeout_cb, NULL); + evtimer_add(&ev, &tv); + + tv.tv_usec = 300*1000; + tv.tv_sec = 0; + event_loopexit(&tv); + + evutil_gettimeofday(&tv_start, NULL); + event_dispatch(); + evutil_gettimeofday(&tv_end, NULL); + + evtimer_del(&ev); + + tt_assert(event_base_got_exit(global_base)); + tt_assert(!event_base_got_break(global_base)); + + test_timeval_diff_eq(&tv_start, &tv_end, 300); + + test_ok = 1; +end: + cleanup_test(); +} + +static void +test_loopexit_multiple(void) +{ + struct timeval tv, tv_start, tv_end; + struct event_base *base; + + setup_test("Loop Multiple exit: "); + + base = event_base_new(); + + tv.tv_usec = 200*1000; + tv.tv_sec = 0; + event_base_loopexit(base, &tv); + + tv.tv_usec = 0; + tv.tv_sec = 3; + event_base_loopexit(base, &tv); + + evutil_gettimeofday(&tv_start, NULL); + event_base_dispatch(base); + evutil_gettimeofday(&tv_end, NULL); + + tt_assert(event_base_got_exit(base)); + tt_assert(!event_base_got_break(base)); + + event_base_free(base); + + test_timeval_diff_eq(&tv_start, &tv_end, 200); + + test_ok = 1; + +end: + cleanup_test(); +} + +static void +break_cb(evutil_socket_t fd, short events, void *arg) +{ + test_ok = 1; + event_loopbreak(); +} + +static void +fail_cb(evutil_socket_t fd, short events, void *arg) +{ + test_ok = 0; +} + +static void +test_loopbreak(void) +{ + struct event ev1, ev2; + struct timeval tv; + + setup_test("Loop break: "); + + tv.tv_sec = 0; + tv.tv_usec = 0; + evtimer_set(&ev1, break_cb, NULL); + evtimer_add(&ev1, &tv); + evtimer_set(&ev2, fail_cb, NULL); + evtimer_add(&ev2, &tv); + + event_dispatch(); + + tt_assert(!event_base_got_exit(global_base)); + tt_assert(event_base_got_break(global_base)); + + evtimer_del(&ev1); + evtimer_del(&ev2); + +end: + cleanup_test(); +} + +static struct event *readd_test_event_last_added = NULL; +static void +re_add_read_cb(evutil_socket_t fd, short event, void *arg) +{ + char buf[256]; + struct event *ev_other = arg; + ev_ssize_t n_read; + + readd_test_event_last_added = ev_other; + + n_read = read(fd, buf, sizeof(buf)); + + if (n_read < 0) { + tt_fail_perror("read"); + event_base_loopbreak(event_get_base(ev_other)); + return; + } else { + event_add(ev_other, NULL); + ++test_ok; + } +} + +static void +test_nonpersist_readd(void) +{ + struct event ev1, ev2; + + setup_test("Re-add nonpersistent events: "); + event_set(&ev1, pair[0], EV_READ, re_add_read_cb, &ev2); + event_set(&ev2, pair[1], EV_READ, re_add_read_cb, &ev1); + + if (write(pair[0], "Hello", 5) < 0) { + tt_fail_perror("write(pair[0])"); + } + + if (write(pair[1], "Hello", 5) < 0) { + tt_fail_perror("write(pair[1])\n"); + } + + if (event_add(&ev1, NULL) == -1 || + event_add(&ev2, NULL) == -1) { + test_ok = 0; + } + if (test_ok != 0) + exit(1); + event_loop(EVLOOP_ONCE); + if (test_ok != 2) + exit(1); + /* At this point, we executed both callbacks. Whichever one got + * called first added the second, but the second then immediately got + * deleted before its callback was called. At this point, though, it + * re-added the first. + */ + if (!readd_test_event_last_added) { + test_ok = 0; + } else if (readd_test_event_last_added == &ev1) { + if (!event_pending(&ev1, EV_READ, NULL) || + event_pending(&ev2, EV_READ, NULL)) + test_ok = 0; + } else { + if (event_pending(&ev1, EV_READ, NULL) || + !event_pending(&ev2, EV_READ, NULL)) + test_ok = 0; + } + + event_del(&ev1); + event_del(&ev2); + + cleanup_test(); +} + +struct test_pri_event { + struct event ev; + int count; +}; + +static void +test_priorities_cb(evutil_socket_t fd, short what, void *arg) +{ + struct test_pri_event *pri = arg; + struct timeval tv; + + if (pri->count == 3) { + event_loopexit(NULL); + return; + } + + pri->count++; + + evutil_timerclear(&tv); + event_add(&pri->ev, &tv); +} + +static void +test_priorities_impl(int npriorities) +{ + struct test_pri_event one, two; + struct timeval tv; + + TT_BLATHER(("Testing Priorities %d: ", npriorities)); + + event_base_priority_init(global_base, npriorities); + + memset(&one, 0, sizeof(one)); + memset(&two, 0, sizeof(two)); + + timeout_set(&one.ev, test_priorities_cb, &one); + if (event_priority_set(&one.ev, 0) == -1) { + fprintf(stderr, "%s: failed to set priority", __func__); + exit(1); + } + + timeout_set(&two.ev, test_priorities_cb, &two); + if (event_priority_set(&two.ev, npriorities - 1) == -1) { + fprintf(stderr, "%s: failed to set priority", __func__); + exit(1); + } + + evutil_timerclear(&tv); + + if (event_add(&one.ev, &tv) == -1) + exit(1); + if (event_add(&two.ev, &tv) == -1) + exit(1); + + event_dispatch(); + + event_del(&one.ev); + event_del(&two.ev); + + if (npriorities == 1) { + if (one.count == 3 && two.count == 3) + test_ok = 1; + } else if (npriorities == 2) { + /* Two is called once because event_loopexit is priority 1 */ + if (one.count == 3 && two.count == 1) + test_ok = 1; + } else { + if (one.count == 3 && two.count == 0) + test_ok = 1; + } +} + +static void +test_priorities(void) +{ + test_priorities_impl(1); + if (test_ok) + test_priorities_impl(2); + if (test_ok) + test_priorities_impl(3); +} + +/* priority-active-inversion: activate a higher-priority event, and make sure + * it keeps us from running a lower-priority event first. */ +static int n_pai_calls = 0; +static struct event pai_events[3]; + +static void +prio_active_inversion_cb(evutil_socket_t fd, short what, void *arg) +{ + int *call_order = arg; + *call_order = n_pai_calls++; + if (n_pai_calls == 1) { + /* This should activate later, even though it shares a + priority with us. */ + event_active(&pai_events[1], EV_READ, 1); + /* This should activate next, since its priority is higher, + even though we activated it second. */ + event_active(&pai_events[2], EV_TIMEOUT, 1); + } +} + +static void +test_priority_active_inversion(void *data_) +{ + struct basic_test_data *data = data_; + struct event_base *base = data->base; + int call_order[3]; + int i; + tt_int_op(event_base_priority_init(base, 8), ==, 0); + + n_pai_calls = 0; + memset(call_order, 0, sizeof(call_order)); + + for (i=0;i<3;++i) { + event_assign(&pai_events[i], data->base, -1, 0, + prio_active_inversion_cb, &call_order[i]); + } + + event_priority_set(&pai_events[0], 4); + event_priority_set(&pai_events[1], 4); + event_priority_set(&pai_events[2], 0); + + event_active(&pai_events[0], EV_WRITE, 1); + + event_base_dispatch(base); + tt_int_op(n_pai_calls, ==, 3); + tt_int_op(call_order[0], ==, 0); + tt_int_op(call_order[1], ==, 2); + tt_int_op(call_order[2], ==, 1); +end: + ; +} + + +static void +test_multiple_cb(evutil_socket_t fd, short event, void *arg) +{ + if (event & EV_READ) + test_ok |= 1; + else if (event & EV_WRITE) + test_ok |= 2; +} + +static void +test_multiple_events_for_same_fd(void) +{ + struct event e1, e2; + + setup_test("Multiple events for same fd: "); + + event_set(&e1, pair[0], EV_READ, test_multiple_cb, NULL); + event_add(&e1, NULL); + event_set(&e2, pair[0], EV_WRITE, test_multiple_cb, NULL); + event_add(&e2, NULL); + event_loop(EVLOOP_ONCE); + event_del(&e2); + + if (write(pair[1], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + } + + event_loop(EVLOOP_ONCE); + event_del(&e1); + + if (test_ok != 3) + test_ok = 0; + + cleanup_test(); +} + +int evtag_decode_int(ev_uint32_t *pnumber, struct evbuffer *evbuf); +int evtag_decode_int64(ev_uint64_t *pnumber, struct evbuffer *evbuf); +int evtag_encode_tag(struct evbuffer *evbuf, ev_uint32_t number); +int evtag_decode_tag(ev_uint32_t *pnumber, struct evbuffer *evbuf); + +static void +read_once_cb(evutil_socket_t fd, short event, void *arg) +{ + char buf[256]; + int len; + + len = read(fd, buf, sizeof(buf)); + + if (called) { + test_ok = 0; + } else if (len) { + /* Assumes global pair[0] can be used for writing */ + if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + test_ok = 0; + } else { + test_ok = 1; + } + } + + called++; +} + +static void +test_want_only_once(void) +{ + struct event ev; + struct timeval tv; + + /* Very simple read test */ + setup_test("Want read only once: "); + + if (write(pair[0], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + } + + /* Setup the loop termination */ + evutil_timerclear(&tv); + tv.tv_usec = 300*1000; + event_loopexit(&tv); + + event_set(&ev, pair[1], EV_READ, read_once_cb, &ev); + if (event_add(&ev, NULL) == -1) + exit(1); + event_dispatch(); + + cleanup_test(); +} + +#define TEST_MAX_INT 6 + +static void +evtag_int_test(void *ptr) +{ + struct evbuffer *tmp = evbuffer_new(); + ev_uint32_t integers[TEST_MAX_INT] = { + 0xaf0, 0x1000, 0x1, 0xdeadbeef, 0x00, 0xbef000 + }; + ev_uint32_t integer; + ev_uint64_t big_int; + int i; + + evtag_init(); + + for (i = 0; i < TEST_MAX_INT; i++) { + int oldlen, newlen; + oldlen = (int)EVBUFFER_LENGTH(tmp); + evtag_encode_int(tmp, integers[i]); + newlen = (int)EVBUFFER_LENGTH(tmp); + TT_BLATHER(("encoded 0x%08x with %d bytes", + (unsigned)integers[i], newlen - oldlen)); + big_int = integers[i]; + big_int *= 1000000000; /* 1 billion */ + evtag_encode_int64(tmp, big_int); + } + + for (i = 0; i < TEST_MAX_INT; i++) { + tt_int_op(evtag_decode_int(&integer, tmp), !=, -1); + tt_uint_op(integer, ==, integers[i]); + tt_int_op(evtag_decode_int64(&big_int, tmp), !=, -1); + tt_assert((big_int / 1000000000) == integers[i]); + } + + tt_uint_op(EVBUFFER_LENGTH(tmp), ==, 0); +end: + evbuffer_free(tmp); +} + +static void +evtag_fuzz(void *ptr) +{ + u_char buffer[4096]; + struct evbuffer *tmp = evbuffer_new(); + struct timeval tv; + int i, j; + + int not_failed = 0; + + evtag_init(); + + for (j = 0; j < 100; j++) { + for (i = 0; i < (int)sizeof(buffer); i++) + buffer[i] = test_weakrand(); + evbuffer_drain(tmp, -1); + evbuffer_add(tmp, buffer, sizeof(buffer)); + + if (evtag_unmarshal_timeval(tmp, 0, &tv) != -1) + not_failed++; + } + + /* The majority of decodes should fail */ + tt_int_op(not_failed, <, 10); + + /* Now insert some corruption into the tag length field */ + evbuffer_drain(tmp, -1); + evutil_timerclear(&tv); + tv.tv_sec = 1; + evtag_marshal_timeval(tmp, 0, &tv); + evbuffer_add(tmp, buffer, sizeof(buffer)); + + ((char *)EVBUFFER_DATA(tmp))[1] = '\xff'; + if (evtag_unmarshal_timeval(tmp, 0, &tv) != -1) { + tt_abort_msg("evtag_unmarshal_timeval should have failed"); + } + +end: + evbuffer_free(tmp); +} + +static void +evtag_tag_encoding(void *ptr) +{ + struct evbuffer *tmp = evbuffer_new(); + ev_uint32_t integers[TEST_MAX_INT] = { + 0xaf0, 0x1000, 0x1, 0xdeadbeef, 0x00, 0xbef000 + }; + ev_uint32_t integer; + int i; + + evtag_init(); + + for (i = 0; i < TEST_MAX_INT; i++) { + int oldlen, newlen; + oldlen = (int)EVBUFFER_LENGTH(tmp); + evtag_encode_tag(tmp, integers[i]); + newlen = (int)EVBUFFER_LENGTH(tmp); + TT_BLATHER(("encoded 0x%08x with %d bytes", + (unsigned)integers[i], newlen - oldlen)); + } + + for (i = 0; i < TEST_MAX_INT; i++) { + tt_int_op(evtag_decode_tag(&integer, tmp), !=, -1); + tt_uint_op(integer, ==, integers[i]); + } + + tt_uint_op(EVBUFFER_LENGTH(tmp), ==, 0); + +end: + evbuffer_free(tmp); +} + +static void +evtag_test_peek(void *ptr) +{ + struct evbuffer *tmp = evbuffer_new(); + ev_uint32_t u32; + + evtag_marshal_int(tmp, 30, 0); + evtag_marshal_string(tmp, 40, "Hello world"); + + tt_int_op(evtag_peek(tmp, &u32), ==, 1); + tt_int_op(u32, ==, 30); + tt_int_op(evtag_peek_length(tmp, &u32), ==, 0); + tt_int_op(u32, ==, 1+1+1); + tt_int_op(evtag_consume(tmp), ==, 0); + + tt_int_op(evtag_peek(tmp, &u32), ==, 1); + tt_int_op(u32, ==, 40); + tt_int_op(evtag_peek_length(tmp, &u32), ==, 0); + tt_int_op(u32, ==, 1+1+11); + tt_int_op(evtag_payload_length(tmp, &u32), ==, 0); + tt_int_op(u32, ==, 11); + +end: + evbuffer_free(tmp); +} + + +static void +test_methods(void *ptr) +{ + const char **methods = event_get_supported_methods(); + struct event_config *cfg = NULL; + struct event_base *base = NULL; + const char *backend; + int n_methods = 0; + + tt_assert(methods); + + backend = methods[0]; + while (*methods != NULL) { + TT_BLATHER(("Support method: %s", *methods)); + ++methods; + ++n_methods; + } + + cfg = event_config_new(); + assert(cfg != NULL); + + tt_int_op(event_config_avoid_method(cfg, backend), ==, 0); + event_config_set_flag(cfg, EVENT_BASE_FLAG_IGNORE_ENV); + + base = event_base_new_with_config(cfg); + if (n_methods > 1) { + tt_assert(base); + tt_str_op(backend, !=, event_base_get_method(base)); + } else { + tt_assert(base == NULL); + } + +end: + if (base) + event_base_free(base); + if (cfg) + event_config_free(cfg); +} + +static void +test_version(void *arg) +{ + const char *vstr; + ev_uint32_t vint; + int major, minor, patch, n; + + vstr = event_get_version(); + vint = event_get_version_number(); + + tt_assert(vstr); + tt_assert(vint); + + tt_str_op(vstr, ==, LIBEVENT_VERSION); + tt_int_op(vint, ==, LIBEVENT_VERSION_NUMBER); + + n = sscanf(vstr, "%d.%d.%d", &major, &minor, &patch); + tt_assert(3 == n); + tt_int_op((vint&0xffffff00), ==, ((major<<24)|(minor<<16)|(patch<<8))); +end: + ; +} + +static void +test_base_features(void *arg) +{ + struct event_base *base = NULL; + struct event_config *cfg = NULL; + + cfg = event_config_new(); + + tt_assert(0 == event_config_require_features(cfg, EV_FEATURE_ET)); + + base = event_base_new_with_config(cfg); + if (base) { + tt_int_op(EV_FEATURE_ET, ==, + event_base_get_features(base) & EV_FEATURE_ET); + } else { + base = event_base_new(); + tt_int_op(0, ==, event_base_get_features(base) & EV_FEATURE_ET); + } + +end: + if (base) + event_base_free(base); + if (cfg) + event_config_free(cfg); +} + +#ifdef EVENT__HAVE_SETENV +#define SETENV_OK +#elif !defined(EVENT__HAVE_SETENV) && defined(EVENT__HAVE_PUTENV) +static void setenv(const char *k, const char *v, int o_) +{ + char b[256]; + evutil_snprintf(b, sizeof(b), "%s=%s",k,v); + putenv(b); +} +#define SETENV_OK +#endif + +#ifdef EVENT__HAVE_UNSETENV +#define UNSETENV_OK +#elif !defined(EVENT__HAVE_UNSETENV) && defined(EVENT__HAVE_PUTENV) +static void unsetenv(const char *k) +{ + char b[256]; + evutil_snprintf(b, sizeof(b), "%s=",k); + putenv(b); +} +#define UNSETENV_OK +#endif + +#if defined(SETENV_OK) && defined(UNSETENV_OK) +static void +methodname_to_envvar(const char *mname, char *buf, size_t buflen) +{ + char *cp; + evutil_snprintf(buf, buflen, "EVENT_NO%s", mname); + for (cp = buf; *cp; ++cp) { + *cp = EVUTIL_TOUPPER_(*cp); + } +} +#endif + +static void +test_base_environ(void *arg) +{ + struct event_base *base = NULL; + struct event_config *cfg = NULL; + +#if defined(SETENV_OK) && defined(UNSETENV_OK) + const char **basenames; + int i, n_methods=0; + char varbuf[128]; + const char *defaultname, *ignoreenvname; + + /* See if unsetenv works before we rely on it. */ + setenv("EVENT_NOWAFFLES", "1", 1); + unsetenv("EVENT_NOWAFFLES"); + if (getenv("EVENT_NOWAFFLES") != NULL) { +#ifndef EVENT__HAVE_UNSETENV + TT_DECLARE("NOTE", ("Can't fake unsetenv; skipping test")); +#else + TT_DECLARE("NOTE", ("unsetenv doesn't work; skipping test")); +#endif + tt_skip(); + } + + basenames = event_get_supported_methods(); + for (i = 0; basenames[i]; ++i) { + methodname_to_envvar(basenames[i], varbuf, sizeof(varbuf)); + unsetenv(varbuf); + ++n_methods; + } + + base = event_base_new(); + tt_assert(base); + + defaultname = event_base_get_method(base); + TT_BLATHER(("default is <%s>", defaultname)); + event_base_free(base); + base = NULL; + + /* Can we disable the method with EVENT_NOfoo ? */ + if (!strcmp(defaultname, "epoll (with changelist)")) { + setenv("EVENT_NOEPOLL", "1", 1); + ignoreenvname = "epoll"; + } else { + methodname_to_envvar(defaultname, varbuf, sizeof(varbuf)); + setenv(varbuf, "1", 1); + ignoreenvname = defaultname; + } + + /* Use an empty cfg rather than NULL so a failure doesn't exit() */ + cfg = event_config_new(); + base = event_base_new_with_config(cfg); + event_config_free(cfg); + cfg = NULL; + if (n_methods == 1) { + tt_assert(!base); + } else { + tt_assert(base); + tt_str_op(defaultname, !=, event_base_get_method(base)); + event_base_free(base); + base = NULL; + } + + /* Can we disable looking at the environment with IGNORE_ENV ? */ + cfg = event_config_new(); + event_config_set_flag(cfg, EVENT_BASE_FLAG_IGNORE_ENV); + base = event_base_new_with_config(cfg); + tt_assert(base); + tt_str_op(ignoreenvname, ==, event_base_get_method(base)); +#else + tt_skip(); +#endif + +end: + if (base) + event_base_free(base); + if (cfg) + event_config_free(cfg); +} + +static void +read_called_once_cb(evutil_socket_t fd, short event, void *arg) +{ + tt_int_op(event, ==, EV_READ); + called += 1; +end: + ; +} + +static void +timeout_called_once_cb(evutil_socket_t fd, short event, void *arg) +{ + tt_int_op(event, ==, EV_TIMEOUT); + called += 100; +end: + ; +} + +static void +immediate_called_twice_cb(evutil_socket_t fd, short event, void *arg) +{ + tt_int_op(event, ==, EV_TIMEOUT); + called += 1000; +end: + ; +} + +static void +test_event_once(void *ptr) +{ + struct basic_test_data *data = ptr; + struct timeval tv; + int r; + + tv.tv_sec = 0; + tv.tv_usec = 50*1000; + called = 0; + r = event_base_once(data->base, data->pair[0], EV_READ, + read_called_once_cb, NULL, NULL); + tt_int_op(r, ==, 0); + r = event_base_once(data->base, -1, EV_TIMEOUT, + timeout_called_once_cb, NULL, &tv); + tt_int_op(r, ==, 0); + r = event_base_once(data->base, -1, 0, NULL, NULL, NULL); + tt_int_op(r, <, 0); + r = event_base_once(data->base, -1, EV_TIMEOUT, + immediate_called_twice_cb, NULL, NULL); + tt_int_op(r, ==, 0); + tv.tv_sec = 0; + tv.tv_usec = 0; + r = event_base_once(data->base, -1, EV_TIMEOUT, + immediate_called_twice_cb, NULL, &tv); + tt_int_op(r, ==, 0); + + if (write(data->pair[1], TEST1, strlen(TEST1)+1) < 0) { + tt_fail_perror("write"); + } + + shutdown(data->pair[1], SHUT_WR); + + event_base_dispatch(data->base); + + tt_int_op(called, ==, 2101); +end: + ; +} + +static void +test_event_once_never(void *ptr) +{ + struct basic_test_data *data = ptr; + struct timeval tv; + + /* Have one trigger in 10 seconds (don't worry, because) */ + tv.tv_sec = 10; + tv.tv_usec = 0; + called = 0; + event_base_once(data->base, -1, EV_TIMEOUT, + timeout_called_once_cb, NULL, &tv); + + /* But shut down the base in 75 msec. */ + tv.tv_sec = 0; + tv.tv_usec = 75*1000; + event_base_loopexit(data->base, &tv); + + event_base_dispatch(data->base); + + tt_int_op(called, ==, 0); +end: + ; +} + +static void +test_event_pending(void *ptr) +{ + struct basic_test_data *data = ptr; + struct event *r=NULL, *w=NULL, *t=NULL; + struct timeval tv, now, tv2; + + tv.tv_sec = 0; + tv.tv_usec = 500 * 1000; + r = event_new(data->base, data->pair[0], EV_READ, simple_read_cb, + NULL); + w = event_new(data->base, data->pair[1], EV_WRITE, simple_write_cb, + NULL); + t = evtimer_new(data->base, timeout_cb, NULL); + + tt_assert(r); + tt_assert(w); + tt_assert(t); + + evutil_gettimeofday(&now, NULL); + event_add(r, NULL); + event_add(t, &tv); + + tt_assert( event_pending(r, EV_READ, NULL)); + tt_assert(!event_pending(w, EV_WRITE, NULL)); + tt_assert(!event_pending(r, EV_WRITE, NULL)); + tt_assert( event_pending(r, EV_READ|EV_WRITE, NULL)); + tt_assert(!event_pending(r, EV_TIMEOUT, NULL)); + tt_assert( event_pending(t, EV_TIMEOUT, NULL)); + tt_assert( event_pending(t, EV_TIMEOUT, &tv2)); + + tt_assert(evutil_timercmp(&tv2, &now, >)); + + test_timeval_diff_eq(&now, &tv2, 500); + +end: + if (r) { + event_del(r); + event_free(r); + } + if (w) { + event_del(w); + event_free(w); + } + if (t) { + event_del(t); + event_free(t); + } +} + +#ifndef _WIN32 +/* You can't do this test on windows, since dup2 doesn't work on sockets */ + +static void +dfd_cb(evutil_socket_t fd, short e, void *data) +{ + *(int*)data = (int)e; +} + +/* Regression test for our workaround for a fun epoll/linux related bug + * where fd2 = dup(fd1); add(fd2); close(fd2); dup2(fd1,fd2); add(fd2) + * will get you an EEXIST */ +static void +test_dup_fd(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct event *ev1=NULL, *ev2=NULL; + int fd, dfd=-1; + int ev1_got, ev2_got; + + tt_int_op(write(data->pair[0], "Hello world", + strlen("Hello world")), >, 0); + fd = data->pair[1]; + + dfd = dup(fd); + tt_int_op(dfd, >=, 0); + + ev1 = event_new(base, fd, EV_READ|EV_PERSIST, dfd_cb, &ev1_got); + ev2 = event_new(base, dfd, EV_READ|EV_PERSIST, dfd_cb, &ev2_got); + ev1_got = ev2_got = 0; + event_add(ev1, NULL); + event_add(ev2, NULL); + event_base_loop(base, EVLOOP_ONCE); + tt_int_op(ev1_got, ==, EV_READ); + tt_int_op(ev2_got, ==, EV_READ); + + /* Now close and delete dfd then dispatch. We need to do the + * dispatch here so that when we add it later, we think there + * was an intermediate delete. */ + close(dfd); + event_del(ev2); + ev1_got = ev2_got = 0; + event_base_loop(base, EVLOOP_ONCE); + tt_want_int_op(ev1_got, ==, EV_READ); + tt_int_op(ev2_got, ==, 0); + + /* Re-duplicate the fd. We need to get the same duplicated + * value that we closed to provoke the epoll quirk. Also, we + * need to change the events to write, or else the old lingering + * read event will make the test pass whether the change was + * successful or not. */ + tt_int_op(dup2(fd, dfd), ==, dfd); + event_free(ev2); + ev2 = event_new(base, dfd, EV_WRITE|EV_PERSIST, dfd_cb, &ev2_got); + event_add(ev2, NULL); + ev1_got = ev2_got = 0; + event_base_loop(base, EVLOOP_ONCE); + tt_want_int_op(ev1_got, ==, EV_READ); + tt_int_op(ev2_got, ==, EV_WRITE); + +end: + if (ev1) + event_free(ev1); + if (ev2) + event_free(ev2); + if (dfd >= 0) + close(dfd); +} +#endif + +#ifdef EVENT__DISABLE_MM_REPLACEMENT +static void +test_mm_functions(void *arg) +{ + tinytest_set_test_skipped_(); +} +#else +static int +check_dummy_mem_ok(void *mem_) +{ + char *mem = mem_; + mem -= 16; + return !memcmp(mem, "{[]}", 16); +} + +static void * +dummy_malloc(size_t len) +{ + char *mem = malloc(len+16); + if (mem == NULL) { + fprintf(stderr, "Unable to allocate memory in dummy_malloc()\n"); + return NULL; + } + memcpy(mem, "{[]}", 16); + return mem+16; +} + +static void * +dummy_realloc(void *mem_, size_t len) +{ + char *mem = mem_; + if (!mem) + return dummy_malloc(len); + tt_want(check_dummy_mem_ok(mem_)); + mem -= 16; + mem = realloc(mem, len+16); + return mem+16; +} + +static void +dummy_free(void *mem_) +{ + char *mem = mem_; + tt_want(check_dummy_mem_ok(mem_)); + mem -= 16; + free(mem); +} + +static void +test_mm_functions(void *arg) +{ + struct event_base *b = NULL; + struct event_config *cfg = NULL; + event_set_mem_functions(dummy_malloc, dummy_realloc, dummy_free); + cfg = event_config_new(); + event_config_avoid_method(cfg, "Nonesuch"); + b = event_base_new_with_config(cfg); + tt_assert(b); + tt_assert(check_dummy_mem_ok(b)); +end: + if (cfg) + event_config_free(cfg); + if (b) + event_base_free(b); +} +#endif + +static void +many_event_cb(evutil_socket_t fd, short event, void *arg) +{ + int *calledp = arg; + *calledp += 1; +} + +static void +test_many_events(void *arg) +{ + /* Try 70 events that should all be ready at once. This will + * exercise the "resize" code on most of the backends, and will make + * sure that we can get past the 64-handle limit of some windows + * functions. */ +#define MANY 70 + + struct basic_test_data *data = arg; + struct event_base *base = data->base; + int one_at_a_time = data->setup_data != NULL; + evutil_socket_t sock[MANY]; + struct event *ev[MANY]; + int called[MANY]; + int i; + int loopflags = EVLOOP_NONBLOCK, evflags=0; + if (one_at_a_time) { + loopflags |= EVLOOP_ONCE; + evflags = EV_PERSIST; + } + + memset(sock, 0xff, sizeof(sock)); + memset(ev, 0, sizeof(ev)); + memset(called, 0, sizeof(called)); + + for (i = 0; i < MANY; ++i) { + /* We need an event that will hit the backend, and that will + * be ready immediately. "Send a datagram" is an easy + * instance of that. */ + sock[i] = socket(AF_INET, SOCK_DGRAM, 0); + tt_assert(sock[i] >= 0); + called[i] = 0; + ev[i] = event_new(base, sock[i], EV_WRITE|evflags, + many_event_cb, &called[i]); + event_add(ev[i], NULL); + if (one_at_a_time) + event_base_loop(base, EVLOOP_NONBLOCK|EVLOOP_ONCE); + } + + event_base_loop(base, loopflags); + + for (i = 0; i < MANY; ++i) { + if (one_at_a_time) + tt_int_op(called[i], ==, MANY - i + 1); + else + tt_int_op(called[i], ==, 1); + } + +end: + for (i = 0; i < MANY; ++i) { + if (ev[i]) + event_free(ev[i]); + if (sock[i] >= 0) + evutil_closesocket(sock[i]); + } +#undef MANY +} + +static void +test_struct_event_size(void *arg) +{ + tt_int_op(event_get_struct_event_size(), <=, sizeof(struct event)); +end: + ; +} + +static void +test_get_assignment(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct event *ev1 = NULL; + const char *str = "foo"; + + struct event_base *b; + evutil_socket_t s; + short what; + event_callback_fn cb; + void *cb_arg; + + ev1 = event_new(base, data->pair[1], EV_READ, dummy_read_cb, (void*)str); + event_get_assignment(ev1, &b, &s, &what, &cb, &cb_arg); + + tt_ptr_op(b, ==, base); + tt_int_op(s, ==, data->pair[1]); + tt_int_op(what, ==, EV_READ); + tt_ptr_op(cb, ==, dummy_read_cb); + tt_ptr_op(cb_arg, ==, str); + + /* Now make sure this doesn't crash. */ + event_get_assignment(ev1, NULL, NULL, NULL, NULL, NULL); + +end: + if (ev1) + event_free(ev1); +} + +struct foreach_helper { + int count; + const struct event *ev; +}; + +static int +foreach_count_cb(const struct event_base *base, const struct event *ev, void *arg) +{ + struct foreach_helper *h = event_get_callback_arg(ev); + struct timeval *tv = arg; + if (event_get_callback(ev) != timeout_cb) + return 0; + tt_ptr_op(event_get_base(ev), ==, base); + tt_int_op(tv->tv_sec, ==, 10); + h->ev = ev; + h->count++; + return 0; +end: + return -1; +} + +static int +foreach_find_cb(const struct event_base *base, const struct event *ev, void *arg) +{ + const struct event **ev_out = arg; + struct foreach_helper *h = event_get_callback_arg(ev); + if (event_get_callback(ev) != timeout_cb) + return 0; + if (h->count == 99) { + *ev_out = ev; + return 101; + } + return 0; +} + +static void +test_event_foreach(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct event *ev[5]; + struct foreach_helper visited[5]; + int i; + struct timeval ten_sec = {10,0}; + const struct event *ev_found = NULL; + + for (i = 0; i < 5; ++i) { + visited[i].count = 0; + visited[i].ev = NULL; + ev[i] = event_new(base, -1, 0, timeout_cb, &visited[i]); + } + + tt_int_op(-1, ==, event_base_foreach_event(NULL, foreach_count_cb, NULL)); + tt_int_op(-1, ==, event_base_foreach_event(base, NULL, NULL)); + + event_add(ev[0], &ten_sec); + event_add(ev[1], &ten_sec); + event_active(ev[1], EV_TIMEOUT, 1); + event_active(ev[2], EV_TIMEOUT, 1); + event_add(ev[3], &ten_sec); + /* Don't touch ev[4]. */ + + tt_int_op(0, ==, event_base_foreach_event(base, foreach_count_cb, + &ten_sec)); + tt_int_op(1, ==, visited[0].count); + tt_int_op(1, ==, visited[1].count); + tt_int_op(1, ==, visited[2].count); + tt_int_op(1, ==, visited[3].count); + tt_ptr_op(ev[0], ==, visited[0].ev); + tt_ptr_op(ev[1], ==, visited[1].ev); + tt_ptr_op(ev[2], ==, visited[2].ev); + tt_ptr_op(ev[3], ==, visited[3].ev); + + visited[2].count = 99; + tt_int_op(101, ==, event_base_foreach_event(base, foreach_find_cb, + &ev_found)); + tt_ptr_op(ev_found, ==, ev[2]); + +end: + for (i=0; i<5; ++i) { + event_free(ev[i]); + } +} + +static struct event_base *cached_time_base = NULL; +static int cached_time_reset = 0; +static int cached_time_sleep = 0; +static void +cache_time_cb(evutil_socket_t fd, short what, void *arg) +{ + struct timeval *tv = arg; + tt_int_op(0, ==, event_base_gettimeofday_cached(cached_time_base, tv)); + if (cached_time_sleep) { + struct timeval delay = { 0, 30*1000 }; + evutil_usleep_(&delay); + } + if (cached_time_reset) { + event_base_update_cache_time(cached_time_base); + } +end: + ; +} + +static void +test_gettimeofday_cached(void *arg) +{ + struct basic_test_data *data = arg; + struct event_config *cfg = NULL; + struct event_base *base = NULL; + struct timeval tv1, tv2, tv3, now; + struct event *ev1=NULL, *ev2=NULL, *ev3=NULL; + int cached_time_disable = strstr(data->setup_data, "disable") != NULL; + + cfg = event_config_new(); + if (cached_time_disable) { + event_config_set_flag(cfg, EVENT_BASE_FLAG_NO_CACHE_TIME); + } + cached_time_base = base = event_base_new_with_config(cfg); + tt_assert(base); + + /* Try gettimeofday_cached outside of an event loop. */ + evutil_gettimeofday(&now, NULL); + tt_int_op(0, ==, event_base_gettimeofday_cached(NULL, &tv1)); + tt_int_op(0, ==, event_base_gettimeofday_cached(base, &tv2)); + tt_int_op(timeval_msec_diff(&tv1, &tv2), <, 10); + tt_int_op(timeval_msec_diff(&tv1, &now), <, 10); + + cached_time_reset = strstr(data->setup_data, "reset") != NULL; + cached_time_sleep = strstr(data->setup_data, "sleep") != NULL; + + ev1 = event_new(base, -1, 0, cache_time_cb, &tv1); + ev2 = event_new(base, -1, 0, cache_time_cb, &tv2); + ev3 = event_new(base, -1, 0, cache_time_cb, &tv3); + + event_active(ev1, EV_TIMEOUT, 1); + event_active(ev2, EV_TIMEOUT, 1); + event_active(ev3, EV_TIMEOUT, 1); + + event_base_dispatch(base); + + if (cached_time_reset && cached_time_sleep) { + tt_int_op(labs(timeval_msec_diff(&tv1,&tv2)), >, 10); + tt_int_op(labs(timeval_msec_diff(&tv2,&tv3)), >, 10); + } else if (cached_time_disable && cached_time_sleep) { + tt_int_op(labs(timeval_msec_diff(&tv1,&tv2)), >, 10); + tt_int_op(labs(timeval_msec_diff(&tv2,&tv3)), >, 10); + } else if (! cached_time_disable) { + tt_assert(evutil_timercmp(&tv1, &tv2, ==)); + tt_assert(evutil_timercmp(&tv2, &tv3, ==)); + } + +end: + if (ev1) + event_free(ev1); + if (ev2) + event_free(ev2); + if (ev3) + event_free(ev3); + if (base) + event_base_free(base); + if (cfg) + event_config_free(cfg); +} + +static void +tabf_cb(evutil_socket_t fd, short what, void *arg) +{ + int *ptr = arg; + *ptr = what; + *ptr += 0x10000; +} + +static void +test_active_by_fd(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct event *ev1 = NULL, *ev2 = NULL, *ev3 = NULL, *ev4 = NULL; + int e1,e2,e3,e4; +#ifndef _WIN32 + struct event *evsig = NULL; + int es; +#endif + struct timeval tenmin = { 600, 0 }; + + /* Ensure no crash on nonexistent FD. */ + event_base_active_by_fd(base, 1000, EV_READ); + + /* Ensure no crash on bogus FD. */ + event_base_active_by_fd(base, -1, EV_READ); + + /* Ensure no crash on nonexistent/bogus signal. */ + event_base_active_by_signal(base, 1000); + event_base_active_by_signal(base, -1); + + event_base_assert_ok_(base); + + e1 = e2 = e3 = e4 = 0; + ev1 = event_new(base, data->pair[0], EV_READ, tabf_cb, &e1); + ev2 = event_new(base, data->pair[0], EV_WRITE, tabf_cb, &e2); + ev3 = event_new(base, data->pair[1], EV_READ, tabf_cb, &e3); + ev4 = event_new(base, data->pair[1], EV_READ, tabf_cb, &e4); + tt_assert(ev1); + tt_assert(ev2); + tt_assert(ev3); + tt_assert(ev4); +#ifndef _WIN32 + evsig = event_new(base, SIGHUP, EV_SIGNAL, tabf_cb, &es); + tt_assert(evsig); + event_add(evsig, &tenmin); +#endif + + event_add(ev1, &tenmin); + event_add(ev2, NULL); + event_add(ev3, NULL); + event_add(ev4, &tenmin); + + + event_base_assert_ok_(base); + + /* Trigger 2, 3, 4 */ + event_base_active_by_fd(base, data->pair[0], EV_WRITE); + event_base_active_by_fd(base, data->pair[1], EV_READ); +#ifndef _WIN32 + event_base_active_by_signal(base, SIGHUP); +#endif + + event_base_assert_ok_(base); + + event_base_loop(base, EVLOOP_ONCE); + + tt_int_op(e1, ==, 0); + tt_int_op(e2, ==, EV_WRITE | 0x10000); + tt_int_op(e3, ==, EV_READ | 0x10000); + /* Mask out EV_WRITE here, since it could be genuinely writeable. */ + tt_int_op((e4 & ~EV_WRITE), ==, EV_READ | 0x10000); +#ifndef _WIN32 + tt_int_op(es, ==, EV_SIGNAL | 0x10000); +#endif + +end: + if (ev1) + event_free(ev1); + if (ev2) + event_free(ev2); + if (ev3) + event_free(ev3); + if (ev4) + event_free(ev4); +#ifndef _WIN32 + if (evsig) + event_free(evsig); +#endif +} + +struct testcase_t main_testcases[] = { + /* Some converted-over tests */ + { "methods", test_methods, TT_FORK, NULL, NULL }, + { "version", test_version, 0, NULL, NULL }, + BASIC(base_features, TT_FORK|TT_NO_LOGS), + { "base_environ", test_base_environ, TT_FORK, NULL, NULL }, + + BASIC(event_base_new, TT_FORK|TT_NEED_SOCKETPAIR), + BASIC(free_active_base, TT_FORK|TT_NEED_SOCKETPAIR), + + BASIC(manipulate_active_events, TT_FORK|TT_NEED_BASE), + BASIC(event_new_selfarg, TT_FORK|TT_NEED_BASE), + BASIC(event_assign_selfarg, TT_FORK|TT_NEED_BASE), + BASIC(event_base_get_num_events, TT_FORK|TT_NEED_BASE), + BASIC(event_base_get_max_events, TT_FORK|TT_NEED_BASE), + + BASIC(bad_assign, TT_FORK|TT_NEED_BASE|TT_NO_LOGS), + BASIC(bad_reentrant, TT_FORK|TT_NEED_BASE|TT_NO_LOGS), + BASIC(active_later, TT_FORK|TT_NEED_BASE|TT_NEED_SOCKETPAIR), + BASIC(event_remove_timeout, TT_FORK|TT_NEED_BASE|TT_NEED_SOCKETPAIR), + + /* These are still using the old API */ + LEGACY(persistent_timeout, TT_FORK|TT_NEED_BASE), + { "persistent_timeout_jump", test_persistent_timeout_jump, TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + { "persistent_active_timeout", test_persistent_active_timeout, + TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + LEGACY(priorities, TT_FORK|TT_NEED_BASE), + BASIC(priority_active_inversion, TT_FORK|TT_NEED_BASE), + { "common_timeout", test_common_timeout, TT_FORK|TT_NEED_BASE, + &basic_setup, NULL }, + + /* These legacy tests may not all need all of these flags. */ + LEGACY(simpleread, TT_ISOLATED), + LEGACY(simpleread_multiple, TT_ISOLATED), + LEGACY(simplewrite, TT_ISOLATED), + { "simpleclose", test_simpleclose, TT_FORK, &basic_setup, + NULL }, + LEGACY(multiple, TT_ISOLATED), + LEGACY(persistent, TT_ISOLATED), + LEGACY(combined, TT_ISOLATED), + LEGACY(simpletimeout, TT_ISOLATED), + LEGACY(loopbreak, TT_ISOLATED), + LEGACY(loopexit, TT_ISOLATED), + LEGACY(loopexit_multiple, TT_ISOLATED), + LEGACY(nonpersist_readd, TT_ISOLATED), + LEGACY(multiple_events_for_same_fd, TT_ISOLATED), + LEGACY(want_only_once, TT_ISOLATED), + { "event_once", test_event_once, TT_ISOLATED, &basic_setup, NULL }, + { "event_once_never", test_event_once_never, TT_ISOLATED, &basic_setup, NULL }, + { "event_pending", test_event_pending, TT_ISOLATED, &basic_setup, + NULL }, +#ifndef _WIN32 + { "dup_fd", test_dup_fd, TT_ISOLATED, &basic_setup, NULL }, +#endif + { "mm_functions", test_mm_functions, TT_FORK, NULL, NULL }, + { "many_events", test_many_events, TT_ISOLATED, &basic_setup, NULL }, + { "many_events_slow_add", test_many_events, TT_ISOLATED, &basic_setup, (void*)1 }, + + { "struct_event_size", test_struct_event_size, 0, NULL, NULL }, + BASIC(get_assignment, TT_FORK|TT_NEED_BASE|TT_NEED_SOCKETPAIR), + + BASIC(event_foreach, TT_FORK|TT_NEED_BASE), + { "gettimeofday_cached", test_gettimeofday_cached, TT_FORK, &basic_setup, (void*)"" }, + { "gettimeofday_cached_sleep", test_gettimeofday_cached, TT_FORK, &basic_setup, (void*)"sleep" }, + { "gettimeofday_cached_reset", test_gettimeofday_cached, TT_FORK, &basic_setup, (void*)"sleep reset" }, + { "gettimeofday_cached_disabled", test_gettimeofday_cached, TT_FORK, &basic_setup, (void*)"sleep disable" }, + { "gettimeofday_cached_disabled_nosleep", test_gettimeofday_cached, TT_FORK, &basic_setup, (void*)"disable" }, + + BASIC(active_by_fd, TT_FORK|TT_NEED_BASE|TT_NEED_SOCKETPAIR), + +#ifndef _WIN32 + LEGACY(fork, TT_ISOLATED), +#endif + END_OF_TESTCASES +}; + +struct testcase_t evtag_testcases[] = { + { "int", evtag_int_test, TT_FORK, NULL, NULL }, + { "fuzz", evtag_fuzz, TT_FORK, NULL, NULL }, + { "encoding", evtag_tag_encoding, TT_FORK, NULL, NULL }, + { "peek", evtag_test_peek, 0, NULL, NULL }, + + END_OF_TESTCASES +}; + +struct testcase_t signal_testcases[] = { +#ifndef _WIN32 + LEGACY(simplestsignal, TT_ISOLATED), + LEGACY(simplesignal, TT_ISOLATED), + LEGACY(multiplesignal, TT_ISOLATED), + LEGACY(immediatesignal, TT_ISOLATED), + LEGACY(signal_dealloc, TT_ISOLATED), + LEGACY(signal_pipeloss, TT_ISOLATED), + LEGACY(signal_switchbase, TT_ISOLATED|TT_NO_LOGS), + LEGACY(signal_restore, TT_ISOLATED), + LEGACY(signal_assert, TT_ISOLATED), + LEGACY(signal_while_processing, TT_ISOLATED), +#endif + END_OF_TESTCASES +}; + diff --git a/contrib/ntp/sntp/libevent/test/regress.gen.c b/contrib/ntp/sntp/libevent/test/regress.gen.c new file mode 100644 index 000000000..8d1c8b69c --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress.gen.c @@ -0,0 +1 @@ + diff --git a/contrib/ntp/sntp/libevent/test/regress.gen.h b/contrib/ntp/sntp/libevent/test/regress.gen.h new file mode 100644 index 000000000..7130984db --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress.gen.h @@ -0,0 +1 @@ +#define NO_PYTHON_EXISTS diff --git a/contrib/ntp/sntp/libevent/test/regress.h b/contrib/ntp/sntp/libevent/test/regress.h new file mode 100644 index 000000000..bbfefe673 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress.h @@ -0,0 +1,136 @@ +/* + * Copyright (c) 2000-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#ifndef REGRESS_H_INCLUDED_ +#define REGRESS_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include "tinytest.h" +#include "tinytest_macros.h" + +extern struct testcase_t main_testcases[]; +extern struct testcase_t evtag_testcases[]; +extern struct testcase_t evbuffer_testcases[]; +extern struct testcase_t finalize_testcases[]; +extern struct testcase_t bufferevent_testcases[]; +extern struct testcase_t bufferevent_iocp_testcases[]; +extern struct testcase_t util_testcases[]; +extern struct testcase_t signal_testcases[]; +extern struct testcase_t http_testcases[]; +extern struct testcase_t dns_testcases[]; +extern struct testcase_t rpc_testcases[]; +extern struct testcase_t edgetriggered_testcases[]; +extern struct testcase_t minheap_testcases[]; +extern struct testcase_t iocp_testcases[]; +extern struct testcase_t ssl_testcases[]; +extern struct testcase_t listener_testcases[]; +extern struct testcase_t listener_iocp_testcases[]; +extern struct testcase_t thread_testcases[]; + +extern struct evutil_weakrand_state test_weakrand_state; + +#define test_weakrand() (evutil_weakrand_(&test_weakrand_state)) + +void regress_threads(void *); +void test_bufferevent_zlib(void *); + +/* Helpers to wrap old testcases */ +extern evutil_socket_t pair[2]; +extern int test_ok; +extern int called; +extern struct event_base *global_base; +extern int in_legacy_test_wrapper; + +int regress_make_tmpfile(const void *data, size_t datalen, char **filename_out); + +struct basic_test_data { + struct event_base *base; + evutil_socket_t pair[2]; + + void (*legacy_test_fn)(void); + + void *setup_data; +}; +extern const struct testcase_setup_t basic_setup; + + +extern const struct testcase_setup_t legacy_setup; +void run_legacy_test_fn(void *ptr); + +extern int libevent_tests_running_in_debug_mode; + +/* A couple of flags that basic/legacy_setup can support. */ +#define TT_NEED_SOCKETPAIR TT_FIRST_USER_FLAG +#define TT_NEED_BASE (TT_FIRST_USER_FLAG<<1) +#define TT_NEED_DNS (TT_FIRST_USER_FLAG<<2) +#define TT_LEGACY (TT_FIRST_USER_FLAG<<3) +#define TT_NEED_THREADS (TT_FIRST_USER_FLAG<<4) +#define TT_NO_LOGS (TT_FIRST_USER_FLAG<<5) +#define TT_ENABLE_IOCP_FLAG (TT_FIRST_USER_FLAG<<6) +#define TT_ENABLE_IOCP (TT_ENABLE_IOCP_FLAG|TT_NEED_THREADS) + +/* All the flags that a legacy test needs. */ +#define TT_ISOLATED TT_FORK|TT_NEED_SOCKETPAIR|TT_NEED_BASE + + +#define BASIC(name,flags) \ + { #name, test_## name, flags, &basic_setup, NULL } + +#define LEGACY(name,flags) \ + { #name, run_legacy_test_fn, flags|TT_LEGACY, &legacy_setup, \ + test_## name } + +struct evutil_addrinfo; +struct evutil_addrinfo *ai_find_by_family(struct evutil_addrinfo *ai, int f); +struct evutil_addrinfo *ai_find_by_protocol(struct evutil_addrinfo *ai, int p); +int test_ai_eq_(const struct evutil_addrinfo *ai, const char *sockaddr_port, + int socktype, int protocol, int line); + +#define test_ai_eq(ai, str, s, p) do { \ + if (test_ai_eq_((ai), (str), (s), (p), __LINE__)<0) \ + goto end; \ + } while (0) + +#define test_timeval_diff_leq(tv1, tv2, diff, tolerance) \ + tt_int_op(labs(timeval_msec_diff((tv1), (tv2)) - diff), <=, tolerance) + +#define test_timeval_diff_eq(tv1, tv2, diff) \ + test_timeval_diff_leq((tv1), (tv2), (diff), 50) + +long timeval_msec_diff(const struct timeval *start, const struct timeval *end); + +#ifndef _WIN32 +pid_t regress_fork(void); +#endif + +#ifdef __cplusplus +} +#endif + +#endif /* REGRESS_H_INCLUDED_ */ diff --git a/contrib/ntp/sntp/libevent/test/regress.rpc b/contrib/ntp/sntp/libevent/test/regress.rpc new file mode 100644 index 000000000..0ee904e91 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress.rpc @@ -0,0 +1,25 @@ +/* tests data packing and unpacking */ + +struct msg { + string /* sender */ from_name = 1; /* be verbose */ + string to_name = 2; + optional struct[kill] attack = 3; + array struct[run] run = 4; +} + +struct kill { + string weapon = 0x10121; + string action = 2; + array int how_often = 3; +} + +struct run { + string how = 1; + optional bytes some_bytes = 2; + + bytes fixed_bytes[24] = 3; + array string notes = 4; + + optional int64 large_number = 5; + array int other_numbers = 6; +} diff --git a/contrib/ntp/sntp/libevent/test/regress_buffer.c b/contrib/ntp/sntp/libevent/test/regress_buffer.c new file mode 100644 index 000000000..4d6a5de20 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress_buffer.c @@ -0,0 +1,2281 @@ +/* + * Copyright (c) 2003-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "util-internal.h" + +#ifdef _WIN32 +#include +#include +#endif + +#include "event2/event-config.h" + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#ifndef _WIN32 +#include +#include +#include +#include +#include +#endif +#include +#include +#include +#include +#include + +#include "event2/event.h" +#include "event2/buffer.h" +#include "event2/buffer_compat.h" +#include "event2/util.h" + +#include "defer-internal.h" +#include "evbuffer-internal.h" +#include "log-internal.h" + +#include "regress.h" + +/* Validates that an evbuffer is good. Returns false if it isn't, true if it + * is*/ +static int +evbuffer_validate_(struct evbuffer *buf) +{ + struct evbuffer_chain *chain; + size_t sum = 0; + int found_last_with_datap = 0; + + if (buf->first == NULL) { + tt_assert(buf->last == NULL); + tt_assert(buf->total_len == 0); + } + + chain = buf->first; + + tt_assert(buf->last_with_datap); + if (buf->last_with_datap == &buf->first) + found_last_with_datap = 1; + + while (chain != NULL) { + if (&chain->next == buf->last_with_datap) + found_last_with_datap = 1; + sum += chain->off; + if (chain->next == NULL) { + tt_assert(buf->last == chain); + } + tt_assert(chain->buffer_len >= chain->misalign + chain->off); + chain = chain->next; + } + + if (buf->first) + tt_assert(*buf->last_with_datap); + + if (*buf->last_with_datap) { + chain = *buf->last_with_datap; + if (chain->off == 0 || buf->total_len == 0) { + tt_assert(chain->off == 0) + tt_assert(chain == buf->first); + tt_assert(buf->total_len == 0); + } + chain = chain->next; + while (chain != NULL) { + tt_assert(chain->off == 0); + chain = chain->next; + } + } else { + tt_assert(buf->last_with_datap == &buf->first); + } + tt_assert(found_last_with_datap); + + tt_assert(sum == buf->total_len); + return 1; + end: + return 0; +} + +static void +evbuffer_get_waste(struct evbuffer *buf, size_t *allocatedp, size_t *wastedp, size_t *usedp) +{ + struct evbuffer_chain *chain; + size_t a, w, u; + int n = 0; + u = a = w = 0; + + chain = buf->first; + /* skip empty at start */ + while (chain && chain->off==0) { + ++n; + a += chain->buffer_len; + chain = chain->next; + } + /* first nonempty chain: stuff at the end only is wasted. */ + if (chain) { + ++n; + a += chain->buffer_len; + u += chain->off; + if (chain->next && chain->next->off) + w += (size_t)(chain->buffer_len - (chain->misalign + chain->off)); + chain = chain->next; + } + /* subsequent nonempty chains */ + while (chain && chain->off) { + ++n; + a += chain->buffer_len; + w += (size_t)chain->misalign; + u += chain->off; + if (chain->next && chain->next->off) + w += (size_t) (chain->buffer_len - (chain->misalign + chain->off)); + chain = chain->next; + } + /* subsequent empty chains */ + while (chain) { + ++n; + a += chain->buffer_len; + } + *allocatedp = a; + *wastedp = w; + *usedp = u; +} + +#define evbuffer_validate(buf) \ + TT_STMT_BEGIN if (!evbuffer_validate_(buf)) TT_DIE(("Buffer format invalid")); TT_STMT_END + +static void +test_evbuffer(void *ptr) +{ + static char buffer[512], *tmp; + struct evbuffer *evb = evbuffer_new(); + struct evbuffer *evb_two = evbuffer_new(); + size_t sz_tmp; + int i; + + evbuffer_validate(evb); + evbuffer_add_printf(evb, "%s/%d", "hello", 1); + evbuffer_validate(evb); + + tt_assert(evbuffer_get_length(evb) == 7); + tt_assert(!memcmp((char*)EVBUFFER_DATA(evb), "hello/1", 1)); + + evbuffer_add_buffer(evb, evb_two); + evbuffer_validate(evb); + + evbuffer_drain(evb, strlen("hello/")); + evbuffer_validate(evb); + tt_assert(evbuffer_get_length(evb) == 1); + tt_assert(!memcmp((char*)EVBUFFER_DATA(evb), "1", 1)); + + evbuffer_add_printf(evb_two, "%s", "/hello"); + evbuffer_validate(evb); + evbuffer_add_buffer(evb, evb_two); + evbuffer_validate(evb); + + tt_assert(evbuffer_get_length(evb_two) == 0); + tt_assert(evbuffer_get_length(evb) == 7); + tt_assert(!memcmp((char*)EVBUFFER_DATA(evb), "1/hello", 7) != 0); + + memset(buffer, 0, sizeof(buffer)); + evbuffer_add(evb, buffer, sizeof(buffer)); + evbuffer_validate(evb); + tt_assert(evbuffer_get_length(evb) == 7 + 512); + + tmp = (char *)evbuffer_pullup(evb, 7 + 512); + tt_assert(tmp); + tt_assert(!strncmp(tmp, "1/hello", 7)); + tt_assert(!memcmp(tmp + 7, buffer, sizeof(buffer))); + evbuffer_validate(evb); + + evbuffer_prepend(evb, "something", 9); + evbuffer_validate(evb); + evbuffer_prepend(evb, "else", 4); + evbuffer_validate(evb); + + tmp = (char *)evbuffer_pullup(evb, 4 + 9 + 7); + tt_assert(!strncmp(tmp, "elsesomething1/hello", 4 + 9 + 7)); + evbuffer_validate(evb); + + evbuffer_drain(evb, -1); + evbuffer_validate(evb); + evbuffer_drain(evb_two, -1); + evbuffer_validate(evb); + + for (i = 0; i < 3; ++i) { + evbuffer_add(evb_two, buffer, sizeof(buffer)); + evbuffer_validate(evb_two); + evbuffer_add_buffer(evb, evb_two); + evbuffer_validate(evb); + evbuffer_validate(evb_two); + } + + tt_assert(evbuffer_get_length(evb_two) == 0); + tt_assert(evbuffer_get_length(evb) == i * sizeof(buffer)); + + /* test remove buffer */ + sz_tmp = (size_t)(sizeof(buffer)*2.5); + evbuffer_remove_buffer(evb, evb_two, sz_tmp); + tt_assert(evbuffer_get_length(evb_two) == sz_tmp); + tt_assert(evbuffer_get_length(evb) == sizeof(buffer) / 2); + evbuffer_validate(evb); + + if (memcmp(evbuffer_pullup( + evb, -1), buffer, sizeof(buffer) / 2) != 0 || + memcmp(evbuffer_pullup( + evb_two, -1), buffer, sizeof(buffer)) != 0) + tt_abort_msg("Pullup did not preserve content"); + + evbuffer_validate(evb); + + + /* testing one-vector reserve and commit */ + { + struct evbuffer_iovec v[1]; + char *buf; + int i, j, r; + + for (i = 0; i < 3; ++i) { + r = evbuffer_reserve_space(evb, 10000, v, 1); + tt_int_op(r, ==, 1); + tt_assert(v[0].iov_len >= 10000); + tt_assert(v[0].iov_base != NULL); + + evbuffer_validate(evb); + buf = v[0].iov_base; + for (j = 0; j < 10000; ++j) { + buf[j] = j; + } + evbuffer_validate(evb); + + tt_int_op(evbuffer_commit_space(evb, v, 1), ==, 0); + evbuffer_validate(evb); + + tt_assert(evbuffer_get_length(evb) >= 10000); + + evbuffer_drain(evb, j * 5000); + evbuffer_validate(evb); + } + } + + end: + evbuffer_free(evb); + evbuffer_free(evb_two); +} + +static void +no_cleanup(const void *data, size_t datalen, void *extra) +{ +} + +static void +test_evbuffer_remove_buffer_with_empty(void *ptr) +{ + struct evbuffer *src = evbuffer_new(); + struct evbuffer *dst = evbuffer_new(); + char buf[2]; + + evbuffer_validate(src); + evbuffer_validate(dst); + + /* setup the buffers */ + /* we need more data in src than we will move later */ + evbuffer_add_reference(src, buf, sizeof(buf), no_cleanup, NULL); + evbuffer_add_reference(src, buf, sizeof(buf), no_cleanup, NULL); + /* we need one buffer in dst and one empty buffer at the end */ + evbuffer_add(dst, buf, sizeof(buf)); + evbuffer_add_reference(dst, buf, 0, no_cleanup, NULL); + + evbuffer_validate(src); + evbuffer_validate(dst); + + /* move three bytes over */ + evbuffer_remove_buffer(src, dst, 3); + + evbuffer_validate(src); + evbuffer_validate(dst); + +end: + evbuffer_free(src); + evbuffer_free(dst); +} + +static void +test_evbuffer_reserve2(void *ptr) +{ + /* Test the two-vector cases of reserve/commit. */ + struct evbuffer *buf = evbuffer_new(); + int n, i; + struct evbuffer_iovec v[2]; + size_t remaining; + char *cp, *cp2; + + /* First chunk will necessarily be one chunk. Use 512 bytes of it.*/ + n = evbuffer_reserve_space(buf, 1024, v, 2); + tt_int_op(n, ==, 1); + tt_int_op(evbuffer_get_length(buf), ==, 0); + tt_assert(v[0].iov_base != NULL); + tt_int_op(v[0].iov_len, >=, 1024); + memset(v[0].iov_base, 'X', 512); + cp = v[0].iov_base; + remaining = v[0].iov_len - 512; + v[0].iov_len = 512; + evbuffer_validate(buf); + tt_int_op(0, ==, evbuffer_commit_space(buf, v, 1)); + tt_int_op(evbuffer_get_length(buf), ==, 512); + evbuffer_validate(buf); + + /* Ask for another same-chunk request, in an existing chunk. Use 8 + * bytes of it. */ + n = evbuffer_reserve_space(buf, 32, v, 2); + tt_int_op(n, ==, 1); + tt_assert(cp + 512 == v[0].iov_base); + tt_int_op(remaining, ==, v[0].iov_len); + memset(v[0].iov_base, 'Y', 8); + v[0].iov_len = 8; + tt_int_op(0, ==, evbuffer_commit_space(buf, v, 1)); + tt_int_op(evbuffer_get_length(buf), ==, 520); + remaining -= 8; + evbuffer_validate(buf); + + /* Now ask for a request that will be split. Use only one byte of it, + though. */ + n = evbuffer_reserve_space(buf, remaining+64, v, 2); + tt_int_op(n, ==, 2); + tt_assert(cp + 520 == v[0].iov_base); + tt_int_op(remaining, ==, v[0].iov_len); + tt_assert(v[1].iov_base); + tt_assert(v[1].iov_len >= 64); + cp2 = v[1].iov_base; + memset(v[0].iov_base, 'Z', 1); + v[0].iov_len = 1; + tt_int_op(0, ==, evbuffer_commit_space(buf, v, 1)); + tt_int_op(evbuffer_get_length(buf), ==, 521); + remaining -= 1; + evbuffer_validate(buf); + + /* Now ask for a request that will be split. Use some of the first + * part and some of the second. */ + n = evbuffer_reserve_space(buf, remaining+64, v, 2); + evbuffer_validate(buf); + tt_int_op(n, ==, 2); + tt_assert(cp + 521 == v[0].iov_base); + tt_int_op(remaining, ==, v[0].iov_len); + tt_assert(v[1].iov_base == cp2); + tt_assert(v[1].iov_len >= 64); + memset(v[0].iov_base, 'W', 400); + v[0].iov_len = 400; + memset(v[1].iov_base, 'x', 60); + v[1].iov_len = 60; + tt_int_op(0, ==, evbuffer_commit_space(buf, v, 2)); + tt_int_op(evbuffer_get_length(buf), ==, 981); + evbuffer_validate(buf); + + /* Now peek to make sure stuff got made how we like. */ + memset(v,0,sizeof(v)); + n = evbuffer_peek(buf, -1, NULL, v, 2); + tt_int_op(n, ==, 2); + tt_int_op(v[0].iov_len, ==, 921); + tt_int_op(v[1].iov_len, ==, 60); + + cp = v[0].iov_base; + for (i=0; i<512; ++i) + tt_int_op(cp[i], ==, 'X'); + for (i=512; i<520; ++i) + tt_int_op(cp[i], ==, 'Y'); + for (i=520; i<521; ++i) + tt_int_op(cp[i], ==, 'Z'); + for (i=521; i<921; ++i) + tt_int_op(cp[i], ==, 'W'); + + cp = v[1].iov_base; + for (i=0; i<60; ++i) + tt_int_op(cp[i], ==, 'x'); + +end: + evbuffer_free(buf); +} + +static void +test_evbuffer_reserve_many(void *ptr) +{ + /* This is a glass-box test to handle expanding a buffer with more + * chunks and reallocating chunks as needed */ + struct evbuffer *buf = evbuffer_new(); + struct evbuffer_iovec v[8]; + int n; + size_t sz; + int add_data = ptr && !strcmp(ptr, "add"); + int fill_first = ptr && !strcmp(ptr, "fill"); + char *cp1, *cp2; + + /* When reserving the the first chunk, we just allocate it */ + n = evbuffer_reserve_space(buf, 128, v, 2); + evbuffer_validate(buf); + tt_int_op(n, ==, 1); + tt_assert(v[0].iov_len >= 128); + sz = v[0].iov_len; + cp1 = v[0].iov_base; + if (add_data) { + *(char*)v[0].iov_base = 'X'; + v[0].iov_len = 1; + n = evbuffer_commit_space(buf, v, 1); + tt_int_op(n, ==, 0); + } else if (fill_first) { + memset(v[0].iov_base, 'X', v[0].iov_len); + n = evbuffer_commit_space(buf, v, 1); + tt_int_op(n, ==, 0); + n = evbuffer_reserve_space(buf, 128, v, 2); + tt_int_op(n, ==, 1); + sz = v[0].iov_len; + tt_assert(v[0].iov_base != cp1); + cp1 = v[0].iov_base; + } + + /* Make another chunk get added. */ + n = evbuffer_reserve_space(buf, sz+128, v, 2); + evbuffer_validate(buf); + tt_int_op(n, ==, 2); + sz = v[0].iov_len + v[1].iov_len; + tt_int_op(sz, >=, v[0].iov_len+128); + if (add_data) { + tt_assert(v[0].iov_base == cp1 + 1); + } else { + tt_assert(v[0].iov_base == cp1); + } + cp1 = v[0].iov_base; + cp2 = v[1].iov_base; + + /* And a third chunk. */ + n = evbuffer_reserve_space(buf, sz+128, v, 3); + evbuffer_validate(buf); + tt_int_op(n, ==, 3); + tt_assert(cp1 == v[0].iov_base); + tt_assert(cp2 == v[1].iov_base); + sz = v[0].iov_len + v[1].iov_len + v[2].iov_len; + + /* Now force a reallocation by asking for more space in only 2 + * buffers. */ + n = evbuffer_reserve_space(buf, sz+128, v, 2); + evbuffer_validate(buf); + if (add_data) { + tt_int_op(n, ==, 2); + tt_assert(cp1 == v[0].iov_base); + } else { + tt_int_op(n, ==, 1); + } + +end: + evbuffer_free(buf); +} + +static void +test_evbuffer_expand(void *ptr) +{ + char data[4096]; + struct evbuffer *buf; + size_t a,w,u; + void *buffer; + + memset(data, 'X', sizeof(data)); + + /* Make sure that expand() works on an empty buffer */ + buf = evbuffer_new(); + tt_int_op(evbuffer_expand(buf, 20000), ==, 0); + evbuffer_validate(buf); + a=w=u=0; + evbuffer_get_waste(buf, &a,&w,&u); + tt_assert(w == 0); + tt_assert(u == 0); + tt_assert(a >= 20000); + tt_assert(buf->first); + tt_assert(buf->first == buf->last); + tt_assert(buf->first->off == 0); + tt_assert(buf->first->buffer_len >= 20000); + + /* Make sure that expand() works as a no-op when there's enough + * contiguous space already. */ + buffer = buf->first->buffer; + evbuffer_add(buf, data, 1024); + tt_int_op(evbuffer_expand(buf, 1024), ==, 0); + tt_assert(buf->first->buffer == buffer); + evbuffer_validate(buf); + evbuffer_free(buf); + + /* Make sure that expand() can work by moving misaligned data + * when it makes sense to do so. */ + buf = evbuffer_new(); + evbuffer_add(buf, data, 400); + { + int n = (int)(buf->first->buffer_len - buf->first->off - 1); + tt_assert(n < (int)sizeof(data)); + evbuffer_add(buf, data, n); + } + tt_assert(buf->first == buf->last); + tt_assert(buf->first->off == buf->first->buffer_len - 1); + evbuffer_drain(buf, buf->first->off - 1); + tt_assert(1 == evbuffer_get_length(buf)); + tt_assert(buf->first->misalign > 0); + tt_assert(buf->first->off == 1); + buffer = buf->first->buffer; + tt_assert(evbuffer_expand(buf, 40) == 0); + tt_assert(buf->first == buf->last); + tt_assert(buf->first->off == 1); + tt_assert(buf->first->buffer == buffer); + tt_assert(buf->first->misalign == 0); + evbuffer_validate(buf); + evbuffer_free(buf); + + /* add, expand, pull-up: This used to crash libevent. */ + buf = evbuffer_new(); + + evbuffer_add(buf, data, sizeof(data)); + evbuffer_add(buf, data, sizeof(data)); + evbuffer_add(buf, data, sizeof(data)); + + evbuffer_validate(buf); + evbuffer_expand(buf, 1024); + evbuffer_validate(buf); + evbuffer_pullup(buf, -1); + evbuffer_validate(buf); + +end: + evbuffer_free(buf); +} + + +static int reference_cb_called; +static void +reference_cb(const void *data, size_t len, void *extra) +{ + tt_str_op(data, ==, "this is what we add as read-only memory."); + tt_int_op(len, ==, strlen(data)); + tt_want(extra == (void *)0xdeadaffe); + ++reference_cb_called; +end: + ; +} + +static void +test_evbuffer_reference(void *ptr) +{ + struct evbuffer *src = evbuffer_new(); + struct evbuffer *dst = evbuffer_new(); + struct evbuffer_iovec v[1]; + const char *data = "this is what we add as read-only memory."; + reference_cb_called = 0; + + tt_assert(evbuffer_add_reference(src, data, strlen(data), + reference_cb, (void *)0xdeadaffe) != -1); + + evbuffer_reserve_space(dst, strlen(data), v, 1); + tt_assert(evbuffer_remove(src, v[0].iov_base, 10) != -1); + + evbuffer_validate(src); + evbuffer_validate(dst); + + /* make sure that we don't write data at the beginning */ + evbuffer_prepend(src, "aaaaa", 5); + evbuffer_validate(src); + evbuffer_drain(src, 5); + + tt_assert(evbuffer_remove(src, ((char*)(v[0].iov_base)) + 10, + strlen(data) - 10) != -1); + + v[0].iov_len = strlen(data); + + evbuffer_commit_space(dst, v, 1); + evbuffer_validate(src); + evbuffer_validate(dst); + + tt_int_op(reference_cb_called, ==, 1); + + tt_assert(!memcmp(evbuffer_pullup(dst, strlen(data)), + data, strlen(data))); + evbuffer_validate(dst); + + end: + evbuffer_free(dst); + evbuffer_free(src); +} + +static struct event_base *addfile_test_event_base = NULL; +static int addfile_test_done_writing = 0; +static int addfile_test_total_written = 0; +static int addfile_test_total_read = 0; + +static void +addfile_test_writecb(evutil_socket_t fd, short what, void *arg) +{ + struct evbuffer *b = arg; + int r; + evbuffer_validate(b); + while (evbuffer_get_length(b)) { + r = evbuffer_write(b, fd); + if (r > 0) { + addfile_test_total_written += r; + TT_BLATHER(("Wrote %d/%d bytes", r, addfile_test_total_written)); + } else { + int e = evutil_socket_geterror(fd); + if (EVUTIL_ERR_RW_RETRIABLE(e)) + return; + tt_fail_perror("write"); + event_base_loopexit(addfile_test_event_base,NULL); + } + evbuffer_validate(b); + } + addfile_test_done_writing = 1; + return; +end: + event_base_loopexit(addfile_test_event_base,NULL); +} + +static void +addfile_test_readcb(evutil_socket_t fd, short what, void *arg) +{ + struct evbuffer *b = arg; + int e, r = 0; + do { + r = evbuffer_read(b, fd, 1024); + if (r > 0) { + addfile_test_total_read += r; + TT_BLATHER(("Read %d/%d bytes", r, addfile_test_total_read)); + } + } while (r > 0); + if (r < 0) { + e = evutil_socket_geterror(fd); + if (! EVUTIL_ERR_RW_RETRIABLE(e)) { + tt_fail_perror("read"); + event_base_loopexit(addfile_test_event_base,NULL); + } + } + if (addfile_test_done_writing && + addfile_test_total_read >= addfile_test_total_written) { + event_base_loopexit(addfile_test_event_base,NULL); + } +} + +static void +test_evbuffer_add_file(void *ptr) +{ + struct basic_test_data *testdata = ptr; + const char *impl = testdata->setup_data; + struct evbuffer *src = evbuffer_new(), *dest = evbuffer_new(); + char *tmpfilename = NULL; + char *data = NULL; + const char *expect_data; + size_t datalen, expect_len; + const char *compare; + int fd = -1; + int want_ismapping = -1, want_cansendfile = -1; + unsigned flags = 0; + int use_segment = 1, use_bigfile = 0, map_from_offset = 0, + view_from_offset = 0; + struct evbuffer_file_segment *seg = NULL; + ev_off_t starting_offset = 0, mapping_len = -1; + ev_off_t segment_offset = 0, segment_len = -1; + struct event *rev=NULL, *wev=NULL; + struct event_base *base = testdata->base; + evutil_socket_t pair[2] = {-1, -1}; + struct evutil_weakrand_state seed = { 123456789U }; + + /* This test is highly parameterized based on substrings of its + * argument. The strings are: */ + tt_assert(impl); + if (strstr(impl, "nosegment")) { + /* If nosegment is set, use the older evbuffer_add_file + * interface */ + use_segment = 0; + } + if (strstr(impl, "bigfile")) { + /* If bigfile is set, use a 512K file. Else use a smaller + * one. */ + use_bigfile = 1; + } + if (strstr(impl, "map_offset")) { + /* If map_offset is set, we build the file segment starting + * from a point other than byte 0 and ending somewhere other + * than the last byte. Otherwise we map the whole thing */ + map_from_offset = 1; + } + if (strstr(impl, "offset_in_segment")) { + /* If offset_in_segment is set, we add a subsection of the + * file semgment starting from a point other than byte 0 of + * the segment. */ + view_from_offset = 1; + } + if (strstr(impl, "sendfile")) { + /* If sendfile is set, we try to use a sendfile/splice style + * backend. */ + flags = EVBUF_FS_DISABLE_MMAP; + want_cansendfile = 1; + want_ismapping = 0; + } else if (strstr(impl, "mmap")) { + /* If sendfile is set, we try to use a mmap/CreateFileMapping + * style backend. */ + flags = EVBUF_FS_DISABLE_SENDFILE; + want_ismapping = 1; + want_cansendfile = 0; + } else if (strstr(impl, "linear")) { + /* If linear is set, we try to use a read-the-whole-thing + * backend. */ + flags = EVBUF_FS_DISABLE_SENDFILE|EVBUF_FS_DISABLE_MMAP; + want_ismapping = 0; + want_cansendfile = 0; + } else if (strstr(impl, "default")) { + /* The caller doesn't care which backend we use. */ + ; + } else { + /* The caller must choose a backend. */ + TT_DIE(("Didn't recognize the implementation")); + } + + if (use_bigfile) { + unsigned int i; + datalen = 1024*512; + data = malloc(1024*512); + tt_assert(data); + for (i = 0; i < datalen; ++i) + data[i] = (char)evutil_weakrand_(&seed); + } else { + data = strdup("here is a relatively small string."); + tt_assert(data); + datalen = strlen(data); + } + + fd = regress_make_tmpfile(data, datalen, &tmpfilename); + + if (map_from_offset) { + starting_offset = datalen/4 + 1; + mapping_len = datalen / 2 - 1; + expect_data = data + starting_offset; + expect_len = mapping_len; + } else { + expect_data = data; + expect_len = datalen; + } + if (view_from_offset) { + tt_assert(use_segment); /* Can't do this with add_file*/ + segment_offset = expect_len / 3; + segment_len = expect_len / 2; + expect_data = expect_data + segment_offset; + expect_len = segment_len; + } + + if (use_segment) { + seg = evbuffer_file_segment_new(fd, starting_offset, + mapping_len, flags); + tt_assert(seg); + if (want_ismapping >= 0) { + if (seg->is_mapping != (unsigned)want_ismapping) + tt_skip(); + } + if (want_cansendfile >= 0) { + if (seg->can_sendfile != (unsigned)want_cansendfile) + tt_skip(); + } + } + + /* Say that it drains to a fd so that we can use sendfile. */ + evbuffer_set_flags(src, EVBUFFER_FLAG_DRAINS_TO_FD); + +#if defined(EVENT__HAVE_SENDFILE) && defined(__sun__) && defined(__svr4__) + /* We need to use a pair of AF_INET sockets, since Solaris + doesn't support sendfile() over AF_UNIX. */ + if (evutil_ersatz_socketpair_(AF_INET, SOCK_STREAM, 0, pair) == -1) + tt_abort_msg("ersatz_socketpair failed"); +#else + if (evutil_socketpair(AF_UNIX, SOCK_STREAM, 0, pair) == -1) + tt_abort_msg("socketpair failed"); +#endif + evutil_make_socket_nonblocking(pair[0]); + evutil_make_socket_nonblocking(pair[1]); + + tt_assert(fd != -1); + + if (use_segment) { + tt_assert(evbuffer_add_file_segment(src, seg, + segment_offset, segment_len)!=-1); + } else { + tt_assert(evbuffer_add_file(src, fd, starting_offset, + mapping_len) != -1); + } + + evbuffer_validate(src); + + addfile_test_event_base = base; + wev = event_new(base, pair[0], EV_WRITE|EV_PERSIST, + addfile_test_writecb, src); + rev = event_new(base, pair[1], EV_READ|EV_PERSIST, + addfile_test_readcb, dest); + + event_add(wev, NULL); + event_add(rev, NULL); + event_base_dispatch(base); + + evbuffer_validate(src); + evbuffer_validate(dest); + + tt_assert(addfile_test_done_writing); + tt_int_op(addfile_test_total_written, ==, expect_len); + tt_int_op(addfile_test_total_read, ==, expect_len); + + compare = (char *)evbuffer_pullup(dest, expect_len); + tt_assert(compare != NULL); + if (memcmp(compare, expect_data, expect_len)) { + tt_abort_msg("Data from add_file differs."); + } + + evbuffer_validate(dest); + end: + if (data) + free(data); + if (seg) + evbuffer_file_segment_free(seg); + if (src) + evbuffer_free(src); + if (dest) + evbuffer_free(dest); + if (pair[0] >= 0) + evutil_closesocket(pair[0]); + if (pair[1] >= 0) + evutil_closesocket(pair[1]); + if (wev) + event_free(wev); + if (rev) + event_free(rev); + if (tmpfilename) { + unlink(tmpfilename); + free(tmpfilename); + } +} + +static int file_segment_cleanup_cb_called_count = 0; +static struct evbuffer_file_segment const* file_segment_cleanup_cb_called_with = NULL; +static int file_segment_cleanup_cb_called_with_flags = 0; +static void* file_segment_cleanup_cb_called_with_arg = NULL; +static void +file_segment_cleanup_cp(struct evbuffer_file_segment const* seg, int flags, void* arg) +{ + ++file_segment_cleanup_cb_called_count; + file_segment_cleanup_cb_called_with = seg; + file_segment_cleanup_cb_called_with_flags = flags; + file_segment_cleanup_cb_called_with_arg = arg; +} + +static void +test_evbuffer_file_segment_add_cleanup_cb(void* ptr) +{ + char *tmpfilename = NULL; + int fd = -1; + struct evbuffer *evb = NULL; + struct evbuffer_file_segment *seg = NULL, *segptr; + char const* arg = "token"; + + fd = regress_make_tmpfile("file_segment_test_file", 22, &tmpfilename); + tt_int_op(fd, >=, 0); + + evb = evbuffer_new(); + tt_assert(evb); + + segptr = seg = evbuffer_file_segment_new(fd, 0, -1, 0); + tt_assert(seg); + + evbuffer_file_segment_add_cleanup_cb( + seg, &file_segment_cleanup_cp, (void*)arg); + + tt_assert(fd != -1); + + tt_assert(evbuffer_add_file_segment(evb, seg, 0, -1)!=-1); + + evbuffer_validate(evb); + + tt_int_op(file_segment_cleanup_cb_called_count, ==, 0); + evbuffer_file_segment_free(seg); + seg = NULL; /* Prevent double-free. */ + + tt_int_op(file_segment_cleanup_cb_called_count, ==, 0); + evbuffer_free(evb); + evb = NULL; /* pevent double-free */ + + tt_int_op(file_segment_cleanup_cb_called_count, ==, 1); + tt_assert(file_segment_cleanup_cb_called_with == segptr); + tt_assert(file_segment_cleanup_cb_called_with_flags == 0); + tt_assert(file_segment_cleanup_cb_called_with_arg == (void*)arg); + +end: + if (evb) + evbuffer_free(evb); + if (seg) + evbuffer_file_segment_free(seg); + if (tmpfilename) { + unlink(tmpfilename); + free(tmpfilename); + } +} + +#ifndef EVENT__DISABLE_MM_REPLACEMENT +static void * +failing_malloc(size_t how_much) +{ + errno = ENOMEM; + return NULL; +} +#endif + +static void +test_evbuffer_readln(void *ptr) +{ + struct evbuffer *evb = evbuffer_new(); + struct evbuffer *evb_tmp = evbuffer_new(); + const char *s; + char *cp = NULL; + size_t sz; + +#define tt_line_eq(content) \ + TT_STMT_BEGIN \ + if (!cp || sz != strlen(content) || strcmp(cp, content)) { \ + TT_DIE(("Wanted %s; got %s [%d]", content, cp, (int)sz)); \ + } \ + TT_STMT_END + + /* Test EOL_ANY. */ + s = "complex silly newline\r\n\n\r\n\n\rmore\0\n"; + evbuffer_add(evb, s, strlen(s)+2); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_ANY); + tt_line_eq("complex silly newline"); + free(cp); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_ANY); + if (!cp || sz != 5 || memcmp(cp, "more\0\0", 6)) + tt_abort_msg("Not as expected"); + tt_uint_op(evbuffer_get_length(evb), ==, 0); + evbuffer_validate(evb); + s = "\nno newline"; + evbuffer_add(evb, s, strlen(s)); + free(cp); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_ANY); + tt_line_eq(""); + free(cp); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_ANY); + tt_assert(!cp); + evbuffer_validate(evb); + evbuffer_drain(evb, evbuffer_get_length(evb)); + tt_assert(evbuffer_get_length(evb) == 0); + evbuffer_validate(evb); + + /* Test EOL_CRLF */ + s = "Line with\rin the middle\nLine with good crlf\r\n\nfinal\n"; + evbuffer_add(evb, s, strlen(s)); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF); + tt_line_eq("Line with\rin the middle"); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF); + tt_line_eq("Line with good crlf"); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF); + tt_line_eq(""); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF); + tt_line_eq("final"); + s = "x"; + evbuffer_validate(evb); + evbuffer_add(evb, s, 1); + evbuffer_validate(evb); + free(cp); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF); + tt_assert(!cp); + evbuffer_validate(evb); + + /* Test CRLF_STRICT */ + s = " and a bad crlf\nand a good one\r\n\r\nMore\r"; + evbuffer_add(evb, s, strlen(s)); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq("x and a bad crlf\nand a good one"); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq(""); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_assert(!cp); + evbuffer_validate(evb); + evbuffer_add(evb, "\n", 1); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq("More"); + free(cp); + tt_assert(evbuffer_get_length(evb) == 0); + evbuffer_validate(evb); + + s = "An internal CR\r is not an eol\r\nNor is a lack of one"; + evbuffer_add(evb, s, strlen(s)); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq("An internal CR\r is not an eol"); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_assert(!cp); + evbuffer_validate(evb); + + evbuffer_add(evb, "\r\n", 2); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq("Nor is a lack of one"); + free(cp); + tt_assert(evbuffer_get_length(evb) == 0); + evbuffer_validate(evb); + + /* Test LF */ + s = "An\rand a nl\n\nText"; + evbuffer_add(evb, s, strlen(s)); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_LF); + tt_line_eq("An\rand a nl"); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_LF); + tt_line_eq(""); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_LF); + tt_assert(!cp); + free(cp); + evbuffer_add(evb, "\n", 1); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_LF); + tt_line_eq("Text"); + free(cp); + evbuffer_validate(evb); + + /* Test NUL */ + tt_int_op(evbuffer_get_length(evb), ==, 0); + { + char x[] = + "NUL\n\0\0" + "The all-zeros character which may serve\0" + "to accomplish time fill\0and media fill"; + /* Add all but the final NUL of x. */ + evbuffer_add(evb, x, sizeof(x)-1); + } + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_NUL); + tt_line_eq("NUL\n"); + free(cp); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_NUL); + tt_line_eq(""); + free(cp); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_NUL); + tt_line_eq("The all-zeros character which may serve"); + free(cp); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_NUL); + tt_line_eq("to accomplish time fill"); + free(cp); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_NUL); + tt_ptr_op(cp, ==, NULL); + evbuffer_drain(evb, -1); + + /* Test CRLF_STRICT - across boundaries*/ + s = " and a bad crlf\nand a good one\r"; + evbuffer_add(evb_tmp, s, strlen(s)); + evbuffer_validate(evb); + evbuffer_add_buffer(evb, evb_tmp); + evbuffer_validate(evb); + s = "\n\r"; + evbuffer_add(evb_tmp, s, strlen(s)); + evbuffer_validate(evb); + evbuffer_add_buffer(evb, evb_tmp); + evbuffer_validate(evb); + s = "\nMore\r"; + evbuffer_add(evb_tmp, s, strlen(s)); + evbuffer_validate(evb); + evbuffer_add_buffer(evb, evb_tmp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq(" and a bad crlf\nand a good one"); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq(""); + free(cp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_assert(!cp); + free(cp); + evbuffer_validate(evb); + evbuffer_add(evb, "\n", 1); + evbuffer_validate(evb); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_CRLF_STRICT); + tt_line_eq("More"); + free(cp); cp = NULL; + evbuffer_validate(evb); + tt_assert(evbuffer_get_length(evb) == 0); + + /* Test memory problem*/ + s = "one line\ntwo line\nblue line"; + evbuffer_add(evb_tmp, s, strlen(s)); + evbuffer_validate(evb); + evbuffer_add_buffer(evb, evb_tmp); + evbuffer_validate(evb); + + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_LF); + tt_line_eq("one line"); + free(cp); cp = NULL; + evbuffer_validate(evb); + + /* the next call to readline should fail */ +#ifndef EVENT__DISABLE_MM_REPLACEMENT + event_set_mem_functions(failing_malloc, realloc, free); + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_LF); + tt_assert(cp == NULL); + evbuffer_validate(evb); + + /* now we should get the next line back */ + event_set_mem_functions(malloc, realloc, free); +#endif + cp = evbuffer_readln(evb, &sz, EVBUFFER_EOL_LF); + tt_line_eq("two line"); + free(cp); cp = NULL; + evbuffer_validate(evb); + + end: + evbuffer_free(evb); + evbuffer_free(evb_tmp); + if (cp) free(cp); +} + +static void +test_evbuffer_search_eol(void *ptr) +{ + struct evbuffer *buf = evbuffer_new(); + struct evbuffer_ptr ptr1, ptr2; + const char *s; + size_t eol_len; + + s = "string! \r\n\r\nx\n"; + evbuffer_add(buf, s, strlen(s)); + eol_len = -1; + ptr1 = evbuffer_search_eol(buf, NULL, &eol_len, EVBUFFER_EOL_CRLF); + tt_int_op(ptr1.pos, ==, 8); + tt_int_op(eol_len, ==, 2); + + eol_len = -1; + ptr2 = evbuffer_search_eol(buf, &ptr1, &eol_len, EVBUFFER_EOL_CRLF); + tt_int_op(ptr2.pos, ==, 8); + tt_int_op(eol_len, ==, 2); + + evbuffer_ptr_set(buf, &ptr1, 1, EVBUFFER_PTR_ADD); + eol_len = -1; + ptr2 = evbuffer_search_eol(buf, &ptr1, &eol_len, EVBUFFER_EOL_CRLF); + tt_int_op(ptr2.pos, ==, 9); + tt_int_op(eol_len, ==, 1); + + eol_len = -1; + ptr2 = evbuffer_search_eol(buf, &ptr1, &eol_len, EVBUFFER_EOL_CRLF_STRICT); + tt_int_op(ptr2.pos, ==, 10); + tt_int_op(eol_len, ==, 2); + + eol_len = -1; + ptr1 = evbuffer_search_eol(buf, NULL, &eol_len, EVBUFFER_EOL_LF); + tt_int_op(ptr1.pos, ==, 9); + tt_int_op(eol_len, ==, 1); + + eol_len = -1; + ptr2 = evbuffer_search_eol(buf, &ptr1, &eol_len, EVBUFFER_EOL_LF); + tt_int_op(ptr2.pos, ==, 9); + tt_int_op(eol_len, ==, 1); + + evbuffer_ptr_set(buf, &ptr1, 1, EVBUFFER_PTR_ADD); + eol_len = -1; + ptr2 = evbuffer_search_eol(buf, &ptr1, &eol_len, EVBUFFER_EOL_LF); + tt_int_op(ptr2.pos, ==, 11); + tt_int_op(eol_len, ==, 1); + + tt_assert(evbuffer_ptr_set(buf, &ptr1, evbuffer_get_length(buf), EVBUFFER_PTR_SET) == 0); + eol_len = -1; + ptr2 = evbuffer_search_eol(buf, &ptr1, &eol_len, EVBUFFER_EOL_LF); + tt_int_op(ptr2.pos, ==, -1); + tt_int_op(eol_len, ==, 0); + +end: + evbuffer_free(buf); +} + +static void +test_evbuffer_iterative(void *ptr) +{ + struct evbuffer *buf = evbuffer_new(); + const char *abc = "abcdefghijklmnopqrstvuwxyzabcdefghijklmnopqrstvuwxyzabcdefghijklmnopqrstvuwxyzabcdefghijklmnopqrstvuwxyz"; + unsigned i, j, sum, n; + + sum = 0; + n = 0; + for (i = 0; i < 1000; ++i) { + for (j = 1; j < strlen(abc); ++j) { + char format[32]; + evutil_snprintf(format, sizeof(format), "%%%u.%us", j, j); + evbuffer_add_printf(buf, format, abc); + + /* Only check for rep violations every so often. + Walking over the whole list of chains can get + pretty expensive as it gets long. + */ + if ((n % 337) == 0) + evbuffer_validate(buf); + + sum += j; + n++; + } + } + evbuffer_validate(buf); + + tt_uint_op(sum, ==, evbuffer_get_length(buf)); + + { + size_t a,w,u; + a=w=u=0; + evbuffer_get_waste(buf, &a, &w, &u); + if (0) + printf("Allocated: %u.\nWasted: %u.\nUsed: %u.", + (unsigned)a, (unsigned)w, (unsigned)u); + tt_assert( ((double)w)/a < .125); + } + end: + evbuffer_free(buf); + +} + +static void +test_evbuffer_find(void *ptr) +{ + u_char* p; + const char* test1 = "1234567890\r\n"; + const char* test2 = "1234567890\r"; +#define EVBUFFER_INITIAL_LENGTH 256 + char test3[EVBUFFER_INITIAL_LENGTH]; + unsigned int i; + struct evbuffer * buf = evbuffer_new(); + + tt_assert(buf); + + /* make sure evbuffer_find doesn't match past the end of the buffer */ + evbuffer_add(buf, (u_char*)test1, strlen(test1)); + evbuffer_validate(buf); + evbuffer_drain(buf, strlen(test1)); + evbuffer_validate(buf); + evbuffer_add(buf, (u_char*)test2, strlen(test2)); + evbuffer_validate(buf); + p = evbuffer_find(buf, (u_char*)"\r\n", 2); + tt_want(p == NULL); + + /* + * drain the buffer and do another find; in r309 this would + * read past the allocated buffer causing a valgrind error. + */ + evbuffer_drain(buf, strlen(test2)); + evbuffer_validate(buf); + for (i = 0; i < EVBUFFER_INITIAL_LENGTH; ++i) + test3[i] = 'a'; + test3[EVBUFFER_INITIAL_LENGTH - 1] = 'x'; + evbuffer_add(buf, (u_char *)test3, EVBUFFER_INITIAL_LENGTH); + evbuffer_validate(buf); + p = evbuffer_find(buf, (u_char *)"xy", 2); + tt_want(p == NULL); + + /* simple test for match at end of allocated buffer */ + p = evbuffer_find(buf, (u_char *)"ax", 2); + tt_assert(p != NULL); + tt_want(strncmp((char*)p, "ax", 2) == 0); + +end: + if (buf) + evbuffer_free(buf); +} + +static void +test_evbuffer_ptr_set(void *ptr) +{ + struct evbuffer *buf = evbuffer_new(); + struct evbuffer_ptr pos; + struct evbuffer_iovec v[1]; + + tt_assert(buf); + + tt_int_op(evbuffer_get_length(buf), ==, 0); + + tt_assert(evbuffer_ptr_set(buf, &pos, 0, EVBUFFER_PTR_SET) == 0); + tt_assert(pos.pos == 0); + tt_assert(evbuffer_ptr_set(buf, &pos, 1, EVBUFFER_PTR_ADD) == -1); + tt_assert(pos.pos == -1); + tt_assert(evbuffer_ptr_set(buf, &pos, 1, EVBUFFER_PTR_SET) == -1); + tt_assert(pos.pos == -1); + + /* create some chains */ + evbuffer_reserve_space(buf, 5000, v, 1); + v[0].iov_len = 5000; + memset(v[0].iov_base, 1, v[0].iov_len); + evbuffer_commit_space(buf, v, 1); + evbuffer_validate(buf); + + evbuffer_reserve_space(buf, 4000, v, 1); + v[0].iov_len = 4000; + memset(v[0].iov_base, 2, v[0].iov_len); + evbuffer_commit_space(buf, v, 1); + + evbuffer_reserve_space(buf, 3000, v, 1); + v[0].iov_len = 3000; + memset(v[0].iov_base, 3, v[0].iov_len); + evbuffer_commit_space(buf, v, 1); + evbuffer_validate(buf); + + tt_int_op(evbuffer_get_length(buf), ==, 12000); + + tt_assert(evbuffer_ptr_set(buf, &pos, 13000, EVBUFFER_PTR_SET) == -1); + tt_assert(pos.pos == -1); + tt_assert(evbuffer_ptr_set(buf, &pos, 0, EVBUFFER_PTR_SET) == 0); + tt_assert(pos.pos == 0); + tt_assert(evbuffer_ptr_set(buf, &pos, 13000, EVBUFFER_PTR_ADD) == -1); + + tt_assert(evbuffer_ptr_set(buf, &pos, 0, EVBUFFER_PTR_SET) == 0); + tt_assert(pos.pos == 0); + tt_assert(evbuffer_ptr_set(buf, &pos, 10000, EVBUFFER_PTR_ADD) == 0); + tt_assert(pos.pos == 10000); + tt_assert(evbuffer_ptr_set(buf, &pos, 1000, EVBUFFER_PTR_ADD) == 0); + tt_assert(pos.pos == 11000); + tt_assert(evbuffer_ptr_set(buf, &pos, 1000, EVBUFFER_PTR_ADD) == 0); + tt_assert(pos.pos == 12000); + tt_assert(evbuffer_ptr_set(buf, &pos, 1000, EVBUFFER_PTR_ADD) == -1); + tt_assert(pos.pos == -1); + +end: + if (buf) + evbuffer_free(buf); +} + +static void +test_evbuffer_search(void *ptr) +{ + struct evbuffer *buf = evbuffer_new(); + struct evbuffer *tmp = evbuffer_new(); + struct evbuffer_ptr pos, end; + + tt_assert(buf); + tt_assert(tmp); + + pos = evbuffer_search(buf, "x", 1, NULL); + tt_int_op(pos.pos, ==, -1); + tt_assert(evbuffer_ptr_set(buf, &pos, 0, EVBUFFER_PTR_SET) == 0); + pos = evbuffer_search(buf, "x", 1, &pos); + tt_int_op(pos.pos, ==, -1); + tt_assert(evbuffer_ptr_set(buf, &pos, 0, EVBUFFER_PTR_SET) == 0); + pos = evbuffer_search_range(buf, "x", 1, &pos, &pos); + tt_int_op(pos.pos, ==, -1); + tt_assert(evbuffer_ptr_set(buf, &pos, 0, EVBUFFER_PTR_SET) == 0); + pos = evbuffer_search_range(buf, "x", 1, &pos, NULL); + tt_int_op(pos.pos, ==, -1); + + /* set up our chains */ + evbuffer_add_printf(tmp, "hello"); /* 5 chars */ + evbuffer_add_buffer(buf, tmp); + evbuffer_add_printf(tmp, "foo"); /* 3 chars */ + evbuffer_add_buffer(buf, tmp); + evbuffer_add_printf(tmp, "cat"); /* 3 chars */ + evbuffer_add_buffer(buf, tmp); + evbuffer_add_printf(tmp, "attack"); + evbuffer_add_buffer(buf, tmp); + + pos = evbuffer_search(buf, "attack", 6, NULL); + tt_int_op(pos.pos, ==, 11); + pos = evbuffer_search(buf, "attacker", 8, NULL); + tt_int_op(pos.pos, ==, -1); + + /* test continuing search */ + pos = evbuffer_search(buf, "oc", 2, NULL); + tt_int_op(pos.pos, ==, 7); + pos = evbuffer_search(buf, "cat", 3, &pos); + tt_int_op(pos.pos, ==, 8); + pos = evbuffer_search(buf, "tacking", 7, &pos); + tt_int_op(pos.pos, ==, -1); + + evbuffer_ptr_set(buf, &pos, 5, EVBUFFER_PTR_SET); + pos = evbuffer_search(buf, "foo", 3, &pos); + tt_int_op(pos.pos, ==, 5); + + evbuffer_ptr_set(buf, &pos, 2, EVBUFFER_PTR_ADD); + pos = evbuffer_search(buf, "tat", 3, &pos); + tt_int_op(pos.pos, ==, 10); + + /* test bounded search. */ + /* Set "end" to the first t in "attack". */ + evbuffer_ptr_set(buf, &end, 12, EVBUFFER_PTR_SET); + pos = evbuffer_search_range(buf, "foo", 3, NULL, &end); + tt_int_op(pos.pos, ==, 5); + pos = evbuffer_search_range(buf, "foocata", 7, NULL, &end); + tt_int_op(pos.pos, ==, 5); + pos = evbuffer_search_range(buf, "foocatat", 8, NULL, &end); + tt_int_op(pos.pos, ==, -1); + pos = evbuffer_search_range(buf, "ack", 3, NULL, &end); + tt_int_op(pos.pos, ==, -1); + + /* Set "end" after the last byte in the buffer. */ + tt_assert(evbuffer_ptr_set(buf, &end, 17, EVBUFFER_PTR_SET) == 0); + + pos = evbuffer_search_range(buf, "attack", 6, NULL, &end); + tt_int_op(pos.pos, ==, 11); + tt_assert(evbuffer_ptr_set(buf, &pos, 11, EVBUFFER_PTR_SET) == 0); + pos = evbuffer_search_range(buf, "attack", 6, &pos, &end); + tt_int_op(pos.pos, ==, 11); + tt_assert(evbuffer_ptr_set(buf, &pos, 17, EVBUFFER_PTR_SET) == 0); + pos = evbuffer_search_range(buf, "attack", 6, &pos, &end); + tt_int_op(pos.pos, ==, -1); + tt_assert(evbuffer_ptr_set(buf, &pos, 17, EVBUFFER_PTR_SET) == 0); + pos = evbuffer_search_range(buf, "attack", 6, &pos, NULL); + tt_int_op(pos.pos, ==, -1); + +end: + if (buf) + evbuffer_free(buf); + if (tmp) + evbuffer_free(tmp); +} + +static void +log_change_callback(struct evbuffer *buffer, + const struct evbuffer_cb_info *cbinfo, + void *arg) +{ + + size_t old_len = cbinfo->orig_size; + size_t new_len = old_len + cbinfo->n_added - cbinfo->n_deleted; + struct evbuffer *out = arg; + evbuffer_add_printf(out, "%lu->%lu; ", (unsigned long)old_len, + (unsigned long)new_len); +} +static void +self_draining_callback(struct evbuffer *evbuffer, size_t old_len, + size_t new_len, void *arg) +{ + if (new_len > old_len) + evbuffer_drain(evbuffer, new_len); +} + +static void +test_evbuffer_callbacks(void *ptr) +{ + struct evbuffer *buf = evbuffer_new(); + struct evbuffer *buf_out1 = evbuffer_new(); + struct evbuffer *buf_out2 = evbuffer_new(); + struct evbuffer_cb_entry *cb1, *cb2; + + tt_assert(buf); + tt_assert(buf_out1); + tt_assert(buf_out2); + + cb1 = evbuffer_add_cb(buf, log_change_callback, buf_out1); + cb2 = evbuffer_add_cb(buf, log_change_callback, buf_out2); + + /* Let's run through adding and deleting some stuff from the buffer + * and turning the callbacks on and off and removing them. The callback + * adds a summary of length changes to buf_out1/buf_out2 when called. */ + /* size: 0-> 36. */ + evbuffer_add_printf(buf, "The %d magic words are spotty pudding", 2); + evbuffer_validate(buf); + evbuffer_cb_clear_flags(buf, cb2, EVBUFFER_CB_ENABLED); + evbuffer_drain(buf, 10); /*36->26*/ + evbuffer_validate(buf); + evbuffer_prepend(buf, "Hello", 5);/*26->31*/ + evbuffer_cb_set_flags(buf, cb2, EVBUFFER_CB_ENABLED); + evbuffer_add_reference(buf, "Goodbye", 7, NULL, NULL); /*31->38*/ + evbuffer_remove_cb_entry(buf, cb1); + evbuffer_validate(buf); + evbuffer_drain(buf, evbuffer_get_length(buf)); /*38->0*/; + tt_assert(-1 == evbuffer_remove_cb(buf, log_change_callback, NULL)); + evbuffer_add(buf, "X", 1); /* 0->1 */ + tt_assert(!evbuffer_remove_cb(buf, log_change_callback, buf_out2)); + evbuffer_validate(buf); + + tt_str_op((const char *) evbuffer_pullup(buf_out1, -1), ==, + "0->36; 36->26; 26->31; 31->38; "); + tt_str_op((const char *) evbuffer_pullup(buf_out2, -1), ==, + "0->36; 31->38; 38->0; 0->1; "); + evbuffer_drain(buf_out1, evbuffer_get_length(buf_out1)); + evbuffer_drain(buf_out2, evbuffer_get_length(buf_out2)); + /* Let's test the obsolete buffer_setcb function too. */ + cb1 = evbuffer_add_cb(buf, log_change_callback, buf_out1); + tt_assert(cb1 != NULL); + cb2 = evbuffer_add_cb(buf, log_change_callback, buf_out2); + tt_assert(cb2 != NULL); + evbuffer_setcb(buf, self_draining_callback, NULL); + evbuffer_add_printf(buf, "This should get drained right away."); + tt_uint_op(evbuffer_get_length(buf), ==, 0); + tt_uint_op(evbuffer_get_length(buf_out1), ==, 0); + tt_uint_op(evbuffer_get_length(buf_out2), ==, 0); + evbuffer_setcb(buf, NULL, NULL); + evbuffer_add_printf(buf, "This will not."); + tt_str_op((const char *) evbuffer_pullup(buf, -1), ==, "This will not."); + evbuffer_validate(buf); + evbuffer_drain(buf, evbuffer_get_length(buf)); + evbuffer_validate(buf); +#if 0 + /* Now let's try a suspended callback. */ + cb1 = evbuffer_add_cb(buf, log_change_callback, buf_out1); + cb2 = evbuffer_add_cb(buf, log_change_callback, buf_out2); + evbuffer_cb_suspend(buf,cb2); + evbuffer_prepend(buf,"Hello world",11); /*0->11*/ + evbuffer_validate(buf); + evbuffer_cb_suspend(buf,cb1); + evbuffer_add(buf,"more",4); /* 11->15 */ + evbuffer_cb_unsuspend(buf,cb2); + evbuffer_drain(buf, 4); /* 15->11 */ + evbuffer_cb_unsuspend(buf,cb1); + evbuffer_drain(buf, evbuffer_get_length(buf)); /* 11->0 */ + + tt_str_op(evbuffer_pullup(buf_out1, -1), ==, + "0->11; 11->11; 11->0; "); + tt_str_op(evbuffer_pullup(buf_out2, -1), ==, + "0->15; 15->11; 11->0; "); +#endif + + end: + if (buf) + evbuffer_free(buf); + if (buf_out1) + evbuffer_free(buf_out1); + if (buf_out2) + evbuffer_free(buf_out2); +} + +static int ref_done_cb_called_count = 0; +static void *ref_done_cb_called_with = NULL; +static const void *ref_done_cb_called_with_data = NULL; +static size_t ref_done_cb_called_with_len = 0; +static void ref_done_cb(const void *data, size_t len, void *info) +{ + ++ref_done_cb_called_count; + ref_done_cb_called_with = info; + ref_done_cb_called_with_data = data; + ref_done_cb_called_with_len = len; +} + +static void +test_evbuffer_add_reference(void *ptr) +{ + const char chunk1[] = "If you have found the answer to such a problem"; + const char chunk2[] = "you ought to write it up for publication"; + /* -- Knuth's "Notes on the Exercises" from TAOCP */ + char tmp[16]; + size_t len1 = strlen(chunk1), len2=strlen(chunk2); + + struct evbuffer *buf1 = NULL, *buf2 = NULL; + + buf1 = evbuffer_new(); + tt_assert(buf1); + + evbuffer_add_reference(buf1, chunk1, len1, ref_done_cb, (void*)111); + evbuffer_add(buf1, ", ", 2); + evbuffer_add_reference(buf1, chunk2, len2, ref_done_cb, (void*)222); + tt_int_op(evbuffer_get_length(buf1), ==, len1+len2+2); + + /* Make sure we can drain a little from a reference. */ + tt_int_op(evbuffer_remove(buf1, tmp, 6), ==, 6); + tt_int_op(memcmp(tmp, "If you", 6), ==, 0); + tt_int_op(evbuffer_remove(buf1, tmp, 5), ==, 5); + tt_int_op(memcmp(tmp, " have", 5), ==, 0); + + /* Make sure that prepending does not meddle with immutable data */ + tt_int_op(evbuffer_prepend(buf1, "I have ", 7), ==, 0); + tt_int_op(memcmp(chunk1, "If you", 6), ==, 0); + evbuffer_validate(buf1); + + /* Make sure that when the chunk is over, the callback is invoked. */ + evbuffer_drain(buf1, 7); /* Remove prepended stuff. */ + evbuffer_drain(buf1, len1-11-1); /* remove all but one byte of chunk1 */ + tt_int_op(ref_done_cb_called_count, ==, 0); + evbuffer_remove(buf1, tmp, 1); + tt_int_op(tmp[0], ==, 'm'); + tt_assert(ref_done_cb_called_with == (void*)111); + tt_assert(ref_done_cb_called_with_data == chunk1); + tt_assert(ref_done_cb_called_with_len == len1); + tt_int_op(ref_done_cb_called_count, ==, 1); + evbuffer_validate(buf1); + + /* Drain some of the remaining chunk, then add it to another buffer */ + evbuffer_drain(buf1, 6); /* Remove the ", you ". */ + buf2 = evbuffer_new(); + tt_assert(buf2); + tt_int_op(ref_done_cb_called_count, ==, 1); + evbuffer_add(buf2, "I ", 2); + + evbuffer_add_buffer(buf2, buf1); + tt_int_op(ref_done_cb_called_count, ==, 1); + evbuffer_remove(buf2, tmp, 16); + tt_int_op(memcmp("I ought to write", tmp, 16), ==, 0); + evbuffer_drain(buf2, evbuffer_get_length(buf2)); + tt_int_op(ref_done_cb_called_count, ==, 2); + tt_assert(ref_done_cb_called_with == (void*)222); + evbuffer_validate(buf2); + + /* Now add more stuff to buf1 and make sure that it gets removed on + * free. */ + evbuffer_add(buf1, "You shake and shake the ", 24); + evbuffer_add_reference(buf1, "ketchup bottle", 14, ref_done_cb, + (void*)3333); + evbuffer_add(buf1, ". Nothing comes and then a lot'll.", 35); + evbuffer_free(buf1); + buf1 = NULL; + tt_int_op(ref_done_cb_called_count, ==, 3); + tt_assert(ref_done_cb_called_with == (void*)3333); + +end: + if (buf1) + evbuffer_free(buf1); + if (buf2) + evbuffer_free(buf2); +} + +static void +test_evbuffer_multicast(void *ptr) +{ + const char chunk1[] = "If you have found the answer to such a problem"; + const char chunk2[] = "you ought to write it up for publication"; + /* -- Knuth's "Notes on the Exercises" from TAOCP */ + char tmp[16]; + size_t len1 = strlen(chunk1), len2=strlen(chunk2); + + struct evbuffer *buf1 = NULL, *buf2 = NULL; + + buf1 = evbuffer_new(); + tt_assert(buf1); + + evbuffer_add(buf1, chunk1, len1); + evbuffer_add(buf1, ", ", 2); + evbuffer_add(buf1, chunk2, len2); + tt_int_op(evbuffer_get_length(buf1), ==, len1+len2+2); + + buf2 = evbuffer_new(); + tt_assert(buf2); + + tt_int_op(evbuffer_add_buffer_reference(buf2, buf1), ==, 0); + /* nested references are not allowed */ + tt_int_op(evbuffer_add_buffer_reference(buf2, buf2), ==, -1); + tt_int_op(evbuffer_add_buffer_reference(buf1, buf2), ==, -1); + + /* both buffers contain the same amount of data */ + tt_int_op(evbuffer_get_length(buf1), ==, evbuffer_get_length(buf1)); + + /* Make sure we can drain a little from the first buffer. */ + tt_int_op(evbuffer_remove(buf1, tmp, 6), ==, 6); + tt_int_op(memcmp(tmp, "If you", 6), ==, 0); + tt_int_op(evbuffer_remove(buf1, tmp, 5), ==, 5); + tt_int_op(memcmp(tmp, " have", 5), ==, 0); + + /* Make sure that prepending does not meddle with immutable data */ + tt_int_op(evbuffer_prepend(buf1, "I have ", 7), ==, 0); + tt_int_op(memcmp(chunk1, "If you", 6), ==, 0); + evbuffer_validate(buf1); + + /* Make sure we can drain a little from the second buffer. */ + tt_int_op(evbuffer_remove(buf2, tmp, 6), ==, 6); + tt_int_op(memcmp(tmp, "If you", 6), ==, 0); + tt_int_op(evbuffer_remove(buf2, tmp, 5), ==, 5); + tt_int_op(memcmp(tmp, " have", 5), ==, 0); + + /* Make sure that prepending does not meddle with immutable data */ + tt_int_op(evbuffer_prepend(buf2, "I have ", 7), ==, 0); + tt_int_op(memcmp(chunk1, "If you", 6), ==, 0); + evbuffer_validate(buf2); + + /* Make sure the data can be read from the second buffer when the first is freed */ + evbuffer_free(buf1); + buf1 = NULL; + + tt_int_op(evbuffer_remove(buf2, tmp, 6), ==, 6); + tt_int_op(memcmp(tmp, "I have", 6), ==, 0); + + tt_int_op(evbuffer_remove(buf2, tmp, 6), ==, 6); + tt_int_op(memcmp(tmp, " foun", 6), ==, 0); + +end: + if (buf1) + evbuffer_free(buf1); + if (buf2) + evbuffer_free(buf2); +} + +static void +test_evbuffer_multicast_drain(void *ptr) +{ + const char chunk1[] = "If you have found the answer to such a problem"; + const char chunk2[] = "you ought to write it up for publication"; + /* -- Knuth's "Notes on the Exercises" from TAOCP */ + size_t len1 = strlen(chunk1), len2=strlen(chunk2); + + struct evbuffer *buf1 = NULL, *buf2 = NULL; + + buf1 = evbuffer_new(); + tt_assert(buf1); + + evbuffer_add(buf1, chunk1, len1); + evbuffer_add(buf1, ", ", 2); + evbuffer_add(buf1, chunk2, len2); + tt_int_op(evbuffer_get_length(buf1), ==, len1+len2+2); + + buf2 = evbuffer_new(); + tt_assert(buf2); + + tt_int_op(evbuffer_add_buffer_reference(buf2, buf1), ==, 0); + tt_int_op(evbuffer_get_length(buf2), ==, len1+len2+2); + tt_int_op(evbuffer_drain(buf1, evbuffer_get_length(buf1)), ==, 0); + tt_int_op(evbuffer_get_length(buf2), ==, len1+len2+2); + tt_int_op(evbuffer_drain(buf2, evbuffer_get_length(buf2)), ==, 0); + evbuffer_validate(buf1); + evbuffer_validate(buf2); + +end: + if (buf1) + evbuffer_free(buf1); + if (buf2) + evbuffer_free(buf2); +} + +/* Some cases that we didn't get in test_evbuffer() above, for more coverage. */ +static void +test_evbuffer_prepend(void *ptr) +{ + struct evbuffer *buf1 = NULL, *buf2 = NULL; + char tmp[128]; + int n; + + buf1 = evbuffer_new(); + tt_assert(buf1); + + /* Case 0: The evbuffer is entirely empty. */ + evbuffer_prepend(buf1, "This string has 29 characters", 29); + evbuffer_validate(buf1); + + /* Case 1: Prepend goes entirely in new chunk. */ + evbuffer_prepend(buf1, "Short.", 6); + evbuffer_validate(buf1); + + /* Case 2: prepend goes entirely in first chunk. */ + evbuffer_drain(buf1, 6+11); + evbuffer_prepend(buf1, "it", 2); + evbuffer_validate(buf1); + tt_assert(!memcmp(buf1->first->buffer+buf1->first->misalign, + "it has", 6)); + + /* Case 3: prepend is split over multiple chunks. */ + evbuffer_prepend(buf1, "It is no longer true to say ", 28); + evbuffer_validate(buf1); + n = evbuffer_remove(buf1, tmp, sizeof(tmp)-1); + tt_int_op(n, >=, 0); + tmp[n]='\0'; + tt_str_op(tmp,==,"It is no longer true to say it has 29 characters"); + + buf2 = evbuffer_new(); + tt_assert(buf2); + + /* Case 4: prepend a buffer to an empty buffer. */ + n = 999; + evbuffer_add_printf(buf1, "Here is string %d. ", n++); + evbuffer_prepend_buffer(buf2, buf1); + evbuffer_validate(buf2); + + /* Case 5: prepend a buffer to a nonempty buffer. */ + evbuffer_add_printf(buf1, "Here is string %d. ", n++); + evbuffer_prepend_buffer(buf2, buf1); + evbuffer_validate(buf2); + evbuffer_validate(buf1); + n = evbuffer_remove(buf2, tmp, sizeof(tmp)-1); + tt_int_op(n, >=, 0); + tmp[n]='\0'; + tt_str_op(tmp,==,"Here is string 1000. Here is string 999. "); + +end: + if (buf1) + evbuffer_free(buf1); + if (buf2) + evbuffer_free(buf2); + +} + +static void +test_evbuffer_peek_first_gt(void *info) +{ + struct evbuffer *buf = NULL, *tmp_buf = NULL; + struct evbuffer_ptr ptr; + struct evbuffer_iovec v[2]; + + buf = evbuffer_new(); + tmp_buf = evbuffer_new(); + evbuffer_add_printf(tmp_buf, "Contents of chunk 100\n"); + evbuffer_add_buffer(buf, tmp_buf); + evbuffer_add_printf(tmp_buf, "Contents of chunk 1\n"); + evbuffer_add_buffer(buf, tmp_buf); + + evbuffer_ptr_set(buf, &ptr, 0, EVBUFFER_PTR_SET); + + /** The only case that matters*/ + tt_int_op(evbuffer_peek(buf, -1, &ptr, NULL, 0), ==, 2); + /** Just in case */ + tt_int_op(evbuffer_peek(buf, -1, &ptr, v, 2), ==, 2); + + evbuffer_ptr_set(buf, &ptr, 20, EVBUFFER_PTR_ADD); + tt_int_op(evbuffer_peek(buf, -1, &ptr, NULL, 0), ==, 2); + tt_int_op(evbuffer_peek(buf, -1, &ptr, v, 2), ==, 2); + tt_int_op(evbuffer_peek(buf, 2, &ptr, NULL, 0), ==, 1); + tt_int_op(evbuffer_peek(buf, 2, &ptr, v, 2), ==, 1); + tt_int_op(evbuffer_peek(buf, 3, &ptr, NULL, 0), ==, 2); + tt_int_op(evbuffer_peek(buf, 3, &ptr, v, 2), ==, 2); + +end: + if (buf) + evbuffer_free(buf); + if (tmp_buf) + evbuffer_free(tmp_buf); +} + +static void +test_evbuffer_peek(void *info) +{ + struct evbuffer *buf = NULL, *tmp_buf = NULL; + int i; + struct evbuffer_iovec v[20]; + struct evbuffer_ptr ptr; + +#define tt_iov_eq(v, s) \ + tt_int_op((v)->iov_len, ==, strlen(s)); \ + tt_assert(!memcmp((v)->iov_base, (s), strlen(s))) + + /* Let's make a very fragmented buffer. */ + buf = evbuffer_new(); + tmp_buf = evbuffer_new(); + for (i = 0; i < 16; ++i) { + evbuffer_add_printf(tmp_buf, "Contents of chunk [%d]\n", i); + evbuffer_add_buffer(buf, tmp_buf); + } + + /* How many chunks do we need for everything? */ + i = evbuffer_peek(buf, -1, NULL, NULL, 0); + tt_int_op(i, ==, 16); + + /* Simple peek: get everything. */ + i = evbuffer_peek(buf, -1, NULL, v, 20); + tt_int_op(i, ==, 16); /* we used only 16 chunks. */ + tt_iov_eq(&v[0], "Contents of chunk [0]\n"); + tt_iov_eq(&v[3], "Contents of chunk [3]\n"); + tt_iov_eq(&v[12], "Contents of chunk [12]\n"); + tt_iov_eq(&v[15], "Contents of chunk [15]\n"); + + /* Just get one chunk worth. */ + memset(v, 0, sizeof(v)); + i = evbuffer_peek(buf, -1, NULL, v, 1); + tt_int_op(i, ==, 1); + tt_iov_eq(&v[0], "Contents of chunk [0]\n"); + tt_assert(v[1].iov_base == NULL); + + /* Suppose we want at least the first 40 bytes. */ + memset(v, 0, sizeof(v)); + i = evbuffer_peek(buf, 40, NULL, v, 16); + tt_int_op(i, ==, 2); + tt_iov_eq(&v[0], "Contents of chunk [0]\n"); + tt_iov_eq(&v[1], "Contents of chunk [1]\n"); + tt_assert(v[2].iov_base == NULL); + + /* How many chunks do we need for 100 bytes? */ + memset(v, 0, sizeof(v)); + i = evbuffer_peek(buf, 100, NULL, NULL, 0); + tt_int_op(i, ==, 5); + tt_assert(v[0].iov_base == NULL); + + /* Now we ask for more bytes than we provide chunks for */ + memset(v, 0, sizeof(v)); + i = evbuffer_peek(buf, 60, NULL, v, 1); + tt_int_op(i, ==, 3); + tt_iov_eq(&v[0], "Contents of chunk [0]\n"); + tt_assert(v[1].iov_base == NULL); + + /* Now we ask for more bytes than the buffer has. */ + memset(v, 0, sizeof(v)); + i = evbuffer_peek(buf, 65536, NULL, v, 20); + tt_int_op(i, ==, 16); /* we used only 16 chunks. */ + tt_iov_eq(&v[0], "Contents of chunk [0]\n"); + tt_iov_eq(&v[3], "Contents of chunk [3]\n"); + tt_iov_eq(&v[12], "Contents of chunk [12]\n"); + tt_iov_eq(&v[15], "Contents of chunk [15]\n"); + tt_assert(v[16].iov_base == NULL); + + /* What happens if we try an empty buffer? */ + memset(v, 0, sizeof(v)); + i = evbuffer_peek(tmp_buf, -1, NULL, v, 20); + tt_int_op(i, ==, 0); + tt_assert(v[0].iov_base == NULL); + memset(v, 0, sizeof(v)); + i = evbuffer_peek(tmp_buf, 50, NULL, v, 20); + tt_int_op(i, ==, 0); + tt_assert(v[0].iov_base == NULL); + + /* Okay, now time to have fun with pointers. */ + memset(v, 0, sizeof(v)); + evbuffer_ptr_set(buf, &ptr, 30, EVBUFFER_PTR_SET); + i = evbuffer_peek(buf, 50, &ptr, v, 20); + tt_int_op(i, ==, 3); + tt_iov_eq(&v[0], " of chunk [1]\n"); + tt_iov_eq(&v[1], "Contents of chunk [2]\n"); + tt_iov_eq(&v[2], "Contents of chunk [3]\n"); /*more than we asked for*/ + + /* advance to the start of another chain. */ + memset(v, 0, sizeof(v)); + evbuffer_ptr_set(buf, &ptr, 14, EVBUFFER_PTR_ADD); + i = evbuffer_peek(buf, 44, &ptr, v, 20); + tt_int_op(i, ==, 2); + tt_iov_eq(&v[0], "Contents of chunk [2]\n"); + tt_iov_eq(&v[1], "Contents of chunk [3]\n"); /*more than we asked for*/ + + /* peek at the end of the buffer */ + memset(v, 0, sizeof(v)); + tt_assert(evbuffer_ptr_set(buf, &ptr, evbuffer_get_length(buf), EVBUFFER_PTR_SET) == 0); + i = evbuffer_peek(buf, 44, &ptr, v, 20); + tt_int_op(i, ==, 0); + tt_assert(v[0].iov_base == NULL); + +end: + if (buf) + evbuffer_free(buf); + if (tmp_buf) + evbuffer_free(tmp_buf); +} + +/* Check whether evbuffer freezing works right. This is called twice, + once with the argument "start" and once with the argument "end". + When we test "start", we freeze the start of an evbuffer and make sure + that modifying the start of the buffer doesn't work. When we test + "end", we freeze the end of an evbuffer and make sure that modifying + the end of the buffer doesn't work. + */ +static void +test_evbuffer_freeze(void *ptr) +{ + struct evbuffer *buf = NULL, *tmp_buf=NULL; + const char string[] = /* Year's End, Richard Wilbur */ + "I've known the wind by water banks to shake\n" + "The late leaves down, which frozen where they fell\n" + "And held in ice as dancers in a spell\n" + "Fluttered all winter long into a lake..."; + const int start = !strcmp(ptr, "start"); + char *cp; + char charbuf[128]; + int r; + size_t orig_length; + struct evbuffer_iovec v[1]; + + if (!start) + tt_str_op(ptr, ==, "end"); + + buf = evbuffer_new(); + tmp_buf = evbuffer_new(); + tt_assert(tmp_buf); + + evbuffer_add(buf, string, strlen(string)); + evbuffer_freeze(buf, start); /* Freeze the start or the end.*/ + +#define FREEZE_EQ(a, startcase, endcase) \ + do { \ + if (start) { \ + tt_int_op((a), ==, (startcase)); \ + } else { \ + tt_int_op((a), ==, (endcase)); \ + } \ + } while (0) + + + orig_length = evbuffer_get_length(buf); + + /* These functions all manipulate the end of buf. */ + r = evbuffer_add(buf, "abc", 0); + FREEZE_EQ(r, 0, -1); + r = evbuffer_reserve_space(buf, 10, v, 1); + FREEZE_EQ(r, 1, -1); + if (r == 1) { + memset(v[0].iov_base, 'X', 10); + v[0].iov_len = 10; + } + r = evbuffer_commit_space(buf, v, 1); + FREEZE_EQ(r, 0, -1); + r = evbuffer_add_reference(buf, string, 5, NULL, NULL); + FREEZE_EQ(r, 0, -1); + r = evbuffer_add_printf(buf, "Hello %s", "world"); + FREEZE_EQ(r, 11, -1); + /* TODO: test add_buffer, add_file, read */ + + if (!start) + tt_int_op(orig_length, ==, evbuffer_get_length(buf)); + + orig_length = evbuffer_get_length(buf); + + /* These functions all manipulate the start of buf. */ + r = evbuffer_remove(buf, charbuf, 1); + FREEZE_EQ(r, -1, 1); + r = evbuffer_drain(buf, 3); + FREEZE_EQ(r, -1, 0); + r = evbuffer_prepend(buf, "dummy", 5); + FREEZE_EQ(r, -1, 0); + cp = evbuffer_readln(buf, NULL, EVBUFFER_EOL_LF); + FREEZE_EQ(cp==NULL, 1, 0); + if (cp) + free(cp); + /* TODO: Test remove_buffer, add_buffer, write, prepend_buffer */ + + if (start) + tt_int_op(orig_length, ==, evbuffer_get_length(buf)); + +end: + if (buf) + evbuffer_free(buf); + + if (tmp_buf) + evbuffer_free(tmp_buf); +} + +static void +test_evbuffer_add_iovec(void * ptr) +{ + struct evbuffer * buf = NULL; + struct evbuffer_iovec vec[4]; + const char * data[] = { + "Guilt resembles a sword with two edges.", + "On the one hand, it cuts for Justice, imposing practical morality upon those who fear it.", + "Conscience does not always adhere to rational judgment.", + "Guilt is always a self-imposed burden, but it is not always rightly imposed." + /* -- R.A. Salvatore, _Sojurn_ */ + }; + size_t expected_length = 0; + size_t returned_length = 0; + int i; + + buf = evbuffer_new(); + + tt_assert(buf); + + for (i = 0; i < 4; i++) { + vec[i].iov_len = strlen(data[i]); + vec[i].iov_base = (char*) data[i]; + expected_length += vec[i].iov_len; + } + + returned_length = evbuffer_add_iovec(buf, vec, 4); + + tt_int_op(returned_length, ==, evbuffer_get_length(buf)); + tt_int_op(evbuffer_get_length(buf), ==, expected_length); + + for (i = 0; i < 4; i++) { + char charbuf[1024]; + + memset(charbuf, 0, 1024); + evbuffer_remove(buf, charbuf, strlen(data[i])); + tt_assert(strcmp(charbuf, data[i]) == 0); + } + + tt_assert(evbuffer_get_length(buf) == 0); +end: + if (buf) { + evbuffer_free(buf); + } +} + +static void +test_evbuffer_copyout(void *dummy) +{ + const char string[] = + "Still they skirmish to and fro, men my messmates on the snow " + "When we headed off the aurochs turn for turn; " + "When the rich Allobrogenses never kept amanuenses, " + "And our only plots were piled in lakes at Berne."; + /* -- Kipling, "In The Neolithic Age" */ + char tmp[1024]; + struct evbuffer_ptr ptr; + struct evbuffer *buf; + + (void)dummy; + + buf = evbuffer_new(); + tt_assert(buf); + + tt_int_op(strlen(string), ==, 206); + + /* Ensure separate chains */ + evbuffer_add_reference(buf, string, 80, no_cleanup, NULL); + evbuffer_add_reference(buf, string+80, 80, no_cleanup, NULL); + evbuffer_add(buf, string+160, strlen(string)-160); + + tt_int_op(206, ==, evbuffer_get_length(buf)); + + /* First, let's test plain old copyout. */ + + /* Copy a little from the beginning. */ + tt_int_op(10, ==, evbuffer_copyout(buf, tmp, 10)); + tt_int_op(0, ==, memcmp(tmp, "Still they", 10)); + + /* Now copy more than a little from the beginning */ + memset(tmp, 0, sizeof(tmp)); + tt_int_op(100, ==, evbuffer_copyout(buf, tmp, 100)); + tt_int_op(0, ==, memcmp(tmp, string, 100)); + + /* Copy too much; ensure truncation. */ + memset(tmp, 0, sizeof(tmp)); + tt_int_op(206, ==, evbuffer_copyout(buf, tmp, 230)); + tt_int_op(0, ==, memcmp(tmp, string, 206)); + + /* That was supposed to be nondestructive, btw */ + tt_int_op(206, ==, evbuffer_get_length(buf)); + + /* Now it's time to test copyout_from! First, let's start in the + * first chain. */ + evbuffer_ptr_set(buf, &ptr, 15, EVBUFFER_PTR_SET); + memset(tmp, 0, sizeof(tmp)); + tt_int_op(10, ==, evbuffer_copyout_from(buf, &ptr, tmp, 10)); + tt_int_op(0, ==, memcmp(tmp, "mish to an", 10)); + + /* Right up to the end of the first chain */ + memset(tmp, 0, sizeof(tmp)); + tt_int_op(65, ==, evbuffer_copyout_from(buf, &ptr, tmp, 65)); + tt_int_op(0, ==, memcmp(tmp, string+15, 65)); + + /* Span into the second chain */ + memset(tmp, 0, sizeof(tmp)); + tt_int_op(90, ==, evbuffer_copyout_from(buf, &ptr, tmp, 90)); + tt_int_op(0, ==, memcmp(tmp, string+15, 90)); + + /* Span into the third chain */ + memset(tmp, 0, sizeof(tmp)); + tt_int_op(160, ==, evbuffer_copyout_from(buf, &ptr, tmp, 160)); + tt_int_op(0, ==, memcmp(tmp, string+15, 160)); + + /* Overrun */ + memset(tmp, 0, sizeof(tmp)); + tt_int_op(206-15, ==, evbuffer_copyout_from(buf, &ptr, tmp, 999)); + tt_int_op(0, ==, memcmp(tmp, string+15, 206-15)); + + /* That was supposed to be nondestructive, too */ + tt_int_op(206, ==, evbuffer_get_length(buf)); + +end: + if (buf) + evbuffer_free(buf); +} + +static void * +setup_passthrough(const struct testcase_t *testcase) +{ + return testcase->setup_data; +} +static int +cleanup_passthrough(const struct testcase_t *testcase, void *ptr) +{ + (void) ptr; + return 1; +} + +static const struct testcase_setup_t nil_setup = { + setup_passthrough, + cleanup_passthrough +}; + +struct testcase_t evbuffer_testcases[] = { + { "evbuffer", test_evbuffer, 0, NULL, NULL }, + { "remove_buffer_with_empty", test_evbuffer_remove_buffer_with_empty, 0, NULL, NULL }, + { "reserve2", test_evbuffer_reserve2, 0, NULL, NULL }, + { "reserve_many", test_evbuffer_reserve_many, 0, NULL, NULL }, + { "reserve_many2", test_evbuffer_reserve_many, 0, &nil_setup, (void*)"add" }, + { "reserve_many3", test_evbuffer_reserve_many, 0, &nil_setup, (void*)"fill" }, + { "expand", test_evbuffer_expand, 0, NULL, NULL }, + { "reference", test_evbuffer_reference, 0, NULL, NULL }, + { "iterative", test_evbuffer_iterative, 0, NULL, NULL }, + { "readln", test_evbuffer_readln, TT_NO_LOGS, &basic_setup, NULL }, + { "search_eol", test_evbuffer_search_eol, 0, NULL, NULL }, + { "find", test_evbuffer_find, 0, NULL, NULL }, + { "ptr_set", test_evbuffer_ptr_set, 0, NULL, NULL }, + { "search", test_evbuffer_search, 0, NULL, NULL }, + { "callbacks", test_evbuffer_callbacks, 0, NULL, NULL }, + { "add_reference", test_evbuffer_add_reference, 0, NULL, NULL }, + { "multicast", test_evbuffer_multicast, 0, NULL, NULL }, + { "multicast_drain", test_evbuffer_multicast_drain, 0, NULL, NULL }, + { "prepend", test_evbuffer_prepend, TT_FORK, NULL, NULL }, + { "peek", test_evbuffer_peek, 0, NULL, NULL }, + { "peek_first_gt", test_evbuffer_peek_first_gt, 0, NULL, NULL }, + { "freeze_start", test_evbuffer_freeze, 0, &nil_setup, (void*)"start" }, + { "freeze_end", test_evbuffer_freeze, 0, &nil_setup, (void*)"end" }, + { "add_iovec", test_evbuffer_add_iovec, 0, NULL, NULL}, + { "copyout", test_evbuffer_copyout, 0, NULL, NULL}, + { "file_segment_add_cleanup_cb", test_evbuffer_file_segment_add_cleanup_cb, 0, NULL, NULL }, + +#define ADDFILE_TEST(name, parameters) \ + { name, test_evbuffer_add_file, TT_FORK|TT_NEED_BASE, \ + &basic_setup, (void*)(parameters) } + +#define ADDFILE_TEST_GROUP(name, parameters) \ + ADDFILE_TEST(name "_sendfile", "sendfile " parameters), \ + ADDFILE_TEST(name "_mmap", "mmap " parameters), \ + ADDFILE_TEST(name "_linear", "linear " parameters) + + ADDFILE_TEST_GROUP("add_file", ""), + ADDFILE_TEST("add_file_nosegment", "default nosegment"), + + ADDFILE_TEST_GROUP("add_big_file", "bigfile"), + ADDFILE_TEST("add_big_file_nosegment", "default nosegment bigfile"), + + ADDFILE_TEST_GROUP("add_file_offset", "bigfile map_offset"), + ADDFILE_TEST("add_file_offset_nosegment", + "default nosegment bigfile map_offset"), + + ADDFILE_TEST_GROUP("add_file_offset2", "bigfile offset_in_segment"), + + ADDFILE_TEST_GROUP("add_file_offset3", + "bigfile offset_in_segment map_offset"), + + END_OF_TESTCASES +}; diff --git a/contrib/ntp/sntp/libevent/test/regress_bufferevent.c b/contrib/ntp/sntp/libevent/test/regress_bufferevent.c new file mode 100644 index 000000000..a1998ba62 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress_bufferevent.c @@ -0,0 +1,1162 @@ +/* + * Copyright (c) 2003-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "util-internal.h" + +/* The old tests here need assertions to work. */ +#undef NDEBUG + +#ifdef _WIN32 +#include +#include +#endif + +#include "event2/event-config.h" + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#ifndef _WIN32 +#include +#include +#include +#include +#include +#include +#endif +#include +#include +#include +#include +#include +#include +#include + +#ifdef EVENT__HAVE_ARPA_INET_H +#include +#endif + +#include "event2/event-config.h" +#include "event2/event.h" +#include "event2/event_struct.h" +#include "event2/event_compat.h" +#include "event2/tag.h" +#include "event2/buffer.h" +#include "event2/bufferevent.h" +#include "event2/bufferevent_compat.h" +#include "event2/bufferevent_struct.h" +#include "event2/listener.h" +#include "event2/util.h" + +#include "bufferevent-internal.h" +#include "evthread-internal.h" +#include "util-internal.h" +#ifdef _WIN32 +#include "iocp-internal.h" +#endif + +#include "regress.h" +#include "regress_testutils.h" + +/* + * simple bufferevent test + */ + +static void +readcb(struct bufferevent *bev, void *arg) +{ + if (evbuffer_get_length(bev->input) == 8333) { + struct evbuffer *evbuf = evbuffer_new(); + assert(evbuf != NULL); + + /* gratuitous test of bufferevent_read_buffer */ + bufferevent_read_buffer(bev, evbuf); + + bufferevent_disable(bev, EV_READ); + + if (evbuffer_get_length(evbuf) == 8333) { + test_ok++; + } + + evbuffer_free(evbuf); + } +} + +static void +writecb(struct bufferevent *bev, void *arg) +{ + if (evbuffer_get_length(bev->output) == 0) { + test_ok++; + } +} + +static void +errorcb(struct bufferevent *bev, short what, void *arg) +{ + test_ok = -2; +} + +static void +test_bufferevent_impl(int use_pair) +{ + struct bufferevent *bev1 = NULL, *bev2 = NULL; + char buffer[8333]; + int i; + + if (use_pair) { + struct bufferevent *pair[2]; + tt_assert(0 == bufferevent_pair_new(NULL, 0, pair)); + bev1 = pair[0]; + bev2 = pair[1]; + bufferevent_setcb(bev1, readcb, writecb, errorcb, bev1); + bufferevent_setcb(bev2, readcb, writecb, errorcb, NULL); + tt_int_op(bufferevent_getfd(bev1), ==, -1); + tt_ptr_op(bufferevent_get_underlying(bev1), ==, NULL); + tt_ptr_op(bufferevent_pair_get_partner(bev1), ==, bev2); + tt_ptr_op(bufferevent_pair_get_partner(bev2), ==, bev1); + } else { + bev1 = bufferevent_new(pair[0], readcb, writecb, errorcb, NULL); + bev2 = bufferevent_new(pair[1], readcb, writecb, errorcb, NULL); + tt_int_op(bufferevent_getfd(bev1), ==, pair[0]); + tt_ptr_op(bufferevent_get_underlying(bev1), ==, NULL); + tt_ptr_op(bufferevent_pair_get_partner(bev1), ==, NULL); + tt_ptr_op(bufferevent_pair_get_partner(bev2), ==, NULL); + } + + { + /* Test getcb. */ + bufferevent_data_cb r, w; + bufferevent_event_cb e; + void *a; + bufferevent_getcb(bev1, &r, &w, &e, &a); + tt_ptr_op(r, ==, readcb); + tt_ptr_op(w, ==, writecb); + tt_ptr_op(e, ==, errorcb); + tt_ptr_op(a, ==, use_pair ? bev1 : NULL); + } + + bufferevent_disable(bev1, EV_READ); + bufferevent_enable(bev2, EV_READ); + + tt_int_op(bufferevent_get_enabled(bev1), ==, EV_WRITE); + tt_int_op(bufferevent_get_enabled(bev2), ==, EV_WRITE|EV_READ); + + for (i = 0; i < (int)sizeof(buffer); i++) + buffer[i] = i; + + bufferevent_write(bev1, buffer, sizeof(buffer)); + + event_dispatch(); + + bufferevent_free(bev2); + tt_ptr_op(bufferevent_pair_get_partner(bev1), ==, NULL); + bufferevent_free(bev1); + + if (test_ok != 2) + test_ok = 0; +end: + ; +} + +static void +test_bufferevent(void) +{ + test_bufferevent_impl(0); +} + +static void +test_bufferevent_pair(void) +{ + test_bufferevent_impl(1); +} + +#if defined(EVTHREAD_USE_PTHREADS_IMPLEMENTED) +/** + * Trace lock/unlock/alloc/free for locks. + * (More heavier then evthread_debug*) + */ +typedef struct +{ + void *lock; + enum { + ALLOC, FREE, + } status; + size_t locked /** allow recursive locking */; +} lock_wrapper; +struct lock_unlock_base +{ + /* Original callbacks */ + struct evthread_lock_callbacks cbs; + /* Map of locks */ + lock_wrapper *locks; + size_t nr_locks; +} lu_base = { + .locks = NULL, +}; + +static lock_wrapper *lu_find(void *lock_) +{ + size_t i; + for (i = 0; i < lu_base.nr_locks; ++i) { + lock_wrapper *lock = &lu_base.locks[i]; + if (lock->lock == lock_) + return lock; + } + return NULL; +} + +static void *trace_lock_alloc(unsigned locktype) +{ + ++lu_base.nr_locks; + lu_base.locks = realloc(lu_base.locks, + sizeof(lock_wrapper) * lu_base.nr_locks); + void *lock = lu_base.cbs.alloc(locktype); + lu_base.locks[lu_base.nr_locks - 1] = (lock_wrapper){ lock, ALLOC, 0 }; + return lock; +} +static void trace_lock_free(void *lock_, unsigned locktype) +{ + lock_wrapper *lock = lu_find(lock_); + if (!lock || lock->status == FREE || lock->locked) { + __asm__("int3"); + TT_FAIL(("lock: free error")); + } else { + lock->status = FREE; + lu_base.cbs.free(lock_, locktype); + } +} +static int trace_lock_lock(unsigned mode, void *lock_) +{ + lock_wrapper *lock = lu_find(lock_); + if (!lock || lock->status == FREE) { + TT_FAIL(("lock: lock error")); + return -1; + } else { + ++lock->locked; + return lu_base.cbs.lock(mode, lock_); + } +} +static int trace_lock_unlock(unsigned mode, void *lock_) +{ + lock_wrapper *lock = lu_find(lock_); + if (!lock || lock->status == FREE || !lock->locked) { + TT_FAIL(("lock: unlock error")); + return -1; + } else { + --lock->locked; + return lu_base.cbs.unlock(mode, lock_); + } +} +static void lock_unlock_free_thread_cbs() +{ + event_base_free(NULL); + + /** drop immutable flag */ + evthread_set_lock_callbacks(NULL); + /** avoid calling of event_global_setup_locks_() for new cbs */ + libevent_global_shutdown(); + /** drop immutable flag for non-debug ops (since called after shutdown) */ + evthread_set_lock_callbacks(NULL); +} + +static int use_lock_unlock_profiler(void) +{ + struct evthread_lock_callbacks cbs = { + EVTHREAD_LOCK_API_VERSION, + EVTHREAD_LOCKTYPE_RECURSIVE, + trace_lock_alloc, + trace_lock_free, + trace_lock_lock, + trace_lock_unlock, + }; + memcpy(&lu_base.cbs, evthread_get_lock_callbacks(), + sizeof(lu_base.cbs)); + { + lock_unlock_free_thread_cbs(); + + evthread_set_lock_callbacks(&cbs); + /** re-create debug locks correctly */ + evthread_enable_lock_debugging(); + + event_init(); + } + return 0; +} +static void free_lock_unlock_profiler(struct basic_test_data *data) +{ + lock_unlock_free_thread_cbs(); + free(lu_base.locks); + data->base = NULL; +} + +static void test_bufferevent_pair_release_lock(void *arg) +{ + struct basic_test_data *data = arg; + use_lock_unlock_profiler(); + { + struct bufferevent *pair[2]; + if (!bufferevent_pair_new(NULL, BEV_OPT_THREADSAFE, pair)) { + bufferevent_free(pair[0]); + bufferevent_free(pair[1]); + } else + tt_abort_perror("bufferevent_pair_new"); + } + free_lock_unlock_profiler(data); +end: + ; +} +#endif + +/* + * test watermarks and bufferevent + */ + +static void +wm_readcb(struct bufferevent *bev, void *arg) +{ + struct evbuffer *evbuf = evbuffer_new(); + int len = (int)evbuffer_get_length(bev->input); + static int nread; + + assert(len >= 10 && len <= 20); + + assert(evbuf != NULL); + + /* gratuitous test of bufferevent_read_buffer */ + bufferevent_read_buffer(bev, evbuf); + + nread += len; + if (nread == 65000) { + bufferevent_disable(bev, EV_READ); + test_ok++; + } + + evbuffer_free(evbuf); +} + +static void +wm_writecb(struct bufferevent *bev, void *arg) +{ + assert(evbuffer_get_length(bev->output) <= 100); + if (evbuffer_get_length(bev->output) == 0) { + evbuffer_drain(bev->output, evbuffer_get_length(bev->output)); + test_ok++; + } +} + +static void +wm_errorcb(struct bufferevent *bev, short what, void *arg) +{ + test_ok = -2; +} + +static void +test_bufferevent_watermarks_impl(int use_pair) +{ + struct bufferevent *bev1 = NULL, *bev2 = NULL; + char buffer[65000]; + size_t low, high; + int i; + test_ok = 0; + + if (use_pair) { + struct bufferevent *pair[2]; + tt_assert(0 == bufferevent_pair_new(NULL, 0, pair)); + bev1 = pair[0]; + bev2 = pair[1]; + bufferevent_setcb(bev1, NULL, wm_writecb, errorcb, NULL); + bufferevent_setcb(bev2, wm_readcb, NULL, errorcb, NULL); + } else { + bev1 = bufferevent_new(pair[0], NULL, wm_writecb, wm_errorcb, NULL); + bev2 = bufferevent_new(pair[1], wm_readcb, NULL, wm_errorcb, NULL); + } + tt_assert(bev1); + tt_assert(bev2); + bufferevent_disable(bev1, EV_READ); + bufferevent_enable(bev2, EV_READ); + + /* By default, low watermarks are set to 0 */ + bufferevent_getwatermark(bev1, EV_READ, &low, NULL); + tt_int_op(low, ==, 0); + bufferevent_getwatermark(bev2, EV_WRITE, &low, NULL); + tt_int_op(low, ==, 0); + + for (i = 0; i < (int)sizeof(buffer); i++) + buffer[i] = (char)i; + + /* limit the reading on the receiving bufferevent */ + bufferevent_setwatermark(bev2, EV_READ, 10, 20); + + bufferevent_getwatermark(bev2, EV_READ, &low, &high); + tt_int_op(low, ==, 10); + tt_int_op(high, ==, 20); + + /* Tell the sending bufferevent not to notify us till it's down to + 100 bytes. */ + bufferevent_setwatermark(bev1, EV_WRITE, 100, 2000); + + bufferevent_getwatermark(bev1, EV_WRITE, &low, &high); + tt_int_op(low, ==, 100); + tt_int_op(high, ==, 2000); + + { + int r = bufferevent_getwatermark(bev1, EV_WRITE | EV_READ, &low, &high); + tt_int_op(r, !=, 0); + } + + bufferevent_write(bev1, buffer, sizeof(buffer)); + + event_dispatch(); + + tt_int_op(test_ok, ==, 2); + + /* The write callback drained all the data from outbuf, so we + * should have removed the write event... */ + tt_assert(!event_pending(&bev2->ev_write, EV_WRITE, NULL)); + +end: + if (bev1) + bufferevent_free(bev1); + if (bev2) + bufferevent_free(bev2); +} + +static void +test_bufferevent_watermarks(void) +{ + test_bufferevent_watermarks_impl(0); +} + +static void +test_bufferevent_pair_watermarks(void) +{ + test_bufferevent_watermarks_impl(1); +} + +/* + * Test bufferevent filters + */ + +/* strip an 'x' from each byte */ + +static enum bufferevent_filter_result +bufferevent_input_filter(struct evbuffer *src, struct evbuffer *dst, + ev_ssize_t lim, enum bufferevent_flush_mode state, void *ctx) +{ + const unsigned char *buffer; + unsigned i; + + buffer = evbuffer_pullup(src, evbuffer_get_length(src)); + for (i = 0; i < evbuffer_get_length(src); i += 2) { + assert(buffer[i] == 'x'); + evbuffer_add(dst, buffer + i + 1, 1); + + if (i + 2 > evbuffer_get_length(src)) + break; + } + + evbuffer_drain(src, i); + return (BEV_OK); +} + +/* add an 'x' before each byte */ + +static enum bufferevent_filter_result +bufferevent_output_filter(struct evbuffer *src, struct evbuffer *dst, + ev_ssize_t lim, enum bufferevent_flush_mode state, void *ctx) +{ + const unsigned char *buffer; + unsigned i; + + buffer = evbuffer_pullup(src, evbuffer_get_length(src)); + for (i = 0; i < evbuffer_get_length(src); ++i) { + evbuffer_add(dst, "x", 1); + evbuffer_add(dst, buffer + i, 1); + } + + evbuffer_drain(src, evbuffer_get_length(src)); + return (BEV_OK); +} + +static void +test_bufferevent_filters_impl(int use_pair) +{ + struct bufferevent *bev1 = NULL, *bev2 = NULL; + struct bufferevent *bev1_base = NULL, *bev2_base = NULL; + char buffer[8333]; + int i; + + test_ok = 0; + + if (use_pair) { + struct bufferevent *pair[2]; + tt_assert(0 == bufferevent_pair_new(NULL, 0, pair)); + bev1 = pair[0]; + bev2 = pair[1]; + } else { + bev1 = bufferevent_socket_new(NULL, pair[0], 0); + bev2 = bufferevent_socket_new(NULL, pair[1], 0); + } + bev1_base = bev1; + bev2_base = bev2; + + for (i = 0; i < (int)sizeof(buffer); i++) + buffer[i] = i; + + bev1 = bufferevent_filter_new(bev1, NULL, bufferevent_output_filter, + BEV_OPT_CLOSE_ON_FREE, NULL, NULL); + + bev2 = bufferevent_filter_new(bev2, bufferevent_input_filter, + NULL, BEV_OPT_CLOSE_ON_FREE, NULL, NULL); + bufferevent_setcb(bev1, NULL, writecb, errorcb, NULL); + bufferevent_setcb(bev2, readcb, NULL, errorcb, NULL); + + tt_ptr_op(bufferevent_get_underlying(bev1), ==, bev1_base); + tt_ptr_op(bufferevent_get_underlying(bev2), ==, bev2_base); + tt_int_op(bufferevent_getfd(bev1), ==, -1); + tt_int_op(bufferevent_getfd(bev2), ==, -1); + + bufferevent_disable(bev1, EV_READ); + bufferevent_enable(bev2, EV_READ); + /* insert some filters */ + bufferevent_write(bev1, buffer, sizeof(buffer)); + + event_dispatch(); + + if (test_ok != 2) + test_ok = 0; + +end: + if (bev1) + bufferevent_free(bev1); + if (bev2) + bufferevent_free(bev2); + +} + +static void +test_bufferevent_filters(void) +{ + test_bufferevent_filters_impl(0); +} + +static void +test_bufferevent_pair_filters(void) +{ + test_bufferevent_filters_impl(1); +} + + +static void +sender_writecb(struct bufferevent *bev, void *ctx) +{ + if (evbuffer_get_length(bufferevent_get_output(bev)) == 0) { + bufferevent_disable(bev,EV_READ|EV_WRITE); + TT_BLATHER(("Flushed %d: freeing it.", (int)bufferevent_getfd(bev))); + bufferevent_free(bev); + } +} + +static void +sender_errorcb(struct bufferevent *bev, short what, void *ctx) +{ + TT_FAIL(("Got sender error %d",(int)what)); +} + +static int bufferevent_connect_test_flags = 0; +static int bufferevent_trigger_test_flags = 0; +static int n_strings_read = 0; +static int n_reads_invoked = 0; + +#define TEST_STR "Now is the time for all good events to signal for " \ + "the good of their protocol" +static void +listen_cb(struct evconnlistener *listener, evutil_socket_t fd, + struct sockaddr *sa, int socklen, void *arg) +{ + struct event_base *base = arg; + struct bufferevent *bev; + const char s[] = TEST_STR; + TT_BLATHER(("Got a request on socket %d", (int)fd )); + bev = bufferevent_socket_new(base, fd, bufferevent_connect_test_flags); + tt_assert(bev); + bufferevent_setcb(bev, NULL, sender_writecb, sender_errorcb, NULL); + bufferevent_write(bev, s, sizeof(s)); +end: + ; +} + +static void +reader_eventcb(struct bufferevent *bev, short what, void *ctx) +{ + struct event_base *base = ctx; + if (what & BEV_EVENT_ERROR) { + perror("foobar"); + TT_FAIL(("got connector error %d", (int)what)); + return; + } + if (what & BEV_EVENT_CONNECTED) { + TT_BLATHER(("connected on %d", (int)bufferevent_getfd(bev))); + bufferevent_enable(bev, EV_READ); + } + if (what & BEV_EVENT_EOF) { + char buf[512]; + size_t n; + n = bufferevent_read(bev, buf, sizeof(buf)-1); + tt_int_op(n, >=, 0); + buf[n] = '\0'; + tt_str_op(buf, ==, TEST_STR); + if (++n_strings_read == 2) + event_base_loopexit(base, NULL); + TT_BLATHER(("EOF on %d: %d strings read.", + (int)bufferevent_getfd(bev), n_strings_read)); + } +end: + ; +} + +static void +reader_readcb(struct bufferevent *bev, void *ctx) +{ + TT_BLATHER(("Read invoked on %d.", (int)bufferevent_getfd(bev))); + n_reads_invoked++; +} + +static void +test_bufferevent_connect(void *arg) +{ + struct basic_test_data *data = arg; + struct evconnlistener *lev=NULL; + struct bufferevent *bev1=NULL, *bev2=NULL; + struct sockaddr_in localhost; + struct sockaddr_storage ss; + struct sockaddr *sa; + ev_socklen_t slen; + + int be_flags=BEV_OPT_CLOSE_ON_FREE; + + if (strstr((char*)data->setup_data, "defer")) { + be_flags |= BEV_OPT_DEFER_CALLBACKS; + } + if (strstr((char*)data->setup_data, "unlocked")) { + be_flags |= BEV_OPT_UNLOCK_CALLBACKS; + } + if (strstr((char*)data->setup_data, "lock")) { + be_flags |= BEV_OPT_THREADSAFE; + } + bufferevent_connect_test_flags = be_flags; +#ifdef _WIN32 + if (!strcmp((char*)data->setup_data, "unset_connectex")) { + struct win32_extension_fns *ext = + (struct win32_extension_fns *) + event_get_win32_extension_fns_(); + ext->ConnectEx = NULL; + } +#endif + + memset(&localhost, 0, sizeof(localhost)); + + localhost.sin_port = 0; /* pick-a-port */ + localhost.sin_addr.s_addr = htonl(0x7f000001L); + localhost.sin_family = AF_INET; + sa = (struct sockaddr *)&localhost; + lev = evconnlistener_new_bind(data->base, listen_cb, data->base, + LEV_OPT_CLOSE_ON_FREE|LEV_OPT_REUSEABLE, + 16, sa, sizeof(localhost)); + tt_assert(lev); + + sa = (struct sockaddr *)&ss; + slen = sizeof(ss); + if (regress_get_listener_addr(lev, sa, &slen) < 0) { + tt_abort_perror("getsockname"); + } + + tt_assert(!evconnlistener_enable(lev)); + bev1 = bufferevent_socket_new(data->base, -1, be_flags); + bev2 = bufferevent_socket_new(data->base, -1, be_flags); + tt_assert(bev1); + tt_assert(bev2); + bufferevent_setcb(bev1, reader_readcb,NULL, reader_eventcb, data->base); + bufferevent_setcb(bev2, reader_readcb,NULL, reader_eventcb, data->base); + + bufferevent_enable(bev1, EV_READ); + bufferevent_enable(bev2, EV_READ); + + tt_want(!bufferevent_socket_connect(bev1, sa, sizeof(localhost))); + tt_want(!bufferevent_socket_connect(bev2, sa, sizeof(localhost))); + + event_base_dispatch(data->base); + + tt_int_op(n_strings_read, ==, 2); + tt_int_op(n_reads_invoked, >=, 2); +end: + if (lev) + evconnlistener_free(lev); + + if (bev1) + bufferevent_free(bev1); + + if (bev2) + bufferevent_free(bev2); +} + +static void +want_fail_eventcb(struct bufferevent *bev, short what, void *ctx) +{ + struct event_base *base = ctx; + const char *err; + evutil_socket_t s; + + if (what & BEV_EVENT_ERROR) { + s = bufferevent_getfd(bev); + err = evutil_socket_error_to_string(evutil_socket_geterror(s)); + TT_BLATHER(("connection failure on "EV_SOCK_FMT": %s", + EV_SOCK_ARG(s), err)); + test_ok = 1; + } else { + TT_FAIL(("didn't fail? what %hd", what)); + } + + event_base_loopexit(base, NULL); +} + +static void +close_socket_cb(evutil_socket_t fd, short what, void *arg) +{ + evutil_socket_t *fdp = arg; + if (*fdp >= 0) { + evutil_closesocket(*fdp); + *fdp = -1; + } +} + +static void +test_bufferevent_connect_fail(void *arg) +{ + struct basic_test_data *data = (struct basic_test_data *)arg; + struct bufferevent *bev=NULL; + struct sockaddr_in localhost; + struct sockaddr *sa = (struct sockaddr*)&localhost; + evutil_socket_t fake_listener = -1; + ev_socklen_t slen = sizeof(localhost); + struct event close_listener_event; + int close_listener_event_added = 0; + struct timeval one_second = { 1, 0 }; + int r; + + test_ok = 0; + + memset(&localhost, 0, sizeof(localhost)); + localhost.sin_port = 0; /* have the kernel pick a port */ + localhost.sin_addr.s_addr = htonl(0x7f000001L); + localhost.sin_family = AF_INET; + + /* bind, but don't listen or accept. should trigger + "Connection refused" reliably on most platforms. */ + fake_listener = socket(localhost.sin_family, SOCK_STREAM, 0); + tt_assert(fake_listener >= 0); + tt_assert(bind(fake_listener, sa, slen) == 0); + tt_assert(getsockname(fake_listener, sa, &slen) == 0); + bev = bufferevent_socket_new(data->base, -1, + BEV_OPT_CLOSE_ON_FREE | BEV_OPT_DEFER_CALLBACKS); + tt_assert(bev); + bufferevent_setcb(bev, NULL, NULL, want_fail_eventcb, data->base); + + r = bufferevent_socket_connect(bev, sa, slen); + /* XXXX we'd like to test the '0' case everywhere, but FreeBSD tells + * detects the error immediately, which is not really wrong of it. */ + tt_want(r == 0 || r == -1); + + /* Close the listener socket after a second. This should trigger + "connection refused" on some other platforms, including OSX. */ + evtimer_assign(&close_listener_event, data->base, close_socket_cb, + &fake_listener); + event_add(&close_listener_event, &one_second); + close_listener_event_added = 1; + + event_base_dispatch(data->base); + + tt_int_op(test_ok, ==, 1); + +end: + if (fake_listener >= 0) + evutil_closesocket(fake_listener); + + if (bev) + bufferevent_free(bev); + + if (close_listener_event_added) + event_del(&close_listener_event); +} + +struct timeout_cb_result { + struct timeval read_timeout_at; + struct timeval write_timeout_at; + struct timeval last_wrote_at; + int n_read_timeouts; + int n_write_timeouts; + int total_calls; +}; + +static void +bev_timeout_write_cb(struct bufferevent *bev, void *arg) +{ + struct timeout_cb_result *res = arg; + evutil_gettimeofday(&res->last_wrote_at, NULL); +} + +static void +bev_timeout_event_cb(struct bufferevent *bev, short what, void *arg) +{ + struct timeout_cb_result *res = arg; + ++res->total_calls; + + if ((what & (BEV_EVENT_READING|BEV_EVENT_TIMEOUT)) + == (BEV_EVENT_READING|BEV_EVENT_TIMEOUT)) { + evutil_gettimeofday(&res->read_timeout_at, NULL); + ++res->n_read_timeouts; + } + if ((what & (BEV_EVENT_WRITING|BEV_EVENT_TIMEOUT)) + == (BEV_EVENT_WRITING|BEV_EVENT_TIMEOUT)) { + evutil_gettimeofday(&res->write_timeout_at, NULL); + ++res->n_write_timeouts; + } +} + +static void +test_bufferevent_timeouts(void *arg) +{ + /* "arg" is a string containing "pair" and/or "filter". */ + struct bufferevent *bev1 = NULL, *bev2 = NULL; + struct basic_test_data *data = arg; + int use_pair = 0, use_filter = 0; + struct timeval tv_w, tv_r, started_at; + struct timeout_cb_result res1, res2; + char buf[1024]; + + memset(&res1, 0, sizeof(res1)); + memset(&res2, 0, sizeof(res2)); + + if (strstr((char*)data->setup_data, "pair")) + use_pair = 1; + if (strstr((char*)data->setup_data, "filter")) + use_filter = 1; + + if (use_pair) { + struct bufferevent *p[2]; + tt_int_op(0, ==, bufferevent_pair_new(data->base, 0, p)); + bev1 = p[0]; + bev2 = p[1]; + } else { + bev1 = bufferevent_socket_new(data->base, data->pair[0], 0); + bev2 = bufferevent_socket_new(data->base, data->pair[1], 0); + } + + tt_assert(bev1); + tt_assert(bev2); + + if (use_filter) { + struct bufferevent *bevf1, *bevf2; + bevf1 = bufferevent_filter_new(bev1, NULL, NULL, + BEV_OPT_CLOSE_ON_FREE, NULL, NULL); + bevf2 = bufferevent_filter_new(bev2, NULL, NULL, + BEV_OPT_CLOSE_ON_FREE, NULL, NULL); + tt_assert(bevf1); + tt_assert(bevf2); + bev1 = bevf1; + bev2 = bevf2; + } + + /* Do this nice and early. */ + bufferevent_disable(bev2, EV_READ); + + /* bev1 will try to write and read. Both will time out. */ + evutil_gettimeofday(&started_at, NULL); + tv_w.tv_sec = tv_r.tv_sec = 0; + tv_w.tv_usec = 100*1000; + tv_r.tv_usec = 150*1000; + bufferevent_setcb(bev1, NULL, bev_timeout_write_cb, + bev_timeout_event_cb, &res1); + bufferevent_setwatermark(bev1, EV_WRITE, 1024*1024+10, 0); + bufferevent_set_timeouts(bev1, &tv_r, &tv_w); + if (use_pair) { + /* For a pair, the fact that the other side isn't reading + * makes the writer stall */ + bufferevent_write(bev1, "ABCDEFG", 7); + } else { + /* For a real socket, the kernel's TCP buffers can eat a + * fair number of bytes; make sure that at some point we + * have some bytes that will stall. */ + struct evbuffer *output = bufferevent_get_output(bev1); + int i; + memset(buf, 0xbb, sizeof(buf)); + for (i=0;i<1024;++i) { + evbuffer_add_reference(output, buf, sizeof(buf), + NULL, NULL); + } + } + bufferevent_enable(bev1, EV_READ|EV_WRITE); + + /* bev2 has nothing to say, and isn't listening. */ + bufferevent_setcb(bev2, NULL, bev_timeout_write_cb, + bev_timeout_event_cb, &res2); + tv_w.tv_sec = tv_r.tv_sec = 0; + tv_w.tv_usec = 200*1000; + tv_r.tv_usec = 100*1000; + bufferevent_set_timeouts(bev2, &tv_r, &tv_w); + bufferevent_enable(bev2, EV_WRITE); + + tv_r.tv_sec = 0; + tv_r.tv_usec = 350000; + + event_base_loopexit(data->base, &tv_r); + event_base_dispatch(data->base); + + /* XXXX Test that actually reading or writing a little resets the + * timeouts. */ + + /* Each buf1 timeout happens, and happens only once. */ + tt_want(res1.n_read_timeouts); + tt_want(res1.n_write_timeouts); + tt_want(res1.n_read_timeouts == 1); + tt_want(res1.n_write_timeouts == 1); + + test_timeval_diff_eq(&started_at, &res1.read_timeout_at, 150); + test_timeval_diff_eq(&started_at, &res1.write_timeout_at, 100); + +end: + if (bev1) + bufferevent_free(bev1); + if (bev2) + bufferevent_free(bev2); +} + +static void +trigger_failure_cb(evutil_socket_t fd, short what, void *ctx) +{ + TT_FAIL(("The triggered callback did not fire or the machine is really slow (try increasing timeout).")); +} + +static void +trigger_eventcb(struct bufferevent *bev, short what, void *ctx) +{ + struct event_base *base = ctx; + if (what == ~0) { + TT_BLATHER(("Event successfully triggered.")); + event_base_loopexit(base, NULL); + return; + } + reader_eventcb(bev, what, ctx); +} + +static void +trigger_readcb_triggered(struct bufferevent *bev, void *ctx) +{ + TT_BLATHER(("Read successfully triggered.")); + n_reads_invoked++; + bufferevent_trigger_event(bev, ~0, bufferevent_trigger_test_flags); +} + +static void +trigger_readcb(struct bufferevent *bev, void *ctx) +{ + struct timeval timeout = { 30, 0 }; + struct event_base *base = ctx; + size_t low, high, len; + int expected_reads; + + TT_BLATHER(("Read invoked on %d.", (int)bufferevent_getfd(bev))); + expected_reads = ++n_reads_invoked; + + bufferevent_setcb(bev, trigger_readcb_triggered, NULL, trigger_eventcb, ctx); + + bufferevent_getwatermark(bev, EV_READ, &low, &high); + len = evbuffer_get_length(bufferevent_get_input(bev)); + + bufferevent_setwatermark(bev, EV_READ, len + 1, 0); + bufferevent_trigger(bev, EV_READ, bufferevent_trigger_test_flags); + /* no callback expected */ + tt_int_op(n_reads_invoked, ==, expected_reads); + + if ((bufferevent_trigger_test_flags & BEV_TRIG_DEFER_CALLBACKS) || + (bufferevent_connect_test_flags & BEV_OPT_DEFER_CALLBACKS)) { + /* will be deferred */ + } else { + expected_reads++; + } + + event_base_once(base, -1, EV_TIMEOUT, trigger_failure_cb, NULL, &timeout); + + bufferevent_trigger(bev, EV_READ, + bufferevent_trigger_test_flags | BEV_TRIG_IGNORE_WATERMARKS); + tt_int_op(n_reads_invoked, ==, expected_reads); + + bufferevent_setwatermark(bev, EV_READ, low, high); +end: + ; +} + +static void +test_bufferevent_trigger(void *arg) +{ + struct basic_test_data *data = arg; + struct evconnlistener *lev=NULL; + struct bufferevent *bev=NULL; + struct sockaddr_in localhost; + struct sockaddr_storage ss; + struct sockaddr *sa; + ev_socklen_t slen; + + int be_flags=BEV_OPT_CLOSE_ON_FREE; + int trig_flags=0; + + if (strstr((char*)data->setup_data, "defer")) { + be_flags |= BEV_OPT_DEFER_CALLBACKS; + } + bufferevent_connect_test_flags = be_flags; + + if (strstr((char*)data->setup_data, "postpone")) { + trig_flags |= BEV_TRIG_DEFER_CALLBACKS; + } + bufferevent_trigger_test_flags = trig_flags; + + memset(&localhost, 0, sizeof(localhost)); + + localhost.sin_port = 0; /* pick-a-port */ + localhost.sin_addr.s_addr = htonl(0x7f000001L); + localhost.sin_family = AF_INET; + sa = (struct sockaddr *)&localhost; + lev = evconnlistener_new_bind(data->base, listen_cb, data->base, + LEV_OPT_CLOSE_ON_FREE|LEV_OPT_REUSEABLE, + 16, sa, sizeof(localhost)); + tt_assert(lev); + + sa = (struct sockaddr *)&ss; + slen = sizeof(ss); + if (regress_get_listener_addr(lev, sa, &slen) < 0) { + tt_abort_perror("getsockname"); + } + + tt_assert(!evconnlistener_enable(lev)); + bev = bufferevent_socket_new(data->base, -1, be_flags); + tt_assert(bev); + bufferevent_setcb(bev, trigger_readcb, NULL, trigger_eventcb, data->base); + + bufferevent_enable(bev, EV_READ); + + tt_want(!bufferevent_socket_connect(bev, sa, sizeof(localhost))); + + event_base_dispatch(data->base); + + tt_int_op(n_reads_invoked, ==, 2); +end: + if (lev) + evconnlistener_free(lev); + + if (bev) + bufferevent_free(bev); +} + +struct testcase_t bufferevent_testcases[] = { + + LEGACY(bufferevent, TT_ISOLATED), + LEGACY(bufferevent_pair, TT_ISOLATED), +#if defined(EVTHREAD_USE_PTHREADS_IMPLEMENTED) + { "bufferevent_pair_release_lock", test_bufferevent_pair_release_lock, + TT_FORK|TT_ISOLATED|TT_NEED_THREADS|TT_NEED_BASE|TT_LEGACY, + &basic_setup, NULL }, +#endif + LEGACY(bufferevent_watermarks, TT_ISOLATED), + LEGACY(bufferevent_pair_watermarks, TT_ISOLATED), + LEGACY(bufferevent_filters, TT_ISOLATED), + LEGACY(bufferevent_pair_filters, TT_ISOLATED), + { "bufferevent_connect", test_bufferevent_connect, TT_FORK|TT_NEED_BASE, + &basic_setup, (void*)"" }, + { "bufferevent_connect_defer", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE, &basic_setup, (void*)"defer" }, + { "bufferevent_connect_lock", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_NEED_THREADS, &basic_setup, (void*)"lock" }, + { "bufferevent_connect_lock_defer", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_NEED_THREADS, &basic_setup, + (void*)"defer lock" }, + { "bufferevent_connect_unlocked_cbs", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_NEED_THREADS, &basic_setup, + (void*)"lock defer unlocked" }, + { "bufferevent_connect_fail", test_bufferevent_connect_fail, + TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + { "bufferevent_timeout", test_bufferevent_timeouts, + TT_FORK|TT_NEED_BASE|TT_NEED_SOCKETPAIR, &basic_setup, (void*)"" }, + { "bufferevent_timeout_pair", test_bufferevent_timeouts, + TT_FORK|TT_NEED_BASE, &basic_setup, (void*)"pair" }, + { "bufferevent_timeout_filter", test_bufferevent_timeouts, + TT_FORK|TT_NEED_BASE, &basic_setup, (void*)"filter" }, + { "bufferevent_timeout_filter_pair", test_bufferevent_timeouts, + TT_FORK|TT_NEED_BASE, &basic_setup, (void*)"filter pair" }, + { "bufferevent_trigger", test_bufferevent_trigger, TT_FORK|TT_NEED_BASE, + &basic_setup, (void*)"" }, + { "bufferevent_trigger_defer", test_bufferevent_trigger, + TT_FORK|TT_NEED_BASE, &basic_setup, (void*)"defer" }, + { "bufferevent_trigger_postpone", test_bufferevent_trigger, + TT_FORK|TT_NEED_BASE|TT_NEED_THREADS, &basic_setup, + (void*)"postpone" }, + { "bufferevent_trigger_defer_postpone", test_bufferevent_trigger, + TT_FORK|TT_NEED_BASE|TT_NEED_THREADS, &basic_setup, + (void*)"defer postpone" }, +#ifdef EVENT__HAVE_LIBZ + LEGACY(bufferevent_zlib, TT_ISOLATED), +#else + { "bufferevent_zlib", NULL, TT_SKIP, NULL, NULL }, +#endif + + END_OF_TESTCASES, +}; + +struct testcase_t bufferevent_iocp_testcases[] = { + + LEGACY(bufferevent, TT_ISOLATED|TT_ENABLE_IOCP), + LEGACY(bufferevent_watermarks, TT_ISOLATED|TT_ENABLE_IOCP), + LEGACY(bufferevent_filters, TT_ISOLATED|TT_ENABLE_IOCP), + { "bufferevent_connect", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_ENABLE_IOCP, &basic_setup, (void*)"" }, + { "bufferevent_connect_defer", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_ENABLE_IOCP, &basic_setup, (void*)"defer" }, + { "bufferevent_connect_lock", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_NEED_THREADS|TT_ENABLE_IOCP, &basic_setup, + (void*)"lock" }, + { "bufferevent_connect_lock_defer", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_NEED_THREADS|TT_ENABLE_IOCP, &basic_setup, + (void*)"defer lock" }, + { "bufferevent_connect_fail", test_bufferevent_connect_fail, + TT_FORK|TT_NEED_BASE|TT_ENABLE_IOCP, &basic_setup, NULL }, + { "bufferevent_connect_nonblocking", test_bufferevent_connect, + TT_FORK|TT_NEED_BASE|TT_ENABLE_IOCP, &basic_setup, + (void*)"unset_connectex" }, + + END_OF_TESTCASES, +}; diff --git a/contrib/ntp/sntp/libevent/test/regress_dns.c b/contrib/ntp/sntp/libevent/test/regress_dns.c new file mode 100644 index 000000000..31811407e --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress_dns.c @@ -0,0 +1,2050 @@ +/* + * Copyright (c) 2003-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "../util-internal.h" + +#ifdef _WIN32 +#include +#include +#include +#endif + +#include "event2/event-config.h" + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#ifndef _WIN32 +#include +#include +#include +#include +#include +#endif +#ifdef EVENT__HAVE_NETINET_IN6_H +#include +#endif +#ifdef HAVE_NETDB_H +#include +#endif +#include +#include +#include +#include +#include + +#include "event2/dns.h" +#include "event2/dns_compat.h" +#include "event2/dns_struct.h" +#include "event2/event.h" +#include "event2/event_compat.h" +#include "event2/event_struct.h" +#include "event2/util.h" +#include "event2/listener.h" +#include "event2/bufferevent.h" +#include "log-internal.h" +#include "regress.h" +#include "regress_testutils.h" + +static int dns_ok = 0; +static int dns_got_cancel = 0; +static int dns_err = 0; + + +static void +dns_gethostbyname_cb(int result, char type, int count, int ttl, + void *addresses, void *arg) +{ + dns_ok = dns_err = 0; + + if (result == DNS_ERR_TIMEOUT) { + printf("[Timed out] "); + dns_err = result; + goto out; + } + + if (result != DNS_ERR_NONE) { + printf("[Error code %d] ", result); + goto out; + } + + TT_BLATHER(("type: %d, count: %d, ttl: %d: ", type, count, ttl)); + + switch (type) { + case DNS_IPv6_AAAA: { +#if defined(EVENT__HAVE_STRUCT_IN6_ADDR) && defined(EVENT__HAVE_INET_NTOP) && defined(INET6_ADDRSTRLEN) + struct in6_addr *in6_addrs = addresses; + char buf[INET6_ADDRSTRLEN+1]; + int i; + /* a resolution that's not valid does not help */ + if (ttl < 0) + goto out; + for (i = 0; i < count; ++i) { + const char *b = evutil_inet_ntop(AF_INET6, &in6_addrs[i], buf,sizeof(buf)); + if (b) + TT_BLATHER(("%s ", b)); + else + TT_BLATHER(("%s ", strerror(errno))); + } +#endif + break; + } + case DNS_IPv4_A: { + struct in_addr *in_addrs = addresses; + int i; + /* a resolution that's not valid does not help */ + if (ttl < 0) + goto out; + for (i = 0; i < count; ++i) + TT_BLATHER(("%s ", inet_ntoa(in_addrs[i]))); + break; + } + case DNS_PTR: + /* may get at most one PTR */ + if (count != 1) + goto out; + + TT_BLATHER(("%s ", *(char **)addresses)); + break; + default: + goto out; + } + + dns_ok = type; + +out: + if (arg == NULL) + event_loopexit(NULL); + else + event_base_loopexit((struct event_base *)arg, NULL); +} + +static void +dns_gethostbyname(void) +{ + dns_ok = 0; + evdns_resolve_ipv4("www.monkey.org", 0, dns_gethostbyname_cb, NULL); + event_dispatch(); + + tt_int_op(dns_ok, ==, DNS_IPv4_A); + test_ok = dns_ok; +end: + ; +} + +static void +dns_gethostbyname6(void) +{ + dns_ok = 0; + evdns_resolve_ipv6("www.ietf.org", 0, dns_gethostbyname_cb, NULL); + event_dispatch(); + + if (!dns_ok && dns_err == DNS_ERR_TIMEOUT) { + tt_skip(); + } + + tt_int_op(dns_ok, ==, DNS_IPv6_AAAA); + test_ok = 1; +end: + ; +} + +static void +dns_gethostbyaddr(void) +{ + struct in_addr in; + in.s_addr = htonl(0x7f000001ul); /* 127.0.0.1 */ + dns_ok = 0; + evdns_resolve_reverse(&in, 0, dns_gethostbyname_cb, NULL); + event_dispatch(); + + tt_int_op(dns_ok, ==, DNS_PTR); + test_ok = dns_ok; +end: + ; +} + +static void +dns_resolve_reverse(void *ptr) +{ + struct in_addr in; + struct event_base *base = event_base_new(); + struct evdns_base *dns = evdns_base_new(base, 1/* init name servers */); + struct evdns_request *req = NULL; + + tt_assert(base); + tt_assert(dns); + in.s_addr = htonl(0x7f000001ul); /* 127.0.0.1 */ + dns_ok = 0; + + req = evdns_base_resolve_reverse( + dns, &in, 0, dns_gethostbyname_cb, base); + tt_assert(req); + + event_base_dispatch(base); + + tt_int_op(dns_ok, ==, DNS_PTR); + +end: + if (dns) + evdns_base_free(dns, 0); + if (base) + event_base_free(base); +} + +static int n_server_responses = 0; + +static void +dns_server_request_cb(struct evdns_server_request *req, void *data) +{ + int i, r; + const char TEST_ARPA[] = "11.11.168.192.in-addr.arpa"; + const char TEST_IN6[] = + "f.e.f.e." "0.0.0.0." "0.0.0.0." "1.1.1.1." + "a.a.a.a." "0.0.0.0." "0.0.0.0." "0.f.f.f.ip6.arpa"; + + for (i = 0; i < req->nquestions; ++i) { + const int qtype = req->questions[i]->type; + const int qclass = req->questions[i]->dns_question_class; + const char *qname = req->questions[i]->name; + + struct in_addr ans; + ans.s_addr = htonl(0xc0a80b0bUL); /* 192.168.11.11 */ + if (qtype == EVDNS_TYPE_A && + qclass == EVDNS_CLASS_INET && + !evutil_ascii_strcasecmp(qname, "zz.example.com")) { + r = evdns_server_request_add_a_reply(req, qname, + 1, &ans.s_addr, 12345); + if (r<0) + dns_ok = 0; + } else if (qtype == EVDNS_TYPE_AAAA && + qclass == EVDNS_CLASS_INET && + !evutil_ascii_strcasecmp(qname, "zz.example.com")) { + char addr6[17] = "abcdefghijklmnop"; + r = evdns_server_request_add_aaaa_reply(req, + qname, 1, addr6, 123); + if (r<0) + dns_ok = 0; + } else if (qtype == EVDNS_TYPE_PTR && + qclass == EVDNS_CLASS_INET && + !evutil_ascii_strcasecmp(qname, TEST_ARPA)) { + r = evdns_server_request_add_ptr_reply(req, NULL, + qname, "ZZ.EXAMPLE.COM", 54321); + if (r<0) + dns_ok = 0; + } else if (qtype == EVDNS_TYPE_PTR && + qclass == EVDNS_CLASS_INET && + !evutil_ascii_strcasecmp(qname, TEST_IN6)){ + r = evdns_server_request_add_ptr_reply(req, NULL, + qname, + "ZZ-INET6.EXAMPLE.COM", 54322); + if (r<0) + dns_ok = 0; + } else if (qtype == EVDNS_TYPE_A && + qclass == EVDNS_CLASS_INET && + !evutil_ascii_strcasecmp(qname, "drop.example.com")) { + if (evdns_server_request_drop(req)<0) + dns_ok = 0; + return; + } else { + printf("Unexpected question %d %d \"%s\" ", + qtype, qclass, qname); + dns_ok = 0; + } + } + r = evdns_server_request_respond(req, 0); + if (r<0) { + printf("Couldn't send reply. "); + dns_ok = 0; + } +} + +static void +dns_server_gethostbyname_cb(int result, char type, int count, int ttl, + void *addresses, void *arg) +{ + if (result == DNS_ERR_CANCEL) { + if (arg != (void*)(char*)90909) { + printf("Unexpected cancelation"); + dns_ok = 0; + } + dns_got_cancel = 1; + goto out; + } + if (result != DNS_ERR_NONE) { + printf("Unexpected result %d. ", result); + dns_ok = 0; + goto out; + } + if (count != 1) { + printf("Unexpected answer count %d. ", count); + dns_ok = 0; + goto out; + } + switch (type) { + case DNS_IPv4_A: { + struct in_addr *in_addrs = addresses; + if (in_addrs[0].s_addr != htonl(0xc0a80b0bUL) || ttl != 12345) { + printf("Bad IPv4 response \"%s\" %d. ", + inet_ntoa(in_addrs[0]), ttl); + dns_ok = 0; + goto out; + } + break; + } + case DNS_IPv6_AAAA: { +#if defined (EVENT__HAVE_STRUCT_IN6_ADDR) && defined(EVENT__HAVE_INET_NTOP) && defined(INET6_ADDRSTRLEN) + struct in6_addr *in6_addrs = addresses; + char buf[INET6_ADDRSTRLEN+1]; + if (memcmp(&in6_addrs[0].s6_addr, "abcdefghijklmnop", 16) + || ttl != 123) { + const char *b = evutil_inet_ntop(AF_INET6, &in6_addrs[0],buf,sizeof(buf)); + printf("Bad IPv6 response \"%s\" %d. ", b, ttl); + dns_ok = 0; + goto out; + } +#endif + break; + } + case DNS_PTR: { + char **addrs = addresses; + if (arg != (void*)6) { + if (strcmp(addrs[0], "ZZ.EXAMPLE.COM") || + ttl != 54321) { + printf("Bad PTR response \"%s\" %d. ", + addrs[0], ttl); + dns_ok = 0; + goto out; + } + } else { + if (strcmp(addrs[0], "ZZ-INET6.EXAMPLE.COM") || + ttl != 54322) { + printf("Bad ipv6 PTR response \"%s\" %d. ", + addrs[0], ttl); + dns_ok = 0; + goto out; + } + } + break; + } + default: + printf("Bad response type %d. ", type); + dns_ok = 0; + } + out: + if (++n_server_responses == 3) { + event_loopexit(NULL); + } +} + +static void +dns_server(void) +{ + evutil_socket_t sock=-1; + struct sockaddr_in my_addr; + struct sockaddr_storage ss; + ev_socklen_t slen; + struct evdns_server_port *port=NULL; + struct in_addr resolve_addr; + struct in6_addr resolve_addr6; + struct evdns_base *base=NULL; + struct evdns_request *req=NULL; + + dns_ok = 1; + + base = evdns_base_new(NULL, 0); + + /* Now configure a nameserver port. */ + sock = socket(AF_INET, SOCK_DGRAM, 0); + if (sock<0) { + tt_abort_perror("socket"); + } + + evutil_make_socket_nonblocking(sock); + + memset(&my_addr, 0, sizeof(my_addr)); + my_addr.sin_family = AF_INET; + my_addr.sin_port = 0; /* kernel picks */ + my_addr.sin_addr.s_addr = htonl(0x7f000001UL); + if (bind(sock, (struct sockaddr*)&my_addr, sizeof(my_addr)) < 0) { + tt_abort_perror("bind"); + } + slen = sizeof(ss); + if (getsockname(sock, (struct sockaddr*)&ss, &slen) < 0) { + tt_abort_perror("getsockname"); + } + + port = evdns_add_server_port(sock, 0, dns_server_request_cb, NULL); + + /* Add ourself as the only nameserver, and make sure we really are + * the only nameserver. */ + evdns_base_nameserver_sockaddr_add(base, (struct sockaddr*)&ss, slen, 0); + tt_int_op(evdns_base_count_nameservers(base), ==, 1); + { + struct sockaddr_storage ss2; + int slen2; + + memset(&ss2, 0, sizeof(ss2)); + + slen2 = evdns_base_get_nameserver_addr(base, 0, (struct sockaddr *)&ss2, 3); + tt_int_op(slen2, ==, slen); + tt_int_op(ss2.ss_family, ==, 0); + slen2 = evdns_base_get_nameserver_addr(base, 0, (struct sockaddr *)&ss2, sizeof(ss2)); + tt_int_op(slen2, ==, slen); + tt_mem_op(&ss2, ==, &ss, slen); + + slen2 = evdns_base_get_nameserver_addr(base, 1, (struct sockaddr *)&ss2, sizeof(ss2)); + tt_int_op(-1, ==, slen2); + } + + /* Send some queries. */ + evdns_base_resolve_ipv4(base, "zz.example.com", DNS_QUERY_NO_SEARCH, + dns_server_gethostbyname_cb, NULL); + evdns_base_resolve_ipv6(base, "zz.example.com", DNS_QUERY_NO_SEARCH, + dns_server_gethostbyname_cb, NULL); + resolve_addr.s_addr = htonl(0xc0a80b0bUL); /* 192.168.11.11 */ + evdns_base_resolve_reverse(base, &resolve_addr, 0, + dns_server_gethostbyname_cb, NULL); + memcpy(resolve_addr6.s6_addr, + "\xff\xf0\x00\x00\x00\x00\xaa\xaa" + "\x11\x11\x00\x00\x00\x00\xef\xef", 16); + evdns_base_resolve_reverse_ipv6(base, &resolve_addr6, 0, + dns_server_gethostbyname_cb, (void*)6); + + req = evdns_base_resolve_ipv4(base, + "drop.example.com", DNS_QUERY_NO_SEARCH, + dns_server_gethostbyname_cb, (void*)(char*)90909); + + evdns_cancel_request(base, req); + + event_dispatch(); + + tt_assert(dns_got_cancel); + test_ok = dns_ok; + +end: + if (port) + evdns_close_server_port(port); + if (sock >= 0) + evutil_closesocket(sock); + if (base) + evdns_base_free(base, 0); +} + +static int n_replies_left; +static struct event_base *exit_base; +static struct evdns_server_port *exit_port; + +struct generic_dns_callback_result { + int result; + char type; + int count; + int ttl; + size_t addrs_len; + void *addrs; + char addrs_buf[256]; +}; + +static void +generic_dns_callback(int result, char type, int count, int ttl, void *addresses, + void *arg) +{ + size_t len; + struct generic_dns_callback_result *res = arg; + res->result = result; + res->type = type; + res->count = count; + res->ttl = ttl; + + if (type == DNS_IPv4_A) + len = count * 4; + else if (type == DNS_IPv6_AAAA) + len = count * 16; + else if (type == DNS_PTR) + len = strlen(addresses)+1; + else { + res->addrs_len = len = 0; + res->addrs = NULL; + } + if (len) { + res->addrs_len = len; + if (len > 256) + len = 256; + memcpy(res->addrs_buf, addresses, len); + res->addrs = res->addrs_buf; + } + + --n_replies_left; + if (n_replies_left == 0) { + if (exit_port) { + evdns_close_server_port(exit_port); + exit_port = NULL; + } else + event_base_loopexit(exit_base, NULL); + } +} + +static struct regress_dns_server_table search_table[] = { + { "host.a.example.com", "err", "3", 0 }, + { "host.b.example.com", "err", "3", 0 }, + { "host.c.example.com", "A", "11.22.33.44", 0 }, + { "host2.a.example.com", "err", "3", 0 }, + { "host2.b.example.com", "A", "200.100.0.100", 0 }, + { "host2.c.example.com", "err", "3", 0 }, + { "hostn.a.example.com", "errsoa", "0", 0 }, + { "hostn.b.example.com", "errsoa", "3", 0 }, + { "hostn.c.example.com", "err", "0", 0 }, + + { "host", "err", "3", 0 }, + { "host2", "err", "3", 0 }, + { "*", "err", "3", 0 }, + { NULL, NULL, NULL, 0 } +}; + +static void +dns_search_test(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct evdns_base *dns = NULL; + ev_uint16_t portnum = 0; + char buf[64]; + + struct generic_dns_callback_result r[8]; + + tt_assert(regress_dnsserver(base, &portnum, search_table)); + evutil_snprintf(buf, sizeof(buf), "127.0.0.1:%d", (int)portnum); + + dns = evdns_base_new(base, 0); + tt_assert(!evdns_base_nameserver_ip_add(dns, buf)); + + evdns_base_search_add(dns, "a.example.com"); + evdns_base_search_add(dns, "b.example.com"); + evdns_base_search_add(dns, "c.example.com"); + + n_replies_left = sizeof(r)/sizeof(r[0]); + exit_base = base; + + evdns_base_resolve_ipv4(dns, "host", 0, generic_dns_callback, &r[0]); + evdns_base_resolve_ipv4(dns, "host2", 0, generic_dns_callback, &r[1]); + evdns_base_resolve_ipv4(dns, "host", DNS_NO_SEARCH, generic_dns_callback, &r[2]); + evdns_base_resolve_ipv4(dns, "host2", DNS_NO_SEARCH, generic_dns_callback, &r[3]); + evdns_base_resolve_ipv4(dns, "host3", 0, generic_dns_callback, &r[4]); + evdns_base_resolve_ipv4(dns, "hostn.a.example.com", DNS_NO_SEARCH, generic_dns_callback, &r[5]); + evdns_base_resolve_ipv4(dns, "hostn.b.example.com", DNS_NO_SEARCH, generic_dns_callback, &r[6]); + evdns_base_resolve_ipv4(dns, "hostn.c.example.com", DNS_NO_SEARCH, generic_dns_callback, &r[7]); + + event_base_dispatch(base); + + tt_int_op(r[0].type, ==, DNS_IPv4_A); + tt_int_op(r[0].count, ==, 1); + tt_int_op(((ev_uint32_t*)r[0].addrs)[0], ==, htonl(0x0b16212c)); + tt_int_op(r[1].type, ==, DNS_IPv4_A); + tt_int_op(r[1].count, ==, 1); + tt_int_op(((ev_uint32_t*)r[1].addrs)[0], ==, htonl(0xc8640064)); + tt_int_op(r[2].result, ==, DNS_ERR_NOTEXIST); + tt_int_op(r[3].result, ==, DNS_ERR_NOTEXIST); + tt_int_op(r[4].result, ==, DNS_ERR_NOTEXIST); + tt_int_op(r[5].result, ==, DNS_ERR_NODATA); + tt_int_op(r[5].ttl, ==, 42); + tt_int_op(r[6].result, ==, DNS_ERR_NOTEXIST); + tt_int_op(r[6].ttl, ==, 42); + tt_int_op(r[7].result, ==, DNS_ERR_NODATA); + tt_int_op(r[7].ttl, ==, 0); + +end: + if (dns) + evdns_base_free(dns, 0); + + regress_clean_dnsserver(); +} + +static int request_count = 0; +static struct evdns_request *current_req = NULL; + +static void +search_cancel_server_cb(struct evdns_server_request *req, void *data) +{ + const char *question; + + if (req->nquestions != 1) + TT_DIE(("Only handling one question at a time; got %d", + req->nquestions)); + + question = req->questions[0]->name; + + TT_BLATHER(("got question, %s", question)); + + tt_assert(request_count > 0); + tt_assert(!evdns_server_request_respond(req, 3)); + + if (!--request_count) + evdns_cancel_request(NULL, current_req); + +end: + ; +} + +static void +dns_search_cancel_test(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct evdns_base *dns = NULL; + struct evdns_server_port *port = NULL; + ev_uint16_t portnum = 0; + struct generic_dns_callback_result r1; + char buf[64]; + + port = regress_get_dnsserver(base, &portnum, NULL, + search_cancel_server_cb, NULL); + tt_assert(port); + evutil_snprintf(buf, sizeof(buf), "127.0.0.1:%d", (int)portnum); + + dns = evdns_base_new(base, 0); + tt_assert(!evdns_base_nameserver_ip_add(dns, buf)); + + evdns_base_search_add(dns, "a.example.com"); + evdns_base_search_add(dns, "b.example.com"); + evdns_base_search_add(dns, "c.example.com"); + evdns_base_search_add(dns, "d.example.com"); + + exit_base = base; + request_count = 3; + n_replies_left = 1; + + current_req = evdns_base_resolve_ipv4(dns, "host", 0, + generic_dns_callback, &r1); + event_base_dispatch(base); + + tt_int_op(r1.result, ==, DNS_ERR_CANCEL); + +end: + if (port) + evdns_close_server_port(port); + if (dns) + evdns_base_free(dns, 0); +} + +static void +fail_server_cb(struct evdns_server_request *req, void *data) +{ + const char *question; + int *count = data; + struct in_addr in; + + /* Drop the first N requests that we get. */ + if (*count > 0) { + --*count; + tt_want(! evdns_server_request_drop(req)); + return; + } + + if (req->nquestions != 1) + TT_DIE(("Only handling one question at a time; got %d", + req->nquestions)); + + question = req->questions[0]->name; + + if (!evutil_ascii_strcasecmp(question, "google.com")) { + /* Detect a probe, and get out of the loop. */ + event_base_loopexit(exit_base, NULL); + } + + tt_assert(evutil_inet_pton(AF_INET, "16.32.64.128", &in)); + evdns_server_request_add_a_reply(req, question, 1, &in.s_addr, + 100); + tt_assert(! evdns_server_request_respond(req, 0)) + return; +end: + tt_want(! evdns_server_request_drop(req)); +} + +static void +dns_retry_test_impl(void *arg, int flags) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct evdns_server_port *port = NULL; + struct evdns_base *dns = NULL; + int drop_count = 2; + ev_uint16_t portnum = 0; + char buf[64]; + + struct generic_dns_callback_result r1; + + port = regress_get_dnsserver(base, &portnum, NULL, + fail_server_cb, &drop_count); + tt_assert(port); + evutil_snprintf(buf, sizeof(buf), "127.0.0.1:%d", (int)portnum); + + dns = evdns_base_new(base, flags); + tt_assert(!evdns_base_nameserver_ip_add(dns, buf)); + tt_assert(! evdns_base_set_option(dns, "timeout", "0.2")); + tt_assert(! evdns_base_set_option(dns, "max-timeouts:", "10")); + tt_assert(! evdns_base_set_option(dns, "initial-probe-timeout", "0.1")); + + evdns_base_resolve_ipv4(dns, "host.example.com", 0, + generic_dns_callback, &r1); + + n_replies_left = 1; + exit_base = base; + + event_base_dispatch(base); + + tt_int_op(drop_count, ==, 0); + + tt_int_op(r1.type, ==, DNS_IPv4_A); + tt_int_op(r1.count, ==, 1); + tt_int_op(((ev_uint32_t*)r1.addrs)[0], ==, htonl(0x10204080)); + + /* Now try again, but this time have the server get treated as + * failed, so we can send it a test probe. */ + drop_count = 4; + tt_assert(! evdns_base_set_option(dns, "max-timeouts:", "2")); + tt_assert(! evdns_base_set_option(dns, "attempts:", "3")); + memset(&r1, 0, sizeof(r1)); + + evdns_base_resolve_ipv4(dns, "host.example.com", 0, + generic_dns_callback, &r1); + + n_replies_left = 2; + + /* This will run until it answers the "google.com" probe request. */ + event_base_dispatch(base); + + /* We'll treat the server as failed here. */ + tt_int_op(r1.result, ==, DNS_ERR_TIMEOUT); + + /* It should work this time. */ + tt_int_op(drop_count, ==, 0); + evdns_base_resolve_ipv4(dns, "host.example.com", 0, + generic_dns_callback, &r1); + + event_base_dispatch(base); + tt_int_op(r1.result, ==, DNS_ERR_NONE); + tt_int_op(r1.type, ==, DNS_IPv4_A); + tt_int_op(r1.count, ==, 1); + tt_int_op(((ev_uint32_t*)r1.addrs)[0], ==, htonl(0x10204080)); + +end: + if (dns) + evdns_base_free(dns, 0); + if (port) + evdns_close_server_port(port); +} +static void +dns_retry_test(void *arg) +{ + dns_retry_test_impl(arg, 0); +} +static void +dns_retry_disable_when_inactive_test(void *arg) +{ + dns_retry_test_impl(arg, EVDNS_BASE_DISABLE_WHEN_INACTIVE); +} + +static struct regress_dns_server_table internal_error_table[] = { + /* Error 4 (NOTIMPL) makes us reissue the request to another server + if we can. + + XXXX we should reissue under a much wider set of circumstances! + */ + { "foof.example.com", "err", "4", 0 }, + { NULL, NULL, NULL, 0 } +}; + +static struct regress_dns_server_table reissue_table[] = { + { "foof.example.com", "A", "240.15.240.15", 0 }, + { NULL, NULL, NULL, 0 } +}; + +static void +dns_reissue_test_impl(void *arg, int flags) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + struct evdns_server_port *port1 = NULL, *port2 = NULL; + struct evdns_base *dns = NULL; + struct generic_dns_callback_result r1; + ev_uint16_t portnum1 = 0, portnum2=0; + char buf1[64], buf2[64]; + + port1 = regress_get_dnsserver(base, &portnum1, NULL, + regress_dns_server_cb, internal_error_table); + tt_assert(port1); + port2 = regress_get_dnsserver(base, &portnum2, NULL, + regress_dns_server_cb, reissue_table); + tt_assert(port2); + evutil_snprintf(buf1, sizeof(buf1), "127.0.0.1:%d", (int)portnum1); + evutil_snprintf(buf2, sizeof(buf2), "127.0.0.1:%d", (int)portnum2); + + dns = evdns_base_new(base, flags); + tt_assert(!evdns_base_nameserver_ip_add(dns, buf1)); + tt_assert(! evdns_base_set_option(dns, "timeout:", "0.3")); + tt_assert(! evdns_base_set_option(dns, "max-timeouts:", "2")); + tt_assert(! evdns_base_set_option(dns, "attempts:", "5")); + + memset(&r1, 0, sizeof(r1)); + evdns_base_resolve_ipv4(dns, "foof.example.com", 0, + generic_dns_callback, &r1); + + /* Add this after, so that we are sure to get a reissue. */ + tt_assert(!evdns_base_nameserver_ip_add(dns, buf2)); + + n_replies_left = 1; + exit_base = base; + + event_base_dispatch(base); + tt_int_op(r1.result, ==, DNS_ERR_NONE); + tt_int_op(r1.type, ==, DNS_IPv4_A); + tt_int_op(r1.count, ==, 1); + tt_int_op(((ev_uint32_t*)r1.addrs)[0], ==, htonl(0xf00ff00f)); + + /* Make sure we dropped at least once. */ + tt_int_op(internal_error_table[0].seen, >, 0); + +end: + if (dns) + evdns_base_free(dns, 0); + if (port1) + evdns_close_server_port(port1); + if (port2) + evdns_close_server_port(port2); +} +static void +dns_reissue_test(void *arg) +{ + dns_reissue_test_impl(arg, 0); +} +static void +dns_reissue_disable_when_inactive_test(void *arg) +{ + dns_reissue_test_impl(arg, EVDNS_BASE_DISABLE_WHEN_INACTIVE); +} + +#if 0 +static void +dumb_bytes_fn(char *p, size_t n) +{ + unsigned i; + /* This gets us 6 bits of entropy per transaction ID, which means we + * will have probably have collisions and need to pick again. */ + for (i=0;ibase; + struct evdns_base *dns = NULL; + struct evdns_server_port *dns_port = NULL; + ev_uint16_t portnum = 0; + char buf[64]; + int disable_when_inactive = flags & EVDNS_BASE_DISABLE_WHEN_INACTIVE; + + struct generic_dns_callback_result r[20]; + int i; + + dns_port = regress_get_dnsserver(base, &portnum, NULL, + regress_dns_server_cb, reissue_table); + tt_assert(dns_port); + if (disable_when_inactive) { + exit_port = dns_port; + } + + evutil_snprintf(buf, sizeof(buf), "127.0.0.1:%d", (int)portnum); + + dns = evdns_base_new(base, flags); + tt_assert(!evdns_base_nameserver_ip_add(dns, buf)); + tt_assert(! evdns_base_set_option(dns, "max-inflight:", "3")); + tt_assert(! evdns_base_set_option(dns, "randomize-case:", "0")); + + for (i=0;i<20;++i) + evdns_base_resolve_ipv4(dns, "foof.example.com", 0, generic_dns_callback, &r[i]); + + n_replies_left = 20; + exit_base = base; + + event_base_dispatch(base); + + for (i=0;i<20;++i) { + tt_int_op(r[i].type, ==, DNS_IPv4_A); + tt_int_op(r[i].count, ==, 1); + tt_int_op(((ev_uint32_t*)r[i].addrs)[0], ==, htonl(0xf00ff00f)); + } + +end: + if (dns) + evdns_base_free(dns, 0); + if (exit_port) { + evdns_close_server_port(exit_port); + exit_port = NULL; + } else if (! disable_when_inactive) { + evdns_close_server_port(dns_port); + } +} + +static void +dns_inflight_test(void *arg) +{ + dns_inflight_test_impl(arg, 0); +} + +static void +dns_disable_when_inactive_test(void *arg) +{ + dns_inflight_test_impl(arg, EVDNS_BASE_DISABLE_WHEN_INACTIVE); +} + +static void +dns_disable_when_inactive_no_ns_test(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base, *inactive_base; + struct evdns_base *dns = NULL; + ev_uint16_t portnum = 0; + char buf[64]; + struct generic_dns_callback_result r; + + inactive_base = event_base_new(); + tt_assert(inactive_base); + + /** Create dns server with inactive base, to avoid replying to clients */ + tt_assert(regress_dnsserver(inactive_base, &portnum, search_table)); + evutil_snprintf(buf, sizeof(buf), "127.0.0.1:%d", (int)portnum); + + dns = evdns_base_new(base, EVDNS_BASE_DISABLE_WHEN_INACTIVE); + tt_assert(!evdns_base_nameserver_ip_add(dns, buf)); + tt_assert(! evdns_base_set_option(dns, "timeout:", "0.1")); + + evdns_base_resolve_ipv4(dns, "foof.example.com", 0, generic_dns_callback, &r); + n_replies_left = 1; + exit_base = base; + + event_base_dispatch(base); + + tt_int_op(n_replies_left, ==, 0); + + tt_int_op(r.result, ==, DNS_ERR_TIMEOUT); + tt_int_op(r.count, ==, 0); + tt_ptr_op(r.addrs, ==, NULL); + +end: + if (dns) + evdns_base_free(dns, 0); + regress_clean_dnsserver(); + if (inactive_base) + event_base_free(inactive_base); +} + +/* === Test for bufferevent_socket_connect_hostname */ + +static int total_connected_or_failed = 0; +static int total_n_accepted = 0; +static struct event_base *be_connect_hostname_base = NULL; + +/* Implements a DNS server for the connect_hostname test and the + * getaddrinfo_async test */ +static void +be_getaddrinfo_server_cb(struct evdns_server_request *req, void *data) +{ + int i; + int *n_got_p=data; + int added_any=0; + ++*n_got_p; + + for (i=0;inquestions;++i) { + const int qtype = req->questions[i]->type; + const int qclass = req->questions[i]->dns_question_class; + const char *qname = req->questions[i]->name; + struct in_addr ans; + struct in6_addr ans6; + memset(&ans6, 0, sizeof(ans6)); + + TT_BLATHER(("Got question about %s, type=%d", qname, qtype)); + + if (qtype == EVDNS_TYPE_A && + qclass == EVDNS_CLASS_INET && + !evutil_ascii_strcasecmp(qname, "nobodaddy.example.com")) { + ans.s_addr = htonl(0x7f000001); + evdns_server_request_add_a_reply(req, qname, + 1, &ans.s_addr, 2000); + added_any = 1; + } else if (!evutil_ascii_strcasecmp(qname, + "nosuchplace.example.com")) { + /* ok, just say notfound. */ + } else if (!evutil_ascii_strcasecmp(qname, + "both.example.com")) { + if (qtype == EVDNS_TYPE_A) { + ans.s_addr = htonl(0x50502020); + evdns_server_request_add_a_reply(req, qname, + 1, &ans.s_addr, 2000); + added_any = 1; + } else if (qtype == EVDNS_TYPE_AAAA) { + ans6.s6_addr[0] = 0x80; + ans6.s6_addr[1] = 0xff; + ans6.s6_addr[14] = 0xbb; + ans6.s6_addr[15] = 0xbb; + evdns_server_request_add_aaaa_reply(req, qname, + 1, &ans6.s6_addr, 2000); + added_any = 1; + } + evdns_server_request_add_cname_reply(req, qname, + "both-canonical.example.com", 1000); + } else if (!evutil_ascii_strcasecmp(qname, + "v4only.example.com") || + !evutil_ascii_strcasecmp(qname, "v4assert.example.com")) { + if (qtype == EVDNS_TYPE_A) { + ans.s_addr = htonl(0x12345678); + evdns_server_request_add_a_reply(req, qname, + 1, &ans.s_addr, 2000); + added_any = 1; + } else if (!evutil_ascii_strcasecmp(qname, + "v4assert.example.com")) { + TT_FAIL(("Got an AAAA request for v4assert")); + } + } else if (!evutil_ascii_strcasecmp(qname, + "v6only.example.com") || + !evutil_ascii_strcasecmp(qname, "v6assert.example.com")) { + if (qtype == EVDNS_TYPE_AAAA) { + ans6.s6_addr[0] = 0x0b; + ans6.s6_addr[1] = 0x0b; + ans6.s6_addr[14] = 0xf0; + ans6.s6_addr[15] = 0x0d; + evdns_server_request_add_aaaa_reply(req, qname, + 1, &ans6.s6_addr, 2000); + added_any = 1; + } else if (!evutil_ascii_strcasecmp(qname, + "v6assert.example.com")) { + TT_FAIL(("Got a A request for v6assert")); + } + } else if (!evutil_ascii_strcasecmp(qname, + "v6timeout.example.com")) { + if (qtype == EVDNS_TYPE_A) { + ans.s_addr = htonl(0xabcdef01); + evdns_server_request_add_a_reply(req, qname, + 1, &ans.s_addr, 2000); + added_any = 1; + } else if (qtype == EVDNS_TYPE_AAAA) { + /* Let the v6 request time out.*/ + evdns_server_request_drop(req); + return; + } + } else if (!evutil_ascii_strcasecmp(qname, + "v4timeout.example.com")) { + if (qtype == EVDNS_TYPE_AAAA) { + ans6.s6_addr[0] = 0x0a; + ans6.s6_addr[1] = 0x0a; + ans6.s6_addr[14] = 0xff; + ans6.s6_addr[15] = 0x01; + evdns_server_request_add_aaaa_reply(req, qname, + 1, &ans6.s6_addr, 2000); + added_any = 1; + } else if (qtype == EVDNS_TYPE_A) { + /* Let the v4 request time out.*/ + evdns_server_request_drop(req); + return; + } + } else if (!evutil_ascii_strcasecmp(qname, + "v6timeout-nonexist.example.com")) { + if (qtype == EVDNS_TYPE_A) { + /* Fall through, give an nexist. */ + } else if (qtype == EVDNS_TYPE_AAAA) { + /* Let the v6 request time out.*/ + evdns_server_request_drop(req); + return; + } + } else if (!evutil_ascii_strcasecmp(qname, + "all-timeout.example.com")) { + /* drop all requests */ + evdns_server_request_drop(req); + return; + } else { + TT_GRIPE(("Got weird request for %s",qname)); + } + } + if (added_any) { + TT_BLATHER(("answering")); + evdns_server_request_respond(req, 0); + } else { + TT_BLATHER(("saying nexist.")); + evdns_server_request_respond(req, 3); + } +} + +/* Implements a listener for connect_hostname test. */ +static void +nil_accept_cb(struct evconnlistener *l, evutil_socket_t fd, struct sockaddr *s, + int socklen, void *arg) +{ + int *p = arg; + (*p)++; + ++total_n_accepted; + /* don't do anything with the socket; let it close when we exit() */ + if (total_n_accepted >= 3 && total_connected_or_failed >= 5) + event_base_loopexit(be_connect_hostname_base, + NULL); +} + +struct be_conn_hostname_result { + int dnserr; + int what; +}; + +/* Bufferevent event callback for the connect_hostname test: remembers what + * event we got. */ +static void +be_connect_hostname_event_cb(struct bufferevent *bev, short what, void *ctx) +{ + struct be_conn_hostname_result *got = ctx; + if (!got->what) { + TT_BLATHER(("Got a bufferevent event %d", what)); + got->what = what; + + if ((what & BEV_EVENT_CONNECTED) || (what & BEV_EVENT_ERROR)) { + int r; + if ((r = bufferevent_socket_get_dns_error(bev))) { + got->dnserr = r; + TT_BLATHER(("DNS error %d: %s", r, + evutil_gai_strerror(r))); + } ++total_connected_or_failed; + TT_BLATHER(("Got %d connections or errors.", total_connected_or_failed)); + + if (total_n_accepted >= 3 && total_connected_or_failed >= 5) + event_base_loopexit(be_connect_hostname_base, + NULL); + } + } else { + TT_FAIL(("Two events on one bufferevent. %d,%d", + got->what, (int)what)); + } +} + +static void +test_bufferevent_connect_hostname(void *arg) +{ + struct basic_test_data *data = arg; + struct evconnlistener *listener = NULL; + struct bufferevent *be1=NULL, *be2=NULL, *be3=NULL, *be4=NULL, *be5=NULL; + struct be_conn_hostname_result be1_outcome={0,0}, be2_outcome={0,0}, + be3_outcome={0,0}, be4_outcome={0,0}, be5_outcome={0,0}; + int expect_err5; + struct evdns_base *dns=NULL; + struct evdns_server_port *port=NULL; + struct sockaddr_in sin; + int listener_port=-1; + ev_uint16_t dns_port=0; + int n_accept=0, n_dns=0; + char buf[128]; + + be_connect_hostname_base = data->base; + + /* Bind an address and figure out what port it's on. */ + memset(&sin, 0, sizeof(sin)); + sin.sin_family = AF_INET; + sin.sin_addr.s_addr = htonl(0x7f000001); /* 127.0.0.1 */ + sin.sin_port = 0; + listener = evconnlistener_new_bind(data->base, nil_accept_cb, + &n_accept, + LEV_OPT_REUSEABLE|LEV_OPT_CLOSE_ON_EXEC, + -1, (struct sockaddr *)&sin, sizeof(sin)); + tt_assert(listener); + listener_port = regress_get_socket_port( + evconnlistener_get_fd(listener)); + + port = regress_get_dnsserver(data->base, &dns_port, NULL, + be_getaddrinfo_server_cb, &n_dns); + tt_assert(port); + tt_int_op(dns_port, >=, 0); + + /* Start an evdns_base that uses the server as its resolver. */ + dns = evdns_base_new(data->base, 0); + evutil_snprintf(buf, sizeof(buf), "127.0.0.1:%d", (int)dns_port); + evdns_base_nameserver_ip_add(dns, buf); + + /* Now, finally, at long last, launch the bufferevents. One should do + * a failing lookup IP, one should do a successful lookup by IP, + * and one should do a successful lookup by hostname. */ + be1 = bufferevent_socket_new(data->base, -1, BEV_OPT_CLOSE_ON_FREE); + be2 = bufferevent_socket_new(data->base, -1, BEV_OPT_CLOSE_ON_FREE); + be3 = bufferevent_socket_new(data->base, -1, BEV_OPT_CLOSE_ON_FREE); + be4 = bufferevent_socket_new(data->base, -1, BEV_OPT_CLOSE_ON_FREE); + be5 = bufferevent_socket_new(data->base, -1, BEV_OPT_CLOSE_ON_FREE); + + bufferevent_setcb(be1, NULL, NULL, be_connect_hostname_event_cb, + &be1_outcome); + bufferevent_setcb(be2, NULL, NULL, be_connect_hostname_event_cb, + &be2_outcome); + bufferevent_setcb(be3, NULL, NULL, be_connect_hostname_event_cb, + &be3_outcome); + bufferevent_setcb(be4, NULL, NULL, be_connect_hostname_event_cb, + &be4_outcome); + bufferevent_setcb(be5, NULL, NULL, be_connect_hostname_event_cb, + &be5_outcome); + + /* Launch an async resolve that will fail. */ + tt_assert(!bufferevent_socket_connect_hostname(be1, dns, AF_INET, + "nosuchplace.example.com", listener_port)); + /* Connect to the IP without resolving. */ + tt_assert(!bufferevent_socket_connect_hostname(be2, dns, AF_INET, + "127.0.0.1", listener_port)); + /* Launch an async resolve that will succeed. */ + tt_assert(!bufferevent_socket_connect_hostname(be3, dns, AF_INET, + "nobodaddy.example.com", listener_port)); + /* Use the blocking resolver. This one will fail if your resolver + * can't resolve localhost to 127.0.0.1 */ + tt_assert(!bufferevent_socket_connect_hostname(be4, NULL, AF_INET, + "localhost", listener_port)); + /* Use the blocking resolver with a nonexistent hostname. */ + tt_assert(!bufferevent_socket_connect_hostname(be5, NULL, AF_INET, + "nonesuch.nowhere.example.com", 80)); + { + /* The blocking resolver will use the system nameserver, which + * might tell us anything. (Yes, some twits even pretend that + * example.com is real.) Let's see what answer to expect. */ + struct evutil_addrinfo hints, *ai = NULL; + memset(&hints, 0, sizeof(hints)); + hints.ai_family = AF_INET; + hints.ai_socktype = SOCK_STREAM; + hints.ai_protocol = IPPROTO_TCP; + expect_err5 = evutil_getaddrinfo( + "nonesuch.nowhere.example.com", "80", &hints, &ai); + } + + event_base_dispatch(data->base); + + tt_int_op(be1_outcome.what, ==, BEV_EVENT_ERROR); + tt_int_op(be1_outcome.dnserr, ==, EVUTIL_EAI_NONAME); + tt_int_op(be2_outcome.what, ==, BEV_EVENT_CONNECTED); + tt_int_op(be2_outcome.dnserr, ==, 0); + tt_int_op(be3_outcome.what, ==, BEV_EVENT_CONNECTED); + tt_int_op(be3_outcome.dnserr, ==, 0); + tt_int_op(be4_outcome.what, ==, BEV_EVENT_CONNECTED); + tt_int_op(be4_outcome.dnserr, ==, 0); + if (expect_err5) { + tt_int_op(be5_outcome.what, ==, BEV_EVENT_ERROR); + tt_int_op(be5_outcome.dnserr, ==, expect_err5); + } + + tt_int_op(n_accept, ==, 3); + tt_int_op(n_dns, ==, 2); + +end: + if (listener) + evconnlistener_free(listener); + if (port) + evdns_close_server_port(port); + if (dns) + evdns_base_free(dns, 0); + if (be1) + bufferevent_free(be1); + if (be2) + bufferevent_free(be2); + if (be3) + bufferevent_free(be3); + if (be4) + bufferevent_free(be4); + if (be5) + bufferevent_free(be5); +} + + +struct gai_outcome { + int err; + struct evutil_addrinfo *ai; +}; + +static int n_gai_results_pending = 0; +static struct event_base *exit_base_on_no_pending_results = NULL; + +static void +gai_cb(int err, struct evutil_addrinfo *res, void *ptr) +{ + struct gai_outcome *go = ptr; + go->err = err; + go->ai = res; + if (--n_gai_results_pending <= 0 && exit_base_on_no_pending_results) + event_base_loopexit(exit_base_on_no_pending_results, NULL); + if (n_gai_results_pending < 900) + TT_BLATHER(("Got an answer; expecting %d more.", + n_gai_results_pending)); +} + +static void +cancel_gai_cb(evutil_socket_t fd, short what, void *ptr) +{ + struct evdns_getaddrinfo_request *r = ptr; + evdns_getaddrinfo_cancel(r); +} + +static void +test_getaddrinfo_async(void *arg) +{ + struct basic_test_data *data = arg; + struct evutil_addrinfo hints, *a; + struct gai_outcome local_outcome; + struct gai_outcome a_out[12]; + int i; + struct evdns_getaddrinfo_request *r; + char buf[128]; + struct evdns_server_port *port = NULL; + ev_uint16_t dns_port = 0; + int n_dns_questions = 0; + struct evdns_base *dns_base; + + memset(&a_out, 0, sizeof(a_out)); + memset(&local_outcome, 0, sizeof(local_outcome)); + + dns_base = evdns_base_new(data->base, 0); + tt_assert(dns_base); + + /* for localhost */ + evdns_base_load_hosts(dns_base, NULL); + + tt_assert(! evdns_base_set_option(dns_base, "timeout", "0.3")); + tt_assert(! evdns_base_set_option(dns_base, "getaddrinfo-allow-skew", "0.2")); + + n_gai_results_pending = 10000; /* don't think about exiting yet. */ + + /* 1. Try some cases that will never hit the asynchronous resolver. */ + /* 1a. Simple case with a symbolic service name */ + memset(&hints, 0, sizeof(hints)); + hints.ai_family = PF_UNSPEC; + hints.ai_socktype = SOCK_STREAM; + memset(&local_outcome, 0, sizeof(local_outcome)); + r = evdns_getaddrinfo(dns_base, "1.2.3.4", "http", + &hints, gai_cb, &local_outcome); + tt_assert(! r); + if (!local_outcome.err) { + tt_ptr_op(local_outcome.ai,!=,NULL); + test_ai_eq(local_outcome.ai, "1.2.3.4:80", SOCK_STREAM, IPPROTO_TCP); + evutil_freeaddrinfo(local_outcome.ai); + local_outcome.ai = NULL; + } else { + TT_BLATHER(("Apparently we have no getservbyname.")); + } + + /* 1b. EVUTIL_AI_NUMERICHOST is set */ + memset(&hints, 0, sizeof(hints)); + hints.ai_family = PF_UNSPEC; + hints.ai_flags = EVUTIL_AI_NUMERICHOST; + memset(&local_outcome, 0, sizeof(local_outcome)); + r = evdns_getaddrinfo(dns_base, "www.google.com", "80", + &hints, gai_cb, &local_outcome); + tt_ptr_op(r,==,NULL); + tt_int_op(local_outcome.err,==,EVUTIL_EAI_NONAME); + tt_ptr_op(local_outcome.ai,==,NULL); + + /* 1c. We give a numeric address (ipv6) */ + memset(&hints, 0, sizeof(hints)); + memset(&local_outcome, 0, sizeof(local_outcome)); + hints.ai_family = PF_UNSPEC; + hints.ai_protocol = IPPROTO_TCP; + r = evdns_getaddrinfo(dns_base, "f::f", "8008", + &hints, gai_cb, &local_outcome); + tt_assert(!r); + tt_int_op(local_outcome.err,==,0); + tt_assert(local_outcome.ai); + tt_ptr_op(local_outcome.ai->ai_next,==,NULL); + test_ai_eq(local_outcome.ai, "[f::f]:8008", SOCK_STREAM, IPPROTO_TCP); + evutil_freeaddrinfo(local_outcome.ai); + local_outcome.ai = NULL; + + /* 1d. We give a numeric address (ipv4) */ + memset(&hints, 0, sizeof(hints)); + memset(&local_outcome, 0, sizeof(local_outcome)); + hints.ai_family = PF_UNSPEC; + r = evdns_getaddrinfo(dns_base, "5.6.7.8", NULL, + &hints, gai_cb, &local_outcome); + tt_assert(!r); + tt_int_op(local_outcome.err,==,0); + tt_assert(local_outcome.ai); + a = ai_find_by_protocol(local_outcome.ai, IPPROTO_TCP); + tt_assert(a); + test_ai_eq(a, "5.6.7.8", SOCK_STREAM, IPPROTO_TCP); + a = ai_find_by_protocol(local_outcome.ai, IPPROTO_UDP); + tt_assert(a); + test_ai_eq(a, "5.6.7.8", SOCK_DGRAM, IPPROTO_UDP); + evutil_freeaddrinfo(local_outcome.ai); + local_outcome.ai = NULL; + + /* 1e. nodename is NULL (bind) */ + memset(&hints, 0, sizeof(hints)); + memset(&local_outcome, 0, sizeof(local_outcome)); + hints.ai_family = PF_UNSPEC; + hints.ai_socktype = SOCK_DGRAM; + hints.ai_flags = EVUTIL_AI_PASSIVE; + r = evdns_getaddrinfo(dns_base, NULL, "9090", + &hints, gai_cb, &local_outcome); + tt_assert(!r); + tt_int_op(local_outcome.err,==,0); + tt_assert(local_outcome.ai); + /* we should get a v4 address of 0.0.0.0... */ + a = ai_find_by_family(local_outcome.ai, PF_INET); + tt_assert(a); + test_ai_eq(a, "0.0.0.0:9090", SOCK_DGRAM, IPPROTO_UDP); + /* ... and a v6 address of ::0 */ + a = ai_find_by_family(local_outcome.ai, PF_INET6); + tt_assert(a); + test_ai_eq(a, "[::]:9090", SOCK_DGRAM, IPPROTO_UDP); + evutil_freeaddrinfo(local_outcome.ai); + local_outcome.ai = NULL; + + /* 1f. nodename is NULL (connect) */ + memset(&hints, 0, sizeof(hints)); + memset(&local_outcome, 0, sizeof(local_outcome)); + hints.ai_family = PF_UNSPEC; + hints.ai_socktype = SOCK_STREAM; + r = evdns_getaddrinfo(dns_base, NULL, "2", + &hints, gai_cb, &local_outcome); + tt_assert(!r); + tt_int_op(local_outcome.err,==,0); + tt_assert(local_outcome.ai); + /* we should get a v4 address of 127.0.0.1 .... */ + a = ai_find_by_family(local_outcome.ai, PF_INET); + tt_assert(a); + test_ai_eq(a, "127.0.0.1:2", SOCK_STREAM, IPPROTO_TCP); + /* ... and a v6 address of ::1 */ + a = ai_find_by_family(local_outcome.ai, PF_INET6); + tt_assert(a); + test_ai_eq(a, "[::1]:2", SOCK_STREAM, IPPROTO_TCP); + evutil_freeaddrinfo(local_outcome.ai); + local_outcome.ai = NULL; + + /* 1g. We find localhost immediately. (pf_unspec) */ + memset(&hints, 0, sizeof(hints)); + memset(&local_outcome, 0, sizeof(local_outcome)); + hints.ai_family = PF_UNSPEC; + hints.ai_socktype = SOCK_STREAM; + r = evdns_getaddrinfo(dns_base, "LOCALHOST", "80", + &hints, gai_cb, &local_outcome); + tt_assert(!r); + tt_int_op(local_outcome.err,==,0); + tt_assert(local_outcome.ai); + /* we should get a v4 address of 127.0.0.1 .... */ + a = ai_find_by_family(local_outcome.ai, PF_INET); + tt_assert(a); + test_ai_eq(a, "127.0.0.1:80", SOCK_STREAM, IPPROTO_TCP); + /* ... and a v6 address of ::1 */ + a = ai_find_by_family(local_outcome.ai, PF_INET6); + tt_assert(a); + test_ai_eq(a, "[::1]:80", SOCK_STREAM, IPPROTO_TCP); + evutil_freeaddrinfo(local_outcome.ai); + local_outcome.ai = NULL; + + /* 1g. We find localhost immediately. (pf_inet6) */ + memset(&hints, 0, sizeof(hints)); + memset(&local_outcome, 0, sizeof(local_outcome)); + hints.ai_family = PF_INET6; + hints.ai_socktype = SOCK_STREAM; + r = evdns_getaddrinfo(dns_base, "LOCALHOST", "9999", + &hints, gai_cb, &local_outcome); + tt_assert(! r); + tt_int_op(local_outcome.err,==,0); + tt_assert(local_outcome.ai); + a = local_outcome.ai; + test_ai_eq(a, "[::1]:9999", SOCK_STREAM, IPPROTO_TCP); + tt_ptr_op(a->ai_next, ==, NULL); + evutil_freeaddrinfo(local_outcome.ai); + local_outcome.ai = NULL; + + /* 2. Okay, now we can actually test the asynchronous resolver. */ + /* Start a dummy local dns server... */ + port = regress_get_dnsserver(data->base, &dns_port, NULL, + be_getaddrinfo_server_cb, &n_dns_questions); + tt_assert(port); + tt_int_op(dns_port, >=, 0); + /* ... and tell the evdns_base about it. */ + evutil_snprintf(buf, sizeof(buf), "127.0.0.1:%d", dns_port); + evdns_base_nameserver_ip_add(dns_base, buf); + + memset(&hints, 0, sizeof(hints)); + hints.ai_family = PF_UNSPEC; + hints.ai_socktype = SOCK_STREAM; + hints.ai_flags = EVUTIL_AI_CANONNAME; + /* 0: Request for both.example.com should return both addresses. */ + r = evdns_getaddrinfo(dns_base, "both.example.com", "8000", + &hints, gai_cb, &a_out[0]); + tt_assert(r); + + /* 1: Request for v4only.example.com should return one address. */ + r = evdns_getaddrinfo(dns_base, "v4only.example.com", "8001", + &hints, gai_cb, &a_out[1]); + tt_assert(r); + + /* 2: Request for v6only.example.com should return one address. */ + hints.ai_flags = 0; + r = evdns_getaddrinfo(dns_base, "v6only.example.com", "8002", + &hints, gai_cb, &a_out[2]); + tt_assert(r); + + /* 3: PF_INET request for v4assert.example.com should not generate a + * v6 request. The server will fail the test if it does. */ + hints.ai_family = PF_INET; + r = evdns_getaddrinfo(dns_base, "v4assert.example.com", "8003", + &hints, gai_cb, &a_out[3]); + tt_assert(r); + + /* 4: PF_INET6 request for v6assert.example.com should not generate a + * v4 request. The server will fail the test if it does. */ + hints.ai_family = PF_INET6; + r = evdns_getaddrinfo(dns_base, "v6assert.example.com", "8004", + &hints, gai_cb, &a_out[4]); + tt_assert(r); + + /* 5: PF_INET request for nosuchplace.example.com should give NEXIST. */ + hints.ai_family = PF_INET; + r = evdns_getaddrinfo(dns_base, "nosuchplace.example.com", "8005", + &hints, gai_cb, &a_out[5]); + tt_assert(r); + + /* 6: PF_UNSPEC request for nosuchplace.example.com should give NEXIST. + */ + hints.ai_family = PF_UNSPEC; + r = evdns_getaddrinfo(dns_base, "nosuchplace.example.com", "8006", + &hints, gai_cb, &a_out[6]); + tt_assert(r); + + /* 7: PF_UNSPEC request for v6timeout.example.com should give an ipv4 + * address only. */ + hints.ai_family = PF_UNSPEC; + r = evdns_getaddrinfo(dns_base, "v6timeout.example.com", "8007", + &hints, gai_cb, &a_out[7]); + tt_assert(r); + + /* 8: PF_UNSPEC request for v6timeout-nonexist.example.com should give + * a NEXIST */ + hints.ai_family = PF_UNSPEC; + r = evdns_getaddrinfo(dns_base, "v6timeout-nonexist.example.com", + "8008", &hints, gai_cb, &a_out[8]); + tt_assert(r); + + /* 9: AI_ADDRCONFIG should at least not crash. Can't test it more + * without knowing what kind of internet we have. */ + hints.ai_flags |= EVUTIL_AI_ADDRCONFIG; + r = evdns_getaddrinfo(dns_base, "both.example.com", + "8009", &hints, gai_cb, &a_out[9]); + tt_assert(r); + + /* 10: PF_UNSPEC for v4timeout.example.com should give an ipv6 address + * only. */ + hints.ai_family = PF_UNSPEC; + hints.ai_flags = 0; + r = evdns_getaddrinfo(dns_base, "v4timeout.example.com", "8010", + &hints, gai_cb, &a_out[10]); + tt_assert(r); + + /* 11: timeout.example.com: cancel it after 100 msec. */ + r = evdns_getaddrinfo(dns_base, "all-timeout.example.com", "8011", + &hints, gai_cb, &a_out[11]); + tt_assert(r); + { + struct timeval tv; + tv.tv_sec = 0; + tv.tv_usec = 100*1000; /* 100 msec */ + event_base_once(data->base, -1, EV_TIMEOUT, cancel_gai_cb, + r, &tv); + } + + /* XXXXX There are more tests we could do, including: + + - A test to elicit NODATA. + + */ + + n_gai_results_pending = 12; + exit_base_on_no_pending_results = data->base; + + event_base_dispatch(data->base); + + /* 0: both.example.com */ + tt_int_op(a_out[0].err, ==, 0); + tt_assert(a_out[0].ai); + tt_assert(a_out[0].ai->ai_next); + tt_assert(!a_out[0].ai->ai_next->ai_next); + a = ai_find_by_family(a_out[0].ai, PF_INET); + tt_assert(a); + test_ai_eq(a, "80.80.32.32:8000", SOCK_STREAM, IPPROTO_TCP); + a = ai_find_by_family(a_out[0].ai, PF_INET6); + tt_assert(a); + test_ai_eq(a, "[80ff::bbbb]:8000", SOCK_STREAM, IPPROTO_TCP); + tt_assert(a_out[0].ai->ai_canonname); + tt_str_op(a_out[0].ai->ai_canonname, ==, "both-canonical.example.com"); + + /* 1: v4only.example.com */ + tt_int_op(a_out[1].err, ==, 0); + tt_assert(a_out[1].ai); + tt_assert(! a_out[1].ai->ai_next); + test_ai_eq(a_out[1].ai, "18.52.86.120:8001", SOCK_STREAM, IPPROTO_TCP); + tt_assert(a_out[1].ai->ai_canonname == NULL); + + + /* 2: v6only.example.com */ + tt_int_op(a_out[2].err, ==, 0); + tt_assert(a_out[2].ai); + tt_assert(! a_out[2].ai->ai_next); + test_ai_eq(a_out[2].ai, "[b0b::f00d]:8002", SOCK_STREAM, IPPROTO_TCP); + + /* 3: v4assert.example.com */ + tt_int_op(a_out[3].err, ==, 0); + tt_assert(a_out[3].ai); + tt_assert(! a_out[3].ai->ai_next); + test_ai_eq(a_out[3].ai, "18.52.86.120:8003", SOCK_STREAM, IPPROTO_TCP); + + /* 4: v6assert.example.com */ + tt_int_op(a_out[4].err, ==, 0); + tt_assert(a_out[4].ai); + tt_assert(! a_out[4].ai->ai_next); + test_ai_eq(a_out[4].ai, "[b0b::f00d]:8004", SOCK_STREAM, IPPROTO_TCP); + + /* 5: nosuchplace.example.com (inet) */ + tt_int_op(a_out[5].err, ==, EVUTIL_EAI_NONAME); + tt_assert(! a_out[5].ai); + + /* 6: nosuchplace.example.com (unspec) */ + tt_int_op(a_out[6].err, ==, EVUTIL_EAI_NONAME); + tt_assert(! a_out[6].ai); + + /* 7: v6timeout.example.com */ + tt_int_op(a_out[7].err, ==, 0); + tt_assert(a_out[7].ai); + tt_assert(! a_out[7].ai->ai_next); + test_ai_eq(a_out[7].ai, "171.205.239.1:8007", SOCK_STREAM, IPPROTO_TCP); + + /* 8: v6timeout-nonexist.example.com */ + tt_int_op(a_out[8].err, ==, EVUTIL_EAI_NONAME); + tt_assert(! a_out[8].ai); + + /* 9: both (ADDRCONFIG) */ + tt_int_op(a_out[9].err, ==, 0); + tt_assert(a_out[9].ai); + a = ai_find_by_family(a_out[9].ai, PF_INET); + if (a) + test_ai_eq(a, "80.80.32.32:8009", SOCK_STREAM, IPPROTO_TCP); + else + tt_assert(ai_find_by_family(a_out[9].ai, PF_INET6)); + a = ai_find_by_family(a_out[9].ai, PF_INET6); + if (a) + test_ai_eq(a, "[80ff::bbbb]:8009", SOCK_STREAM, IPPROTO_TCP); + else + tt_assert(ai_find_by_family(a_out[9].ai, PF_INET)); + + /* 10: v4timeout.example.com */ + tt_int_op(a_out[10].err, ==, 0); + tt_assert(a_out[10].ai); + tt_assert(! a_out[10].ai->ai_next); + test_ai_eq(a_out[10].ai, "[a0a::ff01]:8010", SOCK_STREAM, IPPROTO_TCP); + + /* 11: cancelled request. */ + tt_int_op(a_out[11].err, ==, EVUTIL_EAI_CANCEL); + tt_assert(a_out[11].ai == NULL); + +end: + if (local_outcome.ai) + evutil_freeaddrinfo(local_outcome.ai); +#define ARRAY_SIZE(a) (sizeof(a) / sizeof(a[0])) + for (i=0;i<(int)ARRAY_SIZE(a_out);++i) { + if (a_out[i].ai) + evutil_freeaddrinfo(a_out[i].ai); + } + if (port) + evdns_close_server_port(port); + if (dns_base) + evdns_base_free(dns_base, 0); +} + +struct gaic_request_status { + int magic; + struct event_base *base; + struct evdns_base *dns_base; + struct evdns_getaddrinfo_request *request; + struct event cancel_event; + int canceled; +}; + +#define GAIC_MAGIC 0x1234abcd + +static int pending = 0; + +static void +gaic_cancel_request_cb(evutil_socket_t fd, short what, void *arg) +{ + struct gaic_request_status *status = arg; + + tt_assert(status->magic == GAIC_MAGIC); + status->canceled = 1; + evdns_getaddrinfo_cancel(status->request); + return; +end: + event_base_loopexit(status->base, NULL); +} + +static void +gaic_server_cb(struct evdns_server_request *req, void *arg) +{ + ev_uint32_t answer = 0x7f000001; + tt_assert(req->nquestions); + evdns_server_request_add_a_reply(req, req->questions[0]->name, 1, + &answer, 100); + evdns_server_request_respond(req, 0); + return; +end: + evdns_server_request_respond(req, DNS_ERR_REFUSED); +} + + +static void +gaic_getaddrinfo_cb(int result, struct evutil_addrinfo *res, void *arg) +{ + struct gaic_request_status *status = arg; + struct event_base *base = status->base; + tt_assert(status->magic == GAIC_MAGIC); + + if (result == EVUTIL_EAI_CANCEL) { + tt_assert(status->canceled); + } + event_del(&status->cancel_event); + + memset(status, 0xf0, sizeof(*status)); + free(status); + +end: + if (--pending <= 0) + event_base_loopexit(base, NULL); +} + +static void +gaic_launch(struct event_base *base, struct evdns_base *dns_base) +{ + struct gaic_request_status *status = calloc(1, sizeof(*status)); + tt_assert(status); + struct timeval tv = { 0, 10000 }; + status->magic = GAIC_MAGIC; + status->base = base; + status->dns_base = dns_base; + event_assign(&status->cancel_event, base, -1, 0, gaic_cancel_request_cb, + status); + status->request = evdns_getaddrinfo(dns_base, + "foobar.bazquux.example.com", "80", NULL, gaic_getaddrinfo_cb, + status); + event_add(&status->cancel_event, &tv); + ++pending; +} + +#ifdef EVENT_SET_MEM_FUNCTIONS_IMPLEMENTED +/* FIXME: We should move this to regress_main.c if anything else needs it.*/ + +/* Trivial replacements for malloc/free/realloc to check for memory leaks. + * Not threadsafe. */ +static int allocated_chunks = 0; + +static void * +cnt_malloc(size_t sz) +{ + allocated_chunks += 1; + return malloc(sz); +} + +static void * +cnt_realloc(void *old, size_t sz) +{ + if (!old) + allocated_chunks += 1; + if (!sz) + allocated_chunks -= 1; + return realloc(old, sz); +} + +static void +cnt_free(void *ptr) +{ + allocated_chunks -= 1; + free(ptr); +} + +struct testleak_env_t { + struct event_base *base; + struct evdns_base *dns_base; + struct evdns_request *req; + struct generic_dns_callback_result r; +}; + +static void * +testleak_setup(const struct testcase_t *testcase) +{ + struct testleak_env_t *env; + + allocated_chunks = 0; + + /* Reset allocation counter, to start allocations from the very beginning. + * (this will avoid false-positive negative numbers for allocated_chunks) + */ + libevent_global_shutdown(); + + event_set_mem_functions(cnt_malloc, cnt_realloc, cnt_free); + + event_enable_debug_mode(); + + /* not mm_calloc: we don't want to mess with the count. */ + env = calloc(1, sizeof(struct testleak_env_t)); + env->base = event_base_new(); + env->dns_base = evdns_base_new(env->base, 0); + env->req = evdns_base_resolve_ipv4( + env->dns_base, "example.com", DNS_QUERY_NO_SEARCH, + generic_dns_callback, &env->r); + return env; +} + +static int +testleak_cleanup(const struct testcase_t *testcase, void *env_) +{ + int ok = 0; + struct testleak_env_t *env = env_; + tt_assert(env); +#ifdef EVENT__DISABLE_DEBUG_MODE + tt_int_op(allocated_chunks, ==, 0); +#else + libevent_global_shutdown(); + tt_int_op(allocated_chunks, ==, 0); +#endif + ok = 1; +end: + if (env) { + if (env->dns_base) + evdns_base_free(env->dns_base, 0); + if (env->base) + event_base_free(env->base); + free(env); + } + return ok; +} + +static struct testcase_setup_t testleak_funcs = { + testleak_setup, testleak_cleanup +}; + +static void +test_dbg_leak_cancel(void *env_) +{ + /* cancel, loop, free/dns, free/base */ + struct testleak_env_t *env = env_; + int send_err_shutdown = 1; + evdns_cancel_request(env->dns_base, env->req); + env->req = 0; + + /* `req` is freed in callback, that's why one loop is required. */ + event_base_loop(env->base, EVLOOP_NONBLOCK); + + /* send_err_shutdown means nothing as soon as our request is + * already canceled */ + evdns_base_free(env->dns_base, send_err_shutdown); + env->dns_base = 0; + event_base_free(env->base); + env->base = 0; +} + +static void +dbg_leak_resume(void *env_, int cancel, int send_err_shutdown) +{ + /* cancel, loop, free/dns, free/base */ + struct testleak_env_t *env = env_; + if (cancel) { + evdns_cancel_request(env->dns_base, env->req); + tt_assert(!evdns_base_resume(env->dns_base)); + } else { + /* TODO: No nameservers, request can't be processed, must be errored */ + tt_assert(!evdns_base_resume(env->dns_base)); + } + + /** + * Because we don't cancel request, + * and want our callback to recieve DNS_ERR_SHUTDOWN, + * we use deferred callback, and there was + * - one extra malloc(), + * @see reply_schedule_callback() + * - and one missing free + * @see request_finished() (req->handle->pending_cb = 1) + * than we don't need to count in testleak_cleanup() + * + * So just decrement allocated_chunks to 2, + * like we already take care about it. + */ + if (!cancel && send_err_shutdown) { + allocated_chunks -= 2; + } + + event_base_loop(env->base, EVLOOP_NONBLOCK); + +end: + evdns_base_free(env->dns_base, send_err_shutdown); + env->dns_base = 0; + + event_base_free(env->base); + env->base = 0; +} + +#define IMPL_DBG_LEAK_RESUME(name, cancel, send_err_shutdown) \ + static void \ + test_dbg_leak_##name##_(void *env_) \ + { \ + dbg_leak_resume(env_, cancel, send_err_shutdown); \ + } +IMPL_DBG_LEAK_RESUME(resume, 0, 0) +IMPL_DBG_LEAK_RESUME(cancel_and_resume, 1, 0) +IMPL_DBG_LEAK_RESUME(resume_send_err, 0, 1) +IMPL_DBG_LEAK_RESUME(cancel_and_resume_send_err, 1, 1) + +static void +test_dbg_leak_shutdown(void *env_) +{ + /* free/dns, loop, free/base */ + struct testleak_env_t *env = env_; + int send_err_shutdown = 1; + + /* `req` is freed both with `send_err_shutdown` and without it, + * the only difference is `evdns_callback` call */ + env->req = 0; + + evdns_base_free(env->dns_base, send_err_shutdown); + env->dns_base = 0; + + /* `req` is freed in callback, that's why one loop is required */ + event_base_loop(env->base, EVLOOP_NONBLOCK); + event_base_free(env->base); + env->base = 0; +} +#endif + +static void +test_getaddrinfo_async_cancel_stress(void *ptr) +{ + struct event_base *base; + struct evdns_base *dns_base = NULL; + struct evdns_server_port *server = NULL; + evutil_socket_t fd = -1; + struct sockaddr_in sin; + struct sockaddr_storage ss; + ev_socklen_t slen; + int i; + + base = event_base_new(); + dns_base = evdns_base_new(base, 0); + + memset(&sin, 0, sizeof(sin)); + sin.sin_family = AF_INET; + sin.sin_port = 0; + sin.sin_addr.s_addr = htonl(0x7f000001); + if ((fd = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { + tt_abort_perror("socket"); + } + evutil_make_socket_nonblocking(fd); + if (bind(fd, (struct sockaddr*)&sin, sizeof(sin))<0) { + tt_abort_perror("bind"); + } + server = evdns_add_server_port_with_base(base, fd, 0, gaic_server_cb, + base); + + memset(&ss, 0, sizeof(ss)); + slen = sizeof(ss); + if (getsockname(fd, (struct sockaddr*)&ss, &slen)<0) { + tt_abort_perror("getsockname"); + } + evdns_base_nameserver_sockaddr_add(dns_base, + (struct sockaddr*)&ss, slen, 0); + + for (i = 0; i < 1000; ++i) { + gaic_launch(base, dns_base); + } + + event_base_dispatch(base); + +end: + if (dns_base) + evdns_base_free(dns_base, 1); + if (server) + evdns_close_server_port(server); + if (base) + event_base_free(base); + if (fd >= 0) + evutil_closesocket(fd); +} + + +#define DNS_LEGACY(name, flags) \ + { #name, run_legacy_test_fn, flags|TT_LEGACY, &legacy_setup, \ + dns_##name } + +struct testcase_t dns_testcases[] = { + DNS_LEGACY(server, TT_FORK|TT_NEED_BASE), + DNS_LEGACY(gethostbyname, TT_FORK|TT_NEED_BASE|TT_NEED_DNS|TT_OFF_BY_DEFAULT), + DNS_LEGACY(gethostbyname6, TT_FORK|TT_NEED_BASE|TT_NEED_DNS|TT_OFF_BY_DEFAULT), + DNS_LEGACY(gethostbyaddr, TT_FORK|TT_NEED_BASE|TT_NEED_DNS|TT_OFF_BY_DEFAULT), + { "resolve_reverse", dns_resolve_reverse, TT_FORK|TT_OFF_BY_DEFAULT, NULL, NULL }, + { "search", dns_search_test, TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + { "search_cancel", dns_search_cancel_test, + TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + { "retry", dns_retry_test, TT_FORK|TT_NEED_BASE|TT_NO_LOGS, &basic_setup, NULL }, + { "retry_disable_when_inactive", dns_retry_disable_when_inactive_test, + TT_FORK|TT_NEED_BASE|TT_NO_LOGS, &basic_setup, NULL }, + { "reissue", dns_reissue_test, TT_FORK|TT_NEED_BASE|TT_NO_LOGS, &basic_setup, NULL }, + { "reissue_disable_when_inactive", dns_reissue_disable_when_inactive_test, + TT_FORK|TT_NEED_BASE|TT_NO_LOGS, &basic_setup, NULL }, + { "inflight", dns_inflight_test, TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + { "bufferevent_connect_hostname", test_bufferevent_connect_hostname, + TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + { "disable_when_inactive", dns_disable_when_inactive_test, + TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + { "disable_when_inactive_no_ns", dns_disable_when_inactive_no_ns_test, + TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, + + { "getaddrinfo_async", test_getaddrinfo_async, + TT_FORK|TT_NEED_BASE, &basic_setup, (char*)"" }, + { "getaddrinfo_cancel_stress", test_getaddrinfo_async_cancel_stress, + TT_FORK, NULL, NULL }, + +#ifdef EVENT_SET_MEM_FUNCTIONS_IMPLEMENTED + { "leak_shutdown", test_dbg_leak_shutdown, TT_FORK, &testleak_funcs, NULL }, + { "leak_cancel", test_dbg_leak_cancel, TT_FORK, &testleak_funcs, NULL }, + + { "leak_resume", test_dbg_leak_resume_, TT_FORK, &testleak_funcs, NULL }, + { "leak_cancel_and_resume", test_dbg_leak_cancel_and_resume_, + TT_FORK, &testleak_funcs, NULL }, + { "leak_resume_send_err", test_dbg_leak_resume_send_err_, + TT_FORK, &testleak_funcs, NULL }, + { "leak_cancel_and_resume_send_err", test_dbg_leak_cancel_and_resume_send_err_, + TT_FORK, &testleak_funcs, NULL }, +#endif + + END_OF_TESTCASES +}; + diff --git a/contrib/ntp/sntp/libevent/test/regress_et.c b/contrib/ntp/sntp/libevent/test/regress_et.c new file mode 100644 index 000000000..229a78e2d --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress_et.c @@ -0,0 +1,208 @@ +/* + * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "../util-internal.h" +#include "event2/event-config.h" + +#ifdef _WIN32 +#include +#endif +#include +#include +#ifdef EVENT__HAVE_SYS_SOCKET_H +#include +#endif +#include +#include +#include +#include +#ifndef _WIN32 +#include +#include +#endif +#include + +#include "event2/event.h" +#include "event2/util.h" + +#include "regress.h" + +static int was_et = 0; + +static void +read_cb(evutil_socket_t fd, short event, void *arg) +{ + char buf; + int len; + + len = recv(fd, &buf, sizeof(buf), 0); + + called++; + if (event & EV_ET) + was_et = 1; + + if (!len) + event_del(arg); +} + +#ifndef SHUT_WR +#define SHUT_WR 1 +#endif + +#ifdef _WIN32 +#define LOCAL_SOCKETPAIR_AF AF_INET +#else +#define LOCAL_SOCKETPAIR_AF AF_UNIX +#endif + +static void +test_edgetriggered(void *et) +{ + struct event *ev = NULL; + struct event_base *base = NULL; + const char *test = "test string"; + evutil_socket_t pair[2] = {-1,-1}; + int supports_et; + + /* On Linux 3.2.1 (at least, as patched by Fedora and tested by Nick), + * doing a "recv" on an AF_UNIX socket resets the readability of the + * socket, even though there is no state change, so we don't actually + * get edge-triggered behavior. Yuck! Linux 3.1.9 didn't have this + * problem. + */ +#ifdef __linux__ + if (evutil_ersatz_socketpair_(AF_INET, SOCK_STREAM, 0, pair) == -1) { + tt_abort_perror("socketpair"); + } +#else + if (evutil_socketpair(LOCAL_SOCKETPAIR_AF, SOCK_STREAM, 0, pair) == -1) { + tt_abort_perror("socketpair"); + } +#endif + + called = was_et = 0; + + tt_int_op(send(pair[0], test, (int)strlen(test)+1, 0), >, 0); + shutdown(pair[0], SHUT_WR); + + /* Initalize the event library */ + base = event_base_new(); + + if (!strcmp(event_base_get_method(base), "epoll") || + !strcmp(event_base_get_method(base), "epoll (with changelist)") || + !strcmp(event_base_get_method(base), "kqueue")) + supports_et = 1; + else + supports_et = 0; + + TT_BLATHER(("Checking for edge-triggered events with %s, which should %s" + "support edge-triggering", event_base_get_method(base), + supports_et?"":"not ")); + + /* Initalize one event */ + ev = event_new(base, pair[1], EV_READ|EV_ET|EV_PERSIST, read_cb, &ev); + + event_add(ev, NULL); + + /* We're going to call the dispatch function twice. The first invocation + * will read a single byte from pair[1] in either case. If we're edge + * triggered, we'll only see the event once (since we only see transitions + * from no data to data), so the second invocation of event_base_loop will + * do nothing. If we're level triggered, the second invocation of + * event_base_loop will also activate the event (because there's still + * data to read). */ + event_base_loop(base,EVLOOP_NONBLOCK|EVLOOP_ONCE); + event_base_loop(base,EVLOOP_NONBLOCK|EVLOOP_ONCE); + + if (supports_et) { + tt_int_op(called, ==, 1); + tt_assert(was_et); + } else { + tt_int_op(called, ==, 2); + tt_assert(!was_et); + } + + end: + if (ev) { + event_del(ev); + event_free(ev); + } + if (base) + event_base_free(base); + evutil_closesocket(pair[0]); + evutil_closesocket(pair[1]); +} + +static void +test_edgetriggered_mix_error(void *data_) +{ + struct basic_test_data *data = data_; + struct event_base *base = NULL; + struct event *ev_et=NULL, *ev_lt=NULL; + +#ifdef EVENT__DISABLE_DEBUG_MODE + if (1) + tt_skip(); +#endif + + if (!libevent_tests_running_in_debug_mode) + event_enable_debug_mode(); + + base = event_base_new(); + + /* try mixing edge-triggered and level-triggered to make sure it fails*/ + ev_et = event_new(base, data->pair[0], EV_READ|EV_ET, read_cb, ev_et); + tt_assert(ev_et); + ev_lt = event_new(base, data->pair[0], EV_READ, read_cb, ev_lt); + tt_assert(ev_lt); + + /* Add edge-triggered, then level-triggered. Get an error. */ + tt_int_op(0, ==, event_add(ev_et, NULL)); + tt_int_op(-1, ==, event_add(ev_lt, NULL)); + tt_int_op(EV_READ, ==, event_pending(ev_et, EV_READ, NULL)); + tt_int_op(0, ==, event_pending(ev_lt, EV_READ, NULL)); + + tt_int_op(0, ==, event_del(ev_et)); + /* Add level-triggered, then edge-triggered. Get an error. */ + tt_int_op(0, ==, event_add(ev_lt, NULL)); + tt_int_op(-1, ==, event_add(ev_et, NULL)); + tt_int_op(EV_READ, ==, event_pending(ev_lt, EV_READ, NULL)); + tt_int_op(0, ==, event_pending(ev_et, EV_READ, NULL)); + +end: + if (ev_et) + event_free(ev_et); + if (ev_lt) + event_free(ev_lt); + if (base) + event_base_free(base); +} + +struct testcase_t edgetriggered_testcases[] = { + { "et", test_edgetriggered, TT_FORK, NULL, NULL }, + { "et_mix_error", test_edgetriggered_mix_error, + TT_FORK|TT_NEED_SOCKETPAIR|TT_NO_LOGS, &basic_setup, NULL }, + END_OF_TESTCASES +}; diff --git a/contrib/ntp/sntp/libevent/test/regress_finalize.c b/contrib/ntp/sntp/libevent/test/regress_finalize.c new file mode 100644 index 000000000..552210fe9 --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress_finalize.c @@ -0,0 +1,347 @@ +/* + * Copyright (c) 2013 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "event2/event-config.h" +#include "evconfig-private.h" +#include "tinytest.h" +#include "tinytest_macros.h" +#include + +#include "event2/event.h" +#include "event2/util.h" +#include "event-internal.h" +#include "defer-internal.h" + +#include "regress.h" +#include "regress_thread.h" + +static void +timer_callback(evutil_socket_t fd, short what, void *arg) +{ + int *int_arg = arg; + *int_arg += 1; + (void)fd; + (void)what; +} +static void +simple_callback(struct event_callback *evcb, void *arg) +{ + int *int_arg = arg; + *int_arg += 1; + (void)evcb; +} +static void +event_finalize_callback_1(struct event *ev, void *arg) +{ + int *int_arg = arg; + *int_arg += 100; + (void)ev; +} +static void +callback_finalize_callback_1(struct event_callback *evcb, void *arg) +{ + int *int_arg = arg; + *int_arg += 100; + (void)evcb; +} + + +static void +test_fin_cb_invoked(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + + struct event *ev; + struct event ev2; + struct event_callback evcb; + int cb_called = 0; + int ev_called = 0; + + const struct timeval ten_sec = {10,0}; + + event_deferred_cb_init_(&evcb, 0, simple_callback, &cb_called); + ev = evtimer_new(base, timer_callback, &ev_called); + /* Just finalize them; don't bother adding. */ + event_free_finalize(0, ev, event_finalize_callback_1); + event_callback_finalize_(base, 0, &evcb, callback_finalize_callback_1); + + event_base_dispatch(base); + + tt_int_op(cb_called, ==, 100); + tt_int_op(ev_called, ==, 100); + + ev_called = cb_called = 0; + event_base_assert_ok_(base); + + /* Now try it when they're active. (actually, don't finalize: make + * sure activation can happen! */ + ev = evtimer_new(base, timer_callback, &ev_called); + event_deferred_cb_init_(&evcb, 0, simple_callback, &cb_called); + + event_active(ev, EV_TIMEOUT, 1); + event_callback_activate_(base, &evcb); + + event_base_dispatch(base); + tt_int_op(cb_called, ==, 1); + tt_int_op(ev_called, ==, 1); + + ev_called = cb_called = 0; + event_base_assert_ok_(base); + + /* Great, it worked. Now activate and finalize and make sure only + * finalizing happens. */ + event_active(ev, EV_TIMEOUT, 1); + event_callback_activate_(base, &evcb); + event_free_finalize(0, ev, event_finalize_callback_1); + event_callback_finalize_(base, 0, &evcb, callback_finalize_callback_1); + + event_base_dispatch(base); + tt_int_op(cb_called, ==, 100); + tt_int_op(ev_called, ==, 100); + + ev_called = 0; + + event_base_assert_ok_(base); + + /* Okay, now add but don't have it become active, and make sure *that* + * works. */ + ev = evtimer_new(base, timer_callback, &ev_called); + event_add(ev, &ten_sec); + event_free_finalize(0, ev, event_finalize_callback_1); + + event_base_dispatch(base); + tt_int_op(ev_called, ==, 100); + + ev_called = 0; + event_base_assert_ok_(base); + + /* Now try adding and deleting after finalizing. */ + ev = evtimer_new(base, timer_callback, &ev_called); + evtimer_assign(&ev2, base, timer_callback, &ev_called); + event_add(ev, &ten_sec); + event_free_finalize(0, ev, event_finalize_callback_1); + event_finalize(0, &ev2, event_finalize_callback_1); + + event_add(&ev2, &ten_sec); + event_del(ev); + event_active(&ev2, EV_TIMEOUT, 1); + + event_base_dispatch(base); + tt_int_op(ev_called, ==, 200); + + event_base_assert_ok_(base); + +end: + ; +} + +#ifndef EVENT__DISABLE_MM_REPLACEMENT +static void * +tfff_malloc(size_t n) +{ + return malloc(n); +} +static void *tfff_p1=NULL, *tfff_p2=NULL; +static int tfff_p1_freed=0, tfff_p2_freed=0; +static void +tfff_free(void *p) +{ + if (! p) + return; + if (p == tfff_p1) + ++tfff_p1_freed; + if (p == tfff_p2) + ++tfff_p2_freed; + free(p); +} +static void * +tfff_realloc(void *p, size_t sz) +{ + return realloc(p,sz); +} +#endif + +static void +test_fin_free_finalize(void *arg) +{ +#ifdef EVENT__DISABLE_MM_REPLACEMENT + tinytest_set_test_skipped_(); +#else + struct event_base *base = NULL; + struct event *ev, *ev2; + int ev_called = 0; + int ev2_called = 0; + + (void)arg; + + event_set_mem_functions(tfff_malloc, tfff_realloc, tfff_free); + + base = event_base_new(); + tt_assert(base); + + ev = evtimer_new(base, timer_callback, &ev_called); + ev2 = evtimer_new(base, timer_callback, &ev2_called); + tfff_p1 = ev; + tfff_p2 = ev2; + event_free_finalize(0, ev, event_finalize_callback_1); + event_finalize(0, ev2, event_finalize_callback_1); + + event_base_dispatch(base); + + tt_int_op(ev_called, ==, 100); + tt_int_op(ev2_called, ==, 100); + + event_base_assert_ok_(base); + tt_int_op(tfff_p1_freed, ==, 1); + tt_int_op(tfff_p2_freed, ==, 0); + + event_free(ev2); + +end: + if (base) + event_base_free(base); +#endif +} + +/* For test_fin_within_cb */ +struct event_and_count { + struct event *ev; + struct event *ev2; + int count; +}; +static void +event_finalize_callback_2(struct event *ev, void *arg) +{ + struct event_and_count *evc = arg; + evc->count += 100; + event_free(ev); +} +static void +timer_callback_2(evutil_socket_t fd, short what, void *arg) +{ + struct event_and_count *evc = arg; + event_finalize(0, evc->ev, event_finalize_callback_2); + event_finalize(0, evc->ev2, event_finalize_callback_2); + ++ evc->count; + (void)fd; + (void)what; +} + +static void +test_fin_within_cb(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + + struct event_and_count evc1, evc2; + evc1.count = evc2.count = 0; + evc2.ev2 = evc1.ev = evtimer_new(base, timer_callback_2, &evc1); + evc1.ev2 = evc2.ev = evtimer_new(base, timer_callback_2, &evc2); + + /* Activate both. The first one will have its callback run, which + * will finalize both of them, preventing the second one's callback + * from running. */ + event_active(evc1.ev, EV_TIMEOUT, 1); + event_active(evc2.ev, EV_TIMEOUT, 1); + + event_base_dispatch(base); + tt_int_op(evc1.count, ==, 101); + tt_int_op(evc2.count, ==, 100); + + event_base_assert_ok_(base); + /* Now try with EV_PERSIST events. */ + evc1.count = evc2.count = 0; + evc2.ev2 = evc1.ev = event_new(base, -1, EV_PERSIST, timer_callback_2, &evc1); + evc1.ev2 = evc2.ev = event_new(base, -1, EV_PERSIST, timer_callback_2, &evc2); + + event_active(evc1.ev, EV_TIMEOUT, 1); + event_active(evc2.ev, EV_TIMEOUT, 1); + + event_base_dispatch(base); + tt_int_op(evc1.count, ==, 101); + tt_int_op(evc2.count, ==, 100); + + event_base_assert_ok_(base); +end: + ; +} + +#if 0 +static void +timer_callback_3(evutil_socket_t *fd, short what, void *arg) +{ + (void)fd; + (void)what; + +} +static void +test_fin_many(void *arg) +{ + struct basic_test_data *data = arg; + struct event_base *base = data->base; + + struct event *ev1, *ev2; + struct event_callback evcb1, evcb2; + int ev1_count = 0, ev2_count = 0; + int evcb1_count = 0, evcb2_count = 0; + struct event_callback *array[4]; + + int n; + + /* First attempt: call finalize_many with no events running */ + ev1 = evtimer_new(base, timer_callback, &ev1_count); + ev1 = evtimer_new(base, timer_callback, &ev2_count); + event_deferred_cb_init_(&evcb1, 0, simple_callback, &evcb1_called); + event_deferred_cb_init_(&evcb2, 0, simple_callback, &evcb2_called); + array[0] = &ev1->ev_evcallback; + array[1] = &ev2->ev_evcallback; + array[2] = &evcb1; + array[3] = &evcb2; + + + + n = event_callback_finalize_many(base, 4, array, + callback_finalize_callback_1); + +} +#endif + + +#define TEST(name, flags) \ + { #name, test_fin_##name, (flags), &basic_setup, NULL } + +struct testcase_t finalize_testcases[] = { + + TEST(cb_invoked, TT_FORK|TT_NEED_BASE), + TEST(free_finalize, TT_FORK), + TEST(within_cb, TT_FORK|TT_NEED_BASE), +// TEST(many, TT_FORK|TT_NEED_BASE), + + + END_OF_TESTCASES +}; + diff --git a/contrib/ntp/sntp/libevent/test/regress_http.c b/contrib/ntp/sntp/libevent/test/regress_http.c new file mode 100644 index 000000000..147f6ff1a --- /dev/null +++ b/contrib/ntp/sntp/libevent/test/regress_http.c @@ -0,0 +1,3995 @@ +/* + * Copyright (c) 2003-2007 Niels Provos + * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "util-internal.h" + +#ifdef _WIN32 +#include +#include +#include +#endif + +#include "event2/event-config.h" + +#include +#include +#ifdef EVENT__HAVE_SYS_TIME_H +#include +#endif +#include +#ifndef _WIN32 +#include +#include +#include +#include +#endif +#include +#include +#include +#include +#include + +#include "event2/dns.h" + +#include "event2/event.h" +#include "event2/http.h" +#include "event2/buffer.h" +#include "event2/bufferevent.h" +#include "event2/util.h" +#include "log-internal.h" +#include "http-internal.h" +#include "regress.h" +#include "regress_testutils.h" + +static struct evhttp *http; +/* set if a test needs to call loopexit on a base */ +static struct event_base *exit_base; + +static char const BASIC_REQUEST_BODY[] = "This is funny"; + +#define IMPL_HTTP_REQUEST_ERROR_CB(name, expecting_error) \ + static void \ + http_request_error_cb_with_##name##_(enum evhttp_request_error error, \ + void *arg) \ + { \ + if (error != expecting_error) { \ + fprintf(stderr, "FAILED\n"); \ + exit(1); \ + } \ + test_ok = 1; \ + } +IMPL_HTTP_REQUEST_ERROR_CB(cancel, EVREQ_HTTP_REQUEST_CANCEL) + +static void http_basic_cb(struct evhttp_request *req, void *arg); +static void http_chunked_cb(struct evhttp_request *req, void *arg); +static void http_post_cb(struct evhttp_request *req, void *arg); +static void http_put_cb(struct evhttp_request *req, void *arg); +static void http_delete_cb(struct evhttp_request *req, void *arg); +static void http_delay_cb(struct evhttp_request *req, void *arg); +static void http_large_delay_cb(struct evhttp_request *req, void *arg); +static void http_badreq_cb(struct evhttp_request *req, void *arg); +static void http_dispatcher_cb(struct evhttp_request *req, void *arg); +static void http_on_complete_cb(struct evhttp_request *req, void *arg); + +static int +http_bind(struct evhttp *myhttp, ev_uint16_t *pport, int ipv6) +{ + int port; + struct evhttp_bound_socket *sock; + + if (ipv6) + sock = evhttp_bind_socket_with_handle(myhttp, "::1", *pport); + else + sock = evhttp_bind_socket_with_handle(myhttp, "127.0.0.1", *pport); + + if (sock == NULL) { + if (ipv6) + return -1; + else + event_errx(1, "Could not start web server"); + } + + port = regress_get_socket_port(evhttp_bound_socket_get_fd(sock)); + if (port < 0) + return -1; + *pport = (ev_uint16_t) port; + + return 0; +} + +static struct evhttp * +http_setup(ev_uint16_t *pport, struct event_base *base, int ipv6) +{ + struct evhttp *myhttp; + + /* Try a few different ports */ + myhttp = evhttp_new(base); + + if (http_bind(myhttp, pport, ipv6) < 0) + return NULL; + + /* Register a callback for certain types of requests */ + evhttp_set_cb(myhttp, "/test", http_basic_cb, base); + evhttp_set_cb(myhttp, "/chunked", http_chunked_cb, base); + evhttp_set_cb(myhttp, "/streamed", http_chunked_cb, base); + evhttp_set_cb(myhttp, "/postit", http_post_cb, base); + evhttp_set_cb(myhttp, "/putit", http_put_cb, base); + evhttp_set_cb(myhttp, "/deleteit", http_delete_cb, base); + evhttp_set_cb(myhttp, "/delay", http_delay_cb, base); + evhttp_set_cb(myhttp, "/largedelay", http_large_delay_cb, base); + evhttp_set_cb(myhttp, "/badrequest", http_badreq_cb, base); + evhttp_set_cb(myhttp, "/oncomplete", http_on_complete_cb, base); + evhttp_set_cb(myhttp, "/", http_dispatcher_cb, base); + return (myhttp); +} + +#ifndef NI_MAXSERV +#define NI_MAXSERV 1024 +#endif + +static evutil_socket_t +http_connect(const char *address, u_short port) +{ + /* Stupid code for connecting */ + struct evutil_addrinfo ai, *aitop; + char strport[NI_MAXSERV]; + + struct sockaddr *sa; + int slen; + evutil_socket_t fd; + + memset(&ai, 0, sizeof(ai)); + ai.ai_family = AF_INET; + ai.ai_socktype = SOCK_STREAM; + evutil_snprintf(strport, sizeof(strport), "%d", port); + if (evutil_getaddrinfo(address, strport, &ai, &aitop) != 0) { + event_warn("getaddrinfo"); + return (-1); + } + sa = aitop->ai_addr; + slen = aitop->ai_addrlen; + + fd = socket(AF_INET, SOCK_STREAM, 0); + if (fd == -1) + event_err(1, "socket failed"); + + evutil_make_socket_nonblocking(fd); + if (connect(fd, sa, slen) == -1) { +#ifdef _WIN32 + int tmp_err = WSAGetLastError(); + if (tmp_err != WSAEINPROGRESS && tmp_err != WSAEINVAL && + tmp_err != WSAEWOULDBLOCK) + event_err(1, "connect failed"); +#else + if (errno != EINPROGRESS) + event_err(1, "connect failed"); +#endif + } + + evutil_freeaddrinfo(aitop); + + return (fd); +} + +/* Helper: do a strcmp on the contents of buf and the string s. */ +static int +evbuffer_datacmp(struct evbuffer *buf, const char *s) +{ + size_t b_sz = evbuffer_get_length(buf); + size_t s_sz = strlen(s); + unsigned char *d; + int r; + + if (b_sz < s_sz) + return -1; + + d = evbuffer_pullup(buf, s_sz); + if ((r = memcmp(d, s, s_sz))) + return r; + + if (b_sz > s_sz) + return 1; + else + return 0; +} + +/* Helper: Return true iff buf contains s */ +static int +evbuffer_contains(struct evbuffer *buf, const char *s) +{ + struct evbuffer_ptr ptr; + ptr = evbuffer_search(buf, s, strlen(s), NULL); + return ptr.pos != -1; +} + +static void +http_readcb(struct bufferevent *bev, void *arg) +{ + const char *what = BASIC_REQUEST_BODY; + struct event_base *my_base = arg; + + if (evbuffer_contains(bufferevent_get_input(bev), what)) { + struct evhttp_request *req = evhttp_request_new(NULL, NULL); + enum message_read_status done; + + /* req->kind = EVHTTP_RESPONSE; */ + done = evhttp_parse_firstline_(req, bufferevent_get_input(bev)); + if (done != ALL_DATA_READ) + goto out; + + done = evhttp_parse_headers_(req, bufferevent_get_input(bev)); + if (done != ALL_DATA_READ) + goto out; + + if (done == 1 && + evhttp_find_header(evhttp_request_get_input_headers(req), + "Content-Type") != NULL) + test_ok++; + + out: + evhttp_request_free(req); + bufferevent_disable(bev, EV_READ); + if (exit_base) + event_base_loopexit(exit_base, NULL); + else if (my_base) + event_base_loopexit(my_base, NULL); + else { + fprintf(stderr, "No way to exit loop!\n"); + exit(1); + } + } +} + +static void +http_writecb(struct bufferevent *bev, void *arg) +{ + if (evbuffer_get_length(bufferevent_get_output(bev)) == 0) { + /* enable reading of the reply */ + bufferevent_enable(bev, EV_READ); + test_ok++; + } +} + +static void +http_errorcb(struct bufferevent *bev, short what, void *arg) +{ + test_ok = -2; + event_base_loopexit(arg, NULL); +} + +static int found_multi = 0; +static int found_multi2 = 0; + +static void +http_basic_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *evb = evbuffer_new(); + struct evhttp_connection *evcon; + int empty = evhttp_find_header(evhttp_request_get_input_headers(req), "Empty") != NULL; + event_debug(("%s: called\n", __func__)); + evbuffer_add_printf(evb, BASIC_REQUEST_BODY); + + evcon = evhttp_request_get_connection(req); + tt_assert(evhttp_connection_get_server(evcon) == http); + + /* For multi-line headers test */ + { + const char *multi = + evhttp_find_header(evhttp_request_get_input_headers(req),"X-Multi"); + if (multi) { + found_multi = !strcmp(multi,"aaaaaaaa a END"); + if (strcmp("END", multi + strlen(multi) - 3) == 0) + test_ok++; + if (evhttp_find_header(evhttp_request_get_input_headers(req), "X-Last")) + test_ok++; + } + } + { + const char *multi2 = + evhttp_find_header(evhttp_request_get_input_headers(req),"X-Multi-Extra-WS"); + if (multi2) { + found_multi2 = !strcmp(multi2,"libevent 2.1"); + } + } + + + /* injecting a bad content-length */ + if (evhttp_find_header(evhttp_request_get_input_headers(req), "X-Negative")) + evhttp_add_header(evhttp_request_get_output_headers(req), + "Content-Length", "-100"); + + /* allow sending of an empty reply */ + evhttp_send_reply(req, HTTP_OK, "Everything is fine", + !empty ? evb : NULL); + +end: + evbuffer_free(evb); +} + +static char const* const CHUNKS[] = { + "This is funny", + "but not hilarious.", + "bwv 1052" +}; + +struct chunk_req_state { + struct event_base *base; + struct evhttp_request *req; + int i; +}; + +static void +http_chunked_trickle_cb(evutil_socket_t fd, short events, void *arg) +{ + struct evbuffer *evb = evbuffer_new(); + struct chunk_req_state *state = arg; + struct timeval when = { 0, 0 }; + + evbuffer_add_printf(evb, "%s", CHUNKS[state->i]); + evhttp_send_reply_chunk(state->req, evb); + evbuffer_free(evb); + + if (++state->i < (int) (sizeof(CHUNKS)/sizeof(CHUNKS[0]))) { + event_base_once(state->base, -1, EV_TIMEOUT, + http_chunked_trickle_cb, state, &when); + } else { + evhttp_send_reply_end(state->req); + free(state); + } +} + +static void +http_chunked_cb(struct evhttp_request *req, void *arg) +{ + struct timeval when = { 0, 0 }; + struct chunk_req_state *state = malloc(sizeof(struct chunk_req_state)); + event_debug(("%s: called\n", __func__)); + if (state == NULL) { + fprintf(stderr, "Unable to allocate memory in http_chunked_cb()\n"); + exit(1); + } + + memset(state, 0, sizeof(struct chunk_req_state)); + state->req = req; + state->base = arg; + + if (strcmp(evhttp_request_get_uri(req), "/streamed") == 0) { + evhttp_add_header(evhttp_request_get_output_headers(req), "Content-Length", "39"); + } + + /* generate a chunked/streamed reply */ + evhttp_send_reply_start(req, HTTP_OK, "Everything is fine"); + + /* but trickle it across several iterations to ensure we're not + * assuming it comes all at once */ + event_base_once(arg, -1, EV_TIMEOUT, http_chunked_trickle_cb, state, &when); +} + +static void +http_complete_write(evutil_socket_t fd, short what, void *arg) +{ + struct bufferevent *bev = arg; + const char *http_request = "host\r\n" + "Connection: close\r\n" + "\r\n"; + bufferevent_write(bev, http_request, strlen(http_request)); +} + +static void +http_basic_test(void *arg) +{ + struct basic_test_data *data = arg; + struct timeval tv; + struct bufferevent *bev = NULL; + evutil_socket_t fd; + const char *http_request; + ev_uint16_t port = 0, port2 = 0; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + /* bind to a second socket */ + if (http_bind(http, &port2, 0) == -1) { + fprintf(stdout, "FAILED (bind)\n"); + exit(1); + } + + fd = http_connect("127.0.0.1", port); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_readcb, http_writecb, + http_errorcb, data->base); + + /* first half of the http request */ + http_request = + "GET /test HTTP/1.1\r\n" + "Host: some"; + + bufferevent_write(bev, http_request, strlen(http_request)); + evutil_timerclear(&tv); + tv.tv_usec = 10000; + event_base_once(data->base, + -1, EV_TIMEOUT, http_complete_write, bev, &tv); + + event_base_dispatch(data->base); + + tt_assert(test_ok == 3); + + /* connect to the second port */ + bufferevent_free(bev); + evutil_closesocket(fd); + + fd = http_connect("127.0.0.1", port2); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_readcb, http_writecb, + http_errorcb, data->base); + + http_request = + "GET /test HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + tt_assert(test_ok == 5); + + /* Connect to the second port again. This time, send an absolute uri. */ + bufferevent_free(bev); + evutil_closesocket(fd); + + fd = http_connect("127.0.0.1", port2); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_readcb, http_writecb, + http_errorcb, data->base); + + http_request = + "GET http://somehost.net/test HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + tt_assert(test_ok == 7); + + evhttp_free(http); + end: + if (bev) + bufferevent_free(bev); +} + + +static void +http_delay_reply(evutil_socket_t fd, short what, void *arg) +{ + struct evhttp_request *req = arg; + + evhttp_send_reply(req, HTTP_OK, "Everything is fine", NULL); + + ++test_ok; +} + +static void +http_delay_cb(struct evhttp_request *req, void *arg) +{ + struct timeval tv; + evutil_timerclear(&tv); + tv.tv_sec = 0; + tv.tv_usec = 200 * 1000; + + event_base_once(arg, -1, EV_TIMEOUT, http_delay_reply, req, &tv); +} + +static void +http_badreq_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *buf = evbuffer_new(); + + evhttp_add_header(evhttp_request_get_output_headers(req), "Content-Type", "text/xml; charset=UTF-8"); + evbuffer_add_printf(buf, "Hello, %s!", "127.0.0.1"); + + evhttp_send_reply(req, HTTP_OK, "OK", buf); + evbuffer_free(buf); +} + +static void +http_badreq_errorcb(struct bufferevent *bev, short what, void *arg) +{ + event_debug(("%s: called (what=%04x, arg=%p)", __func__, what, arg)); + /* ignore */ +} + +#ifndef SHUT_WR +#ifdef _WIN32 +#define SHUT_WR SD_SEND +#else +#define SHUT_WR 1 +#endif +#endif + +static void +http_badreq_readcb(struct bufferevent *bev, void *arg) +{ + const char *what = "Hello, 127.0.0.1"; + const char *bad_request = "400 Bad Request"; + + if (evbuffer_contains(bufferevent_get_input(bev), bad_request)) { + TT_FAIL(("%s:bad request detected", __func__)); + bufferevent_disable(bev, EV_READ); + event_base_loopexit(arg, NULL); + return; + } + + if (evbuffer_contains(bufferevent_get_input(bev), what)) { + struct evhttp_request *req = evhttp_request_new(NULL, NULL); + enum message_read_status done; + + /* req->kind = EVHTTP_RESPONSE; */ + done = evhttp_parse_firstline_(req, bufferevent_get_input(bev)); + if (done != ALL_DATA_READ) + goto out; + + done = evhttp_parse_headers_(req, bufferevent_get_input(bev)); + if (done != ALL_DATA_READ) + goto out; + + if (done == 1 && + evhttp_find_header(evhttp_request_get_input_headers(req), + "Content-Type") != NULL) + test_ok++; + + out: + evhttp_request_free(req); + evbuffer_drain(bufferevent_get_input(bev), evbuffer_get_length(bufferevent_get_input(bev))); + } + + shutdown(bufferevent_getfd(bev), SHUT_WR); +} + +static void +http_badreq_successcb(evutil_socket_t fd, short what, void *arg) +{ + event_debug(("%s: called (what=%04x, arg=%p)", __func__, what, arg)); + event_base_loopexit(exit_base, NULL); +} + +static void +http_bad_request_test(void *arg) +{ + struct basic_test_data *data = arg; + struct timeval tv; + struct bufferevent *bev = NULL; + evutil_socket_t fd = -1; + const char *http_request; + ev_uint16_t port=0, port2=0; + + test_ok = 0; + exit_base = data->base; + + http = http_setup(&port, data->base, 0); + + /* bind to a second socket */ + if (http_bind(http, &port2, 0) == -1) + TT_DIE(("Bind socket failed")); + + /* NULL request test */ + fd = http_connect("127.0.0.1", port); + tt_int_op(fd, >=, 0); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_badreq_readcb, http_writecb, + http_badreq_errorcb, data->base); + bufferevent_enable(bev, EV_READ); + + /* real NULL request */ + http_request = ""; + + bufferevent_write(bev, http_request, strlen(http_request)); + + shutdown(fd, SHUT_WR); + timerclear(&tv); + tv.tv_usec = 10000; + event_base_once(data->base, -1, EV_TIMEOUT, http_badreq_successcb, bev, &tv); + + event_base_dispatch(data->base); + + bufferevent_free(bev); + evutil_closesocket(fd); + + if (test_ok != 0) { + fprintf(stdout, "FAILED\n"); + exit(1); + } + + /* Second answer (BAD REQUEST) on connection close */ + + /* connect to the second port */ + fd = http_connect("127.0.0.1", port2); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_badreq_readcb, http_writecb, + http_badreq_errorcb, data->base); + bufferevent_enable(bev, EV_READ); + + /* first half of the http request */ + http_request = + "GET /badrequest HTTP/1.0\r\n" \ + "Connection: Keep-Alive\r\n" \ + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + timerclear(&tv); + tv.tv_usec = 10000; + event_base_once(data->base, -1, EV_TIMEOUT, http_badreq_successcb, bev, &tv); + + event_base_dispatch(data->base); + + tt_int_op(test_ok, ==, 2); + +end: + evhttp_free(http); + if (bev) + bufferevent_free(bev); + if (fd >= 0) + evutil_closesocket(fd); +} + +static struct evhttp_connection *delayed_client; + +static void +http_large_delay_cb(struct evhttp_request *req, void *arg) +{ + struct timeval tv; + evutil_timerclear(&tv); + tv.tv_usec = 500000; + + event_base_once(arg, -1, EV_TIMEOUT, http_delay_reply, req, &tv); + evhttp_connection_fail_(delayed_client, EVREQ_HTTP_EOF); +} + +/* + * HTTP DELETE test, just piggyback on the basic test + */ + +static void +http_delete_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *evb = evbuffer_new(); + int empty = evhttp_find_header(evhttp_request_get_input_headers(req), "Empty") != NULL; + + /* Expecting a DELETE request */ + if (evhttp_request_get_command(req) != EVHTTP_REQ_DELETE) { + fprintf(stdout, "FAILED (delete type)\n"); + exit(1); + } + + event_debug(("%s: called\n", __func__)); + evbuffer_add_printf(evb, BASIC_REQUEST_BODY); + + /* allow sending of an empty reply */ + evhttp_send_reply(req, HTTP_OK, "Everything is fine", + !empty ? evb : NULL); + + evbuffer_free(evb); +} + +static void +http_delete_test(void *arg) +{ + struct basic_test_data *data = arg; + struct bufferevent *bev; + evutil_socket_t fd = -1; + const char *http_request; + ev_uint16_t port = 0; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + tt_assert(http); + fd = http_connect("127.0.0.1", port); + tt_int_op(fd, >=, 0); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_readcb, http_writecb, + http_errorcb, data->base); + + http_request = + "DELETE /deleteit HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + bufferevent_free(bev); + evutil_closesocket(fd); + fd = -1; + + evhttp_free(http); + + tt_int_op(test_ok, ==, 2); + end: + if (fd >= 0) + evutil_closesocket(fd); +} + +static void +http_sent_cb(struct evhttp_request *req, void *arg) +{ + ev_uintptr_t val = (ev_uintptr_t)arg; + struct evbuffer *b; + + if (val != 0xDEADBEEF) { + fprintf(stdout, "FAILED on_complete_cb argument\n"); + exit(1); + } + + b = evhttp_request_get_output_buffer(req); + if (evbuffer_get_length(b) != 0) { + fprintf(stdout, "FAILED on_complete_cb output buffer not written\n"); + exit(1); + } + + event_debug(("%s: called\n", __func__)); + + ++test_ok; +} + +static void +http_on_complete_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *evb = evbuffer_new(); + + evhttp_request_set_on_complete_cb(req, http_sent_cb, (void *)0xDEADBEEF); + + event_debug(("%s: called\n", __func__)); + evbuffer_add_printf(evb, BASIC_REQUEST_BODY); + + /* allow sending of an empty reply */ + evhttp_send_reply(req, HTTP_OK, "Everything is fine", evb); + + evbuffer_free(evb); + + ++test_ok; +} + +static void +http_on_complete_test(void *arg) +{ + struct basic_test_data *data = arg; + struct bufferevent *bev; + evutil_socket_t fd = -1; + const char *http_request; + ev_uint16_t port = 0; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + fd = http_connect("127.0.0.1", port); + tt_int_op(fd, >=, 0); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_readcb, http_writecb, + http_errorcb, data->base); + + http_request = + "GET /oncomplete HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + bufferevent_free(bev); + + evhttp_free(http); + + tt_int_op(test_ok, ==, 4); + end: + if (fd >= 0) + evutil_closesocket(fd); +} + +static void +http_allowed_methods_eventcb(struct bufferevent *bev, short what, void *arg) +{ + char **output = arg; + if ((what & (BEV_EVENT_ERROR|BEV_EVENT_EOF))) { + char buf[4096]; + int n; + n = evbuffer_remove(bufferevent_get_input(bev), buf, + sizeof(buf)-1); + if (n >= 0) { + buf[n]='\0'; + if (*output) + free(*output); + *output = strdup(buf); + } + event_base_loopexit(exit_base, NULL); + } +} + +static void +http_allowed_methods_test(void *arg) +{ + struct basic_test_data *data = arg; + struct bufferevent *bev1, *bev2, *bev3; + evutil_socket_t fd1=-1, fd2=-1, fd3=-1; + const char *http_request; + char *result1=NULL, *result2=NULL, *result3=NULL; + ev_uint16_t port = 0; + + exit_base = data->base; + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + fd1 = http_connect("127.0.0.1", port); + tt_int_op(fd1, >=, 0); + + /* GET is out; PATCH is in. */ + evhttp_set_allowed_methods(http, EVHTTP_REQ_PATCH); + + /* Stupid thing to send a request */ + bev1 = bufferevent_socket_new(data->base, fd1, 0); + bufferevent_enable(bev1, EV_READ|EV_WRITE); + bufferevent_setcb(bev1, NULL, NULL, + http_allowed_methods_eventcb, &result1); + + http_request = + "GET /index.html HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev1, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + fd2 = http_connect("127.0.0.1", port); + tt_int_op(fd2, >=, 0); + + bev2 = bufferevent_socket_new(data->base, fd2, 0); + bufferevent_enable(bev2, EV_READ|EV_WRITE); + bufferevent_setcb(bev2, NULL, NULL, + http_allowed_methods_eventcb, &result2); + + http_request = + "PATCH /test HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev2, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + fd3 = http_connect("127.0.0.1", port); + tt_int_op(fd3, >=, 0); + + bev3 = bufferevent_socket_new(data->base, fd3, 0); + bufferevent_enable(bev3, EV_READ|EV_WRITE); + bufferevent_setcb(bev3, NULL, NULL, + http_allowed_methods_eventcb, &result3); + + http_request = + "FLOOP /test HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev3, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + bufferevent_free(bev1); + bufferevent_free(bev2); + bufferevent_free(bev3); + + evhttp_free(http); + + /* Method known but disallowed */ + tt_assert(result1); + tt_assert(!strncmp(result1, "HTTP/1.1 501 ", strlen("HTTP/1.1 501 "))); + + /* Method known and allowed */ + tt_assert(result2); + tt_assert(!strncmp(result2, "HTTP/1.1 200 ", strlen("HTTP/1.1 200 "))); + + /* Method unknown */ + tt_assert(result3); + tt_assert(!strncmp(result3, "HTTP/1.1 501 ", strlen("HTTP/1.1 501 "))); + + end: + if (result1) + free(result1); + if (result2) + free(result2); + if (result3) + free(result3); + if (fd1 >= 0) + evutil_closesocket(fd1); + if (fd2 >= 0) + evutil_closesocket(fd2); + if (fd3 >= 0) + evutil_closesocket(fd3); +} + +static void http_request_done(struct evhttp_request *, void *); +static void http_request_empty_done(struct evhttp_request *, void *); + +static void +http_connection_test_(struct basic_test_data *data, int persistent, + const char *address, struct evdns_base *dnsbase, int ipv6, int family) +{ + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + + test_ok = 0; + + http = http_setup(&port, data->base, ipv6); + if (!http && ipv6) { + tt_skip(); + } + tt_assert(http); + + evcon = evhttp_connection_base_new(data->base, dnsbase, address, port); + tt_assert(evcon); + evhttp_connection_set_family(evcon, family); + + tt_assert(evhttp_connection_get_base(evcon) == data->base); + + exit_base = data->base; + + tt_assert(evhttp_connection_get_server(evcon) == NULL); + + /* + * At this point, we want to schedule a request to the HTTP + * server using our make request method. + */ + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test") == -1) { + fprintf(stdout, "FAILED\n"); + exit(1); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok); + + /* try to make another request over the same connection */ + test_ok = 0; + + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* + * if our connections are not supposed to be persistent; request + * a close from the server. + */ + if (!persistent) + evhttp_add_header(evhttp_request_get_output_headers(req), "Connection", "close"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test") == -1) { + tt_abort_msg("couldn't make request"); + } + + event_base_dispatch(data->base); + + /* make another request: request empty reply */ + test_ok = 0; + + req = evhttp_request_new(http_request_empty_done, data->base); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Empty", "itis"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +static void +http_connection_test(void *arg) +{ + http_connection_test_(arg, 0, "127.0.0.1", NULL, 0, AF_UNSPEC); +} +static void +http_persist_connection_test(void *arg) +{ + http_connection_test_(arg, 1, "127.0.0.1", NULL, 0, AF_UNSPEC); +} + +static struct regress_dns_server_table search_table[] = { + { "localhost", "A", "127.0.0.1", 0 }, + { NULL, NULL, NULL, 0 } +}; + +static void +http_connection_async_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + struct evdns_base *dns_base = NULL; + ev_uint16_t portnum = 0; + char address[64]; + + exit_base = data->base; + tt_assert(regress_dnsserver(data->base, &portnum, search_table)); + + dns_base = evdns_base_new(data->base, 0/* init name servers */); + tt_assert(dns_base); + + /* Add ourself as the only nameserver, and make sure we really are + * the only nameserver. */ + evutil_snprintf(address, sizeof(address), "127.0.0.1:%d", portnum); + evdns_base_nameserver_ip_add(dns_base, address); + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, dns_base, "127.0.0.1", port); + tt_assert(evcon); + + /* + * At this point, we want to schedule a request to the HTTP + * server using our make request method. + */ + + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test") == -1) { + fprintf(stdout, "FAILED\n"); + exit(1); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok); + + /* try to make another request over the same connection */ + test_ok = 0; + + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* + * if our connections are not supposed to be persistent; request + * a close from the server. + */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Connection", "close"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test") == -1) { + tt_abort_msg("couldn't make request"); + } + + event_base_dispatch(data->base); + + /* make another request: request empty reply */ + test_ok = 0; + + req = evhttp_request_new(http_request_empty_done, data->base); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Empty", "itis"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); + if (dns_base) + evdns_base_free(dns_base, 0); + regress_clean_dnsserver(); +} + +static void +http_autofree_connection_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req[2] = { NULL }; + + test_ok = 0; + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* + * At this point, we want to schedule two request to the HTTP + * server using our make request method. + */ + req[0] = evhttp_request_new(http_request_empty_done, data->base); + req[1] = evhttp_request_new(http_request_empty_done, data->base); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req[0]), "Host", "somehost"); + evhttp_add_header(evhttp_request_get_output_headers(req[0]), "Connection", "close"); + evhttp_add_header(evhttp_request_get_output_headers(req[0]), "Empty", "itis"); + evhttp_add_header(evhttp_request_get_output_headers(req[1]), "Host", "somehost"); + evhttp_add_header(evhttp_request_get_output_headers(req[1]), "Connection", "close"); + evhttp_add_header(evhttp_request_get_output_headers(req[1]), "Empty", "itis"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req[0], EVHTTP_REQ_GET, "/test") == -1) { + tt_abort_msg("couldn't make request"); + } + if (evhttp_make_request(evcon, req[1], EVHTTP_REQ_GET, "/test") == -1) { + tt_abort_msg("couldn't make request"); + } + + /* + * Tell libevent to free the connection when the request completes + * We then set the evcon pointer to NULL since we don't want to free it + * when this function ends. + */ + evhttp_connection_free_on_completion(evcon); + evcon = NULL; + + event_base_dispatch(data->base); + + /* at this point, the http server should have no connection */ + tt_assert(TAILQ_FIRST(&http->connections) == NULL); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +static void +http_request_never_call(struct evhttp_request *req, void *arg) +{ + fprintf(stdout, "FAILED\n"); + exit(1); +} + +static void +http_do_cancel(evutil_socket_t fd, short what, void *arg) +{ + struct evhttp_request *req = arg; + struct timeval tv; + struct event_base *base; + evutil_timerclear(&tv); + tv.tv_sec = 0; + tv.tv_usec = 500 * 1000; + + base = evhttp_connection_get_base(evhttp_request_get_connection(req)); + evhttp_cancel_request(req); + + event_base_loopexit(base, &tv); + + ++test_ok; +} + +static void +http_cancel_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + struct timeval tv; + + exit_base = data->base; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* + * At this point, we want to schedule a request to the HTTP + * server using our make request method. + */ + + req = evhttp_request_new(http_request_never_call, NULL); + evhttp_request_set_error_cb(req, http_request_error_cb_with_cancel_); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + tt_int_op(evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/delay"), + !=, -1); + + evutil_timerclear(&tv); + tv.tv_sec = 0; + tv.tv_usec = 100 * 1000; + + event_base_once(data->base, -1, EV_TIMEOUT, http_do_cancel, req, &tv); + + event_base_dispatch(data->base); + + tt_int_op(test_ok, ==, 3); + + /* try to make another request over the same connection */ + test_ok = 0; + + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + tt_int_op(evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test"), + !=, -1); + + event_base_dispatch(data->base); + + /* make another request: request empty reply */ + test_ok = 0; + + req = evhttp_request_new(http_request_empty_done, data->base); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Empty", "itis"); + + /* We give ownership of the request to the connection */ + tt_int_op(evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test"), + !=, -1); + + event_base_dispatch(data->base); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +static void +http_request_done(struct evhttp_request *req, void *arg) +{ + const char *what = arg; + + if (evhttp_request_get_response_code(req) != HTTP_OK) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evhttp_find_header(evhttp_request_get_input_headers(req), "Content-Type") == NULL) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != strlen(what)) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evbuffer_datacmp(evhttp_request_get_input_buffer(req), what) != 0) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + test_ok = 1; + EVUTIL_ASSERT(exit_base); + event_base_loopexit(exit_base, NULL); +} + +static void +http_request_expect_error(struct evhttp_request *req, void *arg) +{ + if (evhttp_request_get_response_code(req) == HTTP_OK) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + test_ok = 1; + EVUTIL_ASSERT(arg); + event_base_loopexit(arg, NULL); +} + +/* test virtual hosts */ +static void +http_virtual_host_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + struct evhttp *second = NULL, *third = NULL; + evutil_socket_t fd; + struct bufferevent *bev; + const char *http_request; + + exit_base = data->base; + + http = http_setup(&port, data->base, 0); + + /* virtual host */ + second = evhttp_new(NULL); + evhttp_set_cb(second, "/funnybunny", http_basic_cb, NULL); + third = evhttp_new(NULL); + evhttp_set_cb(third, "/blackcoffee", http_basic_cb, NULL); + + if (evhttp_add_virtual_host(http, "foo.com", second) == -1) { + tt_abort_msg("Couldn't add vhost"); + } + + if (evhttp_add_virtual_host(http, "bar.*.foo.com", third) == -1) { + tt_abort_msg("Couldn't add wildcarded vhost"); + } + + /* add some aliases to the vhosts */ + tt_assert(evhttp_add_server_alias(second, "manolito.info") == 0); + tt_assert(evhttp_add_server_alias(third, "bonkers.org") == 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* make a request with a different host and expect an error */ + req = evhttp_request_new(http_request_expect_error, data->base); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/funnybunny") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok == 1); + + test_ok = 0; + + /* make a request with the right host and expect a response */ + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "foo.com"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/funnybunny") == -1) { + fprintf(stdout, "FAILED\n"); + exit(1); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok == 1); + + test_ok = 0; + + /* make a request with the right host and expect a response */ + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "bar.magic.foo.com"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/blackcoffee") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok == 1) + + test_ok = 0; + + /* make a request with the right host and expect a response */ + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "manolito.info"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/funnybunny") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok == 1) + + test_ok = 0; + + /* make a request with the right host and expect a response */ + req = evhttp_request_new(http_request_done, (void*) BASIC_REQUEST_BODY); + + /* Add the Host header. This time with the optional port. */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "bonkers.org:8000"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/blackcoffee") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok == 1) + + test_ok = 0; + + /* Now make a raw request with an absolute URI. */ + fd = http_connect("127.0.0.1", port); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_readcb, http_writecb, + http_errorcb, NULL); + + /* The host in the URI should override the Host: header */ + http_request = + "GET http://manolito.info/funnybunny HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + tt_int_op(test_ok, ==, 2); + + bufferevent_free(bev); + evutil_closesocket(fd); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + + +/* test date header and content length */ + +static void +http_request_empty_done(struct evhttp_request *req, void *arg) +{ + if (evhttp_request_get_response_code(req) != HTTP_OK) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evhttp_find_header(evhttp_request_get_input_headers(req), "Date") == NULL) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + + if (evhttp_find_header(evhttp_request_get_input_headers(req), "Content-Length") == NULL) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (strcmp(evhttp_find_header(evhttp_request_get_input_headers(req), "Content-Length"), + "0")) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != 0) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + test_ok = 1; + EVUTIL_ASSERT(arg); + event_base_loopexit(arg, NULL); +} + +/* + * HTTP DISPATCHER test + */ + +void +http_dispatcher_cb(struct evhttp_request *req, void *arg) +{ + + struct evbuffer *evb = evbuffer_new(); + event_debug(("%s: called\n", __func__)); + evbuffer_add_printf(evb, "DISPATCHER_TEST"); + + evhttp_send_reply(req, HTTP_OK, "Everything is fine", evb); + + evbuffer_free(evb); +} + +static void +http_dispatcher_test_done(struct evhttp_request *req, void *arg) +{ + struct event_base *base = arg; + const char *what = "DISPATCHER_TEST"; + + if (evhttp_request_get_response_code(req) != HTTP_OK) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evhttp_find_header(evhttp_request_get_input_headers(req), "Content-Type") == NULL) { + fprintf(stderr, "FAILED (content type)\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != strlen(what)) { + fprintf(stderr, "FAILED (length %lu vs %lu)\n", + (unsigned long)evbuffer_get_length(evhttp_request_get_input_buffer(req)), (unsigned long)strlen(what)); + exit(1); + } + + if (evbuffer_datacmp(evhttp_request_get_input_buffer(req), what) != 0) { + fprintf(stderr, "FAILED (data)\n"); + exit(1); + } + + test_ok = 1; + event_base_loopexit(base, NULL); +} + +static void +http_dispatcher_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* also bind to local host */ + evhttp_connection_set_local_address(evcon, "127.0.0.1"); + + /* + * At this point, we want to schedule an HTTP GET request + * server using our make request method. + */ + + req = evhttp_request_new(http_dispatcher_test_done, data->base); + tt_assert(req); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/?arg=val") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +/* + * HTTP POST test. + */ + +void http_postrequest_done(struct evhttp_request *, void *); + +#define POST_DATA "Okay. Not really printf" + +static void +http_post_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* + * At this point, we want to schedule an HTTP POST request + * server using our make request method. + */ + + req = evhttp_request_new(http_postrequest_done, data->base); + tt_assert(req); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + evbuffer_add_printf(evhttp_request_get_output_buffer(req), POST_DATA); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_POST, "/postit") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_int_op(test_ok, ==, 1); + + test_ok = 0; + + req = evhttp_request_new(http_postrequest_done, data->base); + tt_assert(req); + + /* Now try with 100-continue. */ + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + evhttp_add_header(evhttp_request_get_output_headers(req), "Expect", "100-continue"); + evbuffer_add_printf(evhttp_request_get_output_buffer(req), POST_DATA); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_POST, "/postit") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_int_op(test_ok, ==, 1); + + evhttp_connection_free(evcon); + evhttp_free(http); + + end: + ; +} + +void +http_post_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *evb; + event_debug(("%s: called\n", __func__)); + + /* Yes, we are expecting a post request */ + if (evhttp_request_get_command(req) != EVHTTP_REQ_POST) { + fprintf(stdout, "FAILED (post type)\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != strlen(POST_DATA)) { + fprintf(stdout, "FAILED (length: %lu vs %lu)\n", + (unsigned long) evbuffer_get_length(evhttp_request_get_input_buffer(req)), (unsigned long) strlen(POST_DATA)); + exit(1); + } + + if (evbuffer_datacmp(evhttp_request_get_input_buffer(req), POST_DATA) != 0) { + fprintf(stdout, "FAILED (data)\n"); + fprintf(stdout, "Got :%s\n", evbuffer_pullup(evhttp_request_get_input_buffer(req),-1)); + fprintf(stdout, "Want:%s\n", POST_DATA); + exit(1); + } + + evb = evbuffer_new(); + evbuffer_add_printf(evb, BASIC_REQUEST_BODY); + + evhttp_send_reply(req, HTTP_OK, "Everything is fine", evb); + + evbuffer_free(evb); +} + +void +http_postrequest_done(struct evhttp_request *req, void *arg) +{ + const char *what = BASIC_REQUEST_BODY; + struct event_base *base = arg; + + if (req == NULL) { + fprintf(stderr, "FAILED (timeout)\n"); + exit(1); + } + + if (evhttp_request_get_response_code(req) != HTTP_OK) { + + fprintf(stderr, "FAILED (response code)\n"); + exit(1); + } + + if (evhttp_find_header(evhttp_request_get_input_headers(req), "Content-Type") == NULL) { + fprintf(stderr, "FAILED (content type)\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != strlen(what)) { + fprintf(stderr, "FAILED (length %lu vs %lu)\n", + (unsigned long)evbuffer_get_length(evhttp_request_get_input_buffer(req)), (unsigned long)strlen(what)); + exit(1); + } + + if (evbuffer_datacmp(evhttp_request_get_input_buffer(req), what) != 0) { + fprintf(stderr, "FAILED (data)\n"); + exit(1); + } + + test_ok = 1; + event_base_loopexit(base, NULL); +} + +/* + * HTTP PUT test, basically just like POST, but ... + */ + +void http_putrequest_done(struct evhttp_request *, void *); + +#define PUT_DATA "Hi, I'm some PUT data" + +static void +http_put_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* + * Schedule the HTTP PUT request + */ + + req = evhttp_request_new(http_putrequest_done, data->base); + tt_assert(req); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "someotherhost"); + evbuffer_add_printf(evhttp_request_get_output_buffer(req), PUT_DATA); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_PUT, "/putit") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + evhttp_connection_free(evcon); + evhttp_free(http); + + tt_int_op(test_ok, ==, 1); + end: + ; +} + +void +http_put_cb(struct evhttp_request *req, void *arg) +{ + struct evbuffer *evb; + event_debug(("%s: called\n", __func__)); + + /* Expecting a PUT request */ + if (evhttp_request_get_command(req) != EVHTTP_REQ_PUT) { + fprintf(stdout, "FAILED (put type)\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != strlen(PUT_DATA)) { + fprintf(stdout, "FAILED (length: %lu vs %lu)\n", + (unsigned long)evbuffer_get_length(evhttp_request_get_input_buffer(req)), (unsigned long)strlen(PUT_DATA)); + exit(1); + } + + if (evbuffer_datacmp(evhttp_request_get_input_buffer(req), PUT_DATA) != 0) { + fprintf(stdout, "FAILED (data)\n"); + fprintf(stdout, "Got :%s\n", evbuffer_pullup(evhttp_request_get_input_buffer(req),-1)); + fprintf(stdout, "Want:%s\n", PUT_DATA); + exit(1); + } + + evb = evbuffer_new(); + evbuffer_add_printf(evb, "That ain't funny"); + + evhttp_send_reply(req, HTTP_OK, "Everything is great", evb); + + evbuffer_free(evb); +} + +void +http_putrequest_done(struct evhttp_request *req, void *arg) +{ + struct event_base *base = arg; + const char *what = "That ain't funny"; + + if (req == NULL) { + fprintf(stderr, "FAILED (timeout)\n"); + exit(1); + } + + if (evhttp_request_get_response_code(req) != HTTP_OK) { + + fprintf(stderr, "FAILED (response code)\n"); + exit(1); + } + + if (evhttp_find_header(evhttp_request_get_input_headers(req), "Content-Type") == NULL) { + fprintf(stderr, "FAILED (content type)\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != strlen(what)) { + fprintf(stderr, "FAILED (length %lu vs %lu)\n", + (unsigned long)evbuffer_get_length(evhttp_request_get_input_buffer(req)), (unsigned long)strlen(what)); + exit(1); + } + + + if (evbuffer_datacmp(evhttp_request_get_input_buffer(req), what) != 0) { + fprintf(stderr, "FAILED (data)\n"); + exit(1); + } + + test_ok = 1; + event_base_loopexit(base, NULL); +} + +static void +http_failure_readcb(struct bufferevent *bev, void *arg) +{ + const char *what = "400 Bad Request"; + if (evbuffer_contains(bufferevent_get_input(bev), what)) { + test_ok = 2; + bufferevent_disable(bev, EV_READ); + event_base_loopexit(arg, NULL); + } +} + +/* + * Testing that the HTTP server can deal with a malformed request. + */ +static void +http_failure_test(void *arg) +{ + struct basic_test_data *data = arg; + struct bufferevent *bev; + evutil_socket_t fd = -1; + const char *http_request; + ev_uint16_t port = 0; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + fd = http_connect("127.0.0.1", port); + tt_int_op(fd, >=, 0); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, http_failure_readcb, http_writecb, + http_errorcb, data->base); + + http_request = "illegal request\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + event_base_dispatch(data->base); + + bufferevent_free(bev); + + evhttp_free(http); + + tt_int_op(test_ok, ==, 2); + end: + if (fd >= 0) + evutil_closesocket(fd); +} + +static void +close_detect_done(struct evhttp_request *req, void *arg) +{ + struct timeval tv; + tt_assert(req); + tt_assert(evhttp_request_get_response_code(req) == HTTP_OK); + + test_ok = 1; + + end: + evutil_timerclear(&tv); + tv.tv_usec = 150000; + event_base_loopexit(arg, &tv); +} + +static void +close_detect_launch(evutil_socket_t fd, short what, void *arg) +{ + struct evhttp_connection *evcon = arg; + struct event_base *base = evhttp_connection_get_base(evcon); + struct evhttp_request *req; + + req = evhttp_request_new(close_detect_done, base); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/test") == -1) { + tt_fail_msg("Couldn't make request"); + } +} + +static void +close_detect_cb(struct evhttp_request *req, void *arg) +{ + struct evhttp_connection *evcon = arg; + struct event_base *base = evhttp_connection_get_base(evcon); + struct timeval tv; + + if (req != NULL && evhttp_request_get_response_code(req) != HTTP_OK) { + tt_abort_msg("Failed"); + } + + evutil_timerclear(&tv); + tv.tv_sec = 0; /* longer than the http time out */ + tv.tv_usec = 600000; /* longer than the http time out */ + + /* launch a new request on the persistent connection in .3 seconds */ + event_base_once(base, -1, EV_TIMEOUT, close_detect_launch, evcon, &tv); + end: + ; +} + + +static void +http_close_detection_(struct basic_test_data *data, int with_delay) +{ + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + const struct timeval sec_tenth = { 0, 100000 }; + + test_ok = 0; + http = http_setup(&port, data->base, 0); + + /* .1 second timeout */ + evhttp_set_timeout_tv(http, &sec_tenth); + + evcon = evhttp_connection_base_new(data->base, NULL, + "127.0.0.1", port); + tt_assert(evcon); + evhttp_connection_set_timeout_tv(evcon, &sec_tenth); + + + tt_assert(evcon); + delayed_client = evcon; + + /* + * At this point, we want to schedule a request to the HTTP + * server using our make request method. + */ + + req = evhttp_request_new(close_detect_cb, evcon); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, + req, EVHTTP_REQ_GET, with_delay ? "/largedelay" : "/test") == -1) { + tt_abort_msg("couldn't make request"); + } + + event_base_dispatch(data->base); + + /* at this point, the http server should have no connection */ + tt_assert(TAILQ_FIRST(&http->connections) == NULL); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} +static void +http_close_detection_test(void *arg) +{ + http_close_detection_(arg, 0); +} +static void +http_close_detection_delay_test(void *arg) +{ + http_close_detection_(arg, 1); +} + +static void +http_highport_test(void *arg) +{ + struct basic_test_data *data = arg; + int i = -1; + struct evhttp *myhttp = NULL; + + /* Try a few different ports */ + for (i = 0; i < 50; ++i) { + myhttp = evhttp_new(data->base); + if (evhttp_bind_socket(myhttp, "127.0.0.1", 65535 - i) == 0) { + test_ok = 1; + evhttp_free(myhttp); + return; + } + evhttp_free(myhttp); + } + + tt_fail_msg("Couldn't get a high port"); +} + +static void +http_bad_header_test(void *ptr) +{ + struct evkeyvalq headers; + + TAILQ_INIT(&headers); + + tt_want(evhttp_add_header(&headers, "One", "Two") == 0); + tt_want(evhttp_add_header(&headers, "One", "Two\r\n Three") == 0); + tt_want(evhttp_add_header(&headers, "One\r", "Two") == -1); + tt_want(evhttp_add_header(&headers, "One\n", "Two") == -1); + tt_want(evhttp_add_header(&headers, "One", "Two\r") == -1); + tt_want(evhttp_add_header(&headers, "One", "Two\n") == -1); + + evhttp_clear_headers(&headers); +} + +static int validate_header( + const struct evkeyvalq* headers, + const char *key, const char *value) +{ + const char *real_val = evhttp_find_header(headers, key); + tt_assert(real_val != NULL); + tt_want(strcmp(real_val, value) == 0); +end: + return (0); +} + +static void +http_parse_query_test(void *ptr) +{ + struct evkeyvalq headers; + int r; + + TAILQ_INIT(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test", &headers); + tt_want(validate_header(&headers, "q", "test") == 0); + tt_int_op(r, ==, 0); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test&foo=bar", &headers); + tt_want(validate_header(&headers, "q", "test") == 0); + tt_want(validate_header(&headers, "foo", "bar") == 0); + tt_int_op(r, ==, 0); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test+foo", &headers); + tt_want(validate_header(&headers, "q", "test foo") == 0); + tt_int_op(r, ==, 0); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test%0Afoo", &headers); + tt_want(validate_header(&headers, "q", "test\nfoo") == 0); + tt_int_op(r, ==, 0); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test%0Dfoo", &headers); + tt_want(validate_header(&headers, "q", "test\rfoo") == 0); + tt_int_op(r, ==, 0); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test&&q2", &headers); + tt_int_op(r, ==, -1); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test+this", &headers); + tt_want(validate_header(&headers, "q", "test this") == 0); + tt_int_op(r, ==, 0); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=test&q2=foo", &headers); + tt_int_op(r, ==, 0); + tt_want(validate_header(&headers, "q", "test") == 0); + tt_want(validate_header(&headers, "q2", "foo") == 0); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q&q2=foo", &headers); + tt_int_op(r, ==, -1); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=foo&q2", &headers); + tt_int_op(r, ==, -1); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=foo&q2&q3=x", &headers); + tt_int_op(r, ==, -1); + evhttp_clear_headers(&headers); + + r = evhttp_parse_query("http://www.test.com/?q=&q2=&q3=", &headers); + tt_int_op(r, ==, 0); + tt_want(validate_header(&headers, "q", "") == 0); + tt_want(validate_header(&headers, "q2", "") == 0); + tt_want(validate_header(&headers, "q3", "") == 0); + evhttp_clear_headers(&headers); + +end: + evhttp_clear_headers(&headers); +} + +static void +http_parse_uri_test(void *ptr) +{ + const int nonconform = (ptr != NULL); + const unsigned parse_flags = + nonconform ? EVHTTP_URI_NONCONFORMANT : 0; + struct evhttp_uri *uri = NULL; + char url_tmp[4096]; +#define URI_PARSE(uri) \ + evhttp_uri_parse_with_flags((uri), parse_flags) + +#define TT_URI(want) do { \ + char *ret = evhttp_uri_join(uri, url_tmp, sizeof(url_tmp)); \ + tt_want(ret != NULL); \ + tt_want(ret == url_tmp); \ + if (strcmp(ret,want) != 0) \ + TT_FAIL(("\"%s\" != \"%s\"",ret,want)); \ + } while(0) + + tt_want(evhttp_uri_join(NULL, 0, 0) == NULL); + tt_want(evhttp_uri_join(NULL, url_tmp, 0) == NULL); + tt_want(evhttp_uri_join(NULL, url_tmp, sizeof(url_tmp)) == NULL); + + /* bad URIs: parsing */ +#define BAD(s) do { \ + if (URI_PARSE(s) != NULL) \ + TT_FAIL(("Expected error parsing \"%s\"",s)); \ + } while(0) + /* Nonconformant URIs we can parse: parsing */ +#define NCF(s) do { \ + uri = URI_PARSE(s); \ + if (uri != NULL && !nonconform) { \ + TT_FAIL(("Expected error parsing \"%s\"",s)); \ + } else if (uri == NULL && nonconform) { \ + TT_FAIL(("Couldn't parse nonconformant URI \"%s\"", \ + s)); \ + } \ + if (uri) { \ + tt_want(evhttp_uri_join(uri, url_tmp, \ + sizeof(url_tmp))); \ + evhttp_uri_free(uri); \ + } \ + } while(0) + + NCF("http://www.test.com/ why hello"); + NCF("http://www.test.com/why-hello\x01"); + NCF("http://www.test.com/why-hello?\x01"); + NCF("http://www.test.com/why-hello#\x01"); + BAD("http://www.\x01.test.com/why-hello"); + BAD("http://www.%7test.com/why-hello"); + NCF("http://www.test.com/why-hell%7o"); + BAD("h%3ttp://www.test.com/why-hello"); + NCF("http://www.test.com/why-hello%7"); + NCF("http://www.test.com/why-hell%7o"); + NCF("http://www.test.com/foo?ba%r"); + NCF("http://www.test.com/foo#ba%r"); + BAD("99:99/foo"); + BAD("http://www.test.com:999x/"); + BAD("http://www.test.com:x/"); + BAD("http://[hello-there]/"); + BAD("http://[::1]]/"); + BAD("http://[::1/"); + BAD("http://[foob/"); + BAD("http://[/"); + BAD("http://[ffff:ffff:ffff:ffff:Ffff:ffff:ffff:" + "ffff:ffff:ffff:ffff:ffff:ffff:ffff]/"); + BAD("http://[vX.foo]/"); + BAD("http://[vX.foo]/"); + BAD("http://[v.foo]/"); + BAD("http://[v5.fo%o]/"); + BAD("http://[v5X]/"); + BAD("http://[v5]/"); + BAD("http://[]/"); + BAD("http://f\x01red@www.example.com/"); + BAD("http://f%0red@www.example.com/"); + BAD("http://www.example.com:9999999999999999999999999999999999999/"); + BAD("http://www.example.com:hihi/"); + BAD("://www.example.com/"); + + /* bad URIs: joining */ + uri = evhttp_uri_new(); + tt_want(0==evhttp_uri_set_host(uri, "www.example.com")); + tt_want(evhttp_uri_join(uri, url_tmp, sizeof(url_tmp)) != NULL); + /* not enough space: */ + tt_want(evhttp_uri_join(uri, url_tmp, 3) == NULL); + /* host is set, but path doesn't start with "/": */ + tt_want(0==evhttp_uri_set_path(uri, "hi_mom")); + tt_want(evhttp_uri_join(uri, url_tmp, sizeof(url_tmp)) == NULL); + tt_want(evhttp_uri_join(uri, NULL, sizeof(url_tmp))==NULL); + tt_want(evhttp_uri_join(uri, url_tmp, 0)==NULL); + evhttp_uri_free(uri); + uri = URI_PARSE("mailto:foo@bar"); + tt_want(uri != NULL); + tt_want(evhttp_uri_get_host(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(!strcmp(evhttp_uri_get_scheme(uri), "mailto")); + tt_want(!strcmp(evhttp_uri_get_path(uri), "foo@bar")); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("mailto:foo@bar"); + evhttp_uri_free(uri); + + uri = evhttp_uri_new(); + /* Bad URI usage: setting invalid values */ + tt_want(-1 == evhttp_uri_set_scheme(uri,"")); + tt_want(-1 == evhttp_uri_set_scheme(uri,"33")); + tt_want(-1 == evhttp_uri_set_scheme(uri,"hi!")); + tt_want(-1 == evhttp_uri_set_userinfo(uri,"hello@")); + tt_want(-1 == evhttp_uri_set_host(uri,"[1.2.3.4]")); + tt_want(-1 == evhttp_uri_set_host(uri,"[")); + tt_want(-1 == evhttp_uri_set_host(uri,"www.[foo].com")); + tt_want(-1 == evhttp_uri_set_port(uri,-3)); + tt_want(-1 == evhttp_uri_set_path(uri,"hello?world")); + tt_want(-1 == evhttp_uri_set_query(uri,"hello#world")); + tt_want(-1 == evhttp_uri_set_fragment(uri,"hello#world")); + /* Valid URI usage: setting valid values */ + tt_want(0 == evhttp_uri_set_scheme(uri,"http")); + tt_want(0 == evhttp_uri_set_scheme(uri,NULL)); + tt_want(0 == evhttp_uri_set_userinfo(uri,"username:pass")); + tt_want(0 == evhttp_uri_set_userinfo(uri,NULL)); + tt_want(0 == evhttp_uri_set_host(uri,"www.example.com")); + tt_want(0 == evhttp_uri_set_host(uri,"1.2.3.4")); + tt_want(0 == evhttp_uri_set_host(uri,"[1:2:3:4::]")); + tt_want(0 == evhttp_uri_set_host(uri,"[v7.wobblewobble]")); + tt_want(0 == evhttp_uri_set_host(uri,NULL)); + tt_want(0 == evhttp_uri_set_host(uri,"")); + tt_want(0 == evhttp_uri_set_port(uri, -1)); + tt_want(0 == evhttp_uri_set_port(uri, 80)); + tt_want(0 == evhttp_uri_set_port(uri, 65535)); + tt_want(0 == evhttp_uri_set_path(uri, "")); + tt_want(0 == evhttp_uri_set_path(uri, "/documents/public/index.html")); + tt_want(0 == evhttp_uri_set_path(uri, NULL)); + tt_want(0 == evhttp_uri_set_query(uri, "key=val&key2=val2")); + tt_want(0 == evhttp_uri_set_query(uri, "keyvalblarg")); + tt_want(0 == evhttp_uri_set_query(uri, "")); + tt_want(0 == evhttp_uri_set_query(uri, NULL)); + tt_want(0 == evhttp_uri_set_fragment(uri, "")); + tt_want(0 == evhttp_uri_set_fragment(uri, "here?i?am")); + tt_want(0 == evhttp_uri_set_fragment(uri, NULL)); + evhttp_uri_free(uri); + + /* Valid parsing */ + uri = URI_PARSE("http://www.test.com/?q=t%33est"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "www.test.com") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=t%33est") == 0); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("http://www.test.com/?q=t%33est"); + evhttp_uri_free(uri); + + uri = URI_PARSE("http://%77ww.test.com"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "%77ww.test.com") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("http://%77ww.test.com"); + evhttp_uri_free(uri); + + uri = URI_PARSE("http://www.test.com?q=test"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "www.test.com") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=test") == 0); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("http://www.test.com?q=test"); + evhttp_uri_free(uri); + + uri = URI_PARSE("http://www.test.com#fragment"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "www.test.com") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want_str_op(evhttp_uri_get_fragment(uri), ==, "fragment"); + TT_URI("http://www.test.com#fragment"); + evhttp_uri_free(uri); + + uri = URI_PARSE("http://8000/"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "8000") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("http://8000/"); + evhttp_uri_free(uri); + + uri = URI_PARSE("http://:8000/"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == 8000); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("http://:8000/"); + evhttp_uri_free(uri); + + uri = URI_PARSE("http://www.test.com:/"); /* empty port */ + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "www.test.com") == 0); + tt_want_str_op(evhttp_uri_get_path(uri), ==, "/"); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("http://www.test.com/"); + evhttp_uri_free(uri); + + uri = URI_PARSE("http://www.test.com:"); /* empty port 2 */ + tt_want(strcmp(evhttp_uri_get_scheme(uri), "http") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "www.test.com") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("http://www.test.com"); + evhttp_uri_free(uri); + + uri = URI_PARSE("ftp://www.test.com/?q=test"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "ftp") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "www.test.com") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=test") == 0); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("ftp://www.test.com/?q=test"); + evhttp_uri_free(uri); + + uri = URI_PARSE("ftp://[::1]:999/?q=test"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "ftp") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "[::1]") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=test") == 0); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == 999); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("ftp://[::1]:999/?q=test"); + evhttp_uri_free(uri); + + uri = URI_PARSE("ftp://[ff00::127.0.0.1]/?q=test"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "ftp") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "[ff00::127.0.0.1]") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=test") == 0); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("ftp://[ff00::127.0.0.1]/?q=test"); + evhttp_uri_free(uri); + + uri = URI_PARSE("ftp://[v99.not_(any:time)_soon]/?q=test"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "ftp") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "[v99.not_(any:time)_soon]") == 0); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=test") == 0); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("ftp://[v99.not_(any:time)_soon]/?q=test"); + evhttp_uri_free(uri); + + uri = URI_PARSE("scheme://user:pass@foo.com:42/?q=test&s=some+thing#fragment"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "scheme") == 0); + tt_want(strcmp(evhttp_uri_get_userinfo(uri), "user:pass") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "foo.com") == 0); + tt_want(evhttp_uri_get_port(uri) == 42); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=test&s=some+thing") == 0); + tt_want(strcmp(evhttp_uri_get_fragment(uri), "fragment") == 0); + TT_URI("scheme://user:pass@foo.com:42/?q=test&s=some+thing#fragment"); + evhttp_uri_free(uri); + + uri = URI_PARSE("scheme://user@foo.com/#fragment"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "scheme") == 0); + tt_want(strcmp(evhttp_uri_get_userinfo(uri), "user") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "foo.com") == 0); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(strcmp(evhttp_uri_get_fragment(uri), "fragment") == 0); + TT_URI("scheme://user@foo.com/#fragment"); + evhttp_uri_free(uri); + + uri = URI_PARSE("scheme://%75ser@foo.com/#frag@ment"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "scheme") == 0); + tt_want(strcmp(evhttp_uri_get_userinfo(uri), "%75ser") == 0); + tt_want(strcmp(evhttp_uri_get_host(uri), "foo.com") == 0); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "/") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(strcmp(evhttp_uri_get_fragment(uri), "frag@ment") == 0); + TT_URI("scheme://%75ser@foo.com/#frag@ment"); + evhttp_uri_free(uri); + + uri = URI_PARSE("file:///some/path/to/the/file"); + tt_want(strcmp(evhttp_uri_get_scheme(uri), "file") == 0); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(strcmp(evhttp_uri_get_host(uri), "") == 0); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "/some/path/to/the/file") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("file:///some/path/to/the/file"); + evhttp_uri_free(uri); + + uri = URI_PARSE("///some/path/to/the-file"); + tt_want(uri != NULL); + tt_want(evhttp_uri_get_scheme(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(strcmp(evhttp_uri_get_host(uri), "") == 0); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "/some/path/to/the-file") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("///some/path/to/the-file"); + evhttp_uri_free(uri); + + uri = URI_PARSE("/s:ome/path/to/the-file?q=99#fred"); + tt_want(uri != NULL); + tt_want(evhttp_uri_get_scheme(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_host(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "/s:ome/path/to/the-file") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=99") == 0); + tt_want(strcmp(evhttp_uri_get_fragment(uri), "fred") == 0); + TT_URI("/s:ome/path/to/the-file?q=99#fred"); + evhttp_uri_free(uri); + + uri = URI_PARSE("relative/path/with/co:lon"); + tt_want(uri != NULL); + tt_want(evhttp_uri_get_scheme(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_host(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "relative/path/with/co:lon") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(evhttp_uri_get_fragment(uri) == NULL); + TT_URI("relative/path/with/co:lon"); + evhttp_uri_free(uri); + + uri = URI_PARSE("bob?q=99&q2=q?33#fr?ed"); + tt_want(uri != NULL); + tt_want(evhttp_uri_get_scheme(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_host(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "bob") == 0); + tt_want(strcmp(evhttp_uri_get_query(uri), "q=99&q2=q?33") == 0); + tt_want(strcmp(evhttp_uri_get_fragment(uri), "fr?ed") == 0); + TT_URI("bob?q=99&q2=q?33#fr?ed"); + evhttp_uri_free(uri); + + uri = URI_PARSE("#fr?ed"); + tt_want(uri != NULL); + tt_want(evhttp_uri_get_scheme(uri) == NULL); + tt_want(evhttp_uri_get_userinfo(uri) == NULL); + tt_want(evhttp_uri_get_host(uri) == NULL); + tt_want(evhttp_uri_get_port(uri) == -1); + tt_want(strcmp(evhttp_uri_get_path(uri), "") == 0); + tt_want(evhttp_uri_get_query(uri) == NULL); + tt_want(strcmp(evhttp_uri_get_fragment(uri), "fr?ed") == 0); + TT_URI("#fr?ed"); + evhttp_uri_free(uri); +#undef URI_PARSE +#undef TT_URI +#undef BAD +} + +static void +http_uriencode_test(void *ptr) +{ + char *s=NULL, *s2=NULL; + size_t sz; + int bytes_decoded; + +#define ENC(from,want,plus) do { \ + s = evhttp_uriencode((from), -1, (plus)); \ + tt_assert(s); \ + tt_str_op(s,==,(want)); \ + sz = -1; \ + s2 = evhttp_uridecode((s), (plus), &sz); \ + tt_assert(s2); \ + tt_str_op(s2,==,(from)); \ + tt_int_op(sz,==,strlen(from)); \ + free(s); \ + free(s2); \ + s = s2 = NULL; \ + } while (0) + +#define DEC(from,want,dp) do { \ + s = evhttp_uridecode((from),(dp),&sz); \ + tt_assert(s); \ + tt_str_op(s,==,(want)); \ + tt_int_op(sz,==,strlen(want)); \ + free(s); \ + s = NULL; \ + } while (0) + +#define OLD_DEC(from,want) do { \ + s = evhttp_decode_uri((from)); \ + tt_assert(s); \ + tt_str_op(s,==,(want)); \ + free(s); \ + s = NULL; \ + } while (0) + + + ENC("Hello", "Hello",0); + ENC("99", "99",0); + ENC("", "",0); + ENC( + "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ123456789-.~_", + "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ123456789-.~_",0); + ENC(" ", "%20",0); + ENC(" ", "+",1); + ENC("\xff\xf0\xe0", "%FF%F0%E0",0); + ENC("\x01\x19", "%01%19",1); + ENC("http://www.ietf.org/rfc/rfc3986.txt", + "http%3A%2F%2Fwww.ietf.org%2Frfc%2Frfc3986.txt",1); + + ENC("1+2=3", "1%2B2%3D3",1); + ENC("1+2=3", "1%2B2%3D3",0); + + /* Now try encoding with internal NULs. */ + s = evhttp_uriencode("hello\0world", 11, 0); + tt_assert(s); + tt_str_op(s,==,"hello%00world"); + free(s); + s = NULL; + + /* Now try decoding just part of string. */ + s = malloc(6 + 1 /* NUL byte */); + bytes_decoded = evhttp_decode_uri_internal("hello%20%20", 6, s, 0); + tt_assert(s); + tt_int_op(bytes_decoded,==,6); + tt_str_op(s,==,"hello%"); + free(s); + s = NULL; + + /* Now try out some decoding cases that we don't generate with + * encode_uri: Make sure that malformed stuff doesn't crash... */ + DEC("%%xhello th+ere \xff", + "%%xhello th+ere \xff", 0); + /* Make sure plus decoding works */ + DEC("plus+should%20work+", "plus should work ",1); + /* Try some lowercase hex */ + DEC("%f0%a0%b0", "\xf0\xa0\xb0",1); + + /* Try an internal NUL. */ + sz = 0; + s = evhttp_uridecode("%00%00x%00%00", 1, &sz); + tt_int_op(sz,==,5); + tt_assert(!memcmp(s, "\0\0x\0\0", 5)); + free(s); + s = NULL; + + /* Try with size == NULL */ + sz = 0; + s = evhttp_uridecode("%00%00x%00%00", 1, NULL); + tt_assert(!memcmp(s, "\0\0x\0\0", 5)); + free(s); + s = NULL; + + /* Test out the crazy old behavior of the deprecated + * evhttp_decode_uri */ + OLD_DEC("http://example.com/normal+path/?key=val+with+spaces", + "http://example.com/normal+path/?key=val with spaces"); + +end: + if (s) + free(s); + if (s2) + free(s2); +#undef ENC +#undef DEC +#undef OLD_DEC +} + +static void +http_base_test(void *ptr) +{ + struct event_base *base = NULL; + struct bufferevent *bev; + evutil_socket_t fd; + const char *http_request; + ev_uint16_t port = 0; + + test_ok = 0; + base = event_base_new(); + tt_assert(base); + http = http_setup(&port, base, 0); + + fd = http_connect("127.0.0.1", port); + tt_int_op(fd, >=, 0); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(base, fd, 0); + bufferevent_setcb(bev, http_readcb, http_writecb, + http_errorcb, base); + bufferevent_base_set(base, bev); + + http_request = + "GET /test HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + event_base_dispatch(base); + + bufferevent_free(bev); + evutil_closesocket(fd); + + evhttp_free(http); + + tt_int_op(test_ok, ==, 2); + +end: + if (base) + event_base_free(base); +} + +/* + * the server is just going to close the connection if it times out during + * reading the headers. + */ + +static void +http_incomplete_readcb(struct bufferevent *bev, void *arg) +{ + test_ok = -1; + event_base_loopexit(exit_base,NULL); +} + +static void +http_incomplete_errorcb(struct bufferevent *bev, short what, void *arg) +{ + if (what == (BEV_EVENT_READING|BEV_EVENT_EOF)) + test_ok++; + else + test_ok = -2; + event_base_loopexit(exit_base,NULL); +} + +static void +http_incomplete_writecb(struct bufferevent *bev, void *arg) +{ + if (arg != NULL) { + evutil_socket_t fd = *(evutil_socket_t *)arg; + /* terminate the write side to simulate EOF */ + shutdown(fd, SHUT_WR); + } + if (evbuffer_get_length(bufferevent_get_output(bev)) == 0) { + /* enable reading of the reply */ + bufferevent_enable(bev, EV_READ); + test_ok++; + } +} + +static void +http_incomplete_test_(struct basic_test_data *data, int use_timeout) +{ + struct bufferevent *bev; + evutil_socket_t fd; + const char *http_request; + ev_uint16_t port = 0; + struct timeval tv_start, tv_end; + + exit_base = data->base; + + test_ok = 0; + + http = http_setup(&port, data->base, 0); + evhttp_set_timeout(http, 1); + + fd = http_connect("127.0.0.1", port); + tt_int_op(fd, >=, 0); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, + http_incomplete_readcb, http_incomplete_writecb, + http_incomplete_errorcb, use_timeout ? NULL : &fd); + + http_request = + "GET /test HTTP/1.1\r\n" + "Host: somehost\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + evutil_gettimeofday(&tv_start, NULL); + + event_base_dispatch(data->base); + + evutil_gettimeofday(&tv_end, NULL); + evutil_timersub(&tv_end, &tv_start, &tv_end); + + bufferevent_free(bev); + if (use_timeout) { + evutil_closesocket(fd); + fd = -1; + } + + evhttp_free(http); + + if (use_timeout && tv_end.tv_sec >= 3) { + tt_abort_msg("time"); + } else if (!use_timeout && tv_end.tv_sec >= 1) { + /* we should be done immediately */ + tt_abort_msg("time"); + } + + tt_int_op(test_ok, ==, 2); + end: + if (fd >= 0) + evutil_closesocket(fd); +} +static void +http_incomplete_test(void *arg) +{ + http_incomplete_test_(arg, 0); +} +static void +http_incomplete_timeout_test(void *arg) +{ + http_incomplete_test_(arg, 1); +} + +/* + * the server is going to reply with chunked data. + */ + +static void +http_chunked_readcb(struct bufferevent *bev, void *arg) +{ + /* nothing here */ +} + +static void +http_chunked_errorcb(struct bufferevent *bev, short what, void *arg) +{ + struct evhttp_request *req = NULL; + + if (!test_ok) + goto out; + + test_ok = -1; + + if ((what & BEV_EVENT_EOF) != 0) { + const char *header; + enum message_read_status done; + req = evhttp_request_new(NULL, NULL); + + /* req->kind = EVHTTP_RESPONSE; */ + done = evhttp_parse_firstline_(req, bufferevent_get_input(bev)); + if (done != ALL_DATA_READ) + goto out; + + done = evhttp_parse_headers_(req, bufferevent_get_input(bev)); + if (done != ALL_DATA_READ) + goto out; + + header = evhttp_find_header(evhttp_request_get_input_headers(req), "Transfer-Encoding"); + if (header == NULL || strcmp(header, "chunked")) + goto out; + + header = evhttp_find_header(evhttp_request_get_input_headers(req), "Connection"); + if (header == NULL || strcmp(header, "close")) + goto out; + + header = evbuffer_readln(bufferevent_get_input(bev), NULL, EVBUFFER_EOL_CRLF); + if (header == NULL) + goto out; + /* 13 chars */ + if (strcmp(header, "d")) { + free((void*)header); + goto out; + } + free((void*)header); + + if (strncmp((char *)evbuffer_pullup(bufferevent_get_input(bev), 13), + "This is funny", 13)) + goto out; + + evbuffer_drain(bufferevent_get_input(bev), 13 + 2); + + header = evbuffer_readln(bufferevent_get_input(bev), NULL, EVBUFFER_EOL_CRLF); + if (header == NULL) + goto out; + /* 18 chars */ + if (strcmp(header, "12")) + goto out; + free((char *)header); + + if (strncmp((char *)evbuffer_pullup(bufferevent_get_input(bev), 18), + "but not hilarious.", 18)) + goto out; + + evbuffer_drain(bufferevent_get_input(bev), 18 + 2); + + header = evbuffer_readln(bufferevent_get_input(bev), NULL, EVBUFFER_EOL_CRLF); + if (header == NULL) + goto out; + /* 8 chars */ + if (strcmp(header, "8")) { + free((void*)header); + goto out; + } + free((char *)header); + + if (strncmp((char *)evbuffer_pullup(bufferevent_get_input(bev), 8), + "bwv 1052.", 8)) + goto out; + + evbuffer_drain(bufferevent_get_input(bev), 8 + 2); + + header = evbuffer_readln(bufferevent_get_input(bev), NULL, EVBUFFER_EOL_CRLF); + if (header == NULL) + goto out; + /* 0 chars */ + if (strcmp(header, "0")) { + free((void*)header); + goto out; + } + free((void *)header); + + test_ok = 2; + } + +out: + if (req) + evhttp_request_free(req); + + event_base_loopexit(arg, NULL); +} + +static void +http_chunked_writecb(struct bufferevent *bev, void *arg) +{ + if (evbuffer_get_length(bufferevent_get_output(bev)) == 0) { + /* enable reading of the reply */ + bufferevent_enable(bev, EV_READ); + test_ok++; + } +} + +static void +http_chunked_request_done(struct evhttp_request *req, void *arg) +{ + if (evhttp_request_get_response_code(req) != HTTP_OK) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evhttp_find_header(evhttp_request_get_input_headers(req), + "Transfer-Encoding") == NULL) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != 13 + 18 + 8) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + if (strncmp((char *)evbuffer_pullup(evhttp_request_get_input_buffer(req), 13 + 18 + 8), + "This is funnybut not hilarious.bwv 1052", + 13 + 18 + 8)) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + test_ok = 1; + event_base_loopexit(arg, NULL); +} + +static void +http_chunk_out_test(void *arg) +{ + struct basic_test_data *data = arg; + struct bufferevent *bev; + evutil_socket_t fd; + const char *http_request; + ev_uint16_t port = 0; + struct timeval tv_start, tv_end; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + int i; + + exit_base = data->base; + test_ok = 0; + + http = http_setup(&port, data->base, 0); + + fd = http_connect("127.0.0.1", port); + + /* Stupid thing to send a request */ + bev = bufferevent_socket_new(data->base, fd, 0); + bufferevent_setcb(bev, + http_chunked_readcb, http_chunked_writecb, + http_chunked_errorcb, data->base); + + http_request = + "GET /chunked HTTP/1.1\r\n" + "Host: somehost\r\n" + "Connection: close\r\n" + "\r\n"; + + bufferevent_write(bev, http_request, strlen(http_request)); + + evutil_gettimeofday(&tv_start, NULL); + + event_base_dispatch(data->base); + + bufferevent_free(bev); + + evutil_gettimeofday(&tv_end, NULL); + evutil_timersub(&tv_end, &tv_start, &tv_end); + + tt_int_op(tv_end.tv_sec, <, 1); + + tt_int_op(test_ok, ==, 2); + + /* now try again with the regular connection object */ + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* make two requests to check the keepalive behavior */ + for (i = 0; i < 2; i++) { + test_ok = 0; + req = evhttp_request_new(http_chunked_request_done,data->base); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, + EVHTTP_REQ_GET, "/chunked") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_assert(test_ok == 1); + } + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +static void +http_stream_out_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + + test_ok = 0; + exit_base = data->base; + + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + /* + * At this point, we want to schedule a request to the HTTP + * server using our make request method. + */ + + req = evhttp_request_new(http_request_done, + (void *)"This is funnybut not hilarious.bwv 1052"); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/streamed") + == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +static void +http_stream_in_chunk(struct evhttp_request *req, void *arg) +{ + struct evbuffer *reply = arg; + + if (evhttp_request_get_response_code(req) != HTTP_OK) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + evbuffer_add_buffer(reply, evhttp_request_get_input_buffer(req)); +} + +static void +http_stream_in_done(struct evhttp_request *req, void *arg) +{ + if (evbuffer_get_length(evhttp_request_get_input_buffer(req)) != 0) { + fprintf(stderr, "FAILED\n"); + exit(1); + } + + event_base_loopexit(exit_base, NULL); +} + +/** + * Makes a request and reads the response in chunks. + */ +static void +http_stream_in_test_(struct basic_test_data *data, char const *url, + size_t expected_len, char const *expected) +{ + struct evhttp_connection *evcon; + struct evbuffer *reply = evbuffer_new(); + struct evhttp_request *req = NULL; + ev_uint16_t port = 0; + + exit_base = data->base; + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL,"127.0.0.1", port); + tt_assert(evcon); + + req = evhttp_request_new(http_stream_in_done, reply); + evhttp_request_set_chunked_cb(req, http_stream_in_chunk); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, url) == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + if (evbuffer_get_length(reply) != expected_len) { + TT_DIE(("reply length %lu; expected %lu; FAILED (%s)\n", + (unsigned long)evbuffer_get_length(reply), + (unsigned long)expected_len, + (char*)evbuffer_pullup(reply, -1))); + } + + if (memcmp(evbuffer_pullup(reply, -1), expected, expected_len) != 0) { + tt_abort_msg("Memory mismatch"); + } + + test_ok = 1; + end: + if (reply) + evbuffer_free(reply); + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +static void +http_stream_in_test(void *arg) +{ + http_stream_in_test_(arg, "/chunked", 13 + 18 + 8, + "This is funnybut not hilarious.bwv 1052"); + + http_stream_in_test_(arg, "/test", strlen(BASIC_REQUEST_BODY), + BASIC_REQUEST_BODY); +} + +static void +http_stream_in_cancel_chunk(struct evhttp_request *req, void *arg) +{ + tt_int_op(evhttp_request_get_response_code(req), ==, HTTP_OK); + + end: + evhttp_cancel_request(req); + event_base_loopexit(arg, NULL); +} + +static void +http_stream_in_cancel_done(struct evhttp_request *req, void *arg) +{ + /* should never be called */ + tt_fail_msg("In cancel done"); +} + +static void +http_stream_in_cancel_test(void *arg) +{ + struct basic_test_data *data = arg; + struct evhttp_connection *evcon; + struct evhttp_request *req = NULL; + ev_uint16_t port = 0; + + http = http_setup(&port, data->base, 0); + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + req = evhttp_request_new(http_stream_in_cancel_done, data->base); + evhttp_request_set_chunked_cb(req, http_stream_in_cancel_chunk); + + /* We give ownership of the request to the connection */ + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/chunked") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + test_ok = 1; + end: + evhttp_connection_free(evcon); + evhttp_free(http); + +} + +static void +http_connection_fail_done(struct evhttp_request *req, void *arg) +{ + struct evhttp_connection *evcon = arg; + struct event_base *base = evhttp_connection_get_base(evcon); + + /* An ENETUNREACH error results in an unrecoverable + * evhttp_connection error (see evhttp_connection_fail_()). The + * connection will be reset, and the user will be notified with a NULL + * req parameter. */ + tt_assert(!req); + + evhttp_connection_free(evcon); + + test_ok = 1; + + end: + event_base_loopexit(base, NULL); +} + +/* Test unrecoverable evhttp_connection errors by generating an ENETUNREACH + * error on connection. */ +static void +http_connection_fail_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + + exit_base = data->base; + test_ok = 0; + + /* auto detect a port */ + http = http_setup(&port, data->base, 0); + evhttp_free(http); + http = NULL; + + /* Pick an unroutable address. This administratively scoped multicast + * address should do when working with TCP. */ + evcon = evhttp_connection_base_new(data->base, NULL, "239.10.20.30", 80); + tt_assert(evcon); + + /* + * At this point, we want to schedule an HTTP GET request + * server using our make request method. + */ + + req = evhttp_request_new(http_connection_fail_done, evcon); + tt_assert(req); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, "/") == -1) { + tt_abort_msg("Couldn't make request"); + } + + event_base_dispatch(data->base); + + tt_int_op(test_ok, ==, 1); + + end: + ; +} + +static void +http_connection_retry_done(struct evhttp_request *req, void *arg) +{ + tt_assert(req); + tt_int_op(evhttp_request_get_response_code(req), !=, HTTP_OK); + if (evhttp_find_header(evhttp_request_get_input_headers(req), "Content-Type") != NULL) { + tt_abort_msg("(content type)\n"); + } + + tt_uint_op(evbuffer_get_length(evhttp_request_get_input_buffer(req)), ==, 0); + + test_ok = 1; + end: + event_base_loopexit(arg,NULL); +} + +static struct event_base *http_make_web_server_base=NULL; +static void +http_make_web_server(evutil_socket_t fd, short what, void *arg) +{ + ev_uint16_t port = *(ev_uint16_t*)arg; + http = http_setup(&port, http_make_web_server_base, 0); +} + +static void +http_connection_retry_test(void *arg) +{ + struct basic_test_data *data = arg; + ev_uint16_t port = 0; + struct evhttp_connection *evcon = NULL; + struct evhttp_request *req = NULL; + struct timeval tv, tv_start, tv_end; + + exit_base = data->base; + test_ok = 0; + + /* auto detect a port */ + http = http_setup(&port, data->base, 0); + evhttp_free(http); + http = NULL; + + evcon = evhttp_connection_base_new(data->base, NULL, "127.0.0.1", port); + tt_assert(evcon); + + evhttp_connection_set_timeout(evcon, 1); + /* also bind to local host */ + evhttp_connection_set_local_address(evcon, "127.0.0.1"); + + /* + * At this point, we want to schedule an HTTP GET request + * server using our make request method. + */ + + req = evhttp_request_new(http_connection_retry_done, data->base); + tt_assert(req); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/?arg=val") == -1) { + tt_abort_msg("Couldn't make request"); + } + + evutil_gettimeofday(&tv_start, NULL); + event_base_dispatch(data->base); + evutil_gettimeofday(&tv_end, NULL); + evutil_timersub(&tv_end, &tv_start, &tv_end); + tt_int_op(tv_end.tv_sec, <, 1); + + tt_int_op(test_ok, ==, 1); + + /* + * now test the same but with retries + */ + test_ok = 0; + + { + const struct timeval tv_timeout = { 0, 500000 }; + const struct timeval tv_retry = { 0, 500000 }; + evhttp_connection_set_timeout_tv(evcon, &tv_timeout); + evhttp_connection_set_initial_retry_tv(evcon, &tv_retry); + } + evhttp_connection_set_retries(evcon, 1); + + req = evhttp_request_new(http_connection_retry_done, data->base); + tt_assert(req); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/?arg=val") == -1) { + tt_abort_msg("Couldn't make request"); + } + + evutil_gettimeofday(&tv_start, NULL); + event_base_dispatch(data->base); + evutil_gettimeofday(&tv_end, NULL); + + /* fails fast, .5 sec to wait to retry, fails fast again. */ + test_timeval_diff_leq(&tv_start, &tv_end, 500, 200); + + tt_assert(test_ok == 1); + + /* + * now test the same but with retries and give it a web server + * at the end + */ + test_ok = 0; + + evhttp_connection_set_timeout(evcon, 1); + evhttp_connection_set_retries(evcon, 3); + + req = evhttp_request_new(http_dispatcher_test_done, data->base); + tt_assert(req); + + /* Add the information that we care about */ + evhttp_add_header(evhttp_request_get_output_headers(req), "Host", "somehost"); + + if (evhttp_make_request(evcon, req, EVHTTP_REQ_GET, + "/?arg=val") == -1) { + tt_abort_msg("Couldn't make request"); + } + + /* start up a web server .2 seconds after the connection tried + * to send a request + */ + evutil_timerclear(&tv); + tv.tv_usec = 200000; + http_make_web_server_base = data->base; + event_base_once(data->base, -1, EV_TIMEOUT, http_make_web_server, &port, &tv); + + evutil_gettimeofday(&tv_start, NULL); + event_base_dispatch(data->base); + evutil_gettimeofday(&tv_end, NULL); + /* We'll wait twice as long as we did last time. */ + test_timeval_diff_leq(&tv_start, &tv_end, 1000, 400); + + tt_int_op(test_ok, ==, 1); + + end: + if (evcon) + evhttp_connection_free(evcon); + if (http) + evhttp_free(http); +} + +static void +http_primitives(void *ptr) +{ + char *escaped = NULL; + struct evhttp *http = NULL; + + escaped = evhttp_htmlescape("